@acrobits/ipc-sdk 0.11.2-alpha.0 → 0.11.2-alpha.2

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/lib/ipc-sdk.js CHANGED
@@ -1,48 +1,48 @@
1
1
  var Ae = Object.defineProperty;
2
- var Pe = (n, t, e) => t in n ? Ae(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e;
3
- var M = (n, t, e) => (Pe(n, typeof t != "symbol" ? t + "" : t, e), e);
4
- var C = /* @__PURE__ */ ((n) => (n.BadgeQuery = "BADGE QUERY", n.Lifecycle = "LIFECYCLE", n.PushToken = "PUSH TOKEN", n.RequestLogs = "REQUEST LOGS", n))(C || {}), B = function(n, t) {
2
+ var Pe = (s, t, e) => t in s ? Ae(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e;
3
+ var M = (s, t, e) => (Pe(s, typeof t != "symbol" ? t + "" : t, e), e);
4
+ var S = /* @__PURE__ */ ((s) => (s.BadgeQuery = "BADGE QUERY", s.Lifecycle = "LIFECYCLE", s.PushToken = "PUSH TOKEN", s.RequestLogs = "REQUEST LOGS", s))(S || {}), B = function(s, t) {
5
5
  return B = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e, r) {
6
6
  e.__proto__ = r;
7
7
  } || function(e, r) {
8
- for (var s in r)
9
- Object.prototype.hasOwnProperty.call(r, s) && (e[s] = r[s]);
10
- }, B(n, t);
8
+ for (var n in r)
9
+ Object.prototype.hasOwnProperty.call(r, n) && (e[n] = r[n]);
10
+ }, B(s, t);
11
11
  };
12
- function U(n, t) {
12
+ function U(s, t) {
13
13
  if (typeof t != "function" && t !== null)
14
14
  throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
15
- B(n, t);
15
+ B(s, t);
16
16
  function e() {
17
- this.constructor = n;
17
+ this.constructor = s;
18
18
  }
19
- n.prototype = t === null ? Object.create(t) : (e.prototype = t.prototype, new e());
19
+ s.prototype = t === null ? Object.create(t) : (e.prototype = t.prototype, new e());
20
20
  }
21
- function Q(n) {
22
- var t = typeof Symbol == "function" && Symbol.iterator, e = t && n[t], r = 0;
21
+ function Q(s) {
22
+ var t = typeof Symbol == "function" && Symbol.iterator, e = t && s[t], r = 0;
23
23
  if (e)
24
- return e.call(n);
25
- if (n && typeof n.length == "number")
24
+ return e.call(s);
25
+ if (s && typeof s.length == "number")
26
26
  return {
27
27
  next: function() {
28
- return n && r >= n.length && (n = void 0), { value: n && n[r++], done: !n };
28
+ return s && r >= s.length && (s = void 0), { value: s && s[r++], done: !s };
29
29
  }
30
30
  };
31
31
  throw new TypeError(t ? "Object is not iterable." : "Symbol.iterator is not defined.");
32
32
  }
33
- function $(n, t) {
34
- var e = typeof Symbol == "function" && n[Symbol.iterator];
33
+ function $(s, t) {
34
+ var e = typeof Symbol == "function" && s[Symbol.iterator];
35
35
  if (!e)
36
- return n;
37
- var r = e.call(n), s, i = [], o;
36
+ return s;
37
+ var r = e.call(s), n, i = [], o;
38
38
  try {
39
- for (; (t === void 0 || t-- > 0) && !(s = r.next()).done; )
40
- i.push(s.value);
39
+ for (; (t === void 0 || t-- > 0) && !(n = r.next()).done; )
40
+ i.push(n.value);
41
41
  } catch (c) {
42
42
  o = { error: c };
43
43
  } finally {
44
44
  try {
45
- s && !s.done && (e = r.return) && e.call(r);
45
+ n && !n.done && (e = r.return) && e.call(r);
46
46
  } finally {
47
47
  if (o)
48
48
  throw o.error;
@@ -50,42 +50,42 @@ function $(n, t) {
50
50
  }
51
51
  return i;
52
52
  }
53
- function k(n, t, e) {
53
+ function k(s, t, e) {
54
54
  if (e || arguments.length === 2)
55
- for (var r = 0, s = t.length, i; r < s; r++)
55
+ for (var r = 0, n = t.length, i; r < n; r++)
56
56
  (i || !(r in t)) && (i || (i = Array.prototype.slice.call(t, 0, r)), i[r] = t[r]);
57
- return n.concat(i || Array.prototype.slice.call(t));
57
+ return s.concat(i || Array.prototype.slice.call(t));
58
58
  }
59
- function S(n) {
60
- return typeof n == "function";
59
+ function C(s) {
60
+ return typeof s == "function";
61
61
  }
62
- function X(n) {
62
+ function X(s) {
63
63
  var t = function(r) {
64
64
  Error.call(r), r.stack = new Error().stack;
65
- }, e = n(t);
65
+ }, e = s(t);
66
66
  return e.prototype = Object.create(Error.prototype), e.prototype.constructor = e, e;
67
67
  }
68
- var V = X(function(n) {
68
+ var V = X(function(s) {
69
69
  return function(e) {
70
- n(this), this.message = e ? e.length + ` errors occurred during unsubscription:
71
- ` + e.map(function(r, s) {
72
- return s + 1 + ") " + r.toString();
70
+ s(this), this.message = e ? e.length + ` errors occurred during unsubscription:
71
+ ` + e.map(function(r, n) {
72
+ return n + 1 + ") " + r.toString();
73
73
  }).join(`
74
74
  `) : "", this.name = "UnsubscriptionError", this.errors = e;
75
75
  };
76
76
  });
77
- function D(n, t) {
78
- if (n) {
79
- var e = n.indexOf(t);
80
- 0 <= e && n.splice(e, 1);
77
+ function D(s, t) {
78
+ if (s) {
79
+ var e = s.indexOf(t);
80
+ 0 <= e && s.splice(e, 1);
81
81
  }
82
82
  }
83
83
  var x = function() {
84
- function n(t) {
84
+ function s(t) {
85
85
  this.initialTeardown = t, this.closed = !1, this._parentage = null, this._finalizers = null;
86
86
  }
87
- return n.prototype.unsubscribe = function() {
88
- var t, e, r, s, i;
87
+ return s.prototype.unsubscribe = function() {
88
+ var t, e, r, n, i;
89
89
  if (!this.closed) {
90
90
  this.closed = !0;
91
91
  var o = this._parentage;
@@ -109,7 +109,7 @@ var x = function() {
109
109
  else
110
110
  o.remove(this);
111
111
  var h = this.initialTeardown;
112
- if (S(h))
112
+ if (C(h))
113
113
  try {
114
114
  h();
115
115
  } catch (v) {
@@ -122,7 +122,7 @@ var x = function() {
122
122
  for (var b = Q(l), p = b.next(); !p.done; p = b.next()) {
123
123
  var F = p.value;
124
124
  try {
125
- ne(F);
125
+ se(F);
126
126
  } catch (v) {
127
127
  i = i ?? [], v instanceof V ? i = k(k([], $(i)), $(v.errors)) : i.push(v);
128
128
  }
@@ -131,7 +131,7 @@ var x = function() {
131
131
  r = { error: v };
132
132
  } finally {
133
133
  try {
134
- p && !p.done && (s = b.return) && s.call(b);
134
+ p && !p.done && (n = b.return) && n.call(b);
135
135
  } finally {
136
136
  if (r)
137
137
  throw r.error;
@@ -141,41 +141,41 @@ var x = function() {
141
141
  if (i)
142
142
  throw new V(i);
143
143
  }
144
- }, n.prototype.add = function(t) {
144
+ }, s.prototype.add = function(t) {
145
145
  var e;
146
146
  if (t && t !== this)
147
147
  if (this.closed)
148
- ne(t);
148
+ se(t);
149
149
  else {
150
- if (t instanceof n) {
150
+ if (t instanceof s) {
151
151
  if (t.closed || t._hasParent(this))
152
152
  return;
153
153
  t._addParent(this);
154
154
  }
155
155
  (this._finalizers = (e = this._finalizers) !== null && e !== void 0 ? e : []).push(t);
156
156
  }
157
- }, n.prototype._hasParent = function(t) {
157
+ }, s.prototype._hasParent = function(t) {
158
158
  var e = this._parentage;
159
159
  return e === t || Array.isArray(e) && e.includes(t);
160
- }, n.prototype._addParent = function(t) {
160
+ }, s.prototype._addParent = function(t) {
161
161
  var e = this._parentage;
162
162
  this._parentage = Array.isArray(e) ? (e.push(t), e) : e ? [e, t] : t;
163
- }, n.prototype._removeParent = function(t) {
163
+ }, s.prototype._removeParent = function(t) {
164
164
  var e = this._parentage;
165
165
  e === t ? this._parentage = null : Array.isArray(e) && D(e, t);
166
- }, n.prototype.remove = function(t) {
166
+ }, s.prototype.remove = function(t) {
167
167
  var e = this._finalizers;
168
- e && D(e, t), t instanceof n && t._removeParent(this);
169
- }, n.EMPTY = function() {
170
- var t = new n();
168
+ e && D(e, t), t instanceof s && t._removeParent(this);
169
+ }, s.EMPTY = function() {
170
+ var t = new s();
171
171
  return t.closed = !0, t;
172
- }(), n;
172
+ }(), s;
173
173
  }(), ve = x.EMPTY;
174
- function be(n) {
175
- return n instanceof x || n && "closed" in n && S(n.remove) && S(n.add) && S(n.unsubscribe);
174
+ function be(s) {
175
+ return s instanceof x || s && "closed" in s && C(s.remove) && C(s.add) && C(s.unsubscribe);
176
176
  }
177
- function ne(n) {
178
- S(n) ? n() : n.unsubscribe();
177
+ function se(s) {
178
+ C(s) ? s() : s.unsubscribe();
179
179
  }
180
180
  var we = {
181
181
  onUnhandledError: null,
@@ -183,36 +183,36 @@ var we = {
183
183
  Promise: void 0,
184
184
  useDeprecatedSynchronousErrorHandling: !1,
185
185
  useDeprecatedNextContext: !1
186
- }, Ce = {
187
- setTimeout: function(n, t) {
186
+ }, Se = {
187
+ setTimeout: function(s, t) {
188
188
  for (var e = [], r = 2; r < arguments.length; r++)
189
189
  e[r - 2] = arguments[r];
190
- return setTimeout.apply(void 0, k([n, t], $(e)));
190
+ return setTimeout.apply(void 0, k([s, t], $(e)));
191
191
  },
192
- clearTimeout: function(n) {
193
- var t = Ce.delegate;
194
- return ((t == null ? void 0 : t.clearTimeout) || clearTimeout)(n);
192
+ clearTimeout: function(s) {
193
+ var t = Se.delegate;
194
+ return ((t == null ? void 0 : t.clearTimeout) || clearTimeout)(s);
195
195
  },
196
196
  delegate: void 0
197
197
  };
198
- function _e(n) {
199
- Ce.setTimeout(function() {
200
- throw n;
198
+ function _e(s) {
199
+ Se.setTimeout(function() {
200
+ throw s;
201
201
  });
202
202
  }
203
- function se() {
203
+ function ne() {
204
204
  }
205
- function O(n) {
206
- n();
205
+ function O(s) {
206
+ s();
207
207
  }
208
- var Z = function(n) {
209
- U(t, n);
208
+ var Z = function(s) {
209
+ U(t, s);
210
210
  function t(e) {
211
- var r = n.call(this) || this;
211
+ var r = s.call(this) || this;
212
212
  return r.isStopped = !1, e ? (r.destination = e, be(e) && e.add(r)) : r.destination = ke, r;
213
213
  }
214
- return t.create = function(e, r, s) {
215
- return new N(e, r, s);
214
+ return t.create = function(e, r, n) {
215
+ return new N(e, r, n);
216
216
  }, t.prototype.next = function(e) {
217
217
  this.isStopped || this._next(e);
218
218
  }, t.prototype.error = function(e) {
@@ -220,7 +220,7 @@ var Z = function(n) {
220
220
  }, t.prototype.complete = function() {
221
221
  this.isStopped || (this.isStopped = !0, this._complete());
222
222
  }, t.prototype.unsubscribe = function() {
223
- this.closed || (this.isStopped = !0, n.prototype.unsubscribe.call(this), this.destination = null);
223
+ this.closed || (this.isStopped = !0, s.prototype.unsubscribe.call(this), this.destination = null);
224
224
  }, t.prototype._next = function(e) {
225
225
  this.destination.next(e);
226
226
  }, t.prototype._error = function(e) {
@@ -237,14 +237,14 @@ var Z = function(n) {
237
237
  }
238
238
  }, t;
239
239
  }(x), Le = Function.prototype.bind;
240
- function H(n, t) {
241
- return Le.call(n, t);
240
+ function H(s, t) {
241
+ return Le.call(s, t);
242
242
  }
243
243
  var Oe = function() {
244
- function n(t) {
244
+ function s(t) {
245
245
  this.partialObserver = t;
246
246
  }
247
- return n.prototype.next = function(t) {
247
+ return s.prototype.next = function(t) {
248
248
  var e = this.partialObserver;
249
249
  if (e.next)
250
250
  try {
@@ -252,7 +252,7 @@ var Oe = function() {
252
252
  } catch (r) {
253
253
  P(r);
254
254
  }
255
- }, n.prototype.error = function(t) {
255
+ }, s.prototype.error = function(t) {
256
256
  var e = this.partialObserver;
257
257
  if (e.error)
258
258
  try {
@@ -262,7 +262,7 @@ var Oe = function() {
262
262
  }
263
263
  else
264
264
  P(t);
265
- }, n.prototype.complete = function() {
265
+ }, s.prototype.complete = function() {
266
266
  var t = this.partialObserver;
267
267
  if (t.complete)
268
268
  try {
@@ -270,16 +270,16 @@ var Oe = function() {
270
270
  } catch (e) {
271
271
  P(e);
272
272
  }
273
- }, n;
274
- }(), N = function(n) {
275
- U(t, n);
276
- function t(e, r, s) {
277
- var i = n.call(this) || this, o;
278
- if (S(e) || !e)
273
+ }, s;
274
+ }(), N = function(s) {
275
+ U(t, s);
276
+ function t(e, r, n) {
277
+ var i = s.call(this) || this, o;
278
+ if (C(e) || !e)
279
279
  o = {
280
280
  next: e ?? void 0,
281
281
  error: r ?? void 0,
282
- complete: s ?? void 0
282
+ complete: n ?? void 0
283
283
  };
284
284
  else {
285
285
  var c;
@@ -295,52 +295,52 @@ var Oe = function() {
295
295
  }
296
296
  return t;
297
297
  }(Z);
298
- function P(n) {
299
- _e(n);
298
+ function P(s) {
299
+ _e(s);
300
300
  }
301
- function $e(n) {
302
- throw n;
301
+ function $e(s) {
302
+ throw s;
303
303
  }
304
304
  var ke = {
305
305
  closed: !0,
306
- next: se,
306
+ next: ne,
307
307
  error: $e,
308
- complete: se
308
+ complete: ne
309
309
  }, De = function() {
310
310
  return typeof Symbol == "function" && Symbol.observable || "@@observable";
311
311
  }();
312
- function Se(n) {
313
- return n;
312
+ function Ce(s) {
313
+ return s;
314
314
  }
315
- function Ne(n) {
316
- return n.length === 0 ? Se : n.length === 1 ? n[0] : function(e) {
317
- return n.reduce(function(r, s) {
318
- return s(r);
315
+ function Ne(s) {
316
+ return s.length === 0 ? Ce : s.length === 1 ? s[0] : function(e) {
317
+ return s.reduce(function(r, n) {
318
+ return n(r);
319
319
  }, e);
320
320
  };
321
321
  }
322
322
  var G = function() {
323
- function n(t) {
323
+ function s(t) {
324
324
  t && (this._subscribe = t);
325
325
  }
326
- return n.prototype.lift = function(t) {
327
- var e = new n();
326
+ return s.prototype.lift = function(t) {
327
+ var e = new s();
328
328
  return e.source = this, e.operator = t, e;
329
- }, n.prototype.subscribe = function(t, e, r) {
330
- var s = this, i = Ve(t) ? t : new N(t, e, r);
329
+ }, s.prototype.subscribe = function(t, e, r) {
330
+ var n = this, i = Ve(t) ? t : new N(t, e, r);
331
331
  return O(function() {
332
- var o = s, c = o.operator, a = o.source;
333
- i.add(c ? c.call(i, a) : a ? s._subscribe(i) : s._trySubscribe(i));
332
+ var o = n, c = o.operator, a = o.source;
333
+ i.add(c ? c.call(i, a) : a ? n._subscribe(i) : n._trySubscribe(i));
334
334
  }), i;
335
- }, n.prototype._trySubscribe = function(t) {
335
+ }, s.prototype._trySubscribe = function(t) {
336
336
  try {
337
337
  return this._subscribe(t);
338
338
  } catch (e) {
339
339
  t.error(e);
340
340
  }
341
- }, n.prototype.forEach = function(t, e) {
341
+ }, s.prototype.forEach = function(t, e) {
342
342
  var r = this;
343
- return e = ie(e), new e(function(s, i) {
343
+ return e = ie(e), new e(function(n, i) {
344
344
  var o = new N({
345
345
  next: function(c) {
346
346
  try {
@@ -350,54 +350,54 @@ var G = function() {
350
350
  }
351
351
  },
352
352
  error: i,
353
- complete: s
353
+ complete: n
354
354
  });
355
355
  r.subscribe(o);
356
356
  });
357
- }, n.prototype._subscribe = function(t) {
357
+ }, s.prototype._subscribe = function(t) {
358
358
  var e;
359
359
  return (e = this.source) === null || e === void 0 ? void 0 : e.subscribe(t);
360
- }, n.prototype[De] = function() {
360
+ }, s.prototype[De] = function() {
361
361
  return this;
362
- }, n.prototype.pipe = function() {
362
+ }, s.prototype.pipe = function() {
363
363
  for (var t = [], e = 0; e < arguments.length; e++)
364
364
  t[e] = arguments[e];
365
365
  return Ne(t)(this);
366
- }, n.prototype.toPromise = function(t) {
366
+ }, s.prototype.toPromise = function(t) {
367
367
  var e = this;
368
- return t = ie(t), new t(function(r, s) {
368
+ return t = ie(t), new t(function(r, n) {
369
369
  var i;
370
370
  e.subscribe(function(o) {
371
371
  return i = o;
372
372
  }, function(o) {
373
- return s(o);
373
+ return n(o);
374
374
  }, function() {
375
375
  return r(i);
376
376
  });
377
377
  });
378
- }, n.create = function(t) {
379
- return new n(t);
380
- }, n;
378
+ }, s.create = function(t) {
379
+ return new s(t);
380
+ }, s;
381
381
  }();
382
- function ie(n) {
382
+ function ie(s) {
383
383
  var t;
384
- return (t = n ?? we.Promise) !== null && t !== void 0 ? t : Promise;
384
+ return (t = s ?? we.Promise) !== null && t !== void 0 ? t : Promise;
385
385
  }
386
- function Fe(n) {
387
- return n && S(n.next) && S(n.error) && S(n.complete);
386
+ function Fe(s) {
387
+ return s && C(s.next) && C(s.error) && C(s.complete);
388
388
  }
389
- function Ve(n) {
390
- return n && n instanceof Z || Fe(n) && be(n);
389
+ function Ve(s) {
390
+ return s && s instanceof Z || Fe(s) && be(s);
391
391
  }
392
- function He(n) {
393
- return S(n == null ? void 0 : n.lift);
392
+ function He(s) {
393
+ return C(s == null ? void 0 : s.lift);
394
394
  }
395
- function Ee(n) {
395
+ function Ee(s) {
396
396
  return function(t) {
397
397
  if (He(t))
398
398
  return t.lift(function(e) {
399
399
  try {
400
- return n(e, this);
400
+ return s(e, this);
401
401
  } catch (r) {
402
402
  this.error(r);
403
403
  }
@@ -405,20 +405,20 @@ function Ee(n) {
405
405
  throw new TypeError("Unable to lift unknown Observable type");
406
406
  };
407
407
  }
408
- function Me(n, t, e, r, s) {
409
- return new je(n, t, e, r, s);
408
+ function Me(s, t, e, r, n) {
409
+ return new je(s, t, e, r, n);
410
410
  }
411
- var je = function(n) {
412
- U(t, n);
413
- function t(e, r, s, i, o, c) {
414
- var a = n.call(this, e) || this;
411
+ var je = function(s) {
412
+ U(t, s);
413
+ function t(e, r, n, i, o, c) {
414
+ var a = s.call(this, e) || this;
415
415
  return a.onFinalize = o, a.shouldUnsubscribe = c, a._next = r ? function(u) {
416
416
  try {
417
417
  r(u);
418
418
  } catch (h) {
419
419
  e.error(h);
420
420
  }
421
- } : n.prototype._next, a._error = i ? function(u) {
421
+ } : s.prototype._next, a._error = i ? function(u) {
422
422
  try {
423
423
  i(u);
424
424
  } catch (h) {
@@ -426,31 +426,31 @@ var je = function(n) {
426
426
  } finally {
427
427
  this.unsubscribe();
428
428
  }
429
- } : n.prototype._error, a._complete = s ? function() {
429
+ } : s.prototype._error, a._complete = n ? function() {
430
430
  try {
431
- s();
431
+ n();
432
432
  } catch (u) {
433
433
  e.error(u);
434
434
  } finally {
435
435
  this.unsubscribe();
436
436
  }
437
- } : n.prototype._complete, a;
437
+ } : s.prototype._complete, a;
438
438
  }
439
439
  return t.prototype.unsubscribe = function() {
440
440
  var e;
441
441
  if (!this.shouldUnsubscribe || this.shouldUnsubscribe()) {
442
442
  var r = this.closed;
443
- n.prototype.unsubscribe.call(this), !r && ((e = this.onFinalize) === null || e === void 0 || e.call(this));
443
+ s.prototype.unsubscribe.call(this), !r && ((e = this.onFinalize) === null || e === void 0 || e.call(this));
444
444
  }
445
445
  }, t;
446
- }(Z), qe = X(function(n) {
446
+ }(Z), qe = X(function(s) {
447
447
  return function() {
448
- n(this), this.name = "ObjectUnsubscribedError", this.message = "object unsubscribed";
448
+ s(this), this.name = "ObjectUnsubscribedError", this.message = "object unsubscribed";
449
449
  };
450
- }), Ie = function(n) {
451
- U(t, n);
450
+ }), Ie = function(s) {
451
+ U(t, s);
452
452
  function t() {
453
- var e = n.call(this) || this;
453
+ var e = s.call(this) || this;
454
454
  return e.closed = !1, e.currentObservers = null, e.observers = [], e.isStopped = !1, e.hasError = !1, e.thrownError = null, e;
455
455
  }
456
456
  return t.prototype.lift = function(e) {
@@ -462,7 +462,7 @@ var je = function(n) {
462
462
  }, t.prototype.next = function(e) {
463
463
  var r = this;
464
464
  O(function() {
465
- var s, i;
465
+ var n, i;
466
466
  if (r._throwIfClosed(), !r.isStopped) {
467
467
  r.currentObservers || (r.currentObservers = Array.from(r.observers));
468
468
  try {
@@ -471,13 +471,13 @@ var je = function(n) {
471
471
  a.next(e);
472
472
  }
473
473
  } catch (u) {
474
- s = { error: u };
474
+ n = { error: u };
475
475
  } finally {
476
476
  try {
477
477
  c && !c.done && (i = o.return) && i.call(o);
478
478
  } finally {
479
- if (s)
480
- throw s.error;
479
+ if (n)
480
+ throw n.error;
481
481
  }
482
482
  }
483
483
  }
@@ -487,8 +487,8 @@ var je = function(n) {
487
487
  O(function() {
488
488
  if (r._throwIfClosed(), !r.isStopped) {
489
489
  r.hasError = r.isStopped = !0, r.thrownError = e;
490
- for (var s = r.observers; s.length; )
491
- s.shift().error(e);
490
+ for (var n = r.observers; n.length; )
491
+ n.shift().error(e);
492
492
  }
493
493
  });
494
494
  }, t.prototype.complete = function() {
@@ -510,121 +510,121 @@ var je = function(n) {
510
510
  enumerable: !1,
511
511
  configurable: !0
512
512
  }), t.prototype._trySubscribe = function(e) {
513
- return this._throwIfClosed(), n.prototype._trySubscribe.call(this, e);
513
+ return this._throwIfClosed(), s.prototype._trySubscribe.call(this, e);
514
514
  }, t.prototype._subscribe = function(e) {
515
515
  return this._throwIfClosed(), this._checkFinalizedStatuses(e), this._innerSubscribe(e);
516
516
  }, t.prototype._innerSubscribe = function(e) {
517
- var r = this, s = this, i = s.hasError, o = s.isStopped, c = s.observers;
517
+ var r = this, n = this, i = n.hasError, o = n.isStopped, c = n.observers;
518
518
  return i || o ? ve : (this.currentObservers = null, c.push(e), new x(function() {
519
519
  r.currentObservers = null, D(c, e);
520
520
  }));
521
521
  }, t.prototype._checkFinalizedStatuses = function(e) {
522
- var r = this, s = r.hasError, i = r.thrownError, o = r.isStopped;
523
- s ? e.error(i) : o && e.complete();
522
+ var r = this, n = r.hasError, i = r.thrownError, o = r.isStopped;
523
+ n ? e.error(i) : o && e.complete();
524
524
  }, t.prototype.asObservable = function() {
525
525
  var e = new G();
526
526
  return e.source = this, e;
527
527
  }, t.create = function(e, r) {
528
528
  return new oe(e, r);
529
529
  }, t;
530
- }(G), oe = function(n) {
531
- U(t, n);
530
+ }(G), oe = function(s) {
531
+ U(t, s);
532
532
  function t(e, r) {
533
- var s = n.call(this) || this;
534
- return s.destination = e, s.source = r, s;
533
+ var n = s.call(this) || this;
534
+ return n.destination = e, n.source = r, n;
535
535
  }
536
536
  return t.prototype.next = function(e) {
537
- var r, s;
538
- (s = (r = this.destination) === null || r === void 0 ? void 0 : r.next) === null || s === void 0 || s.call(r, e);
537
+ var r, n;
538
+ (n = (r = this.destination) === null || r === void 0 ? void 0 : r.next) === null || n === void 0 || n.call(r, e);
539
539
  }, t.prototype.error = function(e) {
540
- var r, s;
541
- (s = (r = this.destination) === null || r === void 0 ? void 0 : r.error) === null || s === void 0 || s.call(r, e);
540
+ var r, n;
541
+ (n = (r = this.destination) === null || r === void 0 ? void 0 : r.error) === null || n === void 0 || n.call(r, e);
542
542
  }, t.prototype.complete = function() {
543
543
  var e, r;
544
544
  (r = (e = this.destination) === null || e === void 0 ? void 0 : e.complete) === null || r === void 0 || r.call(e);
545
545
  }, t.prototype._subscribe = function(e) {
546
- var r, s;
547
- return (s = (r = this.source) === null || r === void 0 ? void 0 : r.subscribe(e)) !== null && s !== void 0 ? s : ve;
546
+ var r, n;
547
+ return (n = (r = this.source) === null || r === void 0 ? void 0 : r.subscribe(e)) !== null && n !== void 0 ? n : ve;
548
548
  }, t;
549
549
  }(Ie), Be = {
550
550
  now: function() {
551
551
  return Date.now();
552
552
  },
553
553
  delegate: void 0
554
- }, Qe = function(n) {
555
- U(t, n);
554
+ }, Qe = function(s) {
555
+ U(t, s);
556
556
  function t(e, r) {
557
- return n.call(this) || this;
557
+ return s.call(this) || this;
558
558
  }
559
559
  return t.prototype.schedule = function(e, r) {
560
560
  return this;
561
561
  }, t;
562
562
  }(x), Y = {
563
- setInterval: function(n, t) {
563
+ setInterval: function(s, t) {
564
564
  for (var e = [], r = 2; r < arguments.length; r++)
565
565
  e[r - 2] = arguments[r];
566
- return setInterval.apply(void 0, k([n, t], $(e)));
566
+ return setInterval.apply(void 0, k([s, t], $(e)));
567
567
  },
568
- clearInterval: function(n) {
568
+ clearInterval: function(s) {
569
569
  var t = Y.delegate;
570
- return ((t == null ? void 0 : t.clearInterval) || clearInterval)(n);
570
+ return ((t == null ? void 0 : t.clearInterval) || clearInterval)(s);
571
571
  },
572
572
  delegate: void 0
573
- }, Ge = function(n) {
574
- U(t, n);
573
+ }, Ge = function(s) {
574
+ U(t, s);
575
575
  function t(e, r) {
576
- var s = n.call(this, e, r) || this;
577
- return s.scheduler = e, s.work = r, s.pending = !1, s;
576
+ var n = s.call(this, e, r) || this;
577
+ return n.scheduler = e, n.work = r, n.pending = !1, n;
578
578
  }
579
579
  return t.prototype.schedule = function(e, r) {
580
- var s;
580
+ var n;
581
581
  if (r === void 0 && (r = 0), this.closed)
582
582
  return this;
583
583
  this.state = e;
584
584
  var i = this.id, o = this.scheduler;
585
- return i != null && (this.id = this.recycleAsyncId(o, i, r)), this.pending = !0, this.delay = r, this.id = (s = this.id) !== null && s !== void 0 ? s : this.requestAsyncId(o, this.id, r), this;
586
- }, t.prototype.requestAsyncId = function(e, r, s) {
587
- return s === void 0 && (s = 0), Y.setInterval(e.flush.bind(e, this), s);
588
- }, t.prototype.recycleAsyncId = function(e, r, s) {
589
- if (s === void 0 && (s = 0), s != null && this.delay === s && this.pending === !1)
585
+ return i != null && (this.id = this.recycleAsyncId(o, i, r)), this.pending = !0, this.delay = r, this.id = (n = this.id) !== null && n !== void 0 ? n : this.requestAsyncId(o, this.id, r), this;
586
+ }, t.prototype.requestAsyncId = function(e, r, n) {
587
+ return n === void 0 && (n = 0), Y.setInterval(e.flush.bind(e, this), n);
588
+ }, t.prototype.recycleAsyncId = function(e, r, n) {
589
+ if (n === void 0 && (n = 0), n != null && this.delay === n && this.pending === !1)
590
590
  return r;
591
591
  r != null && Y.clearInterval(r);
592
592
  }, t.prototype.execute = function(e, r) {
593
593
  if (this.closed)
594
594
  return new Error("executing a cancelled action");
595
595
  this.pending = !1;
596
- var s = this._execute(e, r);
597
- if (s)
598
- return s;
596
+ var n = this._execute(e, r);
597
+ if (n)
598
+ return n;
599
599
  this.pending === !1 && this.id != null && (this.id = this.recycleAsyncId(this.scheduler, this.id, null));
600
600
  }, t.prototype._execute = function(e, r) {
601
- var s = !1, i;
601
+ var n = !1, i;
602
602
  try {
603
603
  this.work(e);
604
604
  } catch (o) {
605
- s = !0, i = o || new Error("Scheduled action threw falsy error");
605
+ n = !0, i = o || new Error("Scheduled action threw falsy error");
606
606
  }
607
- if (s)
607
+ if (n)
608
608
  return this.unsubscribe(), i;
609
609
  }, t.prototype.unsubscribe = function() {
610
610
  if (!this.closed) {
611
- var e = this, r = e.id, s = e.scheduler, i = s.actions;
612
- this.work = this.state = this.scheduler = null, this.pending = !1, D(i, this), r != null && (this.id = this.recycleAsyncId(s, r, null)), this.delay = null, n.prototype.unsubscribe.call(this);
611
+ var e = this, r = e.id, n = e.scheduler, i = n.actions;
612
+ this.work = this.state = this.scheduler = null, this.pending = !1, D(i, this), r != null && (this.id = this.recycleAsyncId(n, r, null)), this.delay = null, s.prototype.unsubscribe.call(this);
613
613
  }
614
614
  }, t;
615
615
  }(Qe), ce = function() {
616
- function n(t, e) {
617
- e === void 0 && (e = n.now), this.schedulerActionCtor = t, this.now = e;
616
+ function s(t, e) {
617
+ e === void 0 && (e = s.now), this.schedulerActionCtor = t, this.now = e;
618
618
  }
619
- return n.prototype.schedule = function(t, e, r) {
619
+ return s.prototype.schedule = function(t, e, r) {
620
620
  return e === void 0 && (e = 0), new this.schedulerActionCtor(this, t).schedule(r, e);
621
- }, n.now = Be.now, n;
622
- }(), Ye = function(n) {
623
- U(t, n);
621
+ }, s.now = Be.now, s;
622
+ }(), Ye = function(s) {
623
+ U(t, s);
624
624
  function t(e, r) {
625
625
  r === void 0 && (r = ce.now);
626
- var s = n.call(this, e, r) || this;
627
- return s.actions = [], s._active = !1, s;
626
+ var n = s.call(this, e, r) || this;
627
+ return n.actions = [], n._active = !1, n;
628
628
  }
629
629
  return t.prototype.flush = function(e) {
630
630
  var r = this.actions;
@@ -632,72 +632,72 @@ var je = function(n) {
632
632
  r.push(e);
633
633
  return;
634
634
  }
635
- var s;
635
+ var n;
636
636
  this._active = !0;
637
637
  do
638
- if (s = e.execute(e.state, e.delay))
638
+ if (n = e.execute(e.state, e.delay))
639
639
  break;
640
640
  while (e = r.shift());
641
- if (this._active = !1, s) {
641
+ if (this._active = !1, n) {
642
642
  for (; e = r.shift(); )
643
643
  e.unsubscribe();
644
- throw s;
644
+ throw n;
645
645
  }
646
646
  }, t;
647
647
  }(ce), ze = new Ye(Ge), Je = ze;
648
- function We(n) {
649
- return n && S(n.schedule);
648
+ function We(s) {
649
+ return s && C(s.schedule);
650
650
  }
651
- var Ke = X(function(n) {
651
+ var Ke = X(function(s) {
652
652
  return function() {
653
- n(this), this.name = "EmptyError", this.message = "no elements in sequence";
653
+ s(this), this.name = "EmptyError", this.message = "no elements in sequence";
654
654
  };
655
655
  });
656
- function T(n, t) {
656
+ function T(s, t) {
657
657
  var e = typeof t == "object";
658
- return new Promise(function(r, s) {
658
+ return new Promise(function(r, n) {
659
659
  var i = new N({
660
660
  next: function(o) {
661
661
  r(o), i.unsubscribe();
662
662
  },
663
- error: s,
663
+ error: n,
664
664
  complete: function() {
665
- e ? r(t.defaultValue) : s(new Ke());
665
+ e ? r(t.defaultValue) : n(new Ke());
666
666
  }
667
667
  });
668
- n.subscribe(i);
668
+ s.subscribe(i);
669
669
  });
670
670
  }
671
- function Xe(n) {
672
- return n instanceof Date && !isNaN(n);
671
+ function Xe(s) {
672
+ return s instanceof Date && !isNaN(s);
673
673
  }
674
- function _(n, t) {
674
+ function _(s, t) {
675
675
  return Ee(function(e, r) {
676
- var s = 0;
676
+ var n = 0;
677
677
  e.subscribe(Me(r, function(i) {
678
- r.next(n.call(t, i, s++));
678
+ r.next(s.call(t, i, n++));
679
679
  }));
680
680
  });
681
681
  }
682
- function Ze(n, t, e) {
683
- n === void 0 && (n = 0), e === void 0 && (e = Je);
682
+ function Ze(s, t, e) {
683
+ s === void 0 && (s = 0), e === void 0 && (e = Je);
684
684
  var r = -1;
685
- return t != null && (We(t) ? e = t : r = t), new G(function(s) {
686
- var i = Xe(n) ? +n - e.now() : n;
685
+ return t != null && (We(t) ? e = t : r = t), new G(function(n) {
686
+ var i = Xe(s) ? +s - e.now() : s;
687
687
  i < 0 && (i = 0);
688
688
  var o = 0;
689
689
  return e.schedule(function() {
690
- s.closed || (s.next(o++), 0 <= r ? this.schedule(void 0, r) : s.complete());
690
+ n.closed || (n.next(o++), 0 <= r ? this.schedule(void 0, r) : n.complete());
691
691
  }, i);
692
692
  });
693
693
  }
694
- function et(n, t, e) {
695
- var r = S(n) || t || e ? { next: n, error: t, complete: e } : n;
696
- return r ? Ee(function(s, i) {
694
+ function et(s, t, e) {
695
+ var r = C(s) || t || e ? { next: s, error: t, complete: e } : s;
696
+ return r ? Ee(function(n, i) {
697
697
  var o;
698
698
  (o = r.subscribe) === null || o === void 0 || o.call(r);
699
699
  var c = !0;
700
- s.subscribe(Me(i, function(a) {
700
+ n.subscribe(Me(i, function(a) {
701
701
  var u;
702
702
  (u = r.next) === null || u === void 0 || u.call(r, a), i.next(a);
703
703
  }, function() {
@@ -710,9 +710,9 @@ function et(n, t, e) {
710
710
  var a, u;
711
711
  c && ((a = r.unsubscribe) === null || a === void 0 || a.call(r)), (u = r.finalize) === null || u === void 0 || u.call(r);
712
712
  }));
713
- }) : Se;
713
+ }) : Ce;
714
714
  }
715
- var tt = Object.defineProperty, rt = (n, t, e) => t in n ? tt(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e, I = (n, t, e) => (rt(n, typeof t != "symbol" ? t + "" : t, e), e);
715
+ var tt = Object.defineProperty, rt = (s, t, e) => t in s ? tt(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e, I = (s, t, e) => (rt(s, typeof t != "symbol" ? t + "" : t, e), e);
716
716
  class d extends Error {
717
717
  constructor(t) {
718
718
  super(`Incorrect context (${t}). Cannot perform the requested operation.`), I(this, "context"), this.context = t;
@@ -730,7 +730,7 @@ class ae extends Error {
730
730
  ), this.streamId = t, this.expectedStreamId = e;
731
731
  }
732
732
  }
733
- class nt extends Error {
733
+ class st extends Error {
734
734
  constructor(t) {
735
735
  super(`Invalid version format: ${t}`);
736
736
  }
@@ -746,18 +746,18 @@ class le extends Error {
746
746
  e && (r += ` Minimum version supported is ${e}.`), super(r), this.version = t;
747
747
  }
748
748
  }
749
- function E(n) {
750
- return typeof n == "function";
749
+ function E(s) {
750
+ return typeof s == "function";
751
751
  }
752
- function st(n) {
753
- return E(n == null ? void 0 : n.lift);
752
+ function nt(s) {
753
+ return E(s == null ? void 0 : s.lift);
754
754
  }
755
- function R(n) {
755
+ function R(s) {
756
756
  return function(t) {
757
- if (st(t))
757
+ if (nt(t))
758
758
  return t.lift(function(e) {
759
759
  try {
760
- return n(e, this);
760
+ return s(e, this);
761
761
  } catch (r) {
762
762
  this.error(r);
763
763
  }
@@ -765,48 +765,48 @@ function R(n) {
765
765
  throw new TypeError("Unable to lift unknown Observable type");
766
766
  };
767
767
  }
768
- var z = function(n, t) {
768
+ var z = function(s, t) {
769
769
  return z = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e, r) {
770
770
  e.__proto__ = r;
771
771
  } || function(e, r) {
772
- for (var s in r)
773
- Object.prototype.hasOwnProperty.call(r, s) && (e[s] = r[s]);
774
- }, z(n, t);
772
+ for (var n in r)
773
+ Object.prototype.hasOwnProperty.call(r, n) && (e[n] = r[n]);
774
+ }, z(s, t);
775
775
  };
776
- function ee(n, t) {
776
+ function ee(s, t) {
777
777
  if (typeof t != "function" && t !== null)
778
778
  throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
779
- z(n, t);
779
+ z(s, t);
780
780
  function e() {
781
- this.constructor = n;
781
+ this.constructor = s;
782
782
  }
783
- n.prototype = t === null ? Object.create(t) : (e.prototype = t.prototype, new e());
783
+ s.prototype = t === null ? Object.create(t) : (e.prototype = t.prototype, new e());
784
784
  }
785
- function he(n) {
786
- var t = typeof Symbol == "function" && Symbol.iterator, e = t && n[t], r = 0;
785
+ function he(s) {
786
+ var t = typeof Symbol == "function" && Symbol.iterator, e = t && s[t], r = 0;
787
787
  if (e)
788
- return e.call(n);
789
- if (n && typeof n.length == "number")
788
+ return e.call(s);
789
+ if (s && typeof s.length == "number")
790
790
  return {
791
791
  next: function() {
792
- return n && r >= n.length && (n = void 0), { value: n && n[r++], done: !n };
792
+ return s && r >= s.length && (s = void 0), { value: s && s[r++], done: !s };
793
793
  }
794
794
  };
795
795
  throw new TypeError(t ? "Object is not iterable." : "Symbol.iterator is not defined.");
796
796
  }
797
- function J(n, t) {
798
- var e = typeof Symbol == "function" && n[Symbol.iterator];
797
+ function J(s, t) {
798
+ var e = typeof Symbol == "function" && s[Symbol.iterator];
799
799
  if (!e)
800
- return n;
801
- var r = e.call(n), s, i = [], o;
800
+ return s;
801
+ var r = e.call(s), n, i = [], o;
802
802
  try {
803
- for (; (t === void 0 || t-- > 0) && !(s = r.next()).done; )
804
- i.push(s.value);
803
+ for (; (t === void 0 || t-- > 0) && !(n = r.next()).done; )
804
+ i.push(n.value);
805
805
  } catch (c) {
806
806
  o = { error: c };
807
807
  } finally {
808
808
  try {
809
- s && !s.done && (e = r.return) && e.call(r);
809
+ n && !n.done && (e = r.return) && e.call(r);
810
810
  } finally {
811
811
  if (o)
812
812
  throw o.error;
@@ -814,39 +814,39 @@ function J(n, t) {
814
814
  }
815
815
  return i;
816
816
  }
817
- function W(n, t, e) {
817
+ function W(s, t, e) {
818
818
  if (e || arguments.length === 2)
819
- for (var r = 0, s = t.length, i; r < s; r++)
819
+ for (var r = 0, n = t.length, i; r < n; r++)
820
820
  (i || !(r in t)) && (i || (i = Array.prototype.slice.call(t, 0, r)), i[r] = t[r]);
821
- return n.concat(i || Array.prototype.slice.call(t));
821
+ return s.concat(i || Array.prototype.slice.call(t));
822
822
  }
823
- function it(n) {
823
+ function it(s) {
824
824
  var t = function(r) {
825
825
  Error.call(r), r.stack = new Error().stack;
826
- }, e = n(t);
826
+ }, e = s(t);
827
827
  return e.prototype = Object.create(Error.prototype), e.prototype.constructor = e, e;
828
828
  }
829
- var j = it(function(n) {
829
+ var j = it(function(s) {
830
830
  return function(t) {
831
- n(this), this.message = t ? t.length + ` errors occurred during unsubscription:
831
+ s(this), this.message = t ? t.length + ` errors occurred during unsubscription:
832
832
  ` + t.map(function(e, r) {
833
833
  return r + 1 + ") " + e.toString();
834
834
  }).join(`
835
835
  `) : "", this.name = "UnsubscriptionError", this.errors = t;
836
836
  };
837
837
  });
838
- function de(n, t) {
839
- if (n) {
840
- var e = n.indexOf(t);
841
- 0 <= e && n.splice(e, 1);
838
+ function de(s, t) {
839
+ if (s) {
840
+ var e = s.indexOf(t);
841
+ 0 <= e && s.splice(e, 1);
842
842
  }
843
843
  }
844
844
  var te = function() {
845
- function n(t) {
845
+ function s(t) {
846
846
  this.initialTeardown = t, this.closed = !1, this._parentage = null, this._finalizers = null;
847
847
  }
848
- return n.prototype.unsubscribe = function() {
849
- var t, e, r, s, i;
848
+ return s.prototype.unsubscribe = function() {
849
+ var t, e, r, n, i;
850
850
  if (!this.closed) {
851
851
  this.closed = !0;
852
852
  var o = this._parentage;
@@ -892,7 +892,7 @@ var te = function() {
892
892
  r = { error: v };
893
893
  } finally {
894
894
  try {
895
- p && !p.done && (s = b.return) && s.call(b);
895
+ p && !p.done && (n = b.return) && n.call(b);
896
896
  } finally {
897
897
  if (r)
898
898
  throw r.error;
@@ -902,42 +902,42 @@ var te = function() {
902
902
  if (i)
903
903
  throw new j(i);
904
904
  }
905
- }, n.prototype.add = function(t) {
905
+ }, s.prototype.add = function(t) {
906
906
  var e;
907
907
  if (t && t !== this)
908
908
  if (this.closed)
909
909
  pe(t);
910
910
  else {
911
- if (t instanceof n) {
911
+ if (t instanceof s) {
912
912
  if (t.closed || t._hasParent(this))
913
913
  return;
914
914
  t._addParent(this);
915
915
  }
916
916
  (this._finalizers = (e = this._finalizers) !== null && e !== void 0 ? e : []).push(t);
917
917
  }
918
- }, n.prototype._hasParent = function(t) {
918
+ }, s.prototype._hasParent = function(t) {
919
919
  var e = this._parentage;
920
920
  return e === t || Array.isArray(e) && e.includes(t);
921
- }, n.prototype._addParent = function(t) {
921
+ }, s.prototype._addParent = function(t) {
922
922
  var e = this._parentage;
923
923
  this._parentage = Array.isArray(e) ? (e.push(t), e) : e ? [e, t] : t;
924
- }, n.prototype._removeParent = function(t) {
924
+ }, s.prototype._removeParent = function(t) {
925
925
  var e = this._parentage;
926
926
  e === t ? this._parentage = null : Array.isArray(e) && de(e, t);
927
- }, n.prototype.remove = function(t) {
927
+ }, s.prototype.remove = function(t) {
928
928
  var e = this._finalizers;
929
- e && de(e, t), t instanceof n && t._removeParent(this);
930
- }, n.EMPTY = function() {
931
- var t = new n();
929
+ e && de(e, t), t instanceof s && t._removeParent(this);
930
+ }, s.EMPTY = function() {
931
+ var t = new s();
932
932
  return t.closed = !0, t;
933
- }(), n;
933
+ }(), s;
934
934
  }();
935
935
  te.EMPTY;
936
- function Ue(n) {
937
- return n instanceof te || n && "closed" in n && E(n.remove) && E(n.add) && E(n.unsubscribe);
936
+ function Ue(s) {
937
+ return s instanceof te || s && "closed" in s && E(s.remove) && E(s.add) && E(s.unsubscribe);
938
938
  }
939
- function pe(n) {
940
- E(n) ? n() : n.unsubscribe();
939
+ function pe(s) {
940
+ E(s) ? s() : s.unsubscribe();
941
941
  }
942
942
  var Te = {
943
943
  onUnhandledError: null,
@@ -946,34 +946,34 @@ var Te = {
946
946
  useDeprecatedSynchronousErrorHandling: !1,
947
947
  useDeprecatedNextContext: !1
948
948
  }, ot = {
949
- setTimeout: function(n, t) {
949
+ setTimeout: function(s, t) {
950
950
  for (var e = [], r = 2; r < arguments.length; r++)
951
951
  e[r - 2] = arguments[r];
952
- return setTimeout.apply(void 0, W([n, t], J(e)));
952
+ return setTimeout.apply(void 0, W([s, t], J(e)));
953
953
  },
954
- clearTimeout: function(n) {
955
- return clearTimeout(n);
954
+ clearTimeout: function(s) {
955
+ return clearTimeout(s);
956
956
  },
957
957
  delegate: void 0
958
958
  };
959
- function ct(n) {
959
+ function ct(s) {
960
960
  ot.setTimeout(function() {
961
- throw n;
961
+ throw s;
962
962
  });
963
963
  }
964
964
  function fe() {
965
965
  }
966
- function at(n) {
967
- n();
966
+ function at(s) {
967
+ s();
968
968
  }
969
- var re = function(n) {
970
- ee(t, n);
969
+ var re = function(s) {
970
+ ee(t, s);
971
971
  function t(e) {
972
- var r = n.call(this) || this;
972
+ var r = s.call(this) || this;
973
973
  return r.isStopped = !1, e ? (r.destination = e, Ue(e) && e.add(r)) : r.destination = dt, r;
974
974
  }
975
- return t.create = function(e, r, s) {
976
- return new K(e, r, s);
975
+ return t.create = function(e, r, n) {
976
+ return new K(e, r, n);
977
977
  }, t.prototype.next = function(e) {
978
978
  this.isStopped || this._next(e);
979
979
  }, t.prototype.error = function(e) {
@@ -981,7 +981,7 @@ var re = function(n) {
981
981
  }, t.prototype.complete = function() {
982
982
  this.isStopped || (this.isStopped = !0, this._complete());
983
983
  }, t.prototype.unsubscribe = function() {
984
- this.closed || (this.isStopped = !0, n.prototype.unsubscribe.call(this), this.destination = null);
984
+ this.closed || (this.isStopped = !0, s.prototype.unsubscribe.call(this), this.destination = null);
985
985
  }, t.prototype._next = function(e) {
986
986
  this.destination.next(e);
987
987
  }, t.prototype._error = function(e) {
@@ -998,14 +998,14 @@ var re = function(n) {
998
998
  }
999
999
  }, t;
1000
1000
  }(te), ut = Function.prototype.bind;
1001
- function q(n, t) {
1002
- return ut.call(n, t);
1001
+ function q(s, t) {
1002
+ return ut.call(s, t);
1003
1003
  }
1004
1004
  var lt = function() {
1005
- function n(t) {
1005
+ function s(t) {
1006
1006
  this.partialObserver = t;
1007
1007
  }
1008
- return n.prototype.next = function(t) {
1008
+ return s.prototype.next = function(t) {
1009
1009
  var e = this.partialObserver;
1010
1010
  if (e.next)
1011
1011
  try {
@@ -1013,7 +1013,7 @@ var lt = function() {
1013
1013
  } catch (r) {
1014
1014
  L(r);
1015
1015
  }
1016
- }, n.prototype.error = function(t) {
1016
+ }, s.prototype.error = function(t) {
1017
1017
  var e = this.partialObserver;
1018
1018
  if (e.error)
1019
1019
  try {
@@ -1023,7 +1023,7 @@ var lt = function() {
1023
1023
  }
1024
1024
  else
1025
1025
  L(t);
1026
- }, n.prototype.complete = function() {
1026
+ }, s.prototype.complete = function() {
1027
1027
  var t = this.partialObserver;
1028
1028
  if (t.complete)
1029
1029
  try {
@@ -1031,16 +1031,16 @@ var lt = function() {
1031
1031
  } catch (e) {
1032
1032
  L(e);
1033
1033
  }
1034
- }, n;
1035
- }(), K = function(n) {
1036
- ee(t, n);
1037
- function t(e, r, s) {
1038
- var i = n.call(this) || this, o;
1034
+ }, s;
1035
+ }(), K = function(s) {
1036
+ ee(t, s);
1037
+ function t(e, r, n) {
1038
+ var i = s.call(this) || this, o;
1039
1039
  if (E(e) || !e)
1040
1040
  o = {
1041
1041
  next: e ?? void 0,
1042
1042
  error: r ?? void 0,
1043
- complete: s ?? void 0
1043
+ complete: n ?? void 0
1044
1044
  };
1045
1045
  else {
1046
1046
  var c;
@@ -1056,11 +1056,11 @@ var lt = function() {
1056
1056
  }
1057
1057
  return t;
1058
1058
  }(re);
1059
- function L(n) {
1060
- ct(n);
1059
+ function L(s) {
1060
+ ct(s);
1061
1061
  }
1062
- function ht(n) {
1063
- throw n;
1062
+ function ht(s) {
1063
+ throw s;
1064
1064
  }
1065
1065
  var dt = {
1066
1066
  closed: !0,
@@ -1070,38 +1070,38 @@ var dt = {
1070
1070
  }, pt = function() {
1071
1071
  return typeof Symbol == "function" && Symbol.observable || "@@observable";
1072
1072
  }();
1073
- function xe(n) {
1074
- return n;
1073
+ function xe(s) {
1074
+ return s;
1075
1075
  }
1076
- function ft(n) {
1077
- return n.length === 0 ? xe : n.length === 1 ? n[0] : function(t) {
1078
- return n.reduce(function(e, r) {
1076
+ function ft(s) {
1077
+ return s.length === 0 ? xe : s.length === 1 ? s[0] : function(t) {
1078
+ return s.reduce(function(e, r) {
1079
1079
  return r(e);
1080
1080
  }, t);
1081
1081
  };
1082
1082
  }
1083
1083
  var gt = function() {
1084
- function n(t) {
1084
+ function s(t) {
1085
1085
  t && (this._subscribe = t);
1086
1086
  }
1087
- return n.prototype.lift = function(t) {
1088
- var e = new n();
1087
+ return s.prototype.lift = function(t) {
1088
+ var e = new s();
1089
1089
  return e.source = this, e.operator = t, e;
1090
- }, n.prototype.subscribe = function(t, e, r) {
1091
- var s = this, i = yt(t) ? t : new K(t, e, r);
1090
+ }, s.prototype.subscribe = function(t, e, r) {
1091
+ var n = this, i = yt(t) ? t : new K(t, e, r);
1092
1092
  return at(function() {
1093
- var o = s, c = o.operator, a = o.source;
1094
- i.add(c ? c.call(i, a) : a ? s._subscribe(i) : s._trySubscribe(i));
1093
+ var o = n, c = o.operator, a = o.source;
1094
+ i.add(c ? c.call(i, a) : a ? n._subscribe(i) : n._trySubscribe(i));
1095
1095
  }), i;
1096
- }, n.prototype._trySubscribe = function(t) {
1096
+ }, s.prototype._trySubscribe = function(t) {
1097
1097
  try {
1098
1098
  return this._subscribe(t);
1099
1099
  } catch (e) {
1100
1100
  t.error(e);
1101
1101
  }
1102
- }, n.prototype.forEach = function(t, e) {
1102
+ }, s.prototype.forEach = function(t, e) {
1103
1103
  var r = this;
1104
- return e = ge(e), new e(function(s, i) {
1104
+ return e = ge(e), new e(function(n, i) {
1105
1105
  var o = new K({
1106
1106
  next: function(c) {
1107
1107
  try {
@@ -1111,59 +1111,59 @@ var gt = function() {
1111
1111
  }
1112
1112
  },
1113
1113
  error: i,
1114
- complete: s
1114
+ complete: n
1115
1115
  });
1116
1116
  r.subscribe(o);
1117
1117
  });
1118
- }, n.prototype._subscribe = function(t) {
1118
+ }, s.prototype._subscribe = function(t) {
1119
1119
  var e;
1120
1120
  return (e = this.source) === null || e === void 0 ? void 0 : e.subscribe(t);
1121
- }, n.prototype[pt] = function() {
1121
+ }, s.prototype[pt] = function() {
1122
1122
  return this;
1123
- }, n.prototype.pipe = function() {
1123
+ }, s.prototype.pipe = function() {
1124
1124
  for (var t = [], e = 0; e < arguments.length; e++)
1125
1125
  t[e] = arguments[e];
1126
1126
  return ft(t)(this);
1127
- }, n.prototype.toPromise = function(t) {
1127
+ }, s.prototype.toPromise = function(t) {
1128
1128
  var e = this;
1129
- return t = ge(t), new t(function(r, s) {
1129
+ return t = ge(t), new t(function(r, n) {
1130
1130
  var i;
1131
1131
  e.subscribe(function(o) {
1132
1132
  return i = o;
1133
1133
  }, function(o) {
1134
- return s(o);
1134
+ return n(o);
1135
1135
  }, function() {
1136
1136
  return r(i);
1137
1137
  });
1138
1138
  });
1139
- }, n.create = function(t) {
1140
- return new n(t);
1141
- }, n;
1139
+ }, s.create = function(t) {
1140
+ return new s(t);
1141
+ }, s;
1142
1142
  }();
1143
- function ge(n) {
1143
+ function ge(s) {
1144
1144
  var t;
1145
- return (t = n ?? Te.Promise) !== null && t !== void 0 ? t : Promise;
1145
+ return (t = s ?? Te.Promise) !== null && t !== void 0 ? t : Promise;
1146
1146
  }
1147
- function mt(n) {
1148
- return n && E(n.next) && E(n.error) && E(n.complete);
1147
+ function mt(s) {
1148
+ return s && E(s.next) && E(s.error) && E(s.complete);
1149
1149
  }
1150
- function yt(n) {
1151
- return n && n instanceof re || mt(n) && Ue(n);
1150
+ function yt(s) {
1151
+ return s && s instanceof re || mt(s) && Ue(s);
1152
1152
  }
1153
- function A(n, t, e, r, s) {
1154
- return new vt(n, t, e, r, s);
1153
+ function A(s, t, e, r, n) {
1154
+ return new vt(s, t, e, r, n);
1155
1155
  }
1156
- var vt = function(n) {
1157
- ee(t, n);
1158
- function t(e, r, s, i, o, c) {
1159
- var a = n.call(this, e) || this;
1156
+ var vt = function(s) {
1157
+ ee(t, s);
1158
+ function t(e, r, n, i, o, c) {
1159
+ var a = s.call(this, e) || this;
1160
1160
  return a.onFinalize = o, a.shouldUnsubscribe = c, a._next = r ? function(u) {
1161
1161
  try {
1162
1162
  r(u);
1163
1163
  } catch (h) {
1164
1164
  e.error(h);
1165
1165
  }
1166
- } : n.prototype._next, a._error = i ? function(u) {
1166
+ } : s.prototype._next, a._error = i ? function(u) {
1167
1167
  try {
1168
1168
  i(u);
1169
1169
  } catch (h) {
@@ -1171,69 +1171,69 @@ var vt = function(n) {
1171
1171
  } finally {
1172
1172
  this.unsubscribe();
1173
1173
  }
1174
- } : n.prototype._error, a._complete = s ? function() {
1174
+ } : s.prototype._error, a._complete = n ? function() {
1175
1175
  try {
1176
- s();
1176
+ n();
1177
1177
  } catch (u) {
1178
1178
  e.error(u);
1179
1179
  } finally {
1180
1180
  this.unsubscribe();
1181
1181
  }
1182
- } : n.prototype._complete, a;
1182
+ } : s.prototype._complete, a;
1183
1183
  }
1184
1184
  return t.prototype.unsubscribe = function() {
1185
1185
  var e;
1186
1186
  if (!this.shouldUnsubscribe || this.shouldUnsubscribe()) {
1187
1187
  var r = this.closed;
1188
- n.prototype.unsubscribe.call(this), !r && ((e = this.onFinalize) === null || e === void 0 || e.call(this));
1188
+ s.prototype.unsubscribe.call(this), !r && ((e = this.onFinalize) === null || e === void 0 || e.call(this));
1189
1189
  }
1190
1190
  }, t;
1191
1191
  }(re);
1192
- function f(n, t) {
1192
+ function f(s, t) {
1193
1193
  return R(function(e, r) {
1194
- var s = 0;
1194
+ var n = 0;
1195
1195
  e.subscribe(A(r, function(i) {
1196
- r.next(n.call(t, i, s++));
1196
+ r.next(s.call(t, i, n++));
1197
1197
  }));
1198
1198
  });
1199
1199
  }
1200
- var bt = new gt(function(n) {
1201
- return n.complete();
1200
+ var bt = new gt(function(s) {
1201
+ return s.complete();
1202
1202
  });
1203
- function w(n) {
1204
- return n <= 0 ? function() {
1203
+ function w(s) {
1204
+ return s <= 0 ? function() {
1205
1205
  return bt;
1206
1206
  } : R(function(t, e) {
1207
1207
  var r = 0;
1208
- t.subscribe(A(e, function(s) {
1209
- ++r <= n && (e.next(s), n <= r && e.complete());
1208
+ t.subscribe(A(e, function(n) {
1209
+ ++r <= s && (e.next(n), s <= r && e.complete());
1210
1210
  }));
1211
1211
  });
1212
1212
  }
1213
- function m(n, t) {
1213
+ function m(s, t) {
1214
1214
  return R(function(e, r) {
1215
- var s = 0;
1215
+ var n = 0;
1216
1216
  e.subscribe(A(r, function(i) {
1217
- return n.call(t, i, s++) && r.next(i);
1217
+ return s.call(t, i, n++) && r.next(i);
1218
1218
  }));
1219
1219
  });
1220
1220
  }
1221
- function wt(n, t) {
1221
+ function wt(s, t) {
1222
1222
  return t === void 0 && (t = !1), R(function(e, r) {
1223
- var s = 0;
1223
+ var n = 0;
1224
1224
  e.subscribe(A(r, function(i) {
1225
- var o = n(i, s++);
1225
+ var o = s(i, n++);
1226
1226
  (o || t) && r.next(i), !o && r.complete();
1227
1227
  }));
1228
1228
  });
1229
1229
  }
1230
- function g(n, t, e) {
1231
- var r = E(n) || t || e ? { next: n, error: t, complete: e } : n;
1232
- return r ? R(function(s, i) {
1230
+ function g(s, t, e) {
1231
+ var r = E(s) || t || e ? { next: s, error: t, complete: e } : s;
1232
+ return r ? R(function(n, i) {
1233
1233
  var o;
1234
1234
  (o = r.subscribe) === null || o === void 0 || o.call(r);
1235
1235
  var c = !0;
1236
- s.subscribe(A(i, function(a) {
1236
+ n.subscribe(A(i, function(a) {
1237
1237
  var u;
1238
1238
  (u = r.next) === null || u === void 0 || u.call(r, a), i.next(a);
1239
1239
  }, function() {
@@ -1248,25 +1248,25 @@ function g(n, t, e) {
1248
1248
  }));
1249
1249
  }) : xe;
1250
1250
  }
1251
- const Ct = /^(\d+)\.(\d+)$/;
1252
- function St(n) {
1253
- if (typeof n == "string") {
1254
- const t = n.match(Ct);
1251
+ const St = /^(\d+)\.(\d+)$/;
1252
+ function Ct(s) {
1253
+ if (typeof s == "string") {
1254
+ const t = s.match(St);
1255
1255
  if (t)
1256
1256
  return `${t[1]}.${t[2]}`;
1257
1257
  }
1258
- throw new nt(n);
1258
+ throw new st(s);
1259
1259
  }
1260
- function me(n) {
1261
- const t = St(n), [e, r] = t.split("."), [s, i] = [parseInt(e), parseInt(r)];
1262
- return [s, i];
1260
+ function me(s) {
1261
+ const t = Ct(s), [e, r] = t.split("."), [n, i] = [parseInt(e), parseInt(r)];
1262
+ return [n, i];
1263
1263
  }
1264
- function Re(n, t) {
1265
- const [e, r] = me(n), [s, i] = me(t);
1266
- return e < s ? -1 : e > s ? 1 : r < i ? -1 : r > i ? 1 : 0;
1264
+ function Re(s, t) {
1265
+ const [e, r] = me(s), [n, i] = me(t);
1266
+ return e < n ? -1 : e > n ? 1 : r < i ? -1 : r > i ? 1 : 0;
1267
1267
  }
1268
- function Et(n, t) {
1269
- return Re(n, t) >= 0;
1268
+ function Et(s, t) {
1269
+ return Re(s, t) >= 0;
1270
1270
  }
1271
1271
  const ye = "2.0";
1272
1272
  class Mt {
@@ -1300,7 +1300,7 @@ class Mt {
1300
1300
  return this.inIframe ? this.iframePort1 : (e = (t = window.Acrobits) == null ? void 0 : t.messageChannel) == null ? void 0 : e.port1;
1301
1301
  }
1302
1302
  get port2() {
1303
- var t, e, r, s;
1303
+ var t, e, r, n;
1304
1304
  if (this.inIframe) {
1305
1305
  if (!this.iframePort2)
1306
1306
  throw new ue("port2");
@@ -1308,7 +1308,7 @@ class Mt {
1308
1308
  } else {
1309
1309
  if (!((e = (t = window.Acrobits) == null ? void 0 : t.messageChannel) != null && e.port2))
1310
1310
  throw new ue("port2");
1311
- return (s = (r = window.Acrobits) == null ? void 0 : r.messageChannel) == null ? void 0 : s.port2;
1311
+ return (n = (r = window.Acrobits) == null ? void 0 : r.messageChannel) == null ? void 0 : n.port2;
1312
1312
  }
1313
1313
  }
1314
1314
  /**
@@ -1334,16 +1334,16 @@ class Mt {
1334
1334
  const t = "HELLO", e = this.createMessage(t);
1335
1335
  e.protocolVersions = this.supportedVersions, this.logCreated(t, e);
1336
1336
  const r = this.incomingMessages$.pipe(
1337
- m((s) => s.type === t && s.replyTo === e.id),
1338
- f((s) => s),
1337
+ m((n) => n.type === t && n.replyTo === e.id),
1338
+ f((n) => n),
1339
1339
  g(this.logReceived()),
1340
- f((s) => {
1341
- if (!this.supportedVersions.includes(s.protocolVersion))
1342
- throw new le(s.protocolVersion, this.supportedVersions[0]);
1343
- return s.displayName || (s.displayName = s.cloudUsername), s;
1340
+ f((n) => {
1341
+ if (!this.supportedVersions.includes(n.protocolVersion))
1342
+ throw new le(n.protocolVersion, this.supportedVersions[0]);
1343
+ return n.displayName || (n.displayName = n.cloudUsername), n;
1344
1344
  }),
1345
- g((s) => {
1346
- this.negotiatedProtocolVersion = s.protocolVersion, this.logService.info(
1345
+ g((n) => {
1346
+ this.negotiatedProtocolVersion = n.protocolVersion, this.logService.info(
1347
1347
  `[IPC] Negotiated IPC Protocol Version: ${this.negotiatedProtocolVersion}`
1348
1348
  );
1349
1349
  }),
@@ -1364,8 +1364,8 @@ class Mt {
1364
1364
  const t = "TOKEN", e = this.createMessage(t);
1365
1365
  this.logCreated(t, e);
1366
1366
  const r = this.incomingMessages$.pipe(
1367
- m((s) => s.type === t && s.replyTo === e.id),
1368
- f((s) => s),
1367
+ m((n) => n.type === t && n.replyTo === e.id),
1368
+ f((n) => n),
1369
1369
  g(this.logReceived()),
1370
1370
  w(1)
1371
1371
  );
@@ -1390,14 +1390,14 @@ class Mt {
1390
1390
  const {
1391
1391
  roomName: e,
1392
1392
  roomInvite: r,
1393
- displayName: s,
1393
+ displayName: n,
1394
1394
  jwtToken: i,
1395
1395
  serverUrl: o,
1396
1396
  region: c,
1397
1397
  joinMicMuted: a,
1398
1398
  joinWithoutCamera: u
1399
1399
  } = t, h = "JOINING ROOM", l = this.createMessage(h, !1);
1400
- l.roomName = e, l.jwtToken = i, l.serverUrl = o, l.region = c, l.roomInvite = r, l.joinMicMuted = a ?? !1, l.joinWithoutCamera = u ?? !1, l.displayName = s, this.logCreated(h, l), this.port2.postMessage(l), this.logSent(h, l);
1400
+ l.roomName = e, l.jwtToken = i, l.serverUrl = o, l.region = c, l.roomInvite = r, l.joinMicMuted = a ?? !1, l.joinWithoutCamera = u ?? !1, l.displayName = n, this.logCreated(h, l), this.port2.postMessage(l), this.logSent(h, l);
1401
1401
  }
1402
1402
  /**
1403
1403
  * Sends a {@link LeavingRoomMessage} lifecycle message to the Host app.
@@ -1542,27 +1542,27 @@ class Mt {
1542
1542
  throw new d(this.currentContext);
1543
1543
  const e = "SCREENSHARE SOURCE", r = this.createMessage(e);
1544
1544
  r.sourceTypes = t, this.logCreated(e, r);
1545
- const s = this.incomingMessages$.pipe(
1545
+ const n = this.incomingMessages$.pipe(
1546
1546
  m((i) => i.type === e && i.replyTo === r.id),
1547
1547
  f((i) => i),
1548
1548
  g(this.logReceived()),
1549
1549
  f((i) => i),
1550
1550
  w(1)
1551
1551
  );
1552
- return this.logService.debug(`Created ${e} Reply handler`), this.port2.postMessage(r), this.logSent(e, r), s;
1552
+ return this.logService.debug(`Created ${e} Reply handler`), this.port2.postMessage(r), this.logSent(e, r), n;
1553
1553
  }
1554
1554
  layoutChange(t, e, r) {
1555
1555
  if (!this.isEmbedded())
1556
1556
  throw new d(this.currentContext);
1557
- const s = "LAYOUT CHANGE";
1557
+ const n = "LAYOUT CHANGE";
1558
1558
  let i, o;
1559
- if (e && r ? (i = this.createMessage(s, !1, r), i.result = e) : (i = this.createMessage(s), o = this.incomingMessages$.pipe(
1560
- m((c) => c.type === s && c.replyTo === i.id),
1559
+ if (e && r ? (i = this.createMessage(n, !1, r), i.result = e) : (i = this.createMessage(n), o = this.incomingMessages$.pipe(
1560
+ m((c) => c.type === n && c.replyTo === i.id),
1561
1561
  f((c) => c),
1562
1562
  g(this.logReceived()),
1563
1563
  f((c) => c),
1564
1564
  w(1)
1565
- ), this.logService.debug(`Created ${s} Reply handler`)), i.layout = t, this.logCreated(s, i), this.port2.postMessage(i), this.logSent(s, i), o)
1565
+ ), this.logService.debug(`Created ${n} Reply handler`)), i.layout = t, this.logCreated(n, i), this.port2.postMessage(i), this.logSent(n, i), o)
1566
1566
  return o;
1567
1567
  }
1568
1568
  /**
@@ -1613,21 +1613,21 @@ class Mt {
1613
1613
  Array.isArray(t) || (t = [t]);
1614
1614
  const e = "OAUTH TOKEN", r = this.createMessage(e);
1615
1615
  r.providerTypes = t, this.logCreated(e, r);
1616
- const s = this.incomingMessages$.pipe(
1616
+ const n = this.incomingMessages$.pipe(
1617
1617
  m((i) => i.type === e && i.replyTo === r.id),
1618
1618
  f((i) => i),
1619
1619
  g(this.logReceived()),
1620
1620
  w(1)
1621
1621
  );
1622
- return this.logService.debug(`Created ${e} Reply handler`), this.port2.postMessage(r), this.logSent(e, r), s;
1622
+ return this.logService.debug(`Created ${e} Reply handler`), this.port2.postMessage(r), this.logSent(e, r), n;
1623
1623
  }
1624
1624
  openUrl(t, e) {
1625
1625
  if (!this.isEmbedded())
1626
1626
  throw new d(this.currentContext);
1627
- const r = "OPEN URL", s = this.createMessage(r, !1);
1628
- s.url = t, s.data = e, this.logCreated(r, s), this.port2.postMessage(s), this.logSent(r, s);
1627
+ const r = "OPEN URL", n = this.createMessage(r, !1);
1628
+ n.url = t, n.data = e, this.logCreated(r, n), this.port2.postMessage(n), this.logSent(r, n);
1629
1629
  }
1630
- selectContacts(t, e, r, s) {
1630
+ selectContacts(t, e, r, n) {
1631
1631
  if (!this.isEmbedded())
1632
1632
  throw new d(this.currentContext);
1633
1633
  if (this.negotiatedProtocolVersion === "2.0") {
@@ -1647,7 +1647,7 @@ class Mt {
1647
1647
  t,
1648
1648
  e,
1649
1649
  r,
1650
- s
1650
+ n
1651
1651
  );
1652
1652
  }
1653
1653
  if (typeof e < "u" && typeof e != "object")
@@ -1660,17 +1660,17 @@ class Mt {
1660
1660
  );
1661
1661
  return this.selectContactsV2_1(t, e, r);
1662
1662
  }
1663
- selectContactsV2_0(t, e, r, s) {
1663
+ selectContactsV2_0(t, e, r, n) {
1664
1664
  if (!this.isEmbedded())
1665
1665
  throw new d(this.currentContext);
1666
- s && s.length > 0 && (s = s.map((a) => a.type === "cloudUsername" && a.contactUser ? {
1666
+ n && n.length > 0 && (n = n.map((a) => a.type === "cloudUsername" && a.contactUser ? {
1667
1667
  ...a,
1668
1668
  cloudId: a.cloudId || a.contactUser.cloudId,
1669
1669
  networkId: a.networkId || a.contactUser.networkId,
1670
1670
  cloudUsername: a.cloudUsername || a.contactUser.cloudUsername
1671
1671
  } : a));
1672
1672
  const i = "SELECT CONTACTS", o = this.createMessage(i, !0);
1673
- o.streamId = t, o.streamType = e, o.contactType = r, o.resultTypes = [r], o.currentContacts = s, this.logCreated(i, o);
1673
+ o.streamId = t, o.streamType = e, o.contactType = r, o.resultTypes = [r], o.currentContacts = n, this.logCreated(i, o);
1674
1674
  const c = this.incomingMessages$.pipe(
1675
1675
  m((a) => a.type === i && a.replyTo === o.id),
1676
1676
  g(this.logReceived()),
@@ -1690,7 +1690,7 @@ class Mt {
1690
1690
  selectContactsV2_1(t, e, r) {
1691
1691
  if (!this.isEmbedded())
1692
1692
  throw new d(this.currentContext);
1693
- const s = {
1693
+ const n = {
1694
1694
  allowMultipleSelection: (e == null ? void 0 : e.allowMultipleSelection) ?? !1,
1695
1695
  resultTypes: (e == null ? void 0 : e.resultTypes) ?? ["cloudUsername"]
1696
1696
  };
@@ -1718,7 +1718,7 @@ class Mt {
1718
1718
  }
1719
1719
  }
1720
1720
  const i = "SELECT CONTACTS", o = this.createMessage(i, !0);
1721
- o.streamId = t, o.resultTypes = s.resultTypes, o.currentContacts = r, o.allowMultipleSelection = s.allowMultipleSelection, this.logCreated(i, o);
1721
+ o.streamId = t, o.resultTypes = n.resultTypes, o.currentContacts = r, o.allowMultipleSelection = n.allowMultipleSelection, this.logCreated(i, o);
1722
1722
  const c = this.incomingMessages$.pipe(
1723
1723
  m((a) => a.type === i && a.replyTo === o.id),
1724
1724
  g(this.logReceived()),
@@ -1729,10 +1729,10 @@ class Mt {
1729
1729
  throw new ae(u.streamId, t);
1730
1730
  const h = u.contacts.length;
1731
1731
  u.contacts = u.contacts.filter(
1732
- (l) => s.resultTypes.includes(l.type)
1732
+ (l) => n.resultTypes.includes(l.type)
1733
1733
  ), u.contacts.length !== h && this.logService.debug(
1734
1734
  `[IPC] [SelectContactsReply] Filtered ${h - u.contacts.length} contacts from reply`
1735
- ), !s.allowMultipleSelection && u.contacts.length > 1 && (u.contacts = [u.contacts[0]]);
1735
+ ), !n.allowMultipleSelection && u.contacts.length > 1 && (u.contacts = [u.contacts[0]]);
1736
1736
  for (const l of u.contacts)
1737
1737
  if (l.type === "cloudUsername") {
1738
1738
  if (!l.contactUser)
@@ -1764,33 +1764,33 @@ class Mt {
1764
1764
  throw new y("contacts", t, "At least one contact is required");
1765
1765
  const e = this.createMessage("MATCH CONTACTS");
1766
1766
  if (this.compareVersion("2.1") >= 0) {
1767
- for (const s of t)
1768
- if (s.type === "cloudUsername") {
1769
- if (!s.contactUser)
1767
+ for (const n of t)
1768
+ if (n.type === "cloudUsername") {
1769
+ if (!n.contactUser)
1770
1770
  throw new y(
1771
1771
  "contacts",
1772
- s,
1772
+ n,
1773
1773
  "CloudUsername contact must include contactUser"
1774
1774
  );
1775
- if (!s.contactUser.cloudUsername || !s.contactUser.cloudId || !s.contactUser.networkId)
1775
+ if (!n.contactUser.cloudUsername || !n.contactUser.cloudId || !n.contactUser.networkId)
1776
1776
  throw new y(
1777
1777
  "contacts",
1778
- s,
1778
+ n,
1779
1779
  "CloudContact must define cloudUsername, cloudId, and networkId"
1780
1780
  );
1781
1781
  }
1782
1782
  e.contacts = [...t];
1783
1783
  } else {
1784
- for (const s of t)
1785
- s.type === "cloudUsername" && s.contactUser && (s.cloudId = s.contactUser.cloudId, s.networkId = s.contactUser.networkId, s.cloudUsername = s.contactUser.cloudUsername);
1784
+ for (const n of t)
1785
+ n.type === "cloudUsername" && n.contactUser && (n.cloudId = n.contactUser.cloudId, n.networkId = n.contactUser.networkId, n.cloudUsername = n.contactUser.cloudUsername);
1786
1786
  e.contacts = [...t];
1787
1787
  }
1788
1788
  this.logCreated(e.type, e);
1789
1789
  const r = this.incomingMessages$.pipe(
1790
- m((s) => s.type === e.type && s.replyTo === e.id),
1790
+ m((n) => n.type === e.type && n.replyTo === e.id),
1791
1791
  g(this.logReceived()),
1792
- f((s) => {
1793
- const i = s;
1792
+ f((n) => {
1793
+ const i = n;
1794
1794
  if (this.compareVersion("2.1") >= 0) {
1795
1795
  if (Array.isArray(i.contacts))
1796
1796
  throw new Error(
@@ -1904,9 +1904,9 @@ class Mt {
1904
1904
  const t = "PUSH TOKEN", e = this.createMessage(t);
1905
1905
  this.logCreated(t, e);
1906
1906
  const r = this.incomingMessages$.pipe(
1907
- m((s) => s.type === t && s.replyTo === e.id),
1907
+ m((n) => n.type === t && n.replyTo === e.id),
1908
1908
  g(this.logReceived()),
1909
- f((s) => s),
1909
+ f((n) => n),
1910
1910
  w(1)
1911
1911
  );
1912
1912
  return this.logService.debug(`Created ${t} Reply handler`), this.port2.postMessage(e), this.logSent(t, e), r;
@@ -1987,8 +1987,8 @@ class Mt {
1987
1987
  sendBadgeUpdateMessage(t, e, r) {
1988
1988
  if (!this.isEmbedded())
1989
1989
  throw new d(this.currentContext);
1990
- const s = "BADGE UPDATE", i = this.createMessage(s, !1, r);
1991
- i.count = t, i.activity = e ?? !1, this.logCreated(s, i), this.port2.postMessage(i), this.logSent(s, i);
1990
+ const n = "BADGE UPDATE", i = this.createMessage(n, !1, r);
1991
+ i.count = t, i.activity = e ?? !1, this.logCreated(n, i), this.port2.postMessage(i), this.logSent(n, i);
1992
1992
  }
1993
1993
  /**
1994
1994
  * Sends a {@link LifecycleMessage} to the Host app, to notify it of a lifecycle event.
@@ -2006,8 +2006,8 @@ class Mt {
2006
2006
  sendLifecycleMessage(t, e) {
2007
2007
  if (!this.isEmbedded())
2008
2008
  throw new d(this.currentContext);
2009
- const r = "LIFECYCLE", s = this.createMessage(r, !1);
2010
- s.eventName = t, s.payload = e, this.logCreated(r, s), this.port2.postMessage(s), this.logSent(r, s);
2009
+ const r = "LIFECYCLE", n = this.createMessage(r, !1);
2010
+ n.eventName = t, n.payload = e, this.logCreated(r, n), this.port2.postMessage(n), this.logSent(r, n);
2011
2011
  }
2012
2012
  /**
2013
2013
  * Setup listener for {@link LifecycleMessage}, which can be sent by a `Host` app to notify the
@@ -2045,8 +2045,8 @@ class Mt {
2045
2045
  sendLogMessage(t, e) {
2046
2046
  if (!this.isEmbedded())
2047
2047
  throw new d(this.currentContext);
2048
- const r = "LOG", s = this.createMessage(r, !1);
2049
- s.level = t, s.message = e, this.logCreated(r, s), this.port2.postMessage(s), this.logSent(r, s);
2048
+ const r = "LOG", n = this.createMessage(r, !1);
2049
+ n.level = t, n.message = e, this.logCreated(r, n), this.port2.postMessage(n), this.logSent(r, n);
2050
2050
  }
2051
2051
  /**
2052
2052
  * Setup listener for {@link RequestLogsMessage}, which can be sent by a `Host` app to request
@@ -2080,11 +2080,11 @@ class Mt {
2080
2080
  * @param format - Format of the file. Can be either `gzip` or `text`
2081
2081
  * @param replyTo - The message ID to which the reply should be sent
2082
2082
  */
2083
- sendRequestLogsMessageReply(t, e, r, s, i) {
2083
+ sendRequestLogsMessageReply(t, e, r, n, i) {
2084
2084
  if (!this.isEmbedded())
2085
2085
  throw new d(this.currentContext);
2086
2086
  const o = "REQUEST LOGS", c = this.createMessage(o, !1, i);
2087
- c.fileId = t, c.fileHash = e, c.fileSize = r, c.format = s, this.logCreated(o, c), this.port2.postMessage(c), this.logSent(o, c);
2087
+ c.fileId = t, c.fileHash = e, c.fileSize = r, c.format = n, this.logCreated(o, c), this.port2.postMessage(c), this.logSent(o, c);
2088
2088
  }
2089
2089
  /**
2090
2090
  * Send a {@link ViewTransitionMessage} to the `Host` app, notifying it of a view transition
@@ -2102,8 +2102,8 @@ class Mt {
2102
2102
  sendViewTransitionMessage(t, e) {
2103
2103
  if (!this.isEmbedded())
2104
2104
  throw new d(this.currentContext);
2105
- const r = "VIEW TRANSITION", s = this.createMessage(r, !1);
2106
- s.transitionType = t, s.targetView = e, this.logCreated(r, s), this.port2.postMessage(s), this.logSent(r, s);
2105
+ const r = "VIEW TRANSITION", n = this.createMessage(r, !1);
2106
+ n.transitionType = t, n.targetView = e, this.logCreated(r, n), this.port2.postMessage(n), this.logSent(r, n);
2107
2107
  }
2108
2108
  /**
2109
2109
  * Sends a {@link FileRequestMessage} to the Host app, to request a file by it's SHA256 hash.
@@ -2146,18 +2146,18 @@ class Mt {
2146
2146
  * @returns An observable that either emits once if the result is `error` or `not found` or
2147
2147
  * emits as many times as the number of chunks in the file if the result is `success`.
2148
2148
  */
2149
- sendFileRequestMessage(t, e, r, s, i) {
2149
+ sendFileRequestMessage(t, e, r, n, i) {
2150
2150
  if (!this.isEmbedded())
2151
2151
  throw new d(this.currentContext);
2152
2152
  const o = "FILE REQUEST", c = this.createMessage(o);
2153
2153
  if (c.fileId = t, c.fileHash = e.toLowerCase(), c.intent = r, c.maxChunkSizeInBytes = i, r === "attachment") {
2154
- if (!s)
2154
+ if (!n)
2155
2155
  throw new y(
2156
2156
  "streamId",
2157
- s,
2157
+ n,
2158
2158
  "streamId is required for attachment intent"
2159
2159
  );
2160
- c.streamId = s;
2160
+ c.streamId = n;
2161
2161
  }
2162
2162
  this.logCreated(o, c);
2163
2163
  let a = 0;
@@ -2194,11 +2194,11 @@ class Mt {
2194
2194
  sendFileRequestMessageReply(t, e) {
2195
2195
  if (!this.isEmbedded())
2196
2196
  throw new d(this.currentContext);
2197
- const r = "FILE REQUEST", s = Object.assign(
2197
+ const r = "FILE REQUEST", n = Object.assign(
2198
2198
  e,
2199
2199
  this.createMessage(r, !1, t.id)
2200
2200
  );
2201
- this.logCreated(r, s), this.port2.postMessage(s), this.logSent(r, s);
2201
+ this.logCreated(r, n), this.port2.postMessage(n), this.logSent(r, n);
2202
2202
  }
2203
2203
  /**
2204
2204
  * Setup a listener for {@link FileRequestMessage}, which can be sent by a Host app to request a
@@ -2246,11 +2246,11 @@ class Mt {
2246
2246
  *
2247
2247
  * @returns This method returns void.
2248
2248
  */
2249
- sendFileSelectionMessage(t = "attachment", e, r, s, i, o) {
2249
+ sendFileSelectionMessage(t = "attachment", e, r, n, i, o) {
2250
2250
  if (!this.isEmbedded())
2251
2251
  throw new d(this.currentContext);
2252
2252
  const c = "FILE SELECTION", a = this.createMessage(c);
2253
- if (a.intent = t, a.maxCount = s, a.maxFileSizeInBytes = i, a.mimeTypes = o, t === "attachment") {
2253
+ if (a.intent = t, a.maxCount = n, a.maxFileSizeInBytes = i, a.mimeTypes = o, t === "attachment") {
2254
2254
  if (!e)
2255
2255
  throw new y(
2256
2256
  "streamId",
@@ -2301,11 +2301,11 @@ class Mt {
2301
2301
  sendFileDownloadProgressQueryMessage(t, e, r) {
2302
2302
  if (!this.isEmbedded())
2303
2303
  throw new d(this.currentContext);
2304
- const s = "FILE DOWNLOAD PROGRESS QUERY", i = this.createMessage(
2305
- s,
2304
+ const n = "FILE DOWNLOAD PROGRESS QUERY", i = this.createMessage(
2305
+ n,
2306
2306
  !0
2307
2307
  );
2308
- i.fileHash = t.toLowerCase(), i.url = e, i.correlationId = r, this.logCreated(s, i);
2308
+ i.fileHash = t.toLowerCase(), i.url = e, i.correlationId = r, this.logCreated(n, i);
2309
2309
  const o = this.incomingMessages$.pipe(
2310
2310
  m(
2311
2311
  (c) => c.type === "FILE DOWNLOAD PROGRESS UPDATE" && c.replyTo === i.id
@@ -2314,7 +2314,7 @@ class Mt {
2314
2314
  f((c) => (c.fileHash && (c.fileHash = c.fileHash.toLowerCase()), c)),
2315
2315
  w(1)
2316
2316
  );
2317
- return this.port2.postMessage(i), this.logSent(s, i), o;
2317
+ return this.port2.postMessage(i), this.logSent(n, i), o;
2318
2318
  }
2319
2319
  /**
2320
2320
  * Setup listener for {@link FileDownloadProgressQueryMessage}, which can be sent by a `Host` app
@@ -2352,11 +2352,11 @@ class Mt {
2352
2352
  sendFileUploadProgressQueryMessage(t, e, r) {
2353
2353
  if (!this.isEmbedded())
2354
2354
  throw new d(this.currentContext);
2355
- const s = "FILE UPLOAD PROGRESS QUERY", i = this.createMessage(
2356
- s,
2355
+ const n = "FILE UPLOAD PROGRESS QUERY", i = this.createMessage(
2356
+ n,
2357
2357
  !0
2358
2358
  );
2359
- i.fileHash = t.toLowerCase(), i.fileId = e, i.correlationId = r, this.logCreated(s, i);
2359
+ i.fileHash = t.toLowerCase(), i.fileId = e, i.correlationId = r, this.logCreated(n, i);
2360
2360
  const o = this.incomingMessages$.pipe(
2361
2361
  m(
2362
2362
  (c) => c.type === "FILE UPLOAD PROGRESS UPDATE" && c.replyTo === i.id
@@ -2365,7 +2365,7 @@ class Mt {
2365
2365
  f((c) => (c.fileHash && (c.fileHash = c.fileHash.toLowerCase()), c)),
2366
2366
  w(1)
2367
2367
  );
2368
- return this.port2.postMessage(i), this.logSent(s, i), o;
2368
+ return this.port2.postMessage(i), this.logSent(n, i), o;
2369
2369
  }
2370
2370
  /**
2371
2371
  * Setup listener for {@link FileUploadProgressQueryMessage}, which can be sent by a `Host` app to
@@ -2415,7 +2415,7 @@ class Mt {
2415
2415
  * @returns An observable which emits a {@link FileDownloadMessageReply} instance containing the
2416
2416
  * result of the request. Emits once.
2417
2417
  */
2418
- sendFileDownloadMessage(t, e, r, s, i, o, c, a, u) {
2418
+ sendFileDownloadMessage(t, e, r, n, i, o, c, a, u) {
2419
2419
  if (!this.isEmbedded())
2420
2420
  throw new d(this.currentContext);
2421
2421
  if (a && this.compareVersion("2.1") < 0)
@@ -2440,7 +2440,7 @@ class Mt {
2440
2440
  );
2441
2441
  }
2442
2442
  const h = "FILE DOWNLOAD", l = this.createMessage(h, !0);
2443
- l.url = t, l.key = e, l.fileHash = r.toLowerCase(), l.mimeType = s, l.fileName = i, l.streamId = o, l.correlationId = c, l.sender = a, l.intent = u ?? "download", this.logCreated(h, l);
2443
+ l.url = t, l.key = e, l.fileHash = r.toLowerCase(), l.mimeType = n, l.fileName = i, l.streamId = o, l.correlationId = c, l.sender = a, l.intent = u ?? "download", this.logCreated(h, l);
2444
2444
  const b = this.incomingMessages$.pipe(
2445
2445
  m((p) => p.type === h && p.replyTo === l.id),
2446
2446
  g(this.logReceived()),
@@ -2460,8 +2460,8 @@ class Mt {
2460
2460
  sendCancelFileDownloadMessage(t, e, r) {
2461
2461
  if (!this.isEmbedded())
2462
2462
  throw new d(this.currentContext);
2463
- const s = "CANCEL FILE DOWNLOAD", i = this.createMessage(s, !1);
2464
- i.fileHash = t.toLowerCase(), i.url = e, i.correlationId = r, this.logCreated(s, i), this.port2.postMessage(i), this.logSent(s, i);
2463
+ const n = "CANCEL FILE DOWNLOAD", i = this.createMessage(n, !1);
2464
+ i.fileHash = t.toLowerCase(), i.url = e, i.correlationId = r, this.logCreated(n, i), this.port2.postMessage(i), this.logSent(n, i);
2465
2465
  }
2466
2466
  /**
2467
2467
  * Sends a {@link FileRemoveMessage} to the Host app, to request removal of a file from the
@@ -2481,15 +2481,15 @@ class Mt {
2481
2481
  sendFileRemoveMessage(t, e) {
2482
2482
  if (!this.isEmbedded())
2483
2483
  throw new d(this.currentContext);
2484
- const r = "FILE REMOVE", s = this.createMessage(r, !0);
2485
- s.hash = t.toLowerCase(), s.streamId = e, this.logCreated(r, s);
2484
+ const r = "FILE REMOVE", n = this.createMessage(r, !0);
2485
+ n.hash = t.toLowerCase(), n.streamId = e, this.logCreated(r, n);
2486
2486
  const i = this.incomingMessages$.pipe(
2487
- m((o) => o.type === r && o.replyTo === s.id),
2487
+ m((o) => o.type === r && o.replyTo === n.id),
2488
2488
  g(this.logReceived()),
2489
2489
  f((o) => o),
2490
2490
  w(1)
2491
2491
  );
2492
- return this.port2.postMessage(s), this.logSent(r, s), i;
2492
+ return this.port2.postMessage(n), this.logSent(r, n), i;
2493
2493
  }
2494
2494
  /**
2495
2495
  * Sends a {@link AppResetMessage} to the Host app, to request logging out the user and resetting
@@ -2531,8 +2531,8 @@ class Mt {
2531
2531
  sendMessageSentMessage(t, e) {
2532
2532
  if (!this.isEmbedded())
2533
2533
  throw new d(this.currentContext);
2534
- const r = "MESSAGE SENT", s = this.createMessage(r, !1);
2535
- s.streamId = t, s.correlationId = e, this.logCreated(r, s), this.port2.postMessage(s), this.logSent(r, s);
2534
+ const r = "MESSAGE SENT", n = this.createMessage(r, !1);
2535
+ n.streamId = t, n.correlationId = e, this.logCreated(r, n), this.port2.postMessage(n), this.logSent(r, n);
2536
2536
  }
2537
2537
  /**
2538
2538
  * Sends a {@link SendMessageMessage} to the Host app, to send a message to the specified stream.
@@ -2552,11 +2552,11 @@ class Mt {
2552
2552
  * @returns An observable which emits a {@link SendMessageMessageReply} instance containing the
2553
2553
  * result of the request. Emits once.
2554
2554
  */
2555
- sendSendMessageMessage(t, e, r, s = "TEXT", i, o, c, a = !0, u) {
2555
+ sendSendMessageMessage(t, e, r, n = "TEXT", i, o, c, a = !0, u) {
2556
2556
  if (!this.isEmbedded())
2557
2557
  throw new d(this.currentContext);
2558
2558
  const h = "SEND MESSAGE", l = this.createMessage(h, !0);
2559
- if (l.streamId = t, l.correlationId = e, l.body = r, l.messageType = s, i && i.length > 0)
2559
+ if (l.streamId = t, l.correlationId = e, l.body = r, l.messageType = n, i && i.length > 0)
2560
2560
  if (this.compareVersion("2.1") < 0)
2561
2561
  l.mentions = i.map((p) => p.contactUser ? {
2562
2562
  ...p,
@@ -2604,8 +2604,8 @@ class Mt {
2604
2604
  sendCancelSendMessageMessage(t, e) {
2605
2605
  if (!this.isEmbedded())
2606
2606
  throw new d(this.currentContext);
2607
- const r = "CANCEL SEND MESSAGE", s = this.createMessage(r, !1);
2608
- s.streamId = t, s.correlationId = e, this.logCreated(r, s), this.port2.postMessage(s), this.logSent(r, s);
2607
+ const r = "CANCEL SEND MESSAGE", n = this.createMessage(r, !1);
2608
+ n.streamId = t, n.correlationId = e, this.logCreated(r, n), this.port2.postMessage(n), this.logSent(r, n);
2609
2609
  }
2610
2610
  /**
2611
2611
  * Sends a {@link MessageDeletedMessage} to the Host app, to notify deletion of a message from the
@@ -2617,8 +2617,8 @@ class Mt {
2617
2617
  sendMessageDeletedMessage(t, e) {
2618
2618
  if (!this.isEmbedded())
2619
2619
  throw new d(this.currentContext);
2620
- const r = "MESSAGE DELETED", s = this.createMessage(r, !1);
2621
- s.correlationId = t, s.streamId = e, this.logCreated(r, s), this.port2.postMessage(s), this.logSent(r, s);
2620
+ const r = "MESSAGE DELETED", n = this.createMessage(r, !1);
2621
+ n.correlationId = t, n.streamId = e, this.logCreated(r, n), this.port2.postMessage(n), this.logSent(r, n);
2622
2622
  }
2623
2623
  /**
2624
2624
  * Sends a {@link SendMessageStatusQueryMessage} to the Host app, to query the status of a message
@@ -2636,17 +2636,17 @@ class Mt {
2636
2636
  sendSendMessageStatusQueryMessage(t, e) {
2637
2637
  if (!this.isEmbedded())
2638
2638
  throw new d(this.currentContext);
2639
- const r = "SEND MESSAGE STATUS QUERY", s = this.createMessage(r, !0);
2640
- s.correlationId = t, s.streamId = e, this.logCreated(r, s);
2639
+ const r = "SEND MESSAGE STATUS QUERY", n = this.createMessage(r, !0);
2640
+ n.correlationId = t, n.streamId = e, this.logCreated(r, n);
2641
2641
  const i = this.incomingMessages$.pipe(
2642
2642
  m(
2643
- (o) => o.type === "SEND MESSAGE STATUS UPDATE" && o.replyTo === s.id
2643
+ (o) => o.type === "SEND MESSAGE STATUS UPDATE" && o.replyTo === n.id
2644
2644
  ),
2645
2645
  g(this.logReceived()),
2646
2646
  f((o) => o),
2647
2647
  w(1)
2648
2648
  );
2649
- return this.port2.postMessage(s), this.logSent(r, s), i;
2649
+ return this.port2.postMessage(n), this.logSent(r, n), i;
2650
2650
  }
2651
2651
  /**
2652
2652
  * Setup a listener for {@link SendMessageStatusUpdateMessage}, which can be sent by a Host app to
@@ -2703,8 +2703,8 @@ class Mt {
2703
2703
  sendCustomFunctionMessage(t, e) {
2704
2704
  if (!this.isEmbedded())
2705
2705
  throw new d(this.currentContext);
2706
- const r = "CUSTOM FUNCTION", s = this.createMessage(r, !1);
2707
- s.customFunctionId = t, s.context = e, this.logCreated(r, s), this.port2.postMessage(s), this.logSent(r, s);
2706
+ const r = "CUSTOM FUNCTION", n = this.createMessage(r, !1);
2707
+ n.customFunctionId = t, n.context = e, this.logCreated(r, n), this.port2.postMessage(n), this.logSent(r, n);
2708
2708
  }
2709
2709
  /**
2710
2710
  * Sends a {@link SubscribeButtonsMessage} to the Host app to subscribe to button updates for
@@ -2841,15 +2841,15 @@ class Mt {
2841
2841
  }
2842
2842
  generateId(t = 8, e = !1) {
2843
2843
  let r = "1234567890qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM";
2844
- const s = [];
2844
+ const n = [];
2845
2845
  e && (r = r.substr(0, r.indexOf("Q")));
2846
2846
  for (let i = 0; i < t; i++)
2847
- s.push(r[Math.floor(Math.random() * r.length)]);
2848
- return s.join("");
2847
+ n.push(r[Math.floor(Math.random() * r.length)]);
2848
+ return n.join("");
2849
2849
  }
2850
2850
  }
2851
- function It(n) {
2852
- return n.type === "FILE REQUEST" && n.replyTo !== null;
2851
+ function It(s) {
2852
+ return s.type === "FILE REQUEST" && s.replyTo !== null;
2853
2853
  }
2854
2854
  const Ut = ["2.0", "2.1"];
2855
2855
  class xt {
@@ -2883,7 +2883,7 @@ class xt {
2883
2883
  M(this, "logger");
2884
2884
  M(this, "helper");
2885
2885
  M(this, "listeners");
2886
- this.logger = t ?? console, this.helper = new Mt(Ut, this.logger), this.listeners = /* @__PURE__ */ new Map(), this.listeners.set(C.BadgeQuery, /* @__PURE__ */ new Set()), this.listeners.set(C.Lifecycle, /* @__PURE__ */ new Set()), this.listeners.set(C.PushToken, /* @__PURE__ */ new Set()), this.listeners.set(C.RequestLogs, /* @__PURE__ */ new Set());
2886
+ this.logger = t ?? console, this.helper = new Mt(Ut, this.logger), this.listeners = /* @__PURE__ */ new Map(), this.listeners.set(S.BadgeQuery, /* @__PURE__ */ new Set()), this.listeners.set(S.Lifecycle, /* @__PURE__ */ new Set()), this.listeners.set(S.PushToken, /* @__PURE__ */ new Set()), this.listeners.set(S.RequestLogs, /* @__PURE__ */ new Set());
2887
2887
  }
2888
2888
  /**
2889
2889
  * Returns whether the app is running inside a native WebView (`host` context) or as a
@@ -2925,24 +2925,24 @@ class xt {
2925
2925
  this.helper.onBadgeQueryMessage().subscribe((e) => {
2926
2926
  var r;
2927
2927
  this.logger.debug("Received Badge Query: ", e);
2928
- for (const s of ((r = this.listeners.get(C.BadgeQuery)) == null ? void 0 : r.values()) ?? [])
2929
- s();
2928
+ for (const n of ((r = this.listeners.get(S.BadgeQuery)) == null ? void 0 : r.values()) ?? [])
2929
+ n();
2930
2930
  }), this.helper.onLifecycleMessage().subscribe((e) => {
2931
2931
  var r;
2932
2932
  this.logger.debug("Received Lifecycle Event: ", e);
2933
- for (const s of ((r = this.listeners.get(C.Lifecycle)) == null ? void 0 : r.values()) ?? [])
2934
- s(e.eventName, e.payload);
2933
+ for (const n of ((r = this.listeners.get(S.Lifecycle)) == null ? void 0 : r.values()) ?? [])
2934
+ n(e.eventName, e.payload);
2935
2935
  }), this.helper.onPushTokenMessage().subscribe((e) => {
2936
2936
  var r;
2937
2937
  this.logger.debug("Received Push Token: ", e);
2938
- for (const s of ((r = this.listeners.get(C.PushToken)) == null ? void 0 : r.values()) ?? [])
2939
- s(e.pushToken, e.appId, e.selector);
2938
+ for (const n of ((r = this.listeners.get(S.PushToken)) == null ? void 0 : r.values()) ?? [])
2939
+ n(e.pushToken, e.appId, e.selector);
2940
2940
  }), this.helper.onRequestLogsMessage().subscribe((e) => {
2941
2941
  var r;
2942
2942
  if (this.logger.debug("Received Request Logs Message: ", e), e.responseType === "file")
2943
2943
  throw this.logger.error("File response type not supported"), new Error("File response type not supported");
2944
- for (const s of ((r = this.listeners.get(C.RequestLogs)) == null ? void 0 : r.values()) ?? [])
2945
- s(e.skipCompression);
2944
+ for (const n of ((r = this.listeners.get(S.RequestLogs)) == null ? void 0 : r.values()) ?? [])
2945
+ n(e.skipCompression);
2946
2946
  }), this.cloudId = t.cloudId, this.cloudUsername = t.cloudUsername, this.displayName = t.displayName, this.host = t.host;
2947
2947
  }),
2948
2948
  _(() => {
@@ -2950,23 +2950,23 @@ class xt {
2950
2950
  )
2951
2951
  );
2952
2952
  }
2953
- selectContacts(t, e, r, s) {
2953
+ selectContacts(t, e, r, n) {
2954
2954
  this.logger.debug("Selecting Contacts: ", ...arguments);
2955
2955
  let i;
2956
2956
  if (this.negotiatedVersion === "2.0") {
2957
2957
  if (typeof e != "string")
2958
2958
  throw new y("mode", e, 'mode must be "single" or "multi"');
2959
- if (s === "number")
2959
+ if (n === "number")
2960
2960
  throw new y(
2961
2961
  "contactType",
2962
- s,
2962
+ n,
2963
2963
  'contactType cannot be "number" for version 2.0 of the IPC protocol'
2964
2964
  );
2965
2965
  i = this.selectContacts_V2_0(
2966
2966
  t,
2967
2967
  e ?? "single",
2968
2968
  e === "multi" ? r : void 0,
2969
- e === "multi" ? s : r
2969
+ e === "multi" ? n : r
2970
2970
  );
2971
2971
  } else {
2972
2972
  if (typeof e != "object")
@@ -2984,7 +2984,7 @@ class xt {
2984
2984
  )
2985
2985
  );
2986
2986
  }
2987
- selectContacts_V2_0(t, e, r, s) {
2987
+ selectContacts_V2_0(t, e, r, n) {
2988
2988
  if (this.logger.debug("Selecting Contacts: ", ...arguments), e === "multi") {
2989
2989
  if (!r || !Array.isArray(r))
2990
2990
  throw new y(
@@ -2992,14 +2992,14 @@ class xt {
2992
2992
  r,
2993
2993
  "currentContacts is required for group streams"
2994
2994
  );
2995
- return s || (s = "cloudUsername"), this.helper.selectContacts(
2995
+ return n || (n = "cloudUsername"), this.helper.selectContacts(
2996
2996
  t.toString(),
2997
2997
  "group",
2998
- s,
2998
+ n,
2999
2999
  r
3000
3000
  );
3001
3001
  } else
3002
- return s || (s = "cloudUsername"), this.helper.selectContacts(t.toString(), "direct", s);
3002
+ return n || (n = "cloudUsername"), this.helper.selectContacts(t.toString(), "direct", n);
3003
3003
  }
3004
3004
  selectContacts_V2_1(t, e) {
3005
3005
  if (this.logger.debug("Selecting Contacts: ", e), e.mode === "multi" && (!e.currentContacts || !Array.isArray(e.currentContacts)))
@@ -3104,9 +3104,9 @@ class xt {
3104
3104
  */
3105
3105
  onBadgeQueryRequest(t) {
3106
3106
  var e;
3107
- return this.logger.debug("Registering for Badge Query"), (e = this.listeners.get(C.BadgeQuery)) == null || e.add(t), () => {
3107
+ return this.logger.debug("Registering for Badge Query"), (e = this.listeners.get(S.BadgeQuery)) == null || e.add(t), () => {
3108
3108
  var r;
3109
- return (r = this.listeners.get(C.BadgeQuery)) == null ? void 0 : r.delete(t);
3109
+ return (r = this.listeners.get(S.BadgeQuery)) == null ? void 0 : r.delete(t);
3110
3110
  };
3111
3111
  }
3112
3112
  /**
@@ -3123,9 +3123,9 @@ class xt {
3123
3123
  */
3124
3124
  onLifecycleEvent(t) {
3125
3125
  var e;
3126
- return this.logger.debug("Registering for Lifecycle Event"), (e = this.listeners.get(C.Lifecycle)) == null || e.add(t), () => {
3126
+ return this.logger.debug("Registering for Lifecycle Event"), (e = this.listeners.get(S.Lifecycle)) == null || e.add(t), () => {
3127
3127
  var r;
3128
- return (r = this.listeners.get(C.Lifecycle)) == null ? void 0 : r.delete(t);
3128
+ return (r = this.listeners.get(S.Lifecycle)) == null ? void 0 : r.delete(t);
3129
3129
  };
3130
3130
  }
3131
3131
  /**
@@ -3141,9 +3141,9 @@ class xt {
3141
3141
  */
3142
3142
  onPushToken(t) {
3143
3143
  var e;
3144
- return this.logger.debug("Registering for Push Token"), (e = this.listeners.get(C.PushToken)) == null || e.add(t), () => {
3144
+ return this.logger.debug("Registering for Push Token"), (e = this.listeners.get(S.PushToken)) == null || e.add(t), () => {
3145
3145
  var r;
3146
- return (r = this.listeners.get(C.PushToken)) == null ? void 0 : r.delete(t);
3146
+ return (r = this.listeners.get(S.PushToken)) == null ? void 0 : r.delete(t);
3147
3147
  };
3148
3148
  }
3149
3149
  /**
@@ -3163,9 +3163,9 @@ class xt {
3163
3163
  */
3164
3164
  onRequestLogsMessage(t) {
3165
3165
  var e;
3166
- return this.logger.debug("Registering for Request Logs Message"), (e = this.listeners.get(C.RequestLogs)) == null || e.add(t), () => {
3166
+ return this.logger.debug("Registering for Request Logs Message"), (e = this.listeners.get(S.RequestLogs)) == null || e.add(t), () => {
3167
3167
  var r;
3168
- return (r = this.listeners.get(C.RequestLogs)) == null ? void 0 : r.delete(t);
3168
+ return (r = this.listeners.get(S.RequestLogs)) == null ? void 0 : r.delete(t);
3169
3169
  };
3170
3170
  }
3171
3171
  evaluateContext(t) {
@@ -3176,6 +3176,6 @@ class xt {
3176
3176
  }
3177
3177
  }
3178
3178
  export {
3179
- C as IPCEvents,
3179
+ S as IPCEvents,
3180
3180
  xt as IPCManager
3181
3181
  };