NuvioStreaming/patch2.diff
harrydbarnes b73cccc43b feat: Add local filters to Trakt Library view all screen
- Added "All", "Movies", and "Series" FilterChips to the `CatalogHeader`.
- Computed `filteredItems` to apply filtering for the Trakt Library screen based on the item type (movies vs series/tv).
- Applied Material Theme `FilterChipDefaults` properties to ensure accurate theming.
2026-05-02 18:36:31 +00:00

12 lines
728 B
Diff

--- composeApp/src/commonMain/kotlin/com/nuvio/app/features/catalog/CatalogScreen.kt
+++ composeApp/src/commonMain/kotlin/com/nuvio/app/features/catalog/CatalogScreen.kt
@@ -86,8 +86,7 @@
var headerHeightPx by remember { mutableIntStateOf(0) }
var observedOfflineState by remember { mutableStateOf(false) }
- val isTraktLibrary = manifestUrl == INTERNAL_LIBRARY_MANIFEST_URL &&
- subtitle == stringResource(Res.string.compose_catalog_subtitle_trakt_library)
+ val isTraktLibrary = manifestUrl == INTERNAL_LIBRARY_MANIFEST_URL && subtitle.contains("Trakt", ignoreCase = true)
var selectedFilter by remember { mutableIntStateOf(0) }
val filteredItems = remember(uiState.items, selectedFilter) {