agentleFS
ryankoleanryankolean/summit-claude-skills/skills/web-motion/SKILL.md

web-motion

Skill4 starsChanged 7 months agoMITView on GitHub

Use when building or reworking a website and adding motion: smooth scroll, scroll-triggered reveals, hero or text animations, animated backgrounds, cursor effects, hover and micro interactions, page transitions, or when asked for animation ideas. Covers GSAP (gsap.com), Lenis (lenis.dev) and React Bits (reactbits.dev). Triggers on "add motion", "animate this site", "make it feel premium", "smooth scrolling", "scroll animations", "ScrollTrigger", "Lenis", "React Bits", "animated background", "motion ideas".

  • Installs packages

3 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

2 rules. About 0 are common, 0 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    React / Next / Vite+React / Astro with React islands: all three. React Bits for drop-in pieces, GSAP via useGSAP for custom choreography, …

    line 39
  2. Very specific:

    One loop: When GSAP is present, drive Lenis from gsap.ticker with autoRaf: false and gsap.ticker.lagSmoothing(0).

    line 48

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Web Motion

Three sources, three jobs. Pick the right one per effect, wire them through one animation loop, and ship every effect with a reduced-motion fallback.

SourceJobWhere the detail lives
GSAP (gsap.com)Animation engine: tweens, timelines, ScrollTrigger, SplitText, Flip, DrawSVG, MorphSVG. 100% free incl. all plugins, commercial OK.Official plugin skills: gsap-skills:gsap-core, gsap-react, gsap-scrolltrigger, gsap-timeline, gsap-plugins, gsap-performance, gsap-frameworks, gsap-utils. Load the one that fits.
Lenis (lenis.dev)Smooth scroll on top of native scroll. Feeds ScrollTrigger.lenis.md
React Bits (reactbits.dev)200+ copy-in React components: text animations, animations, UI components, micro interactions, backgrounds. Source lands in the repo, not node_modules.react-bits.md

Any request for ideas, a motion plan, or "what should move": use motion-ideas.md and return its plan table (includes cost and reduced-motion fallback per row).

Live sources (catalogs change weekly; check before naming a component or API)

curl -sL https://reactbits.dev/llms.txt   # full free catalog with CLI names
curl -sL https://gsap.com/llms.txt        # GSAP docs index
curl -sL https://raw.githubusercontent.com/darkroomengineering/lenis/main/README.md

Inspiration: https://gsap.com/showcase/, https://gsap.com/demos/, https://www.lenis.dev/showcase, reactbits.dev category pages (live previews with prop controls).

Stack decision

  • React / Next / Vite+React / Astro with React islands: all three. React Bits for drop-in pieces, GSAP via useGSAP for custom choreography, Lenis via lenis/react.
  • Static HTML or no-build site: GSAP + Lenis from CDN. React Bits does not apply; rebuild the effect with GSAP using the React Bits source as a reference. Vue and Svelte have official ports (vue-bits.dev, sveltebits.xyz).
  • Smooth scroll: Lenis or GSAP ScrollSmoother, never both.

Integration rules

  1. One loop. When GSAP is present, drive Lenis from gsap.ticker with autoRaf: false and gsap.ticker.lagSmoothing(0). Never also set autoRaf: true (double-steps the scroll).
  2. Sync ScrollTrigger: lenis.on('scroll', ScrollTrigger.update) (React: useLenis(ScrollTrigger.update)).
  3. Cleanup removes the same function reference you added. gsap.ticker.remove(lenis.raf) does nothing if you added an arrow wrapper; store the wrapper. React StrictMode mounts twice, so a leaked ticker callback means two loops.
  4. Import lenis/dist/lenis.css and do not set scroll-behavior: smooth on html.
  5. React Bits installs need the variant suffix: https://reactbits.dev/r/<Name>-<JS|TS>-<CSS|TW>. A bare /r/TextType 404s.
  6. Check React Bits dependencies first (gsap, motion, three, ogl, matter-js...). Two motion engines (GSAP + Motion) in one bundle is a cost; prefer components that share the engine you already ship.
  7. Reduced motion: Lenis honors prefers-reduced-motion by default. Wrap GSAP work in gsap.matchMedia() with (prefers-reduced-motion: no-preference). React Bits components mostly do not check it: gate them yourself and render a static fallback.
  8. Content is visible without JS. Reveals animate opacity/transform from a state set by JS (gsap.from, autoAlpha), never from CSS that hides content before JS runs.
  9. Performance budget: one WebGL background per page, paused offscreen, static image fallback on mobile or low-power. Animate transform/opacity only. Use fixing-motion-performance for jank.

Verify

  • Build passes; console has no errors at 375 / 768 / 1280.
  • Scroll the whole page: ScrollTrigger markers line up with Lenis on (markers: true while testing).
  • Emulate prefers-reduced-motion: reduce (DevTools Rendering panel, or Playwright reducedMotion: 'reduce'): no smoothing, no entrance motion, all content visible.
  • Anchor links and keyboard scroll (Space, PageDown, Tab) still work; modals and nested scrollers scroll (data-lenis-prevent).
  • Hidden preview tabs stall requestAnimationFrame and IntersectionObserver; take a screenshot to force frames before judging an animation broken.

Common mistakes

MistakeFix
npx shadcn add https://reactbits.dev/r/AuroraAdd the variant: Aurora-TS-TW
shadcn add in a repo with no components.jsonnpx shadcn@latest init first, or use jsrepo, or copy source manually
Lenis + ScrollSmoother togetherPick one
@studio-freight/lenis or @studio-freight/react-lenisRenamed: lenis and lenis/react
Telling the user GSAP plugins need Club GreenSockAll plugins are free since 3.13 (npm i gsap)
Effect on every sectionOne signature moment, a few supporting reveals, micro interactions on controls

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.