Fix status bar color in Compose theme
Use surface color instead of primary to match TopAppBar
This commit is contained in:
@@ -51,7 +51,7 @@ fun SFATheme(
|
||||
if (!view.isInEditMode) {
|
||||
SideEffect {
|
||||
val window = (view.context as? Activity)?.window ?: return@SideEffect
|
||||
window.statusBarColor = colorScheme.primary.toArgb()
|
||||
window.statusBarColor = colorScheme.surface.toArgb()
|
||||
window.navigationBarColor = colorScheme.background.toArgb()
|
||||
WindowCompat.getInsetsController(window, view).apply {
|
||||
isAppearanceLightStatusBars = !darkTheme
|
||||
|
||||
Reference in New Issue
Block a user