CDPotion.Domain.Animation (cdpotion v0.1.4)
Summary
Functions
Disables animation domain notifications.
Enables animation domain notifications.
Returns the current time of the an animation.
Gets the playback rate of the document timeline.
Releases a set of animations to no longer be manipulated.
Gets the remote object of the Animation.
Seek a set of animations to a particular time within each animation.
Sets the paused state of a set of animations.
Sets the playback rate of the document timeline.
Sets the timing of an animation node.
Types
animation()
@type animation() :: %{ cssId: String.t() | nil, currentTime: number(), id: String.t(), name: String.t(), pausedState: boolean(), playState: String.t(), playbackRate: number(), source: animation_effect() | nil, startTime: number(), type: :CSSTransition | :CSSAnimation | :WebAnimation }
Animation instance.
animation_effect()
@type animation_effect() :: %{ backendNodeId: CDPotion.Domain.DOM.backend_node_id() | nil, delay: number(), direction: String.t(), duration: number(), easing: String.t(), endDelay: number(), fill: String.t(), iterationStart: number(), iterations: number(), keyframesRule: keyframes_rule() | nil }
AnimationEffect instance
keyframe_style()
Keyframe Style
keyframes_rule()
@type keyframes_rule() :: %{keyframes: [keyframe_style()], name: String.t() | nil}
Keyframes Rule
Functions
disable()
Disables animation domain notifications.
enable()
Enables animation domain notifications.
get_current_time(id)
Returns the current time of the an animation.
Parameters:
- (Required)
id
: Id of animation.
get_playback_rate()
Gets the playback rate of the document timeline.
release_animations(animations)
Releases a set of animations to no longer be manipulated.
Parameters:
- (Required)
animations
: List of animation ids to seek.
resolve_animation(animation_id)
Gets the remote object of the Animation.
Parameters:
- (Required)
animation_id
: Animation id.
seek_animations(animations, current_time)
Seek a set of animations to a particular time within each animation.
Parameters:
- (Required)
animations
: List of animation ids to seek. - (Required)
current_time
: Set the current time of each animation.
set_paused(animations, paused)
Sets the paused state of a set of animations.
Parameters:
- (Required)
animations
: Animations to set the pause state of. - (Required)
paused
: Paused state to set to.
set_playback_rate(playback_rate)
Sets the playback rate of the document timeline.
Parameters:
- (Required)
playback_rate
: Playback rate for animations on page
set_timing(animation_id, duration, delay)
Sets the timing of an animation node.
Parameters:
- (Required)
animation_id
: Animation id. - (Required)
duration
: Duration of the animation. - (Required)
delay
: Delay of the animation.