Reputation: 919
I want to know whether is there any easy way to display angular material toast within a specific element.
I'm using Angular-Material Version 1.0.5
Upvotes: 4
Views: 1982
Reputation: 919
HTML
<div id="toastContainer">
</div>
Angular-Material Toast Code
$mdToast.show(
$mdToast.simple({
textContent : "Raise your glass in a toast to myself ;-)",
parent : $document[0].querySelector('#toastContainer'),
hideDelay: 6000
})
);
Upvotes: 5