mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-08 05:46:45 +00:00
Force theme and colors in WaitListView.
This commit is contained in:
+8
-4
@@ -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
|
||||
@@ -132,6 +134,9 @@ private fun WaitListContent(
|
||||
onCancelClicked: () -> Unit,
|
||||
modifier: Modifier = Modifier,
|
||||
) {
|
||||
ElementTheme(
|
||||
darkTheme = true
|
||||
) {
|
||||
Box(
|
||||
modifier = modifier
|
||||
.fillMaxSize()
|
||||
@@ -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) },
|
||||
|
||||
Reference in New Issue
Block a user