Exit Animations

dylantarre/animation-principles/skills/05-by-animation-type/exit-animations

by dylantarre83597134ba8fNo license99 starsListed Oct 8, 2026Updated Oct 8, 2026Repository updated 9 months ago

Use when elements need to leave the screen - closing modals, dismissing notifications, removing items, page transitions out, or any "leaving view" animation.

Instructions onlyDesign & Creative
AI-generated overview

Guides exit animations for UI elements using Disney's 12 animation principles, with timings, easing and CSS patterns.

What it does
This skill provides guidance for animating elements that leave the screen, such as closing modals, dismissing notifications, removing list items and page transitions out. It maps Disney's 12 animation principles onto exit behaviour and gives duration, easing and trajectory recommendations per element type. It also includes a CSS keyframe implementation pattern and a collapse pattern for removed list items.
When to use it
Use it when a UI element needs an exit or dismissal animation and you want principled timing, easing and motion choices. It suits modals, toasts, tooltips, dropdowns, deleted items and page transitions out.
Requirements
No tools, packages or credentials; it is instructions only and ships no scripts. The CSS examples assume a web front end.

Exit Animations

Apply Disney's 12 principles when removing elements from view.

Principle Application

Squash & Stretch: Scale down to 95-98% on exit. Element compresses slightly as it departs.

Anticipation: Brief pause or micro-movement before departure. A 50ms hesitation acknowledges the exit.

Staging: Exit toward logical destinations. Deleted items fall down, dismissed modals shrink to origin, sidebars return to their edge.

Straight Ahead vs Pose-to-Pose: Pose-to-pose with clear visible→invisible states. Plan the exit trajectory.

Follow Through & Overlapping: Content exits before container. Text fades 50ms before the card collapses.

Slow In/Slow Out: Use ease-in for exits. Gentle start, accelerating departure: cubic-bezier(0.4, 0, 1, 1).

Arcs: Exit on curves, not straight lines. Dismissed notifications arc upward-and-out.

Secondary Action: Combine opacity fade with directional movement. Pure fades feel like errors.

Timing:

  • Exits should be 20-30% faster than entrances
  • Quick exits: 100-150ms (tooltips, dropdowns)
  • Standard exits: 150-200ms (modals, toasts)
  • Graceful exits: 200-300ms (page transitions)

Exaggeration: Scale to 0.9 for dramatic departure, 0.97 for subtle dismissal.

Solid Drawing: Maintain spatial logic. Elements should exit the way they came or toward where they "belong."

Appeal: Exits confirm user intent. Make dismissals feel decisive, not abrupt.

Timing Recommendations

Element TypeDurationEasingNotes
Tooltip100msease-inFaster than entrance
Dropdown150msease-inCollapse upward
Toast150msease-inSlide to origin
Modal200msease-inContent first, overlay last
Deleted Item200msease-inCollapse height after fade
Page250msease-inCurrent page exits, then new enters

Implementation Pattern

css
.exiting {  animation: exit 200ms cubic-bezier(0.4, 0, 1, 1) forwards;}
@keyframes exit {  from {    opacity: 1;    transform: translateY(0) scale(1);  }  to {    opacity: 0;    transform: translateY(-10px) scale(0.98);  }}

Collapse Pattern

For removed list items:

  1. Fade out content (150ms)
  2. Collapse height (150ms, starts at 100ms)
  3. Remove from DOM after animation completes

Total perceived time: 250ms. Always use will-change: opacity, transform for smooth exits.

Source and attribution

Source:dylantarre/animation-principlesinskills/05-by-animation-type/exit-animationsat commit8359713

License: No license

Content belongs to its original authors. SourceWeft indexes it from a public repository.

Report or request removal