c') !== 'bc';\n});\n","var isObject = require('../internals/is-object');\nvar classof = require('../internals/classof-raw');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar MATCH = wellKnownSymbol('match');\n\n// `IsRegExp` abstract operation\n// https://tc39.es/ecma262/#sec-isregexp\nmodule.exports = function (it) {\n var isRegExp;\n return isObject(it) && ((isRegExp = it[MATCH]) !== undefined ? !!isRegExp : classof(it) == 'RegExp');\n};\n","var anObject = require('../internals/an-object');\nvar aConstructor = require('../internals/a-constructor');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar SPECIES = wellKnownSymbol('species');\n\n// `SpeciesConstructor` abstract operation\n// https://tc39.es/ecma262/#sec-speciesconstructor\nmodule.exports = function (O, defaultConstructor) {\n var C = anObject(O).constructor;\n var S;\n return C === undefined || (S = anObject(C)[SPECIES]) == undefined ? defaultConstructor : aConstructor(S);\n};\n","var isConstructor = require('../internals/is-constructor');\nvar tryToString = require('../internals/try-to-string');\n\nvar $TypeError = TypeError;\n\n// `Assert: IsConstructor(argument) is true`\nmodule.exports = function (argument) {\n if (isConstructor(argument)) return argument;\n throw $TypeError(tryToString(argument) + ' is not a constructor');\n};\n","var $TypeError = TypeError;\nvar MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF; // 2 ** 53 - 1 == 9007199254740991\n\nmodule.exports = function (it) {\n if (it > MAX_SAFE_INTEGER) throw $TypeError('Maximum allowed index exceeded');\n return it;\n};\n","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar IS_PURE = require('../internals/is-pure');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar NATIVE_SYMBOL = require('../internals/native-symbol');\nvar fails = require('../internals/fails');\nvar hasOwn = require('../internals/has-own-property');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar anObject = require('../internals/an-object');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar toPropertyKey = require('../internals/to-property-key');\nvar $toString = require('../internals/to-string');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar nativeObjectCreate = require('../internals/object-create');\nvar objectKeys = require('../internals/object-keys');\nvar getOwnPropertyNamesModule = require('../internals/object-get-own-property-names');\nvar getOwnPropertyNamesExternal = require('../internals/object-get-own-property-names-external');\nvar getOwnPropertySymbolsModule = require('../internals/object-get-own-property-symbols');\nvar getOwnPropertyDescriptorModule = require('../internals/object-get-own-property-descriptor');\nvar definePropertyModule = require('../internals/object-define-property');\nvar definePropertiesModule = require('../internals/object-define-properties');\nvar propertyIsEnumerableModule = require('../internals/object-property-is-enumerable');\nvar defineBuiltIn = require('../internals/define-built-in');\nvar shared = require('../internals/shared');\nvar sharedKey = require('../internals/shared-key');\nvar hiddenKeys = require('../internals/hidden-keys');\nvar uid = require('../internals/uid');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar wrappedWellKnownSymbolModule = require('../internals/well-known-symbol-wrapped');\nvar defineWellKnownSymbol = require('../internals/define-well-known-symbol');\nvar defineSymbolToPrimitive = require('../internals/symbol-define-to-primitive');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar InternalStateModule = require('../internals/internal-state');\nvar $forEach = require('../internals/array-iteration').forEach;\n\nvar HIDDEN = sharedKey('hidden');\nvar SYMBOL = 'Symbol';\nvar PROTOTYPE = 'prototype';\n\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(SYMBOL);\n\nvar ObjectPrototype = Object[PROTOTYPE];\nvar $Symbol = global.Symbol;\nvar SymbolPrototype = $Symbol && $Symbol[PROTOTYPE];\nvar TypeError = global.TypeError;\nvar QObject = global.QObject;\nvar nativeGetOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\nvar nativeDefineProperty = definePropertyModule.f;\nvar nativeGetOwnPropertyNames = getOwnPropertyNamesExternal.f;\nvar nativePropertyIsEnumerable = propertyIsEnumerableModule.f;\nvar push = uncurryThis([].push);\n\nvar AllSymbols = shared('symbols');\nvar ObjectPrototypeSymbols = shared('op-symbols');\nvar WellKnownSymbolsStore = shared('wks');\n\n// Don't use setters in Qt Script, https://github.com/zloirock/core-js/issues/173\nvar USE_SETTER = !QObject || !QObject[PROTOTYPE] || !QObject[PROTOTYPE].findChild;\n\n// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687\nvar setSymbolDescriptor = DESCRIPTORS && fails(function () {\n return nativeObjectCreate(nativeDefineProperty({}, 'a', {\n get: function () { return nativeDefineProperty(this, 'a', { value: 7 }).a; }\n })).a != 7;\n}) ? function (O, P, Attributes) {\n var ObjectPrototypeDescriptor = nativeGetOwnPropertyDescriptor(ObjectPrototype, P);\n if (ObjectPrototypeDescriptor) delete ObjectPrototype[P];\n nativeDefineProperty(O, P, Attributes);\n if (ObjectPrototypeDescriptor && O !== ObjectPrototype) {\n nativeDefineProperty(ObjectPrototype, P, ObjectPrototypeDescriptor);\n }\n} : nativeDefineProperty;\n\nvar wrap = function (tag, description) {\n var symbol = AllSymbols[tag] = nativeObjectCreate(SymbolPrototype);\n setInternalState(symbol, {\n type: SYMBOL,\n tag: tag,\n description: description\n });\n if (!DESCRIPTORS) symbol.description = description;\n return symbol;\n};\n\nvar $defineProperty = function defineProperty(O, P, Attributes) {\n if (O === ObjectPrototype) $defineProperty(ObjectPrototypeSymbols, P, Attributes);\n anObject(O);\n var key = toPropertyKey(P);\n anObject(Attributes);\n if (hasOwn(AllSymbols, key)) {\n if (!Attributes.enumerable) {\n if (!hasOwn(O, HIDDEN)) nativeDefineProperty(O, HIDDEN, createPropertyDescriptor(1, {}));\n O[HIDDEN][key] = true;\n } else {\n if (hasOwn(O, HIDDEN) && O[HIDDEN][key]) O[HIDDEN][key] = false;\n Attributes = nativeObjectCreate(Attributes, { enumerable: createPropertyDescriptor(0, false) });\n } return setSymbolDescriptor(O, key, Attributes);\n } return nativeDefineProperty(O, key, Attributes);\n};\n\nvar $defineProperties = function defineProperties(O, Properties) {\n anObject(O);\n var properties = toIndexedObject(Properties);\n var keys = objectKeys(properties).concat($getOwnPropertySymbols(properties));\n $forEach(keys, function (key) {\n if (!DESCRIPTORS || call($propertyIsEnumerable, properties, key)) $defineProperty(O, key, properties[key]);\n });\n return O;\n};\n\nvar $create = function create(O, Properties) {\n return Properties === undefined ? nativeObjectCreate(O) : $defineProperties(nativeObjectCreate(O), Properties);\n};\n\nvar $propertyIsEnumerable = function propertyIsEnumerable(V) {\n var P = toPropertyKey(V);\n var enumerable = call(nativePropertyIsEnumerable, this, P);\n if (this === ObjectPrototype && hasOwn(AllSymbols, P) && !hasOwn(ObjectPrototypeSymbols, P)) return false;\n return enumerable || !hasOwn(this, P) || !hasOwn(AllSymbols, P) || hasOwn(this, HIDDEN) && this[HIDDEN][P]\n ? enumerable : true;\n};\n\nvar $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(O, P) {\n var it = toIndexedObject(O);\n var key = toPropertyKey(P);\n if (it === ObjectPrototype && hasOwn(AllSymbols, key) && !hasOwn(ObjectPrototypeSymbols, key)) return;\n var descriptor = nativeGetOwnPropertyDescriptor(it, key);\n if (descriptor && hasOwn(AllSymbols, key) && !(hasOwn(it, HIDDEN) && it[HIDDEN][key])) {\n descriptor.enumerable = true;\n }\n return descriptor;\n};\n\nvar $getOwnPropertyNames = function getOwnPropertyNames(O) {\n var names = nativeGetOwnPropertyNames(toIndexedObject(O));\n var result = [];\n $forEach(names, function (key) {\n if (!hasOwn(AllSymbols, key) && !hasOwn(hiddenKeys, key)) push(result, key);\n });\n return result;\n};\n\nvar $getOwnPropertySymbols = function (O) {\n var IS_OBJECT_PROTOTYPE = O === ObjectPrototype;\n var names = nativeGetOwnPropertyNames(IS_OBJECT_PROTOTYPE ? ObjectPrototypeSymbols : toIndexedObject(O));\n var result = [];\n $forEach(names, function (key) {\n if (hasOwn(AllSymbols, key) && (!IS_OBJECT_PROTOTYPE || hasOwn(ObjectPrototype, key))) {\n push(result, AllSymbols[key]);\n }\n });\n return result;\n};\n\n// `Symbol` constructor\n// https://tc39.es/ecma262/#sec-symbol-constructor\nif (!NATIVE_SYMBOL) {\n $Symbol = function Symbol() {\n if (isPrototypeOf(SymbolPrototype, this)) throw TypeError('Symbol is not a constructor');\n var description = !arguments.length || arguments[0] === undefined ? undefined : $toString(arguments[0]);\n var tag = uid(description);\n var setter = function (value) {\n if (this === ObjectPrototype) call(setter, ObjectPrototypeSymbols, value);\n if (hasOwn(this, HIDDEN) && hasOwn(this[HIDDEN], tag)) this[HIDDEN][tag] = false;\n setSymbolDescriptor(this, tag, createPropertyDescriptor(1, value));\n };\n if (DESCRIPTORS && USE_SETTER) setSymbolDescriptor(ObjectPrototype, tag, { configurable: true, set: setter });\n return wrap(tag, description);\n };\n\n SymbolPrototype = $Symbol[PROTOTYPE];\n\n defineBuiltIn(SymbolPrototype, 'toString', function toString() {\n return getInternalState(this).tag;\n });\n\n defineBuiltIn($Symbol, 'withoutSetter', function (description) {\n return wrap(uid(description), description);\n });\n\n propertyIsEnumerableModule.f = $propertyIsEnumerable;\n definePropertyModule.f = $defineProperty;\n definePropertiesModule.f = $defineProperties;\n getOwnPropertyDescriptorModule.f = $getOwnPropertyDescriptor;\n getOwnPropertyNamesModule.f = getOwnPropertyNamesExternal.f = $getOwnPropertyNames;\n getOwnPropertySymbolsModule.f = $getOwnPropertySymbols;\n\n wrappedWellKnownSymbolModule.f = function (name) {\n return wrap(wellKnownSymbol(name), name);\n };\n\n if (DESCRIPTORS) {\n // https://github.com/tc39/proposal-Symbol-description\n nativeDefineProperty(SymbolPrototype, 'description', {\n configurable: true,\n get: function description() {\n return getInternalState(this).description;\n }\n });\n if (!IS_PURE) {\n defineBuiltIn(ObjectPrototype, 'propertyIsEnumerable', $propertyIsEnumerable, { unsafe: true });\n }\n }\n}\n\n$({ global: true, constructor: true, wrap: true, forced: !NATIVE_SYMBOL, sham: !NATIVE_SYMBOL }, {\n Symbol: $Symbol\n});\n\n$forEach(objectKeys(WellKnownSymbolsStore), function (name) {\n defineWellKnownSymbol(name);\n});\n\n$({ target: SYMBOL, stat: true, forced: !NATIVE_SYMBOL }, {\n useSetter: function () { USE_SETTER = true; },\n useSimple: function () { USE_SETTER = false; }\n});\n\n$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL, sham: !DESCRIPTORS }, {\n // `Object.create` method\n // https://tc39.es/ecma262/#sec-object.create\n create: $create,\n // `Object.defineProperty` method\n // https://tc39.es/ecma262/#sec-object.defineproperty\n defineProperty: $defineProperty,\n // `Object.defineProperties` method\n // https://tc39.es/ecma262/#sec-object.defineproperties\n defineProperties: $defineProperties,\n // `Object.getOwnPropertyDescriptor` method\n // https://tc39.es/ecma262/#sec-object.getownpropertydescriptors\n getOwnPropertyDescriptor: $getOwnPropertyDescriptor\n});\n\n$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL }, {\n // `Object.getOwnPropertyNames` method\n // https://tc39.es/ecma262/#sec-object.getownpropertynames\n getOwnPropertyNames: $getOwnPropertyNames\n});\n\n// `Symbol.prototype[@@toPrimitive]` method\n// https://tc39.es/ecma262/#sec-symbol.prototype-@@toprimitive\ndefineSymbolToPrimitive();\n\n// `Symbol.prototype[@@toStringTag]` property\n// https://tc39.es/ecma262/#sec-symbol.prototype-@@tostringtag\nsetToStringTag($Symbol, SYMBOL);\n\nhiddenKeys[HIDDEN] = true;\n","/* eslint-disable es-x/no-object-getownpropertynames -- safe */\nvar classof = require('../internals/classof-raw');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar $getOwnPropertyNames = require('../internals/object-get-own-property-names').f;\nvar arraySlice = require('../internals/array-slice-simple');\n\nvar windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames\n ? Object.getOwnPropertyNames(window) : [];\n\nvar getWindowNames = function (it) {\n try {\n return $getOwnPropertyNames(it);\n } catch (error) {\n return arraySlice(windowNames);\n }\n};\n\n// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window\nmodule.exports.f = function getOwnPropertyNames(it) {\n return windowNames && classof(it) == 'Window'\n ? getWindowNames(it)\n : $getOwnPropertyNames(toIndexedObject(it));\n};\n","var global = require('../internals/global');\n\nmodule.exports = global;\n","var call = require('../internals/function-call');\nvar getBuiltIn = require('../internals/get-built-in');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar defineBuiltIn = require('../internals/define-built-in');\n\nmodule.exports = function () {\n var Symbol = getBuiltIn('Symbol');\n var SymbolPrototype = Symbol && Symbol.prototype;\n var valueOf = SymbolPrototype && SymbolPrototype.valueOf;\n var TO_PRIMITIVE = wellKnownSymbol('toPrimitive');\n\n if (SymbolPrototype && !SymbolPrototype[TO_PRIMITIVE]) {\n // `Symbol.prototype[@@toPrimitive]` method\n // https://tc39.es/ecma262/#sec-symbol.prototype-@@toprimitive\n // eslint-disable-next-line no-unused-vars -- required for .length\n defineBuiltIn(SymbolPrototype, TO_PRIMITIVE, function (hint) {\n return call(valueOf, this);\n }, { arity: 1 });\n }\n};\n","var $ = require('../internals/export');\nvar getBuiltIn = require('../internals/get-built-in');\nvar hasOwn = require('../internals/has-own-property');\nvar toString = require('../internals/to-string');\nvar shared = require('../internals/shared');\nvar NATIVE_SYMBOL_REGISTRY = require('../internals/native-symbol-registry');\n\nvar StringToSymbolRegistry = shared('string-to-symbol-registry');\nvar SymbolToStringRegistry = shared('symbol-to-string-registry');\n\n// `Symbol.for` method\n// https://tc39.es/ecma262/#sec-symbol.for\n$({ target: 'Symbol', stat: true, forced: !NATIVE_SYMBOL_REGISTRY }, {\n 'for': function (key) {\n var string = toString(key);\n if (hasOwn(StringToSymbolRegistry, string)) return StringToSymbolRegistry[string];\n var symbol = getBuiltIn('Symbol')(string);\n StringToSymbolRegistry[string] = symbol;\n SymbolToStringRegistry[symbol] = string;\n return symbol;\n }\n});\n","var $ = require('../internals/export');\nvar hasOwn = require('../internals/has-own-property');\nvar isSymbol = require('../internals/is-symbol');\nvar tryToString = require('../internals/try-to-string');\nvar shared = require('../internals/shared');\nvar NATIVE_SYMBOL_REGISTRY = require('../internals/native-symbol-registry');\n\nvar SymbolToStringRegistry = shared('symbol-to-string-registry');\n\n// `Symbol.keyFor` method\n// https://tc39.es/ecma262/#sec-symbol.keyfor\n$({ target: 'Symbol', stat: true, forced: !NATIVE_SYMBOL_REGISTRY }, {\n keyFor: function keyFor(sym) {\n if (!isSymbol(sym)) throw TypeError(tryToString(sym) + ' is not a symbol');\n if (hasOwn(SymbolToStringRegistry, sym)) return SymbolToStringRegistry[sym];\n }\n});\n","var $ = require('../internals/export');\nvar getBuiltIn = require('../internals/get-built-in');\nvar apply = require('../internals/function-apply');\nvar call = require('../internals/function-call');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\nvar isArray = require('../internals/is-array');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar isSymbol = require('../internals/is-symbol');\nvar arraySlice = require('../internals/array-slice');\nvar NATIVE_SYMBOL = require('../internals/native-symbol');\n\nvar $stringify = getBuiltIn('JSON', 'stringify');\nvar exec = uncurryThis(/./.exec);\nvar charAt = uncurryThis(''.charAt);\nvar charCodeAt = uncurryThis(''.charCodeAt);\nvar replace = uncurryThis(''.replace);\nvar numberToString = uncurryThis(1.0.toString);\n\nvar tester = /[\\uD800-\\uDFFF]/g;\nvar low = /^[\\uD800-\\uDBFF]$/;\nvar hi = /^[\\uDC00-\\uDFFF]$/;\n\nvar WRONG_SYMBOLS_CONVERSION = !NATIVE_SYMBOL || fails(function () {\n var symbol = getBuiltIn('Symbol')();\n // MS Edge converts symbol values to JSON as {}\n return $stringify([symbol]) != '[null]'\n // WebKit converts symbol values to JSON as null\n || $stringify({ a: symbol }) != '{}'\n // V8 throws on boxed symbols\n || $stringify(Object(symbol)) != '{}';\n});\n\n// https://github.com/tc39/proposal-well-formed-stringify\nvar ILL_FORMED_UNICODE = fails(function () {\n return $stringify('\\uDF06\\uD834') !== '\"\\\\udf06\\\\ud834\"'\n || $stringify('\\uDEAD') !== '\"\\\\udead\"';\n});\n\nvar stringifyWithSymbolsFix = function (it, replacer) {\n var args = arraySlice(arguments);\n var $replacer = replacer;\n if (!isObject(replacer) && it === undefined || isSymbol(it)) return; // IE8 returns string on undefined\n if (!isArray(replacer)) replacer = function (key, value) {\n if (isCallable($replacer)) value = call($replacer, this, key, value);\n if (!isSymbol(value)) return value;\n };\n args[1] = replacer;\n return apply($stringify, null, args);\n};\n\nvar fixIllFormed = function (match, offset, string) {\n var prev = charAt(string, offset - 1);\n var next = charAt(string, offset + 1);\n if ((exec(low, match) && !exec(hi, next)) || (exec(hi, match) && !exec(low, prev))) {\n return '\\\\u' + numberToString(charCodeAt(match, 0), 16);\n } return match;\n};\n\nif ($stringify) {\n // `JSON.stringify` method\n // https://tc39.es/ecma262/#sec-json.stringify\n $({ target: 'JSON', stat: true, arity: 3, forced: WRONG_SYMBOLS_CONVERSION || ILL_FORMED_UNICODE }, {\n // eslint-disable-next-line no-unused-vars -- required for `.length`\n stringify: function stringify(it, replacer, space) {\n var args = arraySlice(arguments);\n var result = apply(WRONG_SYMBOLS_CONVERSION ? stringifyWithSymbolsFix : $stringify, null, args);\n return ILL_FORMED_UNICODE && typeof result == 'string' ? replace(result, tester, fixIllFormed) : result;\n }\n });\n}\n","var $ = require('../internals/export');\nvar NATIVE_SYMBOL = require('../internals/native-symbol');\nvar fails = require('../internals/fails');\nvar getOwnPropertySymbolsModule = require('../internals/object-get-own-property-symbols');\nvar toObject = require('../internals/to-object');\n\n// V8 ~ Chrome 38 and 39 `Object.getOwnPropertySymbols` fails on primitives\n// https://bugs.chromium.org/p/v8/issues/detail?id=3443\nvar FORCED = !NATIVE_SYMBOL || fails(function () { getOwnPropertySymbolsModule.f(1); });\n\n// `Object.getOwnPropertySymbols` method\n// https://tc39.es/ecma262/#sec-object.getownpropertysymbols\n$({ target: 'Object', stat: true, forced: FORCED }, {\n getOwnPropertySymbols: function getOwnPropertySymbols(it) {\n var $getOwnPropertySymbols = getOwnPropertySymbolsModule.f;\n return $getOwnPropertySymbols ? $getOwnPropertySymbols(toObject(it)) : [];\n }\n});\n","'use strict';\nvar bind = require('../internals/function-bind-context');\nvar call = require('../internals/function-call');\nvar toObject = require('../internals/to-object');\nvar callWithSafeIterationClosing = require('../internals/call-with-safe-iteration-closing');\nvar isArrayIteratorMethod = require('../internals/is-array-iterator-method');\nvar isConstructor = require('../internals/is-constructor');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar createProperty = require('../internals/create-property');\nvar getIterator = require('../internals/get-iterator');\nvar getIteratorMethod = require('../internals/get-iterator-method');\n\nvar $Array = Array;\n\n// `Array.from` method implementation\n// https://tc39.es/ecma262/#sec-array.from\nmodule.exports = function from(arrayLike /* , mapfn = undefined, thisArg = undefined */) {\n var O = toObject(arrayLike);\n var IS_CONSTRUCTOR = isConstructor(this);\n var argumentsLength = arguments.length;\n var mapfn = argumentsLength > 1 ? arguments[1] : undefined;\n var mapping = mapfn !== undefined;\n if (mapping) mapfn = bind(mapfn, argumentsLength > 2 ? arguments[2] : undefined);\n var iteratorMethod = getIteratorMethod(O);\n var index = 0;\n var length, result, step, iterator, next, value;\n // if the target is not iterable or it's an array with the default iterator - use a simple case\n if (iteratorMethod && !(this === $Array && isArrayIteratorMethod(iteratorMethod))) {\n iterator = getIterator(O, iteratorMethod);\n next = iterator.next;\n result = IS_CONSTRUCTOR ? new this() : [];\n for (;!(step = call(next, iterator)).done; index++) {\n value = mapping ? callWithSafeIterationClosing(iterator, mapfn, [step.value, index], true) : step.value;\n createProperty(result, index, value);\n }\n } else {\n length = lengthOfArrayLike(O);\n result = IS_CONSTRUCTOR ? new this(length) : $Array(length);\n for (;length > index; index++) {\n value = mapping ? mapfn(O[index], index) : O[index];\n createProperty(result, index, value);\n }\n }\n result.length = index;\n return result;\n};\n","var anObject = require('../internals/an-object');\nvar iteratorClose = require('../internals/iterator-close');\n\n// call something on iterator step with safe closing on error\nmodule.exports = function (iterator, fn, value, ENTRIES) {\n try {\n return ENTRIES ? fn(anObject(value)[0], value[1]) : fn(value);\n } catch (error) {\n iteratorClose(iterator, 'throw', error);\n }\n};\n","var call = require('../internals/function-call');\nvar anObject = require('../internals/an-object');\nvar getMethod = require('../internals/get-method');\n\nmodule.exports = function (iterator, kind, value) {\n var innerResult, innerError;\n anObject(iterator);\n try {\n innerResult = getMethod(iterator, 'return');\n if (!innerResult) {\n if (kind === 'throw') throw value;\n return value;\n }\n innerResult = call(innerResult, iterator);\n } catch (error) {\n innerError = true;\n innerResult = error;\n }\n if (kind === 'throw') throw value;\n if (innerError) throw innerResult;\n anObject(innerResult);\n return value;\n};\n","var wellKnownSymbol = require('../internals/well-known-symbol');\nvar Iterators = require('../internals/iterators');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar ArrayPrototype = Array.prototype;\n\n// check on default Array iterator\nmodule.exports = function (it) {\n return it !== undefined && (Iterators.Array === it || ArrayPrototype[ITERATOR] === it);\n};\n","var call = require('../internals/function-call');\nvar aCallable = require('../internals/a-callable');\nvar anObject = require('../internals/an-object');\nvar tryToString = require('../internals/try-to-string');\nvar getIteratorMethod = require('../internals/get-iterator-method');\n\nvar $TypeError = TypeError;\n\nmodule.exports = function (argument, usingIterator) {\n var iteratorMethod = arguments.length < 2 ? getIteratorMethod(argument) : usingIterator;\n if (aCallable(iteratorMethod)) return anObject(call(iteratorMethod, argument));\n throw $TypeError(tryToString(argument) + ' is not iterable');\n};\n","var wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar SAFE_CLOSING = false;\n\ntry {\n var called = 0;\n var iteratorWithReturn = {\n next: function () {\n return { done: !!called++ };\n },\n 'return': function () {\n SAFE_CLOSING = true;\n }\n };\n iteratorWithReturn[ITERATOR] = function () {\n return this;\n };\n // eslint-disable-next-line es-x/no-array-from, no-throw-literal -- required for testing\n Array.from(iteratorWithReturn, function () { throw 2; });\n} catch (error) { /* empty */ }\n\nmodule.exports = function (exec, SKIP_CLOSING) {\n if (!SKIP_CLOSING && !SAFE_CLOSING) return false;\n var ITERATION_SUPPORT = false;\n try {\n var object = {};\n object[ITERATOR] = function () {\n return {\n next: function () {\n return { done: ITERATION_SUPPORT = true };\n }\n };\n };\n exec(object);\n } catch (error) { /* empty */ }\n return ITERATION_SUPPORT;\n};\n","'use strict';\nvar IteratorPrototype = require('../internals/iterators-core').IteratorPrototype;\nvar create = require('../internals/object-create');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar Iterators = require('../internals/iterators');\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (IteratorConstructor, NAME, next, ENUMERABLE_NEXT) {\n var TO_STRING_TAG = NAME + ' Iterator';\n IteratorConstructor.prototype = create(IteratorPrototype, { next: createPropertyDescriptor(+!ENUMERABLE_NEXT, next) });\n setToStringTag(IteratorConstructor, TO_STRING_TAG, false, true);\n Iterators[TO_STRING_TAG] = returnThis;\n return IteratorConstructor;\n};\n","var fails = require('../internals/fails');\n\nmodule.exports = !fails(function () {\n function F() { /* empty */ }\n F.prototype.constructor = null;\n // eslint-disable-next-line es-x/no-object-getprototypeof -- required for testing\n return Object.getPrototypeOf(new F()) !== F.prototype;\n});\n","/* eslint-disable no-proto -- safe */\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar anObject = require('../internals/an-object');\nvar aPossiblePrototype = require('../internals/a-possible-prototype');\n\n// `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-x/no-object-setprototypeof -- safe\nmodule.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {\n var CORRECT_SETTER = false;\n var test = {};\n var setter;\n try {\n // eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe\n setter = uncurryThis(Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set);\n setter(test, []);\n CORRECT_SETTER = test instanceof Array;\n } catch (error) { /* empty */ }\n return function setPrototypeOf(O, proto) {\n anObject(O);\n aPossiblePrototype(proto);\n if (CORRECT_SETTER) setter(O, proto);\n else O.__proto__ = proto;\n return O;\n };\n}() : undefined);\n","var isCallable = require('../internals/is-callable');\n\nvar $String = String;\nvar $TypeError = TypeError;\n\nmodule.exports = function (argument) {\n if (typeof argument == 'object' || isCallable(argument)) return argument;\n throw $TypeError(\"Can't set \" + $String(argument) + ' as a prototype');\n};\n","var $ = require('../internals/export');\nvar global = require('../internals/global');\nvar setInterval = require('../internals/schedulers-fix').setInterval;\n\n// ie9- setInterval additional parameters fix\n// https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#dom-setinterval\n$({ global: true, bind: true, forced: global.setInterval !== setInterval }, {\n setInterval: setInterval\n});\n","var $TypeError = TypeError;\n\nmodule.exports = function (passed, required) {\n if (passed < required) throw $TypeError('Not enough arguments');\n return passed;\n};\n","var $ = require('../internals/export');\nvar global = require('../internals/global');\nvar setTimeout = require('../internals/schedulers-fix').setTimeout;\n\n// ie9- setTimeout additional parameters fix\n// https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#dom-settimeout\n$({ global: true, bind: true, forced: global.setTimeout !== setTimeout }, {\n setTimeout: setTimeout\n});\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar toObject = require('../internals/to-object');\n\nvar floor = Math.floor;\nvar charAt = uncurryThis(''.charAt);\nvar replace = uncurryThis(''.replace);\nvar stringSlice = uncurryThis(''.slice);\nvar SUBSTITUTION_SYMBOLS = /\\$([$&'`]|\\d{1,2}|<[^>]*>)/g;\nvar SUBSTITUTION_SYMBOLS_NO_NAMED = /\\$([$&'`]|\\d{1,2})/g;\n\n// `GetSubstitution` abstract operation\n// https://tc39.es/ecma262/#sec-getsubstitution\nmodule.exports = function (matched, str, position, captures, namedCaptures, replacement) {\n var tailPos = position + matched.length;\n var m = captures.length;\n var symbols = SUBSTITUTION_SYMBOLS_NO_NAMED;\n if (namedCaptures !== undefined) {\n namedCaptures = toObject(namedCaptures);\n symbols = SUBSTITUTION_SYMBOLS;\n }\n return replace(replacement, symbols, function (match, ch) {\n var capture;\n switch (charAt(ch, 0)) {\n case '$': return '$';\n case '&': return matched;\n case '`': return stringSlice(str, 0, position);\n case \"'\": return stringSlice(str, tailPos);\n case '<':\n capture = namedCaptures[stringSlice(ch, 1, -1)];\n break;\n default: // \\d\\d?\n var n = +ch;\n if (n === 0) return match;\n if (n > m) {\n var f = floor(n / 10);\n if (f === 0) return match;\n if (f <= m) return captures[f - 1] === undefined ? charAt(ch, 1) : captures[f - 1] + charAt(ch, 1);\n return match;\n }\n capture = captures[n - 1];\n }\n return capture === undefined ? '' : capture;\n });\n};\n","'use strict';\nvar $ = require('../internals/export');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar IndexedObject = require('../internals/indexed-object');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar arrayMethodIsStrict = require('../internals/array-method-is-strict');\n\nvar un$Join = uncurryThis([].join);\n\nvar ES3_STRINGS = IndexedObject != Object;\nvar STRICT_METHOD = arrayMethodIsStrict('join', ',');\n\n// `Array.prototype.join` method\n// https://tc39.es/ecma262/#sec-array.prototype.join\n$({ target: 'Array', proto: true, forced: ES3_STRINGS || !STRICT_METHOD }, {\n join: function join(separator) {\n return un$Join(toIndexedObject(this), separator === undefined ? ',' : separator);\n }\n});\n","var $ = require('../internals/export');\nvar toObject = require('../internals/to-object');\nvar nativeKeys = require('../internals/object-keys');\nvar fails = require('../internals/fails');\n\nvar FAILS_ON_PRIMITIVES = fails(function () { nativeKeys(1); });\n\n// `Object.keys` method\n// https://tc39.es/ecma262/#sec-object.keys\n$({ target: 'Object', stat: true, forced: FAILS_ON_PRIMITIVES }, {\n keys: function keys(it) {\n return nativeKeys(toObject(it));\n }\n});\n","var $ = require('../internals/export');\nvar isArray = require('../internals/is-array');\n\n// `Array.isArray` method\n// https://tc39.es/ecma262/#sec-array.isarray\n$({ target: 'Array', stat: true }, {\n isArray: isArray\n});\n","var defineWellKnownSymbol = require('../internals/define-well-known-symbol');\n\n// `Symbol.iterator` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.iterator\ndefineWellKnownSymbol('iterator');\n","var global = require('../internals/global');\nvar DOMIterables = require('../internals/dom-iterables');\nvar DOMTokenListPrototype = require('../internals/dom-token-list-prototype');\nvar ArrayIteratorMethods = require('../modules/es.array.iterator');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar ArrayValues = ArrayIteratorMethods.values;\n\nvar handlePrototype = function (CollectionPrototype, COLLECTION_NAME) {\n if (CollectionPrototype) {\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype[ITERATOR] !== ArrayValues) try {\n createNonEnumerableProperty(CollectionPrototype, ITERATOR, ArrayValues);\n } catch (error) {\n CollectionPrototype[ITERATOR] = ArrayValues;\n }\n if (!CollectionPrototype[TO_STRING_TAG]) {\n createNonEnumerableProperty(CollectionPrototype, TO_STRING_TAG, COLLECTION_NAME);\n }\n if (DOMIterables[COLLECTION_NAME]) for (var METHOD_NAME in ArrayIteratorMethods) {\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype[METHOD_NAME] !== ArrayIteratorMethods[METHOD_NAME]) try {\n createNonEnumerableProperty(CollectionPrototype, METHOD_NAME, ArrayIteratorMethods[METHOD_NAME]);\n } catch (error) {\n CollectionPrototype[METHOD_NAME] = ArrayIteratorMethods[METHOD_NAME];\n }\n }\n }\n};\n\nfor (var COLLECTION_NAME in DOMIterables) {\n handlePrototype(global[COLLECTION_NAME] && global[COLLECTION_NAME].prototype, COLLECTION_NAME);\n}\n\nhandlePrototype(DOMTokenListPrototype, 'DOMTokenList');\n","var $ = require('../internals/export');\nvar $entries = require('../internals/object-to-array').entries;\n\n// `Object.entries` method\n// https://tc39.es/ecma262/#sec-object.entries\n$({ target: 'Object', stat: true }, {\n entries: function entries(O) {\n return $entries(O);\n }\n});\n","var DESCRIPTORS = require('../internals/descriptors');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar objectKeys = require('../internals/object-keys');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar $propertyIsEnumerable = require('../internals/object-property-is-enumerable').f;\n\nvar propertyIsEnumerable = uncurryThis($propertyIsEnumerable);\nvar push = uncurryThis([].push);\n\n// `Object.{ entries, values }` methods implementation\nvar createMethod = function (TO_ENTRIES) {\n return function (it) {\n var O = toIndexedObject(it);\n var keys = objectKeys(O);\n var length = keys.length;\n var i = 0;\n var result = [];\n var key;\n while (length > i) {\n key = keys[i++];\n if (!DESCRIPTORS || propertyIsEnumerable(O, key)) {\n push(result, TO_ENTRIES ? [key, O[key]] : O[key]);\n }\n }\n return result;\n };\n};\n\nmodule.exports = {\n // `Object.entries` method\n // https://tc39.es/ecma262/#sec-object.entries\n entries: createMethod(true),\n // `Object.values` method\n // https://tc39.es/ecma262/#sec-object.values\n values: createMethod(false)\n};\n","'use strict';\nvar $ = require('../internals/export');\nvar $trim = require('../internals/string-trim').trim;\nvar forcedStringTrimMethod = require('../internals/string-trim-forced');\n\n// `String.prototype.trim` method\n// https://tc39.es/ecma262/#sec-string.prototype.trim\n$({ target: 'String', proto: true, forced: forcedStringTrimMethod('trim') }, {\n trim: function trim() {\n return $trim(this);\n }\n});\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\nvar toString = require('../internals/to-string');\nvar whitespaces = require('../internals/whitespaces');\n\nvar replace = uncurryThis(''.replace);\nvar whitespace = '[' + whitespaces + ']';\nvar ltrim = RegExp('^' + whitespace + whitespace + '*');\nvar rtrim = RegExp(whitespace + whitespace + '*$');\n\n// `String.prototype.{ trim, trimStart, trimEnd, trimLeft, trimRight }` methods implementation\nvar createMethod = function (TYPE) {\n return function ($this) {\n var string = toString(requireObjectCoercible($this));\n if (TYPE & 1) string = replace(string, ltrim, '');\n if (TYPE & 2) string = replace(string, rtrim, '');\n return string;\n };\n};\n\nmodule.exports = {\n // `String.prototype.{ trimLeft, trimStart }` methods\n // https://tc39.es/ecma262/#sec-string.prototype.trimstart\n start: createMethod(1),\n // `String.prototype.{ trimRight, trimEnd }` methods\n // https://tc39.es/ecma262/#sec-string.prototype.trimend\n end: createMethod(2),\n // `String.prototype.trim` method\n // https://tc39.es/ecma262/#sec-string.prototype.trim\n trim: createMethod(3)\n};\n","var PROPER_FUNCTION_NAME = require('../internals/function-name').PROPER;\nvar fails = require('../internals/fails');\nvar whitespaces = require('../internals/whitespaces');\n\nvar non = '\\u200B\\u0085\\u180E';\n\n// check that a method works with the correct list\n// of whitespaces and has a correct name\nmodule.exports = function (METHOD_NAME) {\n return fails(function () {\n return !!whitespaces[METHOD_NAME]()\n || non[METHOD_NAME]() !== non\n || (PROPER_FUNCTION_NAME && whitespaces[METHOD_NAME].name !== METHOD_NAME);\n });\n};\n","'use strict';\nvar $ = require('../internals/export');\nvar $find = require('../internals/array-iteration').find;\nvar addToUnscopables = require('../internals/add-to-unscopables');\n\nvar FIND = 'find';\nvar SKIPS_HOLES = true;\n\n// Shouldn't skip holes\nif (FIND in []) Array(1)[FIND](function () { SKIPS_HOLES = false; });\n\n// `Array.prototype.find` method\n// https://tc39.es/ecma262/#sec-array.prototype.find\n$({ target: 'Array', proto: true, forced: SKIPS_HOLES }, {\n find: function find(callbackfn /* , that = undefined */) {\n return $find(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables(FIND);\n","module.exports = __webpack_public_path__ + \"CSS/main.css\";","export default class Slider {\r\n constructor(config) {\r\n this.config = config || {};\r\n this.parentSelector = this.config.parentSelector || '.slider';\r\n this.childSelector = this.config.childSelector || '.slide';\r\n this.parent = this.config.parent || document.querySelector(this.parentSelector);\r\n if (!this.parent) return console.log('slider.js: Container não encontrado.');\r\n this.children = this.parent.querySelectorAll(this.childSelector);\r\n if (!this.children.length) return console.log('slider.js: Slides não encontrados.');\r\n if (this.parent.hasAttribute('data-pagination')) this.pagination = this.config.pagination || '.slider-pagination';\r\n this.index = 0;\r\n this.timeout = this.config.timeout || 3000;\r\n this.parent.classList.add('slider-set');\r\n this.compose();\r\n }\r\n\r\n compose() {\r\n var nextIndex, prevIndex;\r\n prevIndex = this.index > 0 ? this.index - 1 : this.children.length - 1;\r\n nextIndex = this.index < this.children.length - 1 ? this.index + 1 : 0;\r\n Array.prototype.forEach.call(this.children, function (el) {\r\n el.classList.remove('prev');\r\n el.classList.remove('current');\r\n el.classList.remove('next');\r\n return true;\r\n });\r\n this.children[prevIndex].classList.add('prev');\r\n this.children[this.index].classList.add('current');\r\n this.children[nextIndex].classList.add('next');\r\n\r\n if (this.onCompose && this.onCompose instanceof Function) {\r\n this.onCompose(this);\r\n }\r\n\r\n return this;\r\n }\r\n play() {\r\n var that;\r\n that = this;\r\n this.playingStateID = setInterval(function () {\r\n return that.next();\r\n }, this.timeout);\r\n this.isPlaying = true;\r\n return this;\r\n }\r\n pause() {\r\n clearInterval(this.playingStateID);\r\n this.isPlaying = false;\r\n return this;\r\n }\r\n playpause() {\r\n if (this.isPlaying) {\r\n return this.pause();\r\n } else {\r\n return this.play();\r\n }\r\n }\r\n goTo(index) {\r\n var playingState;\r\n this.index = index | 0;\r\n playingState = this.isPlaying;\r\n if (playingState) {\r\n this.pause();\r\n }\r\n this.compose();\r\n if (playingState) {\r\n return this.play();\r\n }\r\n }\r\n prev() {\r\n var playingState;\r\n if (this.index > 0) {\r\n this.index--;\r\n } else {\r\n this.index = this.children.length - 1;\r\n }\r\n playingState = this.isPlaying;\r\n if (playingState) {\r\n this.pause();\r\n }\r\n this.compose();\r\n if (playingState) {\r\n return this.play();\r\n }\r\n }\r\n next() {\r\n var playingState;\r\n if (this.index < this.children.length - 1) {\r\n this.index++;\r\n } else {\r\n this.index = 0;\r\n }\r\n playingState = this.isPlaying;\r\n if (playingState) {\r\n this.pause();\r\n }\r\n this.compose();\r\n if (playingState) {\r\n return this.play();\r\n }\r\n }\r\n on(event, fn) {\r\n this.parent.addEventListener(event, fn);\r\n return this;\r\n }\r\n off(event, fn) {\r\n this.parent.removeEventListener(event, fn);\r\n return this;\r\n }\r\n inspect() {\r\n var err;\r\n console.group(this.parentSelector);\r\n try {\r\n console.info(this.children.length + ' slides');\r\n } catch (error) {\r\n err = error;\r\n console.error(err);\r\n }\r\n console.groupEnd(this.parentSelector);\r\n return this;\r\n }\r\n}","export default class AccManager {\r\n constructor() {}\r\n\r\n static get fontSizes() {\r\n return [\r\n '14px',\r\n '15px',\r\n null,\r\n '18px',\r\n '20px'\r\n ]\r\n }\r\n\r\n static get availableThemes() {\r\n return [\r\n 'dark-theme'\r\n ];\r\n }\r\n\r\n static init() {\r\n AccManager.fontSizeIndex = AccManager.fontSizeIndex;\r\n AccManager.globalTheme = AccManager.globalTheme;\r\n }\r\n\r\n static get globalTheme() {\r\n const theme = localStorage.getItem('global-theme');\r\n if (!AccManager.availableThemes.indexOf(theme) === -1) {\r\n localStorage.removeItem('global-theme');\r\n return null;\r\n }\r\n return theme;\r\n }\r\n\r\n static set globalTheme(theme) {\r\n const storedTheme = AccManager.globalTheme;\r\n const isValid = AccManager.availableThemes.indexOf(theme) !== -1;\r\n if (storedTheme && storedTheme !== theme) {\r\n document.body.classList.remove(storedTheme);\r\n }\r\n if (isValid) {\r\n document.body.classList.add(theme);\r\n localStorage.setItem('global-theme', theme);\r\n }\r\n else {\r\n localStorage.removeItem('global-theme');\r\n }\r\n }\r\n\r\n static get fontSizeTarget() {\r\n return AccManager.__fontSizeTarget__;\r\n }\r\n\r\n static set fontSizeTarget(val) {\r\n AccManager.__fontSizeTarget__ = document.querySelectorAll(val);\r\n }\r\n\r\n static get fontSizeIndex() {\r\n return localStorage.getItem('font-size') || AccManager.fontSizes.indexOf(null) || 0;\r\n }\r\n\r\n static set fontSizeIndex(val) {\r\n if (val < 0) val = 0;\r\n if (val >= AccManager.fontSizes.length) val = AccManager.fontSizes.length - 1;\r\n Array.prototype.forEach.call(\r\n AccManager.fontSizeTarget,\r\n el => el.style.fontSize = AccManager.fontSizes[val]\r\n );\r\n localStorage.setItem('font-size', val);\r\n }\r\n\r\n}","const mascaras = {\r\n\r\n nome: (campo) => {\r\n if (/^[^a-zA-Z]+/.test(campo.value)) campo.value = '';\r\n const regra = /[-'a-zA-ZÀ-ÖØ-öø-ſ ]+/gi;\r\n const valores = campo.value.match(regra);\r\n if (valores) campo.value = valores.join('').replace(/ +/gi, ' ').toUpperCase();\r\n },\r\n\r\n cep: (campo) => {\r\n const regras = [/\\d+/gi, /^(\\d{5})-?(\\d{1,3})/];\r\n const valores = campo.value.match(regras[0]);\r\n if (!valores) return campo.value = '';\r\n campo.value = valores.join('');\r\n if (regras[1].test(campo.value)) campo.value = campo.value.replace(regras[1], '$1-$2');\r\n if (campo.value.length > 9) campo.value = campo.value.substr(0, 9);\r\n },\r\n\r\n telefone: (campo) => {\r\n const regras = [/\\d+/gi, /^(\\d\\d?)/, /^(\\d\\d)(\\d{4})-?(\\d{1,4})/, /^(\\d\\d)(\\d{5})-?(\\d{1,4})/];\r\n const valores = campo.value.match(regras[0]);\r\n if (!valores) return campo.value = '';\r\n const valor = campo.value = valores.join('');\r\n if (valor.length > 0) campo.value = valor.replace(regras[1], '($1');\r\n if (valor.length > 2) campo.value = valor.replace(regras[1], '($1) ');\r\n if (valor.length > 6) campo.value = valor.replace(regras[2], '($1) $2-$3');\r\n if (valor.length > 10) campo.value = valor.replace(regras[3], '($1) $2-$3');\r\n if (valor.length > 11) campo.value = campo.value.substr(0, 15);\r\n },\r\n\r\n rg: (campo) => {\r\n const regras = [/\\d+/gi, /^(\\d{1,2})/, /^(\\d{1,2})\\.?(\\d{3})/, /^(\\d{1,2})\\.?(\\d{3})\\.?(\\d{3})/, /^(\\d{1,2})\\.?(\\d{3})\\.?(\\d{3})-?(\\d)?/];\r\n const valores = campo.value.match(regras[0]);\r\n const letras = campo.value.match(/[a-zA-Z]+$/gi);\r\n const digito = letras ? letras[0][0] : '';\r\n if (!valores) return campo.value = '';\r\n const valor = campo.value = valores.join('');\r\n if (valor.length > 2) campo.value = valor.replace(regras[1], '$1.');\r\n if (valor.length > 5) campo.value = valor.replace(regras[2], '$1.$2.');\r\n if (valor.length > 7) campo.value = valor.replace(regras[3], '$1.$2.$3');\r\n if (valor.length === 8 && digito) campo.value += '-' + digito.toUpperCase();\r\n if (valor.length > 8) campo.value = valor.replace(regras[4], '$1.$2.$3-$4');\r\n if (valor.length > 9) campo.value = campo.value.substr(0, 12);\r\n },\r\n\r\n cpfcnpj: (campo) => {\r\n const numeros = /\\d+/gi;\r\n const valores = campo.value.match(numeros);\r\n if (!valores) return campo.value = '';\r\n const valor = valores.join('');\r\n const cpf = /^([0-9]{1,3})?\\.?([0-9]{1,3})?\\.?([0-9]{1,3})?\\-?([0-9]{1,2})?$/;\r\n const cnpj = /^([0-9]{1,2})?\\.?([0-9]{1,3})?\\.?([0-9]{1,3})?\\/?([0-9]{1,4})?\\-?([0-9]{1,2})?$/;\r\n campo.value = campo.value.replace(/[^\\d.\\/-]/gi, '');\r\n if (cpf.test(valor)) campo.value = valor.replace(cpf, (all, a, b, c, d) => {\r\n return (a || '') + (b ? '.' + b : '') + (c ? '.' + c : '') + (d ? '-' + d : '');\r\n });\r\n else if (cnpj.test(valor)) campo.value = valor.replace(cnpj, (all, a, b, c, d, e) => {\r\n return (a || '') + (b ? '.' + b : '') + (c ? '.' + c : '') + (d ? '/' + d : '') + (e ? '-' + e : '');\r\n });\r\n if (campo.value.length > 18) campo.value = campo.value.substr(0, 18);\r\n },\r\n\r\n cpf: (campo) => {\r\n const numeros = /\\d+/gi;\r\n const valores = campo.value.match(numeros);\r\n if (!valores) return campo.value = '';\r\n const valor = valores.join('');\r\n const cpf = /^([0-9]{1,3})?\\.?([0-9]{1,3})?\\.?([0-9]{1,3})?\\-?([0-9]{1,2})?$/;\r\n campo.value = campo.value.replace(/[^\\d.\\/-]/gi, '');\r\n if (cpf.test(valor)) campo.value = valor.replace(cpf, (all, a, b, c, d) => {\r\n return (a || '') + (b ? '.' + b : '') + (c ? '.' + c : '') + (d ? '-' + d : '');\r\n });\r\n if (campo.value.length > 14) campo.value = campo.value.substr(0, 14);\r\n },\r\n\r\n cnpj: (campo) => {\r\n const numeros = /\\d+/gi;\r\n const valores = campo.value.match(numeros);\r\n if (!valores) return campo.value = '';\r\n const valor = valores.join('');\r\n const cnpj = /^([0-9]{1,2})?\\.?([0-9]{1,3})?\\.?([0-9]{1,3})?\\/?([0-9]{1,4})?\\-?([0-9]{1,2})?$/;\r\n campo.value = campo.value.replace(/[^\\d.\\/-]/gi, '');\r\n if (cnpj.test(valor)) campo.value = valor.replace(cnpj, (all, a, b, c, d, e) => {\r\n return (a || '') + (b ? '.' + b : '') + (c ? '.' + c : '') + (d ? '/' + d : '') + (e ? '-' + e : '');\r\n });\r\n if (campo.value.length > 18) campo.value = campo.value.substr(0, 18);\r\n },\r\n\r\n data: (campo) => {\r\n if (campo.type === 'date') return;\r\n const numeros = campo.value.replace(/^0?\\/|[^\\d\\/]/gi, '');\r\n if (numeros === '') {\r\n campo.value = numeros;\r\n campo.style.borderColor = null;\r\n return;\r\n }\r\n campo.value = numeros\r\n .replace(/(^|\\/)00+\\/?/g, '0')\r\n .replace(/(^|\\/)([1-9]\\/)/, '0$2')\r\n .replace(\r\n /(\\d\\d)(\\/?)(\\d{1,2})?(\\/?)0*(\\d{1,4})?.*/g,\r\n function(all, dd, s1, mm, s2, aaaa) {\r\n if (dd > 31 || mm > 12) campo.style.borderColor = 'red';\r\n else campo.style.borderColor = null;\r\n return dd + (mm ? '/' + mm : s1 || '') + (aaaa ? '/' + aaaa : s2 || '');\r\n }\r\n );\r\n },\r\n\r\n email: (campo) => {\r\n campo.value = campo.value.toLowerCase();\r\n },\r\n\r\n senha: (campo) => {\r\n if (campo.value.length > 0 && campo.value.length < 6) campo.style.borderColor = 'red';\r\n else campo.style.borderColor = null;\r\n }\r\n\r\n};\r\n\r\nexport default mascaras;","import pipe from \"./pipe\";\r\n\r\nexport const $ = (selectors) => {\r\n const elements = (\r\n typeof selectors === 'string'\r\n ? document.querySelectorAll(selectors)\r\n : selectors\r\n );\r\n const array = [].slice.call(elements);\r\n return array;\r\n};\r\n\r\nconst render = (node, {\r\n style, events, children, attrs, ...props\r\n} = {}) => {\r\n const element = (\r\n typeof node === 'string'\r\n ? document.createElement(node)\r\n : node\r\n );\r\n\r\n if (!(element instanceof Node)) {\r\n // eslint-disable-next-line no-console\r\n console.warn('Elemento inválido.', element);\r\n return null;\r\n }\r\n\r\n if (props) {\r\n Object.entries(props).forEach(([key, val]) => {\r\n element[key] = val;\r\n });\r\n }\r\n\r\n if (attrs) {\r\n Object.entries(attrs).forEach(([key, val]) => {\r\n element.setAttribute(key, val);\r\n });\r\n }\r\n\r\n if (style) {\r\n Object.entries(style).forEach(([key, val]) => {\r\n element.style[key] = val;\r\n });\r\n }\r\n\r\n if (children instanceof Array) {\r\n children.forEach((kid) => {\r\n if (kid instanceof Node) {\r\n element.appendChild(kid);\r\n }\r\n });\r\n }\r\n\r\n if (events) {\r\n Object.entries(events).forEach(([name, fn]) => {\r\n if (typeof name === 'string' && fn instanceof Function) {\r\n element.addEventListener(name, fn);\r\n }\r\n });\r\n }\r\n\r\n return element;\r\n};\r\n\r\n$.render = render;\r\n\r\nexport function _remove(element) {\r\n if (!element.parentElement) return;\r\n element.parentElement.removeChild(element);\r\n}\r\n\r\nexport function _add(element) {\r\n if (!element.parentElement) return;\r\n element.insertAdjacentElement('beforebegin', element.parentElement);\r\n}\r\n\r\nexport function _show(what, callback) {\r\n if (typeof what === 'string') what = document.querySelectorAll(what);\r\n if (what instanceof Array) return what.forEach(w => _show(w, callback));\r\n if (what instanceof NodeList) return Array.prototype.forEach.call(what, w => _show(w, callback));\r\n if (!(what instanceof Node)) return;\r\n what.removeAttribute('hidden');\r\n if (callback instanceof Function) callback(what);\r\n}\r\n\r\nexport function _hide(what, callback) {\r\n if (typeof what === 'string') what = document.querySelectorAll(what);\r\n if (what instanceof Array) return what.forEach(w => _hide(w, callback));\r\n if (what instanceof NodeList) return Array.prototype.forEach.call(what, w => _hide(w, callback));\r\n if (!(what instanceof Node)) return;\r\n what.setAttribute('hidden', true);\r\n if (callback instanceof Function) callback(what);\r\n}\r\n\r\nexport function createElement(el, attrs) {\r\n function element(el, attrs) {\r\n if (typeof el === 'string') el = document.createElement(el);\r\n if (!(el instanceof Node)) return false;\r\n if (attrs) extend(el, attrs);\r\n return el;\r\n }\r\n function extend(obj, props) {\r\n const extenders = {\r\n style: function (styles) {\r\n extend(obj.style, styles);\r\n },\r\n dataset: function (data) {\r\n for (var name in data) obj.setAttribute('data-' + name, data[name]);\r\n },\r\n events: function (callbacks) {\r\n for (var name in callbacks) obj.addEventListener(name, callbacks[name]);\r\n },\r\n children: function (kids) {\r\n Array.prototype.forEach.call(kids, function (k) {\r\n if (!(k instanceof Node)) return;\r\n obj.appendChild(k);\r\n });\r\n }\r\n };\r\n for (const name in props) {\r\n (extenders[name] || function (val) {\r\n obj[name] = val;\r\n })(props[name]);\r\n }\r\n }\r\n return element(el, attrs);\r\n}\r\n\r\nexport function createButton(attrs, btnAction) {\r\n var newButton = createElement('button', attrs);\r\n if (typeof btnAction === 'function') {\r\n newButton.addEventListener('click', function () {\r\n btnAction(this);\r\n });\r\n }\r\n return newButton;\r\n}\r\n\r\nexport function template(template, data) {\r\n if (typeof template === 'string') template = document.querySelector(template);\r\n if (!(template instanceof Node)) return console.trace('template: Template não encontrado :(');\r\n if (!data) return console.log('template: Informe o objeto de dados para renderizar o template.');\r\n\r\n const props = /(\\{([^}]*)\\})+/g;\r\n template = template.cloneNode(true);\r\n template.removeAttribute('hidden');\r\n template.removeAttribute('id');\r\n\r\n const operandsRegex = /(.*)(\\s*==|!=\\s*)(.*)/;\r\n\r\n const operators = {\r\n '==': (a, b) => a === b,\r\n '!=': (a, b) => a !== b,\r\n };\r\n\r\n const usingOperator = (str) => {\r\n const matches = str.match(operandsRegex);\r\n if (!matches) {\r\n return false;\r\n }\r\n const a = matches[1];\r\n const key = matches[2];\r\n const b = matches[3];\r\n const operator = operators[key.trim()];\r\n return operator && operator(a, b);\r\n };\r\n\r\n const filters = {\r\n monthname: (val) => ([\r\n 'janeiro', 'fevereiro', 'março',\r\n 'abril', 'maio', 'junho',\r\n 'julho', 'agosto', 'setembro',\r\n 'outubro', 'novembro', 'dezembro',\r\n ][val - 1]),\r\n capitalize: (val) => {\r\n if (typeof val !== 'string') {\r\n return '';\r\n }\r\n return `${val[0].toUpperCase()}${val.substr(1)}`;\r\n },\r\n }\r\n\r\n render('if', (el, val) => {\r\n if (!usingOperator(val.trim())) {\r\n el.setAttribute('hidden', true);\r\n }\r\n else {\r\n el.removeAttribute('hidden');\r\n }\r\n });\r\n render('model', (el, val) => val.trim() && (el.textContent = val));\r\n render('text-content', (el, val) => val.trim() && (el.textContent = val));\r\n render('html', (el, val) => val.trim() && (el.innerHTML = val));\r\n render('href', (el, val) => el.href = val);\r\n render('src', (el, val) => el.src = val);\r\n render('for', (el, val) => el.setAttribute('for', val));\r\n render('id', (el, val) => el.id = val);\r\n render('name', (el, val) => el.name = val);\r\n render('value', (el, val) => el.value = val);\r\n render('title', (el, val) => el.title = val);\r\n render('bg-color', (el, val) => el.style.backgroundColor = val);\r\n render('background', (el, val) => el.style.backgroundImage = `url(${val})`);\r\n render('border-color', (el, val) => el.style.borderColor = val);\r\n render('color', (el, val) => el.style.color = val);\r\n render('hook', (el, val) => el.setAttribute('data-hook', val));\r\n render('time', (el, val) => {\r\n const pattern = /(\\d\\d):(\\d\\d).*/gi;\r\n el.textContent = val.replace(pattern, function (all, hh, min) {\r\n return `${hh}:${min}`;\r\n });\r\n });\r\n render('date', (el, val) => {\r\n const pattern = /(\\d{4})-(\\d\\d)-(\\d\\d)T(\\d\\d):(\\d\\d).*/gi;\r\n el.textContent = val.replace(pattern, function (all, aaaa, mm, dd) {\r\n return `${dd}/${mm}/${aaaa}`;\r\n });\r\n });\r\n render('datetime', (el, val) => {\r\n const pattern = /(\\d{4})-(\\d\\d)-(\\d\\d)T(\\d\\d):(\\d\\d).*/gi;\r\n el.textContent = val.replace(pattern, function (all, aaaa, mm, dd, hh, min) {\r\n return `${dd}/${mm}/${aaaa} às ${hh}:${min}`;\r\n });\r\n });\r\n render('group-by', (el, val) => el.setAttribute('data-group-by', val));\r\n\r\n return template;\r\n\r\n function render(attr, fn) {\r\n if (template.hasAttribute('data-' + attr)) {\r\n fn(template, parseProperty(template.getAttribute('data-' + attr)));\r\n }\r\n const elements = template.querySelectorAll('[data-' + attr + ']');\r\n Array.prototype.forEach.call(elements, el => {\r\n const propertyName = el.getAttribute('data-' + attr);\r\n if (!propertyName) return false;\r\n const val = parseProperty(propertyName);\r\n fn(el, val);\r\n });\r\n }\r\n\r\n function parseProperty(name) {\r\n return name.replace(props, (a, b, prop) => {\r\n const [key, ...filtersNames] = prop.split('|');\r\n const val = data[key.trim()] || '';\r\n if (!filtersNames.length) {\r\n return val;\r\n }\r\n const filterCallbacks = filtersNames\r\n .map(name => filters[name])\r\n .filter(fn => fn instanceof Function);\r\n return pipe(val, ...filterCallbacks);\r\n });\r\n }\r\n}\r\n\r\nexport function _hasParent(target, parent) {\r\n if (!target || !parent) return false;\r\n if (target === parent) return false;\r\n if (target.parentElement === parent) return true;\r\n return _hasParent(target.parentElement, parent);\r\n}\r\n\r\nexport const trigger = (el, name, detail) => {\r\n const customEvent = window.CustomEvent && typeof window.CustomEvent === 'function';\r\n const event = (\r\n customEvent\r\n ? new CustomEvent(name, { detail })\r\n : document.createEvent('CustomEvent')\r\n );\r\n\r\n event.initCustomEvent(name, true, true, detail);\r\n\r\n el.dispatchEvent(event);\r\n};\r\n","import { $ } from '../util/DOM2';\n\nconst closeSVG = '';\n\nconst createModal = (content, keepInDoc) => {\n const container = $.render('div', {\n className: 'modal',\n innerHTML: /* html */ `${\n (content && content.outerHTML) || content || ''\n }
`,\n });\n\n document.body.appendChild(container);\n\n const open = () => {\n container.classList.add('open');\n document.body.classList.add('has-modal');\n };\n\n const fechar = document.querySelectorAll('.close').forEach((item) => {\n item.addEventListener('click', (keep = keepInDoc) => {\n container.classList.remove('open');\n document.body.classList.remove('has-modal');\n if (!keep) {\n setTimeout(() => {\n container.remove();\n }, 500);\n }\n });\n });\n\n const close = (keep = keepInDoc) => {\n container.classList.remove('open');\n document.body.classList.remove('has-modal');\n if (!keep) {\n setTimeout(() => {\n container.remove();\n }, 500);\n }\n };\n\n document.body.appendChild(container);\n\n const modal = {\n container,\n open,\n close,\n };\n\n container.modal = modal;\n\n return modal;\n};\n\nexport default createModal;\n","import createModal from '../components/createModal';\nimport { $ } from '../util/DOM2';\n\nconst svg = {\n prev: '',\n next: '',\n};\n\nconst imageView = ({ href, title }, onclick) => {\n const modal = createModal(/* html */ `\n
\n`, true);\n\n $.render(modal.container, {\n children: [\n $.render('button', {\n type: 'button',\n className: 'modal__prev-button',\n innerHTML: svg.prev,\n events: {\n click: () => onclick(-1),\n },\n }),\n $.render('button', {\n type: 'button',\n className: 'modal__next-button',\n innerHTML: svg.next,\n events: {\n click: () => onclick(+1),\n },\n }),\n ],\n });\n\n return modal;\n};\n\nconst initGallery = () => {\n $('.gallery__container').forEach((container) => {\n const photos = $('.gallery__item', container);\n photos.forEach((p, index) => {\n // eslint-disable-next-line no-param-reassign\n p.modal = imageView(p, (i) => {\n const selectedIndex = index + i;\n p.modal.close();\n if (selectedIndex < 0) {\n photos[photos.length - 1].modal.open();\n return;\n }\n if (selectedIndex >= photos.length) {\n photos[0].modal.open();\n return;\n }\n photos[selectedIndex].modal.open();\n });\n\n p.addEventListener('click', (e) => {\n e.preventDefault();\n p.modal.open();\n });\n });\n });\n};\n\nexport default initGallery;\n","export function _remove(element) {\r\n if(!element.parentElement) return;\r\n element.parentElement.removeChild(element);\r\n}\r\n\r\nexport function _add(element) {\r\n if(!element.parentElement) return;\r\n element.insertAdjacentElement('beforebegin', element.parentElement);\r\n}\r\n\r\nexport function _show(what, callback) {\r\n if (typeof what === 'string') what = document.querySelectorAll(what);\r\n if (what instanceof Array) return what.forEach(w => _show(w, callback));\r\n if (what instanceof NodeList) return Array.prototype.forEach.call(what, w => _show(w, callback));\r\n if (!(what instanceof Node)) return;\r\n what.removeAttribute('hidden');\r\n if (callback instanceof Function) callback(what);\r\n}\r\n \r\nexport function _hide(what, callback) {\r\n if (typeof what === 'string') what = document.querySelectorAll(what);\r\n if (what instanceof Array) return what.forEach(w => _hide(w, callback));\r\n if (what instanceof NodeList) return Array.prototype.forEach.call(what, w => _hide(w, callback));\r\n if (!(what instanceof Node)) return;\r\n what.setAttribute('hidden', true);\r\n if (callback instanceof Function) callback(what);\r\n}\r\n\r\nexport function createElement(el, attrs) {\r\n function element(el, attrs) {\r\n if (typeof el === 'string') el = document.createElement(el);\r\n if (!(el instanceof Node)) return false;\r\n if (attrs) extend(el, attrs);\r\n return el;\r\n }\r\n function extend(obj, props) {\r\n const extenders = {\r\n style: function (styles) {\r\n extend(obj.style, styles);\r\n },\r\n dataset: function (data) {\r\n for (var name in data) obj.setAttribute('data-' + name, data[name]);\r\n },\r\n events: function (callbacks) {\r\n for (var name in callbacks) obj.addEventListener(name, callbacks[name]);\r\n },\r\n children: function (kids) {\r\n Array.prototype.forEach.call(kids, function (k) {\r\n if (!(k instanceof Node)) return;\r\n obj.appendChild(k);\r\n });\r\n }\r\n };\r\n for (const name in props) {\r\n (extenders[name] || function (val) {\r\n obj[name] = val;\r\n })(props[name]);\r\n }\r\n }\r\n return element(el, attrs);\r\n}\r\n \r\nexport function createButton(attrs, btnAction) {\r\n var newButton = createElement('button', attrs);\r\n if (typeof btnAction === 'function') {\r\n newButton.addEventListener('click', function () {\r\n btnAction(this);\r\n });\r\n }\r\n return newButton;\r\n}","import { $ } from '../util/DOM2';\n\nconst initMenuFX = () => {\n const buttons = $('[aria-haspopup=\"true\"]');\n\n const targets = buttons.map((btn) => {\n const target = document.getElementById(btn.getAttribute('aria-controls'));\n if (!target) {\n return null;\n }\n\n btn.addEventListener('click', (e) => {\n e.preventDefault();\n e.stopPropagation();\n const isOpen = btn.getAttribute('aria-expanded') === 'true';\n const groupName = btn.getAttribute('data-group-name');\n if (groupName) {\n $(`[data-group-name=\"${groupName}\"]`).forEach((b) => {\n b.setAttribute('aria-expanded', false);\n });\n }\n btn.setAttribute('aria-expanded', !isOpen);\n });\n\n return target;\n }).filter((el) => !!el);\n\n window.addEventListener('click', ({ target }) => {\n const foundTarget = targets.find((el) => el === target || el.contains(target));\n if (foundTarget) {\n return;\n }\n buttons.forEach((button) => button.setAttribute('aria-expanded', false));\n });\n};\n\nexport default initMenuFX;\n","import Slider from './components/slider';\r\nimport req from './util/req';\r\nimport AccManager from './util/AccManager';\r\nimport hasParent from './util/hasParent';\r\nimport masks from './util/masks';\r\nimport initGallery from './main/initGallery';\r\nimport {\r\n createElement,\r\n createButton,\r\n _remove,\r\n _add,\r\n _show,\r\n _hide\r\n} from './util/DOM';\r\nimport initMenuFX from './main/initMenuFX';\r\n\r\ninitMenuFX();\r\ninitGallery();\r\n\r\nconst each = (i, f) => Array.prototype.forEach.call(i, f);\r\ndocument.body.addEventListener('touchstart', function () {}); /* Bug do iPhone que não fecha o menu */\r\n\r\n//#region modal Img\r\nif(!('modal-img' in sessionStorage)){\r\n openModal(`\r\n

\r\n
`);\r\n sessionStorage.setItem(\"modal-img\", true);\r\n}\r\n//#endregion\r\n\r\n/**\r\n * Scroll\r\n */\r\nconst btnTop = document.querySelector('[data-action~=\"scroll-top\"]');\r\nif(btnTop) {\r\n window.onscroll = function() {\r\n if (document.body.scrollTop > 100 || document.documentElement.scrollTop > 100) {\r\n btnTop.removeAttribute('hidden');\r\n } else {\r\n btnTop.setAttribute('hidden', true);\r\n }\r\n };\r\n}\r\nconst pageLinks = document.querySelectorAll('a[href^=\"#\"]');\r\nArray.prototype.forEach.call(pageLinks, link => link.addEventListener(\"click\", function(){\r\n if(this.hash != \"\") {\r\n var section = document.querySelector(this.hash);\r\n if (!section) return false; \r\n scrollToY(section.offsetTop, 1000); \r\n } \r\n}));\r\n\r\n/**\r\n * Menu\r\n */\r\nconst menuIcons = Array.prototype.slice.call(document.querySelectorAll('.menu-icon'));\r\nmenuIcons.forEach(btn => btn.addEventListener('click', function (e) {\r\n e.preventDefault();\r\n this.classList.toggle('hover');\r\n}));\r\ndocument.body.addEventListener('click', function (e) {\r\n menuIcons.forEach(btn => {\r\n const isTarget = el => e.target === el || hasParent(e.target, el);\r\n const menuContainer = btn.parentElement.querySelector('.trigger');\r\n if (isTarget(btn) || isTarget(menuContainer)) return;\r\n btn.classList.remove('hover');\r\n })\r\n}, false);\r\n\r\n/**\r\n * Abas\r\n */\r\nconst tabSets = document.querySelectorAll('.tabs');\r\nif (tabSets.length) each(tabSets, tabSet => {\r\n const tabItems = tabSet.querySelectorAll('.tabs-item');\r\n if (!tabItems.length) return false;\r\n each(tabItems, tab => {\r\n const inputBtn = document.querySelector('#' + tab.getAttribute('for'));\r\n if (!inputBtn) return false;\r\n if (inputBtn.checked) tab.classList.add('active');\r\n tab.style.cursor = 'pointer';\r\n inputBtn.addEventListener('change', function () {\r\n each(tabItems, t => t.classList.remove('active'));\r\n if (this.checked) tab.classList.add('active');\r\n });\r\n });\r\n});\r\n\r\n/**\r\n * Modal\r\n */\r\nfunction openModal(content) {\r\n const modal = document.querySelector('#modal-container');\r\n if (!modal) return false;\r\n modal.querySelector('.modal-content').innerHTML = content;\r\n each(modal.querySelectorAll('[data-btn]'), btn => btn.onclick = function(e) {\r\n e.preventDefault();\r\n modal.querySelector('.modal-content').innerHTML = '';\r\n modal.classList.remove('target');\r\n });\r\n modal.classList.add('target');\r\n}\r\n\r\n/**\r\n * Slider\r\n */\r\nconst sliders = document.querySelectorAll('.slider');\r\nif (sliders.length) each(sliders, makeSlider);\r\nfunction makeSlider(s) {\r\n const timeout = s.getAttribute('data-timeout') || 3000;\r\n const slider = new Slider({\r\n parent: s,\r\n timeout\r\n });\r\n if (s.hasAttribute('data-play')) setSliderAutoPlay(slider);\r\n if (s.hasAttribute('data-height')) slider.parent.style.height = s.getAttribute('data-height') + 'px';\r\n if (s.hasAttribute('data-controls')) setSliderControls(slider, s.getAttribute('data-controls'));\r\n return slider;\r\n}\r\nfunction setSliderAutoPlay(slider) {\r\n slider\r\n .on('mouseover', () => slider.pause())\r\n .on('mouseout', () => slider.play())\r\n .play();\r\n} \r\nfunction setSliderControls(slider, options, container) {\r\n slider.onCompose = slider => {\r\n const dots = slider.controls.querySelectorAll('.slider-dots .slide-dot');\r\n if (!dots.length) return;\r\n dots.forEach(dot => dot.classList.remove('active'));\r\n dots[slider.index].classList.add('active');\r\n };\r\n const ui = {\r\n prevIcon: '',\r\n nextIcon: ''\r\n };\r\n const controls = {\r\n prev: () => createButton({\r\n className: 'slider-control prev icon',\r\n title: 'VOLTAR',\r\n innerHTML: ui.prevIcon\r\n }, function () {\r\n slider.prev();\r\n }),\r\n next: () => createButton({\r\n className: 'slider-control next icon',\r\n title: 'AVANÇAR',\r\n innerHTML: ui.nextIcon\r\n }, function () {\r\n slider.next();\r\n }),\r\n dots: () => createElement('div', {\r\n className: 'slider-dots',\r\n dataset: {\r\n grid: 'row center small-spacing'\r\n },\r\n children: Array.prototype.map.call(slider.children, (lnk, i) => {\r\n const slideTitle = lnk.title;\r\n return createElement('button', {\r\n innerHTML: i,\r\n className: i == 0 ? 'slide-dot active' : 'slide-dot',\r\n dataset: {\r\n cell: 'shrink'\r\n },\r\n events: {\r\n click: () => slider.goTo(i)\r\n }\r\n });\r\n })\r\n })\r\n };\r\n options = options.split(' ');\r\n if (options.length) {\r\n container = createElement('div', {\r\n className: 'slider-controls'\r\n });\r\n slider.parent.insertAdjacentElement('afterend', container);\r\n slider.controls = container;\r\n options.forEach(opt => {\r\n if (controls[opt]) {\r\n const control = controls[opt]();\r\n if (control instanceof Node) container.appendChild(control);\r\n }\r\n });\r\n }\r\n}\r\n\r\nAccManager.fontSizeTarget = '[data-font-size]';\r\n\r\nconst btnActions = { \r\n \"increase-font-size\": function(e) {\r\n AccManager.fontSizeIndex++;\r\n },\r\n \"decrease-font-size\": function(e) {\r\n AccManager.fontSizeIndex--;\r\n },\r\n \"dark-theme\": function (e) {\r\n if(AccManager.globalTheme === null) {\r\n AccManager.globalTheme = 'dark-theme';\r\n }\r\n else {\r\n AccManager.globalTheme = null;\r\n }\r\n },\r\n \"scroll-top\": function(e){\r\n scrollToY(document.querySelector('header').offsetTop, 1000); \r\n },\r\n \"print\": function(e) {\r\n window.print();\r\n },\r\n \"share\": function(e) {\r\n gtag('event', 'share', { method : e.currentTarget.title });\r\n },\r\n 'youtube-splash': function(e) {\r\n e.preventDefault();\r\n const videoId = this.hash.substr(1);\r\n openModal(`\r\n \r\n
`);\r\n }\r\n};\r\n\r\nAccManager.init();\r\n\r\nArray.prototype.forEach.call(document.querySelectorAll('[data-action]'), btn => {\r\n btn.addEventListener('click', function(e) {\r\n const fnName = this.getAttribute('data-action');\r\n const fn = btnActions[fnName];\r\n if (!(fn instanceof Function)) return;\r\n fn.call(this, e);\r\n })\r\n})\r\n\r\nwindow.AccManager = AccManager;\r\n\r\n/**\r\n * Previsão do tempo\r\n */\r\nvar jsonTempo = 'https://api.hgbrasil.com/weather/?format=json-cors&woeid=458878&key=81a3bcec';\r\nvar wnServer = 'http://webnetserver.com.br/prefeiturasaoluizdoparaitinga';\r\nvar wnServer = '';\r\n// var jsonTempo = `${wnServer}/Content/json/tempo.json`;\r\n\r\nreq(\r\n jsonTempo,\r\n r => {\r\n const data = r.results;\r\n const iconUrl = `${wnServer}/Icone/weather/${data.condition_slug}.svg`;\r\n const container = document.querySelector('.site-header-weather');\r\n const img = container.querySelector('.weather-image');\r\n const climaLabel = container.querySelector('.weather-label');\r\n img.src = iconUrl;\r\n climaLabel.innerHTML = `${data.description} ${data.temp}º`;\r\n },\r\n erro => {\r\n const climaContainer = document.querySelector('.site-weather');\r\n climaContainer.setAttribute('hidden', true);\r\n }\r\n)\r\n\r\n\r\n/**\r\n * Formulário\r\n */\r\nconst form = document.querySelectorAll('form');\r\nif (form.length) each(form, FormMask);\r\nfunction FormMask(f) {\r\n (Array.from(f.elements))\r\n .filter(el => el.hasAttribute('data-mask'))\r\n .forEach(campo => campo.addEventListener('input', function () {\r\n const metodo = this.getAttribute('data-mask');\r\n if (!masks[metodo]) return console.log(`A máscara do tipo \"${metodo}\" não foi definida.`);\r\n\r\n masks[metodo](this);\r\n }));\r\n}\r\n\r\nconst file = document.getElementById('file');\r\nconst fileName = document.querySelector('.file-input');\r\nif(file != null) {file.addEventListener('change', showFileName);}\r\nfunction showFileName(e) { \r\n var input = e.srcElement;\r\n var msg = document.getElementById(\"msg-form\");\r\n\r\n if(input.files.length <= 0) {\r\n fileName.textContent = \"Anexe aqui o arquivo...\";\r\n msg.textContent = \"Selecione pelo menos um arquivo\";\r\n } else if(input.files.length > 1) {\r\n fileName.textContent = input.files.length + \" arquivos selecionados\";\r\n msg.textContent = \"\";\r\n } else {\r\n fileName.textContent = input.files[0].name;\r\n msg.textContent = \"\";\r\n }\r\n}\r\n\r\nvar checkBoxes = document.querySelectorAll('input[type=checkbox]');\r\nif (checkBoxes.length) {\r\n each(checkBoxes, checkBox => {\r\n checkBox.addEventListener('change', function (e) {\r\n document.getElementById('segmento').checked = checkBox.checked;\r\n var text = document.getElementById(`tipo-${checkBox.id}`);\r\n if(text) text.disabled = checkBox.checked ? false : true; \r\n });\r\n });\r\n}\r\n","export default function hasParent(el, fn) {\r\n\r\n if (!fn) return false;\r\n \r\n if (!(fn instanceof Function)) {\r\n const target = fn;\r\n fn = parent => parent === target;\r\n }\r\n \r\n while (el = el.parentElement) {\r\n \r\n if (fn(el)) return true;\r\n \r\n }\r\n \r\n return false;\r\n \r\n };","export default function(url, fn, err) {\r\n const request = new XMLHttpRequest();\r\n request.open('get', encodeURI(url), true);\r\n request.onload = function() {\r\n if (request.status >= 200 && request.status < 400) {\r\n fn && fn(JSON.parse(request.responseText));\r\n } else {\r\n err && err(request);\r\n }\r\n };\r\n request.send();\r\n return request;\r\n}\r\n"],"sourceRoot":""}