Package-level declarations

Types

Link copied to clipboard

Computes how long an item waits before starting its entrance transition.

Link copied to clipboard

Describes an entering item's position relative to the currently visible grid items.

Link copied to clipboard

Controls whether a lazy grid item can run its entrance animation more than once.

Link copied to clipboard

Describes the grid's scroll context when an item begins its entrance animation.

Link copied to clipboard

Retains the keys that have started an entrance animation for a particular lazy grid state.

Link copied to clipboard
class ShakeController(amplitude: Dp = 20.dp, @IntRange(from = 0) durationMillis: Int = 400, @FloatRange(from = 0.0) frequencyHz: Float = 8.0f, @FloatRange(from = 0.0, to = 1.0) decay: Float = 0.7f)

Controls a horizontal shake animation applied through Modifier.shakenBy.

Functions

Link copied to clipboard
context(_: LazyGridItemScope)
fun Modifier.animateLazyGridItemEntrance(itemKey: Any, state: LazyGridItemEntranceState, repeatMode: LazyGridItemEntranceRepeatMode = LazyGridItemEntranceRepeatMode.OncePerKey, delay: LazyGridItemEntranceDelay = LazyGridItemEntranceDelay.diagonal(), animationSpec: FiniteAnimationSpec<Float> = tween(500, easing = LinearOutSlowInEasing), initialScale: Float = 0.8f, initialAlpha: Float = 0.0f): Modifier

Scales and fades a lazy grid item into place after its computed entrance delay.

Link copied to clipboard

Remembers entrance history associated with gridState.

Link copied to clipboard
fun rememberShakeController(amplitude: Dp = 20.dp, @IntRange(from = 0) durationMillis: Int = 400, @FloatRange(from = 0.0) frequencyHz: Float = 8.0f, @FloatRange(from = 0.0, to = 1.0) decay: Float = 0.7f): ShakeController

Creates and remembers a ShakeController.

Link copied to clipboard

Applies the horizontal shake translation controlled by controller.

Link copied to clipboard

Converts a TimeInterpolator from the View animation system into a Compose Easing. This allows existing interpolators to be reused in Compose animation specs.