affaan-m avatar

Motion Patterns

A focused set of copy-paste animation patterns built on Framer Motion and motion-foundations tokens. It covers the usual suspects: buttons, modals, toasts, staggered lists, page transitions for Next.js App Router, and scroll reveals. The core contract is strict: every conditional render must be wrapped in AnimatePresence with a key, every entrance needs an exit, and all timing values are imported from motion-foundations rather than hardcoded. The stagger interval is capped between 0.05s and 0.10s, modals ship with accessibility requirements baked in, and layout animations are forbidden on large subtrees. It's opinionated but disciplined, which is exactly what you want when you're reaching for animation boilerplate at 11pm.

skills.sh installs
5.7K
GitHub stars
300.3K
last updated
Aug 21, 2026

Install

$ npx -y skills add affaan-m/ecc --skill motion-patterns --agent claude-code

Installs into .claude/skills of the current project.

Files

Motion Patterns

Copy-paste patterns for the most common UI animation needs. Every pattern here is built on motion-foundations tokens and springs. Do not define new duration or easing values here — import them.

When to Activate

  • Animating a button, card, modal, or toast notification
  • Building list entrances with stagger
  • Setting up page transitions in Next.js App Router
  • Adding entrance or exit animations to conditional content
  • Implementing scroll-reveal, scroll-linked progress, or sticky story sections
  • Building expanding cards, accordions, or shared-element transitions

Outputs

This skill produces:

  • Accessible, SSR-safe animation for all standard UI components
  • AnimatePresence-wrapped conditional renders with correct exit behavior
  • Page transition wrapper component for Next.js App Router
  • Scroll-reveal and scroll-linked patterns using useScroll + useTransform
  • Layout animation patterns (layout, layoutId) for expanding and crossfading elements

Principles

Sponsors

Details

Repository
github.com/affaan-m/ecc
Categories
Frontend Development, Design & UI/UX
First seen
Jul 14, 2026

More from affaan-m/ecc

All 263
1forcedotcom avatardesign-systems-slds2-migrateforcedotcom/sf-skillsMigrate Lightning Web Components from SLDS 1 to SLDS 2 by running the SLDS linter and fixing violations. Use this skill whenever users mention SLDS 2, SLDS upli5.7Kskills.sh installs
2affaan-m avatarmotion-foundationsaffaan-m/eccMotion tokens, spring presets, performance rules, device adaptation, accessibility enforcement, and SSR safety for React / Next.js using motion/react. Foundatio5.7Kskills.sh installs
3affaan-m avatardocumentation-lookupaffaan-m/eccUse up-to-date library and framework docs via Context7 MCP instead of training data. Activates for setup questions, API references, code examples, or when the u5.7Kskills.sh installs
4affaan-m avatarmotion-advancedaffaan-m/eccAdvanced motion patterns for React / Next.js — drag & drop, gestures, text animations, SVG path drawing, custom hooks, imperative sequences (useAnimate), loader5.6Kskills.sh installs
5tanstack-skills avatartanstack-tabletanstack-skills/tanstack-skillsHeadless UI for building powerful tables & datagrids for TS/JS, React, Vue, Solid, Svelte, Qwik, Angular, and Lit.5.6Kskills.sh installs
6github avatarweb-codergithub/awesome-copilotExpert 10x engineer with comprehensive knowledge of web development, internet protocols, and web standards. Use when working with HTML, CSS, JavaScript, web API5.5Kskills.sh installs