
kiwi.orbit.compose.ui.controls.Separator.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ui Show documentation
Show all versions of ui Show documentation
Orbit UI Components for Jetpack Compose
The newest version!
package kiwi.orbit.compose.ui.controls
import androidx.compose.foundation.background
import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.height
import androidx.compose.foundation.layout.padding
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.unit.Dp
import androidx.compose.ui.unit.dp
import kiwi.orbit.compose.ui.OrbitTheme
@Composable
public fun Separator(
modifier: Modifier = Modifier,
color: Color = OrbitTheme.colors.surface.normal,
thickness: Dp = 1.dp,
startIndent: Dp = 0.dp,
) {
val indentMod = if (startIndent.value != 0f) {
Modifier.padding(start = startIndent)
} else {
Modifier
}
Box(
modifier
.then(indentMod)
.fillMaxWidth()
.height(thickness)
.background(color),
)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy