Fullstack · Motion Design

型紙

Katagami · Template

A fullstack masterclass on motion design. From the 12 principles to springs, scroll choreography, GPU-accelerated transforms, and production-grade React orchestration.

Scroll to begin
AI
編集

Auto-Editor Agent

A self-improving motion-ad agent. It researches current trends, analyzes your media, drafts a plan, critiques itself, and refines — all visible live below.

Drop image or video
or click to browse
Enhanced Ad
20 slides × 3 kfs = 60 keyframes
420 (default)30
1 (simple)3 (rich)6 (max)
~0.30s per slide~0.10s per keyframe
Forwarded to Cháoxiào and played in sync with the timeline preview.
KATAGAMI · MOTION AD AGENT
Researches · plans · critiques · refines
Drop media, set a vibe, hit Auto-Edit. The agent's thoughts will stream here.
00

Why Motion Matters

Motion is communication. It tells the user where things came from, where they're going, and how the system feels under their fingers.

Bad motion is jarring, slow, or distracts. Good motion is invisible until you remove it. Great motion makes the product feel alive.

This guide is a complete tour of the craft — from physical intuition to code patterns to performance budgets.

01
原則

The 12 Principles of Animation

Disney's foundational rules from The Illusion of Life. They predate the web by 80 years yet still govern every great UI motion today.

🫨
Squash & Stretch
Convey weight and elasticity through controlled deformation.
👀
Anticipation
Tiny pre-action that prepares the user for the main move.
🎬
Staging
Frame attention. One hero per moment.
📐
Straight-ahead vs Pose-to-Pose
Spontaneous flow vs planned keyframes.
🌊
Follow-through & Overlap
Different parts settle at different times.
🌀
Slow In / Slow Out
Real things accelerate and decelerate. Linear is robotic.
🏹
Arcs
Natural movement curves. Straight lines feel mechanical.
Secondary Action
Supporting motion that enriches the primary.
⏱️
Timing
Speed = mass + emotion. 200ms cheerful, 600ms heavy.
💥
Exaggeration
Push beyond literal reality to communicate clearly.
🧊
Solid Drawing
Maintain weight and volume across frames.
💎
Appeal
Make it feel good. Charm matters.
02
緩急

Easing Lab

Easing is the soul of motion. A bezier curve dictates how a value moves between two points — and changes everything emotionally.

linear
Robotic, avoid for most UI
easeIn
Slow start — exit animations
easeOut
Fast start — entrance, default for UI
easeInOut
Symmetric — for in-place transforms
circOut
Aggressive deceleration
expo
Modern designer's favorite
back
Overshoots — playful bounce
Rule of thumb

Use easeOut for things appearing (snappy entry), easeIn for things leaving, and easeInOut for in-place changes. [0.22, 1, 0.36, 1] is the gold-standard "smooth confident" curve.

03

Timing & Rhythm — 間 (Ma)

Japanese has a word for the space between: 間 (ma). It's the negative space of time — the silence that lets the music breathe.

100ms
Tap feedback
200ms
Hover, micro
300ms
Standard UI
500ms
Page transitions
800ms
Hero / cinematic
Material Design

Standard: 200–300ms · Complex: 375ms · Large surface: 500ms

Apple HIG

UIView default 0.25s · Spring response 0.5s · Damping 1.0

04
弾性

Spring Physics

Springs simulate real-world physics. Instead of fixed durations, you define stiffness, damping, and mass — the system finds its own time.

200
Higher = snappier
20
Lower = more bounce
1
Higher = sluggish
# Framer Motion
transition={{ type: "spring", stiffness: 200, damping: 20, mass: 1 }}
05
編成

Orchestration · Stagger & Choreography

Animating one element is easy. Animating ten in sequence so the eye flows naturally — that's choreography. The key is stagger.

1
2
3
4
5
6
# Stagger pattern
{items.map((it, i) => (
  <motion.div
    key={it.id}
    initial={{ opacity: 0, y: 40 }}
    animate={{ opacity: 1, y: 0 }}
    transition={{ delay: i * 0.08 }}
  />
))}
06
巻物

Scroll-Driven Motion

Tying motion to the scrollbar transforms a page into a film. useScroll + useTransform map scroll progress to any value.

SCROLL
const { scrollYProgress } = useScroll({ target: ref });
const x = useTransform(scrollYProgress, [0, 1], ["-50%", "50%"]);
const scale = useTransform(scrollYProgress, [0, 0.5, 1], [0.6, 1.2, 0.6]);
07
転換

Page Transitions

AnimatePresence lets you animate components as they leave the tree — the secret to elegant page transitions.

ONE
08

Code Patterns

The four patterns you'll use 90% of the time. Learn these by heart.

Variants — Reusable motion vocabulary
const fade = {
  hidden: { opacity: 0, y: 20 },
  show:   { opacity: 1, y: 0, transition: { duration: 0.4 } }
};
<motion.div variants={fade} initial="hidden" animate="show" />
Layout animations — FLIP for free
<motion.div layout transition={{ type: "spring", stiffness: 300 }}>
  {/* re-renders that change size/position auto-animate */}
</motion.div>
Gestures — drag, hover, tap
<motion.button
  whileHover={{ scale: 1.05 }}
  whileTap={{ scale: 0.95 }}
  drag dragConstraints={{ left: 0, right: 200 }}
/>
Exit animations
<AnimatePresence>
  {open && (
    <motion.div
      initial={{ opacity: 0 }}
      animate={{ opacity: 1 }}
      exit={{ opacity: 0 }}
    />
  )}
</AnimatePresence>
09

Performance Budget

60fps means each frame has 16.67ms. After React, paint, and composite, you have ~6ms of motion budget per frame. Every CSS property you touch matters.

Animate only transform & opacity
These are GPU-composited. width/height/top/left trigger layout = jank.
Use will-change sparingly
Promotes to its own layer, but too many = memory pressure. Add only when actively animating.
Prefer transform: translate3d()
Hints the GPU. Framer Motion does this automatically.
Avoid animating box-shadow
Repaints every frame. Animate a separate shadow layer's opacity instead.
Throttle scroll handlers
Use requestAnimationFrame or useScroll hooks — not raw scroll events.
Respect prefers-reduced-motion
Some users get sick. Always honor the OS-level setting.
10
全層

The Full Stack of Motion

Motion isn't one library — it's a stack. From the GPU compositor up to LLM-generated keyframes. Master each layer and you can ship anything.

Browser
Compositor, GPU, requestAnimationFrame
CSS
transitions, @keyframes, will-change, transform-3d
Web APIs
Web Animations API, IntersectionObserver, ResizeObserver
React
useEffect, refs, render scheduling, AnimatePresence
Framer Motion
motion.* components, variants, layout, gestures, useScroll
Three.js / R3F
WebGL — 3D scenes, shaders, post-processing
Lottie / SVG
Vector animations from After Effects
Backend (LLM)
Generate motion presets, narrate scenes, drive timeline keyframes
Now go animate something.
The pattern is cut. The cloth is yours.
型紙 · Katagami · The pattern from which all motion is cut
Kaspa runs at 10 BPS — live! 🔷