De-duplicate string resource keys (#1560)

## Description
Ensures that all string & plural resource keys are unique. This should
help make sure all of the strings are shown in weblate's translation.

### Related issues
Related to #1551

### Testing
Emulator

## Screenshots
N/A

## AI or LLM usage
None
This commit is contained in:
Damontecres 2026-06-12 01:24:24 -04:00 • committed by GitHub
parent 38b4a8c4de
commit fa5cc99c3b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
42 changed files with 156 additions and 183 deletions

View file

@ -203,12 +203,12 @@ fun listToDotString(
@StringRes
fun formatTypeName(type: BaseItemKind): Int =
when (type) {
BaseItemKind.MOVIE -> R.string.movies
BaseItemKind.SERIES -> R.string.tv_shows
BaseItemKind.MOVIE -> R.string.movies_title
BaseItemKind.SERIES -> R.string.tv_shows_title
BaseItemKind.EPISODE -> R.string.episodes
BaseItemKind.VIDEO -> R.string.videos
BaseItemKind.PLAYLIST -> R.string.playlists
BaseItemKind.PERSON -> R.string.people
BaseItemKind.PERSON -> R.string.people_title
BaseItemKind.BOX_SET -> R.string.collections
BaseItemKind.AUDIO -> TODO()
BaseItemKind.CHANNEL -> R.string.channels

View file

@ -17,7 +17,7 @@ fun ExtrasRow(
modifier: Modifier = Modifier,
) {
ItemRow(
title = stringResource(R.string.extras),
title = stringResource(R.string.extras_title),
items = extras,
onClickItem = onClickItem,
onLongClickItem = onLongClickItem,

View file

@ -33,7 +33,7 @@ fun PersonRow(
people: List<Person>,
onClick: (Person) -> Unit,
modifier: Modifier = Modifier,
@StringRes title: Int = R.string.people,
@StringRes title: Int = R.string.people_title,
onLongClick: ((Int, Person) -> Unit)? = null,
) {
val firstFocus = remember { FocusRequester() }
@ -84,7 +84,7 @@ fun DiscoverPersonRow(
people: List<DiscoverItem>,
onClick: (DiscoverItem) -> Unit,
modifier: Modifier = Modifier,
@StringRes title: Int = R.string.people,
@StringRes title: Int = R.string.people_title,
onLongClick: ((Int, DiscoverItem) -> Unit)? = null,
) {
val firstFocus = remember { FocusRequester() }

View file

@ -56,12 +56,12 @@ fun FavoritesPage(
val tabs =
remember {
listOf(
TabDetails(R.string.movies),
TabDetails(R.string.tv_shows),
TabDetails(R.string.movies_title),
TabDetails(R.string.tv_shows_title),
TabDetails(R.string.episodes),
TabDetails(R.string.videos),
TabDetails(R.string.playlists),
TabDetails(R.string.people),
TabDetails(R.string.people_title),
)
}
val actions =

View file

@ -363,7 +363,7 @@ fun PersonPageContent(
}
item {
LoadingRow(
title = rowTitle(stringResource(R.string.movies), movies),
title = rowTitle(stringResource(R.string.movies_title), movies),
state = movies,
rowIndex = MOVIE_ROW,
position = position,
@ -376,7 +376,7 @@ fun PersonPageContent(
}
item {
LoadingRow(
title = rowTitle(stringResource(R.string.tv_shows), series),
title = rowTitle(stringResource(R.string.tv_shows_title), series),
state = series,
rowIndex = SERIES_ROW,
position = position,

View file

@ -80,7 +80,7 @@ class SeerrDiscoverViewModel
this.copy(
movies =
DiscoverRowData(
ResStringProvider(R.string.movies),
ResStringProvider(R.string.movies_title),
it,
DiscoverRequestType.DISCOVER_MOVIES,
),
@ -90,7 +90,7 @@ class SeerrDiscoverViewModel
this.copy(
tv =
DiscoverRowData(
ResStringProvider(R.string.tv_shows),
ResStringProvider(R.string.tv_shows_title),
it,
DiscoverRequestType.DISCOVER_TV,
),

View file

@ -682,7 +682,7 @@ fun SearchPage(
modifier = Modifier.focusGroup(),
) {
searchResultRow(
title = R.string.movies,
title = R.string.movies_title,
result = state.movies,
rowIndex = MOVIE_ROW,
position = position,
@ -692,7 +692,7 @@ fun SearchPage(
modifier = Modifier.fillMaxWidth(),
)
searchResultRow(
title = R.string.tv_shows,
title = R.string.tv_shows_title,
result = state.series,
rowIndex = SERIES_ROW,
position = position,

View file

@ -53,12 +53,12 @@ fun HomeSettingsFavoriteList(
val favoriteOptions by lazy {
mapOf(
BaseItemKind.MOVIE to R.string.movies,
BaseItemKind.SERIES to R.string.tv_shows,
BaseItemKind.MOVIE to R.string.movies_title,
BaseItemKind.SERIES to R.string.tv_shows_title,
BaseItemKind.EPISODE to R.string.episodes,
BaseItemKind.VIDEO to R.string.videos,
BaseItemKind.PLAYLIST to R.string.playlists,
BaseItemKind.PERSON to R.string.people,
BaseItemKind.PERSON to R.string.people_title,
BaseItemKind.MUSIC_ARTIST to R.string.artists,
BaseItemKind.MUSIC_ALBUM to R.string.albums,
)

View file

@ -413,7 +413,7 @@ class HomeSettingsViewModel
id = id,
title =
ResProviderStringProvider(
R.string.favorite_items,
R.string.favorite_items_title,
ResStringProvider(favoriteOptions[type]!!),
),
config = HomeRowConfig.Favorite(type),