Reorder Watch Provider Above Watch Region

This commit is contained in:
kmshaw1990 2026-05-14 13:34:17 -05:00
parent 0a3dd1d127
commit 47b81ae51c

View file

@ -1354,30 +1354,6 @@ private fun TmdbSourcePickerScreen(
}
},
)
TmdbQuickChips(
label = stringResource(Res.string.collections_editor_tmdb_quick_watch_regions),
chips = listOf(
stringResource(Res.string.collections_editor_tmdb_country_us) to "US",
stringResource(Res.string.collections_editor_tmdb_country_uk) to "GB",
"Canada" to "CA",
"Australia" to "AU",
"Germany" to "DE",
),
onSelect = { value ->
CollectionEditorRepository.updateTmdbFilters { it.copy(watchRegion = value) }
},
)
TmdbFilterField(
label = stringResource(Res.string.collections_editor_tmdb_watch_region),
helper = stringResource(Res.string.collections_editor_tmdb_watch_region_helper),
value = state.tmdbFilters.watchRegion.orEmpty(),
placeholder = "US",
onValueChange = { value ->
CollectionEditorRepository.updateTmdbFilters {
it.copy(watchRegion = value.ifBlank { null })
}
},
)
TmdbQuickChips(
label = stringResource(Res.string.collections_editor_tmdb_quick_watch_providers),
chips = listOf(
@ -1402,6 +1378,30 @@ private fun TmdbSourcePickerScreen(
}
},
)
TmdbQuickChips(
label = stringResource(Res.string.collections_editor_tmdb_quick_watch_regions),
chips = listOf(
stringResource(Res.string.collections_editor_tmdb_country_us) to "US",
stringResource(Res.string.collections_editor_tmdb_country_uk) to "GB",
"Canada" to "CA",
"Australia" to "AU",
"Germany" to "DE",
),
onSelect = { value ->
CollectionEditorRepository.updateTmdbFilters { it.copy(watchRegion = value) }
},
)
TmdbFilterField(
label = stringResource(Res.string.collections_editor_tmdb_watch_region),
helper = stringResource(Res.string.collections_editor_tmdb_watch_region_helper),
value = state.tmdbFilters.watchRegion.orEmpty(),
placeholder = "US",
onValueChange = { value ->
CollectionEditorRepository.updateTmdbFilters {
it.copy(watchRegion = value.ifBlank { null })
}
},
)
}
}
}