sweetalert2 0.0.4 → 4.0.11
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -2
- data/app/assets/javascripts/sweetalert2/sweetalert2.min.js +1 -1
- data/app/assets/stylesheets/sweetalert2/index.css +2 -2
- data/app/assets/stylesheets/sweetalert2/sweetalert2.min.css +1 -0
- data/lib/sweetalert2/version.rb +1 -1
- data/sweetalert2.gemspec +1 -1
- metadata +5 -5
- data/app/assets/stylesheets/sweetalert2/sweetalert2.css +0 -534
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 889395b32f512fb18e49b7801e9538f40a953cad
|
4
|
+
data.tar.gz: d5780dd9e8b002c0160599796b0e6fad11bc2fdf
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a478e723079fd38c58b3bbb6607d231b4563519d706989d958d26b62cd3453fa72c561b8cbbbb19474be816f2fe1c2009a4a0fe0f47dbab9632ac61091a689af
|
7
|
+
data.tar.gz: 371aec5f1b5adfb8afd5ff9f8ad2a4b9b0fb05ca84dcfdc927ed3e46f3a74d44c46541731f256df42ba5f039e4472848401ca126c8ba714630026b610b268ff5
|
data/README.md
CHANGED
@@ -1 +1 @@
|
|
1
|
-
!function(e,t){"use strict";function n(){function n(t){var n=t||e.event,o=n.keyCode||n.which;if(-1!==[9,13,32,27].indexOf(o)){for(var a=n.target||n.srcElement,r=-1,i=0;i<S.length;i++)if(a===S[i]){r=i;break}9===o?(a=-1===r?x:r===S.length-1?S[0]:S[r+1],L(n),l(a)):(13===o||32===o?a=-1===r?x:void 0:27===o&&p.allowEscapeKey===!0?c():a=void 0,void 0!==a&&A(a,n))}}function u(t){var n=t||e.event,o=n.target||n.srcElement,a=n.relatedTarget,r=C(y,"visible");if(r){var l=-1;if(null!==a){for(var i=0;i<S.length;i++)if(a===S[i]){l=i;break}-1===l&&o.focus()}else f=o}}if(void 0===arguments[0])return e.console.error("sweetAlert expects at least 1 attribute!"),!1;var p=r({},w);switch(typeof arguments[0]){case"string":p.title=arguments[0],p.text=arguments[1]||"",p.type=arguments[2]||"";break;case"object":p.title=arguments[0].title||w.title,p.text=arguments[0].text||w.text,p.html=arguments[0].html||w.html,p.type=arguments[0].type||w.type,p.animation=void 0!==arguments[0].animation?arguments[0].animation:w.animation,p.customClass=arguments[0].customClass||p.customClass,p.allowOutsideClick=arguments[0].allowOutsideClick||w.allowOutsideClick,p.allowEscapeKey=void 0!==arguments[0].allowEscapeKey?arguments[0].allowEscapeKey:w.allowEscapeKey,p.showConfirmButton=void 0!==arguments[0].showConfirmButton?arguments[0].showConfirmButton:w.showConfirmButton,p.showCancelButton=void 0!==arguments[0].showCancelButton?arguments[0].showCancelButton:w.showCancelButton,p.closeOnConfirm=void 0!==arguments[0].closeOnConfirm?arguments[0].closeOnConfirm:w.closeOnConfirm,p.closeOnCancel=void 0!==arguments[0].closeOnCancel?arguments[0].closeOnCancel:w.closeOnCancel,p.timer=parseInt(arguments[0].timer)||w.timer,p.width=parseInt(arguments[0].width)||w.width,p.padding=parseInt(arguments[0].padding)||w.padding,p.confirmButtonText=arguments[0].confirmButtonText||w.confirmButtonText,p.confirmButtonColor=arguments[0].confirmButtonColor||w.confirmButtonColor,p.cancelButtonColor=arguments[0].cancelButtonColor||w.cancelButtonColor,p.cancelButtonText=arguments[0].cancelButtonText||w.cancelButtonText,p.imageUrl=arguments[0].imageUrl||w.imageUrl,p.imageSize=arguments[0].imageSize||w.imageSize,p.callback=arguments[1]||null,e.sweetAlert.callback=e.swal.callback=function(e){"function"==typeof p.callback&&p.callback(e)};break;default:return e.console.error('Unexpected type of argument! Expected "string" or "object", got '+typeof arguments[0]),!1}o(p),s(),i();var y=b();p.timer&&(y.timeout=setTimeout(function(){c(),"function"==typeof p.callback&&p.callback()},p.timer));var g,v=function(t){var n=t||e.event,o=n.target||n.srcElement,r=C(o,"confirm"),l=C(o,"cancel"),i=C(y,"visible");switch(n.type){case"mouseover":case"mouseup":case"focus":r?o.style.backgroundColor=a(p.confirmButtonColor,-.1):l&&(o.style.backgroundColor=a(p.cancelButtonColor,-.1));break;case"mouseout":r?o.style.backgroundColor=p.confirmButtonColor:l&&(o.style.backgroundColor=p.cancelButtonColor);break;case"mousedown":r?o.style.backgroundColor=a(p.confirmButtonColor,-.2):l&&(o.style.backgroundColor=a(p.cancelButtonColor,-.2));break;case"click":if(r&&p.callback&&i)p.callback(!0),p.closeOnConfirm&&c();else if(p.callback&&i){var s=String(p.callback).replace(/\s/g,""),u="function("===s.substring(0,9)&&")"!==s.substring(9,10);u&&p.callback(!1),p.closeOnCancel&&c()}else c()}},k=y.querySelectorAll("button");for(g=0;g<k.length;g++)k[g].onclick=v,k[g].onmouseover=v,k[g].onmouseout=v,k[g].onmousedown=v;m=t.onclick,t.onclick=function(t){var n=t||e.event,o=n.target||n.srcElement;o===h()&&p.allowOutsideClick&&c()};var x=y.querySelector("button.confirm"),B=y.querySelector("button.cancel"),S=y.querySelectorAll("button, input:not([type=hidden]), textarea");for(g=0;g<S.length;g++)S[g].onfocus=v;d=e.onkeydown,e.onkeydown=n,x.onblur=u,B.onblur=u,x.disabled=!1,B.disabled=!1,e.onfocus=function(){e.setTimeout(function(){void 0!==f&&(f.focus(),f=void 0)},0)}}function o(n){var o=b();o.style.width=n.width+"px",o.style.padding=n.padding+"px",o.style.marginLeft=-n.width/2+"px";var a=t.getElementsByTagName("head")[0],r=t.createElement("style");r.type="text/css",r.id=g,r.innerHTML="@media screen and (max-width: "+n.width+"px) {.sweet-alert {max-width: 100%;left: 0 !important;margin-left: 0 !important;}}",a.appendChild(r);var l=o.querySelector("h2"),i=o.querySelector("p"),c=o.querySelector("button.cancel"),s=o.querySelector("button.confirm");if(l.innerHTML=B(n.title).split("\n").join("<br>"),i.innerHTML=B(n.text.split("\n").join("<br>"))||n.html,i.innerHTML&&E(i),n.customClass&&k(o,n.customClass),q(o.querySelectorAll(".icon")),n.type){for(var u=!1,m=0;m<v.length;m++)if(n.type===v[m]){u=!0;break}if(!u)return e.console.error("Unknown alert type: "+n.type),!1;var d=o.querySelector(".icon."+n.type);switch(E(d),n.type){case"success":k(d,"animate"),k(d.querySelector(".tip"),"animate-success-tip"),k(d.querySelector(".long"),"animate-success-long");break;case"error":k(d,"animate-error-icon"),k(d.querySelector(".x-mark"),"animate-x-mark");break;case"warning":k(d,"pulse-warning"),k(d.querySelector(".body"),"pulse-warning-ins"),k(d.querySelector(".dot"),"pulse-warning-ins")}}if(n.imageUrl){var f=o.querySelector(".icon.custom");if(f.style.backgroundImage="url("+n.imageUrl+")",E(f),n.imageSize){var p=n.imageSize.match(/(\d+)x(\d+)/);p?f.setAttribute("style",f.getAttribute("style")+"width:"+p[1]+"px; height:"+p[2]+"px"):e.console.error("Parameter imageSize expects value with format WIDTHxHEIGHT, got "+n.imageSize)}}o.setAttribute("data-has-cancel-button",n.showCancelButton),n.showCancelButton?c.style.display="inline-block":q(c),n.showConfirmButton?s.style.display="inline-block":q(s),n.cancelButtonText&&(c.innerHTML=B(n.cancelButtonText)),n.confirmButtonText&&(s.innerHTML=B(n.confirmButtonText)),s.style.backgroundColor=n.confirmButtonColor,c.style.backgroundColor=n.cancelButtonColor,n.animation===!0?x(o,"no-animation"):k(o,"no-animation")}function a(e,t){e=String(e).replace(/[^0-9a-f]/gi,""),e.length<6&&(e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]),t=t||0;for(var n="#",o=0;3>o;o++){var a=parseInt(e.substr(2*o,2),16);a=Math.round(Math.min(Math.max(0,a+a*t),255)).toString(16),n+=("00"+a).substr(a.length)}return n}function r(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e}function l(e){e.focus()}function i(){var e=b();I(h(),10),E(e),k(e,"show-sweet-alert"),x(e,"hide-sweet-alert"),u=t.activeElement,setTimeout(function(){k(e,"visible")},500)}function c(){var n=b();M(h(),5),M(n,5),x(n,"showSweetAlert"),k(n,"hideSweetAlert"),x(n,"visible");var o=n.querySelector(".icon.success");x(o,"animate"),x(o.querySelector(".tip"),"animate-success-tip"),x(o.querySelector(".long"),"animate-success-long");var a=n.querySelector(".icon.error");x(a,"animate-error-icon"),x(a.querySelector(".x-mark"),"animate-x-mark");var r=n.querySelector(".icon.warning");x(r,"pulse-warning"),x(r.querySelector(".body"),"pulse-warning-ins"),x(r.querySelector(".dot"),"pulse-warning-ins"),e.onkeydown=d,t.onclick=m,u&&u.focus(),f=void 0,clearTimeout(n.timeout);var l=t.getElementsByTagName("head")[0],i=t.getElementById(g);l.removeChild(i)}function s(){var e=b();e.style.marginTop=O(b())}var u,m,d,f,p=".sweet-alert",y=".sweet-overlay",g="sweet-alert-mediaquery",v=["error","warning","info","success"],w={title:"",text:"",html:"",type:null,animation:!0,allowOutsideClick:!0,allowEscapeKey:!0,showConfirmButton:!0,showCancelButton:!1,closeOnConfirm:!0,closeOnCancel:!0,confirmButtonText:"OK",confirmButtonColor:"#3085d6",cancelButtonColor:"#aaa",cancelButtonText:"Cancel",imageUrl:null,imageSize:null,timer:null,width:500,padding:20},b=function(){return t.querySelector(p)},h=function(){return t.querySelector(y)},C=function(e,t){return new RegExp(" "+t+" ").test(" "+e.className+" ")},k=function(e,t){C(e,t)||(e.className+=" "+t)},x=function(e,t){var n=" "+e.className.replace(/[\t\r\n]/g," ")+" ";if(C(e,t)){for(;n.indexOf(" "+t+" ")>=0;)n=n.replace(" "+t+" "," ");e.className=n.replace(/^\s+|\s+$/g,"")}},B=function(e){var n=t.createElement("div");return n.appendChild(t.createTextNode(e)),n.innerHTML},S=function(e){e.style.opacity="",e.style.display="block"},E=function(e){if(e&&!e.length)return S(e);for(var t=0;t<e.length;++t)S(e[t])},T=function(e){e.style.opacity="",e.style.display="none"},q=function(e){if(e&&!e.length)return T(e);for(var t=0;t<e.length;++t)T(e[t])},O=function(e){e.style.left="-9999px",e.style.display="block";var t,n=e.clientHeight;return t="undefined"!=typeof getComputedStyle?parseInt(getComputedStyle(e).getPropertyValue("padding"),10):parseInt(e.currentStyle.padding),e.style.left="",e.style.display="none","-"+parseInt(n/2+t)+"px"},I=function(e,t){if(+e.style.opacity<1){t=t||16,e.style.opacity=0,e.style.display="block";var n=+new Date,o=function(){e.style.opacity=+e.style.opacity+(new Date-n)/100,n=+new Date,+e.style.opacity<1&&setTimeout(o,t)};o()}e.style.display="block"},M=function(e,t){t=t||16,e.style.opacity=1;var n=+new Date,o=function(){e.style.opacity=+e.style.opacity-(new Date-n)/100,n=+new Date,+e.style.opacity>0?setTimeout(o,t):e.style.display="none"};o()},A=function(n){if(MouseEvent){var o=new MouseEvent("click",{view:e,bubbles:!1,cancelable:!0});n.dispatchEvent(o)}else if(t.createEvent){var a=t.createEvent("MouseEvents");a.initEvent("click",!1,!1),n.dispatchEvent(a)}else t.createEventObject?n.fireEvent("onclick"):"function"==typeof n.onclick&&n.onclick()},L=function(t){"function"==typeof t.stopPropagation?(t.stopPropagation(),t.preventDefault()):e.event&&e.event.hasOwnProperty("cancelBubble")&&(e.event.cancelBubble=!0)};e.sweetAlertInitialize=function(){var e='<div class="sweet-overlay" tabIndex="-1"></div><div class="sweet-alert" tabIndex="-1"><div class="icon error"><span class="x-mark"><span class="line left"></span><span class="line right"></span></span></div><div class="icon warning"> <span class="body"></span> <span class="dot"></span> </div> <div class="icon info"></div> <div class="icon success"> <span class="line tip"></span> <span class="line long"></span> <div class="placeholder"></div> <div class="fix"></div> </div> <div class="icon custom"></div> <h2>Title</h2><p>Text</p><button class="confirm">OK</button><button class="cancel">Cancel</button></div>',n=t.createElement("div");n.innerHTML=e,t.body.appendChild(n)},e.sweetAlert=e.swal=function(){var e=arguments;if(null!==b())n.apply(this,e);else var t=setInterval(function(){null!==b()&&(clearInterval(t),n.apply(this,e))},100)},e.sweetAlert.closeModal=e.swal.closeModal=function(){c()},e.swal.setDefaults=function(e){if(!e)throw new Error("userParams is required");if("object"!=typeof e)throw new Error("userParams has to be a object");r(w,e)},function(){"complete"===t.readyState||"interactive"===t.readyState&&t.body?e.sweetAlertInitialize():t.addEventListener?t.addEventListener("DOMContentLoaded",function n(){t.removeEventListener("DOMContentLoaded",n,!1),e.sweetAlertInitialize()},!1):t.attachEvent&&t.attachEvent("onreadystatechange",function o(){"complete"===t.readyState&&(t.detachEvent("onreadystatechange",o),e.sweetAlertInitialize())})}()}(window,document);
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):e.Sweetalert2=t()}(this,function(){"use strict";function e(){if(void 0===arguments[0])return console.error("sweetAlert2 expects at least 1 attribute!"),!1;var e=c({},H);switch(typeof arguments[0]){case"string":e.title=arguments[0],e.text=arguments[1]||"",e.type=arguments[2]||"";break;case"object":c(e,arguments[0]),e.extraParams=arguments[0].extraParams,"email"===e.input&&null===e.inputValidator&&(e.inputValidator=function(e){return new Promise(function(t,n){var o=/^[a-zA-Z0-9._-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,6}$/;o.test(e)?t():n("Invalid email address")})});break;default:return console.error('Unexpected type of argument! Expected "string" or "object", got '+typeof arguments[0]),!1}N(e);var o=f();return new Promise(function(r,a){function l(e,t){for(var n=0;n<V.length;n++)if(e+=t,e===V.length?e=0:-1===e&&(e=V.length-1),V[e].offsetWidth||V[e].offsetHeight||V[e].getClientRects().length)return void V[e].focus()}function c(n){var o=n||window.event,i=o.keyCode||o.which;if(-1!==[9,13,32,27].indexOf(i)){for(var r=o.target||o.srcElement,c=-1,s=0;s<V.length;s++)if(r===V[s]){c=s;break}9===i?(o.shiftKey?l(c,-1):l(c,1),P(o)):13===i||32===i?-1===c&&T(M,o):27===i&&e.allowEscapeKey===!0&&(t.closeModal(e.onClose),a("esc"))}}e.timer&&(o.timeout=setTimeout(function(){t.closeModal(e.onClose),a("timer")},e.timer));var u=function(){switch(e.input){case"select":return k(o,i.select);case"radio":return o.querySelector("."+i.radio+" input:checked")||o.querySelector("."+i.radio+" input:first-child");case"checkbox":return o.querySelector("#"+i.checkbox);case"textarea":return k(o,i.textarea);default:return k(o,i.input)}},p=function(){var t=u();switch(e.input){case"checkbox":return t.checked?1:0;case"radio":return t.checked?t.value:null;case"file":return t.files.length?t.files[0]:null;default:return e.inputAutoTrim?t.value.trim():t.value}};e.input&&setTimeout(function(){var e=u();e&&g(e)},0);var f,L=function(n){e.showLoaderOnConfirm&&t.showLoading(),e.preConfirm?e.preConfirm(n,e.extraParams).then(function(o){t.closeModal(e.onClose),r(o||n)},function(e){t.hideLoading(),e&&t.showValidationError(e)}):(t.closeModal(e.onClose),r(n))},A=function(n){var i=n||window.event,r=i.target||i.srcElement,l=v(),c=y(),u=l===r||l.contains(r),d=c===r||c.contains(r),f=b(o,"visible");switch(i.type){case"mouseover":case"mouseup":case"focus":e.buttonsStyling&&(u?l.style.backgroundColor=s(e.confirmButtonColor,-.1):d&&(c.style.backgroundColor=s(e.cancelButtonColor,-.1)));break;case"mouseout":case"blur":e.buttonsStyling&&(u?l.style.backgroundColor=e.confirmButtonColor:d&&(c.style.backgroundColor=e.cancelButtonColor));break;case"mousedown":e.buttonsStyling&&(u?l.style.backgroundColor=s(e.confirmButtonColor,-.2):d&&(c.style.backgroundColor=s(e.cancelButtonColor,-.2)));break;case"click":if(u&&f)if(e.input){var m=p();e.inputValidator?(t.disableInput(),e.inputValidator(m,e.extraParams).then(function(){t.enableInput(),L(m)},function(e){t.enableInput(),e&&t.showValidationError(e)})):L(m)}else L(!0);else d&&f&&(t.closeModal(e.onClose),a("cancel"))}},q=o.querySelectorAll("button");for(f=0;f<q.length;f++)q[f].onclick=A,q[f].onmouseover=A,q[f].onmouseout=A,q[f].onmousedown=A;h().onclick=function(){t.closeModal(e.onClose),a("close")},m().onclick=function(){e.allowOutsideClick&&(t.closeModal(e.onClose),a("overlay"))};var M=v(),O=y(),V=[M,O].concat(Array.prototype.slice.call(o.querySelectorAll("button:not([class^="+n+"]), input:not([type=hidden]), textarea, select")));for(f=0;f<V.length;f++)V[f].onfocus=A,V[f].onblur=A;e.reverseButtons&&M.parentNode.insertBefore(O,M),d.previousWindowKeyDown=window.onkeydown,window.onkeydown=c,e.buttonsStyling&&(M.style.borderLeftColor=e.confirmButtonColor,M.style.borderRightColor=e.confirmButtonColor),t.showLoading=t.enableLoading=function(){w(M,"loading"),w(o,"loading"),M.disabled=!0,O.disabled=!0},t.hideLoading=t.disableLoading=function(){C(M,"loading"),C(o,"loading"),M.disabled=!1,O.disabled=!1},t.enableButtons=function(){M.disabled=!1,O.disabled=!1},t.disableButtons=function(){M.disabled=!0,O.disabled=!0},t.enableInput=function(){var e=u();if("radio"===e.type)for(var t=e.parentNode.parentNode,n=t.querySelectorAll("input"),o=0;o<n.length;o++)n[o].disabled=!1;else e.disabled=!1},t.disableInput=function(){var e=u();if("radio"===e.type)for(var t=e.parentNode.parentNode,n=t.querySelectorAll("input"),o=0;o<n.length;o++)n[o].disabled=!0;else e.disabled=!0},t.showValidationError=function(e){var t=o.querySelector("."+i.validationerror);t.innerHTML=e,E(t);var n=u();g(n),w(n,"error")},t.resetValidationError=function(){var e=o.querySelector("."+i.validationerror);B(e);var t=u();t&&C(t,"error")},t.enableButtons(),t.hideLoading(),t.resetValidationError();var H,N=["input","select","radio","checkbox","textarea"];for(f=0;f<N.length;f++){var j=i[N[f]];for(H=k(o,j);H.attributes.length>0;)H.removeAttribute(H.attributes[0].name);for(var K in e.inputAttributes)H.setAttribute(K,e.inputAttributes[K]);H.className=j,e.inputClass&&w(H,e.inputClass),S(H)}var W;switch(e.input){case"text":case"email":case"password":case"file":H=k(o,i.input),H.value=e.inputValue,H.placeholder=e.inputPlaceholder,H.type=e.input,x(H);break;case"select":var U=k(o,i.select);if(U.innerHTML="",e.inputPlaceholder){var z=document.createElement("option");z.innerHTML=e.inputPlaceholder,z.value="",z.disabled=!0,z.selected=!0,U.appendChild(z)}W=function(t){for(var n in t){var o=document.createElement("option");o.value=n,o.innerHTML=t[n],e.inputValue===n&&(o.selected=!0),U.appendChild(o)}x(U),U.focus()};break;case"radio":var R=k(o,i.radio);R.innerHTML="",W=function(t){for(var n in t){var o=1,r=document.createElement("input"),a=document.createElement("label"),l=document.createElement("span");r.type="radio",r.name=i.radio,r.value=n,r.id=i.radio+"-"+o++,e.inputValue===n&&(r.checked=!0),l.innerHTML=t[n],a.appendChild(r),a.appendChild(l),a["for"]=r.id,R.appendChild(a)}x(R);var c=R.querySelectorAll("input");c.length&&c[0].focus()};break;case"checkbox":var Z=k(o,i.checkbox),$=o.querySelector("#"+i.checkbox);$.value=1,$.checked=Boolean(e.inputValue);var _=Z.getElementsByTagName("span");_.length&&Z.removeChild(_[0]),_=document.createElement("span"),_.innerHTML=e.inputPlaceholder,Z.appendChild(_),x(Z);break;case"textarea":var F=k(o,i.textarea);F.value=e.inputValue,F.placeholder=e.inputPlaceholder,x(F);break;case null:break;default:console.error('Unexpected type of input! Expected "text" or "email" or "password", "select", "checkbox", "textarea" or "file", got '+typeof arguments[0])}"select"!==e.input&&"radio"!==e.input||(e.inputOptions instanceof Promise?(t.showLoading(),e.inputOptions.then(function(e){t.hideLoading(),W(e)})):"object"==typeof e.inputOptions?W(e.inputOptions):console.error("Unexpected type of inputOptions! Expected object or Promise, got "+e.inputOptions)),I(),D(e.animation,e.onOpen),l(-1,1)})}function t(){var n=arguments,o=f();return null===o&&(t.init(),o=f()),b(o,"visible")&&V(),e.apply(this,n)}var n="swal2-",o=function(e){var t={};for(var o in e)t[e[o]]=n+e[o];return t},i=o(["container","modal","overlay","close","content","spacer","confirm","cancel","icon","image","input","select","radio","checkbox","textarea","validationerror"]),r=o(["success","warning","info","question","error"]),a={title:"",text:"",html:"",type:null,animation:!0,allowOutsideClick:!0,allowEscapeKey:!0,showConfirmButton:!0,showCancelButton:!1,preConfirm:null,confirmButtonText:"OK",confirmButtonColor:"#3085d6",confirmButtonClass:null,cancelButtonText:"Cancel",cancelButtonColor:"#aaa",cancelButtonClass:null,buttonsStyling:!0,reverseButtons:!1,showCloseButton:!1,showLoaderOnConfirm:!1,imageUrl:null,imageWidth:null,imageHeight:null,imageClass:null,timer:null,width:500,padding:20,background:"#fff",input:null,inputPlaceholder:"",inputValue:"",inputOptions:{},inputAutoTrim:!0,inputClass:null,inputAttributes:{},inputValidator:null,onOpen:null,onClose:null},l='<div class="'+i.overlay+'" tabIndex="-1"></div><div class="'+i.modal+'" style="display: none" tabIndex="-1"><div class="'+i.icon+" "+r.error+'"><span class="x-mark"><span class="line left"></span><span class="line right"></span></span></div><div class="'+i.icon+" "+r.question+'">?</div><div class="'+i.icon+" "+r.warning+'">!</div><div class="'+i.icon+" "+r.info+'">i</div><div class="'+i.icon+" "+r.success+'"><span class="line tip"></span> <span class="line long"></span><div class="placeholder"></div> <div class="fix"></div></div><img class="'+i.image+'"><h2></h2><div class="'+i.content+'"></div><input class="'+i.input+'"><select class="'+i.select+'"></select><div class="'+i.radio+'"></div><label for="'+i.checkbox+'" class="'+i.checkbox+'"><input type="checkbox" id="'+i.checkbox+'"></label><textarea class="'+i.textarea+'"></textarea><div class="'+i.validationerror+'"></div><hr class="'+i.spacer+'"><button class="'+i.confirm+'">OK</button><button class="'+i.cancel+'">Cancel</button><span class="'+i.close+'">×</span></div>',c=function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e},s=function(e,t){e=String(e).replace(/[^0-9a-f]/gi,""),e.length<6&&(e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]),t=t||0;for(var n="#",o=0;3>o;o++){var i=parseInt(e.substr(2*o,2),16);i=Math.round(Math.min(Math.max(0,i+i*t),255)).toString(16),n+=("00"+i).substr(i.length)}return n},u=n+"mediaquery",d={previousWindowKeyDown:null,previousActiveElement:null},p=function(e){return document.querySelector("."+e)},f=function(){return p(i.modal)},m=function(){return p(i.overlay)},v=function(){return p(i.confirm)},y=function(){return p(i.cancel)},h=function(){return p(i.close)},b=function(e,t){return e.classList.contains(t)},g=function(e){e.focus();var t=e.value;e.value="",e.value=t},w=function(e,t){if(e&&t){var n=t.split(/\s+/);for(var o in n)e.classList.add(n[o])}},C=function(e,t){if(e&&t){var n=t.split(/\s+/);for(var o in n)e.classList.remove(n[o])}},k=function(e,t){for(var n=0;n<e.childNodes.length;n++)if(b(e.childNodes[n],t))return e.childNodes[n]},x=function(e){e.style.opacity="",e.style.display="block"},E=function(e){if(e&&!e.length)return x(e);for(var t=0;t<e.length;++t)x(e[t])},S=function(e){e.style.opacity="",e.style.display="none"},B=function(e){if(e&&!e.length)return S(e);for(var t=0;t<e.length;++t)S(e[t])},L=function(e,t){e.style.removeProperty?e.style.removeProperty(t):e.style.removeAttribute(t)},A=function(e){var t=e.style.display;e.style.left="-9999px",e.style.display="block";var n=e.clientHeight;return e.style.left="",e.style.display=t,"-"+parseInt(n/2,10)+"px"},q=function(e,t){if(+e.style.opacity<1){t=t||16,e.style.opacity=0,e.style.display="block";var n=+new Date,o=function(){var i=+e.style.opacity+(new Date-n)/100;e.style.opacity=i>1?1:i,n=+new Date,+e.style.opacity<1&&setTimeout(o,t)};o()}},M=function(e,t){if(+e.style.opacity>0){t=t||16;var n=e.style.opacity,o=+new Date,i=function(){var r=new Date-o,a=+e.style.opacity-r/(100*n);e.style.opacity=a,o=+new Date,+e.style.opacity>0?setTimeout(i,t):S(e)};i()}},T=function(e){if("function"==typeof MouseEvent){var t=new MouseEvent("click",{view:window,bubbles:!1,cancelable:!0});e.dispatchEvent(t)}else if(document.createEvent){var n=document.createEvent("MouseEvents");n.initEvent("click",!1,!1),e.dispatchEvent(n)}else document.createEventObject?e.fireEvent("onclick"):"function"==typeof e.onclick&&e.onclick()},P=function(e){"function"==typeof e.stopPropagation?(e.stopPropagation(),e.preventDefault()):window.event&&window.event.hasOwnProperty("cancelBubble")&&(window.event.cancelBubble=!0)},O=function(){var e=document.createElement("div"),t={WebkitAnimation:"webkitAnimationEnd",MozAnimation:"animationend",OAnimation:"oAnimationEnd oanimationend",msAnimation:"MSAnimationEnd",animation:"animationend"};for(var n in t)if(t.hasOwnProperty(n)&&void 0!==e.style[n])return t[n];return!1}(),V=function(){var e=f();window.onkeydown=d.previousWindowKeyDown,d.previousActiveElement&&d.previousActiveElement.focus(),clearTimeout(e.timeout);var t=document.getElementsByTagName("head")[0],n=document.getElementById(u);n&&t.removeChild(n)},H=c({},a),N=function(e){var t,n=f();n.style.width=e.width+"px",n.style.padding=e.padding+"px",n.style.marginLeft=-e.width/2+"px",n.style.background=e.background;var o=document.getElementsByTagName("head")[0],a=document.createElement("style");a.type="text/css",a.id=u;var l=5,c=e.width+parseInt(e.width*(l/100)*2,10);a.innerHTML="@media screen and (max-width: "+c+"px) {."+i.modal+" {width: auto !important;left: "+l+"% !important;right: "+l+"% !important;margin-left: 0 !important;}}",o.appendChild(a);var s=n.querySelector("h2"),d=n.querySelector("."+i.content),p=v(),m=y(),h=n.querySelector("."+i.spacer),b=n.querySelector("."+i.close);if(s.innerHTML=e.title.split("\n").join("<br>"),e.text||e.html){if("object"==typeof e.html)if(d.innerHTML="",0 in e.html)for(t=0;t in e.html;t++)d.appendChild(e.html[t]);else d.appendChild(e.html);else d.innerHTML=e.html||e.text.split("\n").join("<br>");E(d)}else B(d);if(e.showCloseButton?E(b):B(b),n.className=i.modal,e.customClass&&w(n,e.customClass),B(n.querySelectorAll("."+i.icon)),e.type){var g=!1;for(var k in r)if(e.type===k){g=!0;break}if(!g)return console.error("Unknown alert type: "+e.type),!1;var x=n.querySelector("."+i.icon+"."+r[e.type]);switch(E(x),e.type){case"success":w(x,"animate"),w(x.querySelector(".tip"),"animate-success-tip"),w(x.querySelector(".long"),"animate-success-long");break;case"error":w(x,"animate-error-icon"),w(x.querySelector(".x-mark"),"animate-x-mark");break;case"warning":w(x,"pulse-warning")}}var S=n.querySelector("."+i.image);e.imageUrl?(S.setAttribute("src",e.imageUrl),E(S),e.imageWidth?S.setAttribute("width",e.imageWidth):S.removeAttribute("width"),e.imageHeight?S.setAttribute("height",e.imageHeight):S.removeAttribute("height"),e.imageClass&&w(S,e.imageClass)):B(S),e.showCancelButton?m.style.display="inline-block":B(m),e.showConfirmButton?L(p,"display"):B(p),e.showConfirmButton||e.showCancelButton?E(h):B(h),p.innerHTML=e.confirmButtonText,m.innerHTML=e.cancelButtonText,e.buttonsStyling&&(p.style.backgroundColor=e.confirmButtonColor,m.style.backgroundColor=e.cancelButtonColor),p.className=i.confirm,w(p,e.confirmButtonClass),m.className=i.cancel,w(m,e.cancelButtonClass),e.buttonsStyling?(w(p,"styled"),w(m,"styled")):(C(p,"styled"),C(m,"styled"),p.style.backgroundColor=p.style.borderLeftColor=p.style.borderRightColor="",m.style.backgroundColor=m.style.borderLeftColor=m.style.borderRightColor=""),e.animation===!0?C(n,"no-animation"):w(n,"no-animation")},D=function(e,t){var n=f();e?(q(m(),10),w(n,"show-swal2"),C(n,"hide-swal2")):E(m()),E(n),d.previousActiveElement=document.activeElement,w(n,"visible"),null!==t&&"function"==typeof t&&t.call(this,n)},I=function(){var e=f();e.style.marginTop=A(e)};return t.queue=function(e){return new Promise(function(n,o){!function i(r,a){r<e.length?t(e[r]).then(function(){i(r+1,a)},function(e){o(e)}):n()}(0)})},t.close=t.closeModal=function(e){var t=f();C(t,"show-swal2"),w(t,"hide-swal2"),C(t,"visible");var n=t.querySelector("."+i.icon+"."+r.success);C(n,"animate"),C(n.querySelector(".tip"),"animate-success-tip"),C(n.querySelector(".long"),"animate-success-long");var o=t.querySelector("."+i.icon+"."+r.error);C(o,"animate-error-icon"),C(o.querySelector(".x-mark"),"animate-x-mark");var a=t.querySelector("."+i.icon+"."+r.warning);C(a,"pulse-warning"),V(),O&&!b(t,"no-animation")?t.addEventListener(O,function l(){t.removeEventListener(O,l),b(t,"hide-swal2")&&(S(t),M(m(),0))}):(S(t),S(m())),null!==e&&"function"==typeof e&&e.call(this,t)},t.clickConfirm=function(){v().click()},t.clickCancel=function(){y().click()},t.init=function(){if("undefined"==typeof document)return void console.log("SweetAlert2 requires document to initialize");if(!document.getElementsByClassName(i.container).length){var e=document.createElement("div");e.className=i.container,e.innerHTML=l,document.body.appendChild(e);var n=f(),o=k(n,i.input),r=k(n,i.select),a=n.querySelector("#"+i.checkbox),c=k(n,i.textarea);o.oninput=function(){t.resetValidationError()},o.onkeyup=function(e){e.stopPropagation(),13===e.keyCode&&t.clickConfirm()},r.onchange=function(){t.resetValidationError()},a.onchange=function(){t.resetValidationError()},c.oninput=function(){t.resetValidationError()},window.addEventListener("resize",I,!1)}},t.setDefaults=function(e){if(!e)throw new Error("userParams is required");if("object"!=typeof e)throw new Error("userParams has to be a object");c(H,e)},t.resetDefaults=function(){H=c({},a)},t.version="4.0.11",window.sweetAlert=window.swal=t,function(){"complete"===document.readyState||"interactive"===document.readyState&&document.body?t.init():document.addEventListener("DOMContentLoaded",function e(){document.removeEventListener("DOMContentLoaded",e,!1),t.init()},!1)}(),"function"==typeof Promise&&(Promise.prototype.done=function(){return this["catch"](function(){})}),t});
|
@@ -1,3 +1,3 @@
|
|
1
1
|
/*
|
2
|
-
*= require ./sweetalert2
|
3
|
-
*/
|
2
|
+
*= require ./sweetalert2.min
|
3
|
+
*/
|
@@ -0,0 +1 @@
|
|
1
|
+
.swal2-modal,.swal2-overlay{position:fixed;display:none}.swal2-overlay{background-color:rgba(0,0,0,.4);left:0;right:0;top:0;bottom:0;z-index:1000}.swal2-modal{background-color:#fff;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;border-radius:5px;box-sizing:border-box;text-align:center;left:50%;top:50%;margin-top:-200px;max-height:90%;overflow-x:hidden;overflow-y:auto;z-index:2000}.swal2-modal:focus{outline:0}.swal2-modal.loading{overflow-y:hidden}.swal2-modal h2{color:#575757;font-size:30px;text-align:center;font-weight:600;text-transform:none;position:relative;margin:0;padding:0;line-height:60px;display:block}.swal2-modal hr{height:10px;color:transparent;border:0}.swal2-modal button.styled{color:#fff;border:0;box-shadow:none;font-size:17px;font-weight:500;border-radius:5px;padding:10px 32px;margin:0 5px;cursor:pointer}.swal2-content,.swal2-icon{padding:0;position:relative}.swal2-modal button.styled:focus{outline:0}.swal2-modal button.styled:not(.loading)[disabled]{opacity:.4;cursor:no-drop}.swal2-modal button.styled.loading{box-sizing:border-box;border:4px solid transparent;width:40px;height:40px;padding:0;margin:-2px 30px;vertical-align:top;background-color:transparent!important;color:transparent;cursor:default;border-radius:100%;-webkit-animation:rotate-loading 1.5s linear 0s infinite normal;animation:rotate-loading 1.5s linear 0s infinite normal}.swal2-modal button.styled::-moz-focus-inner{border:0}.swal2-modal button:not(.styled).loading:after{display:inline-block;content:"";margin-left:5px;vertical-align:-1px;height:6px;width:6px;border:3px solid #999;border-right-color:transparent;border-radius:50%;-webkit-animation:rotate-loading 1.5s linear 0s infinite normal;animation:rotate-loading 1.5s linear 0s infinite normal}.swal2-checkbox input,.swal2-checkbox span,.swal2-radio input,.swal2-radio span{vertical-align:middle}.swal2-modal .swal2-image{margin:20px auto;max-width:100%}.swal2-modal .swal2-close{font-size:36px;line-height:36px;font-family:serif;position:absolute;top:5px;right:13px;cursor:pointer;color:#cfcfcf;-webkit-transition:all .1s ease;transition:all .1s ease}.swal2-modal .swal2-close:hover{color:#d55}.swal2-modal>.swal2-checkbox,.swal2-modal>.swal2-input,.swal2-modal>.swal2-radio,.swal2-modal>.swal2-select,.swal2-modal>.swal2-textarea{display:none}.swal2-content{font-size:18px;text-align:center;font-weight:300;float:none;margin:0;line-height:normal;color:#555}.swal2-icon.swal2-info,.swal2-icon.swal2-question,.swal2-icon.swal2-warning{font-size:60px;line-height:80px;text-align:center}.swal2-icon{width:80px;height:80px;border:4px solid grey;border-radius:50%;margin:20px auto 30px;box-sizing:content-box;cursor:default;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.swal2-icon.swal2-error{border-color:#f27474}.swal2-icon.swal2-error .x-mark{position:relative;display:block}.swal2-icon.swal2-error .line{position:absolute;height:5px;width:47px;background-color:#f27474;display:block;top:37px;border-radius:2px}.swal2-icon.swal2-error .line.left{-webkit-transform:rotate(45deg);transform:rotate(45deg);left:17px}.swal2-icon.swal2-error .line.right{-webkit-transform:rotate(-45deg);transform:rotate(-45deg);right:16px}.swal2-icon.swal2-warning{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;color:#f8bb86;border-color:#f8bb86}.swal2-icon.swal2-info{font-family:"Open Sans",sans-serif;color:#3fc3ee;border-color:#3fc3ee}.swal2-icon.swal2-question{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;color:#c9dae1;border-color:#c9dae1}.swal2-icon.swal2-success{border-color:#a5dc86}.swal2-icon.swal2-success::after,.swal2-icon.swal2-success::before{content:'';position:absolute;width:60px;height:120px;background:#fff}.swal2-icon.swal2-success::before{border-radius:120px 0 0 120px;top:-7px;left:-33px;-webkit-transform:rotate(-45deg);transform:rotate(-45deg);-webkit-transform-origin:60px 60px;transform-origin:60px 60px}.swal2-icon.swal2-success::after{border-radius:0 120px 120px 0;top:-11px;left:30px;-webkit-transform:rotate(-45deg);transform:rotate(-45deg);-webkit-transform-origin:0 60px;transform-origin:0 60px}.swal2-icon.swal2-success .placeholder{width:80px;height:80px;border:4px solid rgba(165,220,134,.2);border-radius:50%;box-sizing:content-box;position:absolute;left:-4px;top:-4px;z-index:2}.swal2-icon.swal2-success .fix{width:7px;height:90px;background-color:#fff;position:absolute;left:28px;top:8px;z-index:1;-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}.swal2-icon.swal2-success .line{height:5px;background-color:#a5dc86;display:block;border-radius:2px;position:absolute;z-index:2}.swal2-icon.swal2-success .line.tip{width:25px;left:14px;top:46px;-webkit-transform:rotate(45deg);transform:rotate(45deg)}.swal2-icon.swal2-success .line.long{width:47px;right:8px;top:38px;-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}.swal2-checkbox,.swal2-input,.swal2-radio,.swal2-select,.swal2-textarea{margin:20px auto}.swal2-input:not([type=file]),.swal2-textarea{width:100%;box-sizing:border-box;border-radius:3px;border:1px solid #d7d7d7;font-size:18px;box-shadow:inset 0 1px 1px rgba(0,0,0,.06);-webkit-transition:all .3s;transition:all .3s}.swal2-input:not([type=file]).error,.swal2-textarea.error{border-color:#f06e57!important}.swal2-input:not([type=file]):focus,.swal2-textarea:focus{outline:0;box-shadow:0 0 3px #c4e6f5;border:1px solid #b4dbed}.swal2-input:not([type=file]):focus::-moz-placeholder,.swal2-textarea:focus::-moz-placeholder{-webkit-transition:opacity .3s 30ms ease;transition:opacity .3s 30ms ease;opacity:.8}.swal2-input:not([type=file]):focus:-ms-input-placeholder,.swal2-textarea:focus:-ms-input-placeholder{-webkit-transition:opacity .3s 30ms ease;transition:opacity .3s 30ms ease;opacity:.8}.swal2-input:not([type=file]):focus::-webkit-input-placeholder,.swal2-textarea:focus::-webkit-input-placeholder{-webkit-transition:opacity .3s 30ms ease;transition:opacity .3s 30ms ease;opacity:.8}.swal2-input:not([type=file])::-moz-placeholder,.swal2-textarea::-moz-placeholder{color:#bdbdbd}.swal2-input:not([type=file]):-ms-input-placeholder,.swal2-textarea:-ms-input-placeholder{color:#bdbdbd}.swal2-input:not([type=file])::-webkit-input-placeholder,.swal2-textarea::-webkit-input-placeholder{color:#bdbdbd}.swal2-input:not([type=file]){height:43px;padding:0 12px}.swal2-input[type=file]{font-size:20px}.swal2-textarea{height:108px;padding:12px}.swal2-select{color:#555;font-size:inherit;padding:5px 10px;min-width:40%;max-width:100%}.swal2-radio{border:0}.swal2-radio label:not(:first-child){margin-left:20px}.swal2-radio input{margin:0 3px 0 0}.swal2-checkbox{color:#555}.swal2-validationerror{background-color:#f1f1f1;margin:0 -20px;overflow:hidden;padding:10px;color:#797979;font-size:16px;font-weight:300;display:none}.swal2-validationerror::before{content:"!";display:inline-block;width:24px;height:24px;border-radius:50%;background-color:#ea7d7d;color:#fff;line-height:24px;text-align:center;margin-right:10px}@-webkit-keyframes showSweetAlert{0%{-webkit-transform:scale(.7);transform:scale(.7)}45%{-webkit-transform:scale(1.05);transform:scale(1.05)}80%{-webkit-transform:scale(.95);transform:scale(.95)}100%{-webkit-transform:scale(1);transform:scale(1)}}@keyframes showSweetAlert{0%{-webkit-transform:scale(.7);transform:scale(.7)}45%{-webkit-transform:scale(1.05);transform:scale(1.05)}80%{-webkit-transform:scale(.95);transform:scale(.95)}100%{-webkit-transform:scale(1);transform:scale(1)}}@-webkit-keyframes hideSweetAlert{0%{-webkit-transform:scale(1);transform:scale(1);opacity:1}100%{-webkit-transform:scale(.5);transform:scale(.5);opacity:0}}@keyframes hideSweetAlert{0%{-webkit-transform:scale(1);transform:scale(1);opacity:1}100%{-webkit-transform:scale(.5);transform:scale(.5);opacity:0}}.show-swal2{-webkit-animation:showSweetAlert .3s;animation:showSweetAlert .3s}.show-swal2.no-animation{-webkit-animation:none;animation:none}.hide-swal2{-webkit-animation:hideSweetAlert .15s;animation:hideSweetAlert .15s}.hide-swal2.no-animation{-webkit-animation:none;animation:none}@-webkit-keyframes animate-success-tip{0%,54%{width:0;left:1px;top:19px}70%{width:50px;left:-8px;top:37px}84%{width:17px;left:21px;top:48px}100%{width:25px;left:14px;top:45px}}@keyframes animate-success-tip{0%,54%{width:0;left:1px;top:19px}70%{width:50px;left:-8px;top:37px}84%{width:17px;left:21px;top:48px}100%{width:25px;left:14px;top:45px}}@-webkit-keyframes animate-success-long{0%,65%{width:0;right:46px;top:54px}84%{width:55px;right:0;top:35px}100%{width:47px;right:8px;top:38px}}@keyframes animate-success-long{0%,65%{width:0;right:46px;top:54px}84%{width:55px;right:0;top:35px}100%{width:47px;right:8px;top:38px}}@-webkit-keyframes rotatePlaceholder{0%,5%{-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}100%,12%{-webkit-transform:rotate(-405deg);transform:rotate(-405deg)}}@keyframes rotatePlaceholder{0%,5%{-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}100%,12%{-webkit-transform:rotate(-405deg);transform:rotate(-405deg)}}.animate-success-tip{-webkit-animation:animate-success-tip .75s;animation:animate-success-tip .75s}.animate-success-long{-webkit-animation:animate-success-long .75s;animation:animate-success-long .75s}.swal2-icon.swal2-success.animate::after{-webkit-animation:rotatePlaceholder 4.25s ease-in;animation:rotatePlaceholder 4.25s ease-in}@-webkit-keyframes animate-error-icon{0%{-webkit-transform:rotateX(100deg);transform:rotateX(100deg);opacity:0}100%{-webkit-transform:rotateX(0);transform:rotateX(0);opacity:1}}@keyframes animate-error-icon{0%{-webkit-transform:rotateX(100deg);transform:rotateX(100deg);opacity:0}100%{-webkit-transform:rotateX(0);transform:rotateX(0);opacity:1}}.animate-error-icon{-webkit-animation:animate-error-icon .5s;animation:animate-error-icon .5s}@-webkit-keyframes animate-x-mark{0%,50%{-webkit-transform:scale(.4);transform:scale(.4);margin-top:26px;opacity:0}80%{-webkit-transform:scale(1.15);transform:scale(1.15);margin-top:-6px}100%{-webkit-transform:scale(1);transform:scale(1);margin-top:0;opacity:1}}@keyframes animate-x-mark{0%,50%{-webkit-transform:scale(.4);transform:scale(.4);margin-top:26px;opacity:0}80%{-webkit-transform:scale(1.15);transform:scale(1.15);margin-top:-6px}100%{-webkit-transform:scale(1);transform:scale(1);margin-top:0;opacity:1}}.animate-x-mark{-webkit-animation:animate-x-mark .5s;animation:animate-x-mark .5s}@-webkit-keyframes pulse-warning{0%{border-color:#f8d486}100%{border-color:#f8bb86}}@keyframes pulse-warning{0%{border-color:#f8d486}100%{border-color:#f8bb86}}.pulse-warning{-webkit-animation:pulse-warning .75s infinite alternate;animation:pulse-warning .75s infinite alternate}@-webkit-keyframes rotate-loading{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes rotate-loading{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}
|
data/lib/sweetalert2/version.rb
CHANGED
data/sweetalert2.gemspec
CHANGED
@@ -9,7 +9,7 @@ Gem::Specification.new do |spec|
|
|
9
9
|
spec.authors = ["Kyle Montag"]
|
10
10
|
spec.email = ["thekylemontag@gmail.com"]
|
11
11
|
spec.summary = %q{SweetAlert 2 for Rails projects}
|
12
|
-
spec.homepage = "
|
12
|
+
spec.homepage = "https://github.com/KMontag42/sweetalert2-rails"
|
13
13
|
spec.license = "MIT"
|
14
14
|
|
15
15
|
spec.files = `git ls-files`.split($/)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sweetalert2
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 4.0.11
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kyle Montag
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-07-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: railties
|
@@ -67,12 +67,12 @@ files:
|
|
67
67
|
- app/assets/javascripts/sweetalert2/index.js
|
68
68
|
- app/assets/javascripts/sweetalert2/sweetalert2.min.js
|
69
69
|
- app/assets/stylesheets/sweetalert2/index.css
|
70
|
-
- app/assets/stylesheets/sweetalert2/sweetalert2.css
|
70
|
+
- app/assets/stylesheets/sweetalert2/sweetalert2.min.css
|
71
71
|
- lib/sweetalert2.rb
|
72
72
|
- lib/sweetalert2/engine.rb
|
73
73
|
- lib/sweetalert2/version.rb
|
74
74
|
- sweetalert2.gemspec
|
75
|
-
homepage:
|
75
|
+
homepage: https://github.com/KMontag42/sweetalert2-rails
|
76
76
|
licenses:
|
77
77
|
- MIT
|
78
78
|
metadata: {}
|
@@ -92,7 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
92
92
|
version: '0'
|
93
93
|
requirements: []
|
94
94
|
rubyforge_project:
|
95
|
-
rubygems_version: 2.
|
95
|
+
rubygems_version: 2.5.1
|
96
96
|
signing_key:
|
97
97
|
specification_version: 4
|
98
98
|
summary: SweetAlert 2 for Rails projects
|
@@ -1,534 +0,0 @@
|
|
1
|
-
.sweet-overlay {
|
2
|
-
background-color: rgba(0, 0, 0, 0.4);
|
3
|
-
position: fixed;
|
4
|
-
left: 0;
|
5
|
-
right: 0;
|
6
|
-
top: 0;
|
7
|
-
bottom: 0;
|
8
|
-
display: none;
|
9
|
-
z-index: 1000; }
|
10
|
-
|
11
|
-
.sweet-alert {
|
12
|
-
background-color: #fff;
|
13
|
-
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
|
14
|
-
border-radius: 5px;
|
15
|
-
box-sizing: border-box;
|
16
|
-
text-align: center;
|
17
|
-
position: fixed;
|
18
|
-
left: 50%;
|
19
|
-
top: 50%;
|
20
|
-
margin-top: -200px;
|
21
|
-
overflow: hidden;
|
22
|
-
display: none;
|
23
|
-
z-index: 2000; }
|
24
|
-
.sweet-alert h2 {
|
25
|
-
color: #575757;
|
26
|
-
font-size: 30px;
|
27
|
-
text-align: center;
|
28
|
-
font-weight: 600;
|
29
|
-
text-transform: none;
|
30
|
-
position: relative;
|
31
|
-
margin: 0;
|
32
|
-
padding: 0;
|
33
|
-
line-height: 60px;
|
34
|
-
display: block; }
|
35
|
-
.sweet-alert p {
|
36
|
-
font-size: 16px;
|
37
|
-
text-align: center;
|
38
|
-
font-weight: 300;
|
39
|
-
position: relative;
|
40
|
-
float: none;
|
41
|
-
margin: 0;
|
42
|
-
padding: 0;
|
43
|
-
line-height: normal; }
|
44
|
-
.sweet-alert button {
|
45
|
-
color: #fff;
|
46
|
-
border: 0;
|
47
|
-
box-shadow: none;
|
48
|
-
font-size: 17px;
|
49
|
-
font-weight: 500;
|
50
|
-
border-radius: 5px;
|
51
|
-
padding: 10px 32px;
|
52
|
-
margin: 26px 5px 0;
|
53
|
-
cursor: pointer; }
|
54
|
-
.sweet-alert button:focus {
|
55
|
-
outline: none; }
|
56
|
-
.sweet-alert button[disabled] {
|
57
|
-
opacity: 0.4; }
|
58
|
-
.sweet-alert button::-moz-focus-inner {
|
59
|
-
border: 0; }
|
60
|
-
.sweet-alert[data-has-cancel-button=false] button {
|
61
|
-
box-shadow: none !important; }
|
62
|
-
.sweet-alert .icon {
|
63
|
-
width: 80px;
|
64
|
-
height: 80px;
|
65
|
-
border: 4px solid #808080;
|
66
|
-
border-radius: 50%;
|
67
|
-
margin: 20px auto;
|
68
|
-
padding: 0;
|
69
|
-
position: relative;
|
70
|
-
box-sizing: content-box; }
|
71
|
-
.sweet-alert .icon.error {
|
72
|
-
border-color: #f27474; }
|
73
|
-
.sweet-alert .icon.error .x-mark {
|
74
|
-
position: relative;
|
75
|
-
display: block; }
|
76
|
-
.sweet-alert .icon.error .line {
|
77
|
-
position: absolute;
|
78
|
-
height: 5px;
|
79
|
-
width: 47px;
|
80
|
-
background-color: #f27474;
|
81
|
-
display: block;
|
82
|
-
top: 37px;
|
83
|
-
border-radius: 2px; }
|
84
|
-
.sweet-alert .icon.error .line.left {
|
85
|
-
-webkit-transform: rotate(45deg);
|
86
|
-
-ms-transform: rotate(45deg);
|
87
|
-
transform: rotate(45deg);
|
88
|
-
left: 17px; }
|
89
|
-
.sweet-alert .icon.error .line.right {
|
90
|
-
-webkit-transform: rotate(-45deg);
|
91
|
-
-ms-transform: rotate(-45deg);
|
92
|
-
transform: rotate(-45deg);
|
93
|
-
right: 16px; }
|
94
|
-
.sweet-alert .icon.warning {
|
95
|
-
border-color: #f8bb86; }
|
96
|
-
.sweet-alert .icon.warning .body {
|
97
|
-
position: absolute;
|
98
|
-
width: 5px;
|
99
|
-
height: 47px;
|
100
|
-
left: 50%;
|
101
|
-
top: 10px;
|
102
|
-
border-radius: 2px;
|
103
|
-
margin-left: -2px;
|
104
|
-
background-color: #f8bb86; }
|
105
|
-
.sweet-alert .icon.warning .dot {
|
106
|
-
position: absolute;
|
107
|
-
width: 7px;
|
108
|
-
height: 7px;
|
109
|
-
border-radius: 50%;
|
110
|
-
margin-left: -3px;
|
111
|
-
left: 50%;
|
112
|
-
bottom: 10px;
|
113
|
-
background-color: #f8bb86; }
|
114
|
-
.sweet-alert .icon.info {
|
115
|
-
border-color: #c9dae1; }
|
116
|
-
.sweet-alert .icon.info::before {
|
117
|
-
content: '';
|
118
|
-
position: absolute;
|
119
|
-
width: 5px;
|
120
|
-
height: 29px;
|
121
|
-
left: 50%;
|
122
|
-
bottom: 17px;
|
123
|
-
border-radius: 2px;
|
124
|
-
margin-left: -2px;
|
125
|
-
background-color: #c9dae1; }
|
126
|
-
.sweet-alert .icon.info::after {
|
127
|
-
content: '';
|
128
|
-
position: absolute;
|
129
|
-
width: 7px;
|
130
|
-
height: 7px;
|
131
|
-
border-radius: 50%;
|
132
|
-
margin-left: -3px;
|
133
|
-
top: 19px;
|
134
|
-
background-color: #c9dae1; }
|
135
|
-
.sweet-alert .icon.success {
|
136
|
-
border-color: #a5dc86; }
|
137
|
-
.sweet-alert .icon.success::before, .sweet-alert .icon.success::after {
|
138
|
-
content: '';
|
139
|
-
border-radius: 50%;
|
140
|
-
position: absolute;
|
141
|
-
width: 60px;
|
142
|
-
height: 120px;
|
143
|
-
background: #fff;
|
144
|
-
-webkit-transform: rotate(45deg);
|
145
|
-
-ms-transform: rotate(45deg);
|
146
|
-
transform: rotate(45deg); }
|
147
|
-
.sweet-alert .icon.success::before {
|
148
|
-
border-radius: 120px 0 0 120px;
|
149
|
-
top: -7px;
|
150
|
-
left: -33px;
|
151
|
-
-webkit-transform: rotate(-45deg);
|
152
|
-
-ms-transform: rotate(-45deg);
|
153
|
-
transform: rotate(-45deg);
|
154
|
-
-webkit-transform-origin: 60px 60px;
|
155
|
-
-ms-transform-origin: 60px 60px;
|
156
|
-
transform-origin: 60px 60px; }
|
157
|
-
.sweet-alert .icon.success::after {
|
158
|
-
border-radius: 0 120px 120px 0;
|
159
|
-
top: -11px;
|
160
|
-
left: 30px;
|
161
|
-
-webkit-transform: rotate(-45deg);
|
162
|
-
-ms-transform: rotate(-45deg);
|
163
|
-
transform: rotate(-45deg);
|
164
|
-
-webkit-transform-origin: 0 60px;
|
165
|
-
-ms-transform-origin: 0 60px;
|
166
|
-
transform-origin: 0 60px; }
|
167
|
-
.sweet-alert .icon.success .placeholder {
|
168
|
-
width: 80px;
|
169
|
-
height: 80px;
|
170
|
-
border: 4px solid rgba(165, 220, 134, 0.2);
|
171
|
-
border-radius: 50%;
|
172
|
-
box-sizing: content-box;
|
173
|
-
position: absolute;
|
174
|
-
left: -4px;
|
175
|
-
top: -4px;
|
176
|
-
z-index: 2; }
|
177
|
-
.sweet-alert .icon.success .fix {
|
178
|
-
width: 5px;
|
179
|
-
height: 90px;
|
180
|
-
background-color: #fff;
|
181
|
-
position: absolute;
|
182
|
-
left: 28px;
|
183
|
-
top: 8px;
|
184
|
-
z-index: 1;
|
185
|
-
-webkit-transform: rotate(-45deg);
|
186
|
-
-ms-transform: rotate(-45deg);
|
187
|
-
transform: rotate(-45deg); }
|
188
|
-
.sweet-alert .icon.success .line {
|
189
|
-
height: 5px;
|
190
|
-
background-color: #a5dc86;
|
191
|
-
display: block;
|
192
|
-
border-radius: 2px;
|
193
|
-
position: absolute;
|
194
|
-
z-index: 2; }
|
195
|
-
.sweet-alert .icon.success .line.tip {
|
196
|
-
width: 25px;
|
197
|
-
left: 14px;
|
198
|
-
top: 46px;
|
199
|
-
-webkit-transform: rotate(45deg);
|
200
|
-
-ms-transform: rotate(45deg);
|
201
|
-
transform: rotate(45deg); }
|
202
|
-
.sweet-alert .icon.success .line.long {
|
203
|
-
width: 47px;
|
204
|
-
right: 8px;
|
205
|
-
top: 38px;
|
206
|
-
-webkit-transform: rotate(-45deg);
|
207
|
-
-ms-transform: rotate(-45deg);
|
208
|
-
transform: rotate(-45deg); }
|
209
|
-
.sweet-alert .icon.custom {
|
210
|
-
background-size: contain;
|
211
|
-
border-radius: 0;
|
212
|
-
border: 0;
|
213
|
-
background-position: center center;
|
214
|
-
background-repeat: no-repeat; }
|
215
|
-
|
216
|
-
@-webkit-keyframes showSweetAlert {
|
217
|
-
0% {
|
218
|
-
-webkit-transform: scale(0.7);
|
219
|
-
transform: scale(0.7); }
|
220
|
-
|
221
|
-
45% {
|
222
|
-
-webkit-transform: scale(1.05);
|
223
|
-
transform: scale(1.05); }
|
224
|
-
|
225
|
-
80% {
|
226
|
-
-webkit-transform: scale(0.95);
|
227
|
-
transform: scale(0.95); }
|
228
|
-
|
229
|
-
100% {
|
230
|
-
-webkit-transform: scale(1);
|
231
|
-
transform: scale(1); } }
|
232
|
-
|
233
|
-
@keyframes showSweetAlert {
|
234
|
-
0% {
|
235
|
-
-webkit-transform: scale(0.7);
|
236
|
-
transform: scale(0.7); }
|
237
|
-
|
238
|
-
45% {
|
239
|
-
-webkit-transform: scale(1.05);
|
240
|
-
transform: scale(1.05); }
|
241
|
-
|
242
|
-
80% {
|
243
|
-
-webkit-transform: scale(0.95);
|
244
|
-
transform: scale(0.95); }
|
245
|
-
|
246
|
-
100% {
|
247
|
-
-webkit-transform: scale(1);
|
248
|
-
transform: scale(1); } }
|
249
|
-
|
250
|
-
@-webkit-keyframes hideSweetAlert {
|
251
|
-
0% {
|
252
|
-
-webkit-transform: scale(1);
|
253
|
-
transform: scale(1); }
|
254
|
-
|
255
|
-
100% {
|
256
|
-
-webkit-transform: scale(0.5);
|
257
|
-
transform: scale(0.5); } }
|
258
|
-
|
259
|
-
@keyframes hideSweetAlert {
|
260
|
-
0% {
|
261
|
-
-webkit-transform: scale(1);
|
262
|
-
transform: scale(1); }
|
263
|
-
|
264
|
-
100% {
|
265
|
-
-webkit-transform: scale(0.5);
|
266
|
-
transform: scale(0.5); } }
|
267
|
-
|
268
|
-
.show-sweet-alert {
|
269
|
-
-webkit-animation: showSweetAlert 0.3s;
|
270
|
-
animation: showSweetAlert 0.3s; }
|
271
|
-
.show-sweet-alert.no-animation {
|
272
|
-
-webkit-animation: none;
|
273
|
-
animation: none; }
|
274
|
-
|
275
|
-
.hide-sweet-alert {
|
276
|
-
-webkit-animation: hideSweetAlert 0.2s;
|
277
|
-
animation: hideSweetAlert 0.2s; }
|
278
|
-
.hide-sweet-alert.no-animation {
|
279
|
-
-webkit-animation: none;
|
280
|
-
animation: none; }
|
281
|
-
|
282
|
-
@-webkit-keyframes animate-success-tip {
|
283
|
-
0% {
|
284
|
-
width: 0;
|
285
|
-
left: 1px;
|
286
|
-
top: 19px; }
|
287
|
-
|
288
|
-
54% {
|
289
|
-
width: 0;
|
290
|
-
left: 1px;
|
291
|
-
top: 19px; }
|
292
|
-
|
293
|
-
70% {
|
294
|
-
width: 50px;
|
295
|
-
left: -8px;
|
296
|
-
top: 37px; }
|
297
|
-
|
298
|
-
84% {
|
299
|
-
width: 17px;
|
300
|
-
left: 21px;
|
301
|
-
top: 48px; }
|
302
|
-
|
303
|
-
100% {
|
304
|
-
width: 25px;
|
305
|
-
left: 14px;
|
306
|
-
top: 45px; } }
|
307
|
-
|
308
|
-
@keyframes animate-success-tip {
|
309
|
-
0% {
|
310
|
-
width: 0;
|
311
|
-
left: 1px;
|
312
|
-
top: 19px; }
|
313
|
-
|
314
|
-
54% {
|
315
|
-
width: 0;
|
316
|
-
left: 1px;
|
317
|
-
top: 19px; }
|
318
|
-
|
319
|
-
70% {
|
320
|
-
width: 50px;
|
321
|
-
left: -8px;
|
322
|
-
top: 37px; }
|
323
|
-
|
324
|
-
84% {
|
325
|
-
width: 17px;
|
326
|
-
left: 21px;
|
327
|
-
top: 48px; }
|
328
|
-
|
329
|
-
100% {
|
330
|
-
width: 25px;
|
331
|
-
left: 14px;
|
332
|
-
top: 45px; } }
|
333
|
-
|
334
|
-
@-webkit-keyframes animate-success-long {
|
335
|
-
0% {
|
336
|
-
width: 0;
|
337
|
-
right: 46px;
|
338
|
-
top: 54px; }
|
339
|
-
|
340
|
-
65% {
|
341
|
-
width: 0;
|
342
|
-
right: 46px;
|
343
|
-
top: 54px; }
|
344
|
-
|
345
|
-
84% {
|
346
|
-
width: 55px;
|
347
|
-
right: 0;
|
348
|
-
top: 35px; }
|
349
|
-
|
350
|
-
100% {
|
351
|
-
width: 47px;
|
352
|
-
right: 8px;
|
353
|
-
top: 38px; } }
|
354
|
-
|
355
|
-
@keyframes animate-success-long {
|
356
|
-
0% {
|
357
|
-
width: 0;
|
358
|
-
right: 46px;
|
359
|
-
top: 54px; }
|
360
|
-
|
361
|
-
65% {
|
362
|
-
width: 0;
|
363
|
-
right: 46px;
|
364
|
-
top: 54px; }
|
365
|
-
|
366
|
-
84% {
|
367
|
-
width: 55px;
|
368
|
-
right: 0;
|
369
|
-
top: 35px; }
|
370
|
-
|
371
|
-
100% {
|
372
|
-
width: 47px;
|
373
|
-
right: 8px;
|
374
|
-
top: 38px; } }
|
375
|
-
|
376
|
-
@-webkit-keyframes rotatePlaceholder {
|
377
|
-
0% {
|
378
|
-
-webkit-transform: rotate(-45deg);
|
379
|
-
transform: rotate(-45deg); }
|
380
|
-
|
381
|
-
5% {
|
382
|
-
-webkit-transform: rotate(-45deg);
|
383
|
-
transform: rotate(-45deg); }
|
384
|
-
|
385
|
-
12% {
|
386
|
-
-webkit-transform: rotate(-405deg);
|
387
|
-
transform: rotate(-405deg); }
|
388
|
-
|
389
|
-
100% {
|
390
|
-
-webkit-transform: rotate(-405deg);
|
391
|
-
transform: rotate(-405deg); } }
|
392
|
-
|
393
|
-
@keyframes rotatePlaceholder {
|
394
|
-
0% {
|
395
|
-
-webkit-transform: rotate(-45deg);
|
396
|
-
transform: rotate(-45deg); }
|
397
|
-
|
398
|
-
5% {
|
399
|
-
-webkit-transform: rotate(-45deg);
|
400
|
-
transform: rotate(-45deg); }
|
401
|
-
|
402
|
-
12% {
|
403
|
-
-webkit-transform: rotate(-405deg);
|
404
|
-
transform: rotate(-405deg); }
|
405
|
-
|
406
|
-
100% {
|
407
|
-
-webkit-transform: rotate(-405deg);
|
408
|
-
transform: rotate(-405deg); } }
|
409
|
-
|
410
|
-
.animate-success-tip {
|
411
|
-
-webkit-animation: animate-success-tip 0.75s;
|
412
|
-
animation: animate-success-tip 0.75s; }
|
413
|
-
|
414
|
-
.animate-success-long {
|
415
|
-
-webkit-animation: animate-success-long 0.75s;
|
416
|
-
animation: animate-success-long 0.75s; }
|
417
|
-
|
418
|
-
.icon.success.animate::after {
|
419
|
-
-webkit-animation: rotatePlaceholder 4.25s ease-in;
|
420
|
-
animation: rotatePlaceholder 4.25s ease-in; }
|
421
|
-
|
422
|
-
@-webkit-keyframes animate-error-icon {
|
423
|
-
0% {
|
424
|
-
-webkit-transform: rotateX(100deg);
|
425
|
-
transform: rotateX(100deg);
|
426
|
-
opacity: 0; }
|
427
|
-
|
428
|
-
100% {
|
429
|
-
-webkit-transform: rotateX(0deg);
|
430
|
-
transform: rotateX(0deg);
|
431
|
-
opacity: 1; } }
|
432
|
-
|
433
|
-
@keyframes animate-error-icon {
|
434
|
-
0% {
|
435
|
-
-webkit-transform: rotateX(100deg);
|
436
|
-
transform: rotateX(100deg);
|
437
|
-
opacity: 0; }
|
438
|
-
|
439
|
-
100% {
|
440
|
-
-webkit-transform: rotateX(0deg);
|
441
|
-
transform: rotateX(0deg);
|
442
|
-
opacity: 1; } }
|
443
|
-
|
444
|
-
.animate-error-icon {
|
445
|
-
-webkit-animation: animate-error-icon 0.5s;
|
446
|
-
animation: animate-error-icon 0.5s; }
|
447
|
-
|
448
|
-
@-webkit-keyframes animate-x-mark {
|
449
|
-
0% {
|
450
|
-
-webkit-transform: scale(0.4);
|
451
|
-
transform: scale(0.4);
|
452
|
-
margin-top: 26px;
|
453
|
-
opacity: 0; }
|
454
|
-
|
455
|
-
50% {
|
456
|
-
-webkit-transform: scale(0.4);
|
457
|
-
transform: scale(0.4);
|
458
|
-
margin-top: 26px;
|
459
|
-
opacity: 0; }
|
460
|
-
|
461
|
-
80% {
|
462
|
-
-webkit-transform: scale(1.15);
|
463
|
-
transform: scale(1.15);
|
464
|
-
margin-top: -6px; }
|
465
|
-
|
466
|
-
100% {
|
467
|
-
-webkit-transform: scale(1);
|
468
|
-
transform: scale(1);
|
469
|
-
margin-top: 0;
|
470
|
-
opacity: 1; } }
|
471
|
-
|
472
|
-
@keyframes animate-x-mark {
|
473
|
-
0% {
|
474
|
-
-webkit-transform: scale(0.4);
|
475
|
-
transform: scale(0.4);
|
476
|
-
margin-top: 26px;
|
477
|
-
opacity: 0; }
|
478
|
-
|
479
|
-
50% {
|
480
|
-
-webkit-transform: scale(0.4);
|
481
|
-
transform: scale(0.4);
|
482
|
-
margin-top: 26px;
|
483
|
-
opacity: 0; }
|
484
|
-
|
485
|
-
80% {
|
486
|
-
-webkit-transform: scale(1.15);
|
487
|
-
transform: scale(1.15);
|
488
|
-
margin-top: -6px; }
|
489
|
-
|
490
|
-
100% {
|
491
|
-
-webkit-transform: scale(1);
|
492
|
-
transform: scale(1);
|
493
|
-
margin-top: 0;
|
494
|
-
opacity: 1; } }
|
495
|
-
|
496
|
-
.animate-x-mark {
|
497
|
-
-webkit-animation: animate-x-mark 0.5s;
|
498
|
-
animation: animate-x-mark 0.5s; }
|
499
|
-
|
500
|
-
@-webkit-keyframes pulse-warning {
|
501
|
-
0% {
|
502
|
-
border-color: #f8d486; }
|
503
|
-
|
504
|
-
100% {
|
505
|
-
border-color: #f8bb86; } }
|
506
|
-
|
507
|
-
@keyframes pulse-warning {
|
508
|
-
0% {
|
509
|
-
border-color: #f8d486; }
|
510
|
-
|
511
|
-
100% {
|
512
|
-
border-color: #f8bb86; } }
|
513
|
-
|
514
|
-
.pulse-warning {
|
515
|
-
-webkit-animation: pulse-warning 0.75s infinite alternate;
|
516
|
-
animation: pulse-warning 0.75s infinite alternate; }
|
517
|
-
|
518
|
-
@-webkit-keyframes pulse-warning-ins {
|
519
|
-
0% {
|
520
|
-
background-color: #f8d486; }
|
521
|
-
|
522
|
-
100% {
|
523
|
-
background-color: #f8bb86; } }
|
524
|
-
|
525
|
-
@keyframes pulse-warning-ins {
|
526
|
-
0% {
|
527
|
-
background-color: #f8d486; }
|
528
|
-
|
529
|
-
100% {
|
530
|
-
background-color: #f8bb86; } }
|
531
|
-
|
532
|
-
.pulse-warning-ins {
|
533
|
-
-webkit-animation: pulse-warning-ins 0.75s infinite alternate;
|
534
|
-
animation: pulse-warning-ins 0.75s infinite alternate; }
|