16 lines
268 KiB
JavaScript
16 lines
268 KiB
JavaScript
|
!function t(e,n,o){function r(s,a){if(!n[s]){if(!e[s]){var l="function"==typeof require&&require;if(!a&&l)return l(s,!0);if(i)return i(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var u=n[s]={exports:{}};e[s][0].call(u.exports,(function(t){return r(e[s][1][t]||t)}),u,u.exports,t,e,n,o)}return n[s].exports}for(var i="function"==typeof require&&require,s=0;s<o.length;s++)r(o[s]);return r}({1:[function(t,e,n){"use strict";var o=t("./utils");function r(){var t={},e=0,n=0,o=0;return{add:function(r,i){i||(i=r,r=0),r>n?n=r:r<o&&(o=r),t[r]||(t[r]=[]),t[r].push(i),e++},process:function(){for(var e=o;e<=n;e++)for(var r=t[e],i=0;i<r.length;i++){(0,r[i])()}},size:function(){return e}}}e.exports=function(t){var e=(t=t||{}).reporter,n=o.getOption(t,"async",!0),i=o.getOption(t,"auto",!0);i&&!n&&(e&&e.warn("Invalid options combination. auto=true and async=false is invalid. Setting async=true."),n=!0);var s,a=r(),l=!1;function c(){for(l=!0;a.size();){var t=a;a=r(),t.process()}l=!1}function u(){var t;t=c,s=setTimeout(t,0)}return{add:function(t,e){!l&&i&&n&&0===a.size()&&u(),a.add(t,e)},force:function(t){l||(void 0===t&&(t=n),s&&(clearTimeout(s),s=null),t?u():c())}}}},{"./utils":2}],2:[function(t,e,n){"use strict";(e.exports={}).getOption=function(t,e,n){var o=t[e];if(null==o&&void 0!==n)return n;return o}},{}],3:[function(t,e,n){var o=t("../internals/is-callable"),r=t("../internals/try-to-string"),i=TypeError;e.exports=function(t){if(o(t))return t;throw i(r(t)+" is not a function")}},{"../internals/is-callable":65,"../internals/try-to-string":110}],4:[function(t,e,n){var o=t("../internals/is-constructor"),r=t("../internals/try-to-string"),i=TypeError;e.exports=function(t){if(o(t))return t;throw i(r(t)+" is not a constructor")}},{"../internals/is-constructor":66,"../internals/try-to-string":110}],5:[function(t,e,n){var o=t("../internals/is-callable"),r=String,i=TypeError;e.exports=function(t){if("object"==typeof t||o(t))return t;throw i("Can't set "+r(t)+" as a prototype")}},{"../internals/is-callable":65}],6:[function(t,e,n){var o=t("../internals/well-known-symbol"),r=t("../internals/object-create"),i=t("../internals/object-define-property").f,s=o("unscopables"),a=Array.prototype;null==a[s]&&i(a,s,{configurable:!0,value:r(null)}),e.exports=function(t){a[s][t]=!0}},{"../internals/object-create":79,"../internals/object-define-property":81,"../internals/well-known-symbol":117}],7:[function(t,e,n){var o=t("../internals/object-is-prototype-of"),r=TypeError;e.exports=function(t,e){if(o(e,t))return t;throw r("Incorrect invocation")}},{"../internals/object-is-prototype-of":86}],8:[function(t,e,n){var o=t("../internals/is-object"),r=String,i=TypeError;e.exports=function(t){if(o(t))return t;throw i(r(t)+" is not an object")}},{"../internals/is-object":69}],9:[function(t,e,n){e.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},{}],10:[function(t,e,n){"use strict";var o,r,i,s=t("../internals/array-buffer-native"),a=t("../internals/descriptors"),l=t("../internals/global"),c=t("../internals/is-callable"),u=t("../internals/is-object"),d=t("../internals/has-own-property"),f=t("../internals/classof"),p=t("../internals/try-to-string"),h=t("../internals/create-non-enumerable-property"),y=t("../internals/define-built-in"),v=t("../internals/object-define-property").f,g=t("../internals/object-is-prototype-of"),m=t("../internals/object-get-prototype-of"),b=t("../internals/object-set-prototype-of"),w=t("../internals/well-known-symbol"),_=t("../internals/uid"),x=t("../internals/internal-state"),D=x.enforce,k=x.get,E=l.Int8Array,B=E&&E.prototype,C=l.Uint8ClampedArray,K=C&&C.prototype,O=E&&m(E),S=B&&m(B),j=Object.prototype,P=l.TypeError,T=w("toStringTag"),M=_("TYPED_ARRAY_TAG"),A="TypedArrayConstructor",I=s&&!!b&&"Opera"!==f(l.opera),L=!1,N={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},R={BigInt64Array:8,BigUint64Array:8},F=function(t){var e=m(t);if(u(e)){var n=k(e);return n&&d(n,A)?n.TypedArrayConstructor:F(e)}},U=func
|
||
|
/*! *****************************************************************************
|
||
|
Copyright (c) Microsoft Corporation.
|
||
|
|
||
|
Permission to use, copy, modify, and/or distribute this software for any
|
||
|
purpose with or without fee is hereby granted.
|
||
|
|
||
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||
|
PERFORMANCE OF THIS SOFTWARE.
|
||
|
***************************************************************************** */
|
||
|
var o,r=function(){return r=Object.assign||function(t){for(var e,n=1,o=arguments.length;n<o;n++)for(var r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t},r.apply(this,arguments)},i=function(){function t(t){this.options=t,this.listeners={}}return t.prototype.on=function(t,e){var n=this.listeners[t]||[];this.listeners[t]=n.concat([e])},t.prototype.triggerEvent=function(t,e){var n=this;(this.listeners[t]||[]).forEach((function(t){return t({target:n,event:e})}))},t}();(o=n.NotyfArrayEvent||(n.NotyfArrayEvent={}))[o.Add=0]="Add",o[o.Remove=1]="Remove";var s,a=function(){function t(){this.notifications=[]}return t.prototype.push=function(t){this.notifications.push(t),this.updateFn(t,n.NotyfArrayEvent.Add,this.notifications)},t.prototype.splice=function(t,e){var o=this.notifications.splice(t,e)[0];return this.updateFn(o,n.NotyfArrayEvent.Remove,this.notifications),o},t.prototype.indexOf=function(t){return this.notifications.indexOf(t)},t.prototype.onUpdate=function(t){this.updateFn=t},t}();(s=n.NotyfEvent||(n.NotyfEvent={})).Dismiss="dismiss",s.Click="click";var l={types:[{type:"success",className:"notyf__toast--success",backgroundColor:"#3dc763",icon:{className:"notyf__icon--success",tagName:"i"}},{type:"error",className:"notyf__toast--error",backgroundColor:"#ed3d3d",icon:{className:"notyf__icon--error",tagName:"i"}}],duration:2e3,ripple:!0,position:{x:"right",y:"bottom"},dismissible:!1},c=function(){function t(){this.notifications=[],this.events={},this.X_POSITION_FLEX_MAP={left:"flex-start",center:"center",right:"flex-end"},this.Y_POSITION_FLEX_MAP={top:"flex-start",center:"center",bottom:"flex-end"};var t=document.createDocumentFragment(),e=this._createHTMLElement({tagName:"div",className:"notyf"});t.appendChild(e),document.body.appendChild(t),this.container=e,this.animationEndEventName=this._getAnimationEndEventName(),this._createA11yContainer()}return t.prototype.on=function(t,e){var n;this.events=r(r({},this.events),((n={})[t]=e,n))},t.prototype.update=function(t,e){e===n.NotyfArrayEvent.Add?this.addNotification(t):e===n.NotyfArrayEvent.Remove&&this.removeNotification(t)},t.prototype.removeNotification=function(t){var e,n,o=this,r=this._popRenderedNotification(t);r&&((e=r.node).classList.add("notyf__toast--disappear"),e.addEventListener(this.animationEndEventName,n=function(t){t.target===e&&(e.removeEventListener(o.animationEndEventName,n),o.container.removeChild(e))}))},t.prototype.addNotification=function(t){var e=this._renderNotification(t);this.notifications.push({notification:t,node:e}),this._announce(t.options.message||"Notification")},t.prototype._renderNotification=function(t){var e,n=this._buildNotificationCard(t),o=t.options.className;return o&&(e=n.classList).add.apply(e,o.split(" ")),this.container.appendChild(n),n},t.prototype._popRenderedNotification=function(t){for(var e=-1,n=0;n<this.notifications.length&&e<0;n++)this.notifications[n].notification===t&&(e=n);if(-1!==e)return this.notifications.splice(e,1)[0]},t.prototype.getXPosition=function(t){var e;return(null===(e=null==t?void 0:t.position)||void 0===e?void 0:e.x)||"right"},t.prototype.getYPosition=function(t){var e;return(null===(e=null==t?void 0:t.position)||void 0===e?void 0:e.y)||"bottom"},t.prototype.adjustContainerAlignment=function(t){var e=this.X_POSITION_FLEX_MAP[this.getXPosition(t)],n=this.Y_POSITION_FLEX_MAP[this.getYPosition(t)],o=this.container.style;o.setProperty("justify-content",n),o.setProperty("align-items",e)},t.prototype._buildNotificationCard=function(t){var e=this,o=t.options,r=o.icon;this.adjustContainerAlignment(o);var i=this._createHTMLElement({tagName:"div",className:"notyf__toast"}),s=this._createHTMLElement({tagName:"div",className:"notyf__ripple"}),a=this._createHTMLElement({tagName:"div",className:"notyf__wrapper"}),l=this._createHTMLElement({tagName:"div",className:"notyf__message"});l.innerHTML=o.message||"";var c=o.background||o.backgroundColor;if(r){var u=this._createHTMLElement({tagName:"div",className:"notyf__icon"});if(("string"==typeof r||r instanceof String)&&(u.innerHTML=new
|