{"version":3,"sources":["webpack:///./node_modules/vex-js/dist/js/vex.js"],"names":["require","module","exports","e","t","n","r","s","o","u","a","i","f","Error","code","l","call","length","1","window","self","document","createElement","createElementNS","view","elemCtrProto","Element","objCtr","Object","strTrim","String","trim","this","replace","arrIndexOf","Array","indexOf","item","len","DOMEx","type","message","name","DOMException","checkTokenAndGetIndex","classList","token","test","ClassList","elem","trimmedClasses","getAttribute","classes","split","push","_updateClassName","setAttribute","toString","classListProto","classListGetter","contains","add","tokens","arguments","updated","remove","index","splice","toggle","force","result","method","join","defineProperty","classListPropDesc","get","enumerable","configurable","ex","undefined","number","__defineGetter__","testElement","createMethod","original","DOMTokenList","prototype","_toggle","2","html","doc","TypeError","m","exec","createTextNode","tag","el","innerHTML","removeChild","lastChild","wrap","map","_default","depth","prefix","suffix","firstChild","fragment","createDocumentFragment","appendChild","bugTestDiv","innerHTMLBug","getElementsByTagName","legend","tr","col","td","th","option","optgroup","thead","tbody","colgroup","caption","tfoot","polyline","ellipse","polygon","circle","text","line","path","rect","g","3","assign","target","firstSource","to","nextSource","keysArray","keys","nextIndex","nextKey","desc","getOwnPropertyDescriptor","polyfill","writable","value","4","domify","escapeHtml","str","div","addClasses","classStr","className","animationEndEvent","eventNames","animation","WebkitAnimation","MozAnimation","OAnimation","msAnimation","style","baseClassNames","vex","content","overlay","close","closing","open","vexes","globalId","isEscapeActive","opts","warnDeprecated","prop","console","warn","css","overlayCSS","contentCSS","closeCSS","vexInstance","id","isOpen","options","escapeButtonCloses","shouldClose","beforeClose","bind","getComputedStyle","contentEl","hasAnimationPre","getPropertyValue","hasAnimation","rootEl","parentNode","removeEventListener","overlayEl","bodyEl","afterClose","body","addEventListener","unsafeContent","defaultOptions","overlayClassName","overlayClosesOnClick","contentClassName","Node","showCloseButton","closeEl","closeClassName","querySelector","appendLocation","afterOpen","vexOrId","closeTop","ids","closeAll","getAll","getById","keyCode","closeAllOnPopState","registerPlugin","pluginFn","plugin","pluginName","classlist-polyfill","es6-object-assign"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EAAAzL,KACA,GAAA4H,EAAA8D,GACA,UAAAvN,MAAA,UAAA6B,EAAA,2BAEA4H,EAAA8D,GAAAD,GAGAlO,EAAAC,QAAAoK,IAEG+D,qBAAA,EAAA/E,OAAA,EAAAgF,oBAAA,SAA6D,GA/uBoS,CA+uBpS","file":"vex.chunks.js","sourcesContent":["(function(f){if(typeof exports===\"object\"&&typeof module!==\"undefined\"){module.exports=f()}else if(typeof define===\"function\"&&define.amd){define([],f)}else{var g;if(typeof window!==\"undefined\"){g=window}else if(typeof global!==\"undefined\"){g=global}else if(typeof self!==\"undefined\"){g=self}else{g=this}g.vex = f()}})(function(){var define,module,exports;return (function(){function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require==\"function\"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error(\"Cannot find module '\"+o+\"'\");throw f.code=\"MODULE_NOT_FOUND\",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require==\"function\"&&require;for(var o=0;o', ''],\n tr: [2, '', '
'],\n col: [2, '', '
'],\n // for script/link/style tags to work in IE6-8, you have to wrap\n // in a div with a non-whitespace character in front, ha!\n _default: innerHTMLBug ? [1, 'X
', '
'] : [0, '', '']\n};\n\nmap.td =\nmap.th = [3, '', '
'];\n\nmap.option =\nmap.optgroup = [1, ''];\n\nmap.thead =\nmap.tbody =\nmap.colgroup =\nmap.caption =\nmap.tfoot = [1, '', '
'];\n\nmap.polyline =\nmap.ellipse =\nmap.polygon =\nmap.circle =\nmap.text =\nmap.line =\nmap.path =\nmap.rect =\nmap.g = [1, '',''];\n\n/**\n * Parse `html` and return a DOM Node instance, which could be a TextNode,\n * HTML DOM Node of some kind (
for example), or a DocumentFragment\n * instance, depending on the contents of the `html` string.\n *\n * @param {String} html - HTML string to \"domify\"\n * @param {Document} doc - The `document` instance to create the Node for\n * @return {DOMNode} the TextNode, DOM Node, or DocumentFragment instance\n * @api private\n */\n\nfunction parse(html, doc) {\n if ('string' != typeof html) throw new TypeError('String expected');\n\n // default to the global `document` object\n if (!doc) doc = document;\n\n // tag name\n var m = /<([\\w:]+)/.exec(html);\n if (!m) return doc.createTextNode(html);\n\n html = html.replace(/^\\s+|\\s+$/g, ''); // Remove leading/trailing whitespace\n\n var tag = m[1];\n\n // body support\n if (tag == 'body') {\n var el = doc.createElement('html');\n el.innerHTML = html;\n return el.removeChild(el.lastChild);\n }\n\n // wrap map\n var wrap = map[tag] || map._default;\n var depth = wrap[0];\n var prefix = wrap[1];\n var suffix = wrap[2];\n var el = doc.createElement('div');\n el.innerHTML = prefix + html + suffix;\n while (depth--) el = el.lastChild;\n\n // one element\n if (el.firstChild == el.lastChild) {\n return el.removeChild(el.firstChild);\n }\n\n // several elements\n var fragment = doc.createDocumentFragment();\n while (el.firstChild) {\n fragment.appendChild(el.removeChild(el.firstChild));\n }\n\n return fragment;\n}\n\n},{}],3:[function(require,module,exports){\n/**\n * Code refactored from Mozilla Developer Network:\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/assign\n */\n\n'use strict';\n\nfunction assign(target, firstSource) {\n if (target === undefined || target === null) {\n throw new TypeError('Cannot convert first argument to object');\n }\n\n var to = Object(target);\n for (var i = 1; i < arguments.length; i++) {\n var nextSource = arguments[i];\n if (nextSource === undefined || nextSource === null) {\n continue;\n }\n\n var keysArray = Object.keys(Object(nextSource));\n for (var nextIndex = 0, len = keysArray.length; nextIndex < len; nextIndex++) {\n var nextKey = keysArray[nextIndex];\n var desc = Object.getOwnPropertyDescriptor(nextSource, nextKey);\n if (desc !== undefined && desc.enumerable) {\n to[nextKey] = nextSource[nextKey];\n }\n }\n }\n return to;\n}\n\nfunction polyfill() {\n if (!Object.assign) {\n Object.defineProperty(Object, 'assign', {\n enumerable: false,\n configurable: true,\n writable: true,\n value: assign\n });\n }\n}\n\nmodule.exports = {\n assign: assign,\n polyfill: polyfill\n};\n\n},{}],4:[function(require,module,exports){\n// classList polyfill for old browsers\r\nrequire('classlist-polyfill')\r\n// Object.assign polyfill\r\nrequire('es6-object-assign').polyfill()\r\n\r\n// String to DOM function\r\nvar domify = require('domify')\r\n\r\n// Use the DOM's HTML parsing to escape any dangerous strings\r\nvar escapeHtml = function escapeHtml (str) {\r\n if (typeof str !== 'undefined') {\r\n var div = document.createElement('div')\r\n div.appendChild(document.createTextNode(str))\r\n return div.innerHTML\r\n } else {\r\n return ''\r\n }\r\n}\r\n\r\n// Utility function to add space-delimited class strings to a DOM element's classList\r\nvar addClasses = function addClasses (el, classStr) {\r\n if (typeof classStr !== 'string' || classStr.length === 0) {\r\n return\r\n }\r\n var classes = classStr.split(' ')\r\n for (var i = 0; i < classes.length; i++) {\r\n var className = classes[i]\r\n if (className.length) {\r\n el.classList.add(className)\r\n }\r\n }\r\n}\r\n\r\n// Detect CSS Animation End Support\r\n// https://github.com/limonte/sweetalert2/blob/99bd539f85e15ac170f69d35001d12e092ef0054/src/utils/dom.js#L194\r\nvar animationEndEvent = (function detectAnimationEndEvent () {\r\n var el = document.createElement('div')\r\n var eventNames = {\r\n 'animation': 'animationend',\r\n 'WebkitAnimation': 'webkitAnimationEnd',\r\n 'MozAnimation': 'animationend',\r\n 'OAnimation': 'oanimationend',\r\n 'msAnimation': 'MSAnimationEnd'\r\n }\r\n for (var i in eventNames) {\r\n if (el.style[i] !== undefined) {\r\n return eventNames[i]\r\n }\r\n }\r\n return false\r\n})()\r\n\r\n// vex base CSS classes\r\nvar baseClassNames = {\r\n vex: 'vex',\r\n content: 'vex-content',\r\n overlay: 'vex-overlay',\r\n close: 'vex-close',\r\n closing: 'vex-closing',\r\n open: 'vex-open'\r\n}\r\n\r\n// Private lookup table of all open vex objects, keyed by id\r\nvar vexes = {}\r\nvar globalId = 1\r\n\r\n// Private boolean to assist the escapeButtonCloses option\r\nvar isEscapeActive = false\r\n\r\n// vex itself is an object that exposes a simple API to open and close vex objects in various ways\r\nvar vex = {\r\n open: function open (opts) {\r\n // Check for usage of deprecated options, and log a warning\r\n var warnDeprecated = function warnDeprecated (prop) {\r\n console.warn('The \"' + prop + '\" property is deprecated in vex 3. Use CSS classes and the appropriate \"ClassName\" options, instead.')\r\n console.warn('See http://github.hubspot.com/vex/api/advanced/#options')\r\n }\r\n if (opts.css) {\r\n warnDeprecated('css')\r\n }\r\n if (opts.overlayCSS) {\r\n warnDeprecated('overlayCSS')\r\n }\r\n if (opts.contentCSS) {\r\n warnDeprecated('contentCSS')\r\n }\r\n if (opts.closeCSS) {\r\n warnDeprecated('closeCSS')\r\n }\r\n\r\n // The dialog instance\r\n var vexInstance = {}\r\n\r\n // Set id\r\n vexInstance.id = globalId++\r\n\r\n // Store internally\r\n vexes[vexInstance.id] = vexInstance\r\n\r\n // Set state\r\n vexInstance.isOpen = true\r\n\r\n // Close function on the vex instance\r\n // This is how all API functions should close individual vexes\r\n vexInstance.close = function instanceClose () {\r\n // Check state\r\n if (!this.isOpen) {\r\n return true\r\n }\r\n\r\n var options = this.options\r\n\r\n // escapeButtonCloses is checked first\r\n if (isEscapeActive && !options.escapeButtonCloses) {\r\n return false\r\n }\r\n\r\n // Allow the user to validate any info or abort the close with the beforeClose callback\r\n var shouldClose = (function shouldClose () {\r\n // Call before close callback\r\n if (options.beforeClose) {\r\n return options.beforeClose.call(this)\r\n }\r\n // Otherwise indicate that it's ok to continue with close\r\n return true\r\n }.bind(this)())\r\n\r\n // If beforeClose() fails, abort the close\r\n if (shouldClose === false) {\r\n return false\r\n }\r\n\r\n // Update state\r\n this.isOpen = false\r\n\r\n // Detect if the content el has any CSS animations defined\r\n var style = window.getComputedStyle(this.contentEl)\r\n function hasAnimationPre (prefix) {\r\n return style.getPropertyValue(prefix + 'animation-name') !== 'none' && style.getPropertyValue(prefix + 'animation-duration') !== '0s'\r\n }\r\n var hasAnimation = hasAnimationPre('') || hasAnimationPre('-webkit-') || hasAnimationPre('-moz-') || hasAnimationPre('-o-')\r\n\r\n // Define the function that will actually close the instance\r\n var close = function close () {\r\n if (!this.rootEl.parentNode) {\r\n return\r\n }\r\n // Run once\r\n this.rootEl.removeEventListener(animationEndEvent, close)\r\n this.overlayEl.removeEventListener(animationEndEvent, close)\r\n // Remove from lookup table (prevent memory leaks)\r\n delete vexes[this.id]\r\n // Remove the dialog from the DOM\r\n this.rootEl.parentNode.removeChild(this.rootEl)\r\n // Remove the overlay from the DOM\r\n this.bodyEl.removeChild(this.overlayEl)\r\n // Call after close callback\r\n if (options.afterClose) {\r\n options.afterClose.call(this)\r\n }\r\n // Remove styling from the body, if no more vexes are open\r\n if (Object.keys(vexes).length === 0) {\r\n document.body.classList.remove(baseClassNames.open)\r\n }\r\n }.bind(this)\r\n\r\n // Close the vex\r\n if (animationEndEvent && hasAnimation) {\r\n // Setup the end event listener, to remove the el from the DOM\r\n this.rootEl.addEventListener(animationEndEvent, close)\r\n this.overlayEl.addEventListener(animationEndEvent, close)\r\n // Add the closing class to the dialog, showing the close animation\r\n this.rootEl.classList.add(baseClassNames.closing)\r\n this.overlayEl.classList.add(baseClassNames.closing)\r\n } else {\r\n close()\r\n }\r\n\r\n return true\r\n }\r\n\r\n // Allow strings as content\r\n if (typeof opts === 'string') {\r\n opts = {\r\n content: opts\r\n }\r\n }\r\n\r\n // `content` is unsafe internally, so translate\r\n // safe default: HTML-escape the content before passing it through\r\n if (opts.unsafeContent && !opts.content) {\r\n opts.content = opts.unsafeContent\r\n } else if (opts.content) {\r\n opts.content = escapeHtml(opts.content)\r\n }\r\n\r\n // Store options on instance for future reference\r\n var options = vexInstance.options = Object.assign({}, vex.defaultOptions, opts)\r\n\r\n // Get Body Element\r\n var bodyEl = vexInstance.bodyEl = document.getElementsByTagName('body')[0]\r\n\r\n // vex root\r\n var rootEl = vexInstance.rootEl = document.createElement('div')\r\n rootEl.classList.add(baseClassNames.vex)\r\n addClasses(rootEl, options.className)\r\n\r\n // Overlay\r\n var overlayEl = vexInstance.overlayEl = document.createElement('div')\r\n overlayEl.classList.add(baseClassNames.overlay)\r\n addClasses(overlayEl, options.overlayClassName)\r\n if (options.overlayClosesOnClick) {\r\n rootEl.addEventListener('click', function overlayClickListener (e) {\r\n if (e.target === rootEl) {\r\n vexInstance.close()\r\n }\r\n })\r\n }\r\n bodyEl.appendChild(overlayEl)\r\n\r\n // Content\r\n var contentEl = vexInstance.contentEl = document.createElement('div')\r\n contentEl.classList.add(baseClassNames.content)\r\n addClasses(contentEl, options.contentClassName)\r\n contentEl.appendChild(options.content instanceof window.Node ? options.content : domify(options.content))\r\n rootEl.appendChild(contentEl)\r\n\r\n // Close button\r\n if (options.showCloseButton) {\r\n var closeEl = vexInstance.closeEl = document.createElement('div')\r\n closeEl.classList.add(baseClassNames.close)\r\n addClasses(closeEl, options.closeClassName)\r\n closeEl.addEventListener('click', vexInstance.close.bind(vexInstance))\r\n contentEl.appendChild(closeEl)\r\n }\r\n\r\n // Add to DOM\r\n document.querySelector(options.appendLocation).appendChild(rootEl)\r\n\r\n // Call after open callback\r\n if (options.afterOpen) {\r\n options.afterOpen.call(vexInstance)\r\n }\r\n\r\n // Apply styling to the body\r\n document.body.classList.add(baseClassNames.open)\r\n\r\n // Return the created vex instance\r\n return vexInstance\r\n },\r\n\r\n // A top-level vex.close function to close dialogs by reference or id\r\n close: function close (vexOrId) {\r\n var id\r\n if (vexOrId.id) {\r\n id = vexOrId.id\r\n } else if (typeof vexOrId === 'string') {\r\n id = vexOrId\r\n } else {\r\n throw new TypeError('close requires a vex object or id string')\r\n }\r\n if (!vexes[id]) {\r\n return false\r\n }\r\n return vexes[id].close()\r\n },\r\n\r\n // Close the most recently created/opened vex\r\n closeTop: function closeTop () {\r\n var ids = Object.keys(vexes)\r\n if (!ids.length) {\r\n return false\r\n }\r\n return vexes[ids[ids.length - 1]].close()\r\n },\r\n\r\n // Close every vex!\r\n closeAll: function closeAll () {\r\n for (var id in vexes) {\r\n this.close(id)\r\n }\r\n return true\r\n },\r\n\r\n // A getter for the internal lookup table\r\n getAll: function getAll () {\r\n return vexes\r\n },\r\n\r\n // A getter for the internal lookup table\r\n getById: function getById (id) {\r\n return vexes[id]\r\n }\r\n}\r\n\r\n// Close top vex on escape\r\nwindow.addEventListener('keyup', function vexKeyupListener (e) {\r\n if (e.keyCode === 27) {\r\n isEscapeActive = true\r\n vex.closeTop()\r\n isEscapeActive = false\r\n }\r\n})\r\n\r\n// Close all vexes on history pop state (useful in single page apps)\r\nwindow.addEventListener('popstate', function () {\r\n if (vex.defaultOptions.closeAllOnPopState) {\r\n vex.closeAll()\r\n }\r\n})\r\n\r\nvex.defaultOptions = {\r\n content: '',\r\n showCloseButton: true,\r\n escapeButtonCloses: true,\r\n overlayClosesOnClick: true,\r\n appendLocation: 'body',\r\n className: '',\r\n overlayClassName: '',\r\n contentClassName: '',\r\n closeClassName: '',\r\n closeAllOnPopState: true\r\n}\r\n\r\n// TODO Loading symbols?\r\n\r\n// Include escapeHtml function on the library object\r\nObject.defineProperty(vex, '_escapeHtml', {\r\n configurable: false,\r\n enumerable: false,\r\n writable: false,\r\n value: escapeHtml\r\n})\r\n\r\n// Plugin system!\r\nvex.registerPlugin = function registerPlugin (pluginFn, name) {\r\n var plugin = pluginFn(vex)\r\n var pluginName = name || plugin.name\r\n if (vex[pluginName]) {\r\n throw new Error('Plugin ' + name + ' is already registered.')\r\n }\r\n vex[pluginName] = plugin\r\n}\r\n\r\nmodule.exports = vex\r\n\n},{\"classlist-polyfill\":1,\"domify\":2,\"es6-object-assign\":3}]},{},[4])(4)\n});"],"sourceRoot":""}