Branch: master
Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
README.md
index.js
readme.js
readme.styl
test.html
test.js

README.md

Toaster

The Toaster component creates a container for all toaster items to be added to.

Demo

Example
Notify Me

Code

The following code should be included once on the page:

HTML

<tonic-toaster></tonic-toaster>

To create a new toaster item:

JS

%js%

Api

Properties

Property Type Description Default
id string Adds an id attribute.
name string Adds a name attribute.
type string Adds an alert type (success, warning, danger, info).
title string Adds a title.
message string Adds a message.
dismiss boolean If set to false, the close button will not be added to the toaster. true
duration number Adds a duration. center
position string (On Parent tonic-toaster Element) Position of the toaster items, can be left, right or center. center
theme string (On Parent tonic-toaster Element) Adds a theme color (light, dark or whatever is defined in your base CSS. light

Instance Methods & Members

Method Description
show() Shows the toaster.
hide() Hides a toaster item.
click() Removes a toaster item.
create() Creates a toaster item.
destroy() Removes a toaster item.