Motion System logo

Motion System

Organization
staple-lab
motion-system

Use when adding animation to a design system or choosing between Motion (motion.dev), GSAP and CSS - motion tokens, enter/exit transitions, layout animation, scroll choreography, reduced-motion handling, and performance. Triggers on "animation", "transition", "motion", "framer motion", "gsap", "prefers-reduced-motion".

Overview

Publisherstaple-lab
Repositorydesign-system-skills
Skill namemotion-system
Stars
7
Forks
0
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by staple-lab on GitHub. Read the source before you install it.

Installation

Install the Motion System AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/staple-lab/design-system-skills/tree/main/plugins/design-system/skills/motion-system
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/staple-lab/design-system-skills.git /tmp/design-system-skills
mkdir -p .claude/skills
cp -r /tmp/design-system-skills/plugins/design-system/skills/motion-system .claude/skills/motion-system
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Motion System in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Motion System on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Motion System is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Motion system

Motion in a design system is not decoration — it is feedback. It tells the user that something responded, where a thing came from, and where it went. Judge every animation by whether removing it would make the interface harder to understand. If not, it is probably noise.

Motion values are tokens

Durations and easings live in tokens/primitive.tokens.json and reach components as var(--ds-duration-normal) / var(--ds-easing-emphasized) like every other value. A hardcoded 0.3s ease-in-out is the same defect as a hardcoded #3b82f6.

duration.instant  50ms    ·  fast 150ms  ·  normal 250ms  ·  slow 400ms  ·  slower 600ms
easing.standard  cubic-bezier(0.2, 0, 0, 1)
easing.emphasized cubic-bezier(0.05, 0.7, 0.1, 1)
easing.decelerate cubic-bezier(0, 0, 0, 1)      entering
easing.accelerate cubic-bezier(0.3, 0, 1, 1)    leaving

Two principles the numbers encode:

  • Exits are faster than entrances (~0.8×). A user who dismissed something has already moved on; making them wait for the goodbye is the most common reason an interface feels sluggish.
  • Distance scales duration. A tooltip appearing 4px away and a full-screen drawer should not share a duration. Small = fast.

Never ease-in-out for UI. It starts and ends slowly, which reads as hesitant. Enter with decelerate (fast start, gentle stop — it feels like it arrived), leave with accelerate (gentle start, fast exit — it feels like it left).

Reduced motion — do this once, at the system level

prefers-reduced-motion is not optional and not per-component. For a meaningful number of users, parallax and large transforms cause actual nausea; for many more it is a preference they set deliberately.

css
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

The blunt global rule is the right default because it cannot be forgotten. 0.01ms, not 0 — a duration of zero prevents animationend/transitionend from firing, and any component that unmounts on that event will hang open forever.

Then reduce thoughtfully where it matters: keep opacity fades (they rarely trigger symptoms), drop movement and scale. "Reduced" means less motion, not no feedback — a state change with zero indication is its own usability problem.

tsx
const shouldReduceMotion = useReducedMotion();   // Motion's hook
<motion.div
  initial={shouldReduceMotion ? { opacity: 0 } : { opacity: 0, y: 8 }}
  animate={{ opacity: 1, y: 0 }}
/>

What animates, and how

InteractionTechniqueDuration
Hover / press / focusCSS transitionfast
Dropdown, tooltip, popoverCSS keyframes on [data-state]normal
Dialog, drawer, sheetCSS or Motion (needs exit)slow in, normal out
Accordion, disclosureCSS grid 1fr/0fr or interpolate-sizenormal
List add / remove / reorderMotion AnimatePresence + layoutnormal
Item moving between containersMotion layoutIdnormal
Scroll choreography, pinningGSAP ScrollTriggern/a
Page transitionView Transitions API, or Motionslow

Reach for CSS first. It runs on the compositor, needs no client boundary in RSC, and cannot be broken by a state bug. Escalate to JS only for the three things CSS genuinely cannot do: exit animations on unmount, layout animations (FLIP), and interruptible spring physics.

Enter/exit from data-state — no JS at all

