diff --git a/app/src/main/java/com/rosetta/messenger/ui/chats/ChatsListScreen.kt b/app/src/main/java/com/rosetta/messenger/ui/chats/ChatsListScreen.kt index b59ddca..e38db2e 100644 --- a/app/src/main/java/com/rosetta/messenger/ui/chats/ChatsListScreen.kt +++ b/app/src/main/java/com/rosetta/messenger/ui/chats/ChatsListScreen.kt @@ -3190,44 +3190,15 @@ fun RequestsSection( Spacer(modifier = Modifier.width(12.dp)) Column(modifier = Modifier.weight(1f)) { - // Верхняя строка: название + badge - Row( - modifier = Modifier.fillMaxWidth(), - horizontalArrangement = Arrangement.SpaceBetween, - verticalAlignment = Alignment.CenterVertically - ) { - Text( - text = "Requests", - fontWeight = FontWeight.SemiBold, - fontSize = 16.sp, - color = titleColor, - maxLines = 1, - overflow = TextOverflow.Ellipsis, - modifier = Modifier.weight(1f) - ) - - // Badge справа на уровне заголовка - if (count > 0) { - Spacer(modifier = Modifier.width(8.dp)) - Box( - modifier = - Modifier - .defaultMinSize(minWidth = 22.dp, minHeight = 22.dp) - .clip(CircleShape) - .background(badgeColor), - contentAlignment = Alignment.Center - ) { - Text( - text = if (count > 99) "99+" else count.toString(), - fontSize = 12.sp, - fontWeight = FontWeight.Bold, - color = Color.White, - lineHeight = 12.sp, - modifier = Modifier.padding(horizontal = 5.dp, vertical = 3.dp) - ) - } - } - } + // Заголовок + Text( + text = "Requests", + fontWeight = FontWeight.SemiBold, + fontSize = 16.sp, + color = titleColor, + maxLines = 1, + overflow = TextOverflow.Ellipsis + ) // Нижняя строка: subtitle (последний запрос) if (subtitle.isNotEmpty()) { @@ -3241,6 +3212,28 @@ fun RequestsSection( ) } } + + // Badge — вертикально отцентрирован в строке + if (count > 0) { + Spacer(modifier = Modifier.width(8.dp)) + Box( + modifier = + Modifier + .defaultMinSize(minWidth = 22.dp, minHeight = 22.dp) + .clip(CircleShape) + .background(badgeColor), + contentAlignment = Alignment.Center + ) { + Text( + text = if (count > 99) "99+" else count.toString(), + fontSize = 12.sp, + fontWeight = FontWeight.Bold, + color = Color.White, + lineHeight = 12.sp, + modifier = Modifier.padding(horizontal = 5.dp, vertical = 3.dp) + ) + } + } } } }