Skip to content
Back to search

motion2code

MarketplaceWorks with Claude CodeGitHub

Motion design video to code skills for coding agents

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/lovisdotio--motion2code/badge.svg)](/listings/lovisdotio--motion2code)

HTML

<a href="/listings/lovisdotio--motion2code"><img src="/api/listings/lovisdotio--motion2code/badge.svg" alt="findsafeskills safety rating" /></a>

Install

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

**Claude Code** (plugin marketplace):

claude plugin marketplace add lovisdotio/motion2code
claude plugin install motion2code@motion2code

Or copy the skill: `cp -R skills/motion2code ~/.claude/skills/`.

**Codex, Cursor, Gemini CLI, Copilot and about 70 other agents** (via [skills](https://github.com/vercel-labs/skills)):

npx skills add lovisdotio/motion2code

Or install by hand: - **Codex:** copy `skills/motion2code` to `~/.agents/skills/`. - **Cursor:** copy it to `~/.cursor/skills/`, plus the rule in `adapters/cursor/`. - **Copilot:** `gh skill install lovisdotio/motion2code motion2code`, plus `adapters/copilot/`. - **Gemini CLI:** `gemini extensions install https://github.com/lovisdotio/motion2code`. - **Hermes:** copy it to `~/.hermes/skills/`.

**claude.ai:** zip `skills/motion2code` and upload it under Settings > Capabilities > Skills.

**ChatGPT, Gemini Gems and other chat tools:** see [`adapters/`](adapters/).

The scripts need Python 3.9+, ffmpeg, and Playwright for the ones that open a browser (`uv run --with playwright python ...`, or `pip install playwright && python -m playwright install chromium`).

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

.claude-plugin/marketplace.json · Manifest · 14 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. {
  2. "name": "motion2code",
  3. "description": "Motion design video to code skills for coding agents",
  4. "owner": { "name": "lovisdotio", "url": "https://github.com/lovisdotio" },
  5. "plugins": [
  6. {
  7. "name": "motion2code",
  8. "source": "./",
  9. "description": "Rebuild a motion design video as looping SVG + GSAP code, verified frame by frame against the source",
  10. "category": "development",
  11. "tags": ["svg", "gsap", "motion-design", "animation", "scrolltrigger"]
  12. }
  13. ]
  14. }
README.md · README · 144 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. # Motion2Code
  2. A skill that teaches coding agents to rebuild a motion design video as clean, editable code: inline SVG shapes
  3. animated by one GSAP timeline, seekable frame by frame, looping seamlessly, and checked side by side against the
  4. source. For screen recordings of websites and apps it goes one step further and builds the real, interactive site
  5. with GSAP ScrollTrigger. It works with Claude Code, Codex, Cursor, Copilot, Gemini and others.
  6. **See them running live:** [fal-motion-in-code.vercel.app](https://fal-motion-in-code.vercel.app)
  7. | | | |
  8. |---|---|---|
  9. | [![Think Big](gallery/think-big/poster.gif)](gallery/think-big/index.html) | [![Eye](gallery/eye/poster.gif)](gallery/eye/index.html) | [![Festival map](gallery/festival-map/poster.gif)](gallery/festival-map/index.html) |
  10. | Kinetic type: a square grows into THINK, a bar wipes to BIG, the period becomes a sun. 10 s, 24 KB | Match cuts: an eye opens, its pupil becomes the O of LOOK, a grid of blinking eyes, SEE., NOTICE. 10 s, 40 KB | Festival site replay: the poster folds into a map, a stage card plays, day turns to night. 15 s, 52 KB, [real site](gallery/festival-map/site.html) |
  11. | [![Weather radar](gallery/weather-radar/poster.gif)](gallery/weather-radar/index.html) | [![Sticker portfolio](gallery/sticker-portfolio/poster.gif)](gallery/sticker-portfolio/index.html) | [![Podcast player](gallery/podcast-player/poster.gif)](gallery/podcast-player/index.html) |
  12. | Weather site replay: the slider drags rain bands across the map, TUE turns it sunny, WED strikes lightning. 15 s, 60 KB, [real site](gallery/weather-radar/site.html) | Portfolio replay: a sticker is dragged, the cat unfolds into a grid of cards, HI!, every sticker flies home. 15 s, 56 KB, [real site](gallery/sticker-portfolio/site.html) | Podcast page replay: PLAY, the waveform pulses, transcript bars light up, the cover bounces to the beat. 15 s, 36 KB, [real site](gallery/podcast-player/site.html) |
  13. Each image links to its self-contained `index.html`. Every folder in [`gallery/`](gallery/) also has `compare.html`
  14. (the source and the code side by side, synced frame by frame) and the source clip at 480p. The source videos were
  15. generated with MiniMax H3 Max on fal (fal.ai) and rebuilt by Claude Opus 5.5 with this skill.
  16. ## Why
  17. ![Source video and code, side by side](gallery/hero.gif)
  18. Agents animate blind: they cannot watch the video. Asked to "recreate this clip", they write what they imagine:
  19. the wrong beat at the wrong second, `power1.inOut` where the source snaps and overshoots, colors from memory, words
  20. spelled the way the model misspelled them, and an animation that jumps when it loops. Some quietly embed the
  21. video or trace its frames instead of rebuilding it. This skill closes those gaps:
  22. - **Look before coding.** `study_video.py` turns the clip into what an agent can see: a frame every 0.25 s, the
  23. frames around every hard change, a contact sheet, the exact flat palette, and whether the source loops.
  24. - **One clock, one contract.** A single GSAP timeline drives everything and the page exposes
  25. `window.anim.seek(t)`, so any moment can be rendered, compared and tested deterministically.
  26. - **Proof, not "looks right".** `frame_diff.py` puts the source and the code side by side at any time, down to
  27. every frame of a transition, with a score to rank the worst moments. `compare.html` does the same live.
  28. - **The loop is done in code.** Even when the video does not loop, the last moment returns to the exact opening
  29. frame; `check_anim.py` measures the seam.
  30. - **Exact frames out.** `render_anim.py` renders through `seek(t)`, frame by frame, so proof videos and GIFs never
  31. drop or double frames.
  32. - **Vectors at any size.** The source is a 1080p video; the code renders sharp at 4K, 8K, 16K or 32K, weighs tens of
  33. kilobytes, and stays editable: recolor, retime or rewrite a word in a text editor.
  34. - **Real sites from fake ones.** A video model's "screen recording" becomes a working page: real scroll with
  35. ScrollTrigger, real buttons, keyboard and mobile support.
  36. ## Install
  37. **Claude Code** (plugin marketplace):
  38. ```bash
  39. claude plugin marketplace add lovisdotio/motion2code
  40. ```
  41. ```bash
  42. claude plugin install motion2code@motion2code
  43. ```
  44. Or copy the skill: `cp -R skills/motion2code ~/.claude/skills/`.
  45. **Codex, Cursor, Gemini CLI, Copilot and about 70 other agents** (via [skills](https://github.com/vercel-labs/skills)):
  46. ```bash
  47. npx skills add lovisdotio/motion2code
  48. ```
  49. Or install by hand:
  50. - **Codex:** copy `skills/motion2code` to `~/.agents/skills/`.
  51. - **Cursor:** copy it to `~/.cursor/skills/`, plus the rule in `adapters/cursor/`.
  52. - **Copilot:** `gh skill install lovisdotio/motion2code motion2code`, plus `adapters/copilot/`.
  53. - **Gemini CLI:** `gemini extensions install https://github.com/lovisdotio/motion2code`.
  54. - **Hermes:** copy it to `~/.hermes/skills/`.
  55. **claude.ai:** zip `skills/motion2code` and upload it under Settings > Capabilities > Skills.
  56. **ChatGPT, Gemini Gems and other chat tools:** see [`adapters/`](adapters/).
  57. The scripts need Python 3.9+, ffmpeg, and Playwright for the ones that open a browser
  58. (`uv run --with playwright python ...`, or `pip install playwright && python -m playwright install chromium`).
  59. ## Use
  60. Ask naturally: *"Rebuild clip.mp4 as an SVG + GSAP animation that loops"*, or *"turn this app screen recording into
  61. a real site"*. For a full brief, fill in [`prompts/convert-video-prompt.md`](prompts/convert-video-prompt.md).
  62. The agent studies the video, builds the page, then checks it:
  63. ```bash
  64. python3 scripts/study_video.py clip.mp4 -o study/
  65. python3 scripts/frame_diff.py clip.mp4 index.html -o diff/
  66. python3 scripts/check_anim.py index.html --runtime
  67. python3 scripts/render_anim.py index.html -o anim.mp4
  68. python3 scripts/side_by_side.py clip.mp4 anim.mp4 -o side_by_side.mp4 --html index.html
  69. ```
  70. What the scripts do:
  71. - `study_video.py` saves frames every 0.25 s (named by time), the frames before and after each detected cut, a
  72. contact sheet, the palette and a loop score of the source in `study.json`.
  73. - `palette.py` prints the exact flat colors of a video or image as hex with their share of the frame.
  74. - `frame_diff.py` writes source | code image pairs at the given times (or every frame of a range), a sheet of all
  75. pairs, and a difference score per time with the worst five.
  76. - `check_anim.py` checks the page contract, the script allowlist and the absence of embedded raster or video; with
  77. `--runtime` it also opens the page headless and checks console errors, network requests, the loop seam, that
  78. `seek` is deterministic, and that the page autoplays.
  79. - `render_anim.py` renders the page frame by frame through `anim.seek` to an mp4, a GIF poster or PNG frames,
  80. at any `--size`.
  81. - `side_by_side.py` stacks the source and the render into one labelled proof video (landscape or portrait).
  82. To view a gallery entry with its comparison, serve the folder (`python3 -m http.server -d gallery/eye`) and open
  83. `http://127.0.0.1:8000/compare.html`.
  84. ## The page contract
  85. ```js
  86. window.anim = { tl, duration, seek(t), play(from), pause() } // seek(t) is a pure function of t
  87. ```
  88. - `index.html?t=6.5` freezes at 6.5 s, `?external=1` waits to be driven, no parameter plays and loops.
  89. - `<html data-ready="1">` once fonts are loaded and the first frame is drawn.
  90. - Self-contained: inline SVG, GSAP 3 from cdnjs, flubber from jsdelivr only for morphs, Google Fonts. Nothing else.
  91. ## Hard rules
  92. - Use only the given source video: never regenerate it, never embed it, never trace its frames.
  93. - Text exactly as in the source prompt, even when the video misspells it.
  94. - Flat shapes as SVG, colors sampled from the source.
  95. - The GSAP timeline is the single clock.
  96. - The loop is done in code: frame(duration) equals frame(0).
  97. - Every moment is checked against the source, side by side.
  98. ## Repository
  99. ```text
  100. skills/motion2code/ the skill: SKILL.md, references/, scripts/, templates/
  101. gallery/ six rebuilt clips: index.html, compare.html, source.mp4 (480p), poster.gif, site.html
  102. prompts/ fill-in conversion prompt and advice for source prompts
  103. adapters/ prompts for tools without skill support
  104. tests/ repository checks (every gallery page and template)
  105. .claude-plugin/ Claude Code plugin + marketplace manifests
  106. ```
  107. Contributing: see [AGENTS.md](AGENTS.md) for the rules every change must pass.
  108. ## License
  109. MIT, Lovis Odin. The gallery source clips were generated with MiniMax H3 Max on fal and are included at 480p for
  110. comparison only.

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.