{"version":3,"sources":["webpack:///./node_modules/vex-dialog/dist/vex.dialog.js","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","deepcopy","value","Object","prototype","toString","Date","getTime","Array","isArray","map","result","keys","forEach","key","2","html","doc","TypeError","document","m","exec","createTextNode","replace","tag","el","createElement","innerHTML","removeChild","lastChild","wrap","_default","depth","prefix","suffix","firstChild","fragment","createDocumentFragment","appendChild","bugTestDiv","innerHTMLBug","getElementsByTagName","undefined","legend","tr","col","td","th","option","optgroup","thead","tbody","colgroup","caption","tfoot","polyline","ellipse","polygon","circle","text","line","path","rect","g","3","k_r_submitter","k_r_success_contrls","brackets","hash_serializer","matches","match","string","children","RegExp","push","parse_keys","hash_assign","shift","between","_values","index","isNaN","existing","str_serialize","encodeURIComponent","form","options","hash","serializer","elements","radio_store","create","element","disabled","name","test","nodeName","type","val","checked","empty","selectOptions","isSelectedOptions","j","allowedEmpty","hasValue","selected","slice","4","domify","serialize","cloneDeep","vex","dialog","open","opts","assign","this","defaultOptions","unsafeMessage","message","_escapeHtml","unsafeContent","classList","add","window","Node","input","buildDialogForm","dialogInstance","yesText","buttons","noText","beforeClose","bind","shouldClose","callback","domButtons","button","domButton","textContent","className","addEventListener","click","onSubmit","focusFirstInput","contentEl","querySelector","focus","alert","defaultAlertOptions","confirm","defaultConfirmOptions","prompt","defaults","defaultPromptOptions","dynamicDefaults","label","placeholder","YES","NO","close","afterOpen","showCloseButton","preventDefault","deep-clone-simple","form-serialize","self","createElementNS","view","elemCtrProto","Element","objCtr","strTrim","String","trim","arrIndexOf","indexOf","item","len","DOMEx","DOMException","checkTokenAndGetIndex","token","ClassList","elem","trimmedClasses","getAttribute","classes","split","_updateClassName","setAttribute","classListProto","classListGetter","contains","tokens","arguments","updated","remove","splice","toggle","force","method","join","defineProperty","classListPropDesc","get","enumerable","configurable","ex","number","__defineGetter__","testElement","createMethod","original","DOMTokenList","_toggle","target","firstSource","to","nextSource","keysArray","nextIndex","nextKey","desc","getOwnPropertyDescriptor","polyfill","writable","escapeHtml","str","div","addClasses","classStr","animationEndEvent","eventNames","animation","WebkitAnimation","MozAnimation","OAnimation","msAnimation","style","baseClassNames","content","overlay","closing","vexes","globalId","isEscapeActive","warnDeprecated","prop","console","warn","css","overlayCSS","contentCSS","closeCSS","vexInstance","id","isOpen","escapeButtonCloses","getComputedStyle","hasAnimationPre","getPropertyValue","hasAnimation","rootEl","parentNode","removeEventListener","overlayEl","bodyEl","afterClose","body","overlayClassName","overlayClosesOnClick","contentClassName","closeEl","closeClassName","appendLocation","vexOrId","closeTop","ids","closeAll","getAll","getById","keyCode","closeAllOnPopState","registerPlugin","pluginFn","plugin","pluginName","classlist-polyfill","es6-object-assign"],"mappings":"mFAAA,IAAAA,EAAwEC,EAAAC,QAAqT,SAAAC,EAAAC,EAAAC,EAAAC,GAAkB,SAAAC,EAAAC,EAAAC,GAAgB,IAAAJ,EAAAG,GAAA,CAAU,IAAAJ,EAAAI,GAAA,CAAU,IAAAE,EAAA,mBAAAV,KAA0C,IAAAS,GAAAC,EAAA,OAAgBV,EAACQ,GAAA,GAAO,GAAAG,EAAA,OAAAA,EAAAH,GAAA,GAAoB,IAAAI,EAAA,IAAAC,MAAA,uBAAAL,EAAA,KAA8C,MAAAI,EAAAE,KAAA,mBAAAF,EAAkC,IAAAG,EAAAV,EAAAG,IAAYN,YAAYE,EAAAI,GAAA,GAAAQ,KAAAD,EAAAb,QAAA,SAAAC,GAAmC,IAAAE,EAAAD,EAAAI,GAAA,GAAAL,GAAiB,OAAAI,EAAAF,GAAAF,IAAgBY,IAAAb,QAAAC,EAAAC,EAAAC,EAAAC,GAAsB,OAAAD,EAAAG,GAAAN,QAA8D,IAA1C,IAAAS,EAAA,mBAAAX,KAA0CQ,EAAA,EAAYA,EAAAF,EAAAW,OAAWT,IAAAD,EAAAD,EAAAE,IAAY,OAAAD,EAAlc,EAAydW,GAAA,SAAAlB,EAAAC,EAA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AAAoB,EAAApB,OACK,qBAAAoB,EAGL,UAAAnQ,UAAA,4CAFA+O,EAAAoB,EAIA,QAAAhC,EAAAY,IAGAZ,EAAAY,GAAAhG,SAIAqH,SAAA,WACA,IAAAC,EAAApR,OAAAS,KAAAyO,GACA,QAAAkC,EAAAxR,QAGAsP,EAAAkC,IAAAxR,OAAA,IAAAkK,SAIAuH,SAAA,WACA,QAAAvB,KAAAZ,EACAhI,KAAA4C,MAAAgG,GAEA,UAIAwB,OAAA,WACA,OAAApC,GAIAqC,QAAA,SAAAzB,GACA,OAAAZ,EAAAY,KAKApI,OAAAiB,iBAAA,iBAAA7J,GACA,KAAAA,EAAA0S,UACApC,GAAA,EACAvI,EAAAsK,WACA/B,GAAA,KAKA1H,OAAAiB,iBAAA,sBACA9B,EAAAM,eAAAsK,oBACA5K,EAAAwK,aAIAxK,EAAAM,gBACA4H,QAAA,GACA/E,iBAAA,EACAgG,oBAAA,EACAa,sBAAA,EACAI,eAAA,OACAvI,UAAA,GACAkI,iBAAA,GACAE,iBAAA,GACAE,eAAA,GACAS,oBAAA,GAMAzR,OAAAyM,eAAA5F,EAAA,eACAgG,cAAA,EACAD,YAAA,EACAoB,UAAA,EACAjO,MAAAkO,IAIApH,EAAA6K,eAAA,SAAAC,EAAAhM,GACA,IAAAiM,EAAAD,EAAA9K,GACAgL,EAAAlM,GAAAiM,EAAAjM,KACA,GAAAkB,EAAAgL,GACA,UAAArS,MAAA,UAAAmG,EAAA,2BAEAkB,EAAAgL,GAAAD,GAGAhT,EAAAC,QAAAgI,IAEGiL,qBAAA,EAAApL,OAAA,EAAAqL,oBAAA,SAA6D,GA/uBoS,CA+uBpS","file":"vendors~components-AddToCartComponent.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.vexDialog = 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<r.length;o++)s(r[o]);return s}return e})()({1:[function(require,module,exports){\n'use strict';\n\nfunction deepcopy(value) {\n  if (!(!!value && typeof value == 'object')) {\n    return value;\n  }\n  if (Object.prototype.toString.call(value) == '[object Date]') {\n    return new Date(value.getTime());\n  }\n  if (Array.isArray(value)) {\n    return value.map(deepcopy);\n  }\n  var result = {};\n  Object.keys(value).forEach(\n    function(key) { result[key] = deepcopy(value[key]); });\n  return result;\n}\n\nmodule.exports = deepcopy;\n\n},{}],2:[function(require,module,exports){\n\n/**\n * Expose `parse`.\n */\n\nmodule.exports = parse;\n\n/**\n * Tests for browser support.\n */\n\nvar innerHTMLBug = false;\nvar bugTestDiv;\nif (typeof document !== 'undefined') {\n  bugTestDiv = document.createElement('div');\n  // Setup\n  bugTestDiv.innerHTML = '  <link/><table></table><a href=\"/a\">a</a><input type=\"checkbox\"/>';\n  // Make sure that link elements get serialized correctly by innerHTML\n  // This requires a wrapper element in IE\n  innerHTMLBug = !bugTestDiv.getElementsByTagName('link').length;\n  bugTestDiv = undefined;\n}\n\n/**\n * Wrap map from jquery.\n */\n\nvar map = {\n  legend: [1, '<fieldset>', '</fieldset>'],\n  tr: [2, '<table><tbody>', '</tbody></table>'],\n  col: [2, '<table><tbody></tbody><colgroup>', '</colgroup></table>'],\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<div>', '</div>'] : [0, '', '']\n};\n\nmap.td =\nmap.th = [3, '<table><tbody><tr>', '</tr></tbody></table>'];\n\nmap.option =\nmap.optgroup = [1, '<select multiple=\"multiple\">', '</select>'];\n\nmap.thead =\nmap.tbody =\nmap.colgroup =\nmap.caption =\nmap.tfoot = [1, '<table>', '</table>'];\n\nmap.polyline =\nmap.ellipse =\nmap.polygon =\nmap.circle =\nmap.text =\nmap.line =\nmap.path =\nmap.rect =\nmap.g = [1, '<svg xmlns=\"http://www.w3.org/2000/svg\" version=\"1.1\">','</svg>'];\n\n/**\n * Parse `html` and return a DOM Node instance, which could be a TextNode,\n * HTML DOM Node of some kind (<div> 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// get successful control from form and assemble into object\n// http://www.w3.org/TR/html401/interact/forms.html#h-17.13.2\n\n// types which indicate a submit action and are not successful controls\n// these will be ignored\nvar k_r_submitter = /^(?:submit|button|image|reset|file)$/i;\n\n// node names which could be successful controls\nvar k_r_success_contrls = /^(?:input|select|textarea|keygen)/i;\n\n// Matches bracket notation.\nvar brackets = /(\\[[^\\[\\]]*\\])/g;\n\n// serializes form fields\n// @param form MUST be an HTMLForm element\n// @param options is an optional argument to configure the serialization. Default output\n// with no options specified is a url encoded string\n//    - hash: [true | false] Configure the output type. If true, the output will\n//    be a js object.\n//    - serializer: [function] Optional serializer function to override the default one.\n//    The function takes 3 arguments (result, key, value) and should return new result\n//    hash and url encoded str serializers are provided with this module\n//    - disabled: [true | false]. If true serialize disabled fields.\n//    - empty: [true | false]. If true serialize empty fields\nfunction serialize(form, options) {\n    if (typeof options != 'object') {\n        options = { hash: !!options };\n    }\n    else if (options.hash === undefined) {\n        options.hash = true;\n    }\n\n    var result = (options.hash) ? {} : '';\n    var serializer = options.serializer || ((options.hash) ? hash_serializer : str_serialize);\n\n    var elements = form && form.elements ? form.elements : [];\n\n    //Object store each radio and set if it's empty or not\n    var radio_store = Object.create(null);\n\n    for (var i=0 ; i<elements.length ; ++i) {\n        var element = elements[i];\n\n        // ingore disabled fields\n        if ((!options.disabled && element.disabled) || !element.name) {\n            continue;\n        }\n        // ignore anyhting that is not considered a success field\n        if (!k_r_success_contrls.test(element.nodeName) ||\n            k_r_submitter.test(element.type)) {\n            continue;\n        }\n\n        var key = element.name;\n        var val = element.value;\n\n        // we can't just use element.value for checkboxes cause some browsers lie to us\n        // they say \"on\" for value when the box isn't checked\n        if ((element.type === 'checkbox' || element.type === 'radio') && !element.checked) {\n            val = undefined;\n        }\n\n        // If we want empty elements\n        if (options.empty) {\n            // for checkbox\n            if (element.type === 'checkbox' && !element.checked) {\n                val = '';\n            }\n\n            // for radio\n            if (element.type === 'radio') {\n                if (!radio_store[element.name] && !element.checked) {\n                    radio_store[element.name] = false;\n                }\n                else if (element.checked) {\n                    radio_store[element.name] = true;\n                }\n            }\n\n            // if options empty is true, continue only if its radio\n            if (!val && element.type == 'radio') {\n                continue;\n            }\n        }\n        else {\n            // value-less fields are ignored unless options.empty is true\n            if (!val) {\n                continue;\n            }\n        }\n\n        // multi select boxes\n        if (element.type === 'select-multiple') {\n            val = [];\n\n            var selectOptions = element.options;\n            var isSelectedOptions = false;\n            for (var j=0 ; j<selectOptions.length ; ++j) {\n                var option = selectOptions[j];\n                var allowedEmpty = options.empty && !option.value;\n                var hasValue = (option.value || allowedEmpty);\n                if (option.selected && hasValue) {\n                    isSelectedOptions = true;\n\n                    // If using a hash serializer be sure to add the\n                    // correct notation for an array in the multi-select\n                    // context. Here the name attribute on the select element\n                    // might be missing the trailing bracket pair. Both names\n                    // \"foo\" and \"foo[]\" should be arrays.\n                    if (options.hash && key.slice(key.length - 2) !== '[]') {\n                        result = serializer(result, key + '[]', option.value);\n                    }\n                    else {\n                        result = serializer(result, key, option.value);\n                    }\n                }\n            }\n\n            // Serialize if no selected options and options.empty is true\n            if (!isSelectedOptions && options.empty) {\n                result = serializer(result, key, '');\n            }\n\n            continue;\n        }\n\n        result = serializer(result, key, val);\n    }\n\n    // Check for all empty radio buttons and serialize them with key=\"\"\n    if (options.empty) {\n        for (var key in radio_store) {\n            if (!radio_store[key]) {\n                result = serializer(result, key, '');\n            }\n        }\n    }\n\n    return result;\n}\n\nfunction parse_keys(string) {\n    var keys = [];\n    var prefix = /^([^\\[\\]]*)/;\n    var children = new RegExp(brackets);\n    var match = prefix.exec(string);\n\n    if (match[1]) {\n        keys.push(match[1]);\n    }\n\n    while ((match = children.exec(string)) !== null) {\n        keys.push(match[1]);\n    }\n\n    return keys;\n}\n\nfunction hash_assign(result, keys, value) {\n    if (keys.length === 0) {\n        result = value;\n        return result;\n    }\n\n    var key = keys.shift();\n    var between = key.match(/^\\[(.+?)\\]$/);\n\n    if (key === '[]') {\n        result = result || [];\n\n        if (Array.isArray(result)) {\n            result.push(hash_assign(null, keys, value));\n        }\n        else {\n            // This might be the result of bad name attributes like \"[][foo]\",\n            // in this case the original `result` object will already be\n            // assigned to an object literal. Rather than coerce the object to\n            // an array, or cause an exception the attribute \"_values\" is\n            // assigned as an array.\n            result._values = result._values || [];\n            result._values.push(hash_assign(null, keys, value));\n        }\n\n        return result;\n    }\n\n    // Key is an attribute name and can be assigned directly.\n    if (!between) {\n        result[key] = hash_assign(result[key], keys, value);\n    }\n    else {\n        var string = between[1];\n        // +var converts the variable into a number\n        // better than parseInt because it doesn't truncate away trailing\n        // letters and actually fails if whole thing is not a number\n        var index = +string;\n\n        // If the characters between the brackets is not a number it is an\n        // attribute name and can be assigned directly.\n        if (isNaN(index)) {\n            result = result || {};\n            result[string] = hash_assign(result[string], keys, value);\n        }\n        else {\n            result = result || [];\n            result[index] = hash_assign(result[index], keys, value);\n        }\n    }\n\n    return result;\n}\n\n// Object/hash encoding serializer.\nfunction hash_serializer(result, key, value) {\n    var matches = key.match(brackets);\n\n    // Has brackets? Use the recursive assignment function to walk the keys,\n    // construct any missing objects in the result tree and make the assignment\n    // at the end of the chain.\n    if (matches) {\n        var keys = parse_keys(key);\n        hash_assign(result, keys, value);\n    }\n    else {\n        // Non bracket notation can make assignments directly.\n        var existing = result[key];\n\n        // If the value has been assigned already (for instance when a radio and\n        // a checkbox have the same name attribute) convert the previous value\n        // into an array before pushing into it.\n        //\n        // NOTE: If this requirement were removed all hash creation and\n        // assignment could go through `hash_assign`.\n        if (existing) {\n            if (!Array.isArray(existing)) {\n                result[key] = [ existing ];\n            }\n\n            result[key].push(value);\n        }\n        else {\n            result[key] = value;\n        }\n    }\n\n    return result;\n}\n\n// urlform encoding serializer\nfunction str_serialize(result, key, value) {\n    // encode newlines as \\r\\n cause the html spec says so\n    value = value.replace(/(\\r)?\\n/g, '\\r\\n');\n    value = encodeURIComponent(value);\n\n    // spaces should be '+' rather than '%20'.\n    value = value.replace(/%20/g, '+');\n    return result + (result ? '&' : '') + encodeURIComponent(key) + '=' + value;\n}\n\nmodule.exports = serialize;\n\n},{}],4:[function(require,module,exports){\nvar domify = require('domify')\r\nvar serialize = require('form-serialize')\r\nvar cloneDeep = require('deep-clone-simple')\r\n\r\n// Build DOM elements for the structure of the dialog\r\nvar buildDialogForm = function buildDialogForm (options) {\r\n  var form = document.createElement('form')\r\n  form.classList.add('vex-dialog-form')\r\n\r\n  var message = document.createElement('div')\r\n  message.classList.add('vex-dialog-message')\r\n  message.appendChild(options.message instanceof window.Node ? options.message : domify(options.message))\r\n\r\n  var input = document.createElement('div')\r\n  input.classList.add('vex-dialog-input')\r\n  input.appendChild(options.input instanceof window.Node ? options.input : domify(options.input))\r\n\r\n  form.appendChild(message)\r\n  form.appendChild(input)\r\n\r\n  return form\r\n}\r\n\r\n// Take an array of buttons (see the default buttons below) and turn them into DOM elements\r\nvar buttonsToDOM = function buttonsToDOM (buttons) {\r\n  var domButtons = document.createElement('div')\r\n  domButtons.classList.add('vex-dialog-buttons')\r\n\r\n  for (var i = 0; i < buttons.length; i++) {\r\n    var button = buttons[i]\r\n    var domButton = document.createElement('button')\r\n    domButton.type = button.type\r\n    domButton.textContent = button.text\r\n    domButton.className = button.className\r\n    domButton.classList.add('vex-dialog-button')\r\n    if (i === 0) {\r\n      domButton.classList.add('vex-first')\r\n    } else if (i === buttons.length - 1) {\r\n      domButton.classList.add('vex-last')\r\n    }\r\n    // Attach click listener to button with closure\r\n    (function (button) {\r\n      domButton.addEventListener('click', function (e) {\r\n        if (button.click) {\r\n          button.click.call(this, e)\r\n        }\r\n      }.bind(this))\r\n    }.bind(this)(button))\r\n\r\n    domButtons.appendChild(domButton)\r\n  }\r\n\r\n  return domButtons\r\n}\r\n\r\nvar plugin = function plugin (vex) {\r\n  // Define the API first\r\n  var dialog = {\r\n    // Plugin name\r\n    name: 'dialog',\r\n\r\n    // Open\r\n    open: function open (opts) {\r\n      var options = Object.assign({}, cloneDeep(this.defaultOptions), opts)\r\n\r\n      // `message` is unsafe internally, so translate\r\n      // safe default: HTML-escape the message before passing it through\r\n      if (options.unsafeMessage && !options.message) {\r\n        options.message = options.unsafeMessage\r\n      } else if (options.message) {\r\n        options.message = vex._escapeHtml(options.message)\r\n      }\r\n\r\n      // Build the form from the options\r\n      var form = options.unsafeContent = buildDialogForm(options)\r\n\r\n      // Open the dialog\r\n      var dialogInstance = vex.open(options)\r\n\r\n      if (options.yesText !== '') {\r\n        options.buttons[0].text = options.yesText\r\n      }\r\n\r\n      if (options.noText !== '') {\r\n        options.buttons[1].text = options.noText\r\n      }\r\n\r\n      // Quick comment - these options and appending buttons and everything\r\n      // would preferably be done _before_ opening the dialog. However, since\r\n      // they rely on the context of the vex instance, we have to do them\r\n      // after. A potential future fix would be to differentiate between\r\n      // a \"created\" vex instance and an \"opened\" vex instance, so any actions\r\n      // that rely on the specific context of the instance can do their stuff\r\n      // before opening the dialog on the page.\r\n\r\n      // Override the before close callback to also pass the value of the form\r\n      var beforeClose = options.beforeClose && options.beforeClose.bind(dialogInstance)\r\n      dialogInstance.options.beforeClose = function dialogBeforeClose () {\r\n        // Only call the callback once - when the validation in beforeClose, if present, is true\r\n        var shouldClose = beforeClose ? beforeClose() : true\r\n        if (shouldClose) {\r\n          options.callback(this.value || false)\r\n        }\r\n        // Return the result of beforeClose() to vex\r\n        return shouldClose\r\n      }.bind(dialogInstance)\r\n\r\n      // Append buttons to form with correct context\r\n      form.appendChild(buttonsToDOM.call(dialogInstance, options.buttons))\r\n\r\n      // Attach form to instance\r\n      dialogInstance.form = form\r\n\r\n      // Add submit listener to form\r\n      form.addEventListener('submit', options.onSubmit.bind(dialogInstance))\r\n\r\n      // Optionally focus the first input in the form\r\n      if (options.focusFirstInput) {\r\n        var el = dialogInstance.contentEl.querySelector('button, input, select, textarea')\r\n        if (el) {\r\n          el.focus()\r\n        }\r\n      }\r\n\r\n      // For chaining\r\n      return dialogInstance\r\n    },\r\n\r\n    // Alert\r\n    alert: function (options) {\r\n      // Allow string as message\r\n      if (typeof options === 'string') {\r\n        options = {\r\n          message: options\r\n        }\r\n      }\r\n      options = Object.assign({}, cloneDeep(this.defaultOptions), cloneDeep(this.defaultAlertOptions), options)\r\n      return this.open(options)\r\n    },\r\n\r\n    // Confirm\r\n    confirm: function (options) {\r\n      if (typeof options !== 'object' || typeof options.callback !== 'function') {\r\n        throw new Error('dialog.confirm(options) requires options.callback.')\r\n      }\r\n      options = Object.assign({}, cloneDeep(this.defaultOptions), cloneDeep(this.defaultConfirmOptions), options)\r\n      return this.open(options)\r\n    },\r\n\r\n    // Prompt\r\n    prompt: function (options) {\r\n      if (typeof options !== 'object' || typeof options.callback !== 'function') {\r\n        throw new Error('dialog.prompt(options) requires options.callback.')\r\n      }\r\n      var defaults = Object.assign({}, cloneDeep(this.defaultOptions), cloneDeep(this.defaultPromptOptions))\r\n      var dynamicDefaults = {\r\n        unsafeMessage: '<label for=\"vex\">' + vex._escapeHtml(options.label || defaults.label) + '</label>',\r\n        input: '<input name=\"vex\" type=\"text\" class=\"vex-dialog-prompt-input\" placeholder=\"' + vex._escapeHtml(options.placeholder || defaults.placeholder) + '\" value=\"' + vex._escapeHtml(options.value || defaults.value) + '\" />'\r\n      }\r\n      options = Object.assign(defaults, dynamicDefaults, options)\r\n      // Pluck the value of the \"vex\" input field as the return value for prompt's callback\r\n      // More closely mimics \"window.prompt\" in that a single string is returned\r\n      var callback = options.callback\r\n      options.callback = function promptCallback (value) {\r\n        if (typeof value === 'object') {\r\n          var keys = Object.keys(value)\r\n          value = keys.length ? value[keys[0]] : ''\r\n        }\r\n        callback(value)\r\n      }\r\n      return this.open(options)\r\n    }\r\n  }\r\n\r\n  // Now define any additional data that's not the direct dialog API\r\n  dialog.buttons = {\r\n    YES: {\r\n      text: 'OK',\r\n      type: 'submit',\r\n      className: 'vex-dialog-button-primary',\r\n      click: function yesClick () {\r\n        this.value = true\r\n      }\r\n    },\r\n\r\n    NO: {\r\n      text: 'Cancel',\r\n      type: 'button',\r\n      className: 'vex-dialog-button-secondary',\r\n      click: function noClick () {\r\n        this.value = false\r\n        this.close()\r\n      }\r\n    }\r\n  }\r\n\r\n  dialog.defaultOptions = {\r\n    callback: function () {},\r\n    afterOpen: function () {},\r\n    message: '',\r\n    input: '',\r\n    yesText: '',\r\n    noText: '',\r\n    buttons: [\r\n      dialog.buttons.YES,\r\n      dialog.buttons.NO\r\n    ],\r\n    showCloseButton: false,\r\n    onSubmit: function onDialogSubmit (e) {\r\n      e.preventDefault()\r\n      if (this.options.input) {\r\n        this.value = serialize(this.form, { hash: true })\r\n      }\r\n      return this.close()\r\n    },\r\n    focusFirstInput: true\r\n  }\r\n\r\n  dialog.defaultAlertOptions = {\r\n    buttons: [\r\n      dialog.buttons.YES\r\n    ]\r\n  }\r\n\r\n  dialog.defaultPromptOptions = {\r\n    label: 'Prompt:',\r\n    placeholder: '',\r\n    value: ''\r\n  }\r\n\r\n  dialog.defaultConfirmOptions = {}\r\n\r\n  return dialog\r\n}\r\n\r\nmodule.exports = plugin\r\n\n},{\"deep-clone-simple\":1,\"domify\":2,\"form-serialize\":3}]},{},[4])(4)\n});","(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<r.length;o++)s(r[o]);return s}return e})()({1:[function(require,module,exports){\n/*\n * classList.js: Cross-browser full element.classList implementation.\n * 1.1.20170427\n *\n * By Eli Grey, http://eligrey.com\n * License: Dedicated to the public domain.\n *   See https://github.com/eligrey/classList.js/blob/master/LICENSE.md\n */\n\n/*global self, document, DOMException */\n\n/*! @source http://purl.eligrey.com/github/classList.js/blob/master/classList.js */\n\nif (\"document\" in window.self) {\n\n// Full polyfill for browsers with no classList support\n// Including IE < Edge missing SVGElement.classList\nif (!(\"classList\" in document.createElement(\"_\")) \n\t|| document.createElementNS && !(\"classList\" in document.createElementNS(\"http://www.w3.org/2000/svg\",\"g\"))) {\n\n(function (view) {\n\n\"use strict\";\n\nif (!('Element' in view)) return;\n\nvar\n\t  classListProp = \"classList\"\n\t, protoProp = \"prototype\"\n\t, elemCtrProto = view.Element[protoProp]\n\t, objCtr = Object\n\t, strTrim = String[protoProp].trim || function () {\n\t\treturn this.replace(/^\\s+|\\s+$/g, \"\");\n\t}\n\t, arrIndexOf = Array[protoProp].indexOf || function (item) {\n\t\tvar\n\t\t\t  i = 0\n\t\t\t, len = this.length\n\t\t;\n\t\tfor (; i < len; i++) {\n\t\t\tif (i in this && this[i] === item) {\n\t\t\t\treturn i;\n\t\t\t}\n\t\t}\n\t\treturn -1;\n\t}\n\t// Vendors: please allow content code to instantiate DOMExceptions\n\t, DOMEx = function (type, message) {\n\t\tthis.name = type;\n\t\tthis.code = DOMException[type];\n\t\tthis.message = message;\n\t}\n\t, checkTokenAndGetIndex = function (classList, token) {\n\t\tif (token === \"\") {\n\t\t\tthrow new DOMEx(\n\t\t\t\t  \"SYNTAX_ERR\"\n\t\t\t\t, \"An invalid or illegal string was specified\"\n\t\t\t);\n\t\t}\n\t\tif (/\\s/.test(token)) {\n\t\t\tthrow new DOMEx(\n\t\t\t\t  \"INVALID_CHARACTER_ERR\"\n\t\t\t\t, \"String contains an invalid character\"\n\t\t\t);\n\t\t}\n\t\treturn arrIndexOf.call(classList, token);\n\t}\n\t, ClassList = function (elem) {\n\t\tvar\n\t\t\t  trimmedClasses = strTrim.call(elem.getAttribute(\"class\") || \"\")\n\t\t\t, classes = trimmedClasses ? trimmedClasses.split(/\\s+/) : []\n\t\t\t, i = 0\n\t\t\t, len = classes.length\n\t\t;\n\t\tfor (; i < len; i++) {\n\t\t\tthis.push(classes[i]);\n\t\t}\n\t\tthis._updateClassName = function () {\n\t\t\telem.setAttribute(\"class\", this.toString());\n\t\t};\n\t}\n\t, classListProto = ClassList[protoProp] = []\n\t, classListGetter = function () {\n\t\treturn new ClassList(this);\n\t}\n;\n// Most DOMException implementations don't allow calling DOMException's toString()\n// on non-DOMExceptions. Error's toString() is sufficient here.\nDOMEx[protoProp] = Error[protoProp];\nclassListProto.item = function (i) {\n\treturn this[i] || null;\n};\nclassListProto.contains = function (token) {\n\ttoken += \"\";\n\treturn checkTokenAndGetIndex(this, token) !== -1;\n};\nclassListProto.add = function () {\n\tvar\n\t\t  tokens = arguments\n\t\t, i = 0\n\t\t, l = tokens.length\n\t\t, token\n\t\t, updated = false\n\t;\n\tdo {\n\t\ttoken = tokens[i] + \"\";\n\t\tif (checkTokenAndGetIndex(this, token) === -1) {\n\t\t\tthis.push(token);\n\t\t\tupdated = true;\n\t\t}\n\t}\n\twhile (++i < l);\n\n\tif (updated) {\n\t\tthis._updateClassName();\n\t}\n};\nclassListProto.remove = function () {\n\tvar\n\t\t  tokens = arguments\n\t\t, i = 0\n\t\t, l = tokens.length\n\t\t, token\n\t\t, updated = false\n\t\t, index\n\t;\n\tdo {\n\t\ttoken = tokens[i] + \"\";\n\t\tindex = checkTokenAndGetIndex(this, token);\n\t\twhile (index !== -1) {\n\t\t\tthis.splice(index, 1);\n\t\t\tupdated = true;\n\t\t\tindex = checkTokenAndGetIndex(this, token);\n\t\t}\n\t}\n\twhile (++i < l);\n\n\tif (updated) {\n\t\tthis._updateClassName();\n\t}\n};\nclassListProto.toggle = function (token, force) {\n\ttoken += \"\";\n\n\tvar\n\t\t  result = this.contains(token)\n\t\t, method = result ?\n\t\t\tforce !== true && \"remove\"\n\t\t:\n\t\t\tforce !== false && \"add\"\n\t;\n\n\tif (method) {\n\t\tthis[method](token);\n\t}\n\n\tif (force === true || force === false) {\n\t\treturn force;\n\t} else {\n\t\treturn !result;\n\t}\n};\nclassListProto.toString = function () {\n\treturn this.join(\" \");\n};\n\nif (objCtr.defineProperty) {\n\tvar classListPropDesc = {\n\t\t  get: classListGetter\n\t\t, enumerable: true\n\t\t, configurable: true\n\t};\n\ttry {\n\t\tobjCtr.defineProperty(elemCtrProto, classListProp, classListPropDesc);\n\t} catch (ex) { // IE 8 doesn't support enumerable:true\n\t\t// adding undefined to fight this issue https://github.com/eligrey/classList.js/issues/36\n\t\t// modernie IE8-MSW7 machine has IE8 8.0.6001.18702 and is affected\n\t\tif (ex.number === undefined || ex.number === -0x7FF5EC54) {\n\t\t\tclassListPropDesc.enumerable = false;\n\t\t\tobjCtr.defineProperty(elemCtrProto, classListProp, classListPropDesc);\n\t\t}\n\t}\n} else if (objCtr[protoProp].__defineGetter__) {\n\telemCtrProto.__defineGetter__(classListProp, classListGetter);\n}\n\n}(window.self));\n\n}\n\n// There is full or partial native classList support, so just check if we need\n// to normalize the add/remove and toggle APIs.\n\n(function () {\n\t\"use strict\";\n\n\tvar testElement = document.createElement(\"_\");\n\n\ttestElement.classList.add(\"c1\", \"c2\");\n\n\t// Polyfill for IE 10/11 and Firefox <26, where classList.add and\n\t// classList.remove exist but support only one argument at a time.\n\tif (!testElement.classList.contains(\"c2\")) {\n\t\tvar createMethod = function(method) {\n\t\t\tvar original = DOMTokenList.prototype[method];\n\n\t\t\tDOMTokenList.prototype[method] = function(token) {\n\t\t\t\tvar i, len = arguments.length;\n\n\t\t\t\tfor (i = 0; i < len; i++) {\n\t\t\t\t\ttoken = arguments[i];\n\t\t\t\t\toriginal.call(this, token);\n\t\t\t\t}\n\t\t\t};\n\t\t};\n\t\tcreateMethod('add');\n\t\tcreateMethod('remove');\n\t}\n\n\ttestElement.classList.toggle(\"c3\", false);\n\n\t// Polyfill for IE 10 and Firefox <24, where classList.toggle does not\n\t// support the second argument.\n\tif (testElement.classList.contains(\"c3\")) {\n\t\tvar _toggle = DOMTokenList.prototype.toggle;\n\n\t\tDOMTokenList.prototype.toggle = function(token, force) {\n\t\t\tif (1 in arguments && !this.contains(token) === !force) {\n\t\t\t\treturn force;\n\t\t\t} else {\n\t\t\t\treturn _toggle.call(this, token);\n\t\t\t}\n\t\t};\n\n\t}\n\n\ttestElement = null;\n}());\n\n}\n\n},{}],2:[function(require,module,exports){\n\n/**\n * Expose `parse`.\n */\n\nmodule.exports = parse;\n\n/**\n * Tests for browser support.\n */\n\nvar innerHTMLBug = false;\nvar bugTestDiv;\nif (typeof document !== 'undefined') {\n  bugTestDiv = document.createElement('div');\n  // Setup\n  bugTestDiv.innerHTML = '  <link/><table></table><a href=\"/a\">a</a><input type=\"checkbox\"/>';\n  // Make sure that link elements get serialized correctly by innerHTML\n  // This requires a wrapper element in IE\n  innerHTMLBug = !bugTestDiv.getElementsByTagName('link').length;\n  bugTestDiv = undefined;\n}\n\n/**\n * Wrap map from jquery.\n */\n\nvar map = {\n  legend: [1, '<fieldset>', '</fieldset>'],\n  tr: [2, '<table><tbody>', '</tbody></table>'],\n  col: [2, '<table><tbody></tbody><colgroup>', '</colgroup></table>'],\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<div>', '</div>'] : [0, '', '']\n};\n\nmap.td =\nmap.th = [3, '<table><tbody><tr>', '</tr></tbody></table>'];\n\nmap.option =\nmap.optgroup = [1, '<select multiple=\"multiple\">', '</select>'];\n\nmap.thead =\nmap.tbody =\nmap.colgroup =\nmap.caption =\nmap.tfoot = [1, '<table>', '</table>'];\n\nmap.polyline =\nmap.ellipse =\nmap.polygon =\nmap.circle =\nmap.text =\nmap.line =\nmap.path =\nmap.rect =\nmap.g = [1, '<svg xmlns=\"http://www.w3.org/2000/svg\" version=\"1.1\">','</svg>'];\n\n/**\n * Parse `html` and return a DOM Node instance, which could be a TextNode,\n * HTML DOM Node of some kind (<div> 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":""}