You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Animate clip-path: interpolate polygon, inset, circle and ellipse in keyframes #384
In the reel 4 reference, the dark wall of a neon room keeps changing silhouette while the camera moves: its cut corners slide from the top to the bottom, open, then close. The whole identity of the set rests on that living frame. Since #339, a static clip-path renders. Animating it isn't possible.
What happens
In keyframes, clip-path is rejected: unknown animation property 'clip-path'.
rules/clip-path.md states that it doesn't interpolate in a timeline either.
Attributes of an inline svg are frozen too.
The only option left is a crossfade between two walls, which shows a double chamfer mid-fade, or transforms, which move the shape without deforming it.
swept by a scalar motion property, clip_path_progress, through the ordinary keyframes engine. Polygon (equal vertex counts), inset, circle and ellipse all interpolate. A kind or vertex-count mismatch prints to stderr and leaves the node unclipped — the same precedent kind: node-path set, rather than a silent snap.
It came out that way because the literal form needs KeyframeValue in schema/animation.rs to grow a ClipPath variant and validate_schema.rs's exhaustive AnimationEffect match to learn it, and both were outside the workstream's file ownership. Reporting the wall instead of reaching across it was the right call there.
What is still missing
The spelling. This issue asks for property: "clip-path" with keyframes carrying shapes. That is not what an author writes today.
More than two shapes. A morph has exactly one from and one to. A three-stage silhouette needs stacked nodes.
The open question
Finishing the literal form is reachable — the blocking files are ordinary. The question is whether a second spelling for the same capability earns its keep, or whether the scalar-driven morph is simply the better design and this issue should be re-scoped to "morph chains of more than two shapes".
Worth an opinion before more code: the current form gets easing, spring, loop and per-keyframe easing for free precisely because it is an ordinary scalar track, and a shape-valued keyframe would have to re-earn all of that.
Activity
fix(paint): border-radius keyframes, border.style dashes, clip-path m…
fix(paint): animated border-radius, real dashed borders, and a clip-p…
LeadcodeDev commentedon Sep 27, 2026
#398 landed a working clip-path animation, but not the vocabulary this issue describes, so it stays open.
What shipped
swept by a scalar motion property,
clip_path_progress, through the ordinarykeyframesengine. Polygon (equal vertex counts), inset, circle and ellipse all interpolate. A kind or vertex-count mismatch prints to stderr and leaves the node unclipped — the same precedentkind: node-pathset, rather than a silent snap.It came out that way because the literal form needs
KeyframeValueinschema/animation.rsto grow aClipPathvariant andvalidate_schema.rs's exhaustiveAnimationEffectmatch to learn it, and both were outside the workstream's file ownership. Reporting the wall instead of reaching across it was the right call there.What is still missing
The spelling. This issue asks for
property: "clip-path"with keyframes carrying shapes. That is not what an author writes today.More than two shapes. A morph has exactly one
fromand oneto. A three-stage silhouette needs stacked nodes.The open question
Finishing the literal form is reachable — the blocking files are ordinary. The question is whether a second spelling for the same capability earns its keep, or whether the scalar-driven morph is simply the better design and this issue should be re-scoped to "morph chains of more than two shapes".
Worth an opinion before more code: the current form gets
easing,spring,loopand per-keyframe easing for free precisely because it is an ordinary scalar track, and a shape-valued keyframe would have to re-earn all of that.