Empty State
A centred panel for a list, table or search with nothing to show, with an optional icon and actions.
Usage
Usage notes
It is content, not a notification: it has no role and no live region. Pair it with volt-alertwhen the list is empty because a request failed.volt-empty-state-titleis not a heading element; wrap it in theh2–h6that fits your page outline.Actions are ordinary buttons or links in [slot=actions]: they keep the page's tab order and wrap on narrow screens.
API Reference
VoltEmptyStateDescription — volt-empty-state-description
| Input | Type | Default |
|---|---|---|
| class | string | '' |
VoltEmptyStateTitle — volt-empty-state-title
| Input | Type | Default |
|---|---|---|
| class | string | '' |
VoltEmptyState — volt-empty-state
| Input | Type | Default |
|---|---|---|
| class | string | '' |
Component Source
Install via CLI:
npx @voltui/cli add empty-stateTypeScript
Loading editor…
Copy this code to your project. The component uses class-variance-authority.