Skip to content

Commit

Permalink
Add strings for search history UI
Browse files Browse the repository at this point in the history
  • Loading branch information
wkoomson committed Jun 28, 2023
1 parent 5e4789b commit 5bc65c0
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@ import androidx.compose.runtime.rememberCoroutineScope
import androidx.compose.runtime.saveable.rememberSaveable
import androidx.compose.runtime.setValue
import androidx.compose.ui.Modifier
import androidx.compose.ui.res.stringResource
import androidx.navigation.NavController
import com.jerboa.R
import com.jerboa.api.ApiState
import com.jerboa.db.AccountViewModel
import com.jerboa.ui.components.common.ApiErrorText
Expand Down Expand Up @@ -81,7 +83,7 @@ fun CommunityListActivity(
ListItem(
headlineContent = {
Text(
text = "Recent searches",
text = stringResource(R.string.community_list_recent_searches),
color = MaterialTheme.colorScheme.onBackground,
style = MaterialTheme.typography.labelLarge,
)
Expand Down Expand Up @@ -116,7 +118,10 @@ fun CommunityListActivity(
content = {
Icon(
Icons.Rounded.Close,
contentDescription = "Delete ${it.text}",
contentDescription = stringResource(
R.string.community_list_delete_search_item,
it.text,
),
tint = MaterialTheme.colorScheme.surfaceTint,
)
},
Expand All @@ -127,7 +132,7 @@ fun CommunityListActivity(
ListItem(
headlineContent = {
Text(
text = "Communities",
text = stringResource(R.string.community_list_title),
color = MaterialTheme.colorScheme.onBackground,
style = MaterialTheme.typography.labelLarge,
)
Expand Down
3 changes: 3 additions & 0 deletions app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,9 @@
<string name="community_link_users_month">%1$s users / month</string>
<string name="community_list_back">Back</string>
<string name="community_list_search">Search...</string>
<string name="community_list_title">Communities</string>
<string name="community_list_recent_searches">Recent searches</string>
<string name="community_list_delete_search_item">Delete %1$s</string>
<string name="community_pending">Pending</string>
<string name="community_refresh">Refresh</string>
<string name="community_sortBy">Sort by</string>
Expand Down

0 comments on commit 5bc65c0

Please sign in to comment.