{"version":3,"sources":["cookie.js"],"names":["document","undefined","cookie","get","apply","arguments","utils","isArray","Array","value","Object","prototype","toString","call","isPlainObject","toArray","slice","getKeys","keys","obj","key","hasOwnProperty","push","encode","String","replace","character","encodeURIComponent","decode","decodeURIComponent","retrieve","fallback","defaults","expiresMultiplier","set","options","k","this","expires","expiresType","Date","toGMTString","path","domain","secure","setDefault","remove","i","l","length","removeSpecific","empty","all","cookies","result","split","item","shift","join","enabled","navigator","cookieEnabled","ret","define","amd","exports","window"],"mappings":"CAEC,SAAUA,EAAUC,GAEpB,IAAIC,EAAS,WACZ,OAAOA,EAAOC,IAAIC,MAAMF,EAAQG,YAG7BC,EAAQJ,EAAOI,MAAS,CAG3BC,QAASC,MAAMD,SAAW,SAAUE,GACnC,MAAiD,mBAA1CC,OAAOC,UAAUC,SAASC,KAAKJ,IAIvCK,cAAe,SAAUL,GACxB,QAASA,GAAmD,oBAA1CC,OAAOC,UAAUC,SAASC,KAAKJ,IAIlDM,QAAS,SAAUN,GAClB,OAAOD,MAAMG,UAAUK,MAAMH,KAAKJ,IAInCQ,QAASP,OAAOQ,MAAQ,SAAUC,GACjC,IAAID,EAAO,GACTE,EAAM,GACR,IAAKA,KAAOD,EACPA,EAAIE,eAAeD,IAAMF,EAAKI,KAAKF,GAExC,OAAOF,GAKRK,OAAQ,SAAUd,GACjB,OAAOe,OAAOf,GAAOgB,QAAQ,eAAgB,SAAUC,GACtD,OAAOC,mBAAmBD,MAI5BE,OAAQ,SAAUnB,GACjB,OAAOoB,mBAAmBpB,IAI3BqB,SAAU,SAAUrB,EAAOsB,GAC1B,OAAgB,MAATtB,EAAgBsB,EAAWtB,IAKpCP,EAAO8B,SAAW,GAElB9B,EAAO+B,kBAAoB,MAE3B/B,EAAOgC,IAAM,SAAUd,EAAKX,EAAO0B,GAClC,GAAI7B,EAAMQ,cAAcM,GAGvB,IAAK,IAAIgB,KAAKhB,EACTA,EAAIC,eAAee,IAAIC,KAAKH,IAAIE,EAAGhB,EAAI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AOc,mBAAXC,QAAyBA,OAAOC,IAC1CD,OAAO,WACN,MAAO,CAAC7D,OAAQA,KAEY,oBAAZ+D,QACjBA,QAAQ/D,OAASA,EACXgE,OAAOhE,OAASA,EAlLvB,CAqLqB,oBAAbF,SAA2B,KAAOA","file":"../../vendor/cookie.js","sourcesContent":["// Copyright (c) 2015 Florian Hartmann, https://github.com/florian https://github.com/florian/cookie.js\r\n\r\n!function (document, undefined) {\r\n\r\n\tvar cookie = function () {\r\n\t\treturn cookie.get.apply(cookie, arguments);\r\n\t};\r\n\r\n\tvar utils = cookie.utils =  {\r\n\r\n\t\t// Is the given value an array? Use ES5 Array.isArray if it's available.\r\n\t\tisArray: Array.isArray || function (value) {\r\n\t\t\treturn Object.prototype.toString.call(value) === '[object Array]';\r\n\t\t},\r\n\r\n\t\t// Is the given value a plain object / an object whose constructor is `Object`?\r\n\t\tisPlainObject: function (value) {\r\n\t\t\treturn !!value && Object.prototype.toString.call(value) === '[object Object]';\r\n\t\t},\r\n\r\n\t\t// Convert an array-like object to an array – for example `arguments`.\r\n\t\ttoArray: function (value) {\r\n\t\t\treturn Array.prototype.slice.call(value);\r\n\t\t},\r\n\r\n\t\t// Get the keys of an object. Use ES5 Object.keys if it's available.\r\n\t\tgetKeys: Object.keys || function (obj) {\r\n\t\t\tvar keys = [],\r\n\t\t\t\t key = '';\r\n\t\t\tfor (key in obj) {\r\n\t\t\t\tif (obj.hasOwnProperty(key)) keys.push(key);\r\n\t\t\t}\r\n\t\t\treturn keys;\r\n\t\t},\r\n\r\n\t\t// Unlike JavaScript's built-in escape functions, this method\r\n\t\t// only escapes characters that are not allowed in cookies.\r\n\t\tencode: function (value) {\r\n\t\t\treturn String(value).replace(/[,;\"\\\\=\\s%]/g, function (character) {\r\n\t\t\t\treturn encodeURIComponent(character);\r\n\t\t\t});\r\n\t\t},\r\n\r\n\t\tdecode: function (value) {\r\n\t\t\treturn decodeURIComponent(value);\r\n\t\t},\r\n\r\n\t\t// Return fallback if the value is not defined, otherwise return value.\r\n\t\tretrieve: function (value, fallback) {\r\n\t\t\treturn value == null ? fallback : value;\r\n\t\t}\r\n\r\n\t};\r\n\r\n\tcookie.defaults = {};\r\n\r\n\tcookie.expiresMultiplier = 60 * 60 * 24;\r\n\r\n\tcookie.set = function (key, value, options) {\r\n\t\tif (utils.isPlainObject(key)) {\r\n\t\t\t// `key` contains an object with keys and values for cookies, `value` contains the options object.\r\n\r\n\t\t\tfor (var k in key) {\r\n\t\t\t\tif (key.hasOwnProperty(k)) this.set(k, key[k], value);\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\toptions = utils.isPlainObject(options) ? options : { expires: options };\r\n\r\n\t\t\t// Empty string for session cookies.\r\n\t\t\tvar expires = options.expires !== undefined ? options.expires : (this.defaults.expires || ''),\r\n\t\t\t    expiresType = typeof(expires);\r\n\r\n\t\t\tif (expiresType === 'string' && expires !== '') expires = new Date(expires);\r\n\t\t\telse if (expiresType === 'number') expires = new Date(+new Date + 1000 * this.expiresMultiplier * expires); // This is needed because IE does not support the `max-age` cookie attribute.\r\n\r\n\t\t\tif (expires !== '' && 'toGMTString' in expires) expires = ';expires=' + expires.toGMTString();\r\n\r\n\t\t\tvar path = options.path || this.defaults.path;\r\n\t\t\tpath = path ? ';path=' + path : '';\r\n\r\n\t\t\tvar domain = options.domain || this.defaults.domain;\r\n\t\t\tdomain = domain ? ';domain=' + domain : '';\r\n\r\n\t\t\tvar secure = options.secure || this.defaults.secure ? ';secure' : '';\r\n\t\t\tif (options.secure === false) secure = '';\r\n\r\n\t\t\tdocument.cookie = utils.encode(key) + '=' + utils.encode(value) + expires + path + domain + secure;\r\n\t\t}\r\n\r\n\t\treturn this; // Return the `cookie` object to make chaining possible.\r\n\t};\r\n\r\n\tcookie.setDefault = function (key, value, options) {\r\n\t\tif (utils.isPlainObject(key)) {\r\n\t\t\tfor (var k in key) {\r\n\t\t\t\tif (this.get(k) === undefined) this.set(k, key[k], value);\r\n\t\t\t}\r\n\t\t\treturn cookie;\r\n\t\t} else {\r\n\t\t\tif (this.get(key) === undefined) return this.set.apply(this, arguments);\r\n\t\t}\r\n\t},\r\n\r\n\tcookie.remove = function (keys) {\r\n\t\tkeys = utils.isArray(keys) ? keys : utils.toArray(arguments);\r\n\r\n\t\tfor (var i = 0, l = keys.length; i < l; i++) {\r\n\t\t\tthis.set(keys[i], '', -1);\r\n\t\t}\r\n\r\n\t\treturn this; // Return the `cookie` object to make chaining possible.\r\n\t};\r\n\r\n\tcookie.removeSpecific = function (keys, options) {\r\n\t\tif (!options) return this.remove(keys);\r\n\r\n\t\tkeys = utils.isArray(keys) ? keys : [keys];\r\n\t\toptions.expires = -1;\r\n\r\n\t\tfor (var i = 0, l = keys.length; i < l; i++) {\r\n\t\t\tthis.set(keys[i], '', options);\r\n\t\t}\r\n\r\n\t\treturn this; // Return the `cookie` object to make chaining possible.\r\n\t};\r\n\r\n\tcookie.empty = function () {\r\n\t\treturn this.remove(utils.getKeys(this.all()));\r\n\t};\r\n\r\n\tcookie.get = function (keys, fallback) {\r\n\t\tvar cookies = this.all();\r\n\r\n\t\tif (utils.isArray(keys)) {\r\n\t\t\tvar result = {};\r\n\r\n\t\t\tfor (var i = 0, l = keys.length; i < l; i++) {\r\n\t\t\t\tvar value = keys[i];\r\n\t\t\t\tresult[value] = utils.retrieve(cookies[value], fallback);\r\n\t\t\t}\r\n\r\n\t\t\treturn result;\r\n\r\n\t\t} else return utils.retrieve(cookies[keys], fallback);\r\n\t};\r\n\r\n\tcookie.all = function () {\r\n\t\tif (document.cookie === '') return {};\r\n\r\n\t\tvar cookies = document.cookie.split('; '),\r\n\t\t    result = {};\r\n\r\n\t\tfor (var i = 0, l = cookies.length; i < l; i++) {\r\n\t\t\tvar item = cookies[i].split('=');\r\n\t\t\tvar key = utils.decode(item.shift());\r\n\t\t\tvar value = utils.decode(item.join('='));\r\n\t\t\tresult[key] = value;\r\n\t\t}\r\n\r\n\t\treturn result;\r\n\t};\r\n\r\n\tcookie.enabled = function () {\r\n\t\tif (navigator.cookieEnabled) return true;\r\n\r\n\t\tvar ret = cookie.set('_', '_').get('_') === '_';\r\n\t\tcookie.remove('_');\r\n\t\treturn ret;\r\n\t};\r\n\r\n\t// If an AMD loader is present use AMD.\r\n\t// If a CommonJS loader is present use CommonJS.\r\n\t// Otherwise assign the `cookie` object to the global scope.\r\n\r\n\tif (typeof define === 'function' && define.amd) {\r\n\t\tdefine(function () {\r\n\t\t\treturn {cookie: cookie};\r\n\t\t});\r\n\t} else if (typeof exports !== 'undefined') {\r\n\t\texports.cookie = cookie;\r\n\t} else window.cookie = cookie;\r\n\r\n// If used e.g. with Browserify and CommonJS, document is not declared.\r\n}(typeof document === 'undefined' ? null : document);\r\n"]}