transitions-dev

Implements twelve production-ready CSS transitions for common web UI state changes.

3|Updated Apr 20, 2026
One-click install
npx skills add https://github.com/langgenius/due-date-hq-jwl --skill transitions-dev-langgenius
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: transitions-dev
Source: https://github.com/langgenius/due-date-hq-jwl/tree/main/.claude/skills/transitions-dev
Command: npx skills add https://github.com/langgenius/due-date-hq-jwl --skill transitions-dev-langgenius

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Hand-tuning CSS transitions for common UI moments (dropdowns, modals, badges, error shakes) is repetitive and error-prone, and ad-hoc snippets often break accessibility or replay incorrectly. This Skill provides twelve tested, drop-in CSS transition patterns with semantic custom properties and built-in reduced-motion guards. ## Core Features & Use Cases - Twelve ready-made transitions: card resize, number pop-in, notification badge, text swap, dropdown, modal, panel reveal, page slide, icon swap, success check, avatar group hover, and error state shake. - Semantic design tokens: a single :root block of CSS custom properties controls every duration, easing, distance, and blur across all transitions. - Accessibility built in: every snippet ships a prefers-reduced-motion guard, and JS orchestration snippets handle reflow-based replay and close-state cleanup. - Use Case: A user asks to "make the modal open smoothly" — the Skill matches the request to the modal pattern, pastes the tuned CSS verbatim, wires the .is-open / .is-closing state classes, and keeps the diff minimal. ## Quick Start Ask the assistant to add a smooth open and close transition to your dropdown menu using the transitions-dev patterns.

Frequently Asked Questions about transitions-dev

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add a smooth open and close transition to a dropdown menu?

Use the menu dropdown pattern: apply the .t-dropdown class with a data-origin attribute, toggle .is-open to show, and swap to .is-closing on close with a setTimeout cleanup matching --dropdown-close-dur. The CSS scales the menu from its trigger origin with opacity fade.

How do I animate a modal dialog opening in CSS?

Apply the .t-modal class and toggle .is-open to scale the dialog from --modal-scale (0.96) up to full size with opacity fade. On close, swap to .is-closing and remove it after --modal-close-dur so the next open starts from the resting state.

Do these CSS transitions support prefers-reduced-motion?

Yes, every snippet includes a required @media (prefers-reduced-motion: reduce) block that disables animations and transitions for users who request less motion at the OS level. Removing this guard causes accessibility audit failures.

Why does my CSS animation not replay when I re-add the class?

Browsers skip re-running an animation if the class is removed and re-added in the same frame. Force a reflow between the two operations with void el.offsetWidth, which the text swap, number pop-in, success check, and error shake snippets all demonstrate.

Can I use these transitions with React or other frameworks?

Yes, the patterns are framework-agnostic CSS with small vanilla JS orchestration snippets. The avatar group hover reference includes a React component example, and other patterns adapt by toggling the documented classes and data attributes from your framework's state.

How do I make the SVG checkmark stroke draw correctly?

Replace the placeholder stroke-dasharray value of 20 with your path's actual length measured via path.getTotalLength(), rounded up by 1 pixel. A wrong value causes the stroke to pre-reveal or over-draw before the animation completes.