Toast (toast
)
Push notifications to your visitors with a toast, a lightweight and easily customizable alert message.
🔗 External documentation.
ID | Label | Description | Schema |
---|---|---|---|
image | Image | The alert heading. Optional. | |
title | Title | Bootstrap | |
meta | Meta | The alert heading. Optional. | |
body | Body | The alert message. | |
dismissible | Dismissible? | It’s possible to dismiss any alert inline |
|
delay | Delay (ms) | Delay hiding the toast (ms). If 0, the toast stays open until manually closed. Default: 0 |
|
role | Accessibility role | If it’s an important message like an error, use "Alert & Assertive", otherwise use "Status & Polite". |
|
id: toast
label: Toast
description: 'Push notifications to your visitors with a toast, a lightweight and easily customizable alert message. '
homepage: 'https://getbootstrap.com/docs/4.6/components/toasts/'
slots:
image:
id: image
label: Image
description: 'The alert heading. Optional.'
title:
id: title
label: Title
description: Bootstrap
meta:
id: meta
label: Meta
description: 'The alert heading. Optional.'
body:
id: body
label: Body
description: 'The alert message.'
props:
dismissible:
id: dismissible
label: 'Dismissible?'
description: 'It’s possible to dismiss any alert inline'
schema:
type: boolean
default: true
delay:
id: delay
label: 'Delay (ms)'
description: 'Delay hiding the toast (ms). If 0, the toast stays open until manually closed. Default: 0'
schema:
type: number
role:
id: role
label: 'Accessibility role'
description: 'If it’s an important message like an error, use "Alert & Assertive", otherwise use "Status & Polite".'
schema:
type: string
enum:
- alert
- status
default: alert
library:
js:
'https://data.dilla.io/bootstrap_4/components/toast/init.js': { }
id: toast
examples:
preview:
id: preview
label: Preview
renderable:
'@component': toast
image:
'@element': img
'@styles':
- rounded
- mr-2
src: 'https://data.dilla.io/bootstrap_4/assets/toast-image.svg'
title: 'Well done!'
meta: '>11 mins ago'
body: 'Hello, world! This is a toast message.'
dismissible: true
delay: 1000
role: alert
Hello, world! This is a toast message.