Describe the feature request
I would like firebase-ui-auth to allow apps to customize the TopAppBar colors used by the built-in Compose auth screens.
At the moment, AuthUITheme.topAppBarColors is hardcoded internally and cannot be overridden from outside.
Current logic in AuthUITheme.kt:
@get:Composable
val topAppBarColors
get() = TopAppBarDefaults.topAppBarColors(
containerColor = MaterialTheme.colorScheme.primary,
titleContentColor = MaterialTheme.colorScheme.onPrimary,
navigationIconContentColor = MaterialTheme.colorScheme.onPrimary,
)
Because of this, apps that integrate FirebaseUI Compose auth screens cannot align the app bar colors with their own theme system unless they replace the whole screen content themselves.
Suggested API options
Any of these would solve the problem:
Option 1: Add topAppBarColors to AuthUITheme
Example:
data class AuthUITheme(
val colorScheme: ColorScheme = ...,
val typography: Typography = ...,
val shapes: Shapes = ...,
val topAppBarColors: TopAppBarColors? = null,
)
And internally:
val resolvedTopAppBarColors =
authUITheme.topAppBarColors ?: TopAppBarDefaults.topAppBarColors(...)
Option 2: Add a topAppBarColors parameter to screen composables
Example:
PhoneAuthScreen(
...,
topAppBarColors = TopAppBarDefaults.topAppBarColors(...)
)
Describe the feature request
I would like firebase-ui-auth to allow apps to customize the TopAppBar colors used by the built-in Compose auth screens.
At the moment, AuthUITheme.topAppBarColors is hardcoded internally and cannot be overridden from outside.
Current logic in AuthUITheme.kt:
Because of this, apps that integrate FirebaseUI Compose auth screens cannot align the app bar colors with their own theme system unless they replace the whole screen content themselves.
Suggested API options
Any of these would solve the problem:
Option 1: Add topAppBarColors to AuthUITheme
Example:
And internally:
Option 2: Add a topAppBarColors parameter to screen composables
Example: