Use ElementTheme instead of MaterialTheme

This commit is contained in:
Benoit Marty 2025-01-31 18:22:29 +01:00
parent 4f5155c314
commit 07d4778ae5
59 changed files with 156 additions and 187 deletions

View file

@ -128,14 +128,14 @@ private fun KnockRequestsBannerContent(
Text(
text = state.formattedTitle(),
style = ElementTheme.typography.fontBodyMdMedium,
color = MaterialTheme.colorScheme.primary,
color = ElementTheme.colors.textPrimary,
textAlign = TextAlign.Start,
)
if (state.subtitle != null) {
Text(
text = state.subtitle,
style = ElementTheme.typography.fontBodySmRegular,
color = MaterialTheme.colorScheme.secondary,
color = ElementTheme.colors.textSecondary,
textAlign = TextAlign.Start,
)
}

View file

@ -27,7 +27,6 @@ import androidx.compose.foundation.layout.width
import androidx.compose.foundation.lazy.LazyColumn
import androidx.compose.foundation.lazy.itemsIndexed
import androidx.compose.material3.ExperimentalMaterial3Api
import androidx.compose.material3.MaterialTheme
import androidx.compose.runtime.Composable
import androidx.compose.runtime.getValue
import androidx.compose.runtime.mutableIntStateOf
@ -331,7 +330,7 @@ private fun KnockRequestItem(
text = knockRequest.getBestName(),
maxLines = 1,
overflow = TextOverflow.Ellipsis,
color = MaterialTheme.colorScheme.primary,
color = ElementTheme.colors.textPrimary,
style = ElementTheme.typography.fontBodyLgMedium,
)
val formattedDate = knockRequest.formattedDate
@ -339,7 +338,7 @@ private fun KnockRequestItem(
Spacer(modifier = Modifier.width(8.dp))
Text(
text = formattedDate,
color = MaterialTheme.colorScheme.secondary,
color = ElementTheme.colors.textSecondary,
style = ElementTheme.typography.fontBodySmRegular,
)
}
@ -348,7 +347,7 @@ private fun KnockRequestItem(
if (!knockRequest.displayName.isNullOrEmpty()) {
Text(
text = knockRequest.userId.value,
color = MaterialTheme.colorScheme.secondary,
color = ElementTheme.colors.textSecondary,
maxLines = 1,
overflow = TextOverflow.Ellipsis,
style = ElementTheme.typography.fontBodyMdRegular,