%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /var/www/html/higroup/wp-content/plugins/user-registration/assets/js/ur-snackbar/
Upload File :
Create Path :
Current File : /var/www/html/higroup/wp-content/plugins/user-registration/assets/js/ur-snackbar/ur-snackbar.min.js

/*!
 * JavaScript Library v1.0.0
 * Name: Snackbar
 * Author: WPEverest
 * Versoin: 1.0.0
 */
var UR_Snackbar=function(){this.offsetY=30,this.diffY=15,this.body=document.getElementsByTagName("body")[0],this.list={}};UR_Snackbar.prototype.add=function(t){var e=this,i="x"+(new Date).getTime().toString(),s=document.createElement("div"),n=document.createElement("span"),a=document.createElement("label"),o=this.offsetY+this.diffY*Object.keys(this.list).length;"object"!=typeof t&&(t={});var c=t.duration?parseFloat(t.duration):1,d=t.message?t.message:"",l=t.type?t.type:"success",r=document.createTextNode(d);Object.values(this.list).forEach(function(t){t.container&&(o+=t.container.clientHeight)}),s.style.bottom=o+"px",s.id=i,s.classList.add("snackbar"),s.classList.add(l),n.classList.add("icon"),s.style.right="-600px",t.containerClass&&s.classList.add(t.containerClass),s.appendChild(n),a.appendChild(r),s.appendChild(a),this.body.appendChild(s),setTimeout(function(){s.style.right="6px"},50),setTimeout(function(){s.style.right="-600px",setTimeout(function(){s.remove(),e.removeListItem(i)},500)},1e3*c),this.list[i]={ID:i,container:s,icon:n,text:r,label:a,options:t}},UR_Snackbar.prototype.removeListItem=function(t){this.list[t]&&delete this.list[t]};

Zerion Mini Shell 1.0