MaterialSharedAxisX
fun <T> MaterialSharedAxisX(targetState: T, forward: Boolean, modifier: Modifier = Modifier, slideDistance: Dp = MotionConstants.DefaultSlideDistance, label: String = "MaterialSharedAxisX", content: @Composable AnimatedVisibilityScope.(T) -> Unit)(source)
MaterialSharedAxisX allows to switch between two layouts with a shared X-axis animation.
Parameters
forward
whether the direction of the animation is forward.
modifier
Modifier to be applied to the animation container.
slideDistance
slide distance of the animation.
label
An optional label to differentiate from other animations in Android Studio.
See also
com.google.android.material.transition.MaterialSharedAxis