← Compose Multiplatform Component in Material Compose
Divider
Common
A divider is a thin line that groups content in lists and layouts.
![Dividers image](/component-preview/material/divider.png)
Last updated:
Installation
dependencies {
implementation("androidx.compose.material:material:1.7.0-beta04")
}
Overloads
@Composable
fun Divider(
modifier: Modifier = Modifier,
color: Color = MaterialTheme.colors.onSurface.copy(alpha = DividerAlpha),
thickness: Dp = 1.dp,
startIndent: Dp = 0.dp
)
Parameters
name | description |
---|---|
color | color of the divider line |
thickness | thickness of the divider line, 1 dp is used by default. Using [Dp.Hairline] will produce a single pixel divider regardless of screen density. |
startIndent | start offset of this line, no offset by default |