Segment
Represents a directional transition segment from initialState to targetState.
Used inside transitionSpec lambdas to select different animation specs based on the direction of a state transition. For example, an expand animation can use a bouncy spring while a collapse uses a quick tween.
transitionSpec = {
when {
false.isTransitioningTo(true) -> spring(stiffness = Stiffness.Low)
true.isTransitioningTo(false) -> tween(200.ms)
else -> spring()
}
}Content copied to clipboard
Functions
Link copied to clipboard
Returns true if the segment represents a transition from this value to target.