Loading source
Pulling the file list, source metadata, and syntax-aware rendering for this listing.
Source from repo
Living wiki of UI design patterns and best practices built with Fumadocs, Next.js, and Base UI components.
Files
Skill
Size
Entrypoint
Format
Open file
Syntax-highlighted preview of this file as included in the skill package.
rules/morphing-spring-rotation.md
1---2title: Spring Physics for Rotation3impact: MEDIUM4tags: morphing, spring, rotation5---67## Spring Physics for Rotation89Rotation between grouped icons should use spring physics for natural motion.1011**Incorrect (duration-based rotation):**1213```tsx14<motion.g animate={{ rotate: rotation }} transition={{ duration: 0.3 }} />15```1617**Correct (spring rotation):**1819```tsx20const rotation = useSpring(definition.rotation ?? 0, activeTransition);2122<motion.g style={{ rotate: rotation, transformOrigin: "center" }} />23```24