From 9846b6d36b448a3929f4cffd5d0e81a0e42925a3 Mon Sep 17 00:00:00 2001 From: Roman Makeev Date: Fri, 11 Aug 2023 21:50:18 +0300 Subject: [PATCH] fix: theme button click --- .../mobile/features/ui/status/StatusScreen.kt | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/modules/features/ui/src/commonMain/kotlin/com/makeevrserg/empireprojekt/mobile/features/ui/status/StatusScreen.kt b/modules/features/ui/src/commonMain/kotlin/com/makeevrserg/empireprojekt/mobile/features/ui/status/StatusScreen.kt index 46adb05f..bc2bd5c7 100644 --- a/modules/features/ui/src/commonMain/kotlin/com/makeevrserg/empireprojekt/mobile/features/ui/status/StatusScreen.kt +++ b/modules/features/ui/src/commonMain/kotlin/com/makeevrserg/empireprojekt/mobile/features/ui/status/StatusScreen.kt @@ -4,6 +4,7 @@ import androidx.compose.foundation.clickable import androidx.compose.foundation.layout.padding import androidx.compose.foundation.lazy.LazyColumn import androidx.compose.foundation.lazy.items +import androidx.compose.foundation.shape.CircleShape import androidx.compose.material.FloatingActionButton import androidx.compose.material.Icon import androidx.compose.material.Scaffold @@ -13,6 +14,7 @@ import androidx.compose.material.icons.filled.Info import androidx.compose.material.icons.filled.WbSunny import androidx.compose.runtime.Composable import androidx.compose.ui.Modifier +import androidx.compose.ui.draw.clip import com.makeevrserg.empireprojekt.mobile.core.ui.asComposableString import com.makeevrserg.empireprojekt.mobile.core.ui.components.navBarsPadding import com.makeevrserg.empireprojekt.mobile.core.ui.theme.AppTheme @@ -60,10 +62,13 @@ fun StatusScreen( imageVector = Icons.Filled.WbSunny, contentDescription = null, tint = AppTheme.materialColor.onPrimary, - modifier = Modifier.clickable { - val nextTheme = themeSwitcher.theme.value.next(ThemeSwitcher.Theme.values()) - themeSwitcher.selectTheme(nextTheme) - } + modifier = Modifier + .clip(CircleShape) + .clickable { + val nextTheme = + themeSwitcher.theme.value.next(ThemeSwitcher.Theme.values()) + themeSwitcher.selectTheme(nextTheme) + } ) } item {