@vindral/web-sdk 4.3.1-2-gddd5768ce → 4.3.1-3-gff362a88

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.
@@ -1,5 +1,5 @@
1
1
  import { n as e, t } from "./BsfwXDui.js";
2
- import { _ as n, a as r, c as i, d as a, f as o, g as s, h as c, i as ee, l, m as te, n as u, o as ne, p as re, r as ie, s as ae, t as oe, u as se, v as ce } from "./DC4PtdMI.js";
2
+ import { _ as n, a as r, c as i, d as a, f as o, g as s, h as c, i as ee, l, m as te, n as u, o as ne, p as re, r as ie, s as ae, t as oe, u as se, v as ce } from "./Yfs75xo5.js";
3
3
  import { M as le } from "./C01DcfYu.js";
4
4
  import { a as d, i as f, n as p, r as m, t as h } from "./B7hT-BKr.js";
5
5
  import { n as ue, t as de } from "./DeYmk5AL.js";
@@ -8045,7 +8045,9 @@ var Ig = (e) => {
8045
8045
  transportSelectionReason: void 0
8046
8046
  };
8047
8047
  }), e(this, "connect", () => {
8048
- S(Wg, this, !0), !x(Gg, this) && (x(Qg, this) === void 0 && S(Yg, this, performance.now()), S(Gg, this, b(a_, this, p_).call(this)));
8048
+ if (S(Wg, this, !0), x(Gg, this)) return;
8049
+ let e = performance.now();
8050
+ x(Qg, this) === void 0 && S(Yg, this, e), x(Xg, this) === void 0 && S(Xg, this, e), S(Gg, this, b(a_, this, p_).call(this));
8049
8051
  }), y(this, n_, () => {
8050
8052
  x(Qg, this) !== void 0 || x(Yg, this) === void 0 || !x(Wg, this) || (S(Qg, this, performance.now() - x(Yg, this)), S(Yg, this, void 0));
8051
8053
  }), e(this, "disconnect", (e = "Disconnect Requested") => {
@@ -8109,7 +8111,7 @@ var Ig = (e) => {
8109
8111
  get estimatedBandwidth() {
8110
8112
  return this.connectionImpl && "estimatedBandwidth" in this.connectionImpl && this.connectionImpl.estimatedBandwidth ? this.connectionImpl.estimatedBandwidth : Pg(this.rtt);
8111
8113
  }
8112
- get firstConnectionTime() {
8114
+ get firstConnectStartTime() {
8113
8115
  return x(Xg, this);
8114
8116
  }
8115
8117
  get lastConnectionTime() {
@@ -8148,7 +8150,7 @@ function p_() {
8148
8150
  } catch (e) {
8149
8151
  throw o = "cached_edge", e;
8150
8152
  }
8151
- x(o_, e).call(e), S(Jg, e, (a = x(Jg, e), a++, a)), S(Kg, e, 0), S(Zg, e, performance.now()), x(Xg, e) === void 0 && S(Xg, e, x(Zg, e)), x(n_, e).call(e), yield e.connectionImpl.closed(), e.logger.info("Connection closed"), o = "cached_edge";
8153
+ x(o_, e).call(e), S(Jg, e, (a = x(Jg, e), a++, a)), S(Kg, e, 0), S(Zg, e, performance.now()), x(n_, e).call(e), yield e.connectionImpl.closed(), e.logger.info("Connection closed"), o = "cached_edge";
8152
8154
  } catch (n) {
8153
8155
  e.logger.warn("Failed to connect", n);
8154
8156
  let r = t.shiftedEdge();
@@ -11046,7 +11048,7 @@ var Uv = class {
11046
11048
  let e = this.modules.canvasModule instanceof J_ ? !0 : void 0;
11047
11049
  return w({
11048
11050
  uptime: this.uptime,
11049
- version: "4.3.1-2-gddd5768ce",
11051
+ version: "4.3.1-3-gff362a88",
11050
11052
  clientId: this.clientId,
11051
11053
  sessionId: this.sessionId,
11052
11054
  channelId: this.channelId,
@@ -11078,7 +11080,7 @@ var Uv = class {
11078
11080
  this.logger.info("Buffer filled - starting playback", { currentTime: e }), this.playbackSource.currentTime = e, this.modules.sync.activateSyncAdjustments(), this.playbackSource.isActivated = !0;
11079
11081
  } else e === "drained" && this.playbackSource.isPaused && (this.playbackSource.isActivated = !1, this.modules.sync.deactivateSyncAdjustments());
11080
11082
  }), e(this, "timeToFirstFrame", () => {
11081
- let e = this.modules.playback.getFirstFrameTime(), t = this.modules.connection.firstConnectionTime;
11083
+ let e = this.modules.playback.getFirstFrameTime(), t = this.modules.connection.firstConnectStartTime;
11082
11084
  if (t !== void 0 && e !== void 0) return Math.round(e - t);
11083
11085
  }), this.options = new Uv(w(w({}, Cn), iy(r))), r.telemetryEnabled === void 0 && ["localhost", "127.0.0.1"].includes(location.hostname) && this.options.set("telemetryEnabled", !1);
11084
11086
  let o = {
package/core.d.ts CHANGED
@@ -1042,8 +1042,10 @@ export type Statistics = ModuleStatistics & ReturnType<UserAgentInformation["get
1042
1042
  */
1043
1043
  channelGroupId?: string;
1044
1044
  /**
1045
- * Time in milliseconds from instantiation to playback of video and audio being started.
1045
+ * Time in milliseconds from the first `connect()` call to playback of video and audio being started.
1046
1046
  * Note that an actual frame render often happens much quicker, but that is not counted as TTFF.
1047
+ * `timeToConnected` shares the same anchor, so `timeToFirstFrame - timeToConnected` is the
1048
+ * post-transport portion (player bootstrap, media flow, decode, buffer fill, render).
1047
1049
  */
1048
1050
  timeToFirstFrame?: number;
1049
1051
  /**
package/core.js CHANGED
@@ -1,3 +1,3 @@
1
- import { t as e } from "./DC4PtdMI.js";
1
+ import { t as e } from "./Yfs75xo5.js";
2
2
  import { a as t, c as n, i as r, l as i, n as a, o, r as s, s as c, u as l } from "./C01DcfYu.js";
3
3
  export { a as AUTHENTICATION_EXPIRED_CODE, s as AUTHENTICATION_FAILED_CODE, r as CHANNEL_NOT_FOUND_CODE, t as CONNECTION_FAILED_AFTER_RETRIES_CODE, o as CONNECTION_FAILED_CODE, c as DISCONNECTED_BY_EDGE, n as INACTIVITY_CODE, i as NO_INCOMING_DATA, e as Vindral, l as VindralError };
package/legacy.d.ts CHANGED
@@ -1057,8 +1057,10 @@ export type Statistics = ModuleStatistics & ReturnType<UserAgentInformation["get
1057
1057
  */
1058
1058
  channelGroupId?: string;
1059
1059
  /**
1060
- * Time in milliseconds from instantiation to playback of video and audio being started.
1060
+ * Time in milliseconds from the first `connect()` call to playback of video and audio being started.
1061
1061
  * Note that an actual frame render often happens much quicker, but that is not counted as TTFF.
1062
+ * `timeToConnected` shares the same anchor, so `timeToFirstFrame - timeToConnected` is the
1063
+ * post-transport portion (player bootstrap, media flow, decode, buffer fill, render).
1062
1064
  */
1063
1065
  timeToFirstFrame?: number;
1064
1066
  /**
package/legacy.es.js CHANGED
@@ -8959,7 +8959,9 @@ var ry, iy = /* @__PURE__ */ new WeakMap(), ay = /* @__PURE__ */ new WeakMap(),
8959
8959
  transportSelectionReason: void 0
8960
8960
  };
8961
8961
  }), p(this, "connect", () => {
8962
- O(ay, this, !0), !A(oy, this) && (A(py, this) === void 0 && O(uy, this, performance.now()), O(oy, this, E(by, this, Oy).call(this)));
8962
+ if (O(ay, this, !0), A(oy, this)) return;
8963
+ let e = performance.now();
8964
+ A(py, this) === void 0 && O(uy, this, e), A(dy, this) === void 0 && O(dy, this, e), O(oy, this, E(by, this, Oy).call(this));
8963
8965
  }), w(this, _y, () => {
8964
8966
  A(py, this) !== void 0 || A(uy, this) === void 0 || !A(ay, this) || (O(py, this, performance.now() - A(uy, this)), O(uy, this, void 0));
8965
8967
  }), p(this, "disconnect", (e = "Disconnect Requested") => {
@@ -9023,7 +9025,7 @@ var ry, iy = /* @__PURE__ */ new WeakMap(), ay = /* @__PURE__ */ new WeakMap(),
9023
9025
  get estimatedBandwidth() {
9024
9026
  return this.connectionImpl && "estimatedBandwidth" in this.connectionImpl && this.connectionImpl.estimatedBandwidth ? this.connectionImpl.estimatedBandwidth : Yv(this.rtt);
9025
9027
  }
9026
- get firstConnectionTime() {
9028
+ get firstConnectStartTime() {
9027
9029
  return A(dy, this);
9028
9030
  }
9029
9031
  get lastConnectionTime() {
@@ -9062,7 +9064,7 @@ function Oy() {
9062
9064
  } catch (e) {
9063
9065
  throw o = "cached_edge", e;
9064
9066
  }
9065
- A(xy, e).call(e), O(ly, e, (a = A(ly, e), a++, a)), O(sy, e, 0), O(fy, e, performance.now()), A(dy, e) === void 0 && O(dy, e, A(fy, e)), A(_y, e).call(e), yield e.connectionImpl.closed(), e.logger.info("Connection closed"), o = "cached_edge";
9067
+ A(xy, e).call(e), O(ly, e, (a = A(ly, e), a++, a)), O(sy, e, 0), O(fy, e, performance.now()), A(_y, e).call(e), yield e.connectionImpl.closed(), e.logger.info("Connection closed"), o = "cached_edge";
9066
9068
  } catch (n) {
9067
9069
  e.logger.warn("Failed to connect", n);
9068
9070
  let r = t.shiftedEdge();
@@ -12545,7 +12547,7 @@ var Xx = /* @__PURE__ */ new WeakMap(), Zx = /* @__PURE__ */ new WeakMap(), Qx =
12545
12547
  let e = this.modules.canvasModule instanceof Lb ? !0 : void 0;
12546
12548
  return R({
12547
12549
  uptime: this.uptime,
12548
- version: "4.3.1-2-gddd5768ce",
12550
+ version: "4.3.1-3-gff362a88",
12549
12551
  clientId: this.clientId,
12550
12552
  sessionId: this.sessionId,
12551
12553
  channelId: this.channelId,
@@ -12577,7 +12579,7 @@ var Xx = /* @__PURE__ */ new WeakMap(), Zx = /* @__PURE__ */ new WeakMap(), Qx =
12577
12579
  this.logger.info("Buffer filled - starting playback", { currentTime: e }), this.playbackSource.currentTime = e, this.modules.sync.activateSyncAdjustments(), this.playbackSource.isActivated = !0;
12578
12580
  } else e === "drained" && this.playbackSource.isPaused && (this.playbackSource.isActivated = !1, this.modules.sync.deactivateSyncAdjustments());
12579
12581
  }), p(this, "timeToFirstFrame", () => {
12580
- let e = this.modules.playback.getFirstFrameTime(), t = this.modules.connection.firstConnectionTime;
12582
+ let e = this.modules.playback.getFirstFrameTime(), t = this.modules.connection.firstConnectStartTime;
12581
12583
  if (t !== void 0 && e !== void 0) return Math.round(e - t);
12582
12584
  }), this.options = new Mx(R(R({}, yr), qx(t))), t.telemetryEnabled === void 0 && ["localhost", "127.0.0.1"].includes(location.hostname) && this.options.set("telemetryEnabled", !1);
12583
12585
  let i = {