Skip to content

zk-toast ​

A short message in a toast container.

Props ​

PropTypeDefaultDescription
variantstring'info'data-variant; warning and error have role="alert"
dismissiblebooltrueShows a close button (data-zk-dismiss=".toast", needs zk-scripts)
closeLabelstring'Close'Accessible name of the close button
classstring|nullnullCSS class(es) merged onto the root element

Undeclared attributes forward to the root element.

Slots ​

SlotDescription
defaultMessage

Class hooks: toast, toast-body, toast-close.

Examples ​

Basic ​

blade
<x-zk-toast variant="success">Saved.</x-zk-toast>

Documentation of 3.2.7 , built from 7415dae on 3.2.7 by pipeline #3081600448 on 2026-11-17.