Empty
Fills a blank space with what goes there and how to start.
Examples
No transactions yet
Add a card or link a bank to see your spending here.
No results for "coffee"
Try a shorter word, or clear the filters.
All paid up
No bills due this week.
Content
No transactions yet
Add a card to see your spending.
first usedefault
No matches
Try a shorter word.
no results
Nothing shared with you
Bills friends split with you show up here.
no action
No receipts
Upload a photo to attach it.
two actions
Usage
When to use it
- Use
- A list, grid or feed with no items yet, where an action makes the first.
- Use
- A search or filter that returned nothing.
- Use
- A tab or panel whose content has not been created.
- Not for
- Content is still loading. Show its shape. Use Skeleton.
- Not for
- Something failed to load. Say what failed and offer a retry. Use Error state.
- Not for
- One missing field. Use the field hint or placeholder.
Rules
9 rules
- Must
- Make the action that fills the region the primary button; any second action is ghost. Because two lime buttons leave the person unsure which one fills the list.
- Must
- Say no matches and offer to clear when a filter emptied the list; never the first-use message. Because "No transactions yet" on a filtered list tells the person their money is gone.
- Should
- Name what is missing in the title, sentence case, such as No transactions yet.
- Should
- Say how the region gets filled in one sentence with the real step; do not restate the title.
- Never
- Add an illustration, mascot or emoji; keep the 24px icon in its well. Because an emoji brings its own platform colors and size into a well sized for a 24px icon.
- Must
- Show one or two buttons in EmptyActions, never more. Because a third button wraps to a second line at 390px and buries the one next step.
- Must
- Render Empty only after the load returns no items; show a skeleton while loading. Because an empty list during the fetch flashes "No transactions yet" at someone who has many.
- Should
- Place EmptyTitle (a fixed h3) under an h2 so no heading level is skipped.
- Should
- Put Empty straight in the region it empties; never wrap it in a card or give it a fill to frame it.
Accessibility
3 checks
- The region is not focusable; Tab goes to the first action.
- EmptyTitle is a heading level 3; EmptyIcon is aria-hidden.
- Buttons carry their own states and focus ring.
Edge cases
6 edge cases
- Long title
- Wraps and stays centered; an unbroken string overflows.
- Narrow to 120px
- Buttons wrap onto separate lines; side padding stays 24px.
- Right to left
- Content is centered and nothing mirrors; action order follows the direction.
- No children
- A 40px padded gap that says nothing; always pass a title.
- Failed load
- Not an empty list; show an error with a retry instead.
- Forced colors
- Nothing to drop: the region has no fill or border, and the icon well loses its fill.
API
5 props
EmptyComponentProps<'div'>EmptyIconComponentProps<'div'>EmptyTitleComponentProps<'h3'>EmptyDescriptionComponentProps<'p'>EmptyActionsComponentProps<'div'>
Tokens
6 tokens
--surface- #f6f5f2
--fg-2- #4a4943
--text-lg- 18px
--weight-semibold- 600
--leading-tight- 1.2
--text-sm- 14px