@beterdichtbij/component-library 0.0.0-dev-timo.12 → 0.0.0-dev-timo.14
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/bd-component-lib.cjs.js +10 -10
- package/dist/bd-component-lib.es.js +163 -162
- package/dist/bd-component-lib.umd.js +1 -1
- package/package.json +1 -1
|
@@ -32223,85 +32223,85 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32223
32223
|
deviceManager: null,
|
|
32224
32224
|
incomingCall: null,
|
|
32225
32225
|
call: null
|
|
32226
|
-
}), ue = A(null), de = A(null), fe = A(null), pe = A(!0), me = A(!1), he = A(null), ge = A(null), _e = A(null), ve = A(0), ye = A(0), be = A(null), xe = A(!1), Ce = A(""), we = A(""), Te = A(null), Ee = A(null), De = A(!0), Oe = A(!1), ke = A(!1), Ae = A(!1), je = A(null), Me = A(null), Ne = A(null), Pe = A(null), L = null, Fe = null, Ie = null, Le = a(() => Oe.value ||
|
|
32226
|
+
}), ue = A(null), de = A(null), fe = A(null), pe = A(!0), me = A(!1), he = A(null), ge = A(null), _e = A(null), ve = A(0), ye = A(0), be = A(null), xe = A(!1), Ce = A(""), we = A(""), Te = A(null), Ee = A(null), De = A(!0), Oe = A(!1), ke = A(!1), Ae = A(!1), je = A(null), Me = A(null), Ne = A(null), Pe = A(null), L = null, Fe = null, Ie = null, Le = a(() => Oe.value || it.value), Re = a(() => {
|
|
32227
32227
|
switch (ve.value) {
|
|
32228
|
-
case 0: return
|
|
32229
|
-
case 1: return
|
|
32230
|
-
default: return
|
|
32228
|
+
case 0: return Xe.value.hasNoAvailableCamera;
|
|
32229
|
+
case 1: return Xe.value.hasOneAvailableCamera;
|
|
32230
|
+
default: return Xe.value.hasMultipleAvailableCameras;
|
|
32231
32231
|
}
|
|
32232
|
-
}),
|
|
32232
|
+
}), ze = a(() => {
|
|
32233
32233
|
let e = navigator.userAgent;
|
|
32234
32234
|
return /Mobi/.test(e) && !te.value;
|
|
32235
|
-
}),
|
|
32235
|
+
}), Be = a(() => {
|
|
32236
32236
|
let e = navigator.userAgent, t = e.indexOf("Android") !== -1, n = /Mobi/.test(e), r = /iPad|iPhone|iPod/.test(e) && !window.MSStream;
|
|
32237
32237
|
return !(t && n || r);
|
|
32238
|
-
}),
|
|
32238
|
+
}), Ve = a(() => !j.value?.video && it.value), He = a(() => !j.value?.audio && it.value), Ue = a(() => M.value === i.Declined ? "incoming--declined" : "incoming--loading"), We = a(() => {
|
|
32239
32239
|
switch (se.value) {
|
|
32240
32240
|
case 0: return "weak";
|
|
32241
32241
|
case 1: return "steady";
|
|
32242
32242
|
case 2: return "strong";
|
|
32243
32243
|
default: return null;
|
|
32244
32244
|
}
|
|
32245
|
-
}),
|
|
32245
|
+
}), Ge = a(() => {
|
|
32246
32246
|
switch (se.value) {
|
|
32247
32247
|
case 0: return O.value.signalStrength.weak;
|
|
32248
32248
|
case 1: return O.value.signalStrength.steady;
|
|
32249
32249
|
case 2: return O.value.signalStrength.strong;
|
|
32250
32250
|
default: return null;
|
|
32251
32251
|
}
|
|
32252
|
-
}),
|
|
32253
|
-
function
|
|
32252
|
+
}), Ke = a(() => O.value.videoCallTemplate || O.value), qe = a(() => Ke.value.actions || Ke.value), Je = a(() => Ke.value.help || Ke.value), Ye = a(() => Ke.value.permissions || Ke.value), Xe = a(() => Ke.value.cameraAvailability || Ke.value), Ze = a(() => te.value ? qe.value.stopSharingScreen : qe.value.shareScreen), Qe = a(() => Je.value.placeholderSettingsHelpTitle), $e = a(() => Je.value.placeholderSettingsHelpMessage), et = a(() => M.value === i.Declined), tt = a(() => M.value === i.HangedUp), nt = a(() => M.value === i.Connected), rt = a(() => !nt.value), it = a(() => M.value === i.DevicePermissionDenied), at = a(() => Ke.value.statusTextMessage || Ke.value), ot = a(() => Ke.value.statusDetailMessage || Ke.value), st = a(() => x.participantRole), ct = a(() => ke.value ? qe.value.microphoneUnmute : qe.value.microphoneMute), lt = a(() => Oe.value ? qe.value.cameraOn : qe.value.cameraOff), ut = a(() => pe.value ? qe.value.backgroundBlurUnavailable : De.value ? qe.value.backgroundBlur : qe.value.backgroundUnblur);
|
|
32253
|
+
function dt(e) {
|
|
32254
32254
|
if (typeof e != "string") return e;
|
|
32255
|
-
let t = e.replaceAll("{participantRole}",
|
|
32255
|
+
let t = e.replaceAll("{participantRole}", st.value);
|
|
32256
32256
|
return t && t.charAt(0).toLocaleUpperCase() + t.slice(1);
|
|
32257
32257
|
}
|
|
32258
|
-
let
|
|
32258
|
+
let ft = a(() => {
|
|
32259
32259
|
switch (M.value) {
|
|
32260
|
-
case i.Initializing: return
|
|
32261
|
-
case i.Dialing: return
|
|
32262
|
-
case i.Ringing: return
|
|
32263
|
-
case i.Answered: return
|
|
32264
|
-
case i.Connected: return
|
|
32265
|
-
case i.Declined: return
|
|
32266
|
-
case i.HangedUp: return
|
|
32267
|
-
case i.DevicePermissionDenied: return
|
|
32268
|
-
}
|
|
32269
|
-
}),
|
|
32260
|
+
case i.Initializing: return dt(at.value.initializing);
|
|
32261
|
+
case i.Dialing: return dt(at.value.dialing);
|
|
32262
|
+
case i.Ringing: return dt(at.value.ringing);
|
|
32263
|
+
case i.Answered: return dt(at.value.answered);
|
|
32264
|
+
case i.Connected: return dt(at.value.connected);
|
|
32265
|
+
case i.Declined: return dt(at.value.videoCallDeclined);
|
|
32266
|
+
case i.HangedUp: return dt(at.value.videoCallHangedUp);
|
|
32267
|
+
case i.DevicePermissionDenied: return dt(at.value.devicePermissionDenied);
|
|
32268
|
+
}
|
|
32269
|
+
}), pt = a(() => Ce.value || ft.value), mt = a(() => we.value);
|
|
32270
32270
|
ne(() => {
|
|
32271
|
-
|
|
32271
|
+
tn(), gt(), Ee.value = window.setInterval(kt, 5e3);
|
|
32272
32272
|
}), ie(() => {
|
|
32273
|
-
be.value && window.clearInterval(be.value), Ee.value && window.clearInterval(Ee.value),
|
|
32273
|
+
be.value && window.clearInterval(be.value), Ee.value && window.clearInterval(Ee.value), ht(), $t();
|
|
32274
32274
|
});
|
|
32275
|
-
function
|
|
32275
|
+
function ht() {
|
|
32276
32276
|
L &&= (window.clearTimeout(L), null), Fe &&= (window.clearTimeout(Fe), null), Ie &&= (window.clearTimeout(Ie), null);
|
|
32277
32277
|
}
|
|
32278
|
-
function
|
|
32279
|
-
|
|
32280
|
-
M.value === i.Initializing && (Ce.value =
|
|
32278
|
+
function gt() {
|
|
32279
|
+
ht(), M.value === i.Initializing ? L = window.setTimeout(() => {
|
|
32280
|
+
M.value === i.Initializing && (Ce.value = dt(at.value.callNotDelivered), we.value = dt(ot.value.callNotDeliveredDetail));
|
|
32281
32281
|
}, 3e4) : M.value === i.Dialing ? Fe = window.setTimeout(() => {
|
|
32282
|
-
M.value === i.Dialing && (Ce.value = "", we.value =
|
|
32282
|
+
M.value === i.Dialing && (Ce.value = "", we.value = dt(ot.value.notAnsweredDetail));
|
|
32283
32283
|
}, 1e4) : M.value === i.Connected && (Ie = window.setTimeout(() => {
|
|
32284
|
-
M.value === i.Connected && (we.value =
|
|
32284
|
+
M.value === i.Connected && (we.value = dt(ot.value.noVideoHint));
|
|
32285
32285
|
}, 5e3));
|
|
32286
32286
|
}
|
|
32287
|
-
function
|
|
32287
|
+
function _t(e) {
|
|
32288
32288
|
[
|
|
32289
32289
|
i.Declined,
|
|
32290
32290
|
i.HangedUp,
|
|
32291
32291
|
i.DevicePermissionDenied
|
|
32292
|
-
].includes(M.value) || (M.value = e, Ce.value = "", we.value = "",
|
|
32292
|
+
].includes(M.value) || (M.value = e, Ce.value = "", we.value = "", gt());
|
|
32293
32293
|
}
|
|
32294
|
-
async function
|
|
32294
|
+
async function vt() {
|
|
32295
32295
|
if (N.call) try {
|
|
32296
32296
|
ke.value ? await N.call.unmute() : await N.call.mute(), ke.value = !ke.value, ke.value || (Ae.value = !1);
|
|
32297
32297
|
} catch (e) {
|
|
32298
32298
|
console.error("Unable to toggle microphone", e);
|
|
32299
32299
|
}
|
|
32300
32300
|
}
|
|
32301
|
-
async function
|
|
32301
|
+
async function yt() {
|
|
32302
32302
|
if (N.call) try {
|
|
32303
32303
|
if (Oe.value) {
|
|
32304
|
-
let e = ue.value || await
|
|
32304
|
+
let e = ue.value || await Ft();
|
|
32305
32305
|
if (!e) return;
|
|
32306
32306
|
await N.call.startVideo(e), ue.value = e, Oe.value = !1, await ee();
|
|
32307
32307
|
let t = Ne.value;
|
|
@@ -32318,7 +32318,7 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32318
32318
|
console.error("Unable to toggle camera", e);
|
|
32319
32319
|
}
|
|
32320
32320
|
}
|
|
32321
|
-
async function
|
|
32321
|
+
async function bt() {
|
|
32322
32322
|
if (!(pe.value || me.value || !de.value || !fe.value)) {
|
|
32323
32323
|
me.value = !0;
|
|
32324
32324
|
try {
|
|
@@ -32330,96 +32330,96 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32330
32330
|
}
|
|
32331
32331
|
}
|
|
32332
32332
|
}
|
|
32333
|
+
function xt() {
|
|
32334
|
+
_t(i.Declined);
|
|
32335
|
+
}
|
|
32333
32336
|
function St() {
|
|
32334
|
-
|
|
32337
|
+
_t(i.Answered);
|
|
32335
32338
|
}
|
|
32336
32339
|
function Ct() {
|
|
32337
|
-
|
|
32340
|
+
M.value !== i.Connected && _t(i.Dialing);
|
|
32338
32341
|
}
|
|
32339
32342
|
function wt() {
|
|
32340
|
-
M.value !== i.
|
|
32343
|
+
M.value !== i.DevicePermissionDenied && !x.isCallee && Nt();
|
|
32341
32344
|
}
|
|
32342
|
-
function Tt() {
|
|
32343
|
-
|
|
32345
|
+
async function Tt() {
|
|
32346
|
+
_t(i.HangedUp), j.value.video && Zt();
|
|
32344
32347
|
}
|
|
32345
|
-
|
|
32346
|
-
|
|
32348
|
+
function Et(e) {
|
|
32349
|
+
_t(i.HangedUp), we.value = Vt(e);
|
|
32347
32350
|
}
|
|
32348
|
-
function Dt(
|
|
32349
|
-
|
|
32351
|
+
function Dt() {
|
|
32352
|
+
Ce.value = dt(at.value.signalHold), we.value = dt(ot.value.signalHoldDetail);
|
|
32350
32353
|
}
|
|
32351
32354
|
function Ot() {
|
|
32352
|
-
Ce.value = ft(ot.value.signalHold), we.value = ft(st.value.signalHoldDetail);
|
|
32353
|
-
}
|
|
32354
|
-
function kt() {
|
|
32355
32355
|
Te.value = /* @__PURE__ */ new Date();
|
|
32356
32356
|
}
|
|
32357
|
-
function
|
|
32357
|
+
function kt() {
|
|
32358
32358
|
if (!Te.value || M.value === i.HangedUp) return;
|
|
32359
32359
|
let e = /* @__PURE__ */ new Date(), t = new Date(Te.value), n = Math.abs(e.getTime() - t.getTime()), r = Math.ceil(n / 1e3);
|
|
32360
|
-
r >= 40 ? (Ce.value =
|
|
32360
|
+
r >= 40 ? (Ce.value = at.value.connectionIssues, we.value = ot.value.connectionIssuesStrong, se.value = 0) : r > 20 && (Ce.value = at.value.connectionIssues, we.value = ot.value.connectionIssuesMedium, se.value = 1);
|
|
32361
32361
|
}
|
|
32362
|
-
async function
|
|
32363
|
-
await
|
|
32362
|
+
async function At(e) {
|
|
32363
|
+
await en(), N.client = w(new f());
|
|
32364
32364
|
let t = new y(e);
|
|
32365
32365
|
if (N.agent = w(await N.client.createCallAgent(t)), N.deviceManager = await N.client.getDeviceManager(), j.value = await N.deviceManager.askDevicePermission({
|
|
32366
32366
|
video: !0,
|
|
32367
32367
|
audio: !0
|
|
32368
|
-
}), (await N.deviceManager.getCameras()).length || (j.value.video = !1), be.value = window.setInterval(
|
|
32369
|
-
|
|
32368
|
+
}), (await N.deviceManager.getCameras()).length || (j.value.video = !1), be.value = window.setInterval(Zt, 5e3), !j.value.audio || !j.value.video) {
|
|
32369
|
+
_t(i.DevicePermissionDenied);
|
|
32370
32370
|
return;
|
|
32371
32371
|
}
|
|
32372
|
-
N.agent.on("incomingCall",
|
|
32372
|
+
N.agent.on("incomingCall", jt), x.isCallee ? S("ready") : S("start-call");
|
|
32373
32373
|
}
|
|
32374
|
-
async function
|
|
32374
|
+
async function jt(e) {
|
|
32375
32375
|
if (!xe.value) try {
|
|
32376
|
-
xe.value = !0, N.incomingCall = e.incomingCall, await
|
|
32376
|
+
xe.value = !0, N.incomingCall = e.incomingCall, await Pt();
|
|
32377
32377
|
} catch (e) {
|
|
32378
32378
|
console.log("error occured during starting call", e);
|
|
32379
32379
|
} finally {
|
|
32380
32380
|
xe.value = !1;
|
|
32381
32381
|
}
|
|
32382
32382
|
}
|
|
32383
|
-
async function
|
|
32384
|
-
let e = await
|
|
32383
|
+
async function Mt() {
|
|
32384
|
+
let e = await Ft();
|
|
32385
32385
|
return ue.value = e, e ? { localVideoStreams: [e] } : void 0;
|
|
32386
32386
|
}
|
|
32387
|
-
async function
|
|
32387
|
+
async function Nt() {
|
|
32388
32388
|
try {
|
|
32389
|
-
|
|
32390
|
-
let e = { videoOptions: await
|
|
32391
|
-
N.call = N.agent.startCall(t, e),
|
|
32389
|
+
_t(i.Dialing);
|
|
32390
|
+
let e = { videoOptions: await Mt() }, t = [{ communicationUserId: x.participant.videoCallIdentityId }];
|
|
32391
|
+
N.call = N.agent.startCall(t, e), Lt(), await Rt(), It();
|
|
32392
32392
|
} catch (e) {
|
|
32393
32393
|
console.error(e);
|
|
32394
32394
|
}
|
|
32395
32395
|
}
|
|
32396
|
-
async function
|
|
32397
|
-
let e = await
|
|
32396
|
+
async function Pt() {
|
|
32397
|
+
let e = await Mt();
|
|
32398
32398
|
try {
|
|
32399
32399
|
N.call = await N.incomingCall.accept({ videoOptions: e });
|
|
32400
32400
|
} catch (e) {
|
|
32401
32401
|
console.error("Error occurred during accepting call", e);
|
|
32402
32402
|
}
|
|
32403
|
-
|
|
32403
|
+
Lt(), await Rt(), It();
|
|
32404
32404
|
}
|
|
32405
|
-
async function
|
|
32405
|
+
async function Ft() {
|
|
32406
32406
|
let e = (await N.deviceManager.getCameras())[0];
|
|
32407
32407
|
if (e) return new g(e);
|
|
32408
32408
|
console.error("No camera device found on the system");
|
|
32409
32409
|
}
|
|
32410
|
-
function
|
|
32411
|
-
N.call.on("stateChanged",
|
|
32412
|
-
e.added.forEach(
|
|
32413
|
-
}), N.call.remoteParticipants.forEach(
|
|
32414
|
-
e.added.forEach(
|
|
32410
|
+
function It() {
|
|
32411
|
+
N.call.on("stateChanged", Bt), N.call.on("localVideoStreamsUpdated", (e) => {
|
|
32412
|
+
e.added.forEach(Ut), e.removed.forEach(Ht);
|
|
32413
|
+
}), N.call.remoteParticipants.forEach(Gt), N.call.on("remoteParticipantsUpdated", (e) => {
|
|
32414
|
+
e.added.forEach(Gt);
|
|
32415
32415
|
}), N.call.on("isScreenSharingOnChanged", () => {
|
|
32416
32416
|
te.value = N.call.isScreenSharingOn;
|
|
32417
32417
|
});
|
|
32418
32418
|
}
|
|
32419
|
-
function
|
|
32420
|
-
le.value = N.call.feature(_.UserFacingDiagnostics), le.value.media.on("diagnosticChanged",
|
|
32419
|
+
function Lt() {
|
|
32420
|
+
le.value = N.call.feature(_.UserFacingDiagnostics), le.value.media.on("diagnosticChanged", zt), le.value.network.on("diagnosticChanged", zt);
|
|
32421
32421
|
}
|
|
32422
|
-
async function
|
|
32422
|
+
async function Rt() {
|
|
32423
32423
|
if (!(!ue.value || de.value)) try {
|
|
32424
32424
|
let e = ue.value.feature(_.VideoEffects), t = new b();
|
|
32425
32425
|
if (!await e.isSupported(t)) return;
|
|
@@ -32430,41 +32430,41 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32430
32430
|
console.error("Unable to initialize background blur", e);
|
|
32431
32431
|
}
|
|
32432
32432
|
}
|
|
32433
|
-
function
|
|
32434
|
-
if (e.diagnostic === "speakingWhileMicrophoneIsMuted") {
|
|
32433
|
+
function zt(e) {
|
|
32434
|
+
if (console.log("Diagnostic info changed:", e), e.diagnostic === "speakingWhileMicrophoneIsMuted") {
|
|
32435
32435
|
Ae.value = e.value === !0;
|
|
32436
32436
|
return;
|
|
32437
32437
|
}
|
|
32438
32438
|
(e.diagnostic === "networkReceiveQuality" || e.diagnostic === "networkSendQuality") && (e.value === v.Bad ? (console.error(`${e.diagnostic} is bad quality`), se.value = 0) : e.value === v.Poor ? (console.error(`${e.diagnostic} is poor quality`), se.value = 1) : se.value = 2);
|
|
32439
32439
|
}
|
|
32440
|
-
function
|
|
32440
|
+
function Bt() {
|
|
32441
32441
|
switch (N.call.state) {
|
|
32442
32442
|
case "EarlyMedia":
|
|
32443
|
-
|
|
32443
|
+
_t(i.Dialing);
|
|
32444
32444
|
break;
|
|
32445
32445
|
case "Ringing":
|
|
32446
|
-
|
|
32446
|
+
_t(i.Ringing);
|
|
32447
32447
|
break;
|
|
32448
32448
|
case "Connected":
|
|
32449
|
-
|
|
32449
|
+
_t(i.Connected);
|
|
32450
32450
|
break;
|
|
32451
32451
|
case "Disconnected":
|
|
32452
32452
|
let e = N.call.callEndReason;
|
|
32453
|
-
console.log("Call end reason:", e), console.log("Code:", e?.code), console.log("SubCode:", e?.subCode),
|
|
32453
|
+
console.log("Call end reason:", e), console.log("Code:", e?.code), console.log("SubCode:", e?.subCode), Tt();
|
|
32454
32454
|
break;
|
|
32455
32455
|
}
|
|
32456
32456
|
}
|
|
32457
|
-
function
|
|
32457
|
+
function Vt(e) {
|
|
32458
32458
|
let t = String(e);
|
|
32459
|
-
return
|
|
32459
|
+
return dt(Ke.value.endReasons?.[t] || "");
|
|
32460
32460
|
}
|
|
32461
|
-
async function
|
|
32461
|
+
async function Ht(e) {
|
|
32462
32462
|
if (!e || e.mediaStreamType !== "ScreenSharing" || !_e.value) return;
|
|
32463
32463
|
_e.value.dispose();
|
|
32464
32464
|
let t = Pe.value;
|
|
32465
32465
|
t && (t.style.display = "none", Ne.value.style.display = "flex");
|
|
32466
32466
|
}
|
|
32467
|
-
async function
|
|
32467
|
+
async function Ut(e) {
|
|
32468
32468
|
if (!e || e.mediaStreamType !== "ScreenSharing") return;
|
|
32469
32469
|
_e.value = await new h(e).createView();
|
|
32470
32470
|
let t = Pe.value;
|
|
@@ -32473,8 +32473,9 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32473
32473
|
let n = t.querySelector("video");
|
|
32474
32474
|
n.style.objectFit = "contain";
|
|
32475
32475
|
}
|
|
32476
|
-
async function
|
|
32477
|
-
if (
|
|
32476
|
+
async function Wt(e) {
|
|
32477
|
+
if (e && e.source && ue.value && ue.value.source && he.value && ue.value.source.id == e.source.id) return !0;
|
|
32478
|
+
console.log("Displaying local video stream", e, ue.value);
|
|
32478
32479
|
try {
|
|
32479
32480
|
he.value = new h(e);
|
|
32480
32481
|
let t = await he.value.createView(), n = Ne.value;
|
|
@@ -32485,36 +32486,36 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32485
32486
|
}
|
|
32486
32487
|
return ue.value = e, !0;
|
|
32487
32488
|
}
|
|
32488
|
-
async function
|
|
32489
|
-
e.videoStreams.forEach(
|
|
32490
|
-
e.added.forEach(
|
|
32489
|
+
async function Gt(e) {
|
|
32490
|
+
e.videoStreams.forEach(Kt), e.on("videoStreamsUpdated", (e) => {
|
|
32491
|
+
e.added.forEach(Kt);
|
|
32491
32492
|
});
|
|
32492
32493
|
}
|
|
32493
|
-
async function
|
|
32494
|
-
if (e.mediaStreamType === "Video" && (await
|
|
32494
|
+
async function Kt(e) {
|
|
32495
|
+
if (e.mediaStreamType === "Video" && (await qt(e), e.on("isAvailableChanged", async () => await qt(e))), e.mediaStreamType === "ScreenSharing" && e.on("isAvailableChanged", Yt), e.mediaStreamType === "ScreenSharing" && e.isAvailable) {
|
|
32495
32496
|
ge.value = new h(e);
|
|
32496
32497
|
let t = await ge.value.createView(), n = Me.value;
|
|
32497
32498
|
if (!n) return;
|
|
32498
|
-
|
|
32499
|
+
Jt(!0), oe.value = !0, Qt(n), n.replaceChildren(t.target);
|
|
32499
32500
|
}
|
|
32500
32501
|
}
|
|
32501
|
-
async function
|
|
32502
|
+
async function qt(e) {
|
|
32502
32503
|
if (!e.isAvailable) return;
|
|
32503
32504
|
ge.value = new h(e);
|
|
32504
32505
|
let t = await ge.value.createView(), n = je.value;
|
|
32505
|
-
n && (n.hidden = !1, n.replaceChildren(t.target),
|
|
32506
|
+
n && (n.hidden = !1, n.replaceChildren(t.target), Qt(n), Jt(!1));
|
|
32506
32507
|
}
|
|
32507
|
-
function
|
|
32508
|
+
function Jt(e) {
|
|
32508
32509
|
let t = je.value, n = Me.value;
|
|
32509
32510
|
!t || !n || (t.style.display = e ? "none" : "block", n.style.display = e ? "flex" : "none");
|
|
32510
32511
|
}
|
|
32511
|
-
function
|
|
32512
|
-
oe.value = !1,
|
|
32512
|
+
function Yt() {
|
|
32513
|
+
oe.value = !1, Jt(!1);
|
|
32513
32514
|
}
|
|
32514
|
-
async function
|
|
32515
|
-
|
|
32515
|
+
async function Xt() {
|
|
32516
|
+
Zt(!0);
|
|
32516
32517
|
}
|
|
32517
|
-
async function
|
|
32518
|
+
async function Zt(e = !1) {
|
|
32518
32519
|
let t = N.call?.state;
|
|
32519
32520
|
if (t === "Connecting" || t === "EarlyMedia") return;
|
|
32520
32521
|
let n = (await N.deviceManager.getCameras()).filter((e) => e.name != "OBS Virtual Camera");
|
|
@@ -32522,18 +32523,18 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32522
32523
|
for (let t = 0; t < ve.value; t++) {
|
|
32523
32524
|
(e || t != 0) && (ye.value = (ye.value + 1) % ve.value);
|
|
32524
32525
|
let r = n[ye.value];
|
|
32525
|
-
if (await
|
|
32526
|
+
if (await Wt(new g(r))) break;
|
|
32526
32527
|
}
|
|
32527
32528
|
}
|
|
32528
|
-
function
|
|
32529
|
+
function Qt(e) {
|
|
32529
32530
|
if (!e) return;
|
|
32530
32531
|
let t = e.querySelector("video");
|
|
32531
32532
|
t && (t.style.objectFit = "contain", t.disablePictureInPicture = !1);
|
|
32532
32533
|
}
|
|
32533
|
-
async function
|
|
32534
|
+
async function $t() {
|
|
32534
32535
|
N.call && N.call.state !== "Disconnected" && (await N.call.hangUp({ forEveryone: !0 }), await N.agent.dispose()), S("end-call", T.value);
|
|
32535
32536
|
}
|
|
32536
|
-
async function
|
|
32537
|
+
async function en() {
|
|
32537
32538
|
return o ||= Promise.all([
|
|
32538
32539
|
import("@azure/communication-calling"),
|
|
32539
32540
|
import("@azure/communication-common"),
|
|
@@ -32542,7 +32543,7 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32542
32543
|
f = e.CallClient, h = e.VideoStreamRenderer, g = e.LocalVideoStream, _ = e.Features, v = e.DiagnosticQuality, y = t.AzureCommunicationTokenCredential, b = n.BackgroundBlurEffect;
|
|
32543
32544
|
}), o;
|
|
32544
32545
|
}
|
|
32545
|
-
async function
|
|
32546
|
+
async function tn() {
|
|
32546
32547
|
d ||= import("./browser-1gKVsH6_.js").then((e) => e.t);
|
|
32547
32548
|
let { AzureLogger: e, setLogLevel: t } = await d;
|
|
32548
32549
|
e.log = (...e) => console.log(...e), t("info"), e.log = (...e) => {
|
|
@@ -32550,29 +32551,29 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32550
32551
|
T.value = T.value.splice(1 - PZ).concat(t);
|
|
32551
32552
|
};
|
|
32552
32553
|
}
|
|
32553
|
-
function
|
|
32554
|
+
function nn() {
|
|
32554
32555
|
let e = oe.value ? Me.value : je.value;
|
|
32555
32556
|
e && e.querySelector("video")?.requestFullscreen();
|
|
32556
32557
|
}
|
|
32557
|
-
function
|
|
32558
|
+
function rn() {
|
|
32558
32559
|
let e = oe.value ? Me.value : je.value;
|
|
32559
32560
|
if (!e) return;
|
|
32560
32561
|
let t = e.querySelector("video");
|
|
32561
32562
|
t && (document.pictureInPictureElement ? t.exitPictureInPicture() : document.pictureInPictureEnabled && t.requestPictureInPicture());
|
|
32562
32563
|
}
|
|
32563
|
-
async function
|
|
32564
|
+
async function an() {
|
|
32564
32565
|
N.call && N.call.isScreenSharingOn ? await N.call.stopScreenSharing() : await N.call.startScreenSharing();
|
|
32565
32566
|
}
|
|
32566
32567
|
return n({
|
|
32567
|
-
CallDeclined:
|
|
32568
|
-
CallAnswered:
|
|
32569
|
-
CallForDataReceived:
|
|
32570
|
-
CallClosedWithStatusCode:
|
|
32571
|
-
CallHeartbeatReceived:
|
|
32572
|
-
CallSignalHoldDetected:
|
|
32573
|
-
CallStartVideoCall:
|
|
32574
|
-
CallHangUp:
|
|
32575
|
-
InitializeAcsConnection:
|
|
32568
|
+
CallDeclined: xt,
|
|
32569
|
+
CallAnswered: St,
|
|
32570
|
+
CallForDataReceived: Ct,
|
|
32571
|
+
CallClosedWithStatusCode: Et,
|
|
32572
|
+
CallHeartbeatReceived: Ot,
|
|
32573
|
+
CallSignalHoldDetected: Dt,
|
|
32574
|
+
CallStartVideoCall: wt,
|
|
32575
|
+
CallHangUp: Tt,
|
|
32576
|
+
InitializeAcsConnection: At
|
|
32576
32577
|
}), (e, n) => {
|
|
32577
32578
|
let r = ce("BDLoader");
|
|
32578
32579
|
return k(), l("div", aZ, [m($q, null, {
|
|
@@ -32585,23 +32586,23 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32585
32586
|
}), m(eJ, null, {
|
|
32586
32587
|
default: I(() => [m(Qq, {
|
|
32587
32588
|
sm: "12",
|
|
32588
|
-
lg:
|
|
32589
|
+
lg: et.value ? "12" : "8"
|
|
32589
32590
|
}, {
|
|
32590
|
-
default: I(() => [u("div", { class: D(["incoming",
|
|
32591
|
+
default: I(() => [u("div", { class: D(["incoming", Ue.value]) }, [rt.value ? (k(), l("div", oZ, [
|
|
32591
32592
|
m(r, {
|
|
32592
32593
|
size: "lg",
|
|
32593
|
-
message:
|
|
32594
|
-
stopAnimation:
|
|
32594
|
+
message: ft.value,
|
|
32595
|
+
stopAnimation: et.value || tt.value || it.value
|
|
32595
32596
|
}, null, 8, ["message", "stopAnimation"]),
|
|
32596
|
-
|
|
32597
|
-
|
|
32598
|
-
|
|
32597
|
+
He.value ? (k(), l("div", sZ, [u("div", cZ, [m(Ri, { class: "icon-xl icon-state-error" })]), u("span", null, P(Ye.value.permissionDeniedForAudio), 1)])) : c("", !0),
|
|
32598
|
+
Ve.value ? (k(), l("div", lZ, [u("div", uZ, [m(oo, { class: "icon-xl icon-state-error" })]), u("span", null, P(Ye.value.permissionDeniedForVideo), 1)])) : c("", !0),
|
|
32599
|
+
et.value || tt.value || it.value ? (k(), s(R, {
|
|
32599
32600
|
key: 2,
|
|
32600
32601
|
variant: "primary",
|
|
32601
32602
|
class: "text-center",
|
|
32602
|
-
onClick:
|
|
32603
|
+
onClick: $t
|
|
32603
32604
|
}, {
|
|
32604
|
-
default: I(() => [p(P(
|
|
32605
|
+
default: I(() => [p(P(qe.value.closeWindow), 1)]),
|
|
32605
32606
|
_: 1
|
|
32606
32607
|
})) : c("", !0)
|
|
32607
32608
|
])) : (k(), l("div", dZ, [
|
|
@@ -32618,22 +32619,22 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32618
32619
|
u("div", fZ, [m(R, {
|
|
32619
32620
|
variant: "primary",
|
|
32620
32621
|
class: "text-center",
|
|
32621
|
-
onClick:
|
|
32622
|
+
onClick: nn
|
|
32622
32623
|
}, {
|
|
32623
|
-
default: I(() => [m(xa), u("span", null, P(
|
|
32624
|
+
default: I(() => [m(xa), u("span", null, P(qe.value.fullScreen), 1)]),
|
|
32624
32625
|
_: 1
|
|
32625
32626
|
}), !E && !re.value ? (k(), s(R, {
|
|
32626
32627
|
key: 0,
|
|
32627
32628
|
variant: "primary",
|
|
32628
32629
|
class: "text-center",
|
|
32629
|
-
onClick:
|
|
32630
|
+
onClick: rn
|
|
32630
32631
|
}, {
|
|
32631
|
-
default: I(() => [m(xa), u("span", null, P(
|
|
32632
|
+
default: I(() => [m(xa), u("span", null, P(qe.value.miniPlayer), 1)]),
|
|
32632
32633
|
_: 1
|
|
32633
32634
|
})) : c("", !0)])
|
|
32634
32635
|
]))], 2)]),
|
|
32635
32636
|
_: 1
|
|
32636
|
-
}, 8, ["lg"]),
|
|
32637
|
+
}, 8, ["lg"]), et.value ? c("", !0) : (k(), s(Qq, {
|
|
32637
32638
|
key: 0,
|
|
32638
32639
|
sm: "12",
|
|
32639
32640
|
lg: "4"
|
|
@@ -32652,95 +32653,95 @@ var iZ = /*#__PURE__*/ L(tZ, [["render", rZ]]), aZ = { class: "video-call-templa
|
|
|
32652
32653
|
ref: Pe,
|
|
32653
32654
|
class: "outgoing__screenshare"
|
|
32654
32655
|
}, null, 512),
|
|
32655
|
-
u("div", _Z, [
|
|
32656
|
+
u("div", _Z, [Ae.value ? (k(), l("div", vZ, [m(Ri), u("span", null, P(qe.value.microphoneMutedNotice), 1)])) : c("", !0)])
|
|
32656
32657
|
]),
|
|
32657
32658
|
u("div", yZ, [
|
|
32658
32659
|
Se((k(), s(R, {
|
|
32659
32660
|
class: D({ "btn-danger": ke.value }),
|
|
32660
|
-
onClick:
|
|
32661
|
+
onClick: vt
|
|
32661
32662
|
}, {
|
|
32662
32663
|
default: I(() => [ke.value ? (k(), l("img", {
|
|
32663
32664
|
key: 0,
|
|
32664
32665
|
src: UX,
|
|
32665
|
-
alt:
|
|
32666
|
+
alt: ct.value
|
|
32666
32667
|
}, null, 8, bZ)) : (k(), l("img", {
|
|
32667
32668
|
key: 1,
|
|
32668
32669
|
src: WX,
|
|
32669
|
-
alt:
|
|
32670
|
+
alt: ct.value
|
|
32670
32671
|
}, null, 8, xZ))]),
|
|
32671
32672
|
_: 1
|
|
32672
|
-
}, 8, ["class"])), [[F(DK),
|
|
32673
|
+
}, 8, ["class"])), [[F(DK), ct.value]]),
|
|
32673
32674
|
Se((k(), s(R, {
|
|
32674
32675
|
class: D({ "btn-danger": Oe.value }),
|
|
32675
|
-
onClick:
|
|
32676
|
+
onClick: yt
|
|
32676
32677
|
}, {
|
|
32677
32678
|
default: I(() => [Oe.value ? (k(), l("img", {
|
|
32678
32679
|
key: 0,
|
|
32679
32680
|
src: GX,
|
|
32680
|
-
alt:
|
|
32681
|
+
alt: lt.value
|
|
32681
32682
|
}, null, 8, SZ)) : (k(), l("img", {
|
|
32682
32683
|
key: 1,
|
|
32683
32684
|
src: KX,
|
|
32684
|
-
alt:
|
|
32685
|
+
alt: lt.value
|
|
32685
32686
|
}, null, 8, CZ))]),
|
|
32686
32687
|
_: 1
|
|
32687
|
-
}, 8, ["class"])), [[F(DK),
|
|
32688
|
+
}, 8, ["class"])), [[F(DK), lt.value]]),
|
|
32688
32689
|
Se((k(), s(R, {
|
|
32689
32690
|
class: D(["blur-button", {
|
|
32690
32691
|
off: De.value,
|
|
32691
32692
|
unavailable: pe.value
|
|
32692
32693
|
}]),
|
|
32693
|
-
onClick:
|
|
32694
|
+
onClick: bt
|
|
32694
32695
|
}, {
|
|
32695
32696
|
default: I(() => [m(iZ), m(eZ)]),
|
|
32696
32697
|
_: 1
|
|
32697
|
-
}, 8, ["class"])), [[F(DK),
|
|
32698
|
+
}, 8, ["class"])), [[F(DK), ut.value]])
|
|
32698
32699
|
]),
|
|
32699
|
-
|
|
32700
|
+
Be.value && !it.value && !re.value && !rt.value ? (k(), s(R, {
|
|
32700
32701
|
key: 0,
|
|
32701
32702
|
variant: te.value ? "danger" : "primary",
|
|
32702
32703
|
class: "share-button",
|
|
32703
|
-
onClick:
|
|
32704
|
+
onClick: an
|
|
32704
32705
|
}, {
|
|
32705
|
-
default: I(() => [m(xa), u("span", null, P(
|
|
32706
|
+
default: I(() => [m(xa), u("span", null, P(Ze.value), 1)]),
|
|
32706
32707
|
_: 1
|
|
32707
32708
|
}, 8, ["variant"])) : c("", !0),
|
|
32708
|
-
|
|
32709
|
+
ze.value ? (k(), l(t, { key: 1 }, [m(R, {
|
|
32709
32710
|
class: "text-center",
|
|
32710
|
-
onClick:
|
|
32711
|
+
onClick: Xt
|
|
32711
32712
|
}, {
|
|
32712
|
-
default: I(() => [p(P(
|
|
32713
|
+
default: I(() => [p(P(qe.value.switchCamera), 1)]),
|
|
32713
32714
|
_: 1
|
|
32714
|
-
}), u("p", wZ, P(
|
|
32715
|
-
|
|
32715
|
+
}), u("p", wZ, P(Re.value), 1)], 64)) : c("", !0),
|
|
32716
|
+
Ve.value ? (k(), l("div", TZ, [u("div", EZ, [m(oo, { class: "icon-xxl icon-state-error" })]), u("span", null, P(Ye.value.permissionDeniedForVideo), 1)])) : c("", !0)
|
|
32716
32717
|
]),
|
|
32717
|
-
!
|
|
32718
|
+
!tt.value && !it.value ? (k(), s(R, {
|
|
32718
32719
|
key: 0,
|
|
32719
32720
|
variant: "danger",
|
|
32720
32721
|
class: "end-call-button text-center w-100",
|
|
32721
|
-
onClick:
|
|
32722
|
+
onClick: $t
|
|
32722
32723
|
}, {
|
|
32723
|
-
default: I(() => [m(zn), u("span", null, P(
|
|
32724
|
+
default: I(() => [m(zn), u("span", null, P(qe.value.endCall), 1)]),
|
|
32724
32725
|
_: 1
|
|
32725
32726
|
})) : c("", !0),
|
|
32726
32727
|
u("div", DZ, [
|
|
32727
|
-
u("div", { class: D(["settings__signal",
|
|
32728
|
+
u("div", { class: D(["settings__signal", We.value]) }, [n[0] ||= u("ul", { class: "indicator" }, [
|
|
32728
32729
|
u("li"),
|
|
32729
32730
|
u("li"),
|
|
32730
32731
|
u("li")
|
|
32731
|
-
], -1), u("p", null, P(
|
|
32732
|
-
u("div", OZ, [u("p", kZ, P(
|
|
32732
|
+
], -1), u("p", null, P(Ge.value), 1)], 2),
|
|
32733
|
+
u("div", OZ, [u("p", kZ, P(pt.value), 1), mt.value ? (k(), l("small", AZ, P(mt.value), 1)) : c("", !0)]),
|
|
32733
32734
|
u("div", jZ, [
|
|
32734
|
-
u("p", null, [u("b", null, P(
|
|
32735
|
-
u("p", null, P(
|
|
32735
|
+
u("p", null, [u("b", null, P(Qe.value), 1)]),
|
|
32736
|
+
u("p", null, P($e.value), 1),
|
|
32736
32737
|
u("p", null, [
|
|
32737
32738
|
u("a", {
|
|
32738
32739
|
href: x.videoTestUrl,
|
|
32739
32740
|
target: "_blank",
|
|
32740
32741
|
rel: "noopener noreferrer"
|
|
32741
|
-
}, P(
|
|
32742
|
+
}, P(qe.value.testCall), 9, MZ),
|
|
32742
32743
|
n[1] ||= p(" • ", -1),
|
|
32743
|
-
u("a", NZ, P(
|
|
32744
|
+
u("a", NZ, P(qe.value.serviceDesk), 1)
|
|
32744
32745
|
])
|
|
32745
32746
|
])
|
|
32746
32747
|
])
|