` by default. You can change this\n * behavior by providing a `component` prop.\n * If you use React v16+ and would like to avoid a wrapping `
` element\n * you can pass in `component={null}`. This is useful if the wrapping div\n * borks your css styles.\n */\n component: _propTypes.default.any,\n\n /**\n * A set of `` components, that are toggled `in` and out as they\n * leave. the `` will inject specific transition props, so\n * remember to spread them through if you are wrapping the `` as\n * with our `` example.\n */\n children: _propTypes.default.node,\n\n /**\n * A convenience prop that enables or disables appear animations\n * for all children. Note that specifying this will override any defaults set\n * on individual children Transitions.\n */\n appear: _propTypes.default.bool,\n\n /**\n * A convenience prop that enables or disables enter animations\n * for all children. Note that specifying this will override any defaults set\n * on individual children Transitions.\n */\n enter: _propTypes.default.bool,\n\n /**\n * A convenience prop that enables or disables exit animations\n * for all children. Note that specifying this will override any defaults set\n * on individual children Transitions.\n */\n exit: _propTypes.default.bool,\n\n /**\n * You may need to apply reactive updates to a child as it is exiting.\n * This is generally done by using `cloneElement` however in the case of an exiting\n * child the element has already been removed and not accessible to the consumer.\n *\n * If you do need to update a child as it leaves you can provide a `childFactory`\n * to wrap every child, even the ones that are leaving.\n *\n * @type Function(child: ReactElement) -> ReactElement\n */\n childFactory: _propTypes.default.func\n} : {};\nTransitionGroup.defaultProps = defaultProps;\n\nvar _default = (0, _reactLifecyclesCompat.polyfill)(TransitionGroup);\n\nexports.default = _default;\nmodule.exports = exports[\"default\"];","'use strict';\n\nvar $propertyIsEnumerable = {}.propertyIsEnumerable; // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\n\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor; // Nashorn ~ JDK8 bug\n\nvar NASHORN_BUG = getOwnPropertyDescriptor && !$propertyIsEnumerable.call({\n 1: 2\n}, 1); // `Object.prototype.propertyIsEnumerable` method implementation\n// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable\n\nexports.f = NASHORN_BUG ? function propertyIsEnumerable(V) {\n var descriptor = getOwnPropertyDescriptor(this, V);\n return !!descriptor && descriptor.enumerable;\n} : $propertyIsEnumerable;","'use strict';\n\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nvar fails = require('../internals/fails');\n\nvar classof = require('../internals/classof-raw');\n\nvar $Object = Object;\nvar split = uncurryThis(''.split); // fallback for non-array-like ES3 and non-enumerable old V8 strings\n\nmodule.exports = fails(function () {\n // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346\n // eslint-disable-next-line no-prototype-builtins -- safe\n return !$Object('z').propertyIsEnumerable(0);\n}) ? function (it) {\n return classof(it) === 'String' ? split(it, '') : $Object(it);\n} : $Object;","'use strict'; // we can't use just `it == null` since of `document.all` special case\n// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec\n\nmodule.exports = function (it) {\n return it === null || it === undefined;\n};","'use strict';\n/* eslint-disable es/no-symbol -- required for testing */\n\nvar NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');\n\nmodule.exports = NATIVE_SYMBOL && !Symbol.sham && typeof Symbol.iterator == 'symbol';","'use strict';\n\nvar DESCRIPTORS = require('../internals/descriptors');\n\nvar fails = require('../internals/fails');\n\nvar createElement = require('../internals/document-create-element'); // Thanks to IE8 for its funny defineProperty\n\n\nmodule.exports = !DESCRIPTORS && !fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty(createElement('div'), 'a', {\n get: function get() {\n return 7;\n }\n }).a !== 7;\n});","'use strict';\n\nvar DESCRIPTORS = require('../internals/descriptors');\n\nvar fails = require('../internals/fails'); // V8 ~ Chrome 36-\n// https://bugs.chromium.org/p/v8/issues/detail?id=3334\n\n\nmodule.exports = DESCRIPTORS && fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty(function () {\n /* empty */\n }, 'prototype', {\n value: 42,\n writable: false\n }).prototype !== 42;\n});","'use strict';\n\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nvar fails = require('../internals/fails');\n\nvar isCallable = require('../internals/is-callable');\n\nvar hasOwn = require('../internals/has-own-property');\n\nvar DESCRIPTORS = require('../internals/descriptors');\n\nvar CONFIGURABLE_FUNCTION_NAME = require('../internals/function-name').CONFIGURABLE;\n\nvar inspectSource = require('../internals/inspect-source');\n\nvar InternalStateModule = require('../internals/internal-state');\n\nvar enforceInternalState = InternalStateModule.enforce;\nvar getInternalState = InternalStateModule.get;\nvar $String = String; // eslint-disable-next-line es/no-object-defineproperty -- safe\n\nvar defineProperty = Object.defineProperty;\nvar stringSlice = uncurryThis(''.slice);\nvar replace = uncurryThis(''.replace);\nvar join = uncurryThis([].join);\nvar CONFIGURABLE_LENGTH = DESCRIPTORS && !fails(function () {\n return defineProperty(function () {\n /* empty */\n }, 'length', {\n value: 8\n }).length !== 8;\n});\nvar TEMPLATE = String(String).split('String');\n\nvar makeBuiltIn = module.exports = function (value, name, options) {\n if (stringSlice($String(name), 0, 7) === 'Symbol(') {\n name = '[' + replace($String(name), /^Symbol\\(([^)]*)\\).*$/, '$1') + ']';\n }\n\n if (options && options.getter) name = 'get ' + name;\n if (options && options.setter) name = 'set ' + name;\n\n if (!hasOwn(value, 'name') || CONFIGURABLE_FUNCTION_NAME && value.name !== name) {\n if (DESCRIPTORS) defineProperty(value, 'name', {\n value: name,\n configurable: true\n });else value.name = name;\n }\n\n if (CONFIGURABLE_LENGTH && options && hasOwn(options, 'arity') && value.length !== options.arity) {\n defineProperty(value, 'length', {\n value: options.arity\n });\n }\n\n try {\n if (options && hasOwn(options, 'constructor') && options.constructor) {\n if (DESCRIPTORS) defineProperty(value, 'prototype', {\n writable: false\n }); // in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable\n } else if (value.prototype) value.prototype = undefined;\n } catch (error) {\n /* empty */\n }\n\n var state = enforceInternalState(value);\n\n if (!hasOwn(state, 'source')) {\n state.source = join(TEMPLATE, typeof name == 'string' ? name : '');\n }\n\n return value;\n}; // add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative\n// eslint-disable-next-line no-extend-native -- required\n\n\nFunction.prototype.toString = makeBuiltIn(function toString() {\n return isCallable(this) && getInternalState(this).source || inspectSource(this);\n}, 'toString');","'use strict';\n\nvar DESCRIPTORS = require('../internals/descriptors');\n\nvar hasOwn = require('../internals/has-own-property');\n\nvar FunctionPrototype = Function.prototype; // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\n\nvar getDescriptor = DESCRIPTORS && Object.getOwnPropertyDescriptor;\nvar EXISTS = hasOwn(FunctionPrototype, 'name'); // additional protection from minified / mangled / dropped function names\n\nvar PROPER = EXISTS && function something() {\n /* empty */\n}.name === 'something';\n\nvar CONFIGURABLE = EXISTS && (!DESCRIPTORS || DESCRIPTORS && getDescriptor(FunctionPrototype, 'name').configurable);\nmodule.exports = {\n EXISTS: EXISTS,\n PROPER: PROPER,\n CONFIGURABLE: CONFIGURABLE\n};","'use strict';\n\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nvar isCallable = require('../internals/is-callable');\n\nvar store = require('../internals/shared-store');\n\nvar functionToString = uncurryThis(Function.toString); // this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper\n\nif (!isCallable(store.inspectSource)) {\n store.inspectSource = function (it) {\n return functionToString(it);\n };\n}\n\nmodule.exports = store.inspectSource;","'use strict';\n\nvar hasOwn = require('../internals/has-own-property');\n\nvar ownKeys = require('../internals/own-keys');\n\nvar getOwnPropertyDescriptorModule = require('../internals/object-get-own-property-descriptor');\n\nvar definePropertyModule = require('../internals/object-define-property');\n\nmodule.exports = function (target, source, exceptions) {\n var keys = ownKeys(source);\n var defineProperty = definePropertyModule.f;\n var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\n\n for (var i = 0; i < keys.length; i++) {\n var key = keys[i];\n\n if (!hasOwn(target, key) && !(exceptions && hasOwn(exceptions, key))) {\n defineProperty(target, key, getOwnPropertyDescriptor(source, key));\n }\n }\n};","'use strict';\n\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nvar hasOwn = require('../internals/has-own-property');\n\nvar toIndexedObject = require('../internals/to-indexed-object');\n\nvar indexOf = require('../internals/array-includes').indexOf;\n\nvar hiddenKeys = require('../internals/hidden-keys');\n\nvar push = uncurryThis([].push);\n\nmodule.exports = function (object, names) {\n var O = toIndexedObject(object);\n var i = 0;\n var result = [];\n var key;\n\n for (key in O) {\n !hasOwn(hiddenKeys, key) && hasOwn(O, key) && push(result, key);\n } // Don't enum bug & hidden keys\n\n\n while (names.length > i) {\n if (hasOwn(O, key = names[i++])) {\n ~indexOf(result, key) || push(result, key);\n }\n }\n\n return result;\n};","'use strict';\n\nvar toLength = require('../internals/to-length'); // `LengthOfArrayLike` abstract operation\n// https://tc39.es/ecma262/#sec-lengthofarraylike\n\n\nmodule.exports = function (obj) {\n return toLength(obj.length);\n};","'use strict';\n/* eslint-disable no-proto -- safe */\n\nvar uncurryThisAccessor = require('../internals/function-uncurry-this-accessor');\n\nvar isObject = require('../internals/is-object');\n\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nvar aPossiblePrototype = require('../internals/a-possible-prototype'); // `Object.setPrototypeOf` method\n// https://tc39.es/ecma262/#sec-object.setprototypeof\n// Works with __proto__ only. Old v8 can't work with null proto objects.\n// eslint-disable-next-line es/no-object-setprototypeof -- safe\n\n\nmodule.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {\n var CORRECT_SETTER = false;\n var test = {};\n var setter;\n\n try {\n setter = uncurryThisAccessor(Object.prototype, '__proto__', 'set');\n setter(test, []);\n CORRECT_SETTER = test instanceof Array;\n } catch (error) {\n /* empty */\n }\n\n return function setPrototypeOf(O, proto) {\n requireObjectCoercible(O);\n aPossiblePrototype(proto);\n if (!isObject(O)) return O;\n if (CORRECT_SETTER) setter(O, proto);else O.__proto__ = proto;\n return O;\n };\n}() : undefined);","'use strict';\n\nvar fails = require('../internals/fails');\n\nmodule.exports = !fails(function () {\n function F() {\n /* empty */\n }\n\n F.prototype.constructor = null; // eslint-disable-next-line es/no-object-getprototypeof -- required for testing\n\n return Object.getPrototypeOf(new F()) !== F.prototype;\n});","'use strict';\n\nvar NATIVE_BIND = require('../internals/function-bind-native');\n\nvar FunctionPrototype = Function.prototype;\nvar apply = FunctionPrototype.apply;\nvar call = FunctionPrototype.call; // eslint-disable-next-line es/no-reflect -- safe\n\nmodule.exports = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call.bind(apply) : function () {\n return call.apply(apply, arguments);\n});","'use strict';\n\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nvar fails = require('../internals/fails');\n\nvar isCallable = require('../internals/is-callable');\n\nvar classof = require('../internals/classof');\n\nvar getBuiltIn = require('../internals/get-built-in');\n\nvar inspectSource = require('../internals/inspect-source');\n\nvar noop = function noop() {\n /* empty */\n};\n\nvar construct = getBuiltIn('Reflect', 'construct');\nvar constructorRegExp = /^\\s*(?:class|function)\\b/;\nvar exec = uncurryThis(constructorRegExp.exec);\nvar INCORRECT_TO_STRING = !constructorRegExp.test(noop);\n\nvar isConstructorModern = function isConstructor(argument) {\n if (!isCallable(argument)) return false;\n\n try {\n construct(noop, [], argument);\n return true;\n } catch (error) {\n return false;\n }\n};\n\nvar isConstructorLegacy = function isConstructor(argument) {\n if (!isCallable(argument)) return false;\n\n switch (classof(argument)) {\n case 'AsyncFunction':\n case 'GeneratorFunction':\n case 'AsyncGeneratorFunction':\n return false;\n }\n\n try {\n // we can't check .prototype since constructors produced by .bind haven't it\n // `Function#toString` throws on some built-it function in some legacy engines\n // (for example, `DOMQuad` and similar in FF41-)\n return INCORRECT_TO_STRING || !!exec(constructorRegExp, inspectSource(argument));\n } catch (error) {\n return true;\n }\n};\n\nisConstructorLegacy.sham = true; // `IsConstructor` abstract operation\n// https://tc39.es/ecma262/#sec-isconstructor\n\nmodule.exports = !construct || fails(function () {\n var called;\n return isConstructorModern(isConstructorModern.call) || !isConstructorModern(Object) || !isConstructorModern(function () {\n called = true;\n }) || called;\n}) ? isConstructorLegacy : isConstructorModern;","'use strict';\n\nvar DESCRIPTORS = require('../internals/descriptors');\n\nvar V8_PROTOTYPE_DEFINE_BUG = require('../internals/v8-prototype-define-bug');\n\nvar definePropertyModule = require('../internals/object-define-property');\n\nvar anObject = require('../internals/an-object');\n\nvar toIndexedObject = require('../internals/to-indexed-object');\n\nvar objectKeys = require('../internals/object-keys'); // `Object.defineProperties` method\n// https://tc39.es/ecma262/#sec-object.defineproperties\n// eslint-disable-next-line es/no-object-defineproperties -- safe\n\n\nexports.f = DESCRIPTORS && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {\n anObject(O);\n var props = toIndexedObject(Properties);\n var keys = objectKeys(Properties);\n var length = keys.length;\n var index = 0;\n var key;\n\n while (length > index) {\n definePropertyModule.f(O, key = keys[index++], props[key]);\n }\n\n return O;\n};","'use strict';\n\nvar internalObjectKeys = require('../internals/object-keys-internal');\n\nvar enumBugKeys = require('../internals/enum-bug-keys'); // `Object.keys` method\n// https://tc39.es/ecma262/#sec-object.keys\n// eslint-disable-next-line es/no-object-keys -- safe\n\n\nmodule.exports = Object.keys || function keys(O) {\n return internalObjectKeys(O, enumBugKeys);\n};","'use strict';\n\nvar makeBuiltIn = require('../internals/make-built-in');\n\nvar defineProperty = require('../internals/object-define-property');\n\nmodule.exports = function (target, name, descriptor) {\n if (descriptor.get) makeBuiltIn(descriptor.get, name, {\n getter: true\n });\n if (descriptor.set) makeBuiltIn(descriptor.set, name, {\n setter: true\n });\n return defineProperty.f(target, name, descriptor);\n};","'use strict';\n\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nexports.f = wellKnownSymbol;","'use strict';\n\nvar path = require('../internals/path');\n\nvar hasOwn = require('../internals/has-own-property');\n\nvar wrappedWellKnownSymbolModule = require('../internals/well-known-symbol-wrapped');\n\nvar defineProperty = require('../internals/object-define-property').f;\n\nmodule.exports = function (NAME) {\n var Symbol = path.Symbol || (path.Symbol = {});\n if (!hasOwn(Symbol, NAME)) defineProperty(Symbol, NAME, {\n value: wrappedWellKnownSymbolModule.f(NAME)\n });\n};","'use strict';\n\nvar classof = require('../internals/classof-raw'); // `IsArray` abstract operation\n// https://tc39.es/ecma262/#sec-isarray\n// eslint-disable-next-line es/no-array-isarray -- safe\n\n\nmodule.exports = Array.isArray || function isArray(argument) {\n return classof(argument) === 'Array';\n};","'use strict';\n\nvar NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');\n/* eslint-disable es/no-symbol -- safe */\n\n\nmodule.exports = NATIVE_SYMBOL && !!Symbol['for'] && !!Symbol.keyFor;","'use strict';\n\nvar toIndexedObject = require('../internals/to-indexed-object');\n\nvar addToUnscopables = require('../internals/add-to-unscopables');\n\nvar Iterators = require('../internals/iterators');\n\nvar InternalStateModule = require('../internals/internal-state');\n\nvar defineProperty = require('../internals/object-define-property').f;\n\nvar defineIterator = require('../internals/iterator-define');\n\nvar createIterResultObject = require('../internals/create-iter-result-object');\n\nvar IS_PURE = require('../internals/is-pure');\n\nvar DESCRIPTORS = require('../internals/descriptors');\n\nvar ARRAY_ITERATOR = 'Array Iterator';\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(ARRAY_ITERATOR); // `Array.prototype.entries` method\n// https://tc39.es/ecma262/#sec-array.prototype.entries\n// `Array.prototype.keys` method\n// https://tc39.es/ecma262/#sec-array.prototype.keys\n// `Array.prototype.values` method\n// https://tc39.es/ecma262/#sec-array.prototype.values\n// `Array.prototype[@@iterator]` method\n// https://tc39.es/ecma262/#sec-array.prototype-@@iterator\n// `CreateArrayIterator` internal method\n// https://tc39.es/ecma262/#sec-createarrayiterator\n\nmodule.exports = defineIterator(Array, 'Array', function (iterated, kind) {\n setInternalState(this, {\n type: ARRAY_ITERATOR,\n target: toIndexedObject(iterated),\n // target\n index: 0,\n // next index\n kind: kind // kind\n\n }); // `%ArrayIteratorPrototype%.next` method\n // https://tc39.es/ecma262/#sec-%arrayiteratorprototype%.next\n}, function () {\n var state = getInternalState(this);\n var target = state.target;\n var index = state.index++;\n\n if (!target || index >= target.length) {\n state.target = null;\n return createIterResultObject(undefined, true);\n }\n\n switch (state.kind) {\n case 'keys':\n return createIterResultObject(index, false);\n\n case 'values':\n return createIterResultObject(target[index], false);\n }\n\n return createIterResultObject([index, target[index]], false);\n}, 'values'); // argumentsList[@@iterator] is %ArrayProto_values%\n// https://tc39.es/ecma262/#sec-createunmappedargumentsobject\n// https://tc39.es/ecma262/#sec-createmappedargumentsobject\n\nvar values = Iterators.Arguments = Iterators.Array; // https://tc39.es/ecma262/#sec-array.prototype-@@unscopables\n\naddToUnscopables('keys');\naddToUnscopables('values');\naddToUnscopables('entries'); // V8 ~ Chrome 45- bug\n\nif (!IS_PURE && DESCRIPTORS && values.name !== 'values') try {\n defineProperty(values, 'name', {\n value: 'values'\n });\n} catch (error) {\n /* empty */\n}","'use strict';\n\nvar $ = require('../internals/export');\n\nvar call = require('../internals/function-call');\n\nvar IS_PURE = require('../internals/is-pure');\n\nvar FunctionName = require('../internals/function-name');\n\nvar isCallable = require('../internals/is-callable');\n\nvar createIteratorConstructor = require('../internals/iterator-create-constructor');\n\nvar getPrototypeOf = require('../internals/object-get-prototype-of');\n\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\n\nvar setToStringTag = require('../internals/set-to-string-tag');\n\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\n\nvar defineBuiltIn = require('../internals/define-built-in');\n\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar Iterators = require('../internals/iterators');\n\nvar IteratorsCore = require('../internals/iterators-core');\n\nvar PROPER_FUNCTION_NAME = FunctionName.PROPER;\nvar CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE;\nvar IteratorPrototype = IteratorsCore.IteratorPrototype;\nvar BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;\nvar ITERATOR = wellKnownSymbol('iterator');\nvar KEYS = 'keys';\nvar VALUES = 'values';\nvar ENTRIES = 'entries';\n\nvar returnThis = function returnThis() {\n return this;\n};\n\nmodule.exports = function (Iterable, NAME, IteratorConstructor, next, DEFAULT, IS_SET, FORCED) {\n createIteratorConstructor(IteratorConstructor, NAME, next);\n\n var getIterationMethod = function getIterationMethod(KIND) {\n if (KIND === DEFAULT && defaultIterator) return defaultIterator;\n if (!BUGGY_SAFARI_ITERATORS && KIND && KIND in IterablePrototype) return IterablePrototype[KIND];\n\n switch (KIND) {\n case KEYS:\n return function keys() {\n return new IteratorConstructor(this, KIND);\n };\n\n case VALUES:\n return function values() {\n return new IteratorConstructor(this, KIND);\n };\n\n case ENTRIES:\n return function entries() {\n return new IteratorConstructor(this, KIND);\n };\n }\n\n return function () {\n return new IteratorConstructor(this);\n };\n };\n\n var TO_STRING_TAG = NAME + ' Iterator';\n var INCORRECT_VALUES_NAME = false;\n var IterablePrototype = Iterable.prototype;\n var nativeIterator = IterablePrototype[ITERATOR] || IterablePrototype['@@iterator'] || DEFAULT && IterablePrototype[DEFAULT];\n var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);\n var anyNativeIterator = NAME === 'Array' ? IterablePrototype.entries || nativeIterator : nativeIterator;\n var CurrentIteratorPrototype, methods, KEY; // fix native\n\n if (anyNativeIterator) {\n CurrentIteratorPrototype = getPrototypeOf(anyNativeIterator.call(new Iterable()));\n\n if (CurrentIteratorPrototype !== Object.prototype && CurrentIteratorPrototype.next) {\n if (!IS_PURE && getPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype) {\n if (setPrototypeOf) {\n setPrototypeOf(CurrentIteratorPrototype, IteratorPrototype);\n } else if (!isCallable(CurrentIteratorPrototype[ITERATOR])) {\n defineBuiltIn(CurrentIteratorPrototype, ITERATOR, returnThis);\n }\n } // Set @@toStringTag to native iterators\n\n\n setToStringTag(CurrentIteratorPrototype, TO_STRING_TAG, true, true);\n if (IS_PURE) Iterators[TO_STRING_TAG] = returnThis;\n }\n } // fix Array.prototype.{ values, @@iterator }.name in V8 / FF\n\n\n if (PROPER_FUNCTION_NAME && DEFAULT === VALUES && nativeIterator && nativeIterator.name !== VALUES) {\n if (!IS_PURE && CONFIGURABLE_FUNCTION_NAME) {\n createNonEnumerableProperty(IterablePrototype, 'name', VALUES);\n } else {\n INCORRECT_VALUES_NAME = true;\n\n defaultIterator = function values() {\n return call(nativeIterator, this);\n };\n }\n } // export additional methods\n\n\n if (DEFAULT) {\n methods = {\n values: getIterationMethod(VALUES),\n keys: IS_SET ? defaultIterator : getIterationMethod(KEYS),\n entries: getIterationMethod(ENTRIES)\n };\n if (FORCED) for (KEY in methods) {\n if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {\n defineBuiltIn(IterablePrototype, KEY, methods[KEY]);\n }\n } else $({\n target: NAME,\n proto: true,\n forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME\n }, methods);\n } // define iterator\n\n\n if ((!IS_PURE || FORCED) && IterablePrototype[ITERATOR] !== defaultIterator) {\n defineBuiltIn(IterablePrototype, ITERATOR, defaultIterator, {\n name: DEFAULT\n });\n }\n\n Iterators[NAME] = defaultIterator;\n return methods;\n};","'use strict';\n\nvar fails = require('../internals/fails');\n\nvar isCallable = require('../internals/is-callable');\n\nvar isObject = require('../internals/is-object');\n\nvar create = require('../internals/object-create');\n\nvar getPrototypeOf = require('../internals/object-get-prototype-of');\n\nvar defineBuiltIn = require('../internals/define-built-in');\n\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar IS_PURE = require('../internals/is-pure');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar BUGGY_SAFARI_ITERATORS = false; // `%IteratorPrototype%` object\n// https://tc39.es/ecma262/#sec-%iteratorprototype%-object\n\nvar IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator;\n/* eslint-disable es/no-array-prototype-keys -- safe */\n\nif ([].keys) {\n arrayIterator = [].keys(); // Safari 8 has buggy iterators w/o `next`\n\n if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true;else {\n PrototypeOfArrayIteratorPrototype = getPrototypeOf(getPrototypeOf(arrayIterator));\n if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype = PrototypeOfArrayIteratorPrototype;\n }\n}\n\nvar NEW_ITERATOR_PROTOTYPE = !isObject(IteratorPrototype) || fails(function () {\n var test = {}; // FF44- legacy iterators case\n\n return IteratorPrototype[ITERATOR].call(test) !== test;\n});\nif (NEW_ITERATOR_PROTOTYPE) IteratorPrototype = {};else if (IS_PURE) IteratorPrototype = create(IteratorPrototype); // `%IteratorPrototype%[@@iterator]()` method\n// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator\n\nif (!isCallable(IteratorPrototype[ITERATOR])) {\n defineBuiltIn(IteratorPrototype, ITERATOR, function () {\n return this;\n });\n}\n\nmodule.exports = {\n IteratorPrototype: IteratorPrototype,\n BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS\n};","'use strict'; // `CreateIterResultObject` abstract operation\n// https://tc39.es/ecma262/#sec-createiterresultobject\n\nmodule.exports = function (value, done) {\n return {\n value: value,\n done: done\n };\n};","var defineProperty = require('./_defineProperty');\n/**\n * The base implementation of `assignValue` and `assignMergeValue` without\n * value checks.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\n\n\nfunction baseAssignValue(object, key, value) {\n if (key == '__proto__' && defineProperty) {\n defineProperty(object, key, {\n 'configurable': true,\n 'enumerable': true,\n 'value': value,\n 'writable': true\n });\n } else {\n object[key] = value;\n }\n}\n\nmodule.exports = baseAssignValue;","var getNative = require('./_getNative');\n\nvar defineProperty = function () {\n try {\n var func = getNative(Object, 'defineProperty');\n func({}, '', {});\n return func;\n } catch (e) {}\n}();\n\nmodule.exports = defineProperty;","var baseGetTag = require('./_baseGetTag'),\n isObject = require('./isObject');\n/** `Object#toString` result references. */\n\n\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\n\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n } // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n\n\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nmodule.exports = isFunction;","/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\nmodule.exports = freeGlobal;","/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n/** Used to resolve the decompiled source of functions. */\n\nvar funcToString = funcProto.toString;\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\n\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n\n try {\n return func + '';\n } catch (e) {}\n }\n\n return '';\n}\n\nmodule.exports = toSource;","/**\n * This method returns the first argument it receives.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Util\n * @param {*} value Any value.\n * @returns {*} Returns `value`.\n * @example\n *\n * var object = { 'a': 1 };\n *\n * console.log(_.identity(object) === object);\n * // => true\n */\nfunction identity(value) {\n return value;\n}\n\nmodule.exports = identity;","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\n\nfunction isLength(value) {\n return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nmodule.exports = isLength;","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n/** Used to detect unsigned integer values. */\n\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\n\nfunction isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n return !!length && (type == 'number' || type != 'symbol' && reIsUint.test(value)) && value > -1 && value % 1 == 0 && value < length;\n}\n\nmodule.exports = isIndex;","var baseTimes = require('./_baseTimes'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isIndex = require('./_isIndex'),\n isTypedArray = require('./isTypedArray');\n/** Used for built-in method references. */\n\n\nvar objectProto = Object.prototype;\n/** Used to check objects for own properties. */\n\nvar hasOwnProperty = objectProto.hasOwnProperty;\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\n\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) && !(skipIndexes && ( // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' || // Node.js 0.10 has enumerable non-index properties on buffers.\n isBuff && (key == 'offset' || key == 'parent') || // PhantomJS 2 has enumerable non-index properties on typed arrays.\n isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset') || // Skip index properties.\n isIndex(key, length)))) {\n result.push(key);\n }\n }\n\n return result;\n}\n\nmodule.exports = arrayLikeKeys;","var root = require('./_root'),\n stubFalse = require('./stubFalse');\n/** Detect free variable `exports`. */\n\n\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n/** Detect free variable `module`. */\n\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n/** Detect the popular CommonJS extension `module.exports`. */\n\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n/** Built-in value references. */\n\nvar Buffer = moduleExports ? root.Buffer : undefined;\n/* Built-in method references for those with the same name as other `lodash` methods. */\n\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\n\nvar isBuffer = nativeIsBuffer || stubFalse;\nmodule.exports = isBuffer;","/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function (arg) {\n return func(transform(arg));\n };\n}\n\nmodule.exports = overArg;","/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\nmodule.exports = stubArray;","var arrayPush = require('./_arrayPush'),\n getPrototype = require('./_getPrototype'),\n getSymbols = require('./_getSymbols'),\n stubArray = require('./stubArray');\n/* Built-in method references for those with the same name as other `lodash` methods. */\n\n\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n/**\n * Creates an array of the own and inherited enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\n\nvar getSymbolsIn = !nativeGetSymbols ? stubArray : function (object) {\n var result = [];\n\n while (object) {\n arrayPush(result, getSymbols(object));\n object = getPrototype(object);\n }\n\n return result;\n};\nmodule.exports = getSymbolsIn;","/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n\n return array;\n}\n\nmodule.exports = arrayPush;","var overArg = require('./_overArg');\n/** Built-in value references. */\n\n\nvar getPrototype = overArg(Object.getPrototypeOf, Object);\nmodule.exports = getPrototype;","var arrayPush = require('./_arrayPush'),\n isArray = require('./isArray');\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\n\n\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nmodule.exports = baseGetAllKeys;","/**\n * Helper function for iterating over a collection\n *\n * @param collection\n * @param fn\n */\nfunction each(collection, fn) {\n var i = 0,\n length = collection.length,\n cont;\n\n for (i; i < length; i++) {\n cont = fn(collection[i], i);\n\n if (cont === false) {\n break; //allow early exit\n }\n }\n}\n/**\n * Helper function for determining whether target object is an array\n *\n * @param target the object under test\n * @return {Boolean} true if array, false otherwise\n */\n\n\nfunction isArray(target) {\n return Object.prototype.toString.apply(target) === '[object Array]';\n}\n/**\n * Helper function for determining whether target object is a function\n *\n * @param target the object under test\n * @return {Boolean} true if function, false otherwise\n */\n\n\nfunction isFunction(target) {\n return typeof target === 'function';\n}\n\nmodule.exports = {\n isFunction: isFunction,\n isArray: isArray,\n each: each\n};","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = convertNodeToElement;\n\nvar _elementTypes = require('./elementTypes');\n\nvar _elementTypes2 = _interopRequireDefault(_elementTypes);\n\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n/**\n * Converts a htmlparser2 node to a React element\n *\n * @param {Object} node The htmlparser2 node to convert\n * @param {Number} index The index of the current node\n * @param {Function} transform Transform function to apply to children of the node\n * @returns {React.Element}\n */\n\n\nfunction convertNodeToElement(node, index, transform) {\n return _elementTypes2.default[node.type](node, index, transform);\n}","var Tokenizer = require(\"./Tokenizer.js\");\n/*\n\tOptions:\n\n\txmlMode: Disables the special behavior for script/style tags (false by default)\n\tlowerCaseAttributeNames: call .toLowerCase for each attribute name (true if xmlMode is `false`)\n\tlowerCaseTags: call .toLowerCase for each tag name (true if xmlMode is `false`)\n*/\n\n/*\n\tCallbacks:\n\n\toncdataend,\n\toncdatastart,\n\tonclosetag,\n\toncomment,\n\toncommentend,\n\tonerror,\n\tonopentag,\n\tonprocessinginstruction,\n\tonreset,\n\tontext\n*/\n\n\nvar formTags = {\n input: true,\n option: true,\n optgroup: true,\n select: true,\n button: true,\n datalist: true,\n textarea: true\n};\nvar openImpliesClose = {\n tr: {\n tr: true,\n th: true,\n td: true\n },\n th: {\n th: true\n },\n td: {\n thead: true,\n th: true,\n td: true\n },\n body: {\n head: true,\n link: true,\n script: true\n },\n li: {\n li: true\n },\n p: {\n p: true\n },\n h1: {\n p: true\n },\n h2: {\n p: true\n },\n h3: {\n p: true\n },\n h4: {\n p: true\n },\n h5: {\n p: true\n },\n h6: {\n p: true\n },\n select: formTags,\n input: formTags,\n output: formTags,\n button: formTags,\n datalist: formTags,\n textarea: formTags,\n option: {\n option: true\n },\n optgroup: {\n optgroup: true\n }\n};\nvar voidElements = {\n __proto__: null,\n area: true,\n base: true,\n basefont: true,\n br: true,\n col: true,\n command: true,\n embed: true,\n frame: true,\n hr: true,\n img: true,\n input: true,\n isindex: true,\n keygen: true,\n link: true,\n meta: true,\n param: true,\n source: true,\n track: true,\n wbr: true\n};\nvar foreignContextElements = {\n __proto__: null,\n math: true,\n svg: true\n};\nvar htmlIntegrationElements = {\n __proto__: null,\n mi: true,\n mo: true,\n mn: true,\n ms: true,\n mtext: true,\n \"annotation-xml\": true,\n foreignObject: true,\n desc: true,\n title: true\n};\nvar re_nameEnd = /\\s|\\//;\n\nfunction Parser(cbs, options) {\n this._options = options || {};\n this._cbs = cbs || {};\n this._tagname = \"\";\n this._attribname = \"\";\n this._attribvalue = \"\";\n this._attribs = null;\n this._stack = [];\n this._foreignContext = [];\n this.startIndex = 0;\n this.endIndex = null;\n this._lowerCaseTagNames = \"lowerCaseTags\" in this._options ? !!this._options.lowerCaseTags : !this._options.xmlMode;\n this._lowerCaseAttributeNames = \"lowerCaseAttributeNames\" in this._options ? !!this._options.lowerCaseAttributeNames : !this._options.xmlMode;\n\n if (this._options.Tokenizer) {\n Tokenizer = this._options.Tokenizer;\n }\n\n this._tokenizer = new Tokenizer(this._options, this);\n if (this._cbs.onparserinit) this._cbs.onparserinit(this);\n}\n\nrequire(\"inherits\")(Parser, require(\"events\").EventEmitter);\n\nParser.prototype._updatePosition = function (initialOffset) {\n if (this.endIndex === null) {\n if (this._tokenizer._sectionStart <= initialOffset) {\n this.startIndex = 0;\n } else {\n this.startIndex = this._tokenizer._sectionStart - initialOffset;\n }\n } else this.startIndex = this.endIndex + 1;\n\n this.endIndex = this._tokenizer.getAbsoluteIndex();\n}; //Tokenizer event handlers\n\n\nParser.prototype.ontext = function (data) {\n this._updatePosition(1);\n\n this.endIndex--;\n if (this._cbs.ontext) this._cbs.ontext(data);\n};\n\nParser.prototype.onopentagname = function (name) {\n if (this._lowerCaseTagNames) {\n name = name.toLowerCase();\n }\n\n this._tagname = name;\n\n if (!this._options.xmlMode && name in openImpliesClose) {\n for (var el; (el = this._stack[this._stack.length - 1]) in openImpliesClose[name]; this.onclosetag(el)) {\n ;\n }\n }\n\n if (this._options.xmlMode || !(name in voidElements)) {\n this._stack.push(name);\n\n if (name in foreignContextElements) this._foreignContext.push(true);else if (name in htmlIntegrationElements) this._foreignContext.push(false);\n }\n\n if (this._cbs.onopentagname) this._cbs.onopentagname(name);\n if (this._cbs.onopentag) this._attribs = {};\n};\n\nParser.prototype.onopentagend = function () {\n this._updatePosition(1);\n\n if (this._attribs) {\n if (this._cbs.onopentag) this._cbs.onopentag(this._tagname, this._attribs);\n this._attribs = null;\n }\n\n if (!this._options.xmlMode && this._cbs.onclosetag && this._tagname in voidElements) {\n this._cbs.onclosetag(this._tagname);\n }\n\n this._tagname = \"\";\n};\n\nParser.prototype.onclosetag = function (name) {\n this._updatePosition(1);\n\n if (this._lowerCaseTagNames) {\n name = name.toLowerCase();\n }\n\n if (name in foreignContextElements || name in htmlIntegrationElements) {\n this._foreignContext.pop();\n }\n\n if (this._stack.length && (!(name in voidElements) || this._options.xmlMode)) {\n var pos = this._stack.lastIndexOf(name);\n\n if (pos !== -1) {\n if (this._cbs.onclosetag) {\n pos = this._stack.length - pos;\n\n while (pos--) {\n this._cbs.onclosetag(this._stack.pop());\n }\n } else this._stack.length = pos;\n } else if (name === \"p\" && !this._options.xmlMode) {\n this.onopentagname(name);\n\n this._closeCurrentTag();\n }\n } else if (!this._options.xmlMode && (name === \"br\" || name === \"p\")) {\n this.onopentagname(name);\n\n this._closeCurrentTag();\n }\n};\n\nParser.prototype.onselfclosingtag = function () {\n if (this._options.xmlMode || this._options.recognizeSelfClosing || this._foreignContext[this._foreignContext.length - 1]) {\n this._closeCurrentTag();\n } else {\n this.onopentagend();\n }\n};\n\nParser.prototype._closeCurrentTag = function () {\n var name = this._tagname;\n this.onopentagend(); //self-closing tags will be on the top of the stack\n //(cheaper check than in onclosetag)\n\n if (this._stack[this._stack.length - 1] === name) {\n if (this._cbs.onclosetag) {\n this._cbs.onclosetag(name);\n }\n\n this._stack.pop();\n }\n};\n\nParser.prototype.onattribname = function (name) {\n if (this._lowerCaseAttributeNames) {\n name = name.toLowerCase();\n }\n\n this._attribname = name;\n};\n\nParser.prototype.onattribdata = function (value) {\n this._attribvalue += value;\n};\n\nParser.prototype.onattribend = function () {\n if (this._cbs.onattribute) this._cbs.onattribute(this._attribname, this._attribvalue);\n\n if (this._attribs && !Object.prototype.hasOwnProperty.call(this._attribs, this._attribname)) {\n this._attribs[this._attribname] = this._attribvalue;\n }\n\n this._attribname = \"\";\n this._attribvalue = \"\";\n};\n\nParser.prototype._getInstructionName = function (value) {\n var idx = value.search(re_nameEnd),\n name = idx < 0 ? value : value.substr(0, idx);\n\n if (this._lowerCaseTagNames) {\n name = name.toLowerCase();\n }\n\n return name;\n};\n\nParser.prototype.ondeclaration = function (value) {\n if (this._cbs.onprocessinginstruction) {\n var name = this._getInstructionName(value);\n\n this._cbs.onprocessinginstruction(\"!\" + name, \"!\" + value);\n }\n};\n\nParser.prototype.onprocessinginstruction = function (value) {\n if (this._cbs.onprocessinginstruction) {\n var name = this._getInstructionName(value);\n\n this._cbs.onprocessinginstruction(\"?\" + name, \"?\" + value);\n }\n};\n\nParser.prototype.oncomment = function (value) {\n this._updatePosition(4);\n\n if (this._cbs.oncomment) this._cbs.oncomment(value);\n if (this._cbs.oncommentend) this._cbs.oncommentend();\n};\n\nParser.prototype.oncdata = function (value) {\n this._updatePosition(1);\n\n if (this._options.xmlMode || this._options.recognizeCDATA) {\n if (this._cbs.oncdatastart) this._cbs.oncdatastart();\n if (this._cbs.ontext) this._cbs.ontext(value);\n if (this._cbs.oncdataend) this._cbs.oncdataend();\n } else {\n this.oncomment(\"[CDATA[\" + value + \"]]\");\n }\n};\n\nParser.prototype.onerror = function (err) {\n if (this._cbs.onerror) this._cbs.onerror(err);\n};\n\nParser.prototype.onend = function () {\n if (this._cbs.onclosetag) {\n for (var i = this._stack.length; i > 0; this._cbs.onclosetag(this._stack[--i])) {\n ;\n }\n }\n\n if (this._cbs.onend) this._cbs.onend();\n}; //Resets the parser to a blank state, ready to parse a new HTML document\n\n\nParser.prototype.reset = function () {\n if (this._cbs.onreset) this._cbs.onreset();\n\n this._tokenizer.reset();\n\n this._tagname = \"\";\n this._attribname = \"\";\n this._attribs = null;\n this._stack = [];\n if (this._cbs.onparserinit) this._cbs.onparserinit(this);\n}; //Parses a complete HTML document and pushes it to the handler\n\n\nParser.prototype.parseComplete = function (data) {\n this.reset();\n this.end(data);\n};\n\nParser.prototype.write = function (chunk) {\n this._tokenizer.write(chunk);\n};\n\nParser.prototype.end = function (chunk) {\n this._tokenizer.end(chunk);\n};\n\nParser.prototype.pause = function () {\n this._tokenizer.pause();\n};\n\nParser.prototype.resume = function () {\n this._tokenizer.resume();\n}; //alias for backwards compat\n\n\nParser.prototype.parseChunk = Parser.prototype.write;\nParser.prototype.done = Parser.prototype.end;\nmodule.exports = Parser;","module.exports = Tokenizer;\n\nvar decodeCodePoint = require(\"entities/lib/decode_codepoint.js\");\n\nvar entityMap = require(\"entities/maps/entities.json\");\n\nvar legacyMap = require(\"entities/maps/legacy.json\");\n\nvar xmlMap = require(\"entities/maps/xml.json\");\n\nvar i = 0;\nvar TEXT = i++;\nvar BEFORE_TAG_NAME = i++; //after <\n\nvar IN_TAG_NAME = i++;\nvar IN_SELF_CLOSING_TAG = i++;\nvar BEFORE_CLOSING_TAG_NAME = i++;\nvar IN_CLOSING_TAG_NAME = i++;\nvar AFTER_CLOSING_TAG_NAME = i++; //attributes\n\nvar BEFORE_ATTRIBUTE_NAME = i++;\nvar IN_ATTRIBUTE_NAME = i++;\nvar AFTER_ATTRIBUTE_NAME = i++;\nvar BEFORE_ATTRIBUTE_VALUE = i++;\nvar IN_ATTRIBUTE_VALUE_DQ = i++; // \"\n\nvar IN_ATTRIBUTE_VALUE_SQ = i++; // '\n\nvar IN_ATTRIBUTE_VALUE_NQ = i++; //declarations\n\nvar BEFORE_DECLARATION = i++; // !\n\nvar IN_DECLARATION = i++; //processing instructions\n\nvar IN_PROCESSING_INSTRUCTION = i++; // ?\n//comments\n\nvar BEFORE_COMMENT = i++;\nvar IN_COMMENT = i++;\nvar AFTER_COMMENT_1 = i++;\nvar AFTER_COMMENT_2 = i++; //cdata\n\nvar BEFORE_CDATA_1 = i++; // [\n\nvar BEFORE_CDATA_2 = i++; // C\n\nvar BEFORE_CDATA_3 = i++; // D\n\nvar BEFORE_CDATA_4 = i++; // A\n\nvar BEFORE_CDATA_5 = i++; // T\n\nvar BEFORE_CDATA_6 = i++; // A\n\nvar IN_CDATA = i++; // [\n\nvar AFTER_CDATA_1 = i++; // ]\n\nvar AFTER_CDATA_2 = i++; // ]\n//special tags\n\nvar BEFORE_SPECIAL = i++; //S\n\nvar BEFORE_SPECIAL_END = i++; //S\n\nvar BEFORE_SCRIPT_1 = i++; //C\n\nvar BEFORE_SCRIPT_2 = i++; //R\n\nvar BEFORE_SCRIPT_3 = i++; //I\n\nvar BEFORE_SCRIPT_4 = i++; //P\n\nvar BEFORE_SCRIPT_5 = i++; //T\n\nvar AFTER_SCRIPT_1 = i++; //C\n\nvar AFTER_SCRIPT_2 = i++; //R\n\nvar AFTER_SCRIPT_3 = i++; //I\n\nvar AFTER_SCRIPT_4 = i++; //P\n\nvar AFTER_SCRIPT_5 = i++; //T\n\nvar BEFORE_STYLE_1 = i++; //T\n\nvar BEFORE_STYLE_2 = i++; //Y\n\nvar BEFORE_STYLE_3 = i++; //L\n\nvar BEFORE_STYLE_4 = i++; //E\n\nvar AFTER_STYLE_1 = i++; //T\n\nvar AFTER_STYLE_2 = i++; //Y\n\nvar AFTER_STYLE_3 = i++; //L\n\nvar AFTER_STYLE_4 = i++; //E\n\nvar BEFORE_ENTITY = i++; //&\n\nvar BEFORE_NUMERIC_ENTITY = i++; //#\n\nvar IN_NAMED_ENTITY = i++;\nvar IN_NUMERIC_ENTITY = i++;\nvar IN_HEX_ENTITY = i++; //X\n\nvar j = 0;\nvar SPECIAL_NONE = j++;\nvar SPECIAL_SCRIPT = j++;\nvar SPECIAL_STYLE = j++;\n\nfunction whitespace(c) {\n return c === \" \" || c === \"\\n\" || c === \"\\t\" || c === \"\\f\" || c === \"\\r\";\n}\n\nfunction ifElseState(upper, SUCCESS, FAILURE) {\n var lower = upper.toLowerCase();\n\n if (upper === lower) {\n return function (c) {\n if (c === lower) {\n this._state = SUCCESS;\n } else {\n this._state = FAILURE;\n this._index--;\n }\n };\n } else {\n return function (c) {\n if (c === lower || c === upper) {\n this._state = SUCCESS;\n } else {\n this._state = FAILURE;\n this._index--;\n }\n };\n }\n}\n\nfunction consumeSpecialNameChar(upper, NEXT_STATE) {\n var lower = upper.toLowerCase();\n return function (c) {\n if (c === lower || c === upper) {\n this._state = NEXT_STATE;\n } else {\n this._state = IN_TAG_NAME;\n this._index--; //consume the token again\n }\n };\n}\n\nfunction Tokenizer(options, cbs) {\n this._state = TEXT;\n this._buffer = \"\";\n this._sectionStart = 0;\n this._index = 0;\n this._bufferOffset = 0; //chars removed from _buffer\n\n this._baseState = TEXT;\n this._special = SPECIAL_NONE;\n this._cbs = cbs;\n this._running = true;\n this._ended = false;\n this._xmlMode = !!(options && options.xmlMode);\n this._decodeEntities = !!(options && options.decodeEntities);\n}\n\nTokenizer.prototype._stateText = function (c) {\n if (c === \"<\") {\n if (this._index > this._sectionStart) {\n this._cbs.ontext(this._getSection());\n }\n\n this._state = BEFORE_TAG_NAME;\n this._sectionStart = this._index;\n } else if (this._decodeEntities && this._special === SPECIAL_NONE && c === \"&\") {\n if (this._index > this._sectionStart) {\n this._cbs.ontext(this._getSection());\n }\n\n this._baseState = TEXT;\n this._state = BEFORE_ENTITY;\n this._sectionStart = this._index;\n }\n};\n\nTokenizer.prototype._stateBeforeTagName = function (c) {\n if (c === \"/\") {\n this._state = BEFORE_CLOSING_TAG_NAME;\n } else if (c === \"<\") {\n this._cbs.ontext(this._getSection());\n\n this._sectionStart = this._index;\n } else if (c === \">\" || this._special !== SPECIAL_NONE || whitespace(c)) {\n this._state = TEXT;\n } else if (c === \"!\") {\n this._state = BEFORE_DECLARATION;\n this._sectionStart = this._index + 1;\n } else if (c === \"?\") {\n this._state = IN_PROCESSING_INSTRUCTION;\n this._sectionStart = this._index + 1;\n } else {\n this._state = !this._xmlMode && (c === \"s\" || c === \"S\") ? BEFORE_SPECIAL : IN_TAG_NAME;\n this._sectionStart = this._index;\n }\n};\n\nTokenizer.prototype._stateInTagName = function (c) {\n if (c === \"/\" || c === \">\" || whitespace(c)) {\n this._emitToken(\"onopentagname\");\n\n this._state = BEFORE_ATTRIBUTE_NAME;\n this._index--;\n }\n};\n\nTokenizer.prototype._stateBeforeCloseingTagName = function (c) {\n if (whitespace(c)) ;else if (c === \">\") {\n this._state = TEXT;\n } else if (this._special !== SPECIAL_NONE) {\n if (c === \"s\" || c === \"S\") {\n this._state = BEFORE_SPECIAL_END;\n } else {\n this._state = TEXT;\n this._index--;\n }\n } else {\n this._state = IN_CLOSING_TAG_NAME;\n this._sectionStart = this._index;\n }\n};\n\nTokenizer.prototype._stateInCloseingTagName = function (c) {\n if (c === \">\" || whitespace(c)) {\n this._emitToken(\"onclosetag\");\n\n this._state = AFTER_CLOSING_TAG_NAME;\n this._index--;\n }\n};\n\nTokenizer.prototype._stateAfterCloseingTagName = function (c) {\n //skip everything until \">\"\n if (c === \">\") {\n this._state = TEXT;\n this._sectionStart = this._index + 1;\n }\n};\n\nTokenizer.prototype._stateBeforeAttributeName = function (c) {\n if (c === \">\") {\n this._cbs.onopentagend();\n\n this._state = TEXT;\n this._sectionStart = this._index + 1;\n } else if (c === \"/\") {\n this._state = IN_SELF_CLOSING_TAG;\n } else if (!whitespace(c)) {\n this._state = IN_ATTRIBUTE_NAME;\n this._sectionStart = this._index;\n }\n};\n\nTokenizer.prototype._stateInSelfClosingTag = function (c) {\n if (c === \">\") {\n this._cbs.onselfclosingtag();\n\n this._state = TEXT;\n this._sectionStart = this._index + 1;\n } else if (!whitespace(c)) {\n this._state = BEFORE_ATTRIBUTE_NAME;\n this._index--;\n }\n};\n\nTokenizer.prototype._stateInAttributeName = function (c) {\n if (c === \"=\" || c === \"/\" || c === \">\" || whitespace(c)) {\n this._cbs.onattribname(this._getSection());\n\n this._sectionStart = -1;\n this._state = AFTER_ATTRIBUTE_NAME;\n this._index--;\n }\n};\n\nTokenizer.prototype._stateAfterAttributeName = function (c) {\n if (c === \"=\") {\n this._state = BEFORE_ATTRIBUTE_VALUE;\n } else if (c === \"/\" || c === \">\") {\n this._cbs.onattribend();\n\n this._state = BEFORE_ATTRIBUTE_NAME;\n this._index--;\n } else if (!whitespace(c)) {\n this._cbs.onattribend();\n\n this._state = IN_ATTRIBUTE_NAME;\n this._sectionStart = this._index;\n }\n};\n\nTokenizer.prototype._stateBeforeAttributeValue = function (c) {\n if (c === '\"') {\n this._state = IN_ATTRIBUTE_VALUE_DQ;\n this._sectionStart = this._index + 1;\n } else if (c === \"'\") {\n this._state = IN_ATTRIBUTE_VALUE_SQ;\n this._sectionStart = this._index + 1;\n } else if (!whitespace(c)) {\n this._state = IN_ATTRIBUTE_VALUE_NQ;\n this._sectionStart = this._index;\n this._index--; //reconsume token\n }\n};\n\nTokenizer.prototype._stateInAttributeValueDoubleQuotes = function (c) {\n if (c === '\"') {\n this._emitToken(\"onattribdata\");\n\n this._cbs.onattribend();\n\n this._state = BEFORE_ATTRIBUTE_NAME;\n } else if (this._decodeEntities && c === \"&\") {\n this._emitToken(\"onattribdata\");\n\n this._baseState = this._state;\n this._state = BEFORE_ENTITY;\n this._sectionStart = this._index;\n }\n};\n\nTokenizer.prototype._stateInAttributeValueSingleQuotes = function (c) {\n if (c === \"'\") {\n this._emitToken(\"onattribdata\");\n\n this._cbs.onattribend();\n\n this._state = BEFORE_ATTRIBUTE_NAME;\n } else if (this._decodeEntities && c === \"&\") {\n this._emitToken(\"onattribdata\");\n\n this._baseState = this._state;\n this._state = BEFORE_ENTITY;\n this._sectionStart = this._index;\n }\n};\n\nTokenizer.prototype._stateInAttributeValueNoQuotes = function (c) {\n if (whitespace(c) || c === \">\") {\n this._emitToken(\"onattribdata\");\n\n this._cbs.onattribend();\n\n this._state = BEFORE_ATTRIBUTE_NAME;\n this._index--;\n } else if (this._decodeEntities && c === \"&\") {\n this._emitToken(\"onattribdata\");\n\n this._baseState = this._state;\n this._state = BEFORE_ENTITY;\n this._sectionStart = this._index;\n }\n};\n\nTokenizer.prototype._stateBeforeDeclaration = function (c) {\n this._state = c === \"[\" ? BEFORE_CDATA_1 : c === \"-\" ? BEFORE_COMMENT : IN_DECLARATION;\n};\n\nTokenizer.prototype._stateInDeclaration = function (c) {\n if (c === \">\") {\n this._cbs.ondeclaration(this._getSection());\n\n this._state = TEXT;\n this._sectionStart = this._index + 1;\n }\n};\n\nTokenizer.prototype._stateInProcessingInstruction = function (c) {\n if (c === \">\") {\n this._cbs.onprocessinginstruction(this._getSection());\n\n this._state = TEXT;\n this._sectionStart = this._index + 1;\n }\n};\n\nTokenizer.prototype._stateBeforeComment = function (c) {\n if (c === \"-\") {\n this._state = IN_COMMENT;\n this._sectionStart = this._index + 1;\n } else {\n this._state = IN_DECLARATION;\n }\n};\n\nTokenizer.prototype._stateInComment = function (c) {\n if (c === \"-\") this._state = AFTER_COMMENT_1;\n};\n\nTokenizer.prototype._stateAfterComment1 = function (c) {\n if (c === \"-\") {\n this._state = AFTER_COMMENT_2;\n } else {\n this._state = IN_COMMENT;\n }\n};\n\nTokenizer.prototype._stateAfterComment2 = function (c) {\n if (c === \">\") {\n //remove 2 trailing chars\n this._cbs.oncomment(this._buffer.substring(this._sectionStart, this._index - 2));\n\n this._state = TEXT;\n this._sectionStart = this._index + 1;\n } else if (c !== \"-\") {\n this._state = IN_COMMENT;\n } // else: stay in AFTER_COMMENT_2 (`--->`)\n\n};\n\nTokenizer.prototype._stateBeforeCdata1 = ifElseState(\"C\", BEFORE_CDATA_2, IN_DECLARATION);\nTokenizer.prototype._stateBeforeCdata2 = ifElseState(\"D\", BEFORE_CDATA_3, IN_DECLARATION);\nTokenizer.prototype._stateBeforeCdata3 = ifElseState(\"A\", BEFORE_CDATA_4, IN_DECLARATION);\nTokenizer.prototype._stateBeforeCdata4 = ifElseState(\"T\", BEFORE_CDATA_5, IN_DECLARATION);\nTokenizer.prototype._stateBeforeCdata5 = ifElseState(\"A\", BEFORE_CDATA_6, IN_DECLARATION);\n\nTokenizer.prototype._stateBeforeCdata6 = function (c) {\n if (c === \"[\") {\n this._state = IN_CDATA;\n this._sectionStart = this._index + 1;\n } else {\n this._state = IN_DECLARATION;\n this._index--;\n }\n};\n\nTokenizer.prototype._stateInCdata = function (c) {\n if (c === \"]\") this._state = AFTER_CDATA_1;\n};\n\nTokenizer.prototype._stateAfterCdata1 = function (c) {\n if (c === \"]\") this._state = AFTER_CDATA_2;else this._state = IN_CDATA;\n};\n\nTokenizer.prototype._stateAfterCdata2 = function (c) {\n if (c === \">\") {\n //remove 2 trailing chars\n this._cbs.oncdata(this._buffer.substring(this._sectionStart, this._index - 2));\n\n this._state = TEXT;\n this._sectionStart = this._index + 1;\n } else if (c !== \"]\") {\n this._state = IN_CDATA;\n } //else: stay in AFTER_CDATA_2 (`]]]>`)\n\n};\n\nTokenizer.prototype._stateBeforeSpecial = function (c) {\n if (c === \"c\" || c === \"C\") {\n this._state = BEFORE_SCRIPT_1;\n } else if (c === \"t\" || c === \"T\") {\n this._state = BEFORE_STYLE_1;\n } else {\n this._state = IN_TAG_NAME;\n this._index--; //consume the token again\n }\n};\n\nTokenizer.prototype._stateBeforeSpecialEnd = function (c) {\n if (this._special === SPECIAL_SCRIPT && (c === \"c\" || c === \"C\")) {\n this._state = AFTER_SCRIPT_1;\n } else if (this._special === SPECIAL_STYLE && (c === \"t\" || c === \"T\")) {\n this._state = AFTER_STYLE_1;\n } else this._state = TEXT;\n};\n\nTokenizer.prototype._stateBeforeScript1 = consumeSpecialNameChar(\"R\", BEFORE_SCRIPT_2);\nTokenizer.prototype._stateBeforeScript2 = consumeSpecialNameChar(\"I\", BEFORE_SCRIPT_3);\nTokenizer.prototype._stateBeforeScript3 = consumeSpecialNameChar(\"P\", BEFORE_SCRIPT_4);\nTokenizer.prototype._stateBeforeScript4 = consumeSpecialNameChar(\"T\", BEFORE_SCRIPT_5);\n\nTokenizer.prototype._stateBeforeScript5 = function (c) {\n if (c === \"/\" || c === \">\" || whitespace(c)) {\n this._special = SPECIAL_SCRIPT;\n }\n\n this._state = IN_TAG_NAME;\n this._index--; //consume the token again\n};\n\nTokenizer.prototype._stateAfterScript1 = ifElseState(\"R\", AFTER_SCRIPT_2, TEXT);\nTokenizer.prototype._stateAfterScript2 = ifElseState(\"I\", AFTER_SCRIPT_3, TEXT);\nTokenizer.prototype._stateAfterScript3 = ifElseState(\"P\", AFTER_SCRIPT_4, TEXT);\nTokenizer.prototype._stateAfterScript4 = ifElseState(\"T\", AFTER_SCRIPT_5, TEXT);\n\nTokenizer.prototype._stateAfterScript5 = function (c) {\n if (c === \">\" || whitespace(c)) {\n this._special = SPECIAL_NONE;\n this._state = IN_CLOSING_TAG_NAME;\n this._sectionStart = this._index - 6;\n this._index--; //reconsume the token\n } else this._state = TEXT;\n};\n\nTokenizer.prototype._stateBeforeStyle1 = consumeSpecialNameChar(\"Y\", BEFORE_STYLE_2);\nTokenizer.prototype._stateBeforeStyle2 = consumeSpecialNameChar(\"L\", BEFORE_STYLE_3);\nTokenizer.prototype._stateBeforeStyle3 = consumeSpecialNameChar(\"E\", BEFORE_STYLE_4);\n\nTokenizer.prototype._stateBeforeStyle4 = function (c) {\n if (c === \"/\" || c === \">\" || whitespace(c)) {\n this._special = SPECIAL_STYLE;\n }\n\n this._state = IN_TAG_NAME;\n this._index--; //consume the token again\n};\n\nTokenizer.prototype._stateAfterStyle1 = ifElseState(\"Y\", AFTER_STYLE_2, TEXT);\nTokenizer.prototype._stateAfterStyle2 = ifElseState(\"L\", AFTER_STYLE_3, TEXT);\nTokenizer.prototype._stateAfterStyle3 = ifElseState(\"E\", AFTER_STYLE_4, TEXT);\n\nTokenizer.prototype._stateAfterStyle4 = function (c) {\n if (c === \">\" || whitespace(c)) {\n this._special = SPECIAL_NONE;\n this._state = IN_CLOSING_TAG_NAME;\n this._sectionStart = this._index - 5;\n this._index--; //reconsume the token\n } else this._state = TEXT;\n};\n\nTokenizer.prototype._stateBeforeEntity = ifElseState(\"#\", BEFORE_NUMERIC_ENTITY, IN_NAMED_ENTITY);\nTokenizer.prototype._stateBeforeNumericEntity = ifElseState(\"X\", IN_HEX_ENTITY, IN_NUMERIC_ENTITY); //for entities terminated with a semicolon\n\nTokenizer.prototype._parseNamedEntityStrict = function () {\n //offset = 1\n if (this._sectionStart + 1 < this._index) {\n var entity = this._buffer.substring(this._sectionStart + 1, this._index),\n map = this._xmlMode ? xmlMap : entityMap;\n\n if (map.hasOwnProperty(entity)) {\n this._emitPartial(map[entity]);\n\n this._sectionStart = this._index + 1;\n }\n }\n}; //parses legacy entities (without trailing semicolon)\n\n\nTokenizer.prototype._parseLegacyEntity = function () {\n var start = this._sectionStart + 1,\n limit = this._index - start;\n if (limit > 6) limit = 6; //the max length of legacy entities is 6\n\n while (limit >= 2) {\n //the min length of legacy entities is 2\n var entity = this._buffer.substr(start, limit);\n\n if (legacyMap.hasOwnProperty(entity)) {\n this._emitPartial(legacyMap[entity]);\n\n this._sectionStart += limit + 1;\n return;\n } else {\n limit--;\n }\n }\n};\n\nTokenizer.prototype._stateInNamedEntity = function (c) {\n if (c === \";\") {\n this._parseNamedEntityStrict();\n\n if (this._sectionStart + 1 < this._index && !this._xmlMode) {\n this._parseLegacyEntity();\n }\n\n this._state = this._baseState;\n } else if ((c < \"a\" || c > \"z\") && (c < \"A\" || c > \"Z\") && (c < \"0\" || c > \"9\")) {\n if (this._xmlMode) ;else if (this._sectionStart + 1 === this._index) ;else if (this._baseState !== TEXT) {\n if (c !== \"=\") {\n this._parseNamedEntityStrict();\n }\n } else {\n this._parseLegacyEntity();\n }\n this._state = this._baseState;\n this._index--;\n }\n};\n\nTokenizer.prototype._decodeNumericEntity = function (offset, base) {\n var sectionStart = this._sectionStart + offset;\n\n if (sectionStart !== this._index) {\n //parse entity\n var entity = this._buffer.substring(sectionStart, this._index);\n\n var parsed = parseInt(entity, base);\n\n this._emitPartial(decodeCodePoint(parsed));\n\n this._sectionStart = this._index;\n } else {\n this._sectionStart--;\n }\n\n this._state = this._baseState;\n};\n\nTokenizer.prototype._stateInNumericEntity = function (c) {\n if (c === \";\") {\n this._decodeNumericEntity(2, 10);\n\n this._sectionStart++;\n } else if (c < \"0\" || c > \"9\") {\n if (!this._xmlMode) {\n this._decodeNumericEntity(2, 10);\n } else {\n this._state = this._baseState;\n }\n\n this._index--;\n }\n};\n\nTokenizer.prototype._stateInHexEntity = function (c) {\n if (c === \";\") {\n this._decodeNumericEntity(3, 16);\n\n this._sectionStart++;\n } else if ((c < \"a\" || c > \"f\") && (c < \"A\" || c > \"F\") && (c < \"0\" || c > \"9\")) {\n if (!this._xmlMode) {\n this._decodeNumericEntity(3, 16);\n } else {\n this._state = this._baseState;\n }\n\n this._index--;\n }\n};\n\nTokenizer.prototype._cleanup = function () {\n if (this._sectionStart < 0) {\n this._buffer = \"\";\n this._bufferOffset += this._index;\n this._index = 0;\n } else if (this._running) {\n if (this._state === TEXT) {\n if (this._sectionStart !== this._index) {\n this._cbs.ontext(this._buffer.substr(this._sectionStart));\n }\n\n this._buffer = \"\";\n this._bufferOffset += this._index;\n this._index = 0;\n } else if (this._sectionStart === this._index) {\n //the section just started\n this._buffer = \"\";\n this._bufferOffset += this._index;\n this._index = 0;\n } else {\n //remove everything unnecessary\n this._buffer = this._buffer.substr(this._sectionStart);\n this._index -= this._sectionStart;\n this._bufferOffset += this._sectionStart;\n }\n\n this._sectionStart = 0;\n }\n}; //TODO make events conditional\n\n\nTokenizer.prototype.write = function (chunk) {\n if (this._ended) this._cbs.onerror(Error(\".write() after done!\"));\n this._buffer += chunk;\n\n this._parse();\n};\n\nTokenizer.prototype._parse = function () {\n while (this._index < this._buffer.length && this._running) {\n var c = this._buffer.charAt(this._index);\n\n if (this._state === TEXT) {\n this._stateText(c);\n } else if (this._state === BEFORE_TAG_NAME) {\n this._stateBeforeTagName(c);\n } else if (this._state === IN_TAG_NAME) {\n this._stateInTagName(c);\n } else if (this._state === BEFORE_CLOSING_TAG_NAME) {\n this._stateBeforeCloseingTagName(c);\n } else if (this._state === IN_CLOSING_TAG_NAME) {\n this._stateInCloseingTagName(c);\n } else if (this._state === AFTER_CLOSING_TAG_NAME) {\n this._stateAfterCloseingTagName(c);\n } else if (this._state === IN_SELF_CLOSING_TAG) {\n this._stateInSelfClosingTag(c);\n } else if (this._state === BEFORE_ATTRIBUTE_NAME) {\n /*\n *\tattributes\n */\n this._stateBeforeAttributeName(c);\n } else if (this._state === IN_ATTRIBUTE_NAME) {\n this._stateInAttributeName(c);\n } else if (this._state === AFTER_ATTRIBUTE_NAME) {\n this._stateAfterAttributeName(c);\n } else if (this._state === BEFORE_ATTRIBUTE_VALUE) {\n this._stateBeforeAttributeValue(c);\n } else if (this._state === IN_ATTRIBUTE_VALUE_DQ) {\n this._stateInAttributeValueDoubleQuotes(c);\n } else if (this._state === IN_ATTRIBUTE_VALUE_SQ) {\n this._stateInAttributeValueSingleQuotes(c);\n } else if (this._state === IN_ATTRIBUTE_VALUE_NQ) {\n this._stateInAttributeValueNoQuotes(c);\n } else if (this._state === BEFORE_DECLARATION) {\n /*\n *\tdeclarations\n */\n this._stateBeforeDeclaration(c);\n } else if (this._state === IN_DECLARATION) {\n this._stateInDeclaration(c);\n } else if (this._state === IN_PROCESSING_INSTRUCTION) {\n /*\n *\tprocessing instructions\n */\n this._stateInProcessingInstruction(c);\n } else if (this._state === BEFORE_COMMENT) {\n /*\n *\tcomments\n */\n this._stateBeforeComment(c);\n } else if (this._state === IN_COMMENT) {\n this._stateInComment(c);\n } else if (this._state === AFTER_COMMENT_1) {\n this._stateAfterComment1(c);\n } else if (this._state === AFTER_COMMENT_2) {\n this._stateAfterComment2(c);\n } else if (this._state === BEFORE_CDATA_1) {\n /*\n *\tcdata\n */\n this._stateBeforeCdata1(c);\n } else if (this._state === BEFORE_CDATA_2) {\n this._stateBeforeCdata2(c);\n } else if (this._state === BEFORE_CDATA_3) {\n this._stateBeforeCdata3(c);\n } else if (this._state === BEFORE_CDATA_4) {\n this._stateBeforeCdata4(c);\n } else if (this._state === BEFORE_CDATA_5) {\n this._stateBeforeCdata5(c);\n } else if (this._state === BEFORE_CDATA_6) {\n this._stateBeforeCdata6(c);\n } else if (this._state === IN_CDATA) {\n this._stateInCdata(c);\n } else if (this._state === AFTER_CDATA_1) {\n this._stateAfterCdata1(c);\n } else if (this._state === AFTER_CDATA_2) {\n this._stateAfterCdata2(c);\n } else if (this._state === BEFORE_SPECIAL) {\n /*\n * special tags\n */\n this._stateBeforeSpecial(c);\n } else if (this._state === BEFORE_SPECIAL_END) {\n this._stateBeforeSpecialEnd(c);\n } else if (this._state === BEFORE_SCRIPT_1) {\n /*\n * script\n */\n this._stateBeforeScript1(c);\n } else if (this._state === BEFORE_SCRIPT_2) {\n this._stateBeforeScript2(c);\n } else if (this._state === BEFORE_SCRIPT_3) {\n this._stateBeforeScript3(c);\n } else if (this._state === BEFORE_SCRIPT_4) {\n this._stateBeforeScript4(c);\n } else if (this._state === BEFORE_SCRIPT_5) {\n this._stateBeforeScript5(c);\n } else if (this._state === AFTER_SCRIPT_1) {\n this._stateAfterScript1(c);\n } else if (this._state === AFTER_SCRIPT_2) {\n this._stateAfterScript2(c);\n } else if (this._state === AFTER_SCRIPT_3) {\n this._stateAfterScript3(c);\n } else if (this._state === AFTER_SCRIPT_4) {\n this._stateAfterScript4(c);\n } else if (this._state === AFTER_SCRIPT_5) {\n this._stateAfterScript5(c);\n } else if (this._state === BEFORE_STYLE_1) {\n /*\n * style\n */\n this._stateBeforeStyle1(c);\n } else if (this._state === BEFORE_STYLE_2) {\n this._stateBeforeStyle2(c);\n } else if (this._state === BEFORE_STYLE_3) {\n this._stateBeforeStyle3(c);\n } else if (this._state === BEFORE_STYLE_4) {\n this._stateBeforeStyle4(c);\n } else if (this._state === AFTER_STYLE_1) {\n this._stateAfterStyle1(c);\n } else if (this._state === AFTER_STYLE_2) {\n this._stateAfterStyle2(c);\n } else if (this._state === AFTER_STYLE_3) {\n this._stateAfterStyle3(c);\n } else if (this._state === AFTER_STYLE_4) {\n this._stateAfterStyle4(c);\n } else if (this._state === BEFORE_ENTITY) {\n /*\n * entities\n */\n this._stateBeforeEntity(c);\n } else if (this._state === BEFORE_NUMERIC_ENTITY) {\n this._stateBeforeNumericEntity(c);\n } else if (this._state === IN_NAMED_ENTITY) {\n this._stateInNamedEntity(c);\n } else if (this._state === IN_NUMERIC_ENTITY) {\n this._stateInNumericEntity(c);\n } else if (this._state === IN_HEX_ENTITY) {\n this._stateInHexEntity(c);\n } else {\n this._cbs.onerror(Error(\"unknown _state\"), this._state);\n }\n\n this._index++;\n }\n\n this._cleanup();\n};\n\nTokenizer.prototype.pause = function () {\n this._running = false;\n};\n\nTokenizer.prototype.resume = function () {\n this._running = true;\n\n if (this._index < this._buffer.length) {\n this._parse();\n }\n\n if (this._ended) {\n this._finish();\n }\n};\n\nTokenizer.prototype.end = function (chunk) {\n if (this._ended) this._cbs.onerror(Error(\".end() after done!\"));\n if (chunk) this.write(chunk);\n this._ended = true;\n if (this._running) this._finish();\n};\n\nTokenizer.prototype._finish = function () {\n //if there is remaining data, emit it in a reasonable way\n if (this._sectionStart < this._index) {\n this._handleTrailingData();\n }\n\n this._cbs.onend();\n};\n\nTokenizer.prototype._handleTrailingData = function () {\n var data = this._buffer.substr(this._sectionStart);\n\n if (this._state === IN_CDATA || this._state === AFTER_CDATA_1 || this._state === AFTER_CDATA_2) {\n this._cbs.oncdata(data);\n } else if (this._state === IN_COMMENT || this._state === AFTER_COMMENT_1 || this._state === AFTER_COMMENT_2) {\n this._cbs.oncomment(data);\n } else if (this._state === IN_NAMED_ENTITY && !this._xmlMode) {\n this._parseLegacyEntity();\n\n if (this._sectionStart < this._index) {\n this._state = this._baseState;\n\n this._handleTrailingData();\n }\n } else if (this._state === IN_NUMERIC_ENTITY && !this._xmlMode) {\n this._decodeNumericEntity(2, 10);\n\n if (this._sectionStart < this._index) {\n this._state = this._baseState;\n\n this._handleTrailingData();\n }\n } else if (this._state === IN_HEX_ENTITY && !this._xmlMode) {\n this._decodeNumericEntity(3, 16);\n\n if (this._sectionStart < this._index) {\n this._state = this._baseState;\n\n this._handleTrailingData();\n }\n } else if (this._state !== IN_TAG_NAME && this._state !== BEFORE_ATTRIBUTE_NAME && this._state !== BEFORE_ATTRIBUTE_VALUE && this._state !== AFTER_ATTRIBUTE_NAME && this._state !== IN_ATTRIBUTE_NAME && this._state !== IN_ATTRIBUTE_VALUE_SQ && this._state !== IN_ATTRIBUTE_VALUE_DQ && this._state !== IN_ATTRIBUTE_VALUE_NQ && this._state !== IN_CLOSING_TAG_NAME) {\n this._cbs.ontext(data);\n } //else, ignore remaining data\n //TODO add a way to remove current tag\n\n};\n\nTokenizer.prototype.reset = function () {\n Tokenizer.call(this, {\n xmlMode: this._xmlMode,\n decodeEntities: this._decodeEntities\n }, this._cbs);\n};\n\nTokenizer.prototype.getAbsoluteIndex = function () {\n return this._bufferOffset + this._index;\n};\n\nTokenizer.prototype._getSection = function () {\n return this._buffer.substring(this._sectionStart, this._index);\n};\n\nTokenizer.prototype._emitToken = function (name) {\n this._cbs[name](this._getSection());\n\n this._sectionStart = -1;\n};\n\nTokenizer.prototype._emitPartial = function (value) {\n if (this._baseState !== TEXT) {\n this._cbs.onattribdata(value); //TODO implement the new event\n\n } else {\n this._cbs.ontext(value);\n }\n};","var decodeMap = require(\"../maps/decode.json\");\n\nmodule.exports = decodeCodePoint; // modified version of https://github.com/mathiasbynens/he/blob/master/src/he.js#L94-L119\n\nfunction decodeCodePoint(codePoint) {\n if (codePoint >= 0xd800 && codePoint <= 0xdfff || codePoint > 0x10ffff) {\n return \"\\uFFFD\";\n }\n\n if (codePoint in decodeMap) {\n codePoint = decodeMap[codePoint];\n }\n\n var output = \"\";\n\n if (codePoint > 0xffff) {\n codePoint -= 0x10000;\n output += String.fromCharCode(codePoint >>> 10 & 0x3ff | 0xd800);\n codePoint = 0xdc00 | codePoint & 0x3ff;\n }\n\n output += String.fromCharCode(codePoint);\n return output;\n}","var ElementType = require(\"domelementtype\");\n\nvar re_whitespace = /\\s+/g;\n\nvar NodePrototype = require(\"./lib/node\");\n\nvar ElementPrototype = require(\"./lib/element\");\n\nfunction DomHandler(callback, options, elementCB) {\n if (typeof callback === \"object\") {\n elementCB = options;\n options = callback;\n callback = null;\n } else if (typeof options === \"function\") {\n elementCB = options;\n options = defaultOpts;\n }\n\n this._callback = callback;\n this._options = options || defaultOpts;\n this._elementCB = elementCB;\n this.dom = [];\n this._done = false;\n this._tagStack = [];\n this._parser = this._parser || null;\n} //default options\n\n\nvar defaultOpts = {\n normalizeWhitespace: false,\n //Replace all whitespace with single spaces\n withStartIndices: false,\n //Add startIndex properties to nodes\n withEndIndices: false //Add endIndex properties to nodes\n\n};\n\nDomHandler.prototype.onparserinit = function (parser) {\n this._parser = parser;\n}; //Resets the handler back to starting state\n\n\nDomHandler.prototype.onreset = function () {\n DomHandler.call(this, this._callback, this._options, this._elementCB);\n}; //Signals the handler that parsing is done\n\n\nDomHandler.prototype.onend = function () {\n if (this._done) return;\n this._done = true;\n this._parser = null;\n\n this._handleCallback(null);\n};\n\nDomHandler.prototype._handleCallback = DomHandler.prototype.onerror = function (error) {\n if (typeof this._callback === \"function\") {\n this._callback(error, this.dom);\n } else {\n if (error) throw error;\n }\n};\n\nDomHandler.prototype.onclosetag = function () {\n //if(this._tagStack.pop().name !== name) this._handleCallback(Error(\"Tagname didn't match!\"));\n var elem = this._tagStack.pop();\n\n if (this._options.withEndIndices && elem) {\n elem.endIndex = this._parser.endIndex;\n }\n\n if (this._elementCB) this._elementCB(elem);\n};\n\nDomHandler.prototype._createDomElement = function (properties) {\n if (!this._options.withDomLvl1) return properties;\n var element;\n\n if (properties.type === \"tag\") {\n element = Object.create(ElementPrototype);\n } else {\n element = Object.create(NodePrototype);\n }\n\n for (var key in properties) {\n if (properties.hasOwnProperty(key)) {\n element[key] = properties[key];\n }\n }\n\n return element;\n};\n\nDomHandler.prototype._addDomElement = function (element) {\n var parent = this._tagStack[this._tagStack.length - 1];\n var siblings = parent ? parent.children : this.dom;\n var previousSibling = siblings[siblings.length - 1];\n element.next = null;\n\n if (this._options.withStartIndices) {\n element.startIndex = this._parser.startIndex;\n }\n\n if (this._options.withEndIndices) {\n element.endIndex = this._parser.endIndex;\n }\n\n if (previousSibling) {\n element.prev = previousSibling;\n previousSibling.next = element;\n } else {\n element.prev = null;\n }\n\n siblings.push(element);\n element.parent = parent || null;\n};\n\nDomHandler.prototype.onopentag = function (name, attribs) {\n var properties = {\n type: name === \"script\" ? ElementType.Script : name === \"style\" ? ElementType.Style : ElementType.Tag,\n name: name,\n attribs: attribs,\n children: []\n };\n\n var element = this._createDomElement(properties);\n\n this._addDomElement(element);\n\n this._tagStack.push(element);\n};\n\nDomHandler.prototype.ontext = function (data) {\n //the ignoreWhitespace is officially dropped, but for now,\n //it's an alias for normalizeWhitespace\n var normalize = this._options.normalizeWhitespace || this._options.ignoreWhitespace;\n var lastTag;\n\n if (!this._tagStack.length && this.dom.length && (lastTag = this.dom[this.dom.length - 1]).type === ElementType.Text) {\n if (normalize) {\n lastTag.data = (lastTag.data + data).replace(re_whitespace, \" \");\n } else {\n lastTag.data += data;\n }\n } else {\n if (this._tagStack.length && (lastTag = this._tagStack[this._tagStack.length - 1]) && (lastTag = lastTag.children[lastTag.children.length - 1]) && lastTag.type === ElementType.Text) {\n if (normalize) {\n lastTag.data = (lastTag.data + data).replace(re_whitespace, \" \");\n } else {\n lastTag.data += data;\n }\n } else {\n if (normalize) {\n data = data.replace(re_whitespace, \" \");\n }\n\n var element = this._createDomElement({\n data: data,\n type: ElementType.Text\n });\n\n this._addDomElement(element);\n }\n }\n};\n\nDomHandler.prototype.oncomment = function (data) {\n var lastTag = this._tagStack[this._tagStack.length - 1];\n\n if (lastTag && lastTag.type === ElementType.Comment) {\n lastTag.data += data;\n return;\n }\n\n var properties = {\n data: data,\n type: ElementType.Comment\n };\n\n var element = this._createDomElement(properties);\n\n this._addDomElement(element);\n\n this._tagStack.push(element);\n};\n\nDomHandler.prototype.oncdatastart = function () {\n var properties = {\n children: [{\n data: \"\",\n type: ElementType.Text\n }],\n type: ElementType.CDATA\n };\n\n var element = this._createDomElement(properties);\n\n this._addDomElement(element);\n\n this._tagStack.push(element);\n};\n\nDomHandler.prototype.oncommentend = DomHandler.prototype.oncdataend = function () {\n this._tagStack.pop();\n};\n\nDomHandler.prototype.onprocessinginstruction = function (name, data) {\n var element = this._createDomElement({\n name: name,\n data: data,\n type: ElementType.Directive\n });\n\n this._addDomElement(element);\n};\n\nmodule.exports = DomHandler;","// This object will be used as the prototype for Nodes when creating a\n// DOM-Level-1-compliant structure.\nvar NodePrototype = module.exports = {\n get firstChild() {\n var children = this.children;\n return children && children[0] || null;\n },\n\n get lastChild() {\n var children = this.children;\n return children && children[children.length - 1] || null;\n },\n\n get nodeType() {\n return nodeTypes[this.type] || nodeTypes.element;\n }\n\n};\nvar domLvl1 = {\n tagName: \"name\",\n childNodes: \"children\",\n parentNode: \"parent\",\n previousSibling: \"prev\",\n nextSibling: \"next\",\n nodeValue: \"data\"\n};\nvar nodeTypes = {\n element: 1,\n text: 3,\n cdata: 4,\n comment: 8\n};\nObject.keys(domLvl1).forEach(function (key) {\n var shorthand = domLvl1[key];\n Object.defineProperty(NodePrototype, key, {\n get: function get() {\n return this[shorthand] || null;\n },\n set: function set(val) {\n this[shorthand] = val;\n return val;\n }\n });\n});","var DomUtils = module.exports;\n[require(\"./lib/stringify\"), require(\"./lib/traversal\"), require(\"./lib/manipulation\"), require(\"./lib/querying\"), require(\"./lib/legacy\"), require(\"./lib/helpers\")].forEach(function (ext) {\n Object.keys(ext).forEach(function (key) {\n DomUtils[key] = ext[key].bind(DomUtils);\n });\n});","module.exports = Stream;\n\nvar Parser = require(\"./Parser.js\");\n\nvar WritableStream = require(\"readable-stream\").Writable;\n\nvar StringDecoder = require(\"string_decoder\").StringDecoder;\n\nvar Buffer = require(\"buffer\").Buffer;\n\nfunction Stream(cbs, options) {\n var parser = this._parser = new Parser(cbs, options);\n var decoder = this._decoder = new StringDecoder();\n WritableStream.call(this, {\n decodeStrings: false\n });\n this.once(\"finish\", function () {\n parser.end(decoder.end());\n });\n}\n\nrequire(\"inherits\")(Stream, WritableStream);\n\nStream.prototype._write = function (chunk, encoding, cb) {\n if (chunk instanceof Buffer) chunk = this._decoder.write(chunk);\n\n this._parser.write(chunk);\n\n cb();\n};","/*!\n * The buffer module from node.js, for the browser.\n *\n * @author Feross Aboukhadijeh \n * @license MIT\n */\n\n/* eslint-disable no-proto */\n'use strict';\n\nvar base64 = require('base64-js');\n\nvar ieee754 = require('ieee754');\n\nvar isArray = require('isarray');\n\nexports.Buffer = Buffer;\nexports.SlowBuffer = SlowBuffer;\nexports.INSPECT_MAX_BYTES = 50;\n/**\n * If `Buffer.TYPED_ARRAY_SUPPORT`:\n * === true Use Uint8Array implementation (fastest)\n * === false Use Object implementation (most compatible, even IE6)\n *\n * Browsers that support typed arrays are IE 10+, Firefox 4+, Chrome 7+, Safari 5.1+,\n * Opera 11.6+, iOS 4.2+.\n *\n * Due to various browser bugs, sometimes the Object implementation will be used even\n * when the browser supports typed arrays.\n *\n * Note:\n *\n * - Firefox 4-29 lacks support for adding new properties to `Uint8Array` instances,\n * See: https://bugzilla.mozilla.org/show_bug.cgi?id=695438.\n *\n * - Chrome 9-10 is missing the `TypedArray.prototype.subarray` function.\n *\n * - IE10 has a broken `TypedArray.prototype.subarray` function which returns arrays of\n * incorrect length in some situations.\n\n * We detect these buggy browsers and set `Buffer.TYPED_ARRAY_SUPPORT` to `false` so they\n * get the Object implementation, which is slower but behaves correctly.\n */\n\nBuffer.TYPED_ARRAY_SUPPORT = global.TYPED_ARRAY_SUPPORT !== undefined ? global.TYPED_ARRAY_SUPPORT : typedArraySupport();\n/*\n * Export kMaxLength after typed array support is determined.\n */\n\nexports.kMaxLength = kMaxLength();\n\nfunction typedArraySupport() {\n try {\n var arr = new Uint8Array(1);\n arr.__proto__ = {\n __proto__: Uint8Array.prototype,\n foo: function foo() {\n return 42;\n }\n };\n return arr.foo() === 42 && // typed array instances can be augmented\n typeof arr.subarray === 'function' && // chrome 9-10 lack `subarray`\n arr.subarray(1, 1).byteLength === 0; // ie10 has broken `subarray`\n } catch (e) {\n return false;\n }\n}\n\nfunction kMaxLength() {\n return Buffer.TYPED_ARRAY_SUPPORT ? 0x7fffffff : 0x3fffffff;\n}\n\nfunction createBuffer(that, length) {\n if (kMaxLength() < length) {\n throw new RangeError('Invalid typed array length');\n }\n\n if (Buffer.TYPED_ARRAY_SUPPORT) {\n // Return an augmented `Uint8Array` instance, for best performance\n that = new Uint8Array(length);\n that.__proto__ = Buffer.prototype;\n } else {\n // Fallback: Return an object instance of the Buffer class\n if (that === null) {\n that = new Buffer(length);\n }\n\n that.length = length;\n }\n\n return that;\n}\n/**\n * The Buffer constructor returns instances of `Uint8Array` that have their\n * prototype changed to `Buffer.prototype`. Furthermore, `Buffer` is a subclass of\n * `Uint8Array`, so the returned instances will have all the node `Buffer` methods\n * and the `Uint8Array` methods. Square bracket notation works as expected -- it\n * returns a single octet.\n *\n * The `Uint8Array` prototype remains unmodified.\n */\n\n\nfunction Buffer(arg, encodingOrOffset, length) {\n if (!Buffer.TYPED_ARRAY_SUPPORT && !(this instanceof Buffer)) {\n return new Buffer(arg, encodingOrOffset, length);\n } // Common case.\n\n\n if (typeof arg === 'number') {\n if (typeof encodingOrOffset === 'string') {\n throw new Error('If encoding is specified then the first argument must be a string');\n }\n\n return allocUnsafe(this, arg);\n }\n\n return from(this, arg, encodingOrOffset, length);\n}\n\nBuffer.poolSize = 8192; // not used by this implementation\n// TODO: Legacy, not needed anymore. Remove in next major version.\n\nBuffer._augment = function (arr) {\n arr.__proto__ = Buffer.prototype;\n return arr;\n};\n\nfunction from(that, value, encodingOrOffset, length) {\n if (typeof value === 'number') {\n throw new TypeError('\"value\" argument must not be a number');\n }\n\n if (typeof ArrayBuffer !== 'undefined' && value instanceof ArrayBuffer) {\n return fromArrayBuffer(that, value, encodingOrOffset, length);\n }\n\n if (typeof value === 'string') {\n return fromString(that, value, encodingOrOffset);\n }\n\n return fromObject(that, value);\n}\n/**\n * Functionally equivalent to Buffer(arg, encoding) but throws a TypeError\n * if value is a number.\n * Buffer.from(str[, encoding])\n * Buffer.from(array)\n * Buffer.from(buffer)\n * Buffer.from(arrayBuffer[, byteOffset[, length]])\n **/\n\n\nBuffer.from = function (value, encodingOrOffset, length) {\n return from(null, value, encodingOrOffset, length);\n};\n\nif (Buffer.TYPED_ARRAY_SUPPORT) {\n Buffer.prototype.__proto__ = Uint8Array.prototype;\n Buffer.__proto__ = Uint8Array;\n\n if (typeof Symbol !== 'undefined' && Symbol.species && Buffer[Symbol.species] === Buffer) {\n // Fix subarray() in ES2016. See: https://github.com/feross/buffer/pull/97\n Object.defineProperty(Buffer, Symbol.species, {\n value: null,\n configurable: true\n });\n }\n}\n\nfunction assertSize(size) {\n if (typeof size !== 'number') {\n throw new TypeError('\"size\" argument must be a number');\n } else if (size < 0) {\n throw new RangeError('\"size\" argument must not be negative');\n }\n}\n\nfunction alloc(that, size, fill, encoding) {\n assertSize(size);\n\n if (size <= 0) {\n return createBuffer(that, size);\n }\n\n if (fill !== undefined) {\n // Only pay attention to encoding if it's a string. This\n // prevents accidentally sending in a number that would\n // be interpretted as a start offset.\n return typeof encoding === 'string' ? createBuffer(that, size).fill(fill, encoding) : createBuffer(that, size).fill(fill);\n }\n\n return createBuffer(that, size);\n}\n/**\n * Creates a new filled Buffer instance.\n * alloc(size[, fill[, encoding]])\n **/\n\n\nBuffer.alloc = function (size, fill, encoding) {\n return alloc(null, size, fill, encoding);\n};\n\nfunction allocUnsafe(that, size) {\n assertSize(size);\n that = createBuffer(that, size < 0 ? 0 : checked(size) | 0);\n\n if (!Buffer.TYPED_ARRAY_SUPPORT) {\n for (var i = 0; i < size; ++i) {\n that[i] = 0;\n }\n }\n\n return that;\n}\n/**\n * Equivalent to Buffer(num), by default creates a non-zero-filled Buffer instance.\n * */\n\n\nBuffer.allocUnsafe = function (size) {\n return allocUnsafe(null, size);\n};\n/**\n * Equivalent to SlowBuffer(num), by default creates a non-zero-filled Buffer instance.\n */\n\n\nBuffer.allocUnsafeSlow = function (size) {\n return allocUnsafe(null, size);\n};\n\nfunction fromString(that, string, encoding) {\n if (typeof encoding !== 'string' || encoding === '') {\n encoding = 'utf8';\n }\n\n if (!Buffer.isEncoding(encoding)) {\n throw new TypeError('\"encoding\" must be a valid string encoding');\n }\n\n var length = byteLength(string, encoding) | 0;\n that = createBuffer(that, length);\n var actual = that.write(string, encoding);\n\n if (actual !== length) {\n // Writing a hex string, for example, that contains invalid characters will\n // cause everything after the first invalid character to be ignored. (e.g.\n // 'abxxcd' will be treated as 'ab')\n that = that.slice(0, actual);\n }\n\n return that;\n}\n\nfunction fromArrayLike(that, array) {\n var length = array.length < 0 ? 0 : checked(array.length) | 0;\n that = createBuffer(that, length);\n\n for (var i = 0; i < length; i += 1) {\n that[i] = array[i] & 255;\n }\n\n return that;\n}\n\nfunction fromArrayBuffer(that, array, byteOffset, length) {\n array.byteLength; // this throws if `array` is not a valid ArrayBuffer\n\n if (byteOffset < 0 || array.byteLength < byteOffset) {\n throw new RangeError('\\'offset\\' is out of bounds');\n }\n\n if (array.byteLength < byteOffset + (length || 0)) {\n throw new RangeError('\\'length\\' is out of bounds');\n }\n\n if (byteOffset === undefined && length === undefined) {\n array = new Uint8Array(array);\n } else if (length === undefined) {\n array = new Uint8Array(array, byteOffset);\n } else {\n array = new Uint8Array(array, byteOffset, length);\n }\n\n if (Buffer.TYPED_ARRAY_SUPPORT) {\n // Return an augmented `Uint8Array` instance, for best performance\n that = array;\n that.__proto__ = Buffer.prototype;\n } else {\n // Fallback: Return an object instance of the Buffer class\n that = fromArrayLike(that, array);\n }\n\n return that;\n}\n\nfunction fromObject(that, obj) {\n if (Buffer.isBuffer(obj)) {\n var len = checked(obj.length) | 0;\n that = createBuffer(that, len);\n\n if (that.length === 0) {\n return that;\n }\n\n obj.copy(that, 0, 0, len);\n return that;\n }\n\n if (obj) {\n if (typeof ArrayBuffer !== 'undefined' && obj.buffer instanceof ArrayBuffer || 'length' in obj) {\n if (typeof obj.length !== 'number' || isnan(obj.length)) {\n return createBuffer(that, 0);\n }\n\n return fromArrayLike(that, obj);\n }\n\n if (obj.type === 'Buffer' && isArray(obj.data)) {\n return fromArrayLike(that, obj.data);\n }\n }\n\n throw new TypeError('First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.');\n}\n\nfunction checked(length) {\n // Note: cannot use `length < kMaxLength()` here because that fails when\n // length is NaN (which is otherwise coerced to zero.)\n if (length >= kMaxLength()) {\n throw new RangeError('Attempt to allocate Buffer larger than maximum ' + 'size: 0x' + kMaxLength().toString(16) + ' bytes');\n }\n\n return length | 0;\n}\n\nfunction SlowBuffer(length) {\n if (+length != length) {\n // eslint-disable-line eqeqeq\n length = 0;\n }\n\n return Buffer.alloc(+length);\n}\n\nBuffer.isBuffer = function isBuffer(b) {\n return !!(b != null && b._isBuffer);\n};\n\nBuffer.compare = function compare(a, b) {\n if (!Buffer.isBuffer(a) || !Buffer.isBuffer(b)) {\n throw new TypeError('Arguments must be Buffers');\n }\n\n if (a === b) return 0;\n var x = a.length;\n var y = b.length;\n\n for (var i = 0, len = Math.min(x, y); i < len; ++i) {\n if (a[i] !== b[i]) {\n x = a[i];\n y = b[i];\n break;\n }\n }\n\n if (x < y) return -1;\n if (y < x) return 1;\n return 0;\n};\n\nBuffer.isEncoding = function isEncoding(encoding) {\n switch (String(encoding).toLowerCase()) {\n case 'hex':\n case 'utf8':\n case 'utf-8':\n case 'ascii':\n case 'latin1':\n case 'binary':\n case 'base64':\n case 'ucs2':\n case 'ucs-2':\n case 'utf16le':\n case 'utf-16le':\n return true;\n\n default:\n return false;\n }\n};\n\nBuffer.concat = function concat(list, length) {\n if (!isArray(list)) {\n throw new TypeError('\"list\" argument must be an Array of Buffers');\n }\n\n if (list.length === 0) {\n return Buffer.alloc(0);\n }\n\n var i;\n\n if (length === undefined) {\n length = 0;\n\n for (i = 0; i < list.length; ++i) {\n length += list[i].length;\n }\n }\n\n var buffer = Buffer.allocUnsafe(length);\n var pos = 0;\n\n for (i = 0; i < list.length; ++i) {\n var buf = list[i];\n\n if (!Buffer.isBuffer(buf)) {\n throw new TypeError('\"list\" argument must be an Array of Buffers');\n }\n\n buf.copy(buffer, pos);\n pos += buf.length;\n }\n\n return buffer;\n};\n\nfunction byteLength(string, encoding) {\n if (Buffer.isBuffer(string)) {\n return string.length;\n }\n\n if (typeof ArrayBuffer !== 'undefined' && typeof ArrayBuffer.isView === 'function' && (ArrayBuffer.isView(string) || string instanceof ArrayBuffer)) {\n return string.byteLength;\n }\n\n if (typeof string !== 'string') {\n string = '' + string;\n }\n\n var len = string.length;\n if (len === 0) return 0; // Use a for loop to avoid recursion\n\n var loweredCase = false;\n\n for (;;) {\n switch (encoding) {\n case 'ascii':\n case 'latin1':\n case 'binary':\n return len;\n\n case 'utf8':\n case 'utf-8':\n case undefined:\n return utf8ToBytes(string).length;\n\n case 'ucs2':\n case 'ucs-2':\n case 'utf16le':\n case 'utf-16le':\n return len * 2;\n\n case 'hex':\n return len >>> 1;\n\n case 'base64':\n return base64ToBytes(string).length;\n\n default:\n if (loweredCase) return utf8ToBytes(string).length; // assume utf8\n\n encoding = ('' + encoding).toLowerCase();\n loweredCase = true;\n }\n }\n}\n\nBuffer.byteLength = byteLength;\n\nfunction slowToString(encoding, start, end) {\n var loweredCase = false; // No need to verify that \"this.length <= MAX_UINT32\" since it's a read-only\n // property of a typed array.\n // This behaves neither like String nor Uint8Array in that we set start/end\n // to their upper/lower bounds if the value passed is out of range.\n // undefined is handled specially as per ECMA-262 6th Edition,\n // Section 13.3.3.7 Runtime Semantics: KeyedBindingInitialization.\n\n if (start === undefined || start < 0) {\n start = 0;\n } // Return early if start > this.length. Done here to prevent potential uint32\n // coercion fail below.\n\n\n if (start > this.length) {\n return '';\n }\n\n if (end === undefined || end > this.length) {\n end = this.length;\n }\n\n if (end <= 0) {\n return '';\n } // Force coersion to uint32. This will also coerce falsey/NaN values to 0.\n\n\n end >>>= 0;\n start >>>= 0;\n\n if (end <= start) {\n return '';\n }\n\n if (!encoding) encoding = 'utf8';\n\n while (true) {\n switch (encoding) {\n case 'hex':\n return hexSlice(this, start, end);\n\n case 'utf8':\n case 'utf-8':\n return utf8Slice(this, start, end);\n\n case 'ascii':\n return asciiSlice(this, start, end);\n\n case 'latin1':\n case 'binary':\n return latin1Slice(this, start, end);\n\n case 'base64':\n return base64Slice(this, start, end);\n\n case 'ucs2':\n case 'ucs-2':\n case 'utf16le':\n case 'utf-16le':\n return utf16leSlice(this, start, end);\n\n default:\n if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding);\n encoding = (encoding + '').toLowerCase();\n loweredCase = true;\n }\n }\n} // The property is used by `Buffer.isBuffer` and `is-buffer` (in Safari 5-7) to detect\n// Buffer instances.\n\n\nBuffer.prototype._isBuffer = true;\n\nfunction swap(b, n, m) {\n var i = b[n];\n b[n] = b[m];\n b[m] = i;\n}\n\nBuffer.prototype.swap16 = function swap16() {\n var len = this.length;\n\n if (len % 2 !== 0) {\n throw new RangeError('Buffer size must be a multiple of 16-bits');\n }\n\n for (var i = 0; i < len; i += 2) {\n swap(this, i, i + 1);\n }\n\n return this;\n};\n\nBuffer.prototype.swap32 = function swap32() {\n var len = this.length;\n\n if (len % 4 !== 0) {\n throw new RangeError('Buffer size must be a multiple of 32-bits');\n }\n\n for (var i = 0; i < len; i += 4) {\n swap(this, i, i + 3);\n swap(this, i + 1, i + 2);\n }\n\n return this;\n};\n\nBuffer.prototype.swap64 = function swap64() {\n var len = this.length;\n\n if (len % 8 !== 0) {\n throw new RangeError('Buffer size must be a multiple of 64-bits');\n }\n\n for (var i = 0; i < len; i += 8) {\n swap(this, i, i + 7);\n swap(this, i + 1, i + 6);\n swap(this, i + 2, i + 5);\n swap(this, i + 3, i + 4);\n }\n\n return this;\n};\n\nBuffer.prototype.toString = function toString() {\n var length = this.length | 0;\n if (length === 0) return '';\n if (arguments.length === 0) return utf8Slice(this, 0, length);\n return slowToString.apply(this, arguments);\n};\n\nBuffer.prototype.equals = function equals(b) {\n if (!Buffer.isBuffer(b)) throw new TypeError('Argument must be a Buffer');\n if (this === b) return true;\n return Buffer.compare(this, b) === 0;\n};\n\nBuffer.prototype.inspect = function inspect() {\n var str = '';\n var max = exports.INSPECT_MAX_BYTES;\n\n if (this.length > 0) {\n str = this.toString('hex', 0, max).match(/.{2}/g).join(' ');\n if (this.length > max) str += ' ... ';\n }\n\n return '';\n};\n\nBuffer.prototype.compare = function compare(target, start, end, thisStart, thisEnd) {\n if (!Buffer.isBuffer(target)) {\n throw new TypeError('Argument must be a Buffer');\n }\n\n if (start === undefined) {\n start = 0;\n }\n\n if (end === undefined) {\n end = target ? target.length : 0;\n }\n\n if (thisStart === undefined) {\n thisStart = 0;\n }\n\n if (thisEnd === undefined) {\n thisEnd = this.length;\n }\n\n if (start < 0 || end > target.length || thisStart < 0 || thisEnd > this.length) {\n throw new RangeError('out of range index');\n }\n\n if (thisStart >= thisEnd && start >= end) {\n return 0;\n }\n\n if (thisStart >= thisEnd) {\n return -1;\n }\n\n if (start >= end) {\n return 1;\n }\n\n start >>>= 0;\n end >>>= 0;\n thisStart >>>= 0;\n thisEnd >>>= 0;\n if (this === target) return 0;\n var x = thisEnd - thisStart;\n var y = end - start;\n var len = Math.min(x, y);\n var thisCopy = this.slice(thisStart, thisEnd);\n var targetCopy = target.slice(start, end);\n\n for (var i = 0; i < len; ++i) {\n if (thisCopy[i] !== targetCopy[i]) {\n x = thisCopy[i];\n y = targetCopy[i];\n break;\n }\n }\n\n if (x < y) return -1;\n if (y < x) return 1;\n return 0;\n}; // Finds either the first index of `val` in `buffer` at offset >= `byteOffset`,\n// OR the last index of `val` in `buffer` at offset <= `byteOffset`.\n//\n// Arguments:\n// - buffer - a Buffer to search\n// - val - a string, Buffer, or number\n// - byteOffset - an index into `buffer`; will be clamped to an int32\n// - encoding - an optional encoding, relevant is val is a string\n// - dir - true for indexOf, false for lastIndexOf\n\n\nfunction bidirectionalIndexOf(buffer, val, byteOffset, encoding, dir) {\n // Empty buffer means no match\n if (buffer.length === 0) return -1; // Normalize byteOffset\n\n if (typeof byteOffset === 'string') {\n encoding = byteOffset;\n byteOffset = 0;\n } else if (byteOffset > 0x7fffffff) {\n byteOffset = 0x7fffffff;\n } else if (byteOffset < -0x80000000) {\n byteOffset = -0x80000000;\n }\n\n byteOffset = +byteOffset; // Coerce to Number.\n\n if (isNaN(byteOffset)) {\n // byteOffset: it it's undefined, null, NaN, \"foo\", etc, search whole buffer\n byteOffset = dir ? 0 : buffer.length - 1;\n } // Normalize byteOffset: negative offsets start from the end of the buffer\n\n\n if (byteOffset < 0) byteOffset = buffer.length + byteOffset;\n\n if (byteOffset >= buffer.length) {\n if (dir) return -1;else byteOffset = buffer.length - 1;\n } else if (byteOffset < 0) {\n if (dir) byteOffset = 0;else return -1;\n } // Normalize val\n\n\n if (typeof val === 'string') {\n val = Buffer.from(val, encoding);\n } // Finally, search either indexOf (if dir is true) or lastIndexOf\n\n\n if (Buffer.isBuffer(val)) {\n // Special case: looking for empty string/buffer always fails\n if (val.length === 0) {\n return -1;\n }\n\n return arrayIndexOf(buffer, val, byteOffset, encoding, dir);\n } else if (typeof val === 'number') {\n val = val & 0xFF; // Search for a byte value [0-255]\n\n if (Buffer.TYPED_ARRAY_SUPPORT && typeof Uint8Array.prototype.indexOf === 'function') {\n if (dir) {\n return Uint8Array.prototype.indexOf.call(buffer, val, byteOffset);\n } else {\n return Uint8Array.prototype.lastIndexOf.call(buffer, val, byteOffset);\n }\n }\n\n return arrayIndexOf(buffer, [val], byteOffset, encoding, dir);\n }\n\n throw new TypeError('val must be string, number or Buffer');\n}\n\nfunction arrayIndexOf(arr, val, byteOffset, encoding, dir) {\n var indexSize = 1;\n var arrLength = arr.length;\n var valLength = val.length;\n\n if (encoding !== undefined) {\n encoding = String(encoding).toLowerCase();\n\n if (encoding === 'ucs2' || encoding === 'ucs-2' || encoding === 'utf16le' || encoding === 'utf-16le') {\n if (arr.length < 2 || val.length < 2) {\n return -1;\n }\n\n indexSize = 2;\n arrLength /= 2;\n valLength /= 2;\n byteOffset /= 2;\n }\n }\n\n function read(buf, i) {\n if (indexSize === 1) {\n return buf[i];\n } else {\n return buf.readUInt16BE(i * indexSize);\n }\n }\n\n var i;\n\n if (dir) {\n var foundIndex = -1;\n\n for (i = byteOffset; i < arrLength; i++) {\n if (read(arr, i) === read(val, foundIndex === -1 ? 0 : i - foundIndex)) {\n if (foundIndex === -1) foundIndex = i;\n if (i - foundIndex + 1 === valLength) return foundIndex * indexSize;\n } else {\n if (foundIndex !== -1) i -= i - foundIndex;\n foundIndex = -1;\n }\n }\n } else {\n if (byteOffset + valLength > arrLength) byteOffset = arrLength - valLength;\n\n for (i = byteOffset; i >= 0; i--) {\n var found = true;\n\n for (var j = 0; j < valLength; j++) {\n if (read(arr, i + j) !== read(val, j)) {\n found = false;\n break;\n }\n }\n\n if (found) return i;\n }\n }\n\n return -1;\n}\n\nBuffer.prototype.includes = function includes(val, byteOffset, encoding) {\n return this.indexOf(val, byteOffset, encoding) !== -1;\n};\n\nBuffer.prototype.indexOf = function indexOf(val, byteOffset, encoding) {\n return bidirectionalIndexOf(this, val, byteOffset, encoding, true);\n};\n\nBuffer.prototype.lastIndexOf = function lastIndexOf(val, byteOffset, encoding) {\n return bidirectionalIndexOf(this, val, byteOffset, encoding, false);\n};\n\nfunction hexWrite(buf, string, offset, length) {\n offset = Number(offset) || 0;\n var remaining = buf.length - offset;\n\n if (!length) {\n length = remaining;\n } else {\n length = Number(length);\n\n if (length > remaining) {\n length = remaining;\n }\n } // must be an even number of digits\n\n\n var strLen = string.length;\n if (strLen % 2 !== 0) throw new TypeError('Invalid hex string');\n\n if (length > strLen / 2) {\n length = strLen / 2;\n }\n\n for (var i = 0; i < length; ++i) {\n var parsed = parseInt(string.substr(i * 2, 2), 16);\n if (isNaN(parsed)) return i;\n buf[offset + i] = parsed;\n }\n\n return i;\n}\n\nfunction utf8Write(buf, string, offset, length) {\n return blitBuffer(utf8ToBytes(string, buf.length - offset), buf, offset, length);\n}\n\nfunction asciiWrite(buf, string, offset, length) {\n return blitBuffer(asciiToBytes(string), buf, offset, length);\n}\n\nfunction latin1Write(buf, string, offset, length) {\n return asciiWrite(buf, string, offset, length);\n}\n\nfunction base64Write(buf, string, offset, length) {\n return blitBuffer(base64ToBytes(string), buf, offset, length);\n}\n\nfunction ucs2Write(buf, string, offset, length) {\n return blitBuffer(utf16leToBytes(string, buf.length - offset), buf, offset, length);\n}\n\nBuffer.prototype.write = function write(string, offset, length, encoding) {\n // Buffer#write(string)\n if (offset === undefined) {\n encoding = 'utf8';\n length = this.length;\n offset = 0; // Buffer#write(string, encoding)\n } else if (length === undefined && typeof offset === 'string') {\n encoding = offset;\n length = this.length;\n offset = 0; // Buffer#write(string, offset[, length][, encoding])\n } else if (isFinite(offset)) {\n offset = offset | 0;\n\n if (isFinite(length)) {\n length = length | 0;\n if (encoding === undefined) encoding = 'utf8';\n } else {\n encoding = length;\n length = undefined;\n } // legacy write(string, encoding, offset, length) - remove in v0.13\n\n } else {\n throw new Error('Buffer.write(string, encoding, offset[, length]) is no longer supported');\n }\n\n var remaining = this.length - offset;\n if (length === undefined || length > remaining) length = remaining;\n\n if (string.length > 0 && (length < 0 || offset < 0) || offset > this.length) {\n throw new RangeError('Attempt to write outside buffer bounds');\n }\n\n if (!encoding) encoding = 'utf8';\n var loweredCase = false;\n\n for (;;) {\n switch (encoding) {\n case 'hex':\n return hexWrite(this, string, offset, length);\n\n case 'utf8':\n case 'utf-8':\n return utf8Write(this, string, offset, length);\n\n case 'ascii':\n return asciiWrite(this, string, offset, length);\n\n case 'latin1':\n case 'binary':\n return latin1Write(this, string, offset, length);\n\n case 'base64':\n // Warning: maxLength not taken into account in base64Write\n return base64Write(this, string, offset, length);\n\n case 'ucs2':\n case 'ucs-2':\n case 'utf16le':\n case 'utf-16le':\n return ucs2Write(this, string, offset, length);\n\n default:\n if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding);\n encoding = ('' + encoding).toLowerCase();\n loweredCase = true;\n }\n }\n};\n\nBuffer.prototype.toJSON = function toJSON() {\n return {\n type: 'Buffer',\n data: Array.prototype.slice.call(this._arr || this, 0)\n };\n};\n\nfunction base64Slice(buf, start, end) {\n if (start === 0 && end === buf.length) {\n return base64.fromByteArray(buf);\n } else {\n return base64.fromByteArray(buf.slice(start, end));\n }\n}\n\nfunction utf8Slice(buf, start, end) {\n end = Math.min(buf.length, end);\n var res = [];\n var i = start;\n\n while (i < end) {\n var firstByte = buf[i];\n var codePoint = null;\n var bytesPerSequence = firstByte > 0xEF ? 4 : firstByte > 0xDF ? 3 : firstByte > 0xBF ? 2 : 1;\n\n if (i + bytesPerSequence <= end) {\n var secondByte, thirdByte, fourthByte, tempCodePoint;\n\n switch (bytesPerSequence) {\n case 1:\n if (firstByte < 0x80) {\n codePoint = firstByte;\n }\n\n break;\n\n case 2:\n secondByte = buf[i + 1];\n\n if ((secondByte & 0xC0) === 0x80) {\n tempCodePoint = (firstByte & 0x1F) << 0x6 | secondByte & 0x3F;\n\n if (tempCodePoint > 0x7F) {\n codePoint = tempCodePoint;\n }\n }\n\n break;\n\n case 3:\n secondByte = buf[i + 1];\n thirdByte = buf[i + 2];\n\n if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80) {\n tempCodePoint = (firstByte & 0xF) << 0xC | (secondByte & 0x3F) << 0x6 | thirdByte & 0x3F;\n\n if (tempCodePoint > 0x7FF && (tempCodePoint < 0xD800 || tempCodePoint > 0xDFFF)) {\n codePoint = tempCodePoint;\n }\n }\n\n break;\n\n case 4:\n secondByte = buf[i + 1];\n thirdByte = buf[i + 2];\n fourthByte = buf[i + 3];\n\n if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80 && (fourthByte & 0xC0) === 0x80) {\n tempCodePoint = (firstByte & 0xF) << 0x12 | (secondByte & 0x3F) << 0xC | (thirdByte & 0x3F) << 0x6 | fourthByte & 0x3F;\n\n if (tempCodePoint > 0xFFFF && tempCodePoint < 0x110000) {\n codePoint = tempCodePoint;\n }\n }\n\n }\n }\n\n if (codePoint === null) {\n // we did not generate a valid codePoint so insert a\n // replacement char (U+FFFD) and advance only 1 byte\n codePoint = 0xFFFD;\n bytesPerSequence = 1;\n } else if (codePoint > 0xFFFF) {\n // encode to utf16 (surrogate pair dance)\n codePoint -= 0x10000;\n res.push(codePoint >>> 10 & 0x3FF | 0xD800);\n codePoint = 0xDC00 | codePoint & 0x3FF;\n }\n\n res.push(codePoint);\n i += bytesPerSequence;\n }\n\n return decodeCodePointsArray(res);\n} // Based on http://stackoverflow.com/a/22747272/680742, the browser with\n// the lowest limit is Chrome, with 0x10000 args.\n// We go 1 magnitude less, for safety\n\n\nvar MAX_ARGUMENTS_LENGTH = 0x1000;\n\nfunction decodeCodePointsArray(codePoints) {\n var len = codePoints.length;\n\n if (len <= MAX_ARGUMENTS_LENGTH) {\n return String.fromCharCode.apply(String, codePoints); // avoid extra slice()\n } // Decode in chunks to avoid \"call stack size exceeded\".\n\n\n var res = '';\n var i = 0;\n\n while (i < len) {\n res += String.fromCharCode.apply(String, codePoints.slice(i, i += MAX_ARGUMENTS_LENGTH));\n }\n\n return res;\n}\n\nfunction asciiSlice(buf, start, end) {\n var ret = '';\n end = Math.min(buf.length, end);\n\n for (var i = start; i < end; ++i) {\n ret += String.fromCharCode(buf[i] & 0x7F);\n }\n\n return ret;\n}\n\nfunction latin1Slice(buf, start, end) {\n var ret = '';\n end = Math.min(buf.length, end);\n\n for (var i = start; i < end; ++i) {\n ret += String.fromCharCode(buf[i]);\n }\n\n return ret;\n}\n\nfunction hexSlice(buf, start, end) {\n var len = buf.length;\n if (!start || start < 0) start = 0;\n if (!end || end < 0 || end > len) end = len;\n var out = '';\n\n for (var i = start; i < end; ++i) {\n out += toHex(buf[i]);\n }\n\n return out;\n}\n\nfunction utf16leSlice(buf, start, end) {\n var bytes = buf.slice(start, end);\n var res = '';\n\n for (var i = 0; i < bytes.length; i += 2) {\n res += String.fromCharCode(bytes[i] + bytes[i + 1] * 256);\n }\n\n return res;\n}\n\nBuffer.prototype.slice = function slice(start, end) {\n var len = this.length;\n start = ~~start;\n end = end === undefined ? len : ~~end;\n\n if (start < 0) {\n start += len;\n if (start < 0) start = 0;\n } else if (start > len) {\n start = len;\n }\n\n if (end < 0) {\n end += len;\n if (end < 0) end = 0;\n } else if (end > len) {\n end = len;\n }\n\n if (end < start) end = start;\n var newBuf;\n\n if (Buffer.TYPED_ARRAY_SUPPORT) {\n newBuf = this.subarray(start, end);\n newBuf.__proto__ = Buffer.prototype;\n } else {\n var sliceLen = end - start;\n newBuf = new Buffer(sliceLen, undefined);\n\n for (var i = 0; i < sliceLen; ++i) {\n newBuf[i] = this[i + start];\n }\n }\n\n return newBuf;\n};\n/*\n * Need to make sure that buffer isn't trying to write out of bounds.\n */\n\n\nfunction checkOffset(offset, ext, length) {\n if (offset % 1 !== 0 || offset < 0) throw new RangeError('offset is not uint');\n if (offset + ext > length) throw new RangeError('Trying to access beyond buffer length');\n}\n\nBuffer.prototype.readUIntLE = function readUIntLE(offset, byteLength, noAssert) {\n offset = offset | 0;\n byteLength = byteLength | 0;\n if (!noAssert) checkOffset(offset, byteLength, this.length);\n var val = this[offset];\n var mul = 1;\n var i = 0;\n\n while (++i < byteLength && (mul *= 0x100)) {\n val += this[offset + i] * mul;\n }\n\n return val;\n};\n\nBuffer.prototype.readUIntBE = function readUIntBE(offset, byteLength, noAssert) {\n offset = offset | 0;\n byteLength = byteLength | 0;\n\n if (!noAssert) {\n checkOffset(offset, byteLength, this.length);\n }\n\n var val = this[offset + --byteLength];\n var mul = 1;\n\n while (byteLength > 0 && (mul *= 0x100)) {\n val += this[offset + --byteLength] * mul;\n }\n\n return val;\n};\n\nBuffer.prototype.readUInt8 = function readUInt8(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 1, this.length);\n return this[offset];\n};\n\nBuffer.prototype.readUInt16LE = function readUInt16LE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 2, this.length);\n return this[offset] | this[offset + 1] << 8;\n};\n\nBuffer.prototype.readUInt16BE = function readUInt16BE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 2, this.length);\n return this[offset] << 8 | this[offset + 1];\n};\n\nBuffer.prototype.readUInt32LE = function readUInt32LE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 4, this.length);\n return (this[offset] | this[offset + 1] << 8 | this[offset + 2] << 16) + this[offset + 3] * 0x1000000;\n};\n\nBuffer.prototype.readUInt32BE = function readUInt32BE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 4, this.length);\n return this[offset] * 0x1000000 + (this[offset + 1] << 16 | this[offset + 2] << 8 | this[offset + 3]);\n};\n\nBuffer.prototype.readIntLE = function readIntLE(offset, byteLength, noAssert) {\n offset = offset | 0;\n byteLength = byteLength | 0;\n if (!noAssert) checkOffset(offset, byteLength, this.length);\n var val = this[offset];\n var mul = 1;\n var i = 0;\n\n while (++i < byteLength && (mul *= 0x100)) {\n val += this[offset + i] * mul;\n }\n\n mul *= 0x80;\n if (val >= mul) val -= Math.pow(2, 8 * byteLength);\n return val;\n};\n\nBuffer.prototype.readIntBE = function readIntBE(offset, byteLength, noAssert) {\n offset = offset | 0;\n byteLength = byteLength | 0;\n if (!noAssert) checkOffset(offset, byteLength, this.length);\n var i = byteLength;\n var mul = 1;\n var val = this[offset + --i];\n\n while (i > 0 && (mul *= 0x100)) {\n val += this[offset + --i] * mul;\n }\n\n mul *= 0x80;\n if (val >= mul) val -= Math.pow(2, 8 * byteLength);\n return val;\n};\n\nBuffer.prototype.readInt8 = function readInt8(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 1, this.length);\n if (!(this[offset] & 0x80)) return this[offset];\n return (0xff - this[offset] + 1) * -1;\n};\n\nBuffer.prototype.readInt16LE = function readInt16LE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 2, this.length);\n var val = this[offset] | this[offset + 1] << 8;\n return val & 0x8000 ? val | 0xFFFF0000 : val;\n};\n\nBuffer.prototype.readInt16BE = function readInt16BE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 2, this.length);\n var val = this[offset + 1] | this[offset] << 8;\n return val & 0x8000 ? val | 0xFFFF0000 : val;\n};\n\nBuffer.prototype.readInt32LE = function readInt32LE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 4, this.length);\n return this[offset] | this[offset + 1] << 8 | this[offset + 2] << 16 | this[offset + 3] << 24;\n};\n\nBuffer.prototype.readInt32BE = function readInt32BE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 4, this.length);\n return this[offset] << 24 | this[offset + 1] << 16 | this[offset + 2] << 8 | this[offset + 3];\n};\n\nBuffer.prototype.readFloatLE = function readFloatLE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 4, this.length);\n return ieee754.read(this, offset, true, 23, 4);\n};\n\nBuffer.prototype.readFloatBE = function readFloatBE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 4, this.length);\n return ieee754.read(this, offset, false, 23, 4);\n};\n\nBuffer.prototype.readDoubleLE = function readDoubleLE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 8, this.length);\n return ieee754.read(this, offset, true, 52, 8);\n};\n\nBuffer.prototype.readDoubleBE = function readDoubleBE(offset, noAssert) {\n if (!noAssert) checkOffset(offset, 8, this.length);\n return ieee754.read(this, offset, false, 52, 8);\n};\n\nfunction checkInt(buf, value, offset, ext, max, min) {\n if (!Buffer.isBuffer(buf)) throw new TypeError('\"buffer\" argument must be a Buffer instance');\n if (value > max || value < min) throw new RangeError('\"value\" argument is out of bounds');\n if (offset + ext > buf.length) throw new RangeError('Index out of range');\n}\n\nBuffer.prototype.writeUIntLE = function writeUIntLE(value, offset, byteLength, noAssert) {\n value = +value;\n offset = offset | 0;\n byteLength = byteLength | 0;\n\n if (!noAssert) {\n var maxBytes = Math.pow(2, 8 * byteLength) - 1;\n checkInt(this, value, offset, byteLength, maxBytes, 0);\n }\n\n var mul = 1;\n var i = 0;\n this[offset] = value & 0xFF;\n\n while (++i < byteLength && (mul *= 0x100)) {\n this[offset + i] = value / mul & 0xFF;\n }\n\n return offset + byteLength;\n};\n\nBuffer.prototype.writeUIntBE = function writeUIntBE(value, offset, byteLength, noAssert) {\n value = +value;\n offset = offset | 0;\n byteLength = byteLength | 0;\n\n if (!noAssert) {\n var maxBytes = Math.pow(2, 8 * byteLength) - 1;\n checkInt(this, value, offset, byteLength, maxBytes, 0);\n }\n\n var i = byteLength - 1;\n var mul = 1;\n this[offset + i] = value & 0xFF;\n\n while (--i >= 0 && (mul *= 0x100)) {\n this[offset + i] = value / mul & 0xFF;\n }\n\n return offset + byteLength;\n};\n\nBuffer.prototype.writeUInt8 = function writeUInt8(value, offset, noAssert) {\n value = +value;\n offset = offset | 0;\n if (!noAssert) checkInt(this, value, offset, 1, 0xff, 0);\n if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value);\n this[offset] = value & 0xff;\n return offset + 1;\n};\n\nfunction objectWriteUInt16(buf, value, offset, littleEndian) {\n if (value < 0) value = 0xffff + value + 1;\n\n for (var i = 0, j = Math.min(buf.length - offset, 2); i < j; ++i) {\n buf[offset + i] = (value & 0xff << 8 * (littleEndian ? i : 1 - i)) >>> (littleEndian ? i : 1 - i) * 8;\n }\n}\n\nBuffer.prototype.writeUInt16LE = function writeUInt16LE(value, offset, noAssert) {\n value = +value;\n offset = offset | 0;\n if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0);\n\n if (Buffer.TYPED_ARRAY_SUPPORT) {\n this[offset] = value & 0xff;\n this[offset + 1] = value >>> 8;\n } else {\n objectWriteUInt16(this, value, offset, true);\n }\n\n return offset + 2;\n};\n\nBuffer.prototype.writeUInt16BE = function writeUInt16BE(value, offset, noAssert) {\n value = +value;\n offset = offset | 0;\n if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0);\n\n if (Buffer.TYPED_ARRAY_SUPPORT) {\n this[offset] = value >>> 8;\n this[offset + 1] = value & 0xff;\n } else {\n objectWriteUInt16(this, value, offset, false);\n }\n\n return offset + 2;\n};\n\nfunction objectWriteUInt32(buf, value, offset, littleEndian) {\n if (value < 0) value = 0xffffffff + value + 1;\n\n for (var i = 0, j = Math.min(buf.length - offset, 4); i < j; ++i) {\n buf[offset + i] = value >>> (littleEndian ? i : 3 - i) * 8 & 0xff;\n }\n}\n\nBuffer.prototype.writeUInt32LE = function writeUInt32LE(value, offset, noAssert) {\n value = +value;\n offset = offset | 0;\n if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0);\n\n if (Buffer.TYPED_ARRAY_SUPPORT) {\n this[offset + 3] = value >>> 24;\n this[offset + 2] = value >>> 16;\n this[offset + 1] = value >>> 8;\n this[offset] = value & 0xff;\n } else {\n objectWriteUInt32(this, value, offset, true);\n }\n\n return offset + 4;\n};\n\nBuffer.prototype.writeUInt32BE = function writeUInt32BE(value, offset, noAssert) {\n value = +value;\n offset = offset | 0;\n if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0);\n\n if (Buffer.TYPED_ARRAY_SUPPORT) {\n this[offset] = value >>> 24;\n this[offset + 1] = value >>> 16;\n this[offset + 2] = value >>> 8;\n this[offset + 3] = value & 0xff;\n } else {\n objectWriteUInt32(this, value, offset, false);\n }\n\n return offset + 4;\n};\n\nBuffer.prototype.writeIntLE = function writeIntLE(value, offset, byteLength, noAssert) {\n value = +value;\n offset = offset | 0;\n\n if (!noAssert) {\n var limit = Math.pow(2, 8 * byteLength - 1);\n checkInt(this, value, offset, byteLength, limit - 1, -limit);\n }\n\n var i = 0;\n var mul = 1;\n var sub = 0;\n this[offset] = value & 0xFF;\n\n while (++i < byteLength && (mul *= 0x100)) {\n if (value < 0 && sub === 0 && this[offset + i - 1] !== 0) {\n sub = 1;\n }\n\n this[offset + i] = (value / mul >> 0) - sub & 0xFF;\n }\n\n return offset + byteLength;\n};\n\nBuffer.prototype.writeIntBE = function writeIntBE(value, offset, byteLength, noAssert) {\n value = +value;\n offset = offset | 0;\n\n if (!noAssert) {\n var limit = Math.pow(2, 8 * byteLength - 1);\n checkInt(this, value, offset, byteLength, limit - 1, -limit);\n }\n\n var i = byteLength - 1;\n var mul = 1;\n var sub = 0;\n this[offset + i] = value & 0xFF;\n\n while (--i >= 0 && (mul *= 0x100)) {\n if (value < 0 && sub === 0 && this[offset + i + 1] !== 0) {\n sub = 1;\n }\n\n this[offset + i] = (value / mul >> 0) - sub & 0xFF;\n }\n\n return offset + byteLength;\n};\n\nBuffer.prototype.writeInt8 = function writeInt8(value, offset, noAssert) {\n value = +value;\n offset = offset | 0;\n if (!noAssert) checkInt(this, value, offset, 1, 0x7f, -0x80);\n if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value);\n if (value < 0) value = 0xff + value + 1;\n this[offset] = value & 0xff;\n return offset + 1;\n};\n\nBuffer.prototype.writeInt16LE = function writeInt16LE(value, offset, noAssert) {\n value = +value;\n offset = offset | 0;\n if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000);\n\n if (Buffer.TYPED_ARRAY_SUPPORT) {\n this[offset] = value & 0xff;\n this[offset + 1] = value >>> 8;\n } else {\n objectWriteUInt16(this, value, offset, true);\n }\n\n return offset + 2;\n};\n\nBuffer.prototype.writeInt16BE = function writeInt16BE(value, offset, noAssert) {\n value = +value;\n offset = offset | 0;\n if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000);\n\n if (Buffer.TYPED_ARRAY_SUPPORT) {\n this[offset] = value >>> 8;\n this[offset + 1] = value & 0xff;\n } else {\n objectWriteUInt16(this, value, offset, false);\n }\n\n return offset + 2;\n};\n\nBuffer.prototype.writeInt32LE = function writeInt32LE(value, offset, noAssert) {\n value = +value;\n offset = offset | 0;\n if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000);\n\n if (Buffer.TYPED_ARRAY_SUPPORT) {\n this[offset] = value & 0xff;\n this[offset + 1] = value >>> 8;\n this[offset + 2] = value >>> 16;\n this[offset + 3] = value >>> 24;\n } else {\n objectWriteUInt32(this, value, offset, true);\n }\n\n return offset + 4;\n};\n\nBuffer.prototype.writeInt32BE = function writeInt32BE(value, offset, noAssert) {\n value = +value;\n offset = offset | 0;\n if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000);\n if (value < 0) value = 0xffffffff + value + 1;\n\n if (Buffer.TYPED_ARRAY_SUPPORT) {\n this[offset] = value >>> 24;\n this[offset + 1] = value >>> 16;\n this[offset + 2] = value >>> 8;\n this[offset + 3] = value & 0xff;\n } else {\n objectWriteUInt32(this, value, offset, false);\n }\n\n return offset + 4;\n};\n\nfunction checkIEEE754(buf, value, offset, ext, max, min) {\n if (offset + ext > buf.length) throw new RangeError('Index out of range');\n if (offset < 0) throw new RangeError('Index out of range');\n}\n\nfunction writeFloat(buf, value, offset, littleEndian, noAssert) {\n if (!noAssert) {\n checkIEEE754(buf, value, offset, 4, 3.4028234663852886e+38, -3.4028234663852886e+38);\n }\n\n ieee754.write(buf, value, offset, littleEndian, 23, 4);\n return offset + 4;\n}\n\nBuffer.prototype.writeFloatLE = function writeFloatLE(value, offset, noAssert) {\n return writeFloat(this, value, offset, true, noAssert);\n};\n\nBuffer.prototype.writeFloatBE = function writeFloatBE(value, offset, noAssert) {\n return writeFloat(this, value, offset, false, noAssert);\n};\n\nfunction writeDouble(buf, value, offset, littleEndian, noAssert) {\n if (!noAssert) {\n checkIEEE754(buf, value, offset, 8, 1.7976931348623157E+308, -1.7976931348623157E+308);\n }\n\n ieee754.write(buf, value, offset, littleEndian, 52, 8);\n return offset + 8;\n}\n\nBuffer.prototype.writeDoubleLE = function writeDoubleLE(value, offset, noAssert) {\n return writeDouble(this, value, offset, true, noAssert);\n};\n\nBuffer.prototype.writeDoubleBE = function writeDoubleBE(value, offset, noAssert) {\n return writeDouble(this, value, offset, false, noAssert);\n}; // copy(targetBuffer, targetStart=0, sourceStart=0, sourceEnd=buffer.length)\n\n\nBuffer.prototype.copy = function copy(target, targetStart, start, end) {\n if (!start) start = 0;\n if (!end && end !== 0) end = this.length;\n if (targetStart >= target.length) targetStart = target.length;\n if (!targetStart) targetStart = 0;\n if (end > 0 && end < start) end = start; // Copy 0 bytes; we're done\n\n if (end === start) return 0;\n if (target.length === 0 || this.length === 0) return 0; // Fatal error conditions\n\n if (targetStart < 0) {\n throw new RangeError('targetStart out of bounds');\n }\n\n if (start < 0 || start >= this.length) throw new RangeError('sourceStart out of bounds');\n if (end < 0) throw new RangeError('sourceEnd out of bounds'); // Are we oob?\n\n if (end > this.length) end = this.length;\n\n if (target.length - targetStart < end - start) {\n end = target.length - targetStart + start;\n }\n\n var len = end - start;\n var i;\n\n if (this === target && start < targetStart && targetStart < end) {\n // descending copy from end\n for (i = len - 1; i >= 0; --i) {\n target[i + targetStart] = this[i + start];\n }\n } else if (len < 1000 || !Buffer.TYPED_ARRAY_SUPPORT) {\n // ascending copy from start\n for (i = 0; i < len; ++i) {\n target[i + targetStart] = this[i + start];\n }\n } else {\n Uint8Array.prototype.set.call(target, this.subarray(start, start + len), targetStart);\n }\n\n return len;\n}; // Usage:\n// buffer.fill(number[, offset[, end]])\n// buffer.fill(buffer[, offset[, end]])\n// buffer.fill(string[, offset[, end]][, encoding])\n\n\nBuffer.prototype.fill = function fill(val, start, end, encoding) {\n // Handle string cases:\n if (typeof val === 'string') {\n if (typeof start === 'string') {\n encoding = start;\n start = 0;\n end = this.length;\n } else if (typeof end === 'string') {\n encoding = end;\n end = this.length;\n }\n\n if (val.length === 1) {\n var code = val.charCodeAt(0);\n\n if (code < 256) {\n val = code;\n }\n }\n\n if (encoding !== undefined && typeof encoding !== 'string') {\n throw new TypeError('encoding must be a string');\n }\n\n if (typeof encoding === 'string' && !Buffer.isEncoding(encoding)) {\n throw new TypeError('Unknown encoding: ' + encoding);\n }\n } else if (typeof val === 'number') {\n val = val & 255;\n } // Invalid ranges are not set to a default, so can range check early.\n\n\n if (start < 0 || this.length < start || this.length < end) {\n throw new RangeError('Out of range index');\n }\n\n if (end <= start) {\n return this;\n }\n\n start = start >>> 0;\n end = end === undefined ? this.length : end >>> 0;\n if (!val) val = 0;\n var i;\n\n if (typeof val === 'number') {\n for (i = start; i < end; ++i) {\n this[i] = val;\n }\n } else {\n var bytes = Buffer.isBuffer(val) ? val : utf8ToBytes(new Buffer(val, encoding).toString());\n var len = bytes.length;\n\n for (i = 0; i < end - start; ++i) {\n this[i + start] = bytes[i % len];\n }\n }\n\n return this;\n}; // HELPER FUNCTIONS\n// ================\n\n\nvar INVALID_BASE64_RE = /[^+\\/0-9A-Za-z-_]/g;\n\nfunction base64clean(str) {\n // Node strips out invalid characters like \\n and \\t from the string, base64-js does not\n str = stringtrim(str).replace(INVALID_BASE64_RE, ''); // Node converts strings with length < 2 to ''\n\n if (str.length < 2) return ''; // Node allows for non-padded base64 strings (missing trailing ===), base64-js does not\n\n while (str.length % 4 !== 0) {\n str = str + '=';\n }\n\n return str;\n}\n\nfunction stringtrim(str) {\n if (str.trim) return str.trim();\n return str.replace(/^\\s+|\\s+$/g, '');\n}\n\nfunction toHex(n) {\n if (n < 16) return '0' + n.toString(16);\n return n.toString(16);\n}\n\nfunction utf8ToBytes(string, units) {\n units = units || Infinity;\n var codePoint;\n var length = string.length;\n var leadSurrogate = null;\n var bytes = [];\n\n for (var i = 0; i < length; ++i) {\n codePoint = string.charCodeAt(i); // is surrogate component\n\n if (codePoint > 0xD7FF && codePoint < 0xE000) {\n // last char was a lead\n if (!leadSurrogate) {\n // no lead yet\n if (codePoint > 0xDBFF) {\n // unexpected trail\n if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD);\n continue;\n } else if (i + 1 === length) {\n // unpaired lead\n if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD);\n continue;\n } // valid lead\n\n\n leadSurrogate = codePoint;\n continue;\n } // 2 leads in a row\n\n\n if (codePoint < 0xDC00) {\n if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD);\n leadSurrogate = codePoint;\n continue;\n } // valid surrogate pair\n\n\n codePoint = (leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00) + 0x10000;\n } else if (leadSurrogate) {\n // valid bmp char, but last char was a lead\n if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD);\n }\n\n leadSurrogate = null; // encode utf8\n\n if (codePoint < 0x80) {\n if ((units -= 1) < 0) break;\n bytes.push(codePoint);\n } else if (codePoint < 0x800) {\n if ((units -= 2) < 0) break;\n bytes.push(codePoint >> 0x6 | 0xC0, codePoint & 0x3F | 0x80);\n } else if (codePoint < 0x10000) {\n if ((units -= 3) < 0) break;\n bytes.push(codePoint >> 0xC | 0xE0, codePoint >> 0x6 & 0x3F | 0x80, codePoint & 0x3F | 0x80);\n } else if (codePoint < 0x110000) {\n if ((units -= 4) < 0) break;\n bytes.push(codePoint >> 0x12 | 0xF0, codePoint >> 0xC & 0x3F | 0x80, codePoint >> 0x6 & 0x3F | 0x80, codePoint & 0x3F | 0x80);\n } else {\n throw new Error('Invalid code point');\n }\n }\n\n return bytes;\n}\n\nfunction asciiToBytes(str) {\n var byteArray = [];\n\n for (var i = 0; i < str.length; ++i) {\n // Node's code seems to be doing this and not & 0x7F..\n byteArray.push(str.charCodeAt(i) & 0xFF);\n }\n\n return byteArray;\n}\n\nfunction utf16leToBytes(str, units) {\n var c, hi, lo;\n var byteArray = [];\n\n for (var i = 0; i < str.length; ++i) {\n if ((units -= 2) < 0) break;\n c = str.charCodeAt(i);\n hi = c >> 8;\n lo = c % 256;\n byteArray.push(lo);\n byteArray.push(hi);\n }\n\n return byteArray;\n}\n\nfunction base64ToBytes(str) {\n return base64.toByteArray(base64clean(str));\n}\n\nfunction blitBuffer(src, dst, offset, length) {\n for (var i = 0; i < length; ++i) {\n if (i + offset >= dst.length || i >= src.length) break;\n dst[i + offset] = src[i];\n }\n\n return i;\n}\n\nfunction isnan(val) {\n return val !== val; // eslint-disable-line no-self-compare\n}","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _extends = Object.assign || function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n\n return target;\n};\n\nexports.default = generatePropsFromAttributes;\n\nvar _htmlAttributesToReact = require('./htmlAttributesToReact');\n\nvar _htmlAttributesToReact2 = _interopRequireDefault(_htmlAttributesToReact);\n\nvar _inlineStyleToObject = require('./inlineStyleToObject');\n\nvar _inlineStyleToObject2 = _interopRequireDefault(_inlineStyleToObject);\n\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n/**\n * Generates props for a React element from an object of HTML attributes\n *\n * @param {Object} attributes The HTML attributes\n * @param {String} key The key to give the react element\n */\n\n\nfunction generatePropsFromAttributes(attributes, key) {\n // generate props\n var props = _extends({}, (0, _htmlAttributesToReact2.default)(attributes), {\n key: key\n }); // if there is an inline/string style prop then convert it to a React style object\n // otherwise, it is invalid and omitted\n\n\n if (typeof props.style === 'string' || props.style instanceof String) {\n props.style = (0, _inlineStyleToObject2.default)(props.style);\n } else {\n delete props.style;\n }\n\n return props;\n}","\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = isValidTagOrAttributeName;\nvar VALID_TAG_REGEX = /^[a-zA-Z][a-zA-Z:_\\.\\-\\d]*$/;\nvar nameCache = {};\n\nfunction isValidTagOrAttributeName(tagName) {\n if (!nameCache.hasOwnProperty(tagName)) {\n nameCache[tagName] = VALID_TAG_REGEX.test(tagName);\n }\n\n return nameCache[tagName];\n}","//! moment.js locale configuration\n//! locale : Tamil [ta]\n//! author : Arjunkumar Krishnamoorthy : https://github.com/tk120404\n;\n\n(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined' && typeof require === 'function' ? factory(require('../moment')) : typeof define === 'function' && define.amd ? define(['../moment'], factory) : factory(global.moment);\n})(this, function (moment) {\n 'use strict'; //! moment.js locale configuration\n\n var symbolMap = {\n '1': '௧',\n '2': '௨',\n '3': '௩',\n '4': '௪',\n '5': '௫',\n '6': '௬',\n '7': '௭',\n '8': '௮',\n '9': '௯',\n '0': '௦'\n },\n numberMap = {\n '௧': '1',\n '௨': '2',\n '௩': '3',\n '௪': '4',\n '௫': '5',\n '௬': '6',\n '௭': '7',\n '௮': '8',\n '௯': '9',\n '௦': '0'\n };\n var ta = moment.defineLocale('ta', {\n months: 'ஜனவரி_பிப்ரவரி_மார்ச்_ஏப்ரல்_மே_ஜூன்_ஜூலை_ஆகஸ்ட்_செப்டெம்பர்_அக்டோபர்_நவம்பர்_டிசம்பர்'.split('_'),\n monthsShort: 'ஜனவரி_பிப்ரவரி_மார்ச்_ஏப்ரல்_மே_ஜூன்_ஜூலை_ஆகஸ்ட்_செப்டெம்பர்_அக்டோபர்_நவம்பர்_டிசம்பர்'.split('_'),\n weekdays: 'ஞாயிற்றுக்கிழமை_திங்கட்கிழமை_செவ்வாய்கிழமை_புதன்கிழமை_வியாழக்கிழமை_வெள்ளிக்கிழமை_சனிக்கிழமை'.split('_'),\n weekdaysShort: 'ஞாயிறு_திங்கள்_செவ்வாய்_புதன்_வியாழன்_வெள்ளி_சனி'.split('_'),\n weekdaysMin: 'ஞா_தி_செ_பு_வி_வெ_ச'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, HH:mm',\n LLLL: 'dddd, D MMMM YYYY, HH:mm'\n },\n calendar: {\n sameDay: '[இன்று] LT',\n nextDay: '[நாளை] LT',\n nextWeek: 'dddd, LT',\n lastDay: '[நேற்று] LT',\n lastWeek: '[கடந்த வாரம்] dddd, LT',\n sameElse: 'L'\n },\n relativeTime: {\n future: '%s இல்',\n past: '%s முன்',\n s: 'ஒரு சில விநாடிகள்',\n ss: '%d விநாடிகள்',\n m: 'ஒரு நிமிடம்',\n mm: '%d நிமிடங்கள்',\n h: 'ஒரு மணி நேரம்',\n hh: '%d மணி நேரம்',\n d: 'ஒரு நாள்',\n dd: '%d நாட்கள்',\n M: 'ஒரு மாதம்',\n MM: '%d மாதங்கள்',\n y: 'ஒரு வருடம்',\n yy: '%d ஆண்டுகள்'\n },\n dayOfMonthOrdinalParse: /\\d{1,2}வது/,\n ordinal: function ordinal(number) {\n return number + 'வது';\n },\n preparse: function preparse(string) {\n return string.replace(/[௧௨௩௪௫௬௭௮௯௦]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function postformat(string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n // refer http://ta.wikipedia.org/s/1er1\n meridiemParse: /யாமம்|வைகறை|காலை|நண்பகல்|எற்பாடு|மாலை/,\n meridiem: function meridiem(hour, minute, isLower) {\n if (hour < 2) {\n return ' யாமம்';\n } else if (hour < 6) {\n return ' வைகறை'; // வைகறை\n } else if (hour < 10) {\n return ' காலை'; // காலை\n } else if (hour < 14) {\n return ' நண்பகல்'; // நண்பகல்\n } else if (hour < 18) {\n return ' எற்பாடு'; // எற்பாடு\n } else if (hour < 22) {\n return ' மாலை'; // மாலை\n } else {\n return ' யாமம்';\n }\n },\n meridiemHour: function meridiemHour(hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n\n if (meridiem === 'யாமம்') {\n return hour < 2 ? hour : hour + 12;\n } else if (meridiem === 'வைகறை' || meridiem === 'காலை') {\n return hour;\n } else if (meridiem === 'நண்பகல்') {\n return hour >= 10 ? hour : hour + 12;\n } else {\n return hour + 12;\n }\n },\n week: {\n dow: 0,\n // Sunday is the first day of the week.\n doy: 6 // The week that contains Jan 6th is the first week of the year.\n\n }\n });\n return ta;\n});","/* Web Font Loader v1.6.28 - (c) Adobe Systems, Google. License: Apache 2.0 */\n(function () {\n function aa(a, b, c) {\n return a.call.apply(a.bind, arguments);\n }\n\n function ba(a, b, c) {\n if (!a) throw Error();\n\n if (2 < arguments.length) {\n var d = Array.prototype.slice.call(arguments, 2);\n return function () {\n var c = Array.prototype.slice.call(arguments);\n Array.prototype.unshift.apply(c, d);\n return a.apply(b, c);\n };\n }\n\n return function () {\n return a.apply(b, arguments);\n };\n }\n\n function p(a, b, c) {\n p = Function.prototype.bind && -1 != Function.prototype.bind.toString().indexOf(\"native code\") ? aa : ba;\n return p.apply(null, arguments);\n }\n\n var q = Date.now || function () {\n return +new Date();\n };\n\n function ca(a, b) {\n this.a = a;\n this.o = b || a;\n this.c = this.o.document;\n }\n\n var da = !!window.FontFace;\n\n function t(a, b, c, d) {\n b = a.c.createElement(b);\n if (c) for (var e in c) {\n c.hasOwnProperty(e) && (\"style\" == e ? b.style.cssText = c[e] : b.setAttribute(e, c[e]));\n }\n d && b.appendChild(a.c.createTextNode(d));\n return b;\n }\n\n function u(a, b, c) {\n a = a.c.getElementsByTagName(b)[0];\n a || (a = document.documentElement);\n a.insertBefore(c, a.lastChild);\n }\n\n function v(a) {\n a.parentNode && a.parentNode.removeChild(a);\n }\n\n function w(a, b, c) {\n b = b || [];\n c = c || [];\n\n for (var d = a.className.split(/\\s+/), e = 0; e < b.length; e += 1) {\n for (var f = !1, g = 0; g < d.length; g += 1) {\n if (b[e] === d[g]) {\n f = !0;\n break;\n }\n }\n\n f || d.push(b[e]);\n }\n\n b = [];\n\n for (e = 0; e < d.length; e += 1) {\n f = !1;\n\n for (g = 0; g < c.length; g += 1) {\n if (d[e] === c[g]) {\n f = !0;\n break;\n }\n }\n\n f || b.push(d[e]);\n }\n\n a.className = b.join(\" \").replace(/\\s+/g, \" \").replace(/^\\s+|\\s+$/, \"\");\n }\n\n function y(a, b) {\n for (var c = a.className.split(/\\s+/), d = 0, e = c.length; d < e; d++) {\n if (c[d] == b) return !0;\n }\n\n return !1;\n }\n\n function ea(a) {\n return a.o.location.hostname || a.a.location.hostname;\n }\n\n function z(a, b, c) {\n function d() {\n m && e && f && (m(g), m = null);\n }\n\n b = t(a, \"link\", {\n rel: \"stylesheet\",\n href: b,\n media: \"all\"\n });\n var e = !1,\n f = !0,\n g = null,\n m = c || null;\n da ? (b.onload = function () {\n e = !0;\n d();\n }, b.onerror = function () {\n e = !0;\n g = Error(\"Stylesheet failed to load\");\n d();\n }) : setTimeout(function () {\n e = !0;\n d();\n }, 0);\n u(a, \"head\", b);\n }\n\n function A(a, b, c, d) {\n var e = a.c.getElementsByTagName(\"head\")[0];\n\n if (e) {\n var f = t(a, \"script\", {\n src: b\n }),\n g = !1;\n\n f.onload = f.onreadystatechange = function () {\n g || this.readyState && \"loaded\" != this.readyState && \"complete\" != this.readyState || (g = !0, c && c(null), f.onload = f.onreadystatechange = null, \"HEAD\" == f.parentNode.tagName && e.removeChild(f));\n };\n\n e.appendChild(f);\n setTimeout(function () {\n g || (g = !0, c && c(Error(\"Script load timeout\")));\n }, d || 5E3);\n return f;\n }\n\n return null;\n }\n\n ;\n\n function B() {\n this.a = 0;\n this.c = null;\n }\n\n function C(a) {\n a.a++;\n return function () {\n a.a--;\n D(a);\n };\n }\n\n function E(a, b) {\n a.c = b;\n D(a);\n }\n\n function D(a) {\n 0 == a.a && a.c && (a.c(), a.c = null);\n }\n\n ;\n\n function F(a) {\n this.a = a || \"-\";\n }\n\n F.prototype.c = function (a) {\n for (var b = [], c = 0; c < arguments.length; c++) {\n b.push(arguments[c].replace(/[\\W_]+/g, \"\").toLowerCase());\n }\n\n return b.join(this.a);\n };\n\n function G(a, b) {\n this.c = a;\n this.f = 4;\n this.a = \"n\";\n var c = (b || \"n4\").match(/^([nio])([1-9])$/i);\n c && (this.a = c[1], this.f = parseInt(c[2], 10));\n }\n\n function fa(a) {\n return H(a) + \" \" + (a.f + \"00\") + \" 300px \" + I(a.c);\n }\n\n function I(a) {\n var b = [];\n a = a.split(/,\\s*/);\n\n for (var c = 0; c < a.length; c++) {\n var d = a[c].replace(/['\"]/g, \"\");\n -1 != d.indexOf(\" \") || /^\\d/.test(d) ? b.push(\"'\" + d + \"'\") : b.push(d);\n }\n\n return b.join(\",\");\n }\n\n function J(a) {\n return a.a + a.f;\n }\n\n function H(a) {\n var b = \"normal\";\n \"o\" === a.a ? b = \"oblique\" : \"i\" === a.a && (b = \"italic\");\n return b;\n }\n\n function ga(a) {\n var b = 4,\n c = \"n\",\n d = null;\n a && ((d = a.match(/(normal|oblique|italic)/i)) && d[1] && (c = d[1].substr(0, 1).toLowerCase()), (d = a.match(/([1-9]00|normal|bold)/i)) && d[1] && (/bold/i.test(d[1]) ? b = 7 : /[1-9]00/.test(d[1]) && (b = parseInt(d[1].substr(0, 1), 10))));\n return c + b;\n }\n\n ;\n\n function ha(a, b) {\n this.c = a;\n this.f = a.o.document.documentElement;\n this.h = b;\n this.a = new F(\"-\");\n this.j = !1 !== b.events;\n this.g = !1 !== b.classes;\n }\n\n function ia(a) {\n a.g && w(a.f, [a.a.c(\"wf\", \"loading\")]);\n K(a, \"loading\");\n }\n\n function L(a) {\n if (a.g) {\n var b = y(a.f, a.a.c(\"wf\", \"active\")),\n c = [],\n d = [a.a.c(\"wf\", \"loading\")];\n b || c.push(a.a.c(\"wf\", \"inactive\"));\n w(a.f, c, d);\n }\n\n K(a, \"inactive\");\n }\n\n function K(a, b, c) {\n if (a.j && a.h[b]) if (c) a.h[b](c.c, J(c));else a.h[b]();\n }\n\n ;\n\n function ja() {\n this.c = {};\n }\n\n function ka(a, b, c) {\n var d = [],\n e;\n\n for (e in b) {\n if (b.hasOwnProperty(e)) {\n var f = a.c[e];\n f && d.push(f(b[e], c));\n }\n }\n\n return d;\n }\n\n ;\n\n function M(a, b) {\n this.c = a;\n this.f = b;\n this.a = t(this.c, \"span\", {\n \"aria-hidden\": \"true\"\n }, this.f);\n }\n\n function N(a) {\n u(a.c, \"body\", a.a);\n }\n\n function O(a) {\n return \"display:block;position:absolute;top:-9999px;left:-9999px;font-size:300px;width:auto;height:auto;line-height:normal;margin:0;padding:0;font-variant:normal;white-space:nowrap;font-family:\" + I(a.c) + \";\" + (\"font-style:\" + H(a) + \";font-weight:\" + (a.f + \"00\") + \";\");\n }\n\n ;\n\n function P(a, b, c, d, e, f) {\n this.g = a;\n this.j = b;\n this.a = d;\n this.c = c;\n this.f = e || 3E3;\n this.h = f || void 0;\n }\n\n P.prototype.start = function () {\n var a = this.c.o.document,\n b = this,\n c = q(),\n d = new Promise(function (d, e) {\n function f() {\n q() - c >= b.f ? e() : a.fonts.load(fa(b.a), b.h).then(function (a) {\n 1 <= a.length ? d() : setTimeout(f, 25);\n }, function () {\n e();\n });\n }\n\n f();\n }),\n e = null,\n f = new Promise(function (a, d) {\n e = setTimeout(d, b.f);\n });\n Promise.race([f, d]).then(function () {\n e && (clearTimeout(e), e = null);\n b.g(b.a);\n }, function () {\n b.j(b.a);\n });\n };\n\n function Q(a, b, c, d, e, f, g) {\n this.v = a;\n this.B = b;\n this.c = c;\n this.a = d;\n this.s = g || \"BESbswy\";\n this.f = {};\n this.w = e || 3E3;\n this.u = f || null;\n this.m = this.j = this.h = this.g = null;\n this.g = new M(this.c, this.s);\n this.h = new M(this.c, this.s);\n this.j = new M(this.c, this.s);\n this.m = new M(this.c, this.s);\n a = new G(this.a.c + \",serif\", J(this.a));\n a = O(a);\n this.g.a.style.cssText = a;\n a = new G(this.a.c + \",sans-serif\", J(this.a));\n a = O(a);\n this.h.a.style.cssText = a;\n a = new G(\"serif\", J(this.a));\n a = O(a);\n this.j.a.style.cssText = a;\n a = new G(\"sans-serif\", J(this.a));\n a = O(a);\n this.m.a.style.cssText = a;\n N(this.g);\n N(this.h);\n N(this.j);\n N(this.m);\n }\n\n var R = {\n D: \"serif\",\n C: \"sans-serif\"\n },\n S = null;\n\n function T() {\n if (null === S) {\n var a = /AppleWebKit\\/([0-9]+)(?:\\.([0-9]+))/.exec(window.navigator.userAgent);\n S = !!a && (536 > parseInt(a[1], 10) || 536 === parseInt(a[1], 10) && 11 >= parseInt(a[2], 10));\n }\n\n return S;\n }\n\n Q.prototype.start = function () {\n this.f.serif = this.j.a.offsetWidth;\n this.f[\"sans-serif\"] = this.m.a.offsetWidth;\n this.A = q();\n U(this);\n };\n\n function la(a, b, c) {\n for (var d in R) {\n if (R.hasOwnProperty(d) && b === a.f[R[d]] && c === a.f[R[d]]) return !0;\n }\n\n return !1;\n }\n\n function U(a) {\n var b = a.g.a.offsetWidth,\n c = a.h.a.offsetWidth,\n d;\n (d = b === a.f.serif && c === a.f[\"sans-serif\"]) || (d = T() && la(a, b, c));\n d ? q() - a.A >= a.w ? T() && la(a, b, c) && (null === a.u || a.u.hasOwnProperty(a.a.c)) ? V(a, a.v) : V(a, a.B) : ma(a) : V(a, a.v);\n }\n\n function ma(a) {\n setTimeout(p(function () {\n U(this);\n }, a), 50);\n }\n\n function V(a, b) {\n setTimeout(p(function () {\n v(this.g.a);\n v(this.h.a);\n v(this.j.a);\n v(this.m.a);\n b(this.a);\n }, a), 0);\n }\n\n ;\n\n function W(a, b, c) {\n this.c = a;\n this.a = b;\n this.f = 0;\n this.m = this.j = !1;\n this.s = c;\n }\n\n var X = null;\n\n W.prototype.g = function (a) {\n var b = this.a;\n b.g && w(b.f, [b.a.c(\"wf\", a.c, J(a).toString(), \"active\")], [b.a.c(\"wf\", a.c, J(a).toString(), \"loading\"), b.a.c(\"wf\", a.c, J(a).toString(), \"inactive\")]);\n K(b, \"fontactive\", a);\n this.m = !0;\n na(this);\n };\n\n W.prototype.h = function (a) {\n var b = this.a;\n\n if (b.g) {\n var c = y(b.f, b.a.c(\"wf\", a.c, J(a).toString(), \"active\")),\n d = [],\n e = [b.a.c(\"wf\", a.c, J(a).toString(), \"loading\")];\n c || d.push(b.a.c(\"wf\", a.c, J(a).toString(), \"inactive\"));\n w(b.f, d, e);\n }\n\n K(b, \"fontinactive\", a);\n na(this);\n };\n\n function na(a) {\n 0 == --a.f && a.j && (a.m ? (a = a.a, a.g && w(a.f, [a.a.c(\"wf\", \"active\")], [a.a.c(\"wf\", \"loading\"), a.a.c(\"wf\", \"inactive\")]), K(a, \"active\")) : L(a.a));\n }\n\n ;\n\n function oa(a) {\n this.j = a;\n this.a = new ja();\n this.h = 0;\n this.f = this.g = !0;\n }\n\n oa.prototype.load = function (a) {\n this.c = new ca(this.j, a.context || this.j);\n this.g = !1 !== a.events;\n this.f = !1 !== a.classes;\n pa(this, new ha(this.c, a), a);\n };\n\n function qa(a, b, c, d, e) {\n var f = 0 == --a.h;\n (a.f || a.g) && setTimeout(function () {\n var a = e || null,\n m = d || null || {};\n if (0 === c.length && f) L(b.a);else {\n b.f += c.length;\n f && (b.j = f);\n var h,\n l = [];\n\n for (h = 0; h < c.length; h++) {\n var k = c[h],\n n = m[k.c],\n r = b.a,\n x = k;\n r.g && w(r.f, [r.a.c(\"wf\", x.c, J(x).toString(), \"loading\")]);\n K(r, \"fontloading\", x);\n r = null;\n if (null === X) if (window.FontFace) {\n var x = /Gecko.*Firefox\\/(\\d+)/.exec(window.navigator.userAgent),\n xa = /OS X.*Version\\/10\\..*Safari/.exec(window.navigator.userAgent) && /Apple/.exec(window.navigator.vendor);\n X = x ? 42 < parseInt(x[1], 10) : xa ? !1 : !0;\n } else X = !1;\n X ? r = new P(p(b.g, b), p(b.h, b), b.c, k, b.s, n) : r = new Q(p(b.g, b), p(b.h, b), b.c, k, b.s, a, n);\n l.push(r);\n }\n\n for (h = 0; h < l.length; h++) {\n l[h].start();\n }\n }\n }, 0);\n }\n\n function pa(a, b, c) {\n var d = [],\n e = c.timeout;\n ia(b);\n var d = ka(a.a, c, a.c),\n f = new W(a.c, b, e);\n a.h = d.length;\n b = 0;\n\n for (c = d.length; b < c; b++) {\n d[b].load(function (b, d, c) {\n qa(a, f, b, d, c);\n });\n }\n }\n\n ;\n\n function ra(a, b) {\n this.c = a;\n this.a = b;\n }\n\n ra.prototype.load = function (a) {\n function b() {\n if (f[\"__mti_fntLst\" + d]) {\n var c = f[\"__mti_fntLst\" + d](),\n e = [],\n h;\n if (c) for (var l = 0; l < c.length; l++) {\n var k = c[l].fontfamily;\n void 0 != c[l].fontStyle && void 0 != c[l].fontWeight ? (h = c[l].fontStyle + c[l].fontWeight, e.push(new G(k, h))) : e.push(new G(k));\n }\n a(e);\n } else setTimeout(function () {\n b();\n }, 50);\n }\n\n var c = this,\n d = c.a.projectId,\n e = c.a.version;\n\n if (d) {\n var f = c.c.o;\n A(this.c, (c.a.api || \"https://fast.fonts.net/jsapi\") + \"/\" + d + \".js\" + (e ? \"?v=\" + e : \"\"), function (e) {\n e ? a([]) : (f[\"__MonotypeConfiguration__\" + d] = function () {\n return c.a;\n }, b());\n }).id = \"__MonotypeAPIScript__\" + d;\n } else a([]);\n };\n\n function sa(a, b) {\n this.c = a;\n this.a = b;\n }\n\n sa.prototype.load = function (a) {\n var b,\n c,\n d = this.a.urls || [],\n e = this.a.families || [],\n f = this.a.testStrings || {},\n g = new B();\n b = 0;\n\n for (c = d.length; b < c; b++) {\n z(this.c, d[b], C(g));\n }\n\n var m = [];\n b = 0;\n\n for (c = e.length; b < c; b++) {\n if (d = e[b].split(\":\"), d[1]) for (var h = d[1].split(\",\"), l = 0; l < h.length; l += 1) {\n m.push(new G(d[0], h[l]));\n } else m.push(new G(d[0]));\n }\n\n E(g, function () {\n a(m, f);\n });\n };\n\n function ta(a, b) {\n a ? this.c = a : this.c = ua;\n this.a = [];\n this.f = [];\n this.g = b || \"\";\n }\n\n var ua = \"https://fonts.googleapis.com/css\";\n\n function va(a, b) {\n for (var c = b.length, d = 0; d < c; d++) {\n var e = b[d].split(\":\");\n 3 == e.length && a.f.push(e.pop());\n var f = \"\";\n 2 == e.length && \"\" != e[1] && (f = \":\");\n a.a.push(e.join(f));\n }\n }\n\n function wa(a) {\n if (0 == a.a.length) throw Error(\"No fonts to load!\");\n if (-1 != a.c.indexOf(\"kit=\")) return a.c;\n\n for (var b = a.a.length, c = [], d = 0; d < b; d++) {\n c.push(a.a[d].replace(/ /g, \"+\"));\n }\n\n b = a.c + \"?family=\" + c.join(\"%7C\");\n 0 < a.f.length && (b += \"&subset=\" + a.f.join(\",\"));\n 0 < a.g.length && (b += \"&text=\" + encodeURIComponent(a.g));\n return b;\n }\n\n ;\n\n function ya(a) {\n this.f = a;\n this.a = [];\n this.c = {};\n }\n\n var za = {\n latin: \"BESbswy\",\n \"latin-ext\": \"\\xE7\\xF6\\xFC\\u011F\\u015F\",\n cyrillic: \"\\u0439\\u044F\\u0416\",\n greek: \"\\u03B1\\u03B2\\u03A3\",\n khmer: \"\\u1780\\u1781\\u1782\",\n Hanuman: \"\\u1780\\u1781\\u1782\"\n },\n Aa = {\n thin: \"1\",\n extralight: \"2\",\n \"extra-light\": \"2\",\n ultralight: \"2\",\n \"ultra-light\": \"2\",\n light: \"3\",\n regular: \"4\",\n book: \"4\",\n medium: \"5\",\n \"semi-bold\": \"6\",\n semibold: \"6\",\n \"demi-bold\": \"6\",\n demibold: \"6\",\n bold: \"7\",\n \"extra-bold\": \"8\",\n extrabold: \"8\",\n \"ultra-bold\": \"8\",\n ultrabold: \"8\",\n black: \"9\",\n heavy: \"9\",\n l: \"3\",\n r: \"4\",\n b: \"7\"\n },\n Ba = {\n i: \"i\",\n italic: \"i\",\n n: \"n\",\n normal: \"n\"\n },\n Ca = /^(thin|(?:(?:extra|ultra)-?)?light|regular|book|medium|(?:(?:semi|demi|extra|ultra)-?)?bold|black|heavy|l|r|b|[1-9]00)?(n|i|normal|italic)?$/;\n\n function Da(a) {\n for (var b = a.f.length, c = 0; c < b; c++) {\n var d = a.f[c].split(\":\"),\n e = d[0].replace(/\\+/g, \" \"),\n f = [\"n4\"];\n\n if (2 <= d.length) {\n var g;\n var m = d[1];\n g = [];\n if (m) for (var m = m.split(\",\"), h = m.length, l = 0; l < h; l++) {\n var k;\n k = m[l];\n\n if (k.match(/^[\\w-]+$/)) {\n var n = Ca.exec(k.toLowerCase());\n if (null == n) k = \"\";else {\n k = n[2];\n k = null == k || \"\" == k ? \"n\" : Ba[k];\n n = n[1];\n if (null == n || \"\" == n) n = \"4\";else var r = Aa[n],\n n = r ? r : isNaN(n) ? \"4\" : n.substr(0, 1);\n k = [k, n].join(\"\");\n }\n } else k = \"\";\n\n k && g.push(k);\n }\n 0 < g.length && (f = g);\n 3 == d.length && (d = d[2], g = [], d = d ? d.split(\",\") : g, 0 < d.length && (d = za[d[0]]) && (a.c[e] = d));\n }\n\n a.c[e] || (d = za[e]) && (a.c[e] = d);\n\n for (d = 0; d < f.length; d += 1) {\n a.a.push(new G(e, f[d]));\n }\n }\n }\n\n ;\n\n function Ea(a, b) {\n this.c = a;\n this.a = b;\n }\n\n var Fa = {\n Arimo: !0,\n Cousine: !0,\n Tinos: !0\n };\n\n Ea.prototype.load = function (a) {\n var b = new B(),\n c = this.c,\n d = new ta(this.a.api, this.a.text),\n e = this.a.families;\n va(d, e);\n var f = new ya(e);\n Da(f);\n z(c, wa(d), C(b));\n E(b, function () {\n a(f.a, f.c, Fa);\n });\n };\n\n function Ga(a, b) {\n this.c = a;\n this.a = b;\n }\n\n Ga.prototype.load = function (a) {\n var b = this.a.id,\n c = this.c.o;\n b ? A(this.c, (this.a.api || \"https://use.typekit.net\") + \"/\" + b + \".js\", function (b) {\n if (b) a([]);else if (c.Typekit && c.Typekit.config && c.Typekit.config.fn) {\n b = c.Typekit.config.fn;\n\n for (var e = [], f = 0; f < b.length; f += 2) {\n for (var g = b[f], m = b[f + 1], h = 0; h < m.length; h++) {\n e.push(new G(g, m[h]));\n }\n }\n\n try {\n c.Typekit.load({\n events: !1,\n classes: !1,\n async: !0\n });\n } catch (l) {}\n\n a(e);\n }\n }, 2E3) : a([]);\n };\n\n function Ha(a, b) {\n this.c = a;\n this.f = b;\n this.a = [];\n }\n\n Ha.prototype.load = function (a) {\n var b = this.f.id,\n c = this.c.o,\n d = this;\n b ? (c.__webfontfontdeckmodule__ || (c.__webfontfontdeckmodule__ = {}), c.__webfontfontdeckmodule__[b] = function (b, c) {\n for (var g = 0, m = c.fonts.length; g < m; ++g) {\n var h = c.fonts[g];\n d.a.push(new G(h.name, ga(\"font-weight:\" + h.weight + \";font-style:\" + h.style)));\n }\n\n a(d.a);\n }, A(this.c, (this.f.api || \"https://f.fontdeck.com/s/css/js/\") + ea(this.c) + \"/\" + b + \".js\", function (b) {\n b && a([]);\n })) : a([]);\n };\n\n var Y = new oa(window);\n\n Y.a.c.custom = function (a, b) {\n return new sa(b, a);\n };\n\n Y.a.c.fontdeck = function (a, b) {\n return new Ha(b, a);\n };\n\n Y.a.c.monotype = function (a, b) {\n return new ra(b, a);\n };\n\n Y.a.c.typekit = function (a, b) {\n return new Ga(b, a);\n };\n\n Y.a.c.google = function (a, b) {\n return new Ea(b, a);\n };\n\n var Z = {\n load: p(Y.load, Y)\n };\n \"function\" === typeof define && define.amd ? define(function () {\n return Z;\n }) : \"undefined\" !== typeof module && module.exports ? module.exports = Z : (window.WebFont = Z, window.WebFontConfig && Y.load(window.WebFontConfig));\n})();","module.exports = {\n parse: require('./lib/parse'),\n stringify: require('./lib/stringify')\n};","function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\n\nmodule.exports = _classCallCheck;","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nfunction _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}\n\nmodule.exports = _createClass;","(function (factory) {\n typeof exports === 'object' && typeof module !== 'undefined' ? module['exports'] = factory() : typeof define === 'function' && define['amd'] ? define(factory()) : window['stylisRuleSheet'] = factory();\n})(function () {\n 'use strict';\n\n return function (insertRule) {\n var delimiter = '/*|*/';\n var needle = delimiter + '}';\n\n function toSheet(block) {\n if (block) try {\n insertRule(block + '}');\n } catch (e) {}\n }\n\n return function ruleSheet(context, content, selectors, parents, line, column, length, ns, depth, at) {\n switch (context) {\n // property\n case 1:\n // @import\n if (depth === 0 && content.charCodeAt(0) === 64) return insertRule(content + ';'), '';\n break;\n // selector\n\n case 2:\n if (ns === 0) return content + delimiter;\n break;\n // at-rule\n\n case 3:\n switch (ns) {\n // @font-face, @page\n case 102:\n case 112:\n return insertRule(selectors[0] + content), '';\n\n default:\n return content + (at === 0 ? delimiter : '');\n }\n\n case -2:\n content.split(needle).forEach(toSheet);\n }\n };\n };\n});","var assignValue = require('./_assignValue'),\n copyObject = require('./_copyObject'),\n createAssigner = require('./_createAssigner'),\n isArrayLike = require('./isArrayLike'),\n isPrototype = require('./_isPrototype'),\n keys = require('./keys');\n/** Used for built-in method references. */\n\n\nvar objectProto = Object.prototype;\n/** Used to check objects for own properties. */\n\nvar hasOwnProperty = objectProto.hasOwnProperty;\n/**\n * Assigns own enumerable string keyed properties of source objects to the\n * destination object. Source objects are applied from left to right.\n * Subsequent sources overwrite property assignments of previous sources.\n *\n * **Note:** This method mutates `object` and is loosely based on\n * [`Object.assign`](https://mdn.io/Object/assign).\n *\n * @static\n * @memberOf _\n * @since 0.10.0\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} [sources] The source objects.\n * @returns {Object} Returns `object`.\n * @see _.assignIn\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * }\n *\n * function Bar() {\n * this.c = 3;\n * }\n *\n * Foo.prototype.b = 2;\n * Bar.prototype.d = 4;\n *\n * _.assign({ 'a': 0 }, new Foo, new Bar);\n * // => { 'a': 1, 'c': 3 }\n */\n\nvar assign = createAssigner(function (object, source) {\n if (isPrototype(source) || isArrayLike(source)) {\n copyObject(source, keys(source), object);\n return;\n }\n\n for (var key in source) {\n if (hasOwnProperty.call(source, key)) {\n assignValue(object, key, source[key]);\n }\n }\n});\nmodule.exports = assign;","'use strict';\n\nvar has = Object.prototype.hasOwnProperty,\n prefix = '~';\n/**\n * Constructor to create a storage for our `EE` objects.\n * An `Events` instance is a plain object whose properties are event names.\n *\n * @constructor\n * @private\n */\n\nfunction Events() {} //\n// We try to not inherit from `Object.prototype`. In some engines creating an\n// instance in this way is faster than calling `Object.create(null)` directly.\n// If `Object.create(null)` is not supported we prefix the event names with a\n// character to make sure that the built-in object properties are not\n// overridden or used as an attack vector.\n//\n\n\nif (Object.create) {\n Events.prototype = Object.create(null); //\n // This hack is needed because the `__proto__` property is still inherited in\n // some old browsers like Android 4, iPhone 5.1, Opera 11 and Safari 5.\n //\n\n if (!new Events().__proto__) prefix = false;\n}\n/**\n * Representation of a single event listener.\n *\n * @param {Function} fn The listener function.\n * @param {*} context The context to invoke the listener with.\n * @param {Boolean} [once=false] Specify if the listener is a one-time listener.\n * @constructor\n * @private\n */\n\n\nfunction EE(fn, context, once) {\n this.fn = fn;\n this.context = context;\n this.once = once || false;\n}\n/**\n * Add a listener for a given event.\n *\n * @param {EventEmitter} emitter Reference to the `EventEmitter` instance.\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn The listener function.\n * @param {*} context The context to invoke the listener with.\n * @param {Boolean} once Specify if the listener is a one-time listener.\n * @returns {EventEmitter}\n * @private\n */\n\n\nfunction addListener(emitter, event, fn, context, once) {\n if (typeof fn !== 'function') {\n throw new TypeError('The listener must be a function');\n }\n\n var listener = new EE(fn, context || emitter, once),\n evt = prefix ? prefix + event : event;\n if (!emitter._events[evt]) emitter._events[evt] = listener, emitter._eventsCount++;else if (!emitter._events[evt].fn) emitter._events[evt].push(listener);else emitter._events[evt] = [emitter._events[evt], listener];\n return emitter;\n}\n/**\n * Clear event by name.\n *\n * @param {EventEmitter} emitter Reference to the `EventEmitter` instance.\n * @param {(String|Symbol)} evt The Event name.\n * @private\n */\n\n\nfunction clearEvent(emitter, evt) {\n if (--emitter._eventsCount === 0) emitter._events = new Events();else delete emitter._events[evt];\n}\n/**\n * Minimal `EventEmitter` interface that is molded against the Node.js\n * `EventEmitter` interface.\n *\n * @constructor\n * @public\n */\n\n\nfunction EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}\n/**\n * Return an array listing the events for which the emitter has registered\n * listeners.\n *\n * @returns {Array}\n * @public\n */\n\n\nEventEmitter.prototype.eventNames = function eventNames() {\n var names = [],\n events,\n name;\n if (this._eventsCount === 0) return names;\n\n for (name in events = this._events) {\n if (has.call(events, name)) names.push(prefix ? name.slice(1) : name);\n }\n\n if (Object.getOwnPropertySymbols) {\n return names.concat(Object.getOwnPropertySymbols(events));\n }\n\n return names;\n};\n/**\n * Return the listeners registered for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @returns {Array} The registered listeners.\n * @public\n */\n\n\nEventEmitter.prototype.listeners = function listeners(event) {\n var evt = prefix ? prefix + event : event,\n handlers = this._events[evt];\n if (!handlers) return [];\n if (handlers.fn) return [handlers.fn];\n\n for (var i = 0, l = handlers.length, ee = new Array(l); i < l; i++) {\n ee[i] = handlers[i].fn;\n }\n\n return ee;\n};\n/**\n * Return the number of listeners listening to a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @returns {Number} The number of listeners.\n * @public\n */\n\n\nEventEmitter.prototype.listenerCount = function listenerCount(event) {\n var evt = prefix ? prefix + event : event,\n listeners = this._events[evt];\n if (!listeners) return 0;\n if (listeners.fn) return 1;\n return listeners.length;\n};\n/**\n * Calls each of the listeners registered for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @returns {Boolean} `true` if the event had listeners, else `false`.\n * @public\n */\n\n\nEventEmitter.prototype.emit = function emit(event, a1, a2, a3, a4, a5) {\n var evt = prefix ? prefix + event : event;\n if (!this._events[evt]) return false;\n var listeners = this._events[evt],\n len = arguments.length,\n args,\n i;\n\n if (listeners.fn) {\n if (listeners.once) this.removeListener(event, listeners.fn, undefined, true);\n\n switch (len) {\n case 1:\n return listeners.fn.call(listeners.context), true;\n\n case 2:\n return listeners.fn.call(listeners.context, a1), true;\n\n case 3:\n return listeners.fn.call(listeners.context, a1, a2), true;\n\n case 4:\n return listeners.fn.call(listeners.context, a1, a2, a3), true;\n\n case 5:\n return listeners.fn.call(listeners.context, a1, a2, a3, a4), true;\n\n case 6:\n return listeners.fn.call(listeners.context, a1, a2, a3, a4, a5), true;\n }\n\n for (i = 1, args = new Array(len - 1); i < len; i++) {\n args[i - 1] = arguments[i];\n }\n\n listeners.fn.apply(listeners.context, args);\n } else {\n var length = listeners.length,\n j;\n\n for (i = 0; i < length; i++) {\n if (listeners[i].once) this.removeListener(event, listeners[i].fn, undefined, true);\n\n switch (len) {\n case 1:\n listeners[i].fn.call(listeners[i].context);\n break;\n\n case 2:\n listeners[i].fn.call(listeners[i].context, a1);\n break;\n\n case 3:\n listeners[i].fn.call(listeners[i].context, a1, a2);\n break;\n\n case 4:\n listeners[i].fn.call(listeners[i].context, a1, a2, a3);\n break;\n\n default:\n if (!args) for (j = 1, args = new Array(len - 1); j < len; j++) {\n args[j - 1] = arguments[j];\n }\n listeners[i].fn.apply(listeners[i].context, args);\n }\n }\n }\n\n return true;\n};\n/**\n * Add a listener for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn The listener function.\n * @param {*} [context=this] The context to invoke the listener with.\n * @returns {EventEmitter} `this`.\n * @public\n */\n\n\nEventEmitter.prototype.on = function on(event, fn, context) {\n return addListener(this, event, fn, context, false);\n};\n/**\n * Add a one-time listener for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn The listener function.\n * @param {*} [context=this] The context to invoke the listener with.\n * @returns {EventEmitter} `this`.\n * @public\n */\n\n\nEventEmitter.prototype.once = function once(event, fn, context) {\n return addListener(this, event, fn, context, true);\n};\n/**\n * Remove the listeners of a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn Only remove the listeners that match this function.\n * @param {*} context Only remove the listeners that have this context.\n * @param {Boolean} once Only remove one-time listeners.\n * @returns {EventEmitter} `this`.\n * @public\n */\n\n\nEventEmitter.prototype.removeListener = function removeListener(event, fn, context, once) {\n var evt = prefix ? prefix + event : event;\n if (!this._events[evt]) return this;\n\n if (!fn) {\n clearEvent(this, evt);\n return this;\n }\n\n var listeners = this._events[evt];\n\n if (listeners.fn) {\n if (listeners.fn === fn && (!once || listeners.once) && (!context || listeners.context === context)) {\n clearEvent(this, evt);\n }\n } else {\n for (var i = 0, events = [], length = listeners.length; i < length; i++) {\n if (listeners[i].fn !== fn || once && !listeners[i].once || context && listeners[i].context !== context) {\n events.push(listeners[i]);\n }\n } //\n // Reset the array, or remove it completely if we have no more listeners.\n //\n\n\n if (events.length) this._events[evt] = events.length === 1 ? events[0] : events;else clearEvent(this, evt);\n }\n\n return this;\n};\n/**\n * Remove all listeners, or those of the specified event.\n *\n * @param {(String|Symbol)} [event] The event name.\n * @returns {EventEmitter} `this`.\n * @public\n */\n\n\nEventEmitter.prototype.removeAllListeners = function removeAllListeners(event) {\n var evt;\n\n if (event) {\n evt = prefix ? prefix + event : event;\n if (this._events[evt]) clearEvent(this, evt);\n } else {\n this._events = new Events();\n this._eventsCount = 0;\n }\n\n return this;\n}; //\n// Alias methods names because people roll like that.\n//\n\n\nEventEmitter.prototype.off = EventEmitter.prototype.removeListener;\nEventEmitter.prototype.addListener = EventEmitter.prototype.on; //\n// Expose the prefix.\n//\n\nEventEmitter.prefixed = prefix; //\n// Allow `EventEmitter` to be imported as module namespace.\n//\n\nEventEmitter.EventEmitter = EventEmitter; //\n// Expose the module.\n//\n\nif ('undefined' !== typeof module) {\n module.exports = EventEmitter;\n}","var baseClone = require('./_baseClone');\n/** Used to compose bitmasks for cloning. */\n\n\nvar CLONE_SYMBOLS_FLAG = 4;\n/**\n * Creates a shallow clone of `value`.\n *\n * **Note:** This method is loosely based on the\n * [structured clone algorithm](https://mdn.io/Structured_clone_algorithm)\n * and supports cloning arrays, array buffers, booleans, date objects, maps,\n * numbers, `Object` objects, regexes, sets, strings, symbols, and typed\n * arrays. The own enumerable properties of `arguments` objects are cloned\n * as plain objects. An empty object is returned for uncloneable values such\n * as error objects, functions, DOM nodes, and WeakMaps.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to clone.\n * @returns {*} Returns the cloned value.\n * @see _.cloneDeep\n * @example\n *\n * var objects = [{ 'a': 1 }, { 'b': 2 }];\n *\n * var shallow = _.clone(objects);\n * console.log(shallow[0] === objects[0]);\n * // => true\n */\n\nfunction clone(value) {\n return baseClone(value, CLONE_SYMBOLS_FLAG);\n}\n\nmodule.exports = clone;","var debounce = require('./debounce'),\n isObject = require('./isObject');\n/** Error message constants. */\n\n\nvar FUNC_ERROR_TEXT = 'Expected a function';\n/**\n * Creates a throttled function that only invokes `func` at most once per\n * every `wait` milliseconds. The throttled function comes with a `cancel`\n * method to cancel delayed `func` invocations and a `flush` method to\n * immediately invoke them. Provide `options` to indicate whether `func`\n * should be invoked on the leading and/or trailing edge of the `wait`\n * timeout. The `func` is invoked with the last arguments provided to the\n * throttled function. Subsequent calls to the throttled function return the\n * result of the last `func` invocation.\n *\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\n * invoked on the trailing edge of the timeout only if the throttled function\n * is invoked more than once during the `wait` timeout.\n *\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\n *\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\n * for details over the differences between `_.throttle` and `_.debounce`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to throttle.\n * @param {number} [wait=0] The number of milliseconds to throttle invocations to.\n * @param {Object} [options={}] The options object.\n * @param {boolean} [options.leading=true]\n * Specify invoking on the leading edge of the timeout.\n * @param {boolean} [options.trailing=true]\n * Specify invoking on the trailing edge of the timeout.\n * @returns {Function} Returns the new throttled function.\n * @example\n *\n * // Avoid excessively updating the position while scrolling.\n * jQuery(window).on('scroll', _.throttle(updatePosition, 100));\n *\n * // Invoke `renewToken` when the click event is fired, but not more than once every 5 minutes.\n * var throttled = _.throttle(renewToken, 300000, { 'trailing': false });\n * jQuery(element).on('click', throttled);\n *\n * // Cancel the trailing throttled invocation.\n * jQuery(window).on('popstate', throttled.cancel);\n */\n\nfunction throttle(func, wait, options) {\n var leading = true,\n trailing = true;\n\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n\n if (isObject(options)) {\n leading = 'leading' in options ? !!options.leading : leading;\n trailing = 'trailing' in options ? !!options.trailing : trailing;\n }\n\n return debounce(func, wait, {\n 'leading': leading,\n 'maxWait': wait,\n 'trailing': trailing\n });\n}\n\nmodule.exports = throttle;","/**\n * This method returns `undefined`.\n *\n * @static\n * @memberOf _\n * @since 2.3.0\n * @category Util\n * @example\n *\n * _.times(2, _.noop);\n * // => [undefined, undefined]\n */\nfunction noop() {// No operation performed.\n}\n\nmodule.exports = noop;","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _extends = Object.assign || function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n\n return target;\n};\n\nvar _createClass = function () {\n function defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n }\n\n return function (Constructor, protoProps, staticProps) {\n if (protoProps) defineProperties(Constructor.prototype, protoProps);\n if (staticProps) defineProperties(Constructor, staticProps);\n return Constructor;\n };\n}();\n\nvar _react = require('react');\n\nvar _react2 = _interopRequireDefault(_react);\n\nvar _propTypes = require('prop-types');\n\nvar _propTypes2 = _interopRequireDefault(_propTypes);\n\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n\nfunction _objectWithoutProperties(obj, keys) {\n var target = {};\n\n for (var i in obj) {\n if (keys.indexOf(i) >= 0) continue;\n if (!Object.prototype.hasOwnProperty.call(obj, i)) continue;\n target[i] = obj[i];\n }\n\n return target;\n}\n\nfunction _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\n\nfunction _possibleConstructorReturn(self, call) {\n if (!self) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self;\n}\n\nfunction _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass);\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass;\n}\n\nvar sizerStyle = {\n position: 'absolute',\n top: 0,\n left: 0,\n visibility: 'hidden',\n height: 0,\n overflow: 'scroll',\n whiteSpace: 'pre'\n};\nvar INPUT_PROPS_BLACKLIST = ['extraWidth', 'injectStyles', 'inputClassName', 'inputRef', 'inputStyle', 'minWidth', 'onAutosize', 'placeholderIsMinWidth'];\n\nvar cleanInputProps = function cleanInputProps(inputProps) {\n INPUT_PROPS_BLACKLIST.forEach(function (field) {\n return delete inputProps[field];\n });\n return inputProps;\n};\n\nvar copyStyles = function copyStyles(styles, node) {\n node.style.fontSize = styles.fontSize;\n node.style.fontFamily = styles.fontFamily;\n node.style.fontWeight = styles.fontWeight;\n node.style.fontStyle = styles.fontStyle;\n node.style.letterSpacing = styles.letterSpacing;\n node.style.textTransform = styles.textTransform;\n};\n\nvar isIE = typeof window !== 'undefined' && window.navigator ? /MSIE |Trident\\/|Edge\\//.test(window.navigator.userAgent) : false;\n\nvar generateId = function generateId() {\n // we only need an auto-generated ID for stylesheet injection, which is only\n // used for IE. so if the browser is not IE, this should return undefined.\n return isIE ? '_' + Math.random().toString(36).substr(2, 12) : undefined;\n};\n\nvar AutosizeInput = function (_Component) {\n _inherits(AutosizeInput, _Component);\n\n function AutosizeInput(props) {\n _classCallCheck(this, AutosizeInput);\n\n var _this = _possibleConstructorReturn(this, (AutosizeInput.__proto__ || Object.getPrototypeOf(AutosizeInput)).call(this, props));\n\n _this.inputRef = function (el) {\n _this.input = el;\n\n if (typeof _this.props.inputRef === 'function') {\n _this.props.inputRef(el);\n }\n };\n\n _this.placeHolderSizerRef = function (el) {\n _this.placeHolderSizer = el;\n };\n\n _this.sizerRef = function (el) {\n _this.sizer = el;\n };\n\n _this.state = {\n inputWidth: props.minWidth,\n inputId: props.id || generateId()\n };\n return _this;\n }\n\n _createClass(AutosizeInput, [{\n key: 'componentDidMount',\n value: function componentDidMount() {\n this.mounted = true;\n this.copyInputStyles();\n this.updateInputWidth();\n }\n }, {\n key: 'UNSAFE_componentWillReceiveProps',\n value: function UNSAFE_componentWillReceiveProps(nextProps) {\n var id = nextProps.id;\n\n if (id !== this.props.id) {\n this.setState({\n inputId: id || generateId()\n });\n }\n }\n }, {\n key: 'componentDidUpdate',\n value: function componentDidUpdate(prevProps, prevState) {\n if (prevState.inputWidth !== this.state.inputWidth) {\n if (typeof this.props.onAutosize === 'function') {\n this.props.onAutosize(this.state.inputWidth);\n }\n }\n\n this.updateInputWidth();\n }\n }, {\n key: 'componentWillUnmount',\n value: function componentWillUnmount() {\n this.mounted = false;\n }\n }, {\n key: 'copyInputStyles',\n value: function copyInputStyles() {\n if (!this.mounted || !window.getComputedStyle) {\n return;\n }\n\n var inputStyles = this.input && window.getComputedStyle(this.input);\n\n if (!inputStyles) {\n return;\n }\n\n copyStyles(inputStyles, this.sizer);\n\n if (this.placeHolderSizer) {\n copyStyles(inputStyles, this.placeHolderSizer);\n }\n }\n }, {\n key: 'updateInputWidth',\n value: function updateInputWidth() {\n if (!this.mounted || !this.sizer || typeof this.sizer.scrollWidth === 'undefined') {\n return;\n }\n\n var newInputWidth = void 0;\n\n if (this.props.placeholder && (!this.props.value || this.props.value && this.props.placeholderIsMinWidth)) {\n newInputWidth = Math.max(this.sizer.scrollWidth, this.placeHolderSizer.scrollWidth) + 2;\n } else {\n newInputWidth = this.sizer.scrollWidth + 2;\n } // add extraWidth to the detected width. for number types, this defaults to 16 to allow for the stepper UI\n\n\n var extraWidth = this.props.type === 'number' && this.props.extraWidth === undefined ? 16 : parseInt(this.props.extraWidth) || 0;\n newInputWidth += extraWidth;\n\n if (newInputWidth < this.props.minWidth) {\n newInputWidth = this.props.minWidth;\n }\n\n if (newInputWidth !== this.state.inputWidth) {\n this.setState({\n inputWidth: newInputWidth\n });\n }\n }\n }, {\n key: 'getInput',\n value: function getInput() {\n return this.input;\n }\n }, {\n key: 'focus',\n value: function focus() {\n this.input.focus();\n }\n }, {\n key: 'blur',\n value: function blur() {\n this.input.blur();\n }\n }, {\n key: 'select',\n value: function select() {\n this.input.select();\n }\n }, {\n key: 'renderStyles',\n value: function renderStyles() {\n // this method injects styles to hide IE's clear indicator, which messes\n // with input size detection. the stylesheet is only injected when the\n // browser is IE, and can also be disabled by the `injectStyles` prop.\n var injectStyles = this.props.injectStyles;\n return isIE && injectStyles ? _react2.default.createElement('style', {\n dangerouslySetInnerHTML: {\n __html: 'input#' + this.state.inputId + '::-ms-clear {display: none;}'\n }\n }) : null;\n }\n }, {\n key: 'render',\n value: function render() {\n var sizerValue = [this.props.defaultValue, this.props.value, ''].reduce(function (previousValue, currentValue) {\n if (previousValue !== null && previousValue !== undefined) {\n return previousValue;\n }\n\n return currentValue;\n });\n\n var wrapperStyle = _extends({}, this.props.style);\n\n if (!wrapperStyle.display) wrapperStyle.display = 'inline-block';\n\n var inputStyle = _extends({\n boxSizing: 'content-box',\n width: this.state.inputWidth + 'px'\n }, this.props.inputStyle);\n\n var inputProps = _objectWithoutProperties(this.props, []);\n\n cleanInputProps(inputProps);\n inputProps.className = this.props.inputClassName;\n inputProps.id = this.state.inputId;\n inputProps.style = inputStyle;\n return _react2.default.createElement('div', {\n className: this.props.className,\n style: wrapperStyle\n }, this.renderStyles(), _react2.default.createElement('input', _extends({}, inputProps, {\n ref: this.inputRef\n })), _react2.default.createElement('div', {\n ref: this.sizerRef,\n style: sizerStyle\n }, sizerValue), this.props.placeholder ? _react2.default.createElement('div', {\n ref: this.placeHolderSizerRef,\n style: sizerStyle\n }, this.props.placeholder) : null);\n }\n }]);\n\n return AutosizeInput;\n}(_react.Component);\n\nAutosizeInput.propTypes = {\n className: _propTypes2.default.string,\n // className for the outer element\n defaultValue: _propTypes2.default.any,\n // default field value\n extraWidth: _propTypes2.default.oneOfType([// additional width for input element\n _propTypes2.default.number, _propTypes2.default.string]),\n id: _propTypes2.default.string,\n // id to use for the input, can be set for consistent snapshots\n injectStyles: _propTypes2.default.bool,\n // inject the custom stylesheet to hide clear UI, defaults to true\n inputClassName: _propTypes2.default.string,\n // className for the input element\n inputRef: _propTypes2.default.func,\n // ref callback for the input element\n inputStyle: _propTypes2.default.object,\n // css styles for the input element\n minWidth: _propTypes2.default.oneOfType([// minimum width for input element\n _propTypes2.default.number, _propTypes2.default.string]),\n onAutosize: _propTypes2.default.func,\n // onAutosize handler: function(newWidth) {}\n onChange: _propTypes2.default.func,\n // onChange handler: function(event) {}\n placeholder: _propTypes2.default.string,\n // placeholder text\n placeholderIsMinWidth: _propTypes2.default.bool,\n // don't collapse size to less than the placeholder\n style: _propTypes2.default.object,\n // css styles for the outer element\n value: _propTypes2.default.any // field value\n\n};\nAutosizeInput.defaultProps = {\n minWidth: 1,\n injectStyles: true\n};\nexports.default = AutosizeInput;","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}","'use strict';\n\nObject.defineProperty(exports, '__esModule', {\n value: true\n});\nvar prefix = 'fas';\nvar iconName = 'times';\nvar width = 352;\nvar height = 512;\nvar ligatures = [];\nvar unicode = 'f00d';\nvar svgPathData = 'M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z';\nexports.definition = {\n prefix: prefix,\n iconName: iconName,\n icon: [width, height, ligatures, unicode, svgPathData]\n};\nexports.faTimes = exports.definition;\nexports.prefix = prefix;\nexports.iconName = iconName;\nexports.width = width;\nexports.height = height;\nexports.ligatures = ligatures;\nexports.unicode = unicode;\nexports.svgPathData = svgPathData;","'use strict';\n\nvar reactIs = require('react-is');\n/**\n * Copyright 2015, Yahoo! Inc.\n * Copyrights licensed under the New BSD License. See the accompanying LICENSE file for terms.\n */\n\n\nvar REACT_STATICS = {\n childContextTypes: true,\n contextType: true,\n contextTypes: true,\n defaultProps: true,\n displayName: true,\n getDefaultProps: true,\n getDerivedStateFromError: true,\n getDerivedStateFromProps: true,\n mixins: true,\n propTypes: true,\n type: true\n};\nvar KNOWN_STATICS = {\n name: true,\n length: true,\n prototype: true,\n caller: true,\n callee: true,\n arguments: true,\n arity: true\n};\nvar FORWARD_REF_STATICS = {\n '$$typeof': true,\n render: true,\n defaultProps: true,\n displayName: true,\n propTypes: true\n};\nvar MEMO_STATICS = {\n '$$typeof': true,\n compare: true,\n defaultProps: true,\n displayName: true,\n propTypes: true,\n type: true\n};\nvar TYPE_STATICS = {};\nTYPE_STATICS[reactIs.ForwardRef] = FORWARD_REF_STATICS;\nTYPE_STATICS[reactIs.Memo] = MEMO_STATICS;\n\nfunction getStatics(component) {\n // React v16.11 and below\n if (reactIs.isMemo(component)) {\n return MEMO_STATICS;\n } // React v16.12 and above\n\n\n return TYPE_STATICS[component['$$typeof']] || REACT_STATICS;\n}\n\nvar defineProperty = Object.defineProperty;\nvar getOwnPropertyNames = Object.getOwnPropertyNames;\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\nvar getPrototypeOf = Object.getPrototypeOf;\nvar objectPrototype = Object.prototype;\n\nfunction hoistNonReactStatics(targetComponent, sourceComponent, blacklist) {\n if (typeof sourceComponent !== 'string') {\n // don't hoist over string (html) components\n if (objectPrototype) {\n var inheritedComponent = getPrototypeOf(sourceComponent);\n\n if (inheritedComponent && inheritedComponent !== objectPrototype) {\n hoistNonReactStatics(targetComponent, inheritedComponent, blacklist);\n }\n }\n\n var keys = getOwnPropertyNames(sourceComponent);\n\n if (getOwnPropertySymbols) {\n keys = keys.concat(getOwnPropertySymbols(sourceComponent));\n }\n\n var targetStatics = getStatics(targetComponent);\n var sourceStatics = getStatics(sourceComponent);\n\n for (var i = 0; i < keys.length; ++i) {\n var key = keys[i];\n\n if (!KNOWN_STATICS[key] && !(blacklist && blacklist[key]) && !(sourceStatics && sourceStatics[key]) && !(targetStatics && targetStatics[key])) {\n var descriptor = getOwnPropertyDescriptor(sourceComponent, key);\n\n try {\n // Avoid failures from read-only properties\n defineProperty(targetComponent, key, descriptor);\n } catch (e) {}\n }\n }\n }\n\n return targetComponent;\n}\n\nmodule.exports = hoistNonReactStatics;","'use strict';\n/**\n * Copyright 2015, Yahoo! Inc.\n * Copyrights licensed under the New BSD License. See the accompanying LICENSE file for terms.\n */\n\nvar REACT_STATICS = {\n childContextTypes: true,\n contextTypes: true,\n defaultProps: true,\n displayName: true,\n getDefaultProps: true,\n getDerivedStateFromProps: true,\n mixins: true,\n propTypes: true,\n type: true\n};\nvar KNOWN_STATICS = {\n name: true,\n length: true,\n prototype: true,\n caller: true,\n callee: true,\n arguments: true,\n arity: true\n};\nvar defineProperty = Object.defineProperty;\nvar getOwnPropertyNames = Object.getOwnPropertyNames;\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\nvar getPrototypeOf = Object.getPrototypeOf;\nvar objectPrototype = getPrototypeOf && getPrototypeOf(Object);\n\nfunction hoistNonReactStatics(targetComponent, sourceComponent, blacklist) {\n if (typeof sourceComponent !== 'string') {\n // don't hoist over string (html) components\n if (objectPrototype) {\n var inheritedComponent = getPrototypeOf(sourceComponent);\n\n if (inheritedComponent && inheritedComponent !== objectPrototype) {\n hoistNonReactStatics(targetComponent, inheritedComponent, blacklist);\n }\n }\n\n var keys = getOwnPropertyNames(sourceComponent);\n\n if (getOwnPropertySymbols) {\n keys = keys.concat(getOwnPropertySymbols(sourceComponent));\n }\n\n for (var i = 0; i < keys.length; ++i) {\n var key = keys[i];\n\n if (!REACT_STATICS[key] && !KNOWN_STATICS[key] && (!blacklist || !blacklist[key])) {\n var descriptor = getOwnPropertyDescriptor(sourceComponent, key);\n\n try {\n // Avoid failures from read-only properties\n defineProperty(targetComponent, key, descriptor);\n } catch (e) {}\n }\n }\n\n return targetComponent;\n }\n\n return targetComponent;\n}\n\nmodule.exports = hoistNonReactStatics;","'use strict';\n\nvar _TagManager = require('./TagManager');\n\nvar _TagManager2 = _interopRequireDefault(_TagManager);\n\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n\nmodule.exports = _TagManager2.default;","function e(e) {\n this.message = e;\n}\n\ne.prototype = new Error(), e.prototype.name = \"InvalidCharacterError\";\n\nvar r = \"undefined\" != typeof window && window.atob && window.atob.bind(window) || function (r) {\n var t = String(r).replace(/=+$/, \"\");\n if (t.length % 4 == 1) throw new e(\"'atob' failed: The string to be decoded is not correctly encoded.\");\n\n for (var n, o, a = 0, i = 0, c = \"\"; o = t.charAt(i++); ~o && (n = a % 4 ? 64 * n + o : o, a++ % 4) ? c += String.fromCharCode(255 & n >> (-2 * a & 6)) : 0) {\n o = \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\".indexOf(o);\n }\n\n return c;\n};\n\nfunction t(e) {\n var t = e.replace(/-/g, \"+\").replace(/_/g, \"/\");\n\n switch (t.length % 4) {\n case 0:\n break;\n\n case 2:\n t += \"==\";\n break;\n\n case 3:\n t += \"=\";\n break;\n\n default:\n throw \"Illegal base64url string!\";\n }\n\n try {\n return function (e) {\n return decodeURIComponent(r(e).replace(/(.)/g, function (e, r) {\n var t = r.charCodeAt(0).toString(16).toUpperCase();\n return t.length < 2 && (t = \"0\" + t), \"%\" + t;\n }));\n }(t);\n } catch (e) {\n return r(t);\n }\n}\n\nfunction n(e) {\n this.message = e;\n}\n\nfunction o(e, r) {\n if (\"string\" != typeof e) throw new n(\"Invalid token specified\");\n var o = !0 === (r = r || {}).header ? 0 : 1;\n\n try {\n return JSON.parse(t(e.split(\".\")[o]));\n } catch (e) {\n throw new n(\"Invalid token specified: \" + e.message);\n }\n}\n\nn.prototype = new Error(), n.prototype.name = \"InvalidTokenError\";\nexport default o;\nexport { n as InvalidTokenError };","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nexport default function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}","export default function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n _typeof = function _typeof(obj) {\n return typeof obj;\n };\n } else {\n _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}","import _classCallCheck from '@babel/runtime/helpers/esm/classCallCheck';\nimport _createClass from '@babel/runtime/helpers/esm/createClass';\nimport _defineProperty from '@babel/runtime/helpers/esm/defineProperty';\nimport _typeof from '@babel/runtime/helpers/esm/typeof';\nvar arr = [];\nvar each = arr.forEach;\nvar slice = arr.slice;\n\nfunction defaults(obj) {\n each.call(slice.call(arguments, 1), function (source) {\n if (source) {\n for (var prop in source) {\n if (obj[prop] === undefined) obj[prop] = source[prop];\n }\n }\n });\n return obj;\n}\n\nfunction addQueryString(url, params) {\n if (params && _typeof(params) === 'object') {\n var queryString = '',\n e = encodeURIComponent; // Must encode data\n\n for (var paramName in params) {\n queryString += '&' + e(paramName) + '=' + e(params[paramName]);\n }\n\n if (!queryString) {\n return url;\n }\n\n url = url + (url.indexOf('?') !== -1 ? '&' : '?') + queryString.slice(1);\n }\n\n return url;\n} // https://gist.github.com/Xeoncross/7663273\n\n\nfunction ajax(url, options, callback, data, cache) {\n if (data && _typeof(data) === 'object') {\n if (!cache) {\n data['_t'] = new Date();\n } // URL encoded form data must be in querystring format\n\n\n data = addQueryString('', data).slice(1);\n }\n\n if (options.queryStringParams) {\n url = addQueryString(url, options.queryStringParams);\n }\n\n try {\n var x;\n\n if (XMLHttpRequest) {\n x = new XMLHttpRequest();\n } else {\n x = new ActiveXObject('MSXML2.XMLHTTP.3.0');\n }\n\n x.open(data ? 'POST' : 'GET', url, 1);\n\n if (!options.crossDomain) {\n x.setRequestHeader('X-Requested-With', 'XMLHttpRequest');\n }\n\n x.withCredentials = !!options.withCredentials;\n\n if (data) {\n x.setRequestHeader('Content-type', 'application/x-www-form-urlencoded');\n }\n\n if (x.overrideMimeType) {\n x.overrideMimeType(\"application/json\");\n }\n\n var h = options.customHeaders;\n h = typeof h === 'function' ? h() : h;\n\n if (h) {\n for (var i in h) {\n x.setRequestHeader(i, h[i]);\n }\n }\n\n x.onreadystatechange = function () {\n x.readyState > 3 && callback && callback(x.responseText, x);\n };\n\n x.send(data);\n } catch (e) {\n console && console.log(e);\n }\n}\n\nfunction getDefaults() {\n return {\n loadPath: '/locales/{{lng}}/{{ns}}.json',\n addPath: '/locales/add/{{lng}}/{{ns}}',\n allowMultiLoading: false,\n parse: JSON.parse,\n parsePayload: function parsePayload(namespace, key, fallbackValue) {\n return _defineProperty({}, key, fallbackValue || '');\n },\n crossDomain: false,\n ajax: ajax\n };\n}\n\nvar Backend =\n/*#__PURE__*/\nfunction () {\n function Backend(services) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n _classCallCheck(this, Backend);\n\n this.init(services, options);\n this.type = 'backend';\n }\n\n _createClass(Backend, [{\n key: \"init\",\n value: function init(services) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n this.services = services;\n this.options = defaults(options, this.options || {}, getDefaults());\n }\n }, {\n key: \"readMulti\",\n value: function readMulti(languages, namespaces, callback) {\n var loadPath = this.options.loadPath;\n\n if (typeof this.options.loadPath === 'function') {\n loadPath = this.options.loadPath(languages, namespaces);\n }\n\n var url = this.services.interpolator.interpolate(loadPath, {\n lng: languages.join('+'),\n ns: namespaces.join('+')\n });\n this.loadUrl(url, callback);\n }\n }, {\n key: \"read\",\n value: function read(language, namespace, callback) {\n var loadPath = this.options.loadPath;\n\n if (typeof this.options.loadPath === 'function') {\n loadPath = this.options.loadPath([language], [namespace]);\n }\n\n var url = this.services.interpolator.interpolate(loadPath, {\n lng: language,\n ns: namespace\n });\n this.loadUrl(url, callback);\n }\n }, {\n key: \"loadUrl\",\n value: function loadUrl(url, callback) {\n var _this = this;\n\n this.options.ajax(url, this.options, function (data, xhr) {\n if (xhr.status >= 500 && xhr.status < 600) return callback('failed loading ' + url, true\n /* retry */\n );\n if (xhr.status >= 400 && xhr.status < 500) return callback('failed loading ' + url, false\n /* no retry */\n );\n var ret, err;\n\n try {\n ret = _this.options.parse(data, url);\n } catch (e) {\n err = 'failed parsing ' + url + ' to json';\n }\n\n if (err) return callback(err, false);\n callback(null, ret);\n });\n }\n }, {\n key: \"create\",\n value: function create(languages, namespace, key, fallbackValue) {\n var _this2 = this;\n\n if (typeof languages === 'string') languages = [languages];\n var payload = this.options.parsePayload(namespace, key, fallbackValue);\n languages.forEach(function (lng) {\n var url = _this2.services.interpolator.interpolate(_this2.options.addPath, {\n lng: lng,\n ns: namespace\n });\n\n _this2.options.ajax(url, _this2.options, function (data, xhr) {//const statusCode = xhr.status.toString();\n // TODO: if statusCode === 4xx do log\n }, payload);\n });\n }\n }]);\n\n return Backend;\n}();\n\nBackend.type = 'backend';\nexport default Backend;","export default function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}","export default function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}","var unitlessKeys = {\n animationIterationCount: 1,\n borderImageOutset: 1,\n borderImageSlice: 1,\n borderImageWidth: 1,\n boxFlex: 1,\n boxFlexGroup: 1,\n boxOrdinalGroup: 1,\n columnCount: 1,\n columns: 1,\n flex: 1,\n flexGrow: 1,\n flexPositive: 1,\n flexShrink: 1,\n flexNegative: 1,\n flexOrder: 1,\n gridRow: 1,\n gridRowEnd: 1,\n gridRowSpan: 1,\n gridRowStart: 1,\n gridColumn: 1,\n gridColumnEnd: 1,\n gridColumnSpan: 1,\n gridColumnStart: 1,\n fontWeight: 1,\n lineHeight: 1,\n opacity: 1,\n order: 1,\n orphans: 1,\n tabSize: 1,\n widows: 1,\n zIndex: 1,\n zoom: 1,\n WebkitLineClamp: 1,\n // SVG-related properties\n fillOpacity: 1,\n floodOpacity: 1,\n stopOpacity: 1,\n strokeDasharray: 1,\n strokeDashoffset: 1,\n strokeMiterlimit: 1,\n strokeOpacity: 1,\n strokeWidth: 1\n};\nexport default unitlessKeys;","/* eslint-disable */\n// murmurhash2 via https://github.com/garycourt/murmurhash-js/blob/master/murmurhash2_gc.js\nfunction murmurhash2_32_gc(str) {\n var l = str.length,\n h = l ^ l,\n i = 0,\n k;\n\n while (l >= 4) {\n k = str.charCodeAt(i) & 0xff | (str.charCodeAt(++i) & 0xff) << 8 | (str.charCodeAt(++i) & 0xff) << 16 | (str.charCodeAt(++i) & 0xff) << 24;\n k = (k & 0xffff) * 0x5bd1e995 + (((k >>> 16) * 0x5bd1e995 & 0xffff) << 16);\n k ^= k >>> 24;\n k = (k & 0xffff) * 0x5bd1e995 + (((k >>> 16) * 0x5bd1e995 & 0xffff) << 16);\n h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16) ^ k;\n l -= 4;\n ++i;\n }\n\n switch (l) {\n case 3:\n h ^= (str.charCodeAt(i + 2) & 0xff) << 16;\n\n case 2:\n h ^= (str.charCodeAt(i + 1) & 0xff) << 8;\n\n case 1:\n h ^= str.charCodeAt(i) & 0xff;\n h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16);\n }\n\n h ^= h >>> 13;\n h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16);\n h ^= h >>> 15;\n return (h >>> 0).toString(36);\n}\n\nexport default murmurhash2_32_gc;","function stylis_min(W) {\n function M(d, c, e, h, a) {\n for (var m = 0, b = 0, v = 0, n = 0, q, g, x = 0, K = 0, k, u = k = q = 0, l = 0, r = 0, I = 0, t = 0, B = e.length, J = B - 1, y, f = '', p = '', F = '', G = '', C; l < B;) {\n g = e.charCodeAt(l);\n l === J && 0 !== b + n + v + m && (0 !== b && (g = 47 === b ? 10 : 47), n = v = m = 0, B++, J++);\n\n if (0 === b + n + v + m) {\n if (l === J && (0 < r && (f = f.replace(N, '')), 0 < f.trim().length)) {\n switch (g) {\n case 32:\n case 9:\n case 59:\n case 13:\n case 10:\n break;\n\n default:\n f += e.charAt(l);\n }\n\n g = 59;\n }\n\n switch (g) {\n case 123:\n f = f.trim();\n q = f.charCodeAt(0);\n k = 1;\n\n for (t = ++l; l < B;) {\n switch (g = e.charCodeAt(l)) {\n case 123:\n k++;\n break;\n\n case 125:\n k--;\n break;\n\n case 47:\n switch (g = e.charCodeAt(l + 1)) {\n case 42:\n case 47:\n a: {\n for (u = l + 1; u < J; ++u) {\n switch (e.charCodeAt(u)) {\n case 47:\n if (42 === g && 42 === e.charCodeAt(u - 1) && l + 2 !== u) {\n l = u + 1;\n break a;\n }\n\n break;\n\n case 10:\n if (47 === g) {\n l = u + 1;\n break a;\n }\n\n }\n }\n\n l = u;\n }\n\n }\n\n break;\n\n case 91:\n g++;\n\n case 40:\n g++;\n\n case 34:\n case 39:\n for (; l++ < J && e.charCodeAt(l) !== g;) {}\n\n }\n\n if (0 === k) break;\n l++;\n }\n\n k = e.substring(t, l);\n 0 === q && (q = (f = f.replace(ca, '').trim()).charCodeAt(0));\n\n switch (q) {\n case 64:\n 0 < r && (f = f.replace(N, ''));\n g = f.charCodeAt(1);\n\n switch (g) {\n case 100:\n case 109:\n case 115:\n case 45:\n r = c;\n break;\n\n default:\n r = O;\n }\n\n k = M(c, r, k, g, a + 1);\n t = k.length;\n 0 < A && (r = X(O, f, I), C = H(3, k, r, c, D, z, t, g, a, h), f = r.join(''), void 0 !== C && 0 === (t = (k = C.trim()).length) && (g = 0, k = ''));\n if (0 < t) switch (g) {\n case 115:\n f = f.replace(da, ea);\n\n case 100:\n case 109:\n case 45:\n k = f + '{' + k + '}';\n break;\n\n case 107:\n f = f.replace(fa, '$1 $2');\n k = f + '{' + k + '}';\n k = 1 === w || 2 === w && L('@' + k, 3) ? '@-webkit-' + k + '@' + k : '@' + k;\n break;\n\n default:\n k = f + k, 112 === h && (k = (p += k, ''));\n } else k = '';\n break;\n\n default:\n k = M(c, X(c, f, I), k, h, a + 1);\n }\n\n F += k;\n k = I = r = u = q = 0;\n f = '';\n g = e.charCodeAt(++l);\n break;\n\n case 125:\n case 59:\n f = (0 < r ? f.replace(N, '') : f).trim();\n if (1 < (t = f.length)) switch (0 === u && (q = f.charCodeAt(0), 45 === q || 96 < q && 123 > q) && (t = (f = f.replace(' ', ':')).length), 0 < A && void 0 !== (C = H(1, f, c, d, D, z, p.length, h, a, h)) && 0 === (t = (f = C.trim()).length) && (f = '\\x00\\x00'), q = f.charCodeAt(0), g = f.charCodeAt(1), q) {\n case 0:\n break;\n\n case 64:\n if (105 === g || 99 === g) {\n G += f + e.charAt(l);\n break;\n }\n\n default:\n 58 !== f.charCodeAt(t - 1) && (p += P(f, q, g, f.charCodeAt(2)));\n }\n I = r = u = q = 0;\n f = '';\n g = e.charCodeAt(++l);\n }\n }\n\n switch (g) {\n case 13:\n case 10:\n 47 === b ? b = 0 : 0 === 1 + q && 107 !== h && 0 < f.length && (r = 1, f += '\\x00');\n 0 < A * Y && H(0, f, c, d, D, z, p.length, h, a, h);\n z = 1;\n D++;\n break;\n\n case 59:\n case 125:\n if (0 === b + n + v + m) {\n z++;\n break;\n }\n\n default:\n z++;\n y = e.charAt(l);\n\n switch (g) {\n case 9:\n case 32:\n if (0 === n + m + b) switch (x) {\n case 44:\n case 58:\n case 9:\n case 32:\n y = '';\n break;\n\n default:\n 32 !== g && (y = ' ');\n }\n break;\n\n case 0:\n y = '\\\\0';\n break;\n\n case 12:\n y = '\\\\f';\n break;\n\n case 11:\n y = '\\\\v';\n break;\n\n case 38:\n 0 === n + b + m && (r = I = 1, y = '\\f' + y);\n break;\n\n case 108:\n if (0 === n + b + m + E && 0 < u) switch (l - u) {\n case 2:\n 112 === x && 58 === e.charCodeAt(l - 3) && (E = x);\n\n case 8:\n 111 === K && (E = K);\n }\n break;\n\n case 58:\n 0 === n + b + m && (u = l);\n break;\n\n case 44:\n 0 === b + v + n + m && (r = 1, y += '\\r');\n break;\n\n case 34:\n case 39:\n 0 === b && (n = n === g ? 0 : 0 === n ? g : n);\n break;\n\n case 91:\n 0 === n + b + v && m++;\n break;\n\n case 93:\n 0 === n + b + v && m--;\n break;\n\n case 41:\n 0 === n + b + m && v--;\n break;\n\n case 40:\n if (0 === n + b + m) {\n if (0 === q) switch (2 * x + 3 * K) {\n case 533:\n break;\n\n default:\n q = 1;\n }\n v++;\n }\n\n break;\n\n case 64:\n 0 === b + v + n + m + u + k && (k = 1);\n break;\n\n case 42:\n case 47:\n if (!(0 < n + m + v)) switch (b) {\n case 0:\n switch (2 * g + 3 * e.charCodeAt(l + 1)) {\n case 235:\n b = 47;\n break;\n\n case 220:\n t = l, b = 42;\n }\n\n break;\n\n case 42:\n 47 === g && 42 === x && t + 2 !== l && (33 === e.charCodeAt(t + 2) && (p += e.substring(t, l + 1)), y = '', b = 0);\n }\n }\n\n 0 === b && (f += y);\n }\n\n K = x;\n x = g;\n l++;\n }\n\n t = p.length;\n\n if (0 < t) {\n r = c;\n if (0 < A && (C = H(2, p, r, d, D, z, t, h, a, h), void 0 !== C && 0 === (p = C).length)) return G + p + F;\n p = r.join(',') + '{' + p + '}';\n\n if (0 !== w * E) {\n 2 !== w || L(p, 2) || (E = 0);\n\n switch (E) {\n case 111:\n p = p.replace(ha, ':-moz-$1') + p;\n break;\n\n case 112:\n p = p.replace(Q, '::-webkit-input-$1') + p.replace(Q, '::-moz-$1') + p.replace(Q, ':-ms-input-$1') + p;\n }\n\n E = 0;\n }\n }\n\n return G + p + F;\n }\n\n function X(d, c, e) {\n var h = c.trim().split(ia);\n c = h;\n var a = h.length,\n m = d.length;\n\n switch (m) {\n case 0:\n case 1:\n var b = 0;\n\n for (d = 0 === m ? '' : d[0] + ' '; b < a; ++b) {\n c[b] = Z(d, c[b], e, m).trim();\n }\n\n break;\n\n default:\n var v = b = 0;\n\n for (c = []; b < a; ++b) {\n for (var n = 0; n < m; ++n) {\n c[v++] = Z(d[n] + ' ', h[b], e, m).trim();\n }\n }\n\n }\n\n return c;\n }\n\n function Z(d, c, e) {\n var h = c.charCodeAt(0);\n 33 > h && (h = (c = c.trim()).charCodeAt(0));\n\n switch (h) {\n case 38:\n return c.replace(F, '$1' + d.trim());\n\n case 58:\n return d.trim() + c.replace(F, '$1' + d.trim());\n\n default:\n if (0 < 1 * e && 0 < c.indexOf('\\f')) return c.replace(F, (58 === d.charCodeAt(0) ? '' : '$1') + d.trim());\n }\n\n return d + c;\n }\n\n function P(d, c, e, h) {\n var a = d + ';',\n m = 2 * c + 3 * e + 4 * h;\n\n if (944 === m) {\n d = a.indexOf(':', 9) + 1;\n var b = a.substring(d, a.length - 1).trim();\n b = a.substring(0, d).trim() + b + ';';\n return 1 === w || 2 === w && L(b, 1) ? '-webkit-' + b + b : b;\n }\n\n if (0 === w || 2 === w && !L(a, 1)) return a;\n\n switch (m) {\n case 1015:\n return 97 === a.charCodeAt(10) ? '-webkit-' + a + a : a;\n\n case 951:\n return 116 === a.charCodeAt(3) ? '-webkit-' + a + a : a;\n\n case 963:\n return 110 === a.charCodeAt(5) ? '-webkit-' + a + a : a;\n\n case 1009:\n if (100 !== a.charCodeAt(4)) break;\n\n case 969:\n case 942:\n return '-webkit-' + a + a;\n\n case 978:\n return '-webkit-' + a + '-moz-' + a + a;\n\n case 1019:\n case 983:\n return '-webkit-' + a + '-moz-' + a + '-ms-' + a + a;\n\n case 883:\n if (45 === a.charCodeAt(8)) return '-webkit-' + a + a;\n if (0 < a.indexOf('image-set(', 11)) return a.replace(ja, '$1-webkit-$2') + a;\n break;\n\n case 932:\n if (45 === a.charCodeAt(4)) switch (a.charCodeAt(5)) {\n case 103:\n return '-webkit-box-' + a.replace('-grow', '') + '-webkit-' + a + '-ms-' + a.replace('grow', 'positive') + a;\n\n case 115:\n return '-webkit-' + a + '-ms-' + a.replace('shrink', 'negative') + a;\n\n case 98:\n return '-webkit-' + a + '-ms-' + a.replace('basis', 'preferred-size') + a;\n }\n return '-webkit-' + a + '-ms-' + a + a;\n\n case 964:\n return '-webkit-' + a + '-ms-flex-' + a + a;\n\n case 1023:\n if (99 !== a.charCodeAt(8)) break;\n b = a.substring(a.indexOf(':', 15)).replace('flex-', '').replace('space-between', 'justify');\n return '-webkit-box-pack' + b + '-webkit-' + a + '-ms-flex-pack' + b + a;\n\n case 1005:\n return ka.test(a) ? a.replace(aa, ':-webkit-') + a.replace(aa, ':-moz-') + a : a;\n\n case 1e3:\n b = a.substring(13).trim();\n c = b.indexOf('-') + 1;\n\n switch (b.charCodeAt(0) + b.charCodeAt(c)) {\n case 226:\n b = a.replace(G, 'tb');\n break;\n\n case 232:\n b = a.replace(G, 'tb-rl');\n break;\n\n case 220:\n b = a.replace(G, 'lr');\n break;\n\n default:\n return a;\n }\n\n return '-webkit-' + a + '-ms-' + b + a;\n\n case 1017:\n if (-1 === a.indexOf('sticky', 9)) break;\n\n case 975:\n c = (a = d).length - 10;\n b = (33 === a.charCodeAt(c) ? a.substring(0, c) : a).substring(d.indexOf(':', 7) + 1).trim();\n\n switch (m = b.charCodeAt(0) + (b.charCodeAt(7) | 0)) {\n case 203:\n if (111 > b.charCodeAt(8)) break;\n\n case 115:\n a = a.replace(b, '-webkit-' + b) + ';' + a;\n break;\n\n case 207:\n case 102:\n a = a.replace(b, '-webkit-' + (102 < m ? 'inline-' : '') + 'box') + ';' + a.replace(b, '-webkit-' + b) + ';' + a.replace(b, '-ms-' + b + 'box') + ';' + a;\n }\n\n return a + ';';\n\n case 938:\n if (45 === a.charCodeAt(5)) switch (a.charCodeAt(6)) {\n case 105:\n return b = a.replace('-items', ''), '-webkit-' + a + '-webkit-box-' + b + '-ms-flex-' + b + a;\n\n case 115:\n return '-webkit-' + a + '-ms-flex-item-' + a.replace(ba, '') + a;\n\n default:\n return '-webkit-' + a + '-ms-flex-line-pack' + a.replace('align-content', '').replace(ba, '') + a;\n }\n break;\n\n case 973:\n case 989:\n if (45 !== a.charCodeAt(3) || 122 === a.charCodeAt(4)) break;\n\n case 931:\n case 953:\n if (!0 === la.test(d)) return 115 === (b = d.substring(d.indexOf(':') + 1)).charCodeAt(0) ? P(d.replace('stretch', 'fill-available'), c, e, h).replace(':fill-available', ':stretch') : a.replace(b, '-webkit-' + b) + a.replace(b, '-moz-' + b.replace('fill-', '')) + a;\n break;\n\n case 962:\n if (a = '-webkit-' + a + (102 === a.charCodeAt(5) ? '-ms-' + a : '') + a, 211 === e + h && 105 === a.charCodeAt(13) && 0 < a.indexOf('transform', 10)) return a.substring(0, a.indexOf(';', 27) + 1).replace(ma, '$1-webkit-$2') + a;\n }\n\n return a;\n }\n\n function L(d, c) {\n var e = d.indexOf(1 === c ? ':' : '{'),\n h = d.substring(0, 3 !== c ? e : 10);\n e = d.substring(e + 1, d.length - 1);\n return R(2 !== c ? h : h.replace(na, '$1'), e, c);\n }\n\n function ea(d, c) {\n var e = P(c, c.charCodeAt(0), c.charCodeAt(1), c.charCodeAt(2));\n return e !== c + ';' ? e.replace(oa, ' or ($1)').substring(4) : '(' + c + ')';\n }\n\n function H(d, c, e, h, a, m, b, v, n, q) {\n for (var g = 0, x = c, w; g < A; ++g) {\n switch (w = S[g].call(B, d, x, e, h, a, m, b, v, n, q)) {\n case void 0:\n case !1:\n case !0:\n case null:\n break;\n\n default:\n x = w;\n }\n }\n\n if (x !== c) return x;\n }\n\n function T(d) {\n switch (d) {\n case void 0:\n case null:\n A = S.length = 0;\n break;\n\n default:\n switch (d.constructor) {\n case Array:\n for (var c = 0, e = d.length; c < e; ++c) {\n T(d[c]);\n }\n\n break;\n\n case Function:\n S[A++] = d;\n break;\n\n case Boolean:\n Y = !!d | 0;\n }\n\n }\n\n return T;\n }\n\n function U(d) {\n d = d.prefix;\n void 0 !== d && (R = null, d ? 'function' !== typeof d ? w = 1 : (w = 2, R = d) : w = 0);\n return U;\n }\n\n function B(d, c) {\n var e = d;\n 33 > e.charCodeAt(0) && (e = e.trim());\n V = e;\n e = [V];\n\n if (0 < A) {\n var h = H(-1, c, e, e, D, z, 0, 0, 0, 0);\n void 0 !== h && 'string' === typeof h && (c = h);\n }\n\n var a = M(O, e, c, 0, 0);\n 0 < A && (h = H(-2, a, e, e, D, z, a.length, 0, 0, 0), void 0 !== h && (a = h));\n V = '';\n E = 0;\n z = D = 1;\n return a;\n }\n\n var ca = /^\\0+/g,\n N = /[\\0\\r\\f]/g,\n aa = /: */g,\n ka = /zoo|gra/,\n ma = /([,: ])(transform)/g,\n ia = /,\\r+?/g,\n F = /([\\t\\r\\n ])*\\f?&/g,\n fa = /@(k\\w+)\\s*(\\S*)\\s*/,\n Q = /::(place)/g,\n ha = /:(read-only)/g,\n G = /[svh]\\w+-[tblr]{2}/,\n da = /\\(\\s*(.*)\\s*\\)/g,\n oa = /([\\s\\S]*?);/g,\n ba = /-self|flex-/g,\n na = /[^]*?(:[rp][el]a[\\w-]+)[^]*/,\n la = /stretch|:\\s*\\w+\\-(?:conte|avail)/,\n ja = /([^-])(image-set\\()/,\n z = 1,\n D = 1,\n E = 0,\n w = 1,\n O = [],\n S = [],\n A = 0,\n R = null,\n Y = 0,\n V = '';\n B.use = T;\n B.set = U;\n void 0 !== W && U(W);\n return B;\n}\n\nexport default stylis_min;","import memoize from '@emotion/memoize';\nimport unitless from '@emotion/unitless';\nimport hashString from '@emotion/hash';\nimport Stylis from '@emotion/stylis';\nimport stylisRuleSheet from 'stylis-rule-sheet';\nvar hyphenateRegex = /[A-Z]|^ms/g;\nvar processStyleName = memoize(function (styleName) {\n return styleName.replace(hyphenateRegex, '-$&').toLowerCase();\n});\n\nvar processStyleValue = function processStyleValue(key, value) {\n if (value == null || typeof value === 'boolean') {\n return '';\n }\n\n if (unitless[key] !== 1 && key.charCodeAt(1) !== 45 && // custom properties\n !isNaN(value) && value !== 0) {\n return value + 'px';\n }\n\n return value;\n};\n\nif (process.env.NODE_ENV !== 'production') {\n var contentValuePattern = /(attr|calc|counters?|url)\\(/;\n var contentValues = ['normal', 'none', 'counter', 'open-quote', 'close-quote', 'no-open-quote', 'no-close-quote', 'initial', 'inherit', 'unset'];\n var oldProcessStyleValue = processStyleValue;\n\n processStyleValue = function processStyleValue(key, value) {\n if (key === 'content') {\n if (typeof value !== 'string' || contentValues.indexOf(value) === -1 && !contentValuePattern.test(value) && (value.charAt(0) !== value.charAt(value.length - 1) || value.charAt(0) !== '\"' && value.charAt(0) !== \"'\")) {\n console.error(\"You seem to be using a value for 'content' without quotes, try replacing it with `content: '\\\"\" + value + \"\\\"'`\");\n }\n }\n\n return oldProcessStyleValue(key, value);\n };\n}\n\nvar classnames = function classnames(args) {\n var len = args.length;\n var i = 0;\n var cls = '';\n\n for (; i < len; i++) {\n var arg = args[i];\n if (arg == null) continue;\n var toAdd = void 0;\n\n switch (typeof arg) {\n case 'boolean':\n break;\n\n case 'function':\n if (process.env.NODE_ENV !== 'production') {\n console.error('Passing functions to cx is deprecated and will be removed in the next major version of Emotion.\\n' + 'Please call the function before passing it to cx.');\n }\n\n toAdd = classnames([arg()]);\n break;\n\n case 'object':\n {\n if (Array.isArray(arg)) {\n toAdd = classnames(arg);\n } else {\n toAdd = '';\n\n for (var k in arg) {\n if (arg[k] && k) {\n toAdd && (toAdd += ' ');\n toAdd += k;\n }\n }\n }\n\n break;\n }\n\n default:\n {\n toAdd = arg;\n }\n }\n\n if (toAdd) {\n cls && (cls += ' ');\n cls += toAdd;\n }\n }\n\n return cls;\n};\n\nvar isBrowser = typeof document !== 'undefined';\n/*\n\nhigh performance StyleSheet for css-in-js systems\n\n- uses multiple style tags behind the scenes for millions of rules\n- uses `insertRule` for appending in production for *much* faster performance\n- 'polyfills' on server side\n\n// usage\n\nimport StyleSheet from 'glamor/lib/sheet'\nlet styleSheet = new StyleSheet()\n\nstyleSheet.inject()\n- 'injects' the stylesheet into the page (or into memory if on server)\n\nstyleSheet.insert('#box { border: 1px solid red; }')\n- appends a css rule into the stylesheet\n\nstyleSheet.flush()\n- empties the stylesheet of all its contents\n\n*/\n// $FlowFixMe\n\nfunction sheetForTag(tag) {\n if (tag.sheet) {\n // $FlowFixMe\n return tag.sheet;\n } // this weirdness brought to you by firefox\n\n\n for (var i = 0; i < document.styleSheets.length; i++) {\n if (document.styleSheets[i].ownerNode === tag) {\n // $FlowFixMe\n return document.styleSheets[i];\n }\n }\n}\n\nfunction makeStyleTag(opts) {\n var tag = document.createElement('style');\n tag.setAttribute('data-emotion', opts.key || '');\n\n if (opts.nonce !== undefined) {\n tag.setAttribute('nonce', opts.nonce);\n }\n\n tag.appendChild(document.createTextNode('')) // $FlowFixMe\n ;\n (opts.container !== undefined ? opts.container : document.head).appendChild(tag);\n return tag;\n}\n\nvar StyleSheet =\n/*#__PURE__*/\nfunction () {\n function StyleSheet(options) {\n this.isSpeedy = process.env.NODE_ENV === 'production'; // the big drawback here is that the css won't be editable in devtools\n\n this.tags = [];\n this.ctr = 0;\n this.opts = options;\n }\n\n var _proto = StyleSheet.prototype;\n\n _proto.inject = function inject() {\n if (this.injected) {\n throw new Error('already injected!');\n }\n\n this.tags[0] = makeStyleTag(this.opts);\n this.injected = true;\n };\n\n _proto.speedy = function speedy(bool) {\n if (this.ctr !== 0) {\n // cannot change speedy mode after inserting any rule to sheet. Either call speedy(${bool}) earlier in your app, or call flush() before speedy(${bool})\n throw new Error(\"cannot change speedy now\");\n }\n\n this.isSpeedy = !!bool;\n };\n\n _proto.insert = function insert(rule, sourceMap) {\n // this is the ultrafast version, works across browsers\n if (this.isSpeedy) {\n var tag = this.tags[this.tags.length - 1];\n var sheet = sheetForTag(tag);\n\n try {\n sheet.insertRule(rule, sheet.cssRules.length);\n } catch (e) {\n if (process.env.NODE_ENV !== 'production') {\n console.warn('illegal rule', rule); // eslint-disable-line no-console\n }\n }\n } else {\n var _tag = makeStyleTag(this.opts);\n\n this.tags.push(_tag);\n\n _tag.appendChild(document.createTextNode(rule + (sourceMap || '')));\n }\n\n this.ctr++;\n\n if (this.ctr % 65000 === 0) {\n this.tags.push(makeStyleTag(this.opts));\n }\n };\n\n _proto.flush = function flush() {\n // $FlowFixMe\n this.tags.forEach(function (tag) {\n return tag.parentNode.removeChild(tag);\n });\n this.tags = [];\n this.ctr = 0; // todo - look for remnants in document.styleSheets\n\n this.injected = false;\n };\n\n return StyleSheet;\n}();\n\nfunction createEmotion(context, options) {\n if (context.__SECRET_EMOTION__ !== undefined) {\n return context.__SECRET_EMOTION__;\n }\n\n if (options === undefined) options = {};\n var key = options.key || 'css';\n\n if (process.env.NODE_ENV !== 'production') {\n if (/[^a-z-]/.test(key)) {\n throw new Error(\"Emotion key must only contain lower case alphabetical characters and - but \\\"\" + key + \"\\\" was passed\");\n }\n }\n\n var current;\n\n function insertRule(rule) {\n current += rule;\n\n if (isBrowser) {\n sheet.insert(rule, currentSourceMap);\n }\n }\n\n var insertionPlugin = stylisRuleSheet(insertRule);\n var stylisOptions;\n\n if (options.prefix !== undefined) {\n stylisOptions = {\n prefix: options.prefix\n };\n }\n\n var caches = {\n registered: {},\n inserted: {},\n nonce: options.nonce,\n key: key\n };\n var sheet = new StyleSheet(options);\n\n if (isBrowser) {\n // 🚀\n sheet.inject();\n }\n\n var stylis = new Stylis(stylisOptions);\n stylis.use(options.stylisPlugins)(insertionPlugin);\n var currentSourceMap = '';\n\n function handleInterpolation(interpolation, couldBeSelectorInterpolation) {\n if (interpolation == null) {\n return '';\n }\n\n switch (typeof interpolation) {\n case 'boolean':\n return '';\n\n case 'function':\n if (interpolation.__emotion_styles !== undefined) {\n var selector = interpolation.toString();\n\n if (selector === 'NO_COMPONENT_SELECTOR' && process.env.NODE_ENV !== 'production') {\n throw new Error('Component selectors can only be used in conjunction with babel-plugin-emotion.');\n }\n\n return selector;\n }\n\n if (this === undefined && process.env.NODE_ENV !== 'production') {\n console.error('Interpolating functions in css calls is deprecated and will be removed in the next major version of Emotion.\\n' + 'If you want to have a css call based on props, create a function that returns a css call like this\\n' + 'let dynamicStyle = (props) => css`color: ${props.color}`\\n' + 'It can be called directly with props or interpolated in a styled call like this\\n' + \"let SomeComponent = styled('div')`${dynamicStyle}`\");\n }\n\n return handleInterpolation.call(this, this === undefined ? interpolation() : // $FlowFixMe\n interpolation(this.mergedProps, this.context), couldBeSelectorInterpolation);\n\n case 'object':\n return createStringFromObject.call(this, interpolation);\n\n default:\n var cached = caches.registered[interpolation];\n return couldBeSelectorInterpolation === false && cached !== undefined ? cached : interpolation;\n }\n }\n\n var objectToStringCache = new WeakMap();\n\n function createStringFromObject(obj) {\n if (objectToStringCache.has(obj)) {\n // $FlowFixMe\n return objectToStringCache.get(obj);\n }\n\n var string = '';\n\n if (Array.isArray(obj)) {\n obj.forEach(function (interpolation) {\n string += handleInterpolation.call(this, interpolation, false);\n }, this);\n } else {\n Object.keys(obj).forEach(function (key) {\n if (typeof obj[key] !== 'object') {\n if (caches.registered[obj[key]] !== undefined) {\n string += key + \"{\" + caches.registered[obj[key]] + \"}\";\n } else {\n string += processStyleName(key) + \":\" + processStyleValue(key, obj[key]) + \";\";\n }\n } else {\n if (key === 'NO_COMPONENT_SELECTOR' && process.env.NODE_ENV !== 'production') {\n throw new Error('Component selectors can only be used in conjunction with babel-plugin-emotion.');\n }\n\n if (Array.isArray(obj[key]) && typeof obj[key][0] === 'string' && caches.registered[obj[key][0]] === undefined) {\n obj[key].forEach(function (value) {\n string += processStyleName(key) + \":\" + processStyleValue(key, value) + \";\";\n });\n } else {\n string += key + \"{\" + handleInterpolation.call(this, obj[key], false) + \"}\";\n }\n }\n }, this);\n }\n\n objectToStringCache.set(obj, string);\n return string;\n }\n\n var name;\n var stylesWithLabel;\n var labelPattern = /label:\\s*([^\\s;\\n{]+)\\s*;/g;\n\n var createClassName = function createClassName(styles, identifierName) {\n return hashString(styles + identifierName) + identifierName;\n };\n\n if (process.env.NODE_ENV !== 'production') {\n var oldCreateClassName = createClassName;\n var sourceMappingUrlPattern = /\\/\\*#\\ssourceMappingURL=data:application\\/json;\\S+\\s+\\*\\//g;\n\n createClassName = function createClassName(styles, identifierName) {\n return oldCreateClassName(styles.replace(sourceMappingUrlPattern, function (sourceMap) {\n currentSourceMap = sourceMap;\n return '';\n }), identifierName);\n };\n }\n\n var createStyles = function createStyles(strings) {\n var stringMode = true;\n var styles = '';\n var identifierName = '';\n\n if (strings == null || strings.raw === undefined) {\n stringMode = false;\n styles += handleInterpolation.call(this, strings, false);\n } else {\n styles += strings[0];\n }\n\n for (var _len = arguments.length, interpolations = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n interpolations[_key - 1] = arguments[_key];\n }\n\n interpolations.forEach(function (interpolation, i) {\n styles += handleInterpolation.call(this, interpolation, styles.charCodeAt(styles.length - 1) === 46 // .\n );\n\n if (stringMode === true && strings[i + 1] !== undefined) {\n styles += strings[i + 1];\n }\n }, this);\n stylesWithLabel = styles;\n styles = styles.replace(labelPattern, function (match, p1) {\n identifierName += \"-\" + p1;\n return '';\n });\n name = createClassName(styles, identifierName);\n return styles;\n };\n\n if (process.env.NODE_ENV !== 'production') {\n var oldStylis = stylis;\n\n stylis = function stylis(selector, styles) {\n oldStylis(selector, styles);\n currentSourceMap = '';\n };\n }\n\n function insert(scope, styles) {\n if (caches.inserted[name] === undefined) {\n current = '';\n stylis(scope, styles);\n caches.inserted[name] = current;\n }\n }\n\n var css = function css() {\n var styles = createStyles.apply(this, arguments);\n var selector = key + \"-\" + name;\n\n if (caches.registered[selector] === undefined) {\n caches.registered[selector] = stylesWithLabel;\n }\n\n insert(\".\" + selector, styles);\n return selector;\n };\n\n var keyframes = function keyframes() {\n var styles = createStyles.apply(this, arguments);\n var animation = \"animation-\" + name;\n insert('', \"@keyframes \" + animation + \"{\" + styles + \"}\");\n return animation;\n };\n\n var injectGlobal = function injectGlobal() {\n var styles = createStyles.apply(this, arguments);\n insert('', styles);\n };\n\n function getRegisteredStyles(registeredStyles, classNames) {\n var rawClassName = '';\n classNames.split(' ').forEach(function (className) {\n if (caches.registered[className] !== undefined) {\n registeredStyles.push(className);\n } else {\n rawClassName += className + \" \";\n }\n });\n return rawClassName;\n }\n\n function merge(className, sourceMap) {\n var registeredStyles = [];\n var rawClassName = getRegisteredStyles(registeredStyles, className);\n\n if (registeredStyles.length < 2) {\n return className;\n }\n\n return rawClassName + css(registeredStyles, sourceMap);\n }\n\n function cx() {\n for (var _len2 = arguments.length, classNames = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n classNames[_key2] = arguments[_key2];\n }\n\n return merge(classnames(classNames));\n }\n\n function hydrateSingleId(id) {\n caches.inserted[id] = true;\n }\n\n function hydrate(ids) {\n ids.forEach(hydrateSingleId);\n }\n\n function flush() {\n if (isBrowser) {\n sheet.flush();\n sheet.inject();\n }\n\n caches.inserted = {};\n caches.registered = {};\n }\n\n if (isBrowser) {\n var chunks = document.querySelectorAll(\"[data-emotion-\" + key + \"]\");\n Array.prototype.forEach.call(chunks, function (node) {\n // $FlowFixMe\n sheet.tags[0].parentNode.insertBefore(node, sheet.tags[0]); // $FlowFixMe\n\n node.getAttribute(\"data-emotion-\" + key).split(' ').forEach(hydrateSingleId);\n });\n }\n\n var emotion = {\n flush: flush,\n hydrate: hydrate,\n cx: cx,\n merge: merge,\n getRegisteredStyles: getRegisteredStyles,\n injectGlobal: injectGlobal,\n keyframes: keyframes,\n css: css,\n sheet: sheet,\n caches: caches\n };\n context.__SECRET_EMOTION__ = emotion;\n return emotion;\n}\n\nexport default createEmotion;","/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\n\n/* global Reflect, Promise */\nvar _extendStatics = function extendStatics(d, b) {\n _extendStatics = Object.setPrototypeOf || {\n __proto__: []\n } instanceof Array && function (d, b) {\n d.__proto__ = b;\n } || function (d, b) {\n for (var p in b) {\n if (b.hasOwnProperty(p)) d[p] = b[p];\n }\n };\n\n return _extendStatics(d, b);\n};\n\nexport function __extends(d, b) {\n _extendStatics(d, b);\n\n function __() {\n this.constructor = d;\n }\n\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n}\n\nvar _assign = function __assign() {\n _assign = Object.assign || function __assign(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\n }\n }\n\n return t;\n };\n\n return _assign.apply(this, arguments);\n};\n\nexport { _assign as __assign };\nexport function __rest(s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n}\nexport function __decorate(decorators, target, key, desc) {\n var c = arguments.length,\n r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc,\n d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) {\n if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n }\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n}\nexport function __param(paramIndex, decorator) {\n return function (target, key) {\n decorator(target, key, paramIndex);\n };\n}\nexport function __metadata(metadataKey, metadataValue) {\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\n}\nexport function __awaiter(thisArg, _arguments, P, generator) {\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) {\n try {\n step(generator.next(value));\n } catch (e) {\n reject(e);\n }\n }\n\n function rejected(value) {\n try {\n step(generator[\"throw\"](value));\n } catch (e) {\n reject(e);\n }\n }\n\n function step(result) {\n result.done ? resolve(result.value) : new P(function (resolve) {\n resolve(result.value);\n }).then(fulfilled, rejected);\n }\n\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n}\nexport function __generator(thisArg, body) {\n var _ = {\n label: 0,\n sent: function sent() {\n if (t[0] & 1) throw t[1];\n return t[1];\n },\n trys: [],\n ops: []\n },\n f,\n y,\n t,\n g;\n return g = {\n next: verb(0),\n \"throw\": verb(1),\n \"return\": verb(2)\n }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function () {\n return this;\n }), g;\n\n function verb(n) {\n return function (v) {\n return step([n, v]);\n };\n }\n\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n\n while (_) {\n try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n\n switch (op[0]) {\n case 0:\n case 1:\n t = op;\n break;\n\n case 4:\n _.label++;\n return {\n value: op[1],\n done: false\n };\n\n case 5:\n _.label++;\n y = op[1];\n op = [0];\n continue;\n\n case 7:\n op = _.ops.pop();\n\n _.trys.pop();\n\n continue;\n\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {\n _ = 0;\n continue;\n }\n\n if (op[0] === 3 && (!t || op[1] > t[0] && op[1] < t[3])) {\n _.label = op[1];\n break;\n }\n\n if (op[0] === 6 && _.label < t[1]) {\n _.label = t[1];\n t = op;\n break;\n }\n\n if (t && _.label < t[2]) {\n _.label = t[2];\n\n _.ops.push(op);\n\n break;\n }\n\n if (t[2]) _.ops.pop();\n\n _.trys.pop();\n\n continue;\n }\n\n op = body.call(thisArg, _);\n } catch (e) {\n op = [6, e];\n y = 0;\n } finally {\n f = t = 0;\n }\n }\n\n if (op[0] & 5) throw op[1];\n return {\n value: op[0] ? op[1] : void 0,\n done: true\n };\n }\n}\nexport function __exportStar(m, exports) {\n for (var p in m) {\n if (!exports.hasOwnProperty(p)) exports[p] = m[p];\n }\n}\nexport function __values(o) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator],\n i = 0;\n if (m) return m.call(o);\n return {\n next: function next() {\n if (o && i >= o.length) o = void 0;\n return {\n value: o && o[i++],\n done: !o\n };\n }\n };\n}\nexport function __read(o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o),\n r,\n ar = [],\n e;\n\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) {\n ar.push(r.value);\n }\n } catch (error) {\n e = {\n error: error\n };\n } finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n } finally {\n if (e) throw e.error;\n }\n }\n\n return ar;\n}\nexport function __spread() {\n for (var ar = [], i = 0; i < arguments.length; i++) {\n ar = ar.concat(__read(arguments[i]));\n }\n\n return ar;\n}\nexport function __spreadArrays() {\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) {\n s += arguments[i].length;\n }\n\n for (var r = Array(s), k = 0, i = 0; i < il; i++) {\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++) {\n r[k] = a[j];\n }\n }\n\n return r;\n}\n;\nexport function __await(v) {\n return this instanceof __await ? (this.v = v, this) : new __await(v);\n}\nexport function __asyncGenerator(thisArg, _arguments, generator) {\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\n var g = generator.apply(thisArg, _arguments || []),\n i,\n q = [];\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () {\n return this;\n }, i;\n\n function verb(n) {\n if (g[n]) i[n] = function (v) {\n return new Promise(function (a, b) {\n q.push([n, v, a, b]) > 1 || resume(n, v);\n });\n };\n }\n\n function resume(n, v) {\n try {\n step(g[n](v));\n } catch (e) {\n settle(q[0][3], e);\n }\n }\n\n function step(r) {\n r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r);\n }\n\n function fulfill(value) {\n resume(\"next\", value);\n }\n\n function reject(value) {\n resume(\"throw\", value);\n }\n\n function settle(f, v) {\n if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]);\n }\n}\nexport function __asyncDelegator(o) {\n var i, p;\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) {\n throw e;\n }), verb(\"return\"), i[Symbol.iterator] = function () {\n return this;\n }, i;\n\n function verb(n, f) {\n i[n] = o[n] ? function (v) {\n return (p = !p) ? {\n value: __await(o[n](v)),\n done: n === \"return\"\n } : f ? f(v) : v;\n } : f;\n }\n}\nexport function __asyncValues(o) {\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\n var m = o[Symbol.asyncIterator],\n i;\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () {\n return this;\n }, i);\n\n function verb(n) {\n i[n] = o[n] && function (v) {\n return new Promise(function (resolve, reject) {\n v = o[n](v), settle(resolve, reject, v.done, v.value);\n });\n };\n }\n\n function settle(resolve, reject, d, v) {\n Promise.resolve(v).then(function (v) {\n resolve({\n value: v,\n done: d\n });\n }, reject);\n }\n}\nexport function __makeTemplateObject(cooked, raw) {\n if (Object.defineProperty) {\n Object.defineProperty(cooked, \"raw\", {\n value: raw\n });\n } else {\n cooked.raw = raw;\n }\n\n return cooked;\n}\n;\nexport function __importStar(mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) {\n if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];\n }\n result.default = mod;\n return result;\n}\nexport function __importDefault(mod) {\n return mod && mod.__esModule ? mod : {\n default: mod\n };\n}","import firebase from '@firebase/app';\nimport { __spread, __awaiter, __generator, __extends, __assign } from 'tslib';\nimport { ErrorFactory, createSubscribe } from '@firebase/util';\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\nvar _a;\n\nvar ERROR_MAP = (_a = {}, _a[\"only-available-in-window\"\n/* AVAILABLE_IN_WINDOW */\n] = 'This method is available in a Window context.', _a[\"only-available-in-sw\"\n/* AVAILABLE_IN_SW */\n] = 'This method is available in a service worker context.', _a[\"should-be-overriden\"\n/* SHOULD_BE_INHERITED */\n] = 'This method should be overriden by extended classes.', _a[\"bad-sender-id\"\n/* BAD_SENDER_ID */\n] = \"Please ensure that 'messagingSenderId' is set \" + 'correctly in the options passed into firebase.initializeApp().', _a[\"permission-default\"\n/* PERMISSION_DEFAULT */\n] = 'The required permissions were not granted and dismissed instead.', _a[\"permission-blocked\"\n/* PERMISSION_BLOCKED */\n] = 'The required permissions were not granted and blocked instead.', _a[\"unsupported-browser\"\n/* UNSUPPORTED_BROWSER */\n] = \"This browser doesn't support the API's \" + 'required to use the firebase SDK.', _a[\"notifications-blocked\"\n/* NOTIFICATIONS_BLOCKED */\n] = 'Notifications have been blocked.', _a[\"failed-serviceworker-registration\"\n/* FAILED_DEFAULT_REGISTRATION */\n] = 'We are unable to register the ' + 'default service worker. {$browserErrorMessage}', _a[\"sw-registration-expected\"\n/* SW_REGISTRATION_EXPECTED */\n] = 'A service worker registration was the expected input.', _a[\"get-subscription-failed\"\n/* GET_SUBSCRIPTION_FAILED */\n] = 'There was an error when trying to get ' + 'any existing Push Subscriptions.', _a[\"invalid-saved-token\"\n/* INVALID_SAVED_TOKEN */\n] = 'Unable to access details of the saved token.', _a[\"sw-reg-redundant\"\n/* SW_REG_REDUNDANT */\n] = 'The service worker being used for push was made redundant.', _a[\"token-subscribe-failed\"\n/* TOKEN_SUBSCRIBE_FAILED */\n] = 'A problem occured while subscribing the user to FCM: {$errorInfo}', _a[\"token-subscribe-no-token\"\n/* TOKEN_SUBSCRIBE_NO_TOKEN */\n] = 'FCM returned no token when subscribing the user to push.', _a[\"token-subscribe-no-push-set\"\n/* TOKEN_SUBSCRIBE_NO_PUSH_SET */\n] = 'FCM returned an invalid response when getting an FCM token.', _a[\"token-unsubscribe-failed\"\n/* TOKEN_UNSUBSCRIBE_FAILED */\n] = 'A problem occured while unsubscribing the ' + 'user from FCM: {$errorInfo}', _a[\"token-update-failed\"\n/* TOKEN_UPDATE_FAILED */\n] = 'A problem occured while updating the user from FCM: {$errorInfo}', _a[\"token-update-no-token\"\n/* TOKEN_UPDATE_NO_TOKEN */\n] = 'FCM returned no token when updating the user to push.', _a[\"use-sw-before-get-token\"\n/* USE_SW_BEFORE_GET_TOKEN */\n] = 'The useServiceWorker() method may only be called once and must be ' + 'called before calling getToken() to ensure your service worker is used.', _a[\"invalid-delete-token\"\n/* INVALID_DELETE_TOKEN */\n] = 'You must pass a valid token into ' + 'deleteToken(), i.e. the token from getToken().', _a[\"delete-token-not-found\"\n/* DELETE_TOKEN_NOT_FOUND */\n] = 'The deletion attempt for token could not ' + 'be performed as the token was not found.', _a[\"delete-scope-not-found\"\n/* DELETE_SCOPE_NOT_FOUND */\n] = 'The deletion attempt for service worker ' + 'scope could not be performed as the scope was not found.', _a[\"bg-handler-function-expected\"\n/* BG_HANDLER_FUNCTION_EXPECTED */\n] = 'The input to setBackgroundMessageHandler() must be a function.', _a[\"no-window-client-to-msg\"\n/* NO_WINDOW_CLIENT_TO_MSG */\n] = 'An attempt was made to message a non-existant window client.', _a[\"unable-to-resubscribe\"\n/* UNABLE_TO_RESUBSCRIBE */\n] = 'There was an error while re-subscribing ' + 'the FCM token for push messaging. Will have to resubscribe the ' + 'user on next visit. {$errorInfo}', _a[\"no-fcm-token-for-resubscribe\"\n/* NO_FCM_TOKEN_FOR_RESUBSCRIBE */\n] = 'Could not find an FCM token ' + 'and as a result, unable to resubscribe. Will have to resubscribe the ' + 'user on next visit.', _a[\"failed-to-delete-token\"\n/* FAILED_TO_DELETE_TOKEN */\n] = 'Unable to delete the currently saved token.', _a[\"no-sw-in-reg\"\n/* NO_SW_IN_REG */\n] = 'Even though the service worker registration was ' + 'successful, there was a problem accessing the service worker itself.', _a[\"bad-scope\"\n/* BAD_SCOPE */\n] = 'The service worker scope must be a string with at ' + 'least one character.', _a[\"bad-vapid-key\"\n/* BAD_VAPID_KEY */\n] = 'The public VAPID key is not a Uint8Array with 65 bytes.', _a[\"bad-subscription\"\n/* BAD_SUBSCRIPTION */\n] = 'The subscription must be a valid PushSubscription.', _a[\"bad-token\"\n/* BAD_TOKEN */\n] = 'The FCM Token used for storage / lookup was not ' + 'a valid token string.', _a[\"bad-push-set\"\n/* BAD_PUSH_SET */\n] = 'The FCM push set used for storage / lookup was not ' + 'not a valid push set string.', _a[\"failed-delete-vapid-key\"\n/* FAILED_DELETE_VAPID_KEY */\n] = 'The VAPID key could not be deleted.', _a[\"invalid-public-vapid-key\"\n/* INVALID_PUBLIC_VAPID_KEY */\n] = 'The public VAPID key must be a string.', _a[\"use-public-key-before-get-token\"\n/* USE_PUBLIC_KEY_BEFORE_GET_TOKEN */\n] = 'The usePublicVapidKey() method may only be called once and must be ' + 'called before calling getToken() to ensure your VAPID key is used.', _a[\"public-vapid-key-decryption-failed\"\n/* PUBLIC_KEY_DECRYPTION_FAILED */\n] = 'The public VAPID key did not equal 65 bytes when decrypted.', _a);\nvar errorFactory = new ErrorFactory('messaging', 'Messaging', ERROR_MAP);\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\nvar DEFAULT_PUBLIC_VAPID_KEY = new Uint8Array([0x04, 0x33, 0x94, 0xf7, 0xdf, 0xa1, 0xeb, 0xb1, 0xdc, 0x03, 0xa2, 0x5e, 0x15, 0x71, 0xdb, 0x48, 0xd3, 0x2e, 0xed, 0xed, 0xb2, 0x34, 0xdb, 0xb7, 0x47, 0x3a, 0x0c, 0x8f, 0xc4, 0xcc, 0xe1, 0x6f, 0x3c, 0x8c, 0x84, 0xdf, 0xab, 0xb6, 0x66, 0x3e, 0xf2, 0x0c, 0xd4, 0x8b, 0xfe, 0xe3, 0xf9, 0x76, 0x2f, 0x14, 0x1c, 0x63, 0x08, 0x6a, 0x6f, 0x2d, 0xb1, 0x1a, 0x95, 0xb0, 0xce, 0x37, 0xc0, 0x9c, 0x6e]);\nvar ENDPOINT = 'https://fcm.googleapis.com';\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\nvar MessageParameter;\n\n(function (MessageParameter) {\n MessageParameter[\"TYPE_OF_MSG\"] = \"firebase-messaging-msg-type\";\n MessageParameter[\"DATA\"] = \"firebase-messaging-msg-data\";\n})(MessageParameter || (MessageParameter = {}));\n\nvar MessageType;\n\n(function (MessageType) {\n MessageType[\"PUSH_MSG_RECEIVED\"] = \"push-msg-received\";\n MessageType[\"NOTIFICATION_CLICKED\"] = \"notification-clicked\";\n})(MessageType || (MessageType = {}));\n/**\r\n * @license\r\n * Copyright 2018 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nfunction isArrayBufferEqual(a, b) {\n if (a == null || b == null) {\n return false;\n }\n\n if (a === b) {\n return true;\n }\n\n if (a.byteLength !== b.byteLength) {\n return false;\n }\n\n var viewA = new DataView(a);\n var viewB = new DataView(b);\n\n for (var i = 0; i < a.byteLength; i++) {\n if (viewA.getUint8(i) !== viewB.getUint8(i)) {\n return false;\n }\n }\n\n return true;\n}\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nfunction toBase64(arrayBuffer) {\n var uint8Version = new Uint8Array(arrayBuffer);\n return btoa(String.fromCharCode.apply(String, __spread(uint8Version)));\n}\n\nfunction arrayBufferToBase64(arrayBuffer) {\n var base64String = toBase64(arrayBuffer);\n return base64String.replace(/=/g, '').replace(/\\+/g, '-').replace(/\\//g, '_');\n}\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nvar IidModel =\n/** @class */\nfunction () {\n function IidModel() {}\n\n IidModel.prototype.getToken = function (senderId, subscription, publicVapidKey) {\n return __awaiter(this, void 0, void 0, function () {\n var p256dh, auth, fcmSubscribeBody, applicationPubKey, headers, subscribeOptions, responseData, response, err_1, message;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n p256dh = arrayBufferToBase64(subscription.getKey('p256dh'));\n auth = arrayBufferToBase64(subscription.getKey('auth'));\n fcmSubscribeBody = \"authorized_entity=\" + senderId + \"&\" + (\"endpoint=\" + subscription.endpoint + \"&\") + (\"encryption_key=\" + p256dh + \"&\") + (\"encryption_auth=\" + auth);\n\n if (!isArrayBufferEqual(publicVapidKey.buffer, DEFAULT_PUBLIC_VAPID_KEY.buffer)) {\n applicationPubKey = arrayBufferToBase64(publicVapidKey);\n fcmSubscribeBody += \"&application_pub_key=\" + applicationPubKey;\n }\n\n headers = new Headers();\n headers.append('Content-Type', 'application/x-www-form-urlencoded');\n subscribeOptions = {\n method: 'POST',\n headers: headers,\n body: fcmSubscribeBody\n };\n _a.label = 1;\n\n case 1:\n _a.trys.push([1, 4,, 5]);\n\n return [4\n /*yield*/\n , fetch(ENDPOINT + '/fcm/connect/subscribe', subscribeOptions)];\n\n case 2:\n response = _a.sent();\n return [4\n /*yield*/\n , response.json()];\n\n case 3:\n responseData = _a.sent();\n return [3\n /*break*/\n , 5];\n\n case 4:\n err_1 = _a.sent();\n throw errorFactory.create(\"token-subscribe-failed\"\n /* TOKEN_SUBSCRIBE_FAILED */\n , {\n errorInfo: err_1\n });\n\n case 5:\n if (responseData.error) {\n message = responseData.error.message;\n throw errorFactory.create(\"token-subscribe-failed\"\n /* TOKEN_SUBSCRIBE_FAILED */\n , {\n errorInfo: message\n });\n }\n\n if (!responseData.token) {\n throw errorFactory.create(\"token-subscribe-no-token\"\n /* TOKEN_SUBSCRIBE_NO_TOKEN */\n );\n }\n\n if (!responseData.pushSet) {\n throw errorFactory.create(\"token-subscribe-no-push-set\"\n /* TOKEN_SUBSCRIBE_NO_PUSH_SET */\n );\n }\n\n return [2\n /*return*/\n , {\n token: responseData.token,\n pushSet: responseData.pushSet\n }];\n }\n });\n });\n };\n /**\r\n * Update the underlying token details for fcmToken.\r\n */\n\n\n IidModel.prototype.updateToken = function (senderId, fcmToken, fcmPushSet, subscription, publicVapidKey) {\n return __awaiter(this, void 0, void 0, function () {\n var p256dh, auth, fcmUpdateBody, applicationPubKey, headers, updateOptions, responseData, response, err_2, message;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n p256dh = arrayBufferToBase64(subscription.getKey('p256dh'));\n auth = arrayBufferToBase64(subscription.getKey('auth'));\n fcmUpdateBody = \"push_set=\" + fcmPushSet + \"&\" + (\"token=\" + fcmToken + \"&\") + (\"authorized_entity=\" + senderId + \"&\") + (\"endpoint=\" + subscription.endpoint + \"&\") + (\"encryption_key=\" + p256dh + \"&\") + (\"encryption_auth=\" + auth);\n\n if (!isArrayBufferEqual(publicVapidKey.buffer, DEFAULT_PUBLIC_VAPID_KEY.buffer)) {\n applicationPubKey = arrayBufferToBase64(publicVapidKey);\n fcmUpdateBody += \"&application_pub_key=\" + applicationPubKey;\n }\n\n headers = new Headers();\n headers.append('Content-Type', 'application/x-www-form-urlencoded');\n updateOptions = {\n method: 'POST',\n headers: headers,\n body: fcmUpdateBody\n };\n _a.label = 1;\n\n case 1:\n _a.trys.push([1, 4,, 5]);\n\n return [4\n /*yield*/\n , fetch(ENDPOINT + '/fcm/connect/subscribe', updateOptions)];\n\n case 2:\n response = _a.sent();\n return [4\n /*yield*/\n , response.json()];\n\n case 3:\n responseData = _a.sent();\n return [3\n /*break*/\n , 5];\n\n case 4:\n err_2 = _a.sent();\n throw errorFactory.create(\"token-update-failed\"\n /* TOKEN_UPDATE_FAILED */\n , {\n errorInfo: err_2\n });\n\n case 5:\n if (responseData.error) {\n message = responseData.error.message;\n throw errorFactory.create(\"token-update-failed\"\n /* TOKEN_UPDATE_FAILED */\n , {\n errorInfo: message\n });\n }\n\n if (!responseData.token) {\n throw errorFactory.create(\"token-update-no-token\"\n /* TOKEN_UPDATE_NO_TOKEN */\n );\n }\n\n return [2\n /*return*/\n , responseData.token];\n }\n });\n });\n };\n /**\r\n * Given a fcmToken, pushSet and messagingSenderId, delete an FCM token.\r\n */\n\n\n IidModel.prototype.deleteToken = function (senderId, fcmToken, fcmPushSet) {\n return __awaiter(this, void 0, void 0, function () {\n var fcmUnsubscribeBody, headers, unsubscribeOptions, response, responseData, message, err_3;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n fcmUnsubscribeBody = \"authorized_entity=\" + senderId + \"&\" + (\"token=\" + fcmToken + \"&\") + (\"pushSet=\" + fcmPushSet);\n headers = new Headers();\n headers.append('Content-Type', 'application/x-www-form-urlencoded');\n unsubscribeOptions = {\n method: 'POST',\n headers: headers,\n body: fcmUnsubscribeBody\n };\n _a.label = 1;\n\n case 1:\n _a.trys.push([1, 4,, 5]);\n\n return [4\n /*yield*/\n , fetch(ENDPOINT + '/fcm/connect/unsubscribe', unsubscribeOptions)];\n\n case 2:\n response = _a.sent();\n return [4\n /*yield*/\n , response.json()];\n\n case 3:\n responseData = _a.sent();\n\n if (responseData.error) {\n message = responseData.error.message;\n throw errorFactory.create(\"token-unsubscribe-failed\"\n /* TOKEN_UNSUBSCRIBE_FAILED */\n , {\n errorInfo: message\n });\n }\n\n return [3\n /*break*/\n , 5];\n\n case 4:\n err_3 = _a.sent();\n throw errorFactory.create(\"token-unsubscribe-failed\"\n /* TOKEN_UNSUBSCRIBE_FAILED */\n , {\n errorInfo: err_3\n });\n\n case 5:\n return [2\n /*return*/\n ];\n }\n });\n });\n };\n\n return IidModel;\n}();\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nfunction base64ToArrayBuffer(base64String) {\n var padding = '='.repeat((4 - base64String.length % 4) % 4);\n var base64 = (base64String + padding).replace(/\\-/g, '+').replace(/_/g, '/');\n var rawData = atob(base64);\n var outputArray = new Uint8Array(rawData.length);\n\n for (var i = 0; i < rawData.length; ++i) {\n outputArray[i] = rawData.charCodeAt(i);\n }\n\n return outputArray;\n}\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nvar OLD_DB_NAME = 'undefined';\nvar OLD_OBJECT_STORE_NAME = 'fcm_token_object_Store';\n\nfunction handleDb(db) {\n if (!db.objectStoreNames.contains(OLD_OBJECT_STORE_NAME)) {\n // We found a database with the name 'undefined', but our expected object\n // store isn't defined.\n return;\n }\n\n var transaction = db.transaction(OLD_OBJECT_STORE_NAME);\n var objectStore = transaction.objectStore(OLD_OBJECT_STORE_NAME);\n var iidModel = new IidModel();\n var openCursorRequest = objectStore.openCursor();\n\n openCursorRequest.onerror = function (event) {\n // NOOP - Nothing we can do.\n console.warn('Unable to cleanup old IDB.', event);\n };\n\n openCursorRequest.onsuccess = function () {\n var cursor = openCursorRequest.result;\n\n if (cursor) {\n // cursor.value contains the current record being iterated through\n // this is where you'd do something with the result\n var tokenDetails = cursor.value; // eslint-disable-next-line @typescript-eslint/no-floating-promises\n\n iidModel.deleteToken(tokenDetails.fcmSenderId, tokenDetails.fcmToken, tokenDetails.fcmPushSet);\n cursor.continue();\n } else {\n db.close();\n indexedDB.deleteDatabase(OLD_DB_NAME);\n }\n };\n}\n\nfunction cleanV1() {\n var request = indexedDB.open(OLD_DB_NAME);\n\n request.onerror = function (_event) {// NOOP - Nothing we can do.\n };\n\n request.onsuccess = function (_event) {\n var db = request.result;\n handleDb(db);\n };\n}\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nvar DbInterface =\n/** @class */\nfunction () {\n function DbInterface() {\n this.dbPromise = null;\n }\n /** Gets record(s) from the objectStore that match the given key. */\n\n\n DbInterface.prototype.get = function (key) {\n return this.createTransaction(function (objectStore) {\n return objectStore.get(key);\n });\n };\n /** Gets record(s) from the objectStore that match the given index. */\n\n\n DbInterface.prototype.getIndex = function (index, key) {\n function runRequest(objectStore) {\n var idbIndex = objectStore.index(index);\n return idbIndex.get(key);\n }\n\n return this.createTransaction(runRequest);\n };\n /** Assigns or overwrites the record for the given value. */\n // IndexedDB values are of type \"any\"\n\n\n DbInterface.prototype.put = function (value) {\n return this.createTransaction(function (objectStore) {\n return objectStore.put(value);\n }, 'readwrite');\n };\n /** Deletes record(s) from the objectStore that match the given key. */\n\n\n DbInterface.prototype.delete = function (key) {\n return this.createTransaction(function (objectStore) {\n return objectStore.delete(key);\n }, 'readwrite');\n };\n /**\r\n * Close the currently open database.\r\n */\n\n\n DbInterface.prototype.closeDatabase = function () {\n return __awaiter(this, void 0, void 0, function () {\n var db;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!this.dbPromise) return [3\n /*break*/\n , 2];\n return [4\n /*yield*/\n , this.dbPromise];\n\n case 1:\n db = _a.sent();\n db.close();\n this.dbPromise = null;\n _a.label = 2;\n\n case 2:\n return [2\n /*return*/\n ];\n }\n });\n });\n };\n /**\r\n * Creates an IndexedDB Transaction and passes its objectStore to the\r\n * runRequest function, which runs the database request.\r\n *\r\n * @return Promise that resolves with the result of the runRequest function\r\n */\n\n\n DbInterface.prototype.createTransaction = function (runRequest, mode) {\n if (mode === void 0) {\n mode = 'readonly';\n }\n\n return __awaiter(this, void 0, void 0, function () {\n var db, transaction, request, result;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n return [4\n /*yield*/\n , this.getDb()];\n\n case 1:\n db = _a.sent();\n transaction = db.transaction(this.objectStoreName, mode);\n request = transaction.objectStore(this.objectStoreName);\n return [4\n /*yield*/\n , promisify(runRequest(request))];\n\n case 2:\n result = _a.sent();\n return [2\n /*return*/\n , new Promise(function (resolve, reject) {\n transaction.oncomplete = function () {\n resolve(result);\n };\n\n transaction.onerror = function () {\n reject(transaction.error);\n };\n })];\n }\n });\n });\n };\n /** Gets the cached db connection or opens a new one. */\n\n\n DbInterface.prototype.getDb = function () {\n var _this = this;\n\n if (!this.dbPromise) {\n this.dbPromise = new Promise(function (resolve, reject) {\n var request = indexedDB.open(_this.dbName, _this.dbVersion);\n\n request.onsuccess = function () {\n resolve(request.result);\n };\n\n request.onerror = function () {\n _this.dbPromise = null;\n reject(request.error);\n };\n\n request.onupgradeneeded = function (event) {\n return _this.onDbUpgrade(request, event);\n };\n });\n }\n\n return this.dbPromise;\n };\n\n return DbInterface;\n}();\n/** Promisifies an IDBRequest. Resolves with the IDBRequest's result. */\n\n\nfunction promisify(request) {\n return new Promise(function (resolve, reject) {\n request.onsuccess = function () {\n resolve(request.result);\n };\n\n request.onerror = function () {\n reject(request.error);\n };\n });\n}\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nvar TokenDetailsModel =\n/** @class */\nfunction (_super) {\n __extends(TokenDetailsModel, _super);\n\n function TokenDetailsModel() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n\n _this.dbName = 'fcm_token_details_db';\n _this.dbVersion = 3;\n _this.objectStoreName = 'fcm_token_object_Store';\n return _this;\n }\n\n TokenDetailsModel.prototype.onDbUpgrade = function (request, event) {\n var db = request.result; // Lack of 'break' statements is intentional.\n\n switch (event.oldVersion) {\n case 0:\n {\n // New IDB instance\n var objectStore = db.createObjectStore(this.objectStoreName, {\n keyPath: 'swScope'\n }); // Make sure the sender ID can be searched\n\n objectStore.createIndex('fcmSenderId', 'fcmSenderId', {\n unique: false\n });\n objectStore.createIndex('fcmToken', 'fcmToken', {\n unique: true\n });\n }\n\n case 1:\n {\n // Prior to version 2, we were using either 'fcm_token_details_db'\n // or 'undefined' as the database name due to bug in the SDK\n // So remove the old tokens and databases.\n cleanV1();\n }\n\n case 2:\n {\n var objectStore = request.transaction.objectStore(this.objectStoreName);\n var cursorRequest_1 = objectStore.openCursor();\n\n cursorRequest_1.onsuccess = function () {\n var cursor = cursorRequest_1.result;\n\n if (cursor) {\n var value = cursor.value;\n\n var newValue = __assign({}, value);\n\n if (!value.createTime) {\n newValue.createTime = Date.now();\n }\n\n if (typeof value.vapidKey === 'string') {\n newValue.vapidKey = base64ToArrayBuffer(value.vapidKey);\n }\n\n if (typeof value.auth === 'string') {\n newValue.auth = base64ToArrayBuffer(value.auth).buffer;\n }\n\n if (typeof value.auth === 'string') {\n newValue.p256dh = base64ToArrayBuffer(value.p256dh).buffer;\n }\n\n cursor.update(newValue);\n cursor.continue();\n }\n };\n }\n\n default: // ignore\n\n }\n };\n /**\r\n * Given a token, this method will look up the details in indexedDB.\r\n */\n\n\n TokenDetailsModel.prototype.getTokenDetailsFromToken = function (fcmToken) {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n if (!fcmToken) {\n throw errorFactory.create(\"bad-token\"\n /* BAD_TOKEN */\n );\n }\n\n validateInputs({\n fcmToken: fcmToken\n });\n return [2\n /*return*/\n , this.getIndex('fcmToken', fcmToken)];\n });\n });\n };\n /**\r\n * Given a service worker scope, this method will look up the details in\r\n * indexedDB.\r\n * @return The details associated with that token.\r\n */\n\n\n TokenDetailsModel.prototype.getTokenDetailsFromSWScope = function (swScope) {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n if (!swScope) {\n throw errorFactory.create(\"bad-scope\"\n /* BAD_SCOPE */\n );\n }\n\n validateInputs({\n swScope: swScope\n });\n return [2\n /*return*/\n , this.get(swScope)];\n });\n });\n };\n /**\r\n * Save the details for the fcm token for re-use at a later date.\r\n * @param input A plain js object containing args to save.\r\n */\n\n\n TokenDetailsModel.prototype.saveTokenDetails = function (tokenDetails) {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n if (!tokenDetails.swScope) {\n throw errorFactory.create(\"bad-scope\"\n /* BAD_SCOPE */\n );\n }\n\n if (!tokenDetails.vapidKey) {\n throw errorFactory.create(\"bad-vapid-key\"\n /* BAD_VAPID_KEY */\n );\n }\n\n if (!tokenDetails.endpoint || !tokenDetails.auth || !tokenDetails.p256dh) {\n throw errorFactory.create(\"bad-subscription\"\n /* BAD_SUBSCRIPTION */\n );\n }\n\n if (!tokenDetails.fcmSenderId) {\n throw errorFactory.create(\"bad-sender-id\"\n /* BAD_SENDER_ID */\n );\n }\n\n if (!tokenDetails.fcmToken) {\n throw errorFactory.create(\"bad-token\"\n /* BAD_TOKEN */\n );\n }\n\n if (!tokenDetails.fcmPushSet) {\n throw errorFactory.create(\"bad-push-set\"\n /* BAD_PUSH_SET */\n );\n }\n\n validateInputs(tokenDetails);\n return [2\n /*return*/\n , this.put(tokenDetails)];\n });\n });\n };\n /**\r\n * This method deletes details of the current FCM token.\r\n * It's returning a promise in case we need to move to an async\r\n * method for deleting at a later date.\r\n *\r\n * @return Resolves once the FCM token details have been deleted and returns\r\n * the deleted details.\r\n */\n\n\n TokenDetailsModel.prototype.deleteToken = function (token) {\n return __awaiter(this, void 0, void 0, function () {\n var details;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (typeof token !== 'string' || token.length === 0) {\n return [2\n /*return*/\n , Promise.reject(errorFactory.create(\"invalid-delete-token\"\n /* INVALID_DELETE_TOKEN */\n ))];\n }\n\n return [4\n /*yield*/\n , this.getTokenDetailsFromToken(token)];\n\n case 1:\n details = _a.sent();\n\n if (!details) {\n throw errorFactory.create(\"delete-token-not-found\"\n /* DELETE_TOKEN_NOT_FOUND */\n );\n }\n\n return [4\n /*yield*/\n , this.delete(details.swScope)];\n\n case 2:\n _a.sent();\n\n return [2\n /*return*/\n , details];\n }\n });\n });\n };\n\n return TokenDetailsModel;\n}(DbInterface);\n/**\r\n * This method takes an object and will check for known arguments and\r\n * validate the input.\r\n * @return Promise that resolves if input is valid, rejects otherwise.\r\n */\n\n\nfunction validateInputs(input) {\n if (input.fcmToken) {\n if (typeof input.fcmToken !== 'string' || input.fcmToken.length === 0) {\n throw errorFactory.create(\"bad-token\"\n /* BAD_TOKEN */\n );\n }\n }\n\n if (input.swScope) {\n if (typeof input.swScope !== 'string' || input.swScope.length === 0) {\n throw errorFactory.create(\"bad-scope\"\n /* BAD_SCOPE */\n );\n }\n }\n\n if (input.vapidKey) {\n if (!(input.vapidKey instanceof Uint8Array) || input.vapidKey.length !== 65) {\n throw errorFactory.create(\"bad-vapid-key\"\n /* BAD_VAPID_KEY */\n );\n }\n }\n\n if (input.endpoint) {\n if (typeof input.endpoint !== 'string' || input.endpoint.length === 0) {\n throw errorFactory.create(\"bad-subscription\"\n /* BAD_SUBSCRIPTION */\n );\n }\n }\n\n if (input.auth) {\n if (!(input.auth instanceof ArrayBuffer)) {\n throw errorFactory.create(\"bad-subscription\"\n /* BAD_SUBSCRIPTION */\n );\n }\n }\n\n if (input.p256dh) {\n if (!(input.p256dh instanceof ArrayBuffer)) {\n throw errorFactory.create(\"bad-subscription\"\n /* BAD_SUBSCRIPTION */\n );\n }\n }\n\n if (input.fcmSenderId) {\n if (typeof input.fcmSenderId !== 'string' || input.fcmSenderId.length === 0) {\n throw errorFactory.create(\"bad-sender-id\"\n /* BAD_SENDER_ID */\n );\n }\n }\n\n if (input.fcmPushSet) {\n if (typeof input.fcmPushSet !== 'string' || input.fcmPushSet.length === 0) {\n throw errorFactory.create(\"bad-push-set\"\n /* BAD_PUSH_SET */\n );\n }\n }\n}\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nvar UNCOMPRESSED_PUBLIC_KEY_SIZE = 65;\n\nvar VapidDetailsModel =\n/** @class */\nfunction (_super) {\n __extends(VapidDetailsModel, _super);\n\n function VapidDetailsModel() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n\n _this.dbName = 'fcm_vapid_details_db';\n _this.dbVersion = 1;\n _this.objectStoreName = 'fcm_vapid_object_Store';\n return _this;\n }\n\n VapidDetailsModel.prototype.onDbUpgrade = function (request) {\n var db = request.result;\n db.createObjectStore(this.objectStoreName, {\n keyPath: 'swScope'\n });\n };\n /**\r\n * Given a service worker scope, this method will look up the vapid key\r\n * in indexedDB.\r\n */\n\n\n VapidDetailsModel.prototype.getVapidFromSWScope = function (swScope) {\n return __awaiter(this, void 0, void 0, function () {\n var result;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (typeof swScope !== 'string' || swScope.length === 0) {\n throw errorFactory.create(\"bad-scope\"\n /* BAD_SCOPE */\n );\n }\n\n return [4\n /*yield*/\n , this.get(swScope)];\n\n case 1:\n result = _a.sent();\n return [2\n /*return*/\n , result ? result.vapidKey : undefined];\n }\n });\n });\n };\n /**\r\n * Save a vapid key against a swScope for later date.\r\n */\n\n\n VapidDetailsModel.prototype.saveVapidDetails = function (swScope, vapidKey) {\n return __awaiter(this, void 0, void 0, function () {\n var details;\n return __generator(this, function (_a) {\n if (typeof swScope !== 'string' || swScope.length === 0) {\n throw errorFactory.create(\"bad-scope\"\n /* BAD_SCOPE */\n );\n }\n\n if (vapidKey === null || vapidKey.length !== UNCOMPRESSED_PUBLIC_KEY_SIZE) {\n throw errorFactory.create(\"bad-vapid-key\"\n /* BAD_VAPID_KEY */\n );\n }\n\n details = {\n swScope: swScope,\n vapidKey: vapidKey\n };\n return [2\n /*return*/\n , this.put(details)];\n });\n });\n };\n /**\r\n * This method deletes details of the current FCM VAPID key for a SW scope.\r\n * Resolves once the scope/vapid details have been deleted and returns the\r\n * deleted vapid key.\r\n */\n\n\n VapidDetailsModel.prototype.deleteVapidDetails = function (swScope) {\n return __awaiter(this, void 0, void 0, function () {\n var vapidKey;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n return [4\n /*yield*/\n , this.getVapidFromSWScope(swScope)];\n\n case 1:\n vapidKey = _a.sent();\n\n if (!vapidKey) {\n throw errorFactory.create(\"delete-scope-not-found\"\n /* DELETE_SCOPE_NOT_FOUND */\n );\n }\n\n return [4\n /*yield*/\n , this.delete(swScope)];\n\n case 2:\n _a.sent();\n\n return [2\n /*return*/\n , vapidKey];\n }\n });\n });\n };\n\n return VapidDetailsModel;\n}(DbInterface);\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nvar SENDER_ID_OPTION_NAME = 'messagingSenderId'; // Database cache should be invalidated once a week.\n\nvar TOKEN_EXPIRATION_MILLIS = 7 * 24 * 60 * 60 * 1000; // 7 days\n\nvar BaseController =\n/** @class */\nfunction () {\n /**\r\n * An interface of the Messaging Service API\r\n */\n function BaseController(app) {\n var _this = this;\n\n if (!app.options[SENDER_ID_OPTION_NAME] || typeof app.options[SENDER_ID_OPTION_NAME] !== 'string') {\n throw errorFactory.create(\"bad-sender-id\"\n /* BAD_SENDER_ID */\n );\n }\n\n this.messagingSenderId = app.options[SENDER_ID_OPTION_NAME];\n this.tokenDetailsModel = new TokenDetailsModel();\n this.vapidDetailsModel = new VapidDetailsModel();\n this.iidModel = new IidModel();\n this.app = app;\n this.INTERNAL = {\n delete: function _delete() {\n return _this.delete();\n }\n };\n }\n /**\r\n * @export\r\n */\n\n\n BaseController.prototype.getToken = function () {\n return __awaiter(this, void 0, void 0, function () {\n var currentPermission, swReg, publicVapidKey, pushSubscription, tokenDetails;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n currentPermission = this.getNotificationPermission_();\n\n if (currentPermission === 'denied') {\n throw errorFactory.create(\"notifications-blocked\"\n /* NOTIFICATIONS_BLOCKED */\n );\n } else if (currentPermission !== 'granted') {\n // We must wait for permission to be granted\n return [2\n /*return*/\n , null];\n }\n\n return [4\n /*yield*/\n , this.getSWRegistration_()];\n\n case 1:\n swReg = _a.sent();\n return [4\n /*yield*/\n , this.getPublicVapidKey_()];\n\n case 2:\n publicVapidKey = _a.sent();\n return [4\n /*yield*/\n , this.getPushSubscription(swReg, publicVapidKey)];\n\n case 3:\n pushSubscription = _a.sent();\n return [4\n /*yield*/\n , this.tokenDetailsModel.getTokenDetailsFromSWScope(swReg.scope)];\n\n case 4:\n tokenDetails = _a.sent();\n\n if (tokenDetails) {\n return [2\n /*return*/\n , this.manageExistingToken(swReg, pushSubscription, publicVapidKey, tokenDetails)];\n }\n\n return [2\n /*return*/\n , this.getNewToken(swReg, pushSubscription, publicVapidKey)];\n }\n });\n });\n };\n /**\r\n * manageExistingToken is triggered if there's an existing FCM token in the\r\n * database and it can take 3 different actions:\r\n * 1) Retrieve the existing FCM token from the database.\r\n * 2) If VAPID details have changed: Delete the existing token and create a\r\n * new one with the new VAPID key.\r\n * 3) If the database cache is invalidated: Send a request to FCM to update\r\n * the token, and to check if the token is still valid on FCM-side.\r\n */\n\n\n BaseController.prototype.manageExistingToken = function (swReg, pushSubscription, publicVapidKey, tokenDetails) {\n return __awaiter(this, void 0, void 0, function () {\n var isTokenValid, now;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n isTokenValid = isTokenStillValid(pushSubscription, publicVapidKey, tokenDetails);\n\n if (isTokenValid) {\n now = Date.now();\n\n if (now < tokenDetails.createTime + TOKEN_EXPIRATION_MILLIS) {\n return [2\n /*return*/\n , tokenDetails.fcmToken];\n } else {\n return [2\n /*return*/\n , this.updateToken(swReg, pushSubscription, publicVapidKey, tokenDetails)];\n }\n } // If the token is no longer valid (for example if the VAPID details\n // have changed), delete the existing token from the FCM client and server\n // database. No need to unsubscribe from the Service Worker as we have a\n // good push subscription that we'd like to use in getNewToken.\n\n\n return [4\n /*yield*/\n , this.deleteTokenFromDB(tokenDetails.fcmToken)];\n\n case 1:\n // If the token is no longer valid (for example if the VAPID details\n // have changed), delete the existing token from the FCM client and server\n // database. No need to unsubscribe from the Service Worker as we have a\n // good push subscription that we'd like to use in getNewToken.\n _a.sent();\n\n return [2\n /*return*/\n , this.getNewToken(swReg, pushSubscription, publicVapidKey)];\n }\n });\n });\n };\n\n BaseController.prototype.updateToken = function (swReg, pushSubscription, publicVapidKey, tokenDetails) {\n return __awaiter(this, void 0, void 0, function () {\n var updatedToken, allDetails, e_1;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n _a.trys.push([0, 4,, 6]);\n\n return [4\n /*yield*/\n , this.iidModel.updateToken(this.messagingSenderId, tokenDetails.fcmToken, tokenDetails.fcmPushSet, pushSubscription, publicVapidKey)];\n\n case 1:\n updatedToken = _a.sent();\n allDetails = {\n swScope: swReg.scope,\n vapidKey: publicVapidKey,\n fcmSenderId: this.messagingSenderId,\n fcmToken: updatedToken,\n fcmPushSet: tokenDetails.fcmPushSet,\n createTime: Date.now(),\n endpoint: pushSubscription.endpoint,\n auth: pushSubscription.getKey('auth'),\n p256dh: pushSubscription.getKey('p256dh')\n };\n return [4\n /*yield*/\n , this.tokenDetailsModel.saveTokenDetails(allDetails)];\n\n case 2:\n _a.sent();\n\n return [4\n /*yield*/\n , this.vapidDetailsModel.saveVapidDetails(swReg.scope, publicVapidKey)];\n\n case 3:\n _a.sent();\n\n return [2\n /*return*/\n , updatedToken];\n\n case 4:\n e_1 = _a.sent();\n return [4\n /*yield*/\n , this.deleteToken(tokenDetails.fcmToken)];\n\n case 5:\n _a.sent();\n\n throw e_1;\n\n case 6:\n return [2\n /*return*/\n ];\n }\n });\n });\n };\n\n BaseController.prototype.getNewToken = function (swReg, pushSubscription, publicVapidKey) {\n return __awaiter(this, void 0, void 0, function () {\n var tokenDetails, allDetails;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n return [4\n /*yield*/\n , this.iidModel.getToken(this.messagingSenderId, pushSubscription, publicVapidKey)];\n\n case 1:\n tokenDetails = _a.sent();\n allDetails = {\n swScope: swReg.scope,\n vapidKey: publicVapidKey,\n fcmSenderId: this.messagingSenderId,\n fcmToken: tokenDetails.token,\n fcmPushSet: tokenDetails.pushSet,\n createTime: Date.now(),\n endpoint: pushSubscription.endpoint,\n auth: pushSubscription.getKey('auth'),\n p256dh: pushSubscription.getKey('p256dh')\n };\n return [4\n /*yield*/\n , this.tokenDetailsModel.saveTokenDetails(allDetails)];\n\n case 2:\n _a.sent();\n\n return [4\n /*yield*/\n , this.vapidDetailsModel.saveVapidDetails(swReg.scope, publicVapidKey)];\n\n case 3:\n _a.sent();\n\n return [2\n /*return*/\n , tokenDetails.token];\n }\n });\n });\n };\n /**\r\n * This method deletes tokens that the token manager looks after,\r\n * unsubscribes the token from FCM and then unregisters the push\r\n * subscription if it exists. It returns a promise that indicates\r\n * whether or not the unsubscribe request was processed successfully.\r\n */\n\n\n BaseController.prototype.deleteToken = function (token) {\n return __awaiter(this, void 0, void 0, function () {\n var registration, pushSubscription;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n // Delete the token details from the database.\n return [4\n /*yield*/\n , this.deleteTokenFromDB(token)];\n\n case 1:\n // Delete the token details from the database.\n _a.sent();\n\n return [4\n /*yield*/\n , this.getSWRegistration_()];\n\n case 2:\n registration = _a.sent();\n if (!registration) return [3\n /*break*/\n , 4];\n return [4\n /*yield*/\n , registration.pushManager.getSubscription()];\n\n case 3:\n pushSubscription = _a.sent();\n\n if (pushSubscription) {\n return [2\n /*return*/\n , pushSubscription.unsubscribe()];\n }\n\n _a.label = 4;\n\n case 4:\n // If there's no SW, consider it a success.\n return [2\n /*return*/\n , true];\n }\n });\n });\n };\n /**\r\n * This method will delete the token from the client database, and make a\r\n * call to FCM to remove it from the server DB. Does not temper with the\r\n * push subscription.\r\n */\n\n\n BaseController.prototype.deleteTokenFromDB = function (token) {\n return __awaiter(this, void 0, void 0, function () {\n var details;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n return [4\n /*yield*/\n , this.tokenDetailsModel.deleteToken(token)];\n\n case 1:\n details = _a.sent();\n return [4\n /*yield*/\n , this.iidModel.deleteToken(details.fcmSenderId, details.fcmToken, details.fcmPushSet)];\n\n case 2:\n _a.sent();\n\n return [2\n /*return*/\n ];\n }\n });\n });\n };\n /**\r\n * Gets a PushSubscription for the current user.\r\n */\n\n\n BaseController.prototype.getPushSubscription = function (swRegistration, publicVapidKey) {\n return swRegistration.pushManager.getSubscription().then(function (subscription) {\n if (subscription) {\n return subscription;\n }\n\n return swRegistration.pushManager.subscribe({\n userVisibleOnly: true,\n applicationServerKey: publicVapidKey\n });\n });\n }; //\n // The following methods should only be available in the window.\n //\n\n /**\r\n * @deprecated Use Notification.requestPermission() instead.\r\n * https://developer.mozilla.org/en-US/docs/Web/API/Notification/requestPermission\r\n */\n\n\n BaseController.prototype.requestPermission = function () {\n throw errorFactory.create(\"only-available-in-window\"\n /* AVAILABLE_IN_WINDOW */\n );\n };\n\n BaseController.prototype.useServiceWorker = function (_registration) {\n throw errorFactory.create(\"only-available-in-window\"\n /* AVAILABLE_IN_WINDOW */\n );\n };\n\n BaseController.prototype.usePublicVapidKey = function (_b64PublicKey) {\n throw errorFactory.create(\"only-available-in-window\"\n /* AVAILABLE_IN_WINDOW */\n );\n };\n\n BaseController.prototype.onMessage = function (_nextOrObserver, _error, _completed) {\n throw errorFactory.create(\"only-available-in-window\"\n /* AVAILABLE_IN_WINDOW */\n );\n };\n\n BaseController.prototype.onTokenRefresh = function (_nextOrObserver, _error, _completed) {\n throw errorFactory.create(\"only-available-in-window\"\n /* AVAILABLE_IN_WINDOW */\n );\n }; //\n // The following methods are used by the service worker only.\n //\n\n\n BaseController.prototype.setBackgroundMessageHandler = function (_callback) {\n throw errorFactory.create(\"only-available-in-sw\"\n /* AVAILABLE_IN_SW */\n );\n }; //\n // The following methods are used by the service themselves and not exposed\n // publicly or not expected to be used by developers.\n //\n\n /**\r\n * This method is required to adhere to the Firebase interface.\r\n * It closes any currently open indexdb database connections.\r\n */\n\n\n BaseController.prototype.delete = function () {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n return [4\n /*yield*/\n , Promise.all([this.tokenDetailsModel.closeDatabase(), this.vapidDetailsModel.closeDatabase()])];\n\n case 1:\n _a.sent();\n\n return [2\n /*return*/\n ];\n }\n });\n });\n };\n /**\r\n * Returns the current Notification Permission state.\r\n */\n\n\n BaseController.prototype.getNotificationPermission_ = function () {\n return Notification.permission;\n };\n\n BaseController.prototype.getTokenDetailsModel = function () {\n return this.tokenDetailsModel;\n };\n\n BaseController.prototype.getVapidDetailsModel = function () {\n return this.vapidDetailsModel;\n }; // Visible for testing\n // TODO: make protected\n\n\n BaseController.prototype.getIidModel = function () {\n return this.iidModel;\n };\n\n return BaseController;\n}();\n/**\r\n * Checks if the tokenDetails match the details provided in the clients.\r\n */\n\n\nfunction isTokenStillValid(pushSubscription, publicVapidKey, tokenDetails) {\n if (!tokenDetails.vapidKey || !isArrayBufferEqual(publicVapidKey.buffer, tokenDetails.vapidKey.buffer)) {\n return false;\n }\n\n var isEndpointEqual = pushSubscription.endpoint === tokenDetails.endpoint;\n var isAuthEqual = isArrayBufferEqual(pushSubscription.getKey('auth'), tokenDetails.auth);\n var isP256dhEqual = isArrayBufferEqual(pushSubscription.getKey('p256dh'), tokenDetails.p256dh);\n return isEndpointEqual && isAuthEqual && isP256dhEqual;\n}\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nvar FCM_MSG = 'FCM_MSG';\n\nvar SwController =\n/** @class */\nfunction (_super) {\n __extends(SwController, _super);\n\n function SwController(app) {\n var _this = _super.call(this, app) || this;\n\n _this.bgMessageHandler = null;\n self.addEventListener('push', function (e) {\n _this.onPush(e);\n });\n self.addEventListener('pushsubscriptionchange', function (e) {\n _this.onSubChange(e);\n });\n self.addEventListener('notificationclick', function (e) {\n _this.onNotificationClick(e);\n });\n return _this;\n } // Visible for testing\n // TODO: Make private\n\n\n SwController.prototype.onPush = function (event) {\n event.waitUntil(this.onPush_(event));\n }; // Visible for testing\n // TODO: Make private\n\n\n SwController.prototype.onSubChange = function (event) {\n event.waitUntil(this.onSubChange_(event));\n }; // Visible for testing\n // TODO: Make private\n\n\n SwController.prototype.onNotificationClick = function (event) {\n event.waitUntil(this.onNotificationClick_(event));\n };\n /**\r\n * A handler for push events that shows notifications based on the content of\r\n * the payload.\r\n *\r\n * The payload must be a JSON-encoded Object with a `notification` key. The\r\n * value of the `notification` property will be used as the NotificationOptions\r\n * object passed to showNotification. Additionally, the `title` property of the\r\n * notification object will be used as the title.\r\n *\r\n * If there is no notification data in the payload then no notification will be\r\n * shown.\r\n */\n\n\n SwController.prototype.onPush_ = function (event) {\n return __awaiter(this, void 0, void 0, function () {\n var msgPayload, hasVisibleClients, notificationDetails, notificationTitle, reg, actions, maxActions;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!event.data) {\n return [2\n /*return*/\n ];\n }\n\n try {\n msgPayload = event.data.json();\n } catch (err) {\n // Not JSON so not an FCM message\n return [2\n /*return*/\n ];\n }\n\n return [4\n /*yield*/\n , this.hasVisibleClients_()];\n\n case 1:\n hasVisibleClients = _a.sent();\n\n if (hasVisibleClients) {\n // App in foreground. Send to page.\n return [2\n /*return*/\n , this.sendMessageToWindowClients_(msgPayload)];\n }\n\n notificationDetails = this.getNotificationData_(msgPayload);\n if (!notificationDetails) return [3\n /*break*/\n , 3];\n notificationTitle = notificationDetails.title || '';\n return [4\n /*yield*/\n , this.getSWRegistration_()];\n\n case 2:\n reg = _a.sent();\n actions = notificationDetails.actions;\n maxActions = Notification.maxActions; // tslint:enable no-any\n\n if (actions && maxActions && actions.length > maxActions) {\n console.warn(\"This browser only supports \" + maxActions + \" actions.\" + \"The remaining actions will not be displayed.\");\n }\n\n return [2\n /*return*/\n , reg.showNotification(notificationTitle, notificationDetails)];\n\n case 3:\n if (!this.bgMessageHandler) return [3\n /*break*/\n , 5];\n return [4\n /*yield*/\n , this.bgMessageHandler(msgPayload)];\n\n case 4:\n _a.sent();\n\n return [2\n /*return*/\n ];\n\n case 5:\n return [2\n /*return*/\n ];\n }\n });\n });\n };\n\n SwController.prototype.onSubChange_ = function (_event) {\n return __awaiter(this, void 0, void 0, function () {\n var registration, err_1, err_2, tokenDetailsModel, tokenDetails;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n _a.trys.push([0, 2,, 3]);\n\n return [4\n /*yield*/\n , this.getSWRegistration_()];\n\n case 1:\n registration = _a.sent();\n return [3\n /*break*/\n , 3];\n\n case 2:\n err_1 = _a.sent();\n throw errorFactory.create(\"unable-to-resubscribe\"\n /* UNABLE_TO_RESUBSCRIBE */\n , {\n errorInfo: err_1\n });\n\n case 3:\n _a.trys.push([3, 5,, 8]);\n\n return [4\n /*yield*/\n , registration.pushManager.getSubscription()];\n\n case 4:\n _a.sent();\n\n return [3\n /*break*/\n , 8];\n\n case 5:\n err_2 = _a.sent();\n tokenDetailsModel = this.getTokenDetailsModel();\n return [4\n /*yield*/\n , tokenDetailsModel.getTokenDetailsFromSWScope(registration.scope)];\n\n case 6:\n tokenDetails = _a.sent();\n\n if (!tokenDetails) {\n // This should rarely occure, but could if indexedDB\n // is corrupted or wiped\n throw err_2;\n } // Attempt to delete the token if we know it's bad\n\n\n return [4\n /*yield*/\n , this.deleteToken(tokenDetails.fcmToken)];\n\n case 7:\n // Attempt to delete the token if we know it's bad\n _a.sent();\n\n throw err_2;\n\n case 8:\n return [2\n /*return*/\n ];\n }\n });\n });\n };\n\n SwController.prototype.onNotificationClick_ = function (event) {\n return __awaiter(this, void 0, void 0, function () {\n var msgPayload, link, windowClient, internalMsg;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!event.notification || !event.notification.data || !event.notification.data[FCM_MSG]) {\n // Not an FCM notification, do nothing.\n return [2\n /*return*/\n ];\n } else if (event.action) {\n // User clicked on an action button.\n // This will allow devs to act on action button clicks by using a custom\n // onNotificationClick listener that they define.\n return [2\n /*return*/\n ];\n } // Prevent other listeners from receiving the event\n\n\n event.stopImmediatePropagation();\n event.notification.close();\n msgPayload = event.notification.data[FCM_MSG];\n\n if (!msgPayload.notification) {\n // Nothing to do.\n return [2\n /*return*/\n ];\n }\n\n link = msgPayload.fcmOptions && msgPayload.fcmOptions.link || msgPayload.notification.click_action;\n\n if (!link) {\n // Nothing to do.\n return [2\n /*return*/\n ];\n }\n\n return [4\n /*yield*/\n , this.getWindowClient_(link)];\n\n case 1:\n windowClient = _a.sent();\n if (!!windowClient) return [3\n /*break*/\n , 3];\n return [4\n /*yield*/\n , self.clients.openWindow(link)];\n\n case 2:\n // Unable to find window client so need to open one.\n windowClient = _a.sent();\n return [3\n /*break*/\n , 5];\n\n case 3:\n return [4\n /*yield*/\n , windowClient.focus()];\n\n case 4:\n windowClient = _a.sent();\n _a.label = 5;\n\n case 5:\n if (!windowClient) {\n // Window Client will not be returned if it's for a third party origin.\n return [2\n /*return*/\n ];\n } // Delete notification and fcmOptions data from payload before sending to\n // the page.\n\n\n delete msgPayload.notification;\n delete msgPayload.fcmOptions;\n internalMsg = createNewMsg(MessageType.NOTIFICATION_CLICKED, msgPayload); // Attempt to send a message to the client to handle the data\n // Is affected by: https://github.com/slightlyoff/ServiceWorker/issues/728\n\n return [2\n /*return*/\n , this.attemptToMessageClient_(windowClient, internalMsg)];\n }\n });\n });\n }; // Visible for testing\n // TODO: Make private\n\n\n SwController.prototype.getNotificationData_ = function (msgPayload) {\n var _a;\n\n if (!msgPayload) {\n return;\n }\n\n if (typeof msgPayload.notification !== 'object') {\n return;\n }\n\n var notificationInformation = __assign({}, msgPayload.notification); // Put the message payload under FCM_MSG name so we can identify the\n // notification as being an FCM notification vs a notification from\n // somewhere else (i.e. normal web push or developer generated\n // notification).\n\n\n notificationInformation.data = __assign({}, msgPayload.notification.data, (_a = {}, _a[FCM_MSG] = msgPayload, _a));\n return notificationInformation;\n };\n /**\r\n * Calling setBackgroundMessageHandler will opt in to some specific\r\n * behaviours.\r\n * 1.) If a notification doesn't need to be shown due to a window already\r\n * being visible, then push messages will be sent to the page.\r\n * 2.) If a notification needs to be shown, and the message contains no\r\n * notification data this method will be called\r\n * and the promise it returns will be passed to event.waitUntil.\r\n * If you do not set this callback then all push messages will let and the\r\n * developer can handle them in a their own 'push' event callback\r\n *\r\n * @param callback The callback to be called when a push message is received\r\n * and a notification must be shown. The callback will be given the data from\r\n * the push message.\r\n */\n\n\n SwController.prototype.setBackgroundMessageHandler = function (callback) {\n if (!callback || typeof callback !== 'function') {\n throw errorFactory.create(\"bg-handler-function-expected\"\n /* BG_HANDLER_FUNCTION_EXPECTED */\n );\n }\n\n this.bgMessageHandler = callback;\n };\n /**\r\n * @param url The URL to look for when focusing a client.\r\n * @return Returns an existing window client or a newly opened WindowClient.\r\n */\n // Visible for testing\n // TODO: Make private\n\n\n SwController.prototype.getWindowClient_ = function (url) {\n return __awaiter(this, void 0, void 0, function () {\n var parsedURL, clientList, suitableClient, i, parsedClientUrl;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n parsedURL = new URL(url, self.location.href).href;\n return [4\n /*yield*/\n , getClientList()];\n\n case 1:\n clientList = _a.sent();\n suitableClient = null;\n\n for (i = 0; i < clientList.length; i++) {\n parsedClientUrl = new URL(clientList[i].url, self.location.href).href;\n\n if (parsedClientUrl === parsedURL) {\n suitableClient = clientList[i];\n break;\n }\n }\n\n return [2\n /*return*/\n , suitableClient];\n }\n });\n });\n };\n /**\r\n * This message will attempt to send the message to a window client.\r\n * @param client The WindowClient to send the message to.\r\n * @param message The message to send to the client.\r\n * @returns Returns a promise that resolves after sending the message. This\r\n * does not guarantee that the message was successfully received.\r\n */\n // Visible for testing\n // TODO: Make private\n\n\n SwController.prototype.attemptToMessageClient_ = function (client, message) {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n // NOTE: This returns a promise in case this API is abstracted later on to\n // do additional work\n if (!client) {\n throw errorFactory.create(\"no-window-client-to-msg\"\n /* NO_WINDOW_CLIENT_TO_MSG */\n );\n }\n\n client.postMessage(message);\n return [2\n /*return*/\n ];\n });\n });\n };\n /**\r\n * @returns If there is currently a visible WindowClient, this method will\r\n * resolve to true, otherwise false.\r\n */\n // Visible for testing\n // TODO: Make private\n\n\n SwController.prototype.hasVisibleClients_ = function () {\n return __awaiter(this, void 0, void 0, function () {\n var clientList;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n return [4\n /*yield*/\n , getClientList()];\n\n case 1:\n clientList = _a.sent();\n return [2\n /*return*/\n , clientList.some(function (client) {\n return client.visibilityState === 'visible' && // Ignore chrome-extension clients as that matches the background pages\n // of extensions, which are always considered visible.\n !client.url.startsWith('chrome-extension://');\n })];\n }\n });\n });\n };\n /**\r\n * @param msgPayload The data from the push event that should be sent to all\r\n * available pages.\r\n * @returns Returns a promise that resolves once the message has been sent to\r\n * all WindowClients.\r\n */\n // Visible for testing\n // TODO: Make private\n\n\n SwController.prototype.sendMessageToWindowClients_ = function (msgPayload) {\n return __awaiter(this, void 0, void 0, function () {\n var clientList, internalMsg;\n\n var _this = this;\n\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n return [4\n /*yield*/\n , getClientList()];\n\n case 1:\n clientList = _a.sent();\n internalMsg = createNewMsg(MessageType.PUSH_MSG_RECEIVED, msgPayload);\n return [4\n /*yield*/\n , Promise.all(clientList.map(function (client) {\n return _this.attemptToMessageClient_(client, internalMsg);\n }))];\n\n case 2:\n _a.sent();\n\n return [2\n /*return*/\n ];\n }\n });\n });\n };\n /**\r\n * This will register the default service worker and return the registration.\r\n * @return he service worker registration to be used for the push service.\r\n */\n\n\n SwController.prototype.getSWRegistration_ = function () {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n return [2\n /*return*/\n , self.registration];\n });\n });\n };\n /**\r\n * This will return the default VAPID key or the uint8array version of the\r\n * public VAPID key provided by the developer.\r\n */\n\n\n SwController.prototype.getPublicVapidKey_ = function () {\n return __awaiter(this, void 0, void 0, function () {\n var swReg, vapidKeyFromDatabase;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n return [4\n /*yield*/\n , this.getSWRegistration_()];\n\n case 1:\n swReg = _a.sent();\n\n if (!swReg) {\n throw errorFactory.create(\"sw-registration-expected\"\n /* SW_REGISTRATION_EXPECTED */\n );\n }\n\n return [4\n /*yield*/\n , this.getVapidDetailsModel().getVapidFromSWScope(swReg.scope)];\n\n case 2:\n vapidKeyFromDatabase = _a.sent();\n\n if (vapidKeyFromDatabase == null) {\n return [2\n /*return*/\n , DEFAULT_PUBLIC_VAPID_KEY];\n }\n\n return [2\n /*return*/\n , vapidKeyFromDatabase];\n }\n });\n });\n };\n\n return SwController;\n}(BaseController);\n\nfunction getClientList() {\n return self.clients.matchAll({\n type: 'window',\n includeUncontrolled: true // TS doesn't know that \"type: 'window'\" means it'll return WindowClient[]\n\n });\n}\n\nfunction createNewMsg(msgType, msgData) {\n var _a;\n\n return _a = {}, _a[MessageParameter.TYPE_OF_MSG] = msgType, _a[MessageParameter.DATA] = msgData, _a;\n}\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nvar DEFAULT_SW_PATH = '/firebase-messaging-sw.js';\nvar DEFAULT_SW_SCOPE = '/firebase-cloud-messaging-push-scope';\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\nvar WindowController =\n/** @class */\nfunction (_super) {\n __extends(WindowController, _super);\n /**\r\n * A service that provides a MessagingService instance.\r\n */\n\n\n function WindowController(app) {\n var _this = _super.call(this, app) || this;\n\n _this.registrationToUse = null;\n _this.publicVapidKeyToUse = null;\n _this.messageObserver = null; // @ts-ignore: Unused variable error, this is not implemented yet.\n\n _this.tokenRefreshObserver = null;\n _this.onMessageInternal = createSubscribe(function (observer) {\n _this.messageObserver = observer;\n });\n _this.onTokenRefreshInternal = createSubscribe(function (observer) {\n _this.tokenRefreshObserver = observer;\n });\n\n _this.setupSWMessageListener_();\n\n return _this;\n }\n /**\r\n * Request permission if it is not currently granted\r\n *\r\n * @return Resolves if the permission was granted, otherwise rejects\r\n *\r\n * @deprecated Use Notification.requestPermission() instead.\r\n * https://developer.mozilla.org/en-US/docs/Web/API/Notification/requestPermission\r\n */\n\n\n WindowController.prototype.requestPermission = function () {\n return __awaiter(this, void 0, void 0, function () {\n var permissionResult;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (this.getNotificationPermission_() === 'granted') {\n return [2\n /*return*/\n ];\n }\n\n return [4\n /*yield*/\n , Notification.requestPermission()];\n\n case 1:\n permissionResult = _a.sent();\n\n if (permissionResult === 'granted') {\n return [2\n /*return*/\n ];\n } else if (permissionResult === 'denied') {\n throw errorFactory.create(\"permission-blocked\"\n /* PERMISSION_BLOCKED */\n );\n } else {\n throw errorFactory.create(\"permission-default\"\n /* PERMISSION_DEFAULT */\n );\n }\n\n return [2\n /*return*/\n ];\n }\n });\n });\n };\n /**\r\n * This method allows a developer to override the default service worker and\r\n * instead use a custom service worker.\r\n *\r\n * @param registration The service worker registration that should be used to\r\n * receive the push messages.\r\n */\n\n\n WindowController.prototype.useServiceWorker = function (registration) {\n if (!(registration instanceof ServiceWorkerRegistration)) {\n throw errorFactory.create(\"sw-registration-expected\"\n /* SW_REGISTRATION_EXPECTED */\n );\n }\n\n if (this.registrationToUse != null) {\n throw errorFactory.create(\"use-sw-before-get-token\"\n /* USE_SW_BEFORE_GET_TOKEN */\n );\n }\n\n this.registrationToUse = registration;\n };\n /**\r\n * This method allows a developer to override the default vapid key\r\n * and instead use a custom VAPID public key.\r\n *\r\n * @param publicKey A URL safe base64 encoded string.\r\n */\n\n\n WindowController.prototype.usePublicVapidKey = function (publicKey) {\n if (typeof publicKey !== 'string') {\n throw errorFactory.create(\"invalid-public-vapid-key\"\n /* INVALID_PUBLIC_VAPID_KEY */\n );\n }\n\n if (this.publicVapidKeyToUse != null) {\n throw errorFactory.create(\"use-public-key-before-get-token\"\n /* USE_PUBLIC_KEY_BEFORE_GET_TOKEN */\n );\n }\n\n var parsedKey = base64ToArrayBuffer(publicKey);\n\n if (parsedKey.length !== 65) {\n throw errorFactory.create(\"public-vapid-key-decryption-failed\"\n /* PUBLIC_KEY_DECRYPTION_FAILED */\n );\n }\n\n this.publicVapidKeyToUse = parsedKey;\n };\n /**\r\n * @export\r\n * @param nextOrObserver An observer object or a function triggered on\r\n * message.\r\n * @param error A function triggered on message error.\r\n * @param completed function triggered when the observer is removed.\r\n * @return The unsubscribe function for the observer.\r\n */\n\n\n WindowController.prototype.onMessage = function (nextOrObserver, error, completed) {\n if (typeof nextOrObserver === 'function') {\n return this.onMessageInternal(nextOrObserver, error, completed);\n } else {\n return this.onMessageInternal(nextOrObserver);\n }\n };\n /**\r\n * @param nextOrObserver An observer object or a function triggered on token\r\n * refresh.\r\n * @param error A function triggered on token refresh error.\r\n * @param completed function triggered when the observer is removed.\r\n * @return The unsubscribe function for the observer.\r\n */\n\n\n WindowController.prototype.onTokenRefresh = function (nextOrObserver, error, completed) {\n if (typeof nextOrObserver === 'function') {\n return this.onTokenRefreshInternal(nextOrObserver, error, completed);\n } else {\n return this.onTokenRefreshInternal(nextOrObserver);\n }\n };\n /**\r\n * Given a registration, wait for the service worker it relates to\r\n * become activer\r\n * @param registration Registration to wait for service worker to become active\r\n * @return Wait for service worker registration to become active\r\n */\n // Visible for testing\n // TODO: Make private\n\n\n WindowController.prototype.waitForRegistrationToActivate_ = function (registration) {\n var serviceWorker = registration.installing || registration.waiting || registration.active;\n return new Promise(function (resolve, reject) {\n if (!serviceWorker) {\n // This is a rare scenario but has occured in firefox\n reject(errorFactory.create(\"no-sw-in-reg\"\n /* NO_SW_IN_REG */\n ));\n return;\n } // Because the Promise function is called on next tick there is a\n // small chance that the worker became active or redundant already.\n\n\n if (serviceWorker.state === 'activated') {\n resolve(registration);\n return;\n }\n\n if (serviceWorker.state === 'redundant') {\n reject(errorFactory.create(\"sw-reg-redundant\"\n /* SW_REG_REDUNDANT */\n ));\n return;\n }\n\n var stateChangeListener = function stateChangeListener() {\n if (serviceWorker.state === 'activated') {\n resolve(registration);\n } else if (serviceWorker.state === 'redundant') {\n reject(errorFactory.create(\"sw-reg-redundant\"\n /* SW_REG_REDUNDANT */\n ));\n } else {\n // Return early and wait to next state change\n return;\n }\n\n serviceWorker.removeEventListener('statechange', stateChangeListener);\n };\n\n serviceWorker.addEventListener('statechange', stateChangeListener);\n });\n };\n /**\r\n * This will register the default service worker and return the registration\r\n * @return The service worker registration to be used for the push service.\r\n */\n\n\n WindowController.prototype.getSWRegistration_ = function () {\n var _this = this;\n\n if (this.registrationToUse) {\n return this.waitForRegistrationToActivate_(this.registrationToUse);\n } // Make the registration null so we know useServiceWorker will not\n // use a new service worker as registrationToUse is no longer undefined\n\n\n this.registrationToUse = null;\n return navigator.serviceWorker.register(DEFAULT_SW_PATH, {\n scope: DEFAULT_SW_SCOPE\n }).catch(function (err) {\n throw errorFactory.create(\"failed-serviceworker-registration\"\n /* FAILED_DEFAULT_REGISTRATION */\n , {\n browserErrorMessage: err.message\n });\n }).then(function (registration) {\n return _this.waitForRegistrationToActivate_(registration).then(function () {\n _this.registrationToUse = registration; // We update after activation due to an issue with Firefox v49 where\n // a race condition occassionally causes the service worker to not\n // install\n // eslint-disable-next-line @typescript-eslint/no-floating-promises\n\n registration.update();\n return registration;\n });\n });\n };\n /**\r\n * This will return the default VAPID key or the uint8array version of the public VAPID key\r\n * provided by the developer.\r\n */\n\n\n WindowController.prototype.getPublicVapidKey_ = function () {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n if (this.publicVapidKeyToUse) {\n return [2\n /*return*/\n , this.publicVapidKeyToUse];\n }\n\n return [2\n /*return*/\n , DEFAULT_PUBLIC_VAPID_KEY];\n });\n });\n };\n /**\r\n * This method will set up a message listener to handle\r\n * events from the service worker that should trigger\r\n * events in the page.\r\n */\n // Visible for testing\n // TODO: Make private\n\n\n WindowController.prototype.setupSWMessageListener_ = function () {\n var _this = this;\n\n navigator.serviceWorker.addEventListener('message', function (event) {\n if (!event.data || !event.data[MessageParameter.TYPE_OF_MSG]) {\n // Not a message from FCM\n return;\n }\n\n var workerPageMessage = event.data;\n\n switch (workerPageMessage[MessageParameter.TYPE_OF_MSG]) {\n case MessageType.PUSH_MSG_RECEIVED:\n case MessageType.NOTIFICATION_CLICKED:\n var pushMessage = workerPageMessage[MessageParameter.DATA];\n\n if (_this.messageObserver) {\n _this.messageObserver.next(pushMessage);\n }\n\n break;\n\n default:\n // Noop.\n break;\n }\n }, false);\n };\n\n return WindowController;\n}(BaseController);\n/**\r\n * @license\r\n * Copyright 2017 Google Inc.\r\n *\r\n * Licensed under the Apache License, Version 2.0 (the \"License\");\r\n * you may not use this file except in compliance with the License.\r\n * You may obtain a copy of the License at\r\n *\r\n * http://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless required by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an \"AS IS\" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\n\n\nfunction registerMessaging(instance) {\n var messagingName = 'messaging';\n\n var factoryMethod = function factoryMethod(app) {\n if (!isSupported()) {\n throw errorFactory.create(\"unsupported-browser\"\n /* UNSUPPORTED_BROWSER */\n );\n }\n\n if (self && 'ServiceWorkerGlobalScope' in self) {\n // Running in ServiceWorker context\n return new SwController(app);\n } else {\n // Assume we are in the window context.\n return new WindowController(app);\n }\n };\n\n var namespaceExports = {\n isSupported: isSupported\n };\n instance.INTERNAL.registerService(messagingName, factoryMethod, namespaceExports);\n}\n\nregisterMessaging(firebase);\n\nfunction isSupported() {\n if (self && 'ServiceWorkerGlobalScope' in self) {\n // Running in ServiceWorker context\n return isSWControllerSupported();\n } else {\n // Assume we are in the window context.\n return isWindowControllerSupported();\n }\n}\n/**\r\n * Checks to see if the required APIs exist.\r\n */\n\n\nfunction isWindowControllerSupported() {\n return navigator.cookieEnabled && 'serviceWorker' in navigator && 'PushManager' in window && 'Notification' in window && 'fetch' in window && ServiceWorkerRegistration.prototype.hasOwnProperty('showNotification') && PushSubscription.prototype.hasOwnProperty('getKey');\n}\n/**\r\n * Checks to see if the required APIs exist within SW Context.\r\n */\n\n\nfunction isSWControllerSupported() {\n return 'PushManager' in self && 'Notification' in self && ServiceWorkerRegistration.prototype.hasOwnProperty('showNotification') && PushSubscription.prototype.hasOwnProperty('getKey');\n}\n\nexport { isSupported, registerMessaging };","/** @license React v16.13.1\n * react.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';\n\nvar l = require(\"object-assign\"),\n n = \"function\" === typeof Symbol && Symbol.for,\n p = n ? Symbol.for(\"react.element\") : 60103,\n q = n ? Symbol.for(\"react.portal\") : 60106,\n r = n ? Symbol.for(\"react.fragment\") : 60107,\n t = n ? Symbol.for(\"react.strict_mode\") : 60108,\n u = n ? Symbol.for(\"react.profiler\") : 60114,\n v = n ? Symbol.for(\"react.provider\") : 60109,\n w = n ? Symbol.for(\"react.context\") : 60110,\n x = n ? Symbol.for(\"react.forward_ref\") : 60112,\n y = n ? Symbol.for(\"react.suspense\") : 60113,\n z = n ? Symbol.for(\"react.memo\") : 60115,\n A = n ? Symbol.for(\"react.lazy\") : 60116,\n B = \"function\" === typeof Symbol && Symbol.iterator;\n\nfunction C(a) {\n for (var b = \"https://reactjs.org/docs/error-decoder.html?invariant=\" + a, c = 1; c < arguments.length; c++) {\n b += \"&args[]=\" + encodeURIComponent(arguments[c]);\n }\n\n return \"Minified React error #\" + a + \"; visit \" + b + \" for the full message or use the non-minified dev environment for full errors and additional helpful warnings.\";\n}\n\nvar D = {\n isMounted: function isMounted() {\n return !1;\n },\n enqueueForceUpdate: function enqueueForceUpdate() {},\n enqueueReplaceState: function enqueueReplaceState() {},\n enqueueSetState: function enqueueSetState() {}\n},\n E = {};\n\nfunction F(a, b, c) {\n this.props = a;\n this.context = b;\n this.refs = E;\n this.updater = c || D;\n}\n\nF.prototype.isReactComponent = {};\n\nF.prototype.setState = function (a, b) {\n if (\"object\" !== typeof a && \"function\" !== typeof a && null != a) throw Error(C(85));\n this.updater.enqueueSetState(this, a, b, \"setState\");\n};\n\nF.prototype.forceUpdate = function (a) {\n this.updater.enqueueForceUpdate(this, a, \"forceUpdate\");\n};\n\nfunction G() {}\n\nG.prototype = F.prototype;\n\nfunction H(a, b, c) {\n this.props = a;\n this.context = b;\n this.refs = E;\n this.updater = c || D;\n}\n\nvar I = H.prototype = new G();\nI.constructor = H;\nl(I, F.prototype);\nI.isPureReactComponent = !0;\nvar J = {\n current: null\n},\n K = Object.prototype.hasOwnProperty,\n L = {\n key: !0,\n ref: !0,\n __self: !0,\n __source: !0\n};\n\nfunction M(a, b, c) {\n var e,\n d = {},\n g = null,\n k = null;\n if (null != b) for (e in void 0 !== b.ref && (k = b.ref), void 0 !== b.key && (g = \"\" + b.key), b) {\n K.call(b, e) && !L.hasOwnProperty(e) && (d[e] = b[e]);\n }\n var f = arguments.length - 2;\n if (1 === f) d.children = c;else if (1 < f) {\n for (var h = Array(f), m = 0; m < f; m++) {\n h[m] = arguments[m + 2];\n }\n\n d.children = h;\n }\n if (a && a.defaultProps) for (e in f = a.defaultProps, f) {\n void 0 === d[e] && (d[e] = f[e]);\n }\n return {\n $$typeof: p,\n type: a,\n key: g,\n ref: k,\n props: d,\n _owner: J.current\n };\n}\n\nfunction N(a, b) {\n return {\n $$typeof: p,\n type: a.type,\n key: b,\n ref: a.ref,\n props: a.props,\n _owner: a._owner\n };\n}\n\nfunction O(a) {\n return \"object\" === typeof a && null !== a && a.$$typeof === p;\n}\n\nfunction escape(a) {\n var b = {\n \"=\": \"=0\",\n \":\": \"=2\"\n };\n return \"$\" + (\"\" + a).replace(/[=:]/g, function (a) {\n return b[a];\n });\n}\n\nvar P = /\\/+/g,\n Q = [];\n\nfunction R(a, b, c, e) {\n if (Q.length) {\n var d = Q.pop();\n d.result = a;\n d.keyPrefix = b;\n d.func = c;\n d.context = e;\n d.count = 0;\n return d;\n }\n\n return {\n result: a,\n keyPrefix: b,\n func: c,\n context: e,\n count: 0\n };\n}\n\nfunction S(a) {\n a.result = null;\n a.keyPrefix = null;\n a.func = null;\n a.context = null;\n a.count = 0;\n 10 > Q.length && Q.push(a);\n}\n\nfunction T(a, b, c, e) {\n var d = typeof a;\n if (\"undefined\" === d || \"boolean\" === d) a = null;\n var g = !1;\n if (null === a) g = !0;else switch (d) {\n case \"string\":\n case \"number\":\n g = !0;\n break;\n\n case \"object\":\n switch (a.$$typeof) {\n case p:\n case q:\n g = !0;\n }\n\n }\n if (g) return c(e, a, \"\" === b ? \".\" + U(a, 0) : b), 1;\n g = 0;\n b = \"\" === b ? \".\" : b + \":\";\n if (Array.isArray(a)) for (var k = 0; k < a.length; k++) {\n d = a[k];\n var f = b + U(d, k);\n g += T(d, f, c, e);\n } else if (null === a || \"object\" !== typeof a ? f = null : (f = B && a[B] || a[\"@@iterator\"], f = \"function\" === typeof f ? f : null), \"function\" === typeof f) for (a = f.call(a), k = 0; !(d = a.next()).done;) {\n d = d.value, f = b + U(d, k++), g += T(d, f, c, e);\n } else if (\"object\" === d) throw c = \"\" + a, Error(C(31, \"[object Object]\" === c ? \"object with keys {\" + Object.keys(a).join(\", \") + \"}\" : c, \"\"));\n return g;\n}\n\nfunction V(a, b, c) {\n return null == a ? 0 : T(a, \"\", b, c);\n}\n\nfunction U(a, b) {\n return \"object\" === typeof a && null !== a && null != a.key ? escape(a.key) : b.toString(36);\n}\n\nfunction W(a, b) {\n a.func.call(a.context, b, a.count++);\n}\n\nfunction aa(a, b, c) {\n var e = a.result,\n d = a.keyPrefix;\n a = a.func.call(a.context, b, a.count++);\n Array.isArray(a) ? X(a, e, c, function (a) {\n return a;\n }) : null != a && (O(a) && (a = N(a, d + (!a.key || b && b.key === a.key ? \"\" : (\"\" + a.key).replace(P, \"$&/\") + \"/\") + c)), e.push(a));\n}\n\nfunction X(a, b, c, e, d) {\n var g = \"\";\n null != c && (g = (\"\" + c).replace(P, \"$&/\") + \"/\");\n b = R(b, g, e, d);\n V(a, aa, b);\n S(b);\n}\n\nvar Y = {\n current: null\n};\n\nfunction Z() {\n var a = Y.current;\n if (null === a) throw Error(C(321));\n return a;\n}\n\nvar ba = {\n ReactCurrentDispatcher: Y,\n ReactCurrentBatchConfig: {\n suspense: null\n },\n ReactCurrentOwner: J,\n IsSomeRendererActing: {\n current: !1\n },\n assign: l\n};\nexports.Children = {\n map: function map(a, b, c) {\n if (null == a) return a;\n var e = [];\n X(a, e, null, b, c);\n return e;\n },\n forEach: function forEach(a, b, c) {\n if (null == a) return a;\n b = R(null, null, b, c);\n V(a, W, b);\n S(b);\n },\n count: function count(a) {\n return V(a, function () {\n return null;\n }, null);\n },\n toArray: function toArray(a) {\n var b = [];\n X(a, b, null, function (a) {\n return a;\n });\n return b;\n },\n only: function only(a) {\n if (!O(a)) throw Error(C(143));\n return a;\n }\n};\nexports.Component = F;\nexports.Fragment = r;\nexports.Profiler = u;\nexports.PureComponent = H;\nexports.StrictMode = t;\nexports.Suspense = y;\nexports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = ba;\n\nexports.cloneElement = function (a, b, c) {\n if (null === a || void 0 === a) throw Error(C(267, a));\n var e = l({}, a.props),\n d = a.key,\n g = a.ref,\n k = a._owner;\n\n if (null != b) {\n void 0 !== b.ref && (g = b.ref, k = J.current);\n void 0 !== b.key && (d = \"\" + b.key);\n if (a.type && a.type.defaultProps) var f = a.type.defaultProps;\n\n for (h in b) {\n K.call(b, h) && !L.hasOwnProperty(h) && (e[h] = void 0 === b[h] && void 0 !== f ? f[h] : b[h]);\n }\n }\n\n var h = arguments.length - 2;\n if (1 === h) e.children = c;else if (1 < h) {\n f = Array(h);\n\n for (var m = 0; m < h; m++) {\n f[m] = arguments[m + 2];\n }\n\n e.children = f;\n }\n return {\n $$typeof: p,\n type: a.type,\n key: d,\n ref: g,\n props: e,\n _owner: k\n };\n};\n\nexports.createContext = function (a, b) {\n void 0 === b && (b = null);\n a = {\n $$typeof: w,\n _calculateChangedBits: b,\n _currentValue: a,\n _currentValue2: a,\n _threadCount: 0,\n Provider: null,\n Consumer: null\n };\n a.Provider = {\n $$typeof: v,\n _context: a\n };\n return a.Consumer = a;\n};\n\nexports.createElement = M;\n\nexports.createFactory = function (a) {\n var b = M.bind(null, a);\n b.type = a;\n return b;\n};\n\nexports.createRef = function () {\n return {\n current: null\n };\n};\n\nexports.forwardRef = function (a) {\n return {\n $$typeof: x,\n render: a\n };\n};\n\nexports.isValidElement = O;\n\nexports.lazy = function (a) {\n return {\n $$typeof: A,\n _ctor: a,\n _status: -1,\n _result: null\n };\n};\n\nexports.memo = function (a, b) {\n return {\n $$typeof: z,\n type: a,\n compare: void 0 === b ? null : b\n };\n};\n\nexports.useCallback = function (a, b) {\n return Z().useCallback(a, b);\n};\n\nexports.useContext = function (a, b) {\n return Z().useContext(a, b);\n};\n\nexports.useDebugValue = function () {};\n\nexports.useEffect = function (a, b) {\n return Z().useEffect(a, b);\n};\n\nexports.useImperativeHandle = function (a, b, c) {\n return Z().useImperativeHandle(a, b, c);\n};\n\nexports.useLayoutEffect = function (a, b) {\n return Z().useLayoutEffect(a, b);\n};\n\nexports.useMemo = function (a, b) {\n return Z().useMemo(a, b);\n};\n\nexports.useReducer = function (a, b, c) {\n return Z().useReducer(a, b, c);\n};\n\nexports.useRef = function (a) {\n return Z().useRef(a);\n};\n\nexports.useState = function (a) {\n return Z().useState(a);\n};\n\nexports.version = \"16.13.1\";","/** @license React v16.13.1\n * react-dom.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n/*\n Modernizr 3.0.0pre (Custom Build) | MIT\n*/\n'use strict';\n\nvar aa = require(\"react\"),\n n = require(\"object-assign\"),\n r = require(\"scheduler\");\n\nfunction u(a) {\n for (var b = \"https://reactjs.org/docs/error-decoder.html?invariant=\" + a, c = 1; c < arguments.length; c++) {\n b += \"&args[]=\" + encodeURIComponent(arguments[c]);\n }\n\n return \"Minified React error #\" + a + \"; visit \" + b + \" for the full message or use the non-minified dev environment for full errors and additional helpful warnings.\";\n}\n\nif (!aa) throw Error(u(227));\n\nfunction ba(a, b, c, d, e, f, g, h, k) {\n var l = Array.prototype.slice.call(arguments, 3);\n\n try {\n b.apply(c, l);\n } catch (m) {\n this.onError(m);\n }\n}\n\nvar da = !1,\n ea = null,\n fa = !1,\n ha = null,\n ia = {\n onError: function onError(a) {\n da = !0;\n ea = a;\n }\n};\n\nfunction ja(a, b, c, d, e, f, g, h, k) {\n da = !1;\n ea = null;\n ba.apply(ia, arguments);\n}\n\nfunction ka(a, b, c, d, e, f, g, h, k) {\n ja.apply(this, arguments);\n\n if (da) {\n if (da) {\n var l = ea;\n da = !1;\n ea = null;\n } else throw Error(u(198));\n\n fa || (fa = !0, ha = l);\n }\n}\n\nvar la = null,\n ma = null,\n na = null;\n\nfunction oa(a, b, c) {\n var d = a.type || \"unknown-event\";\n a.currentTarget = na(c);\n ka(d, b, void 0, a);\n a.currentTarget = null;\n}\n\nvar pa = null,\n qa = {};\n\nfunction ra() {\n if (pa) for (var a in qa) {\n var b = qa[a],\n c = pa.indexOf(a);\n if (!(-1 < c)) throw Error(u(96, a));\n\n if (!sa[c]) {\n if (!b.extractEvents) throw Error(u(97, a));\n sa[c] = b;\n c = b.eventTypes;\n\n for (var d in c) {\n var e = void 0;\n var f = c[d],\n g = b,\n h = d;\n if (ta.hasOwnProperty(h)) throw Error(u(99, h));\n ta[h] = f;\n var k = f.phasedRegistrationNames;\n\n if (k) {\n for (e in k) {\n k.hasOwnProperty(e) && ua(k[e], g, h);\n }\n\n e = !0;\n } else f.registrationName ? (ua(f.registrationName, g, h), e = !0) : e = !1;\n\n if (!e) throw Error(u(98, d, a));\n }\n }\n }\n}\n\nfunction ua(a, b, c) {\n if (va[a]) throw Error(u(100, a));\n va[a] = b;\n wa[a] = b.eventTypes[c].dependencies;\n}\n\nvar sa = [],\n ta = {},\n va = {},\n wa = {};\n\nfunction xa(a) {\n var b = !1,\n c;\n\n for (c in a) {\n if (a.hasOwnProperty(c)) {\n var d = a[c];\n\n if (!qa.hasOwnProperty(c) || qa[c] !== d) {\n if (qa[c]) throw Error(u(102, c));\n qa[c] = d;\n b = !0;\n }\n }\n }\n\n b && ra();\n}\n\nvar ya = !(\"undefined\" === typeof window || \"undefined\" === typeof window.document || \"undefined\" === typeof window.document.createElement),\n za = null,\n Aa = null,\n Ba = null;\n\nfunction Ca(a) {\n if (a = ma(a)) {\n if (\"function\" !== typeof za) throw Error(u(280));\n var b = a.stateNode;\n b && (b = la(b), za(a.stateNode, a.type, b));\n }\n}\n\nfunction Da(a) {\n Aa ? Ba ? Ba.push(a) : Ba = [a] : Aa = a;\n}\n\nfunction Ea() {\n if (Aa) {\n var a = Aa,\n b = Ba;\n Ba = Aa = null;\n Ca(a);\n if (b) for (a = 0; a < b.length; a++) {\n Ca(b[a]);\n }\n }\n}\n\nfunction Fa(a, b) {\n return a(b);\n}\n\nfunction Ga(a, b, c, d, e) {\n return a(b, c, d, e);\n}\n\nfunction Ha() {}\n\nvar Ia = Fa,\n Ja = !1,\n Ka = !1;\n\nfunction La() {\n if (null !== Aa || null !== Ba) Ha(), Ea();\n}\n\nfunction Ma(a, b, c) {\n if (Ka) return a(b, c);\n Ka = !0;\n\n try {\n return Ia(a, b, c);\n } finally {\n Ka = !1, La();\n }\n}\n\nvar Na = /^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$/,\n Oa = Object.prototype.hasOwnProperty,\n Pa = {},\n Qa = {};\n\nfunction Ra(a) {\n if (Oa.call(Qa, a)) return !0;\n if (Oa.call(Pa, a)) return !1;\n if (Na.test(a)) return Qa[a] = !0;\n Pa[a] = !0;\n return !1;\n}\n\nfunction Sa(a, b, c, d) {\n if (null !== c && 0 === c.type) return !1;\n\n switch (typeof b) {\n case \"function\":\n case \"symbol\":\n return !0;\n\n case \"boolean\":\n if (d) return !1;\n if (null !== c) return !c.acceptsBooleans;\n a = a.toLowerCase().slice(0, 5);\n return \"data-\" !== a && \"aria-\" !== a;\n\n default:\n return !1;\n }\n}\n\nfunction Ta(a, b, c, d) {\n if (null === b || \"undefined\" === typeof b || Sa(a, b, c, d)) return !0;\n if (d) return !1;\n if (null !== c) switch (c.type) {\n case 3:\n return !b;\n\n case 4:\n return !1 === b;\n\n case 5:\n return isNaN(b);\n\n case 6:\n return isNaN(b) || 1 > b;\n }\n return !1;\n}\n\nfunction v(a, b, c, d, e, f) {\n this.acceptsBooleans = 2 === b || 3 === b || 4 === b;\n this.attributeName = d;\n this.attributeNamespace = e;\n this.mustUseProperty = c;\n this.propertyName = a;\n this.type = b;\n this.sanitizeURL = f;\n}\n\nvar C = {};\n\"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style\".split(\" \").forEach(function (a) {\n C[a] = new v(a, 0, !1, a, null, !1);\n});\n[[\"acceptCharset\", \"accept-charset\"], [\"className\", \"class\"], [\"htmlFor\", \"for\"], [\"httpEquiv\", \"http-equiv\"]].forEach(function (a) {\n var b = a[0];\n C[b] = new v(b, 1, !1, a[1], null, !1);\n});\n[\"contentEditable\", \"draggable\", \"spellCheck\", \"value\"].forEach(function (a) {\n C[a] = new v(a, 2, !1, a.toLowerCase(), null, !1);\n});\n[\"autoReverse\", \"externalResourcesRequired\", \"focusable\", \"preserveAlpha\"].forEach(function (a) {\n C[a] = new v(a, 2, !1, a, null, !1);\n});\n\"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope\".split(\" \").forEach(function (a) {\n C[a] = new v(a, 3, !1, a.toLowerCase(), null, !1);\n});\n[\"checked\", \"multiple\", \"muted\", \"selected\"].forEach(function (a) {\n C[a] = new v(a, 3, !0, a, null, !1);\n});\n[\"capture\", \"download\"].forEach(function (a) {\n C[a] = new v(a, 4, !1, a, null, !1);\n});\n[\"cols\", \"rows\", \"size\", \"span\"].forEach(function (a) {\n C[a] = new v(a, 6, !1, a, null, !1);\n});\n[\"rowSpan\", \"start\"].forEach(function (a) {\n C[a] = new v(a, 5, !1, a.toLowerCase(), null, !1);\n});\nvar Ua = /[\\-:]([a-z])/g;\n\nfunction Va(a) {\n return a[1].toUpperCase();\n}\n\n\"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height\".split(\" \").forEach(function (a) {\n var b = a.replace(Ua, Va);\n C[b] = new v(b, 1, !1, a, null, !1);\n});\n\"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type\".split(\" \").forEach(function (a) {\n var b = a.replace(Ua, Va);\n C[b] = new v(b, 1, !1, a, \"http://www.w3.org/1999/xlink\", !1);\n});\n[\"xml:base\", \"xml:lang\", \"xml:space\"].forEach(function (a) {\n var b = a.replace(Ua, Va);\n C[b] = new v(b, 1, !1, a, \"http://www.w3.org/XML/1998/namespace\", !1);\n});\n[\"tabIndex\", \"crossOrigin\"].forEach(function (a) {\n C[a] = new v(a, 1, !1, a.toLowerCase(), null, !1);\n});\nC.xlinkHref = new v(\"xlinkHref\", 1, !1, \"xlink:href\", \"http://www.w3.org/1999/xlink\", !0);\n[\"src\", \"href\", \"action\", \"formAction\"].forEach(function (a) {\n C[a] = new v(a, 1, !1, a.toLowerCase(), null, !0);\n});\nvar Wa = aa.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;\nWa.hasOwnProperty(\"ReactCurrentDispatcher\") || (Wa.ReactCurrentDispatcher = {\n current: null\n});\nWa.hasOwnProperty(\"ReactCurrentBatchConfig\") || (Wa.ReactCurrentBatchConfig = {\n suspense: null\n});\n\nfunction Xa(a, b, c, d) {\n var e = C.hasOwnProperty(b) ? C[b] : null;\n var f = null !== e ? 0 === e.type : d ? !1 : !(2 < b.length) || \"o\" !== b[0] && \"O\" !== b[0] || \"n\" !== b[1] && \"N\" !== b[1] ? !1 : !0;\n f || (Ta(b, c, e, d) && (c = null), d || null === e ? Ra(b) && (null === c ? a.removeAttribute(b) : a.setAttribute(b, \"\" + c)) : e.mustUseProperty ? a[e.propertyName] = null === c ? 3 === e.type ? !1 : \"\" : c : (b = e.attributeName, d = e.attributeNamespace, null === c ? a.removeAttribute(b) : (e = e.type, c = 3 === e || 4 === e && !0 === c ? \"\" : \"\" + c, d ? a.setAttributeNS(d, b, c) : a.setAttribute(b, c))));\n}\n\nvar Ya = /^(.*)[\\\\\\/]/,\n E = \"function\" === typeof Symbol && Symbol.for,\n Za = E ? Symbol.for(\"react.element\") : 60103,\n $a = E ? Symbol.for(\"react.portal\") : 60106,\n ab = E ? Symbol.for(\"react.fragment\") : 60107,\n bb = E ? Symbol.for(\"react.strict_mode\") : 60108,\n cb = E ? Symbol.for(\"react.profiler\") : 60114,\n db = E ? Symbol.for(\"react.provider\") : 60109,\n eb = E ? Symbol.for(\"react.context\") : 60110,\n fb = E ? Symbol.for(\"react.concurrent_mode\") : 60111,\n gb = E ? Symbol.for(\"react.forward_ref\") : 60112,\n hb = E ? Symbol.for(\"react.suspense\") : 60113,\n ib = E ? Symbol.for(\"react.suspense_list\") : 60120,\n jb = E ? Symbol.for(\"react.memo\") : 60115,\n kb = E ? Symbol.for(\"react.lazy\") : 60116,\n lb = E ? Symbol.for(\"react.block\") : 60121,\n mb = \"function\" === typeof Symbol && Symbol.iterator;\n\nfunction nb(a) {\n if (null === a || \"object\" !== typeof a) return null;\n a = mb && a[mb] || a[\"@@iterator\"];\n return \"function\" === typeof a ? a : null;\n}\n\nfunction ob(a) {\n if (-1 === a._status) {\n a._status = 0;\n var b = a._ctor;\n b = b();\n a._result = b;\n b.then(function (b) {\n 0 === a._status && (b = b.default, a._status = 1, a._result = b);\n }, function (b) {\n 0 === a._status && (a._status = 2, a._result = b);\n });\n }\n}\n\nfunction pb(a) {\n if (null == a) return null;\n if (\"function\" === typeof a) return a.displayName || a.name || null;\n if (\"string\" === typeof a) return a;\n\n switch (a) {\n case ab:\n return \"Fragment\";\n\n case $a:\n return \"Portal\";\n\n case cb:\n return \"Profiler\";\n\n case bb:\n return \"StrictMode\";\n\n case hb:\n return \"Suspense\";\n\n case ib:\n return \"SuspenseList\";\n }\n\n if (\"object\" === typeof a) switch (a.$$typeof) {\n case eb:\n return \"Context.Consumer\";\n\n case db:\n return \"Context.Provider\";\n\n case gb:\n var b = a.render;\n b = b.displayName || b.name || \"\";\n return a.displayName || (\"\" !== b ? \"ForwardRef(\" + b + \")\" : \"ForwardRef\");\n\n case jb:\n return pb(a.type);\n\n case lb:\n return pb(a.render);\n\n case kb:\n if (a = 1 === a._status ? a._result : null) return pb(a);\n }\n return null;\n}\n\nfunction qb(a) {\n var b = \"\";\n\n do {\n a: switch (a.tag) {\n case 3:\n case 4:\n case 6:\n case 7:\n case 10:\n case 9:\n var c = \"\";\n break a;\n\n default:\n var d = a._debugOwner,\n e = a._debugSource,\n f = pb(a.type);\n c = null;\n d && (c = pb(d.type));\n d = f;\n f = \"\";\n e ? f = \" (at \" + e.fileName.replace(Ya, \"\") + \":\" + e.lineNumber + \")\" : c && (f = \" (created by \" + c + \")\");\n c = \"\\n in \" + (d || \"Unknown\") + f;\n }\n\n b += c;\n a = a.return;\n } while (a);\n\n return b;\n}\n\nfunction rb(a) {\n switch (typeof a) {\n case \"boolean\":\n case \"number\":\n case \"object\":\n case \"string\":\n case \"undefined\":\n return a;\n\n default:\n return \"\";\n }\n}\n\nfunction sb(a) {\n var b = a.type;\n return (a = a.nodeName) && \"input\" === a.toLowerCase() && (\"checkbox\" === b || \"radio\" === b);\n}\n\nfunction tb(a) {\n var b = sb(a) ? \"checked\" : \"value\",\n c = Object.getOwnPropertyDescriptor(a.constructor.prototype, b),\n d = \"\" + a[b];\n\n if (!a.hasOwnProperty(b) && \"undefined\" !== typeof c && \"function\" === typeof c.get && \"function\" === typeof c.set) {\n var e = c.get,\n f = c.set;\n Object.defineProperty(a, b, {\n configurable: !0,\n get: function get() {\n return e.call(this);\n },\n set: function set(a) {\n d = \"\" + a;\n f.call(this, a);\n }\n });\n Object.defineProperty(a, b, {\n enumerable: c.enumerable\n });\n return {\n getValue: function getValue() {\n return d;\n },\n setValue: function setValue(a) {\n d = \"\" + a;\n },\n stopTracking: function stopTracking() {\n a._valueTracker = null;\n delete a[b];\n }\n };\n }\n}\n\nfunction xb(a) {\n a._valueTracker || (a._valueTracker = tb(a));\n}\n\nfunction yb(a) {\n if (!a) return !1;\n var b = a._valueTracker;\n if (!b) return !0;\n var c = b.getValue();\n var d = \"\";\n a && (d = sb(a) ? a.checked ? \"true\" : \"false\" : a.value);\n a = d;\n return a !== c ? (b.setValue(a), !0) : !1;\n}\n\nfunction zb(a, b) {\n var c = b.checked;\n return n({}, b, {\n defaultChecked: void 0,\n defaultValue: void 0,\n value: void 0,\n checked: null != c ? c : a._wrapperState.initialChecked\n });\n}\n\nfunction Ab(a, b) {\n var c = null == b.defaultValue ? \"\" : b.defaultValue,\n d = null != b.checked ? b.checked : b.defaultChecked;\n c = rb(null != b.value ? b.value : c);\n a._wrapperState = {\n initialChecked: d,\n initialValue: c,\n controlled: \"checkbox\" === b.type || \"radio\" === b.type ? null != b.checked : null != b.value\n };\n}\n\nfunction Bb(a, b) {\n b = b.checked;\n null != b && Xa(a, \"checked\", b, !1);\n}\n\nfunction Cb(a, b) {\n Bb(a, b);\n var c = rb(b.value),\n d = b.type;\n if (null != c) {\n if (\"number\" === d) {\n if (0 === c && \"\" === a.value || a.value != c) a.value = \"\" + c;\n } else a.value !== \"\" + c && (a.value = \"\" + c);\n } else if (\"submit\" === d || \"reset\" === d) {\n a.removeAttribute(\"value\");\n return;\n }\n b.hasOwnProperty(\"value\") ? Db(a, b.type, c) : b.hasOwnProperty(\"defaultValue\") && Db(a, b.type, rb(b.defaultValue));\n null == b.checked && null != b.defaultChecked && (a.defaultChecked = !!b.defaultChecked);\n}\n\nfunction Eb(a, b, c) {\n if (b.hasOwnProperty(\"value\") || b.hasOwnProperty(\"defaultValue\")) {\n var d = b.type;\n if (!(\"submit\" !== d && \"reset\" !== d || void 0 !== b.value && null !== b.value)) return;\n b = \"\" + a._wrapperState.initialValue;\n c || b === a.value || (a.value = b);\n a.defaultValue = b;\n }\n\n c = a.name;\n \"\" !== c && (a.name = \"\");\n a.defaultChecked = !!a._wrapperState.initialChecked;\n \"\" !== c && (a.name = c);\n}\n\nfunction Db(a, b, c) {\n if (\"number\" !== b || a.ownerDocument.activeElement !== a) null == c ? a.defaultValue = \"\" + a._wrapperState.initialValue : a.defaultValue !== \"\" + c && (a.defaultValue = \"\" + c);\n}\n\nfunction Fb(a) {\n var b = \"\";\n aa.Children.forEach(a, function (a) {\n null != a && (b += a);\n });\n return b;\n}\n\nfunction Gb(a, b) {\n a = n({\n children: void 0\n }, b);\n if (b = Fb(b.children)) a.children = b;\n return a;\n}\n\nfunction Hb(a, b, c, d) {\n a = a.options;\n\n if (b) {\n b = {};\n\n for (var e = 0; e < c.length; e++) {\n b[\"$\" + c[e]] = !0;\n }\n\n for (c = 0; c < a.length; c++) {\n e = b.hasOwnProperty(\"$\" + a[c].value), a[c].selected !== e && (a[c].selected = e), e && d && (a[c].defaultSelected = !0);\n }\n } else {\n c = \"\" + rb(c);\n b = null;\n\n for (e = 0; e < a.length; e++) {\n if (a[e].value === c) {\n a[e].selected = !0;\n d && (a[e].defaultSelected = !0);\n return;\n }\n\n null !== b || a[e].disabled || (b = a[e]);\n }\n\n null !== b && (b.selected = !0);\n }\n}\n\nfunction Ib(a, b) {\n if (null != b.dangerouslySetInnerHTML) throw Error(u(91));\n return n({}, b, {\n value: void 0,\n defaultValue: void 0,\n children: \"\" + a._wrapperState.initialValue\n });\n}\n\nfunction Jb(a, b) {\n var c = b.value;\n\n if (null == c) {\n c = b.children;\n b = b.defaultValue;\n\n if (null != c) {\n if (null != b) throw Error(u(92));\n\n if (Array.isArray(c)) {\n if (!(1 >= c.length)) throw Error(u(93));\n c = c[0];\n }\n\n b = c;\n }\n\n null == b && (b = \"\");\n c = b;\n }\n\n a._wrapperState = {\n initialValue: rb(c)\n };\n}\n\nfunction Kb(a, b) {\n var c = rb(b.value),\n d = rb(b.defaultValue);\n null != c && (c = \"\" + c, c !== a.value && (a.value = c), null == b.defaultValue && a.defaultValue !== c && (a.defaultValue = c));\n null != d && (a.defaultValue = \"\" + d);\n}\n\nfunction Lb(a) {\n var b = a.textContent;\n b === a._wrapperState.initialValue && \"\" !== b && null !== b && (a.value = b);\n}\n\nvar Mb = {\n html: \"http://www.w3.org/1999/xhtml\",\n mathml: \"http://www.w3.org/1998/Math/MathML\",\n svg: \"http://www.w3.org/2000/svg\"\n};\n\nfunction Nb(a) {\n switch (a) {\n case \"svg\":\n return \"http://www.w3.org/2000/svg\";\n\n case \"math\":\n return \"http://www.w3.org/1998/Math/MathML\";\n\n default:\n return \"http://www.w3.org/1999/xhtml\";\n }\n}\n\nfunction Ob(a, b) {\n return null == a || \"http://www.w3.org/1999/xhtml\" === a ? Nb(b) : \"http://www.w3.org/2000/svg\" === a && \"foreignObject\" === b ? \"http://www.w3.org/1999/xhtml\" : a;\n}\n\nvar Pb,\n Qb = function (a) {\n return \"undefined\" !== typeof MSApp && MSApp.execUnsafeLocalFunction ? function (b, c, d, e) {\n MSApp.execUnsafeLocalFunction(function () {\n return a(b, c, d, e);\n });\n } : a;\n}(function (a, b) {\n if (a.namespaceURI !== Mb.svg || \"innerHTML\" in a) a.innerHTML = b;else {\n Pb = Pb || document.createElement(\"div\");\n Pb.innerHTML = \"\";\n\n for (b = Pb.firstChild; a.firstChild;) {\n a.removeChild(a.firstChild);\n }\n\n for (; b.firstChild;) {\n a.appendChild(b.firstChild);\n }\n }\n});\n\nfunction Rb(a, b) {\n if (b) {\n var c = a.firstChild;\n\n if (c && c === a.lastChild && 3 === c.nodeType) {\n c.nodeValue = b;\n return;\n }\n }\n\n a.textContent = b;\n}\n\nfunction Sb(a, b) {\n var c = {};\n c[a.toLowerCase()] = b.toLowerCase();\n c[\"Webkit\" + a] = \"webkit\" + b;\n c[\"Moz\" + a] = \"moz\" + b;\n return c;\n}\n\nvar Tb = {\n animationend: Sb(\"Animation\", \"AnimationEnd\"),\n animationiteration: Sb(\"Animation\", \"AnimationIteration\"),\n animationstart: Sb(\"Animation\", \"AnimationStart\"),\n transitionend: Sb(\"Transition\", \"TransitionEnd\")\n},\n Ub = {},\n Vb = {};\nya && (Vb = document.createElement(\"div\").style, \"AnimationEvent\" in window || (delete Tb.animationend.animation, delete Tb.animationiteration.animation, delete Tb.animationstart.animation), \"TransitionEvent\" in window || delete Tb.transitionend.transition);\n\nfunction Wb(a) {\n if (Ub[a]) return Ub[a];\n if (!Tb[a]) return a;\n var b = Tb[a],\n c;\n\n for (c in b) {\n if (b.hasOwnProperty(c) && c in Vb) return Ub[a] = b[c];\n }\n\n return a;\n}\n\nvar Xb = Wb(\"animationend\"),\n Yb = Wb(\"animationiteration\"),\n Zb = Wb(\"animationstart\"),\n $b = Wb(\"transitionend\"),\n ac = \"abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting\".split(\" \"),\n bc = new (\"function\" === typeof WeakMap ? WeakMap : Map)();\n\nfunction cc(a) {\n var b = bc.get(a);\n void 0 === b && (b = new Map(), bc.set(a, b));\n return b;\n}\n\nfunction dc(a) {\n var b = a,\n c = a;\n if (a.alternate) for (; b.return;) {\n b = b.return;\n } else {\n a = b;\n\n do {\n b = a, 0 !== (b.effectTag & 1026) && (c = b.return), a = b.return;\n } while (a);\n }\n return 3 === b.tag ? c : null;\n}\n\nfunction ec(a) {\n if (13 === a.tag) {\n var b = a.memoizedState;\n null === b && (a = a.alternate, null !== a && (b = a.memoizedState));\n if (null !== b) return b.dehydrated;\n }\n\n return null;\n}\n\nfunction fc(a) {\n if (dc(a) !== a) throw Error(u(188));\n}\n\nfunction gc(a) {\n var b = a.alternate;\n\n if (!b) {\n b = dc(a);\n if (null === b) throw Error(u(188));\n return b !== a ? null : a;\n }\n\n for (var c = a, d = b;;) {\n var e = c.return;\n if (null === e) break;\n var f = e.alternate;\n\n if (null === f) {\n d = e.return;\n\n if (null !== d) {\n c = d;\n continue;\n }\n\n break;\n }\n\n if (e.child === f.child) {\n for (f = e.child; f;) {\n if (f === c) return fc(e), a;\n if (f === d) return fc(e), b;\n f = f.sibling;\n }\n\n throw Error(u(188));\n }\n\n if (c.return !== d.return) c = e, d = f;else {\n for (var g = !1, h = e.child; h;) {\n if (h === c) {\n g = !0;\n c = e;\n d = f;\n break;\n }\n\n if (h === d) {\n g = !0;\n d = e;\n c = f;\n break;\n }\n\n h = h.sibling;\n }\n\n if (!g) {\n for (h = f.child; h;) {\n if (h === c) {\n g = !0;\n c = f;\n d = e;\n break;\n }\n\n if (h === d) {\n g = !0;\n d = f;\n c = e;\n break;\n }\n\n h = h.sibling;\n }\n\n if (!g) throw Error(u(189));\n }\n }\n if (c.alternate !== d) throw Error(u(190));\n }\n\n if (3 !== c.tag) throw Error(u(188));\n return c.stateNode.current === c ? a : b;\n}\n\nfunction hc(a) {\n a = gc(a);\n if (!a) return null;\n\n for (var b = a;;) {\n if (5 === b.tag || 6 === b.tag) return b;\n if (b.child) b.child.return = b, b = b.child;else {\n if (b === a) break;\n\n for (; !b.sibling;) {\n if (!b.return || b.return === a) return null;\n b = b.return;\n }\n\n b.sibling.return = b.return;\n b = b.sibling;\n }\n }\n\n return null;\n}\n\nfunction ic(a, b) {\n if (null == b) throw Error(u(30));\n if (null == a) return b;\n\n if (Array.isArray(a)) {\n if (Array.isArray(b)) return a.push.apply(a, b), a;\n a.push(b);\n return a;\n }\n\n return Array.isArray(b) ? [a].concat(b) : [a, b];\n}\n\nfunction jc(a, b, c) {\n Array.isArray(a) ? a.forEach(b, c) : a && b.call(c, a);\n}\n\nvar kc = null;\n\nfunction lc(a) {\n if (a) {\n var b = a._dispatchListeners,\n c = a._dispatchInstances;\n if (Array.isArray(b)) for (var d = 0; d < b.length && !a.isPropagationStopped(); d++) {\n oa(a, b[d], c[d]);\n } else b && oa(a, b, c);\n a._dispatchListeners = null;\n a._dispatchInstances = null;\n a.isPersistent() || a.constructor.release(a);\n }\n}\n\nfunction mc(a) {\n null !== a && (kc = ic(kc, a));\n a = kc;\n kc = null;\n\n if (a) {\n jc(a, lc);\n if (kc) throw Error(u(95));\n if (fa) throw a = ha, fa = !1, ha = null, a;\n }\n}\n\nfunction nc(a) {\n a = a.target || a.srcElement || window;\n a.correspondingUseElement && (a = a.correspondingUseElement);\n return 3 === a.nodeType ? a.parentNode : a;\n}\n\nfunction oc(a) {\n if (!ya) return !1;\n a = \"on\" + a;\n var b = a in document;\n b || (b = document.createElement(\"div\"), b.setAttribute(a, \"return;\"), b = \"function\" === typeof b[a]);\n return b;\n}\n\nvar pc = [];\n\nfunction qc(a) {\n a.topLevelType = null;\n a.nativeEvent = null;\n a.targetInst = null;\n a.ancestors.length = 0;\n 10 > pc.length && pc.push(a);\n}\n\nfunction rc(a, b, c, d) {\n if (pc.length) {\n var e = pc.pop();\n e.topLevelType = a;\n e.eventSystemFlags = d;\n e.nativeEvent = b;\n e.targetInst = c;\n return e;\n }\n\n return {\n topLevelType: a,\n eventSystemFlags: d,\n nativeEvent: b,\n targetInst: c,\n ancestors: []\n };\n}\n\nfunction sc(a) {\n var b = a.targetInst,\n c = b;\n\n do {\n if (!c) {\n a.ancestors.push(c);\n break;\n }\n\n var d = c;\n if (3 === d.tag) d = d.stateNode.containerInfo;else {\n for (; d.return;) {\n d = d.return;\n }\n\n d = 3 !== d.tag ? null : d.stateNode.containerInfo;\n }\n if (!d) break;\n b = c.tag;\n 5 !== b && 6 !== b || a.ancestors.push(c);\n c = tc(d);\n } while (c);\n\n for (c = 0; c < a.ancestors.length; c++) {\n b = a.ancestors[c];\n var e = nc(a.nativeEvent);\n d = a.topLevelType;\n var f = a.nativeEvent,\n g = a.eventSystemFlags;\n 0 === c && (g |= 64);\n\n for (var h = null, k = 0; k < sa.length; k++) {\n var l = sa[k];\n l && (l = l.extractEvents(d, b, f, e, g)) && (h = ic(h, l));\n }\n\n mc(h);\n }\n}\n\nfunction uc(a, b, c) {\n if (!c.has(a)) {\n switch (a) {\n case \"scroll\":\n vc(b, \"scroll\", !0);\n break;\n\n case \"focus\":\n case \"blur\":\n vc(b, \"focus\", !0);\n vc(b, \"blur\", !0);\n c.set(\"blur\", null);\n c.set(\"focus\", null);\n break;\n\n case \"cancel\":\n case \"close\":\n oc(a) && vc(b, a, !0);\n break;\n\n case \"invalid\":\n case \"submit\":\n case \"reset\":\n break;\n\n default:\n -1 === ac.indexOf(a) && F(a, b);\n }\n\n c.set(a, null);\n }\n}\n\nvar wc,\n xc,\n yc,\n zc = !1,\n Ac = [],\n Bc = null,\n Cc = null,\n Dc = null,\n Ec = new Map(),\n Fc = new Map(),\n Gc = [],\n Hc = \"mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput close cancel copy cut paste click change contextmenu reset submit\".split(\" \"),\n Ic = \"focus blur dragenter dragleave mouseover mouseout pointerover pointerout gotpointercapture lostpointercapture\".split(\" \");\n\nfunction Jc(a, b) {\n var c = cc(b);\n Hc.forEach(function (a) {\n uc(a, b, c);\n });\n Ic.forEach(function (a) {\n uc(a, b, c);\n });\n}\n\nfunction Kc(a, b, c, d, e) {\n return {\n blockedOn: a,\n topLevelType: b,\n eventSystemFlags: c | 32,\n nativeEvent: e,\n container: d\n };\n}\n\nfunction Lc(a, b) {\n switch (a) {\n case \"focus\":\n case \"blur\":\n Bc = null;\n break;\n\n case \"dragenter\":\n case \"dragleave\":\n Cc = null;\n break;\n\n case \"mouseover\":\n case \"mouseout\":\n Dc = null;\n break;\n\n case \"pointerover\":\n case \"pointerout\":\n Ec.delete(b.pointerId);\n break;\n\n case \"gotpointercapture\":\n case \"lostpointercapture\":\n Fc.delete(b.pointerId);\n }\n}\n\nfunction Mc(a, b, c, d, e, f) {\n if (null === a || a.nativeEvent !== f) return a = Kc(b, c, d, e, f), null !== b && (b = Nc(b), null !== b && xc(b)), a;\n a.eventSystemFlags |= d;\n return a;\n}\n\nfunction Oc(a, b, c, d, e) {\n switch (b) {\n case \"focus\":\n return Bc = Mc(Bc, a, b, c, d, e), !0;\n\n case \"dragenter\":\n return Cc = Mc(Cc, a, b, c, d, e), !0;\n\n case \"mouseover\":\n return Dc = Mc(Dc, a, b, c, d, e), !0;\n\n case \"pointerover\":\n var f = e.pointerId;\n Ec.set(f, Mc(Ec.get(f) || null, a, b, c, d, e));\n return !0;\n\n case \"gotpointercapture\":\n return f = e.pointerId, Fc.set(f, Mc(Fc.get(f) || null, a, b, c, d, e)), !0;\n }\n\n return !1;\n}\n\nfunction Pc(a) {\n var b = tc(a.target);\n\n if (null !== b) {\n var c = dc(b);\n if (null !== c) if (b = c.tag, 13 === b) {\n if (b = ec(c), null !== b) {\n a.blockedOn = b;\n r.unstable_runWithPriority(a.priority, function () {\n yc(c);\n });\n return;\n }\n } else if (3 === b && c.stateNode.hydrate) {\n a.blockedOn = 3 === c.tag ? c.stateNode.containerInfo : null;\n return;\n }\n }\n\n a.blockedOn = null;\n}\n\nfunction Qc(a) {\n if (null !== a.blockedOn) return !1;\n var b = Rc(a.topLevelType, a.eventSystemFlags, a.container, a.nativeEvent);\n\n if (null !== b) {\n var c = Nc(b);\n null !== c && xc(c);\n a.blockedOn = b;\n return !1;\n }\n\n return !0;\n}\n\nfunction Sc(a, b, c) {\n Qc(a) && c.delete(b);\n}\n\nfunction Tc() {\n for (zc = !1; 0 < Ac.length;) {\n var a = Ac[0];\n\n if (null !== a.blockedOn) {\n a = Nc(a.blockedOn);\n null !== a && wc(a);\n break;\n }\n\n var b = Rc(a.topLevelType, a.eventSystemFlags, a.container, a.nativeEvent);\n null !== b ? a.blockedOn = b : Ac.shift();\n }\n\n null !== Bc && Qc(Bc) && (Bc = null);\n null !== Cc && Qc(Cc) && (Cc = null);\n null !== Dc && Qc(Dc) && (Dc = null);\n Ec.forEach(Sc);\n Fc.forEach(Sc);\n}\n\nfunction Uc(a, b) {\n a.blockedOn === b && (a.blockedOn = null, zc || (zc = !0, r.unstable_scheduleCallback(r.unstable_NormalPriority, Tc)));\n}\n\nfunction Vc(a) {\n function b(b) {\n return Uc(b, a);\n }\n\n if (0 < Ac.length) {\n Uc(Ac[0], a);\n\n for (var c = 1; c < Ac.length; c++) {\n var d = Ac[c];\n d.blockedOn === a && (d.blockedOn = null);\n }\n }\n\n null !== Bc && Uc(Bc, a);\n null !== Cc && Uc(Cc, a);\n null !== Dc && Uc(Dc, a);\n Ec.forEach(b);\n Fc.forEach(b);\n\n for (c = 0; c < Gc.length; c++) {\n d = Gc[c], d.blockedOn === a && (d.blockedOn = null);\n }\n\n for (; 0 < Gc.length && (c = Gc[0], null === c.blockedOn);) {\n Pc(c), null === c.blockedOn && Gc.shift();\n }\n}\n\nvar Wc = {},\n Yc = new Map(),\n Zc = new Map(),\n $c = [\"abort\", \"abort\", Xb, \"animationEnd\", Yb, \"animationIteration\", Zb, \"animationStart\", \"canplay\", \"canPlay\", \"canplaythrough\", \"canPlayThrough\", \"durationchange\", \"durationChange\", \"emptied\", \"emptied\", \"encrypted\", \"encrypted\", \"ended\", \"ended\", \"error\", \"error\", \"gotpointercapture\", \"gotPointerCapture\", \"load\", \"load\", \"loadeddata\", \"loadedData\", \"loadedmetadata\", \"loadedMetadata\", \"loadstart\", \"loadStart\", \"lostpointercapture\", \"lostPointerCapture\", \"playing\", \"playing\", \"progress\", \"progress\", \"seeking\", \"seeking\", \"stalled\", \"stalled\", \"suspend\", \"suspend\", \"timeupdate\", \"timeUpdate\", $b, \"transitionEnd\", \"waiting\", \"waiting\"];\n\nfunction ad(a, b) {\n for (var c = 0; c < a.length; c += 2) {\n var d = a[c],\n e = a[c + 1],\n f = \"on\" + (e[0].toUpperCase() + e.slice(1));\n f = {\n phasedRegistrationNames: {\n bubbled: f,\n captured: f + \"Capture\"\n },\n dependencies: [d],\n eventPriority: b\n };\n Zc.set(d, b);\n Yc.set(d, f);\n Wc[e] = f;\n }\n}\n\nad(\"blur blur cancel cancel click click close close contextmenu contextMenu copy copy cut cut auxclick auxClick dblclick doubleClick dragend dragEnd dragstart dragStart drop drop focus focus input input invalid invalid keydown keyDown keypress keyPress keyup keyUp mousedown mouseDown mouseup mouseUp paste paste pause pause play play pointercancel pointerCancel pointerdown pointerDown pointerup pointerUp ratechange rateChange reset reset seeked seeked submit submit touchcancel touchCancel touchend touchEnd touchstart touchStart volumechange volumeChange\".split(\" \"), 0);\nad(\"drag drag dragenter dragEnter dragexit dragExit dragleave dragLeave dragover dragOver mousemove mouseMove mouseout mouseOut mouseover mouseOver pointermove pointerMove pointerout pointerOut pointerover pointerOver scroll scroll toggle toggle touchmove touchMove wheel wheel\".split(\" \"), 1);\nad($c, 2);\n\nfor (var bd = \"change selectionchange textInput compositionstart compositionend compositionupdate\".split(\" \"), cd = 0; cd < bd.length; cd++) {\n Zc.set(bd[cd], 0);\n}\n\nvar dd = r.unstable_UserBlockingPriority,\n ed = r.unstable_runWithPriority,\n fd = !0;\n\nfunction F(a, b) {\n vc(b, a, !1);\n}\n\nfunction vc(a, b, c) {\n var d = Zc.get(b);\n\n switch (void 0 === d ? 2 : d) {\n case 0:\n d = gd.bind(null, b, 1, a);\n break;\n\n case 1:\n d = hd.bind(null, b, 1, a);\n break;\n\n default:\n d = id.bind(null, b, 1, a);\n }\n\n c ? a.addEventListener(b, d, !0) : a.addEventListener(b, d, !1);\n}\n\nfunction gd(a, b, c, d) {\n Ja || Ha();\n var e = id,\n f = Ja;\n Ja = !0;\n\n try {\n Ga(e, a, b, c, d);\n } finally {\n (Ja = f) || La();\n }\n}\n\nfunction hd(a, b, c, d) {\n ed(dd, id.bind(null, a, b, c, d));\n}\n\nfunction id(a, b, c, d) {\n if (fd) if (0 < Ac.length && -1 < Hc.indexOf(a)) a = Kc(null, a, b, c, d), Ac.push(a);else {\n var e = Rc(a, b, c, d);\n if (null === e) Lc(a, d);else if (-1 < Hc.indexOf(a)) a = Kc(e, a, b, c, d), Ac.push(a);else if (!Oc(e, a, b, c, d)) {\n Lc(a, d);\n a = rc(a, d, null, b);\n\n try {\n Ma(sc, a);\n } finally {\n qc(a);\n }\n }\n }\n}\n\nfunction Rc(a, b, c, d) {\n c = nc(d);\n c = tc(c);\n\n if (null !== c) {\n var e = dc(c);\n if (null === e) c = null;else {\n var f = e.tag;\n\n if (13 === f) {\n c = ec(e);\n if (null !== c) return c;\n c = null;\n } else if (3 === f) {\n if (e.stateNode.hydrate) return 3 === e.tag ? e.stateNode.containerInfo : null;\n c = null;\n } else e !== c && (c = null);\n }\n }\n\n a = rc(a, d, c, b);\n\n try {\n Ma(sc, a);\n } finally {\n qc(a);\n }\n\n return null;\n}\n\nvar jd = {\n animationIterationCount: !0,\n borderImageOutset: !0,\n borderImageSlice: !0,\n borderImageWidth: !0,\n boxFlex: !0,\n boxFlexGroup: !0,\n boxOrdinalGroup: !0,\n columnCount: !0,\n columns: !0,\n flex: !0,\n flexGrow: !0,\n flexPositive: !0,\n flexShrink: !0,\n flexNegative: !0,\n flexOrder: !0,\n gridArea: !0,\n gridRow: !0,\n gridRowEnd: !0,\n gridRowSpan: !0,\n gridRowStart: !0,\n gridColumn: !0,\n gridColumnEnd: !0,\n gridColumnSpan: !0,\n gridColumnStart: !0,\n fontWeight: !0,\n lineClamp: !0,\n lineHeight: !0,\n opacity: !0,\n order: !0,\n orphans: !0,\n tabSize: !0,\n widows: !0,\n zIndex: !0,\n zoom: !0,\n fillOpacity: !0,\n floodOpacity: !0,\n stopOpacity: !0,\n strokeDasharray: !0,\n strokeDashoffset: !0,\n strokeMiterlimit: !0,\n strokeOpacity: !0,\n strokeWidth: !0\n},\n kd = [\"Webkit\", \"ms\", \"Moz\", \"O\"];\nObject.keys(jd).forEach(function (a) {\n kd.forEach(function (b) {\n b = b + a.charAt(0).toUpperCase() + a.substring(1);\n jd[b] = jd[a];\n });\n});\n\nfunction ld(a, b, c) {\n return null == b || \"boolean\" === typeof b || \"\" === b ? \"\" : c || \"number\" !== typeof b || 0 === b || jd.hasOwnProperty(a) && jd[a] ? (\"\" + b).trim() : b + \"px\";\n}\n\nfunction md(a, b) {\n a = a.style;\n\n for (var c in b) {\n if (b.hasOwnProperty(c)) {\n var d = 0 === c.indexOf(\"--\"),\n e = ld(c, b[c], d);\n \"float\" === c && (c = \"cssFloat\");\n d ? a.setProperty(c, e) : a[c] = e;\n }\n }\n}\n\nvar nd = n({\n menuitem: !0\n}, {\n area: !0,\n base: !0,\n br: !0,\n col: !0,\n embed: !0,\n hr: !0,\n img: !0,\n input: !0,\n keygen: !0,\n link: !0,\n meta: !0,\n param: !0,\n source: !0,\n track: !0,\n wbr: !0\n});\n\nfunction od(a, b) {\n if (b) {\n if (nd[a] && (null != b.children || null != b.dangerouslySetInnerHTML)) throw Error(u(137, a, \"\"));\n\n if (null != b.dangerouslySetInnerHTML) {\n if (null != b.children) throw Error(u(60));\n if (!(\"object\" === typeof b.dangerouslySetInnerHTML && \"__html\" in b.dangerouslySetInnerHTML)) throw Error(u(61));\n }\n\n if (null != b.style && \"object\" !== typeof b.style) throw Error(u(62, \"\"));\n }\n}\n\nfunction pd(a, b) {\n if (-1 === a.indexOf(\"-\")) return \"string\" === typeof b.is;\n\n switch (a) {\n case \"annotation-xml\":\n case \"color-profile\":\n case \"font-face\":\n case \"font-face-src\":\n case \"font-face-uri\":\n case \"font-face-format\":\n case \"font-face-name\":\n case \"missing-glyph\":\n return !1;\n\n default:\n return !0;\n }\n}\n\nvar qd = Mb.html;\n\nfunction rd(a, b) {\n a = 9 === a.nodeType || 11 === a.nodeType ? a : a.ownerDocument;\n var c = cc(a);\n b = wa[b];\n\n for (var d = 0; d < b.length; d++) {\n uc(b[d], a, c);\n }\n}\n\nfunction sd() {}\n\nfunction td(a) {\n a = a || (\"undefined\" !== typeof document ? document : void 0);\n if (\"undefined\" === typeof a) return null;\n\n try {\n return a.activeElement || a.body;\n } catch (b) {\n return a.body;\n }\n}\n\nfunction ud(a) {\n for (; a && a.firstChild;) {\n a = a.firstChild;\n }\n\n return a;\n}\n\nfunction vd(a, b) {\n var c = ud(a);\n a = 0;\n\n for (var d; c;) {\n if (3 === c.nodeType) {\n d = a + c.textContent.length;\n if (a <= b && d >= b) return {\n node: c,\n offset: b - a\n };\n a = d;\n }\n\n a: {\n for (; c;) {\n if (c.nextSibling) {\n c = c.nextSibling;\n break a;\n }\n\n c = c.parentNode;\n }\n\n c = void 0;\n }\n\n c = ud(c);\n }\n}\n\nfunction wd(a, b) {\n return a && b ? a === b ? !0 : a && 3 === a.nodeType ? !1 : b && 3 === b.nodeType ? wd(a, b.parentNode) : \"contains\" in a ? a.contains(b) : a.compareDocumentPosition ? !!(a.compareDocumentPosition(b) & 16) : !1 : !1;\n}\n\nfunction xd() {\n for (var a = window, b = td(); b instanceof a.HTMLIFrameElement;) {\n try {\n var c = \"string\" === typeof b.contentWindow.location.href;\n } catch (d) {\n c = !1;\n }\n\n if (c) a = b.contentWindow;else break;\n b = td(a.document);\n }\n\n return b;\n}\n\nfunction yd(a) {\n var b = a && a.nodeName && a.nodeName.toLowerCase();\n return b && (\"input\" === b && (\"text\" === a.type || \"search\" === a.type || \"tel\" === a.type || \"url\" === a.type || \"password\" === a.type) || \"textarea\" === b || \"true\" === a.contentEditable);\n}\n\nvar zd = \"$\",\n Ad = \"/$\",\n Bd = \"$?\",\n Cd = \"$!\",\n Dd = null,\n Ed = null;\n\nfunction Fd(a, b) {\n switch (a) {\n case \"button\":\n case \"input\":\n case \"select\":\n case \"textarea\":\n return !!b.autoFocus;\n }\n\n return !1;\n}\n\nfunction Gd(a, b) {\n return \"textarea\" === a || \"option\" === a || \"noscript\" === a || \"string\" === typeof b.children || \"number\" === typeof b.children || \"object\" === typeof b.dangerouslySetInnerHTML && null !== b.dangerouslySetInnerHTML && null != b.dangerouslySetInnerHTML.__html;\n}\n\nvar Hd = \"function\" === typeof setTimeout ? setTimeout : void 0,\n Id = \"function\" === typeof clearTimeout ? clearTimeout : void 0;\n\nfunction Jd(a) {\n for (; null != a; a = a.nextSibling) {\n var b = a.nodeType;\n if (1 === b || 3 === b) break;\n }\n\n return a;\n}\n\nfunction Kd(a) {\n a = a.previousSibling;\n\n for (var b = 0; a;) {\n if (8 === a.nodeType) {\n var c = a.data;\n\n if (c === zd || c === Cd || c === Bd) {\n if (0 === b) return a;\n b--;\n } else c === Ad && b++;\n }\n\n a = a.previousSibling;\n }\n\n return null;\n}\n\nvar Ld = Math.random().toString(36).slice(2),\n Md = \"__reactInternalInstance$\" + Ld,\n Nd = \"__reactEventHandlers$\" + Ld,\n Od = \"__reactContainere$\" + Ld;\n\nfunction tc(a) {\n var b = a[Md];\n if (b) return b;\n\n for (var c = a.parentNode; c;) {\n if (b = c[Od] || c[Md]) {\n c = b.alternate;\n if (null !== b.child || null !== c && null !== c.child) for (a = Kd(a); null !== a;) {\n if (c = a[Md]) return c;\n a = Kd(a);\n }\n return b;\n }\n\n a = c;\n c = a.parentNode;\n }\n\n return null;\n}\n\nfunction Nc(a) {\n a = a[Md] || a[Od];\n return !a || 5 !== a.tag && 6 !== a.tag && 13 !== a.tag && 3 !== a.tag ? null : a;\n}\n\nfunction Pd(a) {\n if (5 === a.tag || 6 === a.tag) return a.stateNode;\n throw Error(u(33));\n}\n\nfunction Qd(a) {\n return a[Nd] || null;\n}\n\nfunction Rd(a) {\n do {\n a = a.return;\n } while (a && 5 !== a.tag);\n\n return a ? a : null;\n}\n\nfunction Sd(a, b) {\n var c = a.stateNode;\n if (!c) return null;\n var d = la(c);\n if (!d) return null;\n c = d[b];\n\n a: switch (b) {\n case \"onClick\":\n case \"onClickCapture\":\n case \"onDoubleClick\":\n case \"onDoubleClickCapture\":\n case \"onMouseDown\":\n case \"onMouseDownCapture\":\n case \"onMouseMove\":\n case \"onMouseMoveCapture\":\n case \"onMouseUp\":\n case \"onMouseUpCapture\":\n case \"onMouseEnter\":\n (d = !d.disabled) || (a = a.type, d = !(\"button\" === a || \"input\" === a || \"select\" === a || \"textarea\" === a));\n a = !d;\n break a;\n\n default:\n a = !1;\n }\n\n if (a) return null;\n if (c && \"function\" !== typeof c) throw Error(u(231, b, typeof c));\n return c;\n}\n\nfunction Td(a, b, c) {\n if (b = Sd(a, c.dispatchConfig.phasedRegistrationNames[b])) c._dispatchListeners = ic(c._dispatchListeners, b), c._dispatchInstances = ic(c._dispatchInstances, a);\n}\n\nfunction Ud(a) {\n if (a && a.dispatchConfig.phasedRegistrationNames) {\n for (var b = a._targetInst, c = []; b;) {\n c.push(b), b = Rd(b);\n }\n\n for (b = c.length; 0 < b--;) {\n Td(c[b], \"captured\", a);\n }\n\n for (b = 0; b < c.length; b++) {\n Td(c[b], \"bubbled\", a);\n }\n }\n}\n\nfunction Vd(a, b, c) {\n a && c && c.dispatchConfig.registrationName && (b = Sd(a, c.dispatchConfig.registrationName)) && (c._dispatchListeners = ic(c._dispatchListeners, b), c._dispatchInstances = ic(c._dispatchInstances, a));\n}\n\nfunction Wd(a) {\n a && a.dispatchConfig.registrationName && Vd(a._targetInst, null, a);\n}\n\nfunction Xd(a) {\n jc(a, Ud);\n}\n\nvar Yd = null,\n Zd = null,\n $d = null;\n\nfunction ae() {\n if ($d) return $d;\n var a,\n b = Zd,\n c = b.length,\n d,\n e = \"value\" in Yd ? Yd.value : Yd.textContent,\n f = e.length;\n\n for (a = 0; a < c && b[a] === e[a]; a++) {\n ;\n }\n\n var g = c - a;\n\n for (d = 1; d <= g && b[c - d] === e[f - d]; d++) {\n ;\n }\n\n return $d = e.slice(a, 1 < d ? 1 - d : void 0);\n}\n\nfunction be() {\n return !0;\n}\n\nfunction ce() {\n return !1;\n}\n\nfunction G(a, b, c, d) {\n this.dispatchConfig = a;\n this._targetInst = b;\n this.nativeEvent = c;\n a = this.constructor.Interface;\n\n for (var e in a) {\n a.hasOwnProperty(e) && ((b = a[e]) ? this[e] = b(c) : \"target\" === e ? this.target = d : this[e] = c[e]);\n }\n\n this.isDefaultPrevented = (null != c.defaultPrevented ? c.defaultPrevented : !1 === c.returnValue) ? be : ce;\n this.isPropagationStopped = ce;\n return this;\n}\n\nn(G.prototype, {\n preventDefault: function preventDefault() {\n this.defaultPrevented = !0;\n var a = this.nativeEvent;\n a && (a.preventDefault ? a.preventDefault() : \"unknown\" !== typeof a.returnValue && (a.returnValue = !1), this.isDefaultPrevented = be);\n },\n stopPropagation: function stopPropagation() {\n var a = this.nativeEvent;\n a && (a.stopPropagation ? a.stopPropagation() : \"unknown\" !== typeof a.cancelBubble && (a.cancelBubble = !0), this.isPropagationStopped = be);\n },\n persist: function persist() {\n this.isPersistent = be;\n },\n isPersistent: ce,\n destructor: function destructor() {\n var a = this.constructor.Interface,\n b;\n\n for (b in a) {\n this[b] = null;\n }\n\n this.nativeEvent = this._targetInst = this.dispatchConfig = null;\n this.isPropagationStopped = this.isDefaultPrevented = ce;\n this._dispatchInstances = this._dispatchListeners = null;\n }\n});\nG.Interface = {\n type: null,\n target: null,\n currentTarget: function currentTarget() {\n return null;\n },\n eventPhase: null,\n bubbles: null,\n cancelable: null,\n timeStamp: function timeStamp(a) {\n return a.timeStamp || Date.now();\n },\n defaultPrevented: null,\n isTrusted: null\n};\n\nG.extend = function (a) {\n function b() {}\n\n function c() {\n return d.apply(this, arguments);\n }\n\n var d = this;\n b.prototype = d.prototype;\n var e = new b();\n n(e, c.prototype);\n c.prototype = e;\n c.prototype.constructor = c;\n c.Interface = n({}, d.Interface, a);\n c.extend = d.extend;\n de(c);\n return c;\n};\n\nde(G);\n\nfunction ee(a, b, c, d) {\n if (this.eventPool.length) {\n var e = this.eventPool.pop();\n this.call(e, a, b, c, d);\n return e;\n }\n\n return new this(a, b, c, d);\n}\n\nfunction fe(a) {\n if (!(a instanceof this)) throw Error(u(279));\n a.destructor();\n 10 > this.eventPool.length && this.eventPool.push(a);\n}\n\nfunction de(a) {\n a.eventPool = [];\n a.getPooled = ee;\n a.release = fe;\n}\n\nvar ge = G.extend({\n data: null\n}),\n he = G.extend({\n data: null\n}),\n ie = [9, 13, 27, 32],\n je = ya && \"CompositionEvent\" in window,\n ke = null;\nya && \"documentMode\" in document && (ke = document.documentMode);\nvar le = ya && \"TextEvent\" in window && !ke,\n me = ya && (!je || ke && 8 < ke && 11 >= ke),\n ne = String.fromCharCode(32),\n oe = {\n beforeInput: {\n phasedRegistrationNames: {\n bubbled: \"onBeforeInput\",\n captured: \"onBeforeInputCapture\"\n },\n dependencies: [\"compositionend\", \"keypress\", \"textInput\", \"paste\"]\n },\n compositionEnd: {\n phasedRegistrationNames: {\n bubbled: \"onCompositionEnd\",\n captured: \"onCompositionEndCapture\"\n },\n dependencies: \"blur compositionend keydown keypress keyup mousedown\".split(\" \")\n },\n compositionStart: {\n phasedRegistrationNames: {\n bubbled: \"onCompositionStart\",\n captured: \"onCompositionStartCapture\"\n },\n dependencies: \"blur compositionstart keydown keypress keyup mousedown\".split(\" \")\n },\n compositionUpdate: {\n phasedRegistrationNames: {\n bubbled: \"onCompositionUpdate\",\n captured: \"onCompositionUpdateCapture\"\n },\n dependencies: \"blur compositionupdate keydown keypress keyup mousedown\".split(\" \")\n }\n},\n pe = !1;\n\nfunction qe(a, b) {\n switch (a) {\n case \"keyup\":\n return -1 !== ie.indexOf(b.keyCode);\n\n case \"keydown\":\n return 229 !== b.keyCode;\n\n case \"keypress\":\n case \"mousedown\":\n case \"blur\":\n return !0;\n\n default:\n return !1;\n }\n}\n\nfunction re(a) {\n a = a.detail;\n return \"object\" === typeof a && \"data\" in a ? a.data : null;\n}\n\nvar se = !1;\n\nfunction te(a, b) {\n switch (a) {\n case \"compositionend\":\n return re(b);\n\n case \"keypress\":\n if (32 !== b.which) return null;\n pe = !0;\n return ne;\n\n case \"textInput\":\n return a = b.data, a === ne && pe ? null : a;\n\n default:\n return null;\n }\n}\n\nfunction ue(a, b) {\n if (se) return \"compositionend\" === a || !je && qe(a, b) ? (a = ae(), $d = Zd = Yd = null, se = !1, a) : null;\n\n switch (a) {\n case \"paste\":\n return null;\n\n case \"keypress\":\n if (!(b.ctrlKey || b.altKey || b.metaKey) || b.ctrlKey && b.altKey) {\n if (b.char && 1 < b.char.length) return b.char;\n if (b.which) return String.fromCharCode(b.which);\n }\n\n return null;\n\n case \"compositionend\":\n return me && \"ko\" !== b.locale ? null : b.data;\n\n default:\n return null;\n }\n}\n\nvar ve = {\n eventTypes: oe,\n extractEvents: function extractEvents(a, b, c, d) {\n var e;\n if (je) b: {\n switch (a) {\n case \"compositionstart\":\n var f = oe.compositionStart;\n break b;\n\n case \"compositionend\":\n f = oe.compositionEnd;\n break b;\n\n case \"compositionupdate\":\n f = oe.compositionUpdate;\n break b;\n }\n\n f = void 0;\n } else se ? qe(a, c) && (f = oe.compositionEnd) : \"keydown\" === a && 229 === c.keyCode && (f = oe.compositionStart);\n f ? (me && \"ko\" !== c.locale && (se || f !== oe.compositionStart ? f === oe.compositionEnd && se && (e = ae()) : (Yd = d, Zd = \"value\" in Yd ? Yd.value : Yd.textContent, se = !0)), f = ge.getPooled(f, b, c, d), e ? f.data = e : (e = re(c), null !== e && (f.data = e)), Xd(f), e = f) : e = null;\n (a = le ? te(a, c) : ue(a, c)) ? (b = he.getPooled(oe.beforeInput, b, c, d), b.data = a, Xd(b)) : b = null;\n return null === e ? b : null === b ? e : [e, b];\n }\n},\n we = {\n color: !0,\n date: !0,\n datetime: !0,\n \"datetime-local\": !0,\n email: !0,\n month: !0,\n number: !0,\n password: !0,\n range: !0,\n search: !0,\n tel: !0,\n text: !0,\n time: !0,\n url: !0,\n week: !0\n};\n\nfunction xe(a) {\n var b = a && a.nodeName && a.nodeName.toLowerCase();\n return \"input\" === b ? !!we[a.type] : \"textarea\" === b ? !0 : !1;\n}\n\nvar ye = {\n change: {\n phasedRegistrationNames: {\n bubbled: \"onChange\",\n captured: \"onChangeCapture\"\n },\n dependencies: \"blur change click focus input keydown keyup selectionchange\".split(\" \")\n }\n};\n\nfunction ze(a, b, c) {\n a = G.getPooled(ye.change, a, b, c);\n a.type = \"change\";\n Da(c);\n Xd(a);\n return a;\n}\n\nvar Ae = null,\n Be = null;\n\nfunction Ce(a) {\n mc(a);\n}\n\nfunction De(a) {\n var b = Pd(a);\n if (yb(b)) return a;\n}\n\nfunction Ee(a, b) {\n if (\"change\" === a) return b;\n}\n\nvar Fe = !1;\nya && (Fe = oc(\"input\") && (!document.documentMode || 9 < document.documentMode));\n\nfunction Ge() {\n Ae && (Ae.detachEvent(\"onpropertychange\", He), Be = Ae = null);\n}\n\nfunction He(a) {\n if (\"value\" === a.propertyName && De(Be)) if (a = ze(Be, a, nc(a)), Ja) mc(a);else {\n Ja = !0;\n\n try {\n Fa(Ce, a);\n } finally {\n Ja = !1, La();\n }\n }\n}\n\nfunction Ie(a, b, c) {\n \"focus\" === a ? (Ge(), Ae = b, Be = c, Ae.attachEvent(\"onpropertychange\", He)) : \"blur\" === a && Ge();\n}\n\nfunction Je(a) {\n if (\"selectionchange\" === a || \"keyup\" === a || \"keydown\" === a) return De(Be);\n}\n\nfunction Ke(a, b) {\n if (\"click\" === a) return De(b);\n}\n\nfunction Le(a, b) {\n if (\"input\" === a || \"change\" === a) return De(b);\n}\n\nvar Me = {\n eventTypes: ye,\n _isInputEventSupported: Fe,\n extractEvents: function extractEvents(a, b, c, d) {\n var e = b ? Pd(b) : window,\n f = e.nodeName && e.nodeName.toLowerCase();\n if (\"select\" === f || \"input\" === f && \"file\" === e.type) var g = Ee;else if (xe(e)) {\n if (Fe) g = Le;else {\n g = Je;\n var h = Ie;\n }\n } else (f = e.nodeName) && \"input\" === f.toLowerCase() && (\"checkbox\" === e.type || \"radio\" === e.type) && (g = Ke);\n if (g && (g = g(a, b))) return ze(g, c, d);\n h && h(a, e, b);\n \"blur\" === a && (a = e._wrapperState) && a.controlled && \"number\" === e.type && Db(e, \"number\", e.value);\n }\n},\n Ne = G.extend({\n view: null,\n detail: null\n}),\n Oe = {\n Alt: \"altKey\",\n Control: \"ctrlKey\",\n Meta: \"metaKey\",\n Shift: \"shiftKey\"\n};\n\nfunction Pe(a) {\n var b = this.nativeEvent;\n return b.getModifierState ? b.getModifierState(a) : (a = Oe[a]) ? !!b[a] : !1;\n}\n\nfunction Qe() {\n return Pe;\n}\n\nvar Re = 0,\n Se = 0,\n Te = !1,\n Ue = !1,\n Ve = Ne.extend({\n screenX: null,\n screenY: null,\n clientX: null,\n clientY: null,\n pageX: null,\n pageY: null,\n ctrlKey: null,\n shiftKey: null,\n altKey: null,\n metaKey: null,\n getModifierState: Qe,\n button: null,\n buttons: null,\n relatedTarget: function relatedTarget(a) {\n return a.relatedTarget || (a.fromElement === a.srcElement ? a.toElement : a.fromElement);\n },\n movementX: function movementX(a) {\n if (\"movementX\" in a) return a.movementX;\n var b = Re;\n Re = a.screenX;\n return Te ? \"mousemove\" === a.type ? a.screenX - b : 0 : (Te = !0, 0);\n },\n movementY: function movementY(a) {\n if (\"movementY\" in a) return a.movementY;\n var b = Se;\n Se = a.screenY;\n return Ue ? \"mousemove\" === a.type ? a.screenY - b : 0 : (Ue = !0, 0);\n }\n}),\n We = Ve.extend({\n pointerId: null,\n width: null,\n height: null,\n pressure: null,\n tangentialPressure: null,\n tiltX: null,\n tiltY: null,\n twist: null,\n pointerType: null,\n isPrimary: null\n}),\n Xe = {\n mouseEnter: {\n registrationName: \"onMouseEnter\",\n dependencies: [\"mouseout\", \"mouseover\"]\n },\n mouseLeave: {\n registrationName: \"onMouseLeave\",\n dependencies: [\"mouseout\", \"mouseover\"]\n },\n pointerEnter: {\n registrationName: \"onPointerEnter\",\n dependencies: [\"pointerout\", \"pointerover\"]\n },\n pointerLeave: {\n registrationName: \"onPointerLeave\",\n dependencies: [\"pointerout\", \"pointerover\"]\n }\n},\n Ye = {\n eventTypes: Xe,\n extractEvents: function extractEvents(a, b, c, d, e) {\n var f = \"mouseover\" === a || \"pointerover\" === a,\n g = \"mouseout\" === a || \"pointerout\" === a;\n if (f && 0 === (e & 32) && (c.relatedTarget || c.fromElement) || !g && !f) return null;\n f = d.window === d ? d : (f = d.ownerDocument) ? f.defaultView || f.parentWindow : window;\n\n if (g) {\n if (g = b, b = (b = c.relatedTarget || c.toElement) ? tc(b) : null, null !== b) {\n var h = dc(b);\n if (b !== h || 5 !== b.tag && 6 !== b.tag) b = null;\n }\n } else g = null;\n\n if (g === b) return null;\n\n if (\"mouseout\" === a || \"mouseover\" === a) {\n var k = Ve;\n var l = Xe.mouseLeave;\n var m = Xe.mouseEnter;\n var p = \"mouse\";\n } else if (\"pointerout\" === a || \"pointerover\" === a) k = We, l = Xe.pointerLeave, m = Xe.pointerEnter, p = \"pointer\";\n\n a = null == g ? f : Pd(g);\n f = null == b ? f : Pd(b);\n l = k.getPooled(l, g, c, d);\n l.type = p + \"leave\";\n l.target = a;\n l.relatedTarget = f;\n c = k.getPooled(m, b, c, d);\n c.type = p + \"enter\";\n c.target = f;\n c.relatedTarget = a;\n d = g;\n p = b;\n if (d && p) a: {\n k = d;\n m = p;\n g = 0;\n\n for (a = k; a; a = Rd(a)) {\n g++;\n }\n\n a = 0;\n\n for (b = m; b; b = Rd(b)) {\n a++;\n }\n\n for (; 0 < g - a;) {\n k = Rd(k), g--;\n }\n\n for (; 0 < a - g;) {\n m = Rd(m), a--;\n }\n\n for (; g--;) {\n if (k === m || k === m.alternate) break a;\n k = Rd(k);\n m = Rd(m);\n }\n\n k = null;\n } else k = null;\n m = k;\n\n for (k = []; d && d !== m;) {\n g = d.alternate;\n if (null !== g && g === m) break;\n k.push(d);\n d = Rd(d);\n }\n\n for (d = []; p && p !== m;) {\n g = p.alternate;\n if (null !== g && g === m) break;\n d.push(p);\n p = Rd(p);\n }\n\n for (p = 0; p < k.length; p++) {\n Vd(k[p], \"bubbled\", l);\n }\n\n for (p = d.length; 0 < p--;) {\n Vd(d[p], \"captured\", c);\n }\n\n return 0 === (e & 64) ? [l] : [l, c];\n }\n};\n\nfunction Ze(a, b) {\n return a === b && (0 !== a || 1 / a === 1 / b) || a !== a && b !== b;\n}\n\nvar $e = \"function\" === typeof Object.is ? Object.is : Ze,\n af = Object.prototype.hasOwnProperty;\n\nfunction bf(a, b) {\n if ($e(a, b)) return !0;\n if (\"object\" !== typeof a || null === a || \"object\" !== typeof b || null === b) return !1;\n var c = Object.keys(a),\n d = Object.keys(b);\n if (c.length !== d.length) return !1;\n\n for (d = 0; d < c.length; d++) {\n if (!af.call(b, c[d]) || !$e(a[c[d]], b[c[d]])) return !1;\n }\n\n return !0;\n}\n\nvar cf = ya && \"documentMode\" in document && 11 >= document.documentMode,\n df = {\n select: {\n phasedRegistrationNames: {\n bubbled: \"onSelect\",\n captured: \"onSelectCapture\"\n },\n dependencies: \"blur contextmenu dragend focus keydown keyup mousedown mouseup selectionchange\".split(\" \")\n }\n},\n ef = null,\n ff = null,\n gf = null,\n hf = !1;\n\nfunction jf(a, b) {\n var c = b.window === b ? b.document : 9 === b.nodeType ? b : b.ownerDocument;\n if (hf || null == ef || ef !== td(c)) return null;\n c = ef;\n \"selectionStart\" in c && yd(c) ? c = {\n start: c.selectionStart,\n end: c.selectionEnd\n } : (c = (c.ownerDocument && c.ownerDocument.defaultView || window).getSelection(), c = {\n anchorNode: c.anchorNode,\n anchorOffset: c.anchorOffset,\n focusNode: c.focusNode,\n focusOffset: c.focusOffset\n });\n return gf && bf(gf, c) ? null : (gf = c, a = G.getPooled(df.select, ff, a, b), a.type = \"select\", a.target = ef, Xd(a), a);\n}\n\nvar kf = {\n eventTypes: df,\n extractEvents: function extractEvents(a, b, c, d, e, f) {\n e = f || (d.window === d ? d.document : 9 === d.nodeType ? d : d.ownerDocument);\n\n if (!(f = !e)) {\n a: {\n e = cc(e);\n f = wa.onSelect;\n\n for (var g = 0; g < f.length; g++) {\n if (!e.has(f[g])) {\n e = !1;\n break a;\n }\n }\n\n e = !0;\n }\n\n f = !e;\n }\n\n if (f) return null;\n e = b ? Pd(b) : window;\n\n switch (a) {\n case \"focus\":\n if (xe(e) || \"true\" === e.contentEditable) ef = e, ff = b, gf = null;\n break;\n\n case \"blur\":\n gf = ff = ef = null;\n break;\n\n case \"mousedown\":\n hf = !0;\n break;\n\n case \"contextmenu\":\n case \"mouseup\":\n case \"dragend\":\n return hf = !1, jf(c, d);\n\n case \"selectionchange\":\n if (cf) break;\n\n case \"keydown\":\n case \"keyup\":\n return jf(c, d);\n }\n\n return null;\n }\n},\n lf = G.extend({\n animationName: null,\n elapsedTime: null,\n pseudoElement: null\n}),\n mf = G.extend({\n clipboardData: function clipboardData(a) {\n return \"clipboardData\" in a ? a.clipboardData : window.clipboardData;\n }\n}),\n nf = Ne.extend({\n relatedTarget: null\n});\n\nfunction of(a) {\n var b = a.keyCode;\n \"charCode\" in a ? (a = a.charCode, 0 === a && 13 === b && (a = 13)) : a = b;\n 10 === a && (a = 13);\n return 32 <= a || 13 === a ? a : 0;\n}\n\nvar pf = {\n Esc: \"Escape\",\n Spacebar: \" \",\n Left: \"ArrowLeft\",\n Up: \"ArrowUp\",\n Right: \"ArrowRight\",\n Down: \"ArrowDown\",\n Del: \"Delete\",\n Win: \"OS\",\n Menu: \"ContextMenu\",\n Apps: \"ContextMenu\",\n Scroll: \"ScrollLock\",\n MozPrintableKey: \"Unidentified\"\n},\n qf = {\n 8: \"Backspace\",\n 9: \"Tab\",\n 12: \"Clear\",\n 13: \"Enter\",\n 16: \"Shift\",\n 17: \"Control\",\n 18: \"Alt\",\n 19: \"Pause\",\n 20: \"CapsLock\",\n 27: \"Escape\",\n 32: \" \",\n 33: \"PageUp\",\n 34: \"PageDown\",\n 35: \"End\",\n 36: \"Home\",\n 37: \"ArrowLeft\",\n 38: \"ArrowUp\",\n 39: \"ArrowRight\",\n 40: \"ArrowDown\",\n 45: \"Insert\",\n 46: \"Delete\",\n 112: \"F1\",\n 113: \"F2\",\n 114: \"F3\",\n 115: \"F4\",\n 116: \"F5\",\n 117: \"F6\",\n 118: \"F7\",\n 119: \"F8\",\n 120: \"F9\",\n 121: \"F10\",\n 122: \"F11\",\n 123: \"F12\",\n 144: \"NumLock\",\n 145: \"ScrollLock\",\n 224: \"Meta\"\n},\n rf = Ne.extend({\n key: function key(a) {\n if (a.key) {\n var b = pf[a.key] || a.key;\n if (\"Unidentified\" !== b) return b;\n }\n\n return \"keypress\" === a.type ? (a = of(a), 13 === a ? \"Enter\" : String.fromCharCode(a)) : \"keydown\" === a.type || \"keyup\" === a.type ? qf[a.keyCode] || \"Unidentified\" : \"\";\n },\n location: null,\n ctrlKey: null,\n shiftKey: null,\n altKey: null,\n metaKey: null,\n repeat: null,\n locale: null,\n getModifierState: Qe,\n charCode: function charCode(a) {\n return \"keypress\" === a.type ? of(a) : 0;\n },\n keyCode: function keyCode(a) {\n return \"keydown\" === a.type || \"keyup\" === a.type ? a.keyCode : 0;\n },\n which: function which(a) {\n return \"keypress\" === a.type ? of(a) : \"keydown\" === a.type || \"keyup\" === a.type ? a.keyCode : 0;\n }\n}),\n sf = Ve.extend({\n dataTransfer: null\n}),\n tf = Ne.extend({\n touches: null,\n targetTouches: null,\n changedTouches: null,\n altKey: null,\n metaKey: null,\n ctrlKey: null,\n shiftKey: null,\n getModifierState: Qe\n}),\n uf = G.extend({\n propertyName: null,\n elapsedTime: null,\n pseudoElement: null\n}),\n vf = Ve.extend({\n deltaX: function deltaX(a) {\n return \"deltaX\" in a ? a.deltaX : \"wheelDeltaX\" in a ? -a.wheelDeltaX : 0;\n },\n deltaY: function deltaY(a) {\n return \"deltaY\" in a ? a.deltaY : \"wheelDeltaY\" in a ? -a.wheelDeltaY : \"wheelDelta\" in a ? -a.wheelDelta : 0;\n },\n deltaZ: null,\n deltaMode: null\n}),\n wf = {\n eventTypes: Wc,\n extractEvents: function extractEvents(a, b, c, d) {\n var e = Yc.get(a);\n if (!e) return null;\n\n switch (a) {\n case \"keypress\":\n if (0 === of(c)) return null;\n\n case \"keydown\":\n case \"keyup\":\n a = rf;\n break;\n\n case \"blur\":\n case \"focus\":\n a = nf;\n break;\n\n case \"click\":\n if (2 === c.button) return null;\n\n case \"auxclick\":\n case \"dblclick\":\n case \"mousedown\":\n case \"mousemove\":\n case \"mouseup\":\n case \"mouseout\":\n case \"mouseover\":\n case \"contextmenu\":\n a = Ve;\n break;\n\n case \"drag\":\n case \"dragend\":\n case \"dragenter\":\n case \"dragexit\":\n case \"dragleave\":\n case \"dragover\":\n case \"dragstart\":\n case \"drop\":\n a = sf;\n break;\n\n case \"touchcancel\":\n case \"touchend\":\n case \"touchmove\":\n case \"touchstart\":\n a = tf;\n break;\n\n case Xb:\n case Yb:\n case Zb:\n a = lf;\n break;\n\n case $b:\n a = uf;\n break;\n\n case \"scroll\":\n a = Ne;\n break;\n\n case \"wheel\":\n a = vf;\n break;\n\n case \"copy\":\n case \"cut\":\n case \"paste\":\n a = mf;\n break;\n\n case \"gotpointercapture\":\n case \"lostpointercapture\":\n case \"pointercancel\":\n case \"pointerdown\":\n case \"pointermove\":\n case \"pointerout\":\n case \"pointerover\":\n case \"pointerup\":\n a = We;\n break;\n\n default:\n a = G;\n }\n\n b = a.getPooled(e, b, c, d);\n Xd(b);\n return b;\n }\n};\nif (pa) throw Error(u(101));\npa = Array.prototype.slice.call(\"ResponderEventPlugin SimpleEventPlugin EnterLeaveEventPlugin ChangeEventPlugin SelectEventPlugin BeforeInputEventPlugin\".split(\" \"));\nra();\nvar xf = Nc;\nla = Qd;\nma = xf;\nna = Pd;\nxa({\n SimpleEventPlugin: wf,\n EnterLeaveEventPlugin: Ye,\n ChangeEventPlugin: Me,\n SelectEventPlugin: kf,\n BeforeInputEventPlugin: ve\n});\nvar yf = [],\n zf = -1;\n\nfunction H(a) {\n 0 > zf || (a.current = yf[zf], yf[zf] = null, zf--);\n}\n\nfunction I(a, b) {\n zf++;\n yf[zf] = a.current;\n a.current = b;\n}\n\nvar Af = {},\n J = {\n current: Af\n},\n K = {\n current: !1\n},\n Bf = Af;\n\nfunction Cf(a, b) {\n var c = a.type.contextTypes;\n if (!c) return Af;\n var d = a.stateNode;\n if (d && d.__reactInternalMemoizedUnmaskedChildContext === b) return d.__reactInternalMemoizedMaskedChildContext;\n var e = {},\n f;\n\n for (f in c) {\n e[f] = b[f];\n }\n\n d && (a = a.stateNode, a.__reactInternalMemoizedUnmaskedChildContext = b, a.__reactInternalMemoizedMaskedChildContext = e);\n return e;\n}\n\nfunction L(a) {\n a = a.childContextTypes;\n return null !== a && void 0 !== a;\n}\n\nfunction Df() {\n H(K);\n H(J);\n}\n\nfunction Ef(a, b, c) {\n if (J.current !== Af) throw Error(u(168));\n I(J, b);\n I(K, c);\n}\n\nfunction Ff(a, b, c) {\n var d = a.stateNode;\n a = b.childContextTypes;\n if (\"function\" !== typeof d.getChildContext) return c;\n d = d.getChildContext();\n\n for (var e in d) {\n if (!(e in a)) throw Error(u(108, pb(b) || \"Unknown\", e));\n }\n\n return n({}, c, {}, d);\n}\n\nfunction Gf(a) {\n a = (a = a.stateNode) && a.__reactInternalMemoizedMergedChildContext || Af;\n Bf = J.current;\n I(J, a);\n I(K, K.current);\n return !0;\n}\n\nfunction Hf(a, b, c) {\n var d = a.stateNode;\n if (!d) throw Error(u(169));\n c ? (a = Ff(a, b, Bf), d.__reactInternalMemoizedMergedChildContext = a, H(K), H(J), I(J, a)) : H(K);\n I(K, c);\n}\n\nvar If = r.unstable_runWithPriority,\n Jf = r.unstable_scheduleCallback,\n Kf = r.unstable_cancelCallback,\n Lf = r.unstable_requestPaint,\n Mf = r.unstable_now,\n Nf = r.unstable_getCurrentPriorityLevel,\n Of = r.unstable_ImmediatePriority,\n Pf = r.unstable_UserBlockingPriority,\n Qf = r.unstable_NormalPriority,\n Rf = r.unstable_LowPriority,\n Sf = r.unstable_IdlePriority,\n Tf = {},\n Uf = r.unstable_shouldYield,\n Vf = void 0 !== Lf ? Lf : function () {},\n Wf = null,\n Xf = null,\n Yf = !1,\n Zf = Mf(),\n $f = 1E4 > Zf ? Mf : function () {\n return Mf() - Zf;\n};\n\nfunction ag() {\n switch (Nf()) {\n case Of:\n return 99;\n\n case Pf:\n return 98;\n\n case Qf:\n return 97;\n\n case Rf:\n return 96;\n\n case Sf:\n return 95;\n\n default:\n throw Error(u(332));\n }\n}\n\nfunction bg(a) {\n switch (a) {\n case 99:\n return Of;\n\n case 98:\n return Pf;\n\n case 97:\n return Qf;\n\n case 96:\n return Rf;\n\n case 95:\n return Sf;\n\n default:\n throw Error(u(332));\n }\n}\n\nfunction cg(a, b) {\n a = bg(a);\n return If(a, b);\n}\n\nfunction dg(a, b, c) {\n a = bg(a);\n return Jf(a, b, c);\n}\n\nfunction eg(a) {\n null === Wf ? (Wf = [a], Xf = Jf(Of, fg)) : Wf.push(a);\n return Tf;\n}\n\nfunction gg() {\n if (null !== Xf) {\n var a = Xf;\n Xf = null;\n Kf(a);\n }\n\n fg();\n}\n\nfunction fg() {\n if (!Yf && null !== Wf) {\n Yf = !0;\n var a = 0;\n\n try {\n var b = Wf;\n cg(99, function () {\n for (; a < b.length; a++) {\n var c = b[a];\n\n do {\n c = c(!0);\n } while (null !== c);\n }\n });\n Wf = null;\n } catch (c) {\n throw null !== Wf && (Wf = Wf.slice(a + 1)), Jf(Of, gg), c;\n } finally {\n Yf = !1;\n }\n }\n}\n\nfunction hg(a, b, c) {\n c /= 10;\n return 1073741821 - (((1073741821 - a + b / 10) / c | 0) + 1) * c;\n}\n\nfunction ig(a, b) {\n if (a && a.defaultProps) {\n b = n({}, b);\n a = a.defaultProps;\n\n for (var c in a) {\n void 0 === b[c] && (b[c] = a[c]);\n }\n }\n\n return b;\n}\n\nvar jg = {\n current: null\n},\n kg = null,\n lg = null,\n mg = null;\n\nfunction ng() {\n mg = lg = kg = null;\n}\n\nfunction og(a) {\n var b = jg.current;\n H(jg);\n a.type._context._currentValue = b;\n}\n\nfunction pg(a, b) {\n for (; null !== a;) {\n var c = a.alternate;\n if (a.childExpirationTime < b) a.childExpirationTime = b, null !== c && c.childExpirationTime < b && (c.childExpirationTime = b);else if (null !== c && c.childExpirationTime < b) c.childExpirationTime = b;else break;\n a = a.return;\n }\n}\n\nfunction qg(a, b) {\n kg = a;\n mg = lg = null;\n a = a.dependencies;\n null !== a && null !== a.firstContext && (a.expirationTime >= b && (rg = !0), a.firstContext = null);\n}\n\nfunction sg(a, b) {\n if (mg !== a && !1 !== b && 0 !== b) {\n if (\"number\" !== typeof b || 1073741823 === b) mg = a, b = 1073741823;\n b = {\n context: a,\n observedBits: b,\n next: null\n };\n\n if (null === lg) {\n if (null === kg) throw Error(u(308));\n lg = b;\n kg.dependencies = {\n expirationTime: 0,\n firstContext: b,\n responders: null\n };\n } else lg = lg.next = b;\n }\n\n return a._currentValue;\n}\n\nvar tg = !1;\n\nfunction ug(a) {\n a.updateQueue = {\n baseState: a.memoizedState,\n baseQueue: null,\n shared: {\n pending: null\n },\n effects: null\n };\n}\n\nfunction vg(a, b) {\n a = a.updateQueue;\n b.updateQueue === a && (b.updateQueue = {\n baseState: a.baseState,\n baseQueue: a.baseQueue,\n shared: a.shared,\n effects: a.effects\n });\n}\n\nfunction wg(a, b) {\n a = {\n expirationTime: a,\n suspenseConfig: b,\n tag: 0,\n payload: null,\n callback: null,\n next: null\n };\n return a.next = a;\n}\n\nfunction xg(a, b) {\n a = a.updateQueue;\n\n if (null !== a) {\n a = a.shared;\n var c = a.pending;\n null === c ? b.next = b : (b.next = c.next, c.next = b);\n a.pending = b;\n }\n}\n\nfunction yg(a, b) {\n var c = a.alternate;\n null !== c && vg(c, a);\n a = a.updateQueue;\n c = a.baseQueue;\n null === c ? (a.baseQueue = b.next = b, b.next = b) : (b.next = c.next, c.next = b);\n}\n\nfunction zg(a, b, c, d) {\n var e = a.updateQueue;\n tg = !1;\n var f = e.baseQueue,\n g = e.shared.pending;\n\n if (null !== g) {\n if (null !== f) {\n var h = f.next;\n f.next = g.next;\n g.next = h;\n }\n\n f = g;\n e.shared.pending = null;\n h = a.alternate;\n null !== h && (h = h.updateQueue, null !== h && (h.baseQueue = g));\n }\n\n if (null !== f) {\n h = f.next;\n var k = e.baseState,\n l = 0,\n m = null,\n p = null,\n x = null;\n\n if (null !== h) {\n var z = h;\n\n do {\n g = z.expirationTime;\n\n if (g < d) {\n var ca = {\n expirationTime: z.expirationTime,\n suspenseConfig: z.suspenseConfig,\n tag: z.tag,\n payload: z.payload,\n callback: z.callback,\n next: null\n };\n null === x ? (p = x = ca, m = k) : x = x.next = ca;\n g > l && (l = g);\n } else {\n null !== x && (x = x.next = {\n expirationTime: 1073741823,\n suspenseConfig: z.suspenseConfig,\n tag: z.tag,\n payload: z.payload,\n callback: z.callback,\n next: null\n });\n Ag(g, z.suspenseConfig);\n\n a: {\n var D = a,\n t = z;\n g = b;\n ca = c;\n\n switch (t.tag) {\n case 1:\n D = t.payload;\n\n if (\"function\" === typeof D) {\n k = D.call(ca, k, g);\n break a;\n }\n\n k = D;\n break a;\n\n case 3:\n D.effectTag = D.effectTag & -4097 | 64;\n\n case 0:\n D = t.payload;\n g = \"function\" === typeof D ? D.call(ca, k, g) : D;\n if (null === g || void 0 === g) break a;\n k = n({}, k, g);\n break a;\n\n case 2:\n tg = !0;\n }\n }\n\n null !== z.callback && (a.effectTag |= 32, g = e.effects, null === g ? e.effects = [z] : g.push(z));\n }\n\n z = z.next;\n if (null === z || z === h) if (g = e.shared.pending, null === g) break;else z = f.next = g.next, g.next = h, e.baseQueue = f = g, e.shared.pending = null;\n } while (1);\n }\n\n null === x ? m = k : x.next = p;\n e.baseState = m;\n e.baseQueue = x;\n Bg(l);\n a.expirationTime = l;\n a.memoizedState = k;\n }\n}\n\nfunction Cg(a, b, c) {\n a = b.effects;\n b.effects = null;\n if (null !== a) for (b = 0; b < a.length; b++) {\n var d = a[b],\n e = d.callback;\n\n if (null !== e) {\n d.callback = null;\n d = e;\n e = c;\n if (\"function\" !== typeof d) throw Error(u(191, d));\n d.call(e);\n }\n }\n}\n\nvar Dg = Wa.ReactCurrentBatchConfig,\n Eg = new aa.Component().refs;\n\nfunction Fg(a, b, c, d) {\n b = a.memoizedState;\n c = c(d, b);\n c = null === c || void 0 === c ? b : n({}, b, c);\n a.memoizedState = c;\n 0 === a.expirationTime && (a.updateQueue.baseState = c);\n}\n\nvar Jg = {\n isMounted: function isMounted(a) {\n return (a = a._reactInternalFiber) ? dc(a) === a : !1;\n },\n enqueueSetState: function enqueueSetState(a, b, c) {\n a = a._reactInternalFiber;\n var d = Gg(),\n e = Dg.suspense;\n d = Hg(d, a, e);\n e = wg(d, e);\n e.payload = b;\n void 0 !== c && null !== c && (e.callback = c);\n xg(a, e);\n Ig(a, d);\n },\n enqueueReplaceState: function enqueueReplaceState(a, b, c) {\n a = a._reactInternalFiber;\n var d = Gg(),\n e = Dg.suspense;\n d = Hg(d, a, e);\n e = wg(d, e);\n e.tag = 1;\n e.payload = b;\n void 0 !== c && null !== c && (e.callback = c);\n xg(a, e);\n Ig(a, d);\n },\n enqueueForceUpdate: function enqueueForceUpdate(a, b) {\n a = a._reactInternalFiber;\n var c = Gg(),\n d = Dg.suspense;\n c = Hg(c, a, d);\n d = wg(c, d);\n d.tag = 2;\n void 0 !== b && null !== b && (d.callback = b);\n xg(a, d);\n Ig(a, c);\n }\n};\n\nfunction Kg(a, b, c, d, e, f, g) {\n a = a.stateNode;\n return \"function\" === typeof a.shouldComponentUpdate ? a.shouldComponentUpdate(d, f, g) : b.prototype && b.prototype.isPureReactComponent ? !bf(c, d) || !bf(e, f) : !0;\n}\n\nfunction Lg(a, b, c) {\n var d = !1,\n e = Af;\n var f = b.contextType;\n \"object\" === typeof f && null !== f ? f = sg(f) : (e = L(b) ? Bf : J.current, d = b.contextTypes, f = (d = null !== d && void 0 !== d) ? Cf(a, e) : Af);\n b = new b(c, f);\n a.memoizedState = null !== b.state && void 0 !== b.state ? b.state : null;\n b.updater = Jg;\n a.stateNode = b;\n b._reactInternalFiber = a;\n d && (a = a.stateNode, a.__reactInternalMemoizedUnmaskedChildContext = e, a.__reactInternalMemoizedMaskedChildContext = f);\n return b;\n}\n\nfunction Mg(a, b, c, d) {\n a = b.state;\n \"function\" === typeof b.componentWillReceiveProps && b.componentWillReceiveProps(c, d);\n \"function\" === typeof b.UNSAFE_componentWillReceiveProps && b.UNSAFE_componentWillReceiveProps(c, d);\n b.state !== a && Jg.enqueueReplaceState(b, b.state, null);\n}\n\nfunction Ng(a, b, c, d) {\n var e = a.stateNode;\n e.props = c;\n e.state = a.memoizedState;\n e.refs = Eg;\n ug(a);\n var f = b.contextType;\n \"object\" === typeof f && null !== f ? e.context = sg(f) : (f = L(b) ? Bf : J.current, e.context = Cf(a, f));\n zg(a, c, e, d);\n e.state = a.memoizedState;\n f = b.getDerivedStateFromProps;\n \"function\" === typeof f && (Fg(a, b, f, c), e.state = a.memoizedState);\n \"function\" === typeof b.getDerivedStateFromProps || \"function\" === typeof e.getSnapshotBeforeUpdate || \"function\" !== typeof e.UNSAFE_componentWillMount && \"function\" !== typeof e.componentWillMount || (b = e.state, \"function\" === typeof e.componentWillMount && e.componentWillMount(), \"function\" === typeof e.UNSAFE_componentWillMount && e.UNSAFE_componentWillMount(), b !== e.state && Jg.enqueueReplaceState(e, e.state, null), zg(a, c, e, d), e.state = a.memoizedState);\n \"function\" === typeof e.componentDidMount && (a.effectTag |= 4);\n}\n\nvar Og = Array.isArray;\n\nfunction Pg(a, b, c) {\n a = c.ref;\n\n if (null !== a && \"function\" !== typeof a && \"object\" !== typeof a) {\n if (c._owner) {\n c = c._owner;\n\n if (c) {\n if (1 !== c.tag) throw Error(u(309));\n var d = c.stateNode;\n }\n\n if (!d) throw Error(u(147, a));\n var e = \"\" + a;\n if (null !== b && null !== b.ref && \"function\" === typeof b.ref && b.ref._stringRef === e) return b.ref;\n\n b = function b(a) {\n var b = d.refs;\n b === Eg && (b = d.refs = {});\n null === a ? delete b[e] : b[e] = a;\n };\n\n b._stringRef = e;\n return b;\n }\n\n if (\"string\" !== typeof a) throw Error(u(284));\n if (!c._owner) throw Error(u(290, a));\n }\n\n return a;\n}\n\nfunction Qg(a, b) {\n if (\"textarea\" !== a.type) throw Error(u(31, \"[object Object]\" === Object.prototype.toString.call(b) ? \"object with keys {\" + Object.keys(b).join(\", \") + \"}\" : b, \"\"));\n}\n\nfunction Rg(a) {\n function b(b, c) {\n if (a) {\n var d = b.lastEffect;\n null !== d ? (d.nextEffect = c, b.lastEffect = c) : b.firstEffect = b.lastEffect = c;\n c.nextEffect = null;\n c.effectTag = 8;\n }\n }\n\n function c(c, d) {\n if (!a) return null;\n\n for (; null !== d;) {\n b(c, d), d = d.sibling;\n }\n\n return null;\n }\n\n function d(a, b) {\n for (a = new Map(); null !== b;) {\n null !== b.key ? a.set(b.key, b) : a.set(b.index, b), b = b.sibling;\n }\n\n return a;\n }\n\n function e(a, b) {\n a = Sg(a, b);\n a.index = 0;\n a.sibling = null;\n return a;\n }\n\n function f(b, c, d) {\n b.index = d;\n if (!a) return c;\n d = b.alternate;\n if (null !== d) return d = d.index, d < c ? (b.effectTag = 2, c) : d;\n b.effectTag = 2;\n return c;\n }\n\n function g(b) {\n a && null === b.alternate && (b.effectTag = 2);\n return b;\n }\n\n function h(a, b, c, d) {\n if (null === b || 6 !== b.tag) return b = Tg(c, a.mode, d), b.return = a, b;\n b = e(b, c);\n b.return = a;\n return b;\n }\n\n function k(a, b, c, d) {\n if (null !== b && b.elementType === c.type) return d = e(b, c.props), d.ref = Pg(a, b, c), d.return = a, d;\n d = Ug(c.type, c.key, c.props, null, a.mode, d);\n d.ref = Pg(a, b, c);\n d.return = a;\n return d;\n }\n\n function l(a, b, c, d) {\n if (null === b || 4 !== b.tag || b.stateNode.containerInfo !== c.containerInfo || b.stateNode.implementation !== c.implementation) return b = Vg(c, a.mode, d), b.return = a, b;\n b = e(b, c.children || []);\n b.return = a;\n return b;\n }\n\n function m(a, b, c, d, f) {\n if (null === b || 7 !== b.tag) return b = Wg(c, a.mode, d, f), b.return = a, b;\n b = e(b, c);\n b.return = a;\n return b;\n }\n\n function p(a, b, c) {\n if (\"string\" === typeof b || \"number\" === typeof b) return b = Tg(\"\" + b, a.mode, c), b.return = a, b;\n\n if (\"object\" === typeof b && null !== b) {\n switch (b.$$typeof) {\n case Za:\n return c = Ug(b.type, b.key, b.props, null, a.mode, c), c.ref = Pg(a, null, b), c.return = a, c;\n\n case $a:\n return b = Vg(b, a.mode, c), b.return = a, b;\n }\n\n if (Og(b) || nb(b)) return b = Wg(b, a.mode, c, null), b.return = a, b;\n Qg(a, b);\n }\n\n return null;\n }\n\n function x(a, b, c, d) {\n var e = null !== b ? b.key : null;\n if (\"string\" === typeof c || \"number\" === typeof c) return null !== e ? null : h(a, b, \"\" + c, d);\n\n if (\"object\" === typeof c && null !== c) {\n switch (c.$$typeof) {\n case Za:\n return c.key === e ? c.type === ab ? m(a, b, c.props.children, d, e) : k(a, b, c, d) : null;\n\n case $a:\n return c.key === e ? l(a, b, c, d) : null;\n }\n\n if (Og(c) || nb(c)) return null !== e ? null : m(a, b, c, d, null);\n Qg(a, c);\n }\n\n return null;\n }\n\n function z(a, b, c, d, e) {\n if (\"string\" === typeof d || \"number\" === typeof d) return a = a.get(c) || null, h(b, a, \"\" + d, e);\n\n if (\"object\" === typeof d && null !== d) {\n switch (d.$$typeof) {\n case Za:\n return a = a.get(null === d.key ? c : d.key) || null, d.type === ab ? m(b, a, d.props.children, e, d.key) : k(b, a, d, e);\n\n case $a:\n return a = a.get(null === d.key ? c : d.key) || null, l(b, a, d, e);\n }\n\n if (Og(d) || nb(d)) return a = a.get(c) || null, m(b, a, d, e, null);\n Qg(b, d);\n }\n\n return null;\n }\n\n function ca(e, g, h, k) {\n for (var l = null, t = null, m = g, y = g = 0, A = null; null !== m && y < h.length; y++) {\n m.index > y ? (A = m, m = null) : A = m.sibling;\n var q = x(e, m, h[y], k);\n\n if (null === q) {\n null === m && (m = A);\n break;\n }\n\n a && m && null === q.alternate && b(e, m);\n g = f(q, g, y);\n null === t ? l = q : t.sibling = q;\n t = q;\n m = A;\n }\n\n if (y === h.length) return c(e, m), l;\n\n if (null === m) {\n for (; y < h.length; y++) {\n m = p(e, h[y], k), null !== m && (g = f(m, g, y), null === t ? l = m : t.sibling = m, t = m);\n }\n\n return l;\n }\n\n for (m = d(e, m); y < h.length; y++) {\n A = z(m, e, y, h[y], k), null !== A && (a && null !== A.alternate && m.delete(null === A.key ? y : A.key), g = f(A, g, y), null === t ? l = A : t.sibling = A, t = A);\n }\n\n a && m.forEach(function (a) {\n return b(e, a);\n });\n return l;\n }\n\n function D(e, g, h, l) {\n var k = nb(h);\n if (\"function\" !== typeof k) throw Error(u(150));\n h = k.call(h);\n if (null == h) throw Error(u(151));\n\n for (var m = k = null, t = g, y = g = 0, A = null, q = h.next(); null !== t && !q.done; y++, q = h.next()) {\n t.index > y ? (A = t, t = null) : A = t.sibling;\n var D = x(e, t, q.value, l);\n\n if (null === D) {\n null === t && (t = A);\n break;\n }\n\n a && t && null === D.alternate && b(e, t);\n g = f(D, g, y);\n null === m ? k = D : m.sibling = D;\n m = D;\n t = A;\n }\n\n if (q.done) return c(e, t), k;\n\n if (null === t) {\n for (; !q.done; y++, q = h.next()) {\n q = p(e, q.value, l), null !== q && (g = f(q, g, y), null === m ? k = q : m.sibling = q, m = q);\n }\n\n return k;\n }\n\n for (t = d(e, t); !q.done; y++, q = h.next()) {\n q = z(t, e, y, q.value, l), null !== q && (a && null !== q.alternate && t.delete(null === q.key ? y : q.key), g = f(q, g, y), null === m ? k = q : m.sibling = q, m = q);\n }\n\n a && t.forEach(function (a) {\n return b(e, a);\n });\n return k;\n }\n\n return function (a, d, f, h) {\n var k = \"object\" === typeof f && null !== f && f.type === ab && null === f.key;\n k && (f = f.props.children);\n var l = \"object\" === typeof f && null !== f;\n if (l) switch (f.$$typeof) {\n case Za:\n a: {\n l = f.key;\n\n for (k = d; null !== k;) {\n if (k.key === l) {\n switch (k.tag) {\n case 7:\n if (f.type === ab) {\n c(a, k.sibling);\n d = e(k, f.props.children);\n d.return = a;\n a = d;\n break a;\n }\n\n break;\n\n default:\n if (k.elementType === f.type) {\n c(a, k.sibling);\n d = e(k, f.props);\n d.ref = Pg(a, k, f);\n d.return = a;\n a = d;\n break a;\n }\n\n }\n\n c(a, k);\n break;\n } else b(a, k);\n\n k = k.sibling;\n }\n\n f.type === ab ? (d = Wg(f.props.children, a.mode, h, f.key), d.return = a, a = d) : (h = Ug(f.type, f.key, f.props, null, a.mode, h), h.ref = Pg(a, d, f), h.return = a, a = h);\n }\n\n return g(a);\n\n case $a:\n a: {\n for (k = f.key; null !== d;) {\n if (d.key === k) {\n if (4 === d.tag && d.stateNode.containerInfo === f.containerInfo && d.stateNode.implementation === f.implementation) {\n c(a, d.sibling);\n d = e(d, f.children || []);\n d.return = a;\n a = d;\n break a;\n } else {\n c(a, d);\n break;\n }\n } else b(a, d);\n d = d.sibling;\n }\n\n d = Vg(f, a.mode, h);\n d.return = a;\n a = d;\n }\n\n return g(a);\n }\n if (\"string\" === typeof f || \"number\" === typeof f) return f = \"\" + f, null !== d && 6 === d.tag ? (c(a, d.sibling), d = e(d, f), d.return = a, a = d) : (c(a, d), d = Tg(f, a.mode, h), d.return = a, a = d), g(a);\n if (Og(f)) return ca(a, d, f, h);\n if (nb(f)) return D(a, d, f, h);\n l && Qg(a, f);\n if (\"undefined\" === typeof f && !k) switch (a.tag) {\n case 1:\n case 0:\n throw a = a.type, Error(u(152, a.displayName || a.name || \"Component\"));\n }\n return c(a, d);\n };\n}\n\nvar Xg = Rg(!0),\n Yg = Rg(!1),\n Zg = {},\n $g = {\n current: Zg\n},\n ah = {\n current: Zg\n},\n bh = {\n current: Zg\n};\n\nfunction ch(a) {\n if (a === Zg) throw Error(u(174));\n return a;\n}\n\nfunction dh(a, b) {\n I(bh, b);\n I(ah, a);\n I($g, Zg);\n a = b.nodeType;\n\n switch (a) {\n case 9:\n case 11:\n b = (b = b.documentElement) ? b.namespaceURI : Ob(null, \"\");\n break;\n\n default:\n a = 8 === a ? b.parentNode : b, b = a.namespaceURI || null, a = a.tagName, b = Ob(b, a);\n }\n\n H($g);\n I($g, b);\n}\n\nfunction eh() {\n H($g);\n H(ah);\n H(bh);\n}\n\nfunction fh(a) {\n ch(bh.current);\n var b = ch($g.current);\n var c = Ob(b, a.type);\n b !== c && (I(ah, a), I($g, c));\n}\n\nfunction gh(a) {\n ah.current === a && (H($g), H(ah));\n}\n\nvar M = {\n current: 0\n};\n\nfunction hh(a) {\n for (var b = a; null !== b;) {\n if (13 === b.tag) {\n var c = b.memoizedState;\n if (null !== c && (c = c.dehydrated, null === c || c.data === Bd || c.data === Cd)) return b;\n } else if (19 === b.tag && void 0 !== b.memoizedProps.revealOrder) {\n if (0 !== (b.effectTag & 64)) return b;\n } else if (null !== b.child) {\n b.child.return = b;\n b = b.child;\n continue;\n }\n\n if (b === a) break;\n\n for (; null === b.sibling;) {\n if (null === b.return || b.return === a) return null;\n b = b.return;\n }\n\n b.sibling.return = b.return;\n b = b.sibling;\n }\n\n return null;\n}\n\nfunction ih(a, b) {\n return {\n responder: a,\n props: b\n };\n}\n\nvar jh = Wa.ReactCurrentDispatcher,\n kh = Wa.ReactCurrentBatchConfig,\n lh = 0,\n N = null,\n O = null,\n P = null,\n mh = !1;\n\nfunction Q() {\n throw Error(u(321));\n}\n\nfunction nh(a, b) {\n if (null === b) return !1;\n\n for (var c = 0; c < b.length && c < a.length; c++) {\n if (!$e(a[c], b[c])) return !1;\n }\n\n return !0;\n}\n\nfunction oh(a, b, c, d, e, f) {\n lh = f;\n N = b;\n b.memoizedState = null;\n b.updateQueue = null;\n b.expirationTime = 0;\n jh.current = null === a || null === a.memoizedState ? ph : qh;\n a = c(d, e);\n\n if (b.expirationTime === lh) {\n f = 0;\n\n do {\n b.expirationTime = 0;\n if (!(25 > f)) throw Error(u(301));\n f += 1;\n P = O = null;\n b.updateQueue = null;\n jh.current = rh;\n a = c(d, e);\n } while (b.expirationTime === lh);\n }\n\n jh.current = sh;\n b = null !== O && null !== O.next;\n lh = 0;\n P = O = N = null;\n mh = !1;\n if (b) throw Error(u(300));\n return a;\n}\n\nfunction th() {\n var a = {\n memoizedState: null,\n baseState: null,\n baseQueue: null,\n queue: null,\n next: null\n };\n null === P ? N.memoizedState = P = a : P = P.next = a;\n return P;\n}\n\nfunction uh() {\n if (null === O) {\n var a = N.alternate;\n a = null !== a ? a.memoizedState : null;\n } else a = O.next;\n\n var b = null === P ? N.memoizedState : P.next;\n if (null !== b) P = b, O = a;else {\n if (null === a) throw Error(u(310));\n O = a;\n a = {\n memoizedState: O.memoizedState,\n baseState: O.baseState,\n baseQueue: O.baseQueue,\n queue: O.queue,\n next: null\n };\n null === P ? N.memoizedState = P = a : P = P.next = a;\n }\n return P;\n}\n\nfunction vh(a, b) {\n return \"function\" === typeof b ? b(a) : b;\n}\n\nfunction wh(a) {\n var b = uh(),\n c = b.queue;\n if (null === c) throw Error(u(311));\n c.lastRenderedReducer = a;\n var d = O,\n e = d.baseQueue,\n f = c.pending;\n\n if (null !== f) {\n if (null !== e) {\n var g = e.next;\n e.next = f.next;\n f.next = g;\n }\n\n d.baseQueue = e = f;\n c.pending = null;\n }\n\n if (null !== e) {\n e = e.next;\n d = d.baseState;\n var h = g = f = null,\n k = e;\n\n do {\n var l = k.expirationTime;\n\n if (l < lh) {\n var m = {\n expirationTime: k.expirationTime,\n suspenseConfig: k.suspenseConfig,\n action: k.action,\n eagerReducer: k.eagerReducer,\n eagerState: k.eagerState,\n next: null\n };\n null === h ? (g = h = m, f = d) : h = h.next = m;\n l > N.expirationTime && (N.expirationTime = l, Bg(l));\n } else null !== h && (h = h.next = {\n expirationTime: 1073741823,\n suspenseConfig: k.suspenseConfig,\n action: k.action,\n eagerReducer: k.eagerReducer,\n eagerState: k.eagerState,\n next: null\n }), Ag(l, k.suspenseConfig), d = k.eagerReducer === a ? k.eagerState : a(d, k.action);\n\n k = k.next;\n } while (null !== k && k !== e);\n\n null === h ? f = d : h.next = g;\n $e(d, b.memoizedState) || (rg = !0);\n b.memoizedState = d;\n b.baseState = f;\n b.baseQueue = h;\n c.lastRenderedState = d;\n }\n\n return [b.memoizedState, c.dispatch];\n}\n\nfunction xh(a) {\n var b = uh(),\n c = b.queue;\n if (null === c) throw Error(u(311));\n c.lastRenderedReducer = a;\n var d = c.dispatch,\n e = c.pending,\n f = b.memoizedState;\n\n if (null !== e) {\n c.pending = null;\n var g = e = e.next;\n\n do {\n f = a(f, g.action), g = g.next;\n } while (g !== e);\n\n $e(f, b.memoizedState) || (rg = !0);\n b.memoizedState = f;\n null === b.baseQueue && (b.baseState = f);\n c.lastRenderedState = f;\n }\n\n return [f, d];\n}\n\nfunction yh(a) {\n var b = th();\n \"function\" === typeof a && (a = a());\n b.memoizedState = b.baseState = a;\n a = b.queue = {\n pending: null,\n dispatch: null,\n lastRenderedReducer: vh,\n lastRenderedState: a\n };\n a = a.dispatch = zh.bind(null, N, a);\n return [b.memoizedState, a];\n}\n\nfunction Ah(a, b, c, d) {\n a = {\n tag: a,\n create: b,\n destroy: c,\n deps: d,\n next: null\n };\n b = N.updateQueue;\n null === b ? (b = {\n lastEffect: null\n }, N.updateQueue = b, b.lastEffect = a.next = a) : (c = b.lastEffect, null === c ? b.lastEffect = a.next = a : (d = c.next, c.next = a, a.next = d, b.lastEffect = a));\n return a;\n}\n\nfunction Bh() {\n return uh().memoizedState;\n}\n\nfunction Ch(a, b, c, d) {\n var e = th();\n N.effectTag |= a;\n e.memoizedState = Ah(1 | b, c, void 0, void 0 === d ? null : d);\n}\n\nfunction Dh(a, b, c, d) {\n var e = uh();\n d = void 0 === d ? null : d;\n var f = void 0;\n\n if (null !== O) {\n var g = O.memoizedState;\n f = g.destroy;\n\n if (null !== d && nh(d, g.deps)) {\n Ah(b, c, f, d);\n return;\n }\n }\n\n N.effectTag |= a;\n e.memoizedState = Ah(1 | b, c, f, d);\n}\n\nfunction Eh(a, b) {\n return Ch(516, 4, a, b);\n}\n\nfunction Fh(a, b) {\n return Dh(516, 4, a, b);\n}\n\nfunction Gh(a, b) {\n return Dh(4, 2, a, b);\n}\n\nfunction Hh(a, b) {\n if (\"function\" === typeof b) return a = a(), b(a), function () {\n b(null);\n };\n if (null !== b && void 0 !== b) return a = a(), b.current = a, function () {\n b.current = null;\n };\n}\n\nfunction Ih(a, b, c) {\n c = null !== c && void 0 !== c ? c.concat([a]) : null;\n return Dh(4, 2, Hh.bind(null, b, a), c);\n}\n\nfunction Jh() {}\n\nfunction Kh(a, b) {\n th().memoizedState = [a, void 0 === b ? null : b];\n return a;\n}\n\nfunction Lh(a, b) {\n var c = uh();\n b = void 0 === b ? null : b;\n var d = c.memoizedState;\n if (null !== d && null !== b && nh(b, d[1])) return d[0];\n c.memoizedState = [a, b];\n return a;\n}\n\nfunction Mh(a, b) {\n var c = uh();\n b = void 0 === b ? null : b;\n var d = c.memoizedState;\n if (null !== d && null !== b && nh(b, d[1])) return d[0];\n a = a();\n c.memoizedState = [a, b];\n return a;\n}\n\nfunction Nh(a, b, c) {\n var d = ag();\n cg(98 > d ? 98 : d, function () {\n a(!0);\n });\n cg(97 < d ? 97 : d, function () {\n var d = kh.suspense;\n kh.suspense = void 0 === b ? null : b;\n\n try {\n a(!1), c();\n } finally {\n kh.suspense = d;\n }\n });\n}\n\nfunction zh(a, b, c) {\n var d = Gg(),\n e = Dg.suspense;\n d = Hg(d, a, e);\n e = {\n expirationTime: d,\n suspenseConfig: e,\n action: c,\n eagerReducer: null,\n eagerState: null,\n next: null\n };\n var f = b.pending;\n null === f ? e.next = e : (e.next = f.next, f.next = e);\n b.pending = e;\n f = a.alternate;\n if (a === N || null !== f && f === N) mh = !0, e.expirationTime = lh, N.expirationTime = lh;else {\n if (0 === a.expirationTime && (null === f || 0 === f.expirationTime) && (f = b.lastRenderedReducer, null !== f)) try {\n var g = b.lastRenderedState,\n h = f(g, c);\n e.eagerReducer = f;\n e.eagerState = h;\n if ($e(h, g)) return;\n } catch (k) {} finally {}\n Ig(a, d);\n }\n}\n\nvar sh = {\n readContext: sg,\n useCallback: Q,\n useContext: Q,\n useEffect: Q,\n useImperativeHandle: Q,\n useLayoutEffect: Q,\n useMemo: Q,\n useReducer: Q,\n useRef: Q,\n useState: Q,\n useDebugValue: Q,\n useResponder: Q,\n useDeferredValue: Q,\n useTransition: Q\n},\n ph = {\n readContext: sg,\n useCallback: Kh,\n useContext: sg,\n useEffect: Eh,\n useImperativeHandle: function useImperativeHandle(a, b, c) {\n c = null !== c && void 0 !== c ? c.concat([a]) : null;\n return Ch(4, 2, Hh.bind(null, b, a), c);\n },\n useLayoutEffect: function useLayoutEffect(a, b) {\n return Ch(4, 2, a, b);\n },\n useMemo: function useMemo(a, b) {\n var c = th();\n b = void 0 === b ? null : b;\n a = a();\n c.memoizedState = [a, b];\n return a;\n },\n useReducer: function useReducer(a, b, c) {\n var d = th();\n b = void 0 !== c ? c(b) : b;\n d.memoizedState = d.baseState = b;\n a = d.queue = {\n pending: null,\n dispatch: null,\n lastRenderedReducer: a,\n lastRenderedState: b\n };\n a = a.dispatch = zh.bind(null, N, a);\n return [d.memoizedState, a];\n },\n useRef: function useRef(a) {\n var b = th();\n a = {\n current: a\n };\n return b.memoizedState = a;\n },\n useState: yh,\n useDebugValue: Jh,\n useResponder: ih,\n useDeferredValue: function useDeferredValue(a, b) {\n var c = yh(a),\n d = c[0],\n e = c[1];\n Eh(function () {\n var c = kh.suspense;\n kh.suspense = void 0 === b ? null : b;\n\n try {\n e(a);\n } finally {\n kh.suspense = c;\n }\n }, [a, b]);\n return d;\n },\n useTransition: function useTransition(a) {\n var b = yh(!1),\n c = b[0];\n b = b[1];\n return [Kh(Nh.bind(null, b, a), [b, a]), c];\n }\n},\n qh = {\n readContext: sg,\n useCallback: Lh,\n useContext: sg,\n useEffect: Fh,\n useImperativeHandle: Ih,\n useLayoutEffect: Gh,\n useMemo: Mh,\n useReducer: wh,\n useRef: Bh,\n useState: function useState() {\n return wh(vh);\n },\n useDebugValue: Jh,\n useResponder: ih,\n useDeferredValue: function useDeferredValue(a, b) {\n var c = wh(vh),\n d = c[0],\n e = c[1];\n Fh(function () {\n var c = kh.suspense;\n kh.suspense = void 0 === b ? null : b;\n\n try {\n e(a);\n } finally {\n kh.suspense = c;\n }\n }, [a, b]);\n return d;\n },\n useTransition: function useTransition(a) {\n var b = wh(vh),\n c = b[0];\n b = b[1];\n return [Lh(Nh.bind(null, b, a), [b, a]), c];\n }\n},\n rh = {\n readContext: sg,\n useCallback: Lh,\n useContext: sg,\n useEffect: Fh,\n useImperativeHandle: Ih,\n useLayoutEffect: Gh,\n useMemo: Mh,\n useReducer: xh,\n useRef: Bh,\n useState: function useState() {\n return xh(vh);\n },\n useDebugValue: Jh,\n useResponder: ih,\n useDeferredValue: function useDeferredValue(a, b) {\n var c = xh(vh),\n d = c[0],\n e = c[1];\n Fh(function () {\n var c = kh.suspense;\n kh.suspense = void 0 === b ? null : b;\n\n try {\n e(a);\n } finally {\n kh.suspense = c;\n }\n }, [a, b]);\n return d;\n },\n useTransition: function useTransition(a) {\n var b = xh(vh),\n c = b[0];\n b = b[1];\n return [Lh(Nh.bind(null, b, a), [b, a]), c];\n }\n},\n Oh = null,\n Ph = null,\n Qh = !1;\n\nfunction Rh(a, b) {\n var c = Sh(5, null, null, 0);\n c.elementType = \"DELETED\";\n c.type = \"DELETED\";\n c.stateNode = b;\n c.return = a;\n c.effectTag = 8;\n null !== a.lastEffect ? (a.lastEffect.nextEffect = c, a.lastEffect = c) : a.firstEffect = a.lastEffect = c;\n}\n\nfunction Th(a, b) {\n switch (a.tag) {\n case 5:\n var c = a.type;\n b = 1 !== b.nodeType || c.toLowerCase() !== b.nodeName.toLowerCase() ? null : b;\n return null !== b ? (a.stateNode = b, !0) : !1;\n\n case 6:\n return b = \"\" === a.pendingProps || 3 !== b.nodeType ? null : b, null !== b ? (a.stateNode = b, !0) : !1;\n\n case 13:\n return !1;\n\n default:\n return !1;\n }\n}\n\nfunction Uh(a) {\n if (Qh) {\n var b = Ph;\n\n if (b) {\n var c = b;\n\n if (!Th(a, b)) {\n b = Jd(c.nextSibling);\n\n if (!b || !Th(a, b)) {\n a.effectTag = a.effectTag & -1025 | 2;\n Qh = !1;\n Oh = a;\n return;\n }\n\n Rh(Oh, c);\n }\n\n Oh = a;\n Ph = Jd(b.firstChild);\n } else a.effectTag = a.effectTag & -1025 | 2, Qh = !1, Oh = a;\n }\n}\n\nfunction Vh(a) {\n for (a = a.return; null !== a && 5 !== a.tag && 3 !== a.tag && 13 !== a.tag;) {\n a = a.return;\n }\n\n Oh = a;\n}\n\nfunction Wh(a) {\n if (a !== Oh) return !1;\n if (!Qh) return Vh(a), Qh = !0, !1;\n var b = a.type;\n if (5 !== a.tag || \"head\" !== b && \"body\" !== b && !Gd(b, a.memoizedProps)) for (b = Ph; b;) {\n Rh(a, b), b = Jd(b.nextSibling);\n }\n Vh(a);\n\n if (13 === a.tag) {\n a = a.memoizedState;\n a = null !== a ? a.dehydrated : null;\n if (!a) throw Error(u(317));\n\n a: {\n a = a.nextSibling;\n\n for (b = 0; a;) {\n if (8 === a.nodeType) {\n var c = a.data;\n\n if (c === Ad) {\n if (0 === b) {\n Ph = Jd(a.nextSibling);\n break a;\n }\n\n b--;\n } else c !== zd && c !== Cd && c !== Bd || b++;\n }\n\n a = a.nextSibling;\n }\n\n Ph = null;\n }\n } else Ph = Oh ? Jd(a.stateNode.nextSibling) : null;\n\n return !0;\n}\n\nfunction Xh() {\n Ph = Oh = null;\n Qh = !1;\n}\n\nvar Yh = Wa.ReactCurrentOwner,\n rg = !1;\n\nfunction R(a, b, c, d) {\n b.child = null === a ? Yg(b, null, c, d) : Xg(b, a.child, c, d);\n}\n\nfunction Zh(a, b, c, d, e) {\n c = c.render;\n var f = b.ref;\n qg(b, e);\n d = oh(a, b, c, d, f, e);\n if (null !== a && !rg) return b.updateQueue = a.updateQueue, b.effectTag &= -517, a.expirationTime <= e && (a.expirationTime = 0), $h(a, b, e);\n b.effectTag |= 1;\n R(a, b, d, e);\n return b.child;\n}\n\nfunction ai(a, b, c, d, e, f) {\n if (null === a) {\n var g = c.type;\n if (\"function\" === typeof g && !bi(g) && void 0 === g.defaultProps && null === c.compare && void 0 === c.defaultProps) return b.tag = 15, b.type = g, ci(a, b, g, d, e, f);\n a = Ug(c.type, null, d, null, b.mode, f);\n a.ref = b.ref;\n a.return = b;\n return b.child = a;\n }\n\n g = a.child;\n if (e < f && (e = g.memoizedProps, c = c.compare, c = null !== c ? c : bf, c(e, d) && a.ref === b.ref)) return $h(a, b, f);\n b.effectTag |= 1;\n a = Sg(g, d);\n a.ref = b.ref;\n a.return = b;\n return b.child = a;\n}\n\nfunction ci(a, b, c, d, e, f) {\n return null !== a && bf(a.memoizedProps, d) && a.ref === b.ref && (rg = !1, e < f) ? (b.expirationTime = a.expirationTime, $h(a, b, f)) : di(a, b, c, d, f);\n}\n\nfunction ei(a, b) {\n var c = b.ref;\n if (null === a && null !== c || null !== a && a.ref !== c) b.effectTag |= 128;\n}\n\nfunction di(a, b, c, d, e) {\n var f = L(c) ? Bf : J.current;\n f = Cf(b, f);\n qg(b, e);\n c = oh(a, b, c, d, f, e);\n if (null !== a && !rg) return b.updateQueue = a.updateQueue, b.effectTag &= -517, a.expirationTime <= e && (a.expirationTime = 0), $h(a, b, e);\n b.effectTag |= 1;\n R(a, b, c, e);\n return b.child;\n}\n\nfunction fi(a, b, c, d, e) {\n if (L(c)) {\n var f = !0;\n Gf(b);\n } else f = !1;\n\n qg(b, e);\n if (null === b.stateNode) null !== a && (a.alternate = null, b.alternate = null, b.effectTag |= 2), Lg(b, c, d), Ng(b, c, d, e), d = !0;else if (null === a) {\n var g = b.stateNode,\n h = b.memoizedProps;\n g.props = h;\n var k = g.context,\n l = c.contextType;\n \"object\" === typeof l && null !== l ? l = sg(l) : (l = L(c) ? Bf : J.current, l = Cf(b, l));\n var m = c.getDerivedStateFromProps,\n p = \"function\" === typeof m || \"function\" === typeof g.getSnapshotBeforeUpdate;\n p || \"function\" !== typeof g.UNSAFE_componentWillReceiveProps && \"function\" !== typeof g.componentWillReceiveProps || (h !== d || k !== l) && Mg(b, g, d, l);\n tg = !1;\n var x = b.memoizedState;\n g.state = x;\n zg(b, d, g, e);\n k = b.memoizedState;\n h !== d || x !== k || K.current || tg ? (\"function\" === typeof m && (Fg(b, c, m, d), k = b.memoizedState), (h = tg || Kg(b, c, h, d, x, k, l)) ? (p || \"function\" !== typeof g.UNSAFE_componentWillMount && \"function\" !== typeof g.componentWillMount || (\"function\" === typeof g.componentWillMount && g.componentWillMount(), \"function\" === typeof g.UNSAFE_componentWillMount && g.UNSAFE_componentWillMount()), \"function\" === typeof g.componentDidMount && (b.effectTag |= 4)) : (\"function\" === typeof g.componentDidMount && (b.effectTag |= 4), b.memoizedProps = d, b.memoizedState = k), g.props = d, g.state = k, g.context = l, d = h) : (\"function\" === typeof g.componentDidMount && (b.effectTag |= 4), d = !1);\n } else g = b.stateNode, vg(a, b), h = b.memoizedProps, g.props = b.type === b.elementType ? h : ig(b.type, h), k = g.context, l = c.contextType, \"object\" === typeof l && null !== l ? l = sg(l) : (l = L(c) ? Bf : J.current, l = Cf(b, l)), m = c.getDerivedStateFromProps, (p = \"function\" === typeof m || \"function\" === typeof g.getSnapshotBeforeUpdate) || \"function\" !== typeof g.UNSAFE_componentWillReceiveProps && \"function\" !== typeof g.componentWillReceiveProps || (h !== d || k !== l) && Mg(b, g, d, l), tg = !1, k = b.memoizedState, g.state = k, zg(b, d, g, e), x = b.memoizedState, h !== d || k !== x || K.current || tg ? (\"function\" === typeof m && (Fg(b, c, m, d), x = b.memoizedState), (m = tg || Kg(b, c, h, d, k, x, l)) ? (p || \"function\" !== typeof g.UNSAFE_componentWillUpdate && \"function\" !== typeof g.componentWillUpdate || (\"function\" === typeof g.componentWillUpdate && g.componentWillUpdate(d, x, l), \"function\" === typeof g.UNSAFE_componentWillUpdate && g.UNSAFE_componentWillUpdate(d, x, l)), \"function\" === typeof g.componentDidUpdate && (b.effectTag |= 4), \"function\" === typeof g.getSnapshotBeforeUpdate && (b.effectTag |= 256)) : (\"function\" !== typeof g.componentDidUpdate || h === a.memoizedProps && k === a.memoizedState || (b.effectTag |= 4), \"function\" !== typeof g.getSnapshotBeforeUpdate || h === a.memoizedProps && k === a.memoizedState || (b.effectTag |= 256), b.memoizedProps = d, b.memoizedState = x), g.props = d, g.state = x, g.context = l, d = m) : (\"function\" !== typeof g.componentDidUpdate || h === a.memoizedProps && k === a.memoizedState || (b.effectTag |= 4), \"function\" !== typeof g.getSnapshotBeforeUpdate || h === a.memoizedProps && k === a.memoizedState || (b.effectTag |= 256), d = !1);\n return gi(a, b, c, d, f, e);\n}\n\nfunction gi(a, b, c, d, e, f) {\n ei(a, b);\n var g = 0 !== (b.effectTag & 64);\n if (!d && !g) return e && Hf(b, c, !1), $h(a, b, f);\n d = b.stateNode;\n Yh.current = b;\n var h = g && \"function\" !== typeof c.getDerivedStateFromError ? null : d.render();\n b.effectTag |= 1;\n null !== a && g ? (b.child = Xg(b, a.child, null, f), b.child = Xg(b, null, h, f)) : R(a, b, h, f);\n b.memoizedState = d.state;\n e && Hf(b, c, !0);\n return b.child;\n}\n\nfunction hi(a) {\n var b = a.stateNode;\n b.pendingContext ? Ef(a, b.pendingContext, b.pendingContext !== b.context) : b.context && Ef(a, b.context, !1);\n dh(a, b.containerInfo);\n}\n\nvar ii = {\n dehydrated: null,\n retryTime: 0\n};\n\nfunction ji(a, b, c) {\n var d = b.mode,\n e = b.pendingProps,\n f = M.current,\n g = !1,\n h;\n (h = 0 !== (b.effectTag & 64)) || (h = 0 !== (f & 2) && (null === a || null !== a.memoizedState));\n h ? (g = !0, b.effectTag &= -65) : null !== a && null === a.memoizedState || void 0 === e.fallback || !0 === e.unstable_avoidThisFallback || (f |= 1);\n I(M, f & 1);\n\n if (null === a) {\n void 0 !== e.fallback && Uh(b);\n\n if (g) {\n g = e.fallback;\n e = Wg(null, d, 0, null);\n e.return = b;\n if (0 === (b.mode & 2)) for (a = null !== b.memoizedState ? b.child.child : b.child, e.child = a; null !== a;) {\n a.return = e, a = a.sibling;\n }\n c = Wg(g, d, c, null);\n c.return = b;\n e.sibling = c;\n b.memoizedState = ii;\n b.child = e;\n return c;\n }\n\n d = e.children;\n b.memoizedState = null;\n return b.child = Yg(b, null, d, c);\n }\n\n if (null !== a.memoizedState) {\n a = a.child;\n d = a.sibling;\n\n if (g) {\n e = e.fallback;\n c = Sg(a, a.pendingProps);\n c.return = b;\n if (0 === (b.mode & 2) && (g = null !== b.memoizedState ? b.child.child : b.child, g !== a.child)) for (c.child = g; null !== g;) {\n g.return = c, g = g.sibling;\n }\n d = Sg(d, e);\n d.return = b;\n c.sibling = d;\n c.childExpirationTime = 0;\n b.memoizedState = ii;\n b.child = c;\n return d;\n }\n\n c = Xg(b, a.child, e.children, c);\n b.memoizedState = null;\n return b.child = c;\n }\n\n a = a.child;\n\n if (g) {\n g = e.fallback;\n e = Wg(null, d, 0, null);\n e.return = b;\n e.child = a;\n null !== a && (a.return = e);\n if (0 === (b.mode & 2)) for (a = null !== b.memoizedState ? b.child.child : b.child, e.child = a; null !== a;) {\n a.return = e, a = a.sibling;\n }\n c = Wg(g, d, c, null);\n c.return = b;\n e.sibling = c;\n c.effectTag |= 2;\n e.childExpirationTime = 0;\n b.memoizedState = ii;\n b.child = e;\n return c;\n }\n\n b.memoizedState = null;\n return b.child = Xg(b, a, e.children, c);\n}\n\nfunction ki(a, b) {\n a.expirationTime < b && (a.expirationTime = b);\n var c = a.alternate;\n null !== c && c.expirationTime < b && (c.expirationTime = b);\n pg(a.return, b);\n}\n\nfunction li(a, b, c, d, e, f) {\n var g = a.memoizedState;\n null === g ? a.memoizedState = {\n isBackwards: b,\n rendering: null,\n renderingStartTime: 0,\n last: d,\n tail: c,\n tailExpiration: 0,\n tailMode: e,\n lastEffect: f\n } : (g.isBackwards = b, g.rendering = null, g.renderingStartTime = 0, g.last = d, g.tail = c, g.tailExpiration = 0, g.tailMode = e, g.lastEffect = f);\n}\n\nfunction mi(a, b, c) {\n var d = b.pendingProps,\n e = d.revealOrder,\n f = d.tail;\n R(a, b, d.children, c);\n d = M.current;\n if (0 !== (d & 2)) d = d & 1 | 2, b.effectTag |= 64;else {\n if (null !== a && 0 !== (a.effectTag & 64)) a: for (a = b.child; null !== a;) {\n if (13 === a.tag) null !== a.memoizedState && ki(a, c);else if (19 === a.tag) ki(a, c);else if (null !== a.child) {\n a.child.return = a;\n a = a.child;\n continue;\n }\n if (a === b) break a;\n\n for (; null === a.sibling;) {\n if (null === a.return || a.return === b) break a;\n a = a.return;\n }\n\n a.sibling.return = a.return;\n a = a.sibling;\n }\n d &= 1;\n }\n I(M, d);\n if (0 === (b.mode & 2)) b.memoizedState = null;else switch (e) {\n case \"forwards\":\n c = b.child;\n\n for (e = null; null !== c;) {\n a = c.alternate, null !== a && null === hh(a) && (e = c), c = c.sibling;\n }\n\n c = e;\n null === c ? (e = b.child, b.child = null) : (e = c.sibling, c.sibling = null);\n li(b, !1, e, c, f, b.lastEffect);\n break;\n\n case \"backwards\":\n c = null;\n e = b.child;\n\n for (b.child = null; null !== e;) {\n a = e.alternate;\n\n if (null !== a && null === hh(a)) {\n b.child = e;\n break;\n }\n\n a = e.sibling;\n e.sibling = c;\n c = e;\n e = a;\n }\n\n li(b, !0, c, null, f, b.lastEffect);\n break;\n\n case \"together\":\n li(b, !1, null, null, void 0, b.lastEffect);\n break;\n\n default:\n b.memoizedState = null;\n }\n return b.child;\n}\n\nfunction $h(a, b, c) {\n null !== a && (b.dependencies = a.dependencies);\n var d = b.expirationTime;\n 0 !== d && Bg(d);\n if (b.childExpirationTime < c) return null;\n if (null !== a && b.child !== a.child) throw Error(u(153));\n\n if (null !== b.child) {\n a = b.child;\n c = Sg(a, a.pendingProps);\n b.child = c;\n\n for (c.return = b; null !== a.sibling;) {\n a = a.sibling, c = c.sibling = Sg(a, a.pendingProps), c.return = b;\n }\n\n c.sibling = null;\n }\n\n return b.child;\n}\n\nvar ni, oi, pi, qi;\n\nni = function ni(a, b) {\n for (var c = b.child; null !== c;) {\n if (5 === c.tag || 6 === c.tag) a.appendChild(c.stateNode);else if (4 !== c.tag && null !== c.child) {\n c.child.return = c;\n c = c.child;\n continue;\n }\n if (c === b) break;\n\n for (; null === c.sibling;) {\n if (null === c.return || c.return === b) return;\n c = c.return;\n }\n\n c.sibling.return = c.return;\n c = c.sibling;\n }\n};\n\noi = function oi() {};\n\npi = function pi(a, b, c, d, e) {\n var f = a.memoizedProps;\n\n if (f !== d) {\n var g = b.stateNode;\n ch($g.current);\n a = null;\n\n switch (c) {\n case \"input\":\n f = zb(g, f);\n d = zb(g, d);\n a = [];\n break;\n\n case \"option\":\n f = Gb(g, f);\n d = Gb(g, d);\n a = [];\n break;\n\n case \"select\":\n f = n({}, f, {\n value: void 0\n });\n d = n({}, d, {\n value: void 0\n });\n a = [];\n break;\n\n case \"textarea\":\n f = Ib(g, f);\n d = Ib(g, d);\n a = [];\n break;\n\n default:\n \"function\" !== typeof f.onClick && \"function\" === typeof d.onClick && (g.onclick = sd);\n }\n\n od(c, d);\n var h, k;\n c = null;\n\n for (h in f) {\n if (!d.hasOwnProperty(h) && f.hasOwnProperty(h) && null != f[h]) if (\"style\" === h) for (k in g = f[h], g) {\n g.hasOwnProperty(k) && (c || (c = {}), c[k] = \"\");\n } else \"dangerouslySetInnerHTML\" !== h && \"children\" !== h && \"suppressContentEditableWarning\" !== h && \"suppressHydrationWarning\" !== h && \"autoFocus\" !== h && (va.hasOwnProperty(h) ? a || (a = []) : (a = a || []).push(h, null));\n }\n\n for (h in d) {\n var l = d[h];\n g = null != f ? f[h] : void 0;\n if (d.hasOwnProperty(h) && l !== g && (null != l || null != g)) if (\"style\" === h) {\n if (g) {\n for (k in g) {\n !g.hasOwnProperty(k) || l && l.hasOwnProperty(k) || (c || (c = {}), c[k] = \"\");\n }\n\n for (k in l) {\n l.hasOwnProperty(k) && g[k] !== l[k] && (c || (c = {}), c[k] = l[k]);\n }\n } else c || (a || (a = []), a.push(h, c)), c = l;\n } else \"dangerouslySetInnerHTML\" === h ? (l = l ? l.__html : void 0, g = g ? g.__html : void 0, null != l && g !== l && (a = a || []).push(h, l)) : \"children\" === h ? g === l || \"string\" !== typeof l && \"number\" !== typeof l || (a = a || []).push(h, \"\" + l) : \"suppressContentEditableWarning\" !== h && \"suppressHydrationWarning\" !== h && (va.hasOwnProperty(h) ? (null != l && rd(e, h), a || g === l || (a = [])) : (a = a || []).push(h, l));\n }\n\n c && (a = a || []).push(\"style\", c);\n e = a;\n if (b.updateQueue = e) b.effectTag |= 4;\n }\n};\n\nqi = function qi(a, b, c, d) {\n c !== d && (b.effectTag |= 4);\n};\n\nfunction ri(a, b) {\n switch (a.tailMode) {\n case \"hidden\":\n b = a.tail;\n\n for (var c = null; null !== b;) {\n null !== b.alternate && (c = b), b = b.sibling;\n }\n\n null === c ? a.tail = null : c.sibling = null;\n break;\n\n case \"collapsed\":\n c = a.tail;\n\n for (var d = null; null !== c;) {\n null !== c.alternate && (d = c), c = c.sibling;\n }\n\n null === d ? b || null === a.tail ? a.tail = null : a.tail.sibling = null : d.sibling = null;\n }\n}\n\nfunction si(a, b, c) {\n var d = b.pendingProps;\n\n switch (b.tag) {\n case 2:\n case 16:\n case 15:\n case 0:\n case 11:\n case 7:\n case 8:\n case 12:\n case 9:\n case 14:\n return null;\n\n case 1:\n return L(b.type) && Df(), null;\n\n case 3:\n return eh(), H(K), H(J), c = b.stateNode, c.pendingContext && (c.context = c.pendingContext, c.pendingContext = null), null !== a && null !== a.child || !Wh(b) || (b.effectTag |= 4), oi(b), null;\n\n case 5:\n gh(b);\n c = ch(bh.current);\n var e = b.type;\n if (null !== a && null != b.stateNode) pi(a, b, e, d, c), a.ref !== b.ref && (b.effectTag |= 128);else {\n if (!d) {\n if (null === b.stateNode) throw Error(u(166));\n return null;\n }\n\n a = ch($g.current);\n\n if (Wh(b)) {\n d = b.stateNode;\n e = b.type;\n var f = b.memoizedProps;\n d[Md] = b;\n d[Nd] = f;\n\n switch (e) {\n case \"iframe\":\n case \"object\":\n case \"embed\":\n F(\"load\", d);\n break;\n\n case \"video\":\n case \"audio\":\n for (a = 0; a < ac.length; a++) {\n F(ac[a], d);\n }\n\n break;\n\n case \"source\":\n F(\"error\", d);\n break;\n\n case \"img\":\n case \"image\":\n case \"link\":\n F(\"error\", d);\n F(\"load\", d);\n break;\n\n case \"form\":\n F(\"reset\", d);\n F(\"submit\", d);\n break;\n\n case \"details\":\n F(\"toggle\", d);\n break;\n\n case \"input\":\n Ab(d, f);\n F(\"invalid\", d);\n rd(c, \"onChange\");\n break;\n\n case \"select\":\n d._wrapperState = {\n wasMultiple: !!f.multiple\n };\n F(\"invalid\", d);\n rd(c, \"onChange\");\n break;\n\n case \"textarea\":\n Jb(d, f), F(\"invalid\", d), rd(c, \"onChange\");\n }\n\n od(e, f);\n a = null;\n\n for (var g in f) {\n if (f.hasOwnProperty(g)) {\n var h = f[g];\n \"children\" === g ? \"string\" === typeof h ? d.textContent !== h && (a = [\"children\", h]) : \"number\" === typeof h && d.textContent !== \"\" + h && (a = [\"children\", \"\" + h]) : va.hasOwnProperty(g) && null != h && rd(c, g);\n }\n }\n\n switch (e) {\n case \"input\":\n xb(d);\n Eb(d, f, !0);\n break;\n\n case \"textarea\":\n xb(d);\n Lb(d);\n break;\n\n case \"select\":\n case \"option\":\n break;\n\n default:\n \"function\" === typeof f.onClick && (d.onclick = sd);\n }\n\n c = a;\n b.updateQueue = c;\n null !== c && (b.effectTag |= 4);\n } else {\n g = 9 === c.nodeType ? c : c.ownerDocument;\n a === qd && (a = Nb(e));\n a === qd ? \"script\" === e ? (a = g.createElement(\"div\"), a.innerHTML = \"