@acrobits/ipc-sdk 0.6.3 → 0.7.1
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/docs/assets/main.js +4 -4
- package/docs/assets/search.js +1 -1
- package/docs/assets/style.css +46 -15
- package/docs/classes/IPCManager.html +29 -24
- package/docs/enums/IPCEvents.html +1 -1
- package/docs/hierarchy.html +1 -0
- package/docs/index.html +1 -1
- package/docs/interfaces/BaseContactItem.html +2 -2
- package/docs/interfaces/CloudUsernameContactItem.html +2 -2
- package/docs/interfaces/DetailedContactItem.html +2 -2
- package/docs/interfaces/ILogger.html +2 -2
- package/docs/interfaces/UriContactItem.html +2 -2
- package/docs/modules.html +1 -1
- package/docs/types/ContactItem.html +1 -1
- package/docs/types/ContactLabel.html +1 -1
- package/docs/types/ContactType.html +1 -1
- package/docs/types/ContactURI.html +1 -1
- package/docs/types/HostType.html +1 -1
- package/docs/types/IPCContext.html +1 -1
- package/docs/types/IpcProtocolVersion.html +1 -1
- package/docs/types/UnsubscribeCallback.html +2 -2
- package/lib/index.d.ts +10 -0
- package/lib/ipc-sdk.js +207 -197
- package/lib/ipc-sdk.js.map +1 -1
- package/lib/ipc-sdk.umd.cjs +3 -3
- package/lib/ipc-sdk.umd.cjs.map +1 -1
- package/lib/tsdoc-metadata.json +1 -1
- package/package.json +9 -9
package/lib/ipc-sdk.js
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var x = (n, t, e) => (
|
|
4
|
-
var b = /* @__PURE__ */ ((n) => (n.BadgeQuery = "BADGE QUERY", n.Lifecycle = "LIFECYCLE", n.PushToken = "PUSH TOKEN", n))(b || {}),
|
|
5
|
-
return
|
|
1
|
+
var Ie = Object.defineProperty;
|
|
2
|
+
var Pe = (n, t, e) => t in n ? Ie(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e;
|
|
3
|
+
var x = (n, t, e) => (Pe(n, typeof t != "symbol" ? t + "" : t, e), e);
|
|
4
|
+
var b = /* @__PURE__ */ ((n) => (n.BadgeQuery = "BADGE QUERY", n.Lifecycle = "LIFECYCLE", n.PushToken = "PUSH TOKEN", n))(b || {}), H = function(n, t) {
|
|
5
|
+
return H = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e, r) {
|
|
6
6
|
e.__proto__ = r;
|
|
7
7
|
} || function(e, r) {
|
|
8
8
|
for (var i in r)
|
|
9
9
|
Object.prototype.hasOwnProperty.call(r, i) && (e[i] = r[i]);
|
|
10
|
-
},
|
|
10
|
+
}, H(n, t);
|
|
11
11
|
};
|
|
12
12
|
function M(n, 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
|
-
|
|
15
|
+
H(n, t);
|
|
16
16
|
function e() {
|
|
17
17
|
this.constructor = n;
|
|
18
18
|
}
|
|
19
19
|
n.prototype = t === null ? Object.create(t) : (e.prototype = t.prototype, new e());
|
|
20
20
|
}
|
|
21
|
-
function
|
|
21
|
+
function z(n) {
|
|
22
22
|
var t = typeof Symbol == "function" && Symbol.iterator, e = t && n[t], r = 0;
|
|
23
23
|
if (e)
|
|
24
24
|
return e.call(n);
|
|
@@ -30,7 +30,7 @@ function Q(n) {
|
|
|
30
30
|
};
|
|
31
31
|
throw new TypeError(t ? "Object is not iterable." : "Symbol.iterator is not defined.");
|
|
32
32
|
}
|
|
33
|
-
function
|
|
33
|
+
function L(n, t) {
|
|
34
34
|
var e = typeof Symbol == "function" && n[Symbol.iterator];
|
|
35
35
|
if (!e)
|
|
36
36
|
return n;
|
|
@@ -50,7 +50,7 @@ function _(n, t) {
|
|
|
50
50
|
}
|
|
51
51
|
return s;
|
|
52
52
|
}
|
|
53
|
-
function
|
|
53
|
+
function $(n, t, e) {
|
|
54
54
|
if (e || arguments.length === 2)
|
|
55
55
|
for (var r = 0, i = t.length, s; r < i; r++)
|
|
56
56
|
(s || !(r in t)) && (s || (s = Array.prototype.slice.call(t, 0, r)), s[r] = t[r]);
|
|
@@ -59,13 +59,13 @@ function I(n, t, e) {
|
|
|
59
59
|
function m(n) {
|
|
60
60
|
return typeof n == "function";
|
|
61
61
|
}
|
|
62
|
-
function
|
|
62
|
+
function X(n) {
|
|
63
63
|
var t = function(r) {
|
|
64
64
|
Error.call(r), r.stack = new Error().stack;
|
|
65
65
|
}, e = n(t);
|
|
66
66
|
return e.prototype = Object.create(Error.prototype), e.prototype.constructor = e, e;
|
|
67
67
|
}
|
|
68
|
-
var
|
|
68
|
+
var j = X(function(n) {
|
|
69
69
|
return function(e) {
|
|
70
70
|
n(this), this.message = e ? e.length + ` errors occurred during unsubscription:
|
|
71
71
|
` + e.map(function(r, i) {
|
|
@@ -80,7 +80,7 @@ function U(n, t) {
|
|
|
80
80
|
0 <= e && n.splice(e, 1);
|
|
81
81
|
}
|
|
82
82
|
}
|
|
83
|
-
var
|
|
83
|
+
var R = function() {
|
|
84
84
|
function n(t) {
|
|
85
85
|
this.initialTeardown = t, this.closed = !1, this._parentage = null, this._finalizers = null;
|
|
86
86
|
}
|
|
@@ -92,7 +92,7 @@ var P = function() {
|
|
|
92
92
|
if (o)
|
|
93
93
|
if (this._parentage = null, Array.isArray(o))
|
|
94
94
|
try {
|
|
95
|
-
for (var c =
|
|
95
|
+
for (var c = z(o), a = c.next(); !a.done; a = c.next()) {
|
|
96
96
|
var u = a.value;
|
|
97
97
|
u.remove(this);
|
|
98
98
|
}
|
|
@@ -113,18 +113,18 @@ var P = function() {
|
|
|
113
113
|
try {
|
|
114
114
|
g();
|
|
115
115
|
} catch (p) {
|
|
116
|
-
s = p instanceof
|
|
116
|
+
s = p instanceof j ? p.errors : [p];
|
|
117
117
|
}
|
|
118
118
|
var v = this._finalizers;
|
|
119
119
|
if (v) {
|
|
120
120
|
this._finalizers = null;
|
|
121
121
|
try {
|
|
122
|
-
for (var E =
|
|
123
|
-
var
|
|
122
|
+
for (var E = z(v), w = E.next(); !w.done; w = E.next()) {
|
|
123
|
+
var V = w.value;
|
|
124
124
|
try {
|
|
125
|
-
|
|
125
|
+
ie(V);
|
|
126
126
|
} catch (p) {
|
|
127
|
-
s = s ?? [], p instanceof
|
|
127
|
+
s = s ?? [], p instanceof j ? s = $($([], L(s)), L(p.errors)) : s.push(p);
|
|
128
128
|
}
|
|
129
129
|
}
|
|
130
130
|
} catch (p) {
|
|
@@ -139,13 +139,13 @@ var P = function() {
|
|
|
139
139
|
}
|
|
140
140
|
}
|
|
141
141
|
if (s)
|
|
142
|
-
throw new
|
|
142
|
+
throw new j(s);
|
|
143
143
|
}
|
|
144
144
|
}, n.prototype.add = function(t) {
|
|
145
145
|
var e;
|
|
146
146
|
if (t && t !== this)
|
|
147
147
|
if (this.closed)
|
|
148
|
-
|
|
148
|
+
ie(t);
|
|
149
149
|
else {
|
|
150
150
|
if (t instanceof n) {
|
|
151
151
|
if (t.closed || t._hasParent(this))
|
|
@@ -170,47 +170,46 @@ var P = function() {
|
|
|
170
170
|
var t = new n();
|
|
171
171
|
return t.closed = !0, t;
|
|
172
172
|
}(), n;
|
|
173
|
-
}(),
|
|
174
|
-
function
|
|
175
|
-
return n instanceof
|
|
173
|
+
}(), be = R.EMPTY;
|
|
174
|
+
function me(n) {
|
|
175
|
+
return n instanceof R || n && "closed" in n && m(n.remove) && m(n.add) && m(n.unsubscribe);
|
|
176
176
|
}
|
|
177
|
-
function
|
|
177
|
+
function ie(n) {
|
|
178
178
|
m(n) ? n() : n.unsubscribe();
|
|
179
179
|
}
|
|
180
|
-
var
|
|
180
|
+
var we = {
|
|
181
181
|
onUnhandledError: null,
|
|
182
182
|
onStoppedNotification: null,
|
|
183
183
|
Promise: void 0,
|
|
184
184
|
useDeprecatedSynchronousErrorHandling: !1,
|
|
185
185
|
useDeprecatedNextContext: !1
|
|
186
|
-
},
|
|
186
|
+
}, Se = {
|
|
187
187
|
setTimeout: function(n, t) {
|
|
188
188
|
for (var e = [], r = 2; r < arguments.length; r++)
|
|
189
189
|
e[r - 2] = arguments[r];
|
|
190
|
-
|
|
191
|
-
return i != null && i.setTimeout ? i.setTimeout.apply(i, I([n, t], _(e))) : setTimeout.apply(void 0, I([n, t], _(e)));
|
|
190
|
+
return setTimeout.apply(void 0, $([n, t], L(e)));
|
|
192
191
|
},
|
|
193
192
|
clearTimeout: function(n) {
|
|
194
|
-
var t =
|
|
193
|
+
var t = Se.delegate;
|
|
195
194
|
return ((t == null ? void 0 : t.clearTimeout) || clearTimeout)(n);
|
|
196
195
|
},
|
|
197
196
|
delegate: void 0
|
|
198
197
|
};
|
|
199
|
-
function
|
|
200
|
-
|
|
198
|
+
function Ae(n) {
|
|
199
|
+
Se.setTimeout(function() {
|
|
201
200
|
throw n;
|
|
202
201
|
});
|
|
203
202
|
}
|
|
204
|
-
function
|
|
203
|
+
function se() {
|
|
205
204
|
}
|
|
206
|
-
function
|
|
205
|
+
function O(n) {
|
|
207
206
|
n();
|
|
208
207
|
}
|
|
209
|
-
var
|
|
208
|
+
var Z = function(n) {
|
|
210
209
|
M(t, n);
|
|
211
210
|
function t(e) {
|
|
212
211
|
var r = n.call(this) || this;
|
|
213
|
-
return r.isStopped = !1, e ? (r.destination = e,
|
|
212
|
+
return r.isStopped = !1, e ? (r.destination = e, me(e) && e.add(r)) : r.destination = Ue, r;
|
|
214
213
|
}
|
|
215
214
|
return t.create = function(e, r, i) {
|
|
216
215
|
return new F(e, r, i);
|
|
@@ -237,11 +236,11 @@ var ee = function(n) {
|
|
|
237
236
|
this.unsubscribe();
|
|
238
237
|
}
|
|
239
238
|
}, t;
|
|
240
|
-
}(
|
|
241
|
-
function
|
|
242
|
-
return
|
|
239
|
+
}(R), Oe = Function.prototype.bind;
|
|
240
|
+
function D(n, t) {
|
|
241
|
+
return Oe.call(n, t);
|
|
243
242
|
}
|
|
244
|
-
var
|
|
243
|
+
var Le = function() {
|
|
245
244
|
function n(t) {
|
|
246
245
|
this.partialObserver = t;
|
|
247
246
|
}
|
|
@@ -251,7 +250,7 @@ var $e = function() {
|
|
|
251
250
|
try {
|
|
252
251
|
e.next(t);
|
|
253
252
|
} catch (r) {
|
|
254
|
-
|
|
253
|
+
I(r);
|
|
255
254
|
}
|
|
256
255
|
}, n.prototype.error = function(t) {
|
|
257
256
|
var e = this.partialObserver;
|
|
@@ -259,17 +258,17 @@ var $e = function() {
|
|
|
259
258
|
try {
|
|
260
259
|
e.error(t);
|
|
261
260
|
} catch (r) {
|
|
262
|
-
|
|
261
|
+
I(r);
|
|
263
262
|
}
|
|
264
263
|
else
|
|
265
|
-
|
|
264
|
+
I(t);
|
|
266
265
|
}, n.prototype.complete = function() {
|
|
267
266
|
var t = this.partialObserver;
|
|
268
267
|
if (t.complete)
|
|
269
268
|
try {
|
|
270
269
|
t.complete();
|
|
271
270
|
} catch (e) {
|
|
272
|
-
|
|
271
|
+
I(e);
|
|
273
272
|
}
|
|
274
273
|
}, n;
|
|
275
274
|
}(), F = function(n) {
|
|
@@ -284,43 +283,43 @@ var $e = function() {
|
|
|
284
283
|
};
|
|
285
284
|
else {
|
|
286
285
|
var c;
|
|
287
|
-
s &&
|
|
286
|
+
s && we.useDeprecatedNextContext ? (c = Object.create(e), c.unsubscribe = function() {
|
|
288
287
|
return s.unsubscribe();
|
|
289
288
|
}, o = {
|
|
290
|
-
next: e.next &&
|
|
291
|
-
error: e.error &&
|
|
292
|
-
complete: e.complete &&
|
|
289
|
+
next: e.next && D(e.next, c),
|
|
290
|
+
error: e.error && D(e.error, c),
|
|
291
|
+
complete: e.complete && D(e.complete, c)
|
|
293
292
|
}) : o = e;
|
|
294
293
|
}
|
|
295
|
-
return s.destination = new
|
|
294
|
+
return s.destination = new Le(o), s;
|
|
296
295
|
}
|
|
297
296
|
return t;
|
|
298
|
-
}(
|
|
299
|
-
function
|
|
300
|
-
|
|
297
|
+
}(Z);
|
|
298
|
+
function I(n) {
|
|
299
|
+
Ae(n);
|
|
301
300
|
}
|
|
302
|
-
function
|
|
301
|
+
function $e(n) {
|
|
303
302
|
throw n;
|
|
304
303
|
}
|
|
305
|
-
var
|
|
304
|
+
var Ue = {
|
|
306
305
|
closed: !0,
|
|
307
|
-
next:
|
|
308
|
-
error:
|
|
309
|
-
complete:
|
|
310
|
-
},
|
|
306
|
+
next: se,
|
|
307
|
+
error: $e,
|
|
308
|
+
complete: se
|
|
309
|
+
}, Fe = function() {
|
|
311
310
|
return typeof Symbol == "function" && Symbol.observable || "@@observable";
|
|
312
311
|
}();
|
|
313
312
|
function Ee(n) {
|
|
314
313
|
return n;
|
|
315
314
|
}
|
|
316
|
-
function
|
|
315
|
+
function ke(n) {
|
|
317
316
|
return n.length === 0 ? Ee : n.length === 1 ? n[0] : function(e) {
|
|
318
317
|
return n.reduce(function(r, i) {
|
|
319
318
|
return i(r);
|
|
320
319
|
}, e);
|
|
321
320
|
};
|
|
322
321
|
}
|
|
323
|
-
var
|
|
322
|
+
var Q = function() {
|
|
324
323
|
function n(t) {
|
|
325
324
|
t && (this._subscribe = t);
|
|
326
325
|
}
|
|
@@ -328,8 +327,8 @@ var G = function() {
|
|
|
328
327
|
var e = new n();
|
|
329
328
|
return e.source = this, e.operator = t, e;
|
|
330
329
|
}, n.prototype.subscribe = function(t, e, r) {
|
|
331
|
-
var i = this, s =
|
|
332
|
-
return
|
|
330
|
+
var i = this, s = Ve(t) ? t : new F(t, e, r);
|
|
331
|
+
return O(function() {
|
|
333
332
|
var o = i, c = o.operator, a = o.source;
|
|
334
333
|
s.add(c ? c.call(s, a) : a ? i._subscribe(s) : i._trySubscribe(s));
|
|
335
334
|
}), s;
|
|
@@ -341,7 +340,7 @@ var G = function() {
|
|
|
341
340
|
}
|
|
342
341
|
}, n.prototype.forEach = function(t, e) {
|
|
343
342
|
var r = this;
|
|
344
|
-
return e =
|
|
343
|
+
return e = oe(e), new e(function(i, s) {
|
|
345
344
|
var o = new F({
|
|
346
345
|
next: function(c) {
|
|
347
346
|
try {
|
|
@@ -358,15 +357,15 @@ var G = function() {
|
|
|
358
357
|
}, n.prototype._subscribe = function(t) {
|
|
359
358
|
var e;
|
|
360
359
|
return (e = this.source) === null || e === void 0 ? void 0 : e.subscribe(t);
|
|
361
|
-
}, n.prototype[
|
|
360
|
+
}, n.prototype[Fe] = function() {
|
|
362
361
|
return this;
|
|
363
362
|
}, n.prototype.pipe = function() {
|
|
364
363
|
for (var t = [], e = 0; e < arguments.length; e++)
|
|
365
364
|
t[e] = arguments[e];
|
|
366
|
-
return
|
|
365
|
+
return ke(t)(this);
|
|
367
366
|
}, n.prototype.toPromise = function(t) {
|
|
368
367
|
var e = this;
|
|
369
|
-
return t =
|
|
368
|
+
return t = oe(t), new t(function(r, i) {
|
|
370
369
|
var s;
|
|
371
370
|
e.subscribe(function(o) {
|
|
372
371
|
return s = o;
|
|
@@ -380,22 +379,22 @@ var G = function() {
|
|
|
380
379
|
return new n(t);
|
|
381
380
|
}, n;
|
|
382
381
|
}();
|
|
383
|
-
function
|
|
382
|
+
function oe(n) {
|
|
384
383
|
var t;
|
|
385
|
-
return (t = n ??
|
|
384
|
+
return (t = n ?? we.Promise) !== null && t !== void 0 ? t : Promise;
|
|
386
385
|
}
|
|
387
|
-
function
|
|
386
|
+
function Ne(n) {
|
|
388
387
|
return n && m(n.next) && m(n.error) && m(n.complete);
|
|
389
388
|
}
|
|
390
|
-
function
|
|
391
|
-
return n && n instanceof
|
|
389
|
+
function Ve(n) {
|
|
390
|
+
return n && n instanceof Z || Ne(n) && me(n);
|
|
392
391
|
}
|
|
393
|
-
function
|
|
392
|
+
function je(n) {
|
|
394
393
|
return m(n == null ? void 0 : n.lift);
|
|
395
394
|
}
|
|
396
395
|
function Ce(n) {
|
|
397
396
|
return function(t) {
|
|
398
|
-
if (
|
|
397
|
+
if (je(t))
|
|
399
398
|
return t.lift(function(e) {
|
|
400
399
|
try {
|
|
401
400
|
return n(e, this);
|
|
@@ -407,9 +406,9 @@ function Ce(n) {
|
|
|
407
406
|
};
|
|
408
407
|
}
|
|
409
408
|
function Me(n, t, e, r, i) {
|
|
410
|
-
return new
|
|
409
|
+
return new De(n, t, e, r, i);
|
|
411
410
|
}
|
|
412
|
-
var
|
|
411
|
+
var De = function(n) {
|
|
413
412
|
M(t, n);
|
|
414
413
|
function t(e, r, i, s, o, c) {
|
|
415
414
|
var a = n.call(this, e) || this;
|
|
@@ -444,7 +443,7 @@ var qe = function(n) {
|
|
|
444
443
|
n.prototype.unsubscribe.call(this), !r && ((e = this.onFinalize) === null || e === void 0 || e.call(this));
|
|
445
444
|
}
|
|
446
445
|
}, t;
|
|
447
|
-
}(
|
|
446
|
+
}(Z), qe = X(function(n) {
|
|
448
447
|
return function() {
|
|
449
448
|
n(this), this.name = "ObjectUnsubscribedError", this.message = "object unsubscribed";
|
|
450
449
|
};
|
|
@@ -455,19 +454,19 @@ var qe = function(n) {
|
|
|
455
454
|
return e.closed = !1, e.currentObservers = null, e.observers = [], e.isStopped = !1, e.hasError = !1, e.thrownError = null, e;
|
|
456
455
|
}
|
|
457
456
|
return t.prototype.lift = function(e) {
|
|
458
|
-
var r = new
|
|
457
|
+
var r = new ae(this, this);
|
|
459
458
|
return r.operator = e, r;
|
|
460
459
|
}, t.prototype._throwIfClosed = function() {
|
|
461
460
|
if (this.closed)
|
|
462
|
-
throw new
|
|
461
|
+
throw new qe();
|
|
463
462
|
}, t.prototype.next = function(e) {
|
|
464
463
|
var r = this;
|
|
465
|
-
|
|
464
|
+
O(function() {
|
|
466
465
|
var i, s;
|
|
467
466
|
if (r._throwIfClosed(), !r.isStopped) {
|
|
468
467
|
r.currentObservers || (r.currentObservers = Array.from(r.observers));
|
|
469
468
|
try {
|
|
470
|
-
for (var o =
|
|
469
|
+
for (var o = z(r.currentObservers), c = o.next(); !c.done; c = o.next()) {
|
|
471
470
|
var a = c.value;
|
|
472
471
|
a.next(e);
|
|
473
472
|
}
|
|
@@ -485,7 +484,7 @@ var qe = function(n) {
|
|
|
485
484
|
});
|
|
486
485
|
}, t.prototype.error = function(e) {
|
|
487
486
|
var r = this;
|
|
488
|
-
|
|
487
|
+
O(function() {
|
|
489
488
|
if (r._throwIfClosed(), !r.isStopped) {
|
|
490
489
|
r.hasError = r.isStopped = !0, r.thrownError = e;
|
|
491
490
|
for (var i = r.observers; i.length; )
|
|
@@ -494,7 +493,7 @@ var qe = function(n) {
|
|
|
494
493
|
});
|
|
495
494
|
}, t.prototype.complete = function() {
|
|
496
495
|
var e = this;
|
|
497
|
-
|
|
496
|
+
O(function() {
|
|
498
497
|
if (e._throwIfClosed(), !e.isStopped) {
|
|
499
498
|
e.isStopped = !0;
|
|
500
499
|
for (var r = e.observers; r.length; )
|
|
@@ -516,19 +515,19 @@ var qe = function(n) {
|
|
|
516
515
|
return this._throwIfClosed(), this._checkFinalizedStatuses(e), this._innerSubscribe(e);
|
|
517
516
|
}, t.prototype._innerSubscribe = function(e) {
|
|
518
517
|
var r = this, i = this, s = i.hasError, o = i.isStopped, c = i.observers;
|
|
519
|
-
return s || o ?
|
|
518
|
+
return s || o ? be : (this.currentObservers = null, c.push(e), new R(function() {
|
|
520
519
|
r.currentObservers = null, U(c, e);
|
|
521
520
|
}));
|
|
522
521
|
}, t.prototype._checkFinalizedStatuses = function(e) {
|
|
523
522
|
var r = this, i = r.hasError, s = r.thrownError, o = r.isStopped;
|
|
524
523
|
i ? e.error(s) : o && e.complete();
|
|
525
524
|
}, t.prototype.asObservable = function() {
|
|
526
|
-
var e = new
|
|
525
|
+
var e = new Q();
|
|
527
526
|
return e.source = this, e;
|
|
528
527
|
}, t.create = function(e, r) {
|
|
529
|
-
return new
|
|
528
|
+
return new ae(e, r);
|
|
530
529
|
}, t;
|
|
531
|
-
}(
|
|
530
|
+
}(Q), ae = function(n) {
|
|
532
531
|
M(t, n);
|
|
533
532
|
function t(e, r) {
|
|
534
533
|
var i = n.call(this) || this;
|
|
@@ -545,11 +544,11 @@ var qe = function(n) {
|
|
|
545
544
|
(r = (e = this.destination) === null || e === void 0 ? void 0 : e.complete) === null || r === void 0 || r.call(e);
|
|
546
545
|
}, t.prototype._subscribe = function(e) {
|
|
547
546
|
var r, i;
|
|
548
|
-
return (i = (r = this.source) === null || r === void 0 ? void 0 : r.subscribe(e)) !== null && i !== void 0 ? i :
|
|
547
|
+
return (i = (r = this.source) === null || r === void 0 ? void 0 : r.subscribe(e)) !== null && i !== void 0 ? i : be;
|
|
549
548
|
}, t;
|
|
550
|
-
}(xe),
|
|
549
|
+
}(xe), Be = {
|
|
551
550
|
now: function() {
|
|
552
|
-
return
|
|
551
|
+
return Date.now();
|
|
553
552
|
},
|
|
554
553
|
delegate: void 0
|
|
555
554
|
}, He = function(n) {
|
|
@@ -560,15 +559,14 @@ var qe = function(n) {
|
|
|
560
559
|
return t.prototype.schedule = function(e, r) {
|
|
561
560
|
return this;
|
|
562
561
|
}, t;
|
|
563
|
-
}(
|
|
562
|
+
}(R), Y = {
|
|
564
563
|
setInterval: function(n, t) {
|
|
565
564
|
for (var e = [], r = 2; r < arguments.length; r++)
|
|
566
565
|
e[r - 2] = arguments[r];
|
|
567
|
-
|
|
568
|
-
return i != null && i.setInterval ? i.setInterval.apply(i, I([n, t], _(e))) : setInterval.apply(void 0, I([n, t], _(e)));
|
|
566
|
+
return setInterval.apply(void 0, $([n, t], L(e)));
|
|
569
567
|
},
|
|
570
568
|
clearInterval: function(n) {
|
|
571
|
-
var t =
|
|
569
|
+
var t = Y.delegate;
|
|
572
570
|
return ((t == null ? void 0 : t.clearInterval) || clearInterval)(n);
|
|
573
571
|
},
|
|
574
572
|
delegate: void 0
|
|
@@ -586,11 +584,11 @@ var qe = function(n) {
|
|
|
586
584
|
var s = this.id, o = this.scheduler;
|
|
587
585
|
return s != null && (this.id = this.recycleAsyncId(o, s, r)), this.pending = !0, this.delay = r, this.id = (i = this.id) !== null && i !== void 0 ? i : this.requestAsyncId(o, this.id, r), this;
|
|
588
586
|
}, t.prototype.requestAsyncId = function(e, r, i) {
|
|
589
|
-
return i === void 0 && (i = 0),
|
|
587
|
+
return i === void 0 && (i = 0), Y.setInterval(e.flush.bind(e, this), i);
|
|
590
588
|
}, t.prototype.recycleAsyncId = function(e, r, i) {
|
|
591
589
|
if (i === void 0 && (i = 0), i != null && this.delay === i && this.pending === !1)
|
|
592
590
|
return r;
|
|
593
|
-
r != null &&
|
|
591
|
+
r != null && Y.clearInterval(r);
|
|
594
592
|
}, t.prototype.execute = function(e, r) {
|
|
595
593
|
if (this.closed)
|
|
596
594
|
return new Error("executing a cancelled action");
|
|
@@ -614,17 +612,17 @@ var qe = function(n) {
|
|
|
614
612
|
this.work = this.state = this.scheduler = null, this.pending = !1, U(s, this), r != null && (this.id = this.recycleAsyncId(i, r, null)), this.delay = null, n.prototype.unsubscribe.call(this);
|
|
615
613
|
}
|
|
616
614
|
}, t;
|
|
617
|
-
}(He),
|
|
615
|
+
}(He), ce = function() {
|
|
618
616
|
function n(t, e) {
|
|
619
617
|
e === void 0 && (e = n.now), this.schedulerActionCtor = t, this.now = e;
|
|
620
618
|
}
|
|
621
619
|
return n.prototype.schedule = function(t, e, r) {
|
|
622
620
|
return e === void 0 && (e = 0), new this.schedulerActionCtor(this, t).schedule(r, e);
|
|
623
|
-
}, n.now =
|
|
621
|
+
}, n.now = Be.now, n;
|
|
624
622
|
}(), Qe = function(n) {
|
|
625
623
|
M(t, n);
|
|
626
624
|
function t(e, r) {
|
|
627
|
-
r === void 0 && (r =
|
|
625
|
+
r === void 0 && (r = ce.now);
|
|
628
626
|
var i = n.call(this, e, r) || this;
|
|
629
627
|
return i.actions = [], i._active = !1, i;
|
|
630
628
|
}
|
|
@@ -646,16 +644,16 @@ var qe = function(n) {
|
|
|
646
644
|
throw i;
|
|
647
645
|
}
|
|
648
646
|
}, t;
|
|
649
|
-
}(
|
|
647
|
+
}(ce), Ye = new Qe(ze), Ge = Ye;
|
|
650
648
|
function Je(n) {
|
|
651
649
|
return n && m(n.schedule);
|
|
652
650
|
}
|
|
653
|
-
var Ke =
|
|
651
|
+
var Ke = X(function(n) {
|
|
654
652
|
return function() {
|
|
655
653
|
n(this), this.name = "EmptyError", this.message = "no elements in sequence";
|
|
656
654
|
};
|
|
657
655
|
});
|
|
658
|
-
function
|
|
656
|
+
function T(n, t) {
|
|
659
657
|
var e = typeof t == "object";
|
|
660
658
|
return new Promise(function(r, i) {
|
|
661
659
|
var s = new F({
|
|
@@ -673,7 +671,7 @@ function R(n, t) {
|
|
|
673
671
|
function We(n) {
|
|
674
672
|
return n instanceof Date && !isNaN(n);
|
|
675
673
|
}
|
|
676
|
-
function
|
|
674
|
+
function P(n, t) {
|
|
677
675
|
return Ce(function(e, r) {
|
|
678
676
|
var i = 0;
|
|
679
677
|
e.subscribe(Me(r, function(s) {
|
|
@@ -684,7 +682,7 @@ function O(n, t) {
|
|
|
684
682
|
function Xe(n, t, e) {
|
|
685
683
|
n === void 0 && (n = 0), e === void 0 && (e = Ge);
|
|
686
684
|
var r = -1;
|
|
687
|
-
return t != null && (Je(t) ? e = t : r = t), new
|
|
685
|
+
return t != null && (Je(t) ? e = t : r = t), new Q(function(i) {
|
|
688
686
|
var s = We(n) ? +n - e.now() : n;
|
|
689
687
|
s < 0 && (s = 0);
|
|
690
688
|
var o = 0;
|
|
@@ -720,7 +718,7 @@ class l extends Error {
|
|
|
720
718
|
super(`Incorrect context (${t}). Cannot perform the requested operation.`), C(this, "context"), this.context = t;
|
|
721
719
|
}
|
|
722
720
|
}
|
|
723
|
-
class
|
|
721
|
+
class _ extends Error {
|
|
724
722
|
constructor(t, e, r) {
|
|
725
723
|
super(`Invalid parameter (${t}). ${r}`), this.param = t, this.value = e, this.reason = r;
|
|
726
724
|
}
|
|
@@ -737,12 +735,12 @@ class nt extends Error {
|
|
|
737
735
|
super(`Invalid version format: ${t}`);
|
|
738
736
|
}
|
|
739
737
|
}
|
|
740
|
-
class
|
|
738
|
+
class ue extends Error {
|
|
741
739
|
constructor(t) {
|
|
742
740
|
super(`${t} needs to be initialized before it can be used.`);
|
|
743
741
|
}
|
|
744
742
|
}
|
|
745
|
-
class
|
|
743
|
+
class le extends Error {
|
|
746
744
|
constructor(t, e) {
|
|
747
745
|
let r = `Unsupported Protocol ${Array.isArray(t) ? "versions" : "version"}: (${t}).`;
|
|
748
746
|
e && (r += ` Minimum version supported is ${e}.`), super(r), this.version = t;
|
|
@@ -754,7 +752,7 @@ function S(n) {
|
|
|
754
752
|
function it(n) {
|
|
755
753
|
return S(n == null ? void 0 : n.lift);
|
|
756
754
|
}
|
|
757
|
-
function
|
|
755
|
+
function k(n) {
|
|
758
756
|
return function(t) {
|
|
759
757
|
if (it(t))
|
|
760
758
|
return t.lift(function(e) {
|
|
@@ -767,24 +765,24 @@ function N(n) {
|
|
|
767
765
|
throw new TypeError("Unable to lift unknown Observable type");
|
|
768
766
|
};
|
|
769
767
|
}
|
|
770
|
-
var
|
|
771
|
-
return
|
|
768
|
+
var G = function(n, t) {
|
|
769
|
+
return G = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e, r) {
|
|
772
770
|
e.__proto__ = r;
|
|
773
771
|
} || function(e, r) {
|
|
774
772
|
for (var i in r)
|
|
775
773
|
Object.prototype.hasOwnProperty.call(r, i) && (e[i] = r[i]);
|
|
776
|
-
},
|
|
774
|
+
}, G(n, t);
|
|
777
775
|
};
|
|
778
|
-
function
|
|
776
|
+
function ee(n, t) {
|
|
779
777
|
if (typeof t != "function" && t !== null)
|
|
780
778
|
throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
|
|
781
|
-
|
|
779
|
+
G(n, t);
|
|
782
780
|
function e() {
|
|
783
781
|
this.constructor = n;
|
|
784
782
|
}
|
|
785
783
|
n.prototype = t === null ? Object.create(t) : (e.prototype = t.prototype, new e());
|
|
786
784
|
}
|
|
787
|
-
function
|
|
785
|
+
function he(n) {
|
|
788
786
|
var t = typeof Symbol == "function" && Symbol.iterator, e = t && n[t], r = 0;
|
|
789
787
|
if (e)
|
|
790
788
|
return e.call(n);
|
|
@@ -796,7 +794,7 @@ function de(n) {
|
|
|
796
794
|
};
|
|
797
795
|
throw new TypeError(t ? "Object is not iterable." : "Symbol.iterator is not defined.");
|
|
798
796
|
}
|
|
799
|
-
function
|
|
797
|
+
function J(n, t) {
|
|
800
798
|
var e = typeof Symbol == "function" && n[Symbol.iterator];
|
|
801
799
|
if (!e)
|
|
802
800
|
return n;
|
|
@@ -816,7 +814,7 @@ function K(n, t) {
|
|
|
816
814
|
}
|
|
817
815
|
return s;
|
|
818
816
|
}
|
|
819
|
-
function
|
|
817
|
+
function K(n, t, e) {
|
|
820
818
|
if (e || arguments.length === 2)
|
|
821
819
|
for (var r = 0, i = t.length, s; r < i; r++)
|
|
822
820
|
(s || !(r in t)) && (s || (s = Array.prototype.slice.call(t, 0, r)), s[r] = t[r]);
|
|
@@ -828,7 +826,7 @@ function st(n) {
|
|
|
828
826
|
}, e = n(t);
|
|
829
827
|
return e.prototype = Object.create(Error.prototype), e.prototype.constructor = e, e;
|
|
830
828
|
}
|
|
831
|
-
var
|
|
829
|
+
var q = st(function(n) {
|
|
832
830
|
return function(t) {
|
|
833
831
|
n(this), this.message = t ? t.length + ` errors occurred during unsubscription:
|
|
834
832
|
` + t.map(function(e, r) {
|
|
@@ -837,13 +835,13 @@ var B = st(function(n) {
|
|
|
837
835
|
`) : "", this.name = "UnsubscriptionError", this.errors = t;
|
|
838
836
|
};
|
|
839
837
|
});
|
|
840
|
-
function
|
|
838
|
+
function de(n, t) {
|
|
841
839
|
if (n) {
|
|
842
840
|
var e = n.indexOf(t);
|
|
843
841
|
0 <= e && n.splice(e, 1);
|
|
844
842
|
}
|
|
845
843
|
}
|
|
846
|
-
var
|
|
844
|
+
var te = function() {
|
|
847
845
|
function n(t) {
|
|
848
846
|
this.initialTeardown = t, this.closed = !1, this._parentage = null, this._finalizers = null;
|
|
849
847
|
}
|
|
@@ -855,7 +853,7 @@ var re = function() {
|
|
|
855
853
|
if (o)
|
|
856
854
|
if (this._parentage = null, Array.isArray(o))
|
|
857
855
|
try {
|
|
858
|
-
for (var c =
|
|
856
|
+
for (var c = he(o), a = c.next(); !a.done; a = c.next()) {
|
|
859
857
|
var u = a.value;
|
|
860
858
|
u.remove(this);
|
|
861
859
|
}
|
|
@@ -876,18 +874,18 @@ var re = function() {
|
|
|
876
874
|
try {
|
|
877
875
|
g();
|
|
878
876
|
} catch (p) {
|
|
879
|
-
s = p instanceof
|
|
877
|
+
s = p instanceof q ? p.errors : [p];
|
|
880
878
|
}
|
|
881
879
|
var v = this._finalizers;
|
|
882
880
|
if (v) {
|
|
883
881
|
this._finalizers = null;
|
|
884
882
|
try {
|
|
885
|
-
for (var E =
|
|
886
|
-
var
|
|
883
|
+
for (var E = he(v), w = E.next(); !w.done; w = E.next()) {
|
|
884
|
+
var V = w.value;
|
|
887
885
|
try {
|
|
888
|
-
|
|
886
|
+
pe(V);
|
|
889
887
|
} catch (p) {
|
|
890
|
-
s = s ?? [], p instanceof
|
|
888
|
+
s = s ?? [], p instanceof q ? s = K(K([], J(s)), J(p.errors)) : s.push(p);
|
|
891
889
|
}
|
|
892
890
|
}
|
|
893
891
|
} catch (p) {
|
|
@@ -902,13 +900,13 @@ var re = function() {
|
|
|
902
900
|
}
|
|
903
901
|
}
|
|
904
902
|
if (s)
|
|
905
|
-
throw new
|
|
903
|
+
throw new q(s);
|
|
906
904
|
}
|
|
907
905
|
}, n.prototype.add = function(t) {
|
|
908
906
|
var e;
|
|
909
907
|
if (t && t !== this)
|
|
910
908
|
if (this.closed)
|
|
911
|
-
|
|
909
|
+
pe(t);
|
|
912
910
|
else {
|
|
913
911
|
if (t instanceof n) {
|
|
914
912
|
if (t.closed || t._hasParent(this))
|
|
@@ -925,23 +923,23 @@ var re = function() {
|
|
|
925
923
|
this._parentage = Array.isArray(e) ? (e.push(t), e) : e ? [e, t] : t;
|
|
926
924
|
}, n.prototype._removeParent = function(t) {
|
|
927
925
|
var e = this._parentage;
|
|
928
|
-
e === t ? this._parentage = null : Array.isArray(e) &&
|
|
926
|
+
e === t ? this._parentage = null : Array.isArray(e) && de(e, t);
|
|
929
927
|
}, n.prototype.remove = function(t) {
|
|
930
928
|
var e = this._finalizers;
|
|
931
|
-
e &&
|
|
929
|
+
e && de(e, t), t instanceof n && t._removeParent(this);
|
|
932
930
|
}, n.EMPTY = function() {
|
|
933
931
|
var t = new n();
|
|
934
932
|
return t.closed = !0, t;
|
|
935
933
|
}(), n;
|
|
936
934
|
}();
|
|
937
|
-
|
|
935
|
+
te.EMPTY;
|
|
938
936
|
function _e(n) {
|
|
939
|
-
return n instanceof
|
|
937
|
+
return n instanceof te || n && "closed" in n && S(n.remove) && S(n.add) && S(n.unsubscribe);
|
|
940
938
|
}
|
|
941
|
-
function
|
|
939
|
+
function pe(n) {
|
|
942
940
|
S(n) ? n() : n.unsubscribe();
|
|
943
941
|
}
|
|
944
|
-
var
|
|
942
|
+
var Te = {
|
|
945
943
|
onUnhandledError: null,
|
|
946
944
|
onStoppedNotification: null,
|
|
947
945
|
Promise: void 0,
|
|
@@ -951,7 +949,7 @@ var Ie = {
|
|
|
951
949
|
setTimeout: function(n, t) {
|
|
952
950
|
for (var e = [], r = 2; r < arguments.length; r++)
|
|
953
951
|
e[r - 2] = arguments[r];
|
|
954
|
-
return setTimeout.apply(void 0,
|
|
952
|
+
return setTimeout.apply(void 0, K([n, t], J(e)));
|
|
955
953
|
},
|
|
956
954
|
clearTimeout: function(n) {
|
|
957
955
|
return clearTimeout(n);
|
|
@@ -963,19 +961,19 @@ function at(n) {
|
|
|
963
961
|
throw n;
|
|
964
962
|
});
|
|
965
963
|
}
|
|
966
|
-
function
|
|
964
|
+
function fe() {
|
|
967
965
|
}
|
|
968
966
|
function ct(n) {
|
|
969
967
|
n();
|
|
970
968
|
}
|
|
971
|
-
var
|
|
972
|
-
|
|
969
|
+
var re = function(n) {
|
|
970
|
+
ee(t, n);
|
|
973
971
|
function t(e) {
|
|
974
972
|
var r = n.call(this) || this;
|
|
975
973
|
return r.isStopped = !1, e ? (r.destination = e, _e(e) && e.add(r)) : r.destination = dt, r;
|
|
976
974
|
}
|
|
977
975
|
return t.create = function(e, r, i) {
|
|
978
|
-
return new
|
|
976
|
+
return new W(e, r, i);
|
|
979
977
|
}, t.prototype.next = function(e) {
|
|
980
978
|
this.isStopped || this._next(e);
|
|
981
979
|
}, t.prototype.error = function(e) {
|
|
@@ -999,8 +997,8 @@ var ne = function(n) {
|
|
|
999
997
|
this.unsubscribe();
|
|
1000
998
|
}
|
|
1001
999
|
}, t;
|
|
1002
|
-
}(
|
|
1003
|
-
function
|
|
1000
|
+
}(te), ut = Function.prototype.bind;
|
|
1001
|
+
function B(n, t) {
|
|
1004
1002
|
return ut.call(n, t);
|
|
1005
1003
|
}
|
|
1006
1004
|
var lt = function() {
|
|
@@ -1013,7 +1011,7 @@ var lt = function() {
|
|
|
1013
1011
|
try {
|
|
1014
1012
|
e.next(t);
|
|
1015
1013
|
} catch (r) {
|
|
1016
|
-
|
|
1014
|
+
A(r);
|
|
1017
1015
|
}
|
|
1018
1016
|
}, n.prototype.error = function(t) {
|
|
1019
1017
|
var e = this.partialObserver;
|
|
@@ -1021,21 +1019,21 @@ var lt = function() {
|
|
|
1021
1019
|
try {
|
|
1022
1020
|
e.error(t);
|
|
1023
1021
|
} catch (r) {
|
|
1024
|
-
|
|
1022
|
+
A(r);
|
|
1025
1023
|
}
|
|
1026
1024
|
else
|
|
1027
|
-
|
|
1025
|
+
A(t);
|
|
1028
1026
|
}, n.prototype.complete = function() {
|
|
1029
1027
|
var t = this.partialObserver;
|
|
1030
1028
|
if (t.complete)
|
|
1031
1029
|
try {
|
|
1032
1030
|
t.complete();
|
|
1033
1031
|
} catch (e) {
|
|
1034
|
-
|
|
1032
|
+
A(e);
|
|
1035
1033
|
}
|
|
1036
1034
|
}, n;
|
|
1037
|
-
}(),
|
|
1038
|
-
|
|
1035
|
+
}(), W = function(n) {
|
|
1036
|
+
ee(t, n);
|
|
1039
1037
|
function t(e, r, i) {
|
|
1040
1038
|
var s = n.call(this) || this, o;
|
|
1041
1039
|
if (S(e) || !e)
|
|
@@ -1046,19 +1044,19 @@ var lt = function() {
|
|
|
1046
1044
|
};
|
|
1047
1045
|
else {
|
|
1048
1046
|
var c;
|
|
1049
|
-
s &&
|
|
1047
|
+
s && Te.useDeprecatedNextContext ? (c = Object.create(e), c.unsubscribe = function() {
|
|
1050
1048
|
return s.unsubscribe();
|
|
1051
1049
|
}, o = {
|
|
1052
|
-
next: e.next &&
|
|
1053
|
-
error: e.error &&
|
|
1054
|
-
complete: e.complete &&
|
|
1050
|
+
next: e.next && B(e.next, c),
|
|
1051
|
+
error: e.error && B(e.error, c),
|
|
1052
|
+
complete: e.complete && B(e.complete, c)
|
|
1055
1053
|
}) : o = e;
|
|
1056
1054
|
}
|
|
1057
1055
|
return s.destination = new lt(o), s;
|
|
1058
1056
|
}
|
|
1059
1057
|
return t;
|
|
1060
|
-
}(
|
|
1061
|
-
function
|
|
1058
|
+
}(re);
|
|
1059
|
+
function A(n) {
|
|
1062
1060
|
at(n);
|
|
1063
1061
|
}
|
|
1064
1062
|
function ht(n) {
|
|
@@ -1066,9 +1064,9 @@ function ht(n) {
|
|
|
1066
1064
|
}
|
|
1067
1065
|
var dt = {
|
|
1068
1066
|
closed: !0,
|
|
1069
|
-
next:
|
|
1067
|
+
next: fe,
|
|
1070
1068
|
error: ht,
|
|
1071
|
-
complete:
|
|
1069
|
+
complete: fe
|
|
1072
1070
|
}, pt = function() {
|
|
1073
1071
|
return typeof Symbol == "function" && Symbol.observable || "@@observable";
|
|
1074
1072
|
}();
|
|
@@ -1090,7 +1088,7 @@ var gt = function() {
|
|
|
1090
1088
|
var e = new n();
|
|
1091
1089
|
return e.source = this, e.operator = t, e;
|
|
1092
1090
|
}, n.prototype.subscribe = function(t, e, r) {
|
|
1093
|
-
var i = this, s = yt(t) ? t : new
|
|
1091
|
+
var i = this, s = yt(t) ? t : new W(t, e, r);
|
|
1094
1092
|
return ct(function() {
|
|
1095
1093
|
var o = i, c = o.operator, a = o.source;
|
|
1096
1094
|
s.add(c ? c.call(s, a) : a ? i._subscribe(s) : i._trySubscribe(s));
|
|
@@ -1103,8 +1101,8 @@ var gt = function() {
|
|
|
1103
1101
|
}
|
|
1104
1102
|
}, n.prototype.forEach = function(t, e) {
|
|
1105
1103
|
var r = this;
|
|
1106
|
-
return e =
|
|
1107
|
-
var o = new
|
|
1104
|
+
return e = ge(e), new e(function(i, s) {
|
|
1105
|
+
var o = new W({
|
|
1108
1106
|
next: function(c) {
|
|
1109
1107
|
try {
|
|
1110
1108
|
t(c);
|
|
@@ -1128,7 +1126,7 @@ var gt = function() {
|
|
|
1128
1126
|
return ft(t)(this);
|
|
1129
1127
|
}, n.prototype.toPromise = function(t) {
|
|
1130
1128
|
var e = this;
|
|
1131
|
-
return t =
|
|
1129
|
+
return t = ge(t), new t(function(r, i) {
|
|
1132
1130
|
var s;
|
|
1133
1131
|
e.subscribe(function(o) {
|
|
1134
1132
|
return s = o;
|
|
@@ -1142,21 +1140,21 @@ var gt = function() {
|
|
|
1142
1140
|
return new n(t);
|
|
1143
1141
|
}, n;
|
|
1144
1142
|
}();
|
|
1145
|
-
function
|
|
1143
|
+
function ge(n) {
|
|
1146
1144
|
var t;
|
|
1147
|
-
return (t = n ??
|
|
1145
|
+
return (t = n ?? Te.Promise) !== null && t !== void 0 ? t : Promise;
|
|
1148
1146
|
}
|
|
1149
1147
|
function vt(n) {
|
|
1150
1148
|
return n && S(n.next) && S(n.error) && S(n.complete);
|
|
1151
1149
|
}
|
|
1152
1150
|
function yt(n) {
|
|
1153
|
-
return n && n instanceof
|
|
1151
|
+
return n && n instanceof re || vt(n) && _e(n);
|
|
1154
1152
|
}
|
|
1155
|
-
function
|
|
1153
|
+
function N(n, t, e, r, i) {
|
|
1156
1154
|
return new bt(n, t, e, r, i);
|
|
1157
1155
|
}
|
|
1158
1156
|
var bt = function(n) {
|
|
1159
|
-
|
|
1157
|
+
ee(t, n);
|
|
1160
1158
|
function t(e, r, i, s, o, c) {
|
|
1161
1159
|
var a = n.call(this, e) || this;
|
|
1162
1160
|
return a.onFinalize = o, a.shouldUnsubscribe = c, a._next = r ? function(u) {
|
|
@@ -1190,11 +1188,11 @@ var bt = function(n) {
|
|
|
1190
1188
|
n.prototype.unsubscribe.call(this), !r && ((e = this.onFinalize) === null || e === void 0 || e.call(this));
|
|
1191
1189
|
}
|
|
1192
1190
|
}, t;
|
|
1193
|
-
}(
|
|
1191
|
+
}(re);
|
|
1194
1192
|
function h(n, t) {
|
|
1195
|
-
return
|
|
1193
|
+
return k(function(e, r) {
|
|
1196
1194
|
var i = 0;
|
|
1197
|
-
e.subscribe(
|
|
1195
|
+
e.subscribe(N(r, function(s) {
|
|
1198
1196
|
r.next(n.call(t, s, i++));
|
|
1199
1197
|
}));
|
|
1200
1198
|
});
|
|
@@ -1205,28 +1203,28 @@ var mt = new gt(function(n) {
|
|
|
1205
1203
|
function y(n) {
|
|
1206
1204
|
return n <= 0 ? function() {
|
|
1207
1205
|
return mt;
|
|
1208
|
-
} :
|
|
1206
|
+
} : k(function(t, e) {
|
|
1209
1207
|
var r = 0;
|
|
1210
|
-
t.subscribe(
|
|
1208
|
+
t.subscribe(N(e, function(i) {
|
|
1211
1209
|
++r <= n && (e.next(i), n <= r && e.complete());
|
|
1212
1210
|
}));
|
|
1213
1211
|
});
|
|
1214
1212
|
}
|
|
1215
1213
|
function f(n, t) {
|
|
1216
|
-
return
|
|
1214
|
+
return k(function(e, r) {
|
|
1217
1215
|
var i = 0;
|
|
1218
|
-
e.subscribe(
|
|
1216
|
+
e.subscribe(N(r, function(s) {
|
|
1219
1217
|
return n.call(t, s, i++) && r.next(s);
|
|
1220
1218
|
}));
|
|
1221
1219
|
});
|
|
1222
1220
|
}
|
|
1223
1221
|
function d(n, t, e) {
|
|
1224
1222
|
var r = S(n) || t || e ? { next: n, error: t, complete: e } : n;
|
|
1225
|
-
return r ?
|
|
1223
|
+
return r ? k(function(i, s) {
|
|
1226
1224
|
var o;
|
|
1227
1225
|
(o = r.subscribe) === null || o === void 0 || o.call(r);
|
|
1228
1226
|
var c = !0;
|
|
1229
|
-
i.subscribe(
|
|
1227
|
+
i.subscribe(N(s, function(a) {
|
|
1230
1228
|
var u;
|
|
1231
1229
|
(u = r.next) === null || u === void 0 || u.call(r, a), s.next(a);
|
|
1232
1230
|
}, function() {
|
|
@@ -1250,21 +1248,21 @@ function St(n) {
|
|
|
1250
1248
|
}
|
|
1251
1249
|
throw new nt(n);
|
|
1252
1250
|
}
|
|
1253
|
-
function
|
|
1251
|
+
function ve(n) {
|
|
1254
1252
|
const t = St(n), [e, r] = t.split("."), [i, s] = [parseInt(e), parseInt(r)];
|
|
1255
1253
|
return [i, s];
|
|
1256
1254
|
}
|
|
1257
|
-
function
|
|
1258
|
-
const [e, r] =
|
|
1255
|
+
function ne(n, t) {
|
|
1256
|
+
const [e, r] = ve(n), [i, s] = ve(t);
|
|
1259
1257
|
return e < i ? -1 : e > i ? 1 : r < s ? -1 : r > s ? 1 : 0;
|
|
1260
1258
|
}
|
|
1261
1259
|
function Et(n, t) {
|
|
1262
|
-
return
|
|
1260
|
+
return ne(n, t) === 1;
|
|
1263
1261
|
}
|
|
1264
1262
|
function Ct(n, t) {
|
|
1265
|
-
return
|
|
1263
|
+
return ne(n, t) >= 0;
|
|
1266
1264
|
}
|
|
1267
|
-
const
|
|
1265
|
+
const ye = "2.0";
|
|
1268
1266
|
class Mt {
|
|
1269
1267
|
/**
|
|
1270
1268
|
* Create a new instance of the {@link IpcHelper | IPC Protocol Helper}.
|
|
@@ -1276,8 +1274,8 @@ class Mt {
|
|
|
1276
1274
|
* @param logService - An instance of a logging service or utility
|
|
1277
1275
|
*/
|
|
1278
1276
|
constructor(t, e) {
|
|
1279
|
-
if (C(this, "negotiatedProtocolVersion"), C(this, "currentContext"), C(this, "incomingMessages$"), C(this, "inIframe", !1), C(this, "embeddedResult"), C(this, "iframePort1"), C(this, "iframePort2"), this.supportedVersions = t, this.logService = e, this.incomingMessages$ = new xe(), this.supportedVersions = t.filter((r) => Ct(r,
|
|
1280
|
-
throw new
|
|
1277
|
+
if (C(this, "negotiatedProtocolVersion"), C(this, "currentContext"), C(this, "incomingMessages$"), C(this, "inIframe", !1), C(this, "embeddedResult"), C(this, "iframePort1"), C(this, "iframePort2"), this.supportedVersions = t, this.logService = e, this.incomingMessages$ = new xe(), this.supportedVersions = t.filter((r) => Ct(r, ye)), !this.supportedVersions.length)
|
|
1278
|
+
throw new le(t, ye);
|
|
1281
1279
|
this.negotiatedProtocolVersion = this.supportedVersions[0], this.embeddedResult = null, this.iframePort2 = null;
|
|
1282
1280
|
}
|
|
1283
1281
|
get parent() {
|
|
@@ -1299,11 +1297,11 @@ class Mt {
|
|
|
1299
1297
|
var t, e, r, i;
|
|
1300
1298
|
if (this.inIframe) {
|
|
1301
1299
|
if (!this.iframePort2)
|
|
1302
|
-
throw new
|
|
1300
|
+
throw new ue("port2");
|
|
1303
1301
|
return this.iframePort2;
|
|
1304
1302
|
} else {
|
|
1305
1303
|
if (!((e = (t = window.Acrobits) == null ? void 0 : t.messageChannel) != null && e.port2))
|
|
1306
|
-
throw new
|
|
1304
|
+
throw new ue("port2");
|
|
1307
1305
|
return (i = (r = window.Acrobits) == null ? void 0 : r.messageChannel) == null ? void 0 : i.port2;
|
|
1308
1306
|
}
|
|
1309
1307
|
}
|
|
@@ -1335,7 +1333,7 @@ class Mt {
|
|
|
1335
1333
|
d(this.logReceived(t)),
|
|
1336
1334
|
h((i) => {
|
|
1337
1335
|
if (this.supportedVersions.some((s) => Et(s, i.protocolVersion)))
|
|
1338
|
-
throw new
|
|
1336
|
+
throw new le(i.protocolVersion, this.supportedVersions[0]);
|
|
1339
1337
|
return i;
|
|
1340
1338
|
}),
|
|
1341
1339
|
d((i) => {
|
|
@@ -1627,13 +1625,13 @@ class Mt {
|
|
|
1627
1625
|
if (!this.isEmbedded())
|
|
1628
1626
|
throw new l(this.currentContext);
|
|
1629
1627
|
if (e === "group" && i === void 0)
|
|
1630
|
-
throw new
|
|
1628
|
+
throw new _(
|
|
1631
1629
|
"currentContacts",
|
|
1632
1630
|
i,
|
|
1633
1631
|
"currentContacts is required for group streams"
|
|
1634
1632
|
);
|
|
1635
1633
|
if (e === "direct" && i !== void 0)
|
|
1636
|
-
throw new
|
|
1634
|
+
throw new _(
|
|
1637
1635
|
"currentContacts",
|
|
1638
1636
|
i,
|
|
1639
1637
|
"currentContacts should not be passed for direct streams"
|
|
@@ -1666,7 +1664,7 @@ class Mt {
|
|
|
1666
1664
|
if (!this.isEmbedded())
|
|
1667
1665
|
throw new l(this.currentContext);
|
|
1668
1666
|
if (!t.length)
|
|
1669
|
-
throw new
|
|
1667
|
+
throw new _("contacts", t, "At least one contact is required");
|
|
1670
1668
|
const e = "MATCH CONTACTS", r = this.createMessage(e);
|
|
1671
1669
|
r.contacts = [...t], this.logCreated(e, r);
|
|
1672
1670
|
const i = this.incomingMessages$.pipe(
|
|
@@ -1936,7 +1934,7 @@ class Mt {
|
|
|
1936
1934
|
const s = "FILE TRANSFER", o = this.createMessage(s, !1);
|
|
1937
1935
|
if (o.mimeType = t.mimeType, o.fileName = t.fileName, o.fileSize = t.fileSize, o.fileHash = t.fileHash.toLowerCase(), o.dataType = t.dataType, o.data = t.data, o.intent = e, e === "attachment") {
|
|
1938
1936
|
if (!r)
|
|
1939
|
-
throw new
|
|
1937
|
+
throw new _(
|
|
1940
1938
|
"streamId",
|
|
1941
1939
|
r,
|
|
1942
1940
|
"streamId is required for attachment intent"
|
|
@@ -2019,7 +2017,7 @@ class Mt {
|
|
|
2019
2017
|
const s = "FILE SELECTION", o = this.createMessage(s);
|
|
2020
2018
|
if (o.intent = t, o.maxCount = r, o.mimeTypes = i, t === "attachment") {
|
|
2021
2019
|
if (!e)
|
|
2022
|
-
throw new
|
|
2020
|
+
throw new _(
|
|
2023
2021
|
"streamId",
|
|
2024
2022
|
e,
|
|
2025
2023
|
"streamId is required for attachment intent"
|
|
@@ -2198,7 +2196,7 @@ class Mt {
|
|
|
2198
2196
|
* version.
|
|
2199
2197
|
*/
|
|
2200
2198
|
compareVersion(t) {
|
|
2201
|
-
return
|
|
2199
|
+
return ne(this.negotiatedProtocolVersion, t);
|
|
2202
2200
|
}
|
|
2203
2201
|
logReceived(t, e) {
|
|
2204
2202
|
t === "FILE TRANSFER" && e != null && e.data && (e = { ...e, data: "..." });
|
|
@@ -2245,7 +2243,7 @@ class Mt {
|
|
|
2245
2243
|
}
|
|
2246
2244
|
}
|
|
2247
2245
|
const xt = ["2.0"];
|
|
2248
|
-
class
|
|
2246
|
+
class Tt {
|
|
2249
2247
|
/**
|
|
2250
2248
|
* A class that manages the IPC communication between the `Client` and the `Host`.
|
|
2251
2249
|
*
|
|
@@ -2295,7 +2293,7 @@ class _t {
|
|
|
2295
2293
|
* @returns A promise with {@link IPCContext} the app is running under.
|
|
2296
2294
|
*/
|
|
2297
2295
|
async determineContext() {
|
|
2298
|
-
const t = await
|
|
2296
|
+
const t = await T(this.helper.determineContext(), {
|
|
2299
2297
|
defaultValue: "guest"
|
|
2300
2298
|
});
|
|
2301
2299
|
return this.evaluateContext(t);
|
|
@@ -2304,7 +2302,7 @@ class _t {
|
|
|
2304
2302
|
* Initiates the IPC handshake with the `Host` app.
|
|
2305
2303
|
*/
|
|
2306
2304
|
initiateConnection() {
|
|
2307
|
-
return
|
|
2305
|
+
return T(
|
|
2308
2306
|
this.helper.openBridge().pipe(
|
|
2309
2307
|
Ze((t) => {
|
|
2310
2308
|
this.helper.onBadgeQueryMessage().subscribe((e) => {
|
|
@@ -2324,7 +2322,7 @@ class _t {
|
|
|
2324
2322
|
i(e.pushToken, e.appId, e.selector);
|
|
2325
2323
|
}), this.cloudId = t.cloudId, this.host = t.host;
|
|
2326
2324
|
}),
|
|
2327
|
-
|
|
2325
|
+
P(() => {
|
|
2328
2326
|
})
|
|
2329
2327
|
)
|
|
2330
2328
|
);
|
|
@@ -2334,7 +2332,7 @@ class _t {
|
|
|
2334
2332
|
let s;
|
|
2335
2333
|
if (e === "multi") {
|
|
2336
2334
|
if (!r || !Array.isArray(r))
|
|
2337
|
-
throw new
|
|
2335
|
+
throw new _(
|
|
2338
2336
|
"currentContacts",
|
|
2339
2337
|
r,
|
|
2340
2338
|
"currentContacts is required for group streams"
|
|
@@ -2347,7 +2345,7 @@ class _t {
|
|
|
2347
2345
|
);
|
|
2348
2346
|
} else
|
|
2349
2347
|
r ? i = r : i = "cloudUsername", s = this.helper.selectContacts(t.toString(), "direct", i);
|
|
2350
|
-
return
|
|
2348
|
+
return T(s.pipe(P((o) => o.contacts)));
|
|
2351
2349
|
}
|
|
2352
2350
|
/**
|
|
2353
2351
|
* Matches batch of {@link ContactItem} objects against the Host's contact list to fetch detailed
|
|
@@ -2359,7 +2357,7 @@ class _t {
|
|
|
2359
2357
|
* Host's contact list.
|
|
2360
2358
|
*/
|
|
2361
2359
|
matchContacts(t) {
|
|
2362
|
-
return this.logger.debug("Match Contacts: ", t),
|
|
2360
|
+
return this.logger.debug("Match Contacts: ", t), T(this.helper.matchContacts(t).pipe(P((e) => e.contacts)));
|
|
2363
2361
|
}
|
|
2364
2362
|
/**
|
|
2365
2363
|
* Requests the `Host` app to provide the Push Token for the current device.
|
|
@@ -2367,7 +2365,7 @@ class _t {
|
|
|
2367
2365
|
* @returns A promise with the Push Token as `string`.
|
|
2368
2366
|
*/
|
|
2369
2367
|
requestPushToken() {
|
|
2370
|
-
return this.logger.debug("Requesting Push Token"),
|
|
2368
|
+
return this.logger.debug("Requesting Push Token"), T(this.helper.requestPushToken().pipe(P((t) => t.pushToken)));
|
|
2371
2369
|
}
|
|
2372
2370
|
/**
|
|
2373
2371
|
* Sends the current badge count to the `Host` app.
|
|
@@ -2388,6 +2386,18 @@ class _t {
|
|
|
2388
2386
|
requestAppReset() {
|
|
2389
2387
|
this.logger.debug("Requesting App Reset"), this.helper.sendAppResetMessage();
|
|
2390
2388
|
}
|
|
2389
|
+
/**
|
|
2390
|
+
* Requests the `Host` app to open the given URL in an external browser.
|
|
2391
|
+
*
|
|
2392
|
+
* @remarks
|
|
2393
|
+
* Any additional data to be posted alongside the URL is included with the `data` parameter.
|
|
2394
|
+
*
|
|
2395
|
+
* @param url - URL to open in the external browser
|
|
2396
|
+
* @param data - _Optional_. Any additional data to be sent along with the URL
|
|
2397
|
+
*/
|
|
2398
|
+
openUrl(t, e) {
|
|
2399
|
+
this.logger.debug("Opening URL: ", t), this.helper.openUrl(t, e);
|
|
2400
|
+
}
|
|
2391
2401
|
/**
|
|
2392
2402
|
* Registers a callback to be invoked when a {@link IPCEvents.BadgeQuery} is received.
|
|
2393
2403
|
*
|
|
@@ -2448,5 +2458,5 @@ class _t {
|
|
|
2448
2458
|
}
|
|
2449
2459
|
export {
|
|
2450
2460
|
b as IPCEvents,
|
|
2451
|
-
|
|
2461
|
+
Tt as IPCManager
|
|
2452
2462
|
};
|