X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/5cb7fbb3d17a39f8fe130e3a9a5f9e43484574a2..53aa7259bb0612eb48a17d0b954ad71ea37d87a4:/vendor/assets/iD/iD.js diff --git a/vendor/assets/iD/iD.js b/vendor/assets/iD/iD.js index c91915940..088e252a2 100644 --- a/vendor/assets/iD/iD.js +++ b/vendor/assets/iD/iD.js @@ -7,7 +7,7 @@ }; // https://github.com/zloirock/core-js/issues/86#issuecomment-115759028 - var global$1m = + var global$1o = // eslint-disable-next-line es/no-global-this -- safe check(typeof globalThis == 'object' && globalThis) || check(typeof window == 'object' && window) || @@ -19,7 +19,7 @@ var objectGetOwnPropertyDescriptor = {}; - var fails$S = function (exec) { + var fails$V = function (exec) { try { return !!exec(); } catch (error) { @@ -27,17 +27,27 @@ } }; - var fails$R = fails$S; + var fails$U = fails$V; // Detect IE8's incomplete defineProperty implementation - var descriptors = !fails$R(function () { + var descriptors = !fails$U(function () { // eslint-disable-next-line es/no-object-defineproperty -- required for testing return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7; }); + var fails$T = fails$V; + + var functionBindNative = !fails$T(function () { + var test = (function () { /* empty */ }).bind(); + // eslint-disable-next-line no-prototype-builtins -- safe + return typeof test != 'function' || test.hasOwnProperty('prototype'); + }); + + var NATIVE_BIND$4 = functionBindNative; + var call$q = Function.prototype.call; - var functionCall = call$q.bind ? call$q.bind(call$q) : function () { + var functionCall = NATIVE_BIND$4 ? call$q.bind(call$q) : function () { return call$q.apply(call$q, arguments); }; @@ -66,13 +76,15 @@ }; }; + var NATIVE_BIND$3 = functionBindNative; + var FunctionPrototype$3 = Function.prototype; - var bind$h = FunctionPrototype$3.bind; + var bind$g = FunctionPrototype$3.bind; var call$p = FunctionPrototype$3.call; - var callBind = bind$h && bind$h.bind(call$p); + var uncurryThis$Y = NATIVE_BIND$3 && bind$g.bind(call$p, call$p); - var functionUncurryThis = bind$h ? function (fn) { - return fn && callBind(call$p, fn); + var functionUncurryThis = NATIVE_BIND$3 ? function (fn) { + return fn && uncurryThis$Y(fn); } : function (fn) { return fn && function () { return call$p.apply(fn, arguments); @@ -88,16 +100,16 @@ return stringSlice$c(toString$n(it), 8, -1); }; - var global$1l = global$1m; + var global$1n = global$1o; var uncurryThis$W = functionUncurryThis; - var fails$Q = fails$S; + var fails$S = fails$V; var classof$e = classofRaw$1; - var Object$5 = global$1l.Object; + var Object$5 = global$1n.Object; var split$4 = uncurryThis$W(''.split); // fallback for non-array-like ES3 and non-enumerable old V8 strings - var indexedObject = fails$Q(function () { + var indexedObject = fails$S(function () { // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346 // eslint-disable-next-line no-prototype-builtins -- safe return !Object$5('z').propertyIsEnumerable(0); @@ -105,14 +117,14 @@ return classof$e(it) == 'String' ? split$4(it, '') : Object$5(it); } : Object$5; - var global$1k = global$1m; + var global$1m = global$1o; - var TypeError$o = global$1k.TypeError; + var TypeError$p = global$1m.TypeError; // `RequireObjectCoercible` abstract operation // https://tc39.es/ecma262/#sec-requireobjectcoercible var requireObjectCoercible$e = function (it) { - if (it == undefined) throw TypeError$o("Can't call method on " + it); + if (it == undefined) throw TypeError$p("Can't call method on " + it); return it; }; @@ -120,7 +132,7 @@ var IndexedObject$4 = indexedObject; var requireObjectCoercible$d = requireObjectCoercible$e; - var toIndexedObject$c = function (it) { + var toIndexedObject$d = function (it) { return IndexedObject$4(requireObjectCoercible$d(it)); }; @@ -136,7 +148,7 @@ return typeof it == 'object' ? it !== null : isCallable$q(it); }; - var global$1j = global$1m; + var global$1l = global$1o; var isCallable$p = isCallable$r; var aFunction = function (argument) { @@ -144,7 +156,7 @@ }; var getBuiltIn$b = function (namespace, method) { - return arguments.length < 2 ? aFunction(global$1j[namespace]) : global$1j[namespace] && global$1j[namespace][method]; + return arguments.length < 2 ? aFunction(global$1l[namespace]) : global$1l[namespace] && global$1l[namespace][method]; }; var uncurryThis$V = functionUncurryThis; @@ -155,11 +167,11 @@ var engineUserAgent = getBuiltIn$a('navigator', 'userAgent') || ''; - var global$1i = global$1m; + var global$1k = global$1o; var userAgent$7 = engineUserAgent; - var process$4 = global$1i.process; - var Deno = global$1i.Deno; + var process$4 = global$1k.process; + var Deno = global$1k.Deno; var versions = process$4 && process$4.versions || Deno && Deno.version; var v8 = versions && versions.v8; var match, version$1; @@ -186,10 +198,10 @@ /* eslint-disable es/no-symbol -- required for testing */ var V8_VERSION$3 = engineV8Version; - var fails$P = fails$S; + var fails$R = fails$V; // eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing - var nativeSymbol = !!Object.getOwnPropertySymbols && !fails$P(function () { + var nativeSymbol = !!Object.getOwnPropertySymbols && !fails$R(function () { var symbol = Symbol(); // Chrome 38 Symbol has incorrect toString conversion // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances @@ -206,13 +218,13 @@ && !Symbol.sham && typeof Symbol.iterator == 'symbol'; - var global$1h = global$1m; + var global$1j = global$1o; var getBuiltIn$9 = getBuiltIn$b; var isCallable$o = isCallable$r; var isPrototypeOf$9 = objectIsPrototypeOf; var USE_SYMBOL_AS_UID$1 = useSymbolAsUid; - var Object$4 = global$1h.Object; + var Object$4 = global$1j.Object; var isSymbol$6 = USE_SYMBOL_AS_UID$1 ? function (it) { return typeof it == 'symbol'; @@ -221,9 +233,9 @@ return isCallable$o($Symbol) && isPrototypeOf$9($Symbol.prototype, Object$4(it)); }; - var global$1g = global$1m; + var global$1i = global$1o; - var String$6 = global$1g.String; + var String$6 = global$1i.String; var tryToString$5 = function (argument) { try { @@ -233,16 +245,16 @@ } }; - var global$1f = global$1m; + var global$1h = global$1o; var isCallable$n = isCallable$r; var tryToString$4 = tryToString$5; - var TypeError$n = global$1f.TypeError; + var TypeError$o = global$1h.TypeError; // `Assert: IsCallable(argument) is true` var aCallable$a = function (argument) { if (isCallable$n(argument)) return argument; - throw TypeError$n(tryToString$4(argument) + ' is not a function'); + throw TypeError$o(tryToString$4(argument) + ' is not a function'); }; var aCallable$9 = aCallable$a; @@ -254,12 +266,12 @@ return func == null ? undefined : aCallable$9(func); }; - var global$1e = global$1m; + var global$1g = global$1o; var call$o = functionCall; var isCallable$m = isCallable$r; var isObject$r = isObject$s; - var TypeError$m = global$1e.TypeError; + var TypeError$n = global$1g.TypeError; // `OrdinaryToPrimitive` abstract operation // https://tc39.es/ecma262/#sec-ordinarytoprimitive @@ -268,31 +280,31 @@ if (pref === 'string' && isCallable$m(fn = input.toString) && !isObject$r(val = call$o(fn, input))) return val; if (isCallable$m(fn = input.valueOf) && !isObject$r(val = call$o(fn, input))) return val; if (pref !== 'string' && isCallable$m(fn = input.toString) && !isObject$r(val = call$o(fn, input))) return val; - throw TypeError$m("Can't convert object to primitive value"); + throw TypeError$n("Can't convert object to primitive value"); }; var shared$5 = {exports: {}}; var isPure = false; - var global$1d = global$1m; + var global$1f = global$1o; // eslint-disable-next-line es/no-object-defineproperty -- safe - var defineProperty$b = Object.defineProperty; + var defineProperty$d = Object.defineProperty; var setGlobal$3 = function (key, value) { try { - defineProperty$b(global$1d, key, { value: value, configurable: true, writable: true }); + defineProperty$d(global$1f, key, { value: value, configurable: true, writable: true }); } catch (error) { - global$1d[key] = value; + global$1f[key] = value; } return value; }; - var global$1c = global$1m; + var global$1e = global$1o; var setGlobal$2 = setGlobal$3; var SHARED = '__core-js_shared__'; - var store$4 = global$1c[SHARED] || setGlobal$2(SHARED, {}); + var store$4 = global$1e[SHARED] || setGlobal$2(SHARED, {}); var sharedStore = store$4; @@ -301,31 +313,33 @@ (shared$5.exports = function (key, value) { return store$3[key] || (store$3[key] = value !== undefined ? value : {}); })('versions', []).push({ - version: '3.19.1', + version: '3.21.0', mode: 'global', - copyright: '© 2021 Denis Pushkarev (zloirock.ru)' + copyright: '© 2014-2022 Denis Pushkarev (zloirock.ru)', + license: 'https://github.com/zloirock/core-js/blob/v3.21.0/LICENSE', + source: 'https://github.com/zloirock/core-js' }); - var global$1b = global$1m; + var global$1d = global$1o; var requireObjectCoercible$c = requireObjectCoercible$e; - var Object$3 = global$1b.Object; + var Object$3 = global$1d.Object; // `ToObject` abstract operation // https://tc39.es/ecma262/#sec-toobject - var toObject$j = function (argument) { + var toObject$i = function (argument) { return Object$3(requireObjectCoercible$c(argument)); }; var uncurryThis$U = functionUncurryThis; - var toObject$i = toObject$j; + var toObject$h = toObject$i; var hasOwnProperty$3 = uncurryThis$U({}.hasOwnProperty); // `HasOwnProperty` abstract operation // https://tc39.es/ecma262/#sec-hasownproperty var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) { - return hasOwnProperty$3(toObject$i(it), key); + return hasOwnProperty$3(toObject$h(it), key); }; var uncurryThis$T = functionUncurryThis; @@ -338,7 +352,7 @@ return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$m(++id$2 + postfix, 36); }; - var global$1a = global$1m; + var global$1c = global$1o; var shared$4 = shared$5.exports; var hasOwn$l = hasOwnProperty_1; var uid$4 = uid$5; @@ -346,7 +360,7 @@ var USE_SYMBOL_AS_UID = useSymbolAsUid; var WellKnownSymbolsStore$1 = shared$4('wks'); - var Symbol$3 = global$1a.Symbol; + var Symbol$3 = global$1c.Symbol; var symbolFor = Symbol$3 && Symbol$3['for']; var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol$3 : Symbol$3 && Symbol$3.withoutSetter || uid$4; @@ -363,7 +377,7 @@ } return WellKnownSymbolsStore$1[name]; }; - var global$19 = global$1m; + var global$1b = global$1o; var call$n = functionCall; var isObject$q = isObject$s; var isSymbol$5 = isSymbol$6; @@ -371,7 +385,7 @@ var ordinaryToPrimitive = ordinaryToPrimitive$1; var wellKnownSymbol$s = wellKnownSymbol$t; - var TypeError$l = global$19.TypeError; + var TypeError$m = global$1b.TypeError; var TO_PRIMITIVE$1 = wellKnownSymbol$s('toPrimitive'); // `ToPrimitive` abstract operation @@ -384,7 +398,7 @@ if (pref === undefined) pref = 'default'; result = call$n(exoticToPrim, input, pref); if (!isObject$q(result) || isSymbol$5(result)) return result; - throw TypeError$l("Can't convert object to primitive value"); + throw TypeError$m("Can't convert object to primitive value"); } if (pref === undefined) pref = 'number'; return ordinaryToPrimitive(input, pref); @@ -400,10 +414,10 @@ return isSymbol$4(key) ? key : key + ''; }; - var global$18 = global$1m; + var global$1a = global$1o; var isObject$p = isObject$s; - var document$3 = global$18.document; + var document$3 = global$1a.document; // typeof document.createElement is 'object' in old IE var EXISTS$1 = isObject$p(document$3) && isObject$p(document$3.createElement); @@ -411,84 +425,118 @@ return EXISTS$1 ? document$3.createElement(it) : {}; }; - var DESCRIPTORS$n = descriptors; - var fails$O = fails$S; + var DESCRIPTORS$p = descriptors; + var fails$Q = fails$V; var createElement$1 = documentCreateElement$2; - // Thank's IE8 for his funny defineProperty - var ie8DomDefine = !DESCRIPTORS$n && !fails$O(function () { - // eslint-disable-next-line es/no-object-defineproperty -- requied for testing + // Thanks to IE8 for its funny defineProperty + var ie8DomDefine = !DESCRIPTORS$p && !fails$Q(function () { + // eslint-disable-next-line es/no-object-defineproperty -- required for testing return Object.defineProperty(createElement$1('div'), 'a', { get: function () { return 7; } }).a != 7; }); - var DESCRIPTORS$m = descriptors; + var DESCRIPTORS$o = descriptors; var call$m = functionCall; var propertyIsEnumerableModule$2 = objectPropertyIsEnumerable; var createPropertyDescriptor$6 = createPropertyDescriptor$7; - var toIndexedObject$b = toIndexedObject$c; + var toIndexedObject$c = toIndexedObject$d; var toPropertyKey$4 = toPropertyKey$5; var hasOwn$k = hasOwnProperty_1; var IE8_DOM_DEFINE$1 = ie8DomDefine; // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe - var $getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor; + var $getOwnPropertyDescriptor$2 = Object.getOwnPropertyDescriptor; // `Object.getOwnPropertyDescriptor` method // https://tc39.es/ecma262/#sec-object.getownpropertydescriptor - objectGetOwnPropertyDescriptor.f = DESCRIPTORS$m ? $getOwnPropertyDescriptor$1 : function getOwnPropertyDescriptor(O, P) { - O = toIndexedObject$b(O); + objectGetOwnPropertyDescriptor.f = DESCRIPTORS$o ? $getOwnPropertyDescriptor$2 : function getOwnPropertyDescriptor(O, P) { + O = toIndexedObject$c(O); P = toPropertyKey$4(P); if (IE8_DOM_DEFINE$1) try { - return $getOwnPropertyDescriptor$1(O, P); + return $getOwnPropertyDescriptor$2(O, P); } catch (error) { /* empty */ } if (hasOwn$k(O, P)) return createPropertyDescriptor$6(!call$m(propertyIsEnumerableModule$2.f, O, P), O[P]); }; var objectDefineProperty = {}; - var global$17 = global$1m; + var DESCRIPTORS$n = descriptors; + var fails$P = fails$V; + + // V8 ~ Chrome 36- + // https://bugs.chromium.org/p/v8/issues/detail?id=3334 + var v8PrototypeDefineBug = DESCRIPTORS$n && fails$P(function () { + // eslint-disable-next-line es/no-object-defineproperty -- required for testing + return Object.defineProperty(function () { /* empty */ }, 'prototype', { + value: 42, + writable: false + }).prototype != 42; + }); + + var global$19 = global$1o; var isObject$o = isObject$s; - var String$5 = global$17.String; - var TypeError$k = global$17.TypeError; + var String$5 = global$19.String; + var TypeError$l = global$19.TypeError; // `Assert: Type(argument) is Object` var anObject$n = function (argument) { if (isObject$o(argument)) return argument; - throw TypeError$k(String$5(argument) + ' is not an object'); + throw TypeError$l(String$5(argument) + ' is not an object'); }; - var global$16 = global$1m; - var DESCRIPTORS$l = descriptors; + var global$18 = global$1o; + var DESCRIPTORS$m = descriptors; var IE8_DOM_DEFINE = ie8DomDefine; + var V8_PROTOTYPE_DEFINE_BUG$1 = v8PrototypeDefineBug; var anObject$m = anObject$n; var toPropertyKey$3 = toPropertyKey$5; - var TypeError$j = global$16.TypeError; + var TypeError$k = global$18.TypeError; // eslint-disable-next-line es/no-object-defineproperty -- safe var $defineProperty$1 = Object.defineProperty; + // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe + var $getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor; + var ENUMERABLE = 'enumerable'; + var CONFIGURABLE$1 = 'configurable'; + var WRITABLE = 'writable'; // `Object.defineProperty` method // https://tc39.es/ecma262/#sec-object.defineproperty - objectDefineProperty.f = DESCRIPTORS$l ? $defineProperty$1 : function defineProperty(O, P, Attributes) { + objectDefineProperty.f = DESCRIPTORS$m ? V8_PROTOTYPE_DEFINE_BUG$1 ? function defineProperty(O, P, Attributes) { + anObject$m(O); + P = toPropertyKey$3(P); + anObject$m(Attributes); + if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) { + var current = $getOwnPropertyDescriptor$1(O, P); + if (current && current[WRITABLE]) { + O[P] = Attributes.value; + Attributes = { + configurable: CONFIGURABLE$1 in Attributes ? Attributes[CONFIGURABLE$1] : current[CONFIGURABLE$1], + enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE], + writable: false + }; + } + } return $defineProperty$1(O, P, Attributes); + } : $defineProperty$1 : function defineProperty(O, P, Attributes) { anObject$m(O); P = toPropertyKey$3(P); anObject$m(Attributes); if (IE8_DOM_DEFINE) try { return $defineProperty$1(O, P, Attributes); } catch (error) { /* empty */ } - if ('get' in Attributes || 'set' in Attributes) throw TypeError$j('Accessors not supported'); + if ('get' in Attributes || 'set' in Attributes) throw TypeError$k('Accessors not supported'); if ('value' in Attributes) O[P] = Attributes.value; return O; }; - var DESCRIPTORS$k = descriptors; + var DESCRIPTORS$l = descriptors; var definePropertyModule$7 = objectDefineProperty; var createPropertyDescriptor$5 = createPropertyDescriptor$7; - var createNonEnumerableProperty$b = DESCRIPTORS$k ? function (object, key, value) { + var createNonEnumerableProperty$b = DESCRIPTORS$l ? function (object, key, value) { return definePropertyModule$7.f(object, key, createPropertyDescriptor$5(1, value)); } : function (object, key, value) { object[key] = value; @@ -512,11 +560,11 @@ var inspectSource$4 = store$2.inspectSource; - var global$15 = global$1m; + var global$17 = global$1o; var isCallable$k = isCallable$r; var inspectSource$3 = inspectSource$4; - var WeakMap$1 = global$15.WeakMap; + var WeakMap$1 = global$17.WeakMap; var nativeWeakMap = isCallable$k(WeakMap$1) && /native code/.test(inspectSource$3(WeakMap$1)); @@ -532,7 +580,7 @@ var hiddenKeys$6 = {}; var NATIVE_WEAK_MAP = nativeWeakMap; - var global$14 = global$1m; + var global$16 = global$1o; var uncurryThis$R = functionUncurryThis; var isObject$n = isObject$s; var createNonEnumerableProperty$a = createNonEnumerableProperty$b; @@ -542,8 +590,8 @@ var hiddenKeys$5 = hiddenKeys$6; var OBJECT_ALREADY_INITIALIZED = 'Object already initialized'; - var TypeError$i = global$14.TypeError; - var WeakMap = global$14.WeakMap; + var TypeError$j = global$16.TypeError; + var WeakMap = global$16.WeakMap; var set$4, get$5, has; var enforce = function (it) { @@ -554,7 +602,7 @@ return function (it) { var state; if (!isObject$n(it) || (state = get$5(it)).type !== TYPE) { - throw TypeError$i('Incompatible receiver, ' + TYPE + ' required'); + throw TypeError$j('Incompatible receiver, ' + TYPE + ' required'); } return state; }; }; @@ -565,7 +613,7 @@ var wmhas = uncurryThis$R(store$1.has); var wmset = uncurryThis$R(store$1.set); set$4 = function (it, metadata) { - if (wmhas(store$1, it)) throw new TypeError$i(OBJECT_ALREADY_INITIALIZED); + if (wmhas(store$1, it)) throw new TypeError$j(OBJECT_ALREADY_INITIALIZED); metadata.facade = it; wmset(store$1, it, metadata); return metadata; @@ -580,7 +628,7 @@ var STATE = sharedKey$3('state'); hiddenKeys$5[STATE] = true; set$4 = function (it, metadata) { - if (hasOwn$j(it, STATE)) throw new TypeError$i(OBJECT_ALREADY_INITIALIZED); + if (hasOwn$j(it, STATE)) throw new TypeError$j(OBJECT_ALREADY_INITIALIZED); metadata.facade = it; createNonEnumerableProperty$a(it, STATE, metadata); return metadata; @@ -601,17 +649,17 @@ getterFor: getterFor }; - var DESCRIPTORS$j = descriptors; + var DESCRIPTORS$k = descriptors; var hasOwn$i = hasOwnProperty_1; var FunctionPrototype$2 = Function.prototype; // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe - var getDescriptor = DESCRIPTORS$j && Object.getOwnPropertyDescriptor; + var getDescriptor = DESCRIPTORS$k && Object.getOwnPropertyDescriptor; var EXISTS = hasOwn$i(FunctionPrototype$2, 'name'); // additional protection from minified / mangled / dropped function names var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something'; - var CONFIGURABLE = EXISTS && (!DESCRIPTORS$j || (DESCRIPTORS$j && getDescriptor(FunctionPrototype$2, 'name').configurable)); + var CONFIGURABLE = EXISTS && (!DESCRIPTORS$k || (DESCRIPTORS$k && getDescriptor(FunctionPrototype$2, 'name').configurable)); var functionName = { EXISTS: EXISTS, @@ -619,7 +667,7 @@ CONFIGURABLE: CONFIGURABLE }; - var global$13 = global$1m; + var global$15 = global$1o; var isCallable$j = isCallable$r; var hasOwn$h = hasOwnProperty_1; var createNonEnumerableProperty$9 = createNonEnumerableProperty$b; @@ -650,7 +698,7 @@ state.source = TEMPLATE.join(typeof name == 'string' ? name : ''); } } - if (O === global$13) { + if (O === global$15) { if (simple) O[key] = value; else setGlobal$1(key, value); return; @@ -681,15 +729,15 @@ var toIntegerOrInfinity$a = toIntegerOrInfinity$b; - var max$4 = Math.max; + var max$5 = Math.max; var min$9 = Math.min; // Helper for a popular repeating case of the spec: // Let integer be ? ToInteger(index). // If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length). - var toAbsoluteIndex$8 = function (index, length) { + var toAbsoluteIndex$9 = function (index, length) { var integer = toIntegerOrInfinity$a(index); - return integer < 0 ? max$4(integer + length, 0) : min$9(integer, length); + return integer < 0 ? max$5(integer + length, 0) : min$9(integer, length); }; var toIntegerOrInfinity$9 = toIntegerOrInfinity$b; @@ -706,20 +754,20 @@ // `LengthOfArrayLike` abstract operation // https://tc39.es/ecma262/#sec-lengthofarraylike - var lengthOfArrayLike$g = function (obj) { + var lengthOfArrayLike$i = function (obj) { return toLength$b(obj.length); }; - var toIndexedObject$a = toIndexedObject$c; - var toAbsoluteIndex$7 = toAbsoluteIndex$8; - var lengthOfArrayLike$f = lengthOfArrayLike$g; + var toIndexedObject$b = toIndexedObject$d; + var toAbsoluteIndex$8 = toAbsoluteIndex$9; + var lengthOfArrayLike$h = lengthOfArrayLike$i; // `Array.prototype.{ indexOf, includes }` methods implementation var createMethod$6 = function (IS_INCLUDES) { return function ($this, el, fromIndex) { - var O = toIndexedObject$a($this); - var length = lengthOfArrayLike$f(O); - var index = toAbsoluteIndex$7(fromIndex, length); + var O = toIndexedObject$b($this); + var length = lengthOfArrayLike$h(O); + var index = toAbsoluteIndex$8(fromIndex, length); var value; // Array#includes uses SameValueZero equality algorithm // eslint-disable-next-line no-self-compare -- NaN check @@ -745,14 +793,14 @@ var uncurryThis$Q = functionUncurryThis; var hasOwn$g = hasOwnProperty_1; - var toIndexedObject$9 = toIndexedObject$c; + var toIndexedObject$a = toIndexedObject$d; var indexOf$1 = arrayIncludes.indexOf; var hiddenKeys$4 = hiddenKeys$6; var push$a = uncurryThis$Q([].push); var objectKeysInternal = function (object, names) { - var O = toIndexedObject$9(object); + var O = toIndexedObject$a(object); var i = 0; var result = []; var key; @@ -812,17 +860,19 @@ var getOwnPropertyDescriptorModule$3 = objectGetOwnPropertyDescriptor; var definePropertyModule$6 = objectDefineProperty; - var copyConstructorProperties$2 = function (target, source) { + var copyConstructorProperties$2 = function (target, source, exceptions) { var keys = ownKeys(source); var defineProperty = definePropertyModule$6.f; var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule$3.f; for (var i = 0; i < keys.length; i++) { var key = keys[i]; - if (!hasOwn$f(target, key)) defineProperty(target, key, getOwnPropertyDescriptor(source, key)); + if (!hasOwn$f(target, key) && !(exceptions && hasOwn$f(exceptions, key))) { + defineProperty(target, key, getOwnPropertyDescriptor(source, key)); + } } }; - var fails$N = fails$S; + var fails$O = fails$V; var isCallable$i = isCallable$r; var replacement = /#|\.prototype\./; @@ -831,7 +881,7 @@ var value = data[normalize$1(feature)]; return value == POLYFILL ? true : value == NATIVE ? false - : isCallable$i(detection) ? fails$N(detection) + : isCallable$i(detection) ? fails$O(detection) : !!detection; }; @@ -845,7 +895,7 @@ var isForced_1 = isForced$5; - var global$12 = global$1m; + var global$14 = global$1o; var getOwnPropertyDescriptor$4 = objectGetOwnPropertyDescriptor.f; var createNonEnumerableProperty$8 = createNonEnumerableProperty$b; var redefine$g = redefine$h.exports; @@ -874,11 +924,11 @@ var STATIC = options.stat; var FORCED, target, key, targetProperty, sourceProperty, descriptor; if (GLOBAL) { - target = global$12; + target = global$14; } else if (STATIC) { - target = global$12[TARGET] || setGlobal(TARGET, {}); + target = global$14[TARGET] || setGlobal(TARGET, {}); } else { - target = (global$12[TARGET] || {}).prototype; + target = (global$14[TARGET] || {}).prototype; } if (target) for (key in source) { sourceProperty = source[key]; @@ -902,10 +952,10 @@ }; var $$1e = _export; - var global$11 = global$1m; + var global$13 = global$1o; var uncurryThis$O = functionUncurryThis; - var Date$1 = global$11.Date; + var Date$1 = global$13.Date; var getTime$2 = uncurryThis$O(Date$1.prototype.getTime); // `Date.now` method @@ -938,17 +988,11 @@ function _typeof(obj) { "@babel/helpers - typeof"; - if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { - _typeof = function (obj) { - return typeof obj; - }; - } else { - _typeof = function (obj) { - return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; - }; - } - - return _typeof(obj); + return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { + return typeof obj; + } : function (obj) { + return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; + }, _typeof(obj); } function _classCallCheck$1(instance, Constructor) { @@ -970,6 +1014,9 @@ function _createClass$1(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$1(Constructor.prototype, protoProps); if (staticProps) _defineProperties$1(Constructor, staticProps); + Object.defineProperty(Constructor, "prototype", { + writable: false + }); return Constructor; } @@ -1121,17 +1168,17 @@ } var $$1d = _export; - var global$10 = global$1m; + var global$12 = global$1o; // `globalThis` object // https://tc39.es/ecma262/#sec-globalthis $$1d({ global: true }, { - globalThis: global$10 + globalThis: global$12 }); - var global$$ = global$1m; + var global$11 = global$1o; - var path$1 = global$$; + var path$1 = global$11; var wellKnownSymbolWrapped = {}; @@ -1142,11 +1189,11 @@ var path = path$1; var hasOwn$e = hasOwnProperty_1; var wrappedWellKnownSymbolModule$1 = wellKnownSymbolWrapped; - var defineProperty$a = objectDefineProperty.f; + var defineProperty$c = objectDefineProperty.f; var defineWellKnownSymbol$4 = function (NAME) { var Symbol = path.Symbol || (path.Symbol = {}); - if (!hasOwn$e(Symbol, NAME)) defineProperty$a(Symbol, NAME, { + if (!hasOwn$e(Symbol, NAME)) defineProperty$c(Symbol, NAME, { value: wrappedWellKnownSymbolModule$1.f(NAME) }); }; @@ -1157,6 +1204,8 @@ // https://tc39.es/ecma262/#sec-symbol.iterator defineWellKnownSymbol$3('iterator'); + var objectDefineProperties = {}; + var internalObjectKeys = objectKeysInternal; var enumBugKeys$1 = enumBugKeys$3; @@ -1167,18 +1216,19 @@ return internalObjectKeys(O, enumBugKeys$1); }; - var DESCRIPTORS$i = descriptors; + var DESCRIPTORS$j = descriptors; + var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug; var definePropertyModule$5 = objectDefineProperty; var anObject$k = anObject$n; - var toIndexedObject$8 = toIndexedObject$c; + var toIndexedObject$9 = toIndexedObject$d; var objectKeys$3 = objectKeys$4; // `Object.defineProperties` method // https://tc39.es/ecma262/#sec-object.defineproperties // eslint-disable-next-line es/no-object-defineproperties -- safe - var objectDefineProperties = DESCRIPTORS$i ? Object.defineProperties : function defineProperties(O, Properties) { + objectDefineProperties.f = DESCRIPTORS$j && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) { anObject$k(O); - var props = toIndexedObject$8(Properties); + var props = toIndexedObject$9(Properties); var keys = objectKeys$3(Properties); var length = keys.length; var index = 0; @@ -1194,7 +1244,7 @@ /* global ActiveXObject -- old IE, WSH */ var anObject$j = anObject$n; - var defineProperties$2 = objectDefineProperties; + var definePropertiesModule$1 = objectDefineProperties; var enumBugKeys = enumBugKeys$3; var hiddenKeys$2 = hiddenKeys$6; var html$1 = html$2; @@ -1272,7 +1322,7 @@ // add "__proto__" for Object.getPrototypeOf polyfill result[IE_PROTO$1] = O; } else result = NullProtoObject(); - return Properties === undefined ? result : defineProperties$2(result, Properties); + return Properties === undefined ? result : definePropertiesModule$1.f(result, Properties); }; var wellKnownSymbol$q = wellKnownSymbol$t; @@ -1298,30 +1348,30 @@ var iterators = {}; - var fails$M = fails$S; + var fails$N = fails$V; - var correctPrototypeGetter = !fails$M(function () { + var correctPrototypeGetter = !fails$N(function () { function F() { /* empty */ } F.prototype.constructor = null; // eslint-disable-next-line es/no-object-getprototypeof -- required for testing return Object.getPrototypeOf(new F()) !== F.prototype; }); - var global$_ = global$1m; + var global$10 = global$1o; var hasOwn$d = hasOwnProperty_1; var isCallable$h = isCallable$r; - var toObject$h = toObject$j; + var toObject$g = toObject$i; var sharedKey$1 = sharedKey$4; var CORRECT_PROTOTYPE_GETTER$1 = correctPrototypeGetter; var IE_PROTO = sharedKey$1('IE_PROTO'); - var Object$2 = global$_.Object; + var Object$2 = global$10.Object; var ObjectPrototype$4 = Object$2.prototype; // `Object.getPrototypeOf` method // https://tc39.es/ecma262/#sec-object.getprototypeof var objectGetPrototypeOf = CORRECT_PROTOTYPE_GETTER$1 ? Object$2.getPrototypeOf : function (O) { - var object = toObject$h(O); + var object = toObject$g(O); if (hasOwn$d(object, IE_PROTO)) return object[IE_PROTO]; var constructor = object.constructor; if (isCallable$h(constructor) && object instanceof constructor) { @@ -1329,7 +1379,7 @@ } return object instanceof Object$2 ? ObjectPrototype$4 : null; }; - var fails$L = fails$S; + var fails$M = fails$V; var isCallable$g = isCallable$r; var getPrototypeOf$4 = objectGetPrototypeOf; var redefine$e = redefine$h.exports; @@ -1353,7 +1403,7 @@ } } - var NEW_ITERATOR_PROTOTYPE = IteratorPrototype$2 == undefined || fails$L(function () { + var NEW_ITERATOR_PROTOTYPE = IteratorPrototype$2 == undefined || fails$M(function () { var test = {}; // FF44- legacy iterators case return IteratorPrototype$2[ITERATOR$a].call(test) !== test; @@ -1374,15 +1424,16 @@ BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS$1 }; - var defineProperty$9 = objectDefineProperty.f; + var defineProperty$b = objectDefineProperty.f; var hasOwn$c = hasOwnProperty_1; var wellKnownSymbol$o = wellKnownSymbol$t; var TO_STRING_TAG$4 = wellKnownSymbol$o('toStringTag'); - var setToStringTag$a = function (it, TAG, STATIC) { - if (it && !hasOwn$c(it = STATIC ? it : it.prototype, TO_STRING_TAG$4)) { - defineProperty$9(it, TO_STRING_TAG$4, { configurable: true, value: TAG }); + var setToStringTag$a = function (target, TAG, STATIC) { + if (target && !STATIC) target = target.prototype; + if (target && !hasOwn$c(target, TO_STRING_TAG$4)) { + defineProperty$b(target, TO_STRING_TAG$4, { configurable: true, value: TAG }); } }; @@ -1394,23 +1445,23 @@ var returnThis$1 = function () { return this; }; - var createIteratorConstructor$2 = function (IteratorConstructor, NAME, next) { + var createIteratorConstructor$2 = function (IteratorConstructor, NAME, next, ENUMERABLE_NEXT) { var TO_STRING_TAG = NAME + ' Iterator'; - IteratorConstructor.prototype = create$9(IteratorPrototype$1, { next: createPropertyDescriptor$4(1, next) }); + IteratorConstructor.prototype = create$9(IteratorPrototype$1, { next: createPropertyDescriptor$4(+!ENUMERABLE_NEXT, next) }); setToStringTag$9(IteratorConstructor, TO_STRING_TAG, false); Iterators$4[TO_STRING_TAG] = returnThis$1; return IteratorConstructor; }; - var global$Z = global$1m; + var global$$ = global$1o; var isCallable$f = isCallable$r; - var String$4 = global$Z.String; - var TypeError$h = global$Z.TypeError; + var String$4 = global$$.String; + var TypeError$i = global$$.TypeError; var aPossiblePrototype$1 = function (argument) { if (typeof argument == 'object' || isCallable$f(argument)) return argument; - throw TypeError$h("Can't set " + String$4(argument) + ' as a prototype'); + throw TypeError$i("Can't set " + String$4(argument) + ' as a prototype'); }; /* eslint-disable no-proto -- safe */ @@ -1456,7 +1507,7 @@ var Iterators$3 = iterators; var IteratorsCore = iteratorsCore; - var PROPER_FUNCTION_NAME$4 = FunctionName$1.PROPER; + var PROPER_FUNCTION_NAME$3 = FunctionName$1.PROPER; var CONFIGURABLE_FUNCTION_NAME$1 = FunctionName$1.CONFIGURABLE; var IteratorPrototype = IteratorsCore.IteratorPrototype; var BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS; @@ -1507,7 +1558,7 @@ } // fix Array.prototype.{ values, @@iterator }.name in V8 / FF - if (PROPER_FUNCTION_NAME$4 && DEFAULT == VALUES && nativeIterator && nativeIterator.name !== VALUES) { + if (PROPER_FUNCTION_NAME$3 && DEFAULT == VALUES && nativeIterator && nativeIterator.name !== VALUES) { if (CONFIGURABLE_FUNCTION_NAME$1) { createNonEnumerableProperty$7(IterablePrototype, 'name', VALUES); } else { @@ -1539,11 +1590,13 @@ return methods; }; - var toIndexedObject$7 = toIndexedObject$c; + var toIndexedObject$8 = toIndexedObject$d; var addToUnscopables$5 = addToUnscopables$6; var Iterators$2 = iterators; var InternalStateModule$8 = internalState; + var defineProperty$a = objectDefineProperty.f; var defineIterator$2 = defineIterator$3; + var DESCRIPTORS$i = descriptors; var ARRAY_ITERATOR = 'Array Iterator'; var setInternalState$8 = InternalStateModule$8.set; @@ -1562,7 +1615,7 @@ var es_array_iterator = defineIterator$2(Array, 'Array', function (iterated, kind) { setInternalState$8(this, { type: ARRAY_ITERATOR, - target: toIndexedObject$7(iterated), // target + target: toIndexedObject$8(iterated), // target index: 0, // next index kind: kind // kind }); @@ -1585,13 +1638,18 @@ // argumentsList[@@iterator] is %ArrayProto_values% // https://tc39.es/ecma262/#sec-createunmappedargumentsobject // https://tc39.es/ecma262/#sec-createmappedargumentsobject - Iterators$2.Arguments = Iterators$2.Array; + var values = Iterators$2.Arguments = Iterators$2.Array; // https://tc39.es/ecma262/#sec-array.prototype-@@unscopables addToUnscopables$5('keys'); addToUnscopables$5('values'); addToUnscopables$5('entries'); + // V8 ~ Chrome 45- bug + if (DESCRIPTORS$i && values.name !== 'values') try { + defineProperty$a(values, 'name', { value: 'values' }); + } catch (error) { /* empty */ } + var wellKnownSymbol$m = wellKnownSymbol$t; var TO_STRING_TAG$3 = wellKnownSymbol$m('toStringTag'); @@ -1601,14 +1659,14 @@ var toStringTagSupport = String(test$2) === '[object z]'; - var global$Y = global$1m; + var global$_ = global$1o; var TO_STRING_TAG_SUPPORT$2 = toStringTagSupport; var isCallable$d = isCallable$r; var classofRaw = classofRaw$1; var wellKnownSymbol$l = wellKnownSymbol$t; var TO_STRING_TAG$2 = wellKnownSymbol$l('toStringTag'); - var Object$1 = global$Y.Object; + var Object$1 = global$_.Object; // ES3 wrong here var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) == 'Arguments'; @@ -1651,10 +1709,10 @@ redefine$c(Object.prototype, 'toString', toString$l, { unsafe: true }); } - var global$X = global$1m; + var global$Z = global$1o; var classof$b = classof$d; - var String$3 = global$X.String; + var String$3 = global$Z.String; var toString$k = function (argument) { if (classof$b(argument) === 'Symbol') throw TypeError('Cannot convert a Symbol value to a string'); @@ -1772,7 +1830,7 @@ var domTokenListPrototype = DOMTokenListPrototype$2 === Object.prototype ? undefined : DOMTokenListPrototype$2; - var global$W = global$1m; + var global$Y = global$1o; var DOMIterables$1 = domIterables; var DOMTokenListPrototype$1 = domTokenListPrototype; var ArrayIteratorMethods = es_array_iterator; @@ -1806,18 +1864,19 @@ }; for (var COLLECTION_NAME$1 in DOMIterables$1) { - handlePrototype$1(global$W[COLLECTION_NAME$1] && global$W[COLLECTION_NAME$1].prototype, COLLECTION_NAME$1); + handlePrototype$1(global$Y[COLLECTION_NAME$1] && global$Y[COLLECTION_NAME$1].prototype, COLLECTION_NAME$1); } handlePrototype$1(DOMTokenListPrototype$1, 'DOMTokenList'); + var NATIVE_BIND$2 = functionBindNative; + var FunctionPrototype$1 = Function.prototype; var apply$9 = FunctionPrototype$1.apply; - var bind$g = FunctionPrototype$1.bind; var call$k = FunctionPrototype$1.call; // eslint-disable-next-line es/no-reflect -- safe - var functionApply = typeof Reflect == 'object' && Reflect.apply || (bind$g ? call$k.bind(apply$9) : function () { + var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND$2 ? call$k.bind(apply$9) : function () { return call$k.apply(apply$9, arguments); }); @@ -1832,16 +1891,40 @@ var objectGetOwnPropertyNamesExternal = {}; - var uncurryThis$K = functionUncurryThis; + var toPropertyKey$2 = toPropertyKey$5; + var definePropertyModule$3 = objectDefineProperty; + var createPropertyDescriptor$3 = createPropertyDescriptor$7; + + var createProperty$5 = function (object, key, value) { + var propertyKey = toPropertyKey$2(key); + if (propertyKey in object) definePropertyModule$3.f(object, propertyKey, createPropertyDescriptor$3(0, value)); + else object[propertyKey] = value; + }; + + var global$X = global$1o; + var toAbsoluteIndex$7 = toAbsoluteIndex$9; + var lengthOfArrayLike$g = lengthOfArrayLike$i; + var createProperty$4 = createProperty$5; - var arraySlice$c = uncurryThis$K([].slice); + var Array$7 = global$X.Array; + var max$4 = Math.max; + + var arraySliceSimple = function (O, start, end) { + var length = lengthOfArrayLike$g(O); + var k = toAbsoluteIndex$7(start, length); + var fin = toAbsoluteIndex$7(end === undefined ? length : end, length); + var result = Array$7(max$4(fin - k, 0)); + for (var n = 0; k < fin; k++, n++) createProperty$4(result, n, O[k]); + result.length = n; + return result; + }; /* eslint-disable es/no-object-getownpropertynames -- safe */ var classof$9 = classofRaw$1; - var toIndexedObject$6 = toIndexedObject$c; + var toIndexedObject$7 = toIndexedObject$d; var $getOwnPropertyNames$1 = objectGetOwnPropertyNames.f; - var arraySlice$b = arraySlice$c; + var arraySlice$c = arraySliceSimple; var windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames ? Object.getOwnPropertyNames(window) : []; @@ -1850,7 +1933,7 @@ try { return $getOwnPropertyNames$1(it); } catch (error) { - return arraySlice$b(windowNames); + return arraySlice$c(windowNames); } }; @@ -1858,24 +1941,29 @@ objectGetOwnPropertyNamesExternal.f = function getOwnPropertyNames(it) { return windowNames && classof$9(it) == 'Window' ? getWindowNames(it) - : $getOwnPropertyNames$1(toIndexedObject$6(it)); + : $getOwnPropertyNames$1(toIndexedObject$7(it)); }; + var uncurryThis$K = functionUncurryThis; + + var arraySlice$b = uncurryThis$K([].slice); + var uncurryThis$J = functionUncurryThis; var aCallable$8 = aCallable$a; + var NATIVE_BIND$1 = functionBindNative; var bind$f = uncurryThis$J(uncurryThis$J.bind); // optional / simple context binding var functionBindContext = function (fn, that) { aCallable$8(fn); - return that === undefined ? fn : bind$f ? bind$f(fn, that) : function (/* ...args */) { + return that === undefined ? fn : NATIVE_BIND$1 ? bind$f(fn, that) : function (/* ...args */) { return fn.apply(that, arguments); }; }; var uncurryThis$I = functionUncurryThis; - var fails$K = fails$S; + var fails$L = fails$V; var isCallable$c = isCallable$r; var classof$8 = classof$d; var getBuiltIn$6 = getBuiltIn$b; @@ -1888,7 +1976,7 @@ var exec$6 = uncurryThis$I(constructorRegExp.exec); var INCORRECT_TO_STRING = !constructorRegExp.exec(noop$2); - var isConstructorModern = function (argument) { + var isConstructorModern = function isConstructor(argument) { if (!isCallable$c(argument)) return false; try { construct$1(noop$2, empty$1, argument); @@ -1898,19 +1986,28 @@ } }; - var isConstructorLegacy = function (argument) { + var isConstructorLegacy = function isConstructor(argument) { if (!isCallable$c(argument)) return false; switch (classof$8(argument)) { case 'AsyncFunction': case 'GeneratorFunction': case 'AsyncGeneratorFunction': return false; + } + try { // we can't check .prototype since constructors produced by .bind haven't it - } return INCORRECT_TO_STRING || !!exec$6(constructorRegExp, inspectSource$1(argument)); + // `Function#toString` throws on some built-it function in some legacy engines + // (for example, `DOMQuad` and similar in FF41-) + return INCORRECT_TO_STRING || !!exec$6(constructorRegExp, inspectSource$1(argument)); + } catch (error) { + return true; + } }; + isConstructorLegacy.sham = true; + // `IsConstructor` abstract operation // https://tc39.es/ecma262/#sec-isconstructor - var isConstructor$4 = !construct$1 || fails$K(function () { + var isConstructor$4 = !construct$1 || fails$L(function () { var called; return isConstructorModern(isConstructorModern.call) || !isConstructorModern(Object) @@ -1918,14 +2015,14 @@ || called; }) ? isConstructorLegacy : isConstructorModern; - var global$V = global$1m; + var global$W = global$1o; var isArray$7 = isArray$8; var isConstructor$3 = isConstructor$4; var isObject$m = isObject$s; var wellKnownSymbol$j = wellKnownSymbol$t; var SPECIES$6 = wellKnownSymbol$j('species'); - var Array$6 = global$V.Array; + var Array$6 = global$W.Array; // a part of `ArraySpeciesCreate` abstract operation // https://tc39.es/ecma262/#sec-arrayspeciescreate @@ -1953,8 +2050,8 @@ var bind$e = functionBindContext; var uncurryThis$H = functionUncurryThis; var IndexedObject$3 = indexedObject; - var toObject$g = toObject$j; - var lengthOfArrayLike$e = lengthOfArrayLike$g; + var toObject$f = toObject$i; + var lengthOfArrayLike$f = lengthOfArrayLike$i; var arraySpeciesCreate$3 = arraySpeciesCreate$4; var push$9 = uncurryThis$H([].push); @@ -1969,10 +2066,10 @@ var IS_FILTER_REJECT = TYPE == 7; var NO_HOLES = TYPE == 5 || IS_FIND_INDEX; return function ($this, callbackfn, that, specificCreate) { - var O = toObject$g($this); + var O = toObject$f($this); var self = IndexedObject$3(O); var boundFunction = bind$e(callbackfn, that); - var length = lengthOfArrayLike$e(self); + var length = lengthOfArrayLike$f(self); var index = 0; var create = specificCreate || arraySpeciesCreate$3; var target = IS_MAP ? create($this, length) : IS_FILTER || IS_FILTER_REJECT ? create($this, 0) : undefined; @@ -2025,14 +2122,14 @@ }; var $$1b = _export; - var global$U = global$1m; + var global$V = global$1o; var getBuiltIn$5 = getBuiltIn$b; var apply$8 = functionApply; var call$j = functionCall; var uncurryThis$G = functionUncurryThis; var DESCRIPTORS$h = descriptors; var NATIVE_SYMBOL$1 = nativeSymbol; - var fails$J = fails$S; + var fails$K = fails$V; var hasOwn$b = hasOwnProperty_1; var isArray$6 = isArray$8; var isCallable$b = isCallable$r; @@ -2040,20 +2137,21 @@ var isPrototypeOf$8 = objectIsPrototypeOf; var isSymbol$3 = isSymbol$6; var anObject$h = anObject$n; - var toObject$f = toObject$j; - var toIndexedObject$5 = toIndexedObject$c; - var toPropertyKey$2 = toPropertyKey$5; + var toObject$e = toObject$i; + var toIndexedObject$6 = toIndexedObject$d; + var toPropertyKey$1 = toPropertyKey$5; var $toString$3 = toString$k; - var createPropertyDescriptor$3 = createPropertyDescriptor$7; + var createPropertyDescriptor$2 = createPropertyDescriptor$7; var nativeObjectCreate = objectCreate; var objectKeys$2 = objectKeys$4; var getOwnPropertyNamesModule$1 = objectGetOwnPropertyNames; var getOwnPropertyNamesExternal = objectGetOwnPropertyNamesExternal; var getOwnPropertySymbolsModule$1 = objectGetOwnPropertySymbols; var getOwnPropertyDescriptorModule$2 = objectGetOwnPropertyDescriptor; - var definePropertyModule$3 = objectDefineProperty; + var definePropertyModule$2 = objectDefineProperty; + var definePropertiesModule = objectDefineProperties; var propertyIsEnumerableModule$1 = objectPropertyIsEnumerable; - var arraySlice$a = arraySlice$c; + var arraySlice$a = arraySlice$b; var redefine$b = redefine$h.exports; var shared$1 = shared$5.exports; var sharedKey = sharedKey$4; @@ -2075,13 +2173,13 @@ var getInternalState$4 = InternalStateModule$6.getterFor(SYMBOL); var ObjectPrototype$3 = Object[PROTOTYPE$1]; - var $Symbol = global$U.Symbol; + var $Symbol = global$V.Symbol; var SymbolPrototype$1 = $Symbol && $Symbol[PROTOTYPE$1]; - var TypeError$g = global$U.TypeError; - var QObject = global$U.QObject; + var TypeError$h = global$V.TypeError; + var QObject = global$V.QObject; var $stringify = getBuiltIn$5('JSON', 'stringify'); var nativeGetOwnPropertyDescriptor$2 = getOwnPropertyDescriptorModule$2.f; - var nativeDefineProperty$1 = definePropertyModule$3.f; + var nativeDefineProperty$1 = definePropertyModule$2.f; var nativeGetOwnPropertyNames = getOwnPropertyNamesExternal.f; var nativePropertyIsEnumerable = propertyIsEnumerableModule$1.f; var push$8 = uncurryThis$G([].push); @@ -2096,7 +2194,7 @@ var USE_SETTER = !QObject || !QObject[PROTOTYPE$1] || !QObject[PROTOTYPE$1].findChild; // fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687 - var setSymbolDescriptor = DESCRIPTORS$h && fails$J(function () { + var setSymbolDescriptor = DESCRIPTORS$h && fails$K(function () { return nativeObjectCreate(nativeDefineProperty$1({}, 'a', { get: function () { return nativeDefineProperty$1(this, 'a', { value: 7 }).a; } })).a != 7; @@ -2123,22 +2221,22 @@ var $defineProperty = function defineProperty(O, P, Attributes) { if (O === ObjectPrototype$3) $defineProperty(ObjectPrototypeSymbols, P, Attributes); anObject$h(O); - var key = toPropertyKey$2(P); + var key = toPropertyKey$1(P); anObject$h(Attributes); if (hasOwn$b(AllSymbols, key)) { if (!Attributes.enumerable) { - if (!hasOwn$b(O, HIDDEN)) nativeDefineProperty$1(O, HIDDEN, createPropertyDescriptor$3(1, {})); + if (!hasOwn$b(O, HIDDEN)) nativeDefineProperty$1(O, HIDDEN, createPropertyDescriptor$2(1, {})); O[HIDDEN][key] = true; } else { if (hasOwn$b(O, HIDDEN) && O[HIDDEN][key]) O[HIDDEN][key] = false; - Attributes = nativeObjectCreate(Attributes, { enumerable: createPropertyDescriptor$3(0, false) }); + Attributes = nativeObjectCreate(Attributes, { enumerable: createPropertyDescriptor$2(0, false) }); } return setSymbolDescriptor(O, key, Attributes); } return nativeDefineProperty$1(O, key, Attributes); }; var $defineProperties = function defineProperties(O, Properties) { anObject$h(O); - var properties = toIndexedObject$5(Properties); + var properties = toIndexedObject$6(Properties); var keys = objectKeys$2(properties).concat($getOwnPropertySymbols(properties)); $forEach$2(keys, function (key) { if (!DESCRIPTORS$h || call$j($propertyIsEnumerable$1, properties, key)) $defineProperty(O, key, properties[key]); @@ -2151,7 +2249,7 @@ }; var $propertyIsEnumerable$1 = function propertyIsEnumerable(V) { - var P = toPropertyKey$2(V); + var P = toPropertyKey$1(V); var enumerable = call$j(nativePropertyIsEnumerable, this, P); if (this === ObjectPrototype$3 && hasOwn$b(AllSymbols, P) && !hasOwn$b(ObjectPrototypeSymbols, P)) return false; return enumerable || !hasOwn$b(this, P) || !hasOwn$b(AllSymbols, P) || hasOwn$b(this, HIDDEN) && this[HIDDEN][P] @@ -2159,8 +2257,8 @@ }; var $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(O, P) { - var it = toIndexedObject$5(O); - var key = toPropertyKey$2(P); + var it = toIndexedObject$6(O); + var key = toPropertyKey$1(P); if (it === ObjectPrototype$3 && hasOwn$b(AllSymbols, key) && !hasOwn$b(ObjectPrototypeSymbols, key)) return; var descriptor = nativeGetOwnPropertyDescriptor$2(it, key); if (descriptor && hasOwn$b(AllSymbols, key) && !(hasOwn$b(it, HIDDEN) && it[HIDDEN][key])) { @@ -2170,7 +2268,7 @@ }; var $getOwnPropertyNames = function getOwnPropertyNames(O) { - var names = nativeGetOwnPropertyNames(toIndexedObject$5(O)); + var names = nativeGetOwnPropertyNames(toIndexedObject$6(O)); var result = []; $forEach$2(names, function (key) { if (!hasOwn$b(AllSymbols, key) && !hasOwn$b(hiddenKeys$1, key)) push$8(result, key); @@ -2180,7 +2278,7 @@ var $getOwnPropertySymbols = function getOwnPropertySymbols(O) { var IS_OBJECT_PROTOTYPE = O === ObjectPrototype$3; - var names = nativeGetOwnPropertyNames(IS_OBJECT_PROTOTYPE ? ObjectPrototypeSymbols : toIndexedObject$5(O)); + var names = nativeGetOwnPropertyNames(IS_OBJECT_PROTOTYPE ? ObjectPrototypeSymbols : toIndexedObject$6(O)); var result = []; $forEach$2(names, function (key) { if (hasOwn$b(AllSymbols, key) && (!IS_OBJECT_PROTOTYPE || hasOwn$b(ObjectPrototype$3, key))) { @@ -2194,13 +2292,13 @@ // https://tc39.es/ecma262/#sec-symbol-constructor if (!NATIVE_SYMBOL$1) { $Symbol = function Symbol() { - if (isPrototypeOf$8(SymbolPrototype$1, this)) throw TypeError$g('Symbol is not a constructor'); + if (isPrototypeOf$8(SymbolPrototype$1, this)) throw TypeError$h('Symbol is not a constructor'); var description = !arguments.length || arguments[0] === undefined ? undefined : $toString$3(arguments[0]); var tag = uid$2(description); var setter = function (value) { if (this === ObjectPrototype$3) call$j(setter, ObjectPrototypeSymbols, value); if (hasOwn$b(this, HIDDEN) && hasOwn$b(this[HIDDEN], tag)) this[HIDDEN][tag] = false; - setSymbolDescriptor(this, tag, createPropertyDescriptor$3(1, value)); + setSymbolDescriptor(this, tag, createPropertyDescriptor$2(1, value)); }; if (DESCRIPTORS$h && USE_SETTER) setSymbolDescriptor(ObjectPrototype$3, tag, { configurable: true, set: setter }); return wrap$2(tag, description); @@ -2217,7 +2315,8 @@ }); propertyIsEnumerableModule$1.f = $propertyIsEnumerable$1; - definePropertyModule$3.f = $defineProperty; + definePropertyModule$2.f = $defineProperty; + definePropertiesModule.f = $defineProperties; getOwnPropertyDescriptorModule$2.f = $getOwnPropertyDescriptor; getOwnPropertyNamesModule$1.f = getOwnPropertyNamesExternal.f = $getOwnPropertyNames; getOwnPropertySymbolsModule$1.f = $getOwnPropertySymbols; @@ -2262,7 +2361,7 @@ // `Symbol.keyFor` method // https://tc39.es/ecma262/#sec-symbol.keyfor keyFor: function keyFor(sym) { - if (!isSymbol$3(sym)) throw TypeError$g(sym + ' is not a symbol'); + if (!isSymbol$3(sym)) throw TypeError$h(sym + ' is not a symbol'); if (hasOwn$b(SymbolToStringRegistry, sym)) return SymbolToStringRegistry[sym]; }, useSetter: function () { USE_SETTER = true; }, @@ -2295,16 +2394,16 @@ // Chrome 38 and 39 `Object.getOwnPropertySymbols` fails on primitives // https://bugs.chromium.org/p/v8/issues/detail?id=3443 - $$1b({ target: 'Object', stat: true, forced: fails$J(function () { getOwnPropertySymbolsModule$1.f(1); }) }, { + $$1b({ target: 'Object', stat: true, forced: fails$K(function () { getOwnPropertySymbolsModule$1.f(1); }) }, { getOwnPropertySymbols: function getOwnPropertySymbols(it) { - return getOwnPropertySymbolsModule$1.f(toObject$f(it)); + return getOwnPropertySymbolsModule$1.f(toObject$e(it)); } }); // `JSON.stringify` method behavior with symbols // https://tc39.es/ecma262/#sec-json.stringify if ($stringify) { - var FORCED_JSON_STRINGIFY = !NATIVE_SYMBOL$1 || fails$J(function () { + var FORCED_JSON_STRINGIFY = !NATIVE_SYMBOL$1 || fails$K(function () { var symbol = $Symbol(); // MS Edge converts symbol values to JSON as {} return $stringify([symbol]) != '[null]' @@ -2348,16 +2447,16 @@ var $$1a = _export; var DESCRIPTORS$g = descriptors; - var global$T = global$1m; + var global$U = global$1o; var uncurryThis$F = functionUncurryThis; var hasOwn$a = hasOwnProperty_1; var isCallable$a = isCallable$r; var isPrototypeOf$7 = objectIsPrototypeOf; var toString$h = toString$k; - var defineProperty$8 = objectDefineProperty.f; + var defineProperty$9 = objectDefineProperty.f; var copyConstructorProperties = copyConstructorProperties$2; - var NativeSymbol = global$T.Symbol; + var NativeSymbol = global$U.Symbol; var SymbolPrototype = NativeSymbol && NativeSymbol.prototype; if (DESCRIPTORS$g && isCallable$a(NativeSymbol) && (!('description' in SymbolPrototype) || @@ -2387,7 +2486,7 @@ var replace$8 = uncurryThis$F(''.replace); var stringSlice$a = uncurryThis$F(''.slice); - defineProperty$8(SymbolPrototype, 'description', { + defineProperty$9(SymbolPrototype, 'description', { configurable: true, get: function description() { var symbol = symbolValueOf(this); @@ -2413,21 +2512,21 @@ return target; }; - var global$S = global$1m; + var global$T = global$1o; var isPrototypeOf$6 = objectIsPrototypeOf; - var TypeError$f = global$S.TypeError; + var TypeError$g = global$T.TypeError; var anInstance$7 = function (it, Prototype) { if (isPrototypeOf$6(Prototype, it)) return it; - throw TypeError$f('Incorrect invocation'); + throw TypeError$g('Incorrect invocation'); }; - var global$R = global$1m; + var global$S = global$1o; var toIntegerOrInfinity$7 = toIntegerOrInfinity$b; var toLength$a = toLength$c; - var RangeError$b = global$R.RangeError; + var RangeError$b = global$S.RangeError; // `ToIndex` abstract operation // https://tc39.es/ecma262/#sec-toindex @@ -2440,9 +2539,9 @@ }; // IEEE754 conversions based on https://github.com/feross/ieee754 - var global$Q = global$1m; + var global$R = global$1o; - var Array$5 = global$Q.Array; + var Array$5 = global$R.Array; var abs$4 = Math.abs; var pow$2 = Math.pow; var floor$7 = Math.floor; @@ -2466,7 +2565,8 @@ exponent = eMax; } else { exponent = floor$7(log$2(number) / LN2); - if (number * (c = pow$2(2, -exponent)) < 1) { + c = pow$2(2, -exponent); + if (number * c < 1) { exponent--; c *= 2; } @@ -2490,10 +2590,18 @@ exponent = 0; } } - for (; mantissaLength >= 8; buffer[index++] = mantissa & 255, mantissa /= 256, mantissaLength -= 8); + while (mantissaLength >= 8) { + buffer[index++] = mantissa & 255; + mantissa /= 256; + mantissaLength -= 8; + } exponent = exponent << mantissaLength | mantissa; exponentLength += mantissaLength; - for (; exponentLength > 0; buffer[index++] = exponent & 255, exponent /= 256, exponentLength -= 8); + while (exponentLength > 0) { + buffer[index++] = exponent & 255; + exponent /= 256; + exponentLength -= 8; + } buffer[--index] |= sign * 128; return buffer; }; @@ -2509,11 +2617,17 @@ var exponent = sign & 127; var mantissa; sign >>= 7; - for (; nBits > 0; exponent = exponent * 256 + buffer[index], index--, nBits -= 8); + while (nBits > 0) { + exponent = exponent * 256 + buffer[index--]; + nBits -= 8; + } mantissa = exponent & (1 << -nBits) - 1; exponent >>= -nBits; nBits += mantissaLength; - for (; nBits > 0; mantissa = mantissa * 256 + buffer[index], index--, nBits -= 8); + while (nBits > 0) { + mantissa = mantissa * 256 + buffer[index--]; + nBits -= 8; + } if (exponent === 0) { exponent = 1 - eBias; } else if (exponent === eMax) { @@ -2529,15 +2643,15 @@ unpack: unpack }; - var toObject$e = toObject$j; - var toAbsoluteIndex$6 = toAbsoluteIndex$8; - var lengthOfArrayLike$d = lengthOfArrayLike$g; + var toObject$d = toObject$i; + var toAbsoluteIndex$6 = toAbsoluteIndex$9; + var lengthOfArrayLike$e = lengthOfArrayLike$i; // `Array.prototype.fill` method implementation // https://tc39.es/ecma262/#sec-array.prototype.fill var arrayFill$1 = function fill(value /* , start = 0, end = @length */) { - var O = toObject$e(this); - var length = lengthOfArrayLike$d(O); + var O = toObject$d(this); + var length = lengthOfArrayLike$e(O); var argumentsLength = arguments.length; var index = toAbsoluteIndex$6(argumentsLength > 1 ? arguments[1] : undefined, length); var end = argumentsLength > 2 ? arguments[2] : undefined; @@ -2546,14 +2660,14 @@ return O; }; - var global$P = global$1m; + var global$Q = global$1o; var uncurryThis$E = functionUncurryThis; var DESCRIPTORS$f = descriptors; var NATIVE_ARRAY_BUFFER$2 = arrayBufferNative; var FunctionName = functionName; var createNonEnumerableProperty$5 = createNonEnumerableProperty$b; var redefineAll$3 = redefineAll$4; - var fails$I = fails$S; + var fails$J = fails$V; var anInstance$6 = anInstance$7; var toIntegerOrInfinity$6 = toIntegerOrInfinity$b; var toLength$9 = toLength$c; @@ -2562,13 +2676,13 @@ var getPrototypeOf$2 = objectGetPrototypeOf; var setPrototypeOf$5 = objectSetPrototypeOf; var getOwnPropertyNames$4 = objectGetOwnPropertyNames.f; - var defineProperty$7 = objectDefineProperty.f; + var defineProperty$8 = objectDefineProperty.f; var arrayFill = arrayFill$1; - var arraySlice$9 = arraySlice$c; + var arraySlice$9 = arraySliceSimple; var setToStringTag$6 = setToStringTag$a; var InternalStateModule$5 = internalState; - var PROPER_FUNCTION_NAME$3 = FunctionName.PROPER; + var PROPER_FUNCTION_NAME$2 = FunctionName.PROPER; var CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE; var getInternalState$3 = InternalStateModule$5.get; var setInternalState$5 = InternalStateModule$5.set; @@ -2577,14 +2691,14 @@ var PROTOTYPE = 'prototype'; var WRONG_LENGTH$1 = 'Wrong length'; var WRONG_INDEX = 'Wrong index'; - var NativeArrayBuffer$1 = global$P[ARRAY_BUFFER$1]; + var NativeArrayBuffer$1 = global$Q[ARRAY_BUFFER$1]; var $ArrayBuffer = NativeArrayBuffer$1; var ArrayBufferPrototype$1 = $ArrayBuffer && $ArrayBuffer[PROTOTYPE]; - var $DataView = global$P[DATA_VIEW]; + var $DataView = global$Q[DATA_VIEW]; var DataViewPrototype$1 = $DataView && $DataView[PROTOTYPE]; var ObjectPrototype$2 = Object.prototype; - var Array$4 = global$P.Array; - var RangeError$a = global$P.RangeError; + var Array$4 = global$Q.Array; + var RangeError$a = global$Q.RangeError; var fill$1 = uncurryThis$E(arrayFill); var reverse = uncurryThis$E([].reverse); @@ -2616,7 +2730,7 @@ }; var addGetter$1 = function (Constructor, key) { - defineProperty$7(Constructor[PROTOTYPE], key, { get: function () { return getInternalState$3(this)[key]; } }); + defineProperty$8(Constructor[PROTOTYPE], key, { get: function () { return getInternalState$3(this)[key]; } }); }; var get$4 = function (view, count, index, isLittleEndian) { @@ -2734,13 +2848,13 @@ } }); } else { - var INCORRECT_ARRAY_BUFFER_NAME = PROPER_FUNCTION_NAME$3 && NativeArrayBuffer$1.name !== ARRAY_BUFFER$1; + var INCORRECT_ARRAY_BUFFER_NAME = PROPER_FUNCTION_NAME$2 && NativeArrayBuffer$1.name !== ARRAY_BUFFER$1; /* eslint-disable no-new -- required for testing */ - if (!fails$I(function () { + if (!fails$J(function () { NativeArrayBuffer$1(1); - }) || !fails$I(function () { + }) || !fails$J(function () { new NativeArrayBuffer$1(-1); - }) || fails$I(function () { + }) || fails$J(function () { new NativeArrayBuffer$1(); new NativeArrayBuffer$1(1.5); new NativeArrayBuffer$1(NaN); @@ -2793,16 +2907,16 @@ DataView: $DataView }; - var global$O = global$1m; + var global$P = global$1o; var isConstructor$2 = isConstructor$4; var tryToString$3 = tryToString$5; - var TypeError$e = global$O.TypeError; + var TypeError$f = global$P.TypeError; // `Assert: IsConstructor(argument) is true` var aConstructor$3 = function (argument) { if (isConstructor$2(argument)) return argument; - throw TypeError$e(tryToString$3(argument) + ' is not a constructor'); + throw TypeError$f(tryToString$3(argument) + ' is not a constructor'); }; var anObject$g = anObject$n; @@ -2821,10 +2935,10 @@ var $$19 = _export; var uncurryThis$D = functionUncurryThis; - var fails$H = fails$S; + var fails$I = fails$V; var ArrayBufferModule$2 = arrayBuffer; var anObject$f = anObject$n; - var toAbsoluteIndex$5 = toAbsoluteIndex$8; + var toAbsoluteIndex$5 = toAbsoluteIndex$9; var toLength$8 = toLength$c; var speciesConstructor$4 = speciesConstructor$5; @@ -2835,7 +2949,7 @@ var getUint8 = uncurryThis$D(DataViewPrototype.getUint8); var setUint8 = uncurryThis$D(DataViewPrototype.setUint8); - var INCORRECT_SLICE = fails$H(function () { + var INCORRECT_SLICE = fails$I(function () { return !new ArrayBuffer$4(2).slice(1, undefined).byteLength; }); @@ -2871,7 +2985,7 @@ var NATIVE_ARRAY_BUFFER = arrayBufferNative; var DESCRIPTORS$e = descriptors; - var global$N = global$1m; + var global$O = global$1o; var isCallable$9 = isCallable$r; var isObject$k = isObject$s; var hasOwn$9 = hasOwnProperty_1; @@ -2879,28 +2993,28 @@ var tryToString$2 = tryToString$5; var createNonEnumerableProperty$4 = createNonEnumerableProperty$b; var redefine$9 = redefine$h.exports; - var defineProperty$6 = objectDefineProperty.f; + var defineProperty$7 = objectDefineProperty.f; var isPrototypeOf$5 = objectIsPrototypeOf; var getPrototypeOf$1 = objectGetPrototypeOf; var setPrototypeOf$4 = objectSetPrototypeOf; var wellKnownSymbol$g = wellKnownSymbol$t; var uid$1 = uid$5; - var Int8Array$3 = global$N.Int8Array; - var Int8ArrayPrototype = Int8Array$3 && Int8Array$3.prototype; - var Uint8ClampedArray = global$N.Uint8ClampedArray; - var Uint8ClampedArrayPrototype = Uint8ClampedArray && Uint8ClampedArray.prototype; - var TypedArray$1 = Int8Array$3 && getPrototypeOf$1(Int8Array$3); - var TypedArrayPrototype$1 = Int8ArrayPrototype && getPrototypeOf$1(Int8ArrayPrototype); + var Int8Array$4 = global$O.Int8Array; + var Int8ArrayPrototype$1 = Int8Array$4 && Int8Array$4.prototype; + var Uint8ClampedArray$1 = global$O.Uint8ClampedArray; + var Uint8ClampedArrayPrototype = Uint8ClampedArray$1 && Uint8ClampedArray$1.prototype; + var TypedArray$1 = Int8Array$4 && getPrototypeOf$1(Int8Array$4); + var TypedArrayPrototype$2 = Int8ArrayPrototype$1 && getPrototypeOf$1(Int8ArrayPrototype$1); var ObjectPrototype$1 = Object.prototype; - var TypeError$d = global$N.TypeError; + var TypeError$e = global$O.TypeError; var TO_STRING_TAG = wellKnownSymbol$g('toStringTag'); var TYPED_ARRAY_TAG$1 = uid$1('TYPED_ARRAY_TAG'); var TYPED_ARRAY_CONSTRUCTOR$2 = uid$1('TYPED_ARRAY_CONSTRUCTOR'); // Fixing native typed arrays in Opera Presto crashes the browser, see #595 - var NATIVE_ARRAY_BUFFER_VIEWS$3 = NATIVE_ARRAY_BUFFER && !!setPrototypeOf$4 && classof$7(global$N.opera) !== 'Opera'; - var TYPED_ARRAY_TAG_REQIRED = false; + var NATIVE_ARRAY_BUFFER_VIEWS$3 = NATIVE_ARRAY_BUFFER && !!setPrototypeOf$4 && classof$7(global$O.opera) !== 'Opera'; + var TYPED_ARRAY_TAG_REQUIRED = false; var NAME$1, Constructor, Prototype; var TypedArrayConstructorsList = { @@ -2937,25 +3051,30 @@ var aTypedArray$m = function (it) { if (isTypedArray$1(it)) return it; - throw TypeError$d('Target is not a typed array'); + throw TypeError$e('Target is not a typed array'); }; var aTypedArrayConstructor$3 = function (C) { if (isCallable$9(C) && (!setPrototypeOf$4 || isPrototypeOf$5(TypedArray$1, C))) return C; - throw TypeError$d(tryToString$2(C) + ' is not a typed array constructor'); + throw TypeError$e(tryToString$2(C) + ' is not a typed array constructor'); }; - var exportTypedArrayMethod$n = function (KEY, property, forced) { + var exportTypedArrayMethod$n = function (KEY, property, forced, options) { if (!DESCRIPTORS$e) return; if (forced) for (var ARRAY in TypedArrayConstructorsList) { - var TypedArrayConstructor = global$N[ARRAY]; + var TypedArrayConstructor = global$O[ARRAY]; if (TypedArrayConstructor && hasOwn$9(TypedArrayConstructor.prototype, KEY)) try { delete TypedArrayConstructor.prototype[KEY]; - } catch (error) { /* empty */ } + } catch (error) { + // old WebKit bug - some methods are non-configurable + try { + TypedArrayConstructor.prototype[KEY] = property; + } catch (error2) { /* empty */ } + } } - if (!TypedArrayPrototype$1[KEY] || forced) { - redefine$9(TypedArrayPrototype$1, KEY, forced ? property - : NATIVE_ARRAY_BUFFER_VIEWS$3 && Int8ArrayPrototype[KEY] || property); + if (!TypedArrayPrototype$2[KEY] || forced) { + redefine$9(TypedArrayPrototype$2, KEY, forced ? property + : NATIVE_ARRAY_BUFFER_VIEWS$3 && Int8ArrayPrototype$1[KEY] || property, options); } }; @@ -2964,7 +3083,7 @@ if (!DESCRIPTORS$e) return; if (setPrototypeOf$4) { if (forced) for (ARRAY in TypedArrayConstructorsList) { - TypedArrayConstructor = global$N[ARRAY]; + TypedArrayConstructor = global$O[ARRAY]; if (TypedArrayConstructor && hasOwn$9(TypedArrayConstructor, KEY)) try { delete TypedArrayConstructor[KEY]; } catch (error) { /* empty */ } @@ -2977,7 +3096,7 @@ } else return; } for (ARRAY in TypedArrayConstructorsList) { - TypedArrayConstructor = global$N[ARRAY]; + TypedArrayConstructor = global$O[ARRAY]; if (TypedArrayConstructor && (!TypedArrayConstructor[KEY] || forced)) { redefine$9(TypedArrayConstructor, KEY, property); } @@ -2985,14 +3104,14 @@ }; for (NAME$1 in TypedArrayConstructorsList) { - Constructor = global$N[NAME$1]; + Constructor = global$O[NAME$1]; Prototype = Constructor && Constructor.prototype; if (Prototype) createNonEnumerableProperty$4(Prototype, TYPED_ARRAY_CONSTRUCTOR$2, Constructor); else NATIVE_ARRAY_BUFFER_VIEWS$3 = false; } for (NAME$1 in BigIntArrayConstructorsList) { - Constructor = global$N[NAME$1]; + Constructor = global$O[NAME$1]; Prototype = Constructor && Constructor.prototype; if (Prototype) createNonEnumerableProperty$4(Prototype, TYPED_ARRAY_CONSTRUCTOR$2, Constructor); } @@ -3001,39 +3120,39 @@ if (!NATIVE_ARRAY_BUFFER_VIEWS$3 || !isCallable$9(TypedArray$1) || TypedArray$1 === Function.prototype) { // eslint-disable-next-line no-shadow -- safe TypedArray$1 = function TypedArray() { - throw TypeError$d('Incorrect invocation'); + throw TypeError$e('Incorrect invocation'); }; if (NATIVE_ARRAY_BUFFER_VIEWS$3) for (NAME$1 in TypedArrayConstructorsList) { - if (global$N[NAME$1]) setPrototypeOf$4(global$N[NAME$1], TypedArray$1); + if (global$O[NAME$1]) setPrototypeOf$4(global$O[NAME$1], TypedArray$1); } } - if (!NATIVE_ARRAY_BUFFER_VIEWS$3 || !TypedArrayPrototype$1 || TypedArrayPrototype$1 === ObjectPrototype$1) { - TypedArrayPrototype$1 = TypedArray$1.prototype; + if (!NATIVE_ARRAY_BUFFER_VIEWS$3 || !TypedArrayPrototype$2 || TypedArrayPrototype$2 === ObjectPrototype$1) { + TypedArrayPrototype$2 = TypedArray$1.prototype; if (NATIVE_ARRAY_BUFFER_VIEWS$3) for (NAME$1 in TypedArrayConstructorsList) { - if (global$N[NAME$1]) setPrototypeOf$4(global$N[NAME$1].prototype, TypedArrayPrototype$1); + if (global$O[NAME$1]) setPrototypeOf$4(global$O[NAME$1].prototype, TypedArrayPrototype$2); } } // WebKit bug - one more object in Uint8ClampedArray prototype chain - if (NATIVE_ARRAY_BUFFER_VIEWS$3 && getPrototypeOf$1(Uint8ClampedArrayPrototype) !== TypedArrayPrototype$1) { - setPrototypeOf$4(Uint8ClampedArrayPrototype, TypedArrayPrototype$1); + if (NATIVE_ARRAY_BUFFER_VIEWS$3 && getPrototypeOf$1(Uint8ClampedArrayPrototype) !== TypedArrayPrototype$2) { + setPrototypeOf$4(Uint8ClampedArrayPrototype, TypedArrayPrototype$2); } - if (DESCRIPTORS$e && !hasOwn$9(TypedArrayPrototype$1, TO_STRING_TAG)) { - TYPED_ARRAY_TAG_REQIRED = true; - defineProperty$6(TypedArrayPrototype$1, TO_STRING_TAG, { get: function () { + if (DESCRIPTORS$e && !hasOwn$9(TypedArrayPrototype$2, TO_STRING_TAG)) { + TYPED_ARRAY_TAG_REQUIRED = true; + defineProperty$7(TypedArrayPrototype$2, TO_STRING_TAG, { get: function () { return isObject$k(this) ? this[TYPED_ARRAY_TAG$1] : undefined; } }); - for (NAME$1 in TypedArrayConstructorsList) if (global$N[NAME$1]) { - createNonEnumerableProperty$4(global$N[NAME$1], TYPED_ARRAY_TAG$1, NAME$1); + for (NAME$1 in TypedArrayConstructorsList) if (global$O[NAME$1]) { + createNonEnumerableProperty$4(global$O[NAME$1], TYPED_ARRAY_TAG$1, NAME$1); } } var arrayBufferViewCore = { NATIVE_ARRAY_BUFFER_VIEWS: NATIVE_ARRAY_BUFFER_VIEWS$3, TYPED_ARRAY_CONSTRUCTOR: TYPED_ARRAY_CONSTRUCTOR$2, - TYPED_ARRAY_TAG: TYPED_ARRAY_TAG_REQIRED && TYPED_ARRAY_TAG$1, + TYPED_ARRAY_TAG: TYPED_ARRAY_TAG_REQUIRED && TYPED_ARRAY_TAG$1, aTypedArray: aTypedArray$m, aTypedArrayConstructor: aTypedArrayConstructor$3, exportTypedArrayMethod: exportTypedArrayMethod$n, @@ -3041,7 +3160,7 @@ isView: isView, isTypedArray: isTypedArray$1, TypedArray: TypedArray$1, - TypedArrayPrototype: TypedArrayPrototype$1 + TypedArrayPrototype: TypedArrayPrototype$2 }; var $$17 = _export; @@ -3056,7 +3175,7 @@ }); var getBuiltIn$4 = getBuiltIn$b; - var definePropertyModule$2 = objectDefineProperty; + var definePropertyModule$1 = objectDefineProperty; var wellKnownSymbol$f = wellKnownSymbol$t; var DESCRIPTORS$d = descriptors; @@ -3064,7 +3183,7 @@ var setSpecies$5 = function (CONSTRUCTOR_NAME) { var Constructor = getBuiltIn$4(CONSTRUCTOR_NAME); - var defineProperty = definePropertyModule$2.f; + var defineProperty = definePropertyModule$1.f; if (DESCRIPTORS$d && Constructor && !Constructor[SPECIES$4]) { defineProperty(Constructor, SPECIES$4, { @@ -3075,13 +3194,13 @@ }; var $$16 = _export; - var global$M = global$1m; + var global$N = global$1o; var arrayBufferModule = arrayBuffer; var setSpecies$4 = setSpecies$5; var ARRAY_BUFFER = 'ArrayBuffer'; var ArrayBuffer$3 = arrayBufferModule[ARRAY_BUFFER]; - var NativeArrayBuffer = global$M[ARRAY_BUFFER]; + var NativeArrayBuffer = global$N[ARRAY_BUFFER]; // `ArrayBuffer` constructor // https://tc39.es/ecma262/#sec-arraybuffer-constructor @@ -3091,11 +3210,11 @@ setSpecies$4(ARRAY_BUFFER); - var fails$G = fails$S; + var fails$H = fails$V; var arrayMethodIsStrict$9 = function (METHOD_NAME, argument) { var method = [][METHOD_NAME]; - return !!method && fails$G(function () { + return !!method && fails$H(function () { // eslint-disable-next-line no-useless-call,no-throw-literal -- required for testing method.call(null, argument || function () { throw 1; }, 1); }); @@ -3140,45 +3259,55 @@ return result; }; - var regexpStickyHelpers = {}; - - var fails$F = fails$S; - var global$L = global$1m; + var fails$G = fails$V; + var global$M = global$1o; // babel-minify and Closure Compiler transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError - var $RegExp$2 = global$L.RegExp; + var $RegExp$2 = global$M.RegExp; - regexpStickyHelpers.UNSUPPORTED_Y = fails$F(function () { + var UNSUPPORTED_Y$3 = fails$G(function () { var re = $RegExp$2('a', 'y'); re.lastIndex = 2; return re.exec('abcd') != null; }); - regexpStickyHelpers.BROKEN_CARET = fails$F(function () { + // UC Browser bug + // https://github.com/zloirock/core-js/issues/1008 + var MISSED_STICKY$1 = UNSUPPORTED_Y$3 || fails$G(function () { + return !$RegExp$2('a', 'y').sticky; + }); + + var BROKEN_CARET = UNSUPPORTED_Y$3 || fails$G(function () { // https://bugzilla.mozilla.org/show_bug.cgi?id=773687 var re = $RegExp$2('^r', 'gy'); re.lastIndex = 2; return re.exec('str') != null; }); - var fails$E = fails$S; - var global$K = global$1m; + var regexpStickyHelpers = { + BROKEN_CARET: BROKEN_CARET, + MISSED_STICKY: MISSED_STICKY$1, + UNSUPPORTED_Y: UNSUPPORTED_Y$3 + }; + + var fails$F = fails$V; + var global$L = global$1o; // babel-minify and Closure Compiler transpiles RegExp('.', 's') -> /./s and it causes SyntaxError - var $RegExp$1 = global$K.RegExp; + var $RegExp$1 = global$L.RegExp; - var regexpUnsupportedDotAll = fails$E(function () { + var regexpUnsupportedDotAll = fails$F(function () { var re = $RegExp$1('.', 's'); return !(re.dotAll && re.exec('\n') && re.flags === 's'); }); - var fails$D = fails$S; - var global$J = global$1m; + var fails$E = fails$V; + var global$K = global$1o; // babel-minify and Closure Compiler transpiles RegExp('(?b)', 'g') -> /(?b)/g and it causes SyntaxError - var $RegExp = global$J.RegExp; + var $RegExp = global$K.RegExp; - var regexpUnsupportedNcg = fails$D(function () { + var regexpUnsupportedNcg = fails$E(function () { var re = $RegExp('(?b)', 'g'); return re.exec('b').groups.a !== 'b' || 'b'.replace(re, '$c') !== 'bc'; @@ -3213,7 +3342,7 @@ return re1.lastIndex !== 0 || re2.lastIndex !== 0; })(); - var UNSUPPORTED_Y$2 = stickyHelpers$2.UNSUPPORTED_Y || stickyHelpers$2.BROKEN_CARET; + var UNSUPPORTED_Y$2 = stickyHelpers$2.BROKEN_CARET; // nonparticipating capturing group, copied from es5-shim's String#split patch. var NPCG_INCLUDED = /()??/.exec('')[1] !== undefined; @@ -3221,7 +3350,6 @@ var PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y$2 || UNSUPPORTED_DOT_ALL$1 || UNSUPPORTED_NCG$1; if (PATCH) { - // eslint-disable-next-line max-statements -- TODO patchedExec = function exec(string) { var re = this; var state = getInternalState$2(re); @@ -3311,7 +3439,7 @@ exec: exec$5 }); - var fails$C = fails$S; + var fails$D = fails$V; var wellKnownSymbol$e = wellKnownSymbol$t; var V8_VERSION$2 = engineV8Version; @@ -3321,7 +3449,7 @@ // We can't use this feature detection in V8 since it causes // deoptimization and serious performance degradation // https://github.com/zloirock/core-js/issues/677 - return V8_VERSION$2 >= 51 || !fails$C(function () { + return V8_VERSION$2 >= 51 || !fails$D(function () { var array = []; var constructor = array.constructor = {}; constructor[SPECIES$3] = function () { @@ -3368,7 +3496,7 @@ forEach: forEach$3 }); - var global$I = global$1m; + var global$J = global$1o; var DOMIterables = domIterables; var DOMTokenListPrototype = domTokenListPrototype; var forEach$2 = arrayForEach; @@ -3385,7 +3513,7 @@ for (var COLLECTION_NAME in DOMIterables) { if (DOMIterables[COLLECTION_NAME]) { - handlePrototype(global$I[COLLECTION_NAME] && global$I[COLLECTION_NAME].prototype); + handlePrototype(global$J[COLLECTION_NAME] && global$J[COLLECTION_NAME].prototype); } } @@ -3401,11 +3529,11 @@ }); var $$10 = _export; - var fails$B = fails$S; + var fails$C = fails$V; var getOwnPropertyNames$3 = objectGetOwnPropertyNamesExternal.f; // eslint-disable-next-line es/no-object-getownpropertynames -- required for testing - var FAILS_ON_PRIMITIVES$5 = fails$B(function () { return !Object.getOwnPropertyNames(1); }); + var FAILS_ON_PRIMITIVES$5 = fails$C(function () { return !Object.getOwnPropertyNames(1); }); // `Object.getOwnPropertyNames` method // https://tc39.es/ecma262/#sec-object.getownpropertynames @@ -3413,9 +3541,9 @@ getOwnPropertyNames: getOwnPropertyNames$3 }); - var global$H = global$1m; + var global$I = global$1o; - var nativePromiseConstructor = global$H.Promise; + var nativePromiseConstructor = global$I.Promise; var wellKnownSymbol$d = wellKnownSymbol$t; var Iterators$1 = iterators; @@ -3441,19 +3569,19 @@ || Iterators[classof$6(it)]; }; - var global$G = global$1m; + var global$H = global$1o; var call$h = functionCall; var aCallable$7 = aCallable$a; var anObject$d = anObject$n; var tryToString$1 = tryToString$5; var getIteratorMethod$4 = getIteratorMethod$5; - var TypeError$c = global$G.TypeError; + var TypeError$d = global$H.TypeError; var getIterator$4 = function (argument, usingIterator) { var iteratorMethod = arguments.length < 2 ? getIteratorMethod$4(argument) : usingIterator; if (aCallable$7(iteratorMethod)) return anObject$d(call$h(iteratorMethod, argument)); - throw TypeError$c(tryToString$1(argument) + ' is not iterable'); + throw TypeError$d(tryToString$1(argument) + ' is not iterable'); }; var call$g = functionCall; @@ -3480,19 +3608,19 @@ return value; }; - var global$F = global$1m; + var global$G = global$1o; var bind$d = functionBindContext; var call$f = functionCall; var anObject$b = anObject$n; var tryToString = tryToString$5; var isArrayIteratorMethod$2 = isArrayIteratorMethod$3; - var lengthOfArrayLike$c = lengthOfArrayLike$g; + var lengthOfArrayLike$d = lengthOfArrayLike$i; var isPrototypeOf$4 = objectIsPrototypeOf; var getIterator$3 = getIterator$4; var getIteratorMethod$3 = getIteratorMethod$5; var iteratorClose$1 = iteratorClose$2; - var TypeError$b = global$F.TypeError; + var TypeError$c = global$G.TypeError; var Result = function (stopped, result) { this.stopped = stopped; @@ -3525,10 +3653,10 @@ iterator = iterable; } else { iterFn = getIteratorMethod$3(iterable); - if (!iterFn) throw TypeError$b(tryToString(iterable) + ' is not iterable'); + if (!iterFn) throw TypeError$c(tryToString(iterable) + ' is not iterable'); // optimisation for array iterators if (isArrayIteratorMethod$2(iterFn)) { - for (index = 0, length = lengthOfArrayLike$c(iterable); length > index; index++) { + for (index = 0, length = lengthOfArrayLike$d(iterable); length > index; index++) { result = callFn(iterable[index]); if (result && isPrototypeOf$4(ResultPrototype, result)) return result; } return new Result(false); @@ -3586,24 +3714,34 @@ return ITERATION_SUPPORT; }; + var global$F = global$1o; + + var TypeError$b = global$F.TypeError; + + var validateArgumentsLength$4 = function (passed, required) { + if (passed < required) throw TypeError$b('Not enough arguments'); + return passed; + }; + var userAgent$6 = engineUserAgent; var engineIsIos = /(?:ipad|iphone|ipod).*applewebkit/i.test(userAgent$6); var classof$5 = classofRaw$1; - var global$E = global$1m; + var global$E = global$1o; var engineIsNode = classof$5(global$E.process) == 'process'; - var global$D = global$1m; + var global$D = global$1o; var apply$7 = functionApply; var bind$c = functionBindContext; var isCallable$8 = isCallable$r; var hasOwn$8 = hasOwnProperty_1; - var fails$A = fails$S; + var fails$B = fails$V; var html = html$2; - var arraySlice$8 = arraySlice$c; + var arraySlice$8 = arraySlice$b; var createElement = documentCreateElement$2; + var validateArgumentsLength$3 = validateArgumentsLength$4; var IS_IOS$1 = engineIsIos; var IS_NODE$4 = engineIsNode; @@ -3615,7 +3753,7 @@ var MessageChannel = global$D.MessageChannel; var String$2 = global$D.String; var counter = 0; - var queue = {}; + var queue$1 = {}; var ONREADYSTATECHANGE = 'onreadystatechange'; var location$1, defer, channel, port; @@ -3625,9 +3763,9 @@ } catch (error) { /* empty */ } var run = function (id) { - if (hasOwn$8(queue, id)) { - var fn = queue[id]; - delete queue[id]; + if (hasOwn$8(queue$1, id)) { + var fn = queue$1[id]; + delete queue$1[id]; fn(); } }; @@ -3649,16 +3787,18 @@ // Node.js 0.9+ & IE10+ has setImmediate, otherwise: if (!set$2 || !clear) { - set$2 = function setImmediate(fn) { + set$2 = function setImmediate(handler) { + validateArgumentsLength$3(arguments.length, 1); + var fn = isCallable$8(handler) ? handler : Function$3(handler); var args = arraySlice$8(arguments, 1); - queue[++counter] = function () { - apply$7(isCallable$8(fn) ? fn : Function$3(fn), undefined, args); + queue$1[++counter] = function () { + apply$7(fn, undefined, args); }; defer(counter); return counter; }; clear = function clearImmediate(id) { - delete queue[id]; + delete queue$1[id]; }; // Node.js 0.8- if (IS_NODE$4) { @@ -3684,7 +3824,7 @@ isCallable$8(global$D.postMessage) && !global$D.importScripts && location$1 && location$1.protocol !== 'file:' && - !fails$A(post) + !fails$B(post) ) { defer = post; global$D.addEventListener('message', listener, false); @@ -3710,7 +3850,7 @@ }; var userAgent$5 = engineUserAgent; - var global$C = global$1m; + var global$C = global$1o; var engineIsIosPebble = /ipad|iphone|ipod/i.test(userAgent$5) && global$C.Pebble !== undefined; @@ -3718,7 +3858,7 @@ var engineIsWebosWebkit = /web0s(?!.*chrome)/i.test(userAgent$4); - var global$B = global$1m; + var global$B = global$1o; var bind$b = functionBindContext; var getOwnPropertyDescriptor$3 = objectGetOwnPropertyDescriptor.f; var macrotask = task$1.set; @@ -3838,7 +3978,7 @@ return promiseCapability.promise; }; - var global$A = global$1m; + var global$A = global$1o; var hostReportErrors$1 = function (a, b) { var console = global$A.console; @@ -3855,10 +3995,34 @@ } }; + var Queue$1 = function () { + this.head = null; + this.tail = null; + }; + + Queue$1.prototype = { + add: function (item) { + var entry = { item: item, next: null }; + if (this.head) this.tail.next = entry; + else this.head = entry; + this.tail = entry; + }, + get: function () { + var entry = this.head; + if (entry) { + this.head = entry.next; + if (this.tail === entry) this.tail = null; + return entry.item; + } + } + }; + + var queue = Queue$1; + var engineIsBrowser = typeof window == 'object'; var $$$ = _export; - var global$z = global$1m; + var global$z = global$1o; var getBuiltIn$3 = getBuiltIn$b; var call$e = functionCall; var NativePromise$1 = nativePromiseConstructor; @@ -3881,6 +4045,7 @@ var hostReportErrors = hostReportErrors$1; var newPromiseCapabilityModule = newPromiseCapability$2; var perform = perform$1; + var Queue = queue; var InternalStateModule$4 = internalState; var isForced$3 = isForced_1; var wellKnownSymbol$a = wellKnownSymbol$t; @@ -3891,7 +4056,7 @@ var SPECIES$2 = wellKnownSymbol$a('species'); var PROMISE = 'Promise'; - var getInternalState$1 = InternalStateModule$4.get; + var getInternalState$1 = InternalStateModule$4.getterFor(PROMISE); var setInternalState$4 = InternalStateModule$4.set; var getInternalPromiseState = InternalStateModule$4.getterFor(PROMISE); var NativePromisePrototype = NativePromise$1 && NativePromise$1.prototype; @@ -3916,7 +4081,7 @@ var Internal, OwnPromiseCapability, PromiseWrapper, nativeThen; - var FORCED$h = isForced$3(PROMISE, function () { + var FORCED$g = isForced$3(PROMISE, function () { var PROMISE_CONSTRUCTOR_SOURCE = inspectSource(PromiseConstructor); var GLOBAL_CORE_JS_PROMISE = PROMISE_CONSTRUCTOR_SOURCE !== String(PromiseConstructor); // V8 6.6 (Node 10 and Chrome 66) have a bug with resolving custom thenables @@ -3940,7 +4105,7 @@ return !GLOBAL_CORE_JS_PROMISE && IS_BROWSER && !NATIVE_REJECTION_EVENT; }); - var INCORRECT_ITERATION$1 = FORCED$h || !checkCorrectnessOfIteration$3(function (iterable) { + var INCORRECT_ITERATION$1 = FORCED$g || !checkCorrectnessOfIteration$3(function (iterable) { PromiseConstructor.all(iterable)['catch'](function () { /* empty */ }); }); @@ -3950,49 +4115,50 @@ return isObject$i(it) && isCallable$7(then = it.then) ? then : false; }; + var callReaction = function (reaction, state) { + var value = state.value; + var ok = state.state == FULFILLED; + var handler = ok ? reaction.ok : reaction.fail; + var resolve = reaction.resolve; + var reject = reaction.reject; + var domain = reaction.domain; + var result, then, exited; + try { + if (handler) { + if (!ok) { + if (state.rejection === UNHANDLED) onHandleUnhandled(state); + state.rejection = HANDLED; + } + if (handler === true) result = value; + else { + if (domain) domain.enter(); + result = handler(value); // can throw + if (domain) { + domain.exit(); + exited = true; + } + } + if (result === reaction.promise) { + reject(TypeError$a('Promise-chain cycle')); + } else if (then = isThenable(result)) { + call$e(then, result, resolve, reject); + } else resolve(result); + } else reject(value); + } catch (error) { + if (domain && !exited) domain.exit(); + reject(error); + } + }; + var notify = function (state, isReject) { if (state.notified) return; state.notified = true; - var chain = state.reactions; microtask(function () { - var value = state.value; - var ok = state.state == FULFILLED; - var index = 0; - // variable length - can't use forEach - while (chain.length > index) { - var reaction = chain[index++]; - var handler = ok ? reaction.ok : reaction.fail; - var resolve = reaction.resolve; - var reject = reaction.reject; - var domain = reaction.domain; - var result, then, exited; - try { - if (handler) { - if (!ok) { - if (state.rejection === UNHANDLED) onHandleUnhandled(state); - state.rejection = HANDLED; - } - if (handler === true) result = value; - else { - if (domain) domain.enter(); - result = handler(value); // can throw - if (domain) { - domain.exit(); - exited = true; - } - } - if (result === reaction.promise) { - reject(TypeError$a('Promise-chain cycle')); - } else if (then = isThenable(result)) { - call$e(then, result, resolve, reject); - } else resolve(result); - } else reject(value); - } catch (error) { - if (domain && !exited) domain.exit(); - reject(error); - } + var reactions = state.reactions; + var reaction; + while (reaction = reactions.get()) { + callReaction(reaction, state); } - state.reactions = []; state.notified = false; if (isReject && !state.rejection) onUnhandled(state); }); @@ -4088,7 +4254,7 @@ }; // constructor polyfill - if (FORCED$h) { + if (FORCED$g) { // 25.4.3.1 Promise(executor) PromiseConstructor = function Promise(executor) { anInstance$5(this, PromisePrototype); @@ -4109,7 +4275,7 @@ done: false, notified: false, parent: false, - reactions: [], + reactions: new Queue(), rejection: false, state: PENDING, value: undefined @@ -4118,16 +4284,18 @@ Internal.prototype = redefineAll$2(PromisePrototype, { // `Promise.prototype.then` method // https://tc39.es/ecma262/#sec-promise.prototype.then + // eslint-disable-next-line unicorn/no-thenable -- safe then: function then(onFulfilled, onRejected) { var state = getInternalPromiseState(this); - var reactions = state.reactions; var reaction = newPromiseCapability(speciesConstructor$3(this, PromiseConstructor)); + state.parent = true; reaction.ok = isCallable$7(onFulfilled) ? onFulfilled : true; reaction.fail = isCallable$7(onRejected) && onRejected; reaction.domain = IS_NODE$2 ? process$1.domain : undefined; - state.parent = true; - reactions[reactions.length] = reaction; - if (state.state != PENDING) notify(state, false); + if (state.state == PENDING) state.reactions.add(reaction); + else microtask(function () { + callReaction(reaction, state); + }); return reaction.promise; }, // `Promise.prototype.catch` method @@ -4178,7 +4346,7 @@ } } - $$$({ global: true, wrap: true, forced: FORCED$h }, { + $$$({ global: true, wrap: true, forced: FORCED$g }, { Promise: PromiseConstructor }); @@ -4188,7 +4356,7 @@ PromiseWrapper = getBuiltIn$3(PROMISE); // statics - $$$({ target: PROMISE, stat: true, forced: FORCED$h }, { + $$$({ target: PROMISE, stat: true, forced: FORCED$g }, { // `Promise.reject` method // https://tc39.es/ecma262/#sec-promise.reject reject: function reject(r) { @@ -4198,7 +4366,7 @@ } }); - $$$({ target: PROMISE, stat: true, forced: FORCED$h }, { + $$$({ target: PROMISE, stat: true, forced: FORCED$g }, { // `Promise.resolve` method // https://tc39.es/ecma262/#sec-promise.resolve resolve: function resolve(x) { @@ -4256,26 +4424,26 @@ /* eslint-disable no-new -- required for testing */ - var global$y = global$1m; - var fails$z = fails$S; + var global$y = global$1o; + var fails$A = fails$V; var checkCorrectnessOfIteration$2 = checkCorrectnessOfIteration$4; var NATIVE_ARRAY_BUFFER_VIEWS$1 = arrayBufferViewCore.NATIVE_ARRAY_BUFFER_VIEWS; var ArrayBuffer$2 = global$y.ArrayBuffer; - var Int8Array$2 = global$y.Int8Array; + var Int8Array$3 = global$y.Int8Array; - var typedArrayConstructorsRequireWrappers = !NATIVE_ARRAY_BUFFER_VIEWS$1 || !fails$z(function () { - Int8Array$2(1); - }) || !fails$z(function () { - new Int8Array$2(-1); + var typedArrayConstructorsRequireWrappers = !NATIVE_ARRAY_BUFFER_VIEWS$1 || !fails$A(function () { + Int8Array$3(1); + }) || !fails$A(function () { + new Int8Array$3(-1); }) || !checkCorrectnessOfIteration$2(function (iterable) { - new Int8Array$2(); - new Int8Array$2(null); - new Int8Array$2(1.5); - new Int8Array$2(iterable); - }, true) || fails$z(function () { + new Int8Array$3(); + new Int8Array$3(null); + new Int8Array$3(1.5); + new Int8Array$3(iterable); + }, true) || fails$A(function () { // Safari (11+) bug - a reason why even Safari 13 should load a typed array polyfill - return new Int8Array$2(new ArrayBuffer$2(2), 1, undefined).length !== 1; + return new Int8Array$3(new ArrayBuffer$2(2), 1, undefined).length !== 1; }); var isObject$h = isObject$s; @@ -4289,7 +4457,7 @@ return !isObject$h(it) && isFinite(it) && floor$6(it) === it; }; - var global$x = global$1m; + var global$x = global$1o; var toIntegerOrInfinity$5 = toIntegerOrInfinity$b; var RangeError$9 = global$x.RangeError; @@ -4300,7 +4468,7 @@ return result; }; - var global$w = global$1m; + var global$w = global$1o; var toPositiveInteger = toPositiveInteger$1; var RangeError$8 = global$w.RangeError; @@ -4314,8 +4482,8 @@ var bind$9 = functionBindContext; var call$d = functionCall; var aConstructor$1 = aConstructor$3; - var toObject$d = toObject$j; - var lengthOfArrayLike$b = lengthOfArrayLike$g; + var toObject$c = toObject$i; + var lengthOfArrayLike$c = lengthOfArrayLike$i; var getIterator$2 = getIterator$4; var getIteratorMethod$2 = getIteratorMethod$5; var isArrayIteratorMethod$1 = isArrayIteratorMethod$3; @@ -4323,7 +4491,7 @@ var typedArrayFrom$2 = function from(source /* , mapfn, thisArg */) { var C = aConstructor$1(this); - var O = toObject$d(source); + var O = toObject$c(source); var argumentsLength = arguments.length; var mapfn = argumentsLength > 1 ? arguments[1] : undefined; var mapping = mapfn !== undefined; @@ -4340,7 +4508,7 @@ if (mapping && argumentsLength > 2) { mapfn = bind$9(mapfn, arguments[2]); } - length = lengthOfArrayLike$b(O); + length = lengthOfArrayLike$c(O); result = new (aTypedArrayConstructor$2(C))(length); for (i = 0; length > i; i++) { result[i] = mapping ? mapfn(O[i], i) : O[i]; @@ -4368,20 +4536,20 @@ }; var $$_ = _export; - var global$v = global$1m; + var global$v = global$1o; var call$c = functionCall; var DESCRIPTORS$c = descriptors; var TYPED_ARRAYS_CONSTRUCTORS_REQUIRES_WRAPPERS$1 = typedArrayConstructorsRequireWrappers; var ArrayBufferViewCore$n = arrayBufferViewCore; var ArrayBufferModule = arrayBuffer; var anInstance$4 = anInstance$7; - var createPropertyDescriptor$2 = createPropertyDescriptor$7; + var createPropertyDescriptor$1 = createPropertyDescriptor$7; var createNonEnumerableProperty$2 = createNonEnumerableProperty$b; var isIntegralNumber = isIntegralNumber$1; var toLength$7 = toLength$c; var toIndex = toIndex$2; var toOffset$1 = toOffset$2; - var toPropertyKey$1 = toPropertyKey$5; + var toPropertyKey = toPropertyKey$5; var hasOwn$7 = hasOwnProperty_1; var classof$4 = classof$d; var isObject$f = isObject$s; @@ -4393,14 +4561,14 @@ var typedArrayFrom$1 = typedArrayFrom$2; var forEach$1 = arrayIteration.forEach; var setSpecies$2 = setSpecies$5; - var definePropertyModule$1 = objectDefineProperty; + var definePropertyModule = objectDefineProperty; var getOwnPropertyDescriptorModule$1 = objectGetOwnPropertyDescriptor; var InternalStateModule$3 = internalState; var inheritIfRequired$3 = inheritIfRequired$4; var getInternalState = InternalStateModule$3.get; var setInternalState$3 = InternalStateModule$3.set; - var nativeDefineProperty = definePropertyModule$1.f; + var nativeDefineProperty = definePropertyModule.f; var nativeGetOwnPropertyDescriptor$1 = getOwnPropertyDescriptorModule$1.f; var round = Math.round; var RangeError$7 = global$v.RangeError; @@ -4411,7 +4579,7 @@ var TYPED_ARRAY_CONSTRUCTOR$1 = ArrayBufferViewCore$n.TYPED_ARRAY_CONSTRUCTOR; var TYPED_ARRAY_TAG = ArrayBufferViewCore$n.TYPED_ARRAY_TAG; var TypedArray = ArrayBufferViewCore$n.TypedArray; - var TypedArrayPrototype = ArrayBufferViewCore$n.TypedArrayPrototype; + var TypedArrayPrototype$1 = ArrayBufferViewCore$n.TypedArrayPrototype; var aTypedArrayConstructor$1 = ArrayBufferViewCore$n.aTypedArrayConstructor; var isTypedArray = ArrayBufferViewCore$n.isTypedArray; var BYTES_PER_ELEMENT = 'BYTES_PER_ELEMENT'; @@ -4446,14 +4614,14 @@ }; var wrappedGetOwnPropertyDescriptor = function getOwnPropertyDescriptor(target, key) { - key = toPropertyKey$1(key); + key = toPropertyKey(key); return isTypedArrayIndex(target, key) - ? createPropertyDescriptor$2(2, target[key]) + ? createPropertyDescriptor$1(2, target[key]) : nativeGetOwnPropertyDescriptor$1(target, key); }; var wrappedDefineProperty = function defineProperty(target, key, descriptor) { - key = toPropertyKey$1(key); + key = toPropertyKey(key); if (isTypedArrayIndex(target, key) && isObject$f(descriptor) && hasOwn$7(descriptor, 'value') @@ -4472,11 +4640,11 @@ if (DESCRIPTORS$c) { if (!NATIVE_ARRAY_BUFFER_VIEWS) { getOwnPropertyDescriptorModule$1.f = wrappedGetOwnPropertyDescriptor; - definePropertyModule$1.f = wrappedDefineProperty; - addGetter(TypedArrayPrototype, 'buffer'); - addGetter(TypedArrayPrototype, 'byteOffset'); - addGetter(TypedArrayPrototype, 'byteLength'); - addGetter(TypedArrayPrototype, 'length'); + definePropertyModule.f = wrappedDefineProperty; + addGetter(TypedArrayPrototype$1, 'buffer'); + addGetter(TypedArrayPrototype$1, 'byteOffset'); + addGetter(TypedArrayPrototype$1, 'byteLength'); + addGetter(TypedArrayPrototype$1, 'length'); } $$_({ target: 'Object', stat: true, forced: !NATIVE_ARRAY_BUFFER_VIEWS }, { @@ -4556,7 +4724,7 @@ }); if (setPrototypeOf$1) setPrototypeOf$1(TypedArrayConstructor, TypedArray); - TypedArrayConstructorPrototype = TypedArrayConstructor.prototype = create$7(TypedArrayPrototype); + TypedArrayConstructorPrototype = TypedArrayConstructor.prototype = create$7(TypedArrayPrototype$1); } else if (TYPED_ARRAYS_CONSTRUCTORS_REQUIRES_WRAPPERS$1) { TypedArrayConstructor = wrapper(function (dummy, data, typedArrayOffset, $length) { anInstance$4(dummy, TypedArrayConstructorPrototype); @@ -4619,9 +4787,9 @@ }; }); - var toObject$c = toObject$j; - var toAbsoluteIndex$4 = toAbsoluteIndex$8; - var lengthOfArrayLike$a = lengthOfArrayLike$g; + var toObject$b = toObject$i; + var toAbsoluteIndex$4 = toAbsoluteIndex$9; + var lengthOfArrayLike$b = lengthOfArrayLike$i; var min$7 = Math.min; @@ -4629,8 +4797,8 @@ // https://tc39.es/ecma262/#sec-array.prototype.copywithin // eslint-disable-next-line es/no-array-prototype-copywithin -- safe var arrayCopyWithin = [].copyWithin || function copyWithin(target /* = 0 */, start /* = 0, end = @length */) { - var O = toObject$c(this); - var len = lengthOfArrayLike$a(O); + var O = toObject$b(this); + var len = lengthOfArrayLike$b(O); var to = toAbsoluteIndex$4(target, len); var from = toAbsoluteIndex$4(start, len); var end = arguments.length > 2 ? arguments[2] : undefined; @@ -4695,9 +4863,11 @@ ); }); + var lengthOfArrayLike$a = lengthOfArrayLike$i; + var arrayFromConstructorAndList$1 = function (Constructor, list) { var index = 0; - var length = list.length; + var length = lengthOfArrayLike$a(list); var result = new Constructor(length); while (length > index) result[index] = list[index++]; return result; @@ -4796,9 +4966,9 @@ return $indexOf(aTypedArray$d(this), searchElement, arguments.length > 1 ? arguments[1] : undefined); }); - var global$u = global$1m; + var global$u = global$1o; + var fails$z = fails$V; var uncurryThis$z = functionUncurryThis; - var PROPER_FUNCTION_NAME$2 = functionName.PROPER; var ArrayBufferViewCore$c = arrayBufferViewCore; var ArrayIterators = es_array_iterator; var wellKnownSymbol$9 = wellKnownSymbol$t; @@ -4810,9 +4980,16 @@ var arrayEntries = uncurryThis$z(ArrayIterators.entries); var aTypedArray$c = ArrayBufferViewCore$c.aTypedArray; var exportTypedArrayMethod$d = ArrayBufferViewCore$c.exportTypedArrayMethod; - var nativeTypedArrayIterator = Uint8Array$2 && Uint8Array$2.prototype[ITERATOR$4]; + var TypedArrayPrototype = Uint8Array$2 && Uint8Array$2.prototype; + + var GENERIC = !fails$z(function () { + TypedArrayPrototype[ITERATOR$4].call([1]); + }); - var PROPER_ARRAY_VALUES_NAME = !!nativeTypedArrayIterator && nativeTypedArrayIterator.name === 'values'; + var ITERATOR_IS_VALUES = !!TypedArrayPrototype + && TypedArrayPrototype.values + && TypedArrayPrototype[ITERATOR$4] === TypedArrayPrototype.values + && TypedArrayPrototype.values.name === 'values'; var typedArrayValues = function values() { return arrayValues(aTypedArray$c(this)); @@ -4822,18 +4999,18 @@ // https://tc39.es/ecma262/#sec-%typedarray%.prototype.entries exportTypedArrayMethod$d('entries', function entries() { return arrayEntries(aTypedArray$c(this)); - }); + }, GENERIC); // `%TypedArray%.prototype.keys` method // https://tc39.es/ecma262/#sec-%typedarray%.prototype.keys exportTypedArrayMethod$d('keys', function keys() { return arrayKeys(aTypedArray$c(this)); - }); + }, GENERIC); // `%TypedArray%.prototype.values` method // https://tc39.es/ecma262/#sec-%typedarray%.prototype.values - exportTypedArrayMethod$d('values', typedArrayValues, PROPER_FUNCTION_NAME$2 && !PROPER_ARRAY_VALUES_NAME); + exportTypedArrayMethod$d('values', typedArrayValues, GENERIC || !ITERATOR_IS_VALUES, { name: 'values' }); // `%TypedArray%.prototype[@@iterator]` method // https://tc39.es/ecma262/#sec-%typedarray%.prototype-@@iterator - exportTypedArrayMethod$d(ITERATOR$4, typedArrayValues, PROPER_FUNCTION_NAME$2 && !PROPER_ARRAY_VALUES_NAME); + exportTypedArrayMethod$d(ITERATOR$4, typedArrayValues, GENERIC || !ITERATOR_IS_VALUES, { name: 'values' }); var ArrayBufferViewCore$b = arrayBufferViewCore; var uncurryThis$y = functionUncurryThis; @@ -4850,23 +5027,23 @@ /* eslint-disable es/no-array-prototype-lastindexof -- safe */ var apply$6 = functionApply; - var toIndexedObject$4 = toIndexedObject$c; + var toIndexedObject$5 = toIndexedObject$d; var toIntegerOrInfinity$4 = toIntegerOrInfinity$b; - var lengthOfArrayLike$9 = lengthOfArrayLike$g; + var lengthOfArrayLike$9 = lengthOfArrayLike$i; var arrayMethodIsStrict$6 = arrayMethodIsStrict$9; var min$6 = Math.min; var $lastIndexOf$1 = [].lastIndexOf; var NEGATIVE_ZERO = !!$lastIndexOf$1 && 1 / [1].lastIndexOf(1, -0) < 0; var STRICT_METHOD$6 = arrayMethodIsStrict$6('lastIndexOf'); - var FORCED$g = NEGATIVE_ZERO || !STRICT_METHOD$6; + var FORCED$f = NEGATIVE_ZERO || !STRICT_METHOD$6; // `Array.prototype.lastIndexOf` method implementation // https://tc39.es/ecma262/#sec-array.prototype.lastindexof - var arrayLastIndexOf = FORCED$g ? function lastIndexOf(searchElement /* , fromIndex = @[*-1] */) { + var arrayLastIndexOf = FORCED$f ? function lastIndexOf(searchElement /* , fromIndex = @[*-1] */) { // convert -0 to +0 if (NEGATIVE_ZERO) return apply$6($lastIndexOf$1, this, arguments) || 0; - var O = toIndexedObject$4(this); + var O = toIndexedObject$5(this); var length = lengthOfArrayLike$9(O); var index = length - 1; if (arguments.length > 1) index = min$6(index, toIntegerOrInfinity$4(arguments[1])); @@ -4904,11 +5081,11 @@ }); }); - var global$t = global$1m; + var global$t = global$1o; var aCallable$4 = aCallable$a; - var toObject$b = toObject$j; + var toObject$a = toObject$i; var IndexedObject$2 = indexedObject; - var lengthOfArrayLike$8 = lengthOfArrayLike$g; + var lengthOfArrayLike$8 = lengthOfArrayLike$i; var TypeError$9 = global$t.TypeError; @@ -4916,7 +5093,7 @@ var createMethod$3 = function (IS_RIGHT) { return function (that, callbackfn, argumentsLength, memo) { aCallable$4(callbackfn); - var O = toObject$b(that); + var O = toObject$a(that); var self = IndexedObject$2(O); var length = lengthOfArrayLike$8(O); var index = IS_RIGHT ? length - 1 : 0; @@ -4995,20 +5172,34 @@ } return that; }); - var global$s = global$1m; + var global$s = global$1o; + var call$a = functionCall; var ArrayBufferViewCore$5 = arrayBufferViewCore; - var lengthOfArrayLike$7 = lengthOfArrayLike$g; + var lengthOfArrayLike$7 = lengthOfArrayLike$i; var toOffset = toOffset$2; - var toObject$a = toObject$j; - var fails$y = fails$S; + var toIndexedObject$4 = toObject$i; + var fails$y = fails$V; var RangeError$6 = global$s.RangeError; + var Int8Array$2 = global$s.Int8Array; + var Int8ArrayPrototype = Int8Array$2 && Int8Array$2.prototype; + var $set = Int8ArrayPrototype && Int8ArrayPrototype.set; var aTypedArray$5 = ArrayBufferViewCore$5.aTypedArray; var exportTypedArrayMethod$6 = ArrayBufferViewCore$5.exportTypedArrayMethod; - var FORCED$f = fails$y(function () { + var WORKS_WITH_OBJECTS_AND_GEERIC_ON_TYPED_ARRAYS = !fails$y(function () { // eslint-disable-next-line es/no-typed-arrays -- required for testing - new Int8Array(1).set({}); + var array = new Uint8ClampedArray(2); + call$a($set, array, { length: 1, 0: 3 }, 1); + return array[1] !== 3; + }); + + // https://bugs.chromium.org/p/v8/issues/detail?id=11294 and other + var TO_OBJECT_BUG = WORKS_WITH_OBJECTS_AND_GEERIC_ON_TYPED_ARRAYS && ArrayBufferViewCore$5.NATIVE_ARRAY_BUFFER_VIEWS && fails$y(function () { + var array = new Int8Array$2(2); + array.set(1); + array.set('2', 1); + return array[0] !== 0 || array[1] !== 2; }); // `%TypedArray%.prototype.set` method @@ -5016,18 +5207,19 @@ exportTypedArrayMethod$6('set', function set(arrayLike /* , offset */) { aTypedArray$5(this); var offset = toOffset(arguments.length > 1 ? arguments[1] : undefined, 1); + var src = toIndexedObject$4(arrayLike); + if (WORKS_WITH_OBJECTS_AND_GEERIC_ON_TYPED_ARRAYS) return call$a($set, this, src, offset); var length = this.length; - var src = toObject$a(arrayLike); var len = lengthOfArrayLike$7(src); var index = 0; if (len + offset > length) throw RangeError$6('Wrong length'); while (index < len) this[offset + index] = src[index++]; - }, FORCED$f); + }, !WORKS_WITH_OBJECTS_AND_GEERIC_ON_TYPED_ARRAYS || TO_OBJECT_BUG); var ArrayBufferViewCore$4 = arrayBufferViewCore; var typedArraySpeciesConstructor$1 = typedArraySpeciesConstructor$4; - var fails$x = fails$S; - var arraySlice$7 = arraySlice$c; + var fails$x = fails$V; + var arraySlice$7 = arraySlice$b; var aTypedArray$4 = ArrayBufferViewCore$4.aTypedArray; var exportTypedArrayMethod$5 = ArrayBufferViewCore$4.exportTypedArrayMethod; @@ -5061,7 +5253,7 @@ return $some$1(aTypedArray$3(this), callbackfn, arguments.length > 1 ? arguments[1] : undefined); }); - var arraySlice$6 = arraySlice$c; + var arraySlice$6 = arraySliceSimple; var floor$4 = Math.floor; @@ -5122,9 +5314,9 @@ var engineWebkitVersion = !!webkit && +webkit[1]; - var global$r = global$1m; + var global$r = global$1o; var uncurryThis$x = functionUncurryThis; - var fails$w = fails$S; + var fails$w = fails$V; var aCallable$3 = aCallable$a; var internalSort$1 = arraySort$1; var ArrayBufferViewCore$2 = arrayBufferViewCore; @@ -5195,7 +5387,7 @@ var ArrayBufferViewCore$1 = arrayBufferViewCore; var toLength$6 = toLength$c; - var toAbsoluteIndex$3 = toAbsoluteIndex$8; + var toAbsoluteIndex$3 = toAbsoluteIndex$9; var typedArraySpeciesConstructor = typedArraySpeciesConstructor$4; var aTypedArray$1 = ArrayBufferViewCore$1.aTypedArray; @@ -5215,11 +5407,11 @@ ); }); - var global$q = global$1m; + var global$q = global$1o; var apply$4 = functionApply; var ArrayBufferViewCore = arrayBufferViewCore; - var fails$v = fails$S; - var arraySlice$5 = arraySlice$c; + var fails$v = fails$V; + var arraySlice$5 = arraySlice$b; var Int8Array$1 = global$q.Int8Array; var aTypedArray = ArrayBufferViewCore.aTypedArray; @@ -5248,8 +5440,8 @@ }, FORCED$d); var exportTypedArrayMethod = arrayBufferViewCore.exportTypedArrayMethod; - var fails$u = fails$S; - var global$p = global$1m; + var fails$u = fails$V; + var global$p = global$1o; var uncurryThis$w = functionUncurryThis; var Uint8Array$1 = global$p.Uint8Array; @@ -5272,7 +5464,7 @@ var $$Z = _export; var uncurryThis$v = functionUncurryThis; var IndexedObject$1 = indexedObject; - var toIndexedObject$3 = toIndexedObject$c; + var toIndexedObject$3 = toIndexedObject$d; var arrayMethodIsStrict$5 = arrayMethodIsStrict$9; var un$Join = uncurryThis$v([].join); @@ -5288,28 +5480,18 @@ } }); - var toPropertyKey = toPropertyKey$5; - var definePropertyModule = objectDefineProperty; - var createPropertyDescriptor$1 = createPropertyDescriptor$7; - - var createProperty$4 = function (object, key, value) { - var propertyKey = toPropertyKey(key); - if (propertyKey in object) definePropertyModule.f(object, propertyKey, createPropertyDescriptor$1(0, value)); - else object[propertyKey] = value; - }; - var $$Y = _export; - var global$o = global$1m; + var global$o = global$1o; var isArray$4 = isArray$8; var isConstructor$1 = isConstructor$4; var isObject$e = isObject$s; - var toAbsoluteIndex$2 = toAbsoluteIndex$8; - var lengthOfArrayLike$6 = lengthOfArrayLike$g; - var toIndexedObject$2 = toIndexedObject$c; - var createProperty$3 = createProperty$4; + var toAbsoluteIndex$2 = toAbsoluteIndex$9; + var lengthOfArrayLike$6 = lengthOfArrayLike$i; + var toIndexedObject$2 = toIndexedObject$d; + var createProperty$3 = createProperty$5; var wellKnownSymbol$8 = wellKnownSymbol$t; var arrayMethodHasSpeciesSupport$3 = arrayMethodHasSpeciesSupport$5; - var un$Slice = arraySlice$c; + var un$Slice = arraySlice$b; var HAS_SPECIES_SUPPORT$2 = arrayMethodHasSpeciesSupport$3('slice'); @@ -5348,13 +5530,14 @@ } }); - var fails$t = fails$S; + var fails$t = fails$V; var wellKnownSymbol$7 = wellKnownSymbol$t; var IS_PURE = isPure; var ITERATOR$3 = wellKnownSymbol$7('iterator'); var nativeUrl = !fails$t(function () { + // eslint-disable-next-line unicorn/relative-url-style -- required for testing var url = new URL('b?a=1&b=2&c=3', 'http://a'); var searchParams = url.searchParams; var result = ''; @@ -5385,9 +5568,9 @@ // TODO: in core-js@4, move /modules/ dependencies to public entries for better optimization by tools like `preset-env` var $$X = _export; - var global$n = global$1m; + var global$n = global$1o; var getBuiltIn$2 = getBuiltIn$b; - var call$a = functionCall; + var call$9 = functionCall; var uncurryThis$u = functionUncurryThis; var USE_NATIVE_URL$1 = nativeUrl; var redefine$7 = redefine$h.exports; @@ -5407,6 +5590,7 @@ var createPropertyDescriptor = createPropertyDescriptor$7; var getIterator$1 = getIterator$4; var getIteratorMethod$1 = getIteratorMethod$5; + var validateArgumentsLength$2 = validateArgumentsLength$4; var wellKnownSymbol$6 = wellKnownSymbol$t; var arraySort = arraySort$1; @@ -5482,33 +5666,6 @@ return replace$6(encodeURIComponent$1(it), find$1, replacer); }; - var parseSearchParams = function (result, query) { - if (query) { - var attributes = split$3(query, '&'); - var index = 0; - var attribute, entry; - while (index < attributes.length) { - attribute = attributes[index++]; - if (attribute.length) { - entry = split$3(attribute, '='); - push$7(result, { - key: deserialize(shift$1(entry)), - value: deserialize(join$4(entry, '=')) - }); - } - } - } - }; - - var updateSearchParams = function (query) { - this.entries.length = 0; - parseSearchParams(this.entries, query); - }; - - var validateArgumentsLength = function (passed, required) { - if (passed < required) throw TypeError$8('Not enough arguments'); - }; - var URLSearchParamsIterator = createIteratorConstructor(function Iterator(params, kind) { setInternalState$2(this, { type: URL_SEARCH_PARAMS_ITERATOR, @@ -5523,57 +5680,96 @@ if (!step.done) { step.value = kind === 'keys' ? entry.key : kind === 'values' ? entry.value : [entry.key, entry.value]; } return step; - }); + }, true); - // `URLSearchParams` constructor - // https://url.spec.whatwg.org/#interface-urlsearchparams - var URLSearchParamsConstructor = function URLSearchParams(/* init */) { - anInstance$3(this, URLSearchParamsPrototype); - var init = arguments.length > 0 ? arguments[0] : undefined; - var that = this; - var entries = []; - var iteratorMethod, iterator, next, step, entryIterator, entryNext, first, second, key; - - setInternalState$2(that, { - type: URL_SEARCH_PARAMS, - entries: entries, - updateURL: function () { /* empty */ }, - updateSearchParams: updateSearchParams - }); + var URLSearchParamsState = function (init) { + this.entries = []; + this.url = null; if (init !== undefined) { - if (isObject$d(init)) { - iteratorMethod = getIteratorMethod$1(init); - if (iteratorMethod) { - iterator = getIterator$1(init, iteratorMethod); - next = iterator.next; - while (!(step = call$a(next, iterator)).done) { - entryIterator = getIterator$1(anObject$9(step.value)); - entryNext = entryIterator.next; - if ( - (first = call$a(entryNext, entryIterator)).done || - (second = call$a(entryNext, entryIterator)).done || - !call$a(entryNext, entryIterator).done - ) throw TypeError$8('Expected sequence with length 2'); - push$7(entries, { key: $toString$2(first.value), value: $toString$2(second.value) }); + if (isObject$d(init)) this.parseObject(init); + else this.parseQuery(typeof init == 'string' ? charAt$5(init, 0) === '?' ? stringSlice$8(init, 1) : init : $toString$2(init)); + } + }; + + URLSearchParamsState.prototype = { + type: URL_SEARCH_PARAMS, + bindURL: function (url) { + this.url = url; + this.update(); + }, + parseObject: function (object) { + var iteratorMethod = getIteratorMethod$1(object); + var iterator, next, step, entryIterator, entryNext, first, second; + + if (iteratorMethod) { + iterator = getIterator$1(object, iteratorMethod); + next = iterator.next; + while (!(step = call$9(next, iterator)).done) { + entryIterator = getIterator$1(anObject$9(step.value)); + entryNext = entryIterator.next; + if ( + (first = call$9(entryNext, entryIterator)).done || + (second = call$9(entryNext, entryIterator)).done || + !call$9(entryNext, entryIterator).done + ) throw TypeError$8('Expected sequence with length 2'); + push$7(this.entries, { key: $toString$2(first.value), value: $toString$2(second.value) }); + } + } else for (var key in object) if (hasOwn$6(object, key)) { + push$7(this.entries, { key: key, value: $toString$2(object[key]) }); + } + }, + parseQuery: function (query) { + if (query) { + var attributes = split$3(query, '&'); + var index = 0; + var attribute, entry; + while (index < attributes.length) { + attribute = attributes[index++]; + if (attribute.length) { + entry = split$3(attribute, '='); + push$7(this.entries, { + key: deserialize(shift$1(entry)), + value: deserialize(join$4(entry, '=')) + }); } - } else for (key in init) if (hasOwn$6(init, key)) push$7(entries, { key: key, value: $toString$2(init[key]) }); - } else { - parseSearchParams( - entries, - typeof init == 'string' ? charAt$5(init, 0) === '?' ? stringSlice$8(init, 1) : init : $toString$2(init) - ); + } } + }, + serialize: function () { + var entries = this.entries; + var result = []; + var index = 0; + var entry; + while (index < entries.length) { + entry = entries[index++]; + push$7(result, serialize(entry.key) + '=' + serialize(entry.value)); + } return join$4(result, '&'); + }, + update: function () { + this.entries.length = 0; + this.parseQuery(this.url.query); + }, + updateURL: function () { + if (this.url) this.url.update(); } }; + // `URLSearchParams` constructor + // https://url.spec.whatwg.org/#interface-urlsearchparams + var URLSearchParamsConstructor = function URLSearchParams(/* init */) { + anInstance$3(this, URLSearchParamsPrototype); + var init = arguments.length > 0 ? arguments[0] : undefined; + setInternalState$2(this, new URLSearchParamsState(init)); + }; + var URLSearchParamsPrototype = URLSearchParamsConstructor.prototype; redefineAll$1(URLSearchParamsPrototype, { // `URLSearchParams.prototype.append` method // https://url.spec.whatwg.org/#dom-urlsearchparams-append append: function append(name, value) { - validateArgumentsLength(arguments.length, 2); + validateArgumentsLength$2(arguments.length, 2); var state = getInternalParamsState(this); push$7(state.entries, { key: $toString$2(name), value: $toString$2(value) }); state.updateURL(); @@ -5581,7 +5777,7 @@ // `URLSearchParams.prototype.delete` method // https://url.spec.whatwg.org/#dom-urlsearchparams-delete 'delete': function (name) { - validateArgumentsLength(arguments.length, 1); + validateArgumentsLength$2(arguments.length, 1); var state = getInternalParamsState(this); var entries = state.entries; var key = $toString$2(name); @@ -5595,7 +5791,7 @@ // `URLSearchParams.prototype.get` method // https://url.spec.whatwg.org/#dom-urlsearchparams-get get: function get(name) { - validateArgumentsLength(arguments.length, 1); + validateArgumentsLength$2(arguments.length, 1); var entries = getInternalParamsState(this).entries; var key = $toString$2(name); var index = 0; @@ -5607,7 +5803,7 @@ // `URLSearchParams.prototype.getAll` method // https://url.spec.whatwg.org/#dom-urlsearchparams-getall getAll: function getAll(name) { - validateArgumentsLength(arguments.length, 1); + validateArgumentsLength$2(arguments.length, 1); var entries = getInternalParamsState(this).entries; var key = $toString$2(name); var result = []; @@ -5620,7 +5816,7 @@ // `URLSearchParams.prototype.has` method // https://url.spec.whatwg.org/#dom-urlsearchparams-has has: function has(name) { - validateArgumentsLength(arguments.length, 1); + validateArgumentsLength$2(arguments.length, 1); var entries = getInternalParamsState(this).entries; var key = $toString$2(name); var index = 0; @@ -5632,7 +5828,7 @@ // `URLSearchParams.prototype.set` method // https://url.spec.whatwg.org/#dom-urlsearchparams-set set: function set(name, value) { - validateArgumentsLength(arguments.length, 1); + validateArgumentsLength$2(arguments.length, 1); var state = getInternalParamsState(this); var entries = state.entries; var found = false; @@ -5693,14 +5889,7 @@ // `URLSearchParams.prototype.toString` method // https://url.spec.whatwg.org/#urlsearchparams-stringification-behavior redefine$7(URLSearchParamsPrototype, 'toString', function toString() { - var entries = getInternalParamsState(this).entries; - var result = []; - var index = 0; - var entry; - while (index < entries.length) { - entry = entries[index++]; - push$7(result, serialize(entry.key) + '=' + serialize(entry.value)); - } return join$4(result, '&'); + return getInternalParamsState(this).serialize(); }, { enumerable: true }); setToStringTag$4(URLSearchParamsConstructor, URL_SEARCH_PARAMS); @@ -5765,7 +5954,7 @@ var anObject$8 = anObject$n; var isPrototypeOf$2 = objectIsPrototypeOf; var $toString$1 = toString$k; - var fails$s = fails$S; + var fails$s = fails$V; var regExpFlags$2 = regexpFlags$1; var TO_STRING = 'toString'; @@ -5794,7 +5983,7 @@ var uncurryThis$s = functionUncurryThis; var redefine$5 = redefine$h.exports; var regexpExec$2 = regexpExec$3; - var fails$r = fails$S; + var fails$r = fails$V; var wellKnownSymbol$5 = wellKnownSymbol$t; var createNonEnumerableProperty$1 = createNonEnumerableProperty$b; @@ -5872,7 +6061,7 @@ }; var uncurryThis$r = functionUncurryThis; - var toObject$9 = toObject$j; + var toObject$9 = toObject$i; var floor$3 = Math.floor; var charAt$3 = uncurryThis$r(''.charAt); @@ -5916,8 +6105,8 @@ }); }; - var global$m = global$1m; - var call$9 = functionCall; + var global$m = global$1o; + var call$8 = functionCall; var anObject$7 = anObject$n; var isCallable$4 = isCallable$r; var classof$2 = classofRaw$1; @@ -5930,19 +6119,19 @@ var regexpExecAbstract = function (R, S) { var exec = R.exec; if (isCallable$4(exec)) { - var result = call$9(exec, R, S); + var result = call$8(exec, R, S); if (result !== null) anObject$7(result); return result; } - if (classof$2(R) === 'RegExp') return call$9(regexpExec$1, R, S); + if (classof$2(R) === 'RegExp') return call$8(regexpExec$1, R, S); throw TypeError$7('RegExp#exec called on incompatible receiver'); }; var apply$3 = functionApply; - var call$8 = functionCall; + var call$7 = functionCall; var uncurryThis$q = functionUncurryThis; var fixRegExpWellKnownSymbolLogic$3 = fixRegexpWellKnownSymbolLogic; - var fails$q = fails$S; + var fails$q = fails$V; var anObject$6 = anObject$n; var isCallable$3 = isCallable$r; var toIntegerOrInfinity$3 = toIntegerOrInfinity$b; @@ -6004,8 +6193,8 @@ var O = requireObjectCoercible$a(this); var replacer = searchValue == undefined ? undefined : getMethod$3(searchValue, REPLACE); return replacer - ? call$8(replacer, searchValue, O, replaceValue) - : call$8(nativeReplace, toString$f(O), searchValue, replaceValue); + ? call$7(replacer, searchValue, O, replaceValue) + : call$7(nativeReplace, toString$f(O), searchValue, replaceValue); }, // `RegExp.prototype[@@replace]` method // https://tc39.es/ecma262/#sec-regexp.prototype-@@replace @@ -6088,7 +6277,7 @@ }; var apply$2 = functionApply; - var call$7 = functionCall; + var call$6 = functionCall; var uncurryThis$p = functionUncurryThis; var fixRegExpWellKnownSymbolLogic$2 = fixRegexpWellKnownSymbolLogic; var isRegExp$2 = isRegexp; @@ -6099,11 +6288,11 @@ var toLength$4 = toLength$c; var toString$e = toString$k; var getMethod$2 = getMethod$7; - var arraySlice$4 = arraySlice$c; + var arraySlice$4 = arraySliceSimple; var callRegExpExec = regexpExecAbstract; var regexpExec = regexpExec$3; var stickyHelpers$1 = regexpStickyHelpers; - var fails$p = fails$S; + var fails$p = fails$V; var UNSUPPORTED_Y$1 = stickyHelpers$1.UNSUPPORTED_Y; var MAX_UINT32 = 0xFFFFFFFF; @@ -6145,7 +6334,7 @@ if (separator === undefined) return [string]; // If `separator` is not a regex, use native split if (!isRegExp$2(separator)) { - return call$7(nativeSplit, string, separator, lim); + return call$6(nativeSplit, string, separator, lim); } var output = []; var flags = (separator.ignoreCase ? 'i' : '') + @@ -6156,7 +6345,7 @@ // Make `global` and avoid `lastIndex` issues by working with a copy var separatorCopy = new RegExp(separator.source, flags + 'g'); var match, lastIndex, lastLength; - while (match = call$7(regexpExec, separatorCopy, string)) { + while (match = call$6(regexpExec, separatorCopy, string)) { lastIndex = separatorCopy.lastIndex; if (lastIndex > lastLastIndex) { push$5(output, stringSlice$5(string, lastLastIndex, match.index)); @@ -6175,7 +6364,7 @@ // Chakra, V8 } else if ('0'.split(undefined, 0).length) { internalSplit = function (separator, limit) { - return separator === undefined && limit === 0 ? [] : call$7(nativeSplit, this, separator, limit); + return separator === undefined && limit === 0 ? [] : call$6(nativeSplit, this, separator, limit); }; } else internalSplit = nativeSplit; @@ -6186,8 +6375,8 @@ var O = requireObjectCoercible$9(this); var splitter = separator == undefined ? undefined : getMethod$2(separator, SPLIT); return splitter - ? call$7(splitter, separator, O, limit) - : call$7(internalSplit, toString$e(O), separator, limit); + ? call$6(splitter, separator, O, limit) + : call$6(internalSplit, toString$e(O), separator, limit); }, // `RegExp.prototype[@@split]` method // https://tc39.es/ecma262/#sec-regexp.prototype-@@split @@ -6280,7 +6469,7 @@ }; var PROPER_FUNCTION_NAME = functionName.PROPER; - var fails$o = fails$S; + var fails$o = fails$V; var whitespaces$2 = whitespaces$4; var non = '\u200B\u0085\u180E'; @@ -6310,18 +6499,18 @@ var DESCRIPTORS$b = descriptors; var FUNCTION_NAME_EXISTS = functionName.EXISTS; var uncurryThis$n = functionUncurryThis; - var defineProperty$5 = objectDefineProperty.f; + var defineProperty$6 = objectDefineProperty.f; var FunctionPrototype = Function.prototype; var functionToString = uncurryThis$n(FunctionPrototype.toString); - var nameRE = /^\s*function ([^ (]*)/; + var nameRE = /function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/; var regExpExec$2 = uncurryThis$n(nameRE.exec); var NAME = 'name'; // Function instances `.name` property // https://tc39.es/ecma262/#sec-function-instances-name if (DESCRIPTORS$b && !FUNCTION_NAME_EXISTS) { - defineProperty$5(FunctionPrototype, NAME, { + defineProperty$6(FunctionPrototype, NAME, { configurable: true, get: function () { try { @@ -6344,22 +6533,24 @@ }); var $$U = _export; - var global$l = global$1m; + var global$l = global$1o; var apply$1 = functionApply; var isCallable$2 = isCallable$r; var userAgent$1 = engineUserAgent; - var arraySlice$3 = arraySlice$c; + var arraySlice$3 = arraySlice$b; + var validateArgumentsLength$1 = validateArgumentsLength$4; var MSIE = /MSIE .\./.test(userAgent$1); // <- dirty ie9- check var Function$2 = global$l.Function; var wrap$1 = function (scheduler) { return function (handler, timeout /* , ...arguments */) { - var boundArgs = arguments.length > 2; + var boundArgs = validateArgumentsLength$1(arguments.length, 1) > 2; + var fn = isCallable$2(handler) ? handler : Function$2(handler); var args = boundArgs ? arraySlice$3(arguments, 2) : undefined; return scheduler(boundArgs ? function () { - apply$1(isCallable$2(handler) ? handler : Function$2(handler), this, args); - } : handler, timeout); + apply$1(fn, this, args); + } : fn, timeout); }; }; @@ -6982,12 +7173,13 @@ var $$T = _export; var DESCRIPTORS$9 = descriptors; - var objectDefinePropertyModile = objectDefineProperty; + var defineProperty$5 = objectDefineProperty.f; // `Object.defineProperty` method // https://tc39.es/ecma262/#sec-object.defineproperty - $$T({ target: 'Object', stat: true, forced: !DESCRIPTORS$9, sham: !DESCRIPTORS$9 }, { - defineProperty: objectDefinePropertyModile.f + // eslint-disable-next-line es/no-object-defineproperty -- safe + $$T({ target: 'Object', stat: true, forced: Object.defineProperty !== defineProperty$5, sham: !DESCRIPTORS$9 }, { + defineProperty: defineProperty$5 }); var $$S = _export; @@ -7000,8 +7192,8 @@ }); var $$R = _export; - var fails$n = fails$S; - var toObject$8 = toObject$j; + var fails$n = fails$V; + var toObject$8 = toObject$i; var nativeGetPrototypeOf = objectGetPrototypeOf; var CORRECT_PROTOTYPE_GETTER = correctPrototypeGetter; @@ -7015,12 +7207,13 @@ } }); - var global$j = global$1m; + var global$j = global$1o; var uncurryThis$m = functionUncurryThis; var aCallable$2 = aCallable$a; var isObject$b = isObject$s; var hasOwn$5 = hasOwnProperty_1; - var arraySlice$2 = arraySlice$c; + var arraySlice$2 = arraySlice$b; + var NATIVE_BIND = functionBindNative; var Function$1 = global$j.Function; var concat$1 = uncurryThis$m([].concat); @@ -7036,7 +7229,7 @@ // `Function.prototype.bind` method implementation // https://tc39.es/ecma262/#sec-function.prototype.bind - var functionBind = Function$1.bind || function bind(that /* , ...args */) { + var functionBind = NATIVE_BIND ? Function$1.bind : function bind(that /* , ...args */) { var F = aCallable$2(this); var Prototype = F.prototype; var partArgs = arraySlice$2(arguments, 1); @@ -7056,7 +7249,7 @@ var anObject$4 = anObject$n; var isObject$a = isObject$s; var create$4 = objectCreate; - var fails$m = fails$S; + var fails$m = fails$V; var nativeConstruct = getBuiltIn$1('Reflect', 'construct'); var ObjectPrototype = Object.prototype; @@ -7112,7 +7305,7 @@ }; var $$P = _export; - var call$6 = functionCall; + var call$5 = functionCall; var isObject$9 = isObject$s; var anObject$3 = anObject$n; var isDataDescriptor = isDataDescriptor$1; @@ -7128,7 +7321,7 @@ descriptor = getOwnPropertyDescriptorModule.f(target, propertyKey); if (descriptor) return isDataDescriptor(descriptor) ? descriptor.value - : descriptor.get === undefined ? undefined : call$6(descriptor.get, receiver); + : descriptor.get === undefined ? undefined : call$5(descriptor.get, receiver); if (isObject$9(prototype = getPrototypeOf(target))) return get$3(prototype, propertyKey, receiver); } @@ -7137,8 +7330,8 @@ }); var $$O = _export; - var fails$l = fails$S; - var toIndexedObject$1 = toIndexedObject$c; + var fails$l = fails$V; + var toIndexedObject$1 = toIndexedObject$d; var nativeGetOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f; var DESCRIPTORS$8 = descriptors; @@ -7154,13 +7347,13 @@ }); var $$N = _export; - var global$i = global$1m; - var toAbsoluteIndex$1 = toAbsoluteIndex$8; + var global$i = global$1o; + var toAbsoluteIndex$1 = toAbsoluteIndex$9; var toIntegerOrInfinity$2 = toIntegerOrInfinity$b; - var lengthOfArrayLike$5 = lengthOfArrayLike$g; - var toObject$7 = toObject$j; + var lengthOfArrayLike$5 = lengthOfArrayLike$i; + var toObject$7 = toObject$i; var arraySpeciesCreate$2 = arraySpeciesCreate$4; - var createProperty$2 = createProperty$4; + var createProperty$2 = createProperty$5; var arrayMethodHasSpeciesSupport$2 = arrayMethodHasSpeciesSupport$5; var HAS_SPECIES_SUPPORT$1 = arrayMethodHasSpeciesSupport$2('splice'); @@ -7229,7 +7422,7 @@ // https://tc39.es/ecma262/#sec-symbol.tostringtag defineWellKnownSymbol$1('toStringTag'); - var global$h = global$1m; + var global$h = global$1o; var setToStringTag$3 = setToStringTag$a; // JSON[@@toStringTag] property @@ -7761,13 +7954,13 @@ } var $$M = _export; - var global$g = global$1m; - var fails$k = fails$S; + var global$g = global$1o; + var fails$k = fails$V; var isArray$3 = isArray$8; var isObject$8 = isObject$s; - var toObject$6 = toObject$j; - var lengthOfArrayLike$4 = lengthOfArrayLike$g; - var createProperty$1 = createProperty$4; + var toObject$6 = toObject$i; + var lengthOfArrayLike$4 = lengthOfArrayLike$i; + var createProperty$1 = createProperty$5; var arraySpeciesCreate$1 = arraySpeciesCreate$4; var arrayMethodHasSpeciesSupport$1 = arrayMethodHasSpeciesSupport$5; var wellKnownSymbol$2 = wellKnownSymbol$t; @@ -7825,12 +8018,12 @@ var DESCRIPTORS$7 = descriptors; var uncurryThis$l = functionUncurryThis; - var call$5 = functionCall; - var fails$j = fails$S; + var call$4 = functionCall; + var fails$j = fails$V; var objectKeys$1 = objectKeys$4; var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols; var propertyIsEnumerableModule = objectPropertyIsEnumerable; - var toObject$5 = toObject$j; + var toObject$5 = toObject$i; var IndexedObject = indexedObject; // eslint-disable-next-line es/no-object-assign -- safe @@ -7875,7 +8068,7 @@ var key; while (length > j) { key = keys[j++]; - if (!DESCRIPTORS$7 || call$5(propertyIsEnumerable, S, key)) T[key] = S[key]; + if (!DESCRIPTORS$7 || call$4(propertyIsEnumerable, S, key)) T[key] = S[key]; } } return T; } : $assign; @@ -7906,9 +8099,9 @@ }); var $$J = _export; - var toObject$4 = toObject$j; + var toObject$4 = toObject$i; var nativeKeys = objectKeys$4; - var fails$i = fails$S; + var fails$i = fails$V; var FAILS_ON_PRIMITIVES$2 = fails$i(function () { nativeKeys(1); }); @@ -7939,8 +8132,8 @@ } }); - var global$f = global$1m; - var fails$h = fails$S; + var global$f = global$1o; + var fails$h = fails$V; var uncurryThis$j = functionUncurryThis; var toString$c = toString$k; var trim$4 = stringTrim.trim; @@ -8378,8 +8571,8 @@ tidal_channel: true }; - var global$e = global$1m; - var fails$g = fails$S; + var global$e = global$1o; + var fails$g = fails$V; var uncurryThis$i = functionUncurryThis; var toString$b = toString$k; var trim$3 = stringTrim.trim; @@ -8413,7 +8606,7 @@ var internalMetadata = {exports: {}}; // FF26- bug: ArrayBuffers are non-extensible, but Object.isExtensible does not report it - var fails$f = fails$S; + var fails$f = fails$V; var arrayBufferNonExtensible = fails$f(function () { if (typeof ArrayBuffer == 'function') { @@ -8423,7 +8616,7 @@ } }); - var fails$e = fails$S; + var fails$e = fails$V; var isObject$7 = isObject$s; var classof = classofRaw$1; var ARRAY_BUFFER_NON_EXTENSIBLE = arrayBufferNonExtensible; @@ -8440,7 +8633,7 @@ return $isExtensible ? $isExtensible(it) : true; } : $isExtensible; - var fails$d = fails$S; + var fails$d = fails$V; var freezing = !fails$d(function () { // eslint-disable-next-line es/no-object-isextensible, es/no-object-preventextensions -- required for testing @@ -8538,7 +8731,7 @@ hiddenKeys[METADATA] = true; var $$E = _export; - var global$d = global$1m; + var global$d = global$1o; var uncurryThis$g = functionUncurryThis; var isForced$2 = isForced_1; var redefine$4 = redefine$h.exports; @@ -8547,7 +8740,7 @@ var anInstance$2 = anInstance$7; var isCallable$1 = isCallable$r; var isObject$5 = isObject$s; - var fails$c = fails$S; + var fails$c = fails$V; var checkCorrectnessOfIteration$1 = checkCorrectnessOfIteration$4; var setToStringTag$1 = setToStringTag$a; var inheritIfRequired$2 = inheritIfRequired$4; @@ -9773,15 +9966,15 @@ } }; - var global$c = global$1m; + var global$c = global$1o; var bind$5 = functionBindContext; - var call$4 = functionCall; - var toObject$3 = toObject$j; + var call$3 = functionCall; + var toObject$3 = toObject$i; var callWithSafeIterationClosing = callWithSafeIterationClosing$1; var isArrayIteratorMethod = isArrayIteratorMethod$3; var isConstructor = isConstructor$4; - var lengthOfArrayLike$3 = lengthOfArrayLike$g; - var createProperty = createProperty$4; + var lengthOfArrayLike$3 = lengthOfArrayLike$i; + var createProperty = createProperty$5; var getIterator = getIterator$4; var getIteratorMethod = getIteratorMethod$5; @@ -9804,7 +9997,7 @@ iterator = getIterator(O, iteratorMethod); next = iterator.next; result = IS_CONSTRUCTOR ? new this() : []; - for (;!(step = call$4(next, iterator)).done; index++) { + for (;!(step = call$3(next, iterator)).done; index++) { value = mapping ? callWithSafeIterationClosing(iterator, mapfn, [step.value, index], true) : step.value; createProperty(result, index, value); } @@ -9948,11 +10141,12 @@ var $$A = _export; var DESCRIPTORS$5 = descriptors; - var defineProperties$1 = objectDefineProperties; + var defineProperties$1 = objectDefineProperties.f; // `Object.defineProperties` method // https://tc39.es/ecma262/#sec-object.defineproperties - $$A({ target: 'Object', stat: true, forced: !DESCRIPTORS$5, sham: !DESCRIPTORS$5 }, { + // eslint-disable-next-line es/no-object-defineproperties -- safe + $$A({ target: 'Object', stat: true, forced: Object.defineProperties !== defineProperties$1, sham: !DESCRIPTORS$5 }, { defineProperties: defineProperties$1 }); @@ -9968,10 +10162,10 @@ var $$z = _export; var uncurryThis$f = functionUncurryThis; var aCallable$1 = aCallable$a; - var toObject$2 = toObject$j; - var lengthOfArrayLike$2 = lengthOfArrayLike$g; + var toObject$2 = toObject$i; + var lengthOfArrayLike$2 = lengthOfArrayLike$i; var toString$a = toString$k; - var fails$b = fails$S; + var fails$b = fails$V; var internalSort = arraySort$1; var arrayMethodIsStrict$3 = arrayMethodIsStrict$9; var FF = engineFfVersion; @@ -14892,7 +15086,7 @@ } var DESCRIPTORS$4 = descriptors; - var global$b = global$1m; + var global$b = global$1o; var uncurryThis$e = functionUncurryThis; var isForced$1 = isForced_1; var inheritIfRequired$1 = inheritIfRequired$4; @@ -14905,7 +15099,7 @@ var regExpFlags$1 = regexpFlags$1; var stickyHelpers = regexpStickyHelpers; var redefine$3 = redefine$h.exports; - var fails$a = fails$S; + var fails$a = fails$V; var hasOwn$2 = hasOwnProperty_1; var enforceInternalState = internalState.enforce; var setSpecies = setSpecies$5; @@ -14931,10 +15125,11 @@ // "new" should create a new object, old webkit bug var CORRECT_NEW = new NativeRegExp(re1) !== re1; + var MISSED_STICKY = stickyHelpers.MISSED_STICKY; var UNSUPPORTED_Y = stickyHelpers.UNSUPPORTED_Y; var BASE_FORCED = DESCRIPTORS$4 && - (!CORRECT_NEW || UNSUPPORTED_Y || UNSUPPORTED_DOT_ALL || UNSUPPORTED_NCG || fails$a(function () { + (!CORRECT_NEW || MISSED_STICKY || UNSUPPORTED_DOT_ALL || UNSUPPORTED_NCG || fails$a(function () { re2[MATCH$1] = false; // RegExp constructor can alter flags and IsRegExp works correct with @@match return NativeRegExp(re1) != re1 || NativeRegExp(re2) == re2 || NativeRegExp(re1, 'i') != '/a/i'; @@ -15039,9 +15234,9 @@ rawFlags = flags; - if (UNSUPPORTED_Y && 'sticky' in re1) { + if (MISSED_STICKY && 'sticky' in re1) { sticky = !!flags && stringIndexOf$1(flags, 'y') > -1; - if (sticky) flags = replace$3(flags, /y/g, ''); + if (sticky && UNSUPPORTED_Y) flags = replace$3(flags, /y/g, ''); } if (UNSUPPORTED_NCG) { @@ -15873,7 +16068,7 @@ // `Function.prototype.bind` method // https://tc39.es/ecma262/#sec-function.prototype.bind - $$t({ target: 'Function', proto: true }, { + $$t({ target: 'Function', proto: true, forced: Function.bind !== bind$4 }, { bind: bind$4 }); @@ -17547,7 +17742,7 @@ return score; } - var call$3 = functionCall; + var call$2 = functionCall; var fixRegExpWellKnownSymbolLogic$1 = fixRegexpWellKnownSymbolLogic; var anObject$1 = anObject$n; var toLength$3 = toLength$c; @@ -17565,7 +17760,7 @@ function match(regexp) { var O = requireObjectCoercible$7(this); var matcher = regexp == undefined ? undefined : getMethod$1(regexp, MATCH); - return matcher ? call$3(matcher, regexp, O) : new RegExp(regexp)[MATCH](toString$8(O)); + return matcher ? call$2(matcher, regexp, O) : new RegExp(regexp)[MATCH](toString$8(O)); }, // `RegExp.prototype[@@match]` method // https://tc39.es/ecma262/#sec-regexp.prototype-@@match @@ -17596,7 +17791,7 @@ var $$s = _export; var FREEZING = freezing; - var fails$9 = fails$S; + var fails$9 = fails$V; var isObject$4 = isObject$s; var onFreeze = internalMetadata.exports.onFreeze; @@ -17763,7 +17958,7 @@ var thisNumberValue$3 = uncurryThis$d(1.0.valueOf); var DESCRIPTORS$3 = descriptors; - var global$a = global$1m; + var global$a = global$1o; var uncurryThis$c = functionUncurryThis; var isForced = isForced_1; var redefine$2 = redefine$h.exports; @@ -17772,7 +17967,7 @@ var isPrototypeOf = objectIsPrototypeOf; var isSymbol$1 = isSymbol$6; var toPrimitive$1 = toPrimitive$3; - var fails$8 = fails$S; + var fails$8 = fails$V; var getOwnPropertyNames = objectGetOwnPropertyNames.f; var getOwnPropertyDescriptor$2 = objectGetOwnPropertyDescriptor.f; var defineProperty = objectDefineProperty.f; @@ -20407,7 +20602,7 @@ var DESCRIPTORS$2 = descriptors; var uncurryThis$b = functionUncurryThis; var objectKeys = objectKeys$4; - var toIndexedObject = toIndexedObject$c; + var toIndexedObject = toIndexedObject$d; var $propertyIsEnumerable = objectPropertyIsEnumerable.f; var propertyIsEnumerable = uncurryThis$b($propertyIsEnumerable); @@ -20564,7 +20759,7 @@ var parseVersion = vparse.exports; var name = "iD"; - var version = "2.20.3"; + var version = "2.20.4"; var description = "A friendly editor for OpenStreetMap"; var main = "dist/iD.min.js"; var repository = "github:openstreetmap/iD"; @@ -20709,7 +20904,7 @@ return _this; } - var global$9 = global$1m; + var global$9 = global$1o; var toIntegerOrInfinity$1 = toIntegerOrInfinity$b; var toString$7 = toString$k; var requireObjectCoercible$6 = requireObjectCoercible$e; @@ -20728,12 +20923,12 @@ }; var $$q = _export; - var global$8 = global$1m; + var global$8 = global$1o; var uncurryThis$a = functionUncurryThis; var toIntegerOrInfinity = toIntegerOrInfinity$b; var thisNumberValue$1 = thisNumberValue$3; var $repeat$1 = stringRepeat; - var fails$7 = fails$S; + var fails$7 = fails$V; var RangeError$4 = global$8.RangeError; var String$1 = global$8.String; @@ -20811,6 +21006,7 @@ var result = '0'; var e, z, j, k; + // TODO: ES2018 increased the maximum number of fraction digits to 100, need to improve the implementation if (fractDigits < 0 || fractDigits > 20) throw RangeError$4('Incorrect fraction digits'); // eslint-disable-next-line no-self-compare -- NaN check if (number != number) return 'NaN'; @@ -20858,7 +21054,7 @@ } }); - var global$7 = global$1m; + var global$7 = global$1o; var globalIsFinite = global$7.isFinite; @@ -20877,9 +21073,9 @@ $$p({ target: 'Number', stat: true }, { isFinite: numberIsFinite }); var $$o = _export; - var global$6 = global$1m; + var global$6 = global$1o; var uncurryThis$9 = functionUncurryThis; - var toAbsoluteIndex = toAbsoluteIndex$8; + var toAbsoluteIndex = toAbsoluteIndex$9; var RangeError$3 = global$6.RangeError; var fromCharCode$1 = String.fromCharCode; @@ -20909,7 +21105,7 @@ } }); - var call$2 = functionCall; + var call$1 = functionCall; var fixRegExpWellKnownSymbolLogic = fixRegexpWellKnownSymbolLogic; var anObject = anObject$n; var requireObjectCoercible$5 = requireObjectCoercible$e; @@ -20926,7 +21122,7 @@ function search(regexp) { var O = requireObjectCoercible$5(this); var searcher = regexp == undefined ? undefined : getMethod(regexp, SEARCH); - return searcher ? call$2(searcher, regexp, O) : new RegExp(regexp)[SEARCH](toString$6(O)); + return searcher ? call$1(searcher, regexp, O) : new RegExp(regexp)[SEARCH](toString$6(O)); }, // `RegExp.prototype[@@search]` method // https://tc39.es/ecma262/#sec-regexp.prototype-@@search @@ -28180,7 +28376,7 @@ return p1 + '>' + S + ''; }; - var fails$6 = fails$S; + var fails$6 = fails$V; // check the existence of a method, lowercase // of a tag and escaping quotes in arguments @@ -30874,8 +31070,8 @@ var precision = geojsonPrecision.exports; var $$k = _export; - var fails$5 = fails$S; - var toObject$1 = toObject$j; + var fails$5 = fails$V; + var toObject$1 = toObject$i; var toPrimitive = toPrimitive$3; var FORCED$5 = fails$5(function () { @@ -30895,13 +31091,13 @@ }); var $$j = _export; - var call$1 = functionCall; + var call = functionCall; // `URL.prototype.toJSON` method // https://url.spec.whatwg.org/#dom-url-tojson $$j({ target: 'URL', proto: true, enumerable: true }, { toJSON: function toJSON() { - return call$1(URL.prototype.toString, this); + return call(URL.prototype.toString, this); } }); @@ -33525,7 +33721,7 @@ // https://tc39.es/ecma262/#sec-array.prototype-@@unscopables addToUnscopables$1(FIND_INDEX); - var global$5 = global$1m; + var global$5 = global$1o; var isRegExp = isRegexp; var TypeError$3 = global$5.TypeError; @@ -34322,9 +34518,57 @@ lastIndexOf: lastIndexOf }); - var global$4 = global$1m; + /** Used to map HTML entities to characters. */ + + var htmlUnescapes = { + '&': '&', + '<': '<', + '>': '>', + '"': '"', + ''': "'" + }; + /** + * Used by `_.unescape` to convert HTML entities to characters. + * + * @private + * @param {string} chr The matched character to unescape. + * @returns {string} Returns the unescaped character. + */ + + var unescapeHtmlChar = basePropertyOf(htmlUnescapes); + + /** Used to match HTML entities and HTML characters. */ + + var reEscapedHtml = /&(?:amp|lt|gt|quot|#39);/g, + reHasEscapedHtml = RegExp(reEscapedHtml.source); + /** + * The inverse of `_.escape`; this method converts the HTML entities + * `&`, `<`, `>`, `"`, and `'` in `string` to + * their corresponding characters. + * + * **Note:** No other HTML entities are unescaped. To unescape additional + * HTML entities use a third-party library like [_he_](https://mths.be/he). + * + * @static + * @memberOf _ + * @since 0.6.0 + * @category String + * @param {string} [string=''] The string to unescape. + * @returns {string} Returns the unescaped string. + * @example + * + * _.unescape('fred, barney, & pebbles'); + * // => 'fred, barney, & pebbles' + */ + + function unescape$3(string) { + string = toString$3(string); + return string && reHasEscapedHtml.test(string) ? string.replace(reEscapedHtml, unescapeHtmlChar) : string; + } + + var global$4 = global$1o; var isArray = isArray$8; - var lengthOfArrayLike$1 = lengthOfArrayLike$g; + var lengthOfArrayLike$1 = lengthOfArrayLike$i; var bind$3 = functionBindContext; var TypeError$2 = global$4.TypeError; @@ -34361,8 +34605,8 @@ var $$e = _export; var flattenIntoArray = flattenIntoArray_1; var aCallable = aCallable$a; - var toObject = toObject$j; - var lengthOfArrayLike = lengthOfArrayLike$g; + var toObject = toObject$i; + var lengthOfArrayLike = lengthOfArrayLike$i; var arraySpeciesCreate = arraySpeciesCreate$4; // `Array.prototype.flatMap` method @@ -42087,7 +42331,7 @@ var DESCRIPTORS$1 = descriptors; var objectDefinePropertyModule = objectDefineProperty; var regExpFlags = regexpFlags$1; - var fails$4 = fails$S; + var fails$4 = fails$V; var RegExpPrototype = RegExp.prototype; @@ -62584,7 +62828,7 @@ var $$5 = _export; var uncurryThis$3 = functionUncurryThis; - var fails$3 = fails$S; + var fails$3 = fails$V; var thisNumberValue = thisNumberValue$3; var un$ToPrecision = uncurryThis$3(1.0.toPrecision); @@ -62995,9 +63239,9 @@ return initRange.apply(linearish(scale), arguments); } - var global$3 = global$1m; + var global$3 = global$1o; var uncurryThis$2 = functionUncurryThis; - var fails$2 = fails$S; + var fails$2 = fails$V; var padStart = stringPad.start; var RangeError$2 = global$3.RangeError; @@ -64820,7 +65064,7 @@ var $$3 = _export; var NativePromise = nativePromiseConstructor; - var fails$1 = fails$S; + var fails$1 = fails$V; var getBuiltIn = getBuiltIn$b; var isCallable = isCallable$r; var speciesConstructor = speciesConstructor$5; @@ -64829,6 +65073,7 @@ // Safari bug https://bugs.webkit.org/show_bug.cgi?id=200829 var NON_GENERIC = !!NativePromise && fails$1(function () { + // eslint-disable-next-line unicorn/no-thenable -- required for testing NativePromise.prototype['finally'].call({ then: function () { /* empty */ } }, function () { /* empty */ }); }); @@ -65523,7 +65768,6 @@ function tokenReplacements(d) { if (!(d instanceof QAItem)) return; - var htmlRegex = new RegExp(/<\/[a-z][\s\S]*>/); var replacements = {}; var issueTemplate = _krData.errorTypes[d.whichType]; @@ -65561,15 +65805,14 @@ if (idType && capture) { // link IDs if present in the capture capture = parseError(capture, idType); - } else if (htmlRegex.test(capture)) { - // escape any html in non-IDs - capture = '\\' + capture + '\\'; } else { var compare = capture.toLowerCase(); if (_krData.localizeStrings[compare]) { // some replacement strings can be localized capture = _t('QA.keepRight.error_parts.' + _krData.localizeStrings[compare]); + } else { + capture = unescape$3(capture); } } @@ -65629,15 +65872,21 @@ return capture; function linkErrorObject(d) { - return "".concat(d, ""); + return { + html: "".concat(d, "") + }; } function linkEntity(d) { - return "".concat(d, ""); + return { + html: "".concat(d, "") + }; } function linkURL(d) { - return "").concat(d, ""); + return { + html: "").concat(d, "") + }; } // arbitrary node list of form: #ID, #ID, #ID... @@ -66021,11 +66270,15 @@ } function linkErrorObject(d) { - return "".concat(d, ""); + return { + html: "".concat(d, "") + }; } function linkEntity(d) { - return "".concat(d, ""); + return { + html: "".concat(d, "") + }; } function pointAverage(points) { @@ -72177,7 +72430,7 @@ .replace(/[\s\-=_!"#%'*{},.\/:;?\(\)\[\]@\\$\^*+<>«»~`’\u00a1\u00a7\u00b6\u00b7\u00bf\u037e\u0387\u055a-\u055f\u0589\u05c0\u05c3\u05c6\u05f3\u05f4\u0609\u060a\u060c\u060d\u061b\u061e\u061f\u066a-\u066d\u06d4\u0700-\u070d\u07f7-\u07f9\u0830-\u083e\u085e\u0964\u0965\u0970\u0af0\u0df4\u0e4f\u0e5a\u0e5b\u0f04-\u0f12\u0f14\u0f85\u0fd0-\u0fd4\u0fd9\u0fda\u104a-\u104f\u10fb\u1360-\u1368\u166d\u166e\u16eb-\u16ed\u1735\u1736\u17d4-\u17d6\u17d8-\u17da\u1800-\u1805\u1807-\u180a\u1944\u1945\u1a1e\u1a1f\u1aa0-\u1aa6\u1aa8-\u1aad\u1b5a-\u1b60\u1bfc-\u1bff\u1c3b-\u1c3f\u1c7e\u1c7f\u1cc0-\u1cc7\u1cd3\u2000-\u206f\u2cf9-\u2cfc\u2cfe\u2cff\u2d70\u2e00-\u2e7f\u3001-\u3003\u303d\u30fb\ua4fe\ua4ff\ua60d-\ua60f\ua673\ua67e\ua6f2-\ua6f7\ua874-\ua877\ua8ce\ua8cf\ua8f8-\ua8fa\ua92e\ua92f\ua95f\ua9c1-\ua9cd\ua9de\ua9df\uaa5c-\uaa5f\uaade\uaadf\uaaf0\uaaf1\uabeb\ufe10-\ufe16\ufe19\ufe30\ufe45\ufe46\ufe49-\ufe4c\ufe50-\ufe52\ufe54-\ufe57\ufe5f-\ufe61\ufe68\ufe6a\ufe6b\ufeff\uff01-\uff03\uff05-\uff07\uff0a\uff0c\uff0e\uff0f\uff1a\uff1b\uff1f\uff20\uff3c\uff61\uff64\uff65]+/g, '').toLowerCase()); } - var matchGroups$1 = {adult_gaming_centre:["amenity/casino","amenity/gambling","leisure/adult_gaming_centre"],beauty:["shop/beauty","shop/hairdresser_supply"],bed:["shop/bed","shop/furniture"],beverages:["shop/alcohol","shop/beer","shop/beverages","shop/wine"],camping:["leisure/park","tourism/camp_site","tourism/caravan_site"],car_parts:["shop/car_parts","shop/car_repair","shop/tires","shop/tyres"],clinic:["amenity/clinic","amenity/doctors","healthcare/clinic","healthcare/dialysis"],confectionery:["shop/candy","shop/chocolate","shop/confectionery"],convenience:["shop/beauty","shop/chemist","shop/convenience","shop/cosmetics","shop/grocery","shop/newsagent","shop/perfumery"],coworking:["amenity/coworking_space","office/coworking","office/coworking_space"],dentist:["amenity/dentist","amenity/doctors","healthcare/dentist"],electronics:["office/telecommunication","shop/computer","shop/electronics","shop/hifi","shop/mobile","shop/mobile_phone","shop/telecommunication"],fabric:["shop/fabric","shop/haberdashery","shop/sewing"],fashion:["shop/accessories","shop/bag","shop/botique","shop/clothes","shop/department_store","shop/fashion","shop/fashion_accessories","shop/sports","shop/shoes"],financial:["amenity/bank","office/accountant","office/financial","office/financial_advisor","office/tax_advisor","shop/tax"],fitness:["leisure/fitness_centre","leisure/fitness_center","leisure/sports_centre","leisure/sports_center"],food:["amenity/pub","amenity/bar","amenity/cafe","amenity/fast_food","amenity/ice_cream","amenity/restaurant","shop/bakery","shop/ice_cream","shop/pastry","shop/tea","shop/coffee"],fuel:["amenity/fuel","shop/gas","shop/convenience;gas","shop/gas;convenience"],gift:["shop/gift","shop/card","shop/cards","shop/stationery"],hardware:["shop/bathroom_furnishing","shop/carpet","shop/diy","shop/doityourself","shop/doors","shop/electrical","shop/flooring","shop/hardware","shop/hardware_store","shop/power_tools","shop/tool_hire","shop/tools","shop/trade"],health_food:["shop/health","shop/health_food","shop/herbalist","shop/nutrition_supplements"],hobby:["shop/electronics","shop/hobby","shop/books","shop/games","shop/collector","shop/toys","shop/model","shop/video_games","shop/anime"],hospital:["amenity/doctors","amenity/hospital","healthcare/hospital"],houseware:["shop/houseware","shop/interior_decoration"],lifeboat_station:["amenity/lifeboat_station","emergency/lifeboat_station","emergency/marine_rescue"],lodging:["tourism/hotel","tourism/motel"],money_transfer:["amenity/money_transfer","shop/money_transfer"],office_supplies:["shop/office_supplies","shop/stationary","shop/stationery"],outdoor:["shop/outdoor","shop/sports"],pharmacy:["amenity/doctors","amenity/pharmacy","healthcare/pharmacy"],playground:["amenity/theme_park","leisure/amusement_arcade","leisure/playground"],rental:["amenity/bicycle_rental","amenity/boat_rental","amenity/car_rental","amenity/truck_rental","amenity/vehicle_rental","shop/rental"],school:["amenity/childcare","amenity/college","amenity/kindergarten","amenity/language_school","amenity/prep_school","amenity/school","amenity/university"],storage:["shop/storage_units","shop/storage_rental"],substation:["power/station","power/substation","power/sub_station"],supermarket:["shop/food","shop/frozen_food","shop/greengrocer","shop/grocery","shop/supermarket","shop/wholesale"],variety_store:["shop/variety_store","shop/discount","shop/convenience"],vending:["amenity/vending_machine","shop/vending_machine"],weight_loss:["amenity/doctors","amenity/weight_clinic","healthcare/counselling","leisure/fitness_centre","office/therapist","shop/beauty","shop/diet","shop/food","shop/health_food","shop/herbalist","shop/nutrition","shop/nutrition_supplements","shop/weight_loss"],wholesale:["shop/wholesale","shop/supermarket","shop/department_store"]}; + var matchGroups$1 = {adult_gaming_centre:["amenity/casino","amenity/gambling","leisure/adult_gaming_centre"],beauty:["shop/beauty","shop/hairdresser_supply"],bed:["shop/bed","shop/furniture"],beverages:["shop/alcohol","shop/beer","shop/beverages","shop/wine"],camping:["leisure/park","tourism/camp_site","tourism/caravan_site"],car_parts:["shop/car_parts","shop/car_repair","shop/tires","shop/tyres"],clinic:["amenity/clinic","amenity/doctors","healthcare/clinic","healthcare/laboratory","healthcare/physiotherapist","healthcare/sample_collection","healthcare/dialysis"],confectionery:["shop/candy","shop/chocolate","shop/confectionery"],convenience:["shop/beauty","shop/chemist","shop/convenience","shop/cosmetics","shop/grocery","shop/newsagent","shop/perfumery"],coworking:["amenity/coworking_space","office/coworking","office/coworking_space"],dentist:["amenity/dentist","amenity/doctors","healthcare/dentist"],electronics:["office/telecommunication","shop/computer","shop/electronics","shop/hifi","shop/mobile","shop/mobile_phone","shop/telecommunication"],fabric:["shop/fabric","shop/haberdashery","shop/sewing"],fashion:["shop/accessories","shop/bag","shop/boutique","shop/clothes","shop/department_store","shop/fashion","shop/fashion_accessories","shop/sports","shop/shoes"],financial:["amenity/bank","office/accountant","office/financial","office/financial_advisor","office/tax_advisor","shop/tax"],fitness:["leisure/fitness_centre","leisure/fitness_center","leisure/sports_centre","leisure/sports_center"],food:["amenity/pub","amenity/bar","amenity/cafe","amenity/fast_food","amenity/ice_cream","amenity/restaurant","shop/bakery","shop/ice_cream","shop/pastry","shop/tea","shop/coffee"],fuel:["amenity/fuel","shop/gas","shop/convenience;gas","shop/gas;convenience"],gift:["shop/gift","shop/card","shop/cards","shop/stationery"],hardware:["shop/bathroom_furnishing","shop/carpet","shop/diy","shop/doityourself","shop/doors","shop/electrical","shop/flooring","shop/hardware","shop/hardware_store","shop/power_tools","shop/tool_hire","shop/tools","shop/trade"],health_food:["shop/health","shop/health_food","shop/herbalist","shop/nutrition_supplements"],hobby:["shop/electronics","shop/hobby","shop/books","shop/games","shop/collector","shop/toys","shop/model","shop/video_games","shop/anime"],hospital:["amenity/doctors","amenity/hospital","healthcare/hospital"],houseware:["shop/houseware","shop/interior_decoration"],lifeboat_station:["amenity/lifeboat_station","emergency/lifeboat_station","emergency/marine_rescue"],lodging:["tourism/hotel","tourism/motel"],money_transfer:["amenity/money_transfer","shop/money_transfer"],office_supplies:["shop/office_supplies","shop/stationary","shop/stationery"],outdoor:["shop/outdoor","shop/sports"],parcel_locker:["amenity/parcel_locker","amenity/vending_machine"],pharmacy:["amenity/doctors","amenity/pharmacy","healthcare/pharmacy"],playground:["amenity/theme_park","leisure/amusement_arcade","leisure/playground"],rental:["amenity/bicycle_rental","amenity/boat_rental","amenity/car_rental","amenity/truck_rental","amenity/vehicle_rental","shop/rental"],school:["amenity/childcare","amenity/college","amenity/kindergarten","amenity/language_school","amenity/prep_school","amenity/school","amenity/university"],storage:["shop/storage_units","shop/storage_rental"],substation:["power/station","power/substation","power/sub_station"],supermarket:["shop/food","shop/frozen_food","shop/greengrocer","shop/grocery","shop/supermarket","shop/wholesale"],variety_store:["shop/variety_store","shop/discount","shop/convenience"],vending:["amenity/vending_machine","shop/vending_machine"],weight_loss:["amenity/clinic","amenity/doctors","amenity/weight_clinic","healthcare/counselling","leisure/fitness_centre","office/therapist","shop/beauty","shop/diet","shop/food","shop/health_food","shop/herbalist","shop/nutrition","shop/nutrition_supplements","shop/weight_loss"],wholesale:["shop/wholesale","shop/supermarket","shop/department_store"]}; var matchGroupsJSON = { matchGroups: matchGroups$1 }; @@ -78785,7 +79038,7 @@ } var $$2 = _export; - var fails = fails$S; + var fails = fails$V; var expm1 = mathExpm1; var abs = Math.abs; @@ -96716,7 +96969,7 @@ } // based on https://github.com/bestiejs/punycode.js/blob/master/punycode.js - var global$2 = global$1m; + var global$2 = global$1o; var uncurryThis$1 = functionUncurryThis; var maxInt = 2147483647; // aka. 0x7FFFFFFF or 2^31-1 @@ -96792,8 +97045,9 @@ var k = 0; delta = firstTime ? floor$1(delta / damp) : delta >> 1; delta += floor$1(delta / numPoints); - for (; delta > baseMinusTMin * tMax >> 1; k += base) { + while (delta > baseMinusTMin * tMax >> 1) { delta = floor$1(delta / baseMinusTMin); + k += base; } return floor$1(k + (baseMinusTMin + 1) * delta / (delta + skew)); }; @@ -96802,7 +97056,6 @@ * Converts a string of Unicode symbols (e.g. a domain name label) to a * Punycode string of ASCII-only symbols. */ - // eslint-disable-next-line max-statements -- TODO var encode = function (input) { var output = []; @@ -96862,24 +97115,26 @@ if (currentValue == n) { // Represent delta as a generalized variable-length integer. var q = delta; - for (var k = base; /* no condition */; k += base) { + var k = base; + while (true) { var t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias); if (q < t) break; var qMinusT = q - t; var baseMinusT = base - t; push$1(output, fromCharCode(digitToBasic(t + qMinusT % baseMinusT))); q = floor$1(qMinusT / baseMinusT); + k += base; } push$1(output, fromCharCode(digitToBasic(q))); bias = adapt(delta, handledCPCountPlusOne, handledCPCount == basicLength); delta = 0; - ++handledCPCount; + handledCPCount++; } } - ++delta; - ++n; + delta++; + n++; } return join$1(output, ''); }; @@ -96900,21 +97155,21 @@ var $ = _export; var DESCRIPTORS = descriptors; var USE_NATIVE_URL = nativeUrl; - var global$1 = global$1m; + var global$1 = global$1o; var bind$2 = functionBindContext; - var call = functionCall; var uncurryThis = functionUncurryThis; - var defineProperties = objectDefineProperties; + var defineProperties = objectDefineProperties.f; var redefine = redefine$h.exports; var anInstance = anInstance$7; var hasOwn = hasOwnProperty_1; var assign$1 = objectAssign; var arrayFrom = arrayFrom$1; - var arraySlice = arraySlice$c; + var arraySlice = arraySliceSimple; var codeAt = stringMultibyte.codeAt; var toASCII = stringPunycodeToAscii; var $toString = toString$k; var setToStringTag = setToStringTag$a; + var validateArgumentsLength = validateArgumentsLength$4; var URLSearchParamsModule = web_urlSearchParams; var InternalStateModule = internalState; @@ -96962,31 +97217,7 @@ /* eslint-enable regexp/no-control-character -- safe */ var EOF; - var parseHost = function (url, input) { - var result, codePoints, index; - if (charAt(input, 0) == '[') { - if (charAt(input, input.length - 1) != ']') return INVALID_HOST; - result = parseIPv6(stringSlice(input, 1, -1)); - if (!result) return INVALID_HOST; - url.host = result; - // opaque host - } else if (!isSpecial(url)) { - if (exec(FORBIDDEN_HOST_CODE_POINT_EXCLUDING_PERCENT, input)) return INVALID_HOST; - result = ''; - codePoints = arrayFrom(input); - for (index = 0; index < codePoints.length; index++) { - result += percentEncode(codePoints[index], C0ControlPercentEncodeSet); - } - url.host = result; - } else { - input = toASCII(input); - if (exec(FORBIDDEN_HOST_CODE_POINT, input)) return INVALID_HOST; - result = parseIPv4(input); - if (result === null) return INVALID_HOST; - url.host = result; - } - }; - + // https://url.spec.whatwg.org/#ipv4-number-parser var parseIPv4 = function (input) { var parts = split(input, '.'); var partsLength, numbers, index, part, radix, number, ipv4; @@ -97025,6 +97256,7 @@ return ipv4; }; + // https://url.spec.whatwg.org/#concept-ipv6-parser // eslint-disable-next-line max-statements -- TODO var parseIPv6 = function (input) { var address = [0, 0, 0, 0, 0, 0, 0, 0]; @@ -97128,6 +97360,7 @@ return maxIndex; }; + // https://url.spec.whatwg.org/#host-serializing var serializeHost = function (host) { var result, index, compress, ignore0; // ipv4 @@ -97172,6 +97405,7 @@ return code > 0x20 && code < 0x7F && !hasOwn(set, chr) ? chr : encodeURIComponent(chr); }; + // https://url.spec.whatwg.org/#special-scheme var specialSchemes = { ftp: 21, file: null, @@ -97181,24 +97415,14 @@ wss: 443 }; - var isSpecial = function (url) { - return hasOwn(specialSchemes, url.scheme); - }; - - var includesCredentials = function (url) { - return url.username != '' || url.password != ''; - }; - - var cannotHaveUsernamePasswordPort = function (url) { - return !url.host || url.cannotBeABaseURL || url.scheme == 'file'; - }; - + // https://url.spec.whatwg.org/#windows-drive-letter var isWindowsDriveLetter = function (string, normalized) { var second; return string.length == 2 && exec(ALPHA, charAt(string, 0)) && ((second = charAt(string, 1)) == ':' || (!normalized && second == '|')); }; + // https://url.spec.whatwg.org/#start-with-a-windows-drive-letter var startsWithWindowsDriveLetter = function (string) { var third; return string.length > 1 && isWindowsDriveLetter(stringSlice(string, 0, 2)) && ( @@ -97207,18 +97431,12 @@ ); }; - var shortenURLsPath = function (url) { - var path = url.path; - var pathSize = path.length; - if (pathSize && (url.scheme != 'file' || pathSize != 1 || !isWindowsDriveLetter(path[0], true))) { - path.length--; - } - }; - + // https://url.spec.whatwg.org/#single-dot-path-segment var isSingleDot = function (segment) { return segment === '.' || toLowerCase(segment) === '%2e'; }; + // https://url.spec.whatwg.org/#double-dot-path-segment var isDoubleDot = function (segment) { segment = toLowerCase(segment); return segment === '..' || segment === '%2e.' || segment === '.%2e' || segment === '%2e%2e'; @@ -97247,402 +97465,625 @@ var QUERY = {}; var FRAGMENT = {}; - // eslint-disable-next-line max-statements -- TODO - var parseURL = function (url, input, stateOverride, base) { - var state = stateOverride || SCHEME_START; - var pointer = 0; - var buffer = ''; - var seenAt = false; - var seenBracket = false; - var seenPasswordToken = false; - var codePoints, chr, bufferCodePoints, failure; - - if (!stateOverride) { - url.scheme = ''; - url.username = ''; - url.password = ''; - url.host = null; - url.port = null; - url.path = []; - url.query = null; - url.fragment = null; - url.cannotBeABaseURL = false; - input = replace(input, LEADING_AND_TRAILING_C0_CONTROL_OR_SPACE, ''); - } - - input = replace(input, TAB_AND_NEW_LINE, ''); - - codePoints = arrayFrom(input); - - while (pointer <= codePoints.length) { - chr = codePoints[pointer]; - switch (state) { - case SCHEME_START: - if (chr && exec(ALPHA, chr)) { - buffer += toLowerCase(chr); - state = SCHEME; - } else if (!stateOverride) { - state = NO_SCHEME; - continue; - } else return INVALID_SCHEME; - break; + var URLState = function (url, isBase, base) { + var urlString = $toString(url); + var baseState, failure, searchParams; + if (isBase) { + failure = this.parse(urlString); + if (failure) throw TypeError$1(failure); + this.searchParams = null; + } else { + if (base !== undefined) baseState = new URLState(base, true); + failure = this.parse(urlString, null, baseState); + if (failure) throw TypeError$1(failure); + searchParams = getInternalSearchParamsState(new URLSearchParams$1()); + searchParams.bindURL(this); + this.searchParams = searchParams; + } + }; - case SCHEME: - if (chr && (exec(ALPHANUMERIC, chr) || chr == '+' || chr == '-' || chr == '.')) { - buffer += toLowerCase(chr); - } else if (chr == ':') { - if (stateOverride && ( - (isSpecial(url) != hasOwn(specialSchemes, buffer)) || - (buffer == 'file' && (includesCredentials(url) || url.port !== null)) || - (url.scheme == 'file' && !url.host) - )) return; - url.scheme = buffer; - if (stateOverride) { - if (isSpecial(url) && specialSchemes[url.scheme] == url.port) url.port = null; - return; - } - buffer = ''; - if (url.scheme == 'file') { - state = FILE; - } else if (isSpecial(url) && base && base.scheme == url.scheme) { - state = SPECIAL_RELATIVE_OR_AUTHORITY; - } else if (isSpecial(url)) { - state = SPECIAL_AUTHORITY_SLASHES; - } else if (codePoints[pointer + 1] == '/') { - state = PATH_OR_AUTHORITY; - pointer++; - } else { - url.cannotBeABaseURL = true; - push(url.path, ''); - state = CANNOT_BE_A_BASE_URL_PATH; - } - } else if (!stateOverride) { - buffer = ''; - state = NO_SCHEME; - pointer = 0; - continue; - } else return INVALID_SCHEME; - break; + URLState.prototype = { + type: 'URL', + // https://url.spec.whatwg.org/#url-parsing + // eslint-disable-next-line max-statements -- TODO + parse: function (input, stateOverride, base) { + var url = this; + var state = stateOverride || SCHEME_START; + var pointer = 0; + var buffer = ''; + var seenAt = false; + var seenBracket = false; + var seenPasswordToken = false; + var codePoints, chr, bufferCodePoints, failure; + + input = $toString(input); + + if (!stateOverride) { + url.scheme = ''; + url.username = ''; + url.password = ''; + url.host = null; + url.port = null; + url.path = []; + url.query = null; + url.fragment = null; + url.cannotBeABaseURL = false; + input = replace(input, LEADING_AND_TRAILING_C0_CONTROL_OR_SPACE, ''); + } - case NO_SCHEME: - if (!base || (base.cannotBeABaseURL && chr != '#')) return INVALID_SCHEME; - if (base.cannotBeABaseURL && chr == '#') { - url.scheme = base.scheme; - url.path = arraySlice(base.path); - url.query = base.query; - url.fragment = ''; - url.cannotBeABaseURL = true; - state = FRAGMENT; - break; - } - state = base.scheme == 'file' ? FILE : RELATIVE; - continue; + input = replace(input, TAB_AND_NEW_LINE, ''); - case SPECIAL_RELATIVE_OR_AUTHORITY: - if (chr == '/' && codePoints[pointer + 1] == '/') { - state = SPECIAL_AUTHORITY_IGNORE_SLASHES; - pointer++; - } else { - state = RELATIVE; - continue; - } break; + codePoints = arrayFrom(input); - case PATH_OR_AUTHORITY: - if (chr == '/') { - state = AUTHORITY; + while (pointer <= codePoints.length) { + chr = codePoints[pointer]; + switch (state) { + case SCHEME_START: + if (chr && exec(ALPHA, chr)) { + buffer += toLowerCase(chr); + state = SCHEME; + } else if (!stateOverride) { + state = NO_SCHEME; + continue; + } else return INVALID_SCHEME; break; - } else { - state = PATH; - continue; - } - case RELATIVE: - url.scheme = base.scheme; - if (chr == EOF) { - url.username = base.username; - url.password = base.password; - url.host = base.host; - url.port = base.port; - url.path = arraySlice(base.path); - url.query = base.query; - } else if (chr == '/' || (chr == '\\' && isSpecial(url))) { - state = RELATIVE_SLASH; - } else if (chr == '?') { - url.username = base.username; - url.password = base.password; - url.host = base.host; - url.port = base.port; - url.path = arraySlice(base.path); - url.query = ''; - state = QUERY; - } else if (chr == '#') { - url.username = base.username; - url.password = base.password; - url.host = base.host; - url.port = base.port; - url.path = arraySlice(base.path); - url.query = base.query; - url.fragment = ''; - state = FRAGMENT; - } else { - url.username = base.username; - url.password = base.password; - url.host = base.host; - url.port = base.port; - url.path = arraySlice(base.path); - url.path.length--; - state = PATH; - continue; - } break; + case SCHEME: + if (chr && (exec(ALPHANUMERIC, chr) || chr == '+' || chr == '-' || chr == '.')) { + buffer += toLowerCase(chr); + } else if (chr == ':') { + if (stateOverride && ( + (url.isSpecial() != hasOwn(specialSchemes, buffer)) || + (buffer == 'file' && (url.includesCredentials() || url.port !== null)) || + (url.scheme == 'file' && !url.host) + )) return; + url.scheme = buffer; + if (stateOverride) { + if (url.isSpecial() && specialSchemes[url.scheme] == url.port) url.port = null; + return; + } + buffer = ''; + if (url.scheme == 'file') { + state = FILE; + } else if (url.isSpecial() && base && base.scheme == url.scheme) { + state = SPECIAL_RELATIVE_OR_AUTHORITY; + } else if (url.isSpecial()) { + state = SPECIAL_AUTHORITY_SLASHES; + } else if (codePoints[pointer + 1] == '/') { + state = PATH_OR_AUTHORITY; + pointer++; + } else { + url.cannotBeABaseURL = true; + push(url.path, ''); + state = CANNOT_BE_A_BASE_URL_PATH; + } + } else if (!stateOverride) { + buffer = ''; + state = NO_SCHEME; + pointer = 0; + continue; + } else return INVALID_SCHEME; + break; - case RELATIVE_SLASH: - if (isSpecial(url) && (chr == '/' || chr == '\\')) { - state = SPECIAL_AUTHORITY_IGNORE_SLASHES; - } else if (chr == '/') { - state = AUTHORITY; - } else { - url.username = base.username; - url.password = base.password; - url.host = base.host; - url.port = base.port; - state = PATH; + case NO_SCHEME: + if (!base || (base.cannotBeABaseURL && chr != '#')) return INVALID_SCHEME; + if (base.cannotBeABaseURL && chr == '#') { + url.scheme = base.scheme; + url.path = arraySlice(base.path); + url.query = base.query; + url.fragment = ''; + url.cannotBeABaseURL = true; + state = FRAGMENT; + break; + } + state = base.scheme == 'file' ? FILE : RELATIVE; continue; - } break; - case SPECIAL_AUTHORITY_SLASHES: - state = SPECIAL_AUTHORITY_IGNORE_SLASHES; - if (chr != '/' || charAt(buffer, pointer + 1) != '/') continue; - pointer++; - break; - - case SPECIAL_AUTHORITY_IGNORE_SLASHES: - if (chr != '/' && chr != '\\') { - state = AUTHORITY; - continue; - } break; - - case AUTHORITY: - if (chr == '@') { - if (seenAt) buffer = '%40' + buffer; - seenAt = true; - bufferCodePoints = arrayFrom(buffer); - for (var i = 0; i < bufferCodePoints.length; i++) { - var codePoint = bufferCodePoints[i]; - if (codePoint == ':' && !seenPasswordToken) { - seenPasswordToken = true; - continue; - } - var encodedCodePoints = percentEncode(codePoint, userinfoPercentEncodeSet); - if (seenPasswordToken) url.password += encodedCodePoints; - else url.username += encodedCodePoints; - } - buffer = ''; - } else if ( - chr == EOF || chr == '/' || chr == '?' || chr == '#' || - (chr == '\\' && isSpecial(url)) - ) { - if (seenAt && buffer == '') return INVALID_AUTHORITY; - pointer -= arrayFrom(buffer).length + 1; - buffer = ''; - state = HOST; - } else buffer += chr; - break; + case SPECIAL_RELATIVE_OR_AUTHORITY: + if (chr == '/' && codePoints[pointer + 1] == '/') { + state = SPECIAL_AUTHORITY_IGNORE_SLASHES; + pointer++; + } else { + state = RELATIVE; + continue; + } break; - case HOST: - case HOSTNAME: - if (stateOverride && url.scheme == 'file') { - state = FILE_HOST; - continue; - } else if (chr == ':' && !seenBracket) { - if (buffer == '') return INVALID_HOST; - failure = parseHost(url, buffer); - if (failure) return failure; - buffer = ''; - state = PORT; - if (stateOverride == HOSTNAME) return; - } else if ( - chr == EOF || chr == '/' || chr == '?' || chr == '#' || - (chr == '\\' && isSpecial(url)) - ) { - if (isSpecial(url) && buffer == '') return INVALID_HOST; - if (stateOverride && buffer == '' && (includesCredentials(url) || url.port !== null)) return; - failure = parseHost(url, buffer); - if (failure) return failure; - buffer = ''; - state = PATH_START; - if (stateOverride) return; - continue; - } else { - if (chr == '[') seenBracket = true; - else if (chr == ']') seenBracket = false; - buffer += chr; - } break; - - case PORT: - if (exec(DIGIT, chr)) { - buffer += chr; - } else if ( - chr == EOF || chr == '/' || chr == '?' || chr == '#' || - (chr == '\\' && isSpecial(url)) || - stateOverride - ) { - if (buffer != '') { - var port = parseInt$1(buffer, 10); - if (port > 0xFFFF) return INVALID_PORT; - url.port = (isSpecial(url) && port === specialSchemes[url.scheme]) ? null : port; - buffer = ''; + case PATH_OR_AUTHORITY: + if (chr == '/') { + state = AUTHORITY; + break; + } else { + state = PATH; + continue; } - if (stateOverride) return; - state = PATH_START; - continue; - } else return INVALID_PORT; - break; - case FILE: - url.scheme = 'file'; - if (chr == '/' || chr == '\\') state = FILE_SLASH; - else if (base && base.scheme == 'file') { + case RELATIVE: + url.scheme = base.scheme; if (chr == EOF) { + url.username = base.username; + url.password = base.password; url.host = base.host; + url.port = base.port; url.path = arraySlice(base.path); url.query = base.query; + } else if (chr == '/' || (chr == '\\' && url.isSpecial())) { + state = RELATIVE_SLASH; } else if (chr == '?') { + url.username = base.username; + url.password = base.password; url.host = base.host; + url.port = base.port; url.path = arraySlice(base.path); url.query = ''; state = QUERY; } else if (chr == '#') { + url.username = base.username; + url.password = base.password; url.host = base.host; + url.port = base.port; url.path = arraySlice(base.path); url.query = base.query; url.fragment = ''; state = FRAGMENT; } else { - if (!startsWithWindowsDriveLetter(join(arraySlice(codePoints, pointer), ''))) { + url.username = base.username; + url.password = base.password; + url.host = base.host; + url.port = base.port; + url.path = arraySlice(base.path); + url.path.length--; + state = PATH; + continue; + } break; + + case RELATIVE_SLASH: + if (url.isSpecial() && (chr == '/' || chr == '\\')) { + state = SPECIAL_AUTHORITY_IGNORE_SLASHES; + } else if (chr == '/') { + state = AUTHORITY; + } else { + url.username = base.username; + url.password = base.password; + url.host = base.host; + url.port = base.port; + state = PATH; + continue; + } break; + + case SPECIAL_AUTHORITY_SLASHES: + state = SPECIAL_AUTHORITY_IGNORE_SLASHES; + if (chr != '/' || charAt(buffer, pointer + 1) != '/') continue; + pointer++; + break; + + case SPECIAL_AUTHORITY_IGNORE_SLASHES: + if (chr != '/' && chr != '\\') { + state = AUTHORITY; + continue; + } break; + + case AUTHORITY: + if (chr == '@') { + if (seenAt) buffer = '%40' + buffer; + seenAt = true; + bufferCodePoints = arrayFrom(buffer); + for (var i = 0; i < bufferCodePoints.length; i++) { + var codePoint = bufferCodePoints[i]; + if (codePoint == ':' && !seenPasswordToken) { + seenPasswordToken = true; + continue; + } + var encodedCodePoints = percentEncode(codePoint, userinfoPercentEncodeSet); + if (seenPasswordToken) url.password += encodedCodePoints; + else url.username += encodedCodePoints; + } + buffer = ''; + } else if ( + chr == EOF || chr == '/' || chr == '?' || chr == '#' || + (chr == '\\' && url.isSpecial()) + ) { + if (seenAt && buffer == '') return INVALID_AUTHORITY; + pointer -= arrayFrom(buffer).length + 1; + buffer = ''; + state = HOST; + } else buffer += chr; + break; + + case HOST: + case HOSTNAME: + if (stateOverride && url.scheme == 'file') { + state = FILE_HOST; + continue; + } else if (chr == ':' && !seenBracket) { + if (buffer == '') return INVALID_HOST; + failure = url.parseHost(buffer); + if (failure) return failure; + buffer = ''; + state = PORT; + if (stateOverride == HOSTNAME) return; + } else if ( + chr == EOF || chr == '/' || chr == '?' || chr == '#' || + (chr == '\\' && url.isSpecial()) + ) { + if (url.isSpecial() && buffer == '') return INVALID_HOST; + if (stateOverride && buffer == '' && (url.includesCredentials() || url.port !== null)) return; + failure = url.parseHost(buffer); + if (failure) return failure; + buffer = ''; + state = PATH_START; + if (stateOverride) return; + continue; + } else { + if (chr == '[') seenBracket = true; + else if (chr == ']') seenBracket = false; + buffer += chr; + } break; + + case PORT: + if (exec(DIGIT, chr)) { + buffer += chr; + } else if ( + chr == EOF || chr == '/' || chr == '?' || chr == '#' || + (chr == '\\' && url.isSpecial()) || + stateOverride + ) { + if (buffer != '') { + var port = parseInt$1(buffer, 10); + if (port > 0xFFFF) return INVALID_PORT; + url.port = (url.isSpecial() && port === specialSchemes[url.scheme]) ? null : port; + buffer = ''; + } + if (stateOverride) return; + state = PATH_START; + continue; + } else return INVALID_PORT; + break; + + case FILE: + url.scheme = 'file'; + if (chr == '/' || chr == '\\') state = FILE_SLASH; + else if (base && base.scheme == 'file') { + if (chr == EOF) { + url.host = base.host; + url.path = arraySlice(base.path); + url.query = base.query; + } else if (chr == '?') { + url.host = base.host; + url.path = arraySlice(base.path); + url.query = ''; + state = QUERY; + } else if (chr == '#') { url.host = base.host; url.path = arraySlice(base.path); - shortenURLsPath(url); + url.query = base.query; + url.fragment = ''; + state = FRAGMENT; + } else { + if (!startsWithWindowsDriveLetter(join(arraySlice(codePoints, pointer), ''))) { + url.host = base.host; + url.path = arraySlice(base.path); + url.shortenPath(); + } + state = PATH; + continue; } + } else { state = PATH; continue; + } break; + + case FILE_SLASH: + if (chr == '/' || chr == '\\') { + state = FILE_HOST; + break; + } + if (base && base.scheme == 'file' && !startsWithWindowsDriveLetter(join(arraySlice(codePoints, pointer), ''))) { + if (isWindowsDriveLetter(base.path[0], true)) push(url.path, base.path[0]); + else url.host = base.host; } - } else { state = PATH; continue; - } break; - case FILE_SLASH: - if (chr == '/' || chr == '\\') { - state = FILE_HOST; + case FILE_HOST: + if (chr == EOF || chr == '/' || chr == '\\' || chr == '?' || chr == '#') { + if (!stateOverride && isWindowsDriveLetter(buffer)) { + state = PATH; + } else if (buffer == '') { + url.host = ''; + if (stateOverride) return; + state = PATH_START; + } else { + failure = url.parseHost(buffer); + if (failure) return failure; + if (url.host == 'localhost') url.host = ''; + if (stateOverride) return; + buffer = ''; + state = PATH_START; + } continue; + } else buffer += chr; break; - } - if (base && base.scheme == 'file' && !startsWithWindowsDriveLetter(join(arraySlice(codePoints, pointer), ''))) { - if (isWindowsDriveLetter(base.path[0], true)) push(url.path, base.path[0]); - else url.host = base.host; - } - state = PATH; - continue; - case FILE_HOST: - if (chr == EOF || chr == '/' || chr == '\\' || chr == '?' || chr == '#') { - if (!stateOverride && isWindowsDriveLetter(buffer)) { + case PATH_START: + if (url.isSpecial()) { state = PATH; - } else if (buffer == '') { - url.host = ''; - if (stateOverride) return; - state = PATH_START; - } else { - failure = parseHost(url, buffer); - if (failure) return failure; - if (url.host == 'localhost') url.host = ''; - if (stateOverride) return; - buffer = ''; - state = PATH_START; - } continue; - } else buffer += chr; - break; - - case PATH_START: - if (isSpecial(url)) { - state = PATH; - if (chr != '/' && chr != '\\') continue; - } else if (!stateOverride && chr == '?') { - url.query = ''; - state = QUERY; - } else if (!stateOverride && chr == '#') { - url.fragment = ''; - state = FRAGMENT; - } else if (chr != EOF) { - state = PATH; - if (chr != '/') continue; - } break; + if (chr != '/' && chr != '\\') continue; + } else if (!stateOverride && chr == '?') { + url.query = ''; + state = QUERY; + } else if (!stateOverride && chr == '#') { + url.fragment = ''; + state = FRAGMENT; + } else if (chr != EOF) { + state = PATH; + if (chr != '/') continue; + } break; - case PATH: - if ( - chr == EOF || chr == '/' || - (chr == '\\' && isSpecial(url)) || - (!stateOverride && (chr == '?' || chr == '#')) - ) { - if (isDoubleDot(buffer)) { - shortenURLsPath(url); - if (chr != '/' && !(chr == '\\' && isSpecial(url))) { - push(url.path, ''); + case PATH: + if ( + chr == EOF || chr == '/' || + (chr == '\\' && url.isSpecial()) || + (!stateOverride && (chr == '?' || chr == '#')) + ) { + if (isDoubleDot(buffer)) { + url.shortenPath(); + if (chr != '/' && !(chr == '\\' && url.isSpecial())) { + push(url.path, ''); + } + } else if (isSingleDot(buffer)) { + if (chr != '/' && !(chr == '\\' && url.isSpecial())) { + push(url.path, ''); + } + } else { + if (url.scheme == 'file' && !url.path.length && isWindowsDriveLetter(buffer)) { + if (url.host) url.host = ''; + buffer = charAt(buffer, 0) + ':'; // normalize windows drive letter + } + push(url.path, buffer); } - } else if (isSingleDot(buffer)) { - if (chr != '/' && !(chr == '\\' && isSpecial(url))) { - push(url.path, ''); + buffer = ''; + if (url.scheme == 'file' && (chr == EOF || chr == '?' || chr == '#')) { + while (url.path.length > 1 && url.path[0] === '') { + shift(url.path); + } } - } else { - if (url.scheme == 'file' && !url.path.length && isWindowsDriveLetter(buffer)) { - if (url.host) url.host = ''; - buffer = charAt(buffer, 0) + ':'; // normalize windows drive letter + if (chr == '?') { + url.query = ''; + state = QUERY; + } else if (chr == '#') { + url.fragment = ''; + state = FRAGMENT; } - push(url.path, buffer); - } - buffer = ''; - if (url.scheme == 'file' && (chr == EOF || chr == '?' || chr == '#')) { - while (url.path.length > 1 && url.path[0] === '') { - shift(url.path); - } - } + } else { + buffer += percentEncode(chr, pathPercentEncodeSet); + } break; + + case CANNOT_BE_A_BASE_URL_PATH: if (chr == '?') { url.query = ''; state = QUERY; } else if (chr == '#') { url.fragment = ''; state = FRAGMENT; - } - } else { - buffer += percentEncode(chr, pathPercentEncodeSet); - } break; - - case CANNOT_BE_A_BASE_URL_PATH: - if (chr == '?') { - url.query = ''; - state = QUERY; - } else if (chr == '#') { - url.fragment = ''; - state = FRAGMENT; - } else if (chr != EOF) { - url.path[0] += percentEncode(chr, C0ControlPercentEncodeSet); - } break; - - case QUERY: - if (!stateOverride && chr == '#') { - url.fragment = ''; - state = FRAGMENT; - } else if (chr != EOF) { - if (chr == "'" && isSpecial(url)) url.query += '%27'; - else if (chr == '#') url.query += '%23'; - else url.query += percentEncode(chr, C0ControlPercentEncodeSet); - } break; - - case FRAGMENT: - if (chr != EOF) url.fragment += percentEncode(chr, fragmentPercentEncodeSet); - break; - } + } else if (chr != EOF) { + url.path[0] += percentEncode(chr, C0ControlPercentEncodeSet); + } break; - pointer++; + case QUERY: + if (!stateOverride && chr == '#') { + url.fragment = ''; + state = FRAGMENT; + } else if (chr != EOF) { + if (chr == "'" && url.isSpecial()) url.query += '%27'; + else if (chr == '#') url.query += '%23'; + else url.query += percentEncode(chr, C0ControlPercentEncodeSet); + } break; + + case FRAGMENT: + if (chr != EOF) url.fragment += percentEncode(chr, fragmentPercentEncodeSet); + break; + } + + pointer++; + } + }, + // https://url.spec.whatwg.org/#host-parsing + parseHost: function (input) { + var result, codePoints, index; + if (charAt(input, 0) == '[') { + if (charAt(input, input.length - 1) != ']') return INVALID_HOST; + result = parseIPv6(stringSlice(input, 1, -1)); + if (!result) return INVALID_HOST; + this.host = result; + // opaque host + } else if (!this.isSpecial()) { + if (exec(FORBIDDEN_HOST_CODE_POINT_EXCLUDING_PERCENT, input)) return INVALID_HOST; + result = ''; + codePoints = arrayFrom(input); + for (index = 0; index < codePoints.length; index++) { + result += percentEncode(codePoints[index], C0ControlPercentEncodeSet); + } + this.host = result; + } else { + input = toASCII(input); + if (exec(FORBIDDEN_HOST_CODE_POINT, input)) return INVALID_HOST; + result = parseIPv4(input); + if (result === null) return INVALID_HOST; + this.host = result; + } + }, + // https://url.spec.whatwg.org/#cannot-have-a-username-password-port + cannotHaveUsernamePasswordPort: function () { + return !this.host || this.cannotBeABaseURL || this.scheme == 'file'; + }, + // https://url.spec.whatwg.org/#include-credentials + includesCredentials: function () { + return this.username != '' || this.password != ''; + }, + // https://url.spec.whatwg.org/#is-special + isSpecial: function () { + return hasOwn(specialSchemes, this.scheme); + }, + // https://url.spec.whatwg.org/#shorten-a-urls-path + shortenPath: function () { + var path = this.path; + var pathSize = path.length; + if (pathSize && (this.scheme != 'file' || pathSize != 1 || !isWindowsDriveLetter(path[0], true))) { + path.length--; + } + }, + // https://url.spec.whatwg.org/#concept-url-serializer + serialize: function () { + var url = this; + var scheme = url.scheme; + var username = url.username; + var password = url.password; + var host = url.host; + var port = url.port; + var path = url.path; + var query = url.query; + var fragment = url.fragment; + var output = scheme + ':'; + if (host !== null) { + output += '//'; + if (url.includesCredentials()) { + output += username + (password ? ':' + password : '') + '@'; + } + output += serializeHost(host); + if (port !== null) output += ':' + port; + } else if (scheme == 'file') output += '//'; + output += url.cannotBeABaseURL ? path[0] : path.length ? '/' + join(path, '/') : ''; + if (query !== null) output += '?' + query; + if (fragment !== null) output += '#' + fragment; + return output; + }, + // https://url.spec.whatwg.org/#dom-url-href + setHref: function (href) { + var failure = this.parse(href); + if (failure) throw TypeError$1(failure); + this.searchParams.update(); + }, + // https://url.spec.whatwg.org/#dom-url-origin + getOrigin: function () { + var scheme = this.scheme; + var port = this.port; + if (scheme == 'blob') try { + return new URLConstructor(scheme.path[0]).origin; + } catch (error) { + return 'null'; + } + if (scheme == 'file' || !this.isSpecial()) return 'null'; + return scheme + '://' + serializeHost(this.host) + (port !== null ? ':' + port : ''); + }, + // https://url.spec.whatwg.org/#dom-url-protocol + getProtocol: function () { + return this.scheme + ':'; + }, + setProtocol: function (protocol) { + this.parse($toString(protocol) + ':', SCHEME_START); + }, + // https://url.spec.whatwg.org/#dom-url-username + getUsername: function () { + return this.username; + }, + setUsername: function (username) { + var codePoints = arrayFrom($toString(username)); + if (this.cannotHaveUsernamePasswordPort()) return; + this.username = ''; + for (var i = 0; i < codePoints.length; i++) { + this.username += percentEncode(codePoints[i], userinfoPercentEncodeSet); + } + }, + // https://url.spec.whatwg.org/#dom-url-password + getPassword: function () { + return this.password; + }, + setPassword: function (password) { + var codePoints = arrayFrom($toString(password)); + if (this.cannotHaveUsernamePasswordPort()) return; + this.password = ''; + for (var i = 0; i < codePoints.length; i++) { + this.password += percentEncode(codePoints[i], userinfoPercentEncodeSet); + } + }, + // https://url.spec.whatwg.org/#dom-url-host + getHost: function () { + var host = this.host; + var port = this.port; + return host === null ? '' + : port === null ? serializeHost(host) + : serializeHost(host) + ':' + port; + }, + setHost: function (host) { + if (this.cannotBeABaseURL) return; + this.parse(host, HOST); + }, + // https://url.spec.whatwg.org/#dom-url-hostname + getHostname: function () { + var host = this.host; + return host === null ? '' : serializeHost(host); + }, + setHostname: function (hostname) { + if (this.cannotBeABaseURL) return; + this.parse(hostname, HOSTNAME); + }, + // https://url.spec.whatwg.org/#dom-url-port + getPort: function () { + var port = this.port; + return port === null ? '' : $toString(port); + }, + setPort: function (port) { + if (this.cannotHaveUsernamePasswordPort()) return; + port = $toString(port); + if (port == '') this.port = null; + else this.parse(port, PORT); + }, + // https://url.spec.whatwg.org/#dom-url-pathname + getPathname: function () { + var path = this.path; + return this.cannotBeABaseURL ? path[0] : path.length ? '/' + join(path, '/') : ''; + }, + setPathname: function (pathname) { + if (this.cannotBeABaseURL) return; + this.path = []; + this.parse(pathname, PATH_START); + }, + // https://url.spec.whatwg.org/#dom-url-search + getSearch: function () { + var query = this.query; + return query ? '?' + query : ''; + }, + setSearch: function (search) { + search = $toString(search); + if (search == '') { + this.query = null; + } else { + if ('?' == charAt(search, 0)) search = stringSlice(search, 1); + this.query = ''; + this.parse(search, QUERY); + } + this.searchParams.update(); + }, + // https://url.spec.whatwg.org/#dom-url-searchparams + getSearchParams: function () { + return this.searchParams.facade; + }, + // https://url.spec.whatwg.org/#dom-url-hash + getHash: function () { + var fragment = this.fragment; + return fragment ? '#' + fragment : ''; + }, + setHash: function (hash) { + hash = $toString(hash); + if (hash == '') { + this.fragment = null; + return; + } + if ('#' == charAt(hash, 0)) hash = stringSlice(hash, 1); + this.fragment = ''; + this.parse(hash, FRAGMENT); + }, + update: function () { + this.query = this.searchParams.serialize() || null; } }; @@ -97650,253 +98091,90 @@ // https://url.spec.whatwg.org/#url-class var URLConstructor = function URL(url /* , base */) { var that = anInstance(this, URLPrototype); - var base = arguments.length > 1 ? arguments[1] : undefined; - var urlString = $toString(url); - var state = setInternalState(that, { type: 'URL' }); - var baseState, failure; - if (base !== undefined) { - try { - baseState = getInternalURLState(base); - } catch (error) { - failure = parseURL(baseState = {}, $toString(base)); - if (failure) throw TypeError$1(failure); - } - } - failure = parseURL(state, urlString, null, baseState); - if (failure) throw TypeError$1(failure); - var searchParams = state.searchParams = new URLSearchParams$1(); - var searchParamsState = getInternalSearchParamsState(searchParams); - searchParamsState.updateSearchParams(state.query); - searchParamsState.updateURL = function () { - state.query = $toString(searchParams) || null; - }; + var base = validateArgumentsLength(arguments.length, 1) > 1 ? arguments[1] : undefined; + var state = setInternalState(that, new URLState(url, false, base)); if (!DESCRIPTORS) { - that.href = call(serializeURL, that); - that.origin = call(getOrigin, that); - that.protocol = call(getProtocol, that); - that.username = call(getUsername, that); - that.password = call(getPassword, that); - that.host = call(getHost, that); - that.hostname = call(getHostname, that); - that.port = call(getPort, that); - that.pathname = call(getPathname, that); - that.search = call(getSearch, that); - that.searchParams = call(getSearchParams, that); - that.hash = call(getHash, that); + that.href = state.serialize(); + that.origin = state.getOrigin(); + that.protocol = state.getProtocol(); + that.username = state.getUsername(); + that.password = state.getPassword(); + that.host = state.getHost(); + that.hostname = state.getHostname(); + that.port = state.getPort(); + that.pathname = state.getPathname(); + that.search = state.getSearch(); + that.searchParams = state.getSearchParams(); + that.hash = state.getHash(); } }; var URLPrototype = URLConstructor.prototype; - var serializeURL = function () { - var url = getInternalURLState(this); - var scheme = url.scheme; - var username = url.username; - var password = url.password; - var host = url.host; - var port = url.port; - var path = url.path; - var query = url.query; - var fragment = url.fragment; - var output = scheme + ':'; - if (host !== null) { - output += '//'; - if (includesCredentials(url)) { - output += username + (password ? ':' + password : '') + '@'; - } - output += serializeHost(host); - if (port !== null) output += ':' + port; - } else if (scheme == 'file') output += '//'; - output += url.cannotBeABaseURL ? path[0] : path.length ? '/' + join(path, '/') : ''; - if (query !== null) output += '?' + query; - if (fragment !== null) output += '#' + fragment; - return output; - }; - - var getOrigin = function () { - var url = getInternalURLState(this); - var scheme = url.scheme; - var port = url.port; - if (scheme == 'blob') try { - return new URLConstructor(scheme.path[0]).origin; - } catch (error) { - return 'null'; - } - if (scheme == 'file' || !isSpecial(url)) return 'null'; - return scheme + '://' + serializeHost(url.host) + (port !== null ? ':' + port : ''); - }; - - var getProtocol = function () { - return getInternalURLState(this).scheme + ':'; - }; - - var getUsername = function () { - return getInternalURLState(this).username; - }; - - var getPassword = function () { - return getInternalURLState(this).password; - }; - - var getHost = function () { - var url = getInternalURLState(this); - var host = url.host; - var port = url.port; - return host === null ? '' - : port === null ? serializeHost(host) - : serializeHost(host) + ':' + port; - }; - - var getHostname = function () { - var host = getInternalURLState(this).host; - return host === null ? '' : serializeHost(host); - }; - - var getPort = function () { - var port = getInternalURLState(this).port; - return port === null ? '' : $toString(port); - }; - - var getPathname = function () { - var url = getInternalURLState(this); - var path = url.path; - return url.cannotBeABaseURL ? path[0] : path.length ? '/' + join(path, '/') : ''; - }; - - var getSearch = function () { - var query = getInternalURLState(this).query; - return query ? '?' + query : ''; - }; - - var getSearchParams = function () { - return getInternalURLState(this).searchParams; - }; - - var getHash = function () { - var fragment = getInternalURLState(this).fragment; - return fragment ? '#' + fragment : ''; - }; - var accessorDescriptor = function (getter, setter) { - return { get: getter, set: setter, configurable: true, enumerable: true }; + return { + get: function () { + return getInternalURLState(this)[getter](); + }, + set: setter && function (value) { + return getInternalURLState(this)[setter](value); + }, + configurable: true, + enumerable: true + }; }; if (DESCRIPTORS) { defineProperties(URLPrototype, { // `URL.prototype.href` accessors pair // https://url.spec.whatwg.org/#dom-url-href - href: accessorDescriptor(serializeURL, function (href) { - var url = getInternalURLState(this); - var urlString = $toString(href); - var failure = parseURL(url, urlString); - if (failure) throw TypeError$1(failure); - getInternalSearchParamsState(url.searchParams).updateSearchParams(url.query); - }), + href: accessorDescriptor('serialize', 'setHref'), // `URL.prototype.origin` getter // https://url.spec.whatwg.org/#dom-url-origin - origin: accessorDescriptor(getOrigin), + origin: accessorDescriptor('getOrigin'), // `URL.prototype.protocol` accessors pair // https://url.spec.whatwg.org/#dom-url-protocol - protocol: accessorDescriptor(getProtocol, function (protocol) { - var url = getInternalURLState(this); - parseURL(url, $toString(protocol) + ':', SCHEME_START); - }), + protocol: accessorDescriptor('getProtocol', 'setProtocol'), // `URL.prototype.username` accessors pair // https://url.spec.whatwg.org/#dom-url-username - username: accessorDescriptor(getUsername, function (username) { - var url = getInternalURLState(this); - var codePoints = arrayFrom($toString(username)); - if (cannotHaveUsernamePasswordPort(url)) return; - url.username = ''; - for (var i = 0; i < codePoints.length; i++) { - url.username += percentEncode(codePoints[i], userinfoPercentEncodeSet); - } - }), + username: accessorDescriptor('getUsername', 'setUsername'), // `URL.prototype.password` accessors pair // https://url.spec.whatwg.org/#dom-url-password - password: accessorDescriptor(getPassword, function (password) { - var url = getInternalURLState(this); - var codePoints = arrayFrom($toString(password)); - if (cannotHaveUsernamePasswordPort(url)) return; - url.password = ''; - for (var i = 0; i < codePoints.length; i++) { - url.password += percentEncode(codePoints[i], userinfoPercentEncodeSet); - } - }), + password: accessorDescriptor('getPassword', 'setPassword'), // `URL.prototype.host` accessors pair // https://url.spec.whatwg.org/#dom-url-host - host: accessorDescriptor(getHost, function (host) { - var url = getInternalURLState(this); - if (url.cannotBeABaseURL) return; - parseURL(url, $toString(host), HOST); - }), + host: accessorDescriptor('getHost', 'setHost'), // `URL.prototype.hostname` accessors pair // https://url.spec.whatwg.org/#dom-url-hostname - hostname: accessorDescriptor(getHostname, function (hostname) { - var url = getInternalURLState(this); - if (url.cannotBeABaseURL) return; - parseURL(url, $toString(hostname), HOSTNAME); - }), + hostname: accessorDescriptor('getHostname', 'setHostname'), // `URL.prototype.port` accessors pair // https://url.spec.whatwg.org/#dom-url-port - port: accessorDescriptor(getPort, function (port) { - var url = getInternalURLState(this); - if (cannotHaveUsernamePasswordPort(url)) return; - port = $toString(port); - if (port == '') url.port = null; - else parseURL(url, port, PORT); - }), + port: accessorDescriptor('getPort', 'setPort'), // `URL.prototype.pathname` accessors pair // https://url.spec.whatwg.org/#dom-url-pathname - pathname: accessorDescriptor(getPathname, function (pathname) { - var url = getInternalURLState(this); - if (url.cannotBeABaseURL) return; - url.path = []; - parseURL(url, $toString(pathname), PATH_START); - }), + pathname: accessorDescriptor('getPathname', 'setPathname'), // `URL.prototype.search` accessors pair // https://url.spec.whatwg.org/#dom-url-search - search: accessorDescriptor(getSearch, function (search) { - var url = getInternalURLState(this); - search = $toString(search); - if (search == '') { - url.query = null; - } else { - if ('?' == charAt(search, 0)) search = stringSlice(search, 1); - url.query = ''; - parseURL(url, search, QUERY); - } - getInternalSearchParamsState(url.searchParams).updateSearchParams(url.query); - }), + search: accessorDescriptor('getSearch', 'setSearch'), // `URL.prototype.searchParams` getter // https://url.spec.whatwg.org/#dom-url-searchparams - searchParams: accessorDescriptor(getSearchParams), + searchParams: accessorDescriptor('getSearchParams'), // `URL.prototype.hash` accessors pair // https://url.spec.whatwg.org/#dom-url-hash - hash: accessorDescriptor(getHash, function (hash) { - var url = getInternalURLState(this); - hash = $toString(hash); - if (hash == '') { - url.fragment = null; - return; - } - if ('#' == charAt(hash, 0)) hash = stringSlice(hash, 1); - url.fragment = ''; - parseURL(url, hash, FRAGMENT); - }) + hash: accessorDescriptor('getHash', 'setHash') }); } // `URL.prototype.toJSON` method // https://url.spec.whatwg.org/#dom-url-tojson redefine(URLPrototype, 'toJSON', function toJSON() { - return call(serializeURL, this); + return getInternalURLState(this).serialize(); }, { enumerable: true }); // `URL.prototype.toString` method // https://url.spec.whatwg.org/#URL-stringification-behavior redefine(URLPrototype, 'toString', function toString() { - return call(serializeURL, this); + return getInternalURLState(this).serialize(); }, { enumerable: true }); if (NativeURL) { @@ -104485,7 +104763,9 @@ if (d.desc) return d.desc; var issueKey = d.issueKey; d.replacements = d.replacements || {}; - d.replacements["default"] = _t.html('inspector.unknown'); // special key `default` works as a fallback string + d.replacements["default"] = { + html: _t.html('inspector.unknown') + }; // special key `default` works as a fallback string return _t.html("QA.improveOSM.error_types.".concat(issueKey, ".description"), d.replacements); } @@ -104499,7 +104779,7 @@ var descriptionEnter = detailsEnter.append('div').attr('class', 'qa-details-subsection'); descriptionEnter.append('h4').call(_t.append('QA.keepRight.detail_description')); - descriptionEnter.append('div').attr('class', 'qa-details-description-text').text(issueDetail); // If there are entity links in the error message.. + descriptionEnter.append('div').attr('class', 'qa-details-description-text').html(issueDetail); // If there are entity links in the error message.. var relatedEntities = []; descriptionEnter.selectAll('.error_entity_link, .error_object_link').attr('href', '#').each(function () { @@ -104571,7 +104851,9 @@ function issueTitle(d) { var issueKey = d.issueKey; d.replacements = d.replacements || {}; - d.replacements["default"] = _t.html('inspector.unknown'); // special key `default` works as a fallback string + d.replacements["default"] = { + html: _t.html('inspector.unknown') + }; // special key `default` works as a fallback string return _t.html("QA.improveOSM.error_types.".concat(issueKey, ".title"), d.replacements); } @@ -104598,7 +104880,7 @@ return "#".concat(picon).concat(isMaki ? '-11' : ''); } }); - headerEnter.append('div').attr('class', 'qa-header-label').text(issueTitle); + headerEnter.append('div').attr('class', 'qa-header-label').html(issueTitle); } improveOsmHeader.issue = function (val) { @@ -105306,13 +105588,15 @@ function issueDetail(d) { var itemType = d.itemType, parentIssueType = d.parentIssueType; - var unknown = _t.html('inspector.unknown'); + var unknown = { + html: _t.html('inspector.unknown') + }; var replacements = d.replacements || {}; replacements["default"] = unknown; // special key `default` works as a fallback string var detail = _t.html("QA.keepRight.errorTypes.".concat(itemType, ".description"), replacements); - if (detail === unknown) { + if (detail === unknown.html) { detail = _t.html("QA.keepRight.errorTypes.".concat(parentIssueType, ".description"), replacements); } @@ -105402,15 +105686,17 @@ parentIssueType = d.parentIssueType; var unknown = _t.html('inspector.unknown'); var replacements = d.replacements || {}; - replacements["default"] = unknown; // special key `default` works as a fallback string + replacements["default"] = { + html: unknown + }; // special key `default` works as a fallback string var title = _t.html("QA.keepRight.errorTypes.".concat(itemType, ".title"), replacements); - if (title === unknown) { - title = _t.html("QA.keepRight.errorTypes.".concat(parentIssueType, ".title"), replacements); + if (title !== unknown) { + return _t.apply("QA.keepRight.errorTypes.".concat(itemType, ".title"), replacements); + } else { + return _t.apply("QA.keepRight.errorTypes.".concat(parentIssueType, ".title"), replacements); } - - return title; } function keepRightHeader(selection) { @@ -106250,8 +106536,9 @@ osm.on('apiStatusChange.uiStatus', update); context.history().on('storage_error', function () { - selection.call(_t.append('osm_api_status.message.local_storage_full')); - selection.attr('class', 'api-status error'); + selection.selectAll('span.local-storage-full').remove(); + selection.append('span').attr('class', 'local-storage-full').call(_t.append('osm_api_status.message.local_storage_full')); + selection.classed('error', true); }); // reload the status periodically regardless of other factors window.setInterval(function () { @@ -111353,7 +111640,7 @@ var _deferred = new Set(); - context.version = '2.20.3'; + context.version = '2.20.4'; context.privacyVersion = '20201202'; // iD will alter the hash so cache the parameters intended to setup the session context.initialHashParams = window.location.hash ? utilStringQs(window.location.hash) : {};