From e3e9157dd56b5b6176dedd85de412654de74b450 Mon Sep 17 00:00:00 2001 From: Danil Nikolaev Date: Sat, 24 Jan 2026 21:58:11 +0300 Subject: [PATCH] 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. --- core/ui/src/main/res/drawable/ic_edit_fill_round_24.xml | 9 +++++++++ .../meloda/fast/messageshistory/model/MessageOption.kt | 2 +- .../fast/messageshistory/presentation/DateStatus.kt | 4 ++-- .../fast/messageshistory/presentation/MessageBubble.kt | 6 ++++-- 4 files changed, 16 insertions(+), 5 deletions(-) create mode 100644 core/ui/src/main/res/drawable/ic_edit_fill_round_24.xml diff --git a/core/ui/src/main/res/drawable/ic_edit_fill_round_24.xml b/core/ui/src/main/res/drawable/ic_edit_fill_round_24.xml new file mode 100644 index 00000000..6cf8f2f2 --- /dev/null +++ b/core/ui/src/main/res/drawable/ic_edit_fill_round_24.xml @@ -0,0 +1,9 @@ + + + diff --git a/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/model/MessageOption.kt b/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/model/MessageOption.kt index 5287730d..c752249e 100644 --- a/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/model/MessageOption.kt +++ b/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/model/MessageOption.kt @@ -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( diff --git a/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/presentation/DateStatus.kt b/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/presentation/DateStatus.kt index 1e854e15..571769d6 100644 --- a/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/presentation/DateStatus.kt +++ b/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/presentation/DateStatus.kt @@ -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) ) diff --git a/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/presentation/MessageBubble.kt b/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/presentation/MessageBubble.kt index 7ec2254e..5e8cf9e3 100644 --- a/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/presentation/MessageBubble.kt +++ b/feature/messageshistory/src/main/kotlin/dev/meloda/fast/messageshistory/presentation/MessageBubble.kt @@ -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 {