slideOutVertically

fun slideOutVertically(spec: FiniteAnimationSpec<Float> = spring(), targetOffsetY: (fullHeight: Int) -> Int = { -it }): ExitTransition

Slides content out vertically. The targetOffsetY lambda receives the full height of the component and returns the pixel offset to end at.

Parameters

spec

The animation spec for the slide. Defaults to spring.

targetOffsetY

Returns the target Y offset in pixels. Defaults to sliding up above (-fullHeight).


fun slideOutVertically(duration: Duration, targetOffsetY: (fullHeight: Int) -> Int = { -it }): ExitTransition

Slides content out vertically over duration — a shortcut for slideOutVertically(tween(duration), targetOffsetY).

Parameters

duration

How long the slide runs.

targetOffsetY

Returns the target Y offset in pixels. Defaults to sliding up above (-fullHeight).