motionsnack

Animated React sections that already feel finished.

Copy them into Next.js or add them with one command. Plain React and Tailwind, light and dark.

New sections, once a month

One short email when something new lands. No spam.

Library

  • Sections
  • Blocks
  • Components
  • Application UI
  • Templates

Popular

  • Hero
  • Gallery
  • Testimonials
  • Stats
  • Logos
  • FAQ

Resources

  • Installation
  • All components
  • All blocks
  • All sections
  • All application UI
  • Design system
  • Changelog
  • Pricing

Company

  • About
  • Contact
  • Terms
  • Privacy

Install

npx motionsnack add <name>Step-by-step guidehello@motionsnack.dev
Kuba Šťastný@kubastastnydev

© 2026 motionsnack. All rights reserved.

TermsPrivacy

motionsnack

motionsnack
DocsSectionsTemplatesWhat's newPricing
Get lifetime access
  1. Home
  2. Docs
  3. Components
  4. Dialog
  5. Spring Dialog
ComponentsBlocksSectionsApplication UI
ComponentsBlocksSectionsApplication UI

Accordion

  • Spring Accordion

Alert

  • Glow Alert

Audio

  • Podcast PlayerNew
  • Voice NoteNew
  • Voice RecorderNew

Avatar

  • Avatar Stack

Badge

  • Pulse Badge

Breadcrumb

  • Slide Breadcrumb

Button

  • Chip ButtonNew
  • Glow Border Button
  • Glow ButtonNew
  • Plain ButtonNew

Calendar

  • Month Calendar

Checkbox

  • Checkbox CardsNew
  • Checkbox GroupNew
  • Chip CheckboxNew

Cropper

  • Image Cropper

Dialog

  • Spring Dialog

Dropdown

  • Command MenuNew
  • Stagger Dropdown
  • Switcher DropdownNew

File Upload

  • Drop Zone Upload

Input

  • Addon InputNew
  • Button InputNew
  • Copy InputNew
  • Date InputNew
  • Floating Label Input
  • Joined InputsNew
  • Notched Label InputNew
  • Number StepperNew
  • OTP InputNew
  • Password InputNew
  • Phone InputNew
  • Range InputNew
  • Search InputNew
  • Tag InputNew
  • Text FieldNew

Loader

  • Curtain LoaderNew
  • Greeting LoaderNew
  • Line LoaderNew
  • Meter LoaderNew
  • Split LoaderNew

Navigation Menu

  • Mobile Tab BarNew

Notification

  • Notification BellNew
  • Toast Stack

Pagination

  • Sliding Pagination

Popover

  • Spring Popover

Radio

  • Card Radio Group
  • Payment MethodNew
  • Radio GroupNew
  • Rating RadioNew

Select

  • ComboboxNew
  • Glide Select
  • Multi SelectNew
  • Rich SelectNew
  • Select FieldNew
  • Tree SelectNew

Sidebar

  • Icon RailNew

Slider

  • Glow Slider

Stepper

  • Progress Stepper

Switch

  • Billing SwitchNew
  • Switch RowNew
  • Toggle SwitchNew

Table

  • Sortable Table

Tabs

  • Sliding Tabs

Textarea

  • Auto Grow Textarea

Toggle

  • Icon ToggleNew
  • Theme ToggleNew
  • Toggle GroupNew

Tooltip

  • Follow Tooltip

Dialog

Spring Dialog

A modal dialog whose panel springs up over a backdrop that fades and blurs in.

npx motionsnack add spring-dialog

Customize

Accent
s
<SpringDialog />

Props

22 properties

PropertyTypeDefaultDescription
triggerReactNode'Publish release'Content of the button that opens the dialog.
openboolean-Controlled open state. Leave undefined to let the component manage it.
defaultOpenbooleanfalseOpen state on first render when uncontrolled.
onOpenChange(open: boolean) => void-Called whenever the dialog wants to open or close.
onConfirm() => void-Called when the confirming button is pressed, before the dialog closes.
onCancel() => void-Called when the dialog is dismissed without confirming.
classNamestring''Extra classes on the wrapper around the trigger.
triggerLabelstring'Publish release'Text of the button that opens the dialog. Empty hides the button.
titlestring'Publish this release?'Heading of the dialog.
descriptionstring'Version 2.4 goes live for all 1,280 workspaces right away. You can roll back from the release history at any time.'Paragraph under the heading.
confirmLabelstring'Publish'Label of the confirming button. Empty hides it.
cancelLabelstring'Not yet'Label of the cancelling button. Empty hides it.
variant'default' | 'destructive''default'Destructive turns it into a confirm (alert dialog): no close button, the confirm carries an error-coloured icon.
icon'spark' | 'info' | 'trash' | 'none''spark'Icon in the coloured badge above the heading.
showClosebooleantrueRound close button in the top right corner.
closeOnBackdropbooleantrueA click on the backdrop closes the dialog.
closeOnEscapebooleantrueThe Escape key closes the dialog.
lockScrollbooleantrueStop the page behind from scrolling while the dialog is open.
accentstring''Colour of the icon tile. Empty keeps it monochrome.
startScalenumber0.9Scale the panel starts from. 1 turns the scaling off.
bouncenumber0.35Bounce of the spring that scales the panel up.
durationnumber0.5Seconds the spring takes to settle.

About Spring Dialog

Spring Dialog pairs a trigger button with an accessible modal: icon badge, title, text, confirm and cancel buttons and a close button. When it opens, the backdrop fades in and blurs the page while the panel scales up on a spring with a bounce you can tune. Closing is a quick, quiet fade so the dialog gets out of the way. Focus moves into the panel, Tab stays trapped inside it and focus returns to the trigger afterwards. Escape and a click on the backdrop dismiss it, and both can be switched off. It works controlled or uncontrolled and falls back to a plain fade for reduced motion.

What's included

  • Spring scale-in with adjustable bounce, duration and start scale
  • Backdrop that fades and blurs the page
  • Focus trap with focus returned to the trigger
  • Escape and backdrop click to dismiss
  • Controlled and uncontrolled open state
  • Default and danger confirm button, optional icon badge
  • Light and dark looks, reduced motion support
Type
Animated React dialog component
Library
Components · Dialog
Stack
Next.js, React, Tailwind CSS
Added
2026-09-20
Install
npx motionsnack add spring-dialog