StylishDescriptions

fun StylishDescriptions(items: List<StylishDescriptionItem>, modifier: Modifier = Modifier, columns: Int = 2, labelStyle: TextStyle = MaterialTheme.typography.labelSmall, valueStyle: TextStyle = MaterialTheme.typography.bodyMedium, labelColor: Color = MaterialTheme.colorScheme.onSurfaceVariant, valueColor: Color = MaterialTheme.colorScheme.onSurface, containerColor: Color = MaterialTheme.colorScheme.surfaceContainerHigh, shape: Shape = RoundedCornerShape(DefaultStylishDimensions.connectedCornerRadius), cellPadding: PaddingValues = androidx.compose.foundation.layout.PaddingValues(horizontal = 16.dp, vertical = 12.dp))

A label/value detail grid — the web "Descriptions" pattern from Ant Design.

Renders items in rows of columns label/value pairs, each pair taking one grid column (label above value). Use it for read-only detail views (vehicle info, account settings, record details).

Parameters

items

The label/value pairs, in display order.

modifier

Modifier applied to the root surface.

columns

Number of pairs per row. Defaults to 2.

labelStyle

Typography of the labels. Defaults to MaterialTheme.typography.labelSmall.

valueStyle

Typography of the values. Defaults to MaterialTheme.typography.bodyMedium.

labelColor

Color of the labels. Defaults to MaterialTheme.colorScheme.onSurfaceVariant.

valueColor

Color of the values. Defaults to MaterialTheme.colorScheme.onSurface.

containerColor

Background of the surface. Defaults to MaterialTheme.colorScheme.surfaceContainerHigh.

shape

Corner shape of the surface. Defaults to RoundedCornerShape with DefaultStylishDimensions.connectedCornerRadius.

cellPadding

Inner padding of each pair. Defaults to 16 x 12 dp.