@avaturn-live/web-sdk 0.3.1 → 0.3.3
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/dist/main.cjs +16 -16
- package/dist/main.js +320 -321
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -115,8 +115,8 @@ function re(t, e) {
|
|
|
115
115
|
if (Object(i) !== i) return;
|
|
116
116
|
h = !1;
|
|
117
117
|
} else for (; !(h = (s = c.call(i)).done) && (f.push(s.value), f.length !== r); h = !0) ;
|
|
118
|
-
} catch (
|
|
119
|
-
v = !0, a =
|
|
118
|
+
} catch (E) {
|
|
119
|
+
v = !0, a = E;
|
|
120
120
|
} finally {
|
|
121
121
|
try {
|
|
122
122
|
if (!h && i.return != null && (l = i.return(), Object(l) !== l)) return;
|
|
@@ -143,8 +143,8 @@ function Ua(t) {
|
|
|
143
143
|
var pi, Jt = { exports: {} }, ir = function() {
|
|
144
144
|
if (pi) return Jt.exports;
|
|
145
145
|
pi = 1;
|
|
146
|
-
var t, e = typeof Reflect == "object" ? Reflect : null, n = e && typeof e.apply == "function" ? e.apply : function(m,
|
|
147
|
-
return Function.prototype.apply.call(m,
|
|
146
|
+
var t, e = typeof Reflect == "object" ? Reflect : null, n = e && typeof e.apply == "function" ? e.apply : function(m, y, w) {
|
|
147
|
+
return Function.prototype.apply.call(m, y, w);
|
|
148
148
|
};
|
|
149
149
|
t = e && typeof e.ownKeys == "function" ? e.ownKeys : Object.getOwnPropertySymbols ? function(m) {
|
|
150
150
|
return Object.getOwnPropertyNames(m).concat(Object.getOwnPropertySymbols(m));
|
|
@@ -157,16 +157,16 @@ var pi, Jt = { exports: {} }, ir = function() {
|
|
|
157
157
|
function i() {
|
|
158
158
|
i.init.call(this);
|
|
159
159
|
}
|
|
160
|
-
Jt.exports = i, Jt.exports.once = function(m,
|
|
160
|
+
Jt.exports = i, Jt.exports.once = function(m, y) {
|
|
161
161
|
return new Promise(function(w, C) {
|
|
162
162
|
function A(x) {
|
|
163
|
-
m.removeListener(
|
|
163
|
+
m.removeListener(y, j), C(x);
|
|
164
164
|
}
|
|
165
165
|
function j() {
|
|
166
166
|
typeof m.removeListener == "function" && m.removeListener("error", A), w([].slice.call(arguments));
|
|
167
167
|
}
|
|
168
|
-
|
|
169
|
-
typeof x.on == "function" &&
|
|
168
|
+
b(m, y, j, { once: !0 }), y !== "error" && function(x, R, J) {
|
|
169
|
+
typeof x.on == "function" && b(x, "error", R, J);
|
|
170
170
|
}(m, A, { once: !0 });
|
|
171
171
|
});
|
|
172
172
|
}, i.EventEmitter = i, i.prototype._events = void 0, i.prototype._eventsCount = 0, i.prototype._maxListeners = void 0;
|
|
@@ -177,51 +177,51 @@ var pi, Jt = { exports: {} }, ir = function() {
|
|
|
177
177
|
function c(m) {
|
|
178
178
|
return m._maxListeners === void 0 ? i.defaultMaxListeners : m._maxListeners;
|
|
179
179
|
}
|
|
180
|
-
function l(m,
|
|
180
|
+
function l(m, y, w, C) {
|
|
181
181
|
var A, j, x, R;
|
|
182
|
-
if (a(w), (j = m._events) === void 0 ? (j = m._events = /* @__PURE__ */ Object.create(null), m._eventsCount = 0) : (j.newListener !== void 0 && (m.emit("newListener",
|
|
183
|
-
else if (typeof x == "function" ? x = j[
|
|
182
|
+
if (a(w), (j = m._events) === void 0 ? (j = m._events = /* @__PURE__ */ Object.create(null), m._eventsCount = 0) : (j.newListener !== void 0 && (m.emit("newListener", y, w.listener ? w.listener : w), j = m._events), x = j[y]), x === void 0) x = j[y] = w, ++m._eventsCount;
|
|
183
|
+
else if (typeof x == "function" ? x = j[y] = C ? [w, x] : [x, w] : C ? x.unshift(w) : x.push(w), (A = c(m)) > 0 && x.length > A && !x.warned) {
|
|
184
184
|
x.warned = !0;
|
|
185
|
-
var J = new Error("Possible EventEmitter memory leak detected. " + x.length + " " + String(
|
|
186
|
-
J.name = "MaxListenersExceededWarning", J.emitter = m, J.type =
|
|
185
|
+
var J = new Error("Possible EventEmitter memory leak detected. " + x.length + " " + String(y) + " listeners added. Use emitter.setMaxListeners() to increase limit");
|
|
186
|
+
J.name = "MaxListenersExceededWarning", J.emitter = m, J.type = y, J.count = x.length, R = J, console && console.warn && console.warn(R);
|
|
187
187
|
}
|
|
188
188
|
return m;
|
|
189
189
|
}
|
|
190
190
|
function f() {
|
|
191
191
|
if (!this.fired) return this.target.removeListener(this.type, this.wrapFn), this.fired = !0, arguments.length === 0 ? this.listener.call(this.target) : this.listener.apply(this.target, arguments);
|
|
192
192
|
}
|
|
193
|
-
function h(m,
|
|
194
|
-
var C = { fired: !1, wrapFn: void 0, target: m, type:
|
|
193
|
+
function h(m, y, w) {
|
|
194
|
+
var C = { fired: !1, wrapFn: void 0, target: m, type: y, listener: w }, A = f.bind(C);
|
|
195
195
|
return A.listener = w, C.wrapFn = A, A;
|
|
196
196
|
}
|
|
197
|
-
function v(m,
|
|
197
|
+
function v(m, y, w) {
|
|
198
198
|
var C = m._events;
|
|
199
199
|
if (C === void 0) return [];
|
|
200
|
-
var A = C[
|
|
200
|
+
var A = C[y];
|
|
201
201
|
return A === void 0 ? [] : typeof A == "function" ? w ? [A.listener || A] : [A] : w ? function(j) {
|
|
202
202
|
for (var x = new Array(j.length), R = 0; R < x.length; ++R) x[R] = j[R].listener || j[R];
|
|
203
203
|
return x;
|
|
204
|
-
}(A) :
|
|
204
|
+
}(A) : k(A, A.length);
|
|
205
205
|
}
|
|
206
|
-
function
|
|
207
|
-
var
|
|
208
|
-
if (
|
|
209
|
-
var w =
|
|
206
|
+
function E(m) {
|
|
207
|
+
var y = this._events;
|
|
208
|
+
if (y !== void 0) {
|
|
209
|
+
var w = y[m];
|
|
210
210
|
if (typeof w == "function") return 1;
|
|
211
211
|
if (w !== void 0) return w.length;
|
|
212
212
|
}
|
|
213
213
|
return 0;
|
|
214
214
|
}
|
|
215
|
-
function
|
|
216
|
-
for (var w = new Array(
|
|
215
|
+
function k(m, y) {
|
|
216
|
+
for (var w = new Array(y), C = 0; C < y; ++C) w[C] = m[C];
|
|
217
217
|
return w;
|
|
218
218
|
}
|
|
219
|
-
function
|
|
220
|
-
if (typeof m.on == "function") C.once ? m.once(
|
|
219
|
+
function b(m, y, w, C) {
|
|
220
|
+
if (typeof m.on == "function") C.once ? m.once(y, w) : m.on(y, w);
|
|
221
221
|
else {
|
|
222
222
|
if (typeof m.addEventListener != "function") throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type ' + typeof m);
|
|
223
|
-
m.addEventListener(
|
|
224
|
-
C.once && m.removeEventListener(
|
|
223
|
+
m.addEventListener(y, function A(j) {
|
|
224
|
+
C.once && m.removeEventListener(y, A), w(j);
|
|
225
225
|
});
|
|
226
226
|
}
|
|
227
227
|
}
|
|
@@ -238,39 +238,39 @@ var pi, Jt = { exports: {} }, ir = function() {
|
|
|
238
238
|
}, i.prototype.getMaxListeners = function() {
|
|
239
239
|
return c(this);
|
|
240
240
|
}, i.prototype.emit = function(m) {
|
|
241
|
-
for (var
|
|
241
|
+
for (var y = [], w = 1; w < arguments.length; w++) y.push(arguments[w]);
|
|
242
242
|
var C = m === "error", A = this._events;
|
|
243
243
|
if (A !== void 0) C = C && A.error === void 0;
|
|
244
244
|
else if (!C) return !1;
|
|
245
245
|
if (C) {
|
|
246
246
|
var j;
|
|
247
|
-
if (
|
|
247
|
+
if (y.length > 0 && (j = y[0]), j instanceof Error) throw j;
|
|
248
248
|
var x = new Error("Unhandled error." + (j ? " (" + j.message + ")" : ""));
|
|
249
249
|
throw x.context = j, x;
|
|
250
250
|
}
|
|
251
251
|
var R = A[m];
|
|
252
252
|
if (R === void 0) return !1;
|
|
253
|
-
if (typeof R == "function") n(R, this,
|
|
253
|
+
if (typeof R == "function") n(R, this, y);
|
|
254
254
|
else {
|
|
255
|
-
var J = R.length, X =
|
|
256
|
-
for (w = 0; w < J; ++w) n(X[w], this,
|
|
255
|
+
var J = R.length, X = k(R, J);
|
|
256
|
+
for (w = 0; w < J; ++w) n(X[w], this, y);
|
|
257
257
|
}
|
|
258
258
|
return !0;
|
|
259
|
-
}, i.prototype.addListener = function(m,
|
|
260
|
-
return l(this, m,
|
|
261
|
-
}, i.prototype.on = i.prototype.addListener, i.prototype.prependListener = function(m,
|
|
262
|
-
return l(this, m,
|
|
263
|
-
}, i.prototype.once = function(m,
|
|
264
|
-
return a(
|
|
265
|
-
}, i.prototype.prependOnceListener = function(m,
|
|
266
|
-
return a(
|
|
267
|
-
}, i.prototype.removeListener = function(m,
|
|
259
|
+
}, i.prototype.addListener = function(m, y) {
|
|
260
|
+
return l(this, m, y, !1);
|
|
261
|
+
}, i.prototype.on = i.prototype.addListener, i.prototype.prependListener = function(m, y) {
|
|
262
|
+
return l(this, m, y, !0);
|
|
263
|
+
}, i.prototype.once = function(m, y) {
|
|
264
|
+
return a(y), this.on(m, h(this, m, y)), this;
|
|
265
|
+
}, i.prototype.prependOnceListener = function(m, y) {
|
|
266
|
+
return a(y), this.prependListener(m, h(this, m, y)), this;
|
|
267
|
+
}, i.prototype.removeListener = function(m, y) {
|
|
268
268
|
var w, C, A, j, x;
|
|
269
|
-
if (a(
|
|
269
|
+
if (a(y), (C = this._events) === void 0) return this;
|
|
270
270
|
if ((w = C[m]) === void 0) return this;
|
|
271
|
-
if (w ===
|
|
271
|
+
if (w === y || w.listener === y) --this._eventsCount == 0 ? this._events = /* @__PURE__ */ Object.create(null) : (delete C[m], C.removeListener && this.emit("removeListener", m, w.listener || y));
|
|
272
272
|
else if (typeof w != "function") {
|
|
273
|
-
for (A = -1, j = w.length - 1; j >= 0; j--) if (w[j] ===
|
|
273
|
+
for (A = -1, j = w.length - 1; j >= 0; j--) if (w[j] === y || w[j].listener === y) {
|
|
274
274
|
x = w[j].listener, A = j;
|
|
275
275
|
break;
|
|
276
276
|
}
|
|
@@ -278,11 +278,11 @@ var pi, Jt = { exports: {} }, ir = function() {
|
|
|
278
278
|
A === 0 ? w.shift() : function(R, J) {
|
|
279
279
|
for (; J + 1 < R.length; J++) R[J] = R[J + 1];
|
|
280
280
|
R.pop();
|
|
281
|
-
}(w, A), w.length === 1 && (C[m] = w[0]), C.removeListener !== void 0 && this.emit("removeListener", m, x ||
|
|
281
|
+
}(w, A), w.length === 1 && (C[m] = w[0]), C.removeListener !== void 0 && this.emit("removeListener", m, x || y);
|
|
282
282
|
}
|
|
283
283
|
return this;
|
|
284
284
|
}, i.prototype.off = i.prototype.removeListener, i.prototype.removeAllListeners = function(m) {
|
|
285
|
-
var
|
|
285
|
+
var y, w, C;
|
|
286
286
|
if ((w = this._events) === void 0) return this;
|
|
287
287
|
if (w.removeListener === void 0) return arguments.length === 0 ? (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0) : w[m] !== void 0 && (--this._eventsCount == 0 ? this._events = /* @__PURE__ */ Object.create(null) : delete w[m]), this;
|
|
288
288
|
if (arguments.length === 0) {
|
|
@@ -290,16 +290,16 @@ var pi, Jt = { exports: {} }, ir = function() {
|
|
|
290
290
|
for (C = 0; C < j.length; ++C) (A = j[C]) !== "removeListener" && this.removeAllListeners(A);
|
|
291
291
|
return this.removeAllListeners("removeListener"), this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0, this;
|
|
292
292
|
}
|
|
293
|
-
if (typeof (
|
|
294
|
-
else if (
|
|
293
|
+
if (typeof (y = w[m]) == "function") this.removeListener(m, y);
|
|
294
|
+
else if (y !== void 0) for (C = y.length - 1; C >= 0; C--) this.removeListener(m, y[C]);
|
|
295
295
|
return this;
|
|
296
296
|
}, i.prototype.listeners = function(m) {
|
|
297
297
|
return v(this, m, !0);
|
|
298
298
|
}, i.prototype.rawListeners = function(m) {
|
|
299
299
|
return v(this, m, !1);
|
|
300
|
-
}, i.listenerCount = function(m,
|
|
301
|
-
return typeof m.listenerCount == "function" ? m.listenerCount(
|
|
302
|
-
}, i.prototype.listenerCount =
|
|
300
|
+
}, i.listenerCount = function(m, y) {
|
|
301
|
+
return typeof m.listenerCount == "function" ? m.listenerCount(y) : E.call(m, y);
|
|
302
|
+
}, i.prototype.listenerCount = E, i.prototype.eventNames = function() {
|
|
303
303
|
return this._eventsCount > 0 ? t(this._events) : [];
|
|
304
304
|
}, Jt.exports;
|
|
305
305
|
}(), qt = Ua(ir), mi = Object.prototype.hasOwnProperty;
|
|
@@ -424,7 +424,7 @@ class T {
|
|
|
424
424
|
let a = Math.max(i, s), c = 0;
|
|
425
425
|
const l = T.map([e, n], (f) => {
|
|
426
426
|
const h = a - T.getVersionPrecision(f), v = f + new Array(h + 1).join(".0");
|
|
427
|
-
return T.map(v.split("."), (
|
|
427
|
+
return T.map(v.split("."), (E) => new Array(20 - E.length).join("0") + E).reverse();
|
|
428
428
|
});
|
|
429
429
|
for (r && (c = a - Math.min(i, s)), a -= 1; a >= c; ) {
|
|
430
430
|
if (l[0][a] > l[1][a]) return 1;
|
|
@@ -1612,14 +1612,14 @@ function ac(t) {
|
|
|
1612
1612
|
if (a) return a;
|
|
1613
1613
|
const c = Po(t.spanContext().traceId, e), l = Jr(n), f = l.data || {}, h = f["sentry.sample_rate"];
|
|
1614
1614
|
h != null && (c.sample_rate = `${h}`);
|
|
1615
|
-
const v = f["sentry.source"],
|
|
1616
|
-
return v !== "url" &&
|
|
1615
|
+
const v = f["sentry.source"], E = l.description;
|
|
1616
|
+
return v !== "url" && E && (c.transaction = E), function(k) {
|
|
1617
1617
|
if (typeof __SENTRY_TRACING__ == "boolean" && !__SENTRY_TRACING__) return !1;
|
|
1618
|
-
const
|
|
1618
|
+
const b = te(), m = b && b.getOptions();
|
|
1619
1619
|
return !!m && (m.enableTracing || "tracesSampleRate" in m || "tracesSampler" in m);
|
|
1620
|
-
}() && (c.sampled = String(function(
|
|
1621
|
-
const { traceFlags:
|
|
1622
|
-
return
|
|
1620
|
+
}() && (c.sampled = String(function(k) {
|
|
1621
|
+
const { traceFlags: b } = k.spanContext();
|
|
1622
|
+
return b === 1;
|
|
1623
1623
|
}(n))), e.emit("createDsc", c, n), c;
|
|
1624
1624
|
}
|
|
1625
1625
|
const cc = /^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;
|
|
@@ -1638,10 +1638,10 @@ function lc(t) {
|
|
|
1638
1638
|
});
|
|
1639
1639
|
const [i, s, a = "", c = "", l = "", f = ""] = r.slice(1);
|
|
1640
1640
|
let h = "", v = f;
|
|
1641
|
-
const
|
|
1642
|
-
if (
|
|
1643
|
-
const
|
|
1644
|
-
|
|
1641
|
+
const E = v.split("/");
|
|
1642
|
+
if (E.length > 1 && (h = E.slice(0, -1).join("/"), v = E.pop()), v) {
|
|
1643
|
+
const k = v.match(/^\d+/);
|
|
1644
|
+
k && (v = k[0]);
|
|
1645
1645
|
}
|
|
1646
1646
|
return Di({ host: c, pass: a, path: h, projectId: v, port: l, protocol: i, publicKey: s });
|
|
1647
1647
|
}(t) : Di(t);
|
|
@@ -1683,26 +1683,26 @@ function dr(t, e, n = 1 / 0, r = 1 / 0, i = /* @__PURE__ */ function() {
|
|
|
1683
1683
|
}()) {
|
|
1684
1684
|
const [s, a] = i;
|
|
1685
1685
|
if (e == null || ["boolean", "string"].includes(typeof e) || typeof e == "number" && Number.isFinite(e)) return e;
|
|
1686
|
-
const c = function(
|
|
1686
|
+
const c = function(k, b) {
|
|
1687
1687
|
try {
|
|
1688
|
-
if (
|
|
1689
|
-
if (
|
|
1690
|
-
if (typeof global < "u" &&
|
|
1691
|
-
if (typeof window < "u" &&
|
|
1692
|
-
if (typeof document < "u" &&
|
|
1693
|
-
if (Eo(
|
|
1694
|
-
if (ft(m =
|
|
1695
|
-
if (typeof
|
|
1696
|
-
if (typeof
|
|
1697
|
-
if (typeof
|
|
1698
|
-
if (typeof
|
|
1699
|
-
const
|
|
1688
|
+
if (k === "domain" && b && typeof b == "object" && b._events) return "[Domain]";
|
|
1689
|
+
if (k === "domainEmitter") return "[DomainEmitter]";
|
|
1690
|
+
if (typeof global < "u" && b === global) return "[Global]";
|
|
1691
|
+
if (typeof window < "u" && b === window) return "[Window]";
|
|
1692
|
+
if (typeof document < "u" && b === document) return "[Document]";
|
|
1693
|
+
if (Eo(b)) return "[VueViewModel]";
|
|
1694
|
+
if (ft(m = b) && "nativeEvent" in m && "preventDefault" in m && "stopPropagation" in m) return "[SyntheticEvent]";
|
|
1695
|
+
if (typeof b == "number" && !Number.isFinite(b)) return `[${b}]`;
|
|
1696
|
+
if (typeof b == "function") return `[Function: ${Fe(b)}]`;
|
|
1697
|
+
if (typeof b == "symbol") return `[${String(b)}]`;
|
|
1698
|
+
if (typeof b == "bigint") return `[BigInt: ${String(b)}]`;
|
|
1699
|
+
const y = function(w) {
|
|
1700
1700
|
const C = Object.getPrototypeOf(w);
|
|
1701
1701
|
return C ? C.constructor.name : "null prototype";
|
|
1702
|
-
}(
|
|
1703
|
-
return /^HTML(\w*)Element$/.test(
|
|
1704
|
-
} catch (
|
|
1705
|
-
return `**non-serializable** (${
|
|
1702
|
+
}(b);
|
|
1703
|
+
return /^HTML(\w*)Element$/.test(y) ? `[HTMLElement: ${y}]` : `[object ${y}]`;
|
|
1704
|
+
} catch (y) {
|
|
1705
|
+
return `**non-serializable** (${y})`;
|
|
1706
1706
|
}
|
|
1707
1707
|
var m;
|
|
1708
1708
|
}(t, e);
|
|
@@ -1718,15 +1718,15 @@ function dr(t, e, n = 1 / 0, r = 1 / 0, i = /* @__PURE__ */ function() {
|
|
|
1718
1718
|
}
|
|
1719
1719
|
const h = Array.isArray(e) ? [] : {};
|
|
1720
1720
|
let v = 0;
|
|
1721
|
-
const
|
|
1722
|
-
for (const
|
|
1723
|
-
if (!Object.prototype.hasOwnProperty.call(
|
|
1721
|
+
const E = Mo(e);
|
|
1722
|
+
for (const k in E) {
|
|
1723
|
+
if (!Object.prototype.hasOwnProperty.call(E, k)) continue;
|
|
1724
1724
|
if (v >= r) {
|
|
1725
|
-
h[
|
|
1725
|
+
h[k] = "[MaxProperties ~]";
|
|
1726
1726
|
break;
|
|
1727
1727
|
}
|
|
1728
|
-
const
|
|
1729
|
-
h[
|
|
1728
|
+
const b = E[k];
|
|
1729
|
+
h[k] = dr(k, b, l - 1, r, i), v++;
|
|
1730
1730
|
}
|
|
1731
1731
|
return a(e), h;
|
|
1732
1732
|
}
|
|
@@ -1812,14 +1812,14 @@ let Ht, Ui, Fn;
|
|
|
1812
1812
|
function mc(t, e) {
|
|
1813
1813
|
const { fingerprint: n, span: r, breadcrumbs: i, sdkProcessingMetadata: s } = e;
|
|
1814
1814
|
(function(a, c) {
|
|
1815
|
-
const { extra: l, tags: f, user: h, contexts: v, level:
|
|
1816
|
-
|
|
1815
|
+
const { extra: l, tags: f, user: h, contexts: v, level: E, transactionName: k } = c, b = me(l);
|
|
1816
|
+
b && Object.keys(b).length && (a.extra = { ...b, ...a.extra });
|
|
1817
1817
|
const m = me(f);
|
|
1818
1818
|
m && Object.keys(m).length && (a.tags = { ...m, ...a.tags });
|
|
1819
|
-
const
|
|
1820
|
-
|
|
1819
|
+
const y = me(h);
|
|
1820
|
+
y && Object.keys(y).length && (a.user = { ...y, ...a.user });
|
|
1821
1821
|
const w = me(v);
|
|
1822
|
-
w && Object.keys(w).length && (a.contexts = { ...w, ...a.contexts }),
|
|
1822
|
+
w && Object.keys(w).length && (a.contexts = { ...w, ...a.contexts }), E && (a.level = E), k && a.type !== "transaction" && (a.transaction = k);
|
|
1823
1823
|
})(t, e), r && function(a, c) {
|
|
1824
1824
|
a.contexts = { trace: ic(c), ...a.contexts }, a.sdkProcessingMetadata = { dynamicSamplingContext: ac(c), ...a.sdkProcessingMetadata };
|
|
1825
1825
|
const l = Ao(c), f = Jr(l).description;
|
|
@@ -1834,25 +1834,25 @@ function mc(t, e) {
|
|
|
1834
1834
|
}(t, s);
|
|
1835
1835
|
}
|
|
1836
1836
|
function Bi(t, e) {
|
|
1837
|
-
const { extra: n, tags: r, user: i, contexts: s, level: a, sdkProcessingMetadata: c, breadcrumbs: l, fingerprint: f, eventProcessors: h, attachments: v, propagationContext:
|
|
1838
|
-
Wt(t, "extra", n), Wt(t, "tags", r), Wt(t, "user", i), Wt(t, "contexts", s), t.sdkProcessingMetadata = On(t.sdkProcessingMetadata, c, 2), a && (t.level = a),
|
|
1837
|
+
const { extra: n, tags: r, user: i, contexts: s, level: a, sdkProcessingMetadata: c, breadcrumbs: l, fingerprint: f, eventProcessors: h, attachments: v, propagationContext: E, transactionName: k, span: b } = e;
|
|
1838
|
+
Wt(t, "extra", n), Wt(t, "tags", r), Wt(t, "user", i), Wt(t, "contexts", s), t.sdkProcessingMetadata = On(t.sdkProcessingMetadata, c, 2), a && (t.level = a), k && (t.transactionName = k), b && (t.span = b), l.length && (t.breadcrumbs = [...t.breadcrumbs, ...l]), f.length && (t.fingerprint = [...t.fingerprint, ...f]), h.length && (t.eventProcessors = [...t.eventProcessors, ...h]), v.length && (t.attachments = [...t.attachments, ...v]), t.propagationContext = { ...t.propagationContext, ...E };
|
|
1839
1839
|
}
|
|
1840
1840
|
function Wt(t, e, n) {
|
|
1841
1841
|
t[e] = On(t[e], n, 1);
|
|
1842
1842
|
}
|
|
1843
1843
|
function gc(t, e, n, r, i, s) {
|
|
1844
|
-
const { normalizeDepth: a = 3, normalizeMaxBreadth: c = 1e3 } = t, l = { ...e, event_id: e.event_id || n.event_id || ge(), timestamp: e.timestamp || Rt() }, f = n.integrations || t.integrations.map((
|
|
1845
|
-
(function(
|
|
1846
|
-
const { environment:
|
|
1847
|
-
|
|
1848
|
-
const j =
|
|
1844
|
+
const { normalizeDepth: a = 3, normalizeMaxBreadth: c = 1e3 } = t, l = { ...e, event_id: e.event_id || n.event_id || ge(), timestamp: e.timestamp || Rt() }, f = n.integrations || t.integrations.map((b) => b.name);
|
|
1845
|
+
(function(b, m) {
|
|
1846
|
+
const { environment: y, release: w, dist: C, maxValueLength: A = 250 } = m;
|
|
1847
|
+
b.environment = b.environment || y || qr, !b.release && w && (b.release = w), !b.dist && C && (b.dist = C), b.message && (b.message = ut(b.message, A));
|
|
1848
|
+
const j = b.exception && b.exception.values && b.exception.values[0];
|
|
1849
1849
|
j && j.value && (j.value = ut(j.value, A));
|
|
1850
|
-
const x =
|
|
1850
|
+
const x = b.request;
|
|
1851
1851
|
x && x.url && (x.url = ut(x.url, A));
|
|
1852
|
-
})(l, t), function(
|
|
1853
|
-
m.length > 0 && (
|
|
1854
|
-
}(l, f), i && i.emit("applyFrameMetadata", e), e.type === void 0 && function(
|
|
1855
|
-
const
|
|
1852
|
+
})(l, t), function(b, m) {
|
|
1853
|
+
m.length > 0 && (b.sdk = b.sdk || {}, b.sdk.integrations = [...b.sdk.integrations || [], ...m]);
|
|
1854
|
+
}(l, f), i && i.emit("applyFrameMetadata", e), e.type === void 0 && function(b, m) {
|
|
1855
|
+
const y = function(w) {
|
|
1856
1856
|
const C = $._sentryDebugIds;
|
|
1857
1857
|
if (!C) return {};
|
|
1858
1858
|
const A = Object.keys(C);
|
|
@@ -1874,44 +1874,44 @@ function gc(t, e, n, r, i, s) {
|
|
|
1874
1874
|
}, {})), Fn;
|
|
1875
1875
|
}(m);
|
|
1876
1876
|
try {
|
|
1877
|
-
|
|
1877
|
+
b.exception.values.forEach((w) => {
|
|
1878
1878
|
w.stacktrace.frames.forEach((C) => {
|
|
1879
|
-
|
|
1879
|
+
y && C.filename && (C.debug_id = y[C.filename]);
|
|
1880
1880
|
});
|
|
1881
1881
|
});
|
|
1882
1882
|
} catch {
|
|
1883
1883
|
}
|
|
1884
1884
|
}(l, t.stackParser);
|
|
1885
|
-
const h = function(
|
|
1886
|
-
if (!m) return
|
|
1887
|
-
const
|
|
1888
|
-
return
|
|
1885
|
+
const h = function(b, m) {
|
|
1886
|
+
if (!m) return b;
|
|
1887
|
+
const y = b ? b.clone() : new Ue();
|
|
1888
|
+
return y.update(m), y;
|
|
1889
1889
|
}(r, n.captureContext);
|
|
1890
1890
|
n.mechanism && ht(l, n.mechanism);
|
|
1891
|
-
const v = i ? i.getEventProcessors() : [],
|
|
1892
|
-
s && Bi(
|
|
1893
|
-
const
|
|
1894
|
-
return
|
|
1895
|
-
const
|
|
1891
|
+
const v = i ? i.getEventProcessors() : [], E = hn("globalScope", () => new Ue()).getScopeData();
|
|
1892
|
+
s && Bi(E, s.getScopeData()), h && Bi(E, h.getScopeData());
|
|
1893
|
+
const k = [...n.attachments || [], ...E.attachments];
|
|
1894
|
+
return k.length && (n.attachments = k), mc(l, E), hr([...v, ...E.eventProcessors], l, n).then((b) => (b && function(m) {
|
|
1895
|
+
const y = {};
|
|
1896
1896
|
try {
|
|
1897
1897
|
m.exception.values.forEach((C) => {
|
|
1898
1898
|
C.stacktrace.frames.forEach((A) => {
|
|
1899
|
-
A.debug_id && (A.abs_path ?
|
|
1899
|
+
A.debug_id && (A.abs_path ? y[A.abs_path] = A.debug_id : A.filename && (y[A.filename] = A.debug_id), delete A.debug_id);
|
|
1900
1900
|
});
|
|
1901
1901
|
});
|
|
1902
1902
|
} catch {
|
|
1903
1903
|
}
|
|
1904
|
-
if (Object.keys(
|
|
1904
|
+
if (Object.keys(y).length === 0) return;
|
|
1905
1905
|
m.debug_meta = m.debug_meta || {}, m.debug_meta.images = m.debug_meta.images || [];
|
|
1906
1906
|
const w = m.debug_meta.images;
|
|
1907
|
-
Object.entries(
|
|
1907
|
+
Object.entries(y).forEach(([C, A]) => {
|
|
1908
1908
|
w.push({ type: "sourcemap", code_file: C, debug_id: A });
|
|
1909
1909
|
});
|
|
1910
|
-
}(
|
|
1910
|
+
}(b), typeof a == "number" && a > 0 ? function(m, y, w) {
|
|
1911
1911
|
if (!m) return null;
|
|
1912
|
-
const C = { ...m, ...m.breadcrumbs && { breadcrumbs: m.breadcrumbs.map((A) => ({ ...A, ...A.data && { data: Pe(A.data,
|
|
1913
|
-
return m.contexts && m.contexts.trace && C.contexts && (C.contexts.trace = m.contexts.trace, m.contexts.trace.data && (C.contexts.trace.data = Pe(m.contexts.trace.data,
|
|
1914
|
-
}(
|
|
1912
|
+
const C = { ...m, ...m.breadcrumbs && { breadcrumbs: m.breadcrumbs.map((A) => ({ ...A, ...A.data && { data: Pe(A.data, y, w) } })) }, ...m.user && { user: Pe(m.user, y, w) }, ...m.contexts && { contexts: Pe(m.contexts, y, w) }, ...m.extra && { extra: Pe(m.extra, y, w) } };
|
|
1913
|
+
return m.contexts && m.contexts.trace && C.contexts && (C.contexts.trace = m.contexts.trace, m.contexts.trace.data && (C.contexts.trace.data = Pe(m.contexts.trace.data, y, w))), m.spans && (C.spans = m.spans.map((A) => ({ ...A, ...A.data && { data: Pe(A.data, y, w) } }))), m.contexts && m.contexts.flags && C.contexts && (C.contexts.flags = Pe(m.contexts.flags, 3, w)), C;
|
|
1914
|
+
}(b, a, c) : b));
|
|
1915
1915
|
}
|
|
1916
1916
|
function Vi(t, e) {
|
|
1917
1917
|
return st().captureEvent(t, e);
|
|
@@ -2122,19 +2122,19 @@ class yc {
|
|
|
2122
2122
|
});
|
|
2123
2123
|
}
|
|
2124
2124
|
_processEvent(e, n, r) {
|
|
2125
|
-
const i = this.getOptions(), { sampleRate: s } = i, a = Ki(e), c = Gi(e), l = e.type || "error", f = `before send for type \`${l}\``, h = s === void 0 ? void 0 : function(
|
|
2126
|
-
if (typeof
|
|
2127
|
-
const
|
|
2128
|
-
if (!(typeof
|
|
2129
|
-
W && D.warn(`[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(
|
|
2125
|
+
const i = this.getOptions(), { sampleRate: s } = i, a = Ki(e), c = Gi(e), l = e.type || "error", f = `before send for type \`${l}\``, h = s === void 0 ? void 0 : function(k) {
|
|
2126
|
+
if (typeof k == "boolean") return Number(k);
|
|
2127
|
+
const b = typeof k == "string" ? parseFloat(k) : k;
|
|
2128
|
+
if (!(typeof b != "number" || isNaN(b) || b < 0 || b > 1)) return b;
|
|
2129
|
+
W && D.warn(`[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(k)} of type ${JSON.stringify(typeof k)}.`);
|
|
2130
2130
|
}(s);
|
|
2131
2131
|
if (c && typeof h == "number" && Math.random() > h) return this.recordDroppedEvent("sample_rate", "error", e), mn(new be(`Discarding event because it's not included in the random sample (sampling rate = ${s})`, "log"));
|
|
2132
|
-
const v = l === "replay_event" ? "replay" : l,
|
|
2133
|
-
return this._prepareEvent(e, n, r,
|
|
2134
|
-
if (
|
|
2135
|
-
if (n.data && n.data.__sentry__ === !0) return
|
|
2136
|
-
const
|
|
2137
|
-
const { beforeSend: A, beforeSendTransaction: j, beforeSendSpan: x } =
|
|
2132
|
+
const v = l === "replay_event" ? "replay" : l, E = (e.sdkProcessingMetadata || {}).capturedSpanIsolationScope;
|
|
2133
|
+
return this._prepareEvent(e, n, r, E).then((k) => {
|
|
2134
|
+
if (k === null) throw this.recordDroppedEvent("event_processor", v, e), new be("An event processor returned `null`, will not send event.", "log");
|
|
2135
|
+
if (n.data && n.data.__sentry__ === !0) return k;
|
|
2136
|
+
const b = function(m, y, w, C) {
|
|
2137
|
+
const { beforeSend: A, beforeSendTransaction: j, beforeSendSpan: x } = y;
|
|
2138
2138
|
if (Gi(w) && A) return A(w, C);
|
|
2139
2139
|
if (Ki(w)) {
|
|
2140
2140
|
if (w.spans && x) {
|
|
@@ -2154,40 +2154,40 @@ class yc {
|
|
|
2154
2154
|
}
|
|
2155
2155
|
}
|
|
2156
2156
|
return w;
|
|
2157
|
-
}(this, i,
|
|
2158
|
-
return function(m,
|
|
2159
|
-
const w = `${
|
|
2157
|
+
}(this, i, k, n);
|
|
2158
|
+
return function(m, y) {
|
|
2159
|
+
const w = `${y} must return \`null\` or a valid event.`;
|
|
2160
2160
|
if (Mn(m)) return m.then((C) => {
|
|
2161
2161
|
if (!ft(C) && C !== null) throw new be(w);
|
|
2162
2162
|
return C;
|
|
2163
2163
|
}, (C) => {
|
|
2164
|
-
throw new be(`${
|
|
2164
|
+
throw new be(`${y} rejected with ${C}`);
|
|
2165
2165
|
});
|
|
2166
2166
|
if (!ft(m) && m !== null) throw new be(w);
|
|
2167
2167
|
return m;
|
|
2168
|
-
}(
|
|
2169
|
-
}).then((
|
|
2170
|
-
if (
|
|
2168
|
+
}(b, f);
|
|
2169
|
+
}).then((k) => {
|
|
2170
|
+
if (k === null) {
|
|
2171
2171
|
if (this.recordDroppedEvent("before_send", v, e), a) {
|
|
2172
|
-
const
|
|
2173
|
-
this.recordDroppedEvent("before_send", "span",
|
|
2172
|
+
const y = 1 + (e.spans || []).length;
|
|
2173
|
+
this.recordDroppedEvent("before_send", "span", y);
|
|
2174
2174
|
}
|
|
2175
2175
|
throw new be(`${f} returned \`null\`, will not send event.`, "log");
|
|
2176
2176
|
}
|
|
2177
|
-
const
|
|
2178
|
-
if (!a &&
|
|
2179
|
-
const
|
|
2180
|
-
|
|
2177
|
+
const b = r && r.getSession();
|
|
2178
|
+
if (!a && b && this._updateSessionFromEvent(b, k), a) {
|
|
2179
|
+
const y = (k.sdkProcessingMetadata && k.sdkProcessingMetadata.spanCountBeforeProcessing || 0) - (k.spans ? k.spans.length : 0);
|
|
2180
|
+
y > 0 && this.recordDroppedEvent("before_send", "span", y);
|
|
2181
2181
|
}
|
|
2182
|
-
const m =
|
|
2183
|
-
if (a && m &&
|
|
2184
|
-
const
|
|
2185
|
-
|
|
2182
|
+
const m = k.transaction_info;
|
|
2183
|
+
if (a && m && k.transaction !== e.transaction) {
|
|
2184
|
+
const y = "custom";
|
|
2185
|
+
k.transaction_info = { ...m, source: y };
|
|
2186
2186
|
}
|
|
2187
|
-
return this.sendEvent(
|
|
2188
|
-
}).then(null, (
|
|
2189
|
-
throw
|
|
2190
|
-
Reason: ${
|
|
2187
|
+
return this.sendEvent(k, n), k;
|
|
2188
|
+
}).then(null, (k) => {
|
|
2189
|
+
throw k instanceof be ? k : (this.captureException(k, { data: { __sentry__: !0 }, originalException: k }), new be(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.
|
|
2190
|
+
Reason: ${k}`));
|
|
2191
2191
|
});
|
|
2192
2192
|
}
|
|
2193
2193
|
_process(e) {
|
|
@@ -2245,9 +2245,9 @@ function bc(t) {
|
|
|
2245
2245
|
function _c(t, { statusCode: e, headers: n }, r = Date.now()) {
|
|
2246
2246
|
const i = { ...t }, s = n && n["x-sentry-rate-limits"], a = n && n["retry-after"];
|
|
2247
2247
|
if (s) for (const c of s.trim().split(",")) {
|
|
2248
|
-
const [l, f, , , h] = c.split(":", 5), v = parseInt(l, 10),
|
|
2249
|
-
if (f) for (const
|
|
2250
|
-
else i.all = r +
|
|
2248
|
+
const [l, f, , , h] = c.split(":", 5), v = parseInt(l, 10), E = 1e3 * (isNaN(v) ? 60 : v);
|
|
2249
|
+
if (f) for (const k of f.split(";")) k === "metric_bucket" && h && !h.split(";").includes("custom") || (i[k] = r + E);
|
|
2250
|
+
else i.all = r + E;
|
|
2251
2251
|
}
|
|
2252
2252
|
else a ? i.all = r + function(c, l = Date.now()) {
|
|
2253
2253
|
const f = parseInt(`${c}`, 10);
|
|
@@ -2263,10 +2263,10 @@ function wc(t, e, n = bc(t.bufferSize || 64)) {
|
|
|
2263
2263
|
const s = [];
|
|
2264
2264
|
if (Ni(i, (l, f) => {
|
|
2265
2265
|
const h = Fi(f);
|
|
2266
|
-
if (function(v,
|
|
2267
|
-
return function(
|
|
2268
|
-
return
|
|
2269
|
-
}(v,
|
|
2266
|
+
if (function(v, E, k = Date.now()) {
|
|
2267
|
+
return function(b, m) {
|
|
2268
|
+
return b[m] || b.all || 0;
|
|
2269
|
+
}(v, E) > k;
|
|
2270
2270
|
}(r, h)) {
|
|
2271
2271
|
const v = Qi(l, f);
|
|
2272
2272
|
t.recordDroppedEvent("ratelimit_backoff", h, v);
|
|
@@ -2326,12 +2326,12 @@ Event: ${Ne(a)}`), !0) : function(l, f) {
|
|
|
2326
2326
|
return l.type || !f || !f.length ? !1 : function(h) {
|
|
2327
2327
|
const v = [];
|
|
2328
2328
|
h.message && v.push(h.message);
|
|
2329
|
-
let
|
|
2329
|
+
let E;
|
|
2330
2330
|
try {
|
|
2331
|
-
|
|
2331
|
+
E = h.exception.values[h.exception.values.length - 1];
|
|
2332
2332
|
} catch {
|
|
2333
2333
|
}
|
|
2334
|
-
return
|
|
2334
|
+
return E && E.value && (v.push(E.value), E.type && v.push(`${E.type}: ${E.value}`)), v;
|
|
2335
2335
|
}(l).some((h) => zt(h, f));
|
|
2336
2336
|
}(a, c.ignoreErrors) ? (W && D.warn(`Event dropped due to being matched by \`ignoreErrors\` option.
|
|
2337
2337
|
Event: ${Ne(a)}`), !0) : function(l) {
|
|
@@ -2392,8 +2392,8 @@ function pr(t, e, n, r, i, s, a, c) {
|
|
|
2392
2392
|
return Array.isArray(r.errors) && r.errors.forEach((f, h) => {
|
|
2393
2393
|
if (Ze(f, Error)) {
|
|
2394
2394
|
Zi(a, c);
|
|
2395
|
-
const v = t(e, f),
|
|
2396
|
-
es(v, `errors[${h}]`,
|
|
2395
|
+
const v = t(e, f), E = l.length;
|
|
2396
|
+
es(v, `errors[${h}]`, E, c), l = pr(t, e, n, f, i, [v, ...l], v, E);
|
|
2397
2397
|
}
|
|
2398
2398
|
}), l;
|
|
2399
2399
|
}
|
|
@@ -2502,11 +2502,11 @@ function xc(t, e) {
|
|
|
2502
2502
|
const c = new Error(), { method: l, url: f } = function(v) {
|
|
2503
2503
|
if (v.length === 0) return { method: "GET", url: "" };
|
|
2504
2504
|
if (v.length === 2) {
|
|
2505
|
-
const [
|
|
2506
|
-
return { url: ss(
|
|
2505
|
+
const [k, b] = v;
|
|
2506
|
+
return { url: ss(k), method: gr(b, "method") ? String(b.method).toUpperCase() : "GET" };
|
|
2507
2507
|
}
|
|
2508
|
-
const
|
|
2509
|
-
return { url: ss(
|
|
2508
|
+
const E = v[0];
|
|
2509
|
+
return { url: ss(E), method: gr(E, "method") ? String(E.method).toUpperCase() : "GET" };
|
|
2510
2510
|
}(a), h = { args: a, fetchData: { method: l, url: f }, startTimestamp: 1e3 * Ie(), virtualError: c };
|
|
2511
2511
|
return r || _e("fetch", { ...h }), s.apply($, a).then(async (v) => (r ? r(v) : _e("fetch", { ...h, endTimestamp: 1e3 * Ie(), response: v }), v), (v) => {
|
|
2512
2512
|
throw _e("fetch", { ...h, endTimestamp: 1e3 * Ie(), error: v }), Dr(v) && v.stack === void 0 && (v.stack = c.stack, et(v, "framesToPop", 1)), v;
|
|
@@ -2815,8 +2815,8 @@ function Vc() {
|
|
|
2815
2815
|
}
|
|
2816
2816
|
};
|
|
2817
2817
|
return "onreadystatechange" in n && typeof n.onreadystatechange == "function" ? n.onreadystatechange = new Proxy(n.onreadystatechange, { apply: (f, h, v) => (l(), f.apply(h, v)) }) : n.addEventListener("readystatechange", l), n.setRequestHeader = new Proxy(n.setRequestHeader, { apply(f, h, v) {
|
|
2818
|
-
const [
|
|
2819
|
-
return
|
|
2818
|
+
const [E, k] = v, b = h[Mt];
|
|
2819
|
+
return b && xe(E) && xe(k) && (b.request_headers[E.toLowerCase()] = k), f.apply(h, v);
|
|
2820
2820
|
} }), e.apply(n, r);
|
|
2821
2821
|
} }), t.send = new Proxy(t.send, { apply(e, n, r) {
|
|
2822
2822
|
const i = n[Mt];
|
|
@@ -2933,13 +2933,13 @@ const qc = /^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i, $c = /^\s*at (?:(.+?\)(?: \
|
|
|
2933
2933
|
let c, l, f = typeof s == "object" ? s.serializeAttribute : void 0, h = typeof s == "object" && typeof s.maxStringLength == "number" ? s.maxStringLength : void 0;
|
|
2934
2934
|
h && h > ds && (An && D.warn(`\`dom.maxStringLength\` cannot exceed 1024, but a value of ${h} was configured. Sentry will use 1024 instead.`), h = ds), typeof f == "string" && (f = [f]);
|
|
2935
2935
|
try {
|
|
2936
|
-
const
|
|
2937
|
-
return !!
|
|
2938
|
-
}(
|
|
2939
|
-
c = To(
|
|
2936
|
+
const E = a.event, k = function(b) {
|
|
2937
|
+
return !!b && !!b.target;
|
|
2938
|
+
}(E) ? E.target : E;
|
|
2939
|
+
c = To(k, { keyAttrs: f, maxStringLength: h }), l = function(b) {
|
|
2940
2940
|
if (!Fr.HTMLElement) return null;
|
|
2941
|
-
let m =
|
|
2942
|
-
for (let
|
|
2941
|
+
let m = b;
|
|
2942
|
+
for (let y = 0; y < 5; y++) {
|
|
2943
2943
|
if (!m) return null;
|
|
2944
2944
|
if (m instanceof HTMLElement) {
|
|
2945
2945
|
if (m.dataset.sentryComponent) return m.dataset.sentryComponent;
|
|
@@ -2948,7 +2948,7 @@ const qc = /^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i, $c = /^\s*at (?:(.+?\)(?: \
|
|
|
2948
2948
|
m = m.parentNode;
|
|
2949
2949
|
}
|
|
2950
2950
|
return null;
|
|
2951
|
-
}(
|
|
2951
|
+
}(k);
|
|
2952
2952
|
} catch {
|
|
2953
2953
|
c = "<unknown>";
|
|
2954
2954
|
}
|
|
@@ -2963,8 +2963,8 @@ const qc = /^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i, $c = /^\s*at (?:(.+?\)(?: \
|
|
|
2963
2963
|
if (te() !== i) return;
|
|
2964
2964
|
const { startTimestamp: a, endTimestamp: c } = s, l = s.xhr[Mt];
|
|
2965
2965
|
if (!a || !c || !l) return;
|
|
2966
|
-
const { method: f, url: h, status_code: v, body:
|
|
2967
|
-
Je({ category: "xhr", data:
|
|
2966
|
+
const { method: f, url: h, status_code: v, body: E } = l, k = { method: f, url: h, status_code: v }, b = { xhr: s.xhr, input: E, startTimestamp: a, endTimestamp: c };
|
|
2967
|
+
Je({ category: "xhr", data: k, type: "http", level: is(v) }, b);
|
|
2968
2968
|
};
|
|
2969
2969
|
}(n)), e.fetch && xc(/* @__PURE__ */ function(i) {
|
|
2970
2970
|
return function(s) {
|
|
@@ -3059,17 +3059,17 @@ const tl = () => ({ name: "BrowserSession", setupOnce() {
|
|
|
3059
3059
|
})((i) => {
|
|
3060
3060
|
const { stackParser: s, attachStacktrace: a } = ps();
|
|
3061
3061
|
if (te() !== r || os()) return;
|
|
3062
|
-
const { msg: c, url: l, line: f, column: h, error: v } = i,
|
|
3063
|
-
const w =
|
|
3062
|
+
const { msg: c, url: l, line: f, column: h, error: v } = i, E = function(k, b, m, y) {
|
|
3063
|
+
const w = k.exception = k.exception || {}, C = w.values = w.values || [], A = C[0] = C[0] || {}, j = A.stacktrace = A.stacktrace || {}, x = j.frames = j.frames || [], R = y, J = m, X = xe(b) && b.length > 0 ? b : function() {
|
|
3064
3064
|
try {
|
|
3065
3065
|
return Fr.document.location.href;
|
|
3066
3066
|
} catch {
|
|
3067
3067
|
return "";
|
|
3068
3068
|
}
|
|
3069
3069
|
}();
|
|
3070
|
-
return x.length === 0 && x.push({ colno: R, filename: X, function: We, in_app: !0, lineno: J }),
|
|
3070
|
+
return x.length === 0 && x.push({ colno: R, filename: X, function: We, in_app: !0, lineno: J }), k;
|
|
3071
3071
|
}(yr(s, v || c, void 0, a, !1), l, f, h);
|
|
3072
|
-
|
|
3072
|
+
E.level = "error", Vi(E, { originalException: v, mechanism: { handled: !1, type: "onerror" } });
|
|
3073
3073
|
});
|
|
3074
3074
|
}(n), hs("onerror")), e.onunhandledrejection && (function(r) {
|
|
3075
3075
|
(function(i) {
|
|
@@ -4022,8 +4022,8 @@ var Qo = function() {
|
|
|
4022
4022
|
} else {
|
|
4023
4023
|
if (q(e[s]) !== "object") return [!1, "invalid (non-object) value for field '".concat(s, "' in canReceive")];
|
|
4024
4024
|
for (var f = 0, h = Object.values(e[s]); f < h.length; f++) {
|
|
4025
|
-
var v = h[f],
|
|
4026
|
-
if (!
|
|
4025
|
+
var v = h[f], E = re(ee.validateJSONObject(v), 2), k = E[0], b = E[1];
|
|
4026
|
+
if (!k) return [!1, b];
|
|
4027
4027
|
}
|
|
4028
4028
|
}
|
|
4029
4029
|
}
|
|
@@ -4278,16 +4278,16 @@ var $e = {}, Ks = "video", Iu = "voice", Qs = V() ? { data: {} } : { data: {}, t
|
|
|
4278
4278
|
(s instanceof Array || Array.isArray(s)) && (t.canSend = new Set(s));
|
|
4279
4279
|
break;
|
|
4280
4280
|
case "canReceive":
|
|
4281
|
-
var h = re(Qo.validateJSONObject(s), 2), v = h[0],
|
|
4282
|
-
if (!v) return console.error(
|
|
4281
|
+
var h = re(Qo.validateJSONObject(s), 2), v = h[0], E = h[1];
|
|
4282
|
+
if (!v) return console.error(E), !1;
|
|
4283
4283
|
break;
|
|
4284
4284
|
case "canAdmin":
|
|
4285
4285
|
if (s instanceof Set || s instanceof Array || Array.isArray(s)) {
|
|
4286
|
-
var
|
|
4286
|
+
var k, b = ["participants", "streaming", "transcription"], m = Ws(s);
|
|
4287
4287
|
try {
|
|
4288
|
-
for (m.s(); !(
|
|
4289
|
-
var
|
|
4290
|
-
if (!
|
|
4288
|
+
for (m.s(); !(k = m.n()).done; ) {
|
|
4289
|
+
var y = k.value;
|
|
4290
|
+
if (!b.includes(y)) return !1;
|
|
4291
4291
|
}
|
|
4292
4292
|
} catch (w) {
|
|
4293
4293
|
m.e(w);
|
|
@@ -4937,7 +4937,7 @@ var Lu = function() {
|
|
|
4937
4937
|
if (H(this._callState, "stopTranscription()"), o && q(o) !== "object") throw new Error("stopTranscription Error: options must be object type");
|
|
4938
4938
|
if (o && !o.instanceId) throw new Error('"instanceId" not provided');
|
|
4939
4939
|
this.sendMessageToCallMachine(I({ action: "daily-method-stop-transcription" }, o));
|
|
4940
|
-
} }, { key: "startDialOut", value: (
|
|
4940
|
+
} }, { key: "startDialOut", value: (y = L(function* (o) {
|
|
4941
4941
|
var d = this;
|
|
4942
4942
|
H(this._callState, "startDialOut()");
|
|
4943
4943
|
var u = function(M) {
|
|
@@ -4994,7 +4994,7 @@ var Lu = function() {
|
|
|
4994
4994
|
});
|
|
4995
4995
|
});
|
|
4996
4996
|
}), function(o) {
|
|
4997
|
-
return
|
|
4997
|
+
return y.apply(this, arguments);
|
|
4998
4998
|
}) }, { key: "stopDialOut", value: function(o) {
|
|
4999
4999
|
var d = this;
|
|
5000
5000
|
return H(this._callState, "stopDialOut()"), new Promise(function(u, p) {
|
|
@@ -5012,7 +5012,7 @@ var Lu = function() {
|
|
|
5012
5012
|
});
|
|
5013
5013
|
}), function(o) {
|
|
5014
5014
|
return m.apply(this, arguments);
|
|
5015
|
-
}) }, { key: "sipRefer", value: (
|
|
5015
|
+
}) }, { key: "sipRefer", value: (b = L(function* (o) {
|
|
5016
5016
|
var d = this;
|
|
5017
5017
|
if (H(this._callState, "sipRefer()"), !o) throw new Error("sessionId and toEndPoint are mandatory parameter");
|
|
5018
5018
|
return o.useSipRefer = !0, to(o, "sipRefer"), new Promise(function(u, p) {
|
|
@@ -5021,8 +5021,8 @@ var Lu = function() {
|
|
|
5021
5021
|
});
|
|
5022
5022
|
});
|
|
5023
5023
|
}), function(o) {
|
|
5024
|
-
return
|
|
5025
|
-
}) }, { key: "sendDTMF", value: (
|
|
5024
|
+
return b.apply(this, arguments);
|
|
5025
|
+
}) }, { key: "sendDTMF", value: (k = L(function* (o) {
|
|
5026
5026
|
var d = this;
|
|
5027
5027
|
return H(this._callState, "sendDTMF()"), function(u) {
|
|
5028
5028
|
var p = u.sessionId, g = u.tones;
|
|
@@ -5037,7 +5037,7 @@ var Lu = function() {
|
|
|
5037
5037
|
});
|
|
5038
5038
|
});
|
|
5039
5039
|
}), function(o) {
|
|
5040
|
-
return
|
|
5040
|
+
return k.apply(this, arguments);
|
|
5041
5041
|
}) }, { key: "getNetworkStats", value: function() {
|
|
5042
5042
|
var o = this;
|
|
5043
5043
|
return this._callState !== He ? Promise.resolve(I({ stats: { latest: {} } }, this._network)) : new Promise(function(d) {
|
|
@@ -5045,7 +5045,7 @@ var Lu = function() {
|
|
|
5045
5045
|
d(I(I({}, o._network), {}, { stats: u.stats }));
|
|
5046
5046
|
});
|
|
5047
5047
|
});
|
|
5048
|
-
} }, { key: "testWebsocketConnectivity", value: (
|
|
5048
|
+
} }, { key: "testWebsocketConnectivity", value: (E = L(function* () {
|
|
5049
5049
|
var o = this;
|
|
5050
5050
|
if (Zn(this._testCallInProgress, "testWebsocketConnectivity()"), this.needsLoad()) try {
|
|
5051
5051
|
yield this.load();
|
|
@@ -5058,7 +5058,7 @@ var Lu = function() {
|
|
|
5058
5058
|
});
|
|
5059
5059
|
});
|
|
5060
5060
|
}), function() {
|
|
5061
|
-
return
|
|
5061
|
+
return E.apply(this, arguments);
|
|
5062
5062
|
}) }, { key: "abortTestWebsocketConnectivity", value: function() {
|
|
5063
5063
|
this.sendMessageToCallMachine({ action: "abort-test-websocket-connectivity" });
|
|
5064
5064
|
} }, { key: "_validateVideoTrackForNetworkTests", value: function(o) {
|
|
@@ -5746,7 +5746,7 @@ var Lu = function() {
|
|
|
5746
5746
|
var o = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : void 0;
|
|
5747
5747
|
return o ? $e[o] : Object.values($e)[0];
|
|
5748
5748
|
} }]);
|
|
5749
|
-
var e, n, r, i, s, a, c, l, f, h, v,
|
|
5749
|
+
var e, n, r, i, s, a, c, l, f, h, v, E, k, b, m, y, w, C, A, j, x, R, J, X, Oe, ot, at, Yr, Zr, ei, ti, ni, ri, ii, si, oi, ai, ci;
|
|
5750
5750
|
}();
|
|
5751
5751
|
function ct(t, e) {
|
|
5752
5752
|
var n = {};
|
|
@@ -5826,8 +5826,8 @@ function Zo(t) {
|
|
|
5826
5826
|
}
|
|
5827
5827
|
function ea(t, e) {
|
|
5828
5828
|
for (var n = e.allowAllParticipantsKey, r = function(v) {
|
|
5829
|
-
var
|
|
5830
|
-
return n ||
|
|
5829
|
+
var E = ["local"];
|
|
5830
|
+
return n || E.push("*"), v && !E.includes(v);
|
|
5831
5831
|
}, i = function(v) {
|
|
5832
5832
|
return !!(v.layer === void 0 || Number.isInteger(v.layer) && v.layer >= 0 || v.layer === "inherit");
|
|
5833
5833
|
}, s = function(v) {
|
|
@@ -5861,9 +5861,9 @@ function ta(t) {
|
|
|
5861
5861
|
break;
|
|
5862
5862
|
case "audio":
|
|
5863
5863
|
if (q(s) !== "object") return !1;
|
|
5864
|
-
for (var v = 0,
|
|
5865
|
-
var
|
|
5866
|
-
switch (
|
|
5864
|
+
for (var v = 0, E = Object.entries(s); v < E.length; v++) {
|
|
5865
|
+
var k = re(E[v], 2), b = k[0], m = k[1];
|
|
5866
|
+
switch (b) {
|
|
5867
5867
|
case "processor":
|
|
5868
5868
|
if (!Ru(m)) return !1;
|
|
5869
5869
|
break;
|
|
@@ -5915,13 +5915,13 @@ function Du(t) {
|
|
|
5915
5915
|
if (fn(a.source)) return a.type = "url", !!function(f) {
|
|
5916
5916
|
var h = new URL(f), v = h.pathname;
|
|
5917
5917
|
if (h.protocol === "data:") try {
|
|
5918
|
-
var
|
|
5919
|
-
return Gn.includes(
|
|
5920
|
-
} catch (
|
|
5921
|
-
return console.error("failed to deduce blob content type",
|
|
5918
|
+
var E = v.substring(v.indexOf(":") + 1, v.indexOf(";")).split("/")[1];
|
|
5919
|
+
return Gn.includes(E);
|
|
5920
|
+
} catch (b) {
|
|
5921
|
+
return console.error("failed to deduce blob content type", b), !1;
|
|
5922
5922
|
}
|
|
5923
|
-
var
|
|
5924
|
-
return Gn.includes(
|
|
5923
|
+
var k = v.split(".").at(-1).toLowerCase().trim();
|
|
5924
|
+
return Gn.includes(k);
|
|
5925
5925
|
}(a.source) || (console.error("invalid image type; supported types: [".concat(Gn.join(", "), "]")), !1);
|
|
5926
5926
|
return c = a.source, l = Number(c), isNaN(l) || !Number.isInteger(l) || l <= 0 || l > 10 ? (console.error("invalid image selection; must be an int, > 0, <= ".concat(10)), !1) : (a.type = "daily-preselect", !0);
|
|
5927
5927
|
var c, l;
|
|
@@ -5972,8 +5972,8 @@ function oa(t) {
|
|
|
5972
5972
|
if (!t || t && q(t) !== "object" || Array.isArray(t)) return console.error(ia()), !1;
|
|
5973
5973
|
for (var e = function(v) {
|
|
5974
5974
|
return "".concat(v, " should be ").concat(Cr.id[v]);
|
|
5975
|
-
}, n = function(v,
|
|
5976
|
-
return console.error("customIntegration ".concat(v, ": ").concat(
|
|
5975
|
+
}, n = function(v, E) {
|
|
5976
|
+
return console.error("customIntegration ".concat(v, ": ").concat(E));
|
|
5977
5977
|
}, r = 0, i = Object.entries(t); r < i.length; r++) {
|
|
5978
5978
|
var s = re(i[r], 1)[0];
|
|
5979
5979
|
if (!("label" in t[s])) return n(s, "label is required"), !1;
|
|
@@ -6369,28 +6369,28 @@ function In(t, e, n) {
|
|
|
6369
6369
|
metaTokens: !0,
|
|
6370
6370
|
dots: !1,
|
|
6371
6371
|
indexes: !1
|
|
6372
|
-
}, !1, function(m,
|
|
6373
|
-
return !_.isUndefined(
|
|
6372
|
+
}, !1, function(m, y) {
|
|
6373
|
+
return !_.isUndefined(y[m]);
|
|
6374
6374
|
});
|
|
6375
6375
|
const r = n.metaTokens, i = n.visitor || h, s = n.dots, a = n.indexes, l = (n.Blob || typeof Blob < "u" && Blob) && _.isSpecCompliantForm(e);
|
|
6376
6376
|
if (!_.isFunction(i))
|
|
6377
6377
|
throw new TypeError("visitor must be a function");
|
|
6378
|
-
function f(
|
|
6379
|
-
if (
|
|
6380
|
-
if (_.isDate(
|
|
6381
|
-
return
|
|
6382
|
-
if (_.isBoolean(
|
|
6383
|
-
return
|
|
6384
|
-
if (!l && _.isBlob(
|
|
6378
|
+
function f(b) {
|
|
6379
|
+
if (b === null) return "";
|
|
6380
|
+
if (_.isDate(b))
|
|
6381
|
+
return b.toISOString();
|
|
6382
|
+
if (_.isBoolean(b))
|
|
6383
|
+
return b.toString();
|
|
6384
|
+
if (!l && _.isBlob(b))
|
|
6385
6385
|
throw new N("Blob is not supported. Use a Buffer instead.");
|
|
6386
|
-
return _.isArrayBuffer(
|
|
6386
|
+
return _.isArrayBuffer(b) || _.isTypedArray(b) ? l && typeof Blob == "function" ? new Blob([b]) : Buffer.from(b) : b;
|
|
6387
6387
|
}
|
|
6388
|
-
function h(
|
|
6389
|
-
let w =
|
|
6390
|
-
if (
|
|
6388
|
+
function h(b, m, y) {
|
|
6389
|
+
let w = b;
|
|
6390
|
+
if (b && !y && typeof b == "object") {
|
|
6391
6391
|
if (_.endsWith(m, "{}"))
|
|
6392
|
-
m = r ? m : m.slice(0, -2),
|
|
6393
|
-
else if (_.isArray(
|
|
6392
|
+
m = r ? m : m.slice(0, -2), b = JSON.stringify(b);
|
|
6393
|
+
else if (_.isArray(b) && kd(b) || (_.isFileList(b) || _.endsWith(m, "[]")) && (w = _.toArray(b)))
|
|
6394
6394
|
return m = ya(m), w.forEach(function(A, j) {
|
|
6395
6395
|
!(_.isUndefined(A) || A === null) && e.append(
|
|
6396
6396
|
// eslint-disable-next-line no-nested-ternary
|
|
@@ -6399,31 +6399,31 @@ function In(t, e, n) {
|
|
|
6399
6399
|
);
|
|
6400
6400
|
}), !1;
|
|
6401
6401
|
}
|
|
6402
|
-
return Ar(
|
|
6402
|
+
return Ar(b) ? !0 : (e.append(so(y, m, s), f(b)), !1);
|
|
6403
6403
|
}
|
|
6404
|
-
const v = [],
|
|
6404
|
+
const v = [], E = Object.assign(Ed, {
|
|
6405
6405
|
defaultVisitor: h,
|
|
6406
6406
|
convertValue: f,
|
|
6407
6407
|
isVisitable: Ar
|
|
6408
6408
|
});
|
|
6409
|
-
function
|
|
6410
|
-
if (!_.isUndefined(
|
|
6411
|
-
if (v.indexOf(
|
|
6409
|
+
function k(b, m) {
|
|
6410
|
+
if (!_.isUndefined(b)) {
|
|
6411
|
+
if (v.indexOf(b) !== -1)
|
|
6412
6412
|
throw Error("Circular reference detected in " + m.join("."));
|
|
6413
|
-
v.push(
|
|
6413
|
+
v.push(b), _.forEach(b, function(w, C) {
|
|
6414
6414
|
(!(_.isUndefined(w) || w === null) && i.call(
|
|
6415
6415
|
e,
|
|
6416
6416
|
w,
|
|
6417
6417
|
_.isString(C) ? C.trim() : C,
|
|
6418
6418
|
m,
|
|
6419
|
-
|
|
6420
|
-
)) === !0 &&
|
|
6419
|
+
E
|
|
6420
|
+
)) === !0 && k(w, m ? m.concat(C) : [C]);
|
|
6421
6421
|
}), v.pop();
|
|
6422
6422
|
}
|
|
6423
6423
|
}
|
|
6424
6424
|
if (!_.isObject(t))
|
|
6425
6425
|
throw new TypeError("data must be an object");
|
|
6426
|
-
return
|
|
6426
|
+
return k(t), e;
|
|
6427
6427
|
}
|
|
6428
6428
|
function oo(t) {
|
|
6429
6429
|
const e = {
|
|
@@ -6902,13 +6902,13 @@ function zd(t, e) {
|
|
|
6902
6902
|
return e = e !== void 0 ? e : 1e3, function(l) {
|
|
6903
6903
|
const f = Date.now(), h = r[s];
|
|
6904
6904
|
a || (a = f), n[i] = l, r[i] = f;
|
|
6905
|
-
let v = s,
|
|
6905
|
+
let v = s, E = 0;
|
|
6906
6906
|
for (; v !== i; )
|
|
6907
|
-
|
|
6907
|
+
E += n[v++], v = v % t;
|
|
6908
6908
|
if (i = (i + 1) % t, i === s && (s = (s + 1) % t), f - a < e)
|
|
6909
6909
|
return;
|
|
6910
|
-
const
|
|
6911
|
-
return
|
|
6910
|
+
const k = h && f - h;
|
|
6911
|
+
return k ? Math.round(E * 1e3 / k) : void 0;
|
|
6912
6912
|
};
|
|
6913
6913
|
}
|
|
6914
6914
|
function Hd(t, e) {
|
|
@@ -6993,14 +6993,14 @@ const fo = (t) => t instanceof ce ? { ...t } : t;
|
|
|
6993
6993
|
function rt(t, e) {
|
|
6994
6994
|
e = e || {};
|
|
6995
6995
|
const n = {};
|
|
6996
|
-
function r(f, h, v,
|
|
6997
|
-
return _.isPlainObject(f) && _.isPlainObject(h) ? _.merge.call({ caseless:
|
|
6996
|
+
function r(f, h, v, E) {
|
|
6997
|
+
return _.isPlainObject(f) && _.isPlainObject(h) ? _.merge.call({ caseless: E }, f, h) : _.isPlainObject(h) ? _.merge({}, h) : _.isArray(h) ? h.slice() : h;
|
|
6998
6998
|
}
|
|
6999
|
-
function i(f, h, v,
|
|
6999
|
+
function i(f, h, v, E) {
|
|
7000
7000
|
if (_.isUndefined(h)) {
|
|
7001
7001
|
if (!_.isUndefined(f))
|
|
7002
|
-
return r(void 0, f, v,
|
|
7003
|
-
} else return r(f, h, v,
|
|
7002
|
+
return r(void 0, f, v, E);
|
|
7003
|
+
} else return r(f, h, v, E);
|
|
7004
7004
|
}
|
|
7005
7005
|
function s(f, h) {
|
|
7006
7006
|
if (!_.isUndefined(h))
|
|
@@ -7050,8 +7050,8 @@ function rt(t, e) {
|
|
|
7050
7050
|
headers: (f, h, v) => i(fo(f), fo(h), v, !0)
|
|
7051
7051
|
};
|
|
7052
7052
|
return _.forEach(Object.keys({ ...t, ...e }), function(h) {
|
|
7053
|
-
const v = l[h] || i,
|
|
7054
|
-
_.isUndefined(
|
|
7053
|
+
const v = l[h] || i, E = v(t[h], e[h], h);
|
|
7054
|
+
_.isUndefined(E) && v !== c || (n[h] = E);
|
|
7055
7055
|
}), n;
|
|
7056
7056
|
}
|
|
7057
7057
|
const Ca = (t) => {
|
|
@@ -7080,57 +7080,57 @@ const Ca = (t) => {
|
|
|
7080
7080
|
const i = Ca(t);
|
|
7081
7081
|
let s = i.data;
|
|
7082
7082
|
const a = ce.from(i.headers).normalize();
|
|
7083
|
-
let { responseType: c, onUploadProgress: l, onDownloadProgress: f } = i, h, v,
|
|
7083
|
+
let { responseType: c, onUploadProgress: l, onDownloadProgress: f } = i, h, v, E, k, b;
|
|
7084
7084
|
function m() {
|
|
7085
|
-
|
|
7085
|
+
k && k(), b && b(), i.cancelToken && i.cancelToken.unsubscribe(h), i.signal && i.signal.removeEventListener("abort", h);
|
|
7086
7086
|
}
|
|
7087
|
-
let
|
|
7088
|
-
|
|
7087
|
+
let y = new XMLHttpRequest();
|
|
7088
|
+
y.open(i.method.toUpperCase(), i.url, !0), y.timeout = i.timeout;
|
|
7089
7089
|
function w() {
|
|
7090
|
-
if (!
|
|
7090
|
+
if (!y)
|
|
7091
7091
|
return;
|
|
7092
7092
|
const A = ce.from(
|
|
7093
|
-
"getAllResponseHeaders" in
|
|
7093
|
+
"getAllResponseHeaders" in y && y.getAllResponseHeaders()
|
|
7094
7094
|
), x = {
|
|
7095
|
-
data: !c || c === "text" || c === "json" ?
|
|
7096
|
-
status:
|
|
7097
|
-
statusText:
|
|
7095
|
+
data: !c || c === "text" || c === "json" ? y.responseText : y.response,
|
|
7096
|
+
status: y.status,
|
|
7097
|
+
statusText: y.statusText,
|
|
7098
7098
|
headers: A,
|
|
7099
7099
|
config: t,
|
|
7100
|
-
request:
|
|
7100
|
+
request: y
|
|
7101
7101
|
};
|
|
7102
7102
|
Ea(function(J) {
|
|
7103
7103
|
n(J), m();
|
|
7104
7104
|
}, function(J) {
|
|
7105
7105
|
r(J), m();
|
|
7106
|
-
}, x),
|
|
7107
|
-
}
|
|
7108
|
-
"onloadend" in
|
|
7109
|
-
!
|
|
7110
|
-
},
|
|
7111
|
-
|
|
7112
|
-
},
|
|
7113
|
-
r(new N("Network Error", N.ERR_NETWORK, t,
|
|
7114
|
-
},
|
|
7106
|
+
}, x), y = null;
|
|
7107
|
+
}
|
|
7108
|
+
"onloadend" in y ? y.onloadend = w : y.onreadystatechange = function() {
|
|
7109
|
+
!y || y.readyState !== 4 || y.status === 0 && !(y.responseURL && y.responseURL.indexOf("file:") === 0) || setTimeout(w);
|
|
7110
|
+
}, y.onabort = function() {
|
|
7111
|
+
y && (r(new N("Request aborted", N.ECONNABORTED, t, y)), y = null);
|
|
7112
|
+
}, y.onerror = function() {
|
|
7113
|
+
r(new N("Network Error", N.ERR_NETWORK, t, y)), y = null;
|
|
7114
|
+
}, y.ontimeout = function() {
|
|
7115
7115
|
let j = i.timeout ? "timeout of " + i.timeout + "ms exceeded" : "timeout exceeded";
|
|
7116
7116
|
const x = i.transitional || wa;
|
|
7117
7117
|
i.timeoutErrorMessage && (j = i.timeoutErrorMessage), r(new N(
|
|
7118
7118
|
j,
|
|
7119
7119
|
x.clarifyTimeoutError ? N.ETIMEDOUT : N.ECONNABORTED,
|
|
7120
7120
|
t,
|
|
7121
|
-
|
|
7122
|
-
)),
|
|
7123
|
-
}, s === void 0 && a.setContentType(null), "setRequestHeader" in
|
|
7124
|
-
|
|
7125
|
-
}), _.isUndefined(i.withCredentials) || (
|
|
7126
|
-
|
|
7121
|
+
y
|
|
7122
|
+
)), y = null;
|
|
7123
|
+
}, s === void 0 && a.setContentType(null), "setRequestHeader" in y && _.forEach(a.toJSON(), function(j, x) {
|
|
7124
|
+
y.setRequestHeader(x, j);
|
|
7125
|
+
}), _.isUndefined(i.withCredentials) || (y.withCredentials = !!i.withCredentials), c && c !== "json" && (y.responseType = i.responseType), f && ([E, b] = _n(f, !0), y.addEventListener("progress", E)), l && y.upload && ([v, k] = _n(l), y.upload.addEventListener("progress", v), y.upload.addEventListener("loadend", k)), (i.cancelToken || i.signal) && (h = (A) => {
|
|
7126
|
+
y && (r(!A || A.type ? new bt(null, t, y) : A), y.abort(), y = null);
|
|
7127
7127
|
}, i.cancelToken && i.cancelToken.subscribe(h), i.signal && (i.signal.aborted ? h() : i.signal.addEventListener("abort", h)));
|
|
7128
7128
|
const C = $d(i.url);
|
|
7129
7129
|
if (C && ne.protocols.indexOf(C) === -1) {
|
|
7130
7130
|
r(new N("Unsupported protocol " + C + ":", N.ERR_BAD_REQUEST, t));
|
|
7131
7131
|
return;
|
|
7132
7132
|
}
|
|
7133
|
-
|
|
7133
|
+
y.send(s || null);
|
|
7134
7134
|
});
|
|
7135
7135
|
}, Zd = (t, e) => {
|
|
7136
7136
|
const { length: n } = t = t ? t.filter(Boolean) : [];
|
|
@@ -7198,8 +7198,8 @@ const Ca = (t) => {
|
|
|
7198
7198
|
}
|
|
7199
7199
|
let v = h.byteLength;
|
|
7200
7200
|
if (n) {
|
|
7201
|
-
let
|
|
7202
|
-
n(
|
|
7201
|
+
let E = s += v;
|
|
7202
|
+
n(E);
|
|
7203
7203
|
}
|
|
7204
7204
|
l.enqueue(new Uint8Array(h));
|
|
7205
7205
|
} catch (f) {
|
|
@@ -7268,16 +7268,16 @@ const of = async (t) => {
|
|
|
7268
7268
|
responseType: f,
|
|
7269
7269
|
headers: h,
|
|
7270
7270
|
withCredentials: v = "same-origin",
|
|
7271
|
-
fetchOptions:
|
|
7271
|
+
fetchOptions: E
|
|
7272
7272
|
} = Ca(t);
|
|
7273
7273
|
f = f ? (f + "").toLowerCase() : "text";
|
|
7274
|
-
let
|
|
7275
|
-
const m =
|
|
7276
|
-
|
|
7274
|
+
let k = Zd([i, s && s.toAbortSignal()], a), b;
|
|
7275
|
+
const m = k && k.unsubscribe && (() => {
|
|
7276
|
+
k.unsubscribe();
|
|
7277
7277
|
});
|
|
7278
|
-
let
|
|
7278
|
+
let y;
|
|
7279
7279
|
try {
|
|
7280
|
-
if (l && sf && n !== "get" && n !== "head" && (
|
|
7280
|
+
if (l && sf && n !== "get" && n !== "head" && (y = await af(h, r)) !== 0) {
|
|
7281
7281
|
let x = new Request(e, {
|
|
7282
7282
|
method: "POST",
|
|
7283
7283
|
body: r,
|
|
@@ -7285,7 +7285,7 @@ const of = async (t) => {
|
|
|
7285
7285
|
}), R;
|
|
7286
7286
|
if (_.isFormData(r) && (R = x.headers.get("content-type")) && h.setContentType(R), x.body) {
|
|
7287
7287
|
const [J, X] = lo(
|
|
7288
|
-
|
|
7288
|
+
y,
|
|
7289
7289
|
_n(uo(l))
|
|
7290
7290
|
);
|
|
7291
7291
|
r = ho(x.body, po, J, X);
|
|
@@ -7293,16 +7293,16 @@ const of = async (t) => {
|
|
|
7293
7293
|
}
|
|
7294
7294
|
_.isString(v) || (v = v ? "include" : "omit");
|
|
7295
7295
|
const w = "credentials" in Request.prototype;
|
|
7296
|
-
|
|
7297
|
-
...
|
|
7298
|
-
signal:
|
|
7296
|
+
b = new Request(e, {
|
|
7297
|
+
...E,
|
|
7298
|
+
signal: k,
|
|
7299
7299
|
method: n.toUpperCase(),
|
|
7300
7300
|
headers: h.normalize().toJSON(),
|
|
7301
7301
|
body: r,
|
|
7302
7302
|
duplex: "half",
|
|
7303
7303
|
credentials: w ? v : void 0
|
|
7304
7304
|
});
|
|
7305
|
-
let C = await fetch(
|
|
7305
|
+
let C = await fetch(b, E);
|
|
7306
7306
|
const A = xr && (f === "stream" || f === "response");
|
|
7307
7307
|
if (xr && (c || A && m)) {
|
|
7308
7308
|
const x = {};
|
|
@@ -7329,16 +7329,16 @@ const of = async (t) => {
|
|
|
7329
7329
|
status: C.status,
|
|
7330
7330
|
statusText: C.statusText,
|
|
7331
7331
|
config: t,
|
|
7332
|
-
request:
|
|
7332
|
+
request: b
|
|
7333
7333
|
});
|
|
7334
7334
|
});
|
|
7335
7335
|
} catch (w) {
|
|
7336
7336
|
throw m && m(), w && w.name === "TypeError" && /Load failed|fetch/i.test(w.message) ? Object.assign(
|
|
7337
|
-
new N("Network Error", N.ERR_NETWORK, t,
|
|
7337
|
+
new N("Network Error", N.ERR_NETWORK, t, b),
|
|
7338
7338
|
{
|
|
7339
7339
|
cause: w.cause || w
|
|
7340
7340
|
}
|
|
7341
|
-
) : N.from(w, w && w.code, t,
|
|
7341
|
+
) : N.from(w, w && w.code, t, b);
|
|
7342
7342
|
}
|
|
7343
7343
|
}), jr = {
|
|
7344
7344
|
http: Sd,
|
|
@@ -7510,8 +7510,8 @@ let Ye = class {
|
|
|
7510
7510
|
);
|
|
7511
7511
|
s && _.forEach(
|
|
7512
7512
|
["delete", "get", "head", "post", "put", "patch", "common"],
|
|
7513
|
-
(
|
|
7514
|
-
delete s[
|
|
7513
|
+
(b) => {
|
|
7514
|
+
delete s[b];
|
|
7515
7515
|
}
|
|
7516
7516
|
), n.headers = ce.concat(a, s);
|
|
7517
7517
|
const c = [];
|
|
@@ -7523,30 +7523,30 @@ let Ye = class {
|
|
|
7523
7523
|
this.interceptors.response.forEach(function(m) {
|
|
7524
7524
|
f.push(m.fulfilled, m.rejected);
|
|
7525
7525
|
});
|
|
7526
|
-
let h, v = 0,
|
|
7526
|
+
let h, v = 0, E;
|
|
7527
7527
|
if (!l) {
|
|
7528
|
-
const
|
|
7529
|
-
for (
|
|
7530
|
-
h = h.then(
|
|
7528
|
+
const b = [go.bind(this), void 0];
|
|
7529
|
+
for (b.unshift(...c), b.push(...f), E = b.length, h = Promise.resolve(n); v < E; )
|
|
7530
|
+
h = h.then(b[v++], b[v++]);
|
|
7531
7531
|
return h;
|
|
7532
7532
|
}
|
|
7533
|
-
|
|
7534
|
-
let
|
|
7535
|
-
for (v = 0; v <
|
|
7536
|
-
const
|
|
7533
|
+
E = c.length;
|
|
7534
|
+
let k = n;
|
|
7535
|
+
for (v = 0; v < E; ) {
|
|
7536
|
+
const b = c[v++], m = c[v++];
|
|
7537
7537
|
try {
|
|
7538
|
-
|
|
7539
|
-
} catch (
|
|
7540
|
-
m.call(this,
|
|
7538
|
+
k = b(k);
|
|
7539
|
+
} catch (y) {
|
|
7540
|
+
m.call(this, y);
|
|
7541
7541
|
break;
|
|
7542
7542
|
}
|
|
7543
7543
|
}
|
|
7544
7544
|
try {
|
|
7545
|
-
h = go.call(this,
|
|
7546
|
-
} catch (
|
|
7547
|
-
return Promise.reject(
|
|
7545
|
+
h = go.call(this, k);
|
|
7546
|
+
} catch (b) {
|
|
7547
|
+
return Promise.reject(b);
|
|
7548
7548
|
}
|
|
7549
|
-
for (v = 0,
|
|
7549
|
+
for (v = 0, E = f.length; v < E; )
|
|
7550
7550
|
h = h.then(f[v++], f[v++]);
|
|
7551
7551
|
return h;
|
|
7552
7552
|
}
|
|
@@ -7998,22 +7998,20 @@ class _f {
|
|
|
7998
7998
|
}
|
|
7999
7999
|
applyEventHandlers(e) {
|
|
8000
8000
|
return new Promise((n, r) => {
|
|
8001
|
-
var a, c
|
|
8001
|
+
var a, c;
|
|
8002
8002
|
const i = e != null && e.timeout && e.timeout > 0 ? e == null ? void 0 : e.timeout : 3e4, s = e != null && e.timeout ? setTimeout(() => r("Connection timeout"), i) : null;
|
|
8003
|
-
(a = this.call) == null || a.on("participant-
|
|
8004
|
-
|
|
8005
|
-
|
|
8006
|
-
var k, E;
|
|
8007
|
-
if (console.log("prtcp: ", f), !f.owner)
|
|
8003
|
+
(a = this.call) == null || a.on("participant-updated", ({ participant: l }) => {
|
|
8004
|
+
var v, E;
|
|
8005
|
+
if (!l.owner)
|
|
8008
8006
|
return;
|
|
8009
8007
|
this.dispatch("local_audio_change", this.call.localAudio());
|
|
8010
|
-
const { video:
|
|
8011
|
-
|
|
8012
|
-
}), this.call.on("error", (
|
|
8013
|
-
console.error("[SKD_ERROR]: ",
|
|
8014
|
-
}), (
|
|
8015
|
-
var
|
|
8016
|
-
this.restartIdleTimeout(),
|
|
8008
|
+
const { video: f, audio: h } = l.tracks;
|
|
8009
|
+
f.persistentTrack && (this.mediaStream.getVideoTracks().forEach((k) => this.mediaStream.removeTrack(k)), (v = this.mediaStream) == null || v.addTrack(f.persistentTrack)), h.persistentTrack && (this.mediaStream.getAudioTracks().forEach((k) => this.mediaStream.removeTrack(k)), (E = this.mediaStream) == null || E.addTrack(h.persistentTrack)), s && clearTimeout(s), f.persistentTrack && (this.inited = !0, this.drawUI(), n());
|
|
8010
|
+
}), this.call.on("error", (l) => {
|
|
8011
|
+
console.error("[SKD_ERROR]: ", l);
|
|
8012
|
+
}), (c = this.call) == null || c.on("app-message", ({ data: l }) => {
|
|
8013
|
+
var f;
|
|
8014
|
+
this.restartIdleTimeout(), l.type && ((f = this.handlers[l.type]) == null || f.forEach((h) => h(l)));
|
|
8017
8015
|
});
|
|
8018
8016
|
});
|
|
8019
8017
|
}
|
|
@@ -8024,6 +8022,7 @@ class _f {
|
|
|
8024
8022
|
if (this.inited)
|
|
8025
8023
|
return;
|
|
8026
8024
|
this.call = Lu.createCallObject({
|
|
8025
|
+
subscribeToTracksAutomatically: !0,
|
|
8027
8026
|
videoSource: !1,
|
|
8028
8027
|
audioSource: this.config.audioSource,
|
|
8029
8028
|
dailyConfig: {
|