Create and edit Lottie animations using Skia's Skottie module.
Works with
AI-first code editor with Composer
Before installing skills in Cursor, ensure your development environment meets these requirements:
node --versiontext-to-lottieExecute the skills CLI command in your project's root directory to begin installation:
Fetches text-to-lottie from diffusionstudio/lottie and configures it for Cursor.
The CLI shows a list of agents. Use arrow keys and space to select Cursor:
Confirm successful installation by checking the skill directory location:
Restart Cursor to activate text-to-lottie. Access via /text-to-lottie in your agent's command palette.
We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.
Skills execute code in your environment. Always review source, verify the publisher, and test in isolation before production.
Submit your Claude Code skill and start earning
Automate repetitive workflows and reduce manual effort
Example
Generate reports, summarize documents, draft communications
Save 3-5 hours per week on routine tasks
Learn new skills, understand complex topics, get expert guidance
Example
Explain concepts, provide examples, suggest learning resources
Accelerate learning and skill development by 2x
Enhance output quality through reviews, suggestions, and refinements
Example
Review drafts, suggest improvements, catch errors
Improve work quality by 30-40% with less effort
71
total installs
71
this week
0
upvotes
Run in your terminal
71
installs
71
this week
โ
stars
| name | text-to-lottie |
| description | Author a Lottie (Bodymovin) JSON animation that renders in a local skia player. Use whenever the user asks to create, generate, edit, or fix a Lottie animation, or asks for "an animation" to load. |
This app renders Lottie with Skia's Skottie module (via canvaskit-wasm),
not the JS lottie-web runtime. Follow the rules below and
verify the result.
This skill covers the mechanics โ the JSON shape Skottie needs. For the craft (timing, easing, choreography, Disney animation principles), see LottieFiles' motion-design skill. Its guidance is in milliseconds; convert to frames with
frames = ms / 1000 * fr.
The deliverable is not just public/lottie.json: the viewer should be set up
and the animation should be previewable in the browser. If the player project is
missing, create it; if it exists, install/update dependencies as needed, start
the dev server, and open the local preview URL for verification.
Always use the official GitHub player project โ never hand-roll a custom
viewer. This skill's JSON rules (slots, the properties panel, the ?frame=
URL controls, the Skottie wasm wiring) only hold inside that exact project. Do
not build your own HTML page, swap in lottie-web, or scaffold a bespoke
canvas setup โ any of those will silently diverge from how this player renders
and the verification steps below won't apply. If the player project isn't
already on this machine, scaffold a fresh copy of the repo with degit:
npx degit diffusionstudio/lottie my-animation
cd my-animation
npm install # postinstall copies the CanvasKit wasm into /public
npm run dev
Then open the printed local URL. If you already have the project, just
npm install && npm run dev.
public/lottie.json. That is the only file
you need to touch to change what the app shows โ src/App.tsx
fetches /lottie.json at startup.npm run dev), a Vite plugin watches that file
and full-reloads the page on save, so your edit appears immediately. No
other wiring is required.Every Lottie document is one JSON object with at least these fields:
{
"v": "5.7.0", // bodymovin version string
"fr": 60, // frame rate (fps)
"ip": 0, // in point (start frame)
"op": 120, // out point (end frame) โ duration = (op - ip) / fr seconds
"w": 512, // composition width (px)
"h": 512, // composition height (px)
"assets": [], // images / precomps; [] if none
"layers": [ /* ... */ ]
}
The app letterboxes the wรh composition to fit the canvas, so pick a square
or sensible aspect ratio. op controls the total frame count shown in the UI.
layers follows After Effects order: the first entry in the array is the
topmost layer, and later entries render underneath it. Each layer needs at
minimum:
{
"ty": 4, // layer type: 4 = shape layer (the common case)
"nm": "circle", // name (optional but helpful)
"ip": 0, // layer in point
"op": 120, // layer out point โ must cover the frames you want it visible
"st": 0, // start time
"ks": { /* transform โ see below */ },
"shapes": [ /* ... */ ] // for shape layers
}
Common layer types: 4 shape, 2 image, 1 solid, 0 precomp, 5 text.
Prefer shape layers (ty: 4) for LLM-authored animations โ no external
assets needed.
ks)Every layer has a transform. Each property is either static ({ "a": 0, "k": value })
or animated ({ "a": 1, "k": [ ...keyframes ] }).
"ks": {
"o": { "a": 0, "k": 100 }, // opacity 0โ100
"r": { "a": 0, "k": 0 }, // rotation (degrees)
"p": { "a": 0, "k": [256, 256, 0] }, // position [x, y, z]
"a": { "a": 0, "k": [0, 0, 0] }, // anchor point [x, y, z]
"s": { "a": 0, "k": [100, 100, 100] } // scale (percent, per axis)
}
Anchor matters: rotation and scale pivot around the anchor a, expressed in
the layer's own coordinate space. To rotate a shape around its own center, set
the shape's geometry around the anchor (e.g. center the ellipse on a).
Skottie requires shape elements to be wrapped in a Group (ty: "gr"). A flat
list of shapes + fills directly in shapes renders blank. Always nest the
geometry, fill/stroke, and a group transform inside a group's it array:
"shapes": [
{
"ty": "gr", // GROUP โ required wrapper
"nm": "ball",
"it": [
{
"ty": "el", // ellipse
"p": { "a": 0, "k": [0, 0] },
"s": { "a": 0, "k": [120, 120] }
},
{
"ty": "fl", // fill
"c": { "a": 0, "k": [0.2, 0.6, 1, 1] }, // RGBA, each 0โ1
"o": { "a": 0, "k": 100 }
},
{
"ty": "tr", // GROUP TRANSFORM โ include even if identity
"p": { "a": 0, "k": [0, 0] },
"a": { "a": 0, "k": [0, 0] },
"s": { "a": 0, "k": [100, 100] },
"r": { "a": 0, "k": 0 },
"o": { "a": 0, "k": 100 }
}
]
}
]
Shape primitives inside it:
"el" ellipse โ p center, s [width, height]"rc" rectangle โ p center, s [w, h], r corner radius"sh" custom path โ ks.k is a bezier { "c": closed?, "v": verts, "i": inTangents, "o": outTangents }"st" stroke โ c color, w width, o opacity"fl" fill โ c color (RGBA 0โ1), o opacity"tr" the group's transform (always include it last)Colors are normalized 0โ1 RGBA, not 0โ255. [1, 0, 0, 1] is opaque red.
Set "a": 1 and make k an array of keyframe objects. Each keyframe has a
time t (frame), a value s (start value for that segment, as an array), and
easing handles i/o:
"p": {
"a": 1,
"k": [
{ "t": 0, "s": [256, 120], "i": { "x": [0.5], "y": [1] }, "o": { "x": [0.5], "y": [0] } },
{ "t": 60, "s": [256, 400], "i": { "x": [0.5], "y": [1] }, "o": { "x": [0.5], "y": [0] } },
{ "t": 120, "s": [256, 120] }
]
}
t is the frame number; the last keyframe usually has no i/o/easing pair
beyond s (it's the end).s is always an array, even for scalars like rotation: "s": [360].i/o are the bezier ease handles (incoming / outgoing). x/y arrays in
[0..1]. For a smooth ease use x:[0.5], y:[1] (in) and x:[0.5], y:[0]
(out); for linear use x:[0], y:[0] / x:[1], y:[1]. Multi-dimensional
values may use per-axis arrays.The app can render a live properties panel (text inputs and sliders) that edit chosen values of the animation in real time. This rides on Skottie's native slot feature โ no re-parse, the change shows on the next frame.
To make a property editable, do two things:
1. Declare a slot in the Lottie JSON. Add a top-level "slots" object whose
keys are slot IDs, and point a property at one with "sid" instead of (or
alongside) an inline value. The slot's "p" holds the default, in the same
shape the property would normally take.
{
"v": "5.7.0", "fr": 60, "ip": 0, "op": 90, "w": 512, "h": 512, "assets": [],
"slots": {
"ballColor": { "p": { "a": 0, "k": [0.231, 0.6, 1, 1] } }, // color: RGBA 0โ1
"ballSize": { "p": { "a": 0, "k": 120 } } // scalar
},
"layers": [ /* ... */
// in the fill: "c": { "sid": "ballColor" }
// in a scalar: "s": { "sid": "ballSize" }
]
}
Slot types map to controls like this:
| Slot value | Control rendered |
|---|---|
| scalar (a single number) | slider |
| color (RGBA 0โ1) | color picker |
vec2 ([x, y]) | two number inputs |
| text (a string) | text input |
The app discovers slots automatically via Skottie's getSlotInfo() โ you do
not list them anywhere else for them to work. The panel appears as soon as
the animation declares at least one slot.
Every animation you produce must expose at least one control for the
background color. The player does not paint a composition background of its
own, so add a full-composition background layer as the last entry in
layers (so it renders underneath everything), fill it with a slotted color,
and label that slot in controls.json. Use a rectangle the size of the
composition:
// last layer in `layers`:
{
"ty": 4, "nm": "background", "ip": 0, "op": 120, "st": 0,
"ks": { "o": { "a": 0, "k": 100 }, "p": { "a": 0, "k": [256, 256, 0] },
"a": { "a": 0, "k": [0, 0, 0] }, "s": { "a": 0, "k": [100, 100, 100] },
"r": { "a": 0, "k": 0 } },
"shapes": [
{ "ty": "gr", "it": [
{ "ty": "rc", "p": { "a": 0, "k": [256, 256] },
"s": { "a": 0, "k": [512, 512] }, "r": { "a": 0, "k": 0 } },
{ "ty": "fl", "c": { "sid": "bgColor" }, "o": { "a": 0, "k": 100 } },
{ "ty": "tr", "p": { "a": 0, "k": [0, 0] }, "a": { "a": 0, "k": [0, 0] },
"s": { "a": 0, "k": [100, 100] }, "r": { "a": 0, "k": 0 },
"o": { "a": 0, "k": 100 } }
] }
}
// slots: "bgColor": { "p": { "a": 0, "k": [1, 1, 1, 1] } } // default white
// controls: { "sid": "bgColor", "label": "Background color" }
Match the rectangle's p/s to your composition's wรh. This is in addition
to whatever other controls the animation exposes.
2. (Optional) Describe presentation in public/controls.json. Slots only
expose an ID and type, not a label or a sensible slider range. The sidecar file
adds that. It is optional โ missing entries fall back to the slot ID and a
generic 0โ100 range. Like lottie.json, it hot-reloads on save.
{
"controls": [
{ "sid": "ballColor", "label": "Ball color" },
{ "sid": "ballSize", "label": "Ball size", "min": 40, "max": 240, "step": 1 }
]
}
sid must match a slot ID exactly.label is the display name; min/max/step shape scalar sliders and vec2
inputs (ignored for color/text).sid matches no slot is simply ignored; a slot with no entry
still renders with defaults.When you drive the page through a browser tool, do not pixel-drag the slider or hunt for the play button โ it's unreliable and you can't land on an exact frame. Instead, pin the frame in the URL and read the canvas by its test id:
http://localhost:5173/?frame=60&paused=1
?frame=N seeks to frame N on load and holds it paused, so the moment sits
still for a screenshot. This is the right way to inspect a specific frame
(e.g. "is the ball at the bottom at frame 60?"): open ?frame=60, then
screenshot.?paused=1 starts paused (at frame 0, or at frame if also given);
?paused=0 forces autoplay even with a frame pinned.To change the inspected frame, navigate to a new URL (or just edit the query
string and reload). The canvas carries data-testid="lottie-canvas", so a
browser tool can target it directly for screenshots. If the canvas is blank,
the page hasn't finished loading or the Lottie failed to parse (check the
on-screen error).
node -e "JSON.parse(require('fs').readFileSync('public/lottie.json','utf8'))"."ty": "gr" group's it array, and
each group ends with a "tr" transform.op and each layer's op cover the frames you animate.wรh composition.s values are arrays; loops repeat the first value at the end.layers) with a slotted fill (e.g. bgColor) and a matching
controls.json label.npm run dev. A blank canvas (no error) โ re-check the group wrapping.?frame=60&paused=1 and
screenshot, rather than dragging the on-screen slider.Prerequisites
Time Estimate
15-45 minutes depending on use case complexity
Steps
Common Pitfalls
โ Do
โ Don't
๐ก Pro Tips
โ Use when
Use when skill capabilities match your task, clear ROI on time saved, and you can validate outputs. Best for repetitive tasks, learning, and quality improvement.
โ Avoid when
Avoid when task requires deep expertise you can't validate, involves sensitive decisions, or when learning process is more valuable than speed of completion.
anthropics/claude-code
mblode/agent-skills
leonxlnx/taste-skill
sickn33/antigravity-awesome-skills
erichowens/some_claude_skills
hyperb1iss/hyperskills
text-to-lottie has been reliable in day-to-day use. Documentation quality is above average for community skills.
text-to-lottie is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.
Useful defaults in text-to-lottie โ fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.
I recommend text-to-lottie for anyone iterating fast on agent tooling; clear intent and a small, reviewable surface area.
Solid pick for teams standardizing on skills: text-to-lottie is focused, and the summary matches what you get after install.
Useful defaults in text-to-lottie โ fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.
text-to-lottie reduced setup friction for our internal harness; good balance of opinion and flexibility.
text-to-lottie fits our agent workflows well โ practical, well scoped, and easy to wire into existing repos.
text-to-lottie has been reliable in day-to-day use. Documentation quality is above average for community skills.
Solid pick for teams standardizing on skills: text-to-lottie is focused, and the summary matches what you get after install.
showing 1-10 of 61