css
.content[data-state='open']   { animation: enter var(--ds-duration-normal) var(--ds-easing-decelerate); }
.content[data-state='closed'] { animation: exit  var(--ds-duration-fast)   var(--ds-easing-accelerate); }
.content[data-side='top']     { transform-origin: bottom center; }

@keyframes enter { from { opacity: 0; transform: scale(0.96) translateY(-4px); } }
@keyframes exit  { to   { opacity: 0; transform: scale(0.96); } }

Radix and Base UI both keep the element mounted through the exit animation, so this works without AnimatePresence. The transform-origin line is what makes a popover appear to grow out of its trigger — a large perceived-quality difference for two lines.

Motion (motion/react)

tsx
import { motion, AnimatePresence } from 'motion/react';

<AnimatePresence>
  {items.map((item) => (
    <motion.li key={item.id} layout
      initial={{ opacity: 0, y: 8 }}
      animate={{ opacity: 1, y: 0 }}
      exit={{ opacity: 0, x: -8 }}
      transition={{ duration: 0.25, ease: [0.2, 0, 0, 1] }}
    />
  ))}
</AnimatePresence>

layout is the standout feature — FLIP animation of position and size changes for free, including across containers with layoutId. Doing it by hand is genuinely hard. Note motion components need "use client" in an RSC app.

Feed Motion the token values, not new magic numbers. Export them once:

ts
import { resolved } from '@/tokens/dist/tokens';
export const transitions = {
  fast:   { duration: 0.15, ease: [0.2, 0, 0, 1] },
  normal: { duration: 0.25, ease: [0.2, 0, 0, 1] },
  spring: { type: 'spring', stiffness: 400, damping: 30 },
} as const;

GSAP

For choreography and scroll. Inside React, always useGSAP — it scopes the animations and handles cleanup, and without it Strict Mode's double-invoke leaves duplicate tweens running.

tsx
import { useGSAP } from '@gsap/react';
useGSAP(() => {
  gsap.timeline({ scrollTrigger: { trigger: ref.current, start: 'top 80%', scrub: 1 } })
      .from('.card', { y: 40, opacity: 0, stagger: 0.08 });
}, { scope: ref });

Keep GSAP out of the component library itself. It belongs in the product's set-pieces; a design system component that depends on ScrollTrigger has coupled every consumer to a scroll library.

Performance

  • Animate transform and opacity only. They run on the compositor. Animating width, height, top, left, margin or box-shadow triggers layout or paint on every frame and drops the animation to the main thread.
  • Height is the common exception people need. Use grid-template-rows: 0fr → 1fr, or interpolate-size: allow-keywords with height: auto where support allows — both beat measuring in JS.
  • will-change is a last resort, applied just before the animation and removed after. Left on permanently it costs memory on every element that has it.
  • Animating box-shadow is expensive; animate the opacity of a pseudo-element that holds the shadow instead.
  • Budget: 60fps means 16ms per frame. If a list of 200 rows animates on mount, it will not hold — stagger a visible subset and let the rest appear.

Rules

  1. Motion values are tokens. No inline durations.
  2. prefers-reduced-motion handled globally, refined locally.
  3. CSS first; JS only for exit, layout and springs.
  4. Nothing above 400ms unless the user asked for it.
  5. Never animate something the user is trying to read or click. A moving target is a usability bug regardless of how good it looks.
  6. Never block input on an animation. The next click must land during the transition.
  7. Animation is state feedback, not entertainment — the second time a user sees it, only the information survives.

Frequently asked questions

What does the Motion System AI skill do?

Use when adding animation to a design system or choosing between Motion (motion.dev), GSAP and CSS - motion tokens, enter/exit transitions, layout animation, scroll choreography, reduced-motion handling, and performance. Triggers on "animation", "transition", "motion", "framer motion", "gsap", "prefers-reduced-motion".

Why use Motion System on TypingMind?

Because you install it once and use it with any model. Motion System is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Motion System in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/staple-lab/design-system-skills/tree/main/plugins/design-system/skills/motion-system. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Motion System?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Motion System?

As many as you like. As long as a model supports skills, you can use Motion System with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Motion System AI skill free?

Yes. It is published on GitHub by staple-lab under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