Color aliases now use ElementTheme

This commit is contained in:
Benoit Marty
2025-01-31 17:10:14 +01:00
parent 468ef0f7fc
commit 484ecb5f6c
2 changed files with 11 additions and 13 deletions

View File

@@ -24,7 +24,6 @@ import androidx.compose.foundation.layout.heightIn
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.size
import androidx.compose.foundation.layout.width
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.ripple
import androidx.compose.runtime.Composable
import androidx.compose.runtime.remember
@@ -212,7 +211,7 @@ private fun NameAndTimestampRow(
style = ElementTheme.typography.fontBodyLgMedium,
text = name ?: stringResource(id = CommonStrings.common_no_room_name),
fontStyle = FontStyle.Italic.takeIf { name == null },
color = MaterialTheme.roomListRoomName(),
color = ElementTheme.roomListRoomName(),
maxLines = 1,
overflow = TextOverflow.Ellipsis
)
@@ -223,7 +222,7 @@ private fun NameAndTimestampRow(
color = if (isHighlighted) {
ElementTheme.colors.unreadIndicator
} else {
MaterialTheme.roomListRoomMessageDate()
ElementTheme.roomListRoomMessageDate()
},
)
}
@@ -247,7 +246,7 @@ private fun InviteSubtitle(
maxLines = 1,
overflow = TextOverflow.Ellipsis,
style = ElementTheme.typography.fontBodyMdRegular,
color = MaterialTheme.roomListRoomMessage(),
color = ElementTheme.roomListRoomMessage(),
modifier = modifier,
)
}
@@ -268,7 +267,7 @@ private fun LastMessageAndIndicatorRow(
Text(
modifier = Modifier.weight(1f),
text = attributedLastMessage,
color = MaterialTheme.roomListRoomMessage(),
color = ElementTheme.roomListRoomMessage(),
style = ElementTheme.typography.fontBodyMdRegular,
minLines = 2,
maxLines = 2,
@@ -315,7 +314,7 @@ private fun InviteNameAndIndicatorRow(
style = ElementTheme.typography.fontBodyLgMedium,
text = name ?: stringResource(id = CommonStrings.common_no_room_name),
fontStyle = FontStyle.Italic.takeIf { name == null },
color = MaterialTheme.roomListRoomName(),
color = ElementTheme.roomListRoomName(),
maxLines = 1,
overflow = TextOverflow.Ellipsis
)