@dereekb/browser 12.5.9 → 12.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.cjs.js CHANGED
@@ -3,6 +3,876 @@
3
3
  var rxjs$1 = require('@dereekb/rxjs');
4
4
  var rxjs = require('rxjs');
5
5
 
6
+ var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
7
+
8
+ // https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot
9
+ var documentAll = typeof document == 'object' && document.all;
10
+
11
+ // `IsCallable` abstract operation
12
+ // https://tc39.es/ecma262/#sec-iscallable
13
+ // eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
14
+ var isCallable$a = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
15
+ return typeof argument == 'function' || argument === documentAll;
16
+ } : function (argument) {
17
+ return typeof argument == 'function';
18
+ };
19
+
20
+ var objectDefineProperty = {};
21
+
22
+ var fails$6 = function (exec) {
23
+ try {
24
+ return !!exec();
25
+ } catch (error) {
26
+ return true;
27
+ }
28
+ };
29
+
30
+ var fails$5 = fails$6;
31
+
32
+ // Detect IE8's incomplete defineProperty implementation
33
+ var descriptors = !fails$5(function () {
34
+ // eslint-disable-next-line es/no-object-defineproperty -- required for testing
35
+ return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
36
+ });
37
+
38
+ var check = function (it) {
39
+ return it && it.Math === Math && it;
40
+ };
41
+
42
+ // https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
43
+ var global$9 =
44
+ // eslint-disable-next-line es/no-global-this -- safe
45
+ check(typeof globalThis == 'object' && globalThis) ||
46
+ check(typeof window == 'object' && window) ||
47
+ // eslint-disable-next-line no-restricted-globals -- safe
48
+ check(typeof self == 'object' && self) ||
49
+ check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
50
+ check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
51
+ // eslint-disable-next-line no-new-func -- fallback
52
+ (function () { return this; })() || Function('return this')();
53
+
54
+ var isCallable$9 = isCallable$a;
55
+
56
+ var isObject$5 = function (it) {
57
+ return typeof it == 'object' ? it !== null : isCallable$9(it);
58
+ };
59
+
60
+ var global$8 = global$9;
61
+ var isObject$4 = isObject$5;
62
+
63
+ var document$1 = global$8.document;
64
+ // typeof document.createElement is 'object' in old IE
65
+ var EXISTS$1 = isObject$4(document$1) && isObject$4(document$1.createElement);
66
+
67
+ var documentCreateElement = function (it) {
68
+ return EXISTS$1 ? document$1.createElement(it) : {};
69
+ };
70
+
71
+ var DESCRIPTORS$6 = descriptors;
72
+ var fails$4 = fails$6;
73
+ var createElement = documentCreateElement;
74
+
75
+ // Thanks to IE8 for its funny defineProperty
76
+ var ie8DomDefine = !DESCRIPTORS$6 && !fails$4(function () {
77
+ // eslint-disable-next-line es/no-object-defineproperty -- required for testing
78
+ return Object.defineProperty(createElement('div'), 'a', {
79
+ get: function () { return 7; }
80
+ }).a !== 7;
81
+ });
82
+
83
+ var DESCRIPTORS$5 = descriptors;
84
+ var fails$3 = fails$6;
85
+
86
+ // V8 ~ Chrome 36-
87
+ // https://bugs.chromium.org/p/v8/issues/detail?id=3334
88
+ var v8PrototypeDefineBug = DESCRIPTORS$5 && fails$3(function () {
89
+ // eslint-disable-next-line es/no-object-defineproperty -- required for testing
90
+ return Object.defineProperty(function () { /* empty */ }, 'prototype', {
91
+ value: 42,
92
+ writable: false
93
+ }).prototype !== 42;
94
+ });
95
+
96
+ var isObject$3 = isObject$5;
97
+
98
+ var $String$4 = String;
99
+ var $TypeError$6 = TypeError;
100
+
101
+ // `Assert: Type(argument) is Object`
102
+ var anObject$1 = function (argument) {
103
+ if (isObject$3(argument)) return argument;
104
+ throw new $TypeError$6($String$4(argument) + ' is not an object');
105
+ };
106
+
107
+ var fails$2 = fails$6;
108
+
109
+ var functionBindNative = !fails$2(function () {
110
+ // eslint-disable-next-line es/no-function-prototype-bind -- safe
111
+ var test = (function () { /* empty */ }).bind();
112
+ // eslint-disable-next-line no-prototype-builtins -- safe
113
+ return typeof test != 'function' || test.hasOwnProperty('prototype');
114
+ });
115
+
116
+ var NATIVE_BIND$1 = functionBindNative;
117
+
118
+ var call$3 = Function.prototype.call;
119
+
120
+ var functionCall = NATIVE_BIND$1 ? call$3.bind(call$3) : function () {
121
+ return call$3.apply(call$3, arguments);
122
+ };
123
+
124
+ var global$7 = global$9;
125
+ var isCallable$8 = isCallable$a;
126
+
127
+ var aFunction = function (argument) {
128
+ return isCallable$8(argument) ? argument : undefined;
129
+ };
130
+
131
+ var getBuiltIn$1 = function (namespace, method) {
132
+ return arguments.length < 2 ? aFunction(global$7[namespace]) : global$7[namespace] && global$7[namespace][method];
133
+ };
134
+
135
+ var NATIVE_BIND = functionBindNative;
136
+
137
+ var FunctionPrototype$1 = Function.prototype;
138
+ var call$2 = FunctionPrototype$1.call;
139
+ var uncurryThisWithBind = NATIVE_BIND && FunctionPrototype$1.bind.bind(call$2, call$2);
140
+
141
+ var functionUncurryThis = NATIVE_BIND ? uncurryThisWithBind : function (fn) {
142
+ return function () {
143
+ return call$2.apply(fn, arguments);
144
+ };
145
+ };
146
+
147
+ var uncurryThis$8 = functionUncurryThis;
148
+
149
+ var objectIsPrototypeOf = uncurryThis$8({}.isPrototypeOf);
150
+
151
+ var engineUserAgent = typeof navigator != 'undefined' && String(navigator.userAgent) || '';
152
+
153
+ var global$6 = global$9;
154
+ var userAgent = engineUserAgent;
155
+
156
+ var process = global$6.process;
157
+ var Deno = global$6.Deno;
158
+ var versions = process && process.versions || Deno && Deno.version;
159
+ var v8 = versions && versions.v8;
160
+ var match, version;
161
+
162
+ if (v8) {
163
+ match = v8.split('.');
164
+ // in old Chrome, versions of V8 isn't V8 = Chrome / 10
165
+ // but their correct versions are not interesting for us
166
+ version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);
167
+ }
168
+
169
+ // BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`
170
+ // so check `userAgent` even if `.v8` exists, but 0
171
+ if (!version && userAgent) {
172
+ match = userAgent.match(/Edge\/(\d+)/);
173
+ if (!match || match[1] >= 74) {
174
+ match = userAgent.match(/Chrome\/(\d+)/);
175
+ if (match) version = +match[1];
176
+ }
177
+ }
178
+
179
+ var engineV8Version = version;
180
+
181
+ /* eslint-disable es/no-symbol -- required for testing */
182
+ var V8_VERSION = engineV8Version;
183
+ var fails$1 = fails$6;
184
+ var global$5 = global$9;
185
+
186
+ var $String$3 = global$5.String;
187
+
188
+ // eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
189
+ var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$1(function () {
190
+ var symbol = Symbol('symbol detection');
191
+ // Chrome 38 Symbol has incorrect toString conversion
192
+ // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
193
+ // nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will,
194
+ // of course, fail.
195
+ return !$String$3(symbol) || !(Object(symbol) instanceof Symbol) ||
196
+ // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
197
+ !Symbol.sham && V8_VERSION && V8_VERSION < 41;
198
+ });
199
+
200
+ /* eslint-disable es/no-symbol -- required for testing */
201
+ var NATIVE_SYMBOL$1 = symbolConstructorDetection;
202
+
203
+ var useSymbolAsUid = NATIVE_SYMBOL$1
204
+ && !Symbol.sham
205
+ && typeof Symbol.iterator == 'symbol';
206
+
207
+ var getBuiltIn = getBuiltIn$1;
208
+ var isCallable$7 = isCallable$a;
209
+ var isPrototypeOf = objectIsPrototypeOf;
210
+ var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
211
+
212
+ var $Object$2 = Object;
213
+
214
+ var isSymbol$2 = USE_SYMBOL_AS_UID$1 ? function (it) {
215
+ return typeof it == 'symbol';
216
+ } : function (it) {
217
+ var $Symbol = getBuiltIn('Symbol');
218
+ return isCallable$7($Symbol) && isPrototypeOf($Symbol.prototype, $Object$2(it));
219
+ };
220
+
221
+ var $String$2 = String;
222
+
223
+ var tryToString$1 = function (argument) {
224
+ try {
225
+ return $String$2(argument);
226
+ } catch (error) {
227
+ return 'Object';
228
+ }
229
+ };
230
+
231
+ var isCallable$6 = isCallable$a;
232
+ var tryToString = tryToString$1;
233
+
234
+ var $TypeError$5 = TypeError;
235
+
236
+ // `Assert: IsCallable(argument) is true`
237
+ var aCallable$1 = function (argument) {
238
+ if (isCallable$6(argument)) return argument;
239
+ throw new $TypeError$5(tryToString(argument) + ' is not a function');
240
+ };
241
+
242
+ // we can't use just `it == null` since of `document.all` special case
243
+ // https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
244
+ var isNullOrUndefined$2 = function (it) {
245
+ return it === null || it === undefined;
246
+ };
247
+
248
+ var aCallable = aCallable$1;
249
+ var isNullOrUndefined$1 = isNullOrUndefined$2;
250
+
251
+ // `GetMethod` abstract operation
252
+ // https://tc39.es/ecma262/#sec-getmethod
253
+ var getMethod$1 = function (V, P) {
254
+ var func = V[P];
255
+ return isNullOrUndefined$1(func) ? undefined : aCallable(func);
256
+ };
257
+
258
+ var call$1 = functionCall;
259
+ var isCallable$5 = isCallable$a;
260
+ var isObject$2 = isObject$5;
261
+
262
+ var $TypeError$4 = TypeError;
263
+
264
+ // `OrdinaryToPrimitive` abstract operation
265
+ // https://tc39.es/ecma262/#sec-ordinarytoprimitive
266
+ var ordinaryToPrimitive$1 = function (input, pref) {
267
+ var fn, val;
268
+ if (pref === 'string' && isCallable$5(fn = input.toString) && !isObject$2(val = call$1(fn, input))) return val;
269
+ if (isCallable$5(fn = input.valueOf) && !isObject$2(val = call$1(fn, input))) return val;
270
+ if (pref !== 'string' && isCallable$5(fn = input.toString) && !isObject$2(val = call$1(fn, input))) return val;
271
+ throw new $TypeError$4("Can't convert object to primitive value");
272
+ };
273
+
274
+ var sharedStore = {exports: {}};
275
+
276
+ var global$4 = global$9;
277
+
278
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
279
+ var defineProperty$2 = Object.defineProperty;
280
+
281
+ var defineGlobalProperty$2 = function (key, value) {
282
+ try {
283
+ defineProperty$2(global$4, key, { value: value, configurable: true, writable: true });
284
+ } catch (error) {
285
+ global$4[key] = value;
286
+ } return value;
287
+ };
288
+
289
+ var globalThis$1 = global$9;
290
+ var defineGlobalProperty$1 = defineGlobalProperty$2;
291
+
292
+ var SHARED = '__core-js_shared__';
293
+ var store$3 = sharedStore.exports = globalThis$1[SHARED] || defineGlobalProperty$1(SHARED, {});
294
+
295
+ (store$3.versions || (store$3.versions = [])).push({
296
+ version: '3.36.1',
297
+ mode: 'global',
298
+ copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',
299
+ license: 'https://github.com/zloirock/core-js/blob/v3.36.1/LICENSE',
300
+ source: 'https://github.com/zloirock/core-js'
301
+ });
302
+
303
+ var sharedStoreExports = sharedStore.exports;
304
+
305
+ var store$2 = sharedStoreExports;
306
+
307
+ var shared$3 = function (key, value) {
308
+ return store$2[key] || (store$2[key] = value || {});
309
+ };
310
+
311
+ var isNullOrUndefined = isNullOrUndefined$2;
312
+
313
+ var $TypeError$3 = TypeError;
314
+
315
+ // `RequireObjectCoercible` abstract operation
316
+ // https://tc39.es/ecma262/#sec-requireobjectcoercible
317
+ var requireObjectCoercible$1 = function (it) {
318
+ if (isNullOrUndefined(it)) throw new $TypeError$3("Can't call method on " + it);
319
+ return it;
320
+ };
321
+
322
+ var requireObjectCoercible = requireObjectCoercible$1;
323
+
324
+ var $Object$1 = Object;
325
+
326
+ // `ToObject` abstract operation
327
+ // https://tc39.es/ecma262/#sec-toobject
328
+ var toObject$1 = function (argument) {
329
+ return $Object$1(requireObjectCoercible(argument));
330
+ };
331
+
332
+ var uncurryThis$7 = functionUncurryThis;
333
+ var toObject = toObject$1;
334
+
335
+ var hasOwnProperty = uncurryThis$7({}.hasOwnProperty);
336
+
337
+ // `HasOwnProperty` abstract operation
338
+ // https://tc39.es/ecma262/#sec-hasownproperty
339
+ // eslint-disable-next-line es/no-object-hasown -- safe
340
+ var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
341
+ return hasOwnProperty(toObject(it), key);
342
+ };
343
+
344
+ var uncurryThis$6 = functionUncurryThis;
345
+
346
+ var id = 0;
347
+ var postfix = Math.random();
348
+ var toString$4 = uncurryThis$6(1.0.toString);
349
+
350
+ var uid$2 = function (key) {
351
+ return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$4(++id + postfix, 36);
352
+ };
353
+
354
+ var global$3 = global$9;
355
+ var shared$2 = shared$3;
356
+ var hasOwn$3 = hasOwnProperty_1;
357
+ var uid$1 = uid$2;
358
+ var NATIVE_SYMBOL = symbolConstructorDetection;
359
+ var USE_SYMBOL_AS_UID = useSymbolAsUid;
360
+
361
+ var Symbol$1 = global$3.Symbol;
362
+ var WellKnownSymbolsStore = shared$2('wks');
363
+ var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol$1['for'] || Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid$1;
364
+
365
+ var wellKnownSymbol$3 = function (name) {
366
+ if (!hasOwn$3(WellKnownSymbolsStore, name)) {
367
+ WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn$3(Symbol$1, name)
368
+ ? Symbol$1[name]
369
+ : createWellKnownSymbol('Symbol.' + name);
370
+ } return WellKnownSymbolsStore[name];
371
+ };
372
+
373
+ var call = functionCall;
374
+ var isObject$1 = isObject$5;
375
+ var isSymbol$1 = isSymbol$2;
376
+ var getMethod = getMethod$1;
377
+ var ordinaryToPrimitive = ordinaryToPrimitive$1;
378
+ var wellKnownSymbol$2 = wellKnownSymbol$3;
379
+
380
+ var $TypeError$2 = TypeError;
381
+ var TO_PRIMITIVE = wellKnownSymbol$2('toPrimitive');
382
+
383
+ // `ToPrimitive` abstract operation
384
+ // https://tc39.es/ecma262/#sec-toprimitive
385
+ var toPrimitive$1 = function (input, pref) {
386
+ if (!isObject$1(input) || isSymbol$1(input)) return input;
387
+ var exoticToPrim = getMethod(input, TO_PRIMITIVE);
388
+ var result;
389
+ if (exoticToPrim) {
390
+ if (pref === undefined) pref = 'default';
391
+ result = call(exoticToPrim, input, pref);
392
+ if (!isObject$1(result) || isSymbol$1(result)) return result;
393
+ throw new $TypeError$2("Can't convert object to primitive value");
394
+ }
395
+ if (pref === undefined) pref = 'number';
396
+ return ordinaryToPrimitive(input, pref);
397
+ };
398
+
399
+ var toPrimitive = toPrimitive$1;
400
+ var isSymbol = isSymbol$2;
401
+
402
+ // `ToPropertyKey` abstract operation
403
+ // https://tc39.es/ecma262/#sec-topropertykey
404
+ var toPropertyKey$1 = function (argument) {
405
+ var key = toPrimitive(argument, 'string');
406
+ return isSymbol(key) ? key : key + '';
407
+ };
408
+
409
+ var DESCRIPTORS$4 = descriptors;
410
+ var IE8_DOM_DEFINE = ie8DomDefine;
411
+ var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
412
+ var anObject = anObject$1;
413
+ var toPropertyKey = toPropertyKey$1;
414
+
415
+ var $TypeError$1 = TypeError;
416
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
417
+ var $defineProperty = Object.defineProperty;
418
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
419
+ var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
420
+ var ENUMERABLE = 'enumerable';
421
+ var CONFIGURABLE$1 = 'configurable';
422
+ var WRITABLE = 'writable';
423
+
424
+ // `Object.defineProperty` method
425
+ // https://tc39.es/ecma262/#sec-object.defineproperty
426
+ objectDefineProperty.f = DESCRIPTORS$4 ? V8_PROTOTYPE_DEFINE_BUG ? function defineProperty(O, P, Attributes) {
427
+ anObject(O);
428
+ P = toPropertyKey(P);
429
+ anObject(Attributes);
430
+ if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {
431
+ var current = $getOwnPropertyDescriptor(O, P);
432
+ if (current && current[WRITABLE]) {
433
+ O[P] = Attributes.value;
434
+ Attributes = {
435
+ configurable: CONFIGURABLE$1 in Attributes ? Attributes[CONFIGURABLE$1] : current[CONFIGURABLE$1],
436
+ enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE],
437
+ writable: false
438
+ };
439
+ }
440
+ } return $defineProperty(O, P, Attributes);
441
+ } : $defineProperty : function defineProperty(O, P, Attributes) {
442
+ anObject(O);
443
+ P = toPropertyKey(P);
444
+ anObject(Attributes);
445
+ if (IE8_DOM_DEFINE) try {
446
+ return $defineProperty(O, P, Attributes);
447
+ } catch (error) { /* empty */ }
448
+ if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$1('Accessors not supported');
449
+ if ('value' in Attributes) O[P] = Attributes.value;
450
+ return O;
451
+ };
452
+
453
+ var makeBuiltIn$3 = {exports: {}};
454
+
455
+ var DESCRIPTORS$3 = descriptors;
456
+ var hasOwn$2 = hasOwnProperty_1;
457
+
458
+ var FunctionPrototype = Function.prototype;
459
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
460
+ var getDescriptor = DESCRIPTORS$3 && Object.getOwnPropertyDescriptor;
461
+
462
+ var EXISTS = hasOwn$2(FunctionPrototype, 'name');
463
+ // additional protection from minified / mangled / dropped function names
464
+ var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
465
+ var CONFIGURABLE = EXISTS && (!DESCRIPTORS$3 || (DESCRIPTORS$3 && getDescriptor(FunctionPrototype, 'name').configurable));
466
+
467
+ var functionName = {
468
+ EXISTS: EXISTS,
469
+ PROPER: PROPER,
470
+ CONFIGURABLE: CONFIGURABLE
471
+ };
472
+
473
+ var uncurryThis$5 = functionUncurryThis;
474
+ var isCallable$4 = isCallable$a;
475
+ var store$1 = sharedStoreExports;
476
+
477
+ var functionToString = uncurryThis$5(Function.toString);
478
+
479
+ // this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
480
+ if (!isCallable$4(store$1.inspectSource)) {
481
+ store$1.inspectSource = function (it) {
482
+ return functionToString(it);
483
+ };
484
+ }
485
+
486
+ var inspectSource$1 = store$1.inspectSource;
487
+
488
+ var global$2 = global$9;
489
+ var isCallable$3 = isCallable$a;
490
+
491
+ var WeakMap$1 = global$2.WeakMap;
492
+
493
+ var weakMapBasicDetection = isCallable$3(WeakMap$1) && /native code/.test(String(WeakMap$1));
494
+
495
+ var createPropertyDescriptor$1 = function (bitmap, value) {
496
+ return {
497
+ enumerable: !(bitmap & 1),
498
+ configurable: !(bitmap & 2),
499
+ writable: !(bitmap & 4),
500
+ value: value
501
+ };
502
+ };
503
+
504
+ var DESCRIPTORS$2 = descriptors;
505
+ var definePropertyModule$1 = objectDefineProperty;
506
+ var createPropertyDescriptor = createPropertyDescriptor$1;
507
+
508
+ var createNonEnumerableProperty$1 = DESCRIPTORS$2 ? function (object, key, value) {
509
+ return definePropertyModule$1.f(object, key, createPropertyDescriptor(1, value));
510
+ } : function (object, key, value) {
511
+ object[key] = value;
512
+ return object;
513
+ };
514
+
515
+ var shared$1 = shared$3;
516
+ var uid = uid$2;
517
+
518
+ var keys = shared$1('keys');
519
+
520
+ var sharedKey$1 = function (key) {
521
+ return keys[key] || (keys[key] = uid(key));
522
+ };
523
+
524
+ var NATIVE_WEAK_MAP = weakMapBasicDetection;
525
+ var global$1 = global$9;
526
+ var isObject = isObject$5;
527
+ var createNonEnumerableProperty = createNonEnumerableProperty$1;
528
+ var hasOwn$1 = hasOwnProperty_1;
529
+ var shared = sharedStoreExports;
530
+ var sharedKey = sharedKey$1;
531
+
532
+ var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
533
+ var TypeError$1 = global$1.TypeError;
534
+ var WeakMap = global$1.WeakMap;
535
+ var set, get, has;
536
+
537
+ var enforce = function (it) {
538
+ return has(it) ? get(it) : set(it, {});
539
+ };
540
+
541
+ var getterFor = function (TYPE) {
542
+ return function (it) {
543
+ var state;
544
+ if (!isObject(it) || (state = get(it)).type !== TYPE) {
545
+ throw new TypeError$1('Incompatible receiver, ' + TYPE + ' required');
546
+ } return state;
547
+ };
548
+ };
549
+
550
+ if (NATIVE_WEAK_MAP || shared.state) {
551
+ var store = shared.state || (shared.state = new WeakMap());
552
+ /* eslint-disable no-self-assign -- prototype methods protection */
553
+ store.get = store.get;
554
+ store.has = store.has;
555
+ store.set = store.set;
556
+ /* eslint-enable no-self-assign -- prototype methods protection */
557
+ set = function (it, metadata) {
558
+ if (store.has(it)) throw new TypeError$1(OBJECT_ALREADY_INITIALIZED);
559
+ metadata.facade = it;
560
+ store.set(it, metadata);
561
+ return metadata;
562
+ };
563
+ get = function (it) {
564
+ return store.get(it) || {};
565
+ };
566
+ has = function (it) {
567
+ return store.has(it);
568
+ };
569
+ } else {
570
+ var STATE = sharedKey('state');
571
+ set = function (it, metadata) {
572
+ if (hasOwn$1(it, STATE)) throw new TypeError$1(OBJECT_ALREADY_INITIALIZED);
573
+ metadata.facade = it;
574
+ createNonEnumerableProperty(it, STATE, metadata);
575
+ return metadata;
576
+ };
577
+ get = function (it) {
578
+ return hasOwn$1(it, STATE) ? it[STATE] : {};
579
+ };
580
+ has = function (it) {
581
+ return hasOwn$1(it, STATE);
582
+ };
583
+ }
584
+
585
+ var internalState = {
586
+ set: set,
587
+ get: get,
588
+ has: has,
589
+ enforce: enforce,
590
+ getterFor: getterFor
591
+ };
592
+
593
+ var uncurryThis$4 = functionUncurryThis;
594
+ var fails = fails$6;
595
+ var isCallable$2 = isCallable$a;
596
+ var hasOwn = hasOwnProperty_1;
597
+ var DESCRIPTORS$1 = descriptors;
598
+ var CONFIGURABLE_FUNCTION_NAME = functionName.CONFIGURABLE;
599
+ var inspectSource = inspectSource$1;
600
+ var InternalStateModule = internalState;
601
+
602
+ var enforceInternalState = InternalStateModule.enforce;
603
+ var getInternalState = InternalStateModule.get;
604
+ var $String$1 = String;
605
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
606
+ var defineProperty$1 = Object.defineProperty;
607
+ var stringSlice$1 = uncurryThis$4(''.slice);
608
+ var replace = uncurryThis$4(''.replace);
609
+ var join = uncurryThis$4([].join);
610
+
611
+ var CONFIGURABLE_LENGTH = DESCRIPTORS$1 && !fails(function () {
612
+ return defineProperty$1(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
613
+ });
614
+
615
+ var TEMPLATE = String(String).split('String');
616
+
617
+ var makeBuiltIn$2 = makeBuiltIn$3.exports = function (value, name, options) {
618
+ if (stringSlice$1($String$1(name), 0, 7) === 'Symbol(') {
619
+ name = '[' + replace($String$1(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
620
+ }
621
+ if (options && options.getter) name = 'get ' + name;
622
+ if (options && options.setter) name = 'set ' + name;
623
+ if (!hasOwn(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {
624
+ if (DESCRIPTORS$1) defineProperty$1(value, 'name', { value: name, configurable: true });
625
+ else value.name = name;
626
+ }
627
+ if (CONFIGURABLE_LENGTH && options && hasOwn(options, 'arity') && value.length !== options.arity) {
628
+ defineProperty$1(value, 'length', { value: options.arity });
629
+ }
630
+ try {
631
+ if (options && hasOwn(options, 'constructor') && options.constructor) {
632
+ if (DESCRIPTORS$1) defineProperty$1(value, 'prototype', { writable: false });
633
+ // in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable
634
+ } else if (value.prototype) value.prototype = undefined;
635
+ } catch (error) { /* empty */ }
636
+ var state = enforceInternalState(value);
637
+ if (!hasOwn(state, 'source')) {
638
+ state.source = join(TEMPLATE, typeof name == 'string' ? name : '');
639
+ } return value;
640
+ };
641
+
642
+ // add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
643
+ // eslint-disable-next-line no-extend-native -- required
644
+ Function.prototype.toString = makeBuiltIn$2(function toString() {
645
+ return isCallable$2(this) && getInternalState(this).source || inspectSource(this);
646
+ }, 'toString');
647
+
648
+ var makeBuiltInExports = makeBuiltIn$3.exports;
649
+
650
+ var isCallable$1 = isCallable$a;
651
+ var definePropertyModule = objectDefineProperty;
652
+ var makeBuiltIn$1 = makeBuiltInExports;
653
+ var defineGlobalProperty = defineGlobalProperty$2;
654
+
655
+ var defineBuiltIn$2 = function (O, key, value, options) {
656
+ if (!options) options = {};
657
+ var simple = options.enumerable;
658
+ var name = options.name !== undefined ? options.name : key;
659
+ if (isCallable$1(value)) makeBuiltIn$1(value, name, options);
660
+ if (options.global) {
661
+ if (simple) O[key] = value;
662
+ else defineGlobalProperty(key, value);
663
+ } else {
664
+ try {
665
+ if (!options.unsafe) delete O[key];
666
+ else if (O[key]) simple = true;
667
+ } catch (error) { /* empty */ }
668
+ if (simple) O[key] = value;
669
+ else definePropertyModule.f(O, key, {
670
+ value: value,
671
+ enumerable: false,
672
+ configurable: !options.nonConfigurable,
673
+ writable: !options.nonWritable
674
+ });
675
+ } return O;
676
+ };
677
+
678
+ var wellKnownSymbol$1 = wellKnownSymbol$3;
679
+
680
+ var TO_STRING_TAG$1 = wellKnownSymbol$1('toStringTag');
681
+ var test = {};
682
+
683
+ test[TO_STRING_TAG$1] = 'z';
684
+
685
+ var toStringTagSupport = String(test) === '[object z]';
686
+
687
+ var uncurryThis$3 = functionUncurryThis;
688
+
689
+ var toString$3 = uncurryThis$3({}.toString);
690
+ var stringSlice = uncurryThis$3(''.slice);
691
+
692
+ var classofRaw$1 = function (it) {
693
+ return stringSlice(toString$3(it), 8, -1);
694
+ };
695
+
696
+ var TO_STRING_TAG_SUPPORT = toStringTagSupport;
697
+ var isCallable = isCallable$a;
698
+ var classofRaw = classofRaw$1;
699
+ var wellKnownSymbol = wellKnownSymbol$3;
700
+
701
+ var TO_STRING_TAG = wellKnownSymbol('toStringTag');
702
+ var $Object = Object;
703
+
704
+ // ES3 wrong here
705
+ var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) === 'Arguments';
706
+
707
+ // fallback for IE11 Script Access Denied error
708
+ var tryGet = function (it, key) {
709
+ try {
710
+ return it[key];
711
+ } catch (error) { /* empty */ }
712
+ };
713
+
714
+ // getting tag from ES6+ `Object.prototype.toString`
715
+ var classof$1 = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {
716
+ var O, tag, result;
717
+ return it === undefined ? 'Undefined' : it === null ? 'Null'
718
+ // @@toStringTag case
719
+ : typeof (tag = tryGet(O = $Object(it), TO_STRING_TAG)) == 'string' ? tag
720
+ // builtinTag case
721
+ : CORRECT_ARGUMENTS ? classofRaw(O)
722
+ // ES3 arguments fallback
723
+ : (result = classofRaw(O)) === 'Object' && isCallable(O.callee) ? 'Arguments' : result;
724
+ };
725
+
726
+ var classof = classof$1;
727
+
728
+ var $String = String;
729
+
730
+ var toString$2 = function (argument) {
731
+ if (classof(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');
732
+ return $String(argument);
733
+ };
734
+
735
+ var $TypeError = TypeError;
736
+
737
+ var validateArgumentsLength$2 = function (passed, required) {
738
+ if (passed < required) throw new $TypeError('Not enough arguments');
739
+ return passed;
740
+ };
741
+
742
+ var defineBuiltIn$1 = defineBuiltIn$2;
743
+ var uncurryThis$2 = functionUncurryThis;
744
+ var toString$1 = toString$2;
745
+ var validateArgumentsLength$1 = validateArgumentsLength$2;
746
+
747
+ var $URLSearchParams$1 = URLSearchParams;
748
+ var URLSearchParamsPrototype$2 = $URLSearchParams$1.prototype;
749
+ var append = uncurryThis$2(URLSearchParamsPrototype$2.append);
750
+ var $delete = uncurryThis$2(URLSearchParamsPrototype$2['delete']);
751
+ var forEach$1 = uncurryThis$2(URLSearchParamsPrototype$2.forEach);
752
+ var push = uncurryThis$2([].push);
753
+ var params$1 = new $URLSearchParams$1('a=1&a=2&b=3');
754
+
755
+ params$1['delete']('a', 1);
756
+ // `undefined` case is a Chromium 117 bug
757
+ // https://bugs.chromium.org/p/v8/issues/detail?id=14222
758
+ params$1['delete']('b', undefined);
759
+
760
+ if (params$1 + '' !== 'a=2') {
761
+ defineBuiltIn$1(URLSearchParamsPrototype$2, 'delete', function (name /* , value */) {
762
+ var length = arguments.length;
763
+ var $value = length < 2 ? undefined : arguments[1];
764
+ if (length && $value === undefined) return $delete(this, name);
765
+ var entries = [];
766
+ forEach$1(this, function (v, k) { // also validates `this`
767
+ push(entries, { key: k, value: v });
768
+ });
769
+ validateArgumentsLength$1(length, 1);
770
+ var key = toString$1(name);
771
+ var value = toString$1($value);
772
+ var index = 0;
773
+ var dindex = 0;
774
+ var found = false;
775
+ var entriesLength = entries.length;
776
+ var entry;
777
+ while (index < entriesLength) {
778
+ entry = entries[index++];
779
+ if (found || entry.key === key) {
780
+ found = true;
781
+ $delete(this, entry.key);
782
+ } else dindex++;
783
+ }
784
+ while (dindex < entriesLength) {
785
+ entry = entries[dindex++];
786
+ if (!(entry.key === key && entry.value === value)) append(this, entry.key, entry.value);
787
+ }
788
+ }, { enumerable: true, unsafe: true });
789
+ }
790
+
791
+ var defineBuiltIn = defineBuiltIn$2;
792
+ var uncurryThis$1 = functionUncurryThis;
793
+ var toString = toString$2;
794
+ var validateArgumentsLength = validateArgumentsLength$2;
795
+
796
+ var $URLSearchParams = URLSearchParams;
797
+ var URLSearchParamsPrototype$1 = $URLSearchParams.prototype;
798
+ var getAll = uncurryThis$1(URLSearchParamsPrototype$1.getAll);
799
+ var $has = uncurryThis$1(URLSearchParamsPrototype$1.has);
800
+ var params = new $URLSearchParams('a=1');
801
+
802
+ // `undefined` case is a Chromium 117 bug
803
+ // https://bugs.chromium.org/p/v8/issues/detail?id=14222
804
+ if (params.has('a', 2) || !params.has('a', undefined)) {
805
+ defineBuiltIn(URLSearchParamsPrototype$1, 'has', function has(name /* , value */) {
806
+ var length = arguments.length;
807
+ var $value = length < 2 ? undefined : arguments[1];
808
+ if (length && $value === undefined) return $has(this, name);
809
+ var values = getAll(this, name); // also validates `this`
810
+ validateArgumentsLength(length, 1);
811
+ var value = toString($value);
812
+ var index = 0;
813
+ while (index < values.length) {
814
+ if (values[index++] === value) return true;
815
+ } return false;
816
+ }, { enumerable: true, unsafe: true });
817
+ }
818
+
819
+ var makeBuiltIn = makeBuiltInExports;
820
+ var defineProperty = objectDefineProperty;
821
+
822
+ var defineBuiltInAccessor$1 = function (target, name, descriptor) {
823
+ if (descriptor.get) makeBuiltIn(descriptor.get, name, { getter: true });
824
+ if (descriptor.set) makeBuiltIn(descriptor.set, name, { setter: true });
825
+ return defineProperty.f(target, name, descriptor);
826
+ };
827
+
828
+ var DESCRIPTORS = descriptors;
829
+ var uncurryThis = functionUncurryThis;
830
+ var defineBuiltInAccessor = defineBuiltInAccessor$1;
831
+
832
+ var URLSearchParamsPrototype = URLSearchParams.prototype;
833
+ var forEach = uncurryThis(URLSearchParamsPrototype.forEach);
834
+
835
+ // `URLSearchParams.prototype.size` getter
836
+ // https://github.com/whatwg/url/pull/734
837
+ if (DESCRIPTORS && !('size' in URLSearchParamsPrototype)) {
838
+ defineBuiltInAccessor(URLSearchParamsPrototype, 'size', {
839
+ get: function size() {
840
+ var count = 0;
841
+ forEach(this, function () { count++; });
842
+ return count;
843
+ },
844
+ configurable: true,
845
+ enumerable: true
846
+ });
847
+ }
848
+
849
+ /**
850
+ * Creatse a new BrowserObjectURLRef.
851
+ */
852
+ function browserObjectUrlRef() {
853
+ let browserUrl;
854
+ /**
855
+ * Revokes the existing browser object URL, if one exists.
856
+ */
857
+ function destroy() {
858
+ if (browserUrl) {
859
+ URL.revokeObjectURL(browserUrl);
860
+ }
861
+ }
862
+ function createBrowserUrl(input) {
863
+ destroy();
864
+ if (input) {
865
+ browserUrl = URL.createObjectURL(input);
866
+ }
867
+ return browserUrl;
868
+ }
869
+ return {
870
+ destroy,
871
+ getBrowserUrl: () => browserUrl,
872
+ createBrowserUrl: createBrowserUrl
873
+ };
874
+ }
875
+
6
876
  /**
7
877
  * Used for loading services in the browser that are imported from other scripts, such as Facebook, Segment, Stripe, etc.
8
878
  */
@@ -138,6 +1008,7 @@ function getWindowPathNameWithQuery() {
138
1008
 
139
1009
  exports.AbstractAsyncWindowLoadedService = AbstractAsyncWindowLoadedService;
140
1010
  exports.DEFAULT_VH100_VARIABLE_NAME = DEFAULT_VH100_VARIABLE_NAME;
1011
+ exports.browserObjectUrlRef = browserObjectUrlRef;
141
1012
  exports.getBaseWindowUrl = getBaseWindowUrl;
142
1013
  exports.getWindowPathNameWithQuery = getWindowPathNameWithQuery;
143
1014
  exports.isLocalhost = isLocalhost;