@dereekb/rxjs 11.1.7 → 12.0.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
@@ -1,13 +1,11 @@
1
1
  'use strict';
2
2
 
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
3
  var rxjs = require('rxjs');
6
4
  var util = require('@dereekb/util');
7
5
 
8
6
  var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
9
7
 
10
- var fails$d = function (exec) {
8
+ var fails$g = function (exec) {
11
9
  try {
12
10
  return !!exec();
13
11
  } catch (error) {
@@ -15,9 +13,9 @@ var fails$d = function (exec) {
15
13
  }
16
14
  };
17
15
 
18
- var fails$c = fails$d;
16
+ var fails$f = fails$g;
19
17
 
20
- var functionBindNative = !fails$c(function () {
18
+ var functionBindNative = !fails$f(function () {
21
19
  // eslint-disable-next-line es/no-function-prototype-bind -- safe
22
20
  var test = (function () { /* empty */ }).bind();
23
21
  // eslint-disable-next-line no-prototype-builtins -- safe
@@ -27,38 +25,38 @@ var functionBindNative = !fails$c(function () {
27
25
  var NATIVE_BIND$3 = functionBindNative;
28
26
 
29
27
  var FunctionPrototype$2 = Function.prototype;
30
- var call$d = FunctionPrototype$2.call;
31
- var uncurryThisWithBind = NATIVE_BIND$3 && FunctionPrototype$2.bind.bind(call$d, call$d);
28
+ var call$g = FunctionPrototype$2.call;
29
+ var uncurryThisWithBind = NATIVE_BIND$3 && FunctionPrototype$2.bind.bind(call$g, call$g);
32
30
 
33
31
  var functionUncurryThis = NATIVE_BIND$3 ? uncurryThisWithBind : function (fn) {
34
32
  return function () {
35
- return call$d.apply(fn, arguments);
33
+ return call$g.apply(fn, arguments);
36
34
  };
37
35
  };
38
36
 
39
- var uncurryThis$e = functionUncurryThis;
37
+ var uncurryThis$f = functionUncurryThis;
40
38
 
41
- var toString$1 = uncurryThis$e({}.toString);
42
- var stringSlice$1 = uncurryThis$e(''.slice);
39
+ var toString$3 = uncurryThis$f({}.toString);
40
+ var stringSlice$1 = uncurryThis$f(''.slice);
43
41
 
44
42
  var classofRaw$2 = function (it) {
45
- return stringSlice$1(toString$1(it), 8, -1);
43
+ return stringSlice$1(toString$3(it), 8, -1);
46
44
  };
47
45
 
48
- var uncurryThis$d = functionUncurryThis;
49
- var fails$b = fails$d;
50
- var classof$4 = classofRaw$2;
46
+ var uncurryThis$e = functionUncurryThis;
47
+ var fails$e = fails$g;
48
+ var classof$6 = classofRaw$2;
51
49
 
52
50
  var $Object$4 = Object;
53
- var split = uncurryThis$d(''.split);
51
+ var split = uncurryThis$e(''.split);
54
52
 
55
53
  // fallback for non-array-like ES3 and non-enumerable old V8 strings
56
- var indexedObject = fails$b(function () {
54
+ var indexedObject = fails$e(function () {
57
55
  // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
58
56
  // eslint-disable-next-line no-prototype-builtins -- safe
59
57
  return !$Object$4('z').propertyIsEnumerable(0);
60
58
  }) ? function (it) {
61
- return classof$4(it) === 'String' ? split(it, '') : $Object$4(it);
59
+ return classof$6(it) === 'String' ? split(it, '') : $Object$4(it);
62
60
  } : $Object$4;
63
61
 
64
62
  // we can't use just `it == null` since of `document.all` special case
@@ -69,21 +67,21 @@ var isNullOrUndefined$4 = function (it) {
69
67
 
70
68
  var isNullOrUndefined$3 = isNullOrUndefined$4;
71
69
 
72
- var $TypeError$c = TypeError;
70
+ var $TypeError$f = TypeError;
73
71
 
74
72
  // `RequireObjectCoercible` abstract operation
75
73
  // https://tc39.es/ecma262/#sec-requireobjectcoercible
76
- var requireObjectCoercible$2 = function (it) {
77
- if (isNullOrUndefined$3(it)) throw new $TypeError$c("Can't call method on " + it);
74
+ var requireObjectCoercible$3 = function (it) {
75
+ if (isNullOrUndefined$3(it)) throw new $TypeError$f("Can't call method on " + it);
78
76
  return it;
79
77
  };
80
78
 
81
79
  // toObject with fallback for non-array-like ES3 strings
82
80
  var IndexedObject$1 = indexedObject;
83
- var requireObjectCoercible$1 = requireObjectCoercible$2;
81
+ var requireObjectCoercible$2 = requireObjectCoercible$3;
84
82
 
85
83
  var toIndexedObject$5 = function (it) {
86
- return IndexedObject$1(requireObjectCoercible$1(it));
84
+ return IndexedObject$1(requireObjectCoercible$2(it));
87
85
  };
88
86
 
89
87
  var check = function (it) {
@@ -91,7 +89,7 @@ var check = function (it) {
91
89
  };
92
90
 
93
91
  // https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
94
- var global$j =
92
+ var global$k =
95
93
  // eslint-disable-next-line es/no-global-this -- safe
96
94
  check(typeof globalThis == 'object' && globalThis) ||
97
95
  check(typeof window == 'object' && window) ||
@@ -102,80 +100,84 @@ var global$j =
102
100
  // eslint-disable-next-line no-new-func -- fallback
103
101
  (function () { return this; })() || Function('return this')();
104
102
 
105
- var shared$3 = {exports: {}};
103
+ var sharedStore = {exports: {}};
104
+
105
+ var isPure = false;
106
106
 
107
- var global$i = global$j;
107
+ var global$j = global$k;
108
108
 
109
109
  // eslint-disable-next-line es/no-object-defineproperty -- safe
110
- var defineProperty$6 = Object.defineProperty;
110
+ var defineProperty$7 = Object.defineProperty;
111
111
 
112
112
  var defineGlobalProperty$3 = function (key, value) {
113
113
  try {
114
- defineProperty$6(global$i, key, { value: value, configurable: true, writable: true });
114
+ defineProperty$7(global$j, key, { value: value, configurable: true, writable: true });
115
115
  } catch (error) {
116
- global$i[key] = value;
116
+ global$j[key] = value;
117
117
  } return value;
118
118
  };
119
119
 
120
- var global$h = global$j;
120
+ var globalThis$1 = global$k;
121
121
  var defineGlobalProperty$2 = defineGlobalProperty$3;
122
122
 
123
123
  var SHARED = '__core-js_shared__';
124
- var store$3 = global$h[SHARED] || defineGlobalProperty$2(SHARED, {});
125
-
126
- var sharedStore = store$3;
127
-
128
- var store$2 = sharedStore;
124
+ var store$3 = sharedStore.exports = globalThis$1[SHARED] || defineGlobalProperty$2(SHARED, {});
129
125
 
130
- (shared$3.exports = function (key, value) {
131
- return store$2[key] || (store$2[key] = value !== undefined ? value : {});
132
- })('versions', []).push({
133
- version: '3.35.1',
126
+ (store$3.versions || (store$3.versions = [])).push({
127
+ version: '3.36.1',
134
128
  mode: 'global',
135
129
  copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',
136
- license: 'https://github.com/zloirock/core-js/blob/v3.35.1/LICENSE',
130
+ license: 'https://github.com/zloirock/core-js/blob/v3.36.1/LICENSE',
137
131
  source: 'https://github.com/zloirock/core-js'
138
132
  });
139
133
 
140
- var requireObjectCoercible = requireObjectCoercible$2;
134
+ var sharedStoreExports = sharedStore.exports;
135
+
136
+ var store$2 = sharedStoreExports;
137
+
138
+ var shared$3 = function (key, value) {
139
+ return store$2[key] || (store$2[key] = value || {});
140
+ };
141
+
142
+ var requireObjectCoercible$1 = requireObjectCoercible$3;
141
143
 
142
144
  var $Object$3 = Object;
143
145
 
144
146
  // `ToObject` abstract operation
145
147
  // https://tc39.es/ecma262/#sec-toobject
146
- var toObject$3 = function (argument) {
147
- return $Object$3(requireObjectCoercible(argument));
148
+ var toObject$4 = function (argument) {
149
+ return $Object$3(requireObjectCoercible$1(argument));
148
150
  };
149
151
 
150
- var uncurryThis$c = functionUncurryThis;
151
- var toObject$2 = toObject$3;
152
+ var uncurryThis$d = functionUncurryThis;
153
+ var toObject$3 = toObject$4;
152
154
 
153
- var hasOwnProperty = uncurryThis$c({}.hasOwnProperty);
155
+ var hasOwnProperty = uncurryThis$d({}.hasOwnProperty);
154
156
 
155
157
  // `HasOwnProperty` abstract operation
156
158
  // https://tc39.es/ecma262/#sec-hasownproperty
157
159
  // eslint-disable-next-line es/no-object-hasown -- safe
158
160
  var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
159
- return hasOwnProperty(toObject$2(it), key);
161
+ return hasOwnProperty(toObject$3(it), key);
160
162
  };
161
163
 
162
- var uncurryThis$b = functionUncurryThis;
164
+ var uncurryThis$c = functionUncurryThis;
163
165
 
164
166
  var id = 0;
165
167
  var postfix = Math.random();
166
- var toString = uncurryThis$b(1.0.toString);
168
+ var toString$2 = uncurryThis$c(1.0.toString);
167
169
 
168
170
  var uid$2 = function (key) {
169
- return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);
171
+ return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$2(++id + postfix, 36);
170
172
  };
171
173
 
172
174
  var engineUserAgent = typeof navigator != 'undefined' && String(navigator.userAgent) || '';
173
175
 
174
- var global$g = global$j;
176
+ var global$i = global$k;
175
177
  var userAgent$3 = engineUserAgent;
176
178
 
177
- var process$3 = global$g.process;
178
- var Deno$1 = global$g.Deno;
179
+ var process$3 = global$i.process;
180
+ var Deno$1 = global$i.Deno;
179
181
  var versions = process$3 && process$3.versions || Deno$1 && Deno$1.version;
180
182
  var v8 = versions && versions.v8;
181
183
  var match, version;
@@ -201,19 +203,19 @@ var engineV8Version = version;
201
203
 
202
204
  /* eslint-disable es/no-symbol -- required for testing */
203
205
  var V8_VERSION$1 = engineV8Version;
204
- var fails$a = fails$d;
205
- var global$f = global$j;
206
+ var fails$d = fails$g;
207
+ var global$h = global$k;
206
208
 
207
- var $String$4 = global$f.String;
209
+ var $String$5 = global$h.String;
208
210
 
209
211
  // eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
210
- var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$a(function () {
212
+ var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$d(function () {
211
213
  var symbol = Symbol('symbol detection');
212
214
  // Chrome 38 Symbol has incorrect toString conversion
213
215
  // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
214
216
  // nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will,
215
217
  // of course, fail.
216
- return !$String$4(symbol) || !(Object(symbol) instanceof Symbol) ||
218
+ return !$String$5(symbol) || !(Object(symbol) instanceof Symbol) ||
217
219
  // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
218
220
  !Symbol.sham && V8_VERSION$1 && V8_VERSION$1 < 41;
219
221
  });
@@ -225,20 +227,20 @@ var useSymbolAsUid = NATIVE_SYMBOL$1
225
227
  && !Symbol.sham
226
228
  && typeof Symbol.iterator == 'symbol';
227
229
 
228
- var global$e = global$j;
229
- var shared$2 = shared$3.exports;
230
- var hasOwn$9 = hasOwnProperty_1;
230
+ var global$g = global$k;
231
+ var shared$2 = shared$3;
232
+ var hasOwn$b = hasOwnProperty_1;
231
233
  var uid$1 = uid$2;
232
234
  var NATIVE_SYMBOL = symbolConstructorDetection;
233
235
  var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
234
236
 
235
- var Symbol$1 = global$e.Symbol;
237
+ var Symbol$1 = global$g.Symbol;
236
238
  var WellKnownSymbolsStore = shared$2('wks');
237
239
  var createWellKnownSymbol = USE_SYMBOL_AS_UID$1 ? Symbol$1['for'] || Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid$1;
238
240
 
239
- var wellKnownSymbol$e = function (name) {
240
- if (!hasOwn$9(WellKnownSymbolsStore, name)) {
241
- WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn$9(Symbol$1, name)
241
+ var wellKnownSymbol$g = function (name) {
242
+ if (!hasOwn$b(WellKnownSymbolsStore, name)) {
243
+ WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn$b(Symbol$1, name)
242
244
  ? Symbol$1[name]
243
245
  : createWellKnownSymbol('Symbol.' + name);
244
246
  } return WellKnownSymbolsStore[name];
@@ -250,45 +252,45 @@ var documentAll = typeof document == 'object' && document.all;
250
252
  // `IsCallable` abstract operation
251
253
  // https://tc39.es/ecma262/#sec-iscallable
252
254
  // eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
253
- var isCallable$j = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
255
+ var isCallable$l = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
254
256
  return typeof argument == 'function' || argument === documentAll;
255
257
  } : function (argument) {
256
258
  return typeof argument == 'function';
257
259
  };
258
260
 
259
- var isCallable$i = isCallable$j;
261
+ var isCallable$k = isCallable$l;
260
262
 
261
- var isObject$9 = function (it) {
262
- return typeof it == 'object' ? it !== null : isCallable$i(it);
263
+ var isObject$c = function (it) {
264
+ return typeof it == 'object' ? it !== null : isCallable$k(it);
263
265
  };
264
266
 
265
- var isObject$8 = isObject$9;
267
+ var isObject$b = isObject$c;
266
268
 
267
- var $String$3 = String;
268
- var $TypeError$b = TypeError;
269
+ var $String$4 = String;
270
+ var $TypeError$e = TypeError;
269
271
 
270
272
  // `Assert: Type(argument) is Object`
271
- var anObject$a = function (argument) {
272
- if (isObject$8(argument)) return argument;
273
- throw new $TypeError$b($String$3(argument) + ' is not an object');
273
+ var anObject$f = function (argument) {
274
+ if (isObject$b(argument)) return argument;
275
+ throw new $TypeError$e($String$4(argument) + ' is not an object');
274
276
  };
275
277
 
276
278
  var objectDefineProperties = {};
277
279
 
278
- var fails$9 = fails$d;
280
+ var fails$c = fails$g;
279
281
 
280
282
  // Detect IE8's incomplete defineProperty implementation
281
- var descriptors = !fails$9(function () {
283
+ var descriptors = !fails$c(function () {
282
284
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
283
285
  return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
284
286
  });
285
287
 
286
- var DESCRIPTORS$b = descriptors;
287
- var fails$8 = fails$d;
288
+ var DESCRIPTORS$f = descriptors;
289
+ var fails$b = fails$g;
288
290
 
289
291
  // V8 ~ Chrome 36-
290
292
  // https://bugs.chromium.org/p/v8/issues/detail?id=3334
291
- var v8PrototypeDefineBug = DESCRIPTORS$b && fails$8(function () {
293
+ var v8PrototypeDefineBug = DESCRIPTORS$f && fails$b(function () {
292
294
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
293
295
  return Object.defineProperty(function () { /* empty */ }, 'prototype', {
294
296
  value: 42,
@@ -298,23 +300,23 @@ var v8PrototypeDefineBug = DESCRIPTORS$b && fails$8(function () {
298
300
 
299
301
  var objectDefineProperty = {};
300
302
 
301
- var global$d = global$j;
302
- var isObject$7 = isObject$9;
303
+ var global$f = global$k;
304
+ var isObject$a = isObject$c;
303
305
 
304
- var document$3 = global$d.document;
306
+ var document$3 = global$f.document;
305
307
  // typeof document.createElement is 'object' in old IE
306
- var EXISTS$1 = isObject$7(document$3) && isObject$7(document$3.createElement);
308
+ var EXISTS$1 = isObject$a(document$3) && isObject$a(document$3.createElement);
307
309
 
308
310
  var documentCreateElement$2 = function (it) {
309
311
  return EXISTS$1 ? document$3.createElement(it) : {};
310
312
  };
311
313
 
312
- var DESCRIPTORS$a = descriptors;
313
- var fails$7 = fails$d;
314
+ var DESCRIPTORS$e = descriptors;
315
+ var fails$a = fails$g;
314
316
  var createElement$1 = documentCreateElement$2;
315
317
 
316
318
  // Thanks to IE8 for its funny defineProperty
317
- var ie8DomDefine = !DESCRIPTORS$a && !fails$7(function () {
319
+ var ie8DomDefine = !DESCRIPTORS$e && !fails$a(function () {
318
320
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
319
321
  return Object.defineProperty(createElement$1('div'), 'a', {
320
322
  get: function () { return 7; }
@@ -323,30 +325,30 @@ var ie8DomDefine = !DESCRIPTORS$a && !fails$7(function () {
323
325
 
324
326
  var NATIVE_BIND$2 = functionBindNative;
325
327
 
326
- var call$c = Function.prototype.call;
328
+ var call$f = Function.prototype.call;
327
329
 
328
- var functionCall = NATIVE_BIND$2 ? call$c.bind(call$c) : function () {
329
- return call$c.apply(call$c, arguments);
330
+ var functionCall = NATIVE_BIND$2 ? call$f.bind(call$f) : function () {
331
+ return call$f.apply(call$f, arguments);
330
332
  };
331
333
 
332
- var global$c = global$j;
333
- var isCallable$h = isCallable$j;
334
+ var global$e = global$k;
335
+ var isCallable$j = isCallable$l;
334
336
 
335
337
  var aFunction = function (argument) {
336
- return isCallable$h(argument) ? argument : undefined;
338
+ return isCallable$j(argument) ? argument : undefined;
337
339
  };
338
340
 
339
- var getBuiltIn$7 = function (namespace, method) {
340
- return arguments.length < 2 ? aFunction(global$c[namespace]) : global$c[namespace] && global$c[namespace][method];
341
+ var getBuiltIn$8 = function (namespace, method) {
342
+ return arguments.length < 2 ? aFunction(global$e[namespace]) : global$e[namespace] && global$e[namespace][method];
341
343
  };
342
344
 
343
- var uncurryThis$a = functionUncurryThis;
345
+ var uncurryThis$b = functionUncurryThis;
344
346
 
345
- var objectIsPrototypeOf = uncurryThis$a({}.isPrototypeOf);
347
+ var objectIsPrototypeOf = uncurryThis$b({}.isPrototypeOf);
346
348
 
347
- var getBuiltIn$6 = getBuiltIn$7;
348
- var isCallable$g = isCallable$j;
349
- var isPrototypeOf$2 = objectIsPrototypeOf;
349
+ var getBuiltIn$7 = getBuiltIn$8;
350
+ var isCallable$i = isCallable$l;
351
+ var isPrototypeOf$3 = objectIsPrototypeOf;
350
352
  var USE_SYMBOL_AS_UID = useSymbolAsUid;
351
353
 
352
354
  var $Object$2 = Object;
@@ -354,78 +356,78 @@ var $Object$2 = Object;
354
356
  var isSymbol$2 = USE_SYMBOL_AS_UID ? function (it) {
355
357
  return typeof it == 'symbol';
356
358
  } : function (it) {
357
- var $Symbol = getBuiltIn$6('Symbol');
358
- return isCallable$g($Symbol) && isPrototypeOf$2($Symbol.prototype, $Object$2(it));
359
+ var $Symbol = getBuiltIn$7('Symbol');
360
+ return isCallable$i($Symbol) && isPrototypeOf$3($Symbol.prototype, $Object$2(it));
359
361
  };
360
362
 
361
- var $String$2 = String;
363
+ var $String$3 = String;
362
364
 
363
365
  var tryToString$4 = function (argument) {
364
366
  try {
365
- return $String$2(argument);
367
+ return $String$3(argument);
366
368
  } catch (error) {
367
369
  return 'Object';
368
370
  }
369
371
  };
370
372
 
371
- var isCallable$f = isCallable$j;
373
+ var isCallable$h = isCallable$l;
372
374
  var tryToString$3 = tryToString$4;
373
375
 
374
- var $TypeError$a = TypeError;
376
+ var $TypeError$d = TypeError;
375
377
 
376
378
  // `Assert: IsCallable(argument) is true`
377
- var aCallable$8 = function (argument) {
378
- if (isCallable$f(argument)) return argument;
379
- throw new $TypeError$a(tryToString$3(argument) + ' is not a function');
379
+ var aCallable$c = function (argument) {
380
+ if (isCallable$h(argument)) return argument;
381
+ throw new $TypeError$d(tryToString$3(argument) + ' is not a function');
380
382
  };
381
383
 
382
- var aCallable$7 = aCallable$8;
384
+ var aCallable$b = aCallable$c;
383
385
  var isNullOrUndefined$2 = isNullOrUndefined$4;
384
386
 
385
387
  // `GetMethod` abstract operation
386
388
  // https://tc39.es/ecma262/#sec-getmethod
387
- var getMethod$3 = function (V, P) {
389
+ var getMethod$4 = function (V, P) {
388
390
  var func = V[P];
389
- return isNullOrUndefined$2(func) ? undefined : aCallable$7(func);
391
+ return isNullOrUndefined$2(func) ? undefined : aCallable$b(func);
390
392
  };
391
393
 
392
- var call$b = functionCall;
393
- var isCallable$e = isCallable$j;
394
- var isObject$6 = isObject$9;
394
+ var call$e = functionCall;
395
+ var isCallable$g = isCallable$l;
396
+ var isObject$9 = isObject$c;
395
397
 
396
- var $TypeError$9 = TypeError;
398
+ var $TypeError$c = TypeError;
397
399
 
398
400
  // `OrdinaryToPrimitive` abstract operation
399
401
  // https://tc39.es/ecma262/#sec-ordinarytoprimitive
400
402
  var ordinaryToPrimitive$1 = function (input, pref) {
401
403
  var fn, val;
402
- if (pref === 'string' && isCallable$e(fn = input.toString) && !isObject$6(val = call$b(fn, input))) return val;
403
- if (isCallable$e(fn = input.valueOf) && !isObject$6(val = call$b(fn, input))) return val;
404
- if (pref !== 'string' && isCallable$e(fn = input.toString) && !isObject$6(val = call$b(fn, input))) return val;
405
- throw new $TypeError$9("Can't convert object to primitive value");
404
+ if (pref === 'string' && isCallable$g(fn = input.toString) && !isObject$9(val = call$e(fn, input))) return val;
405
+ if (isCallable$g(fn = input.valueOf) && !isObject$9(val = call$e(fn, input))) return val;
406
+ if (pref !== 'string' && isCallable$g(fn = input.toString) && !isObject$9(val = call$e(fn, input))) return val;
407
+ throw new $TypeError$c("Can't convert object to primitive value");
406
408
  };
407
409
 
408
- var call$a = functionCall;
409
- var isObject$5 = isObject$9;
410
+ var call$d = functionCall;
411
+ var isObject$8 = isObject$c;
410
412
  var isSymbol$1 = isSymbol$2;
411
- var getMethod$2 = getMethod$3;
413
+ var getMethod$3 = getMethod$4;
412
414
  var ordinaryToPrimitive = ordinaryToPrimitive$1;
413
- var wellKnownSymbol$d = wellKnownSymbol$e;
415
+ var wellKnownSymbol$f = wellKnownSymbol$g;
414
416
 
415
- var $TypeError$8 = TypeError;
416
- var TO_PRIMITIVE = wellKnownSymbol$d('toPrimitive');
417
+ var $TypeError$b = TypeError;
418
+ var TO_PRIMITIVE = wellKnownSymbol$f('toPrimitive');
417
419
 
418
420
  // `ToPrimitive` abstract operation
419
421
  // https://tc39.es/ecma262/#sec-toprimitive
420
422
  var toPrimitive$1 = function (input, pref) {
421
- if (!isObject$5(input) || isSymbol$1(input)) return input;
422
- var exoticToPrim = getMethod$2(input, TO_PRIMITIVE);
423
+ if (!isObject$8(input) || isSymbol$1(input)) return input;
424
+ var exoticToPrim = getMethod$3(input, TO_PRIMITIVE);
423
425
  var result;
424
426
  if (exoticToPrim) {
425
427
  if (pref === undefined) pref = 'default';
426
- result = call$a(exoticToPrim, input, pref);
427
- if (!isObject$5(result) || isSymbol$1(result)) return result;
428
- throw new $TypeError$8("Can't convert object to primitive value");
428
+ result = call$d(exoticToPrim, input, pref);
429
+ if (!isObject$8(result) || isSymbol$1(result)) return result;
430
+ throw new $TypeError$b("Can't convert object to primitive value");
429
431
  }
430
432
  if (pref === undefined) pref = 'number';
431
433
  return ordinaryToPrimitive(input, pref);
@@ -441,13 +443,13 @@ var toPropertyKey$2 = function (argument) {
441
443
  return isSymbol(key) ? key : key + '';
442
444
  };
443
445
 
444
- var DESCRIPTORS$9 = descriptors;
446
+ var DESCRIPTORS$d = descriptors;
445
447
  var IE8_DOM_DEFINE$1 = ie8DomDefine;
446
448
  var V8_PROTOTYPE_DEFINE_BUG$1 = v8PrototypeDefineBug;
447
- var anObject$9 = anObject$a;
449
+ var anObject$e = anObject$f;
448
450
  var toPropertyKey$1 = toPropertyKey$2;
449
451
 
450
- var $TypeError$7 = TypeError;
452
+ var $TypeError$a = TypeError;
451
453
  // eslint-disable-next-line es/no-object-defineproperty -- safe
452
454
  var $defineProperty = Object.defineProperty;
453
455
  // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
@@ -458,10 +460,10 @@ var WRITABLE = 'writable';
458
460
 
459
461
  // `Object.defineProperty` method
460
462
  // https://tc39.es/ecma262/#sec-object.defineproperty
461
- objectDefineProperty.f = DESCRIPTORS$9 ? V8_PROTOTYPE_DEFINE_BUG$1 ? function defineProperty(O, P, Attributes) {
462
- anObject$9(O);
463
+ objectDefineProperty.f = DESCRIPTORS$d ? V8_PROTOTYPE_DEFINE_BUG$1 ? function defineProperty(O, P, Attributes) {
464
+ anObject$e(O);
463
465
  P = toPropertyKey$1(P);
464
- anObject$9(Attributes);
466
+ anObject$e(Attributes);
465
467
  if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {
466
468
  var current = $getOwnPropertyDescriptor$1(O, P);
467
469
  if (current && current[WRITABLE]) {
@@ -474,13 +476,13 @@ objectDefineProperty.f = DESCRIPTORS$9 ? V8_PROTOTYPE_DEFINE_BUG$1 ? function de
474
476
  }
475
477
  } return $defineProperty(O, P, Attributes);
476
478
  } : $defineProperty : function defineProperty(O, P, Attributes) {
477
- anObject$9(O);
479
+ anObject$e(O);
478
480
  P = toPropertyKey$1(P);
479
- anObject$9(Attributes);
481
+ anObject$e(Attributes);
480
482
  if (IE8_DOM_DEFINE$1) try {
481
483
  return $defineProperty(O, P, Attributes);
482
484
  } catch (error) { /* empty */ }
483
- if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$7('Accessors not supported');
485
+ if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$a('Accessors not supported');
484
486
  if ('value' in Attributes) O[P] = Attributes.value;
485
487
  return O;
486
488
  };
@@ -534,19 +536,20 @@ var toLength = toLength$1;
534
536
 
535
537
  // `LengthOfArrayLike` abstract operation
536
538
  // https://tc39.es/ecma262/#sec-lengthofarraylike
537
- var lengthOfArrayLike$2 = function (obj) {
539
+ var lengthOfArrayLike$3 = function (obj) {
538
540
  return toLength(obj.length);
539
541
  };
540
542
 
541
543
  var toIndexedObject$4 = toIndexedObject$5;
542
544
  var toAbsoluteIndex = toAbsoluteIndex$1;
543
- var lengthOfArrayLike$1 = lengthOfArrayLike$2;
545
+ var lengthOfArrayLike$2 = lengthOfArrayLike$3;
544
546
 
545
547
  // `Array.prototype.{ indexOf, includes }` methods implementation
546
548
  var createMethod = function (IS_INCLUDES) {
547
549
  return function ($this, el, fromIndex) {
548
550
  var O = toIndexedObject$4($this);
549
- var length = lengthOfArrayLike$1(O);
551
+ var length = lengthOfArrayLike$2(O);
552
+ if (length === 0) return !IS_INCLUDES && -1;
550
553
  var index = toAbsoluteIndex(fromIndex, length);
551
554
  var value;
552
555
  // Array#includes uses SameValueZero equality algorithm
@@ -573,22 +576,22 @@ var arrayIncludes = {
573
576
 
574
577
  var hiddenKeys$4 = {};
575
578
 
576
- var uncurryThis$9 = functionUncurryThis;
577
- var hasOwn$8 = hasOwnProperty_1;
579
+ var uncurryThis$a = functionUncurryThis;
580
+ var hasOwn$a = hasOwnProperty_1;
578
581
  var toIndexedObject$3 = toIndexedObject$5;
579
582
  var indexOf = arrayIncludes.indexOf;
580
583
  var hiddenKeys$3 = hiddenKeys$4;
581
584
 
582
- var push = uncurryThis$9([].push);
585
+ var push = uncurryThis$a([].push);
583
586
 
584
587
  var objectKeysInternal = function (object, names) {
585
588
  var O = toIndexedObject$3(object);
586
589
  var i = 0;
587
590
  var result = [];
588
591
  var key;
589
- for (key in O) !hasOwn$8(hiddenKeys$3, key) && hasOwn$8(O, key) && push(result, key);
592
+ for (key in O) !hasOwn$a(hiddenKeys$3, key) && hasOwn$a(O, key) && push(result, key);
590
593
  // Don't enum bug & hidden keys
591
- while (names.length > i) if (hasOwn$8(O, key = names[i++])) {
594
+ while (names.length > i) if (hasOwn$a(O, key = names[i++])) {
592
595
  ~indexOf(result, key) || push(result, key);
593
596
  }
594
597
  return result;
@@ -615,32 +618,32 @@ var objectKeys$2 = Object.keys || function keys(O) {
615
618
  return internalObjectKeys$1(O, enumBugKeys$2);
616
619
  };
617
620
 
618
- var DESCRIPTORS$8 = descriptors;
621
+ var DESCRIPTORS$c = descriptors;
619
622
  var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
620
- var definePropertyModule$3 = objectDefineProperty;
621
- var anObject$8 = anObject$a;
623
+ var definePropertyModule$4 = objectDefineProperty;
624
+ var anObject$d = anObject$f;
622
625
  var toIndexedObject$2 = toIndexedObject$5;
623
626
  var objectKeys$1 = objectKeys$2;
624
627
 
625
628
  // `Object.defineProperties` method
626
629
  // https://tc39.es/ecma262/#sec-object.defineproperties
627
630
  // eslint-disable-next-line es/no-object-defineproperties -- safe
628
- objectDefineProperties.f = DESCRIPTORS$8 && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
629
- anObject$8(O);
631
+ objectDefineProperties.f = DESCRIPTORS$c && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
632
+ anObject$d(O);
630
633
  var props = toIndexedObject$2(Properties);
631
634
  var keys = objectKeys$1(Properties);
632
635
  var length = keys.length;
633
636
  var index = 0;
634
637
  var key;
635
- while (length > index) definePropertyModule$3.f(O, key = keys[index++], props[key]);
638
+ while (length > index) definePropertyModule$4.f(O, key = keys[index++], props[key]);
636
639
  return O;
637
640
  };
638
641
 
639
- var getBuiltIn$5 = getBuiltIn$7;
642
+ var getBuiltIn$6 = getBuiltIn$8;
640
643
 
641
- var html$2 = getBuiltIn$5('document', 'documentElement');
644
+ var html$2 = getBuiltIn$6('document', 'documentElement');
642
645
 
643
- var shared$1 = shared$3.exports;
646
+ var shared$1 = shared$3;
644
647
  var uid = uid$2;
645
648
 
646
649
  var keys = shared$1('keys');
@@ -650,7 +653,7 @@ var sharedKey$3 = function (key) {
650
653
  };
651
654
 
652
655
  /* global ActiveXObject -- old IE, WSH */
653
- var anObject$7 = anObject$a;
656
+ var anObject$c = anObject$f;
654
657
  var definePropertiesModule = objectDefineProperties;
655
658
  var enumBugKeys$1 = enumBugKeys$3;
656
659
  var hiddenKeys$2 = hiddenKeys$4;
@@ -724,7 +727,7 @@ hiddenKeys$2[IE_PROTO$1] = true;
724
727
  var objectCreate = Object.create || function create(O, Properties) {
725
728
  var result;
726
729
  if (O !== null) {
727
- EmptyConstructor[PROTOTYPE] = anObject$7(O);
730
+ EmptyConstructor[PROTOTYPE] = anObject$c(O);
728
731
  result = new EmptyConstructor();
729
732
  EmptyConstructor[PROTOTYPE] = null;
730
733
  // add "__proto__" for Object.getPrototypeOf polyfill
@@ -733,19 +736,19 @@ var objectCreate = Object.create || function create(O, Properties) {
733
736
  return Properties === undefined ? result : definePropertiesModule.f(result, Properties);
734
737
  };
735
738
 
736
- var wellKnownSymbol$c = wellKnownSymbol$e;
737
- var create$1 = objectCreate;
738
- var defineProperty$5 = objectDefineProperty.f;
739
+ var wellKnownSymbol$e = wellKnownSymbol$g;
740
+ var create$2 = objectCreate;
741
+ var defineProperty$6 = objectDefineProperty.f;
739
742
 
740
- var UNSCOPABLES = wellKnownSymbol$c('unscopables');
743
+ var UNSCOPABLES = wellKnownSymbol$e('unscopables');
741
744
  var ArrayPrototype$1 = Array.prototype;
742
745
 
743
746
  // Array.prototype[@@unscopables]
744
747
  // https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
745
748
  if (ArrayPrototype$1[UNSCOPABLES] === undefined) {
746
- defineProperty$5(ArrayPrototype$1, UNSCOPABLES, {
749
+ defineProperty$6(ArrayPrototype$1, UNSCOPABLES, {
747
750
  configurable: true,
748
- value: create$1(null)
751
+ value: create$2(null)
749
752
  });
750
753
  }
751
754
 
@@ -756,14 +759,14 @@ var addToUnscopables$1 = function (key) {
756
759
 
757
760
  var iterators = {};
758
761
 
759
- var global$b = global$j;
760
- var isCallable$d = isCallable$j;
762
+ var global$d = global$k;
763
+ var isCallable$f = isCallable$l;
761
764
 
762
- var WeakMap$1 = global$b.WeakMap;
765
+ var WeakMap$1 = global$d.WeakMap;
763
766
 
764
- var weakMapBasicDetection = isCallable$d(WeakMap$1) && /native code/.test(String(WeakMap$1));
767
+ var weakMapBasicDetection = isCallable$f(WeakMap$1) && /native code/.test(String(WeakMap$1));
765
768
 
766
- var createPropertyDescriptor$3 = function (bitmap, value) {
769
+ var createPropertyDescriptor$5 = function (bitmap, value) {
767
770
  return {
768
771
  enumerable: !(bitmap & 1),
769
772
  configurable: !(bitmap & 2),
@@ -772,29 +775,29 @@ var createPropertyDescriptor$3 = function (bitmap, value) {
772
775
  };
773
776
  };
774
777
 
775
- var DESCRIPTORS$7 = descriptors;
776
- var definePropertyModule$2 = objectDefineProperty;
777
- var createPropertyDescriptor$2 = createPropertyDescriptor$3;
778
+ var DESCRIPTORS$b = descriptors;
779
+ var definePropertyModule$3 = objectDefineProperty;
780
+ var createPropertyDescriptor$4 = createPropertyDescriptor$5;
778
781
 
779
- var createNonEnumerableProperty$4 = DESCRIPTORS$7 ? function (object, key, value) {
780
- return definePropertyModule$2.f(object, key, createPropertyDescriptor$2(1, value));
782
+ var createNonEnumerableProperty$8 = DESCRIPTORS$b ? function (object, key, value) {
783
+ return definePropertyModule$3.f(object, key, createPropertyDescriptor$4(1, value));
781
784
  } : function (object, key, value) {
782
785
  object[key] = value;
783
786
  return object;
784
787
  };
785
788
 
786
789
  var NATIVE_WEAK_MAP = weakMapBasicDetection;
787
- var global$a = global$j;
788
- var isObject$4 = isObject$9;
789
- var createNonEnumerableProperty$3 = createNonEnumerableProperty$4;
790
- var hasOwn$7 = hasOwnProperty_1;
791
- var shared = sharedStore;
790
+ var global$c = global$k;
791
+ var isObject$7 = isObject$c;
792
+ var createNonEnumerableProperty$7 = createNonEnumerableProperty$8;
793
+ var hasOwn$9 = hasOwnProperty_1;
794
+ var shared = sharedStoreExports;
792
795
  var sharedKey$1 = sharedKey$3;
793
796
  var hiddenKeys$1 = hiddenKeys$4;
794
797
 
795
798
  var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
796
- var TypeError$2 = global$a.TypeError;
797
- var WeakMap = global$a.WeakMap;
799
+ var TypeError$2 = global$c.TypeError;
800
+ var WeakMap = global$c.WeakMap;
798
801
  var set$1, get, has;
799
802
 
800
803
  var enforce = function (it) {
@@ -804,7 +807,7 @@ var enforce = function (it) {
804
807
  var getterFor = function (TYPE) {
805
808
  return function (it) {
806
809
  var state;
807
- if (!isObject$4(it) || (state = get(it)).type !== TYPE) {
810
+ if (!isObject$7(it) || (state = get(it)).type !== TYPE) {
808
811
  throw new TypeError$2('Incompatible receiver, ' + TYPE + ' required');
809
812
  } return state;
810
813
  };
@@ -833,16 +836,16 @@ if (NATIVE_WEAK_MAP || shared.state) {
833
836
  var STATE = sharedKey$1('state');
834
837
  hiddenKeys$1[STATE] = true;
835
838
  set$1 = function (it, metadata) {
836
- if (hasOwn$7(it, STATE)) throw new TypeError$2(OBJECT_ALREADY_INITIALIZED);
839
+ if (hasOwn$9(it, STATE)) throw new TypeError$2(OBJECT_ALREADY_INITIALIZED);
837
840
  metadata.facade = it;
838
- createNonEnumerableProperty$3(it, STATE, metadata);
841
+ createNonEnumerableProperty$7(it, STATE, metadata);
839
842
  return metadata;
840
843
  };
841
844
  get = function (it) {
842
- return hasOwn$7(it, STATE) ? it[STATE] : {};
845
+ return hasOwn$9(it, STATE) ? it[STATE] : {};
843
846
  };
844
847
  has = function (it) {
845
- return hasOwn$7(it, STATE);
848
+ return hasOwn$9(it, STATE);
846
849
  };
847
850
  }
848
851
 
@@ -860,25 +863,25 @@ var objectPropertyIsEnumerable = {};
860
863
 
861
864
  var $propertyIsEnumerable = {}.propertyIsEnumerable;
862
865
  // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
863
- var getOwnPropertyDescriptor$2 = Object.getOwnPropertyDescriptor;
866
+ var getOwnPropertyDescriptor$3 = Object.getOwnPropertyDescriptor;
864
867
 
865
868
  // Nashorn ~ JDK8 bug
866
- var NASHORN_BUG = getOwnPropertyDescriptor$2 && !$propertyIsEnumerable.call({ 1: 2 }, 1);
869
+ var NASHORN_BUG = getOwnPropertyDescriptor$3 && !$propertyIsEnumerable.call({ 1: 2 }, 1);
867
870
 
868
871
  // `Object.prototype.propertyIsEnumerable` method implementation
869
872
  // https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
870
873
  objectPropertyIsEnumerable.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
871
- var descriptor = getOwnPropertyDescriptor$2(this, V);
874
+ var descriptor = getOwnPropertyDescriptor$3(this, V);
872
875
  return !!descriptor && descriptor.enumerable;
873
876
  } : $propertyIsEnumerable;
874
877
 
875
- var DESCRIPTORS$6 = descriptors;
876
- var call$9 = functionCall;
878
+ var DESCRIPTORS$a = descriptors;
879
+ var call$c = functionCall;
877
880
  var propertyIsEnumerableModule$1 = objectPropertyIsEnumerable;
878
- var createPropertyDescriptor$1 = createPropertyDescriptor$3;
881
+ var createPropertyDescriptor$3 = createPropertyDescriptor$5;
879
882
  var toIndexedObject$1 = toIndexedObject$5;
880
883
  var toPropertyKey = toPropertyKey$2;
881
- var hasOwn$6 = hasOwnProperty_1;
884
+ var hasOwn$8 = hasOwnProperty_1;
882
885
  var IE8_DOM_DEFINE = ie8DomDefine;
883
886
 
884
887
  // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
@@ -886,28 +889,28 @@ var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
886
889
 
887
890
  // `Object.getOwnPropertyDescriptor` method
888
891
  // https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
889
- objectGetOwnPropertyDescriptor.f = DESCRIPTORS$6 ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {
892
+ objectGetOwnPropertyDescriptor.f = DESCRIPTORS$a ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {
890
893
  O = toIndexedObject$1(O);
891
894
  P = toPropertyKey(P);
892
895
  if (IE8_DOM_DEFINE) try {
893
896
  return $getOwnPropertyDescriptor(O, P);
894
897
  } catch (error) { /* empty */ }
895
- if (hasOwn$6(O, P)) return createPropertyDescriptor$1(!call$9(propertyIsEnumerableModule$1.f, O, P), O[P]);
898
+ if (hasOwn$8(O, P)) return createPropertyDescriptor$3(!call$c(propertyIsEnumerableModule$1.f, O, P), O[P]);
896
899
  };
897
900
 
898
901
  var makeBuiltIn$3 = {exports: {}};
899
902
 
900
- var DESCRIPTORS$5 = descriptors;
901
- var hasOwn$5 = hasOwnProperty_1;
903
+ var DESCRIPTORS$9 = descriptors;
904
+ var hasOwn$7 = hasOwnProperty_1;
902
905
 
903
906
  var FunctionPrototype$1 = Function.prototype;
904
907
  // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
905
- var getDescriptor = DESCRIPTORS$5 && Object.getOwnPropertyDescriptor;
908
+ var getDescriptor = DESCRIPTORS$9 && Object.getOwnPropertyDescriptor;
906
909
 
907
- var EXISTS = hasOwn$5(FunctionPrototype$1, 'name');
910
+ var EXISTS = hasOwn$7(FunctionPrototype$1, 'name');
908
911
  // additional protection from minified / mangled / dropped function names
909
912
  var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
910
- var CONFIGURABLE = EXISTS && (!DESCRIPTORS$5 || (DESCRIPTORS$5 && getDescriptor(FunctionPrototype$1, 'name').configurable));
913
+ var CONFIGURABLE = EXISTS && (!DESCRIPTORS$9 || (DESCRIPTORS$9 && getDescriptor(FunctionPrototype$1, 'name').configurable));
911
914
 
912
915
  var functionName = {
913
916
  EXISTS: EXISTS,
@@ -915,14 +918,14 @@ var functionName = {
915
918
  CONFIGURABLE: CONFIGURABLE
916
919
  };
917
920
 
918
- var uncurryThis$8 = functionUncurryThis;
919
- var isCallable$c = isCallable$j;
920
- var store = sharedStore;
921
+ var uncurryThis$9 = functionUncurryThis;
922
+ var isCallable$e = isCallable$l;
923
+ var store = sharedStoreExports;
921
924
 
922
- var functionToString = uncurryThis$8(Function.toString);
925
+ var functionToString = uncurryThis$9(Function.toString);
923
926
 
924
927
  // this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
925
- if (!isCallable$c(store.inspectSource)) {
928
+ if (!isCallable$e(store.inspectSource)) {
926
929
  store.inspectSource = function (it) {
927
930
  return functionToString(it);
928
931
  };
@@ -930,51 +933,51 @@ if (!isCallable$c(store.inspectSource)) {
930
933
 
931
934
  var inspectSource$3 = store.inspectSource;
932
935
 
933
- var uncurryThis$7 = functionUncurryThis;
934
- var fails$6 = fails$d;
935
- var isCallable$b = isCallable$j;
936
- var hasOwn$4 = hasOwnProperty_1;
937
- var DESCRIPTORS$4 = descriptors;
936
+ var uncurryThis$8 = functionUncurryThis;
937
+ var fails$9 = fails$g;
938
+ var isCallable$d = isCallable$l;
939
+ var hasOwn$6 = hasOwnProperty_1;
940
+ var DESCRIPTORS$8 = descriptors;
938
941
  var CONFIGURABLE_FUNCTION_NAME$1 = functionName.CONFIGURABLE;
939
942
  var inspectSource$2 = inspectSource$3;
940
- var InternalStateModule$2 = internalState;
943
+ var InternalStateModule$3 = internalState;
941
944
 
942
- var enforceInternalState = InternalStateModule$2.enforce;
943
- var getInternalState$1 = InternalStateModule$2.get;
944
- var $String$1 = String;
945
+ var enforceInternalState = InternalStateModule$3.enforce;
946
+ var getInternalState$1 = InternalStateModule$3.get;
947
+ var $String$2 = String;
945
948
  // eslint-disable-next-line es/no-object-defineproperty -- safe
946
- var defineProperty$4 = Object.defineProperty;
947
- var stringSlice = uncurryThis$7(''.slice);
948
- var replace = uncurryThis$7(''.replace);
949
- var join = uncurryThis$7([].join);
949
+ var defineProperty$5 = Object.defineProperty;
950
+ var stringSlice = uncurryThis$8(''.slice);
951
+ var replace$1 = uncurryThis$8(''.replace);
952
+ var join = uncurryThis$8([].join);
950
953
 
951
- var CONFIGURABLE_LENGTH = DESCRIPTORS$4 && !fails$6(function () {
952
- return defineProperty$4(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
954
+ var CONFIGURABLE_LENGTH = DESCRIPTORS$8 && !fails$9(function () {
955
+ return defineProperty$5(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
953
956
  });
954
957
 
955
958
  var TEMPLATE = String(String).split('String');
956
959
 
957
960
  var makeBuiltIn$2 = makeBuiltIn$3.exports = function (value, name, options) {
958
- if (stringSlice($String$1(name), 0, 7) === 'Symbol(') {
959
- name = '[' + replace($String$1(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
961
+ if (stringSlice($String$2(name), 0, 7) === 'Symbol(') {
962
+ name = '[' + replace$1($String$2(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
960
963
  }
961
964
  if (options && options.getter) name = 'get ' + name;
962
965
  if (options && options.setter) name = 'set ' + name;
963
- if (!hasOwn$4(value, 'name') || (CONFIGURABLE_FUNCTION_NAME$1 && value.name !== name)) {
964
- if (DESCRIPTORS$4) defineProperty$4(value, 'name', { value: name, configurable: true });
966
+ if (!hasOwn$6(value, 'name') || (CONFIGURABLE_FUNCTION_NAME$1 && value.name !== name)) {
967
+ if (DESCRIPTORS$8) defineProperty$5(value, 'name', { value: name, configurable: true });
965
968
  else value.name = name;
966
969
  }
967
- if (CONFIGURABLE_LENGTH && options && hasOwn$4(options, 'arity') && value.length !== options.arity) {
968
- defineProperty$4(value, 'length', { value: options.arity });
970
+ if (CONFIGURABLE_LENGTH && options && hasOwn$6(options, 'arity') && value.length !== options.arity) {
971
+ defineProperty$5(value, 'length', { value: options.arity });
969
972
  }
970
973
  try {
971
- if (options && hasOwn$4(options, 'constructor') && options.constructor) {
972
- if (DESCRIPTORS$4) defineProperty$4(value, 'prototype', { writable: false });
974
+ if (options && hasOwn$6(options, 'constructor') && options.constructor) {
975
+ if (DESCRIPTORS$8) defineProperty$5(value, 'prototype', { writable: false });
973
976
  // in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable
974
977
  } else if (value.prototype) value.prototype = undefined;
975
978
  } catch (error) { /* empty */ }
976
979
  var state = enforceInternalState(value);
977
- if (!hasOwn$4(state, 'source')) {
980
+ if (!hasOwn$6(state, 'source')) {
978
981
  state.source = join(TEMPLATE, typeof name == 'string' ? name : '');
979
982
  } return value;
980
983
  };
@@ -982,19 +985,21 @@ var makeBuiltIn$2 = makeBuiltIn$3.exports = function (value, name, options) {
982
985
  // add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
983
986
  // eslint-disable-next-line no-extend-native -- required
984
987
  Function.prototype.toString = makeBuiltIn$2(function toString() {
985
- return isCallable$b(this) && getInternalState$1(this).source || inspectSource$2(this);
988
+ return isCallable$d(this) && getInternalState$1(this).source || inspectSource$2(this);
986
989
  }, 'toString');
987
990
 
988
- var isCallable$a = isCallable$j;
989
- var definePropertyModule$1 = objectDefineProperty;
990
- var makeBuiltIn$1 = makeBuiltIn$3.exports;
991
+ var makeBuiltInExports = makeBuiltIn$3.exports;
992
+
993
+ var isCallable$c = isCallable$l;
994
+ var definePropertyModule$2 = objectDefineProperty;
995
+ var makeBuiltIn$1 = makeBuiltInExports;
991
996
  var defineGlobalProperty$1 = defineGlobalProperty$3;
992
997
 
993
- var defineBuiltIn$5 = function (O, key, value, options) {
998
+ var defineBuiltIn$6 = function (O, key, value, options) {
994
999
  if (!options) options = {};
995
1000
  var simple = options.enumerable;
996
1001
  var name = options.name !== undefined ? options.name : key;
997
- if (isCallable$a(value)) makeBuiltIn$1(value, name, options);
1002
+ if (isCallable$c(value)) makeBuiltIn$1(value, name, options);
998
1003
  if (options.global) {
999
1004
  if (simple) O[key] = value;
1000
1005
  else defineGlobalProperty$1(key, value);
@@ -1004,7 +1009,7 @@ var defineBuiltIn$5 = function (O, key, value, options) {
1004
1009
  else if (O[key]) simple = true;
1005
1010
  } catch (error) { /* empty */ }
1006
1011
  if (simple) O[key] = value;
1007
- else definePropertyModule$1.f(O, key, {
1012
+ else definePropertyModule$2.f(O, key, {
1008
1013
  value: value,
1009
1014
  enumerable: false,
1010
1015
  configurable: !options.nonConfigurable,
@@ -1032,40 +1037,40 @@ var objectGetOwnPropertySymbols = {};
1032
1037
  // eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
1033
1038
  objectGetOwnPropertySymbols.f = Object.getOwnPropertySymbols;
1034
1039
 
1035
- var getBuiltIn$4 = getBuiltIn$7;
1036
- var uncurryThis$6 = functionUncurryThis;
1040
+ var getBuiltIn$5 = getBuiltIn$8;
1041
+ var uncurryThis$7 = functionUncurryThis;
1037
1042
  var getOwnPropertyNamesModule = objectGetOwnPropertyNames;
1038
1043
  var getOwnPropertySymbolsModule$1 = objectGetOwnPropertySymbols;
1039
- var anObject$6 = anObject$a;
1044
+ var anObject$b = anObject$f;
1040
1045
 
1041
- var concat$1 = uncurryThis$6([].concat);
1046
+ var concat$1 = uncurryThis$7([].concat);
1042
1047
 
1043
1048
  // all object keys, includes non-enumerable and symbols
1044
- var ownKeys$1 = getBuiltIn$4('Reflect', 'ownKeys') || function ownKeys(it) {
1045
- var keys = getOwnPropertyNamesModule.f(anObject$6(it));
1049
+ var ownKeys$1 = getBuiltIn$5('Reflect', 'ownKeys') || function ownKeys(it) {
1050
+ var keys = getOwnPropertyNamesModule.f(anObject$b(it));
1046
1051
  var getOwnPropertySymbols = getOwnPropertySymbolsModule$1.f;
1047
1052
  return getOwnPropertySymbols ? concat$1(keys, getOwnPropertySymbols(it)) : keys;
1048
1053
  };
1049
1054
 
1050
- var hasOwn$3 = hasOwnProperty_1;
1055
+ var hasOwn$5 = hasOwnProperty_1;
1051
1056
  var ownKeys = ownKeys$1;
1052
1057
  var getOwnPropertyDescriptorModule = objectGetOwnPropertyDescriptor;
1053
- var definePropertyModule = objectDefineProperty;
1058
+ var definePropertyModule$1 = objectDefineProperty;
1054
1059
 
1055
- var copyConstructorProperties$1 = function (target, source, exceptions) {
1060
+ var copyConstructorProperties$2 = function (target, source, exceptions) {
1056
1061
  var keys = ownKeys(source);
1057
- var defineProperty = definePropertyModule.f;
1062
+ var defineProperty = definePropertyModule$1.f;
1058
1063
  var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
1059
1064
  for (var i = 0; i < keys.length; i++) {
1060
1065
  var key = keys[i];
1061
- if (!hasOwn$3(target, key) && !(exceptions && hasOwn$3(exceptions, key))) {
1066
+ if (!hasOwn$5(target, key) && !(exceptions && hasOwn$5(exceptions, key))) {
1062
1067
  defineProperty(target, key, getOwnPropertyDescriptor(source, key));
1063
1068
  }
1064
1069
  }
1065
1070
  };
1066
1071
 
1067
- var fails$5 = fails$d;
1068
- var isCallable$9 = isCallable$j;
1072
+ var fails$8 = fails$g;
1073
+ var isCallable$b = isCallable$l;
1069
1074
 
1070
1075
  var replacement = /#|\.prototype\./;
1071
1076
 
@@ -1073,7 +1078,7 @@ var isForced$2 = function (feature, detection) {
1073
1078
  var value = data[normalize(feature)];
1074
1079
  return value === POLYFILL ? true
1075
1080
  : value === NATIVE ? false
1076
- : isCallable$9(detection) ? fails$5(detection)
1081
+ : isCallable$b(detection) ? fails$8(detection)
1077
1082
  : !!detection;
1078
1083
  };
1079
1084
 
@@ -1087,12 +1092,12 @@ var POLYFILL = isForced$2.POLYFILL = 'P';
1087
1092
 
1088
1093
  var isForced_1 = isForced$2;
1089
1094
 
1090
- var global$9 = global$j;
1091
- var getOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
1092
- var createNonEnumerableProperty$2 = createNonEnumerableProperty$4;
1093
- var defineBuiltIn$4 = defineBuiltIn$5;
1095
+ var global$b = global$k;
1096
+ var getOwnPropertyDescriptor$2 = objectGetOwnPropertyDescriptor.f;
1097
+ var createNonEnumerableProperty$6 = createNonEnumerableProperty$8;
1098
+ var defineBuiltIn$5 = defineBuiltIn$6;
1094
1099
  var defineGlobalProperty = defineGlobalProperty$3;
1095
- var copyConstructorProperties = copyConstructorProperties$1;
1100
+ var copyConstructorProperties$1 = copyConstructorProperties$2;
1096
1101
  var isForced$1 = isForced_1;
1097
1102
 
1098
1103
  /*
@@ -1116,44 +1121,44 @@ var _export = function (options, source) {
1116
1121
  var STATIC = options.stat;
1117
1122
  var FORCED, target, key, targetProperty, sourceProperty, descriptor;
1118
1123
  if (GLOBAL) {
1119
- target = global$9;
1124
+ target = global$b;
1120
1125
  } else if (STATIC) {
1121
- target = global$9[TARGET] || defineGlobalProperty(TARGET, {});
1126
+ target = global$b[TARGET] || defineGlobalProperty(TARGET, {});
1122
1127
  } else {
1123
- target = global$9[TARGET] && global$9[TARGET].prototype;
1128
+ target = global$b[TARGET] && global$b[TARGET].prototype;
1124
1129
  }
1125
1130
  if (target) for (key in source) {
1126
1131
  sourceProperty = source[key];
1127
1132
  if (options.dontCallGetSet) {
1128
- descriptor = getOwnPropertyDescriptor$1(target, key);
1133
+ descriptor = getOwnPropertyDescriptor$2(target, key);
1129
1134
  targetProperty = descriptor && descriptor.value;
1130
1135
  } else targetProperty = target[key];
1131
1136
  FORCED = isForced$1(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
1132
1137
  // contained in target
1133
1138
  if (!FORCED && targetProperty !== undefined) {
1134
1139
  if (typeof sourceProperty == typeof targetProperty) continue;
1135
- copyConstructorProperties(sourceProperty, targetProperty);
1140
+ copyConstructorProperties$1(sourceProperty, targetProperty);
1136
1141
  }
1137
1142
  // add a flag to not completely full polyfills
1138
1143
  if (options.sham || (targetProperty && targetProperty.sham)) {
1139
- createNonEnumerableProperty$2(sourceProperty, 'sham', true);
1144
+ createNonEnumerableProperty$6(sourceProperty, 'sham', true);
1140
1145
  }
1141
- defineBuiltIn$4(target, key, sourceProperty, options);
1146
+ defineBuiltIn$5(target, key, sourceProperty, options);
1142
1147
  }
1143
1148
  };
1144
1149
 
1145
- var fails$4 = fails$d;
1150
+ var fails$7 = fails$g;
1146
1151
 
1147
- var correctPrototypeGetter = !fails$4(function () {
1152
+ var correctPrototypeGetter = !fails$7(function () {
1148
1153
  function F() { /* empty */ }
1149
1154
  F.prototype.constructor = null;
1150
1155
  // eslint-disable-next-line es/no-object-getprototypeof -- required for testing
1151
1156
  return Object.getPrototypeOf(new F()) !== F.prototype;
1152
1157
  });
1153
1158
 
1154
- var hasOwn$2 = hasOwnProperty_1;
1155
- var isCallable$8 = isCallable$j;
1156
- var toObject$1 = toObject$3;
1159
+ var hasOwn$4 = hasOwnProperty_1;
1160
+ var isCallable$a = isCallable$l;
1161
+ var toObject$2 = toObject$4;
1157
1162
  var sharedKey = sharedKey$3;
1158
1163
  var CORRECT_PROTOTYPE_GETTER = correctPrototypeGetter;
1159
1164
 
@@ -1165,27 +1170,27 @@ var ObjectPrototype = $Object$1.prototype;
1165
1170
  // https://tc39.es/ecma262/#sec-object.getprototypeof
1166
1171
  // eslint-disable-next-line es/no-object-getprototypeof -- safe
1167
1172
  var objectGetPrototypeOf = CORRECT_PROTOTYPE_GETTER ? $Object$1.getPrototypeOf : function (O) {
1168
- var object = toObject$1(O);
1169
- if (hasOwn$2(object, IE_PROTO)) return object[IE_PROTO];
1173
+ var object = toObject$2(O);
1174
+ if (hasOwn$4(object, IE_PROTO)) return object[IE_PROTO];
1170
1175
  var constructor = object.constructor;
1171
- if (isCallable$8(constructor) && object instanceof constructor) {
1176
+ if (isCallable$a(constructor) && object instanceof constructor) {
1172
1177
  return constructor.prototype;
1173
1178
  } return object instanceof $Object$1 ? ObjectPrototype : null;
1174
1179
  };
1175
1180
 
1176
- var fails$3 = fails$d;
1177
- var isCallable$7 = isCallable$j;
1178
- var isObject$3 = isObject$9;
1179
- var getPrototypeOf$1 = objectGetPrototypeOf;
1180
- var defineBuiltIn$3 = defineBuiltIn$5;
1181
- var wellKnownSymbol$b = wellKnownSymbol$e;
1181
+ var fails$6 = fails$g;
1182
+ var isCallable$9 = isCallable$l;
1183
+ var isObject$6 = isObject$c;
1184
+ var getPrototypeOf$2 = objectGetPrototypeOf;
1185
+ var defineBuiltIn$4 = defineBuiltIn$6;
1186
+ var wellKnownSymbol$d = wellKnownSymbol$g;
1182
1187
 
1183
- var ITERATOR$5 = wellKnownSymbol$b('iterator');
1188
+ var ITERATOR$6 = wellKnownSymbol$d('iterator');
1184
1189
  var BUGGY_SAFARI_ITERATORS$1 = false;
1185
1190
 
1186
1191
  // `%IteratorPrototype%` object
1187
1192
  // https://tc39.es/ecma262/#sec-%iteratorprototype%-object
1188
- var IteratorPrototype$2, PrototypeOfArrayIteratorPrototype, arrayIterator;
1193
+ var IteratorPrototype$4, PrototypeOfArrayIteratorPrototype, arrayIterator;
1189
1194
 
1190
1195
  /* eslint-disable es/no-array-prototype-keys -- safe */
1191
1196
  if ([].keys) {
@@ -1193,48 +1198,48 @@ if ([].keys) {
1193
1198
  // Safari 8 has buggy iterators w/o `next`
1194
1199
  if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS$1 = true;
1195
1200
  else {
1196
- PrototypeOfArrayIteratorPrototype = getPrototypeOf$1(getPrototypeOf$1(arrayIterator));
1197
- if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype$2 = PrototypeOfArrayIteratorPrototype;
1201
+ PrototypeOfArrayIteratorPrototype = getPrototypeOf$2(getPrototypeOf$2(arrayIterator));
1202
+ if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype$4 = PrototypeOfArrayIteratorPrototype;
1198
1203
  }
1199
1204
  }
1200
1205
 
1201
- var NEW_ITERATOR_PROTOTYPE = !isObject$3(IteratorPrototype$2) || fails$3(function () {
1206
+ var NEW_ITERATOR_PROTOTYPE = !isObject$6(IteratorPrototype$4) || fails$6(function () {
1202
1207
  var test = {};
1203
1208
  // FF44- legacy iterators case
1204
- return IteratorPrototype$2[ITERATOR$5].call(test) !== test;
1209
+ return IteratorPrototype$4[ITERATOR$6].call(test) !== test;
1205
1210
  });
1206
1211
 
1207
- if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype$2 = {};
1212
+ if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype$4 = {};
1208
1213
 
1209
1214
  // `%IteratorPrototype%[@@iterator]()` method
1210
1215
  // https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator
1211
- if (!isCallable$7(IteratorPrototype$2[ITERATOR$5])) {
1212
- defineBuiltIn$3(IteratorPrototype$2, ITERATOR$5, function () {
1216
+ if (!isCallable$9(IteratorPrototype$4[ITERATOR$6])) {
1217
+ defineBuiltIn$4(IteratorPrototype$4, ITERATOR$6, function () {
1213
1218
  return this;
1214
1219
  });
1215
1220
  }
1216
1221
 
1217
1222
  var iteratorsCore = {
1218
- IteratorPrototype: IteratorPrototype$2,
1223
+ IteratorPrototype: IteratorPrototype$4,
1219
1224
  BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS$1
1220
1225
  };
1221
1226
 
1222
- var defineProperty$3 = objectDefineProperty.f;
1223
- var hasOwn$1 = hasOwnProperty_1;
1224
- var wellKnownSymbol$a = wellKnownSymbol$e;
1227
+ var defineProperty$4 = objectDefineProperty.f;
1228
+ var hasOwn$3 = hasOwnProperty_1;
1229
+ var wellKnownSymbol$c = wellKnownSymbol$g;
1225
1230
 
1226
- var TO_STRING_TAG$2 = wellKnownSymbol$a('toStringTag');
1231
+ var TO_STRING_TAG$4 = wellKnownSymbol$c('toStringTag');
1227
1232
 
1228
1233
  var setToStringTag$4 = function (target, TAG, STATIC) {
1229
1234
  if (target && !STATIC) target = target.prototype;
1230
- if (target && !hasOwn$1(target, TO_STRING_TAG$2)) {
1231
- defineProperty$3(target, TO_STRING_TAG$2, { configurable: true, value: TAG });
1235
+ if (target && !hasOwn$3(target, TO_STRING_TAG$4)) {
1236
+ defineProperty$4(target, TO_STRING_TAG$4, { configurable: true, value: TAG });
1232
1237
  }
1233
1238
  };
1234
1239
 
1235
- var IteratorPrototype$1 = iteratorsCore.IteratorPrototype;
1236
- var create = objectCreate;
1237
- var createPropertyDescriptor = createPropertyDescriptor$3;
1240
+ var IteratorPrototype$3 = iteratorsCore.IteratorPrototype;
1241
+ var create$1 = objectCreate;
1242
+ var createPropertyDescriptor$2 = createPropertyDescriptor$5;
1238
1243
  var setToStringTag$3 = setToStringTag$4;
1239
1244
  var Iterators$4 = iterators;
1240
1245
 
@@ -1242,41 +1247,42 @@ var returnThis$1 = function () { return this; };
1242
1247
 
1243
1248
  var iteratorCreateConstructor = function (IteratorConstructor, NAME, next, ENUMERABLE_NEXT) {
1244
1249
  var TO_STRING_TAG = NAME + ' Iterator';
1245
- IteratorConstructor.prototype = create(IteratorPrototype$1, { next: createPropertyDescriptor(+!ENUMERABLE_NEXT, next) });
1250
+ IteratorConstructor.prototype = create$1(IteratorPrototype$3, { next: createPropertyDescriptor$2(+!ENUMERABLE_NEXT, next) });
1246
1251
  setToStringTag$3(IteratorConstructor, TO_STRING_TAG, false);
1247
1252
  Iterators$4[TO_STRING_TAG] = returnThis$1;
1248
1253
  return IteratorConstructor;
1249
1254
  };
1250
1255
 
1251
- var uncurryThis$5 = functionUncurryThis;
1252
- var aCallable$6 = aCallable$8;
1256
+ var uncurryThis$6 = functionUncurryThis;
1257
+ var aCallable$a = aCallable$c;
1253
1258
 
1254
1259
  var functionUncurryThisAccessor = function (object, key, method) {
1255
1260
  try {
1256
1261
  // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
1257
- return uncurryThis$5(aCallable$6(Object.getOwnPropertyDescriptor(object, key)[method]));
1262
+ return uncurryThis$6(aCallable$a(Object.getOwnPropertyDescriptor(object, key)[method]));
1258
1263
  } catch (error) { /* empty */ }
1259
1264
  };
1260
1265
 
1261
- var isObject$2 = isObject$9;
1266
+ var isObject$5 = isObject$c;
1262
1267
 
1263
1268
  var isPossiblePrototype$1 = function (argument) {
1264
- return isObject$2(argument) || argument === null;
1269
+ return isObject$5(argument) || argument === null;
1265
1270
  };
1266
1271
 
1267
1272
  var isPossiblePrototype = isPossiblePrototype$1;
1268
1273
 
1269
- var $String = String;
1270
- var $TypeError$6 = TypeError;
1274
+ var $String$1 = String;
1275
+ var $TypeError$9 = TypeError;
1271
1276
 
1272
1277
  var aPossiblePrototype$1 = function (argument) {
1273
1278
  if (isPossiblePrototype(argument)) return argument;
1274
- throw new $TypeError$6("Can't set " + $String(argument) + ' as a prototype');
1279
+ throw new $TypeError$9("Can't set " + $String$1(argument) + ' as a prototype');
1275
1280
  };
1276
1281
 
1277
1282
  /* eslint-disable no-proto -- safe */
1278
1283
  var uncurryThisAccessor = functionUncurryThisAccessor;
1279
- var anObject$5 = anObject$a;
1284
+ var isObject$4 = isObject$c;
1285
+ var requireObjectCoercible = requireObjectCoercible$3;
1280
1286
  var aPossiblePrototype = aPossiblePrototype$1;
1281
1287
 
1282
1288
  // `Object.setPrototypeOf` method
@@ -1293,33 +1299,34 @@ var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? functio
1293
1299
  CORRECT_SETTER = test instanceof Array;
1294
1300
  } catch (error) { /* empty */ }
1295
1301
  return function setPrototypeOf(O, proto) {
1296
- anObject$5(O);
1302
+ requireObjectCoercible(O);
1297
1303
  aPossiblePrototype(proto);
1304
+ if (!isObject$4(O)) return O;
1298
1305
  if (CORRECT_SETTER) setter(O, proto);
1299
1306
  else O.__proto__ = proto;
1300
1307
  return O;
1301
1308
  };
1302
1309
  }() : undefined);
1303
1310
 
1304
- var $$7 = _export;
1305
- var call$8 = functionCall;
1311
+ var $$e = _export;
1312
+ var call$b = functionCall;
1306
1313
  var FunctionName = functionName;
1307
- var isCallable$6 = isCallable$j;
1314
+ var isCallable$8 = isCallable$l;
1308
1315
  var createIteratorConstructor = iteratorCreateConstructor;
1309
- var getPrototypeOf = objectGetPrototypeOf;
1310
- var setPrototypeOf$1 = objectSetPrototypeOf;
1316
+ var getPrototypeOf$1 = objectGetPrototypeOf;
1317
+ var setPrototypeOf$3 = objectSetPrototypeOf;
1311
1318
  var setToStringTag$2 = setToStringTag$4;
1312
- var createNonEnumerableProperty$1 = createNonEnumerableProperty$4;
1313
- var defineBuiltIn$2 = defineBuiltIn$5;
1314
- var wellKnownSymbol$9 = wellKnownSymbol$e;
1319
+ var createNonEnumerableProperty$5 = createNonEnumerableProperty$8;
1320
+ var defineBuiltIn$3 = defineBuiltIn$6;
1321
+ var wellKnownSymbol$b = wellKnownSymbol$g;
1315
1322
  var Iterators$3 = iterators;
1316
1323
  var IteratorsCore = iteratorsCore;
1317
1324
 
1318
1325
  var PROPER_FUNCTION_NAME = FunctionName.PROPER;
1319
1326
  var CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE;
1320
- var IteratorPrototype = IteratorsCore.IteratorPrototype;
1327
+ var IteratorPrototype$2 = IteratorsCore.IteratorPrototype;
1321
1328
  var BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;
1322
- var ITERATOR$4 = wellKnownSymbol$9('iterator');
1329
+ var ITERATOR$5 = wellKnownSymbol$b('iterator');
1323
1330
  var KEYS = 'keys';
1324
1331
  var VALUES = 'values';
1325
1332
  var ENTRIES = 'entries';
@@ -1345,7 +1352,7 @@ var iteratorDefine = function (Iterable, NAME, IteratorConstructor, next, DEFAUL
1345
1352
  var TO_STRING_TAG = NAME + ' Iterator';
1346
1353
  var INCORRECT_VALUES_NAME = false;
1347
1354
  var IterablePrototype = Iterable.prototype;
1348
- var nativeIterator = IterablePrototype[ITERATOR$4]
1355
+ var nativeIterator = IterablePrototype[ITERATOR$5]
1349
1356
  || IterablePrototype['@@iterator']
1350
1357
  || DEFAULT && IterablePrototype[DEFAULT];
1351
1358
  var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);
@@ -1354,13 +1361,13 @@ var iteratorDefine = function (Iterable, NAME, IteratorConstructor, next, DEFAUL
1354
1361
 
1355
1362
  // fix native
1356
1363
  if (anyNativeIterator) {
1357
- CurrentIteratorPrototype = getPrototypeOf(anyNativeIterator.call(new Iterable()));
1364
+ CurrentIteratorPrototype = getPrototypeOf$1(anyNativeIterator.call(new Iterable()));
1358
1365
  if (CurrentIteratorPrototype !== Object.prototype && CurrentIteratorPrototype.next) {
1359
- if (getPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype) {
1360
- if (setPrototypeOf$1) {
1361
- setPrototypeOf$1(CurrentIteratorPrototype, IteratorPrototype);
1362
- } else if (!isCallable$6(CurrentIteratorPrototype[ITERATOR$4])) {
1363
- defineBuiltIn$2(CurrentIteratorPrototype, ITERATOR$4, returnThis);
1366
+ if (getPrototypeOf$1(CurrentIteratorPrototype) !== IteratorPrototype$2) {
1367
+ if (setPrototypeOf$3) {
1368
+ setPrototypeOf$3(CurrentIteratorPrototype, IteratorPrototype$2);
1369
+ } else if (!isCallable$8(CurrentIteratorPrototype[ITERATOR$5])) {
1370
+ defineBuiltIn$3(CurrentIteratorPrototype, ITERATOR$5, returnThis);
1364
1371
  }
1365
1372
  }
1366
1373
  // Set @@toStringTag to native iterators
@@ -1371,10 +1378,10 @@ var iteratorDefine = function (Iterable, NAME, IteratorConstructor, next, DEFAUL
1371
1378
  // fix Array.prototype.{ values, @@iterator }.name in V8 / FF
1372
1379
  if (PROPER_FUNCTION_NAME && DEFAULT === VALUES && nativeIterator && nativeIterator.name !== VALUES) {
1373
1380
  if (CONFIGURABLE_FUNCTION_NAME) {
1374
- createNonEnumerableProperty$1(IterablePrototype, 'name', VALUES);
1381
+ createNonEnumerableProperty$5(IterablePrototype, 'name', VALUES);
1375
1382
  } else {
1376
1383
  INCORRECT_VALUES_NAME = true;
1377
- defaultIterator = function values() { return call$8(nativeIterator, this); };
1384
+ defaultIterator = function values() { return call$b(nativeIterator, this); };
1378
1385
  }
1379
1386
  }
1380
1387
 
@@ -1387,14 +1394,14 @@ var iteratorDefine = function (Iterable, NAME, IteratorConstructor, next, DEFAUL
1387
1394
  };
1388
1395
  if (FORCED) for (KEY in methods) {
1389
1396
  if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {
1390
- defineBuiltIn$2(IterablePrototype, KEY, methods[KEY]);
1397
+ defineBuiltIn$3(IterablePrototype, KEY, methods[KEY]);
1391
1398
  }
1392
- } else $$7({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);
1399
+ } else $$e({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);
1393
1400
  }
1394
1401
 
1395
1402
  // define iterator
1396
- if (IterablePrototype[ITERATOR$4] !== defaultIterator) {
1397
- defineBuiltIn$2(IterablePrototype, ITERATOR$4, defaultIterator, { name: DEFAULT });
1403
+ if (IterablePrototype[ITERATOR$5] !== defaultIterator) {
1404
+ defineBuiltIn$3(IterablePrototype, ITERATOR$5, defaultIterator, { name: DEFAULT });
1398
1405
  }
1399
1406
  Iterators$3[NAME] = defaultIterator;
1400
1407
 
@@ -1403,22 +1410,22 @@ var iteratorDefine = function (Iterable, NAME, IteratorConstructor, next, DEFAUL
1403
1410
 
1404
1411
  // `CreateIterResultObject` abstract operation
1405
1412
  // https://tc39.es/ecma262/#sec-createiterresultobject
1406
- var createIterResultObject$1 = function (value, done) {
1413
+ var createIterResultObject$2 = function (value, done) {
1407
1414
  return { value: value, done: done };
1408
1415
  };
1409
1416
 
1410
1417
  var toIndexedObject = toIndexedObject$5;
1411
1418
  var addToUnscopables = addToUnscopables$1;
1412
1419
  var Iterators$2 = iterators;
1413
- var InternalStateModule$1 = internalState;
1414
- var defineProperty$2 = objectDefineProperty.f;
1420
+ var InternalStateModule$2 = internalState;
1421
+ var defineProperty$3 = objectDefineProperty.f;
1415
1422
  var defineIterator = iteratorDefine;
1416
- var createIterResultObject = createIterResultObject$1;
1417
- var DESCRIPTORS$3 = descriptors;
1423
+ var createIterResultObject$1 = createIterResultObject$2;
1424
+ var DESCRIPTORS$7 = descriptors;
1418
1425
 
1419
1426
  var ARRAY_ITERATOR = 'Array Iterator';
1420
- var setInternalState$1 = InternalStateModule$1.set;
1421
- var getInternalState = InternalStateModule$1.getterFor(ARRAY_ITERATOR);
1427
+ var setInternalState$2 = InternalStateModule$2.set;
1428
+ var getInternalState = InternalStateModule$2.getterFor(ARRAY_ITERATOR);
1422
1429
 
1423
1430
  // `Array.prototype.entries` method
1424
1431
  // https://tc39.es/ecma262/#sec-array.prototype.entries
@@ -1431,7 +1438,7 @@ var getInternalState = InternalStateModule$1.getterFor(ARRAY_ITERATOR);
1431
1438
  // `CreateArrayIterator` internal method
1432
1439
  // https://tc39.es/ecma262/#sec-createarrayiterator
1433
1440
  var es_array_iterator = defineIterator(Array, 'Array', function (iterated, kind) {
1434
- setInternalState$1(this, {
1441
+ setInternalState$2(this, {
1435
1442
  type: ARRAY_ITERATOR,
1436
1443
  target: toIndexedObject(iterated), // target
1437
1444
  index: 0, // next index
@@ -1445,12 +1452,12 @@ var es_array_iterator = defineIterator(Array, 'Array', function (iterated, kind)
1445
1452
  var index = state.index++;
1446
1453
  if (!target || index >= target.length) {
1447
1454
  state.target = undefined;
1448
- return createIterResultObject(undefined, true);
1455
+ return createIterResultObject$1(undefined, true);
1449
1456
  }
1450
1457
  switch (state.kind) {
1451
- case 'keys': return createIterResultObject(index, false);
1452
- case 'values': return createIterResultObject(target[index], false);
1453
- } return createIterResultObject([index, target[index]], false);
1458
+ case 'keys': return createIterResultObject$1(index, false);
1459
+ case 'values': return createIterResultObject$1(target[index], false);
1460
+ } return createIterResultObject$1([index, target[index]], false);
1454
1461
  }, 'values');
1455
1462
 
1456
1463
  // argumentsList[@@iterator] is %ArrayProto_values%
@@ -1464,111 +1471,618 @@ addToUnscopables('values');
1464
1471
  addToUnscopables('entries');
1465
1472
 
1466
1473
  // V8 ~ Chrome 45- bug
1467
- if (DESCRIPTORS$3 && values.name !== 'values') try {
1468
- defineProperty$2(values, 'name', { value: 'values' });
1474
+ if (DESCRIPTORS$7 && values.name !== 'values') try {
1475
+ defineProperty$3(values, 'name', { value: 'values' });
1469
1476
  } catch (error) { /* empty */ }
1470
1477
 
1471
- // iterable DOM collections
1472
- // flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods
1473
- var domIterables = {
1474
- CSSRuleList: 0,
1475
- CSSStyleDeclaration: 0,
1476
- CSSValueList: 0,
1477
- ClientRectList: 0,
1478
- DOMRectList: 0,
1479
- DOMStringList: 0,
1480
- DOMTokenList: 1,
1481
- DataTransferItemList: 0,
1482
- FileList: 0,
1483
- HTMLAllCollection: 0,
1484
- HTMLCollection: 0,
1485
- HTMLFormElement: 0,
1486
- HTMLSelectElement: 0,
1487
- MediaList: 0,
1488
- MimeTypeArray: 0,
1489
- NamedNodeMap: 0,
1490
- NodeList: 1,
1491
- PaintRequestList: 0,
1492
- Plugin: 0,
1493
- PluginArray: 0,
1494
- SVGLengthList: 0,
1495
- SVGNumberList: 0,
1496
- SVGPathSegList: 0,
1497
- SVGPointList: 0,
1498
- SVGStringList: 0,
1499
- SVGTransformList: 0,
1500
- SourceBufferList: 0,
1501
- StyleSheetList: 0,
1502
- TextTrackCueList: 0,
1503
- TextTrackList: 0,
1504
- TouchList: 0
1478
+ var isPrototypeOf$2 = objectIsPrototypeOf;
1479
+
1480
+ var $TypeError$8 = TypeError;
1481
+
1482
+ var anInstance$2 = function (it, Prototype) {
1483
+ if (isPrototypeOf$2(Prototype, it)) return it;
1484
+ throw new $TypeError$8('Incorrect invocation');
1505
1485
  };
1506
1486
 
1507
- // in old WebKit versions, `element.classList` is not an instance of global `DOMTokenList`
1508
- var documentCreateElement = documentCreateElement$2;
1487
+ var makeBuiltIn = makeBuiltInExports;
1488
+ var defineProperty$2 = objectDefineProperty;
1509
1489
 
1510
- var classList = documentCreateElement('span').classList;
1511
- var DOMTokenListPrototype$1 = classList && classList.constructor && classList.constructor.prototype;
1490
+ var defineBuiltInAccessor$2 = function (target, name, descriptor) {
1491
+ if (descriptor.get) makeBuiltIn(descriptor.get, name, { getter: true });
1492
+ if (descriptor.set) makeBuiltIn(descriptor.set, name, { setter: true });
1493
+ return defineProperty$2.f(target, name, descriptor);
1494
+ };
1512
1495
 
1513
- var domTokenListPrototype = DOMTokenListPrototype$1 === Object.prototype ? undefined : DOMTokenListPrototype$1;
1496
+ var DESCRIPTORS$6 = descriptors;
1497
+ var definePropertyModule = objectDefineProperty;
1498
+ var createPropertyDescriptor$1 = createPropertyDescriptor$5;
1514
1499
 
1515
- var global$8 = global$j;
1516
- var DOMIterables = domIterables;
1517
- var DOMTokenListPrototype = domTokenListPrototype;
1518
- var ArrayIteratorMethods = es_array_iterator;
1519
- var createNonEnumerableProperty = createNonEnumerableProperty$4;
1520
- var setToStringTag$1 = setToStringTag$4;
1521
- var wellKnownSymbol$8 = wellKnownSymbol$e;
1500
+ var createProperty$1 = function (object, key, value) {
1501
+ if (DESCRIPTORS$6) definePropertyModule.f(object, key, createPropertyDescriptor$1(0, value));
1502
+ else object[key] = value;
1503
+ };
1522
1504
 
1523
- var ITERATOR$3 = wellKnownSymbol$8('iterator');
1524
- var ArrayValues = ArrayIteratorMethods.values;
1505
+ var $$d = _export;
1506
+ var global$a = global$k;
1507
+ var anInstance$1 = anInstance$2;
1508
+ var anObject$a = anObject$f;
1509
+ var isCallable$7 = isCallable$l;
1510
+ var getPrototypeOf = objectGetPrototypeOf;
1511
+ var defineBuiltInAccessor$1 = defineBuiltInAccessor$2;
1512
+ var createProperty = createProperty$1;
1513
+ var fails$5 = fails$g;
1514
+ var hasOwn$2 = hasOwnProperty_1;
1515
+ var wellKnownSymbol$a = wellKnownSymbol$g;
1516
+ var IteratorPrototype$1 = iteratorsCore.IteratorPrototype;
1517
+ var DESCRIPTORS$5 = descriptors;
1525
1518
 
1526
- var handlePrototype = function (CollectionPrototype, COLLECTION_NAME) {
1527
- if (CollectionPrototype) {
1528
- // some Chrome versions have non-configurable methods on DOMTokenList
1529
- if (CollectionPrototype[ITERATOR$3] !== ArrayValues) try {
1530
- createNonEnumerableProperty(CollectionPrototype, ITERATOR$3, ArrayValues);
1531
- } catch (error) {
1532
- CollectionPrototype[ITERATOR$3] = ArrayValues;
1519
+ var CONSTRUCTOR = 'constructor';
1520
+ var ITERATOR$4 = 'Iterator';
1521
+ var TO_STRING_TAG$3 = wellKnownSymbol$a('toStringTag');
1522
+
1523
+ var $TypeError$7 = TypeError;
1524
+ var NativeIterator = global$a[ITERATOR$4];
1525
+
1526
+ // FF56- have non-standard global helper `Iterator`
1527
+ var FORCED$2 = !isCallable$7(NativeIterator)
1528
+ || NativeIterator.prototype !== IteratorPrototype$1
1529
+ // FF44- non-standard `Iterator` passes previous tests
1530
+ || !fails$5(function () { NativeIterator({}); });
1531
+
1532
+ var IteratorConstructor = function Iterator() {
1533
+ anInstance$1(this, IteratorPrototype$1);
1534
+ if (getPrototypeOf(this) === IteratorPrototype$1) throw new $TypeError$7('Abstract class Iterator not directly constructable');
1535
+ };
1536
+
1537
+ var defineIteratorPrototypeAccessor = function (key, value) {
1538
+ if (DESCRIPTORS$5) {
1539
+ defineBuiltInAccessor$1(IteratorPrototype$1, key, {
1540
+ configurable: true,
1541
+ get: function () {
1542
+ return value;
1543
+ },
1544
+ set: function (replacement) {
1545
+ anObject$a(this);
1546
+ if (this === IteratorPrototype$1) throw new $TypeError$7("You can't redefine this property");
1547
+ if (hasOwn$2(this, key)) this[key] = replacement;
1548
+ else createProperty(this, key, replacement);
1549
+ }
1550
+ });
1551
+ } else IteratorPrototype$1[key] = value;
1552
+ };
1553
+
1554
+ if (!hasOwn$2(IteratorPrototype$1, TO_STRING_TAG$3)) defineIteratorPrototypeAccessor(TO_STRING_TAG$3, ITERATOR$4);
1555
+
1556
+ if (FORCED$2 || !hasOwn$2(IteratorPrototype$1, CONSTRUCTOR) || IteratorPrototype$1[CONSTRUCTOR] === Object) {
1557
+ defineIteratorPrototypeAccessor(CONSTRUCTOR, IteratorConstructor);
1558
+ }
1559
+
1560
+ IteratorConstructor.prototype = IteratorPrototype$1;
1561
+
1562
+ // `Iterator` constructor
1563
+ // https://github.com/tc39/proposal-iterator-helpers
1564
+ $$d({ global: true, constructor: true, forced: FORCED$2 }, {
1565
+ Iterator: IteratorConstructor
1566
+ });
1567
+
1568
+ // `GetIteratorDirect(obj)` abstract operation
1569
+ // https://tc39.es/proposal-iterator-helpers/#sec-getiteratordirect
1570
+ var getIteratorDirect$4 = function (obj) {
1571
+ return {
1572
+ iterator: obj,
1573
+ next: obj.next,
1574
+ done: false
1575
+ };
1576
+ };
1577
+
1578
+ var defineBuiltIn$2 = defineBuiltIn$6;
1579
+
1580
+ var defineBuiltIns$1 = function (target, src, options) {
1581
+ for (var key in src) defineBuiltIn$2(target, key, src[key], options);
1582
+ return target;
1583
+ };
1584
+
1585
+ var call$a = functionCall;
1586
+ var anObject$9 = anObject$f;
1587
+ var getMethod$2 = getMethod$4;
1588
+
1589
+ var iteratorClose$3 = function (iterator, kind, value) {
1590
+ var innerResult, innerError;
1591
+ anObject$9(iterator);
1592
+ try {
1593
+ innerResult = getMethod$2(iterator, 'return');
1594
+ if (!innerResult) {
1595
+ if (kind === 'throw') throw value;
1596
+ return value;
1533
1597
  }
1534
- setToStringTag$1(CollectionPrototype, COLLECTION_NAME, true);
1535
- if (DOMIterables[COLLECTION_NAME]) for (var METHOD_NAME in ArrayIteratorMethods) {
1536
- // some Chrome versions have non-configurable methods on DOMTokenList
1537
- if (CollectionPrototype[METHOD_NAME] !== ArrayIteratorMethods[METHOD_NAME]) try {
1538
- createNonEnumerableProperty(CollectionPrototype, METHOD_NAME, ArrayIteratorMethods[METHOD_NAME]);
1598
+ innerResult = call$a(innerResult, iterator);
1599
+ } catch (error) {
1600
+ innerError = true;
1601
+ innerResult = error;
1602
+ }
1603
+ if (kind === 'throw') throw value;
1604
+ if (innerError) throw innerResult;
1605
+ anObject$9(innerResult);
1606
+ return value;
1607
+ };
1608
+
1609
+ var call$9 = functionCall;
1610
+ var create = objectCreate;
1611
+ var createNonEnumerableProperty$4 = createNonEnumerableProperty$8;
1612
+ var defineBuiltIns = defineBuiltIns$1;
1613
+ var wellKnownSymbol$9 = wellKnownSymbol$g;
1614
+ var InternalStateModule$1 = internalState;
1615
+ var getMethod$1 = getMethod$4;
1616
+ var IteratorPrototype = iteratorsCore.IteratorPrototype;
1617
+ var createIterResultObject = createIterResultObject$2;
1618
+ var iteratorClose$2 = iteratorClose$3;
1619
+
1620
+ var TO_STRING_TAG$2 = wellKnownSymbol$9('toStringTag');
1621
+ var ITERATOR_HELPER = 'IteratorHelper';
1622
+ var WRAP_FOR_VALID_ITERATOR = 'WrapForValidIterator';
1623
+ var setInternalState$1 = InternalStateModule$1.set;
1624
+
1625
+ var createIteratorProxyPrototype = function (IS_ITERATOR) {
1626
+ var getInternalState = InternalStateModule$1.getterFor(IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER);
1627
+
1628
+ return defineBuiltIns(create(IteratorPrototype), {
1629
+ next: function next() {
1630
+ var state = getInternalState(this);
1631
+ // for simplification:
1632
+ // for `%WrapForValidIteratorPrototype%.next` our `nextHandler` returns `IterResultObject`
1633
+ // for `%IteratorHelperPrototype%.next` - just a value
1634
+ if (IS_ITERATOR) return state.nextHandler();
1635
+ try {
1636
+ var result = state.done ? undefined : state.nextHandler();
1637
+ return createIterResultObject(result, state.done);
1539
1638
  } catch (error) {
1540
- CollectionPrototype[METHOD_NAME] = ArrayIteratorMethods[METHOD_NAME];
1639
+ state.done = true;
1640
+ throw error;
1641
+ }
1642
+ },
1643
+ 'return': function () {
1644
+ var state = getInternalState(this);
1645
+ var iterator = state.iterator;
1646
+ state.done = true;
1647
+ if (IS_ITERATOR) {
1648
+ var returnMethod = getMethod$1(iterator, 'return');
1649
+ return returnMethod ? call$9(returnMethod, iterator) : createIterResultObject(undefined, true);
1650
+ }
1651
+ if (state.inner) try {
1652
+ iteratorClose$2(state.inner.iterator, 'normal');
1653
+ } catch (error) {
1654
+ return iteratorClose$2(iterator, 'throw', error);
1541
1655
  }
1656
+ iteratorClose$2(iterator, 'normal');
1657
+ return createIterResultObject(undefined, true);
1542
1658
  }
1543
- }
1659
+ });
1544
1660
  };
1545
1661
 
1546
- for (var COLLECTION_NAME in DOMIterables) {
1547
- handlePrototype(global$8[COLLECTION_NAME] && global$8[COLLECTION_NAME].prototype, COLLECTION_NAME);
1548
- }
1662
+ var WrapForValidIteratorPrototype = createIteratorProxyPrototype(true);
1663
+ var IteratorHelperPrototype = createIteratorProxyPrototype(false);
1549
1664
 
1550
- handlePrototype(DOMTokenListPrototype, 'DOMTokenList');
1665
+ createNonEnumerableProperty$4(IteratorHelperPrototype, TO_STRING_TAG$2, 'Iterator Helper');
1551
1666
 
1552
- function asObservable(valueOrObs) {
1553
- if (rxjs.isObservable(valueOrObs)) {
1554
- return valueOrObs;
1555
- } else {
1556
- return rxjs.of(valueOrObs);
1667
+ var iteratorCreateProxy = function (nextHandler, IS_ITERATOR) {
1668
+ var IteratorProxy = function Iterator(record, state) {
1669
+ if (state) {
1670
+ state.iterator = record.iterator;
1671
+ state.next = record.next;
1672
+ } else state = record;
1673
+ state.type = IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER;
1674
+ state.nextHandler = nextHandler;
1675
+ state.counter = 0;
1676
+ state.done = false;
1677
+ setInternalState$1(this, state);
1678
+ };
1679
+
1680
+ IteratorProxy.prototype = IS_ITERATOR ? WrapForValidIteratorPrototype : IteratorHelperPrototype;
1681
+
1682
+ return IteratorProxy;
1683
+ };
1684
+
1685
+ var anObject$8 = anObject$f;
1686
+ var iteratorClose$1 = iteratorClose$3;
1687
+
1688
+ // call something on iterator step with safe closing on error
1689
+ var callWithSafeIterationClosing$2 = function (iterator, fn, value, ENTRIES) {
1690
+ try {
1691
+ return ENTRIES ? fn(anObject$8(value)[0], value[1]) : fn(value);
1692
+ } catch (error) {
1693
+ iteratorClose$1(iterator, 'throw', error);
1557
1694
  }
1695
+ };
1696
+
1697
+ var $$c = _export;
1698
+ var call$8 = functionCall;
1699
+ var aCallable$9 = aCallable$c;
1700
+ var anObject$7 = anObject$f;
1701
+ var getIteratorDirect$3 = getIteratorDirect$4;
1702
+ var createIteratorProxy$1 = iteratorCreateProxy;
1703
+ var callWithSafeIterationClosing$1 = callWithSafeIterationClosing$2;
1704
+ var IS_PURE$1 = isPure;
1705
+
1706
+ var IteratorProxy$1 = createIteratorProxy$1(function () {
1707
+ var iterator = this.iterator;
1708
+ var predicate = this.predicate;
1709
+ var next = this.next;
1710
+ var result, done, value;
1711
+ while (true) {
1712
+ result = anObject$7(call$8(next, iterator));
1713
+ done = this.done = !!result.done;
1714
+ if (done) return;
1715
+ value = result.value;
1716
+ if (callWithSafeIterationClosing$1(iterator, predicate, [value, this.counter++], true)) return value;
1717
+ }
1718
+ });
1719
+
1720
+ // `Iterator.prototype.filter` method
1721
+ // https://github.com/tc39/proposal-iterator-helpers
1722
+ $$c({ target: 'Iterator', proto: true, real: true, forced: IS_PURE$1 }, {
1723
+ filter: function filter(predicate) {
1724
+ anObject$7(this);
1725
+ aCallable$9(predicate);
1726
+ return new IteratorProxy$1(getIteratorDirect$3(this), {
1727
+ predicate: predicate
1728
+ });
1729
+ }
1730
+ });
1731
+
1732
+ var classofRaw$1 = classofRaw$2;
1733
+ var uncurryThis$5 = functionUncurryThis;
1734
+
1735
+ var functionUncurryThisClause = function (fn) {
1736
+ // Nashorn bug:
1737
+ // https://github.com/zloirock/core-js/issues/1128
1738
+ // https://github.com/zloirock/core-js/issues/1130
1739
+ if (classofRaw$1(fn) === 'Function') return uncurryThis$5(fn);
1740
+ };
1741
+
1742
+ var uncurryThis$4 = functionUncurryThisClause;
1743
+ var aCallable$8 = aCallable$c;
1744
+ var NATIVE_BIND$1 = functionBindNative;
1745
+
1746
+ var bind$4 = uncurryThis$4(uncurryThis$4.bind);
1747
+
1748
+ // optional / simple context binding
1749
+ var functionBindContext = function (fn, that) {
1750
+ aCallable$8(fn);
1751
+ return that === undefined ? fn : NATIVE_BIND$1 ? bind$4(fn, that) : function (/* ...args */) {
1752
+ return fn.apply(that, arguments);
1753
+ };
1754
+ };
1755
+
1756
+ var wellKnownSymbol$8 = wellKnownSymbol$g;
1757
+ var Iterators$1 = iterators;
1758
+
1759
+ var ITERATOR$3 = wellKnownSymbol$8('iterator');
1760
+ var ArrayPrototype = Array.prototype;
1761
+
1762
+ // check on default Array iterator
1763
+ var isArrayIteratorMethod$1 = function (it) {
1764
+ return it !== undefined && (Iterators$1.Array === it || ArrayPrototype[ITERATOR$3] === it);
1765
+ };
1766
+
1767
+ var wellKnownSymbol$7 = wellKnownSymbol$g;
1768
+
1769
+ var TO_STRING_TAG$1 = wellKnownSymbol$7('toStringTag');
1770
+ var test = {};
1771
+
1772
+ test[TO_STRING_TAG$1] = 'z';
1773
+
1774
+ var toStringTagSupport = String(test) === '[object z]';
1775
+
1776
+ var TO_STRING_TAG_SUPPORT = toStringTagSupport;
1777
+ var isCallable$6 = isCallable$l;
1778
+ var classofRaw = classofRaw$2;
1779
+ var wellKnownSymbol$6 = wellKnownSymbol$g;
1780
+
1781
+ var TO_STRING_TAG = wellKnownSymbol$6('toStringTag');
1782
+ var $Object = Object;
1783
+
1784
+ // ES3 wrong here
1785
+ var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) === 'Arguments';
1786
+
1787
+ // fallback for IE11 Script Access Denied error
1788
+ var tryGet = function (it, key) {
1789
+ try {
1790
+ return it[key];
1791
+ } catch (error) { /* empty */ }
1792
+ };
1793
+
1794
+ // getting tag from ES6+ `Object.prototype.toString`
1795
+ var classof$5 = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {
1796
+ var O, tag, result;
1797
+ return it === undefined ? 'Undefined' : it === null ? 'Null'
1798
+ // @@toStringTag case
1799
+ : typeof (tag = tryGet(O = $Object(it), TO_STRING_TAG)) == 'string' ? tag
1800
+ // builtinTag case
1801
+ : CORRECT_ARGUMENTS ? classofRaw(O)
1802
+ // ES3 arguments fallback
1803
+ : (result = classofRaw(O)) === 'Object' && isCallable$6(O.callee) ? 'Arguments' : result;
1804
+ };
1805
+
1806
+ var classof$4 = classof$5;
1807
+ var getMethod = getMethod$4;
1808
+ var isNullOrUndefined$1 = isNullOrUndefined$4;
1809
+ var Iterators = iterators;
1810
+ var wellKnownSymbol$5 = wellKnownSymbol$g;
1811
+
1812
+ var ITERATOR$2 = wellKnownSymbol$5('iterator');
1813
+
1814
+ var getIteratorMethod$2 = function (it) {
1815
+ if (!isNullOrUndefined$1(it)) return getMethod(it, ITERATOR$2)
1816
+ || getMethod(it, '@@iterator')
1817
+ || Iterators[classof$4(it)];
1818
+ };
1819
+
1820
+ var call$7 = functionCall;
1821
+ var aCallable$7 = aCallable$c;
1822
+ var anObject$6 = anObject$f;
1823
+ var tryToString$2 = tryToString$4;
1824
+ var getIteratorMethod$1 = getIteratorMethod$2;
1825
+
1826
+ var $TypeError$6 = TypeError;
1827
+
1828
+ var getIterator$1 = function (argument, usingIterator) {
1829
+ var iteratorMethod = arguments.length < 2 ? getIteratorMethod$1(argument) : usingIterator;
1830
+ if (aCallable$7(iteratorMethod)) return anObject$6(call$7(iteratorMethod, argument));
1831
+ throw new $TypeError$6(tryToString$2(argument) + ' is not iterable');
1832
+ };
1833
+
1834
+ var bind$3 = functionBindContext;
1835
+ var call$6 = functionCall;
1836
+ var anObject$5 = anObject$f;
1837
+ var tryToString$1 = tryToString$4;
1838
+ var isArrayIteratorMethod = isArrayIteratorMethod$1;
1839
+ var lengthOfArrayLike$1 = lengthOfArrayLike$3;
1840
+ var isPrototypeOf$1 = objectIsPrototypeOf;
1841
+ var getIterator = getIterator$1;
1842
+ var getIteratorMethod = getIteratorMethod$2;
1843
+ var iteratorClose = iteratorClose$3;
1844
+
1845
+ var $TypeError$5 = TypeError;
1846
+
1847
+ var Result = function (stopped, result) {
1848
+ this.stopped = stopped;
1849
+ this.result = result;
1850
+ };
1851
+
1852
+ var ResultPrototype = Result.prototype;
1853
+
1854
+ var iterate$4 = function (iterable, unboundFunction, options) {
1855
+ var that = options && options.that;
1856
+ var AS_ENTRIES = !!(options && options.AS_ENTRIES);
1857
+ var IS_RECORD = !!(options && options.IS_RECORD);
1858
+ var IS_ITERATOR = !!(options && options.IS_ITERATOR);
1859
+ var INTERRUPTED = !!(options && options.INTERRUPTED);
1860
+ var fn = bind$3(unboundFunction, that);
1861
+ var iterator, iterFn, index, length, result, next, step;
1862
+
1863
+ var stop = function (condition) {
1864
+ if (iterator) iteratorClose(iterator, 'normal', condition);
1865
+ return new Result(true, condition);
1866
+ };
1867
+
1868
+ var callFn = function (value) {
1869
+ if (AS_ENTRIES) {
1870
+ anObject$5(value);
1871
+ return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);
1872
+ } return INTERRUPTED ? fn(value, stop) : fn(value);
1873
+ };
1874
+
1875
+ if (IS_RECORD) {
1876
+ iterator = iterable.iterator;
1877
+ } else if (IS_ITERATOR) {
1878
+ iterator = iterable;
1879
+ } else {
1880
+ iterFn = getIteratorMethod(iterable);
1881
+ if (!iterFn) throw new $TypeError$5(tryToString$1(iterable) + ' is not iterable');
1882
+ // optimisation for array iterators
1883
+ if (isArrayIteratorMethod(iterFn)) {
1884
+ for (index = 0, length = lengthOfArrayLike$1(iterable); length > index; index++) {
1885
+ result = callFn(iterable[index]);
1886
+ if (result && isPrototypeOf$1(ResultPrototype, result)) return result;
1887
+ } return new Result(false);
1888
+ }
1889
+ iterator = getIterator(iterable, iterFn);
1890
+ }
1891
+
1892
+ next = IS_RECORD ? iterable.next : iterator.next;
1893
+ while (!(step = call$6(next, iterator)).done) {
1894
+ try {
1895
+ result = callFn(step.value);
1896
+ } catch (error) {
1897
+ iteratorClose(iterator, 'throw', error);
1898
+ }
1899
+ if (typeof result == 'object' && result && isPrototypeOf$1(ResultPrototype, result)) return result;
1900
+ } return new Result(false);
1901
+ };
1902
+
1903
+ var $$b = _export;
1904
+ var iterate$3 = iterate$4;
1905
+ var aCallable$6 = aCallable$c;
1906
+ var anObject$4 = anObject$f;
1907
+ var getIteratorDirect$2 = getIteratorDirect$4;
1908
+
1909
+ // `Iterator.prototype.find` method
1910
+ // https://github.com/tc39/proposal-iterator-helpers
1911
+ $$b({ target: 'Iterator', proto: true, real: true }, {
1912
+ find: function find(predicate) {
1913
+ anObject$4(this);
1914
+ aCallable$6(predicate);
1915
+ var record = getIteratorDirect$2(this);
1916
+ var counter = 0;
1917
+ return iterate$3(record, function (value, stop) {
1918
+ if (predicate(value, counter++)) return stop(value);
1919
+ }, { IS_RECORD: true, INTERRUPTED: true }).result;
1920
+ }
1921
+ });
1922
+
1923
+ var $$a = _export;
1924
+ var iterate$2 = iterate$4;
1925
+ var aCallable$5 = aCallable$c;
1926
+ var anObject$3 = anObject$f;
1927
+ var getIteratorDirect$1 = getIteratorDirect$4;
1928
+
1929
+ // `Iterator.prototype.forEach` method
1930
+ // https://github.com/tc39/proposal-iterator-helpers
1931
+ $$a({ target: 'Iterator', proto: true, real: true }, {
1932
+ forEach: function forEach(fn) {
1933
+ anObject$3(this);
1934
+ aCallable$5(fn);
1935
+ var record = getIteratorDirect$1(this);
1936
+ var counter = 0;
1937
+ iterate$2(record, function (value) {
1938
+ fn(value, counter++);
1939
+ }, { IS_RECORD: true });
1940
+ }
1941
+ });
1942
+
1943
+ var call$5 = functionCall;
1944
+ var aCallable$4 = aCallable$c;
1945
+ var anObject$2 = anObject$f;
1946
+ var getIteratorDirect = getIteratorDirect$4;
1947
+ var createIteratorProxy = iteratorCreateProxy;
1948
+ var callWithSafeIterationClosing = callWithSafeIterationClosing$2;
1949
+
1950
+ var IteratorProxy = createIteratorProxy(function () {
1951
+ var iterator = this.iterator;
1952
+ var result = anObject$2(call$5(this.next, iterator));
1953
+ var done = this.done = !!result.done;
1954
+ if (!done) return callWithSafeIterationClosing(iterator, this.mapper, [result.value, this.counter++], true);
1955
+ });
1956
+
1957
+ // `Iterator.prototype.map` method
1958
+ // https://github.com/tc39/proposal-iterator-helpers
1959
+ var iteratorMap = function map(mapper) {
1960
+ anObject$2(this);
1961
+ aCallable$4(mapper);
1962
+ return new IteratorProxy(getIteratorDirect(this), {
1963
+ mapper: mapper
1964
+ });
1965
+ };
1966
+
1967
+ var $$9 = _export;
1968
+ var map = iteratorMap;
1969
+ var IS_PURE = isPure;
1970
+
1971
+ // `Iterator.prototype.map` method
1972
+ // https://github.com/tc39/proposal-iterator-helpers
1973
+ $$9({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, {
1974
+ map: map
1975
+ });
1976
+
1977
+ // iterable DOM collections
1978
+ // flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods
1979
+ var domIterables = {
1980
+ CSSRuleList: 0,
1981
+ CSSStyleDeclaration: 0,
1982
+ CSSValueList: 0,
1983
+ ClientRectList: 0,
1984
+ DOMRectList: 0,
1985
+ DOMStringList: 0,
1986
+ DOMTokenList: 1,
1987
+ DataTransferItemList: 0,
1988
+ FileList: 0,
1989
+ HTMLAllCollection: 0,
1990
+ HTMLCollection: 0,
1991
+ HTMLFormElement: 0,
1992
+ HTMLSelectElement: 0,
1993
+ MediaList: 0,
1994
+ MimeTypeArray: 0,
1995
+ NamedNodeMap: 0,
1996
+ NodeList: 1,
1997
+ PaintRequestList: 0,
1998
+ Plugin: 0,
1999
+ PluginArray: 0,
2000
+ SVGLengthList: 0,
2001
+ SVGNumberList: 0,
2002
+ SVGPathSegList: 0,
2003
+ SVGPointList: 0,
2004
+ SVGStringList: 0,
2005
+ SVGTransformList: 0,
2006
+ SourceBufferList: 0,
2007
+ StyleSheetList: 0,
2008
+ TextTrackCueList: 0,
2009
+ TextTrackList: 0,
2010
+ TouchList: 0
2011
+ };
2012
+
2013
+ // in old WebKit versions, `element.classList` is not an instance of global `DOMTokenList`
2014
+ var documentCreateElement = documentCreateElement$2;
2015
+
2016
+ var classList = documentCreateElement('span').classList;
2017
+ var DOMTokenListPrototype$1 = classList && classList.constructor && classList.constructor.prototype;
2018
+
2019
+ var domTokenListPrototype = DOMTokenListPrototype$1 === Object.prototype ? undefined : DOMTokenListPrototype$1;
2020
+
2021
+ var global$9 = global$k;
2022
+ var DOMIterables = domIterables;
2023
+ var DOMTokenListPrototype = domTokenListPrototype;
2024
+ var ArrayIteratorMethods = es_array_iterator;
2025
+ var createNonEnumerableProperty$3 = createNonEnumerableProperty$8;
2026
+ var setToStringTag$1 = setToStringTag$4;
2027
+ var wellKnownSymbol$4 = wellKnownSymbol$g;
2028
+
2029
+ var ITERATOR$1 = wellKnownSymbol$4('iterator');
2030
+ var ArrayValues = ArrayIteratorMethods.values;
2031
+
2032
+ var handlePrototype = function (CollectionPrototype, COLLECTION_NAME) {
2033
+ if (CollectionPrototype) {
2034
+ // some Chrome versions have non-configurable methods on DOMTokenList
2035
+ if (CollectionPrototype[ITERATOR$1] !== ArrayValues) try {
2036
+ createNonEnumerableProperty$3(CollectionPrototype, ITERATOR$1, ArrayValues);
2037
+ } catch (error) {
2038
+ CollectionPrototype[ITERATOR$1] = ArrayValues;
2039
+ }
2040
+ setToStringTag$1(CollectionPrototype, COLLECTION_NAME, true);
2041
+ if (DOMIterables[COLLECTION_NAME]) for (var METHOD_NAME in ArrayIteratorMethods) {
2042
+ // some Chrome versions have non-configurable methods on DOMTokenList
2043
+ if (CollectionPrototype[METHOD_NAME] !== ArrayIteratorMethods[METHOD_NAME]) try {
2044
+ createNonEnumerableProperty$3(CollectionPrototype, METHOD_NAME, ArrayIteratorMethods[METHOD_NAME]);
2045
+ } catch (error) {
2046
+ CollectionPrototype[METHOD_NAME] = ArrayIteratorMethods[METHOD_NAME];
2047
+ }
2048
+ }
2049
+ }
2050
+ };
2051
+
2052
+ for (var COLLECTION_NAME in DOMIterables) {
2053
+ handlePrototype(global$9[COLLECTION_NAME] && global$9[COLLECTION_NAME].prototype, COLLECTION_NAME);
2054
+ }
2055
+
2056
+ handlePrototype(DOMTokenListPrototype, 'DOMTokenList');
2057
+
2058
+ function asObservable(valueOrObs) {
2059
+ if (rxjs.isObservable(valueOrObs)) {
2060
+ return valueOrObs;
2061
+ } else {
2062
+ return rxjs.of(valueOrObs);
2063
+ }
2064
+ }
2065
+ /**
2066
+ * Switch map for an ObservableGetter that pipes through the value.
2067
+ *
2068
+ * @returns OperatorFunction<ObservableOrValue<T>, T>
2069
+ */
2070
+ function valueFromObservableOrValue() {
2071
+ return rxjs.switchMap(x => asObservable(x));
2072
+ }
2073
+ /**
2074
+ * Switch map for an ObservableGetter that pipes through the Maybe value.
2075
+ *
2076
+ * @returns OperatorFunction<Maybe<ObservableOrValue<T>>, Maybe<T>>
2077
+ */
2078
+ function maybeValueFromObservableOrValue() {
2079
+ return rxjs.switchMap(x => x != null ? asObservable(x) : rxjs.of(undefined));
2080
+ }
2081
+ function asObservableFromGetter(input, args) {
2082
+ const obs = util.getValueFromGetter(input, args);
2083
+ return asObservable(obs);
1558
2084
  }
1559
2085
  /**
1560
- * Switch map for an ObservableGetter that pipes through the value.
1561
- *
1562
- * @returns
1563
- */
1564
- function valueFromObservableOrValue() {
1565
- return rxjs.switchMap(x => asObservable(x));
1566
- }
1567
- function asObservableFromGetter(input, args) {
1568
- const obs = util.getValueFromGetter(input, args);
1569
- return asObservable(obs);
1570
- }
1571
- /**
1572
2086
  * Switch map for an ObservableOrValueGetter that pipes through the value.
1573
2087
  *
1574
2088
  * @returns
@@ -1583,6 +2097,31 @@ function useAsObservable(input, observer) {
1583
2097
  return asObservable(input).subscribe(observer);
1584
2098
  }
1585
2099
 
2100
+ /**
2101
+ * Creates an IsModifiedFunction from an IsEqualFunction, or from IsModifiedFunctionInput.
2102
+ *
2103
+ * @param isEqualFunction
2104
+ */
2105
+ function makeIsModifiedFunction(isEqualFunction) {
2106
+ return value => isEqualFunction(value).pipe(rxjs.map(x => !x));
2107
+ }
2108
+ /**
2109
+ * Creates an Observable<IsModifiedFunction> from the input config.
2110
+ *
2111
+ * @param config MakeIsModifiedFunctionObservableConfig.
2112
+ * @returns Observable<IsModifiedFunction<T>>
2113
+ */
2114
+ function makeIsModifiedFunctionObservable(config) {
2115
+ const {
2116
+ isModified,
2117
+ isEqual,
2118
+ defaultFunction
2119
+ } = config;
2120
+ return rxjs.combineLatest([asObservable(isModified), asObservable(isEqual)]).pipe(rxjs.map(([isModified, isEqual]) => {
2121
+ var _ref, _ref2;
2122
+ return (_ref = (_ref2 = isModified != null ? isModified : isEqual ? makeIsModifiedFunction(isEqual) : undefined) != null ? _ref2 : defaultFunction) != null ? _ref : () => rxjs.of(true);
2123
+ }));
2124
+ }
1586
2125
  // MARK: IsCheck
1587
2126
  function makeReturnIfIsFunction(isCheckFunction, defaultValueOnMaybe) {
1588
2127
  return value => returnIfIs(isCheckFunction, value, defaultValueOnMaybe);
@@ -1677,16 +2216,27 @@ function switchMapOnBoolean(switchOnValue, obs, otherwise) {
1677
2216
  });
1678
2217
  }
1679
2218
  /**
1680
- * Combines both filterMaybe and switchMap to build a subscriber that emits only concrete values.
2219
+ * Combines both filterMaybe and switchMap to build a subscriber that emits values only from a concrete Observable, filtering out null/undefined Observables.
1681
2220
  *
1682
2221
  * @returns
1683
2222
  */
1684
- function switchMapMaybeObs() {
2223
+ function switchMapFilterMaybe() {
1685
2224
  return source => {
1686
2225
  const subscriber = source.pipe(filterMaybe(), rxjs.switchMap(x => x));
1687
2226
  return subscriber;
1688
2227
  };
1689
2228
  }
2229
+ /**
2230
+ * Converts a Maybe<Observable<Maybe<T>>> to an Observable<Maybe<T>> that emits null/undefined if the input observable is also null/undefined.
2231
+ *
2232
+ * @returns
2233
+ */
2234
+ function switchMapMaybe() {
2235
+ return source => {
2236
+ const subscriber = source.pipe(rxjs.switchMap(x => x != null ? x : rxjs.of(undefined)));
2237
+ return subscriber;
2238
+ };
2239
+ }
1690
2240
  /**
1691
2241
  * Performs the input map function on the input if it is not null/undefined.
1692
2242
  *
@@ -1753,7 +2303,7 @@ function filterIfObjectValuesUnchanged(input) {
1753
2303
  }
1754
2304
 
1755
2305
  /**
1756
- * Destroyable object that wraps a subscription.
2306
+ * Destroyable object that wraps an Unsubscribable.
1757
2307
  */
1758
2308
  class SubscriptionObject {
1759
2309
  constructor(sub) {
@@ -1820,20 +2370,37 @@ class MultiSubscriptionObject {
1820
2370
  * A basic FilterSource implementation.
1821
2371
  */
1822
2372
  class FilterSourceInstance {
1823
- constructor() {
2373
+ constructor(config) {
1824
2374
  this._initialFilterSub = new SubscriptionObject();
1825
2375
  this._initialFilterTakesPriority = new rxjs.BehaviorSubject(false);
1826
2376
  this._filter = new rxjs.BehaviorSubject(undefined);
2377
+ /**
2378
+ * The initial filter can only pass through observables that always emit a value.
2379
+ */
1827
2380
  this._initialFilter = new rxjs.BehaviorSubject(undefined);
1828
2381
  this._defaultFilter = new rxjs.BehaviorSubject(undefined);
1829
- this.defaultFilter$ = this._defaultFilter.pipe(switchMapMaybeObs());
1830
- this.initialFilter$ = rxjs.combineLatest([this._initialFilter, this._defaultFilter]).pipe(rxjs.map(([a, b]) => a != null ? a : b), switchMapMaybeObs(), rxjs.distinctUntilChanged(), rxjs.shareReplay(1));
2382
+ this.defaultFilter$ = this._defaultFilter.pipe(switchMapFilterMaybe());
2383
+ this.initialFilter$ = rxjs.combineLatest([this._initialFilter, this._defaultFilter]).pipe(rxjs.map(([a, b]) => a != null ? a : b), switchMapFilterMaybe(), rxjs.distinctUntilChanged(), rxjs.shareReplay(1));
1831
2384
  /**
1832
2385
  * filter$ uses the latest value from any filter.
1833
2386
  */
1834
2387
  this.filter$ = this._filter.pipe(rxjs.switchMap(x => x != null ? rxjs.of(x) : this.initialFilter$), filterMaybe(),
1835
2388
  // Only provided non-maybe filter values.
1836
2389
  distinctUntilObjectValuesChanged(), rxjs.shareReplay(1));
2390
+ const {
2391
+ initWithFilter,
2392
+ defaultFilter,
2393
+ filter
2394
+ } = config != null ? config : {};
2395
+ if (initWithFilter != null) {
2396
+ this.initWithFilter(initWithFilter);
2397
+ }
2398
+ if (defaultFilter != null) {
2399
+ this.setDefaultFilter(defaultFilter);
2400
+ }
2401
+ if (filter != null) {
2402
+ this.setFilter(filter);
2403
+ }
1837
2404
  }
1838
2405
  initWithFilter(filterObs) {
1839
2406
  this._initialFilter.next(filterObs);
@@ -1852,10 +2419,7 @@ class FilterSourceInstance {
1852
2419
  this._filter.next(undefined);
1853
2420
  }
1854
2421
  // MARK: Accessors
1855
- get initialFilterTakesPriority() {
1856
- return this._initialFilterTakesPriority.value;
1857
- }
1858
- set initialFilterTakesPriority(initialFilterTakesPriority) {
2422
+ setInitialFilterTakesPriority(initialFilterTakesPriority) {
1859
2423
  this._initialFilterTakesPriority.next(initialFilterTakesPriority);
1860
2424
  this.initFilterTakesPriority();
1861
2425
  }
@@ -1884,6 +2448,13 @@ class FilterSourceInstance {
1884
2448
  this._initialFilter.complete();
1885
2449
  this._defaultFilter.complete();
1886
2450
  }
2451
+ // MARK: Compat
2452
+ /**
2453
+ * @deprecated use setInitialFilterTakesPriority instead.
2454
+ */
2455
+ set initialFilterTakesPriority(initialFilterTakesPriority) {
2456
+ this.setInitialFilterTakesPriority(initialFilterTakesPriority);
2457
+ }
1887
2458
  }
1888
2459
 
1889
2460
  /**
@@ -2034,97 +2605,269 @@ class PresetFilterSource extends FilterSource {}
2034
2605
  */
2035
2606
  class FilterSourceConnector {}
2036
2607
 
2037
- var global$7 = global$j;
2038
- var classof$3 = classofRaw$2;
2608
+ var NATIVE_BIND = functionBindNative;
2609
+
2610
+ var FunctionPrototype = Function.prototype;
2611
+ var apply$2 = FunctionPrototype.apply;
2612
+ var call$4 = FunctionPrototype.call;
2039
2613
 
2040
- var engineIsNode = classof$3(global$7.process) === 'process';
2614
+ // eslint-disable-next-line es/no-reflect -- safe
2615
+ var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call$4.bind(apply$2) : function () {
2616
+ return call$4.apply(apply$2, arguments);
2617
+ });
2041
2618
 
2042
- var makeBuiltIn = makeBuiltIn$3.exports;
2043
- var defineProperty$1 = objectDefineProperty;
2619
+ var defineProperty$1 = objectDefineProperty.f;
2044
2620
 
2045
- var defineBuiltInAccessor$1 = function (target, name, descriptor) {
2046
- if (descriptor.get) makeBuiltIn(descriptor.get, name, { getter: true });
2047
- if (descriptor.set) makeBuiltIn(descriptor.set, name, { setter: true });
2048
- return defineProperty$1.f(target, name, descriptor);
2621
+ var proxyAccessor$1 = function (Target, Source, key) {
2622
+ key in Target || defineProperty$1(Target, key, {
2623
+ configurable: true,
2624
+ get: function () { return Source[key]; },
2625
+ set: function (it) { Source[key] = it; }
2626
+ });
2049
2627
  };
2050
2628
 
2051
- var getBuiltIn$3 = getBuiltIn$7;
2052
- var defineBuiltInAccessor = defineBuiltInAccessor$1;
2053
- var wellKnownSymbol$7 = wellKnownSymbol$e;
2054
- var DESCRIPTORS$2 = descriptors;
2629
+ var isCallable$5 = isCallable$l;
2630
+ var isObject$3 = isObject$c;
2631
+ var setPrototypeOf$2 = objectSetPrototypeOf;
2632
+
2633
+ // makes subclassing work correct for wrapped built-ins
2634
+ var inheritIfRequired$1 = function ($this, dummy, Wrapper) {
2635
+ var NewTarget, NewTargetPrototype;
2636
+ if (
2637
+ // it can work only with native `setPrototypeOf`
2638
+ setPrototypeOf$2 &&
2639
+ // we haven't completely correct pre-ES6 way for getting `new.target`, so use this
2640
+ isCallable$5(NewTarget = dummy.constructor) &&
2641
+ NewTarget !== Wrapper &&
2642
+ isObject$3(NewTargetPrototype = NewTarget.prototype) &&
2643
+ NewTargetPrototype !== Wrapper.prototype
2644
+ ) setPrototypeOf$2($this, NewTargetPrototype);
2645
+ return $this;
2646
+ };
2055
2647
 
2056
- var SPECIES$2 = wellKnownSymbol$7('species');
2648
+ var classof$3 = classof$5;
2057
2649
 
2058
- var setSpecies$1 = function (CONSTRUCTOR_NAME) {
2059
- var Constructor = getBuiltIn$3(CONSTRUCTOR_NAME);
2650
+ var $String = String;
2060
2651
 
2061
- if (DESCRIPTORS$2 && Constructor && !Constructor[SPECIES$2]) {
2062
- defineBuiltInAccessor(Constructor, SPECIES$2, {
2063
- configurable: true,
2064
- get: function () { return this; }
2065
- });
2652
+ var toString$1 = function (argument) {
2653
+ if (classof$3(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');
2654
+ return $String(argument);
2655
+ };
2656
+
2657
+ var toString = toString$1;
2658
+
2659
+ var normalizeStringArgument$1 = function (argument, $default) {
2660
+ return argument === undefined ? arguments.length < 2 ? '' : $default : toString(argument);
2661
+ };
2662
+
2663
+ var isObject$2 = isObject$c;
2664
+ var createNonEnumerableProperty$2 = createNonEnumerableProperty$8;
2665
+
2666
+ // `InstallErrorCause` abstract operation
2667
+ // https://tc39.es/proposal-error-cause/#sec-errorobjects-install-error-cause
2668
+ var installErrorCause$1 = function (O, options) {
2669
+ if (isObject$2(options) && 'cause' in options) {
2670
+ createNonEnumerableProperty$2(O, 'cause', options.cause);
2066
2671
  }
2067
2672
  };
2068
2673
 
2069
- var isPrototypeOf$1 = objectIsPrototypeOf;
2674
+ var uncurryThis$3 = functionUncurryThis;
2070
2675
 
2071
- var $TypeError$5 = TypeError;
2676
+ var $Error = Error;
2677
+ var replace = uncurryThis$3(''.replace);
2072
2678
 
2073
- var anInstance$1 = function (it, Prototype) {
2074
- if (isPrototypeOf$1(Prototype, it)) return it;
2075
- throw new $TypeError$5('Incorrect invocation');
2679
+ var TEST = (function (arg) { return String(new $Error(arg).stack); })('zxcasd');
2680
+ // eslint-disable-next-line redos/no-vulnerable -- safe
2681
+ var V8_OR_CHAKRA_STACK_ENTRY = /\n\s*at [^:]*:[^\n]*/;
2682
+ var IS_V8_OR_CHAKRA_STACK = V8_OR_CHAKRA_STACK_ENTRY.test(TEST);
2683
+
2684
+ var errorStackClear = function (stack, dropEntries) {
2685
+ if (IS_V8_OR_CHAKRA_STACK && typeof stack == 'string' && !$Error.prepareStackTrace) {
2686
+ while (dropEntries--) stack = replace(stack, V8_OR_CHAKRA_STACK_ENTRY, '');
2687
+ } return stack;
2076
2688
  };
2077
2689
 
2078
- var wellKnownSymbol$6 = wellKnownSymbol$e;
2690
+ var fails$4 = fails$g;
2691
+ var createPropertyDescriptor = createPropertyDescriptor$5;
2079
2692
 
2080
- var TO_STRING_TAG$1 = wellKnownSymbol$6('toStringTag');
2081
- var test = {};
2693
+ var errorStackInstallable = !fails$4(function () {
2694
+ var error = new Error('a');
2695
+ if (!('stack' in error)) return true;
2696
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
2697
+ Object.defineProperty(error, 'stack', createPropertyDescriptor(1, 7));
2698
+ return error.stack !== 7;
2699
+ });
2082
2700
 
2083
- test[TO_STRING_TAG$1] = 'z';
2701
+ var createNonEnumerableProperty$1 = createNonEnumerableProperty$8;
2702
+ var clearErrorStack = errorStackClear;
2703
+ var ERROR_STACK_INSTALLABLE = errorStackInstallable;
2084
2704
 
2085
- var toStringTagSupport = String(test) === '[object z]';
2705
+ // non-standard V8
2706
+ var captureStackTrace = Error.captureStackTrace;
2086
2707
 
2087
- var TO_STRING_TAG_SUPPORT = toStringTagSupport;
2088
- var isCallable$5 = isCallable$j;
2089
- var classofRaw$1 = classofRaw$2;
2090
- var wellKnownSymbol$5 = wellKnownSymbol$e;
2708
+ var errorStackInstall = function (error, C, stack, dropEntries) {
2709
+ if (ERROR_STACK_INSTALLABLE) {
2710
+ if (captureStackTrace) captureStackTrace(error, C);
2711
+ else createNonEnumerableProperty$1(error, 'stack', clearErrorStack(stack, dropEntries));
2712
+ }
2713
+ };
2091
2714
 
2092
- var TO_STRING_TAG = wellKnownSymbol$5('toStringTag');
2093
- var $Object = Object;
2715
+ var getBuiltIn$4 = getBuiltIn$8;
2716
+ var hasOwn$1 = hasOwnProperty_1;
2717
+ var createNonEnumerableProperty = createNonEnumerableProperty$8;
2718
+ var isPrototypeOf = objectIsPrototypeOf;
2719
+ var setPrototypeOf$1 = objectSetPrototypeOf;
2720
+ var copyConstructorProperties = copyConstructorProperties$2;
2721
+ var proxyAccessor = proxyAccessor$1;
2722
+ var inheritIfRequired = inheritIfRequired$1;
2723
+ var normalizeStringArgument = normalizeStringArgument$1;
2724
+ var installErrorCause = installErrorCause$1;
2725
+ var installErrorStack = errorStackInstall;
2726
+ var DESCRIPTORS$4 = descriptors;
2094
2727
 
2095
- // ES3 wrong here
2096
- var CORRECT_ARGUMENTS = classofRaw$1(function () { return arguments; }()) === 'Arguments';
2728
+ var wrapErrorConstructorWithCause$1 = function (FULL_NAME, wrapper, FORCED, IS_AGGREGATE_ERROR) {
2729
+ var STACK_TRACE_LIMIT = 'stackTraceLimit';
2730
+ var OPTIONS_POSITION = IS_AGGREGATE_ERROR ? 2 : 1;
2731
+ var path = FULL_NAME.split('.');
2732
+ var ERROR_NAME = path[path.length - 1];
2733
+ var OriginalError = getBuiltIn$4.apply(null, path);
2734
+
2735
+ if (!OriginalError) return;
2736
+
2737
+ var OriginalErrorPrototype = OriginalError.prototype;
2738
+
2739
+ // V8 9.3- bug https://bugs.chromium.org/p/v8/issues/detail?id=12006
2740
+ if (hasOwn$1(OriginalErrorPrototype, 'cause')) delete OriginalErrorPrototype.cause;
2741
+
2742
+ if (!FORCED) return OriginalError;
2743
+
2744
+ var BaseError = getBuiltIn$4('Error');
2745
+
2746
+ var WrappedError = wrapper(function (a, b) {
2747
+ var message = normalizeStringArgument(IS_AGGREGATE_ERROR ? b : a, undefined);
2748
+ var result = IS_AGGREGATE_ERROR ? new OriginalError(a) : new OriginalError();
2749
+ if (message !== undefined) createNonEnumerableProperty(result, 'message', message);
2750
+ installErrorStack(result, WrappedError, result.stack, 2);
2751
+ if (this && isPrototypeOf(OriginalErrorPrototype, this)) inheritIfRequired(result, this, WrappedError);
2752
+ if (arguments.length > OPTIONS_POSITION) installErrorCause(result, arguments[OPTIONS_POSITION]);
2753
+ return result;
2754
+ });
2755
+
2756
+ WrappedError.prototype = OriginalErrorPrototype;
2757
+
2758
+ if (ERROR_NAME !== 'Error') {
2759
+ if (setPrototypeOf$1) setPrototypeOf$1(WrappedError, BaseError);
2760
+ else copyConstructorProperties(WrappedError, BaseError, { name: true });
2761
+ } else if (DESCRIPTORS$4 && STACK_TRACE_LIMIT in OriginalError) {
2762
+ proxyAccessor(WrappedError, OriginalError, STACK_TRACE_LIMIT);
2763
+ proxyAccessor(WrappedError, OriginalError, 'prepareStackTrace');
2764
+ }
2765
+
2766
+ copyConstructorProperties(WrappedError, OriginalError);
2097
2767
 
2098
- // fallback for IE11 Script Access Denied error
2099
- var tryGet = function (it, key) {
2100
2768
  try {
2101
- return it[key];
2769
+ // Safari 13- bug: WebAssembly errors does not have a proper `.name`
2770
+ if (OriginalErrorPrototype.name !== ERROR_NAME) {
2771
+ createNonEnumerableProperty(OriginalErrorPrototype, 'name', ERROR_NAME);
2772
+ }
2773
+ OriginalErrorPrototype.constructor = WrappedError;
2102
2774
  } catch (error) { /* empty */ }
2775
+
2776
+ return WrappedError;
2103
2777
  };
2104
2778
 
2105
- // getting tag from ES6+ `Object.prototype.toString`
2106
- var classof$2 = TO_STRING_TAG_SUPPORT ? classofRaw$1 : function (it) {
2107
- var O, tag, result;
2108
- return it === undefined ? 'Undefined' : it === null ? 'Null'
2109
- // @@toStringTag case
2110
- : typeof (tag = tryGet(O = $Object(it), TO_STRING_TAG)) == 'string' ? tag
2111
- // builtinTag case
2112
- : CORRECT_ARGUMENTS ? classofRaw$1(O)
2113
- // ES3 arguments fallback
2114
- : (result = classofRaw$1(O)) === 'Object' && isCallable$5(O.callee) ? 'Arguments' : result;
2779
+ /* eslint-disable no-unused-vars -- required for functions `.length` */
2780
+ var $$8 = _export;
2781
+ var global$8 = global$k;
2782
+ var apply$1 = functionApply;
2783
+ var wrapErrorConstructorWithCause = wrapErrorConstructorWithCause$1;
2784
+
2785
+ var WEB_ASSEMBLY = 'WebAssembly';
2786
+ var WebAssembly = global$8[WEB_ASSEMBLY];
2787
+
2788
+ // eslint-disable-next-line es/no-error-cause -- feature detection
2789
+ var FORCED$1 = new Error('e', { cause: 7 }).cause !== 7;
2790
+
2791
+ var exportGlobalErrorCauseWrapper = function (ERROR_NAME, wrapper) {
2792
+ var O = {};
2793
+ O[ERROR_NAME] = wrapErrorConstructorWithCause(ERROR_NAME, wrapper, FORCED$1);
2794
+ $$8({ global: true, constructor: true, arity: 1, forced: FORCED$1 }, O);
2795
+ };
2796
+
2797
+ var exportWebAssemblyErrorCauseWrapper = function (ERROR_NAME, wrapper) {
2798
+ if (WebAssembly && WebAssembly[ERROR_NAME]) {
2799
+ var O = {};
2800
+ O[ERROR_NAME] = wrapErrorConstructorWithCause(WEB_ASSEMBLY + '.' + ERROR_NAME, wrapper, FORCED$1);
2801
+ $$8({ target: WEB_ASSEMBLY, stat: true, constructor: true, arity: 1, forced: FORCED$1 }, O);
2802
+ }
2803
+ };
2804
+
2805
+ // https://tc39.es/ecma262/#sec-nativeerror
2806
+ exportGlobalErrorCauseWrapper('Error', function (init) {
2807
+ return function Error(message) { return apply$1(init, this, arguments); };
2808
+ });
2809
+ exportGlobalErrorCauseWrapper('EvalError', function (init) {
2810
+ return function EvalError(message) { return apply$1(init, this, arguments); };
2811
+ });
2812
+ exportGlobalErrorCauseWrapper('RangeError', function (init) {
2813
+ return function RangeError(message) { return apply$1(init, this, arguments); };
2814
+ });
2815
+ exportGlobalErrorCauseWrapper('ReferenceError', function (init) {
2816
+ return function ReferenceError(message) { return apply$1(init, this, arguments); };
2817
+ });
2818
+ exportGlobalErrorCauseWrapper('SyntaxError', function (init) {
2819
+ return function SyntaxError(message) { return apply$1(init, this, arguments); };
2820
+ });
2821
+ exportGlobalErrorCauseWrapper('TypeError', function (init) {
2822
+ return function TypeError(message) { return apply$1(init, this, arguments); };
2823
+ });
2824
+ exportGlobalErrorCauseWrapper('URIError', function (init) {
2825
+ return function URIError(message) { return apply$1(init, this, arguments); };
2826
+ });
2827
+ exportWebAssemblyErrorCauseWrapper('CompileError', function (init) {
2828
+ return function CompileError(message) { return apply$1(init, this, arguments); };
2829
+ });
2830
+ exportWebAssemblyErrorCauseWrapper('LinkError', function (init) {
2831
+ return function LinkError(message) { return apply$1(init, this, arguments); };
2832
+ });
2833
+ exportWebAssemblyErrorCauseWrapper('RuntimeError', function (init) {
2834
+ return function RuntimeError(message) { return apply$1(init, this, arguments); };
2835
+ });
2836
+
2837
+ var global$7 = global$k;
2838
+ var classof$2 = classofRaw$2;
2839
+
2840
+ var engineIsNode = classof$2(global$7.process) === 'process';
2841
+
2842
+ var getBuiltIn$3 = getBuiltIn$8;
2843
+ var defineBuiltInAccessor = defineBuiltInAccessor$2;
2844
+ var wellKnownSymbol$3 = wellKnownSymbol$g;
2845
+ var DESCRIPTORS$3 = descriptors;
2846
+
2847
+ var SPECIES$2 = wellKnownSymbol$3('species');
2848
+
2849
+ var setSpecies$1 = function (CONSTRUCTOR_NAME) {
2850
+ var Constructor = getBuiltIn$3(CONSTRUCTOR_NAME);
2851
+
2852
+ if (DESCRIPTORS$3 && Constructor && !Constructor[SPECIES$2]) {
2853
+ defineBuiltInAccessor(Constructor, SPECIES$2, {
2854
+ configurable: true,
2855
+ get: function () { return this; }
2856
+ });
2857
+ }
2115
2858
  };
2116
2859
 
2117
- var uncurryThis$4 = functionUncurryThis;
2118
- var fails$2 = fails$d;
2119
- var isCallable$4 = isCallable$j;
2120
- var classof$1 = classof$2;
2121
- var getBuiltIn$2 = getBuiltIn$7;
2860
+ var uncurryThis$2 = functionUncurryThis;
2861
+ var fails$3 = fails$g;
2862
+ var isCallable$4 = isCallable$l;
2863
+ var classof$1 = classof$5;
2864
+ var getBuiltIn$2 = getBuiltIn$8;
2122
2865
  var inspectSource$1 = inspectSource$3;
2123
2866
 
2124
2867
  var noop = function () { /* empty */ };
2125
2868
  var construct = getBuiltIn$2('Reflect', 'construct');
2126
2869
  var constructorRegExp = /^\s*(?:class|function)\b/;
2127
- var exec = uncurryThis$4(constructorRegExp.exec);
2870
+ var exec = uncurryThis$2(constructorRegExp.exec);
2128
2871
  var INCORRECT_TO_STRING = !constructorRegExp.test(noop);
2129
2872
 
2130
2873
  var isConstructorModern = function isConstructor(argument) {
@@ -2158,7 +2901,7 @@ isConstructorLegacy.sham = true;
2158
2901
 
2159
2902
  // `IsConstructor` abstract operation
2160
2903
  // https://tc39.es/ecma262/#sec-isconstructor
2161
- var isConstructor$1 = !construct || fails$2(function () {
2904
+ var isConstructor$1 = !construct || fails$3(function () {
2162
2905
  var called;
2163
2906
  return isConstructorModern(isConstructorModern.call)
2164
2907
  || !isConstructorModern(Object)
@@ -2167,64 +2910,29 @@ var isConstructor$1 = !construct || fails$2(function () {
2167
2910
  }) ? isConstructorLegacy : isConstructorModern;
2168
2911
 
2169
2912
  var isConstructor = isConstructor$1;
2170
- var tryToString$2 = tryToString$4;
2913
+ var tryToString = tryToString$4;
2171
2914
 
2172
2915
  var $TypeError$4 = TypeError;
2173
2916
 
2174
2917
  // `Assert: IsConstructor(argument) is true`
2175
2918
  var aConstructor$1 = function (argument) {
2176
2919
  if (isConstructor(argument)) return argument;
2177
- throw new $TypeError$4(tryToString$2(argument) + ' is not a constructor');
2920
+ throw new $TypeError$4(tryToString(argument) + ' is not a constructor');
2178
2921
  };
2179
2922
 
2180
- var anObject$4 = anObject$a;
2923
+ var anObject$1 = anObject$f;
2181
2924
  var aConstructor = aConstructor$1;
2182
- var isNullOrUndefined$1 = isNullOrUndefined$4;
2183
- var wellKnownSymbol$4 = wellKnownSymbol$e;
2925
+ var isNullOrUndefined = isNullOrUndefined$4;
2926
+ var wellKnownSymbol$2 = wellKnownSymbol$g;
2184
2927
 
2185
- var SPECIES$1 = wellKnownSymbol$4('species');
2928
+ var SPECIES$1 = wellKnownSymbol$2('species');
2186
2929
 
2187
2930
  // `SpeciesConstructor` abstract operation
2188
2931
  // https://tc39.es/ecma262/#sec-speciesconstructor
2189
2932
  var speciesConstructor$1 = function (O, defaultConstructor) {
2190
- var C = anObject$4(O).constructor;
2933
+ var C = anObject$1(O).constructor;
2191
2934
  var S;
2192
- return C === undefined || isNullOrUndefined$1(S = anObject$4(C)[SPECIES$1]) ? defaultConstructor : aConstructor(S);
2193
- };
2194
-
2195
- var NATIVE_BIND$1 = functionBindNative;
2196
-
2197
- var FunctionPrototype = Function.prototype;
2198
- var apply$1 = FunctionPrototype.apply;
2199
- var call$7 = FunctionPrototype.call;
2200
-
2201
- // eslint-disable-next-line es/no-reflect -- safe
2202
- var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND$1 ? call$7.bind(apply$1) : function () {
2203
- return call$7.apply(apply$1, arguments);
2204
- });
2205
-
2206
- var classofRaw = classofRaw$2;
2207
- var uncurryThis$3 = functionUncurryThis;
2208
-
2209
- var functionUncurryThisClause = function (fn) {
2210
- // Nashorn bug:
2211
- // https://github.com/zloirock/core-js/issues/1128
2212
- // https://github.com/zloirock/core-js/issues/1130
2213
- if (classofRaw(fn) === 'Function') return uncurryThis$3(fn);
2214
- };
2215
-
2216
- var uncurryThis$2 = functionUncurryThisClause;
2217
- var aCallable$5 = aCallable$8;
2218
- var NATIVE_BIND = functionBindNative;
2219
-
2220
- var bind$4 = uncurryThis$2(uncurryThis$2.bind);
2221
-
2222
- // optional / simple context binding
2223
- var functionBindContext = function (fn, that) {
2224
- aCallable$5(fn);
2225
- return that === undefined ? fn : NATIVE_BIND ? bind$4(fn, that) : function (/* ...args */) {
2226
- return fn.apply(that, arguments);
2227
- };
2935
+ return C === undefined || isNullOrUndefined(S = anObject$1(C)[SPECIES$1]) ? defaultConstructor : aConstructor(S);
2228
2936
  };
2229
2937
 
2230
2938
  var uncurryThis$1 = functionUncurryThis;
@@ -2243,12 +2951,12 @@ var userAgent$2 = engineUserAgent;
2243
2951
  // eslint-disable-next-line redos/no-vulnerable -- safe
2244
2952
  var engineIsIos = /(?:ipad|iphone|ipod).*applewebkit/i.test(userAgent$2);
2245
2953
 
2246
- var global$6 = global$j;
2954
+ var global$6 = global$k;
2247
2955
  var apply = functionApply;
2248
- var bind$3 = functionBindContext;
2249
- var isCallable$3 = isCallable$j;
2956
+ var bind$2 = functionBindContext;
2957
+ var isCallable$3 = isCallable$l;
2250
2958
  var hasOwn = hasOwnProperty_1;
2251
- var fails$1 = fails$d;
2959
+ var fails$2 = fails$g;
2252
2960
  var html = html$2;
2253
2961
  var arraySlice = arraySlice$1;
2254
2962
  var createElement = documentCreateElement$2;
@@ -2268,7 +2976,7 @@ var queue$2 = {};
2268
2976
  var ONREADYSTATECHANGE = 'onreadystatechange';
2269
2977
  var $location, defer, channel, port;
2270
2978
 
2271
- fails$1(function () {
2979
+ fails$2(function () {
2272
2980
  // Deno throws a ReferenceError on `location` access without `--location` flag
2273
2981
  $location = global$6.location;
2274
2982
  });
@@ -2327,7 +3035,7 @@ if (!set || !clear) {
2327
3035
  channel = new MessageChannel();
2328
3036
  port = channel.port2;
2329
3037
  channel.port1.onmessage = eventListener;
2330
- defer = bind$3(port.postMessage, port);
3038
+ defer = bind$2(port.postMessage, port);
2331
3039
  // Browsers with postMessage, skip WebWorkers
2332
3040
  // IE8 has postMessage, but it's sync & typeof its postMessage is 'object'
2333
3041
  } else if (
@@ -2335,7 +3043,7 @@ if (!set || !clear) {
2335
3043
  isCallable$3(global$6.postMessage) &&
2336
3044
  !global$6.importScripts &&
2337
3045
  $location && $location.protocol !== 'file:' &&
2338
- !fails$1(globalPostMessageDefer)
3046
+ !fails$2(globalPostMessageDefer)
2339
3047
  ) {
2340
3048
  defer = globalPostMessageDefer;
2341
3049
  global$6.addEventListener('message', eventListener, false);
@@ -2360,16 +3068,16 @@ var task$1 = {
2360
3068
  clear: clear
2361
3069
  };
2362
3070
 
2363
- var global$5 = global$j;
2364
- var DESCRIPTORS$1 = descriptors;
3071
+ var global$5 = global$k;
3072
+ var DESCRIPTORS$2 = descriptors;
2365
3073
 
2366
3074
  // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
2367
- var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
3075
+ var getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
2368
3076
 
2369
3077
  // Avoid NodeJS experimental warning
2370
3078
  var safeGetBuiltIn$1 = function (name) {
2371
- if (!DESCRIPTORS$1) return global$5[name];
2372
- var descriptor = getOwnPropertyDescriptor(global$5, name);
3079
+ if (!DESCRIPTORS$2) return global$5[name];
3080
+ var descriptor = getOwnPropertyDescriptor$1(global$5, name);
2373
3081
  return descriptor && descriptor.value;
2374
3082
  };
2375
3083
 
@@ -2406,9 +3114,9 @@ var userAgent = engineUserAgent;
2406
3114
 
2407
3115
  var engineIsWebosWebkit = /web0s(?!.*chrome)/i.test(userAgent);
2408
3116
 
2409
- var global$4 = global$j;
3117
+ var global$4 = global$k;
2410
3118
  var safeGetBuiltIn = safeGetBuiltIn$1;
2411
- var bind$2 = functionBindContext;
3119
+ var bind$1 = functionBindContext;
2412
3120
  var macrotask = task$1.set;
2413
3121
  var Queue$1 = queue$1;
2414
3122
  var IS_IOS = engineIsIos;
@@ -2454,7 +3162,7 @@ if (!microtask$1) {
2454
3162
  promise = Promise$1.resolve(undefined);
2455
3163
  // workaround of WebKit ~ iOS Safari 10.1 bug
2456
3164
  promise.constructor = Promise$1;
2457
- then = bind$2(promise.then, promise);
3165
+ then = bind$1(promise.then, promise);
2458
3166
  notify$1 = function () {
2459
3167
  then(flush);
2460
3168
  };
@@ -2471,7 +3179,7 @@ if (!microtask$1) {
2471
3179
  // - setTimeout
2472
3180
  } else {
2473
3181
  // `webpack` dev server bug on IE global methods - use bind(fn, global)
2474
- macrotask = bind$2(macrotask, global$4);
3182
+ macrotask = bind$1(macrotask, global$4);
2475
3183
  notify$1 = function () {
2476
3184
  macrotask(flush);
2477
3185
  };
@@ -2500,7 +3208,7 @@ var perform$3 = function (exec) {
2500
3208
  }
2501
3209
  };
2502
3210
 
2503
- var global$3 = global$j;
3211
+ var global$3 = global$k;
2504
3212
 
2505
3213
  var promiseNativeConstructor = global$3.Promise;
2506
3214
 
@@ -2514,18 +3222,18 @@ var engineIsBrowser = !IS_DENO$1 && !IS_NODE$1
2514
3222
  && typeof window == 'object'
2515
3223
  && typeof document == 'object';
2516
3224
 
2517
- var global$2 = global$j;
3225
+ var global$2 = global$k;
2518
3226
  var NativePromiseConstructor$3 = promiseNativeConstructor;
2519
- var isCallable$2 = isCallable$j;
3227
+ var isCallable$2 = isCallable$l;
2520
3228
  var isForced = isForced_1;
2521
3229
  var inspectSource = inspectSource$3;
2522
- var wellKnownSymbol$3 = wellKnownSymbol$e;
3230
+ var wellKnownSymbol$1 = wellKnownSymbol$g;
2523
3231
  var IS_BROWSER = engineIsBrowser;
2524
3232
  var IS_DENO = engineIsDeno;
2525
3233
  var V8_VERSION = engineV8Version;
2526
3234
 
2527
3235
  NativePromiseConstructor$3 && NativePromiseConstructor$3.prototype;
2528
- var SPECIES = wellKnownSymbol$3('species');
3236
+ var SPECIES = wellKnownSymbol$1('species');
2529
3237
  var SUBCLASSING = false;
2530
3238
  var NATIVE_PROMISE_REJECTION_EVENT$1 = isCallable$2(global$2.PromiseRejectionEvent);
2531
3239
 
@@ -2561,7 +3269,7 @@ var promiseConstructorDetection = {
2561
3269
 
2562
3270
  var newPromiseCapability$2 = {};
2563
3271
 
2564
- var aCallable$4 = aCallable$8;
3272
+ var aCallable$3 = aCallable$c;
2565
3273
 
2566
3274
  var $TypeError$2 = TypeError;
2567
3275
 
@@ -2572,8 +3280,8 @@ var PromiseCapability = function (C) {
2572
3280
  resolve = $$resolve;
2573
3281
  reject = $$reject;
2574
3282
  });
2575
- this.resolve = aCallable$4(resolve);
2576
- this.reject = aCallable$4(reject);
3283
+ this.resolve = aCallable$3(resolve);
3284
+ this.reject = aCallable$3(reject);
2577
3285
  };
2578
3286
 
2579
3287
  // `NewPromiseCapability` abstract operation
@@ -2582,18 +3290,18 @@ newPromiseCapability$2.f = function (C) {
2582
3290
  return new PromiseCapability(C);
2583
3291
  };
2584
3292
 
2585
- var $$6 = _export;
3293
+ var $$7 = _export;
2586
3294
  var IS_NODE = engineIsNode;
2587
- var global$1 = global$j;
2588
- var call$6 = functionCall;
2589
- var defineBuiltIn$1 = defineBuiltIn$5;
3295
+ var global$1 = global$k;
3296
+ var call$3 = functionCall;
3297
+ var defineBuiltIn$1 = defineBuiltIn$6;
2590
3298
  var setPrototypeOf = objectSetPrototypeOf;
2591
3299
  var setToStringTag = setToStringTag$4;
2592
3300
  var setSpecies = setSpecies$1;
2593
- var aCallable$3 = aCallable$8;
2594
- var isCallable$1 = isCallable$j;
2595
- var isObject$1 = isObject$9;
2596
- var anInstance = anInstance$1;
3301
+ var aCallable$2 = aCallable$c;
3302
+ var isCallable$1 = isCallable$l;
3303
+ var isObject$1 = isObject$c;
3304
+ var anInstance = anInstance$2;
2597
3305
  var speciesConstructor = speciesConstructor$1;
2598
3306
  var task = task$1.set;
2599
3307
  var microtask = microtask_1;
@@ -2663,7 +3371,7 @@ var callReaction = function (reaction, state) {
2663
3371
  if (result === reaction.promise) {
2664
3372
  reject(new TypeError$1('Promise-chain cycle'));
2665
3373
  } else if (then = isThenable(result)) {
2666
- call$6(then, result, resolve, reject);
3374
+ call$3(then, result, resolve, reject);
2667
3375
  } else resolve(result);
2668
3376
  } else reject(value);
2669
3377
  } catch (error) {
@@ -2700,7 +3408,7 @@ var dispatchEvent = function (name, promise, reason) {
2700
3408
  };
2701
3409
 
2702
3410
  var onUnhandled = function (state) {
2703
- call$6(task, global$1, function () {
3411
+ call$3(task, global$1, function () {
2704
3412
  var promise = state.facade;
2705
3413
  var value = state.value;
2706
3414
  var IS_UNHANDLED = isUnhandled(state);
@@ -2723,7 +3431,7 @@ var isUnhandled = function (state) {
2723
3431
  };
2724
3432
 
2725
3433
  var onHandleUnhandled = function (state) {
2726
- call$6(task, global$1, function () {
3434
+ call$3(task, global$1, function () {
2727
3435
  var promise = state.facade;
2728
3436
  if (IS_NODE) {
2729
3437
  process.emit('rejectionHandled', promise);
@@ -2731,7 +3439,7 @@ var onHandleUnhandled = function (state) {
2731
3439
  });
2732
3440
  };
2733
3441
 
2734
- var bind$1 = function (fn, state, unwrap) {
3442
+ var bind = function (fn, state, unwrap) {
2735
3443
  return function (value) {
2736
3444
  fn(state, value, unwrap);
2737
3445
  };
@@ -2757,9 +3465,9 @@ var internalResolve = function (state, value, unwrap) {
2757
3465
  microtask(function () {
2758
3466
  var wrapper = { done: false };
2759
3467
  try {
2760
- call$6(then, value,
2761
- bind$1(internalResolve, wrapper, state),
2762
- bind$1(internalReject, wrapper, state)
3468
+ call$3(then, value,
3469
+ bind(internalResolve, wrapper, state),
3470
+ bind(internalReject, wrapper, state)
2763
3471
  );
2764
3472
  } catch (error) {
2765
3473
  internalReject(wrapper, error, state);
@@ -2780,11 +3488,11 @@ if (FORCED_PROMISE_CONSTRUCTOR$4) {
2780
3488
  // 25.4.3.1 Promise(executor)
2781
3489
  PromiseConstructor = function Promise(executor) {
2782
3490
  anInstance(this, PromisePrototype);
2783
- aCallable$3(executor);
2784
- call$6(Internal, this);
3491
+ aCallable$2(executor);
3492
+ call$3(Internal, this);
2785
3493
  var state = getInternalPromiseState(this);
2786
3494
  try {
2787
- executor(bind$1(internalResolve, state), bind$1(internalReject, state));
3495
+ executor(bind(internalResolve, state), bind(internalReject, state));
2788
3496
  } catch (error) {
2789
3497
  internalReject(state, error);
2790
3498
  }
@@ -2826,182 +3534,50 @@ if (FORCED_PROMISE_CONSTRUCTOR$4) {
2826
3534
  var promise = new Internal();
2827
3535
  var state = getInternalPromiseState(promise);
2828
3536
  this.promise = promise;
2829
- this.resolve = bind$1(internalResolve, state);
2830
- this.reject = bind$1(internalReject, state);
3537
+ this.resolve = bind(internalResolve, state);
3538
+ this.reject = bind(internalReject, state);
2831
3539
  };
2832
3540
 
2833
3541
  newPromiseCapabilityModule$3.f = newPromiseCapability$1 = function (C) {
2834
- return C === PromiseConstructor || C === PromiseWrapper
2835
- ? new OwnPromiseCapability(C)
2836
- : newGenericPromiseCapability(C);
2837
- };
2838
-
2839
- if (isCallable$1(NativePromiseConstructor$2) && NativePromisePrototype$1 !== Object.prototype) {
2840
- nativeThen = NativePromisePrototype$1.then;
2841
-
2842
- if (!NATIVE_PROMISE_SUBCLASSING) {
2843
- // make `Promise#then` return a polyfilled `Promise` for native promise-based APIs
2844
- defineBuiltIn$1(NativePromisePrototype$1, 'then', function then(onFulfilled, onRejected) {
2845
- var that = this;
2846
- return new PromiseConstructor(function (resolve, reject) {
2847
- call$6(nativeThen, that, resolve, reject);
2848
- }).then(onFulfilled, onRejected);
2849
- // https://github.com/zloirock/core-js/issues/640
2850
- }, { unsafe: true });
2851
- }
2852
-
2853
- // make `.constructor === Promise` work for native promise-based APIs
2854
- try {
2855
- delete NativePromisePrototype$1.constructor;
2856
- } catch (error) { /* empty */ }
2857
-
2858
- // make `instanceof Promise` work for native promise-based APIs
2859
- if (setPrototypeOf) {
2860
- setPrototypeOf(NativePromisePrototype$1, PromisePrototype);
2861
- }
2862
- }
2863
- }
2864
-
2865
- $$6({ global: true, constructor: true, wrap: true, forced: FORCED_PROMISE_CONSTRUCTOR$4 }, {
2866
- Promise: PromiseConstructor
2867
- });
2868
-
2869
- setToStringTag(PromiseConstructor, PROMISE, false);
2870
- setSpecies(PROMISE);
2871
-
2872
- var wellKnownSymbol$2 = wellKnownSymbol$e;
2873
- var Iterators$1 = iterators;
2874
-
2875
- var ITERATOR$2 = wellKnownSymbol$2('iterator');
2876
- var ArrayPrototype = Array.prototype;
2877
-
2878
- // check on default Array iterator
2879
- var isArrayIteratorMethod$1 = function (it) {
2880
- return it !== undefined && (Iterators$1.Array === it || ArrayPrototype[ITERATOR$2] === it);
2881
- };
2882
-
2883
- var classof = classof$2;
2884
- var getMethod$1 = getMethod$3;
2885
- var isNullOrUndefined = isNullOrUndefined$4;
2886
- var Iterators = iterators;
2887
- var wellKnownSymbol$1 = wellKnownSymbol$e;
2888
-
2889
- var ITERATOR$1 = wellKnownSymbol$1('iterator');
2890
-
2891
- var getIteratorMethod$2 = function (it) {
2892
- if (!isNullOrUndefined(it)) return getMethod$1(it, ITERATOR$1)
2893
- || getMethod$1(it, '@@iterator')
2894
- || Iterators[classof(it)];
2895
- };
2896
-
2897
- var call$5 = functionCall;
2898
- var aCallable$2 = aCallable$8;
2899
- var anObject$3 = anObject$a;
2900
- var tryToString$1 = tryToString$4;
2901
- var getIteratorMethod$1 = getIteratorMethod$2;
2902
-
2903
- var $TypeError$1 = TypeError;
2904
-
2905
- var getIterator$1 = function (argument, usingIterator) {
2906
- var iteratorMethod = arguments.length < 2 ? getIteratorMethod$1(argument) : usingIterator;
2907
- if (aCallable$2(iteratorMethod)) return anObject$3(call$5(iteratorMethod, argument));
2908
- throw new $TypeError$1(tryToString$1(argument) + ' is not iterable');
2909
- };
2910
-
2911
- var call$4 = functionCall;
2912
- var anObject$2 = anObject$a;
2913
- var getMethod = getMethod$3;
2914
-
2915
- var iteratorClose$1 = function (iterator, kind, value) {
2916
- var innerResult, innerError;
2917
- anObject$2(iterator);
2918
- try {
2919
- innerResult = getMethod(iterator, 'return');
2920
- if (!innerResult) {
2921
- if (kind === 'throw') throw value;
2922
- return value;
2923
- }
2924
- innerResult = call$4(innerResult, iterator);
2925
- } catch (error) {
2926
- innerError = true;
2927
- innerResult = error;
2928
- }
2929
- if (kind === 'throw') throw value;
2930
- if (innerError) throw innerResult;
2931
- anObject$2(innerResult);
2932
- return value;
2933
- };
2934
-
2935
- var bind = functionBindContext;
2936
- var call$3 = functionCall;
2937
- var anObject$1 = anObject$a;
2938
- var tryToString = tryToString$4;
2939
- var isArrayIteratorMethod = isArrayIteratorMethod$1;
2940
- var lengthOfArrayLike = lengthOfArrayLike$2;
2941
- var isPrototypeOf = objectIsPrototypeOf;
2942
- var getIterator = getIterator$1;
2943
- var getIteratorMethod = getIteratorMethod$2;
2944
- var iteratorClose = iteratorClose$1;
2945
-
2946
- var $TypeError = TypeError;
2947
-
2948
- var Result = function (stopped, result) {
2949
- this.stopped = stopped;
2950
- this.result = result;
2951
- };
2952
-
2953
- var ResultPrototype = Result.prototype;
2954
-
2955
- var iterate$2 = function (iterable, unboundFunction, options) {
2956
- var that = options && options.that;
2957
- var AS_ENTRIES = !!(options && options.AS_ENTRIES);
2958
- var IS_RECORD = !!(options && options.IS_RECORD);
2959
- var IS_ITERATOR = !!(options && options.IS_ITERATOR);
2960
- var INTERRUPTED = !!(options && options.INTERRUPTED);
2961
- var fn = bind(unboundFunction, that);
2962
- var iterator, iterFn, index, length, result, next, step;
2963
-
2964
- var stop = function (condition) {
2965
- if (iterator) iteratorClose(iterator, 'normal', condition);
2966
- return new Result(true, condition);
2967
- };
2968
-
2969
- var callFn = function (value) {
2970
- if (AS_ENTRIES) {
2971
- anObject$1(value);
2972
- return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);
2973
- } return INTERRUPTED ? fn(value, stop) : fn(value);
3542
+ return C === PromiseConstructor || C === PromiseWrapper
3543
+ ? new OwnPromiseCapability(C)
3544
+ : newGenericPromiseCapability(C);
2974
3545
  };
2975
3546
 
2976
- if (IS_RECORD) {
2977
- iterator = iterable.iterator;
2978
- } else if (IS_ITERATOR) {
2979
- iterator = iterable;
2980
- } else {
2981
- iterFn = getIteratorMethod(iterable);
2982
- if (!iterFn) throw new $TypeError(tryToString(iterable) + ' is not iterable');
2983
- // optimisation for array iterators
2984
- if (isArrayIteratorMethod(iterFn)) {
2985
- for (index = 0, length = lengthOfArrayLike(iterable); length > index; index++) {
2986
- result = callFn(iterable[index]);
2987
- if (result && isPrototypeOf(ResultPrototype, result)) return result;
2988
- } return new Result(false);
3547
+ if (isCallable$1(NativePromiseConstructor$2) && NativePromisePrototype$1 !== Object.prototype) {
3548
+ nativeThen = NativePromisePrototype$1.then;
3549
+
3550
+ if (!NATIVE_PROMISE_SUBCLASSING) {
3551
+ // make `Promise#then` return a polyfilled `Promise` for native promise-based APIs
3552
+ defineBuiltIn$1(NativePromisePrototype$1, 'then', function then(onFulfilled, onRejected) {
3553
+ var that = this;
3554
+ return new PromiseConstructor(function (resolve, reject) {
3555
+ call$3(nativeThen, that, resolve, reject);
3556
+ }).then(onFulfilled, onRejected);
3557
+ // https://github.com/zloirock/core-js/issues/640
3558
+ }, { unsafe: true });
2989
3559
  }
2990
- iterator = getIterator(iterable, iterFn);
2991
- }
2992
3560
 
2993
- next = IS_RECORD ? iterable.next : iterator.next;
2994
- while (!(step = call$3(next, iterator)).done) {
3561
+ // make `.constructor === Promise` work for native promise-based APIs
2995
3562
  try {
2996
- result = callFn(step.value);
2997
- } catch (error) {
2998
- iteratorClose(iterator, 'throw', error);
3563
+ delete NativePromisePrototype$1.constructor;
3564
+ } catch (error) { /* empty */ }
3565
+
3566
+ // make `instanceof Promise` work for native promise-based APIs
3567
+ if (setPrototypeOf) {
3568
+ setPrototypeOf(NativePromisePrototype$1, PromisePrototype);
2999
3569
  }
3000
- if (typeof result == 'object' && result && isPrototypeOf(ResultPrototype, result)) return result;
3001
- } return new Result(false);
3002
- };
3570
+ }
3571
+ }
3572
+
3573
+ $$7({ global: true, constructor: true, wrap: true, forced: FORCED_PROMISE_CONSTRUCTOR$4 }, {
3574
+ Promise: PromiseConstructor
3575
+ });
3003
3576
 
3004
- var wellKnownSymbol = wellKnownSymbol$e;
3577
+ setToStringTag(PromiseConstructor, PROMISE, false);
3578
+ setSpecies(PROMISE);
3579
+
3580
+ var wellKnownSymbol = wellKnownSymbol$g;
3005
3581
 
3006
3582
  var ITERATOR = wellKnownSymbol('iterator');
3007
3583
  var SAFE_CLOSING = false;
@@ -3050,17 +3626,17 @@ var promiseStaticsIncorrectIteration = FORCED_PROMISE_CONSTRUCTOR$3 || !checkCor
3050
3626
  NativePromiseConstructor$1.all(iterable).then(undefined, function () { /* empty */ });
3051
3627
  });
3052
3628
 
3053
- var $$5 = _export;
3629
+ var $$6 = _export;
3054
3630
  var call$2 = functionCall;
3055
- var aCallable$1 = aCallable$8;
3631
+ var aCallable$1 = aCallable$c;
3056
3632
  var newPromiseCapabilityModule$2 = newPromiseCapability$2;
3057
3633
  var perform$1 = perform$3;
3058
- var iterate$1 = iterate$2;
3634
+ var iterate$1 = iterate$4;
3059
3635
  var PROMISE_STATICS_INCORRECT_ITERATION$1 = promiseStaticsIncorrectIteration;
3060
3636
 
3061
3637
  // `Promise.all` method
3062
3638
  // https://tc39.es/ecma262/#sec-promise.all
3063
- $$5({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION$1 }, {
3639
+ $$6({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION$1 }, {
3064
3640
  all: function all(iterable) {
3065
3641
  var C = this;
3066
3642
  var capability = newPromiseCapabilityModule$2.f(C);
@@ -3089,18 +3665,18 @@ $$5({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION
3089
3665
  }
3090
3666
  });
3091
3667
 
3092
- var $$4 = _export;
3668
+ var $$5 = _export;
3093
3669
  var FORCED_PROMISE_CONSTRUCTOR$2 = promiseConstructorDetection.CONSTRUCTOR;
3094
3670
  var NativePromiseConstructor = promiseNativeConstructor;
3095
- var getBuiltIn$1 = getBuiltIn$7;
3096
- var isCallable = isCallable$j;
3097
- var defineBuiltIn = defineBuiltIn$5;
3671
+ var getBuiltIn$1 = getBuiltIn$8;
3672
+ var isCallable = isCallable$l;
3673
+ var defineBuiltIn = defineBuiltIn$6;
3098
3674
 
3099
3675
  var NativePromisePrototype = NativePromiseConstructor && NativePromiseConstructor.prototype;
3100
3676
 
3101
3677
  // `Promise.prototype.catch` method
3102
3678
  // https://tc39.es/ecma262/#sec-promise.prototype.catch
3103
- $$4({ target: 'Promise', proto: true, forced: FORCED_PROMISE_CONSTRUCTOR$2, real: true }, {
3679
+ $$5({ target: 'Promise', proto: true, forced: FORCED_PROMISE_CONSTRUCTOR$2, real: true }, {
3104
3680
  'catch': function (onRejected) {
3105
3681
  return this.then(undefined, onRejected);
3106
3682
  }
@@ -3114,17 +3690,17 @@ if (isCallable(NativePromiseConstructor)) {
3114
3690
  }
3115
3691
  }
3116
3692
 
3117
- var $$3 = _export;
3693
+ var $$4 = _export;
3118
3694
  var call$1 = functionCall;
3119
- var aCallable = aCallable$8;
3695
+ var aCallable = aCallable$c;
3120
3696
  var newPromiseCapabilityModule$1 = newPromiseCapability$2;
3121
3697
  var perform = perform$3;
3122
- var iterate = iterate$2;
3698
+ var iterate = iterate$4;
3123
3699
  var PROMISE_STATICS_INCORRECT_ITERATION = promiseStaticsIncorrectIteration;
3124
3700
 
3125
3701
  // `Promise.race` method
3126
3702
  // https://tc39.es/ecma262/#sec-promise.race
3127
- $$3({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION }, {
3703
+ $$4({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION }, {
3128
3704
  race: function race(iterable) {
3129
3705
  var C = this;
3130
3706
  var capability = newPromiseCapabilityModule$1.f(C);
@@ -3140,13 +3716,13 @@ $$3({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION
3140
3716
  }
3141
3717
  });
3142
3718
 
3143
- var $$2 = _export;
3719
+ var $$3 = _export;
3144
3720
  var newPromiseCapabilityModule = newPromiseCapability$2;
3145
3721
  var FORCED_PROMISE_CONSTRUCTOR$1 = promiseConstructorDetection.CONSTRUCTOR;
3146
3722
 
3147
3723
  // `Promise.reject` method
3148
3724
  // https://tc39.es/ecma262/#sec-promise.reject
3149
- $$2({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR$1 }, {
3725
+ $$3({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR$1 }, {
3150
3726
  reject: function reject(r) {
3151
3727
  var capability = newPromiseCapabilityModule.f(this);
3152
3728
  var capabilityReject = capability.reject;
@@ -3155,8 +3731,8 @@ $$2({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR$1 }, {
3155
3731
  }
3156
3732
  });
3157
3733
 
3158
- var anObject = anObject$a;
3159
- var isObject = isObject$9;
3734
+ var anObject = anObject$f;
3735
+ var isObject = isObject$c;
3160
3736
  var newPromiseCapability = newPromiseCapability$2;
3161
3737
 
3162
3738
  var promiseResolve$1 = function (C, x) {
@@ -3168,8 +3744,8 @@ var promiseResolve$1 = function (C, x) {
3168
3744
  return promiseCapability.promise;
3169
3745
  };
3170
3746
 
3171
- var $$1 = _export;
3172
- var getBuiltIn = getBuiltIn$7;
3747
+ var $$2 = _export;
3748
+ var getBuiltIn = getBuiltIn$8;
3173
3749
  var FORCED_PROMISE_CONSTRUCTOR = promiseConstructorDetection.CONSTRUCTOR;
3174
3750
  var promiseResolve = promiseResolve$1;
3175
3751
 
@@ -3177,7 +3753,7 @@ getBuiltIn('Promise');
3177
3753
 
3178
3754
  // `Promise.resolve` method
3179
3755
  // https://tc39.es/ecma262/#sec-promise.resolve
3180
- $$1({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR }, {
3756
+ $$2({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR }, {
3181
3757
  resolve: function resolve(x) {
3182
3758
  return promiseResolve(this, x);
3183
3759
  }
@@ -3189,29 +3765,6 @@ $$1({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR }, {
3189
3765
  * @param iteration
3190
3766
  * @returns
3191
3767
  */
3192
-
3193
- function _async$2(f) {
3194
- return function () {
3195
- for (var args = [], i = 0; i < arguments.length; i++) {
3196
- args[i] = arguments[i];
3197
- }
3198
- try {
3199
- return Promise.resolve(f.apply(this, args));
3200
- } catch (e) {
3201
- return Promise.reject(e);
3202
- }
3203
- };
3204
- } /**
3205
- * Automatically calls next up to the current maxPageLoadLimit configured on the iterator.
3206
- *
3207
- * If no maximum limit is defined, uses the defaultLimit. If default limit is not defined or null, this will result in an error.
3208
- *
3209
- * The promise will reject with an error if an error is encountered.
3210
- *
3211
- * @param iterator
3212
- * @param defaultLimit
3213
- * @returns
3214
- */
3215
3768
  function iterationHasNextAndCanLoadMore(iteration) {
3216
3769
  return iteration.canLoadMore$.pipe(rxjs.switchMap(canLoadMore => {
3217
3770
  if (canLoadMore) {
@@ -3221,6 +3774,17 @@ function iterationHasNextAndCanLoadMore(iteration) {
3221
3774
  }
3222
3775
  }), rxjs.shareReplay(1));
3223
3776
  }
3777
+ /**
3778
+ * Automatically calls next up to the current maxPageLoadLimit configured on the iterator.
3779
+ *
3780
+ * If no maximum limit is defined, uses the defaultLimit. If default limit is not defined or null, this will result in an error.
3781
+ *
3782
+ * The promise will reject with an error if an error is encountered.
3783
+ *
3784
+ * @param iterator
3785
+ * @param defaultLimit
3786
+ * @returns
3787
+ */
3224
3788
  function iteratorNextPageUntilMaxPageLoadLimit(iterator, defaultLimit = 100) {
3225
3789
  return iteratorNextPageUntilPage(iterator, () => {
3226
3790
  var _iterator$getMaxPageL;
@@ -3253,12 +3817,8 @@ function iteratorNextPageUntilPage(iteration, page) {
3253
3817
  next: firstLatestPage => {
3254
3818
  const promise = util.performTaskLoop({
3255
3819
  initValue: firstLatestPage,
3256
- checkContinue: _async$2(function (latestPage) {
3257
- return rxjs.firstValueFrom(iterationHasNextAndCanLoadMore(iteration)).then(canLoadMore => canLoadMore && checkPageLimit(latestPage));
3258
- }),
3259
- next: _async$2(function () {
3260
- return iteration.nextPage();
3261
- })
3820
+ checkContinue: async latestPage => rxjs.firstValueFrom(iterationHasNextAndCanLoadMore(iteration)).then(canLoadMore => canLoadMore && checkPageLimit(latestPage)),
3821
+ next: async () => await iteration.nextPage()
3262
3822
  });
3263
3823
  resolve(promise);
3264
3824
  },
@@ -3269,6 +3829,92 @@ function iteratorNextPageUntilPage(iteration, page) {
3269
3829
  });
3270
3830
  }
3271
3831
 
3832
+ var classof = classofRaw$2;
3833
+
3834
+ // `IsArray` abstract operation
3835
+ // https://tc39.es/ecma262/#sec-isarray
3836
+ // eslint-disable-next-line es/no-array-isarray -- safe
3837
+ var isArray$1 = Array.isArray || function isArray(argument) {
3838
+ return classof(argument) === 'Array';
3839
+ };
3840
+
3841
+ var DESCRIPTORS$1 = descriptors;
3842
+ var isArray = isArray$1;
3843
+
3844
+ var $TypeError$1 = TypeError;
3845
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
3846
+ var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
3847
+
3848
+ // Safari < 13 does not throw an error in this case
3849
+ var SILENT_ON_NON_WRITABLE_LENGTH_SET = DESCRIPTORS$1 && !function () {
3850
+ // makes no sense without proper strict mode support
3851
+ if (this !== undefined) return true;
3852
+ try {
3853
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
3854
+ Object.defineProperty([], 'length', { writable: false }).length = 1;
3855
+ } catch (error) {
3856
+ return error instanceof TypeError;
3857
+ }
3858
+ }();
3859
+
3860
+ var arraySetLength = SILENT_ON_NON_WRITABLE_LENGTH_SET ? function (O, length) {
3861
+ if (isArray(O) && !getOwnPropertyDescriptor(O, 'length').writable) {
3862
+ throw new $TypeError$1('Cannot set read only .length');
3863
+ } return O.length = length;
3864
+ } : function (O, length) {
3865
+ return O.length = length;
3866
+ };
3867
+
3868
+ var $TypeError = TypeError;
3869
+ var MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF; // 2 ** 53 - 1 == 9007199254740991
3870
+
3871
+ var doesNotExceedSafeInteger$1 = function (it) {
3872
+ if (it > MAX_SAFE_INTEGER) throw $TypeError('Maximum allowed index exceeded');
3873
+ return it;
3874
+ };
3875
+
3876
+ var $$1 = _export;
3877
+ var toObject$1 = toObject$4;
3878
+ var lengthOfArrayLike = lengthOfArrayLike$3;
3879
+ var setArrayLength = arraySetLength;
3880
+ var doesNotExceedSafeInteger = doesNotExceedSafeInteger$1;
3881
+ var fails$1 = fails$g;
3882
+
3883
+ var INCORRECT_TO_LENGTH = fails$1(function () {
3884
+ return [].push.call({ length: 0x100000000 }, 1) !== 4294967297;
3885
+ });
3886
+
3887
+ // V8 <= 121 and Safari <= 15.4; FF < 23 throws InternalError
3888
+ // https://bugs.chromium.org/p/v8/issues/detail?id=12681
3889
+ var properErrorOnNonWritableLength = function () {
3890
+ try {
3891
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
3892
+ Object.defineProperty([], 'length', { writable: false }).push();
3893
+ } catch (error) {
3894
+ return error instanceof TypeError;
3895
+ }
3896
+ };
3897
+
3898
+ var FORCED = INCORRECT_TO_LENGTH || !properErrorOnNonWritableLength();
3899
+
3900
+ // `Array.prototype.push` method
3901
+ // https://tc39.es/ecma262/#sec-array.prototype.push
3902
+ $$1({ target: 'Array', proto: true, arity: 1, forced: FORCED }, {
3903
+ // eslint-disable-next-line no-unused-vars -- required for `.length`
3904
+ push: function push(item) {
3905
+ var O = toObject$1(this);
3906
+ var len = lengthOfArrayLike(O);
3907
+ var argCount = arguments.length;
3908
+ doesNotExceedSafeInteger(len + argCount);
3909
+ for (var i = 0; i < argCount; i++) {
3910
+ O[len] = arguments[i];
3911
+ len++;
3912
+ }
3913
+ setArrayLength(O, len);
3914
+ return len;
3915
+ }
3916
+ });
3917
+
3272
3918
  function distinctUntilArrayLengthChanges(inputGetArray) {
3273
3919
  const getArray = inputGetArray != null ? inputGetArray : value => util.asArray(value);
3274
3920
  return rxjs.distinctUntilChanged((a, b) => a === b, x => getArray(x).length);
@@ -3663,11 +4309,11 @@ function distinctUntilMapHasDifferentKeys() {
3663
4309
  var DESCRIPTORS = descriptors;
3664
4310
  var uncurryThis = functionUncurryThis;
3665
4311
  var call = functionCall;
3666
- var fails = fails$d;
4312
+ var fails = fails$g;
3667
4313
  var objectKeys = objectKeys$2;
3668
4314
  var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols;
3669
4315
  var propertyIsEnumerableModule = objectPropertyIsEnumerable;
3670
- var toObject = toObject$3;
4316
+ var toObject = toObject$4;
3671
4317
  var IndexedObject = indexedObject;
3672
4318
 
3673
4319
  // eslint-disable-next-line es/no-object-assign -- safe
@@ -4016,6 +4662,23 @@ function useFirst(obs, useFn) {
4016
4662
  obs.pipe(rxjs.first()).subscribe(useFn);
4017
4663
  }
4018
4664
 
4665
+ /**
4666
+ * Creates a switchMap operator that will emit the stream of events from the input LoadingContext as soon as a non-null LoadingContext is emitted.
4667
+ */
4668
+ function switchMapMaybeLoadingContextStream() {
4669
+ return rxjs.switchMap(x => x != null ? x.stream$ : rxjs.of(undefined));
4670
+ }
4671
+
4672
+ /**
4673
+ * Returns true if the input LoadingErrorPair has the same loading (truthy vs falsy) and error values as the other LoadingErrorPair.
4674
+ *
4675
+ * @param a LoadingErrorPair a
4676
+ * @param b LoadingErrorPair b
4677
+ * @returns Returns true if the input's metadata is considered equivalent.
4678
+ */
4679
+ function isLoadingStateMetadataEqual(a, b) {
4680
+ return a.loading == b.loading && util.valuesAreBothNullishOrEquivalent(a.error, b.error);
4681
+ }
4019
4682
  // MARK: Utility
4020
4683
  /**
4021
4684
  * Describes a LoadingState's current state type.
@@ -4425,58 +5088,6 @@ const updatedStateForSetValue = mergeLoadingStateWithValue;
4425
5088
  */
4426
5089
  const updatedStateForSetError = mergeLoadingStateWithError;
4427
5090
 
4428
- /**
4429
- * Abstract LoadingContext implementation using LoadingState.
4430
- */
4431
- class AbstractLoadingStateContextInstance {
4432
- constructor(_config) {
4433
- this._stateSubject = new rxjs.BehaviorSubject(undefined);
4434
- this._config = new rxjs.BehaviorSubject(undefined);
4435
- this.config$ = this._config.pipe(filterMaybe(), rxjs.shareReplay(1));
4436
- this.stateSubject$ = this._stateSubject.pipe(filterMaybe(), rxjs.distinctUntilChanged(), rxjs.shareReplay(1));
4437
- this.state$ = this.stateSubject$.pipe(rxjs.switchMap(x => x), rxjs.shareReplay(1));
4438
- this.stateObs$ = this._stateSubject.asObservable();
4439
- this.stream$ = this.stateObs$.pipe(rxjs.mergeMap(obs => {
4440
- if (obs) {
4441
- return obs.pipe(
4442
- // If the observable did not pass a value immediately, we start with the start value.
4443
- timeoutStartWith(beginLoading()), rxjs.combineLatestWith(this.config$), rxjs.map(([x, config]) => this.loadingEventForLoadingPair(x, config)));
4444
- } else {
4445
- return rxjs.of(beginLoading());
4446
- }
4447
- }), rxjs.distinctUntilChanged((a, b) => {
4448
- return a.loading === b.loading && a.error === b.error && a.value === b.value;
4449
- }), rxjs.shareReplay(1));
4450
- /**
4451
- * Emits when the input state has changed.
4452
- */
4453
- this.stateChange$ = this._stateSubject.pipe(rxjs.map(() => undefined));
4454
- this.loading$ = this.stream$.pipe(rxjs.map(x => x.loading), rxjs.shareReplay(1));
4455
- let nextConfig;
4456
- if (rxjs.isObservable(_config)) {
4457
- nextConfig = {
4458
- obs: _config
4459
- };
4460
- } else {
4461
- nextConfig = _config != null ? _config : {
4462
- showLoadingOnNoValue: false
4463
- };
4464
- }
4465
- this._config.next(nextConfig);
4466
- // Only set once
4467
- if (nextConfig.obs) {
4468
- this.setStateObs(nextConfig.obs);
4469
- }
4470
- }
4471
- setStateObs(state) {
4472
- this._stateSubject.next(state);
4473
- }
4474
- destroy() {
4475
- this._stateSubject.complete();
4476
- this._config.complete();
4477
- }
4478
- }
4479
-
4480
5091
  // TODO(BREAKING_CHANGE): Fix all LoadingState types to use the LoadingStateValue inference typings
4481
5092
  /**
4482
5093
  * Wraps an observable output and maps the value to a LoadingState.
@@ -4540,7 +5151,7 @@ function startWithBeginLoading(state) {
4540
5151
  */
4541
5152
  function valueFromLoadingState() {
4542
5153
  return obs => {
4543
- return obs.pipe(rxjs.filter(isLoadingStateWithDefinedValue), rxjs.map(x => x.value));
5154
+ return obs.pipe(rxjs.map(x => x.value));
4544
5155
  };
4545
5156
  }
4546
5157
  /**
@@ -4656,9 +5267,9 @@ function distinctLoadingState(inputConfig) {
4656
5267
  // pick the value
4657
5268
  const value = isSameValue ? acc.value : nextValue;
4658
5269
  const current = Object.assign({}, state, {
5270
+ // copy all metadata over
4659
5271
  value // set the new value
4660
5272
  });
4661
-
4662
5273
  return Object.assign({}, acc, {
4663
5274
  value,
4664
5275
  isSameValue,
@@ -4696,6 +5307,85 @@ function promiseFromLoadingState(obs) {
4696
5307
  });
4697
5308
  }
4698
5309
 
5310
+ const DEFAULT_LOADING_EVENT_FOR_LOADING_PAIR_FUNCTION = (state, input) => {
5311
+ const {
5312
+ showLoadingOnUndefinedValue
5313
+ } = input;
5314
+ const {
5315
+ error,
5316
+ value
5317
+ } = state;
5318
+ let loading = false;
5319
+ if (!util.hasNonNullValue(error)) {
5320
+ if (showLoadingOnUndefinedValue) {
5321
+ loading = !util.hasNonNullValue(value);
5322
+ } else {
5323
+ loading = isLoadingStateLoading(state);
5324
+ }
5325
+ }
5326
+ return {
5327
+ loading,
5328
+ error,
5329
+ value
5330
+ };
5331
+ };
5332
+ /**
5333
+ * Creates a new LoadingStateContext from the input.
5334
+
5335
+ * @param input LoadingStateContextInput
5336
+ * @returns LoadingStateContext
5337
+ */
5338
+ function loadingStateContext(input) {
5339
+ var _config$loadingEventF, _ref, _config$showLoadingOn;
5340
+ const _config = input && rxjs.isObservable(input) ? {
5341
+ obs: input
5342
+ } : input;
5343
+ const loadingEventForLoadingPair = (_config$loadingEventF = _config == null ? void 0 : _config.loadingEventForLoadingPair) != null ? _config$loadingEventF : DEFAULT_LOADING_EVENT_FOR_LOADING_PAIR_FUNCTION;
5344
+ const showLoadingOnUndefinedValue = (_ref = (_config$showLoadingOn = _config == null ? void 0 : _config.showLoadingOnUndefinedValue) != null ? _config$showLoadingOn : _config == null ? void 0 : _config.showLoadingOnNoValue) != null ? _ref : false;
5345
+ const _stateStream = new rxjs.BehaviorSubject(_config == null ? void 0 : _config.obs);
5346
+ const currentStateStream$ = _stateStream.asObservable();
5347
+ const stateStream$ = currentStateStream$.pipe(filterMaybe());
5348
+ const eventStream$ = currentStateStream$.pipe(rxjs.switchMap(obs => {
5349
+ let result;
5350
+ if (obs) {
5351
+ result = obs.pipe(filterMaybe(),
5352
+ // If the observable did not pass a value immediately, we start with the start value.
5353
+ timeoutStartWith(beginLoading()), rxjs.map(x => loadingEventForLoadingPair(x, {
5354
+ showLoadingOnUndefinedValue
5355
+ })));
5356
+ } else {
5357
+ result = rxjs.of(beginLoading());
5358
+ }
5359
+ return result;
5360
+ }), rxjs.distinctUntilChanged((a, b) => a.loading === b.loading && a.error === b.error && (a == null ? void 0 : a.value) === (b == null ? void 0 : b.value)), rxjs.shareReplay(1));
5361
+ const currentState$ = currentStateStream$.pipe(rxjs.switchMap(x => x ? x : rxjs.of(undefined)));
5362
+ const state$ = currentState$.pipe(filterMaybe(), rxjs.shareReplay(1));
5363
+ const loading$ = eventStream$.pipe(rxjs.map(isLoadingStateLoading));
5364
+ const currentValue$ = state$.pipe(valueFromLoadingState(), rxjs.shareReplay(1));
5365
+ const valueAfterLoaded$ = state$.pipe(valueFromFinishedLoadingState(), rxjs.shareReplay(1));
5366
+ const value$ = valueAfterLoaded$.pipe(filterMaybe(), rxjs.shareReplay(1));
5367
+ function setStateObs(obs) {
5368
+ _stateStream.next(obs);
5369
+ }
5370
+ function destroy() {
5371
+ _stateStream.complete();
5372
+ }
5373
+ const loadingStateContext = {
5374
+ currentStateStream$,
5375
+ stateStream$,
5376
+ stream$: eventStream$,
5377
+ currentState$,
5378
+ state$,
5379
+ loading$,
5380
+ currentValue$,
5381
+ valueAfterLoaded$,
5382
+ value$,
5383
+ setStateObs,
5384
+ destroy
5385
+ };
5386
+ return loadingStateContext;
5387
+ }
5388
+
4699
5389
  /**
4700
5390
  * Returns true if the loading state is not loading and is empty.
4701
5391
  *
@@ -4733,104 +5423,40 @@ const listLoadingStateIsEmpty = isListLoadingStateWithEmptyValue;
4733
5423
  const isListLoadingStateEmpty = mapIsListLoadingStateWithEmptyValue;
4734
5424
 
4735
5425
  /**
4736
- * LoadingContext implementation that uses a ListLoadingState observable.
4737
- */
4738
- class ListLoadingStateContextInstance extends AbstractLoadingStateContextInstance {
4739
- constructor(...args) {
4740
- super(...args);
4741
- /**
4742
- * Returns the current values or an empty list.
4743
- */
4744
- this.list$ = this.stream$.pipe(rxjs.map(x => {
4745
- var _x$value;
4746
- return (_x$value = x.value) != null ? _x$value : [];
4747
- }), rxjs.shareReplay(1));
4748
- /**
4749
- * Returns true while loading and the current value is considered empty.
4750
- */
4751
- this.isEmptyLoading$ = this.stream$.pipe(rxjs.map(x => isLoadingStateLoading(x) && isListLoadingStateWithEmptyValue(x)), rxjs.distinctUntilChanged(), rxjs.shareReplay(1));
4752
- /**
4753
- * Whether or not the current value is empty.
4754
- *
4755
- * Only resolves when the first non-loading event has occured.
4756
- *
4757
- * After that, will return true if the value is empty even if loading a new value.
4758
- */
4759
- this.isEmpty$ = this.stream$.pipe(rxjs.skipWhile(x => isLoadingStateLoading(x)),
4760
- // skip until the first non-loading event has occured
4761
- mapIsListLoadingStateWithEmptyValue(), rxjs.distinctUntilChanged());
4762
- /**
4763
- * Whether or not the current value is empty and not loading.
4764
- *
4765
- * Only resolves when the first non-loading event has occured.
4766
- *
4767
- * After that, will return true if the value is empty even if loading a new value.
4768
- */
4769
- this.isEmptyAndNotLoading$ = this.stream$.pipe(rxjs.skipWhile(x => isLoadingStateLoading(x)),
4770
- // skip until the first non-loading event has occured
4771
- rxjs.map(x => !isLoadingStateLoading(x) && isListLoadingStateWithEmptyValue(x)), rxjs.distinctUntilChanged());
4772
- }
4773
- loadingEventForLoadingPair(state, config = {}) {
4774
- const {
4775
- showLoadingOnNoValue
4776
- } = config;
4777
- let loading = state == null ? void 0 : state.loading;
4778
- const error = state == null ? void 0 : state.error;
4779
- let value = state == null ? void 0 : state.value;
4780
- const hasValue = value != null;
4781
- if (hasValue) {
4782
- value = util.limitArray(value, config); // Always limit the value/results.
4783
- }
4784
- // If there is no error
4785
- if (!util.hasNonNullValue(error)) {
4786
- if (showLoadingOnNoValue) {
4787
- loading = !hasValue;
4788
- } else {
4789
- loading = isLoadingStateLoading(state);
4790
- }
4791
- }
4792
- return {
4793
- loading: Boolean(loading),
4794
- error,
4795
- value
4796
- };
4797
- }
4798
- }
4799
- function listLoadingStateContext(config) {
4800
- return new ListLoadingStateContextInstance(config);
4801
- }
4802
-
4803
- /**
4804
- * LoadingContext implementation for a LoadingState.
5426
+ * Creates a ListLoadingStateContext.
5427
+ *
5428
+ * @param input Optional configuration for the ListLoadingStateContext.
5429
+ * @returns A ListLoadingStateContext.
4805
5430
  */
4806
- class LoadingStateContextInstance extends AbstractLoadingStateContextInstance {
4807
- constructor(...args) {
4808
- super(...args);
4809
- this.value$ = this.stream$.pipe(rxjs.map(x => x.value), rxjs.shareReplay(1));
4810
- this.valueAfterLoaded$ = this.stream$.pipe(rxjs.filter(x => !x.loading), rxjs.map(x => x.value), rxjs.shareReplay(1));
4811
- }
4812
- loadingEventForLoadingPair(pair, {
4813
- showLoadingOnNoValue
4814
- } = {}) {
4815
- let loading = false;
4816
- const error = pair == null ? void 0 : pair.error;
4817
- const value = pair == null ? void 0 : pair.value;
4818
- if (!util.hasNonNullValue(error)) {
4819
- if (showLoadingOnNoValue) {
4820
- loading = !util.hasNonNullValue(value);
4821
- } else {
4822
- loading = isLoadingStateLoading(pair);
5431
+ function listLoadingStateContext(input) {
5432
+ const limitArrayConfig = typeof input === 'object' ? input : undefined;
5433
+ const loadingState = loadingStateContext(Object.assign({}, input, {
5434
+ loadingEventForLoadingPair: (state, config) => {
5435
+ const result = DEFAULT_LOADING_EVENT_FOR_LOADING_PAIR_FUNCTION(state, config);
5436
+ const hasValue = util.hasNonNullValue(result.value);
5437
+ if (hasValue) {
5438
+ result.value = util.limitArray(result.value, limitArrayConfig); // Always limit the value/results.
4823
5439
  }
5440
+ return result;
4824
5441
  }
4825
- return {
4826
- loading,
4827
- error,
4828
- value
4829
- };
4830
- }
4831
- }
4832
- function loadingStateContext(config) {
4833
- return new LoadingStateContextInstance(config);
5442
+ }));
5443
+ const currentList$ = loadingState.value$;
5444
+ const listAfterLoaded$ = loadingState.valueAfterLoaded$;
5445
+ const list$ = loadingState.valueAfterLoaded$.pipe(rxjs.map(x => x != null ? x : []));
5446
+ const isEmpty$ = loadingState.stream$.pipe(rxjs.skipWhile(x => isLoadingStateLoading(x)),
5447
+ // skip until the first non-loading event has occured
5448
+ mapIsListLoadingStateWithEmptyValue(), rxjs.distinctUntilChanged());
5449
+ const isEmptyLoading$ = loadingState.stream$.pipe(rxjs.map(x => isLoadingStateLoading(x) && isListLoadingStateWithEmptyValue(x)), rxjs.distinctUntilChanged(), rxjs.shareReplay(1));
5450
+ const isEmptyAndNotLoading$ = loadingState.stream$.pipe(rxjs.map(x => !isLoadingStateLoading(x) && isListLoadingStateWithEmptyValue(x)), rxjs.distinctUntilChanged());
5451
+ const result = Object.assign({}, loadingState, {
5452
+ currentList$,
5453
+ listAfterLoaded$,
5454
+ list$,
5455
+ isEmpty$,
5456
+ isEmptyLoading$,
5457
+ isEmptyAndNotLoading$
5458
+ });
5459
+ return result;
4834
5460
  }
4835
5461
 
4836
5462
  /**
@@ -4838,28 +5464,28 @@ function loadingStateContext(config) {
4838
5464
  */
4839
5465
  class SimpleLoadingContext {
4840
5466
  constructor(loading = true) {
4841
- this._subject = void 0;
4842
- this._error = void 0;
4843
5467
  this._subject = new rxjs.BehaviorSubject({
4844
- loading
5468
+ loading: true
4845
5469
  });
5470
+ this.stream$ = this._subject.asObservable();
5471
+ this.setLoading(loading);
4846
5472
  }
4847
5473
  destroy() {
4848
5474
  this._subject.complete();
4849
5475
  }
4850
5476
  hasError() {
4851
- return Boolean(this._error);
5477
+ return isLoadingStateWithError(this._subject.value);
4852
5478
  }
4853
5479
  clearError() {
4854
- delete this._error;
4855
- }
4856
- get stream$() {
4857
- return this._subject.asObservable();
5480
+ this._subject.next(Object.assign({}, this._subject.value, {
5481
+ error: undefined
5482
+ }));
4858
5483
  }
4859
5484
  setSuccess() {
4860
5485
  this.setLoading(false);
4861
5486
  }
4862
5487
  setLoading(loading = true) {
5488
+ // clears the current error
4863
5489
  this._subject.next({
4864
5490
  loading
4865
5491
  });
@@ -4906,47 +5532,6 @@ class ValuesLoadingContext extends SimpleLoadingContext {
4906
5532
  }
4907
5533
  }
4908
5534
 
4909
- function _await$1(value, then, direct) {
4910
- if (direct) {
4911
- return then ? then(value) : value;
4912
- }
4913
- if (!value || !value.then) {
4914
- value = Promise.resolve(value);
4915
- }
4916
- return then ? value.then(then) : value;
4917
- } /**
4918
- * Automatically calls next on the accumulator's page item iteration up to the target number of results. Returns the total number of items loaded.
4919
- *
4920
- * The promise will reject with an error if an error is encountered.
4921
- *
4922
- * @param iteration
4923
- * @param maxResultsLimit
4924
- * @returns
4925
- */
4926
-
4927
- function _async$1(f) {
4928
- return function () {
4929
- for (var args = [], i = 0; i < arguments.length; i++) {
4930
- args[i] = arguments[i];
4931
- }
4932
- try {
4933
- return Promise.resolve(f.apply(this, args));
4934
- } catch (e) {
4935
- return Promise.reject(e);
4936
- }
4937
- };
4938
- }
4939
- function _call(body, then, direct) {
4940
- if (direct) {
4941
- return then ? then(body()) : body();
4942
- }
4943
- try {
4944
- var result = Promise.resolve(body());
4945
- return then ? result.then(then) : result;
4946
- } catch (e) {
4947
- return Promise.reject(e);
4948
- }
4949
- }
4950
5535
  function itemAccumulator(itemIteration, inputMapItem) {
4951
5536
  const mapItemFunction = inputMapItem != null ? inputMapItem : a => a;
4952
5537
  const hasCompletedInitialLoad$ = itemIteration.firstState$.pipe(rxjs.map(() => true), rxjs.startWith(false), rxjs.distinctUntilChanged(), rxjs.shareReplay(1));
@@ -4998,21 +5583,16 @@ function itemAccumulator(itemIteration, inputMapItem) {
4998
5583
  };
4999
5584
  return result;
5000
5585
  }
5586
+ /**
5587
+ * Automatically calls next on the accumulator's page item iteration up to the target number of results. Returns the total number of items loaded.
5588
+ *
5589
+ * The promise will reject with an error if an error is encountered.
5590
+ *
5591
+ * @param iteration
5592
+ * @param maxResultsLimit
5593
+ * @returns
5594
+ */
5001
5595
  function itemAccumulatorNextPageUntilResultsCount(config) {
5002
- const checkResultsLimit = _async$1(function () {
5003
- return _await$1(rxjs.firstValueFrom(accumulator.currentAllItems$), function (allItems) {
5004
- return _await$1(rxjs.firstValueFrom(canLoadMoreObs), function (canLoadMore) {
5005
- return _await$1(countResults(allItems), function (currentCount) {
5006
- const maxResultsLimit = getMaxResultsLimit();
5007
- const shouldContinue = canLoadMore && currentCount < maxResultsLimit;
5008
- return {
5009
- shouldContinue,
5010
- currentCount
5011
- };
5012
- });
5013
- });
5014
- });
5015
- });
5016
5596
  const {
5017
5597
  accumulator,
5018
5598
  maxResultsLimit,
@@ -5022,20 +5602,28 @@ function itemAccumulatorNextPageUntilResultsCount(config) {
5022
5602
  const canLoadMoreObs = iterationHasNextAndCanLoadMore(accumulator.itemIteration).pipe(timeoutStartWith(false, 100),
5023
5603
  // TODO: This can fail to emit anything if the iterator has been destroyed
5024
5604
  rxjs.shareReplay(1));
5605
+ async function checkResultsLimit() {
5606
+ const allItems = await rxjs.firstValueFrom(accumulator.currentAllItems$);
5607
+ const canLoadMore = await rxjs.firstValueFrom(canLoadMoreObs);
5608
+ const currentCount = await countResults(allItems);
5609
+ const maxResultsLimit = getMaxResultsLimit();
5610
+ const shouldContinue = canLoadMore && currentCount < maxResultsLimit;
5611
+ return {
5612
+ shouldContinue,
5613
+ currentCount
5614
+ };
5615
+ }
5025
5616
  return new Promise((resolve, reject) => {
5026
5617
  accumulator.currentAllItems$.pipe(rxjs.first(), rxjs.switchMap(allItems => rxjs.from(util.asPromise(countResults(allItems))))).subscribe({
5027
- next: _async$1(function (currentResultsCount) {
5618
+ next: async currentResultsCount => {
5028
5619
  util.performTaskLoop({
5029
5620
  initValue: currentResultsCount,
5030
- checkContinue: function (x, i) {
5031
- return _call(checkResultsLimit, function (result) {
5032
- currentResultsCount = result.currentCount;
5033
- return result.shouldContinue;
5034
- });
5621
+ checkContinue: async (x, i) => {
5622
+ const result = await checkResultsLimit();
5623
+ currentResultsCount = result.currentCount;
5624
+ return result.shouldContinue;
5035
5625
  },
5036
- next: _async$1(function () {
5037
- return accumulator.itemIteration.nextPage();
5038
- })
5626
+ next: async () => accumulator.itemIteration.nextPage()
5039
5627
  }).then(page => {
5040
5628
  resolve({
5041
5629
  page,
@@ -5045,8 +5633,7 @@ function itemAccumulatorNextPageUntilResultsCount(config) {
5045
5633
  reject(error);
5046
5634
  throw error;
5047
5635
  });
5048
- return _await$1();
5049
- }),
5636
+ },
5050
5637
  error: error => {
5051
5638
  reject(error);
5052
5639
  }
@@ -5170,32 +5757,10 @@ const mapPageItemIteration = mappedPageItemIteration;
5170
5757
  /**
5171
5758
  * Default number of pages that can be loaded.
5172
5759
  */
5173
-
5174
- function _await(value, then, direct) {
5175
- if (direct) {
5176
- return then ? then(value) : value;
5177
- }
5178
- if (!value || !value.then) {
5179
- value = Promise.resolve(value);
5180
- }
5181
- return then ? value.then(then) : value;
5182
- } /**
5183
- * Used for generating new iterations.
5184
- */
5185
-
5186
- function _async(f) {
5187
- return function () {
5188
- for (var args = [], i = 0; i < arguments.length; i++) {
5189
- args[i] = arguments[i];
5190
- }
5191
- try {
5192
- return Promise.resolve(f.apply(this, args));
5193
- } catch (e) {
5194
- return Promise.reject(e);
5195
- }
5196
- };
5197
- }
5198
5760
  const DEFAULT_ITEM_PAGE_ITERATOR_MAX = 100;
5761
+ /**
5762
+ * Used for generating new iterations.
5763
+ */
5199
5764
  class ItemPageIterator {
5200
5765
  constructor(delegate) {
5201
5766
  this._delegate = void 0;
@@ -5310,6 +5875,7 @@ class ItemPageIterationInstance {
5310
5875
  current: {
5311
5876
  page: util.FIRST_PAGE
5312
5877
  },
5878
+ // Start with loading the first page
5313
5879
  firstFinished: undefined,
5314
5880
  latestFinished: undefined,
5315
5881
  firstSuccessful: undefined,
@@ -5402,8 +5968,8 @@ class ItemPageIterationInstance {
5402
5968
  this._maxPageLoadLimit.next(limit);
5403
5969
  }
5404
5970
  nextPage(request = {}) {
5405
- const _this = this;
5406
- return new Promise(_async(function (resolve, reject) {
5971
+ var _this = this;
5972
+ return new Promise(async function (resolve, reject) {
5407
5973
  _this._nextFinished$.pipe(rxjs.exhaustMap(() => _this.latestPageResultState$), rxjs.defaultIfEmpty({
5408
5974
  error: undefined,
5409
5975
  page: -1
@@ -5420,8 +5986,7 @@ class ItemPageIterationInstance {
5420
5986
  }
5421
5987
  });
5422
5988
  _this.next(request);
5423
- return _await();
5424
- }));
5989
+ });
5425
5990
  }
5426
5991
  next(request = {}) {
5427
5992
  this._pushNext(request);
@@ -5465,7 +6030,6 @@ function itemPageIteratorShouldLoadNextPage(request, hasNextAndCanLoadMore, prev
5465
6030
  // Must not have any errors
5466
6031
  Boolean(request.page == null || nextIteratorPageNumber(prevResult) === request.page); // Must match the page, if provided
5467
6032
  }
5468
-
5469
6033
  function nextIteratorPageNumber(prevResult) {
5470
6034
  return isLoadingStateWithError(prevResult) ? prevResult.page : util.getNextPageNumber(prevResult);
5471
6035
  }
@@ -5547,7 +6111,6 @@ class LockSet {
5547
6111
  addLock(key, obs) {
5548
6112
  obs = obs.pipe(rxjs.defaultIfEmpty(false) // empty observables count as unlocked.
5549
6113
  );
5550
-
5551
6114
  const removeLock = () => this._removeObsForKey(obs, key);
5552
6115
  this._locks.value.set(key, obs);
5553
6116
  this._locks.next(this._locks.value);
@@ -5823,10 +6386,10 @@ function workFactoryForConfigFactory(configFactory) {
5823
6386
  };
5824
6387
  }
5825
6388
 
5826
- exports.AbstractLoadingStateContextInstance = AbstractLoadingStateContextInstance;
5827
6389
  exports.DEFAULT_ASYNC_PUSHER_THROTTLE = DEFAULT_ASYNC_PUSHER_THROTTLE;
5828
6390
  exports.DEFAULT_FACTORY_TIMER_INTERVAL = DEFAULT_FACTORY_TIMER_INTERVAL;
5829
6391
  exports.DEFAULT_ITEM_PAGE_ITERATOR_MAX = DEFAULT_ITEM_PAGE_ITERATOR_MAX;
6392
+ exports.DEFAULT_LOADING_EVENT_FOR_LOADING_PAIR_FUNCTION = DEFAULT_LOADING_EVENT_FOR_LOADING_PAIR_FUNCTION;
5830
6393
  exports.DEFAULT_LOCK_SET_TIME_LOCK_KEY = DEFAULT_LOCK_SET_TIME_LOCK_KEY;
5831
6394
  exports.FilterMap = FilterMap;
5832
6395
  exports.FilterMapKeyInstance = FilterMapKeyInstance;
@@ -5835,8 +6398,6 @@ exports.FilterSourceConnector = FilterSourceConnector;
5835
6398
  exports.FilterSourceInstance = FilterSourceInstance;
5836
6399
  exports.ItemPageIterationInstance = ItemPageIterationInstance;
5837
6400
  exports.ItemPageIterator = ItemPageIterator;
5838
- exports.ListLoadingStateContextInstance = ListLoadingStateContextInstance;
5839
- exports.LoadingStateContextInstance = LoadingStateContextInstance;
5840
6401
  exports.LockSet = LockSet;
5841
6402
  exports.MultiSubscriptionObject = MultiSubscriptionObject;
5842
6403
  exports.PresetFilterSource = PresetFilterSource;
@@ -5907,6 +6468,7 @@ exports.isLoadingStateInIdleState = isLoadingStateInIdleState;
5907
6468
  exports.isLoadingStateInLoadingState = isLoadingStateInLoadingState;
5908
6469
  exports.isLoadingStateInSuccessState = isLoadingStateInSuccessState;
5909
6470
  exports.isLoadingStateLoading = isLoadingStateLoading;
6471
+ exports.isLoadingStateMetadataEqual = isLoadingStateMetadataEqual;
5910
6472
  exports.isLoadingStateWithDefinedValue = isLoadingStateWithDefinedValue;
5911
6473
  exports.isLoadingStateWithError = isLoadingStateWithError;
5912
6474
  exports.isLoadingStateWithStateType = isLoadingStateWithStateType;
@@ -5934,6 +6496,8 @@ exports.loadingStateIsLoading = loadingStateIsLoading;
5934
6496
  exports.loadingStateType = loadingStateType;
5935
6497
  exports.loadingStatesHaveEquivalentMetadata = loadingStatesHaveEquivalentMetadata;
5936
6498
  exports.makeCheckIsFunction = makeCheckIsFunction;
6499
+ exports.makeIsModifiedFunction = makeIsModifiedFunction;
6500
+ exports.makeIsModifiedFunctionObservable = makeIsModifiedFunctionObservable;
5937
6501
  exports.makeMapFilterWithPresetFn = makeMapFilterWithPresetFn;
5938
6502
  exports.makeReturnIfIsFunction = makeReturnIfIsFunction;
5939
6503
  exports.mapEachAsync = mapEachAsync;
@@ -5951,6 +6515,7 @@ exports.mapMaybe = mapMaybe;
5951
6515
  exports.mapMultipleLoadingStateResults = mapMultipleLoadingStateResults;
5952
6516
  exports.mapPageItemIteration = mapPageItemIteration;
5953
6517
  exports.mappedPageItemIteration = mappedPageItemIteration;
6518
+ exports.maybeValueFromObservableOrValue = maybeValueFromObservableOrValue;
5954
6519
  exports.maybeValueFromObservableOrValueGetter = maybeValueFromObservableOrValueGetter;
5955
6520
  exports.mergeLoadingStateWithError = mergeLoadingStateWithError;
5956
6521
  exports.mergeLoadingStateWithLoading = mergeLoadingStateWithLoading;
@@ -5979,8 +6544,10 @@ exports.skipFirstMaybe = skipFirstMaybe;
5979
6544
  exports.startWithBeginLoading = startWithBeginLoading;
5980
6545
  exports.successPageResult = successPageResult;
5981
6546
  exports.successResult = successResult;
6547
+ exports.switchMapFilterMaybe = switchMapFilterMaybe;
6548
+ exports.switchMapMaybe = switchMapMaybe;
5982
6549
  exports.switchMapMaybeDefault = switchMapMaybeDefault;
5983
- exports.switchMapMaybeObs = switchMapMaybeObs;
6550
+ exports.switchMapMaybeLoadingContextStream = switchMapMaybeLoadingContextStream;
5984
6551
  exports.switchMapObject = switchMapObject;
5985
6552
  exports.switchMapOnBoolean = switchMapOnBoolean;
5986
6553
  exports.switchMapToDefault = switchMapToDefault;