Style: Update icons for message status and actions
This commit updates the icons used to indicate a message's status and within the message context menu. The outlined "star" and "edit" icons have been replaced with their filled variants for better visual distinction. Key changes: - Replaced `ic_star_round_24` with `ic_star_fill_round_24` for "important" messages in `DateStatus` and the "Mark as Important" action. - Replaced `ic_edit_round_24` with `ic_edit_fill_round_24` for "edited" messages in `DateStatus`. - Added the new `ic_edit_fill_round_24` drawable resource. - In `MessageBubble`, the `derivedStateOf` for `shouldFill` is now wrapped in a `remember` block to prevent unnecessary recompositions.
This commit is contained in:
+1
-1
@@ -54,7 +54,7 @@ sealed class MessageOption(
|
||||
|
||||
data object MarkAsImportant : MessageOption(
|
||||
titleResId = R.string.message_context_action_mark_as_important,
|
||||
iconResId = R.drawable.ic_star_round_24
|
||||
iconResId = R.drawable.ic_star_fill_round_24
|
||||
)
|
||||
|
||||
data object UnmarkAsImportant : MessageOption(
|
||||
|
||||
+2
-2
@@ -45,7 +45,7 @@ fun BoxScope.DateStatus(
|
||||
if (isImportant) {
|
||||
Spacer(modifier = Modifier.width(4.dp))
|
||||
Icon(
|
||||
painter = painterResource(R.drawable.ic_star_round_24),
|
||||
painter = painterResource(R.drawable.ic_star_fill_round_24),
|
||||
contentDescription = null,
|
||||
modifier = Modifier.size(14.dp)
|
||||
)
|
||||
@@ -64,7 +64,7 @@ fun BoxScope.DateStatus(
|
||||
if (isEdited) {
|
||||
Spacer(modifier = Modifier.width(4.dp))
|
||||
Icon(
|
||||
painter = painterResource(R.drawable.ic_edit_round_24),
|
||||
painter = painterResource(R.drawable.ic_edit_fill_round_24),
|
||||
contentDescription = null,
|
||||
modifier = Modifier.size(14.dp)
|
||||
)
|
||||
|
||||
+4
-2
@@ -85,8 +85,10 @@ fun MessageBubble(
|
||||
mutableIntStateOf(0)
|
||||
}
|
||||
|
||||
val shouldFill by derivedStateOf {
|
||||
attachmentsContainerWidth >= bubbleContainerWidth
|
||||
val shouldFill by remember {
|
||||
derivedStateOf {
|
||||
attachmentsContainerWidth >= bubbleContainerWidth
|
||||
}
|
||||
}
|
||||
|
||||
var containerWidth by remember {
|
||||
|
||||
Reference in New Issue
Block a user