Section: align InfoRow / IndentedInfoRow horizontal padding with CARD_ITEM_PADDING

InfoRow defaulted to DEFAULT_PADDING (20dp), but card chrome adopted CARD_ITEM_PADDING (15dp) for SectionItemView and InfoRowTwoValues. Inside a card, rows of different kinds visibly jumped left/right. Bring InfoRow and its IndentedInfoRow variant onto the same baseline.
This commit is contained in:
another-simple-pixel
2026-05-16 13:18:26 -07:00
parent f2ef38092a
commit 4cbfea727f
2 changed files with 3 additions and 2 deletions
@@ -1,5 +1,6 @@
package chat.simplex.common.views.chatlist
import CARD_ITEM_PADDING
import InfoRow
import InfoRowTwoValues
import SectionBottomSpacer
@@ -444,7 +445,7 @@ fun XFTPStatsView(stats: AgentXFTPServerStatsData, statsStartedAt: Instant, rh:
@Composable
private fun IndentedInfoRow(title: String, desc: String) {
InfoRow(title, desc, padding = PaddingValues(start = 24.dp + DEFAULT_PADDING, end = DEFAULT_PADDING))
InfoRow(title, desc, padding = PaddingValues(start = 24.dp + CARD_ITEM_PADDING, end = CARD_ITEM_PADDING))
}
@Composable
@@ -347,7 +347,7 @@ fun TextIconSpaced(extraPadding: Boolean = false) {
}
@Composable
fun InfoRow(title: String, value: String, icon: Painter? = null, iconTint: Color? = null, textColor: Color = MaterialTheme.colors.onBackground, padding: PaddingValues = PaddingValues(horizontal = DEFAULT_PADDING)) {
fun InfoRow(title: String, value: String, icon: Painter? = null, iconTint: Color? = null, textColor: Color = MaterialTheme.colors.onBackground, padding: PaddingValues = PaddingValues(horizontal = CARD_ITEM_PADDING)) {
SectionItemViewSpaceBetween(padding = padding) {
Row {
val iconSize = with(LocalDensity.current) { 21.sp.toDp() }