Renderer-side sequential animation chain.
Chains multiple transitions and springs that execute one after
another on the same prop. Each step's from: defaults to the
previous step's final value if not specified.
Usage
# List form
opacity: sequence([
transition(200, to: 1.0, from: 0.0),
loop(800, to: 0.7, from: 1.0, cycles: 3),
transition(300, to: 0.0)
])
# Do-block form
opacity: sequence do
transition(200, to: 1.0, from: 0.0)
loop(800, to: 0.7, from: 1.0, cycles: 3)
transition(300, to: 0.0)
endCompletion
Only the sequence-level on_complete: fires. Individual step
completion tags are ignored.
opacity: sequence([
transition(200, to: 1.0, from: 0.0),
transition(300, to: 0.0)
], on_complete: :fade_cycle_done)
Summary
Functions
Creates a new sequence from a list of transition/spring steps.
Sets the completion event tag.
Types
@type step() :: Plushie.Animation.Transition.t() | Plushie.Animation.Spring.t()
Functions
Creates a new sequence from a list of transition/spring steps.
Sequence.new([
Transition.new(200, to: 1.0, from: 0.0),
Transition.new(300, to: 0.0)
])
Sequence.new([...], on_complete: :done)
Sets the completion event tag.