@ninetailed/experience.js 2.0.0-beta.3 → 2.0.0-beta.30

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/index.esm.js CHANGED
@@ -1,11 +1,13 @@
1
1
  import get$2 from 'lodash/get';
2
2
  import unionBy from 'lodash/unionBy';
3
3
  import { buildEmptyCache, buildTrackEvent, buildIdentifyEvent, buildPageEvent } from '@ninetailed/experience.js-shared';
4
+ import * as loglevel from 'loglevel';
4
5
  import Analytics from 'analytics';
5
6
  import flatten from 'lodash/flatten';
6
7
  import find from 'lodash/find';
7
8
  import includes from 'lodash/includes';
8
9
  import pickBy from 'lodash/pickBy';
10
+ import { murmur3 } from 'murmurhash-js';
9
11
 
10
12
  var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
11
13
 
@@ -14,7 +16,7 @@ var check = function (it) {
14
16
  };
15
17
 
16
18
  // https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
17
- var global$H =
19
+ var global$K =
18
20
  // eslint-disable-next-line es/no-global-this -- safe
19
21
  check(typeof globalThis == 'object' && globalThis) ||
20
22
  check(typeof window == 'object' && window) ||
@@ -26,7 +28,7 @@ var global$H =
26
28
 
27
29
  var objectGetOwnPropertyDescriptor = {};
28
30
 
