Orchestration
Also called animation sequencing or motion choreography
Coordinating several different animations into one planned sequence, so the parts of a screen enter in a clear order.
import { Dialog } from '@base-ui/react/dialog';
import { motion, stagger } from 'motion/react';
// Content starts at 180ms, 100ms after the panel, with 60ms between items.
const content = {
hidden: {},
shown: { transition: { delayChildren: stagger(0.06, { startDelay: 0.18 }) } }
};
const item = { hidden: { opacity: 0, y: 8 }, shown: { opacity: 1, y: 0 } };
type Props = { open: boolean; onOpenChange: (open: boolean) => void };
export function WelcomeDialog({ open, onOpenChange }: Props) {
return (
<Dialog.Root open={open} onOpenChange={onOpenChange}>
<Dialog.Portal>
{/* 1. The backdrop fades in over 200ms. */}
<Dialog.Backdrop className='fixed inset-0 bg-black/40 transition-opacity duration-200 data-ending-style:opacity-0 data-ending-style:duration-150 data-starting-style:opacity-0' />
{/* 2. 80ms later the panel scales up over 300ms. Both close together in 150ms. */}
<Dialog.Popup className='fixed top-1/2 left-1/2 w-96 max-w-[calc(100vw-3rem)] -translate-1/2 rounded-2xl border bg-background p-6 text-center shadow-xl outline-none transition-[opacity,scale] delay-80 duration-300 ease-[cubic-bezier(0.23,1,0.32,1)] data-ending-style:scale-96 data-ending-style:opacity-0 data-ending-style:delay-0 data-ending-style:duration-150 data-starting-style:scale-96 data-starting-style:opacity-0'>
{/* 3. The avatar, text, and buttons follow in order. */}
<motion.div
variants={content}
initial='hidden'
animate='shown'
className='flex flex-col items-center gap-3'
>
<motion.img
variants={item}
src='/avatars/maya.png'
alt=''
className='size-14 rounded-full'
/>
<motion.div variants={item}>
<Dialog.Title className='text-lg font-semibold'>
Welcome aboard, Maya
</Dialog.Title>
<Dialog.Description className='text-sm text-muted-foreground'>
Your workspace is ready. Pick a template to start.
</Dialog.Description>
</motion.div>
{/* Opacity doesn't block clicks, so the buttons work right away. */}
<motion.div variants={item} className='flex gap-2'>
<Dialog.Close className='rounded-md border px-3 py-2 text-sm font-medium hover:bg-muted'>
Skip for now
</Dialog.Close>
<Dialog.Close className='rounded-md bg-primary px-3 py-2 text-sm font-medium text-primary-foreground'>
Browse templates
</Dialog.Close>
</motion.div>
</motion.div>
</Dialog.Popup>
</Dialog.Portal>
</Dialog.Root>
);
}Orchestrate the welcome dialog’s entrance: fade the backdrop in over 200ms, then 80ms later scale the panel from 0.96 to 1 and fade it in over 300ms with an ease-out curve, then reveal the avatar, title, and buttons with a 60ms stagger. Keep the whole sequence under 700ms, make the buttons clickable right away, and close everything together in 150ms.
Paste into Layerwise or any AI coding tool.
Orchestration explained
Orchestration decides when each part of a scene moves relative to the others. When a dialog opens, the backdrop fades in first, the panel rises, and then the content settles in: avatar, title, and finally the buttons. Each piece has its own animation, and the timing between them tells the eye where to look.
Use it for moments that introduce something: dialogs, onboarding steps, empty states, or a hero section on first load. Lead with the container, then the most important content, and finish with actions. Overlap the steps instead of waiting for each to finish; offsets of 50 to 100ms feel connected.
Keep the whole sequence short, ideally under about 700ms, and make sure people can click before the last flourish ends. In Motion for React, variants let a parent run its children’s animations with delayChildren and the stagger() helper.
Often confused with
- Stagger
- A stagger repeats one animation across many similar items. Orchestration coordinates different animations, such as a backdrop, a panel, and its buttons.
Related terms
All termsStagger
Animating a group of items one after another with a small delay between each, so they arrive as a cascade.
Delay
The wait between the moment an animation is triggered and the moment it starts moving, used to sequence motion or ignore brief triggers.
Modal
A window that opens over the page, dims everything behind it, and blocks the rest of the interface until you finish or dismiss it.
Enter and exit animations
The pair of animations an element plays as it is added to the page and as it is removed, so changes to a list or layout are easy to follow.
Build it with Layerwise
Describe your app, watch it run in a live preview, and publish it with a database, storage, and sign-in built in.