<sk-keyframe-effect>

← prev index next →

The keyframe effect — the target, keyframes, and timing that together make up one animation, the unit the SkenraAnimatable family composes.

Remarks

A keyframe effect bundles what is animated (a target and its keyframes) with how long it takes (the timing). It has no element of its own: a single top-level effect is transparent — an sk-animation directly IS the keyframe effect, with its sk-keyframe children as the keyframes, its timing as the effect's timing, and its host node as the target.

Key attributes. The effect's controls are the animation's timing (duration, iterations, direction, easing, delay) plus its keyframes; the target is the element the animation applies to. composite decides how the effect stacks with others on the same property (replace, add, accumulate) when several animate it at once.

Related. It is embodied by an sk-animation with sk-keyframe children. Multiple effects compose in parallel via sk-group-effect or in sequence via sk-sequence-effect.

Serve these docs to run the live example. WebGPU needs a secure context — open this page via grunt serve rather than double-clicking the file. The Markup tab works from disk.

Attributes

AttributeTypeDefaultDescription
id <id> The element's unique identifier — the standard HTML global id attribute.
iterations <iteration-count> (<number> | Infinity) attribute only
direction <playback-direction> ("normal" | "reverse" | "alternate" | "alternate-reverse") attribute only
fill <fill-mode> ("none" | "forwards" | "backwards" | "both" | "auto") attribute only
easing <easing-function> attribute only
composite <composite-operation> ("replace" | "add" | "accumulate") Gets the composite operation for this effect per Web Animations spec §5.3.2.