@ninetailed/experience.js-plugin-google-analytics 3.0.0-beta.32 → 3.0.0-beta.34
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/NinetailedGoogleAnalyticsPlugin.d.ts +14 -0
- package/index.cjs +1481 -346
- package/index.d.ts +2 -2
- package/index.js +1481 -345
- package/package.json +4 -5
- package/lib/google-analytics.d.ts +0 -8
package/index.cjs
CHANGED
|
@@ -2,12 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var googleAnalytics = require('@analytics/google-analytics');
|
|
6
5
|
var template = require('lodash/template');
|
|
6
|
+
var experience_jsPluginAnalytics = require('@ninetailed/experience.js-plugin-analytics');
|
|
7
7
|
|
|
8
8
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
9
9
|
|
|
10
|
-
var googleAnalytics__default = /*#__PURE__*/_interopDefaultLegacy(googleAnalytics);
|
|
11
10
|
var template__default = /*#__PURE__*/_interopDefaultLegacy(template);
|
|
12
11
|
|
|
13
12
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
@@ -17,7 +16,7 @@ var check = function (it) {
|
|
|
17
16
|
};
|
|
18
17
|
|
|
19
18
|
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
|
|
20
|
-
var global$
|
|
19
|
+
var global$i =
|
|
21
20
|
// eslint-disable-next-line es/no-global-this -- safe
|
|
22
21
|
check(typeof globalThis == 'object' && globalThis) ||
|
|
23
22
|
check(typeof window == 'object' && window) ||
|
|
@@ -29,7 +28,7 @@ var global$a =
|
|
|
29
28
|
|
|
30
29
|
var objectGetOwnPropertyDescriptor = {};
|
|
31
30
|
|
|
32
|
-
var fails$
|
|
31
|
+
var fails$a = function (exec) {
|
|
33
32
|
try {
|
|
34
33
|
return !!exec();
|
|
35
34
|
} catch (error) {
|
|
@@ -37,44 +36,44 @@ var fails$9 = function (exec) {
|
|
|
37
36
|
}
|
|
38
37
|
};
|
|
39
38
|
|
|
40
|
-
var fails$
|
|
39
|
+
var fails$9 = fails$a;
|
|
41
40
|
|
|
42
41
|
// Detect IE8's incomplete defineProperty implementation
|
|
43
|
-
var descriptors = !fails$
|
|
42
|
+
var descriptors = !fails$9(function () {
|
|
44
43
|
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
45
44
|
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7;
|
|
46
45
|
});
|
|
47
46
|
|
|
48
|
-
var fails$
|
|
47
|
+
var fails$8 = fails$a;
|
|
49
48
|
|
|
50
|
-
var functionBindNative = !fails$
|
|
49
|
+
var functionBindNative = !fails$8(function () {
|
|
51
50
|
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
52
51
|
var test = (function () { /* empty */ }).bind();
|
|
53
52
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
54
53
|
return typeof test != 'function' || test.hasOwnProperty('prototype');
|
|
55
54
|
});
|
|
56
55
|
|
|
57
|
-
var NATIVE_BIND$
|
|
56
|
+
var NATIVE_BIND$3 = functionBindNative;
|
|
58
57
|
|
|
59
|
-
var call$
|
|
58
|
+
var call$c = Function.prototype.call;
|
|
60
59
|
|
|
61
|
-
var functionCall = NATIVE_BIND$
|
|
62
|
-
return call$
|
|
60
|
+
var functionCall = NATIVE_BIND$3 ? call$c.bind(call$c) : function () {
|
|
61
|
+
return call$c.apply(call$c, arguments);
|
|
63
62
|
};
|
|
64
63
|
|
|
65
64
|
var objectPropertyIsEnumerable = {};
|
|
66
65
|
|
|
67
66
|
var $propertyIsEnumerable = {}.propertyIsEnumerable;
|
|
68
67
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
69
|
-
var getOwnPropertyDescriptor$
|
|
68
|
+
var getOwnPropertyDescriptor$2 = Object.getOwnPropertyDescriptor;
|
|
70
69
|
|
|
71
70
|
// Nashorn ~ JDK8 bug
|
|
72
|
-
var NASHORN_BUG = getOwnPropertyDescriptor$
|
|
71
|
+
var NASHORN_BUG = getOwnPropertyDescriptor$2 && !$propertyIsEnumerable.call({ 1: 2 }, 1);
|
|
73
72
|
|
|
74
73
|
// `Object.prototype.propertyIsEnumerable` method implementation
|
|
75
74
|
// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
|
|
76
75
|
objectPropertyIsEnumerable.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
|
|
77
|
-
var descriptor = getOwnPropertyDescriptor$
|
|
76
|
+
var descriptor = getOwnPropertyDescriptor$2(this, V);
|
|
78
77
|
return !!descriptor && descriptor.enumerable;
|
|
79
78
|
} : $propertyIsEnumerable;
|
|
80
79
|
|
|
@@ -87,66 +86,66 @@ var createPropertyDescriptor$2 = function (bitmap, value) {
|
|
|
87
86
|
};
|
|
88
87
|
};
|
|
89
88
|
|
|
90
|
-
var NATIVE_BIND = functionBindNative;
|
|
89
|
+
var NATIVE_BIND$2 = functionBindNative;
|
|
91
90
|
|
|
92
|
-
var FunctionPrototype$
|
|
93
|
-
var call$
|
|
94
|
-
var uncurryThisWithBind = NATIVE_BIND && FunctionPrototype$
|
|
91
|
+
var FunctionPrototype$2 = Function.prototype;
|
|
92
|
+
var call$b = FunctionPrototype$2.call;
|
|
93
|
+
var uncurryThisWithBind = NATIVE_BIND$2 && FunctionPrototype$2.bind.bind(call$b, call$b);
|
|
95
94
|
|
|
96
|
-
var functionUncurryThis = NATIVE_BIND ? uncurryThisWithBind : function (fn) {
|
|
95
|
+
var functionUncurryThis = NATIVE_BIND$2 ? uncurryThisWithBind : function (fn) {
|
|
97
96
|
return function () {
|
|
98
|
-
return call$
|
|
97
|
+
return call$b.apply(fn, arguments);
|
|
99
98
|
};
|
|
100
99
|
};
|
|
101
100
|
|
|
102
|
-
var uncurryThis$
|
|
101
|
+
var uncurryThis$c = functionUncurryThis;
|
|
103
102
|
|
|
104
|
-
var toString$1 = uncurryThis$
|
|
105
|
-
var stringSlice = uncurryThis$
|
|
103
|
+
var toString$1 = uncurryThis$c({}.toString);
|
|
104
|
+
var stringSlice = uncurryThis$c(''.slice);
|
|
106
105
|
|
|
107
|
-
var classofRaw = function (it) {
|
|
106
|
+
var classofRaw$2 = function (it) {
|
|
108
107
|
return stringSlice(toString$1(it), 8, -1);
|
|
109
108
|
};
|
|
110
109
|
|
|
111
|
-
var uncurryThis$
|
|
112
|
-
var fails$
|
|
113
|
-
var classof = classofRaw;
|
|
110
|
+
var uncurryThis$b = functionUncurryThis;
|
|
111
|
+
var fails$7 = fails$a;
|
|
112
|
+
var classof$4 = classofRaw$2;
|
|
114
113
|
|
|
115
|
-
var $Object$
|
|
116
|
-
var split = uncurryThis$
|
|
114
|
+
var $Object$3 = Object;
|
|
115
|
+
var split = uncurryThis$b(''.split);
|
|
117
116
|
|
|
118
117
|
// fallback for non-array-like ES3 and non-enumerable old V8 strings
|
|
119
|
-
var indexedObject = fails$
|
|
118
|
+
var indexedObject = fails$7(function () {
|
|
120
119
|
// throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
|
|
121
120
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
122
|
-
return !$Object$
|
|
121
|
+
return !$Object$3('z').propertyIsEnumerable(0);
|
|
123
122
|
}) ? function (it) {
|
|
124
|
-
return classof(it) == 'String' ? split(it, '') : $Object$
|
|
125
|
-
} : $Object$
|
|
123
|
+
return classof$4(it) == 'String' ? split(it, '') : $Object$3(it);
|
|
124
|
+
} : $Object$3;
|
|
126
125
|
|
|
127
126
|
// we can't use just `it == null` since of `document.all` special case
|
|
128
127
|
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
|
|
129
|
-
var isNullOrUndefined$
|
|
128
|
+
var isNullOrUndefined$4 = function (it) {
|
|
130
129
|
return it === null || it === undefined;
|
|
131
130
|
};
|
|
132
131
|
|
|
133
|
-
var isNullOrUndefined$
|
|
132
|
+
var isNullOrUndefined$3 = isNullOrUndefined$4;
|
|
134
133
|
|
|
135
|
-
var $TypeError$
|
|
134
|
+
var $TypeError$c = TypeError;
|
|
136
135
|
|
|
137
136
|
// `RequireObjectCoercible` abstract operation
|
|
138
137
|
// https://tc39.es/ecma262/#sec-requireobjectcoercible
|
|
139
138
|
var requireObjectCoercible$2 = function (it) {
|
|
140
|
-
if (isNullOrUndefined$
|
|
139
|
+
if (isNullOrUndefined$3(it)) throw $TypeError$c("Can't call method on " + it);
|
|
141
140
|
return it;
|
|
142
141
|
};
|
|
143
142
|
|
|
144
143
|
// toObject with fallback for non-array-like ES3 strings
|
|
145
|
-
var IndexedObject
|
|
144
|
+
var IndexedObject = indexedObject;
|
|
146
145
|
var requireObjectCoercible$1 = requireObjectCoercible$2;
|
|
147
146
|
|
|
148
147
|
var toIndexedObject$3 = function (it) {
|
|
149
|
-
return IndexedObject
|
|
148
|
+
return IndexedObject(requireObjectCoercible$1(it));
|
|
150
149
|
};
|
|
151
150
|
|
|
152
151
|
var documentAll$2 = typeof document == 'object' && document.all;
|
|
@@ -165,48 +164,48 @@ var documentAll$1 = $documentAll$1.all;
|
|
|
165
164
|
|
|
166
165
|
// `IsCallable` abstract operation
|
|
167
166
|
// https://tc39.es/ecma262/#sec-iscallable
|
|
168
|
-
var isCallable$
|
|
167
|
+
var isCallable$h = $documentAll$1.IS_HTMLDDA ? function (argument) {
|
|
169
168
|
return typeof argument == 'function' || argument === documentAll$1;
|
|
170
169
|
} : function (argument) {
|
|
171
170
|
return typeof argument == 'function';
|
|
172
171
|
};
|
|
173
172
|
|
|
174
|
-
var isCallable$
|
|
173
|
+
var isCallable$g = isCallable$h;
|
|
175
174
|
var $documentAll = documentAll_1;
|
|
176
175
|
|
|
177
176
|
var documentAll = $documentAll.all;
|
|
178
177
|
|
|
179
|
-
var isObject$
|
|
180
|
-
return typeof it == 'object' ? it !== null : isCallable$
|
|
178
|
+
var isObject$7 = $documentAll.IS_HTMLDDA ? function (it) {
|
|
179
|
+
return typeof it == 'object' ? it !== null : isCallable$g(it) || it === documentAll;
|
|
181
180
|
} : function (it) {
|
|
182
|
-
return typeof it == 'object' ? it !== null : isCallable$
|
|
181
|
+
return typeof it == 'object' ? it !== null : isCallable$g(it);
|
|
183
182
|
};
|
|
184
183
|
|
|
185
|
-
var global$
|
|
186
|
-
var isCallable$
|
|
184
|
+
var global$h = global$i;
|
|
185
|
+
var isCallable$f = isCallable$h;
|
|
187
186
|
|
|
188
187
|
var aFunction = function (argument) {
|
|
189
|
-
return isCallable$
|
|
188
|
+
return isCallable$f(argument) ? argument : undefined;
|
|
190
189
|
};
|
|
191
190
|
|
|
192
|
-
var getBuiltIn$
|
|
193
|
-
return arguments.length < 2 ? aFunction(global$
|
|
191
|
+
var getBuiltIn$8 = function (namespace, method) {
|
|
192
|
+
return arguments.length < 2 ? aFunction(global$h[namespace]) : global$h[namespace] && global$h[namespace][method];
|
|
194
193
|
};
|
|
195
194
|
|
|
196
|
-
var uncurryThis$
|
|
195
|
+
var uncurryThis$a = functionUncurryThis;
|
|
197
196
|
|
|
198
|
-
var objectIsPrototypeOf = uncurryThis$
|
|
197
|
+
var objectIsPrototypeOf = uncurryThis$a({}.isPrototypeOf);
|
|
199
198
|
|
|
200
|
-
var getBuiltIn$
|
|
199
|
+
var getBuiltIn$7 = getBuiltIn$8;
|
|
201
200
|
|
|
202
|
-
var engineUserAgent = getBuiltIn$
|
|
201
|
+
var engineUserAgent = getBuiltIn$7('navigator', 'userAgent') || '';
|
|
203
202
|
|
|
204
|
-
var global$
|
|
205
|
-
var userAgent = engineUserAgent;
|
|
203
|
+
var global$g = global$i;
|
|
204
|
+
var userAgent$3 = engineUserAgent;
|
|
206
205
|
|
|
207
|
-
var process = global$
|
|
208
|
-
var Deno = global$
|
|
209
|
-
var versions = process && process.versions || Deno && Deno.version;
|
|
206
|
+
var process$3 = global$g.process;
|
|
207
|
+
var Deno$1 = global$g.Deno;
|
|
208
|
+
var versions = process$3 && process$3.versions || Deno$1 && Deno$1.version;
|
|
210
209
|
var v8 = versions && versions.v8;
|
|
211
210
|
var match, version;
|
|
212
211
|
|
|
@@ -219,10 +218,10 @@ if (v8) {
|
|
|
219
218
|
|
|
220
219
|
// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`
|
|
221
220
|
// so check `userAgent` even if `.v8` exists, but 0
|
|
222
|
-
if (!version && userAgent) {
|
|
223
|
-
match = userAgent.match(/Edge\/(\d+)/);
|
|
221
|
+
if (!version && userAgent$3) {
|
|
222
|
+
match = userAgent$3.match(/Edge\/(\d+)/);
|
|
224
223
|
if (!match || match[1] >= 74) {
|
|
225
|
-
match = userAgent.match(/Chrome\/(\d+)/);
|
|
224
|
+
match = userAgent$3.match(/Chrome\/(\d+)/);
|
|
226
225
|
if (match) version = +match[1];
|
|
227
226
|
}
|
|
228
227
|
}
|
|
@@ -231,17 +230,17 @@ var engineV8Version = version;
|
|
|
231
230
|
|
|
232
231
|
/* eslint-disable es/no-symbol -- required for testing */
|
|
233
232
|
|
|
234
|
-
var V8_VERSION = engineV8Version;
|
|
235
|
-
var fails$
|
|
233
|
+
var V8_VERSION$1 = engineV8Version;
|
|
234
|
+
var fails$6 = fails$a;
|
|
236
235
|
|
|
237
236
|
// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
|
|
238
|
-
var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$
|
|
237
|
+
var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$6(function () {
|
|
239
238
|
var symbol = Symbol();
|
|
240
239
|
// Chrome 38 Symbol has incorrect toString conversion
|
|
241
240
|
// `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
|
|
242
241
|
return !String(symbol) || !(Object(symbol) instanceof Symbol) ||
|
|
243
242
|
// Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
|
|
244
|
-
!Symbol.sham && V8_VERSION && V8_VERSION < 41;
|
|
243
|
+
!Symbol.sham && V8_VERSION$1 && V8_VERSION$1 < 41;
|
|
245
244
|
});
|
|
246
245
|
|
|
247
246
|
/* eslint-disable es/no-symbol -- required for testing */
|
|
@@ -252,87 +251,87 @@ var useSymbolAsUid = NATIVE_SYMBOL$1
|
|
|
252
251
|
&& !Symbol.sham
|
|
253
252
|
&& typeof Symbol.iterator == 'symbol';
|
|
254
253
|
|
|
255
|
-
var getBuiltIn$
|
|
256
|
-
var isCallable$
|
|
257
|
-
var isPrototypeOf = objectIsPrototypeOf;
|
|
254
|
+
var getBuiltIn$6 = getBuiltIn$8;
|
|
255
|
+
var isCallable$e = isCallable$h;
|
|
256
|
+
var isPrototypeOf$2 = objectIsPrototypeOf;
|
|
258
257
|
var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
|
|
259
258
|
|
|
260
|
-
var $Object$
|
|
259
|
+
var $Object$2 = Object;
|
|
261
260
|
|
|
262
261
|
var isSymbol$2 = USE_SYMBOL_AS_UID$1 ? function (it) {
|
|
263
262
|
return typeof it == 'symbol';
|
|
264
263
|
} : function (it) {
|
|
265
|
-
var $Symbol = getBuiltIn$
|
|
266
|
-
return isCallable$
|
|
264
|
+
var $Symbol = getBuiltIn$6('Symbol');
|
|
265
|
+
return isCallable$e($Symbol) && isPrototypeOf$2($Symbol.prototype, $Object$2(it));
|
|
267
266
|
};
|
|
268
267
|
|
|
269
|
-
var $String$
|
|
268
|
+
var $String$2 = String;
|
|
270
269
|
|
|
271
|
-
var tryToString$
|
|
270
|
+
var tryToString$4 = function (argument) {
|
|
272
271
|
try {
|
|
273
|
-
return $String$
|
|
272
|
+
return $String$2(argument);
|
|
274
273
|
} catch (error) {
|
|
275
274
|
return 'Object';
|
|
276
275
|
}
|
|
277
276
|
};
|
|
278
277
|
|
|
279
|
-
var isCallable$
|
|
280
|
-
var tryToString = tryToString$
|
|
278
|
+
var isCallable$d = isCallable$h;
|
|
279
|
+
var tryToString$3 = tryToString$4;
|
|
281
280
|
|
|
282
|
-
var $TypeError$
|
|
281
|
+
var $TypeError$b = TypeError;
|
|
283
282
|
|
|
284
283
|
// `Assert: IsCallable(argument) is true`
|
|
285
|
-
var aCallable$
|
|
286
|
-
if (isCallable$
|
|
287
|
-
throw $TypeError$
|
|
284
|
+
var aCallable$7 = function (argument) {
|
|
285
|
+
if (isCallable$d(argument)) return argument;
|
|
286
|
+
throw $TypeError$b(tryToString$3(argument) + ' is not a function');
|
|
288
287
|
};
|
|
289
288
|
|
|
290
|
-
var aCallable = aCallable$
|
|
291
|
-
var isNullOrUndefined = isNullOrUndefined$
|
|
289
|
+
var aCallable$6 = aCallable$7;
|
|
290
|
+
var isNullOrUndefined$2 = isNullOrUndefined$4;
|
|
292
291
|
|
|
293
292
|
// `GetMethod` abstract operation
|
|
294
293
|
// https://tc39.es/ecma262/#sec-getmethod
|
|
295
|
-
var getMethod$
|
|
294
|
+
var getMethod$3 = function (V, P) {
|
|
296
295
|
var func = V[P];
|
|
297
|
-
return isNullOrUndefined(func) ? undefined : aCallable(func);
|
|
296
|
+
return isNullOrUndefined$2(func) ? undefined : aCallable$6(func);
|
|
298
297
|
};
|
|
299
298
|
|
|
300
|
-
var call$
|
|
301
|
-
var isCallable$
|
|
302
|
-
var isObject$
|
|
299
|
+
var call$a = functionCall;
|
|
300
|
+
var isCallable$c = isCallable$h;
|
|
301
|
+
var isObject$6 = isObject$7;
|
|
303
302
|
|
|
304
|
-
var $TypeError$
|
|
303
|
+
var $TypeError$a = TypeError;
|
|
305
304
|
|
|
306
305
|
// `OrdinaryToPrimitive` abstract operation
|
|
307
306
|
// https://tc39.es/ecma262/#sec-ordinarytoprimitive
|
|
308
307
|
var ordinaryToPrimitive$1 = function (input, pref) {
|
|
309
308
|
var fn, val;
|
|
310
|
-
if (pref === 'string' && isCallable$
|
|
311
|
-
if (isCallable$
|
|
312
|
-
if (pref !== 'string' && isCallable$
|
|
313
|
-
throw $TypeError$
|
|
309
|
+
if (pref === 'string' && isCallable$c(fn = input.toString) && !isObject$6(val = call$a(fn, input))) return val;
|
|
310
|
+
if (isCallable$c(fn = input.valueOf) && !isObject$6(val = call$a(fn, input))) return val;
|
|
311
|
+
if (pref !== 'string' && isCallable$c(fn = input.toString) && !isObject$6(val = call$a(fn, input))) return val;
|
|
312
|
+
throw $TypeError$a("Can't convert object to primitive value");
|
|
314
313
|
};
|
|
315
314
|
|
|
316
315
|
var shared$3 = {exports: {}};
|
|
317
316
|
|
|
318
|
-
var global$
|
|
317
|
+
var global$f = global$i;
|
|
319
318
|
|
|
320
319
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
321
320
|
var defineProperty$2 = Object.defineProperty;
|
|
322
321
|
|
|
323
322
|
var defineGlobalProperty$3 = function (key, value) {
|
|
324
323
|
try {
|
|
325
|
-
defineProperty$2(global$
|
|
324
|
+
defineProperty$2(global$f, key, { value: value, configurable: true, writable: true });
|
|
326
325
|
} catch (error) {
|
|
327
|
-
global$
|
|
326
|
+
global$f[key] = value;
|
|
328
327
|
} return value;
|
|
329
328
|
};
|
|
330
329
|
|
|
331
|
-
var global$
|
|
330
|
+
var global$e = global$i;
|
|
332
331
|
var defineGlobalProperty$2 = defineGlobalProperty$3;
|
|
333
332
|
|
|
334
333
|
var SHARED = '__core-js_shared__';
|
|
335
|
-
var store$3 = global$
|
|
334
|
+
var store$3 = global$e[SHARED] || defineGlobalProperty$2(SHARED, {});
|
|
336
335
|
|
|
337
336
|
var sharedStore = store$3;
|
|
338
337
|
|
|
@@ -350,52 +349,52 @@ var store$2 = sharedStore;
|
|
|
350
349
|
|
|
351
350
|
var requireObjectCoercible = requireObjectCoercible$2;
|
|
352
351
|
|
|
353
|
-
var $Object = Object;
|
|
352
|
+
var $Object$1 = Object;
|
|
354
353
|
|
|
355
354
|
// `ToObject` abstract operation
|
|
356
355
|
// https://tc39.es/ecma262/#sec-toobject
|
|
357
|
-
var toObject$
|
|
358
|
-
return $Object(requireObjectCoercible(argument));
|
|
356
|
+
var toObject$1 = function (argument) {
|
|
357
|
+
return $Object$1(requireObjectCoercible(argument));
|
|
359
358
|
};
|
|
360
359
|
|
|
361
|
-
var uncurryThis$
|
|
362
|
-
var toObject
|
|
360
|
+
var uncurryThis$9 = functionUncurryThis;
|
|
361
|
+
var toObject = toObject$1;
|
|
363
362
|
|
|
364
|
-
var hasOwnProperty = uncurryThis$
|
|
363
|
+
var hasOwnProperty = uncurryThis$9({}.hasOwnProperty);
|
|
365
364
|
|
|
366
365
|
// `HasOwnProperty` abstract operation
|
|
367
366
|
// https://tc39.es/ecma262/#sec-hasownproperty
|
|
368
367
|
// eslint-disable-next-line es/no-object-hasown -- safe
|
|
369
368
|
var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
|
|
370
|
-
return hasOwnProperty(toObject
|
|
369
|
+
return hasOwnProperty(toObject(it), key);
|
|
371
370
|
};
|
|
372
371
|
|
|
373
|
-
var uncurryThis$
|
|
372
|
+
var uncurryThis$8 = functionUncurryThis;
|
|
374
373
|
|
|
375
374
|
var id = 0;
|
|
376
375
|
var postfix = Math.random();
|
|
377
|
-
var toString = uncurryThis$
|
|
376
|
+
var toString = uncurryThis$8(1.0.toString);
|
|
378
377
|
|
|
379
378
|
var uid$2 = function (key) {
|
|
380
379
|
return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);
|
|
381
380
|
};
|
|
382
381
|
|
|
383
|
-
var global$
|
|
382
|
+
var global$d = global$i;
|
|
384
383
|
var shared$2 = shared$3.exports;
|
|
385
|
-
var hasOwn$
|
|
384
|
+
var hasOwn$8 = hasOwnProperty_1;
|
|
386
385
|
var uid$1 = uid$2;
|
|
387
386
|
var NATIVE_SYMBOL = symbolConstructorDetection;
|
|
388
387
|
var USE_SYMBOL_AS_UID = useSymbolAsUid;
|
|
389
388
|
|
|
390
389
|
var WellKnownSymbolsStore = shared$2('wks');
|
|
391
|
-
var Symbol$1 = global$
|
|
390
|
+
var Symbol$1 = global$d.Symbol;
|
|
392
391
|
var symbolFor = Symbol$1 && Symbol$1['for'];
|
|
393
392
|
var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid$1;
|
|
394
393
|
|
|
395
|
-
var wellKnownSymbol$
|
|
396
|
-
if (!hasOwn$
|
|
394
|
+
var wellKnownSymbol$a = function (name) {
|
|
395
|
+
if (!hasOwn$8(WellKnownSymbolsStore, name) || !(NATIVE_SYMBOL || typeof WellKnownSymbolsStore[name] == 'string')) {
|
|
397
396
|
var description = 'Symbol.' + name;
|
|
398
|
-
if (NATIVE_SYMBOL && hasOwn$
|
|
397
|
+
if (NATIVE_SYMBOL && hasOwn$8(Symbol$1, name)) {
|
|
399
398
|
WellKnownSymbolsStore[name] = Symbol$1[name];
|
|
400
399
|
} else if (USE_SYMBOL_AS_UID && symbolFor) {
|
|
401
400
|
WellKnownSymbolsStore[name] = symbolFor(description);
|
|
@@ -405,27 +404,27 @@ var wellKnownSymbol$1 = function (name) {
|
|
|
405
404
|
} return WellKnownSymbolsStore[name];
|
|
406
405
|
};
|
|
407
406
|
|
|
408
|
-
var call$
|
|
409
|
-
var isObject$
|
|
407
|
+
var call$9 = functionCall;
|
|
408
|
+
var isObject$5 = isObject$7;
|
|
410
409
|
var isSymbol$1 = isSymbol$2;
|
|
411
|
-
var getMethod = getMethod$
|
|
410
|
+
var getMethod$2 = getMethod$3;
|
|
412
411
|
var ordinaryToPrimitive = ordinaryToPrimitive$1;
|
|
413
|
-
var wellKnownSymbol = wellKnownSymbol$
|
|
412
|
+
var wellKnownSymbol$9 = wellKnownSymbol$a;
|
|
414
413
|
|
|
415
|
-
var $TypeError$
|
|
416
|
-
var TO_PRIMITIVE = wellKnownSymbol('toPrimitive');
|
|
414
|
+
var $TypeError$9 = TypeError;
|
|
415
|
+
var TO_PRIMITIVE = wellKnownSymbol$9('toPrimitive');
|
|
417
416
|
|
|
418
417
|
// `ToPrimitive` abstract operation
|
|
419
418
|
// https://tc39.es/ecma262/#sec-toprimitive
|
|
420
419
|
var toPrimitive$1 = function (input, pref) {
|
|
421
|
-
if (!isObject$
|
|
422
|
-
var exoticToPrim = getMethod(input, TO_PRIMITIVE);
|
|
420
|
+
if (!isObject$5(input) || isSymbol$1(input)) return input;
|
|
421
|
+
var exoticToPrim = getMethod$2(input, TO_PRIMITIVE);
|
|
423
422
|
var result;
|
|
424
423
|
if (exoticToPrim) {
|
|
425
424
|
if (pref === undefined) pref = 'default';
|
|
426
|
-
result = call$
|
|
427
|
-
if (!isObject$
|
|
428
|
-
throw $TypeError$
|
|
425
|
+
result = call$9(exoticToPrim, input, pref);
|
|
426
|
+
if (!isObject$5(result) || isSymbol$1(result)) return result;
|
|
427
|
+
throw $TypeError$9("Can't convert object to primitive value");
|
|
429
428
|
}
|
|
430
429
|
if (pref === undefined) pref = 'number';
|
|
431
430
|
return ordinaryToPrimitive(input, pref);
|
|
@@ -441,36 +440,36 @@ var toPropertyKey$2 = function (argument) {
|
|
|
441
440
|
return isSymbol(key) ? key : key + '';
|
|
442
441
|
};
|
|
443
442
|
|
|
444
|
-
var global$
|
|
445
|
-
var isObject$
|
|
443
|
+
var global$c = global$i;
|
|
444
|
+
var isObject$4 = isObject$7;
|
|
446
445
|
|
|
447
|
-
var document$
|
|
446
|
+
var document$3 = global$c.document;
|
|
448
447
|
// typeof document.createElement is 'object' in old IE
|
|
449
|
-
var EXISTS$1 = isObject$
|
|
448
|
+
var EXISTS$1 = isObject$4(document$3) && isObject$4(document$3.createElement);
|
|
450
449
|
|
|
451
450
|
var documentCreateElement = function (it) {
|
|
452
|
-
return EXISTS$1 ? document$
|
|
451
|
+
return EXISTS$1 ? document$3.createElement(it) : {};
|
|
453
452
|
};
|
|
454
453
|
|
|
455
454
|
var DESCRIPTORS$7 = descriptors;
|
|
456
|
-
var fails$
|
|
457
|
-
var createElement = documentCreateElement;
|
|
455
|
+
var fails$5 = fails$a;
|
|
456
|
+
var createElement$1 = documentCreateElement;
|
|
458
457
|
|
|
459
458
|
// Thanks to IE8 for its funny defineProperty
|
|
460
|
-
var ie8DomDefine = !DESCRIPTORS$7 && !fails$
|
|
459
|
+
var ie8DomDefine = !DESCRIPTORS$7 && !fails$5(function () {
|
|
461
460
|
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
462
|
-
return Object.defineProperty(createElement('div'), 'a', {
|
|
461
|
+
return Object.defineProperty(createElement$1('div'), 'a', {
|
|
463
462
|
get: function () { return 7; }
|
|
464
463
|
}).a != 7;
|
|
465
464
|
});
|
|
466
465
|
|
|
467
466
|
var DESCRIPTORS$6 = descriptors;
|
|
468
|
-
var call$
|
|
469
|
-
var propertyIsEnumerableModule
|
|
467
|
+
var call$8 = functionCall;
|
|
468
|
+
var propertyIsEnumerableModule = objectPropertyIsEnumerable;
|
|
470
469
|
var createPropertyDescriptor$1 = createPropertyDescriptor$2;
|
|
471
470
|
var toIndexedObject$2 = toIndexedObject$3;
|
|
472
471
|
var toPropertyKey$1 = toPropertyKey$2;
|
|
473
|
-
var hasOwn$
|
|
472
|
+
var hasOwn$7 = hasOwnProperty_1;
|
|
474
473
|
var IE8_DOM_DEFINE$1 = ie8DomDefine;
|
|
475
474
|
|
|
476
475
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
@@ -484,17 +483,17 @@ objectGetOwnPropertyDescriptor.f = DESCRIPTORS$6 ? $getOwnPropertyDescriptor$1 :
|
|
|
484
483
|
if (IE8_DOM_DEFINE$1) try {
|
|
485
484
|
return $getOwnPropertyDescriptor$1(O, P);
|
|
486
485
|
} catch (error) { /* empty */ }
|
|
487
|
-
if (hasOwn$
|
|
486
|
+
if (hasOwn$7(O, P)) return createPropertyDescriptor$1(!call$8(propertyIsEnumerableModule.f, O, P), O[P]);
|
|
488
487
|
};
|
|
489
488
|
|
|
490
489
|
var objectDefineProperty = {};
|
|
491
490
|
|
|
492
491
|
var DESCRIPTORS$5 = descriptors;
|
|
493
|
-
var fails$
|
|
492
|
+
var fails$4 = fails$a;
|
|
494
493
|
|
|
495
494
|
// V8 ~ Chrome 36-
|
|
496
495
|
// https://bugs.chromium.org/p/v8/issues/detail?id=3334
|
|
497
|
-
var v8PrototypeDefineBug = DESCRIPTORS$5 && fails$
|
|
496
|
+
var v8PrototypeDefineBug = DESCRIPTORS$5 && fails$4(function () {
|
|
498
497
|
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
499
498
|
return Object.defineProperty(function () { /* empty */ }, 'prototype', {
|
|
500
499
|
value: 42,
|
|
@@ -502,24 +501,24 @@ var v8PrototypeDefineBug = DESCRIPTORS$5 && fails$3(function () {
|
|
|
502
501
|
}).prototype != 42;
|
|
503
502
|
});
|
|
504
503
|
|
|
505
|
-
var isObject$
|
|
504
|
+
var isObject$3 = isObject$7;
|
|
506
505
|
|
|
507
|
-
var $String = String;
|
|
508
|
-
var $TypeError$
|
|
506
|
+
var $String$1 = String;
|
|
507
|
+
var $TypeError$8 = TypeError;
|
|
509
508
|
|
|
510
509
|
// `Assert: Type(argument) is Object`
|
|
511
|
-
var anObject$
|
|
512
|
-
if (isObject$
|
|
513
|
-
throw $TypeError$
|
|
510
|
+
var anObject$8 = function (argument) {
|
|
511
|
+
if (isObject$3(argument)) return argument;
|
|
512
|
+
throw $TypeError$8($String$1(argument) + ' is not an object');
|
|
514
513
|
};
|
|
515
514
|
|
|
516
515
|
var DESCRIPTORS$4 = descriptors;
|
|
517
516
|
var IE8_DOM_DEFINE = ie8DomDefine;
|
|
518
517
|
var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
|
|
519
|
-
var anObject$
|
|
518
|
+
var anObject$7 = anObject$8;
|
|
520
519
|
var toPropertyKey = toPropertyKey$2;
|
|
521
520
|
|
|
522
|
-
var $TypeError = TypeError;
|
|
521
|
+
var $TypeError$7 = TypeError;
|
|
523
522
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
524
523
|
var $defineProperty = Object.defineProperty;
|
|
525
524
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
@@ -531,9 +530,9 @@ var WRITABLE = 'writable';
|
|
|
531
530
|
// `Object.defineProperty` method
|
|
532
531
|
// https://tc39.es/ecma262/#sec-object.defineproperty
|
|
533
532
|
objectDefineProperty.f = DESCRIPTORS$4 ? V8_PROTOTYPE_DEFINE_BUG ? function defineProperty(O, P, Attributes) {
|
|
534
|
-
anObject$
|
|
533
|
+
anObject$7(O);
|
|
535
534
|
P = toPropertyKey(P);
|
|
536
|
-
anObject$
|
|
535
|
+
anObject$7(Attributes);
|
|
537
536
|
if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {
|
|
538
537
|
var current = $getOwnPropertyDescriptor(O, P);
|
|
539
538
|
if (current && current[WRITABLE]) {
|
|
@@ -546,23 +545,23 @@ objectDefineProperty.f = DESCRIPTORS$4 ? V8_PROTOTYPE_DEFINE_BUG ? function defi
|
|
|
546
545
|
}
|
|
547
546
|
} return $defineProperty(O, P, Attributes);
|
|
548
547
|
} : $defineProperty : function defineProperty(O, P, Attributes) {
|
|
549
|
-
anObject$
|
|
548
|
+
anObject$7(O);
|
|
550
549
|
P = toPropertyKey(P);
|
|
551
|
-
anObject$
|
|
550
|
+
anObject$7(Attributes);
|
|
552
551
|
if (IE8_DOM_DEFINE) try {
|
|
553
552
|
return $defineProperty(O, P, Attributes);
|
|
554
553
|
} catch (error) { /* empty */ }
|
|
555
|
-
if ('get' in Attributes || 'set' in Attributes) throw $TypeError('Accessors not supported');
|
|
554
|
+
if ('get' in Attributes || 'set' in Attributes) throw $TypeError$7('Accessors not supported');
|
|
556
555
|
if ('value' in Attributes) O[P] = Attributes.value;
|
|
557
556
|
return O;
|
|
558
557
|
};
|
|
559
558
|
|
|
560
559
|
var DESCRIPTORS$3 = descriptors;
|
|
561
|
-
var definePropertyModule$
|
|
560
|
+
var definePropertyModule$3 = objectDefineProperty;
|
|
562
561
|
var createPropertyDescriptor = createPropertyDescriptor$2;
|
|
563
562
|
|
|
564
563
|
var createNonEnumerableProperty$2 = DESCRIPTORS$3 ? function (object, key, value) {
|
|
565
|
-
return definePropertyModule$
|
|
564
|
+
return definePropertyModule$3.f(object, key, createPropertyDescriptor(1, value));
|
|
566
565
|
} : function (object, key, value) {
|
|
567
566
|
object[key] = value;
|
|
568
567
|
return object;
|
|
@@ -571,16 +570,16 @@ var createNonEnumerableProperty$2 = DESCRIPTORS$3 ? function (object, key, value
|
|
|
571
570
|
var makeBuiltIn$2 = {exports: {}};
|
|
572
571
|
|
|
573
572
|
var DESCRIPTORS$2 = descriptors;
|
|
574
|
-
var hasOwn$
|
|
573
|
+
var hasOwn$6 = hasOwnProperty_1;
|
|
575
574
|
|
|
576
|
-
var FunctionPrototype = Function.prototype;
|
|
575
|
+
var FunctionPrototype$1 = Function.prototype;
|
|
577
576
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
578
577
|
var getDescriptor = DESCRIPTORS$2 && Object.getOwnPropertyDescriptor;
|
|
579
578
|
|
|
580
|
-
var EXISTS = hasOwn$
|
|
579
|
+
var EXISTS = hasOwn$6(FunctionPrototype$1, 'name');
|
|
581
580
|
// additional protection from minified / mangled / dropped function names
|
|
582
581
|
var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
|
|
583
|
-
var CONFIGURABLE = EXISTS && (!DESCRIPTORS$2 || (DESCRIPTORS$2 && getDescriptor(FunctionPrototype, 'name').configurable));
|
|
582
|
+
var CONFIGURABLE = EXISTS && (!DESCRIPTORS$2 || (DESCRIPTORS$2 && getDescriptor(FunctionPrototype$1, 'name').configurable));
|
|
584
583
|
|
|
585
584
|
var functionName = {
|
|
586
585
|
EXISTS: EXISTS,
|
|
@@ -588,27 +587,27 @@ var functionName = {
|
|
|
588
587
|
CONFIGURABLE: CONFIGURABLE
|
|
589
588
|
};
|
|
590
589
|
|
|
591
|
-
var uncurryThis$
|
|
592
|
-
var isCallable$
|
|
590
|
+
var uncurryThis$7 = functionUncurryThis;
|
|
591
|
+
var isCallable$b = isCallable$h;
|
|
593
592
|
var store$1 = sharedStore;
|
|
594
593
|
|
|
595
|
-
var functionToString = uncurryThis$
|
|
594
|
+
var functionToString = uncurryThis$7(Function.toString);
|
|
596
595
|
|
|
597
596
|
// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
|
|
598
|
-
if (!isCallable$
|
|
597
|
+
if (!isCallable$b(store$1.inspectSource)) {
|
|
599
598
|
store$1.inspectSource = function (it) {
|
|
600
599
|
return functionToString(it);
|
|
601
600
|
};
|
|
602
601
|
}
|
|
603
602
|
|
|
604
|
-
var inspectSource$
|
|
603
|
+
var inspectSource$3 = store$1.inspectSource;
|
|
605
604
|
|
|
606
|
-
var global$
|
|
607
|
-
var isCallable$
|
|
605
|
+
var global$b = global$i;
|
|
606
|
+
var isCallable$a = isCallable$h;
|
|
608
607
|
|
|
609
|
-
var WeakMap$1 = global$
|
|
608
|
+
var WeakMap$1 = global$b.WeakMap;
|
|
610
609
|
|
|
611
|
-
var weakMapBasicDetection = isCallable$
|
|
610
|
+
var weakMapBasicDetection = isCallable$a(WeakMap$1) && /native code/.test(String(WeakMap$1));
|
|
612
611
|
|
|
613
612
|
var shared$1 = shared$3.exports;
|
|
614
613
|
var uid = uid$2;
|
|
@@ -622,28 +621,28 @@ var sharedKey$1 = function (key) {
|
|
|
622
621
|
var hiddenKeys$3 = {};
|
|
623
622
|
|
|
624
623
|
var NATIVE_WEAK_MAP = weakMapBasicDetection;
|
|
625
|
-
var global$
|
|
626
|
-
var isObject = isObject$
|
|
624
|
+
var global$a = global$i;
|
|
625
|
+
var isObject$2 = isObject$7;
|
|
627
626
|
var createNonEnumerableProperty$1 = createNonEnumerableProperty$2;
|
|
628
|
-
var hasOwn$
|
|
627
|
+
var hasOwn$5 = hasOwnProperty_1;
|
|
629
628
|
var shared = sharedStore;
|
|
630
629
|
var sharedKey = sharedKey$1;
|
|
631
630
|
var hiddenKeys$2 = hiddenKeys$3;
|
|
632
631
|
|
|
633
632
|
var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
|
|
634
|
-
var TypeError$
|
|
635
|
-
var WeakMap = global$
|
|
636
|
-
var set, get, has;
|
|
633
|
+
var TypeError$2 = global$a.TypeError;
|
|
634
|
+
var WeakMap = global$a.WeakMap;
|
|
635
|
+
var set$1, get, has;
|
|
637
636
|
|
|
638
637
|
var enforce = function (it) {
|
|
639
|
-
return has(it) ? get(it) : set(it, {});
|
|
638
|
+
return has(it) ? get(it) : set$1(it, {});
|
|
640
639
|
};
|
|
641
640
|
|
|
642
641
|
var getterFor = function (TYPE) {
|
|
643
642
|
return function (it) {
|
|
644
643
|
var state;
|
|
645
|
-
if (!isObject(it) || (state = get(it)).type !== TYPE) {
|
|
646
|
-
throw TypeError$
|
|
644
|
+
if (!isObject$2(it) || (state = get(it)).type !== TYPE) {
|
|
645
|
+
throw TypeError$2('Incompatible receiver, ' + TYPE + ' required');
|
|
647
646
|
} return state;
|
|
648
647
|
};
|
|
649
648
|
};
|
|
@@ -655,8 +654,8 @@ if (NATIVE_WEAK_MAP || shared.state) {
|
|
|
655
654
|
store.has = store.has;
|
|
656
655
|
store.set = store.set;
|
|
657
656
|
/* eslint-enable no-self-assign -- prototype methods protection */
|
|
658
|
-
set = function (it, metadata) {
|
|
659
|
-
if (store.has(it)) throw TypeError$
|
|
657
|
+
set$1 = function (it, metadata) {
|
|
658
|
+
if (store.has(it)) throw TypeError$2(OBJECT_ALREADY_INITIALIZED);
|
|
660
659
|
metadata.facade = it;
|
|
661
660
|
store.set(it, metadata);
|
|
662
661
|
return metadata;
|
|
@@ -670,42 +669,42 @@ if (NATIVE_WEAK_MAP || shared.state) {
|
|
|
670
669
|
} else {
|
|
671
670
|
var STATE = sharedKey('state');
|
|
672
671
|
hiddenKeys$2[STATE] = true;
|
|
673
|
-
set = function (it, metadata) {
|
|
674
|
-
if (hasOwn$
|
|
672
|
+
set$1 = function (it, metadata) {
|
|
673
|
+
if (hasOwn$5(it, STATE)) throw TypeError$2(OBJECT_ALREADY_INITIALIZED);
|
|
675
674
|
metadata.facade = it;
|
|
676
675
|
createNonEnumerableProperty$1(it, STATE, metadata);
|
|
677
676
|
return metadata;
|
|
678
677
|
};
|
|
679
678
|
get = function (it) {
|
|
680
|
-
return hasOwn$
|
|
679
|
+
return hasOwn$5(it, STATE) ? it[STATE] : {};
|
|
681
680
|
};
|
|
682
681
|
has = function (it) {
|
|
683
|
-
return hasOwn$
|
|
682
|
+
return hasOwn$5(it, STATE);
|
|
684
683
|
};
|
|
685
684
|
}
|
|
686
685
|
|
|
687
686
|
var internalState = {
|
|
688
|
-
set: set,
|
|
687
|
+
set: set$1,
|
|
689
688
|
get: get,
|
|
690
689
|
has: has,
|
|
691
690
|
enforce: enforce,
|
|
692
691
|
getterFor: getterFor
|
|
693
692
|
};
|
|
694
693
|
|
|
695
|
-
var fails$
|
|
696
|
-
var isCallable$
|
|
697
|
-
var hasOwn$
|
|
694
|
+
var fails$3 = fails$a;
|
|
695
|
+
var isCallable$9 = isCallable$h;
|
|
696
|
+
var hasOwn$4 = hasOwnProperty_1;
|
|
698
697
|
var DESCRIPTORS$1 = descriptors;
|
|
699
698
|
var CONFIGURABLE_FUNCTION_NAME = functionName.CONFIGURABLE;
|
|
700
|
-
var inspectSource = inspectSource$
|
|
701
|
-
var InternalStateModule = internalState;
|
|
699
|
+
var inspectSource$2 = inspectSource$3;
|
|
700
|
+
var InternalStateModule$1 = internalState;
|
|
702
701
|
|
|
703
|
-
var enforceInternalState = InternalStateModule.enforce;
|
|
704
|
-
var getInternalState = InternalStateModule.get;
|
|
702
|
+
var enforceInternalState = InternalStateModule$1.enforce;
|
|
703
|
+
var getInternalState = InternalStateModule$1.get;
|
|
705
704
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
706
705
|
var defineProperty$1 = Object.defineProperty;
|
|
707
706
|
|
|
708
|
-
var CONFIGURABLE_LENGTH = DESCRIPTORS$1 && !fails$
|
|
707
|
+
var CONFIGURABLE_LENGTH = DESCRIPTORS$1 && !fails$3(function () {
|
|
709
708
|
return defineProperty$1(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
|
|
710
709
|
});
|
|
711
710
|
|
|
@@ -717,21 +716,21 @@ var makeBuiltIn$1 = makeBuiltIn$2.exports = function (value, name, options) {
|
|
|
717
716
|
}
|
|
718
717
|
if (options && options.getter) name = 'get ' + name;
|
|
719
718
|
if (options && options.setter) name = 'set ' + name;
|
|
720
|
-
if (!hasOwn$
|
|
719
|
+
if (!hasOwn$4(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {
|
|
721
720
|
if (DESCRIPTORS$1) defineProperty$1(value, 'name', { value: name, configurable: true });
|
|
722
721
|
else value.name = name;
|
|
723
722
|
}
|
|
724
|
-
if (CONFIGURABLE_LENGTH && options && hasOwn$
|
|
723
|
+
if (CONFIGURABLE_LENGTH && options && hasOwn$4(options, 'arity') && value.length !== options.arity) {
|
|
725
724
|
defineProperty$1(value, 'length', { value: options.arity });
|
|
726
725
|
}
|
|
727
726
|
try {
|
|
728
|
-
if (options && hasOwn$
|
|
727
|
+
if (options && hasOwn$4(options, 'constructor') && options.constructor) {
|
|
729
728
|
if (DESCRIPTORS$1) defineProperty$1(value, 'prototype', { writable: false });
|
|
730
729
|
// in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable
|
|
731
730
|
} else if (value.prototype) value.prototype = undefined;
|
|
732
731
|
} catch (error) { /* empty */ }
|
|
733
732
|
var state = enforceInternalState(value);
|
|
734
|
-
if (!hasOwn$
|
|
733
|
+
if (!hasOwn$4(state, 'source')) {
|
|
735
734
|
state.source = TEMPLATE.join(typeof name == 'string' ? name : '');
|
|
736
735
|
} return value;
|
|
737
736
|
};
|
|
@@ -739,19 +738,19 @@ var makeBuiltIn$1 = makeBuiltIn$2.exports = function (value, name, options) {
|
|
|
739
738
|
// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
|
|
740
739
|
// eslint-disable-next-line no-extend-native -- required
|
|
741
740
|
Function.prototype.toString = makeBuiltIn$1(function toString() {
|
|
742
|
-
return isCallable$
|
|
741
|
+
return isCallable$9(this) && getInternalState(this).source || inspectSource$2(this);
|
|
743
742
|
}, 'toString');
|
|
744
743
|
|
|
745
|
-
var isCallable$
|
|
746
|
-
var definePropertyModule$
|
|
744
|
+
var isCallable$8 = isCallable$h;
|
|
745
|
+
var definePropertyModule$2 = objectDefineProperty;
|
|
747
746
|
var makeBuiltIn = makeBuiltIn$2.exports;
|
|
748
747
|
var defineGlobalProperty$1 = defineGlobalProperty$3;
|
|
749
748
|
|
|
750
|
-
var defineBuiltIn$
|
|
749
|
+
var defineBuiltIn$3 = function (O, key, value, options) {
|
|
751
750
|
if (!options) options = {};
|
|
752
751
|
var simple = options.enumerable;
|
|
753
752
|
var name = options.name !== undefined ? options.name : key;
|
|
754
|
-
if (isCallable$
|
|
753
|
+
if (isCallable$8(value)) makeBuiltIn(value, name, options);
|
|
755
754
|
if (options.global) {
|
|
756
755
|
if (simple) O[key] = value;
|
|
757
756
|
else defineGlobalProperty$1(key, value);
|
|
@@ -761,7 +760,7 @@ var defineBuiltIn$1 = function (O, key, value, options) {
|
|
|
761
760
|
else if (O[key]) simple = true;
|
|
762
761
|
} catch (error) { /* empty */ }
|
|
763
762
|
if (simple) O[key] = value;
|
|
764
|
-
else definePropertyModule$
|
|
763
|
+
else definePropertyModule$2.f(O, key, {
|
|
765
764
|
value: value,
|
|
766
765
|
enumerable: false,
|
|
767
766
|
configurable: !options.nonConfigurable,
|
|
@@ -820,19 +819,19 @@ var toLength = toLength$1;
|
|
|
820
819
|
|
|
821
820
|
// `LengthOfArrayLike` abstract operation
|
|
822
821
|
// https://tc39.es/ecma262/#sec-lengthofarraylike
|
|
823
|
-
var lengthOfArrayLike$
|
|
822
|
+
var lengthOfArrayLike$2 = function (obj) {
|
|
824
823
|
return toLength(obj.length);
|
|
825
824
|
};
|
|
826
825
|
|
|
827
826
|
var toIndexedObject$1 = toIndexedObject$3;
|
|
828
827
|
var toAbsoluteIndex = toAbsoluteIndex$1;
|
|
829
|
-
var lengthOfArrayLike = lengthOfArrayLike$
|
|
828
|
+
var lengthOfArrayLike$1 = lengthOfArrayLike$2;
|
|
830
829
|
|
|
831
830
|
// `Array.prototype.{ indexOf, includes }` methods implementation
|
|
832
831
|
var createMethod = function (IS_INCLUDES) {
|
|
833
832
|
return function ($this, el, fromIndex) {
|
|
834
833
|
var O = toIndexedObject$1($this);
|
|
835
|
-
var length = lengthOfArrayLike(O);
|
|
834
|
+
var length = lengthOfArrayLike$1(O);
|
|
836
835
|
var index = toAbsoluteIndex(fromIndex, length);
|
|
837
836
|
var value;
|
|
838
837
|
// Array#includes uses SameValueZero equality algorithm
|
|
@@ -857,29 +856,29 @@ var arrayIncludes = {
|
|
|
857
856
|
indexOf: createMethod(false)
|
|
858
857
|
};
|
|
859
858
|
|
|
860
|
-
var uncurryThis$
|
|
861
|
-
var hasOwn$
|
|
859
|
+
var uncurryThis$6 = functionUncurryThis;
|
|
860
|
+
var hasOwn$3 = hasOwnProperty_1;
|
|
862
861
|
var toIndexedObject = toIndexedObject$3;
|
|
863
862
|
var indexOf = arrayIncludes.indexOf;
|
|
864
863
|
var hiddenKeys$1 = hiddenKeys$3;
|
|
865
864
|
|
|
866
|
-
var push = uncurryThis$
|
|
865
|
+
var push = uncurryThis$6([].push);
|
|
867
866
|
|
|
868
867
|
var objectKeysInternal = function (object, names) {
|
|
869
868
|
var O = toIndexedObject(object);
|
|
870
869
|
var i = 0;
|
|
871
870
|
var result = [];
|
|
872
871
|
var key;
|
|
873
|
-
for (key in O) !hasOwn$
|
|
872
|
+
for (key in O) !hasOwn$3(hiddenKeys$1, key) && hasOwn$3(O, key) && push(result, key);
|
|
874
873
|
// Don't enum bug & hidden keys
|
|
875
|
-
while (names.length > i) if (hasOwn$
|
|
874
|
+
while (names.length > i) if (hasOwn$3(O, key = names[i++])) {
|
|
876
875
|
~indexOf(result, key) || push(result, key);
|
|
877
876
|
}
|
|
878
877
|
return result;
|
|
879
878
|
};
|
|
880
879
|
|
|
881
880
|
// IE8- don't enum bug keys
|
|
882
|
-
var enumBugKeys$
|
|
881
|
+
var enumBugKeys$1 = [
|
|
883
882
|
'constructor',
|
|
884
883
|
'hasOwnProperty',
|
|
885
884
|
'isPrototypeOf',
|
|
@@ -889,16 +888,16 @@ var enumBugKeys$2 = [
|
|
|
889
888
|
'valueOf'
|
|
890
889
|
];
|
|
891
890
|
|
|
892
|
-
var internalObjectKeys
|
|
893
|
-
var enumBugKeys
|
|
891
|
+
var internalObjectKeys = objectKeysInternal;
|
|
892
|
+
var enumBugKeys = enumBugKeys$1;
|
|
894
893
|
|
|
895
|
-
var hiddenKeys = enumBugKeys
|
|
894
|
+
var hiddenKeys = enumBugKeys.concat('length', 'prototype');
|
|
896
895
|
|
|
897
896
|
// `Object.getOwnPropertyNames` method
|
|
898
897
|
// https://tc39.es/ecma262/#sec-object.getownpropertynames
|
|
899
898
|
// eslint-disable-next-line es/no-object-getownpropertynames -- safe
|
|
900
899
|
objectGetOwnPropertyNames.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
|
|
901
|
-
return internalObjectKeys
|
|
900
|
+
return internalObjectKeys(O, hiddenKeys);
|
|
902
901
|
};
|
|
903
902
|
|
|
904
903
|
var objectGetOwnPropertySymbols = {};
|
|
@@ -906,68 +905,68 @@ var objectGetOwnPropertySymbols = {};
|
|
|
906
905
|
// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
|
|
907
906
|
objectGetOwnPropertySymbols.f = Object.getOwnPropertySymbols;
|
|
908
907
|
|
|
909
|
-
var getBuiltIn = getBuiltIn$
|
|
910
|
-
var uncurryThis$
|
|
908
|
+
var getBuiltIn$5 = getBuiltIn$8;
|
|
909
|
+
var uncurryThis$5 = functionUncurryThis;
|
|
911
910
|
var getOwnPropertyNamesModule = objectGetOwnPropertyNames;
|
|
912
|
-
var getOwnPropertySymbolsModule
|
|
913
|
-
var anObject = anObject$
|
|
911
|
+
var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols;
|
|
912
|
+
var anObject$6 = anObject$8;
|
|
914
913
|
|
|
915
|
-
var concat
|
|
914
|
+
var concat = uncurryThis$5([].concat);
|
|
916
915
|
|
|
917
916
|
// all object keys, includes non-enumerable and symbols
|
|
918
|
-
var ownKeys$1 = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {
|
|
919
|
-
var keys = getOwnPropertyNamesModule.f(anObject(it));
|
|
920
|
-
var getOwnPropertySymbols = getOwnPropertySymbolsModule
|
|
921
|
-
return getOwnPropertySymbols ? concat
|
|
917
|
+
var ownKeys$1 = getBuiltIn$5('Reflect', 'ownKeys') || function ownKeys(it) {
|
|
918
|
+
var keys = getOwnPropertyNamesModule.f(anObject$6(it));
|
|
919
|
+
var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
|
|
920
|
+
return getOwnPropertySymbols ? concat(keys, getOwnPropertySymbols(it)) : keys;
|
|
922
921
|
};
|
|
923
922
|
|
|
924
|
-
var hasOwn = hasOwnProperty_1;
|
|
923
|
+
var hasOwn$2 = hasOwnProperty_1;
|
|
925
924
|
var ownKeys = ownKeys$1;
|
|
926
925
|
var getOwnPropertyDescriptorModule = objectGetOwnPropertyDescriptor;
|
|
927
|
-
var definePropertyModule = objectDefineProperty;
|
|
926
|
+
var definePropertyModule$1 = objectDefineProperty;
|
|
928
927
|
|
|
929
928
|
var copyConstructorProperties$1 = function (target, source, exceptions) {
|
|
930
929
|
var keys = ownKeys(source);
|
|
931
|
-
var defineProperty = definePropertyModule.f;
|
|
930
|
+
var defineProperty = definePropertyModule$1.f;
|
|
932
931
|
var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
|
|
933
932
|
for (var i = 0; i < keys.length; i++) {
|
|
934
933
|
var key = keys[i];
|
|
935
|
-
if (!hasOwn(target, key) && !(exceptions && hasOwn(exceptions, key))) {
|
|
934
|
+
if (!hasOwn$2(target, key) && !(exceptions && hasOwn$2(exceptions, key))) {
|
|
936
935
|
defineProperty(target, key, getOwnPropertyDescriptor(source, key));
|
|
937
936
|
}
|
|
938
937
|
}
|
|
939
938
|
};
|
|
940
939
|
|
|
941
|
-
var fails$
|
|
942
|
-
var isCallable = isCallable$
|
|
940
|
+
var fails$2 = fails$a;
|
|
941
|
+
var isCallable$7 = isCallable$h;
|
|
943
942
|
|
|
944
943
|
var replacement = /#|\.prototype\./;
|
|
945
944
|
|
|
946
|
-
var isForced$
|
|
945
|
+
var isForced$2 = function (feature, detection) {
|
|
947
946
|
var value = data[normalize(feature)];
|
|
948
947
|
return value == POLYFILL ? true
|
|
949
948
|
: value == NATIVE ? false
|
|
950
|
-
: isCallable(detection) ? fails$
|
|
949
|
+
: isCallable$7(detection) ? fails$2(detection)
|
|
951
950
|
: !!detection;
|
|
952
951
|
};
|
|
953
952
|
|
|
954
|
-
var normalize = isForced$
|
|
953
|
+
var normalize = isForced$2.normalize = function (string) {
|
|
955
954
|
return String(string).replace(replacement, '.').toLowerCase();
|
|
956
955
|
};
|
|
957
956
|
|
|
958
|
-
var data = isForced$
|
|
959
|
-
var NATIVE = isForced$
|
|
960
|
-
var POLYFILL = isForced$
|
|
957
|
+
var data = isForced$2.data = {};
|
|
958
|
+
var NATIVE = isForced$2.NATIVE = 'N';
|
|
959
|
+
var POLYFILL = isForced$2.POLYFILL = 'P';
|
|
961
960
|
|
|
962
|
-
var isForced_1 = isForced$
|
|
961
|
+
var isForced_1 = isForced$2;
|
|
963
962
|
|
|
964
|
-
var global$
|
|
965
|
-
var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
|
|
963
|
+
var global$9 = global$i;
|
|
964
|
+
var getOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
|
|
966
965
|
var createNonEnumerableProperty = createNonEnumerableProperty$2;
|
|
967
|
-
var defineBuiltIn = defineBuiltIn$
|
|
966
|
+
var defineBuiltIn$2 = defineBuiltIn$3;
|
|
968
967
|
var defineGlobalProperty = defineGlobalProperty$3;
|
|
969
968
|
var copyConstructorProperties = copyConstructorProperties$1;
|
|
970
|
-
var isForced = isForced_1;
|
|
969
|
+
var isForced$1 = isForced_1;
|
|
971
970
|
|
|
972
971
|
/*
|
|
973
972
|
options.target - name of the target object
|
|
@@ -990,19 +989,19 @@ var _export = function (options, source) {
|
|
|
990
989
|
var STATIC = options.stat;
|
|
991
990
|
var FORCED, target, key, targetProperty, sourceProperty, descriptor;
|
|
992
991
|
if (GLOBAL) {
|
|
993
|
-
target = global$
|
|
992
|
+
target = global$9;
|
|
994
993
|
} else if (STATIC) {
|
|
995
|
-
target = global$
|
|
994
|
+
target = global$9[TARGET] || defineGlobalProperty(TARGET, {});
|
|
996
995
|
} else {
|
|
997
|
-
target = (global$
|
|
996
|
+
target = (global$9[TARGET] || {}).prototype;
|
|
998
997
|
}
|
|
999
998
|
if (target) for (key in source) {
|
|
1000
999
|
sourceProperty = source[key];
|
|
1001
1000
|
if (options.dontCallGetSet) {
|
|
1002
|
-
descriptor = getOwnPropertyDescriptor(target, key);
|
|
1001
|
+
descriptor = getOwnPropertyDescriptor$1(target, key);
|
|
1003
1002
|
targetProperty = descriptor && descriptor.value;
|
|
1004
1003
|
} else targetProperty = target[key];
|
|
1005
|
-
FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
|
|
1004
|
+
FORCED = isForced$1(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
|
|
1006
1005
|
// contained in target
|
|
1007
1006
|
if (!FORCED && targetProperty !== undefined) {
|
|
1008
1007
|
if (typeof sourceProperty == typeof targetProperty) continue;
|
|
@@ -1012,141 +1011,1277 @@ var _export = function (options, source) {
|
|
|
1012
1011
|
if (options.sham || (targetProperty && targetProperty.sham)) {
|
|
1013
1012
|
createNonEnumerableProperty(sourceProperty, 'sham', true);
|
|
1014
1013
|
}
|
|
1015
|
-
defineBuiltIn(target, key, sourceProperty, options);
|
|
1014
|
+
defineBuiltIn$2(target, key, sourceProperty, options);
|
|
1016
1015
|
}
|
|
1017
1016
|
};
|
|
1018
1017
|
|
|
1019
|
-
var
|
|
1020
|
-
var
|
|
1018
|
+
var classof$3 = classofRaw$2;
|
|
1019
|
+
var global$8 = global$i;
|
|
1020
|
+
|
|
1021
|
+
var engineIsNode = classof$3(global$8.process) == 'process';
|
|
1022
|
+
|
|
1023
|
+
var isCallable$6 = isCallable$h;
|
|
1024
|
+
|
|
1025
|
+
var $String = String;
|
|
1026
|
+
var $TypeError$6 = TypeError;
|
|
1027
|
+
|
|
1028
|
+
var aPossiblePrototype$1 = function (argument) {
|
|
1029
|
+
if (typeof argument == 'object' || isCallable$6(argument)) return argument;
|
|
1030
|
+
throw $TypeError$6("Can't set " + $String(argument) + ' as a prototype');
|
|
1031
|
+
};
|
|
1032
|
+
|
|
1033
|
+
/* eslint-disable no-proto -- safe */
|
|
1034
|
+
|
|
1035
|
+
var uncurryThis$4 = functionUncurryThis;
|
|
1036
|
+
var anObject$5 = anObject$8;
|
|
1037
|
+
var aPossiblePrototype = aPossiblePrototype$1;
|
|
1038
|
+
|
|
1039
|
+
// `Object.setPrototypeOf` method
|
|
1040
|
+
// https://tc39.es/ecma262/#sec-object.setprototypeof
|
|
1041
|
+
// Works with __proto__ only. Old v8 can't work with null proto objects.
|
|
1042
|
+
// eslint-disable-next-line es/no-object-setprototypeof -- safe
|
|
1043
|
+
var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? function () {
|
|
1044
|
+
var CORRECT_SETTER = false;
|
|
1045
|
+
var test = {};
|
|
1046
|
+
var setter;
|
|
1047
|
+
try {
|
|
1048
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
1049
|
+
setter = uncurryThis$4(Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set);
|
|
1050
|
+
setter(test, []);
|
|
1051
|
+
CORRECT_SETTER = test instanceof Array;
|
|
1052
|
+
} catch (error) { /* empty */ }
|
|
1053
|
+
return function setPrototypeOf(O, proto) {
|
|
1054
|
+
anObject$5(O);
|
|
1055
|
+
aPossiblePrototype(proto);
|
|
1056
|
+
if (CORRECT_SETTER) setter(O, proto);
|
|
1057
|
+
else O.__proto__ = proto;
|
|
1058
|
+
return O;
|
|
1059
|
+
};
|
|
1060
|
+
}() : undefined);
|
|
1061
|
+
|
|
1062
|
+
var defineProperty = objectDefineProperty.f;
|
|
1063
|
+
var hasOwn$1 = hasOwnProperty_1;
|
|
1064
|
+
var wellKnownSymbol$8 = wellKnownSymbol$a;
|
|
1021
1065
|
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1066
|
+
var TO_STRING_TAG$2 = wellKnownSymbol$8('toStringTag');
|
|
1067
|
+
|
|
1068
|
+
var setToStringTag$1 = function (target, TAG, STATIC) {
|
|
1069
|
+
if (target && !STATIC) target = target.prototype;
|
|
1070
|
+
if (target && !hasOwn$1(target, TO_STRING_TAG$2)) {
|
|
1071
|
+
defineProperty(target, TO_STRING_TAG$2, { configurable: true, value: TAG });
|
|
1072
|
+
}
|
|
1027
1073
|
};
|
|
1028
1074
|
|
|
1075
|
+
var getBuiltIn$4 = getBuiltIn$8;
|
|
1076
|
+
var definePropertyModule = objectDefineProperty;
|
|
1077
|
+
var wellKnownSymbol$7 = wellKnownSymbol$a;
|
|
1029
1078
|
var DESCRIPTORS = descriptors;
|
|
1079
|
+
|
|
1080
|
+
var SPECIES$2 = wellKnownSymbol$7('species');
|
|
1081
|
+
|
|
1082
|
+
var setSpecies$1 = function (CONSTRUCTOR_NAME) {
|
|
1083
|
+
var Constructor = getBuiltIn$4(CONSTRUCTOR_NAME);
|
|
1084
|
+
var defineProperty = definePropertyModule.f;
|
|
1085
|
+
|
|
1086
|
+
if (DESCRIPTORS && Constructor && !Constructor[SPECIES$2]) {
|
|
1087
|
+
defineProperty(Constructor, SPECIES$2, {
|
|
1088
|
+
configurable: true,
|
|
1089
|
+
get: function () { return this; }
|
|
1090
|
+
});
|
|
1091
|
+
}
|
|
1092
|
+
};
|
|
1093
|
+
|
|
1094
|
+
var isPrototypeOf$1 = objectIsPrototypeOf;
|
|
1095
|
+
|
|
1096
|
+
var $TypeError$5 = TypeError;
|
|
1097
|
+
|
|
1098
|
+
var anInstance$1 = function (it, Prototype) {
|
|
1099
|
+
if (isPrototypeOf$1(Prototype, it)) return it;
|
|
1100
|
+
throw $TypeError$5('Incorrect invocation');
|
|
1101
|
+
};
|
|
1102
|
+
|
|
1103
|
+
var wellKnownSymbol$6 = wellKnownSymbol$a;
|
|
1104
|
+
|
|
1105
|
+
var TO_STRING_TAG$1 = wellKnownSymbol$6('toStringTag');
|
|
1106
|
+
var test = {};
|
|
1107
|
+
|
|
1108
|
+
test[TO_STRING_TAG$1] = 'z';
|
|
1109
|
+
|
|
1110
|
+
var toStringTagSupport = String(test) === '[object z]';
|
|
1111
|
+
|
|
1112
|
+
var TO_STRING_TAG_SUPPORT = toStringTagSupport;
|
|
1113
|
+
var isCallable$5 = isCallable$h;
|
|
1114
|
+
var classofRaw$1 = classofRaw$2;
|
|
1115
|
+
var wellKnownSymbol$5 = wellKnownSymbol$a;
|
|
1116
|
+
|
|
1117
|
+
var TO_STRING_TAG = wellKnownSymbol$5('toStringTag');
|
|
1118
|
+
var $Object = Object;
|
|
1119
|
+
|
|
1120
|
+
// ES3 wrong here
|
|
1121
|
+
var CORRECT_ARGUMENTS = classofRaw$1(function () { return arguments; }()) == 'Arguments';
|
|
1122
|
+
|
|
1123
|
+
// fallback for IE11 Script Access Denied error
|
|
1124
|
+
var tryGet = function (it, key) {
|
|
1125
|
+
try {
|
|
1126
|
+
return it[key];
|
|
1127
|
+
} catch (error) { /* empty */ }
|
|
1128
|
+
};
|
|
1129
|
+
|
|
1130
|
+
// getting tag from ES6+ `Object.prototype.toString`
|
|
1131
|
+
var classof$2 = TO_STRING_TAG_SUPPORT ? classofRaw$1 : function (it) {
|
|
1132
|
+
var O, tag, result;
|
|
1133
|
+
return it === undefined ? 'Undefined' : it === null ? 'Null'
|
|
1134
|
+
// @@toStringTag case
|
|
1135
|
+
: typeof (tag = tryGet(O = $Object(it), TO_STRING_TAG)) == 'string' ? tag
|
|
1136
|
+
// builtinTag case
|
|
1137
|
+
: CORRECT_ARGUMENTS ? classofRaw$1(O)
|
|
1138
|
+
// ES3 arguments fallback
|
|
1139
|
+
: (result = classofRaw$1(O)) == 'Object' && isCallable$5(O.callee) ? 'Arguments' : result;
|
|
1140
|
+
};
|
|
1141
|
+
|
|
1142
|
+
var uncurryThis$3 = functionUncurryThis;
|
|
1143
|
+
var fails$1 = fails$a;
|
|
1144
|
+
var isCallable$4 = isCallable$h;
|
|
1145
|
+
var classof$1 = classof$2;
|
|
1146
|
+
var getBuiltIn$3 = getBuiltIn$8;
|
|
1147
|
+
var inspectSource$1 = inspectSource$3;
|
|
1148
|
+
|
|
1149
|
+
var noop = function () { /* empty */ };
|
|
1150
|
+
var empty = [];
|
|
1151
|
+
var construct = getBuiltIn$3('Reflect', 'construct');
|
|
1152
|
+
var constructorRegExp = /^\s*(?:class|function)\b/;
|
|
1153
|
+
var exec = uncurryThis$3(constructorRegExp.exec);
|
|
1154
|
+
var INCORRECT_TO_STRING = !constructorRegExp.exec(noop);
|
|
1155
|
+
|
|
1156
|
+
var isConstructorModern = function isConstructor(argument) {
|
|
1157
|
+
if (!isCallable$4(argument)) return false;
|
|
1158
|
+
try {
|
|
1159
|
+
construct(noop, empty, argument);
|
|
1160
|
+
return true;
|
|
1161
|
+
} catch (error) {
|
|
1162
|
+
return false;
|
|
1163
|
+
}
|
|
1164
|
+
};
|
|
1165
|
+
|
|
1166
|
+
var isConstructorLegacy = function isConstructor(argument) {
|
|
1167
|
+
if (!isCallable$4(argument)) return false;
|
|
1168
|
+
switch (classof$1(argument)) {
|
|
1169
|
+
case 'AsyncFunction':
|
|
1170
|
+
case 'GeneratorFunction':
|
|
1171
|
+
case 'AsyncGeneratorFunction': return false;
|
|
1172
|
+
}
|
|
1173
|
+
try {
|
|
1174
|
+
// we can't check .prototype since constructors produced by .bind haven't it
|
|
1175
|
+
// `Function#toString` throws on some built-it function in some legacy engines
|
|
1176
|
+
// (for example, `DOMQuad` and similar in FF41-)
|
|
1177
|
+
return INCORRECT_TO_STRING || !!exec(constructorRegExp, inspectSource$1(argument));
|
|
1178
|
+
} catch (error) {
|
|
1179
|
+
return true;
|
|
1180
|
+
}
|
|
1181
|
+
};
|
|
1182
|
+
|
|
1183
|
+
isConstructorLegacy.sham = true;
|
|
1184
|
+
|
|
1185
|
+
// `IsConstructor` abstract operation
|
|
1186
|
+
// https://tc39.es/ecma262/#sec-isconstructor
|
|
1187
|
+
var isConstructor$1 = !construct || fails$1(function () {
|
|
1188
|
+
var called;
|
|
1189
|
+
return isConstructorModern(isConstructorModern.call)
|
|
1190
|
+
|| !isConstructorModern(Object)
|
|
1191
|
+
|| !isConstructorModern(function () { called = true; })
|
|
1192
|
+
|| called;
|
|
1193
|
+
}) ? isConstructorLegacy : isConstructorModern;
|
|
1194
|
+
|
|
1195
|
+
var isConstructor = isConstructor$1;
|
|
1196
|
+
var tryToString$2 = tryToString$4;
|
|
1197
|
+
|
|
1198
|
+
var $TypeError$4 = TypeError;
|
|
1199
|
+
|
|
1200
|
+
// `Assert: IsConstructor(argument) is true`
|
|
1201
|
+
var aConstructor$1 = function (argument) {
|
|
1202
|
+
if (isConstructor(argument)) return argument;
|
|
1203
|
+
throw $TypeError$4(tryToString$2(argument) + ' is not a constructor');
|
|
1204
|
+
};
|
|
1205
|
+
|
|
1206
|
+
var anObject$4 = anObject$8;
|
|
1207
|
+
var aConstructor = aConstructor$1;
|
|
1208
|
+
var isNullOrUndefined$1 = isNullOrUndefined$4;
|
|
1209
|
+
var wellKnownSymbol$4 = wellKnownSymbol$a;
|
|
1210
|
+
|
|
1211
|
+
var SPECIES$1 = wellKnownSymbol$4('species');
|
|
1212
|
+
|
|
1213
|
+
// `SpeciesConstructor` abstract operation
|
|
1214
|
+
// https://tc39.es/ecma262/#sec-speciesconstructor
|
|
1215
|
+
var speciesConstructor$1 = function (O, defaultConstructor) {
|
|
1216
|
+
var C = anObject$4(O).constructor;
|
|
1217
|
+
var S;
|
|
1218
|
+
return C === undefined || isNullOrUndefined$1(S = anObject$4(C)[SPECIES$1]) ? defaultConstructor : aConstructor(S);
|
|
1219
|
+
};
|
|
1220
|
+
|
|
1221
|
+
var NATIVE_BIND$1 = functionBindNative;
|
|
1222
|
+
|
|
1223
|
+
var FunctionPrototype = Function.prototype;
|
|
1224
|
+
var apply$1 = FunctionPrototype.apply;
|
|
1225
|
+
var call$7 = FunctionPrototype.call;
|
|
1226
|
+
|
|
1227
|
+
// eslint-disable-next-line es/no-reflect -- safe
|
|
1228
|
+
var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND$1 ? call$7.bind(apply$1) : function () {
|
|
1229
|
+
return call$7.apply(apply$1, arguments);
|
|
1230
|
+
});
|
|
1231
|
+
|
|
1232
|
+
var classofRaw = classofRaw$2;
|
|
1233
|
+
var uncurryThis$2 = functionUncurryThis;
|
|
1234
|
+
|
|
1235
|
+
var functionUncurryThisClause = function (fn) {
|
|
1236
|
+
// Nashorn bug:
|
|
1237
|
+
// https://github.com/zloirock/core-js/issues/1128
|
|
1238
|
+
// https://github.com/zloirock/core-js/issues/1130
|
|
1239
|
+
if (classofRaw(fn) === 'Function') return uncurryThis$2(fn);
|
|
1240
|
+
};
|
|
1241
|
+
|
|
1242
|
+
var uncurryThis$1 = functionUncurryThisClause;
|
|
1243
|
+
var aCallable$5 = aCallable$7;
|
|
1244
|
+
var NATIVE_BIND = functionBindNative;
|
|
1245
|
+
|
|
1246
|
+
var bind$4 = uncurryThis$1(uncurryThis$1.bind);
|
|
1247
|
+
|
|
1248
|
+
// optional / simple context binding
|
|
1249
|
+
var functionBindContext = function (fn, that) {
|
|
1250
|
+
aCallable$5(fn);
|
|
1251
|
+
return that === undefined ? fn : NATIVE_BIND ? bind$4(fn, that) : function (/* ...args */) {
|
|
1252
|
+
return fn.apply(that, arguments);
|
|
1253
|
+
};
|
|
1254
|
+
};
|
|
1255
|
+
|
|
1256
|
+
var getBuiltIn$2 = getBuiltIn$8;
|
|
1257
|
+
|
|
1258
|
+
var html$1 = getBuiltIn$2('document', 'documentElement');
|
|
1259
|
+
|
|
1030
1260
|
var uncurryThis = functionUncurryThis;
|
|
1031
|
-
var call = functionCall;
|
|
1032
|
-
var fails = fails$9;
|
|
1033
|
-
var objectKeys = objectKeys$1;
|
|
1034
|
-
var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols;
|
|
1035
|
-
var propertyIsEnumerableModule = objectPropertyIsEnumerable;
|
|
1036
|
-
var toObject = toObject$2;
|
|
1037
|
-
var IndexedObject = indexedObject;
|
|
1038
1261
|
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
var
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1262
|
+
var arraySlice$1 = uncurryThis([].slice);
|
|
1263
|
+
|
|
1264
|
+
var $TypeError$3 = TypeError;
|
|
1265
|
+
|
|
1266
|
+
var validateArgumentsLength$1 = function (passed, required) {
|
|
1267
|
+
if (passed < required) throw $TypeError$3('Not enough arguments');
|
|
1268
|
+
return passed;
|
|
1269
|
+
};
|
|
1270
|
+
|
|
1271
|
+
var userAgent$2 = engineUserAgent;
|
|
1272
|
+
|
|
1273
|
+
var engineIsIos = /(?:ipad|iphone|ipod).*applewebkit/i.test(userAgent$2);
|
|
1274
|
+
|
|
1275
|
+
var global$7 = global$i;
|
|
1276
|
+
var apply = functionApply;
|
|
1277
|
+
var bind$3 = functionBindContext;
|
|
1278
|
+
var isCallable$3 = isCallable$h;
|
|
1279
|
+
var hasOwn = hasOwnProperty_1;
|
|
1280
|
+
var fails = fails$a;
|
|
1281
|
+
var html = html$1;
|
|
1282
|
+
var arraySlice = arraySlice$1;
|
|
1283
|
+
var createElement = documentCreateElement;
|
|
1284
|
+
var validateArgumentsLength = validateArgumentsLength$1;
|
|
1285
|
+
var IS_IOS$1 = engineIsIos;
|
|
1286
|
+
var IS_NODE$3 = engineIsNode;
|
|
1287
|
+
|
|
1288
|
+
var set = global$7.setImmediate;
|
|
1289
|
+
var clear = global$7.clearImmediate;
|
|
1290
|
+
var process$2 = global$7.process;
|
|
1291
|
+
var Dispatch = global$7.Dispatch;
|
|
1292
|
+
var Function$1 = global$7.Function;
|
|
1293
|
+
var MessageChannel = global$7.MessageChannel;
|
|
1294
|
+
var String$1 = global$7.String;
|
|
1295
|
+
var counter = 0;
|
|
1296
|
+
var queue$1 = {};
|
|
1297
|
+
var ONREADYSTATECHANGE = 'onreadystatechange';
|
|
1298
|
+
var $location, defer, channel, port;
|
|
1299
|
+
|
|
1300
|
+
try {
|
|
1301
|
+
// Deno throws a ReferenceError on `location` access without `--location` flag
|
|
1302
|
+
$location = global$7.location;
|
|
1303
|
+
} catch (error) { /* empty */ }
|
|
1304
|
+
|
|
1305
|
+
var run = function (id) {
|
|
1306
|
+
if (hasOwn(queue$1, id)) {
|
|
1307
|
+
var fn = queue$1[id];
|
|
1308
|
+
delete queue$1[id];
|
|
1309
|
+
fn();
|
|
1310
|
+
}
|
|
1311
|
+
};
|
|
1312
|
+
|
|
1313
|
+
var runner = function (id) {
|
|
1314
|
+
return function () {
|
|
1315
|
+
run(id);
|
|
1316
|
+
};
|
|
1317
|
+
};
|
|
1318
|
+
|
|
1319
|
+
var listener = function (event) {
|
|
1320
|
+
run(event.data);
|
|
1321
|
+
};
|
|
1322
|
+
|
|
1323
|
+
var post = function (id) {
|
|
1324
|
+
// old engines have not location.origin
|
|
1325
|
+
global$7.postMessage(String$1(id), $location.protocol + '//' + $location.host);
|
|
1326
|
+
};
|
|
1327
|
+
|
|
1328
|
+
// Node.js 0.9+ & IE10+ has setImmediate, otherwise:
|
|
1329
|
+
if (!set || !clear) {
|
|
1330
|
+
set = function setImmediate(handler) {
|
|
1331
|
+
validateArgumentsLength(arguments.length, 1);
|
|
1332
|
+
var fn = isCallable$3(handler) ? handler : Function$1(handler);
|
|
1333
|
+
var args = arraySlice(arguments, 1);
|
|
1334
|
+
queue$1[++counter] = function () {
|
|
1335
|
+
apply(fn, undefined, args);
|
|
1336
|
+
};
|
|
1337
|
+
defer(counter);
|
|
1338
|
+
return counter;
|
|
1339
|
+
};
|
|
1340
|
+
clear = function clearImmediate(id) {
|
|
1341
|
+
delete queue$1[id];
|
|
1342
|
+
};
|
|
1343
|
+
// Node.js 0.8-
|
|
1344
|
+
if (IS_NODE$3) {
|
|
1345
|
+
defer = function (id) {
|
|
1346
|
+
process$2.nextTick(runner(id));
|
|
1347
|
+
};
|
|
1348
|
+
// Sphere (JS game engine) Dispatch API
|
|
1349
|
+
} else if (Dispatch && Dispatch.now) {
|
|
1350
|
+
defer = function (id) {
|
|
1351
|
+
Dispatch.now(runner(id));
|
|
1352
|
+
};
|
|
1353
|
+
// Browsers with MessageChannel, includes WebWorkers
|
|
1354
|
+
// except iOS - https://github.com/zloirock/core-js/issues/624
|
|
1355
|
+
} else if (MessageChannel && !IS_IOS$1) {
|
|
1356
|
+
channel = new MessageChannel();
|
|
1357
|
+
port = channel.port2;
|
|
1358
|
+
channel.port1.onmessage = listener;
|
|
1359
|
+
defer = bind$3(port.postMessage, port);
|
|
1360
|
+
// Browsers with postMessage, skip WebWorkers
|
|
1361
|
+
// IE8 has postMessage, but it's sync & typeof its postMessage is 'object'
|
|
1362
|
+
} else if (
|
|
1363
|
+
global$7.addEventListener &&
|
|
1364
|
+
isCallable$3(global$7.postMessage) &&
|
|
1365
|
+
!global$7.importScripts &&
|
|
1366
|
+
$location && $location.protocol !== 'file:' &&
|
|
1367
|
+
!fails(post)
|
|
1368
|
+
) {
|
|
1369
|
+
defer = post;
|
|
1370
|
+
global$7.addEventListener('message', listener, false);
|
|
1371
|
+
// IE8-
|
|
1372
|
+
} else if (ONREADYSTATECHANGE in createElement('script')) {
|
|
1373
|
+
defer = function (id) {
|
|
1374
|
+
html.appendChild(createElement('script'))[ONREADYSTATECHANGE] = function () {
|
|
1375
|
+
html.removeChild(this);
|
|
1376
|
+
run(id);
|
|
1377
|
+
};
|
|
1378
|
+
};
|
|
1379
|
+
// Rest old browsers
|
|
1380
|
+
} else {
|
|
1381
|
+
defer = function (id) {
|
|
1382
|
+
setTimeout(runner(id), 0);
|
|
1383
|
+
};
|
|
1384
|
+
}
|
|
1385
|
+
}
|
|
1386
|
+
|
|
1387
|
+
var task$1 = {
|
|
1388
|
+
set: set,
|
|
1389
|
+
clear: clear
|
|
1390
|
+
};
|
|
1391
|
+
|
|
1392
|
+
var userAgent$1 = engineUserAgent;
|
|
1393
|
+
var global$6 = global$i;
|
|
1394
|
+
|
|
1395
|
+
var engineIsIosPebble = /ipad|iphone|ipod/i.test(userAgent$1) && global$6.Pebble !== undefined;
|
|
1396
|
+
|
|
1397
|
+
var userAgent = engineUserAgent;
|
|
1398
|
+
|
|
1399
|
+
var engineIsWebosWebkit = /web0s(?!.*chrome)/i.test(userAgent);
|
|
1400
|
+
|
|
1401
|
+
var global$5 = global$i;
|
|
1402
|
+
var bind$2 = functionBindContext;
|
|
1403
|
+
var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
|
|
1404
|
+
var macrotask = task$1.set;
|
|
1405
|
+
var IS_IOS = engineIsIos;
|
|
1406
|
+
var IS_IOS_PEBBLE = engineIsIosPebble;
|
|
1407
|
+
var IS_WEBOS_WEBKIT = engineIsWebosWebkit;
|
|
1408
|
+
var IS_NODE$2 = engineIsNode;
|
|
1409
|
+
|
|
1410
|
+
var MutationObserver = global$5.MutationObserver || global$5.WebKitMutationObserver;
|
|
1411
|
+
var document$2 = global$5.document;
|
|
1412
|
+
var process$1 = global$5.process;
|
|
1413
|
+
var Promise$1 = global$5.Promise;
|
|
1414
|
+
// Node.js 11 shows ExperimentalWarning on getting `queueMicrotask`
|
|
1415
|
+
var queueMicrotaskDescriptor = getOwnPropertyDescriptor(global$5, 'queueMicrotask');
|
|
1416
|
+
var queueMicrotask = queueMicrotaskDescriptor && queueMicrotaskDescriptor.value;
|
|
1417
|
+
|
|
1418
|
+
var flush, head, last, notify$1, toggle, node, promise, then;
|
|
1419
|
+
|
|
1420
|
+
// modern engines have queueMicrotask method
|
|
1421
|
+
if (!queueMicrotask) {
|
|
1422
|
+
flush = function () {
|
|
1423
|
+
var parent, fn;
|
|
1424
|
+
if (IS_NODE$2 && (parent = process$1.domain)) parent.exit();
|
|
1425
|
+
while (head) {
|
|
1426
|
+
fn = head.fn;
|
|
1427
|
+
head = head.next;
|
|
1428
|
+
try {
|
|
1429
|
+
fn();
|
|
1430
|
+
} catch (error) {
|
|
1431
|
+
if (head) notify$1();
|
|
1432
|
+
else last = undefined;
|
|
1433
|
+
throw error;
|
|
1434
|
+
}
|
|
1435
|
+
} last = undefined;
|
|
1436
|
+
if (parent) parent.enter();
|
|
1437
|
+
};
|
|
1438
|
+
|
|
1439
|
+
// browsers with MutationObserver, except iOS - https://github.com/zloirock/core-js/issues/339
|
|
1440
|
+
// also except WebOS Webkit https://github.com/zloirock/core-js/issues/898
|
|
1441
|
+
if (!IS_IOS && !IS_NODE$2 && !IS_WEBOS_WEBKIT && MutationObserver && document$2) {
|
|
1442
|
+
toggle = true;
|
|
1443
|
+
node = document$2.createTextNode('');
|
|
1444
|
+
new MutationObserver(flush).observe(node, { characterData: true });
|
|
1445
|
+
notify$1 = function () {
|
|
1446
|
+
node.data = toggle = !toggle;
|
|
1447
|
+
};
|
|
1448
|
+
// environments with maybe non-completely correct, but existent Promise
|
|
1449
|
+
} else if (!IS_IOS_PEBBLE && Promise$1 && Promise$1.resolve) {
|
|
1450
|
+
// Promise.resolve without an argument throws an error in LG WebOS 2
|
|
1451
|
+
promise = Promise$1.resolve(undefined);
|
|
1452
|
+
// workaround of WebKit ~ iOS Safari 10.1 bug
|
|
1453
|
+
promise.constructor = Promise$1;
|
|
1454
|
+
then = bind$2(promise.then, promise);
|
|
1455
|
+
notify$1 = function () {
|
|
1456
|
+
then(flush);
|
|
1457
|
+
};
|
|
1458
|
+
// Node.js without promises
|
|
1459
|
+
} else if (IS_NODE$2) {
|
|
1460
|
+
notify$1 = function () {
|
|
1461
|
+
process$1.nextTick(flush);
|
|
1462
|
+
};
|
|
1463
|
+
// for other environments - macrotask based on:
|
|
1464
|
+
// - setImmediate
|
|
1465
|
+
// - MessageChannel
|
|
1466
|
+
// - window.postMessage
|
|
1467
|
+
// - onreadystatechange
|
|
1468
|
+
// - setTimeout
|
|
1469
|
+
} else {
|
|
1470
|
+
// strange IE + webpack dev server bug - use .bind(global)
|
|
1471
|
+
macrotask = bind$2(macrotask, global$5);
|
|
1472
|
+
notify$1 = function () {
|
|
1473
|
+
macrotask(flush);
|
|
1474
|
+
};
|
|
1475
|
+
}
|
|
1476
|
+
}
|
|
1477
|
+
|
|
1478
|
+
var microtask$1 = queueMicrotask || function (fn) {
|
|
1479
|
+
var task = { fn: fn, next: undefined };
|
|
1480
|
+
if (last) last.next = task;
|
|
1481
|
+
if (!head) {
|
|
1482
|
+
head = task;
|
|
1483
|
+
notify$1();
|
|
1484
|
+
} last = task;
|
|
1485
|
+
};
|
|
1486
|
+
|
|
1487
|
+
var global$4 = global$i;
|
|
1488
|
+
|
|
1489
|
+
var hostReportErrors$1 = function (a, b) {
|
|
1490
|
+
var console = global$4.console;
|
|
1491
|
+
if (console && console.error) {
|
|
1492
|
+
arguments.length == 1 ? console.error(a) : console.error(a, b);
|
|
1493
|
+
}
|
|
1494
|
+
};
|
|
1495
|
+
|
|
1496
|
+
var perform$3 = function (exec) {
|
|
1497
|
+
try {
|
|
1498
|
+
return { error: false, value: exec() };
|
|
1499
|
+
} catch (error) {
|
|
1500
|
+
return { error: true, value: error };
|
|
1501
|
+
}
|
|
1502
|
+
};
|
|
1503
|
+
|
|
1504
|
+
var Queue$1 = function () {
|
|
1505
|
+
this.head = null;
|
|
1506
|
+
this.tail = null;
|
|
1507
|
+
};
|
|
1508
|
+
|
|
1509
|
+
Queue$1.prototype = {
|
|
1510
|
+
add: function (item) {
|
|
1511
|
+
var entry = { item: item, next: null };
|
|
1512
|
+
if (this.head) this.tail.next = entry;
|
|
1513
|
+
else this.head = entry;
|
|
1514
|
+
this.tail = entry;
|
|
1515
|
+
},
|
|
1516
|
+
get: function () {
|
|
1517
|
+
var entry = this.head;
|
|
1518
|
+
if (entry) {
|
|
1519
|
+
this.head = entry.next;
|
|
1520
|
+
if (this.tail === entry) this.tail = null;
|
|
1521
|
+
return entry.item;
|
|
1522
|
+
}
|
|
1523
|
+
}
|
|
1524
|
+
};
|
|
1525
|
+
|
|
1526
|
+
var queue = Queue$1;
|
|
1527
|
+
|
|
1528
|
+
var global$3 = global$i;
|
|
1529
|
+
|
|
1530
|
+
var promiseNativeConstructor = global$3.Promise;
|
|
1531
|
+
|
|
1532
|
+
/* global Deno -- Deno case */
|
|
1533
|
+
|
|
1534
|
+
var engineIsDeno = typeof Deno == 'object' && Deno && typeof Deno.version == 'object';
|
|
1535
|
+
|
|
1536
|
+
var IS_DENO$1 = engineIsDeno;
|
|
1537
|
+
var IS_NODE$1 = engineIsNode;
|
|
1538
|
+
|
|
1539
|
+
var engineIsBrowser = !IS_DENO$1 && !IS_NODE$1
|
|
1540
|
+
&& typeof window == 'object'
|
|
1541
|
+
&& typeof document == 'object';
|
|
1542
|
+
|
|
1543
|
+
var global$2 = global$i;
|
|
1544
|
+
var NativePromiseConstructor$3 = promiseNativeConstructor;
|
|
1545
|
+
var isCallable$2 = isCallable$h;
|
|
1546
|
+
var isForced = isForced_1;
|
|
1547
|
+
var inspectSource = inspectSource$3;
|
|
1548
|
+
var wellKnownSymbol$3 = wellKnownSymbol$a;
|
|
1549
|
+
var IS_BROWSER = engineIsBrowser;
|
|
1550
|
+
var IS_DENO = engineIsDeno;
|
|
1551
|
+
var V8_VERSION = engineV8Version;
|
|
1552
|
+
|
|
1553
|
+
NativePromiseConstructor$3 && NativePromiseConstructor$3.prototype;
|
|
1554
|
+
var SPECIES = wellKnownSymbol$3('species');
|
|
1555
|
+
var SUBCLASSING = false;
|
|
1556
|
+
var NATIVE_PROMISE_REJECTION_EVENT$1 = isCallable$2(global$2.PromiseRejectionEvent);
|
|
1557
|
+
|
|
1558
|
+
var FORCED_PROMISE_CONSTRUCTOR$5 = isForced('Promise', function () {
|
|
1559
|
+
var PROMISE_CONSTRUCTOR_SOURCE = inspectSource(NativePromiseConstructor$3);
|
|
1560
|
+
var GLOBAL_CORE_JS_PROMISE = PROMISE_CONSTRUCTOR_SOURCE !== String(NativePromiseConstructor$3);
|
|
1561
|
+
// V8 6.6 (Node 10 and Chrome 66) have a bug with resolving custom thenables
|
|
1562
|
+
// https://bugs.chromium.org/p/chromium/issues/detail?id=830565
|
|
1563
|
+
// We can't detect it synchronously, so just check versions
|
|
1564
|
+
if (!GLOBAL_CORE_JS_PROMISE && V8_VERSION === 66) return true;
|
|
1565
|
+
// We can't use @@species feature detection in V8 since it causes
|
|
1566
|
+
// deoptimization and performance degradation
|
|
1567
|
+
// https://github.com/zloirock/core-js/issues/679
|
|
1568
|
+
if (!V8_VERSION || V8_VERSION < 51 || !/native code/.test(PROMISE_CONSTRUCTOR_SOURCE)) {
|
|
1569
|
+
// Detect correctness of subclassing with @@species support
|
|
1570
|
+
var promise = new NativePromiseConstructor$3(function (resolve) { resolve(1); });
|
|
1571
|
+
var FakePromise = function (exec) {
|
|
1572
|
+
exec(function () { /* empty */ }, function () { /* empty */ });
|
|
1573
|
+
};
|
|
1574
|
+
var constructor = promise.constructor = {};
|
|
1575
|
+
constructor[SPECIES] = FakePromise;
|
|
1576
|
+
SUBCLASSING = promise.then(function () { /* empty */ }) instanceof FakePromise;
|
|
1577
|
+
if (!SUBCLASSING) return true;
|
|
1578
|
+
// Unhandled rejections tracking support, NodeJS Promise without it fails @@species test
|
|
1579
|
+
} return !GLOBAL_CORE_JS_PROMISE && (IS_BROWSER || IS_DENO) && !NATIVE_PROMISE_REJECTION_EVENT$1;
|
|
1580
|
+
});
|
|
1581
|
+
|
|
1582
|
+
var promiseConstructorDetection = {
|
|
1583
|
+
CONSTRUCTOR: FORCED_PROMISE_CONSTRUCTOR$5,
|
|
1584
|
+
REJECTION_EVENT: NATIVE_PROMISE_REJECTION_EVENT$1,
|
|
1585
|
+
SUBCLASSING: SUBCLASSING
|
|
1586
|
+
};
|
|
1587
|
+
|
|
1588
|
+
var newPromiseCapability$2 = {};
|
|
1589
|
+
|
|
1590
|
+
var aCallable$4 = aCallable$7;
|
|
1591
|
+
|
|
1592
|
+
var $TypeError$2 = TypeError;
|
|
1593
|
+
|
|
1594
|
+
var PromiseCapability = function (C) {
|
|
1595
|
+
var resolve, reject;
|
|
1596
|
+
this.promise = new C(function ($$resolve, $$reject) {
|
|
1597
|
+
if (resolve !== undefined || reject !== undefined) throw $TypeError$2('Bad Promise constructor');
|
|
1598
|
+
resolve = $$resolve;
|
|
1599
|
+
reject = $$reject;
|
|
1600
|
+
});
|
|
1601
|
+
this.resolve = aCallable$4(resolve);
|
|
1602
|
+
this.reject = aCallable$4(reject);
|
|
1603
|
+
};
|
|
1604
|
+
|
|
1605
|
+
// `NewPromiseCapability` abstract operation
|
|
1606
|
+
// https://tc39.es/ecma262/#sec-newpromisecapability
|
|
1607
|
+
newPromiseCapability$2.f = function (C) {
|
|
1608
|
+
return new PromiseCapability(C);
|
|
1609
|
+
};
|
|
1610
|
+
|
|
1611
|
+
var $$5 = _export;
|
|
1612
|
+
var IS_NODE = engineIsNode;
|
|
1613
|
+
var global$1 = global$i;
|
|
1614
|
+
var call$6 = functionCall;
|
|
1615
|
+
var defineBuiltIn$1 = defineBuiltIn$3;
|
|
1616
|
+
var setPrototypeOf = objectSetPrototypeOf;
|
|
1617
|
+
var setToStringTag = setToStringTag$1;
|
|
1618
|
+
var setSpecies = setSpecies$1;
|
|
1619
|
+
var aCallable$3 = aCallable$7;
|
|
1620
|
+
var isCallable$1 = isCallable$h;
|
|
1621
|
+
var isObject$1 = isObject$7;
|
|
1622
|
+
var anInstance = anInstance$1;
|
|
1623
|
+
var speciesConstructor = speciesConstructor$1;
|
|
1624
|
+
var task = task$1.set;
|
|
1625
|
+
var microtask = microtask$1;
|
|
1626
|
+
var hostReportErrors = hostReportErrors$1;
|
|
1627
|
+
var perform$2 = perform$3;
|
|
1628
|
+
var Queue = queue;
|
|
1629
|
+
var InternalStateModule = internalState;
|
|
1630
|
+
var NativePromiseConstructor$2 = promiseNativeConstructor;
|
|
1631
|
+
var PromiseConstructorDetection = promiseConstructorDetection;
|
|
1632
|
+
var newPromiseCapabilityModule$3 = newPromiseCapability$2;
|
|
1633
|
+
|
|
1634
|
+
var PROMISE = 'Promise';
|
|
1635
|
+
var FORCED_PROMISE_CONSTRUCTOR$4 = PromiseConstructorDetection.CONSTRUCTOR;
|
|
1636
|
+
var NATIVE_PROMISE_REJECTION_EVENT = PromiseConstructorDetection.REJECTION_EVENT;
|
|
1637
|
+
var NATIVE_PROMISE_SUBCLASSING = PromiseConstructorDetection.SUBCLASSING;
|
|
1638
|
+
var getInternalPromiseState = InternalStateModule.getterFor(PROMISE);
|
|
1639
|
+
var setInternalState = InternalStateModule.set;
|
|
1640
|
+
var NativePromisePrototype$1 = NativePromiseConstructor$2 && NativePromiseConstructor$2.prototype;
|
|
1641
|
+
var PromiseConstructor = NativePromiseConstructor$2;
|
|
1642
|
+
var PromisePrototype = NativePromisePrototype$1;
|
|
1643
|
+
var TypeError$1 = global$1.TypeError;
|
|
1644
|
+
var document$1 = global$1.document;
|
|
1645
|
+
var process = global$1.process;
|
|
1646
|
+
var newPromiseCapability$1 = newPromiseCapabilityModule$3.f;
|
|
1647
|
+
var newGenericPromiseCapability = newPromiseCapability$1;
|
|
1648
|
+
|
|
1649
|
+
var DISPATCH_EVENT = !!(document$1 && document$1.createEvent && global$1.dispatchEvent);
|
|
1650
|
+
var UNHANDLED_REJECTION = 'unhandledrejection';
|
|
1651
|
+
var REJECTION_HANDLED = 'rejectionhandled';
|
|
1652
|
+
var PENDING = 0;
|
|
1653
|
+
var FULFILLED = 1;
|
|
1654
|
+
var REJECTED = 2;
|
|
1655
|
+
var HANDLED = 1;
|
|
1656
|
+
var UNHANDLED = 2;
|
|
1657
|
+
|
|
1658
|
+
var Internal, OwnPromiseCapability, PromiseWrapper, nativeThen;
|
|
1659
|
+
|
|
1660
|
+
// helpers
|
|
1661
|
+
var isThenable = function (it) {
|
|
1662
|
+
var then;
|
|
1663
|
+
return isObject$1(it) && isCallable$1(then = it.then) ? then : false;
|
|
1664
|
+
};
|
|
1665
|
+
|
|
1666
|
+
var callReaction = function (reaction, state) {
|
|
1667
|
+
var value = state.value;
|
|
1668
|
+
var ok = state.state == FULFILLED;
|
|
1669
|
+
var handler = ok ? reaction.ok : reaction.fail;
|
|
1670
|
+
var resolve = reaction.resolve;
|
|
1671
|
+
var reject = reaction.reject;
|
|
1672
|
+
var domain = reaction.domain;
|
|
1673
|
+
var result, then, exited;
|
|
1674
|
+
try {
|
|
1675
|
+
if (handler) {
|
|
1676
|
+
if (!ok) {
|
|
1677
|
+
if (state.rejection === UNHANDLED) onHandleUnhandled(state);
|
|
1678
|
+
state.rejection = HANDLED;
|
|
1679
|
+
}
|
|
1680
|
+
if (handler === true) result = value;
|
|
1681
|
+
else {
|
|
1682
|
+
if (domain) domain.enter();
|
|
1683
|
+
result = handler(value); // can throw
|
|
1684
|
+
if (domain) {
|
|
1685
|
+
domain.exit();
|
|
1686
|
+
exited = true;
|
|
1687
|
+
}
|
|
1688
|
+
}
|
|
1689
|
+
if (result === reaction.promise) {
|
|
1690
|
+
reject(TypeError$1('Promise-chain cycle'));
|
|
1691
|
+
} else if (then = isThenable(result)) {
|
|
1692
|
+
call$6(then, result, resolve, reject);
|
|
1693
|
+
} else resolve(result);
|
|
1694
|
+
} else reject(value);
|
|
1695
|
+
} catch (error) {
|
|
1696
|
+
if (domain && !exited) domain.exit();
|
|
1697
|
+
reject(error);
|
|
1698
|
+
}
|
|
1699
|
+
};
|
|
1700
|
+
|
|
1701
|
+
var notify = function (state, isReject) {
|
|
1702
|
+
if (state.notified) return;
|
|
1703
|
+
state.notified = true;
|
|
1704
|
+
microtask(function () {
|
|
1705
|
+
var reactions = state.reactions;
|
|
1706
|
+
var reaction;
|
|
1707
|
+
while (reaction = reactions.get()) {
|
|
1708
|
+
callReaction(reaction, state);
|
|
1709
|
+
}
|
|
1710
|
+
state.notified = false;
|
|
1711
|
+
if (isReject && !state.rejection) onUnhandled(state);
|
|
1712
|
+
});
|
|
1713
|
+
};
|
|
1714
|
+
|
|
1715
|
+
var dispatchEvent = function (name, promise, reason) {
|
|
1716
|
+
var event, handler;
|
|
1717
|
+
if (DISPATCH_EVENT) {
|
|
1718
|
+
event = document$1.createEvent('Event');
|
|
1719
|
+
event.promise = promise;
|
|
1720
|
+
event.reason = reason;
|
|
1721
|
+
event.initEvent(name, false, true);
|
|
1722
|
+
global$1.dispatchEvent(event);
|
|
1723
|
+
} else event = { promise: promise, reason: reason };
|
|
1724
|
+
if (!NATIVE_PROMISE_REJECTION_EVENT && (handler = global$1['on' + name])) handler(event);
|
|
1725
|
+
else if (name === UNHANDLED_REJECTION) hostReportErrors('Unhandled promise rejection', reason);
|
|
1726
|
+
};
|
|
1727
|
+
|
|
1728
|
+
var onUnhandled = function (state) {
|
|
1729
|
+
call$6(task, global$1, function () {
|
|
1730
|
+
var promise = state.facade;
|
|
1731
|
+
var value = state.value;
|
|
1732
|
+
var IS_UNHANDLED = isUnhandled(state);
|
|
1733
|
+
var result;
|
|
1734
|
+
if (IS_UNHANDLED) {
|
|
1735
|
+
result = perform$2(function () {
|
|
1736
|
+
if (IS_NODE) {
|
|
1737
|
+
process.emit('unhandledRejection', value, promise);
|
|
1738
|
+
} else dispatchEvent(UNHANDLED_REJECTION, promise, value);
|
|
1055
1739
|
});
|
|
1740
|
+
// Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should
|
|
1741
|
+
state.rejection = IS_NODE || isUnhandled(state) ? UNHANDLED : HANDLED;
|
|
1742
|
+
if (result.error) throw result.value;
|
|
1056
1743
|
}
|
|
1057
|
-
})
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1744
|
+
});
|
|
1745
|
+
};
|
|
1746
|
+
|
|
1747
|
+
var isUnhandled = function (state) {
|
|
1748
|
+
return state.rejection !== HANDLED && !state.parent;
|
|
1749
|
+
};
|
|
1750
|
+
|
|
1751
|
+
var onHandleUnhandled = function (state) {
|
|
1752
|
+
call$6(task, global$1, function () {
|
|
1753
|
+
var promise = state.facade;
|
|
1754
|
+
if (IS_NODE) {
|
|
1755
|
+
process.emit('rejectionHandled', promise);
|
|
1756
|
+
} else dispatchEvent(REJECTION_HANDLED, promise, state.value);
|
|
1757
|
+
});
|
|
1758
|
+
};
|
|
1759
|
+
|
|
1760
|
+
var bind$1 = function (fn, state, unwrap) {
|
|
1761
|
+
return function (value) {
|
|
1762
|
+
fn(state, value, unwrap);
|
|
1763
|
+
};
|
|
1764
|
+
};
|
|
1765
|
+
|
|
1766
|
+
var internalReject = function (state, value, unwrap) {
|
|
1767
|
+
if (state.done) return;
|
|
1768
|
+
state.done = true;
|
|
1769
|
+
if (unwrap) state = unwrap;
|
|
1770
|
+
state.value = value;
|
|
1771
|
+
state.state = REJECTED;
|
|
1772
|
+
notify(state, true);
|
|
1773
|
+
};
|
|
1774
|
+
|
|
1775
|
+
var internalResolve = function (state, value, unwrap) {
|
|
1776
|
+
if (state.done) return;
|
|
1777
|
+
state.done = true;
|
|
1778
|
+
if (unwrap) state = unwrap;
|
|
1779
|
+
try {
|
|
1780
|
+
if (state.facade === value) throw TypeError$1("Promise can't be resolved itself");
|
|
1781
|
+
var then = isThenable(value);
|
|
1782
|
+
if (then) {
|
|
1783
|
+
microtask(function () {
|
|
1784
|
+
var wrapper = { done: false };
|
|
1785
|
+
try {
|
|
1786
|
+
call$6(then, value,
|
|
1787
|
+
bind$1(internalResolve, wrapper, state),
|
|
1788
|
+
bind$1(internalReject, wrapper, state)
|
|
1789
|
+
);
|
|
1790
|
+
} catch (error) {
|
|
1791
|
+
internalReject(wrapper, error, state);
|
|
1792
|
+
}
|
|
1793
|
+
});
|
|
1794
|
+
} else {
|
|
1795
|
+
state.value = value;
|
|
1796
|
+
state.state = FULFILLED;
|
|
1797
|
+
notify(state, false);
|
|
1798
|
+
}
|
|
1799
|
+
} catch (error) {
|
|
1800
|
+
internalReject({ done: false }, error, state);
|
|
1801
|
+
}
|
|
1802
|
+
};
|
|
1803
|
+
|
|
1804
|
+
// constructor polyfill
|
|
1805
|
+
if (FORCED_PROMISE_CONSTRUCTOR$4) {
|
|
1806
|
+
// 25.4.3.1 Promise(executor)
|
|
1807
|
+
PromiseConstructor = function Promise(executor) {
|
|
1808
|
+
anInstance(this, PromisePrototype);
|
|
1809
|
+
aCallable$3(executor);
|
|
1810
|
+
call$6(Internal, this);
|
|
1811
|
+
var state = getInternalPromiseState(this);
|
|
1812
|
+
try {
|
|
1813
|
+
executor(bind$1(internalResolve, state), bind$1(internalReject, state));
|
|
1814
|
+
} catch (error) {
|
|
1815
|
+
internalReject(state, error);
|
|
1816
|
+
}
|
|
1817
|
+
};
|
|
1818
|
+
|
|
1819
|
+
PromisePrototype = PromiseConstructor.prototype;
|
|
1820
|
+
|
|
1821
|
+
// eslint-disable-next-line no-unused-vars -- required for `.length`
|
|
1822
|
+
Internal = function Promise(executor) {
|
|
1823
|
+
setInternalState(this, {
|
|
1824
|
+
type: PROMISE,
|
|
1825
|
+
done: false,
|
|
1826
|
+
notified: false,
|
|
1827
|
+
parent: false,
|
|
1828
|
+
reactions: new Queue(),
|
|
1829
|
+
rejection: false,
|
|
1830
|
+
state: PENDING,
|
|
1831
|
+
value: undefined
|
|
1832
|
+
});
|
|
1833
|
+
};
|
|
1834
|
+
|
|
1835
|
+
// `Promise.prototype.then` method
|
|
1836
|
+
// https://tc39.es/ecma262/#sec-promise.prototype.then
|
|
1837
|
+
Internal.prototype = defineBuiltIn$1(PromisePrototype, 'then', function then(onFulfilled, onRejected) {
|
|
1838
|
+
var state = getInternalPromiseState(this);
|
|
1839
|
+
var reaction = newPromiseCapability$1(speciesConstructor(this, PromiseConstructor));
|
|
1840
|
+
state.parent = true;
|
|
1841
|
+
reaction.ok = isCallable$1(onFulfilled) ? onFulfilled : true;
|
|
1842
|
+
reaction.fail = isCallable$1(onRejected) && onRejected;
|
|
1843
|
+
reaction.domain = IS_NODE ? process.domain : undefined;
|
|
1844
|
+
if (state.state == PENDING) state.reactions.add(reaction);
|
|
1845
|
+
else microtask(function () {
|
|
1846
|
+
callReaction(reaction, state);
|
|
1847
|
+
});
|
|
1848
|
+
return reaction.promise;
|
|
1849
|
+
});
|
|
1850
|
+
|
|
1851
|
+
OwnPromiseCapability = function () {
|
|
1852
|
+
var promise = new Internal();
|
|
1853
|
+
var state = getInternalPromiseState(promise);
|
|
1854
|
+
this.promise = promise;
|
|
1855
|
+
this.resolve = bind$1(internalResolve, state);
|
|
1856
|
+
this.reject = bind$1(internalReject, state);
|
|
1857
|
+
};
|
|
1858
|
+
|
|
1859
|
+
newPromiseCapabilityModule$3.f = newPromiseCapability$1 = function (C) {
|
|
1860
|
+
return C === PromiseConstructor || C === PromiseWrapper
|
|
1861
|
+
? new OwnPromiseCapability(C)
|
|
1862
|
+
: newGenericPromiseCapability(C);
|
|
1863
|
+
};
|
|
1864
|
+
|
|
1865
|
+
if (isCallable$1(NativePromiseConstructor$2) && NativePromisePrototype$1 !== Object.prototype) {
|
|
1866
|
+
nativeThen = NativePromisePrototype$1.then;
|
|
1867
|
+
|
|
1868
|
+
if (!NATIVE_PROMISE_SUBCLASSING) {
|
|
1869
|
+
// make `Promise#then` return a polyfilled `Promise` for native promise-based APIs
|
|
1870
|
+
defineBuiltIn$1(NativePromisePrototype$1, 'then', function then(onFulfilled, onRejected) {
|
|
1871
|
+
var that = this;
|
|
1872
|
+
return new PromiseConstructor(function (resolve, reject) {
|
|
1873
|
+
call$6(nativeThen, that, resolve, reject);
|
|
1874
|
+
}).then(onFulfilled, onRejected);
|
|
1875
|
+
// https://github.com/zloirock/core-js/issues/640
|
|
1876
|
+
}, { unsafe: true });
|
|
1877
|
+
}
|
|
1878
|
+
|
|
1879
|
+
// make `.constructor === Promise` work for native promise-based APIs
|
|
1880
|
+
try {
|
|
1881
|
+
delete NativePromisePrototype$1.constructor;
|
|
1882
|
+
} catch (error) { /* empty */ }
|
|
1883
|
+
|
|
1884
|
+
// make `instanceof Promise` work for native promise-based APIs
|
|
1885
|
+
if (setPrototypeOf) {
|
|
1886
|
+
setPrototypeOf(NativePromisePrototype$1, PromisePrototype);
|
|
1887
|
+
}
|
|
1888
|
+
}
|
|
1889
|
+
}
|
|
1890
|
+
|
|
1891
|
+
$$5({ global: true, constructor: true, wrap: true, forced: FORCED_PROMISE_CONSTRUCTOR$4 }, {
|
|
1892
|
+
Promise: PromiseConstructor
|
|
1893
|
+
});
|
|
1894
|
+
|
|
1895
|
+
setToStringTag(PromiseConstructor, PROMISE, false);
|
|
1896
|
+
setSpecies(PROMISE);
|
|
1897
|
+
|
|
1898
|
+
var iterators = {};
|
|
1899
|
+
|
|
1900
|
+
var wellKnownSymbol$2 = wellKnownSymbol$a;
|
|
1901
|
+
var Iterators$1 = iterators;
|
|
1902
|
+
|
|
1903
|
+
var ITERATOR$2 = wellKnownSymbol$2('iterator');
|
|
1904
|
+
var ArrayPrototype = Array.prototype;
|
|
1905
|
+
|
|
1906
|
+
// check on default Array iterator
|
|
1907
|
+
var isArrayIteratorMethod$1 = function (it) {
|
|
1908
|
+
return it !== undefined && (Iterators$1.Array === it || ArrayPrototype[ITERATOR$2] === it);
|
|
1909
|
+
};
|
|
1910
|
+
|
|
1911
|
+
var classof = classof$2;
|
|
1912
|
+
var getMethod$1 = getMethod$3;
|
|
1913
|
+
var isNullOrUndefined = isNullOrUndefined$4;
|
|
1914
|
+
var Iterators = iterators;
|
|
1915
|
+
var wellKnownSymbol$1 = wellKnownSymbol$a;
|
|
1916
|
+
|
|
1917
|
+
var ITERATOR$1 = wellKnownSymbol$1('iterator');
|
|
1918
|
+
|
|
1919
|
+
var getIteratorMethod$2 = function (it) {
|
|
1920
|
+
if (!isNullOrUndefined(it)) return getMethod$1(it, ITERATOR$1)
|
|
1921
|
+
|| getMethod$1(it, '@@iterator')
|
|
1922
|
+
|| Iterators[classof(it)];
|
|
1923
|
+
};
|
|
1924
|
+
|
|
1925
|
+
var call$5 = functionCall;
|
|
1926
|
+
var aCallable$2 = aCallable$7;
|
|
1927
|
+
var anObject$3 = anObject$8;
|
|
1928
|
+
var tryToString$1 = tryToString$4;
|
|
1929
|
+
var getIteratorMethod$1 = getIteratorMethod$2;
|
|
1930
|
+
|
|
1931
|
+
var $TypeError$1 = TypeError;
|
|
1932
|
+
|
|
1933
|
+
var getIterator$1 = function (argument, usingIterator) {
|
|
1934
|
+
var iteratorMethod = arguments.length < 2 ? getIteratorMethod$1(argument) : usingIterator;
|
|
1935
|
+
if (aCallable$2(iteratorMethod)) return anObject$3(call$5(iteratorMethod, argument));
|
|
1936
|
+
throw $TypeError$1(tryToString$1(argument) + ' is not iterable');
|
|
1937
|
+
};
|
|
1938
|
+
|
|
1939
|
+
var call$4 = functionCall;
|
|
1940
|
+
var anObject$2 = anObject$8;
|
|
1941
|
+
var getMethod = getMethod$3;
|
|
1942
|
+
|
|
1943
|
+
var iteratorClose$1 = function (iterator, kind, value) {
|
|
1944
|
+
var innerResult, innerError;
|
|
1945
|
+
anObject$2(iterator);
|
|
1946
|
+
try {
|
|
1947
|
+
innerResult = getMethod(iterator, 'return');
|
|
1948
|
+
if (!innerResult) {
|
|
1949
|
+
if (kind === 'throw') throw value;
|
|
1950
|
+
return value;
|
|
1951
|
+
}
|
|
1952
|
+
innerResult = call$4(innerResult, iterator);
|
|
1953
|
+
} catch (error) {
|
|
1954
|
+
innerError = true;
|
|
1955
|
+
innerResult = error;
|
|
1956
|
+
}
|
|
1957
|
+
if (kind === 'throw') throw value;
|
|
1958
|
+
if (innerError) throw innerResult;
|
|
1959
|
+
anObject$2(innerResult);
|
|
1960
|
+
return value;
|
|
1961
|
+
};
|
|
1962
|
+
|
|
1963
|
+
var bind = functionBindContext;
|
|
1964
|
+
var call$3 = functionCall;
|
|
1965
|
+
var anObject$1 = anObject$8;
|
|
1966
|
+
var tryToString = tryToString$4;
|
|
1967
|
+
var isArrayIteratorMethod = isArrayIteratorMethod$1;
|
|
1968
|
+
var lengthOfArrayLike = lengthOfArrayLike$2;
|
|
1969
|
+
var isPrototypeOf = objectIsPrototypeOf;
|
|
1970
|
+
var getIterator = getIterator$1;
|
|
1971
|
+
var getIteratorMethod = getIteratorMethod$2;
|
|
1972
|
+
var iteratorClose = iteratorClose$1;
|
|
1973
|
+
|
|
1974
|
+
var $TypeError = TypeError;
|
|
1975
|
+
|
|
1976
|
+
var Result = function (stopped, result) {
|
|
1977
|
+
this.stopped = stopped;
|
|
1978
|
+
this.result = result;
|
|
1979
|
+
};
|
|
1980
|
+
|
|
1981
|
+
var ResultPrototype = Result.prototype;
|
|
1982
|
+
|
|
1983
|
+
var iterate$2 = function (iterable, unboundFunction, options) {
|
|
1984
|
+
var that = options && options.that;
|
|
1985
|
+
var AS_ENTRIES = !!(options && options.AS_ENTRIES);
|
|
1986
|
+
var IS_RECORD = !!(options && options.IS_RECORD);
|
|
1987
|
+
var IS_ITERATOR = !!(options && options.IS_ITERATOR);
|
|
1988
|
+
var INTERRUPTED = !!(options && options.INTERRUPTED);
|
|
1989
|
+
var fn = bind(unboundFunction, that);
|
|
1990
|
+
var iterator, iterFn, index, length, result, next, step;
|
|
1991
|
+
|
|
1992
|
+
var stop = function (condition) {
|
|
1993
|
+
if (iterator) iteratorClose(iterator, 'normal', condition);
|
|
1994
|
+
return new Result(true, condition);
|
|
1995
|
+
};
|
|
1996
|
+
|
|
1997
|
+
var callFn = function (value) {
|
|
1998
|
+
if (AS_ENTRIES) {
|
|
1999
|
+
anObject$1(value);
|
|
2000
|
+
return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);
|
|
2001
|
+
} return INTERRUPTED ? fn(value, stop) : fn(value);
|
|
2002
|
+
};
|
|
2003
|
+
|
|
2004
|
+
if (IS_RECORD) {
|
|
2005
|
+
iterator = iterable.iterator;
|
|
2006
|
+
} else if (IS_ITERATOR) {
|
|
2007
|
+
iterator = iterable;
|
|
2008
|
+
} else {
|
|
2009
|
+
iterFn = getIteratorMethod(iterable);
|
|
2010
|
+
if (!iterFn) throw $TypeError(tryToString(iterable) + ' is not iterable');
|
|
2011
|
+
// optimisation for array iterators
|
|
2012
|
+
if (isArrayIteratorMethod(iterFn)) {
|
|
2013
|
+
for (index = 0, length = lengthOfArrayLike(iterable); length > index; index++) {
|
|
2014
|
+
result = callFn(iterable[index]);
|
|
2015
|
+
if (result && isPrototypeOf(ResultPrototype, result)) return result;
|
|
2016
|
+
} return new Result(false);
|
|
1082
2017
|
}
|
|
1083
|
-
|
|
1084
|
-
}
|
|
2018
|
+
iterator = getIterator(iterable, iterFn);
|
|
2019
|
+
}
|
|
2020
|
+
|
|
2021
|
+
next = IS_RECORD ? iterable.next : iterator.next;
|
|
2022
|
+
while (!(step = call$3(next, iterator)).done) {
|
|
2023
|
+
try {
|
|
2024
|
+
result = callFn(step.value);
|
|
2025
|
+
} catch (error) {
|
|
2026
|
+
iteratorClose(iterator, 'throw', error);
|
|
2027
|
+
}
|
|
2028
|
+
if (typeof result == 'object' && result && isPrototypeOf(ResultPrototype, result)) return result;
|
|
2029
|
+
} return new Result(false);
|
|
2030
|
+
};
|
|
2031
|
+
|
|
2032
|
+
var wellKnownSymbol = wellKnownSymbol$a;
|
|
2033
|
+
|
|
2034
|
+
var ITERATOR = wellKnownSymbol('iterator');
|
|
2035
|
+
var SAFE_CLOSING = false;
|
|
2036
|
+
|
|
2037
|
+
try {
|
|
2038
|
+
var called = 0;
|
|
2039
|
+
var iteratorWithReturn = {
|
|
2040
|
+
next: function () {
|
|
2041
|
+
return { done: !!called++ };
|
|
2042
|
+
},
|
|
2043
|
+
'return': function () {
|
|
2044
|
+
SAFE_CLOSING = true;
|
|
2045
|
+
}
|
|
2046
|
+
};
|
|
2047
|
+
iteratorWithReturn[ITERATOR] = function () {
|
|
2048
|
+
return this;
|
|
2049
|
+
};
|
|
2050
|
+
// eslint-disable-next-line es/no-array-from, no-throw-literal -- required for testing
|
|
2051
|
+
Array.from(iteratorWithReturn, function () { throw 2; });
|
|
2052
|
+
} catch (error) { /* empty */ }
|
|
2053
|
+
|
|
2054
|
+
var checkCorrectnessOfIteration$1 = function (exec, SKIP_CLOSING) {
|
|
2055
|
+
if (!SKIP_CLOSING && !SAFE_CLOSING) return false;
|
|
2056
|
+
var ITERATION_SUPPORT = false;
|
|
2057
|
+
try {
|
|
2058
|
+
var object = {};
|
|
2059
|
+
object[ITERATOR] = function () {
|
|
2060
|
+
return {
|
|
2061
|
+
next: function () {
|
|
2062
|
+
return { done: ITERATION_SUPPORT = true };
|
|
2063
|
+
}
|
|
2064
|
+
};
|
|
2065
|
+
};
|
|
2066
|
+
exec(object);
|
|
2067
|
+
} catch (error) { /* empty */ }
|
|
2068
|
+
return ITERATION_SUPPORT;
|
|
2069
|
+
};
|
|
2070
|
+
|
|
2071
|
+
var NativePromiseConstructor$1 = promiseNativeConstructor;
|
|
2072
|
+
var checkCorrectnessOfIteration = checkCorrectnessOfIteration$1;
|
|
2073
|
+
var FORCED_PROMISE_CONSTRUCTOR$3 = promiseConstructorDetection.CONSTRUCTOR;
|
|
2074
|
+
|
|
2075
|
+
var promiseStaticsIncorrectIteration = FORCED_PROMISE_CONSTRUCTOR$3 || !checkCorrectnessOfIteration(function (iterable) {
|
|
2076
|
+
NativePromiseConstructor$1.all(iterable).then(undefined, function () { /* empty */ });
|
|
2077
|
+
});
|
|
2078
|
+
|
|
2079
|
+
var $$4 = _export;
|
|
2080
|
+
var call$2 = functionCall;
|
|
2081
|
+
var aCallable$1 = aCallable$7;
|
|
2082
|
+
var newPromiseCapabilityModule$2 = newPromiseCapability$2;
|
|
2083
|
+
var perform$1 = perform$3;
|
|
2084
|
+
var iterate$1 = iterate$2;
|
|
2085
|
+
var PROMISE_STATICS_INCORRECT_ITERATION$1 = promiseStaticsIncorrectIteration;
|
|
2086
|
+
|
|
2087
|
+
// `Promise.all` method
|
|
2088
|
+
// https://tc39.es/ecma262/#sec-promise.all
|
|
2089
|
+
$$4({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION$1 }, {
|
|
2090
|
+
all: function all(iterable) {
|
|
2091
|
+
var C = this;
|
|
2092
|
+
var capability = newPromiseCapabilityModule$2.f(C);
|
|
2093
|
+
var resolve = capability.resolve;
|
|
2094
|
+
var reject = capability.reject;
|
|
2095
|
+
var result = perform$1(function () {
|
|
2096
|
+
var $promiseResolve = aCallable$1(C.resolve);
|
|
2097
|
+
var values = [];
|
|
2098
|
+
var counter = 0;
|
|
2099
|
+
var remaining = 1;
|
|
2100
|
+
iterate$1(iterable, function (promise) {
|
|
2101
|
+
var index = counter++;
|
|
2102
|
+
var alreadyCalled = false;
|
|
2103
|
+
remaining++;
|
|
2104
|
+
call$2($promiseResolve, C, promise).then(function (value) {
|
|
2105
|
+
if (alreadyCalled) return;
|
|
2106
|
+
alreadyCalled = true;
|
|
2107
|
+
values[index] = value;
|
|
2108
|
+
--remaining || resolve(values);
|
|
2109
|
+
}, reject);
|
|
2110
|
+
});
|
|
2111
|
+
--remaining || resolve(values);
|
|
2112
|
+
});
|
|
2113
|
+
if (result.error) reject(result.value);
|
|
2114
|
+
return capability.promise;
|
|
2115
|
+
}
|
|
2116
|
+
});
|
|
2117
|
+
|
|
2118
|
+
var $$3 = _export;
|
|
2119
|
+
var FORCED_PROMISE_CONSTRUCTOR$2 = promiseConstructorDetection.CONSTRUCTOR;
|
|
2120
|
+
var NativePromiseConstructor = promiseNativeConstructor;
|
|
2121
|
+
var getBuiltIn$1 = getBuiltIn$8;
|
|
2122
|
+
var isCallable = isCallable$h;
|
|
2123
|
+
var defineBuiltIn = defineBuiltIn$3;
|
|
2124
|
+
|
|
2125
|
+
var NativePromisePrototype = NativePromiseConstructor && NativePromiseConstructor.prototype;
|
|
2126
|
+
|
|
2127
|
+
// `Promise.prototype.catch` method
|
|
2128
|
+
// https://tc39.es/ecma262/#sec-promise.prototype.catch
|
|
2129
|
+
$$3({ target: 'Promise', proto: true, forced: FORCED_PROMISE_CONSTRUCTOR$2, real: true }, {
|
|
2130
|
+
'catch': function (onRejected) {
|
|
2131
|
+
return this.then(undefined, onRejected);
|
|
2132
|
+
}
|
|
2133
|
+
});
|
|
2134
|
+
|
|
2135
|
+
// makes sure that native promise-based APIs `Promise#catch` properly works with patched `Promise#then`
|
|
2136
|
+
if (isCallable(NativePromiseConstructor)) {
|
|
2137
|
+
var method = getBuiltIn$1('Promise').prototype['catch'];
|
|
2138
|
+
if (NativePromisePrototype['catch'] !== method) {
|
|
2139
|
+
defineBuiltIn(NativePromisePrototype, 'catch', method, { unsafe: true });
|
|
2140
|
+
}
|
|
2141
|
+
}
|
|
2142
|
+
|
|
2143
|
+
var $$2 = _export;
|
|
2144
|
+
var call$1 = functionCall;
|
|
2145
|
+
var aCallable = aCallable$7;
|
|
2146
|
+
var newPromiseCapabilityModule$1 = newPromiseCapability$2;
|
|
2147
|
+
var perform = perform$3;
|
|
2148
|
+
var iterate = iterate$2;
|
|
2149
|
+
var PROMISE_STATICS_INCORRECT_ITERATION = promiseStaticsIncorrectIteration;
|
|
2150
|
+
|
|
2151
|
+
// `Promise.race` method
|
|
2152
|
+
// https://tc39.es/ecma262/#sec-promise.race
|
|
2153
|
+
$$2({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION }, {
|
|
2154
|
+
race: function race(iterable) {
|
|
2155
|
+
var C = this;
|
|
2156
|
+
var capability = newPromiseCapabilityModule$1.f(C);
|
|
2157
|
+
var reject = capability.reject;
|
|
2158
|
+
var result = perform(function () {
|
|
2159
|
+
var $promiseResolve = aCallable(C.resolve);
|
|
2160
|
+
iterate(iterable, function (promise) {
|
|
2161
|
+
call$1($promiseResolve, C, promise).then(capability.resolve, reject);
|
|
2162
|
+
});
|
|
2163
|
+
});
|
|
2164
|
+
if (result.error) reject(result.value);
|
|
2165
|
+
return capability.promise;
|
|
2166
|
+
}
|
|
2167
|
+
});
|
|
2168
|
+
|
|
2169
|
+
var $$1 = _export;
|
|
2170
|
+
var call = functionCall;
|
|
2171
|
+
var newPromiseCapabilityModule = newPromiseCapability$2;
|
|
2172
|
+
var FORCED_PROMISE_CONSTRUCTOR$1 = promiseConstructorDetection.CONSTRUCTOR;
|
|
2173
|
+
|
|
2174
|
+
// `Promise.reject` method
|
|
2175
|
+
// https://tc39.es/ecma262/#sec-promise.reject
|
|
2176
|
+
$$1({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR$1 }, {
|
|
2177
|
+
reject: function reject(r) {
|
|
2178
|
+
var capability = newPromiseCapabilityModule.f(this);
|
|
2179
|
+
call(capability.reject, undefined, r);
|
|
2180
|
+
return capability.promise;
|
|
2181
|
+
}
|
|
2182
|
+
});
|
|
2183
|
+
|
|
2184
|
+
var anObject = anObject$8;
|
|
2185
|
+
var isObject = isObject$7;
|
|
2186
|
+
var newPromiseCapability = newPromiseCapability$2;
|
|
2187
|
+
|
|
2188
|
+
var promiseResolve$1 = function (C, x) {
|
|
2189
|
+
anObject(C);
|
|
2190
|
+
if (isObject(x) && x.constructor === C) return x;
|
|
2191
|
+
var promiseCapability = newPromiseCapability.f(C);
|
|
2192
|
+
var resolve = promiseCapability.resolve;
|
|
2193
|
+
resolve(x);
|
|
2194
|
+
return promiseCapability.promise;
|
|
2195
|
+
};
|
|
1085
2196
|
|
|
1086
2197
|
var $ = _export;
|
|
1087
|
-
var
|
|
2198
|
+
var getBuiltIn = getBuiltIn$8;
|
|
2199
|
+
var FORCED_PROMISE_CONSTRUCTOR = promiseConstructorDetection.CONSTRUCTOR;
|
|
2200
|
+
var promiseResolve = promiseResolve$1;
|
|
1088
2201
|
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
//
|
|
1092
|
-
|
|
1093
|
-
|
|
2202
|
+
getBuiltIn('Promise');
|
|
2203
|
+
|
|
2204
|
+
// `Promise.resolve` method
|
|
2205
|
+
// https://tc39.es/ecma262/#sec-promise.resolve
|
|
2206
|
+
$({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR }, {
|
|
2207
|
+
resolve: function resolve(x) {
|
|
2208
|
+
return promiseResolve(this, x);
|
|
2209
|
+
}
|
|
1094
2210
|
});
|
|
1095
2211
|
|
|
1096
|
-
|
|
2212
|
+
/******************************************************************************
|
|
2213
|
+
Copyright (c) Microsoft Corporation.
|
|
2214
|
+
|
|
2215
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
2216
|
+
purpose with or without fee is hereby granted.
|
|
2217
|
+
|
|
2218
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
2219
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
2220
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
2221
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
2222
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
2223
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
2224
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
2225
|
+
***************************************************************************** */
|
|
2226
|
+
|
|
2227
|
+
function __awaiter(thisArg, _arguments, P, generator) {
|
|
2228
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
2229
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
2230
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
2231
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
2232
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
2233
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
2234
|
+
});
|
|
2235
|
+
}
|
|
2236
|
+
|
|
1097
2237
|
const TEMPLATE_OPTIONS = {
|
|
1098
2238
|
interpolate: /{{([\s\S]+?)}}/g
|
|
1099
2239
|
};
|
|
1100
|
-
const
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
}
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
2240
|
+
const isGoogleAnalyticsInitialized = () => {
|
|
2241
|
+
return typeof window === 'object' && 'gtag' in window &&
|
|
2242
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
2243
|
+
// @ts-ignore
|
|
2244
|
+
typeof window.gtag === 'function';
|
|
2245
|
+
};
|
|
2246
|
+
class NinetailedGoogleAnalyticsPlugin extends experience_jsPluginAnalytics.NinetailedAnalyticsPlugin {
|
|
2247
|
+
constructor(options = {}) {
|
|
2248
|
+
super();
|
|
2249
|
+
this.name = 'ninetailed:google-analytics';
|
|
2250
|
+
this.actionTemplate = template__default["default"](options.actionTemplate || 'Has Seen Component - Audience:{{ audience.id }}', TEMPLATE_OPTIONS);
|
|
2251
|
+
this.labelTemplate = template__default["default"](options.labelTemplate || '{{ baselineOrVariant }}:{{ component.id }}', TEMPLATE_OPTIONS);
|
|
2252
|
+
}
|
|
2253
|
+
onTrackExperience(properties) {
|
|
2254
|
+
return Promise.resolve();
|
|
2255
|
+
}
|
|
2256
|
+
onTrackComponent(properties) {
|
|
2257
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
2258
|
+
if (!isGoogleAnalyticsInitialized()) {
|
|
2259
|
+
return;
|
|
1118
2260
|
}
|
|
1119
2261
|
const {
|
|
1120
2262
|
variant,
|
|
1121
2263
|
audience,
|
|
1122
2264
|
isPersonalized
|
|
1123
2265
|
} = properties;
|
|
1124
|
-
const action = actionTemplate({
|
|
2266
|
+
const action = this.actionTemplate({
|
|
1125
2267
|
component: variant,
|
|
1126
2268
|
audience
|
|
1127
2269
|
});
|
|
1128
|
-
const label = labelTemplate({
|
|
2270
|
+
const label = this.labelTemplate({
|
|
1129
2271
|
component: variant,
|
|
1130
2272
|
audience,
|
|
1131
2273
|
baselineOrVariant: isPersonalized ? 'Variant' : 'Baseline'
|
|
1132
2274
|
});
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
}
|
|
2275
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
2276
|
+
// @ts-ignore
|
|
2277
|
+
window.gtag('event', action, {
|
|
2278
|
+
category: 'Ninetailed',
|
|
2279
|
+
label,
|
|
2280
|
+
nonInteraction: true
|
|
1140
2281
|
});
|
|
1141
|
-
}
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
}) => abort()
|
|
1145
|
-
};
|
|
1146
|
-
return [trackOverwritePlugin, googleAnalytics__default["default"]({
|
|
1147
|
-
trackingId: options.trackingId
|
|
1148
|
-
})];
|
|
1149
|
-
};
|
|
2282
|
+
});
|
|
2283
|
+
}
|
|
2284
|
+
}
|
|
1150
2285
|
|
|
1151
2286
|
exports.NinetailedGoogleAnalyticsPlugin = NinetailedGoogleAnalyticsPlugin;
|
|
1152
2287
|
exports["default"] = NinetailedGoogleAnalyticsPlugin;
|