Empty
A compact empty-state card for panels and filtered results.
Usage
Basic
compact switches to the small size; iconClass replaces the icon.
Loading demo...
Action
Loading demo...
Best Practices
- Use
TxEmptyfor list, search, or panel placeholders that want a card surface. - When the empty cause has product meaning, use
TxNoData,TxNoSelection,TxOfflineState, orTxPermissionState. - Set
compactin dense regions such as sidebars and table interiors. - Put click handling on the control in the
actionslot;TxEmptyemits no events.
API Reference
Renders TxEmptyState with variant="empty", surface="card", and layout="vertical" fixed.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
title | string | 'Nothing here' | Main message. |
description | string | '' | Supporting text below the title. |
iconClass | string | 'i-carbon-incomplete' | Icon class, passed to TxEmptyState as icon. |
compact | boolean | false | true sets size="small"; otherwise medium. |
Slots
| Slot | Props | Description |
|---|---|---|
icon | - | Replaces the iconClass icon. |
title | - | Replaces the title. |
description | - | Replaces the description. |
action | - | Action area; replaces the actions slot of TxEmptyState. |
Technologies
- Source:
packages/tuffex/packages/components/src/empty/.
查看源码
packages/tuffex/packages/components/src/empty/index.ts