@voicenter-team/opensips-js 1.0.119 → 1.0.121
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/opensips-js.cjs.js +1 -1
- package/dist/opensips-js.es.js +16 -15
- package/dist/opensips-js.iife.js +1 -1
- package/dist/opensips-js.umd.js +1 -1
- package/package.json +1 -1
package/dist/opensips-js.es.js
CHANGED
@@ -82422,9 +82422,9 @@ class Wy extends Dw {
|
|
82422
82422
|
}, this.selectors.document || (this.selectors.document = document);
|
82423
82423
|
}
|
82424
82424
|
createVideoElement() {
|
82425
|
-
const e =
|
82425
|
+
const e = document.createElement("video");
|
82426
82426
|
e.setAttribute("id", this.selectors.videoElement), e.setAttribute("autoplay", ""), e.style.setProperty("visibility", "hidden"), e.style.setProperty("width", "auto"), e.style.setProperty("height", "auto"), this.video = e;
|
82427
|
-
const t =
|
82427
|
+
const t = document.createElement("div");
|
82428
82428
|
t.classList.add(this.selectors.videoElementContainer), t.style.setProperty("display", "none"), t.appendChild(e), this.wrapperEl = t, this.selectors.document.body ? this.selectors.document.body.appendChild(t) : this.selectors.document.appendChild(t);
|
82429
82429
|
}
|
82430
82430
|
getAspectRatioDimensions(e, t) {
|
@@ -82450,26 +82450,27 @@ class Wy extends Dw {
|
|
82450
82450
|
n.style.setProperty("position", "relative"), n.style.setProperty("margin", "auto 0");
|
82451
82451
|
const { width: i, height: s } = this.getAspectRatioDimensions(e, t);
|
82452
82452
|
let a = i, o = s;
|
82453
|
+
const u = this.selectors.document.getElementById(this.selectors.drawerContainer);
|
82453
82454
|
this.screenShareKonvaDrawer = new Ub({
|
82454
|
-
container:
|
82455
|
+
container: u,
|
82455
82456
|
width: a,
|
82456
82457
|
height: o
|
82457
82458
|
});
|
82458
|
-
const
|
82459
|
-
this.screenShareKonvaDrawer.initFreeDrawing(
|
82460
|
-
const
|
82461
|
-
|
82462
|
-
const
|
82463
|
-
const { width:
|
82464
|
-
a =
|
82459
|
+
const c = this.screenShareKonvaDrawer.addLayer();
|
82460
|
+
this.screenShareKonvaDrawer.initFreeDrawing(c);
|
82461
|
+
const d = this.selectors.document.getElementById(this.selectors.drawerContainer), p = d.querySelector("canvas"), m = d.querySelector(".konvajs-content"), _ = this.selectors.document.getElementById(this.selectors.compositeCanvas);
|
82462
|
+
_.style.setProperty("position", "absolute"), _.style.setProperty("top", "0"), _.style.setProperty("left", "0");
|
82463
|
+
const y = _.getContext("2d"), b = () => {
|
82464
|
+
const { width: x, height: E } = this.getAspectRatioDimensions(e, t);
|
82465
|
+
a = x, o = E, p.width = x, p.height = E, p.style.width = `${x}px`, p.style.height = `${E}px`, m.style.width = `${x}px`, m.style.height = `${E}px`, n.style.height = `${E}px`, _.width = x, _.height = E;
|
82465
82466
|
};
|
82466
|
-
|
82467
|
-
|
82467
|
+
b(), window.addEventListener("resize", () => {
|
82468
|
+
b(), this.screenShareKonvaDrawer.addWakeupLine(c);
|
82468
82469
|
});
|
82469
|
-
const
|
82470
|
-
|
82470
|
+
const T = this.video, w = () => {
|
82471
|
+
y.drawImage(T, 0, 0, a, o), y.drawImage(p, 0, 0, a, o), requestAnimationFrame(w);
|
82471
82472
|
};
|
82472
|
-
return
|
82473
|
+
return w(), _.captureStream(30);
|
82473
82474
|
}
|
82474
82475
|
/**
|
82475
82476
|
* Stops stream processing
|