Set LocationShareRow max lines to Text components

This commit is contained in:
ganfra
2026-03-12 10:29:20 +01:00
parent e664fb0a61
commit 7b305e34ef

View File

@@ -19,6 +19,7 @@ import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.text.style.TextOverflow
import androidx.compose.ui.unit.dp
import io.element.android.compound.theme.ElementTheme
import io.element.android.compound.tokens.generated.CompoundIcons
@@ -62,6 +63,8 @@ fun LocationShareRow(
text = item.displayName,
style = ElementTheme.typography.fontBodyLgMedium,
color = ElementTheme.colors.textPrimary,
maxLines = 1,
overflow = TextOverflow.Ellipsis,
)
Row(
verticalAlignment = Alignment.CenterVertically,
@@ -82,12 +85,13 @@ fun LocationShareRow(
tint = ElementTheme.colors.iconSecondary,
modifier = Modifier.size(16.dp),
)
}
Text(
text = item.formattedTimestamp,
style = ElementTheme.typography.fontBodySmRegular,
color = ElementTheme.colors.textSecondary,
maxLines = 1,
overflow = TextOverflow.Ellipsis,
)
}
}