Skip to content
On this page

Alert

Light

light is default variant for alert.

Use color prop to change the alert color.

Filled

You can use variant="fill" to create alert with filled background.

Outlined

You can use variant="outline" to create outlined alert.

Icons

You can use icon prop to render icon in alert.

Use append-icon prop to render icon after default slot.

Dismissible

Use dismissible prop to create dismissible alert.

You can customize close icon using append-icon prop.

v-model support

Alert also supports v-model to show and hide alert based on model value.

API

Alert

dismissible : boolean

Make alert dismissible using this prop. Adds close icon as appended icon.

modelValue : boolean

Hide/Show alert based on v-model value

color : ColorProp
variant : LayerVariant
states : boolean

Interaction states like hover & active

icon : ConfigurableValue

prepend icon

appendIcon : ConfigurableValue

append (close) icon

default : any

Default slot for rendering alert content

append : any

Slot for appending content to alert

click:appendIcon => []
update:modelValue => [value: boolean | undefined]

Released under the MIT License.