@cloudflare/realtimekit 1.1.7-staging.2 → 1.1.7-staging.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/index.es.js CHANGED
@@ -19396,7 +19396,7 @@ class n0 {
19396
19396
  };
19397
19397
  });
19398
19398
  h(this, "getAudioConstraints", (t2) => {
19399
- var n, o, c, d, l, p, f, S;
19399
+ var n, o, c, d, l, p, f;
19400
19400
  const e2 = {}, r = (n = a(this, ki)) == null ? void 0 : n.audio, i = r != null && r.enableStereo ? 2 : 1;
19401
19401
  return Te.isFirefox() || Te.isWebKitBased() ? (e2.audio = {
19402
19402
  deviceId: t2,
@@ -19404,15 +19404,12 @@ class n0 {
19404
19404
  echoCancellation: (c = r == null ? void 0 : r.echoCancellation) != null ? c : true,
19405
19405
  noiseSuppression: (d = r == null ? void 0 : r.noiseSupression) != null ? d : true,
19406
19406
  channelCount: i
19407
- }, e2) : (e2.audio = {}, e2.audio.optional = [
19408
- t2 ? { sourceId: t2 } : { sourceId: "default" },
19409
- { channelCount: i },
19410
- { echoCancellation: (l = r == null ? void 0 : r.echoCancellation) != null ? l : true },
19411
- { googEchoCancellation: (p = r == null ? void 0 : r.echoCancellation) != null ? p : true },
19412
- { googAutoGainControl: (f = r == null ? void 0 : r.autoGainControl) != null ? f : true },
19413
- { googNoiseSuppression: (S = r == null ? void 0 : r.noiseSupression) != null ? S : true },
19414
- { googHighpassFilter: true }
19415
- ], e2);
19407
+ }, e2) : (e2.audio = {
19408
+ autoGainControl: (l = r == null ? void 0 : r.autoGainControl) != null ? l : true,
19409
+ echoCancellation: (p = r == null ? void 0 : r.echoCancellation) != null ? p : true,
19410
+ noiseSuppression: (f = r == null ? void 0 : r.noiseSupression) != null ? f : true,
19411
+ channelCount: i
19412
+ }, t2 && t2 !== "default" && (e2.audio.deviceId = { exact: t2 }), e2);
19416
19413
  });
19417
19414
  h(this, "getVideoConstraints", (t2) => {
19418
19415
  var n, o, c, d;
@@ -20001,12 +19998,12 @@ let Ld = class extends Jn {
20001
19998
  });
20002
19999
  }
20003
20000
  getCurrentDeviceId() {
20004
- var e, r;
20001
+ var e, r, i, n;
20005
20002
  const { kind: t } = this.mediaTrack;
20006
20003
  switch (t) {
20007
20004
  case "audio": {
20008
- const i = this.mediaTrack.getConstraints();
20009
- return this.userSelectedDevice ? (r = (e = i == null ? void 0 : i.deviceId) != null ? e : i == null ? void 0 : i.advanced[0].deviceId) != null ? r : this.mediaTrack.getSettings().deviceId : this.mediaTrack.getSettings().deviceId;
20005
+ const o = this.mediaTrack.getConstraints();
20006
+ return this.userSelectedDevice ? (n = (i = (r = o == null ? void 0 : o.deviceId) != null ? r : (e = o == null ? void 0 : o.advanced) == null ? void 0 : e[0].deviceId) != null ? i : this.mediaTrack.getSettings().deviceId) != null ? n : "default" : this.mediaTrack.getSettings().deviceId;
20010
20007
  }
20011
20008
  default:
20012
20009
  return this.mediaTrack.getSettings().deviceId;
@@ -30504,7 +30501,7 @@ let ri = (Wg = class {
30504
30501
  video: true
30505
30502
  };
30506
30503
  return n.setValue("options", e), n.setValue("peerId", t), n.setValue("modules", o), n.setValue("sdkName", "web-core"), n.setValue("meetingId", r), n.setValue("apiBase", i.apiBase), n.setValue("baseURI", i.baseURI), n.setValue("userId", i.participantId), n.setValue("organizationId", i.orgId), n.setValue("authToken", e.authToken), n.setValue("overrides", (d = e.overrides) != null ? d : {}), n.setValue("env", PC({ baseURI: i.baseURI })), n.setValue("defaults", c), n.setValue("onError", e.onError || (() => {
30507
- })), n.setValue("cachedUserDetails", _s(e.cachedUserDetails)), n.setValue("sdkVersion", "3.1.7-staging.2"), (l = e.modules) != null && l.experimentalAudioPlayback && n.setValue("audioPlayback", new oO()), n;
30504
+ })), n.setValue("cachedUserDetails", _s(e.cachedUserDetails)), n.setValue("sdkVersion", "3.1.7-staging.3"), (l = e.modules) != null && l.experimentalAudioPlayback && n.setValue("audioPlayback", new oO()), n;
30508
30505
  }
30509
30506
  join() {
30510
30507
  return u(this, null, function* () {