Force theme and colors in WaitListView.
This commit is contained in:
parent
e7de13a1bc
commit
182e0ebf97
1 changed files with 65 additions and 61 deletions
|
|
@ -29,7 +29,9 @@ import androidx.compose.foundation.layout.padding
|
|||
import androidx.compose.foundation.layout.size
|
||||
import androidx.compose.foundation.layout.systemBarsPadding
|
||||
import androidx.compose.foundation.layout.widthIn
|
||||
import androidx.compose.material3.LocalContentColor
|
||||
import androidx.compose.runtime.Composable
|
||||
import androidx.compose.runtime.CompositionLocalProvider
|
||||
import androidx.compose.ui.Alignment
|
||||
import androidx.compose.ui.BiasAbsoluteAlignment
|
||||
import androidx.compose.ui.Modifier
|
||||
|
|
@ -131,6 +133,9 @@ private fun WaitListContent(
|
|||
state: WaitListState,
|
||||
onCancelClicked: () -> Unit,
|
||||
modifier: Modifier = Modifier,
|
||||
) {
|
||||
ElementTheme(
|
||||
darkTheme = true
|
||||
) {
|
||||
Box(
|
||||
modifier = modifier
|
||||
|
|
@ -139,7 +144,7 @@ private fun WaitListContent(
|
|||
.padding(horizontal = 16.dp, vertical = 16.dp)
|
||||
) {
|
||||
if (state.loginAction !is Async.Success) {
|
||||
ElementTheme(darkTheme = true) {
|
||||
CompositionLocalProvider(LocalContentColor provides Color.Black) {
|
||||
TextButton(
|
||||
text = stringResource(CommonStrings.action_cancel),
|
||||
onClick = onCancelClicked,
|
||||
|
|
@ -160,7 +165,7 @@ private fun WaitListContent(
|
|||
CircularProgressIndicator(
|
||||
modifier = Modifier.size(24.dp),
|
||||
strokeWidth = 2.dp,
|
||||
color = Color.White
|
||||
color = ElementTheme.colors.iconPrimary
|
||||
)
|
||||
} else {
|
||||
Spacer(modifier = Modifier.height(24.dp))
|
||||
|
|
@ -174,7 +179,7 @@ private fun WaitListContent(
|
|||
text = withColoredPeriod(titleRes),
|
||||
style = ElementTheme.typography.fontHeadingXlBold,
|
||||
textAlign = TextAlign.Center,
|
||||
color = Color.White,
|
||||
color = ElementTheme.colors.textPrimary,
|
||||
)
|
||||
Spacer(modifier = Modifier.height(8.dp))
|
||||
val subtitle = when (state.loginAction) {
|
||||
|
|
@ -198,7 +203,6 @@ private fun WaitListContent(
|
|||
}
|
||||
}
|
||||
if (state.loginAction is Async.Success) {
|
||||
ElementTheme(darkTheme = true) {
|
||||
Button(
|
||||
text = stringResource(id = CommonStrings.action_continue),
|
||||
onClick = { state.eventSink.invoke(WaitListEvents.Continue) },
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue