Empty

An empty-content state with a configurable animated SVG illustration.

Empty

Default

An open, completely empty box conveys missing content. Explain the state with description and offer the next action in the default slot.

Animation

Use animated to control the built-in scene. The three rectangular flaps open together from a partly open pose, revealing the empty interior. A few luminous stars briefly appear, then fade; the box stays open. Replay the example with the button, or restart an application instance by remounting it or re-enabling animated. Reduced motion keeps the scene static; offscreen or hidden pages pause it.

Image size

image-size sets both box dimensions while preserving the SVG aspect ratio. Numbers use px; CSS lengths also work. Custom images use the same size.

Custom image

Pass image to replace the default SVG. Custom images use object-fit: contain and do not receive built-in animation.

Slots

The image slot replaces the illustration and takes precedence over the image prop. Customize the message with description and place actions in the default slot.

API

PROPS

Property
Type
Values
Description
default
Example
More
image
String
URL
Custom image URL. Replaces the built-in SVG and its animation.
—
image-size
Number | String
CSS size
Sets both illustration box dimensions; numbers use px. The default box is 160 × 128px.
—
description
String
text
Empty-state message.
—
animated
Boolean
true | false
Enable a one-time opening animation followed by a brief sparkle. It finishes on the open box; reduced motion shows that static pose. Offscreen or hidden pages pause playback. Does not affect custom images or the image slot.
true

SLOTS

Slot
Description
default
Example
More
image
Replace the illustration; takes precedence over image and the built-in SVG.
—
description
Custom empty-state message.
—
default
Actions below the message.
—
Last Updated: 2026-10-28, 06:17:56 UTC
Copied