Skip to content

Motion

Overlays, menus and panels move with Animate UI, everything else on one ease, and reduced motion removes it all.

Motion in Silkware is small and quiet. Overlays, menus, panels and a few controls move with Animate UI, a set of animated drop-ins for the primitives the components are built on. Everything else keeps the CSS transitions shadcn ships, on one ease. A person who asks their system for less motion gets the content at once.

What the system does

Animate UI

Animate UI animates primitives, not components. Each one has exactly the API of the React Aria or Base UI part it wraps, with Motion inside, so a Silkware component changes only the line it imports its primitive from. Parts, props, data attributes and accessibility stay the library's.

These components move with it: Accordion, Alert Dialog, Carousel, Checkbox, Collapsible, Combobox, Command, Context Menu, Dialog, Drawer, Dropdown Menu, Hover Card, Input OTP, Menubar, Popover, Progress, Questionnaire, Radio Group, Select, Sheet, Slider, Switch, Tabs, Toggle, Toggle Group and Tooltip. Navigation Menu and Code Block keep their CSS animations.

Every animated primitive follows the same rules:

  • Springs and short tweens on a strong ease-out. Exits are quicker than entrances.
  • Transform and opacity, not layout. A panel's height is the one exception, and it never fights a CSS transition.
  • Interruptible: reopen a menu while it closes and it turns around.
  • Nothing moves on keyboard navigation.

When you install a component from @silkware, the shadcn CLI installs @animate-ui/react and motion with it. There is nothing to configure.

One ease

--ease is cubic-bezier(0.16, 1, 0.3, 1), a fast start that settles gently. It is wired in two places:

  • --default-transition-timing-function is var(--ease), so every Tailwind transition, transition-colors and transition-[...] class uses it without naming it.
  • --ease-brand makes ease-brand a utility, for your own transitions.

Animate UI moves on its own curves, which are close to it. They live in code, not in globals.css, so a client theme changes the ease of CSS transitions and not of Animate UI's springs.

ease-brand, the default
ease-linear

Reduced motion

Under prefers-reduced-motion: reduce, Animate UI drops movement and height changes and keeps only a short fade. globals.css sets every CSS animation and transition to 0.01ms, removes delays, limits animations to one iteration and turns off smooth scrolling. You write nothing to get either.

To check it, turn on Reduce motion in your operating system and reopen the dialog above.

Press and hover

Radio Group and Toggle scale to 0.97 when pressed, from Animate UI. Buttons nudge down by 1px and fade their colour, as upstream ships them. The brand's 0.96 press and 260ms hover wipe are not applied: --press exists in globals.css for a client brand to adopt.

Rules for your own motion

  • Compose the components first: most motion you need is already in them.
  • For something of your own, use motion/react with Animate UI's tokens from @animate-ui/react/utils/motion, so it moves like the rest. Use useReducedMotion from Motion to drop the movement for people who ask.
  • Never add animate-in, data-entering: or fade-in classes to a part Animate UI already animates. Two animations on one element stutter.
  • Animate transform, opacity and clip-path. Do not animate width, height or margins.
  • An entrance plays once, as the thing enters. Nothing loops for attention.
  • Nothing to manage: no pause buttons, no progress lines on anything that plays by itself.
Supplier confirmed by Luca on Tuesday.
Do

Move something in with opacity and a small transform, once.

Order BRV-2042 waits on Luca
Don’t

Don’t loop an animation to draw attention.

Out of scope

The brand source describes signature moves: the hero entrance, the scroll-linked statement fill, the plate that glides to a chosen row, the square that travels, photographs that open out of a clip, and a 280ms crossfade on theme change. They run on GSAP, with SplitText, ScrollTrigger and Flip, on the brand site.

None of them are part of this system, and GSAP is not a dependency. In an application the theme change is instant: the provider disables transitions while it switches, so components do not flash through a half-changed state.

This documentation site adds two Animate UI pieces to its own chrome, which are not registry items: pages change with its Page Transition on the flow effect, and the theme button is its Theme Toggler wipe around its Theme Toggler Button. An application that wants them adds them from Animate UI's registry with the shadcn CLI.