ZIndexModifierSample
@Sampled
@Composable
fun ZIndexModifierSample() {
Box {
Text("Drawn second", Modifier.zIndex(1f))
Text("Drawn first")
}
}Creates a modifier that controls the drawing order for the children of the same layout parent.
CodeRabbit
AI writes the code. CodeRabbit catches the slop.
Robomori
Run Android emulators and devices outside Android Studio.
@Sampled
@Composable
fun ZIndexModifierSample() {
Box {
Text("Drawn second", Modifier.zIndex(1f))
Text("Drawn first")
}
}Content updated: