@silas-test/molecules-slider 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +85 -0
- package/index.cjs.js +3384 -0
- package/index.d.ts +1 -0
- package/package.json +14 -0
- package/src/index.d.ts +2 -0
- package/src/lib/molecules-slider.d.ts +5 -0
- package/src/lib/molecules-slider.stories.d.ts +11 -0
- package/src/lib/molecules-slider.style.d.ts +585 -0
- package/src/lib/molecules-slider.type.d.ts +51 -0
package/index.cjs.js
ADDED
|
@@ -0,0 +1,3384 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
var jsxRuntime = require('react/jsx-runtime');
|
|
5
|
+
var React = require('react');
|
|
6
|
+
var styled = require('styled-components');
|
|
7
|
+
var frontendFoundations = require('@silas-test/frontend-foundations');
|
|
8
|
+
var testAtomsButton = require('@silas-test/test-atoms-button');
|
|
9
|
+
|
|
10
|
+
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
|
+
|
|
12
|
+
var React__default = /*#__PURE__*/_interopDefault(React);
|
|
13
|
+
var styled__default = /*#__PURE__*/_interopDefault(styled);
|
|
14
|
+
|
|
15
|
+
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
16
|
+
|
|
17
|
+
var fails$e = function (exec) {
|
|
18
|
+
try {
|
|
19
|
+
return !!exec();
|
|
20
|
+
} catch (error) {
|
|
21
|
+
return true;
|
|
22
|
+
}
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
var fails$d = fails$e;
|
|
26
|
+
|
|
27
|
+
var functionBindNative = !fails$d(function () {
|
|
28
|
+
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
29
|
+
var test = (function () { /* empty */ }).bind();
|
|
30
|
+
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
31
|
+
return typeof test != 'function' || test.hasOwnProperty('prototype');
|
|
32
|
+
});
|
|
33
|
+
|
|
34
|
+
var NATIVE_BIND$3 = functionBindNative;
|
|
35
|
+
|
|
36
|
+
var FunctionPrototype$2 = Function.prototype;
|
|
37
|
+
var call$f = FunctionPrototype$2.call;
|
|
38
|
+
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
39
|
+
var uncurryThisWithBind = NATIVE_BIND$3 && FunctionPrototype$2.bind.bind(call$f, call$f);
|
|
40
|
+
|
|
41
|
+
var functionUncurryThis = NATIVE_BIND$3 ? uncurryThisWithBind : function (fn) {
|
|
42
|
+
return function () {
|
|
43
|
+
return call$f.apply(fn, arguments);
|
|
44
|
+
};
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
var uncurryThis$e = functionUncurryThis;
|
|
48
|
+
|
|
49
|
+
var toString$1 = uncurryThis$e({}.toString);
|
|
50
|
+
var stringSlice$1 = uncurryThis$e(''.slice);
|
|
51
|
+
|
|
52
|
+
var classofRaw$2 = function (it) {
|
|
53
|
+
return stringSlice$1(toString$1(it), 8, -1);
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
var uncurryThis$d = functionUncurryThis;
|
|
57
|
+
var fails$c = fails$e;
|
|
58
|
+
var classof$4 = classofRaw$2;
|
|
59
|
+
|
|
60
|
+
var $Object$4 = Object;
|
|
61
|
+
var split = uncurryThis$d(''.split);
|
|
62
|
+
|
|
63
|
+
// fallback for non-array-like ES3 and non-enumerable old V8 strings
|
|
64
|
+
var indexedObject = fails$c(function () {
|
|
65
|
+
// throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
|
|
66
|
+
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
67
|
+
return !$Object$4('z').propertyIsEnumerable(0);
|
|
68
|
+
}) ? function (it) {
|
|
69
|
+
return classof$4(it) === 'String' ? split(it, '') : $Object$4(it);
|
|
70
|
+
} : $Object$4;
|
|
71
|
+
|
|
72
|
+
// we can't use just `it == null` since of `document.all` special case
|
|
73
|
+
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
|
|
74
|
+
var isNullOrUndefined$4 = function (it) {
|
|
75
|
+
return it === null || it === undefined;
|
|
76
|
+
};
|
|
77
|
+
|
|
78
|
+
var isNullOrUndefined$3 = isNullOrUndefined$4;
|
|
79
|
+
|
|
80
|
+
var $TypeError$d = TypeError;
|
|
81
|
+
|
|
82
|
+
// `RequireObjectCoercible` abstract operation
|
|
83
|
+
// https://tc39.es/ecma262/#sec-requireobjectcoercible
|
|
84
|
+
var requireObjectCoercible$3 = function (it) {
|
|
85
|
+
if (isNullOrUndefined$3(it)) throw new $TypeError$d("Can't call method on " + it);
|
|
86
|
+
return it;
|
|
87
|
+
};
|
|
88
|
+
|
|
89
|
+
// toObject with fallback for non-array-like ES3 strings
|
|
90
|
+
var IndexedObject$1 = indexedObject;
|
|
91
|
+
var requireObjectCoercible$2 = requireObjectCoercible$3;
|
|
92
|
+
|
|
93
|
+
var toIndexedObject$5 = function (it) {
|
|
94
|
+
return IndexedObject$1(requireObjectCoercible$2(it));
|
|
95
|
+
};
|
|
96
|
+
|
|
97
|
+
var check = function (it) {
|
|
98
|
+
return it && it.Math === Math && it;
|
|
99
|
+
};
|
|
100
|
+
|
|
101
|
+
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
|
|
102
|
+
var globalThis_1 =
|
|
103
|
+
// eslint-disable-next-line es/no-global-this -- safe
|
|
104
|
+
check(typeof globalThis == 'object' && globalThis) ||
|
|
105
|
+
check(typeof window == 'object' && window) ||
|
|
106
|
+
// eslint-disable-next-line no-restricted-globals -- safe
|
|
107
|
+
check(typeof self == 'object' && self) ||
|
|
108
|
+
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
109
|
+
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
110
|
+
// eslint-disable-next-line no-new-func -- fallback
|
|
111
|
+
(function () { return this; })() || Function('return this')();
|
|
112
|
+
|
|
113
|
+
var sharedStore = {exports: {}};
|
|
114
|
+
|
|
115
|
+
var globalThis$m = globalThis_1;
|
|
116
|
+
|
|
117
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
118
|
+
var defineProperty$6 = Object.defineProperty;
|
|
119
|
+
|
|
120
|
+
var defineGlobalProperty$3 = function (key, value) {
|
|
121
|
+
try {
|
|
122
|
+
defineProperty$6(globalThis$m, key, { value: value, configurable: true, writable: true });
|
|
123
|
+
} catch (error) {
|
|
124
|
+
globalThis$m[key] = value;
|
|
125
|
+
} return value;
|
|
126
|
+
};
|
|
127
|
+
|
|
128
|
+
var globalThis$l = globalThis_1;
|
|
129
|
+
var defineGlobalProperty$2 = defineGlobalProperty$3;
|
|
130
|
+
|
|
131
|
+
var SHARED = '__core-js_shared__';
|
|
132
|
+
var store$3 = sharedStore.exports = globalThis$l[SHARED] || defineGlobalProperty$2(SHARED, {});
|
|
133
|
+
|
|
134
|
+
(store$3.versions || (store$3.versions = [])).push({
|
|
135
|
+
version: '3.48.0',
|
|
136
|
+
mode: 'global',
|
|
137
|
+
copyright: '© 2013–2025 Denis Pushkarev (zloirock.ru), 2025–2026 CoreJS Company (core-js.io). All rights reserved.',
|
|
138
|
+
license: 'https://github.com/zloirock/core-js/blob/v3.48.0/LICENSE',
|
|
139
|
+
source: 'https://github.com/zloirock/core-js'
|
|
140
|
+
});
|
|
141
|
+
|
|
142
|
+
var sharedStoreExports = sharedStore.exports;
|
|
143
|
+
|
|
144
|
+
var store$2 = sharedStoreExports;
|
|
145
|
+
|
|
146
|
+
var shared$3 = function (key, value) {
|
|
147
|
+
return store$2[key] || (store$2[key] = value || {});
|
|
148
|
+
};
|
|
149
|
+
|
|
150
|
+
var requireObjectCoercible$1 = requireObjectCoercible$3;
|
|
151
|
+
|
|
152
|
+
var $Object$3 = Object;
|
|
153
|
+
|
|
154
|
+
// `ToObject` abstract operation
|
|
155
|
+
// https://tc39.es/ecma262/#sec-toobject
|
|
156
|
+
var toObject$3 = function (argument) {
|
|
157
|
+
return $Object$3(requireObjectCoercible$1(argument));
|
|
158
|
+
};
|
|
159
|
+
|
|
160
|
+
var uncurryThis$c = functionUncurryThis;
|
|
161
|
+
var toObject$2 = toObject$3;
|
|
162
|
+
|
|
163
|
+
var hasOwnProperty = uncurryThis$c({}.hasOwnProperty);
|
|
164
|
+
|
|
165
|
+
// `HasOwnProperty` abstract operation
|
|
166
|
+
// https://tc39.es/ecma262/#sec-hasownproperty
|
|
167
|
+
// eslint-disable-next-line es/no-object-hasown -- safe
|
|
168
|
+
var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
|
|
169
|
+
return hasOwnProperty(toObject$2(it), key);
|
|
170
|
+
};
|
|
171
|
+
|
|
172
|
+
var uncurryThis$b = functionUncurryThis;
|
|
173
|
+
|
|
174
|
+
var id = 0;
|
|
175
|
+
var postfix = Math.random();
|
|
176
|
+
var toString = uncurryThis$b(1.1.toString);
|
|
177
|
+
|
|
178
|
+
var uid$2 = function (key) {
|
|
179
|
+
return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);
|
|
180
|
+
};
|
|
181
|
+
|
|
182
|
+
var globalThis$k = globalThis_1;
|
|
183
|
+
|
|
184
|
+
var navigator = globalThis$k.navigator;
|
|
185
|
+
var userAgent$5 = navigator && navigator.userAgent;
|
|
186
|
+
|
|
187
|
+
var environmentUserAgent = userAgent$5 ? String(userAgent$5) : '';
|
|
188
|
+
|
|
189
|
+
var globalThis$j = globalThis_1;
|
|
190
|
+
var userAgent$4 = environmentUserAgent;
|
|
191
|
+
|
|
192
|
+
var process$3 = globalThis$j.process;
|
|
193
|
+
var Deno$1 = globalThis$j.Deno;
|
|
194
|
+
var versions = process$3 && process$3.versions || Deno$1 && Deno$1.version;
|
|
195
|
+
var v8 = versions && versions.v8;
|
|
196
|
+
var match, version;
|
|
197
|
+
|
|
198
|
+
if (v8) {
|
|
199
|
+
match = v8.split('.');
|
|
200
|
+
// in old Chrome, versions of V8 isn't V8 = Chrome / 10
|
|
201
|
+
// but their correct versions are not interesting for us
|
|
202
|
+
version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`
|
|
206
|
+
// so check `userAgent` even if `.v8` exists, but 0
|
|
207
|
+
if (!version && userAgent$4) {
|
|
208
|
+
match = userAgent$4.match(/Edge\/(\d+)/);
|
|
209
|
+
if (!match || match[1] >= 74) {
|
|
210
|
+
match = userAgent$4.match(/Chrome\/(\d+)/);
|
|
211
|
+
if (match) version = +match[1];
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
var environmentV8Version = version;
|
|
216
|
+
|
|
217
|
+
/* eslint-disable es/no-symbol -- required for testing */
|
|
218
|
+
var V8_VERSION$1 = environmentV8Version;
|
|
219
|
+
var fails$b = fails$e;
|
|
220
|
+
var globalThis$i = globalThis_1;
|
|
221
|
+
|
|
222
|
+
var $String$4 = globalThis$i.String;
|
|
223
|
+
|
|
224
|
+
// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
|
|
225
|
+
var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$b(function () {
|
|
226
|
+
var symbol = Symbol('symbol detection');
|
|
227
|
+
// Chrome 38 Symbol has incorrect toString conversion
|
|
228
|
+
// `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
|
|
229
|
+
// nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will,
|
|
230
|
+
// of course, fail.
|
|
231
|
+
return !$String$4(symbol) || !(Object(symbol) instanceof Symbol) ||
|
|
232
|
+
// Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
|
|
233
|
+
!Symbol.sham && V8_VERSION$1 && V8_VERSION$1 < 41;
|
|
234
|
+
});
|
|
235
|
+
|
|
236
|
+
/* eslint-disable es/no-symbol -- required for testing */
|
|
237
|
+
var NATIVE_SYMBOL$1 = symbolConstructorDetection;
|
|
238
|
+
|
|
239
|
+
var useSymbolAsUid = NATIVE_SYMBOL$1 &&
|
|
240
|
+
!Symbol.sham &&
|
|
241
|
+
typeof Symbol.iterator == 'symbol';
|
|
242
|
+
|
|
243
|
+
var globalThis$h = globalThis_1;
|
|
244
|
+
var shared$2 = shared$3;
|
|
245
|
+
var hasOwn$a = hasOwnProperty_1;
|
|
246
|
+
var uid$1 = uid$2;
|
|
247
|
+
var NATIVE_SYMBOL = symbolConstructorDetection;
|
|
248
|
+
var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
|
|
249
|
+
|
|
250
|
+
var Symbol$1 = globalThis$h.Symbol;
|
|
251
|
+
var WellKnownSymbolsStore = shared$2('wks');
|
|
252
|
+
var createWellKnownSymbol = USE_SYMBOL_AS_UID$1 ? Symbol$1['for'] || Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid$1;
|
|
253
|
+
|
|
254
|
+
var wellKnownSymbol$g = function (name) {
|
|
255
|
+
if (!hasOwn$a(WellKnownSymbolsStore, name)) {
|
|
256
|
+
WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn$a(Symbol$1, name)
|
|
257
|
+
? Symbol$1[name]
|
|
258
|
+
: createWellKnownSymbol('Symbol.' + name);
|
|
259
|
+
} return WellKnownSymbolsStore[name];
|
|
260
|
+
};
|
|
261
|
+
|
|
262
|
+
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot
|
|
263
|
+
var documentAll = typeof document == 'object' && document.all;
|
|
264
|
+
|
|
265
|
+
// `IsCallable` abstract operation
|
|
266
|
+
// https://tc39.es/ecma262/#sec-iscallable
|
|
267
|
+
// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
|
|
268
|
+
var isCallable$k = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
|
|
269
|
+
return typeof argument == 'function' || argument === documentAll;
|
|
270
|
+
} : function (argument) {
|
|
271
|
+
return typeof argument == 'function';
|
|
272
|
+
};
|
|
273
|
+
|
|
274
|
+
var isCallable$j = isCallable$k;
|
|
275
|
+
|
|
276
|
+
var isObject$a = function (it) {
|
|
277
|
+
return typeof it == 'object' ? it !== null : isCallable$j(it);
|
|
278
|
+
};
|
|
279
|
+
|
|
280
|
+
var isObject$9 = isObject$a;
|
|
281
|
+
|
|
282
|
+
var $String$3 = String;
|
|
283
|
+
var $TypeError$c = TypeError;
|
|
284
|
+
|
|
285
|
+
// `Assert: Type(argument) is Object`
|
|
286
|
+
var anObject$d = function (argument) {
|
|
287
|
+
if (isObject$9(argument)) return argument;
|
|
288
|
+
throw new $TypeError$c($String$3(argument) + ' is not an object');
|
|
289
|
+
};
|
|
290
|
+
|
|
291
|
+
var objectDefineProperties = {};
|
|
292
|
+
|
|
293
|
+
var fails$a = fails$e;
|
|
294
|
+
|
|
295
|
+
// Detect IE8's incomplete defineProperty implementation
|
|
296
|
+
var descriptors = !fails$a(function () {
|
|
297
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
298
|
+
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
|
|
299
|
+
});
|
|
300
|
+
|
|
301
|
+
var DESCRIPTORS$d = descriptors;
|
|
302
|
+
var fails$9 = fails$e;
|
|
303
|
+
|
|
304
|
+
// V8 ~ Chrome 36-
|
|
305
|
+
// https://bugs.chromium.org/p/v8/issues/detail?id=3334
|
|
306
|
+
var v8PrototypeDefineBug = DESCRIPTORS$d && fails$9(function () {
|
|
307
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
308
|
+
return Object.defineProperty(function () { /* empty */ }, 'prototype', {
|
|
309
|
+
value: 42,
|
|
310
|
+
writable: false
|
|
311
|
+
}).prototype !== 42;
|
|
312
|
+
});
|
|
313
|
+
|
|
314
|
+
var objectDefineProperty = {};
|
|
315
|
+
|
|
316
|
+
var globalThis$g = globalThis_1;
|
|
317
|
+
var isObject$8 = isObject$a;
|
|
318
|
+
|
|
319
|
+
var document$3 = globalThis$g.document;
|
|
320
|
+
// typeof document.createElement is 'object' in old IE
|
|
321
|
+
var EXISTS$1 = isObject$8(document$3) && isObject$8(document$3.createElement);
|
|
322
|
+
|
|
323
|
+
var documentCreateElement$2 = function (it) {
|
|
324
|
+
return EXISTS$1 ? document$3.createElement(it) : {};
|
|
325
|
+
};
|
|
326
|
+
|
|
327
|
+
var DESCRIPTORS$c = descriptors;
|
|
328
|
+
var fails$8 = fails$e;
|
|
329
|
+
var createElement$1 = documentCreateElement$2;
|
|
330
|
+
|
|
331
|
+
// Thanks to IE8 for its funny defineProperty
|
|
332
|
+
var ie8DomDefine = !DESCRIPTORS$c && !fails$8(function () {
|
|
333
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
334
|
+
return Object.defineProperty(createElement$1('div'), 'a', {
|
|
335
|
+
get: function () { return 7; }
|
|
336
|
+
}).a !== 7;
|
|
337
|
+
});
|
|
338
|
+
|
|
339
|
+
var NATIVE_BIND$2 = functionBindNative;
|
|
340
|
+
|
|
341
|
+
var call$e = Function.prototype.call;
|
|
342
|
+
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
343
|
+
var functionCall = NATIVE_BIND$2 ? call$e.bind(call$e) : function () {
|
|
344
|
+
return call$e.apply(call$e, arguments);
|
|
345
|
+
};
|
|
346
|
+
|
|
347
|
+
var globalThis$f = globalThis_1;
|
|
348
|
+
var isCallable$i = isCallable$k;
|
|
349
|
+
|
|
350
|
+
var aFunction = function (argument) {
|
|
351
|
+
return isCallable$i(argument) ? argument : undefined;
|
|
352
|
+
};
|
|
353
|
+
|
|
354
|
+
var getBuiltIn$7 = function (namespace, method) {
|
|
355
|
+
return arguments.length < 2 ? aFunction(globalThis$f[namespace]) : globalThis$f[namespace] && globalThis$f[namespace][method];
|
|
356
|
+
};
|
|
357
|
+
|
|
358
|
+
var uncurryThis$a = functionUncurryThis;
|
|
359
|
+
|
|
360
|
+
var objectIsPrototypeOf = uncurryThis$a({}.isPrototypeOf);
|
|
361
|
+
|
|
362
|
+
var getBuiltIn$6 = getBuiltIn$7;
|
|
363
|
+
var isCallable$h = isCallable$k;
|
|
364
|
+
var isPrototypeOf$2 = objectIsPrototypeOf;
|
|
365
|
+
var USE_SYMBOL_AS_UID = useSymbolAsUid;
|
|
366
|
+
|
|
367
|
+
var $Object$2 = Object;
|
|
368
|
+
|
|
369
|
+
var isSymbol$2 = USE_SYMBOL_AS_UID ? function (it) {
|
|
370
|
+
return typeof it == 'symbol';
|
|
371
|
+
} : function (it) {
|
|
372
|
+
var $Symbol = getBuiltIn$6('Symbol');
|
|
373
|
+
return isCallable$h($Symbol) && isPrototypeOf$2($Symbol.prototype, $Object$2(it));
|
|
374
|
+
};
|
|
375
|
+
|
|
376
|
+
var $String$2 = String;
|
|
377
|
+
|
|
378
|
+
var tryToString$4 = function (argument) {
|
|
379
|
+
try {
|
|
380
|
+
return $String$2(argument);
|
|
381
|
+
} catch (error) {
|
|
382
|
+
return 'Object';
|
|
383
|
+
}
|
|
384
|
+
};
|
|
385
|
+
|
|
386
|
+
var isCallable$g = isCallable$k;
|
|
387
|
+
var tryToString$3 = tryToString$4;
|
|
388
|
+
|
|
389
|
+
var $TypeError$b = TypeError;
|
|
390
|
+
|
|
391
|
+
// `Assert: IsCallable(argument) is true`
|
|
392
|
+
var aCallable$9 = function (argument) {
|
|
393
|
+
if (isCallable$g(argument)) return argument;
|
|
394
|
+
throw new $TypeError$b(tryToString$3(argument) + ' is not a function');
|
|
395
|
+
};
|
|
396
|
+
|
|
397
|
+
var aCallable$8 = aCallable$9;
|
|
398
|
+
var isNullOrUndefined$2 = isNullOrUndefined$4;
|
|
399
|
+
|
|
400
|
+
// `GetMethod` abstract operation
|
|
401
|
+
// https://tc39.es/ecma262/#sec-getmethod
|
|
402
|
+
var getMethod$4 = function (V, P) {
|
|
403
|
+
var func = V[P];
|
|
404
|
+
return isNullOrUndefined$2(func) ? undefined : aCallable$8(func);
|
|
405
|
+
};
|
|
406
|
+
|
|
407
|
+
var call$d = functionCall;
|
|
408
|
+
var isCallable$f = isCallable$k;
|
|
409
|
+
var isObject$7 = isObject$a;
|
|
410
|
+
|
|
411
|
+
var $TypeError$a = TypeError;
|
|
412
|
+
|
|
413
|
+
// `OrdinaryToPrimitive` abstract operation
|
|
414
|
+
// https://tc39.es/ecma262/#sec-ordinarytoprimitive
|
|
415
|
+
var ordinaryToPrimitive$1 = function (input, pref) {
|
|
416
|
+
var fn, val;
|
|
417
|
+
if (pref === 'string' && isCallable$f(fn = input.toString) && !isObject$7(val = call$d(fn, input))) return val;
|
|
418
|
+
if (isCallable$f(fn = input.valueOf) && !isObject$7(val = call$d(fn, input))) return val;
|
|
419
|
+
if (pref !== 'string' && isCallable$f(fn = input.toString) && !isObject$7(val = call$d(fn, input))) return val;
|
|
420
|
+
throw new $TypeError$a("Can't convert object to primitive value");
|
|
421
|
+
};
|
|
422
|
+
|
|
423
|
+
var call$c = functionCall;
|
|
424
|
+
var isObject$6 = isObject$a;
|
|
425
|
+
var isSymbol$1 = isSymbol$2;
|
|
426
|
+
var getMethod$3 = getMethod$4;
|
|
427
|
+
var ordinaryToPrimitive = ordinaryToPrimitive$1;
|
|
428
|
+
var wellKnownSymbol$f = wellKnownSymbol$g;
|
|
429
|
+
|
|
430
|
+
var $TypeError$9 = TypeError;
|
|
431
|
+
var TO_PRIMITIVE = wellKnownSymbol$f('toPrimitive');
|
|
432
|
+
|
|
433
|
+
// `ToPrimitive` abstract operation
|
|
434
|
+
// https://tc39.es/ecma262/#sec-toprimitive
|
|
435
|
+
var toPrimitive$1 = function (input, pref) {
|
|
436
|
+
if (!isObject$6(input) || isSymbol$1(input)) return input;
|
|
437
|
+
var exoticToPrim = getMethod$3(input, TO_PRIMITIVE);
|
|
438
|
+
var result;
|
|
439
|
+
if (exoticToPrim) {
|
|
440
|
+
if (pref === undefined) pref = 'default';
|
|
441
|
+
result = call$c(exoticToPrim, input, pref);
|
|
442
|
+
if (!isObject$6(result) || isSymbol$1(result)) return result;
|
|
443
|
+
throw new $TypeError$9("Can't convert object to primitive value");
|
|
444
|
+
}
|
|
445
|
+
if (pref === undefined) pref = 'number';
|
|
446
|
+
return ordinaryToPrimitive(input, pref);
|
|
447
|
+
};
|
|
448
|
+
|
|
449
|
+
var toPrimitive = toPrimitive$1;
|
|
450
|
+
var isSymbol = isSymbol$2;
|
|
451
|
+
|
|
452
|
+
// `ToPropertyKey` abstract operation
|
|
453
|
+
// https://tc39.es/ecma262/#sec-topropertykey
|
|
454
|
+
var toPropertyKey$2 = function (argument) {
|
|
455
|
+
var key = toPrimitive(argument, 'string');
|
|
456
|
+
return isSymbol(key) ? key : key + '';
|
|
457
|
+
};
|
|
458
|
+
|
|
459
|
+
var DESCRIPTORS$b = descriptors;
|
|
460
|
+
var IE8_DOM_DEFINE$1 = ie8DomDefine;
|
|
461
|
+
var V8_PROTOTYPE_DEFINE_BUG$1 = v8PrototypeDefineBug;
|
|
462
|
+
var anObject$c = anObject$d;
|
|
463
|
+
var toPropertyKey$1 = toPropertyKey$2;
|
|
464
|
+
|
|
465
|
+
var $TypeError$8 = TypeError;
|
|
466
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
467
|
+
var $defineProperty = Object.defineProperty;
|
|
468
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
469
|
+
var $getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
|
|
470
|
+
var ENUMERABLE = 'enumerable';
|
|
471
|
+
var CONFIGURABLE$1 = 'configurable';
|
|
472
|
+
var WRITABLE = 'writable';
|
|
473
|
+
|
|
474
|
+
// `Object.defineProperty` method
|
|
475
|
+
// https://tc39.es/ecma262/#sec-object.defineproperty
|
|
476
|
+
objectDefineProperty.f = DESCRIPTORS$b ? V8_PROTOTYPE_DEFINE_BUG$1 ? function defineProperty(O, P, Attributes) {
|
|
477
|
+
anObject$c(O);
|
|
478
|
+
P = toPropertyKey$1(P);
|
|
479
|
+
anObject$c(Attributes);
|
|
480
|
+
if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {
|
|
481
|
+
var current = $getOwnPropertyDescriptor$1(O, P);
|
|
482
|
+
if (current && current[WRITABLE]) {
|
|
483
|
+
O[P] = Attributes.value;
|
|
484
|
+
Attributes = {
|
|
485
|
+
configurable: CONFIGURABLE$1 in Attributes ? Attributes[CONFIGURABLE$1] : current[CONFIGURABLE$1],
|
|
486
|
+
enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE],
|
|
487
|
+
writable: false
|
|
488
|
+
};
|
|
489
|
+
}
|
|
490
|
+
} return $defineProperty(O, P, Attributes);
|
|
491
|
+
} : $defineProperty : function defineProperty(O, P, Attributes) {
|
|
492
|
+
anObject$c(O);
|
|
493
|
+
P = toPropertyKey$1(P);
|
|
494
|
+
anObject$c(Attributes);
|
|
495
|
+
if (IE8_DOM_DEFINE$1) try {
|
|
496
|
+
return $defineProperty(O, P, Attributes);
|
|
497
|
+
} catch (error) { /* empty */ }
|
|
498
|
+
if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$8('Accessors not supported');
|
|
499
|
+
if ('value' in Attributes) O[P] = Attributes.value;
|
|
500
|
+
return O;
|
|
501
|
+
};
|
|
502
|
+
|
|
503
|
+
var ceil = Math.ceil;
|
|
504
|
+
var floor = Math.floor;
|
|
505
|
+
|
|
506
|
+
// `Math.trunc` method
|
|
507
|
+
// https://tc39.es/ecma262/#sec-math.trunc
|
|
508
|
+
// eslint-disable-next-line es/no-math-trunc -- safe
|
|
509
|
+
var mathTrunc = Math.trunc || function trunc(x) {
|
|
510
|
+
var n = +x;
|
|
511
|
+
return (n > 0 ? floor : ceil)(n);
|
|
512
|
+
};
|
|
513
|
+
|
|
514
|
+
var trunc = mathTrunc;
|
|
515
|
+
|
|
516
|
+
// `ToIntegerOrInfinity` abstract operation
|
|
517
|
+
// https://tc39.es/ecma262/#sec-tointegerorinfinity
|
|
518
|
+
var toIntegerOrInfinity$2 = function (argument) {
|
|
519
|
+
var number = +argument;
|
|
520
|
+
// eslint-disable-next-line no-self-compare -- NaN check
|
|
521
|
+
return number !== number || number === 0 ? 0 : trunc(number);
|
|
522
|
+
};
|
|
523
|
+
|
|
524
|
+
var toIntegerOrInfinity$1 = toIntegerOrInfinity$2;
|
|
525
|
+
|
|
526
|
+
var max = Math.max;
|
|
527
|
+
var min$1 = Math.min;
|
|
528
|
+
|
|
529
|
+
// Helper for a popular repeating case of the spec:
|
|
530
|
+
// Let integer be ? ToInteger(index).
|
|
531
|
+
// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
|
|
532
|
+
var toAbsoluteIndex$1 = function (index, length) {
|
|
533
|
+
var integer = toIntegerOrInfinity$1(index);
|
|
534
|
+
return integer < 0 ? max(integer + length, 0) : min$1(integer, length);
|
|
535
|
+
};
|
|
536
|
+
|
|
537
|
+
var toIntegerOrInfinity = toIntegerOrInfinity$2;
|
|
538
|
+
|
|
539
|
+
var min = Math.min;
|
|
540
|
+
|
|
541
|
+
// `ToLength` abstract operation
|
|
542
|
+
// https://tc39.es/ecma262/#sec-tolength
|
|
543
|
+
var toLength$1 = function (argument) {
|
|
544
|
+
var len = toIntegerOrInfinity(argument);
|
|
545
|
+
return len > 0 ? min(len, 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
|
|
546
|
+
};
|
|
547
|
+
|
|
548
|
+
var toLength = toLength$1;
|
|
549
|
+
|
|
550
|
+
// `LengthOfArrayLike` abstract operation
|
|
551
|
+
// https://tc39.es/ecma262/#sec-lengthofarraylike
|
|
552
|
+
var lengthOfArrayLike$2 = function (obj) {
|
|
553
|
+
return toLength(obj.length);
|
|
554
|
+
};
|
|
555
|
+
|
|
556
|
+
var toIndexedObject$4 = toIndexedObject$5;
|
|
557
|
+
var toAbsoluteIndex = toAbsoluteIndex$1;
|
|
558
|
+
var lengthOfArrayLike$1 = lengthOfArrayLike$2;
|
|
559
|
+
|
|
560
|
+
// `Array.prototype.{ indexOf, includes }` methods implementation
|
|
561
|
+
var createMethod = function (IS_INCLUDES) {
|
|
562
|
+
return function ($this, el, fromIndex) {
|
|
563
|
+
var O = toIndexedObject$4($this);
|
|
564
|
+
var length = lengthOfArrayLike$1(O);
|
|
565
|
+
if (length === 0) return !IS_INCLUDES && -1;
|
|
566
|
+
var index = toAbsoluteIndex(fromIndex, length);
|
|
567
|
+
var value;
|
|
568
|
+
// Array#includes uses SameValueZero equality algorithm
|
|
569
|
+
// eslint-disable-next-line no-self-compare -- NaN check
|
|
570
|
+
if (IS_INCLUDES && el !== el) while (length > index) {
|
|
571
|
+
value = O[index++];
|
|
572
|
+
// eslint-disable-next-line no-self-compare -- NaN check
|
|
573
|
+
if (value !== value) return true;
|
|
574
|
+
// Array#indexOf ignores holes, Array#includes - not
|
|
575
|
+
} else for (;length > index; index++) {
|
|
576
|
+
if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;
|
|
577
|
+
} return !IS_INCLUDES && -1;
|
|
578
|
+
};
|
|
579
|
+
};
|
|
580
|
+
|
|
581
|
+
var arrayIncludes = {
|
|
582
|
+
// `Array.prototype.indexOf` method
|
|
583
|
+
// https://tc39.es/ecma262/#sec-array.prototype.indexof
|
|
584
|
+
indexOf: createMethod(false)
|
|
585
|
+
};
|
|
586
|
+
|
|
587
|
+
var hiddenKeys$4 = {};
|
|
588
|
+
|
|
589
|
+
var uncurryThis$9 = functionUncurryThis;
|
|
590
|
+
var hasOwn$9 = hasOwnProperty_1;
|
|
591
|
+
var toIndexedObject$3 = toIndexedObject$5;
|
|
592
|
+
var indexOf = arrayIncludes.indexOf;
|
|
593
|
+
var hiddenKeys$3 = hiddenKeys$4;
|
|
594
|
+
|
|
595
|
+
var push = uncurryThis$9([].push);
|
|
596
|
+
|
|
597
|
+
var objectKeysInternal = function (object, names) {
|
|
598
|
+
var O = toIndexedObject$3(object);
|
|
599
|
+
var i = 0;
|
|
600
|
+
var result = [];
|
|
601
|
+
var key;
|
|
602
|
+
for (key in O) !hasOwn$9(hiddenKeys$3, key) && hasOwn$9(O, key) && push(result, key);
|
|
603
|
+
// Don't enum bug & hidden keys
|
|
604
|
+
while (names.length > i) if (hasOwn$9(O, key = names[i++])) {
|
|
605
|
+
~indexOf(result, key) || push(result, key);
|
|
606
|
+
}
|
|
607
|
+
return result;
|
|
608
|
+
};
|
|
609
|
+
|
|
610
|
+
// IE8- don't enum bug keys
|
|
611
|
+
var enumBugKeys$3 = [
|
|
612
|
+
'constructor',
|
|
613
|
+
'hasOwnProperty',
|
|
614
|
+
'isPrototypeOf',
|
|
615
|
+
'propertyIsEnumerable',
|
|
616
|
+
'toLocaleString',
|
|
617
|
+
'toString',
|
|
618
|
+
'valueOf'
|
|
619
|
+
];
|
|
620
|
+
|
|
621
|
+
var internalObjectKeys$1 = objectKeysInternal;
|
|
622
|
+
var enumBugKeys$2 = enumBugKeys$3;
|
|
623
|
+
|
|
624
|
+
// `Object.keys` method
|
|
625
|
+
// https://tc39.es/ecma262/#sec-object.keys
|
|
626
|
+
// eslint-disable-next-line es/no-object-keys -- safe
|
|
627
|
+
var objectKeys$2 = Object.keys || function keys(O) {
|
|
628
|
+
return internalObjectKeys$1(O, enumBugKeys$2);
|
|
629
|
+
};
|
|
630
|
+
|
|
631
|
+
var DESCRIPTORS$a = descriptors;
|
|
632
|
+
var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
|
|
633
|
+
var definePropertyModule$4 = objectDefineProperty;
|
|
634
|
+
var anObject$b = anObject$d;
|
|
635
|
+
var toIndexedObject$2 = toIndexedObject$5;
|
|
636
|
+
var objectKeys$1 = objectKeys$2;
|
|
637
|
+
|
|
638
|
+
// `Object.defineProperties` method
|
|
639
|
+
// https://tc39.es/ecma262/#sec-object.defineproperties
|
|
640
|
+
// eslint-disable-next-line es/no-object-defineproperties -- safe
|
|
641
|
+
objectDefineProperties.f = DESCRIPTORS$a && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
|
|
642
|
+
anObject$b(O);
|
|
643
|
+
var props = toIndexedObject$2(Properties);
|
|
644
|
+
var keys = objectKeys$1(Properties);
|
|
645
|
+
var length = keys.length;
|
|
646
|
+
var index = 0;
|
|
647
|
+
var key;
|
|
648
|
+
while (length > index) definePropertyModule$4.f(O, key = keys[index++], props[key]);
|
|
649
|
+
return O;
|
|
650
|
+
};
|
|
651
|
+
|
|
652
|
+
var getBuiltIn$5 = getBuiltIn$7;
|
|
653
|
+
|
|
654
|
+
var html$2 = getBuiltIn$5('document', 'documentElement');
|
|
655
|
+
|
|
656
|
+
var shared$1 = shared$3;
|
|
657
|
+
var uid = uid$2;
|
|
658
|
+
|
|
659
|
+
var keys = shared$1('keys');
|
|
660
|
+
|
|
661
|
+
var sharedKey$3 = function (key) {
|
|
662
|
+
return keys[key] || (keys[key] = uid(key));
|
|
663
|
+
};
|
|
664
|
+
|
|
665
|
+
/* global ActiveXObject -- old IE, WSH */
|
|
666
|
+
var anObject$a = anObject$d;
|
|
667
|
+
var definePropertiesModule = objectDefineProperties;
|
|
668
|
+
var enumBugKeys$1 = enumBugKeys$3;
|
|
669
|
+
var hiddenKeys$2 = hiddenKeys$4;
|
|
670
|
+
var html$1 = html$2;
|
|
671
|
+
var documentCreateElement$1 = documentCreateElement$2;
|
|
672
|
+
var sharedKey$2 = sharedKey$3;
|
|
673
|
+
|
|
674
|
+
var GT = '>';
|
|
675
|
+
var LT = '<';
|
|
676
|
+
var PROTOTYPE = 'prototype';
|
|
677
|
+
var SCRIPT = 'script';
|
|
678
|
+
var IE_PROTO$1 = sharedKey$2('IE_PROTO');
|
|
679
|
+
|
|
680
|
+
var EmptyConstructor = function () { /* empty */ };
|
|
681
|
+
|
|
682
|
+
var scriptTag = function (content) {
|
|
683
|
+
return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
|
|
684
|
+
};
|
|
685
|
+
|
|
686
|
+
// Create object with fake `null` prototype: use ActiveX Object with cleared prototype
|
|
687
|
+
var NullProtoObjectViaActiveX = function (activeXDocument) {
|
|
688
|
+
activeXDocument.write(scriptTag(''));
|
|
689
|
+
activeXDocument.close();
|
|
690
|
+
var temp = activeXDocument.parentWindow.Object;
|
|
691
|
+
// eslint-disable-next-line no-useless-assignment -- avoid memory leak
|
|
692
|
+
activeXDocument = null;
|
|
693
|
+
return temp;
|
|
694
|
+
};
|
|
695
|
+
|
|
696
|
+
// Create object with fake `null` prototype: use iframe Object with cleared prototype
|
|
697
|
+
var NullProtoObjectViaIFrame = function () {
|
|
698
|
+
// Thrash, waste and sodomy: IE GC bug
|
|
699
|
+
var iframe = documentCreateElement$1('iframe');
|
|
700
|
+
var JS = 'java' + SCRIPT + ':';
|
|
701
|
+
var iframeDocument;
|
|
702
|
+
iframe.style.display = 'none';
|
|
703
|
+
html$1.appendChild(iframe);
|
|
704
|
+
// https://github.com/zloirock/core-js/issues/475
|
|
705
|
+
iframe.src = String(JS);
|
|
706
|
+
iframeDocument = iframe.contentWindow.document;
|
|
707
|
+
iframeDocument.open();
|
|
708
|
+
iframeDocument.write(scriptTag('document.F=Object'));
|
|
709
|
+
iframeDocument.close();
|
|
710
|
+
return iframeDocument.F;
|
|
711
|
+
};
|
|
712
|
+
|
|
713
|
+
// Check for document.domain and active x support
|
|
714
|
+
// No need to use active x approach when document.domain is not set
|
|
715
|
+
// see https://github.com/es-shims/es5-shim/issues/150
|
|
716
|
+
// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
|
|
717
|
+
// avoid IE GC bug
|
|
718
|
+
var activeXDocument;
|
|
719
|
+
var NullProtoObject = function () {
|
|
720
|
+
try {
|
|
721
|
+
activeXDocument = new ActiveXObject('htmlfile');
|
|
722
|
+
} catch (error) { /* ignore */ }
|
|
723
|
+
NullProtoObject = typeof document != 'undefined'
|
|
724
|
+
? document.domain && activeXDocument
|
|
725
|
+
? NullProtoObjectViaActiveX(activeXDocument) // old IE
|
|
726
|
+
: NullProtoObjectViaIFrame()
|
|
727
|
+
: NullProtoObjectViaActiveX(activeXDocument); // WSH
|
|
728
|
+
var length = enumBugKeys$1.length;
|
|
729
|
+
while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys$1[length]];
|
|
730
|
+
return NullProtoObject();
|
|
731
|
+
};
|
|
732
|
+
|
|
733
|
+
hiddenKeys$2[IE_PROTO$1] = true;
|
|
734
|
+
|
|
735
|
+
// `Object.create` method
|
|
736
|
+
// https://tc39.es/ecma262/#sec-object.create
|
|
737
|
+
// eslint-disable-next-line es/no-object-create -- safe
|
|
738
|
+
var objectCreate = Object.create || function create(O, Properties) {
|
|
739
|
+
var result;
|
|
740
|
+
if (O !== null) {
|
|
741
|
+
EmptyConstructor[PROTOTYPE] = anObject$a(O);
|
|
742
|
+
result = new EmptyConstructor();
|
|
743
|
+
EmptyConstructor[PROTOTYPE] = null;
|
|
744
|
+
// add "__proto__" for Object.getPrototypeOf polyfill
|
|
745
|
+
result[IE_PROTO$1] = O;
|
|
746
|
+
} else result = NullProtoObject();
|
|
747
|
+
return Properties === undefined ? result : definePropertiesModule.f(result, Properties);
|
|
748
|
+
};
|
|
749
|
+
|
|
750
|
+
var wellKnownSymbol$e = wellKnownSymbol$g;
|
|
751
|
+
var create$2 = objectCreate;
|
|
752
|
+
var defineProperty$5 = objectDefineProperty.f;
|
|
753
|
+
|
|
754
|
+
var UNSCOPABLES = wellKnownSymbol$e('unscopables');
|
|
755
|
+
var ArrayPrototype$1 = Array.prototype;
|
|
756
|
+
|
|
757
|
+
// Array.prototype[@@unscopables]
|
|
758
|
+
// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
|
|
759
|
+
if (ArrayPrototype$1[UNSCOPABLES] === undefined) {
|
|
760
|
+
defineProperty$5(ArrayPrototype$1, UNSCOPABLES, {
|
|
761
|
+
configurable: true,
|
|
762
|
+
value: create$2(null)
|
|
763
|
+
});
|
|
764
|
+
}
|
|
765
|
+
|
|
766
|
+
// add a key to Array.prototype[@@unscopables]
|
|
767
|
+
var addToUnscopables$1 = function (key) {
|
|
768
|
+
ArrayPrototype$1[UNSCOPABLES][key] = true;
|
|
769
|
+
};
|
|
770
|
+
|
|
771
|
+
var iterators = {};
|
|
772
|
+
|
|
773
|
+
var globalThis$e = globalThis_1;
|
|
774
|
+
var isCallable$e = isCallable$k;
|
|
775
|
+
|
|
776
|
+
var WeakMap$1 = globalThis$e.WeakMap;
|
|
777
|
+
|
|
778
|
+
var weakMapBasicDetection = isCallable$e(WeakMap$1) && /native code/.test(String(WeakMap$1));
|
|
779
|
+
|
|
780
|
+
var createPropertyDescriptor$4 = function (bitmap, value) {
|
|
781
|
+
return {
|
|
782
|
+
enumerable: !(bitmap & 1),
|
|
783
|
+
configurable: !(bitmap & 2),
|
|
784
|
+
writable: !(bitmap & 4),
|
|
785
|
+
value: value
|
|
786
|
+
};
|
|
787
|
+
};
|
|
788
|
+
|
|
789
|
+
var DESCRIPTORS$9 = descriptors;
|
|
790
|
+
var definePropertyModule$3 = objectDefineProperty;
|
|
791
|
+
var createPropertyDescriptor$3 = createPropertyDescriptor$4;
|
|
792
|
+
|
|
793
|
+
var createNonEnumerableProperty$5 = DESCRIPTORS$9 ? function (object, key, value) {
|
|
794
|
+
return definePropertyModule$3.f(object, key, createPropertyDescriptor$3(1, value));
|
|
795
|
+
} : function (object, key, value) {
|
|
796
|
+
object[key] = value;
|
|
797
|
+
return object;
|
|
798
|
+
};
|
|
799
|
+
|
|
800
|
+
var NATIVE_WEAK_MAP = weakMapBasicDetection;
|
|
801
|
+
var globalThis$d = globalThis_1;
|
|
802
|
+
var isObject$5 = isObject$a;
|
|
803
|
+
var createNonEnumerableProperty$4 = createNonEnumerableProperty$5;
|
|
804
|
+
var hasOwn$8 = hasOwnProperty_1;
|
|
805
|
+
var shared = sharedStoreExports;
|
|
806
|
+
var sharedKey$1 = sharedKey$3;
|
|
807
|
+
var hiddenKeys$1 = hiddenKeys$4;
|
|
808
|
+
|
|
809
|
+
var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
|
|
810
|
+
var TypeError$2 = globalThis$d.TypeError;
|
|
811
|
+
var WeakMap = globalThis$d.WeakMap;
|
|
812
|
+
var set$1, get, has;
|
|
813
|
+
|
|
814
|
+
var enforce = function (it) {
|
|
815
|
+
return has(it) ? get(it) : set$1(it, {});
|
|
816
|
+
};
|
|
817
|
+
|
|
818
|
+
var getterFor = function (TYPE) {
|
|
819
|
+
return function (it) {
|
|
820
|
+
var state;
|
|
821
|
+
if (!isObject$5(it) || (state = get(it)).type !== TYPE) {
|
|
822
|
+
throw new TypeError$2('Incompatible receiver, ' + TYPE + ' required');
|
|
823
|
+
} return state;
|
|
824
|
+
};
|
|
825
|
+
};
|
|
826
|
+
|
|
827
|
+
if (NATIVE_WEAK_MAP || shared.state) {
|
|
828
|
+
var store$1 = shared.state || (shared.state = new WeakMap());
|
|
829
|
+
/* eslint-disable no-self-assign -- prototype methods protection */
|
|
830
|
+
store$1.get = store$1.get;
|
|
831
|
+
store$1.has = store$1.has;
|
|
832
|
+
store$1.set = store$1.set;
|
|
833
|
+
/* eslint-enable no-self-assign -- prototype methods protection */
|
|
834
|
+
set$1 = function (it, metadata) {
|
|
835
|
+
if (store$1.has(it)) throw new TypeError$2(OBJECT_ALREADY_INITIALIZED);
|
|
836
|
+
metadata.facade = it;
|
|
837
|
+
store$1.set(it, metadata);
|
|
838
|
+
return metadata;
|
|
839
|
+
};
|
|
840
|
+
get = function (it) {
|
|
841
|
+
return store$1.get(it) || {};
|
|
842
|
+
};
|
|
843
|
+
has = function (it) {
|
|
844
|
+
return store$1.has(it);
|
|
845
|
+
};
|
|
846
|
+
} else {
|
|
847
|
+
var STATE = sharedKey$1('state');
|
|
848
|
+
hiddenKeys$1[STATE] = true;
|
|
849
|
+
set$1 = function (it, metadata) {
|
|
850
|
+
if (hasOwn$8(it, STATE)) throw new TypeError$2(OBJECT_ALREADY_INITIALIZED);
|
|
851
|
+
metadata.facade = it;
|
|
852
|
+
createNonEnumerableProperty$4(it, STATE, metadata);
|
|
853
|
+
return metadata;
|
|
854
|
+
};
|
|
855
|
+
get = function (it) {
|
|
856
|
+
return hasOwn$8(it, STATE) ? it[STATE] : {};
|
|
857
|
+
};
|
|
858
|
+
has = function (it) {
|
|
859
|
+
return hasOwn$8(it, STATE);
|
|
860
|
+
};
|
|
861
|
+
}
|
|
862
|
+
|
|
863
|
+
var internalState = {
|
|
864
|
+
set: set$1,
|
|
865
|
+
get: get,
|
|
866
|
+
has: has,
|
|
867
|
+
enforce: enforce,
|
|
868
|
+
getterFor: getterFor
|
|
869
|
+
};
|
|
870
|
+
|
|
871
|
+
var objectGetOwnPropertyDescriptor = {};
|
|
872
|
+
|
|
873
|
+
var objectPropertyIsEnumerable = {};
|
|
874
|
+
|
|
875
|
+
var $propertyIsEnumerable = {}.propertyIsEnumerable;
|
|
876
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
877
|
+
var getOwnPropertyDescriptor$2 = Object.getOwnPropertyDescriptor;
|
|
878
|
+
|
|
879
|
+
// Nashorn ~ JDK8 bug
|
|
880
|
+
var NASHORN_BUG = getOwnPropertyDescriptor$2 && !$propertyIsEnumerable.call({ 1: 2 }, 1);
|
|
881
|
+
|
|
882
|
+
// `Object.prototype.propertyIsEnumerable` method implementation
|
|
883
|
+
// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
|
|
884
|
+
objectPropertyIsEnumerable.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
|
|
885
|
+
var descriptor = getOwnPropertyDescriptor$2(this, V);
|
|
886
|
+
return !!descriptor && descriptor.enumerable;
|
|
887
|
+
} : $propertyIsEnumerable;
|
|
888
|
+
|
|
889
|
+
var DESCRIPTORS$8 = descriptors;
|
|
890
|
+
var call$b = functionCall;
|
|
891
|
+
var propertyIsEnumerableModule$1 = objectPropertyIsEnumerable;
|
|
892
|
+
var createPropertyDescriptor$2 = createPropertyDescriptor$4;
|
|
893
|
+
var toIndexedObject$1 = toIndexedObject$5;
|
|
894
|
+
var toPropertyKey = toPropertyKey$2;
|
|
895
|
+
var hasOwn$7 = hasOwnProperty_1;
|
|
896
|
+
var IE8_DOM_DEFINE = ie8DomDefine;
|
|
897
|
+
|
|
898
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
899
|
+
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
900
|
+
|
|
901
|
+
// `Object.getOwnPropertyDescriptor` method
|
|
902
|
+
// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
|
|
903
|
+
objectGetOwnPropertyDescriptor.f = DESCRIPTORS$8 ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {
|
|
904
|
+
O = toIndexedObject$1(O);
|
|
905
|
+
P = toPropertyKey(P);
|
|
906
|
+
if (IE8_DOM_DEFINE) try {
|
|
907
|
+
return $getOwnPropertyDescriptor(O, P);
|
|
908
|
+
} catch (error) { /* empty */ }
|
|
909
|
+
if (hasOwn$7(O, P)) return createPropertyDescriptor$2(!call$b(propertyIsEnumerableModule$1.f, O, P), O[P]);
|
|
910
|
+
};
|
|
911
|
+
|
|
912
|
+
var makeBuiltIn$3 = {exports: {}};
|
|
913
|
+
|
|
914
|
+
var DESCRIPTORS$7 = descriptors;
|
|
915
|
+
var hasOwn$6 = hasOwnProperty_1;
|
|
916
|
+
|
|
917
|
+
var FunctionPrototype$1 = Function.prototype;
|
|
918
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
919
|
+
var getDescriptor = DESCRIPTORS$7 && Object.getOwnPropertyDescriptor;
|
|
920
|
+
|
|
921
|
+
var EXISTS = hasOwn$6(FunctionPrototype$1, 'name');
|
|
922
|
+
// additional protection from minified / mangled / dropped function names
|
|
923
|
+
var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
|
|
924
|
+
var CONFIGURABLE = EXISTS && (!DESCRIPTORS$7 || (DESCRIPTORS$7 && getDescriptor(FunctionPrototype$1, 'name').configurable));
|
|
925
|
+
|
|
926
|
+
var functionName = {
|
|
927
|
+
PROPER: PROPER,
|
|
928
|
+
CONFIGURABLE: CONFIGURABLE
|
|
929
|
+
};
|
|
930
|
+
|
|
931
|
+
var uncurryThis$8 = functionUncurryThis;
|
|
932
|
+
var isCallable$d = isCallable$k;
|
|
933
|
+
var store = sharedStoreExports;
|
|
934
|
+
|
|
935
|
+
var functionToString = uncurryThis$8(Function.toString);
|
|
936
|
+
|
|
937
|
+
// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
|
|
938
|
+
if (!isCallable$d(store.inspectSource)) {
|
|
939
|
+
store.inspectSource = function (it) {
|
|
940
|
+
return functionToString(it);
|
|
941
|
+
};
|
|
942
|
+
}
|
|
943
|
+
|
|
944
|
+
var inspectSource$3 = store.inspectSource;
|
|
945
|
+
|
|
946
|
+
var uncurryThis$7 = functionUncurryThis;
|
|
947
|
+
var fails$7 = fails$e;
|
|
948
|
+
var isCallable$c = isCallable$k;
|
|
949
|
+
var hasOwn$5 = hasOwnProperty_1;
|
|
950
|
+
var DESCRIPTORS$6 = descriptors;
|
|
951
|
+
var CONFIGURABLE_FUNCTION_NAME$1 = functionName.CONFIGURABLE;
|
|
952
|
+
var inspectSource$2 = inspectSource$3;
|
|
953
|
+
var InternalStateModule$3 = internalState;
|
|
954
|
+
|
|
955
|
+
var enforceInternalState = InternalStateModule$3.enforce;
|
|
956
|
+
var getInternalState$1 = InternalStateModule$3.get;
|
|
957
|
+
var $String$1 = String;
|
|
958
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
959
|
+
var defineProperty$4 = Object.defineProperty;
|
|
960
|
+
var stringSlice = uncurryThis$7(''.slice);
|
|
961
|
+
var replace = uncurryThis$7(''.replace);
|
|
962
|
+
var join = uncurryThis$7([].join);
|
|
963
|
+
|
|
964
|
+
var CONFIGURABLE_LENGTH = DESCRIPTORS$6 && !fails$7(function () {
|
|
965
|
+
return defineProperty$4(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
|
|
966
|
+
});
|
|
967
|
+
|
|
968
|
+
var TEMPLATE = String(String).split('String');
|
|
969
|
+
|
|
970
|
+
var makeBuiltIn$2 = makeBuiltIn$3.exports = function (value, name, options) {
|
|
971
|
+
if (stringSlice($String$1(name), 0, 7) === 'Symbol(') {
|
|
972
|
+
name = '[' + replace($String$1(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
|
|
973
|
+
}
|
|
974
|
+
if (options && options.getter) name = 'get ' + name;
|
|
975
|
+
if (options && options.setter) name = 'set ' + name;
|
|
976
|
+
if (!hasOwn$5(value, 'name') || (CONFIGURABLE_FUNCTION_NAME$1 && value.name !== name)) {
|
|
977
|
+
if (DESCRIPTORS$6) defineProperty$4(value, 'name', { value: name, configurable: true });
|
|
978
|
+
else value.name = name;
|
|
979
|
+
}
|
|
980
|
+
if (CONFIGURABLE_LENGTH && options && hasOwn$5(options, 'arity') && value.length !== options.arity) {
|
|
981
|
+
defineProperty$4(value, 'length', { value: options.arity });
|
|
982
|
+
}
|
|
983
|
+
try {
|
|
984
|
+
if (options && hasOwn$5(options, 'constructor') && options.constructor) {
|
|
985
|
+
if (DESCRIPTORS$6) defineProperty$4(value, 'prototype', { writable: false });
|
|
986
|
+
// in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable
|
|
987
|
+
} else if (value.prototype) value.prototype = undefined;
|
|
988
|
+
} catch (error) { /* empty */ }
|
|
989
|
+
var state = enforceInternalState(value);
|
|
990
|
+
if (!hasOwn$5(state, 'source')) {
|
|
991
|
+
state.source = join(TEMPLATE, typeof name == 'string' ? name : '');
|
|
992
|
+
} return value;
|
|
993
|
+
};
|
|
994
|
+
|
|
995
|
+
// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
|
|
996
|
+
// eslint-disable-next-line no-extend-native -- required
|
|
997
|
+
Function.prototype.toString = makeBuiltIn$2(function toString() {
|
|
998
|
+
return isCallable$c(this) && getInternalState$1(this).source || inspectSource$2(this);
|
|
999
|
+
}, 'toString');
|
|
1000
|
+
|
|
1001
|
+
var makeBuiltInExports = makeBuiltIn$3.exports;
|
|
1002
|
+
|
|
1003
|
+
var isCallable$b = isCallable$k;
|
|
1004
|
+
var definePropertyModule$2 = objectDefineProperty;
|
|
1005
|
+
var makeBuiltIn$1 = makeBuiltInExports;
|
|
1006
|
+
var defineGlobalProperty$1 = defineGlobalProperty$3;
|
|
1007
|
+
|
|
1008
|
+
var defineBuiltIn$6 = function (O, key, value, options) {
|
|
1009
|
+
if (!options) options = {};
|
|
1010
|
+
var simple = options.enumerable;
|
|
1011
|
+
var name = options.name !== undefined ? options.name : key;
|
|
1012
|
+
if (isCallable$b(value)) makeBuiltIn$1(value, name, options);
|
|
1013
|
+
if (options.global) {
|
|
1014
|
+
if (simple) O[key] = value;
|
|
1015
|
+
else defineGlobalProperty$1(key, value);
|
|
1016
|
+
} else {
|
|
1017
|
+
try {
|
|
1018
|
+
if (!options.unsafe) delete O[key];
|
|
1019
|
+
else if (O[key]) simple = true;
|
|
1020
|
+
} catch (error) { /* empty */ }
|
|
1021
|
+
if (simple) O[key] = value;
|
|
1022
|
+
else definePropertyModule$2.f(O, key, {
|
|
1023
|
+
value: value,
|
|
1024
|
+
enumerable: false,
|
|
1025
|
+
configurable: !options.nonConfigurable,
|
|
1026
|
+
writable: !options.nonWritable
|
|
1027
|
+
});
|
|
1028
|
+
} return O;
|
|
1029
|
+
};
|
|
1030
|
+
|
|
1031
|
+
var objectGetOwnPropertyNames = {};
|
|
1032
|
+
|
|
1033
|
+
var internalObjectKeys = objectKeysInternal;
|
|
1034
|
+
var enumBugKeys = enumBugKeys$3;
|
|
1035
|
+
|
|
1036
|
+
var hiddenKeys = enumBugKeys.concat('length', 'prototype');
|
|
1037
|
+
|
|
1038
|
+
// `Object.getOwnPropertyNames` method
|
|
1039
|
+
// https://tc39.es/ecma262/#sec-object.getownpropertynames
|
|
1040
|
+
// eslint-disable-next-line es/no-object-getownpropertynames -- safe
|
|
1041
|
+
objectGetOwnPropertyNames.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
|
|
1042
|
+
return internalObjectKeys(O, hiddenKeys);
|
|
1043
|
+
};
|
|
1044
|
+
|
|
1045
|
+
var objectGetOwnPropertySymbols = {};
|
|
1046
|
+
|
|
1047
|
+
// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
|
|
1048
|
+
objectGetOwnPropertySymbols.f = Object.getOwnPropertySymbols;
|
|
1049
|
+
|
|
1050
|
+
var getBuiltIn$4 = getBuiltIn$7;
|
|
1051
|
+
var uncurryThis$6 = functionUncurryThis;
|
|
1052
|
+
var getOwnPropertyNamesModule = objectGetOwnPropertyNames;
|
|
1053
|
+
var getOwnPropertySymbolsModule$1 = objectGetOwnPropertySymbols;
|
|
1054
|
+
var anObject$9 = anObject$d;
|
|
1055
|
+
|
|
1056
|
+
var concat$1 = uncurryThis$6([].concat);
|
|
1057
|
+
|
|
1058
|
+
// all object keys, includes non-enumerable and symbols
|
|
1059
|
+
var ownKeys$1 = getBuiltIn$4('Reflect', 'ownKeys') || function ownKeys(it) {
|
|
1060
|
+
var keys = getOwnPropertyNamesModule.f(anObject$9(it));
|
|
1061
|
+
var getOwnPropertySymbols = getOwnPropertySymbolsModule$1.f;
|
|
1062
|
+
return getOwnPropertySymbols ? concat$1(keys, getOwnPropertySymbols(it)) : keys;
|
|
1063
|
+
};
|
|
1064
|
+
|
|
1065
|
+
var hasOwn$4 = hasOwnProperty_1;
|
|
1066
|
+
var ownKeys = ownKeys$1;
|
|
1067
|
+
var getOwnPropertyDescriptorModule = objectGetOwnPropertyDescriptor;
|
|
1068
|
+
var definePropertyModule$1 = objectDefineProperty;
|
|
1069
|
+
|
|
1070
|
+
var copyConstructorProperties$1 = function (target, source, exceptions) {
|
|
1071
|
+
var keys = ownKeys(source);
|
|
1072
|
+
var defineProperty = definePropertyModule$1.f;
|
|
1073
|
+
var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
|
|
1074
|
+
for (var i = 0; i < keys.length; i++) {
|
|
1075
|
+
var key = keys[i];
|
|
1076
|
+
if (!hasOwn$4(target, key) && !(exceptions && hasOwn$4(exceptions, key))) {
|
|
1077
|
+
defineProperty(target, key, getOwnPropertyDescriptor(source, key));
|
|
1078
|
+
}
|
|
1079
|
+
}
|
|
1080
|
+
};
|
|
1081
|
+
|
|
1082
|
+
var fails$6 = fails$e;
|
|
1083
|
+
var isCallable$a = isCallable$k;
|
|
1084
|
+
|
|
1085
|
+
var replacement = /#|\.prototype\./;
|
|
1086
|
+
|
|
1087
|
+
var isForced$2 = function (feature, detection) {
|
|
1088
|
+
var value = data[normalize(feature)];
|
|
1089
|
+
return value === POLYFILL ? true
|
|
1090
|
+
: value === NATIVE ? false
|
|
1091
|
+
: isCallable$a(detection) ? fails$6(detection)
|
|
1092
|
+
: !!detection;
|
|
1093
|
+
};
|
|
1094
|
+
|
|
1095
|
+
var normalize = isForced$2.normalize = function (string) {
|
|
1096
|
+
return String(string).replace(replacement, '.').toLowerCase();
|
|
1097
|
+
};
|
|
1098
|
+
|
|
1099
|
+
var data = isForced$2.data = {};
|
|
1100
|
+
var NATIVE = isForced$2.NATIVE = 'N';
|
|
1101
|
+
var POLYFILL = isForced$2.POLYFILL = 'P';
|
|
1102
|
+
|
|
1103
|
+
var isForced_1 = isForced$2;
|
|
1104
|
+
|
|
1105
|
+
var globalThis$c = globalThis_1;
|
|
1106
|
+
var getOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
|
|
1107
|
+
var createNonEnumerableProperty$3 = createNonEnumerableProperty$5;
|
|
1108
|
+
var defineBuiltIn$5 = defineBuiltIn$6;
|
|
1109
|
+
var defineGlobalProperty = defineGlobalProperty$3;
|
|
1110
|
+
var copyConstructorProperties = copyConstructorProperties$1;
|
|
1111
|
+
var isForced$1 = isForced_1;
|
|
1112
|
+
|
|
1113
|
+
/*
|
|
1114
|
+
options.target - name of the target object
|
|
1115
|
+
options.global - target is the global object
|
|
1116
|
+
options.stat - export as static methods of target
|
|
1117
|
+
options.proto - export as prototype methods of target
|
|
1118
|
+
options.real - real prototype method for the `pure` version
|
|
1119
|
+
options.forced - export even if the native feature is available
|
|
1120
|
+
options.bind - bind methods to the target, required for the `pure` version
|
|
1121
|
+
options.wrap - wrap constructors to preventing global pollution, required for the `pure` version
|
|
1122
|
+
options.unsafe - use the simple assignment of property instead of delete + defineProperty
|
|
1123
|
+
options.sham - add a flag to not completely full polyfills
|
|
1124
|
+
options.enumerable - export as enumerable property
|
|
1125
|
+
options.dontCallGetSet - prevent calling a getter on target
|
|
1126
|
+
options.name - the .name of the function if it does not match the key
|
|
1127
|
+
*/
|
|
1128
|
+
var _export = function (options, source) {
|
|
1129
|
+
var TARGET = options.target;
|
|
1130
|
+
var GLOBAL = options.global;
|
|
1131
|
+
var STATIC = options.stat;
|
|
1132
|
+
var FORCED, target, key, targetProperty, sourceProperty, descriptor;
|
|
1133
|
+
if (GLOBAL) {
|
|
1134
|
+
target = globalThis$c;
|
|
1135
|
+
} else if (STATIC) {
|
|
1136
|
+
target = globalThis$c[TARGET] || defineGlobalProperty(TARGET, {});
|
|
1137
|
+
} else {
|
|
1138
|
+
target = globalThis$c[TARGET] && globalThis$c[TARGET].prototype;
|
|
1139
|
+
}
|
|
1140
|
+
if (target) for (key in source) {
|
|
1141
|
+
sourceProperty = source[key];
|
|
1142
|
+
if (options.dontCallGetSet) {
|
|
1143
|
+
descriptor = getOwnPropertyDescriptor$1(target, key);
|
|
1144
|
+
targetProperty = descriptor && descriptor.value;
|
|
1145
|
+
} else targetProperty = target[key];
|
|
1146
|
+
FORCED = isForced$1(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
|
|
1147
|
+
// contained in target
|
|
1148
|
+
if (!FORCED && targetProperty !== undefined) {
|
|
1149
|
+
if (typeof sourceProperty == typeof targetProperty) continue;
|
|
1150
|
+
copyConstructorProperties(sourceProperty, targetProperty);
|
|
1151
|
+
}
|
|
1152
|
+
// add a flag to not completely full polyfills
|
|
1153
|
+
if (options.sham || (targetProperty && targetProperty.sham)) {
|
|
1154
|
+
createNonEnumerableProperty$3(sourceProperty, 'sham', true);
|
|
1155
|
+
}
|
|
1156
|
+
defineBuiltIn$5(target, key, sourceProperty, options);
|
|
1157
|
+
}
|
|
1158
|
+
};
|
|
1159
|
+
|
|
1160
|
+
var fails$5 = fails$e;
|
|
1161
|
+
|
|
1162
|
+
var correctPrototypeGetter = !fails$5(function () {
|
|
1163
|
+
function F() { /* empty */ }
|
|
1164
|
+
F.prototype.constructor = null;
|
|
1165
|
+
// eslint-disable-next-line es/no-object-getprototypeof -- required for testing
|
|
1166
|
+
return Object.getPrototypeOf(new F()) !== F.prototype;
|
|
1167
|
+
});
|
|
1168
|
+
|
|
1169
|
+
var hasOwn$3 = hasOwnProperty_1;
|
|
1170
|
+
var isCallable$9 = isCallable$k;
|
|
1171
|
+
var toObject$1 = toObject$3;
|
|
1172
|
+
var sharedKey = sharedKey$3;
|
|
1173
|
+
var CORRECT_PROTOTYPE_GETTER = correctPrototypeGetter;
|
|
1174
|
+
|
|
1175
|
+
var IE_PROTO = sharedKey('IE_PROTO');
|
|
1176
|
+
var $Object$1 = Object;
|
|
1177
|
+
var ObjectPrototype = $Object$1.prototype;
|
|
1178
|
+
|
|
1179
|
+
// `Object.getPrototypeOf` method
|
|
1180
|
+
// https://tc39.es/ecma262/#sec-object.getprototypeof
|
|
1181
|
+
// eslint-disable-next-line es/no-object-getprototypeof -- safe
|
|
1182
|
+
var objectGetPrototypeOf = CORRECT_PROTOTYPE_GETTER ? $Object$1.getPrototypeOf : function (O) {
|
|
1183
|
+
var object = toObject$1(O);
|
|
1184
|
+
if (hasOwn$3(object, IE_PROTO)) return object[IE_PROTO];
|
|
1185
|
+
var constructor = object.constructor;
|
|
1186
|
+
if (isCallable$9(constructor) && object instanceof constructor) {
|
|
1187
|
+
return constructor.prototype;
|
|
1188
|
+
} return object instanceof $Object$1 ? ObjectPrototype : null;
|
|
1189
|
+
};
|
|
1190
|
+
|
|
1191
|
+
var fails$4 = fails$e;
|
|
1192
|
+
var isCallable$8 = isCallable$k;
|
|
1193
|
+
var isObject$4 = isObject$a;
|
|
1194
|
+
var getPrototypeOf$2 = objectGetPrototypeOf;
|
|
1195
|
+
var defineBuiltIn$4 = defineBuiltIn$6;
|
|
1196
|
+
var wellKnownSymbol$d = wellKnownSymbol$g;
|
|
1197
|
+
|
|
1198
|
+
var ITERATOR$6 = wellKnownSymbol$d('iterator');
|
|
1199
|
+
var BUGGY_SAFARI_ITERATORS$1 = false;
|
|
1200
|
+
|
|
1201
|
+
// `%IteratorPrototype%` object
|
|
1202
|
+
// https://tc39.es/ecma262/#sec-%iteratorprototype%-object
|
|
1203
|
+
var IteratorPrototype$4, PrototypeOfArrayIteratorPrototype, arrayIterator;
|
|
1204
|
+
|
|
1205
|
+
/* eslint-disable es/no-array-prototype-keys -- safe */
|
|
1206
|
+
if ([].keys) {
|
|
1207
|
+
arrayIterator = [].keys();
|
|
1208
|
+
// Safari 8 has buggy iterators w/o `next`
|
|
1209
|
+
if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS$1 = true;
|
|
1210
|
+
else {
|
|
1211
|
+
PrototypeOfArrayIteratorPrototype = getPrototypeOf$2(getPrototypeOf$2(arrayIterator));
|
|
1212
|
+
if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype$4 = PrototypeOfArrayIteratorPrototype;
|
|
1213
|
+
}
|
|
1214
|
+
}
|
|
1215
|
+
|
|
1216
|
+
var NEW_ITERATOR_PROTOTYPE = !isObject$4(IteratorPrototype$4) || fails$4(function () {
|
|
1217
|
+
var test = {};
|
|
1218
|
+
// FF44- legacy iterators case
|
|
1219
|
+
return IteratorPrototype$4[ITERATOR$6].call(test) !== test;
|
|
1220
|
+
});
|
|
1221
|
+
|
|
1222
|
+
if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype$4 = {};
|
|
1223
|
+
|
|
1224
|
+
// `%IteratorPrototype%[@@iterator]()` method
|
|
1225
|
+
// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator
|
|
1226
|
+
if (!isCallable$8(IteratorPrototype$4[ITERATOR$6])) {
|
|
1227
|
+
defineBuiltIn$4(IteratorPrototype$4, ITERATOR$6, function () {
|
|
1228
|
+
return this;
|
|
1229
|
+
});
|
|
1230
|
+
}
|
|
1231
|
+
|
|
1232
|
+
var iteratorsCore = {
|
|
1233
|
+
IteratorPrototype: IteratorPrototype$4,
|
|
1234
|
+
BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS$1
|
|
1235
|
+
};
|
|
1236
|
+
|
|
1237
|
+
var defineProperty$3 = objectDefineProperty.f;
|
|
1238
|
+
var hasOwn$2 = hasOwnProperty_1;
|
|
1239
|
+
var wellKnownSymbol$c = wellKnownSymbol$g;
|
|
1240
|
+
|
|
1241
|
+
var TO_STRING_TAG$4 = wellKnownSymbol$c('toStringTag');
|
|
1242
|
+
|
|
1243
|
+
var setToStringTag$4 = function (target, TAG, STATIC) {
|
|
1244
|
+
if (target && !STATIC) target = target.prototype;
|
|
1245
|
+
if (target && !hasOwn$2(target, TO_STRING_TAG$4)) {
|
|
1246
|
+
defineProperty$3(target, TO_STRING_TAG$4, { configurable: true, value: TAG });
|
|
1247
|
+
}
|
|
1248
|
+
};
|
|
1249
|
+
|
|
1250
|
+
var IteratorPrototype$3 = iteratorsCore.IteratorPrototype;
|
|
1251
|
+
var create$1 = objectCreate;
|
|
1252
|
+
var createPropertyDescriptor$1 = createPropertyDescriptor$4;
|
|
1253
|
+
var setToStringTag$3 = setToStringTag$4;
|
|
1254
|
+
var Iterators$4 = iterators;
|
|
1255
|
+
|
|
1256
|
+
var returnThis$1 = function () { return this; };
|
|
1257
|
+
|
|
1258
|
+
var iteratorCreateConstructor = function (IteratorConstructor, NAME, next, ENUMERABLE_NEXT) {
|
|
1259
|
+
var TO_STRING_TAG = NAME + ' Iterator';
|
|
1260
|
+
IteratorConstructor.prototype = create$1(IteratorPrototype$3, { next: createPropertyDescriptor$1(+!ENUMERABLE_NEXT, next) });
|
|
1261
|
+
setToStringTag$3(IteratorConstructor, TO_STRING_TAG, false);
|
|
1262
|
+
Iterators$4[TO_STRING_TAG] = returnThis$1;
|
|
1263
|
+
return IteratorConstructor;
|
|
1264
|
+
};
|
|
1265
|
+
|
|
1266
|
+
var uncurryThis$5 = functionUncurryThis;
|
|
1267
|
+
var aCallable$7 = aCallable$9;
|
|
1268
|
+
|
|
1269
|
+
var functionUncurryThisAccessor = function (object, key, method) {
|
|
1270
|
+
try {
|
|
1271
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
1272
|
+
return uncurryThis$5(aCallable$7(Object.getOwnPropertyDescriptor(object, key)[method]));
|
|
1273
|
+
} catch (error) { /* empty */ }
|
|
1274
|
+
};
|
|
1275
|
+
|
|
1276
|
+
var isObject$3 = isObject$a;
|
|
1277
|
+
|
|
1278
|
+
var isPossiblePrototype$1 = function (argument) {
|
|
1279
|
+
return isObject$3(argument) || argument === null;
|
|
1280
|
+
};
|
|
1281
|
+
|
|
1282
|
+
var isPossiblePrototype = isPossiblePrototype$1;
|
|
1283
|
+
|
|
1284
|
+
var $String = String;
|
|
1285
|
+
var $TypeError$7 = TypeError;
|
|
1286
|
+
|
|
1287
|
+
var aPossiblePrototype$1 = function (argument) {
|
|
1288
|
+
if (isPossiblePrototype(argument)) return argument;
|
|
1289
|
+
throw new $TypeError$7("Can't set " + $String(argument) + ' as a prototype');
|
|
1290
|
+
};
|
|
1291
|
+
|
|
1292
|
+
/* eslint-disable no-proto -- safe */
|
|
1293
|
+
var uncurryThisAccessor = functionUncurryThisAccessor;
|
|
1294
|
+
var isObject$2 = isObject$a;
|
|
1295
|
+
var requireObjectCoercible = requireObjectCoercible$3;
|
|
1296
|
+
var aPossiblePrototype = aPossiblePrototype$1;
|
|
1297
|
+
|
|
1298
|
+
// `Object.setPrototypeOf` method
|
|
1299
|
+
// https://tc39.es/ecma262/#sec-object.setprototypeof
|
|
1300
|
+
// Works with __proto__ only. Old v8 can't work with null proto objects.
|
|
1301
|
+
// eslint-disable-next-line es/no-object-setprototypeof -- safe
|
|
1302
|
+
var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? function () {
|
|
1303
|
+
var CORRECT_SETTER = false;
|
|
1304
|
+
var test = {};
|
|
1305
|
+
var setter;
|
|
1306
|
+
try {
|
|
1307
|
+
setter = uncurryThisAccessor(Object.prototype, '__proto__', 'set');
|
|
1308
|
+
setter(test, []);
|
|
1309
|
+
CORRECT_SETTER = test instanceof Array;
|
|
1310
|
+
} catch (error) { /* empty */ }
|
|
1311
|
+
return function setPrototypeOf(O, proto) {
|
|
1312
|
+
requireObjectCoercible(O);
|
|
1313
|
+
aPossiblePrototype(proto);
|
|
1314
|
+
if (!isObject$2(O)) return O;
|
|
1315
|
+
if (CORRECT_SETTER) setter(O, proto);
|
|
1316
|
+
else O.__proto__ = proto;
|
|
1317
|
+
return O;
|
|
1318
|
+
};
|
|
1319
|
+
}() : undefined);
|
|
1320
|
+
|
|
1321
|
+
var $$a = _export;
|
|
1322
|
+
var call$a = functionCall;
|
|
1323
|
+
var FunctionName = functionName;
|
|
1324
|
+
var isCallable$7 = isCallable$k;
|
|
1325
|
+
var createIteratorConstructor = iteratorCreateConstructor;
|
|
1326
|
+
var getPrototypeOf$1 = objectGetPrototypeOf;
|
|
1327
|
+
var setPrototypeOf$1 = objectSetPrototypeOf;
|
|
1328
|
+
var setToStringTag$2 = setToStringTag$4;
|
|
1329
|
+
var createNonEnumerableProperty$2 = createNonEnumerableProperty$5;
|
|
1330
|
+
var defineBuiltIn$3 = defineBuiltIn$6;
|
|
1331
|
+
var wellKnownSymbol$b = wellKnownSymbol$g;
|
|
1332
|
+
var Iterators$3 = iterators;
|
|
1333
|
+
var IteratorsCore = iteratorsCore;
|
|
1334
|
+
|
|
1335
|
+
var PROPER_FUNCTION_NAME = FunctionName.PROPER;
|
|
1336
|
+
var CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE;
|
|
1337
|
+
var IteratorPrototype$2 = IteratorsCore.IteratorPrototype;
|
|
1338
|
+
var BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;
|
|
1339
|
+
var ITERATOR$5 = wellKnownSymbol$b('iterator');
|
|
1340
|
+
var KEYS = 'keys';
|
|
1341
|
+
var VALUES = 'values';
|
|
1342
|
+
var ENTRIES = 'entries';
|
|
1343
|
+
|
|
1344
|
+
var returnThis = function () { return this; };
|
|
1345
|
+
|
|
1346
|
+
var iteratorDefine = function (Iterable, NAME, IteratorConstructor, next, DEFAULT, IS_SET, FORCED) {
|
|
1347
|
+
createIteratorConstructor(IteratorConstructor, NAME, next);
|
|
1348
|
+
|
|
1349
|
+
var getIterationMethod = function (KIND) {
|
|
1350
|
+
if (KIND === DEFAULT && defaultIterator) return defaultIterator;
|
|
1351
|
+
if (!BUGGY_SAFARI_ITERATORS && KIND && KIND in IterablePrototype) return IterablePrototype[KIND];
|
|
1352
|
+
|
|
1353
|
+
switch (KIND) {
|
|
1354
|
+
case KEYS: return function keys() { return new IteratorConstructor(this, KIND); };
|
|
1355
|
+
case VALUES: return function values() { return new IteratorConstructor(this, KIND); };
|
|
1356
|
+
case ENTRIES: return function entries() { return new IteratorConstructor(this, KIND); };
|
|
1357
|
+
}
|
|
1358
|
+
|
|
1359
|
+
return function () { return new IteratorConstructor(this); };
|
|
1360
|
+
};
|
|
1361
|
+
|
|
1362
|
+
var TO_STRING_TAG = NAME + ' Iterator';
|
|
1363
|
+
var INCORRECT_VALUES_NAME = false;
|
|
1364
|
+
var IterablePrototype = Iterable.prototype;
|
|
1365
|
+
var nativeIterator = IterablePrototype[ITERATOR$5]
|
|
1366
|
+
|| IterablePrototype['@@iterator']
|
|
1367
|
+
|| DEFAULT && IterablePrototype[DEFAULT];
|
|
1368
|
+
var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);
|
|
1369
|
+
var anyNativeIterator = NAME === 'Array' ? IterablePrototype.entries || nativeIterator : nativeIterator;
|
|
1370
|
+
var CurrentIteratorPrototype, methods, KEY;
|
|
1371
|
+
|
|
1372
|
+
// fix native
|
|
1373
|
+
if (anyNativeIterator) {
|
|
1374
|
+
CurrentIteratorPrototype = getPrototypeOf$1(anyNativeIterator.call(new Iterable()));
|
|
1375
|
+
if (CurrentIteratorPrototype !== Object.prototype && CurrentIteratorPrototype.next) {
|
|
1376
|
+
if (getPrototypeOf$1(CurrentIteratorPrototype) !== IteratorPrototype$2) {
|
|
1377
|
+
if (setPrototypeOf$1) {
|
|
1378
|
+
setPrototypeOf$1(CurrentIteratorPrototype, IteratorPrototype$2);
|
|
1379
|
+
} else if (!isCallable$7(CurrentIteratorPrototype[ITERATOR$5])) {
|
|
1380
|
+
defineBuiltIn$3(CurrentIteratorPrototype, ITERATOR$5, returnThis);
|
|
1381
|
+
}
|
|
1382
|
+
}
|
|
1383
|
+
// Set @@toStringTag to native iterators
|
|
1384
|
+
setToStringTag$2(CurrentIteratorPrototype, TO_STRING_TAG, true);
|
|
1385
|
+
}
|
|
1386
|
+
}
|
|
1387
|
+
|
|
1388
|
+
// fix Array.prototype.{ values, @@iterator }.name in V8 / FF
|
|
1389
|
+
if (PROPER_FUNCTION_NAME && DEFAULT === VALUES && nativeIterator && nativeIterator.name !== VALUES) {
|
|
1390
|
+
if (CONFIGURABLE_FUNCTION_NAME) {
|
|
1391
|
+
createNonEnumerableProperty$2(IterablePrototype, 'name', VALUES);
|
|
1392
|
+
} else {
|
|
1393
|
+
INCORRECT_VALUES_NAME = true;
|
|
1394
|
+
defaultIterator = function values() { return call$a(nativeIterator, this); };
|
|
1395
|
+
}
|
|
1396
|
+
}
|
|
1397
|
+
|
|
1398
|
+
// export additional methods
|
|
1399
|
+
if (DEFAULT) {
|
|
1400
|
+
methods = {
|
|
1401
|
+
values: getIterationMethod(VALUES),
|
|
1402
|
+
keys: IS_SET ? defaultIterator : getIterationMethod(KEYS),
|
|
1403
|
+
entries: getIterationMethod(ENTRIES)
|
|
1404
|
+
};
|
|
1405
|
+
if (FORCED) for (KEY in methods) {
|
|
1406
|
+
if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {
|
|
1407
|
+
defineBuiltIn$3(IterablePrototype, KEY, methods[KEY]);
|
|
1408
|
+
}
|
|
1409
|
+
} else $$a({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);
|
|
1410
|
+
}
|
|
1411
|
+
|
|
1412
|
+
// define iterator
|
|
1413
|
+
if (IterablePrototype[ITERATOR$5] !== defaultIterator) {
|
|
1414
|
+
defineBuiltIn$3(IterablePrototype, ITERATOR$5, defaultIterator, { name: DEFAULT });
|
|
1415
|
+
}
|
|
1416
|
+
Iterators$3[NAME] = defaultIterator;
|
|
1417
|
+
|
|
1418
|
+
return methods;
|
|
1419
|
+
};
|
|
1420
|
+
|
|
1421
|
+
// `CreateIterResultObject` abstract operation
|
|
1422
|
+
// https://tc39.es/ecma262/#sec-createiterresultobject
|
|
1423
|
+
var createIterResultObject$2 = function (value, done) {
|
|
1424
|
+
return { value: value, done: done };
|
|
1425
|
+
};
|
|
1426
|
+
|
|
1427
|
+
var toIndexedObject = toIndexedObject$5;
|
|
1428
|
+
var addToUnscopables = addToUnscopables$1;
|
|
1429
|
+
var Iterators$2 = iterators;
|
|
1430
|
+
var InternalStateModule$2 = internalState;
|
|
1431
|
+
var defineProperty$2 = objectDefineProperty.f;
|
|
1432
|
+
var defineIterator = iteratorDefine;
|
|
1433
|
+
var createIterResultObject$1 = createIterResultObject$2;
|
|
1434
|
+
var DESCRIPTORS$5 = descriptors;
|
|
1435
|
+
|
|
1436
|
+
var ARRAY_ITERATOR = 'Array Iterator';
|
|
1437
|
+
var setInternalState$2 = InternalStateModule$2.set;
|
|
1438
|
+
var getInternalState = InternalStateModule$2.getterFor(ARRAY_ITERATOR);
|
|
1439
|
+
|
|
1440
|
+
// `Array.prototype.entries` method
|
|
1441
|
+
// https://tc39.es/ecma262/#sec-array.prototype.entries
|
|
1442
|
+
// `Array.prototype.keys` method
|
|
1443
|
+
// https://tc39.es/ecma262/#sec-array.prototype.keys
|
|
1444
|
+
// `Array.prototype.values` method
|
|
1445
|
+
// https://tc39.es/ecma262/#sec-array.prototype.values
|
|
1446
|
+
// `Array.prototype[@@iterator]` method
|
|
1447
|
+
// https://tc39.es/ecma262/#sec-array.prototype-@@iterator
|
|
1448
|
+
// `CreateArrayIterator` internal method
|
|
1449
|
+
// https://tc39.es/ecma262/#sec-createarrayiterator
|
|
1450
|
+
var es_array_iterator = defineIterator(Array, 'Array', function (iterated, kind) {
|
|
1451
|
+
setInternalState$2(this, {
|
|
1452
|
+
type: ARRAY_ITERATOR,
|
|
1453
|
+
target: toIndexedObject(iterated), // target
|
|
1454
|
+
index: 0, // next index
|
|
1455
|
+
kind: kind // kind
|
|
1456
|
+
});
|
|
1457
|
+
// `%ArrayIteratorPrototype%.next` method
|
|
1458
|
+
// https://tc39.es/ecma262/#sec-%arrayiteratorprototype%.next
|
|
1459
|
+
}, function () {
|
|
1460
|
+
var state = getInternalState(this);
|
|
1461
|
+
var target = state.target;
|
|
1462
|
+
var index = state.index++;
|
|
1463
|
+
if (!target || index >= target.length) {
|
|
1464
|
+
state.target = null;
|
|
1465
|
+
return createIterResultObject$1(undefined, true);
|
|
1466
|
+
}
|
|
1467
|
+
switch (state.kind) {
|
|
1468
|
+
case 'keys': return createIterResultObject$1(index, false);
|
|
1469
|
+
case 'values': return createIterResultObject$1(target[index], false);
|
|
1470
|
+
} return createIterResultObject$1([index, target[index]], false);
|
|
1471
|
+
}, 'values');
|
|
1472
|
+
|
|
1473
|
+
// argumentsList[@@iterator] is %ArrayProto_values%
|
|
1474
|
+
// https://tc39.es/ecma262/#sec-createunmappedargumentsobject
|
|
1475
|
+
// https://tc39.es/ecma262/#sec-createmappedargumentsobject
|
|
1476
|
+
var values = Iterators$2.Arguments = Iterators$2.Array;
|
|
1477
|
+
|
|
1478
|
+
// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
|
|
1479
|
+
addToUnscopables('keys');
|
|
1480
|
+
addToUnscopables('values');
|
|
1481
|
+
addToUnscopables('entries');
|
|
1482
|
+
|
|
1483
|
+
// V8 ~ Chrome 45- bug
|
|
1484
|
+
if (DESCRIPTORS$5 && values.name !== 'values') try {
|
|
1485
|
+
defineProperty$2(values, 'name', { value: 'values' });
|
|
1486
|
+
} catch (error) { /* empty */ }
|
|
1487
|
+
|
|
1488
|
+
var isPrototypeOf$1 = objectIsPrototypeOf;
|
|
1489
|
+
|
|
1490
|
+
var $TypeError$6 = TypeError;
|
|
1491
|
+
|
|
1492
|
+
var anInstance$2 = function (it, Prototype) {
|
|
1493
|
+
if (isPrototypeOf$1(Prototype, it)) return it;
|
|
1494
|
+
throw new $TypeError$6('Incorrect invocation');
|
|
1495
|
+
};
|
|
1496
|
+
|
|
1497
|
+
var makeBuiltIn = makeBuiltInExports;
|
|
1498
|
+
var defineProperty$1 = objectDefineProperty;
|
|
1499
|
+
|
|
1500
|
+
var defineBuiltInAccessor$2 = function (target, name, descriptor) {
|
|
1501
|
+
if (descriptor.get) makeBuiltIn(descriptor.get, name, { getter: true });
|
|
1502
|
+
if (descriptor.set) makeBuiltIn(descriptor.set, name, { setter: true });
|
|
1503
|
+
return defineProperty$1.f(target, name, descriptor);
|
|
1504
|
+
};
|
|
1505
|
+
|
|
1506
|
+
var DESCRIPTORS$4 = descriptors;
|
|
1507
|
+
var definePropertyModule = objectDefineProperty;
|
|
1508
|
+
var createPropertyDescriptor = createPropertyDescriptor$4;
|
|
1509
|
+
|
|
1510
|
+
var createProperty$2 = function (object, key, value) {
|
|
1511
|
+
if (DESCRIPTORS$4) definePropertyModule.f(object, key, createPropertyDescriptor(0, value));
|
|
1512
|
+
else object[key] = value;
|
|
1513
|
+
};
|
|
1514
|
+
|
|
1515
|
+
var $$9 = _export;
|
|
1516
|
+
var globalThis$b = globalThis_1;
|
|
1517
|
+
var anInstance$1 = anInstance$2;
|
|
1518
|
+
var anObject$8 = anObject$d;
|
|
1519
|
+
var isCallable$6 = isCallable$k;
|
|
1520
|
+
var getPrototypeOf = objectGetPrototypeOf;
|
|
1521
|
+
var defineBuiltInAccessor$1 = defineBuiltInAccessor$2;
|
|
1522
|
+
var createProperty$1 = createProperty$2;
|
|
1523
|
+
var fails$3 = fails$e;
|
|
1524
|
+
var hasOwn$1 = hasOwnProperty_1;
|
|
1525
|
+
var wellKnownSymbol$a = wellKnownSymbol$g;
|
|
1526
|
+
var IteratorPrototype$1 = iteratorsCore.IteratorPrototype;
|
|
1527
|
+
var DESCRIPTORS$3 = descriptors;
|
|
1528
|
+
|
|
1529
|
+
var CONSTRUCTOR = 'constructor';
|
|
1530
|
+
var ITERATOR$4 = 'Iterator';
|
|
1531
|
+
var TO_STRING_TAG$3 = wellKnownSymbol$a('toStringTag');
|
|
1532
|
+
|
|
1533
|
+
var $TypeError$5 = TypeError;
|
|
1534
|
+
var NativeIterator = globalThis$b[ITERATOR$4];
|
|
1535
|
+
|
|
1536
|
+
// FF56- have non-standard global helper `Iterator`
|
|
1537
|
+
var FORCED$1 = !isCallable$6(NativeIterator)
|
|
1538
|
+
|| NativeIterator.prototype !== IteratorPrototype$1
|
|
1539
|
+
// FF44- non-standard `Iterator` passes previous tests
|
|
1540
|
+
|| !fails$3(function () { NativeIterator({}); });
|
|
1541
|
+
|
|
1542
|
+
var IteratorConstructor = function Iterator() {
|
|
1543
|
+
anInstance$1(this, IteratorPrototype$1);
|
|
1544
|
+
if (getPrototypeOf(this) === IteratorPrototype$1) throw new $TypeError$5('Abstract class Iterator not directly constructable');
|
|
1545
|
+
};
|
|
1546
|
+
|
|
1547
|
+
var defineIteratorPrototypeAccessor = function (key, value) {
|
|
1548
|
+
if (DESCRIPTORS$3) {
|
|
1549
|
+
defineBuiltInAccessor$1(IteratorPrototype$1, key, {
|
|
1550
|
+
configurable: true,
|
|
1551
|
+
get: function () {
|
|
1552
|
+
return value;
|
|
1553
|
+
},
|
|
1554
|
+
set: function (replacement) {
|
|
1555
|
+
anObject$8(this);
|
|
1556
|
+
if (this === IteratorPrototype$1) throw new $TypeError$5("You can't redefine this property");
|
|
1557
|
+
if (hasOwn$1(this, key)) this[key] = replacement;
|
|
1558
|
+
else createProperty$1(this, key, replacement);
|
|
1559
|
+
}
|
|
1560
|
+
});
|
|
1561
|
+
} else IteratorPrototype$1[key] = value;
|
|
1562
|
+
};
|
|
1563
|
+
|
|
1564
|
+
if (!hasOwn$1(IteratorPrototype$1, TO_STRING_TAG$3)) defineIteratorPrototypeAccessor(TO_STRING_TAG$3, ITERATOR$4);
|
|
1565
|
+
|
|
1566
|
+
if (FORCED$1 || !hasOwn$1(IteratorPrototype$1, CONSTRUCTOR) || IteratorPrototype$1[CONSTRUCTOR] === Object) {
|
|
1567
|
+
defineIteratorPrototypeAccessor(CONSTRUCTOR, IteratorConstructor);
|
|
1568
|
+
}
|
|
1569
|
+
|
|
1570
|
+
IteratorConstructor.prototype = IteratorPrototype$1;
|
|
1571
|
+
|
|
1572
|
+
// `Iterator` constructor
|
|
1573
|
+
// https://tc39.es/ecma262/#sec-iterator
|
|
1574
|
+
$$9({ global: true, constructor: true, forced: FORCED$1 }, {
|
|
1575
|
+
Iterator: IteratorConstructor
|
|
1576
|
+
});
|
|
1577
|
+
|
|
1578
|
+
// `GetIteratorDirect(obj)` abstract operation
|
|
1579
|
+
// https://tc39.es/ecma262/#sec-getiteratordirect
|
|
1580
|
+
var getIteratorDirect$2 = function (obj) {
|
|
1581
|
+
return {
|
|
1582
|
+
iterator: obj,
|
|
1583
|
+
next: obj.next,
|
|
1584
|
+
done: false
|
|
1585
|
+
};
|
|
1586
|
+
};
|
|
1587
|
+
|
|
1588
|
+
var defineBuiltIn$2 = defineBuiltIn$6;
|
|
1589
|
+
|
|
1590
|
+
var defineBuiltIns$1 = function (target, src, options) {
|
|
1591
|
+
for (var key in src) defineBuiltIn$2(target, key, src[key], options);
|
|
1592
|
+
return target;
|
|
1593
|
+
};
|
|
1594
|
+
|
|
1595
|
+
var call$9 = functionCall;
|
|
1596
|
+
var anObject$7 = anObject$d;
|
|
1597
|
+
var getMethod$2 = getMethod$4;
|
|
1598
|
+
|
|
1599
|
+
var iteratorClose$5 = function (iterator, kind, value) {
|
|
1600
|
+
var innerResult, innerError;
|
|
1601
|
+
anObject$7(iterator);
|
|
1602
|
+
try {
|
|
1603
|
+
innerResult = getMethod$2(iterator, 'return');
|
|
1604
|
+
if (!innerResult) {
|
|
1605
|
+
if (kind === 'throw') throw value;
|
|
1606
|
+
return value;
|
|
1607
|
+
}
|
|
1608
|
+
innerResult = call$9(innerResult, iterator);
|
|
1609
|
+
} catch (error) {
|
|
1610
|
+
innerError = true;
|
|
1611
|
+
innerResult = error;
|
|
1612
|
+
}
|
|
1613
|
+
if (kind === 'throw') throw value;
|
|
1614
|
+
if (innerError) throw innerResult;
|
|
1615
|
+
anObject$7(innerResult);
|
|
1616
|
+
return value;
|
|
1617
|
+
};
|
|
1618
|
+
|
|
1619
|
+
var iteratorClose$4 = iteratorClose$5;
|
|
1620
|
+
|
|
1621
|
+
var iteratorCloseAll$1 = function (iters, kind, value) {
|
|
1622
|
+
for (var i = iters.length - 1; i >= 0; i--) {
|
|
1623
|
+
if (iters[i] === undefined) continue;
|
|
1624
|
+
try {
|
|
1625
|
+
value = iteratorClose$4(iters[i].iterator, kind, value);
|
|
1626
|
+
} catch (error) {
|
|
1627
|
+
kind = 'throw';
|
|
1628
|
+
value = error;
|
|
1629
|
+
}
|
|
1630
|
+
}
|
|
1631
|
+
if (kind === 'throw') throw value;
|
|
1632
|
+
return value;
|
|
1633
|
+
};
|
|
1634
|
+
|
|
1635
|
+
var call$8 = functionCall;
|
|
1636
|
+
var create = objectCreate;
|
|
1637
|
+
var createNonEnumerableProperty$1 = createNonEnumerableProperty$5;
|
|
1638
|
+
var defineBuiltIns = defineBuiltIns$1;
|
|
1639
|
+
var wellKnownSymbol$9 = wellKnownSymbol$g;
|
|
1640
|
+
var InternalStateModule$1 = internalState;
|
|
1641
|
+
var getMethod$1 = getMethod$4;
|
|
1642
|
+
var IteratorPrototype = iteratorsCore.IteratorPrototype;
|
|
1643
|
+
var createIterResultObject = createIterResultObject$2;
|
|
1644
|
+
var iteratorClose$3 = iteratorClose$5;
|
|
1645
|
+
var iteratorCloseAll = iteratorCloseAll$1;
|
|
1646
|
+
|
|
1647
|
+
var TO_STRING_TAG$2 = wellKnownSymbol$9('toStringTag');
|
|
1648
|
+
var ITERATOR_HELPER = 'IteratorHelper';
|
|
1649
|
+
var WRAP_FOR_VALID_ITERATOR = 'WrapForValidIterator';
|
|
1650
|
+
var NORMAL = 'normal';
|
|
1651
|
+
var THROW = 'throw';
|
|
1652
|
+
var setInternalState$1 = InternalStateModule$1.set;
|
|
1653
|
+
|
|
1654
|
+
var createIteratorProxyPrototype = function (IS_ITERATOR) {
|
|
1655
|
+
var getInternalState = InternalStateModule$1.getterFor(IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER);
|
|
1656
|
+
|
|
1657
|
+
return defineBuiltIns(create(IteratorPrototype), {
|
|
1658
|
+
next: function next() {
|
|
1659
|
+
var state = getInternalState(this);
|
|
1660
|
+
// for simplification:
|
|
1661
|
+
// for `%WrapForValidIteratorPrototype%.next` or with `state.returnHandlerResult` our `nextHandler` returns `IterResultObject`
|
|
1662
|
+
// for `%IteratorHelperPrototype%.next` - just a value
|
|
1663
|
+
if (IS_ITERATOR) return state.nextHandler();
|
|
1664
|
+
if (state.done) return createIterResultObject(undefined, true);
|
|
1665
|
+
try {
|
|
1666
|
+
var result = state.nextHandler();
|
|
1667
|
+
return state.returnHandlerResult ? result : createIterResultObject(result, state.done);
|
|
1668
|
+
} catch (error) {
|
|
1669
|
+
state.done = true;
|
|
1670
|
+
throw error;
|
|
1671
|
+
}
|
|
1672
|
+
},
|
|
1673
|
+
'return': function () {
|
|
1674
|
+
var state = getInternalState(this);
|
|
1675
|
+
var iterator = state.iterator;
|
|
1676
|
+
state.done = true;
|
|
1677
|
+
if (IS_ITERATOR) {
|
|
1678
|
+
var returnMethod = getMethod$1(iterator, 'return');
|
|
1679
|
+
return returnMethod ? call$8(returnMethod, iterator) : createIterResultObject(undefined, true);
|
|
1680
|
+
}
|
|
1681
|
+
if (state.inner) try {
|
|
1682
|
+
iteratorClose$3(state.inner.iterator, NORMAL);
|
|
1683
|
+
} catch (error) {
|
|
1684
|
+
return iteratorClose$3(iterator, THROW, error);
|
|
1685
|
+
}
|
|
1686
|
+
if (state.openIters) try {
|
|
1687
|
+
iteratorCloseAll(state.openIters, NORMAL);
|
|
1688
|
+
} catch (error) {
|
|
1689
|
+
return iteratorClose$3(iterator, THROW, error);
|
|
1690
|
+
}
|
|
1691
|
+
if (iterator) iteratorClose$3(iterator, NORMAL);
|
|
1692
|
+
return createIterResultObject(undefined, true);
|
|
1693
|
+
}
|
|
1694
|
+
});
|
|
1695
|
+
};
|
|
1696
|
+
|
|
1697
|
+
var WrapForValidIteratorPrototype = createIteratorProxyPrototype(true);
|
|
1698
|
+
var IteratorHelperPrototype = createIteratorProxyPrototype(false);
|
|
1699
|
+
|
|
1700
|
+
createNonEnumerableProperty$1(IteratorHelperPrototype, TO_STRING_TAG$2, 'Iterator Helper');
|
|
1701
|
+
|
|
1702
|
+
var iteratorCreateProxy = function (nextHandler, IS_ITERATOR, RETURN_HANDLER_RESULT) {
|
|
1703
|
+
var IteratorProxy = function Iterator(record, state) {
|
|
1704
|
+
if (state) {
|
|
1705
|
+
state.iterator = record.iterator;
|
|
1706
|
+
state.next = record.next;
|
|
1707
|
+
} else state = record;
|
|
1708
|
+
state.type = IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER;
|
|
1709
|
+
state.returnHandlerResult = !!RETURN_HANDLER_RESULT;
|
|
1710
|
+
state.nextHandler = nextHandler;
|
|
1711
|
+
state.counter = 0;
|
|
1712
|
+
state.done = false;
|
|
1713
|
+
setInternalState$1(this, state);
|
|
1714
|
+
};
|
|
1715
|
+
|
|
1716
|
+
IteratorProxy.prototype = IS_ITERATOR ? WrapForValidIteratorPrototype : IteratorHelperPrototype;
|
|
1717
|
+
|
|
1718
|
+
return IteratorProxy;
|
|
1719
|
+
};
|
|
1720
|
+
|
|
1721
|
+
var anObject$6 = anObject$d;
|
|
1722
|
+
var iteratorClose$2 = iteratorClose$5;
|
|
1723
|
+
|
|
1724
|
+
// call something on iterator step with safe closing on error
|
|
1725
|
+
var callWithSafeIterationClosing$1 = function (iterator, fn, value, ENTRIES) {
|
|
1726
|
+
try {
|
|
1727
|
+
return ENTRIES ? fn(anObject$6(value)[0], value[1]) : fn(value);
|
|
1728
|
+
} catch (error) {
|
|
1729
|
+
iteratorClose$2(iterator, 'throw', error);
|
|
1730
|
+
}
|
|
1731
|
+
};
|
|
1732
|
+
|
|
1733
|
+
// Should throw an error on invalid iterator
|
|
1734
|
+
// https://issues.chromium.org/issues/336839115
|
|
1735
|
+
var iteratorHelperThrowsOnInvalidIterator$1 = function (methodName, argument) {
|
|
1736
|
+
// eslint-disable-next-line es/no-iterator -- required for testing
|
|
1737
|
+
var method = typeof Iterator == 'function' && Iterator.prototype[methodName];
|
|
1738
|
+
if (method) try {
|
|
1739
|
+
method.call({ next: null }, argument).next();
|
|
1740
|
+
} catch (error) {
|
|
1741
|
+
return true;
|
|
1742
|
+
}
|
|
1743
|
+
};
|
|
1744
|
+
|
|
1745
|
+
var globalThis$a = globalThis_1;
|
|
1746
|
+
|
|
1747
|
+
// https://github.com/tc39/ecma262/pull/3467
|
|
1748
|
+
var iteratorHelperWithoutClosingOnEarlyError$1 = function (METHOD_NAME, ExpectedError) {
|
|
1749
|
+
var Iterator = globalThis$a.Iterator;
|
|
1750
|
+
var IteratorPrototype = Iterator && Iterator.prototype;
|
|
1751
|
+
var method = IteratorPrototype && IteratorPrototype[METHOD_NAME];
|
|
1752
|
+
|
|
1753
|
+
var CLOSED = false;
|
|
1754
|
+
|
|
1755
|
+
if (method) try {
|
|
1756
|
+
method.call({
|
|
1757
|
+
next: function () { return { done: true }; },
|
|
1758
|
+
'return': function () { CLOSED = true; }
|
|
1759
|
+
}, -1);
|
|
1760
|
+
} catch (error) {
|
|
1761
|
+
// https://bugs.webkit.org/show_bug.cgi?id=291195
|
|
1762
|
+
if (!(error instanceof ExpectedError)) CLOSED = false;
|
|
1763
|
+
}
|
|
1764
|
+
|
|
1765
|
+
if (!CLOSED) return method;
|
|
1766
|
+
};
|
|
1767
|
+
|
|
1768
|
+
var $$8 = _export;
|
|
1769
|
+
var call$7 = functionCall;
|
|
1770
|
+
var aCallable$6 = aCallable$9;
|
|
1771
|
+
var anObject$5 = anObject$d;
|
|
1772
|
+
var getIteratorDirect$1 = getIteratorDirect$2;
|
|
1773
|
+
var createIteratorProxy = iteratorCreateProxy;
|
|
1774
|
+
var callWithSafeIterationClosing = callWithSafeIterationClosing$1;
|
|
1775
|
+
var iteratorClose$1 = iteratorClose$5;
|
|
1776
|
+
var iteratorHelperThrowsOnInvalidIterator = iteratorHelperThrowsOnInvalidIterator$1;
|
|
1777
|
+
var iteratorHelperWithoutClosingOnEarlyError = iteratorHelperWithoutClosingOnEarlyError$1;
|
|
1778
|
+
|
|
1779
|
+
var MAP_WITHOUT_THROWING_ON_INVALID_ITERATOR = !iteratorHelperThrowsOnInvalidIterator('map', function () { /* empty */ });
|
|
1780
|
+
var mapWithoutClosingOnEarlyError = !MAP_WITHOUT_THROWING_ON_INVALID_ITERATOR
|
|
1781
|
+
&& iteratorHelperWithoutClosingOnEarlyError('map', TypeError);
|
|
1782
|
+
|
|
1783
|
+
var FORCED = MAP_WITHOUT_THROWING_ON_INVALID_ITERATOR || mapWithoutClosingOnEarlyError;
|
|
1784
|
+
|
|
1785
|
+
var IteratorProxy = createIteratorProxy(function () {
|
|
1786
|
+
var iterator = this.iterator;
|
|
1787
|
+
var result = anObject$5(call$7(this.next, iterator));
|
|
1788
|
+
var done = this.done = !!result.done;
|
|
1789
|
+
if (!done) return callWithSafeIterationClosing(iterator, this.mapper, [result.value, this.counter++], true);
|
|
1790
|
+
});
|
|
1791
|
+
|
|
1792
|
+
// `Iterator.prototype.map` method
|
|
1793
|
+
// https://tc39.es/ecma262/#sec-iterator.prototype.map
|
|
1794
|
+
$$8({ target: 'Iterator', proto: true, real: true, forced: FORCED }, {
|
|
1795
|
+
map: function map(mapper) {
|
|
1796
|
+
anObject$5(this);
|
|
1797
|
+
try {
|
|
1798
|
+
aCallable$6(mapper);
|
|
1799
|
+
} catch (error) {
|
|
1800
|
+
iteratorClose$1(this, 'throw', error);
|
|
1801
|
+
}
|
|
1802
|
+
|
|
1803
|
+
if (mapWithoutClosingOnEarlyError) return call$7(mapWithoutClosingOnEarlyError, this, mapper);
|
|
1804
|
+
|
|
1805
|
+
return new IteratorProxy(getIteratorDirect$1(this), {
|
|
1806
|
+
mapper: mapper
|
|
1807
|
+
});
|
|
1808
|
+
}
|
|
1809
|
+
});
|
|
1810
|
+
|
|
1811
|
+
var classofRaw$1 = classofRaw$2;
|
|
1812
|
+
var uncurryThis$4 = functionUncurryThis;
|
|
1813
|
+
|
|
1814
|
+
var functionUncurryThisClause = function (fn) {
|
|
1815
|
+
// Nashorn bug:
|
|
1816
|
+
// https://github.com/zloirock/core-js/issues/1128
|
|
1817
|
+
// https://github.com/zloirock/core-js/issues/1130
|
|
1818
|
+
if (classofRaw$1(fn) === 'Function') return uncurryThis$4(fn);
|
|
1819
|
+
};
|
|
1820
|
+
|
|
1821
|
+
var uncurryThis$3 = functionUncurryThisClause;
|
|
1822
|
+
var aCallable$5 = aCallable$9;
|
|
1823
|
+
var NATIVE_BIND$1 = functionBindNative;
|
|
1824
|
+
|
|
1825
|
+
var bind$4 = uncurryThis$3(uncurryThis$3.bind);
|
|
1826
|
+
|
|
1827
|
+
// optional / simple context binding
|
|
1828
|
+
var functionBindContext = function (fn, that) {
|
|
1829
|
+
aCallable$5(fn);
|
|
1830
|
+
return that === undefined ? fn : NATIVE_BIND$1 ? bind$4(fn, that) : function (/* ...args */) {
|
|
1831
|
+
return fn.apply(that, arguments);
|
|
1832
|
+
};
|
|
1833
|
+
};
|
|
1834
|
+
|
|
1835
|
+
var wellKnownSymbol$8 = wellKnownSymbol$g;
|
|
1836
|
+
var Iterators$1 = iterators;
|
|
1837
|
+
|
|
1838
|
+
var ITERATOR$3 = wellKnownSymbol$8('iterator');
|
|
1839
|
+
var ArrayPrototype = Array.prototype;
|
|
1840
|
+
|
|
1841
|
+
// check on default Array iterator
|
|
1842
|
+
var isArrayIteratorMethod$1 = function (it) {
|
|
1843
|
+
return it !== undefined && (Iterators$1.Array === it || ArrayPrototype[ITERATOR$3] === it);
|
|
1844
|
+
};
|
|
1845
|
+
|
|
1846
|
+
var wellKnownSymbol$7 = wellKnownSymbol$g;
|
|
1847
|
+
|
|
1848
|
+
var TO_STRING_TAG$1 = wellKnownSymbol$7('toStringTag');
|
|
1849
|
+
var test = {};
|
|
1850
|
+
// eslint-disable-next-line unicorn/no-immediate-mutation -- ES3 syntax limitation
|
|
1851
|
+
test[TO_STRING_TAG$1] = 'z';
|
|
1852
|
+
|
|
1853
|
+
var toStringTagSupport = String(test) === '[object z]';
|
|
1854
|
+
|
|
1855
|
+
var TO_STRING_TAG_SUPPORT = toStringTagSupport;
|
|
1856
|
+
var isCallable$5 = isCallable$k;
|
|
1857
|
+
var classofRaw = classofRaw$2;
|
|
1858
|
+
var wellKnownSymbol$6 = wellKnownSymbol$g;
|
|
1859
|
+
|
|
1860
|
+
var TO_STRING_TAG = wellKnownSymbol$6('toStringTag');
|
|
1861
|
+
var $Object = Object;
|
|
1862
|
+
|
|
1863
|
+
// ES3 wrong here
|
|
1864
|
+
var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) === 'Arguments';
|
|
1865
|
+
|
|
1866
|
+
// fallback for IE11 Script Access Denied error
|
|
1867
|
+
var tryGet = function (it, key) {
|
|
1868
|
+
try {
|
|
1869
|
+
return it[key];
|
|
1870
|
+
} catch (error) { /* empty */ }
|
|
1871
|
+
};
|
|
1872
|
+
|
|
1873
|
+
// getting tag from ES6+ `Object.prototype.toString`
|
|
1874
|
+
var classof$3 = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {
|
|
1875
|
+
var O, tag, result;
|
|
1876
|
+
return it === undefined ? 'Undefined' : it === null ? 'Null'
|
|
1877
|
+
// @@toStringTag case
|
|
1878
|
+
: typeof (tag = tryGet(O = $Object(it), TO_STRING_TAG)) == 'string' ? tag
|
|
1879
|
+
// builtinTag case
|
|
1880
|
+
: CORRECT_ARGUMENTS ? classofRaw(O)
|
|
1881
|
+
// ES3 arguments fallback
|
|
1882
|
+
: (result = classofRaw(O)) === 'Object' && isCallable$5(O.callee) ? 'Arguments' : result;
|
|
1883
|
+
};
|
|
1884
|
+
|
|
1885
|
+
var classof$2 = classof$3;
|
|
1886
|
+
var getMethod = getMethod$4;
|
|
1887
|
+
var isNullOrUndefined$1 = isNullOrUndefined$4;
|
|
1888
|
+
var Iterators = iterators;
|
|
1889
|
+
var wellKnownSymbol$5 = wellKnownSymbol$g;
|
|
1890
|
+
|
|
1891
|
+
var ITERATOR$2 = wellKnownSymbol$5('iterator');
|
|
1892
|
+
|
|
1893
|
+
var getIteratorMethod$2 = function (it) {
|
|
1894
|
+
if (!isNullOrUndefined$1(it)) return getMethod(it, ITERATOR$2)
|
|
1895
|
+
|| getMethod(it, '@@iterator')
|
|
1896
|
+
|| Iterators[classof$2(it)];
|
|
1897
|
+
};
|
|
1898
|
+
|
|
1899
|
+
var call$6 = functionCall;
|
|
1900
|
+
var aCallable$4 = aCallable$9;
|
|
1901
|
+
var anObject$4 = anObject$d;
|
|
1902
|
+
var tryToString$2 = tryToString$4;
|
|
1903
|
+
var getIteratorMethod$1 = getIteratorMethod$2;
|
|
1904
|
+
|
|
1905
|
+
var $TypeError$4 = TypeError;
|
|
1906
|
+
|
|
1907
|
+
var getIterator$1 = function (argument, usingIterator) {
|
|
1908
|
+
var iteratorMethod = arguments.length < 2 ? getIteratorMethod$1(argument) : usingIterator;
|
|
1909
|
+
if (aCallable$4(iteratorMethod)) return anObject$4(call$6(iteratorMethod, argument));
|
|
1910
|
+
throw new $TypeError$4(tryToString$2(argument) + ' is not iterable');
|
|
1911
|
+
};
|
|
1912
|
+
|
|
1913
|
+
var bind$3 = functionBindContext;
|
|
1914
|
+
var call$5 = functionCall;
|
|
1915
|
+
var anObject$3 = anObject$d;
|
|
1916
|
+
var tryToString$1 = tryToString$4;
|
|
1917
|
+
var isArrayIteratorMethod = isArrayIteratorMethod$1;
|
|
1918
|
+
var lengthOfArrayLike = lengthOfArrayLike$2;
|
|
1919
|
+
var isPrototypeOf = objectIsPrototypeOf;
|
|
1920
|
+
var getIterator = getIterator$1;
|
|
1921
|
+
var getIteratorMethod = getIteratorMethod$2;
|
|
1922
|
+
var iteratorClose = iteratorClose$5;
|
|
1923
|
+
|
|
1924
|
+
var $TypeError$3 = TypeError;
|
|
1925
|
+
|
|
1926
|
+
var Result = function (stopped, result) {
|
|
1927
|
+
this.stopped = stopped;
|
|
1928
|
+
this.result = result;
|
|
1929
|
+
};
|
|
1930
|
+
|
|
1931
|
+
var ResultPrototype = Result.prototype;
|
|
1932
|
+
|
|
1933
|
+
var iterate$3 = function (iterable, unboundFunction, options) {
|
|
1934
|
+
var that = options && options.that;
|
|
1935
|
+
var AS_ENTRIES = !!(options && options.AS_ENTRIES);
|
|
1936
|
+
var IS_RECORD = !!(options && options.IS_RECORD);
|
|
1937
|
+
var IS_ITERATOR = !!(options && options.IS_ITERATOR);
|
|
1938
|
+
var INTERRUPTED = !!(options && options.INTERRUPTED);
|
|
1939
|
+
var fn = bind$3(unboundFunction, that);
|
|
1940
|
+
var iterator, iterFn, index, length, result, next, step;
|
|
1941
|
+
|
|
1942
|
+
var stop = function (condition) {
|
|
1943
|
+
if (iterator) iteratorClose(iterator, 'normal');
|
|
1944
|
+
return new Result(true, condition);
|
|
1945
|
+
};
|
|
1946
|
+
|
|
1947
|
+
var callFn = function (value) {
|
|
1948
|
+
if (AS_ENTRIES) {
|
|
1949
|
+
anObject$3(value);
|
|
1950
|
+
return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);
|
|
1951
|
+
} return INTERRUPTED ? fn(value, stop) : fn(value);
|
|
1952
|
+
};
|
|
1953
|
+
|
|
1954
|
+
if (IS_RECORD) {
|
|
1955
|
+
iterator = iterable.iterator;
|
|
1956
|
+
} else if (IS_ITERATOR) {
|
|
1957
|
+
iterator = iterable;
|
|
1958
|
+
} else {
|
|
1959
|
+
iterFn = getIteratorMethod(iterable);
|
|
1960
|
+
if (!iterFn) throw new $TypeError$3(tryToString$1(iterable) + ' is not iterable');
|
|
1961
|
+
// optimisation for array iterators
|
|
1962
|
+
if (isArrayIteratorMethod(iterFn)) {
|
|
1963
|
+
for (index = 0, length = lengthOfArrayLike(iterable); length > index; index++) {
|
|
1964
|
+
result = callFn(iterable[index]);
|
|
1965
|
+
if (result && isPrototypeOf(ResultPrototype, result)) return result;
|
|
1966
|
+
} return new Result(false);
|
|
1967
|
+
}
|
|
1968
|
+
iterator = getIterator(iterable, iterFn);
|
|
1969
|
+
}
|
|
1970
|
+
|
|
1971
|
+
next = IS_RECORD ? iterable.next : iterator.next;
|
|
1972
|
+
while (!(step = call$5(next, iterator)).done) {
|
|
1973
|
+
try {
|
|
1974
|
+
result = callFn(step.value);
|
|
1975
|
+
} catch (error) {
|
|
1976
|
+
iteratorClose(iterator, 'throw', error);
|
|
1977
|
+
}
|
|
1978
|
+
if (typeof result == 'object' && result && isPrototypeOf(ResultPrototype, result)) return result;
|
|
1979
|
+
} return new Result(false);
|
|
1980
|
+
};
|
|
1981
|
+
|
|
1982
|
+
var $$7 = _export;
|
|
1983
|
+
var anObject$2 = anObject$d;
|
|
1984
|
+
var createProperty = createProperty$2;
|
|
1985
|
+
var iterate$2 = iterate$3;
|
|
1986
|
+
var getIteratorDirect = getIteratorDirect$2;
|
|
1987
|
+
|
|
1988
|
+
// `Iterator.prototype.toArray` method
|
|
1989
|
+
// https://tc39.es/ecma262/#sec-iterator.prototype.toarray
|
|
1990
|
+
$$7({ target: 'Iterator', proto: true, real: true }, {
|
|
1991
|
+
toArray: function toArray() {
|
|
1992
|
+
var result = [];
|
|
1993
|
+
var index = 0;
|
|
1994
|
+
iterate$2(getIteratorDirect(anObject$2(this)), function (element) {
|
|
1995
|
+
createProperty(result, index++, element);
|
|
1996
|
+
}, { IS_RECORD: true });
|
|
1997
|
+
return result;
|
|
1998
|
+
}
|
|
1999
|
+
});
|
|
2000
|
+
|
|
2001
|
+
var DESCRIPTORS$2 = descriptors;
|
|
2002
|
+
var uncurryThis$2 = functionUncurryThis;
|
|
2003
|
+
var call$4 = functionCall;
|
|
2004
|
+
var fails$2 = fails$e;
|
|
2005
|
+
var objectKeys = objectKeys$2;
|
|
2006
|
+
var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols;
|
|
2007
|
+
var propertyIsEnumerableModule = objectPropertyIsEnumerable;
|
|
2008
|
+
var toObject = toObject$3;
|
|
2009
|
+
var IndexedObject = indexedObject;
|
|
2010
|
+
|
|
2011
|
+
// eslint-disable-next-line es/no-object-assign -- safe
|
|
2012
|
+
var $assign = Object.assign;
|
|
2013
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
2014
|
+
var defineProperty = Object.defineProperty;
|
|
2015
|
+
var concat = uncurryThis$2([].concat);
|
|
2016
|
+
|
|
2017
|
+
// `Object.assign` method
|
|
2018
|
+
// https://tc39.es/ecma262/#sec-object.assign
|
|
2019
|
+
var objectAssign = !$assign || fails$2(function () {
|
|
2020
|
+
// should have correct order of operations (Edge bug)
|
|
2021
|
+
if (DESCRIPTORS$2 && $assign({ b: 1 }, $assign(defineProperty({}, 'a', {
|
|
2022
|
+
enumerable: true,
|
|
2023
|
+
get: function () {
|
|
2024
|
+
defineProperty(this, 'b', {
|
|
2025
|
+
value: 3,
|
|
2026
|
+
enumerable: false
|
|
2027
|
+
});
|
|
2028
|
+
}
|
|
2029
|
+
}), { b: 2 })).b !== 1) return true;
|
|
2030
|
+
// should work with symbols and should have deterministic property order (V8 bug)
|
|
2031
|
+
var A = {};
|
|
2032
|
+
var B = {};
|
|
2033
|
+
// eslint-disable-next-line es/no-symbol -- safe
|
|
2034
|
+
var symbol = Symbol('assign detection');
|
|
2035
|
+
var alphabet = 'abcdefghijklmnopqrst';
|
|
2036
|
+
A[symbol] = 7;
|
|
2037
|
+
// eslint-disable-next-line es/no-array-prototype-foreach -- safe
|
|
2038
|
+
alphabet.split('').forEach(function (chr) { B[chr] = chr; });
|
|
2039
|
+
return $assign({}, A)[symbol] !== 7 || objectKeys($assign({}, B)).join('') !== alphabet;
|
|
2040
|
+
}) ? function assign(target, source) { // eslint-disable-line no-unused-vars -- required for `.length`
|
|
2041
|
+
var T = toObject(target);
|
|
2042
|
+
var argumentsLength = arguments.length;
|
|
2043
|
+
var index = 1;
|
|
2044
|
+
var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
|
|
2045
|
+
var propertyIsEnumerable = propertyIsEnumerableModule.f;
|
|
2046
|
+
while (argumentsLength > index) {
|
|
2047
|
+
var S = IndexedObject(arguments[index++]);
|
|
2048
|
+
var keys = getOwnPropertySymbols ? concat(objectKeys(S), getOwnPropertySymbols(S)) : objectKeys(S);
|
|
2049
|
+
var length = keys.length;
|
|
2050
|
+
var j = 0;
|
|
2051
|
+
var key;
|
|
2052
|
+
while (length > j) {
|
|
2053
|
+
key = keys[j++];
|
|
2054
|
+
if (!DESCRIPTORS$2 || call$4(propertyIsEnumerable, S, key)) T[key] = S[key];
|
|
2055
|
+
}
|
|
2056
|
+
} return T;
|
|
2057
|
+
} : $assign;
|
|
2058
|
+
|
|
2059
|
+
var $$6 = _export;
|
|
2060
|
+
var assign = objectAssign;
|
|
2061
|
+
|
|
2062
|
+
// `Object.assign` method
|
|
2063
|
+
// https://tc39.es/ecma262/#sec-object.assign
|
|
2064
|
+
// eslint-disable-next-line es/no-object-assign -- required for testing
|
|
2065
|
+
$$6({ target: 'Object', stat: true, arity: 2, forced: Object.assign !== assign }, {
|
|
2066
|
+
assign: assign
|
|
2067
|
+
});
|
|
2068
|
+
|
|
2069
|
+
/* global Bun, Deno -- detection */
|
|
2070
|
+
var globalThis$9 = globalThis_1;
|
|
2071
|
+
var userAgent$3 = environmentUserAgent;
|
|
2072
|
+
var classof$1 = classofRaw$2;
|
|
2073
|
+
|
|
2074
|
+
var userAgentStartsWith = function (string) {
|
|
2075
|
+
return userAgent$3.slice(0, string.length) === string;
|
|
2076
|
+
};
|
|
2077
|
+
|
|
2078
|
+
var environment = (function () {
|
|
2079
|
+
if (userAgentStartsWith('Bun/')) return 'BUN';
|
|
2080
|
+
if (userAgentStartsWith('Cloudflare-Workers')) return 'CLOUDFLARE';
|
|
2081
|
+
if (userAgentStartsWith('Deno/')) return 'DENO';
|
|
2082
|
+
if (userAgentStartsWith('Node.js/')) return 'NODE';
|
|
2083
|
+
if (globalThis$9.Bun && typeof Bun.version == 'string') return 'BUN';
|
|
2084
|
+
if (globalThis$9.Deno && typeof Deno.version == 'object') return 'DENO';
|
|
2085
|
+
if (classof$1(globalThis$9.process) === 'process') return 'NODE';
|
|
2086
|
+
if (globalThis$9.window && globalThis$9.document) return 'BROWSER';
|
|
2087
|
+
return 'REST';
|
|
2088
|
+
})();
|
|
2089
|
+
|
|
2090
|
+
var ENVIRONMENT$1 = environment;
|
|
2091
|
+
|
|
2092
|
+
var environmentIsNode = ENVIRONMENT$1 === 'NODE';
|
|
2093
|
+
|
|
2094
|
+
var globalThis$8 = globalThis_1;
|
|
2095
|
+
|
|
2096
|
+
var path$1 = globalThis$8;
|
|
2097
|
+
|
|
2098
|
+
var getBuiltIn$3 = getBuiltIn$7;
|
|
2099
|
+
var defineBuiltInAccessor = defineBuiltInAccessor$2;
|
|
2100
|
+
var wellKnownSymbol$4 = wellKnownSymbol$g;
|
|
2101
|
+
var DESCRIPTORS$1 = descriptors;
|
|
2102
|
+
|
|
2103
|
+
var SPECIES$2 = wellKnownSymbol$4('species');
|
|
2104
|
+
|
|
2105
|
+
var setSpecies$1 = function (CONSTRUCTOR_NAME) {
|
|
2106
|
+
var Constructor = getBuiltIn$3(CONSTRUCTOR_NAME);
|
|
2107
|
+
|
|
2108
|
+
if (DESCRIPTORS$1 && Constructor && !Constructor[SPECIES$2]) {
|
|
2109
|
+
defineBuiltInAccessor(Constructor, SPECIES$2, {
|
|
2110
|
+
configurable: true,
|
|
2111
|
+
get: function () { return this; }
|
|
2112
|
+
});
|
|
2113
|
+
}
|
|
2114
|
+
};
|
|
2115
|
+
|
|
2116
|
+
var uncurryThis$1 = functionUncurryThis;
|
|
2117
|
+
var fails$1 = fails$e;
|
|
2118
|
+
var isCallable$4 = isCallable$k;
|
|
2119
|
+
var classof = classof$3;
|
|
2120
|
+
var getBuiltIn$2 = getBuiltIn$7;
|
|
2121
|
+
var inspectSource$1 = inspectSource$3;
|
|
2122
|
+
|
|
2123
|
+
var noop = function () { /* empty */ };
|
|
2124
|
+
var construct = getBuiltIn$2('Reflect', 'construct');
|
|
2125
|
+
var constructorRegExp = /^\s*(?:class|function)\b/;
|
|
2126
|
+
var exec = uncurryThis$1(constructorRegExp.exec);
|
|
2127
|
+
var INCORRECT_TO_STRING = !constructorRegExp.test(noop);
|
|
2128
|
+
|
|
2129
|
+
var isConstructorModern = function isConstructor(argument) {
|
|
2130
|
+
if (!isCallable$4(argument)) return false;
|
|
2131
|
+
try {
|
|
2132
|
+
construct(noop, [], argument);
|
|
2133
|
+
return true;
|
|
2134
|
+
} catch (error) {
|
|
2135
|
+
return false;
|
|
2136
|
+
}
|
|
2137
|
+
};
|
|
2138
|
+
|
|
2139
|
+
var isConstructorLegacy = function isConstructor(argument) {
|
|
2140
|
+
if (!isCallable$4(argument)) return false;
|
|
2141
|
+
switch (classof(argument)) {
|
|
2142
|
+
case 'AsyncFunction':
|
|
2143
|
+
case 'GeneratorFunction':
|
|
2144
|
+
case 'AsyncGeneratorFunction': return false;
|
|
2145
|
+
}
|
|
2146
|
+
try {
|
|
2147
|
+
// we can't check .prototype since constructors produced by .bind haven't it
|
|
2148
|
+
// `Function#toString` throws on some built-it function in some legacy engines
|
|
2149
|
+
// (for example, `DOMQuad` and similar in FF41-)
|
|
2150
|
+
return INCORRECT_TO_STRING || !!exec(constructorRegExp, inspectSource$1(argument));
|
|
2151
|
+
} catch (error) {
|
|
2152
|
+
return true;
|
|
2153
|
+
}
|
|
2154
|
+
};
|
|
2155
|
+
|
|
2156
|
+
isConstructorLegacy.sham = true;
|
|
2157
|
+
|
|
2158
|
+
// `IsConstructor` abstract operation
|
|
2159
|
+
// https://tc39.es/ecma262/#sec-isconstructor
|
|
2160
|
+
var isConstructor$1 = !construct || fails$1(function () {
|
|
2161
|
+
var called;
|
|
2162
|
+
return isConstructorModern(isConstructorModern.call)
|
|
2163
|
+
|| !isConstructorModern(Object)
|
|
2164
|
+
|| !isConstructorModern(function () { called = true; })
|
|
2165
|
+
|| called;
|
|
2166
|
+
}) ? isConstructorLegacy : isConstructorModern;
|
|
2167
|
+
|
|
2168
|
+
var isConstructor = isConstructor$1;
|
|
2169
|
+
var tryToString = tryToString$4;
|
|
2170
|
+
|
|
2171
|
+
var $TypeError$2 = TypeError;
|
|
2172
|
+
|
|
2173
|
+
// `Assert: IsConstructor(argument) is true`
|
|
2174
|
+
var aConstructor$1 = function (argument) {
|
|
2175
|
+
if (isConstructor(argument)) return argument;
|
|
2176
|
+
throw new $TypeError$2(tryToString(argument) + ' is not a constructor');
|
|
2177
|
+
};
|
|
2178
|
+
|
|
2179
|
+
var anObject$1 = anObject$d;
|
|
2180
|
+
var aConstructor = aConstructor$1;
|
|
2181
|
+
var isNullOrUndefined = isNullOrUndefined$4;
|
|
2182
|
+
var wellKnownSymbol$3 = wellKnownSymbol$g;
|
|
2183
|
+
|
|
2184
|
+
var SPECIES$1 = wellKnownSymbol$3('species');
|
|
2185
|
+
|
|
2186
|
+
// `SpeciesConstructor` abstract operation
|
|
2187
|
+
// https://tc39.es/ecma262/#sec-speciesconstructor
|
|
2188
|
+
var speciesConstructor$1 = function (O, defaultConstructor) {
|
|
2189
|
+
var C = anObject$1(O).constructor;
|
|
2190
|
+
var S;
|
|
2191
|
+
return C === undefined || isNullOrUndefined(S = anObject$1(C)[SPECIES$1]) ? defaultConstructor : aConstructor(S);
|
|
2192
|
+
};
|
|
2193
|
+
|
|
2194
|
+
var NATIVE_BIND = functionBindNative;
|
|
2195
|
+
|
|
2196
|
+
var FunctionPrototype = Function.prototype;
|
|
2197
|
+
var apply$1 = FunctionPrototype.apply;
|
|
2198
|
+
var call$3 = FunctionPrototype.call;
|
|
2199
|
+
|
|
2200
|
+
// eslint-disable-next-line es/no-function-prototype-bind, es/no-reflect -- safe
|
|
2201
|
+
var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call$3.bind(apply$1) : function () {
|
|
2202
|
+
return call$3.apply(apply$1, arguments);
|
|
2203
|
+
});
|
|
2204
|
+
|
|
2205
|
+
var uncurryThis = functionUncurryThis;
|
|
2206
|
+
|
|
2207
|
+
var arraySlice$1 = uncurryThis([].slice);
|
|
2208
|
+
|
|
2209
|
+
var $TypeError$1 = TypeError;
|
|
2210
|
+
|
|
2211
|
+
var validateArgumentsLength$1 = function (passed, required) {
|
|
2212
|
+
if (passed < required) throw new $TypeError$1('Not enough arguments');
|
|
2213
|
+
return passed;
|
|
2214
|
+
};
|
|
2215
|
+
|
|
2216
|
+
var userAgent$2 = environmentUserAgent;
|
|
2217
|
+
|
|
2218
|
+
// eslint-disable-next-line redos/no-vulnerable -- safe
|
|
2219
|
+
var environmentIsIos = /(?:ipad|iphone|ipod).*applewebkit/i.test(userAgent$2);
|
|
2220
|
+
|
|
2221
|
+
var globalThis$7 = globalThis_1;
|
|
2222
|
+
var apply = functionApply;
|
|
2223
|
+
var bind$2 = functionBindContext;
|
|
2224
|
+
var isCallable$3 = isCallable$k;
|
|
2225
|
+
var hasOwn = hasOwnProperty_1;
|
|
2226
|
+
var fails = fails$e;
|
|
2227
|
+
var html = html$2;
|
|
2228
|
+
var arraySlice = arraySlice$1;
|
|
2229
|
+
var createElement = documentCreateElement$2;
|
|
2230
|
+
var validateArgumentsLength = validateArgumentsLength$1;
|
|
2231
|
+
var IS_IOS$1 = environmentIsIos;
|
|
2232
|
+
var IS_NODE$2 = environmentIsNode;
|
|
2233
|
+
|
|
2234
|
+
var set = globalThis$7.setImmediate;
|
|
2235
|
+
var clear = globalThis$7.clearImmediate;
|
|
2236
|
+
var process$2 = globalThis$7.process;
|
|
2237
|
+
var Dispatch = globalThis$7.Dispatch;
|
|
2238
|
+
var Function$1 = globalThis$7.Function;
|
|
2239
|
+
var MessageChannel = globalThis$7.MessageChannel;
|
|
2240
|
+
var String$1 = globalThis$7.String;
|
|
2241
|
+
var counter = 0;
|
|
2242
|
+
var queue$2 = {};
|
|
2243
|
+
var ONREADYSTATECHANGE = 'onreadystatechange';
|
|
2244
|
+
var $location, defer, channel, port;
|
|
2245
|
+
|
|
2246
|
+
fails(function () {
|
|
2247
|
+
// Deno throws a ReferenceError on `location` access without `--location` flag
|
|
2248
|
+
$location = globalThis$7.location;
|
|
2249
|
+
});
|
|
2250
|
+
|
|
2251
|
+
var run = function (id) {
|
|
2252
|
+
if (hasOwn(queue$2, id)) {
|
|
2253
|
+
var fn = queue$2[id];
|
|
2254
|
+
delete queue$2[id];
|
|
2255
|
+
fn();
|
|
2256
|
+
}
|
|
2257
|
+
};
|
|
2258
|
+
|
|
2259
|
+
var runner = function (id) {
|
|
2260
|
+
return function () {
|
|
2261
|
+
run(id);
|
|
2262
|
+
};
|
|
2263
|
+
};
|
|
2264
|
+
|
|
2265
|
+
var eventListener = function (event) {
|
|
2266
|
+
run(event.data);
|
|
2267
|
+
};
|
|
2268
|
+
|
|
2269
|
+
var globalPostMessageDefer = function (id) {
|
|
2270
|
+
// old engines have not location.origin
|
|
2271
|
+
globalThis$7.postMessage(String$1(id), $location.protocol + '//' + $location.host);
|
|
2272
|
+
};
|
|
2273
|
+
|
|
2274
|
+
// Node.js 0.9+ & IE10+ has setImmediate, otherwise:
|
|
2275
|
+
if (!set || !clear) {
|
|
2276
|
+
set = function setImmediate(handler) {
|
|
2277
|
+
validateArgumentsLength(arguments.length, 1);
|
|
2278
|
+
var fn = isCallable$3(handler) ? handler : Function$1(handler);
|
|
2279
|
+
var args = arraySlice(arguments, 1);
|
|
2280
|
+
queue$2[++counter] = function () {
|
|
2281
|
+
apply(fn, undefined, args);
|
|
2282
|
+
};
|
|
2283
|
+
defer(counter);
|
|
2284
|
+
return counter;
|
|
2285
|
+
};
|
|
2286
|
+
clear = function clearImmediate(id) {
|
|
2287
|
+
delete queue$2[id];
|
|
2288
|
+
};
|
|
2289
|
+
// Node.js 0.8-
|
|
2290
|
+
if (IS_NODE$2) {
|
|
2291
|
+
defer = function (id) {
|
|
2292
|
+
process$2.nextTick(runner(id));
|
|
2293
|
+
};
|
|
2294
|
+
// Sphere (JS game engine) Dispatch API
|
|
2295
|
+
} else if (Dispatch && Dispatch.now) {
|
|
2296
|
+
defer = function (id) {
|
|
2297
|
+
Dispatch.now(runner(id));
|
|
2298
|
+
};
|
|
2299
|
+
// Browsers with MessageChannel, includes WebWorkers
|
|
2300
|
+
// except iOS - https://github.com/zloirock/core-js/issues/624
|
|
2301
|
+
} else if (MessageChannel && !IS_IOS$1) {
|
|
2302
|
+
channel = new MessageChannel();
|
|
2303
|
+
port = channel.port2;
|
|
2304
|
+
channel.port1.onmessage = eventListener;
|
|
2305
|
+
defer = bind$2(port.postMessage, port);
|
|
2306
|
+
// Browsers with postMessage, skip WebWorkers
|
|
2307
|
+
// IE8 has postMessage, but it's sync & typeof its postMessage is 'object'
|
|
2308
|
+
} else if (
|
|
2309
|
+
globalThis$7.addEventListener &&
|
|
2310
|
+
isCallable$3(globalThis$7.postMessage) &&
|
|
2311
|
+
!globalThis$7.importScripts &&
|
|
2312
|
+
$location && $location.protocol !== 'file:' &&
|
|
2313
|
+
!fails(globalPostMessageDefer)
|
|
2314
|
+
) {
|
|
2315
|
+
defer = globalPostMessageDefer;
|
|
2316
|
+
globalThis$7.addEventListener('message', eventListener, false);
|
|
2317
|
+
// IE8-
|
|
2318
|
+
} else if (ONREADYSTATECHANGE in createElement('script')) {
|
|
2319
|
+
defer = function (id) {
|
|
2320
|
+
html.appendChild(createElement('script'))[ONREADYSTATECHANGE] = function () {
|
|
2321
|
+
html.removeChild(this);
|
|
2322
|
+
run(id);
|
|
2323
|
+
};
|
|
2324
|
+
};
|
|
2325
|
+
// Rest old browsers
|
|
2326
|
+
} else {
|
|
2327
|
+
defer = function (id) {
|
|
2328
|
+
setTimeout(runner(id), 0);
|
|
2329
|
+
};
|
|
2330
|
+
}
|
|
2331
|
+
}
|
|
2332
|
+
|
|
2333
|
+
var task$1 = {
|
|
2334
|
+
set: set};
|
|
2335
|
+
|
|
2336
|
+
var globalThis$6 = globalThis_1;
|
|
2337
|
+
var DESCRIPTORS = descriptors;
|
|
2338
|
+
|
|
2339
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
2340
|
+
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
2341
|
+
|
|
2342
|
+
// Avoid NodeJS experimental warning
|
|
2343
|
+
var safeGetBuiltIn$1 = function (name) {
|
|
2344
|
+
if (!DESCRIPTORS) return globalThis$6[name];
|
|
2345
|
+
var descriptor = getOwnPropertyDescriptor(globalThis$6, name);
|
|
2346
|
+
return descriptor && descriptor.value;
|
|
2347
|
+
};
|
|
2348
|
+
|
|
2349
|
+
var Queue$2 = function () {
|
|
2350
|
+
this.head = null;
|
|
2351
|
+
this.tail = null;
|
|
2352
|
+
};
|
|
2353
|
+
|
|
2354
|
+
Queue$2.prototype = {
|
|
2355
|
+
add: function (item) {
|
|
2356
|
+
var entry = { item: item, next: null };
|
|
2357
|
+
var tail = this.tail;
|
|
2358
|
+
if (tail) tail.next = entry;
|
|
2359
|
+
else this.head = entry;
|
|
2360
|
+
this.tail = entry;
|
|
2361
|
+
},
|
|
2362
|
+
get: function () {
|
|
2363
|
+
var entry = this.head;
|
|
2364
|
+
if (entry) {
|
|
2365
|
+
var next = this.head = entry.next;
|
|
2366
|
+
if (next === null) this.tail = null;
|
|
2367
|
+
return entry.item;
|
|
2368
|
+
}
|
|
2369
|
+
}
|
|
2370
|
+
};
|
|
2371
|
+
|
|
2372
|
+
var queue$1 = Queue$2;
|
|
2373
|
+
|
|
2374
|
+
var userAgent$1 = environmentUserAgent;
|
|
2375
|
+
|
|
2376
|
+
var environmentIsIosPebble = /ipad|iphone|ipod/i.test(userAgent$1) && typeof Pebble != 'undefined';
|
|
2377
|
+
|
|
2378
|
+
var userAgent = environmentUserAgent;
|
|
2379
|
+
|
|
2380
|
+
var environmentIsWebosWebkit = /web0s(?!.*chrome)/i.test(userAgent);
|
|
2381
|
+
|
|
2382
|
+
var globalThis$5 = globalThis_1;
|
|
2383
|
+
var safeGetBuiltIn = safeGetBuiltIn$1;
|
|
2384
|
+
var bind$1 = functionBindContext;
|
|
2385
|
+
var macrotask = task$1.set;
|
|
2386
|
+
var Queue$1 = queue$1;
|
|
2387
|
+
var IS_IOS = environmentIsIos;
|
|
2388
|
+
var IS_IOS_PEBBLE = environmentIsIosPebble;
|
|
2389
|
+
var IS_WEBOS_WEBKIT = environmentIsWebosWebkit;
|
|
2390
|
+
var IS_NODE$1 = environmentIsNode;
|
|
2391
|
+
|
|
2392
|
+
var MutationObserver = globalThis$5.MutationObserver || globalThis$5.WebKitMutationObserver;
|
|
2393
|
+
var document$2 = globalThis$5.document;
|
|
2394
|
+
var process$1 = globalThis$5.process;
|
|
2395
|
+
var Promise$1 = globalThis$5.Promise;
|
|
2396
|
+
var microtask$1 = safeGetBuiltIn('queueMicrotask');
|
|
2397
|
+
var notify$1, toggle, node, promise, then;
|
|
2398
|
+
|
|
2399
|
+
// modern engines have queueMicrotask method
|
|
2400
|
+
if (!microtask$1) {
|
|
2401
|
+
var queue = new Queue$1();
|
|
2402
|
+
|
|
2403
|
+
var flush = function () {
|
|
2404
|
+
var parent, fn;
|
|
2405
|
+
if (IS_NODE$1 && (parent = process$1.domain)) parent.exit();
|
|
2406
|
+
while (fn = queue.get()) try {
|
|
2407
|
+
fn();
|
|
2408
|
+
} catch (error) {
|
|
2409
|
+
if (queue.head) notify$1();
|
|
2410
|
+
throw error;
|
|
2411
|
+
}
|
|
2412
|
+
if (parent) parent.enter();
|
|
2413
|
+
};
|
|
2414
|
+
|
|
2415
|
+
// browsers with MutationObserver, except iOS - https://github.com/zloirock/core-js/issues/339
|
|
2416
|
+
// also except WebOS Webkit https://github.com/zloirock/core-js/issues/898
|
|
2417
|
+
if (!IS_IOS && !IS_NODE$1 && !IS_WEBOS_WEBKIT && MutationObserver && document$2) {
|
|
2418
|
+
toggle = true;
|
|
2419
|
+
node = document$2.createTextNode('');
|
|
2420
|
+
new MutationObserver(flush).observe(node, { characterData: true });
|
|
2421
|
+
notify$1 = function () {
|
|
2422
|
+
node.data = toggle = !toggle;
|
|
2423
|
+
};
|
|
2424
|
+
// environments with maybe non-completely correct, but existent Promise
|
|
2425
|
+
} else if (!IS_IOS_PEBBLE && Promise$1 && Promise$1.resolve) {
|
|
2426
|
+
// Promise.resolve without an argument throws an error in LG WebOS 2
|
|
2427
|
+
promise = Promise$1.resolve(undefined);
|
|
2428
|
+
// workaround of WebKit ~ iOS Safari 10.1 bug
|
|
2429
|
+
promise.constructor = Promise$1;
|
|
2430
|
+
then = bind$1(promise.then, promise);
|
|
2431
|
+
notify$1 = function () {
|
|
2432
|
+
then(flush);
|
|
2433
|
+
};
|
|
2434
|
+
// Node.js without promises
|
|
2435
|
+
} else if (IS_NODE$1) {
|
|
2436
|
+
notify$1 = function () {
|
|
2437
|
+
process$1.nextTick(flush);
|
|
2438
|
+
};
|
|
2439
|
+
// for other environments - macrotask based on:
|
|
2440
|
+
// - setImmediate
|
|
2441
|
+
// - MessageChannel
|
|
2442
|
+
// - window.postMessage
|
|
2443
|
+
// - onreadystatechange
|
|
2444
|
+
// - setTimeout
|
|
2445
|
+
} else {
|
|
2446
|
+
// `webpack` dev server bug on IE global methods - use bind(fn, global)
|
|
2447
|
+
macrotask = bind$1(macrotask, globalThis$5);
|
|
2448
|
+
notify$1 = function () {
|
|
2449
|
+
macrotask(flush);
|
|
2450
|
+
};
|
|
2451
|
+
}
|
|
2452
|
+
|
|
2453
|
+
microtask$1 = function (fn) {
|
|
2454
|
+
if (!queue.head) notify$1();
|
|
2455
|
+
queue.add(fn);
|
|
2456
|
+
};
|
|
2457
|
+
}
|
|
2458
|
+
|
|
2459
|
+
var microtask_1 = microtask$1;
|
|
2460
|
+
|
|
2461
|
+
var hostReportErrors$1 = function (a, b) {
|
|
2462
|
+
try {
|
|
2463
|
+
// eslint-disable-next-line no-console -- safe
|
|
2464
|
+
arguments.length === 1 ? console.error(a) : console.error(a, b);
|
|
2465
|
+
} catch (error) { /* empty */ }
|
|
2466
|
+
};
|
|
2467
|
+
|
|
2468
|
+
var perform$3 = function (exec) {
|
|
2469
|
+
try {
|
|
2470
|
+
return { error: false, value: exec() };
|
|
2471
|
+
} catch (error) {
|
|
2472
|
+
return { error: true, value: error };
|
|
2473
|
+
}
|
|
2474
|
+
};
|
|
2475
|
+
|
|
2476
|
+
var globalThis$4 = globalThis_1;
|
|
2477
|
+
|
|
2478
|
+
var promiseNativeConstructor = globalThis$4.Promise;
|
|
2479
|
+
|
|
2480
|
+
var globalThis$3 = globalThis_1;
|
|
2481
|
+
var NativePromiseConstructor$3 = promiseNativeConstructor;
|
|
2482
|
+
var isCallable$2 = isCallable$k;
|
|
2483
|
+
var isForced = isForced_1;
|
|
2484
|
+
var inspectSource = inspectSource$3;
|
|
2485
|
+
var wellKnownSymbol$2 = wellKnownSymbol$g;
|
|
2486
|
+
var ENVIRONMENT = environment;
|
|
2487
|
+
var V8_VERSION = environmentV8Version;
|
|
2488
|
+
|
|
2489
|
+
NativePromiseConstructor$3 && NativePromiseConstructor$3.prototype;
|
|
2490
|
+
var SPECIES = wellKnownSymbol$2('species');
|
|
2491
|
+
var SUBCLASSING = false;
|
|
2492
|
+
var NATIVE_PROMISE_REJECTION_EVENT$1 = isCallable$2(globalThis$3.PromiseRejectionEvent);
|
|
2493
|
+
|
|
2494
|
+
var FORCED_PROMISE_CONSTRUCTOR$5 = isForced('Promise', function () {
|
|
2495
|
+
var PROMISE_CONSTRUCTOR_SOURCE = inspectSource(NativePromiseConstructor$3);
|
|
2496
|
+
var GLOBAL_CORE_JS_PROMISE = PROMISE_CONSTRUCTOR_SOURCE !== String(NativePromiseConstructor$3);
|
|
2497
|
+
// V8 6.6 (Node 10 and Chrome 66) have a bug with resolving custom thenables
|
|
2498
|
+
// https://bugs.chromium.org/p/chromium/issues/detail?id=830565
|
|
2499
|
+
// We can't detect it synchronously, so just check versions
|
|
2500
|
+
if (!GLOBAL_CORE_JS_PROMISE && V8_VERSION === 66) return true;
|
|
2501
|
+
// We can't use @@species feature detection in V8 since it causes
|
|
2502
|
+
// deoptimization and performance degradation
|
|
2503
|
+
// https://github.com/zloirock/core-js/issues/679
|
|
2504
|
+
if (!V8_VERSION || V8_VERSION < 51 || !/native code/.test(PROMISE_CONSTRUCTOR_SOURCE)) {
|
|
2505
|
+
// Detect correctness of subclassing with @@species support
|
|
2506
|
+
var promise = new NativePromiseConstructor$3(function (resolve) { resolve(1); });
|
|
2507
|
+
var FakePromise = function (exec) {
|
|
2508
|
+
exec(function () { /* empty */ }, function () { /* empty */ });
|
|
2509
|
+
};
|
|
2510
|
+
var constructor = promise.constructor = {};
|
|
2511
|
+
constructor[SPECIES] = FakePromise;
|
|
2512
|
+
SUBCLASSING = promise.then(function () { /* empty */ }) instanceof FakePromise;
|
|
2513
|
+
if (!SUBCLASSING) return true;
|
|
2514
|
+
// Unhandled rejections tracking support, NodeJS Promise without it fails @@species test
|
|
2515
|
+
} return !GLOBAL_CORE_JS_PROMISE && (ENVIRONMENT === 'BROWSER' || ENVIRONMENT === 'DENO') && !NATIVE_PROMISE_REJECTION_EVENT$1;
|
|
2516
|
+
});
|
|
2517
|
+
|
|
2518
|
+
var promiseConstructorDetection = {
|
|
2519
|
+
CONSTRUCTOR: FORCED_PROMISE_CONSTRUCTOR$5,
|
|
2520
|
+
REJECTION_EVENT: NATIVE_PROMISE_REJECTION_EVENT$1,
|
|
2521
|
+
SUBCLASSING: SUBCLASSING
|
|
2522
|
+
};
|
|
2523
|
+
|
|
2524
|
+
var newPromiseCapability$2 = {};
|
|
2525
|
+
|
|
2526
|
+
var aCallable$3 = aCallable$9;
|
|
2527
|
+
|
|
2528
|
+
var $TypeError = TypeError;
|
|
2529
|
+
|
|
2530
|
+
var PromiseCapability = function (C) {
|
|
2531
|
+
var resolve, reject;
|
|
2532
|
+
this.promise = new C(function ($$resolve, $$reject) {
|
|
2533
|
+
if (resolve !== undefined || reject !== undefined) throw new $TypeError('Bad Promise constructor');
|
|
2534
|
+
resolve = $$resolve;
|
|
2535
|
+
reject = $$reject;
|
|
2536
|
+
});
|
|
2537
|
+
this.resolve = aCallable$3(resolve);
|
|
2538
|
+
this.reject = aCallable$3(reject);
|
|
2539
|
+
};
|
|
2540
|
+
|
|
2541
|
+
// `NewPromiseCapability` abstract operation
|
|
2542
|
+
// https://tc39.es/ecma262/#sec-newpromisecapability
|
|
2543
|
+
newPromiseCapability$2.f = function (C) {
|
|
2544
|
+
return new PromiseCapability(C);
|
|
2545
|
+
};
|
|
2546
|
+
|
|
2547
|
+
var $$5 = _export;
|
|
2548
|
+
var IS_NODE = environmentIsNode;
|
|
2549
|
+
var globalThis$2 = globalThis_1;
|
|
2550
|
+
var path = path$1;
|
|
2551
|
+
var call$2 = functionCall;
|
|
2552
|
+
var defineBuiltIn$1 = defineBuiltIn$6;
|
|
2553
|
+
var setPrototypeOf = objectSetPrototypeOf;
|
|
2554
|
+
var setToStringTag$1 = setToStringTag$4;
|
|
2555
|
+
var setSpecies = setSpecies$1;
|
|
2556
|
+
var aCallable$2 = aCallable$9;
|
|
2557
|
+
var isCallable$1 = isCallable$k;
|
|
2558
|
+
var isObject$1 = isObject$a;
|
|
2559
|
+
var anInstance = anInstance$2;
|
|
2560
|
+
var speciesConstructor = speciesConstructor$1;
|
|
2561
|
+
var task = task$1.set;
|
|
2562
|
+
var microtask = microtask_1;
|
|
2563
|
+
var hostReportErrors = hostReportErrors$1;
|
|
2564
|
+
var perform$2 = perform$3;
|
|
2565
|
+
var Queue = queue$1;
|
|
2566
|
+
var InternalStateModule = internalState;
|
|
2567
|
+
var NativePromiseConstructor$2 = promiseNativeConstructor;
|
|
2568
|
+
var PromiseConstructorDetection = promiseConstructorDetection;
|
|
2569
|
+
var newPromiseCapabilityModule$3 = newPromiseCapability$2;
|
|
2570
|
+
|
|
2571
|
+
var PROMISE = 'Promise';
|
|
2572
|
+
var FORCED_PROMISE_CONSTRUCTOR$4 = PromiseConstructorDetection.CONSTRUCTOR;
|
|
2573
|
+
var NATIVE_PROMISE_REJECTION_EVENT = PromiseConstructorDetection.REJECTION_EVENT;
|
|
2574
|
+
var NATIVE_PROMISE_SUBCLASSING = PromiseConstructorDetection.SUBCLASSING;
|
|
2575
|
+
var getInternalPromiseState = InternalStateModule.getterFor(PROMISE);
|
|
2576
|
+
var setInternalState = InternalStateModule.set;
|
|
2577
|
+
var NativePromisePrototype$1 = NativePromiseConstructor$2 && NativePromiseConstructor$2.prototype;
|
|
2578
|
+
var PromiseConstructor = NativePromiseConstructor$2;
|
|
2579
|
+
var PromisePrototype = NativePromisePrototype$1;
|
|
2580
|
+
var TypeError$1 = globalThis$2.TypeError;
|
|
2581
|
+
var document$1 = globalThis$2.document;
|
|
2582
|
+
var process = globalThis$2.process;
|
|
2583
|
+
var newPromiseCapability$1 = newPromiseCapabilityModule$3.f;
|
|
2584
|
+
var newGenericPromiseCapability = newPromiseCapability$1;
|
|
2585
|
+
|
|
2586
|
+
var DISPATCH_EVENT = !!(document$1 && document$1.createEvent && globalThis$2.dispatchEvent);
|
|
2587
|
+
var UNHANDLED_REJECTION = 'unhandledrejection';
|
|
2588
|
+
var REJECTION_HANDLED = 'rejectionhandled';
|
|
2589
|
+
var PENDING = 0;
|
|
2590
|
+
var FULFILLED = 1;
|
|
2591
|
+
var REJECTED = 2;
|
|
2592
|
+
var HANDLED = 1;
|
|
2593
|
+
var UNHANDLED = 2;
|
|
2594
|
+
|
|
2595
|
+
var Internal, OwnPromiseCapability, PromiseWrapper, nativeThen;
|
|
2596
|
+
|
|
2597
|
+
// helpers
|
|
2598
|
+
var isThenable = function (it) {
|
|
2599
|
+
var then;
|
|
2600
|
+
return isObject$1(it) && isCallable$1(then = it.then) ? then : false;
|
|
2601
|
+
};
|
|
2602
|
+
|
|
2603
|
+
var callReaction = function (reaction, state) {
|
|
2604
|
+
var value = state.value;
|
|
2605
|
+
var ok = state.state === FULFILLED;
|
|
2606
|
+
var handler = ok ? reaction.ok : reaction.fail;
|
|
2607
|
+
var resolve = reaction.resolve;
|
|
2608
|
+
var reject = reaction.reject;
|
|
2609
|
+
var domain = reaction.domain;
|
|
2610
|
+
var result, then, exited;
|
|
2611
|
+
try {
|
|
2612
|
+
if (handler) {
|
|
2613
|
+
if (!ok) {
|
|
2614
|
+
if (state.rejection === UNHANDLED) onHandleUnhandled(state);
|
|
2615
|
+
state.rejection = HANDLED;
|
|
2616
|
+
}
|
|
2617
|
+
if (handler === true) result = value;
|
|
2618
|
+
else {
|
|
2619
|
+
if (domain) domain.enter();
|
|
2620
|
+
result = handler(value); // can throw
|
|
2621
|
+
if (domain) {
|
|
2622
|
+
domain.exit();
|
|
2623
|
+
exited = true;
|
|
2624
|
+
}
|
|
2625
|
+
}
|
|
2626
|
+
if (result === reaction.promise) {
|
|
2627
|
+
reject(new TypeError$1('Promise-chain cycle'));
|
|
2628
|
+
} else if (then = isThenable(result)) {
|
|
2629
|
+
call$2(then, result, resolve, reject);
|
|
2630
|
+
} else resolve(result);
|
|
2631
|
+
} else reject(value);
|
|
2632
|
+
} catch (error) {
|
|
2633
|
+
if (domain && !exited) domain.exit();
|
|
2634
|
+
reject(error);
|
|
2635
|
+
}
|
|
2636
|
+
};
|
|
2637
|
+
|
|
2638
|
+
var notify = function (state, isReject) {
|
|
2639
|
+
if (state.notified) return;
|
|
2640
|
+
state.notified = true;
|
|
2641
|
+
microtask(function () {
|
|
2642
|
+
var reactions = state.reactions;
|
|
2643
|
+
var reaction;
|
|
2644
|
+
while (reaction = reactions.get()) {
|
|
2645
|
+
callReaction(reaction, state);
|
|
2646
|
+
}
|
|
2647
|
+
state.notified = false;
|
|
2648
|
+
if (isReject && !state.rejection) onUnhandled(state);
|
|
2649
|
+
});
|
|
2650
|
+
};
|
|
2651
|
+
|
|
2652
|
+
var dispatchEvent = function (name, promise, reason) {
|
|
2653
|
+
var event, handler;
|
|
2654
|
+
if (DISPATCH_EVENT) {
|
|
2655
|
+
event = document$1.createEvent('Event');
|
|
2656
|
+
event.promise = promise;
|
|
2657
|
+
event.reason = reason;
|
|
2658
|
+
event.initEvent(name, false, true);
|
|
2659
|
+
globalThis$2.dispatchEvent(event);
|
|
2660
|
+
} else event = { promise: promise, reason: reason };
|
|
2661
|
+
if (!NATIVE_PROMISE_REJECTION_EVENT && (handler = globalThis$2['on' + name])) handler(event);
|
|
2662
|
+
else if (name === UNHANDLED_REJECTION) hostReportErrors('Unhandled promise rejection', reason);
|
|
2663
|
+
};
|
|
2664
|
+
|
|
2665
|
+
var onUnhandled = function (state) {
|
|
2666
|
+
call$2(task, globalThis$2, function () {
|
|
2667
|
+
var promise = state.facade;
|
|
2668
|
+
var value = state.value;
|
|
2669
|
+
var IS_UNHANDLED = isUnhandled(state);
|
|
2670
|
+
var result;
|
|
2671
|
+
if (IS_UNHANDLED) {
|
|
2672
|
+
result = perform$2(function () {
|
|
2673
|
+
if (IS_NODE) {
|
|
2674
|
+
process.emit('unhandledRejection', value, promise);
|
|
2675
|
+
} else dispatchEvent(UNHANDLED_REJECTION, promise, value);
|
|
2676
|
+
});
|
|
2677
|
+
// Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should
|
|
2678
|
+
state.rejection = IS_NODE || isUnhandled(state) ? UNHANDLED : HANDLED;
|
|
2679
|
+
if (result.error) throw result.value;
|
|
2680
|
+
}
|
|
2681
|
+
});
|
|
2682
|
+
};
|
|
2683
|
+
|
|
2684
|
+
var isUnhandled = function (state) {
|
|
2685
|
+
return state.rejection !== HANDLED && !state.parent;
|
|
2686
|
+
};
|
|
2687
|
+
|
|
2688
|
+
var onHandleUnhandled = function (state) {
|
|
2689
|
+
call$2(task, globalThis$2, function () {
|
|
2690
|
+
var promise = state.facade;
|
|
2691
|
+
if (IS_NODE) {
|
|
2692
|
+
process.emit('rejectionHandled', promise);
|
|
2693
|
+
} else dispatchEvent(REJECTION_HANDLED, promise, state.value);
|
|
2694
|
+
});
|
|
2695
|
+
};
|
|
2696
|
+
|
|
2697
|
+
var bind = function (fn, state, unwrap) {
|
|
2698
|
+
return function (value) {
|
|
2699
|
+
fn(state, value, unwrap);
|
|
2700
|
+
};
|
|
2701
|
+
};
|
|
2702
|
+
|
|
2703
|
+
var internalReject = function (state, value, unwrap) {
|
|
2704
|
+
if (state.done) return;
|
|
2705
|
+
state.done = true;
|
|
2706
|
+
if (unwrap) state = unwrap;
|
|
2707
|
+
state.value = value;
|
|
2708
|
+
state.state = REJECTED;
|
|
2709
|
+
notify(state, true);
|
|
2710
|
+
};
|
|
2711
|
+
|
|
2712
|
+
var internalResolve = function (state, value, unwrap) {
|
|
2713
|
+
if (state.done) return;
|
|
2714
|
+
state.done = true;
|
|
2715
|
+
if (unwrap) state = unwrap;
|
|
2716
|
+
try {
|
|
2717
|
+
if (state.facade === value) throw new TypeError$1("Promise can't be resolved itself");
|
|
2718
|
+
var then = isThenable(value);
|
|
2719
|
+
if (then) {
|
|
2720
|
+
microtask(function () {
|
|
2721
|
+
var wrapper = { done: false };
|
|
2722
|
+
try {
|
|
2723
|
+
call$2(then, value,
|
|
2724
|
+
bind(internalResolve, wrapper, state),
|
|
2725
|
+
bind(internalReject, wrapper, state)
|
|
2726
|
+
);
|
|
2727
|
+
} catch (error) {
|
|
2728
|
+
internalReject(wrapper, error, state);
|
|
2729
|
+
}
|
|
2730
|
+
});
|
|
2731
|
+
} else {
|
|
2732
|
+
state.value = value;
|
|
2733
|
+
state.state = FULFILLED;
|
|
2734
|
+
notify(state, false);
|
|
2735
|
+
}
|
|
2736
|
+
} catch (error) {
|
|
2737
|
+
internalReject({ done: false }, error, state);
|
|
2738
|
+
}
|
|
2739
|
+
};
|
|
2740
|
+
|
|
2741
|
+
// constructor polyfill
|
|
2742
|
+
if (FORCED_PROMISE_CONSTRUCTOR$4) {
|
|
2743
|
+
// 25.4.3.1 Promise(executor)
|
|
2744
|
+
PromiseConstructor = function Promise(executor) {
|
|
2745
|
+
anInstance(this, PromisePrototype);
|
|
2746
|
+
aCallable$2(executor);
|
|
2747
|
+
call$2(Internal, this);
|
|
2748
|
+
var state = getInternalPromiseState(this);
|
|
2749
|
+
try {
|
|
2750
|
+
executor(bind(internalResolve, state), bind(internalReject, state));
|
|
2751
|
+
} catch (error) {
|
|
2752
|
+
internalReject(state, error);
|
|
2753
|
+
}
|
|
2754
|
+
};
|
|
2755
|
+
|
|
2756
|
+
PromisePrototype = PromiseConstructor.prototype;
|
|
2757
|
+
|
|
2758
|
+
// eslint-disable-next-line no-unused-vars -- required for `.length`
|
|
2759
|
+
Internal = function Promise(executor) {
|
|
2760
|
+
setInternalState(this, {
|
|
2761
|
+
type: PROMISE,
|
|
2762
|
+
done: false,
|
|
2763
|
+
notified: false,
|
|
2764
|
+
parent: false,
|
|
2765
|
+
reactions: new Queue(),
|
|
2766
|
+
rejection: false,
|
|
2767
|
+
state: PENDING,
|
|
2768
|
+
value: null
|
|
2769
|
+
});
|
|
2770
|
+
};
|
|
2771
|
+
|
|
2772
|
+
// `Promise.prototype.then` method
|
|
2773
|
+
// https://tc39.es/ecma262/#sec-promise.prototype.then
|
|
2774
|
+
Internal.prototype = defineBuiltIn$1(PromisePrototype, 'then', function then(onFulfilled, onRejected) {
|
|
2775
|
+
var state = getInternalPromiseState(this);
|
|
2776
|
+
var reaction = newPromiseCapability$1(speciesConstructor(this, PromiseConstructor));
|
|
2777
|
+
state.parent = true;
|
|
2778
|
+
reaction.ok = isCallable$1(onFulfilled) ? onFulfilled : true;
|
|
2779
|
+
reaction.fail = isCallable$1(onRejected) && onRejected;
|
|
2780
|
+
reaction.domain = IS_NODE ? process.domain : undefined;
|
|
2781
|
+
if (state.state === PENDING) state.reactions.add(reaction);
|
|
2782
|
+
else microtask(function () {
|
|
2783
|
+
callReaction(reaction, state);
|
|
2784
|
+
});
|
|
2785
|
+
return reaction.promise;
|
|
2786
|
+
});
|
|
2787
|
+
|
|
2788
|
+
OwnPromiseCapability = function () {
|
|
2789
|
+
var promise = new Internal();
|
|
2790
|
+
var state = getInternalPromiseState(promise);
|
|
2791
|
+
this.promise = promise;
|
|
2792
|
+
this.resolve = bind(internalResolve, state);
|
|
2793
|
+
this.reject = bind(internalReject, state);
|
|
2794
|
+
};
|
|
2795
|
+
|
|
2796
|
+
newPromiseCapabilityModule$3.f = newPromiseCapability$1 = function (C) {
|
|
2797
|
+
return C === PromiseConstructor || C === PromiseWrapper
|
|
2798
|
+
? new OwnPromiseCapability(C)
|
|
2799
|
+
: newGenericPromiseCapability(C);
|
|
2800
|
+
};
|
|
2801
|
+
|
|
2802
|
+
if (isCallable$1(NativePromiseConstructor$2) && NativePromisePrototype$1 !== Object.prototype) {
|
|
2803
|
+
nativeThen = NativePromisePrototype$1.then;
|
|
2804
|
+
|
|
2805
|
+
if (!NATIVE_PROMISE_SUBCLASSING) {
|
|
2806
|
+
// make `Promise#then` return a polyfilled `Promise` for native promise-based APIs
|
|
2807
|
+
defineBuiltIn$1(NativePromisePrototype$1, 'then', function then(onFulfilled, onRejected) {
|
|
2808
|
+
var that = this;
|
|
2809
|
+
return new PromiseConstructor(function (resolve, reject) {
|
|
2810
|
+
call$2(nativeThen, that, resolve, reject);
|
|
2811
|
+
}).then(onFulfilled, onRejected);
|
|
2812
|
+
// https://github.com/zloirock/core-js/issues/640
|
|
2813
|
+
}, { unsafe: true });
|
|
2814
|
+
}
|
|
2815
|
+
|
|
2816
|
+
// make `.constructor === Promise` work for native promise-based APIs
|
|
2817
|
+
try {
|
|
2818
|
+
delete NativePromisePrototype$1.constructor;
|
|
2819
|
+
} catch (error) { /* empty */ }
|
|
2820
|
+
|
|
2821
|
+
// make `instanceof Promise` work for native promise-based APIs
|
|
2822
|
+
if (setPrototypeOf) {
|
|
2823
|
+
setPrototypeOf(NativePromisePrototype$1, PromisePrototype);
|
|
2824
|
+
}
|
|
2825
|
+
}
|
|
2826
|
+
}
|
|
2827
|
+
|
|
2828
|
+
// `Promise` constructor
|
|
2829
|
+
// https://tc39.es/ecma262/#sec-promise-executor
|
|
2830
|
+
$$5({ global: true, constructor: true, wrap: true, forced: FORCED_PROMISE_CONSTRUCTOR$4 }, {
|
|
2831
|
+
Promise: PromiseConstructor
|
|
2832
|
+
});
|
|
2833
|
+
|
|
2834
|
+
PromiseWrapper = path.Promise;
|
|
2835
|
+
|
|
2836
|
+
setToStringTag$1(PromiseConstructor, PROMISE, false);
|
|
2837
|
+
setSpecies(PROMISE);
|
|
2838
|
+
|
|
2839
|
+
var wellKnownSymbol$1 = wellKnownSymbol$g;
|
|
2840
|
+
|
|
2841
|
+
var ITERATOR$1 = wellKnownSymbol$1('iterator');
|
|
2842
|
+
var SAFE_CLOSING = false;
|
|
2843
|
+
|
|
2844
|
+
try {
|
|
2845
|
+
var called = 0;
|
|
2846
|
+
var iteratorWithReturn = {
|
|
2847
|
+
next: function () {
|
|
2848
|
+
return { done: !!called++ };
|
|
2849
|
+
},
|
|
2850
|
+
'return': function () {
|
|
2851
|
+
SAFE_CLOSING = true;
|
|
2852
|
+
}
|
|
2853
|
+
};
|
|
2854
|
+
// eslint-disable-next-line unicorn/no-immediate-mutation -- ES3 syntax limitation
|
|
2855
|
+
iteratorWithReturn[ITERATOR$1] = function () {
|
|
2856
|
+
return this;
|
|
2857
|
+
};
|
|
2858
|
+
// eslint-disable-next-line es/no-array-from, no-throw-literal -- required for testing
|
|
2859
|
+
Array.from(iteratorWithReturn, function () { throw 2; });
|
|
2860
|
+
} catch (error) { /* empty */ }
|
|
2861
|
+
|
|
2862
|
+
var checkCorrectnessOfIteration$1 = function (exec, SKIP_CLOSING) {
|
|
2863
|
+
try {
|
|
2864
|
+
if (!SKIP_CLOSING && !SAFE_CLOSING) return false;
|
|
2865
|
+
} catch (error) { return false; } // workaround of old WebKit + `eval` bug
|
|
2866
|
+
var ITERATION_SUPPORT = false;
|
|
2867
|
+
try {
|
|
2868
|
+
var object = {};
|
|
2869
|
+
// eslint-disable-next-line unicorn/no-immediate-mutation -- ES3 syntax limitation
|
|
2870
|
+
object[ITERATOR$1] = function () {
|
|
2871
|
+
return {
|
|
2872
|
+
next: function () {
|
|
2873
|
+
return { done: ITERATION_SUPPORT = true };
|
|
2874
|
+
}
|
|
2875
|
+
};
|
|
2876
|
+
};
|
|
2877
|
+
exec(object);
|
|
2878
|
+
} catch (error) { /* empty */ }
|
|
2879
|
+
return ITERATION_SUPPORT;
|
|
2880
|
+
};
|
|
2881
|
+
|
|
2882
|
+
var NativePromiseConstructor$1 = promiseNativeConstructor;
|
|
2883
|
+
var checkCorrectnessOfIteration = checkCorrectnessOfIteration$1;
|
|
2884
|
+
var FORCED_PROMISE_CONSTRUCTOR$3 = promiseConstructorDetection.CONSTRUCTOR;
|
|
2885
|
+
|
|
2886
|
+
var promiseStaticsIncorrectIteration = FORCED_PROMISE_CONSTRUCTOR$3 || !checkCorrectnessOfIteration(function (iterable) {
|
|
2887
|
+
NativePromiseConstructor$1.all(iterable).then(undefined, function () { /* empty */ });
|
|
2888
|
+
});
|
|
2889
|
+
|
|
2890
|
+
var $$4 = _export;
|
|
2891
|
+
var call$1 = functionCall;
|
|
2892
|
+
var aCallable$1 = aCallable$9;
|
|
2893
|
+
var newPromiseCapabilityModule$2 = newPromiseCapability$2;
|
|
2894
|
+
var perform$1 = perform$3;
|
|
2895
|
+
var iterate$1 = iterate$3;
|
|
2896
|
+
var PROMISE_STATICS_INCORRECT_ITERATION$1 = promiseStaticsIncorrectIteration;
|
|
2897
|
+
|
|
2898
|
+
// `Promise.all` method
|
|
2899
|
+
// https://tc39.es/ecma262/#sec-promise.all
|
|
2900
|
+
$$4({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION$1 }, {
|
|
2901
|
+
all: function all(iterable) {
|
|
2902
|
+
var C = this;
|
|
2903
|
+
var capability = newPromiseCapabilityModule$2.f(C);
|
|
2904
|
+
var resolve = capability.resolve;
|
|
2905
|
+
var reject = capability.reject;
|
|
2906
|
+
var result = perform$1(function () {
|
|
2907
|
+
var $promiseResolve = aCallable$1(C.resolve);
|
|
2908
|
+
var values = [];
|
|
2909
|
+
var counter = 0;
|
|
2910
|
+
var remaining = 1;
|
|
2911
|
+
iterate$1(iterable, function (promise) {
|
|
2912
|
+
var index = counter++;
|
|
2913
|
+
var alreadyCalled = false;
|
|
2914
|
+
remaining++;
|
|
2915
|
+
call$1($promiseResolve, C, promise).then(function (value) {
|
|
2916
|
+
if (alreadyCalled) return;
|
|
2917
|
+
alreadyCalled = true;
|
|
2918
|
+
values[index] = value;
|
|
2919
|
+
--remaining || resolve(values);
|
|
2920
|
+
}, reject);
|
|
2921
|
+
});
|
|
2922
|
+
--remaining || resolve(values);
|
|
2923
|
+
});
|
|
2924
|
+
if (result.error) reject(result.value);
|
|
2925
|
+
return capability.promise;
|
|
2926
|
+
}
|
|
2927
|
+
});
|
|
2928
|
+
|
|
2929
|
+
var $$3 = _export;
|
|
2930
|
+
var FORCED_PROMISE_CONSTRUCTOR$2 = promiseConstructorDetection.CONSTRUCTOR;
|
|
2931
|
+
var NativePromiseConstructor = promiseNativeConstructor;
|
|
2932
|
+
var getBuiltIn$1 = getBuiltIn$7;
|
|
2933
|
+
var isCallable = isCallable$k;
|
|
2934
|
+
var defineBuiltIn = defineBuiltIn$6;
|
|
2935
|
+
|
|
2936
|
+
var NativePromisePrototype = NativePromiseConstructor && NativePromiseConstructor.prototype;
|
|
2937
|
+
|
|
2938
|
+
// `Promise.prototype.catch` method
|
|
2939
|
+
// https://tc39.es/ecma262/#sec-promise.prototype.catch
|
|
2940
|
+
$$3({ target: 'Promise', proto: true, forced: FORCED_PROMISE_CONSTRUCTOR$2, real: true }, {
|
|
2941
|
+
'catch': function (onRejected) {
|
|
2942
|
+
return this.then(undefined, onRejected);
|
|
2943
|
+
}
|
|
2944
|
+
});
|
|
2945
|
+
|
|
2946
|
+
// makes sure that native promise-based APIs `Promise#catch` properly works with patched `Promise#then`
|
|
2947
|
+
if (isCallable(NativePromiseConstructor)) {
|
|
2948
|
+
var method = getBuiltIn$1('Promise').prototype['catch'];
|
|
2949
|
+
if (NativePromisePrototype['catch'] !== method) {
|
|
2950
|
+
defineBuiltIn(NativePromisePrototype, 'catch', method, { unsafe: true });
|
|
2951
|
+
}
|
|
2952
|
+
}
|
|
2953
|
+
|
|
2954
|
+
var $$2 = _export;
|
|
2955
|
+
var call = functionCall;
|
|
2956
|
+
var aCallable = aCallable$9;
|
|
2957
|
+
var newPromiseCapabilityModule$1 = newPromiseCapability$2;
|
|
2958
|
+
var perform = perform$3;
|
|
2959
|
+
var iterate = iterate$3;
|
|
2960
|
+
var PROMISE_STATICS_INCORRECT_ITERATION = promiseStaticsIncorrectIteration;
|
|
2961
|
+
|
|
2962
|
+
// `Promise.race` method
|
|
2963
|
+
// https://tc39.es/ecma262/#sec-promise.race
|
|
2964
|
+
$$2({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION }, {
|
|
2965
|
+
race: function race(iterable) {
|
|
2966
|
+
var C = this;
|
|
2967
|
+
var capability = newPromiseCapabilityModule$1.f(C);
|
|
2968
|
+
var reject = capability.reject;
|
|
2969
|
+
var result = perform(function () {
|
|
2970
|
+
var $promiseResolve = aCallable(C.resolve);
|
|
2971
|
+
iterate(iterable, function (promise) {
|
|
2972
|
+
call($promiseResolve, C, promise).then(capability.resolve, reject);
|
|
2973
|
+
});
|
|
2974
|
+
});
|
|
2975
|
+
if (result.error) reject(result.value);
|
|
2976
|
+
return capability.promise;
|
|
2977
|
+
}
|
|
2978
|
+
});
|
|
2979
|
+
|
|
2980
|
+
var $$1 = _export;
|
|
2981
|
+
var newPromiseCapabilityModule = newPromiseCapability$2;
|
|
2982
|
+
var FORCED_PROMISE_CONSTRUCTOR$1 = promiseConstructorDetection.CONSTRUCTOR;
|
|
2983
|
+
|
|
2984
|
+
// `Promise.reject` method
|
|
2985
|
+
// https://tc39.es/ecma262/#sec-promise.reject
|
|
2986
|
+
$$1({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR$1 }, {
|
|
2987
|
+
reject: function reject(r) {
|
|
2988
|
+
var capability = newPromiseCapabilityModule.f(this);
|
|
2989
|
+
var capabilityReject = capability.reject;
|
|
2990
|
+
capabilityReject(r);
|
|
2991
|
+
return capability.promise;
|
|
2992
|
+
}
|
|
2993
|
+
});
|
|
2994
|
+
|
|
2995
|
+
var anObject = anObject$d;
|
|
2996
|
+
var isObject = isObject$a;
|
|
2997
|
+
var newPromiseCapability = newPromiseCapability$2;
|
|
2998
|
+
|
|
2999
|
+
var promiseResolve$1 = function (C, x) {
|
|
3000
|
+
anObject(C);
|
|
3001
|
+
if (isObject(x) && x.constructor === C) return x;
|
|
3002
|
+
var promiseCapability = newPromiseCapability.f(C);
|
|
3003
|
+
var resolve = promiseCapability.resolve;
|
|
3004
|
+
resolve(x);
|
|
3005
|
+
return promiseCapability.promise;
|
|
3006
|
+
};
|
|
3007
|
+
|
|
3008
|
+
var $ = _export;
|
|
3009
|
+
var getBuiltIn = getBuiltIn$7;
|
|
3010
|
+
var FORCED_PROMISE_CONSTRUCTOR = promiseConstructorDetection.CONSTRUCTOR;
|
|
3011
|
+
var promiseResolve = promiseResolve$1;
|
|
3012
|
+
|
|
3013
|
+
getBuiltIn('Promise');
|
|
3014
|
+
|
|
3015
|
+
// `Promise.resolve` method
|
|
3016
|
+
// https://tc39.es/ecma262/#sec-promise.resolve
|
|
3017
|
+
$({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR }, {
|
|
3018
|
+
resolve: function resolve(x) {
|
|
3019
|
+
return promiseResolve(this, x);
|
|
3020
|
+
}
|
|
3021
|
+
});
|
|
3022
|
+
|
|
3023
|
+
// iterable DOM collections
|
|
3024
|
+
// flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods
|
|
3025
|
+
var domIterables = {
|
|
3026
|
+
CSSRuleList: 0,
|
|
3027
|
+
CSSStyleDeclaration: 0,
|
|
3028
|
+
CSSValueList: 0,
|
|
3029
|
+
ClientRectList: 0,
|
|
3030
|
+
DOMRectList: 0,
|
|
3031
|
+
DOMStringList: 0,
|
|
3032
|
+
DOMTokenList: 1,
|
|
3033
|
+
DataTransferItemList: 0,
|
|
3034
|
+
FileList: 0,
|
|
3035
|
+
HTMLAllCollection: 0,
|
|
3036
|
+
HTMLCollection: 0,
|
|
3037
|
+
HTMLFormElement: 0,
|
|
3038
|
+
HTMLSelectElement: 0,
|
|
3039
|
+
MediaList: 0,
|
|
3040
|
+
MimeTypeArray: 0,
|
|
3041
|
+
NamedNodeMap: 0,
|
|
3042
|
+
NodeList: 1,
|
|
3043
|
+
PaintRequestList: 0,
|
|
3044
|
+
Plugin: 0,
|
|
3045
|
+
PluginArray: 0,
|
|
3046
|
+
SVGLengthList: 0,
|
|
3047
|
+
SVGNumberList: 0,
|
|
3048
|
+
SVGPathSegList: 0,
|
|
3049
|
+
SVGPointList: 0,
|
|
3050
|
+
SVGStringList: 0,
|
|
3051
|
+
SVGTransformList: 0,
|
|
3052
|
+
SourceBufferList: 0,
|
|
3053
|
+
StyleSheetList: 0,
|
|
3054
|
+
TextTrackCueList: 0,
|
|
3055
|
+
TextTrackList: 0,
|
|
3056
|
+
TouchList: 0
|
|
3057
|
+
};
|
|
3058
|
+
|
|
3059
|
+
// in old WebKit versions, `element.classList` is not an instance of global `DOMTokenList`
|
|
3060
|
+
var documentCreateElement = documentCreateElement$2;
|
|
3061
|
+
|
|
3062
|
+
var classList = documentCreateElement('span').classList;
|
|
3063
|
+
var DOMTokenListPrototype$1 = classList && classList.constructor && classList.constructor.prototype;
|
|
3064
|
+
|
|
3065
|
+
var domTokenListPrototype = DOMTokenListPrototype$1 === Object.prototype ? undefined : DOMTokenListPrototype$1;
|
|
3066
|
+
|
|
3067
|
+
var globalThis$1 = globalThis_1;
|
|
3068
|
+
var DOMIterables = domIterables;
|
|
3069
|
+
var DOMTokenListPrototype = domTokenListPrototype;
|
|
3070
|
+
var ArrayIteratorMethods = es_array_iterator;
|
|
3071
|
+
var createNonEnumerableProperty = createNonEnumerableProperty$5;
|
|
3072
|
+
var setToStringTag = setToStringTag$4;
|
|
3073
|
+
var wellKnownSymbol = wellKnownSymbol$g;
|
|
3074
|
+
|
|
3075
|
+
var ITERATOR = wellKnownSymbol('iterator');
|
|
3076
|
+
var ArrayValues = ArrayIteratorMethods.values;
|
|
3077
|
+
|
|
3078
|
+
var handlePrototype = function (CollectionPrototype, COLLECTION_NAME) {
|
|
3079
|
+
if (CollectionPrototype) {
|
|
3080
|
+
// some Chrome versions have non-configurable methods on DOMTokenList
|
|
3081
|
+
if (CollectionPrototype[ITERATOR] !== ArrayValues) try {
|
|
3082
|
+
createNonEnumerableProperty(CollectionPrototype, ITERATOR, ArrayValues);
|
|
3083
|
+
} catch (error) {
|
|
3084
|
+
CollectionPrototype[ITERATOR] = ArrayValues;
|
|
3085
|
+
}
|
|
3086
|
+
setToStringTag(CollectionPrototype, COLLECTION_NAME, true);
|
|
3087
|
+
if (DOMIterables[COLLECTION_NAME]) for (var METHOD_NAME in ArrayIteratorMethods) {
|
|
3088
|
+
// some Chrome versions have non-configurable methods on DOMTokenList
|
|
3089
|
+
if (CollectionPrototype[METHOD_NAME] !== ArrayIteratorMethods[METHOD_NAME]) try {
|
|
3090
|
+
createNonEnumerableProperty(CollectionPrototype, METHOD_NAME, ArrayIteratorMethods[METHOD_NAME]);
|
|
3091
|
+
} catch (error) {
|
|
3092
|
+
CollectionPrototype[METHOD_NAME] = ArrayIteratorMethods[METHOD_NAME];
|
|
3093
|
+
}
|
|
3094
|
+
}
|
|
3095
|
+
}
|
|
3096
|
+
};
|
|
3097
|
+
|
|
3098
|
+
for (var COLLECTION_NAME in DOMIterables) {
|
|
3099
|
+
handlePrototype(globalThis$1[COLLECTION_NAME] && globalThis$1[COLLECTION_NAME].prototype, COLLECTION_NAME);
|
|
3100
|
+
}
|
|
3101
|
+
|
|
3102
|
+
handlePrototype(DOMTokenListPrototype, 'DOMTokenList');
|
|
3103
|
+
|
|
3104
|
+
const SliderItemContainer = /*#__PURE__*/styled__default.default.div.withConfig({
|
|
3105
|
+
displayName: "molecules-sliderstyle__SliderItemContainer",
|
|
3106
|
+
componentId: "sc-sjtfzf-0"
|
|
3107
|
+
})(["user-select:none;box-sizing:border-box;img,svg{pointer-events:none;}"]);
|
|
3108
|
+
const SliderContainer = /*#__PURE__*/styled__default.default.div.withConfig({
|
|
3109
|
+
displayName: "molecules-sliderstyle__SliderContainer",
|
|
3110
|
+
componentId: "sc-sjtfzf-1"
|
|
3111
|
+
})(["position:relative;overflow:hidden;box-sizing:border-box;padding-bottom:", ";", "{width:", ";flex-shrink:0;}&:focus-visible{outline:2px solid #000;outline-offset:2px;}.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0);}"], ({
|
|
3112
|
+
theme,
|
|
3113
|
+
$showBullets
|
|
3114
|
+
}) => $showBullets ? theme.tokens.padding.XL : '0', SliderItemContainer, ({
|
|
3115
|
+
theme,
|
|
3116
|
+
$size,
|
|
3117
|
+
$slidesPerPage
|
|
3118
|
+
}) => $slidesPerPage > 1 ? `calc(${$size}% - ${theme.tokens.flexbox.XXS})` : `${$size}%`);
|
|
3119
|
+
const SliderContent = /*#__PURE__*/styled__default.default.div.withConfig({
|
|
3120
|
+
displayName: "molecules-sliderstyle__SliderContent",
|
|
3121
|
+
componentId: "sc-sjtfzf-2"
|
|
3122
|
+
})(["display:flex;", ";"], ({
|
|
3123
|
+
$slidesPerPage
|
|
3124
|
+
}) => $slidesPerPage > 1 && styled.css(["gap:", ";"], ({
|
|
3125
|
+
theme
|
|
3126
|
+
}) => theme.tokens.flexbox.XXS));
|
|
3127
|
+
const ButtonContainer = /*#__PURE__*/styled__default.default.div.withConfig({
|
|
3128
|
+
displayName: "molecules-sliderstyle__ButtonContainer",
|
|
3129
|
+
componentId: "sc-sjtfzf-3"
|
|
3130
|
+
})(["position:absolute;top:50%;transform:translateY(-50%);", ";&:focus-visible{outline:2px solid #000;outline-offset:2px;}@media only screen and (max-width:", "px){display:none;}"], ({
|
|
3131
|
+
$side
|
|
3132
|
+
}) => $side === 'left' ? styled.css(["left:", ";"], ({
|
|
3133
|
+
theme
|
|
3134
|
+
}) => theme.tokens.padding.L) : styled.css(["right:", ";"], ({
|
|
3135
|
+
theme
|
|
3136
|
+
}) => theme.tokens.padding.L), frontendFoundations.ScreenSizes.SM.max);
|
|
3137
|
+
const PageBulletContainer = /*#__PURE__*/styled__default.default.div.withConfig({
|
|
3138
|
+
displayName: "molecules-sliderstyle__PageBulletContainer",
|
|
3139
|
+
componentId: "sc-sjtfzf-4"
|
|
3140
|
+
})(["position:absolute;display:flex;gap:", ";bottom:", ";left:50%;transform:translate(-50%,50%);&:focus-visible{outline:2px solid #000;outline-offset:2px;}"], ({
|
|
3141
|
+
theme
|
|
3142
|
+
}) => theme.tokens.flexbox.XXS, ({
|
|
3143
|
+
theme
|
|
3144
|
+
}) => `calc(${theme.tokens.padding.XL} / 2)`);
|
|
3145
|
+
const PageBullet = /*#__PURE__*/styled__default.default.button.withConfig({
|
|
3146
|
+
displayName: "molecules-sliderstyle__PageBullet",
|
|
3147
|
+
componentId: "sc-sjtfzf-5"
|
|
3148
|
+
})(["all:unset;width:16px;height:4px;border-radius:", ";background-color:", ";cursor:pointer;&:focus-visible{outline:2px solid #000;outline-offset:2px;}"], ({
|
|
3149
|
+
theme
|
|
3150
|
+
}) => theme.tokens.borderRadius.S, ({
|
|
3151
|
+
theme,
|
|
3152
|
+
$active
|
|
3153
|
+
}) => $active ? theme.colors.background.accent : theme.colors.background.weak);
|
|
3154
|
+
|
|
3155
|
+
const MAX_DISTANCE_TRESHOLD = 75;
|
|
3156
|
+
const ANIMATION_DURATION = '.4s';
|
|
3157
|
+
function isTouch(event) {
|
|
3158
|
+
return 'touches' in event;
|
|
3159
|
+
}
|
|
3160
|
+
const SliderItem = /*#__PURE__*/React.forwardRef(({
|
|
3161
|
+
children
|
|
3162
|
+
}, ref) => {
|
|
3163
|
+
return jsxRuntime.jsx(SliderItemContainer, {
|
|
3164
|
+
ref: ref,
|
|
3165
|
+
draggable: "false",
|
|
3166
|
+
role: "group",
|
|
3167
|
+
"aria-roledescription": "slide",
|
|
3168
|
+
children: children
|
|
3169
|
+
});
|
|
3170
|
+
});
|
|
3171
|
+
const Slider = /*#__PURE__*/React.forwardRef(({
|
|
3172
|
+
id: _id = 'slider',
|
|
3173
|
+
dataTestId: _dataTestId = 'slider',
|
|
3174
|
+
currentPage,
|
|
3175
|
+
slidesPerPage: _slidesPerPage = 1,
|
|
3176
|
+
showArrows: _showArrows = true,
|
|
3177
|
+
showBullets: _showBullets = true,
|
|
3178
|
+
duration: _duration = 5000,
|
|
3179
|
+
count,
|
|
3180
|
+
onChange,
|
|
3181
|
+
children
|
|
3182
|
+
}, ref) => {
|
|
3183
|
+
var _a, _b, _c;
|
|
3184
|
+
const [finalSlidesPerPage, setFinalSlidesPerPage] = React.useState(_slidesPerPage);
|
|
3185
|
+
const [isHydrated, setIsHydrated] = React.useState(false);
|
|
3186
|
+
const containerRef = React.useRef(null);
|
|
3187
|
+
const contentRef = React.useRef(null);
|
|
3188
|
+
const intervalRef = React.useRef(null);
|
|
3189
|
+
const startXPosition = React.useRef(0);
|
|
3190
|
+
const dragDistance = React.useRef(0);
|
|
3191
|
+
const childrenArray = React__default.default.Children.toArray(children);
|
|
3192
|
+
const finalChildrens = typeof count === 'undefined' && childrenArray.length === 1 && ((_b = (_a = childrenArray[0]) === null || _a === void 0 ? void 0 : _a.type) === null || _b === void 0 ? void 0 : _b.displayName) !== 'SliderItem' ? (_c = childrenArray[0].props) === null || _c === void 0 ? void 0 : _c.children : childrenArray;
|
|
3193
|
+
const totalSlides = typeof count !== 'undefined' ? count : finalChildrens.length;
|
|
3194
|
+
if (currentPage >= totalSlides) {
|
|
3195
|
+
onChange && onChange(totalSlides - 1);
|
|
3196
|
+
} else if (currentPage < 0) {
|
|
3197
|
+
onChange && onChange(0);
|
|
3198
|
+
}
|
|
3199
|
+
const pages = Array.from(Array(Math.ceil(totalSlides / finalSlidesPerPage)).keys());
|
|
3200
|
+
const baseTransform = `-100% * ${currentPage}`;
|
|
3201
|
+
const intervalFunction = React.useCallback(() => {
|
|
3202
|
+
const finalPage = currentPage === pages.length - 1 ? 0 : currentPage + 1;
|
|
3203
|
+
onChange && onChange(finalPage);
|
|
3204
|
+
}, [currentPage, onChange, pages.length]);
|
|
3205
|
+
const dragEvent = React.useCallback(event => {
|
|
3206
|
+
if (typeof window === 'undefined' || !contentRef.current) return;
|
|
3207
|
+
const clientX = isTouch(event) ? event.touches[0].clientX : event.clientX;
|
|
3208
|
+
const isFirstPage = currentPage === 0;
|
|
3209
|
+
const isLastPage = currentPage === pages.length - 1;
|
|
3210
|
+
const distance = startXPosition.current - clientX;
|
|
3211
|
+
let finalDistance = distance;
|
|
3212
|
+
if (isFirstPage && distance < -MAX_DISTANCE_TRESHOLD) {
|
|
3213
|
+
finalDistance = -MAX_DISTANCE_TRESHOLD;
|
|
3214
|
+
} else if (isLastPage && distance > MAX_DISTANCE_TRESHOLD) {
|
|
3215
|
+
finalDistance = MAX_DISTANCE_TRESHOLD;
|
|
3216
|
+
}
|
|
3217
|
+
dragDistance.current = finalDistance;
|
|
3218
|
+
contentRef.current.style.transform = `translateX(calc(${baseTransform} - ${dragDistance.current}px))`;
|
|
3219
|
+
contentRef.current.style.transition = '';
|
|
3220
|
+
}, [baseTransform, currentPage, pages.length]);
|
|
3221
|
+
const startDrag = React.useCallback(event => {
|
|
3222
|
+
if (!containerRef.current) return;
|
|
3223
|
+
startXPosition.current = isTouch(event) ? event.touches[0].clientX : event.clientX;
|
|
3224
|
+
if (_duration > 0 && intervalRef.current) window.clearInterval(intervalRef.current);
|
|
3225
|
+
containerRef.current.addEventListener('mousemove', dragEvent);
|
|
3226
|
+
containerRef.current.addEventListener('touchmove', dragEvent);
|
|
3227
|
+
}, [dragEvent, _duration]);
|
|
3228
|
+
const changePage = React.useCallback(page => {
|
|
3229
|
+
let finalPage = page;
|
|
3230
|
+
if (page >= pages.length) finalPage = 0;else if (page < 0) finalPage = pages.length - 1;
|
|
3231
|
+
if (_duration > 0 && intervalRef.current) {
|
|
3232
|
+
window.clearInterval(intervalRef.current);
|
|
3233
|
+
intervalRef.current = window.setInterval(intervalFunction, _duration);
|
|
3234
|
+
}
|
|
3235
|
+
onChange && onChange(finalPage);
|
|
3236
|
+
}, [_duration, intervalFunction, pages.length, onChange]);
|
|
3237
|
+
const stopDrag = React.useCallback(() => {
|
|
3238
|
+
if (!containerRef.current || !contentRef.current) return;
|
|
3239
|
+
if (dragDistance.current > MAX_DISTANCE_TRESHOLD) changePage(currentPage + 1);else if (dragDistance.current < -MAX_DISTANCE_TRESHOLD) changePage(currentPage - 1);else {
|
|
3240
|
+
if (_duration > 0) intervalRef.current = window.setInterval(intervalFunction, _duration);
|
|
3241
|
+
contentRef.current.style.transform = `translateX(calc(${baseTransform}))`;
|
|
3242
|
+
}
|
|
3243
|
+
contentRef.current.style.transition = `transform ${ANIMATION_DURATION}`;
|
|
3244
|
+
containerRef.current.removeEventListener('mousemove', dragEvent);
|
|
3245
|
+
containerRef.current.removeEventListener('touchmove', dragEvent);
|
|
3246
|
+
dragDistance.current = 0;
|
|
3247
|
+
startXPosition.current = 0;
|
|
3248
|
+
}, [dragEvent, _duration, intervalFunction, baseTransform, changePage, currentPage]);
|
|
3249
|
+
const resizeEvent = React.useCallback(() => {
|
|
3250
|
+
if (typeof window === 'undefined' || !frontendFoundations.ScreenSizes.SM.max) return;
|
|
3251
|
+
if (window.innerWidth <= frontendFoundations.ScreenSizes.SM.max && finalSlidesPerPage > 1) {
|
|
3252
|
+
setFinalSlidesPerPage(1);
|
|
3253
|
+
onChange && onChange(0);
|
|
3254
|
+
} else if (window.innerWidth > frontendFoundations.ScreenSizes.SM.max && finalSlidesPerPage !== _slidesPerPage) {
|
|
3255
|
+
setFinalSlidesPerPage(_slidesPerPage);
|
|
3256
|
+
onChange && onChange(0);
|
|
3257
|
+
}
|
|
3258
|
+
}, [finalSlidesPerPage, _slidesPerPage, onChange]);
|
|
3259
|
+
React.useEffect(() => {
|
|
3260
|
+
if (typeof window === 'undefined' || !isHydrated) return;
|
|
3261
|
+
if (_duration > 0) intervalRef.current = window.setInterval(intervalFunction, _duration);
|
|
3262
|
+
resizeEvent();
|
|
3263
|
+
window.addEventListener('resize', resizeEvent);
|
|
3264
|
+
return () => {
|
|
3265
|
+
if (intervalRef.current && _duration > 0) window.clearInterval(intervalRef.current);
|
|
3266
|
+
window.removeEventListener('resize', resizeEvent);
|
|
3267
|
+
};
|
|
3268
|
+
}, [intervalFunction, _duration, resizeEvent, isHydrated]);
|
|
3269
|
+
React.useEffect(() => {
|
|
3270
|
+
setIsHydrated(true);
|
|
3271
|
+
}, []);
|
|
3272
|
+
return typeof count !== 'undefined' && !isHydrated ? null : jsxRuntime.jsxs(SliderContainer, Object.assign({
|
|
3273
|
+
id: _id,
|
|
3274
|
+
"data-testid": _dataTestId,
|
|
3275
|
+
tabIndex: 0,
|
|
3276
|
+
role: "region",
|
|
3277
|
+
"aria-roledescription": "carousel",
|
|
3278
|
+
"aria-label": 'Slider',
|
|
3279
|
+
ref: instance => {
|
|
3280
|
+
containerRef.current = instance;
|
|
3281
|
+
if (typeof ref === 'function') {
|
|
3282
|
+
ref(instance);
|
|
3283
|
+
} else if (typeof ref === 'object' && ref) {
|
|
3284
|
+
ref.current = instance;
|
|
3285
|
+
}
|
|
3286
|
+
},
|
|
3287
|
+
"$slidesPerPage": finalSlidesPerPage,
|
|
3288
|
+
"$size": 100 / finalSlidesPerPage,
|
|
3289
|
+
"$showBullets": _showBullets
|
|
3290
|
+
}, isHydrated ? {
|
|
3291
|
+
onMouseDown: startDrag,
|
|
3292
|
+
onMouseUp: stopDrag,
|
|
3293
|
+
onTouchStart: startDrag,
|
|
3294
|
+
onTouchEnd: stopDrag
|
|
3295
|
+
} : {}, {
|
|
3296
|
+
onMouseEnter: () => {
|
|
3297
|
+
if (intervalRef.current) window.clearInterval(intervalRef.current);
|
|
3298
|
+
},
|
|
3299
|
+
onMouseLeave: () => {
|
|
3300
|
+
if (_duration > 0) intervalRef.current = window.setInterval(intervalFunction, _duration);
|
|
3301
|
+
},
|
|
3302
|
+
onFocusCapture: () => {
|
|
3303
|
+
if (intervalRef.current) window.clearInterval(intervalRef.current);
|
|
3304
|
+
},
|
|
3305
|
+
onBlurCapture: () => {
|
|
3306
|
+
if (_duration > 0) intervalRef.current = window.setInterval(intervalFunction, _duration);
|
|
3307
|
+
},
|
|
3308
|
+
onKeyDown: e => {
|
|
3309
|
+
if (e.key === 'ArrowLeft') {
|
|
3310
|
+
e.preventDefault();
|
|
3311
|
+
changePage(currentPage - 1);
|
|
3312
|
+
} else if (e.key === 'ArrowRight') {
|
|
3313
|
+
e.preventDefault();
|
|
3314
|
+
changePage(currentPage + 1);
|
|
3315
|
+
}
|
|
3316
|
+
},
|
|
3317
|
+
children: [jsxRuntime.jsx(SliderContent, {
|
|
3318
|
+
id: `${_id}-content`,
|
|
3319
|
+
"data-testid": `${_dataTestId}-content`,
|
|
3320
|
+
ref: contentRef,
|
|
3321
|
+
"$slidesPerPage": finalSlidesPerPage,
|
|
3322
|
+
"$currentPage": currentPage,
|
|
3323
|
+
"$dragDistance": dragDistance.current,
|
|
3324
|
+
style: {
|
|
3325
|
+
transform: `translateX(calc(${baseTransform}))`,
|
|
3326
|
+
transition: `transform ${ANIMATION_DURATION}`
|
|
3327
|
+
},
|
|
3328
|
+
children: finalChildrens
|
|
3329
|
+
}), _showArrows ? jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
3330
|
+
children: [jsxRuntime.jsx(ButtonContainer, {
|
|
3331
|
+
"$side": "left",
|
|
3332
|
+
children: jsxRuntime.jsx(testAtomsButton.Button, {
|
|
3333
|
+
dataTestId: `${_dataTestId}-prev-button`,
|
|
3334
|
+
iconLeft: "arrow_back",
|
|
3335
|
+
size: "lg",
|
|
3336
|
+
variant: "ghost",
|
|
3337
|
+
ariaLabel: "Previous slide",
|
|
3338
|
+
disabled: currentPage === 0 || !isHydrated,
|
|
3339
|
+
onClick: () => {
|
|
3340
|
+
changePage(currentPage - 1);
|
|
3341
|
+
}
|
|
3342
|
+
})
|
|
3343
|
+
}), jsxRuntime.jsx(ButtonContainer, {
|
|
3344
|
+
"$side": "right",
|
|
3345
|
+
children: jsxRuntime.jsx(testAtomsButton.Button, {
|
|
3346
|
+
dataTestId: `${_dataTestId}-next-button`,
|
|
3347
|
+
iconLeft: "arrow_forward",
|
|
3348
|
+
size: "lg",
|
|
3349
|
+
variant: "ghost",
|
|
3350
|
+
ariaLabel: "Next slide",
|
|
3351
|
+
disabled: currentPage === pages.length - 1 || !isHydrated,
|
|
3352
|
+
onClick: () => {
|
|
3353
|
+
changePage(currentPage + 1);
|
|
3354
|
+
}
|
|
3355
|
+
})
|
|
3356
|
+
})]
|
|
3357
|
+
}) : null, _showBullets ? jsxRuntime.jsx(PageBulletContainer, {
|
|
3358
|
+
id: `${_id}-bullet-container`,
|
|
3359
|
+
"data-testid": `${_dataTestId}-bullet-container`,
|
|
3360
|
+
role: "tablist",
|
|
3361
|
+
"aria-label": "Slide navigation",
|
|
3362
|
+
children: pages.map((_, index) => jsxRuntime.jsx(PageBullet, {
|
|
3363
|
+
id: `${_id}-bullet-${index}`,
|
|
3364
|
+
"data-testid": `${_dataTestId}-bullet-${index}`,
|
|
3365
|
+
"$page": index,
|
|
3366
|
+
onClick: () => {
|
|
3367
|
+
changePage(index);
|
|
3368
|
+
},
|
|
3369
|
+
"$active": currentPage === index,
|
|
3370
|
+
disabled: !isHydrated,
|
|
3371
|
+
"aria-label": `Go to slide ${index + 1}`,
|
|
3372
|
+
"aria-current": currentPage === index ? 'true' : undefined
|
|
3373
|
+
}, index))
|
|
3374
|
+
}) : null, jsxRuntime.jsx("span", {
|
|
3375
|
+
"aria-live": "polite",
|
|
3376
|
+
"aria-atomic": "true",
|
|
3377
|
+
className: 'sr-only',
|
|
3378
|
+
children: `Slide ${currentPage + 1} of ${pages.length}`
|
|
3379
|
+
})]
|
|
3380
|
+
}));
|
|
3381
|
+
});
|
|
3382
|
+
|
|
3383
|
+
exports.Slider = Slider;
|
|
3384
|
+
exports.SliderItem = SliderItem;
|