Files
effectcraft/crates/lottie/tests/fixtures/shapes-gradient.json
Brandon ThomasandClaude Opus 5.5 c4100bcf80 M11.4: Lottie export/import
New crate effectcraft-lottie (L3): export a comp to Lottie JSON / dotLottie
(precomp and base64 image assets; shape, solid, null, precomp, image and text
layers or glyph shapes; transforms with parenting, separated position,
anchor; keyframes with speed/influence converted to normalised i/o tangents,
hold keys, spatial ti/to; all shape items incl. gradients, dashes, trim,
repeater and path operators; masks, track mattes, blend modes, time remap,
timing, markers, optional expressions, a few Lottie effects) with a warnings
list for what Lottie cannot express, and the inverse import. Commands
file.exportLottie / file.importLottie with File > Export / Import entries.
Round-trip tests (values and rendered frames) and hand-written fixtures.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-02 08:56:03 -04:00

68 lines
2.3 KiB
JSON

{
"v": "5.12.0",
"nm": "Shapes and Gradient",
"fr": 24,
"ip": 0,
"op": 24,
"w": 160,
"h": 120,
"assets": [],
"layers": [
{
"ind": 1,
"ty": 4,
"nm": "Shapes",
"sr": 1,
"ks": { "a": { "a": 0, "k": [0, 0] }, "p": { "a": 0, "k": [80, 60] }, "s": { "a": 0, "k": [100, 100] }, "r": { "a": 0, "k": 0 }, "o": { "a": 0, "k": 100 } },
"ip": 0,
"op": 24,
"st": 0,
"bm": 0,
"shapes": [
{
"ty": "gr",
"nm": "Badge",
"it": [
{ "ty": "sr", "nm": "Star", "sy": 1, "d": 1, "pt": { "a": 0, "k": 6 }, "p": { "a": 0, "k": [-30, 0] }, "r": { "a": 0, "k": 0 }, "ir": { "a": 0, "k": 12 }, "or": { "a": 0, "k": 28 }, "is": { "a": 0, "k": 0 }, "os": { "a": 0, "k": 0 } },
{ "ty": "rc", "nm": "Box", "d": 1, "p": { "a": 0, "k": [30, 0] }, "s": { "a": 0, "k": [50, 40] }, "r": { "a": 0, "k": 8 } },
{
"ty": "gf",
"nm": "Gradient",
"o": { "a": 0, "k": 100 },
"r": 1,
"s": { "a": 0, "k": [-60, 0] },
"e": { "a": 0, "k": [60, 0] },
"t": 1,
"g": { "p": 2, "k": { "a": 0, "k": [0, 0.1, 0.4, 0.9, 1, 0.9, 0.2, 0.5] } }
},
{
"ty": "st",
"nm": "Outline",
"c": { "a": 0, "k": [1, 1, 1, 1] },
"o": { "a": 0, "k": 100 },
"w": { "a": 0, "k": 2 },
"lc": 2,
"lj": 2,
"ml": 4,
"d": [
{ "n": "d", "nm": "dash", "v": { "a": 0, "k": 4 } },
{ "n": "g", "nm": "gap", "v": { "a": 0, "k": 2 } },
{ "n": "o", "nm": "offset", "v": { "a": 0, "k": 0 } }
]
},
{
"ty": "tm",
"nm": "Trim",
"s": { "a": 0, "k": 0 },
"e": { "a": 1, "k": [{ "t": 0, "s": [10], "o": { "x": [0.167], "y": [0.167] }, "i": { "x": [0.833], "y": [0.833] } }, { "t": 23, "s": [100] }] },
"o": { "a": 0, "k": 0 },
"m": 1
},
{ "ty": "tr", "a": { "a": 0, "k": [0, 0] }, "p": { "a": 0, "k": [0, 0] }, "s": { "a": 0, "k": [100, 100] }, "r": { "a": 0, "k": 0 }, "o": { "a": 0, "k": 100 } }
]
}
]
}
]
}