Open arashb31 opened 8 years ago
Hey @arashb31 you can archive this by doing some minor tweaks to ionic-toast.js line number 57
toastScope.hide = function () { toastScope.ionicToast.toastClass = 'ionic_toast_top ionic_toast_sticky animated fadeOutDown'; };
and line number 70
angular.extend(toastScope.ionicToast, { toastClass: toastPosition[position] + ' ' + (closeBtn ? 'ionic_toast_sticky animated fadeInDown' : ''), toastMessage: message });
You also need to have animate.css file from https://daneden.github.io/animate.css/
Hope this help :)
Great that works!. How about adding an optional parameter on the toast.show to add any optional classes/IDs?
eg.
var classes = {
openID: "myID",
openClass: "animated fadeInLeft",
closeClass : "animated fadeOutRight"
}
ionicToast.show('This is a toast at the top.', 'top', true, 2500, classes);
+1 for optional parameter for adding classes
great work, by the way!
Any way of adding animations to the toast appearing/disappearing (like Android)?
Maybe add some classes for it to work with animate.css