diff --git a/feature/conversations/src/main/kotlin/dev/meloda/fast/conversations/presentation/ConversationItem.kt b/feature/conversations/src/main/kotlin/dev/meloda/fast/conversations/presentation/ConversationItem.kt index 4f3b430e..766975b7 100644 --- a/feature/conversations/src/main/kotlin/dev/meloda/fast/conversations/presentation/ConversationItem.kt +++ b/feature/conversations/src/main/kotlin/dev/meloda/fast/conversations/presentation/ConversationItem.kt @@ -134,7 +134,7 @@ fun ConversationItem( .size(32.dp), painter = painterResource(id = UiR.drawable.ic_round_bookmark_border_24), contentDescription = "Favorites icon", - tint = Color.White + tint = MaterialTheme.colorScheme.onPrimary ) } } else { 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 c61d3503..9f20c622 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 @@ -23,17 +23,23 @@ fun MessageBubble( date: String?, edited: Boolean, ) { + val backgroundColor = if (!isOut) { + MaterialTheme.colorScheme.surfaceColorAtElevation(2.dp) + } else { + MaterialTheme.colorScheme.primaryContainer + } + + val textColor = if (!isOut) { + MaterialTheme.colorScheme.onSurface + } else { + MaterialTheme.colorScheme.onPrimaryContainer + } + Box( modifier = modifier .widthIn(min = 56.dp) .clip(RoundedCornerShape(24.dp)) - .background( - if (isOut) { - MaterialTheme.colorScheme.surfaceColorAtElevation(2.dp) - } else { - MaterialTheme.colorScheme.primaryContainer - } - ) + .background(backgroundColor) .padding( horizontal = 8.dp, vertical = 6.dp @@ -45,7 +51,8 @@ fun MessageBubble( modifier = Modifier .padding(2.dp) .align(Alignment.Center) - .animateContentSize() + .animateContentSize(), + color = textColor ) }