Appearance
Tag
SCATag is a label chip that can be selected, removed and decorated with an avatar or icons. Icon names are typed (IconName); see Icons.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
variant | 'default' | 'underline' | 'breadcrumb' | 'ghost' | 'default' | Visual style. breadcrumb adds a leading caret-right. |
selected | boolean | false | Selected look. Two-way via v-model:selected. |
disabled | boolean | false | Disabled look; clicks do not toggle selected. |
removable | boolean | false | Show a remove (×) icon that emits remove. |
error | boolean | false | Error look. |
unavailable | boolean | false | Muted look for a value that is no longer available. |
icon | IconName | — | Leading icon (use the iconLeft slot for custom content). |
iconSize | string | '12px' | Size of icon. |
iconColor | string | — | Fixed colour of icon. |
avatar | Omit<SCAAvatarProps, 'size'> & { image?: string } | — | Small avatar before the label; see Avatar. |
overflow | CSS overflow | 'hidden' | Overflow of the label. |
truncateTooltip | boolean | false | Show the full text in a tooltip when the label is truncated. |
tooltip | string | — | Plain-text tooltip; replaces the truncation tooltip. |
as | string | Component | 'div' | Root element or component. |
Slots
| Slot | Description |
|---|---|
default | The label. |
iconLeft / iconRight | Custom content (usually SCASvgIcon) before / after the label. |
Emits
| Event | Payload | When |
|---|---|---|
remove | — | The remove icon is clicked. |
update:selected | boolean | The tag is clicked (not while disabled). |
removable
Icons
Avatar
The avatar property contains the following properties of the SCAAvatar component.
initials emphasis appearance shape
Additional props
image
selection
error and unavailable
Variant: Underline
Variant: Breadcrumb
Overflow
Set css overflow for the label. Default = hidden