keyframes
fun <T> keyframes(duration: Duration, block: KeyframesBuilder<T>.() -> Unit): DurationBasedAnimationSpec<T>
Creates a KeyframesSpec with the given duration and keyframe definitions.
keyframes<Float>(duration = 500.ms) {
0f at 0.ms using Easing.Linear
0.8f at 200.ms using Easing.FastOutSlowIn
1f at 500.ms
}Content copied to clipboard
Parameters
duration
The total duration of the keyframes animation.
block
Builder block for defining keyframes.