@cloudflare/realtimekit 0.5.0-staging.96 → 0.5.0-staging.97

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
@@ -27530,21 +27530,25 @@ tr = /* @__PURE__ */ new WeakMap(), sr = /* @__PURE__ */ new WeakMap(), ms = /*
27530
27530
  const e = Math.log10(t);
27531
27531
  return Math.round(e);
27532
27532
  }, g(fo, lc), g(fo, ml);
27533
- const YO = () => {
27534
- const s = new window.AudioContext(), t = s.createOscillator();
27535
- t.type = "triangle", t.frequency.setValueAtTime(20, s.currentTime);
27536
- const e = s.createGain();
27537
- e.gain.setValueAtTime(0, s.currentTime), t.connect(e);
27538
- const r = s.createMediaStreamDestination();
27539
- return e.connect(r), t.start(), r.stream.getAudioTracks()[0];
27540
- }, QO = () => {
27541
- var r, i;
27542
- const s = new MediaStream().getVideoTracks()[0], t = document.createElement("canvas");
27543
- t.height = (r = s == null ? void 0 : s.getSettings().height) != null ? r : 720, t.width = (i = s == null ? void 0 : s.getSettings().width) != null ? i : 1280;
27544
- const e = t.getContext("2d");
27545
- return e.fillStyle = "black", e.fillRect(0, 0, t.width, t.height), setInterval(() => {
27546
- e.fillStyle = "black", e.fillRect(0, 0, t.width, t.height);
27547
- }, 1e3), t.captureStream().getVideoTracks()[0];
27533
+ const YO = (s = false) => {
27534
+ const t = new window.AudioContext(), e = t.createOscillator();
27535
+ e.type = "triangle", e.frequency.setValueAtTime(20, t.currentTime);
27536
+ const r = t.createGain();
27537
+ r.gain.setValueAtTime(0, t.currentTime), e.connect(r);
27538
+ const i = t.createMediaStreamDestination();
27539
+ r.connect(i), e.start();
27540
+ const n = i.stream.getAudioTracks()[0];
27541
+ return n.enabled = s, n;
27542
+ }, QO = (s = false) => {
27543
+ var n, a;
27544
+ const t = new MediaStream().getVideoTracks()[0], e = document.createElement("canvas");
27545
+ e.height = (n = t == null ? void 0 : t.getSettings().height) != null ? n : 720, e.width = (a = t == null ? void 0 : t.getSettings().width) != null ? a : 1280;
27546
+ const r = e.getContext("2d");
27547
+ r.fillStyle = "black", r.fillRect(0, 0, e.width, e.height), setInterval(() => {
27548
+ r.fillStyle = "black", r.fillRect(0, 0, e.width, e.height);
27549
+ }, 1e3);
27550
+ const i = e.captureStream().getVideoTracks()[0];
27551
+ return i.enabled = s, i;
27548
27552
  };
27549
27553
  var XO = Object.defineProperty, ZO = Object.getOwnPropertyDescriptor, le = (s, t, e, r) => {
27550
27554
  for (var i = r > 1 ? void 0 : r ? ZO(t, e) : t, n = s.length - 1, a; n >= 0; n--)
@@ -30705,7 +30709,7 @@ let si = (Pf = class {
30705
30709
  var c;
30706
30710
  const n = Ji.createContext(t, e), a = N(N({}, YR), e == null ? void 0 : e.modules);
30707
30711
  return n.setValue("peerId", t), n.setValue("modules", a), 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", (c = e.overrides) != null ? c : {}), n.setValue("env", QR({ baseURI: i.baseURI })), n.setValue("defaults", e.defaults || { audio: true, video: true }), n.setValue("onError", e.onError || (() => {
30708
- })), n.setValue("cachedUserDetails", ys(e.cachedUserDetails)), n.setValue("sdkVersion", "2.5.0-staging.96"), n;
30712
+ })), n.setValue("cachedUserDetails", ys(e.cachedUserDetails)), n.setValue("sdkVersion", "2.5.0-staging.97"), n;
30709
30713
  }
30710
30714
  join() {
30711
30715
  return u(this, null, function* () {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cloudflare/realtimekit",
3
- "version": "0.5.0-staging.96",
3
+ "version": "0.5.0-staging.97",
4
4
  "description": "A real-time video and audio SDK for building custom, collaborative communication experiences.",
5
5
  "main": "./dist/index.cjs.js",
6
6
  "module": "./dist/index.es.js",