29
- var fails$h = function (exec) {
31
+ var fails$k = function (exec) {
30
32
  try {
31
33
  return !!exec();
32
34
  } catch (error) {
@@ -34,17 +36,17 @@ var fails$h = function (exec) {
34
36
  }
35
37
  };
36
38
 
37
- var fails$g = fails$h;
39
+ var fails$j = fails$k;
38
40
 
39
41
  // Detect IE8's incomplete defineProperty implementation
40
- var descriptors = !fails$g(function () {
42
+ var descriptors = !fails$j(function () {
41
43
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
42
44
  return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7;
43
45
  });
44
46
 
45
- var fails$f = fails$h;
47
+ var fails$i = fails$k;
46
48
 
47
- var functionBindNative = !fails$f(function () {
49
+ var functionBindNative = !fails$i(function () {
48
50
  var test = (function () { /* empty */ }).bind();
49
51
  // eslint-disable-next-line no-prototype-builtins -- safe
50
52
  return typeof test != 'function' || test.hasOwnProperty('prototype');
@@ -52,10 +54,10 @@ var functionBindNative = !fails$f(function () {
52
54
 
53
55
  var NATIVE_BIND$3 = functionBindNative;
54
56
 
55
- var call$e = Function.prototype.call;
57
+ var call$f = Function.prototype.call;
56
58
 
57
- var functionCall = NATIVE_BIND$3 ? call$e.bind(call$e) : function () {
58
- return call$e.apply(call$e, arguments);
59
+ var functionCall = NATIVE_BIND$3 ? call$f.bind(call$f) : function () {
60
+ return call$f.apply(call$f, arguments);
59
61
  };
60
62
 
61
63
  var objectPropertyIsEnumerable = {};
@@ -74,7 +76,7 @@ objectPropertyIsEnumerable.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
74
76
  return !!descriptor && descriptor.enumerable;
75
77
  } : $propertyIsEnumerable;
76
78
 
77
- var createPropertyDescriptor$3 = function (bitmap, value) {
79
+ var createPropertyDescriptor$4 = function (bitmap, value) {
78
80
  return {
79
81
  enumerable: !(bitmap & 1),
80
82
  configurable: !(bitmap & 2),
@@ -87,36 +89,36 @@ var NATIVE_BIND$2 = functionBindNative;
87
89
 
88
90
  var FunctionPrototype$2 = Function.prototype;
89
91
  var bind$5 = FunctionPrototype$2.bind;
90
- var call$d = FunctionPrototype$2.call;
91
- var uncurryThis$k = NATIVE_BIND$2 && bind$5.bind(call$d, call$d);
92
+ var call$e = FunctionPrototype$2.call;
93
+ var uncurryThis$n = NATIVE_BIND$2 && bind$5.bind(call$e, call$e);
92
94
 
93
95
  var functionUncurryThis = NATIVE_BIND$2 ? function (fn) {
94
- return fn && uncurryThis$k(fn);
96
+ return fn && uncurryThis$n(fn);
95
97
  } : function (fn) {
96
98
  return fn && function () {
97
- return call$d.apply(fn, arguments);
99
+ return call$e.apply(fn, arguments);
98
100
  };
99
101
  };
100
102
 
101
- var uncurryThis$j = functionUncurryThis;
103
+ var uncurryThis$m = functionUncurryThis;
102
104
 
103
- var toString$6 = uncurryThis$j({}.toString);
104
- var stringSlice$5 = uncurryThis$j(''.slice);
105
+ var toString$9 = uncurryThis$m({}.toString);
106
+ var stringSlice$6 = uncurryThis$m(''.slice);
105
107
 
106
108
  var classofRaw$1 = function (it) {
107
- return stringSlice$5(toString$6(it), 8, -1);
109
+ return stringSlice$6(toString$9(it), 8, -1);
108
110
  };
109
111
 
110
- var global$G = global$H;
111
- var uncurryThis$i = functionUncurryThis;
112
- var fails$e = fails$h;
112
+ var global$J = global$K;
113
+ var uncurryThis$l = functionUncurryThis;
114
+ var fails$h = fails$k;
113
115
  var classof$7 = classofRaw$1;
114
116
 
115
- var Object$5 = global$G.Object;
116
- var split = uncurryThis$i(''.split);
117
+ var Object$5 = global$J.Object;
118
+ var split = uncurryThis$l(''.split);
117
119
 
118
120
  // fallback for non-array-like ES3 and non-enumerable old V8 strings
119
- var indexedObject = fails$e(function () {
121
+ var indexedObject = fails$h(function () {
120
122
  // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
121
123
  // eslint-disable-next-line no-prototype-builtins -- safe
122
124
  return !Object$5('z').propertyIsEnumerable(0);
@@ -124,23 +126,23 @@ var indexedObject = fails$e(function () {
124
126
  return classof$7(it) == 'String' ? split(it, '') : Object$5(it);
125
127
  } : Object$5;
126
128
 
127
- var global$F = global$H;
129
+ var global$I = global$K;
128
130
 
129
- var TypeError$g = global$F.TypeError;
131
+ var TypeError$h = global$I.TypeError;
130
132
 
131
133
  // `RequireObjectCoercible` abstract operation
132
134
  // https://tc39.es/ecma262/#sec-requireobjectcoercible
133
- var requireObjectCoercible$5 = function (it) {
134
- if (it == undefined) throw TypeError$g("Can't call method on " + it);
135
+ var requireObjectCoercible$7 = function (it) {
136
+ if (it == undefined) throw TypeError$h("Can't call method on " + it);
135
137
  return it;
136
138
  };
137
139
 
138
140
  // toObject with fallback for non-array-like ES3 strings
139
- var IndexedObject$1 = indexedObject;
140
- var requireObjectCoercible$4 = requireObjectCoercible$5;
141
+ var IndexedObject$2 = indexedObject;
142
+ var requireObjectCoercible$6 = requireObjectCoercible$7;
141
143
 
142
144
  var toIndexedObject$5 = function (it) {
143
- return IndexedObject$1(requireObjectCoercible$4(it));
145
+ return IndexedObject$2(requireObjectCoercible$6(it));
144
146
  };
145
147
 
146
148
  // `IsCallable` abstract operation
@@ -155,7 +157,7 @@ var isObject$8 = function (it) {
155
157
  return typeof it == 'object' ? it !== null : isCallable$i(it);
156
158
  };
157
159
 
158
- var global$E = global$H;
160
+ var global$H = global$K;
159
161
  var isCallable$h = isCallable$j;
160
162
 
161
163
  var aFunction = function (argument) {
@@ -163,23 +165,23 @@ var aFunction = function (argument) {
163
165
  };
164
166
 
165
167
  var getBuiltIn$7 = function (namespace, method) {
166
- return arguments.length < 2 ? aFunction(global$E[namespace]) : global$E[namespace] && global$E[namespace][method];
168
+ return arguments.length < 2 ? aFunction(global$H[namespace]) : global$H[namespace] && global$H[namespace][method];
167
169
  };
168
170
 
169
- var uncurryThis$h = functionUncurryThis;
171
+ var uncurryThis$k = functionUncurryThis;
170
172
 
171
- var objectIsPrototypeOf = uncurryThis$h({}.isPrototypeOf);
173
+ var objectIsPrototypeOf = uncurryThis$k({}.isPrototypeOf);
172
174
 
173
175
  var getBuiltIn$6 = getBuiltIn$7;
174
176
 
175
177
  var engineUserAgent = getBuiltIn$6('navigator', 'userAgent') || '';
176
178
 
177
- var global$D = global$H;
179
+ var global$G = global$K;
178
180
  var userAgent$3 = engineUserAgent;
179
181
 
180
- var process$4 = global$D.process;
181
- var Deno = global$D.Deno;
182
- var versions = process$4 && process$4.versions || Deno && Deno.version;
182
+ var process$3 = global$G.process;
183
+ var Deno = global$G.Deno;
184
+ var versions = process$3 && process$3.versions || Deno && Deno.version;
183
185
  var v8 = versions && versions.v8;
184
186
  var match, version;
185
187
 
@@ -205,10 +207,10 @@ var engineV8Version = version;
205
207
  /* eslint-disable es/no-symbol -- required for testing */
206
208
 
207
209
  var V8_VERSION$1 = engineV8Version;
208
- var fails$d = fails$h;
210
+ var fails$g = fails$k;
209
211
 
210
212
  // eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
211
- var nativeSymbol = !!Object.getOwnPropertySymbols && !fails$d(function () {
213
+ var nativeSymbol = !!Object.getOwnPropertySymbols && !fails$g(function () {
212
214
  var symbol = Symbol();
213
215
  // Chrome 38 Symbol has incorrect toString conversion
214
216
  // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
@@ -225,13 +227,13 @@ var useSymbolAsUid = NATIVE_SYMBOL$1
225
227
  && !Symbol.sham
226
228
  && typeof Symbol.iterator == 'symbol';
227
229
 
228
- var global$C = global$H;
230
+ var global$F = global$K;
229
231
  var getBuiltIn$5 = getBuiltIn$7;
230
232
  var isCallable$g = isCallable$j;
231
233
  var isPrototypeOf$2 = objectIsPrototypeOf;
232
234
  var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
233
235
 
234
- var Object$4 = global$C.Object;
236
+ var Object$4 = global$F.Object;
235
237
 
236
238
  var isSymbol$2 = USE_SYMBOL_AS_UID$1 ? function (it) {
237
239
  return typeof it == 'symbol';
@@ -240,9 +242,9 @@ var isSymbol$2 = USE_SYMBOL_AS_UID$1 ? function (it) {
240
242
  return isCallable$g($Symbol) && isPrototypeOf$2($Symbol.prototype, Object$4(it));
241
243
  };
242
244
 
243
- var global$B = global$H;
245
+ var global$E = global$K;
244
246
 
245
- var String$5 = global$B.String;
247
+ var String$5 = global$E.String;
246
248
 
247
249
  var tryToString$4 = function (argument) {
248
250
  try {
@@ -252,64 +254,64 @@ var tryToString$4 = function (argument) {
252
254
  }
253
255
  };
254
256
 
255
- var global$A = global$H;
257
+ var global$D = global$K;
256
258
  var isCallable$f = isCallable$j;
257
259
  var tryToString$3 = tryToString$4;
258
260
 
259
- var TypeError$f = global$A.TypeError;
261
+ var TypeError$g = global$D.TypeError;
260
262
 
261
263
  // `Assert: IsCallable(argument) is true`
262
- var aCallable$5 = function (argument) {
264
+ var aCallable$6 = function (argument) {
263
265
  if (isCallable$f(argument)) return argument;
264
- throw TypeError$f(tryToString$3(argument) + ' is not a function');
266
+ throw TypeError$g(tryToString$3(argument) + ' is not a function');
265
267
  };
266
268
 
267
- var aCallable$4 = aCallable$5;
269
+ var aCallable$5 = aCallable$6;
268
270
 
269
271
  // `GetMethod` abstract operation
270
272
  // https://tc39.es/ecma262/#sec-getmethod
271
- var getMethod$4 = function (V, P) {
273
+ var getMethod$5 = function (V, P) {
272
274
  var func = V[P];
273
- return func == null ? undefined : aCallable$4(func);
275
+ return func == null ? undefined : aCallable$5(func);
274
276
  };
275
277
 
276
- var global$z = global$H;
277
- var call$c = functionCall;
278
+ var global$C = global$K;
279
+ var call$d = functionCall;
278
280
  var isCallable$e = isCallable$j;
279
281
  var isObject$7 = isObject$8;
280
282
 
281
- var TypeError$e = global$z.TypeError;
283
+ var TypeError$f = global$C.TypeError;
282
284
 
283
285
  // `OrdinaryToPrimitive` abstract operation
284
286
  // https://tc39.es/ecma262/#sec-ordinarytoprimitive
285
287
  var ordinaryToPrimitive$1 = function (input, pref) {
286
288
  var fn, val;
287
- if (pref === 'string' && isCallable$e(fn = input.toString) && !isObject$7(val = call$c(fn, input))) return val;
288
- if (isCallable$e(fn = input.valueOf) && !isObject$7(val = call$c(fn, input))) return val;
289
- if (pref !== 'string' && isCallable$e(fn = input.toString) && !isObject$7(val = call$c(fn, input))) return val;
290
- throw TypeError$e("Can't convert object to primitive value");
289
+ if (pref === 'string' && isCallable$e(fn = input.toString) && !isObject$7(val = call$d(fn, input))) return val;
290
+ if (isCallable$e(fn = input.valueOf) && !isObject$7(val = call$d(fn, input))) return val;
291
+ if (pref !== 'string' && isCallable$e(fn = input.toString) && !isObject$7(val = call$d(fn, input))) return val;
292
+ throw TypeError$f("Can't convert object to primitive value");
291
293
  };
292
294
 
293
295
  var shared$4 = {exports: {}};
294
296
 
295
- var global$y = global$H;
297
+ var global$B = global$K;
296
298
 
297
299
  // eslint-disable-next-line es/no-object-defineproperty -- safe
298
300
  var defineProperty$3 = Object.defineProperty;
299
301
 
300
302
  var setGlobal$3 = function (key, value) {
301
303
  try {
302
- defineProperty$3(global$y, key, { value: value, configurable: true, writable: true });
304
+ defineProperty$3(global$B, key, { value: value, configurable: true, writable: true });
303
305
  } catch (error) {
304
- global$y[key] = value;
306
+ global$B[key] = value;
305
307
  } return value;
306
308
  };
307
309
 
308
- var global$x = global$H;
310
+ var global$A = global$K;
309
311
  var setGlobal$2 = setGlobal$3;
310
312
 
311
313
  var SHARED = '__core-js_shared__';
312
- var store$3 = global$x[SHARED] || setGlobal$2(SHARED, {});
314
+ var store$3 = global$A[SHARED] || setGlobal$2(SHARED, {});
313
315
 
314
316
  var sharedStore = store$3;
315
317
 
@@ -325,39 +327,39 @@ var store$2 = sharedStore;
325
327
  source: 'https://github.com/zloirock/core-js'
326
328
  });
327
329
 
328
- var global$w = global$H;
329
- var requireObjectCoercible$3 = requireObjectCoercible$5;
330
+ var global$z = global$K;
331
+ var requireObjectCoercible$5 = requireObjectCoercible$7;
330
332
 
331
- var Object$3 = global$w.Object;
333
+ var Object$3 = global$z.Object;
332
334
 
333
335
  // `ToObject` abstract operation
334
336
  // https://tc39.es/ecma262/#sec-toobject
335
- var toObject$4 = function (argument) {
336
- return Object$3(requireObjectCoercible$3(argument));
337
+ var toObject$5 = function (argument) {
338
+ return Object$3(requireObjectCoercible$5(argument));
337
339
  };
338
340
 
339
- var uncurryThis$g = functionUncurryThis;
340
- var toObject$3 = toObject$4;
341
+ var uncurryThis$j = functionUncurryThis;
342
+ var toObject$4 = toObject$5;
341
343
 
342
- var hasOwnProperty = uncurryThis$g({}.hasOwnProperty);
344
+ var hasOwnProperty = uncurryThis$j({}.hasOwnProperty);
343
345
 
344
346
  // `HasOwnProperty` abstract operation
345
347
  // https://tc39.es/ecma262/#sec-hasownproperty
346
348
  var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
347
- return hasOwnProperty(toObject$3(it), key);
349
+ return hasOwnProperty(toObject$4(it), key);
348
350
  };
349
351
 
350
- var uncurryThis$f = functionUncurryThis;
352
+ var uncurryThis$i = functionUncurryThis;
351
353
 
352
354
  var id = 0;
353
355
  var postfix = Math.random();
354
- var toString$5 = uncurryThis$f(1.0.toString);
356
+ var toString$8 = uncurryThis$i(1.0.toString);
355
357
 
356
358
  var uid$2 = function (key) {
357
- return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$5(++id + postfix, 36);
359
+ return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$8(++id + postfix, 36);
358
360
  };
359
361
 
360
- var global$v = global$H;
362
+ var global$y = global$K;
361
363
  var shared$3 = shared$4.exports;
362
364
  var hasOwn$9 = hasOwnProperty_1;
363
365
  var uid$1 = uid$2;
@@ -365,15 +367,15 @@ var NATIVE_SYMBOL = nativeSymbol;
365
367
  var USE_SYMBOL_AS_UID = useSymbolAsUid;
366
368
 
367
369
  var WellKnownSymbolsStore = shared$3('wks');
368
- var Symbol$1 = global$v.Symbol;
369
- var symbolFor = Symbol$1 && Symbol$1['for'];
370
- var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid$1;
370
+ var Symbol$2 = global$y.Symbol;
371
+ var symbolFor = Symbol$2 && Symbol$2['for'];
372
+ var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol$2 : Symbol$2 && Symbol$2.withoutSetter || uid$1;
371
373
 
372
374
  var wellKnownSymbol$i = function (name) {
373
375
  if (!hasOwn$9(WellKnownSymbolsStore, name) || !(NATIVE_SYMBOL || typeof WellKnownSymbolsStore[name] == 'string')) {
374
376
  var description = 'Symbol.' + name;
375
- if (NATIVE_SYMBOL && hasOwn$9(Symbol$1, name)) {
376
- WellKnownSymbolsStore[name] = Symbol$1[name];
377
+ if (NATIVE_SYMBOL && hasOwn$9(Symbol$2, name)) {
378
+ WellKnownSymbolsStore[name] = Symbol$2[name];
377
379
  } else if (USE_SYMBOL_AS_UID && symbolFor) {
378
380
  WellKnownSymbolsStore[name] = symbolFor(description);
379
381
  } else {
@@ -382,28 +384,28 @@ var wellKnownSymbol$i = function (name) {
382
384
  } return WellKnownSymbolsStore[name];
383
385
  };
384
386
 
385
- var global$u = global$H;
386
- var call$b = functionCall;
387
+ var global$x = global$K;
388
+ var call$c = functionCall;
387
389
  var isObject$6 = isObject$8;
388
390
  var isSymbol$1 = isSymbol$2;
389
- var getMethod$3 = getMethod$4;
391
+ var getMethod$4 = getMethod$5;
390
392
  var ordinaryToPrimitive = ordinaryToPrimitive$1;
391
393
  var wellKnownSymbol$h = wellKnownSymbol$i;
392
394
 
393
- var TypeError$d = global$u.TypeError;
395
+ var TypeError$e = global$x.TypeError;
394
396
  var TO_PRIMITIVE = wellKnownSymbol$h('toPrimitive');
395
397
 
396
398
  // `ToPrimitive` abstract operation
397
399
  // https://tc39.es/ecma262/#sec-toprimitive
398
400
  var toPrimitive$1 = function (input, pref) {
399
401
  if (!isObject$6(input) || isSymbol$1(input)) return input;
400
- var exoticToPrim = getMethod$3(input, TO_PRIMITIVE);
402
+ var exoticToPrim = getMethod$4(input, TO_PRIMITIVE);
401
403
  var result;
402
404
  if (exoticToPrim) {
403
405
  if (pref === undefined) pref = 'default';
404
- result = call$b(exoticToPrim, input, pref);
406
+ result = call$c(exoticToPrim, input, pref);
405
407
  if (!isObject$6(result) || isSymbol$1(result)) return result;
406
- throw TypeError$d("Can't convert object to primitive value");
408
+ throw TypeError$e("Can't convert object to primitive value");
407
409
  }
408
410
  if (pref === undefined) pref = 'number';
409
411
  return ordinaryToPrimitive(input, pref);
@@ -414,15 +416,15 @@ var isSymbol = isSymbol$2;
414
416
 
415
417
  // `ToPropertyKey` abstract operation
416
418
  // https://tc39.es/ecma262/#sec-topropertykey
417
- var toPropertyKey$2 = function (argument) {
419
+ var toPropertyKey$3 = function (argument) {
418
420
  var key = toPrimitive(argument, 'string');
419
421
  return isSymbol(key) ? key : key + '';
420
422
  };
421
423
 
422
- var global$t = global$H;
424
+ var global$w = global$K;
423
425
  var isObject$5 = isObject$8;
424
426
 
425
- var document$3 = global$t.document;
427
+ var document$3 = global$w.document;
426
428
  // typeof document.createElement is 'object' in old IE
427
429
  var EXISTS$1 = isObject$5(document$3) && isObject$5(document$3.createElement);
428
430
 
@@ -431,11 +433,11 @@ var documentCreateElement$2 = function (it) {
431
433
  };
432
434
 
433
435
  var DESCRIPTORS$9 = descriptors;
434
- var fails$c = fails$h;
436
+ var fails$f = fails$k;
435
437
  var createElement$1 = documentCreateElement$2;
436
438
 
437
439
  // Thanks to IE8 for its funny defineProperty
438
- var ie8DomDefine = !DESCRIPTORS$9 && !fails$c(function () {
440
+ var ie8DomDefine = !DESCRIPTORS$9 && !fails$f(function () {
439
441
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
440
442
  return Object.defineProperty(createElement$1('div'), 'a', {
441
443
  get: function () { return 7; }
@@ -443,11 +445,11 @@ var ie8DomDefine = !DESCRIPTORS$9 && !fails$c(function () {
443
445
  });
444
446
 
445
447
  var DESCRIPTORS$8 = descriptors;
446
- var call$a = functionCall;
448
+ var call$b = functionCall;
447
449
  var propertyIsEnumerableModule$1 = objectPropertyIsEnumerable;
448
- var createPropertyDescriptor$2 = createPropertyDescriptor$3;
450
+ var createPropertyDescriptor$3 = createPropertyDescriptor$4;
449
451
  var toIndexedObject$4 = toIndexedObject$5;
450
- var toPropertyKey$1 = toPropertyKey$2;
452
+ var toPropertyKey$2 = toPropertyKey$3;
451
453
  var hasOwn$8 = hasOwnProperty_1;
452
454
  var IE8_DOM_DEFINE$1 = ie8DomDefine;
453
455
 
@@ -458,21 +460,21 @@ var $getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
458
460
  // https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
459
461
  objectGetOwnPropertyDescriptor.f = DESCRIPTORS$8 ? $getOwnPropertyDescriptor$1 : function getOwnPropertyDescriptor(O, P) {
460
462
  O = toIndexedObject$4(O);
461
- P = toPropertyKey$1(P);
463
+ P = toPropertyKey$2(P);
462
464
  if (IE8_DOM_DEFINE$1) try {
463
465
  return $getOwnPropertyDescriptor$1(O, P);
464
466
  } catch (error) { /* empty */ }
465
- if (hasOwn$8(O, P)) return createPropertyDescriptor$2(!call$a(propertyIsEnumerableModule$1.f, O, P), O[P]);
467
+ if (hasOwn$8(O, P)) return createPropertyDescriptor$3(!call$b(propertyIsEnumerableModule$1.f, O, P), O[P]);
466
468
  };
467
469
 
468
470
  var objectDefineProperty = {};
469
471
 
470
472
  var DESCRIPTORS$7 = descriptors;
471
- var fails$b = fails$h;
473
+ var fails$e = fails$k;
472
474
 
473
475
  // V8 ~ Chrome 36-
474
476
  // https://bugs.chromium.org/p/v8/issues/detail?id=3334
475
- var v8PrototypeDefineBug = DESCRIPTORS$7 && fails$b(function () {
477
+ var v8PrototypeDefineBug = DESCRIPTORS$7 && fails$e(function () {
476
478
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
477
479
  return Object.defineProperty(function () { /* empty */ }, 'prototype', {
478
480
  value: 42,
@@ -480,26 +482,26 @@ var v8PrototypeDefineBug = DESCRIPTORS$7 && fails$b(function () {
480
482
  }).prototype != 42;
481
483
  });
482
484
 
483
- var global$s = global$H;
485
+ var global$v = global$K;
484
486
  var isObject$4 = isObject$8;
485
487
 
486
- var String$4 = global$s.String;
487
- var TypeError$c = global$s.TypeError;
488
+ var String$4 = global$v.String;
489
+ var TypeError$d = global$v.TypeError;
488
490
 
489
491
  // `Assert: Type(argument) is Object`
490
- var anObject$d = function (argument) {
492
+ var anObject$e = function (argument) {
491
493
  if (isObject$4(argument)) return argument;
492
- throw TypeError$c(String$4(argument) + ' is not an object');
494
+ throw TypeError$d(String$4(argument) + ' is not an object');
493
495
  };
494
496
 
495
- var global$r = global$H;
497
+ var global$u = global$K;
496
498
  var DESCRIPTORS$6 = descriptors;
497
499
  var IE8_DOM_DEFINE = ie8DomDefine;
498
500
  var V8_PROTOTYPE_DEFINE_BUG$1 = v8PrototypeDefineBug;
499
- var anObject$c = anObject$d;
500
- var toPropertyKey = toPropertyKey$2;
501
+ var anObject$d = anObject$e;
502
+ var toPropertyKey$1 = toPropertyKey$3;
501
503
 
502
- var TypeError$b = global$r.TypeError;
504
+ var TypeError$c = global$u.TypeError;
503
505
  // eslint-disable-next-line es/no-object-defineproperty -- safe
504
506
  var $defineProperty = Object.defineProperty;
505
507
  // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
@@ -511,9 +513,9 @@ var WRITABLE = 'writable';
511
513
  // `Object.defineProperty` method
512
514
  // https://tc39.es/ecma262/#sec-object.defineproperty
513
515
  objectDefineProperty.f = DESCRIPTORS$6 ? V8_PROTOTYPE_DEFINE_BUG$1 ? function defineProperty(O, P, Attributes) {
514
- anObject$c(O);
515
- P = toPropertyKey(P);
516
- anObject$c(Attributes);
516
+ anObject$d(O);
517
+ P = toPropertyKey$1(P);
518
+ anObject$d(Attributes);
517
519
  if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {
518
520
  var current = $getOwnPropertyDescriptor(O, P);
519
521
  if (current && current[WRITABLE]) {
@@ -526,23 +528,23 @@ objectDefineProperty.f = DESCRIPTORS$6 ? V8_PROTOTYPE_DEFINE_BUG$1 ? function de
526
528
  }
527
529
  } return $defineProperty(O, P, Attributes);
528
530
  } : $defineProperty : function defineProperty(O, P, Attributes) {
529
- anObject$c(O);
530
- P = toPropertyKey(P);
531
- anObject$c(Attributes);
531
+ anObject$d(O);
532
+ P = toPropertyKey$1(P);
533
+ anObject$d(Attributes);
532
534
  if (IE8_DOM_DEFINE) try {
533
535
  return $defineProperty(O, P, Attributes);
534
536
  } catch (error) { /* empty */ }
535
- if ('get' in Attributes || 'set' in Attributes) throw TypeError$b('Accessors not supported');
537
+ if ('get' in Attributes || 'set' in Attributes) throw TypeError$c('Accessors not supported');
536
538
  if ('value' in Attributes) O[P] = Attributes.value;
537
539
  return O;
538
540
  };
539
541
 
540
542
  var DESCRIPTORS$5 = descriptors;
541
- var definePropertyModule$4 = objectDefineProperty;
542
- var createPropertyDescriptor$1 = createPropertyDescriptor$3;
543
+ var definePropertyModule$5 = objectDefineProperty;
544
+ var createPropertyDescriptor$2 = createPropertyDescriptor$4;
543
545
 
544
546
  var createNonEnumerableProperty$6 = DESCRIPTORS$5 ? function (object, key, value) {
545
- return definePropertyModule$4.f(object, key, createPropertyDescriptor$1(1, value));
547
+ return definePropertyModule$5.f(object, key, createPropertyDescriptor$2(1, value));
546
548
  } : function (object, key, value) {
547
549
  object[key] = value;
548
550
  return object;
@@ -550,11 +552,11 @@ var createNonEnumerableProperty$6 = DESCRIPTORS$5 ? function (object, key, value
550
552
 
551
553
  var redefine$6 = {exports: {}};
552
554
 
553
- var uncurryThis$e = functionUncurryThis;
555
+ var uncurryThis$h = functionUncurryThis;
554
556
  var isCallable$d = isCallable$j;
555
557
  var store$1 = sharedStore;
556
558
 
557
- var functionToString = uncurryThis$e(Function.toString);
559
+ var functionToString = uncurryThis$h(Function.toString);
558
560
 
559
561
  // this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
560
562
  if (!isCallable$d(store$1.inspectSource)) {
@@ -565,11 +567,11 @@ if (!isCallable$d(store$1.inspectSource)) {
565
567
 
566
568
  var inspectSource$4 = store$1.inspectSource;
567
569
 
568
- var global$q = global$H;
570
+ var global$t = global$K;
569
571
  var isCallable$c = isCallable$j;
570
572
  var inspectSource$3 = inspectSource$4;
571
573
 
572
- var WeakMap$1 = global$q.WeakMap;
574
+ var WeakMap$1 = global$t.WeakMap;
573
575
 
574
576
  var nativeWeakMap = isCallable$c(WeakMap$1) && /native code/.test(inspectSource$3(WeakMap$1));
575
577
 
@@ -585,8 +587,8 @@ var sharedKey$3 = function (key) {
585
587
  var hiddenKeys$4 = {};
586
588
 
587
589
  var NATIVE_WEAK_MAP = nativeWeakMap;
588
- var global$p = global$H;
589
- var uncurryThis$d = functionUncurryThis;
590
+ var global$s = global$K;
591
+ var uncurryThis$g = functionUncurryThis;
590
592
  var isObject$3 = isObject$8;
591
593
  var createNonEnumerableProperty$5 = createNonEnumerableProperty$6;
592
594
  var hasOwn$7 = hasOwnProperty_1;
@@ -595,8 +597,8 @@ var sharedKey$2 = sharedKey$3;
595
597
  var hiddenKeys$3 = hiddenKeys$4;
596
598
 
597
599
  var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
598
- var TypeError$a = global$p.TypeError;
599
- var WeakMap = global$p.WeakMap;
600
+ var TypeError$b = global$s.TypeError;
601
+ var WeakMap = global$s.WeakMap;
600
602
  var set$2, get$1, has;
601
603
 
602
604
  var enforce = function (it) {
@@ -607,18 +609,18 @@ var getterFor = function (TYPE) {
607
609
  return function (it) {
608
610
  var state;
609
611
  if (!isObject$3(it) || (state = get$1(it)).type !== TYPE) {
610
- throw TypeError$a('Incompatible receiver, ' + TYPE + ' required');
612
+ throw TypeError$b('Incompatible receiver, ' + TYPE + ' required');
611
613
  } return state;
612
614
  };
613
615
  };
614
616
 
615
617
  if (NATIVE_WEAK_MAP || shared$1.state) {
616
618
  var store = shared$1.state || (shared$1.state = new WeakMap());
617
- var wmget = uncurryThis$d(store.get);
618
- var wmhas = uncurryThis$d(store.has);
619
- var wmset = uncurryThis$d(store.set);
619
+ var wmget = uncurryThis$g(store.get);
620
+ var wmhas = uncurryThis$g(store.has);
621
+ var wmset = uncurryThis$g(store.set);
620
622
  set$2 = function (it, metadata) {
621
- if (wmhas(store, it)) throw new TypeError$a(OBJECT_ALREADY_INITIALIZED);
623
+ if (wmhas(store, it)) throw new TypeError$b(OBJECT_ALREADY_INITIALIZED);
622
624
  metadata.facade = it;
623
625
  wmset(store, it, metadata);
624
626
  return metadata;
@@ -633,7 +635,7 @@ if (NATIVE_WEAK_MAP || shared$1.state) {
633
635
  var STATE = sharedKey$2('state');
634
636
  hiddenKeys$3[STATE] = true;
635
637
  set$2 = function (it, metadata) {
636
- if (hasOwn$7(it, STATE)) throw new TypeError$a(OBJECT_ALREADY_INITIALIZED);
638
+ if (hasOwn$7(it, STATE)) throw new TypeError$b(OBJECT_ALREADY_INITIALIZED);
637
639
  metadata.facade = it;
638
640
  createNonEnumerableProperty$5(it, STATE, metadata);
639
641
  return metadata;
@@ -672,7 +674,7 @@ var functionName = {
672
674
  CONFIGURABLE: CONFIGURABLE
673
675
  };
674
676
 
675
- var global$o = global$H;
677
+ var global$r = global$K;
676
678
  var isCallable$b = isCallable$j;
677
679
  var hasOwn$5 = hasOwnProperty_1;
678
680
  var createNonEnumerableProperty$4 = createNonEnumerableProperty$6;
@@ -703,7 +705,7 @@ var TEMPLATE = String(String).split('String');
703
705
  state.source = TEMPLATE.join(typeof name == 'string' ? name : '');
704
706
  }
705
707
  }
706
- if (O === global$o) {
708
+ if (O === global$r) {
707
709
  if (simple) O[key] = value;
708
710
  else setGlobal$1(key, value);
709
711
  return;
@@ -734,45 +736,45 @@ var toIntegerOrInfinity$4 = function (argument) {
734
736
 
735
737
  var toIntegerOrInfinity$3 = toIntegerOrInfinity$4;
736
738
 
737
- var max$1 = Math.max;
738
- var min$3 = Math.min;
739
+ var max$2 = Math.max;
740
+ var min$4 = Math.min;
739
741
 
740
742
  // Helper for a popular repeating case of the spec:
741
743
  // Let integer be ? ToInteger(index).
742
744
  // If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
743
- var toAbsoluteIndex$1 = function (index, length) {
745
+ var toAbsoluteIndex$2 = function (index, length) {
744
746
  var integer = toIntegerOrInfinity$3(index);
745
- return integer < 0 ? max$1(integer + length, 0) : min$3(integer, length);
747
+ return integer < 0 ? max$2(integer + length, 0) : min$4(integer, length);
746
748
  };
747
749
 
748
750
  var toIntegerOrInfinity$2 = toIntegerOrInfinity$4;
749
751
 
750
- var min$2 = Math.min;
752
+ var min$3 = Math.min;
751
753
 
752
754
  // `ToLength` abstract operation
753
755
  // https://tc39.es/ecma262/#sec-tolength
754
- var toLength$3 = function (argument) {
755
- return argument > 0 ? min$2(toIntegerOrInfinity$2(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
756
+ var toLength$4 = function (argument) {
757
+ return argument > 0 ? min$3(toIntegerOrInfinity$2(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
756
758
  };
757
759
 
758
- var toLength$2 = toLength$3;
760
+ var toLength$3 = toLength$4;
759
761
 
760
762
  // `LengthOfArrayLike` abstract operation
761
763
  // https://tc39.es/ecma262/#sec-lengthofarraylike
762
- var lengthOfArrayLike$2 = function (obj) {
763
- return toLength$2(obj.length);
764
+ var lengthOfArrayLike$4 = function (obj) {
765
+ return toLength$3(obj.length);
764
766
  };
765
767
 
766
768
  var toIndexedObject$3 = toIndexedObject$5;
767
- var toAbsoluteIndex = toAbsoluteIndex$1;
768
- var lengthOfArrayLike$1 = lengthOfArrayLike$2;
769
+ var toAbsoluteIndex$1 = toAbsoluteIndex$2;
770
+ var lengthOfArrayLike$3 = lengthOfArrayLike$4;
769
771
 
770
772
  // `Array.prototype.{ indexOf, includes }` methods implementation
771
- var createMethod$1 = function (IS_INCLUDES) {
773
+ var createMethod$3 = function (IS_INCLUDES) {
772
774
  return function ($this, el, fromIndex) {
773
775
  var O = toIndexedObject$3($this);
774
- var length = lengthOfArrayLike$1(O);
775
- var index = toAbsoluteIndex(fromIndex, length);
776
+ var length = lengthOfArrayLike$3(O);
777
+ var index = toAbsoluteIndex$1(fromIndex, length);
776
778
  var value;
777
779
  // Array#includes uses SameValueZero equality algorithm
778
780
  // eslint-disable-next-line no-self-compare -- NaN check
@@ -790,29 +792,29 @@ var createMethod$1 = function (IS_INCLUDES) {
790
792
  var arrayIncludes = {
791
793
  // `Array.prototype.includes` method
792
794
  // https://tc39.es/ecma262/#sec-array.prototype.includes
793
- includes: createMethod$1(true),
795
+ includes: createMethod$3(true),
794
796
  // `Array.prototype.indexOf` method
795
797
  // https://tc39.es/ecma262/#sec-array.prototype.indexof
796
- indexOf: createMethod$1(false)
798
+ indexOf: createMethod$3(false)
797
799
  };
798
800
 
799
- var uncurryThis$c = functionUncurryThis;
801
+ var uncurryThis$f = functionUncurryThis;
800
802
  var hasOwn$4 = hasOwnProperty_1;
801
803
  var toIndexedObject$2 = toIndexedObject$5;
802
804
  var indexOf$1 = arrayIncludes.indexOf;
803
805
  var hiddenKeys$2 = hiddenKeys$4;
804
806
 
805
- var push$1 = uncurryThis$c([].push);
807
+ var push$2 = uncurryThis$f([].push);
806
808
 
807
809
  var objectKeysInternal = function (object, names) {
808
810
  var O = toIndexedObject$2(object);
809
811
  var i = 0;
810
812
  var result = [];
811
813
  var key;
812
- for (key in O) !hasOwn$4(hiddenKeys$2, key) && hasOwn$4(O, key) && push$1(result, key);
814
+ for (key in O) !hasOwn$4(hiddenKeys$2, key) && hasOwn$4(O, key) && push$2(result, key);
813
815
  // Don't enum bug & hidden keys
814
816
  while (names.length > i) if (hasOwn$4(O, key = names[i++])) {
815
- ~indexOf$1(result, key) || push$1(result, key);
817
+ ~indexOf$1(result, key) || push$2(result, key);
816
818
  }
817
819
  return result;
818
820
  };
@@ -846,16 +848,16 @@ var objectGetOwnPropertySymbols = {};
846
848
  objectGetOwnPropertySymbols.f = Object.getOwnPropertySymbols;
847
849
 
848
850
  var getBuiltIn$4 = getBuiltIn$7;
849
- var uncurryThis$b = functionUncurryThis;
851
+ var uncurryThis$e = functionUncurryThis;
850
852
  var getOwnPropertyNamesModule = objectGetOwnPropertyNames;
851
853
  var getOwnPropertySymbolsModule$1 = objectGetOwnPropertySymbols;
852
- var anObject$b = anObject$d;
854
+ var anObject$c = anObject$e;
853
855
 
854
- var concat$2 = uncurryThis$b([].concat);
856
+ var concat$2 = uncurryThis$e([].concat);
855
857
 
856
858
  // all object keys, includes non-enumerable and symbols
857
859
  var ownKeys$1 = getBuiltIn$4('Reflect', 'ownKeys') || function ownKeys(it) {
858
- var keys = getOwnPropertyNamesModule.f(anObject$b(it));
860
+ var keys = getOwnPropertyNamesModule.f(anObject$c(it));
859
861
  var getOwnPropertySymbols = getOwnPropertySymbolsModule$1.f;
860
862
  return getOwnPropertySymbols ? concat$2(keys, getOwnPropertySymbols(it)) : keys;
861
863
  };
@@ -863,11 +865,11 @@ var ownKeys$1 = getBuiltIn$4('Reflect', 'ownKeys') || function ownKeys(it) {
863
865
  var hasOwn$3 = hasOwnProperty_1;
864
866
  var ownKeys = ownKeys$1;
865
867
  var getOwnPropertyDescriptorModule = objectGetOwnPropertyDescriptor;
866
- var definePropertyModule$3 = objectDefineProperty;
868
+ var definePropertyModule$4 = objectDefineProperty;
867
869
 
868
870
  var copyConstructorProperties$1 = function (target, source, exceptions) {
869
871
  var keys = ownKeys(source);
870
- var defineProperty = definePropertyModule$3.f;
872
+ var defineProperty = definePropertyModule$4.f;
871
873
  var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
872
874
  for (var i = 0; i < keys.length; i++) {
873
875
  var key = keys[i];
@@ -877,20 +879,20 @@ var copyConstructorProperties$1 = function (target, source, exceptions) {
877
879
  }
878
880
  };
879
881
 
880
- var fails$a = fails$h;
882
+ var fails$d = fails$k;
881
883
  var isCallable$a = isCallable$j;
882
884
 
883
885
  var replacement = /#|\.prototype\./;
884
886
 
885
887
  var isForced$2 = function (feature, detection) {
886
- var value = data[normalize(feature)];
888
+ var value = data[normalize$1(feature)];
887
889
  return value == POLYFILL ? true
888
890
  : value == NATIVE ? false
889
- : isCallable$a(detection) ? fails$a(detection)
891
+ : isCallable$a(detection) ? fails$d(detection)
890
892
  : !!detection;
891
893
  };
892
894
 
893
- var normalize = isForced$2.normalize = function (string) {
895
+ var normalize$1 = isForced$2.normalize = function (string) {
894
896
  return String(string).replace(replacement, '.').toLowerCase();
895
897
  };
896
898
 
@@ -900,7 +902,7 @@ var POLYFILL = isForced$2.POLYFILL = 'P';
900
902
 
901
903
  var isForced_1 = isForced$2;
902
904
 
903
- var global$n = global$H;
905
+ var global$q = global$K;
904
906
  var getOwnPropertyDescriptor$2 = objectGetOwnPropertyDescriptor.f;
905
907
  var createNonEnumerableProperty$3 = createNonEnumerableProperty$6;
906
908
  var redefine$5 = redefine$6.exports;
@@ -929,11 +931,11 @@ var _export = function (options, source) {
929
931
  var STATIC = options.stat;
930
932
  var FORCED, target, key, targetProperty, sourceProperty, descriptor;
931
933
  if (GLOBAL) {
932
- target = global$n;
934
+ target = global$q;
933
935
  } else if (STATIC) {
934
- target = global$n[TARGET] || setGlobal(TARGET, {});
936
+ target = global$q[TARGET] || setGlobal(TARGET, {});
935
937
  } else {
936
- target = (global$n[TARGET] || {}).prototype;
938
+ target = (global$q[TARGET] || {}).prototype;
937
939
  }
938
940
  if (target) for (key in source) {
939
941
  sourceProperty = source[key];
@@ -956,9 +958,9 @@ var _export = function (options, source) {
956
958
  }
957
959
  };
958
960
 
959
- var global$m = global$H;
961
+ var global$p = global$K;
960
962
 
961
- var nativePromiseConstructor = global$m.Promise;
963
+ var nativePromiseConstructor = global$p.Promise;
962
964
 
963
965
  var redefine$4 = redefine$6.exports;
964
966
 
@@ -967,21 +969,21 @@ var redefineAll$1 = function (target, src, options) {
967
969
  return target;
968
970
  };
969
971
 
970
- var global$l = global$H;
972
+ var global$o = global$K;
971
973
  var isCallable$9 = isCallable$j;
972
974
 
973
- var String$3 = global$l.String;
974
- var TypeError$9 = global$l.TypeError;
975
+ var String$3 = global$o.String;
976
+ var TypeError$a = global$o.TypeError;
975
977
 
976
978
  var aPossiblePrototype$1 = function (argument) {
977
979
  if (typeof argument == 'object' || isCallable$9(argument)) return argument;
978
- throw TypeError$9("Can't set " + String$3(argument) + ' as a prototype');
980
+ throw TypeError$a("Can't set " + String$3(argument) + ' as a prototype');
979
981
  };
980
982
 
981
983
  /* eslint-disable no-proto -- safe */
982
984
 
983
- var uncurryThis$a = functionUncurryThis;
984
- var anObject$a = anObject$d;
985
+ var uncurryThis$d = functionUncurryThis;
986
+ var anObject$b = anObject$e;
985
987
  var aPossiblePrototype = aPossiblePrototype$1;
986
988
 
987
989
  // `Object.setPrototypeOf` method
@@ -994,12 +996,12 @@ var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? functio
994
996
  var setter;
995
997
  try {
996
998
  // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
997
- setter = uncurryThis$a(Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set);
999
+ setter = uncurryThis$d(Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set);
998
1000
  setter(test, []);
999
1001
  CORRECT_SETTER = test instanceof Array;
1000
1002
  } catch (error) { /* empty */ }
1001
1003
  return function setPrototypeOf(O, proto) {
1002
- anObject$a(O);
1004
+ anObject$b(O);
1003
1005
  aPossiblePrototype(proto);
1004
1006
  if (CORRECT_SETTER) setter(O, proto);
1005
1007
  else O.__proto__ = proto;
@@ -1021,7 +1023,7 @@ var setToStringTag$3 = function (target, TAG, STATIC) {
1021
1023
  };
1022
1024
 
1023
1025
  var getBuiltIn$3 = getBuiltIn$7;
1024
- var definePropertyModule$2 = objectDefineProperty;
1026
+ var definePropertyModule$3 = objectDefineProperty;
1025
1027
  var wellKnownSymbol$f = wellKnownSymbol$i;
1026
1028
  var DESCRIPTORS$3 = descriptors;
1027
1029
 
@@ -1029,7 +1031,7 @@ var SPECIES$3 = wellKnownSymbol$f('species');
1029
1031
 
1030
1032
  var setSpecies$1 = function (CONSTRUCTOR_NAME) {
1031
1033
  var Constructor = getBuiltIn$3(CONSTRUCTOR_NAME);
1032
- var defineProperty = definePropertyModule$2.f;
1034
+ var defineProperty = definePropertyModule$3.f;
1033
1035
 
1034
1036
  if (DESCRIPTORS$3 && Constructor && !Constructor[SPECIES$3]) {
1035
1037
  defineProperty(Constructor, SPECIES$3, {
@@ -1039,25 +1041,25 @@ var setSpecies$1 = function (CONSTRUCTOR_NAME) {
1039
1041
  }
1040
1042
  };
1041
1043
 
1042
- var global$k = global$H;
1044
+ var global$n = global$K;
1043
1045
  var isPrototypeOf$1 = objectIsPrototypeOf;
1044
1046
 
1045
- var TypeError$8 = global$k.TypeError;
1047
+ var TypeError$9 = global$n.TypeError;
1046
1048
 
1047
1049
  var anInstance$1 = function (it, Prototype) {
1048
1050
  if (isPrototypeOf$1(Prototype, it)) return it;
1049
- throw TypeError$8('Incorrect invocation');
1051
+ throw TypeError$9('Incorrect invocation');
1050
1052
  };
1051
1053
 
1052
- var uncurryThis$9 = functionUncurryThis;
1053
- var aCallable$3 = aCallable$5;
1054
+ var uncurryThis$c = functionUncurryThis;
1055
+ var aCallable$4 = aCallable$6;
1054
1056
  var NATIVE_BIND$1 = functionBindNative;
1055
1057
 
1056
- var bind$4 = uncurryThis$9(uncurryThis$9.bind);
1058
+ var bind$4 = uncurryThis$c(uncurryThis$c.bind);
1057
1059
 
1058
1060
  // optional / simple context binding
1059
1061
  var functionBindContext = function (fn, that) {
1060
- aCallable$3(fn);
1062
+ aCallable$4(fn);
1061
1063
  return that === undefined ? fn : NATIVE_BIND$1 ? bind$4(fn, that) : function (/* ...args */) {
1062
1064
  return fn.apply(that, arguments);
1063
1065
  };
@@ -1068,12 +1070,12 @@ var iterators = {};
1068
1070
  var wellKnownSymbol$e = wellKnownSymbol$i;
1069
1071
  var Iterators$4 = iterators;
1070
1072
 
1071
- var ITERATOR$5 = wellKnownSymbol$e('iterator');
1073
+ var ITERATOR$6 = wellKnownSymbol$e('iterator');
1072
1074
  var ArrayPrototype$1 = Array.prototype;
1073
1075
 
1074
1076
  // check on default Array iterator
1075
1077
  var isArrayIteratorMethod$1 = function (it) {
1076
- return it !== undefined && (Iterators$4.Array === it || ArrayPrototype$1[ITERATOR$5] === it);
1078
+ return it !== undefined && (Iterators$4.Array === it || ArrayPrototype$1[ITERATOR$6] === it);
1077
1079
  };
1078
1080
 
1079
1081
  var wellKnownSymbol$d = wellKnownSymbol$i;
@@ -1085,14 +1087,14 @@ test[TO_STRING_TAG$2] = 'z';
1085
1087
 
1086
1088
  var toStringTagSupport = String(test) === '[object z]';
1087
1089
 
1088
- var global$j = global$H;
1090
+ var global$m = global$K;
1089
1091
  var TO_STRING_TAG_SUPPORT = toStringTagSupport;
1090
1092
  var isCallable$8 = isCallable$j;
1091
1093
  var classofRaw = classofRaw$1;
1092
1094
  var wellKnownSymbol$c = wellKnownSymbol$i;
1093
1095
 
1094
1096
  var TO_STRING_TAG$1 = wellKnownSymbol$c('toStringTag');
1095
- var Object$2 = global$j.Object;
1097
+ var Object$2 = global$m.Object;
1096
1098
 
1097
1099
  // ES3 wrong here
1098
1100
  var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) == 'Arguments';
@@ -1117,70 +1119,70 @@ var classof$6 = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {
1117
1119
  };
1118
1120
 
1119
1121
  var classof$5 = classof$6;
1120
- var getMethod$2 = getMethod$4;
1122
+ var getMethod$3 = getMethod$5;
1121
1123
  var Iterators$3 = iterators;
1122
1124
  var wellKnownSymbol$b = wellKnownSymbol$i;
1123
1125
 
1124
- var ITERATOR$4 = wellKnownSymbol$b('iterator');
1126
+ var ITERATOR$5 = wellKnownSymbol$b('iterator');
1125
1127
 
1126
1128
  var getIteratorMethod$2 = function (it) {
1127
- if (it != undefined) return getMethod$2(it, ITERATOR$4)
1128
- || getMethod$2(it, '@@iterator')
1129
+ if (it != undefined) return getMethod$3(it, ITERATOR$5)
1130
+ || getMethod$3(it, '@@iterator')
1129
1131
  || Iterators$3[classof$5(it)];
1130
1132
  };
1131
1133
 
1132
- var global$i = global$H;
1133
- var call$9 = functionCall;
1134
- var aCallable$2 = aCallable$5;
1135
- var anObject$9 = anObject$d;
1134
+ var global$l = global$K;
1135
+ var call$a = functionCall;
1136
+ var aCallable$3 = aCallable$6;
1137
+ var anObject$a = anObject$e;
1136
1138
  var tryToString$2 = tryToString$4;
1137
1139
  var getIteratorMethod$1 = getIteratorMethod$2;
1138
1140
 
1139
- var TypeError$7 = global$i.TypeError;
1141
+ var TypeError$8 = global$l.TypeError;
1140
1142
 
1141
1143
  var getIterator$1 = function (argument, usingIterator) {
1142
1144
  var iteratorMethod = arguments.length < 2 ? getIteratorMethod$1(argument) : usingIterator;
1143
- if (aCallable$2(iteratorMethod)) return anObject$9(call$9(iteratorMethod, argument));
1144
- throw TypeError$7(tryToString$2(argument) + ' is not iterable');
1145
+ if (aCallable$3(iteratorMethod)) return anObject$a(call$a(iteratorMethod, argument));
1146
+ throw TypeError$8(tryToString$2(argument) + ' is not iterable');
1145
1147
  };
1146
1148
 
1147
- var call$8 = functionCall;
1148
- var anObject$8 = anObject$d;
1149
- var getMethod$1 = getMethod$4;
1149
+ var call$9 = functionCall;
1150
+ var anObject$9 = anObject$e;
1151
+ var getMethod$2 = getMethod$5;
1150
1152
 
1151
1153
  var iteratorClose$1 = function (iterator, kind, value) {
1152
1154
  var innerResult, innerError;
1153
- anObject$8(iterator);
1155
+ anObject$9(iterator);
1154
1156
  try {
1155
- innerResult = getMethod$1(iterator, 'return');
1157
+ innerResult = getMethod$2(iterator, 'return');
1156
1158
  if (!innerResult) {
1157
1159
  if (kind === 'throw') throw value;
1158
1160
  return value;
1159
1161
  }
1160
- innerResult = call$8(innerResult, iterator);
1162
+ innerResult = call$9(innerResult, iterator);
1161
1163
  } catch (error) {
1162
1164
  innerError = true;
1163
1165
  innerResult = error;
1164
1166
  }
1165
1167
  if (kind === 'throw') throw value;
1166
1168
  if (innerError) throw innerResult;
1167
- anObject$8(innerResult);
1169
+ anObject$9(innerResult);
1168
1170
  return value;
1169
1171
  };
1170
1172
 
1171
- var global$h = global$H;
1173
+ var global$k = global$K;
1172
1174
  var bind$3 = functionBindContext;
1173
- var call$7 = functionCall;
1174
- var anObject$7 = anObject$d;
1175
+ var call$8 = functionCall;
1176
+ var anObject$8 = anObject$e;
1175
1177
  var tryToString$1 = tryToString$4;
1176
1178
  var isArrayIteratorMethod = isArrayIteratorMethod$1;
1177
- var lengthOfArrayLike = lengthOfArrayLike$2;
1179
+ var lengthOfArrayLike$2 = lengthOfArrayLike$4;
1178
1180
  var isPrototypeOf = objectIsPrototypeOf;
1179
1181
  var getIterator = getIterator$1;
1180
1182
  var getIteratorMethod = getIteratorMethod$2;
1181
1183
  var iteratorClose = iteratorClose$1;
1182
1184
 
1183
- var TypeError$6 = global$h.TypeError;
1185
+ var TypeError$7 = global$k.TypeError;
1184
1186
 
1185
1187
  var Result = function (stopped, result) {
1186
1188
  this.stopped = stopped;
@@ -1204,7 +1206,7 @@ var iterate$1 = function (iterable, unboundFunction, options) {
1204
1206
 
1205
1207
  var callFn = function (value) {
1206
1208
  if (AS_ENTRIES) {
1207
- anObject$7(value);
1209
+ anObject$8(value);
1208
1210
  return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);
1209
1211
  } return INTERRUPTED ? fn(value, stop) : fn(value);
1210
1212
  };
@@ -1213,10 +1215,10 @@ var iterate$1 = function (iterable, unboundFunction, options) {
1213
1215
  iterator = iterable;
1214
1216
  } else {
1215
1217
  iterFn = getIteratorMethod(iterable);
1216
- if (!iterFn) throw TypeError$6(tryToString$1(iterable) + ' is not iterable');
1218
+ if (!iterFn) throw TypeError$7(tryToString$1(iterable) + ' is not iterable');
1217
1219
  // optimisation for array iterators
1218
1220
  if (isArrayIteratorMethod(iterFn)) {
1219
- for (index = 0, length = lengthOfArrayLike(iterable); length > index; index++) {
1221
+ for (index = 0, length = lengthOfArrayLike$2(iterable); length > index; index++) {
1220
1222
  result = callFn(iterable[index]);
1221
1223
  if (result && isPrototypeOf(ResultPrototype, result)) return result;
1222
1224
  } return new Result(false);
@@ -1225,7 +1227,7 @@ var iterate$1 = function (iterable, unboundFunction, options) {
1225
1227
  }
1226
1228
 
1227
1229
  next = iterator.next;
1228
- while (!(step = call$7(next, iterator)).done) {
1230
+ while (!(step = call$8(next, iterator)).done) {
1229
1231
  try {
1230
1232
  result = callFn(step.value);
1231
1233
  } catch (error) {
@@ -1237,7 +1239,7 @@ var iterate$1 = function (iterable, unboundFunction, options) {
1237
1239
 
1238
1240
  var wellKnownSymbol$a = wellKnownSymbol$i;
1239
1241
 
1240
- var ITERATOR$3 = wellKnownSymbol$a('iterator');
1242
+ var ITERATOR$4 = wellKnownSymbol$a('iterator');
1241
1243
  var SAFE_CLOSING = false;
1242
1244
 
1243
1245
  try {
@@ -1250,7 +1252,7 @@ try {
1250
1252
  SAFE_CLOSING = true;
1251
1253
  }
1252
1254
  };
1253
- iteratorWithReturn[ITERATOR$3] = function () {
1255
+ iteratorWithReturn[ITERATOR$4] = function () {
1254
1256
  return this;
1255
1257
  };
1256
1258
  // eslint-disable-next-line es/no-array-from, no-throw-literal -- required for testing
@@ -1262,7 +1264,7 @@ var checkCorrectnessOfIteration$1 = function (exec, SKIP_CLOSING) {
1262
1264
  var ITERATION_SUPPORT = false;
1263
1265
  try {
1264
1266
  var object = {};
1265
- object[ITERATOR$3] = function () {
1267
+ object[ITERATOR$4] = function () {
1266
1268
  return {
1267
1269
  next: function () {
1268
1270
  return { done: ITERATION_SUPPORT = true };
@@ -1274,8 +1276,8 @@ var checkCorrectnessOfIteration$1 = function (exec, SKIP_CLOSING) {
1274
1276
  return ITERATION_SUPPORT;
1275
1277
  };
1276
1278
 
1277
- var uncurryThis$8 = functionUncurryThis;
1278
- var fails$9 = fails$h;
1279
+ var uncurryThis$b = functionUncurryThis;
1280
+ var fails$c = fails$k;
1279
1281
  var isCallable$7 = isCallable$j;
1280
1282
  var classof$4 = classof$6;
1281
1283
  var getBuiltIn$2 = getBuiltIn$7;
@@ -1285,7 +1287,7 @@ var noop = function () { /* empty */ };
1285
1287
  var empty = [];
1286
1288
  var construct = getBuiltIn$2('Reflect', 'construct');
1287
1289
  var constructorRegExp = /^\s*(?:class|function)\b/;
1288
- var exec$1 = uncurryThis$8(constructorRegExp.exec);
1290
+ var exec$3 = uncurryThis$b(constructorRegExp.exec);
1289
1291
  var INCORRECT_TO_STRING = !constructorRegExp.exec(noop);
1290
1292
 
1291
1293
  var isConstructorModern = function isConstructor(argument) {
@@ -1309,7 +1311,7 @@ var isConstructorLegacy = function isConstructor(argument) {
1309
1311
  // we can't check .prototype since constructors produced by .bind haven't it
1310
1312
  // `Function#toString` throws on some built-it function in some legacy engines
1311
1313
  // (for example, `DOMQuad` and similar in FF41-)
1312
- return INCORRECT_TO_STRING || !!exec$1(constructorRegExp, inspectSource$1(argument));
1314
+ return INCORRECT_TO_STRING || !!exec$3(constructorRegExp, inspectSource$1(argument));
1313
1315
  } catch (error) {
1314
1316
  return true;
1315
1317
  }
@@ -1319,7 +1321,7 @@ isConstructorLegacy.sham = true;
1319
1321
 
1320
1322
  // `IsConstructor` abstract operation
1321
1323
  // https://tc39.es/ecma262/#sec-isconstructor
1322
- var isConstructor$1 = !construct || fails$9(function () {
1324
+ var isConstructor$1 = !construct || fails$c(function () {
1323
1325
  var called;
1324
1326
  return isConstructorModern(isConstructorModern.call)
1325
1327
  || !isConstructorModern(Object)
@@ -1327,19 +1329,19 @@ var isConstructor$1 = !construct || fails$9(function () {
1327
1329
  || called;
1328
1330
  }) ? isConstructorLegacy : isConstructorModern;
1329
1331
 
1330
- var global$g = global$H;
1332
+ var global$j = global$K;
1331
1333
  var isConstructor = isConstructor$1;
1332
1334
  var tryToString = tryToString$4;
1333
1335
 
1334
- var TypeError$5 = global$g.TypeError;
1336
+ var TypeError$6 = global$j.TypeError;
1335
1337
 
1336
1338
  // `Assert: IsConstructor(argument) is true`
1337
1339
  var aConstructor$1 = function (argument) {
1338
1340
  if (isConstructor(argument)) return argument;
1339
- throw TypeError$5(tryToString(argument) + ' is not a constructor');
1341
+ throw TypeError$6(tryToString(argument) + ' is not a constructor');
1340
1342
  };
1341
1343
 
1342
- var anObject$6 = anObject$d;
1344
+ var anObject$7 = anObject$e;
1343
1345
  var aConstructor = aConstructor$1;
1344
1346
  var wellKnownSymbol$9 = wellKnownSymbol$i;
1345
1347
 
@@ -1347,37 +1349,37 @@ var SPECIES$2 = wellKnownSymbol$9('species');
1347
1349
 
1348
1350
  // `SpeciesConstructor` abstract operation
1349
1351
  // https://tc39.es/ecma262/#sec-speciesconstructor
1350
- var speciesConstructor$1 = function (O, defaultConstructor) {
1351
- var C = anObject$6(O).constructor;
1352
+ var speciesConstructor$2 = function (O, defaultConstructor) {
1353
+ var C = anObject$7(O).constructor;
1352
1354
  var S;
1353
- return C === undefined || (S = anObject$6(C)[SPECIES$2]) == undefined ? defaultConstructor : aConstructor(S);
1355
+ return C === undefined || (S = anObject$7(C)[SPECIES$2]) == undefined ? defaultConstructor : aConstructor(S);
1354
1356
  };
1355
1357
 
1356
1358
  var NATIVE_BIND = functionBindNative;
1357
1359
 
1358
1360
  var FunctionPrototype = Function.prototype;
1359
- var apply$2 = FunctionPrototype.apply;
1360
- var call$6 = FunctionPrototype.call;
1361
+ var apply$3 = FunctionPrototype.apply;
1362
+ var call$7 = FunctionPrototype.call;
1361
1363
 
1362
1364
  // eslint-disable-next-line es/no-reflect -- safe
1363
- var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call$6.bind(apply$2) : function () {
1364
- return call$6.apply(apply$2, arguments);
1365
+ var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call$7.bind(apply$3) : function () {
1366
+ return call$7.apply(apply$3, arguments);
1365
1367
  });
1366
1368
 
1367
1369
  var getBuiltIn$1 = getBuiltIn$7;
1368
1370
 
1369
1371
  var html$2 = getBuiltIn$1('document', 'documentElement');
1370
1372
 
1371
- var uncurryThis$7 = functionUncurryThis;
1373
+ var uncurryThis$a = functionUncurryThis;
1372
1374
 
1373
- var arraySlice$1 = uncurryThis$7([].slice);
1375
+ var arraySlice$2 = uncurryThis$a([].slice);
1374
1376
 
1375
- var global$f = global$H;
1377
+ var global$i = global$K;
1376
1378
 
1377
- var TypeError$4 = global$f.TypeError;
1379
+ var TypeError$5 = global$i.TypeError;
1378
1380
 
1379
1381
  var validateArgumentsLength$1 = function (passed, required) {
1380
- if (passed < required) throw TypeError$4('Not enough arguments');
1382
+ if (passed < required) throw TypeError$5('Not enough arguments');
1381
1383
  return passed;
1382
1384
  };
1383
1385
 
@@ -1386,30 +1388,30 @@ var userAgent$2 = engineUserAgent;
1386
1388
  var engineIsIos = /(?:ipad|iphone|ipod).*applewebkit/i.test(userAgent$2);
1387
1389
 
1388
1390
  var classof$3 = classofRaw$1;
1389
- var global$e = global$H;
1391
+ var global$h = global$K;
1390
1392
 
1391
- var engineIsNode = classof$3(global$e.process) == 'process';
1393
+ var engineIsNode = classof$3(global$h.process) == 'process';
1392
1394
 
1393
- var global$d = global$H;
1394
- var apply$1 = functionApply;
1395
+ var global$g = global$K;
1396
+ var apply$2 = functionApply;
1395
1397
  var bind$2 = functionBindContext;
1396
1398
  var isCallable$6 = isCallable$j;
1397
1399
  var hasOwn$1 = hasOwnProperty_1;
1398
- var fails$8 = fails$h;
1400
+ var fails$b = fails$k;
1399
1401
  var html$1 = html$2;
1400
- var arraySlice = arraySlice$1;
1402
+ var arraySlice$1 = arraySlice$2;
1401
1403
  var createElement = documentCreateElement$2;
1402
1404
  var validateArgumentsLength = validateArgumentsLength$1;
1403
1405
  var IS_IOS$1 = engineIsIos;
1404
- var IS_NODE$2 = engineIsNode;
1405
-
1406
- var set$1 = global$d.setImmediate;
1407
- var clear = global$d.clearImmediate;
1408
- var process$3 = global$d.process;
1409
- var Dispatch = global$d.Dispatch;
1410
- var Function$1 = global$d.Function;
1411
- var MessageChannel = global$d.MessageChannel;
1412
- var String$2 = global$d.String;
1406
+ var IS_NODE$3 = engineIsNode;
1407
+
1408
+ var set$1 = global$g.setImmediate;
1409
+ var clear = global$g.clearImmediate;
1410
+ var process$2 = global$g.process;
1411
+ var Dispatch = global$g.Dispatch;
1412
+ var Function$1 = global$g.Function;
1413
+ var MessageChannel = global$g.MessageChannel;
1414
+ var String$2 = global$g.String;
1413
1415
  var counter = 0;
1414
1416
  var queue$1 = {};
1415
1417
  var ONREADYSTATECHANGE = 'onreadystatechange';
@@ -1417,7 +1419,7 @@ var location, defer, channel, port;
1417
1419
 
1418
1420
  try {
1419
1421
  // Deno throws a ReferenceError on `location` access without `--location` flag
1420
- location = global$d.location;
1422
+ location = global$g.location;
1421
1423
  } catch (error) { /* empty */ }
1422
1424
 
1423
1425
  var run = function (id) {
@@ -1440,7 +1442,7 @@ var listener = function (event) {
1440
1442
 
1441
1443
  var post = function (id) {
1442
1444
  // old engines have not location.origin
1443
- global$d.postMessage(String$2(id), location.protocol + '//' + location.host);
1445
+ global$g.postMessage(String$2(id), location.protocol + '//' + location.host);
1444
1446
  };
1445
1447
 
1446
1448
  // Node.js 0.9+ & IE10+ has setImmediate, otherwise:
@@ -1448,9 +1450,9 @@ if (!set$1 || !clear) {
1448
1450
  set$1 = function setImmediate(handler) {
1449
1451
  validateArgumentsLength(arguments.length, 1);
1450
1452
  var fn = isCallable$6(handler) ? handler : Function$1(handler);
1451
- var args = arraySlice(arguments, 1);
1453
+ var args = arraySlice$1(arguments, 1);
1452
1454
  queue$1[++counter] = function () {
1453
- apply$1(fn, undefined, args);
1455
+ apply$2(fn, undefined, args);
1454
1456
  };
1455
1457
  defer(counter);
1456
1458
  return counter;
@@ -1459,9 +1461,9 @@ if (!set$1 || !clear) {
1459
1461
  delete queue$1[id];
1460
1462
  };
1461
1463
  // Node.js 0.8-
1462
- if (IS_NODE$2) {
1464
+ if (IS_NODE$3) {
1463
1465
  defer = function (id) {
1464
- process$3.nextTick(runner(id));
1466
+ process$2.nextTick(runner(id));
1465
1467
  };
1466
1468
  // Sphere (JS game engine) Dispatch API
1467
1469
  } else if (Dispatch && Dispatch.now) {
@@ -1478,14 +1480,14 @@ if (!set$1 || !clear) {
1478
1480
  // Browsers with postMessage, skip WebWorkers
1479
1481
  // IE8 has postMessage, but it's sync & typeof its postMessage is 'object'
1480
1482
  } else if (
1481
- global$d.addEventListener &&
1482
- isCallable$6(global$d.postMessage) &&
1483
- !global$d.importScripts &&
1483
+ global$g.addEventListener &&
1484
+ isCallable$6(global$g.postMessage) &&
1485
+ !global$g.importScripts &&
1484
1486
  location && location.protocol !== 'file:' &&
1485
- !fails$8(post)
1487
+ !fails$b(post)
1486
1488
  ) {
1487
1489
  defer = post;
1488
- global$d.addEventListener('message', listener, false);
1490
+ global$g.addEventListener('message', listener, false);
1489
1491
  // IE8-
1490
1492
  } else if (ONREADYSTATECHANGE in createElement('script')) {
1491
1493
  defer = function (id) {
@@ -1508,29 +1510,29 @@ var task$1 = {
1508
1510
  };
1509
1511
 
1510
1512
  var userAgent$1 = engineUserAgent;
1511
- var global$c = global$H;
1513
+ var global$f = global$K;
1512
1514
 
1513
- var engineIsIosPebble = /ipad|iphone|ipod/i.test(userAgent$1) && global$c.Pebble !== undefined;
1515
+ var engineIsIosPebble = /ipad|iphone|ipod/i.test(userAgent$1) && global$f.Pebble !== undefined;
1514
1516
 
1515
1517
  var userAgent = engineUserAgent;
1516
1518
 
1517
1519
  var engineIsWebosWebkit = /web0s(?!.*chrome)/i.test(userAgent);
1518
1520
 
1519
- var global$b = global$H;
1521
+ var global$e = global$K;
1520
1522
  var bind$1 = functionBindContext;
1521
1523
  var getOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
1522
1524
  var macrotask = task$1.set;
1523
1525
  var IS_IOS = engineIsIos;
1524
1526
  var IS_IOS_PEBBLE = engineIsIosPebble;
1525
1527
  var IS_WEBOS_WEBKIT = engineIsWebosWebkit;
1526
- var IS_NODE$1 = engineIsNode;
1528
+ var IS_NODE$2 = engineIsNode;
1527
1529
 
1528
- var MutationObserver = global$b.MutationObserver || global$b.WebKitMutationObserver;
1529
- var document$2 = global$b.document;
1530
- var process$2 = global$b.process;
1531
- var Promise$1 = global$b.Promise;
1530
+ var MutationObserver = global$e.MutationObserver || global$e.WebKitMutationObserver;
1531
+ var document$2 = global$e.document;
1532
+ var process$1 = global$e.process;
1533
+ var Promise$1 = global$e.Promise;
1532
1534
  // Node.js 11 shows ExperimentalWarning on getting `queueMicrotask`
1533
- var queueMicrotaskDescriptor = getOwnPropertyDescriptor$1(global$b, 'queueMicrotask');
1535
+ var queueMicrotaskDescriptor = getOwnPropertyDescriptor$1(global$e, 'queueMicrotask');
1534
1536
  var queueMicrotask = queueMicrotaskDescriptor && queueMicrotaskDescriptor.value;
1535
1537
 
1536
1538
  var flush, head, last, notify$1, toggle, node, promise, then;
@@ -1539,7 +1541,7 @@ var flush, head, last, notify$1, toggle, node, promise, then;
1539
1541
  if (!queueMicrotask) {
1540
1542
  flush = function () {
1541
1543
  var parent, fn;
1542
- if (IS_NODE$1 && (parent = process$2.domain)) parent.exit();
1544
+ if (IS_NODE$2 && (parent = process$1.domain)) parent.exit();
1543
1545
  while (head) {
1544
1546
  fn = head.fn;
1545
1547
  head = head.next;
@@ -1556,7 +1558,7 @@ if (!queueMicrotask) {
1556
1558
 
1557
1559
  // browsers with MutationObserver, except iOS - https://github.com/zloirock/core-js/issues/339
1558
1560
  // also except WebOS Webkit https://github.com/zloirock/core-js/issues/898
1559
- if (!IS_IOS && !IS_NODE$1 && !IS_WEBOS_WEBKIT && MutationObserver && document$2) {
1561
+ if (!IS_IOS && !IS_NODE$2 && !IS_WEBOS_WEBKIT && MutationObserver && document$2) {
1560
1562
  toggle = true;
1561
1563
  node = document$2.createTextNode('');
1562
1564
  new MutationObserver(flush).observe(node, { characterData: true });
@@ -1574,9 +1576,9 @@ if (!queueMicrotask) {
1574
1576
  then(flush);
1575
1577
  };
1576
1578
  // Node.js without promises
1577
- } else if (IS_NODE$1) {
1579
+ } else if (IS_NODE$2) {
1578
1580
  notify$1 = function () {
1579
- process$2.nextTick(flush);
1581
+ process$1.nextTick(flush);
1580
1582
  };
1581
1583
  // for other environments - macrotask based on:
1582
1584
  // - setImmediate
@@ -1586,7 +1588,7 @@ if (!queueMicrotask) {
1586
1588
  // - setTimeout
1587
1589
  } else {
1588
1590
  // strange IE + webpack dev server bug - use .bind(global)
1589
- macrotask = bind$1(macrotask, global$b);
1591
+ macrotask = bind$1(macrotask, global$e);
1590
1592
  notify$1 = function () {
1591
1593
  macrotask(flush);
1592
1594
  };
@@ -1604,7 +1606,7 @@ var microtask$1 = queueMicrotask || function (fn) {
1604
1606
 
1605
1607
  var newPromiseCapability$2 = {};
1606
1608
 
1607
- var aCallable$1 = aCallable$5;
1609
+ var aCallable$2 = aCallable$6;
1608
1610
 
1609
1611
  var PromiseCapability = function (C) {
1610
1612
  var resolve, reject;
@@ -1613,8 +1615,8 @@ var PromiseCapability = function (C) {
1613
1615
  resolve = $$resolve;
1614
1616
  reject = $$reject;
1615
1617
  });
1616
- this.resolve = aCallable$1(resolve);
1617
- this.reject = aCallable$1(reject);
1618
+ this.resolve = aCallable$2(resolve);
1619
+ this.reject = aCallable$2(reject);
1618
1620
  };
1619
1621
 
1620
1622
  // `NewPromiseCapability` abstract operation
@@ -1623,12 +1625,12 @@ newPromiseCapability$2.f = function (C) {
1623
1625
  return new PromiseCapability(C);
1624
1626
  };
1625
1627
 
1626
- var anObject$5 = anObject$d;
1628
+ var anObject$6 = anObject$e;
1627
1629
  var isObject$2 = isObject$8;
1628
1630
  var newPromiseCapability$1 = newPromiseCapability$2;
1629
1631
 
1630
1632
  var promiseResolve$1 = function (C, x) {
1631
- anObject$5(C);
1633
+ anObject$6(C);
1632
1634
  if (isObject$2(x) && x.constructor === C) return x;
1633
1635
  var promiseCapability = newPromiseCapability$1.f(C);
1634
1636
  var resolve = promiseCapability.resolve;
@@ -1636,10 +1638,10 @@ var promiseResolve$1 = function (C, x) {
1636
1638
  return promiseCapability.promise;
1637
1639
  };
1638
1640
 
1639
- var global$a = global$H;
1641
+ var global$d = global$K;
1640
1642
 
1641
1643
  var hostReportErrors$1 = function (a, b) {
1642
- var console = global$a.console;
1644
+ var console = global$d.console;
1643
1645
  if (console && console.error) {
1644
1646
  arguments.length == 1 ? console.error(a) : console.error(a, b);
1645
1647
  }
@@ -1679,24 +1681,24 @@ var queue = Queue$1;
1679
1681
 
1680
1682
  var engineIsBrowser = typeof window == 'object';
1681
1683
 
1682
- var $$4 = _export;
1683
- var global$9 = global$H;
1684
+ var $$6 = _export;
1685
+ var global$c = global$K;
1684
1686
  var getBuiltIn = getBuiltIn$7;
1685
- var call$5 = functionCall;
1687
+ var call$6 = functionCall;
1686
1688
  var NativePromise = nativePromiseConstructor;
1687
1689
  var redefine$3 = redefine$6.exports;
1688
1690
  var redefineAll = redefineAll$1;
1689
1691
  var setPrototypeOf$1 = objectSetPrototypeOf;
1690
1692
  var setToStringTag$2 = setToStringTag$3;
1691
1693
  var setSpecies = setSpecies$1;
1692
- var aCallable = aCallable$5;
1694
+ var aCallable$1 = aCallable$6;
1693
1695
  var isCallable$5 = isCallable$j;
1694
1696
  var isObject$1 = isObject$8;
1695
1697
  var anInstance = anInstance$1;
1696
1698
  var inspectSource = inspectSource$4;
1697
1699
  var iterate = iterate$1;
1698
1700
  var checkCorrectnessOfIteration = checkCorrectnessOfIteration$1;
1699
- var speciesConstructor = speciesConstructor$1;
1701
+ var speciesConstructor$1 = speciesConstructor$2;
1700
1702
  var task = task$1.set;
1701
1703
  var microtask = microtask$1;
1702
1704
  var promiseResolve = promiseResolve$1;
@@ -1708,7 +1710,7 @@ var InternalStateModule$1 = internalState;
1708
1710
  var isForced = isForced_1;
1709
1711
  var wellKnownSymbol$8 = wellKnownSymbol$i;
1710
1712
  var IS_BROWSER = engineIsBrowser;
1711
- var IS_NODE = engineIsNode;
1713
+ var IS_NODE$1 = engineIsNode;
1712
1714
  var V8_VERSION = engineV8Version;
1713
1715
 
1714
1716
  var SPECIES$1 = wellKnownSymbol$8('species');
@@ -1720,14 +1722,14 @@ var getInternalPromiseState = InternalStateModule$1.getterFor(PROMISE);
1720
1722
  var NativePromisePrototype = NativePromise && NativePromise.prototype;
1721
1723
  var PromiseConstructor = NativePromise;
1722
1724
  var PromisePrototype = NativePromisePrototype;
1723
- var TypeError$3 = global$9.TypeError;
1724
- var document$1 = global$9.document;
1725
- var process$1 = global$9.process;
1725
+ var TypeError$4 = global$c.TypeError;
1726
+ var document$1 = global$c.document;
1727
+ var process = global$c.process;
1726
1728
  var newPromiseCapability = newPromiseCapabilityModule.f;
1727
1729
  var newGenericPromiseCapability = newPromiseCapability;
1728
1730
 
1729
- var DISPATCH_EVENT = !!(document$1 && document$1.createEvent && global$9.dispatchEvent);
1730
- var NATIVE_REJECTION_EVENT = isCallable$5(global$9.PromiseRejectionEvent);
1731
+ var DISPATCH_EVENT = !!(document$1 && document$1.createEvent && global$c.dispatchEvent);
1732
+ var NATIVE_REJECTION_EVENT = isCallable$5(global$c.PromiseRejectionEvent);
1731
1733
  var UNHANDLED_REJECTION = 'unhandledrejection';
1732
1734
  var REJECTION_HANDLED = 'rejectionhandled';
1733
1735
  var PENDING = 0;
@@ -1739,7 +1741,7 @@ var SUBCLASSING = false;
1739
1741
 
1740
1742
  var Internal, OwnPromiseCapability, PromiseWrapper, nativeThen;
1741
1743
 
1742
- var FORCED = isForced(PROMISE, function () {
1744
+ var FORCED$1 = isForced(PROMISE, function () {
1743
1745
  var PROMISE_CONSTRUCTOR_SOURCE = inspectSource(PromiseConstructor);
1744
1746
  var GLOBAL_CORE_JS_PROMISE = PROMISE_CONSTRUCTOR_SOURCE !== String(PromiseConstructor);
1745
1747
  // V8 6.6 (Node 10 and Chrome 66) have a bug with resolving custom thenables
@@ -1763,7 +1765,7 @@ var FORCED = isForced(PROMISE, function () {
1763
1765
  return !GLOBAL_CORE_JS_PROMISE && IS_BROWSER && !NATIVE_REJECTION_EVENT;
1764
1766
  });
1765
1767
 
1766
- var INCORRECT_ITERATION = FORCED || !checkCorrectnessOfIteration(function (iterable) {
1768
+ var INCORRECT_ITERATION = FORCED$1 || !checkCorrectnessOfIteration(function (iterable) {
1767
1769
  PromiseConstructor.all(iterable)['catch'](function () { /* empty */ });
1768
1770
  });
1769
1771
 
@@ -1797,9 +1799,9 @@ var callReaction = function (reaction, state) {
1797
1799
  }
1798
1800
  }
1799
1801
  if (result === reaction.promise) {
1800
- reject(TypeError$3('Promise-chain cycle'));
1802
+ reject(TypeError$4('Promise-chain cycle'));
1801
1803
  } else if (then = isThenable(result)) {
1802
- call$5(then, result, resolve, reject);
1804
+ call$6(then, result, resolve, reject);
1803
1805
  } else resolve(result);
1804
1806
  } else reject(value);
1805
1807
  } catch (error) {
@@ -1829,26 +1831,26 @@ var dispatchEvent = function (name, promise, reason) {
1829
1831
  event.promise = promise;
1830
1832
  event.reason = reason;
1831
1833
  event.initEvent(name, false, true);
1832
- global$9.dispatchEvent(event);
1834
+ global$c.dispatchEvent(event);
1833
1835
  } else event = { promise: promise, reason: reason };
1834
- if (!NATIVE_REJECTION_EVENT && (handler = global$9['on' + name])) handler(event);
1836
+ if (!NATIVE_REJECTION_EVENT && (handler = global$c['on' + name])) handler(event);
1835
1837
  else if (name === UNHANDLED_REJECTION) hostReportErrors('Unhandled promise rejection', reason);
1836
1838
  };
1837
1839
 
1838
1840
  var onUnhandled = function (state) {
1839
- call$5(task, global$9, function () {
1841
+ call$6(task, global$c, function () {
1840
1842
  var promise = state.facade;
1841
1843
  var value = state.value;
1842
1844
  var IS_UNHANDLED = isUnhandled(state);
1843
1845
  var result;
1844
1846
  if (IS_UNHANDLED) {
1845
1847
  result = perform(function () {
1846
- if (IS_NODE) {
1847
- process$1.emit('unhandledRejection', value, promise);
1848
+ if (IS_NODE$1) {
1849
+ process.emit('unhandledRejection', value, promise);
1848
1850
  } else dispatchEvent(UNHANDLED_REJECTION, promise, value);
1849
1851
  });
1850
1852
  // Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should
1851
- state.rejection = IS_NODE || isUnhandled(state) ? UNHANDLED : HANDLED;
1853
+ state.rejection = IS_NODE$1 || isUnhandled(state) ? UNHANDLED : HANDLED;
1852
1854
  if (result.error) throw result.value;
1853
1855
  }
1854
1856
  });
@@ -1859,10 +1861,10 @@ var isUnhandled = function (state) {
1859
1861
  };
1860
1862
 
1861
1863
  var onHandleUnhandled = function (state) {
1862
- call$5(task, global$9, function () {
1864
+ call$6(task, global$c, function () {
1863
1865
  var promise = state.facade;
1864
- if (IS_NODE) {
1865
- process$1.emit('rejectionHandled', promise);
1866
+ if (IS_NODE$1) {
1867
+ process.emit('rejectionHandled', promise);
1866
1868
  } else dispatchEvent(REJECTION_HANDLED, promise, state.value);
1867
1869
  });
1868
1870
  };
@@ -1887,13 +1889,13 @@ var internalResolve = function (state, value, unwrap) {
1887
1889
  state.done = true;
1888
1890
  if (unwrap) state = unwrap;
1889
1891
  try {
1890
- if (state.facade === value) throw TypeError$3("Promise can't be resolved itself");
1892
+ if (state.facade === value) throw TypeError$4("Promise can't be resolved itself");
1891
1893
  var then = isThenable(value);
1892
1894
  if (then) {
1893
1895
  microtask(function () {
1894
1896
  var wrapper = { done: false };
1895
1897
  try {
1896
- call$5(then, value,
1898
+ call$6(then, value,
1897
1899
  bind(internalResolve, wrapper, state),
1898
1900
  bind(internalReject, wrapper, state)
1899
1901
  );
@@ -1912,12 +1914,12 @@ var internalResolve = function (state, value, unwrap) {
1912
1914
  };
1913
1915
 
1914
1916
  // constructor polyfill
1915
- if (FORCED) {
1917
+ if (FORCED$1) {
1916
1918
  // 25.4.3.1 Promise(executor)
1917
1919
  PromiseConstructor = function Promise(executor) {
1918
1920
  anInstance(this, PromisePrototype);
1919
- aCallable(executor);
1920
- call$5(Internal, this);
1921
+ aCallable$1(executor);
1922
+ call$6(Internal, this);
1921
1923
  var state = getInternalState$2(this);
1922
1924
  try {
1923
1925
  executor(bind(internalResolve, state), bind(internalReject, state));
@@ -1945,11 +1947,11 @@ if (FORCED) {
1945
1947
  // eslint-disable-next-line unicorn/no-thenable -- safe
1946
1948
  then: function then(onFulfilled, onRejected) {
1947
1949
  var state = getInternalPromiseState(this);
1948
- var reaction = newPromiseCapability(speciesConstructor(this, PromiseConstructor));
1950
+ var reaction = newPromiseCapability(speciesConstructor$1(this, PromiseConstructor));
1949
1951
  state.parent = true;
1950
1952
  reaction.ok = isCallable$5(onFulfilled) ? onFulfilled : true;
1951
1953
  reaction.fail = isCallable$5(onRejected) && onRejected;
1952
- reaction.domain = IS_NODE ? process$1.domain : undefined;
1954
+ reaction.domain = IS_NODE$1 ? process.domain : undefined;
1953
1955
  if (state.state == PENDING) state.reactions.add(reaction);
1954
1956
  else microtask(function () {
1955
1957
  callReaction(reaction, state);
@@ -1983,7 +1985,7 @@ if (FORCED) {
1983
1985
  redefine$3(NativePromisePrototype, 'then', function then(onFulfilled, onRejected) {
1984
1986
  var that = this;
1985
1987
  return new PromiseConstructor(function (resolve, reject) {
1986
- call$5(nativeThen, that, resolve, reject);
1988
+ call$6(nativeThen, that, resolve, reject);
1987
1989
  }).then(onFulfilled, onRejected);
1988
1990
  // https://github.com/zloirock/core-js/issues/640
1989
1991
  }, { unsafe: true });
@@ -2004,7 +2006,7 @@ if (FORCED) {
2004
2006
  }
2005
2007
  }
2006
2008
 
2007
- $$4({ global: true, wrap: true, forced: FORCED }, {
2009
+ $$6({ global: true, wrap: true, forced: FORCED$1 }, {
2008
2010
  Promise: PromiseConstructor
2009
2011
  });
2010
2012
 
@@ -2014,17 +2016,17 @@ setSpecies(PROMISE);
2014
2016
  PromiseWrapper = getBuiltIn(PROMISE);
2015
2017
 
2016
2018
  // statics
2017
- $$4({ target: PROMISE, stat: true, forced: FORCED }, {
2019
+ $$6({ target: PROMISE, stat: true, forced: FORCED$1 }, {
2018
2020
  // `Promise.reject` method
2019
2021
  // https://tc39.es/ecma262/#sec-promise.reject
2020
2022
  reject: function reject(r) {
2021
2023
  var capability = newPromiseCapability(this);
2022
- call$5(capability.reject, undefined, r);
2024
+ call$6(capability.reject, undefined, r);
2023
2025
  return capability.promise;
2024
2026
  }
2025
2027
  });
2026
2028
 
2027
- $$4({ target: PROMISE, stat: true, forced: FORCED }, {
2029
+ $$6({ target: PROMISE, stat: true, forced: FORCED$1 }, {
2028
2030
  // `Promise.resolve` method
2029
2031
  // https://tc39.es/ecma262/#sec-promise.resolve
2030
2032
  resolve: function resolve(x) {
@@ -2032,7 +2034,7 @@ $$4({ target: PROMISE, stat: true, forced: FORCED }, {
2032
2034
  }
2033
2035
  });
2034
2036
 
2035
- $$4({ target: PROMISE, stat: true, forced: INCORRECT_ITERATION }, {
2037
+ $$6({ target: PROMISE, stat: true, forced: INCORRECT_ITERATION }, {
2036
2038
  // `Promise.all` method
2037
2039
  // https://tc39.es/ecma262/#sec-promise.all
2038
2040
  all: function all(iterable) {
@@ -2041,7 +2043,7 @@ $$4({ target: PROMISE, stat: true, forced: INCORRECT_ITERATION }, {
2041
2043
  var resolve = capability.resolve;
2042
2044
  var reject = capability.reject;
2043
2045
  var result = perform(function () {
2044
- var $promiseResolve = aCallable(C.resolve);
2046
+ var $promiseResolve = aCallable$1(C.resolve);
2045
2047
  var values = [];
2046
2048
  var counter = 0;
2047
2049
  var remaining = 1;
@@ -2049,7 +2051,7 @@ $$4({ target: PROMISE, stat: true, forced: INCORRECT_ITERATION }, {
2049
2051
  var index = counter++;
2050
2052
  var alreadyCalled = false;
2051
2053
  remaining++;
2052
- call$5($promiseResolve, C, promise).then(function (value) {
2054
+ call$6($promiseResolve, C, promise).then(function (value) {
2053
2055
  if (alreadyCalled) return;
2054
2056
  alreadyCalled = true;
2055
2057
  values[index] = value;
@@ -2068,9 +2070,9 @@ $$4({ target: PROMISE, stat: true, forced: INCORRECT_ITERATION }, {
2068
2070
  var capability = newPromiseCapability(C);
2069
2071
  var reject = capability.reject;
2070
2072
  var result = perform(function () {
2071
- var $promiseResolve = aCallable(C.resolve);
2073
+ var $promiseResolve = aCallable$1(C.resolve);
2072
2074
  iterate(iterable, function (promise) {
2073
- call$5($promiseResolve, C, promise).then(capability.resolve, reject);
2075
+ call$6($promiseResolve, C, promise).then(capability.resolve, reject);
2074
2076
  });
2075
2077
  });
2076
2078
  if (result.error) reject(result.value);
@@ -2089,24 +2091,24 @@ var objectKeys$2 = Object.keys || function keys(O) {
2089
2091
  };
2090
2092
 
2091
2093
  var DESCRIPTORS$2 = descriptors;
2092
- var uncurryThis$6 = functionUncurryThis;
2093
- var call$4 = functionCall;
2094
- var fails$7 = fails$h;
2094
+ var uncurryThis$9 = functionUncurryThis;
2095
+ var call$5 = functionCall;
2096
+ var fails$a = fails$k;
2095
2097
  var objectKeys$1 = objectKeys$2;
2096
2098
  var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols;
2097
2099
  var propertyIsEnumerableModule = objectPropertyIsEnumerable;
2098
- var toObject$2 = toObject$4;
2099
- var IndexedObject = indexedObject;
2100
+ var toObject$3 = toObject$5;
2101
+ var IndexedObject$1 = indexedObject;
2100
2102
 
2101
2103
  // eslint-disable-next-line es/no-object-assign -- safe
2102
2104
  var $assign = Object.assign;
2103
2105
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
2104
2106
  var defineProperty$1 = Object.defineProperty;
2105
- var concat$1 = uncurryThis$6([].concat);
2107
+ var concat$1 = uncurryThis$9([].concat);
2106
2108
 
2107
2109
  // `Object.assign` method
2108
2110
  // https://tc39.es/ecma262/#sec-object.assign
2109
- var objectAssign = !$assign || fails$7(function () {
2111
+ var objectAssign = !$assign || fails$a(function () {
2110
2112
  // should have correct order of operations (Edge bug)
2111
2113
  if (DESCRIPTORS$2 && $assign({ b: 1 }, $assign(defineProperty$1({}, 'a', {
2112
2114
  enumerable: true,
@@ -2127,31 +2129,31 @@ var objectAssign = !$assign || fails$7(function () {
2127
2129
  alphabet.split('').forEach(function (chr) { B[chr] = chr; });
2128
2130
  return $assign({}, A)[symbol] != 7 || objectKeys$1($assign({}, B)).join('') != alphabet;
2129
2131
  }) ? function assign(target, source) { // eslint-disable-line no-unused-vars -- required for `.length`
2130
- var T = toObject$2(target);
2132
+ var T = toObject$3(target);
2131
2133
  var argumentsLength = arguments.length;
2132
2134
  var index = 1;
2133
2135
  var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
2134
2136
  var propertyIsEnumerable = propertyIsEnumerableModule.f;
2135
2137
  while (argumentsLength > index) {
2136
- var S = IndexedObject(arguments[index++]);
2138
+ var S = IndexedObject$1(arguments[index++]);
2137
2139
  var keys = getOwnPropertySymbols ? concat$1(objectKeys$1(S), getOwnPropertySymbols(S)) : objectKeys$1(S);
2138
2140
  var length = keys.length;
2139
2141
  var j = 0;
2140
2142
  var key;
2141
2143
  while (length > j) {
2142
2144
  key = keys[j++];
2143
- if (!DESCRIPTORS$2 || call$4(propertyIsEnumerable, S, key)) T[key] = S[key];
2145
+ if (!DESCRIPTORS$2 || call$5(propertyIsEnumerable, S, key)) T[key] = S[key];
2144
2146
  }
2145
2147
  } return T;
2146
2148
  } : $assign;
2147
2149
 
2148
- var $$3 = _export;
2150
+ var $$5 = _export;
2149
2151
  var assign = objectAssign;
2150
2152
 
2151
2153
  // `Object.assign` method
2152
2154
  // https://tc39.es/ecma262/#sec-object.assign
2153
2155
  // eslint-disable-next-line es/no-object-assign -- required for testing
2154
- $$3({ target: 'Object', stat: true, forced: Object.assign !== assign }, {
2156
+ $$5({ target: 'Object', stat: true, forced: Object.assign !== assign }, {
2155
2157
  assign: assign
2156
2158
  });
2157
2159
 
@@ -2200,6 +2202,11 @@ const set = (cache, {
2200
2202
  instance.storage.setItem(NINETAILED_CACHE_KEY, cache);
2201
2203
  return cache;
2202
2204
  };
2205
+ const remove = ({
2206
+ instance
2207
+ }) => {
2208
+ instance.storage.removeItem(NINETAILED_CACHE_KEY);
2209
+ };
2203
2210
  const reset = ({
2204
2211
  instance
2205
2212
  }) => {
@@ -2208,6 +2215,15 @@ const reset = ({
2208
2215
  });
2209
2216
  };
2210
2217
 
2218
+ var index = /*#__PURE__*/Object.freeze({
2219
+ __proto__: null,
2220
+ initialize: initialize,
2221
+ get: get,
2222
+ set: set,
2223
+ remove: remove,
2224
+ reset: reset
2225
+ });
2226
+
2211
2227
  const buildClientLocale = () => navigator.languages && navigator.languages.length ? navigator.languages[0] : navigator.language;
2212
2228
 
2213
2229
  const buildClientNinetailedRequestContext = () => ({
@@ -2220,724 +2236,14 @@ const buildClientNinetailedRequestContext = () => ({
2220
2236
  }
2221
2237
  });
2222
2238
 
2223
- var browser = {exports: {}};
2224
-
2225
- /**
2226
- * Helpers.
2227
- */
2228
-
2229
- var s = 1000;
2230
- var m = s * 60;
2231
- var h = m * 60;
2232
- var d = h * 24;
2233
- var w = d * 7;
2234
- var y = d * 365.25;
2235
-
2236
- /**
2237
- * Parse or format the given `val`.
2238
- *
2239
- * Options:
2240
- *
2241
- * - `long` verbose formatting [false]
2242
- *
2243
- * @param {String|Number} val
2244
- * @param {Object} [options]
2245
- * @throws {Error} throw an error if val is not a non-empty string or a number
2246
- * @return {String|Number}
2247
- * @api public
2248
- */
2249
-
2250
- var ms = function(val, options) {
2251
- options = options || {};
2252
- var type = typeof val;
2253
- if (type === 'string' && val.length > 0) {
2254
- return parse(val);
2255
- } else if (type === 'number' && isFinite(val)) {
2256
- return options.long ? fmtLong(val) : fmtShort(val);
2257
- }
2258
- throw new Error(
2259
- 'val is not a non-empty string or a valid number. val=' +
2260
- JSON.stringify(val)
2261
- );
2262
- };
2263
-
2264
- /**
2265
- * Parse the given `str` and return milliseconds.
2266
- *
2267
- * @param {String} str
2268
- * @return {Number}
2269
- * @api private
2270
- */
2271
-
2272
- function parse(str) {
2273
- str = String(str);
2274
- if (str.length > 100) {
2275
- return;
2276
- }
2277
- var match = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(
2278
- str
2279
- );
2280
- if (!match) {
2281
- return;
2282
- }
2283
- var n = parseFloat(match[1]);
2284
- var type = (match[2] || 'ms').toLowerCase();
2285
- switch (type) {
2286
- case 'years':
2287
- case 'year':
2288
- case 'yrs':
2289
- case 'yr':
2290
- case 'y':
2291
- return n * y;
2292
- case 'weeks':
2293
- case 'week':
2294
- case 'w':
2295
- return n * w;
2296
- case 'days':
2297
- case 'day':
2298
- case 'd':
2299
- return n * d;
2300
- case 'hours':
2301
- case 'hour':
2302
- case 'hrs':
2303
- case 'hr':
2304
- case 'h':
2305
- return n * h;
2306
- case 'minutes':
2307
- case 'minute':
2308
- case 'mins':
2309
- case 'min':
2310
- case 'm':
2311
- return n * m;
2312
- case 'seconds':
2313
- case 'second':
2314
- case 'secs':
2315
- case 'sec':
2316
- case 's':
2317
- return n * s;
2318
- case 'milliseconds':
2319
- case 'millisecond':
2320
- case 'msecs':
2321
- case 'msec':
2322
- case 'ms':
2323
- return n;
2324
- default:
2325
- return undefined;
2326
- }
2327
- }
2328
-
2329
- /**
2330
- * Short format for `ms`.
2331
- *
2332
- * @param {Number} ms
2333
- * @return {String}
2334
- * @api private
2335
- */
2336
-
2337
- function fmtShort(ms) {
2338
- var msAbs = Math.abs(ms);
2339
- if (msAbs >= d) {
2340
- return Math.round(ms / d) + 'd';
2341
- }
2342
- if (msAbs >= h) {
2343
- return Math.round(ms / h) + 'h';
2344
- }
2345
- if (msAbs >= m) {
2346
- return Math.round(ms / m) + 'm';
2347
- }
2348
- if (msAbs >= s) {
2349
- return Math.round(ms / s) + 's';
2350
- }
2351
- return ms + 'ms';
2352
- }
2353
-
2354
- /**
2355
- * Long format for `ms`.
2356
- *
2357
- * @param {Number} ms
2358
- * @return {String}
2359
- * @api private
2360
- */
2361
-
2362
- function fmtLong(ms) {
2363
- var msAbs = Math.abs(ms);
2364
- if (msAbs >= d) {
2365
- return plural(ms, msAbs, d, 'day');
2366
- }
2367
- if (msAbs >= h) {
2368
- return plural(ms, msAbs, h, 'hour');
2369
- }
2370
- if (msAbs >= m) {
2371
- return plural(ms, msAbs, m, 'minute');
2372
- }
2373
- if (msAbs >= s) {
2374
- return plural(ms, msAbs, s, 'second');
2375
- }
2376
- return ms + ' ms';
2377
- }
2378
-
2379
- /**
2380
- * Pluralization helper.
2381
- */
2382
-
2383
- function plural(ms, msAbs, n, name) {
2384
- var isPlural = msAbs >= n * 1.5;
2385
- return Math.round(ms / n) + ' ' + name + (isPlural ? 's' : '');
2386
- }
2387
-
2388
- /**
2389
- * This is the common logic for both the Node.js and web browser
2390
- * implementations of `debug()`.
2391
- */
2392
-
2393
- function setup(env) {
2394
- createDebug.debug = createDebug;
2395
- createDebug.default = createDebug;
2396
- createDebug.coerce = coerce;
2397
- createDebug.disable = disable;
2398
- createDebug.enable = enable;
2399
- createDebug.enabled = enabled;
2400
- createDebug.humanize = ms;
2401
- createDebug.destroy = destroy;
2402
-
2403
- Object.keys(env).forEach(key => {
2404
- createDebug[key] = env[key];
2405
- });
2406
-
2407
- /**
2408
- * The currently active debug mode names, and names to skip.
2409
- */
2410
-
2411
- createDebug.names = [];
2412
- createDebug.skips = [];
2413
-
2414
- /**
2415
- * Map of special "%n" handling functions, for the debug "format" argument.
2416
- *
2417
- * Valid key names are a single, lower or upper-case letter, i.e. "n" and "N".
2418
- */
2419
- createDebug.formatters = {};
2420
-
2421
- /**
2422
- * Selects a color for a debug namespace
2423
- * @param {String} namespace The namespace string for the debug instance to be colored
2424
- * @return {Number|String} An ANSI color code for the given namespace
2425
- * @api private
2426
- */
2427
- function selectColor(namespace) {
2428
- let hash = 0;
2429
-
2430
- for (let i = 0; i < namespace.length; i++) {
2431
- hash = ((hash << 5) - hash) + namespace.charCodeAt(i);
2432
- hash |= 0; // Convert to 32bit integer
2433
- }
2434
-
2435
- return createDebug.colors[Math.abs(hash) % createDebug.colors.length];
2436
- }
2437
- createDebug.selectColor = selectColor;
2438
-
2439
- /**
2440
- * Create a debugger with the given `namespace`.
2441
- *
2442
- * @param {String} namespace
2443
- * @return {Function}
2444
- * @api public
2445
- */
2446
- function createDebug(namespace) {
2447
- let prevTime;
2448
- let enableOverride = null;
2449
- let namespacesCache;
2450
- let enabledCache;
2451
-
2452
- function debug(...args) {
2453
- // Disabled?
2454
- if (!debug.enabled) {
2455
- return;
2456
- }
2457
-
2458
- const self = debug;
2459
-
2460
- // Set `diff` timestamp
2461
- const curr = Number(new Date());
2462
- const ms = curr - (prevTime || curr);
2463
- self.diff = ms;
2464
- self.prev = prevTime;
2465
- self.curr = curr;
2466
- prevTime = curr;
2467
-
2468
- args[0] = createDebug.coerce(args[0]);
2469
-
2470
- if (typeof args[0] !== 'string') {
2471
- // Anything else let's inspect with %O
2472
- args.unshift('%O');
2473
- }
2474
-
2475
- // Apply any `formatters` transformations
2476
- let index = 0;
2477
- args[0] = args[0].replace(/%([a-zA-Z%])/g, (match, format) => {
2478
- // If we encounter an escaped % then don't increase the array index
2479
- if (match === '%%') {
2480
- return '%';
2481
- }
2482
- index++;
2483
- const formatter = createDebug.formatters[format];
2484
- if (typeof formatter === 'function') {
2485
- const val = args[index];
2486
- match = formatter.call(self, val);
2487
-
2488
- // Now we need to remove `args[index]` since it's inlined in the `format`
2489
- args.splice(index, 1);
2490
- index--;
2491
- }
2492
- return match;
2493
- });
2494
-
2495
- // Apply env-specific formatting (colors, etc.)
2496
- createDebug.formatArgs.call(self, args);
2497
-
2498
- const logFn = self.log || createDebug.log;
2499
- logFn.apply(self, args);
2500
- }
2501
-
2502
- debug.namespace = namespace;
2503
- debug.useColors = createDebug.useColors();
2504
- debug.color = createDebug.selectColor(namespace);
2505
- debug.extend = extend;
2506
- debug.destroy = createDebug.destroy; // XXX Temporary. Will be removed in the next major release.
2507
-
2508
- Object.defineProperty(debug, 'enabled', {
2509
- enumerable: true,
2510
- configurable: false,
2511
- get: () => {
2512
- if (enableOverride !== null) {
2513
- return enableOverride;
2514
- }
2515
- if (namespacesCache !== createDebug.namespaces) {
2516
- namespacesCache = createDebug.namespaces;
2517
- enabledCache = createDebug.enabled(namespace);
2518
- }
2519
-
2520
- return enabledCache;
2521
- },
2522
- set: v => {
2523
- enableOverride = v;
2524
- }
2525
- });
2526
-
2527
- // Env-specific initialization logic for debug instances
2528
- if (typeof createDebug.init === 'function') {
2529
- createDebug.init(debug);
2530
- }
2531
-
2532
- return debug;
2533
- }
2534
-
2535
- function extend(namespace, delimiter) {
2536
- const newDebug = createDebug(this.namespace + (typeof delimiter === 'undefined' ? ':' : delimiter) + namespace);
2537
- newDebug.log = this.log;
2538
- return newDebug;
2539
- }
2540
-
2541
- /**
2542
- * Enables a debug mode by namespaces. This can include modes
2543
- * separated by a colon and wildcards.
2544
- *
2545
- * @param {String} namespaces
2546
- * @api public
2547
- */
2548
- function enable(namespaces) {
2549
- createDebug.save(namespaces);
2550
- createDebug.namespaces = namespaces;
2551
-
2552
- createDebug.names = [];
2553
- createDebug.skips = [];
2554
-
2555
- let i;
2556
- const split = (typeof namespaces === 'string' ? namespaces : '').split(/[\s,]+/);
2557
- const len = split.length;
2558
-
2559
- for (i = 0; i < len; i++) {
2560
- if (!split[i]) {
2561
- // ignore empty strings
2562
- continue;
2563
- }
2564
-
2565
- namespaces = split[i].replace(/\*/g, '.*?');
2566
-
2567
- if (namespaces[0] === '-') {
2568
- createDebug.skips.push(new RegExp('^' + namespaces.substr(1) + '$'));
2569
- } else {
2570
- createDebug.names.push(new RegExp('^' + namespaces + '$'));
2571
- }
2572
- }
2573
- }
2574
-
2575
- /**
2576
- * Disable debug output.
2577
- *
2578
- * @return {String} namespaces
2579
- * @api public
2580
- */
2581
- function disable() {
2582
- const namespaces = [
2583
- ...createDebug.names.map(toNamespace),
2584
- ...createDebug.skips.map(toNamespace).map(namespace => '-' + namespace)
2585
- ].join(',');
2586
- createDebug.enable('');
2587
- return namespaces;
2588
- }
2589
-
2590
- /**
2591
- * Returns true if the given mode name is enabled, false otherwise.
2592
- *
2593
- * @param {String} name
2594
- * @return {Boolean}
2595
- * @api public
2596
- */
2597
- function enabled(name) {
2598
- if (name[name.length - 1] === '*') {
2599
- return true;
2600
- }
2601
-
2602
- let i;
2603
- let len;
2604
-
2605
- for (i = 0, len = createDebug.skips.length; i < len; i++) {
2606
- if (createDebug.skips[i].test(name)) {
2607
- return false;
2608
- }
2609
- }
2610
-
2611
- for (i = 0, len = createDebug.names.length; i < len; i++) {
2612
- if (createDebug.names[i].test(name)) {
2613
- return true;
2614
- }
2615
- }
2616
-
2617
- return false;
2618
- }
2619
-
2620
- /**
2621
- * Convert regexp to namespace
2622
- *
2623
- * @param {RegExp} regxep
2624
- * @return {String} namespace
2625
- * @api private
2626
- */
2627
- function toNamespace(regexp) {
2628
- return regexp.toString()
2629
- .substring(2, regexp.toString().length - 2)
2630
- .replace(/\.\*\?$/, '*');
2631
- }
2632
-
2633
- /**
2634
- * Coerce `val`.
2635
- *
2636
- * @param {Mixed} val
2637
- * @return {Mixed}
2638
- * @api private
2639
- */
2640
- function coerce(val) {
2641
- if (val instanceof Error) {
2642
- return val.stack || val.message;
2643
- }
2644
- return val;
2645
- }
2646
-
2647
- /**
2648
- * XXX DO NOT USE. This is a temporary stub function.
2649
- * XXX It WILL be removed in the next major release.
2650
- */
2651
- function destroy() {
2652
- console.warn('Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.');
2653
- }
2654
-
2655
- createDebug.enable(createDebug.load());
2656
-
2657
- return createDebug;
2658
- }
2659
-
2660
- var common = setup;
2661
-
2662
- /* eslint-env browser */
2663
-
2664
- (function (module, exports) {
2665
- /**
2666
- * This is the web browser implementation of `debug()`.
2667
- */
2668
-
2669
- exports.formatArgs = formatArgs;
2670
- exports.save = save;
2671
- exports.load = load;
2672
- exports.useColors = useColors;
2673
- exports.storage = localstorage();
2674
- exports.destroy = (() => {
2675
- let warned = false;
2676
-
2677
- return () => {
2678
- if (!warned) {
2679
- warned = true;
2680
- console.warn('Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.');
2681
- }
2682
- };
2683
- })();
2684
-
2685
- /**
2686
- * Colors.
2687
- */
2688
-
2689
- exports.colors = [
2690
- '#0000CC',
2691
- '#0000FF',
2692
- '#0033CC',
2693
- '#0033FF',
2694
- '#0066CC',
2695
- '#0066FF',
2696
- '#0099CC',
2697
- '#0099FF',
2698
- '#00CC00',
2699
- '#00CC33',
2700
- '#00CC66',
2701
- '#00CC99',
2702
- '#00CCCC',
2703
- '#00CCFF',
2704
- '#3300CC',
2705
- '#3300FF',
2706
- '#3333CC',
2707
- '#3333FF',
2708
- '#3366CC',
2709
- '#3366FF',
2710
- '#3399CC',
2711
- '#3399FF',
2712
- '#33CC00',
2713
- '#33CC33',
2714
- '#33CC66',
2715
- '#33CC99',
2716
- '#33CCCC',
2717
- '#33CCFF',
2718
- '#6600CC',
2719
- '#6600FF',
2720
- '#6633CC',
2721
- '#6633FF',
2722
- '#66CC00',
2723
- '#66CC33',
2724
- '#9900CC',
2725
- '#9900FF',
2726
- '#9933CC',
2727
- '#9933FF',
2728
- '#99CC00',
2729
- '#99CC33',
2730
- '#CC0000',
2731
- '#CC0033',
2732
- '#CC0066',
2733
- '#CC0099',
2734
- '#CC00CC',
2735
- '#CC00FF',
2736
- '#CC3300',
2737
- '#CC3333',
2738
- '#CC3366',
2739
- '#CC3399',
2740
- '#CC33CC',
2741
- '#CC33FF',
2742
- '#CC6600',
2743
- '#CC6633',
2744
- '#CC9900',
2745
- '#CC9933',
2746
- '#CCCC00',
2747
- '#CCCC33',
2748
- '#FF0000',
2749
- '#FF0033',
2750
- '#FF0066',
2751
- '#FF0099',
2752
- '#FF00CC',
2753
- '#FF00FF',
2754
- '#FF3300',
2755
- '#FF3333',
2756
- '#FF3366',
2757
- '#FF3399',
2758
- '#FF33CC',
2759
- '#FF33FF',
2760
- '#FF6600',
2761
- '#FF6633',
2762
- '#FF9900',
2763
- '#FF9933',
2764
- '#FFCC00',
2765
- '#FFCC33'
2766
- ];
2767
-
2768
- /**
2769
- * Currently only WebKit-based Web Inspectors, Firefox >= v31,
2770
- * and the Firebug extension (any Firefox version) are known
2771
- * to support "%c" CSS customizations.
2772
- *
2773
- * TODO: add a `localStorage` variable to explicitly enable/disable colors
2774
- */
2775
-
2776
- // eslint-disable-next-line complexity
2777
- function useColors() {
2778
- // NB: In an Electron preload script, document will be defined but not fully
2779
- // initialized. Since we know we're in Chrome, we'll just detect this case
2780
- // explicitly
2781
- if (typeof window !== 'undefined' && window.process && (window.process.type === 'renderer' || window.process.__nwjs)) {
2782
- return true;
2783
- }
2784
-
2785
- // Internet Explorer and Edge do not support colors.
2786
- if (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)) {
2787
- return false;
2788
- }
2789
-
2790
- // Is webkit? http://stackoverflow.com/a/16459606/376773
2791
- // document is undefined in react-native: https://github.com/facebook/react-native/pull/1632
2792
- return (typeof document !== 'undefined' && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance) ||
2793
- // Is firebug? http://stackoverflow.com/a/398120/376773
2794
- (typeof window !== 'undefined' && window.console && (window.console.firebug || (window.console.exception && window.console.table))) ||
2795
- // Is firefox >= v31?
2796
- // https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages
2797
- (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31) ||
2798
- // Double check webkit in userAgent just in case we are in a worker
2799
- (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/));
2800
- }
2801
-
2802
- /**
2803
- * Colorize log arguments if enabled.
2804
- *
2805
- * @api public
2806
- */
2807
-
2808
- function formatArgs(args) {
2809
- args[0] = (this.useColors ? '%c' : '') +
2810
- this.namespace +
2811
- (this.useColors ? ' %c' : ' ') +
2812
- args[0] +
2813
- (this.useColors ? '%c ' : ' ') +
2814
- '+' + module.exports.humanize(this.diff);
2815
-
2816
- if (!this.useColors) {
2817
- return;
2818
- }
2819
-
2820
- const c = 'color: ' + this.color;
2821
- args.splice(1, 0, c, 'color: inherit');
2822
-
2823
- // The final "%c" is somewhat tricky, because there could be other
2824
- // arguments passed either before or after the %c, so we need to
2825
- // figure out the correct index to insert the CSS into
2826
- let index = 0;
2827
- let lastC = 0;
2828
- args[0].replace(/%[a-zA-Z%]/g, match => {
2829
- if (match === '%%') {
2830
- return;
2831
- }
2832
- index++;
2833
- if (match === '%c') {
2834
- // We only are interested in the *last* %c
2835
- // (the user may have provided their own)
2836
- lastC = index;
2837
- }
2838
- });
2839
-
2840
- args.splice(lastC, 0, c);
2841
- }
2842
-
2843
- /**
2844
- * Invokes `console.debug()` when available.
2845
- * No-op when `console.debug` is not a "function".
2846
- * If `console.debug` is not available, falls back
2847
- * to `console.log`.
2848
- *
2849
- * @api public
2850
- */
2851
- exports.log = console.debug || console.log || (() => {});
2852
-
2853
- /**
2854
- * Save `namespaces`.
2855
- *
2856
- * @param {String} namespaces
2857
- * @api private
2858
- */
2859
- function save(namespaces) {
2860
- try {
2861
- if (namespaces) {
2862
- exports.storage.setItem('debug', namespaces);
2863
- } else {
2864
- exports.storage.removeItem('debug');
2865
- }
2866
- } catch (error) {
2867
- // Swallow
2868
- // XXX (@Qix-) should we be logging these?
2869
- }
2870
- }
2871
-
2872
- /**
2873
- * Load `namespaces`.
2874
- *
2875
- * @return {String} returns the previously persisted debug modes
2876
- * @api private
2877
- */
2878
- function load() {
2879
- let r;
2880
- try {
2881
- r = exports.storage.getItem('debug');
2882
- } catch (error) {
2883
- // Swallow
2884
- // XXX (@Qix-) should we be logging these?
2885
- }
2886
-
2887
- // If debug isn't set in LS, and we're in Electron, try to load $DEBUG
2888
- if (!r && typeof process !== 'undefined' && 'env' in process) {
2889
- r = process.env.DEBUG;
2890
- }
2891
-
2892
- return r;
2893
- }
2894
-
2895
- /**
2896
- * Localstorage attempts to return the localstorage.
2897
- *
2898
- * This is necessary because safari throws
2899
- * when a user disables cookies/localstorage
2900
- * and you attempt to access it.
2901
- *
2902
- * @return {LocalStorage}
2903
- * @api private
2904
- */
2905
-
2906
- function localstorage() {
2907
- try {
2908
- // TVMLKit (Apple TV JS Runtime) does not have a window object, just localStorage in the global context
2909
- // The Browser also has localStorage in the global context.
2910
- return localStorage;
2911
- } catch (error) {
2912
- // Swallow
2913
- // XXX (@Qix-) should we be logging these?
2914
- }
2915
- }
2916
-
2917
- module.exports = common(exports);
2918
-
2919
- const {formatters} = module.exports;
2920
-
2921
- /**
2922
- * Map %j to `JSON.stringify()`, since no Web Inspectors do that by default.
2923
- */
2924
-
2925
- formatters.j = function (v) {
2926
- try {
2927
- return JSON.stringify(v);
2928
- } catch (error) {
2929
- return '[UnexpectedJSONParseError]: ' + error.message;
2930
- }
2931
- };
2932
- }(browser, browser.exports));
2933
-
2934
- var Debug = browser.exports;
2935
-
2936
- const log = Debug('ninetailed:experience-sdk');
2937
2239
  const enable = () => {
2938
- Debug.enable('ninetailed:experience-sdk');
2240
+ loglevel.enableAll();
2241
+ };
2242
+ const disable = () => {
2243
+ loglevel.disableAll();
2939
2244
  };
2940
- const disable = () => Debug.disable();
2245
+ const Logger = loglevel.getLogger('ninetailed:experience.js');
2246
+ const log = Logger.log;
2941
2247
 
2942
2248
  const BASE_URL = 'https://api.ninetailed.co';
2943
2249
 
@@ -3261,8 +2567,8 @@ var objectDefineProperties = {};
3261
2567
 
3262
2568
  var DESCRIPTORS$1 = descriptors;
3263
2569
  var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
3264
- var definePropertyModule$1 = objectDefineProperty;
3265
- var anObject$4 = anObject$d;
2570
+ var definePropertyModule$2 = objectDefineProperty;
2571
+ var anObject$5 = anObject$e;
3266
2572
  var toIndexedObject$1 = toIndexedObject$5;
3267
2573
  var objectKeys = objectKeys$2;
3268
2574
 
@@ -3270,19 +2576,19 @@ var objectKeys = objectKeys$2;
3270
2576
  // https://tc39.es/ecma262/#sec-object.defineproperties
3271
2577
  // eslint-disable-next-line es/no-object-defineproperties -- safe
3272
2578
  objectDefineProperties.f = DESCRIPTORS$1 && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
3273
- anObject$4(O);
2579
+ anObject$5(O);
3274
2580
  var props = toIndexedObject$1(Properties);
3275
2581
  var keys = objectKeys(Properties);
3276
2582
  var length = keys.length;
3277
2583
  var index = 0;
3278
2584
  var key;
3279
- while (length > index) definePropertyModule$1.f(O, key = keys[index++], props[key]);
2585
+ while (length > index) definePropertyModule$2.f(O, key = keys[index++], props[key]);
3280
2586
  return O;
3281
2587
  };
3282
2588
 
3283
2589
  /* global ActiveXObject -- old IE, WSH */
3284
2590
 
3285
- var anObject$3 = anObject$d;
2591
+ var anObject$4 = anObject$e;
3286
2592
  var definePropertiesModule = objectDefineProperties;
3287
2593
  var enumBugKeys = enumBugKeys$3;
3288
2594
  var hiddenKeys = hiddenKeys$4;
@@ -3355,7 +2661,7 @@ hiddenKeys[IE_PROTO$1] = true;
3355
2661
  var objectCreate = Object.create || function create(O, Properties) {
3356
2662
  var result;
3357
2663
  if (O !== null) {
3358
- EmptyConstructor[PROTOTYPE] = anObject$3(O);
2664
+ EmptyConstructor[PROTOTYPE] = anObject$4(O);
3359
2665
  result = new EmptyConstructor();
3360
2666
  EmptyConstructor[PROTOTYPE] = null;
3361
2667
  // add "__proto__" for Object.getPrototypeOf polyfill
@@ -3366,7 +2672,7 @@ var objectCreate = Object.create || function create(O, Properties) {
3366
2672
 
3367
2673
  var wellKnownSymbol$7 = wellKnownSymbol$i;
3368
2674
  var create$2 = objectCreate;
3369
- var definePropertyModule = objectDefineProperty;
2675
+ var definePropertyModule$1 = objectDefineProperty;
3370
2676
 
3371
2677
  var UNSCOPABLES = wellKnownSymbol$7('unscopables');
3372
2678
  var ArrayPrototype = Array.prototype;
@@ -3374,7 +2680,7 @@ var ArrayPrototype = Array.prototype;
3374
2680
  // Array.prototype[@@unscopables]
3375
2681
  // https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
3376
2682
  if (ArrayPrototype[UNSCOPABLES] == undefined) {
3377
- definePropertyModule.f(ArrayPrototype, UNSCOPABLES, {
2683
+ definePropertyModule$1.f(ArrayPrototype, UNSCOPABLES, {
3378
2684
  configurable: true,
3379
2685
  value: create$2(null)
3380
2686
  });
@@ -3385,30 +2691,30 @@ var addToUnscopables$1 = function (key) {
3385
2691
  ArrayPrototype[UNSCOPABLES][key] = true;
3386
2692
  };
3387
2693
 
3388
- var fails$6 = fails$h;
2694
+ var fails$9 = fails$k;
3389
2695
 
3390
- var correctPrototypeGetter = !fails$6(function () {
2696
+ var correctPrototypeGetter = !fails$9(function () {
3391
2697
  function F() { /* empty */ }
3392
2698
  F.prototype.constructor = null;
3393
2699
  // eslint-disable-next-line es/no-object-getprototypeof -- required for testing
3394
2700
  return Object.getPrototypeOf(new F()) !== F.prototype;
3395
2701
  });
3396
2702
 
3397
- var global$8 = global$H;
2703
+ var global$b = global$K;
3398
2704
  var hasOwn = hasOwnProperty_1;
3399
2705
  var isCallable$4 = isCallable$j;
3400
- var toObject$1 = toObject$4;
2706
+ var toObject$2 = toObject$5;
3401
2707
  var sharedKey = sharedKey$3;
3402
2708
  var CORRECT_PROTOTYPE_GETTER = correctPrototypeGetter;
3403
2709
 
3404
2710
  var IE_PROTO = sharedKey('IE_PROTO');
3405
- var Object$1 = global$8.Object;
2711
+ var Object$1 = global$b.Object;
3406
2712
  var ObjectPrototype = Object$1.prototype;
3407
2713
 
3408
2714
  // `Object.getPrototypeOf` method
3409
2715
  // https://tc39.es/ecma262/#sec-object.getprototypeof
3410
2716
  var objectGetPrototypeOf = CORRECT_PROTOTYPE_GETTER ? Object$1.getPrototypeOf : function (O) {
3411
- var object = toObject$1(O);
2717
+ var object = toObject$2(O);
3412
2718
  if (hasOwn(object, IE_PROTO)) return object[IE_PROTO];
3413
2719
  var constructor = object.constructor;
3414
2720
  if (isCallable$4(constructor) && object instanceof constructor) {
@@ -3416,13 +2722,13 @@ var objectGetPrototypeOf = CORRECT_PROTOTYPE_GETTER ? Object$1.getPrototypeOf :
3416
2722
  } return object instanceof Object$1 ? ObjectPrototype : null;
3417
2723
  };
3418
2724
 
3419
- var fails$5 = fails$h;
2725
+ var fails$8 = fails$k;
3420
2726
  var isCallable$3 = isCallable$j;
3421
2727
  var getPrototypeOf$1 = objectGetPrototypeOf;
3422
2728
  var redefine$2 = redefine$6.exports;
3423
2729
  var wellKnownSymbol$6 = wellKnownSymbol$i;
3424
2730
 
3425
- var ITERATOR$2 = wellKnownSymbol$6('iterator');
2731
+ var ITERATOR$3 = wellKnownSymbol$6('iterator');
3426
2732
  var BUGGY_SAFARI_ITERATORS$1 = false;
3427
2733
 
3428
2734
  // `%IteratorPrototype%` object
@@ -3440,18 +2746,18 @@ if ([].keys) {
3440
2746
  }
3441
2747
  }
3442
2748
 
3443
- var NEW_ITERATOR_PROTOTYPE = IteratorPrototype$2 == undefined || fails$5(function () {
2749
+ var NEW_ITERATOR_PROTOTYPE = IteratorPrototype$2 == undefined || fails$8(function () {
3444
2750
  var test = {};
3445
2751
  // FF44- legacy iterators case
3446
- return IteratorPrototype$2[ITERATOR$2].call(test) !== test;
2752
+ return IteratorPrototype$2[ITERATOR$3].call(test) !== test;
3447
2753
  });
3448
2754
 
3449
2755
  if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype$2 = {};
3450
2756
 
3451
2757
  // `%IteratorPrototype%[@@iterator]()` method
3452
2758
  // https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator
3453
- if (!isCallable$3(IteratorPrototype$2[ITERATOR$2])) {
3454
- redefine$2(IteratorPrototype$2, ITERATOR$2, function () {
2759
+ if (!isCallable$3(IteratorPrototype$2[ITERATOR$3])) {
2760
+ redefine$2(IteratorPrototype$2, ITERATOR$3, function () {
3455
2761
  return this;
3456
2762
  });
3457
2763
  }
@@ -3463,7 +2769,7 @@ var iteratorsCore = {
3463
2769
 
3464
2770
  var IteratorPrototype$1 = iteratorsCore.IteratorPrototype;
3465
2771
  var create$1 = objectCreate;
3466
- var createPropertyDescriptor = createPropertyDescriptor$3;
2772
+ var createPropertyDescriptor$1 = createPropertyDescriptor$4;
3467
2773
  var setToStringTag$1 = setToStringTag$3;
3468
2774
  var Iterators$2 = iterators;
3469
2775
 
@@ -3471,14 +2777,14 @@ var returnThis$1 = function () { return this; };
3471
2777
 
3472
2778
  var createIteratorConstructor$1 = function (IteratorConstructor, NAME, next, ENUMERABLE_NEXT) {
3473
2779
  var TO_STRING_TAG = NAME + ' Iterator';
3474
- IteratorConstructor.prototype = create$1(IteratorPrototype$1, { next: createPropertyDescriptor(+!ENUMERABLE_NEXT, next) });
2780
+ IteratorConstructor.prototype = create$1(IteratorPrototype$1, { next: createPropertyDescriptor$1(+!ENUMERABLE_NEXT, next) });
3475
2781
  setToStringTag$1(IteratorConstructor, TO_STRING_TAG, false);
3476
2782
  Iterators$2[TO_STRING_TAG] = returnThis$1;
3477
2783
  return IteratorConstructor;
3478
2784
  };
3479
2785
 
3480
- var $$2 = _export;
3481
- var call$3 = functionCall;
2786
+ var $$4 = _export;
2787
+ var call$4 = functionCall;
3482
2788
  var FunctionName = functionName;
3483
2789
  var isCallable$2 = isCallable$j;
3484
2790
  var createIteratorConstructor = createIteratorConstructor$1;
@@ -3495,7 +2801,7 @@ var PROPER_FUNCTION_NAME = FunctionName.PROPER;
3495
2801
  var CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE;
3496
2802
  var IteratorPrototype = IteratorsCore.IteratorPrototype;
3497
2803
  var BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;
3498
- var ITERATOR$1 = wellKnownSymbol$5('iterator');
2804
+ var ITERATOR$2 = wellKnownSymbol$5('iterator');
3499
2805
  var KEYS = 'keys';
3500
2806
  var VALUES = 'values';
3501
2807
  var ENTRIES = 'entries';
@@ -3518,7 +2824,7 @@ var defineIterator$1 = function (Iterable, NAME, IteratorConstructor, next, DEFA
3518
2824
  var TO_STRING_TAG = NAME + ' Iterator';
3519
2825
  var INCORRECT_VALUES_NAME = false;
3520
2826
  var IterablePrototype = Iterable.prototype;
3521
- var nativeIterator = IterablePrototype[ITERATOR$1]
2827
+ var nativeIterator = IterablePrototype[ITERATOR$2]
3522
2828
  || IterablePrototype['@@iterator']
3523
2829
  || DEFAULT && IterablePrototype[DEFAULT];
3524
2830
  var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);
@@ -3532,8 +2838,8 @@ var defineIterator$1 = function (Iterable, NAME, IteratorConstructor, next, DEFA
3532
2838
  if (getPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype) {
3533
2839
  if (setPrototypeOf) {
3534
2840
  setPrototypeOf(CurrentIteratorPrototype, IteratorPrototype);
3535
- } else if (!isCallable$2(CurrentIteratorPrototype[ITERATOR$1])) {
3536
- redefine$1(CurrentIteratorPrototype, ITERATOR$1, returnThis);
2841
+ } else if (!isCallable$2(CurrentIteratorPrototype[ITERATOR$2])) {
2842
+ redefine$1(CurrentIteratorPrototype, ITERATOR$2, returnThis);
3537
2843
  }
3538
2844
  }
3539
2845
  // Set @@toStringTag to native iterators
@@ -3547,7 +2853,7 @@ var defineIterator$1 = function (Iterable, NAME, IteratorConstructor, next, DEFA
3547
2853
  createNonEnumerableProperty$2(IterablePrototype, 'name', VALUES);
3548
2854
  } else {
3549
2855
  INCORRECT_VALUES_NAME = true;
3550
- defaultIterator = function values() { return call$3(nativeIterator, this); };
2856
+ defaultIterator = function values() { return call$4(nativeIterator, this); };
3551
2857
  }
3552
2858
  }
3553
2859
 
@@ -3562,12 +2868,12 @@ var defineIterator$1 = function (Iterable, NAME, IteratorConstructor, next, DEFA
3562
2868
  if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {
3563
2869
  redefine$1(IterablePrototype, KEY, methods[KEY]);
3564
2870
  }
3565
- } else $$2({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);
2871
+ } else $$4({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);
3566
2872
  }
3567
2873
 
3568
2874
  // define iterator
3569
- if (IterablePrototype[ITERATOR$1] !== defaultIterator) {
3570
- redefine$1(IterablePrototype, ITERATOR$1, defaultIterator, { name: DEFAULT });
2875
+ if (IterablePrototype[ITERATOR$2] !== defaultIterator) {
2876
+ redefine$1(IterablePrototype, ITERATOR$2, defaultIterator, { name: DEFAULT });
3571
2877
  }
3572
2878
  Iterators$1[NAME] = defaultIterator;
3573
2879
 
@@ -3678,24 +2984,24 @@ var DOMTokenListPrototype$1 = classList && classList.constructor && classList.co
3678
2984
 
3679
2985
  var domTokenListPrototype = DOMTokenListPrototype$1 === Object.prototype ? undefined : DOMTokenListPrototype$1;
3680
2986
 
3681
- var global$7 = global$H;
2987
+ var global$a = global$K;
3682
2988
  var DOMIterables = domIterables;
3683
2989
  var DOMTokenListPrototype = domTokenListPrototype;
3684
2990
  var ArrayIteratorMethods = es_array_iterator;
3685
2991
  var createNonEnumerableProperty$1 = createNonEnumerableProperty$6;
3686
2992
  var wellKnownSymbol$4 = wellKnownSymbol$i;
3687
2993
 
3688
- var ITERATOR = wellKnownSymbol$4('iterator');
2994
+ var ITERATOR$1 = wellKnownSymbol$4('iterator');
3689
2995
  var TO_STRING_TAG = wellKnownSymbol$4('toStringTag');
3690
2996
  var ArrayValues = ArrayIteratorMethods.values;
3691
2997
 
3692
2998
  var handlePrototype = function (CollectionPrototype, COLLECTION_NAME) {
3693
2999
  if (CollectionPrototype) {
3694
3000
  // some Chrome versions have non-configurable methods on DOMTokenList
3695
- if (CollectionPrototype[ITERATOR] !== ArrayValues) try {
3696
- createNonEnumerableProperty$1(CollectionPrototype, ITERATOR, ArrayValues);
3001
+ if (CollectionPrototype[ITERATOR$1] !== ArrayValues) try {
3002
+ createNonEnumerableProperty$1(CollectionPrototype, ITERATOR$1, ArrayValues);
3697
3003
  } catch (error) {
3698
- CollectionPrototype[ITERATOR] = ArrayValues;
3004
+ CollectionPrototype[ITERATOR$1] = ArrayValues;
3699
3005
  }
3700
3006
  if (!CollectionPrototype[TO_STRING_TAG]) {
3701
3007
  createNonEnumerableProperty$1(CollectionPrototype, TO_STRING_TAG, COLLECTION_NAME);
@@ -3712,7 +3018,7 @@ var handlePrototype = function (CollectionPrototype, COLLECTION_NAME) {
3712
3018
  };
3713
3019
 
3714
3020
  for (var COLLECTION_NAME in DOMIterables) {
3715
- handlePrototype(global$7[COLLECTION_NAME] && global$7[COLLECTION_NAME].prototype, COLLECTION_NAME);
3021
+ handlePrototype(global$a[COLLECTION_NAME] && global$a[COLLECTION_NAME].prototype, COLLECTION_NAME);
3716
3022
  }
3717
3023
 
3718
3024
  handlePrototype(DOMTokenListPrototype, 'DOMTokenList');
@@ -3745,6 +3051,15 @@ class Ninetailed {
3745
3051
  });
3746
3052
  };
3747
3053
 
3054
+ this.trackExperience = payload => {
3055
+ return this.track('experience', payload, {
3056
+ plugins: {
3057
+ all: true,
3058
+ ninetailed: false
3059
+ }
3060
+ });
3061
+ };
3062
+
3748
3063
  this.identify = (uid, traits, options) => {
3749
3064
  return this.instance.identify(uid, traits, this.buildOptions(options));
3750
3065
  };
@@ -3925,6 +3240,8 @@ const selectVariant$1 = (baseline, variants, {
3925
3240
  };
3926
3241
  };
3927
3242
 
3243
+ const EXPERIENCE_TRAIT_PREFIX = 'nt_experiment_';
3244
+
3928
3245
  const selectBaselineWithVariants = (experience, baseline) => {
3929
3246
  return experience.components.find(baselineWithVariants => baselineWithVariants.baseline.id === baseline.id);
3930
3247
  };
@@ -3944,12 +3261,12 @@ const selectHasVariants = (experience, baseline) => {
3944
3261
  return variants.length > 0;
3945
3262
  };
3946
3263
 
3947
- var global$6 = global$H;
3264
+ var global$9 = global$K;
3948
3265
  var classof$2 = classof$6;
3949
3266
 
3950
- var String$1 = global$6.String;
3267
+ var String$1 = global$9.String;
3951
3268
 
3952
- var toString$4 = function (argument) {
3269
+ var toString$7 = function (argument) {
3953
3270
  if (classof$2(argument) === 'Symbol') throw TypeError('Cannot convert a Symbol value to a string');
3954
3271
  return String$1(argument);
3955
3272
  };
@@ -3967,14 +3284,14 @@ var isRegexp = function (it) {
3967
3284
  return isObject(it) && ((isRegExp = it[MATCH$1]) !== undefined ? !!isRegExp : classof$1(it) == 'RegExp');
3968
3285
  };
3969
3286
 
3970
- var global$5 = global$H;
3971
- var isRegExp = isRegexp;
3287
+ var global$8 = global$K;
3288
+ var isRegExp$1 = isRegexp;
3972
3289
 
3973
- var TypeError$2 = global$5.TypeError;
3290
+ var TypeError$3 = global$8.TypeError;
3974
3291
 
3975
3292
  var notARegexp = function (it) {
3976
- if (isRegExp(it)) {
3977
- throw TypeError$2("The method doesn't accept regular expressions");
3293
+ if (isRegExp$1(it)) {
3294
+ throw TypeError$3("The method doesn't accept regular expressions");
3978
3295
  } return it;
3979
3296
  };
3980
3297
 
@@ -3994,19 +3311,19 @@ var correctIsRegexpLogic = function (METHOD_NAME) {
3994
3311
  } return false;
3995
3312
  };
3996
3313
 
3997
- var $$1 = _export;
3998
- var uncurryThis$5 = functionUncurryThis;
3314
+ var $$3 = _export;
3315
+ var uncurryThis$8 = functionUncurryThis;
3999
3316
  var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
4000
- var toLength$1 = toLength$3;
4001
- var toString$3 = toString$4;
3317
+ var toLength$2 = toLength$4;
3318
+ var toString$6 = toString$7;
4002
3319
  var notARegExp = notARegexp;
4003
- var requireObjectCoercible$2 = requireObjectCoercible$5;
3320
+ var requireObjectCoercible$4 = requireObjectCoercible$7;
4004
3321
  var correctIsRegExpLogic = correctIsRegexpLogic;
4005
3322
 
4006
3323
  // eslint-disable-next-line es/no-string-prototype-startswith -- safe
4007
- var un$StartsWith = uncurryThis$5(''.startsWith);
4008
- var stringSlice$4 = uncurryThis$5(''.slice);
4009
- var min$1 = Math.min;
3324
+ var un$StartsWith = uncurryThis$8(''.startsWith);
3325
+ var stringSlice$5 = uncurryThis$8(''.slice);
3326
+ var min$2 = Math.min;
4010
3327
 
4011
3328
  var CORRECT_IS_REGEXP_LOGIC = correctIsRegExpLogic('startsWith');
4012
3329
  // https://github.com/zloirock/core-js/pull/702
@@ -4017,24 +3334,24 @@ var MDN_POLYFILL_BUG = !CORRECT_IS_REGEXP_LOGIC && !!function () {
4017
3334
 
4018
3335
  // `String.prototype.startsWith` method
4019
3336
  // https://tc39.es/ecma262/#sec-string.prototype.startswith
4020
- $$1({ target: 'String', proto: true, forced: !MDN_POLYFILL_BUG && !CORRECT_IS_REGEXP_LOGIC }, {
3337
+ $$3({ target: 'String', proto: true, forced: !MDN_POLYFILL_BUG && !CORRECT_IS_REGEXP_LOGIC }, {
4021
3338
  startsWith: function startsWith(searchString /* , position = 0 */) {
4022
- var that = toString$3(requireObjectCoercible$2(this));
3339
+ var that = toString$6(requireObjectCoercible$4(this));
4023
3340
  notARegExp(searchString);
4024
- var index = toLength$1(min$1(arguments.length > 1 ? arguments[1] : undefined, that.length));
4025
- var search = toString$3(searchString);
3341
+ var index = toLength$2(min$2(arguments.length > 1 ? arguments[1] : undefined, that.length));
3342
+ var search = toString$6(searchString);
4026
3343
  return un$StartsWith
4027
3344
  ? un$StartsWith(that, search, index)
4028
- : stringSlice$4(that, index, index + search.length) === search;
3345
+ : stringSlice$5(that, index, index + search.length) === search;
4029
3346
  }
4030
3347
  });
4031
3348
 
4032
- var anObject$2 = anObject$d;
3349
+ var anObject$3 = anObject$e;
4033
3350
 
4034
3351
  // `RegExp.prototype.flags` getter implementation
4035
3352
  // https://tc39.es/ecma262/#sec-get-regexp.prototype.flags
4036
3353
  var regexpFlags$1 = function () {
4037
- var that = anObject$2(this);
3354
+ var that = anObject$3(this);
4038
3355
  var result = '';
4039
3356
  if (that.global) result += 'g';
4040
3357
  if (that.ignoreCase) result += 'i';
@@ -4045,13 +3362,13 @@ var regexpFlags$1 = function () {
4045
3362
  return result;
4046
3363
  };
4047
3364
 
4048
- var fails$4 = fails$h;
4049
- var global$4 = global$H;
3365
+ var fails$7 = fails$k;
3366
+ var global$7 = global$K;
4050
3367
 
4051
3368
  // babel-minify and Closure Compiler transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError
4052
- var $RegExp$2 = global$4.RegExp;
3369
+ var $RegExp$2 = global$7.RegExp;
4053
3370
 
4054
- var UNSUPPORTED_Y$1 = fails$4(function () {
3371
+ var UNSUPPORTED_Y$2 = fails$7(function () {
4055
3372
  var re = $RegExp$2('a', 'y');
4056
3373
  re.lastIndex = 2;
4057
3374
  return re.exec('abcd') != null;
@@ -4059,11 +3376,11 @@ var UNSUPPORTED_Y$1 = fails$4(function () {
4059
3376
 
4060
3377
  // UC Browser bug
4061
3378
  // https://github.com/zloirock/core-js/issues/1008
4062
- var MISSED_STICKY = UNSUPPORTED_Y$1 || fails$4(function () {
3379
+ var MISSED_STICKY = UNSUPPORTED_Y$2 || fails$7(function () {
4063
3380
  return !$RegExp$2('a', 'y').sticky;
4064
3381
  });
4065
3382
 
4066
- var BROKEN_CARET = UNSUPPORTED_Y$1 || fails$4(function () {
3383
+ var BROKEN_CARET = UNSUPPORTED_Y$2 || fails$7(function () {
4067
3384
  // https://bugzilla.mozilla.org/show_bug.cgi?id=773687
4068
3385
  var re = $RegExp$2('^r', 'gy');
4069
3386
  re.lastIndex = 2;
@@ -4073,27 +3390,27 @@ var BROKEN_CARET = UNSUPPORTED_Y$1 || fails$4(function () {
4073
3390
  var regexpStickyHelpers = {
4074
3391
  BROKEN_CARET: BROKEN_CARET,
4075
3392
  MISSED_STICKY: MISSED_STICKY,
4076
- UNSUPPORTED_Y: UNSUPPORTED_Y$1
3393
+ UNSUPPORTED_Y: UNSUPPORTED_Y$2
4077
3394
  };
4078
3395
 
4079
- var fails$3 = fails$h;
4080
- var global$3 = global$H;
3396
+ var fails$6 = fails$k;
3397
+ var global$6 = global$K;
4081
3398
 
4082
3399
  // babel-minify and Closure Compiler transpiles RegExp('.', 's') -> /./s and it causes SyntaxError
4083
- var $RegExp$1 = global$3.RegExp;
3400
+ var $RegExp$1 = global$6.RegExp;
4084
3401
 
4085
- var regexpUnsupportedDotAll = fails$3(function () {
3402
+ var regexpUnsupportedDotAll = fails$6(function () {
4086
3403
  var re = $RegExp$1('.', 's');
4087
3404
  return !(re.dotAll && re.exec('\n') && re.flags === 's');
4088
3405
  });
4089
3406
 
4090
- var fails$2 = fails$h;
4091
- var global$2 = global$H;
3407
+ var fails$5 = fails$k;
3408
+ var global$5 = global$K;
4092
3409
 
4093
3410
  // babel-minify and Closure Compiler transpiles RegExp('(?<a>b)', 'g') -> /(?<a>b)/g and it causes SyntaxError
4094
- var $RegExp = global$2.RegExp;
3411
+ var $RegExp = global$5.RegExp;
4095
3412
 
4096
- var regexpUnsupportedNcg = fails$2(function () {
3413
+ var regexpUnsupportedNcg = fails$5(function () {
4097
3414
  var re = $RegExp('(?<a>b)', 'g');
4098
3415
  return re.exec('b').groups.a !== 'b' ||
4099
3416
  'b'.replace(re, '$<a>c') !== 'bc';
@@ -4101,11 +3418,11 @@ var regexpUnsupportedNcg = fails$2(function () {
4101
3418
 
4102
3419
  /* eslint-disable regexp/no-empty-capturing-group, regexp/no-empty-group, regexp/no-lazy-ends -- testing */
4103
3420
  /* eslint-disable regexp/no-useless-quantifier -- testing */
4104
- var call$2 = functionCall;
4105
- var uncurryThis$4 = functionUncurryThis;
4106
- var toString$2 = toString$4;
3421
+ var call$3 = functionCall;
3422
+ var uncurryThis$7 = functionUncurryThis;
3423
+ var toString$5 = toString$7;
4107
3424
  var regexpFlags = regexpFlags$1;
4108
- var stickyHelpers = regexpStickyHelpers;
3425
+ var stickyHelpers$1 = regexpStickyHelpers;
4109
3426
  var shared = shared$4.exports;
4110
3427
  var create = objectCreate;
4111
3428
  var getInternalState = internalState.get;
@@ -4115,55 +3432,55 @@ var UNSUPPORTED_NCG = regexpUnsupportedNcg;
4115
3432
  var nativeReplace = shared('native-string-replace', String.prototype.replace);
4116
3433
  var nativeExec = RegExp.prototype.exec;
4117
3434
  var patchedExec = nativeExec;
4118
- var charAt$3 = uncurryThis$4(''.charAt);
4119
- var indexOf = uncurryThis$4(''.indexOf);
4120
- var replace$1 = uncurryThis$4(''.replace);
4121
- var stringSlice$3 = uncurryThis$4(''.slice);
3435
+ var charAt$3 = uncurryThis$7(''.charAt);
3436
+ var indexOf = uncurryThis$7(''.indexOf);
3437
+ var replace$2 = uncurryThis$7(''.replace);
3438
+ var stringSlice$4 = uncurryThis$7(''.slice);
4122
3439
 
4123
3440
  var UPDATES_LAST_INDEX_WRONG = (function () {
4124
3441
  var re1 = /a/;
4125
3442
  var re2 = /b*/g;
4126
- call$2(nativeExec, re1, 'a');
4127
- call$2(nativeExec, re2, 'a');
3443
+ call$3(nativeExec, re1, 'a');
3444
+ call$3(nativeExec, re2, 'a');
4128
3445
  return re1.lastIndex !== 0 || re2.lastIndex !== 0;
4129
3446
  })();
4130
3447
 
4131
- var UNSUPPORTED_Y = stickyHelpers.BROKEN_CARET;
3448
+ var UNSUPPORTED_Y$1 = stickyHelpers$1.BROKEN_CARET;
4132
3449
 
4133
3450
  // nonparticipating capturing group, copied from es5-shim's String#split patch.
4134
3451
  var NPCG_INCLUDED = /()??/.exec('')[1] !== undefined;
4135
3452
 
4136
- var PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y || UNSUPPORTED_DOT_ALL || UNSUPPORTED_NCG;
3453
+ var PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y$1 || UNSUPPORTED_DOT_ALL || UNSUPPORTED_NCG;
4137
3454
 
4138
3455
  if (PATCH) {
4139
3456
  patchedExec = function exec(string) {
4140
3457
  var re = this;
4141
3458
  var state = getInternalState(re);
4142
- var str = toString$2(string);
3459
+ var str = toString$5(string);
4143
3460
  var raw = state.raw;
4144
3461
  var result, reCopy, lastIndex, match, i, object, group;
4145
3462
 
4146
3463
  if (raw) {
4147
3464
  raw.lastIndex = re.lastIndex;
4148
- result = call$2(patchedExec, raw, str);
3465
+ result = call$3(patchedExec, raw, str);
4149
3466
  re.lastIndex = raw.lastIndex;
4150
3467
  return result;
4151
3468
  }
4152
3469
 
4153
3470
  var groups = state.groups;
4154
- var sticky = UNSUPPORTED_Y && re.sticky;
4155
- var flags = call$2(regexpFlags, re);
3471
+ var sticky = UNSUPPORTED_Y$1 && re.sticky;
3472
+ var flags = call$3(regexpFlags, re);
4156
3473
  var source = re.source;
4157
3474
  var charsAdded = 0;
4158
3475
  var strCopy = str;
4159
3476
 
4160
3477
  if (sticky) {
4161
- flags = replace$1(flags, 'y', '');
3478
+ flags = replace$2(flags, 'y', '');
4162
3479
  if (indexOf(flags, 'g') === -1) {
4163
3480
  flags += 'g';
4164
3481
  }
4165
3482
 
4166
- strCopy = stringSlice$3(str, re.lastIndex);
3483
+ strCopy = stringSlice$4(str, re.lastIndex);
4167
3484
  // Support anchored sticky behavior.
4168
3485
  if (re.lastIndex > 0 && (!re.multiline || re.multiline && charAt$3(str, re.lastIndex - 1) !== '\n')) {
4169
3486
  source = '(?: ' + source + ')';
@@ -4180,12 +3497,12 @@ if (PATCH) {
4180
3497
  }
4181
3498
  if (UPDATES_LAST_INDEX_WRONG) lastIndex = re.lastIndex;
4182
3499
 
4183
- match = call$2(nativeExec, sticky ? reCopy : re, strCopy);
3500
+ match = call$3(nativeExec, sticky ? reCopy : re, strCopy);
4184
3501
 
4185
3502
  if (sticky) {
4186
3503
  if (match) {
4187
- match.input = stringSlice$3(match.input, charsAdded);
4188
- match[0] = stringSlice$3(match[0], charsAdded);
3504
+ match.input = stringSlice$4(match.input, charsAdded);
3505
+ match[0] = stringSlice$4(match[0], charsAdded);
4189
3506
  match.index = re.lastIndex;
4190
3507
  re.lastIndex += match[0].length;
4191
3508
  } else re.lastIndex = 0;
@@ -4195,7 +3512,7 @@ if (PATCH) {
4195
3512
  if (NPCG_INCLUDED && match && match.length > 1) {
4196
3513
  // Fix browsers whose `exec` methods don't consistently return `undefined`
4197
3514
  // for NPCG, like IE8. NOTE: This doesn' work for /(.?)?/
4198
- call$2(nativeReplace, match[0], reCopy, function () {
3515
+ call$3(nativeReplace, match[0], reCopy, function () {
4199
3516
  for (i = 1; i < arguments.length - 2; i++) {
4200
3517
  if (arguments[i] === undefined) match[i] = undefined;
4201
3518
  }
@@ -4214,23 +3531,23 @@ if (PATCH) {
4214
3531
  };
4215
3532
  }
4216
3533
 
4217
- var regexpExec$2 = patchedExec;
3534
+ var regexpExec$3 = patchedExec;
4218
3535
 
4219
- var $ = _export;
4220
- var exec = regexpExec$2;
3536
+ var $$2 = _export;
3537
+ var exec$2 = regexpExec$3;
4221
3538
 
4222
3539
  // `RegExp.prototype.exec` method
4223
3540
  // https://tc39.es/ecma262/#sec-regexp.prototype.exec
4224
- $({ target: 'RegExp', proto: true, forced: /./.exec !== exec }, {
4225
- exec: exec
3541
+ $$2({ target: 'RegExp', proto: true, forced: /./.exec !== exec$2 }, {
3542
+ exec: exec$2
4226
3543
  });
4227
3544
 
4228
3545
  // TODO: Remove from `core-js@4` since it's moved to entry points
4229
3546
 
4230
- var uncurryThis$3 = functionUncurryThis;
3547
+ var uncurryThis$6 = functionUncurryThis;
4231
3548
  var redefine = redefine$6.exports;
4232
- var regexpExec$1 = regexpExec$2;
4233
- var fails$1 = fails$h;
3549
+ var regexpExec$2 = regexpExec$3;
3550
+ var fails$4 = fails$k;
4234
3551
  var wellKnownSymbol$1 = wellKnownSymbol$i;
4235
3552
  var createNonEnumerableProperty = createNonEnumerableProperty$6;
4236
3553
 
@@ -4240,14 +3557,14 @@ var RegExpPrototype = RegExp.prototype;
4240
3557
  var fixRegexpWellKnownSymbolLogic = function (KEY, exec, FORCED, SHAM) {
4241
3558
  var SYMBOL = wellKnownSymbol$1(KEY);
4242
3559
 
4243
- var DELEGATES_TO_SYMBOL = !fails$1(function () {
3560
+ var DELEGATES_TO_SYMBOL = !fails$4(function () {
4244
3561
  // String methods call symbol-named RegEp methods
4245
3562
  var O = {};
4246
3563
  O[SYMBOL] = function () { return 7; };
4247
3564
  return ''[KEY](O) != 7;
4248
3565
  });
4249
3566
 
4250
- var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails$1(function () {
3567
+ var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails$4(function () {
4251
3568
  // Symbol-named RegExp methods call .exec
4252
3569
  var execCalled = false;
4253
3570
  var re = /a/;
@@ -4276,11 +3593,11 @@ var fixRegexpWellKnownSymbolLogic = function (KEY, exec, FORCED, SHAM) {
4276
3593
  !DELEGATES_TO_EXEC ||
4277
3594
  FORCED
4278
3595
  ) {
4279
- var uncurriedNativeRegExpMethod = uncurryThis$3(/./[SYMBOL]);
3596
+ var uncurriedNativeRegExpMethod = uncurryThis$6(/./[SYMBOL]);
4280
3597
  var methods = exec(SYMBOL, ''[KEY], function (nativeMethod, regexp, str, arg2, forceStringMethod) {
4281
- var uncurriedNativeMethod = uncurryThis$3(nativeMethod);
3598
+ var uncurriedNativeMethod = uncurryThis$6(nativeMethod);
4282
3599
  var $exec = regexp.exec;
4283
- if ($exec === regexpExec$1 || $exec === RegExpPrototype.exec) {
3600
+ if ($exec === regexpExec$2 || $exec === RegExpPrototype.exec) {
4284
3601
  if (DELEGATES_TO_SYMBOL && !forceStringMethod) {
4285
3602
  // The native String method already delegates to @@method (this
4286
3603
  // polyfilled function), leasing to infinite recursion.
@@ -4299,18 +3616,18 @@ var fixRegexpWellKnownSymbolLogic = function (KEY, exec, FORCED, SHAM) {
4299
3616
  if (SHAM) createNonEnumerableProperty(RegExpPrototype[SYMBOL], 'sham', true);
4300
3617
  };
4301
3618
 
4302
- var uncurryThis$2 = functionUncurryThis;
3619
+ var uncurryThis$5 = functionUncurryThis;
4303
3620
  var toIntegerOrInfinity$1 = toIntegerOrInfinity$4;
4304
- var toString$1 = toString$4;
4305
- var requireObjectCoercible$1 = requireObjectCoercible$5;
3621
+ var toString$4 = toString$7;
3622
+ var requireObjectCoercible$3 = requireObjectCoercible$7;
4306
3623
 
4307
- var charAt$2 = uncurryThis$2(''.charAt);
4308
- var charCodeAt = uncurryThis$2(''.charCodeAt);
4309
- var stringSlice$2 = uncurryThis$2(''.slice);
3624
+ var charAt$2 = uncurryThis$5(''.charAt);
3625
+ var charCodeAt = uncurryThis$5(''.charCodeAt);
3626
+ var stringSlice$3 = uncurryThis$5(''.slice);
4310
3627
 
4311
- var createMethod = function (CONVERT_TO_STRING) {
3628
+ var createMethod$2 = function (CONVERT_TO_STRING) {
4312
3629
  return function ($this, pos) {
4313
- var S = toString$1(requireObjectCoercible$1($this));
3630
+ var S = toString$4(requireObjectCoercible$3($this));
4314
3631
  var position = toIntegerOrInfinity$1(pos);
4315
3632
  var size = S.length;
4316
3633
  var first, second;
@@ -4322,7 +3639,7 @@ var createMethod = function (CONVERT_TO_STRING) {
4322
3639
  ? charAt$2(S, position)
4323
3640
  : first
4324
3641
  : CONVERT_TO_STRING
4325
- ? stringSlice$2(S, position, position + 2)
3642
+ ? stringSlice$3(S, position, position + 2)
4326
3643
  : (first - 0xD800 << 10) + (second - 0xDC00) + 0x10000;
4327
3644
  };
4328
3645
  };
@@ -4330,27 +3647,27 @@ var createMethod = function (CONVERT_TO_STRING) {
4330
3647
  var stringMultibyte = {
4331
3648
  // `String.prototype.codePointAt` method
4332
3649
  // https://tc39.es/ecma262/#sec-string.prototype.codepointat
4333
- codeAt: createMethod(false),
3650
+ codeAt: createMethod$2(false),
4334
3651
  // `String.prototype.at` method
4335
3652
  // https://github.com/mathiasbynens/String.prototype.at
4336
- charAt: createMethod(true)
3653
+ charAt: createMethod$2(true)
4337
3654
  };
4338
3655
 
4339
3656
  var charAt$1 = stringMultibyte.charAt;
4340
3657
 
4341
3658
  // `AdvanceStringIndex` abstract operation
4342
3659
  // https://tc39.es/ecma262/#sec-advancestringindex
4343
- var advanceStringIndex$1 = function (S, index, unicode) {
3660
+ var advanceStringIndex$2 = function (S, index, unicode) {
4344
3661
  return index + (unicode ? charAt$1(S, index).length : 1);
4345
3662
  };
4346
3663
 
4347
- var uncurryThis$1 = functionUncurryThis;
4348
- var toObject = toObject$4;
3664
+ var uncurryThis$4 = functionUncurryThis;
3665
+ var toObject$1 = toObject$5;
4349
3666
 
4350
3667
  var floor = Math.floor;
4351
- var charAt = uncurryThis$1(''.charAt);
4352
- var replace = uncurryThis$1(''.replace);
4353
- var stringSlice$1 = uncurryThis$1(''.slice);
3668
+ var charAt = uncurryThis$4(''.charAt);
3669
+ var replace$1 = uncurryThis$4(''.replace);
3670
+ var stringSlice$2 = uncurryThis$4(''.slice);
4354
3671
  var SUBSTITUTION_SYMBOLS = /\$([$&'`]|\d{1,2}|<[^>]*>)/g;
4355
3672
  var SUBSTITUTION_SYMBOLS_NO_NAMED = /\$([$&'`]|\d{1,2})/g;
4356
3673
 
@@ -4361,18 +3678,18 @@ var getSubstitution$1 = function (matched, str, position, captures, namedCapture
4361
3678
  var m = captures.length;
4362
3679
  var symbols = SUBSTITUTION_SYMBOLS_NO_NAMED;
4363
3680
  if (namedCaptures !== undefined) {
4364
- namedCaptures = toObject(namedCaptures);
3681
+ namedCaptures = toObject$1(namedCaptures);
4365
3682
  symbols = SUBSTITUTION_SYMBOLS;
4366
3683
  }
4367
- return replace(replacement, symbols, function (match, ch) {
3684
+ return replace$1(replacement, symbols, function (match, ch) {
4368
3685
  var capture;
4369
3686
  switch (charAt(ch, 0)) {
4370
3687
  case '$': return '$';
4371
3688
  case '&': return matched;
4372
- case '`': return stringSlice$1(str, 0, position);
4373
- case "'": return stringSlice$1(str, tailPos);
3689
+ case '`': return stringSlice$2(str, 0, position);
3690
+ case "'": return stringSlice$2(str, tailPos);
4374
3691
  case '<':
4375
- capture = namedCaptures[stringSlice$1(ch, 1, -1)];
3692
+ capture = namedCaptures[stringSlice$2(ch, 1, -1)];
4376
3693
  break;
4377
3694
  default: // \d\d?
4378
3695
  var n = +ch;
@@ -4389,52 +3706,52 @@ var getSubstitution$1 = function (matched, str, position, captures, namedCapture
4389
3706
  });
4390
3707
  };
4391
3708
 
4392
- var global$1 = global$H;
4393
- var call$1 = functionCall;
4394
- var anObject$1 = anObject$d;
3709
+ var global$4 = global$K;
3710
+ var call$2 = functionCall;
3711
+ var anObject$2 = anObject$e;
4395
3712
  var isCallable$1 = isCallable$j;
4396
3713
  var classof = classofRaw$1;
4397
- var regexpExec = regexpExec$2;
3714
+ var regexpExec$1 = regexpExec$3;
4398
3715
 
4399
- var TypeError$1 = global$1.TypeError;
3716
+ var TypeError$2 = global$4.TypeError;
4400
3717
 
4401
3718
  // `RegExpExec` abstract operation
4402
3719
  // https://tc39.es/ecma262/#sec-regexpexec
4403
3720
  var regexpExecAbstract = function (R, S) {
4404
3721
  var exec = R.exec;
4405
3722
  if (isCallable$1(exec)) {
4406
- var result = call$1(exec, R, S);
4407
- if (result !== null) anObject$1(result);
3723
+ var result = call$2(exec, R, S);
3724
+ if (result !== null) anObject$2(result);
4408
3725
  return result;
4409
3726
  }
4410
- if (classof(R) === 'RegExp') return call$1(regexpExec, R, S);
4411
- throw TypeError$1('RegExp#exec called on incompatible receiver');
3727
+ if (classof(R) === 'RegExp') return call$2(regexpExec$1, R, S);
3728
+ throw TypeError$2('RegExp#exec called on incompatible receiver');
4412
3729
  };
4413
3730
 
4414
- var apply = functionApply;
4415
- var call = functionCall;
4416
- var uncurryThis = functionUncurryThis;
4417
- var fixRegExpWellKnownSymbolLogic = fixRegexpWellKnownSymbolLogic;
4418
- var fails = fails$h;
4419
- var anObject = anObject$d;
3731
+ var apply$1 = functionApply;
3732
+ var call$1 = functionCall;
3733
+ var uncurryThis$3 = functionUncurryThis;
3734
+ var fixRegExpWellKnownSymbolLogic$1 = fixRegexpWellKnownSymbolLogic;
3735
+ var fails$3 = fails$k;
3736
+ var anObject$1 = anObject$e;
4420
3737
  var isCallable = isCallable$j;
4421
3738
  var toIntegerOrInfinity = toIntegerOrInfinity$4;
4422
- var toLength = toLength$3;
4423
- var toString = toString$4;
4424
- var requireObjectCoercible = requireObjectCoercible$5;
4425
- var advanceStringIndex = advanceStringIndex$1;
4426
- var getMethod = getMethod$4;
3739
+ var toLength$1 = toLength$4;
3740
+ var toString$3 = toString$7;
3741
+ var requireObjectCoercible$2 = requireObjectCoercible$7;
3742
+ var advanceStringIndex$1 = advanceStringIndex$2;
3743
+ var getMethod$1 = getMethod$5;
4427
3744
  var getSubstitution = getSubstitution$1;
4428
3745
  var regExpExec = regexpExecAbstract;
4429
3746
  var wellKnownSymbol = wellKnownSymbol$i;
4430
3747
 
4431
3748
  var REPLACE = wellKnownSymbol('replace');
4432
- var max = Math.max;
4433
- var min = Math.min;
4434
- var concat = uncurryThis([].concat);
4435
- var push = uncurryThis([].push);
4436
- var stringIndexOf = uncurryThis(''.indexOf);
4437
- var stringSlice = uncurryThis(''.slice);
3749
+ var max$1 = Math.max;
3750
+ var min$1 = Math.min;
3751
+ var concat = uncurryThis$3([].concat);
3752
+ var push$1 = uncurryThis$3([].push);
3753
+ var stringIndexOf = uncurryThis$3(''.indexOf);
3754
+ var stringSlice$1 = uncurryThis$3(''.slice);
4438
3755
 
4439
3756
  var maybeToString = function (it) {
4440
3757
  return it === undefined ? it : String(it);
@@ -4455,7 +3772,7 @@ var REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE = (function () {
4455
3772
  return false;
4456
3773
  })();
4457
3774
 
4458
- var REPLACE_SUPPORTS_NAMED_GROUPS = !fails(function () {
3775
+ var REPLACE_SUPPORTS_NAMED_GROUPS = !fails$3(function () {
4459
3776
  var re = /./;
4460
3777
  re.exec = function () {
4461
3778
  var result = [];
@@ -4467,24 +3784,24 @@ var REPLACE_SUPPORTS_NAMED_GROUPS = !fails(function () {
4467
3784
  });
4468
3785
 
4469
3786
  // @@replace logic
4470
- fixRegExpWellKnownSymbolLogic('replace', function (_, nativeReplace, maybeCallNative) {
3787
+ fixRegExpWellKnownSymbolLogic$1('replace', function (_, nativeReplace, maybeCallNative) {
4471
3788
  var UNSAFE_SUBSTITUTE = REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE ? '$' : '$0';
4472
3789
 
4473
3790
  return [
4474
3791
  // `String.prototype.replace` method
4475
3792
  // https://tc39.es/ecma262/#sec-string.prototype.replace
4476
3793
  function replace(searchValue, replaceValue) {
4477
- var O = requireObjectCoercible(this);
4478
- var replacer = searchValue == undefined ? undefined : getMethod(searchValue, REPLACE);
3794
+ var O = requireObjectCoercible$2(this);
3795
+ var replacer = searchValue == undefined ? undefined : getMethod$1(searchValue, REPLACE);
4479
3796
  return replacer
4480
- ? call(replacer, searchValue, O, replaceValue)
4481
- : call(nativeReplace, toString(O), searchValue, replaceValue);
3797
+ ? call$1(replacer, searchValue, O, replaceValue)
3798
+ : call$1(nativeReplace, toString$3(O), searchValue, replaceValue);
4482
3799
  },
4483
3800
  // `RegExp.prototype[@@replace]` method
4484
3801
  // https://tc39.es/ecma262/#sec-regexp.prototype-@@replace
4485
3802
  function (string, replaceValue) {
4486
- var rx = anObject(this);
4487
- var S = toString(string);
3803
+ var rx = anObject$1(this);
3804
+ var S = toString$3(string);
4488
3805
 
4489
3806
  if (
4490
3807
  typeof replaceValue == 'string' &&
@@ -4496,7 +3813,7 @@ fixRegExpWellKnownSymbolLogic('replace', function (_, nativeReplace, maybeCallNa
4496
3813
  }
4497
3814
 
4498
3815
  var functionalReplace = isCallable(replaceValue);
4499
- if (!functionalReplace) replaceValue = toString(replaceValue);
3816
+ if (!functionalReplace) replaceValue = toString$3(replaceValue);
4500
3817
 
4501
3818
  var global = rx.global;
4502
3819
  if (global) {
@@ -4508,11 +3825,11 @@ fixRegExpWellKnownSymbolLogic('replace', function (_, nativeReplace, maybeCallNa
4508
3825
  var result = regExpExec(rx, S);
4509
3826
  if (result === null) break;
4510
3827
 
4511
- push(results, result);
3828
+ push$1(results, result);
4512
3829
  if (!global) break;
4513
3830
 
4514
- var matchStr = toString(result[0]);
4515
- if (matchStr === '') rx.lastIndex = advanceStringIndex(S, toLength(rx.lastIndex), fullUnicode);
3831
+ var matchStr = toString$3(result[0]);
3832
+ if (matchStr === '') rx.lastIndex = advanceStringIndex$1(S, toLength$1(rx.lastIndex), fullUnicode);
4516
3833
  }
4517
3834
 
4518
3835
  var accumulatedResult = '';
@@ -4520,35 +3837,33 @@ fixRegExpWellKnownSymbolLogic('replace', function (_, nativeReplace, maybeCallNa
4520
3837
  for (var i = 0; i < results.length; i++) {
4521
3838
  result = results[i];
4522
3839
 
4523
- var matched = toString(result[0]);
4524
- var position = max(min(toIntegerOrInfinity(result.index), S.length), 0);
3840
+ var matched = toString$3(result[0]);
3841
+ var position = max$1(min$1(toIntegerOrInfinity(result.index), S.length), 0);
4525
3842
  var captures = [];
4526
3843
  // NOTE: This is equivalent to
4527
3844
  // captures = result.slice(1).map(maybeToString)
4528
3845
  // but for some reason `nativeSlice.call(result, 1, result.length)` (called in
4529
3846
  // the slice polyfill when slicing native arrays) "doesn't work" in safari 9 and
4530
3847
  // causes a crash (https://pastebin.com/N21QzeQA) when trying to debug it.
4531
- for (var j = 1; j < result.length; j++) push(captures, maybeToString(result[j]));
3848
+ for (var j = 1; j < result.length; j++) push$1(captures, maybeToString(result[j]));
4532
3849
  var namedCaptures = result.groups;
4533
3850
  if (functionalReplace) {
4534
3851
  var replacerArgs = concat([matched], captures, position, S);
4535
- if (namedCaptures !== undefined) push(replacerArgs, namedCaptures);
4536
- var replacement = toString(apply(replaceValue, undefined, replacerArgs));
3852
+ if (namedCaptures !== undefined) push$1(replacerArgs, namedCaptures);
3853
+ var replacement = toString$3(apply$1(replaceValue, undefined, replacerArgs));
4537
3854
  } else {
4538
3855
  replacement = getSubstitution(matched, S, position, captures, namedCaptures, replaceValue);
4539
3856
  }
4540
3857
  if (position >= nextSourcePosition) {
4541
- accumulatedResult += stringSlice(S, nextSourcePosition, position) + replacement;
3858
+ accumulatedResult += stringSlice$1(S, nextSourcePosition, position) + replacement;
4542
3859
  nextSourcePosition = position + matched.length;
4543
3860
  }
4544
3861
  }
4545
- return accumulatedResult + stringSlice(S, nextSourcePosition);
3862
+ return accumulatedResult + stringSlice$1(S, nextSourcePosition);
4546
3863
  }
4547
3864
  ];
4548
3865
  }, !REPLACE_SUPPORTS_NAMED_GROUPS || !REPLACE_KEEPS_$0 || REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE);
4549
3866
 
4550
- const EXPERIENCE_TRAIT_PREFIX = 'nt_experiment_';
4551
-
4552
3867
  const selectActiveExperiments = (experiments, profile) => {
4553
3868
  const experimentTraits = pickBy(profile.traits, (value, key) => key.startsWith(EXPERIENCE_TRAIT_PREFIX) && value === true);
4554
3869
  const experimentTraitsIds = Object.keys(experimentTraits).map(id => id.replace(EXPERIENCE_TRAIT_PREFIX, '')); // a experiment is active when the use has it set as a true value on the traits and the experiment config is still active
@@ -4558,12 +3873,12 @@ const selectActiveExperiments = (experiments, profile) => {
4558
3873
  };
4559
3874
 
4560
3875
  /**
4561
- * We can use any personalization as eglible experience
3876
+ * We can use any personalization as eligible experience
4562
3877
  * When going for an experiment we can only select a active experiment when 1 or more experiments are active
4563
3878
  * If the profile is not in any active experiments, we can select any expermiment
4564
3879
  */
4565
3880
 
4566
- const selectEglibleExperiences = ({
3881
+ const selectEligibleExperiences = ({
4567
3882
  experiences,
4568
3883
  activeExperiments
4569
3884
  }) => {
@@ -4572,23 +3887,70 @@ const selectEglibleExperiences = ({
4572
3887
  }));
4573
3888
  };
4574
3889
 
3890
+ const LOWER_BOUND = 0;
3891
+ const UPPER_BOUND = 4294967295;
3892
+
3893
+ const normalize = (val, min, max) => (val - min) / (max - min);
3894
+
3895
+ const getRandom = text => {
3896
+ const hash = murmur3(text, 0);
3897
+ const random = normalize(hash, LOWER_BOUND, UPPER_BOUND);
3898
+ return random;
3899
+ };
3900
+
3901
+ const getTrafficRandom = (profile, experience) => getRandom(`traffic-${experience.id}-${profile.id}`);
3902
+ const getDistributionRandom = (profile, experience) => getRandom(`distribution-${experience.id}-${profile.id}`);
3903
+
3904
+ const isExperienceMatch = ({
3905
+ experience,
3906
+ activeExperiments,
3907
+ profile
3908
+ }) => {
3909
+ const trafficRandom = getTrafficRandom(profile, experience);
3910
+ log(`The traffic random factor for experience ${experience.id} is ${trafficRandom}. It's traffic allocation is set to ${experience.trafficAllocation}.`);
3911
+ const isInTrafficRange = experience.trafficAllocation > trafficRandom;
3912
+ const matchesAudience = !experience.audience || includes(profile.audiences, experience.audience.id);
3913
+ const hasActiveExperiment = !!find(activeExperiments, {
3914
+ id: experience.id
3915
+ });
3916
+ log(`Is the profile in traffic allocation range? ${isInTrafficRange ? 'yes' : 'no'}.\n
3917
+ Does the profile match the audience of the experience? ${matchesAudience ? 'yes' : 'no'}.\n
3918
+ Is there an active experiment for this profile? ${hasActiveExperiment ? 'yes' : 'no'}.`);
3919
+ return isInTrafficRange && (matchesAudience || // if the expriment is active already then it's selectible without further contraints to be fullfilled
3920
+ hasActiveExperiment);
3921
+ };
3922
+
4575
3923
  const selectExperience = ({
4576
3924
  experiences,
4577
3925
  activeExperiments,
4578
3926
  profile
4579
3927
  }) => {
4580
- const eglibleExperiences = selectEglibleExperiences({
3928
+ const eligibleExperiences = selectEligibleExperiences({
4581
3929
  experiences,
4582
3930
  activeExperiments
4583
3931
  });
4584
- const selectedExperience = eglibleExperiences.find(experience => // TODO check traffic allocation
4585
- includes(profile.audiences, experience.audience.id) || // if the expriment is active already then it's selectible without further contraints to be fullfilled
4586
- find(activeExperiments, {
4587
- id: experience.id
3932
+ const selectedExperience = eligibleExperiences.find(experience => isExperienceMatch({
3933
+ experience,
3934
+ activeExperiments,
3935
+ profile
4588
3936
  }));
4589
3937
  return selectedExperience;
4590
3938
  };
4591
3939
 
3940
+ const selectDistribution = ({
3941
+ experience,
3942
+ profile
3943
+ }) => {
3944
+ const distributionRandom = getDistributionRandom(profile, experience);
3945
+ log(`The distribution random factor for experience ${experience.id} is ${distributionRandom}. It's distribution is set to ${JSON.stringify(experience.distribution, null, 2)}.`);
3946
+ const distribution = find(experience.distribution, ({
3947
+ start,
3948
+ end
3949
+ }) => distributionRandom >= start && distributionRandom <= end // this overlaps on one value for each boundary but we just find the first match
3950
+ );
3951
+ return distribution;
3952
+ };
3953
+
4592
3954
  const selectVariant = ({
4593
3955
  baseline,
4594
3956
  experience,
@@ -4598,20 +3960,12 @@ const selectVariant = ({
4598
3960
 
4599
3961
  if (!variants.length) {
4600
3962
  return null;
4601
- } // Personalization
4602
-
4603
-
4604
- if (experience.type === 'nt_personalization') {
4605
- // TODO check holdout
4606
- // Personalization Expriences can have only one variant.
4607
- return variants[0];
4608
- } // Experiment
4609
-
3963
+ }
4610
3964
 
4611
- const distribution = find(experience.distribution, ({
4612
- start,
4613
- end
4614
- }) => profile.random > start && profile.random < end);
3965
+ const distribution = selectDistribution({
3966
+ experience,
3967
+ profile
3968
+ });
4615
3969
 
4616
3970
  if (!distribution) {
4617
3971
  return null;
@@ -4640,4 +3994,348 @@ const selectVariant = ({
4640
3994
  return variant;
4641
3995
  };
4642
3996
 
4643
- export { NINETAILED_TRACKER_EVENTS, Ninetailed, PLUGIN_NAME, ninetailedPlugin, selectActiveExperiments, selectEglibleExperiences, selectExperience, selectBaselineWithVariants as selectExperienceBaselineWithVariants, selectVariant as selectExperienceVariant, selectVariants as selectExperienceVariants, selectHasVariants as selectHasExperienceVariants, selectVariant$1 as selectVariant };
3997
+ var global$3 = global$K;
3998
+ var aCallable = aCallable$6;
3999
+ var toObject = toObject$5;
4000
+ var IndexedObject = indexedObject;
4001
+ var lengthOfArrayLike$1 = lengthOfArrayLike$4;
4002
+
4003
+ var TypeError$1 = global$3.TypeError;
4004
+
4005
+ // `Array.prototype.{ reduce, reduceRight }` methods implementation
4006
+ var createMethod$1 = function (IS_RIGHT) {
4007
+ return function (that, callbackfn, argumentsLength, memo) {
4008
+ aCallable(callbackfn);
4009
+ var O = toObject(that);
4010
+ var self = IndexedObject(O);
4011
+ var length = lengthOfArrayLike$1(O);
4012
+ var index = IS_RIGHT ? length - 1 : 0;
4013
+ var i = IS_RIGHT ? -1 : 1;
4014
+ if (argumentsLength < 2) while (true) {
4015
+ if (index in self) {
4016
+ memo = self[index];
4017
+ index += i;
4018
+ break;
4019
+ }
4020
+ index += i;
4021
+ if (IS_RIGHT ? index < 0 : length <= index) {
4022
+ throw TypeError$1('Reduce of empty array with no initial value');
4023
+ }
4024
+ }
4025
+ for (;IS_RIGHT ? index >= 0 : length > index; index += i) if (index in self) {
4026
+ memo = callbackfn(memo, self[index], index, O);
4027
+ }
4028
+ return memo;
4029
+ };
4030
+ };
4031
+
4032
+ var arrayReduce = {
4033
+ // `Array.prototype.reduce` method
4034
+ // https://tc39.es/ecma262/#sec-array.prototype.reduce
4035
+ left: createMethod$1(false),
4036
+ // `Array.prototype.reduceRight` method
4037
+ // https://tc39.es/ecma262/#sec-array.prototype.reduceright
4038
+ right: createMethod$1(true)
4039
+ };
4040
+
4041
+ var fails$2 = fails$k;
4042
+
4043
+ var arrayMethodIsStrict$1 = function (METHOD_NAME, argument) {
4044
+ var method = [][METHOD_NAME];
4045
+ return !!method && fails$2(function () {
4046
+ // eslint-disable-next-line no-useless-call -- required for testing
4047
+ method.call(null, argument || function () { return 1; }, 1);
4048
+ });
4049
+ };
4050
+
4051
+ var $$1 = _export;
4052
+ var $reduce = arrayReduce.left;
4053
+ var arrayMethodIsStrict = arrayMethodIsStrict$1;
4054
+ var CHROME_VERSION = engineV8Version;
4055
+ var IS_NODE = engineIsNode;
4056
+
4057
+ var STRICT_METHOD = arrayMethodIsStrict('reduce');
4058
+ // Chrome 80-82 has a critical bug
4059
+ // https://bugs.chromium.org/p/chromium/issues/detail?id=1049982
4060
+ var CHROME_BUG = !IS_NODE && CHROME_VERSION > 79 && CHROME_VERSION < 83;
4061
+
4062
+ // `Array.prototype.reduce` method
4063
+ // https://tc39.es/ecma262/#sec-array.prototype.reduce
4064
+ $$1({ target: 'Array', proto: true, forced: !STRICT_METHOD || CHROME_BUG }, {
4065
+ reduce: function reduce(callbackfn /* , initialValue */) {
4066
+ var length = arguments.length;
4067
+ return $reduce(this, callbackfn, length, length > 1 ? arguments[1] : undefined);
4068
+ }
4069
+ });
4070
+
4071
+ var toPropertyKey = toPropertyKey$3;
4072
+ var definePropertyModule = objectDefineProperty;
4073
+ var createPropertyDescriptor = createPropertyDescriptor$4;
4074
+
4075
+ var createProperty$1 = function (object, key, value) {
4076
+ var propertyKey = toPropertyKey(key);
4077
+ if (propertyKey in object) definePropertyModule.f(object, propertyKey, createPropertyDescriptor(0, value));
4078
+ else object[propertyKey] = value;
4079
+ };
4080
+
4081
+ var global$2 = global$K;
4082
+ var toAbsoluteIndex = toAbsoluteIndex$2;
4083
+ var lengthOfArrayLike = lengthOfArrayLike$4;
4084
+ var createProperty = createProperty$1;
4085
+
4086
+ var Array$1 = global$2.Array;
4087
+ var max = Math.max;
4088
+
4089
+ var arraySliceSimple = function (O, start, end) {
4090
+ var length = lengthOfArrayLike(O);
4091
+ var k = toAbsoluteIndex(start, length);
4092
+ var fin = toAbsoluteIndex(end === undefined ? length : end, length);
4093
+ var result = Array$1(max(fin - k, 0));
4094
+ for (var n = 0; k < fin; k++, n++) createProperty(result, n, O[k]);
4095
+ result.length = n;
4096
+ return result;
4097
+ };
4098
+
4099
+ var apply = functionApply;
4100
+ var call = functionCall;
4101
+ var uncurryThis$2 = functionUncurryThis;
4102
+ var fixRegExpWellKnownSymbolLogic = fixRegexpWellKnownSymbolLogic;
4103
+ var isRegExp = isRegexp;
4104
+ var anObject = anObject$e;
4105
+ var requireObjectCoercible$1 = requireObjectCoercible$7;
4106
+ var speciesConstructor = speciesConstructor$2;
4107
+ var advanceStringIndex = advanceStringIndex$2;
4108
+ var toLength = toLength$4;
4109
+ var toString$2 = toString$7;
4110
+ var getMethod = getMethod$5;
4111
+ var arraySlice = arraySliceSimple;
4112
+ var callRegExpExec = regexpExecAbstract;
4113
+ var regexpExec = regexpExec$3;
4114
+ var stickyHelpers = regexpStickyHelpers;
4115
+ var fails$1 = fails$k;
4116
+
4117
+ var UNSUPPORTED_Y = stickyHelpers.UNSUPPORTED_Y;
4118
+ var MAX_UINT32 = 0xFFFFFFFF;
4119
+ var min = Math.min;
4120
+ var $push = [].push;
4121
+ var exec$1 = uncurryThis$2(/./.exec);
4122
+ var push = uncurryThis$2($push);
4123
+ var stringSlice = uncurryThis$2(''.slice);
4124
+
4125
+ // Chrome 51 has a buggy "split" implementation when RegExp#exec !== nativeExec
4126
+ // Weex JS has frozen built-in prototypes, so use try / catch wrapper
4127
+ var SPLIT_WORKS_WITH_OVERWRITTEN_EXEC = !fails$1(function () {
4128
+ // eslint-disable-next-line regexp/no-empty-group -- required for testing
4129
+ var re = /(?:)/;
4130
+ var originalExec = re.exec;
4131
+ re.exec = function () { return originalExec.apply(this, arguments); };
4132
+ var result = 'ab'.split(re);
4133
+ return result.length !== 2 || result[0] !== 'a' || result[1] !== 'b';
4134
+ });
4135
+
4136
+ // @@split logic
4137
+ fixRegExpWellKnownSymbolLogic('split', function (SPLIT, nativeSplit, maybeCallNative) {
4138
+ var internalSplit;
4139
+ if (
4140
+ 'abbc'.split(/(b)*/)[1] == 'c' ||
4141
+ // eslint-disable-next-line regexp/no-empty-group -- required for testing
4142
+ 'test'.split(/(?:)/, -1).length != 4 ||
4143
+ 'ab'.split(/(?:ab)*/).length != 2 ||
4144
+ '.'.split(/(.?)(.?)/).length != 4 ||
4145
+ // eslint-disable-next-line regexp/no-empty-capturing-group, regexp/no-empty-group -- required for testing
4146
+ '.'.split(/()()/).length > 1 ||
4147
+ ''.split(/.?/).length
4148
+ ) {
4149
+ // based on es5-shim implementation, need to rework it
4150
+ internalSplit = function (separator, limit) {
4151
+ var string = toString$2(requireObjectCoercible$1(this));
4152
+ var lim = limit === undefined ? MAX_UINT32 : limit >>> 0;
4153
+ if (lim === 0) return [];
4154
+ if (separator === undefined) return [string];
4155
+ // If `separator` is not a regex, use native split
4156
+ if (!isRegExp(separator)) {
4157
+ return call(nativeSplit, string, separator, lim);
4158
+ }
4159
+ var output = [];
4160
+ var flags = (separator.ignoreCase ? 'i' : '') +
4161
+ (separator.multiline ? 'm' : '') +
4162
+ (separator.unicode ? 'u' : '') +
4163
+ (separator.sticky ? 'y' : '');
4164
+ var lastLastIndex = 0;
4165
+ // Make `global` and avoid `lastIndex` issues by working with a copy
4166
+ var separatorCopy = new RegExp(separator.source, flags + 'g');
4167
+ var match, lastIndex, lastLength;
4168
+ while (match = call(regexpExec, separatorCopy, string)) {
4169
+ lastIndex = separatorCopy.lastIndex;
4170
+ if (lastIndex > lastLastIndex) {
4171
+ push(output, stringSlice(string, lastLastIndex, match.index));
4172
+ if (match.length > 1 && match.index < string.length) apply($push, output, arraySlice(match, 1));
4173
+ lastLength = match[0].length;
4174
+ lastLastIndex = lastIndex;
4175
+ if (output.length >= lim) break;
4176
+ }
4177
+ if (separatorCopy.lastIndex === match.index) separatorCopy.lastIndex++; // Avoid an infinite loop
4178
+ }
4179
+ if (lastLastIndex === string.length) {
4180
+ if (lastLength || !exec$1(separatorCopy, '')) push(output, '');
4181
+ } else push(output, stringSlice(string, lastLastIndex));
4182
+ return output.length > lim ? arraySlice(output, 0, lim) : output;
4183
+ };
4184
+ // Chakra, V8
4185
+ } else if ('0'.split(undefined, 0).length) {
4186
+ internalSplit = function (separator, limit) {
4187
+ return separator === undefined && limit === 0 ? [] : call(nativeSplit, this, separator, limit);
4188
+ };
4189
+ } else internalSplit = nativeSplit;
4190
+
4191
+ return [
4192
+ // `String.prototype.split` method
4193
+ // https://tc39.es/ecma262/#sec-string.prototype.split
4194
+ function split(separator, limit) {
4195
+ var O = requireObjectCoercible$1(this);
4196
+ var splitter = separator == undefined ? undefined : getMethod(separator, SPLIT);
4197
+ return splitter
4198
+ ? call(splitter, separator, O, limit)
4199
+ : call(internalSplit, toString$2(O), separator, limit);
4200
+ },
4201
+ // `RegExp.prototype[@@split]` method
4202
+ // https://tc39.es/ecma262/#sec-regexp.prototype-@@split
4203
+ //
4204
+ // NOTE: This cannot be properly polyfilled in engines that don't support
4205
+ // the 'y' flag.
4206
+ function (string, limit) {
4207
+ var rx = anObject(this);
4208
+ var S = toString$2(string);
4209
+ var res = maybeCallNative(internalSplit, rx, S, limit, internalSplit !== nativeSplit);
4210
+
4211
+ if (res.done) return res.value;
4212
+
4213
+ var C = speciesConstructor(rx, RegExp);
4214
+
4215
+ var unicodeMatching = rx.unicode;
4216
+ var flags = (rx.ignoreCase ? 'i' : '') +
4217
+ (rx.multiline ? 'm' : '') +
4218
+ (rx.unicode ? 'u' : '') +
4219
+ (UNSUPPORTED_Y ? 'g' : 'y');
4220
+
4221
+ // ^(? + rx + ) is needed, in combination with some S slicing, to
4222
+ // simulate the 'y' flag.
4223
+ var splitter = new C(UNSUPPORTED_Y ? '^(?:' + rx.source + ')' : rx, flags);
4224
+ var lim = limit === undefined ? MAX_UINT32 : limit >>> 0;
4225
+ if (lim === 0) return [];
4226
+ if (S.length === 0) return callRegExpExec(splitter, S) === null ? [S] : [];
4227
+ var p = 0;
4228
+ var q = 0;
4229
+ var A = [];
4230
+ while (q < S.length) {
4231
+ splitter.lastIndex = UNSUPPORTED_Y ? 0 : q;
4232
+ var z = callRegExpExec(splitter, UNSUPPORTED_Y ? stringSlice(S, q) : S);
4233
+ var e;
4234
+ if (
4235
+ z === null ||
4236
+ (e = min(toLength(splitter.lastIndex + (UNSUPPORTED_Y ? q : 0)), S.length)) === p
4237
+ ) {
4238
+ q = advanceStringIndex(S, q, unicodeMatching);
4239
+ } else {
4240
+ push(A, stringSlice(S, p, q));
4241
+ if (A.length === lim) return A;
4242
+ for (var i = 1; i <= z.length - 1; i++) {
4243
+ push(A, z[i]);
4244
+ if (A.length === lim) return A;
4245
+ }
4246
+ q = p = e;
4247
+ }
4248
+ }
4249
+ push(A, stringSlice(S, p));
4250
+ return A;
4251
+ }
4252
+ ];
4253
+ }, !SPLIT_WORKS_WITH_OVERWRITTEN_EXEC, UNSUPPORTED_Y);
4254
+
4255
+ // a string of all valid unicode whitespaces
4256
+ var whitespaces$2 = '\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u2000\u2001\u2002' +
4257
+ '\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF';
4258
+
4259
+ var uncurryThis$1 = functionUncurryThis;
4260
+ var requireObjectCoercible = requireObjectCoercible$7;
4261
+ var toString$1 = toString$7;
4262
+ var whitespaces$1 = whitespaces$2;
4263
+
4264
+ var replace = uncurryThis$1(''.replace);
4265
+ var whitespace = '[' + whitespaces$1 + ']';
4266
+ var ltrim = RegExp('^' + whitespace + whitespace + '*');
4267
+ var rtrim = RegExp(whitespace + whitespace + '*$');
4268
+
4269
+ // `String.prototype.{ trim, trimStart, trimEnd, trimLeft, trimRight }` methods implementation
4270
+ var createMethod = function (TYPE) {
4271
+ return function ($this) {
4272
+ var string = toString$1(requireObjectCoercible($this));
4273
+ if (TYPE & 1) string = replace(string, ltrim, '');
4274
+ if (TYPE & 2) string = replace(string, rtrim, '');
4275
+ return string;
4276
+ };
4277
+ };
4278
+
4279
+ var stringTrim = {
4280
+ // `String.prototype.{ trimLeft, trimStart }` methods
4281
+ // https://tc39.es/ecma262/#sec-string.prototype.trimstart
4282
+ start: createMethod(1),
4283
+ // `String.prototype.{ trimRight, trimEnd }` methods
4284
+ // https://tc39.es/ecma262/#sec-string.prototype.trimend
4285
+ end: createMethod(2),
4286
+ // `String.prototype.trim` method
4287
+ // https://tc39.es/ecma262/#sec-string.prototype.trim
4288
+ trim: createMethod(3)
4289
+ };
4290
+
4291
+ var global$1 = global$K;
4292
+ var fails = fails$k;
4293
+ var uncurryThis = functionUncurryThis;
4294
+ var toString = toString$7;
4295
+ var trim = stringTrim.trim;
4296
+ var whitespaces = whitespaces$2;
4297
+
4298
+ var $parseInt$1 = global$1.parseInt;
4299
+ var Symbol$1 = global$1.Symbol;
4300
+ var ITERATOR = Symbol$1 && Symbol$1.iterator;
4301
+ var hex = /^[+-]?0x/i;
4302
+ var exec = uncurryThis(hex.exec);
4303
+ var FORCED = $parseInt$1(whitespaces + '08') !== 8 || $parseInt$1(whitespaces + '0x16') !== 22
4304
+ // MS Edge 18- broken with boxed symbols
4305
+ || (ITERATOR && !fails(function () { $parseInt$1(Object(ITERATOR)); }));
4306
+
4307
+ // `parseInt` method
4308
+ // https://tc39.es/ecma262/#sec-parseint-string-radix
4309
+ var numberParseInt = FORCED ? function parseInt(string, radix) {
4310
+ var S = trim(toString(string));
4311
+ return $parseInt$1(S, (radix >>> 0) || (exec(hex, S) ? 16 : 10));
4312
+ } : $parseInt$1;
4313
+
4314
+ var $ = _export;
4315
+ var $parseInt = numberParseInt;
4316
+
4317
+ // `parseInt` method
4318
+ // https://tc39.es/ecma262/#sec-parseint-string-radix
4319
+ $({ global: true, forced: parseInt != $parseInt }, {
4320
+ parseInt: $parseInt
4321
+ });
4322
+
4323
+ const decodeExperienceVariantsMap = encodedExperienceVariantsMap => {
4324
+ return encodedExperienceVariantsMap.split(',').map(experienceIdWithVariant => {
4325
+ const [experienceId, _variantIndex] = experienceIdWithVariant.split('=');
4326
+ const variantIndex = parseInt(_variantIndex);
4327
+
4328
+ if (!experienceId || !variantIndex) {
4329
+ return null;
4330
+ }
4331
+
4332
+ return {
4333
+ experienceId,
4334
+ variantIndex
4335
+ };
4336
+ }).filter(x => x).reduce((acc, curr) => Object.assign(Object.assign({}, acc), {
4337
+ [curr.experienceId]: curr.variantIndex
4338
+ }), {});
4339
+ };
4340
+
4341
+ export { index as Cache, EXPERIENCE_TRAIT_PREFIX, NINETAILED_TRACKER_EVENTS, Ninetailed, PLUGIN_NAME, decodeExperienceVariantsMap, isExperienceMatch, ninetailedPlugin, selectActiveExperiments, selectDistribution, selectEligibleExperiences, selectExperience, selectBaselineWithVariants as selectExperienceBaselineWithVariants, selectVariant as selectExperienceVariant, selectVariants as selectExperienceVariants, selectHasVariants as selectHasExperienceVariants, selectVariant$1 as selectVariant };