@snapcall/stream-ui 1.5.0 → 1.7.0
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/README.md +3 -2
- package/dist/stream-ui.esm.js +1655 -211
- package/dist/stream-ui.js +1664 -220
- package/dist/stream-ui.umd.js +705 -249
- package/dist/timer.2f4f9ac0.js +1 -0
- package/dist/timer.370d0e5a.js +13 -0
- package/dist/timer.7690fc0b.js +12 -0
- package/dist/types.d.ts +27 -2
- package/package.json +3 -1
package/dist/stream-ui.esm.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import {jsx as $3Sbms$jsx, jsxs as $3Sbms$jsxs, Fragment as $3Sbms$Fragment} from "react/jsx-runtime";
|
|
2
2
|
import {render as $3Sbms$render, createPortal as $3Sbms$createPortal} from "react-dom";
|
|
3
|
+
import $3Sbms$hotjarbrowser from "@hotjar/browser";
|
|
3
4
|
import $3Sbms$reacthottoast, {toast as $3Sbms$toast, Toaster as $3Sbms$Toaster, ToastBar as $3Sbms$ToastBar} from "react-hot-toast";
|
|
4
|
-
import $3Sbms$styledcomponents, {keyframes as $3Sbms$keyframes, ThemeProvider as $3Sbms$ThemeProvider, css as $3Sbms$css, createGlobalStyle as $3Sbms$createGlobalStyle} from "styled-components";
|
|
5
|
+
import $3Sbms$styledcomponents, {keyframes as $3Sbms$keyframes, ThemeProvider as $3Sbms$ThemeProvider, css as $3Sbms$css, ThemeContext as $3Sbms$ThemeContext, createGlobalStyle as $3Sbms$createGlobalStyle} from "styled-components";
|
|
5
6
|
import {useState as $3Sbms$useState, useRef as $3Sbms$useRef, useEffect as $3Sbms$useEffect, useContext as $3Sbms$useContext, useMemo as $3Sbms$useMemo, createContext as $3Sbms$createContext, useReducer as $3Sbms$useReducer, useLayoutEffect as $3Sbms$useLayoutEffect, useCallback as $3Sbms$useCallback} from "react";
|
|
6
7
|
import "inobounce";
|
|
7
8
|
import $3Sbms$i18next from "i18next";
|
|
@@ -12,10 +13,12 @@ import {WebSocketTransport as $3Sbms$WebSocketTransport, Peer as $3Sbms$Peer} fr
|
|
|
12
13
|
import {captureException as $3Sbms$captureException, addBreadcrumb as $3Sbms$addBreadcrumb, setTag as $3Sbms$setTag} from "@sentry/browser";
|
|
13
14
|
import {Producer as $3Sbms$Producer} from "mediasoup-client/lib/Producer";
|
|
14
15
|
import {Device as $3Sbms$Device} from "mediasoup-client";
|
|
16
|
+
import {SelfieSegmentation as $3Sbms$SelfieSegmentation} from "@mediapipe/selfie_segmentation";
|
|
15
17
|
import {toCanvas as $3Sbms$toCanvas} from "qrcode";
|
|
16
18
|
|
|
17
19
|
|
|
18
20
|
|
|
21
|
+
|
|
19
22
|
const $365e765f9890497b$var$isObject = (obj)=>{
|
|
20
23
|
if (typeof obj === "object" && obj !== null) {
|
|
21
24
|
if (typeof Object.getPrototypeOf === "function") {
|
|
@@ -306,6 +309,7 @@ const $a5146f9062d7bf28$export$3a57e165650c636f = (message, options = {})=>{
|
|
|
306
309
|
|
|
307
310
|
|
|
308
311
|
|
|
312
|
+
|
|
309
313
|
const $a3e657fb86ae23f3$export$604ba5624273df44 = ()=>{
|
|
310
314
|
try {
|
|
311
315
|
const storedTheme = localStorage.getItem("stream_ui_language");
|
|
@@ -340,7 +344,9 @@ const $18fb8799f38eb407$export$84584c2a98eb6753 = {
|
|
|
340
344
|
tooLate: "You arrived too late",
|
|
341
345
|
callIsOver: "The call is over or deleted",
|
|
342
346
|
callEnded: "The call is now ended",
|
|
343
|
-
callLeft: "You left the call"
|
|
347
|
+
callLeft: "You left the call",
|
|
348
|
+
full: "You can't join this call",
|
|
349
|
+
fullDescription: "The room is full. Please try to join the call later."
|
|
344
350
|
},
|
|
345
351
|
menu: {
|
|
346
352
|
title: "Menu",
|
|
@@ -352,6 +358,7 @@ const $18fb8799f38eb407$export$84584c2a98eb6753 = {
|
|
|
352
358
|
},
|
|
353
359
|
copyLink: {
|
|
354
360
|
title: "Copy link",
|
|
361
|
+
description: "Copy link into clipboard",
|
|
355
362
|
error: "An error occured when trying to copy to clipboard",
|
|
356
363
|
copied: "Link copied to clipboard"
|
|
357
364
|
},
|
|
@@ -385,21 +392,19 @@ const $18fb8799f38eb407$export$84584c2a98eb6753 = {
|
|
|
385
392
|
shareLink: {
|
|
386
393
|
title: "Share link",
|
|
387
394
|
title2: "Share a link",
|
|
388
|
-
linkUrl: "LINK URL",
|
|
389
395
|
invalid: "Invalid link",
|
|
390
396
|
sentToUsers: "Link sent to users",
|
|
391
397
|
sentToUser: "Link sent to {{user}}",
|
|
392
398
|
failed: "Failed to send link",
|
|
393
|
-
creating: "Link is creating...",
|
|
394
399
|
poweredBy: "Powered by",
|
|
395
400
|
invoice: "{{user}} sent you an invoice.",
|
|
396
401
|
pay: "Pay"
|
|
397
402
|
},
|
|
398
403
|
youtube: {
|
|
399
|
-
title: "
|
|
404
|
+
title: "Watch Together",
|
|
400
405
|
url: "YOUTUBE URL",
|
|
401
406
|
invalid: "Invalid YouTube URL",
|
|
402
|
-
share: "
|
|
407
|
+
share: "Watch now"
|
|
403
408
|
},
|
|
404
409
|
sharedHistory: {
|
|
405
410
|
shared: "Shared with you"
|
|
@@ -420,13 +425,17 @@ const $18fb8799f38eb407$export$84584c2a98eb6753 = {
|
|
|
420
425
|
request: "{{user}} would like you to share your {{device}}",
|
|
421
426
|
timedOut: "Your request has timed out.",
|
|
422
427
|
declined: "Your request has been declined.",
|
|
423
|
-
userDeclined: "{{
|
|
428
|
+
userDeclined: "{{user}} has declined your request."
|
|
424
429
|
},
|
|
425
430
|
leave: {
|
|
426
431
|
title: "Leave",
|
|
427
432
|
leaveCall: "Leave call",
|
|
428
433
|
endCall: "End call for all"
|
|
429
434
|
},
|
|
435
|
+
virtualBackground: {
|
|
436
|
+
title: "Virtual Background",
|
|
437
|
+
setBackground: "Set Background"
|
|
438
|
+
},
|
|
430
439
|
misc: {
|
|
431
440
|
someone: "Someone",
|
|
432
441
|
camera: "Camera",
|
|
@@ -439,6 +448,20 @@ const $18fb8799f38eb407$export$84584c2a98eb6753 = {
|
|
|
439
448
|
accept: "Accept",
|
|
440
449
|
decline: "Decline",
|
|
441
450
|
you: "You"
|
|
451
|
+
},
|
|
452
|
+
invite: {
|
|
453
|
+
title: "Share link to start a conversation",
|
|
454
|
+
copy: "Copy",
|
|
455
|
+
description: "You are currently the only participant. Invite people to start the conversation."
|
|
456
|
+
},
|
|
457
|
+
greeting: {
|
|
458
|
+
mainTitle: "Welcome to SnapCall",
|
|
459
|
+
sideTitle: "Are you ready to join?",
|
|
460
|
+
sideDescription: "Before joining the room, enter your name. It will displayed to participants.",
|
|
461
|
+
namePlaceholder: "Your name",
|
|
462
|
+
nameSubmit: "Join Conversation",
|
|
463
|
+
footerTitle: "Powered by SnapCall",
|
|
464
|
+
footerDescription: "Meet SnapCall, the easiest way to add real-time video to platform, product or service."
|
|
442
465
|
}
|
|
443
466
|
}
|
|
444
467
|
};
|
|
@@ -466,7 +489,9 @@ const $c5472fb74fa04782$export$acb2a88f7d552ebf = {
|
|
|
466
489
|
tooLate: "Vous \xeates arrivez trop tard",
|
|
467
490
|
callIsOver: "Cet appel est termin\xe9 ou supprim\xe9",
|
|
468
491
|
callEnded: "Cet appel est termin\xe9",
|
|
469
|
-
callLeft: "Vous avez quitt\xe9 l'appel"
|
|
492
|
+
callLeft: "Vous avez quitt\xe9 l'appel",
|
|
493
|
+
full: "Impossible de rejoindre l'appel",
|
|
494
|
+
fullDescription: "Limite d'utilisateurs atteinte. Merci de rejoindre l'appel ult\xe9rieurement."
|
|
470
495
|
},
|
|
471
496
|
menu: {
|
|
472
497
|
title: "Menu",
|
|
@@ -478,6 +503,7 @@ const $c5472fb74fa04782$export$acb2a88f7d552ebf = {
|
|
|
478
503
|
},
|
|
479
504
|
copyLink: {
|
|
480
505
|
title: "Copier le lien",
|
|
506
|
+
description: "Copier le lien dans le presse-papiers",
|
|
481
507
|
error: "Une erreur est survenue pendant la copie du lien dans le presse-papier",
|
|
482
508
|
copied: "Lien copi\xe9 dans le presse-papier"
|
|
483
509
|
},
|
|
@@ -511,21 +537,19 @@ const $c5472fb74fa04782$export$acb2a88f7d552ebf = {
|
|
|
511
537
|
shareLink: {
|
|
512
538
|
title: "Partager un lien",
|
|
513
539
|
title2: "Partager un lien",
|
|
514
|
-
linkUrl: "URL DU LIEN",
|
|
515
540
|
invalid: "Lien invalide",
|
|
516
541
|
sentToUsers: "Lien envoy\xe9 aux participants",
|
|
517
542
|
sentToUser: "Lien envoy\xe9 \xe0 {{user}}",
|
|
518
543
|
failed: "Une erreur est survenue pendant l'envoi du lien",
|
|
519
|
-
creating: "Lien en cours de cr\xe9ation...",
|
|
520
544
|
poweredBy: "Propos\xe9 par",
|
|
521
545
|
invoice: "{{user}} vous a envoy\xe9 une facture.",
|
|
522
546
|
pay: "Payer"
|
|
523
547
|
},
|
|
524
548
|
youtube: {
|
|
525
|
-
title: "
|
|
549
|
+
title: "Regardons Ensemble",
|
|
526
550
|
url: "URL YOUTUBE",
|
|
527
551
|
invalid: "URL YouTube invalide",
|
|
528
|
-
share: "
|
|
552
|
+
share: "Regarder maintenant"
|
|
529
553
|
},
|
|
530
554
|
sharedHistory: {
|
|
531
555
|
shared: "Partag\xe9 avec vous"
|
|
@@ -546,12 +570,16 @@ const $c5472fb74fa04782$export$acb2a88f7d552ebf = {
|
|
|
546
570
|
request: "{{user}} voudrait que vous partagiez votre {{device}}",
|
|
547
571
|
timedOut: "Votre requ\xeate n'a pas eu de r\xe9ponse",
|
|
548
572
|
declined: "Votre requ\xeate a \xe9t\xe9 refus\xe9.",
|
|
549
|
-
userDeclined: "{{
|
|
573
|
+
userDeclined: "{{user}} a d\xe9clin\xe9 votre requ\xeate."
|
|
550
574
|
},
|
|
551
575
|
leave: {
|
|
552
576
|
title: "Quitter",
|
|
553
577
|
leaveCall: "Quitter l'appel",
|
|
554
|
-
endCall: "Terminer l'appel
|
|
578
|
+
endCall: "Terminer l'appel"
|
|
579
|
+
},
|
|
580
|
+
virtualBackground: {
|
|
581
|
+
title: "Arri\xe8re plan virtuel",
|
|
582
|
+
setBackground: "Mettre l'arri\xe8re plan"
|
|
555
583
|
},
|
|
556
584
|
misc: {
|
|
557
585
|
someone: "Quelqu'un",
|
|
@@ -565,6 +593,20 @@ const $c5472fb74fa04782$export$acb2a88f7d552ebf = {
|
|
|
565
593
|
accept: "Accepter",
|
|
566
594
|
decline: "D\xe9cliner",
|
|
567
595
|
you: "Vous"
|
|
596
|
+
},
|
|
597
|
+
invite: {
|
|
598
|
+
title: "Partagez le lien pour commencer une conversation",
|
|
599
|
+
copy: "Copier",
|
|
600
|
+
description: "Vous \xeates actuellement le seul participant. Inviter des personnes pour commencer la conversation."
|
|
601
|
+
},
|
|
602
|
+
greeting: {
|
|
603
|
+
mainTitle: "Bienvenue sur SnapCall",
|
|
604
|
+
sideTitle: "Pr\xeat \xe0 rejoindre ?",
|
|
605
|
+
sideDescription: "Avant de rejoindre la salle, veuillez entrer votre nom.",
|
|
606
|
+
namePlaceholder: "Nom",
|
|
607
|
+
nameSubmit: "Rejoindre la conversation",
|
|
608
|
+
footerTitle: "Propuls\xe9 par SnapCall",
|
|
609
|
+
footerDescription: "D\xe9couvrez SnapCall, ajoutez de la vid\xe9o en temps r\xe9el \xe0 n'importe quelle plateforme, produit ou service."
|
|
568
610
|
}
|
|
569
611
|
}
|
|
570
612
|
};
|
|
@@ -592,7 +634,9 @@ const $b7790fb9e48df5c4$export$3486a10f30cf1ee4 = {
|
|
|
592
634
|
tooLate: "Sei arrivato troppo tardi",
|
|
593
635
|
callIsOver: "Questa chiamata \xe8 finita o \xe8 stata eliminata",
|
|
594
636
|
callEnded: "Questa chiamata \xe8 finita",
|
|
595
|
-
callLeft: "Hai lasciato la chiamata"
|
|
637
|
+
callLeft: "Hai lasciato la chiamata",
|
|
638
|
+
full: "Impossibile partecipare alla chiamata",
|
|
639
|
+
fullDescription: "Limite d'uso attenente."
|
|
596
640
|
},
|
|
597
641
|
menu: {
|
|
598
642
|
title: "Men\xf9",
|
|
@@ -604,6 +648,7 @@ const $b7790fb9e48df5c4$export$3486a10f30cf1ee4 = {
|
|
|
604
648
|
},
|
|
605
649
|
copyLink: {
|
|
606
650
|
title: "Copia il link",
|
|
651
|
+
description: "Copia il link negli appunti",
|
|
607
652
|
error: "Si \xe8 verificato un errore durante la copia negli Appunti",
|
|
608
653
|
copied: "Link copiato negli Appunti"
|
|
609
654
|
},
|
|
@@ -637,21 +682,19 @@ const $b7790fb9e48df5c4$export$3486a10f30cf1ee4 = {
|
|
|
637
682
|
shareLink: {
|
|
638
683
|
title: "Condividi un link",
|
|
639
684
|
title2: "Condividi un link",
|
|
640
|
-
linkUrl: "Link URL",
|
|
641
685
|
invalid: "Collegamento non valido",
|
|
642
686
|
sentToUsers: "Link inviato ai partecipanti",
|
|
643
687
|
sentToUser: "Link inviato a {{user}}",
|
|
644
688
|
failed: "Si \xe8 verificato un errore durante l'invio del link",
|
|
645
|
-
creating: "Link che viene creato...",
|
|
646
689
|
poweredBy: "Proposto da",
|
|
647
690
|
invoice: "{{User}} ti ha inviato una fattura.",
|
|
648
691
|
pay: "Paga"
|
|
649
692
|
},
|
|
650
693
|
youtube: {
|
|
651
|
-
title: "
|
|
694
|
+
title: "Vedere Assieme",
|
|
652
695
|
url: "URL YOUTUBE",
|
|
653
696
|
invalid: "URL YouTube non valido",
|
|
654
|
-
share: "
|
|
697
|
+
share: "Guarda ora"
|
|
655
698
|
},
|
|
656
699
|
sharedHistory: {
|
|
657
700
|
shared: "Condiviso con te"
|
|
@@ -672,13 +715,21 @@ const $b7790fb9e48df5c4$export$3486a10f30cf1ee4 = {
|
|
|
672
715
|
request: "{{user}} vorrebbe condividere il tuo {{device}}",
|
|
673
716
|
timedOut: "La tua richiesta non ha ricevuto risposta",
|
|
674
717
|
declined: "La tua richiesta \xe8 stata rifiutata.",
|
|
675
|
-
userDeclined: "{{
|
|
718
|
+
userDeclined: "{{user}} ha rifiutato la tua richiesta"
|
|
676
719
|
},
|
|
677
720
|
leave: {
|
|
678
721
|
title: "Lasciare",
|
|
679
722
|
leaveCall: "Lascia la chiamata",
|
|
680
723
|
endCall: "Termina la chiamata per tutti"
|
|
681
724
|
},
|
|
725
|
+
virtualBackground: {
|
|
726
|
+
title: "Sfondo virtuale",
|
|
727
|
+
setBackground: "Imposta sfondo"
|
|
728
|
+
},
|
|
729
|
+
virtualbackground: {
|
|
730
|
+
title: "Virtual Background",
|
|
731
|
+
setBackground: "Set Background"
|
|
732
|
+
},
|
|
682
733
|
misc: {
|
|
683
734
|
someone: "Qualcuno",
|
|
684
735
|
camera: "Telecamera",
|
|
@@ -691,6 +742,20 @@ const $b7790fb9e48df5c4$export$3486a10f30cf1ee4 = {
|
|
|
691
742
|
accept: "Accettare",
|
|
692
743
|
decline: "Declinare",
|
|
693
744
|
you: "Voi"
|
|
745
|
+
},
|
|
746
|
+
invite: {
|
|
747
|
+
title: "Condividi link per avviare una conversazione",
|
|
748
|
+
copy: "Copiare",
|
|
749
|
+
description: "Attualmente sei l'unico partecipante. Invita le persone ad iniziare la conversazione."
|
|
750
|
+
},
|
|
751
|
+
greeting: {
|
|
752
|
+
mainTitle: "Benvenuto a SnapCall",
|
|
753
|
+
sideTitle: "Sei pronto per unirti?",
|
|
754
|
+
sideDescription: "Prima di entrare nella stanza, inserisci il tuo nome. Verr\xe0 visualizzato ai partecipanti.",
|
|
755
|
+
namePlaceholder: "Il tuo nome",
|
|
756
|
+
nameSubmit: "Partecipa alla conversazione",
|
|
757
|
+
footerTitle: "Offerto da SnapCall",
|
|
758
|
+
footerDescription: "Incontrare SnapCall, il modo pi\xf9 semplice per aggiungere video in tempo reale a piattaforma, prodotto o servizio."
|
|
694
759
|
}
|
|
695
760
|
}
|
|
696
761
|
};
|
|
@@ -720,6 +785,7 @@ var $384d985bb9605c35$export$2e2bcd8739ae039 = (0, $3Sbms$i18next);
|
|
|
720
785
|
|
|
721
786
|
|
|
722
787
|
|
|
788
|
+
|
|
723
789
|
const $0f65a9eaf4a1e910$var$LogLevel = {
|
|
724
790
|
error: 1,
|
|
725
791
|
warn: 2,
|
|
@@ -1121,13 +1187,165 @@ class $a2f0e3c29b11c88e$export$2e2bcd8739ae039 {
|
|
|
1121
1187
|
}
|
|
1122
1188
|
|
|
1123
1189
|
|
|
1190
|
+
|
|
1191
|
+
|
|
1192
|
+
const $0148b6fd862a22e8$var$log = new (0, $0f65a9eaf4a1e910$export$2e2bcd8739ae039)("MediaPipe");
|
|
1193
|
+
const $0148b6fd862a22e8$var$mediapipeUrl = "https://stream-assets.snapcall.io/v1.7.0";
|
|
1194
|
+
let $0148b6fd862a22e8$var$selfieSegmentationInitialized = false;
|
|
1195
|
+
const $0148b6fd862a22e8$var$selfieSegmentation = new $3Sbms$SelfieSegmentation({
|
|
1196
|
+
locateFile: (file, prefix)=>{
|
|
1197
|
+
$0148b6fd862a22e8$var$log.debug("selfieSegmentation", file, prefix);
|
|
1198
|
+
if ($0148b6fd862a22e8$var$mediapipeUrl) return `${$0148b6fd862a22e8$var$mediapipeUrl}/mediapipe/${file}`;
|
|
1199
|
+
const url = window.location.href;
|
|
1200
|
+
const path = url.split("/").slice(0, -1).join("/");
|
|
1201
|
+
return `${path}/mediapipe/${file}`;
|
|
1202
|
+
}
|
|
1203
|
+
});
|
|
1204
|
+
class $0148b6fd862a22e8$export$2e2bcd8739ae039 {
|
|
1205
|
+
fillColor = "#000000";
|
|
1206
|
+
type = "blur";
|
|
1207
|
+
live = false;
|
|
1208
|
+
fps = 24;
|
|
1209
|
+
blurLevel = 10;
|
|
1210
|
+
timerWorker = new Worker(new URL("timer.370d0e5a.js", import.meta.url), {
|
|
1211
|
+
name: "VirtualBackgroundTimerWorker"
|
|
1212
|
+
});
|
|
1213
|
+
constructor(stream, options){
|
|
1214
|
+
this.stream = stream;
|
|
1215
|
+
this.image = document.createElement("video");
|
|
1216
|
+
this.image.style.display = "none";
|
|
1217
|
+
this.image.setAttribute("autoplay", "");
|
|
1218
|
+
this.image.setAttribute("playsinline", "");
|
|
1219
|
+
this.image.setAttribute("muted", "");
|
|
1220
|
+
this.canvas = document.createElement("canvas");
|
|
1221
|
+
this.canvas.style.display = "none";
|
|
1222
|
+
if (options) this.setOptions(options);
|
|
1223
|
+
}
|
|
1224
|
+
setOptions(options) {
|
|
1225
|
+
this.setType(options.type);
|
|
1226
|
+
this.setFillColor(options.fillColor || this.fillColor);
|
|
1227
|
+
this.setVideoBackground(options.background);
|
|
1228
|
+
this.setBlurLevel(options.blurLevel || this.blurLevel);
|
|
1229
|
+
}
|
|
1230
|
+
setType(type) {
|
|
1231
|
+
this.type = type;
|
|
1232
|
+
}
|
|
1233
|
+
setBlurLevel(level) {
|
|
1234
|
+
this.blurLevel = level;
|
|
1235
|
+
}
|
|
1236
|
+
setVideoBackground(data) {
|
|
1237
|
+
this.background = data;
|
|
1238
|
+
}
|
|
1239
|
+
setFillColor(color) {
|
|
1240
|
+
this.fillColor = color;
|
|
1241
|
+
}
|
|
1242
|
+
drawWithBlur(ctx, results) {
|
|
1243
|
+
ctx.save();
|
|
1244
|
+
ctx.drawImage(results.image, 0, 0, this.canvas.width, this.canvas.height);
|
|
1245
|
+
ctx.globalCompositeOperation = "destination-atop";
|
|
1246
|
+
ctx.drawImage(results.segmentationMask, 0, 0, this.canvas.width, this.canvas.height);
|
|
1247
|
+
// Blur the context for all subsequent draws then set the raw image as the background
|
|
1248
|
+
ctx.filter = `blur(${this.blurLevel}px)`;
|
|
1249
|
+
ctx.globalCompositeOperation = "destination-over";
|
|
1250
|
+
ctx.drawImage(results.image, 0, 0, this.canvas.width, this.canvas.height);
|
|
1251
|
+
// Restore the context's blank state
|
|
1252
|
+
ctx.restore();
|
|
1253
|
+
}
|
|
1254
|
+
drawWithBackground(ctx, results) {
|
|
1255
|
+
ctx.clearRect(0, 0, this.canvas.width, this.canvas.height);
|
|
1256
|
+
ctx.drawImage(results.segmentationMask, 0, 0, this.canvas.width, this.canvas.height);
|
|
1257
|
+
ctx.globalCompositeOperation = "source-out";
|
|
1258
|
+
ctx.fillStyle = this.fillColor;
|
|
1259
|
+
if (this.background) ctx.drawImage(this.background, 0, 0, this.canvas.width, this.canvas.height);
|
|
1260
|
+
else ctx.fillRect(0, 0, this.canvas.width, this.canvas.height);
|
|
1261
|
+
ctx.globalCompositeOperation = "destination-atop";
|
|
1262
|
+
ctx.drawImage(results.image, 0, 0, this.canvas.width, this.canvas.height);
|
|
1263
|
+
ctx.restore();
|
|
1264
|
+
}
|
|
1265
|
+
onFrame(results) {
|
|
1266
|
+
this.canvas.width = results.image.width;
|
|
1267
|
+
this.canvas.height = results.image.height;
|
|
1268
|
+
const ctx = this.canvas.getContext("2d");
|
|
1269
|
+
if (ctx) switch(this.type){
|
|
1270
|
+
case "blur":
|
|
1271
|
+
this.drawWithBlur(ctx, results);
|
|
1272
|
+
break;
|
|
1273
|
+
case "background":
|
|
1274
|
+
this.drawWithBackground(ctx, results);
|
|
1275
|
+
break;
|
|
1276
|
+
default:
|
|
1277
|
+
this.drawWithBlur(ctx, results);
|
|
1278
|
+
}
|
|
1279
|
+
}
|
|
1280
|
+
runWithFrameCallback() {
|
|
1281
|
+
if (this.live) this.image.requestVideoFrameCallback(()=>{
|
|
1282
|
+
$0148b6fd862a22e8$var$selfieSegmentation.send({
|
|
1283
|
+
image: this.image
|
|
1284
|
+
});
|
|
1285
|
+
this.runWithFrameCallback();
|
|
1286
|
+
});
|
|
1287
|
+
}
|
|
1288
|
+
async createStream() {
|
|
1289
|
+
try {
|
|
1290
|
+
const option = {
|
|
1291
|
+
selfieMode: false,
|
|
1292
|
+
modelSelection: 0
|
|
1293
|
+
};
|
|
1294
|
+
$0148b6fd862a22e8$var$selfieSegmentation.setOptions(option);
|
|
1295
|
+
$0148b6fd862a22e8$var$log.log("selfie segmentation initialized");
|
|
1296
|
+
if (!$0148b6fd862a22e8$var$selfieSegmentationInitialized) {
|
|
1297
|
+
await $0148b6fd862a22e8$var$selfieSegmentation.initialize();
|
|
1298
|
+
$0148b6fd862a22e8$var$selfieSegmentationInitialized = true;
|
|
1299
|
+
}
|
|
1300
|
+
this.image.srcObject = this.stream;
|
|
1301
|
+
this.image.onplay = async ()=>{
|
|
1302
|
+
this.live = true;
|
|
1303
|
+
try {
|
|
1304
|
+
$0148b6fd862a22e8$var$selfieSegmentation.onResults((res)=>{
|
|
1305
|
+
this.onFrame(res);
|
|
1306
|
+
});
|
|
1307
|
+
this.timerWorker.onmessage = ()=>{
|
|
1308
|
+
$0148b6fd862a22e8$var$selfieSegmentation.send({
|
|
1309
|
+
image: this.image
|
|
1310
|
+
});
|
|
1311
|
+
};
|
|
1312
|
+
this.timerWorker.postMessage({
|
|
1313
|
+
action: "start",
|
|
1314
|
+
params: this.fps
|
|
1315
|
+
});
|
|
1316
|
+
} catch (err) {
|
|
1317
|
+
$0148b6fd862a22e8$var$log.error("createStream:play", err);
|
|
1318
|
+
}
|
|
1319
|
+
};
|
|
1320
|
+
} catch (err) {
|
|
1321
|
+
console.error("createStream", err);
|
|
1322
|
+
}
|
|
1323
|
+
return this.canvas.captureStream();
|
|
1324
|
+
}
|
|
1325
|
+
clean() {
|
|
1326
|
+
return new Promise((resolve)=>{
|
|
1327
|
+
this.live = false;
|
|
1328
|
+
clearInterval(this.runInterval);
|
|
1329
|
+
this.image.srcObject = null;
|
|
1330
|
+
this.stream.getTracks().forEach((track)=>{
|
|
1331
|
+
track.stop();
|
|
1332
|
+
this.stream.removeTrack(track);
|
|
1333
|
+
});
|
|
1334
|
+
this.timerWorker.terminate();
|
|
1335
|
+
resolve();
|
|
1336
|
+
});
|
|
1337
|
+
}
|
|
1338
|
+
}
|
|
1339
|
+
|
|
1340
|
+
|
|
1124
1341
|
const $c31e3fb4360572af$var$log = new (0, $0f65a9eaf4a1e910$export$2e2bcd8739ae039)("StreamerClient");
|
|
1125
1342
|
const $c31e3fb4360572af$export$818d60b2e626da0c = {
|
|
1126
1343
|
WEBRTC_FAILED: "WRTC1",
|
|
1127
1344
|
WEBRTC_RECOVER_ERROR: "WRTC2",
|
|
1128
1345
|
CREATE_TRANSPORT_FAILED: "TRANS1",
|
|
1129
1346
|
CONSUME_ERROR: "CONS1",
|
|
1130
|
-
SOCKET_LOST: "SOCK1"
|
|
1347
|
+
SOCKET_LOST: "SOCK1",
|
|
1348
|
+
USER_LIMIT: "USERLIMIT"
|
|
1131
1349
|
};
|
|
1132
1350
|
const $c31e3fb4360572af$export$d21ffcc5eb136bfa = {
|
|
1133
1351
|
qvga: {
|
|
@@ -1189,8 +1407,16 @@ class $c31e3fb4360572af$var$SnapcallEvent extends CustomEvent {
|
|
|
1189
1407
|
}
|
|
1190
1408
|
}
|
|
1191
1409
|
const $c31e3fb4360572af$var$StreamerEventTargetType = EventTarget;
|
|
1410
|
+
const $c31e3fb4360572af$var$defaultMediapipeOptions = {
|
|
1411
|
+
background: undefined,
|
|
1412
|
+
fillColor: "#ffffff",
|
|
1413
|
+
type: "blur",
|
|
1414
|
+
blurLevel: 10
|
|
1415
|
+
};
|
|
1192
1416
|
class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$StreamerEventTargetType {
|
|
1193
1417
|
mediasoupTransport = {};
|
|
1418
|
+
mediaPipeOption = $c31e3fb4360572af$var$defaultMediapipeOptions;
|
|
1419
|
+
useVideoBackground = false;
|
|
1194
1420
|
pendingDeviceRequest = {};
|
|
1195
1421
|
joinOptions = {};
|
|
1196
1422
|
devicesList = [];
|
|
@@ -1355,7 +1581,9 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1355
1581
|
this.protoo.on("close", ()=>$c31e3fb4360572af$var$log.log("protoo.on", "close :("));
|
|
1356
1582
|
this.protoo.on("notification", async (notification)=>{
|
|
1357
1583
|
$c31e3fb4360572af$var$log.log("notification", notification);
|
|
1358
|
-
if (notification.method === "
|
|
1584
|
+
if (notification.method === "error") {
|
|
1585
|
+
if (notification.data?.reason === "reached user limit") this.onCriticalError($c31e3fb4360572af$export$818d60b2e626da0c.USER_LIMIT);
|
|
1586
|
+
} else if (notification.method === "newPeer") {
|
|
1359
1587
|
const { id: id , profile: profile } = notification.data;
|
|
1360
1588
|
this.peers.set(id, {
|
|
1361
1589
|
id: id,
|
|
@@ -1490,9 +1718,13 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1490
1718
|
}
|
|
1491
1719
|
});
|
|
1492
1720
|
}
|
|
1493
|
-
closeWebrtcTransport(
|
|
1494
|
-
transport
|
|
1495
|
-
|
|
1721
|
+
closeWebrtcTransport(key) {
|
|
1722
|
+
const transport = this.mediasoupTransport[key];
|
|
1723
|
+
if (transport) {
|
|
1724
|
+
transport?.transport?.close();
|
|
1725
|
+
clearTimeout(transport?.disconnectTimeout);
|
|
1726
|
+
delete this.mediasoupTransport[key];
|
|
1727
|
+
}
|
|
1496
1728
|
}
|
|
1497
1729
|
async getTransport(kind, direction) {
|
|
1498
1730
|
if (!this.streamerMediasoup) throw new Error("streamerMediasoup not initialized");
|
|
@@ -1765,7 +1997,11 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1765
1997
|
}
|
|
1766
1998
|
release() {
|
|
1767
1999
|
$c31e3fb4360572af$var$log.log("release");
|
|
1768
|
-
for(let key in this.mediasoupTransport)this.closeWebrtcTransport(
|
|
2000
|
+
for(let key in this.mediasoupTransport)this.closeWebrtcTransport(key);
|
|
2001
|
+
if (this.mediaPipe) {
|
|
2002
|
+
this.mediaPipe.clean();
|
|
2003
|
+
this.mediaPipe = undefined;
|
|
2004
|
+
}
|
|
1769
2005
|
this.webcamTrack?.stop();
|
|
1770
2006
|
this.webcamTrack = null;
|
|
1771
2007
|
this.protooTransport.close();
|
|
@@ -1867,6 +2103,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1867
2103
|
}
|
|
1868
2104
|
}
|
|
1869
2105
|
scaleVideoEncodingsParameter() {
|
|
2106
|
+
if (this.useVideoBackground) return;
|
|
1870
2107
|
try {
|
|
1871
2108
|
let videoCount = 0;
|
|
1872
2109
|
this.consumers.forEach((consumer)=>{
|
|
@@ -1894,6 +2131,24 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1894
2131
|
$c31e3fb4360572af$var$log.error("scaleVideoEncodingsParameter", "scaleVideo error", error);
|
|
1895
2132
|
}
|
|
1896
2133
|
}
|
|
2134
|
+
setVideoBackground(options) {
|
|
2135
|
+
this.mediaPipe?.setOptions(options);
|
|
2136
|
+
this.mediaPipeOption = options;
|
|
2137
|
+
}
|
|
2138
|
+
async initVideoBackground() {
|
|
2139
|
+
if (this.useVideoBackground === true) return;
|
|
2140
|
+
this.useVideoBackground = true;
|
|
2141
|
+
if (!this.webcamProducer || this.webcamProducer.closed) return;
|
|
2142
|
+
await this.switchWebcam({});
|
|
2143
|
+
}
|
|
2144
|
+
async stopVideoBackground() {
|
|
2145
|
+
if (this.useVideoBackground === false) return;
|
|
2146
|
+
this.useVideoBackground = false;
|
|
2147
|
+
await this.mediaPipe?.clean();
|
|
2148
|
+
this.mediaPipe = undefined;
|
|
2149
|
+
if (!this.webcamProducer || this.webcamProducer.closed) return;
|
|
2150
|
+
await this.switchWebcam({});
|
|
2151
|
+
}
|
|
1897
2152
|
async switchWebcam({ device: device , resolution: resolution , rotate: rotate }) {
|
|
1898
2153
|
if (!this.webcam.device) throw new Error("no webcam devices");
|
|
1899
2154
|
if (rotate) {
|
|
@@ -1910,18 +2165,32 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1910
2165
|
if (device) this.webcam.device = device;
|
|
1911
2166
|
if (resolution) this.webcam.resolution = resolution;
|
|
1912
2167
|
}
|
|
1913
|
-
|
|
2168
|
+
let usedResolution = $c31e3fb4360572af$export$d21ffcc5eb136bfa[resolution || this.webcam.resolution];
|
|
2169
|
+
if (this.useVideoBackground) usedResolution = {
|
|
2170
|
+
width: {
|
|
2171
|
+
ideal: 560
|
|
2172
|
+
},
|
|
2173
|
+
height: {
|
|
2174
|
+
ideal: 400
|
|
2175
|
+
},
|
|
2176
|
+
qualityIndex: 2
|
|
2177
|
+
};
|
|
2178
|
+
const mediaStream = await this.handleGetUserMediaError("webcam", navigator.mediaDevices.getUserMedia({
|
|
1914
2179
|
video: {
|
|
1915
2180
|
deviceId: {
|
|
1916
2181
|
ideal: this.webcam.device.deviceId
|
|
1917
2182
|
},
|
|
1918
|
-
|
|
2183
|
+
...usedResolution
|
|
1919
2184
|
}
|
|
1920
2185
|
}));
|
|
2186
|
+
if (this.useVideoBackground) {
|
|
2187
|
+
if (this.mediaPipe) await this.mediaPipe.clean();
|
|
2188
|
+
this.mediaPipe = new (0, $0148b6fd862a22e8$export$2e2bcd8739ae039)(mediaStream, this.mediaPipeOption);
|
|
2189
|
+
}
|
|
2190
|
+
const stream = await this.mediaPipe?.createStream() || mediaStream;
|
|
1921
2191
|
const transport = await this.getTransport("video", "send");
|
|
1922
2192
|
if (!transport) throw new Error("video transport not found, can not switch");
|
|
1923
2193
|
const track = stream.getVideoTracks()[0];
|
|
1924
|
-
this.webcamTrack = track;
|
|
1925
2194
|
await this.webcamProducer?.replaceTrack?.({
|
|
1926
2195
|
track: track
|
|
1927
2196
|
});
|
|
@@ -1942,14 +2211,29 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1942
2211
|
await this.updateWebcams();
|
|
1943
2212
|
if (config?.device) this.webcam.device = config.device;
|
|
1944
2213
|
if (!this.webcam.device) throw new Error("no webcam devices");
|
|
1945
|
-
|
|
2214
|
+
let usedResolution = $c31e3fb4360572af$export$d21ffcc5eb136bfa[config?.resolution || this.webcam.resolution];
|
|
2215
|
+
if (this.useVideoBackground) usedResolution = {
|
|
2216
|
+
width: {
|
|
2217
|
+
ideal: 560
|
|
2218
|
+
},
|
|
2219
|
+
height: {
|
|
2220
|
+
ideal: 400
|
|
2221
|
+
},
|
|
2222
|
+
qualityIndex: 2
|
|
2223
|
+
};
|
|
2224
|
+
const mediaStream = await this.handleGetUserMediaError("webcam", navigator.mediaDevices.getUserMedia({
|
|
1946
2225
|
video: {
|
|
1947
2226
|
deviceId: {
|
|
1948
2227
|
ideal: this.webcam.device.deviceId
|
|
1949
2228
|
},
|
|
1950
|
-
|
|
2229
|
+
...usedResolution
|
|
1951
2230
|
}
|
|
1952
2231
|
}));
|
|
2232
|
+
if (this.useVideoBackground) {
|
|
2233
|
+
if (this.mediaPipe) await this.mediaPipe.clean();
|
|
2234
|
+
this.mediaPipe = new (0, $0148b6fd862a22e8$export$2e2bcd8739ae039)(mediaStream, this.mediaPipeOption);
|
|
2235
|
+
}
|
|
2236
|
+
const stream = await this.mediaPipe?.createStream() || mediaStream;
|
|
1953
2237
|
await this.updateWebcams();
|
|
1954
2238
|
const transport = await this.getTransport("video", "send");
|
|
1955
2239
|
const track = stream.getVideoTracks()[0];
|
|
@@ -2109,6 +2393,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2109
2393
|
}
|
|
2110
2394
|
}
|
|
2111
2395
|
requestVideo({ mediaId: mediaId , element: element }) {
|
|
2396
|
+
$c31e3fb4360572af$var$log.info("requestVideo");
|
|
2112
2397
|
const consumer = this.consumers.get(mediaId);
|
|
2113
2398
|
if (consumer) {
|
|
2114
2399
|
const mediaStream = new MediaStream();
|
|
@@ -2126,6 +2411,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2126
2411
|
return image;
|
|
2127
2412
|
}
|
|
2128
2413
|
requestLocalVideo(element) {
|
|
2414
|
+
$c31e3fb4360572af$var$log.info("requestLocalVideo");
|
|
2129
2415
|
if (this.webcamProducer) {
|
|
2130
2416
|
const mediaStream = new MediaStream();
|
|
2131
2417
|
mediaStream.addTrack(this.webcamProducer.track);
|
|
@@ -2645,7 +2931,7 @@ const $2da9626742e3560b$export$6546b255bd3a2004 = ()=>/*#__PURE__*/ (0, $3Sbms$j
|
|
|
2645
2931
|
fill: "#fff"
|
|
2646
2932
|
})
|
|
2647
2933
|
});
|
|
2648
|
-
const $2da9626742e3560b$export$92ce62e1201c4fc0 = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
2934
|
+
const $2da9626742e3560b$export$92ce62e1201c4fc0 = ({ color: color })=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
2649
2935
|
width: "24",
|
|
2650
2936
|
height: "24",
|
|
2651
2937
|
viewBox: "0 0 24 24",
|
|
@@ -2653,10 +2939,10 @@ const $2da9626742e3560b$export$92ce62e1201c4fc0 = ()=>/*#__PURE__*/ (0, $3Sbms$j
|
|
|
2653
2939
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2654
2940
|
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
2655
2941
|
d: "M21 8.94a1.307 1.307 0 0 0-.06-.27v-.09a1.07 1.07 0 0 0-.19-.28l-6-6a1.071 1.071 0 0 0-.28-.19.32.32 0 0 0-.09 0 .88.88 0 0 0-.33-.11H10a3 3 0 0 0-3 3v1H6a3 3 0 0 0-3 3v10a3 3 0 0 0 3 3h8a3 3 0 0 0 3-3v-1h1a3 3 0 0 0 3-3V8.94Zm-6-3.53L17.59 8H16a1 1 0 0 1-1-1V5.41ZM15 19a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V9a1 1 0 0 1 1-1h1v7a3 3 0 0 0 3 3h5v1Zm4-4a1 1 0 0 1-1 1h-8a1 1 0 0 1-1-1V5a1 1 0 0 1 1-1h3v3a3 3 0 0 0 3 3h3v5Z",
|
|
2656
|
-
fill: "#fff"
|
|
2942
|
+
fill: color || "#fff"
|
|
2657
2943
|
})
|
|
2658
2944
|
});
|
|
2659
|
-
const $2da9626742e3560b$export$6470d09a29d34d08 = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
2945
|
+
const $2da9626742e3560b$export$6470d09a29d34d08 = ({ color: color })=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
2660
2946
|
width: "24",
|
|
2661
2947
|
height: "24",
|
|
2662
2948
|
viewBox: "0 0 24 24",
|
|
@@ -2664,7 +2950,7 @@ const $2da9626742e3560b$export$6470d09a29d34d08 = ()=>/*#__PURE__*/ (0, $3Sbms$j
|
|
|
2664
2950
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2665
2951
|
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
2666
2952
|
d: "M8 21H4a1 1 0 0 1-1-1v-4a1 1 0 1 0-2 0v4a3 3 0 0 0 3 3h4a1 1 0 0 0 0-2Zm14-6a1 1 0 0 0-1 1v4a1 1 0 0 1-1 1h-4a1 1 0 0 0 0 2h4a3 3 0 0 0 3-3v-4a1 1 0 0 0-1-1ZM20 1h-4a1 1 0 1 0 0 2h4a1 1 0 0 1 1 1v4a1 1 0 0 0 2 0V4a3 3 0 0 0-3-3ZM2 9a1 1 0 0 0 1-1V4a1 1 0 0 1 1-1h4a1 1 0 0 0 0-2H4a3 3 0 0 0-3 3v4a1 1 0 0 0 1 1Zm8-4H6a1 1 0 0 0-1 1v4a1 1 0 0 0 1 1h4a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1ZM9 9H7V7h2v2Zm5 2h4a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v4a1 1 0 0 0 1 1Zm1-4h2v2h-2V7Zm-5 6H6a1 1 0 0 0-1 1v4a1 1 0 0 0 1 1h4a1 1 0 0 0 1-1v-4a1 1 0 0 0-1-1Zm-1 4H7v-2h2v2Zm5-1a1 1 0 0 0 1-1 1 1 0 0 0 0-2h-1a1 1 0 0 0-1 1v1a1 1 0 0 0 1 1Zm4-3a1 1 0 0 0-1 1v3a1 1 0 0 0 0 2h1a1 1 0 0 0 1-1v-4a1 1 0 0 0-1-1Zm-4 4a1 1 0 1 0 0 2 1 1 0 0 0 0-2Z",
|
|
2667
|
-
fill: "#fff"
|
|
2953
|
+
fill: color || "#fff"
|
|
2668
2954
|
})
|
|
2669
2955
|
});
|
|
2670
2956
|
const $2da9626742e3560b$export$1095c93890fce526 = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
@@ -2719,6 +3005,17 @@ const $2da9626742e3560b$export$5170987d58ae338d = ()=>/*#__PURE__*/ (0, $3Sbms$j
|
|
|
2719
3005
|
]
|
|
2720
3006
|
})
|
|
2721
3007
|
});
|
|
3008
|
+
const $2da9626742e3560b$export$d5424e4dfe4be076 = ({ color: color })=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
3009
|
+
width: "24",
|
|
3010
|
+
height: "24",
|
|
3011
|
+
viewBox: "0 0 24 24",
|
|
3012
|
+
fill: "none",
|
|
3013
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
3014
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
3015
|
+
d: "M19 4H5a3 3 0 0 0-3 3v10a3 3 0 0 0 3 3h14a3 3 0 0 0 3-3V7a3 3 0 0 0-3-3ZM5 18a1 1 0 0 1-1-1v-2.42l3.3-3.29a1 1 0 0 1 1.4 0L15.41 18H5Zm15-1a1 1 0 0 1-1 1h-.77l-3.81-3.83.88-.88a1 1 0 0 1 1.4 0l3.3 3.29V17Zm0-3.24-1.88-1.87a3.06 3.06 0 0 0-4.24 0l-.88.88-2.88-2.88a3.06 3.06 0 0 0-4.24 0L4 11.76V7a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v6.76Z",
|
|
3016
|
+
fill: color || "#fff"
|
|
3017
|
+
})
|
|
3018
|
+
});
|
|
2722
3019
|
|
|
2723
3020
|
|
|
2724
3021
|
|
|
@@ -2909,10 +3206,17 @@ const $ab29487ffcc05855$export$e2457e1974c298c3 = (0, $3Sbms$styledcomponents).b
|
|
|
2909
3206
|
line-height: 16px;
|
|
2910
3207
|
padding: 4px 12px;
|
|
2911
3208
|
border-radius: 50px;
|
|
3209
|
+
gap: 5px;
|
|
2912
3210
|
|
|
2913
3211
|
&:hover {
|
|
2914
3212
|
border: 2px solid ${(props)=>props.theme.controlsHoverBorderColor};
|
|
2915
3213
|
}
|
|
3214
|
+
|
|
3215
|
+
img,
|
|
3216
|
+
svg {
|
|
3217
|
+
max-width: 15px;
|
|
3218
|
+
max-height: 15px;
|
|
3219
|
+
}
|
|
2916
3220
|
`;
|
|
2917
3221
|
const $ab29487ffcc05855$export$c4e460d5c7d83bc3 = (0, $3Sbms$styledcomponents).div`
|
|
2918
3222
|
position: absolute;
|
|
@@ -2940,12 +3244,18 @@ const $ae6e25be45301335$var$HeaderSettings = ({ baseCategories: baseCategories ,
|
|
|
2940
3244
|
...options,
|
|
2941
3245
|
...category.items
|
|
2942
3246
|
], []) || [];
|
|
2943
|
-
return definedSettingsShortcuts.reduce((shortcutsList,
|
|
2944
|
-
const baseShortcut = baseOptions.find((option)=>option.id ===
|
|
2945
|
-
if (baseShortcut) shortcutsList.push(
|
|
3247
|
+
return definedSettingsShortcuts.reduce((shortcutsList, shortcut)=>{
|
|
3248
|
+
const baseShortcut = baseOptions.find((option)=>option.id === shortcut.id);
|
|
3249
|
+
if (baseShortcut) shortcutsList.push({
|
|
3250
|
+
...baseShortcut,
|
|
3251
|
+
displayType: shortcut.displayType
|
|
3252
|
+
});
|
|
2946
3253
|
else {
|
|
2947
|
-
const extraShortcut = extraOptions?.find((option)=>option.id ===
|
|
2948
|
-
if (extraShortcut) shortcutsList.push(
|
|
3254
|
+
const extraShortcut = extraOptions?.find((option)=>option.id === shortcut.id);
|
|
3255
|
+
if (extraShortcut) shortcutsList.push({
|
|
3256
|
+
...extraShortcut,
|
|
3257
|
+
displayType: shortcut.displayType
|
|
3258
|
+
});
|
|
2949
3259
|
}
|
|
2950
3260
|
return shortcutsList;
|
|
2951
3261
|
}, []);
|
|
@@ -3002,7 +3312,19 @@ const $ae6e25be45301335$var$HeaderSettings = ({ baseCategories: baseCategories ,
|
|
|
3002
3312
|
const onSettingsButtonClick = ()=>setDisplaySettingsOptions((previousValue)=>!previousValue);
|
|
3003
3313
|
return /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $ab29487ffcc05855$export$8376625f8bb18347), {
|
|
3004
3314
|
children: [
|
|
3005
|
-
shortcuts.map((shortcut)
|
|
3315
|
+
shortcuts.map((shortcut)=>{
|
|
3316
|
+
if (shortcut.displayType === "full") return /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $ab29487ffcc05855$export$e2457e1974c298c3), {
|
|
3317
|
+
onClick: shortcut.action,
|
|
3318
|
+
children: [
|
|
3319
|
+
shortcut.jsxIcon && shortcut.jsxIcon,
|
|
3320
|
+
shortcut.srcIcon && /*#__PURE__*/ (0, $3Sbms$jsx)("img", {
|
|
3321
|
+
alt: shortcut.title,
|
|
3322
|
+
src: shortcut.srcIcon
|
|
3323
|
+
}),
|
|
3324
|
+
shortcut.title
|
|
3325
|
+
]
|
|
3326
|
+
}, shortcut.id);
|
|
3327
|
+
return /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $ab29487ffcc05855$export$4297bad962271b02), {
|
|
3006
3328
|
onClick: shortcut.action,
|
|
3007
3329
|
children: [
|
|
3008
3330
|
shortcut.jsxIcon && shortcut.jsxIcon,
|
|
@@ -3011,7 +3333,8 @@ const $ae6e25be45301335$var$HeaderSettings = ({ baseCategories: baseCategories ,
|
|
|
3011
3333
|
src: shortcut.srcIcon
|
|
3012
3334
|
})
|
|
3013
3335
|
]
|
|
3014
|
-
}, shortcut.id)
|
|
3336
|
+
}, shortcut.id);
|
|
3337
|
+
}),
|
|
3015
3338
|
streamUIOptions.showMenuButton && /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $ab29487ffcc05855$export$a7d9b76c122d0627), {
|
|
3016
3339
|
children: [
|
|
3017
3340
|
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $ab29487ffcc05855$export$e2457e1974c298c3), {
|
|
@@ -3212,7 +3535,7 @@ const $f235befa4cdc42d6$var$multiPiP = new (0, $e96d119a19ed0c6c$export$45fabd1c
|
|
|
3212
3535
|
const $f235befa4cdc42d6$var$browser = $3Sbms$parse(window.navigator.userAgent);
|
|
3213
3536
|
const $f235befa4cdc42d6$var$Header = ()=>{
|
|
3214
3537
|
const { t: t } = (0, $3Sbms$useTranslation)();
|
|
3215
|
-
const { setIsQuickConnectPopupVisible: setIsQuickConnectPopupVisible , setIsSettingsMenuVisible: setIsSettingsMenuVisible , options: options , muted: muted , streaming: streaming } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
3538
|
+
const { setIsQuickConnectPopupVisible: setIsQuickConnectPopupVisible , setIsSettingsMenuVisible: setIsSettingsMenuVisible , setIsVirtualBackgroundPopupVisible: setIsVirtualBackgroundPopupVisible , options: options , muted: muted , streaming: streaming , } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
3216
3539
|
const { streams: streams } = (0, $cce9fd41d8a55a18$export$b5633a7cfbe42d9f)();
|
|
3217
3540
|
const [extraOptions, setExtraOptions] = (0, $3Sbms$useState)(options.extraSettingsOptions || []);
|
|
3218
3541
|
const onSetExtraSettingsOptions = (event)=>{
|
|
@@ -3261,10 +3584,14 @@ const $f235befa4cdc42d6$var$Header = ()=>{
|
|
|
3261
3584
|
};
|
|
3262
3585
|
const onScanQuickConnectClick = ()=>{
|
|
3263
3586
|
setIsQuickConnectPopupVisible(true);
|
|
3587
|
+
(0, $3Sbms$hotjarbrowser).event("quickConnectClick");
|
|
3264
3588
|
};
|
|
3265
3589
|
const onSettingsMenuClick = ()=>{
|
|
3266
3590
|
setIsSettingsMenuVisible(true);
|
|
3267
3591
|
};
|
|
3592
|
+
const onVirtualBackgroundClick = ()=>{
|
|
3593
|
+
setIsVirtualBackgroundPopupVisible(true);
|
|
3594
|
+
};
|
|
3268
3595
|
const computedCategories = [
|
|
3269
3596
|
{
|
|
3270
3597
|
id: "1",
|
|
@@ -3306,6 +3633,12 @@ const $f235befa4cdc42d6$var$Header = ()=>{
|
|
|
3306
3633
|
]
|
|
3307
3634
|
},
|
|
3308
3635
|
];
|
|
3636
|
+
if ($f235befa4cdc42d6$var$browser.platform.type === "desktop" && $f235befa4cdc42d6$var$browser.engine.name === "Blink") computedCategories[2].items.push({
|
|
3637
|
+
id: "virtualBackground",
|
|
3638
|
+
title: t("virtualBackground.title"),
|
|
3639
|
+
jsxIcon: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $2da9626742e3560b$export$d5424e4dfe4be076), {}),
|
|
3640
|
+
action: onVirtualBackgroundClick
|
|
3641
|
+
});
|
|
3309
3642
|
if (document.pictureInPictureEnabled && $f235befa4cdc42d6$var$browser.platform.type === "desktop") computedCategories[0].items.push({
|
|
3310
3643
|
id: "pip",
|
|
3311
3644
|
title: t("menu.pictureInPicture"),
|
|
@@ -3319,6 +3652,7 @@ const $f235befa4cdc42d6$var$Header = ()=>{
|
|
|
3319
3652
|
options.sharedURL,
|
|
3320
3653
|
setIsQuickConnectPopupVisible,
|
|
3321
3654
|
setIsSettingsMenuVisible,
|
|
3655
|
+
setIsVirtualBackgroundPopupVisible,
|
|
3322
3656
|
t,
|
|
3323
3657
|
]);
|
|
3324
3658
|
return /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $ab29487ffcc05855$export$1e86fd0e1db89578), {
|
|
@@ -3952,7 +4286,7 @@ const $6efc75079651494a$export$98d9314e6a208b24 = (0, $3Sbms$styledcomponents).d
|
|
|
3952
4286
|
if (props.full) return (0, $3Sbms$css)`
|
|
3953
4287
|
width: 100%;
|
|
3954
4288
|
height: 100%;
|
|
3955
|
-
|
|
4289
|
+
right: 0px;
|
|
3956
4290
|
padding: 17px 10px;
|
|
3957
4291
|
box-sizing: border-box;
|
|
3958
4292
|
`;
|
|
@@ -4810,7 +5144,8 @@ const $5939a59dc7c96d41$var$SelfStreamTile = ({ isSomeonePresenting: isSomeonePr
|
|
|
4810
5144
|
const [containerWidth, containerHeight] = (0, $af23c74942bdcae7$export$2b86bedf890eab8)(videosContainerRef.current);
|
|
4811
5145
|
const isAlone = streams.length < 1;
|
|
4812
5146
|
const cursor = streaming && !isAlone && !extended ? "pointer" : "default";
|
|
4813
|
-
let
|
|
5147
|
+
let tileWidth = orientation === "landscape" ? "50%" : "100%";
|
|
5148
|
+
let tileHeight = orientation === "landscape" ? "100%" : "50%";
|
|
4814
5149
|
if (!isAlone) {
|
|
4815
5150
|
const computedWidth = (0, $b8e10de7c6dba8c4$export$a6112fefa8de799d)({
|
|
4816
5151
|
containerWidth: containerWidth,
|
|
@@ -4820,7 +5155,8 @@ const $5939a59dc7c96d41$var$SelfStreamTile = ({ isSomeonePresenting: isSomeonePr
|
|
|
4820
5155
|
orientation: orientation,
|
|
4821
5156
|
extended: extended
|
|
4822
5157
|
});
|
|
4823
|
-
|
|
5158
|
+
tileWidth = `${computedWidth}px`;
|
|
5159
|
+
tileHeight = `${computedWidth}px`;
|
|
4824
5160
|
}
|
|
4825
5161
|
const onLocalVideoChange = (event)=>{
|
|
4826
5162
|
if (!event.detail?.camera?.device) return;
|
|
@@ -4871,7 +5207,7 @@ const $5939a59dc7c96d41$var$SelfStreamTile = ({ isSomeonePresenting: isSomeonePr
|
|
|
4871
5207
|
if (streams.length === 1) {
|
|
4872
5208
|
const userName = streams[0].profile.name || t("misc.user");
|
|
4873
5209
|
notificationMessage = t("snapshot.sentToUser", {
|
|
4874
|
-
|
|
5210
|
+
user: userName
|
|
4875
5211
|
});
|
|
4876
5212
|
}
|
|
4877
5213
|
(0, $a5146f9062d7bf28$export$3a57e165650c636f)(notificationMessage, {
|
|
@@ -5059,8 +5395,8 @@ const $5939a59dc7c96d41$var$SelfStreamTile = ({ isSomeonePresenting: isSomeonePr
|
|
|
5059
5395
|
ref: SelfTileRef,
|
|
5060
5396
|
full: isAlone,
|
|
5061
5397
|
style: {
|
|
5062
|
-
width:
|
|
5063
|
-
height:
|
|
5398
|
+
width: tileWidth,
|
|
5399
|
+
height: tileHeight
|
|
5064
5400
|
},
|
|
5065
5401
|
cursor: cursor,
|
|
5066
5402
|
onClick: onSelfTileClick,
|
|
@@ -5896,8 +6232,113 @@ var $b496fc6f0d99c06d$export$2e2bcd8739ae039 = $b496fc6f0d99c06d$var$Highlighted
|
|
|
5896
6232
|
|
|
5897
6233
|
|
|
5898
6234
|
|
|
6235
|
+
const $b56218b5a57cb77c$export$d653589df987fd93 = (0, $3Sbms$styledcomponents).div`
|
|
6236
|
+
display: flex;
|
|
6237
|
+
position: absolute;
|
|
6238
|
+
z-index: 20;
|
|
6239
|
+
left: 0;
|
|
6240
|
+
top: 0;
|
|
6241
|
+
transition: all 0.4s;
|
|
6242
|
+
width: ${({ orientation: orientation })=>orientation === "landscape" ? "50%" : "100%"};
|
|
6243
|
+
height: ${({ orientation: orientation })=>orientation === "landscape" ? "100%" : "50%"};
|
|
6244
|
+
padding: 17px 10px;
|
|
6245
|
+
box-sizing: border-box;
|
|
6246
|
+
`;
|
|
6247
|
+
const $b56218b5a57cb77c$export$dd2ac23a70f320dd = (0, $3Sbms$styledcomponents).div`
|
|
6248
|
+
display: flex;
|
|
6249
|
+
flex-direction: column;
|
|
6250
|
+
justify-content: center;
|
|
6251
|
+
align-items: center;
|
|
6252
|
+
position: relative;
|
|
6253
|
+
width: 100%;
|
|
6254
|
+
height: 100%;
|
|
6255
|
+
background-color: ${({ theme: theme })=>theme.streamTileBackgroundColor};
|
|
6256
|
+
border: 2px solid ${({ theme: theme })=>theme.streamTileBorderColor};
|
|
6257
|
+
border-radius: 20px;
|
|
6258
|
+
box-sizing: border-box;
|
|
6259
|
+
color: #fff;
|
|
6260
|
+
font-family: Lato;
|
|
6261
|
+
`;
|
|
6262
|
+
const $b56218b5a57cb77c$export$2dabfbe763cc7a4 = (0, $3Sbms$styledcomponents).h2`
|
|
6263
|
+
font-weight: 600;
|
|
6264
|
+
font-size: 16px;
|
|
6265
|
+
text-align: center;
|
|
6266
|
+
width: 300px;
|
|
6267
|
+
`;
|
|
6268
|
+
const $b56218b5a57cb77c$export$6ed6e36e1b456f96 = (0, $3Sbms$styledcomponents).div`
|
|
6269
|
+
position: relative;
|
|
6270
|
+
display: flex;
|
|
6271
|
+
align-items: center;
|
|
6272
|
+
height: 50px;
|
|
6273
|
+
width: 300px;
|
|
6274
|
+
background-color: ${({ theme: theme })=>theme.popupBackgroundSecondaryColor};
|
|
6275
|
+
border: 1px solid ${({ theme: theme })=>theme.popupBorderColor};
|
|
6276
|
+
border-radius: 15px;
|
|
6277
|
+
padding: 0 10px;
|
|
6278
|
+
`;
|
|
6279
|
+
const $b56218b5a57cb77c$export$5f759de1870a3e41 = (0, $3Sbms$styledcomponents).div`
|
|
6280
|
+
display: flex;
|
|
6281
|
+
align-items: center;
|
|
6282
|
+
width: 100%;
|
|
6283
|
+
gap: 5px;
|
|
6284
|
+
|
|
6285
|
+
svg {
|
|
6286
|
+
width: 20px;
|
|
6287
|
+
height: 20px;
|
|
6288
|
+
}
|
|
6289
|
+
`;
|
|
6290
|
+
const $b56218b5a57cb77c$export$c6b180e8ec79154e = (0, $3Sbms$styledcomponents).p`
|
|
6291
|
+
color: #242324;
|
|
6292
|
+
font-size: 15px;
|
|
6293
|
+
font-weight: 600;
|
|
6294
|
+
width: 100%;
|
|
6295
|
+
text-overflow: ellipsis;
|
|
6296
|
+
white-space: nowrap;
|
|
6297
|
+
overflow: hidden;
|
|
6298
|
+
line-height: 15px;
|
|
6299
|
+
`;
|
|
6300
|
+
const $b56218b5a57cb77c$export$d7f3ab4b3437ad97 = (0, $3Sbms$styledcomponents).button`
|
|
6301
|
+
position: absolute;
|
|
6302
|
+
right: 5px;
|
|
6303
|
+
display: flex;
|
|
6304
|
+
justify-content: center;
|
|
6305
|
+
align-items: center;
|
|
6306
|
+
background-color: ${({ theme: theme })=>theme.primaryColor};
|
|
6307
|
+
border: none;
|
|
6308
|
+
border-radius: 8px;
|
|
6309
|
+
height: 32px;
|
|
6310
|
+
color: #fff;
|
|
6311
|
+
font-weight: 600;
|
|
6312
|
+
font-size: 16px;
|
|
6313
|
+
padding: 8px 12px;
|
|
6314
|
+
line-height: 18px;
|
|
6315
|
+
`;
|
|
6316
|
+
const $b56218b5a57cb77c$export$c22678f0e7b404e0 = (0, $3Sbms$styledcomponents).p`
|
|
6317
|
+
font-size: 12px;
|
|
6318
|
+
font-weight: 400;
|
|
6319
|
+
width: 300px;
|
|
6320
|
+
text-align: center;
|
|
6321
|
+
`;
|
|
6322
|
+
|
|
6323
|
+
|
|
6324
|
+
|
|
6325
|
+
|
|
5899
6326
|
|
|
5900
6327
|
|
|
6328
|
+
const $1ec1d06e0a21fdaa$var$Link = ({ color: color })=>{
|
|
6329
|
+
return /*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
6330
|
+
width: "24",
|
|
6331
|
+
height: "24",
|
|
6332
|
+
viewBox: "0 0 24 24",
|
|
6333
|
+
fill: "none",
|
|
6334
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
6335
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
6336
|
+
d: "m12.11 15.39-3.88 3.88a2.52 2.52 0 0 1-3.5 0 2.47 2.47 0 0 1 0-3.5l3.88-3.88a1.004 1.004 0 0 0-1.42-1.42l-3.88 3.89a4.48 4.48 0 0 0 6.33 6.33l3.89-3.88a1.004 1.004 0 1 0-1.42-1.42Zm8.58-12.08a4.49 4.49 0 0 0-6.33 0l-3.89 3.88a1.004 1.004 0 0 0 1.42 1.42l3.88-3.88a2.52 2.52 0 0 1 3.5 0 2.471 2.471 0 0 1 0 3.5l-3.88 3.88a1.002 1.002 0 0 0 .325 1.639.999.999 0 0 0 1.095-.219l3.88-3.89a4.49 4.49 0 0 0 0-6.33ZM8.83 15.17a1 1 0 0 0 .71.29 1 1 0 0 0 .71-.29l4.92-4.92a1.004 1.004 0 0 0-1.42-1.42l-4.92 4.92a1 1 0 0 0 0 1.42Z",
|
|
6337
|
+
fill: color || "#fff"
|
|
6338
|
+
})
|
|
6339
|
+
});
|
|
6340
|
+
};
|
|
6341
|
+
var $1ec1d06e0a21fdaa$export$2e2bcd8739ae039 = $1ec1d06e0a21fdaa$var$Link;
|
|
5901
6342
|
|
|
5902
6343
|
|
|
5903
6344
|
|
|
@@ -5950,6 +6391,64 @@ const $93a0377c243d965e$export$c7df1b15b59b1df2 = /*#__PURE__*/ (0, $3Sbms$jsxs)
|
|
|
5950
6391
|
});
|
|
5951
6392
|
|
|
5952
6393
|
|
|
6394
|
+
const $f0b0b18fe6c6ae77$var$InvitationTile = ({ orientation: orientation })=>{
|
|
6395
|
+
const { t: t } = (0, $3Sbms$useTranslation)();
|
|
6396
|
+
const onCopyCallLinkClick = async ()=>{
|
|
6397
|
+
try {
|
|
6398
|
+
await (0, $57162bcada7d6f66$export$2e2bcd8739ae039)(window.location.href);
|
|
6399
|
+
(0, $a5146f9062d7bf28$export$3a57e165650c636f)(t("copyLink.copied"), {
|
|
6400
|
+
duration: 2000
|
|
6401
|
+
});
|
|
6402
|
+
} catch (copyError) {
|
|
6403
|
+
console.warn(copyError);
|
|
6404
|
+
(0, $a5146f9062d7bf28$export$3a57e165650c636f)(t("copyLink.error"), {
|
|
6405
|
+
icon: (0, $93a0377c243d965e$export$edf27be85e5f6da0)
|
|
6406
|
+
});
|
|
6407
|
+
}
|
|
6408
|
+
};
|
|
6409
|
+
return /*#__PURE__*/ (0, $3Sbms$jsx)((0, $b56218b5a57cb77c$export$d653589df987fd93), {
|
|
6410
|
+
orientation: orientation,
|
|
6411
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $b56218b5a57cb77c$export$dd2ac23a70f320dd), {
|
|
6412
|
+
orientation: orientation,
|
|
6413
|
+
children: [
|
|
6414
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $b56218b5a57cb77c$export$2dabfbe763cc7a4), {
|
|
6415
|
+
children: t("invite.title")
|
|
6416
|
+
}),
|
|
6417
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $b56218b5a57cb77c$export$6ed6e36e1b456f96), {
|
|
6418
|
+
children: [
|
|
6419
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $b56218b5a57cb77c$export$5f759de1870a3e41), {
|
|
6420
|
+
children: [
|
|
6421
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $1ec1d06e0a21fdaa$export$2e2bcd8739ae039), {
|
|
6422
|
+
color: "black"
|
|
6423
|
+
}),
|
|
6424
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $b56218b5a57cb77c$export$c6b180e8ec79154e), {
|
|
6425
|
+
children: window.location.href
|
|
6426
|
+
})
|
|
6427
|
+
]
|
|
6428
|
+
}),
|
|
6429
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $b56218b5a57cb77c$export$d7f3ab4b3437ad97), {
|
|
6430
|
+
onClick: onCopyCallLinkClick,
|
|
6431
|
+
children: t("invite.copy")
|
|
6432
|
+
})
|
|
6433
|
+
]
|
|
6434
|
+
}),
|
|
6435
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $b56218b5a57cb77c$export$c22678f0e7b404e0), {
|
|
6436
|
+
children: t("invite.description")
|
|
6437
|
+
})
|
|
6438
|
+
]
|
|
6439
|
+
})
|
|
6440
|
+
});
|
|
6441
|
+
};
|
|
6442
|
+
var $f0b0b18fe6c6ae77$export$2e2bcd8739ae039 = $f0b0b18fe6c6ae77$var$InvitationTile;
|
|
6443
|
+
|
|
6444
|
+
|
|
6445
|
+
|
|
6446
|
+
|
|
6447
|
+
|
|
6448
|
+
|
|
6449
|
+
|
|
6450
|
+
|
|
6451
|
+
|
|
5953
6452
|
const $b8963bf62cf5b984$var$Container = (0, $3Sbms$styledcomponents).div`
|
|
5954
6453
|
background-color: rgba(45, 45, 45, 0.75);
|
|
5955
6454
|
display: flex;
|
|
@@ -6199,6 +6698,9 @@ const $cdab47bb8796991e$var$Video = ()=>{
|
|
|
6199
6698
|
width: tileSize.width,
|
|
6200
6699
|
height: tileSize.height
|
|
6201
6700
|
}, stream.id);
|
|
6701
|
+
}),
|
|
6702
|
+
streams.length < 1 && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $f0b0b18fe6c6ae77$export$2e2bcd8739ae039), {
|
|
6703
|
+
orientation: orientation
|
|
6202
6704
|
})
|
|
6203
6705
|
]
|
|
6204
6706
|
})
|
|
@@ -6217,6 +6719,7 @@ var $cdab47bb8796991e$export$2e2bcd8739ae039 = $cdab47bb8796991e$var$Video;
|
|
|
6217
6719
|
|
|
6218
6720
|
|
|
6219
6721
|
|
|
6722
|
+
|
|
6220
6723
|
const $f0e90fb231c59fab$var$HangUp = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
6221
6724
|
width: "25",
|
|
6222
6725
|
height: "24",
|
|
@@ -6313,7 +6816,8 @@ var $8b7bd174d29d9a1f$export$2e2bcd8739ae039 = $8b7bd174d29d9a1f$var$Spinner;
|
|
|
6313
6816
|
|
|
6314
6817
|
|
|
6315
6818
|
|
|
6316
|
-
|
|
6819
|
+
|
|
6820
|
+
const $a2d206a438475087$var$YoutubeIcon = ({ color: color })=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
6317
6821
|
width: "24",
|
|
6318
6822
|
height: "25",
|
|
6319
6823
|
viewBox: "0 0 24 25",
|
|
@@ -6321,29 +6825,13 @@ const $a2d206a438475087$var$YoutubeIcon = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg
|
|
|
6321
6825
|
xmlns: "http://www.w3.org/2000/svg",
|
|
6322
6826
|
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
6323
6827
|
d: "M23 10.21a8.499 8.499 0 0 0-.91-4.13 2.92 2.92 0 0 0-1.72-1A78.362 78.362 0 0 0 12 4.77a78.45 78.45 0 0 0-8.34.3 2.87 2.87 0 0 0-1.46.74c-.9.83-1 2.25-1.1 3.45a48.29 48.29 0 0 0 0 6.48 9.55 9.55 0 0 0 .3 2c.12.505.365.972.71 1.36a2.86 2.86 0 0 0 1.49.78c2.156.266 4.328.376 6.5.33 3.5.05 6.57 0 10.2-.28a2.88 2.88 0 0 0 1.53-.78c.28-.28.49-.623.61-1 .358-1.097.533-2.246.52-3.4.04-.56.04-3.94.04-4.54ZM9.74 15.35V9.16l5.92 3.11c-1.66.92-3.85 1.96-5.92 3.08Z",
|
|
6324
|
-
fill: "#fff"
|
|
6828
|
+
fill: color || "#fff"
|
|
6325
6829
|
})
|
|
6326
6830
|
});
|
|
6327
6831
|
var $a2d206a438475087$export$2e2bcd8739ae039 = $a2d206a438475087$var$YoutubeIcon;
|
|
6328
6832
|
|
|
6329
6833
|
|
|
6330
6834
|
|
|
6331
|
-
const $1ec1d06e0a21fdaa$var$Link = ()=>{
|
|
6332
|
-
return /*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
6333
|
-
width: "24",
|
|
6334
|
-
height: "24",
|
|
6335
|
-
viewBox: "0 0 24 24",
|
|
6336
|
-
fill: "none",
|
|
6337
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
6338
|
-
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
6339
|
-
d: "m12.11 15.39-3.88 3.88a2.52 2.52 0 0 1-3.5 0 2.47 2.47 0 0 1 0-3.5l3.88-3.88a1.004 1.004 0 0 0-1.42-1.42l-3.88 3.89a4.48 4.48 0 0 0 6.33 6.33l3.89-3.88a1.004 1.004 0 1 0-1.42-1.42Zm8.58-12.08a4.49 4.49 0 0 0-6.33 0l-3.89 3.88a1.004 1.004 0 0 0 1.42 1.42l3.88-3.88a2.52 2.52 0 0 1 3.5 0 2.471 2.471 0 0 1 0 3.5l-3.88 3.88a1.002 1.002 0 0 0 .325 1.639.999.999 0 0 0 1.095-.219l3.88-3.89a4.49 4.49 0 0 0 0-6.33ZM8.83 15.17a1 1 0 0 0 .71.29 1 1 0 0 0 .71-.29l4.92-4.92a1.004 1.004 0 0 0-1.42-1.42l-4.92 4.92a1 1 0 0 0 0 1.42Z",
|
|
6340
|
-
fill: "#fff"
|
|
6341
|
-
})
|
|
6342
|
-
});
|
|
6343
|
-
};
|
|
6344
|
-
var $1ec1d06e0a21fdaa$export$2e2bcd8739ae039 = $1ec1d06e0a21fdaa$var$Link;
|
|
6345
|
-
|
|
6346
|
-
|
|
6347
6835
|
|
|
6348
6836
|
|
|
6349
6837
|
|
|
@@ -6442,9 +6930,12 @@ const $db92fac48417791a$var$HighlightButton = ()=>{
|
|
|
6442
6930
|
const onScreenshareClick = async ()=>{
|
|
6443
6931
|
setIsHighlightMenuOpen(false);
|
|
6444
6932
|
try {
|
|
6933
|
+
(0, $3Sbms$hotjarbrowser).event("screenshareClick");
|
|
6445
6934
|
await (0, $c9e496369b59be7a$export$2f377c2162fd02b2).enableScreenshare();
|
|
6935
|
+
(0, $3Sbms$hotjarbrowser).event("enableScreenshare");
|
|
6446
6936
|
} catch (screenshareError) {
|
|
6447
6937
|
console.warn(screenshareError);
|
|
6938
|
+
(0, $3Sbms$hotjarbrowser).event("screenshareCancel");
|
|
6448
6939
|
(0, $3Sbms$reacthottoast)(t("notifications.screensharingError"), {
|
|
6449
6940
|
className: "error"
|
|
6450
6941
|
});
|
|
@@ -6453,10 +6944,12 @@ const $db92fac48417791a$var$HighlightButton = ()=>{
|
|
|
6453
6944
|
const onYoutubeClick = ()=>{
|
|
6454
6945
|
setIsHighlightMenuOpen(false);
|
|
6455
6946
|
setIsYoutubePopupVisible(true);
|
|
6947
|
+
(0, $3Sbms$hotjarbrowser).event("youtubeClick");
|
|
6456
6948
|
};
|
|
6457
6949
|
const onLinkshareClick = ()=>{
|
|
6458
6950
|
setIsHighlightMenuOpen(false);
|
|
6459
6951
|
setIsLinksharePopupVisible(true);
|
|
6952
|
+
(0, $3Sbms$hotjarbrowser).event("linkshareClick");
|
|
6460
6953
|
};
|
|
6461
6954
|
const menuCategories = [
|
|
6462
6955
|
{
|
|
@@ -6470,7 +6963,7 @@ const $db92fac48417791a$var$HighlightButton = ()=>{
|
|
|
6470
6963
|
},
|
|
6471
6964
|
{
|
|
6472
6965
|
id: "youtube",
|
|
6473
|
-
title: "
|
|
6966
|
+
title: t("youtube.title"),
|
|
6474
6967
|
jsxIcon: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $a2d206a438475087$export$2e2bcd8739ae039), {}),
|
|
6475
6968
|
action: onYoutubeClick
|
|
6476
6969
|
},
|
|
@@ -6524,8 +7017,13 @@ const $69a9c49ece80e773$var$ControlBar = ()=>{
|
|
|
6524
7017
|
const onMicrophoneClick = async ()=>{
|
|
6525
7018
|
try {
|
|
6526
7019
|
const devicesState = (0, $c9e496369b59be7a$export$2f377c2162fd02b2).getDevicesState();
|
|
6527
|
-
if (devicesState.microphone.enabled)
|
|
6528
|
-
|
|
7020
|
+
if (devicesState.microphone.enabled) {
|
|
7021
|
+
(0, $3Sbms$hotjarbrowser).event("toggleMicrophone");
|
|
7022
|
+
await (0, $c9e496369b59be7a$export$2f377c2162fd02b2).toggleMute();
|
|
7023
|
+
} else {
|
|
7024
|
+
(0, $3Sbms$hotjarbrowser).event("enableMicrophone");
|
|
7025
|
+
await (0, $c9e496369b59be7a$export$2f377c2162fd02b2).enableMicrophone();
|
|
7026
|
+
}
|
|
6529
7027
|
} catch (muteError) {
|
|
6530
7028
|
console.warn(muteError);
|
|
6531
7029
|
(0, $3Sbms$reacthottoast)(t("notifications.microphoneError"), {
|
|
@@ -6535,9 +7033,12 @@ const $69a9c49ece80e773$var$ControlBar = ()=>{
|
|
|
6535
7033
|
};
|
|
6536
7034
|
const onCameraClick = async ()=>{
|
|
6537
7035
|
try {
|
|
6538
|
-
if (streaming)
|
|
6539
|
-
|
|
7036
|
+
if (streaming) {
|
|
7037
|
+
(0, $3Sbms$hotjarbrowser).event("disableCamera");
|
|
7038
|
+
await (0, $c9e496369b59be7a$export$2f377c2162fd02b2).disableVideo();
|
|
7039
|
+
} else {
|
|
6540
7040
|
setIsCameraLoading(true);
|
|
7041
|
+
(0, $3Sbms$hotjarbrowser).event("enableCamera");
|
|
6541
7042
|
await (0, $c9e496369b59be7a$export$2f377c2162fd02b2).enableVideo();
|
|
6542
7043
|
}
|
|
6543
7044
|
} catch (cameraError) {
|
|
@@ -6551,6 +7052,7 @@ const $69a9c49ece80e773$var$ControlBar = ()=>{
|
|
|
6551
7052
|
};
|
|
6552
7053
|
const onRotateClick = async ()=>{
|
|
6553
7054
|
try {
|
|
7055
|
+
(0, $3Sbms$hotjarbrowser).event("rotateCamera");
|
|
6554
7056
|
await (0, $c9e496369b59be7a$export$2f377c2162fd02b2).rotateVideo();
|
|
6555
7057
|
} catch (rotateError) {
|
|
6556
7058
|
console.warn(rotateError);
|
|
@@ -6657,15 +7159,20 @@ var $69a9c49ece80e773$export$2e2bcd8739ae039 = $69a9c49ece80e773$var$ControlBar;
|
|
|
6657
7159
|
|
|
6658
7160
|
|
|
6659
7161
|
|
|
7162
|
+
|
|
7163
|
+
|
|
7164
|
+
|
|
7165
|
+
|
|
7166
|
+
|
|
6660
7167
|
const $8d3d0e80c56cde5c$export$9d03e7b857083c37 = (0, $3Sbms$styledcomponents).div`
|
|
6661
7168
|
position: absolute;
|
|
6662
7169
|
width: 100%;
|
|
6663
|
-
bottom: ${(props)=>props.open ? 0 : "-
|
|
7170
|
+
bottom: ${(props)=>props.open ? 0 : "-500px"};
|
|
6664
7171
|
transition: all 0.4s;
|
|
6665
7172
|
|
|
6666
7173
|
${(props)=>{
|
|
6667
7174
|
if (props.desktop) return (0, $3Sbms$css)`
|
|
6668
|
-
bottom: ${props.open ? 0 : "calc(-
|
|
7175
|
+
bottom: ${props.open ? 0 : "calc(-500px - (100vh / 2))"};
|
|
6669
7176
|
height: 100%;
|
|
6670
7177
|
display: flex;
|
|
6671
7178
|
justify-content: center;
|
|
@@ -6676,11 +7183,12 @@ const $8d3d0e80c56cde5c$export$9d03e7b857083c37 = (0, $3Sbms$styledcomponents).d
|
|
|
6676
7183
|
const $8d3d0e80c56cde5c$export$6bc4d6c63b7f8b75 = (0, $3Sbms$styledcomponents).div`
|
|
6677
7184
|
display: flex;
|
|
6678
7185
|
flex-direction: column;
|
|
6679
|
-
height:
|
|
7186
|
+
height: 500px;
|
|
6680
7187
|
max-height: 100vh;
|
|
6681
|
-
background-color: ${(props)=>props.theme.
|
|
6682
|
-
color: ${(props)=>props.theme.
|
|
7188
|
+
background-color: ${(props)=>props.theme.popupBackgroundPrimaryColor};
|
|
7189
|
+
color: ${(props)=>props.theme.popupTitleColor};
|
|
6683
7190
|
border-radius: ${(props)=>props.desktop ? "20px" : "20px 20px 0 0"};
|
|
7191
|
+
padding-bottom: ${({ desktop: desktop })=>desktop ? 0 : "12px"};
|
|
6684
7192
|
`;
|
|
6685
7193
|
const $8d3d0e80c56cde5c$export$f8e80e2c9abbb7eb = (0, $3Sbms$styledcomponents).div`
|
|
6686
7194
|
display: flex;
|
|
@@ -6693,15 +7201,30 @@ const $8d3d0e80c56cde5c$export$f8e80e2c9abbb7eb = (0, $3Sbms$styledcomponents).d
|
|
|
6693
7201
|
font-weight: 600;
|
|
6694
7202
|
}
|
|
6695
7203
|
`;
|
|
7204
|
+
const $8d3d0e80c56cde5c$export$2bd9c7c3b36c82cd = (0, $3Sbms$styledcomponents).div`
|
|
7205
|
+
display: flex;
|
|
7206
|
+
align-items: center;
|
|
7207
|
+
|
|
7208
|
+
h4 {
|
|
7209
|
+
margin: 0 0 0 8px;
|
|
7210
|
+
font-weight: 600;
|
|
7211
|
+
line-height: 19px;
|
|
7212
|
+
}
|
|
7213
|
+
|
|
7214
|
+
svg {
|
|
7215
|
+
width: 20px;
|
|
7216
|
+
height: 20px;
|
|
7217
|
+
}
|
|
7218
|
+
`;
|
|
6696
7219
|
const $8d3d0e80c56cde5c$export$b421c25a8e0ea22e = (0, $3Sbms$styledcomponents).button`
|
|
6697
7220
|
display: flex;
|
|
6698
7221
|
justify-content: center;
|
|
6699
7222
|
align-items: center;
|
|
6700
7223
|
border: none;
|
|
6701
|
-
background-color: ${(props)=>props.theme.
|
|
7224
|
+
background-color: ${(props)=>props.theme.popupBackgroundSecondaryColor};
|
|
6702
7225
|
border-radius: 50%;
|
|
6703
|
-
height:
|
|
6704
|
-
width:
|
|
7226
|
+
height: 30px;
|
|
7227
|
+
width: 30px;
|
|
6705
7228
|
padding: 0;
|
|
6706
7229
|
|
|
6707
7230
|
svg {
|
|
@@ -6716,6 +7239,7 @@ const $8d3d0e80c56cde5c$export$b421c25a8e0ea22e = (0, $3Sbms$styledcomponents).b
|
|
|
6716
7239
|
const $8d3d0e80c56cde5c$export$dc1a3f6996a97083 = (0, $3Sbms$styledcomponents).div`
|
|
6717
7240
|
display: flex;
|
|
6718
7241
|
justify-content: center;
|
|
7242
|
+
align-items: center;
|
|
6719
7243
|
flex: 1;
|
|
6720
7244
|
height: 0;
|
|
6721
7245
|
|
|
@@ -6729,13 +7253,57 @@ const $8d3d0e80c56cde5c$export$51760c3b0f5567d2 = (0, $3Sbms$styledcomponents).p
|
|
|
6729
7253
|
display: flex;
|
|
6730
7254
|
justify-content: center;
|
|
6731
7255
|
text-align: center;
|
|
6732
|
-
margin:
|
|
7256
|
+
margin: 0px 16% 20px;
|
|
6733
7257
|
font-size: 14px;
|
|
6734
7258
|
`;
|
|
7259
|
+
const $8d3d0e80c56cde5c$export$6a789d1ce3bcb863 = (0, $3Sbms$styledcomponents).button`
|
|
7260
|
+
font-size: 100%;
|
|
7261
|
+
font-family: inherit;
|
|
7262
|
+
font-weight: 700;
|
|
7263
|
+
background-color: inherit;
|
|
7264
|
+
border: 0;
|
|
7265
|
+
padding: 0;
|
|
7266
|
+
margin: 20px 0;
|
|
7267
|
+
display: flex;
|
|
7268
|
+
flex-direction: row;
|
|
7269
|
+
gap: 5px;
|
|
7270
|
+
align-items: center;
|
|
7271
|
+
justify-content: center;
|
|
7272
|
+
color: ${({ theme: theme })=>theme.popupTitleColor};
|
|
7273
|
+
`;
|
|
7274
|
+
const $8d3d0e80c56cde5c$export$c58a46cd2027881e = (0, $3Sbms$styledcomponents).image`
|
|
7275
|
+
position: absolute;
|
|
7276
|
+
with: 70px;
|
|
7277
|
+
height: 70px;
|
|
7278
|
+
`;
|
|
6735
7279
|
|
|
6736
7280
|
|
|
6737
|
-
|
|
6738
|
-
|
|
7281
|
+
|
|
7282
|
+
const $16d11fc0880587fd$var$QuickConnectLogo = ()=>/*#__PURE__*/ (0, $3Sbms$jsxs)("svg", {
|
|
7283
|
+
width: "71",
|
|
7284
|
+
height: "70",
|
|
7285
|
+
viewBox: "0 0 71 70",
|
|
7286
|
+
fill: "none",
|
|
7287
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
7288
|
+
children: [
|
|
7289
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
7290
|
+
d: "M2 35c0-7.171.386-12.832 1.38-17.303.99-4.454 2.562-7.635 4.872-9.945 2.31-2.31 5.491-3.882 9.945-4.872C22.668 1.886 28.33 1.5 35.5 1.5c7.171 0 12.832.386 17.303 1.38 4.454.99 7.635 2.562 9.945 4.872 2.31 2.31 3.882 5.491 4.872 9.945C68.614 22.168 69 27.83 69 35c0 7.171-.386 12.832-1.38 17.303-.99 4.454-2.562 7.635-4.872 9.945-2.31 2.31-5.491 3.882-9.945 4.872-4.471.994-10.132 1.38-17.303 1.38-7.171 0-12.832-.386-17.303-1.38-4.454-.99-7.635-2.562-9.945-4.872-2.31-2.31-3.882-5.491-4.872-9.945C2.386 47.832 2 42.17 2 35Z",
|
|
7291
|
+
fill: "#000",
|
|
7292
|
+
stroke: "#fff",
|
|
7293
|
+
strokeWidth: "3"
|
|
7294
|
+
}),
|
|
7295
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
7296
|
+
d: "M35.72 55.833c2.3 0 4.229-1.91 3.518-4.099a13.01 13.01 0 0 0-3.045-5.058c-2.365-2.43-5.572-3.794-8.917-3.794-3.344 0-6.551 1.365-8.916 3.794a13.01 13.01 0 0 0-3.045 5.058c-.711 2.189 1.217 4.099 3.518 4.099H35.72ZM35.28 14.167c-2.3 0-4.229 1.91-3.518 4.099a13.008 13.008 0 0 0 3.045 5.058c2.365 2.43 5.572 3.793 8.917 3.793 3.344 0 6.551-1.364 8.916-3.793a13.005 13.005 0 0 0 3.045-5.058c.711-2.189-1.217-4.099-3.519-4.099H35.281ZM43.724 51.667c0 2.301 1.916 4.231 4.087 3.467a12.565 12.565 0 0 0 4.829-3.094c2.365-2.428 3.693-5.722 3.693-9.157 0-3.435-1.328-6.729-3.693-9.158a12.565 12.565 0 0 0-4.829-3.093c-2.17-.764-4.087 1.166-4.087 3.467v17.568ZM27.277 18.333c0-2.3-1.917-4.23-4.088-3.467a12.565 12.565 0 0 0-4.829 3.094c-2.364 2.429-3.693 5.723-3.693 9.157 0 3.435 1.329 6.729 3.693 9.158a12.565 12.565 0 0 0 4.83 3.093c2.17.764 4.087-1.166 4.087-3.467V18.333Z",
|
|
7297
|
+
fill: "#fff"
|
|
7298
|
+
})
|
|
7299
|
+
]
|
|
7300
|
+
});
|
|
7301
|
+
var $16d11fc0880587fd$export$2e2bcd8739ae039 = $16d11fc0880587fd$var$QuickConnectLogo;
|
|
7302
|
+
|
|
7303
|
+
|
|
7304
|
+
const $5b80b81d7b095f89$var$QuickConnect = ()=>{
|
|
7305
|
+
const { t: t } = (0, $3Sbms$useTranslation)();
|
|
7306
|
+
const themeContext = (0, $3Sbms$useContext)((0, $3Sbms$ThemeContext));
|
|
6739
7307
|
const QuickConnectContainerRef = (0, $3Sbms$useRef)(null);
|
|
6740
7308
|
const QuickConnectRef = (0, $3Sbms$useRef)(null);
|
|
6741
7309
|
const { selfPeerId: selfPeerId , profile: profile , isQuickConnectPopupVisible: isQuickConnectPopupVisible , setIsQuickConnectPopupVisible: setIsQuickConnectPopupVisible , options: options , orientation: orientation , } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
@@ -6762,6 +7330,22 @@ const $5b80b81d7b095f89$var$QuickConnect = ()=>{
|
|
|
6762
7330
|
selfPeerId,
|
|
6763
7331
|
profile.name
|
|
6764
7332
|
]);
|
|
7333
|
+
const onCopyCallLinkClick = (0, $3Sbms$useCallback)(async ()=>{
|
|
7334
|
+
try {
|
|
7335
|
+
await (0, $57162bcada7d6f66$export$2e2bcd8739ae039)(qrCodeURL || window.location.href);
|
|
7336
|
+
(0, $a5146f9062d7bf28$export$3a57e165650c636f)(t("copyLink.copied"), {
|
|
7337
|
+
duration: 2000
|
|
7338
|
+
});
|
|
7339
|
+
} catch (copyError) {
|
|
7340
|
+
console.warn(copyError);
|
|
7341
|
+
(0, $a5146f9062d7bf28$export$3a57e165650c636f)(t("copyLink.error"), {
|
|
7342
|
+
icon: (0, $93a0377c243d965e$export$edf27be85e5f6da0)
|
|
7343
|
+
});
|
|
7344
|
+
}
|
|
7345
|
+
}, [
|
|
7346
|
+
t,
|
|
7347
|
+
qrCodeURL
|
|
7348
|
+
]);
|
|
6765
7349
|
const onQuickConnectPopupCloseClick = ()=>setIsQuickConnectPopupVisible(false);
|
|
6766
7350
|
(0, $3Sbms$useEffect)(()=>{
|
|
6767
7351
|
const onCustomMessage = (event)=>{
|
|
@@ -6776,7 +7360,9 @@ const $5b80b81d7b095f89$var$QuickConnect = ()=>{
|
|
|
6776
7360
|
setIsQuickConnectPopupVisible
|
|
6777
7361
|
]);
|
|
6778
7362
|
(0, $3Sbms$useEffect)(()=>{
|
|
6779
|
-
$3Sbms$toCanvas(QuickConnectRef.current, qrCodeURL
|
|
7363
|
+
$3Sbms$toCanvas(QuickConnectRef.current, qrCodeURL, {
|
|
7364
|
+
errorCorrectionLevel: "M"
|
|
7365
|
+
});
|
|
6780
7366
|
}, [
|
|
6781
7367
|
qrCodeURL
|
|
6782
7368
|
]);
|
|
@@ -6809,8 +7395,15 @@ const $5b80b81d7b095f89$var$QuickConnect = ()=>{
|
|
|
6809
7395
|
children: [
|
|
6810
7396
|
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $8d3d0e80c56cde5c$export$f8e80e2c9abbb7eb), {
|
|
6811
7397
|
children: [
|
|
6812
|
-
/*#__PURE__*/ (0, $3Sbms$
|
|
6813
|
-
children:
|
|
7398
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $8d3d0e80c56cde5c$export$2bd9c7c3b36c82cd), {
|
|
7399
|
+
children: [
|
|
7400
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $2da9626742e3560b$export$6470d09a29d34d08), {
|
|
7401
|
+
color: themeContext.popupTitleColor
|
|
7402
|
+
}),
|
|
7403
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("h4", {
|
|
7404
|
+
children: t("quickConnect.scanTitle")
|
|
7405
|
+
})
|
|
7406
|
+
]
|
|
6814
7407
|
}),
|
|
6815
7408
|
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $8d3d0e80c56cde5c$export$b421c25a8e0ea22e), {
|
|
6816
7409
|
onClick: onQuickConnectPopupCloseClick,
|
|
@@ -6818,13 +7411,27 @@ const $5b80b81d7b095f89$var$QuickConnect = ()=>{
|
|
|
6818
7411
|
})
|
|
6819
7412
|
]
|
|
6820
7413
|
}),
|
|
6821
|
-
/*#__PURE__*/ (0, $3Sbms$
|
|
6822
|
-
children:
|
|
6823
|
-
|
|
6824
|
-
|
|
7414
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $8d3d0e80c56cde5c$export$dc1a3f6996a97083), {
|
|
7415
|
+
children: [
|
|
7416
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $8d3d0e80c56cde5c$export$c58a46cd2027881e), {
|
|
7417
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $16d11fc0880587fd$export$2e2bcd8739ae039), {})
|
|
7418
|
+
}),
|
|
7419
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("canvas", {
|
|
7420
|
+
ref: QuickConnectRef
|
|
7421
|
+
})
|
|
7422
|
+
]
|
|
6825
7423
|
}),
|
|
6826
7424
|
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $8d3d0e80c56cde5c$export$51760c3b0f5567d2), {
|
|
6827
7425
|
children: t("quickConnect.scan")
|
|
7426
|
+
}),
|
|
7427
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $8d3d0e80c56cde5c$export$6a789d1ce3bcb863), {
|
|
7428
|
+
onClick: onCopyCallLinkClick,
|
|
7429
|
+
children: [
|
|
7430
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $2da9626742e3560b$export$92ce62e1201c4fc0), {
|
|
7431
|
+
color: "#686868"
|
|
7432
|
+
}),
|
|
7433
|
+
t("copyLink.description")
|
|
7434
|
+
]
|
|
6828
7435
|
})
|
|
6829
7436
|
]
|
|
6830
7437
|
})
|
|
@@ -7602,15 +8209,33 @@ var $c11e4c21ca692a16$export$2e2bcd8739ae039 = $c11e4c21ca692a16$var$Menu;
|
|
|
7602
8209
|
|
|
7603
8210
|
|
|
7604
8211
|
|
|
8212
|
+
|
|
8213
|
+
const $5dd22e058f46af7f$var$CircledTopArrow = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
8214
|
+
width: "21",
|
|
8215
|
+
height: "20",
|
|
8216
|
+
viewBox: "0 0 21 20",
|
|
8217
|
+
fill: "none",
|
|
8218
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
8219
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
8220
|
+
d: "M11.091 6.908a.833.833 0 0 0-.275-.175.833.833 0 0 0-.633 0 .833.833 0 0 0-.275.175l-2.5 2.5a.837.837 0 1 0 1.183 1.184l1.075-1.084V12.5a.833.833 0 1 0 1.667 0V9.508l1.075 1.084a.833.833 0 0 0 1.183 0 .833.833 0 0 0 0-1.184l-2.5-2.5Zm-.592-5.242a8.333 8.333 0 1 0 0 16.667 8.333 8.333 0 0 0 0-16.666Zm0 15a6.667 6.667 0 1 1 0-13.334 6.667 6.667 0 0 1 0 13.334Z",
|
|
8221
|
+
fill: "#fff"
|
|
8222
|
+
})
|
|
8223
|
+
});
|
|
8224
|
+
var $5dd22e058f46af7f$export$2e2bcd8739ae039 = $5dd22e058f46af7f$var$CircledTopArrow;
|
|
8225
|
+
|
|
8226
|
+
|
|
8227
|
+
|
|
8228
|
+
|
|
8229
|
+
const $d677836e2f373a45$var$modalHeight = (desktop)=>desktop ? "215px" : "227px";
|
|
7605
8230
|
const $d677836e2f373a45$export$b679a9a7caefa4b1 = (0, $3Sbms$styledcomponents).div`
|
|
7606
8231
|
position: absolute;
|
|
7607
8232
|
width: 100%;
|
|
7608
|
-
bottom: ${(props)=>props.open ? 0 :
|
|
8233
|
+
bottom: ${(props)=>props.open ? 0 : `-${$d677836e2f373a45$var$modalHeight(props.desktop)}`};
|
|
7609
8234
|
transition: all 0.4s;
|
|
7610
8235
|
|
|
7611
8236
|
${(props)=>{
|
|
7612
8237
|
if (props.desktop) return (0, $3Sbms$css)`
|
|
7613
|
-
bottom: ${props.open ? 0 :
|
|
8238
|
+
bottom: ${props.open ? 0 : `calc(-${$d677836e2f373a45$var$modalHeight(props.desktop)} - (100vh / 2))`};
|
|
7614
8239
|
height: 100%;
|
|
7615
8240
|
display: flex;
|
|
7616
8241
|
justify-content: center;
|
|
@@ -7622,12 +8247,12 @@ const $d677836e2f373a45$export$c506828286db9a46 = (0, $3Sbms$styledcomponents).d
|
|
|
7622
8247
|
display: flex;
|
|
7623
8248
|
flex-direction: column;
|
|
7624
8249
|
width: ${(props)=>props.desktop ? "375px" : "100%"};
|
|
7625
|
-
height:
|
|
8250
|
+
height: ${({ desktop: desktop })=>$d677836e2f373a45$var$modalHeight(desktop)};
|
|
7626
8251
|
max-height: 100vh;
|
|
7627
|
-
background-color: ${(props)=>props.theme.
|
|
7628
|
-
color: ${(props)=>props.theme.
|
|
8252
|
+
background-color: ${(props)=>props.theme.popupBackgroundPrimaryColor};
|
|
8253
|
+
color: ${(props)=>props.theme.popupTitleColor};
|
|
7629
8254
|
border-radius: ${(props)=>props.desktop ? "20px" : "20px 20px 0 0"};
|
|
7630
|
-
padding:
|
|
8255
|
+
padding: ${({ desktop: desktop })=>desktop ? "16px 14px" : "16px 14px 28px"};
|
|
7631
8256
|
box-sizing: border-box;
|
|
7632
8257
|
`;
|
|
7633
8258
|
const $d677836e2f373a45$export$f39d8ef0ab6ab3de = (0, $3Sbms$styledcomponents).div`
|
|
@@ -7656,10 +8281,10 @@ const $d677836e2f373a45$export$7ae684a6a708b51d = (0, $3Sbms$styledcomponents).b
|
|
|
7656
8281
|
justify-content: center;
|
|
7657
8282
|
align-items: center;
|
|
7658
8283
|
border: none;
|
|
7659
|
-
background-color: ${(props)=>props.theme.
|
|
8284
|
+
background-color: ${(props)=>props.theme.popupBackgroundSecondaryColor};
|
|
7660
8285
|
border-radius: 50%;
|
|
7661
|
-
height:
|
|
7662
|
-
width:
|
|
8286
|
+
height: 30px;
|
|
8287
|
+
width: 30px;
|
|
7663
8288
|
padding: 0;
|
|
7664
8289
|
|
|
7665
8290
|
svg {
|
|
@@ -7691,9 +8316,9 @@ const $d677836e2f373a45$export$176dd61d50c7f3d7 = (0, $3Sbms$styledcomponents).d
|
|
|
7691
8316
|
input {
|
|
7692
8317
|
padding: 16px 10px 16px 20px;
|
|
7693
8318
|
border-radius: 15px;
|
|
7694
|
-
background-color:
|
|
7695
|
-
border: 1px solid ${(props)=>props.errored ? "#d84949" :
|
|
7696
|
-
color: #
|
|
8319
|
+
background-color: ${({ theme: theme })=>theme.popupBackgroundSecondaryColor};
|
|
8320
|
+
border: 1px solid ${(props)=>props.errored ? "#d84949" : props.theme.popupBorderColor};
|
|
8321
|
+
color: #878787;
|
|
7697
8322
|
|
|
7698
8323
|
&:focus {
|
|
7699
8324
|
outline: none;
|
|
@@ -7714,13 +8339,23 @@ const $d677836e2f373a45$export$baf775d6bf9683d5 = (0, $3Sbms$styledcomponents).s
|
|
|
7714
8339
|
const $d677836e2f373a45$export$3711c5e6a7ba3fdc = (0, $3Sbms$styledcomponents).button`
|
|
7715
8340
|
background-color: ${({ theme: theme })=>theme.primaryColor};
|
|
7716
8341
|
padding: 8px 18px;
|
|
7717
|
-
|
|
8342
|
+
width: 100%;
|
|
8343
|
+
height: 46px;
|
|
8344
|
+
border-radius: 15px;
|
|
7718
8345
|
margin: 30px auto 0;
|
|
7719
8346
|
border: none;
|
|
7720
8347
|
color: #fff;
|
|
7721
8348
|
font-size: 16px;
|
|
7722
8349
|
font-weight: 700;
|
|
7723
8350
|
line-height: 18px;
|
|
8351
|
+
|
|
8352
|
+
span {
|
|
8353
|
+
display: flex;
|
|
8354
|
+
flex-direction: row;
|
|
8355
|
+
gap: 5px;
|
|
8356
|
+
alig-items: center;
|
|
8357
|
+
justify-content: center;
|
|
8358
|
+
}
|
|
7724
8359
|
`;
|
|
7725
8360
|
|
|
7726
8361
|
|
|
@@ -7728,6 +8363,7 @@ const $d677836e2f373a45$export$3711c5e6a7ba3fdc = (0, $3Sbms$styledcomponents).b
|
|
|
7728
8363
|
const $49372cd9190da903$var$youtubeIDRegExp = /.*(?:youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=)([^#&?]*).*/;
|
|
7729
8364
|
const $49372cd9190da903$var$YoutubePopup = ()=>{
|
|
7730
8365
|
const { t: t } = (0, $3Sbms$useTranslation)();
|
|
8366
|
+
const themeContext = (0, $3Sbms$useContext)((0, $3Sbms$ThemeContext));
|
|
7731
8367
|
const youtubePopupRef = (0, $3Sbms$useRef)(null);
|
|
7732
8368
|
const [youtubeInputValue, setYoutubeInputValue] = (0, $3Sbms$useState)("");
|
|
7733
8369
|
const [errorMessage, setErrorMessage] = (0, $3Sbms$useState)(null);
|
|
@@ -7740,6 +8376,7 @@ const $49372cd9190da903$var$YoutubePopup = ()=>{
|
|
|
7740
8376
|
const onShareClick = (event)=>{
|
|
7741
8377
|
event.preventDefault();
|
|
7742
8378
|
setErrorMessage(null);
|
|
8379
|
+
(0, $3Sbms$hotjarbrowser).event("youtubeShare");
|
|
7743
8380
|
const [, videoId] = youtubeInputValue.match($49372cd9190da903$var$youtubeIDRegExp) || [];
|
|
7744
8381
|
if (videoId) {
|
|
7745
8382
|
dispatch({
|
|
@@ -7774,7 +8411,9 @@ const $49372cd9190da903$var$YoutubePopup = ()=>{
|
|
|
7774
8411
|
children: [
|
|
7775
8412
|
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $d677836e2f373a45$export$11781939bbc73f8b), {
|
|
7776
8413
|
children: [
|
|
7777
|
-
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $a2d206a438475087$export$2e2bcd8739ae039), {
|
|
8414
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $a2d206a438475087$export$2e2bcd8739ae039), {
|
|
8415
|
+
color: themeContext.popupTitleColor
|
|
8416
|
+
}),
|
|
7778
8417
|
/*#__PURE__*/ (0, $3Sbms$jsx)("h4", {
|
|
7779
8418
|
children: t("youtube.title")
|
|
7780
8419
|
})
|
|
@@ -7792,10 +8431,6 @@ const $49372cd9190da903$var$YoutubePopup = ()=>{
|
|
|
7792
8431
|
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $d677836e2f373a45$export$176dd61d50c7f3d7), {
|
|
7793
8432
|
errored: Boolean(errorMessage),
|
|
7794
8433
|
children: [
|
|
7795
|
-
/*#__PURE__*/ (0, $3Sbms$jsx)("label", {
|
|
7796
|
-
htmlFor: "youtube-popup-input",
|
|
7797
|
-
children: t("youtube.url")
|
|
7798
|
-
}),
|
|
7799
8434
|
/*#__PURE__*/ (0, $3Sbms$jsx)("input", {
|
|
7800
8435
|
id: "youtube-popup-input",
|
|
7801
8436
|
placeholder: "https://www.youtube.com/watch?v=abcdef",
|
|
@@ -7812,7 +8447,12 @@ const $49372cd9190da903$var$YoutubePopup = ()=>{
|
|
|
7812
8447
|
}),
|
|
7813
8448
|
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $d677836e2f373a45$export$3711c5e6a7ba3fdc), {
|
|
7814
8449
|
type: "submit",
|
|
7815
|
-
children:
|
|
8450
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)("span", {
|
|
8451
|
+
children: [
|
|
8452
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $5dd22e058f46af7f$export$2e2bcd8739ae039), {}),
|
|
8453
|
+
t("youtube.share")
|
|
8454
|
+
]
|
|
8455
|
+
})
|
|
7816
8456
|
})
|
|
7817
8457
|
]
|
|
7818
8458
|
})
|
|
@@ -7833,6 +8473,9 @@ var $49372cd9190da903$export$2e2bcd8739ae039 = $49372cd9190da903$var$YoutubePopu
|
|
|
7833
8473
|
|
|
7834
8474
|
|
|
7835
8475
|
|
|
8476
|
+
|
|
8477
|
+
|
|
8478
|
+
|
|
7836
8479
|
const $dc26e7b014ddcf8c$var$PaypalWhite = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
7837
8480
|
width: "24",
|
|
7838
8481
|
height: "24",
|
|
@@ -7892,15 +8535,16 @@ var $dc26e7b014ddcf8c$export$2e2bcd8739ae039 = $dc26e7b014ddcf8c$var$Paypal;
|
|
|
7892
8535
|
|
|
7893
8536
|
|
|
7894
8537
|
|
|
8538
|
+
const $554f3984e3212196$var$modalHeight = (desktop)=>desktop ? "215px" : "227px";
|
|
7895
8539
|
const $554f3984e3212196$export$ed0d510542cc4e55 = (0, $3Sbms$styledcomponents).div`
|
|
7896
8540
|
position: absolute;
|
|
7897
8541
|
width: 100%;
|
|
7898
|
-
bottom: ${(props)=>props.open ? 0 :
|
|
8542
|
+
bottom: ${(props)=>props.open ? 0 : `-${$554f3984e3212196$var$modalHeight(props.desktop)}`};
|
|
7899
8543
|
transition: all 0.4s;
|
|
7900
8544
|
|
|
7901
8545
|
${(props)=>{
|
|
7902
8546
|
if (props.desktop) return (0, $3Sbms$css)`
|
|
7903
|
-
bottom: ${props.open ? 0 :
|
|
8547
|
+
bottom: ${props.open ? 0 : `calc(-${$554f3984e3212196$var$modalHeight(props.desktop)} - (100vh / 2))`};
|
|
7904
8548
|
height: 100%;
|
|
7905
8549
|
display: flex;
|
|
7906
8550
|
justify-content: center;
|
|
@@ -7912,12 +8556,12 @@ const $554f3984e3212196$export$93c2cc854b34757d = (0, $3Sbms$styledcomponents).d
|
|
|
7912
8556
|
display: flex;
|
|
7913
8557
|
flex-direction: column;
|
|
7914
8558
|
width: ${(props)=>props.desktop ? "375px" : "100%"};
|
|
7915
|
-
height:
|
|
8559
|
+
height: ${({ desktop: desktop })=>$554f3984e3212196$var$modalHeight(desktop)};
|
|
7916
8560
|
max-height: 100vh;
|
|
7917
|
-
background-color: ${(props)=>props.theme.
|
|
7918
|
-
color: ${(props)=>props.theme.
|
|
8561
|
+
background-color: ${(props)=>props.theme.popupBackgroundPrimaryColor};
|
|
8562
|
+
color: ${(props)=>props.theme.popupTitleColor};
|
|
7919
8563
|
border-radius: ${(props)=>props.desktop ? "20px" : "20px 20px 0 0"};
|
|
7920
|
-
padding:
|
|
8564
|
+
padding: ${({ desktop: desktop })=>desktop ? "16px 14px" : "16px 14px 28px"};
|
|
7921
8565
|
box-sizing: border-box;
|
|
7922
8566
|
`;
|
|
7923
8567
|
const $554f3984e3212196$export$f0162ebc287dd01 = (0, $3Sbms$styledcomponents).div`
|
|
@@ -7946,10 +8590,10 @@ const $554f3984e3212196$export$fcade06574a60ff0 = (0, $3Sbms$styledcomponents).b
|
|
|
7946
8590
|
justify-content: center;
|
|
7947
8591
|
align-items: center;
|
|
7948
8592
|
border: none;
|
|
7949
|
-
background-color: ${(props)=>props.theme.
|
|
8593
|
+
background-color: ${(props)=>props.theme.popupBackgroundSecondaryColor};
|
|
7950
8594
|
border-radius: 50%;
|
|
7951
|
-
height:
|
|
7952
|
-
width:
|
|
8595
|
+
height: 30px;
|
|
8596
|
+
width: 30px;
|
|
7953
8597
|
padding: 0;
|
|
7954
8598
|
|
|
7955
8599
|
svg {
|
|
@@ -7970,20 +8614,12 @@ const $554f3984e3212196$export$dcb32b2b413109d8 = (0, $3Sbms$styledcomponents).d
|
|
|
7970
8614
|
flex-direction: column;
|
|
7971
8615
|
position: relative;
|
|
7972
8616
|
|
|
7973
|
-
label {
|
|
7974
|
-
font-size: 10px;
|
|
7975
|
-
font-weight: 700;
|
|
7976
|
-
line-height: 10px;
|
|
7977
|
-
color: #fff;
|
|
7978
|
-
margin-bottom: 10px;
|
|
7979
|
-
}
|
|
7980
|
-
|
|
7981
8617
|
input {
|
|
7982
8618
|
padding: 16px 10px 16px 20px;
|
|
7983
8619
|
border-radius: 15px;
|
|
7984
|
-
background-color:
|
|
7985
|
-
border: 1px solid ${(props)=>props.errored ? "#d84949" :
|
|
7986
|
-
color: #
|
|
8620
|
+
background-color: ${({ theme: theme })=>theme.popupBackgroundSecondaryColor};
|
|
8621
|
+
border: 1px solid ${(props)=>props.errored ? "#d84949" : props.theme.popupBorderColor};
|
|
8622
|
+
color: #878787;
|
|
7987
8623
|
|
|
7988
8624
|
&:focus {
|
|
7989
8625
|
outline: none;
|
|
@@ -8003,14 +8639,25 @@ const $554f3984e3212196$export$711a92c06f80c3bd = (0, $3Sbms$styledcomponents).s
|
|
|
8003
8639
|
`;
|
|
8004
8640
|
const $554f3984e3212196$export$aec21c9a4da7a1b7 = (0, $3Sbms$styledcomponents).button`
|
|
8005
8641
|
background-color: ${({ theme: theme })=>theme.primaryColor};
|
|
8006
|
-
padding: 8px 18px;
|
|
8007
|
-
|
|
8642
|
+
padding: ${({ status: status })=>status !== "waiting" ? "auto" : "8px 18px"};
|
|
8643
|
+
width: ${({ status: status })=>status !== "waiting" ? "46px" : "100%"};
|
|
8644
|
+
height: 46px;
|
|
8645
|
+
border-radius: ${({ status: status })=>status !== "waiting" ? "50%" : "15px"};
|
|
8008
8646
|
margin: 30px auto 0;
|
|
8009
8647
|
border: none;
|
|
8010
8648
|
color: #fff;
|
|
8011
8649
|
font-size: 16px;
|
|
8012
8650
|
font-weight: 700;
|
|
8013
8651
|
line-height: 18px;
|
|
8652
|
+
transition: border-radius 0.3s ease-in, width 0.3s;
|
|
8653
|
+
|
|
8654
|
+
span {
|
|
8655
|
+
display: flex;
|
|
8656
|
+
flex-direction: row;
|
|
8657
|
+
gap: 5px;
|
|
8658
|
+
align-items: center;
|
|
8659
|
+
justify-content: center;
|
|
8660
|
+
}
|
|
8014
8661
|
`;
|
|
8015
8662
|
const $554f3984e3212196$export$9e155375d8fb1f67 = (0, $3Sbms$styledcomponents).img`
|
|
8016
8663
|
width: 36px;
|
|
@@ -8019,7 +8666,8 @@ const $554f3984e3212196$export$9e155375d8fb1f67 = (0, $3Sbms$styledcomponents).i
|
|
|
8019
8666
|
`;
|
|
8020
8667
|
const $554f3984e3212196$export$5e3f251c730829 = (0, $3Sbms$styledcomponents).div`
|
|
8021
8668
|
display: flex;
|
|
8022
|
-
|
|
8669
|
+
align-items: center;
|
|
8670
|
+
justify-content: center;
|
|
8023
8671
|
`;
|
|
8024
8672
|
|
|
8025
8673
|
|
|
@@ -8061,7 +8709,7 @@ const $98933bbc579a3e66$var$sendLinkNotification = (data, t)=>{
|
|
|
8061
8709
|
const $98933bbc579a3e66$var$sendPaypalInvoiceNotification = (senderName, url, t)=>{
|
|
8062
8710
|
const userName = senderName || t("misc.user");
|
|
8063
8711
|
const title = t("shareLink.invoice", {
|
|
8064
|
-
|
|
8712
|
+
user: userName
|
|
8065
8713
|
});
|
|
8066
8714
|
(0, $a5146f9062d7bf28$export$3a57e165650c636f)(title, {
|
|
8067
8715
|
button: {
|
|
@@ -8087,11 +8735,12 @@ const $98933bbc579a3e66$var$sendPaypalInvoiceNotification = (senderName, url, t)
|
|
|
8087
8735
|
};
|
|
8088
8736
|
const $98933bbc579a3e66$var$LinksharePopup = ()=>{
|
|
8089
8737
|
const { t: t } = (0, $3Sbms$useTranslation)();
|
|
8738
|
+
const themeContext = (0, $3Sbms$useContext)((0, $3Sbms$ThemeContext));
|
|
8090
8739
|
const linksharePopupRef = (0, $3Sbms$useRef)(null);
|
|
8091
8740
|
const linkshareInputRef = (0, $3Sbms$useRef)(null);
|
|
8092
8741
|
const [linkshareInputValue, setLinkshareInputValue] = (0, $3Sbms$useState)("");
|
|
8093
8742
|
const [errorMessage, setErrorMessage] = (0, $3Sbms$useState)(null);
|
|
8094
|
-
const [
|
|
8743
|
+
const [status, setStatus] = (0, $3Sbms$useState)("waiting");
|
|
8095
8744
|
const { isLinksharePopupVisible: isLinksharePopupVisible , setIsLinksharePopupVisible: setIsLinksharePopupVisible , orientation: orientation , options: options } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
8096
8745
|
const { streams: streams } = (0, $cce9fd41d8a55a18$export$b5633a7cfbe42d9f)();
|
|
8097
8746
|
const desktop = orientation === "landscape";
|
|
@@ -8110,7 +8759,8 @@ const $98933bbc579a3e66$var$LinksharePopup = ()=>{
|
|
|
8110
8759
|
event.preventDefault();
|
|
8111
8760
|
if (!linkshareInputValue) return;
|
|
8112
8761
|
setErrorMessage(null);
|
|
8113
|
-
|
|
8762
|
+
setStatus("loading");
|
|
8763
|
+
(0, $3Sbms$hotjarbrowser).event("linkshareShare");
|
|
8114
8764
|
let url;
|
|
8115
8765
|
try {
|
|
8116
8766
|
url = new URL(linkshareInputValue);
|
|
@@ -8142,7 +8792,7 @@ const $98933bbc579a3e66$var$LinksharePopup = ()=>{
|
|
|
8142
8792
|
if (streams.length < 2) {
|
|
8143
8793
|
const userName = streams[0]?.profile?.name || t("misc.user");
|
|
8144
8794
|
(0, $3Sbms$reacthottoast)(t("shareLink.sentToUser", {
|
|
8145
|
-
|
|
8795
|
+
user: userName
|
|
8146
8796
|
}));
|
|
8147
8797
|
} else (0, $3Sbms$reacthottoast)(t("shareLink.sentToUsers"));
|
|
8148
8798
|
setIsLinksharePopupVisible(false);
|
|
@@ -8154,7 +8804,7 @@ const $98933bbc579a3e66$var$LinksharePopup = ()=>{
|
|
|
8154
8804
|
}
|
|
8155
8805
|
setLinkshareInputValue("");
|
|
8156
8806
|
}
|
|
8157
|
-
|
|
8807
|
+
setStatus("done");
|
|
8158
8808
|
};
|
|
8159
8809
|
const onCloseClick = ()=>setIsLinksharePopupVisible(false);
|
|
8160
8810
|
(0, $3Sbms$useEffect)(()=>{
|
|
@@ -8167,6 +8817,7 @@ const $98933bbc579a3e66$var$LinksharePopup = ()=>{
|
|
|
8167
8817
|
]);
|
|
8168
8818
|
const onPopupTransitionEnd = ()=>{
|
|
8169
8819
|
if (isLinksharePopupVisible) linkshareInputRef.current?.focus();
|
|
8820
|
+
if (status === "done") setStatus("waiting");
|
|
8170
8821
|
};
|
|
8171
8822
|
return /*#__PURE__*/ (0, $3Sbms$jsx)((0, $554f3984e3212196$export$ed0d510542cc4e55), {
|
|
8172
8823
|
open: isLinksharePopupVisible,
|
|
@@ -8180,7 +8831,9 @@ const $98933bbc579a3e66$var$LinksharePopup = ()=>{
|
|
|
8180
8831
|
children: [
|
|
8181
8832
|
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $554f3984e3212196$export$7563f0d47f114601), {
|
|
8182
8833
|
children: [
|
|
8183
|
-
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $1ec1d06e0a21fdaa$export$2e2bcd8739ae039), {
|
|
8834
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $1ec1d06e0a21fdaa$export$2e2bcd8739ae039), {
|
|
8835
|
+
color: themeContext.popupTitleColor
|
|
8836
|
+
}),
|
|
8184
8837
|
/*#__PURE__*/ (0, $3Sbms$jsx)("h4", {
|
|
8185
8838
|
children: t("shareLink.title2")
|
|
8186
8839
|
})
|
|
@@ -8198,10 +8851,6 @@ const $98933bbc579a3e66$var$LinksharePopup = ()=>{
|
|
|
8198
8851
|
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $554f3984e3212196$export$dcb32b2b413109d8), {
|
|
8199
8852
|
errored: Boolean(errorMessage),
|
|
8200
8853
|
children: [
|
|
8201
|
-
/*#__PURE__*/ (0, $3Sbms$jsx)("label", {
|
|
8202
|
-
htmlFor: "linkshare-popup-input",
|
|
8203
|
-
children: t("shareLink.linkUrl")
|
|
8204
|
-
}),
|
|
8205
8854
|
/*#__PURE__*/ (0, $3Sbms$jsx)("input", {
|
|
8206
8855
|
id: "linkshare-popup-input",
|
|
8207
8856
|
ref: linkshareInputRef,
|
|
@@ -8219,17 +8868,18 @@ const $98933bbc579a3e66$var$LinksharePopup = ()=>{
|
|
|
8219
8868
|
}),
|
|
8220
8869
|
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $554f3984e3212196$export$aec21c9a4da7a1b7), {
|
|
8221
8870
|
type: "submit",
|
|
8222
|
-
disabled:
|
|
8223
|
-
|
|
8871
|
+
disabled: status !== "waiting",
|
|
8872
|
+
status: status,
|
|
8873
|
+
children: status !== "waiting" ? /*#__PURE__*/ (0, $3Sbms$jsx)((0, $554f3984e3212196$export$5e3f251c730829), {
|
|
8874
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $8b7bd174d29d9a1f$export$2e2bcd8739ae039), {
|
|
8875
|
+
size: "18px"
|
|
8876
|
+
})
|
|
8877
|
+
}) : /*#__PURE__*/ (0, $3Sbms$jsxs)("span", {
|
|
8224
8878
|
children: [
|
|
8225
|
-
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $
|
|
8226
|
-
|
|
8227
|
-
}),
|
|
8228
|
-
/*#__PURE__*/ (0, $3Sbms$jsx)("span", {
|
|
8229
|
-
children: t("shareLink.creating")
|
|
8230
|
-
})
|
|
8879
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $5dd22e058f46af7f$export$2e2bcd8739ae039), {}),
|
|
8880
|
+
t("shareLink.title")
|
|
8231
8881
|
]
|
|
8232
|
-
})
|
|
8882
|
+
})
|
|
8233
8883
|
})
|
|
8234
8884
|
]
|
|
8235
8885
|
})
|
|
@@ -8241,83 +8891,401 @@ var $98933bbc579a3e66$export$2e2bcd8739ae039 = $98933bbc579a3e66$var$LinksharePo
|
|
|
8241
8891
|
|
|
8242
8892
|
|
|
8243
8893
|
|
|
8244
|
-
const $e1c48a389d8ac959$export$8376625f8bb18347 = (0, $3Sbms$styledcomponents).div`
|
|
8245
|
-
position: absolute;
|
|
8246
|
-
width: 100%;
|
|
8247
|
-
height: 100%;
|
|
8248
|
-
background-color: ${(props)=>props.open ? "rgba(0, 0, 0, 0.9)" : "transparent"};
|
|
8249
|
-
z-index: ${(props)=>props.open ? 100 : -1};
|
|
8250
|
-
overflow: hidden;
|
|
8251
|
-
transition: all ${(props)=>props.open ? "0.2s" : "0.6s"};
|
|
8252
|
-
`;
|
|
8253
8894
|
|
|
8254
8895
|
|
|
8255
|
-
const $01986a58bfba8001$var$Settings = ()=>{
|
|
8256
|
-
const { isQuickConnectPopupVisible: isQuickConnectPopupVisible , isSettingsMenuVisible: isSettingsMenuVisible , isYoutubePopupVisible: isYoutubePopupVisible , isLinksharePopupVisible: isLinksharePopupVisible , } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
8257
|
-
const open = isQuickConnectPopupVisible || isSettingsMenuVisible || isYoutubePopupVisible || isLinksharePopupVisible;
|
|
8258
|
-
return /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $e1c48a389d8ac959$export$8376625f8bb18347), {
|
|
8259
|
-
open: open,
|
|
8260
|
-
children: [
|
|
8261
|
-
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $5b80b81d7b095f89$export$2e2bcd8739ae039), {}),
|
|
8262
|
-
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $c11e4c21ca692a16$export$2e2bcd8739ae039), {}),
|
|
8263
|
-
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $49372cd9190da903$export$2e2bcd8739ae039), {}),
|
|
8264
|
-
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $98933bbc579a3e66$export$2e2bcd8739ae039), {})
|
|
8265
|
-
]
|
|
8266
|
-
});
|
|
8267
|
-
};
|
|
8268
|
-
var $01986a58bfba8001$export$2e2bcd8739ae039 = $01986a58bfba8001$var$Settings;
|
|
8269
8896
|
|
|
8270
8897
|
|
|
8271
8898
|
|
|
8272
8899
|
|
|
8273
8900
|
|
|
8901
|
+
const $de519a3c48c42424$var$CircledCheckmark = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
8902
|
+
width: "20",
|
|
8903
|
+
height: "20",
|
|
8904
|
+
viewBox: "0 0 20 20",
|
|
8905
|
+
fill: "none",
|
|
8906
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
8907
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
8908
|
+
d: "M12.266 7.325 8.691 10.91 7.316 9.534a.833.833 0 1 0-1.175 1.175l1.958 1.966a.831.831 0 0 0 .592.242.833.833 0 0 0 .583-.242l4.167-4.166a.833.833 0 1 0-1.175-1.184ZM9.999 1.667a8.333 8.333 0 1 0 0 16.667 8.333 8.333 0 0 0 0-16.667Zm0 15a6.667 6.667 0 1 1 0-13.334 6.667 6.667 0 0 1 0 13.334Z",
|
|
8909
|
+
fill: "#fff"
|
|
8910
|
+
})
|
|
8911
|
+
});
|
|
8912
|
+
var $de519a3c48c42424$export$2e2bcd8739ae039 = $de519a3c48c42424$var$CircledCheckmark;
|
|
8274
8913
|
|
|
8275
8914
|
|
|
8276
8915
|
|
|
8916
|
+
const $30e857a4d83ba073$var$modalHeight = (desktop)=>desktop ? "420px" : "432px";
|
|
8917
|
+
const $30e857a4d83ba073$export$b298b737d508d68e = (0, $3Sbms$styledcomponents).div`
|
|
8918
|
+
position: absolute;
|
|
8919
|
+
width: 100%;
|
|
8920
|
+
bottom: ${(props)=>props.open ? 0 : `-${$30e857a4d83ba073$var$modalHeight(props.desktop)}`};
|
|
8921
|
+
transition: all 0.4s;
|
|
8277
8922
|
|
|
8278
|
-
|
|
8923
|
+
${(props)=>{
|
|
8924
|
+
if (props.desktop) return (0, $3Sbms$css)`
|
|
8925
|
+
bottom: ${props.open ? 0 : `calc(-${$30e857a4d83ba073$var$modalHeight(props.desktop)} - (100vh / 2))`};
|
|
8926
|
+
height: 100%;
|
|
8927
|
+
display: flex;
|
|
8928
|
+
justify-content: center;
|
|
8929
|
+
align-items: center;
|
|
8930
|
+
`;
|
|
8931
|
+
}}
|
|
8932
|
+
`;
|
|
8933
|
+
const $30e857a4d83ba073$export$156bb26b5a0d2f83 = (0, $3Sbms$styledcomponents).div`
|
|
8279
8934
|
display: flex;
|
|
8280
|
-
flex: 1;
|
|
8281
8935
|
flex-direction: column;
|
|
8936
|
+
width: ${(props)=>props.desktop ? "375px" : "100%"};
|
|
8937
|
+
height: ${({ desktop: desktop })=>$30e857a4d83ba073$var$modalHeight(desktop)};
|
|
8938
|
+
max-height: 100vh;
|
|
8939
|
+
background-color: ${(props)=>props.theme.popupBackgroundPrimaryColor};
|
|
8940
|
+
color: ${(props)=>props.theme.popupTitleColor};
|
|
8941
|
+
border-radius: ${(props)=>props.desktop ? "20px" : "20px 20px 0 0"};
|
|
8942
|
+
padding: 12px 14px 30px;
|
|
8943
|
+
box-sizing: border-box;
|
|
8944
|
+
`;
|
|
8945
|
+
const $30e857a4d83ba073$export$28a9baece842bd02 = (0, $3Sbms$styledcomponents).div`
|
|
8946
|
+
display: flex;
|
|
8947
|
+
justify-content: space-between;
|
|
8948
|
+
align-items: center;
|
|
8949
|
+
margin-bottom: 30px;
|
|
8950
|
+
`;
|
|
8951
|
+
const $30e857a4d83ba073$export$de75cb5a82158063 = (0, $3Sbms$styledcomponents).div`
|
|
8952
|
+
display: flex;
|
|
8953
|
+
align-items: center;
|
|
8954
|
+
|
|
8955
|
+
h4 {
|
|
8956
|
+
margin: 0 0 0 8px;
|
|
8957
|
+
font-weight: 600;
|
|
8958
|
+
line-height: 19px;
|
|
8959
|
+
}
|
|
8960
|
+
|
|
8961
|
+
svg {
|
|
8962
|
+
width: 20px;
|
|
8963
|
+
height: 20px;
|
|
8964
|
+
}
|
|
8965
|
+
`;
|
|
8966
|
+
const $30e857a4d83ba073$export$ab8c73b78f24745 = (0, $3Sbms$styledcomponents).button`
|
|
8967
|
+
display: flex;
|
|
8282
8968
|
justify-content: center;
|
|
8283
8969
|
align-items: center;
|
|
8284
|
-
|
|
8285
|
-
color:
|
|
8286
|
-
|
|
8970
|
+
border: none;
|
|
8971
|
+
background-color: ${(props)=>props.theme.popupBackgroundSecondaryColor};
|
|
8972
|
+
border-radius: 50%;
|
|
8973
|
+
height: 30px;
|
|
8974
|
+
width: 30px;
|
|
8975
|
+
padding: 0;
|
|
8976
|
+
|
|
8977
|
+
svg {
|
|
8978
|
+
width: 15px;
|
|
8979
|
+
height: 15px;
|
|
8980
|
+
|
|
8981
|
+
path {
|
|
8982
|
+
fill: #000;
|
|
8983
|
+
}
|
|
8984
|
+
}
|
|
8287
8985
|
`;
|
|
8288
|
-
const $
|
|
8289
|
-
|
|
8986
|
+
const $30e857a4d83ba073$export$8603bdc04df69ddb = (0, $3Sbms$styledcomponents).form`
|
|
8987
|
+
display: flex;
|
|
8988
|
+
flex-direction: column;
|
|
8290
8989
|
`;
|
|
8291
|
-
const $
|
|
8292
|
-
|
|
8293
|
-
|
|
8294
|
-
|
|
8990
|
+
const $30e857a4d83ba073$export$3f7ff862632a81a7 = (0, $3Sbms$styledcomponents).div`
|
|
8991
|
+
display: flex;
|
|
8992
|
+
flex-direction: row;
|
|
8993
|
+
flex-wrap: wrap-reverse;
|
|
8994
|
+
gap: 10px 20px;
|
|
8995
|
+
width: 280px;
|
|
8996
|
+
margin: auto;
|
|
8295
8997
|
`;
|
|
8296
|
-
const $
|
|
8297
|
-
|
|
8298
|
-
|
|
8299
|
-
|
|
8300
|
-
|
|
8998
|
+
const $30e857a4d83ba073$export$1058440c16b3a127 = (0, $3Sbms$styledcomponents).label`
|
|
8999
|
+
display: flex;
|
|
9000
|
+
flex-direction: column;
|
|
9001
|
+
position: relative;
|
|
9002
|
+
justify-content: center;
|
|
9003
|
+
flex-grow: 1;
|
|
9004
|
+
|
|
9005
|
+
font-size: 16px;
|
|
9006
|
+
font-weight: 700;
|
|
9007
|
+
line-height: 10px;
|
|
9008
|
+
color: #686868;
|
|
9009
|
+
input[type='radio'] {
|
|
9010
|
+
appearance: none;
|
|
9011
|
+
border: ${(props)=>props.image ? 0 : `3px solid ${props.theme.popupBorderColor}`};
|
|
9012
|
+
background-color: ${({ theme: theme })=>theme.popupBackgroundThirdColor};
|
|
9013
|
+
background-position: 0 0;
|
|
9014
|
+
background-image: ${({ image: image })=>image ? `url(${image})` : undefined};
|
|
9015
|
+
height: 80px;
|
|
9016
|
+
min-width: 80px;
|
|
9017
|
+
border-radius: 10px;
|
|
9018
|
+
margin: 0;
|
|
9019
|
+
box-sizing: border-box;
|
|
9020
|
+
|
|
9021
|
+
&:checked {
|
|
9022
|
+
background-position: -3px -3px;
|
|
9023
|
+
border: 3px solid ${({ theme: theme })=>theme.primaryColor};
|
|
9024
|
+
}
|
|
9025
|
+
|
|
9026
|
+
&:checked + span {
|
|
9027
|
+
color: ${({ theme: theme })=>theme.primaryColor};
|
|
9028
|
+
}
|
|
9029
|
+
}
|
|
9030
|
+
|
|
9031
|
+
&:hover input[type='radio'],
|
|
9032
|
+
span {
|
|
9033
|
+
cursor: pointer;
|
|
9034
|
+
}
|
|
9035
|
+
|
|
9036
|
+
span {
|
|
9037
|
+
position: absolute;
|
|
9038
|
+
width: 100%;
|
|
9039
|
+
text-align: center;
|
|
9040
|
+
display: ${({ image: image })=>image ? "none" : "inline"};
|
|
9041
|
+
}
|
|
8301
9042
|
`;
|
|
8302
|
-
const $
|
|
9043
|
+
const $30e857a4d83ba073$export$dfc919b3320e9811 = (0, $3Sbms$styledcomponents).button`
|
|
8303
9044
|
background-color: ${({ theme: theme })=>theme.primaryColor};
|
|
9045
|
+
padding: 8px 18px;
|
|
9046
|
+
width: 280px;
|
|
9047
|
+
height: 46px;
|
|
9048
|
+
border-radius: 15px;
|
|
9049
|
+
margin: 20px auto 0;
|
|
8304
9050
|
border: none;
|
|
8305
|
-
|
|
8306
|
-
padding: 12px 18px;
|
|
9051
|
+
color: #fff;
|
|
8307
9052
|
font-size: 16px;
|
|
8308
|
-
font-weight:
|
|
9053
|
+
font-weight: 700;
|
|
8309
9054
|
line-height: 18px;
|
|
8310
|
-
|
|
8311
|
-
|
|
9055
|
+
transition: border-radius 0.3s ease-in, width 0.3s;
|
|
9056
|
+
|
|
9057
|
+
span {
|
|
9058
|
+
display: flex;
|
|
9059
|
+
flex-direction: row;
|
|
9060
|
+
gap: 5px;
|
|
9061
|
+
align-items: center;
|
|
9062
|
+
justify-content: center;
|
|
9063
|
+
}
|
|
8312
9064
|
`;
|
|
8313
9065
|
|
|
8314
9066
|
|
|
8315
|
-
const $
|
|
9067
|
+
const $d493afe60dcea711$var$backgroundOptions = [
|
|
9068
|
+
{
|
|
9069
|
+
title: "Blue",
|
|
9070
|
+
id: "background-blue",
|
|
9071
|
+
iconUrl: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/blue_background_icon.png`,
|
|
9072
|
+
value: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/blue_background.png`
|
|
9073
|
+
},
|
|
9074
|
+
{
|
|
9075
|
+
title: "Cold",
|
|
9076
|
+
id: "background-cold",
|
|
9077
|
+
iconUrl: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/cold_background_icon.png`,
|
|
9078
|
+
value: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/cold_background.png`
|
|
9079
|
+
},
|
|
9080
|
+
{
|
|
9081
|
+
title: "Bricks",
|
|
9082
|
+
id: "background-bricks",
|
|
9083
|
+
iconUrl: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/bricks_background_icon.png`,
|
|
9084
|
+
value: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/bricks_background.png`
|
|
9085
|
+
},
|
|
9086
|
+
{
|
|
9087
|
+
title: "White",
|
|
9088
|
+
id: "background-white",
|
|
9089
|
+
iconUrl: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/white_background_icon.png`,
|
|
9090
|
+
value: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/white_background.png`
|
|
9091
|
+
},
|
|
9092
|
+
{
|
|
9093
|
+
title: "Yellow",
|
|
9094
|
+
id: "background-yellow",
|
|
9095
|
+
iconUrl: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/yellow_background_icon.png`,
|
|
9096
|
+
value: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/yellow_background.png`
|
|
9097
|
+
},
|
|
9098
|
+
{
|
|
9099
|
+
title: "Warm",
|
|
9100
|
+
id: "background-warm",
|
|
9101
|
+
iconUrl: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/warm_background_icon.png`,
|
|
9102
|
+
value: `${"https://stream-assets.snapcall.io/v1.7.0"}/backgrounds/warm_background.png`
|
|
9103
|
+
},
|
|
9104
|
+
{
|
|
9105
|
+
title: "None",
|
|
9106
|
+
value: "none",
|
|
9107
|
+
id: "background-none"
|
|
9108
|
+
},
|
|
9109
|
+
{
|
|
9110
|
+
title: "Blurred",
|
|
9111
|
+
value: "blurred",
|
|
9112
|
+
id: "background-blurred"
|
|
9113
|
+
},
|
|
9114
|
+
];
|
|
9115
|
+
const $d493afe60dcea711$var$VirtualBackgroundPopup = ()=>{
|
|
8316
9116
|
const { t: t } = (0, $3Sbms$useTranslation)();
|
|
8317
|
-
const
|
|
9117
|
+
const virtualBackgroundPopupRef = (0, $3Sbms$useRef)(null);
|
|
9118
|
+
const { isVirtualBackgroundPopupVisible: isVirtualBackgroundPopupVisible , setIsVirtualBackgroundPopupVisible: setIsVirtualBackgroundPopupVisible , orientation: orientation } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
9119
|
+
const desktop = orientation === "landscape";
|
|
9120
|
+
const onSubmit = (e)=>{
|
|
9121
|
+
e.preventDefault();
|
|
9122
|
+
const value = e.currentTarget.elements.background.value;
|
|
9123
|
+
if (value === "none") (0, $c9e496369b59be7a$export$2f377c2162fd02b2).stopVideoBackground();
|
|
9124
|
+
else if (value === "blurred") {
|
|
9125
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).setVideoBackground({
|
|
9126
|
+
blurLevel: 16,
|
|
9127
|
+
type: "blur"
|
|
9128
|
+
});
|
|
9129
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).initVideoBackground();
|
|
9130
|
+
} else {
|
|
9131
|
+
const background = new Image();
|
|
9132
|
+
background.src = value;
|
|
9133
|
+
background.crossOrigin = "anonymous";
|
|
9134
|
+
background.onload = ()=>{
|
|
9135
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).setVideoBackground({
|
|
9136
|
+
background: background,
|
|
9137
|
+
type: "background"
|
|
9138
|
+
});
|
|
9139
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).initVideoBackground();
|
|
9140
|
+
};
|
|
9141
|
+
}
|
|
9142
|
+
setIsVirtualBackgroundPopupVisible(false);
|
|
9143
|
+
};
|
|
9144
|
+
const onCloseClick = ()=>setIsVirtualBackgroundPopupVisible(false);
|
|
9145
|
+
return /*#__PURE__*/ (0, $3Sbms$jsx)((0, $30e857a4d83ba073$export$b298b737d508d68e), {
|
|
9146
|
+
open: isVirtualBackgroundPopupVisible,
|
|
9147
|
+
desktop: desktop,
|
|
9148
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $30e857a4d83ba073$export$156bb26b5a0d2f83), {
|
|
9149
|
+
ref: virtualBackgroundPopupRef,
|
|
9150
|
+
desktop: desktop,
|
|
9151
|
+
children: [
|
|
9152
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $30e857a4d83ba073$export$28a9baece842bd02), {
|
|
9153
|
+
children: [
|
|
9154
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $30e857a4d83ba073$export$de75cb5a82158063), {
|
|
9155
|
+
children: [
|
|
9156
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $2da9626742e3560b$export$d5424e4dfe4be076), {
|
|
9157
|
+
color: "#000"
|
|
9158
|
+
}),
|
|
9159
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("h4", {
|
|
9160
|
+
children: t("virtualBackground.title")
|
|
9161
|
+
})
|
|
9162
|
+
]
|
|
9163
|
+
}),
|
|
9164
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $30e857a4d83ba073$export$ab8c73b78f24745), {
|
|
9165
|
+
onClick: onCloseClick,
|
|
9166
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $57ab7b9a012d9acd$export$2e2bcd8739ae039), {})
|
|
9167
|
+
})
|
|
9168
|
+
]
|
|
9169
|
+
}),
|
|
9170
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $30e857a4d83ba073$export$8603bdc04df69ddb), {
|
|
9171
|
+
onSubmit: onSubmit,
|
|
9172
|
+
children: [
|
|
9173
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $30e857a4d83ba073$export$3f7ff862632a81a7), {
|
|
9174
|
+
children: $d493afe60dcea711$var$backgroundOptions.map(({ id: id , title: title , value: value , iconUrl: iconUrl })=>/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $30e857a4d83ba073$export$1058440c16b3a127), {
|
|
9175
|
+
htmlFor: id,
|
|
9176
|
+
image: iconUrl,
|
|
9177
|
+
children: [
|
|
9178
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("input", {
|
|
9179
|
+
type: "radio",
|
|
9180
|
+
value: value,
|
|
9181
|
+
id: id,
|
|
9182
|
+
name: "background",
|
|
9183
|
+
defaultChecked: value === "none"
|
|
9184
|
+
}),
|
|
9185
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("span", {
|
|
9186
|
+
children: title
|
|
9187
|
+
})
|
|
9188
|
+
]
|
|
9189
|
+
}, id))
|
|
9190
|
+
}),
|
|
9191
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $30e857a4d83ba073$export$dfc919b3320e9811), {
|
|
9192
|
+
type: "submit",
|
|
9193
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)("span", {
|
|
9194
|
+
children: [
|
|
9195
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $de519a3c48c42424$export$2e2bcd8739ae039), {}),
|
|
9196
|
+
t("virtualBackground.setBackground")
|
|
9197
|
+
]
|
|
9198
|
+
})
|
|
9199
|
+
})
|
|
9200
|
+
]
|
|
9201
|
+
})
|
|
9202
|
+
]
|
|
9203
|
+
})
|
|
9204
|
+
});
|
|
9205
|
+
};
|
|
9206
|
+
var $d493afe60dcea711$export$2e2bcd8739ae039 = $d493afe60dcea711$var$VirtualBackgroundPopup;
|
|
9207
|
+
|
|
9208
|
+
|
|
9209
|
+
|
|
9210
|
+
const $e1c48a389d8ac959$export$8376625f8bb18347 = (0, $3Sbms$styledcomponents).div`
|
|
9211
|
+
position: absolute;
|
|
9212
|
+
width: 100%;
|
|
9213
|
+
height: 100%;
|
|
9214
|
+
background-color: ${(props)=>props.open ? "rgba(0, 0, 0, 0.9)" : "transparent"};
|
|
9215
|
+
z-index: ${(props)=>props.open ? 100 : -1};
|
|
9216
|
+
overflow: hidden;
|
|
9217
|
+
transition: all ${(props)=>props.open ? "0.2s" : "0.6s"};
|
|
9218
|
+
`;
|
|
9219
|
+
|
|
9220
|
+
|
|
9221
|
+
const $01986a58bfba8001$var$Settings = ()=>{
|
|
9222
|
+
const { isQuickConnectPopupVisible: isQuickConnectPopupVisible , isSettingsMenuVisible: isSettingsMenuVisible , isYoutubePopupVisible: isYoutubePopupVisible , isLinksharePopupVisible: isLinksharePopupVisible , isVirtualBackgroundPopupVisible: isVirtualBackgroundPopupVisible , } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
9223
|
+
const open = isQuickConnectPopupVisible || isSettingsMenuVisible || isYoutubePopupVisible || isLinksharePopupVisible || isVirtualBackgroundPopupVisible;
|
|
9224
|
+
return /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $e1c48a389d8ac959$export$8376625f8bb18347), {
|
|
9225
|
+
open: open,
|
|
9226
|
+
children: [
|
|
9227
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $5b80b81d7b095f89$export$2e2bcd8739ae039), {}),
|
|
9228
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $c11e4c21ca692a16$export$2e2bcd8739ae039), {}),
|
|
9229
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $49372cd9190da903$export$2e2bcd8739ae039), {}),
|
|
9230
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $98933bbc579a3e66$export$2e2bcd8739ae039), {}),
|
|
9231
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $d493afe60dcea711$export$2e2bcd8739ae039), {})
|
|
9232
|
+
]
|
|
9233
|
+
});
|
|
9234
|
+
};
|
|
9235
|
+
var $01986a58bfba8001$export$2e2bcd8739ae039 = $01986a58bfba8001$var$Settings;
|
|
9236
|
+
|
|
9237
|
+
|
|
9238
|
+
|
|
9239
|
+
|
|
9240
|
+
|
|
9241
|
+
|
|
9242
|
+
|
|
9243
|
+
|
|
9244
|
+
|
|
9245
|
+
const $61b9018279e658f9$export$104f28dc79f055f4 = (0, $3Sbms$styledcomponents).div`
|
|
9246
|
+
display: flex;
|
|
9247
|
+
flex: 1;
|
|
9248
|
+
flex-direction: column;
|
|
9249
|
+
justify-content: center;
|
|
9250
|
+
align-items: center;
|
|
9251
|
+
background-color: #000;
|
|
9252
|
+
color: #fff;
|
|
9253
|
+
padding-top: 70px;
|
|
9254
|
+
`;
|
|
9255
|
+
const $61b9018279e658f9$export$51071a7ce784448 = (0, $3Sbms$styledcomponents).span`
|
|
9256
|
+
font-size: 60px;
|
|
9257
|
+
`;
|
|
9258
|
+
const $61b9018279e658f9$export$eebc018855fb0cb6 = (0, $3Sbms$styledcomponents).h1`
|
|
9259
|
+
font-size: 28px;
|
|
9260
|
+
font-weight: 600;
|
|
9261
|
+
line-height: 33.6px;
|
|
9262
|
+
`;
|
|
9263
|
+
const $61b9018279e658f9$export$f4e7b895a81715e9 = (0, $3Sbms$styledcomponents).p`
|
|
9264
|
+
font-size: 22px;
|
|
9265
|
+
font-weight: 500;
|
|
9266
|
+
line-height: 26.4px;
|
|
9267
|
+
margin: 0;
|
|
9268
|
+
`;
|
|
9269
|
+
const $61b9018279e658f9$export$3a4deda42b6182b7 = (0, $3Sbms$styledcomponents).button`
|
|
9270
|
+
background-color: ${({ theme: theme })=>theme.primaryColor};
|
|
9271
|
+
border: none;
|
|
9272
|
+
border-radius: 50px;
|
|
9273
|
+
padding: 12px 18px;
|
|
9274
|
+
font-size: 16px;
|
|
9275
|
+
font-weight: 600;
|
|
9276
|
+
line-height: 18px;
|
|
9277
|
+
color: #fff;
|
|
9278
|
+
margin-top: 30px;
|
|
9279
|
+
`;
|
|
9280
|
+
|
|
9281
|
+
|
|
9282
|
+
const $df41bfe6da05853a$var$EndView = ()=>{
|
|
9283
|
+
const { t: t } = (0, $3Sbms$useTranslation)();
|
|
9284
|
+
const { streamState: streamState , setStreamState: setStreamState } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
8318
9285
|
const ended = streamState === "ended";
|
|
8319
9286
|
const terminated = streamState === "terminated";
|
|
8320
9287
|
const expired = streamState === "expired";
|
|
9288
|
+
const full = streamState === "full";
|
|
8321
9289
|
const onGoBackClick = ()=>{
|
|
8322
9290
|
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).init();
|
|
8323
9291
|
setStreamState("streaming");
|
|
@@ -8330,24 +9298,28 @@ const $df41bfe6da05853a$var$EndView = ()=>{
|
|
|
8330
9298
|
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $61b9018279e658f9$export$51071a7ce784448), {
|
|
8331
9299
|
children: [
|
|
8332
9300
|
(ended || terminated) && "\uD83D\uDC4B",
|
|
8333
|
-
expired && "\uD83E\uDD7A"
|
|
9301
|
+
(expired || full) && "\uD83E\uDD7A"
|
|
8334
9302
|
]
|
|
8335
9303
|
}),
|
|
8336
9304
|
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $61b9018279e658f9$export$eebc018855fb0cb6), {
|
|
8337
9305
|
children: [
|
|
8338
9306
|
ended && t("endView.callLeft"),
|
|
8339
9307
|
terminated && t("endView.callEnded"),
|
|
8340
|
-
expired && t("endView.tooLate")
|
|
9308
|
+
expired && t("endView.tooLate"),
|
|
9309
|
+
full && t("endView.full")
|
|
8341
9310
|
]
|
|
8342
9311
|
}),
|
|
8343
9312
|
expired && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $61b9018279e658f9$export$f4e7b895a81715e9), {
|
|
8344
9313
|
children: t("endView.callIsOver")
|
|
8345
9314
|
}),
|
|
8346
|
-
|
|
9315
|
+
full && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $61b9018279e658f9$export$f4e7b895a81715e9), {
|
|
9316
|
+
children: t("endView.fullDescription")
|
|
9317
|
+
}),
|
|
9318
|
+
(ended || full) && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $61b9018279e658f9$export$3a4deda42b6182b7), {
|
|
8347
9319
|
onClick: onGoBackClick,
|
|
8348
9320
|
children: t("endView.goBack")
|
|
8349
9321
|
}),
|
|
8350
|
-
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $f81bfa56534026c2$export$ad5f39c592532e2d), {})
|
|
9322
|
+
!full && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $f81bfa56534026c2$export$ad5f39c592532e2d), {})
|
|
8351
9323
|
]
|
|
8352
9324
|
});
|
|
8353
9325
|
};
|
|
@@ -8419,7 +9391,6 @@ var $805d92fa41e6e1b0$export$2e2bcd8739ae039 = $805d92fa41e6e1b0$var$Sounds;
|
|
|
8419
9391
|
|
|
8420
9392
|
|
|
8421
9393
|
|
|
8422
|
-
|
|
8423
9394
|
const $3a42b2ef7646d035$var$iconsMap = {
|
|
8424
9395
|
error: (0, $93a0377c243d965e$export$edf27be85e5f6da0),
|
|
8425
9396
|
critical: (0, $93a0377c243d965e$export$c7df1b15b59b1df2)
|
|
@@ -8532,7 +9503,12 @@ const $52580db2e49cdd90$export$f30cb9bc4f736419 = {
|
|
|
8532
9503
|
settingsBackgroundColor: "#fff",
|
|
8533
9504
|
settingsHeaderTextColor: "#000",
|
|
8534
9505
|
settingsTextColor: "#000",
|
|
8535
|
-
settingsCloseBackgroundColor: "#eaebec"
|
|
9506
|
+
settingsCloseBackgroundColor: "#eaebec",
|
|
9507
|
+
popupBackgroundPrimaryColor: "#fff",
|
|
9508
|
+
popupBackgroundSecondaryColor: "#f3f3f3",
|
|
9509
|
+
popupBackgroundThirdColor: "#f7f7f7",
|
|
9510
|
+
popupBorderColor: "#d4d4d4",
|
|
9511
|
+
popupTitleColor: "#2d2d2d"
|
|
8536
9512
|
};
|
|
8537
9513
|
const $52580db2e49cdd90$export$3e936a8db52a10a0 = {
|
|
8538
9514
|
primaryColor: "#268AFA",
|
|
@@ -8548,7 +9524,12 @@ const $52580db2e49cdd90$export$3e936a8db52a10a0 = {
|
|
|
8548
9524
|
settingsBackgroundColor: "#242324",
|
|
8549
9525
|
settingsHeaderTextColor: "#f9f9f9",
|
|
8550
9526
|
settingsTextColor: "#fff",
|
|
8551
|
-
settingsCloseBackgroundColor: "#7b7c7e"
|
|
9527
|
+
settingsCloseBackgroundColor: "#7b7c7e",
|
|
9528
|
+
popupBackgroundPrimaryColor: "#fff",
|
|
9529
|
+
popupBackgroundSecondaryColor: "#f3f3f3",
|
|
9530
|
+
popupBackgroundThirdColor: "#f7f7f7",
|
|
9531
|
+
popupBorderColor: "#d4d4d4",
|
|
9532
|
+
popupTitleColor: "#2d2d2d"
|
|
8552
9533
|
};
|
|
8553
9534
|
|
|
8554
9535
|
|
|
@@ -8694,6 +9675,13 @@ const $d6008ea114507578$var$SvgDefinitions = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("
|
|
|
8694
9675
|
fill: "#fff",
|
|
8695
9676
|
d: "M0 0h24v24H0z"
|
|
8696
9677
|
})
|
|
9678
|
+
}),
|
|
9679
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("clipPath", {
|
|
9680
|
+
id: "greetingSnapcallLogo",
|
|
9681
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
9682
|
+
fill: "#fff",
|
|
9683
|
+
d: "M0 0h72v72H0z"
|
|
9684
|
+
})
|
|
8697
9685
|
})
|
|
8698
9686
|
]
|
|
8699
9687
|
})
|
|
@@ -9061,6 +10049,12 @@ const $4fb4815baa04b470$export$20f257fc407da7a3 = (0, $3Sbms$createGlobalStyle)`
|
|
|
9061
10049
|
src: url('https://cdn.snapcall.io/fonts/Lato/Bold.woff2') format('woff2'),
|
|
9062
10050
|
url('https://cdn.snapcall.io/fonts/Lato/Bold.woff') format('woff');
|
|
9063
10051
|
}
|
|
10052
|
+
@font-face {
|
|
10053
|
+
font-family: 'Gazpacho';
|
|
10054
|
+
font-weight: 700;
|
|
10055
|
+
src: url('https://cdn.snapcall.io/fonts/Gazpacho/Bold.woff2') format('woff2'),
|
|
10056
|
+
url('https://cdn.snapcall.io/fonts/Gazpacho/Bold.woff') format('woff');
|
|
10057
|
+
}
|
|
9064
10058
|
`;
|
|
9065
10059
|
const $4fb4815baa04b470$export$914ddf2021ea8ee6 = (0, $3Sbms$styledcomponents).div`
|
|
9066
10060
|
display: flex;
|
|
@@ -9103,6 +10097,7 @@ const $26ed036cbc17809a$var$StreamUI = ({ options: options })=>{
|
|
|
9103
10097
|
const [isSettingsMenuVisible, setIsSettingsMenuVisible] = (0, $3Sbms$useState)(false);
|
|
9104
10098
|
const [isYoutubePopupVisible, setIsYoutubePopupVisible] = (0, $3Sbms$useState)(false);
|
|
9105
10099
|
const [isLinksharePopupVisible, setIsLinksharePopupVisible] = (0, $3Sbms$useState)(false);
|
|
10100
|
+
const [isVirtualBackgroundPopupVisible, setIsVirtualBackgroundPopupVisible] = (0, $3Sbms$useState)(false);
|
|
9106
10101
|
const [theme, setTheme] = (0, $3Sbms$useState)($26ed036cbc17809a$var$currentTheme);
|
|
9107
10102
|
const [language, setLanguage] = (0, $3Sbms$useState)(options.language || $26ed036cbc17809a$var$currentLanguage);
|
|
9108
10103
|
const [profile1, setProfile] = (0, $3Sbms$useState)({});
|
|
@@ -9113,7 +10108,7 @@ const $26ed036cbc17809a$var$StreamUI = ({ options: options })=>{
|
|
|
9113
10108
|
const [userInteractionTriggered, setUserInteractionTriggered] = (0, $3Sbms$useState)(false);
|
|
9114
10109
|
const [containerWidth, containerHeight] = (0, $af23c74942bdcae7$export$2b86bedf890eab8)(streamUIContainerRef.current);
|
|
9115
10110
|
const [isBlockedDevicesPopupOpen, setBlockedDevicesPopupOpen] = (0, $3Sbms$useState)(false);
|
|
9116
|
-
const orientation = containerWidth > containerHeight ? "landscape" : "portrait";
|
|
10111
|
+
const orientation = (containerWidth || window.screen.width) > (containerHeight || window.screen.height) ? "landscape" : "portrait";
|
|
9117
10112
|
const styledTheme = theme === "dark" ? (0, $52580db2e49cdd90$export$3e936a8db52a10a0) : (0, $52580db2e49cdd90$export$f30cb9bc4f736419);
|
|
9118
10113
|
const onEnterRoom = async (event)=>{
|
|
9119
10114
|
const peerId = event.detail.peerId;
|
|
@@ -9168,15 +10163,23 @@ const $26ed036cbc17809a$var$StreamUI = ({ options: options })=>{
|
|
|
9168
10163
|
setStreamState("expired");
|
|
9169
10164
|
};
|
|
9170
10165
|
const onAgentIdentity = (event)=>{
|
|
9171
|
-
const { success: success } = event.detail;
|
|
9172
|
-
if (success)
|
|
9173
|
-
|
|
10166
|
+
const { success: success , email: email } = event.detail;
|
|
10167
|
+
if (success) {
|
|
10168
|
+
setIsAgent(true);
|
|
10169
|
+
if (email) (0, $3Sbms$hotjarbrowser).identify(null, {
|
|
10170
|
+
email: email
|
|
10171
|
+
});
|
|
10172
|
+
} else (0, $3Sbms$reacthottoast)("An error occured while trying to join the room as an agent", {
|
|
9174
10173
|
className: "error"
|
|
9175
10174
|
});
|
|
9176
10175
|
};
|
|
9177
10176
|
const onCriticalError = (event)=>{
|
|
9178
10177
|
const duration = 20000;
|
|
9179
10178
|
const now = Date.now();
|
|
10179
|
+
if (event.detail.code === "USERLIMIT") {
|
|
10180
|
+
setStreamState("full");
|
|
10181
|
+
return;
|
|
10182
|
+
}
|
|
9180
10183
|
if ($26ed036cbc17809a$var$timestampCriticalError !== -1 && $26ed036cbc17809a$var$timestampCriticalError + duration > now) return;
|
|
9181
10184
|
$26ed036cbc17809a$var$timestampCriticalError = now;
|
|
9182
10185
|
(0, $a5146f9062d7bf28$export$3a57e165650c636f)(`A critical error has occurred (error ${event.detail.code}).`, {
|
|
@@ -9259,6 +10262,8 @@ const $26ed036cbc17809a$var$StreamUI = ({ options: options })=>{
|
|
|
9259
10262
|
setIsYoutubePopupVisible: setIsYoutubePopupVisible,
|
|
9260
10263
|
isLinksharePopupVisible: isLinksharePopupVisible,
|
|
9261
10264
|
setIsLinksharePopupVisible: setIsLinksharePopupVisible,
|
|
10265
|
+
isVirtualBackgroundPopupVisible: isVirtualBackgroundPopupVisible,
|
|
10266
|
+
setIsVirtualBackgroundPopupVisible: setIsVirtualBackgroundPopupVisible,
|
|
9262
10267
|
theme: theme,
|
|
9263
10268
|
setTheme: setTheme,
|
|
9264
10269
|
language: language,
|
|
@@ -9298,7 +10303,7 @@ const $26ed036cbc17809a$var$StreamUI = ({ options: options })=>{
|
|
|
9298
10303
|
]
|
|
9299
10304
|
})
|
|
9300
10305
|
}),
|
|
9301
|
-
(streamState === "ended" || streamState === "terminated" || streamState === "expired") && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $df41bfe6da05853a$export$2e2bcd8739ae039), {})
|
|
10306
|
+
(streamState === "ended" || streamState === "terminated" || streamState === "full" || streamState === "expired") && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $df41bfe6da05853a$export$2e2bcd8739ae039), {})
|
|
9302
10307
|
]
|
|
9303
10308
|
})
|
|
9304
10309
|
]
|
|
@@ -9309,6 +10314,432 @@ var $26ed036cbc17809a$export$2e2bcd8739ae039 = $26ed036cbc17809a$var$StreamUI;
|
|
|
9309
10314
|
|
|
9310
10315
|
|
|
9311
10316
|
|
|
10317
|
+
// https://help.hotjar.com/hc/en-us/articles/360033640653-Identify-API-Reference#01G2A279ZXW4JT60NKXKX69G49
|
|
10318
|
+
// prettier-ignore
|
|
10319
|
+
// @ts-ignore
|
|
10320
|
+
window.hj = window.hj || function() {
|
|
10321
|
+
(hj.q = hj.q || []).push(arguments);
|
|
10322
|
+
};
|
|
10323
|
+
|
|
10324
|
+
|
|
10325
|
+
|
|
10326
|
+
|
|
10327
|
+
|
|
10328
|
+
|
|
10329
|
+
|
|
10330
|
+
|
|
10331
|
+
const $9a3d651cab8c9249$var$GreetingSnapcallLogo = ()=>{
|
|
10332
|
+
return /*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
10333
|
+
width: "72",
|
|
10334
|
+
height: "72",
|
|
10335
|
+
viewBox: "0 0 72 72",
|
|
10336
|
+
fill: "none",
|
|
10337
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
10338
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)("g", {
|
|
10339
|
+
clipPath: "url(#greetingSnapcallLogo)",
|
|
10340
|
+
children: [
|
|
10341
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
10342
|
+
d: "M0 36C0 6.354 6.354 0 36 0s36 6.354 36 36-6.354 36-36 36S0 65.646 0 36Z",
|
|
10343
|
+
fill: "#000"
|
|
10344
|
+
}),
|
|
10345
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
10346
|
+
d: "M36.225 57.428c2.367 0 4.35-1.964 3.62-4.215a13.38 13.38 0 0 0-3.133-5.203c-2.432-2.498-5.73-3.902-9.17-3.902-3.44 0-6.74 1.404-9.172 3.902a13.381 13.381 0 0 0-3.132 5.203c-.731 2.25 1.252 4.215 3.62 4.215h17.367ZM35.775 14.572c-2.367 0-4.35 1.965-3.62 4.216a13.381 13.381 0 0 0 3.133 5.203c2.432 2.498 5.73 3.901 9.17 3.901 3.44 0 6.74-1.403 9.172-3.901a13.375 13.375 0 0 0 3.132-5.203c.731-2.252-1.252-4.216-3.62-4.216H35.776ZM44.459 53.143c0 2.367 1.971 4.352 4.204 3.566a12.924 12.924 0 0 0 4.967-3.182c2.432-2.498 3.799-5.886 3.799-9.419 0-3.533-1.367-6.921-3.8-9.42a12.923 12.923 0 0 0-4.966-3.181c-2.233-.786-4.204 1.2-4.204 3.566v18.07ZM27.541 18.857c0-2.367-1.971-4.352-4.204-3.566a12.923 12.923 0 0 0-4.967 3.182c-2.432 2.498-3.799 5.886-3.799 9.42 0 3.532 1.367 6.92 3.8 9.418a12.923 12.923 0 0 0 4.966 3.182c2.233.786 4.204-1.2 4.204-3.566v-18.07Z",
|
|
10347
|
+
fill: "#fff"
|
|
10348
|
+
})
|
|
10349
|
+
]
|
|
10350
|
+
})
|
|
10351
|
+
});
|
|
10352
|
+
};
|
|
10353
|
+
var $9a3d651cab8c9249$export$2e2bcd8739ae039 = $9a3d651cab8c9249$var$GreetingSnapcallLogo;
|
|
10354
|
+
|
|
10355
|
+
|
|
10356
|
+
|
|
10357
|
+
|
|
10358
|
+
const $35c6a4b506b7dc62$export$d653589df987fd93 = (0, $3Sbms$styledcomponents).div`
|
|
10359
|
+
height: 100%;
|
|
10360
|
+
display: flex;
|
|
10361
|
+
flex-direction: column;
|
|
10362
|
+
align-items: center;
|
|
10363
|
+
color: #1d1c20;
|
|
10364
|
+
padding-top: 76px;
|
|
10365
|
+
font-family: Lato;
|
|
10366
|
+
box-sizing: border-box;
|
|
10367
|
+
`;
|
|
10368
|
+
const $35c6a4b506b7dc62$export$d43ffeaaec0b2a58 = (0, $3Sbms$styledcomponents).div`
|
|
10369
|
+
display: flex;
|
|
10370
|
+
align-items: center;
|
|
10371
|
+
justify-content: center;
|
|
10372
|
+
width: 72px;
|
|
10373
|
+
height: 72px;
|
|
10374
|
+
svg {
|
|
10375
|
+
width: 50px;
|
|
10376
|
+
height: 50px;
|
|
10377
|
+
}
|
|
10378
|
+
background-color: black;
|
|
10379
|
+
border-radius: 25px;
|
|
10380
|
+
box-sizing: border-box;
|
|
10381
|
+
`;
|
|
10382
|
+
const $35c6a4b506b7dc62$export$873b7756313e36bb = (0, $3Sbms$styledcomponents).h1`
|
|
10383
|
+
font-size: 32px;
|
|
10384
|
+
line-height: 39px;
|
|
10385
|
+
font-weight: 700;
|
|
10386
|
+
font-family: Gazpacho;
|
|
10387
|
+
text-align: center;
|
|
10388
|
+
`;
|
|
10389
|
+
const $35c6a4b506b7dc62$export$b7a7fefc0b349825 = (0, $3Sbms$styledcomponents).div`
|
|
10390
|
+
display: flex;
|
|
10391
|
+
align-items: center;
|
|
10392
|
+
gap: 10px;
|
|
10393
|
+
`;
|
|
10394
|
+
const $35c6a4b506b7dc62$export$b302ef9d8310f71 = (0, $3Sbms$styledcomponents).div`
|
|
10395
|
+
position: relative;
|
|
10396
|
+
width: 350px;
|
|
10397
|
+
height: 350px;
|
|
10398
|
+
display: flex;
|
|
10399
|
+
align-items: center;
|
|
10400
|
+
justify-content: center;
|
|
10401
|
+
`;
|
|
10402
|
+
const $35c6a4b506b7dc62$export$ae01dedf5c052bb = (0, $3Sbms$styledcomponents).video`
|
|
10403
|
+
width: 300px;
|
|
10404
|
+
height: 300px;
|
|
10405
|
+
background-color: black;
|
|
10406
|
+
border-radius: 15px;
|
|
10407
|
+
object-fit: cover;
|
|
10408
|
+
`;
|
|
10409
|
+
const $35c6a4b506b7dc62$export$778ed67917f5eacf = (0, $3Sbms$styledcomponents).div`
|
|
10410
|
+
display: flex;
|
|
10411
|
+
position: absolute;
|
|
10412
|
+
top: 8px;
|
|
10413
|
+
left: 8px;
|
|
10414
|
+
gap: 8px;
|
|
10415
|
+
z-index: 15;
|
|
10416
|
+
`;
|
|
10417
|
+
const $35c6a4b506b7dc62$export$92fe811838849d7d = (0, $3Sbms$styledcomponents).div`
|
|
10418
|
+
display: flex;
|
|
10419
|
+
justify-content: center;
|
|
10420
|
+
align-items: center;
|
|
10421
|
+
width: 26px;
|
|
10422
|
+
height: 26px;
|
|
10423
|
+
border-radius: 50%;
|
|
10424
|
+
background-color: rgba(28, 32, 36, 0.25);
|
|
10425
|
+
z-index: 2;
|
|
10426
|
+
`;
|
|
10427
|
+
const $35c6a4b506b7dc62$export$65550b47dde6d016 = (0, $3Sbms$styledcomponents).div`
|
|
10428
|
+
position: absolute;
|
|
10429
|
+
width: 300px;
|
|
10430
|
+
height: 300px;
|
|
10431
|
+
background-color: black;
|
|
10432
|
+
border-radius: 15px;
|
|
10433
|
+
z-index: 1;
|
|
10434
|
+
display: ${({ webcamEnabled: webcamEnabled })=>webcamEnabled ? "none" : "flex"};
|
|
10435
|
+
align-items: center;
|
|
10436
|
+
justify-content: center;
|
|
10437
|
+
`;
|
|
10438
|
+
const $35c6a4b506b7dc62$export$48377ae1c677702b = (0, $3Sbms$styledcomponents).div`
|
|
10439
|
+
position: absolute;
|
|
10440
|
+
bottom: 45px;
|
|
10441
|
+
display: flex;
|
|
10442
|
+
width: 100%;
|
|
10443
|
+
justify-content: center;
|
|
10444
|
+
gap: 13px;
|
|
10445
|
+
z-index: 2;
|
|
10446
|
+
`;
|
|
10447
|
+
const $35c6a4b506b7dc62$export$6e8af0bd0a2aaa77 = (0, $3Sbms$styledcomponents).button`
|
|
10448
|
+
display: flex;
|
|
10449
|
+
align-items: center;
|
|
10450
|
+
justify-content: center;
|
|
10451
|
+
min-width: 48px;
|
|
10452
|
+
min-height: 48px;
|
|
10453
|
+
background-color: ${({ danger: danger })=>danger ? "#d84949" : "#2d2d2d"};
|
|
10454
|
+
border: none;
|
|
10455
|
+
border-radius: 15px;
|
|
10456
|
+
padding: 0 8px;
|
|
10457
|
+
gap: 8px;
|
|
10458
|
+
cursor: pointer;
|
|
10459
|
+
|
|
10460
|
+
p {
|
|
10461
|
+
color: white;
|
|
10462
|
+
font-size: 14px;
|
|
10463
|
+
font-weight: 600;
|
|
10464
|
+
margin: 0;
|
|
10465
|
+
}
|
|
10466
|
+
|
|
10467
|
+
&:hover {
|
|
10468
|
+
border: 2px solid ${({ danger: danger })=>danger ? "#fc7d7d" : "#8d8d8d"};
|
|
10469
|
+
}
|
|
10470
|
+
|
|
10471
|
+
svg {
|
|
10472
|
+
width: 24px;
|
|
10473
|
+
height: 24px;
|
|
10474
|
+
}
|
|
10475
|
+
`;
|
|
10476
|
+
const $35c6a4b506b7dc62$export$c7a6f02121c3b3b5 = (0, $3Sbms$styledcomponents).div`
|
|
10477
|
+
display: flex;
|
|
10478
|
+
flex-direction: column;
|
|
10479
|
+
align-items: flex-start;
|
|
10480
|
+
width: 350px;
|
|
10481
|
+
|
|
10482
|
+
h3 {
|
|
10483
|
+
margin: 0;
|
|
10484
|
+
}
|
|
10485
|
+
`;
|
|
10486
|
+
const $35c6a4b506b7dc62$export$916d4667067f956a = (0, $3Sbms$styledcomponents).h3`
|
|
10487
|
+
font-size: 20px;
|
|
10488
|
+
line-height: 24px;
|
|
10489
|
+
font-weight: 700;
|
|
10490
|
+
margin: 0;
|
|
10491
|
+
font-family: Gazpacho;
|
|
10492
|
+
`;
|
|
10493
|
+
const $35c6a4b506b7dc62$export$190947c3048e2d5d = (0, $3Sbms$styledcomponents).p`
|
|
10494
|
+
font-size: 16px;
|
|
10495
|
+
line-height: 22px;
|
|
10496
|
+
font-weight: 400;
|
|
10497
|
+
`;
|
|
10498
|
+
const $35c6a4b506b7dc62$export$f5b8910cec6cf069 = (0, $3Sbms$styledcomponents).input`
|
|
10499
|
+
width: 100%;
|
|
10500
|
+
border: 1px solid #c9c9ca;
|
|
10501
|
+
border-radius: 8px;
|
|
10502
|
+
height: 50px;
|
|
10503
|
+
padding: 14px 12px;
|
|
10504
|
+
box-sizing: border-box;
|
|
10505
|
+
margin-top: 40px;
|
|
10506
|
+
font-size: 16px;
|
|
10507
|
+
`;
|
|
10508
|
+
const $35c6a4b506b7dc62$export$353f5b6fc5456de1 = (0, $3Sbms$styledcomponents).button`
|
|
10509
|
+
width: 100%;
|
|
10510
|
+
background-color: #1d1c20;
|
|
10511
|
+
color: white;
|
|
10512
|
+
padding: 0;
|
|
10513
|
+
outline: inherit;
|
|
10514
|
+
height: 50px;
|
|
10515
|
+
border: 0;
|
|
10516
|
+
border-radius: 8px;
|
|
10517
|
+
margin-top: 15px;
|
|
10518
|
+
font-size: 16px;
|
|
10519
|
+
line-height: 19px;
|
|
10520
|
+
font-weight: 500;
|
|
10521
|
+
cursor: pointer;
|
|
10522
|
+
`;
|
|
10523
|
+
const $35c6a4b506b7dc62$export$a06f1c675e846f6f = (0, $3Sbms$styledcomponents).footer`
|
|
10524
|
+
display: flex;
|
|
10525
|
+
flex: 1;
|
|
10526
|
+
justify-content: flex-end;
|
|
10527
|
+
flex-direction: column;
|
|
10528
|
+
margin-bottom: 30px;
|
|
10529
|
+
align-items: center;
|
|
10530
|
+
text-align: center;
|
|
10531
|
+
width: 300px;
|
|
10532
|
+
`;
|
|
10533
|
+
const $35c6a4b506b7dc62$export$53e4a0ea45e729a2 = (0, $3Sbms$styledcomponents).h5`
|
|
10534
|
+
font-weight: 700;
|
|
10535
|
+
font-size: 16px;
|
|
10536
|
+
line-height: 19px;
|
|
10537
|
+
margin: 0;
|
|
10538
|
+
font-family: Gazpacho;
|
|
10539
|
+
`;
|
|
10540
|
+
const $35c6a4b506b7dc62$export$eb20cbaff2d739a5 = (0, $3Sbms$styledcomponents).p`
|
|
10541
|
+
font-weight: 400;
|
|
10542
|
+
font-size: 12px;
|
|
10543
|
+
line-height: 14px;
|
|
10544
|
+
color: black;
|
|
10545
|
+
margin-bottom: 0;
|
|
10546
|
+
margin-top: 10px;
|
|
10547
|
+
`;
|
|
10548
|
+
const $35c6a4b506b7dc62$export$d4a1a815e49dfefd = (0, $3Sbms$styledcomponents).div`
|
|
10549
|
+
display: flex;
|
|
10550
|
+
flex-direction: column;
|
|
10551
|
+
align-items: center;
|
|
10552
|
+
justify-content: center;
|
|
10553
|
+
background-color: #fff;
|
|
10554
|
+
color: #1d1c20;
|
|
10555
|
+
height: 100%;
|
|
10556
|
+
`;
|
|
10557
|
+
|
|
10558
|
+
|
|
10559
|
+
|
|
10560
|
+
|
|
10561
|
+
|
|
10562
|
+
const $f8d57e3d223f5089$var$getUserMedia = async (device)=>{
|
|
10563
|
+
try {
|
|
10564
|
+
const stream = navigator.mediaDevices.getUserMedia({
|
|
10565
|
+
video: device === "webcam",
|
|
10566
|
+
audio: device === "microphone"
|
|
10567
|
+
});
|
|
10568
|
+
return stream;
|
|
10569
|
+
} catch (err) {
|
|
10570
|
+
console.error("Get User Media Failed: ", err);
|
|
10571
|
+
return null;
|
|
10572
|
+
}
|
|
10573
|
+
};
|
|
10574
|
+
let $f8d57e3d223f5089$var$videoTrack;
|
|
10575
|
+
const $f8d57e3d223f5089$var$GreetingView = ({ onGreetingDone: onGreetingDone })=>{
|
|
10576
|
+
const { t: t } = (0, $3Sbms$useTranslation)();
|
|
10577
|
+
const mainContainerRef = (0, $3Sbms$useRef)(null);
|
|
10578
|
+
const videoRef = (0, $3Sbms$useRef)(null);
|
|
10579
|
+
const inputRef = (0, $3Sbms$useRef)(null);
|
|
10580
|
+
const stream = (0, $3Sbms$useMemo)(()=>new MediaStream(), []);
|
|
10581
|
+
const [webcamEnabled, setWebcamEnabled] = (0, $3Sbms$useState)(false);
|
|
10582
|
+
const [micEnabled, setMicEnabled] = (0, $3Sbms$useState)(false);
|
|
10583
|
+
const [joining, setJoining] = (0, $3Sbms$useState)(false);
|
|
10584
|
+
const [firstRender, setFirstRender] = (0, $3Sbms$useState)(true);
|
|
10585
|
+
const [width, height] = (0, $af23c74942bdcae7$export$2b86bedf890eab8)(mainContainerRef.current);
|
|
10586
|
+
const desktop = width >= height;
|
|
10587
|
+
const onSubmit = ()=>{
|
|
10588
|
+
const displayName = inputRef.current?.value;
|
|
10589
|
+
setJoining(true);
|
|
10590
|
+
setTimeout(()=>{
|
|
10591
|
+
onGreetingDone({
|
|
10592
|
+
cameraEnabled: webcamEnabled,
|
|
10593
|
+
micEnabled: micEnabled,
|
|
10594
|
+
displayName: displayName
|
|
10595
|
+
});
|
|
10596
|
+
}, 4000);
|
|
10597
|
+
};
|
|
10598
|
+
const onCameraClick = (0, $3Sbms$useCallback)(()=>{
|
|
10599
|
+
if (!webcamEnabled) $f8d57e3d223f5089$var$getUserMedia("webcam").then((videoStream)=>{
|
|
10600
|
+
if (!videoStream || !videoRef.current) return;
|
|
10601
|
+
$f8d57e3d223f5089$var$videoTrack = videoStream.getVideoTracks()[0];
|
|
10602
|
+
stream.addTrack($f8d57e3d223f5089$var$videoTrack);
|
|
10603
|
+
setWebcamEnabled(true);
|
|
10604
|
+
if (!videoRef.current.srcObject) videoRef.current.srcObject = stream;
|
|
10605
|
+
});
|
|
10606
|
+
else {
|
|
10607
|
+
if ($f8d57e3d223f5089$var$videoTrack) stream.removeTrack($f8d57e3d223f5089$var$videoTrack);
|
|
10608
|
+
$f8d57e3d223f5089$var$videoTrack = undefined;
|
|
10609
|
+
setWebcamEnabled(false);
|
|
10610
|
+
}
|
|
10611
|
+
}, [
|
|
10612
|
+
webcamEnabled,
|
|
10613
|
+
stream
|
|
10614
|
+
]);
|
|
10615
|
+
const onMicrophoneClick = (0, $3Sbms$useCallback)(async ()=>{
|
|
10616
|
+
if (!micEnabled) $f8d57e3d223f5089$var$getUserMedia("microphone").then(()=>{
|
|
10617
|
+
if (!videoRef.current) return;
|
|
10618
|
+
setMicEnabled(true);
|
|
10619
|
+
});
|
|
10620
|
+
else setMicEnabled(false);
|
|
10621
|
+
}, [
|
|
10622
|
+
micEnabled
|
|
10623
|
+
]);
|
|
10624
|
+
(0, $3Sbms$useEffect)(()=>{
|
|
10625
|
+
if (!firstRender) return;
|
|
10626
|
+
try {
|
|
10627
|
+
onCameraClick();
|
|
10628
|
+
onMicrophoneClick();
|
|
10629
|
+
} catch (err) {
|
|
10630
|
+
console.error("Error: ", err);
|
|
10631
|
+
} finally{
|
|
10632
|
+
setFirstRender(false);
|
|
10633
|
+
}
|
|
10634
|
+
}, [
|
|
10635
|
+
firstRender,
|
|
10636
|
+
onCameraClick,
|
|
10637
|
+
onMicrophoneClick
|
|
10638
|
+
]);
|
|
10639
|
+
if (joining === true) return /*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$d4a1a815e49dfefd), {
|
|
10640
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("img", {
|
|
10641
|
+
src: `${"https://stream-assets.snapcall.io/v1.7.0"}/animations/snapcall-logo-animation.gif`,
|
|
10642
|
+
alt: "Snapcall logo animation",
|
|
10643
|
+
height: 40
|
|
10644
|
+
})
|
|
10645
|
+
});
|
|
10646
|
+
return /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $35c6a4b506b7dc62$export$d653589df987fd93), {
|
|
10647
|
+
ref: mainContainerRef,
|
|
10648
|
+
children: [
|
|
10649
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $4fb4815baa04b470$export$20f257fc407da7a3), {}),
|
|
10650
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $9a3d651cab8c9249$export$2e2bcd8739ae039), {}),
|
|
10651
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$873b7756313e36bb), {
|
|
10652
|
+
children: t("greeting.mainTitle")
|
|
10653
|
+
}),
|
|
10654
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $35c6a4b506b7dc62$export$b7a7fefc0b349825), {
|
|
10655
|
+
children: [
|
|
10656
|
+
desktop && /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $35c6a4b506b7dc62$export$b302ef9d8310f71), {
|
|
10657
|
+
children: [
|
|
10658
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$ae01dedf5c052bb), {
|
|
10659
|
+
webcamEnabled: webcamEnabled,
|
|
10660
|
+
ref: videoRef,
|
|
10661
|
+
autoPlay: true
|
|
10662
|
+
}),
|
|
10663
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $35c6a4b506b7dc62$export$65550b47dde6d016), {
|
|
10664
|
+
webcamEnabled: webcamEnabled,
|
|
10665
|
+
children: [
|
|
10666
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $35c6a4b506b7dc62$export$778ed67917f5eacf), {
|
|
10667
|
+
children: [
|
|
10668
|
+
!micEnabled && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$92fe811838849d7d), {
|
|
10669
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $6043ae1b48c5aa97$export$2e2bcd8739ae039), {
|
|
10670
|
+
status: !micEnabled
|
|
10671
|
+
})
|
|
10672
|
+
}),
|
|
10673
|
+
!webcamEnabled && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$92fe811838849d7d), {
|
|
10674
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $04e57b1f07a8e9f4$export$2e2bcd8739ae039), {
|
|
10675
|
+
status: !webcamEnabled
|
|
10676
|
+
})
|
|
10677
|
+
})
|
|
10678
|
+
]
|
|
10679
|
+
}),
|
|
10680
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$6e8af0bd0a2aaa77), {
|
|
10681
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $57da43088f4a416a$export$2e2bcd8739ae039), {})
|
|
10682
|
+
})
|
|
10683
|
+
]
|
|
10684
|
+
}),
|
|
10685
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $35c6a4b506b7dc62$export$48377ae1c677702b), {
|
|
10686
|
+
children: [
|
|
10687
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$6e8af0bd0a2aaa77), {
|
|
10688
|
+
onClick: onMicrophoneClick,
|
|
10689
|
+
danger: !micEnabled,
|
|
10690
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $6043ae1b48c5aa97$export$2e2bcd8739ae039), {
|
|
10691
|
+
status: !micEnabled
|
|
10692
|
+
})
|
|
10693
|
+
}),
|
|
10694
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$6e8af0bd0a2aaa77), {
|
|
10695
|
+
onClick: onCameraClick,
|
|
10696
|
+
danger: !webcamEnabled,
|
|
10697
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $04e57b1f07a8e9f4$export$2e2bcd8739ae039), {
|
|
10698
|
+
status: !webcamEnabled
|
|
10699
|
+
})
|
|
10700
|
+
})
|
|
10701
|
+
]
|
|
10702
|
+
})
|
|
10703
|
+
]
|
|
10704
|
+
}),
|
|
10705
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $35c6a4b506b7dc62$export$c7a6f02121c3b3b5), {
|
|
10706
|
+
children: [
|
|
10707
|
+
desktop && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$916d4667067f956a), {
|
|
10708
|
+
children: t("greeting.sideTitle")
|
|
10709
|
+
}),
|
|
10710
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$190947c3048e2d5d), {
|
|
10711
|
+
children: t("greeting.sideDescription")
|
|
10712
|
+
}),
|
|
10713
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$f5b8910cec6cf069), {
|
|
10714
|
+
ref: inputRef,
|
|
10715
|
+
name: "displayName",
|
|
10716
|
+
type: "text",
|
|
10717
|
+
placeholder: t("greeting.namePlaceholder"),
|
|
10718
|
+
autoFocus: true
|
|
10719
|
+
}),
|
|
10720
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$353f5b6fc5456de1), {
|
|
10721
|
+
onClick: onSubmit,
|
|
10722
|
+
children: t("greeting.nameSubmit")
|
|
10723
|
+
})
|
|
10724
|
+
]
|
|
10725
|
+
})
|
|
10726
|
+
]
|
|
10727
|
+
}),
|
|
10728
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $35c6a4b506b7dc62$export$a06f1c675e846f6f), {
|
|
10729
|
+
children: [
|
|
10730
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$53e4a0ea45e729a2), {
|
|
10731
|
+
children: t("greeting.footerTitle")
|
|
10732
|
+
}),
|
|
10733
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $35c6a4b506b7dc62$export$eb20cbaff2d739a5), {
|
|
10734
|
+
children: t("greeting.footerDescription")
|
|
10735
|
+
})
|
|
10736
|
+
]
|
|
10737
|
+
})
|
|
10738
|
+
]
|
|
10739
|
+
});
|
|
10740
|
+
};
|
|
10741
|
+
var $f8d57e3d223f5089$export$2e2bcd8739ae039 = $f8d57e3d223f5089$var$GreetingView;
|
|
10742
|
+
|
|
9312
10743
|
|
|
9313
10744
|
const $24075a5d702d64b3$var$currentURL = new URL(window.location.href);
|
|
9314
10745
|
const $24075a5d702d64b3$var$microphoneEnabled = $24075a5d702d64b3$var$currentURL.searchParams.get("microphone-enabled") !== "0";
|
|
@@ -9316,6 +10747,12 @@ const $24075a5d702d64b3$var$cameraEnabled = $24075a5d702d64b3$var$currentURL.sea
|
|
|
9316
10747
|
const $24075a5d702d64b3$var$defaultOptions = {
|
|
9317
10748
|
sharedURL: window.location.href,
|
|
9318
10749
|
showMenuButton: true,
|
|
10750
|
+
settingsShortcuts: [
|
|
10751
|
+
{
|
|
10752
|
+
id: "pip",
|
|
10753
|
+
displayType: "icon"
|
|
10754
|
+
}
|
|
10755
|
+
],
|
|
9319
10756
|
controls: {
|
|
9320
10757
|
microphone: {
|
|
9321
10758
|
available: true,
|
|
@@ -9329,7 +10766,8 @@ const $24075a5d702d64b3$var$defaultOptions = {
|
|
|
9329
10766
|
available: true
|
|
9330
10767
|
}
|
|
9331
10768
|
},
|
|
9332
|
-
streamApiURL: String("https://apistream.snapcall.io")
|
|
10769
|
+
streamApiURL: String("https://apistream.snapcall.io"),
|
|
10770
|
+
tracking: false
|
|
9333
10771
|
};
|
|
9334
10772
|
const $24075a5d702d64b3$export$3f94917203ab7078 = {
|
|
9335
10773
|
init: ({ element: element , ...options })=>{
|
|
@@ -9338,6 +10776,12 @@ const $24075a5d702d64b3$export$3f94917203ab7078 = {
|
|
|
9338
10776
|
(0, $3Sbms$render)(/*#__PURE__*/ (0, $3Sbms$jsx)((0, $26ed036cbc17809a$export$2e2bcd8739ae039), {
|
|
9339
10777
|
options: mergedOptions
|
|
9340
10778
|
}), element);
|
|
10779
|
+
if (mergedOptions.tracking) (0, $3Sbms$hotjarbrowser).init(3111933, 6);
|
|
10780
|
+
},
|
|
10781
|
+
initGreeting: (element, onGreetingDone)=>{
|
|
10782
|
+
(0, $3Sbms$render)(/*#__PURE__*/ (0, $3Sbms$jsx)((0, $f8d57e3d223f5089$export$2e2bcd8739ae039), {
|
|
10783
|
+
onGreetingDone: onGreetingDone
|
|
10784
|
+
}), element);
|
|
9341
10785
|
},
|
|
9342
10786
|
setExtraSettingsOptions: (extraOptions)=>{
|
|
9343
10787
|
const event = new CustomEvent("streamUISetExtraSettingsOptions", {
|