vanillatoasts
Advanced tools
Comparing version 1.4.0 to 1.5.0
{ | ||
"name": "vanillatoasts", | ||
"version": "1.4.0", | ||
"version": "1.5.0", | ||
"description": "Agnostic Javascript Library for Website Notifications", | ||
@@ -5,0 +5,0 @@ "main": "vanillatoasts.js", |
@@ -80,2 +80,8 @@ (function (root, factory) { | ||
} | ||
if (options.onHide) { | ||
// do something | ||
} | ||
} | ||
@@ -117,3 +123,15 @@ // position | ||
toast.addEventListener('animationend', removeToast, false); | ||
}; | ||
if (options.onHide) { | ||
options.onHide(); | ||
} | ||
} | ||
// single | ||
if (options.single === true) { | ||
var elements = document.getElementsByClassName('vanillatoasts-toast'); | ||
while (elements.length > 0) { | ||
elements[0].parentNode.removeChild(elements[0]); | ||
} | ||
} | ||
@@ -120,0 +138,0 @@ // autohide |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
16917
5
264