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

Attributes

AttributeDescriptionTypeAccepted ValuesDefault
titletitlestring
typeComponent typestringsuccess/warning/info/errorinfo
descriptionDescriptive text. Can also be passed with the default slotstring
closableIf closable or notbooleantrue
centerWhether to center the textbooleanfalse
close-textCustomized close button textstring
show-iconIf a type icon is displayedbooleanfalse
effectChoose themestringlight/darklight

Slots

NameDescription
description
titlecontent of the Alert title

Events

Event NameDescriptionParameters
closefires when alert is closed