Props
| Name | Type | Default | Description |
|---|---|---|---|
ariaLive | "off" | "polite" | "assertive" | undefined | - | ARIA live region politeness.
Defaults to Only override it when visual tone and urgency come apart — a quiet |
closeLabel | string | undefined | - | Visually hidden string used to label the close button. Defaults to a localised "Close" from the plugin |
hideClose | boolean | undefined | false | 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 |
icon | string | undefined | - | 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 | number | ({ size?: any; } & string) | keyof Sizes | undefined | "16" | Size of the icon to use. |
modelValue | any | true | Used by v-model, set type to any to avoid Vue casting it as false. Alerts are visible on mount; the model dismisses them. |
pt | PtMap<BbAlertPtPart, never> | undefined | - | Passthrough, object form: the same keys as the |
pt:close | PtValue | undefined | - | |
pt:icon | PtValue | undefined | - | |
pt:root | PtValue | undefined | - | |
pt:text | PtValue | undefined | - | |
pt:title | PtValue | undefined | - | |
role | "alert" | "status" | undefined | - | Accessibility role for the alert container.
Defaults to Derived from the variant, so setting it is a deliberate disagreement with that derivation. Reserve |
text | string | undefined | - | Text content of the alert body. For when a string is all you have — a server message, an item in a |
title | string | undefined | - | Text content of the alert title. |
transitionDuration | number | undefined | 250 | Transition duration in milliseconds for enter/leave. |
variant | keyof AlertVariantRegistry | undefined | "outline" | Visual variant of the alert. An open registry, not a closed enum: |
v-model
Values kept in sync through v-model.
| Name | Type | Description |
|---|---|---|
modelValue | any | Typed |
Events
| Name | Type | Description |
|---|---|---|
update:modelValue | (event: "update:modelValue", value: boolean): void |
Slots
The listed properties are the ones exposed to the slot scope.
| Name | Type | Description |
|---|---|---|
default | any | The alert body — the shortest form, and the one to reach for:
|
text | BbAlertTextSlotProps | Replaces the default alert body text. Wins over children and Receives |
title | BbAlertTitleSlotProps | Replaces the default alert title text. See example |
Changes from v2
Props removed or renamed in 3.0. If you are coming from v2, the answer is here.
showClosehideClosefails silentlythemevariantfails silently