Alert

Displays important alert messages.

Basic Usage

Alert components are non-overlay elements in the page that does not disappear automatically.

Theme

Alert provide two different themes, light and dark.

Customizable Close Button

Customize the close button as texts or other symbols.

With Icon

Displaying an icon improves readability.

Centered Text

Use the center attribute to center the text.

With Description

Description includes a message with more detailed information.

With Icon and Description

Alert API

Attributes

NameDescriptionTypeDefault
titlealert title.string
typealert type.enuminfo
descriptiondescriptive text.string
closablewhether alert can be dismissed.booleantrue
centerwhether content is placed in the center.booleanfalse
close-textcustomized close button text.string
show-iconwhether a type icon is displayed.booleanfalse
effecttheme style.enumlight

Events

NameDescriptionType
closetrigger when alert is closed.Function

Slots

NameDescription
defaultcontent of the alert description.
titlecontent of the alert title.

Source

ComponentDocs

Contributors