
Motion Framer
Implement React UI motion—gestures, layout transitions, and exit animations—with Motion (Framer Motion) patterns your agent can apply directly.
Overview
Motion-Framer is an agent skill for the Build phase that helps you add Motion and Framer Motion animations—gestures, layout transitions, and exit effects—to React and JavaScript UI.
Install
npx skills add https://github.com/freshtechbro/claudedesignskills --skill motion-framerWhat is this skill?
- Declarative motion components with variants and spring physics
- Gestures: hover, tap, drag, and focus-driven micro-interactions
- AnimatePresence for mount/unmount exit animations
- Layout animations for resize, reorder, and shared-element-style transitions
- Scroll-linked and parallax-style effects for marketing and app chrome
- Supports Motion v11+ and Framer Motion lineage
- Documented gesture set includes hover, tap, drag, and focus
Adoption & trust: 949 installs on skills.sh; 227 GitHub stars; 3/3 security scanners passed (skills.sh audits).
What problem does it solve?
Your UI feels static or your CSS transitions cannot handle layout changes, drag gestures, or coordinated enter/exit sequences.
Who is it for?
Solo builders shipping React 18+ interfaces who want hover/tap/drag feedback, route transitions, or list reorder animations without a dedicated motion designer.
Skip if: Non-React stacks with no Motion dependency, performance-critical pages where animation is disabled by policy, or purely static document sites with no interactive components.
When should I use this skill?
Building interactive UI components, micro-interactions, page transitions, layout animations, drag-and-drop, or scroll-based effects with Motion or Framer Motion.
What do I get? / Deliverables
You get declarative motion components and patterns for interactive, performant animations you can drop into React screens and refine with variants and springs.
- Motion-wrapped components with variants and transitions
- Gesture and layout animation implementations
- Exit and sequence patterns using AnimatePresence where needed
Recommended Skills
Journey fit
Build/frontend is the canonical shelf because the skill teaches interactive UI animation implementation in React and JavaScript. Motion components, variants, and AnimatePresence are applied while composing product UI, not during ops or growth tooling.
How it compares
Use Motion components for orchestrated React state and layout animation instead of only CSS transition utilities.
Common Questions / FAQ
Who is motion-framer for?
Indie developers and designers shipping React or JS frontends who need credible motion for components, pages, and marketing UI.
When should I use motion-framer?
In Build/frontend when adding micro-interactions, AnimatePresence exits, layout animations, drag UIs, or scroll-driven effects to components you are actively coding.
Is motion-framer safe to install?
Check the Security Audits panel on this Prism page; the skill is documentation and patterns—review third-party Motion package versions in your own lockfile.
SKILL.md
READMESKILL.md - Motion Framer
# Motion & Framer Motion ## Overview Motion (formerly Framer Motion) is a production-ready animation library for React and JavaScript that enables declarative, performant animations with minimal code. It provides `motion` components that wrap HTML elements with animation superpowers, supports gesture recognition (hover, tap, drag, focus), and includes advanced features like layout animations, exit animations, and spring physics. **When to use this skill:** - Building interactive UI components (buttons, cards, menus) - Creating micro-interactions and hover effects - Implementing page transitions and route animations - Adding scroll-based animations and parallax effects - Animating layout changes (resizing, reordering, shared element transitions) - Drag-and-drop interfaces - Complex animation sequences and state-based animations - Replacing CSS transitions with more powerful, controllable animations **Technology:** - **Motion** (v11+) - The modern, smaller library from Framer Motion creators - **Framer Motion** - The full-featured predecessor (still widely used) - React 18+ compatible, also supports Vue - Supports TypeScript - Works with Next.js, Vite, Remix, and all modern React frameworks ## Core Concepts ### 1. Motion Components Convert any HTML/SVG element into an animatable component by prefixing with `motion.`: ```jsx import { motion } from "framer-motion" // Regular HTML becomes motion component <motion.div /> <motion.button /> <motion.svg /> <motion.path /> ``` Every motion component accepts animation props like `animate`, `initial`, `transition`, and gesture props like `whileHover`, `whileTap`, etc. ### 2. Animate Prop The `animate` prop defines the target animation state. When values change, Motion automatically animates to them: ```jsx // Simple animation - x position changes <motion.div animate={{ x: 100 }} /> // Multiple properties <motion.div animate={{ x: 100, opacity: 1, scale: 1.2 }} /> // Animates when state changes const [isOpen, setIsOpen] = useState(false) <motion.div animate={{ width: isOpen ? 300 : 100 }} /> ``` ### 3. Initial State Set the initial state before animation using the `initial` prop: ```jsx <motion.div initial={{ opacity: 0, y: 50 }} animate={{ opacity: 1, y: 0 }} /> ``` Set `initial={false}` to disable initial animations on mount. ### 4. Transitions Control how animations move between states using the `transition` prop: ```jsx // Duration-based <motion.div animate={{ x: 100 }} transition={{ duration: 0.5, ease: "easeInOut" }} /> // Spring physics <motion.div animate={{ scale: 1.2 }} transition={{ type: "spring", stiffness: 300, damping: 20 }} /> // Different transitions for different properties <motion.div animate={{ x: 100, opacity: 1 }} transition={{ x: { type: "spring", stiffness: 300 }, opacity: { duration: 0.2 } }} /> ``` **Transition types:** - `"tween"` (default) - Duration-based with easing - `"spring"` - Physics-based spring animation - `"inertia"` - Decelerating animation (used in drag) ### 5. Variants Organize animation states using named variants for cleaner code and propagation to children: ```jsx const variants = { hidden: { opacity: 0, y: 20 }, visible: { opacity: 1, y: 0 }, exit: { opacity: 0, scale: 0.9 } } <motion.div variants={variants} initial="hidden" animate="visible" exit="exit" /> ``` **Variant propagation** - Children automatically inherit parent variant states: ```jsx const containerVariants = { hidden: { opacity: 0 }, visible: { opacity: 1, transition: { staggerChildren: 0.1 // S