User bubbles: move timestamp + delivery checkmarks to their own bottom-right line (Telegram look, matching agent bubbles) instead of inline at the end of the text

This commit is contained in:
ARIA committed 2026-08-21 00:01:13 +02:00
1 parent f8effb4152
commit a1814d016c
1 file changed
+28 -26
@@ -1912,33 +1912,35 @@ private fun MessageBubble(
Spacer(modifier = Modifier.height(6.dp))
}
if (isUser) {
// M7: text + inline timestamp / delivery status at the end
// (reference look); the bubble hugs its content. User text is
// rendered as markdown too (bold / italic / inline code), so a
// pasted snippet or emphasis shows up the same as in replies.
Row(verticalAlignment = Alignment.Bottom) {
if (msg.text.isNotBlank() || msg.streaming) {
MarkdownText(
text = msg.text.prepareForMarkdown().preserveNewlinesAsHardBreaks() +
if (msg.streaming) " ▉" else "",
color = textColor,
fontSize = 15.sp,
)
// M7: user text rendered as markdown (bold / italic / inline
// code), so a pasted snippet or emphasis shows up the same as
// in replies.
if (msg.text.isNotBlank() || msg.streaming) {
MarkdownText(
text = msg.text.prepareForMarkdown().preserveNewlinesAsHardBreaks() +
if (msg.streaming) " ▉" else "",
color = textColor,
fontSize = 15.sp,
)
}
// M7: timestamp + delivery status on their own line at the
// bottom-right (Telegram look, same as agent bubbles).
Row(
modifier = Modifier.fillMaxWidth(),
horizontalArrangement = Arrangement.End,
verticalAlignment = Alignment.CenterVertically,
) {
if (time.isNotEmpty()) {
Text(time, fontSize = 10.sp, color = textColor.copy(alpha = 0.6f))
}
Spacer(modifier = Modifier.width(8.dp))
Row(verticalAlignment = Alignment.CenterVertically) {
if (time.isNotEmpty()) {
Text(time, fontSize = 10.sp, color = textColor.copy(alpha = 0.6f))
}
when (msg.status) {
MsgStatus.Pending ->
Text(" sending…", fontSize = 10.sp, color = textColor.copy(alpha = 0.6f))
MsgStatus.Sent ->
Text(" ✓", fontSize = 10.sp, color = textColor.copy(alpha = 0.8f))
MsgStatus.Read ->
Text(" ✓✓", fontSize = 10.sp, color = textColor.copy(alpha = 0.8f))
MsgStatus.Failed -> Unit
}
when (msg.status) {
MsgStatus.Pending ->
Text(" sending…", fontSize = 10.sp, color = textColor.copy(alpha = 0.6f))
MsgStatus.Sent ->
Text(" ✓", fontSize = 10.sp, color = textColor.copy(alpha = 0.8f))
MsgStatus.Read ->
Text(" ✓✓", fontSize = 10.sp, color = textColor.copy(alpha = 0.8f))
MsgStatus.Failed -> Unit
}
}
if (msg.status == MsgStatus.Failed) {