Badge
Props
| Name | Type | Default | Description |
|---|---|---|---|
variant | BadgeVariant | 'neutral' | Sets the visual variant of the badge. Optional: neutral, info, success, warning, error, blue, cyan, green, orange, pink, purple, red, teal, yellow. |
Slots
| Name | Description |
|---|---|
default | Text content displayed by the badge. |
icon | Optional leading icon. An icon should not replace the text label. |
Native attributes
The root element is <span>.
The root element receives:
- HTML attributes.
aria-*attributes.data-*attributes.class.style.- Native event listeners.
Badge is a read-only indicator. Do not add interactive behavior.