diff --git a/app/index.js b/app/index.js
index 4411449..ac5de97 100644
--- a/app/index.js
+++ b/app/index.js
@@ -10,6 +10,13 @@
// app startup
+ //configure noty
+ Noty.overrideDefaults({
+ layout: 'topRight',
+ theme: 'bootstrap-v4',
+ closeWith: ['click', 'button']
+ });
+
// set language
i18next
.use(i18nextBrowserLanguageDetector)
diff --git a/app/text/text.js b/app/text/text.js
index 2056788..477d6b7 100644
--- a/app/text/text.js
+++ b/app/text/text.js
@@ -24,7 +24,11 @@
$(document).on('click', '.js-link', function(ev) {
var el = $(ev.currentTarget);
var linkId = el.attr('data-id');
- PNotify.success('The text you clicked had id ' + linkId + '. Maybe next time I will do something with this id.');
+ new Noty({
+ type: 'success',
+ text: 'The text you clicked had id ' + linkId + '. Maybe next time I will do something with this id.',
+ timeout: 5000
+ }).show();
});
// app startup
diff --git a/index.html b/index.html
index 11bf156..dc443f9 100644
--- a/index.html
+++ b/index.html
@@ -5,7 +5,8 @@
-
+
+
@@ -21,8 +22,7 @@
-
-
+
diff --git a/node_modules/noty/LICENSE.txt b/node_modules/noty/LICENSE.txt
new file mode 100644
index 0000000..6869939
--- /dev/null
+++ b/node_modules/noty/LICENSE.txt
@@ -0,0 +1,20 @@
+Copyright (c) 2012 Nedim Arabacı
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
\ No newline at end of file
diff --git a/node_modules/noty/README.markdown b/node_modules/noty/README.markdown
new file mode 100644
index 0000000..6e04965
--- /dev/null
+++ b/node_modules/noty/README.markdown
@@ -0,0 +1,124 @@
+
+
+
+
+
+
+## Hi
+
+**NOTY** is a notification library that makes it easy to create **alert** - **success** - **error** - **warning** - **information** - **confirmation** messages as an alternative the standard alert dialog.
+
+The notifications can be positioned at the;
+**top** - **topLeft** - **topCenter** - **topRight** - **center** - **centerLeft** - **centerRight** - **bottom** - **bottomLeft** - **bottomCenter** - **bottomRight**
+
+There are lots of other options in the API to customise the text, animation, buttons and much more.
+
+It also has various callbacks for the buttons, opening closing the notifications and queue control.
+
+### Sponsored By
+
' + buildButtons(ref) + '';
+
+ ref.barDom = document.createElement('div');
+ ref.barDom.setAttribute('id', ref.id);
+ Utils.addClass(ref.barDom, 'noty_bar noty_type__' + ref.options.type + ' noty_theme__' + ref.options.theme);
+
+ ref.barDom.innerHTML = markup;
+
+ fire(ref, 'onTemplate');
+}
+
+/**
+ * @param {Noty} ref
+ * @return {boolean}
+ */
+function hasButtons(ref) {
+ return !!(ref.options.buttons && Object.keys(ref.options.buttons).length);
+}
+
+/**
+ * @param {Noty} ref
+ * @return {string}
+ */
+function buildButtons(ref) {
+ if (hasButtons(ref)) {
+ var buttons = document.createElement('div');
+ Utils.addClass(buttons, 'noty_buttons');
+
+ Object.keys(ref.options.buttons).forEach(function (key) {
+ buttons.appendChild(ref.options.buttons[key].dom);
+ });
+
+ ref.options.buttons.forEach(function (btn) {
+ buttons.appendChild(btn.dom);
+ });
+ return buttons.outerHTML;
+ }
+ return '';
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+function handleModal(ref) {
+ if (ref.options.modal) {
+ if (DocModalCount === 0) {
+ createModal(ref);
+ }
+
+ exports.DocModalCount = DocModalCount += 1;
+ }
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+function handleModalClose(ref) {
+ if (ref.options.modal && DocModalCount > 0) {
+ exports.DocModalCount = DocModalCount -= 1;
+
+ if (DocModalCount <= 0) {
+ var modal = document.querySelector('.noty_modal');
+
+ if (modal) {
+ Utils.removeClass(modal, 'noty_modal_open');
+ Utils.addClass(modal, 'noty_modal_close');
+ Utils.addListener(modal, Utils.animationEndEvents, function () {
+ Utils.remove(modal);
+ });
+ }
+ }
+ }
+}
+
+/**
+ * @return {void}
+ */
+function createModal() {
+ var body = document.querySelector('body');
+ var modal = document.createElement('div');
+ Utils.addClass(modal, 'noty_modal');
+ body.insertBefore(modal, body.firstChild);
+ Utils.addClass(modal, 'noty_modal_open');
+
+ Utils.addListener(modal, Utils.animationEndEvents, function () {
+ Utils.removeClass(modal, 'noty_modal_open');
+ });
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+function findOrCreateContainer(ref) {
+ if (ref.options.container) {
+ ref.layoutDom = document.querySelector(ref.options.container);
+ return;
+ }
+
+ var layoutID = 'noty_layout__' + ref.options.layout;
+ ref.layoutDom = document.querySelector('div#' + layoutID);
+
+ if (!ref.layoutDom) {
+ ref.layoutDom = document.createElement('div');
+ ref.layoutDom.setAttribute('id', layoutID);
+ ref.layoutDom.setAttribute('role', 'alert');
+ ref.layoutDom.setAttribute('aria-live', 'polite');
+ Utils.addClass(ref.layoutDom, 'noty_layout');
+ document.querySelector('body').appendChild(ref.layoutDom);
+ }
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+function queueClose(ref) {
+ if (ref.options.timeout) {
+ if (ref.options.progressBar && ref.progressDom) {
+ Utils.css(ref.progressDom, {
+ transition: 'width ' + ref.options.timeout + 'ms linear',
+ width: '0%'
+ });
+ }
+
+ clearTimeout(ref.closeTimer);
+
+ ref.closeTimer = setTimeout(function () {
+ ref.close();
+ }, ref.options.timeout);
+ }
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+function dequeueClose(ref) {
+ if (ref.options.timeout && ref.closeTimer) {
+ clearTimeout(ref.closeTimer);
+ ref.closeTimer = -1;
+
+ if (ref.options.progressBar && ref.progressDom) {
+ Utils.css(ref.progressDom, {
+ transition: 'width 0ms linear',
+ width: '100%'
+ });
+ }
+ }
+}
+
+/**
+ * @param {Noty} ref
+ * @param {string} eventName
+ * @return {void}
+ */
+function fire(ref, eventName) {
+ if (ref.listeners.hasOwnProperty(eventName)) {
+ ref.listeners[eventName].forEach(function (cb) {
+ if (typeof cb === 'function') {
+ cb.apply(ref);
+ }
+ });
+ }
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+function openFlow(ref) {
+ fire(ref, 'afterShow');
+ queueClose(ref);
+
+ Utils.addListener(ref.barDom, 'mouseenter', function () {
+ dequeueClose(ref);
+ });
+
+ Utils.addListener(ref.barDom, 'mouseleave', function () {
+ queueClose(ref);
+ });
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+function closeFlow(ref) {
+ delete Store[ref.id];
+ ref.closing = false;
+ fire(ref, 'afterClose');
+
+ Utils.remove(ref.barDom);
+
+ if (ref.layoutDom.querySelectorAll('.noty_bar').length === 0 && !ref.options.container) {
+ Utils.remove(ref.layoutDom);
+ }
+
+ if (Utils.inArray('docVisible', ref.options.titleCount.conditions) || Utils.inArray('docHidden', ref.options.titleCount.conditions)) {
+ docTitle.decrement();
+ }
+
+ queueRender(ref.options.queue);
+}
+
+/***/ }),
+/* 2 */
+/***/ (function(module, exports, __webpack_require__) {
+
+"use strict";
+
+
+Object.defineProperty(exports, "__esModule", {
+ value: true
+});
+exports.NotyButton = undefined;
+
+var _utils = __webpack_require__(0);
+
+var Utils = _interopRequireWildcard(_utils);
+
+function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+
+var NotyButton = exports.NotyButton = function NotyButton(html, classes, cb) {
+ var _this = this;
+
+ var attributes = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
+
+ _classCallCheck(this, NotyButton);
+
+ this.dom = document.createElement('button');
+ this.dom.innerHTML = html;
+ this.id = attributes.id = attributes.id || Utils.generateID('button');
+ this.cb = cb;
+ Object.keys(attributes).forEach(function (propertyName) {
+ _this.dom.setAttribute(propertyName, attributes[propertyName]);
+ });
+ Utils.addClass(this.dom, classes || 'noty_btn');
+
+ return this;
+};
+
+/***/ }),
+/* 3 */
+/***/ (function(module, exports, __webpack_require__) {
+
+"use strict";
+
+
+Object.defineProperty(exports, "__esModule", {
+ value: true
+});
+
+var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
+
+function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+
+var Push = exports.Push = function () {
+ function Push() {
+ var workerPath = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '/service-worker.js';
+
+ _classCallCheck(this, Push);
+
+ this.subData = {};
+ this.workerPath = workerPath;
+ this.listeners = {
+ onPermissionGranted: [],
+ onPermissionDenied: [],
+ onSubscriptionSuccess: [],
+ onSubscriptionCancel: [],
+ onWorkerError: [],
+ onWorkerSuccess: [],
+ onWorkerNotSupported: []
+ };
+ return this;
+ }
+
+ /**
+ * @param {string} eventName
+ * @param {function} cb
+ * @return {Push}
+ */
+
+
+ _createClass(Push, [{
+ key: 'on',
+ value: function on(eventName) {
+ var cb = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : function () {};
+
+ if (typeof cb === 'function' && this.listeners.hasOwnProperty(eventName)) {
+ this.listeners[eventName].push(cb);
+ }
+
+ return this;
+ }
+ }, {
+ key: 'fire',
+ value: function fire(eventName) {
+ var _this = this;
+
+ var params = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
+
+ if (this.listeners.hasOwnProperty(eventName)) {
+ this.listeners[eventName].forEach(function (cb) {
+ if (typeof cb === 'function') {
+ cb.apply(_this, params);
+ }
+ });
+ }
+ }
+ }, {
+ key: 'create',
+ value: function create() {
+ console.log('NOT IMPLEMENTED YET');
+ }
+
+ /**
+ * @return {boolean}
+ */
+
+ }, {
+ key: 'isSupported',
+ value: function isSupported() {
+ var result = false;
+
+ try {
+ result = window.Notification || window.webkitNotifications || navigator.mozNotification || window.external && window.external.msIsSiteMode() !== undefined;
+ } catch (e) {}
+
+ return result;
+ }
+
+ /**
+ * @return {string}
+ */
+
+ }, {
+ key: 'getPermissionStatus',
+ value: function getPermissionStatus() {
+ var perm = 'default';
+
+ if (window.Notification && window.Notification.permissionLevel) {
+ perm = window.Notification.permissionLevel;
+ } else if (window.webkitNotifications && window.webkitNotifications.checkPermission) {
+ switch (window.webkitNotifications.checkPermission()) {
+ case 1:
+ perm = 'default';
+ break;
+ case 0:
+ perm = 'granted';
+ break;
+ default:
+ perm = 'denied';
+ }
+ } else if (window.Notification && window.Notification.permission) {
+ perm = window.Notification.permission;
+ } else if (navigator.mozNotification) {
+ perm = 'granted';
+ } else if (window.external && window.external.msIsSiteMode() !== undefined) {
+ perm = window.external.msIsSiteMode() ? 'granted' : 'default';
+ }
+
+ return perm.toString().toLowerCase();
+ }
+
+ /**
+ * @return {string}
+ */
+
+ }, {
+ key: 'getEndpoint',
+ value: function getEndpoint(subscription) {
+ var endpoint = subscription.endpoint;
+ var subscriptionId = subscription.subscriptionId;
+
+ // fix for Chrome < 45
+ if (subscriptionId && endpoint.indexOf(subscriptionId) === -1) {
+ endpoint += '/' + subscriptionId;
+ }
+
+ return endpoint;
+ }
+
+ /**
+ * @return {boolean}
+ */
+
+ }, {
+ key: 'isSWRegistered',
+ value: function isSWRegistered() {
+ try {
+ return navigator.serviceWorker.controller.state === 'activated';
+ } catch (e) {
+ return false;
+ }
+ }
+
+ /**
+ * @return {void}
+ */
+
+ }, {
+ key: 'unregisterWorker',
+ value: function unregisterWorker() {
+ var self = this;
+ if ('serviceWorker' in navigator) {
+ navigator.serviceWorker.getRegistrations().then(function (registrations) {
+ var _iteratorNormalCompletion = true;
+ var _didIteratorError = false;
+ var _iteratorError = undefined;
+
+ try {
+ for (var _iterator = registrations[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
+ var registration = _step.value;
+
+ registration.unregister();
+ self.fire('onSubscriptionCancel');
+ }
+ } catch (err) {
+ _didIteratorError = true;
+ _iteratorError = err;
+ } finally {
+ try {
+ if (!_iteratorNormalCompletion && _iterator.return) {
+ _iterator.return();
+ }
+ } finally {
+ if (_didIteratorError) {
+ throw _iteratorError;
+ }
+ }
+ }
+ });
+ }
+ }
+
+ /**
+ * @return {void}
+ */
+
+ }, {
+ key: 'requestSubscription',
+ value: function requestSubscription() {
+ var _this2 = this;
+
+ var userVisibleOnly = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
+
+ var self = this;
+ var current = this.getPermissionStatus();
+ var cb = function cb(result) {
+ if (result === 'granted') {
+ _this2.fire('onPermissionGranted');
+
+ if ('serviceWorker' in navigator) {
+ navigator.serviceWorker.register(_this2.workerPath).then(function () {
+ navigator.serviceWorker.ready.then(function (serviceWorkerRegistration) {
+ self.fire('onWorkerSuccess');
+ serviceWorkerRegistration.pushManager.subscribe({
+ userVisibleOnly: userVisibleOnly
+ }).then(function (subscription) {
+ var key = subscription.getKey('p256dh');
+ var token = subscription.getKey('auth');
+
+ self.subData = {
+ endpoint: self.getEndpoint(subscription),
+ p256dh: key ? window.btoa(String.fromCharCode.apply(null, new Uint8Array(key))) : null,
+ auth: token ? window.btoa(String.fromCharCode.apply(null, new Uint8Array(token))) : null
+ };
+
+ self.fire('onSubscriptionSuccess', [self.subData]);
+ }).catch(function (err) {
+ self.fire('onWorkerError', [err]);
+ });
+ });
+ });
+ } else {
+ self.fire('onWorkerNotSupported');
+ }
+ } else if (result === 'denied') {
+ _this2.fire('onPermissionDenied');
+ _this2.unregisterWorker();
+ }
+ };
+
+ if (current === 'default') {
+ if (window.Notification && window.Notification.requestPermission) {
+ window.Notification.requestPermission(cb);
+ } else if (window.webkitNotifications && window.webkitNotifications.checkPermission) {
+ window.webkitNotifications.requestPermission(cb);
+ }
+ } else {
+ cb(current);
+ }
+ }
+ }]);
+
+ return Push;
+}();
+
+/***/ }),
+/* 4 */
+/***/ (function(module, exports, __webpack_require__) {
+
+/* WEBPACK VAR INJECTION */(function(process, global) {var require;/*!
+ * @overview es6-promise - a tiny implementation of Promises/A+.
+ * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)
+ * @license Licensed under MIT license
+ * See https://raw.githubusercontent.com/stefanpenner/es6-promise/master/LICENSE
+ * @version 4.1.1
+ */
+
+(function (global, factory) {
+ true ? module.exports = factory() :
+ typeof define === 'function' && define.amd ? define(factory) :
+ (global.ES6Promise = factory());
+}(this, (function () { 'use strict';
+
+function objectOrFunction(x) {
+ var type = typeof x;
+ return x !== null && (type === 'object' || type === 'function');
+}
+
+function isFunction(x) {
+ return typeof x === 'function';
+}
+
+var _isArray = undefined;
+if (Array.isArray) {
+ _isArray = Array.isArray;
+} else {
+ _isArray = function (x) {
+ return Object.prototype.toString.call(x) === '[object Array]';
+ };
+}
+
+var isArray = _isArray;
+
+var len = 0;
+var vertxNext = undefined;
+var customSchedulerFn = undefined;
+
+var asap = function asap(callback, arg) {
+ queue[len] = callback;
+ queue[len + 1] = arg;
+ len += 2;
+ if (len === 2) {
+ // If len is 2, that means that we need to schedule an async flush.
+ // If additional callbacks are queued before the queue is flushed, they
+ // will be processed by this flush that we are scheduling.
+ if (customSchedulerFn) {
+ customSchedulerFn(flush);
+ } else {
+ scheduleFlush();
+ }
+ }
+};
+
+function setScheduler(scheduleFn) {
+ customSchedulerFn = scheduleFn;
+}
+
+function setAsap(asapFn) {
+ asap = asapFn;
+}
+
+var browserWindow = typeof window !== 'undefined' ? window : undefined;
+var browserGlobal = browserWindow || {};
+var BrowserMutationObserver = browserGlobal.MutationObserver || browserGlobal.WebKitMutationObserver;
+var isNode = typeof self === 'undefined' && typeof process !== 'undefined' && ({}).toString.call(process) === '[object process]';
+
+// test for web worker but not in IE10
+var isWorker = typeof Uint8ClampedArray !== 'undefined' && typeof importScripts !== 'undefined' && typeof MessageChannel !== 'undefined';
+
+// node
+function useNextTick() {
+ // node version 0.10.x displays a deprecation warning when nextTick is used recursively
+ // see https://github.com/cujojs/when/issues/410 for details
+ return function () {
+ return process.nextTick(flush);
+ };
+}
+
+// vertx
+function useVertxTimer() {
+ if (typeof vertxNext !== 'undefined') {
+ return function () {
+ vertxNext(flush);
+ };
+ }
+
+ return useSetTimeout();
+}
+
+function useMutationObserver() {
+ var iterations = 0;
+ var observer = new BrowserMutationObserver(flush);
+ var node = document.createTextNode('');
+ observer.observe(node, { characterData: true });
+
+ return function () {
+ node.data = iterations = ++iterations % 2;
+ };
+}
+
+// web worker
+function useMessageChannel() {
+ var channel = new MessageChannel();
+ channel.port1.onmessage = flush;
+ return function () {
+ return channel.port2.postMessage(0);
+ };
+}
+
+function useSetTimeout() {
+ // Store setTimeout reference so es6-promise will be unaffected by
+ // other code modifying setTimeout (like sinon.useFakeTimers())
+ var globalSetTimeout = setTimeout;
+ return function () {
+ return globalSetTimeout(flush, 1);
+ };
+}
+
+var queue = new Array(1000);
+function flush() {
+ for (var i = 0; i < len; i += 2) {
+ var callback = queue[i];
+ var arg = queue[i + 1];
+
+ callback(arg);
+
+ queue[i] = undefined;
+ queue[i + 1] = undefined;
+ }
+
+ len = 0;
+}
+
+function attemptVertx() {
+ try {
+ var r = require;
+ var vertx = __webpack_require__(9);
+ vertxNext = vertx.runOnLoop || vertx.runOnContext;
+ return useVertxTimer();
+ } catch (e) {
+ return useSetTimeout();
+ }
+}
+
+var scheduleFlush = undefined;
+// Decide what async method to use to triggering processing of queued callbacks:
+if (isNode) {
+ scheduleFlush = useNextTick();
+} else if (BrowserMutationObserver) {
+ scheduleFlush = useMutationObserver();
+} else if (isWorker) {
+ scheduleFlush = useMessageChannel();
+} else if (browserWindow === undefined && "function" === 'function') {
+ scheduleFlush = attemptVertx();
+} else {
+ scheduleFlush = useSetTimeout();
+}
+
+function then(onFulfillment, onRejection) {
+ var _arguments = arguments;
+
+ var parent = this;
+
+ var child = new this.constructor(noop);
+
+ if (child[PROMISE_ID] === undefined) {
+ makePromise(child);
+ }
+
+ var _state = parent._state;
+
+ if (_state) {
+ (function () {
+ var callback = _arguments[_state - 1];
+ asap(function () {
+ return invokeCallback(_state, child, callback, parent._result);
+ });
+ })();
+ } else {
+ subscribe(parent, child, onFulfillment, onRejection);
+ }
+
+ return child;
+}
+
+/**
+ `Promise.resolve` returns a promise that will become resolved with the
+ passed `value`. It is shorthand for the following:
+
+ ```javascript
+ let promise = new Promise(function(resolve, reject){
+ resolve(1);
+ });
+
+ promise.then(function(value){
+ // value === 1
+ });
+ ```
+
+ Instead of writing the above, your code now simply becomes the following:
+
+ ```javascript
+ let promise = Promise.resolve(1);
+
+ promise.then(function(value){
+ // value === 1
+ });
+ ```
+
+ @method resolve
+ @static
+ @param {Any} value value that the returned promise will be resolved with
+ Useful for tooling.
+ @return {Promise} a promise that will become fulfilled with the given
+ `value`
+*/
+function resolve$1(object) {
+ /*jshint validthis:true */
+ var Constructor = this;
+
+ if (object && typeof object === 'object' && object.constructor === Constructor) {
+ return object;
+ }
+
+ var promise = new Constructor(noop);
+ resolve(promise, object);
+ return promise;
+}
+
+var PROMISE_ID = Math.random().toString(36).substring(16);
+
+function noop() {}
+
+var PENDING = void 0;
+var FULFILLED = 1;
+var REJECTED = 2;
+
+var GET_THEN_ERROR = new ErrorObject();
+
+function selfFulfillment() {
+ return new TypeError("You cannot resolve a promise with itself");
+}
+
+function cannotReturnOwn() {
+ return new TypeError('A promises callback cannot return that same promise.');
+}
+
+function getThen(promise) {
+ try {
+ return promise.then;
+ } catch (error) {
+ GET_THEN_ERROR.error = error;
+ return GET_THEN_ERROR;
+ }
+}
+
+function tryThen(then$$1, value, fulfillmentHandler, rejectionHandler) {
+ try {
+ then$$1.call(value, fulfillmentHandler, rejectionHandler);
+ } catch (e) {
+ return e;
+ }
+}
+
+function handleForeignThenable(promise, thenable, then$$1) {
+ asap(function (promise) {
+ var sealed = false;
+ var error = tryThen(then$$1, thenable, function (value) {
+ if (sealed) {
+ return;
+ }
+ sealed = true;
+ if (thenable !== value) {
+ resolve(promise, value);
+ } else {
+ fulfill(promise, value);
+ }
+ }, function (reason) {
+ if (sealed) {
+ return;
+ }
+ sealed = true;
+
+ reject(promise, reason);
+ }, 'Settle: ' + (promise._label || ' unknown promise'));
+
+ if (!sealed && error) {
+ sealed = true;
+ reject(promise, error);
+ }
+ }, promise);
+}
+
+function handleOwnThenable(promise, thenable) {
+ if (thenable._state === FULFILLED) {
+ fulfill(promise, thenable._result);
+ } else if (thenable._state === REJECTED) {
+ reject(promise, thenable._result);
+ } else {
+ subscribe(thenable, undefined, function (value) {
+ return resolve(promise, value);
+ }, function (reason) {
+ return reject(promise, reason);
+ });
+ }
+}
+
+function handleMaybeThenable(promise, maybeThenable, then$$1) {
+ if (maybeThenable.constructor === promise.constructor && then$$1 === then && maybeThenable.constructor.resolve === resolve$1) {
+ handleOwnThenable(promise, maybeThenable);
+ } else {
+ if (then$$1 === GET_THEN_ERROR) {
+ reject(promise, GET_THEN_ERROR.error);
+ GET_THEN_ERROR.error = null;
+ } else if (then$$1 === undefined) {
+ fulfill(promise, maybeThenable);
+ } else if (isFunction(then$$1)) {
+ handleForeignThenable(promise, maybeThenable, then$$1);
+ } else {
+ fulfill(promise, maybeThenable);
+ }
+ }
+}
+
+function resolve(promise, value) {
+ if (promise === value) {
+ reject(promise, selfFulfillment());
+ } else if (objectOrFunction(value)) {
+ handleMaybeThenable(promise, value, getThen(value));
+ } else {
+ fulfill(promise, value);
+ }
+}
+
+function publishRejection(promise) {
+ if (promise._onerror) {
+ promise._onerror(promise._result);
+ }
+
+ publish(promise);
+}
+
+function fulfill(promise, value) {
+ if (promise._state !== PENDING) {
+ return;
+ }
+
+ promise._result = value;
+ promise._state = FULFILLED;
+
+ if (promise._subscribers.length !== 0) {
+ asap(publish, promise);
+ }
+}
+
+function reject(promise, reason) {
+ if (promise._state !== PENDING) {
+ return;
+ }
+ promise._state = REJECTED;
+ promise._result = reason;
+
+ asap(publishRejection, promise);
+}
+
+function subscribe(parent, child, onFulfillment, onRejection) {
+ var _subscribers = parent._subscribers;
+ var length = _subscribers.length;
+
+ parent._onerror = null;
+
+ _subscribers[length] = child;
+ _subscribers[length + FULFILLED] = onFulfillment;
+ _subscribers[length + REJECTED] = onRejection;
+
+ if (length === 0 && parent._state) {
+ asap(publish, parent);
+ }
+}
+
+function publish(promise) {
+ var subscribers = promise._subscribers;
+ var settled = promise._state;
+
+ if (subscribers.length === 0) {
+ return;
+ }
+
+ var child = undefined,
+ callback = undefined,
+ detail = promise._result;
+
+ for (var i = 0; i < subscribers.length; i += 3) {
+ child = subscribers[i];
+ callback = subscribers[i + settled];
+
+ if (child) {
+ invokeCallback(settled, child, callback, detail);
+ } else {
+ callback(detail);
+ }
+ }
+
+ promise._subscribers.length = 0;
+}
+
+function ErrorObject() {
+ this.error = null;
+}
+
+var TRY_CATCH_ERROR = new ErrorObject();
+
+function tryCatch(callback, detail) {
+ try {
+ return callback(detail);
+ } catch (e) {
+ TRY_CATCH_ERROR.error = e;
+ return TRY_CATCH_ERROR;
+ }
+}
+
+function invokeCallback(settled, promise, callback, detail) {
+ var hasCallback = isFunction(callback),
+ value = undefined,
+ error = undefined,
+ succeeded = undefined,
+ failed = undefined;
+
+ if (hasCallback) {
+ value = tryCatch(callback, detail);
+
+ if (value === TRY_CATCH_ERROR) {
+ failed = true;
+ error = value.error;
+ value.error = null;
+ } else {
+ succeeded = true;
+ }
+
+ if (promise === value) {
+ reject(promise, cannotReturnOwn());
+ return;
+ }
+ } else {
+ value = detail;
+ succeeded = true;
+ }
+
+ if (promise._state !== PENDING) {
+ // noop
+ } else if (hasCallback && succeeded) {
+ resolve(promise, value);
+ } else if (failed) {
+ reject(promise, error);
+ } else if (settled === FULFILLED) {
+ fulfill(promise, value);
+ } else if (settled === REJECTED) {
+ reject(promise, value);
+ }
+}
+
+function initializePromise(promise, resolver) {
+ try {
+ resolver(function resolvePromise(value) {
+ resolve(promise, value);
+ }, function rejectPromise(reason) {
+ reject(promise, reason);
+ });
+ } catch (e) {
+ reject(promise, e);
+ }
+}
+
+var id = 0;
+function nextId() {
+ return id++;
+}
+
+function makePromise(promise) {
+ promise[PROMISE_ID] = id++;
+ promise._state = undefined;
+ promise._result = undefined;
+ promise._subscribers = [];
+}
+
+function Enumerator$1(Constructor, input) {
+ this._instanceConstructor = Constructor;
+ this.promise = new Constructor(noop);
+
+ if (!this.promise[PROMISE_ID]) {
+ makePromise(this.promise);
+ }
+
+ if (isArray(input)) {
+ this.length = input.length;
+ this._remaining = input.length;
+
+ this._result = new Array(this.length);
+
+ if (this.length === 0) {
+ fulfill(this.promise, this._result);
+ } else {
+ this.length = this.length || 0;
+ this._enumerate(input);
+ if (this._remaining === 0) {
+ fulfill(this.promise, this._result);
+ }
+ }
+ } else {
+ reject(this.promise, validationError());
+ }
+}
+
+function validationError() {
+ return new Error('Array Methods must be provided an Array');
+}
+
+Enumerator$1.prototype._enumerate = function (input) {
+ for (var i = 0; this._state === PENDING && i < input.length; i++) {
+ this._eachEntry(input[i], i);
+ }
+};
+
+Enumerator$1.prototype._eachEntry = function (entry, i) {
+ var c = this._instanceConstructor;
+ var resolve$$1 = c.resolve;
+
+ if (resolve$$1 === resolve$1) {
+ var _then = getThen(entry);
+
+ if (_then === then && entry._state !== PENDING) {
+ this._settledAt(entry._state, i, entry._result);
+ } else if (typeof _then !== 'function') {
+ this._remaining--;
+ this._result[i] = entry;
+ } else if (c === Promise$2) {
+ var promise = new c(noop);
+ handleMaybeThenable(promise, entry, _then);
+ this._willSettleAt(promise, i);
+ } else {
+ this._willSettleAt(new c(function (resolve$$1) {
+ return resolve$$1(entry);
+ }), i);
+ }
+ } else {
+ this._willSettleAt(resolve$$1(entry), i);
+ }
+};
+
+Enumerator$1.prototype._settledAt = function (state, i, value) {
+ var promise = this.promise;
+
+ if (promise._state === PENDING) {
+ this._remaining--;
+
+ if (state === REJECTED) {
+ reject(promise, value);
+ } else {
+ this._result[i] = value;
+ }
+ }
+
+ if (this._remaining === 0) {
+ fulfill(promise, this._result);
+ }
+};
+
+Enumerator$1.prototype._willSettleAt = function (promise, i) {
+ var enumerator = this;
+
+ subscribe(promise, undefined, function (value) {
+ return enumerator._settledAt(FULFILLED, i, value);
+ }, function (reason) {
+ return enumerator._settledAt(REJECTED, i, reason);
+ });
+};
+
+/**
+ `Promise.all` accepts an array of promises, and returns a new promise which
+ is fulfilled with an array of fulfillment values for the passed promises, or
+ rejected with the reason of the first passed promise to be rejected. It casts all
+ elements of the passed iterable to promises as it runs this algorithm.
+
+ Example:
+
+ ```javascript
+ let promise1 = resolve(1);
+ let promise2 = resolve(2);
+ let promise3 = resolve(3);
+ let promises = [ promise1, promise2, promise3 ];
+
+ Promise.all(promises).then(function(array){
+ // The array here would be [ 1, 2, 3 ];
+ });
+ ```
+
+ If any of the `promises` given to `all` are rejected, the first promise
+ that is rejected will be given as an argument to the returned promises's
+ rejection handler. For example:
+
+ Example:
+
+ ```javascript
+ let promise1 = resolve(1);
+ let promise2 = reject(new Error("2"));
+ let promise3 = reject(new Error("3"));
+ let promises = [ promise1, promise2, promise3 ];
+
+ Promise.all(promises).then(function(array){
+ // Code here never runs because there are rejected promises!
+ }, function(error) {
+ // error.message === "2"
+ });
+ ```
+
+ @method all
+ @static
+ @param {Array} entries array of promises
+ @param {String} label optional string for labeling the promise.
+ Useful for tooling.
+ @return {Promise} promise that is fulfilled when all `promises` have been
+ fulfilled, or rejected if any of them become rejected.
+ @static
+*/
+function all$1(entries) {
+ return new Enumerator$1(this, entries).promise;
+}
+
+/**
+ `Promise.race` returns a new promise which is settled in the same way as the
+ first passed promise to settle.
+
+ Example:
+
+ ```javascript
+ let promise1 = new Promise(function(resolve, reject){
+ setTimeout(function(){
+ resolve('promise 1');
+ }, 200);
+ });
+
+ let promise2 = new Promise(function(resolve, reject){
+ setTimeout(function(){
+ resolve('promise 2');
+ }, 100);
+ });
+
+ Promise.race([promise1, promise2]).then(function(result){
+ // result === 'promise 2' because it was resolved before promise1
+ // was resolved.
+ });
+ ```
+
+ `Promise.race` is deterministic in that only the state of the first
+ settled promise matters. For example, even if other promises given to the
+ `promises` array argument are resolved, but the first settled promise has
+ become rejected before the other promises became fulfilled, the returned
+ promise will become rejected:
+
+ ```javascript
+ let promise1 = new Promise(function(resolve, reject){
+ setTimeout(function(){
+ resolve('promise 1');
+ }, 200);
+ });
+
+ let promise2 = new Promise(function(resolve, reject){
+ setTimeout(function(){
+ reject(new Error('promise 2'));
+ }, 100);
+ });
+
+ Promise.race([promise1, promise2]).then(function(result){
+ // Code here never runs
+ }, function(reason){
+ // reason.message === 'promise 2' because promise 2 became rejected before
+ // promise 1 became fulfilled
+ });
+ ```
+
+ An example real-world use case is implementing timeouts:
+
+ ```javascript
+ Promise.race([ajax('foo.json'), timeout(5000)])
+ ```
+
+ @method race
+ @static
+ @param {Array} promises array of promises to observe
+ Useful for tooling.
+ @return {Promise} a promise which settles in the same way as the first passed
+ promise to settle.
+*/
+function race$1(entries) {
+ /*jshint validthis:true */
+ var Constructor = this;
+
+ if (!isArray(entries)) {
+ return new Constructor(function (_, reject) {
+ return reject(new TypeError('You must pass an array to race.'));
+ });
+ } else {
+ return new Constructor(function (resolve, reject) {
+ var length = entries.length;
+ for (var i = 0; i < length; i++) {
+ Constructor.resolve(entries[i]).then(resolve, reject);
+ }
+ });
+ }
+}
+
+/**
+ `Promise.reject` returns a promise rejected with the passed `reason`.
+ It is shorthand for the following:
+
+ ```javascript
+ let promise = new Promise(function(resolve, reject){
+ reject(new Error('WHOOPS'));
+ });
+
+ promise.then(function(value){
+ // Code here doesn't run because the promise is rejected!
+ }, function(reason){
+ // reason.message === 'WHOOPS'
+ });
+ ```
+
+ Instead of writing the above, your code now simply becomes the following:
+
+ ```javascript
+ let promise = Promise.reject(new Error('WHOOPS'));
+
+ promise.then(function(value){
+ // Code here doesn't run because the promise is rejected!
+ }, function(reason){
+ // reason.message === 'WHOOPS'
+ });
+ ```
+
+ @method reject
+ @static
+ @param {Any} reason value that the returned promise will be rejected with.
+ Useful for tooling.
+ @return {Promise} a promise rejected with the given `reason`.
+*/
+function reject$1(reason) {
+ /*jshint validthis:true */
+ var Constructor = this;
+ var promise = new Constructor(noop);
+ reject(promise, reason);
+ return promise;
+}
+
+function needsResolver() {
+ throw new TypeError('You must pass a resolver function as the first argument to the promise constructor');
+}
+
+function needsNew() {
+ throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.");
+}
+
+/**
+ Promise objects represent the eventual result of an asynchronous operation. The
+ primary way of interacting with a promise is through its `then` method, which
+ registers callbacks to receive either a promise's eventual value or the reason
+ why the promise cannot be fulfilled.
+
+ Terminology
+ -----------
+
+ - `promise` is an object or function with a `then` method whose behavior conforms to this specification.
+ - `thenable` is an object or function that defines a `then` method.
+ - `value` is any legal JavaScript value (including undefined, a thenable, or a promise).
+ - `exception` is a value that is thrown using the throw statement.
+ - `reason` is a value that indicates why a promise was rejected.
+ - `settled` the final resting state of a promise, fulfilled or rejected.
+
+ A promise can be in one of three states: pending, fulfilled, or rejected.
+
+ Promises that are fulfilled have a fulfillment value and are in the fulfilled
+ state. Promises that are rejected have a rejection reason and are in the
+ rejected state. A fulfillment value is never a thenable.
+
+ Promises can also be said to *resolve* a value. If this value is also a
+ promise, then the original promise's settled state will match the value's
+ settled state. So a promise that *resolves* a promise that rejects will
+ itself reject, and a promise that *resolves* a promise that fulfills will
+ itself fulfill.
+
+
+ Basic Usage:
+ ------------
+
+ ```js
+ let promise = new Promise(function(resolve, reject) {
+ // on success
+ resolve(value);
+
+ // on failure
+ reject(reason);
+ });
+
+ promise.then(function(value) {
+ // on fulfillment
+ }, function(reason) {
+ // on rejection
+ });
+ ```
+
+ Advanced Usage:
+ ---------------
+
+ Promises shine when abstracting away asynchronous interactions such as
+ `XMLHttpRequest`s.
+
+ ```js
+ function getJSON(url) {
+ return new Promise(function(resolve, reject){
+ let xhr = new XMLHttpRequest();
+
+ xhr.open('GET', url);
+ xhr.onreadystatechange = handler;
+ xhr.responseType = 'json';
+ xhr.setRequestHeader('Accept', 'application/json');
+ xhr.send();
+
+ function handler() {
+ if (this.readyState === this.DONE) {
+ if (this.status === 200) {
+ resolve(this.response);
+ } else {
+ reject(new Error('getJSON: `' + url + '` failed with status: [' + this.status + ']'));
+ }
+ }
+ };
+ });
+ }
+
+ getJSON('/posts.json').then(function(json) {
+ // on fulfillment
+ }, function(reason) {
+ // on rejection
+ });
+ ```
+
+ Unlike callbacks, promises are great composable primitives.
+
+ ```js
+ Promise.all([
+ getJSON('/posts'),
+ getJSON('/comments')
+ ]).then(function(values){
+ values[0] // => postsJSON
+ values[1] // => commentsJSON
+
+ return values;
+ });
+ ```
+
+ @class Promise
+ @param {function} resolver
+ Useful for tooling.
+ @constructor
+*/
+function Promise$2(resolver) {
+ this[PROMISE_ID] = nextId();
+ this._result = this._state = undefined;
+ this._subscribers = [];
+
+ if (noop !== resolver) {
+ typeof resolver !== 'function' && needsResolver();
+ this instanceof Promise$2 ? initializePromise(this, resolver) : needsNew();
+ }
+}
+
+Promise$2.all = all$1;
+Promise$2.race = race$1;
+Promise$2.resolve = resolve$1;
+Promise$2.reject = reject$1;
+Promise$2._setScheduler = setScheduler;
+Promise$2._setAsap = setAsap;
+Promise$2._asap = asap;
+
+Promise$2.prototype = {
+ constructor: Promise$2,
+
+ /**
+ The primary way of interacting with a promise is through its `then` method,
+ which registers callbacks to receive either a promise's eventual value or the
+ reason why the promise cannot be fulfilled.
+
+ ```js
+ findUser().then(function(user){
+ // user is available
+ }, function(reason){
+ // user is unavailable, and you are given the reason why
+ });
+ ```
+
+ Chaining
+ --------
+
+ The return value of `then` is itself a promise. This second, 'downstream'
+ promise is resolved with the return value of the first promise's fulfillment
+ or rejection handler, or rejected if the handler throws an exception.
+
+ ```js
+ findUser().then(function (user) {
+ return user.name;
+ }, function (reason) {
+ return 'default name';
+ }).then(function (userName) {
+ // If `findUser` fulfilled, `userName` will be the user's name, otherwise it
+ // will be `'default name'`
+ });
+
+ findUser().then(function (user) {
+ throw new Error('Found user, but still unhappy');
+ }, function (reason) {
+ throw new Error('`findUser` rejected and we're unhappy');
+ }).then(function (value) {
+ // never reached
+ }, function (reason) {
+ // if `findUser` fulfilled, `reason` will be 'Found user, but still unhappy'.
+ // If `findUser` rejected, `reason` will be '`findUser` rejected and we're unhappy'.
+ });
+ ```
+ If the downstream promise does not specify a rejection handler, rejection reasons will be propagated further downstream.
+
+ ```js
+ findUser().then(function (user) {
+ throw new PedagogicalException('Upstream error');
+ }).then(function (value) {
+ // never reached
+ }).then(function (value) {
+ // never reached
+ }, function (reason) {
+ // The `PedgagocialException` is propagated all the way down to here
+ });
+ ```
+
+ Assimilation
+ ------------
+
+ Sometimes the value you want to propagate to a downstream promise can only be
+ retrieved asynchronously. This can be achieved by returning a promise in the
+ fulfillment or rejection handler. The downstream promise will then be pending
+ until the returned promise is settled. This is called *assimilation*.
+
+ ```js
+ findUser().then(function (user) {
+ return findCommentsByAuthor(user);
+ }).then(function (comments) {
+ // The user's comments are now available
+ });
+ ```
+
+ If the assimliated promise rejects, then the downstream promise will also reject.
+
+ ```js
+ findUser().then(function (user) {
+ return findCommentsByAuthor(user);
+ }).then(function (comments) {
+ // If `findCommentsByAuthor` fulfills, we'll have the value here
+ }, function (reason) {
+ // If `findCommentsByAuthor` rejects, we'll have the reason here
+ });
+ ```
+
+ Simple Example
+ --------------
+
+ Synchronous Example
+
+ ```javascript
+ let result;
+
+ try {
+ result = findResult();
+ // success
+ } catch(reason) {
+ // failure
+ }
+ ```
+
+ Errback Example
+
+ ```js
+ findResult(function(result, err){
+ if (err) {
+ // failure
+ } else {
+ // success
+ }
+ });
+ ```
+
+ Promise Example;
+
+ ```javascript
+ findResult().then(function(result){
+ // success
+ }, function(reason){
+ // failure
+ });
+ ```
+
+ Advanced Example
+ --------------
+
+ Synchronous Example
+
+ ```javascript
+ let author, books;
+
+ try {
+ author = findAuthor();
+ books = findBooksByAuthor(author);
+ // success
+ } catch(reason) {
+ // failure
+ }
+ ```
+
+ Errback Example
+
+ ```js
+
+ function foundBooks(books) {
+
+ }
+
+ function failure(reason) {
+
+ }
+
+ findAuthor(function(author, err){
+ if (err) {
+ failure(err);
+ // failure
+ } else {
+ try {
+ findBoooksByAuthor(author, function(books, err) {
+ if (err) {
+ failure(err);
+ } else {
+ try {
+ foundBooks(books);
+ } catch(reason) {
+ failure(reason);
+ }
+ }
+ });
+ } catch(error) {
+ failure(err);
+ }
+ // success
+ }
+ });
+ ```
+
+ Promise Example;
+
+ ```javascript
+ findAuthor().
+ then(findBooksByAuthor).
+ then(function(books){
+ // found books
+ }).catch(function(reason){
+ // something went wrong
+ });
+ ```
+
+ @method then
+ @param {Function} onFulfilled
+ @param {Function} onRejected
+ Useful for tooling.
+ @return {Promise}
+ */
+ then: then,
+
+ /**
+ `catch` is simply sugar for `then(undefined, onRejection)` which makes it the same
+ as the catch block of a try/catch statement.
+
+ ```js
+ function findAuthor(){
+ throw new Error('couldn't find that author');
+ }
+
+ // synchronous
+ try {
+ findAuthor();
+ } catch(reason) {
+ // something went wrong
+ }
+
+ // async with promises
+ findAuthor().catch(function(reason){
+ // something went wrong
+ });
+ ```
+
+ @method catch
+ @param {Function} onRejection
+ Useful for tooling.
+ @return {Promise}
+ */
+ 'catch': function _catch(onRejection) {
+ return this.then(null, onRejection);
+ }
+};
+
+/*global self*/
+function polyfill$1() {
+ var local = undefined;
+
+ if (typeof global !== 'undefined') {
+ local = global;
+ } else if (typeof self !== 'undefined') {
+ local = self;
+ } else {
+ try {
+ local = Function('return this')();
+ } catch (e) {
+ throw new Error('polyfill failed because global object is unavailable in this environment');
+ }
+ }
+
+ var P = local.Promise;
+
+ if (P) {
+ var promiseToString = null;
+ try {
+ promiseToString = Object.prototype.toString.call(P.resolve());
+ } catch (e) {
+ // silently ignored
+ }
+
+ if (promiseToString === '[object Promise]' && !P.cast) {
+ return;
+ }
+ }
+
+ local.Promise = Promise$2;
+}
+
+// Strange compat..
+Promise$2.polyfill = polyfill$1;
+Promise$2.Promise = Promise$2;
+
+return Promise$2;
+
+})));
+
+//# sourceMappingURL=es6-promise.map
+
+/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7), __webpack_require__(8)))
+
+/***/ }),
+/* 5 */
+/***/ (function(module, exports) {
+
+// removed by extract-text-webpack-plugin
+
+/***/ }),
+/* 6 */
+/***/ (function(module, exports, __webpack_require__) {
+
+"use strict";
+
+
+Object.defineProperty(exports, "__esModule", {
+ value: true
+});
+
+var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); /* global VERSION */
+
+__webpack_require__(5);
+
+var _es6Promise = __webpack_require__(4);
+
+var _es6Promise2 = _interopRequireDefault(_es6Promise);
+
+var _utils = __webpack_require__(0);
+
+var Utils = _interopRequireWildcard(_utils);
+
+var _api = __webpack_require__(1);
+
+var API = _interopRequireWildcard(_api);
+
+var _button = __webpack_require__(2);
+
+var _push = __webpack_require__(3);
+
+function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+
+var Noty = function () {
+ /**
+ * @param {object} options
+ * @return {Noty}
+ */
+ function Noty() {
+ var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
+
+ _classCallCheck(this, Noty);
+
+ this.options = Utils.deepExtend({}, API.Defaults, options);
+
+ if (API.Store[this.options.id]) {
+ return API.Store[this.options.id];
+ }
+
+ this.id = this.options.id || Utils.generateID('bar');
+ this.closeTimer = -1;
+ this.barDom = null;
+ this.layoutDom = null;
+ this.progressDom = null;
+ this.showing = false;
+ this.shown = false;
+ this.closed = false;
+ this.closing = false;
+ this.killable = this.options.timeout || this.options.closeWith.length > 0;
+ this.hasSound = this.options.sounds.sources.length > 0;
+ this.soundPlayed = false;
+ this.listeners = {
+ beforeShow: [],
+ onShow: [],
+ afterShow: [],
+ onClose: [],
+ afterClose: [],
+ onClick: [],
+ onHover: [],
+ onTemplate: []
+ };
+ this.promises = {
+ show: null,
+ close: null
+ };
+ this.on('beforeShow', this.options.callbacks.beforeShow);
+ this.on('onShow', this.options.callbacks.onShow);
+ this.on('afterShow', this.options.callbacks.afterShow);
+ this.on('onClose', this.options.callbacks.onClose);
+ this.on('afterClose', this.options.callbacks.afterClose);
+ this.on('onClick', this.options.callbacks.onClick);
+ this.on('onHover', this.options.callbacks.onHover);
+ this.on('onTemplate', this.options.callbacks.onTemplate);
+
+ return this;
+ }
+
+ /**
+ * @param {string} eventName
+ * @param {function} cb
+ * @return {Noty}
+ */
+
+
+ _createClass(Noty, [{
+ key: 'on',
+ value: function on(eventName) {
+ var cb = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : function () {};
+
+ if (typeof cb === 'function' && this.listeners.hasOwnProperty(eventName)) {
+ this.listeners[eventName].push(cb);
+ }
+
+ return this;
+ }
+
+ /**
+ * @return {Noty}
+ */
+
+ }, {
+ key: 'show',
+ value: function show() {
+ var _this = this;
+
+ if (this.showing || this.shown) {
+ return this; // preventing multiple show
+ }
+
+ if (this.options.killer === true) {
+ Noty.closeAll();
+ } else if (typeof this.options.killer === 'string') {
+ Noty.closeAll(this.options.killer);
+ }
+
+ var queueCounts = API.getQueueCounts(this.options.queue);
+
+ if (queueCounts.current >= queueCounts.maxVisible || API.PageHidden && this.options.visibilityControl) {
+ API.addToQueue(this);
+
+ if (API.PageHidden && this.hasSound && Utils.inArray('docHidden', this.options.sounds.conditions)) {
+ Utils.createAudioElements(this);
+ }
+
+ if (API.PageHidden && Utils.inArray('docHidden', this.options.titleCount.conditions)) {
+ API.docTitle.increment();
+ }
+
+ return this;
+ }
+
+ API.Store[this.id] = this;
+
+ API.fire(this, 'beforeShow');
+
+ this.showing = true;
+
+ if (this.closing) {
+ this.showing = false;
+ return this;
+ }
+
+ API.build(this);
+ API.handleModal(this);
+
+ if (this.options.force) {
+ this.layoutDom.insertBefore(this.barDom, this.layoutDom.firstChild);
+ } else {
+ this.layoutDom.appendChild(this.barDom);
+ }
+
+ if (this.hasSound && !this.soundPlayed && Utils.inArray('docVisible', this.options.sounds.conditions)) {
+ Utils.createAudioElements(this);
+ }
+
+ if (Utils.inArray('docVisible', this.options.titleCount.conditions)) {
+ API.docTitle.increment();
+ }
+
+ this.shown = true;
+ this.closed = false;
+
+ // bind button events if any
+ if (API.hasButtons(this)) {
+ Object.keys(this.options.buttons).forEach(function (key) {
+ var btn = _this.barDom.querySelector('#' + _this.options.buttons[key].id);
+ Utils.addListener(btn, 'click', function (e) {
+ Utils.stopPropagation(e);
+ _this.options.buttons[key].cb(_this);
+ });
+ });
+ }
+
+ this.progressDom = this.barDom.querySelector('.noty_progressbar');
+
+ if (Utils.inArray('click', this.options.closeWith)) {
+ Utils.addClass(this.barDom, 'noty_close_with_click');
+ Utils.addListener(this.barDom, 'click', function (e) {
+ Utils.stopPropagation(e);
+ API.fire(_this, 'onClick');
+ _this.close();
+ }, false);
+ }
+
+ Utils.addListener(this.barDom, 'mouseenter', function () {
+ API.fire(_this, 'onHover');
+ }, false);
+
+ if (this.options.timeout) Utils.addClass(this.barDom, 'noty_has_timeout');
+ if (this.options.progressBar) {
+ Utils.addClass(this.barDom, 'noty_has_progressbar');
+ }
+
+ if (Utils.inArray('button', this.options.closeWith)) {
+ Utils.addClass(this.barDom, 'noty_close_with_button');
+
+ var closeButton = document.createElement('div');
+ Utils.addClass(closeButton, 'noty_close_button');
+ closeButton.innerHTML = '×';
+ this.barDom.appendChild(closeButton);
+
+ Utils.addListener(closeButton, 'click', function (e) {
+ Utils.stopPropagation(e);
+ _this.close();
+ }, false);
+ }
+
+ API.fire(this, 'onShow');
+
+ if (this.options.animation.open === null) {
+ this.promises.show = new _es6Promise2.default(function (resolve) {
+ resolve();
+ });
+ } else if (typeof this.options.animation.open === 'function') {
+ this.promises.show = new _es6Promise2.default(this.options.animation.open.bind(this));
+ } else {
+ Utils.addClass(this.barDom, this.options.animation.open);
+ this.promises.show = new _es6Promise2.default(function (resolve) {
+ Utils.addListener(_this.barDom, Utils.animationEndEvents, function () {
+ Utils.removeClass(_this.barDom, _this.options.animation.open);
+ resolve();
+ });
+ });
+ }
+
+ this.promises.show.then(function () {
+ var _t = _this;
+ setTimeout(function () {
+ API.openFlow(_t);
+ }, 100);
+ });
+
+ return this;
+ }
+
+ /**
+ * @return {Noty}
+ */
+
+ }, {
+ key: 'stop',
+ value: function stop() {
+ API.dequeueClose(this);
+ return this;
+ }
+
+ /**
+ * @return {Noty}
+ */
+
+ }, {
+ key: 'resume',
+ value: function resume() {
+ API.queueClose(this);
+ return this;
+ }
+
+ /**
+ * @param {int|boolean} ms
+ * @return {Noty}
+ */
+
+ }, {
+ key: 'setTimeout',
+ value: function (_setTimeout) {
+ function setTimeout(_x) {
+ return _setTimeout.apply(this, arguments);
+ }
+
+ setTimeout.toString = function () {
+ return _setTimeout.toString();
+ };
+
+ return setTimeout;
+ }(function (ms) {
+ this.stop();
+ this.options.timeout = ms;
+
+ if (this.barDom) {
+ if (this.options.timeout) {
+ Utils.addClass(this.barDom, 'noty_has_timeout');
+ } else {
+ Utils.removeClass(this.barDom, 'noty_has_timeout');
+ }
+
+ var _t = this;
+ setTimeout(function () {
+ // ugly fix for progressbar display bug
+ _t.resume();
+ }, 100);
+ }
+
+ return this;
+ })
+
+ /**
+ * @param {string} html
+ * @param {boolean} optionsOverride
+ * @return {Noty}
+ */
+
+ }, {
+ key: 'setText',
+ value: function setText(html) {
+ var optionsOverride = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
+
+ if (this.barDom) {
+ this.barDom.querySelector('.noty_body').innerHTML = html;
+ }
+
+ if (optionsOverride) this.options.text = html;
+
+ return this;
+ }
+
+ /**
+ * @param {string} type
+ * @param {boolean} optionsOverride
+ * @return {Noty}
+ */
+
+ }, {
+ key: 'setType',
+ value: function setType(type) {
+ var _this2 = this;
+
+ var optionsOverride = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
+
+ if (this.barDom) {
+ var classList = Utils.classList(this.barDom).split(' ');
+
+ classList.forEach(function (c) {
+ if (c.substring(0, 11) === 'noty_type__') {
+ Utils.removeClass(_this2.barDom, c);
+ }
+ });
+
+ Utils.addClass(this.barDom, 'noty_type__' + type);
+ }
+
+ if (optionsOverride) this.options.type = type;
+
+ return this;
+ }
+
+ /**
+ * @param {string} theme
+ * @param {boolean} optionsOverride
+ * @return {Noty}
+ */
+
+ }, {
+ key: 'setTheme',
+ value: function setTheme(theme) {
+ var _this3 = this;
+
+ var optionsOverride = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
+
+ if (this.barDom) {
+ var classList = Utils.classList(this.barDom).split(' ');
+
+ classList.forEach(function (c) {
+ if (c.substring(0, 12) === 'noty_theme__') {
+ Utils.removeClass(_this3.barDom, c);
+ }
+ });
+
+ Utils.addClass(this.barDom, 'noty_theme__' + theme);
+ }
+
+ if (optionsOverride) this.options.theme = theme;
+
+ return this;
+ }
+
+ /**
+ * @return {Noty}
+ */
+
+ }, {
+ key: 'close',
+ value: function close() {
+ var _this4 = this;
+
+ if (this.closed) return this;
+
+ if (!this.shown) {
+ // it's in the queue
+ API.removeFromQueue(this);
+ return this;
+ }
+
+ API.fire(this, 'onClose');
+
+ this.closing = true;
+
+ if (this.options.animation.close === null || this.options.animation.close === false) {
+ this.promises.close = new _es6Promise2.default(function (resolve) {
+ resolve();
+ });
+ } else if (typeof this.options.animation.close === 'function') {
+ this.promises.close = new _es6Promise2.default(this.options.animation.close.bind(this));
+ } else {
+ Utils.addClass(this.barDom, this.options.animation.close);
+ this.promises.close = new _es6Promise2.default(function (resolve) {
+ Utils.addListener(_this4.barDom, Utils.animationEndEvents, function () {
+ if (_this4.options.force) {
+ Utils.remove(_this4.barDom);
+ } else {
+ API.ghostFix(_this4);
+ }
+ resolve();
+ });
+ });
+ }
+
+ this.promises.close.then(function () {
+ API.closeFlow(_this4);
+ API.handleModalClose(_this4);
+ });
+
+ this.closed = true;
+
+ return this;
+ }
+
+ // API functions
+
+ /**
+ * @param {boolean|string} queueName
+ * @return {Noty}
+ */
+
+ }], [{
+ key: 'closeAll',
+ value: function closeAll() {
+ var queueName = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
+
+ Object.keys(API.Store).forEach(function (id) {
+ if (queueName) {
+ if (API.Store[id].options.queue === queueName && API.Store[id].killable) {
+ API.Store[id].close();
+ }
+ } else if (API.Store[id].killable) {
+ API.Store[id].close();
+ }
+ });
+ return this;
+ }
+
+ /**
+ * @param {string} queueName
+ * @return {Noty}
+ */
+
+ }, {
+ key: 'clearQueue',
+ value: function clearQueue() {
+ var queueName = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'global';
+
+ if (API.Queues.hasOwnProperty(queueName)) {
+ API.Queues[queueName].queue = [];
+ }
+ return this;
+ }
+
+ /**
+ * @return {API.Queues}
+ */
+
+ }, {
+ key: 'overrideDefaults',
+
+
+ /**
+ * @param {Object} obj
+ * @return {Noty}
+ */
+ value: function overrideDefaults(obj) {
+ API.Defaults = Utils.deepExtend({}, API.Defaults, obj);
+ return this;
+ }
+
+ /**
+ * @param {int} amount
+ * @param {string} queueName
+ * @return {Noty}
+ */
+
+ }, {
+ key: 'setMaxVisible',
+ value: function setMaxVisible() {
+ var amount = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : API.DefaultMaxVisible;
+ var queueName = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'global';
+
+ if (!API.Queues.hasOwnProperty(queueName)) {
+ API.Queues[queueName] = { maxVisible: amount, queue: [] };
+ }
+
+ API.Queues[queueName].maxVisible = amount;
+ return this;
+ }
+
+ /**
+ * @param {string} innerHtml
+ * @param {String} classes
+ * @param {Function} cb
+ * @param {Object} attributes
+ * @return {NotyButton}
+ */
+
+ }, {
+ key: 'button',
+ value: function button(innerHtml) {
+ var classes = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
+ var cb = arguments[2];
+ var attributes = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
+
+ return new _button.NotyButton(innerHtml, classes, cb, attributes);
+ }
+
+ /**
+ * @return {string}
+ */
+
+ }, {
+ key: 'version',
+ value: function version() {
+ return "3.2.0-beta";
+ }
+
+ /**
+ * @param {String} workerPath
+ * @return {Push}
+ */
+
+ }, {
+ key: 'Push',
+ value: function Push(workerPath) {
+ return new _push.Push(workerPath);
+ }
+ }, {
+ key: 'Queues',
+ get: function get() {
+ return API.Queues;
+ }
+
+ /**
+ * @return {API.PageHidden}
+ */
+
+ }, {
+ key: 'PageHidden',
+ get: function get() {
+ return API.PageHidden;
+ }
+ }]);
+
+ return Noty;
+}();
+
+// Document visibility change controller
+
+
+exports.default = Noty;
+if (typeof window !== 'undefined') {
+ Utils.visibilityChangeFlow();
+}
+module.exports = exports['default'];
+
+/***/ }),
+/* 7 */
+/***/ (function(module, exports) {
+
+// shim for using process in browser
+var process = module.exports = {};
+
+// cached from whatever global is present so that test runners that stub it
+// don't break things. But we need to wrap it in a try catch in case it is
+// wrapped in strict mode code which doesn't define any globals. It's inside a
+// function because try/catches deoptimize in certain engines.
+
+var cachedSetTimeout;
+var cachedClearTimeout;
+
+function defaultSetTimout() {
+ throw new Error('setTimeout has not been defined');
+}
+function defaultClearTimeout () {
+ throw new Error('clearTimeout has not been defined');
+}
+(function () {
+ try {
+ if (typeof setTimeout === 'function') {
+ cachedSetTimeout = setTimeout;
+ } else {
+ cachedSetTimeout = defaultSetTimout;
+ }
+ } catch (e) {
+ cachedSetTimeout = defaultSetTimout;
+ }
+ try {
+ if (typeof clearTimeout === 'function') {
+ cachedClearTimeout = clearTimeout;
+ } else {
+ cachedClearTimeout = defaultClearTimeout;
+ }
+ } catch (e) {
+ cachedClearTimeout = defaultClearTimeout;
+ }
+} ())
+function runTimeout(fun) {
+ if (cachedSetTimeout === setTimeout) {
+ //normal enviroments in sane situations
+ return setTimeout(fun, 0);
+ }
+ // if setTimeout wasn't available but was latter defined
+ if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {
+ cachedSetTimeout = setTimeout;
+ return setTimeout(fun, 0);
+ }
+ try {
+ // when when somebody has screwed with setTimeout but no I.E. maddness
+ return cachedSetTimeout(fun, 0);
+ } catch(e){
+ try {
+ // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
+ return cachedSetTimeout.call(null, fun, 0);
+ } catch(e){
+ // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error
+ return cachedSetTimeout.call(this, fun, 0);
+ }
+ }
+
+
+}
+function runClearTimeout(marker) {
+ if (cachedClearTimeout === clearTimeout) {
+ //normal enviroments in sane situations
+ return clearTimeout(marker);
+ }
+ // if clearTimeout wasn't available but was latter defined
+ if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {
+ cachedClearTimeout = clearTimeout;
+ return clearTimeout(marker);
+ }
+ try {
+ // when when somebody has screwed with setTimeout but no I.E. maddness
+ return cachedClearTimeout(marker);
+ } catch (e){
+ try {
+ // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
+ return cachedClearTimeout.call(null, marker);
+ } catch (e){
+ // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.
+ // Some versions of I.E. have different rules for clearTimeout vs setTimeout
+ return cachedClearTimeout.call(this, marker);
+ }
+ }
+
+
+
+}
+var queue = [];
+var draining = false;
+var currentQueue;
+var queueIndex = -1;
+
+function cleanUpNextTick() {
+ if (!draining || !currentQueue) {
+ return;
+ }
+ draining = false;
+ if (currentQueue.length) {
+ queue = currentQueue.concat(queue);
+ } else {
+ queueIndex = -1;
+ }
+ if (queue.length) {
+ drainQueue();
+ }
+}
+
+function drainQueue() {
+ if (draining) {
+ return;
+ }
+ var timeout = runTimeout(cleanUpNextTick);
+ draining = true;
+
+ var len = queue.length;
+ while(len) {
+ currentQueue = queue;
+ queue = [];
+ while (++queueIndex < len) {
+ if (currentQueue) {
+ currentQueue[queueIndex].run();
+ }
+ }
+ queueIndex = -1;
+ len = queue.length;
+ }
+ currentQueue = null;
+ draining = false;
+ runClearTimeout(timeout);
+}
+
+process.nextTick = function (fun) {
+ var args = new Array(arguments.length - 1);
+ if (arguments.length > 1) {
+ for (var i = 1; i < arguments.length; i++) {
+ args[i - 1] = arguments[i];
+ }
+ }
+ queue.push(new Item(fun, args));
+ if (queue.length === 1 && !draining) {
+ runTimeout(drainQueue);
+ }
+};
+
+// v8 likes predictible objects
+function Item(fun, array) {
+ this.fun = fun;
+ this.array = array;
+}
+Item.prototype.run = function () {
+ this.fun.apply(null, this.array);
+};
+process.title = 'browser';
+process.browser = true;
+process.env = {};
+process.argv = [];
+process.version = ''; // empty string to avoid regexp issues
+process.versions = {};
+
+function noop() {}
+
+process.on = noop;
+process.addListener = noop;
+process.once = noop;
+process.off = noop;
+process.removeListener = noop;
+process.removeAllListeners = noop;
+process.emit = noop;
+process.prependListener = noop;
+process.prependOnceListener = noop;
+
+process.listeners = function (name) { return [] }
+
+process.binding = function (name) {
+ throw new Error('process.binding is not supported');
+};
+
+process.cwd = function () { return '/' };
+process.chdir = function (dir) {
+ throw new Error('process.chdir is not supported');
+};
+process.umask = function() { return 0; };
+
+
+/***/ }),
+/* 8 */
+/***/ (function(module, exports) {
+
+var g;
+
+// This works in non-strict mode
+g = (function() {
+ return this;
+})();
+
+try {
+ // This works if eval is allowed (see CSP)
+ g = g || Function("return this")() || (1,eval)("this");
+} catch(e) {
+ // This works if the window reference is available
+ if(typeof window === "object")
+ g = window;
+}
+
+// g can still be undefined, but nothing to do about it...
+// We return undefined, instead of nothing here, so it's
+// easier to handle this case. if(!global) { ...}
+
+module.exports = g;
+
+
+/***/ }),
+/* 9 */
+/***/ (function(module, exports) {
+
+/* (ignored) */
+
+/***/ })
+/******/ ]);
+});
+//# sourceMappingURL=noty.js.map
\ No newline at end of file
diff --git a/node_modules/noty/lib/noty.js.map b/node_modules/noty/lib/noty.js.map
new file mode 100644
index 0000000..f9d3d8b
--- /dev/null
+++ b/node_modules/noty/lib/noty.js.map
@@ -0,0 +1 @@
+{"version":3,"sources":["webpack:///webpack/universalModuleDefinition","webpack:///webpack/bootstrap 13c137d60d3e439c3a2f","webpack:///./src/utils.js","webpack:///./src/api.js","webpack:///./src/button.js","webpack:///./src/push.js","webpack:///./~/es6-promise/dist/es6-promise.js","webpack:///./src/noty.scss","webpack:///./src/index.js","webpack:///./~/process/browser.js","webpack:///(webpack)/buildin/global.js","webpack:///vertx (ignored)"],"names":["inArray","stopPropagation","generateID","outerHeight","addListener","hasClass","addClass","removeClass","remove","classList","visibilityChangeFlow","createAudioElements","API","animationEndEvents","needle","haystack","argStrict","key","strict","hasOwnProperty","evt","window","event","cancelBubble","deepExtend","out","i","arguments","length","obj","Array","isArray","prefix","id","replace","c","r","Math","random","v","toString","el","height","offsetHeight","style","getComputedStyle","parseInt","marginTop","marginBottom","css","cssPrefixes","cssProps","camelCase","string","match","letter","toUpperCase","getVendorProp","name","document","body","capName","charAt","slice","vendorName","getStyleProp","applyCss","element","prop","value","properties","args","undefined","events","cb","useCapture","split","addEventListener","attachEvent","list","indexOf","oldList","newList","className","substring","parentNode","removeChild","hidden","visibilityChange","msHidden","webkitHidden","onVisibilityChange","PageHidden","handleVisibilityChange","onBlur","onFocus","stopAll","resumeAll","setTimeout","Object","keys","Store","forEach","options","visibilityControl","stop","resume","queueRenderAll","ref","hasSound","audioElement","createElement","sounds","sources","source","src","s","type","getExtension","appendChild","barDom","querySelector","volume","soundPlayed","play","onended","fileName","getQueueCounts","addToQueue","removeFromQueue","queueRender","ghostFix","build","hasButtons","handleModal","handleModalClose","queueClose","dequeueClose","fire","openFlow","closeFlow","Utils","DocModalCount","DocTitleProps","originalTitle","count","changed","timer","docTitle","increment","_update","decrement","_clear","title","DefaultMaxVisible","Queues","global","maxVisible","queue","Defaults","layout","theme","text","timeout","progressBar","closeWith","animation","open","close","force","killer","container","buttons","callbacks","beforeShow","onShow","afterShow","onClose","afterClose","onClick","onHover","onTemplate","conditions","titleCount","modal","queueName","max","closed","current","push","noty","shift","show","ghostID","ghost","setAttribute","insertAdjacentHTML","outerHTML","getElementById","findOrCreateContainer","markup","buildButtons","innerHTML","dom","btn","createModal","insertBefore","firstChild","layoutDom","layoutID","progressDom","transition","width","clearTimeout","closeTimer","eventName","listeners","apply","closing","querySelectorAll","NotyButton","html","classes","attributes","propertyName","Push","workerPath","subData","onPermissionGranted","onPermissionDenied","onSubscriptionSuccess","onSubscriptionCancel","onWorkerError","onWorkerSuccess","onWorkerNotSupported","params","console","log","result","Notification","webkitNotifications","navigator","mozNotification","external","msIsSiteMode","e","perm","permissionLevel","checkPermission","permission","toLowerCase","subscription","endpoint","subscriptionId","serviceWorker","controller","state","self","getRegistrations","then","registrations","registration","unregister","userVisibleOnly","getPermissionStatus","register","ready","serviceWorkerRegistration","pushManager","subscribe","getKey","token","getEndpoint","p256dh","btoa","String","fromCharCode","Uint8Array","auth","catch","err","unregisterWorker","requestPermission","Noty","showing","shown","killable","promises","on","closeAll","queueCounts","closeButton","resolve","bind","_t","ms","optionsOverride","amount","innerHtml"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,O;ACVA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;;AAGA;AACA;;AAEA;AACA;;AAEA;AACA,mDAA2C,cAAc;;AAEzD;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAK;AACL;AACA;;AAEA;AACA;AACA;AACA,mCAA2B,0BAA0B,EAAE;AACvD,yCAAiC,eAAe;AAChD;AACA;AACA;;AAEA;AACA,8DAAsD,+DAA+D;;AAErH;AACA;;AAEA;AACA;;;;;;;;;;;;;;;;;QC5DgBA,O,GAAAA,O;QAoBAC,e,GAAAA,e;QAkCAC,U,GAAAA,U;QAYAC,W,GAAAA,W;QAkEAC,W,GAAAA,W;QAWAC,Q,GAAAA,Q;QAKAC,Q,GAAAA,Q;QAUAC,W,GAAAA,W;QAaAC,M,GAAAA,M;QAMAC,S,GAAAA,S;QAOAC,oB,GAAAA,oB;QA0EAC,mB,GAAAA,mB;;AAtQhB;;IAAYC,G;;;;AAEL,IAAMC,kDAAqB,8EAA3B;;AAEA,SAASb,OAAT,CAAkBc,MAAlB,EAA0BC,QAA1B,EAAoCC,SAApC,EAA+C;AACpD,MAAIC,YAAJ;AACA,MAAIC,SAAS,CAAC,CAACF,SAAf;;AAEA,MAAIE,MAAJ,EAAY;AACV,SAAKD,GAAL,IAA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KpG,IAAL,CAAU,oBAAV;AACA,iBAAK+I,gBAAL;AACD;AACF,OAjDD;;AAmDA,UAAI7F,YAAY,SAAhB,EAA2B;AACzB,YAAIvK,OAAO0N,YAAP,IAAuB1N,OAAO0N,YAAP,CAAoB2C,iBAA/C,EAAkE;AAChErQ,iBAAO0N,YAAP,CAAoB2C,iBAApB,CAAsChN,EAAtC;AACD,SAFD,MAEO,IACLrD,OAAO2N,mBAAP,IAA8B3N,OAAO2N,mBAAP,CAA2BQ,eADpD,EAEL;AACAnO,iBAAO2N,mBAAP,CAA2B0C,iBAA3B,CAA6ChN,EAA7C;AACD;AACF,OARD,MAQO;AACLA,WAAGkH,OAAH;AACD;AACF;;;;;;;;;;uDC1MH;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,CAAC,qBAAqB;;AAEtB;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,iFAAiF;;AAEjF;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA,0BAA0B,sBAAsB;;AAEhD;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,iBAAiB,SAAS;AAC1B;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,CAAC;AACD;AACA,CAAC;AACD;AACA,CAAC;AACD;AACA,CAAC;AACD;AACA;;AAEA;AACA;;AAEA;;AAEA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP,KAAK;AACL,GAAG;AACH;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,GAAG;;AAEH;AACA;AACA,GAAG;AACH;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA,GAAG;AACH;;AAEA;AACA;AACA,UAAU,IAAI;AACd;AACA,WAAW,QAAQ;AACnB;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;;AAEA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;;AAEA;AACA,KAAK;;AAEL;AACA;AACA;AACA;AACA,GAAG;AACH;;AAEA;AACA;AACA;AACA,GAAG;AACH;AACA,GAAG;AACH;AACA;AACA,KAAK;AACL;AACA,KAAK;AACL;AACA;;AAEA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA,KAAK;AACL;AACA,KAAK;AACL;AACA,KAAK;AACL;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,GAAG;AACH;AACA,GAAG;AACH;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA,iBAAiB,wBAAwB;AACzC;AACA;;AAEA;AACA;AACA,KAAK;AACL;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;;AAEA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;;AAEA;AACA;AACA,GAAG;AACH;AACA,KAAK;AACL;AACA,KAAK;AACL;AACA,KAAK;AACL;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA,KAAK;AACL,GAAG;AACH;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA,iBAAiB,6CAA6C;AAC9D;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA,KAAK;AACL;AACA;AACA,KAAK;AACL;AACA;AACA;AACA,KAAK;AACL;AACA;AACA,OAAO;AACP;AACA,GAAG;AACH;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA,KAAK;AACL;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA,GAAG;AACH;AACA,GAAG;AACH;;AAEA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,GAAG;AACH;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,GAAG;AACH;AACA,GAAG;AACH;;AAEA;AACA;AACA,UAAU,MAAM;AAChB,UAAU,OAAO;AACjB;AACA,WAAW,QAAQ;AACnB;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA,KAAK;AACL,GAAG;;AAEH;AACA;AACA;AACA,KAAK;AACL,GAAG;;AAEH;AACA;AACA;AACA,GAAG;AACH;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,KAAK;AACL,GAAG;;AAEH;AACA;AACA;AACA,KAAK;AACL,GAAG;;AAEH;AACA;AACA,GAAG;AACH;AACA;AACA,GAAG;AACH;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA,UAAU,MAAM;AAChB;AACA,WAAW,QAAQ;AACnB;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,KAAK;AACL,GAAG;AACH;AACA;AACA,qBAAqB,YAAY;AACjC;AACA;AACA,KAAK;AACL;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,GAAG;;AAEH;AACA;AACA,GAAG;AACH;AACA,GAAG;AACH;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA,GAAG;AACH;AACA,GAAG;AACH;;AAEA;AACA;AACA,UAAU,IAAI;AACd;AACA,WAAW,QAAQ;AACnB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;;AAGA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA,GAAG;;AAEH;AACA;AACA,GAAG;AACH;AACA,GAAG;AACH;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,WAAW;AACX;AACA;AACA;AACA;AACA,KAAK;AACL;;AAEA;AACA;AACA,GAAG;AACH;AACA,GAAG;AACH;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,GAAG;AACH;;AAEA;AACA,UAAU,SAAS;AACnB;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,KAAK;AACL;AACA,KAAK;AACL;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,KAAK;AACL;AACA,KAAK;AACL;AACA;AACA,KAAK;;AAEL;AACA;AACA,KAAK;AACL;AACA,KAAK;AACL;AACA,KAAK;AACL;AACA;AACA,KAAK;AACL;AACA;;AAEA;AACA;AACA;AACA,KAAK;AACL;AACA,KAAK;AACL;AACA,KAAK;AACL;AACA,KAAK;AACL;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,KAAK;AACL;AACA,KAAK;AACL;;AAEA;;AAEA;AACA;AACA;AACA,KAAK;AACL;AACA,KAAK;AACL;AACA,KAAK;AACL;;AAEA;AACA;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA,KAAK;AACL;;AAEA;;AAEA;AACA;AACA;AACA,KAAK;AACL;AACA,KAAK;AACL;;AAEA;AACA;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;;AAEA;;AAEA;;AAEA;;AAEA;;AAEA;;AAEA;;AAEA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA,aAAa;AACb;AACA;AACA,eAAe;AACf;AACA;AACA;AACA,WAAW;AACX,SAAS;AACT;AACA;AACA;AACA;AACA,KAAK;AACL;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA,KAAK;AACL;;AAEA;AACA,YAAY,SAAS;AACrB,YAAY,SAAS;AACrB;AACA,aAAa;AACb;AACA;;AAEA;AAC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;;;yBAIaG,U,EAAY;AACvB,aAAO,eAASA,UAAT,CAAP;AACD;;;wBA1DoB;AACnB,aAAOtN,IAAI+I,MAAX;AACD;;AAED;;;;;;wBAGyB;AACvB,aAAO/I,IAAIgF,UAAX;AACD;;;;;;AAoDH;;;kBAheqB+L,I;AAierB,IAAI,OAAOtQ,MAAP,KAAkB,WAAtB,EAAmC;AACjCwH,QAAMnI,oBAAN;AACD;;;;;;;AC5eD;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA,KAAK;AACL;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;;;AAGA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;;;;AAIA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,uBAAuB,sBAAsB;AAC7C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qBAAqB;AACrB;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,qCAAqC;;AAErC;AACA;AACA;;AAEA,2BAA2B;AAC3B;AACA;AACA;AACA,4BAA4B,UAAU;;;;;;;ACvLtC;;AAEA;AACA;AACA;AACA,CAAC;;AAED;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;;AAEA;AACA;AACA,4CAA4C;;AAE5C;;;;;;;ACpBA,e","file":"noty.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine(\"Noty\", [], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"Noty\"] = factory();\n\telse\n\t\troot[\"Noty\"] = factory();\n})(this, function() {\nreturn \n\n\n// WEBPACK FOOTER //\n// webpack/universalModuleDefinition"," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// identity function for calling harmony imports with the correct context\n \t__webpack_require__.i = function(value) { return value; };\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 6);\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap 13c137d60d3e439c3a2f","import * as API from 'api'\r\n\r\nexport const animationEndEvents = 'webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend'\r\n\r\nexport function inArray (needle, haystack, argStrict) {\r\n let key\r\n let strict = !!argStrict\r\n\r\n if (strict) {\r\n for (key in haystack) {\r\n if (haystack.hasOwnProperty(key) && haystack[key] === needle) {\r\n return true\r\n }\r\n }\r\n } else {\r\n for (key in haystack) {\r\n if (haystack.hasOwnProperty(key) && haystack[key] === needle) {\r\n return true\r\n }\r\n }\r\n }\r\n return false\r\n}\r\n\r\nexport function stopPropagation (evt) {\r\n evt = evt || window.event\r\n\r\n if (typeof evt.stopPropagation !== 'undefined') {\r\n evt.stopPropagation()\r\n } else {\r\n evt.cancelBubble = true\r\n }\r\n}\r\n\r\nexport const deepExtend = function (out) {\r\n out = out || {}\r\n\r\n for (let i = 1; i < arguments.length; i++) {\r\n let obj = arguments[i]\r\n\r\n if (!obj) continue\r\n\r\n for (let key in obj) {\r\n if (obj.hasOwnProperty(key)) {\r\n if (Array.isArray(obj[key])) {\r\n out[key] = obj[key]\r\n } else if (typeof obj[key] === 'object' && obj[key] !== null) {\r\n out[key] = deepExtend(out[key], obj[key])\r\n } else {\r\n out[key] = obj[key]\r\n }\r\n }\r\n }\r\n }\r\n\r\n return out\r\n}\r\n\r\nexport function generateID (prefix = '') {\r\n let id = `noty_${prefix}_`\r\n\r\n id += 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {\r\n let r = Math.random() * 16 | 0\r\n let v = c === 'x' ? r : r & 0x3 | 0x8\r\n return v.toString(16)\r\n })\r\n\r\n return id\r\n}\r\n\r\nexport function outerHeight (el) {\r\n let height = el.offsetHeight\r\n let style = window.getComputedStyle(el)\r\n\r\n height += parseInt(style.marginTop) + parseInt(style.marginBottom)\r\n return height\r\n}\r\n\r\nexport let css = (function () {\r\n let cssPrefixes = ['Webkit', 'O', 'Moz', 'ms']\r\n let cssProps = {}\r\n\r\n function camelCase (string) {\r\n return string\r\n .replace(/^-ms-/, 'ms-')\r\n .replace(/-([\\da-z])/gi, function (match, letter) {\r\n return letter.toUpperCase()\r\n })\r\n }\r\n\r\n function getVendorProp (name) {\r\n let style = document.body.style\r\n if (name in style) return name\r\n\r\n let i = cssPrefixes.length\r\n let capName = name.charAt(0).toUpperCase() + name.slice(1)\r\n let vendorName\r\n\r\n while (i--) {\r\n vendorName = cssPrefixes[i] + capName\r\n if (vendorName in style) return vendorName\r\n }\r\n\r\n return name\r\n }\r\n\r\n function getStyleProp (name) {\r\n name = camelCase(name)\r\n return cssProps[name] || (cssProps[name] = getVendorProp(name))\r\n }\r\n\r\n function applyCss (element, prop, value) {\r\n prop = getStyleProp(prop)\r\n element.style[prop] = value\r\n }\r\n\r\n return function (element, properties) {\r\n let args = arguments\r\n let prop\r\n let value\r\n\r\n if (args.length === 2) {\r\n for (prop in properties) {\r\n if (properties.hasOwnProperty(prop)) {\r\n value = properties[prop]\r\n if (value !== undefined && properties.hasOwnProperty(prop)) {\r\n applyCss(element, prop, value)\r\n }\r\n }\r\n }\r\n } else {\r\n applyCss(element, args[1], args[2])\r\n }\r\n }\r\n})()\r\n\r\nexport function addListener (el, events, cb, useCapture = false) {\r\n events = events.split(' ')\r\n for (let i = 0; i < events.length; i++) {\r\n if (document.addEventListener) {\r\n el.addEventListener(events[i], cb, useCapture)\r\n } else if (document.attachEvent) {\r\n el.attachEvent('on' + events[i], cb)\r\n }\r\n }\r\n}\r\n\r\nexport function hasClass (element, name) {\r\n let list = typeof element === 'string' ? element : classList(element)\r\n return list.indexOf(' ' + name + ' ') >= 0\r\n}\r\n\r\nexport function addClass (element, name) {\r\n let oldList = classList(element)\r\n let newList = oldList + name\r\n\r\n if (hasClass(oldList, name)) return\r\n\r\n // Trim the opening space.\r\n element.className = newList.substring(1)\r\n}\r\n\r\nexport function removeClass (element, name) {\r\n let oldList = classList(element)\r\n let newList\r\n\r\n if (!hasClass(element, name)) return\r\n\r\n // Replace the class name.\r\n newList = oldList.replace(' ' + name + ' ', ' ')\r\n\r\n // Trim the opening and closing spaces.\r\n element.className = newList.substring(1, newList.length - 1)\r\n}\r\n\r\nexport function remove (element) {\r\n if (element.parentNode) {\r\n element.parentNode.removeChild(element)\r\n }\r\n}\r\n\r\nexport function classList (element) {\r\n return (' ' + ((element && element.className) || '') + ' ').replace(\r\n /\\s+/gi,\r\n ' '\r\n )\r\n}\r\n\r\nexport function visibilityChangeFlow () {\r\n let hidden\r\n let visibilityChange\r\n if (typeof document.hidden !== 'undefined') {\r\n // Opera 12.10 and Firefox 18 and later support\r\n hidden = 'hidden'\r\n visibilityChange = 'visibilitychange'\r\n } else if (typeof document.msHidden !== 'undefined') {\r\n hidden = 'msHidden'\r\n visibilityChange = 'msvisibilitychange'\r\n } else if (typeof document.webkitHidden !== 'undefined') {\r\n hidden = 'webkitHidden'\r\n visibilityChange = 'webkitvisibilitychange'\r\n }\r\n\r\n function onVisibilityChange () {\r\n API.PageHidden = document[hidden]\r\n handleVisibilityChange()\r\n }\r\n\r\n function onBlur () {\r\n API.PageHidden = true\r\n handleVisibilityChange()\r\n }\r\n\r\n function onFocus () {\r\n API.PageHidden = false\r\n handleVisibilityChange()\r\n }\r\n\r\n function handleVisibilityChange () {\r\n if (API.PageHidden) stopAll()\r\n else resumeAll()\r\n }\r\n\r\n function stopAll () {\r\n setTimeout(\r\n function () {\r\n Object.keys(API.Store).forEach(id => {\r\n if (API.Store.hasOwnProperty(id)) {\r\n if (API.Store[id].options.visibilityControl) {\r\n API.Store[id].stop()\r\n }\r\n }\r\n })\r\n },\r\n 100\r\n )\r\n }\r\n\r\n function resumeAll () {\r\n setTimeout(\r\n function () {\r\n Object.keys(API.Store).forEach(id => {\r\n if (API.Store.hasOwnProperty(id)) {\r\n if (API.Store[id].options.visibilityControl) {\r\n API.Store[id].resume()\r\n }\r\n }\r\n })\r\n API.queueRenderAll()\r\n },\r\n 100\r\n )\r\n }\r\n\r\n if (visibilityChange) {\r\n addListener(document, visibilityChange, onVisibilityChange)\r\n }\r\n\r\n addListener(window, 'blur', onBlur)\r\n addListener(window, 'focus', onFocus)\r\n}\r\n\r\nexport function createAudioElements (ref) {\r\n if (ref.hasSound) {\r\n const audioElement = document.createElement('audio')\r\n\r\n ref.options.sounds.sources.forEach(s => {\r\n const source = document.createElement('source')\r\n source.src = s\r\n source.type = `audio/${getExtension(s)}`\r\n audioElement.appendChild(source)\r\n })\r\n\r\n if (ref.barDom) {\r\n ref.barDom.appendChild(audioElement)\r\n } else {\r\n document.querySelector('body').appendChild(audioElement)\r\n }\r\n\r\n audioElement.volume = ref.options.sounds.volume\r\n\r\n if (!ref.soundPlayed) {\r\n audioElement.play()\r\n ref.soundPlayed = true\r\n }\r\n\r\n audioElement.onended = function () {\r\n remove(audioElement)\r\n }\r\n }\r\n}\r\n\r\nfunction getExtension (fileName) {\r\n return fileName.match(/\\.([^.]+)$/)[1]\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./src/utils.js","import * as Utils from 'utils'\r\n\r\nexport let PageHidden = false\r\nexport let DocModalCount = 0\r\n\r\nconst DocTitleProps = {\r\n originalTitle: null,\r\n count: 0,\r\n changed: false,\r\n timer: -1\r\n}\r\n\r\nexport const docTitle = {\r\n increment: () => {\r\n DocTitleProps.count++\r\n\r\n docTitle._update()\r\n },\r\n\r\n decrement: () => {\r\n DocTitleProps.count--\r\n\r\n if (DocTitleProps.count <= 0) {\r\n docTitle._clear()\r\n return\r\n }\r\n\r\n docTitle._update()\r\n },\r\n\r\n _update: () => {\r\n let title = document.title\r\n\r\n if (!DocTitleProps.changed) {\r\n DocTitleProps.originalTitle = title\r\n document.title = `(${DocTitleProps.count}) ${title}`\r\n DocTitleProps.changed = true\r\n } else {\r\n document.title = `(${DocTitleProps.count}) ${DocTitleProps.originalTitle}`\r\n }\r\n },\r\n\r\n _clear: () => {\r\n if (DocTitleProps.changed) {\r\n DocTitleProps.count = 0\r\n document.title = DocTitleProps.originalTitle\r\n DocTitleProps.changed = false\r\n }\r\n }\r\n}\r\n\r\nexport const DefaultMaxVisible = 5\r\n\r\nexport const Queues = {\r\n global: {\r\n maxVisible: DefaultMaxVisible,\r\n queue: []\r\n }\r\n}\r\n\r\nexport const Store = {}\r\n\r\nexport let Defaults = {\r\n type: 'alert',\r\n layout: 'topRight',\r\n theme: 'mint',\r\n text: '',\r\n timeout: false,\r\n progressBar: true,\r\n closeWith: ['click'],\r\n animation: {\r\n open: 'noty_effects_open',\r\n close: 'noty_effects_close'\r\n },\r\n id: false,\r\n force: false,\r\n killer: false,\r\n queue: 'global',\r\n container: false,\r\n buttons: [],\r\n callbacks: {\r\n beforeShow: null,\r\n onShow: null,\r\n afterShow: null,\r\n onClose: null,\r\n afterClose: null,\r\n onClick: null,\r\n onHover: null,\r\n onTemplate: null\r\n },\r\n sounds: {\r\n sources: [],\r\n volume: 1,\r\n conditions: []\r\n },\r\n titleCount: {\r\n conditions: []\r\n },\r\n modal: false,\r\n visibilityControl: false\r\n}\r\n\r\n/**\r\n * @param {string} queueName\r\n * @return {object}\r\n */\r\nexport function getQueueCounts (queueName = 'global') {\r\n let count = 0\r\n let max = DefaultMaxVisible\r\n\r\n if (Queues.hasOwnProperty(queueName)) {\r\n max = Queues[queueName].maxVisible\r\n Object.keys(Store).forEach(i => {\r\n if (Store[i].options.queue === queueName && !Store[i].closed) count++\r\n })\r\n }\r\n\r\n return {\r\n current: count,\r\n maxVisible: max\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function addToQueue (ref) {\r\n if (!Queues.hasOwnProperty(ref.options.queue)) {\r\n Queues[ref.options.queue] = {maxVisible: DefaultMaxVisible, queue: []}\r\n }\r\n\r\n Queues[ref.options.queue].queue.push(ref)\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function removeFromQueue (ref) {\r\n if (Queues.hasOwnProperty(ref.options.queue)) {\r\n const queue = []\r\n Object.keys(Queues[ref.options.queue].queue).forEach(i => {\r\n if (Queues[ref.options.queue].queue[i].id !== ref.id) {\r\n queue.push(Queues[ref.options.queue].queue[i])\r\n }\r\n })\r\n Queues[ref.options.queue].queue = queue\r\n }\r\n}\r\n\r\n/**\r\n * @param {string} queueName\r\n * @return {void}\r\n */\r\nexport function queueRender (queueName = 'global') {\r\n if (Queues.hasOwnProperty(queueName)) {\r\n const noty = Queues[queueName].queue.shift()\r\n\r\n if (noty) noty.show()\r\n }\r\n}\r\n\r\n/**\r\n * @return {void}\r\n */\r\nexport function queueRenderAll () {\r\n Object.keys(Queues).forEach(queueName => {\r\n queueRender(queueName)\r\n })\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function ghostFix (ref) {\r\n const ghostID = Utils.generateID('ghost')\r\n let ghost = document.createElement('div')\r\n ghost.setAttribute('id', ghostID)\r\n Utils.css(ghost, {\r\n height: Utils.outerHeight(ref.barDom) + 'px'\r\n })\r\n\r\n ref.barDom.insertAdjacentHTML('afterend', ghost.outerHTML)\r\n\r\n Utils.remove(ref.barDom)\r\n ghost = document.getElementById(ghostID)\r\n Utils.addClass(ghost, 'noty_fix_effects_height')\r\n Utils.addListener(ghost, Utils.animationEndEvents, () => {\r\n Utils.remove(ghost)\r\n })\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function build (ref) {\r\n findOrCreateContainer(ref)\r\n\r\n const markup = `
${ref.options.text}
${buildButtons(ref)}`\r\n\r\n ref.barDom = document.createElement('div')\r\n ref.barDom.setAttribute('id', ref.id)\r\n Utils.addClass(\r\n ref.barDom,\r\n `noty_bar noty_type__${ref.options.type} noty_theme__${ref.options.theme}`\r\n )\r\n\r\n ref.barDom.innerHTML = markup\r\n\r\n fire(ref, 'onTemplate')\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {boolean}\r\n */\r\nexport function hasButtons (ref) {\r\n return !!(ref.options.buttons && Object.keys(ref.options.buttons).length)\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {string}\r\n */\r\nfunction buildButtons (ref) {\r\n if (hasButtons(ref)) {\r\n let buttons = document.createElement('div')\r\n Utils.addClass(buttons, 'noty_buttons')\r\n\r\n Object.keys(ref.options.buttons).forEach(key => {\r\n buttons.appendChild(ref.options.buttons[key].dom)\r\n })\r\n\r\n ref.options.buttons.forEach(btn => {\r\n buttons.appendChild(btn.dom)\r\n })\r\n return buttons.outerHTML\r\n }\r\n return ''\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function handleModal (ref) {\r\n if (ref.options.modal) {\r\n if (DocModalCount === 0) {\r\n createModal(ref)\r\n }\r\n\r\n DocModalCount++\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function handleModalClose (ref) {\r\n if (ref.options.modal && DocModalCount > 0) {\r\n DocModalCount--\r\n\r\n if (DocModalCount <= 0) {\r\n const modal = document.querySelector('.noty_modal')\r\n\r\n if (modal) {\r\n Utils.removeClass(modal, 'noty_modal_open')\r\n Utils.addClass(modal, 'noty_modal_close')\r\n Utils.addListener(modal, Utils.animationEndEvents, () => {\r\n Utils.remove(modal)\r\n })\r\n }\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * @return {void}\r\n */\r\nfunction createModal () {\r\n const body = document.querySelector('body')\r\n const modal = document.createElement('div')\r\n Utils.addClass(modal, 'noty_modal')\r\n body.insertBefore(modal, body.firstChild)\r\n Utils.addClass(modal, 'noty_modal_open')\r\n\r\n Utils.addListener(modal, Utils.animationEndEvents, () => {\r\n Utils.removeClass(modal, 'noty_modal_open')\r\n })\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nfunction findOrCreateContainer (ref) {\r\n if (ref.options.container) {\r\n ref.layoutDom = document.querySelector(ref.options.container)\r\n return\r\n }\r\n\r\n const layoutID = `noty_layout__${ref.options.layout}`\r\n ref.layoutDom = document.querySelector(`div#${layoutID}`)\r\n\r\n if (!ref.layoutDom) {\r\n ref.layoutDom = document.createElement('div')\r\n ref.layoutDom.setAttribute('id', layoutID)\r\n ref.layoutDom.setAttribute('role', 'alert')\r\n ref.layoutDom.setAttribute('aria-live', 'polite')\r\n Utils.addClass(ref.layoutDom, 'noty_layout')\r\n document.querySelector('body').appendChild(ref.layoutDom)\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function queueClose (ref) {\r\n if (ref.options.timeout) {\r\n if (ref.options.progressBar && ref.progressDom) {\r\n Utils.css(ref.progressDom, {\r\n transition: `width ${ref.options.timeout}ms linear`,\r\n width: '0%'\r\n })\r\n }\r\n\r\n clearTimeout(ref.closeTimer)\r\n\r\n ref.closeTimer = setTimeout(\r\n () => {\r\n ref.close()\r\n },\r\n ref.options.timeout\r\n )\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function dequeueClose (ref) {\r\n if (ref.options.timeout && ref.closeTimer) {\r\n clearTimeout(ref.closeTimer)\r\n ref.closeTimer = -1\r\n\r\n if (ref.options.progressBar && ref.progressDom) {\r\n Utils.css(ref.progressDom, {\r\n transition: 'width 0ms linear',\r\n width: '100%'\r\n })\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @param {string} eventName\r\n * @return {void}\r\n */\r\nexport function fire (ref, eventName) {\r\n if (ref.listeners.hasOwnProperty(eventName)) {\r\n ref.listeners[eventName].forEach(cb => {\r\n if (typeof cb === 'function') {\r\n cb.apply(ref)\r\n }\r\n })\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function openFlow (ref) {\r\n fire(ref, 'afterShow')\r\n queueClose(ref)\r\n\r\n Utils.addListener(ref.barDom, 'mouseenter', () => {\r\n dequeueClose(ref)\r\n })\r\n\r\n Utils.addListener(ref.barDom, 'mouseleave', () => {\r\n queueClose(ref)\r\n })\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function closeFlow (ref) {\r\n delete Store[ref.id]\r\n ref.closing = false\r\n fire(ref, 'afterClose')\r\n\r\n Utils.remove(ref.barDom)\r\n\r\n if (\r\n ref.layoutDom.querySelectorAll('.noty_bar').length === 0 &&\r\n !ref.options.container\r\n ) {\r\n Utils.remove(ref.layoutDom)\r\n }\r\n\r\n if (\r\n Utils.inArray('docVisible', ref.options.titleCount.conditions) ||\r\n Utils.inArray('docHidden', ref.options.titleCount.conditions)\r\n ) {\r\n docTitle.decrement()\r\n }\r\n\r\n queueRender(ref.options.queue)\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./src/api.js","import * as Utils from 'utils'\r\n\r\nexport class NotyButton {\r\n constructor (html, classes, cb, attributes = {}) {\r\n this.dom = document.createElement('button')\r\n this.dom.innerHTML = html\r\n this.id = (attributes.id = attributes.id || Utils.generateID('button'))\r\n this.cb = cb\r\n Object.keys(attributes).forEach(propertyName => {\r\n this.dom.setAttribute(propertyName, attributes[propertyName])\r\n })\r\n Utils.addClass(this.dom, classes || 'noty_btn')\r\n\r\n return this\r\n }\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./src/button.js","export class Push {\r\n constructor (workerPath = '/service-worker.js') {\r\n this.subData = {}\r\n this.workerPath = workerPath\r\n this.listeners = {\r\n onPermissionGranted: [],\r\n onPermissionDenied: [],\r\n onSubscriptionSuccess: [],\r\n onSubscriptionCancel: [],\r\n onWorkerError: [],\r\n onWorkerSuccess: [],\r\n onWorkerNotSupported: []\r\n }\r\n return this\r\n }\r\n\r\n /**\r\n * @param {string} eventName\r\n * @param {function} cb\r\n * @return {Push}\r\n */\r\n on (eventName, cb = () => {}) {\r\n if (typeof cb === 'function' && this.listeners.hasOwnProperty(eventName)) {\r\n this.listeners[eventName].push(cb)\r\n }\r\n\r\n return this\r\n }\r\n\r\n fire (eventName, params = []) {\r\n if (this.listeners.hasOwnProperty(eventName)) {\r\n this.listeners[eventName].forEach(cb => {\r\n if (typeof cb === 'function') {\r\n cb.apply(this, params)\r\n }\r\n })\r\n }\r\n }\r\n\r\n create () {\r\n console.log('NOT IMPLEMENTED YET')\r\n }\r\n\r\n /**\r\n * @return {boolean}\r\n */\r\n isSupported () {\r\n let result = false\r\n\r\n try {\r\n result = window.Notification ||\r\n window.webkitNotifications ||\r\n navigator.mozNotification ||\r\n (window.external && window.external.msIsSiteMode() !== undefined)\r\n } catch (e) {}\r\n\r\n return result\r\n }\r\n\r\n /**\r\n * @return {string}\r\n */\r\n getPermissionStatus () {\r\n let perm = 'default'\r\n\r\n if (window.Notification && window.Notification.permissionLevel) {\r\n perm = window.Notification.permissionLevel\r\n } else if (\r\n window.webkitNotifications && window.webkitNotifications.checkPermission\r\n ) {\r\n switch (window.webkitNotifications.checkPermission()) {\r\n case 1:\r\n perm = 'default'\r\n break\r\n case 0:\r\n perm = 'granted'\r\n break\r\n default:\r\n perm = 'denied'\r\n }\r\n } else if (window.Notification && window.Notification.permission) {\r\n perm = window.Notification.permission\r\n } else if (navigator.mozNotification) {\r\n perm = 'granted'\r\n } else if (\r\n window.external && window.external.msIsSiteMode() !== undefined\r\n ) {\r\n perm = window.external.msIsSiteMode() ? 'granted' : 'default'\r\n }\r\n\r\n return perm.toString().toLowerCase()\r\n }\r\n\r\n /**\r\n * @return {string}\r\n */\r\n getEndpoint (subscription) {\r\n let endpoint = subscription.endpoint\r\n const subscriptionId = subscription.subscriptionId\r\n\r\n // fix for Chrome < 45\r\n if (subscriptionId && endpoint.indexOf(subscriptionId) === -1) {\r\n endpoint += '/' + subscriptionId\r\n }\r\n\r\n return endpoint\r\n }\r\n\r\n /**\r\n * @return {boolean}\r\n */\r\n isSWRegistered () {\r\n try {\r\n return navigator.serviceWorker.controller.state === 'activated'\r\n } catch (e) {\r\n return false\r\n }\r\n }\r\n\r\n /**\r\n * @return {void}\r\n */\r\n unregisterWorker () {\r\n const self = this\r\n if ('serviceWorker' in navigator) {\r\n navigator.serviceWorker.getRegistrations().then(function (registrations) {\r\n for (let registration of registrations) {\r\n registration.unregister()\r\n self.fire('onSubscriptionCancel')\r\n }\r\n })\r\n }\r\n }\r\n\r\n /**\r\n * @return {void}\r\n */\r\n requestSubscription (userVisibleOnly = true) {\r\n const self = this\r\n const current = this.getPermissionStatus()\r\n const cb = result => {\r\n if (result === 'granted') {\r\n this.fire('onPermissionGranted')\r\n\r\n if ('serviceWorker' in navigator) {\r\n navigator.serviceWorker.register(this.workerPath).then(function () {\r\n navigator.serviceWorker.ready.then(\r\n function (serviceWorkerRegistration) {\r\n self.fire('onWorkerSuccess')\r\n serviceWorkerRegistration.pushManager\r\n .subscribe({\r\n userVisibleOnly: userVisibleOnly\r\n })\r\n .then(function (subscription) {\r\n const key = subscription.getKey('p256dh')\r\n const token = subscription.getKey('auth')\r\n\r\n self.subData = {\r\n endpoint: self.getEndpoint(subscription),\r\n p256dh: key\r\n ? window.btoa(\r\n String.fromCharCode.apply(null, new Uint8Array(key))\r\n )\r\n : null,\r\n auth: token\r\n ? window.btoa(\r\n String.fromCharCode.apply(\r\n null,\r\n new Uint8Array(token)\r\n )\r\n )\r\n : null\r\n }\r\n\r\n self.fire('onSubscriptionSuccess', [self.subData])\r\n })\r\n .catch(function (err) {\r\n self.fire('onWorkerError', [err])\r\n })\r\n }\r\n )\r\n })\r\n } else {\r\n self.fire('onWorkerNotSupported')\r\n }\r\n } else if (result === 'denied') {\r\n this.fire('onPermissionDenied')\r\n this.unregisterWorker()\r\n }\r\n }\r\n\r\n if (current === 'default') {\r\n if (window.Notification && window.Notification.requestPermission) {\r\n window.Notification.requestPermission(cb)\r\n } else if (\r\n window.webkitNotifications && window.webkitNotifications.checkPermission\r\n ) {\r\n window.webkitNotifications.requestPermission(cb)\r\n }\r\n } else {\r\n cb(current)\r\n }\r\n }\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./src/push.js","/*!\n * @overview es6-promise - a tiny implementation of Promises/A+.\n * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)\n * @license Licensed under MIT license\n * See https://raw.githubusercontent.com/stefanpenner/es6-promise/master/LICENSE\n * @version 4.1.1\n */\n\n(function (global, factory) {\n\ttypeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :\n\ttypeof define === 'function' && define.amd ? define(factory) :\n\t(global.ES6Promise = factory());\n}(this, (function () { 'use strict';\n\nfunction objectOrFunction(x) {\n var type = typeof x;\n return x !== null && (type === 'object' || type === 'function');\n}\n\nfunction isFunction(x) {\n return typeof x === 'function';\n}\n\nvar _isArray = undefined;\nif (Array.isArray) {\n _isArray = Array.isArray;\n} else {\n _isArray = function (x) {\n return Object.prototype.toString.call(x) === '[object Array]';\n };\n}\n\nvar isArray = _isArray;\n\nvar len = 0;\nvar vertxNext = undefined;\nvar customSchedulerFn = undefined;\n\nvar asap = function asap(callback, arg) {\n queue[len] = callback;\n queue[len + 1] = arg;\n len += 2;\n if (len === 2) {\n // If len is 2, that means that we need to schedule an async flush.\n // If additional callbacks are queued before the queue is flushed, they\n // will be processed by this flush that we are scheduling.\n if (customSchedulerFn) {\n customSchedulerFn(flush);\n } else {\n scheduleFlush();\n }\n }\n};\n\nfunction setScheduler(scheduleFn) {\n customSchedulerFn = scheduleFn;\n}\n\nfunction setAsap(asapFn) {\n asap = asapFn;\n}\n\nvar browserWindow = typeof window !== 'undefined' ? window : undefined;\nvar browserGlobal = browserWindow || {};\nvar BrowserMutationObserver = browserGlobal.MutationObserver || browserGlobal.WebKitMutationObserver;\nvar isNode = typeof self === 'undefined' && typeof process !== 'undefined' && ({}).toString.call(process) === '[object process]';\n\n// test for web worker but not in IE10\nvar isWorker = typeof Uint8ClampedArray !== 'undefined' && typeof importScripts !== 'undefined' && typeof MessageChannel !== 'undefined';\n\n// node\nfunction useNextTick() {\n // node version 0.10.x displays a deprecation warning when nextTick is used recursively\n // see https://github.com/cujojs/when/issues/410 for details\n return function () {\n return process.nextTick(flush);\n };\n}\n\n// vertx\nfunction useVertxTimer() {\n if (typeof vertxNext !== 'undefined') {\n return function () {\n vertxNext(flush);\n };\n }\n\n return useSetTimeout();\n}\n\nfunction useMutationObserver() {\n var iterations = 0;\n var observer = new BrowserMutationObserver(flush);\n var node = document.createTextNode('');\n observer.observe(node, { characterData: true });\n\n return function () {\n node.data = iterations = ++iterations % 2;\n };\n}\n\n// web worker\nfunction useMessageChannel() {\n var channel = new MessageChannel();\n channel.port1.onmessage = flush;\n return function () {\n return channel.port2.postMessage(0);\n };\n}\n\nfunction useSetTimeout() {\n // Store setTimeout reference so es6-promise will be unaffected by\n // other code modifying setTimeout (like sinon.useFakeTimers())\n var globalSetTimeout = setTimeout;\n return function () {\n return globalSetTimeout(flush, 1);\n };\n}\n\nvar queue = new Array(1000);\nfunction flush() {\n for (var i = 0; i < len; i += 2) {\n var callback = queue[i];\n var arg = queue[i + 1];\n\n callback(arg);\n\n queue[i] = undefined;\n queue[i + 1] = undefined;\n }\n\n len = 0;\n}\n\nfunction attemptVertx() {\n try {\n var r = require;\n var vertx = r('vertx');\n vertxNext = vertx.runOnLoop || vertx.runOnContext;\n return useVertxTimer();\n } catch (e) {\n return useSetTimeout();\n }\n}\n\nvar scheduleFlush = undefined;\n// Decide what async method to use to triggering processing of queued callbacks:\nif (isNode) {\n scheduleFlush = useNextTick();\n} else if (BrowserMutationObserver) {\n scheduleFlush = useMutationObserver();\n} else if (isWorker) {\n scheduleFlush = useMessageChannel();\n} else if (browserWindow === undefined && typeof require === 'function') {\n scheduleFlush = attemptVertx();\n} else {\n scheduleFlush = useSetTimeout();\n}\n\nfunction then(onFulfillment, onRejection) {\n var _arguments = arguments;\n\n var parent = this;\n\n var child = new this.constructor(noop);\n\n if (child[PROMISE_ID] === undefined) {\n makePromise(child);\n }\n\n var _state = parent._state;\n\n if (_state) {\n (function () {\n var callback = _arguments[_state - 1];\n asap(function () {\n return invokeCallback(_state, child, callback, parent._result);\n });\n })();\n } else {\n subscribe(parent, child, onFulfillment, onRejection);\n }\n\n return child;\n}\n\n/**\n `Promise.resolve` returns a promise that will become resolved with the\n passed `value`. It is shorthand for the following:\n\n ```javascript\n let promise = new Promise(function(resolve, reject){\n resolve(1);\n });\n\n promise.then(function(value){\n // value === 1\n });\n ```\n\n Instead of writing the above, your code now simply becomes the following:\n\n ```javascript\n let promise = Promise.resolve(1);\n\n promise.then(function(value){\n // value === 1\n });\n ```\n\n @method resolve\n @static\n @param {Any} value value that the returned promise will be resolved with\n Useful for tooling.\n @return {Promise} a promise that will become fulfilled with the given\n `value`\n*/\nfunction resolve$1(object) {\n /*jshint validthis:true */\n var Constructor = this;\n\n if (object && typeof object === 'object' && object.constructor === Constructor) {\n return object;\n }\n\n var promise = new Constructor(noop);\n resolve(promise, object);\n return promise;\n}\n\nvar PROMISE_ID = Math.random().toString(36).substring(16);\n\nfunction noop() {}\n\nvar PENDING = void 0;\nvar FULFILLED = 1;\nvar REJECTED = 2;\n\nvar GET_THEN_ERROR = new ErrorObject();\n\nfunction selfFulfillment() {\n return new TypeError(\"You cannot resolve a promise with itself\");\n}\n\nfunction cannotReturnOwn() {\n return new TypeError('A promises callback cannot return that same promise.');\n}\n\nfunction getThen(promise) {\n try {\n return promise.then;\n } catch (error) {\n GET_THEN_ERROR.error = error;\n return GET_THEN_ERROR;\n }\n}\n\nfunction tryThen(then$$1, value, fulfillmentHandler, rejectionHandler) {\n try {\n then$$1.call(value, fulfillmentHandler, rejectionHandler);\n } catch (e) {\n return e;\n }\n}\n\nfunction handleForeignThenable(promise, thenable, then$$1) {\n asap(function (promise) {\n var sealed = false;\n var error = tryThen(then$$1, thenable, function (value) {\n if (sealed) {\n return;\n }\n sealed = true;\n if (thenable !== value) {\n resolve(promise, value);\n } else {\n fulfill(promise, value);\n }\n }, function (reason) {\n if (sealed) {\n return;\n }\n sealed = true;\n\n reject(promise, reason);\n }, 'Settle: ' + (promise._label || ' unknown promise'));\n\n if (!sealed && error) {\n sealed = true;\n reject(promise, error);\n }\n }, promise);\n}\n\nfunction handleOwnThenable(promise, thenable) {\n if (thenable._state === FULFILLED) {\n fulfill(promise, thenable._result);\n } else if (thenable._state === REJECTED) {\n reject(promise, thenable._result);\n } else {\n subscribe(thenable, undefined, function (value) {\n return resolve(promise, value);\n }, function (reason) {\n return reject(promise, reason);\n });\n }\n}\n\nfunction handleMaybeThenable(promise, maybeThenable, then$$1) {\n if (maybeThenable.constructor === promise.constructor && then$$1 === then && maybeThenable.constructor.resolve === resolve$1) {\n handleOwnThenable(promise, maybeThenable);\n } else {\n if (then$$1 === GET_THEN_ERROR) {\n reject(promise, GET_THEN_ERROR.error);\n GET_THEN_ERROR.error = null;\n } else if (then$$1 === undefined) {\n fulfill(promise, maybeThenable);\n } else if (isFunction(then$$1)) {\n handleForeignThenable(promise, maybeThenable, then$$1);\n } else {\n fulfill(promise, maybeThenable);\n }\n }\n}\n\nfunction resolve(promise, value) {\n if (promise === value) {\n reject(promise, selfFulfillment());\n } else if (objectOrFunction(value)) {\n handleMaybeThenable(promise, value, getThen(value));\n } else {\n fulfill(promise, value);\n }\n}\n\nfunction publishRejection(promise) {\n if (promise._onerror) {\n promise._onerror(promise._result);\n }\n\n publish(promise);\n}\n\nfunction fulfill(promise, value) {\n if (promise._state !== PENDING) {\n return;\n }\n\n promise._result = value;\n promise._state = FULFILLED;\n\n if (promise._subscribers.length !== 0) {\n asap(publish, promise);\n }\n}\n\nfunction reject(promise, reason) {\n if (promise._state !== PENDING) {\n return;\n }\n promise._state = REJECTED;\n promise._result = reason;\n\n asap(publishRejection, promise);\n}\n\nfunction subscribe(parent, child, onFulfillment, onRejection) {\n var _subscribers = parent._subscribers;\n var length = _subscribers.length;\n\n parent._onerror = null;\n\n _subscribers[length] = child;\n _subscribers[length + FULFILLED] = onFulfillment;\n _subscribers[length + REJECTED] = onRejection;\n\n if (length === 0 && parent._state) {\n asap(publish, parent);\n }\n}\n\nfunction publish(promise) {\n var subscribers = promise._subscribers;\n var settled = promise._state;\n\n if (subscribers.length === 0) {\n return;\n }\n\n var child = undefined,\n callback = undefined,\n detail = promise._result;\n\n for (var i = 0; i < subscribers.length; i += 3) {\n child = subscribers[i];\n callback = subscribers[i + settled];\n\n if (child) {\n invokeCallback(settled, child, callback, detail);\n } else {\n callback(detail);\n }\n }\n\n promise._subscribers.length = 0;\n}\n\nfunction ErrorObject() {\n this.error = null;\n}\n\nvar TRY_CATCH_ERROR = new ErrorObject();\n\nfunction tryCatch(callback, detail) {\n try {\n return callback(detail);\n } catch (e) {\n TRY_CATCH_ERROR.error = e;\n return TRY_CATCH_ERROR;\n }\n}\n\nfunction invokeCallback(settled, promise, callback, detail) {\n var hasCallback = isFunction(callback),\n value = undefined,\n error = undefined,\n succeeded = undefined,\n failed = undefined;\n\n if (hasCallback) {\n value = tryCatch(callback, detail);\n\n if (value === TRY_CATCH_ERROR) {\n failed = true;\n error = value.error;\n value.error = null;\n } else {\n succeeded = true;\n }\n\n if (promise === value) {\n reject(promise, cannotReturnOwn());\n return;\n }\n } else {\n value = detail;\n succeeded = true;\n }\n\n if (promise._state !== PENDING) {\n // noop\n } else if (hasCallback && succeeded) {\n resolve(promise, value);\n } else if (failed) {\n reject(promise, error);\n } else if (settled === FULFILLED) {\n fulfill(promise, value);\n } else if (settled === REJECTED) {\n reject(promise, value);\n }\n}\n\nfunction initializePromise(promise, resolver) {\n try {\n resolver(function resolvePromise(value) {\n resolve(promise, value);\n }, function rejectPromise(reason) {\n reject(promise, reason);\n });\n } catch (e) {\n reject(promise, e);\n }\n}\n\nvar id = 0;\nfunction nextId() {\n return id++;\n}\n\nfunction makePromise(promise) {\n promise[PROMISE_ID] = id++;\n promise._state = undefined;\n promise._result = undefined;\n promise._subscribers = [];\n}\n\nfunction Enumerator$1(Constructor, input) {\n this._instanceConstructor = Constructor;\n this.promise = new Constructor(noop);\n\n if (!this.promise[PROMISE_ID]) {\n makePromise(this.promise);\n }\n\n if (isArray(input)) {\n this.length = input.length;\n this._remaining = input.length;\n\n this._result = new Array(this.length);\n\n if (this.length === 0) {\n fulfill(this.promise, this._result);\n } else {\n this.length = this.length || 0;\n this._enumerate(input);\n if (this._remaining === 0) {\n fulfill(this.promise, this._result);\n }\n }\n } else {\n reject(this.promise, validationError());\n }\n}\n\nfunction validationError() {\n return new Error('Array Methods must be provided an Array');\n}\n\nEnumerator$1.prototype._enumerate = function (input) {\n for (var i = 0; this._state === PENDING && i < input.length; i++) {\n this._eachEntry(input[i], i);\n }\n};\n\nEnumerator$1.prototype._eachEntry = function (entry, i) {\n var c = this._instanceConstructor;\n var resolve$$1 = c.resolve;\n\n if (resolve$$1 === resolve$1) {\n var _then = getThen(entry);\n\n if (_then === then && entry._state !== PENDING) {\n this._settledAt(entry._state, i, entry._result);\n } else if (typeof _then !== 'function') {\n this._remaining--;\n this._result[i] = entry;\n } else if (c === Promise$2) {\n var promise = new c(noop);\n handleMaybeThenable(promise, entry, _then);\n this._willSettleAt(promise, i);\n } else {\n this._willSettleAt(new c(function (resolve$$1) {\n return resolve$$1(entry);\n }), i);\n }\n } else {\n this._willSettleAt(resolve$$1(entry), i);\n }\n};\n\nEnumerator$1.prototype._settledAt = function (state, i, value) {\n var promise = this.promise;\n\n if (promise._state === PENDING) {\n this._remaining--;\n\n if (state === REJECTED) {\n reject(promise, value);\n } else {\n this._result[i] = value;\n }\n }\n\n if (this._remaining === 0) {\n fulfill(promise, this._result);\n }\n};\n\nEnumerator$1.prototype._willSettleAt = function (promise, i) {\n var enumerator = this;\n\n subscribe(promise, undefined, function (value) {\n return enumerator._settledAt(FULFILLED, i, value);\n }, function (reason) {\n return enumerator._settledAt(REJECTED, i, reason);\n });\n};\n\n/**\n `Promise.all` accepts an array of promises, and returns a new promise which\n is fulfilled with an array of fulfillment values for the passed promises, or\n rejected with the reason of the first passed promise to be rejected. It casts all\n elements of the passed iterable to promises as it runs this algorithm.\n\n Example:\n\n ```javascript\n let promise1 = resolve(1);\n let promise2 = resolve(2);\n let promise3 = resolve(3);\n let promises = [ promise1, promise2, promise3 ];\n\n Promise.all(promises).then(function(array){\n // The array here would be [ 1, 2, 3 ];\n });\n ```\n\n If any of the `promises` given to `all` are rejected, the first promise\n that is rejected will be given as an argument to the returned promises's\n rejection handler. For example:\n\n Example:\n\n ```javascript\n let promise1 = resolve(1);\n let promise2 = reject(new Error(\"2\"));\n let promise3 = reject(new Error(\"3\"));\n let promises = [ promise1, promise2, promise3 ];\n\n Promise.all(promises).then(function(array){\n // Code here never runs because there are rejected promises!\n }, function(error) {\n // error.message === \"2\"\n });\n ```\n\n @method all\n @static\n @param {Array} entries array of promises\n @param {String} label optional string for labeling the promise.\n Useful for tooling.\n @return {Promise} promise that is fulfilled when all `promises` have been\n fulfilled, or rejected if any of them become rejected.\n @static\n*/\nfunction all$1(entries) {\n return new Enumerator$1(this, entries).promise;\n}\n\n/**\n `Promise.race` returns a new promise which is settled in the same way as the\n first passed promise to settle.\n\n Example:\n\n ```javascript\n let promise1 = new Promise(function(resolve, reject){\n setTimeout(function(){\n resolve('promise 1');\n }, 200);\n });\n\n let promise2 = new Promise(function(resolve, reject){\n setTimeout(function(){\n resolve('promise 2');\n }, 100);\n });\n\n Promise.race([promise1, promise2]).then(function(result){\n // result === 'promise 2' because it was resolved before promise1\n // was resolved.\n });\n ```\n\n `Promise.race` is deterministic in that only the state of the first\n settled promise matters. For example, even if other promises given to the\n `promises` array argument are resolved, but the first settled promise has\n become rejected before the other promises became fulfilled, the returned\n promise will become rejected:\n\n ```javascript\n let promise1 = new Promise(function(resolve, reject){\n setTimeout(function(){\n resolve('promise 1');\n }, 200);\n });\n\n let promise2 = new Promise(function(resolve, reject){\n setTimeout(function(){\n reject(new Error('promise 2'));\n }, 100);\n });\n\n Promise.race([promise1, promise2]).then(function(result){\n // Code here never runs\n }, function(reason){\n // reason.message === 'promise 2' because promise 2 became rejected before\n // promise 1 became fulfilled\n });\n ```\n\n An example real-world use case is implementing timeouts:\n\n ```javascript\n Promise.race([ajax('foo.json'), timeout(5000)])\n ```\n\n @method race\n @static\n @param {Array} promises array of promises to observe\n Useful for tooling.\n @return {Promise} a promise which settles in the same way as the first passed\n promise to settle.\n*/\nfunction race$1(entries) {\n /*jshint validthis:true */\n var Constructor = this;\n\n if (!isArray(entries)) {\n return new Constructor(function (_, reject) {\n return reject(new TypeError('You must pass an array to race.'));\n });\n } else {\n return new Constructor(function (resolve, reject) {\n var length = entries.length;\n for (var i = 0; i < length; i++) {\n Constructor.resolve(entries[i]).then(resolve, reject);\n }\n });\n }\n}\n\n/**\n `Promise.reject` returns a promise rejected with the passed `reason`.\n It is shorthand for the following:\n\n ```javascript\n let promise = new Promise(function(resolve, reject){\n reject(new Error('WHOOPS'));\n });\n\n promise.then(function(value){\n // Code here doesn't run because the promise is rejected!\n }, function(reason){\n // reason.message === 'WHOOPS'\n });\n ```\n\n Instead of writing the above, your code now simply becomes the following:\n\n ```javascript\n let promise = Promise.reject(new Error('WHOOPS'));\n\n promise.then(function(value){\n // Code here doesn't run because the promise is rejected!\n }, function(reason){\n // reason.message === 'WHOOPS'\n });\n ```\n\n @method reject\n @static\n @param {Any} reason value that the returned promise will be rejected with.\n Useful for tooling.\n @return {Promise} a promise rejected with the given `reason`.\n*/\nfunction reject$1(reason) {\n /*jshint validthis:true */\n var Constructor = this;\n var promise = new Constructor(noop);\n reject(promise, reason);\n return promise;\n}\n\nfunction needsResolver() {\n throw new TypeError('You must pass a resolver function as the first argument to the promise constructor');\n}\n\nfunction needsNew() {\n throw new TypeError(\"Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.\");\n}\n\n/**\n Promise objects represent the eventual result of an asynchronous operation. The\n primary way of interacting with a promise is through its `then` method, which\n registers callbacks to receive either a promise's eventual value or the reason\n why the promise cannot be fulfilled.\n\n Terminology\n -----------\n\n - `promise` is an object or function with a `then` method whose behavior conforms to this specification.\n - `thenable` is an object or function that defines a `then` method.\n - `value` is any legal JavaScript value (including undefined, a thenable, or a promise).\n - `exception` is a value that is thrown using the throw statement.\n - `reason` is a value that indicates why a promise was rejected.\n - `settled` the final resting state of a promise, fulfilled or rejected.\n\n A promise can be in one of three states: pending, fulfilled, or rejected.\n\n Promises that are fulfilled have a fulfillment value and are in the fulfilled\n state. Promises that are rejected have a rejection reason and are in the\n rejected state. A fulfillment value is never a thenable.\n\n Promises can also be said to *resolve* a value. If this value is also a\n promise, then the original promise's settled state will match the value's\n settled state. So a promise that *resolves* a promise that rejects will\n itself reject, and a promise that *resolves* a promise that fulfills will\n itself fulfill.\n\n\n Basic Usage:\n ------------\n\n ```js\n let promise = new Promise(function(resolve, reject) {\n // on success\n resolve(value);\n\n // on failure\n reject(reason);\n });\n\n promise.then(function(value) {\n // on fulfillment\n }, function(reason) {\n // on rejection\n });\n ```\n\n Advanced Usage:\n ---------------\n\n Promises shine when abstracting away asynchronous interactions such as\n `XMLHttpRequest`s.\n\n ```js\n function getJSON(url) {\n return new Promise(function(resolve, reject){\n let xhr = new XMLHttpRequest();\n\n xhr.open('GET', url);\n xhr.onreadystatechange = handler;\n xhr.responseType = 'json';\n xhr.setRequestHeader('Accept', 'application/json');\n xhr.send();\n\n function handler() {\n if (this.readyState === this.DONE) {\n if (this.status === 200) {\n resolve(this.response);\n } else {\n reject(new Error('getJSON: `' + url + '` failed with status: [' + this.status + ']'));\n }\n }\n };\n });\n }\n\n getJSON('/posts.json').then(function(json) {\n // on fulfillment\n }, function(reason) {\n // on rejection\n });\n ```\n\n Unlike callbacks, promises are great composable primitives.\n\n ```js\n Promise.all([\n getJSON('/posts'),\n getJSON('/comments')\n ]).then(function(values){\n values[0] // => postsJSON\n values[1] // => commentsJSON\n\n return values;\n });\n ```\n\n @class Promise\n @param {function} resolver\n Useful for tooling.\n @constructor\n*/\nfunction Promise$2(resolver) {\n this[PROMISE_ID] = nextId();\n this._result = this._state = undefined;\n this._subscribers = [];\n\n if (noop !== resolver) {\n typeof resolver !== 'function' && needsResolver();\n this instanceof Promise$2 ? initializePromise(this, resolver) : needsNew();\n }\n}\n\nPromise$2.all = all$1;\nPromise$2.race = race$1;\nPromise$2.resolve = resolve$1;\nPromise$2.reject = reject$1;\nPromise$2._setScheduler = setScheduler;\nPromise$2._setAsap = setAsap;\nPromise$2._asap = asap;\n\nPromise$2.prototype = {\n constructor: Promise$2,\n\n /**\n The primary way of interacting with a promise is through its `then` method,\n which registers callbacks to receive either a promise's eventual value or the\n reason why the promise cannot be fulfilled.\n \n ```js\n findUser().then(function(user){\n // user is available\n }, function(reason){\n // user is unavailable, and you are given the reason why\n });\n ```\n \n Chaining\n --------\n \n The return value of `then` is itself a promise. This second, 'downstream'\n promise is resolved with the return value of the first promise's fulfillment\n or rejection handler, or rejected if the handler throws an exception.\n \n ```js\n findUser().then(function (user) {\n return user.name;\n }, function (reason) {\n return 'default name';\n }).then(function (userName) {\n // If `findUser` fulfilled, `userName` will be the user's name, otherwise it\n // will be `'default name'`\n });\n \n findUser().then(function (user) {\n throw new Error('Found user, but still unhappy');\n }, function (reason) {\n throw new Error('`findUser` rejected and we're unhappy');\n }).then(function (value) {\n // never reached\n }, function (reason) {\n // if `findUser` fulfilled, `reason` will be 'Found user, but still unhappy'.\n // If `findUser` rejected, `reason` will be '`findUser` rejected and we're unhappy'.\n });\n ```\n If the downstream promise does not specify a rejection handler, rejection reasons will be propagated further downstream.\n \n ```js\n findUser().then(function (user) {\n throw new PedagogicalException('Upstream error');\n }).then(function (value) {\n // never reached\n }).then(function (value) {\n // never reached\n }, function (reason) {\n // The `PedgagocialException` is propagated all the way down to here\n });\n ```\n \n Assimilation\n ------------\n \n Sometimes the value you want to propagate to a downstream promise can only be\n retrieved asynchronously. This can be achieved by returning a promise in the\n fulfillment or rejection handler. The downstream promise will then be pending\n until the returned promise is settled. This is called *assimilation*.\n \n ```js\n findUser().then(function (user) {\n return findCommentsByAuthor(user);\n }).then(function (comments) {\n // The user's comments are now available\n });\n ```\n \n If the assimliated promise rejects, then the downstream promise will also reject.\n \n ```js\n findUser().then(function (user) {\n return findCommentsByAuthor(user);\n }).then(function (comments) {\n // If `findCommentsByAuthor` fulfills, we'll have the value here\n }, function (reason) {\n // If `findCommentsByAuthor` rejects, we'll have the reason here\n });\n ```\n \n Simple Example\n --------------\n \n Synchronous Example\n \n ```javascript\n let result;\n \n try {\n result = findResult();\n // success\n } catch(reason) {\n // failure\n }\n ```\n \n Errback Example\n \n ```js\n findResult(function(result, err){\n if (err) {\n // failure\n } else {\n // success\n }\n });\n ```\n \n Promise Example;\n \n ```javascript\n findResult().then(function(result){\n // success\n }, function(reason){\n // failure\n });\n ```\n \n Advanced Example\n --------------\n \n Synchronous Example\n \n ```javascript\n let author, books;\n \n try {\n author = findAuthor();\n books = findBooksByAuthor(author);\n // success\n } catch(reason) {\n // failure\n }\n ```\n \n Errback Example\n \n ```js\n \n function foundBooks(books) {\n \n }\n \n function failure(reason) {\n \n }\n \n findAuthor(function(author, err){\n if (err) {\n failure(err);\n // failure\n } else {\n try {\n findBoooksByAuthor(author, function(books, err) {\n if (err) {\n failure(err);\n } else {\n try {\n foundBooks(books);\n } catch(reason) {\n failure(reason);\n }\n }\n });\n } catch(error) {\n failure(err);\n }\n // success\n }\n });\n ```\n \n Promise Example;\n \n ```javascript\n findAuthor().\n then(findBooksByAuthor).\n then(function(books){\n // found books\n }).catch(function(reason){\n // something went wrong\n });\n ```\n \n @method then\n @param {Function} onFulfilled\n @param {Function} onRejected\n Useful for tooling.\n @return {Promise}\n */\n then: then,\n\n /**\n `catch` is simply sugar for `then(undefined, onRejection)` which makes it the same\n as the catch block of a try/catch statement.\n \n ```js\n function findAuthor(){\n throw new Error('couldn't find that author');\n }\n \n // synchronous\n try {\n findAuthor();\n } catch(reason) {\n // something went wrong\n }\n \n // async with promises\n findAuthor().catch(function(reason){\n // something went wrong\n });\n ```\n \n @method catch\n @param {Function} onRejection\n Useful for tooling.\n @return {Promise}\n */\n 'catch': function _catch(onRejection) {\n return this.then(null, onRejection);\n }\n};\n\n/*global self*/\nfunction polyfill$1() {\n var local = undefined;\n\n if (typeof global !== 'undefined') {\n local = global;\n } else if (typeof self !== 'undefined') {\n local = self;\n } else {\n try {\n local = Function('return this')();\n } catch (e) {\n throw new Error('polyfill failed because global object is unavailable in this environment');\n }\n }\n\n var P = local.Promise;\n\n if (P) {\n var promiseToString = null;\n try {\n promiseToString = Object.prototype.toString.call(P.resolve());\n } catch (e) {\n // silently ignored\n }\n\n if (promiseToString === '[object Promise]' && !P.cast) {\n return;\n }\n }\n\n local.Promise = Promise$2;\n}\n\n// Strange compat..\nPromise$2.polyfill = polyfill$1;\nPromise$2.Promise = Promise$2;\n\nreturn Promise$2;\n\n})));\n\n//# sourceMappingURL=es6-promise.map\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/es6-promise/dist/es6-promise.js\n// module id = 4\n// module chunks = 0","// removed by extract-text-webpack-plugin\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./src/noty.scss\n// module id = 5\n// module chunks = 0","/* global VERSION */\n\nimport 'noty.scss'\nimport Promise from 'es6-promise'\nimport * as Utils from 'utils'\nimport * as API from 'api'\nimport { NotyButton } from 'button'\nimport { Push } from 'push'\n\nexport default class Noty {\n /**\n * @param {object} options\n * @return {Noty}\n */\n constructor (options = {}) {\n this.options = Utils.deepExtend({}, API.Defaults, options)\n\n if (API.Store[this.options.id]) {\n return API.Store[this.options.id]\n }\n\n this.id = this.options.id || Utils.generateID('bar')\n this.closeTimer = -1\n this.barDom = null\n this.layoutDom = null\n this.progressDom = null\n this.showing = false\n this.shown = false\n this.closed = false\n this.closing = false\n this.killable = this.options.timeout || this.options.closeWith.length > 0\n this.hasSound = this.options.sounds.sources.length > 0\n this.soundPlayed = false\n this.listeners = {\n beforeShow: [],\n onShow: [],\n afterShow: [],\n onClose: [],\n afterClose: [],\n onClick: [],\n onHover: [],\n onTemplate: []\n }\n this.promises = {\n show: null,\n close: null\n }\n this.on('beforeShow', this.options.callbacks.beforeShow)\n this.on('onShow', this.options.callbacks.onShow)\n this.on('afterShow', this.options.callbacks.afterShow)\n this.on('onClose', this.options.callbacks.onClose)\n this.on('afterClose', this.options.callbacks.afterClose)\n this.on('onClick', this.options.callbacks.onClick)\n this.on('onHover', this.options.callbacks.onHover)\n this.on('onTemplate', this.options.callbacks.onTemplate)\n\n return this\n }\n\n /**\n * @param {string} eventName\n * @param {function} cb\n * @return {Noty}\n */\n on (eventName, cb = () => {}) {\n if (typeof cb === 'function' && this.listeners.hasOwnProperty(eventName)) {\n this.listeners[eventName].push(cb)\n }\n\n return this\n }\n\n /**\n * @return {Noty}\n */\n show () {\n if (this.showing || this.shown) {\n return this // preventing multiple show\n }\n\n if (this.options.killer === true) {\n Noty.closeAll()\n } else if (typeof this.options.killer === 'string') {\n Noty.closeAll(this.options.killer)\n }\n\n let queueCounts = API.getQueueCounts(this.options.queue)\n\n if (\n queueCounts.current >= queueCounts.maxVisible ||\n (API.PageHidden && this.options.visibilityControl)\n ) {\n API.addToQueue(this)\n\n if (\n API.PageHidden &&\n this.hasSound &&\n Utils.inArray('docHidden', this.options.sounds.conditions)\n ) {\n Utils.createAudioElements(this)\n }\n\n if (\n API.PageHidden &&\n Utils.inArray('docHidden', this.options.titleCount.conditions)\n ) {\n API.docTitle.increment()\n }\n\n return this\n }\n\n API.Store[this.id] = this\n\n API.fire(this, 'beforeShow')\n\n this.showing = true\n\n if (this.closing) {\n this.showing = false\n return this\n }\n\n API.build(this)\n API.handleModal(this)\n\n if (this.options.force) {\n this.layoutDom.insertBefore(this.barDom, this.layoutDom.firstChild)\n } else {\n this.layoutDom.appendChild(this.barDom)\n }\n\n if (\n this.hasSound &&\n !this.soundPlayed &&\n Utils.inArray('docVisible', this.options.sounds.conditions)\n ) {\n Utils.createAudioElements(this)\n }\n\n if (Utils.inArray('docVisible', this.options.titleCount.conditions)) {\n API.docTitle.increment()\n }\n\n this.shown = true\n this.closed = false\n\n // bind button events if any\n if (API.hasButtons(this)) {\n Object.keys(this.options.buttons).forEach(key => {\n const btn = this.barDom.querySelector(\n `#${this.options.buttons[key].id}`\n )\n Utils.addListener(btn, 'click', e => {\n Utils.stopPropagation(e)\n this.options.buttons[key].cb(this)\n })\n })\n }\n\n this.progressDom = this.barDom.querySelector('.noty_progressbar')\n\n if (Utils.inArray('click', this.options.closeWith)) {\n Utils.addClass(this.barDom, 'noty_close_with_click')\n Utils.addListener(\n this.barDom,\n 'click',\n e => {\n Utils.stopPropagation(e)\n API.fire(this, 'onClick')\n this.close()\n },\n false\n )\n }\n\n Utils.addListener(\n this.barDom,\n 'mouseenter',\n () => {\n API.fire(this, 'onHover')\n },\n false\n )\n\n if (this.options.timeout) Utils.addClass(this.barDom, 'noty_has_timeout')\n if (this.options.progressBar) {\n Utils.addClass(this.barDom, 'noty_has_progressbar')\n }\n\n if (Utils.inArray('button', this.options.closeWith)) {\n Utils.addClass(this.barDom, 'noty_close_with_button')\n\n const closeButton = document.createElement('div')\n Utils.addClass(closeButton, 'noty_close_button')\n closeButton.innerHTML = '×'\n this.barDom.appendChild(closeButton)\n\n Utils.addListener(\n closeButton,\n 'click',\n e => {\n Utils.stopPropagation(e)\n this.close()\n },\n false\n )\n }\n\n API.fire(this, 'onShow')\n\n if (this.options.animation.open === null) {\n this.promises.show = new Promise(resolve => {\n resolve()\n })\n } else if (typeof this.options.animation.open === 'function') {\n this.promises.show = new Promise(this.options.animation.open.bind(this))\n } else {\n Utils.addClass(this.barDom, this.options.animation.open)\n this.promises.show = new Promise(resolve => {\n Utils.addListener(this.barDom, Utils.animationEndEvents, () => {\n Utils.removeClass(this.barDom, this.options.animation.open)\n resolve()\n })\n })\n }\n\n this.promises.show.then(() => {\n const _t = this\n setTimeout(\n () => {\n API.openFlow(_t)\n },\n 100\n )\n })\n\n return this\n }\n\n /**\n * @return {Noty}\n */\n stop () {\n API.dequeueClose(this)\n return this\n }\n\n /**\n * @return {Noty}\n */\n resume () {\n API.queueClose(this)\n return this\n }\n\n /**\n * @param {int|boolean} ms\n * @return {Noty}\n */\n setTimeout (ms) {\n this.stop()\n this.options.timeout = ms\n\n if (this.barDom) {\n if (this.options.timeout) {\n Utils.addClass(this.barDom, 'noty_has_timeout')\n } else {\n Utils.removeClass(this.barDom, 'noty_has_timeout')\n }\n\n const _t = this\n setTimeout(\n function () {\n // ugly fix for progressbar display bug\n _t.resume()\n },\n 100\n )\n }\n\n return this\n }\n\n /**\n * @param {string} html\n * @param {boolean} optionsOverride\n * @return {Noty}\n */\n setText (html, optionsOverride = false) {\n if (this.barDom) {\n this.barDom.querySelector('.noty_body').innerHTML = html\n }\n\n if (optionsOverride) this.options.text = html\n\n return this\n }\n\n /**\n * @param {string} type\n * @param {boolean} optionsOverride\n * @return {Noty}\n */\n setType (type, optionsOverride = false) {\n if (this.barDom) {\n let classList = Utils.classList(this.barDom).split(' ')\n\n classList.forEach(c => {\n if (c.substring(0, 11) === 'noty_type__') {\n Utils.removeClass(this.barDom, c)\n }\n })\n\n Utils.addClass(this.barDom, `noty_type__${type}`)\n }\n\n if (optionsOverride) this.options.type = type\n\n return this\n }\n\n /**\n * @param {string} theme\n * @param {boolean} optionsOverride\n * @return {Noty}\n */\n setTheme (theme, optionsOverride = false) {\n if (this.barDom) {\n let classList = Utils.classList(this.barDom).split(' ')\n\n classList.forEach(c => {\n if (c.substring(0, 12) === 'noty_theme__') {\n Utils.removeClass(this.barDom, c)\n }\n })\n\n Utils.addClass(this.barDom, `noty_theme__${theme}`)\n }\n\n if (optionsOverride) this.options.theme = theme\n\n return this\n }\n\n /**\n * @return {Noty}\n */\n close () {\n if (this.closed) return this\n\n if (!this.shown) {\n // it's in the queue\n API.removeFromQueue(this)\n return this\n }\n\n API.fire(this, 'onClose')\n\n this.closing = true\n\n if (this.options.animation.close === null || this.options.animation.close === false) {\n this.promises.close = new Promise(resolve => {\n resolve()\n })\n } else if (typeof this.options.animation.close === 'function') {\n this.promises.close = new Promise(\n this.options.animation.close.bind(this)\n )\n } else {\n Utils.addClass(this.barDom, this.options.animation.close)\n this.promises.close = new Promise(resolve => {\n Utils.addListener(this.barDom, Utils.animationEndEvents, () => {\n if (this.options.force) {\n Utils.remove(this.barDom)\n } else {\n API.ghostFix(this)\n }\n resolve()\n })\n })\n }\n\n this.promises.close.then(() => {\n API.closeFlow(this)\n API.handleModalClose(this)\n })\n\n this.closed = true\n\n return this\n }\n\n // API functions\n\n /**\n * @param {boolean|string} queueName\n * @return {Noty}\n */\n static closeAll (queueName = false) {\n Object.keys(API.Store).forEach(id => {\n if (queueName) {\n if (\n API.Store[id].options.queue === queueName && API.Store[id].killable\n ) {\n API.Store[id].close()\n }\n } else if (API.Store[id].killable) {\n API.Store[id].close()\n }\n })\n return this\n }\n\n /**\n * @param {string} queueName\n * @return {Noty}\n */\n static clearQueue (queueName = 'global') {\n if (API.Queues.hasOwnProperty(queueName)) {\n API.Queues[queueName].queue = []\n }\n return this\n }\n\n /**\n * @return {API.Queues}\n */\n static get Queues () {\n return API.Queues\n }\n\n /**\n * @return {API.PageHidden}\n */\n static get PageHidden () {\n return API.PageHidden\n }\n\n /**\n * @param {Object} obj\n * @return {Noty}\n */\n static overrideDefaults (obj) {\n API.Defaults = Utils.deepExtend({}, API.Defaults, obj)\n return this\n }\n\n /**\n * @param {int} amount\n * @param {string} queueName\n * @return {Noty}\n */\n static setMaxVisible (amount = API.DefaultMaxVisible, queueName = 'global') {\n if (!API.Queues.hasOwnProperty(queueName)) {\n API.Queues[queueName] = {maxVisible: amount, queue: []}\n }\n\n API.Queues[queueName].maxVisible = amount\n return this\n }\n\n /**\n * @param {string} innerHtml\n * @param {String} classes\n * @param {Function} cb\n * @param {Object} attributes\n * @return {NotyButton}\n */\n static button (innerHtml, classes = null, cb, attributes = {}) {\n return new NotyButton(innerHtml, classes, cb, attributes)\n }\n\n /**\n * @return {string}\n */\n static version () {\n return VERSION\n }\n\n /**\n * @param {String} workerPath\n * @return {Push}\n */\n static Push (workerPath) {\n return new Push(workerPath)\n }\n}\n\n// Document visibility change controller\nif (typeof window !== 'undefined') {\n Utils.visibilityChangeFlow()\n}\n\n\n\n// WEBPACK FOOTER //\n// ./src/index.js","// shim for using process in browser\nvar process = module.exports = {};\n\n// cached from whatever global is present so that test runners that stub it\n// don't break things. But we need to wrap it in a try catch in case it is\n// wrapped in strict mode code which doesn't define any globals. It's inside a\n// function because try/catches deoptimize in certain engines.\n\nvar cachedSetTimeout;\nvar cachedClearTimeout;\n\nfunction defaultSetTimout() {\n throw new Error('setTimeout has not been defined');\n}\nfunction defaultClearTimeout () {\n throw new Error('clearTimeout has not been defined');\n}\n(function () {\n try {\n if (typeof setTimeout === 'function') {\n cachedSetTimeout = setTimeout;\n } else {\n cachedSetTimeout = defaultSetTimout;\n }\n } catch (e) {\n cachedSetTimeout = defaultSetTimout;\n }\n try {\n if (typeof clearTimeout === 'function') {\n cachedClearTimeout = clearTimeout;\n } else {\n cachedClearTimeout = defaultClearTimeout;\n }\n } catch (e) {\n cachedClearTimeout = defaultClearTimeout;\n }\n} ())\nfunction runTimeout(fun) {\n if (cachedSetTimeout === setTimeout) {\n //normal enviroments in sane situations\n return setTimeout(fun, 0);\n }\n // if setTimeout wasn't available but was latter defined\n if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {\n cachedSetTimeout = setTimeout;\n return setTimeout(fun, 0);\n }\n try {\n // when when somebody has screwed with setTimeout but no I.E. maddness\n return cachedSetTimeout(fun, 0);\n } catch(e){\n try {\n // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally\n return cachedSetTimeout.call(null, fun, 0);\n } catch(e){\n // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error\n return cachedSetTimeout.call(this, fun, 0);\n }\n }\n\n\n}\nfunction runClearTimeout(marker) {\n if (cachedClearTimeout === clearTimeout) {\n //normal enviroments in sane situations\n return clearTimeout(marker);\n }\n // if clearTimeout wasn't available but was latter defined\n if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {\n cachedClearTimeout = clearTimeout;\n return clearTimeout(marker);\n }\n try {\n // when when somebody has screwed with setTimeout but no I.E. maddness\n return cachedClearTimeout(marker);\n } catch (e){\n try {\n // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally\n return cachedClearTimeout.call(null, marker);\n } catch (e){\n // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.\n // Some versions of I.E. have different rules for clearTimeout vs setTimeout\n return cachedClearTimeout.call(this, marker);\n }\n }\n\n\n\n}\nvar queue = [];\nvar draining = false;\nvar currentQueue;\nvar queueIndex = -1;\n\nfunction cleanUpNextTick() {\n if (!draining || !currentQueue) {\n return;\n }\n draining = false;\n if (currentQueue.length) {\n queue = currentQueue.concat(queue);\n } else {\n queueIndex = -1;\n }\n if (queue.length) {\n drainQueue();\n }\n}\n\nfunction drainQueue() {\n if (draining) {\n return;\n }\n var timeout = runTimeout(cleanUpNextTick);\n draining = true;\n\n var len = queue.length;\n while(len) {\n currentQueue = queue;\n queue = [];\n while (++queueIndex < len) {\n if (currentQueue) {\n currentQueue[queueIndex].run();\n }\n }\n queueIndex = -1;\n len = queue.length;\n }\n currentQueue = null;\n draining = false;\n runClearTimeout(timeout);\n}\n\nprocess.nextTick = function (fun) {\n var args = new Array(arguments.length - 1);\n if (arguments.length > 1) {\n for (var i = 1; i < arguments.length; i++) {\n args[i - 1] = arguments[i];\n }\n }\n queue.push(new Item(fun, args));\n if (queue.length === 1 && !draining) {\n runTimeout(drainQueue);\n }\n};\n\n// v8 likes predictible objects\nfunction Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}\nItem.prototype.run = function () {\n this.fun.apply(null, this.array);\n};\nprocess.title = 'browser';\nprocess.browser = true;\nprocess.env = {};\nprocess.argv = [];\nprocess.version = ''; // empty string to avoid regexp issues\nprocess.versions = {};\n\nfunction noop() {}\n\nprocess.on = noop;\nprocess.addListener = noop;\nprocess.once = noop;\nprocess.off = noop;\nprocess.removeListener = noop;\nprocess.removeAllListeners = noop;\nprocess.emit = noop;\nprocess.prependListener = noop;\nprocess.prependOnceListener = noop;\n\nprocess.listeners = function (name) { return [] }\n\nprocess.binding = function (name) {\n throw new Error('process.binding is not supported');\n};\n\nprocess.cwd = function () { return '/' };\nprocess.chdir = function (dir) {\n throw new Error('process.chdir is not supported');\n};\nprocess.umask = function() { return 0; };\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/process/browser.js\n// module id = 7\n// module chunks = 0","var g;\r\n\r\n// This works in non-strict mode\r\ng = (function() {\r\n\treturn this;\r\n})();\r\n\r\ntry {\r\n\t// This works if eval is allowed (see CSP)\r\n\tg = g || Function(\"return this\")() || (1,eval)(\"this\");\r\n} catch(e) {\r\n\t// This works if the window reference is available\r\n\tif(typeof window === \"object\")\r\n\t\tg = window;\r\n}\r\n\r\n// g can still be undefined, but nothing to do about it...\r\n// We return undefined, instead of nothing here, so it's\r\n// easier to handle this case. if(!global) { ...}\r\n\r\nmodule.exports = g;\r\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// (webpack)/buildin/global.js\n// module id = 8\n// module chunks = 0","/* (ignored) */\n\n\n//////////////////\n// WEBPACK FOOTER\n// vertx (ignored)\n// module id = 9\n// module chunks = 0"],"sourceRoot":""}
\ No newline at end of file
diff --git a/node_modules/noty/lib/noty.min.js b/node_modules/noty/lib/noty.min.js
new file mode 100644
index 0000000..7419fe0
--- /dev/null
+++ b/node_modules/noty/lib/noty.min.js
@@ -0,0 +1,17 @@
+/*
+ @package NOTY - Dependency-free notification library
+ @version version: 3.2.0-beta
+ @contributors https://github.com/needim/noty/graphs/contributors
+ @documentation Examples and Documentation - https://ned.im/noty
+ @license Licensed under the MIT licenses: http://www.opensource.org/licenses/mit-license.php
+*/
+
+!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define("Noty",[],e):"object"==typeof exports?exports.Noty=e():t.Noty=e()}(this,function(){return function(t){function e(o){if(n[o])return n[o].exports;var i=n[o]={i:o,l:!1,exports:{}};return t[o].call(i.exports,i,i.exports,e),i.l=!0,i.exports}var n={};return e.m=t,e.c=n,e.i=function(t){return t},e.d=function(t,n,o){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:o})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=6)}([function(t,e,n){"use strict";function o(t,e,n){var o=void 0;if(!n){for(o in e)if(e.hasOwnProperty(o)&&e[o]===t)return!0}else for(o in e)if(e.hasOwnProperty(o)&&e[o]===t)return!0;return!1}function i(t){t=t||window.event,void 0!==t.stopPropagation?t.stopPropagation():t.cancelBubble=!0}function r(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e="noty_"+t+"_";return e+="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(t){var e=16*Math.random()|0;return("x"===t?e:3&e|8).toString(16)})}function s(t){var e=t.offsetHeight,n=window.getComputedStyle(t);return e+=parseInt(n.marginTop)+parseInt(n.marginBottom)}function u(t,e,n){var o=arguments.length>3&&void 0!==arguments[3]&&arguments[3];e=e.split(" ");for(var i=0;i=0}function c(t,e){var n=f(t),o=n+e;a(n,e)||(t.className=o.substring(1))}function l(t,e){var n=f(t),o=void 0;a(t,e)&&(o=n.replace(" "+e+" "," "),t.className=o.substring(1,o.length-1))}function d(t){t.parentNode&&t.parentNode.removeChild(t)}function f(t){return(" "+(t&&t.className||"")+" ").replace(/\s+/gi," ")}function h(){function t(){b.PageHidden=document[s],o()}function e(){b.PageHidden=!0,o()}function n(){b.PageHidden=!1,o()}function o(){b.PageHidden?i():r()}function i(){setTimeout(function(){Object.keys(b.Store).forEach(function(t){b.Store.hasOwnProperty(t)&&b.Store[t].options.visibilityControl&&b.Store[t].stop()})},100)}function r(){setTimeout(function(){Object.keys(b.Store).forEach(function(t){b.Store.hasOwnProperty(t)&&b.Store[t].options.visibilityControl&&b.Store[t].resume()}),b.queueRenderAll()},100)}var s=void 0,a=void 0;void 0!==document.hidden?(s="hidden",a="visibilitychange"):void 0!==document.msHidden?(s="msHidden",a="msvisibilitychange"):void 0!==document.webkitHidden&&(s="webkitHidden",a="webkitvisibilitychange"),a&&u(document,a,t),u(window,"blur",e),u(window,"focus",n)}function p(t){if(t.hasSound){var e=document.createElement("audio");t.options.sounds.sources.forEach(function(t){var n=document.createElement("source");n.src=t,n.type="audio/"+m(t),e.appendChild(n)}),t.barDom?t.barDom.appendChild(e):document.querySelector("body").appendChild(e),e.volume=t.options.sounds.volume,t.soundPlayed||(e.play(),t.soundPlayed=!0),e.onended=function(){d(e)}}}function m(t){return t.match(/\.([^.]+)$/)[1]}Object.defineProperty(e,"__esModule",{value:!0}),e.css=e.deepExtend=e.animationEndEvents=void 0;var v="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};e.inArray=o,e.stopPropagation=i,e.generateID=r,e.outerHeight=s,e.addListener=u,e.hasClass=a,e.addClass=c,e.removeClass=l,e.remove=d,e.classList=f,e.visibilityChangeFlow=h,e.createAudioElements=p;var y=n(1),b=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}(y);e.animationEndEvents="webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend",e.deepExtend=function t(e){e=e||{};for(var n=1;n0&&void 0!==arguments[0]?arguments[0]:"global",e=0,n=x;return E.hasOwnProperty(t)&&(n=E[t].maxVisible,Object.keys(P).forEach(function(n){P[n].options.queue!==t||P[n].closed||e++})),{current:e,maxVisible:n}}function i(t){E.hasOwnProperty(t.options.queue)||(E[t.options.queue]={maxVisible:x,queue:[]}),E[t.options.queue].queue.push(t)}function r(t){if(E.hasOwnProperty(t.options.queue)){var e=[];Object.keys(E[t.options.queue].queue).forEach(function(n){E[t.options.queue].queue[n].id!==t.id&&e.push(E[t.options.queue].queue[n])}),E[t.options.queue].queue=e}}function s(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"global";if(E.hasOwnProperty(t)){var e=E[t].queue.shift();e&&e.show()}}function u(){Object.keys(E).forEach(function(t){s(t)})}function a(t){var e=k.generateID("ghost"),n=document.createElement("div");n.setAttribute("id",e),k.css(n,{height:k.outerHeight(t.barDom)+"px"}),t.barDom.insertAdjacentHTML("afterend",n.outerHTML),k.remove(t.barDom),n=document.getElementById(e),k.addClass(n,"noty_fix_effects_height"),k.addListener(n,k.animationEndEvents,function(){k.remove(n)})}function c(t){m(t);var e='
'+t.options.text+"
"+d(t)+'';t.barDom=document.createElement("div"),t.barDom.setAttribute("id",t.id),k.addClass(t.barDom,"noty_bar noty_type__"+t.options.type+" noty_theme__"+t.options.theme),t.barDom.innerHTML=e,b(t,"onTemplate")}function l(t){return!(!t.options.buttons||!Object.keys(t.options.buttons).length)}function d(t){if(l(t)){var e=document.createElement("div");return k.addClass(e,"noty_buttons"),Object.keys(t.options.buttons).forEach(function(n){e.appendChild(t.options.buttons[n].dom)}),t.options.buttons.forEach(function(t){e.appendChild(t.dom)}),e.outerHTML}return""}function f(t){t.options.modal&&(0===C&&p(),e.DocModalCount=C+=1)}function h(t){if(t.options.modal&&C>0&&(e.DocModalCount=C-=1,C<=0)){var n=document.querySelector(".noty_modal");n&&(k.removeClass(n,"noty_modal_open"),k.addClass(n,"noty_modal_close"),k.addListener(n,k.animationEndEvents,function(){k.remove(n)}))}}function p(){var t=document.querySelector("body"),e=document.createElement("div");k.addClass(e,"noty_modal"),t.insertBefore(e,t.firstChild),k.addClass(e,"noty_modal_open"),k.addListener(e,k.animationEndEvents,function(){k.removeClass(e,"noty_modal_open")})}function m(t){if(t.options.container)return void(t.layoutDom=document.querySelector(t.options.container));var e="noty_layout__"+t.options.layout;t.layoutDom=document.querySelector("div#"+e),t.layoutDom||(t.layoutDom=document.createElement("div"),t.layoutDom.setAttribute("id",e),t.layoutDom.setAttribute("role","alert"),t.layoutDom.setAttribute("aria-live","polite"),k.addClass(t.layoutDom,"noty_layout"),document.querySelector("body").appendChild(t.layoutDom))}function v(t){t.options.timeout&&(t.options.progressBar&&t.progressDom&&k.css(t.progressDom,{transition:"width "+t.options.timeout+"ms linear",width:"0%"}),clearTimeout(t.closeTimer),t.closeTimer=setTimeout(function(){t.close()},t.options.timeout))}function y(t){t.options.timeout&&t.closeTimer&&(clearTimeout(t.closeTimer),t.closeTimer=-1,t.options.progressBar&&t.progressDom&&k.css(t.progressDom,{transition:"width 0ms linear",width:"100%"}))}function b(t,e){t.listeners.hasOwnProperty(e)&&t.listeners[e].forEach(function(e){"function"==typeof e&&e.apply(t)})}function w(t){b(t,"afterShow"),v(t),k.addListener(t.barDom,"mouseenter",function(){y(t)}),k.addListener(t.barDom,"mouseleave",function(){v(t)})}function g(t){delete P[t.id],t.closing=!1,b(t,"afterClose"),k.remove(t.barDom),0!==t.layoutDom.querySelectorAll(".noty_bar").length||t.options.container||k.remove(t.layoutDom),(k.inArray("docVisible",t.options.titleCount.conditions)||k.inArray("docHidden",t.options.titleCount.conditions))&&D.decrement(),s(t.options.queue)}Object.defineProperty(e,"__esModule",{value:!0}),e.Defaults=e.Store=e.Queues=e.DefaultMaxVisible=e.docTitle=e.DocModalCount=e.PageHidden=void 0,e.getQueueCounts=o,e.addToQueue=i,e.removeFromQueue=r,e.queueRender=s,e.queueRenderAll=u,e.ghostFix=a,e.build=c,e.hasButtons=l,e.handleModal=f,e.handleModalClose=h,e.queueClose=v,e.dequeueClose=y,e.fire=b,e.openFlow=w,e.closeFlow=g;var _=n(0),k=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}(_),C=(e.PageHidden=!1,e.DocModalCount=0),S={originalTitle:null,count:0,changed:!1,timer:-1},D=e.docTitle={increment:function(){S.count++,D._update()},decrement:function(){if(--S.count<=0)return void D._clear();D._update()},_update:function(){var t=document.title;S.changed?document.title="("+S.count+") "+S.originalTitle:(S.originalTitle=t,document.title="("+S.count+") "+t,S.changed=!0)},_clear:function(){S.changed&&(S.count=0,document.title=S.originalTitle,S.changed=!1)}},x=e.DefaultMaxVisible=5,E=e.Queues={global:{maxVisible:x,queue:[]}},P=e.Store={};e.Defaults={type:"alert",layout:"topRight",theme:"mint",text:"",timeout:!1,progressBar:!0,closeWith:["click"],animation:{open:"noty_effects_open",close:"noty_effects_close"},id:!1,force:!1,killer:!1,queue:"global",container:!1,buttons:[],callbacks:{beforeShow:null,onShow:null,afterShow:null,onClose:null,afterClose:null,onClick:null,onHover:null,onTemplate:null},sounds:{sources:[],volume:1,conditions:[]},titleCount:{conditions:[]},modal:!1,visibilityControl:!1}},function(t,e,n){"use strict";function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0}),e.NotyButton=void 0;var i=n(0),r=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}(i);e.NotyButton=function t(e,n,i){var s=this,u=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return o(this,t),this.dom=document.createElement("button"),this.dom.innerHTML=e,this.id=u.id=u.id||r.generateID("button"),this.cb=i,Object.keys(u).forEach(function(t){s.dom.setAttribute(t,u[t])}),r.addClass(this.dom,n||"noty_btn"),this}},function(t,e,n){"use strict";function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var i=function(){function t(t,e){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:"/service-worker.js";return o(this,t),this.subData={},this.workerPath=e,this.listeners={onPermissionGranted:[],onPermissionDenied:[],onSubscriptionSuccess:[],onSubscriptionCancel:[],onWorkerError:[],onWorkerSuccess:[],onWorkerNotSupported:[]},this}return i(t,[{key:"on",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){};return"function"==typeof e&&this.listeners.hasOwnProperty(t)&&this.listeners[t].push(e),this}},{key:"fire",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];this.listeners.hasOwnProperty(t)&&this.listeners[t].forEach(function(t){"function"==typeof t&&t.apply(e,n)})}},{key:"create",value:function(){console.log("NOT IMPLEMENTED YET")}},{key:"isSupported",value:function(){var t=!1;try{t=window.Notification||window.webkitNotifications||navigator.mozNotification||window.external&&void 0!==window.external.msIsSiteMode()}catch(t){}return t}},{key:"getPermissionStatus",value:function(){var t="default";if(window.Notification&&window.Notification.permissionLevel)t=window.Notification.permissionLevel;else if(window.webkitNotifications&&window.webkitNotifications.checkPermission)switch(window.webkitNotifications.checkPermission()){case 1:t="default";break;case 0:t="granted";break;default:t="denied"}else window.Notification&&window.Notification.permission?t=window.Notification.permission:navigator.mozNotification?t="granted":window.external&&void 0!==window.external.msIsSiteMode()&&(t=window.external.msIsSiteMode()?"granted":"default");return t.toString().toLowerCase()}},{key:"getEndpoint",value:function(t){var e=t.endpoint,n=t.subscriptionId;return n&&-1===e.indexOf(n)&&(e+="/"+n),e}},{key:"isSWRegistered",value:function(){try{return"activated"===navigator.serviceWorker.controller.state}catch(t){return!1}}},{key:"unregisterWorker",value:function(){var t=this;"serviceWorker"in navigator&&navigator.serviceWorker.getRegistrations().then(function(e){var n=!0,o=!1,i=void 0;try{for(var r,s=e[Symbol.iterator]();!(n=(r=s.next()).done);n=!0){r.value.unregister(),t.fire("onSubscriptionCancel")}}catch(t){o=!0,i=t}finally{try{!n&&s.return&&s.return()}finally{if(o)throw i}}})}},{key:"requestSubscription",value:function(){var t=this,e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],n=this,o=this.getPermissionStatus(),i=function(o){"granted"===o?(t.fire("onPermissionGranted"),"serviceWorker"in navigator?navigator.serviceWorker.register(t.workerPath).then(function(){navigator.serviceWorker.ready.then(function(t){n.fire("onWorkerSuccess"),t.pushManager.subscribe({userVisibleOnly:e}).then(function(t){var e=t.getKey("p256dh"),o=t.getKey("auth");n.subData={endpoint:n.getEndpoint(t),p256dh:e?window.btoa(String.fromCharCode.apply(null,new Uint8Array(e))):null,auth:o?window.btoa(String.fromCharCode.apply(null,new Uint8Array(o))):null},n.fire("onSubscriptionSuccess",[n.subData])}).catch(function(t){n.fire("onWorkerError",[t])})})}):n.fire("onWorkerNotSupported")):"denied"===o&&(t.fire("onPermissionDenied"),t.unregisterWorker())};"default"===o?window.Notification&&window.Notification.requestPermission?window.Notification.requestPermission(i):window.webkitNotifications&&window.webkitNotifications.checkPermission&&window.webkitNotifications.requestPermission(i):i(o)}}]),t}()},function(t,e,n){(function(e,o){/*!
+ * @overview es6-promise - a tiny implementation of Promises/A+.
+ * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)
+ * @license Licensed under MIT license
+ * See https://raw.githubusercontent.com/stefanpenner/es6-promise/master/LICENSE
+ * @version 4.1.1
+ */
+!function(e,n){t.exports=n()}(0,function(){"use strict";function t(t){var e=typeof t;return null!==t&&("object"===e||"function"===e)}function i(t){return"function"==typeof t}function r(t){z=t}function s(t){U=t}function u(){return void 0!==R?function(){R(c)}:a()}function a(){var t=setTimeout;return function(){return t(c,1)}}function c(){for(var t=0;t0&&void 0!==arguments[0]?arguments[0]:{};return i(this,t),this.options=c.deepExtend({},d.Defaults,e),d.Store[this.options.id]?d.Store[this.options.id]:(this.id=this.options.id||c.generateID("bar"),this.closeTimer=-1,this.barDom=null,this.layoutDom=null,this.progressDom=null,this.showing=!1,this.shown=!1,this.closed=!1,this.closing=!1,this.killable=this.options.timeout||this.options.closeWith.length>0,this.hasSound=this.options.sounds.sources.length>0,this.soundPlayed=!1,this.listeners={beforeShow:[],onShow:[],afterShow:[],onClose:[],afterClose:[],onClick:[],onHover:[],onTemplate:[]},this.promises={show:null,close:null},this.on("beforeShow",this.options.callbacks.beforeShow),this.on("onShow",this.options.callbacks.onShow),this.on("afterShow",this.options.callbacks.afterShow),this.on("onClose",this.options.callbacks.onClose),this.on("afterClose",this.options.callbacks.afterClose),this.on("onClick",this.options.callbacks.onClick),this.on("onHover",this.options.callbacks.onHover),this.on("onTemplate",this.options.callbacks.onTemplate),this)}return r(t,[{key:"on",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){};return"function"==typeof e&&this.listeners.hasOwnProperty(t)&&this.listeners[t].push(e),this}},{key:"show",value:function(){var e=this;if(this.showing||this.shown)return this;!0===this.options.killer?t.closeAll():"string"==typeof this.options.killer&&t.closeAll(this.options.killer);var n=d.getQueueCounts(this.options.queue);if(n.current>=n.maxVisible||d.PageHidden&&this.options.visibilityControl)return d.addToQueue(this),d.PageHidden&&this.hasSound&&c.inArray("docHidden",this.options.sounds.conditions)&&c.createAudioElements(this),d.PageHidden&&c.inArray("docHidden",this.options.titleCount.conditions)&&d.docTitle.increment(),this;if(d.Store[this.id]=this,d.fire(this,"beforeShow"),this.showing=!0,this.closing)return this.showing=!1,this;if(d.build(this),d.handleModal(this),this.options.force?this.layoutDom.insertBefore(this.barDom,this.layoutDom.firstChild):this.layoutDom.appendChild(this.barDom),this.hasSound&&!this.soundPlayed&&c.inArray("docVisible",this.options.sounds.conditions)&&c.createAudioElements(this),c.inArray("docVisible",this.options.titleCount.conditions)&&d.docTitle.increment(),this.shown=!0,this.closed=!1,d.hasButtons(this)&&Object.keys(this.options.buttons).forEach(function(t){var n=e.barDom.querySelector("#"+e.options.buttons[t].id);c.addListener(n,"click",function(n){c.stopPropagation(n),e.options.buttons[t].cb(e)})}),this.progressDom=this.barDom.querySelector(".noty_progressbar"),c.inArray("click",this.options.closeWith)&&(c.addClass(this.barDom,"noty_close_with_click"),c.addListener(this.barDom,"click",function(t){c.stopPropagation(t),d.fire(e,"onClick"),e.close()},!1)),c.addListener(this.barDom,"mouseenter",function(){d.fire(e,"onHover")},!1),this.options.timeout&&c.addClass(this.barDom,"noty_has_timeout"),this.options.progressBar&&c.addClass(this.barDom,"noty_has_progressbar"),c.inArray("button",this.options.closeWith)){c.addClass(this.barDom,"noty_close_with_button");var o=document.createElement("div");c.addClass(o,"noty_close_button"),o.innerHTML="×",this.barDom.appendChild(o),c.addListener(o,"click",function(t){c.stopPropagation(t),e.close()},!1)}return d.fire(this,"onShow"),null===this.options.animation.open?this.promises.show=new u.default(function(t){t()}):"function"==typeof this.options.animation.open?this.promises.show=new u.default(this.options.animation.open.bind(this)):(c.addClass(this.barDom,this.options.animation.open),this.promises.show=new u.default(function(t){c.addListener(e.barDom,c.animationEndEvents,function(){c.removeClass(e.barDom,e.options.animation.open),t()})})),this.promises.show.then(function(){var t=e;setTimeout(function(){d.openFlow(t)},100)}),this}},{key:"stop",value:function(){return d.dequeueClose(this),this}},{key:"resume",value:function(){return d.queueClose(this),this}},{key:"setTimeout",value:function(t){function e(e){return t.apply(this,arguments)}return e.toString=function(){return t.toString()},e}(function(t){if(this.stop(),this.options.timeout=t,this.barDom){this.options.timeout?c.addClass(this.barDom,"noty_has_timeout"):c.removeClass(this.barDom,"noty_has_timeout");var e=this;setTimeout(function(){e.resume()},100)}return this})},{key:"setText",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return this.barDom&&(this.barDom.querySelector(".noty_body").innerHTML=t),e&&(this.options.text=t),this}},{key:"setType",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(this.barDom){c.classList(this.barDom).split(" ").forEach(function(t){"noty_type__"===t.substring(0,11)&&c.removeClass(e.barDom,t)}),c.addClass(this.barDom,"noty_type__"+t)}return n&&(this.options.type=t),this}},{key:"setTheme",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(this.barDom){c.classList(this.barDom).split(" ").forEach(function(t){"noty_theme__"===t.substring(0,12)&&c.removeClass(e.barDom,t)}),c.addClass(this.barDom,"noty_theme__"+t)}return n&&(this.options.theme=t),this}},{key:"close",value:function(){var t=this;return this.closed?this:this.shown?(d.fire(this,"onClose"),this.closing=!0,null===this.options.animation.close||!1===this.options.animation.close?this.promises.close=new u.default(function(t){t()}):"function"==typeof this.options.animation.close?this.promises.close=new u.default(this.options.animation.close.bind(this)):(c.addClass(this.barDom,this.options.animation.close),this.promises.close=new u.default(function(e){c.addListener(t.barDom,c.animationEndEvents,function(){t.options.force?c.remove(t.barDom):d.ghostFix(t),e()})})),this.promises.close.then(function(){d.closeFlow(t),d.handleModalClose(t)}),this.closed=!0,this):(d.removeFromQueue(this),this)}}],[{key:"closeAll",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return Object.keys(d.Store).forEach(function(e){t?d.Store[e].options.queue===t&&d.Store[e].killable&&d.Store[e].close():d.Store[e].killable&&d.Store[e].close()}),this}},{key:"clearQueue",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"global";return d.Queues.hasOwnProperty(t)&&(d.Queues[t].queue=[]),this}},{key:"overrideDefaults",value:function(t){return d.Defaults=c.deepExtend({},d.Defaults,t),this}},{key:"setMaxVisible",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d.DefaultMaxVisible,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"global";return d.Queues.hasOwnProperty(e)||(d.Queues[e]={maxVisible:t,queue:[]}),d.Queues[e].maxVisible=t,this}},{key:"button",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments[2],o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return new f.NotyButton(t,e,n,o)}},{key:"version",value:function(){return"3.2.0-beta"}},{key:"Push",value:function(t){return new h.Push(t)}},{key:"Queues",get:function(){return d.Queues}},{key:"PageHidden",get:function(){return d.PageHidden}}]),t}();e.default=p,"undefined"!=typeof window&&c.visibilityChangeFlow(),t.exports=e.default},function(t,e){function n(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function i(t){if(l===setTimeout)return setTimeout(t,0);if((l===n||!l)&&setTimeout)return l=setTimeout,setTimeout(t,0);try{return l(t,0)}catch(e){try{return l.call(null,t,0)}catch(e){return l.call(this,t,0)}}}function r(t){if(d===clearTimeout)return clearTimeout(t);if((d===o||!d)&&clearTimeout)return d=clearTimeout,clearTimeout(t);try{return d(t)}catch(e){try{return d.call(null,t)}catch(e){return d.call(this,t)}}}function s(){m&&h&&(m=!1,h.length?p=h.concat(p):v=-1,p.length&&u())}function u(){if(!m){var t=i(s);m=!0;for(var e=p.length;e;){for(h=p,p=[];++v1)for(var n=1;n 0 && arguments[0] !== undefined ? arguments[0] : '';\n\n var id = 'noty_' + prefix + '_';\n\n id += 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {\n var r = Math.random() * 16 | 0;\n var v = c === 'x' ? r : r & 0x3 | 0x8;\n return v.toString(16);\n });\n\n return id;\n}\n\nfunction outerHeight(el) {\n var height = el.offsetHeight;\n var style = window.getComputedStyle(el);\n\n height += parseInt(style.marginTop) + parseInt(style.marginBottom);\n return height;\n}\n\nvar css = exports.css = function () {\n var cssPrefixes = ['Webkit', 'O', 'Moz', 'ms'];\n var cssProps = {};\n\n function camelCase(string) {\n return string.replace(/^-ms-/, 'ms-').replace(/-([\\da-z])/gi, function (match, letter) {\n return letter.toUpperCase();\n });\n }\n\n function getVendorProp(name) {\n var style = document.body.style;\n if (name in style) return name;\n\n var i = cssPrefixes.length;\n var capName = name.charAt(0).toUpperCase() + name.slice(1);\n var vendorName = void 0;\n\n while (i--) {\n vendorName = cssPrefixes[i] + capName;\n if (vendorName in style) return vendorName;\n }\n\n return name;\n }\n\n function getStyleProp(name) {\n name = camelCase(name);\n return cssProps[name] || (cssProps[name] = getVendorProp(name));\n }\n\n function applyCss(element, prop, value) {\n prop = getStyleProp(prop);\n element.style[prop] = value;\n }\n\n return function (element, properties) {\n var args = arguments;\n var prop = void 0;\n var value = void 0;\n\n if (args.length === 2) {\n for (prop in properties) {\n if (properties.hasOwnProperty(prop)) {\n value = properties[prop];\n if (value !== undefined && properties.hasOwnProperty(prop)) {\n applyCss(element, prop, value);\n }\n }\n }\n } else {\n applyCss(element, args[1], args[2]);\n }\n };\n}();\n\nfunction addListener(el, events, cb) {\n var useCapture = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;\n\n events = events.split(' ');\n for (var i = 0; i < events.length; i++) {\n if (document.addEventListener) {\n el.addEventListener(events[i], cb, useCapture);\n } else if (document.attachEvent) {\n el.attachEvent('on' + events[i], cb);\n }\n }\n}\n\nfunction hasClass(element, name) {\n var list = typeof element === 'string' ? element : classList(element);\n return list.indexOf(' ' + name + ' ') >= 0;\n}\n\nfunction addClass(element, name) {\n var oldList = classList(element);\n var newList = oldList + name;\n\n if (hasClass(oldList, name)) return;\n\n // Trim the opening space.\n element.className = newList.substring(1);\n}\n\nfunction removeClass(element, name) {\n var oldList = classList(element);\n var newList = void 0;\n\n if (!hasClass(element, name)) return;\n\n // Replace the class name.\n newList = oldList.replace(' ' + name + ' ', ' ');\n\n // Trim the opening and closing spaces.\n element.className = newList.substring(1, newList.length - 1);\n}\n\nfunction remove(element) {\n if (element.parentNode) {\n element.parentNode.removeChild(element);\n }\n}\n\nfunction classList(element) {\n return (' ' + (element && element.className || '') + ' ').replace(/\\s+/gi, ' ');\n}\n\nfunction visibilityChangeFlow() {\n var hidden = void 0;\n var visibilityChange = void 0;\n if (typeof document.hidden !== 'undefined') {\n // Opera 12.10 and Firefox 18 and later support\n hidden = 'hidden';\n visibilityChange = 'visibilitychange';\n } else if (typeof document.msHidden !== 'undefined') {\n hidden = 'msHidden';\n visibilityChange = 'msvisibilitychange';\n } else if (typeof document.webkitHidden !== 'undefined') {\n hidden = 'webkitHidden';\n visibilityChange = 'webkitvisibilitychange';\n }\n\n function onVisibilityChange() {\n API.PageHidden = document[hidden];\n handleVisibilityChange();\n }\n\n function onBlur() {\n API.PageHidden = true;\n handleVisibilityChange();\n }\n\n function onFocus() {\n API.PageHidden = false;\n handleVisibilityChange();\n }\n\n function handleVisibilityChange() {\n if (API.PageHidden) stopAll();else resumeAll();\n }\n\n function stopAll() {\n setTimeout(function () {\n Object.keys(API.Store).forEach(function (id) {\n if (API.Store.hasOwnProperty(id)) {\n if (API.Store[id].options.visibilityControl) {\n API.Store[id].stop();\n }\n }\n });\n }, 100);\n }\n\n function resumeAll() {\n setTimeout(function () {\n Object.keys(API.Store).forEach(function (id) {\n if (API.Store.hasOwnProperty(id)) {\n if (API.Store[id].options.visibilityControl) {\n API.Store[id].resume();\n }\n }\n });\n API.queueRenderAll();\n }, 100);\n }\n\n if (visibilityChange) {\n addListener(document, visibilityChange, onVisibilityChange);\n }\n\n addListener(window, 'blur', onBlur);\n addListener(window, 'focus', onFocus);\n}\n\nfunction createAudioElements(ref) {\n if (ref.hasSound) {\n var audioElement = document.createElement('audio');\n\n ref.options.sounds.sources.forEach(function (s) {\n var source = document.createElement('source');\n source.src = s;\n source.type = 'audio/' + getExtension(s);\n audioElement.appendChild(source);\n });\n\n if (ref.barDom) {\n ref.barDom.appendChild(audioElement);\n } else {\n document.querySelector('body').appendChild(audioElement);\n }\n\n audioElement.volume = ref.options.sounds.volume;\n\n if (!ref.soundPlayed) {\n audioElement.play();\n ref.soundPlayed = true;\n }\n\n audioElement.onended = function () {\n remove(audioElement);\n };\n }\n}\n\nfunction getExtension(fileName) {\n return fileName.match(/\\.([^.]+)$/)[1];\n}\n\n/***/ }),\n/* 1 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.Defaults = exports.Store = exports.Queues = exports.DefaultMaxVisible = exports.docTitle = exports.DocModalCount = exports.PageHidden = undefined;\nexports.getQueueCounts = getQueueCounts;\nexports.addToQueue = addToQueue;\nexports.removeFromQueue = removeFromQueue;\nexports.queueRender = queueRender;\nexports.queueRenderAll = queueRenderAll;\nexports.ghostFix = ghostFix;\nexports.build = build;\nexports.hasButtons = hasButtons;\nexports.handleModal = handleModal;\nexports.handleModalClose = handleModalClose;\nexports.queueClose = queueClose;\nexports.dequeueClose = dequeueClose;\nexports.fire = fire;\nexports.openFlow = openFlow;\nexports.closeFlow = closeFlow;\n\nvar _utils = __webpack_require__(0);\n\nvar Utils = _interopRequireWildcard(_utils);\n\nfunction _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }\n\nvar PageHidden = exports.PageHidden = false;\nvar DocModalCount = exports.DocModalCount = 0;\n\nvar DocTitleProps = {\n originalTitle: null,\n count: 0,\n changed: false,\n timer: -1\n};\n\nvar docTitle = exports.docTitle = {\n increment: function increment() {\n DocTitleProps.count++;\n\n docTitle._update();\n },\n\n decrement: function decrement() {\n DocTitleProps.count--;\n\n if (DocTitleProps.count <= 0) {\n docTitle._clear();\n return;\n }\n\n docTitle._update();\n },\n\n _update: function _update() {\n var title = document.title;\n\n if (!DocTitleProps.changed) {\n DocTitleProps.originalTitle = title;\n document.title = '(' + DocTitleProps.count + ') ' + title;\n DocTitleProps.changed = true;\n } else {\n document.title = '(' + DocTitleProps.count + ') ' + DocTitleProps.originalTitle;\n }\n },\n\n _clear: function _clear() {\n if (DocTitleProps.changed) {\n DocTitleProps.count = 0;\n document.title = DocTitleProps.originalTitle;\n DocTitleProps.changed = false;\n }\n }\n};\n\nvar DefaultMaxVisible = exports.DefaultMaxVisible = 5;\n\nvar Queues = exports.Queues = {\n global: {\n maxVisible: DefaultMaxVisible,\n queue: []\n }\n};\n\nvar Store = exports.Store = {};\n\nvar Defaults = exports.Defaults = {\n type: 'alert',\n layout: 'topRight',\n theme: 'mint',\n text: '',\n timeout: false,\n progressBar: true,\n closeWith: ['click'],\n animation: {\n open: 'noty_effects_open',\n close: 'noty_effects_close'\n },\n id: false,\n force: false,\n killer: false,\n queue: 'global',\n container: false,\n buttons: [],\n callbacks: {\n beforeShow: null,\n onShow: null,\n afterShow: null,\n onClose: null,\n afterClose: null,\n onClick: null,\n onHover: null,\n onTemplate: null\n },\n sounds: {\n sources: [],\n volume: 1,\n conditions: []\n },\n titleCount: {\n conditions: []\n },\n modal: false,\n visibilityControl: false\n\n /**\r\n * @param {string} queueName\r\n * @return {object}\r\n */\n};function getQueueCounts() {\n var queueName = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'global';\n\n var count = 0;\n var max = DefaultMaxVisible;\n\n if (Queues.hasOwnProperty(queueName)) {\n max = Queues[queueName].maxVisible;\n Object.keys(Store).forEach(function (i) {\n if (Store[i].options.queue === queueName && !Store[i].closed) count++;\n });\n }\n\n return {\n current: count,\n maxVisible: max\n };\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\nfunction addToQueue(ref) {\n if (!Queues.hasOwnProperty(ref.options.queue)) {\n Queues[ref.options.queue] = { maxVisible: DefaultMaxVisible, queue: [] };\n }\n\n Queues[ref.options.queue].queue.push(ref);\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\nfunction removeFromQueue(ref) {\n if (Queues.hasOwnProperty(ref.options.queue)) {\n var queue = [];\n Object.keys(Queues[ref.options.queue].queue).forEach(function (i) {\n if (Queues[ref.options.queue].queue[i].id !== ref.id) {\n queue.push(Queues[ref.options.queue].queue[i]);\n }\n });\n Queues[ref.options.queue].queue = queue;\n }\n}\n\n/**\r\n * @param {string} queueName\r\n * @return {void}\r\n */\nfunction queueRender() {\n var queueName = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'global';\n\n if (Queues.hasOwnProperty(queueName)) {\n var noty = Queues[queueName].queue.shift();\n\n if (noty) noty.show();\n }\n}\n\n/**\r\n * @return {void}\r\n */\nfunction queueRenderAll() {\n Object.keys(Queues).forEach(function (queueName) {\n queueRender(queueName);\n });\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\nfunction ghostFix(ref) {\n var ghostID = Utils.generateID('ghost');\n var ghost = document.createElement('div');\n ghost.setAttribute('id', ghostID);\n Utils.css(ghost, {\n height: Utils.outerHeight(ref.barDom) + 'px'\n });\n\n ref.barDom.insertAdjacentHTML('afterend', ghost.outerHTML);\n\n Utils.remove(ref.barDom);\n ghost = document.getElementById(ghostID);\n Utils.addClass(ghost, 'noty_fix_effects_height');\n Utils.addListener(ghost, Utils.animationEndEvents, function () {\n Utils.remove(ghost);\n });\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\nfunction build(ref) {\n findOrCreateContainer(ref);\n\n var markup = '
' + ref.options.text + '
' + buildButtons(ref) + '';\n\n ref.barDom = document.createElement('div');\n ref.barDom.setAttribute('id', ref.id);\n Utils.addClass(ref.barDom, 'noty_bar noty_type__' + ref.options.type + ' noty_theme__' + ref.options.theme);\n\n ref.barDom.innerHTML = markup;\n\n fire(ref, 'onTemplate');\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {boolean}\r\n */\nfunction hasButtons(ref) {\n return !!(ref.options.buttons && Object.keys(ref.options.buttons).length);\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {string}\r\n */\nfunction buildButtons(ref) {\n if (hasButtons(ref)) {\n var buttons = document.createElement('div');\n Utils.addClass(buttons, 'noty_buttons');\n\n Object.keys(ref.options.buttons).forEach(function (key) {\n buttons.appendChild(ref.options.buttons[key].dom);\n });\n\n ref.options.buttons.forEach(function (btn) {\n buttons.appendChild(btn.dom);\n });\n return buttons.outerHTML;\n }\n return '';\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\nfunction handleModal(ref) {\n if (ref.options.modal) {\n if (DocModalCount === 0) {\n createModal(ref);\n }\n\n exports.DocModalCount = DocModalCount += 1;\n }\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\nfunction handleModalClose(ref) {\n if (ref.options.modal && DocModalCount > 0) {\n exports.DocModalCount = DocModalCount -= 1;\n\n if (DocModalCount <= 0) {\n var modal = document.querySelector('.noty_modal');\n\n if (modal) {\n Utils.removeClass(modal, 'noty_modal_open');\n Utils.addClass(modal, 'noty_modal_close');\n Utils.addListener(modal, Utils.animationEndEvents, function () {\n Utils.remove(modal);\n });\n }\n }\n }\n}\n\n/**\r\n * @return {void}\r\n */\nfunction createModal() {\n var body = document.querySelector('body');\n var modal = document.createElement('div');\n Utils.addClass(modal, 'noty_modal');\n body.insertBefore(modal, body.firstChild);\n Utils.addClass(modal, 'noty_modal_open');\n\n Utils.addListener(modal, Utils.animationEndEvents, function () {\n Utils.removeClass(modal, 'noty_modal_open');\n });\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\nfunction findOrCreateContainer(ref) {\n if (ref.options.container) {\n ref.layoutDom = document.querySelector(ref.options.container);\n return;\n }\n\n var layoutID = 'noty_layout__' + ref.options.layout;\n ref.layoutDom = document.querySelector('div#' + layoutID);\n\n if (!ref.layoutDom) {\n ref.layoutDom = document.createElement('div');\n ref.layoutDom.setAttribute('id', layoutID);\n ref.layoutDom.setAttribute('role', 'alert');\n ref.layoutDom.setAttribute('aria-live', 'polite');\n Utils.addClass(ref.layoutDom, 'noty_layout');\n document.querySelector('body').appendChild(ref.layoutDom);\n }\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\nfunction queueClose(ref) {\n if (ref.options.timeout) {\n if (ref.options.progressBar && ref.progressDom) {\n Utils.css(ref.progressDom, {\n transition: 'width ' + ref.options.timeout + 'ms linear',\n width: '0%'\n });\n }\n\n clearTimeout(ref.closeTimer);\n\n ref.closeTimer = setTimeout(function () {\n ref.close();\n }, ref.options.timeout);\n }\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\nfunction dequeueClose(ref) {\n if (ref.options.timeout && ref.closeTimer) {\n clearTimeout(ref.closeTimer);\n ref.closeTimer = -1;\n\n if (ref.options.progressBar && ref.progressDom) {\n Utils.css(ref.progressDom, {\n transition: 'width 0ms linear',\n width: '100%'\n });\n }\n }\n}\n\n/**\r\n * @param {Noty} ref\r\n * @param {string} eventName\r\n * @return {void}\r\n */\nfunction fire(ref, eventName) {\n if (ref.listeners.hasOwnProperty(eventName)) {\n ref.listeners[eventName].forEach(function (cb) {\n if (typeof cb === 'function') {\n cb.apply(ref);\n }\n });\n }\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\nfunction openFlow(ref) {\n fire(ref, 'afterShow');\n queueClose(ref);\n\n Utils.addListener(ref.barDom, 'mouseenter', function () {\n dequeueClose(ref);\n });\n\n Utils.addListener(ref.barDom, 'mouseleave', function () {\n queueClose(ref);\n });\n}\n\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\nfunction closeFlow(ref) {\n delete Store[ref.id];\n ref.closing = false;\n fire(ref, 'afterClose');\n\n Utils.remove(ref.barDom);\n\n if (ref.layoutDom.querySelectorAll('.noty_bar').length === 0 && !ref.options.container) {\n Utils.remove(ref.layoutDom);\n }\n\n if (Utils.inArray('docVisible', ref.options.titleCount.conditions) || Utils.inArray('docHidden', ref.options.titleCount.conditions)) {\n docTitle.decrement();\n }\n\n queueRender(ref.options.queue);\n}\n\n/***/ }),\n/* 2 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.NotyButton = undefined;\n\nvar _utils = __webpack_require__(0);\n\nvar Utils = _interopRequireWildcard(_utils);\n\nfunction _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nvar NotyButton = exports.NotyButton = function NotyButton(html, classes, cb) {\n var _this = this;\n\n var attributes = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};\n\n _classCallCheck(this, NotyButton);\n\n this.dom = document.createElement('button');\n this.dom.innerHTML = html;\n this.id = attributes.id = attributes.id || Utils.generateID('button');\n this.cb = cb;\n Object.keys(attributes).forEach(function (propertyName) {\n _this.dom.setAttribute(propertyName, attributes[propertyName]);\n });\n Utils.addClass(this.dom, classes || 'noty_btn');\n\n return this;\n};\n\n/***/ }),\n/* 3 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nvar Push = exports.Push = function () {\n function Push() {\n var workerPath = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '/service-worker.js';\n\n _classCallCheck(this, Push);\n\n this.subData = {};\n this.workerPath = workerPath;\n this.listeners = {\n onPermissionGranted: [],\n onPermissionDenied: [],\n onSubscriptionSuccess: [],\n onSubscriptionCancel: [],\n onWorkerError: [],\n onWorkerSuccess: [],\n onWorkerNotSupported: []\n };\n return this;\n }\n\n /**\r\n * @param {string} eventName\r\n * @param {function} cb\r\n * @return {Push}\r\n */\n\n\n _createClass(Push, [{\n key: 'on',\n value: function on(eventName) {\n var cb = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : function () {};\n\n if (typeof cb === 'function' && this.listeners.hasOwnProperty(eventName)) {\n this.listeners[eventName].push(cb);\n }\n\n return this;\n }\n }, {\n key: 'fire',\n value: function fire(eventName) {\n var _this = this;\n\n var params = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];\n\n if (this.listeners.hasOwnProperty(eventName)) {\n this.listeners[eventName].forEach(function (cb) {\n if (typeof cb === 'function') {\n cb.apply(_this, params);\n }\n });\n }\n }\n }, {\n key: 'create',\n value: function create() {\n console.log('NOT IMPLEMENTED YET');\n }\n\n /**\r\n * @return {boolean}\r\n */\n\n }, {\n key: 'isSupported',\n value: function isSupported() {\n var result = false;\n\n try {\n result = window.Notification || window.webkitNotifications || navigator.mozNotification || window.external && window.external.msIsSiteMode() !== undefined;\n } catch (e) {}\n\n return result;\n }\n\n /**\r\n * @return {string}\r\n */\n\n }, {\n key: 'getPermissionStatus',\n value: function getPermissionStatus() {\n var perm = 'default';\n\n if (window.Notification && window.Notification.permissionLevel) {\n perm = window.Notification.permissionLevel;\n } else if (window.webkitNotifications && window.webkitNotifications.checkPermission) {\n switch (window.webkitNotifications.checkPermission()) {\n case 1:\n perm = 'default';\n break;\n case 0:\n perm = 'granted';\n break;\n default:\n perm = 'denied';\n }\n } else if (window.Notification && window.Notification.permission) {\n perm = window.Notification.permission;\n } else if (navigator.mozNotification) {\n perm = 'granted';\n } else if (window.external && window.external.msIsSiteMode() !== undefined) {\n perm = window.external.msIsSiteMode() ? 'granted' : 'default';\n }\n\n return perm.toString().toLowerCase();\n }\n\n /**\r\n * @return {string}\r\n */\n\n }, {\n key: 'getEndpoint',\n value: function getEndpoint(subscription) {\n var endpoint = subscription.endpoint;\n var subscriptionId = subscription.subscriptionId;\n\n // fix for Chrome < 45\n if (subscriptionId && endpoint.indexOf(subscriptionId) === -1) {\n endpoint += '/' + subscriptionId;\n }\n\n return endpoint;\n }\n\n /**\r\n * @return {boolean}\r\n */\n\n }, {\n key: 'isSWRegistered',\n value: function isSWRegistered() {\n try {\n return navigator.serviceWorker.controller.state === 'activated';\n } catch (e) {\n return false;\n }\n }\n\n /**\r\n * @return {void}\r\n */\n\n }, {\n key: 'unregisterWorker',\n value: function unregisterWorker() {\n var self = this;\n if ('serviceWorker' in navigator) {\n navigator.serviceWorker.getRegistrations().then(function (registrations) {\n var _iteratorNormalCompletion = true;\n var _didIteratorError = false;\n var _iteratorError = undefined;\n\n try {\n for (var _iterator = registrations[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {\n var registration = _step.value;\n\n registration.unregister();\n self.fire('onSubscriptionCancel');\n }\n } catch (err) {\n _didIteratorError = true;\n _iteratorError = err;\n } finally {\n try {\n if (!_iteratorNormalCompletion && _iterator.return) {\n _iterator.return();\n }\n } finally {\n if (_didIteratorError) {\n throw _iteratorError;\n }\n }\n }\n });\n }\n }\n\n /**\r\n * @return {void}\r\n */\n\n }, {\n key: 'requestSubscription',\n value: function requestSubscription() {\n var _this2 = this;\n\n var userVisibleOnly = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;\n\n var self = this;\n var current = this.getPermissionStatus();\n var cb = function cb(result) {\n if (result === 'granted') {\n _this2.fire('onPermissionGranted');\n\n if ('serviceWorker' in navigator) {\n navigator.serviceWorker.register(_this2.workerPath).then(function () {\n navigator.serviceWorker.ready.then(function (serviceWorkerRegistration) {\n self.fire('onWorkerSuccess');\n serviceWorkerRegistration.pushManager.subscribe({\n userVisibleOnly: userVisibleOnly\n }).then(function (subscription) {\n var key = subscription.getKey('p256dh');\n var token = subscription.getKey('auth');\n\n self.subData = {\n endpoint: self.getEndpoint(subscription),\n p256dh: key ? window.btoa(String.fromCharCode.apply(null, new Uint8Array(key))) : null,\n auth: token ? window.btoa(String.fromCharCode.apply(null, new Uint8Array(token))) : null\n };\n\n self.fire('onSubscriptionSuccess', [self.subData]);\n }).catch(function (err) {\n self.fire('onWorkerError', [err]);\n });\n });\n });\n } else {\n self.fire('onWorkerNotSupported');\n }\n } else if (result === 'denied') {\n _this2.fire('onPermissionDenied');\n _this2.unregisterWorker();\n }\n };\n\n if (current === 'default') {\n if (window.Notification && window.Notification.requestPermission) {\n window.Notification.requestPermission(cb);\n } else if (window.webkitNotifications && window.webkitNotifications.checkPermission) {\n window.webkitNotifications.requestPermission(cb);\n }\n } else {\n cb(current);\n }\n }\n }]);\n\n return Push;\n}();\n\n/***/ }),\n/* 4 */\n/***/ (function(module, exports, __webpack_require__) {\n\n/* WEBPACK VAR INJECTION */(function(process, global) {var require;/*!\n * @overview es6-promise - a tiny implementation of Promises/A+.\n * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)\n * @license Licensed under MIT license\n * See https://raw.githubusercontent.com/stefanpenner/es6-promise/master/LICENSE\n * @version 4.1.1\n */\n\n(function (global, factory) {\n\t true ? module.exports = factory() :\n\ttypeof define === 'function' && define.amd ? define(factory) :\n\t(global.ES6Promise = factory());\n}(this, (function () { 'use strict';\n\nfunction objectOrFunction(x) {\n var type = typeof x;\n return x !== null && (type === 'object' || type === 'function');\n}\n\nfunction isFunction(x) {\n return typeof x === 'function';\n}\n\nvar _isArray = undefined;\nif (Array.isArray) {\n _isArray = Array.isArray;\n} else {\n _isArray = function (x) {\n return Object.prototype.toString.call(x) === '[object Array]';\n };\n}\n\nvar isArray = _isArray;\n\nvar len = 0;\nvar vertxNext = undefined;\nvar customSchedulerFn = undefined;\n\nvar asap = function asap(callback, arg) {\n queue[len] = callback;\n queue[len + 1] = arg;\n len += 2;\n if (len === 2) {\n // If len is 2, that means that we need to schedule an async flush.\n // If additional callbacks are queued before the queue is flushed, they\n // will be processed by this flush that we are scheduling.\n if (customSchedulerFn) {\n customSchedulerFn(flush);\n } else {\n scheduleFlush();\n }\n }\n};\n\nfunction setScheduler(scheduleFn) {\n customSchedulerFn = scheduleFn;\n}\n\nfunction setAsap(asapFn) {\n asap = asapFn;\n}\n\nvar browserWindow = typeof window !== 'undefined' ? window : undefined;\nvar browserGlobal = browserWindow || {};\nvar BrowserMutationObserver = browserGlobal.MutationObserver || browserGlobal.WebKitMutationObserver;\nvar isNode = typeof self === 'undefined' && typeof process !== 'undefined' && ({}).toString.call(process) === '[object process]';\n\n// test for web worker but not in IE10\nvar isWorker = typeof Uint8ClampedArray !== 'undefined' && typeof importScripts !== 'undefined' && typeof MessageChannel !== 'undefined';\n\n// node\nfunction useNextTick() {\n // node version 0.10.x displays a deprecation warning when nextTick is used recursively\n // see https://github.com/cujojs/when/issues/410 for details\n return function () {\n return process.nextTick(flush);\n };\n}\n\n// vertx\nfunction useVertxTimer() {\n if (typeof vertxNext !== 'undefined') {\n return function () {\n vertxNext(flush);\n };\n }\n\n return useSetTimeout();\n}\n\nfunction useMutationObserver() {\n var iterations = 0;\n var observer = new BrowserMutationObserver(flush);\n var node = document.createTextNode('');\n observer.observe(node, { characterData: true });\n\n return function () {\n node.data = iterations = ++iterations % 2;\n };\n}\n\n// web worker\nfunction useMessageChannel() {\n var channel = new MessageChannel();\n channel.port1.onmessage = flush;\n return function () {\n return channel.port2.postMessage(0);\n };\n}\n\nfunction useSetTimeout() {\n // Store setTimeout reference so es6-promise will be unaffected by\n // other code modifying setTimeout (like sinon.useFakeTimers())\n var globalSetTimeout = setTimeout;\n return function () {\n return globalSetTimeout(flush, 1);\n };\n}\n\nvar queue = new Array(1000);\nfunction flush() {\n for (var i = 0; i < len; i += 2) {\n var callback = queue[i];\n var arg = queue[i + 1];\n\n callback(arg);\n\n queue[i] = undefined;\n queue[i + 1] = undefined;\n }\n\n len = 0;\n}\n\nfunction attemptVertx() {\n try {\n var r = require;\n var vertx = __webpack_require__(9);\n vertxNext = vertx.runOnLoop || vertx.runOnContext;\n return useVertxTimer();\n } catch (e) {\n return useSetTimeout();\n }\n}\n\nvar scheduleFlush = undefined;\n// Decide what async method to use to triggering processing of queued callbacks:\nif (isNode) {\n scheduleFlush = useNextTick();\n} else if (BrowserMutationObserver) {\n scheduleFlush = useMutationObserver();\n} else if (isWorker) {\n scheduleFlush = useMessageChannel();\n} else if (browserWindow === undefined && \"function\" === 'function') {\n scheduleFlush = attemptVertx();\n} else {\n scheduleFlush = useSetTimeout();\n}\n\nfunction then(onFulfillment, onRejection) {\n var _arguments = arguments;\n\n var parent = this;\n\n var child = new this.constructor(noop);\n\n if (child[PROMISE_ID] === undefined) {\n makePromise(child);\n }\n\n var _state = parent._state;\n\n if (_state) {\n (function () {\n var callback = _arguments[_state - 1];\n asap(function () {\n return invokeCallback(_state, child, callback, parent._result);\n });\n })();\n } else {\n subscribe(parent, child, onFulfillment, onRejection);\n }\n\n return child;\n}\n\n/**\n `Promise.resolve` returns a promise that will become resolved with the\n passed `value`. It is shorthand for the following:\n\n ```javascript\n let promise = new Promise(function(resolve, reject){\n resolve(1);\n });\n\n promise.then(function(value){\n // value === 1\n });\n ```\n\n Instead of writing the above, your code now simply becomes the following:\n\n ```javascript\n let promise = Promise.resolve(1);\n\n promise.then(function(value){\n // value === 1\n });\n ```\n\n @method resolve\n @static\n @param {Any} value value that the returned promise will be resolved with\n Useful for tooling.\n @return {Promise} a promise that will become fulfilled with the given\n `value`\n*/\nfunction resolve$1(object) {\n /*jshint validthis:true */\n var Constructor = this;\n\n if (object && typeof object === 'object' && object.constructor === Constructor) {\n return object;\n }\n\n var promise = new Constructor(noop);\n resolve(promise, object);\n return promise;\n}\n\nvar PROMISE_ID = Math.random().toString(36).substring(16);\n\nfunction noop() {}\n\nvar PENDING = void 0;\nvar FULFILLED = 1;\nvar REJECTED = 2;\n\nvar GET_THEN_ERROR = new ErrorObject();\n\nfunction selfFulfillment() {\n return new TypeError(\"You cannot resolve a promise with itself\");\n}\n\nfunction cannotReturnOwn() {\n return new TypeError('A promises callback cannot return that same promise.');\n}\n\nfunction getThen(promise) {\n try {\n return promise.then;\n } catch (error) {\n GET_THEN_ERROR.error = error;\n return GET_THEN_ERROR;\n }\n}\n\nfunction tryThen(then$$1, value, fulfillmentHandler, rejectionHandler) {\n try {\n then$$1.call(value, fulfillmentHandler, rejectionHandler);\n } catch (e) {\n return e;\n }\n}\n\nfunction handleForeignThenable(promise, thenable, then$$1) {\n asap(function (promise) {\n var sealed = false;\n var error = tryThen(then$$1, thenable, function (value) {\n if (sealed) {\n return;\n }\n sealed = true;\n if (thenable !== value) {\n resolve(promise, value);\n } else {\n fulfill(promise, value);\n }\n }, function (reason) {\n if (sealed) {\n return;\n }\n sealed = true;\n\n reject(promise, reason);\n }, 'Settle: ' + (promise._label || ' unknown promise'));\n\n if (!sealed && error) {\n sealed = true;\n reject(promise, error);\n }\n }, promise);\n}\n\nfunction handleOwnThenable(promise, thenable) {\n if (thenable._state === FULFILLED) {\n fulfill(promise, thenable._result);\n } else if (thenable._state === REJECTED) {\n reject(promise, thenable._result);\n } else {\n subscribe(thenable, undefined, function (value) {\n return resolve(promise, value);\n }, function (reason) {\n return reject(promise, reason);\n });\n }\n}\n\nfunction handleMaybeThenable(promise, maybeThenable, then$$1) {\n if (maybeThenable.constructor === promise.constructor && then$$1 === then && maybeThenable.constructor.resolve === resolve$1) {\n handleOwnThenable(promise, maybeThenable);\n } else {\n if (then$$1 === GET_THEN_ERROR) {\n reject(promise, GET_THEN_ERROR.error);\n GET_THEN_ERROR.error = null;\n } else if (then$$1 === undefined) {\n fulfill(promise, maybeThenable);\n } else if (isFunction(then$$1)) {\n handleForeignThenable(promise, maybeThenable, then$$1);\n } else {\n fulfill(promise, maybeThenable);\n }\n }\n}\n\nfunction resolve(promise, value) {\n if (promise === value) {\n reject(promise, selfFulfillment());\n } else if (objectOrFunction(value)) {\n handleMaybeThenable(promise, value, getThen(value));\n } else {\n fulfill(promise, value);\n }\n}\n\nfunction publishRejection(promise) {\n if (promise._onerror) {\n promise._onerror(promise._result);\n }\n\n publish(promise);\n}\n\nfunction fulfill(promise, value) {\n if (promise._state !== PENDING) {\n return;\n }\n\n promise._result = value;\n promise._state = FULFILLED;\n\n if (promise._subscribers.length !== 0) {\n asap(publish, promise);\n }\n}\n\nfunction reject(promise, reason) {\n if (promise._state !== PENDING) {\n return;\n }\n promise._state = REJECTED;\n promise._result = reason;\n\n asap(publishRejection, promise);\n}\n\nfunction subscribe(parent, child, onFulfillment, onRejection) {\n var _subscribers = parent._subscribers;\n var length = _subscribers.length;\n\n parent._onerror = null;\n\n _subscribers[length] = child;\n _subscribers[length + FULFILLED] = onFulfillment;\n _subscribers[length + REJECTED] = onRejection;\n\n if (length === 0 && parent._state) {\n asap(publish, parent);\n }\n}\n\nfunction publish(promise) {\n var subscribers = promise._subscribers;\n var settled = promise._state;\n\n if (subscribers.length === 0) {\n return;\n }\n\n var child = undefined,\n callback = undefined,\n detail = promise._result;\n\n for (var i = 0; i < subscribers.length; i += 3) {\n child = subscribers[i];\n callback = subscribers[i + settled];\n\n if (child) {\n invokeCallback(settled, child, callback, detail);\n } else {\n callback(detail);\n }\n }\n\n promise._subscribers.length = 0;\n}\n\nfunction ErrorObject() {\n this.error = null;\n}\n\nvar TRY_CATCH_ERROR = new ErrorObject();\n\nfunction tryCatch(callback, detail) {\n try {\n return callback(detail);\n } catch (e) {\n TRY_CATCH_ERROR.error = e;\n return TRY_CATCH_ERROR;\n }\n}\n\nfunction invokeCallback(settled, promise, callback, detail) {\n var hasCallback = isFunction(callback),\n value = undefined,\n error = undefined,\n succeeded = undefined,\n failed = undefined;\n\n if (hasCallback) {\n value = tryCatch(callback, detail);\n\n if (value === TRY_CATCH_ERROR) {\n failed = true;\n error = value.error;\n value.error = null;\n } else {\n succeeded = true;\n }\n\n if (promise === value) {\n reject(promise, cannotReturnOwn());\n return;\n }\n } else {\n value = detail;\n succeeded = true;\n }\n\n if (promise._state !== PENDING) {\n // noop\n } else if (hasCallback && succeeded) {\n resolve(promise, value);\n } else if (failed) {\n reject(promise, error);\n } else if (settled === FULFILLED) {\n fulfill(promise, value);\n } else if (settled === REJECTED) {\n reject(promise, value);\n }\n}\n\nfunction initializePromise(promise, resolver) {\n try {\n resolver(function resolvePromise(value) {\n resolve(promise, value);\n }, function rejectPromise(reason) {\n reject(promise, reason);\n });\n } catch (e) {\n reject(promise, e);\n }\n}\n\nvar id = 0;\nfunction nextId() {\n return id++;\n}\n\nfunction makePromise(promise) {\n promise[PROMISE_ID] = id++;\n promise._state = undefined;\n promise._result = undefined;\n promise._subscribers = [];\n}\n\nfunction Enumerator$1(Constructor, input) {\n this._instanceConstructor = Constructor;\n this.promise = new Constructor(noop);\n\n if (!this.promise[PROMISE_ID]) {\n makePromise(this.promise);\n }\n\n if (isArray(input)) {\n this.length = input.length;\n this._remaining = input.length;\n\n this._result = new Array(this.length);\n\n if (this.length === 0) {\n fulfill(this.promise, this._result);\n } else {\n this.length = this.length || 0;\n this._enumerate(input);\n if (this._remaining === 0) {\n fulfill(this.promise, this._result);\n }\n }\n } else {\n reject(this.promise, validationError());\n }\n}\n\nfunction validationError() {\n return new Error('Array Methods must be provided an Array');\n}\n\nEnumerator$1.prototype._enumerate = function (input) {\n for (var i = 0; this._state === PENDING && i < input.length; i++) {\n this._eachEntry(input[i], i);\n }\n};\n\nEnumerator$1.prototype._eachEntry = function (entry, i) {\n var c = this._instanceConstructor;\n var resolve$$1 = c.resolve;\n\n if (resolve$$1 === resolve$1) {\n var _then = getThen(entry);\n\n if (_then === then && entry._state !== PENDING) {\n this._settledAt(entry._state, i, entry._result);\n } else if (typeof _then !== 'function') {\n this._remaining--;\n this._result[i] = entry;\n } else if (c === Promise$2) {\n var promise = new c(noop);\n handleMaybeThenable(promise, entry, _then);\n this._willSettleAt(promise, i);\n } else {\n this._willSettleAt(new c(function (resolve$$1) {\n return resolve$$1(entry);\n }), i);\n }\n } else {\n this._willSettleAt(resolve$$1(entry), i);\n }\n};\n\nEnumerator$1.prototype._settledAt = function (state, i, value) {\n var promise = this.promise;\n\n if (promise._state === PENDING) {\n this._remaining--;\n\n if (state === REJECTED) {\n reject(promise, value);\n } else {\n this._result[i] = value;\n }\n }\n\n if (this._remaining === 0) {\n fulfill(promise, this._result);\n }\n};\n\nEnumerator$1.prototype._willSettleAt = function (promise, i) {\n var enumerator = this;\n\n subscribe(promise, undefined, function (value) {\n return enumerator._settledAt(FULFILLED, i, value);\n }, function (reason) {\n return enumerator._settledAt(REJECTED, i, reason);\n });\n};\n\n/**\n `Promise.all` accepts an array of promises, and returns a new promise which\n is fulfilled with an array of fulfillment values for the passed promises, or\n rejected with the reason of the first passed promise to be rejected. It casts all\n elements of the passed iterable to promises as it runs this algorithm.\n\n Example:\n\n ```javascript\n let promise1 = resolve(1);\n let promise2 = resolve(2);\n let promise3 = resolve(3);\n let promises = [ promise1, promise2, promise3 ];\n\n Promise.all(promises).then(function(array){\n // The array here would be [ 1, 2, 3 ];\n });\n ```\n\n If any of the `promises` given to `all` are rejected, the first promise\n that is rejected will be given as an argument to the returned promises's\n rejection handler. For example:\n\n Example:\n\n ```javascript\n let promise1 = resolve(1);\n let promise2 = reject(new Error(\"2\"));\n let promise3 = reject(new Error(\"3\"));\n let promises = [ promise1, promise2, promise3 ];\n\n Promise.all(promises).then(function(array){\n // Code here never runs because there are rejected promises!\n }, function(error) {\n // error.message === \"2\"\n });\n ```\n\n @method all\n @static\n @param {Array} entries array of promises\n @param {String} label optional string for labeling the promise.\n Useful for tooling.\n @return {Promise} promise that is fulfilled when all `promises` have been\n fulfilled, or rejected if any of them become rejected.\n @static\n*/\nfunction all$1(entries) {\n return new Enumerator$1(this, entries).promise;\n}\n\n/**\n `Promise.race` returns a new promise which is settled in the same way as the\n first passed promise to settle.\n\n Example:\n\n ```javascript\n let promise1 = new Promise(function(resolve, reject){\n setTimeout(function(){\n resolve('promise 1');\n }, 200);\n });\n\n let promise2 = new Promise(function(resolve, reject){\n setTimeout(function(){\n resolve('promise 2');\n }, 100);\n });\n\n Promise.race([promise1, promise2]).then(function(result){\n // result === 'promise 2' because it was resolved before promise1\n // was resolved.\n });\n ```\n\n `Promise.race` is deterministic in that only the state of the first\n settled promise matters. For example, even if other promises given to the\n `promises` array argument are resolved, but the first settled promise has\n become rejected before the other promises became fulfilled, the returned\n promise will become rejected:\n\n ```javascript\n let promise1 = new Promise(function(resolve, reject){\n setTimeout(function(){\n resolve('promise 1');\n }, 200);\n });\n\n let promise2 = new Promise(function(resolve, reject){\n setTimeout(function(){\n reject(new Error('promise 2'));\n }, 100);\n });\n\n Promise.race([promise1, promise2]).then(function(result){\n // Code here never runs\n }, function(reason){\n // reason.message === 'promise 2' because promise 2 became rejected before\n // promise 1 became fulfilled\n });\n ```\n\n An example real-world use case is implementing timeouts:\n\n ```javascript\n Promise.race([ajax('foo.json'), timeout(5000)])\n ```\n\n @method race\n @static\n @param {Array} promises array of promises to observe\n Useful for tooling.\n @return {Promise} a promise which settles in the same way as the first passed\n promise to settle.\n*/\nfunction race$1(entries) {\n /*jshint validthis:true */\n var Constructor = this;\n\n if (!isArray(entries)) {\n return new Constructor(function (_, reject) {\n return reject(new TypeError('You must pass an array to race.'));\n });\n } else {\n return new Constructor(function (resolve, reject) {\n var length = entries.length;\n for (var i = 0; i < length; i++) {\n Constructor.resolve(entries[i]).then(resolve, reject);\n }\n });\n }\n}\n\n/**\n `Promise.reject` returns a promise rejected with the passed `reason`.\n It is shorthand for the following:\n\n ```javascript\n let promise = new Promise(function(resolve, reject){\n reject(new Error('WHOOPS'));\n });\n\n promise.then(function(value){\n // Code here doesn't run because the promise is rejected!\n }, function(reason){\n // reason.message === 'WHOOPS'\n });\n ```\n\n Instead of writing the above, your code now simply becomes the following:\n\n ```javascript\n let promise = Promise.reject(new Error('WHOOPS'));\n\n promise.then(function(value){\n // Code here doesn't run because the promise is rejected!\n }, function(reason){\n // reason.message === 'WHOOPS'\n });\n ```\n\n @method reject\n @static\n @param {Any} reason value that the returned promise will be rejected with.\n Useful for tooling.\n @return {Promise} a promise rejected with the given `reason`.\n*/\nfunction reject$1(reason) {\n /*jshint validthis:true */\n var Constructor = this;\n var promise = new Constructor(noop);\n reject(promise, reason);\n return promise;\n}\n\nfunction needsResolver() {\n throw new TypeError('You must pass a resolver function as the first argument to the promise constructor');\n}\n\nfunction needsNew() {\n throw new TypeError(\"Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.\");\n}\n\n/**\n Promise objects represent the eventual result of an asynchronous operation. The\n primary way of interacting with a promise is through its `then` method, which\n registers callbacks to receive either a promise's eventual value or the reason\n why the promise cannot be fulfilled.\n\n Terminology\n -----------\n\n - `promise` is an object or function with a `then` method whose behavior conforms to this specification.\n - `thenable` is an object or function that defines a `then` method.\n - `value` is any legal JavaScript value (including undefined, a thenable, or a promise).\n - `exception` is a value that is thrown using the throw statement.\n - `reason` is a value that indicates why a promise was rejected.\n - `settled` the final resting state of a promise, fulfilled or rejected.\n\n A promise can be in one of three states: pending, fulfilled, or rejected.\n\n Promises that are fulfilled have a fulfillment value and are in the fulfilled\n state. Promises that are rejected have a rejection reason and are in the\n rejected state. A fulfillment value is never a thenable.\n\n Promises can also be said to *resolve* a value. If this value is also a\n promise, then the original promise's settled state will match the value's\n settled state. So a promise that *resolves* a promise that rejects will\n itself reject, and a promise that *resolves* a promise that fulfills will\n itself fulfill.\n\n\n Basic Usage:\n ------------\n\n ```js\n let promise = new Promise(function(resolve, reject) {\n // on success\n resolve(value);\n\n // on failure\n reject(reason);\n });\n\n promise.then(function(value) {\n // on fulfillment\n }, function(reason) {\n // on rejection\n });\n ```\n\n Advanced Usage:\n ---------------\n\n Promises shine when abstracting away asynchronous interactions such as\n `XMLHttpRequest`s.\n\n ```js\n function getJSON(url) {\n return new Promise(function(resolve, reject){\n let xhr = new XMLHttpRequest();\n\n xhr.open('GET', url);\n xhr.onreadystatechange = handler;\n xhr.responseType = 'json';\n xhr.setRequestHeader('Accept', 'application/json');\n xhr.send();\n\n function handler() {\n if (this.readyState === this.DONE) {\n if (this.status === 200) {\n resolve(this.response);\n } else {\n reject(new Error('getJSON: `' + url + '` failed with status: [' + this.status + ']'));\n }\n }\n };\n });\n }\n\n getJSON('/posts.json').then(function(json) {\n // on fulfillment\n }, function(reason) {\n // on rejection\n });\n ```\n\n Unlike callbacks, promises are great composable primitives.\n\n ```js\n Promise.all([\n getJSON('/posts'),\n getJSON('/comments')\n ]).then(function(values){\n values[0] // => postsJSON\n values[1] // => commentsJSON\n\n return values;\n });\n ```\n\n @class Promise\n @param {function} resolver\n Useful for tooling.\n @constructor\n*/\nfunction Promise$2(resolver) {\n this[PROMISE_ID] = nextId();\n this._result = this._state = undefined;\n this._subscribers = [];\n\n if (noop !== resolver) {\n typeof resolver !== 'function' && needsResolver();\n this instanceof Promise$2 ? initializePromise(this, resolver) : needsNew();\n }\n}\n\nPromise$2.all = all$1;\nPromise$2.race = race$1;\nPromise$2.resolve = resolve$1;\nPromise$2.reject = reject$1;\nPromise$2._setScheduler = setScheduler;\nPromise$2._setAsap = setAsap;\nPromise$2._asap = asap;\n\nPromise$2.prototype = {\n constructor: Promise$2,\n\n /**\n The primary way of interacting with a promise is through its `then` method,\n which registers callbacks to receive either a promise's eventual value or the\n reason why the promise cannot be fulfilled.\n \n ```js\n findUser().then(function(user){\n // user is available\n }, function(reason){\n // user is unavailable, and you are given the reason why\n });\n ```\n \n Chaining\n --------\n \n The return value of `then` is itself a promise. This second, 'downstream'\n promise is resolved with the return value of the first promise's fulfillment\n or rejection handler, or rejected if the handler throws an exception.\n \n ```js\n findUser().then(function (user) {\n return user.name;\n }, function (reason) {\n return 'default name';\n }).then(function (userName) {\n // If `findUser` fulfilled, `userName` will be the user's name, otherwise it\n // will be `'default name'`\n });\n \n findUser().then(function (user) {\n throw new Error('Found user, but still unhappy');\n }, function (reason) {\n throw new Error('`findUser` rejected and we're unhappy');\n }).then(function (value) {\n // never reached\n }, function (reason) {\n // if `findUser` fulfilled, `reason` will be 'Found user, but still unhappy'.\n // If `findUser` rejected, `reason` will be '`findUser` rejected and we're unhappy'.\n });\n ```\n If the downstream promise does not specify a rejection handler, rejection reasons will be propagated further downstream.\n \n ```js\n findUser().then(function (user) {\n throw new PedagogicalException('Upstream error');\n }).then(function (value) {\n // never reached\n }).then(function (value) {\n // never reached\n }, function (reason) {\n // The `PedgagocialException` is propagated all the way down to here\n });\n ```\n \n Assimilation\n ------------\n \n Sometimes the value you want to propagate to a downstream promise can only be\n retrieved asynchronously. This can be achieved by returning a promise in the\n fulfillment or rejection handler. The downstream promise will then be pending\n until the returned promise is settled. This is called *assimilation*.\n \n ```js\n findUser().then(function (user) {\n return findCommentsByAuthor(user);\n }).then(function (comments) {\n // The user's comments are now available\n });\n ```\n \n If the assimliated promise rejects, then the downstream promise will also reject.\n \n ```js\n findUser().then(function (user) {\n return findCommentsByAuthor(user);\n }).then(function (comments) {\n // If `findCommentsByAuthor` fulfills, we'll have the value here\n }, function (reason) {\n // If `findCommentsByAuthor` rejects, we'll have the reason here\n });\n ```\n \n Simple Example\n --------------\n \n Synchronous Example\n \n ```javascript\n let result;\n \n try {\n result = findResult();\n // success\n } catch(reason) {\n // failure\n }\n ```\n \n Errback Example\n \n ```js\n findResult(function(result, err){\n if (err) {\n // failure\n } else {\n // success\n }\n });\n ```\n \n Promise Example;\n \n ```javascript\n findResult().then(function(result){\n // success\n }, function(reason){\n // failure\n });\n ```\n \n Advanced Example\n --------------\n \n Synchronous Example\n \n ```javascript\n let author, books;\n \n try {\n author = findAuthor();\n books = findBooksByAuthor(author);\n // success\n } catch(reason) {\n // failure\n }\n ```\n \n Errback Example\n \n ```js\n \n function foundBooks(books) {\n \n }\n \n function failure(reason) {\n \n }\n \n findAuthor(function(author, err){\n if (err) {\n failure(err);\n // failure\n } else {\n try {\n findBoooksByAuthor(author, function(books, err) {\n if (err) {\n failure(err);\n } else {\n try {\n foundBooks(books);\n } catch(reason) {\n failure(reason);\n }\n }\n });\n } catch(error) {\n failure(err);\n }\n // success\n }\n });\n ```\n \n Promise Example;\n \n ```javascript\n findAuthor().\n then(findBooksByAuthor).\n then(function(books){\n // found books\n }).catch(function(reason){\n // something went wrong\n });\n ```\n \n @method then\n @param {Function} onFulfilled\n @param {Function} onRejected\n Useful for tooling.\n @return {Promise}\n */\n then: then,\n\n /**\n `catch` is simply sugar for `then(undefined, onRejection)` which makes it the same\n as the catch block of a try/catch statement.\n \n ```js\n function findAuthor(){\n throw new Error('couldn't find that author');\n }\n \n // synchronous\n try {\n findAuthor();\n } catch(reason) {\n // something went wrong\n }\n \n // async with promises\n findAuthor().catch(function(reason){\n // something went wrong\n });\n ```\n \n @method catch\n @param {Function} onRejection\n Useful for tooling.\n @return {Promise}\n */\n 'catch': function _catch(onRejection) {\n return this.then(null, onRejection);\n }\n};\n\n/*global self*/\nfunction polyfill$1() {\n var local = undefined;\n\n if (typeof global !== 'undefined') {\n local = global;\n } else if (typeof self !== 'undefined') {\n local = self;\n } else {\n try {\n local = Function('return this')();\n } catch (e) {\n throw new Error('polyfill failed because global object is unavailable in this environment');\n }\n }\n\n var P = local.Promise;\n\n if (P) {\n var promiseToString = null;\n try {\n promiseToString = Object.prototype.toString.call(P.resolve());\n } catch (e) {\n // silently ignored\n }\n\n if (promiseToString === '[object Promise]' && !P.cast) {\n return;\n }\n }\n\n local.Promise = Promise$2;\n}\n\n// Strange compat..\nPromise$2.polyfill = polyfill$1;\nPromise$2.Promise = Promise$2;\n\nreturn Promise$2;\n\n})));\n\n//# sourceMappingURL=es6-promise.map\n\n/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7), __webpack_require__(8)))\n\n/***/ }),\n/* 5 */\n/***/ (function(module, exports) {\n\n// removed by extract-text-webpack-plugin\n\n/***/ }),\n/* 6 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); /* global VERSION */\n\n__webpack_require__(5);\n\nvar _es6Promise = __webpack_require__(4);\n\nvar _es6Promise2 = _interopRequireDefault(_es6Promise);\n\nvar _utils = __webpack_require__(0);\n\nvar Utils = _interopRequireWildcard(_utils);\n\nvar _api = __webpack_require__(1);\n\nvar API = _interopRequireWildcard(_api);\n\nvar _button = __webpack_require__(2);\n\nvar _push = __webpack_require__(3);\n\nfunction _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nvar Noty = function () {\n /**\n * @param {object} options\n * @return {Noty}\n */\n function Noty() {\n var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n\n _classCallCheck(this, Noty);\n\n this.options = Utils.deepExtend({}, API.Defaults, options);\n\n if (API.Store[this.options.id]) {\n return API.Store[this.options.id];\n }\n\n this.id = this.options.id || Utils.generateID('bar');\n this.closeTimer = -1;\n this.barDom = null;\n this.layoutDom = null;\n this.progressDom = null;\n this.showing = false;\n this.shown = false;\n this.closed = false;\n this.closing = false;\n this.killable = this.options.timeout || this.options.closeWith.length > 0;\n this.hasSound = this.options.sounds.sources.length > 0;\n this.soundPlayed = false;\n this.listeners = {\n beforeShow: [],\n onShow: [],\n afterShow: [],\n onClose: [],\n afterClose: [],\n onClick: [],\n onHover: [],\n onTemplate: []\n };\n this.promises = {\n show: null,\n close: null\n };\n this.on('beforeShow', this.options.callbacks.beforeShow);\n this.on('onShow', this.options.callbacks.onShow);\n this.on('afterShow', this.options.callbacks.afterShow);\n this.on('onClose', this.options.callbacks.onClose);\n this.on('afterClose', this.options.callbacks.afterClose);\n this.on('onClick', this.options.callbacks.onClick);\n this.on('onHover', this.options.callbacks.onHover);\n this.on('onTemplate', this.options.callbacks.onTemplate);\n\n return this;\n }\n\n /**\n * @param {string} eventName\n * @param {function} cb\n * @return {Noty}\n */\n\n\n _createClass(Noty, [{\n key: 'on',\n value: function on(eventName) {\n var cb = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : function () {};\n\n if (typeof cb === 'function' && this.listeners.hasOwnProperty(eventName)) {\n this.listeners[eventName].push(cb);\n }\n\n return this;\n }\n\n /**\n * @return {Noty}\n */\n\n }, {\n key: 'show',\n value: function show() {\n var _this = this;\n\n if (this.showing || this.shown) {\n return this; // preventing multiple show\n }\n\n if (this.options.killer === true) {\n Noty.closeAll();\n } else if (typeof this.options.killer === 'string') {\n Noty.closeAll(this.options.killer);\n }\n\n var queueCounts = API.getQueueCounts(this.options.queue);\n\n if (queueCounts.current >= queueCounts.maxVisible || API.PageHidden && this.options.visibilityControl) {\n API.addToQueue(this);\n\n if (API.PageHidden && this.hasSound && Utils.inArray('docHidden', this.options.sounds.conditions)) {\n Utils.createAudioElements(this);\n }\n\n if (API.PageHidden && Utils.inArray('docHidden', this.options.titleCount.conditions)) {\n API.docTitle.increment();\n }\n\n return this;\n }\n\n API.Store[this.id] = this;\n\n API.fire(this, 'beforeShow');\n\n this.showing = true;\n\n if (this.closing) {\n this.showing = false;\n return this;\n }\n\n API.build(this);\n API.handleModal(this);\n\n if (this.options.force) {\n this.layoutDom.insertBefore(this.barDom, this.layoutDom.firstChild);\n } else {\n this.layoutDom.appendChild(this.barDom);\n }\n\n if (this.hasSound && !this.soundPlayed && Utils.inArray('docVisible', this.options.sounds.conditions)) {\n Utils.createAudioElements(this);\n }\n\n if (Utils.inArray('docVisible', this.options.titleCount.conditions)) {\n API.docTitle.increment();\n }\n\n this.shown = true;\n this.closed = false;\n\n // bind button events if any\n if (API.hasButtons(this)) {\n Object.keys(this.options.buttons).forEach(function (key) {\n var btn = _this.barDom.querySelector('#' + _this.options.buttons[key].id);\n Utils.addListener(btn, 'click', function (e) {\n Utils.stopPropagation(e);\n _this.options.buttons[key].cb(_this);\n });\n });\n }\n\n this.progressDom = this.barDom.querySelector('.noty_progressbar');\n\n if (Utils.inArray('click', this.options.closeWith)) {\n Utils.addClass(this.barDom, 'noty_close_with_click');\n Utils.addListener(this.barDom, 'click', function (e) {\n Utils.stopPropagation(e);\n API.fire(_this, 'onClick');\n _this.close();\n }, false);\n }\n\n Utils.addListener(this.barDom, 'mouseenter', function () {\n API.fire(_this, 'onHover');\n }, false);\n\n if (this.options.timeout) Utils.addClass(this.barDom, 'noty_has_timeout');\n if (this.options.progressBar) {\n Utils.addClass(this.barDom, 'noty_has_progressbar');\n }\n\n if (Utils.inArray('button', this.options.closeWith)) {\n Utils.addClass(this.barDom, 'noty_close_with_button');\n\n var closeButton = document.createElement('div');\n Utils.addClass(closeButton, 'noty_close_button');\n closeButton.innerHTML = '×';\n this.barDom.appendChild(closeButton);\n\n Utils.addListener(closeButton, 'click', function (e) {\n Utils.stopPropagation(e);\n _this.close();\n }, false);\n }\n\n API.fire(this, 'onShow');\n\n if (this.options.animation.open === null) {\n this.promises.show = new _es6Promise2.default(function (resolve) {\n resolve();\n });\n } else if (typeof this.options.animation.open === 'function') {\n this.promises.show = new _es6Promise2.default(this.options.animation.open.bind(this));\n } else {\n Utils.addClass(this.barDom, this.options.animation.open);\n this.promises.show = new _es6Promise2.default(function (resolve) {\n Utils.addListener(_this.barDom, Utils.animationEndEvents, function () {\n Utils.removeClass(_this.barDom, _this.options.animation.open);\n resolve();\n });\n });\n }\n\n this.promises.show.then(function () {\n var _t = _this;\n setTimeout(function () {\n API.openFlow(_t);\n }, 100);\n });\n\n return this;\n }\n\n /**\n * @return {Noty}\n */\n\n }, {\n key: 'stop',\n value: function stop() {\n API.dequeueClose(this);\n return this;\n }\n\n /**\n * @return {Noty}\n */\n\n }, {\n key: 'resume',\n value: function resume() {\n API.queueClose(this);\n return this;\n }\n\n /**\n * @param {int|boolean} ms\n * @return {Noty}\n */\n\n }, {\n key: 'setTimeout',\n value: function (_setTimeout) {\n function setTimeout(_x) {\n return _setTimeout.apply(this, arguments);\n }\n\n setTimeout.toString = function () {\n return _setTimeout.toString();\n };\n\n return setTimeout;\n }(function (ms) {\n this.stop();\n this.options.timeout = ms;\n\n if (this.barDom) {\n if (this.options.timeout) {\n Utils.addClass(this.barDom, 'noty_has_timeout');\n } else {\n Utils.removeClass(this.barDom, 'noty_has_timeout');\n }\n\n var _t = this;\n setTimeout(function () {\n // ugly fix for progressbar display bug\n _t.resume();\n }, 100);\n }\n\n return this;\n })\n\n /**\n * @param {string} html\n * @param {boolean} optionsOverride\n * @return {Noty}\n */\n\n }, {\n key: 'setText',\n value: function setText(html) {\n var optionsOverride = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n\n if (this.barDom) {\n this.barDom.querySelector('.noty_body').innerHTML = html;\n }\n\n if (optionsOverride) this.options.text = html;\n\n return this;\n }\n\n /**\n * @param {string} type\n * @param {boolean} optionsOverride\n * @return {Noty}\n */\n\n }, {\n key: 'setType',\n value: function setType(type) {\n var _this2 = this;\n\n var optionsOverride = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n\n if (this.barDom) {\n var classList = Utils.classList(this.barDom).split(' ');\n\n classList.forEach(function (c) {\n if (c.substring(0, 11) === 'noty_type__') {\n Utils.removeClass(_this2.barDom, c);\n }\n });\n\n Utils.addClass(this.barDom, 'noty_type__' + type);\n }\n\n if (optionsOverride) this.options.type = type;\n\n return this;\n }\n\n /**\n * @param {string} theme\n * @param {boolean} optionsOverride\n * @return {Noty}\n */\n\n }, {\n key: 'setTheme',\n value: function setTheme(theme) {\n var _this3 = this;\n\n var optionsOverride = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n\n if (this.barDom) {\n var classList = Utils.classList(this.barDom).split(' ');\n\n classList.forEach(function (c) {\n if (c.substring(0, 12) === 'noty_theme__') {\n Utils.removeClass(_this3.barDom, c);\n }\n });\n\n Utils.addClass(this.barDom, 'noty_theme__' + theme);\n }\n\n if (optionsOverride) this.options.theme = theme;\n\n return this;\n }\n\n /**\n * @return {Noty}\n */\n\n }, {\n key: 'close',\n value: function close() {\n var _this4 = this;\n\n if (this.closed) return this;\n\n if (!this.shown) {\n // it's in the queue\n API.removeFromQueue(this);\n return this;\n }\n\n API.fire(this, 'onClose');\n\n this.closing = true;\n\n if (this.options.animation.close === null || this.options.animation.close === false) {\n this.promises.close = new _es6Promise2.default(function (resolve) {\n resolve();\n });\n } else if (typeof this.options.animation.close === 'function') {\n this.promises.close = new _es6Promise2.default(this.options.animation.close.bind(this));\n } else {\n Utils.addClass(this.barDom, this.options.animation.close);\n this.promises.close = new _es6Promise2.default(function (resolve) {\n Utils.addListener(_this4.barDom, Utils.animationEndEvents, function () {\n if (_this4.options.force) {\n Utils.remove(_this4.barDom);\n } else {\n API.ghostFix(_this4);\n }\n resolve();\n });\n });\n }\n\n this.promises.close.then(function () {\n API.closeFlow(_this4);\n API.handleModalClose(_this4);\n });\n\n this.closed = true;\n\n return this;\n }\n\n // API functions\n\n /**\n * @param {boolean|string} queueName\n * @return {Noty}\n */\n\n }], [{\n key: 'closeAll',\n value: function closeAll() {\n var queueName = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n\n Object.keys(API.Store).forEach(function (id) {\n if (queueName) {\n if (API.Store[id].options.queue === queueName && API.Store[id].killable) {\n API.Store[id].close();\n }\n } else if (API.Store[id].killable) {\n API.Store[id].close();\n }\n });\n return this;\n }\n\n /**\n * @param {string} queueName\n * @return {Noty}\n */\n\n }, {\n key: 'clearQueue',\n value: function clearQueue() {\n var queueName = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'global';\n\n if (API.Queues.hasOwnProperty(queueName)) {\n API.Queues[queueName].queue = [];\n }\n return this;\n }\n\n /**\n * @return {API.Queues}\n */\n\n }, {\n key: 'overrideDefaults',\n\n\n /**\n * @param {Object} obj\n * @return {Noty}\n */\n value: function overrideDefaults(obj) {\n API.Defaults = Utils.deepExtend({}, API.Defaults, obj);\n return this;\n }\n\n /**\n * @param {int} amount\n * @param {string} queueName\n * @return {Noty}\n */\n\n }, {\n key: 'setMaxVisible',\n value: function setMaxVisible() {\n var amount = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : API.DefaultMaxVisible;\n var queueName = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'global';\n\n if (!API.Queues.hasOwnProperty(queueName)) {\n API.Queues[queueName] = { maxVisible: amount, queue: [] };\n }\n\n API.Queues[queueName].maxVisible = amount;\n return this;\n }\n\n /**\n * @param {string} innerHtml\n * @param {String} classes\n * @param {Function} cb\n * @param {Object} attributes\n * @return {NotyButton}\n */\n\n }, {\n key: 'button',\n value: function button(innerHtml) {\n var classes = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;\n var cb = arguments[2];\n var attributes = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};\n\n return new _button.NotyButton(innerHtml, classes, cb, attributes);\n }\n\n /**\n * @return {string}\n */\n\n }, {\n key: 'version',\n value: function version() {\n return \"3.2.0-beta\";\n }\n\n /**\n * @param {String} workerPath\n * @return {Push}\n */\n\n }, {\n key: 'Push',\n value: function Push(workerPath) {\n return new _push.Push(workerPath);\n }\n }, {\n key: 'Queues',\n get: function get() {\n return API.Queues;\n }\n\n /**\n * @return {API.PageHidden}\n */\n\n }, {\n key: 'PageHidden',\n get: function get() {\n return API.PageHidden;\n }\n }]);\n\n return Noty;\n}();\n\n// Document visibility change controller\n\n\nexports.default = Noty;\nif (typeof window !== 'undefined') {\n Utils.visibilityChangeFlow();\n}\nmodule.exports = exports['default'];\n\n/***/ }),\n/* 7 */\n/***/ (function(module, exports) {\n\n// shim for using process in browser\nvar process = module.exports = {};\n\n// cached from whatever global is present so that test runners that stub it\n// don't break things. But we need to wrap it in a try catch in case it is\n// wrapped in strict mode code which doesn't define any globals. It's inside a\n// function because try/catches deoptimize in certain engines.\n\nvar cachedSetTimeout;\nvar cachedClearTimeout;\n\nfunction defaultSetTimout() {\n throw new Error('setTimeout has not been defined');\n}\nfunction defaultClearTimeout () {\n throw new Error('clearTimeout has not been defined');\n}\n(function () {\n try {\n if (typeof setTimeout === 'function') {\n cachedSetTimeout = setTimeout;\n } else {\n cachedSetTimeout = defaultSetTimout;\n }\n } catch (e) {\n cachedSetTimeout = defaultSetTimout;\n }\n try {\n if (typeof clearTimeout === 'function') {\n cachedClearTimeout = clearTimeout;\n } else {\n cachedClearTimeout = defaultClearTimeout;\n }\n } catch (e) {\n cachedClearTimeout = defaultClearTimeout;\n }\n} ())\nfunction runTimeout(fun) {\n if (cachedSetTimeout === setTimeout) {\n //normal enviroments in sane situations\n return setTimeout(fun, 0);\n }\n // if setTimeout wasn't available but was latter defined\n if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {\n cachedSetTimeout = setTimeout;\n return setTimeout(fun, 0);\n }\n try {\n // when when somebody has screwed with setTimeout but no I.E. maddness\n return cachedSetTimeout(fun, 0);\n } catch(e){\n try {\n // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally\n return cachedSetTimeout.call(null, fun, 0);\n } catch(e){\n // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error\n return cachedSetTimeout.call(this, fun, 0);\n }\n }\n\n\n}\nfunction runClearTimeout(marker) {\n if (cachedClearTimeout === clearTimeout) {\n //normal enviroments in sane situations\n return clearTimeout(marker);\n }\n // if clearTimeout wasn't available but was latter defined\n if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {\n cachedClearTimeout = clearTimeout;\n return clearTimeout(marker);\n }\n try {\n // when when somebody has screwed with setTimeout but no I.E. maddness\n return cachedClearTimeout(marker);\n } catch (e){\n try {\n // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally\n return cachedClearTimeout.call(null, marker);\n } catch (e){\n // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.\n // Some versions of I.E. have different rules for clearTimeout vs setTimeout\n return cachedClearTimeout.call(this, marker);\n }\n }\n\n\n\n}\nvar queue = [];\nvar draining = false;\nvar currentQueue;\nvar queueIndex = -1;\n\nfunction cleanUpNextTick() {\n if (!draining || !currentQueue) {\n return;\n }\n draining = false;\n if (currentQueue.length) {\n queue = currentQueue.concat(queue);\n } else {\n queueIndex = -1;\n }\n if (queue.length) {\n drainQueue();\n }\n}\n\nfunction drainQueue() {\n if (draining) {\n return;\n }\n var timeout = runTimeout(cleanUpNextTick);\n draining = true;\n\n var len = queue.length;\n while(len) {\n currentQueue = queue;\n queue = [];\n while (++queueIndex < len) {\n if (currentQueue) {\n currentQueue[queueIndex].run();\n }\n }\n queueIndex = -1;\n len = queue.length;\n }\n currentQueue = null;\n draining = false;\n runClearTimeout(timeout);\n}\n\nprocess.nextTick = function (fun) {\n var args = new Array(arguments.length - 1);\n if (arguments.length > 1) {\n for (var i = 1; i < arguments.length; i++) {\n args[i - 1] = arguments[i];\n }\n }\n queue.push(new Item(fun, args));\n if (queue.length === 1 && !draining) {\n runTimeout(drainQueue);\n }\n};\n\n// v8 likes predictible objects\nfunction Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}\nItem.prototype.run = function () {\n this.fun.apply(null, this.array);\n};\nprocess.title = 'browser';\nprocess.browser = true;\nprocess.env = {};\nprocess.argv = [];\nprocess.version = ''; // empty string to avoid regexp issues\nprocess.versions = {};\n\nfunction noop() {}\n\nprocess.on = noop;\nprocess.addListener = noop;\nprocess.once = noop;\nprocess.off = noop;\nprocess.removeListener = noop;\nprocess.removeAllListeners = noop;\nprocess.emit = noop;\nprocess.prependListener = noop;\nprocess.prependOnceListener = noop;\n\nprocess.listeners = function (name) { return [] }\n\nprocess.binding = function (name) {\n throw new Error('process.binding is not supported');\n};\n\nprocess.cwd = function () { return '/' };\nprocess.chdir = function (dir) {\n throw new Error('process.chdir is not supported');\n};\nprocess.umask = function() { return 0; };\n\n\n/***/ }),\n/* 8 */\n/***/ (function(module, exports) {\n\nvar g;\r\n\r\n// This works in non-strict mode\r\ng = (function() {\r\n\treturn this;\r\n})();\r\n\r\ntry {\r\n\t// This works if eval is allowed (see CSP)\r\n\tg = g || Function(\"return this\")() || (1,eval)(\"this\");\r\n} catch(e) {\r\n\t// This works if the window reference is available\r\n\tif(typeof window === \"object\")\r\n\t\tg = window;\r\n}\r\n\r\n// g can still be undefined, but nothing to do about it...\r\n// We return undefined, instead of nothing here, so it's\r\n// easier to handle this case. if(!global) { ...}\r\n\r\nmodule.exports = g;\r\n\n\n/***/ }),\n/* 9 */\n/***/ (function(module, exports) {\n\n/* (ignored) */\n\n/***/ })\n/******/ ]);\n});\n\n\n// WEBPACK FOOTER //\n// noty.min.js"," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// identity function for calling harmony imports with the correct context\n \t__webpack_require__.i = function(value) { return value; };\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 6);\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap d3b233870119224fe21e","import * as API from 'api'\r\n\r\nexport const animationEndEvents = 'webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend'\r\n\r\nexport function inArray (needle, haystack, argStrict) {\r\n let key\r\n let strict = !!argStrict\r\n\r\n if (strict) {\r\n for (key in haystack) {\r\n if (haystack.hasOwnProperty(key) && haystack[key] === needle) {\r\n return true\r\n }\r\n }\r\n } else {\r\n for (key in haystack) {\r\n if (haystack.hasOwnProperty(key) && haystack[key] === needle) {\r\n return true\r\n }\r\n }\r\n }\r\n return false\r\n}\r\n\r\nexport function stopPropagation (evt) {\r\n evt = evt || window.event\r\n\r\n if (typeof evt.stopPropagation !== 'undefined') {\r\n evt.stopPropagation()\r\n } else {\r\n evt.cancelBubble = true\r\n }\r\n}\r\n\r\nexport const deepExtend = function (out) {\r\n out = out || {}\r\n\r\n for (let i = 1; i < arguments.length; i++) {\r\n let obj = arguments[i]\r\n\r\n if (!obj) continue\r\n\r\n for (let key in obj) {\r\n if (obj.hasOwnProperty(key)) {\r\n if (Array.isArray(obj[key])) {\r\n out[key] = obj[key]\r\n } else if (typeof obj[key] === 'object' && obj[key] !== null) {\r\n out[key] = deepExtend(out[key], obj[key])\r\n } else {\r\n out[key] = obj[key]\r\n }\r\n }\r\n }\r\n }\r\n\r\n return out\r\n}\r\n\r\nexport function generateID (prefix = '') {\r\n let id = `noty_${prefix}_`\r\n\r\n id += 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {\r\n let r = Math.random() * 16 | 0\r\n let v = c === 'x' ? r : r & 0x3 | 0x8\r\n return v.toString(16)\r\n })\r\n\r\n return id\r\n}\r\n\r\nexport function outerHeight (el) {\r\n let height = el.offsetHeight\r\n let style = window.getComputedStyle(el)\r\n\r\n height += parseInt(style.marginTop) + parseInt(style.marginBottom)\r\n return height\r\n}\r\n\r\nexport let css = (function () {\r\n let cssPrefixes = ['Webkit', 'O', 'Moz', 'ms']\r\n let cssProps = {}\r\n\r\n function camelCase (string) {\r\n return string\r\n .replace(/^-ms-/, 'ms-')\r\n .replace(/-([\\da-z])/gi, function (match, letter) {\r\n return letter.toUpperCase()\r\n })\r\n }\r\n\r\n function getVendorProp (name) {\r\n let style = document.body.style\r\n if (name in style) return name\r\n\r\n let i = cssPrefixes.length\r\n let capName = name.charAt(0).toUpperCase() + name.slice(1)\r\n let vendorName\r\n\r\n while (i--) {\r\n vendorName = cssPrefixes[i] + capName\r\n if (vendorName in style) return vendorName\r\n }\r\n\r\n return name\r\n }\r\n\r\n function getStyleProp (name) {\r\n name = camelCase(name)\r\n return cssProps[name] || (cssProps[name] = getVendorProp(name))\r\n }\r\n\r\n function applyCss (element, prop, value) {\r\n prop = getStyleProp(prop)\r\n element.style[prop] = value\r\n }\r\n\r\n return function (element, properties) {\r\n let args = arguments\r\n let prop\r\n let value\r\n\r\n if (args.length === 2) {\r\n for (prop in properties) {\r\n if (properties.hasOwnProperty(prop)) {\r\n value = properties[prop]\r\n if (value !== undefined && properties.hasOwnProperty(prop)) {\r\n applyCss(element, prop, value)\r\n }\r\n }\r\n }\r\n } else {\r\n applyCss(element, args[1], args[2])\r\n }\r\n }\r\n})()\r\n\r\nexport function addListener (el, events, cb, useCapture = false) {\r\n events = events.split(' ')\r\n for (let i = 0; i < events.length; i++) {\r\n if (document.addEventListener) {\r\n el.addEventListener(events[i], cb, useCapture)\r\n } else if (document.attachEvent) {\r\n el.attachEvent('on' + events[i], cb)\r\n }\r\n }\r\n}\r\n\r\nexport function hasClass (element, name) {\r\n let list = typeof element === 'string' ? element : classList(element)\r\n return list.indexOf(' ' + name + ' ') >= 0\r\n}\r\n\r\nexport function addClass (element, name) {\r\n let oldList = classList(element)\r\n let newList = oldList + name\r\n\r\n if (hasClass(oldList, name)) return\r\n\r\n // Trim the opening space.\r\n element.className = newList.substring(1)\r\n}\r\n\r\nexport function removeClass (element, name) {\r\n let oldList = classList(element)\r\n let newList\r\n\r\n if (!hasClass(element, name)) return\r\n\r\n // Replace the class name.\r\n newList = oldList.replace(' ' + name + ' ', ' ')\r\n\r\n // Trim the opening and closing spaces.\r\n element.className = newList.substring(1, newList.length - 1)\r\n}\r\n\r\nexport function remove (element) {\r\n if (element.parentNode) {\r\n element.parentNode.removeChild(element)\r\n }\r\n}\r\n\r\nexport function classList (element) {\r\n return (' ' + ((element && element.className) || '') + ' ').replace(\r\n /\\s+/gi,\r\n ' '\r\n )\r\n}\r\n\r\nexport function visibilityChangeFlow () {\r\n let hidden\r\n let visibilityChange\r\n if (typeof document.hidden !== 'undefined') {\r\n // Opera 12.10 and Firefox 18 and later support\r\n hidden = 'hidden'\r\n visibilityChange = 'visibilitychange'\r\n } else if (typeof document.msHidden !== 'undefined') {\r\n hidden = 'msHidden'\r\n visibilityChange = 'msvisibilitychange'\r\n } else if (typeof document.webkitHidden !== 'undefined') {\r\n hidden = 'webkitHidden'\r\n visibilityChange = 'webkitvisibilitychange'\r\n }\r\n\r\n function onVisibilityChange () {\r\n API.PageHidden = document[hidden]\r\n handleVisibilityChange()\r\n }\r\n\r\n function onBlur () {\r\n API.PageHidden = true\r\n handleVisibilityChange()\r\n }\r\n\r\n function onFocus () {\r\n API.PageHidden = false\r\n handleVisibilityChange()\r\n }\r\n\r\n function handleVisibilityChange () {\r\n if (API.PageHidden) stopAll()\r\n else resumeAll()\r\n }\r\n\r\n function stopAll () {\r\n setTimeout(\r\n function () {\r\n Object.keys(API.Store).forEach(id => {\r\n if (API.Store.hasOwnProperty(id)) {\r\n if (API.Store[id].options.visibilityControl) {\r\n API.Store[id].stop()\r\n }\r\n }\r\n })\r\n },\r\n 100\r\n )\r\n }\r\n\r\n function resumeAll () {\r\n setTimeout(\r\n function () {\r\n Object.keys(API.Store).forEach(id => {\r\n if (API.Store.hasOwnProperty(id)) {\r\n if (API.Store[id].options.visibilityControl) {\r\n API.Store[id].resume()\r\n }\r\n }\r\n })\r\n API.queueRenderAll()\r\n },\r\n 100\r\n )\r\n }\r\n\r\n if (visibilityChange) {\r\n addListener(document, visibilityChange, onVisibilityChange)\r\n }\r\n\r\n addListener(window, 'blur', onBlur)\r\n addListener(window, 'focus', onFocus)\r\n}\r\n\r\nexport function createAudioElements (ref) {\r\n if (ref.hasSound) {\r\n const audioElement = document.createElement('audio')\r\n\r\n ref.options.sounds.sources.forEach(s => {\r\n const source = document.createElement('source')\r\n source.src = s\r\n source.type = `audio/${getExtension(s)}`\r\n audioElement.appendChild(source)\r\n })\r\n\r\n if (ref.barDom) {\r\n ref.barDom.appendChild(audioElement)\r\n } else {\r\n document.querySelector('body').appendChild(audioElement)\r\n }\r\n\r\n audioElement.volume = ref.options.sounds.volume\r\n\r\n if (!ref.soundPlayed) {\r\n audioElement.play()\r\n ref.soundPlayed = true\r\n }\r\n\r\n audioElement.onended = function () {\r\n remove(audioElement)\r\n }\r\n }\r\n}\r\n\r\nfunction getExtension (fileName) {\r\n return fileName.match(/\\.([^.]+)$/)[1]\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./src/utils.js","import * as Utils from 'utils'\r\n\r\nexport let PageHidden = false\r\nexport let DocModalCount = 0\r\n\r\nconst DocTitleProps = {\r\n originalTitle: null,\r\n count: 0,\r\n changed: false,\r\n timer: -1\r\n}\r\n\r\nexport const docTitle = {\r\n increment: () => {\r\n DocTitleProps.count++\r\n\r\n docTitle._update()\r\n },\r\n\r\n decrement: () => {\r\n DocTitleProps.count--\r\n\r\n if (DocTitleProps.count <= 0) {\r\n docTitle._clear()\r\n return\r\n }\r\n\r\n docTitle._update()\r\n },\r\n\r\n _update: () => {\r\n let title = document.title\r\n\r\n if (!DocTitleProps.changed) {\r\n DocTitleProps.originalTitle = title\r\n document.title = `(${DocTitleProps.count}) ${title}`\r\n DocTitleProps.changed = true\r\n } else {\r\n document.title = `(${DocTitleProps.count}) ${DocTitleProps.originalTitle}`\r\n }\r\n },\r\n\r\n _clear: () => {\r\n if (DocTitleProps.changed) {\r\n DocTitleProps.count = 0\r\n document.title = DocTitleProps.originalTitle\r\n DocTitleProps.changed = false\r\n }\r\n }\r\n}\r\n\r\nexport const DefaultMaxVisible = 5\r\n\r\nexport const Queues = {\r\n global: {\r\n maxVisible: DefaultMaxVisible,\r\n queue: []\r\n }\r\n}\r\n\r\nexport const Store = {}\r\n\r\nexport let Defaults = {\r\n type: 'alert',\r\n layout: 'topRight',\r\n theme: 'mint',\r\n text: '',\r\n timeout: false,\r\n progressBar: true,\r\n closeWith: ['click'],\r\n animation: {\r\n open: 'noty_effects_open',\r\n close: 'noty_effects_close'\r\n },\r\n id: false,\r\n force: false,\r\n killer: false,\r\n queue: 'global',\r\n container: false,\r\n buttons: [],\r\n callbacks: {\r\n beforeShow: null,\r\n onShow: null,\r\n afterShow: null,\r\n onClose: null,\r\n afterClose: null,\r\n onClick: null,\r\n onHover: null,\r\n onTemplate: null\r\n },\r\n sounds: {\r\n sources: [],\r\n volume: 1,\r\n conditions: []\r\n },\r\n titleCount: {\r\n conditions: []\r\n },\r\n modal: false,\r\n visibilityControl: false\r\n}\r\n\r\n/**\r\n * @param {string} queueName\r\n * @return {object}\r\n */\r\nexport function getQueueCounts (queueName = 'global') {\r\n let count = 0\r\n let max = DefaultMaxVisible\r\n\r\n if (Queues.hasOwnProperty(queueName)) {\r\n max = Queues[queueName].maxVisible\r\n Object.keys(Store).forEach(i => {\r\n if (Store[i].options.queue === queueName && !Store[i].closed) count++\r\n })\r\n }\r\n\r\n return {\r\n current: count,\r\n maxVisible: max\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function addToQueue (ref) {\r\n if (!Queues.hasOwnProperty(ref.options.queue)) {\r\n Queues[ref.options.queue] = {maxVisible: DefaultMaxVisible, queue: []}\r\n }\r\n\r\n Queues[ref.options.queue].queue.push(ref)\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function removeFromQueue (ref) {\r\n if (Queues.hasOwnProperty(ref.options.queue)) {\r\n const queue = []\r\n Object.keys(Queues[ref.options.queue].queue).forEach(i => {\r\n if (Queues[ref.options.queue].queue[i].id !== ref.id) {\r\n queue.push(Queues[ref.options.queue].queue[i])\r\n }\r\n })\r\n Queues[ref.options.queue].queue = queue\r\n }\r\n}\r\n\r\n/**\r\n * @param {string} queueName\r\n * @return {void}\r\n */\r\nexport function queueRender (queueName = 'global') {\r\n if (Queues.hasOwnProperty(queueName)) {\r\n const noty = Queues[queueName].queue.shift()\r\n\r\n if (noty) noty.show()\r\n }\r\n}\r\n\r\n/**\r\n * @return {void}\r\n */\r\nexport function queueRenderAll () {\r\n Object.keys(Queues).forEach(queueName => {\r\n queueRender(queueName)\r\n })\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function ghostFix (ref) {\r\n const ghostID = Utils.generateID('ghost')\r\n let ghost = document.createElement('div')\r\n ghost.setAttribute('id', ghostID)\r\n Utils.css(ghost, {\r\n height: Utils.outerHeight(ref.barDom) + 'px'\r\n })\r\n\r\n ref.barDom.insertAdjacentHTML('afterend', ghost.outerHTML)\r\n\r\n Utils.remove(ref.barDom)\r\n ghost = document.getElementById(ghostID)\r\n Utils.addClass(ghost, 'noty_fix_effects_height')\r\n Utils.addListener(ghost, Utils.animationEndEvents, () => {\r\n Utils.remove(ghost)\r\n })\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function build (ref) {\r\n findOrCreateContainer(ref)\r\n\r\n const markup = `
${ref.options.text}
${buildButtons(ref)}`\r\n\r\n ref.barDom = document.createElement('div')\r\n ref.barDom.setAttribute('id', ref.id)\r\n Utils.addClass(\r\n ref.barDom,\r\n `noty_bar noty_type__${ref.options.type} noty_theme__${ref.options.theme}`\r\n )\r\n\r\n ref.barDom.innerHTML = markup\r\n\r\n fire(ref, 'onTemplate')\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {boolean}\r\n */\r\nexport function hasButtons (ref) {\r\n return !!(ref.options.buttons && Object.keys(ref.options.buttons).length)\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {string}\r\n */\r\nfunction buildButtons (ref) {\r\n if (hasButtons(ref)) {\r\n let buttons = document.createElement('div')\r\n Utils.addClass(buttons, 'noty_buttons')\r\n\r\n Object.keys(ref.options.buttons).forEach(key => {\r\n buttons.appendChild(ref.options.buttons[key].dom)\r\n })\r\n\r\n ref.options.buttons.forEach(btn => {\r\n buttons.appendChild(btn.dom)\r\n })\r\n return buttons.outerHTML\r\n }\r\n return ''\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function handleModal (ref) {\r\n if (ref.options.modal) {\r\n if (DocModalCount === 0) {\r\n createModal(ref)\r\n }\r\n\r\n DocModalCount++\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function handleModalClose (ref) {\r\n if (ref.options.modal && DocModalCount > 0) {\r\n DocModalCount--\r\n\r\n if (DocModalCount <= 0) {\r\n const modal = document.querySelector('.noty_modal')\r\n\r\n if (modal) {\r\n Utils.removeClass(modal, 'noty_modal_open')\r\n Utils.addClass(modal, 'noty_modal_close')\r\n Utils.addListener(modal, Utils.animationEndEvents, () => {\r\n Utils.remove(modal)\r\n })\r\n }\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * @return {void}\r\n */\r\nfunction createModal () {\r\n const body = document.querySelector('body')\r\n const modal = document.createElement('div')\r\n Utils.addClass(modal, 'noty_modal')\r\n body.insertBefore(modal, body.firstChild)\r\n Utils.addClass(modal, 'noty_modal_open')\r\n\r\n Utils.addListener(modal, Utils.animationEndEvents, () => {\r\n Utils.removeClass(modal, 'noty_modal_open')\r\n })\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nfunction findOrCreateContainer (ref) {\r\n if (ref.options.container) {\r\n ref.layoutDom = document.querySelector(ref.options.container)\r\n return\r\n }\r\n\r\n const layoutID = `noty_layout__${ref.options.layout}`\r\n ref.layoutDom = document.querySelector(`div#${layoutID}`)\r\n\r\n if (!ref.layoutDom) {\r\n ref.layoutDom = document.createElement('div')\r\n ref.layoutDom.setAttribute('id', layoutID)\r\n ref.layoutDom.setAttribute('role', 'alert')\r\n ref.layoutDom.setAttribute('aria-live', 'polite')\r\n Utils.addClass(ref.layoutDom, 'noty_layout')\r\n document.querySelector('body').appendChild(ref.layoutDom)\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function queueClose (ref) {\r\n if (ref.options.timeout) {\r\n if (ref.options.progressBar && ref.progressDom) {\r\n Utils.css(ref.progressDom, {\r\n transition: `width ${ref.options.timeout}ms linear`,\r\n width: '0%'\r\n })\r\n }\r\n\r\n clearTimeout(ref.closeTimer)\r\n\r\n ref.closeTimer = setTimeout(\r\n () => {\r\n ref.close()\r\n },\r\n ref.options.timeout\r\n )\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function dequeueClose (ref) {\r\n if (ref.options.timeout && ref.closeTimer) {\r\n clearTimeout(ref.closeTimer)\r\n ref.closeTimer = -1\r\n\r\n if (ref.options.progressBar && ref.progressDom) {\r\n Utils.css(ref.progressDom, {\r\n transition: 'width 0ms linear',\r\n width: '100%'\r\n })\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @param {string} eventName\r\n * @return {void}\r\n */\r\nexport function fire (ref, eventName) {\r\n if (ref.listeners.hasOwnProperty(eventName)) {\r\n ref.listeners[eventName].forEach(cb => {\r\n if (typeof cb === 'function') {\r\n cb.apply(ref)\r\n }\r\n })\r\n }\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function openFlow (ref) {\r\n fire(ref, 'afterShow')\r\n queueClose(ref)\r\n\r\n Utils.addListener(ref.barDom, 'mouseenter', () => {\r\n dequeueClose(ref)\r\n })\r\n\r\n Utils.addListener(ref.barDom, 'mouseleave', () => {\r\n queueClose(ref)\r\n })\r\n}\r\n\r\n/**\r\n * @param {Noty} ref\r\n * @return {void}\r\n */\r\nexport function closeFlow (ref) {\r\n delete Store[ref.id]\r\n ref.closing = false\r\n fire(ref, 'afterClose')\r\n\r\n Utils.remove(ref.barDom)\r\n\r\n if (\r\n ref.layoutDom.querySelectorAll('.noty_bar').length === 0 &&\r\n !ref.options.container\r\n ) {\r\n Utils.remove(ref.layoutDom)\r\n }\r\n\r\n if (\r\n Utils.inArray('docVisible', ref.options.titleCount.conditions) ||\r\n Utils.inArray('docHidden', ref.options.titleCount.conditions)\r\n ) {\r\n docTitle.decrement()\r\n }\r\n\r\n queueRender(ref.options.queue)\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./src/api.js","import * as Utils from 'utils'\r\n\r\nexport class NotyButton {\r\n constructor (html, classes, cb, attributes = {}) {\r\n this.dom = document.createElement('button')\r\n this.dom.innerHTML = html\r\n this.id = (attributes.id = attributes.id || Utils.generateID('button'))\r\n this.cb = cb\r\n Object.keys(attributes).forEach(propertyName => {\r\n this.dom.setAttribute(propertyName, attributes[propertyName])\r\n })\r\n Utils.addClass(this.dom, classes || 'noty_btn')\r\n\r\n return this\r\n }\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./src/button.js","export class Push {\r\n constructor (workerPath = '/service-worker.js') {\r\n this.subData = {}\r\n this.workerPath = workerPath\r\n this.listeners = {\r\n onPermissionGranted: [],\r\n onPermissionDenied: [],\r\n onSubscriptionSuccess: [],\r\n onSubscriptionCancel: [],\r\n onWorkerError: [],\r\n onWorkerSuccess: [],\r\n onWorkerNotSupported: []\r\n }\r\n return this\r\n }\r\n\r\n /**\r\n * @param {string} eventName\r\n * @param {function} cb\r\n * @return {Push}\r\n */\r\n on (eventName, cb = () => {}) {\r\n if (typeof cb === 'function' && this.listeners.hasOwnProperty(eventName)) {\r\n this.listeners[eventName].push(cb)\r\n }\r\n\r\n return this\r\n }\r\n\r\n fire (eventName, params = []) {\r\n if (this.listeners.hasOwnProperty(eventName)) {\r\n this.listeners[eventName].forEach(cb => {\r\n if (typeof cb === 'function') {\r\n cb.apply(this, params)\r\n }\r\n })\r\n }\r\n }\r\n\r\n create () {\r\n console.log('NOT IMPLEMENTED YET')\r\n }\r\n\r\n /**\r\n * @return {boolean}\r\n */\r\n isSupported () {\r\n let result = false\r\n\r\n try {\r\n result = window.Notification ||\r\n window.webkitNotifications ||\r\n navigator.mozNotification ||\r\n (window.external && window.external.msIsSiteMode() !== undefined)\r\n } catch (e) {}\r\n\r\n return result\r\n }\r\n\r\n /**\r\n * @return {string}\r\n */\r\n getPermissionStatus () {\r\n let perm = 'default'\r\n\r\n if (window.Notification && window.Notification.permissionLevel) {\r\n perm = window.Notification.permissionLevel\r\n } else if (\r\n window.webkitNotifications && window.webkitNotifications.checkPermission\r\n ) {\r\n switch (window.webkitNotifications.checkPermission()) {\r\n case 1:\r\n perm = 'default'\r\n break\r\n case 0:\r\n perm = 'granted'\r\n break\r\n default:\r\n perm = 'denied'\r\n }\r\n } else if (window.Notification && window.Notification.permission) {\r\n perm = window.Notification.permission\r\n } else if (navigator.mozNotification) {\r\n perm = 'granted'\r\n } else if (\r\n window.external && window.external.msIsSiteMode() !== undefined\r\n ) {\r\n perm = window.external.msIsSiteMode() ? 'granted' : 'default'\r\n }\r\n\r\n return perm.toString().toLowerCase()\r\n }\r\n\r\n /**\r\n * @return {string}\r\n */\r\n getEndpoint (subscription) {\r\n let endpoint = subscription.endpoint\r\n const subscriptionId = subscription.subscriptionId\r\n\r\n // fix for Chrome < 45\r\n if (subscriptionId && endpoint.indexOf(subscriptionId) === -1) {\r\n endpoint += '/' + subscriptionId\r\n }\r\n\r\n return endpoint\r\n }\r\n\r\n /**\r\n * @return {boolean}\r\n */\r\n isSWRegistered () {\r\n try {\r\n return navigator.serviceWorker.controller.state === 'activated'\r\n } catch (e) {\r\n return false\r\n }\r\n }\r\n\r\n /**\r\n * @return {void}\r\n */\r\n unregisterWorker () {\r\n const self = this\r\n if ('serviceWorker' in navigator) {\r\n navigator.serviceWorker.getRegistrations().then(function (registrations) {\r\n for (let registration of registrations) {\r\n registration.unregister()\r\n self.fire('onSubscriptionCancel')\r\n }\r\n })\r\n }\r\n }\r\n\r\n /**\r\n * @return {void}\r\n */\r\n requestSubscription (userVisibleOnly = true) {\r\n const self = this\r\n const current = this.getPermissionStatus()\r\n const cb = result => {\r\n if (result === 'granted') {\r\n this.fire('onPermissionGranted')\r\n\r\n if ('serviceWorker' in navigator) {\r\n navigator.serviceWorker.register(this.workerPath).then(function () {\r\n navigator.serviceWorker.ready.then(\r\n function (serviceWorkerRegistration) {\r\n self.fire('onWorkerSuccess')\r\n serviceWorkerRegistration.pushManager\r\n .subscribe({\r\n userVisibleOnly: userVisibleOnly\r\n })\r\n .then(function (subscription) {\r\n const key = subscription.getKey('p256dh')\r\n const token = subscription.getKey('auth')\r\n\r\n self.subData = {\r\n endpoint: self.getEndpoint(subscription),\r\n p256dh: key\r\n ? window.btoa(\r\n String.fromCharCode.apply(null, new Uint8Array(key))\r\n )\r\n : null,\r\n auth: token\r\n ? window.btoa(\r\n String.fromCharCode.apply(\r\n null,\r\n new Uint8Array(token)\r\n )\r\n )\r\n : null\r\n }\r\n\r\n self.fire('onSubscriptionSuccess', [self.subData])\r\n })\r\n .catch(function (err) {\r\n self.fire('onWorkerError', [err])\r\n })\r\n }\r\n )\r\n })\r\n } else {\r\n self.fire('onWorkerNotSupported')\r\n }\r\n } else if (result === 'denied') {\r\n this.fire('onPermissionDenied')\r\n this.unregisterWorker()\r\n }\r\n }\r\n\r\n if (current === 'default') {\r\n if (window.Notification && window.Notification.requestPermission) {\r\n window.Notification.requestPermission(cb)\r\n } else if (\r\n window.webkitNotifications && window.webkitNotifications.checkPermission\r\n ) {\r\n window.webkitNotifications.requestPermission(cb)\r\n }\r\n } else {\r\n cb(current)\r\n }\r\n }\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./src/push.js","/*!\n * @overview es6-promise - a tiny implementation of Promises/A+.\n * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)\n * @license Licensed under MIT license\n * See https://raw.githubusercontent.com/stefanpenner/es6-promise/master/LICENSE\n * @version 4.1.1\n */\n\n(function (global, factory) {\n\ttypeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :\n\ttypeof define === 'function' && define.amd ? define(factory) :\n\t(global.ES6Promise = factory());\n}(this, (function () { 'use strict';\n\nfunction objectOrFunction(x) {\n var type = typeof x;\n return x !== null && (type === 'object' || type === 'function');\n}\n\nfunction isFunction(x) {\n return typeof x === 'function';\n}\n\nvar _isArray = undefined;\nif (Array.isArray) {\n _isArray = Array.isArray;\n} else {\n _isArray = function (x) {\n return Object.prototype.toString.call(x) === '[object Array]';\n };\n}\n\nvar isArray = _isArray;\n\nvar len = 0;\nvar vertxNext = undefined;\nvar customSchedulerFn = undefined;\n\nvar asap = function asap(callback, arg) {\n queue[len] = callback;\n queue[len + 1] = arg;\n len += 2;\n if (len === 2) {\n // If len is 2, that means that we need to schedule an async flush.\n // If additional callbacks are queued before the queue is flushed, they\n // will be processed by this flush that we are scheduling.\n if (customSchedulerFn) {\n customSchedulerFn(flush);\n } else {\n scheduleFlush();\n }\n }\n};\n\nfunction setScheduler(scheduleFn) {\n customSchedulerFn = scheduleFn;\n}\n\nfunction setAsap(asapFn) {\n asap = asapFn;\n}\n\nvar browserWindow = typeof window !== 'undefined' ? window : undefined;\nvar browserGlobal = browserWindow || {};\nvar BrowserMutationObserver = browserGlobal.MutationObserver || browserGlobal.WebKitMutationObserver;\nvar isNode = typeof self === 'undefined' && typeof process !== 'undefined' && ({}).toString.call(process) === '[object process]';\n\n// test for web worker but not in IE10\nvar isWorker = typeof Uint8ClampedArray !== 'undefined' && typeof importScripts !== 'undefined' && typeof MessageChannel !== 'undefined';\n\n// node\nfunction useNextTick() {\n // node version 0.10.x displays a deprecation warning when nextTick is used recursively\n // see https://github.com/cujojs/when/issues/410 for details\n return function () {\n return process.nextTick(flush);\n };\n}\n\n// vertx\nfunction useVertxTimer() {\n if (typeof vertxNext !== 'undefined') {\n return function () {\n vertxNext(flush);\n };\n }\n\n return useSetTimeout();\n}\n\nfunction useMutationObserver() {\n var iterations = 0;\n var observer = new BrowserMutationObserver(flush);\n var node = document.createTextNode('');\n observer.observe(node, { characterData: true });\n\n return function () {\n node.data = iterations = ++iterations % 2;\n };\n}\n\n// web worker\nfunction useMessageChannel() {\n var channel = new MessageChannel();\n channel.port1.onmessage = flush;\n return function () {\n return channel.port2.postMessage(0);\n };\n}\n\nfunction useSetTimeout() {\n // Store setTimeout reference so es6-promise will be unaffected by\n // other code modifying setTimeout (like sinon.useFakeTimers())\n var globalSetTimeout = setTimeout;\n return function () {\n return globalSetTimeout(flush, 1);\n };\n}\n\nvar queue = new Array(1000);\nfunction flush() {\n for (var i = 0; i < len; i += 2) {\n var callback = queue[i];\n var arg = queue[i + 1];\n\n callback(arg);\n\n queue[i] = undefined;\n queue[i + 1] = undefined;\n }\n\n len = 0;\n}\n\nfunction attemptVertx() {\n try {\n var r = require;\n var vertx = r('vertx');\n vertxNext = vertx.runOnLoop || vertx.runOnContext;\n return useVertxTimer();\n } catch (e) {\n return useSetTimeout();\n }\n}\n\nvar scheduleFlush = undefined;\n// Decide what async method to use to triggering processing of queued callbacks:\nif (isNode) {\n scheduleFlush = useNextTick();\n} else if (BrowserMutationObserver) {\n scheduleFlush = useMutationObserver();\n} else if (isWorker) {\n scheduleFlush = useMessageChannel();\n} else if (browserWindow === undefined && typeof require === 'function') {\n scheduleFlush = attemptVertx();\n} else {\n scheduleFlush = useSetTimeout();\n}\n\nfunction then(onFulfillment, onRejection) {\n var _arguments = arguments;\n\n var parent = this;\n\n var child = new this.constructor(noop);\n\n if (child[PROMISE_ID] === undefined) {\n makePromise(child);\n }\n\n var _state = parent._state;\n\n if (_state) {\n (function () {\n var callback = _arguments[_state - 1];\n asap(function () {\n return invokeCallback(_state, child, callback, parent._result);\n });\n })();\n } else {\n subscribe(parent, child, onFulfillment, onRejection);\n }\n\n return child;\n}\n\n/**\n `Promise.resolve` returns a promise that will become resolved with the\n passed `value`. It is shorthand for the following:\n\n ```javascript\n let promise = new Promise(function(resolve, reject){\n resolve(1);\n });\n\n promise.then(function(value){\n // value === 1\n });\n ```\n\n Instead of writing the above, your code now simply becomes the following:\n\n ```javascript\n let promise = Promise.resolve(1);\n\n promise.then(function(value){\n // value === 1\n });\n ```\n\n @method resolve\n @static\n @param {Any} value value that the returned promise will be resolved with\n Useful for tooling.\n @return {Promise} a promise that will become fulfilled with the given\n `value`\n*/\nfunction resolve$1(object) {\n /*jshint validthis:true */\n var Constructor = this;\n\n if (object && typeof object === 'object' && object.constructor === Constructor) {\n return object;\n }\n\n var promise = new Constructor(noop);\n resolve(promise, object);\n return promise;\n}\n\nvar PROMISE_ID = Math.random().toString(36).substring(16);\n\nfunction noop() {}\n\nvar PENDING = void 0;\nvar FULFILLED = 1;\nvar REJECTED = 2;\n\nvar GET_THEN_ERROR = new ErrorObject();\n\nfunction selfFulfillment() {\n return new TypeError(\"You cannot resolve a promise with itself\");\n}\n\nfunction cannotReturnOwn() {\n return new TypeError('A promises callback cannot return that same promise.');\n}\n\nfunction getThen(promise) {\n try {\n return promise.then;\n } catch (error) {\n GET_THEN_ERROR.error = error;\n return GET_THEN_ERROR;\n }\n}\n\nfunction tryThen(then$$1, value, fulfillmentHandler, rejectionHandler) {\n try {\n then$$1.call(value, fulfillmentHandler, rejectionHandler);\n } catch (e) {\n return e;\n }\n}\n\nfunction handleForeignThenable(promise, thenable, then$$1) {\n asap(function (promise) {\n var sealed = false;\n var error = tryThen(then$$1, thenable, function (value) {\n if (sealed) {\n return;\n }\n sealed = true;\n if (thenable !== value) {\n resolve(promise, value);\n } else {\n fulfill(promise, value);\n }\n }, function (reason) {\n if (sealed) {\n return;\n }\n sealed = true;\n\n reject(promise, reason);\n }, 'Settle: ' + (promise._label || ' unknown promise'));\n\n if (!sealed && error) {\n sealed = true;\n reject(promise, error);\n }\n }, promise);\n}\n\nfunction handleOwnThenable(promise, thenable) {\n if (thenable._state === FULFILLED) {\n fulfill(promise, thenable._result);\n } else if (thenable._state === REJECTED) {\n reject(promise, thenable._result);\n } else {\n subscribe(thenable, undefined, function (value) {\n return resolve(promise, value);\n }, function (reason) {\n return reject(promise, reason);\n });\n }\n}\n\nfunction handleMaybeThenable(promise, maybeThenable, then$$1) {\n if (maybeThenable.constructor === promise.constructor && then$$1 === then && maybeThenable.constructor.resolve === resolve$1) {\n handleOwnThenable(promise, maybeThenable);\n } else {\n if (then$$1 === GET_THEN_ERROR) {\n reject(promise, GET_THEN_ERROR.error);\n GET_THEN_ERROR.error = null;\n } else if (then$$1 === undefined) {\n fulfill(promise, maybeThenable);\n } else if (isFunction(then$$1)) {\n handleForeignThenable(promise, maybeThenable, then$$1);\n } else {\n fulfill(promise, maybeThenable);\n }\n }\n}\n\nfunction resolve(promise, value) {\n if (promise === value) {\n reject(promise, selfFulfillment());\n } else if (objectOrFunction(value)) {\n handleMaybeThenable(promise, value, getThen(value));\n } else {\n fulfill(promise, value);\n }\n}\n\nfunction publishRejection(promise) {\n if (promise._onerror) {\n promise._onerror(promise._result);\n }\n\n publish(promise);\n}\n\nfunction fulfill(promise, value) {\n if (promise._state !== PENDING) {\n return;\n }\n\n promise._result = value;\n promise._state = FULFILLED;\n\n if (promise._subscribers.length !== 0) {\n asap(publish, promise);\n }\n}\n\nfunction reject(promise, reason) {\n if (promise._state !== PENDING) {\n return;\n }\n promise._state = REJECTED;\n promise._result = reason;\n\n asap(publishRejection, promise);\n}\n\nfunction subscribe(parent, child, onFulfillment, onRejection) {\n var _subscribers = parent._subscribers;\n var length = _subscribers.length;\n\n parent._onerror = null;\n\n _subscribers[length] = child;\n _subscribers[length + FULFILLED] = onFulfillment;\n _subscribers[length + REJECTED] = onRejection;\n\n if (length === 0 && parent._state) {\n asap(publish, parent);\n }\n}\n\nfunction publish(promise) {\n var subscribers = promise._subscribers;\n var settled = promise._state;\n\n if (subscribers.length === 0) {\n return;\n }\n\n var child = undefined,\n callback = undefined,\n detail = promise._result;\n\n for (var i = 0; i < subscribers.length; i += 3) {\n child = subscribers[i];\n callback = subscribers[i + settled];\n\n if (child) {\n invokeCallback(settled, child, callback, detail);\n } else {\n callback(detail);\n }\n }\n\n promise._subscribers.length = 0;\n}\n\nfunction ErrorObject() {\n this.error = null;\n}\n\nvar TRY_CATCH_ERROR = new ErrorObject();\n\nfunction tryCatch(callback, detail) {\n try {\n return callback(detail);\n } catch (e) {\n TRY_CATCH_ERROR.error = e;\n return TRY_CATCH_ERROR;\n }\n}\n\nfunction invokeCallback(settled, promise, callback, detail) {\n var hasCallback = isFunction(callback),\n value = undefined,\n error = undefined,\n succeeded = undefined,\n failed = undefined;\n\n if (hasCallback) {\n value = tryCatch(callback, detail);\n\n if (value === TRY_CATCH_ERROR) {\n failed = true;\n error = value.error;\n value.error = null;\n } else {\n succeeded = true;\n }\n\n if (promise === value) {\n reject(promise, cannotReturnOwn());\n return;\n }\n } else {\n value = detail;\n succeeded = true;\n }\n\n if (promise._state !== PENDING) {\n // noop\n } else if (hasCallback && succeeded) {\n resolve(promise, value);\n } else if (failed) {\n reject(promise, error);\n } else if (settled === FULFILLED) {\n fulfill(promise, value);\n } else if (settled === REJECTED) {\n reject(promise, value);\n }\n}\n\nfunction initializePromise(promise, resolver) {\n try {\n resolver(function resolvePromise(value) {\n resolve(promise, value);\n }, function rejectPromise(reason) {\n reject(promise, reason);\n });\n } catch (e) {\n reject(promise, e);\n }\n}\n\nvar id = 0;\nfunction nextId() {\n return id++;\n}\n\nfunction makePromise(promise) {\n promise[PROMISE_ID] = id++;\n promise._state = undefined;\n promise._result = undefined;\n promise._subscribers = [];\n}\n\nfunction Enumerator$1(Constructor, input) {\n this._instanceConstructor = Constructor;\n this.promise = new Constructor(noop);\n\n if (!this.promise[PROMISE_ID]) {\n makePromise(this.promise);\n }\n\n if (isArray(input)) {\n this.length = input.length;\n this._remaining = input.length;\n\n this._result = new Array(this.length);\n\n if (this.length === 0) {\n fulfill(this.promise, this._result);\n } else {\n this.length = this.length || 0;\n this._enumerate(input);\n if (this._remaining === 0) {\n fulfill(this.promise, this._result);\n }\n }\n } else {\n reject(this.promise, validationError());\n }\n}\n\nfunction validationError() {\n return new Error('Array Methods must be provided an Array');\n}\n\nEnumerator$1.prototype._enumerate = function (input) {\n for (var i = 0; this._state === PENDING && i < input.length; i++) {\n this._eachEntry(input[i], i);\n }\n};\n\nEnumerator$1.prototype._eachEntry = function (entry, i) {\n var c = this._instanceConstructor;\n var resolve$$1 = c.resolve;\n\n if (resolve$$1 === resolve$1) {\n var _then = getThen(entry);\n\n if (_then === then && entry._state !== PENDING) {\n this._settledAt(entry._state, i, entry._result);\n } else if (typeof _then !== 'function') {\n this._remaining--;\n this._result[i] = entry;\n } else if (c === Promise$2) {\n var promise = new c(noop);\n handleMaybeThenable(promise, entry, _then);\n this._willSettleAt(promise, i);\n } else {\n this._willSettleAt(new c(function (resolve$$1) {\n return resolve$$1(entry);\n }), i);\n }\n } else {\n this._willSettleAt(resolve$$1(entry), i);\n }\n};\n\nEnumerator$1.prototype._settledAt = function (state, i, value) {\n var promise = this.promise;\n\n if (promise._state === PENDING) {\n this._remaining--;\n\n if (state === REJECTED) {\n reject(promise, value);\n } else {\n this._result[i] = value;\n }\n }\n\n if (this._remaining === 0) {\n fulfill(promise, this._result);\n }\n};\n\nEnumerator$1.prototype._willSettleAt = function (promise, i) {\n var enumerator = this;\n\n subscribe(promise, undefined, function (value) {\n return enumerator._settledAt(FULFILLED, i, value);\n }, function (reason) {\n return enumerator._settledAt(REJECTED, i, reason);\n });\n};\n\n/**\n `Promise.all` accepts an array of promises, and returns a new promise which\n is fulfilled with an array of fulfillment values for the passed promises, or\n rejected with the reason of the first passed promise to be rejected. It casts all\n elements of the passed iterable to promises as it runs this algorithm.\n\n Example:\n\n ```javascript\n let promise1 = resolve(1);\n let promise2 = resolve(2);\n let promise3 = resolve(3);\n let promises = [ promise1, promise2, promise3 ];\n\n Promise.all(promises).then(function(array){\n // The array here would be [ 1, 2, 3 ];\n });\n ```\n\n If any of the `promises` given to `all` are rejected, the first promise\n that is rejected will be given as an argument to the returned promises's\n rejection handler. For example:\n\n Example:\n\n ```javascript\n let promise1 = resolve(1);\n let promise2 = reject(new Error(\"2\"));\n let promise3 = reject(new Error(\"3\"));\n let promises = [ promise1, promise2, promise3 ];\n\n Promise.all(promises).then(function(array){\n // Code here never runs because there are rejected promises!\n }, function(error) {\n // error.message === \"2\"\n });\n ```\n\n @method all\n @static\n @param {Array} entries array of promises\n @param {String} label optional string for labeling the promise.\n Useful for tooling.\n @return {Promise} promise that is fulfilled when all `promises` have been\n fulfilled, or rejected if any of them become rejected.\n @static\n*/\nfunction all$1(entries) {\n return new Enumerator$1(this, entries).promise;\n}\n\n/**\n `Promise.race` returns a new promise which is settled in the same way as the\n first passed promise to settle.\n\n Example:\n\n ```javascript\n let promise1 = new Promise(function(resolve, reject){\n setTimeout(function(){\n resolve('promise 1');\n }, 200);\n });\n\n let promise2 = new Promise(function(resolve, reject){\n setTimeout(function(){\n resolve('promise 2');\n }, 100);\n });\n\n Promise.race([promise1, promise2]).then(function(result){\n // result === 'promise 2' because it was resolved before promise1\n // was resolved.\n });\n ```\n\n `Promise.race` is deterministic in that only the state of the first\n settled promise matters. For example, even if other promises given to the\n `promises` array argument are resolved, but the first settled promise has\n become rejected before the other promises became fulfilled, the returned\n promise will become rejected:\n\n ```javascript\n let promise1 = new Promise(function(resolve, reject){\n setTimeout(function(){\n resolve('promise 1');\n }, 200);\n });\n\n let promise2 = new Promise(function(resolve, reject){\n setTimeout(function(){\n reject(new Error('promise 2'));\n }, 100);\n });\n\n Promise.race([promise1, promise2]).then(function(result){\n // Code here never runs\n }, function(reason){\n // reason.message === 'promise 2' because promise 2 became rejected before\n // promise 1 became fulfilled\n });\n ```\n\n An example real-world use case is implementing timeouts:\n\n ```javascript\n Promise.race([ajax('foo.json'), timeout(5000)])\n ```\n\n @method race\n @static\n @param {Array} promises array of promises to observe\n Useful for tooling.\n @return {Promise} a promise which settles in the same way as the first passed\n promise to settle.\n*/\nfunction race$1(entries) {\n /*jshint validthis:true */\n var Constructor = this;\n\n if (!isArray(entries)) {\n return new Constructor(function (_, reject) {\n return reject(new TypeError('You must pass an array to race.'));\n });\n } else {\n return new Constructor(function (resolve, reject) {\n var length = entries.length;\n for (var i = 0; i < length; i++) {\n Constructor.resolve(entries[i]).then(resolve, reject);\n }\n });\n }\n}\n\n/**\n `Promise.reject` returns a promise rejected with the passed `reason`.\n It is shorthand for the following:\n\n ```javascript\n let promise = new Promise(function(resolve, reject){\n reject(new Error('WHOOPS'));\n });\n\n promise.then(function(value){\n // Code here doesn't run because the promise is rejected!\n }, function(reason){\n // reason.message === 'WHOOPS'\n });\n ```\n\n Instead of writing the above, your code now simply becomes the following:\n\n ```javascript\n let promise = Promise.reject(new Error('WHOOPS'));\n\n promise.then(function(value){\n // Code here doesn't run because the promise is rejected!\n }, function(reason){\n // reason.message === 'WHOOPS'\n });\n ```\n\n @method reject\n @static\n @param {Any} reason value that the returned promise will be rejected with.\n Useful for tooling.\n @return {Promise} a promise rejected with the given `reason`.\n*/\nfunction reject$1(reason) {\n /*jshint validthis:true */\n var Constructor = this;\n var promise = new Constructor(noop);\n reject(promise, reason);\n return promise;\n}\n\nfunction needsResolver() {\n throw new TypeError('You must pass a resolver function as the first argument to the promise constructor');\n}\n\nfunction needsNew() {\n throw new TypeError(\"Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.\");\n}\n\n/**\n Promise objects represent the eventual result of an asynchronous operation. The\n primary way of interacting with a promise is through its `then` method, which\n registers callbacks to receive either a promise's eventual value or the reason\n why the promise cannot be fulfilled.\n\n Terminology\n -----------\n\n - `promise` is an object or function with a `then` method whose behavior conforms to this specification.\n - `thenable` is an object or function that defines a `then` method.\n - `value` is any legal JavaScript value (including undefined, a thenable, or a promise).\n - `exception` is a value that is thrown using the throw statement.\n - `reason` is a value that indicates why a promise was rejected.\n - `settled` the final resting state of a promise, fulfilled or rejected.\n\n A promise can be in one of three states: pending, fulfilled, or rejected.\n\n Promises that are fulfilled have a fulfillment value and are in the fulfilled\n state. Promises that are rejected have a rejection reason and are in the\n rejected state. A fulfillment value is never a thenable.\n\n Promises can also be said to *resolve* a value. If this value is also a\n promise, then the original promise's settled state will match the value's\n settled state. So a promise that *resolves* a promise that rejects will\n itself reject, and a promise that *resolves* a promise that fulfills will\n itself fulfill.\n\n\n Basic Usage:\n ------------\n\n ```js\n let promise = new Promise(function(resolve, reject) {\n // on success\n resolve(value);\n\n // on failure\n reject(reason);\n });\n\n promise.then(function(value) {\n // on fulfillment\n }, function(reason) {\n // on rejection\n });\n ```\n\n Advanced Usage:\n ---------------\n\n Promises shine when abstracting away asynchronous interactions such as\n `XMLHttpRequest`s.\n\n ```js\n function getJSON(url) {\n return new Promise(function(resolve, reject){\n let xhr = new XMLHttpRequest();\n\n xhr.open('GET', url);\n xhr.onreadystatechange = handler;\n xhr.responseType = 'json';\n xhr.setRequestHeader('Accept', 'application/json');\n xhr.send();\n\n function handler() {\n if (this.readyState === this.DONE) {\n if (this.status === 200) {\n resolve(this.response);\n } else {\n reject(new Error('getJSON: `' + url + '` failed with status: [' + this.status + ']'));\n }\n }\n };\n });\n }\n\n getJSON('/posts.json').then(function(json) {\n // on fulfillment\n }, function(reason) {\n // on rejection\n });\n ```\n\n Unlike callbacks, promises are great composable primitives.\n\n ```js\n Promise.all([\n getJSON('/posts'),\n getJSON('/comments')\n ]).then(function(values){\n values[0] // => postsJSON\n values[1] // => commentsJSON\n\n return values;\n });\n ```\n\n @class Promise\n @param {function} resolver\n Useful for tooling.\n @constructor\n*/\nfunction Promise$2(resolver) {\n this[PROMISE_ID] = nextId();\n this._result = this._state = undefined;\n this._subscribers = [];\n\n if (noop !== resolver) {\n typeof resolver !== 'function' && needsResolver();\n this instanceof Promise$2 ? initializePromise(this, resolver) : needsNew();\n }\n}\n\nPromise$2.all = all$1;\nPromise$2.race = race$1;\nPromise$2.resolve = resolve$1;\nPromise$2.reject = reject$1;\nPromise$2._setScheduler = setScheduler;\nPromise$2._setAsap = setAsap;\nPromise$2._asap = asap;\n\nPromise$2.prototype = {\n constructor: Promise$2,\n\n /**\n The primary way of interacting with a promise is through its `then` method,\n which registers callbacks to receive either a promise's eventual value or the\n reason why the promise cannot be fulfilled.\n \n ```js\n findUser().then(function(user){\n // user is available\n }, function(reason){\n // user is unavailable, and you are given the reason why\n });\n ```\n \n Chaining\n --------\n \n The return value of `then` is itself a promise. This second, 'downstream'\n promise is resolved with the return value of the first promise's fulfillment\n or rejection handler, or rejected if the handler throws an exception.\n \n ```js\n findUser().then(function (user) {\n return user.name;\n }, function (reason) {\n return 'default name';\n }).then(function (userName) {\n // If `findUser` fulfilled, `userName` will be the user's name, otherwise it\n // will be `'default name'`\n });\n \n findUser().then(function (user) {\n throw new Error('Found user, but still unhappy');\n }, function (reason) {\n throw new Error('`findUser` rejected and we're unhappy');\n }).then(function (value) {\n // never reached\n }, function (reason) {\n // if `findUser` fulfilled, `reason` will be 'Found user, but still unhappy'.\n // If `findUser` rejected, `reason` will be '`findUser` rejected and we're unhappy'.\n });\n ```\n If the downstream promise does not specify a rejection handler, rejection reasons will be propagated further downstream.\n \n ```js\n findUser().then(function (user) {\n throw new PedagogicalException('Upstream error');\n }).then(function (value) {\n // never reached\n }).then(function (value) {\n // never reached\n }, function (reason) {\n // The `PedgagocialException` is propagated all the way down to here\n });\n ```\n \n Assimilation\n ------------\n \n Sometimes the value you want to propagate to a downstream promise can only be\n retrieved asynchronously. This can be achieved by returning a promise in the\n fulfillment or rejection handler. The downstream promise will then be pending\n until the returned promise is settled. This is called *assimilation*.\n \n ```js\n findUser().then(function (user) {\n return findCommentsByAuthor(user);\n }).then(function (comments) {\n // The user's comments are now available\n });\n ```\n \n If the assimliated promise rejects, then the downstream promise will also reject.\n \n ```js\n findUser().then(function (user) {\n return findCommentsByAuthor(user);\n }).then(function (comments) {\n // If `findCommentsByAuthor` fulfills, we'll have the value here\n }, function (reason) {\n // If `findCommentsByAuthor` rejects, we'll have the reason here\n });\n ```\n \n Simple Example\n --------------\n \n Synchronous Example\n \n ```javascript\n let result;\n \n try {\n result = findResult();\n // success\n } catch(reason) {\n // failure\n }\n ```\n \n Errback Example\n \n ```js\n findResult(function(result, err){\n if (err) {\n // failure\n } else {\n // success\n }\n });\n ```\n \n Promise Example;\n \n ```javascript\n findResult().then(function(result){\n // success\n }, function(reason){\n // failure\n });\n ```\n \n Advanced Example\n --------------\n \n Synchronous Example\n \n ```javascript\n let author, books;\n \n try {\n author = findAuthor();\n books = findBooksByAuthor(author);\n // success\n } catch(reason) {\n // failure\n }\n ```\n \n Errback Example\n \n ```js\n \n function foundBooks(books) {\n \n }\n \n function failure(reason) {\n \n }\n \n findAuthor(function(author, err){\n if (err) {\n failure(err);\n // failure\n } else {\n try {\n findBoooksByAuthor(author, function(books, err) {\n if (err) {\n failure(err);\n } else {\n try {\n foundBooks(books);\n } catch(reason) {\n failure(reason);\n }\n }\n });\n } catch(error) {\n failure(err);\n }\n // success\n }\n });\n ```\n \n Promise Example;\n \n ```javascript\n findAuthor().\n then(findBooksByAuthor).\n then(function(books){\n // found books\n }).catch(function(reason){\n // something went wrong\n });\n ```\n \n @method then\n @param {Function} onFulfilled\n @param {Function} onRejected\n Useful for tooling.\n @return {Promise}\n */\n then: then,\n\n /**\n `catch` is simply sugar for `then(undefined, onRejection)` which makes it the same\n as the catch block of a try/catch statement.\n \n ```js\n function findAuthor(){\n throw new Error('couldn't find that author');\n }\n \n // synchronous\n try {\n findAuthor();\n } catch(reason) {\n // something went wrong\n }\n \n // async with promises\n findAuthor().catch(function(reason){\n // something went wrong\n });\n ```\n \n @method catch\n @param {Function} onRejection\n Useful for tooling.\n @return {Promise}\n */\n 'catch': function _catch(onRejection) {\n return this.then(null, onRejection);\n }\n};\n\n/*global self*/\nfunction polyfill$1() {\n var local = undefined;\n\n if (typeof global !== 'undefined') {\n local = global;\n } else if (typeof self !== 'undefined') {\n local = self;\n } else {\n try {\n local = Function('return this')();\n } catch (e) {\n throw new Error('polyfill failed because global object is unavailable in this environment');\n }\n }\n\n var P = local.Promise;\n\n if (P) {\n var promiseToString = null;\n try {\n promiseToString = Object.prototype.toString.call(P.resolve());\n } catch (e) {\n // silently ignored\n }\n\n if (promiseToString === '[object Promise]' && !P.cast) {\n return;\n }\n }\n\n local.Promise = Promise$2;\n}\n\n// Strange compat..\nPromise$2.polyfill = polyfill$1;\nPromise$2.Promise = Promise$2;\n\nreturn Promise$2;\n\n})));\n\n//# sourceMappingURL=es6-promise.map\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/es6-promise/dist/es6-promise.js\n// module id = 4\n// module chunks = 0","/* global VERSION */\n\nimport 'noty.scss'\nimport Promise from 'es6-promise'\nimport * as Utils from 'utils'\nimport * as API from 'api'\nimport { NotyButton } from 'button'\nimport { Push } from 'push'\n\nexport default class Noty {\n /**\n * @param {object} options\n * @return {Noty}\n */\n constructor (options = {}) {\n this.options = Utils.deepExtend({}, API.Defaults, options)\n\n if (API.Store[this.options.id]) {\n return API.Store[this.options.id]\n }\n\n this.id = this.options.id || Utils.generateID('bar')\n this.closeTimer = -1\n this.barDom = null\n this.layoutDom = null\n this.progressDom = null\n this.showing = false\n this.shown = false\n this.closed = false\n this.closing = false\n this.killable = this.options.timeout || this.options.closeWith.length > 0\n this.hasSound = this.options.sounds.sources.length > 0\n this.soundPlayed = false\n this.listeners = {\n beforeShow: [],\n onShow: [],\n afterShow: [],\n onClose: [],\n afterClose: [],\n onClick: [],\n onHover: [],\n onTemplate: []\n }\n this.promises = {\n show: null,\n close: null\n }\n this.on('beforeShow', this.options.callbacks.beforeShow)\n this.on('onShow', this.options.callbacks.onShow)\n this.on('afterShow', this.options.callbacks.afterShow)\n this.on('onClose', this.options.callbacks.onClose)\n this.on('afterClose', this.options.callbacks.afterClose)\n this.on('onClick', this.options.callbacks.onClick)\n this.on('onHover', this.options.callbacks.onHover)\n this.on('onTemplate', this.options.callbacks.onTemplate)\n\n return this\n }\n\n /**\n * @param {string} eventName\n * @param {function} cb\n * @return {Noty}\n */\n on (eventName, cb = () => {}) {\n if (typeof cb === 'function' && this.listeners.hasOwnProperty(eventName)) {\n this.listeners[eventName].push(cb)\n }\n\n return this\n }\n\n /**\n * @return {Noty}\n */\n show () {\n if (this.showing || this.shown) {\n return this // preventing multiple show\n }\n\n if (this.options.killer === true) {\n Noty.closeAll()\n } else if (typeof this.options.killer === 'string') {\n Noty.closeAll(this.options.killer)\n }\n\n let queueCounts = API.getQueueCounts(this.options.queue)\n\n if (\n queueCounts.current >= queueCounts.maxVisible ||\n (API.PageHidden && this.options.visibilityControl)\n ) {\n API.addToQueue(this)\n\n if (\n API.PageHidden &&\n this.hasSound &&\n Utils.inArray('docHidden', this.options.sounds.conditions)\n ) {\n Utils.createAudioElements(this)\n }\n\n if (\n API.PageHidden &&\n Utils.inArray('docHidden', this.options.titleCount.conditions)\n ) {\n API.docTitle.increment()\n }\n\n return this\n }\n\n API.Store[this.id] = this\n\n API.fire(this, 'beforeShow')\n\n this.showing = true\n\n if (this.closing) {\n this.showing = false\n return this\n }\n\n API.build(this)\n API.handleModal(this)\n\n if (this.options.force) {\n this.layoutDom.insertBefore(this.barDom, this.layoutDom.firstChild)\n } else {\n this.layoutDom.appendChild(this.barDom)\n }\n\n if (\n this.hasSound &&\n !this.soundPlayed &&\n Utils.inArray('docVisible', this.options.sounds.conditions)\n ) {\n Utils.createAudioElements(this)\n }\n\n if (Utils.inArray('docVisible', this.options.titleCount.conditions)) {\n API.docTitle.increment()\n }\n\n this.shown = true\n this.closed = false\n\n // bind button events if any\n if (API.hasButtons(this)) {\n Object.keys(this.options.buttons).forEach(key => {\n const btn = this.barDom.querySelector(\n `#${this.options.buttons[key].id}`\n )\n Utils.addListener(btn, 'click', e => {\n Utils.stopPropagation(e)\n this.options.buttons[key].cb(this)\n })\n })\n }\n\n this.progressDom = this.barDom.querySelector('.noty_progressbar')\n\n if (Utils.inArray('click', this.options.closeWith)) {\n Utils.addClass(this.barDom, 'noty_close_with_click')\n Utils.addListener(\n this.barDom,\n 'click',\n e => {\n Utils.stopPropagation(e)\n API.fire(this, 'onClick')\n this.close()\n },\n false\n )\n }\n\n Utils.addListener(\n this.barDom,\n 'mouseenter',\n () => {\n API.fire(this, 'onHover')\n },\n false\n )\n\n if (this.options.timeout) Utils.addClass(this.barDom, 'noty_has_timeout')\n if (this.options.progressBar) {\n Utils.addClass(this.barDom, 'noty_has_progressbar')\n }\n\n if (Utils.inArray('button', this.options.closeWith)) {\n Utils.addClass(this.barDom, 'noty_close_with_button')\n\n const closeButton = document.createElement('div')\n Utils.addClass(closeButton, 'noty_close_button')\n closeButton.innerHTML = '×'\n this.barDom.appendChild(closeButton)\n\n Utils.addListener(\n closeButton,\n 'click',\n e => {\n Utils.stopPropagation(e)\n this.close()\n },\n false\n )\n }\n\n API.fire(this, 'onShow')\n\n if (this.options.animation.open === null) {\n this.promises.show = new Promise(resolve => {\n resolve()\n })\n } else if (typeof this.options.animation.open === 'function') {\n this.promises.show = new Promise(this.options.animation.open.bind(this))\n } else {\n Utils.addClass(this.barDom, this.options.animation.open)\n this.promises.show = new Promise(resolve => {\n Utils.addListener(this.barDom, Utils.animationEndEvents, () => {\n Utils.removeClass(this.barDom, this.options.animation.open)\n resolve()\n })\n })\n }\n\n this.promises.show.then(() => {\n const _t = this\n setTimeout(\n () => {\n API.openFlow(_t)\n },\n 100\n )\n })\n\n return this\n }\n\n /**\n * @return {Noty}\n */\n stop () {\n API.dequeueClose(this)\n return this\n }\n\n /**\n * @return {Noty}\n */\n resume () {\n API.queueClose(this)\n return this\n }\n\n /**\n * @param {int|boolean} ms\n * @return {Noty}\n */\n setTimeout (ms) {\n this.stop()\n this.options.timeout = ms\n\n if (this.barDom) {\n if (this.options.timeout) {\n Utils.addClass(this.barDom, 'noty_has_timeout')\n } else {\n Utils.removeClass(this.barDom, 'noty_has_timeout')\n }\n\n const _t = this\n setTimeout(\n function () {\n // ugly fix for progressbar display bug\n _t.resume()\n },\n 100\n )\n }\n\n return this\n }\n\n /**\n * @param {string} html\n * @param {boolean} optionsOverride\n * @return {Noty}\n */\n setText (html, optionsOverride = false) {\n if (this.barDom) {\n this.barDom.querySelector('.noty_body').innerHTML = html\n }\n\n if (optionsOverride) this.options.text = html\n\n return this\n }\n\n /**\n * @param {string} type\n * @param {boolean} optionsOverride\n * @return {Noty}\n */\n setType (type, optionsOverride = false) {\n if (this.barDom) {\n let classList = Utils.classList(this.barDom).split(' ')\n\n classList.forEach(c => {\n if (c.substring(0, 11) === 'noty_type__') {\n Utils.removeClass(this.barDom, c)\n }\n })\n\n Utils.addClass(this.barDom, `noty_type__${type}`)\n }\n\n if (optionsOverride) this.options.type = type\n\n return this\n }\n\n /**\n * @param {string} theme\n * @param {boolean} optionsOverride\n * @return {Noty}\n */\n setTheme (theme, optionsOverride = false) {\n if (this.barDom) {\n let classList = Utils.classList(this.barDom).split(' ')\n\n classList.forEach(c => {\n if (c.substring(0, 12) === 'noty_theme__') {\n Utils.removeClass(this.barDom, c)\n }\n })\n\n Utils.addClass(this.barDom, `noty_theme__${theme}`)\n }\n\n if (optionsOverride) this.options.theme = theme\n\n return this\n }\n\n /**\n * @return {Noty}\n */\n close () {\n if (this.closed) return this\n\n if (!this.shown) {\n // it's in the queue\n API.removeFromQueue(this)\n return this\n }\n\n API.fire(this, 'onClose')\n\n this.closing = true\n\n if (this.options.animation.close === null || this.options.animation.close === false) {\n this.promises.close = new Promise(resolve => {\n resolve()\n })\n } else if (typeof this.options.animation.close === 'function') {\n this.promises.close = new Promise(\n this.options.animation.close.bind(this)\n )\n } else {\n Utils.addClass(this.barDom, this.options.animation.close)\n this.promises.close = new Promise(resolve => {\n Utils.addListener(this.barDom, Utils.animationEndEvents, () => {\n if (this.options.force) {\n Utils.remove(this.barDom)\n } else {\n API.ghostFix(this)\n }\n resolve()\n })\n })\n }\n\n this.promises.close.then(() => {\n API.closeFlow(this)\n API.handleModalClose(this)\n })\n\n this.closed = true\n\n return this\n }\n\n // API functions\n\n /**\n * @param {boolean|string} queueName\n * @return {Noty}\n */\n static closeAll (queueName = false) {\n Object.keys(API.Store).forEach(id => {\n if (queueName) {\n if (\n API.Store[id].options.queue === queueName && API.Store[id].killable\n ) {\n API.Store[id].close()\n }\n } else if (API.Store[id].killable) {\n API.Store[id].close()\n }\n })\n return this\n }\n\n /**\n * @param {string} queueName\n * @return {Noty}\n */\n static clearQueue (queueName = 'global') {\n if (API.Queues.hasOwnProperty(queueName)) {\n API.Queues[queueName].queue = []\n }\n return this\n }\n\n /**\n * @return {API.Queues}\n */\n static get Queues () {\n return API.Queues\n }\n\n /**\n * @return {API.PageHidden}\n */\n static get PageHidden () {\n return API.PageHidden\n }\n\n /**\n * @param {Object} obj\n * @return {Noty}\n */\n static overrideDefaults (obj) {\n API.Defaults = Utils.deepExtend({}, API.Defaults, obj)\n return this\n }\n\n /**\n * @param {int} amount\n * @param {string} queueName\n * @return {Noty}\n */\n static setMaxVisible (amount = API.DefaultMaxVisible, queueName = 'global') {\n if (!API.Queues.hasOwnProperty(queueName)) {\n API.Queues[queueName] = {maxVisible: amount, queue: []}\n }\n\n API.Queues[queueName].maxVisible = amount\n return this\n }\n\n /**\n * @param {string} innerHtml\n * @param {String} classes\n * @param {Function} cb\n * @param {Object} attributes\n * @return {NotyButton}\n */\n static button (innerHtml, classes = null, cb, attributes = {}) {\n return new NotyButton(innerHtml, classes, cb, attributes)\n }\n\n /**\n * @return {string}\n */\n static version () {\n return VERSION\n }\n\n /**\n * @param {String} workerPath\n * @return {Push}\n */\n static Push (workerPath) {\n return new Push(workerPath)\n }\n}\n\n// Document visibility change controller\nif (typeof window !== 'undefined') {\n Utils.visibilityChangeFlow()\n}\n\n\n\n// WEBPACK FOOTER //\n// ./src/index.js","// shim for using process in browser\nvar process = module.exports = {};\n\n// cached from whatever global is present so that test runners that stub it\n// don't break things. But we need to wrap it in a try catch in case it is\n// wrapped in strict mode code which doesn't define any globals. It's inside a\n// function because try/catches deoptimize in certain engines.\n\nvar cachedSetTimeout;\nvar cachedClearTimeout;\n\nfunction defaultSetTimout() {\n throw new Error('setTimeout has not been defined');\n}\nfunction defaultClearTimeout () {\n throw new Error('clearTimeout has not been defined');\n}\n(function () {\n try {\n if (typeof setTimeout === 'function') {\n cachedSetTimeout = setTimeout;\n } else {\n cachedSetTimeout = defaultSetTimout;\n }\n } catch (e) {\n cachedSetTimeout = defaultSetTimout;\n }\n try {\n if (typeof clearTimeout === 'function') {\n cachedClearTimeout = clearTimeout;\n } else {\n cachedClearTimeout = defaultClearTimeout;\n }\n } catch (e) {\n cachedClearTimeout = defaultClearTimeout;\n }\n} ())\nfunction runTimeout(fun) {\n if (cachedSetTimeout === setTimeout) {\n //normal enviroments in sane situations\n return setTimeout(fun, 0);\n }\n // if setTimeout wasn't available but was latter defined\n if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {\n cachedSetTimeout = setTimeout;\n return setTimeout(fun, 0);\n }\n try {\n // when when somebody has screwed with setTimeout but no I.E. maddness\n return cachedSetTimeout(fun, 0);\n } catch(e){\n try {\n // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally\n return cachedSetTimeout.call(null, fun, 0);\n } catch(e){\n // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error\n return cachedSetTimeout.call(this, fun, 0);\n }\n }\n\n\n}\nfunction runClearTimeout(marker) {\n if (cachedClearTimeout === clearTimeout) {\n //normal enviroments in sane situations\n return clearTimeout(marker);\n }\n // if clearTimeout wasn't available but was latter defined\n if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {\n cachedClearTimeout = clearTimeout;\n return clearTimeout(marker);\n }\n try {\n // when when somebody has screwed with setTimeout but no I.E. maddness\n return cachedClearTimeout(marker);\n } catch (e){\n try {\n // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally\n return cachedClearTimeout.call(null, marker);\n } catch (e){\n // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.\n // Some versions of I.E. have different rules for clearTimeout vs setTimeout\n return cachedClearTimeout.call(this, marker);\n }\n }\n\n\n\n}\nvar queue = [];\nvar draining = false;\nvar currentQueue;\nvar queueIndex = -1;\n\nfunction cleanUpNextTick() {\n if (!draining || !currentQueue) {\n return;\n }\n draining = false;\n if (currentQueue.length) {\n queue = currentQueue.concat(queue);\n } else {\n queueIndex = -1;\n }\n if (queue.length) {\n drainQueue();\n }\n}\n\nfunction drainQueue() {\n if (draining) {\n return;\n }\n var timeout = runTimeout(cleanUpNextTick);\n draining = true;\n\n var len = queue.length;\n while(len) {\n currentQueue = queue;\n queue = [];\n while (++queueIndex < len) {\n if (currentQueue) {\n currentQueue[queueIndex].run();\n }\n }\n queueIndex = -1;\n len = queue.length;\n }\n currentQueue = null;\n draining = false;\n runClearTimeout(timeout);\n}\n\nprocess.nextTick = function (fun) {\n var args = new Array(arguments.length - 1);\n if (arguments.length > 1) {\n for (var i = 1; i < arguments.length; i++) {\n args[i - 1] = arguments[i];\n }\n }\n queue.push(new Item(fun, args));\n if (queue.length === 1 && !draining) {\n runTimeout(drainQueue);\n }\n};\n\n// v8 likes predictible objects\nfunction Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}\nItem.prototype.run = function () {\n this.fun.apply(null, this.array);\n};\nprocess.title = 'browser';\nprocess.browser = true;\nprocess.env = {};\nprocess.argv = [];\nprocess.version = ''; // empty string to avoid regexp issues\nprocess.versions = {};\n\nfunction noop() {}\n\nprocess.on = noop;\nprocess.addListener = noop;\nprocess.once = noop;\nprocess.off = noop;\nprocess.removeListener = noop;\nprocess.removeAllListeners = noop;\nprocess.emit = noop;\nprocess.prependListener = noop;\nprocess.prependOnceListener = noop;\n\nprocess.listeners = function (name) { return [] }\n\nprocess.binding = function (name) {\n throw new Error('process.binding is not supported');\n};\n\nprocess.cwd = function () { return '/' };\nprocess.chdir = function (dir) {\n throw new Error('process.chdir is not supported');\n};\nprocess.umask = function() { return 0; };\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/process/browser.js\n// module id = 7\n// module chunks = 0","var g;\r\n\r\n// This works in non-strict mode\r\ng = (function() {\r\n\treturn this;\r\n})();\r\n\r\ntry {\r\n\t// This works if eval is allowed (see CSP)\r\n\tg = g || Function(\"return this\")() || (1,eval)(\"this\");\r\n} catch(e) {\r\n\t// This works if the window reference is available\r\n\tif(typeof window === \"object\")\r\n\t\tg = window;\r\n}\r\n\r\n// g can still be undefined, but nothing to do about it...\r\n// We return undefined, instead of nothing here, so it's\r\n// easier to handle this case. if(!global) { ...}\r\n\r\nmodule.exports = g;\r\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// (webpack)/buildin/global.js\n// module id = 8\n// module chunks = 0"],"sourceRoot":""}
\ No newline at end of file
diff --git a/node_modules/noty/lib/themes/bootstrap-v3.css b/node_modules/noty/lib/themes/bootstrap-v3.css
new file mode 100644
index 0000000..4879868
--- /dev/null
+++ b/node_modules/noty/lib/themes/bootstrap-v3.css
@@ -0,0 +1,51 @@
+.noty_theme__bootstrap-v3.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ position: relative;
+ border: 1px solid transparent;
+ border-radius: 4px; }
+ .noty_theme__bootstrap-v3.noty_bar .noty_body {
+ padding: 15px; }
+ .noty_theme__bootstrap-v3.noty_bar .noty_buttons {
+ padding: 10px; }
+ .noty_theme__bootstrap-v3.noty_bar .noty_close_button {
+ font-size: 21px;
+ font-weight: 700;
+ line-height: 1;
+ color: #000;
+ text-shadow: 0 1px 0 #fff;
+ filter: alpha(opacity=20);
+ opacity: .2;
+ background: transparent; }
+ .noty_theme__bootstrap-v3.noty_bar .noty_close_button:hover {
+ background: transparent;
+ text-decoration: none;
+ cursor: pointer;
+ filter: alpha(opacity=50);
+ opacity: .5; }
+
+.noty_theme__bootstrap-v3.noty_type__alert,
+.noty_theme__bootstrap-v3.noty_type__notification {
+ background-color: #fff;
+ color: inherit; }
+
+.noty_theme__bootstrap-v3.noty_type__warning {
+ background-color: #fcf8e3;
+ color: #8a6d3b;
+ border-color: #faebcc; }
+
+.noty_theme__bootstrap-v3.noty_type__error {
+ background-color: #f2dede;
+ color: #a94442;
+ border-color: #ebccd1; }
+
+.noty_theme__bootstrap-v3.noty_type__info,
+.noty_theme__bootstrap-v3.noty_type__information {
+ background-color: #d9edf7;
+ color: #31708f;
+ border-color: #bce8f1; }
+
+.noty_theme__bootstrap-v3.noty_type__success {
+ background-color: #dff0d8;
+ color: #3c763d;
+ border-color: #d6e9c6; }
diff --git a/node_modules/noty/lib/themes/bootstrap-v4.css b/node_modules/noty/lib/themes/bootstrap-v4.css
new file mode 100644
index 0000000..026fc6e
--- /dev/null
+++ b/node_modules/noty/lib/themes/bootstrap-v4.css
@@ -0,0 +1,51 @@
+.noty_theme__bootstrap-v4.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ position: relative;
+ border: 1px solid transparent;
+ border-radius: .25rem; }
+ .noty_theme__bootstrap-v4.noty_bar .noty_body {
+ padding: .75rem 1.25rem; }
+ .noty_theme__bootstrap-v4.noty_bar .noty_buttons {
+ padding: 10px; }
+ .noty_theme__bootstrap-v4.noty_bar .noty_close_button {
+ font-size: 1.5rem;
+ font-weight: 700;
+ line-height: 1;
+ color: #000;
+ text-shadow: 0 1px 0 #fff;
+ filter: alpha(opacity=20);
+ opacity: .5;
+ background: transparent; }
+ .noty_theme__bootstrap-v4.noty_bar .noty_close_button:hover {
+ background: transparent;
+ text-decoration: none;
+ cursor: pointer;
+ filter: alpha(opacity=50);
+ opacity: .75; }
+
+.noty_theme__bootstrap-v4.noty_type__alert,
+.noty_theme__bootstrap-v4.noty_type__notification {
+ background-color: #fff;
+ color: inherit; }
+
+.noty_theme__bootstrap-v4.noty_type__warning {
+ background-color: #fcf8e3;
+ color: #8a6d3b;
+ border-color: #faebcc; }
+
+.noty_theme__bootstrap-v4.noty_type__error {
+ background-color: #f2dede;
+ color: #a94442;
+ border-color: #ebccd1; }
+
+.noty_theme__bootstrap-v4.noty_type__info,
+.noty_theme__bootstrap-v4.noty_type__information {
+ background-color: #d9edf7;
+ color: #31708f;
+ border-color: #bce8f1; }
+
+.noty_theme__bootstrap-v4.noty_type__success {
+ background-color: #dff0d8;
+ color: #3c763d;
+ border-color: #d6e9c6; }
diff --git a/node_modules/noty/lib/themes/light.css b/node_modules/noty/lib/themes/light.css
new file mode 100644
index 0000000..17785bb
--- /dev/null
+++ b/node_modules/noty/lib/themes/light.css
@@ -0,0 +1,46 @@
+.noty_theme__light.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ border-radius: 2px;
+ position: relative; }
+ .noty_theme__light.noty_bar .noty_body {
+ padding: 10px; }
+ .noty_theme__light.noty_bar .noty_buttons {
+ border-top: 1px solid #e7e7e7;
+ padding: 5px 10px; }
+
+.noty_theme__light.noty_type__alert,
+.noty_theme__light.noty_type__notification {
+ background-color: #fff;
+ border: 1px solid #dedede;
+ color: #444; }
+
+.noty_theme__light.noty_type__warning {
+ background-color: #FFEAA8;
+ border: 1px solid #FFC237;
+ color: #826200; }
+ .noty_theme__light.noty_type__warning .noty_buttons {
+ border-color: #dfaa30; }
+
+.noty_theme__light.noty_type__error {
+ background-color: #ED7000;
+ border: 1px solid #e25353;
+ color: #FFF; }
+ .noty_theme__light.noty_type__error .noty_buttons {
+ border-color: darkred; }
+
+.noty_theme__light.noty_type__info,
+.noty_theme__light.noty_type__information {
+ background-color: #78C5E7;
+ border: 1px solid #3badd6;
+ color: #FFF; }
+ .noty_theme__light.noty_type__info .noty_buttons,
+ .noty_theme__light.noty_type__information .noty_buttons {
+ border-color: #0B90C4; }
+
+.noty_theme__light.noty_type__success {
+ background-color: #57C880;
+ border: 1px solid #7cdd77;
+ color: darkgreen; }
+ .noty_theme__light.noty_type__success .noty_buttons {
+ border-color: #50C24E; }
diff --git a/node_modules/noty/lib/themes/metroui.css b/node_modules/noty/lib/themes/metroui.css
new file mode 100644
index 0000000..d8406c8
--- /dev/null
+++ b/node_modules/noty/lib/themes/metroui.css
@@ -0,0 +1,41 @@
+.noty_theme__metroui.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ position: relative;
+ box-shadow: rgba(0, 0, 0, 0.298039) 0 0 5px 0; }
+ .noty_theme__metroui.noty_bar .noty_progressbar {
+ position: absolute;
+ left: 0;
+ bottom: 0;
+ height: 3px;
+ width: 100%;
+ background-color: #000;
+ opacity: 0.2;
+ filter: alpha(opacity=20); }
+ .noty_theme__metroui.noty_bar .noty_body {
+ padding: 1.25em;
+ font-size: 14px; }
+ .noty_theme__metroui.noty_bar .noty_buttons {
+ padding: 0 10px .5em 10px; }
+
+.noty_theme__metroui.noty_type__alert,
+.noty_theme__metroui.noty_type__notification {
+ background-color: #fff;
+ color: #1d1d1d; }
+
+.noty_theme__metroui.noty_type__warning {
+ background-color: #FA6800;
+ color: #fff; }
+
+.noty_theme__metroui.noty_type__error {
+ background-color: #CE352C;
+ color: #FFF; }
+
+.noty_theme__metroui.noty_type__info,
+.noty_theme__metroui.noty_type__information {
+ background-color: #1BA1E2;
+ color: #FFF; }
+
+.noty_theme__metroui.noty_type__success {
+ background-color: #60A917;
+ color: #fff; }
diff --git a/node_modules/noty/lib/themes/mint.css b/node_modules/noty/lib/themes/mint.css
new file mode 100644
index 0000000..5d33b8c
--- /dev/null
+++ b/node_modules/noty/lib/themes/mint.css
@@ -0,0 +1,37 @@
+.noty_theme__mint.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ border-radius: 2px;
+ position: relative; }
+ .noty_theme__mint.noty_bar .noty_body {
+ padding: 10px;
+ font-size: 14px; }
+ .noty_theme__mint.noty_bar .noty_buttons {
+ padding: 10px; }
+
+.noty_theme__mint.noty_type__alert,
+.noty_theme__mint.noty_type__notification {
+ background-color: #fff;
+ border-bottom: 1px solid #D1D1D1;
+ color: #2F2F2F; }
+
+.noty_theme__mint.noty_type__warning {
+ background-color: #FFAE42;
+ border-bottom: 1px solid #E89F3C;
+ color: #fff; }
+
+.noty_theme__mint.noty_type__error {
+ background-color: #DE636F;
+ border-bottom: 1px solid #CA5A65;
+ color: #fff; }
+
+.noty_theme__mint.noty_type__info,
+.noty_theme__mint.noty_type__information {
+ background-color: #7F7EFF;
+ border-bottom: 1px solid #7473E8;
+ color: #fff; }
+
+.noty_theme__mint.noty_type__success {
+ background-color: #AFC765;
+ border-bottom: 1px solid #A0B55C;
+ color: #fff; }
diff --git a/node_modules/noty/lib/themes/nest.css b/node_modules/noty/lib/themes/nest.css
new file mode 100644
index 0000000..acbdad5
--- /dev/null
+++ b/node_modules/noty/lib/themes/nest.css
@@ -0,0 +1,120 @@
+.noty_theme__nest.noty_bar {
+ margin: 0 0 15px 0;
+ overflow: hidden;
+ border-radius: 2px;
+ position: relative;
+ box-shadow: rgba(0, 0, 0, 0.098039) 5px 4px 10px 0; }
+ .noty_theme__nest.noty_bar .noty_body {
+ padding: 10px;
+ font-size: 14px;
+ text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.1); }
+ .noty_theme__nest.noty_bar .noty_buttons {
+ padding: 10px; }
+
+.noty_layout .noty_theme__nest.noty_bar {
+ z-index: 5; }
+
+.noty_layout .noty_theme__nest.noty_bar:nth-child(2) {
+ position: absolute;
+ top: 0;
+ margin-top: 4px;
+ margin-right: -4px;
+ margin-left: 4px;
+ z-index: 4;
+ width: 100%; }
+
+.noty_layout .noty_theme__nest.noty_bar:nth-child(3) {
+ position: absolute;
+ top: 0;
+ margin-top: 8px;
+ margin-right: -8px;
+ margin-left: 8px;
+ z-index: 3;
+ width: 100%; }
+
+.noty_layout .noty_theme__nest.noty_bar:nth-child(4) {
+ position: absolute;
+ top: 0;
+ margin-top: 12px;
+ margin-right: -12px;
+ margin-left: 12px;
+ z-index: 2;
+ width: 100%; }
+
+.noty_layout .noty_theme__nest.noty_bar:nth-child(5) {
+ position: absolute;
+ top: 0;
+ margin-top: 16px;
+ margin-right: -16px;
+ margin-left: 16px;
+ z-index: 1;
+ width: 100%; }
+
+.noty_layout .noty_theme__nest.noty_bar:nth-child(n+6) {
+ position: absolute;
+ top: 0;
+ margin-top: 20px;
+ margin-right: -20px;
+ margin-left: 20px;
+ z-index: -1;
+ width: 100%; }
+
+#noty_layout__bottomLeft .noty_theme__nest.noty_bar:nth-child(2),
+#noty_layout__topLeft .noty_theme__nest.noty_bar:nth-child(2) {
+ margin-top: 4px;
+ margin-left: -4px;
+ margin-right: 4px; }
+
+#noty_layout__bottomLeft .noty_theme__nest.noty_bar:nth-child(3),
+#noty_layout__topLeft .noty_theme__nest.noty_bar:nth-child(3) {
+ margin-top: 8px;
+ margin-left: -8px;
+ margin-right: 8px; }
+
+#noty_layout__bottomLeft .noty_theme__nest.noty_bar:nth-child(4),
+#noty_layout__topLeft .noty_theme__nest.noty_bar:nth-child(4) {
+ margin-top: 12px;
+ margin-left: -12px;
+ margin-right: 12px; }
+
+#noty_layout__bottomLeft .noty_theme__nest.noty_bar:nth-child(5),
+#noty_layout__topLeft .noty_theme__nest.noty_bar:nth-child(5) {
+ margin-top: 16px;
+ margin-left: -16px;
+ margin-right: 16px; }
+
+#noty_layout__bottomLeft .noty_theme__nest.noty_bar:nth-child(n+6),
+#noty_layout__topLeft .noty_theme__nest.noty_bar:nth-child(n+6) {
+ margin-top: 20px;
+ margin-left: -20px;
+ margin-right: 20px; }
+
+.noty_theme__nest.noty_type__alert,
+.noty_theme__nest.noty_type__notification {
+ background-color: #073B4C;
+ color: #fff; }
+ .noty_theme__nest.noty_type__alert .noty_progressbar,
+ .noty_theme__nest.noty_type__notification .noty_progressbar {
+ background-color: #fff; }
+
+.noty_theme__nest.noty_type__warning {
+ background-color: #FFD166;
+ color: #fff; }
+
+.noty_theme__nest.noty_type__error {
+ background-color: #EF476F;
+ color: #fff; }
+ .noty_theme__nest.noty_type__error .noty_progressbar {
+ opacity: .4; }
+
+.noty_theme__nest.noty_type__info,
+.noty_theme__nest.noty_type__information {
+ background-color: #118AB2;
+ color: #fff; }
+ .noty_theme__nest.noty_type__info .noty_progressbar,
+ .noty_theme__nest.noty_type__information .noty_progressbar {
+ opacity: .6; }
+
+.noty_theme__nest.noty_type__success {
+ background-color: #06D6A0;
+ color: #fff; }
diff --git a/node_modules/noty/lib/themes/relax.css b/node_modules/noty/lib/themes/relax.css
new file mode 100644
index 0000000..f5f99ec
--- /dev/null
+++ b/node_modules/noty/lib/themes/relax.css
@@ -0,0 +1,46 @@
+.noty_theme__relax.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ border-radius: 2px;
+ position: relative; }
+ .noty_theme__relax.noty_bar .noty_body {
+ padding: 10px; }
+ .noty_theme__relax.noty_bar .noty_buttons {
+ border-top: 1px solid #e7e7e7;
+ padding: 5px 10px; }
+
+.noty_theme__relax.noty_type__alert,
+.noty_theme__relax.noty_type__notification {
+ background-color: #fff;
+ border: 1px solid #dedede;
+ color: #444; }
+
+.noty_theme__relax.noty_type__warning {
+ background-color: #FFEAA8;
+ border: 1px solid #FFC237;
+ color: #826200; }
+ .noty_theme__relax.noty_type__warning .noty_buttons {
+ border-color: #dfaa30; }
+
+.noty_theme__relax.noty_type__error {
+ background-color: #FF8181;
+ border: 1px solid #e25353;
+ color: #FFF; }
+ .noty_theme__relax.noty_type__error .noty_buttons {
+ border-color: darkred; }
+
+.noty_theme__relax.noty_type__info,
+.noty_theme__relax.noty_type__information {
+ background-color: #78C5E7;
+ border: 1px solid #3badd6;
+ color: #FFF; }
+ .noty_theme__relax.noty_type__info .noty_buttons,
+ .noty_theme__relax.noty_type__information .noty_buttons {
+ border-color: #0B90C4; }
+
+.noty_theme__relax.noty_type__success {
+ background-color: #BCF5BC;
+ border: 1px solid #7cdd77;
+ color: darkgreen; }
+ .noty_theme__relax.noty_type__success .noty_buttons {
+ border-color: #50C24E; }
diff --git a/node_modules/noty/lib/themes/semanticui.css b/node_modules/noty/lib/themes/semanticui.css
new file mode 100644
index 0000000..d0005f1
--- /dev/null
+++ b/node_modules/noty/lib/themes/semanticui.css
@@ -0,0 +1,39 @@
+.noty_theme__semanticui.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ position: relative;
+ border: 1px solid transparent;
+ font-size: 1em;
+ border-radius: .28571429rem;
+ box-shadow: 0 0 0 1px rgba(34, 36, 38, 0.22) inset, 0 0 0 0 transparent; }
+ .noty_theme__semanticui.noty_bar .noty_body {
+ padding: 1em 1.5em;
+ line-height: 1.4285em; }
+ .noty_theme__semanticui.noty_bar .noty_buttons {
+ padding: 10px; }
+
+.noty_theme__semanticui.noty_type__alert,
+.noty_theme__semanticui.noty_type__notification {
+ background-color: #f8f8f9;
+ color: rgba(0, 0, 0, 0.87); }
+
+.noty_theme__semanticui.noty_type__warning {
+ background-color: #fffaf3;
+ color: #573a08;
+ box-shadow: 0 0 0 1px #c9ba9b inset, 0 0 0 0 transparent; }
+
+.noty_theme__semanticui.noty_type__error {
+ background-color: #fff6f6;
+ color: #9f3a38;
+ box-shadow: 0 0 0 1px #e0b4b4 inset, 0 0 0 0 transparent; }
+
+.noty_theme__semanticui.noty_type__info,
+.noty_theme__semanticui.noty_type__information {
+ background-color: #f8ffff;
+ color: #276f86;
+ box-shadow: 0 0 0 1px #a9d5de inset, 0 0 0 0 transparent; }
+
+.noty_theme__semanticui.noty_type__success {
+ background-color: #fcfff5;
+ color: #2c662d;
+ box-shadow: 0 0 0 1px #a3c293 inset, 0 0 0 0 transparent; }
diff --git a/node_modules/noty/lib/themes/sunset.css b/node_modules/noty/lib/themes/sunset.css
new file mode 100644
index 0000000..0ebd0c2
--- /dev/null
+++ b/node_modules/noty/lib/themes/sunset.css
@@ -0,0 +1,41 @@
+.noty_theme__sunset.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ border-radius: 2px;
+ position: relative; }
+ .noty_theme__sunset.noty_bar .noty_body {
+ padding: 10px;
+ font-size: 14px;
+ text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.1); }
+ .noty_theme__sunset.noty_bar .noty_buttons {
+ padding: 10px; }
+
+.noty_theme__sunset.noty_type__alert,
+.noty_theme__sunset.noty_type__notification {
+ background-color: #073B4C;
+ color: #fff; }
+ .noty_theme__sunset.noty_type__alert .noty_progressbar,
+ .noty_theme__sunset.noty_type__notification .noty_progressbar {
+ background-color: #fff; }
+
+.noty_theme__sunset.noty_type__warning {
+ background-color: #FFD166;
+ color: #fff; }
+
+.noty_theme__sunset.noty_type__error {
+ background-color: #EF476F;
+ color: #fff; }
+ .noty_theme__sunset.noty_type__error .noty_progressbar {
+ opacity: .4; }
+
+.noty_theme__sunset.noty_type__info,
+.noty_theme__sunset.noty_type__information {
+ background-color: #118AB2;
+ color: #fff; }
+ .noty_theme__sunset.noty_type__info .noty_progressbar,
+ .noty_theme__sunset.noty_type__information .noty_progressbar {
+ opacity: .6; }
+
+.noty_theme__sunset.noty_type__success {
+ background-color: #06D6A0;
+ color: #fff; }
diff --git a/node_modules/noty/package.json b/node_modules/noty/package.json
new file mode 100644
index 0000000..b2371b7
--- /dev/null
+++ b/node_modules/noty/package.json
@@ -0,0 +1,121 @@
+{
+ "_from": "noty",
+ "_id": "noty@3.2.0-beta",
+ "_inBundle": false,
+ "_integrity": "sha512-a1//Rth1MTQ/GCvGzwBXrZqCwOPyxiIKMdHT1TlcdrDYBYVfb7vzwsU0N4x+j/HeIQTi6/pbP8lRtY9gBz/d3Q==",
+ "_location": "/noty",
+ "_phantomChildren": {},
+ "_requested": {
+ "type": "tag",
+ "registry": true,
+ "raw": "noty",
+ "name": "noty",
+ "escapedName": "noty",
+ "rawSpec": "",
+ "saveSpec": null,
+ "fetchSpec": "latest"
+ },
+ "_requiredBy": [
+ "#USER",
+ "/"
+ ],
+ "_resolved": "https://registry.npmjs.org/noty/-/noty-3.2.0-beta.tgz",
+ "_shasum": "cd1117277a1b83c9b08dfc78f968c6c5960d3cfa",
+ "_spec": "noty",
+ "_where": "D:\\Projects\\vanillajs-seed",
+ "author": {
+ "name": "Nedim Arabacı",
+ "url": "http://ned.im"
+ },
+ "bugs": {
+ "url": "https://github.com/needim/noty/issues"
+ },
+ "bundleDependencies": false,
+ "deprecated": false,
+ "description": "Noty is a dependency-free notification library that makes it easy to create alert - success - error - warning - information - confirmation messages as an alternative the standard alert dialog. Each notification is added to a queue. (Optional)",
+ "devDependencies": {
+ "autoprefixer": "^6.3.6",
+ "babel-core": "6.24.1",
+ "babel-eslint": "7.2.2",
+ "babel-loader": "6.4.1",
+ "babel-plugin-add-module-exports": "0.2.1",
+ "babel-preset-es2015": "6.24.1",
+ "browser-sync": "^2.19.0",
+ "browser-sync-webpack-plugin": "^1.2.0",
+ "browserstack-runner": "^0.5.2",
+ "css-loader": "^0.26.0",
+ "docsify-cli": "^4.1.9",
+ "es6-promise": "^4.1.0",
+ "eslint": "^4.3.0",
+ "eslint-loader": "1.9.0",
+ "extract-text-webpack-plugin": "2.1.0",
+ "grunt": "^1.0.1",
+ "grunt-banner": "^0.6.0",
+ "grunt-contrib-connect": "^1.0.2",
+ "grunt-contrib-qunit": "^2.0.0",
+ "grunt-curl": "^2.2.1",
+ "grunt-exec": "^2.0.0",
+ "grunt-sass": "^2.0.0",
+ "load-grunt-tasks": "^3.5.2",
+ "node-sass": "^4.1.0",
+ "postcss-loader": "^1.0.0",
+ "pre-commit": "^1.2.2",
+ "prettier-standard": "^3.0.1",
+ "sass-loader": "^4.0.1",
+ "standard": "^10.0.2",
+ "standard-loader": "^6.0.1",
+ "style-loader": "^0.13.1",
+ "web-push": "^3.2.2",
+ "webpack": "2.4.1",
+ "yargs": "7.0.2"
+ },
+ "files": [
+ "lib",
+ "src",
+ "index.d.ts"
+ ],
+ "homepage": "https://ned.im/noty",
+ "keywords": [
+ "noty",
+ "notification",
+ "alert",
+ "confirm",
+ "confirmation",
+ "success",
+ "error",
+ "warning",
+ "information"
+ ],
+ "license": "MIT",
+ "main": "lib/noty.js",
+ "name": "noty",
+ "pre-commit": [
+ "precommit-msg",
+ "test"
+ ],
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/needim/noty.git"
+ },
+ "scripts": {
+ "browserstack": "browserstack-runner",
+ "build": "grunt themes && webpack --env dev && webpack --env build && grunt banner",
+ "dev": "grunt themes && webpack --progress --colors --watch --env dev",
+ "format": "prettier-standard 'src/**/*.js'",
+ "precommit-msg": "echo 'Pre-commit checks...' && exit 0",
+ "serve-docs": "docsify start ./docs",
+ "test": "npm run format && standard && grunt test"
+ },
+ "standard": {
+ "ignore": [
+ "demo/**/*",
+ "docs/**/*",
+ "lib/**",
+ "test/**"
+ ],
+ "parser": "babel-eslint"
+ },
+ "title": "Noty - Dependency-free notification library",
+ "types": "index.d.ts",
+ "version": "3.2.0-beta"
+}
diff --git a/node_modules/noty/src/api.js b/node_modules/noty/src/api.js
new file mode 100644
index 0000000..cdd8c51
--- /dev/null
+++ b/node_modules/noty/src/api.js
@@ -0,0 +1,419 @@
+import * as Utils from 'utils'
+
+export let PageHidden = false
+export let DocModalCount = 0
+
+const DocTitleProps = {
+ originalTitle: null,
+ count: 0,
+ changed: false,
+ timer: -1
+}
+
+export const docTitle = {
+ increment: () => {
+ DocTitleProps.count++
+
+ docTitle._update()
+ },
+
+ decrement: () => {
+ DocTitleProps.count--
+
+ if (DocTitleProps.count <= 0) {
+ docTitle._clear()
+ return
+ }
+
+ docTitle._update()
+ },
+
+ _update: () => {
+ let title = document.title
+
+ if (!DocTitleProps.changed) {
+ DocTitleProps.originalTitle = title
+ document.title = `(${DocTitleProps.count}) ${title}`
+ DocTitleProps.changed = true
+ } else {
+ document.title = `(${DocTitleProps.count}) ${DocTitleProps.originalTitle}`
+ }
+ },
+
+ _clear: () => {
+ if (DocTitleProps.changed) {
+ DocTitleProps.count = 0
+ document.title = DocTitleProps.originalTitle
+ DocTitleProps.changed = false
+ }
+ }
+}
+
+export const DefaultMaxVisible = 5
+
+export const Queues = {
+ global: {
+ maxVisible: DefaultMaxVisible,
+ queue: []
+ }
+}
+
+export const Store = {}
+
+export let Defaults = {
+ type: 'alert',
+ layout: 'topRight',
+ theme: 'mint',
+ text: '',
+ timeout: false,
+ progressBar: true,
+ closeWith: ['click'],
+ animation: {
+ open: 'noty_effects_open',
+ close: 'noty_effects_close'
+ },
+ id: false,
+ force: false,
+ killer: false,
+ queue: 'global',
+ container: false,
+ buttons: [],
+ callbacks: {
+ beforeShow: null,
+ onShow: null,
+ afterShow: null,
+ onClose: null,
+ afterClose: null,
+ onClick: null,
+ onHover: null,
+ onTemplate: null
+ },
+ sounds: {
+ sources: [],
+ volume: 1,
+ conditions: []
+ },
+ titleCount: {
+ conditions: []
+ },
+ modal: false,
+ visibilityControl: false
+}
+
+/**
+ * @param {string} queueName
+ * @return {object}
+ */
+export function getQueueCounts (queueName = 'global') {
+ let count = 0
+ let max = DefaultMaxVisible
+
+ if (Queues.hasOwnProperty(queueName)) {
+ max = Queues[queueName].maxVisible
+ Object.keys(Store).forEach(i => {
+ if (Store[i].options.queue === queueName && !Store[i].closed) count++
+ })
+ }
+
+ return {
+ current: count,
+ maxVisible: max
+ }
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+export function addToQueue (ref) {
+ if (!Queues.hasOwnProperty(ref.options.queue)) {
+ Queues[ref.options.queue] = {maxVisible: DefaultMaxVisible, queue: []}
+ }
+
+ Queues[ref.options.queue].queue.push(ref)
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+export function removeFromQueue (ref) {
+ if (Queues.hasOwnProperty(ref.options.queue)) {
+ const queue = []
+ Object.keys(Queues[ref.options.queue].queue).forEach(i => {
+ if (Queues[ref.options.queue].queue[i].id !== ref.id) {
+ queue.push(Queues[ref.options.queue].queue[i])
+ }
+ })
+ Queues[ref.options.queue].queue = queue
+ }
+}
+
+/**
+ * @param {string} queueName
+ * @return {void}
+ */
+export function queueRender (queueName = 'global') {
+ if (Queues.hasOwnProperty(queueName)) {
+ const noty = Queues[queueName].queue.shift()
+
+ if (noty) noty.show()
+ }
+}
+
+/**
+ * @return {void}
+ */
+export function queueRenderAll () {
+ Object.keys(Queues).forEach(queueName => {
+ queueRender(queueName)
+ })
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+export function ghostFix (ref) {
+ const ghostID = Utils.generateID('ghost')
+ let ghost = document.createElement('div')
+ ghost.setAttribute('id', ghostID)
+ Utils.css(ghost, {
+ height: Utils.outerHeight(ref.barDom) + 'px'
+ })
+
+ ref.barDom.insertAdjacentHTML('afterend', ghost.outerHTML)
+
+ Utils.remove(ref.barDom)
+ ghost = document.getElementById(ghostID)
+ Utils.addClass(ghost, 'noty_fix_effects_height')
+ Utils.addListener(ghost, Utils.animationEndEvents, () => {
+ Utils.remove(ghost)
+ })
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+export function build (ref) {
+ findOrCreateContainer(ref)
+
+ const markup = `
${ref.options.text}
${buildButtons(ref)}`
+
+ ref.barDom = document.createElement('div')
+ ref.barDom.setAttribute('id', ref.id)
+ Utils.addClass(
+ ref.barDom,
+ `noty_bar noty_type__${ref.options.type} noty_theme__${ref.options.theme}`
+ )
+
+ ref.barDom.innerHTML = markup
+
+ fire(ref, 'onTemplate')
+}
+
+/**
+ * @param {Noty} ref
+ * @return {boolean}
+ */
+export function hasButtons (ref) {
+ return !!(ref.options.buttons && Object.keys(ref.options.buttons).length)
+}
+
+/**
+ * @param {Noty} ref
+ * @return {string}
+ */
+function buildButtons (ref) {
+ if (hasButtons(ref)) {
+ let buttons = document.createElement('div')
+ Utils.addClass(buttons, 'noty_buttons')
+
+ Object.keys(ref.options.buttons).forEach(key => {
+ buttons.appendChild(ref.options.buttons[key].dom)
+ })
+
+ ref.options.buttons.forEach(btn => {
+ buttons.appendChild(btn.dom)
+ })
+ return buttons.outerHTML
+ }
+ return ''
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+export function handleModal (ref) {
+ if (ref.options.modal) {
+ if (DocModalCount === 0) {
+ createModal(ref)
+ }
+
+ DocModalCount++
+ }
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+export function handleModalClose (ref) {
+ if (ref.options.modal && DocModalCount > 0) {
+ DocModalCount--
+
+ if (DocModalCount <= 0) {
+ const modal = document.querySelector('.noty_modal')
+
+ if (modal) {
+ Utils.removeClass(modal, 'noty_modal_open')
+ Utils.addClass(modal, 'noty_modal_close')
+ Utils.addListener(modal, Utils.animationEndEvents, () => {
+ Utils.remove(modal)
+ })
+ }
+ }
+ }
+}
+
+/**
+ * @return {void}
+ */
+function createModal () {
+ const body = document.querySelector('body')
+ const modal = document.createElement('div')
+ Utils.addClass(modal, 'noty_modal')
+ body.insertBefore(modal, body.firstChild)
+ Utils.addClass(modal, 'noty_modal_open')
+
+ Utils.addListener(modal, Utils.animationEndEvents, () => {
+ Utils.removeClass(modal, 'noty_modal_open')
+ })
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+function findOrCreateContainer (ref) {
+ if (ref.options.container) {
+ ref.layoutDom = document.querySelector(ref.options.container)
+ return
+ }
+
+ const layoutID = `noty_layout__${ref.options.layout}`
+ ref.layoutDom = document.querySelector(`div#${layoutID}`)
+
+ if (!ref.layoutDom) {
+ ref.layoutDom = document.createElement('div')
+ ref.layoutDom.setAttribute('id', layoutID)
+ ref.layoutDom.setAttribute('role', 'alert')
+ ref.layoutDom.setAttribute('aria-live', 'polite')
+ Utils.addClass(ref.layoutDom, 'noty_layout')
+ document.querySelector('body').appendChild(ref.layoutDom)
+ }
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+export function queueClose (ref) {
+ if (ref.options.timeout) {
+ if (ref.options.progressBar && ref.progressDom) {
+ Utils.css(ref.progressDom, {
+ transition: `width ${ref.options.timeout}ms linear`,
+ width: '0%'
+ })
+ }
+
+ clearTimeout(ref.closeTimer)
+
+ ref.closeTimer = setTimeout(
+ () => {
+ ref.close()
+ },
+ ref.options.timeout
+ )
+ }
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+export function dequeueClose (ref) {
+ if (ref.options.timeout && ref.closeTimer) {
+ clearTimeout(ref.closeTimer)
+ ref.closeTimer = -1
+
+ if (ref.options.progressBar && ref.progressDom) {
+ Utils.css(ref.progressDom, {
+ transition: 'width 0ms linear',
+ width: '100%'
+ })
+ }
+ }
+}
+
+/**
+ * @param {Noty} ref
+ * @param {string} eventName
+ * @return {void}
+ */
+export function fire (ref, eventName) {
+ if (ref.listeners.hasOwnProperty(eventName)) {
+ ref.listeners[eventName].forEach(cb => {
+ if (typeof cb === 'function') {
+ cb.apply(ref)
+ }
+ })
+ }
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+export function openFlow (ref) {
+ fire(ref, 'afterShow')
+ queueClose(ref)
+
+ Utils.addListener(ref.barDom, 'mouseenter', () => {
+ dequeueClose(ref)
+ })
+
+ Utils.addListener(ref.barDom, 'mouseleave', () => {
+ queueClose(ref)
+ })
+}
+
+/**
+ * @param {Noty} ref
+ * @return {void}
+ */
+export function closeFlow (ref) {
+ delete Store[ref.id]
+ ref.closing = false
+ fire(ref, 'afterClose')
+
+ Utils.remove(ref.barDom)
+
+ if (
+ ref.layoutDom.querySelectorAll('.noty_bar').length === 0 &&
+ !ref.options.container
+ ) {
+ Utils.remove(ref.layoutDom)
+ }
+
+ if (
+ Utils.inArray('docVisible', ref.options.titleCount.conditions) ||
+ Utils.inArray('docHidden', ref.options.titleCount.conditions)
+ ) {
+ docTitle.decrement()
+ }
+
+ queueRender(ref.options.queue)
+}
diff --git a/node_modules/noty/src/button.js b/node_modules/noty/src/button.js
new file mode 100644
index 0000000..6413be0
--- /dev/null
+++ b/node_modules/noty/src/button.js
@@ -0,0 +1,16 @@
+import * as Utils from 'utils'
+
+export class NotyButton {
+ constructor (html, classes, cb, attributes = {}) {
+ this.dom = document.createElement('button')
+ this.dom.innerHTML = html
+ this.id = (attributes.id = attributes.id || Utils.generateID('button'))
+ this.cb = cb
+ Object.keys(attributes).forEach(propertyName => {
+ this.dom.setAttribute(propertyName, attributes[propertyName])
+ })
+ Utils.addClass(this.dom, classes || 'noty_btn')
+
+ return this
+ }
+}
diff --git a/node_modules/noty/src/index.js b/node_modules/noty/src/index.js
new file mode 100644
index 0000000..2cf071f
--- /dev/null
+++ b/node_modules/noty/src/index.js
@@ -0,0 +1,493 @@
+/* global VERSION */
+
+import 'noty.scss'
+import Promise from 'es6-promise'
+import * as Utils from 'utils'
+import * as API from 'api'
+import { NotyButton } from 'button'
+import { Push } from 'push'
+
+export default class Noty {
+ /**
+ * @param {object} options
+ * @return {Noty}
+ */
+ constructor (options = {}) {
+ this.options = Utils.deepExtend({}, API.Defaults, options)
+
+ if (API.Store[this.options.id]) {
+ return API.Store[this.options.id]
+ }
+
+ this.id = this.options.id || Utils.generateID('bar')
+ this.closeTimer = -1
+ this.barDom = null
+ this.layoutDom = null
+ this.progressDom = null
+ this.showing = false
+ this.shown = false
+ this.closed = false
+ this.closing = false
+ this.killable = this.options.timeout || this.options.closeWith.length > 0
+ this.hasSound = this.options.sounds.sources.length > 0
+ this.soundPlayed = false
+ this.listeners = {
+ beforeShow: [],
+ onShow: [],
+ afterShow: [],
+ onClose: [],
+ afterClose: [],
+ onClick: [],
+ onHover: [],
+ onTemplate: []
+ }
+ this.promises = {
+ show: null,
+ close: null
+ }
+ this.on('beforeShow', this.options.callbacks.beforeShow)
+ this.on('onShow', this.options.callbacks.onShow)
+ this.on('afterShow', this.options.callbacks.afterShow)
+ this.on('onClose', this.options.callbacks.onClose)
+ this.on('afterClose', this.options.callbacks.afterClose)
+ this.on('onClick', this.options.callbacks.onClick)
+ this.on('onHover', this.options.callbacks.onHover)
+ this.on('onTemplate', this.options.callbacks.onTemplate)
+
+ return this
+ }
+
+ /**
+ * @param {string} eventName
+ * @param {function} cb
+ * @return {Noty}
+ */
+ on (eventName, cb = () => {}) {
+ if (typeof cb === 'function' && this.listeners.hasOwnProperty(eventName)) {
+ this.listeners[eventName].push(cb)
+ }
+
+ return this
+ }
+
+ /**
+ * @return {Noty}
+ */
+ show () {
+ if (this.showing || this.shown) {
+ return this // preventing multiple show
+ }
+
+ if (this.options.killer === true) {
+ Noty.closeAll()
+ } else if (typeof this.options.killer === 'string') {
+ Noty.closeAll(this.options.killer)
+ }
+
+ let queueCounts = API.getQueueCounts(this.options.queue)
+
+ if (
+ queueCounts.current >= queueCounts.maxVisible ||
+ (API.PageHidden && this.options.visibilityControl)
+ ) {
+ API.addToQueue(this)
+
+ if (
+ API.PageHidden &&
+ this.hasSound &&
+ Utils.inArray('docHidden', this.options.sounds.conditions)
+ ) {
+ Utils.createAudioElements(this)
+ }
+
+ if (
+ API.PageHidden &&
+ Utils.inArray('docHidden', this.options.titleCount.conditions)
+ ) {
+ API.docTitle.increment()
+ }
+
+ return this
+ }
+
+ API.Store[this.id] = this
+
+ API.fire(this, 'beforeShow')
+
+ this.showing = true
+
+ if (this.closing) {
+ this.showing = false
+ return this
+ }
+
+ API.build(this)
+ API.handleModal(this)
+
+ if (this.options.force) {
+ this.layoutDom.insertBefore(this.barDom, this.layoutDom.firstChild)
+ } else {
+ this.layoutDom.appendChild(this.barDom)
+ }
+
+ if (
+ this.hasSound &&
+ !this.soundPlayed &&
+ Utils.inArray('docVisible', this.options.sounds.conditions)
+ ) {
+ Utils.createAudioElements(this)
+ }
+
+ if (Utils.inArray('docVisible', this.options.titleCount.conditions)) {
+ API.docTitle.increment()
+ }
+
+ this.shown = true
+ this.closed = false
+
+ // bind button events if any
+ if (API.hasButtons(this)) {
+ Object.keys(this.options.buttons).forEach(key => {
+ const btn = this.barDom.querySelector(
+ `#${this.options.buttons[key].id}`
+ )
+ Utils.addListener(btn, 'click', e => {
+ Utils.stopPropagation(e)
+ this.options.buttons[key].cb(this)
+ })
+ })
+ }
+
+ this.progressDom = this.barDom.querySelector('.noty_progressbar')
+
+ if (Utils.inArray('click', this.options.closeWith)) {
+ Utils.addClass(this.barDom, 'noty_close_with_click')
+ Utils.addListener(
+ this.barDom,
+ 'click',
+ e => {
+ Utils.stopPropagation(e)
+ API.fire(this, 'onClick')
+ this.close()
+ },
+ false
+ )
+ }
+
+ Utils.addListener(
+ this.barDom,
+ 'mouseenter',
+ () => {
+ API.fire(this, 'onHover')
+ },
+ false
+ )
+
+ if (this.options.timeout) Utils.addClass(this.barDom, 'noty_has_timeout')
+ if (this.options.progressBar) {
+ Utils.addClass(this.barDom, 'noty_has_progressbar')
+ }
+
+ if (Utils.inArray('button', this.options.closeWith)) {
+ Utils.addClass(this.barDom, 'noty_close_with_button')
+
+ const closeButton = document.createElement('div')
+ Utils.addClass(closeButton, 'noty_close_button')
+ closeButton.innerHTML = '×'
+ this.barDom.appendChild(closeButton)
+
+ Utils.addListener(
+ closeButton,
+ 'click',
+ e => {
+ Utils.stopPropagation(e)
+ this.close()
+ },
+ false
+ )
+ }
+
+ API.fire(this, 'onShow')
+
+ if (this.options.animation.open === null) {
+ this.promises.show = new Promise(resolve => {
+ resolve()
+ })
+ } else if (typeof this.options.animation.open === 'function') {
+ this.promises.show = new Promise(this.options.animation.open.bind(this))
+ } else {
+ Utils.addClass(this.barDom, this.options.animation.open)
+ this.promises.show = new Promise(resolve => {
+ Utils.addListener(this.barDom, Utils.animationEndEvents, () => {
+ Utils.removeClass(this.barDom, this.options.animation.open)
+ resolve()
+ })
+ })
+ }
+
+ this.promises.show.then(() => {
+ const _t = this
+ setTimeout(
+ () => {
+ API.openFlow(_t)
+ },
+ 100
+ )
+ })
+
+ return this
+ }
+
+ /**
+ * @return {Noty}
+ */
+ stop () {
+ API.dequeueClose(this)
+ return this
+ }
+
+ /**
+ * @return {Noty}
+ */
+ resume () {
+ API.queueClose(this)
+ return this
+ }
+
+ /**
+ * @param {int|boolean} ms
+ * @return {Noty}
+ */
+ setTimeout (ms) {
+ this.stop()
+ this.options.timeout = ms
+
+ if (this.barDom) {
+ if (this.options.timeout) {
+ Utils.addClass(this.barDom, 'noty_has_timeout')
+ } else {
+ Utils.removeClass(this.barDom, 'noty_has_timeout')
+ }
+
+ const _t = this
+ setTimeout(
+ function () {
+ // ugly fix for progressbar display bug
+ _t.resume()
+ },
+ 100
+ )
+ }
+
+ return this
+ }
+
+ /**
+ * @param {string} html
+ * @param {boolean} optionsOverride
+ * @return {Noty}
+ */
+ setText (html, optionsOverride = false) {
+ if (this.barDom) {
+ this.barDom.querySelector('.noty_body').innerHTML = html
+ }
+
+ if (optionsOverride) this.options.text = html
+
+ return this
+ }
+
+ /**
+ * @param {string} type
+ * @param {boolean} optionsOverride
+ * @return {Noty}
+ */
+ setType (type, optionsOverride = false) {
+ if (this.barDom) {
+ let classList = Utils.classList(this.barDom).split(' ')
+
+ classList.forEach(c => {
+ if (c.substring(0, 11) === 'noty_type__') {
+ Utils.removeClass(this.barDom, c)
+ }
+ })
+
+ Utils.addClass(this.barDom, `noty_type__${type}`)
+ }
+
+ if (optionsOverride) this.options.type = type
+
+ return this
+ }
+
+ /**
+ * @param {string} theme
+ * @param {boolean} optionsOverride
+ * @return {Noty}
+ */
+ setTheme (theme, optionsOverride = false) {
+ if (this.barDom) {
+ let classList = Utils.classList(this.barDom).split(' ')
+
+ classList.forEach(c => {
+ if (c.substring(0, 12) === 'noty_theme__') {
+ Utils.removeClass(this.barDom, c)
+ }
+ })
+
+ Utils.addClass(this.barDom, `noty_theme__${theme}`)
+ }
+
+ if (optionsOverride) this.options.theme = theme
+
+ return this
+ }
+
+ /**
+ * @return {Noty}
+ */
+ close () {
+ if (this.closed) return this
+
+ if (!this.shown) {
+ // it's in the queue
+ API.removeFromQueue(this)
+ return this
+ }
+
+ API.fire(this, 'onClose')
+
+ this.closing = true
+
+ if (this.options.animation.close === null || this.options.animation.close === false) {
+ this.promises.close = new Promise(resolve => {
+ resolve()
+ })
+ } else if (typeof this.options.animation.close === 'function') {
+ this.promises.close = new Promise(
+ this.options.animation.close.bind(this)
+ )
+ } else {
+ Utils.addClass(this.barDom, this.options.animation.close)
+ this.promises.close = new Promise(resolve => {
+ Utils.addListener(this.barDom, Utils.animationEndEvents, () => {
+ if (this.options.force) {
+ Utils.remove(this.barDom)
+ } else {
+ API.ghostFix(this)
+ }
+ resolve()
+ })
+ })
+ }
+
+ this.promises.close.then(() => {
+ API.closeFlow(this)
+ API.handleModalClose(this)
+ })
+
+ this.closed = true
+
+ return this
+ }
+
+ // API functions
+
+ /**
+ * @param {boolean|string} queueName
+ * @return {Noty}
+ */
+ static closeAll (queueName = false) {
+ Object.keys(API.Store).forEach(id => {
+ if (queueName) {
+ if (
+ API.Store[id].options.queue === queueName && API.Store[id].killable
+ ) {
+ API.Store[id].close()
+ }
+ } else if (API.Store[id].killable) {
+ API.Store[id].close()
+ }
+ })
+ return this
+ }
+
+ /**
+ * @param {string} queueName
+ * @return {Noty}
+ */
+ static clearQueue (queueName = 'global') {
+ if (API.Queues.hasOwnProperty(queueName)) {
+ API.Queues[queueName].queue = []
+ }
+ return this
+ }
+
+ /**
+ * @return {API.Queues}
+ */
+ static get Queues () {
+ return API.Queues
+ }
+
+ /**
+ * @return {API.PageHidden}
+ */
+ static get PageHidden () {
+ return API.PageHidden
+ }
+
+ /**
+ * @param {Object} obj
+ * @return {Noty}
+ */
+ static overrideDefaults (obj) {
+ API.Defaults = Utils.deepExtend({}, API.Defaults, obj)
+ return this
+ }
+
+ /**
+ * @param {int} amount
+ * @param {string} queueName
+ * @return {Noty}
+ */
+ static setMaxVisible (amount = API.DefaultMaxVisible, queueName = 'global') {
+ if (!API.Queues.hasOwnProperty(queueName)) {
+ API.Queues[queueName] = {maxVisible: amount, queue: []}
+ }
+
+ API.Queues[queueName].maxVisible = amount
+ return this
+ }
+
+ /**
+ * @param {string} innerHtml
+ * @param {String} classes
+ * @param {Function} cb
+ * @param {Object} attributes
+ * @return {NotyButton}
+ */
+ static button (innerHtml, classes = null, cb, attributes = {}) {
+ return new NotyButton(innerHtml, classes, cb, attributes)
+ }
+
+ /**
+ * @return {string}
+ */
+ static version () {
+ return VERSION
+ }
+
+ /**
+ * @param {String} workerPath
+ * @return {Push}
+ */
+ static Push (workerPath) {
+ return new Push(workerPath)
+ }
+}
+
+// Document visibility change controller
+if (typeof window !== 'undefined') {
+ Utils.visibilityChangeFlow()
+}
diff --git a/node_modules/noty/src/noty.scss b/node_modules/noty/src/noty.scss
new file mode 100644
index 0000000..1614d4d
--- /dev/null
+++ b/node_modules/noty/src/noty.scss
@@ -0,0 +1,228 @@
+$noty-primary-color: #333;
+$noty-default-width: 325px;
+$noty-corner-space: 20px;
+
+.noty_layout_mixin {
+ position: fixed;
+ margin: 0;
+ padding: 0;
+ z-index: 9999999;
+ transform: translateZ(0) scale(1.0, 1.0);
+ backface-visibility: hidden;
+ -webkit-font-smoothing: subpixel-antialiased;
+ filter: blur(0);
+ -webkit-filter: blur(0);
+ max-width: 90%;
+}
+
+#noty_layout__top {
+ @extend .noty_layout_mixin;
+ top: 0;
+ left: 5%;
+ width: 90%;
+}
+
+#noty_layout__topLeft {
+ @extend .noty_layout_mixin;
+ top: $noty-corner-space;
+ left: $noty-corner-space;
+ width: $noty-default-width;
+}
+
+#noty_layout__topCenter {
+ @extend .noty_layout_mixin;
+ top: 5%;
+ left: 50%;
+ width: $noty-default-width;
+ transform: translate(calc(-50% - .5px)) translateZ(0) scale(1.0, 1.0);
+}
+
+#noty_layout__topRight {
+ @extend .noty_layout_mixin;
+ top: $noty-corner-space;
+ right: $noty-corner-space;
+ width: $noty-default-width;
+}
+
+#noty_layout__bottom {
+ @extend .noty_layout_mixin;
+ bottom: 0;
+ left: 5%;
+ width: 90%;
+}
+
+#noty_layout__bottomLeft {
+ @extend .noty_layout_mixin;
+ bottom: $noty-corner-space;
+ left: $noty-corner-space;
+ width: $noty-default-width;
+}
+
+#noty_layout__bottomCenter {
+ @extend .noty_layout_mixin;
+ bottom: 5%;
+ left: 50%;
+ width: $noty-default-width;
+ transform: translate(calc(-50% - .5px)) translateZ(0) scale(1.0, 1.0);
+}
+
+#noty_layout__bottomRight {
+ @extend .noty_layout_mixin;
+ bottom: $noty-corner-space;
+ right: $noty-corner-space;
+ width: $noty-default-width;
+}
+
+#noty_layout__center {
+ @extend .noty_layout_mixin;
+ top: 50%;
+ left: 50%;
+ width: $noty-default-width;
+ transform: translate(calc(-50% - .5px), calc(-50% - .5px)) translateZ(0) scale(1.0, 1.0);
+}
+
+#noty_layout__centerLeft {
+ @extend .noty_layout_mixin;
+ top: 50%;
+ left: $noty-corner-space;
+ width: $noty-default-width;
+ transform: translate(0, calc(-50% - .5px)) translateZ(0) scale(1.0, 1.0);
+}
+
+#noty_layout__centerRight {
+ @extend .noty_layout_mixin;
+ top: 50%;
+ right: $noty-corner-space;
+ width: $noty-default-width;
+ transform: translate(0, calc(-50% - .5px)) translateZ(0) scale(1, 1);
+}
+
+.noty_progressbar {
+ display: none;
+}
+
+.noty_has_timeout.noty_has_progressbar .noty_progressbar {
+ display: block;
+ position: absolute;
+ left: 0;
+ bottom: 0;
+ height: 3px;
+ width: 100%;
+ background-color: #646464;
+ opacity: 0.2;
+ filter: alpha(opacity=10)
+}
+
+.noty_bar {
+ -webkit-backface-visibility: hidden;
+ -webkit-transform: translate(0, 0) translateZ(0) scale(1.0, 1.0);
+ transform: translate(0, 0) scale(1.0, 1.0);
+ -webkit-font-smoothing: subpixel-antialiased;
+ overflow: hidden;
+}
+
+.noty_effects_open {
+ opacity: 0;
+ transform: translate(50%);
+ animation: noty_anim_in .5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
+ animation-fill-mode: forwards;
+}
+
+.noty_effects_close {
+ animation: noty_anim_out .5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
+ animation-fill-mode: forwards;
+}
+
+.noty_fix_effects_height {
+ animation: noty_anim_height 75ms ease-out;
+}
+
+.noty_close_with_click {
+ cursor: pointer;
+}
+
+.noty_close_button {
+ position: absolute;
+ top: 2px;
+ right: 2px;
+ font-weight: bold;
+ width: 20px;
+ height: 20px;
+ text-align: center;
+ line-height: 20px;
+ background-color: rgba(0, 0, 0, .05);
+ border-radius: 2px;
+ cursor: pointer;
+ transition: all .2s ease-out;
+}
+
+.noty_close_button:hover {
+ background-color: rgba(0, 0, 0, .1);
+}
+
+.noty_modal {
+ position: fixed;
+ width: 100%;
+ height: 100%;
+ background-color: #000;
+ z-index: 10000;
+ opacity: .3;
+ left: 0;
+ top: 0;
+}
+
+.noty_modal.noty_modal_open {
+ opacity: 0;
+ animation: noty_modal_in .3s ease-out;
+}
+.noty_modal.noty_modal_close {
+ animation: noty_modal_out .3s ease-out;
+ animation-fill-mode: forwards;
+}
+
+@keyframes noty_modal_in {
+ 100% {
+ opacity: .3;
+ }
+}
+@keyframes noty_modal_out {
+ 100% {
+ opacity: 0;
+ }
+}
+
+@keyframes noty_modal_out {
+ 100% {
+ opacity: 0;
+ }
+}
+
+@keyframes noty_anim_in {
+ 100% {
+ transform: translate(0);
+ opacity: 1;
+ }
+}
+
+@keyframes noty_anim_out {
+ 100% {
+ transform: translate(50%);
+ opacity: 0;
+ }
+}
+
+@keyframes noty_anim_height {
+ 100% {
+ height: 0;
+ }
+}
+
+//@import "themes/relax";
+//@import "themes/metroui";
+//@import "themes/mint";
+//@import "themes/sunset";
+//@import "themes/bootstrap-v3";
+//@import "themes/bootstrap-v4";
+//@import "themes/semanticui";
+//@import "themes/nest";
+//@import "themes/light";
diff --git a/node_modules/noty/src/push.js b/node_modules/noty/src/push.js
new file mode 100644
index 0000000..9885a0b
--- /dev/null
+++ b/node_modules/noty/src/push.js
@@ -0,0 +1,204 @@
+export class Push {
+ constructor (workerPath = '/service-worker.js') {
+ this.subData = {}
+ this.workerPath = workerPath
+ this.listeners = {
+ onPermissionGranted: [],
+ onPermissionDenied: [],
+ onSubscriptionSuccess: [],
+ onSubscriptionCancel: [],
+ onWorkerError: [],
+ onWorkerSuccess: [],
+ onWorkerNotSupported: []
+ }
+ return this
+ }
+
+ /**
+ * @param {string} eventName
+ * @param {function} cb
+ * @return {Push}
+ */
+ on (eventName, cb = () => {}) {
+ if (typeof cb === 'function' && this.listeners.hasOwnProperty(eventName)) {
+ this.listeners[eventName].push(cb)
+ }
+
+ return this
+ }
+
+ fire (eventName, params = []) {
+ if (this.listeners.hasOwnProperty(eventName)) {
+ this.listeners[eventName].forEach(cb => {
+ if (typeof cb === 'function') {
+ cb.apply(this, params)
+ }
+ })
+ }
+ }
+
+ create () {
+ console.log('NOT IMPLEMENTED YET')
+ }
+
+ /**
+ * @return {boolean}
+ */
+ isSupported () {
+ let result = false
+
+ try {
+ result = window.Notification ||
+ window.webkitNotifications ||
+ navigator.mozNotification ||
+ (window.external && window.external.msIsSiteMode() !== undefined)
+ } catch (e) {}
+
+ return result
+ }
+
+ /**
+ * @return {string}
+ */
+ getPermissionStatus () {
+ let perm = 'default'
+
+ if (window.Notification && window.Notification.permissionLevel) {
+ perm = window.Notification.permissionLevel
+ } else if (
+ window.webkitNotifications && window.webkitNotifications.checkPermission
+ ) {
+ switch (window.webkitNotifications.checkPermission()) {
+ case 1:
+ perm = 'default'
+ break
+ case 0:
+ perm = 'granted'
+ break
+ default:
+ perm = 'denied'
+ }
+ } else if (window.Notification && window.Notification.permission) {
+ perm = window.Notification.permission
+ } else if (navigator.mozNotification) {
+ perm = 'granted'
+ } else if (
+ window.external && window.external.msIsSiteMode() !== undefined
+ ) {
+ perm = window.external.msIsSiteMode() ? 'granted' : 'default'
+ }
+
+ return perm.toString().toLowerCase()
+ }
+
+ /**
+ * @return {string}
+ */
+ getEndpoint (subscription) {
+ let endpoint = subscription.endpoint
+ const subscriptionId = subscription.subscriptionId
+
+ // fix for Chrome < 45
+ if (subscriptionId && endpoint.indexOf(subscriptionId) === -1) {
+ endpoint += '/' + subscriptionId
+ }
+
+ return endpoint
+ }
+
+ /**
+ * @return {boolean}
+ */
+ isSWRegistered () {
+ try {
+ return navigator.serviceWorker.controller.state === 'activated'
+ } catch (e) {
+ return false
+ }
+ }
+
+ /**
+ * @return {void}
+ */
+ unregisterWorker () {
+ const self = this
+ if ('serviceWorker' in navigator) {
+ navigator.serviceWorker.getRegistrations().then(function (registrations) {
+ for (let registration of registrations) {
+ registration.unregister()
+ self.fire('onSubscriptionCancel')
+ }
+ })
+ }
+ }
+
+ /**
+ * @return {void}
+ */
+ requestSubscription (userVisibleOnly = true) {
+ const self = this
+ const current = this.getPermissionStatus()
+ const cb = result => {
+ if (result === 'granted') {
+ this.fire('onPermissionGranted')
+
+ if ('serviceWorker' in navigator) {
+ navigator.serviceWorker.register(this.workerPath).then(function () {
+ navigator.serviceWorker.ready.then(
+ function (serviceWorkerRegistration) {
+ self.fire('onWorkerSuccess')
+ serviceWorkerRegistration.pushManager
+ .subscribe({
+ userVisibleOnly: userVisibleOnly
+ })
+ .then(function (subscription) {
+ const key = subscription.getKey('p256dh')
+ const token = subscription.getKey('auth')
+
+ self.subData = {
+ endpoint: self.getEndpoint(subscription),
+ p256dh: key
+ ? window.btoa(
+ String.fromCharCode.apply(null, new Uint8Array(key))
+ )
+ : null,
+ auth: token
+ ? window.btoa(
+ String.fromCharCode.apply(
+ null,
+ new Uint8Array(token)
+ )
+ )
+ : null
+ }
+
+ self.fire('onSubscriptionSuccess', [self.subData])
+ })
+ .catch(function (err) {
+ self.fire('onWorkerError', [err])
+ })
+ }
+ )
+ })
+ } else {
+ self.fire('onWorkerNotSupported')
+ }
+ } else if (result === 'denied') {
+ this.fire('onPermissionDenied')
+ this.unregisterWorker()
+ }
+ }
+
+ if (current === 'default') {
+ if (window.Notification && window.Notification.requestPermission) {
+ window.Notification.requestPermission(cb)
+ } else if (
+ window.webkitNotifications && window.webkitNotifications.checkPermission
+ ) {
+ window.webkitNotifications.requestPermission(cb)
+ }
+ } else {
+ cb(current)
+ }
+ }
+}
diff --git a/node_modules/noty/src/themes/bootstrap-v3.scss b/node_modules/noty/src/themes/bootstrap-v3.scss
new file mode 100644
index 0000000..9d454f4
--- /dev/null
+++ b/node_modules/noty/src/themes/bootstrap-v3.scss
@@ -0,0 +1,64 @@
+.noty_theme__bootstrap-v3.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ position: relative;
+ border: 1px solid transparent;
+ border-radius: 4px;
+
+ .noty_body {
+ padding: 15px;
+ }
+
+ .noty_buttons {
+ padding: 10px;
+ }
+
+ .noty_close_button {
+ font-size: 21px;
+ font-weight: 700;
+ line-height: 1;
+ color: #000;
+ text-shadow: 0 1px 0 #fff;
+ filter: alpha(opacity=20);
+ opacity: .2;
+ background: transparent;
+ }
+ .noty_close_button:hover {
+ background: transparent;
+ text-decoration: none;
+ cursor: pointer;
+ filter: alpha(opacity=50);
+ opacity: .5;
+ }
+}
+
+.noty_theme__bootstrap-v3.noty_type__alert,
+.noty_theme__bootstrap-v3.noty_type__notification {
+ background-color: #fff;
+ color: inherit;
+}
+
+.noty_theme__bootstrap-v3.noty_type__warning {
+ background-color: #fcf8e3;
+ color: #8a6d3b;
+ border-color: #faebcc;
+}
+
+.noty_theme__bootstrap-v3.noty_type__error {
+ background-color: #f2dede;
+ color: #a94442;
+ border-color: #ebccd1;
+}
+
+.noty_theme__bootstrap-v3.noty_type__info,
+.noty_theme__bootstrap-v3.noty_type__information {
+ background-color: #d9edf7;
+ color: #31708f;
+ border-color: #bce8f1;
+}
+
+.noty_theme__bootstrap-v3.noty_type__success {
+ background-color: #dff0d8;
+ color: #3c763d;
+ border-color: #d6e9c6;
+}
diff --git a/node_modules/noty/src/themes/bootstrap-v4.scss b/node_modules/noty/src/themes/bootstrap-v4.scss
new file mode 100644
index 0000000..f3b25f0
--- /dev/null
+++ b/node_modules/noty/src/themes/bootstrap-v4.scss
@@ -0,0 +1,65 @@
+.noty_theme__bootstrap-v4.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ position: relative;
+ border: 1px solid transparent;
+ border-radius: .25rem;
+
+ .noty_body {
+ padding: .75rem 1.25rem;
+ }
+
+ .noty_buttons {
+ padding: 10px;
+ }
+
+ .noty_close_button {
+ font-size: 1.5rem;
+ font-weight: 700;
+ line-height: 1;
+ color: #000;
+ text-shadow: 0 1px 0 #fff;
+ filter: alpha(opacity=20);
+ opacity: .5;
+ background: transparent;
+ }
+
+ .noty_close_button:hover {
+ background: transparent;
+ text-decoration: none;
+ cursor: pointer;
+ filter: alpha(opacity=50);
+ opacity: .75;
+ }
+}
+
+.noty_theme__bootstrap-v4.noty_type__alert,
+.noty_theme__bootstrap-v4.noty_type__notification {
+ background-color: #fff;
+ color: inherit;
+}
+
+.noty_theme__bootstrap-v4.noty_type__warning {
+ background-color: #fcf8e3;
+ color: #8a6d3b;
+ border-color: #faebcc;
+}
+
+.noty_theme__bootstrap-v4.noty_type__error {
+ background-color: #f2dede;
+ color: #a94442;
+ border-color: #ebccd1;
+}
+
+.noty_theme__bootstrap-v4.noty_type__info,
+.noty_theme__bootstrap-v4.noty_type__information {
+ background-color: #d9edf7;
+ color: #31708f;
+ border-color: #bce8f1;
+}
+
+.noty_theme__bootstrap-v4.noty_type__success {
+ background-color: #dff0d8;
+ color: #3c763d;
+ border-color: #d6e9c6;
+}
diff --git a/node_modules/noty/src/themes/light.scss b/node_modules/noty/src/themes/light.scss
new file mode 100644
index 0000000..4b7c1ed
--- /dev/null
+++ b/node_modules/noty/src/themes/light.scss
@@ -0,0 +1,63 @@
+.noty_theme__light.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ border-radius: 2px;
+ position: relative;
+
+ .noty_body {
+ padding: 10px;
+ }
+
+ .noty_buttons {
+ border-top: 1px solid #e7e7e7;
+ padding: 5px 10px;
+ }
+}
+
+.noty_theme__light.noty_type__alert,
+.noty_theme__light.noty_type__notification {
+ background-color: #fff;
+ border: 1px solid #dedede;
+ color: #444;
+}
+
+.noty_theme__light.noty_type__warning {
+ background-color: #FFEAA8;
+ border: 1px solid #FFC237;
+ color: #826200;
+
+ .noty_buttons {
+ border-color: #dfaa30;
+ }
+}
+
+.noty_theme__light.noty_type__error {
+ background-color: #ED7000;
+ border: 1px solid #e25353;
+ color: #FFF;
+
+ .noty_buttons {
+ border-color: darkred;
+ }
+}
+
+.noty_theme__light.noty_type__info,
+.noty_theme__light.noty_type__information {
+ background-color: #78C5E7;
+ border: 1px solid #3badd6;
+ color: #FFF;
+
+ .noty_buttons {
+ border-color: #0B90C4;
+ }
+}
+
+.noty_theme__light.noty_type__success {
+ background-color: #57C880;
+ border: 1px solid #7cdd77;
+ color: darkgreen;
+
+ .noty_buttons {
+ border-color: #50C24E;
+ }
+}
diff --git a/node_modules/noty/src/themes/metroui.scss b/node_modules/noty/src/themes/metroui.scss
new file mode 100644
index 0000000..656e9da
--- /dev/null
+++ b/node_modules/noty/src/themes/metroui.scss
@@ -0,0 +1,53 @@
+.noty_theme__metroui.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ position: relative;
+ box-shadow: rgba(0, 0, 0, 0.298039) 0 0 5px 0;
+
+ .noty_progressbar {
+ position: absolute;
+ left: 0;
+ bottom: 0;
+ height: 3px;
+ width: 100%;
+ background-color: #000;
+ opacity: 0.2;
+ filter: alpha(opacity=20)
+ }
+
+ .noty_body {
+ padding: 1.25em;
+ font-size: 14px;
+ }
+
+ .noty_buttons {
+ padding: 0 10px .5em 10px;
+ }
+}
+
+.noty_theme__metroui.noty_type__alert,
+.noty_theme__metroui.noty_type__notification {
+ background-color: #fff;
+ color: #1d1d1d;
+}
+
+.noty_theme__metroui.noty_type__warning {
+ background-color: #FA6800;
+ color: #fff;
+}
+
+.noty_theme__metroui.noty_type__error {
+ background-color: #CE352C;
+ color: #FFF;
+}
+
+.noty_theme__metroui.noty_type__info,
+.noty_theme__metroui.noty_type__information {
+ background-color: #1BA1E2;
+ color: #FFF;
+}
+
+.noty_theme__metroui.noty_type__success {
+ background-color: #60A917;
+ color: #fff;
+}
diff --git a/node_modules/noty/src/themes/mint.scss b/node_modules/noty/src/themes/mint.scss
new file mode 100644
index 0000000..25266ab
--- /dev/null
+++ b/node_modules/noty/src/themes/mint.scss
@@ -0,0 +1,47 @@
+.noty_theme__mint.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ border-radius: 2px;
+ position: relative;
+
+ .noty_body {
+ padding: 10px;
+ font-size: 14px;
+ }
+
+ .noty_buttons {
+ padding: 10px;
+ }
+}
+
+.noty_theme__mint.noty_type__alert,
+.noty_theme__mint.noty_type__notification {
+ background-color: #fff;
+ border-bottom: 1px solid #D1D1D1;
+ color: #2F2F2F;
+}
+
+.noty_theme__mint.noty_type__warning {
+ background-color: #FFAE42;
+ border-bottom: 1px solid #E89F3C;
+ color: #fff;
+}
+
+.noty_theme__mint.noty_type__error {
+ background-color: #DE636F;
+ border-bottom: 1px solid #CA5A65;
+ color: #fff;
+}
+
+.noty_theme__mint.noty_type__info,
+.noty_theme__mint.noty_type__information {
+ background-color: #7F7EFF;
+ border-bottom: 1px solid #7473E8;
+ color: #fff;
+}
+
+.noty_theme__mint.noty_type__success {
+ background-color: #AFC765;
+ border-bottom: 1px solid #A0B55C;
+ color: #fff;
+}
diff --git a/node_modules/noty/src/themes/nest.scss b/node_modules/noty/src/themes/nest.scss
new file mode 100644
index 0000000..963a691
--- /dev/null
+++ b/node_modules/noty/src/themes/nest.scss
@@ -0,0 +1,146 @@
+.noty_theme__nest.noty_bar {
+ margin: 0 0 15px 0;
+ overflow: hidden;
+ border-radius: 2px;
+ position: relative;
+ box-shadow: rgba(0, 0, 0, 0.098039) 5px 4px 10px 0;
+
+ .noty_body {
+ padding: 10px;
+ font-size: 14px;
+ text-shadow: 1px 1px 1px rgba(0, 0, 0, .1);
+ }
+
+ .noty_buttons {
+ padding: 10px;
+ }
+}
+
+.noty_layout .noty_theme__nest.noty_bar {
+ z-index: 5;
+}
+
+.noty_layout .noty_theme__nest.noty_bar:nth-child(2) {
+ position: absolute;
+ top: 0;
+ margin-top: 4px;
+ margin-right: -4px;
+ margin-left: 4px;
+ z-index: 4;
+ width: 100%;
+}
+
+.noty_layout .noty_theme__nest.noty_bar:nth-child(3) {
+ position: absolute;
+ top: 0;
+ margin-top: 8px;
+ margin-right: -8px;
+ margin-left: 8px;
+ z-index: 3;
+ width: 100%;
+}
+
+.noty_layout .noty_theme__nest.noty_bar:nth-child(4) {
+ position: absolute;
+ top: 0;
+ margin-top: 12px;
+ margin-right: -12px;
+ margin-left: 12px;
+ z-index: 2;
+ width: 100%;
+}
+
+.noty_layout .noty_theme__nest.noty_bar:nth-child(5) {
+ position: absolute;
+ top: 0;
+ margin-top: 16px;
+ margin-right: -16px;
+ margin-left: 16px;
+ z-index: 1;
+ width: 100%;
+}
+
+.noty_layout .noty_theme__nest.noty_bar:nth-child(n+6) {
+ position: absolute;
+ top: 0;
+ margin-top: 20px;
+ margin-right: -20px;
+ margin-left: 20px;
+ z-index: -1;
+ width: 100%;
+}
+
+// left corner stacks
+#noty_layout__bottomLeft .noty_theme__nest.noty_bar:nth-child(2),
+#noty_layout__topLeft .noty_theme__nest.noty_bar:nth-child(2) {
+ margin-top: 4px;
+ margin-left: -4px;
+ margin-right: 4px;
+}
+
+#noty_layout__bottomLeft .noty_theme__nest.noty_bar:nth-child(3),
+#noty_layout__topLeft .noty_theme__nest.noty_bar:nth-child(3) {
+ margin-top: 8px;
+ margin-left: -8px;
+ margin-right: 8px;
+}
+
+#noty_layout__bottomLeft .noty_theme__nest.noty_bar:nth-child(4),
+#noty_layout__topLeft .noty_theme__nest.noty_bar:nth-child(4) {
+ margin-top: 12px;
+ margin-left: -12px;
+ margin-right: 12px;
+}
+
+#noty_layout__bottomLeft .noty_theme__nest.noty_bar:nth-child(5),
+#noty_layout__topLeft .noty_theme__nest.noty_bar:nth-child(5) {
+ margin-top: 16px;
+ margin-left: -16px;
+ margin-right: 16px;
+}
+
+#noty_layout__bottomLeft .noty_theme__nest.noty_bar:nth-child(n+6),
+#noty_layout__topLeft .noty_theme__nest.noty_bar:nth-child(n+6) {
+ margin-top: 20px;
+ margin-left: -20px;
+ margin-right: 20px;
+}
+
+.noty_theme__nest.noty_type__alert,
+.noty_theme__nest.noty_type__notification {
+ background-color: #073B4C;
+ color: #fff;
+
+ .noty_progressbar {
+ background-color: #fff;
+ }
+}
+
+.noty_theme__nest.noty_type__warning {
+ background-color: #FFD166;
+ color: #fff;
+}
+
+.noty_theme__nest.noty_type__error {
+ background-color: #EF476F;
+ color: #fff;
+
+ .noty_progressbar {
+ opacity: .4;
+ }
+}
+
+.noty_theme__nest.noty_type__info,
+.noty_theme__nest.noty_type__information {
+ background-color: #118AB2;
+ color: #fff;
+
+ .noty_progressbar {
+ opacity: .6;
+ }
+}
+
+.noty_theme__nest.noty_type__success {
+ background-color: #06D6A0;
+ color: #fff;
+}
diff --git a/node_modules/noty/src/themes/relax.scss b/node_modules/noty/src/themes/relax.scss
new file mode 100644
index 0000000..306fca6
--- /dev/null
+++ b/node_modules/noty/src/themes/relax.scss
@@ -0,0 +1,63 @@
+.noty_theme__relax.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ border-radius: 2px;
+ position: relative;
+
+ .noty_body {
+ padding: 10px;
+ }
+
+ .noty_buttons {
+ border-top: 1px solid #e7e7e7;
+ padding: 5px 10px;
+ }
+}
+
+.noty_theme__relax.noty_type__alert,
+.noty_theme__relax.noty_type__notification {
+ background-color: #fff;
+ border: 1px solid #dedede;
+ color: #444;
+}
+
+.noty_theme__relax.noty_type__warning {
+ background-color: #FFEAA8;
+ border: 1px solid #FFC237;
+ color: #826200;
+
+ .noty_buttons {
+ border-color: #dfaa30;
+ }
+}
+
+.noty_theme__relax.noty_type__error {
+ background-color: #FF8181;
+ border: 1px solid #e25353;
+ color: #FFF;
+
+ .noty_buttons {
+ border-color: darkred;
+ }
+}
+
+.noty_theme__relax.noty_type__info,
+.noty_theme__relax.noty_type__information {
+ background-color: #78C5E7;
+ border: 1px solid #3badd6;
+ color: #FFF;
+
+ .noty_buttons {
+ border-color: #0B90C4;
+ }
+}
+
+.noty_theme__relax.noty_type__success {
+ background-color: #BCF5BC;
+ border: 1px solid #7cdd77;
+ color: darkgreen;
+
+ .noty_buttons {
+ border-color: #50C24E;
+ }
+}
diff --git a/node_modules/noty/src/themes/semanticui.scss b/node_modules/noty/src/themes/semanticui.scss
new file mode 100644
index 0000000..e52e910
--- /dev/null
+++ b/node_modules/noty/src/themes/semanticui.scss
@@ -0,0 +1,53 @@
+.noty_theme__semanticui.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ position: relative;
+ border: 1px solid transparent;
+ font-size: 1em;
+ border-radius: .28571429rem;
+ box-shadow: 0 0 0 1px rgba(34,36,38,.22) inset, 0 0 0 0 transparent;
+
+ .noty_body {
+ padding: 1em 1.5em;
+ line-height: 1.4285em;
+ }
+
+ .noty_buttons {
+ padding: 10px;
+ }
+}
+
+.noty_theme__semanticui.noty_type__alert,
+.noty_theme__semanticui.noty_type__notification {
+ background-color: #f8f8f9;
+ color: rgba(0,0,0,.87);
+}
+
+.noty_theme__semanticui.noty_type__warning {
+ background-color: #fffaf3;
+ color: #573a08;
+
+ box-shadow: 0 0 0 1px #c9ba9b inset, 0 0 0 0 transparent;
+}
+
+.noty_theme__semanticui.noty_type__error {
+ background-color: #fff6f6;
+ color: #9f3a38;
+
+ box-shadow: 0 0 0 1px #e0b4b4 inset, 0 0 0 0 transparent;
+}
+
+.noty_theme__semanticui.noty_type__info,
+.noty_theme__semanticui.noty_type__information {
+ background-color: #f8ffff;
+ color: #276f86;
+
+ box-shadow: 0 0 0 1px #a9d5de inset, 0 0 0 0 transparent;
+}
+
+.noty_theme__semanticui.noty_type__success {
+ background-color: #fcfff5;
+ color: #2c662d;
+
+ box-shadow: 0 0 0 1px #a3c293 inset, 0 0 0 0 transparent;
+}
diff --git a/node_modules/noty/src/themes/sunset.scss b/node_modules/noty/src/themes/sunset.scss
new file mode 100644
index 0000000..513827a
--- /dev/null
+++ b/node_modules/noty/src/themes/sunset.scss
@@ -0,0 +1,55 @@
+.noty_theme__sunset.noty_bar {
+ margin: 4px 0;
+ overflow: hidden;
+ border-radius: 2px;
+ position: relative;
+
+ .noty_body {
+ padding: 10px;
+ font-size: 14px;
+ text-shadow: 1px 1px 1px rgba(0, 0, 0, .1);
+ }
+
+ .noty_buttons {
+ padding: 10px;
+ }
+}
+
+.noty_theme__sunset.noty_type__alert,
+.noty_theme__sunset.noty_type__notification {
+ background-color: #073B4C;
+ color: #fff;
+
+ .noty_progressbar {
+ background-color: #fff;
+ }
+}
+
+.noty_theme__sunset.noty_type__warning {
+ background-color: #FFD166;
+ color: #fff;
+}
+
+.noty_theme__sunset.noty_type__error {
+ background-color: #EF476F;
+ color: #fff;
+
+ .noty_progressbar {
+ opacity: .4;
+ }
+}
+
+.noty_theme__sunset.noty_type__info,
+.noty_theme__sunset.noty_type__information {
+ background-color: #118AB2;
+ color: #fff;
+
+ .noty_progressbar {
+ opacity: .6;
+ }
+}
+
+.noty_theme__sunset.noty_type__success {
+ background-color: #06D6A0;
+ color: #fff;
+}
diff --git a/node_modules/noty/src/utils.js b/node_modules/noty/src/utils.js
new file mode 100644
index 0000000..4285c01
--- /dev/null
+++ b/node_modules/noty/src/utils.js
@@ -0,0 +1,295 @@
+import * as API from 'api'
+
+export const animationEndEvents = 'webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend'
+
+export function inArray (needle, haystack, argStrict) {
+ let key
+ let strict = !!argStrict
+
+ if (strict) {
+ for (key in haystack) {
+ if (haystack.hasOwnProperty(key) && haystack[key] === needle) {
+ return true
+ }
+ }
+ } else {
+ for (key in haystack) {
+ if (haystack.hasOwnProperty(key) && haystack[key] === needle) {
+ return true
+ }
+ }
+ }
+ return false
+}
+
+export function stopPropagation (evt) {
+ evt = evt || window.event
+
+ if (typeof evt.stopPropagation !== 'undefined') {
+ evt.stopPropagation()
+ } else {
+ evt.cancelBubble = true
+ }
+}
+
+export const deepExtend = function (out) {
+ out = out || {}
+
+ for (let i = 1; i < arguments.length; i++) {
+ let obj = arguments[i]
+
+ if (!obj) continue
+
+ for (let key in obj) {
+ if (obj.hasOwnProperty(key)) {
+ if (Array.isArray(obj[key])) {
+ out[key] = obj[key]
+ } else if (typeof obj[key] === 'object' && obj[key] !== null) {
+ out[key] = deepExtend(out[key], obj[key])
+ } else {
+ out[key] = obj[key]
+ }
+ }
+ }
+ }
+
+ return out
+}
+
+export function generateID (prefix = '') {
+ let id = `noty_${prefix}_`
+
+ id += 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
+ let r = Math.random() * 16 | 0
+ let v = c === 'x' ? r : r & 0x3 | 0x8
+ return v.toString(16)
+ })
+
+ return id
+}
+
+export function outerHeight (el) {
+ let height = el.offsetHeight
+ let style = window.getComputedStyle(el)
+
+ height += parseInt(style.marginTop) + parseInt(style.marginBottom)
+ return height
+}
+
+export let css = (function () {
+ let cssPrefixes = ['Webkit', 'O', 'Moz', 'ms']
+ let cssProps = {}
+
+ function camelCase (string) {
+ return string
+ .replace(/^-ms-/, 'ms-')
+ .replace(/-([\da-z])/gi, function (match, letter) {
+ return letter.toUpperCase()
+ })
+ }
+
+ function getVendorProp (name) {
+ let style = document.body.style
+ if (name in style) return name
+
+ let i = cssPrefixes.length
+ let capName = name.charAt(0).toUpperCase() + name.slice(1)
+ let vendorName
+
+ while (i--) {
+ vendorName = cssPrefixes[i] + capName
+ if (vendorName in style) return vendorName
+ }
+
+ return name
+ }
+
+ function getStyleProp (name) {
+ name = camelCase(name)
+ return cssProps[name] || (cssProps[name] = getVendorProp(name))
+ }
+
+ function applyCss (element, prop, value) {
+ prop = getStyleProp(prop)
+ element.style[prop] = value
+ }
+
+ return function (element, properties) {
+ let args = arguments
+ let prop
+ let value
+
+ if (args.length === 2) {
+ for (prop in properties) {
+ if (properties.hasOwnProperty(prop)) {
+ value = properties[prop]
+ if (value !== undefined && properties.hasOwnProperty(prop)) {
+ applyCss(element, prop, value)
+ }
+ }
+ }
+ } else {
+ applyCss(element, args[1], args[2])
+ }
+ }
+})()
+
+export function addListener (el, events, cb, useCapture = false) {
+ events = events.split(' ')
+ for (let i = 0; i < events.length; i++) {
+ if (document.addEventListener) {
+ el.addEventListener(events[i], cb, useCapture)
+ } else if (document.attachEvent) {
+ el.attachEvent('on' + events[i], cb)
+ }
+ }
+}
+
+export function hasClass (element, name) {
+ let list = typeof element === 'string' ? element : classList(element)
+ return list.indexOf(' ' + name + ' ') >= 0
+}
+
+export function addClass (element, name) {
+ let oldList = classList(element)
+ let newList = oldList + name
+
+ if (hasClass(oldList, name)) return
+
+ // Trim the opening space.
+ element.className = newList.substring(1)
+}
+
+export function removeClass (element, name) {
+ let oldList = classList(element)
+ let newList
+
+ if (!hasClass(element, name)) return
+
+ // Replace the class name.
+ newList = oldList.replace(' ' + name + ' ', ' ')
+
+ // Trim the opening and closing spaces.
+ element.className = newList.substring(1, newList.length - 1)
+}
+
+export function remove (element) {
+ if (element.parentNode) {
+ element.parentNode.removeChild(element)
+ }
+}
+
+export function classList (element) {
+ return (' ' + ((element && element.className) || '') + ' ').replace(
+ /\s+/gi,
+ ' '
+ )
+}
+
+export function visibilityChangeFlow () {
+ let hidden
+ let visibilityChange
+ if (typeof document.hidden !== 'undefined') {
+ // Opera 12.10 and Firefox 18 and later support
+ hidden = 'hidden'
+ visibilityChange = 'visibilitychange'
+ } else if (typeof document.msHidden !== 'undefined') {
+ hidden = 'msHidden'
+ visibilityChange = 'msvisibilitychange'
+ } else if (typeof document.webkitHidden !== 'undefined') {
+ hidden = 'webkitHidden'
+ visibilityChange = 'webkitvisibilitychange'
+ }
+
+ function onVisibilityChange () {
+ API.PageHidden = document[hidden]
+ handleVisibilityChange()
+ }
+
+ function onBlur () {
+ API.PageHidden = true
+ handleVisibilityChange()
+ }
+
+ function onFocus () {
+ API.PageHidden = false
+ handleVisibilityChange()
+ }
+
+ function handleVisibilityChange () {
+ if (API.PageHidden) stopAll()
+ else resumeAll()
+ }
+
+ function stopAll () {
+ setTimeout(
+ function () {
+ Object.keys(API.Store).forEach(id => {
+ if (API.Store.hasOwnProperty(id)) {
+ if (API.Store[id].options.visibilityControl) {
+ API.Store[id].stop()
+ }
+ }
+ })
+ },
+ 100
+ )
+ }
+
+ function resumeAll () {
+ setTimeout(
+ function () {
+ Object.keys(API.Store).forEach(id => {
+ if (API.Store.hasOwnProperty(id)) {
+ if (API.Store[id].options.visibilityControl) {
+ API.Store[id].resume()
+ }
+ }
+ })
+ API.queueRenderAll()
+ },
+ 100
+ )
+ }
+
+ if (visibilityChange) {
+ addListener(document, visibilityChange, onVisibilityChange)
+ }
+
+ addListener(window, 'blur', onBlur)
+ addListener(window, 'focus', onFocus)
+}
+
+export function createAudioElements (ref) {
+ if (ref.hasSound) {
+ const audioElement = document.createElement('audio')
+
+ ref.options.sounds.sources.forEach(s => {
+ const source = document.createElement('source')
+ source.src = s
+ source.type = `audio/${getExtension(s)}`
+ audioElement.appendChild(source)
+ })
+
+ if (ref.barDom) {
+ ref.barDom.appendChild(audioElement)
+ } else {
+ document.querySelector('body').appendChild(audioElement)
+ }
+
+ audioElement.volume = ref.options.sounds.volume
+
+ if (!ref.soundPlayed) {
+ audioElement.play()
+ ref.soundPlayed = true
+ }
+
+ audioElement.onended = function () {
+ remove(audioElement)
+ }
+ }
+}
+
+function getExtension (fileName) {
+ return fileName.match(/\.([^.]+)$/)[1]
+}
diff --git a/node_modules/pnotify/LICENSE b/node_modules/pnotify/LICENSE
deleted file mode 100644
index d645695..0000000
--- a/node_modules/pnotify/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
diff --git a/node_modules/pnotify/README.md b/node_modules/pnotify/README.md
deleted file mode 100644
index 81d2fbf..0000000
--- a/node_modules/pnotify/README.md
+++ /dev/null
@@ -1,783 +0,0 @@
-[](https://www.npmjs.com/package/pnotify) [](https://www.jsdelivr.com/package/npm/pnotify)
-
-PNotify is a vanilla JavaScript notification and [confirmation/prompt](http://sciactive.com/pnotify/#confirm-module) library. PNotify can provide [desktop notifications](http://sciactive.com/pnotify/#web-notifications) based on the [Web Notifications spec](http://www.w3.org/TR/notifications/) with fall back to an in-browser notice.
-
-
v5 is in Alpha
-
-[PNotify v5](https://github.com/sciactive/pnotify/tree/develop) has some [really awesome changes](https://github.com/sciactive/pnotify/blob/develop/MIGRATING.md), and is currently in alpha release. Feel free to try it out and [submit feedback](https://github.com/sciactive/pnotify/issues).
-
-
Demos
-
-
V4 (Stable Version)
-
-http://sciactive.com/pnotify/
-
-
V5 (Development Version)
-
-https://sciactive.github.io/pnotify/
-
-
Table of Contents
-
-
-- [Getting Started](#Getting-Started)
- - [Migrating from PNotify 3](#Migrating-from-PNotify-3)
-- [Installation](#Installation)
- - [Svelte](#Svelte)
- - [React](#React)
- - [Angular](#Angular)
- - [Angular (Injectable)](#Angular-Injectable)
- - [AngularJS](#AngularJS)
- - [Vanilla JS (ES5)](#Vanilla-JS-ES5)
- - [Vanilla JS (ES6)](#Vanilla-JS-ES6)
-- [Styles](#Styles)
- - [Bright Theme](#Bright-Theme)
- - [Material](#Material)
- - [Material Icons](#Material-Icons)
- - [Bootstrap](#Bootstrap)
- - [Font Awesome (Icons)](#Font-Awesome-Icons)
-- [Creating Notices](#Creating-Notices)
-- [Options](#Options)
- - [Changing Defaults](#Changing-Defaults)
-- [Module Options](#Module-Options)
- - [Desktop Module](#Desktop-Module)
- - [Buttons Module](#Buttons-Module)
- - [NonBlock Module](#NonBlock-Module)
- - [Mobile Module](#Mobile-Module)
- - [Animate Module](#Animate-Module)
- - [Confirm Module](#Confirm-Module)
- - [History Module](#History-Module)
- - [Callbacks Module](#Callbacks-Module)
-- [Static Methods and Properties](#Static-Methods-and-Properties)
-- [Instance Methods and Properties](#Instance-Methods-and-Properties)
- - [From the Svelte Component API](#From-the-Svelte-Component-API)
- - [Events](#Events)
-- [Stacks](#Stacks)
- - [Example Stack](#Example-Stack)
-- [Features](#Features)
-- [Licensing and Additional Info](#Licensing-and-Additional-Info)
-
-
-# Getting Started
-
-You can get PNotify using NPM. (You can also use [jsDelivr](https://www.jsdelivr.com/package/npm/pnotify) or [UNPKG](https://unpkg.com/pnotify/).)
-
-```sh
-npm install --save pnotify
-
-# If you plan to use Material style:
-npm install --save material-design-icons
-
-# If you plan to use the Animate module:
-npm install --save animate.css
-
-# If you plan to use the NonBlock module:
-npm install --save nonblockjs
-```
-
-Inside the pnotify module directory:
-
-* `src` Svelte components and uncompressed Bright Theme CSS.
-* `lib/es` uncompressed ECMAScript modules.
-* `lib/umd` uncompressed UMD modules.
-* `lib/iife` uncompressed IIFE scripts.
-* `dist` compressed Bright Theme CSS.
-* `dist/es` compressed ECMAScript modules.
-* `dist/umd` compressed UMD modules.
-* `dist/iife` compressed IIFE scripts.
-
-## [Migrating from PNotify 3](MIGRATING.md)
-
-# Installation
-
-In addition to the JS, be sure to [include a PNotify style](#styles).
-
-## Svelte
-
-[PNotify in Svelte](https://codesandbox.io/s/nwoxqkvw6m). Import the Svelte files from `src`:
-
-```js
-import PNotify from 'pnotify/src/PNotify.html';
-import PNotifyButtons from 'pnotify/src/PNotifyButtons.html';
-
-PNotify.alert('Notice me, senpai!');
-```
-
-## React
-
-[PNotify in React](https://codesandbox.io/s/wwqzk8472w). Import the ES modules from `dist`:
-
-```js
-import PNotify from 'pnotify/dist/es/PNotify';
-import PNotifyButtons from 'pnotify/dist/es/PNotifyButtons';
-
-PNotify.alert('Notice me, senpai!');
-```
-
-## Angular
-
-[PNotify in Angular](https://codesandbox.io/s/l3pzkl64yq). Import the ES modules from `dist` and initiate the modules:
-
-```ts
-import PNotify from 'pnotify/dist/es/PNotify';
-import PNotifyButtons from 'pnotify/dist/es/PNotifyButtons';
-
-//...
-export class WhateverComponent {
- constructor() {
- PNotifyButtons; // Initiate the module. Important!
- PNotify.alert('Notice me, senpai!');
- }
-}
-```
-
-For IE support, see [this issue](https://github.com/sciactive/pnotify/issues/343).
-
-## Angular (Injectable)
-
-[PNotify in Angular](https://codesandbox.io/s/17yr520yj) as an injectable service:
-
-```ts
-// pnotify.service.ts
-import { Injectable } from '@angular/core';
-import PNotify from 'pnotify/dist/es/PNotify';
-import PNotifyButtons from 'pnotify/dist/es/PNotifyButtons';
-
-@Injectable()
-export class PNotifyService {
- getPNotify() {
- PNotifyButtons; // Initiate the module. Important!
- return PNotify;
- }
-}
-
-// whatever.module.ts
-//...
-import { PNotifyService } from './pnotify.service';
-@NgModule({
- declarations: [...],
- imports: [...],
- providers: [PNotifyService],
- bootstrap: [...]
-})
-export class WhateverModule {}
-
-// whatever.component.ts
-import { PNotifyService } from './pnotify.service';
-//...
-export class WhateverComponent {
- pnotify = undefined;
- constructor(pnotifyService: PNotifyService) {
- this.pnotify = pnotifyService.getPNotify();
- this.pnotify.alert('Notice me, senpai!');
- }
-}
-```
-
-## AngularJS
-
-[PNotify in AngularJS](https://codesandbox.io/s/o5mp55p2p9). Import the UMD modules from `dist`:
-
-```js
-var angular = require('angular');
-var PNotify = require('pnotify/dist/umd/PNotify');
-var PNotifyButtons = require('pnotify/dist/umd/PNotifyButtons');
-
-angular.module('WhateverModule', [])
- .value('PNotify', PNotify)
- .controller('WhateverController', ['PNotify', function(PNotify) {
- PNotify.alert('Notice me, senpai!');
- }]);
-```
-
-## Vanilla JS (ES5)
-
-PNotify in vanilla ECMAScript 5. Include the IIFE scripts from `dist`:
-
-```html
-
-
-
-```
-
-## Vanilla JS (ES6)
-
-PNotify in vanilla ECMAScript 6+. Include the ES modules from `dist`:
-
-```js
-import PNotify from 'node_modules/pnotify/dist/es/PNotify.js';
-import PNotifyButtons from 'node_modules/pnotify/dist/es/PNotifyButtons.js';
-
-PNotify.alert('Notice me, senpai!');
-```
-
-# Styles
-
-## Bright Theme
-
-The default, standalone theme, Bright Theme. Include the CSS file in your page:
-
-```html
-
-```
-
-## Material
-
-The Material Style module. Requires [material-design-icons](https://www.npmjs.com/package/material-design-icons). Include the module in your JS, and set it as the default:
-
-```js
-import PNotifyStyleMaterial from 'pnotify/dist/es/PNotifyStyleMaterial.js';
-// or
-var PNotifyStyleMaterial = require('pnotify/dist/umd/PNotifyStyleMaterial.js');
-
-// Set default styling.
-PNotify.defaults.styling = 'material';
-// This icon setting requires the Material Icons font. (See below.)
-PNotify.defaults.icons = 'material';
-```
-
-### Material Icons
-
-To use the Material Style icons, include the Material Design Icons Font in your page.
-
-```sh
-# The official Google package:
-npm install --save material-design-icons
-
-# OR, An unofficial package that only includes the font:
-npm install --save material-design-icon-fonts
-```
-
-```html
-
-```
-
-Alternatively, you can use the Google Fonts CDN:
-
-```html
-
-```
-
-## Bootstrap
-
-To set Bootstrap as the default style, include the appropriate line(s) from below after you import PNotify:
-
-```js
-PNotify.defaults.styling = 'bootstrap3'; // Bootstrap version 3
-PNotify.defaults.icons = 'bootstrap3'; // glyphicons
-// or
-PNotify.defaults.styling = 'bootstrap4'; // Bootstrap version 4
-```
-
-## Font Awesome (Icons)
-
-To set Font Awesome as the default icons, include the appropriate line from below after you import PNotify:
-
-```js
-PNotify.defaults.icons = 'fontawesome4'; // Font Awesome 4
-// or
-PNotify.defaults.icons = 'fontawesome5'; // Font Awesome 5
-```
-
-# Creating Notices
-
-To make a notice, use the factory functions:
-
-```js
-// Manually set the type.
-PNotify.alert({
- text: "I'm an alert.",
- type: 'notice'
-});
-
-// Automatically set the type.
-PNotify.notice({
- text: "I'm a notice."
-});
-PNotify.info({
- text: "I'm an info message."
-});
-PNotify.success({
- text: "I'm a success message."
-});
-PNotify.error({
- text: "I'm an error message."
-});
-```
-
-# Options
-
-PNotify options and default values.
-
-`PNotify.defaults = {`
-* `title: false`
- The notice's title.
-* `titleTrusted: false`
- Whether to trust the title or escape its contents. (Not allow HTML.)
-* `text: false`
- The notice's text.
-* `textTrusted: false`
- Whether to trust the text or escape its contents. (Not allow HTML.)
-* `styling: 'brighttheme'`
- What styling classes to use. (Can be 'brighttheme', 'bootstrap3', 'bootstrap4', or a styling object. See the source in PNotifyStyleMaterial.html for the properties in a style object.)
-* `icons: 'brighttheme'`
- What icons classes to use (Can be 'brighttheme', 'bootstrap3', 'fontawesome4', 'fontawesome5', or an icon object. See the source in PNotifyStyleMaterial.html for the properties in an icon object.)
-* `addClass: ''`
- Additional classes to be added to the notice. (For custom styling.)
-* `cornerClass: ''`
- Class to be added to the notice for corner styling.
-* `autoDisplay: true`
- Display the notice when it is created. Turn this off to add notifications to the history without displaying them.
-* `width: '360px'`
- Width of the notice.
-* `minHeight: '16px'`
- Minimum height of the notice. It will expand to fit content.
-* `type: 'notice'`
- Type of the notice. 'notice', 'info', 'success', or 'error'.
-* `icon: true`
- Set icon to true to use the default icon for the selected style/type, false for no icon, or a string for your own icon class.
-* `animation: 'fade'`
- The animation to use when displaying and hiding the notice. 'none' and 'fade' are supported through CSS. Others are supported through the Animate module and Animate.css.
-* `animateSpeed: 'normal'`
- Speed at which the notice animates in and out. 'slow', 'normal', or 'fast'. Respectively, 400ms, 250ms, 100ms.
-* `shadow: true`
- Display a drop shadow.
-* `hide: true`
- After a delay, close the notice.
-* `delay: 8000`
- Delay in milliseconds before the notice is closed.
-* `mouseReset: true`
- Reset the hide timer if the mouse moves over the notice.
-* `remove: true`
- Remove the notice's elements from the DOM after it is closed.
-* `destroy: true`
- Whether to remove the notice from the global array when it is closed.
-* `stack: PNotify.defaultStack`
- The stack on which the notices will be placed. Also controls the direction the notices stack.
-* `modules: {}`
- This is where options for modules should be defined.
-
-`}`
-
-```js
-PNotify.defaultStack = {
- dir1: 'down',
- dir2: 'left',
- firstpos1: 25,
- firstpos2: 25,
- spacing1: 36,
- spacing2: 36,
- push: 'bottom',
- context: document.body
-}
-```
-
-[Learn more about stacks.](#Stacks)
-
-## Changing Defaults
-
-```js
-PNotify.defaults.width = '400px';
-```
-
-Changing a default for modules can be done in a couple ways.
-
-```js
-// This will change the default for every notice, and is the recommended way.
-PNotify.modules.History.defaults.maxInStack = 10;
-
-// This will change the default only for notices that don't have a `modules` option.
-PNotify.defaults.modules = {
- History: {
- maxInStack: 10
- }
-};
-```
-
-# Module Options
-
-## Desktop Module
-
-`Desktop: {`
-* `desktop: false`
- Display the notification as a desktop notification.
-* `fallback: true`
- If desktop notifications are not supported or allowed, fall back to a regular notice.
-* `icon: null`
- The URL of the icon to display. If false, no icon will show. If null, a default icon will show.
-* `tag: null`
- Using a tag lets you update an existing notice, or keep from duplicating notices between tabs. If you leave tag null, one will be generated, facilitating the `update` function.
-* `title: null`
- Optionally display a different title for the desktop.
-* `text: null`
- Optionally display different text for the desktop.
-* `options: {}`
- Any additional options to be passed to the Notification constructor.
-
-`}`
-
-## Buttons Module
-
-`Buttons: {`
-* `closer: true`
- Provide a button for the user to manually close the notice.
-* `closerHover: true`
- Only show the closer button on hover.
-* `sticker: true`
- Provide a button for the user to manually stick the notice.
-* `stickerHover: true`
- Only show the sticker button on hover.
-* `labels: {close: 'Close', stick: 'Stick', unstick: 'Unstick'}`
- Lets you change the displayed text, facilitating internationalization.
-* `classes: {closer: null, pinUp: null, pinDown: null}`
- The classes to use for button icons. Leave them null to use the classes from the styling you're using.
-
-`}`
-
-> :information_source: In v4, it's no longer possible to show closer/sticker buttons when the notice is nonblocking.
-
-## NonBlock Module
-
-Requires [NonBlock.js](https://github.com/sciactive/nonblockjs) 1.0.8 or higher.
-
-**It is also deprecated and unnecessary in v4.** All it does is add the 'nonblock' class to your notice. You can do the same yourself with `addClass: 'nonblock'`.
-
-`NonBlock: {`
-* `nonblock: false`
- Use NonBlock.js to create a non-blocking notice. It lets the user click elements underneath it.
-
-`}`
-
-## Mobile Module
-
-`Mobile: {`
-* `swipeDismiss: true`
- Let the user swipe the notice away.
-* `styling: true`
- Styles the notice to look good on mobile.
-
-`}`
-
-## Animate Module
-
-Requires [Animate.css](https://daneden.github.io/animate.css/).
-
-`Animate: {`
-* `animate: false`
- Use animate.css to animate the notice.
-* `inClass: ''`
- The class to use to animate the notice in.
-* `outClass: ''`
- The class to use to animate the notice out.
-
-`}`
-
-The Animate module also creates a method, `attention`, on notices which accepts an attention grabber class and an animation completed callback.
-
-## Confirm Module
-
-`Confirm: {`
-* `confirm: false`
- Make a confirmation box.
-* `focus: null`
- For confirmation boxes, true means the first button or the button with promptTrigger will be focused, and null means focus will change only for modal notices. For prompts, true or null means focus the prompt. When false, focus will not change.
-* `prompt: false`
- Make a prompt.
-* `promptClass: ''`
- Classes to add to the input element of the prompt.
-* `promptValue: ''`
- The value of the prompt. (Note that this is two-way bound to the input.)
-* `promptMultiLine: false`
- Whether the prompt should accept multiple lines of text.
-* `align: 'right'`
- Where to align the buttons. (right, center, left, justify)
-
-```js
-buttons: [
- {
- text: 'Ok',
- textTrusted: false,
- addClass: '',
- primary: true,
- // Whether to trigger this button when the user hits enter in a single line
- // prompt. Also, focus the button if it is a modal prompt.
- promptTrigger: true,
- click: (notice, value) => {
- notice.close();
- notice.fire('pnotify.confirm', {notice, value});
- }
- },
- {
- text: 'Cancel',
- textTrusted: false,
- addClass: '',
- click: (notice) => {
- notice.close();
- notice.fire('pnotify.cancel', {notice});
- }
- }
-]
-```
-* The buttons to display, and their callbacks. If a button has promptTrigger set to true, it will be triggered when the user hits enter in a prompt (unless they hold shift).
-
-`}`
-
-Because the default buttons fire notice events on confirmation and cancellation, you can listen for them like this:
-
-```js
-const notice = PNotify.alert({
- title: 'Confirmation Needed',
- text: 'Are you sure?',
- hide: false,
- modules: {
- Confirm: {
- confirm: true
- }
- }
-});
-notice.on('pnotify.confirm', () => {
- // User confirmed, continue here...
-});
-notice.on('pnotify.cancel', () => {
- // User canceled, continue here...
-});
-```
-
-## History Module
-
-`History: {`
-* `history: true`
- Place the notice in the history.
-* `maxInStack: Infinity`
- Maximum number of notices to have open in its stack.
-
-`}`
-
-The History module also has two methods:
-
-* `PNotify.modules.History.showLast(stack)`
- Reopen the last closed notice from a stack that was placed in the history. If no stack is provided, it will use the default stack.
-* `PNotify.modules.History.showAll(stack)`
- Reopen all notices from a stack that were placed in the history. If no stack is provided, it will also use the default stack. If stack is `true`, it will reopen all notices from every stack.
-
-> :information_source: In v4, the History module can no longer make a dropdown for you. But hey, it's smaller now.
-
-## Callbacks Module
-
-The callback options all expect the value to be a callback function. If the function returns false on the `beforeOpen` or `beforeClose` callback, that event will be canceled.
-
-`Callbacks: {`
-* `beforeInit`
- Called before the notice has been initialized. Given one argument, the options object.
-* `afterInit`
- Called after the notice has been initialized. Given one argument, the notice object.
-* `beforeOpen`
- Called before the notice opens. Given one argument, the notice object.
-* `afterOpen`
- Called after the notice opens. Given one argument, the notice object.
-* `beforeClose`
- Called before the notice closes. Given one argument, the notice object.
-* `afterClose`
- Called after the notice closes. Given one argument, the notice object.
-
-`}`
-
-# Static Methods and Properties
-
-* `PNotify.alert(options)`
- Create a notice.
-* `PNotify.notice(options)`
- Create a notice with 'notice' type.
-* `PNotify.info(options)`
- Create a notice with 'info' type.
-* `PNotify.success(options)`
- Create a notice with 'success' type.
-* `PNotify.error(options)`
- Create a notice with 'error' type.
-* `PNotify.closeAll()`
- Close all notices.
-* `PNotify.removeAll()`
- Alias for closeAll(). (Deprecated)
-* `PNotify.closeStack(stack)`
- Close all the notices in a stack.
-* `PNotify.removeStack(stack)`
- Alias for closeStack(stack). (Deprecated)
-* `PNotify.positionAll()`
- Reposition all notices.
-* `PNotify.VERSION`
- PNotify version number.
-* `PNotify.defaults`
- Defaults for options.
-* `PNotify.defaultStack`
- The default stack object.
-* `PNotify.notices`
- An array of all active notices.
-* `PNotify.modules`
- This object holds all the PNotify modules.
-* `PNotify.styling`
- Styling objects.
-
-# Instance Methods and Properties
-
-* `notice.open()`
- Open the notice.
-* `notice.close()`
- Close the notice.
-* `notice.remove()`
- Alias for close(). (Deprecated)
-* `notice.update(options)`
- Update the notice with new options.
-* `notice.addModuleClass(...classNames)`
- This is for modules to add classes to the notice.
-* `notice.removeModuleClass(...classNames)`
- This is for modules to remove classes from the notice.
-* `notice.hasModuleClass(...classNames)`
- This is for modules to test classes on the notice.
-* `notice.refs.elem`
- The notice's DOM element.
-* `notice.refs.container`
- The notice container DOM element.
-* `notice.refs.titleContainer`
- The title container DOM element.
-* `notice.refs.textContainer`
- The text container DOM element.
-* `notice.refs.iconContainer`
- The icon container DOM element.
-
-## From the [Svelte Component API](https://v2.svelte.dev/guide#component-api)
-
-* `notice.get(option)`
- Get the value of an option.
-* `notice.set(options)`
- You probably want to use `update(options)` instead. It has some special PNotify secret sauce to make sure your notice doesn't break.
-* `notice.observe(key, callback[, options])`
- Observe an option. See the Svelte docs for more info.
-* `notice.destroy()`
- Removes the component from the DOM and any observers/event listeners. You probably want to use `close()` instead. It will animate the notice out and you can open it again. Once you destroy it, you can't open it again.
-
-## Events
-
-* `notice.on(eventName, callback)`
- Assign a callback to an event. Callback receives an `event` argument.
-* `notice.fire(eventName, event)`
- Fire an event.
-
-# Stacks
-
-A stack is an object used to determine where to position notices.
-
-Stack properties:
-
-* `dir1`
- The primary stacking direction. Can be `'up'`, `'down'`, `'right'`, or `'left'`.
-* `firstpos1`
- Number of pixels from the edge of the context, relative to `dir1`, the first notice will appear. If undefined, the current position of the notice, whatever that is, will be used.
-* `spacing1`
- Number of pixels between notices along `dir1`. If undefined, `25` will be used.
-* `dir2`
- The secondary stacking direction. Should be a perpendicular direction to `dir1`. The notices will continue in this direction when they reach the edge of the viewport along `dir1`.
-* `firstpos2`
- Number of pixels from the edge of the context, relative to `dir2`, the first notice will appear. If undefined, the current position of the notice, whatever that is, will be used.
-* `spacing2`
- Number of pixels between notices along `dir2`. If undefined, `25` will be used.
-* `push`
- Where, in the stack, to push new notices. Can be `'top'` or `'bottom'`.
-* `modal`
- Whether to create a modal overlay when this stack's notices are open.
-* `overlayClose`
- Whether clicking on the modal overlay should close the stack's notices.
-* `context`
- The DOM element this stack's notices should appear in. If undefined, `document.body` will be used.
-
-Stack behavior:
-
-* If there is no `dir1` property, the notice will be centered in the context.
-* If there is a `dir1` and no `dir2`, the notices will be centered along the axis of `dir1`.
-* The `firstpos*` values are relative to an edge determined by the corresponding `dir*` value.
- * `dirX === 'up'` means `firstposX` is relative to the **bottom** edge.
- * `dirX === 'down'` means `firstposX` is relative to the **top** edge.
- * `dirX === 'left'` means `firstposX` is relative to the **right** edge.
- * `dirX === 'right'` means `firstposX` is relative to the **left** edge.
-* Stacks are independent of each other, so a stack doesn't know and doesn't care if it overlaps (and blocks) another stack.
-* Stack objects are used and manipulated by PNotify, and therefore, should be a variable when passed.
-
-> :warning: Calling something like `PNotify.alert({text: 'notice', stack: {dir1: 'down', firstpos1: 25}});` may not do what you want. It will create a notice, but that notice will be in its own stack and will overlap other notices.
-
-## Example Stack
-
-Here is an example stack with comments to explain. You can play with it [here](https://codesandbox.io/s/2po6zq9yrr).
-
-```js
-const stackBottomModal = {
- dir1: 'up', // With a dir1 of 'up', the stacks will start appearing at the bottom.
- // Without a `dir2`, this stack will be horizontally centered, since the `dir1` axis is vertical.
- firstpos1: 25, // The notices will appear 25 pixels from the bottom of the context.
- // Without a `spacing1`, this stack's notices will be placed 25 pixels apart.
- push: 'top', // Each new notice will appear at the bottom of the screen, which is where the 'top' of the stack is. Other notices will be pushed up.
- modal: true, // When a notice appears in this stack, a modal overlay will be created.
- overlayClose: true, // When the user clicks on the overlay, all notices in this stack will be closed.
- context: document.getElementById('page-container') // The notices will be placed in the 'page-container' element.
-};
-```
-
-If you just want to position a single notice programmatically, and don't want to add any other notices into the stack, you can use something like this:
-
-```js
-PNotify.alert({
- text: "Notice that's positioned in its own stack.",
- stack: {
- dir1: 'down', dir2: 'right', // Position from the top left corner.
- firstpos1: 90, firstpos2: 90 // 90px from the top, 90px from the left.
- }
-});
-```
-
-# Features
-
-* Rich graphical features and effects.
- * Material, Bootstrap 3/4, Font Awesome 4/5, or the stand-alone theme, Bright Theme.
- * Mobile styling and swipe support.
- * Timed hiding.
- * Slick animations with Animate.css.
- * Attention getters with Animate.css.
-* Highly customizable UI.
- * Sticky notices.
- * Optional close and stick buttons.
- * Non-blocking notices for less intrusive use.
- * Notification types: notice, info, success, and error.
- * Stacks allow notices to position together or independently.
- * Control stack direction and push to top or bottom.
- * Modal notices.
- * Confirm dialogs, alert buttons, and prompts.
- * RTL language support.
-* Feature rich API.
- * Desktop notifications based on the Web Notifications standard.
- * Dynamically update existing notices.
- * Put forms and other HTML in notices.
- * By default, escapes text to prevent XSS attack.
- * Callbacks for lifespan events.
- * Notice history for reshowing old notices.
-* Universally compatible.
- * Works with any frontend library (React, Angular, Svelte, Vue, Ember, etc.).
- * Works well with bundlers (Webpack, Rollup, etc.).
- * No dependencies for most features.
-
-# Licensing and Additional Info
-
-Copyright 2009-2020 Hunter Perrin
-Copyright 2015 Google, Inc.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-See http://sciactive.com/pnotify/ for more information, and demos.
diff --git a/node_modules/pnotify/dist/PNotifyBrightTheme.css b/node_modules/pnotify/dist/PNotifyBrightTheme.css
deleted file mode 100644
index ec3014b..0000000
--- a/node_modules/pnotify/dist/PNotifyBrightTheme.css
+++ /dev/null
@@ -1 +0,0 @@
-[ui-pnotify].ui-pnotify .brighttheme{-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}[ui-pnotify].ui-pnotify .brighttheme.ui-pnotify-container{padding:1.3rem}[ui-pnotify].ui-pnotify-with-icon .brighttheme .ui-pnotify-confirm,[ui-pnotify].ui-pnotify-with-icon .brighttheme .ui-pnotify-text,[ui-pnotify].ui-pnotify-with-icon .brighttheme .ui-pnotify-title{margin-left:1.8rem}[dir=rtl] [ui-pnotify].ui-pnotify-with-icon .brighttheme .ui-pnotify-confirm,[dir=rtl] [ui-pnotify].ui-pnotify-with-icon .brighttheme .ui-pnotify-text,[dir=rtl] [ui-pnotify].ui-pnotify-with-icon .brighttheme .ui-pnotify-title{margin-right:1.8rem;margin-left:0}[ui-pnotify].ui-pnotify .brighttheme .ui-pnotify-title{font-size:1.2rem;line-height:1.4rem;margin-top:-.2rem;margin-bottom:1rem}[ui-pnotify].ui-pnotify .brighttheme .ui-pnotify-text{font-size:1rem;line-height:1.2rem;margin-top:0}[ui-pnotify].ui-pnotify .brighttheme .ui-pnotify-icon{line-height:1}[ui-pnotify].ui-pnotify .brighttheme-notice{background-color:#ffffa2;border:0 solid #ff0}[ui-pnotify].ui-pnotify .brighttheme-notice div,[ui-pnotify].ui-pnotify .brighttheme-notice h4{color:#4f4f00}[ui-pnotify].ui-pnotify .brighttheme-info{background-color:#8fcedd;border:0 solid #0286a5}[ui-pnotify].ui-pnotify .brighttheme-info div,[ui-pnotify].ui-pnotify .brighttheme-info h4{color:#012831}[ui-pnotify].ui-pnotify .brighttheme-success{background-color:#aff29a;border:0 solid #35db00}[ui-pnotify].ui-pnotify .brighttheme-success div,[ui-pnotify].ui-pnotify .brighttheme-success h4{color:#104300}[ui-pnotify].ui-pnotify .brighttheme-error{background-color:#ffaba2;background-image:repeating-linear-gradient(135deg,transparent,transparent 35px,rgba(255,255,255,.3) 35px,rgba(255,255,255,.3) 70px);border:0 solid #ff1800}[ui-pnotify].ui-pnotify .brighttheme-error div,[ui-pnotify].ui-pnotify .brighttheme-error h4{color:#4f0800}[ui-pnotify].ui-pnotify .brighttheme .ui-pnotify-closer,[ui-pnotify].ui-pnotify .brighttheme .ui-pnotify-sticker{font-size:1rem;line-height:1.2rem}[ui-pnotify].ui-pnotify .brighttheme-icon-closer,[ui-pnotify].ui-pnotify .brighttheme-icon-error,[ui-pnotify].ui-pnotify .brighttheme-icon-info,[ui-pnotify].ui-pnotify .brighttheme-icon-notice,[ui-pnotify].ui-pnotify .brighttheme-icon-sticker,[ui-pnotify].ui-pnotify .brighttheme-icon-success{position:relative;width:1rem;height:1rem;font-size:1rem;font-weight:700;line-height:1rem;font-family:"Courier New",Courier,monospace;border-radius:50%}[ui-pnotify].ui-pnotify .brighttheme-icon-closer:after,[ui-pnotify].ui-pnotify .brighttheme-icon-info:after,[ui-pnotify].ui-pnotify .brighttheme-icon-notice:after,[ui-pnotify].ui-pnotify .brighttheme-icon-sticker:after,[ui-pnotify].ui-pnotify .brighttheme-icon-success:after{position:absolute;top:0;left:.2rem}[ui-pnotify].ui-pnotify .brighttheme-icon-notice{background-color:#2e2e00;color:#ffffa2}[ui-pnotify].ui-pnotify .brighttheme-icon-notice:after{content:"!"}[ui-pnotify].ui-pnotify .brighttheme-icon-info{background-color:#012831;color:#8fcedd}[ui-pnotify].ui-pnotify .brighttheme-icon-info:after{content:"i"}[ui-pnotify].ui-pnotify .brighttheme-icon-success{background-color:#104300;color:#aff29a}[ui-pnotify].ui-pnotify .brighttheme-icon-success:after{content:"\002713"}[ui-pnotify].ui-pnotify .brighttheme-icon-error{width:0;height:0;font-size:0;line-height:0;border-radius:0;border-left:.6rem solid transparent;border-right:.6rem solid transparent;border-bottom:1.2rem solid #2e0400;color:#ffaba2}[ui-pnotify].ui-pnotify .brighttheme-icon-error:after{position:absolute;top:.1rem;left:-.25rem;font-size:.9rem;font-weight:700;line-height:1.4rem;font-family:"Courier New",Courier,monospace;content:"!"}[ui-pnotify].ui-pnotify .brighttheme-icon-closer,[ui-pnotify].ui-pnotify .brighttheme-icon-sticker{display:inline-block}[ui-pnotify].ui-pnotify .brighttheme-icon-closer:after{content:"\002715"}[ui-pnotify].ui-pnotify .brighttheme-icon-sticker:after{top:-1px;content:"\002016"}[ui-pnotify].ui-pnotify .brighttheme-icon-sticker.brighttheme-icon-stuck:after{content:"\00003E"}[ui-pnotify].ui-pnotify .brighttheme .ui-pnotify-confirm{margin-top:1rem}[ui-pnotify].ui-pnotify .brighttheme .ui-pnotify-prompt-bar{margin-bottom:1rem}[ui-pnotify].ui-pnotify .brighttheme .ui-pnotify-action-button{text-transform:uppercase;font-weight:700;padding:.4rem 1rem;border:none;background:0 0;cursor:pointer}[ui-pnotify].ui-pnotify .brighttheme-notice .ui-pnotify-action-button.brighttheme-primary{background-color:#ff0;color:#4f4f00}[ui-pnotify].ui-pnotify .brighttheme-info .ui-pnotify-action-button.brighttheme-primary{background-color:#0286a5;color:#012831}[ui-pnotify].ui-pnotify .brighttheme-success .ui-pnotify-action-button.brighttheme-primary{background-color:#35db00;color:#104300}[ui-pnotify].ui-pnotify .brighttheme-error .ui-pnotify-action-button.brighttheme-primary{background-color:#ff1800;color:#4f0800}
\ No newline at end of file
diff --git a/node_modules/pnotify/dist/es/PNotify.js b/node_modules/pnotify/dist/es/PNotify.js
deleted file mode 100644
index f5a0f3c..0000000
--- a/node_modules/pnotify/dist/es/PNotify.js
+++ /dev/null
@@ -1,2 +0,0 @@
-let PNotify,posTimer,onDocumentLoaded=()=>{PNotify.defaultStack.context=document.body,window.addEventListener("resize",()=>{posTimer&&clearTimeout(posTimer),posTimer=setTimeout(()=>{PNotify.positionAll()},10)})},createStackOverlay=t=>{const e=document.createElement("div");e.classList.add("ui-pnotify-modal-overlay"),t.context!==document.body&&(e.style.height=t.context.scrollHeight+"px",e.style.width=t.context.scrollWidth+"px"),e.addEventListener("click",()=>{t.overlayClose&&PNotify.closeStack(t)}),t.overlay=e},insertStackOverlay=t=>{t.overlay.parentNode!==t.context&&(t.overlay=t.context.insertBefore(t.overlay,t.context.firstChild))},removeStackOverlay=t=>{t.overlay.parentNode&&t.overlay.parentNode.removeChild(t.overlay)};const getDefaultArgs=(t,e)=>("object"!=typeof t&&(t={text:t}),e&&(t.type=e),{target:document.body,data:t});function _styles({styling:t}){return"object"==typeof t?t:PNotify.styling[t]}function _icons({icons:t}){return"object"==typeof t?t:PNotify.icons[t]}function _widthStyle({width:t}){return"string"==typeof t?"width: "+t+";":""}function _minHeightStyle({minHeight:t}){return"string"==typeof t?"min-height: "+t+";":""}function data(){const t=Object.assign({_state:"initializing",_timer:null,_animTimer:null,_animating:!1,_animatingClass:"",_moveClass:"",_timerHide:!1,_moduleClasses:[],_moduleIsNoticeOpen:!1,_modules:{},_modulesPrependContainer:PNotify.modulesPrependContainer,_modulesAppendContainer:PNotify.modulesAppendContainer},PNotify.defaults);return t.modules=Object.assign({},PNotify.defaults.modules),t}var methods={runModules(t){if("init"===t){for(let t in PNotify.modules)if(PNotify.modules.hasOwnProperty(t)&&"function"==typeof PNotify.modules[t].init){const e=PNotify.modules[t].init(this);this.initModule(e)}}else{const{_modules:e}=this.get();for(let i in e){if(!e.hasOwnProperty(i))continue;const n=Object.assign({_notice:this,_options:this.get()},this.get().modules[i]);e[i].set(n),"function"==typeof e[i][t]&&e[i][t]()}}},initModule(t){const{modules:e}=this.get();e.hasOwnProperty(t.constructor.key)||(e[t.constructor.key]={});const i=Object.assign({_notice:this,_options:this.get()},e[t.constructor.key]);t.initModule(i);const{_modules:n}=this.get();n[t.constructor.key]=t},update(t){const e=this.get().hide,i=this.get().icon;this.set(t),this.runModules("update"),this.get().hide?e||this.queueClose():this.cancelClose(),this.queuePosition();const{icon:n}=this.get();return n!==i&&(!0===n&&"fontawesome5"===this.get().icons||"string"==typeof n&&n.match(/(^| )fa[srlb]($| )/))&&(this.set({icon:!1}),this.set({icon:n})),this},open(){const{_state:t,hide:e}=this.get();if("opening"===t)return;if("open"===t)return void(e&&this.queueClose());this.set({_state:"opening",_animatingClass:"ui-pnotify-initial-hidden"}),this.runModules("beforeOpen");let{stack:i}=this.get();if(!this.refs.elem.parentNode||i&&i.context&&i.context!==this.refs.elem.parentNode)if(i&&i.context)i.context.appendChild(this.refs.elem);else{if(!document.body)throw new Error("No context to open this notice in.");document.body.appendChild(this.refs.elem)}return setTimeout(()=>{i&&(i.animation=!1,PNotify.positionAll(),i.animation=!0),this.animateIn(()=>{this.get().hide&&this.queueClose(),this.set({_state:"open"}),this.runModules("afterOpen")})},0),this},remove(t){return this.close(t)},close(t){const{_state:e}=this.get();if("closing"===e||"closed"===e)return;this.set({_state:"closing",_timerHide:!!t}),this.runModules("beforeClose");const{_timer:i}=this.get();return i&&clearTimeout&&(clearTimeout(i),this.set({_timer:null})),this.animateOut(()=>{if(this.set({_state:"closed"}),this.runModules("afterClose"),this.queuePosition(),this.get().remove&&this.refs.elem.parentNode.removeChild(this.refs.elem),this.runModules("beforeDestroy"),this.get().destroy&&null!==PNotify.notices){const t=PNotify.notices.indexOf(this);-1!==t&&PNotify.notices.splice(t,1)}this.runModules("afterDestroy")}),this},animateIn(t){this.set({_animating:"in"});const e=()=>{this.refs.elem.removeEventListener("transitionend",e);const{_animTimer:i,_animating:n,_moduleIsNoticeOpen:o}=this.get();if(i&&clearTimeout(i),"in"!==n)return;let s=o;if(!s){const t=this.refs.elem.getBoundingClientRect();for(let e in t)if(t[e]>0){s=!0;break}}s?(t&&t.call(),this.set({_animating:!1})):this.set({_animTimer:setTimeout(e,40)})};"fade"===this.get().animation?(this.refs.elem.addEventListener("transitionend",e),this.set({_animatingClass:"ui-pnotify-in"}),this.refs.elem.style.opacity,this.set({_animatingClass:"ui-pnotify-in ui-pnotify-fade-in"}),this.set({_animTimer:setTimeout(e,650)})):(this.set({_animatingClass:"ui-pnotify-in"}),e())},animateOut(t){this.set({_animating:"out"});const e=()=>{this.refs.elem.removeEventListener("transitionend",e);const{_animTimer:i,_animating:n,_moduleIsNoticeOpen:o}=this.get();if(i&&clearTimeout(i),"out"!==n)return;let s=o;if(!s){const t=this.refs.elem.getBoundingClientRect();for(let e in t)if(t[e]>0){s=!0;break}}if(this.refs.elem.style.opacity&&"0"!==this.refs.elem.style.opacity&&s)this.set({_animTimer:setTimeout(e,40)});else{this.set({_animatingClass:""});const{stack:e}=this.get();if(e&&e.overlay){let t=!1;for(let i=0;in||("left"===t.dir1||"right"===t.dir1)&&a>o)&&(t.nextpos1=t.firstpos1,t.nextpos2+=t.addpos2+(void 0===t.spacing2?25:t.spacing2),t.addpos2=0),"number"==typeof t.nextpos2&&(e.style[s]=t.nextpos2+"px",t.animation||e.style[s]),t.dir2){case"down":case"up":e.offsetHeight+(parseFloat(e.style.marginTop,10)||0)+(parseFloat(e.style.marginBottom,10)||0)>t.addpos2&&(t.addpos2=e.offsetHeight);break;case"left":case"right":e.offsetWidth+(parseFloat(e.style.marginLeft,10)||0)+(parseFloat(e.style.marginRight,10)||0)>t.addpos2&&(t.addpos2=e.offsetWidth)}}else if(t.dir1){let i,o;switch(t.dir1){case"down":case"up":o=["left","right"],i=t.context.scrollWidth/2-e.offsetWidth/2;break;case"left":case"right":o=["top","bottom"],i=n/2-e.offsetHeight/2}e.style[o[0]]=i+"px",e.style[o[1]]="auto",t.animation||e.style[o[0]]}if(t.dir1)switch("number"==typeof t.nextpos1&&(e.style[i]=t.nextpos1+"px",t.animation||e.style[i]),t.dir1){case"down":case"up":t.nextpos1+=e.offsetHeight+(void 0===t.spacing1?25:t.spacing1);break;case"left":case"right":t.nextpos1+=e.offsetWidth+(void 0===t.spacing1?25:t.spacing1)}else{let i=o/2-e.offsetWidth/2,s=n/2-e.offsetHeight/2;e.style.left=i+"px",e.style.top=s+"px",t.animation||e.style.left}return this},queuePosition(t){return posTimer&&clearTimeout(posTimer),t||(t=10),posTimer=setTimeout(()=>{PNotify.positionAll()},t),this},cancelRemove(){return this.cancelClose()},cancelClose(){const{_timer:t,_animTimer:e,_state:i,animation:n}=this.get();return t&&clearTimeout(t),e&&clearTimeout(e),"closing"===i&&this.set({_state:"open",_animating:!1,_animatingClass:"fade"===n?"ui-pnotify-in ui-pnotify-fade-in":"ui-pnotify-in"}),this},queueRemove(){return this.queueClose()},queueClose(){return this.cancelClose(),this.set({_timer:setTimeout(()=>this.close(!0),isNaN(this.get().delay)?0:this.get().delay)}),this},addModuleClass(...t){const{_moduleClasses:e}=this.get();for(let i=0;i{if(this.get().mouseReset&&"out"===this.get()._animating){if(!this.get()._timerHide)return;this.cancelClose()}this.get().hide&&this.get().mouseReset&&this.cancelClose()}),this.on("mouseleave",t=>{this.get().hide&&this.get().mouseReset&&"out"!==this.get()._animating&&this.queueClose(),PNotify.positionAll()});let{stack:t}=this.get();t&&"top"===t.push?PNotify.notices.splice(0,0,this):PNotify.notices.push(this),this.runModules("init"),this.set({_state:"closed"}),this.get().autoDisplay&&this.open()}function setup(t){(PNotify=t).VERSION="4.0.1",PNotify.defaultStack={dir1:"down",dir2:"left",firstpos1:25,firstpos2:25,spacing1:36,spacing2:36,push:"bottom",context:window&&document.body},PNotify.defaults={title:!1,titleTrusted:!1,text:!1,textTrusted:!1,styling:"brighttheme",icons:"brighttheme",addClass:"",cornerClass:"",autoDisplay:!0,width:"360px",minHeight:"16px",type:"notice",icon:!0,animation:"fade",animateSpeed:"normal",shadow:!0,hide:!0,delay:8e3,mouseReset:!0,remove:!0,destroy:!0,stack:PNotify.defaultStack,modules:{}},PNotify.notices=[],PNotify.modules={},PNotify.modulesPrependContainer=[],PNotify.modulesAppendContainer=[],PNotify.alert=(t=>new PNotify(getDefaultArgs(t))),PNotify.notice=(t=>new PNotify(getDefaultArgs(t,"notice"))),PNotify.info=(t=>new PNotify(getDefaultArgs(t,"info"))),PNotify.success=(t=>new PNotify(getDefaultArgs(t,"success"))),PNotify.error=(t=>new PNotify(getDefaultArgs(t,"error"))),PNotify.removeAll=(()=>{PNotify.closeAll()}),PNotify.closeAll=(()=>{for(let t=0;t{PNotify.closeStack(t)}),PNotify.closeStack=(t=>{if(!1!==t)for(let e=0;e{if(posTimer&&clearTimeout(posTimer),posTimer=null,PNotify.notices.length>0){for(let t=0;t .ui-pnotify{position:fixed;z-index:100040}body > .ui-pnotify.ui-pnotify-modal{z-index:100042}.ui-pnotify{position:absolute;height:auto;z-index:1;display:none}.ui-pnotify.ui-pnotify-modal{z-index:3}.ui-pnotify.ui-pnotify-in{display:block}.ui-pnotify.ui-pnotify-initial-hidden{display:block;visibility:hidden}.ui-pnotify.ui-pnotify-move{transition:left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-slow{transition:opacity .4s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-slow.ui-pnotify.ui-pnotify-move{transition:opacity .4s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-normal{transition:opacity .25s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-normal.ui-pnotify.ui-pnotify-move{transition:opacity .25s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-fast{transition:opacity .1s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-fast.ui-pnotify.ui-pnotify-move{transition:opacity .1s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-in{opacity:1}.ui-pnotify .ui-pnotify-shadow{-webkit-box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1);-moz-box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1);box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1)}.ui-pnotify-container{background-position:0 0;padding:.8em;height:100%;margin:0}.ui-pnotify-container:after{content:" ";visibility:hidden;display:block;height:0;clear:both}.ui-pnotify-container.ui-pnotify-sharp{-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.ui-pnotify-title{display:block;white-space:pre-line;margin-bottom:.4em;margin-top:0}.ui-pnotify.ui-pnotify-with-icon .ui-pnotify-title,.ui-pnotify.ui-pnotify-with-icon .ui-pnotify-text{margin-left:24px}[dir=rtl] .ui-pnotify.ui-pnotify-with-icon .ui-pnotify-title,[dir=rtl] .ui-pnotify.ui-pnotify-with-icon .ui-pnotify-text{margin-right:24px;margin-left:0}.ui-pnotify-title-bs4{font-size:1.2rem}.ui-pnotify-text{display:block;white-space:pre-line}.ui-pnotify-icon,.ui-pnotify-icon span{display:block;float:left}[dir=rtl] .ui-pnotify-icon,[dir=rtl] .ui-pnotify-icon span{float:right}.ui-pnotify-icon-bs3 > span{position:relative;top:2px}.ui-pnotify-icon-bs4 > span{position:relative;top:4px}.ui-pnotify-modal-overlay{background-color:rgba(0, 0, 0, .4);top:0;left:0;position:absolute;height:100%;width:100%;z-index:2}body > .ui-pnotify-modal-overlay{position:fixed;z-index:100041}',append(document.head,t)}function get_each1_context(t,e,i){const n=Object.create(t);return n.module=e[i],n}function get_each0_context(t,e,i){const n=Object.create(t);return n.module=e[i],n}function create_main_fragment(t,e){var i,n,o,s,r,a,c,l,f,d=[],u=blankObject(),h=[],m=blankObject(),p=e._modulesPrependContainer;const y=t=>t.module.key;for(var _=0;_t.module.key;for(_=0;_{oncreate.call(this),this.fire("update",{changed:assignTrue({},this._state),current:this._state})}),t.target&&(this._fragment.c(),this._mount(t.target,t.anchor),flush(this))}function createElement(t){return document.createElement(t)}function append(t,e){t.appendChild(e)}function blankObject(){return Object.create(null)}function createText(t){return document.createTextNode(t)}function setAttribute(t,e,i){null==i?t.removeAttribute(e):t.setAttribute(e,i)}function addListener(t,e,i,n){t.addEventListener(e,i,n)}function insert(t,e,i){t.insertBefore(e,i)}function updateKeyedEach(t,e,i,n,o,s,r,a,c,l,f,d,u,h){for(var m=t.length,p=r.length,y=m,_={};y--;)_[t[y].key]=y;var g=[],b={},v={};for(y=p;y--;){var x=h(s,r,y),N=n(x),k=a[N];k?o&&k.p(i,x):(k=f(e,N,x)).c(),g[y]=b[N]=k,N in _&&(v[N]=Math.abs(y-_[N]))}var C={},w={};function P(t){t[d](c,u),a[t.key]=t,u=t.first,p--}for(;m&&p;){var T=g[p-1],L=t[m-1],S=T.key,O=L.key;T===L?(u=T.first,m--,p--):b[O]?!a[S]||C[S]?P(T):w[O]?m--:v[S]>v[O]?(w[S]=!0,P(T)):(C[O]=!0,m--):(l(L,a),m--)}for(;m--;){b[(L=t[m]).key]||l(L,a)}for(;p;)P(g[p-1]);return g}function destroyBlock(t,e){t.d(1),e[t.key]=null}function detachNode(t){t.parentNode.removeChild(t)}function removeListener(t,e,i,n){t.removeEventListener(e,i,n)}function createComment(){return document.createComment("")}function setData(t,e){t.data=""+e}function detachBetween(t,e){for(;t.nextSibling&&t.nextSibling!==e;)t.parentNode.removeChild(t.nextSibling)}function init(t,e){t._handlers=blankObject(),t._slots=blankObject(),t._bind=e._bind,t._staged={},t.options=e,t.root=e.root||t,t.store=e.store||t.root.store,e.root||(t._beforecreate=[],t._oncreate=[],t._aftercreate=[])}function assign(t,e){for(var i in e)t[i]=e[i];return t}function assignTrue(t,e){for(var i in e)t[i]=1;return t}function flush(t){t._lock=!0,callAll(t._beforecreate),callAll(t._oncreate),callAll(t._aftercreate),t._lock=!1}function destroy(t){this.destroy=noop,this.fire("destroy"),this.set=noop,this._fragment.d(!1!==t),this._fragment=null,this._state={}}function get(){return this._state}function fire(t,e){var i=t in this._handlers&&this._handlers[t].slice();if(i)for(var n=0;n0&&(i=t.animateSpeed),i/=1e3,e.refs.elem.style.WebkitAnimationDuration=i+"s",e.refs.elem.style.MozAnimationDuration=i+"s",e.refs.elem.style.animationDuration=i+"s"}else e._animateIn&&e._animateOut&&(e.animateIn=e._animateIn,delete e._animateIn,e.animateOut=e._animateOut,delete e._animateOut)},animateIn(e){const{_notice:t}=this.get();t.set({_animating:"in"});const n=()=>{t.refs.elem.removeEventListener("webkitAnimationEnd",n),t.refs.elem.removeEventListener("mozAnimationEnd",n),t.refs.elem.removeEventListener("MSAnimationEnd",n),t.refs.elem.removeEventListener("oanimationend",n),t.refs.elem.removeEventListener("animationend",n),t.set({_animatingClass:"ui-pnotify-in animated"}),e&&e.call(),t.set({_animating:!1})};t.refs.elem.addEventListener("webkitAnimationEnd",n),t.refs.elem.addEventListener("mozAnimationEnd",n),t.refs.elem.addEventListener("MSAnimationEnd",n),t.refs.elem.addEventListener("oanimationend",n),t.refs.elem.addEventListener("animationend",n),t.set({_animatingClass:"ui-pnotify-in animated "+this.get().inClass})},animateOut(e){const{_notice:t}=this.get();t.set({_animating:"out"});const n=()=>{t.refs.elem.removeEventListener("webkitAnimationEnd",n),t.refs.elem.removeEventListener("mozAnimationEnd",n),t.refs.elem.removeEventListener("MSAnimationEnd",n),t.refs.elem.removeEventListener("oanimationend",n),t.refs.elem.removeEventListener("animationend",n),t.set({_animatingClass:"animated"}),e&&e.call(),t.set({_animating:!1})};t.refs.elem.addEventListener("webkitAnimationEnd",n),t.refs.elem.addEventListener("mozAnimationEnd",n),t.refs.elem.addEventListener("MSAnimationEnd",n),t.refs.elem.addEventListener("oanimationend",n),t.refs.elem.addEventListener("animationend",n),t.set({_animatingClass:"ui-pnotify-in animated "+this.get().outClass})}};function setup(e){e.key="Animate",e.defaults={animate:!1,inClass:"",outClass:""},e.init=(t=>(t.attention=((e,n)=>{const i=()=>{t.refs.container.removeEventListener("webkitAnimationEnd",i),t.refs.container.removeEventListener("mozAnimationEnd",i),t.refs.container.removeEventListener("MSAnimationEnd",i),t.refs.container.removeEventListener("oanimationend",i),t.refs.container.removeEventListener("animationend",i),t.refs.container.classList.remove(e),n&&n.call(t)};t.refs.container.addEventListener("webkitAnimationEnd",i),t.refs.container.addEventListener("mozAnimationEnd",i),t.refs.container.addEventListener("MSAnimationEnd",i),t.refs.container.addEventListener("oanimationend",i),t.refs.container.addEventListener("animationend",i),t.refs.container.classList.add("animated"),t.refs.container.classList.add(e)}),new e({target:document.body}))),PNotify.modules.Animate=e}function create_main_fragment(e,t){return{c:noop,m:noop,p:noop,d:noop}}function PNotifyAnimate(e){init(this,e),this._state=assign(data(),e.data),this._intro=!0,this._fragment=create_main_fragment(this,this._state),e.target&&(this._fragment.c(),this._mount(e.target,e.anchor))}function noop(){}function init(e,t){e._handlers=blankObject(),e._slots=blankObject(),e._bind=t._bind,e._staged={},e.options=t,e.root=t.root||e,e.store=t.store||e.root.store,t.root||(e._beforecreate=[],e._oncreate=[],e._aftercreate=[])}function assign(e,t){for(var n in t)e[n]=t[n];return e}function destroy(e){this.destroy=noop,this.fire("destroy"),this.set=noop,this._fragment.d(!1!==e),this._fragment=null,this._state={}}function get(){return this._state}function fire(e,t){var n=e in this._handlers&&this._handlers[e].slice();if(n)for(var i=0;ithis.set({_mouseIsIn:!0})),t.on("mouseleave",()=>this.set({_mouseIsIn:!1})),t.on("state",({changed:e,current:t})=>{if(!e.hide)return;const{sticker:s}=this.get();if(!s)return;const i=t.hide?this.get().classes.pinUp:this.get().classes.pinDown;("fontawesome5"===this.get()._notice.get().icons||"string"==typeof i&&i.match(/(^| )fa[srlb]($| )/))&&(this.set({sticker:!1}),this.set({sticker:!0}))})},handleStickerClick(){const{_notice:e}=this.get();e.update({hide:!e.get().hide})},handleCloserClick(){this.get()._notice.close(!1),this.set({_mouseIsIn:!1})}};function oncreate(){this.fire("init",{module:this})}function setup(e){e.key="Buttons",e.defaults={closer:!0,closerHover:!0,sticker:!0,stickerHover:!0,labels:{close:"Close",stick:"Stick",unstick:"Unstick"},classes:{closer:null,pinUp:null,pinDown:null}},PNotify.modules.Buttons=e,PNotify.modulesPrependContainer.push(e),Object.assign(PNotify.icons.brighttheme,{closer:"brighttheme-icon-closer",pinUp:"brighttheme-icon-sticker",pinDown:"brighttheme-icon-sticker brighttheme-icon-stuck"}),Object.assign(PNotify.icons.bootstrap3,{closer:"glyphicon glyphicon-remove",pinUp:"glyphicon glyphicon-pause",pinDown:"glyphicon glyphicon-play"}),Object.assign(PNotify.icons.fontawesome4,{closer:"fa fa-times",pinUp:"fa fa-pause",pinDown:"fa fa-play"}),Object.assign(PNotify.icons.fontawesome5,{closer:"fas fa-times",pinUp:"fas fa-pause",pinDown:"fas fa-play"})}function add_css(){var e=createElement("style");e.id="svelte-1yjle82-style",e.textContent=".ui-pnotify-closer.svelte-1yjle82,.ui-pnotify-sticker.svelte-1yjle82{float:right;margin-left:.5em;cursor:pointer}[dir=rtl] .ui-pnotify-closer.svelte-1yjle82,[dir=rtl] .ui-pnotify-sticker.svelte-1yjle82{float:left;margin-right:.5em;margin-left:0}.ui-pnotify-buttons-hidden.svelte-1yjle82{visibility:hidden}",append(document.head,e)}function create_main_fragment(e,t){var s,i,n=t._showCloser&&create_if_block_1(e,t),o=t._showSticker&&create_if_block(e,t);return{c(){n&&n.c(),s=createText("\n"),o&&o.c(),i=createComment()},m(e,t){n&&n.m(e,t),insert(e,s,t),o&&o.m(e,t),insert(e,i,t)},p(t,r){r._showCloser?n?n.p(t,r):((n=create_if_block_1(e,r)).c(),n.m(s.parentNode,s)):n&&(n.d(1),n=null),r._showSticker?o?o.p(t,r):((o=create_if_block(e,r)).c(),o.m(i.parentNode,i)):o&&(o.d(1),o=null)},d(e){n&&n.d(e),e&&detachNode(s),o&&o.d(e),e&&detachNode(i)}}}function create_if_block_1(e,t){var s,i,n,o;function r(t){e.handleCloserClick()}return{c(){s=createElement("div"),(i=createElement("span")).className=t._closerClass+" svelte-1yjle82",addListener(s,"click",r),s.className=n="ui-pnotify-closer "+(!t.closerHover||t._mouseIsIn?"":"ui-pnotify-buttons-hidden")+" svelte-1yjle82",setAttribute(s,"role","button"),s.tabIndex="0",s.title=o=t.labels.close},m(e,t){insert(e,s,t),append(s,i)},p(e,t){e._closerClass&&(i.className=t._closerClass+" svelte-1yjle82"),(e.closerHover||e._mouseIsIn)&&n!==(n="ui-pnotify-closer "+(!t.closerHover||t._mouseIsIn?"":"ui-pnotify-buttons-hidden")+" svelte-1yjle82")&&(s.className=n),e.labels&&o!==(o=t.labels.close)&&(s.title=o)},d(e){e&&detachNode(s),removeListener(s,"click",r)}}}function create_if_block(e,t){var s,i,n,o,r,c;function l(t){e.handleStickerClick()}return{c(){s=createElement("div"),(i=createElement("span")).className=n=(t._options.hide?t._pinUpClass:t._pinDownClass)+" svelte-1yjle82",addListener(s,"click",l),s.className=o="ui-pnotify-sticker "+(!t.stickerHover||t._mouseIsIn?"":"ui-pnotify-buttons-hidden")+" svelte-1yjle82",setAttribute(s,"role","button"),setAttribute(s,"aria-pressed",r=t._options.hide),s.tabIndex="0",s.title=c=t._options.hide?t.labels.stick:t.labels.unstick},m(e,t){insert(e,s,t),append(s,i)},p(e,t){(e._options||e._pinUpClass||e._pinDownClass)&&n!==(n=(t._options.hide?t._pinUpClass:t._pinDownClass)+" svelte-1yjle82")&&(i.className=n),(e.stickerHover||e._mouseIsIn)&&o!==(o="ui-pnotify-sticker "+(!t.stickerHover||t._mouseIsIn?"":"ui-pnotify-buttons-hidden")+" svelte-1yjle82")&&(s.className=o),e._options&&r!==(r=t._options.hide)&&setAttribute(s,"aria-pressed",r),(e._options||e.labels)&&c!==(c=t._options.hide?t.labels.stick:t.labels.unstick)&&(s.title=c)},d(e){e&&detachNode(s),removeListener(s,"click",l)}}}function PNotifyButtons(e){init(this,e),this._state=assign(data(),e.data),this._recompute({sticker:1,_notice:1,closer:1,classes:1},this._state),this._intro=!0,document.getElementById("svelte-1yjle82-style")||add_css(),this._fragment=create_main_fragment(this,this._state),this.root._oncreate.push(()=>{oncreate.call(this),this.fire("update",{changed:assignTrue({},this._state),current:this._state})}),e.target&&(this._fragment.c(),this._mount(e.target,e.anchor),flush(this))}function createElement(e){return document.createElement(e)}function append(e,t){e.appendChild(t)}function createText(e){return document.createTextNode(e)}function createComment(){return document.createComment("")}function insert(e,t,s){e.insertBefore(t,s)}function detachNode(e){e.parentNode.removeChild(e)}function addListener(e,t,s,i){e.addEventListener(t,s,i)}function setAttribute(e,t,s){null==s?e.removeAttribute(t):e.setAttribute(t,s)}function removeListener(e,t,s,i){e.removeEventListener(t,s,i)}function init(e,t){e._handlers=blankObject(),e._slots=blankObject(),e._bind=t._bind,e._staged={},e.options=t,e.root=t.root||e,e.store=t.store||e.root.store,t.root||(e._beforecreate=[],e._oncreate=[],e._aftercreate=[])}function assign(e,t){for(var s in t)e[s]=t[s];return e}function assignTrue(e,t){for(var s in t)e[s]=1;return e}function flush(e){e._lock=!0,callAll(e._beforecreate),callAll(e._oncreate),callAll(e._aftercreate),e._lock=!1}function destroy(e){this.destroy=noop,this.fire("destroy"),this.set=noop,this._fragment.d(!1!==e),this._fragment=null,this._state={}}function get(){return this._state}function fire(e,t){var s=e in this._handlers&&this._handlers[e].slice();if(s)for(var i=0;i{let i=t?t.get().modules:e.modules,o=i&&i.Callbacks?i.Callbacks:{};return o[s]?o[s]:()=>!0};function setup(t){t.key="Callbacks",t.getCallbacks=callbacks;let e=PNotify.alert,s=PNotify.notice,i=PNotify.info,o=PNotify.success,n=PNotify.error,a=(t,e)=>{callbacks(null,e,"beforeInit")(e);let s=t(e);return callbacks(s,null,"afterInit")(s),s};PNotify.alert=(t=>a(e,t)),PNotify.notice=(t=>a(s,t)),PNotify.info=(t=>a(i,t)),PNotify.success=(t=>a(o,t)),PNotify.error=(t=>a(n,t)),PNotify.modules.Callbacks=t}function create_main_fragment(t,e){return{c:noop,m:noop,p:noop,d:noop}}function PNotifyCallbacks(t){init(this,t),this._state=assign({},t.data),this._intro=!0,this._fragment=create_main_fragment(this,this._state),t.target&&(this._fragment.c(),this._mount(t.target,t.anchor))}function noop(){}function init(t,e){t._handlers=blankObject(),t._slots=blankObject(),t._bind=e._bind,t._staged={},t.options=e,t.root=e.root||t,t.store=e.store||t.root.store,e.root||(t._beforecreate=[],t._oncreate=[],t._aftercreate=[])}function assign(t,e){for(var s in e)t[s]=e[s];return t}function destroy(t){this.destroy=noop,this.fire("destroy"),this.set=noop,this._fragment.d(!1!==t),this._fragment=null,this._state={}}function get(){return this._state}function fire(t,e){var s=t in this._handlers&&this._handlers[t].slice();if(s)for(var i=0;i{const s=t?Object.assign({},o?PNotifyCompat.prototype.options[o]:{},e):Object.assign({},PNotifyCompat.prototype.options,e),l=e=>{let t,o=e;for(;-1!==(t=o.indexOf("_"));)o=o.slice(0,t)+o.slice(t+1,t+2).toUpperCase()+o.slice(t+2);return o};for(let e in s)if(s.hasOwnProperty(e)&&-1!==e.indexOf("_")){s[l(e)]=s[e],delete s[e]}return t||(s.hasOwnProperty("addclass")&&(s.addClass=s.addclass,delete s.addclass),s.hasOwnProperty("cornerclass")&&(s.cornerClass=s.cornerclass,delete s.cornerClass),s.hasOwnProperty("textEscape")&&(s.textTrusted=!s.textEscape,delete s.textEscape),s.hasOwnProperty("titleEscape")&&(s.titleTrusted=!s.titleEscape,delete s.titleEscape),s.hasOwnProperty("styling")&&("bootstrap3"===s.styling?s.icons="bootstrap3":"fontawesome"===s.styling&&(s.styling="bootstrap3",s.icons="fontawesome4")),s.hasOwnProperty("stack")&&s.stack.overlay_close&&(s.stack.overlayClose=s.stack.overlay_close),s.modules={},s.hasOwnProperty("animate")&&(s.modules.Animate=translateOptions(s.animate,!0,"animate"),delete s.animate),s.hasOwnProperty("buttons")&&(s.modules.Buttons=translateOptions(s.buttons,!0,"buttons"),delete s.buttons,s.modules.Buttons.classes&&(s.modules.Buttons.classes=translateOptions(s.modules.Buttons.classes,!0))),s.hasOwnProperty("confirm")&&(s.modules.Confirm=translateOptions(s.confirm,!0,"confirm"),s.modules.Confirm.promptDefault&&(s.modules.Confirm.promptValue=s.modules.Confirm.promptDefault,delete s.modules.Confirm.promptDefault),delete s.confirm),s.hasOwnProperty("desktop")&&(s.modules.Desktop=translateOptions(s.desktop,!0,"desktop"),delete s.desktop),s.hasOwnProperty("history")&&(s.modules.History=translateOptions(s.history,!0,"history"),delete s.history),s.hasOwnProperty("mobile")&&(s.modules.Mobile=translateOptions(s.mobile,!0,"mobile"),delete s.mobile),s.hasOwnProperty("nonblock")&&(s.modules.NonBlock=translateOptions(s.nonblock,!0,"nonblock"),delete s.nonblock),s.hasOwnProperty("reference")&&(s.modules.Reference=translateOptions(s.reference,!0,"reference"),delete s.reference),s.hasOwnProperty("beforeInit")&&(s.modules.Callbacks||(s.modules.Callbacks={}),s.modules.Callbacks.beforeInit=s.beforeInit,delete s.beforeInit),s.hasOwnProperty("afterInit")&&(s.modules.Callbacks||(s.modules.Callbacks={}),s.modules.Callbacks.afterInit=s.afterInit,delete s.afterInit),s.hasOwnProperty("beforeOpen")&&(s.modules.Callbacks||(s.modules.Callbacks={}),s.modules.Callbacks.beforeOpen=s.beforeOpen,delete s.beforeOpen),s.hasOwnProperty("afterOpen")&&(s.modules.Callbacks||(s.modules.Callbacks={}),s.modules.Callbacks.afterOpen=s.afterOpen,delete s.afterOpen),s.hasOwnProperty("beforeClose")&&(s.modules.Callbacks||(s.modules.Callbacks={}),s.modules.Callbacks.beforeClose=s.beforeClose,delete s.beforeClose),s.hasOwnProperty("afterClose")&&(s.modules.Callbacks||(s.modules.Callbacks={}),s.modules.Callbacks.afterClose=s.afterClose,delete s.afterClose)),s};class PNotifyCompat extends PNotify{constructor(e){"object"!=typeof e&&(e={text:e}),PNotify.modules.Callbacks&&e.before_init&&e.before_init(e),e=translateOptions(e),super({target:document.body,data:e});const t=this.get;this.get=function(e){return void 0===e?Object.assign(window.jQuery?window.jQuery(this.refs.elem):this.refs.elem,t.call(this)):t.call(this,e)},this.on("pnotify.confirm",e=>{window.jQuery&&window.jQuery(this.refs.elem).trigger("pnotify.confirm",[this,e.value])}),this.on("pnotify.cancel",e=>{window.jQuery&&window.jQuery(this.refs.elem).trigger("pnotify.cancel",this)}),PNotify.modules.Callbacks&&PNotify.modules.Callbacks.getCallbacks(this,null,"afterInit")(this)}update(e){return e=translateOptions(e),super.update(e)}}PNotifyCompat.prototype.options={text_escape:!1,title_escape:!1},PNotifyCompat.reload=(()=>PNotifyCompat),PNotifyCompat.removeAll=(()=>PNotify.removeAll()),PNotifyCompat.removeStack=(e=>PNotify.removeStack(e)),PNotifyCompat.positionAll=(e=>PNotify.positionAll(e)),PNotifyCompat.desktop={permission:()=>{PNotify.modules.Desktop.permission()}},window.jQuery&&window.jQuery(()=>{window.jQuery(document.body).on("pnotify.history-last",function(){PNotify.modules.History.showLast()})});export default PNotifyCompat;
-//# sourceMappingURL=PNotifyCompat.js.map
\ No newline at end of file
diff --git a/node_modules/pnotify/dist/es/PNotifyCompat.js.map b/node_modules/pnotify/dist/es/PNotifyCompat.js.map
deleted file mode 100644
index 222ee73..0000000
--- a/node_modules/pnotify/dist/es/PNotifyCompat.js.map
+++ /dev/null
@@ -1 +0,0 @@
-{"version":3,"sources":["PNotifyCompat.js"],"names":["PNotify","translateOptions","options","module","moduleName","newOptions","Object","assign","PNotifyCompat","prototype","translateName","badName","underscoreIndex","goodName","indexOf","slice","toUpperCase","name","hasOwnProperty","addClass","addclass","cornerClass","cornerclass","textTrusted","textEscape","titleTrusted","titleEscape","styling","icons","stack","overlay_close","overlayClose","modules","Animate","animate","Buttons","buttons","classes","Confirm","confirm","promptDefault","promptValue","Desktop","desktop","History","history","Mobile","mobile","NonBlock","nonblock","Reference","reference","Callbacks","beforeInit","afterInit","beforeOpen","afterOpen","beforeClose","afterClose","[object Object]","text","before_init","super","target","document","body","data","_get","this","get","option","undefined","window","jQuery","refs","elem","call","on","e","trigger","value","getCallbacks","update","text_escape","title_escape","reload","removeAll","removeStack","positionAll","permission","showLast"],"mappings":"OAAOA,YAAa,eAGpB,MAAMC,iBAAmB,CAACC,EAASC,EAAQC,KAEzC,MAAMC,EAAaF,EAASG,OAAOC,UAAWH,EAAaI,cAAcC,UAAUP,QAAQE,MAAkBF,GAAWI,OAAOC,U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AOhF,IAKxBM,cAAcC,UAAUP,SACtBiF,aAAa,EACbC,cAAc,GAIhB5E,cAAc6E,OAAS,KAAM7E,eAC7BA,cAAc8E,UAAY,KAAMtF,QAAQsF,aACxC9E,cAAc+E,YAAc,CAAC1D,GAAU7B,QAAQuF,YAAY1D,IAC3DrB,cAAcgF,YAAc,CAACtD,GAAYlC,QAAQwF,YAAYtD,IAG7D1B,cAAcmC,SACZ8C,WAAY,KACVzF,QAAQgC,QAAQU,QAAQ+C,eAKxBjB,OAAOC,QACTD,OAAOC,OAAO,KACZD,OAAOC,OAAOT,SAASC,MAAMY,GAAG,uBAAwB,WACtD7E,QAAQgC,QAAQY,QAAQ8C,8BAKflF","file":"PNotifyCompat.js","sourceRoot":"../"}
\ No newline at end of file
diff --git a/node_modules/pnotify/dist/es/PNotifyConfirm.js b/node_modules/pnotify/dist/es/PNotifyConfirm.js
deleted file mode 100644
index 70616fd..0000000
--- a/node_modules/pnotify/dist/es/PNotifyConfirm.js
+++ /dev/null
@@ -1,2 +0,0 @@
-import PNotify from"./PNotify.js";function data(){return Object.assign({_notice:null,_options:{}},PNotify.modules.Confirm.defaults)}var methods={initModule(t){this.set(t)},afterOpen(){if(this.get().prompt&&!1!==this.get().focus)this.get().promptMultiLine?this.refs.promptMulti.focus():this.refs.promptSingle.focus();else if(this.get().confirm&&(!0===this.get().focus||null===this.get().focus&&this.get()._options.stack.modal)){const t=this.get().buttons;if(t.length){let e=t.length-1;for(;e>=0&&!t[e].promptTrigger;)e--;this.refs.buttons.children[e].focus()}}},handleClick(t,e){t.click&&t.click(this.get()._notice,this.get().prompt?this.get().promptValue:null,e)},handleKeyPress(t){if(13===t.keyCode&&!t.shiftKey){t.preventDefault();const{buttons:e}=this.get();for(let n=0;n{t.close(),t.fire("pnotify.confirm",{notice:t,value:e})}},{text:"Cancel",textTrusted:!1,addClass:"",click:t=>{t.close(),t.fire("pnotify.cancel",{notice:t})}}]},PNotify.modules.Confirm=t,PNotify.modulesAppendContainer.push(t),Object.assign(PNotify.styling.brighttheme,{actionBar:"",promptBar:"",btn:"",btnPrimary:"brighttheme-primary",input:""}),Object.assign(PNotify.styling.bootstrap3,{actionBar:"ui-pnotify-confirm-ml",promptBar:"ui-pnotify-confirm-ml",btn:"btn btn-default ui-pnotify-confirm-mx-1",btnPrimary:"btn btn-default ui-pnotify-confirm-mx-1 btn-primary",input:"form-control"}),Object.assign(PNotify.styling.bootstrap4,{actionBar:"ui-pnotify-confirm-ml",promptBar:"ui-pnotify-confirm-ml",btn:"btn btn-secondary mx-1",btnPrimary:"btn btn-primary mx-1",input:"form-control"}),PNotify.styling.material||(PNotify.styling.material={}),Object.assign(PNotify.styling.material,{actionBar:"",promptBar:"",btn:"",btnPrimary:"ui-pnotify-material-primary",input:""})}function add_css(){var t=createElement("style");t.id="svelte-1y9suua-style",t.textContent=".ui-pnotify-action-bar.svelte-1y9suua,.ui-pnotify-prompt-bar.svelte-1y9suua{margin-top:5px;clear:both}.ui-pnotify-action-bar.svelte-1y9suua{display:flex;flex-wrap:wrap;justify-content:flex-end}.ui-pnotify-prompt-input.svelte-1y9suua{margin-bottom:5px;display:block;width:100%}.ui-pnotify-confirm-mx-1.svelte-1y9suua{margin:0 5px}.ui-pnotify.ui-pnotify-with-icon .ui-pnotify-confirm-ml.svelte-1y9suua{margin-left:24px}[dir=rtl] .ui-pnotify.ui-pnotify-with-icon .ui-pnotify-confirm-ml.svelte-1y9suua{margin-right:24px;margin-left:0}",append(document.head,t)}function click_handler(t){const{component:e,ctx:n}=this._svelte;e.handleClick(n.button,t)}function get_each_context(t,e,n){const i=Object.create(t);return i.button=e[n],i}function create_main_fragment(t,e){var n,i=(e.confirm||e.prompt)&&create_if_block(t,e);return{c(){i&&i.c(),n=createComment()},m(t,e){i&&i.m(t,e),insert(t,n,e)},p(e,o){o.confirm||o.prompt?i?i.p(e,o):((i=create_if_block(t,o)).c(),i.m(n.parentNode,n)):i&&(i.d(1),i=null)},d(t){i&&i.d(t),t&&detachNode(n)}}}function create_if_block(t,e){for(var n,i,o,s,r=e.prompt&&create_if_block_2(t,e),a=e.buttons,c=[],l=0;l{oncreate.call(this),this.fire("update",{changed:assignTrue({},this._state),current:this._state})}),t.target&&(this._fragment.c(),this._mount(t.target,t.anchor),flush(this))}function createElement(t){return document.createElement(t)}function append(t,e){t.appendChild(e)}function createComment(){return document.createComment("")}function insert(t,e,n){t.insertBefore(e,n)}function detachNode(t){t.parentNode.removeChild(t)}function createText(t){return document.createTextNode(t)}function setStyle(t,e,n){t.style.setProperty(e,n)}function destroyEach(t,e){for(var n=0;n(notify="Notification"in window?(t,i,e,n)=>{const o=new Notification(t,i);return"NotificationEvent"in window?(o.addEventListener("notificationclick",e),o.addEventListener("close",n)):"addEventListener"in o?(o.addEventListener("click",e),o.addEventListener("close",n)):(o.onclick=e,o.onclose=n),o}:"mozNotification"in navigator?(t,i,e,n)=>{const o=navigator.mozNotification.createNotification(t,i.body,i.icon).show();return o.onclick=e,o.onclose=n,o}:"webkitNotifications"in window?(t,i,e,n)=>{const o=window.webkitNotifications.createNotification(i.icon,t,i.body);return o.onclick=e,o.onclose=n,o}:(t,i,e,n)=>null)(t,i,e,n);function data(){return Object.assign({_notice:null,_options:{}},PNotify.modules.Desktop.defaults)}var methods={initModule(t){this.set(t);const{_notice:i}=this.get();this.set({_oldAnimation:i.get().animation}),i.on("state",({changed:t,current:e,previous:n})=>{t.animation&&(void 0===n.animation||"none"!==e.animation||"none"===n.animation&&e.animation!==this.get()._oldAnimation)&&this.set({_oldAnimation:e.animation}),t._animatingClass&&(""===e._animatingClass||0!==permission&&this.get().fallback||!this.get().desktop||i.set({_animatingClass:""}))}),this.get().desktop&&(0===(permission=PNotify.modules.Desktop.checkPermission())?(i.set({animation:"none"}),i.addModuleClass("ui-pnotify-desktop-hide"),this.genNotice()):this.get().fallback||i.set({autoDisplay:!1}))},update(){const{_notice:t}=this.get();if(0!==permission&&this.get().fallback||!this.get().desktop)return t.set({animation:this.get()._oldAnimation}),void t.removeModuleClass("ui-pnotify-desktop-hide");t.set({animation:"none"}),t.addModuleClass("ui-pnotify-desktop-hide"),this.genNotice()},beforeOpen(){if(this.get().desktop&&0!==permission&&PNotify.modules.Desktop.permission(),0!==permission&&this.get().fallback||!this.get().desktop)return;const{_desktop:t}=this.get();t&&"show"in t&&(this.get()._notice.set({_moduleIsNoticeOpen:!0}),t.show())},beforeClose(){if(0!==permission&&this.get().fallback||!this.get().desktop)return;const{_desktop:t}=this.get();t&&"close"in t&&(t.close(),this.get()._notice.set({_moduleIsNoticeOpen:!1}))},genNotice(){const{_notice:t,icon:i}=this.get();if(null===i)switch(t.get().type){case"error":this.set({_icon:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3gQJATQg7e6HvQAAAB1pVFh0Q29tbWVudAAAAAAAQ3JlYXRlZCB3aXRoIEdJTVBkLmUHAAABr0lEQVRYw8WXu0oDQRSGv7hRSFYrLTTWKihaqUgUJO+gphBLL1jYpPSCVcAggpWthYhC7Ows9An0IbSPkMRCw8ZmFuI6yczs9cAPuzNz5v92brtrESxGARtokkCcAg2hk7jNl4G2R/m4zFPAiwTgWdRFHnmJuaulOAAaPQDqUZvv9DB3tR0lwIcGwHtU5uca5q4qYZvngJbHpAZ8CtU8dS1gLEyAisegBGTFKWiL65KnzVlY5uOSId6VtNuTtMupOu/TAHiQlNmSskHNXCOAGWBeUp7VhFoApoMAXAOWJoCszBJ9+ALY6vL0JiPgjsKmKUAaOOoBZwIAcNxlJLsCrAOTIQJMAWu62y4LOIqT7lGS96TIcYCMDkBZ46h1gB+PHI28ssq8X/G6DaqG8Piz2DrjVjGXbtSBy46F5QAHwJAizwZugKKscs7gSaqS/KpB/qxsFxwafhf6Odb/eblJi8BGwJdW26BtURxQpMU83hmaDQsNiPtvYMSwj3tgAqDgYzU7wJdHjo9+CgBvEW47lV5Tgj5DMtG0xIfESkIAF+522gdWxTzGEX3i9+6KpOMXF5UBt0NKJCAAAAAASUVORK5CYII="});break;case"success":this.set({_icon:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3gQJATQPRj+65AAAAdBJREFUWMPtlzsvRFEQx3+7HmEjoiYKolVJJDRqnS8ggvVIVEQhCIUsEYJGCEH2E4h4FPREaLTbEo1IEJXHrmY2GTf33nPuY7ud5OTenTMz//89Z86ZWShLWf5LB3AOfACFiOMF2AkC3qOc88BXxFEAxlX8ftGdaNCEen8H6oFHYBR4FocwkpTngzzHgF01fwL0aYcp9fVtMW/rsMcWXWijK1Hexgye9smRT6CxaHgjytMYwccNSXqoja9FeVbiZS+OVaeDiUBLAPAJA/i2m5MXgRSQk7llC/DBMOBeBGqAe0eAjQhfvurH3EmgQk6EW6CVEHt+ZFo6J4EU8OoTcF35jhnAl2wSx20LFgyB1yyOWtY2c72ScMAAkPeZy6g4zUBdGAIAcyEq4Z7y7xbdTFgCACMBwPVJqVDHeNqvaplkH5i0sNuUwmaNkQxww20ZSOy7gFvX7SAk0i76jPQQlJoAwAEwq35ngfmwVatSdUMArZZ+K9JQ1Bp6iGqgSt7f/AIOqSzujLEn6AV+JG6zm4HuCZ+AJuAbWAQu5aIJu7JDck0ngDugC/j1c2qPqR13jpxuvWyS8liY/kQcean/lX6ACQ99DdAQYe+Lf0zylMUgf7qDKgzv284QAAAAAElFTkSuQmCC"});break;case"info":this.set({_icon:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3gQJATQ09zRTwAAAAdxJREFUWMPtl88rRFEUxz8zBolRCgsrpOym8TMSO2WplLKwUrKi/B0W7JSFmhVLNlhSlLKx8CtRG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0MhALQCAE9MoIdGkQCJIBgE4ZgWiNMvDL10qgUMMMFGQEnjQmkLXbVg38s8y4qtFcTCAnHiJ5oKiJnSoHjVgIXAmHkGIl5yy+YcWruIy9dvqpupIDCfZWEXvh1gsWFVfxIbG9a3RbRwJnYiuqJYfAqxsBgBWFiQyJzfTAlIB1uzEicbwBFoBTl8lSwINoSuXKjrv4F4FBh61zlKUKvgn7/e5ZEngMEDgLdFSieHaAT42LpgTMVbqC24B54Bi4twV9E6cnDcw6PFj+RSo/l6rlSlldhx4AAAAASUVORK5CYII="})}else!1===i?this.set({_icon:null}):this.set({_icon:i});let{tag:e}=this.get();this.get()._tag&&null===e||this.set({_tag:null===e?"PNotify-"+Math.round(1e6*Math.random()):e});const n={body:this.get().text||t.get().text,tag:this.get()._tag};t.get().hide||(n.requireInteraction=!0),null!==this.get()._icon&&(n.icon=this.get()._icon),Object.apply(n,this.get().options);const o=notify(this.get().title||t.get().title,n,()=>{t.fire("click",{target:o})},()=>{t.close()});t.set({_moduleIsNoticeOpen:!0}),this.set({_desktop:o}),!("close"in o)&&"cancel"in o&&(o.close=(()=>{o.cancel()}))}};function setup(t){t.key="Desktop",t.defaults={desktop:!1,fallback:!0,icon:null,tag:null,title:null,text:null,options:{}},t.init=(i=>new t({target:document.body})),t.permission=(()=>{void 0!==Notification&&"requestPermission"in Notification?Notification.requestPermission():"webkitNotifications"in window&&window.webkitNotifications.requestPermission()}),t.checkPermission=(()=>void 0!==Notification&&"permission"in Notification?"granted"===Notification.permission?0:1:"webkitNotifications"in window&&0==window.webkitNotifications.checkPermission()?0:1),permission=t.checkPermission(),PNotify.modules.Desktop=t}function add_css(){var t=createElement("style");t.id="svelte-xbgnx4-style",t.textContent="[ui-pnotify].ui-pnotify-desktop-hide.ui-pnotify{left:-10000px !important;display:none !important}",append(document.head,t)}function create_main_fragment(t,i){return{c:noop,m:noop,p:noop,d:noop}}function PNotifyDesktop(t){init(this,t),this._state=assign(data(),t.data),this._intro=!0,document.getElementById("svelte-xbgnx4-style")||add_css(),this._fragment=create_main_fragment(this,this._state),t.target&&(this._fragment.c(),this._mount(t.target,t.anchor))}function createElement(t){return document.createElement(t)}function append(t,i){t.appendChild(i)}function noop(){}function init(t,i){t._handlers=blankObject(),t._slots=blankObject(),t._bind=i._bind,t._staged={},t.options=i,t.root=i.root||t,t.store=i.store||t.root.store,i.root||(t._beforecreate=[],t._oncreate=[],t._aftercreate=[])}function assign(t,i){for(var e in i)t[e]=i[e];return t}function destroy(t){this.destroy=noop,this.fire("destroy"),this.set=noop,this._fragment.d(!1!==t),this._fragment=null,this._state={}}function get(){return this._state}function fire(t,i){var e=t in this._handlers&&this._handlers[t].slice();if(e)for(var n=0;nt){const e="top"===i.push,o=[];let s=0;for(let n=e?0:PNotify.notices.length-1;e?n=0;e?n++:n--)-1!==["opening","open"].indexOf(PNotify.notices[n].get()._state)&&PNotify.notices[n].get().stack===i&&(s>=t?o.push(PNotify.notices[n]):s++);for(let t=0;tnew t({target:document.body})),t.showLast=(t=>{if(void 0===t&&(t=PNotify.defaultStack),!1===t)return;const e="top"===t.push;let i,o=e?0:PNotify.notices.length-1;do{if(!(i=PNotify.notices[o]))return;o+=e?1:-1}while(i.get().stack!==t||!i.get()._modules.History.get().history||"opening"===i.get()._state||"open"===i.get()._state);i.open()}),t.showAll=(t=>{if(void 0===t&&(t=PNotify.defaultStack),!1!==t)for(let e=0;e{if(!this.get().swipeDismiss)return;const{stack:o}=t.get();if(!1!==o)switch(o.dir1){case"up":case"down":r="left",l="X",a="Width";break;case"left":case"right":r="top",l="Y",a="Height"}e=i.touches[0]["screen"+l],n=t.refs.elem["scroll"+a],s=window.getComputedStyle(t.refs.elem).opacity,t.refs.container.style[r]=0}),t.on("touchmove",i=>{if(!e||!this.get().swipeDismiss)return;const a=i.touches[0]["screen"+l];o=a-e;const f=(1-Math.abs(o)/n)*s;t.refs.elem.style.opacity=f,t.refs.container.style[r]=o+"px"}),t.on("touchend",()=>{if(e&&this.get().swipeDismiss){if(t.refs.container.classList.add("ui-pnotify-mobile-animate-left"),Math.abs(o)>40){const i=o<0?-2*n:2*n;t.refs.elem.style.opacity=0,t.refs.container.style[r]=i+"px",t.close()}else t.refs.elem.style.removeProperty("opacity"),t.refs.container.style.removeProperty(r);e=null,o=null,n=null,s=null}}),t.on("touchcancel",()=>{e&&this.get().swipeDismiss&&(t.refs.elem.style.removeProperty("opacity"),t.refs.container.style.removeProperty(r),e=null,o=null,n=null,s=null)}),this.doMobileStyling()},update(){this.doMobileStyling()},beforeOpen(){window.addEventListener("resize",this.get()._doMobileStylingBound)},afterClose(){if(window.removeEventListener("resize",this.get()._doMobileStylingBound),!this.get().swipeDismiss)return;const{_notice:i}=this.get();i.refs.elem.style.removeProperty("opacity"),i.refs.container.style.removeProperty("left"),i.refs.container.style.removeProperty("top")},doMobileStyling(){const{_notice:i}=this.get(),{stack:t}=i.get();if(this.get().styling){if(!1!==t)switch(window.innerWidth<=480?(t.mobileOrigSpacing1||(t.mobileOrigSpacing1=t.spacing1),t.spacing1=0,t.mobileOrigFirstpos1||(t.mobileOrigFirstpos1=t.firstpos1),t.firstpos1=0,t.mobileOrigSpacing2||(t.mobileOrigSpacing2=t.spacing2),t.spacing2=0,t.mobileOrigFirstpos2||(t.mobileOrigFirstpos2=t.firstpos2),t.firstpos2=0):(t.mobileOrigSpacing1&&(t.spacing1=t.mobileOrigSpacing1,delete t.mobileOrigSpacing1),t.mobileOrigFirstpos1&&(t.firstpos1=t.mobileOrigFirstpos1,delete t.mobileOrigFirstpos1),t.mobileOrigSpacing2&&(t.spacing2=t.mobileOrigSpacing2,delete t.mobileOrigSpacing2),t.mobileOrigFirstpos2&&(t.firstpos2=t.mobileOrigFirstpos2,delete t.mobileOrigFirstpos2)),t.dir1){case"down":i.addModuleClass("ui-pnotify-mobile-top");break;case"up":i.addModuleClass("ui-pnotify-mobile-bottom");break;case"left":i.addModuleClass("ui-pnotify-mobile-right");break;case"right":i.addModuleClass("ui-pnotify-mobile-left")}i.addModuleClass("ui-pnotify-mobile-able")}else i.removeModuleClass("ui-pnotify-mobile-able","ui-pnotify-mobile-top","ui-pnotify-mobile-bottom","ui-pnotify-mobile-right","ui-pnotify-mobile-left"),!1!==t&&(t.mobileOrigSpacing1&&(t.spacing1=t.mobileOrigSpacing1,delete t.mobileOrigSpacing1),t.mobileOrigFirstpos1&&(t.firstpos1=t.mobileOrigFirstpos1,delete t.mobileOrigFirstpos1),t.mobileOrigSpacing2&&(t.spacing2=t.mobileOrigSpacing2,delete t.mobileOrigSpacing2),t.mobileOrigFirstpos2&&(t.firstpos2=t.mobileOrigFirstpos2,delete t.mobileOrigFirstpos2))}};function oncreate(){this.set({_doMobileStylingBound:this.doMobileStyling.bind(this)})}function setup(i){i.key="Mobile",i.defaults={swipeDismiss:!0,styling:!0},i.init=(t=>new i({target:document.body})),PNotify.modules.Mobile=i}function add_css(){var i=createElement("style");i.id="svelte-49u8sj-style",i.textContent="[ui-pnotify] .ui-pnotify-container{position:relative}[ui-pnotify] .ui-pnotify-mobile-animate-left{transition:left .1s ease}[ui-pnotify] .ui-pnotify-mobile-animate-top{transition:top .1s ease}@media(max-width: 480px){[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able{font-size:1.2em;-webkit-font-smoothing:antialiased;-moz-font-smoothing:antialiased;-ms-font-smoothing:antialiased;font-smoothing:antialiased}body > [ui-pnotify].ui-pnotify.ui-pnotify-mobile-able{position:fixed}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-top,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-bottom{width:100% !important}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-left,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-right{height:100% !important}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able .ui-pnotify-shadow{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-top .ui-pnotify-shadow{border-bottom-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-bottom .ui-pnotify-shadow{border-top-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-left .ui-pnotify-shadow{border-right-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-right .ui-pnotify-shadow{border-left-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able .ui-pnotify-container{-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-top .ui-pnotify-container,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-bottom .ui-pnotify-container{width:auto !important}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-left .ui-pnotify-container,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-right .ui-pnotify-container{height:100% !important}}",append(document.head,i)}function create_main_fragment(i,t){return{c:noop,m:noop,p:noop,d:noop}}function PNotifyMobile(i){init(this,i),this._state=assign(data(),i.data),this._intro=!0,document.getElementById("svelte-49u8sj-style")||add_css(),this._fragment=create_main_fragment(this,this._state),this.root._oncreate.push(()=>{oncreate.call(this),this.fire("update",{changed:assignTrue({},this._state),current:this._state})}),i.target&&(this._fragment.c(),this._mount(i.target,i.anchor),flush(this))}function createElement(i){return document.createElement(i)}function append(i,t){i.appendChild(t)}function noop(){}function init(i,t){i._handlers=blankObject(),i._slots=blankObject(),i._bind=t._bind,i._staged={},i.options=t,i.root=t.root||i,i.store=t.store||i.root.store,t.root||(i._beforecreate=[],i._oncreate=[],i._aftercreate=[])}function assign(i,t){for(var e in t)i[e]=t[e];return i}function assignTrue(i,t){for(var e in t)i[e]=1;return i}function flush(i){i._lock=!0,callAll(i._beforecreate),callAll(i._oncreate),callAll(i._aftercreate),i._lock=!1}function destroy(i){this.destroy=noop,this.fire("destroy"),this.set=noop,this._fragment.d(!1!==i),this._fragment=null,this._state={}}function get(){return this._state}function fire(i,t){var e=i in this._handlers&&this._handlers[i].slice();if(e)for(var o=0;onew t({target:document.body,data:{_notice:o}})),PNotify.modules.NonBlock=t}function create_main_fragment(t,o){return{c:noop,m:noop,p:noop,d:noop}}function PNotifyNonBlock(t){init(this,t),this._state=assign(data(),t.data),this._intro=!0,this._fragment=create_main_fragment(this,this._state),t.target&&(this._fragment.c(),this._mount(t.target,t.anchor))}function noop(){}function init(t,o){t._handlers=blankObject(),t._slots=blankObject(),t._bind=o._bind,t._staged={},t.options=o,t.root=o.root||t,t.store=o.store||t.root.store,o.root||(t._beforecreate=[],t._oncreate=[],t._aftercreate=[])}function assign(t,o){for(var n in o)t[n]=o[n];return t}function destroy(t){this.destroy=noop,this.fire("destroy"),this.set=noop,this._fragment.d(!1!==t),this._fragment=null,this._state={}}function get(){return this._state}function fire(t,o){var n=t in this._handlers&&this._handlers[t].slice();if(n)for(var e=0;ethis.set({_mouseIsIn:!0})),t.on("mouseleave",()=>this.set({_mouseIsIn:!1}))},doSomething(){let e=0;const{_notice:t}=this.get(),n=setInterval(()=>{360===(e+=10)&&(e=0,clearInterval(n)),t.refs.elem.style.transform="rotate("+e+"deg)"},20)},update(){},beforeOpen(){},afterOpen(){},beforeClose(){},afterClose(){},beforeDestroy(){},afterDestroy(){}};function oncreate(){this.fire("init",{module:this})}function setup(e){e.key="Reference",e.defaults={putThing:!1,labels:{text:"Spin Around"}},PNotify.modules.Reference=e,PNotify.modulesAppendContainer.push(e),Object.assign(PNotify.icons.brighttheme,{athing:"bt-icon bt-icon-refresh"}),Object.assign(PNotify.icons.bootstrap3,{athing:"glyphicon glyphicon-refresh"}),Object.assign(PNotify.icons.fontawesome4,{athing:"fa fa-refresh"}),Object.assign(PNotify.icons.fontawesome5,{athing:"fas fa-sync"}),PNotify.icons.material||(PNotify.icons.material={}),Object.assign(PNotify.icons.material,{athing:"material-icons pnotify-material-icon-refresh"})}function add_css(){var e=createElement("style");e.id="svelte-1qy4b0e-style",e.textContent=".ui-pnotify-reference-button.svelte-1qy4b0e{float:right}.ui-pnotify-reference-clearing.svelte-1qy4b0e{clear:right;line-height:0}",append(document.head,e)}function create_main_fragment(e,t){var n,i=t.putThing&&create_if_block(e,t);return{c(){i&&i.c(),n=createComment()},m(e,t){i&&i.m(e,t),insert(e,n,t)},p(t,s){s.putThing?i?i.p(t,s):((i=create_if_block(e,s)).c(),i.m(n.parentNode,n)):i&&(i.d(1),i=null)},d(e){i&&i.d(e),e&&detachNode(n)}}}function create_if_block(e,t){var n,i,s,o,r,a,c,f,l=t.labels.text;function h(t){e.doSomething()}return{c(){n=createElement("button"),i=createElement("i"),o=createText(" "),r=createText(l),c=createText("\n \n "),f=createElement("div"),i.className=s=t._notice.get()._icons.athing+" svelte-1qy4b0e",addListener(n,"click",h),n.className="ui-pnotify-reference-button btn btn-default svelte-1qy4b0e",n.type="button",n.disabled=a=!t._mouseIsIn,f.className="ui-pnotify-reference-clearing svelte-1qy4b0e"},m(t,s){insert(t,n,s),append(n,i),append(n,o),append(n,r),e.refs.thingElem=n,insert(t,c,s),insert(t,f,s)},p(e,t){e._notice&&s!==(s=t._notice.get()._icons.athing+" svelte-1qy4b0e")&&(i.className=s),e.labels&&l!==(l=t.labels.text)&&setData(r,l),e._mouseIsIn&&a!==(a=!t._mouseIsIn)&&(n.disabled=a)},d(t){t&&detachNode(n),removeListener(n,"click",h),e.refs.thingElem===n&&(e.refs.thingElem=null),t&&(detachNode(c),detachNode(f))}}}function PNotifyReference(e){init(this,e),this.refs={},this._state=assign(data(),e.data),this._intro=!0,document.getElementById("svelte-1qy4b0e-style")||add_css(),this._fragment=create_main_fragment(this,this._state),this.root._oncreate.push(()=>{oncreate.call(this),this.fire("update",{changed:assignTrue({},this._state),current:this._state})}),e.target&&(this._fragment.c(),this._mount(e.target,e.anchor),flush(this))}function createElement(e){return document.createElement(e)}function append(e,t){e.appendChild(t)}function createComment(){return document.createComment("")}function insert(e,t,n){e.insertBefore(t,n)}function detachNode(e){e.parentNode.removeChild(e)}function createText(e){return document.createTextNode(e)}function addListener(e,t,n,i){e.addEventListener(t,n,i)}function setData(e,t){e.data=""+t}function removeListener(e,t,n,i){e.removeEventListener(t,n,i)}function init(e,t){e._handlers=blankObject(),e._slots=blankObject(),e._bind=t._bind,e._staged={},e.options=t,e.root=t.root||e,e.store=t.store||e.root.store,t.root||(e._beforecreate=[],e._oncreate=[],e._aftercreate=[])}function assign(e,t){for(var n in t)e[n]=t[n];return e}function assignTrue(e,t){for(var n in t)e[n]=1;return e}function flush(e){e._lock=!0,callAll(e._beforecreate),callAll(e._oncreate),callAll(e._aftercreate),e._lock=!1}function destroy(e){this.destroy=noop,this.fire("destroy"),this.set=noop,this._fragment.d(!1!==e),this._fragment=null,this._state={}}function get(){return this._state}function fire(e,t){var n=e in this._handlers&&this._handlers[e].slice();if(n)for(var i=0;it.addpos2&&(t.addpos2=e.offsetHeight);break;case"left":case"right":e.offsetWidth+(parseFloat(e.style.marginLeft,10)||0)+(parseFloat(e.style.marginRight,10)||0)>t.addpos2&&(t.addpos2=e.offsetWidth)}}else if(t.dir1){var p=void 0,m=void 0;switch(t.dir1){case"down":case"up":m=["left","right"],p=t.context.scrollWidth/2-e.offsetWidth/2;break;case"left":case"right":m=["top","bottom"],p=s/2-e.offsetHeight/2}e.style[m[0]]=p+"px",e.style[m[1]]="auto",t.animation||e.style[m[0]]}if(t.dir1)switch("number"==typeof t.nextpos1&&(e.style[a]=t.nextpos1+"px",t.animation||e.style[a]),t.dir1){case"down":case"up":t.nextpos1+=e.offsetHeight+(void 0===t.spacing1?25:t.spacing1);break;case"left":case"right":t.nextpos1+=e.offsetWidth+(void 0===t.spacing1?25:t.spacing1)}else{var h=r/2-e.offsetWidth/2,y=s/2-e.offsetHeight/2;e.style.left=h+"px",e.style.top=y+"px",t.animation||e.style.left}return this}},queuePosition:function(t){return n&&clearTimeout(n),t=t||10,n=setTimeout(function(){g.positionAll()},t),this},cancelRemove:function(){return this.cancelClose()},cancelClose:function(){var t=this.get(),e=t._timer,i=t._animTimer,n=t._state,o=t.animation;return e&&clearTimeout(e),i&&clearTimeout(i),"closing"===n&&this.set({_state:"open",_animating:!1,_animatingClass:"fade"===o?"ui-pnotify-in ui-pnotify-fade-in":"ui-pnotify-in"}),this},queueRemove:function(){return this.queueClose()},queueClose:function(){var t=this;return this.cancelClose(),this.set({_timer:setTimeout(function(){return t.close(!0)},isNaN(this.get().delay)?0:this.get().delay)}),this},addModuleClass:function(){for(var t=this.get()._moduleClasses,e=arguments.length,i=Array(e),n=0;n .ui-pnotify{position:fixed;z-index:100040}body > .ui-pnotify.ui-pnotify-modal{z-index:100042}.ui-pnotify{position:absolute;height:auto;z-index:1;display:none}.ui-pnotify.ui-pnotify-modal{z-index:3}.ui-pnotify.ui-pnotify-in{display:block}.ui-pnotify.ui-pnotify-initial-hidden{display:block;visibility:hidden}.ui-pnotify.ui-pnotify-move{transition:left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-slow{transition:opacity .4s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-slow.ui-pnotify.ui-pnotify-move{transition:opacity .4s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-normal{transition:opacity .25s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-normal.ui-pnotify.ui-pnotify-move{transition:opacity .25s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-fast{transition:opacity .1s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-fast.ui-pnotify.ui-pnotify-move{transition:opacity .1s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-in{opacity:1}.ui-pnotify .ui-pnotify-shadow{-webkit-box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1);-moz-box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1);box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1)}.ui-pnotify-container{background-position:0 0;padding:.8em;height:100%;margin:0}.ui-pnotify-container:after{content:" ";visibility:hidden;display:block;height:0;clear:both}.ui-pnotify-container.ui-pnotify-sharp{-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.ui-pnotify-title{display:block;white-space:pre-line;margin-bottom:.4em;margin-top:0}.ui-pnotify.ui-pnotify-with-icon .ui-pnotify-title,.ui-pnotify.ui-pnotify-with-icon .ui-pnotify-text{margin-left:24px}[dir=rtl] .ui-pnotify.ui-pnotify-with-icon .ui-pnotify-title,[dir=rtl] .ui-pnotify.ui-pnotify-with-icon .ui-pnotify-text{margin-right:24px;margin-left:0}.ui-pnotify-title-bs4{font-size:1.2rem}.ui-pnotify-text{display:block;white-space:pre-line}.ui-pnotify-icon,.ui-pnotify-icon span{display:block;float:left}[dir=rtl] .ui-pnotify-icon,[dir=rtl] .ui-pnotify-icon span{float:right}.ui-pnotify-icon-bs3 > span{position:relative;top:2px}.ui-pnotify-icon-bs4 > span{position:relative;top:4px}.ui-pnotify-modal-overlay{background-color:rgba(0, 0, 0, .4);top:0;left:0;position:absolute;height:100%;width:100%;z-index:2}body > .ui-pnotify-modal-overlay{position:fixed;z-index:100041}',U(document.head,o)),this._fragment=function(o,t){for(var s,r,a,c,l,u,f,d,p,m=[],h=X(),y=[],g=X(),e=t._modulesPrependContainer,_=function(t){return t.module.key},i=0;ib[O]?(T[M]=!0,S(N)):(k[O]=!0,m--):(l(H,a),m--)}for(;m--;){v[(H=t[m]).key]||l(H,a)}for(;h;)S(_[h-1]);return _}function nt(t,e){t.d(1),e[t.key]=null}function ot(t){t.parentNode.removeChild(t)}function st(t,e,i,n){t.removeEventListener(e,i,n)}function d(){return document.createComment("")}function s(t,e){t.data=""+e}function r(t,e){for(;t.nextSibling&&t.nextSibling!==e;)t.parentNode.removeChild(t.nextSibling)}function a(t,e){for(var i in e)t[i]=e[i];return t}function p(t){t._lock=!0,h(t._beforecreate),h(t._oncreate),h(t._aftercreate),t._lock=!1}function h(t){for(;t&&t.length;)t.shift()()}function y(){}return a(o.prototype,{destroy:function(t){this.destroy=y,this.fire("destroy"),this.set=y,this._fragment.d(!1!==t),this._fragment=null,this._state={}},get:function(){return this._state},fire:function(t,e){var i=t in this._handlers&&this._handlers[t].slice();if(!i)return;for(var n=0;ne){for(var i="top"===o.push,s=[],r=0,a=i?0:c.notices.length-1;i?a [ui-pnotify].ui-pnotify.ui-pnotify-mobile-able{position:fixed}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-top,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-bottom{width:100% !important}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-left,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-right{height:100% !important}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able .ui-pnotify-shadow{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-top .ui-pnotify-shadow{border-bottom-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-bottom .ui-pnotify-shadow{border-top-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-left .ui-pnotify-shadow{border-right-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-right .ui-pnotify-shadow{border-left-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able .ui-pnotify-container{-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-top .ui-pnotify-container,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-bottom .ui-pnotify-container{width:auto !important}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-left .ui-pnotify-container,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-right .ui-pnotify-container{height:100% !important}}",t=document.head,e=o,t.appendChild(e)}function e(i){var t,e,o=this;e=i,(t=this)._handlers=f(),t._slots=f(),t._bind=e._bind,t._staged={},t.options=e,t.root=e.root||t,t.store=e.store||t.root.store,e.root||(t._beforecreate=[],t._oncreate=[],t._aftercreate=[]),this._state=l(_extends({_notice:null,_options:{}},n.modules.Mobile.defaults),i.data),this._intro=!0,document.getElementById("svelte-49u8sj-style")||s(),this._fragment=(this._state,{c:r,m:r,p:r,d:r}),this.root._oncreate.push(function(){(function(){this.set({_doMobileStylingBound:this.doMobileStyling.bind(this)})}).call(o),o.fire("update",{changed:function(i,t){for(var e in t)i[e]=1;return i}({},o._state),current:o._state})}),i.target&&(this._fragment.c(),this._mount(i.target,i.anchor),a(this))}function r(){}function l(i,t){for(var e in t)i[e]=t[e];return i}function a(i){i._lock=!0,o(i._beforecreate),o(i._oncreate),o(i._aftercreate),i._lock=!1}function f(){return Object.create(null)}function o(i){for(;i&&i.length;)i.shift()()}return l(e.prototype,{destroy:function(i){this.destroy=r,this.fire("destroy"),this.set=r,this._fragment.d(!1!==i),this._fragment=null,this._state={}},get:function(){return this._state},fire:function(i,t){var e=i in this._handlers&&this._handlers[i].slice();if(!e)return;for(var o=0;ot.addpos2&&(t.addpos2=e.offsetHeight);break;case"left":case"right":e.offsetWidth+(parseFloat(e.style.marginLeft,10)||0)+(parseFloat(e.style.marginRight,10)||0)>t.addpos2&&(t.addpos2=e.offsetWidth)}}else if(t.dir1){var p=void 0,m=void 0;switch(t.dir1){case"down":case"up":m=["left","right"],p=t.context.scrollWidth/2-e.offsetWidth/2;break;case"left":case"right":m=["top","bottom"],p=s/2-e.offsetHeight/2}e.style[m[0]]=p+"px",e.style[m[1]]="auto",t.animation||e.style[m[0]]}if(t.dir1)switch("number"==typeof t.nextpos1&&(e.style[a]=t.nextpos1+"px",t.animation||e.style[a]),t.dir1){case"down":case"up":t.nextpos1+=e.offsetHeight+(void 0===t.spacing1?25:t.spacing1);break;case"left":case"right":t.nextpos1+=e.offsetWidth+(void 0===t.spacing1?25:t.spacing1)}else{var h=r/2-e.offsetWidth/2,y=s/2-e.offsetHeight/2;e.style.left=h+"px",e.style.top=y+"px",t.animation||e.style.left}return this}},queuePosition:function(t){return n&&clearTimeout(n),t=t||10,n=setTimeout(function(){g.positionAll()},t),this},cancelRemove:function(){return this.cancelClose()},cancelClose:function(){var t=this.get(),e=t._timer,i=t._animTimer,n=t._state,o=t.animation;return e&&clearTimeout(e),i&&clearTimeout(i),"closing"===n&&this.set({_state:"open",_animating:!1,_animatingClass:"fade"===o?"ui-pnotify-in ui-pnotify-fade-in":"ui-pnotify-in"}),this},queueRemove:function(){return this.queueClose()},queueClose:function(){var t=this;return this.cancelClose(),this.set({_timer:setTimeout(function(){return t.close(!0)},isNaN(this.get().delay)?0:this.get().delay)}),this},addModuleClass:function(){for(var t=this.get()._moduleClasses,e=arguments.length,i=Array(e),n=0;n .ui-pnotify{position:fixed;z-index:100040}body > .ui-pnotify.ui-pnotify-modal{z-index:100042}.ui-pnotify{position:absolute;height:auto;z-index:1;display:none}.ui-pnotify.ui-pnotify-modal{z-index:3}.ui-pnotify.ui-pnotify-in{display:block}.ui-pnotify.ui-pnotify-initial-hidden{display:block;visibility:hidden}.ui-pnotify.ui-pnotify-move{transition:left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-slow{transition:opacity .4s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-slow.ui-pnotify.ui-pnotify-move{transition:opacity .4s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-normal{transition:opacity .25s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-normal.ui-pnotify.ui-pnotify-move{transition:opacity .25s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-fast{transition:opacity .1s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-fast.ui-pnotify.ui-pnotify-move{transition:opacity .1s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-in{opacity:1}.ui-pnotify .ui-pnotify-shadow{-webkit-box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1);-moz-box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1);box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1)}.ui-pnotify-container{background-position:0 0;padding:.8em;height:100%;margin:0}.ui-pnotify-container:after{content:" ";visibility:hidden;display:block;height:0;clear:both}.ui-pnotify-container.ui-pnotify-sharp{-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.ui-pnotify-title{display:block;white-space:pre-line;margin-bottom:.4em;margin-top:0}.ui-pnotify.ui-pnotify-with-icon .ui-pnotify-title,.ui-pnotify.ui-pnotify-with-icon .ui-pnotify-text{margin-left:24px}[dir=rtl] .ui-pnotify.ui-pnotify-with-icon .ui-pnotify-title,[dir=rtl] .ui-pnotify.ui-pnotify-with-icon .ui-pnotify-text{margin-right:24px;margin-left:0}.ui-pnotify-title-bs4{font-size:1.2rem}.ui-pnotify-text{display:block;white-space:pre-line}.ui-pnotify-icon,.ui-pnotify-icon span{display:block;float:left}[dir=rtl] .ui-pnotify-icon,[dir=rtl] .ui-pnotify-icon span{float:right}.ui-pnotify-icon-bs3 > span{position:relative;top:2px}.ui-pnotify-icon-bs4 > span{position:relative;top:4px}.ui-pnotify-modal-overlay{background-color:rgba(0, 0, 0, .4);top:0;left:0;position:absolute;height:100%;width:100%;z-index:2}body > .ui-pnotify-modal-overlay{position:fixed;z-index:100041}',U(document.head,o)),this._fragment=function(o,t){for(var s,r,a,c,l,f,u,d,p,m=[],h=X(),y=[],g=X(),e=t._modulesPrependContainer,_=function(t){return t.module.key},i=0;ib[O]?(T[M]=!0,S(N)):(k[O]=!0,m--):(l(H,a),m--)}for(;m--;){v[(H=t[m]).key]||l(H,a)}for(;h;)S(_[h-1]);return _}function nt(t,e){t.d(1),e[t.key]=null}function ot(t){t.parentNode.removeChild(t)}function st(t,e,i,n){t.removeEventListener(e,i,n)}function d(){return document.createComment("")}function s(t,e){t.data=""+e}function r(t,e){for(;t.nextSibling&&t.nextSibling!==e;)t.parentNode.removeChild(t.nextSibling)}function a(t,e){for(var i in e)t[i]=e[i];return t}function p(t){t._lock=!0,h(t._beforecreate),h(t._oncreate),h(t._aftercreate),t._lock=!1}function h(t){for(;t&&t.length;)t.shift()()}function y(){}return a(o.prototype,{destroy:function(t){this.destroy=y,this.fire("destroy"),this.set=y,this._fragment.d(!1!==t),this._fragment=null,this._state={}},get:function(){return this._state},fire:function(t,e){var i=t in this._handlers&&this._handlers[t].slice();if(!i)return;for(var n=0;ne){for(var i="top"===n.push,s=[],r=0,f=i?0:c.notices.length-1;i?f [ui-pnotify].ui-pnotify.ui-pnotify-mobile-able{position:fixed}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-top,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-bottom{width:100% !important}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-left,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-right{height:100% !important}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able .ui-pnotify-shadow{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-top .ui-pnotify-shadow{border-bottom-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-bottom .ui-pnotify-shadow{border-top-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-left .ui-pnotify-shadow{border-right-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-right .ui-pnotify-shadow{border-left-width:5px}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able .ui-pnotify-container{-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-top .ui-pnotify-container,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-bottom .ui-pnotify-container{width:auto !important}[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-left .ui-pnotify-container,[ui-pnotify].ui-pnotify.ui-pnotify-mobile-able.ui-pnotify-mobile-right .ui-pnotify-container{height:100% !important}}",t=document.head,e=o,t.appendChild(e)}function e(i){var t,e,o=this;e=i,(t=this)._handlers=a(),t._slots=a(),t._bind=e._bind,t._staged={},t.options=e,t.root=e.root||t,t.store=e.store||t.root.store,e.root||(t._beforecreate=[],t._oncreate=[],t._aftercreate=[]),this._state=l(_extends({_notice:null,_options:{}},n.modules.Mobile.defaults),i.data),this._intro=!0,document.getElementById("svelte-49u8sj-style")||s(),this._fragment=(this._state,{c:r,m:r,p:r,d:r}),this.root._oncreate.push(function(){(function(){this.set({_doMobileStylingBound:this.doMobileStyling.bind(this)})}).call(o),o.fire("update",{changed:function(i,t){for(var e in t)i[e]=1;return i}({},o._state),current:o._state})}),i.target&&(this._fragment.c(),this._mount(i.target,i.anchor),f(this))}function r(){}function l(i,t){for(var e in t)i[e]=t[e];return i}function f(i){i._lock=!0,o(i._beforecreate),o(i._oncreate),o(i._aftercreate),i._lock=!1}function a(){return Object.create(null)}function o(i){for(;i&&i.length;)i.shift()()}return l(e.prototype,{destroy:function(i){this.destroy=r,this.fire("destroy"),this.set=r,this._fragment.d(!1!==i),this._fragment=null,this._state={}},get:function(){return this._state},fire:function(i,t){var e=i in this._handlers&&this._handlers[i].slice();if(!e)return;for(var o=0;o {
- PNotify.defaultStack.context = document.body;
- // Reposition the notices when the window resizes.
- window.addEventListener('resize', () => {
- if (posTimer) {
- clearTimeout(posTimer);
- }
- posTimer = setTimeout(() => {
- PNotify.positionAll();
- }, 10);
- });
-};
-
-// Creates the background overlay for modal stacks.
-let createStackOverlay = (stack) => {
- const overlay = document.createElement('div');
- overlay.classList.add('ui-pnotify-modal-overlay');
- if (stack.context !== document.body) {
- overlay.style.height = stack.context.scrollHeight + 'px';
- overlay.style.width = stack.context.scrollWidth + 'px';
- }
- // Close the notices on overlay click.
- overlay.addEventListener('click', () => {
- if (stack.overlayClose) {
- PNotify.closeStack(stack);
- }
- });
- stack.overlay = overlay;
-};
-
-let insertStackOverlay = (stack) => {
- if (stack.overlay.parentNode !== stack.context) {
- stack.overlay = stack.context.insertBefore(stack.overlay, stack.context.firstChild);
- }
-};
-
-let removeStackOverlay = (stack) => {
- if (stack.overlay.parentNode) {
- stack.overlay.parentNode.removeChild(stack.overlay);
- }
-};
-
-// Default arguments for the new notice helper functions.
-const getDefaultArgs = (options, type) => {
- if (typeof options !== 'object') {
- options = { 'text': options };
- }
-
- // Only assign the type if it was requested, so we don't overwrite
- // options.type if it has something assigned.
- if (type) {
- options.type = type;
- }
-
- return { target: document.body, data: options };
-};
-
-function _styles({ styling }) {
- return typeof styling === 'object' ? styling : PNotify.styling[styling];
-}
-
-function _icons({ icons }) {
- return typeof icons === 'object' ? icons : PNotify.icons[icons];
-}
-
-function _widthStyle({ width }) {
- return typeof width === 'string' ? 'width: ' + width + ';' : '';
-}
-
-function _minHeightStyle({ minHeight }) {
- return typeof minHeight === 'string' ? 'min-height: ' + minHeight + ';' : '';
-}
-
-function data() {
- const data = Object.assign({
- '_state': 'initializing', // The state can be 'initializing', 'opening', 'open', 'closing', and 'closed'.
- '_timer': null, // Auto close timer.
- '_animTimer': null, // Animation timer.
- '_animating': false, // Stores what is currently being animated (in or out).
- '_animatingClass': '', // Stores the class that adds entry/exit animation effects.
- '_moveClass': '', // Stores the class that adds movement animation effects.
- '_timerHide': false, // Stores whether the notice was hidden by a timer.
- '_moduleClasses': [], // Modules can add classes here to be added to the notice element. (They should play nice and not remove classes that aren't theirs.)
- '_moduleIsNoticeOpen': false, // Modules that change how the notice displays (causing the notice element to not appear) can set this to true to make PNotify assume the notice has opened.
- '_modules': {}, // Stores the instances of the modules.
- '_modulesPrependContainer': PNotify.modulesPrependContainer,
- '_modulesAppendContainer': PNotify.modulesAppendContainer
- }, PNotify.defaults);
- data.modules = Object.assign({}, PNotify.defaults.modules);
- return data;
-};
-
-var methods = {
- // This runs an event on all the modules.
- runModules (event) {
- if (event === 'init') {
- // Initializing a module should only be done if it has an init
- // function, which means it's not rendered in the template.
- for (let key in PNotify.modules) {
- if (!PNotify.modules.hasOwnProperty(key)) {
- continue;
- }
- if (typeof PNotify.modules[key].init === 'function') {
- const module = PNotify.modules[key].init(this);
- this.initModule(module);
- }
- }
- } else {
- const { _modules } = this.get();
- for (let module in _modules) {
- if (!_modules.hasOwnProperty(module)) {
- continue;
- }
- const moduleOptions = Object.assign({
- '_notice': this,
- '_options': this.get()
- }, this.get().modules[module]);
- _modules[module].set(moduleOptions);
- if (typeof _modules[module][event] === 'function') {
- _modules[module][event]();
- }
- }
- }
- },
-
- // This passes module options to a module.
- initModule (module) {
- const { modules } = this.get();
- if (!modules.hasOwnProperty(module.constructor.key)) {
- modules[module.constructor.key] = {};
- }
- const moduleOptions = Object.assign({
- '_notice': this,
- '_options': this.get()
- }, modules[module.constructor.key]);
- module.initModule(moduleOptions);
-
- // Now save the module instance.
- const { _modules } = this.get();
- _modules[module.constructor.key] = module;
- },
-
- update (options) {
- // Save old options.
- const oldHide = this.get().hide;
- const oldIcon = this.get().icon;
-
- this.set(options);
-
- // Run the modules.
- this.runModules('update');
-
- // Update the timed hiding.
- if (!this.get().hide) {
- this.cancelClose();
- } else if (!oldHide) {
- this.queueClose();
- }
- this.queuePosition();
-
- // Font Awesome 5 replaces our lovely element with a gross SVG. In order
- // to make it play nice with Svelte, we have to clear the element and
- // make it again.
- const { icon } = this.get();
- if (
- icon !== oldIcon &&
- (
- (icon === true && this.get().icons === 'fontawesome5') ||
- (typeof icon === 'string' && icon.match(/(^| )fa[srlb]($| )/))
- )
- ) {
- this.set({ 'icon': false });
- this.set({ 'icon': icon });
- }
-
- return this;
- },
-
- // Display the notice.
- open () {
- const { _state, hide } = this.get();
- if (_state === 'opening') {
- return;
- }
- if (_state === 'open') {
- if (hide) {
- this.queueClose();
- }
- return;
- }
- this.set({
- '_state': 'opening',
- // This makes the notice visibity: hidden; so its dimensions can be
- // determined.
- '_animatingClass': 'ui-pnotify-initial-hidden'
- });
- // Run the modules.
- this.runModules('beforeOpen');
-
- let { stack } = this.get();
- // If the notice is not in the DOM, or in the wrong context, append it.
- if (
- !this.refs.elem.parentNode ||
- (
- stack &&
- stack.context &&
- stack.context !== this.refs.elem.parentNode
- )
- ) {
- if (stack && stack.context) {
- stack.context.appendChild(this.refs.elem);
- } else if (document.body) {
- document.body.appendChild(this.refs.elem);
- } else {
- throw new Error('No context to open this notice in.');
- }
- }
-
- // Wait until the DOM is updated.
- setTimeout(() => {
- if (stack) {
- // Mark the stack so it won't animate the new notice.
- stack.animation = false;
- // Now position all the notices.
- PNotify.positionAll();
- // Reset animation.
- stack.animation = true;
- }
-
- this.animateIn(() => {
- // Now set it to hide.
- if (this.get().hide) {
- this.queueClose();
- }
-
- this.set({ '_state': 'open' });
-
- // Run the modules.
- this.runModules('afterOpen');
- });
- }, 0);
-
- return this;
- },
-
- remove (timerHide) {
- return this.close(timerHide);
- },
-
- // Remove the notice.
- close (timerHide) {
- const { _state } = this.get();
- if (_state === 'closing' || _state === 'closed') {
- return;
- }
- this.set({ '_state': 'closing', '_timerHide': !!timerHide }); // Make sure it's a boolean.
- // Run the modules.
- this.runModules('beforeClose');
-
- const { _timer } = this.get();
- if (_timer && clearTimeout) {
- clearTimeout(_timer);
- this.set({ '_timer': null });
- }
- this.animateOut(() => {
- this.set({ '_state': 'closed' });
- // Run the modules.
- this.runModules('afterClose');
- this.queuePosition();
- // If we're supposed to remove the notice from the DOM, do it.
- if (this.get().remove) {
- this.refs.elem.parentNode.removeChild(this.refs.elem);
- }
- // Run the modules.
- this.runModules('beforeDestroy');
- // Remove object from PNotify.notices to prevent memory leak (issue #49)
- // unless destroy is off
- if (this.get().destroy) {
- if (PNotify.notices !== null) {
- const idx = PNotify.notices.indexOf(this);
- if (idx !== -1) {
- PNotify.notices.splice(idx, 1);
- }
- }
- }
- // Run the modules.
- this.runModules('afterDestroy');
- });
-
- return this;
- },
-
- // Animate the notice in.
- animateIn (callback) {
- // Declare that the notice is animating in.
- this.set({ '_animating': 'in' });
- const finished = () => {
- this.refs.elem.removeEventListener('transitionend', finished);
- const { _animTimer, _animating, _moduleIsNoticeOpen } = this.get();
- if (_animTimer) {
- clearTimeout(_animTimer);
- }
- if (_animating !== 'in') {
- return;
- }
- let visible = _moduleIsNoticeOpen;
- if (!visible) {
- const domRect = this.refs.elem.getBoundingClientRect();
- for (let prop in domRect) {
- if (domRect[prop] > 0) {
- visible = true;
- break;
- }
- }
- }
- if (visible) {
- if (callback) {
- callback.call();
- }
- // Declare that the notice has completed animating.
- this.set({ '_animating': false });
- } else {
- this.set({ '_animTimer': setTimeout(finished, 40) });
- }
- };
-
- if (this.get().animation === 'fade') {
- this.refs.elem.addEventListener('transitionend', finished);
- this.set({ '_animatingClass': 'ui-pnotify-in' });
- // eslint-disable-next-line no-unused-expressions
- this.refs.elem.style.opacity; // This line is necessary for some reason. Some notices don't fade without it.
- this.set({ '_animatingClass': 'ui-pnotify-in ui-pnotify-fade-in' });
- // Just in case the event doesn't fire, call it after 650 ms.
- this.set({ '_animTimer': setTimeout(finished, 650) });
- } else {
- this.set({ '_animatingClass': 'ui-pnotify-in' });
- finished();
- }
- },
-
- // Animate the notice out.
- animateOut (callback) {
- // Declare that the notice is animating out.
- this.set({ '_animating': 'out' });
- const finished = () => {
- this.refs.elem.removeEventListener('transitionend', finished);
- const { _animTimer, _animating, _moduleIsNoticeOpen } = this.get();
- if (_animTimer) {
- clearTimeout(_animTimer);
- }
- if (_animating !== 'out') {
- return;
- }
- let visible = _moduleIsNoticeOpen;
- if (!visible) {
- const domRect = this.refs.elem.getBoundingClientRect();
- for (let prop in domRect) {
- if (domRect[prop] > 0) {
- visible = true;
- break;
- }
- }
- }
- if (!this.refs.elem.style.opacity || this.refs.elem.style.opacity === '0' || !visible) {
- this.set({ '_animatingClass': '' });
- const { stack } = this.get();
- if (stack && stack.overlay) {
- // Go through the modal stack to see if any are left open.
- // TODO: Rewrite this cause it sucks.
- let stillOpen = false;
- for (let i = 0; i < PNotify.notices.length; i++) {
- const notice = PNotify.notices[i];
- if (notice !== this && notice.get().stack === stack && notice.get()._state !== 'closed') {
- stillOpen = true;
- break;
- }
- }
- if (!stillOpen) {
- removeStackOverlay(stack);
- }
- }
- if (callback) {
- callback.call();
- }
- // Declare that the notice has completed animating.
- this.set({ '_animating': false });
- } else {
- // In case this was called before the notice finished animating.
- this.set({ '_animTimer': setTimeout(finished, 40) });
- }
- };
-
- if (this.get().animation === 'fade') {
- this.refs.elem.addEventListener('transitionend', finished);
- this.set({ '_animatingClass': 'ui-pnotify-in' });
- // Just in case the event doesn't fire, call it after 650 ms.
- this.set({ '_animTimer': setTimeout(finished, 650) });
- } else {
- this.set({ '_animatingClass': '' });
- finished();
- }
- },
-
- // Position the notice.
- position () {
- // Get the notice's stack.
- let { stack } = this.get();
- let elem = this.refs.elem;
- if (!stack) {
- return;
- }
- if (!stack.context) {
- stack.context = document.body;
- }
- if (typeof stack.nextpos1 !== 'number') {
- stack.nextpos1 = stack.firstpos1;
- }
- if (typeof stack.nextpos2 !== 'number') {
- stack.nextpos2 = stack.firstpos2;
- }
- if (typeof stack.addpos2 !== 'number') {
- stack.addpos2 = 0;
- }
-
- // Skip this notice if it's not shown.
- if (
- !elem.classList.contains('ui-pnotify-in') &&
- !elem.classList.contains('ui-pnotify-initial-hidden')
- ) {
- return this;
- }
-
- if (stack.modal) {
- if (!stack.overlay) {
- createStackOverlay(stack);
- }
- insertStackOverlay(stack);
- }
-
- // Read from the DOM to cause refresh.
- elem.getBoundingClientRect();
-
- if (stack.animation) {
- // Add animate class.
- this.set({ '_moveClass': 'ui-pnotify-move' });
- }
-
- let spaceY = (stack.context === document.body ? window.innerHeight : stack.context.scrollHeight);
- let spaceX = (stack.context === document.body ? window.innerWidth : stack.context.scrollWidth);
-
- let csspos1;
-
- if (stack.dir1) {
- csspos1 = {
- 'down': 'top',
- 'up': 'bottom',
- 'left': 'right',
- 'right': 'left'
- }[stack.dir1];
-
- // Calculate the current pos1 value.
- let curpos1;
- switch (stack.dir1) {
- case 'down':
- curpos1 = elem.offsetTop;
- break;
- case 'up':
- curpos1 = spaceY - elem.scrollHeight - elem.offsetTop;
- break;
- case 'left':
- curpos1 = spaceX - elem.scrollWidth - elem.offsetLeft;
- break;
- case 'right':
- curpos1 = elem.offsetLeft;
- break;
- }
- // Remember the first pos1, so the first notice goes there.
- if (typeof stack.firstpos1 === 'undefined') {
- stack.firstpos1 = curpos1;
- stack.nextpos1 = stack.firstpos1;
- }
- }
-
- if (stack.dir1 && stack.dir2) {
- let csspos2 = {
- 'down': 'top',
- 'up': 'bottom',
- 'left': 'right',
- 'right': 'left'
- }[stack.dir2];
-
- // Calculate the current pos2 value.
- let curpos2;
- switch (stack.dir2) {
- case 'down':
- curpos2 = elem.offsetTop;
- break;
- case 'up':
- curpos2 = spaceY - elem.scrollHeight - elem.offsetTop;
- break;
- case 'left':
- curpos2 = spaceX - elem.scrollWidth - elem.offsetLeft;
- break;
- case 'right':
- curpos2 = elem.offsetLeft;
- break;
- }
- // Remember the first pos2, so the first notice goes there.
- if (typeof stack.firstpos2 === 'undefined') {
- stack.firstpos2 = curpos2;
- stack.nextpos2 = stack.firstpos2;
- }
-
- // Check that it's not beyond the viewport edge.
- const endY = stack.nextpos1 + elem.offsetHeight + (typeof stack.spacing1 === 'undefined' ? 25 : stack.spacing1);
- const endX = stack.nextpos1 + elem.offsetWidth + (typeof stack.spacing1 === 'undefined' ? 25 : stack.spacing1);
- if (
- ((stack.dir1 === 'down' || stack.dir1 === 'up') && endY > spaceY) ||
- ((stack.dir1 === 'left' || stack.dir1 === 'right') && endX > spaceX)
- ) {
- // If it is, it needs to go back to the first pos1, and over on pos2.
- stack.nextpos1 = stack.firstpos1;
- stack.nextpos2 += stack.addpos2 + (typeof stack.spacing2 === 'undefined' ? 25 : stack.spacing2);
- stack.addpos2 = 0;
- }
-
- // Move the notice on dir2.
- if (typeof stack.nextpos2 === 'number') {
- elem.style[csspos2] = stack.nextpos2 + 'px';
- if (!stack.animation) {
- // eslint-disable-next-line no-unused-expressions
- elem.style[csspos2]; // Read from the DOM for update.
- }
- }
-
- // Keep track of the widest/tallest notice in the column/row, so we can push the next column/row.
- switch (stack.dir2) {
- case 'down':
- case 'up':
- if (elem.offsetHeight + (parseFloat(elem.style.marginTop, 10) || 0) + (parseFloat(elem.style.marginBottom, 10) || 0) > stack.addpos2) {
- stack.addpos2 = elem.offsetHeight;
- }
- break;
- case 'left':
- case 'right':
- if (elem.offsetWidth + (parseFloat(elem.style.marginLeft, 10) || 0) + (parseFloat(elem.style.marginRight, 10) || 0) > stack.addpos2) {
- stack.addpos2 = elem.offsetWidth;
- }
- break;
- }
- } else if (stack.dir1) {
- // Center the notice along dir1 axis, because the stack has no dir2.
- let cssMiddle, cssposCross;
- switch (stack.dir1) {
- case 'down':
- case 'up':
- cssposCross = ['left', 'right'];
- cssMiddle = (stack.context.scrollWidth / 2) - (elem.offsetWidth / 2);
- break;
- case 'left':
- case 'right':
- cssposCross = ['top', 'bottom'];
- cssMiddle = (spaceY / 2) - (elem.offsetHeight / 2);
- break;
- }
- elem.style[cssposCross[0]] = cssMiddle + 'px';
- elem.style[cssposCross[1]] = 'auto';
- if (!stack.animation) {
- // eslint-disable-next-line no-unused-expressions
- elem.style[cssposCross[0]]; // Read from the DOM for update.
- }
- }
-
- if (stack.dir1) {
- // Move the notice on dir1.
- if (typeof stack.nextpos1 === 'number') {
- elem.style[csspos1] = stack.nextpos1 + 'px';
- if (!stack.animation) {
- // eslint-disable-next-line no-unused-expressions
- elem.style[csspos1]; // Read from the DOM for update.
- }
- }
-
- // Calculate the next dir1 position.
- switch (stack.dir1) {
- case 'down':
- case 'up':
- stack.nextpos1 += elem.offsetHeight + (typeof stack.spacing1 === 'undefined' ? 25 : stack.spacing1);
- break;
- case 'left':
- case 'right':
- stack.nextpos1 += elem.offsetWidth + (typeof stack.spacing1 === 'undefined' ? 25 : stack.spacing1);
- break;
- }
- } else {
- // Center the notice on the screen, because the stack has no dir1.
- let cssMiddleLeft = (spaceX / 2) - (elem.offsetWidth / 2);
- let cssMiddleTop = (spaceY / 2) - (elem.offsetHeight / 2);
- elem.style.left = cssMiddleLeft + 'px';
- elem.style.top = cssMiddleTop + 'px';
- if (!stack.animation) {
- // eslint-disable-next-line no-unused-expressions
- elem.style.left; // Read from the DOM for update.
- }
- }
-
- return this;
- },
-
- // Queue the position all function so it doesn't run repeatedly and
- // use up resources.
- queuePosition (milliseconds) {
- if (posTimer) {
- clearTimeout(posTimer);
- }
- if (!milliseconds) {
- milliseconds = 10;
- }
- posTimer = setTimeout(() => {
- PNotify.positionAll();
- }, milliseconds);
- return this;
- },
-
- cancelRemove () {
- return this.cancelClose();
- },
-
- // Cancel any pending removal timer.
- cancelClose () {
- const { _timer, _animTimer, _state, animation } = this.get();
- if (_timer) {
- clearTimeout(_timer);
- }
- if (_animTimer) {
- clearTimeout(_animTimer);
- }
- if (_state === 'closing') {
- // If it's animating out, stop it.
- this.set({
- '_state': 'open',
- '_animating': false,
- '_animatingClass': animation === 'fade' ? 'ui-pnotify-in ui-pnotify-fade-in' : 'ui-pnotify-in'
- });
- }
- return this;
- },
-
- queueRemove () {
- return this.queueClose();
- },
-
- // Queue a close timer.
- queueClose () {
- // Cancel any current close timer.
- this.cancelClose();
- this.set({
- '_timer': setTimeout(() => this.close(true), (isNaN(this.get().delay) ? 0 : this.get().delay))
- });
- return this;
- },
-
- addModuleClass (...classNames) {
- const { _moduleClasses } = this.get();
- for (let i = 0; i < classNames.length; i++) {
- let className = classNames[i];
- if (_moduleClasses.indexOf(className) === -1) {
- _moduleClasses.push(className);
- }
- }
- this.set({ _moduleClasses });
- },
-
- removeModuleClass (...classNames) {
- const { _moduleClasses } = this.get();
- for (let i = 0; i < classNames.length; i++) {
- let className = classNames[i];
- const idx = _moduleClasses.indexOf(className);
- if (idx !== -1) {
- _moduleClasses.splice(idx, 1);
- }
- }
- this.set({ _moduleClasses });
- },
-
- hasModuleClass (...classNames) {
- const { _moduleClasses } = this.get();
- for (let i = 0; i < classNames.length; i++) {
- let className = classNames[i];
- if (_moduleClasses.indexOf(className) === -1) {
- return false;
- }
- }
- return true;
- }
-};
-
-function oncreate() {
- this.on('mouseenter', (e) => {
- // Stop animation, reset the removal timer when the user mouses over.
- if (this.get().mouseReset && this.get()._animating === 'out') {
- if (!this.get()._timerHide) {
- return;
- }
- this.cancelClose();
- }
- // Stop the close timer.
- if (this.get().hide && this.get().mouseReset) {
- this.cancelClose();
- }
- });
-
- this.on('mouseleave', (e) => {
- // Start the close timer.
- if (this.get().hide && this.get().mouseReset && this.get()._animating !== 'out') {
- this.queueClose();
- }
- PNotify.positionAll();
- });
-
- let { stack } = this.get();
-
- // Add the notice to the notice array.
- if (stack && stack.push === 'top') {
- PNotify.notices.splice(0, 0, this);
- } else {
- PNotify.notices.push(this);
- }
-
- // Run the modules.
- this.runModules('init');
-
- // We're now initialized, but haven't been opened yet.
- this.set({ '_state': 'closed' });
-
- // Display the notice.
- if (this.get().autoDisplay) {
- this.open();
- }
-};
-
-function setup(Component) {
- // Add static properties to the PNotify object.
- PNotify = Component;
-
- PNotify.VERSION = '4.0.1';
-
- PNotify.defaultStack = {
- dir1: 'down',
- dir2: 'left',
- firstpos1: 25,
- firstpos2: 25,
- spacing1: 36,
- spacing2: 36,
- push: 'bottom',
- context: window && document.body
- };
-
- PNotify.defaults = {
- // The notice's title.
- title: false,
- // Whether to trust the title or escape its contents. (Not allow HTML.)
- titleTrusted: false,
- // The notice's text.
- text: false,
- // Whether to trust the text or escape its contents. (Not allow HTML.)
- textTrusted: false,
- // What styling classes to use. (Can be 'brighttheme', 'bootstrap3', 'bootstrap4', or a styling object.)
- styling: 'brighttheme',
- // What icons to use (Can be 'brighttheme', 'bootstrap3', 'fontawesome4', 'fontawesome5', or an icon object.)
- icons: 'brighttheme',
- // Additional classes to be added to the notice. (For custom styling.)
- addClass: '',
- // Class to be added to the notice for corner styling.
- cornerClass: '',
- // Display the notice when it is created.
- autoDisplay: true,
- // Width of the notice.
- width: '360px',
- // Minimum height of the notice. It will expand to fit content.
- minHeight: '16px',
- // Type of the notice. 'notice', 'info', 'success', or 'error'.
- type: 'notice',
- // Set icon to true to use the default icon for the selected
- // style/type, false for no icon, or a string for your own icon class.
- icon: true,
- // The animation to use when displaying and hiding the notice. 'none'
- // and 'fade' are supported through CSS. Others are supported
- // through the Animate module and Animate.css.
- animation: 'fade',
- // Speed at which the notice animates in and out. 'slow', 'normal',
- // or 'fast'. Respectively, 400ms, 250ms, 100ms.
- animateSpeed: 'normal',
- // Display a drop shadow.
- shadow: true,
- // After a delay, remove the notice.
- hide: true,
- // Delay in milliseconds before the notice is removed.
- delay: 8000,
- // Reset the hide timer if the mouse moves over the notice.
- mouseReset: true,
- // Remove the notice's elements from the DOM after it is removed.
- remove: true,
- // Whether to remove the notice from the global array when it is closed.
- destroy: true,
- // The stack on which the notices will be placed. Also controls the
- // direction the notices stack.
- stack: PNotify.defaultStack,
- // This is where options for modules should be defined.
- modules: {}
- };
-
- // An array of all active notices.
- PNotify.notices = [];
-
- // This object holds all the PNotify modules. They are used to provide
- // additional functionality.
- PNotify.modules = {};
-
- // Modules can add themselves to these to be rendered in the template.
- PNotify.modulesPrependContainer = [];
- PNotify.modulesAppendContainer = [];
-
- // Helper function to create a new notice.
- PNotify.alert = (options) => new PNotify(getDefaultArgs(options));
- // Helper function to create a new notice (notice type).
- PNotify.notice = (options) => new PNotify(getDefaultArgs(options, 'notice'));
- // Helper function to create a new notice (info type).
- PNotify.info = (options) => new PNotify(getDefaultArgs(options, 'info'));
- // Helper function to create a new notice (success type).
- PNotify.success = (options) => new PNotify(getDefaultArgs(options, 'success'));
- // Helper function to create a new notice (error type).
- PNotify.error = (options) => new PNotify(getDefaultArgs(options, 'error'));
-
- PNotify.removeAll = () => {
- PNotify.closeAll();
- };
-
- // Close all notices.
- PNotify.closeAll = () => {
- for (let i = 0; i < PNotify.notices.length; i++) {
- if (PNotify.notices[i].close) {
- PNotify.notices[i].close(false);
- }
- }
- };
-
- PNotify.removeStack = (stack) => {
- PNotify.closeStack(stack);
- };
-
- // Close all notices in a single stack.
- PNotify.closeStack = (stack) => {
- if (stack === false) {
- return;
- }
- for (let i = 0; i < PNotify.notices.length; i++) {
- if (PNotify.notices[i].close && PNotify.notices[i].get().stack === stack) {
- PNotify.notices[i].close(false);
- }
- }
- };
-
- // Position all notices.
- PNotify.positionAll = () => {
- // This timer is used for queueing this function so it doesn't run
- // repeatedly.
- if (posTimer) {
- clearTimeout(posTimer);
- }
- posTimer = null;
- // Reset the next position data.
- if (PNotify.notices.length > 0) {
- for (let i = 0; i < PNotify.notices.length; i++) {
- let notice = PNotify.notices[i];
- let { stack } = notice.get();
- if (!stack) {
- continue;
- }
- if (stack.overlay) {
- removeStackOverlay(stack);
- }
- stack.nextpos1 = stack.firstpos1;
- stack.nextpos2 = stack.firstpos2;
- stack.addpos2 = 0;
- }
- for (let i = 0; i < PNotify.notices.length; i++) {
- PNotify.notices[i].position();
- }
- } else {
- delete PNotify.defaultStack.nextpos1;
- delete PNotify.defaultStack.nextpos2;
- }
- };
-
- PNotify.styling = {
- brighttheme: {
- // Bright Theme doesn't require any UI libraries.
- container: 'brighttheme',
- notice: 'brighttheme-notice',
- info: 'brighttheme-info',
- success: 'brighttheme-success',
- error: 'brighttheme-error'
- },
- bootstrap3: {
- container: 'alert',
- notice: 'alert-warning',
- info: 'alert-info',
- success: 'alert-success',
- error: 'alert-danger',
- icon: 'ui-pnotify-icon-bs3'
- },
- bootstrap4: {
- container: 'alert',
- notice: 'alert-warning',
- info: 'alert-info',
- success: 'alert-success',
- error: 'alert-danger',
- icon: 'ui-pnotify-icon-bs4',
- title: 'ui-pnotify-title-bs4'
- }
- };
-
- // icons are separate from the style, since bs4 doesn't come with any
- PNotify.icons = {
- brighttheme: {
- notice: 'brighttheme-icon-notice',
- info: 'brighttheme-icon-info',
- success: 'brighttheme-icon-success',
- error: 'brighttheme-icon-error'
- },
- bootstrap3: {
- notice: 'glyphicon glyphicon-exclamation-sign',
- info: 'glyphicon glyphicon-info-sign',
- success: 'glyphicon glyphicon-ok-sign',
- error: 'glyphicon glyphicon-warning-sign'
- },
- // User must have Font Awesome v4.0+
- fontawesome4: {
- notice: 'fa fa-exclamation-circle',
- info: 'fa fa-info-circle',
- success: 'fa fa-check-circle',
- error: 'fa fa-exclamation-triangle'
- },
- // User must have Font Awesome v5.0+
- fontawesome5: {
- notice: 'fas fa-exclamation-circle',
- info: 'fas fa-info-circle',
- success: 'fas fa-check-circle',
- error: 'fas fa-exclamation-triangle'
- }
- };
-
- // Run the deferred actions once the DOM is ready.
- if (window && document.body) {
- onDocumentLoaded();
- } else {
- document.addEventListener('DOMContentLoaded', onDocumentLoaded);
- }
-}
-
-function add_css() {
- var style = createElement("style");
- style.id = 'svelte-1eldsjg-style';
- style.textContent = "body > .ui-pnotify{position:fixed;z-index:100040}body > .ui-pnotify.ui-pnotify-modal{z-index:100042}.ui-pnotify{position:absolute;height:auto;z-index:1;display:none}.ui-pnotify.ui-pnotify-modal{z-index:3}.ui-pnotify.ui-pnotify-in{display:block}.ui-pnotify.ui-pnotify-initial-hidden{display:block;visibility:hidden}.ui-pnotify.ui-pnotify-move{transition:left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-slow{transition:opacity .4s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-slow.ui-pnotify.ui-pnotify-move{transition:opacity .4s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-normal{transition:opacity .25s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-normal.ui-pnotify.ui-pnotify-move{transition:opacity .25s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-fast{transition:opacity .1s linear;opacity:0}.ui-pnotify.ui-pnotify-fade-fast.ui-pnotify.ui-pnotify-move{transition:opacity .1s linear, left .5s ease, top .5s ease, right .5s ease, bottom .5s ease}.ui-pnotify.ui-pnotify-fade-in{opacity:1}.ui-pnotify .ui-pnotify-shadow{-webkit-box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1);-moz-box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1);box-shadow:0px 6px 28px 0px rgba(0,0,0,0.1)}.ui-pnotify-container{background-position:0 0;padding:.8em;height:100%;margin:0}.ui-pnotify-container:after{content:\" \";visibility:hidden;display:block;height:0;clear:both}.ui-pnotify-container.ui-pnotify-sharp{-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.ui-pnotify-title{display:block;white-space:pre-line;margin-bottom:.4em;margin-top:0}.ui-pnotify.ui-pnotify-with-icon .ui-pnotify-title,.ui-pnotify.ui-pnotify-with-icon .ui-pnotify-text{margin-left:24px}[dir=rtl] .ui-pnotify.ui-pnotify-with-icon .ui-pnotify-title,[dir=rtl] .ui-pnotify.ui-pnotify-with-icon .ui-pnotify-text{margin-right:24px;margin-left:0}.ui-pnotify-title-bs4{font-size:1.2rem}.ui-pnotify-text{display:block;white-space:pre-line}.ui-pnotify-icon,.ui-pnotify-icon span{display:block;float:left}[dir=rtl] .ui-pnotify-icon,[dir=rtl] .ui-pnotify-icon span{float:right}.ui-pnotify-icon-bs3 > span{position:relative;top:2px}.ui-pnotify-icon-bs4 > span{position:relative;top:4px}.ui-pnotify-modal-overlay{background-color:rgba(0, 0, 0, .4);top:0;left:0;position:absolute;height:100%;width:100%;z-index:2}body > .ui-pnotify-modal-overlay{position:fixed;z-index:100041}";
- append(document.head, style);
-}
-
-function get_each1_context(ctx, list, i) {
- const child_ctx = Object.create(ctx);
- child_ctx.module = list[i];
- return child_ctx;
-}
-
-function get_each0_context(ctx, list, i) {
- const child_ctx = Object.create(ctx);
- child_ctx.module = list[i];
- return child_ctx;
-}
-
-function create_main_fragment(component, ctx) {
- var div1, div0, each0_blocks_1 = [], each0_lookup = blankObject(), text0, text1, text2, text3, each1_blocks_1 = [], each1_lookup = blankObject(), div0_class_value, div0_style_value, div1_class_value;
-
- var each0_value = ctx._modulesPrependContainer;
-
- const get_key = ctx => ctx.module.key;
-
- for (var i = 0; i < each0_value.length; i += 1) {
- let child_ctx = get_each0_context(ctx, each0_value, i);
- let key = get_key(child_ctx);
- each0_blocks_1[i] = each0_lookup[key] = create_each_block_1(component, key, child_ctx);
- }
-
- var if_block0 = (ctx.icon !== false) && create_if_block_4(component, ctx);
-
- var if_block1 = (ctx.title !== false) && create_if_block_2(component, ctx);
-
- var if_block2 = (ctx.text !== false) && create_if_block(component, ctx);
-
- var each1_value = ctx._modulesAppendContainer;
-
- const get_key_1 = ctx => ctx.module.key;
-
- for (var i = 0; i < each1_value.length; i += 1) {
- let child_ctx = get_each1_context(ctx, each1_value, i);
- let key = get_key_1(child_ctx);
- each1_blocks_1[i] = each1_lookup[key] = create_each_block(component, key, child_ctx);
- }
-
- function mouseover_handler(event) {
- component.fire("mouseover", event);
- }
-
- function mouseout_handler(event) {
- component.fire("mouseout", event);
- }
-
- function mouseenter_handler(event) {
- component.fire("mouseenter", event);
- }
-
- function mouseleave_handler(event) {
- component.fire("mouseleave", event);
- }
-
- function mousemove_handler(event) {
- component.fire("mousemove", event);
- }
-
- function mousedown_handler(event) {
- component.fire("mousedown", event);
- }
-
- function mouseup_handler(event) {
- component.fire("mouseup", event);
- }
-
- function click_handler(event) {
- component.fire("click", event);
- }
-
- function dblclick_handler(event) {
- component.fire("dblclick", event);
- }
-
- function focus_handler(event) {
- component.fire("focus", event);
- }
-
- function blur_handler(event) {
- component.fire("blur", event);
- }
-
- function touchstart_handler(event) {
- component.fire("touchstart", event);
- }
-
- function touchmove_handler(event) {
- component.fire("touchmove", event);
- }
-
- function touchend_handler(event) {
- component.fire("touchend", event);
- }
-
- function touchcancel_handler(event) {
- component.fire("touchcancel", event);
- }
-
- return {
- c() {
- div1 = createElement("div");
- div0 = createElement("div");
-
- for (i = 0; i < each0_blocks_1.length; i += 1) each0_blocks_1[i].c();
-
- text0 = createText("\n ");
- if (if_block0) if_block0.c();
- text1 = createText("\n ");
- if (if_block1) if_block1.c();
- text2 = createText("\n ");
- if (if_block2) if_block2.c();
- text3 = createText("\n ");
-
- for (i = 0; i < each1_blocks_1.length; i += 1) each1_blocks_1[i].c();
- div0.className = div0_class_value = "\n ui-pnotify-container\n " + (ctx._styles.container ? ctx._styles.container : '') + "\n " + (ctx._styles[ctx.type] ? ctx._styles[ctx.type] : '') + "\n " + ctx.cornerClass + "\n " + (ctx.shadow ? 'ui-pnotify-shadow' : '') + "\n ";
- div0.style.cssText = div0_style_value = "" + ctx._widthStyle + " " + ctx._minHeightStyle;
- setAttribute(div0, "role", "alert");
- addListener(div1, "mouseover", mouseover_handler);
- addListener(div1, "mouseout", mouseout_handler);
- addListener(div1, "mouseenter", mouseenter_handler);
- addListener(div1, "mouseleave", mouseleave_handler);
- addListener(div1, "mousemove", mousemove_handler);
- addListener(div1, "mousedown", mousedown_handler);
- addListener(div1, "mouseup", mouseup_handler);
- addListener(div1, "click", click_handler);
- addListener(div1, "dblclick", dblclick_handler);
- addListener(div1, "focus", focus_handler);
- addListener(div1, "blur", blur_handler);
- addListener(div1, "touchstart", touchstart_handler);
- addListener(div1, "touchmove", touchmove_handler);
- addListener(div1, "touchend", touchend_handler);
- addListener(div1, "touchcancel", touchcancel_handler);
- div1.className = div1_class_value = "\n ui-pnotify\n " + (ctx.icon !== false ? 'ui-pnotify-with-icon' : '') + "\n " + (ctx._styles.element ? ctx._styles.element : '') + "\n " + ctx.addClass + "\n " + ctx._animatingClass + "\n " + ctx._moveClass + "\n " + (ctx.animation === 'fade' ? 'ui-pnotify-fade-'+ctx.animateSpeed : '') + "\n " + (ctx.stack && ctx.stack.modal ? 'ui-pnotify-modal' : '') + "\n " + ctx._moduleClasses.join(' ') + "\n ";
- setAttribute(div1, "aria-live", "assertive");
- setAttribute(div1, "role", "alertdialog");
- setAttribute(div1, "ui-pnotify", true);
- },
-
- m(target, anchor) {
- insert(target, div1, anchor);
- append(div1, div0);
-
- for (i = 0; i < each0_blocks_1.length; i += 1) each0_blocks_1[i].m(div0, null);
-
- append(div0, text0);
- if (if_block0) if_block0.m(div0, null);
- append(div0, text1);
- if (if_block1) if_block1.m(div0, null);
- append(div0, text2);
- if (if_block2) if_block2.m(div0, null);
- append(div0, text3);
-
- for (i = 0; i < each1_blocks_1.length; i += 1) each1_blocks_1[i].m(div0, null);
-
- component.refs.container = div0;
- component.refs.elem = div1;
- },
-
- p(changed, ctx) {
- const each0_value = ctx._modulesPrependContainer;
- each0_blocks_1 = updateKeyedEach(each0_blocks_1, component, changed, get_key, 1, ctx, each0_value, each0_lookup, div0, destroyBlock, create_each_block_1, "m", text0, get_each0_context);
-
- if (ctx.icon !== false) {
- if (if_block0) {
- if_block0.p(changed, ctx);
- } else {
- if_block0 = create_if_block_4(component, ctx);
- if_block0.c();
- if_block0.m(div0, text1);
- }
- } else if (if_block0) {
- if_block0.d(1);
- if_block0 = null;
- }
-
- if (ctx.title !== false) {
- if (if_block1) {
- if_block1.p(changed, ctx);
- } else {
- if_block1 = create_if_block_2(component, ctx);
- if_block1.c();
- if_block1.m(div0, text2);
- }
- } else if (if_block1) {
- if_block1.d(1);
- if_block1 = null;
- }
-
- if (ctx.text !== false) {
- if (if_block2) {
- if_block2.p(changed, ctx);
- } else {
- if_block2 = create_if_block(component, ctx);
- if_block2.c();
- if_block2.m(div0, text3);
- }
- } else if (if_block2) {
- if_block2.d(1);
- if_block2 = null;
- }
-
- const each1_value = ctx._modulesAppendContainer;
- each1_blocks_1 = updateKeyedEach(each1_blocks_1, component, changed, get_key_1, 1, ctx, each1_value, each1_lookup, div0, destroyBlock, create_each_block, "m", null, get_each1_context);
-
- if ((changed._styles || changed.type || changed.cornerClass || changed.shadow) && div0_class_value !== (div0_class_value = "\n ui-pnotify-container\n " + (ctx._styles.container ? ctx._styles.container : '') + "\n " + (ctx._styles[ctx.type] ? ctx._styles[ctx.type] : '') + "\n " + ctx.cornerClass + "\n " + (ctx.shadow ? 'ui-pnotify-shadow' : '') + "\n ")) {
- div0.className = div0_class_value;
- }
-
- if ((changed._widthStyle || changed._minHeightStyle) && div0_style_value !== (div0_style_value = "" + ctx._widthStyle + " " + ctx._minHeightStyle)) {
- div0.style.cssText = div0_style_value;
- }
-
- if ((changed.icon || changed._styles || changed.addClass || changed._animatingClass || changed._moveClass || changed.animation || changed.animateSpeed || changed.stack || changed._moduleClasses) && div1_class_value !== (div1_class_value = "\n ui-pnotify\n " + (ctx.icon !== false ? 'ui-pnotify-with-icon' : '') + "\n " + (ctx._styles.element ? ctx._styles.element : '') + "\n " + ctx.addClass + "\n " + ctx._animatingClass + "\n " + ctx._moveClass + "\n " + (ctx.animation === 'fade' ? 'ui-pnotify-fade-'+ctx.animateSpeed : '') + "\n " + (ctx.stack && ctx.stack.modal ? 'ui-pnotify-modal' : '') + "\n " + ctx._moduleClasses.join(' ') + "\n ")) {
- div1.className = div1_class_value;
- }
- },
-
- d(detach) {
- if (detach) {
- detachNode(div1);
- }
-
- for (i = 0; i < each0_blocks_1.length; i += 1) each0_blocks_1[i].d();
-
- if (if_block0) if_block0.d();
- if (if_block1) if_block1.d();
- if (if_block2) if_block2.d();
-
- for (i = 0; i < each1_blocks_1.length; i += 1) each1_blocks_1[i].d();
-
- if (component.refs.container === div0) component.refs.container = null;
- removeListener(div1, "mouseover", mouseover_handler);
- removeListener(div1, "mouseout", mouseout_handler);
- removeListener(div1, "mouseenter", mouseenter_handler);
- removeListener(div1, "mouseleave", mouseleave_handler);
- removeListener(div1, "mousemove", mousemove_handler);
- removeListener(div1, "mousedown", mousedown_handler);
- removeListener(div1, "mouseup", mouseup_handler);
- removeListener(div1, "click", click_handler);
- removeListener(div1, "dblclick", dblclick_handler);
- removeListener(div1, "focus", focus_handler);
- removeListener(div1, "blur", blur_handler);
- removeListener(div1, "touchstart", touchstart_handler);
- removeListener(div1, "touchmove", touchmove_handler);
- removeListener(div1, "touchend", touchend_handler);
- removeListener(div1, "touchcancel", touchcancel_handler);
- if (component.refs.elem === div1) component.refs.elem = null;
- }
- };
-}
-
-// (53:4) {#each _modulesPrependContainer as module (module.key)}
-function create_each_block_1(component, key_1, ctx) {
- var first, switch_instance_anchor;
-
- var switch_value = ctx.module;
-
- function switch_props(ctx) {
- return {
- root: component.root,
- store: component.store
- };
- }
-
- if (switch_value) {
- var switch_instance = new switch_value(switch_props(ctx));
- }
-
- function switch_instance_init(event) {
- component.initModule(event.module);
- }
-
- if (switch_instance) switch_instance.on("init", switch_instance_init);
-
- return {
- key: key_1,
-
- first: null,
-
- c() {
- first = createComment();
- if (switch_instance) switch_instance._fragment.c();
- switch_instance_anchor = createComment();
- this.first = first;
- },
-
- m(target, anchor) {
- insert(target, first, anchor);
-
- if (switch_instance) {
- switch_instance._mount(target, anchor);
- }
-
- insert(target, switch_instance_anchor, anchor);
- },
-
- p(changed, ctx) {
- if (switch_value !== (switch_value = ctx.module)) {
- if (switch_instance) {
- switch_instance.destroy();
- }
-
- if (switch_value) {
- switch_instance = new switch_value(switch_props(ctx));
- switch_instance._fragment.c();
- switch_instance._mount(switch_instance_anchor.parentNode, switch_instance_anchor);
-
- switch_instance.on("init", switch_instance_init);
- } else {
- switch_instance = null;
- }
- }
- },
-
- d(detach) {
- if (detach) {
- detachNode(first);
- detachNode(switch_instance_anchor);
- }
-
- if (switch_instance) switch_instance.destroy(detach);
- }
- };
-}
-
-// (56:4) {#if icon !== false}
-function create_if_block_4(component, ctx) {
- var div, span, span_class_value, div_class_value;
-
- return {
- c() {
- div = createElement("div");
- span = createElement("span");
- span.className = span_class_value = ctx.icon === true ? (ctx._icons[ctx.type] ? ctx._icons[ctx.type] : '') : ctx.icon;
- div.className = div_class_value = "ui-pnotify-icon " + (ctx._styles.icon ? ctx._styles.icon : '');
- },
-
- m(target, anchor) {
- insert(target, div, anchor);
- append(div, span);
- component.refs.iconContainer = div;
- },
-
- p(changed, ctx) {
- if ((changed.icon || changed._icons || changed.type) && span_class_value !== (span_class_value = ctx.icon === true ? (ctx._icons[ctx.type] ? ctx._icons[ctx.type] : '') : ctx.icon)) {
- span.className = span_class_value;
- }
-
- if ((changed._styles) && div_class_value !== (div_class_value = "ui-pnotify-icon " + (ctx._styles.icon ? ctx._styles.icon : ''))) {
- div.className = div_class_value;
- }
- },
-
- d(detach) {
- if (detach) {
- detachNode(div);
- }
-
- if (component.refs.iconContainer === div) component.refs.iconContainer = null;
- }
- };
-}
-
-// (61:4) {#if title !== false}
-function create_if_block_2(component, ctx) {
- var h4, h4_class_value;
-
- function select_block_type(ctx) {
- if (ctx.titleTrusted) return create_if_block_3;
- return create_else_block_1;
- }
-
- var current_block_type = select_block_type(ctx);
- var if_block = current_block_type(component, ctx);
-
- return {
- c() {
- h4 = createElement("h4");
- if_block.c();
- h4.className = h4_class_value = "ui-pnotify-title " + (ctx._styles.title ? ctx._styles.title : '');
- },
-
- m(target, anchor) {
- insert(target, h4, anchor);
- if_block.m(h4, null);
- component.refs.titleContainer = h4;
- },
-
- p(changed, ctx) {
- if (current_block_type === (current_block_type = select_block_type(ctx)) && if_block) {
- if_block.p(changed, ctx);
- } else {
- if_block.d(1);
- if_block = current_block_type(component, ctx);
- if_block.c();
- if_block.m(h4, null);
- }
-
- if ((changed._styles) && h4_class_value !== (h4_class_value = "ui-pnotify-title " + (ctx._styles.title ? ctx._styles.title : ''))) {
- h4.className = h4_class_value;
- }
- },
-
- d(detach) {
- if (detach) {
- detachNode(h4);
- }
-
- if_block.d();
- if (component.refs.titleContainer === h4) component.refs.titleContainer = null;
- }
- };
-}
-
-// (65:8) {:else}
-function create_else_block_1(component, ctx) {
- var text;
-
- return {
- c() {
- text = createText(ctx.title);
- },
-
- m(target, anchor) {
- insert(target, text, anchor);
- },
-
- p(changed, ctx) {
- if (changed.title) {
- setData(text, ctx.title);
- }
- },
-
- d(detach) {
- if (detach) {
- detachNode(text);
- }
- }
- };
-}
-
-// (63:8) {#if titleTrusted}
-function create_if_block_3(component, ctx) {
- var raw_before, raw_after;
-
- return {
- c() {
- raw_before = createElement('noscript');
- raw_after = createElement('noscript');
- },
-
- m(target, anchor) {
- insert(target, raw_before, anchor);
- raw_before.insertAdjacentHTML("afterend", ctx.title);
- insert(target, raw_after, anchor);
- },
-
- p(changed, ctx) {
- if (changed.title) {
- detachBetween(raw_before, raw_after);
- raw_before.insertAdjacentHTML("afterend", ctx.title);
- }
- },
-
- d(detach) {
- if (detach) {
- detachBetween(raw_before, raw_after);
- detachNode(raw_before);
- detachNode(raw_after);
- }
- }
- };
-}
-
-// (70:4) {#if text !== false}
-function create_if_block(component, ctx) {
- var div, div_class_value;
-
- function select_block_type_1(ctx) {
- if (ctx.textTrusted) return create_if_block_1;
- return create_else_block;
- }
-
- var current_block_type = select_block_type_1(ctx);
- var if_block = current_block_type(component, ctx);
-
- return {
- c() {
- div = createElement("div");
- if_block.c();
- div.className = div_class_value = "ui-pnotify-text " + (ctx._styles.text ? ctx._styles.text : '');
- setAttribute(div, "role", "alert");
- },
-
- m(target, anchor) {
- insert(target, div, anchor);
- if_block.m(div, null);
- component.refs.textContainer = div;
- },
-
- p(changed, ctx) {
- if (current_block_type === (current_block_type = select_block_type_1(ctx)) && if_block) {
- if_block.p(changed, ctx);
- } else {
- if_block.d(1);
- if_block = current_block_type(component, ctx);
- if_block.c();
- if_block.m(div, null);
- }
-
- if ((changed._styles) && div_class_value !== (div_class_value = "ui-pnotify-text " + (ctx._styles.text ? ctx._styles.text : ''))) {
- div.className = div_class_value;
- }
- },
-
- d(detach) {
- if (detach) {
- detachNode(div);
- }
-
- if_block.d();
- if (component.refs.textContainer === div) component.refs.textContainer = null;
- }
- };
-}
-
-// (74:8) {:else}
-function create_else_block(component, ctx) {
- var text;
-
- return {
- c() {
- text = createText(ctx.text);
- },
-
- m(target, anchor) {
- insert(target, text, anchor);
- },
-
- p(changed, ctx) {
- if (changed.text) {
- setData(text, ctx.text);
- }
- },
-
- d(detach) {
- if (detach) {
- detachNode(text);
- }
- }
- };
-}
-
-// (72:8) {#if textTrusted}
-function create_if_block_1(component, ctx) {
- var raw_before, raw_after;
-
- return {
- c() {
- raw_before = createElement('noscript');
- raw_after = createElement('noscript');
- },
-
- m(target, anchor) {
- insert(target, raw_before, anchor);
- raw_before.insertAdjacentHTML("afterend", ctx.text);
- insert(target, raw_after, anchor);
- },
-
- p(changed, ctx) {
- if (changed.text) {
- detachBetween(raw_before, raw_after);
- raw_before.insertAdjacentHTML("afterend", ctx.text);
- }
- },
-
- d(detach) {
- if (detach) {
- detachBetween(raw_before, raw_after);
- detachNode(raw_before);
- detachNode(raw_after);
- }
- }
- };
-}
-
-// (79:4) {#each _modulesAppendContainer as module (module.key)}
-function create_each_block(component, key_1, ctx) {
- var first, switch_instance_anchor;
-
- var switch_value = ctx.module;
-
- function switch_props(ctx) {
- return {
- root: component.root,
- store: component.store
- };
- }
-
- if (switch_value) {
- var switch_instance = new switch_value(switch_props(ctx));
- }
-
- function switch_instance_init(event) {
- component.initModule(event.module);
- }
-
- if (switch_instance) switch_instance.on("init", switch_instance_init);
-
- return {
- key: key_1,
-
- first: null,
-
- c() {
- first = createComment();
- if (switch_instance) switch_instance._fragment.c();
- switch_instance_anchor = createComment();
- this.first = first;
- },
-
- m(target, anchor) {
- insert(target, first, anchor);
-
- if (switch_instance) {
- switch_instance._mount(target, anchor);
- }
-
- insert(target, switch_instance_anchor, anchor);
- },
-
- p(changed, ctx) {
- if (switch_value !== (switch_value = ctx.module)) {
- if (switch_instance) {
- switch_instance.destroy();
- }
-
- if (switch_value) {
- switch_instance = new switch_value(switch_props(ctx));
- switch_instance._fragment.c();
- switch_instance._mount(switch_instance_anchor.parentNode, switch_instance_anchor);
-
- switch_instance.on("init", switch_instance_init);
- } else {
- switch_instance = null;
- }
- }
- },
-
- d(detach) {
- if (detach) {
- detachNode(first);
- detachNode(switch_instance_anchor);
- }
-
- if (switch_instance) switch_instance.destroy(detach);
- }
- };
-}
-
-function PNotify_1(options) {
- init(this, options);
- this.refs = {};
- this._state = assign(data(), options.data);
-
- this._recompute({ styling: 1, icons: 1, width: 1, minHeight: 1 }, this._state);
- this._intro = true;
-
- if (!document.getElementById("svelte-1eldsjg-style")) add_css();
-
- this._fragment = create_main_fragment(this, this._state);
-
- this.root._oncreate.push(() => {
- oncreate.call(this);
- this.fire("update", { changed: assignTrue({}, this._state), current: this._state });
- });
-
- if (options.target) {
- this._fragment.c();
- this._mount(options.target, options.anchor);
-
- flush(this);
- }
-}
-
-assign(PNotify_1.prototype, {
- destroy: destroy,
- get: get,
- fire: fire,
- on: on,
- set: set,
- _set: _set,
- _stage: _stage,
- _mount: _mount,
- _differs: _differs
- });
-assign(PNotify_1.prototype, methods);
-
-PNotify_1.prototype._recompute = function _recompute(changed, state) {
- if (changed.styling) {
- if (this._differs(state._styles, (state._styles = _styles(state)))) changed._styles = true;
- }
-
- if (changed.icons) {
- if (this._differs(state._icons, (state._icons = _icons(state)))) changed._icons = true;
- }
-
- if (changed.width) {
- if (this._differs(state._widthStyle, (state._widthStyle = _widthStyle(state)))) changed._widthStyle = true;
- }
-
- if (changed.minHeight) {
- if (this._differs(state._minHeightStyle, (state._minHeightStyle = _minHeightStyle(state)))) changed._minHeightStyle = true;
- }
-}
-
-setup(PNotify_1);
-
-function createElement(name) {
- return document.createElement(name);
-}
-
-function append(target, node) {
- target.appendChild(node);
-}
-
-function blankObject() {
- return Object.create(null);
-}
-
-function createText(data) {
- return document.createTextNode(data);
-}
-
-function setAttribute(node, attribute, value) {
- if (value == null) node.removeAttribute(attribute);
- else node.setAttribute(attribute, value);
-}
-
-function addListener(node, event, handler, options) {
- node.addEventListener(event, handler, options);
-}
-
-function insert(target, node, anchor) {
- target.insertBefore(node, anchor);
-}
-
-function updateKeyedEach(old_blocks, component, changed, get_key, dynamic, ctx, list, lookup, node, destroy, create_each_block, intro_method, next, get_context) {
- var o = old_blocks.length;
- var n = list.length;
-
- var i = o;
- var old_indexes = {};
- while (i--) old_indexes[old_blocks[i].key] = i;
-
- var new_blocks = [];
- var new_lookup = {};
- var deltas = {};
-
- var i = n;
- while (i--) {
- var child_ctx = get_context(ctx, list, i);
- var key = get_key(child_ctx);
- var block = lookup[key];
-
- if (!block) {
- block = create_each_block(component, key, child_ctx);
- block.c();
- } else if (dynamic) {
- block.p(changed, child_ctx);
- }
-
- new_blocks[i] = new_lookup[key] = block;
-
- if (key in old_indexes) deltas[key] = Math.abs(i - old_indexes[key]);
- }
-
- var will_move = {};
- var did_move = {};
-
- function insert(block) {
- block[intro_method](node, next);
- lookup[block.key] = block;
- next = block.first;
- n--;
- }
-
- while (o && n) {
- var new_block = new_blocks[n - 1];
- var old_block = old_blocks[o - 1];
- var new_key = new_block.key;
- var old_key = old_block.key;
-
- if (new_block === old_block) {
- // do nothing
- next = new_block.first;
- o--;
- n--;
- }
-
- else if (!new_lookup[old_key]) {
- // remove old block
- destroy(old_block, lookup);
- o--;
- }
-
- else if (!lookup[new_key] || will_move[new_key]) {
- insert(new_block);
- }
-
- else if (did_move[old_key]) {
- o--;
-
- } else if (deltas[new_key] > deltas[old_key]) {
- did_move[new_key] = true;
- insert(new_block);
-
- } else {
- will_move[old_key] = true;
- o--;
- }
- }
-
- while (o--) {
- var old_block = old_blocks[o];
- if (!new_lookup[old_block.key]) destroy(old_block, lookup);
- }
-
- while (n) insert(new_blocks[n - 1]);
-
- return new_blocks;
-}
-
-function destroyBlock(block, lookup) {
- block.d(1);
- lookup[block.key] = null;
-}
-
-function detachNode(node) {
- node.parentNode.removeChild(node);
-}
-
-function removeListener(node, event, handler, options) {
- node.removeEventListener(event, handler, options);
-}
-
-function createComment() {
- return document.createComment('');
-}
-
-function setData(text, data) {
- text.data = '' + data;
-}
-
-function detachBetween(before, after) {
- while (before.nextSibling && before.nextSibling !== after) {
- before.parentNode.removeChild(before.nextSibling);
- }
-}
-
-function init(component, options) {
- component._handlers = blankObject();
- component._slots = blankObject();
- component._bind = options._bind;
- component._staged = {};
-
- component.options = options;
- component.root = options.root || component;
- component.store = options.store || component.root.store;
-
- if (!options.root) {
- component._beforecreate = [];
- component._oncreate = [];
- component._aftercreate = [];
- }
-}
-
-function assign(tar, src) {
- for (var k in src) tar[k] = src[k];
- return tar;
-}
-
-function assignTrue(tar, src) {
- for (var k in src) tar[k] = 1;
- return tar;
-}
-
-function flush(component) {
- component._lock = true;
- callAll(component._beforecreate);
- callAll(component._oncreate);
- callAll(component._aftercreate);
- component._lock = false;
-}
-
-function destroy(detach) {
- this.destroy = noop;
- this.fire('destroy');
- this.set = noop;
-
- this._fragment.d(detach !== false);
- this._fragment = null;
- this._state = {};
-}
-
-function get() {
- return this._state;
-}
-
-function fire(eventName, data) {
- var handlers =
- eventName in this._handlers && this._handlers[eventName].slice();
- if (!handlers) return;
-
- for (var i = 0; i < handlers.length; i += 1) {
- var handler = handlers[i];
-
- if (!handler.__calling) {
- try {
- handler.__calling = true;
- handler.call(this, data);
- } finally {
- handler.__calling = false;
- }
- }
- }
-}
-
-function on(eventName, handler) {
- var handlers = this._handlers[eventName] || (this._handlers[eventName] = []);
- handlers.push(handler);
-
- return {
- cancel: function() {
- var index = handlers.indexOf(handler);
- if (~index) handlers.splice(index, 1);
- }
- };
-}
-
-function set(newState) {
- this._set(assign({}, newState));
- if (this.root._lock) return;
- flush(this.root);
-}
-
-function _set(newState) {
- var oldState = this._state,
- changed = {},
- dirty = false;
-
- newState = assign(this._staged, newState);
- this._staged = {};
-
- for (var key in newState) {
- if (this._differs(newState[key], oldState[key])) changed[key] = dirty = true;
- }
- if (!dirty) return;
-
- this._state = assign(assign({}, oldState), newState);
- this._recompute(changed, this._state);
- if (this._bind) this._bind(changed, this._state);
-
- if (this._fragment) {
- this.fire("state", { changed: changed, current: this._state, previous: oldState });
- this._fragment.p(changed, this._state);
- this.fire("update", { changed: changed, current: this._state, previous: oldState });
- }
-}
-
-function _stage(newState) {
- assign(this._staged, newState);
-}
-
-function _mount(target, anchor) {
- this._fragment[this._fragment.i ? 'i' : 'm'](target, anchor || null);
-}
-
-function _differs(a, b) {
- return a != a ? b == b : a !== b || ((a && typeof a === 'object') || typeof a === 'function');
-}
-
-function callAll(fns) {
- while (fns && fns.length) fns.shift()();
-}
-
-function noop() {}
-export default PNotify_1;
\ No newline at end of file
diff --git a/node_modules/pnotify/lib/es/PNotify.js.map b/node_modules/pnotify/lib/es/PNotify.js.map
deleted file mode 100644
index eef5dbb..0000000
--- a/node_modules/pnotify/lib/es/PNotify.js.map
+++ /dev/null
@@ -1 +0,0 @@
-{"version":3,"file":"PNotify.js","sources":["src/PNotify.html"],"sourcesContent":["\n\n