From a826f58dede5db84bb4eede39fe22d5ac2584830 Mon Sep 17 00:00:00 2001 From: tapframe <85391825+tapframe@users.noreply.github.com> Date: Sat, 4 Apr 2026 13:54:09 +0530 Subject: [PATCH] fix: reorder general items, and adding animatecontentsize in epiosde section --- .../app/features/details/MetaDetailsScreen.kt | 15 +-------- .../details/components/DetailSeriesContent.kt | 2 ++ .../app/features/settings/SettingsRootPage.kt | 32 +++++++++---------- iosApp/iosApp.xcodeproj/project.pbxproj | 9 ++++-- 4 files changed, 26 insertions(+), 32 deletions(-) diff --git a/composeApp/src/commonMain/kotlin/com/nuvio/app/features/details/MetaDetailsScreen.kt b/composeApp/src/commonMain/kotlin/com/nuvio/app/features/details/MetaDetailsScreen.kt index e90bc459..d6d7ebd2 100644 --- a/composeApp/src/commonMain/kotlin/com/nuvio/app/features/details/MetaDetailsScreen.kt +++ b/composeApp/src/commonMain/kotlin/com/nuvio/app/features/details/MetaDetailsScreen.kt @@ -1,7 +1,6 @@ package com.nuvio.app.features.details import androidx.compose.animation.Crossfade -import androidx.compose.animation.core.Animatable import androidx.compose.animation.core.LinearOutSlowInEasing import androidx.compose.animation.core.animateFloatAsState import androidx.compose.animation.core.tween @@ -39,7 +38,6 @@ import androidx.compose.runtime.rememberCoroutineScope import androidx.compose.runtime.setValue import androidx.compose.ui.Alignment import androidx.compose.ui.Modifier -import androidx.compose.ui.draw.alpha import androidx.compose.ui.draw.blur import androidx.compose.ui.graphics.Brush import androidx.compose.ui.graphics.Color @@ -125,7 +123,6 @@ fun MetaDetailsScreen( WatchProgressRepository.ensureLoaded() WatchProgressRepository.uiState }.collectAsStateWithLifecycle() - val screenAlpha = remember(type, id) { Animatable(0f) } val needsFreshLoad = displayedMeta == null && !uiState.isLoading var selectedEpisodeForActions by remember(type, id) { mutableStateOf(null) } val commentsEnabled by remember { @@ -173,22 +170,12 @@ fun MetaDetailsScreen( } LaunchedEffect(type, id, needsFreshLoad) { - if (!needsFreshLoad) { - screenAlpha.snapTo(1f) - return@LaunchedEffect - } - screenAlpha.snapTo(0f) - screenAlpha.animateTo( - targetValue = 1f, - animationSpec = tween(durationMillis = 220), - ) - MetaDetailsRepository.load(type, id) + if (needsFreshLoad) MetaDetailsRepository.load(type, id) } Box( modifier = modifier .fillMaxSize() - .alpha(screenAlpha.value) .background(MaterialTheme.colorScheme.background), ) { when { diff --git a/composeApp/src/commonMain/kotlin/com/nuvio/app/features/details/components/DetailSeriesContent.kt b/composeApp/src/commonMain/kotlin/com/nuvio/app/features/details/components/DetailSeriesContent.kt index 2cef26bb..f39c2034 100644 --- a/composeApp/src/commonMain/kotlin/com/nuvio/app/features/details/components/DetailSeriesContent.kt +++ b/composeApp/src/commonMain/kotlin/com/nuvio/app/features/details/components/DetailSeriesContent.kt @@ -2,6 +2,7 @@ package com.nuvio.app.features.details.components import androidx.compose.animation.AnimatedContent import androidx.compose.animation.Crossfade +import androidx.compose.animation.animateContentSize import androidx.compose.animation.core.tween import androidx.compose.animation.fadeIn import androidx.compose.animation.fadeOut @@ -156,6 +157,7 @@ fun DetailSeriesContent( .any { !it.seasonPoster.isNullOrBlank() } } Column( + modifier = Modifier.animateContentSize(animationSpec = tween(280)), verticalArrangement = Arrangement.spacedBy(12.dp), ) { Row( diff --git a/composeApp/src/commonMain/kotlin/com/nuvio/app/features/settings/SettingsRootPage.kt b/composeApp/src/commonMain/kotlin/com/nuvio/app/features/settings/SettingsRootPage.kt index 93554e7b..7bf6051e 100644 --- a/composeApp/src/commonMain/kotlin/com/nuvio/app/features/settings/SettingsRootPage.kt +++ b/composeApp/src/commonMain/kotlin/com/nuvio/app/features/settings/SettingsRootPage.kt @@ -66,14 +66,6 @@ internal fun LazyListScope.settingsRootContent( isTablet = isTablet, ) { SettingsGroup(isTablet = isTablet) { - SettingsNavigationRow( - title = "Playback", - description = "Control player behavior and viewing defaults.", - icon = Icons.Rounded.PlayArrow, - isTablet = isTablet, - onClick = onPlaybackClick, - ) - SettingsGroupDivider(isTablet = isTablet) SettingsNavigationRow( title = "Appearance", description = "Tune home presentation and visual preferences.", @@ -82,14 +74,6 @@ internal fun LazyListScope.settingsRootContent( onClick = onAppearanceClick, ) SettingsGroupDivider(isTablet = isTablet) - SettingsNavigationRow( - title = "Notifications", - description = "Manage episode release alerts and send a test notification.", - icon = Icons.Rounded.Notifications, - isTablet = isTablet, - onClick = onNotificationsClick, - ) - SettingsGroupDivider(isTablet = isTablet) SettingsNavigationRow( title = "Content & Discovery", description = "Manage addons and discovery sources.", @@ -98,6 +82,14 @@ internal fun LazyListScope.settingsRootContent( onClick = onContentDiscoveryClick, ) SettingsGroupDivider(isTablet = isTablet) + SettingsNavigationRow( + title = "Playback", + description = "Control player behavior and viewing defaults.", + icon = Icons.Rounded.PlayArrow, + isTablet = isTablet, + onClick = onPlaybackClick, + ) + SettingsGroupDivider(isTablet = isTablet) SettingsNavigationRow( title = "Integrations", description = "Connect TMDB and MDBList services.", @@ -105,6 +97,14 @@ internal fun LazyListScope.settingsRootContent( isTablet = isTablet, onClick = onIntegrationsClick, ) + SettingsGroupDivider(isTablet = isTablet) + SettingsNavigationRow( + title = "Notifications", + description = "Manage episode release alerts and send a test notification.", + icon = Icons.Rounded.Notifications, + isTablet = isTablet, + onClick = onNotificationsClick, + ) } } } diff --git a/iosApp/iosApp.xcodeproj/project.pbxproj b/iosApp/iosApp.xcodeproj/project.pbxproj index c19bde73..12411d63 100644 --- a/iosApp/iosApp.xcodeproj/project.pbxproj +++ b/iosApp/iosApp.xcodeproj/project.pbxproj @@ -6,6 +6,10 @@ objectVersion = 77; objects = { +/* Begin PBXBuildFile section */ + 7397CF462F80FE3A00AC0F84 /* MPVKit in Frameworks */ = {isa = PBXBuildFile; productRef = A1B2C3D4E5F6A7B8C9D0E1F2 /* MPVKit */; }; +/* End PBXBuildFile section */ + /* Begin PBXFileReference section */ 07921B4E8F8546BEE682C2FE /* Nuvio.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Nuvio.app; sourceTree = BUILT_PRODUCTS_DIR; }; /* End PBXFileReference section */ @@ -41,6 +45,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + 7397CF462F80FE3A00AC0F84 /* MPVKit in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -115,11 +120,11 @@ ); mainGroup = 4BD16EE0A246E7EC8E40D563; minimizedProjectReferenceProxies = 1; - preferredProjectObjectVersion = 77; - productRefGroup = AD93033A33973C81BB77B73A /* Products */; packageReferences = ( F1E2D3C4B5A6F7E8D9C0B1A2 /* XCLocalSwiftPackageReference "../MPVKit" */, ); + preferredProjectObjectVersion = 77; + productRefGroup = AD93033A33973C81BB77B73A /* Products */; projectDirPath = ""; projectRoot = ""; targets = (