Props
| Name | Description |
|---|---|
ariaLive Type: "off" | "polite" | "assertive" | ARIA live region politeness. Unset, it follows Only override it when visual tone and urgency come apart — a quiet |
closeLabel Type: string | Visually hidden string used to label the close button. Defaults to a localised "Close" from the plugin |
hideClose Type: booleanDefaultfalse | Defines whether to hide the close button. The only way to make an alert permanent: an unbound alert is still dismissible, because the internal model starts at |
hideIcon Type: booleanDefaultfalse | Hide the icon, its own or its variant's; with neither it does nothing. |
icon Type: string | Name of a registered icon to use, or a full raw No variant implies an icon — pass one, and pick it together with the variant. It reinforces the message; |
iconSize Type: number | CssSize | keyof SizesDefault"16" | Size of the icon to use. |
modelValue Type: booleanDefaulttrue | Used by v-model. Alerts are visible on mount; the model dismisses them. |
pt Type: PtMap<BbAlertPtPart, "outline" | "primary" | "destructive" | "warning"> | Passthrough, object form: the same keys as the |
pt:<part> Type: PtValue | Passthrough, attribute form: one attribute per part, |
role Type: "alert" | "status" | Accessibility role for the alert container. Defaults to Derived from the variant, so setting it is a deliberate disagreement with that derivation. Reserve |
text Type: string | Text content of the alert body. For when a string is all you have — a server message, an item in a |
title Type: string | Text content of the alert title. |
transitionDuration Type: numberDefault250 | Transition duration in milliseconds for enter/leave. |
variant Type: keyof AlertVariantRegistryDefault"outline" | Visual variant of the alert. An open registry, not a closed enum: |
v-model
Values kept in sync through v-model.
| Name | Description |
|---|---|
modelValue Type: boolean | A boolean that starts at |
Events
| Name | Description |
|---|---|
update:modelValue Type: (value: boolean): void | Emitted with the new value whenever |
Slots
The listed properties are the ones exposed to the slot scope.
| Name | Description |
|---|---|
default Type: any | The alert body, the shortest form: |
text Type: BbAlertTextSlotProps | Replaces the default alert body text. Wins over children and Receives |
title Type: BbAlertTitleSlotProps | Replaces the default alert title text. See example |
Renamed and removed
Names from v2 and from earlier 3.0 betas that no longer work, and what to write instead.
showClosehideClosefails silentlythemevariantfails silently