@bolttech/atoms-segmented-control 0.22.1 → 0.24.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.
|
@@ -1,17 +1,15 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
5
|
-
|
|
6
4
|
var jsxRuntime = require('react/jsx-runtime');
|
|
7
5
|
var react = require('react');
|
|
8
6
|
var frontendFoundations = require('@bolttech/frontend-foundations');
|
|
9
7
|
var styled = require('styled-components');
|
|
10
8
|
var uiUtils = require('@bolttech/ui-utils');
|
|
11
9
|
|
|
12
|
-
function
|
|
10
|
+
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
13
11
|
|
|
14
|
-
var styled__default = /*#__PURE__*/
|
|
12
|
+
var styled__default = /*#__PURE__*/_interopDefault(styled);
|
|
15
13
|
|
|
16
14
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
17
15
|
|
|
@@ -33,7 +31,7 @@ var globalThis_1 =
|
|
|
33
31
|
|
|
34
32
|
var objectGetOwnPropertyDescriptor = {};
|
|
35
33
|
|
|
36
|
-
var fails$
|
|
34
|
+
var fails$i = function (exec) {
|
|
37
35
|
try {
|
|
38
36
|
return !!exec();
|
|
39
37
|
} catch (error) {
|
|
@@ -41,17 +39,17 @@ var fails$e = function (exec) {
|
|
|
41
39
|
}
|
|
42
40
|
};
|
|
43
41
|
|
|
44
|
-
var fails$
|
|
42
|
+
var fails$h = fails$i;
|
|
45
43
|
|
|
46
44
|
// Detect IE8's incomplete defineProperty implementation
|
|
47
|
-
var descriptors = !fails$
|
|
45
|
+
var descriptors = !fails$h(function () {
|
|
48
46
|
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
49
47
|
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
|
|
50
48
|
});
|
|
51
49
|
|
|
52
|
-
var fails$
|
|
50
|
+
var fails$g = fails$i;
|
|
53
51
|
|
|
54
|
-
var functionBindNative = !fails$
|
|
52
|
+
var functionBindNative = !fails$g(function () {
|
|
55
53
|
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
56
54
|
var test = (function () { /* empty */ }).bind();
|
|
57
55
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
@@ -60,10 +58,10 @@ var functionBindNative = !fails$c(function () {
|
|
|
60
58
|
|
|
61
59
|
var NATIVE_BIND$2 = functionBindNative;
|
|
62
60
|
|
|
63
|
-
var call$
|
|
64
|
-
|
|
65
|
-
var functionCall = NATIVE_BIND$2 ? call$
|
|
66
|
-
return call$
|
|
61
|
+
var call$e = Function.prototype.call;
|
|
62
|
+
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
63
|
+
var functionCall = NATIVE_BIND$2 ? call$e.bind(call$e) : function () {
|
|
64
|
+
return call$e.apply(call$e, arguments);
|
|
67
65
|
};
|
|
68
66
|
|
|
69
67
|
var objectPropertyIsEnumerable = {};
|
|
@@ -82,7 +80,7 @@ objectPropertyIsEnumerable.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
|
|
|
82
80
|
return !!descriptor && descriptor.enumerable;
|
|
83
81
|
} : $propertyIsEnumerable;
|
|
84
82
|
|
|
85
|
-
var createPropertyDescriptor$
|
|
83
|
+
var createPropertyDescriptor$3 = function (bitmap, value) {
|
|
86
84
|
return {
|
|
87
85
|
enumerable: !(bitmap & 1),
|
|
88
86
|
configurable: !(bitmap & 2),
|
|
@@ -94,12 +92,13 @@ var createPropertyDescriptor$2 = function (bitmap, value) {
|
|
|
94
92
|
var NATIVE_BIND$1 = functionBindNative;
|
|
95
93
|
|
|
96
94
|
var FunctionPrototype$2 = Function.prototype;
|
|
97
|
-
var call$
|
|
98
|
-
|
|
95
|
+
var call$d = FunctionPrototype$2.call;
|
|
96
|
+
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
97
|
+
var uncurryThisWithBind = NATIVE_BIND$1 && FunctionPrototype$2.bind.bind(call$d, call$d);
|
|
99
98
|
|
|
100
99
|
var functionUncurryThis = NATIVE_BIND$1 ? uncurryThisWithBind : function (fn) {
|
|
101
100
|
return function () {
|
|
102
|
-
return call$
|
|
101
|
+
return call$d.apply(fn, arguments);
|
|
103
102
|
};
|
|
104
103
|
};
|
|
105
104
|
|
|
@@ -113,35 +112,35 @@ var classofRaw$1 = function (it) {
|
|
|
113
112
|
};
|
|
114
113
|
|
|
115
114
|
var uncurryThis$c = functionUncurryThis;
|
|
116
|
-
var fails$
|
|
115
|
+
var fails$f = fails$i;
|
|
117
116
|
var classof$3 = classofRaw$1;
|
|
118
117
|
|
|
119
|
-
var $Object$
|
|
118
|
+
var $Object$4 = Object;
|
|
120
119
|
var split = uncurryThis$c(''.split);
|
|
121
120
|
|
|
122
121
|
// fallback for non-array-like ES3 and non-enumerable old V8 strings
|
|
123
|
-
var indexedObject = fails$
|
|
122
|
+
var indexedObject = fails$f(function () {
|
|
124
123
|
// throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
|
|
125
124
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
126
|
-
return !$Object$
|
|
125
|
+
return !$Object$4('z').propertyIsEnumerable(0);
|
|
127
126
|
}) ? function (it) {
|
|
128
|
-
return classof$3(it) === 'String' ? split(it, '') : $Object$
|
|
129
|
-
} : $Object$
|
|
127
|
+
return classof$3(it) === 'String' ? split(it, '') : $Object$4(it);
|
|
128
|
+
} : $Object$4;
|
|
130
129
|
|
|
131
130
|
// we can't use just `it == null` since of `document.all` special case
|
|
132
131
|
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
|
|
133
|
-
var isNullOrUndefined$
|
|
132
|
+
var isNullOrUndefined$2 = function (it) {
|
|
134
133
|
return it === null || it === undefined;
|
|
135
134
|
};
|
|
136
135
|
|
|
137
|
-
var isNullOrUndefined$
|
|
136
|
+
var isNullOrUndefined$1 = isNullOrUndefined$2;
|
|
138
137
|
|
|
139
|
-
var $TypeError$
|
|
138
|
+
var $TypeError$8 = TypeError;
|
|
140
139
|
|
|
141
140
|
// `RequireObjectCoercible` abstract operation
|
|
142
141
|
// https://tc39.es/ecma262/#sec-requireobjectcoercible
|
|
143
142
|
var requireObjectCoercible$4 = function (it) {
|
|
144
|
-
if (isNullOrUndefined$
|
|
143
|
+
if (isNullOrUndefined$1(it)) throw new $TypeError$8("Can't call method on " + it);
|
|
145
144
|
return it;
|
|
146
145
|
};
|
|
147
146
|
|
|
@@ -159,45 +158,45 @@ var documentAll = typeof document == 'object' && document.all;
|
|
|
159
158
|
// `IsCallable` abstract operation
|
|
160
159
|
// https://tc39.es/ecma262/#sec-iscallable
|
|
161
160
|
// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
|
|
162
|
-
var isCallable$
|
|
161
|
+
var isCallable$g = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
|
|
163
162
|
return typeof argument == 'function' || argument === documentAll;
|
|
164
163
|
} : function (argument) {
|
|
165
164
|
return typeof argument == 'function';
|
|
166
165
|
};
|
|
167
166
|
|
|
168
|
-
var isCallable$
|
|
167
|
+
var isCallable$f = isCallable$g;
|
|
169
168
|
|
|
170
|
-
var isObject$
|
|
171
|
-
return typeof it == 'object' ? it !== null : isCallable$
|
|
169
|
+
var isObject$7 = function (it) {
|
|
170
|
+
return typeof it == 'object' ? it !== null : isCallable$f(it);
|
|
172
171
|
};
|
|
173
172
|
|
|
174
|
-
var globalThis$
|
|
175
|
-
var isCallable$
|
|
173
|
+
var globalThis$h = globalThis_1;
|
|
174
|
+
var isCallable$e = isCallable$g;
|
|
176
175
|
|
|
177
176
|
var aFunction = function (argument) {
|
|
178
|
-
return isCallable$
|
|
177
|
+
return isCallable$e(argument) ? argument : undefined;
|
|
179
178
|
};
|
|
180
179
|
|
|
181
180
|
var getBuiltIn$3 = function (namespace, method) {
|
|
182
|
-
return arguments.length < 2 ? aFunction(globalThis$
|
|
181
|
+
return arguments.length < 2 ? aFunction(globalThis$h[namespace]) : globalThis$h[namespace] && globalThis$h[namespace][method];
|
|
183
182
|
};
|
|
184
183
|
|
|
185
184
|
var uncurryThis$b = functionUncurryThis;
|
|
186
185
|
|
|
187
186
|
var objectIsPrototypeOf = uncurryThis$b({}.isPrototypeOf);
|
|
188
187
|
|
|
189
|
-
var globalThis$
|
|
188
|
+
var globalThis$g = globalThis_1;
|
|
190
189
|
|
|
191
|
-
var navigator = globalThis$
|
|
190
|
+
var navigator = globalThis$g.navigator;
|
|
192
191
|
var userAgent$1 = navigator && navigator.userAgent;
|
|
193
192
|
|
|
194
193
|
var environmentUserAgent = userAgent$1 ? String(userAgent$1) : '';
|
|
195
194
|
|
|
196
|
-
var globalThis$
|
|
195
|
+
var globalThis$f = globalThis_1;
|
|
197
196
|
var userAgent = environmentUserAgent;
|
|
198
197
|
|
|
199
|
-
var process = globalThis$
|
|
200
|
-
var Deno = globalThis$
|
|
198
|
+
var process = globalThis$f.process;
|
|
199
|
+
var Deno = globalThis$f.Deno;
|
|
201
200
|
var versions = process && process.versions || Deno && Deno.version;
|
|
202
201
|
var v8 = versions && versions.v8;
|
|
203
202
|
var match, version;
|
|
@@ -223,13 +222,13 @@ var environmentV8Version = version;
|
|
|
223
222
|
|
|
224
223
|
/* eslint-disable es/no-symbol -- required for testing */
|
|
225
224
|
var V8_VERSION = environmentV8Version;
|
|
226
|
-
var fails$
|
|
227
|
-
var globalThis$
|
|
225
|
+
var fails$e = fails$i;
|
|
226
|
+
var globalThis$e = globalThis_1;
|
|
228
227
|
|
|
229
|
-
var $String$4 = globalThis$
|
|
228
|
+
var $String$4 = globalThis$e.String;
|
|
230
229
|
|
|
231
230
|
// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
|
|
232
|
-
var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$
|
|
231
|
+
var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$e(function () {
|
|
233
232
|
var symbol = Symbol('symbol detection');
|
|
234
233
|
// Chrome 38 Symbol has incorrect toString conversion
|
|
235
234
|
// `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
|
|
@@ -248,17 +247,17 @@ var useSymbolAsUid = NATIVE_SYMBOL$1 &&
|
|
|
248
247
|
typeof Symbol.iterator == 'symbol';
|
|
249
248
|
|
|
250
249
|
var getBuiltIn$2 = getBuiltIn$3;
|
|
251
|
-
var isCallable$
|
|
252
|
-
var isPrototypeOf = objectIsPrototypeOf;
|
|
250
|
+
var isCallable$d = isCallable$g;
|
|
251
|
+
var isPrototypeOf$2 = objectIsPrototypeOf;
|
|
253
252
|
var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
|
|
254
253
|
|
|
255
|
-
var $Object$
|
|
254
|
+
var $Object$3 = Object;
|
|
256
255
|
|
|
257
256
|
var isSymbol$2 = USE_SYMBOL_AS_UID$1 ? function (it) {
|
|
258
257
|
return typeof it == 'symbol';
|
|
259
258
|
} : function (it) {
|
|
260
259
|
var $Symbol = getBuiltIn$2('Symbol');
|
|
261
|
-
return isCallable$
|
|
260
|
+
return isCallable$d($Symbol) && isPrototypeOf$2($Symbol.prototype, $Object$3(it));
|
|
262
261
|
};
|
|
263
262
|
|
|
264
263
|
var $String$3 = String;
|
|
@@ -271,73 +270,75 @@ var tryToString$1 = function (argument) {
|
|
|
271
270
|
}
|
|
272
271
|
};
|
|
273
272
|
|
|
274
|
-
var isCallable$
|
|
273
|
+
var isCallable$c = isCallable$g;
|
|
275
274
|
var tryToString = tryToString$1;
|
|
276
275
|
|
|
277
|
-
var $TypeError$
|
|
276
|
+
var $TypeError$7 = TypeError;
|
|
278
277
|
|
|
279
278
|
// `Assert: IsCallable(argument) is true`
|
|
280
|
-
var aCallable$
|
|
281
|
-
if (isCallable$
|
|
282
|
-
throw new $TypeError$
|
|
279
|
+
var aCallable$2 = function (argument) {
|
|
280
|
+
if (isCallable$c(argument)) return argument;
|
|
281
|
+
throw new $TypeError$7(tryToString(argument) + ' is not a function');
|
|
283
282
|
};
|
|
284
283
|
|
|
285
|
-
var aCallable = aCallable$
|
|
286
|
-
var isNullOrUndefined
|
|
284
|
+
var aCallable$1 = aCallable$2;
|
|
285
|
+
var isNullOrUndefined = isNullOrUndefined$2;
|
|
287
286
|
|
|
288
287
|
// `GetMethod` abstract operation
|
|
289
288
|
// https://tc39.es/ecma262/#sec-getmethod
|
|
290
|
-
var getMethod$
|
|
289
|
+
var getMethod$4 = function (V, P) {
|
|
291
290
|
var func = V[P];
|
|
292
|
-
return isNullOrUndefined
|
|
291
|
+
return isNullOrUndefined(func) ? undefined : aCallable$1(func);
|
|
293
292
|
};
|
|
294
293
|
|
|
295
|
-
var call$
|
|
296
|
-
var isCallable$
|
|
297
|
-
var isObject$
|
|
294
|
+
var call$c = functionCall;
|
|
295
|
+
var isCallable$b = isCallable$g;
|
|
296
|
+
var isObject$6 = isObject$7;
|
|
298
297
|
|
|
299
|
-
var $TypeError$
|
|
298
|
+
var $TypeError$6 = TypeError;
|
|
300
299
|
|
|
301
300
|
// `OrdinaryToPrimitive` abstract operation
|
|
302
301
|
// https://tc39.es/ecma262/#sec-ordinarytoprimitive
|
|
303
302
|
var ordinaryToPrimitive$1 = function (input, pref) {
|
|
304
303
|
var fn, val;
|
|
305
|
-
if (pref === 'string' && isCallable$
|
|
306
|
-
if (isCallable$
|
|
307
|
-
if (pref !== 'string' && isCallable$
|
|
308
|
-
throw new $TypeError$
|
|
304
|
+
if (pref === 'string' && isCallable$b(fn = input.toString) && !isObject$6(val = call$c(fn, input))) return val;
|
|
305
|
+
if (isCallable$b(fn = input.valueOf) && !isObject$6(val = call$c(fn, input))) return val;
|
|
306
|
+
if (pref !== 'string' && isCallable$b(fn = input.toString) && !isObject$6(val = call$c(fn, input))) return val;
|
|
307
|
+
throw new $TypeError$6("Can't convert object to primitive value");
|
|
309
308
|
};
|
|
310
309
|
|
|
311
310
|
var sharedStore = {exports: {}};
|
|
312
311
|
|
|
313
|
-
var globalThis$
|
|
312
|
+
var globalThis$d = globalThis_1;
|
|
314
313
|
|
|
315
314
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
316
|
-
var defineProperty$
|
|
315
|
+
var defineProperty$3 = Object.defineProperty;
|
|
317
316
|
|
|
318
317
|
var defineGlobalProperty$3 = function (key, value) {
|
|
319
318
|
try {
|
|
320
|
-
defineProperty$
|
|
319
|
+
defineProperty$3(globalThis$d, key, { value: value, configurable: true, writable: true });
|
|
321
320
|
} catch (error) {
|
|
322
|
-
globalThis$
|
|
321
|
+
globalThis$d[key] = value;
|
|
323
322
|
} return value;
|
|
324
323
|
};
|
|
325
324
|
|
|
326
|
-
var globalThis$
|
|
325
|
+
var globalThis$c = globalThis_1;
|
|
327
326
|
var defineGlobalProperty$2 = defineGlobalProperty$3;
|
|
328
327
|
|
|
329
328
|
var SHARED = '__core-js_shared__';
|
|
330
|
-
var store$3 = sharedStore.exports = globalThis$
|
|
329
|
+
var store$3 = sharedStore.exports = globalThis$c[SHARED] || defineGlobalProperty$2(SHARED, {});
|
|
331
330
|
|
|
332
331
|
(store$3.versions || (store$3.versions = [])).push({
|
|
333
|
-
version: '3.
|
|
332
|
+
version: '3.48.0',
|
|
334
333
|
mode: 'global',
|
|
335
|
-
copyright: '©
|
|
336
|
-
license: 'https://github.com/zloirock/core-js/blob/v3.
|
|
334
|
+
copyright: '© 2013–2025 Denis Pushkarev (zloirock.ru), 2025–2026 CoreJS Company (core-js.io). All rights reserved.',
|
|
335
|
+
license: 'https://github.com/zloirock/core-js/blob/v3.48.0/LICENSE',
|
|
337
336
|
source: 'https://github.com/zloirock/core-js'
|
|
338
337
|
});
|
|
339
338
|
|
|
340
|
-
var
|
|
339
|
+
var sharedStoreExports = sharedStore.exports;
|
|
340
|
+
|
|
341
|
+
var store$2 = sharedStoreExports;
|
|
341
342
|
|
|
342
343
|
var shared$4 = function (key, value) {
|
|
343
344
|
return store$2[key] || (store$2[key] = value || {});
|
|
@@ -345,16 +346,16 @@ var shared$4 = function (key, value) {
|
|
|
345
346
|
|
|
346
347
|
var requireObjectCoercible$2 = requireObjectCoercible$4;
|
|
347
348
|
|
|
348
|
-
var $Object$
|
|
349
|
+
var $Object$2 = Object;
|
|
349
350
|
|
|
350
351
|
// `ToObject` abstract operation
|
|
351
352
|
// https://tc39.es/ecma262/#sec-toobject
|
|
352
|
-
var toObject$
|
|
353
|
-
return $Object$
|
|
353
|
+
var toObject$4 = function (argument) {
|
|
354
|
+
return $Object$2(requireObjectCoercible$2(argument));
|
|
354
355
|
};
|
|
355
356
|
|
|
356
357
|
var uncurryThis$a = functionUncurryThis;
|
|
357
|
-
var toObject$
|
|
358
|
+
var toObject$3 = toObject$4;
|
|
358
359
|
|
|
359
360
|
var hasOwnProperty = uncurryThis$a({}.hasOwnProperty);
|
|
360
361
|
|
|
@@ -362,59 +363,59 @@ var hasOwnProperty = uncurryThis$a({}.hasOwnProperty);
|
|
|
362
363
|
// https://tc39.es/ecma262/#sec-hasownproperty
|
|
363
364
|
// eslint-disable-next-line es/no-object-hasown -- safe
|
|
364
365
|
var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
|
|
365
|
-
return hasOwnProperty(toObject$
|
|
366
|
+
return hasOwnProperty(toObject$3(it), key);
|
|
366
367
|
};
|
|
367
368
|
|
|
368
369
|
var uncurryThis$9 = functionUncurryThis;
|
|
369
370
|
|
|
370
371
|
var id = 0;
|
|
371
372
|
var postfix = Math.random();
|
|
372
|
-
var toString$4 = uncurryThis$9(1.
|
|
373
|
+
var toString$4 = uncurryThis$9(1.1.toString);
|
|
373
374
|
|
|
374
375
|
var uid$2 = function (key) {
|
|
375
376
|
return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$4(++id + postfix, 36);
|
|
376
377
|
};
|
|
377
378
|
|
|
378
|
-
var globalThis$
|
|
379
|
+
var globalThis$b = globalThis_1;
|
|
379
380
|
var shared$3 = shared$4;
|
|
380
|
-
var hasOwn$
|
|
381
|
+
var hasOwn$9 = hasOwnProperty_1;
|
|
381
382
|
var uid$1 = uid$2;
|
|
382
383
|
var NATIVE_SYMBOL = symbolConstructorDetection;
|
|
383
384
|
var USE_SYMBOL_AS_UID = useSymbolAsUid;
|
|
384
385
|
|
|
385
|
-
var Symbol$1 = globalThis$
|
|
386
|
+
var Symbol$1 = globalThis$b.Symbol;
|
|
386
387
|
var WellKnownSymbolsStore = shared$3('wks');
|
|
387
388
|
var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol$1['for'] || Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid$1;
|
|
388
389
|
|
|
389
|
-
var wellKnownSymbol$
|
|
390
|
-
if (!hasOwn$
|
|
391
|
-
WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn$
|
|
390
|
+
var wellKnownSymbol$8 = function (name) {
|
|
391
|
+
if (!hasOwn$9(WellKnownSymbolsStore, name)) {
|
|
392
|
+
WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn$9(Symbol$1, name)
|
|
392
393
|
? Symbol$1[name]
|
|
393
394
|
: createWellKnownSymbol('Symbol.' + name);
|
|
394
395
|
} return WellKnownSymbolsStore[name];
|
|
395
396
|
};
|
|
396
397
|
|
|
397
|
-
var call$
|
|
398
|
-
var isObject$
|
|
398
|
+
var call$b = functionCall;
|
|
399
|
+
var isObject$5 = isObject$7;
|
|
399
400
|
var isSymbol$1 = isSymbol$2;
|
|
400
|
-
var getMethod$
|
|
401
|
+
var getMethod$3 = getMethod$4;
|
|
401
402
|
var ordinaryToPrimitive = ordinaryToPrimitive$1;
|
|
402
|
-
var wellKnownSymbol$
|
|
403
|
+
var wellKnownSymbol$7 = wellKnownSymbol$8;
|
|
403
404
|
|
|
404
|
-
var $TypeError$
|
|
405
|
-
var TO_PRIMITIVE = wellKnownSymbol$
|
|
405
|
+
var $TypeError$5 = TypeError;
|
|
406
|
+
var TO_PRIMITIVE = wellKnownSymbol$7('toPrimitive');
|
|
406
407
|
|
|
407
408
|
// `ToPrimitive` abstract operation
|
|
408
409
|
// https://tc39.es/ecma262/#sec-toprimitive
|
|
409
410
|
var toPrimitive$1 = function (input, pref) {
|
|
410
|
-
if (!isObject$
|
|
411
|
-
var exoticToPrim = getMethod$
|
|
411
|
+
if (!isObject$5(input) || isSymbol$1(input)) return input;
|
|
412
|
+
var exoticToPrim = getMethod$3(input, TO_PRIMITIVE);
|
|
412
413
|
var result;
|
|
413
414
|
if (exoticToPrim) {
|
|
414
415
|
if (pref === undefined) pref = 'default';
|
|
415
|
-
result = call$
|
|
416
|
-
if (!isObject$
|
|
417
|
-
throw new $TypeError$
|
|
416
|
+
result = call$b(exoticToPrim, input, pref);
|
|
417
|
+
if (!isObject$5(result) || isSymbol$1(result)) return result;
|
|
418
|
+
throw new $TypeError$5("Can't convert object to primitive value");
|
|
418
419
|
}
|
|
419
420
|
if (pref === undefined) pref = 'number';
|
|
420
421
|
return ordinaryToPrimitive(input, pref);
|
|
@@ -430,36 +431,36 @@ var toPropertyKey$2 = function (argument) {
|
|
|
430
431
|
return isSymbol(key) ? key : key + '';
|
|
431
432
|
};
|
|
432
433
|
|
|
433
|
-
var globalThis$
|
|
434
|
-
var isObject$
|
|
434
|
+
var globalThis$a = globalThis_1;
|
|
435
|
+
var isObject$4 = isObject$7;
|
|
435
436
|
|
|
436
|
-
var document$1 = globalThis$
|
|
437
|
+
var document$1 = globalThis$a.document;
|
|
437
438
|
// typeof document.createElement is 'object' in old IE
|
|
438
|
-
var EXISTS$1 = isObject$
|
|
439
|
+
var EXISTS$1 = isObject$4(document$1) && isObject$4(document$1.createElement);
|
|
439
440
|
|
|
440
441
|
var documentCreateElement$1 = function (it) {
|
|
441
442
|
return EXISTS$1 ? document$1.createElement(it) : {};
|
|
442
443
|
};
|
|
443
444
|
|
|
444
|
-
var DESCRIPTORS$
|
|
445
|
-
var fails$
|
|
445
|
+
var DESCRIPTORS$a = descriptors;
|
|
446
|
+
var fails$d = fails$i;
|
|
446
447
|
var createElement = documentCreateElement$1;
|
|
447
448
|
|
|
448
449
|
// Thanks to IE8 for its funny defineProperty
|
|
449
|
-
var ie8DomDefine = !DESCRIPTORS$
|
|
450
|
+
var ie8DomDefine = !DESCRIPTORS$a && !fails$d(function () {
|
|
450
451
|
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
451
452
|
return Object.defineProperty(createElement('div'), 'a', {
|
|
452
453
|
get: function () { return 7; }
|
|
453
454
|
}).a !== 7;
|
|
454
455
|
});
|
|
455
456
|
|
|
456
|
-
var DESCRIPTORS$
|
|
457
|
-
var call$
|
|
457
|
+
var DESCRIPTORS$9 = descriptors;
|
|
458
|
+
var call$a = functionCall;
|
|
458
459
|
var propertyIsEnumerableModule$1 = objectPropertyIsEnumerable;
|
|
459
|
-
var createPropertyDescriptor$
|
|
460
|
+
var createPropertyDescriptor$2 = createPropertyDescriptor$3;
|
|
460
461
|
var toIndexedObject$3 = toIndexedObject$4;
|
|
461
462
|
var toPropertyKey$1 = toPropertyKey$2;
|
|
462
|
-
var hasOwn$
|
|
463
|
+
var hasOwn$8 = hasOwnProperty_1;
|
|
463
464
|
var IE8_DOM_DEFINE$1 = ie8DomDefine;
|
|
464
465
|
|
|
465
466
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
@@ -467,23 +468,23 @@ var $getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
|
|
|
467
468
|
|
|
468
469
|
// `Object.getOwnPropertyDescriptor` method
|
|
469
470
|
// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
|
|
470
|
-
objectGetOwnPropertyDescriptor.f = DESCRIPTORS$
|
|
471
|
+
objectGetOwnPropertyDescriptor.f = DESCRIPTORS$9 ? $getOwnPropertyDescriptor$1 : function getOwnPropertyDescriptor(O, P) {
|
|
471
472
|
O = toIndexedObject$3(O);
|
|
472
473
|
P = toPropertyKey$1(P);
|
|
473
474
|
if (IE8_DOM_DEFINE$1) try {
|
|
474
475
|
return $getOwnPropertyDescriptor$1(O, P);
|
|
475
476
|
} catch (error) { /* empty */ }
|
|
476
|
-
if (hasOwn$
|
|
477
|
+
if (hasOwn$8(O, P)) return createPropertyDescriptor$2(!call$a(propertyIsEnumerableModule$1.f, O, P), O[P]);
|
|
477
478
|
};
|
|
478
479
|
|
|
479
480
|
var objectDefineProperty = {};
|
|
480
481
|
|
|
481
|
-
var DESCRIPTORS$
|
|
482
|
-
var fails$
|
|
482
|
+
var DESCRIPTORS$8 = descriptors;
|
|
483
|
+
var fails$c = fails$i;
|
|
483
484
|
|
|
484
485
|
// V8 ~ Chrome 36-
|
|
485
486
|
// https://bugs.chromium.org/p/v8/issues/detail?id=3334
|
|
486
|
-
var v8PrototypeDefineBug = DESCRIPTORS$
|
|
487
|
+
var v8PrototypeDefineBug = DESCRIPTORS$8 && fails$c(function () {
|
|
487
488
|
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
488
489
|
return Object.defineProperty(function () { /* empty */ }, 'prototype', {
|
|
489
490
|
value: 42,
|
|
@@ -491,24 +492,24 @@ var v8PrototypeDefineBug = DESCRIPTORS$6 && fails$8(function () {
|
|
|
491
492
|
}).prototype !== 42;
|
|
492
493
|
});
|
|
493
494
|
|
|
494
|
-
var isObject$
|
|
495
|
+
var isObject$3 = isObject$7;
|
|
495
496
|
|
|
496
497
|
var $String$2 = String;
|
|
497
|
-
var $TypeError$
|
|
498
|
+
var $TypeError$4 = TypeError;
|
|
498
499
|
|
|
499
500
|
// `Assert: Type(argument) is Object`
|
|
500
|
-
var anObject$
|
|
501
|
-
if (isObject$
|
|
502
|
-
throw new $TypeError$
|
|
501
|
+
var anObject$b = function (argument) {
|
|
502
|
+
if (isObject$3(argument)) return argument;
|
|
503
|
+
throw new $TypeError$4($String$2(argument) + ' is not an object');
|
|
503
504
|
};
|
|
504
505
|
|
|
505
|
-
var DESCRIPTORS$
|
|
506
|
+
var DESCRIPTORS$7 = descriptors;
|
|
506
507
|
var IE8_DOM_DEFINE = ie8DomDefine;
|
|
507
508
|
var V8_PROTOTYPE_DEFINE_BUG$1 = v8PrototypeDefineBug;
|
|
508
|
-
var anObject$
|
|
509
|
+
var anObject$a = anObject$b;
|
|
509
510
|
var toPropertyKey = toPropertyKey$2;
|
|
510
511
|
|
|
511
|
-
var $TypeError$
|
|
512
|
+
var $TypeError$3 = TypeError;
|
|
512
513
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
513
514
|
var $defineProperty = Object.defineProperty;
|
|
514
515
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
@@ -519,10 +520,10 @@ var WRITABLE = 'writable';
|
|
|
519
520
|
|
|
520
521
|
// `Object.defineProperty` method
|
|
521
522
|
// https://tc39.es/ecma262/#sec-object.defineproperty
|
|
522
|
-
objectDefineProperty.f = DESCRIPTORS$
|
|
523
|
-
anObject$
|
|
523
|
+
objectDefineProperty.f = DESCRIPTORS$7 ? V8_PROTOTYPE_DEFINE_BUG$1 ? function defineProperty(O, P, Attributes) {
|
|
524
|
+
anObject$a(O);
|
|
524
525
|
P = toPropertyKey(P);
|
|
525
|
-
anObject$
|
|
526
|
+
anObject$a(Attributes);
|
|
526
527
|
if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {
|
|
527
528
|
var current = $getOwnPropertyDescriptor(O, P);
|
|
528
529
|
if (current && current[WRITABLE]) {
|
|
@@ -535,56 +536,52 @@ objectDefineProperty.f = DESCRIPTORS$5 ? V8_PROTOTYPE_DEFINE_BUG$1 ? function de
|
|
|
535
536
|
}
|
|
536
537
|
} return $defineProperty(O, P, Attributes);
|
|
537
538
|
} : $defineProperty : function defineProperty(O, P, Attributes) {
|
|
538
|
-
anObject$
|
|
539
|
+
anObject$a(O);
|
|
539
540
|
P = toPropertyKey(P);
|
|
540
|
-
anObject$
|
|
541
|
+
anObject$a(Attributes);
|
|
541
542
|
if (IE8_DOM_DEFINE) try {
|
|
542
543
|
return $defineProperty(O, P, Attributes);
|
|
543
544
|
} catch (error) { /* empty */ }
|
|
544
|
-
if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$
|
|
545
|
+
if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$3('Accessors not supported');
|
|
545
546
|
if ('value' in Attributes) O[P] = Attributes.value;
|
|
546
547
|
return O;
|
|
547
548
|
};
|
|
548
549
|
|
|
549
|
-
var DESCRIPTORS$
|
|
550
|
-
var definePropertyModule$
|
|
551
|
-
var createPropertyDescriptor = createPropertyDescriptor$
|
|
550
|
+
var DESCRIPTORS$6 = descriptors;
|
|
551
|
+
var definePropertyModule$4 = objectDefineProperty;
|
|
552
|
+
var createPropertyDescriptor$1 = createPropertyDescriptor$3;
|
|
552
553
|
|
|
553
|
-
var createNonEnumerableProperty$
|
|
554
|
-
return definePropertyModule$
|
|
554
|
+
var createNonEnumerableProperty$4 = DESCRIPTORS$6 ? function (object, key, value) {
|
|
555
|
+
return definePropertyModule$4.f(object, key, createPropertyDescriptor$1(1, value));
|
|
555
556
|
} : function (object, key, value) {
|
|
556
557
|
object[key] = value;
|
|
557
558
|
return object;
|
|
558
559
|
};
|
|
559
560
|
|
|
560
|
-
var makeBuiltIn$
|
|
561
|
+
var makeBuiltIn$3 = {exports: {}};
|
|
561
562
|
|
|
562
|
-
var DESCRIPTORS$
|
|
563
|
-
var hasOwn$
|
|
563
|
+
var DESCRIPTORS$5 = descriptors;
|
|
564
|
+
var hasOwn$7 = hasOwnProperty_1;
|
|
564
565
|
|
|
565
566
|
var FunctionPrototype$1 = Function.prototype;
|
|
566
567
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
567
|
-
var getDescriptor = DESCRIPTORS$
|
|
568
|
+
var getDescriptor = DESCRIPTORS$5 && Object.getOwnPropertyDescriptor;
|
|
568
569
|
|
|
569
|
-
var EXISTS = hasOwn$
|
|
570
|
-
|
|
571
|
-
var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
|
|
572
|
-
var CONFIGURABLE = EXISTS && (!DESCRIPTORS$3 || (DESCRIPTORS$3 && getDescriptor(FunctionPrototype$1, 'name').configurable));
|
|
570
|
+
var EXISTS = hasOwn$7(FunctionPrototype$1, 'name');
|
|
571
|
+
var CONFIGURABLE = EXISTS && (!DESCRIPTORS$5 || (DESCRIPTORS$5 && getDescriptor(FunctionPrototype$1, 'name').configurable));
|
|
573
572
|
|
|
574
573
|
var functionName = {
|
|
575
|
-
EXISTS: EXISTS,
|
|
576
|
-
PROPER: PROPER,
|
|
577
574
|
CONFIGURABLE: CONFIGURABLE
|
|
578
575
|
};
|
|
579
576
|
|
|
580
577
|
var uncurryThis$8 = functionUncurryThis;
|
|
581
|
-
var isCallable$
|
|
582
|
-
var store$1 =
|
|
578
|
+
var isCallable$a = isCallable$g;
|
|
579
|
+
var store$1 = sharedStoreExports;
|
|
583
580
|
|
|
584
581
|
var functionToString = uncurryThis$8(Function.toString);
|
|
585
582
|
|
|
586
583
|
// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
|
|
587
|
-
if (!isCallable$
|
|
584
|
+
if (!isCallable$a(store$1.inspectSource)) {
|
|
588
585
|
store$1.inspectSource = function (it) {
|
|
589
586
|
return functionToString(it);
|
|
590
587
|
};
|
|
@@ -592,36 +589,36 @@ if (!isCallable$7(store$1.inspectSource)) {
|
|
|
592
589
|
|
|
593
590
|
var inspectSource$1 = store$1.inspectSource;
|
|
594
591
|
|
|
595
|
-
var globalThis$
|
|
596
|
-
var isCallable$
|
|
592
|
+
var globalThis$9 = globalThis_1;
|
|
593
|
+
var isCallable$9 = isCallable$g;
|
|
597
594
|
|
|
598
|
-
var WeakMap$1 = globalThis$
|
|
595
|
+
var WeakMap$1 = globalThis$9.WeakMap;
|
|
599
596
|
|
|
600
|
-
var weakMapBasicDetection = isCallable$
|
|
597
|
+
var weakMapBasicDetection = isCallable$9(WeakMap$1) && /native code/.test(String(WeakMap$1));
|
|
601
598
|
|
|
602
599
|
var shared$2 = shared$4;
|
|
603
600
|
var uid = uid$2;
|
|
604
601
|
|
|
605
602
|
var keys = shared$2('keys');
|
|
606
603
|
|
|
607
|
-
var sharedKey$
|
|
604
|
+
var sharedKey$3 = function (key) {
|
|
608
605
|
return keys[key] || (keys[key] = uid(key));
|
|
609
606
|
};
|
|
610
607
|
|
|
611
608
|
var hiddenKeys$4 = {};
|
|
612
609
|
|
|
613
610
|
var NATIVE_WEAK_MAP = weakMapBasicDetection;
|
|
614
|
-
var globalThis$
|
|
615
|
-
var isObject = isObject$
|
|
616
|
-
var createNonEnumerableProperty$
|
|
617
|
-
var hasOwn$
|
|
618
|
-
var shared$1 =
|
|
619
|
-
var sharedKey$
|
|
611
|
+
var globalThis$8 = globalThis_1;
|
|
612
|
+
var isObject$2 = isObject$7;
|
|
613
|
+
var createNonEnumerableProperty$3 = createNonEnumerableProperty$4;
|
|
614
|
+
var hasOwn$6 = hasOwnProperty_1;
|
|
615
|
+
var shared$1 = sharedStoreExports;
|
|
616
|
+
var sharedKey$2 = sharedKey$3;
|
|
620
617
|
var hiddenKeys$3 = hiddenKeys$4;
|
|
621
618
|
|
|
622
619
|
var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
|
|
623
|
-
var TypeError$1 = globalThis$
|
|
624
|
-
var WeakMap = globalThis$
|
|
620
|
+
var TypeError$1 = globalThis$8.TypeError;
|
|
621
|
+
var WeakMap = globalThis$8.WeakMap;
|
|
625
622
|
var set, get, has;
|
|
626
623
|
|
|
627
624
|
var enforce = function (it) {
|
|
@@ -631,7 +628,7 @@ var enforce = function (it) {
|
|
|
631
628
|
var getterFor = function (TYPE) {
|
|
632
629
|
return function (it) {
|
|
633
630
|
var state;
|
|
634
|
-
if (!isObject(it) || (state = get(it)).type !== TYPE) {
|
|
631
|
+
if (!isObject$2(it) || (state = get(it)).type !== TYPE) {
|
|
635
632
|
throw new TypeError$1('Incompatible receiver, ' + TYPE + ' required');
|
|
636
633
|
} return state;
|
|
637
634
|
};
|
|
@@ -657,19 +654,19 @@ if (NATIVE_WEAK_MAP || shared$1.state) {
|
|
|
657
654
|
return store.has(it);
|
|
658
655
|
};
|
|
659
656
|
} else {
|
|
660
|
-
var STATE = sharedKey$
|
|
657
|
+
var STATE = sharedKey$2('state');
|
|
661
658
|
hiddenKeys$3[STATE] = true;
|
|
662
659
|
set = function (it, metadata) {
|
|
663
|
-
if (hasOwn$
|
|
660
|
+
if (hasOwn$6(it, STATE)) throw new TypeError$1(OBJECT_ALREADY_INITIALIZED);
|
|
664
661
|
metadata.facade = it;
|
|
665
|
-
createNonEnumerableProperty$
|
|
662
|
+
createNonEnumerableProperty$3(it, STATE, metadata);
|
|
666
663
|
return metadata;
|
|
667
664
|
};
|
|
668
665
|
get = function (it) {
|
|
669
|
-
return hasOwn$
|
|
666
|
+
return hasOwn$6(it, STATE) ? it[STATE] : {};
|
|
670
667
|
};
|
|
671
668
|
has = function (it) {
|
|
672
|
-
return hasOwn$
|
|
669
|
+
return hasOwn$6(it, STATE);
|
|
673
670
|
};
|
|
674
671
|
}
|
|
675
672
|
|
|
@@ -682,70 +679,72 @@ var internalState = {
|
|
|
682
679
|
};
|
|
683
680
|
|
|
684
681
|
var uncurryThis$7 = functionUncurryThis;
|
|
685
|
-
var fails$
|
|
686
|
-
var isCallable$
|
|
687
|
-
var hasOwn$
|
|
688
|
-
var DESCRIPTORS$
|
|
682
|
+
var fails$b = fails$i;
|
|
683
|
+
var isCallable$8 = isCallable$g;
|
|
684
|
+
var hasOwn$5 = hasOwnProperty_1;
|
|
685
|
+
var DESCRIPTORS$4 = descriptors;
|
|
689
686
|
var CONFIGURABLE_FUNCTION_NAME = functionName.CONFIGURABLE;
|
|
690
687
|
var inspectSource = inspectSource$1;
|
|
691
|
-
var InternalStateModule = internalState;
|
|
688
|
+
var InternalStateModule$1 = internalState;
|
|
692
689
|
|
|
693
|
-
var enforceInternalState = InternalStateModule.enforce;
|
|
694
|
-
var getInternalState$1 = InternalStateModule.get;
|
|
690
|
+
var enforceInternalState = InternalStateModule$1.enforce;
|
|
691
|
+
var getInternalState$1 = InternalStateModule$1.get;
|
|
695
692
|
var $String$1 = String;
|
|
696
693
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
697
|
-
var defineProperty$
|
|
694
|
+
var defineProperty$2 = Object.defineProperty;
|
|
698
695
|
var stringSlice$4 = uncurryThis$7(''.slice);
|
|
699
696
|
var replace$2 = uncurryThis$7(''.replace);
|
|
700
697
|
var join = uncurryThis$7([].join);
|
|
701
698
|
|
|
702
|
-
var CONFIGURABLE_LENGTH = DESCRIPTORS$
|
|
703
|
-
return defineProperty$
|
|
699
|
+
var CONFIGURABLE_LENGTH = DESCRIPTORS$4 && !fails$b(function () {
|
|
700
|
+
return defineProperty$2(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
|
|
704
701
|
});
|
|
705
702
|
|
|
706
703
|
var TEMPLATE = String(String).split('String');
|
|
707
704
|
|
|
708
|
-
var makeBuiltIn$
|
|
705
|
+
var makeBuiltIn$2 = makeBuiltIn$3.exports = function (value, name, options) {
|
|
709
706
|
if (stringSlice$4($String$1(name), 0, 7) === 'Symbol(') {
|
|
710
707
|
name = '[' + replace$2($String$1(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
|
|
711
708
|
}
|
|
712
709
|
if (options && options.getter) name = 'get ' + name;
|
|
713
710
|
if (options && options.setter) name = 'set ' + name;
|
|
714
|
-
if (!hasOwn$
|
|
715
|
-
if (DESCRIPTORS$
|
|
711
|
+
if (!hasOwn$5(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {
|
|
712
|
+
if (DESCRIPTORS$4) defineProperty$2(value, 'name', { value: name, configurable: true });
|
|
716
713
|
else value.name = name;
|
|
717
714
|
}
|
|
718
|
-
if (CONFIGURABLE_LENGTH && options && hasOwn$
|
|
719
|
-
defineProperty$
|
|
715
|
+
if (CONFIGURABLE_LENGTH && options && hasOwn$5(options, 'arity') && value.length !== options.arity) {
|
|
716
|
+
defineProperty$2(value, 'length', { value: options.arity });
|
|
720
717
|
}
|
|
721
718
|
try {
|
|
722
|
-
if (options && hasOwn$
|
|
723
|
-
if (DESCRIPTORS$
|
|
719
|
+
if (options && hasOwn$5(options, 'constructor') && options.constructor) {
|
|
720
|
+
if (DESCRIPTORS$4) defineProperty$2(value, 'prototype', { writable: false });
|
|
724
721
|
// in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable
|
|
725
722
|
} else if (value.prototype) value.prototype = undefined;
|
|
726
723
|
} catch (error) { /* empty */ }
|
|
727
724
|
var state = enforceInternalState(value);
|
|
728
|
-
if (!hasOwn$
|
|
725
|
+
if (!hasOwn$5(state, 'source')) {
|
|
729
726
|
state.source = join(TEMPLATE, typeof name == 'string' ? name : '');
|
|
730
727
|
} return value;
|
|
731
728
|
};
|
|
732
729
|
|
|
733
730
|
// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
|
|
734
731
|
// eslint-disable-next-line no-extend-native -- required
|
|
735
|
-
Function.prototype.toString = makeBuiltIn$
|
|
736
|
-
return isCallable$
|
|
732
|
+
Function.prototype.toString = makeBuiltIn$2(function toString() {
|
|
733
|
+
return isCallable$8(this) && getInternalState$1(this).source || inspectSource(this);
|
|
737
734
|
}, 'toString');
|
|
738
735
|
|
|
739
|
-
var
|
|
740
|
-
|
|
741
|
-
var
|
|
736
|
+
var makeBuiltInExports = makeBuiltIn$3.exports;
|
|
737
|
+
|
|
738
|
+
var isCallable$7 = isCallable$g;
|
|
739
|
+
var definePropertyModule$3 = objectDefineProperty;
|
|
740
|
+
var makeBuiltIn$1 = makeBuiltInExports;
|
|
742
741
|
var defineGlobalProperty$1 = defineGlobalProperty$3;
|
|
743
742
|
|
|
744
|
-
var defineBuiltIn$
|
|
743
|
+
var defineBuiltIn$4 = function (O, key, value, options) {
|
|
745
744
|
if (!options) options = {};
|
|
746
745
|
var simple = options.enumerable;
|
|
747
746
|
var name = options.name !== undefined ? options.name : key;
|
|
748
|
-
if (isCallable$
|
|
747
|
+
if (isCallable$7(value)) makeBuiltIn$1(value, name, options);
|
|
749
748
|
if (options.global) {
|
|
750
749
|
if (simple) O[key] = value;
|
|
751
750
|
else defineGlobalProperty$1(key, value);
|
|
@@ -755,7 +754,7 @@ var defineBuiltIn$2 = function (O, key, value, options) {
|
|
|
755
754
|
else if (O[key]) simple = true;
|
|
756
755
|
} catch (error) { /* empty */ }
|
|
757
756
|
if (simple) O[key] = value;
|
|
758
|
-
else definePropertyModule$
|
|
757
|
+
else definePropertyModule$3.f(O, key, {
|
|
759
758
|
value: value,
|
|
760
759
|
enumerable: false,
|
|
761
760
|
configurable: !options.nonConfigurable,
|
|
@@ -845,16 +844,13 @@ var createMethod$1 = function (IS_INCLUDES) {
|
|
|
845
844
|
};
|
|
846
845
|
|
|
847
846
|
var arrayIncludes = {
|
|
848
|
-
// `Array.prototype.includes` method
|
|
849
|
-
// https://tc39.es/ecma262/#sec-array.prototype.includes
|
|
850
|
-
includes: createMethod$1(true),
|
|
851
847
|
// `Array.prototype.indexOf` method
|
|
852
848
|
// https://tc39.es/ecma262/#sec-array.prototype.indexof
|
|
853
849
|
indexOf: createMethod$1(false)
|
|
854
850
|
};
|
|
855
851
|
|
|
856
852
|
var uncurryThis$6 = functionUncurryThis;
|
|
857
|
-
var hasOwn$
|
|
853
|
+
var hasOwn$4 = hasOwnProperty_1;
|
|
858
854
|
var toIndexedObject$1 = toIndexedObject$4;
|
|
859
855
|
var indexOf$1 = arrayIncludes.indexOf;
|
|
860
856
|
var hiddenKeys$2 = hiddenKeys$4;
|
|
@@ -866,9 +862,9 @@ var objectKeysInternal = function (object, names) {
|
|
|
866
862
|
var i = 0;
|
|
867
863
|
var result = [];
|
|
868
864
|
var key;
|
|
869
|
-
for (key in O) !hasOwn$
|
|
865
|
+
for (key in O) !hasOwn$4(hiddenKeys$2, key) && hasOwn$4(O, key) && push$1(result, key);
|
|
870
866
|
// Don't enum bug & hidden keys
|
|
871
|
-
while (names.length > i) if (hasOwn$
|
|
867
|
+
while (names.length > i) if (hasOwn$4(O, key = names[i++])) {
|
|
872
868
|
~indexOf$1(result, key) || push$1(result, key);
|
|
873
869
|
}
|
|
874
870
|
return result;
|
|
@@ -906,36 +902,36 @@ var getBuiltIn$1 = getBuiltIn$3;
|
|
|
906
902
|
var uncurryThis$5 = functionUncurryThis;
|
|
907
903
|
var getOwnPropertyNamesModule = objectGetOwnPropertyNames;
|
|
908
904
|
var getOwnPropertySymbolsModule$1 = objectGetOwnPropertySymbols;
|
|
909
|
-
var anObject$
|
|
905
|
+
var anObject$9 = anObject$b;
|
|
910
906
|
|
|
911
907
|
var concat$2 = uncurryThis$5([].concat);
|
|
912
908
|
|
|
913
909
|
// all object keys, includes non-enumerable and symbols
|
|
914
910
|
var ownKeys$1 = getBuiltIn$1('Reflect', 'ownKeys') || function ownKeys(it) {
|
|
915
|
-
var keys = getOwnPropertyNamesModule.f(anObject$
|
|
911
|
+
var keys = getOwnPropertyNamesModule.f(anObject$9(it));
|
|
916
912
|
var getOwnPropertySymbols = getOwnPropertySymbolsModule$1.f;
|
|
917
913
|
return getOwnPropertySymbols ? concat$2(keys, getOwnPropertySymbols(it)) : keys;
|
|
918
914
|
};
|
|
919
915
|
|
|
920
|
-
var hasOwn = hasOwnProperty_1;
|
|
916
|
+
var hasOwn$3 = hasOwnProperty_1;
|
|
921
917
|
var ownKeys = ownKeys$1;
|
|
922
918
|
var getOwnPropertyDescriptorModule = objectGetOwnPropertyDescriptor;
|
|
923
|
-
var definePropertyModule$
|
|
919
|
+
var definePropertyModule$2 = objectDefineProperty;
|
|
924
920
|
|
|
925
921
|
var copyConstructorProperties$1 = function (target, source, exceptions) {
|
|
926
922
|
var keys = ownKeys(source);
|
|
927
|
-
var defineProperty = definePropertyModule$
|
|
923
|
+
var defineProperty = definePropertyModule$2.f;
|
|
928
924
|
var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
|
|
929
925
|
for (var i = 0; i < keys.length; i++) {
|
|
930
926
|
var key = keys[i];
|
|
931
|
-
if (!hasOwn(target, key) && !(exceptions && hasOwn(exceptions, key))) {
|
|
927
|
+
if (!hasOwn$3(target, key) && !(exceptions && hasOwn$3(exceptions, key))) {
|
|
932
928
|
defineProperty(target, key, getOwnPropertyDescriptor(source, key));
|
|
933
929
|
}
|
|
934
930
|
}
|
|
935
931
|
};
|
|
936
932
|
|
|
937
|
-
var fails$
|
|
938
|
-
var isCallable$
|
|
933
|
+
var fails$a = fails$i;
|
|
934
|
+
var isCallable$6 = isCallable$g;
|
|
939
935
|
|
|
940
936
|
var replacement = /#|\.prototype\./;
|
|
941
937
|
|
|
@@ -943,7 +939,7 @@ var isForced$1 = function (feature, detection) {
|
|
|
943
939
|
var value = data[normalize(feature)];
|
|
944
940
|
return value === POLYFILL ? true
|
|
945
941
|
: value === NATIVE ? false
|
|
946
|
-
: isCallable$
|
|
942
|
+
: isCallable$6(detection) ? fails$a(detection)
|
|
947
943
|
: !!detection;
|
|
948
944
|
};
|
|
949
945
|
|
|
@@ -957,10 +953,10 @@ var POLYFILL = isForced$1.POLYFILL = 'P';
|
|
|
957
953
|
|
|
958
954
|
var isForced_1 = isForced$1;
|
|
959
955
|
|
|
960
|
-
var globalThis$
|
|
956
|
+
var globalThis$7 = globalThis_1;
|
|
961
957
|
var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
|
|
962
|
-
var createNonEnumerableProperty$
|
|
963
|
-
var defineBuiltIn$
|
|
958
|
+
var createNonEnumerableProperty$2 = createNonEnumerableProperty$4;
|
|
959
|
+
var defineBuiltIn$3 = defineBuiltIn$4;
|
|
964
960
|
var defineGlobalProperty = defineGlobalProperty$3;
|
|
965
961
|
var copyConstructorProperties = copyConstructorProperties$1;
|
|
966
962
|
var isForced = isForced_1;
|
|
@@ -986,11 +982,11 @@ var _export = function (options, source) {
|
|
|
986
982
|
var STATIC = options.stat;
|
|
987
983
|
var FORCED, target, key, targetProperty, sourceProperty, descriptor;
|
|
988
984
|
if (GLOBAL) {
|
|
989
|
-
target = globalThis$
|
|
985
|
+
target = globalThis$7;
|
|
990
986
|
} else if (STATIC) {
|
|
991
|
-
target = globalThis$
|
|
987
|
+
target = globalThis$7[TARGET] || defineGlobalProperty(TARGET, {});
|
|
992
988
|
} else {
|
|
993
|
-
target = globalThis$
|
|
989
|
+
target = globalThis$7[TARGET] && globalThis$7[TARGET].prototype;
|
|
994
990
|
}
|
|
995
991
|
if (target) for (key in source) {
|
|
996
992
|
sourceProperty = source[key];
|
|
@@ -1006,12 +1002,72 @@ var _export = function (options, source) {
|
|
|
1006
1002
|
}
|
|
1007
1003
|
// add a flag to not completely full polyfills
|
|
1008
1004
|
if (options.sham || (targetProperty && targetProperty.sham)) {
|
|
1009
|
-
createNonEnumerableProperty$
|
|
1005
|
+
createNonEnumerableProperty$2(sourceProperty, 'sham', true);
|
|
1010
1006
|
}
|
|
1011
|
-
defineBuiltIn$
|
|
1007
|
+
defineBuiltIn$3(target, key, sourceProperty, options);
|
|
1012
1008
|
}
|
|
1013
1009
|
};
|
|
1014
1010
|
|
|
1011
|
+
var isPrototypeOf$1 = objectIsPrototypeOf;
|
|
1012
|
+
|
|
1013
|
+
var $TypeError$2 = TypeError;
|
|
1014
|
+
|
|
1015
|
+
var anInstance$1 = function (it, Prototype) {
|
|
1016
|
+
if (isPrototypeOf$1(Prototype, it)) return it;
|
|
1017
|
+
throw new $TypeError$2('Incorrect invocation');
|
|
1018
|
+
};
|
|
1019
|
+
|
|
1020
|
+
var fails$9 = fails$i;
|
|
1021
|
+
|
|
1022
|
+
var correctPrototypeGetter = !fails$9(function () {
|
|
1023
|
+
function F() { /* empty */ }
|
|
1024
|
+
F.prototype.constructor = null;
|
|
1025
|
+
// eslint-disable-next-line es/no-object-getprototypeof -- required for testing
|
|
1026
|
+
return Object.getPrototypeOf(new F()) !== F.prototype;
|
|
1027
|
+
});
|
|
1028
|
+
|
|
1029
|
+
var hasOwn$2 = hasOwnProperty_1;
|
|
1030
|
+
var isCallable$5 = isCallable$g;
|
|
1031
|
+
var toObject$2 = toObject$4;
|
|
1032
|
+
var sharedKey$1 = sharedKey$3;
|
|
1033
|
+
var CORRECT_PROTOTYPE_GETTER = correctPrototypeGetter;
|
|
1034
|
+
|
|
1035
|
+
var IE_PROTO$1 = sharedKey$1('IE_PROTO');
|
|
1036
|
+
var $Object$1 = Object;
|
|
1037
|
+
var ObjectPrototype = $Object$1.prototype;
|
|
1038
|
+
|
|
1039
|
+
// `Object.getPrototypeOf` method
|
|
1040
|
+
// https://tc39.es/ecma262/#sec-object.getprototypeof
|
|
1041
|
+
// eslint-disable-next-line es/no-object-getprototypeof -- safe
|
|
1042
|
+
var objectGetPrototypeOf = CORRECT_PROTOTYPE_GETTER ? $Object$1.getPrototypeOf : function (O) {
|
|
1043
|
+
var object = toObject$2(O);
|
|
1044
|
+
if (hasOwn$2(object, IE_PROTO$1)) return object[IE_PROTO$1];
|
|
1045
|
+
var constructor = object.constructor;
|
|
1046
|
+
if (isCallable$5(constructor) && object instanceof constructor) {
|
|
1047
|
+
return constructor.prototype;
|
|
1048
|
+
} return object instanceof $Object$1 ? ObjectPrototype : null;
|
|
1049
|
+
};
|
|
1050
|
+
|
|
1051
|
+
var makeBuiltIn = makeBuiltInExports;
|
|
1052
|
+
var defineProperty$1 = objectDefineProperty;
|
|
1053
|
+
|
|
1054
|
+
var defineBuiltInAccessor$1 = function (target, name, descriptor) {
|
|
1055
|
+
if (descriptor.get) makeBuiltIn(descriptor.get, name, { getter: true });
|
|
1056
|
+
if (descriptor.set) makeBuiltIn(descriptor.set, name, { setter: true });
|
|
1057
|
+
return defineProperty$1.f(target, name, descriptor);
|
|
1058
|
+
};
|
|
1059
|
+
|
|
1060
|
+
var DESCRIPTORS$3 = descriptors;
|
|
1061
|
+
var definePropertyModule$1 = objectDefineProperty;
|
|
1062
|
+
var createPropertyDescriptor = createPropertyDescriptor$3;
|
|
1063
|
+
|
|
1064
|
+
var createProperty$1 = function (object, key, value) {
|
|
1065
|
+
if (DESCRIPTORS$3) definePropertyModule$1.f(object, key, createPropertyDescriptor(0, value));
|
|
1066
|
+
else object[key] = value;
|
|
1067
|
+
};
|
|
1068
|
+
|
|
1069
|
+
var objectDefineProperties = {};
|
|
1070
|
+
|
|
1015
1071
|
var internalObjectKeys = objectKeysInternal;
|
|
1016
1072
|
var enumBugKeys$1 = enumBugKeys$3;
|
|
1017
1073
|
|
|
@@ -1022,14 +1078,469 @@ var objectKeys$2 = Object.keys || function keys(O) {
|
|
|
1022
1078
|
return internalObjectKeys(O, enumBugKeys$1);
|
|
1023
1079
|
};
|
|
1024
1080
|
|
|
1081
|
+
var DESCRIPTORS$2 = descriptors;
|
|
1082
|
+
var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
|
|
1083
|
+
var definePropertyModule = objectDefineProperty;
|
|
1084
|
+
var anObject$8 = anObject$b;
|
|
1085
|
+
var toIndexedObject = toIndexedObject$4;
|
|
1086
|
+
var objectKeys$1 = objectKeys$2;
|
|
1087
|
+
|
|
1088
|
+
// `Object.defineProperties` method
|
|
1089
|
+
// https://tc39.es/ecma262/#sec-object.defineproperties
|
|
1090
|
+
// eslint-disable-next-line es/no-object-defineproperties -- safe
|
|
1091
|
+
objectDefineProperties.f = DESCRIPTORS$2 && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
|
|
1092
|
+
anObject$8(O);
|
|
1093
|
+
var props = toIndexedObject(Properties);
|
|
1094
|
+
var keys = objectKeys$1(Properties);
|
|
1095
|
+
var length = keys.length;
|
|
1096
|
+
var index = 0;
|
|
1097
|
+
var key;
|
|
1098
|
+
while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);
|
|
1099
|
+
return O;
|
|
1100
|
+
};
|
|
1101
|
+
|
|
1102
|
+
var getBuiltIn = getBuiltIn$3;
|
|
1103
|
+
|
|
1104
|
+
var html$1 = getBuiltIn('document', 'documentElement');
|
|
1105
|
+
|
|
1106
|
+
/* global ActiveXObject -- old IE, WSH */
|
|
1107
|
+
var anObject$7 = anObject$b;
|
|
1108
|
+
var definePropertiesModule = objectDefineProperties;
|
|
1109
|
+
var enumBugKeys = enumBugKeys$3;
|
|
1110
|
+
var hiddenKeys = hiddenKeys$4;
|
|
1111
|
+
var html = html$1;
|
|
1112
|
+
var documentCreateElement = documentCreateElement$1;
|
|
1113
|
+
var sharedKey = sharedKey$3;
|
|
1114
|
+
|
|
1115
|
+
var GT = '>';
|
|
1116
|
+
var LT = '<';
|
|
1117
|
+
var PROTOTYPE = 'prototype';
|
|
1118
|
+
var SCRIPT = 'script';
|
|
1119
|
+
var IE_PROTO = sharedKey('IE_PROTO');
|
|
1120
|
+
|
|
1121
|
+
var EmptyConstructor = function () { /* empty */ };
|
|
1122
|
+
|
|
1123
|
+
var scriptTag = function (content) {
|
|
1124
|
+
return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
|
|
1125
|
+
};
|
|
1126
|
+
|
|
1127
|
+
// Create object with fake `null` prototype: use ActiveX Object with cleared prototype
|
|
1128
|
+
var NullProtoObjectViaActiveX = function (activeXDocument) {
|
|
1129
|
+
activeXDocument.write(scriptTag(''));
|
|
1130
|
+
activeXDocument.close();
|
|
1131
|
+
var temp = activeXDocument.parentWindow.Object;
|
|
1132
|
+
// eslint-disable-next-line no-useless-assignment -- avoid memory leak
|
|
1133
|
+
activeXDocument = null;
|
|
1134
|
+
return temp;
|
|
1135
|
+
};
|
|
1136
|
+
|
|
1137
|
+
// Create object with fake `null` prototype: use iframe Object with cleared prototype
|
|
1138
|
+
var NullProtoObjectViaIFrame = function () {
|
|
1139
|
+
// Thrash, waste and sodomy: IE GC bug
|
|
1140
|
+
var iframe = documentCreateElement('iframe');
|
|
1141
|
+
var JS = 'java' + SCRIPT + ':';
|
|
1142
|
+
var iframeDocument;
|
|
1143
|
+
iframe.style.display = 'none';
|
|
1144
|
+
html.appendChild(iframe);
|
|
1145
|
+
// https://github.com/zloirock/core-js/issues/475
|
|
1146
|
+
iframe.src = String(JS);
|
|
1147
|
+
iframeDocument = iframe.contentWindow.document;
|
|
1148
|
+
iframeDocument.open();
|
|
1149
|
+
iframeDocument.write(scriptTag('document.F=Object'));
|
|
1150
|
+
iframeDocument.close();
|
|
1151
|
+
return iframeDocument.F;
|
|
1152
|
+
};
|
|
1153
|
+
|
|
1154
|
+
// Check for document.domain and active x support
|
|
1155
|
+
// No need to use active x approach when document.domain is not set
|
|
1156
|
+
// see https://github.com/es-shims/es5-shim/issues/150
|
|
1157
|
+
// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
|
|
1158
|
+
// avoid IE GC bug
|
|
1159
|
+
var activeXDocument;
|
|
1160
|
+
var NullProtoObject = function () {
|
|
1161
|
+
try {
|
|
1162
|
+
activeXDocument = new ActiveXObject('htmlfile');
|
|
1163
|
+
} catch (error) { /* ignore */ }
|
|
1164
|
+
NullProtoObject = typeof document != 'undefined'
|
|
1165
|
+
? document.domain && activeXDocument
|
|
1166
|
+
? NullProtoObjectViaActiveX(activeXDocument) // old IE
|
|
1167
|
+
: NullProtoObjectViaIFrame()
|
|
1168
|
+
: NullProtoObjectViaActiveX(activeXDocument); // WSH
|
|
1169
|
+
var length = enumBugKeys.length;
|
|
1170
|
+
while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];
|
|
1171
|
+
return NullProtoObject();
|
|
1172
|
+
};
|
|
1173
|
+
|
|
1174
|
+
hiddenKeys[IE_PROTO] = true;
|
|
1175
|
+
|
|
1176
|
+
// `Object.create` method
|
|
1177
|
+
// https://tc39.es/ecma262/#sec-object.create
|
|
1178
|
+
// eslint-disable-next-line es/no-object-create -- safe
|
|
1179
|
+
var objectCreate = Object.create || function create(O, Properties) {
|
|
1180
|
+
var result;
|
|
1181
|
+
if (O !== null) {
|
|
1182
|
+
EmptyConstructor[PROTOTYPE] = anObject$7(O);
|
|
1183
|
+
result = new EmptyConstructor();
|
|
1184
|
+
EmptyConstructor[PROTOTYPE] = null;
|
|
1185
|
+
// add "__proto__" for Object.getPrototypeOf polyfill
|
|
1186
|
+
result[IE_PROTO] = O;
|
|
1187
|
+
} else result = NullProtoObject();
|
|
1188
|
+
return Properties === undefined ? result : definePropertiesModule.f(result, Properties);
|
|
1189
|
+
};
|
|
1190
|
+
|
|
1191
|
+
var fails$8 = fails$i;
|
|
1192
|
+
var isCallable$4 = isCallable$g;
|
|
1193
|
+
var isObject$1 = isObject$7;
|
|
1194
|
+
var getPrototypeOf$1 = objectGetPrototypeOf;
|
|
1195
|
+
var defineBuiltIn$2 = defineBuiltIn$4;
|
|
1196
|
+
var wellKnownSymbol$6 = wellKnownSymbol$8;
|
|
1197
|
+
|
|
1198
|
+
var ITERATOR$1 = wellKnownSymbol$6('iterator');
|
|
1199
|
+
|
|
1200
|
+
// `%IteratorPrototype%` object
|
|
1201
|
+
// https://tc39.es/ecma262/#sec-%iteratorprototype%-object
|
|
1202
|
+
var IteratorPrototype$2, PrototypeOfArrayIteratorPrototype, arrayIterator;
|
|
1203
|
+
|
|
1204
|
+
/* eslint-disable es/no-array-prototype-keys -- safe */
|
|
1205
|
+
if ([].keys) {
|
|
1206
|
+
arrayIterator = [].keys();
|
|
1207
|
+
// Safari 8 has buggy iterators w/o `next`
|
|
1208
|
+
if (!('next' in arrayIterator)) ;
|
|
1209
|
+
else {
|
|
1210
|
+
PrototypeOfArrayIteratorPrototype = getPrototypeOf$1(getPrototypeOf$1(arrayIterator));
|
|
1211
|
+
if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype$2 = PrototypeOfArrayIteratorPrototype;
|
|
1212
|
+
}
|
|
1213
|
+
}
|
|
1214
|
+
|
|
1215
|
+
var NEW_ITERATOR_PROTOTYPE = !isObject$1(IteratorPrototype$2) || fails$8(function () {
|
|
1216
|
+
var test = {};
|
|
1217
|
+
// FF44- legacy iterators case
|
|
1218
|
+
return IteratorPrototype$2[ITERATOR$1].call(test) !== test;
|
|
1219
|
+
});
|
|
1220
|
+
|
|
1221
|
+
if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype$2 = {};
|
|
1222
|
+
|
|
1223
|
+
// `%IteratorPrototype%[@@iterator]()` method
|
|
1224
|
+
// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator
|
|
1225
|
+
if (!isCallable$4(IteratorPrototype$2[ITERATOR$1])) {
|
|
1226
|
+
defineBuiltIn$2(IteratorPrototype$2, ITERATOR$1, function () {
|
|
1227
|
+
return this;
|
|
1228
|
+
});
|
|
1229
|
+
}
|
|
1230
|
+
|
|
1231
|
+
var iteratorsCore = {
|
|
1232
|
+
IteratorPrototype: IteratorPrototype$2};
|
|
1233
|
+
|
|
1234
|
+
var $$3 = _export;
|
|
1235
|
+
var globalThis$6 = globalThis_1;
|
|
1236
|
+
var anInstance = anInstance$1;
|
|
1237
|
+
var anObject$6 = anObject$b;
|
|
1238
|
+
var isCallable$3 = isCallable$g;
|
|
1239
|
+
var getPrototypeOf = objectGetPrototypeOf;
|
|
1240
|
+
var defineBuiltInAccessor = defineBuiltInAccessor$1;
|
|
1241
|
+
var createProperty = createProperty$1;
|
|
1242
|
+
var fails$7 = fails$i;
|
|
1243
|
+
var hasOwn$1 = hasOwnProperty_1;
|
|
1244
|
+
var wellKnownSymbol$5 = wellKnownSymbol$8;
|
|
1245
|
+
var IteratorPrototype$1 = iteratorsCore.IteratorPrototype;
|
|
1025
1246
|
var DESCRIPTORS$1 = descriptors;
|
|
1247
|
+
|
|
1248
|
+
var CONSTRUCTOR = 'constructor';
|
|
1249
|
+
var ITERATOR = 'Iterator';
|
|
1250
|
+
var TO_STRING_TAG$3 = wellKnownSymbol$5('toStringTag');
|
|
1251
|
+
|
|
1252
|
+
var $TypeError$1 = TypeError;
|
|
1253
|
+
var NativeIterator = globalThis$6[ITERATOR];
|
|
1254
|
+
|
|
1255
|
+
// FF56- have non-standard global helper `Iterator`
|
|
1256
|
+
var FORCED$1 = !isCallable$3(NativeIterator)
|
|
1257
|
+
|| NativeIterator.prototype !== IteratorPrototype$1
|
|
1258
|
+
// FF44- non-standard `Iterator` passes previous tests
|
|
1259
|
+
|| !fails$7(function () { NativeIterator({}); });
|
|
1260
|
+
|
|
1261
|
+
var IteratorConstructor = function Iterator() {
|
|
1262
|
+
anInstance(this, IteratorPrototype$1);
|
|
1263
|
+
if (getPrototypeOf(this) === IteratorPrototype$1) throw new $TypeError$1('Abstract class Iterator not directly constructable');
|
|
1264
|
+
};
|
|
1265
|
+
|
|
1266
|
+
var defineIteratorPrototypeAccessor = function (key, value) {
|
|
1267
|
+
if (DESCRIPTORS$1) {
|
|
1268
|
+
defineBuiltInAccessor(IteratorPrototype$1, key, {
|
|
1269
|
+
configurable: true,
|
|
1270
|
+
get: function () {
|
|
1271
|
+
return value;
|
|
1272
|
+
},
|
|
1273
|
+
set: function (replacement) {
|
|
1274
|
+
anObject$6(this);
|
|
1275
|
+
if (this === IteratorPrototype$1) throw new $TypeError$1("You can't redefine this property");
|
|
1276
|
+
if (hasOwn$1(this, key)) this[key] = replacement;
|
|
1277
|
+
else createProperty(this, key, replacement);
|
|
1278
|
+
}
|
|
1279
|
+
});
|
|
1280
|
+
} else IteratorPrototype$1[key] = value;
|
|
1281
|
+
};
|
|
1282
|
+
|
|
1283
|
+
if (!hasOwn$1(IteratorPrototype$1, TO_STRING_TAG$3)) defineIteratorPrototypeAccessor(TO_STRING_TAG$3, ITERATOR);
|
|
1284
|
+
|
|
1285
|
+
if (FORCED$1 || !hasOwn$1(IteratorPrototype$1, CONSTRUCTOR) || IteratorPrototype$1[CONSTRUCTOR] === Object) {
|
|
1286
|
+
defineIteratorPrototypeAccessor(CONSTRUCTOR, IteratorConstructor);
|
|
1287
|
+
}
|
|
1288
|
+
|
|
1289
|
+
IteratorConstructor.prototype = IteratorPrototype$1;
|
|
1290
|
+
|
|
1291
|
+
// `Iterator` constructor
|
|
1292
|
+
// https://tc39.es/ecma262/#sec-iterator
|
|
1293
|
+
$$3({ global: true, constructor: true, forced: FORCED$1 }, {
|
|
1294
|
+
Iterator: IteratorConstructor
|
|
1295
|
+
});
|
|
1296
|
+
|
|
1297
|
+
// `GetIteratorDirect(obj)` abstract operation
|
|
1298
|
+
// https://tc39.es/ecma262/#sec-getiteratordirect
|
|
1299
|
+
var getIteratorDirect$1 = function (obj) {
|
|
1300
|
+
return {
|
|
1301
|
+
iterator: obj,
|
|
1302
|
+
next: obj.next,
|
|
1303
|
+
done: false
|
|
1304
|
+
};
|
|
1305
|
+
};
|
|
1306
|
+
|
|
1307
|
+
var defineBuiltIn$1 = defineBuiltIn$4;
|
|
1308
|
+
|
|
1309
|
+
var defineBuiltIns$1 = function (target, src, options) {
|
|
1310
|
+
for (var key in src) defineBuiltIn$1(target, key, src[key], options);
|
|
1311
|
+
return target;
|
|
1312
|
+
};
|
|
1313
|
+
|
|
1314
|
+
// `CreateIterResultObject` abstract operation
|
|
1315
|
+
// https://tc39.es/ecma262/#sec-createiterresultobject
|
|
1316
|
+
var createIterResultObject$1 = function (value, done) {
|
|
1317
|
+
return { value: value, done: done };
|
|
1318
|
+
};
|
|
1319
|
+
|
|
1320
|
+
var call$9 = functionCall;
|
|
1321
|
+
var anObject$5 = anObject$b;
|
|
1322
|
+
var getMethod$2 = getMethod$4;
|
|
1323
|
+
|
|
1324
|
+
var iteratorClose$4 = function (iterator, kind, value) {
|
|
1325
|
+
var innerResult, innerError;
|
|
1326
|
+
anObject$5(iterator);
|
|
1327
|
+
try {
|
|
1328
|
+
innerResult = getMethod$2(iterator, 'return');
|
|
1329
|
+
if (!innerResult) {
|
|
1330
|
+
if (kind === 'throw') throw value;
|
|
1331
|
+
return value;
|
|
1332
|
+
}
|
|
1333
|
+
innerResult = call$9(innerResult, iterator);
|
|
1334
|
+
} catch (error) {
|
|
1335
|
+
innerError = true;
|
|
1336
|
+
innerResult = error;
|
|
1337
|
+
}
|
|
1338
|
+
if (kind === 'throw') throw value;
|
|
1339
|
+
if (innerError) throw innerResult;
|
|
1340
|
+
anObject$5(innerResult);
|
|
1341
|
+
return value;
|
|
1342
|
+
};
|
|
1343
|
+
|
|
1344
|
+
var iteratorClose$3 = iteratorClose$4;
|
|
1345
|
+
|
|
1346
|
+
var iteratorCloseAll$1 = function (iters, kind, value) {
|
|
1347
|
+
for (var i = iters.length - 1; i >= 0; i--) {
|
|
1348
|
+
if (iters[i] === undefined) continue;
|
|
1349
|
+
try {
|
|
1350
|
+
value = iteratorClose$3(iters[i].iterator, kind, value);
|
|
1351
|
+
} catch (error) {
|
|
1352
|
+
kind = 'throw';
|
|
1353
|
+
value = error;
|
|
1354
|
+
}
|
|
1355
|
+
}
|
|
1356
|
+
if (kind === 'throw') throw value;
|
|
1357
|
+
return value;
|
|
1358
|
+
};
|
|
1359
|
+
|
|
1360
|
+
var call$8 = functionCall;
|
|
1361
|
+
var create$1 = objectCreate;
|
|
1362
|
+
var createNonEnumerableProperty$1 = createNonEnumerableProperty$4;
|
|
1363
|
+
var defineBuiltIns = defineBuiltIns$1;
|
|
1364
|
+
var wellKnownSymbol$4 = wellKnownSymbol$8;
|
|
1365
|
+
var InternalStateModule = internalState;
|
|
1366
|
+
var getMethod$1 = getMethod$4;
|
|
1367
|
+
var IteratorPrototype = iteratorsCore.IteratorPrototype;
|
|
1368
|
+
var createIterResultObject = createIterResultObject$1;
|
|
1369
|
+
var iteratorClose$2 = iteratorClose$4;
|
|
1370
|
+
var iteratorCloseAll = iteratorCloseAll$1;
|
|
1371
|
+
|
|
1372
|
+
var TO_STRING_TAG$2 = wellKnownSymbol$4('toStringTag');
|
|
1373
|
+
var ITERATOR_HELPER = 'IteratorHelper';
|
|
1374
|
+
var WRAP_FOR_VALID_ITERATOR = 'WrapForValidIterator';
|
|
1375
|
+
var NORMAL = 'normal';
|
|
1376
|
+
var THROW = 'throw';
|
|
1377
|
+
var setInternalState = InternalStateModule.set;
|
|
1378
|
+
|
|
1379
|
+
var createIteratorProxyPrototype = function (IS_ITERATOR) {
|
|
1380
|
+
var getInternalState = InternalStateModule.getterFor(IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER);
|
|
1381
|
+
|
|
1382
|
+
return defineBuiltIns(create$1(IteratorPrototype), {
|
|
1383
|
+
next: function next() {
|
|
1384
|
+
var state = getInternalState(this);
|
|
1385
|
+
// for simplification:
|
|
1386
|
+
// for `%WrapForValidIteratorPrototype%.next` or with `state.returnHandlerResult` our `nextHandler` returns `IterResultObject`
|
|
1387
|
+
// for `%IteratorHelperPrototype%.next` - just a value
|
|
1388
|
+
if (IS_ITERATOR) return state.nextHandler();
|
|
1389
|
+
if (state.done) return createIterResultObject(undefined, true);
|
|
1390
|
+
try {
|
|
1391
|
+
var result = state.nextHandler();
|
|
1392
|
+
return state.returnHandlerResult ? result : createIterResultObject(result, state.done);
|
|
1393
|
+
} catch (error) {
|
|
1394
|
+
state.done = true;
|
|
1395
|
+
throw error;
|
|
1396
|
+
}
|
|
1397
|
+
},
|
|
1398
|
+
'return': function () {
|
|
1399
|
+
var state = getInternalState(this);
|
|
1400
|
+
var iterator = state.iterator;
|
|
1401
|
+
state.done = true;
|
|
1402
|
+
if (IS_ITERATOR) {
|
|
1403
|
+
var returnMethod = getMethod$1(iterator, 'return');
|
|
1404
|
+
return returnMethod ? call$8(returnMethod, iterator) : createIterResultObject(undefined, true);
|
|
1405
|
+
}
|
|
1406
|
+
if (state.inner) try {
|
|
1407
|
+
iteratorClose$2(state.inner.iterator, NORMAL);
|
|
1408
|
+
} catch (error) {
|
|
1409
|
+
return iteratorClose$2(iterator, THROW, error);
|
|
1410
|
+
}
|
|
1411
|
+
if (state.openIters) try {
|
|
1412
|
+
iteratorCloseAll(state.openIters, NORMAL);
|
|
1413
|
+
} catch (error) {
|
|
1414
|
+
return iteratorClose$2(iterator, THROW, error);
|
|
1415
|
+
}
|
|
1416
|
+
if (iterator) iteratorClose$2(iterator, NORMAL);
|
|
1417
|
+
return createIterResultObject(undefined, true);
|
|
1418
|
+
}
|
|
1419
|
+
});
|
|
1420
|
+
};
|
|
1421
|
+
|
|
1422
|
+
var WrapForValidIteratorPrototype = createIteratorProxyPrototype(true);
|
|
1423
|
+
var IteratorHelperPrototype = createIteratorProxyPrototype(false);
|
|
1424
|
+
|
|
1425
|
+
createNonEnumerableProperty$1(IteratorHelperPrototype, TO_STRING_TAG$2, 'Iterator Helper');
|
|
1426
|
+
|
|
1427
|
+
var iteratorCreateProxy = function (nextHandler, IS_ITERATOR, RETURN_HANDLER_RESULT) {
|
|
1428
|
+
var IteratorProxy = function Iterator(record, state) {
|
|
1429
|
+
if (state) {
|
|
1430
|
+
state.iterator = record.iterator;
|
|
1431
|
+
state.next = record.next;
|
|
1432
|
+
} else state = record;
|
|
1433
|
+
state.type = IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER;
|
|
1434
|
+
state.returnHandlerResult = !!RETURN_HANDLER_RESULT;
|
|
1435
|
+
state.nextHandler = nextHandler;
|
|
1436
|
+
state.counter = 0;
|
|
1437
|
+
state.done = false;
|
|
1438
|
+
setInternalState(this, state);
|
|
1439
|
+
};
|
|
1440
|
+
|
|
1441
|
+
IteratorProxy.prototype = IS_ITERATOR ? WrapForValidIteratorPrototype : IteratorHelperPrototype;
|
|
1442
|
+
|
|
1443
|
+
return IteratorProxy;
|
|
1444
|
+
};
|
|
1445
|
+
|
|
1446
|
+
var anObject$4 = anObject$b;
|
|
1447
|
+
var iteratorClose$1 = iteratorClose$4;
|
|
1448
|
+
|
|
1449
|
+
// call something on iterator step with safe closing on error
|
|
1450
|
+
var callWithSafeIterationClosing$1 = function (iterator, fn, value, ENTRIES) {
|
|
1451
|
+
try {
|
|
1452
|
+
return ENTRIES ? fn(anObject$4(value)[0], value[1]) : fn(value);
|
|
1453
|
+
} catch (error) {
|
|
1454
|
+
iteratorClose$1(iterator, 'throw', error);
|
|
1455
|
+
}
|
|
1456
|
+
};
|
|
1457
|
+
|
|
1458
|
+
// Should throw an error on invalid iterator
|
|
1459
|
+
// https://issues.chromium.org/issues/336839115
|
|
1460
|
+
var iteratorHelperThrowsOnInvalidIterator$1 = function (methodName, argument) {
|
|
1461
|
+
// eslint-disable-next-line es/no-iterator -- required for testing
|
|
1462
|
+
var method = typeof Iterator == 'function' && Iterator.prototype[methodName];
|
|
1463
|
+
if (method) try {
|
|
1464
|
+
method.call({ next: null }, argument).next();
|
|
1465
|
+
} catch (error) {
|
|
1466
|
+
return true;
|
|
1467
|
+
}
|
|
1468
|
+
};
|
|
1469
|
+
|
|
1470
|
+
var globalThis$5 = globalThis_1;
|
|
1471
|
+
|
|
1472
|
+
// https://github.com/tc39/ecma262/pull/3467
|
|
1473
|
+
var iteratorHelperWithoutClosingOnEarlyError$1 = function (METHOD_NAME, ExpectedError) {
|
|
1474
|
+
var Iterator = globalThis$5.Iterator;
|
|
1475
|
+
var IteratorPrototype = Iterator && Iterator.prototype;
|
|
1476
|
+
var method = IteratorPrototype && IteratorPrototype[METHOD_NAME];
|
|
1477
|
+
|
|
1478
|
+
var CLOSED = false;
|
|
1479
|
+
|
|
1480
|
+
if (method) try {
|
|
1481
|
+
method.call({
|
|
1482
|
+
next: function () { return { done: true }; },
|
|
1483
|
+
'return': function () { CLOSED = true; }
|
|
1484
|
+
}, -1);
|
|
1485
|
+
} catch (error) {
|
|
1486
|
+
// https://bugs.webkit.org/show_bug.cgi?id=291195
|
|
1487
|
+
if (!(error instanceof ExpectedError)) CLOSED = false;
|
|
1488
|
+
}
|
|
1489
|
+
|
|
1490
|
+
if (!CLOSED) return method;
|
|
1491
|
+
};
|
|
1492
|
+
|
|
1493
|
+
var $$2 = _export;
|
|
1494
|
+
var call$7 = functionCall;
|
|
1495
|
+
var aCallable = aCallable$2;
|
|
1496
|
+
var anObject$3 = anObject$b;
|
|
1497
|
+
var getIteratorDirect = getIteratorDirect$1;
|
|
1498
|
+
var createIteratorProxy = iteratorCreateProxy;
|
|
1499
|
+
var callWithSafeIterationClosing = callWithSafeIterationClosing$1;
|
|
1500
|
+
var iteratorClose = iteratorClose$4;
|
|
1501
|
+
var iteratorHelperThrowsOnInvalidIterator = iteratorHelperThrowsOnInvalidIterator$1;
|
|
1502
|
+
var iteratorHelperWithoutClosingOnEarlyError = iteratorHelperWithoutClosingOnEarlyError$1;
|
|
1503
|
+
|
|
1504
|
+
var MAP_WITHOUT_THROWING_ON_INVALID_ITERATOR = !iteratorHelperThrowsOnInvalidIterator('map', function () { /* empty */ });
|
|
1505
|
+
var mapWithoutClosingOnEarlyError = !MAP_WITHOUT_THROWING_ON_INVALID_ITERATOR
|
|
1506
|
+
&& iteratorHelperWithoutClosingOnEarlyError('map', TypeError);
|
|
1507
|
+
|
|
1508
|
+
var FORCED = MAP_WITHOUT_THROWING_ON_INVALID_ITERATOR || mapWithoutClosingOnEarlyError;
|
|
1509
|
+
|
|
1510
|
+
var IteratorProxy = createIteratorProxy(function () {
|
|
1511
|
+
var iterator = this.iterator;
|
|
1512
|
+
var result = anObject$3(call$7(this.next, iterator));
|
|
1513
|
+
var done = this.done = !!result.done;
|
|
1514
|
+
if (!done) return callWithSafeIterationClosing(iterator, this.mapper, [result.value, this.counter++], true);
|
|
1515
|
+
});
|
|
1516
|
+
|
|
1517
|
+
// `Iterator.prototype.map` method
|
|
1518
|
+
// https://tc39.es/ecma262/#sec-iterator.prototype.map
|
|
1519
|
+
$$2({ target: 'Iterator', proto: true, real: true, forced: FORCED }, {
|
|
1520
|
+
map: function map(mapper) {
|
|
1521
|
+
anObject$3(this);
|
|
1522
|
+
try {
|
|
1523
|
+
aCallable(mapper);
|
|
1524
|
+
} catch (error) {
|
|
1525
|
+
iteratorClose(this, 'throw', error);
|
|
1526
|
+
}
|
|
1527
|
+
|
|
1528
|
+
if (mapWithoutClosingOnEarlyError) return call$7(mapWithoutClosingOnEarlyError, this, mapper);
|
|
1529
|
+
|
|
1530
|
+
return new IteratorProxy(getIteratorDirect(this), {
|
|
1531
|
+
mapper: mapper
|
|
1532
|
+
});
|
|
1533
|
+
}
|
|
1534
|
+
});
|
|
1535
|
+
|
|
1536
|
+
var DESCRIPTORS = descriptors;
|
|
1026
1537
|
var uncurryThis$4 = functionUncurryThis;
|
|
1027
|
-
var call$
|
|
1028
|
-
var fails$
|
|
1029
|
-
var objectKeys
|
|
1538
|
+
var call$6 = functionCall;
|
|
1539
|
+
var fails$6 = fails$i;
|
|
1540
|
+
var objectKeys = objectKeys$2;
|
|
1030
1541
|
var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols;
|
|
1031
1542
|
var propertyIsEnumerableModule = objectPropertyIsEnumerable;
|
|
1032
|
-
var toObject$1 = toObject$
|
|
1543
|
+
var toObject$1 = toObject$4;
|
|
1033
1544
|
var IndexedObject = indexedObject;
|
|
1034
1545
|
|
|
1035
1546
|
// eslint-disable-next-line es/no-object-assign -- safe
|
|
@@ -1040,9 +1551,9 @@ var concat$1 = uncurryThis$4([].concat);
|
|
|
1040
1551
|
|
|
1041
1552
|
// `Object.assign` method
|
|
1042
1553
|
// https://tc39.es/ecma262/#sec-object.assign
|
|
1043
|
-
var objectAssign = !$assign || fails$
|
|
1554
|
+
var objectAssign = !$assign || fails$6(function () {
|
|
1044
1555
|
// should have correct order of operations (Edge bug)
|
|
1045
|
-
if (DESCRIPTORS
|
|
1556
|
+
if (DESCRIPTORS && $assign({ b: 1 }, $assign(defineProperty({}, 'a', {
|
|
1046
1557
|
enumerable: true,
|
|
1047
1558
|
get: function () {
|
|
1048
1559
|
defineProperty(this, 'b', {
|
|
@@ -1058,8 +1569,9 @@ var objectAssign = !$assign || fails$5(function () {
|
|
|
1058
1569
|
var symbol = Symbol('assign detection');
|
|
1059
1570
|
var alphabet = 'abcdefghijklmnopqrst';
|
|
1060
1571
|
A[symbol] = 7;
|
|
1572
|
+
// eslint-disable-next-line es/no-array-prototype-foreach -- safe
|
|
1061
1573
|
alphabet.split('').forEach(function (chr) { B[chr] = chr; });
|
|
1062
|
-
return $assign({}, A)[symbol] !== 7 || objectKeys
|
|
1574
|
+
return $assign({}, A)[symbol] !== 7 || objectKeys($assign({}, B)).join('') !== alphabet;
|
|
1063
1575
|
}) ? function assign(target, source) { // eslint-disable-line no-unused-vars -- required for `.length`
|
|
1064
1576
|
var T = toObject$1(target);
|
|
1065
1577
|
var argumentsLength = arguments.length;
|
|
@@ -1068,13 +1580,13 @@ var objectAssign = !$assign || fails$5(function () {
|
|
|
1068
1580
|
var propertyIsEnumerable = propertyIsEnumerableModule.f;
|
|
1069
1581
|
while (argumentsLength > index) {
|
|
1070
1582
|
var S = IndexedObject(arguments[index++]);
|
|
1071
|
-
var keys = getOwnPropertySymbols ? concat$1(objectKeys
|
|
1583
|
+
var keys = getOwnPropertySymbols ? concat$1(objectKeys(S), getOwnPropertySymbols(S)) : objectKeys(S);
|
|
1072
1584
|
var length = keys.length;
|
|
1073
1585
|
var j = 0;
|
|
1074
1586
|
var key;
|
|
1075
1587
|
while (length > j) {
|
|
1076
1588
|
key = keys[j++];
|
|
1077
|
-
if (!DESCRIPTORS
|
|
1589
|
+
if (!DESCRIPTORS || call$6(propertyIsEnumerable, S, key)) T[key] = S[key];
|
|
1078
1590
|
}
|
|
1079
1591
|
} return T;
|
|
1080
1592
|
} : $assign;
|
|
@@ -1103,6 +1615,8 @@ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
1103
1615
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
1104
1616
|
PERFORMANCE OF THIS SOFTWARE.
|
|
1105
1617
|
***************************************************************************** */
|
|
1618
|
+
/* global Reflect, Promise, SuppressedError, Symbol, Iterator */
|
|
1619
|
+
|
|
1106
1620
|
|
|
1107
1621
|
function __rest(s, e) {
|
|
1108
1622
|
var t = {};
|
|
@@ -1121,19 +1635,19 @@ typeof SuppressedError === "function" ? SuppressedError : function (error, suppr
|
|
|
1121
1635
|
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
1122
1636
|
};
|
|
1123
1637
|
|
|
1124
|
-
var wellKnownSymbol$3 = wellKnownSymbol$
|
|
1638
|
+
var wellKnownSymbol$3 = wellKnownSymbol$8;
|
|
1125
1639
|
|
|
1126
1640
|
var TO_STRING_TAG$1 = wellKnownSymbol$3('toStringTag');
|
|
1127
1641
|
var test = {};
|
|
1128
|
-
|
|
1642
|
+
// eslint-disable-next-line unicorn/no-immediate-mutation -- ES3 syntax limitation
|
|
1129
1643
|
test[TO_STRING_TAG$1] = 'z';
|
|
1130
1644
|
|
|
1131
1645
|
var toStringTagSupport = String(test) === '[object z]';
|
|
1132
1646
|
|
|
1133
1647
|
var TO_STRING_TAG_SUPPORT = toStringTagSupport;
|
|
1134
|
-
var isCallable$2 = isCallable$
|
|
1648
|
+
var isCallable$2 = isCallable$g;
|
|
1135
1649
|
var classofRaw = classofRaw$1;
|
|
1136
|
-
var wellKnownSymbol$2 = wellKnownSymbol$
|
|
1650
|
+
var wellKnownSymbol$2 = wellKnownSymbol$8;
|
|
1137
1651
|
|
|
1138
1652
|
var TO_STRING_TAG = wellKnownSymbol$2('toStringTag');
|
|
1139
1653
|
var $Object = Object;
|
|
@@ -1169,12 +1683,12 @@ var toString$3 = function (argument) {
|
|
|
1169
1683
|
return $String(argument);
|
|
1170
1684
|
};
|
|
1171
1685
|
|
|
1172
|
-
var anObject$
|
|
1686
|
+
var anObject$2 = anObject$b;
|
|
1173
1687
|
|
|
1174
1688
|
// `RegExp.prototype.flags` getter implementation
|
|
1175
1689
|
// https://tc39.es/ecma262/#sec-get-regexp.prototype.flags
|
|
1176
1690
|
var regexpFlags$1 = function () {
|
|
1177
|
-
var that = anObject$
|
|
1691
|
+
var that = anObject$2(this);
|
|
1178
1692
|
var result = '';
|
|
1179
1693
|
if (that.hasIndices) result += 'd';
|
|
1180
1694
|
if (that.global) result += 'g';
|
|
@@ -1187,13 +1701,13 @@ var regexpFlags$1 = function () {
|
|
|
1187
1701
|
return result;
|
|
1188
1702
|
};
|
|
1189
1703
|
|
|
1190
|
-
var fails$
|
|
1191
|
-
var globalThis$
|
|
1704
|
+
var fails$5 = fails$i;
|
|
1705
|
+
var globalThis$4 = globalThis_1;
|
|
1192
1706
|
|
|
1193
1707
|
// babel-minify and Closure Compiler transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError
|
|
1194
|
-
var $RegExp$2 = globalThis$
|
|
1708
|
+
var $RegExp$2 = globalThis$4.RegExp;
|
|
1195
1709
|
|
|
1196
|
-
var UNSUPPORTED_Y$1 = fails$
|
|
1710
|
+
var UNSUPPORTED_Y$1 = fails$5(function () {
|
|
1197
1711
|
var re = $RegExp$2('a', 'y');
|
|
1198
1712
|
re.lastIndex = 2;
|
|
1199
1713
|
return re.exec('abcd') !== null;
|
|
@@ -1201,11 +1715,11 @@ var UNSUPPORTED_Y$1 = fails$4(function () {
|
|
|
1201
1715
|
|
|
1202
1716
|
// UC Browser bug
|
|
1203
1717
|
// https://github.com/zloirock/core-js/issues/1008
|
|
1204
|
-
|
|
1718
|
+
UNSUPPORTED_Y$1 || fails$5(function () {
|
|
1205
1719
|
return !$RegExp$2('a', 'y').sticky;
|
|
1206
1720
|
});
|
|
1207
1721
|
|
|
1208
|
-
var BROKEN_CARET = UNSUPPORTED_Y$1 || fails$
|
|
1722
|
+
var BROKEN_CARET = UNSUPPORTED_Y$1 || fails$5(function () {
|
|
1209
1723
|
// https://bugzilla.mozilla.org/show_bug.cgi?id=773687
|
|
1210
1724
|
var re = $RegExp$2('^r', 'gy');
|
|
1211
1725
|
re.lastIndex = 2;
|
|
@@ -1213,141 +1727,26 @@ var BROKEN_CARET = UNSUPPORTED_Y$1 || fails$4(function () {
|
|
|
1213
1727
|
});
|
|
1214
1728
|
|
|
1215
1729
|
var regexpStickyHelpers = {
|
|
1216
|
-
BROKEN_CARET: BROKEN_CARET
|
|
1217
|
-
MISSED_STICKY: MISSED_STICKY,
|
|
1218
|
-
UNSUPPORTED_Y: UNSUPPORTED_Y$1
|
|
1219
|
-
};
|
|
1220
|
-
|
|
1221
|
-
var objectDefineProperties = {};
|
|
1222
|
-
|
|
1223
|
-
var DESCRIPTORS = descriptors;
|
|
1224
|
-
var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
|
|
1225
|
-
var definePropertyModule = objectDefineProperty;
|
|
1226
|
-
var anObject$3 = anObject$7;
|
|
1227
|
-
var toIndexedObject = toIndexedObject$4;
|
|
1228
|
-
var objectKeys = objectKeys$2;
|
|
1229
|
-
|
|
1230
|
-
// `Object.defineProperties` method
|
|
1231
|
-
// https://tc39.es/ecma262/#sec-object.defineproperties
|
|
1232
|
-
// eslint-disable-next-line es/no-object-defineproperties -- safe
|
|
1233
|
-
objectDefineProperties.f = DESCRIPTORS && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
|
|
1234
|
-
anObject$3(O);
|
|
1235
|
-
var props = toIndexedObject(Properties);
|
|
1236
|
-
var keys = objectKeys(Properties);
|
|
1237
|
-
var length = keys.length;
|
|
1238
|
-
var index = 0;
|
|
1239
|
-
var key;
|
|
1240
|
-
while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);
|
|
1241
|
-
return O;
|
|
1242
|
-
};
|
|
1243
|
-
|
|
1244
|
-
var getBuiltIn = getBuiltIn$3;
|
|
1245
|
-
|
|
1246
|
-
var html$1 = getBuiltIn('document', 'documentElement');
|
|
1247
|
-
|
|
1248
|
-
/* global ActiveXObject -- old IE, WSH */
|
|
1249
|
-
var anObject$2 = anObject$7;
|
|
1250
|
-
var definePropertiesModule = objectDefineProperties;
|
|
1251
|
-
var enumBugKeys = enumBugKeys$3;
|
|
1252
|
-
var hiddenKeys = hiddenKeys$4;
|
|
1253
|
-
var html = html$1;
|
|
1254
|
-
var documentCreateElement = documentCreateElement$1;
|
|
1255
|
-
var sharedKey = sharedKey$2;
|
|
1730
|
+
BROKEN_CARET: BROKEN_CARET};
|
|
1256
1731
|
|
|
1257
|
-
var
|
|
1258
|
-
var
|
|
1259
|
-
var PROTOTYPE = 'prototype';
|
|
1260
|
-
var SCRIPT = 'script';
|
|
1261
|
-
var IE_PROTO = sharedKey('IE_PROTO');
|
|
1262
|
-
|
|
1263
|
-
var EmptyConstructor = function () { /* empty */ };
|
|
1264
|
-
|
|
1265
|
-
var scriptTag = function (content) {
|
|
1266
|
-
return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
|
|
1267
|
-
};
|
|
1268
|
-
|
|
1269
|
-
// Create object with fake `null` prototype: use ActiveX Object with cleared prototype
|
|
1270
|
-
var NullProtoObjectViaActiveX = function (activeXDocument) {
|
|
1271
|
-
activeXDocument.write(scriptTag(''));
|
|
1272
|
-
activeXDocument.close();
|
|
1273
|
-
var temp = activeXDocument.parentWindow.Object;
|
|
1274
|
-
// eslint-disable-next-line no-useless-assignment -- avoid memory leak
|
|
1275
|
-
activeXDocument = null;
|
|
1276
|
-
return temp;
|
|
1277
|
-
};
|
|
1278
|
-
|
|
1279
|
-
// Create object with fake `null` prototype: use iframe Object with cleared prototype
|
|
1280
|
-
var NullProtoObjectViaIFrame = function () {
|
|
1281
|
-
// Thrash, waste and sodomy: IE GC bug
|
|
1282
|
-
var iframe = documentCreateElement('iframe');
|
|
1283
|
-
var JS = 'java' + SCRIPT + ':';
|
|
1284
|
-
var iframeDocument;
|
|
1285
|
-
iframe.style.display = 'none';
|
|
1286
|
-
html.appendChild(iframe);
|
|
1287
|
-
// https://github.com/zloirock/core-js/issues/475
|
|
1288
|
-
iframe.src = String(JS);
|
|
1289
|
-
iframeDocument = iframe.contentWindow.document;
|
|
1290
|
-
iframeDocument.open();
|
|
1291
|
-
iframeDocument.write(scriptTag('document.F=Object'));
|
|
1292
|
-
iframeDocument.close();
|
|
1293
|
-
return iframeDocument.F;
|
|
1294
|
-
};
|
|
1295
|
-
|
|
1296
|
-
// Check for document.domain and active x support
|
|
1297
|
-
// No need to use active x approach when document.domain is not set
|
|
1298
|
-
// see https://github.com/es-shims/es5-shim/issues/150
|
|
1299
|
-
// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
|
|
1300
|
-
// avoid IE GC bug
|
|
1301
|
-
var activeXDocument;
|
|
1302
|
-
var NullProtoObject = function () {
|
|
1303
|
-
try {
|
|
1304
|
-
activeXDocument = new ActiveXObject('htmlfile');
|
|
1305
|
-
} catch (error) { /* ignore */ }
|
|
1306
|
-
NullProtoObject = typeof document != 'undefined'
|
|
1307
|
-
? document.domain && activeXDocument
|
|
1308
|
-
? NullProtoObjectViaActiveX(activeXDocument) // old IE
|
|
1309
|
-
: NullProtoObjectViaIFrame()
|
|
1310
|
-
: NullProtoObjectViaActiveX(activeXDocument); // WSH
|
|
1311
|
-
var length = enumBugKeys.length;
|
|
1312
|
-
while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];
|
|
1313
|
-
return NullProtoObject();
|
|
1314
|
-
};
|
|
1315
|
-
|
|
1316
|
-
hiddenKeys[IE_PROTO] = true;
|
|
1317
|
-
|
|
1318
|
-
// `Object.create` method
|
|
1319
|
-
// https://tc39.es/ecma262/#sec-object.create
|
|
1320
|
-
// eslint-disable-next-line es/no-object-create -- safe
|
|
1321
|
-
var objectCreate = Object.create || function create(O, Properties) {
|
|
1322
|
-
var result;
|
|
1323
|
-
if (O !== null) {
|
|
1324
|
-
EmptyConstructor[PROTOTYPE] = anObject$2(O);
|
|
1325
|
-
result = new EmptyConstructor();
|
|
1326
|
-
EmptyConstructor[PROTOTYPE] = null;
|
|
1327
|
-
// add "__proto__" for Object.getPrototypeOf polyfill
|
|
1328
|
-
result[IE_PROTO] = O;
|
|
1329
|
-
} else result = NullProtoObject();
|
|
1330
|
-
return Properties === undefined ? result : definePropertiesModule.f(result, Properties);
|
|
1331
|
-
};
|
|
1332
|
-
|
|
1333
|
-
var fails$3 = fails$e;
|
|
1334
|
-
var globalThis$2 = globalThis_1;
|
|
1732
|
+
var fails$4 = fails$i;
|
|
1733
|
+
var globalThis$3 = globalThis_1;
|
|
1335
1734
|
|
|
1336
1735
|
// babel-minify and Closure Compiler transpiles RegExp('.', 's') -> /./s and it causes SyntaxError
|
|
1337
|
-
var $RegExp$1 = globalThis$
|
|
1736
|
+
var $RegExp$1 = globalThis$3.RegExp;
|
|
1338
1737
|
|
|
1339
|
-
var regexpUnsupportedDotAll = fails$
|
|
1738
|
+
var regexpUnsupportedDotAll = fails$4(function () {
|
|
1340
1739
|
var re = $RegExp$1('.', 's');
|
|
1341
1740
|
return !(re.dotAll && re.test('\n') && re.flags === 's');
|
|
1342
1741
|
});
|
|
1343
1742
|
|
|
1344
|
-
var fails$
|
|
1345
|
-
var globalThis$
|
|
1743
|
+
var fails$3 = fails$i;
|
|
1744
|
+
var globalThis$2 = globalThis_1;
|
|
1346
1745
|
|
|
1347
1746
|
// babel-minify and Closure Compiler transpiles RegExp('(?<a>b)', 'g') -> /(?<a>b)/g and it causes SyntaxError
|
|
1348
|
-
var $RegExp = globalThis$
|
|
1747
|
+
var $RegExp = globalThis$2.RegExp;
|
|
1349
1748
|
|
|
1350
|
-
var regexpUnsupportedNcg = fails$
|
|
1749
|
+
var regexpUnsupportedNcg = fails$3(function () {
|
|
1351
1750
|
var re = $RegExp('(?<a>b)', 'g');
|
|
1352
1751
|
return re.exec('b').groups.a !== 'b' ||
|
|
1353
1752
|
'b'.replace(re, '$<a>c') !== 'bc';
|
|
@@ -1355,7 +1754,7 @@ var regexpUnsupportedNcg = fails$2(function () {
|
|
|
1355
1754
|
|
|
1356
1755
|
/* eslint-disable regexp/no-empty-capturing-group, regexp/no-empty-group, regexp/no-lazy-ends -- testing */
|
|
1357
1756
|
/* eslint-disable regexp/no-useless-quantifier -- testing */
|
|
1358
|
-
var call$
|
|
1757
|
+
var call$5 = functionCall;
|
|
1359
1758
|
var uncurryThis$3 = functionUncurryThis;
|
|
1360
1759
|
var toString$2 = toString$3;
|
|
1361
1760
|
var regexpFlags = regexpFlags$1;
|
|
@@ -1377,8 +1776,8 @@ var stringSlice$3 = uncurryThis$3(''.slice);
|
|
|
1377
1776
|
var UPDATES_LAST_INDEX_WRONG = (function () {
|
|
1378
1777
|
var re1 = /a/;
|
|
1379
1778
|
var re2 = /b*/g;
|
|
1380
|
-
call$
|
|
1381
|
-
call$
|
|
1779
|
+
call$5(nativeExec, re1, 'a');
|
|
1780
|
+
call$5(nativeExec, re2, 'a');
|
|
1382
1781
|
return re1.lastIndex !== 0 || re2.lastIndex !== 0;
|
|
1383
1782
|
})();
|
|
1384
1783
|
|
|
@@ -1399,14 +1798,14 @@ if (PATCH) {
|
|
|
1399
1798
|
|
|
1400
1799
|
if (raw) {
|
|
1401
1800
|
raw.lastIndex = re.lastIndex;
|
|
1402
|
-
result = call$
|
|
1801
|
+
result = call$5(patchedExec, raw, str);
|
|
1403
1802
|
re.lastIndex = raw.lastIndex;
|
|
1404
1803
|
return result;
|
|
1405
1804
|
}
|
|
1406
1805
|
|
|
1407
1806
|
var groups = state.groups;
|
|
1408
1807
|
var sticky = UNSUPPORTED_Y && re.sticky;
|
|
1409
|
-
var flags = call$
|
|
1808
|
+
var flags = call$5(regexpFlags, re);
|
|
1410
1809
|
var source = re.source;
|
|
1411
1810
|
var charsAdded = 0;
|
|
1412
1811
|
var strCopy = str;
|
|
@@ -1434,7 +1833,7 @@ if (PATCH) {
|
|
|
1434
1833
|
}
|
|
1435
1834
|
if (UPDATES_LAST_INDEX_WRONG) lastIndex = re.lastIndex;
|
|
1436
1835
|
|
|
1437
|
-
match = call$
|
|
1836
|
+
match = call$5(nativeExec, sticky ? reCopy : re, strCopy);
|
|
1438
1837
|
|
|
1439
1838
|
if (sticky) {
|
|
1440
1839
|
if (match) {
|
|
@@ -1449,7 +1848,7 @@ if (PATCH) {
|
|
|
1449
1848
|
if (NPCG_INCLUDED && match && match.length > 1) {
|
|
1450
1849
|
// Fix browsers whose `exec` methods don't consistently return `undefined`
|
|
1451
1850
|
// for NPCG, like IE8. NOTE: This doesn't work for /(.?)?/
|
|
1452
|
-
call$
|
|
1851
|
+
call$5(nativeReplace, match[0], reCopy, function () {
|
|
1453
1852
|
for (i = 1; i < arguments.length - 2; i++) {
|
|
1454
1853
|
if (arguments[i] === undefined) match[i] = undefined;
|
|
1455
1854
|
}
|
|
@@ -1483,36 +1882,37 @@ var NATIVE_BIND = functionBindNative;
|
|
|
1483
1882
|
|
|
1484
1883
|
var FunctionPrototype = Function.prototype;
|
|
1485
1884
|
var apply$1 = FunctionPrototype.apply;
|
|
1486
|
-
var call$
|
|
1885
|
+
var call$4 = FunctionPrototype.call;
|
|
1487
1886
|
|
|
1488
|
-
// eslint-disable-next-line es/no-reflect -- safe
|
|
1489
|
-
var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call$
|
|
1490
|
-
return call$
|
|
1887
|
+
// eslint-disable-next-line es/no-function-prototype-bind, es/no-reflect -- safe
|
|
1888
|
+
var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call$4.bind(apply$1) : function () {
|
|
1889
|
+
return call$4.apply(apply$1, arguments);
|
|
1491
1890
|
});
|
|
1492
1891
|
|
|
1493
1892
|
// TODO: Remove from `core-js@4` since it's moved to entry points
|
|
1494
1893
|
|
|
1495
|
-
var call$
|
|
1496
|
-
var defineBuiltIn = defineBuiltIn$
|
|
1894
|
+
var call$3 = functionCall;
|
|
1895
|
+
var defineBuiltIn = defineBuiltIn$4;
|
|
1497
1896
|
var regexpExec$1 = regexpExec$2;
|
|
1498
|
-
var fails$
|
|
1499
|
-
var wellKnownSymbol$1 = wellKnownSymbol$
|
|
1500
|
-
var createNonEnumerableProperty = createNonEnumerableProperty$
|
|
1897
|
+
var fails$2 = fails$i;
|
|
1898
|
+
var wellKnownSymbol$1 = wellKnownSymbol$8;
|
|
1899
|
+
var createNonEnumerableProperty = createNonEnumerableProperty$4;
|
|
1501
1900
|
|
|
1502
1901
|
var SPECIES = wellKnownSymbol$1('species');
|
|
1503
|
-
var RegExpPrototype = RegExp.prototype;
|
|
1902
|
+
var RegExpPrototype$1 = RegExp.prototype;
|
|
1504
1903
|
|
|
1505
1904
|
var fixRegexpWellKnownSymbolLogic = function (KEY, exec, FORCED, SHAM) {
|
|
1506
1905
|
var SYMBOL = wellKnownSymbol$1(KEY);
|
|
1507
1906
|
|
|
1508
|
-
var DELEGATES_TO_SYMBOL = !fails$
|
|
1907
|
+
var DELEGATES_TO_SYMBOL = !fails$2(function () {
|
|
1509
1908
|
// String methods call symbol-named RegExp methods
|
|
1510
1909
|
var O = {};
|
|
1910
|
+
// eslint-disable-next-line unicorn/no-immediate-mutation -- ES3 syntax limitation
|
|
1511
1911
|
O[SYMBOL] = function () { return 7; };
|
|
1512
1912
|
return ''[KEY](O) !== 7;
|
|
1513
1913
|
});
|
|
1514
1914
|
|
|
1515
|
-
var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails$
|
|
1915
|
+
var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails$2(function () {
|
|
1516
1916
|
// Symbol-named RegExp methods call .exec
|
|
1517
1917
|
var execCalled = false;
|
|
1518
1918
|
var re = /a/;
|
|
@@ -1521,12 +1921,13 @@ var fixRegexpWellKnownSymbolLogic = function (KEY, exec, FORCED, SHAM) {
|
|
|
1521
1921
|
// We can't use real regex here since it causes deoptimization
|
|
1522
1922
|
// and serious performance degradation in V8
|
|
1523
1923
|
// https://github.com/zloirock/core-js/issues/306
|
|
1524
|
-
re = {};
|
|
1525
1924
|
// RegExp[@@split] doesn't call the regex's exec method, but first creates
|
|
1526
1925
|
// a new one. We need to return the patched regex when creating the new one.
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1926
|
+
var constructor = {};
|
|
1927
|
+
// eslint-disable-next-line unicorn/no-immediate-mutation -- ES3 syntax limitation
|
|
1928
|
+
constructor[SPECIES] = function () { return re; };
|
|
1929
|
+
re = { constructor: constructor, flags: '' };
|
|
1930
|
+
// eslint-disable-next-line unicorn/no-immediate-mutation -- ES3 syntax limitation
|
|
1530
1931
|
re[SYMBOL] = /./[SYMBOL];
|
|
1531
1932
|
}
|
|
1532
1933
|
|
|
@@ -1547,23 +1948,23 @@ var fixRegexpWellKnownSymbolLogic = function (KEY, exec, FORCED, SHAM) {
|
|
|
1547
1948
|
var nativeRegExpMethod = /./[SYMBOL];
|
|
1548
1949
|
var methods = exec(SYMBOL, ''[KEY], function (nativeMethod, regexp, str, arg2, forceStringMethod) {
|
|
1549
1950
|
var $exec = regexp.exec;
|
|
1550
|
-
if ($exec === regexpExec$1 || $exec === RegExpPrototype.exec) {
|
|
1951
|
+
if ($exec === regexpExec$1 || $exec === RegExpPrototype$1.exec) {
|
|
1551
1952
|
if (DELEGATES_TO_SYMBOL && !forceStringMethod) {
|
|
1552
1953
|
// The native String method already delegates to @@method (this
|
|
1553
1954
|
// polyfilled function), leasing to infinite recursion.
|
|
1554
1955
|
// We avoid it by directly calling the native @@method method.
|
|
1555
|
-
return { done: true, value: call$
|
|
1956
|
+
return { done: true, value: call$3(nativeRegExpMethod, regexp, str, arg2) };
|
|
1556
1957
|
}
|
|
1557
|
-
return { done: true, value: call$
|
|
1958
|
+
return { done: true, value: call$3(nativeMethod, str, regexp, arg2) };
|
|
1558
1959
|
}
|
|
1559
1960
|
return { done: false };
|
|
1560
1961
|
});
|
|
1561
1962
|
|
|
1562
1963
|
defineBuiltIn(String.prototype, KEY, methods[0]);
|
|
1563
|
-
defineBuiltIn(RegExpPrototype, SYMBOL, methods[1]);
|
|
1964
|
+
defineBuiltIn(RegExpPrototype$1, SYMBOL, methods[1]);
|
|
1564
1965
|
}
|
|
1565
1966
|
|
|
1566
|
-
if (SHAM) createNonEnumerableProperty(RegExpPrototype[SYMBOL], 'sham', true);
|
|
1967
|
+
if (SHAM) createNonEnumerableProperty(RegExpPrototype$1[SYMBOL], 'sham', true);
|
|
1567
1968
|
};
|
|
1568
1969
|
|
|
1569
1970
|
var uncurryThis$2 = functionUncurryThis;
|
|
@@ -1595,9 +1996,6 @@ var createMethod = function (CONVERT_TO_STRING) {
|
|
|
1595
1996
|
};
|
|
1596
1997
|
|
|
1597
1998
|
var stringMultibyte = {
|
|
1598
|
-
// `String.prototype.codePointAt` method
|
|
1599
|
-
// https://tc39.es/ecma262/#sec-string.prototype.codepointat
|
|
1600
|
-
codeAt: createMethod(false),
|
|
1601
1999
|
// `String.prototype.at` method
|
|
1602
2000
|
// https://github.com/mathiasbynens/String.prototype.at
|
|
1603
2001
|
charAt: createMethod(true)
|
|
@@ -1612,7 +2010,7 @@ var advanceStringIndex$1 = function (S, index, unicode) {
|
|
|
1612
2010
|
};
|
|
1613
2011
|
|
|
1614
2012
|
var uncurryThis$1 = functionUncurryThis;
|
|
1615
|
-
var toObject = toObject$
|
|
2013
|
+
var toObject = toObject$4;
|
|
1616
2014
|
|
|
1617
2015
|
var floor = Math.floor;
|
|
1618
2016
|
var charAt = uncurryThis$1(''.charAt);
|
|
@@ -1657,9 +2055,72 @@ var getSubstitution$1 = function (matched, str, position, captures, namedCapture
|
|
|
1657
2055
|
});
|
|
1658
2056
|
};
|
|
1659
2057
|
|
|
2058
|
+
var globalThis$1 = globalThis_1;
|
|
2059
|
+
var fails$1 = fails$i;
|
|
2060
|
+
|
|
2061
|
+
// babel-minify and Closure Compiler transpiles RegExp('.', 'd') -> /./d and it causes SyntaxError
|
|
2062
|
+
var RegExp$1 = globalThis$1.RegExp;
|
|
2063
|
+
|
|
2064
|
+
var FLAGS_GETTER_IS_CORRECT = !fails$1(function () {
|
|
2065
|
+
var INDICES_SUPPORT = true;
|
|
2066
|
+
try {
|
|
2067
|
+
RegExp$1('.', 'd');
|
|
2068
|
+
} catch (error) {
|
|
2069
|
+
INDICES_SUPPORT = false;
|
|
2070
|
+
}
|
|
2071
|
+
|
|
2072
|
+
var O = {};
|
|
2073
|
+
// modern V8 bug
|
|
2074
|
+
var calls = '';
|
|
2075
|
+
var expected = INDICES_SUPPORT ? 'dgimsy' : 'gimsy';
|
|
2076
|
+
|
|
2077
|
+
var addGetter = function (key, chr) {
|
|
2078
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
2079
|
+
Object.defineProperty(O, key, { get: function () {
|
|
2080
|
+
calls += chr;
|
|
2081
|
+
return true;
|
|
2082
|
+
} });
|
|
2083
|
+
};
|
|
2084
|
+
|
|
2085
|
+
var pairs = {
|
|
2086
|
+
dotAll: 's',
|
|
2087
|
+
global: 'g',
|
|
2088
|
+
ignoreCase: 'i',
|
|
2089
|
+
multiline: 'm',
|
|
2090
|
+
sticky: 'y'
|
|
2091
|
+
};
|
|
2092
|
+
|
|
2093
|
+
if (INDICES_SUPPORT) pairs.hasIndices = 'd';
|
|
2094
|
+
|
|
2095
|
+
for (var key in pairs) addGetter(key, pairs[key]);
|
|
2096
|
+
|
|
2097
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
2098
|
+
var result = Object.getOwnPropertyDescriptor(RegExp$1.prototype, 'flags').get.call(O);
|
|
2099
|
+
|
|
2100
|
+
return result !== expected || calls !== expected;
|
|
2101
|
+
});
|
|
2102
|
+
|
|
2103
|
+
var regexpFlagsDetection = { correct: FLAGS_GETTER_IS_CORRECT };
|
|
2104
|
+
|
|
2105
|
+
var call$2 = functionCall;
|
|
2106
|
+
var hasOwn = hasOwnProperty_1;
|
|
2107
|
+
var isPrototypeOf = objectIsPrototypeOf;
|
|
2108
|
+
var regExpFlagsDetection = regexpFlagsDetection;
|
|
2109
|
+
var regExpFlagsGetterImplementation = regexpFlags$1;
|
|
2110
|
+
|
|
2111
|
+
var RegExpPrototype = RegExp.prototype;
|
|
2112
|
+
|
|
2113
|
+
var regexpGetFlags = regExpFlagsDetection.correct ? function (it) {
|
|
2114
|
+
return it.flags;
|
|
2115
|
+
} : function (it) {
|
|
2116
|
+
return (!regExpFlagsDetection.correct && isPrototypeOf(RegExpPrototype, it) && !hasOwn(it, 'flags'))
|
|
2117
|
+
? call$2(regExpFlagsGetterImplementation, it)
|
|
2118
|
+
: it.flags;
|
|
2119
|
+
};
|
|
2120
|
+
|
|
1660
2121
|
var call$1 = functionCall;
|
|
1661
|
-
var anObject$1 = anObject$
|
|
1662
|
-
var isCallable$1 = isCallable$
|
|
2122
|
+
var anObject$1 = anObject$b;
|
|
2123
|
+
var isCallable$1 = isCallable$g;
|
|
1663
2124
|
var classof = classofRaw$1;
|
|
1664
2125
|
var regexpExec = regexpExec$2;
|
|
1665
2126
|
|
|
@@ -1682,19 +2143,20 @@ var apply = functionApply;
|
|
|
1682
2143
|
var call = functionCall;
|
|
1683
2144
|
var uncurryThis = functionUncurryThis;
|
|
1684
2145
|
var fixRegExpWellKnownSymbolLogic = fixRegexpWellKnownSymbolLogic;
|
|
1685
|
-
var fails = fails$
|
|
1686
|
-
var anObject = anObject$
|
|
1687
|
-
var isCallable = isCallable$
|
|
1688
|
-
var
|
|
2146
|
+
var fails = fails$i;
|
|
2147
|
+
var anObject = anObject$b;
|
|
2148
|
+
var isCallable = isCallable$g;
|
|
2149
|
+
var isObject = isObject$7;
|
|
1689
2150
|
var toIntegerOrInfinity = toIntegerOrInfinity$4;
|
|
1690
2151
|
var toLength = toLength$2;
|
|
1691
2152
|
var toString = toString$3;
|
|
1692
2153
|
var requireObjectCoercible = requireObjectCoercible$4;
|
|
1693
2154
|
var advanceStringIndex = advanceStringIndex$1;
|
|
1694
|
-
var getMethod = getMethod$
|
|
2155
|
+
var getMethod = getMethod$4;
|
|
1695
2156
|
var getSubstitution = getSubstitution$1;
|
|
2157
|
+
var getRegExpFlags = regexpGetFlags;
|
|
1696
2158
|
var regExpExec = regexpExecAbstract;
|
|
1697
|
-
var wellKnownSymbol = wellKnownSymbol$
|
|
2159
|
+
var wellKnownSymbol = wellKnownSymbol$8;
|
|
1698
2160
|
|
|
1699
2161
|
var REPLACE = wellKnownSymbol('replace');
|
|
1700
2162
|
var max = Math.max;
|
|
@@ -1743,7 +2205,7 @@ fixRegExpWellKnownSymbolLogic('replace', function (_, nativeReplace, maybeCallNa
|
|
|
1743
2205
|
// https://tc39.es/ecma262/#sec-string.prototype.replace
|
|
1744
2206
|
function replace(searchValue, replaceValue) {
|
|
1745
2207
|
var O = requireObjectCoercible(this);
|
|
1746
|
-
var replacer =
|
|
2208
|
+
var replacer = isObject(searchValue) ? getMethod(searchValue, REPLACE) : undefined;
|
|
1747
2209
|
return replacer
|
|
1748
2210
|
? call(replacer, searchValue, O, replaceValue)
|
|
1749
2211
|
: call(nativeReplace, toString(O), searchValue, replaceValue);
|
|
@@ -1766,10 +2228,11 @@ fixRegExpWellKnownSymbolLogic('replace', function (_, nativeReplace, maybeCallNa
|
|
|
1766
2228
|
var functionalReplace = isCallable(replaceValue);
|
|
1767
2229
|
if (!functionalReplace) replaceValue = toString(replaceValue);
|
|
1768
2230
|
|
|
1769
|
-
var
|
|
2231
|
+
var flags = toString(getRegExpFlags(rx));
|
|
2232
|
+
var global = stringIndexOf(flags, 'g') !== -1;
|
|
1770
2233
|
var fullUnicode;
|
|
1771
2234
|
if (global) {
|
|
1772
|
-
fullUnicode =
|
|
2235
|
+
fullUnicode = stringIndexOf(flags, 'u') !== -1;
|
|
1773
2236
|
rx.lastIndex = 0;
|
|
1774
2237
|
}
|
|
1775
2238
|
|
|
@@ -1821,7 +2284,7 @@ fixRegExpWellKnownSymbolLogic('replace', function (_, nativeReplace, maybeCallNa
|
|
|
1821
2284
|
}, !REPLACE_SUPPORTS_NAMED_GROUPS || !REPLACE_KEEPS_$0 || REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE);
|
|
1822
2285
|
|
|
1823
2286
|
const tokenToInteger = token => Number(token.replace('px', ''));
|
|
1824
|
-
const Option = /*#__PURE__*/styled__default
|
|
2287
|
+
const Option = /*#__PURE__*/styled__default.default.button.withConfig({
|
|
1825
2288
|
displayName: "atoms-segmented-controlstyles__Option",
|
|
1826
2289
|
componentId: "sc-1lpqq2u-0"
|
|
1827
2290
|
})(["background-color:", ";border:", " solid ", ";padding:", ";cursor:pointer;&:first-of-type{border-top-left-radius:", ";border-bottom-left-radius:", ";}&:last-of-type{border-top-right-radius:", ";border-bottom-right-radius:", ";}", " *{cursor:pointer;}", ";"], ({
|
|
@@ -1854,7 +2317,7 @@ const Option = /*#__PURE__*/styled__default["default"].button.withConfig({
|
|
|
1854
2317
|
}) => theme.components.segmentControl.border.color.disabled, ({
|
|
1855
2318
|
theme
|
|
1856
2319
|
}) => theme.components.segmentControl.container.color.disabled));
|
|
1857
|
-
const SegmentedControlContainer = /*#__PURE__*/styled__default
|
|
2320
|
+
const SegmentedControlContainer = /*#__PURE__*/styled__default.default.div.withConfig({
|
|
1858
2321
|
displayName: "atoms-segmented-controlstyles__SegmentedControlContainer",
|
|
1859
2322
|
componentId: "sc-1lpqq2u-1"
|
|
1860
2323
|
})(["display:flex;flex-direction:column;gap:", ";", ";@media only screen and (max-width:", "px){button{flex:1;}}"], ({
|
|
@@ -1862,7 +2325,7 @@ const SegmentedControlContainer = /*#__PURE__*/styled__default["default"].div.wi
|
|
|
1862
2325
|
}) => theme.tokens.padding.XS, ({
|
|
1863
2326
|
$fullWidth
|
|
1864
2327
|
}) => $fullWidth && styled.css(["button{flex:1;}"]), frontendFoundations.ScreenSizes.SM.max);
|
|
1865
|
-
const SegmentedControlWrapper = /*#__PURE__*/styled__default
|
|
2328
|
+
const SegmentedControlWrapper = /*#__PURE__*/styled__default.default.div.withConfig({
|
|
1866
2329
|
displayName: "atoms-segmented-controlstyles__SegmentedControlWrapper",
|
|
1867
2330
|
componentId: "sc-1lpqq2u-2"
|
|
1868
2331
|
})(["box-shadow:", ";display:flex;flex-direction:row;gap:", ";"], ({
|
|
@@ -1874,7 +2337,7 @@ const SegmentedControlWrapper = /*#__PURE__*/styled__default["default"].div.with
|
|
|
1874
2337
|
}) => shadow.lvl0, ({
|
|
1875
2338
|
theme
|
|
1876
2339
|
}) => theme.components.segmentControl.gap);
|
|
1877
|
-
const OptionLabel = /*#__PURE__*/styled__default
|
|
2340
|
+
const OptionLabel = /*#__PURE__*/styled__default.default.label.withConfig({
|
|
1878
2341
|
displayName: "atoms-segmented-controlstyles__OptionLabel",
|
|
1879
2342
|
componentId: "sc-1lpqq2u-3"
|
|
1880
2343
|
})(["color:", ";font-size:", ";font-weight:", ";letter-spacing:", ";line-height:", ";text-decoration:", ";text-indent:", ";text-transform:", ";", ";"], ({
|
|
@@ -1899,7 +2362,7 @@ const OptionLabel = /*#__PURE__*/styled__default["default"].label.withConfig({
|
|
|
1899
2362
|
}) => $disabled && styled.css(["color:", ";"], ({
|
|
1900
2363
|
theme
|
|
1901
2364
|
}) => theme.components.segmentControl.text.color.disabled));
|
|
1902
|
-
const LabelError = /*#__PURE__*/styled__default
|
|
2365
|
+
const LabelError = /*#__PURE__*/styled__default.default.label.withConfig({
|
|
1903
2366
|
displayName: "atoms-segmented-controlstyles__LabelError",
|
|
1904
2367
|
componentId: "sc-1lpqq2u-4"
|
|
1905
2368
|
})(["color:", ";font-size:", ";font-weight:700;letter-spacing:", ";line-height:", ";text-decoration:", ";text-indent:", ";text-transform:", ";"], ({
|
|
@@ -1939,6 +2402,9 @@ const SegmentedControl = /*#__PURE__*/react.forwardRef((_a, ref) => {
|
|
|
1939
2402
|
children: "Two options at minimum are required."
|
|
1940
2403
|
});
|
|
1941
2404
|
return options.map(option => jsxRuntime.jsx(Option, Object.assign({
|
|
2405
|
+
role: "radio",
|
|
2406
|
+
"aria-checked": option.value === value,
|
|
2407
|
+
"aria-disabled": option.disabled,
|
|
1942
2408
|
"data-testid": `segmentedcontrol-option-${option.value}${option.value === value ? '-active' : ''}`,
|
|
1943
2409
|
onClick: () => {
|
|
1944
2410
|
if (!option.disabled) {
|
|
@@ -1959,6 +2425,7 @@ const SegmentedControl = /*#__PURE__*/react.forwardRef((_a, ref) => {
|
|
|
1959
2425
|
}), `segmentedcontrol-option-${option.value}`));
|
|
1960
2426
|
};
|
|
1961
2427
|
return jsxRuntime.jsxs(SegmentedControlContainer, Object.assign({
|
|
2428
|
+
role: "radiogroup",
|
|
1962
2429
|
id: id,
|
|
1963
2430
|
"data-testid": dataTestId,
|
|
1964
2431
|
"$fullWidth": fullWidth,
|
|
@@ -1969,6 +2436,7 @@ const SegmentedControl = /*#__PURE__*/react.forwardRef((_a, ref) => {
|
|
|
1969
2436
|
onFocus: onFocus,
|
|
1970
2437
|
children: renderOptions()
|
|
1971
2438
|
}), errorMessage && jsxRuntime.jsx(LabelError, {
|
|
2439
|
+
role: 'alert',
|
|
1972
2440
|
"data-testid": `${dataTestId}-error`,
|
|
1973
2441
|
children: errorMessage
|
|
1974
2442
|
})]
|