File tree Expand file tree Collapse file tree 3 files changed +19
-8
lines changed
src/main/java/com/pira/ccloud Expand file tree Collapse file tree 3 files changed +19
-8
lines changed Original file line number Diff line number Diff line change @@ -18,8 +18,8 @@ android {
1818 // Android 8.x and below are not supported due to Jetpack Compose limitations
1919 minSdk = 26
2020 targetSdk = 36
21- versionCode = 14
22- versionName = " 1.1.3 "
21+ versionCode = 15
22+ versionName = " 1.1.4 "
2323
2424 testInstrumentationRunner = " androidx.test.runner.AndroidJUnitRunner"
2525 }
Original file line number Diff line number Diff line change 11package com.pira.ccloud.navigation
22
3+ import androidx.compose.foundation.isSystemInDarkTheme
34import androidx.compose.runtime.Composable
45import androidx.compose.runtime.remember
56import androidx.lifecycle.viewmodel.compose.viewModel
@@ -47,6 +48,7 @@ fun AppNavigation(
4748 startDestination = AppScreens .Splash .route
4849 ) {
4950 composable(route = AppScreens .Splash .route) {
51+ val isSystemInDarkMode = isSystemInDarkTheme()
5052 SplashScreen (
5153 onTimeout = {
5254 navController.popBackStack()
@@ -55,10 +57,20 @@ fun AppNavigation(
5557 launchSingleTop = true
5658 }
5759 },
58- backgroundColor = if (themeSettings.themeMode == com.pira.ccloud.ui.theme.ThemeMode .DARK ) {
59- androidx.compose.ui.graphics.Color (0xFF121212 )
60- } else {
61- androidx.compose.ui.graphics.Color (0xFFFFFBFE )
60+ backgroundColor = when (themeSettings.themeMode) {
61+ com.pira.ccloud.ui.theme.ThemeMode .DARK -> {
62+ androidx.compose.ui.graphics.Color (0xFF121212 )
63+ }
64+ com.pira.ccloud.ui.theme.ThemeMode .LIGHT -> {
65+ androidx.compose.ui.graphics.Color (0xFFFFFBFE )
66+ }
67+ com.pira.ccloud.ui.theme.ThemeMode .SYSTEM -> {
68+ if (isSystemInDarkMode) {
69+ androidx.compose.ui.graphics.Color (0xFF121212 )
70+ } else {
71+ androidx.compose.ui.graphics.Color (0xFFFFFBFE )
72+ }
73+ }
6274 }
6375 )
6476 }
Original file line number Diff line number Diff line change @@ -67,8 +67,7 @@ fun SplashScreen(
6767 Column (
6868 modifier = Modifier
6969 .fillMaxSize()
70- .background(backgroundColor)
71- .alpha(alpha.value),
70+ .background(backgroundColor),
7271 horizontalAlignment = Alignment .CenterHorizontally ,
7372 verticalArrangement = Arrangement .Center
7473 ) {
You can’t perform that action at this time.
0 commit comments