@snapcall/stream-ui 1.10.0 → 1.11.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/dist/stream-ui.esm.js +1611 -232
- package/dist/stream-ui.js +1606 -230
- package/dist/stream-ui.umd.js +314 -243
- package/dist/{timer.370d0e5a.js → timer.7144fe82.js} +4 -0
- package/dist/{timer.7690fc0b.js → timer.d0b8fda2.js} +4 -0
- package/dist/types.d.ts +30 -4
- package/package.json +25 -12
package/dist/stream-ui.esm.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {jsx as $3Sbms$jsx, jsxs as $3Sbms$jsxs, Fragment as $3Sbms$Fragment} from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import {createRoot as $3Sbms$createRoot} from "react-dom/client";
|
|
3
3
|
import $3Sbms$hotjarbrowser from "@hotjar/browser";
|
|
4
4
|
import $3Sbms$reacthottoast, {toast as $3Sbms$toast, Toaster as $3Sbms$Toaster, ToastBar as $3Sbms$ToastBar} from "react-hot-toast";
|
|
5
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";
|
|
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
|
+
import $3Sbms$react, {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, forwardRef as $3Sbms$forwardRef} from "react";
|
|
7
7
|
import "inobounce";
|
|
8
8
|
import $3Sbms$i18next from "i18next";
|
|
9
9
|
import {initReactI18next as $3Sbms$initReactI18next, useTranslation as $3Sbms$useTranslation} from "react-i18next";
|
|
@@ -14,11 +14,24 @@ import {captureException as $3Sbms$captureException, addBreadcrumb as $3Sbms$add
|
|
|
14
14
|
import {Producer as $3Sbms$Producer} from "mediasoup-client/lib/Producer";
|
|
15
15
|
import {Device as $3Sbms$Device} from "mediasoup-client";
|
|
16
16
|
import {SelfieSegmentation as $3Sbms$SelfieSegmentation} from "@mediapipe/selfie_segmentation";
|
|
17
|
+
import {createPortal as $3Sbms$createPortal} from "react-dom";
|
|
17
18
|
import {toCanvas as $3Sbms$toCanvas} from "qrcode";
|
|
19
|
+
import {useOverlayTriggerState as $3Sbms$useOverlayTriggerState, useToggleState as $3Sbms$useToggleState} from "react-stately";
|
|
20
|
+
import $3Sbms$classnames from "classnames";
|
|
21
|
+
import {useToggleButton as $3Sbms$useToggleButton, useFocusRing as $3Sbms$useFocusRing, useButton as $3Sbms$useButton} from "react-aria";
|
|
22
|
+
import {useModalOverlay as $3Sbms$useModalOverlay, Overlay as $3Sbms$Overlay} from "@react-aria/overlays";
|
|
23
|
+
import {useViewportSize as $3Sbms$useViewportSize} from "@react-aria/utils";
|
|
24
|
+
import {CSSTransition as $3Sbms$CSSTransition} from "react-transition-group";
|
|
25
|
+
import {useHover as $3Sbms$useHover} from "@react-aria/interactions";
|
|
26
|
+
import $3Sbms$reactcontentloader from "react-content-loader";
|
|
27
|
+
|
|
28
|
+
function $parcel$interopDefault(a) {
|
|
29
|
+
return a && a.__esModule ? a.default : a;
|
|
30
|
+
}
|
|
18
31
|
|
|
19
32
|
|
|
20
33
|
|
|
21
|
-
|
|
34
|
+
// https://github.com/voodoocreation/ts-deepmerge/blob/master/src/index.ts
|
|
22
35
|
const $365e765f9890497b$var$isObject = (obj)=>{
|
|
23
36
|
if (typeof obj === "object" && obj !== null) {
|
|
24
37
|
if (typeof Object.getPrototypeOf === "function") {
|
|
@@ -805,7 +818,7 @@ var $384d985bb9605c35$export$2e2bcd8739ae039 = (0, $3Sbms$i18next);
|
|
|
805
818
|
|
|
806
819
|
|
|
807
820
|
|
|
808
|
-
|
|
821
|
+
/* eslint-disable no-console */
|
|
809
822
|
const $0f65a9eaf4a1e910$var$LogLevel = {
|
|
810
823
|
error: 1,
|
|
811
824
|
warn: 2,
|
|
@@ -972,8 +985,8 @@ class $67e45b2e30dcc030$export$ea669869acd8f177 {
|
|
|
972
985
|
});
|
|
973
986
|
try {
|
|
974
987
|
this.audioStreamSource.disconnect(this.analyser);
|
|
975
|
-
} catch (
|
|
976
|
-
$67e45b2e30dcc030$var$log.error("release", "audioStreamSource failed to disconnect",
|
|
988
|
+
} catch (err) {
|
|
989
|
+
$67e45b2e30dcc030$var$log.error("release", "audioStreamSource failed to disconnect", err);
|
|
977
990
|
}
|
|
978
991
|
this.audioContext.close().catch((err)=>{
|
|
979
992
|
$67e45b2e30dcc030$var$log.error("release", "audioContext failed to close", err);
|
|
@@ -1227,7 +1240,7 @@ class $0148b6fd862a22e8$export$2e2bcd8739ae039 {
|
|
|
1227
1240
|
live = false;
|
|
1228
1241
|
fps = 24;
|
|
1229
1242
|
blurLevel = 10;
|
|
1230
|
-
timerWorker = new Worker(new URL("timer.
|
|
1243
|
+
timerWorker = new Worker(new URL("timer.7144fe82.js", import.meta.url), {
|
|
1231
1244
|
name: "VirtualBackgroundTimerWorker"
|
|
1232
1245
|
});
|
|
1233
1246
|
constructor(stream, options){
|
|
@@ -1359,7 +1372,7 @@ class $0148b6fd862a22e8$export$2e2bcd8739ae039 {
|
|
|
1359
1372
|
|
|
1360
1373
|
|
|
1361
1374
|
const $c31e3fb4360572af$var$log = new (0, $0f65a9eaf4a1e910$export$2e2bcd8739ae039)("StreamerClient");
|
|
1362
|
-
const $c31e3fb4360572af$export$
|
|
1375
|
+
const $c31e3fb4360572af$export$103bedf43ba882db = {
|
|
1363
1376
|
WEBRTC_FAILED: "WRTC1",
|
|
1364
1377
|
WEBRTC_RECOVER_ERROR: "WRTC2",
|
|
1365
1378
|
CREATE_TRANSPORT_FAILED: "TRANS1",
|
|
@@ -1408,7 +1421,7 @@ const $c31e3fb4360572af$var$WEBCAM_SIMULCAST_ENCODINGS = [
|
|
|
1408
1421
|
{
|
|
1409
1422
|
scaleResolutionDownBy: 1,
|
|
1410
1423
|
maxBitrate: 5000000
|
|
1411
|
-
}
|
|
1424
|
+
}
|
|
1412
1425
|
];
|
|
1413
1426
|
const $c31e3fb4360572af$var$SCREEN_SHARING_SIMULCAST_ENCODINGS = [
|
|
1414
1427
|
{
|
|
@@ -1418,7 +1431,7 @@ const $c31e3fb4360572af$var$SCREEN_SHARING_SIMULCAST_ENCODINGS = [
|
|
|
1418
1431
|
{
|
|
1419
1432
|
dtx: true,
|
|
1420
1433
|
maxBitrate: 6000000
|
|
1421
|
-
}
|
|
1434
|
+
}
|
|
1422
1435
|
];
|
|
1423
1436
|
class $c31e3fb4360572af$var$SnapcallEvent extends CustomEvent {
|
|
1424
1437
|
// eslint-disable-next-line @typescript-eslint/no-useless-constructor
|
|
@@ -1446,6 +1459,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1446
1459
|
super();
|
|
1447
1460
|
navigator.mediaDevices.addEventListener("devicechange", ()=>this.onDeviceChange());
|
|
1448
1461
|
this.config = {
|
|
1462
|
+
streamApiURL: String("https://apistream.snapcall.io"),
|
|
1449
1463
|
apiUrl: String("https://api.snapcall.io/v2"),
|
|
1450
1464
|
streamerServer: String("wss://g.snapcall.io/stream"),
|
|
1451
1465
|
streamerApi: String("https://g.snapcall.io/stream"),
|
|
@@ -1455,7 +1469,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1455
1469
|
username: "test",
|
|
1456
1470
|
credential: "test",
|
|
1457
1471
|
credentialType: "password"
|
|
1458
|
-
}
|
|
1472
|
+
}
|
|
1459
1473
|
]
|
|
1460
1474
|
};
|
|
1461
1475
|
this.peers = new Map();
|
|
@@ -1496,10 +1510,8 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1496
1510
|
}
|
|
1497
1511
|
};
|
|
1498
1512
|
peer.producersData.forEach((producer)=>{
|
|
1499
|
-
if (producer.deviceType === "microphone")
|
|
1500
|
-
|
|
1501
|
-
deviceState.microphone.muted = producer.paused;
|
|
1502
|
-
} else if (producer.deviceType === "screen") deviceState.screenshare.enabled = true;
|
|
1513
|
+
if (producer.deviceType === "microphone") deviceState.microphone.enabled = true;
|
|
1514
|
+
else if (producer.deviceType === "screen") deviceState.screenshare.enabled = true;
|
|
1503
1515
|
else if (producer.deviceType === "webcam") deviceState.camera.enabled = true;
|
|
1504
1516
|
});
|
|
1505
1517
|
peers.push({
|
|
@@ -1565,7 +1577,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1565
1577
|
if (!this.peerId) this.peerId = (0, $3Sbms$v4)();
|
|
1566
1578
|
let url;
|
|
1567
1579
|
try {
|
|
1568
|
-
const { streamer_instance: instanceId , plan: { permissions: permissions , name: name }
|
|
1580
|
+
const { streamer_instance: instanceId , plan: { permissions: permissions , name: name } } = await fetch(`${this.config.apiUrl}/streams/${room}/info`, {
|
|
1569
1581
|
method: "get",
|
|
1570
1582
|
headers: {
|
|
1571
1583
|
"Content-Type": "application/json"
|
|
@@ -1576,7 +1588,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1576
1588
|
});
|
|
1577
1589
|
this.permissions = permissions;
|
|
1578
1590
|
this.plan = name;
|
|
1579
|
-
url = `${this.config.streamerServer}/${instanceId}
|
|
1591
|
+
url = `${this.config.streamerServer}/${instanceId}${this.joinOptions.recorder ? "/recorder" : ""}?roomId=${room}&peerId=${this.peerId}`;
|
|
1580
1592
|
} catch (roomError) {
|
|
1581
1593
|
const event = new $c31e3fb4360572af$var$SnapcallEvent("invalidRoom", {
|
|
1582
1594
|
detail: {}
|
|
@@ -1592,34 +1604,40 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1592
1604
|
});
|
|
1593
1605
|
this.protoo = new $3Sbms$Peer(this.protooTransport);
|
|
1594
1606
|
this.protoo.on("open", ()=>{
|
|
1607
|
+
if (this.joinOptions.recorder) {
|
|
1608
|
+
this.joinRecorder();
|
|
1609
|
+
return;
|
|
1610
|
+
}
|
|
1595
1611
|
this.joinRoom();
|
|
1596
1612
|
});
|
|
1597
1613
|
this.protoo.on("failed", ()=>{
|
|
1598
1614
|
$c31e3fb4360572af$var$log.error("protoo.on", "failed");
|
|
1599
|
-
this.onCriticalError($c31e3fb4360572af$export$
|
|
1615
|
+
this.onCriticalError($c31e3fb4360572af$export$103bedf43ba882db.SOCKET_LOST);
|
|
1600
1616
|
});
|
|
1601
1617
|
this.protoo.on("disconnected", ()=>{
|
|
1602
1618
|
$c31e3fb4360572af$var$log.error("protoo.on", "disconnected");
|
|
1603
|
-
this.onCriticalError($c31e3fb4360572af$export$
|
|
1619
|
+
this.onCriticalError($c31e3fb4360572af$export$103bedf43ba882db.SOCKET_LOST);
|
|
1604
1620
|
});
|
|
1605
1621
|
this.protoo.on("close", ()=>$c31e3fb4360572af$var$log.log("protoo.on", "close :("));
|
|
1606
1622
|
this.protoo.on("notification", async (notification)=>{
|
|
1607
1623
|
$c31e3fb4360572af$var$log.log("notification", notification);
|
|
1608
1624
|
if (notification.method === "error") {
|
|
1609
|
-
if (notification.data?.reason === "reached user limit") this.onCriticalError($c31e3fb4360572af$export$
|
|
1625
|
+
if (notification.data?.reason === "reached user limit") this.onCriticalError($c31e3fb4360572af$export$103bedf43ba882db.USER_LIMIT);
|
|
1610
1626
|
} else if (notification.method === "newPeer") {
|
|
1611
|
-
const { id: id , profile: profile } = notification.data;
|
|
1627
|
+
const { id: id , profile: profile , muted: muted } = notification.data;
|
|
1612
1628
|
this.peers.set(id, {
|
|
1613
1629
|
id: id,
|
|
1614
1630
|
peerId: id,
|
|
1615
1631
|
profile: profile,
|
|
1632
|
+
muted: muted,
|
|
1616
1633
|
producersData: []
|
|
1617
1634
|
});
|
|
1618
1635
|
const event = new $c31e3fb4360572af$var$SnapcallEvent("newPeer", {
|
|
1619
1636
|
detail: {
|
|
1620
1637
|
peerId: id,
|
|
1621
1638
|
displayName: profile.name,
|
|
1622
|
-
profile: profile
|
|
1639
|
+
profile: profile,
|
|
1640
|
+
muted: muted
|
|
1623
1641
|
}
|
|
1624
1642
|
});
|
|
1625
1643
|
this.dispatchEvent(event);
|
|
@@ -1650,7 +1668,10 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1650
1668
|
this.onConsumerClose({
|
|
1651
1669
|
consumerId: consumerId
|
|
1652
1670
|
});
|
|
1653
|
-
} else if (notification.method === "
|
|
1671
|
+
} else if (notification.method === "recordStopped") this.dispatchEvent(new $c31e3fb4360572af$var$SnapcallEvent("recordStopped", {
|
|
1672
|
+
detail: notification.data
|
|
1673
|
+
}));
|
|
1674
|
+
else if (notification.method === "displayName") {
|
|
1654
1675
|
const { peerId: peerId , displayName: displayName } = notification.data;
|
|
1655
1676
|
const event = new $c31e3fb4360572af$var$SnapcallEvent("displayName", {
|
|
1656
1677
|
detail: {
|
|
@@ -1698,6 +1719,26 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1698
1719
|
}
|
|
1699
1720
|
});
|
|
1700
1721
|
this.dispatchEvent(event);
|
|
1722
|
+
} else if (notification.method === "mute") {
|
|
1723
|
+
const { peerId: peerId , device: device } = notification.data;
|
|
1724
|
+
const event = new $c31e3fb4360572af$var$SnapcallEvent("mediaPause", {
|
|
1725
|
+
detail: {
|
|
1726
|
+
peerId: peerId,
|
|
1727
|
+
deviceType: device,
|
|
1728
|
+
paused: true
|
|
1729
|
+
}
|
|
1730
|
+
});
|
|
1731
|
+
this.dispatchEvent(event);
|
|
1732
|
+
} else if (notification.method === "unmute") {
|
|
1733
|
+
const { peerId: peerId , device: device } = notification.data;
|
|
1734
|
+
const event = new $c31e3fb4360572af$var$SnapcallEvent("mediaResume", {
|
|
1735
|
+
detail: {
|
|
1736
|
+
peerId: peerId,
|
|
1737
|
+
deviceType: device,
|
|
1738
|
+
paused: false
|
|
1739
|
+
}
|
|
1740
|
+
});
|
|
1741
|
+
this.dispatchEvent(event);
|
|
1701
1742
|
} else if (notification.method === "requestDeviceResult") {
|
|
1702
1743
|
const event = new $c31e3fb4360572af$var$SnapcallEvent(notification.method, {
|
|
1703
1744
|
detail: notification.data
|
|
@@ -1710,17 +1751,17 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1710
1751
|
});
|
|
1711
1752
|
this.dispatchEvent(event);
|
|
1712
1753
|
} else if (notification.method === "customMessage") {
|
|
1713
|
-
const { messageId: messageId , chunk:
|
|
1754
|
+
const { messageId: messageId , chunk: chunk , chunkIndex: chunkIndex , totalChunks: totalChunks } = notification.data.event;
|
|
1714
1755
|
const existingMessage = this.customMessages.get(messageId);
|
|
1715
1756
|
if (existingMessage) existingMessage.chunks.push({
|
|
1716
1757
|
index: chunkIndex,
|
|
1717
|
-
data:
|
|
1758
|
+
data: chunk
|
|
1718
1759
|
});
|
|
1719
1760
|
else this.customMessages.set(messageId, {
|
|
1720
1761
|
chunks: [
|
|
1721
1762
|
{
|
|
1722
1763
|
index: chunkIndex,
|
|
1723
|
-
data:
|
|
1764
|
+
data: chunk
|
|
1724
1765
|
}
|
|
1725
1766
|
],
|
|
1726
1767
|
totalChunks: totalChunks
|
|
@@ -1765,7 +1806,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1765
1806
|
transport.transport = await promise;
|
|
1766
1807
|
if (transport.transport) this.listenWebRTCTransportStates(transport);
|
|
1767
1808
|
} catch (err) {
|
|
1768
|
-
this.onCriticalError($c31e3fb4360572af$export$
|
|
1809
|
+
this.onCriticalError($c31e3fb4360572af$export$103bedf43ba882db.CREATE_TRANSPORT_FAILED);
|
|
1769
1810
|
throw err;
|
|
1770
1811
|
}
|
|
1771
1812
|
return transport.transport;
|
|
@@ -1792,7 +1833,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1792
1833
|
}
|
|
1793
1834
|
});
|
|
1794
1835
|
$c31e3fb4360572af$var$log.error("listenWebRTCTransportStats", "webrtc stat failed", err);
|
|
1795
|
-
this.onCriticalError($c31e3fb4360572af$export$
|
|
1836
|
+
this.onCriticalError($c31e3fb4360572af$export$103bedf43ba882db.WEBRTC_FAILED);
|
|
1796
1837
|
}
|
|
1797
1838
|
}
|
|
1798
1839
|
});
|
|
@@ -1833,7 +1874,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1833
1874
|
{
|
|
1834
1875
|
...peer,
|
|
1835
1876
|
peerId: peer.id || peer.peerId
|
|
1836
|
-
}
|
|
1877
|
+
}
|
|
1837
1878
|
]));
|
|
1838
1879
|
const callId = await this.getCallId();
|
|
1839
1880
|
this.dispatchEvent(new $c31e3fb4360572af$var$SnapcallEvent("enterRoom", {
|
|
@@ -1861,6 +1902,19 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1861
1902
|
});
|
|
1862
1903
|
});
|
|
1863
1904
|
}
|
|
1905
|
+
async joinRecorder() {
|
|
1906
|
+
this.streamerMediasoup = await (0, $a2f0e3c29b11c88e$export$2e2bcd8739ae039).create(this.protoo, this.config);
|
|
1907
|
+
const callId = await this.getCallId();
|
|
1908
|
+
this.dispatchEvent(new $c31e3fb4360572af$var$SnapcallEvent("enterRoom", {
|
|
1909
|
+
detail: {
|
|
1910
|
+
peerId: this.peerId,
|
|
1911
|
+
peers: [],
|
|
1912
|
+
callId: callId,
|
|
1913
|
+
plan: this.plan,
|
|
1914
|
+
permissions: this.permissions
|
|
1915
|
+
}
|
|
1916
|
+
}));
|
|
1917
|
+
}
|
|
1864
1918
|
async switchMicrophone(deviceId) {
|
|
1865
1919
|
try {
|
|
1866
1920
|
$c31e3fb4360572af$var$log.log("switchMicrophone", "switching Microphone");
|
|
@@ -1985,28 +2039,30 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
1985
2039
|
this.dispatchEvent(event);
|
|
1986
2040
|
}
|
|
1987
2041
|
}
|
|
1988
|
-
|
|
2042
|
+
muteMicrophone() {
|
|
1989
2043
|
if (this.micProducer) {
|
|
1990
2044
|
this.onStopSpeak();
|
|
1991
|
-
this.micProducer
|
|
1992
|
-
await this.protoo.request("pauseProducer", {
|
|
1993
|
-
producerId: this.micProducer?.id
|
|
1994
|
-
});
|
|
2045
|
+
this.micProducer.pause();
|
|
1995
2046
|
this.muted = true;
|
|
2047
|
+
const device = "microphone";
|
|
2048
|
+
this.protoo.notify("mute", {
|
|
2049
|
+
device: device
|
|
2050
|
+
});
|
|
1996
2051
|
const event = new $c31e3fb4360572af$var$SnapcallEvent("microphoneMute", {
|
|
1997
2052
|
detail: {}
|
|
1998
2053
|
});
|
|
1999
2054
|
this.dispatchEvent(event);
|
|
2000
2055
|
}
|
|
2001
2056
|
}
|
|
2002
|
-
|
|
2057
|
+
unMuteMicrophone() {
|
|
2003
2058
|
if (this.micProducer) {
|
|
2004
2059
|
this.micProducer.resume();
|
|
2005
2060
|
this.resolvePendingDeviceRequest("microphone", true);
|
|
2006
|
-
await this.protoo.request("resumeProducer", {
|
|
2007
|
-
producerId: this.micProducer.id
|
|
2008
|
-
});
|
|
2009
2061
|
this.muted = false;
|
|
2062
|
+
const device = "microphone";
|
|
2063
|
+
this.protoo.notify("unmute", {
|
|
2064
|
+
device: device
|
|
2065
|
+
});
|
|
2010
2066
|
const event = new $c31e3fb4360572af$var$SnapcallEvent("microphoneUnmute", {
|
|
2011
2067
|
detail: {}
|
|
2012
2068
|
});
|
|
@@ -2114,7 +2170,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2114
2170
|
iceParameters: iceParameters
|
|
2115
2171
|
});
|
|
2116
2172
|
} catch (err) {
|
|
2117
|
-
this.onCriticalError($c31e3fb4360572af$export$
|
|
2173
|
+
this.onCriticalError($c31e3fb4360572af$export$103bedf43ba882db.WEBRTC_RECOVER_ERROR);
|
|
2118
2174
|
$c31e3fb4360572af$var$log.log("restartIce", "restartIceFailed", err);
|
|
2119
2175
|
$3Sbms$captureException(err, {
|
|
2120
2176
|
extra: {
|
|
@@ -2181,20 +2237,39 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2181
2237
|
if (!this.webcamProducer || this.webcamProducer.closed) return;
|
|
2182
2238
|
await this.switchWebcam({});
|
|
2183
2239
|
}
|
|
2184
|
-
async switchWebcam({ device: device , resolution: resolution , rotate: rotate }) {
|
|
2240
|
+
async switchWebcam({ device: device , resolution: resolution , rotate: rotate , frameRate: frameRate , facingMode: facingMode }) {
|
|
2185
2241
|
if (!this.webcam.device) throw new Error("no webcam devices");
|
|
2242
|
+
const optionalParam = {};
|
|
2186
2243
|
if (rotate) {
|
|
2187
|
-
|
|
2188
|
-
|
|
2189
|
-
|
|
2190
|
-
|
|
2191
|
-
else
|
|
2192
|
-
|
|
2193
|
-
|
|
2194
|
-
|
|
2195
|
-
|
|
2244
|
+
if (this.webcam.facingMode) {
|
|
2245
|
+
console.log("switch by facing mod");
|
|
2246
|
+
this.webcam.facingMode = this.webcam.facingMode === "user" ? "environment" : "user";
|
|
2247
|
+
optionalParam.facingMode = this.webcam.facingMode;
|
|
2248
|
+
} else {
|
|
2249
|
+
const webcams = Array.from(this.webcams.keys());
|
|
2250
|
+
const deviceId = this.webcam?.device?.deviceId || "unknow";
|
|
2251
|
+
let newWebcamIndex = webcams.indexOf(deviceId);
|
|
2252
|
+
if (newWebcamIndex < webcams.length - 1) newWebcamIndex++;
|
|
2253
|
+
else newWebcamIndex = 0;
|
|
2254
|
+
const newWebcamDevice = this.webcams.get(webcams[newWebcamIndex]);
|
|
2255
|
+
if (!newWebcamDevice) throw new Error("no webcam device");
|
|
2256
|
+
this.webcam.device = newWebcamDevice;
|
|
2257
|
+
this.webcam.resolution = "hd";
|
|
2258
|
+
optionalParam.deviceId = {
|
|
2259
|
+
ideal: this.webcam.device?.deviceId
|
|
2260
|
+
};
|
|
2261
|
+
}
|
|
2196
2262
|
} else {
|
|
2197
|
-
if (
|
|
2263
|
+
if (facingMode) {
|
|
2264
|
+
this.webcam.facingMode = facingMode;
|
|
2265
|
+
optionalParam.facingMode = this.webcam.facingMode;
|
|
2266
|
+
} else if (device) {
|
|
2267
|
+
this.webcam.device = device;
|
|
2268
|
+
this.webcam.facingMode = undefined;
|
|
2269
|
+
optionalParam.deviceId = {
|
|
2270
|
+
ideal: this.webcam.device.deviceId
|
|
2271
|
+
};
|
|
2272
|
+
}
|
|
2198
2273
|
if (resolution) this.webcam.resolution = resolution;
|
|
2199
2274
|
}
|
|
2200
2275
|
let usedResolution = $c31e3fb4360572af$export$d21ffcc5eb136bfa[resolution || this.webcam.resolution];
|
|
@@ -2207,11 +2282,15 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2207
2282
|
},
|
|
2208
2283
|
qualityIndex: 2
|
|
2209
2284
|
};
|
|
2285
|
+
await this.webcamProducer?.replaceTrack?.({
|
|
2286
|
+
track: null
|
|
2287
|
+
}).catch((err)=>{
|
|
2288
|
+
$c31e3fb4360572af$var$log.error("switchCamera", "clean track failed", err);
|
|
2289
|
+
});
|
|
2210
2290
|
const mediaStream = await this.handleGetUserMediaError("webcam", navigator.mediaDevices.getUserMedia({
|
|
2211
2291
|
video: {
|
|
2212
|
-
|
|
2213
|
-
|
|
2214
|
-
},
|
|
2292
|
+
frameRate: frameRate,
|
|
2293
|
+
...optionalParam,
|
|
2215
2294
|
...usedResolution
|
|
2216
2295
|
}
|
|
2217
2296
|
}));
|
|
@@ -2241,7 +2320,16 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2241
2320
|
}
|
|
2242
2321
|
async enableVideo(config) {
|
|
2243
2322
|
await this.updateWebcams();
|
|
2244
|
-
|
|
2323
|
+
const optionalParam = {};
|
|
2324
|
+
if (config?.facingMode) {
|
|
2325
|
+
optionalParam.facingMode = config.facingMode;
|
|
2326
|
+
this.webcam.facingMode = config.facingMode;
|
|
2327
|
+
} else {
|
|
2328
|
+
if (config?.device) this.webcam.device = config.device;
|
|
2329
|
+
optionalParam.deviceId = {
|
|
2330
|
+
ideal: this.webcam.device?.deviceId
|
|
2331
|
+
};
|
|
2332
|
+
}
|
|
2245
2333
|
if (!this.webcam.device) throw new Error("no webcam devices");
|
|
2246
2334
|
let usedResolution = $c31e3fb4360572af$export$d21ffcc5eb136bfa[config?.resolution || this.webcam.resolution];
|
|
2247
2335
|
if (this.useVideoBackground) usedResolution = {
|
|
@@ -2255,12 +2343,18 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2255
2343
|
};
|
|
2256
2344
|
const mediaStream = await this.handleGetUserMediaError("webcam", navigator.mediaDevices.getUserMedia({
|
|
2257
2345
|
video: {
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
},
|
|
2346
|
+
frameRate: config?.frameRate,
|
|
2347
|
+
...optionalParam,
|
|
2261
2348
|
...usedResolution
|
|
2262
2349
|
}
|
|
2263
2350
|
}));
|
|
2351
|
+
if (config?.facingMode) try {
|
|
2352
|
+
const capabilities = mediaStream.getVideoTracks()[0].getCapabilities();
|
|
2353
|
+
if (!capabilities?.facingMode || capabilities.facingMode.length === 0) throw new Error("no facing mod");
|
|
2354
|
+
} catch {
|
|
2355
|
+
this.webcam.device = this.webcams.values().next().value;
|
|
2356
|
+
this.webcam.facingMode = undefined;
|
|
2357
|
+
}
|
|
2264
2358
|
if (this.useVideoBackground) {
|
|
2265
2359
|
if (this.mediaPipe) await this.mediaPipe.clean();
|
|
2266
2360
|
this.mediaPipe = new (0, $0148b6fd862a22e8$export$2e2bcd8739ae039)(mediaStream, this.mediaPipeOption);
|
|
@@ -2316,7 +2410,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2316
2410
|
advanced: [
|
|
2317
2411
|
{
|
|
2318
2412
|
zoom: this.webcamZoom.min * 2
|
|
2319
|
-
}
|
|
2413
|
+
}
|
|
2320
2414
|
]
|
|
2321
2415
|
});
|
|
2322
2416
|
}
|
|
@@ -2327,7 +2421,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2327
2421
|
advanced: [
|
|
2328
2422
|
{
|
|
2329
2423
|
zoom: this.webcamZoom.min
|
|
2330
|
-
}
|
|
2424
|
+
}
|
|
2331
2425
|
]
|
|
2332
2426
|
});
|
|
2333
2427
|
}
|
|
@@ -2436,6 +2530,27 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2436
2530
|
element.srcObject = mediaStream;
|
|
2437
2531
|
} else $c31e3fb4360572af$var$log.error("requestVideo", `Video consumer ${consumer} not found`);
|
|
2438
2532
|
}
|
|
2533
|
+
async saveCapture(base64Image) {
|
|
2534
|
+
const { objectUrl: objectUrl } = await fetch(`${this.config.streamApiURL}/uploadSnapshot`, {
|
|
2535
|
+
method: "POST",
|
|
2536
|
+
body: JSON.stringify({
|
|
2537
|
+
file: base64Image
|
|
2538
|
+
})
|
|
2539
|
+
}).then((rawResponse)=>rawResponse.json());
|
|
2540
|
+
const res = await this.protoo.request("addCapture", {
|
|
2541
|
+
url: objectUrl
|
|
2542
|
+
});
|
|
2543
|
+
return {
|
|
2544
|
+
url: objectUrl,
|
|
2545
|
+
assetId: res.assetId
|
|
2546
|
+
};
|
|
2547
|
+
}
|
|
2548
|
+
async deleteCapture(assetId) {
|
|
2549
|
+
const res = await this.protoo.request("deleteCapture", {
|
|
2550
|
+
assetId: assetId
|
|
2551
|
+
});
|
|
2552
|
+
return res;
|
|
2553
|
+
}
|
|
2439
2554
|
async captureVideo(videoElement) {
|
|
2440
2555
|
if (this.permissions.find((permission)=>permission === "instant_picture")) {
|
|
2441
2556
|
let image;
|
|
@@ -2509,6 +2624,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2509
2624
|
deviceType: deviceType
|
|
2510
2625
|
});
|
|
2511
2626
|
this.scaleVideoEncodingsParameter();
|
|
2627
|
+
const paused = peer ? peer.muted : false;
|
|
2512
2628
|
const event = new $c31e3fb4360572af$var$SnapcallEvent("mediaStart", {
|
|
2513
2629
|
detail: {
|
|
2514
2630
|
peerId: peerId,
|
|
@@ -2529,7 +2645,7 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2529
2645
|
consumerId: consumer.id
|
|
2530
2646
|
});
|
|
2531
2647
|
} catch (error) {
|
|
2532
|
-
this.onCriticalError($c31e3fb4360572af$export$
|
|
2648
|
+
this.onCriticalError($c31e3fb4360572af$export$103bedf43ba882db.CONSUME_ERROR);
|
|
2533
2649
|
$c31e3fb4360572af$var$log.error("consumeProducer", "newConsumer request failed", error);
|
|
2534
2650
|
throw error;
|
|
2535
2651
|
}
|
|
@@ -2733,6 +2849,12 @@ class $c31e3fb4360572af$export$2e2bcd8739ae039 extends $c31e3fb4360572af$var$Str
|
|
|
2733
2849
|
getPermissions() {
|
|
2734
2850
|
return this.permissions;
|
|
2735
2851
|
}
|
|
2852
|
+
async startRecord() {
|
|
2853
|
+
await this.protoo.request("startRecord");
|
|
2854
|
+
}
|
|
2855
|
+
async stopRecord() {
|
|
2856
|
+
await this.protoo.request("stopRecord");
|
|
2857
|
+
}
|
|
2736
2858
|
}
|
|
2737
2859
|
|
|
2738
2860
|
|
|
@@ -2747,17 +2869,17 @@ var $5f30d8bf4f04621e$export$2e2bcd8739ae039 = $5f30d8bf4f04621e$var$StreamUICon
|
|
|
2747
2869
|
|
|
2748
2870
|
|
|
2749
2871
|
let $2884da8a64948e35$export$96a9662a3eda31f6;
|
|
2750
|
-
(function(
|
|
2751
|
-
|
|
2752
|
-
|
|
2753
|
-
|
|
2754
|
-
|
|
2755
|
-
|
|
2756
|
-
|
|
2757
|
-
|
|
2758
|
-
|
|
2759
|
-
|
|
2760
|
-
|
|
2872
|
+
(function(StreamsReducerActionTypes) {
|
|
2873
|
+
StreamsReducerActionTypes[StreamsReducerActionTypes["SET_STREAMS"] = 0] = "SET_STREAMS";
|
|
2874
|
+
StreamsReducerActionTypes[StreamsReducerActionTypes["ADD_STREAM"] = 1] = "ADD_STREAM";
|
|
2875
|
+
StreamsReducerActionTypes[StreamsReducerActionTypes["REMOVE_STREAM"] = 2] = "REMOVE_STREAM";
|
|
2876
|
+
StreamsReducerActionTypes[StreamsReducerActionTypes["DEVICE_UPDATE"] = 3] = "DEVICE_UPDATE";
|
|
2877
|
+
StreamsReducerActionTypes[StreamsReducerActionTypes["MUTE"] = 4] = "MUTE";
|
|
2878
|
+
StreamsReducerActionTypes[StreamsReducerActionTypes["UNMUTE"] = 5] = "UNMUTE";
|
|
2879
|
+
StreamsReducerActionTypes[StreamsReducerActionTypes["SET_HIGHLIGHTED_TILE"] = 6] = "SET_HIGHLIGHTED_TILE";
|
|
2880
|
+
StreamsReducerActionTypes[StreamsReducerActionTypes["UNSET_HIGHLIGHTED_TILE"] = 7] = "UNSET_HIGHLIGHTED_TILE";
|
|
2881
|
+
StreamsReducerActionTypes[StreamsReducerActionTypes["SET_STREAM_PROFILE"] = 8] = "SET_STREAM_PROFILE";
|
|
2882
|
+
StreamsReducerActionTypes[StreamsReducerActionTypes["SET_STREAM_SPEAKING"] = 9] = "SET_STREAM_SPEAKING";
|
|
2761
2883
|
})($2884da8a64948e35$export$96a9662a3eda31f6 || ($2884da8a64948e35$export$96a9662a3eda31f6 = {}));
|
|
2762
2884
|
const $2884da8a64948e35$export$7fc21eab2c971c9c = {
|
|
2763
2885
|
streams: [],
|
|
@@ -2968,6 +3090,52 @@ const $a1ac29d50bdaa837$var$SnapcallLogoMedium = ()=>{
|
|
|
2968
3090
|
})
|
|
2969
3091
|
});
|
|
2970
3092
|
};
|
|
3093
|
+
const $a1ac29d50bdaa837$export$3741e4ac43f04ca2 = ()=>{
|
|
3094
|
+
return /*#__PURE__*/ (0, $3Sbms$jsxs)("svg", {
|
|
3095
|
+
width: "48",
|
|
3096
|
+
height: "48",
|
|
3097
|
+
viewBox: "0 0 48 48",
|
|
3098
|
+
fill: "none",
|
|
3099
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
3100
|
+
children: [
|
|
3101
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("g", {
|
|
3102
|
+
clipPath: "url(#clip0_243_300)",
|
|
3103
|
+
children: [
|
|
3104
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
3105
|
+
d: "M0 24C0 4.236 4.236 0 24 0C43.764 0 48 4.236 48 24C48 43.764 43.764 48 24 48C4.236 48 0 43.764 0 24Z",
|
|
3106
|
+
fill: "black"
|
|
3107
|
+
}),
|
|
3108
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
3109
|
+
d: "M24.15 38.2856C25.7279 38.2856 27.0502 36.9758 26.5626 35.4753C26.1419 34.1801 25.4321 32.9898 24.4746 32.0064C22.853 30.341 20.6537 29.4053 18.3605 29.4053C16.0673 29.4053 13.8679 30.341 12.2464 32.0064C11.2888 32.9898 10.5791 34.1801 10.1583 35.4753C9.67078 36.9758 10.9931 38.2856 12.571 38.2856H24.15Z",
|
|
3110
|
+
fill: "white"
|
|
3111
|
+
}),
|
|
3112
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
3113
|
+
d: "M23.8494 9.71436C22.2714 9.71436 20.9491 11.0242 21.4367 12.5249C21.8574 13.8199 22.5672 15.0102 23.5248 15.9937C25.1463 17.6591 27.3456 18.5947 29.6389 18.5947C31.932 18.5947 34.1314 17.6591 35.7529 15.9937C36.7106 15.0102 37.4203 13.8199 37.8409 12.5249C38.3286 11.0242 37.0063 9.71436 35.4283 9.71436H23.8494Z",
|
|
3114
|
+
fill: "white"
|
|
3115
|
+
}),
|
|
3116
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
3117
|
+
d: "M29.6387 35.4287C29.6387 37.0067 30.953 38.3301 32.4415 37.8064C33.6767 37.3715 34.8118 36.6509 35.7527 35.6847C37.3744 34.0195 38.2852 31.7606 38.2852 29.4055C38.2852 27.0502 37.3744 24.7915 35.7527 23.1261C34.8118 22.1599 33.6767 21.4393 32.4415 21.0046C30.953 20.4807 29.6387 21.8043 29.6387 23.3823V35.4287Z",
|
|
3118
|
+
fill: "white"
|
|
3119
|
+
}),
|
|
3120
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
3121
|
+
d: "M18.3605 12.5712C18.3605 10.9933 17.0461 9.66972 15.5576 10.1936C14.3224 10.6283 13.1872 11.3489 12.2464 12.3151C10.6248 13.9804 9.71387 16.2392 9.71387 18.5944C9.71387 20.9496 10.6248 23.2083 12.2464 24.8737C13.1872 25.8399 14.3224 26.5605 15.5576 26.9952C17.0461 27.5191 18.3605 26.1955 18.3605 24.6176V12.5712Z",
|
|
3122
|
+
fill: "white"
|
|
3123
|
+
})
|
|
3124
|
+
]
|
|
3125
|
+
}),
|
|
3126
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("defs", {
|
|
3127
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("clipPath", {
|
|
3128
|
+
id: "clip0_243_300",
|
|
3129
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("rect", {
|
|
3130
|
+
width: "48",
|
|
3131
|
+
height: "48",
|
|
3132
|
+
fill: "white"
|
|
3133
|
+
})
|
|
3134
|
+
})
|
|
3135
|
+
})
|
|
3136
|
+
]
|
|
3137
|
+
});
|
|
3138
|
+
};
|
|
2971
3139
|
var $a1ac29d50bdaa837$export$2e2bcd8739ae039 = $a1ac29d50bdaa837$var$SnapcallLogo;
|
|
2972
3140
|
|
|
2973
3141
|
|
|
@@ -3076,8 +3244,9 @@ const $2da9626742e3560b$export$d5424e4dfe4be076 = ({ color: color })=>/*#__PURE
|
|
|
3076
3244
|
|
|
3077
3245
|
const $e1413aacdaa5a03e$export$71b2224f1ce5e08e = (ref, action)=>{
|
|
3078
3246
|
(0, $3Sbms$useEffect)(()=>{
|
|
3247
|
+
const effectTimestamp = performance.now();
|
|
3079
3248
|
const onWindowClick = (event)=>{
|
|
3080
|
-
if (!ref?.current?.contains(event.target)) action();
|
|
3249
|
+
if (!ref?.current?.contains(event.target) && event.timeStamp > effectTimestamp) action();
|
|
3081
3250
|
};
|
|
3082
3251
|
if (ref?.current) {
|
|
3083
3252
|
window.addEventListener("click", onWindowClick);
|
|
@@ -3166,7 +3335,9 @@ const $59d1053cd71d481a$var$Menu = ({ categories: categories })=>{
|
|
|
3166
3335
|
children: category.title
|
|
3167
3336
|
}),
|
|
3168
3337
|
category.items.map((item)=>/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $4ee077ee5e6fe3e7$export$44020656de05f2b4), {
|
|
3169
|
-
onClick:
|
|
3338
|
+
onClick: ()=>{
|
|
3339
|
+
item.action();
|
|
3340
|
+
},
|
|
3170
3341
|
danger: item.danger,
|
|
3171
3342
|
children: [
|
|
3172
3343
|
item.jsxIcon && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $4ee077ee5e6fe3e7$export$5912a8d3f489e1c1), {
|
|
@@ -3325,7 +3496,7 @@ const $ae6e25be45301335$var$HeaderSettings = ({ baseCategories: baseCategories ,
|
|
|
3325
3496
|
items: [
|
|
3326
3497
|
...baseCategory.items
|
|
3327
3498
|
]
|
|
3328
|
-
}))
|
|
3499
|
+
}))
|
|
3329
3500
|
];
|
|
3330
3501
|
extraCategories?.forEach((extraCategory)=>{
|
|
3331
3502
|
const existingCategory = mergedCategories.find((category)=>category.id === extraCategory.id);
|
|
@@ -3465,7 +3636,7 @@ const $e96d119a19ed0c6c$var$getLayout = ({ width: width , cellAspectRatio: cellA
|
|
|
3465
3636
|
width: roundedWidth,
|
|
3466
3637
|
height: height
|
|
3467
3638
|
}
|
|
3468
|
-
}
|
|
3639
|
+
}
|
|
3469
3640
|
],
|
|
3470
3641
|
tileCount: tileCount
|
|
3471
3642
|
};
|
|
@@ -3587,7 +3758,7 @@ const $f235befa4cdc42d6$var$multiPiP = new (0, $e96d119a19ed0c6c$export$45fabd1c
|
|
|
3587
3758
|
const $f235befa4cdc42d6$var$browser = $3Sbms$parse(window.navigator.userAgent);
|
|
3588
3759
|
const $f235befa4cdc42d6$var$Header = ()=>{
|
|
3589
3760
|
const { t: t } = (0, $3Sbms$useTranslation)();
|
|
3590
|
-
const { setIsQuickConnectPopupVisible: setIsQuickConnectPopupVisible , setIsSettingsMenuVisible: setIsSettingsMenuVisible , setIsVirtualBackgroundPopupVisible: setIsVirtualBackgroundPopupVisible , options: options , muted: muted , streaming: streaming , permissions: permissions , plan: plan , setBlockedFeaturePopupOpen: setBlockedFeaturePopupOpen
|
|
3761
|
+
const { setIsQuickConnectPopupVisible: setIsQuickConnectPopupVisible , setIsSettingsMenuVisible: setIsSettingsMenuVisible , setIsVirtualBackgroundPopupVisible: setIsVirtualBackgroundPopupVisible , options: options , muted: muted , streaming: streaming , permissions: permissions , plan: plan , setBlockedFeaturePopupOpen: setBlockedFeaturePopupOpen } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
3591
3762
|
const { streams: streams } = (0, $cce9fd41d8a55a18$export$b5633a7cfbe42d9f)();
|
|
3592
3763
|
const [extraOptions, setExtraOptions] = (0, $3Sbms$useState)(options.extraSettingsOptions || []);
|
|
3593
3764
|
const onSetExtraSettingsOptions = (event)=>{
|
|
@@ -3656,7 +3827,7 @@ const $f235befa4cdc42d6$var$Header = ()=>{
|
|
|
3656
3827
|
title: t("menu.openNewTab"),
|
|
3657
3828
|
jsxIcon: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $2da9626742e3560b$export$6546b255bd3a2004), {}),
|
|
3658
3829
|
action: onOpenInNewTabClick
|
|
3659
|
-
}
|
|
3830
|
+
}
|
|
3660
3831
|
]
|
|
3661
3832
|
},
|
|
3662
3833
|
{
|
|
@@ -3673,7 +3844,7 @@ const $f235befa4cdc42d6$var$Header = ()=>{
|
|
|
3673
3844
|
title: t("quickConnect.title"),
|
|
3674
3845
|
jsxIcon: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $2da9626742e3560b$export$6470d09a29d34d08), {}),
|
|
3675
3846
|
action: onScanQuickConnectClick
|
|
3676
|
-
}
|
|
3847
|
+
}
|
|
3677
3848
|
]
|
|
3678
3849
|
},
|
|
3679
3850
|
{
|
|
@@ -3684,9 +3855,9 @@ const $f235befa4cdc42d6$var$Header = ()=>{
|
|
|
3684
3855
|
title: t("settings.title"),
|
|
3685
3856
|
jsxIcon: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $2da9626742e3560b$export$1095c93890fce526), {}),
|
|
3686
3857
|
action: onSettingsMenuClick
|
|
3687
|
-
}
|
|
3858
|
+
}
|
|
3688
3859
|
]
|
|
3689
|
-
}
|
|
3860
|
+
}
|
|
3690
3861
|
];
|
|
3691
3862
|
if ($f235befa4cdc42d6$var$browser.platform.type === "desktop" && $f235befa4cdc42d6$var$browser.engine.name === "Blink") computedCategories[2].items.unshift({
|
|
3692
3863
|
id: "virtualBackground",
|
|
@@ -3710,7 +3881,7 @@ const $f235befa4cdc42d6$var$Header = ()=>{
|
|
|
3710
3881
|
setIsQuickConnectPopupVisible,
|
|
3711
3882
|
setBlockedFeaturePopupOpen,
|
|
3712
3883
|
setIsSettingsMenuVisible,
|
|
3713
|
-
setIsVirtualBackgroundPopupVisible
|
|
3884
|
+
setIsVirtualBackgroundPopupVisible
|
|
3714
3885
|
]);
|
|
3715
3886
|
return /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $ab29487ffcc05855$export$1e86fd0e1db89578), {
|
|
3716
3887
|
children: [
|
|
@@ -4867,7 +5038,7 @@ var $f260365f66cb6a6f$export$2e2bcd8739ae039 = $f260365f66cb6a6f$var$Reduce;
|
|
|
4867
5038
|
|
|
4868
5039
|
|
|
4869
5040
|
|
|
4870
|
-
const $57ab7b9a012d9acd$var$Cross = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
5041
|
+
const $57ab7b9a012d9acd$var$Cross = ({ color: color = "#fff" })=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
4871
5042
|
width: "24",
|
|
4872
5043
|
height: "24",
|
|
4873
5044
|
viewBox: "0 0 24 24",
|
|
@@ -4875,7 +5046,7 @@ const $57ab7b9a012d9acd$var$Cross = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
|
4875
5046
|
xmlns: "http://www.w3.org/2000/svg",
|
|
4876
5047
|
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
4877
5048
|
d: "m13.41 12 6.3-6.29a1.004 1.004 0 0 0-1.42-1.42L12 10.59l-6.29-6.3a1.004 1.004 0 1 0-1.42 1.42l6.3 6.29-6.3 6.29a.999.999 0 0 0 0 1.42 1 1 0 0 0 1.42 0l6.29-6.3 6.29 6.3a1.001 1.001 0 0 0 1.639-.325 1 1 0 0 0-.22-1.095L13.41 12Z",
|
|
4878
|
-
fill:
|
|
5049
|
+
fill: color
|
|
4879
5050
|
})
|
|
4880
5051
|
});
|
|
4881
5052
|
var $57ab7b9a012d9acd$export$2e2bcd8739ae039 = $57ab7b9a012d9acd$var$Cross;
|
|
@@ -5224,7 +5395,7 @@ const $5939a59dc7c96d41$var$SelfStreamTile = ({ isSomeonePresenting: isSomeonePr
|
|
|
5224
5395
|
const videoElementRef = (0, $3Sbms$useRef)(null);
|
|
5225
5396
|
const videoMediaProviderRef = (0, $3Sbms$useRef)(null);
|
|
5226
5397
|
const SelfTileRef = (0, $3Sbms$useRef)(null);
|
|
5227
|
-
const { videosContainerRef: videosContainerRef , remoteTilesContainerRef: remoteTilesContainerRef , profile: profile , muted: muted , streaming: streaming , orientation: orientation , options: options , permissions: permissions , setBlockedFeaturePopupOpen: setBlockedFeaturePopupOpen
|
|
5398
|
+
const { videosContainerRef: videosContainerRef , remoteTilesContainerRef: remoteTilesContainerRef , profile: profile , muted: muted , streaming: streaming , orientation: orientation , options: options , permissions: permissions , setBlockedFeaturePopupOpen: setBlockedFeaturePopupOpen } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
5228
5399
|
const { streams: streams } = (0, $cce9fd41d8a55a18$export$b5633a7cfbe42d9f)();
|
|
5229
5400
|
const [containerWidth, containerHeight] = (0, $af23c74942bdcae7$export$2b86bedf890eab8)(videosContainerRef.current);
|
|
5230
5401
|
const cursor = streaming && !extended ? "pointer" : "default";
|
|
@@ -5638,7 +5809,7 @@ const $f81bfa56534026c2$export$e9785ae652b3a722 = (item)=>{
|
|
|
5638
5809
|
{
|
|
5639
5810
|
...item,
|
|
5640
5811
|
id: 0
|
|
5641
|
-
}
|
|
5812
|
+
}
|
|
5642
5813
|
]);
|
|
5643
5814
|
localStorage.setItem(key, stringifiedHistory);
|
|
5644
5815
|
}
|
|
@@ -5746,7 +5917,7 @@ const $5e2ac34f2c3f1b42$export$405a29439cf92237 = "youtube_pause";
|
|
|
5746
5917
|
const $5e2ac34f2c3f1b42$export$649698d6e35b1ef3 = "youtube_stop";
|
|
5747
5918
|
const $5e2ac34f2c3f1b42$var$YoutubeTile = (tile)=>{
|
|
5748
5919
|
const { selfPeerId: selfPeerId } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
5749
|
-
const [
|
|
5920
|
+
const [player, setPlayer] = (0, $3Sbms$useState)(null);
|
|
5750
5921
|
const isSelf = tile.peerId === selfPeerId;
|
|
5751
5922
|
const onVideoStateChange = (event)=>{
|
|
5752
5923
|
const time = event.target.getCurrentTime();
|
|
@@ -5814,15 +5985,15 @@ const $5e2ac34f2c3f1b42$var$YoutubeTile = (tile)=>{
|
|
|
5814
5985
|
isSelf
|
|
5815
5986
|
]);
|
|
5816
5987
|
(0, $3Sbms$useEffect)(()=>{
|
|
5817
|
-
if (!isSelf &&
|
|
5988
|
+
if (!isSelf && player) {
|
|
5818
5989
|
const onCustomMessage = (event)=>{
|
|
5819
5990
|
const { type: type , time: time } = event.detail.event;
|
|
5820
5991
|
if (type === $5e2ac34f2c3f1b42$export$405a29439cf92237) {
|
|
5821
|
-
|
|
5822
|
-
|
|
5992
|
+
player.pauseVideo();
|
|
5993
|
+
player.seekTo(time, true);
|
|
5823
5994
|
} else if (type === $5e2ac34f2c3f1b42$export$1712c056f28ddd33) {
|
|
5824
|
-
|
|
5825
|
-
|
|
5995
|
+
player.playVideo();
|
|
5996
|
+
player.seekTo(time, true);
|
|
5826
5997
|
}
|
|
5827
5998
|
};
|
|
5828
5999
|
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).addEventListener("customMessage", onCustomMessage);
|
|
@@ -5830,10 +6001,10 @@ const $5e2ac34f2c3f1b42$var$YoutubeTile = (tile)=>{
|
|
|
5830
6001
|
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).removeEventListener("customMessage", onCustomMessage);
|
|
5831
6002
|
};
|
|
5832
6003
|
}
|
|
5833
|
-
if (isSelf &&
|
|
6004
|
+
if (isSelf && player) {
|
|
5834
6005
|
const onNewPeer = (event)=>{
|
|
5835
6006
|
const { peerId: peerId } = event.detail;
|
|
5836
|
-
const time =
|
|
6007
|
+
const time = player.getCurrentTime();
|
|
5837
6008
|
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).sendCustomMessage(peerId, {
|
|
5838
6009
|
type: $5e2ac34f2c3f1b42$export$8bd7ff36223ef5c1,
|
|
5839
6010
|
videoId: tile.data.videoId,
|
|
@@ -5848,7 +6019,7 @@ const $5e2ac34f2c3f1b42$var$YoutubeTile = (tile)=>{
|
|
|
5848
6019
|
}, [
|
|
5849
6020
|
tile.data,
|
|
5850
6021
|
isSelf,
|
|
5851
|
-
|
|
6022
|
+
player
|
|
5852
6023
|
]);
|
|
5853
6024
|
return /*#__PURE__*/ (0, $3Sbms$jsx)((0, $34a6fb3d684caabd$export$f4a8a05247f8d4c), {
|
|
5854
6025
|
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $34a6fb3d684caabd$export$b0da35797f3be127), {
|
|
@@ -6422,7 +6593,7 @@ var $b8963bf62cf5b984$export$2e2bcd8739ae039 = $b8963bf62cf5b984$var$tooltip;
|
|
|
6422
6593
|
|
|
6423
6594
|
|
|
6424
6595
|
const $cdab47bb8796991e$var$Video = ()=>{
|
|
6425
|
-
const { selfPeerId: selfPeerId , videosContainerRef: videosContainerRef , remoteTilesContainerRef: remoteTilesContainerRef , options: options , muted: selfMuted , profile:
|
|
6596
|
+
const { selfPeerId: selfPeerId , videosContainerRef: videosContainerRef , remoteTilesContainerRef: remoteTilesContainerRef , options: options , muted: selfMuted , profile: profile , orientation: orientation , userInteractionTriggered: userInteractionTriggered } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
6426
6597
|
const [tileSize, setTileSize] = (0, $3Sbms$useState)({
|
|
6427
6598
|
width: 0,
|
|
6428
6599
|
height: 0
|
|
@@ -6516,7 +6687,8 @@ const $cdab47bb8796991e$var$Video = ()=>{
|
|
|
6516
6687
|
const { peers: peers } = event.detail;
|
|
6517
6688
|
const roomStreams = peers.map((peer)=>({
|
|
6518
6689
|
id: peer.peerId,
|
|
6519
|
-
profile: peer.profile
|
|
6690
|
+
profile: peer.profile,
|
|
6691
|
+
muted: peer.muted
|
|
6520
6692
|
}));
|
|
6521
6693
|
dispatch({
|
|
6522
6694
|
type: (0, $2884da8a64948e35$export$96a9662a3eda31f6).SET_STREAMS,
|
|
@@ -6601,7 +6773,7 @@ const $cdab47bb8796991e$var$Video = ()=>{
|
|
|
6601
6773
|
stream: {
|
|
6602
6774
|
id: String(selfPeerId),
|
|
6603
6775
|
muted: selfMuted,
|
|
6604
|
-
profile:
|
|
6776
|
+
profile: profile
|
|
6605
6777
|
}
|
|
6606
6778
|
}),
|
|
6607
6779
|
streams.map((stream)=>{
|
|
@@ -6662,6 +6834,18 @@ const $58d405d56c1abe95$var$Rotate = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
|
6662
6834
|
fill: "#F7F7F7"
|
|
6663
6835
|
})
|
|
6664
6836
|
});
|
|
6837
|
+
const $58d405d56c1abe95$export$aefffb14595958fe = ()=>{
|
|
6838
|
+
return /*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
6839
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
6840
|
+
width: "32",
|
|
6841
|
+
height: "32",
|
|
6842
|
+
fill: "none",
|
|
6843
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
6844
|
+
fill: "#fff",
|
|
6845
|
+
d: "M26.547 20.68h-6.04a1.333 1.333 0 1 0 0 2.666h3.2A10.667 10.667 0 0 1 5.334 16a1.333 1.333 0 0 0-2.667 0 13.333 13.333 0 0 0 22.507 9.64V28a1.333 1.333 0 1 0 2.666 0v-6a1.333 1.333 0 0 0-1.293-1.32ZM16 2.666A13.333 13.333 0 0 0 6.827 6.36V4A1.333 1.333 0 1 0 4.16 4v6a1.333 1.333 0 0 0 1.334 1.333h6a1.333 1.333 0 0 0 0-2.667h-3.2A10.667 10.667 0 0 1 26.667 16a1.333 1.333 0 1 0 2.667 0A13.333 13.333 0 0 0 16 2.666Z"
|
|
6846
|
+
})
|
|
6847
|
+
});
|
|
6848
|
+
};
|
|
6665
6849
|
var $58d405d56c1abe95$export$2e2bcd8739ae039 = $58d405d56c1abe95$var$Rotate;
|
|
6666
6850
|
|
|
6667
6851
|
|
|
@@ -6845,7 +7029,7 @@ const $db92fac48417791a$var$HighlightButton = ()=>{
|
|
|
6845
7029
|
const { t: t } = (0, $3Sbms$useTranslation)();
|
|
6846
7030
|
const highlightMenuRef = (0, $3Sbms$useRef)(null);
|
|
6847
7031
|
const [isHighlightMenuOpen, setIsHighlightMenuOpen] = (0, $3Sbms$useState)(false);
|
|
6848
|
-
const { setIsYoutubePopupVisible: setIsYoutubePopupVisible , setIsLinksharePopupVisible: setIsLinksharePopupVisible , selfPeerId: selfPeerId , permissions: permissions , setBlockedFeaturePopupOpen: setBlockedFeaturePopupOpen
|
|
7032
|
+
const { setIsYoutubePopupVisible: setIsYoutubePopupVisible , setIsLinksharePopupVisible: setIsLinksharePopupVisible , selfPeerId: selfPeerId , permissions: permissions , setBlockedFeaturePopupOpen: setBlockedFeaturePopupOpen } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
6849
7033
|
const { highlightedTile: highlightedTile , dispatch: dispatch } = (0, $cce9fd41d8a55a18$export$b5633a7cfbe42d9f)();
|
|
6850
7034
|
const isPresenting = Boolean(highlightedTile?.isGlobal && highlightedTile?.peerId === selfPeerId);
|
|
6851
7035
|
(0, $e1413aacdaa5a03e$export$71b2224f1ce5e08e)(highlightMenuRef, ()=>setIsHighlightMenuOpen(false));
|
|
@@ -6898,9 +7082,9 @@ const $db92fac48417791a$var$HighlightButton = ()=>{
|
|
|
6898
7082
|
title: t("youtube.title"),
|
|
6899
7083
|
jsxIcon: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $a2d206a438475087$export$2e2bcd8739ae039), {}),
|
|
6900
7084
|
action: onYoutubeClick
|
|
6901
|
-
}
|
|
7085
|
+
}
|
|
6902
7086
|
]
|
|
6903
|
-
}
|
|
7087
|
+
}
|
|
6904
7088
|
];
|
|
6905
7089
|
if ($db92fac48417791a$var$isScreenshareSupported) menuCategories.push({
|
|
6906
7090
|
id: "2",
|
|
@@ -6910,7 +7094,7 @@ const $db92fac48417791a$var$HighlightButton = ()=>{
|
|
|
6910
7094
|
title: t("menu.screenSharing"),
|
|
6911
7095
|
jsxIcon: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $1ca024917df8f7bc$export$2e2bcd8739ae039), {}),
|
|
6912
7096
|
action: onScreenshareClick
|
|
6913
|
-
}
|
|
7097
|
+
}
|
|
6914
7098
|
]
|
|
6915
7099
|
});
|
|
6916
7100
|
return /*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$Fragment), {
|
|
@@ -7055,9 +7239,9 @@ const $69a9c49ece80e773$var$ControlBar = ()=>{
|
|
|
7055
7239
|
jsxIcon: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $2da9626742e3560b$export$e57aa6aff2e1f414), {}),
|
|
7056
7240
|
action: terminateCall,
|
|
7057
7241
|
danger: true
|
|
7058
|
-
}
|
|
7242
|
+
}
|
|
7059
7243
|
]
|
|
7060
|
-
}
|
|
7244
|
+
}
|
|
7061
7245
|
]
|
|
7062
7246
|
})
|
|
7063
7247
|
}),
|
|
@@ -7238,7 +7422,7 @@ const $5b80b81d7b095f89$var$QuickConnect = ()=>{
|
|
|
7238
7422
|
const themeContext = (0, $3Sbms$useContext)((0, $3Sbms$ThemeContext));
|
|
7239
7423
|
const QuickConnectContainerRef = (0, $3Sbms$useRef)(null);
|
|
7240
7424
|
const QuickConnectRef = (0, $3Sbms$useRef)(null);
|
|
7241
|
-
const { selfPeerId: selfPeerId , profile: profile , isQuickConnectPopupVisible: isQuickConnectPopupVisible , setIsQuickConnectPopupVisible: setIsQuickConnectPopupVisible , options: options , orientation: orientation
|
|
7425
|
+
const { selfPeerId: selfPeerId , profile: profile , isQuickConnectPopupVisible: isQuickConnectPopupVisible , setIsQuickConnectPopupVisible: setIsQuickConnectPopupVisible , options: options , orientation: orientation } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
7242
7426
|
(0, $e1413aacdaa5a03e$export$71b2224f1ce5e08e)(QuickConnectContainerRef, ()=>{
|
|
7243
7427
|
if (isQuickConnectPopupVisible) setIsQuickConnectPopupVisible(false);
|
|
7244
7428
|
});
|
|
@@ -9092,7 +9276,7 @@ const $d493afe60dcea711$var$backgroundOptions = [
|
|
|
9092
9276
|
title: "Blurred",
|
|
9093
9277
|
value: "blurred",
|
|
9094
9278
|
id: "background-blurred"
|
|
9095
|
-
}
|
|
9279
|
+
}
|
|
9096
9280
|
];
|
|
9097
9281
|
const $d493afe60dcea711$var$VirtualBackgroundPopup = ()=>{
|
|
9098
9282
|
const { t: t } = (0, $3Sbms$useTranslation)();
|
|
@@ -9365,7 +9549,7 @@ const $e1c48a389d8ac959$export$8376625f8bb18347 = (0, $3Sbms$styledcomponents).d
|
|
|
9365
9549
|
|
|
9366
9550
|
|
|
9367
9551
|
const $01986a58bfba8001$var$Settings = ()=>{
|
|
9368
|
-
const { isQuickConnectPopupVisible: isQuickConnectPopupVisible , isSettingsMenuVisible: isSettingsMenuVisible , isYoutubePopupVisible: isYoutubePopupVisible , isLinksharePopupVisible: isLinksharePopupVisible , isVirtualBackgroundPopupVisible: isVirtualBackgroundPopupVisible , isBlockedFeaturePopupOpen: isBlockedFeaturePopupOpen
|
|
9552
|
+
const { isQuickConnectPopupVisible: isQuickConnectPopupVisible , isSettingsMenuVisible: isSettingsMenuVisible , isYoutubePopupVisible: isYoutubePopupVisible , isLinksharePopupVisible: isLinksharePopupVisible , isVirtualBackgroundPopupVisible: isVirtualBackgroundPopupVisible , isBlockedFeaturePopupOpen: isBlockedFeaturePopupOpen } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
9369
9553
|
const open = isQuickConnectPopupVisible || isSettingsMenuVisible || isYoutubePopupVisible || isBlockedFeaturePopupOpen || isLinksharePopupVisible || isVirtualBackgroundPopupVisible;
|
|
9370
9554
|
return /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $e1c48a389d8ac959$export$8376625f8bb18347), {
|
|
9371
9555
|
open: open,
|
|
@@ -10143,8 +10327,8 @@ const $15a01b611391c1e7$var$audioSource = new Blob([
|
|
|
10143
10327
|
170,
|
|
10144
10328
|
170,
|
|
10145
10329
|
170,
|
|
10146
|
-
170
|
|
10147
|
-
])
|
|
10330
|
+
170
|
|
10331
|
+
])
|
|
10148
10332
|
], {
|
|
10149
10333
|
type: "audio/mpeg"
|
|
10150
10334
|
});
|
|
@@ -10245,117 +10429,1292 @@ const $4fb4815baa04b470$export$914ddf2021ea8ee6 = (0, $3Sbms$styledcomponents).d
|
|
|
10245
10429
|
|
|
10246
10430
|
|
|
10247
10431
|
|
|
10248
|
-
|
|
10249
|
-
|
|
10250
|
-
|
|
10251
|
-
|
|
10252
|
-
|
|
10253
|
-
|
|
10254
|
-
|
|
10255
|
-
|
|
10256
|
-
|
|
10257
|
-
|
|
10258
|
-
|
|
10259
|
-
|
|
10260
|
-
|
|
10261
|
-
|
|
10262
|
-
|
|
10263
|
-
|
|
10264
|
-
const
|
|
10265
|
-
|
|
10266
|
-
|
|
10267
|
-
|
|
10268
|
-
|
|
10269
|
-
|
|
10270
|
-
|
|
10271
|
-
|
|
10272
|
-
|
|
10273
|
-
const
|
|
10274
|
-
|
|
10275
|
-
const
|
|
10276
|
-
const
|
|
10277
|
-
|
|
10278
|
-
|
|
10279
|
-
|
|
10280
|
-
|
|
10281
|
-
|
|
10282
|
-
|
|
10283
|
-
|
|
10284
|
-
|
|
10285
|
-
|
|
10286
|
-
|
|
10287
|
-
|
|
10288
|
-
|
|
10289
|
-
|
|
10290
|
-
|
|
10291
|
-
|
|
10292
|
-
|
|
10293
|
-
|
|
10294
|
-
|
|
10295
|
-
|
|
10296
|
-
|
|
10297
|
-
|
|
10298
|
-
|
|
10299
|
-
|
|
10300
|
-
|
|
10301
|
-
|
|
10302
|
-
|
|
10303
|
-
|
|
10304
|
-
|
|
10305
|
-
|
|
10306
|
-
|
|
10307
|
-
|
|
10308
|
-
|
|
10309
|
-
|
|
10310
|
-
};
|
|
10311
|
-
const
|
|
10312
|
-
|
|
10313
|
-
|
|
10432
|
+
|
|
10433
|
+
|
|
10434
|
+
|
|
10435
|
+
|
|
10436
|
+
|
|
10437
|
+
|
|
10438
|
+
|
|
10439
|
+
|
|
10440
|
+
|
|
10441
|
+
|
|
10442
|
+
|
|
10443
|
+
|
|
10444
|
+
|
|
10445
|
+
|
|
10446
|
+
|
|
10447
|
+
function $5a48b7481979330f$export$61dc559f8a0b9bcf(ref) {
|
|
10448
|
+
const innerRef = (0, $3Sbms$useRef)(null);
|
|
10449
|
+
(0, $3Sbms$useEffect)(()=>{
|
|
10450
|
+
if (!ref) return;
|
|
10451
|
+
if (typeof ref === "function") ref(innerRef.current);
|
|
10452
|
+
else ref.current = innerRef.current;
|
|
10453
|
+
});
|
|
10454
|
+
return innerRef;
|
|
10455
|
+
}
|
|
10456
|
+
const $5a48b7481979330f$export$d2b052e7b4be1756 = /*#__PURE__*/ (0, $3Sbms$forwardRef)(function Button({ children: children , ...otherProps }, forwardedRef) {
|
|
10457
|
+
const ref = $5a48b7481979330f$export$61dc559f8a0b9bcf(forwardedRef);
|
|
10458
|
+
let state = (0, $3Sbms$useToggleState)(otherProps);
|
|
10459
|
+
const { buttonProps: buttonProps } = (0, $3Sbms$useToggleButton)(otherProps, state, ref);
|
|
10460
|
+
const { isFocusVisible: isFocusVisible , focusProps: focusProps } = (0, $3Sbms$useFocusRing)();
|
|
10461
|
+
return /*#__PURE__*/ (0, $3Sbms$jsx)("button", {
|
|
10462
|
+
className: (0, $3Sbms$classnames)("w-[76px] h-[40px]", otherProps.isSelected ? "bg-[#FFFFFF]" : "bg-[#FFFFFF] opacity-[0.4]", "rounded-full", "text-black", "flex items-center justify-center gap-[5px]", "text-base font-medium", "transition-colors ease-in-out", "focus:outline-none", {
|
|
10463
|
+
"ring-[3px] ring-cta": isFocusVisible,
|
|
10464
|
+
"cursor-not-allowed": buttonProps.disabled
|
|
10465
|
+
}),
|
|
10466
|
+
...buttonProps,
|
|
10467
|
+
...focusProps,
|
|
10468
|
+
ref: ref,
|
|
10469
|
+
children: children
|
|
10470
|
+
});
|
|
10471
|
+
});
|
|
10472
|
+
|
|
10473
|
+
|
|
10474
|
+
|
|
10475
|
+
|
|
10476
|
+
|
|
10477
|
+
|
|
10478
|
+
|
|
10479
|
+
|
|
10480
|
+
|
|
10481
|
+
|
|
10482
|
+
|
|
10483
|
+
|
|
10484
|
+
|
|
10485
|
+
|
|
10486
|
+
|
|
10487
|
+
|
|
10488
|
+
const $0590ee3141e14968$export$353f5b6fc5456de1 = /*#__PURE__*/ (0, $3Sbms$forwardRef)(function Button({ children: children , variant: variant = "primary" , size: size = "medium" , fullWidth: fullWidth = false , form: form , className: className , ...otherProps }, forwardedRef) {
|
|
10489
|
+
const ref = (0, $5a48b7481979330f$export$61dc559f8a0b9bcf)(forwardedRef);
|
|
10490
|
+
const { buttonProps: buttonProps , isPressed: isPressed } = (0, $3Sbms$useButton)(otherProps, ref);
|
|
10491
|
+
const { isFocusVisible: isFocusVisible , focusProps: focusProps } = (0, $3Sbms$useFocusRing)();
|
|
10492
|
+
const { hoverProps: hoverProps , isHovered: isHovered } = (0, $3Sbms$useHover)({
|
|
10493
|
+
isDisabled: buttonProps.disabled
|
|
10494
|
+
});
|
|
10495
|
+
const isActive = isHovered || isFocusVisible || isPressed;
|
|
10496
|
+
const variantStyle = {
|
|
10497
|
+
primary: (0, $3Sbms$classnames)(isActive ? "bg-primaryLight" : "bg-primary", "text-white disabled:bg-secondaryLight"),
|
|
10498
|
+
secondary: (0, $3Sbms$classnames)(isActive ? "bg-graySelected" : "bg-transparent", "text-primary border border-secondaryLight disabled:text-secondaryLight disabled:bg-graySelected"),
|
|
10499
|
+
basic: (0, $3Sbms$classnames)(isActive ? "bg-graySelected" : "bg-white", "text-primary disabled:text-secondaryLight disabled:bg-graySelected"),
|
|
10500
|
+
custom: ""
|
|
10314
10501
|
};
|
|
10315
|
-
const
|
|
10316
|
-
|
|
10502
|
+
const sizeStyle = {
|
|
10503
|
+
large: "py-3 px-4 text-base rounded-lg",
|
|
10504
|
+
medium: "py-[9px] px-3.5 text-base rounded-lg",
|
|
10505
|
+
small: "py-2 px-3 text-sm rounded-lg",
|
|
10506
|
+
extraSmall: "py-1.5 px-2.5 text-xs rounded-md",
|
|
10507
|
+
custom: ""
|
|
10317
10508
|
};
|
|
10318
|
-
|
|
10319
|
-
|
|
10320
|
-
|
|
10321
|
-
|
|
10322
|
-
|
|
10323
|
-
|
|
10324
|
-
|
|
10325
|
-
|
|
10326
|
-
|
|
10327
|
-
|
|
10509
|
+
return /*#__PURE__*/ (0, $3Sbms$jsx)("button", {
|
|
10510
|
+
className: (0, $3Sbms$classnames)(sizeStyle[size], variantStyle[variant], "flex items-center justify-center gap-[5px] font-medium", "transition-colors ease-in-out", "focus:outline-none", {
|
|
10511
|
+
"ring-[3px] ring-cta": isFocusVisible,
|
|
10512
|
+
"cursor-not-allowed": buttonProps.disabled,
|
|
10513
|
+
"w-full": fullWidth
|
|
10514
|
+
}, className),
|
|
10515
|
+
...buttonProps,
|
|
10516
|
+
...focusProps,
|
|
10517
|
+
...hoverProps,
|
|
10518
|
+
form: form,
|
|
10519
|
+
ref: ref,
|
|
10520
|
+
children: children
|
|
10521
|
+
});
|
|
10522
|
+
});
|
|
10523
|
+
|
|
10524
|
+
|
|
10525
|
+
function $c0bb66c3d546ed81$export$2b77a92f1a5ad772(props) {
|
|
10526
|
+
const { children: children , state: state , size: size = "small" , title: title , description: description , primaryAction: primaryAction , secondaryAction: secondaryAction , centered: centered = false } = props;
|
|
10527
|
+
const ref = (0, $3Sbms$react).useRef(null);
|
|
10528
|
+
const { modalProps: modalProps , underlayProps: underlayProps } = (0, $3Sbms$useModalOverlay)({
|
|
10529
|
+
isDismissable: true,
|
|
10530
|
+
...props
|
|
10531
|
+
}, state, ref);
|
|
10532
|
+
const [exited, setExited] = (0, $3Sbms$useState)(!state.isOpen);
|
|
10533
|
+
const viewport = (0, $3Sbms$useViewportSize)();
|
|
10534
|
+
const maxHeight = viewport.height - 64;
|
|
10535
|
+
const modalSize = {
|
|
10536
|
+
small: "max-w-[400px] mx-[20px]",
|
|
10537
|
+
medium: "max-w-[600px]",
|
|
10538
|
+
large: "max-w-[800px]"
|
|
10328
10539
|
};
|
|
10329
|
-
|
|
10330
|
-
|
|
10331
|
-
|
|
10332
|
-
|
|
10333
|
-
|
|
10334
|
-
|
|
10335
|
-
|
|
10336
|
-
|
|
10337
|
-
|
|
10338
|
-
|
|
10339
|
-
|
|
10340
|
-
button: {
|
|
10341
|
-
text: "Reload",
|
|
10342
|
-
action: ()=>{
|
|
10343
|
-
window.location.reload();
|
|
10344
|
-
}
|
|
10540
|
+
// Don't render anything if the modal is not open and we're not animating out.
|
|
10541
|
+
if (!(state.isOpen || !exited)) return null;
|
|
10542
|
+
return /*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$Overlay), {
|
|
10543
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$CSSTransition), {
|
|
10544
|
+
in: state.isOpen,
|
|
10545
|
+
appear: true,
|
|
10546
|
+
onEntered: ()=>setExited(false),
|
|
10547
|
+
onExited: ()=>setExited(true),
|
|
10548
|
+
timeout: {
|
|
10549
|
+
enter: 0,
|
|
10550
|
+
exit: 300
|
|
10345
10551
|
},
|
|
10346
|
-
|
|
10347
|
-
|
|
10348
|
-
|
|
10349
|
-
|
|
10350
|
-
|
|
10351
|
-
|
|
10352
|
-
|
|
10353
|
-
|
|
10354
|
-
|
|
10355
|
-
|
|
10356
|
-
|
|
10357
|
-
|
|
10358
|
-
|
|
10552
|
+
classNames: {
|
|
10553
|
+
enter: "opacity-0",
|
|
10554
|
+
enterDone: "opacity-1 transition ease-in",
|
|
10555
|
+
exit: "opacity-0 transition ease-out"
|
|
10556
|
+
},
|
|
10557
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
10558
|
+
className: "fixed z-[100] inset-0 bg-black bg-opacity-90 flex justify-center items-center",
|
|
10559
|
+
...underlayProps,
|
|
10560
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$CSSTransition), {
|
|
10561
|
+
in: state.isOpen,
|
|
10562
|
+
appear: true,
|
|
10563
|
+
nodeRef: ref,
|
|
10564
|
+
timeout: {
|
|
10565
|
+
enter: 0,
|
|
10566
|
+
exit: 300
|
|
10567
|
+
},
|
|
10568
|
+
classNames: {
|
|
10569
|
+
appear: "translate-y-2",
|
|
10570
|
+
appearDone: "translate-y-0 transition ease-in",
|
|
10571
|
+
exit: "translate-y-2 transition ease-out"
|
|
10572
|
+
},
|
|
10573
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
10574
|
+
...modalProps,
|
|
10575
|
+
ref: ref,
|
|
10576
|
+
className: (0, $3Sbms$classnames)("bg-white rounded-[10px] z-[1] overflow-auto focus:outline-none", modalSize[size]),
|
|
10577
|
+
style: {
|
|
10578
|
+
maxHeight: `${maxHeight}px`
|
|
10579
|
+
},
|
|
10580
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
10581
|
+
className: "flex flex-col gap-5 px-5 py-[25px]",
|
|
10582
|
+
children: [
|
|
10583
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
10584
|
+
className: (0, $3Sbms$classnames)("flex flex-col gap-[5px]", {
|
|
10585
|
+
"text-center": centered
|
|
10586
|
+
}),
|
|
10587
|
+
children: [
|
|
10588
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("h2", {
|
|
10589
|
+
className: "text-xl font-medium",
|
|
10590
|
+
children: title
|
|
10591
|
+
}),
|
|
10592
|
+
description && /*#__PURE__*/ (0, $3Sbms$jsx)("p", {
|
|
10593
|
+
className: "text-sm text-secondary",
|
|
10594
|
+
children: description
|
|
10595
|
+
})
|
|
10596
|
+
]
|
|
10597
|
+
}),
|
|
10598
|
+
children,
|
|
10599
|
+
(primaryAction || secondaryAction) && /*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
10600
|
+
className: (0, $3Sbms$classnames)("flex justify-end gap-2.5", centered ? "justify-center" : "justify-end"),
|
|
10601
|
+
children: [
|
|
10602
|
+
typeof secondaryAction === "string" && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $0590ee3141e14968$export$353f5b6fc5456de1), {
|
|
10603
|
+
variant: "secondary",
|
|
10604
|
+
onPress: state.close,
|
|
10605
|
+
fullWidth: centered,
|
|
10606
|
+
children: secondaryAction
|
|
10607
|
+
}),
|
|
10608
|
+
typeof secondaryAction === "function" && secondaryAction({
|
|
10609
|
+
close: state.close
|
|
10610
|
+
}),
|
|
10611
|
+
typeof primaryAction === "string" && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $0590ee3141e14968$export$353f5b6fc5456de1), {
|
|
10612
|
+
onPress: state.close,
|
|
10613
|
+
fullWidth: centered,
|
|
10614
|
+
children: primaryAction
|
|
10615
|
+
}),
|
|
10616
|
+
typeof primaryAction === "function" && primaryAction({
|
|
10617
|
+
close: state.close
|
|
10618
|
+
})
|
|
10619
|
+
]
|
|
10620
|
+
})
|
|
10621
|
+
]
|
|
10622
|
+
})
|
|
10623
|
+
})
|
|
10624
|
+
})
|
|
10625
|
+
})
|
|
10626
|
+
})
|
|
10627
|
+
});
|
|
10628
|
+
}
|
|
10629
|
+
|
|
10630
|
+
|
|
10631
|
+
|
|
10632
|
+
|
|
10633
|
+
const $444e1dd9fa8f6883$export$f9da3144ae2525a3 = ()=>/*#__PURE__*/ (0, $3Sbms$jsxs)("svg", {
|
|
10634
|
+
width: "20",
|
|
10635
|
+
height: "21",
|
|
10636
|
+
viewBox: "0 0 20 21",
|
|
10637
|
+
fill: "none",
|
|
10638
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
10639
|
+
style: {
|
|
10640
|
+
display: "inline"
|
|
10641
|
+
},
|
|
10642
|
+
transform: "translate(0 -1)",
|
|
10643
|
+
children: [
|
|
10644
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
10645
|
+
d: "M10 2.167a8.333 8.333 0 1 0 0 16.666 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.333Z",
|
|
10646
|
+
fill: "#1D1C20"
|
|
10647
|
+
}),
|
|
10648
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
10649
|
+
d: "M6.76 5.65a5.833 5.833 0 1 1 6.481 9.7 5.833 5.833 0 0 1-6.481-9.7Z",
|
|
10650
|
+
fill: "#F12828"
|
|
10651
|
+
})
|
|
10652
|
+
]
|
|
10653
|
+
});
|
|
10654
|
+
const $444e1dd9fa8f6883$export$c6a849fd9d9d93a2 = ()=>/*#__PURE__*/ (0, $3Sbms$jsxs)("svg", {
|
|
10655
|
+
width: "20",
|
|
10656
|
+
height: "20",
|
|
10657
|
+
viewBox: "0 0 20 20",
|
|
10658
|
+
fill: "none",
|
|
10659
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
10660
|
+
style: {
|
|
10661
|
+
display: "inline"
|
|
10662
|
+
},
|
|
10663
|
+
transform: "translate(0 -1)",
|
|
10664
|
+
children: [
|
|
10665
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
10666
|
+
d: "M10 1.667a8.333 8.333 0 1 0 0 16.666 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.333Z",
|
|
10667
|
+
fill: "#1D1C20"
|
|
10668
|
+
}),
|
|
10669
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
10670
|
+
d: "M7.5 6.667h5a.833.833 0 0 1 .833.833v5a.833.833 0 0 1-.834.834h-5a.833.833 0 0 1-.833-.834v-5a.833.833 0 0 1 .833-.833Z",
|
|
10671
|
+
fill: "#F12828"
|
|
10672
|
+
})
|
|
10673
|
+
]
|
|
10674
|
+
});
|
|
10675
|
+
const $444e1dd9fa8f6883$export$dce36e07153365d = ()=>/*#__PURE__*/ (0, $3Sbms$jsxs)("svg", {
|
|
10676
|
+
width: "20",
|
|
10677
|
+
height: "20",
|
|
10678
|
+
viewBox: "0 0 20 20",
|
|
10679
|
+
fill: "none",
|
|
10680
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
10681
|
+
style: {
|
|
10682
|
+
display: "inline"
|
|
10683
|
+
},
|
|
10684
|
+
transform: "translate(0 -1)",
|
|
10685
|
+
children: [
|
|
10686
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
10687
|
+
d: "M10 1.667a8.333 8.333 0 1 0 0 16.666 8.333 8.333 0 0 0 0-16.666Zm0 15a6.666 6.666 0 1 1 0-13.333 6.666 6.666 0 0 1 0 13.333Z",
|
|
10688
|
+
fill: "#1D1C20"
|
|
10689
|
+
}),
|
|
10690
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
10691
|
+
d: "M6.76 5.15a5.833 5.833 0 1 1 6.481 9.7 5.833 5.833 0 0 1-6.481-9.7Z",
|
|
10692
|
+
fill: "#1D1C20"
|
|
10693
|
+
})
|
|
10694
|
+
]
|
|
10695
|
+
});
|
|
10696
|
+
|
|
10697
|
+
|
|
10698
|
+
|
|
10699
|
+
|
|
10700
|
+
|
|
10701
|
+
const $f4e9ebfd4b02cf09$var$Text = ({ children: children })=>/*#__PURE__*/ (0, $3Sbms$jsx)("span", {
|
|
10702
|
+
className: "w-full text-base text-primaryLight font-normal leading-[20px]",
|
|
10703
|
+
children: children
|
|
10704
|
+
});
|
|
10705
|
+
const $f4e9ebfd4b02cf09$var$Bold = ({ children: children })=>/*#__PURE__*/ (0, $3Sbms$jsx)("span", {
|
|
10706
|
+
className: "text-primary font-medium",
|
|
10707
|
+
children: children
|
|
10708
|
+
});
|
|
10709
|
+
const $f4e9ebfd4b02cf09$var$InstructionRow = ({ children: children , index: index })=>/*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
10710
|
+
className: "flex flex-row justify-center gap-[5px]",
|
|
10711
|
+
children: [
|
|
10712
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
10713
|
+
className: "flex items-center justify-center min-w-[24px] h-[24px] rounded-[50%] bg-secondaryVLight",
|
|
10714
|
+
children: index
|
|
10715
|
+
}),
|
|
10716
|
+
children
|
|
10717
|
+
]
|
|
10718
|
+
});
|
|
10719
|
+
const $f4e9ebfd4b02cf09$export$788cb893d96254c8 = ({ state: state , type: type })=>{
|
|
10720
|
+
const [permissionsState, setPermissionsState] = (0, $3Sbms$useState)("idle");
|
|
10721
|
+
const { orientation: orientation } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
10722
|
+
const device = orientation === "landscape" ? "desktop" : "mobile";
|
|
10723
|
+
const videoLength = permissionsState === "granted" ? "short" : "full";
|
|
10724
|
+
const videoType = type === "picture" ? "photo" : "video";
|
|
10725
|
+
const onDeviceEnabled = ()=>setPermissionsState("granted");
|
|
10726
|
+
const ref = (0, $3Sbms$useRef)(null);
|
|
10727
|
+
const title = (0, $3Sbms$useMemo)(()=>{
|
|
10728
|
+
if (permissionsState === "refused") return "Something went wrong!";
|
|
10729
|
+
if (type === "picture") return "Ready to take a shot?";
|
|
10730
|
+
return "Ready to record a video?";
|
|
10731
|
+
}, [
|
|
10732
|
+
permissionsState,
|
|
10733
|
+
type
|
|
10734
|
+
]);
|
|
10735
|
+
(0, $3Sbms$useEffect)(()=>{
|
|
10736
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).addEventListener("localVideoAvailable", onDeviceEnabled);
|
|
10737
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).addEventListener("microphoneEnabled", onDeviceEnabled);
|
|
10738
|
+
return ()=>{
|
|
10739
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).removeEventListener("localVideoAvailable", onDeviceEnabled);
|
|
10740
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).removeEventListener("microphoneEnabled", onDeviceEnabled);
|
|
10741
|
+
};
|
|
10742
|
+
}, []);
|
|
10743
|
+
const permissionsInstructionIndex = Number(permissionsState !== "granted");
|
|
10744
|
+
return /*#__PURE__*/ (0, $3Sbms$jsx)((0, $c0bb66c3d546ed81$export$2b77a92f1a5ad772), {
|
|
10745
|
+
title: title,
|
|
10746
|
+
state: state,
|
|
10747
|
+
centered: permissionsState !== "refused",
|
|
10748
|
+
isDismissable: false,
|
|
10749
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
10750
|
+
className: "flex flex-col gap-[20px]",
|
|
10751
|
+
children: [
|
|
10752
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
10753
|
+
className: "flex flex-col gap-[10px]",
|
|
10754
|
+
ref: ref,
|
|
10755
|
+
children: permissionsState === "refused" ? /*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$Text, {
|
|
10756
|
+
children: "Without camera and microphone access, you can't take photos or videos to share with the support team. Please grant access in your browser settings."
|
|
10757
|
+
}) : /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $3Sbms$Fragment), {
|
|
10758
|
+
children: [
|
|
10759
|
+
permissionsState !== "granted" && /*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$InstructionRow, {
|
|
10760
|
+
index: 1,
|
|
10761
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)($f4e9ebfd4b02cf09$var$Text, {
|
|
10762
|
+
children: [
|
|
10763
|
+
"When prompted, ",
|
|
10764
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$Bold, {
|
|
10765
|
+
children: "allow access"
|
|
10766
|
+
}),
|
|
10767
|
+
" to camera and microphone."
|
|
10768
|
+
]
|
|
10769
|
+
})
|
|
10770
|
+
}),
|
|
10771
|
+
type === "picture" && /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $3Sbms$Fragment), {
|
|
10772
|
+
children: [
|
|
10773
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$InstructionRow, {
|
|
10774
|
+
index: 1 + permissionsInstructionIndex,
|
|
10775
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)($f4e9ebfd4b02cf09$var$Text, {
|
|
10776
|
+
children: [
|
|
10777
|
+
"Tap the ",
|
|
10778
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $444e1dd9fa8f6883$export$dce36e07153365d), {}),
|
|
10779
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$Bold, {
|
|
10780
|
+
children: " Camera button"
|
|
10781
|
+
}),
|
|
10782
|
+
" to take a photo."
|
|
10783
|
+
]
|
|
10784
|
+
})
|
|
10785
|
+
}),
|
|
10786
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$InstructionRow, {
|
|
10787
|
+
index: 2 + permissionsInstructionIndex,
|
|
10788
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$Text, {
|
|
10789
|
+
children: "Don't hesitate to take multiple photos for more detail."
|
|
10790
|
+
})
|
|
10791
|
+
}),
|
|
10792
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$InstructionRow, {
|
|
10793
|
+
index: 3 + permissionsInstructionIndex,
|
|
10794
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)($f4e9ebfd4b02cf09$var$Text, {
|
|
10795
|
+
children: [
|
|
10796
|
+
"You can review your photo and then ",
|
|
10797
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$Bold, {
|
|
10798
|
+
children: "send it when you're done."
|
|
10799
|
+
})
|
|
10800
|
+
]
|
|
10801
|
+
})
|
|
10802
|
+
})
|
|
10803
|
+
]
|
|
10804
|
+
}),
|
|
10805
|
+
type === "video" && /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $3Sbms$Fragment), {
|
|
10806
|
+
children: [
|
|
10807
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$InstructionRow, {
|
|
10808
|
+
index: 1 + permissionsInstructionIndex,
|
|
10809
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)($f4e9ebfd4b02cf09$var$Text, {
|
|
10810
|
+
children: [
|
|
10811
|
+
"Tap the ",
|
|
10812
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $444e1dd9fa8f6883$export$f9da3144ae2525a3), {}),
|
|
10813
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$Bold, {
|
|
10814
|
+
children: " Record button"
|
|
10815
|
+
}),
|
|
10816
|
+
" to start a recording."
|
|
10817
|
+
]
|
|
10818
|
+
})
|
|
10819
|
+
}),
|
|
10820
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$InstructionRow, {
|
|
10821
|
+
index: 2 + permissionsInstructionIndex,
|
|
10822
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)($f4e9ebfd4b02cf09$var$Text, {
|
|
10823
|
+
children: [
|
|
10824
|
+
"You can ",
|
|
10825
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$Bold, {
|
|
10826
|
+
children: "speak during"
|
|
10827
|
+
}),
|
|
10828
|
+
" the recording for added detail."
|
|
10829
|
+
]
|
|
10830
|
+
})
|
|
10831
|
+
}),
|
|
10832
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$InstructionRow, {
|
|
10833
|
+
index: 3 + permissionsInstructionIndex,
|
|
10834
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)($f4e9ebfd4b02cf09$var$Text, {
|
|
10835
|
+
children: [
|
|
10836
|
+
"When you're finished, tap the ",
|
|
10837
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $444e1dd9fa8f6883$export$c6a849fd9d9d93a2), {}),
|
|
10838
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$Bold, {
|
|
10839
|
+
children: " Stop button"
|
|
10840
|
+
}),
|
|
10841
|
+
"."
|
|
10842
|
+
]
|
|
10843
|
+
})
|
|
10844
|
+
}),
|
|
10845
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$InstructionRow, {
|
|
10846
|
+
index: 4 + permissionsInstructionIndex,
|
|
10847
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)($f4e9ebfd4b02cf09$var$Text, {
|
|
10848
|
+
children: [
|
|
10849
|
+
"You can review your video and then ",
|
|
10850
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)($f4e9ebfd4b02cf09$var$Bold, {
|
|
10851
|
+
children: "send it when you're done"
|
|
10852
|
+
}),
|
|
10853
|
+
"."
|
|
10854
|
+
]
|
|
10855
|
+
})
|
|
10856
|
+
})
|
|
10857
|
+
]
|
|
10858
|
+
})
|
|
10859
|
+
]
|
|
10860
|
+
})
|
|
10861
|
+
}),
|
|
10862
|
+
permissionsState !== "refused" && /*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
10863
|
+
className: "flex items-center justify-center rounded-[8px] overflow-hidden",
|
|
10864
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("video", {
|
|
10865
|
+
src: `${"https://stream-assets.snapcall.io"}/animations/${device}-assist-onboarding-${videoType}-${videoLength}.mp4`,
|
|
10866
|
+
playsInline: true,
|
|
10867
|
+
autoPlay: true,
|
|
10868
|
+
muted: true,
|
|
10869
|
+
loop: true
|
|
10870
|
+
})
|
|
10871
|
+
}),
|
|
10872
|
+
permissionsState === "refused" ? /*#__PURE__*/ (0, $3Sbms$jsx)((0, $0590ee3141e14968$export$353f5b6fc5456de1), {
|
|
10873
|
+
onPress: ()=>window.location.reload(),
|
|
10874
|
+
children: "Allow access"
|
|
10875
|
+
}) : /*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$Fragment), {
|
|
10876
|
+
children: permissionsState === "granted" ? /*#__PURE__*/ (0, $3Sbms$jsx)((0, $0590ee3141e14968$export$353f5b6fc5456de1), {
|
|
10877
|
+
onPress: state.close,
|
|
10878
|
+
children: "Okay"
|
|
10879
|
+
}) : /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $0590ee3141e14968$export$353f5b6fc5456de1), {
|
|
10880
|
+
isDisabled: permissionsState === "requesting",
|
|
10881
|
+
onPress: async ()=>{
|
|
10882
|
+
setPermissionsState("requesting");
|
|
10883
|
+
try {
|
|
10884
|
+
const mediaResult = await navigator.mediaDevices.getUserMedia({
|
|
10885
|
+
audio: true,
|
|
10886
|
+
video: true
|
|
10887
|
+
});
|
|
10888
|
+
mediaResult.getTracks().forEach((track)=>track.stop());
|
|
10889
|
+
await (0, $c9e496369b59be7a$export$2f377c2162fd02b2).enableMicrophone();
|
|
10890
|
+
await (0, $c9e496369b59be7a$export$2f377c2162fd02b2).enableVideo({
|
|
10891
|
+
resolution: "vga",
|
|
10892
|
+
frameRate: 20,
|
|
10893
|
+
facingMode: "environment"
|
|
10894
|
+
});
|
|
10895
|
+
} catch {
|
|
10896
|
+
setPermissionsState("refused");
|
|
10897
|
+
}
|
|
10898
|
+
},
|
|
10899
|
+
children: [
|
|
10900
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $910dd7d7d872a463$export$2e2bcd8739ae039), {}),
|
|
10901
|
+
"Allow access to cam/mic"
|
|
10902
|
+
]
|
|
10903
|
+
})
|
|
10904
|
+
})
|
|
10905
|
+
]
|
|
10906
|
+
})
|
|
10907
|
+
});
|
|
10908
|
+
};
|
|
10909
|
+
|
|
10910
|
+
|
|
10911
|
+
function $a94f21ef9007b90a$export$bd7b6af6aa16550c({ photo: photo = true }) {
|
|
10912
|
+
const [isPhoto, setPhoto] = (0, $3Sbms$useState)(photo);
|
|
10913
|
+
const [streaming, setStreaming] = (0, $3Sbms$useState)(false);
|
|
10914
|
+
return {
|
|
10915
|
+
photo: isPhoto,
|
|
10916
|
+
setPhoto: setPhoto,
|
|
10917
|
+
streaming: streaming,
|
|
10918
|
+
setStreaming: setStreaming
|
|
10919
|
+
};
|
|
10920
|
+
}
|
|
10921
|
+
const $a94f21ef9007b90a$export$11a6fe490bbc4873 = (props)=>{
|
|
10922
|
+
const [isPhotoInstructionsModalOpen, setIsPhotoInstructionsModalOpen] = (0, $3Sbms$useState)(props.state.photo);
|
|
10923
|
+
const [isVideoInstructionsModalOpen, setIsVideoInstructionsModalOpen] = (0, $3Sbms$useState)(!props.state.photo);
|
|
10924
|
+
const photoInstructionsModalState = (0, $3Sbms$useOverlayTriggerState)({
|
|
10925
|
+
isOpen: isPhotoInstructionsModalOpen,
|
|
10926
|
+
onOpenChange: setIsPhotoInstructionsModalOpen
|
|
10927
|
+
});
|
|
10928
|
+
const videoInstructionsModalState = (0, $3Sbms$useOverlayTriggerState)({
|
|
10929
|
+
isOpen: isVideoInstructionsModalOpen,
|
|
10930
|
+
onOpenChange: setIsVideoInstructionsModalOpen
|
|
10931
|
+
});
|
|
10932
|
+
return /*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
10933
|
+
className: "flex flex-col bg-primary h-[150px] w-full max-w-[400px] rounded-[15px] p-2.5 gap-2.5",
|
|
10934
|
+
children: [
|
|
10935
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $f4e9ebfd4b02cf09$export$788cb893d96254c8), {
|
|
10936
|
+
state: photoInstructionsModalState,
|
|
10937
|
+
type: "picture"
|
|
10938
|
+
}),
|
|
10939
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $f4e9ebfd4b02cf09$export$788cb893d96254c8), {
|
|
10940
|
+
state: videoInstructionsModalState,
|
|
10941
|
+
type: "video"
|
|
10942
|
+
}),
|
|
10943
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
10944
|
+
className: "flex flex-1 flex-row px-[10px] w-full",
|
|
10945
|
+
children: [
|
|
10946
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
10947
|
+
className: "flex flex-row flex-auto items-center gap-[10px]",
|
|
10948
|
+
children: [
|
|
10949
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $a1ac29d50bdaa837$export$3741e4ac43f04ca2), {}),
|
|
10950
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
10951
|
+
className: " text-white text-base font-medium",
|
|
10952
|
+
children: "SnapCall"
|
|
10953
|
+
})
|
|
10954
|
+
]
|
|
10955
|
+
}),
|
|
10956
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
10957
|
+
className: "flex flex-row justify-end flex-auto items-center gap-[10px] ",
|
|
10958
|
+
children: [
|
|
10959
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $5a48b7481979330f$export$d2b052e7b4be1756), {
|
|
10960
|
+
onPress: ()=>{
|
|
10961
|
+
if (!props.state.streaming) {
|
|
10962
|
+
props.state.setPhoto(true);
|
|
10963
|
+
photoInstructionsModalState.open();
|
|
10964
|
+
}
|
|
10965
|
+
},
|
|
10966
|
+
isSelected: props.state.photo,
|
|
10967
|
+
children: "Photo"
|
|
10968
|
+
}),
|
|
10969
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $5a48b7481979330f$export$d2b052e7b4be1756), {
|
|
10970
|
+
onPress: ()=>{
|
|
10971
|
+
if (!props.state.streaming) {
|
|
10972
|
+
props.state.setPhoto(false);
|
|
10973
|
+
videoInstructionsModalState.open();
|
|
10974
|
+
}
|
|
10975
|
+
},
|
|
10976
|
+
isSelected: !props.state.photo,
|
|
10977
|
+
children: "Video"
|
|
10978
|
+
})
|
|
10979
|
+
]
|
|
10980
|
+
})
|
|
10981
|
+
]
|
|
10982
|
+
}),
|
|
10983
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
10984
|
+
className: "flex flex-row flex-1 items-center justify-between w-full ",
|
|
10985
|
+
children: [
|
|
10986
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
10987
|
+
className: "w-[60px] h-[60px]",
|
|
10988
|
+
children: props.thumbnail
|
|
10989
|
+
}),
|
|
10990
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
10991
|
+
className: "bg-white rounded-full w-[72px] h-[72px] p-[3px]",
|
|
10992
|
+
onClick: ()=>props.onCapturePress(),
|
|
10993
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
10994
|
+
className: "bg-primary rounded-full w-full h-full p-[3px] flex items-center justify-center cursor-pointer",
|
|
10995
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
10996
|
+
className: (0, $3Sbms$classnames)("w-full h-full transition-[transform,border-radius] duration-300", props.state.photo ? "bg-white" : "bg-[#f12828]", props.state.streaming ? "rounded-[5px] scale-[0.4]" : "rounded-[60px]")
|
|
10997
|
+
})
|
|
10998
|
+
})
|
|
10999
|
+
}),
|
|
11000
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11001
|
+
onClick: props.onSwitch,
|
|
11002
|
+
className: "bg-[#565656] rounded-full w-[56px] h-[56px] flex items-center justify-center cursor-pointer",
|
|
11003
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $58d405d56c1abe95$export$aefffb14595958fe), {})
|
|
11004
|
+
})
|
|
11005
|
+
]
|
|
11006
|
+
})
|
|
11007
|
+
]
|
|
11008
|
+
});
|
|
11009
|
+
};
|
|
11010
|
+
|
|
11011
|
+
|
|
11012
|
+
|
|
11013
|
+
|
|
11014
|
+
|
|
11015
|
+
|
|
11016
|
+
|
|
11017
|
+
|
|
11018
|
+
|
|
11019
|
+
|
|
11020
|
+
|
|
11021
|
+
|
|
11022
|
+
|
|
11023
|
+
function $38cdd553fb158eaa$export$4589ed81930b555c(props) {
|
|
11024
|
+
const { children: children , state: state } = props;
|
|
11025
|
+
const ref = (0, $3Sbms$react).useRef(null);
|
|
11026
|
+
const { orientation: orientation } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
11027
|
+
const { modalProps: modalProps , underlayProps: underlayProps } = (0, $3Sbms$useModalOverlay)(props, state, ref);
|
|
11028
|
+
const [exited, setExited] = (0, $3Sbms$useState)(!state.isOpen);
|
|
11029
|
+
const viewport = (0, $3Sbms$useViewportSize)();
|
|
11030
|
+
const maxHeight = viewport.height - 64;
|
|
11031
|
+
const desktop = orientation === "landscape";
|
|
11032
|
+
// Don't render anything if the modal is not open and we're not animating out.
|
|
11033
|
+
if (!(state.isOpen || !exited)) return null;
|
|
11034
|
+
return /*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$Overlay), {
|
|
11035
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$CSSTransition), {
|
|
11036
|
+
in: state.isOpen,
|
|
11037
|
+
appear: true,
|
|
11038
|
+
onEntered: ()=>setExited(false),
|
|
11039
|
+
onExited: ()=>setExited(true),
|
|
11040
|
+
timeout: {
|
|
11041
|
+
enter: 0,
|
|
11042
|
+
exit: 300
|
|
11043
|
+
},
|
|
11044
|
+
classNames: {
|
|
11045
|
+
enter: "opacity-0",
|
|
11046
|
+
enterDone: "opacity-1 transition ease-in",
|
|
11047
|
+
exit: "opacity-0 transition ease-out"
|
|
11048
|
+
},
|
|
11049
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11050
|
+
className: (0, $3Sbms$classnames)("fixed z-[100] inset-0 bg-underlay flex justify-center", desktop ? "items-center" : "items-end"),
|
|
11051
|
+
...underlayProps,
|
|
11052
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$CSSTransition), {
|
|
11053
|
+
in: state.isOpen,
|
|
11054
|
+
appear: true,
|
|
11055
|
+
nodeRef: ref,
|
|
11056
|
+
timeout: {
|
|
11057
|
+
enter: 0,
|
|
11058
|
+
exit: 300
|
|
11059
|
+
},
|
|
11060
|
+
classNames: {
|
|
11061
|
+
appear: desktop ? "translate-y-[200%]" : "translate-y-full",
|
|
11062
|
+
appearDone: "translate-y-0 transition duration-300 ease-out",
|
|
11063
|
+
exit: (0, $3Sbms$classnames)("transition ease-out", desktop ? "translate-y-[200%]" : "translate-y-full")
|
|
11064
|
+
},
|
|
11065
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11066
|
+
...modalProps,
|
|
11067
|
+
ref: ref,
|
|
11068
|
+
className: (0, $3Sbms$classnames)("bg-white z-[1] overflow-auto focus:outline-none", desktop ? "translate-y-[200%] rounded-[15px]" : "translate-y-full rounded-t-[15px]"),
|
|
11069
|
+
style: {
|
|
11070
|
+
maxHeight: `${maxHeight}px`
|
|
11071
|
+
},
|
|
11072
|
+
children: children
|
|
11073
|
+
})
|
|
11074
|
+
})
|
|
11075
|
+
})
|
|
11076
|
+
})
|
|
11077
|
+
});
|
|
11078
|
+
}
|
|
11079
|
+
|
|
11080
|
+
|
|
11081
|
+
|
|
11082
|
+
|
|
11083
|
+
|
|
11084
|
+
|
|
11085
|
+
|
|
11086
|
+
|
|
11087
|
+
|
|
11088
|
+
|
|
11089
|
+
|
|
11090
|
+
const $4425c0dfad3f82bb$export$480db61f4dcd7727 = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
11091
|
+
width: "12",
|
|
11092
|
+
height: "15",
|
|
11093
|
+
viewBox: "0 0 12 15",
|
|
11094
|
+
fill: "none",
|
|
11095
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
11096
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
11097
|
+
d: "M11.103 5.747 2.677.272A1.614 1.614 0 0 0 1.773 0a1.62 1.62 0 0 0-.9.288 1.886 1.886 0 0 0-.64.733A2.235 2.235 0 0 0 0 2.025v10.95c0 .352.08.699.233 1.004.154.305.375.558.64.733.273.186.584.285.9.288.317.003.63-.091.904-.272l8.426-5.475c.272-.173.498-.427.656-.736.158-.308.241-.66.241-1.017a2.24 2.24 0 0 0-.24-1.017 1.884 1.884 0 0 0-.657-.736Z",
|
|
11098
|
+
fill: "#fff"
|
|
11099
|
+
})
|
|
11100
|
+
});
|
|
11101
|
+
|
|
11102
|
+
|
|
11103
|
+
const $c7542aa0d9bb5f39$export$1cd1efc78cb52ca5 = ({ asset: asset , onClick: onClick })=>{
|
|
11104
|
+
if (!asset) return null;
|
|
11105
|
+
return /*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
11106
|
+
className: "flex items-center justify-center w-[60px] h-[60px] rounded-[8px] cursor-pointer bg-white relative overflow-hidden",
|
|
11107
|
+
onClick: onClick,
|
|
11108
|
+
children: [
|
|
11109
|
+
asset?.type === "picture" && /*#__PURE__*/ (0, $3Sbms$jsx)("img", {
|
|
11110
|
+
className: "cursor-pointer bg-white",
|
|
11111
|
+
src: asset.objectUrl,
|
|
11112
|
+
alt: "last shot"
|
|
11113
|
+
}),
|
|
11114
|
+
asset?.type === "video" && /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $3Sbms$Fragment), {
|
|
11115
|
+
children: [
|
|
11116
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("video", {
|
|
11117
|
+
src: asset.objectUrl,
|
|
11118
|
+
className: "min-w-[100%] min-h-[100%] object-cover"
|
|
11119
|
+
}),
|
|
11120
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11121
|
+
className: "absolute left-0 top-0 flex items-center justify-center w-[60px] h-[60px] bg-primary opacity-50",
|
|
11122
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $4425c0dfad3f82bb$export$480db61f4dcd7727), {})
|
|
11123
|
+
})
|
|
11124
|
+
]
|
|
11125
|
+
})
|
|
11126
|
+
]
|
|
11127
|
+
});
|
|
11128
|
+
};
|
|
11129
|
+
|
|
11130
|
+
|
|
11131
|
+
|
|
11132
|
+
|
|
11133
|
+
const $a879d6bc7f43b0c5$export$28e1ba20e0688eb7 = ()=>/*#__PURE__*/ (0, $3Sbms$jsx)("svg", {
|
|
11134
|
+
width: "18",
|
|
11135
|
+
height: "19",
|
|
11136
|
+
viewBox: "0 0 18 19",
|
|
11137
|
+
fill: "none",
|
|
11138
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
11139
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("path", {
|
|
11140
|
+
d: "M7.5 14a.75.75 0 0 0 .75-.75v-4.5a.75.75 0 0 0-1.5 0v4.5a.75.75 0 0 0 .75.75ZM15 5h-3v-.75A2.25 2.25 0 0 0 9.75 2h-1.5A2.25 2.25 0 0 0 6 4.25V5H3a.75.75 0 0 0 0 1.5h.75v8.25A2.25 2.25 0 0 0 6 17h6a2.25 2.25 0 0 0 2.25-2.25V6.5H15A.75.75 0 1 0 15 5Zm-7.5-.75a.75.75 0 0 1 .75-.75h1.5a.75.75 0 0 1 .75.75V5h-3v-.75Zm5.25 10.5a.75.75 0 0 1-.75.75H6a.75.75 0 0 1-.75-.75V6.5h7.5v8.25ZM10.5 14a.75.75 0 0 0 .75-.75v-4.5a.75.75 0 1 0-1.5 0v4.5a.75.75 0 0 0 .75.75Z",
|
|
11141
|
+
fill: "#fff"
|
|
11142
|
+
})
|
|
11143
|
+
});
|
|
11144
|
+
|
|
11145
|
+
|
|
11146
|
+
const $77fb06ba253d6f7c$var$dateFormat = new Intl.DateTimeFormat("default", {
|
|
11147
|
+
dateStyle: "short"
|
|
11148
|
+
});
|
|
11149
|
+
const $77fb06ba253d6f7c$var$timeFormat = new Intl.DateTimeFormat("default", {
|
|
11150
|
+
hour: "numeric",
|
|
11151
|
+
minute: "2-digit"
|
|
11152
|
+
});
|
|
11153
|
+
function $77fb06ba253d6f7c$var$formatDate(date) {
|
|
11154
|
+
const ampm = date.getHours() % 12 >= 12 ? "PM" : "AM";
|
|
11155
|
+
return `${$77fb06ba253d6f7c$var$dateFormat.format(date)} at ${$77fb06ba253d6f7c$var$timeFormat.format(date)} ${ampm}`;
|
|
11156
|
+
}
|
|
11157
|
+
const $77fb06ba253d6f7c$export$c9169049516d8bcf = ({ asset: asset , index: index , removeAsset: removeAsset })=>{
|
|
11158
|
+
const confirmRemovalModalState = (0, $3Sbms$useOverlayTriggerState)({});
|
|
11159
|
+
return /*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
11160
|
+
className: "flex flex-row justify-between items-center",
|
|
11161
|
+
children: [
|
|
11162
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $c0bb66c3d546ed81$export$2b77a92f1a5ad772), {
|
|
11163
|
+
title: "Confirm removal",
|
|
11164
|
+
state: confirmRemovalModalState,
|
|
11165
|
+
description: "Are you sure you want to remove this photo/video? This action cannot be undone.",
|
|
11166
|
+
primaryAction: ({ close: close })=>/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $0590ee3141e14968$export$353f5b6fc5456de1), {
|
|
11167
|
+
onPress: async ()=>{
|
|
11168
|
+
await removeAsset(asset);
|
|
11169
|
+
close();
|
|
11170
|
+
},
|
|
11171
|
+
children: [
|
|
11172
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $a879d6bc7f43b0c5$export$28e1ba20e0688eb7), {}),
|
|
11173
|
+
"Confirm"
|
|
11174
|
+
]
|
|
11175
|
+
}),
|
|
11176
|
+
secondaryAction: "Cancel"
|
|
11177
|
+
}),
|
|
11178
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
11179
|
+
className: "flex flex-row gap-[10px] items-center",
|
|
11180
|
+
children: [
|
|
11181
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $c7542aa0d9bb5f39$export$1cd1efc78cb52ca5), {
|
|
11182
|
+
asset: asset
|
|
11183
|
+
}),
|
|
11184
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("span", {
|
|
11185
|
+
className: "text-sm",
|
|
11186
|
+
style: {
|
|
11187
|
+
hyphens: "manual"
|
|
11188
|
+
},
|
|
11189
|
+
children: [
|
|
11190
|
+
asset.type === "picture" ? "Photo" : "Video",
|
|
11191
|
+
" ",
|
|
11192
|
+
index + 1,
|
|
11193
|
+
" \xb7",
|
|
11194
|
+
" ",
|
|
11195
|
+
$77fb06ba253d6f7c$var$formatDate(new Date(asset.timestamp))
|
|
11196
|
+
]
|
|
11197
|
+
})
|
|
11198
|
+
]
|
|
11199
|
+
}),
|
|
11200
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("span", {
|
|
11201
|
+
className: "text-xs font-bold underline cursor-pointer ml-[10px]",
|
|
11202
|
+
onClick: confirmRemovalModalState.open,
|
|
11203
|
+
children: "Remove"
|
|
11204
|
+
})
|
|
11205
|
+
]
|
|
11206
|
+
}, asset.assetId);
|
|
11207
|
+
};
|
|
11208
|
+
|
|
11209
|
+
|
|
11210
|
+
|
|
11211
|
+
|
|
11212
|
+
const $7436fc0a14c16764$export$4fa52f68b1c78fbf = ()=>/*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
11213
|
+
className: "w-screen max-w-[400px] h-[235px] px-[20px] py-[25px] gap-[10px]",
|
|
11214
|
+
children: [
|
|
11215
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11216
|
+
className: "w-[360px] h-[93px]",
|
|
11217
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $3Sbms$reactcontentloader), {
|
|
11218
|
+
width: 360,
|
|
11219
|
+
height: 93,
|
|
11220
|
+
foregroundColor: "#EBEBEB",
|
|
11221
|
+
children: [
|
|
11222
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("rect", {
|
|
11223
|
+
x: 0,
|
|
11224
|
+
y: 0,
|
|
11225
|
+
rx: 8,
|
|
11226
|
+
ry: 8,
|
|
11227
|
+
width: 230,
|
|
11228
|
+
height: 16
|
|
11229
|
+
}),
|
|
11230
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("rect", {
|
|
11231
|
+
x: 0,
|
|
11232
|
+
y: 33,
|
|
11233
|
+
rx: 8,
|
|
11234
|
+
ry: 8,
|
|
11235
|
+
width: 60,
|
|
11236
|
+
height: 60
|
|
11237
|
+
}),
|
|
11238
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("rect", {
|
|
11239
|
+
x: 70,
|
|
11240
|
+
y: 56,
|
|
11241
|
+
rx: 7,
|
|
11242
|
+
ry: 7,
|
|
11243
|
+
width: 180,
|
|
11244
|
+
height: 14
|
|
11245
|
+
})
|
|
11246
|
+
]
|
|
11247
|
+
})
|
|
11248
|
+
}),
|
|
11249
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11250
|
+
className: "flex items-center justify-center w-full h-[40px] rounded-[8px] border border-primaryLight mt-[10px]",
|
|
11251
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$reactcontentloader), {
|
|
11252
|
+
width: 120,
|
|
11253
|
+
height: 14,
|
|
11254
|
+
foregroundColor: "#EBEBEB",
|
|
11255
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("rect", {
|
|
11256
|
+
x: 0,
|
|
11257
|
+
y: 0,
|
|
11258
|
+
rx: 7,
|
|
11259
|
+
ry: 7,
|
|
11260
|
+
width: 120,
|
|
11261
|
+
height: 14
|
|
11262
|
+
})
|
|
11263
|
+
})
|
|
11264
|
+
}),
|
|
11265
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11266
|
+
className: "flex items-center justify-center w-full h-[40px] rounded-[8px] bg-primary mt-[10px]",
|
|
11267
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$reactcontentloader), {
|
|
11268
|
+
width: 120,
|
|
11269
|
+
height: 14,
|
|
11270
|
+
foregroundColor: "#EBEBEB",
|
|
11271
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("rect", {
|
|
11272
|
+
x: 0,
|
|
11273
|
+
y: 0,
|
|
11274
|
+
rx: 7,
|
|
11275
|
+
ry: 7,
|
|
11276
|
+
width: 120,
|
|
11277
|
+
height: 14
|
|
11278
|
+
})
|
|
11279
|
+
})
|
|
11280
|
+
})
|
|
11281
|
+
]
|
|
11282
|
+
});
|
|
11283
|
+
|
|
11284
|
+
|
|
11285
|
+
const $d4d374dc7955cc18$export$5c334f209b1aa661 = ({ assets: assets , state: state , onSendAssets: onSendAssets , removeAsset: removeAsset , loading: loading })=>{
|
|
11286
|
+
const ref = (0, $3Sbms$useRef)(null);
|
|
11287
|
+
const [assetKind, setAssetKind] = (0, $3Sbms$useState)(assets[assets.length - 1]?.type === "picture" ? "photo" : "video");
|
|
11288
|
+
const { orientation: orientation } = (0, $3Sbms$useContext)((0, $5f30d8bf4f04621e$export$2e2bcd8739ae039));
|
|
11289
|
+
const desktop = orientation === "landscape";
|
|
11290
|
+
(0, $3Sbms$useEffect)(()=>{
|
|
11291
|
+
if (assets.length < 1) return;
|
|
11292
|
+
setAssetKind(assets[assets.length - 1]?.type === "picture" ? "photo" : "video");
|
|
11293
|
+
}, [
|
|
11294
|
+
assets
|
|
11295
|
+
]);
|
|
11296
|
+
return /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $3Sbms$Fragment), {
|
|
11297
|
+
children: [
|
|
11298
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$CSSTransition), {
|
|
11299
|
+
in: state.isOpen,
|
|
11300
|
+
appear: true,
|
|
11301
|
+
timeout: {
|
|
11302
|
+
enter: 0,
|
|
11303
|
+
exit: 300
|
|
11304
|
+
},
|
|
11305
|
+
classNames: {
|
|
11306
|
+
enter: "opacity-0",
|
|
11307
|
+
enterDone: "opacity-90 transition ease-in",
|
|
11308
|
+
exit: "opacity-0 transition ease-out"
|
|
11309
|
+
},
|
|
11310
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11311
|
+
className: (0, $3Sbms$classnames)("fixed justify-center w-screen h-screen top-0 left-0 bg-black z-[1]", state.isOpen ? "flex" : "hidden"),
|
|
11312
|
+
children: loading && /*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
11313
|
+
className: (0, $3Sbms$classnames)("flex mt-[50px] h-fit opacity-1", desktop ? "flex-row items-center w-[400px]" : "flex-col items-center text-center w-[320px]"),
|
|
11314
|
+
children: [
|
|
11315
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11316
|
+
className: "w-[24px] h-[24px] m-[10px]",
|
|
11317
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $8b7bd174d29d9a1f$export$2e2bcd8739ae039), {})
|
|
11318
|
+
}),
|
|
11319
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("span", {
|
|
11320
|
+
className: "text-sm text-white",
|
|
11321
|
+
children: [
|
|
11322
|
+
"Please wait a moment while your ",
|
|
11323
|
+
loading,
|
|
11324
|
+
" is being processed...",
|
|
11325
|
+
loading === "video" ? " It may take up to 15 seconds for a video to be ready." : ""
|
|
11326
|
+
]
|
|
11327
|
+
})
|
|
11328
|
+
]
|
|
11329
|
+
})
|
|
11330
|
+
})
|
|
11331
|
+
}),
|
|
11332
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $38cdd553fb158eaa$export$4589ed81930b555c), {
|
|
11333
|
+
state: {
|
|
11334
|
+
...state,
|
|
11335
|
+
close: loading ? ()=>{} : state.close
|
|
11336
|
+
},
|
|
11337
|
+
children: loading ? /*#__PURE__*/ (0, $3Sbms$jsx)((0, $7436fc0a14c16764$export$4fa52f68b1c78fbf), {}) : /*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
11338
|
+
ref: ref,
|
|
11339
|
+
className: "flex flex-col w-screen max-w-[400px] text-primary",
|
|
11340
|
+
children: [
|
|
11341
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
11342
|
+
className: "flex flex-row justify-between p-[12px]",
|
|
11343
|
+
children: [
|
|
11344
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("h1", {
|
|
11345
|
+
className: "text-lg first-letter:capitalize",
|
|
11346
|
+
children: [
|
|
11347
|
+
assetKind,
|
|
11348
|
+
" successfully captured"
|
|
11349
|
+
]
|
|
11350
|
+
}),
|
|
11351
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11352
|
+
className: "flex justify-center items-center rounded-full bg-[#f3f3f3] h-[30px] w-[30px] cursor-pointer",
|
|
11353
|
+
onClick: state.close,
|
|
11354
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $57ab7b9a012d9acd$export$2e2bcd8739ae039), {
|
|
11355
|
+
color: "#565656"
|
|
11356
|
+
})
|
|
11357
|
+
})
|
|
11358
|
+
]
|
|
11359
|
+
}),
|
|
11360
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
11361
|
+
className: "flex flex-col px-[20px] pb-[25px] gap-[10px]",
|
|
11362
|
+
children: [
|
|
11363
|
+
assets.map((asset, index)=>/*#__PURE__*/ (0, $3Sbms$jsx)((0, $77fb06ba253d6f7c$export$c9169049516d8bcf), {
|
|
11364
|
+
asset: asset,
|
|
11365
|
+
index: index,
|
|
11366
|
+
removeAsset: removeAsset
|
|
11367
|
+
}, asset.assetId)),
|
|
11368
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $0590ee3141e14968$export$353f5b6fc5456de1), {
|
|
11369
|
+
variant: "secondary",
|
|
11370
|
+
onPress: state.close,
|
|
11371
|
+
children: [
|
|
11372
|
+
"Take new ",
|
|
11373
|
+
assetKind
|
|
11374
|
+
]
|
|
11375
|
+
}),
|
|
11376
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $0590ee3141e14968$export$353f5b6fc5456de1), {
|
|
11377
|
+
onPress: ()=>{
|
|
11378
|
+
onSendAssets();
|
|
11379
|
+
state.close();
|
|
11380
|
+
},
|
|
11381
|
+
children: [
|
|
11382
|
+
"Send ",
|
|
11383
|
+
assets.length > 1 ? `${assets.length} elements` : assetKind
|
|
11384
|
+
]
|
|
11385
|
+
})
|
|
11386
|
+
]
|
|
11387
|
+
})
|
|
11388
|
+
]
|
|
11389
|
+
})
|
|
11390
|
+
})
|
|
11391
|
+
]
|
|
11392
|
+
});
|
|
11393
|
+
};
|
|
11394
|
+
|
|
11395
|
+
|
|
11396
|
+
|
|
11397
|
+
|
|
11398
|
+
|
|
11399
|
+
|
|
11400
|
+
|
|
11401
|
+
const $db82628e5503d51b$export$53819c0e58f98d49 = (props)=>{
|
|
11402
|
+
const [countdown, setCountdown] = (0, $3Sbms$useState)(props.initialValue);
|
|
11403
|
+
(0, $3Sbms$useEffect)(()=>{
|
|
11404
|
+
if (countdown === undefined) return;
|
|
11405
|
+
const t = setTimeout(()=>{
|
|
11406
|
+
if (countdown === 1) props.onFinish();
|
|
11407
|
+
setCountdown(countdown - 1);
|
|
11408
|
+
}, 1000);
|
|
11409
|
+
return ()=>clearTimeout(t);
|
|
11410
|
+
}, [
|
|
11411
|
+
countdown,
|
|
11412
|
+
props
|
|
11413
|
+
]);
|
|
11414
|
+
return /*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11415
|
+
children: countdown
|
|
11416
|
+
});
|
|
11417
|
+
};
|
|
11418
|
+
|
|
11419
|
+
|
|
11420
|
+
const $92672d57809ea9d3$var$timerText = (delta)=>{
|
|
11421
|
+
const d = [
|
|
11422
|
+
Math.floor(delta / 60),
|
|
11423
|
+
Math.round(delta % 60)
|
|
11424
|
+
].map((n)=>`${n < 10 ? "0" : ""}${n}`);
|
|
11425
|
+
return d.join(":");
|
|
11426
|
+
};
|
|
11427
|
+
const $92672d57809ea9d3$export$336a011955157f9a = ()=>{
|
|
11428
|
+
const [startRecordTime, setStartRecordTime] = (0, $3Sbms$useState)(undefined);
|
|
11429
|
+
const [timer, setTimer] = (0, $3Sbms$useState)(0);
|
|
11430
|
+
const [countdownVisible, setCountdownVisible] = (0, $3Sbms$useState)(false);
|
|
11431
|
+
const videoElementRef = (0, $3Sbms$useRef)(null);
|
|
11432
|
+
const [assets, setAssets] = (0, $3Sbms$useState)([]);
|
|
11433
|
+
const [assetLoading, setAssetLoading] = (0, $3Sbms$useState)(null);
|
|
11434
|
+
const [isAssetsPopupStateOpen, setIsAssetsPopupStateOpen] = (0, $3Sbms$useState)(false);
|
|
11435
|
+
const assetsPopupState = (0, $3Sbms$useOverlayTriggerState)({
|
|
11436
|
+
isOpen: isAssetsPopupStateOpen,
|
|
11437
|
+
onOpenChange: setIsAssetsPopupStateOpen
|
|
11438
|
+
});
|
|
11439
|
+
const sendAssetsModalState = (0, $3Sbms$useOverlayTriggerState)({});
|
|
11440
|
+
const [flashAnimation, setFlashAnimation] = (0, $3Sbms$useState)(false);
|
|
11441
|
+
const menuBarState = (0, $a94f21ef9007b90a$export$bd7b6af6aa16550c)({});
|
|
11442
|
+
const exitStreaming = (0, $3Sbms$useCallback)(()=>{
|
|
11443
|
+
menuBarState.setStreaming(false);
|
|
11444
|
+
setStartRecordTime(undefined);
|
|
11445
|
+
setCountdownVisible(false);
|
|
11446
|
+
setTimer(0);
|
|
11447
|
+
}, [
|
|
11448
|
+
menuBarState
|
|
11449
|
+
]);
|
|
11450
|
+
const onLocalVideoChange = (event)=>{
|
|
11451
|
+
if (!event.detail?.camera?.device || !videoElementRef.current) return;
|
|
11452
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).requestLocalVideo(videoElementRef?.current);
|
|
11453
|
+
};
|
|
11454
|
+
const onStopRecord = (0, $3Sbms$useCallback)((event)=>{
|
|
11455
|
+
const { url: url , assetId: assetId } = event.detail;
|
|
11456
|
+
exitStreaming();
|
|
11457
|
+
setAssetLoading(null);
|
|
11458
|
+
setAssets([
|
|
11459
|
+
...assets,
|
|
11460
|
+
{
|
|
11461
|
+
type: "video",
|
|
11462
|
+
timestamp: Date.now(),
|
|
11463
|
+
objectUrl: url,
|
|
11464
|
+
assetId: assetId
|
|
11465
|
+
}
|
|
11466
|
+
]);
|
|
11467
|
+
}, [
|
|
11468
|
+
assets,
|
|
11469
|
+
exitStreaming
|
|
11470
|
+
]);
|
|
11471
|
+
const onPhotoCapture = async (videoElement)=>{
|
|
11472
|
+
const timestamp = Date.now();
|
|
11473
|
+
setAssetLoading("picture");
|
|
11474
|
+
const image = await (0, $c9e496369b59be7a$export$2f377c2162fd02b2).captureVideo(videoElement);
|
|
11475
|
+
const { url: url , assetId: assetId } = await (0, $c9e496369b59be7a$export$2f377c2162fd02b2).saveCapture(image);
|
|
11476
|
+
setAssetLoading(null);
|
|
11477
|
+
setAssets([
|
|
11478
|
+
...assets,
|
|
11479
|
+
{
|
|
11480
|
+
type: "picture",
|
|
11481
|
+
timestamp: timestamp,
|
|
11482
|
+
objectUrl: url,
|
|
11483
|
+
assetId: assetId
|
|
11484
|
+
}
|
|
11485
|
+
]);
|
|
11486
|
+
};
|
|
11487
|
+
const removeAsset = (0, $3Sbms$useCallback)(async (asset)=>{
|
|
11488
|
+
if (!asset.assetId) return;
|
|
11489
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).deleteCapture(asset.assetId);
|
|
11490
|
+
const newAssets = assets.filter((item)=>item.assetId !== asset.assetId);
|
|
11491
|
+
setAssets(newAssets);
|
|
11492
|
+
if (newAssets.length < 1) setIsAssetsPopupStateOpen(false);
|
|
11493
|
+
}, [
|
|
11494
|
+
assets
|
|
11495
|
+
]);
|
|
11496
|
+
(0, $3Sbms$useEffect)(()=>{
|
|
11497
|
+
if (startRecordTime === undefined) return;
|
|
11498
|
+
const interval = setInterval(()=>{
|
|
11499
|
+
const delta = (Date.now() - startRecordTime) / 1000;
|
|
11500
|
+
setTimer(delta);
|
|
11501
|
+
}, 1000);
|
|
11502
|
+
return ()=>clearInterval(interval);
|
|
11503
|
+
}, [
|
|
11504
|
+
startRecordTime
|
|
11505
|
+
]);
|
|
11506
|
+
(0, $3Sbms$useEffect)(()=>{
|
|
11507
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).addEventListener("localVideoAvailable", onLocalVideoChange);
|
|
11508
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).addEventListener("localVideoChange", onLocalVideoChange);
|
|
11509
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).addEventListener("recordStopped", onStopRecord);
|
|
11510
|
+
return ()=>{
|
|
11511
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).removeEventListener("localVideoChange", onLocalVideoChange);
|
|
11512
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).removeEventListener("localVideoAvailable", onLocalVideoChange);
|
|
11513
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).removeEventListener("recordStopped", onStopRecord);
|
|
11514
|
+
};
|
|
11515
|
+
}, [
|
|
11516
|
+
onStopRecord
|
|
11517
|
+
]);
|
|
11518
|
+
return /*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
11519
|
+
className: "bg-[#000] w-full h-full justify-center flex flex-col antialiased",
|
|
11520
|
+
children: [
|
|
11521
|
+
!menuBarState.photo && /*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11522
|
+
className: "text-base text-white text-center font-medium pt-2.5",
|
|
11523
|
+
children: $92672d57809ea9d3$var$timerText(timer)
|
|
11524
|
+
}),
|
|
11525
|
+
countdownVisible && /*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11526
|
+
className: "absolute z-50 top-0 bottom-[160px] left-0 right-0 text-[100px] flex items-center justify-center text-center text-white bg-[#000000] opacity-[0.6] ",
|
|
11527
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $db82628e5503d51b$export$53819c0e58f98d49), {
|
|
11528
|
+
initialValue: 3,
|
|
11529
|
+
onFinish: ()=>{
|
|
11530
|
+
setCountdownVisible(false);
|
|
11531
|
+
setStartRecordTime(Date.now());
|
|
11532
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).startRecord();
|
|
11533
|
+
}
|
|
11534
|
+
})
|
|
11535
|
+
}),
|
|
11536
|
+
/*#__PURE__*/ (0, $3Sbms$jsxs)("div", {
|
|
11537
|
+
className: "relative flex-1 min-h-0 px-2.5 pt-2.5",
|
|
11538
|
+
children: [
|
|
11539
|
+
flashAnimation && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $6efc75079651494a$export$2b501aee548bae06), {
|
|
11540
|
+
onAnimationEnd: ()=>{
|
|
11541
|
+
setFlashAnimation(false);
|
|
11542
|
+
assetsPopupState.open();
|
|
11543
|
+
}
|
|
11544
|
+
}),
|
|
11545
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("video", {
|
|
11546
|
+
autoPlay: true,
|
|
11547
|
+
muted: true,
|
|
11548
|
+
playsInline: true,
|
|
11549
|
+
ref: videoElementRef,
|
|
11550
|
+
className: "w-full h-full object-cover rounded-[10px]"
|
|
11551
|
+
})
|
|
11552
|
+
]
|
|
11553
|
+
}),
|
|
11554
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)("div", {
|
|
11555
|
+
className: "flex justify-center p-2.5",
|
|
11556
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $a94f21ef9007b90a$export$11a6fe490bbc4873), {
|
|
11557
|
+
state: menuBarState,
|
|
11558
|
+
thumbnail: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $c7542aa0d9bb5f39$export$1cd1efc78cb52ca5), {
|
|
11559
|
+
asset: assets[assets.length - 1],
|
|
11560
|
+
onClick: assetsPopupState.open
|
|
11561
|
+
}),
|
|
11562
|
+
onSwitch: ()=>{
|
|
11563
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).rotateVideo();
|
|
11564
|
+
},
|
|
11565
|
+
onCapturePress: ()=>{
|
|
11566
|
+
if (menuBarState.photo && videoElementRef.current) {
|
|
11567
|
+
onPhotoCapture(videoElementRef.current);
|
|
11568
|
+
setFlashAnimation(true);
|
|
11569
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).captureVideo(videoElementRef.current);
|
|
11570
|
+
}
|
|
11571
|
+
if (!menuBarState.photo && !menuBarState.streaming) {
|
|
11572
|
+
menuBarState.setStreaming(true);
|
|
11573
|
+
setTimer(0);
|
|
11574
|
+
setCountdownVisible(true);
|
|
11575
|
+
}
|
|
11576
|
+
if (!menuBarState.photo && menuBarState.streaming) {
|
|
11577
|
+
exitStreaming();
|
|
11578
|
+
if (startRecordTime) {
|
|
11579
|
+
(0, $c9e496369b59be7a$export$2f377c2162fd02b2).stopRecord();
|
|
11580
|
+
setAssetLoading("video");
|
|
11581
|
+
assetsPopupState.open();
|
|
11582
|
+
}
|
|
11583
|
+
}
|
|
11584
|
+
}
|
|
11585
|
+
})
|
|
11586
|
+
}),
|
|
11587
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $d4d374dc7955cc18$export$5c334f209b1aa661), {
|
|
11588
|
+
assets: assets,
|
|
11589
|
+
state: assetsPopupState,
|
|
11590
|
+
onSendAssets: sendAssetsModalState.open,
|
|
11591
|
+
removeAsset: removeAsset,
|
|
11592
|
+
loading: assetLoading
|
|
11593
|
+
}),
|
|
11594
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $c0bb66c3d546ed81$export$2b77a92f1a5ad772), {
|
|
11595
|
+
title: "Thank you for your submission!",
|
|
11596
|
+
state: sendAssetsModalState,
|
|
11597
|
+
children: /*#__PURE__*/ (0, $3Sbms$jsx)("span", {
|
|
11598
|
+
className: "text-base text-primaryLight",
|
|
11599
|
+
children: "Your photo/video has been successfully sent. We will review it and get back to you soon."
|
|
11600
|
+
})
|
|
11601
|
+
})
|
|
11602
|
+
]
|
|
11603
|
+
});
|
|
11604
|
+
};
|
|
11605
|
+
|
|
11606
|
+
|
|
11607
|
+
const $26ed036cbc17809a$var$currentTheme = (0, $52580db2e49cdd90$export$3bfd0d5209a8006a)();
|
|
11608
|
+
const $26ed036cbc17809a$var$currentLanguage = (0, $a3e657fb86ae23f3$export$604ba5624273df44)();
|
|
11609
|
+
let $26ed036cbc17809a$var$timestampCriticalError = -1;
|
|
11610
|
+
const $26ed036cbc17809a$var$StreamUI = ({ options: options })=>{
|
|
11611
|
+
const [selfPeerId, setSelfPeerId] = (0, $3Sbms$useState)(undefined);
|
|
11612
|
+
const streamUIContainerRef = (0, $3Sbms$useRef)(null);
|
|
11613
|
+
const videosContainerRef = (0, $3Sbms$useRef)(null);
|
|
11614
|
+
const remoteTilesContainerRef = (0, $3Sbms$useRef)(null);
|
|
11615
|
+
const [streamState, setStreamState] = (0, $3Sbms$useState)(options.recorder ? "recorder" : "streaming");
|
|
11616
|
+
const [isQuickConnectPopupVisible, setIsQuickConnectPopupVisible] = (0, $3Sbms$useState)(false);
|
|
11617
|
+
const [isSettingsMenuVisible, setIsSettingsMenuVisible] = (0, $3Sbms$useState)(false);
|
|
11618
|
+
const [isYoutubePopupVisible, setIsYoutubePopupVisible] = (0, $3Sbms$useState)(false);
|
|
11619
|
+
const [isLinksharePopupVisible, setIsLinksharePopupVisible] = (0, $3Sbms$useState)(false);
|
|
11620
|
+
const [isVirtualBackgroundPopupVisible, setIsVirtualBackgroundPopupVisible] = (0, $3Sbms$useState)(false);
|
|
11621
|
+
const [theme, setTheme] = (0, $3Sbms$useState)($26ed036cbc17809a$var$currentTheme);
|
|
11622
|
+
const [language, setLanguage] = (0, $3Sbms$useState)(options.language || $26ed036cbc17809a$var$currentLanguage);
|
|
11623
|
+
const [profile, setProfile] = (0, $3Sbms$useState)({});
|
|
11624
|
+
const [muted, setMuted] = (0, $3Sbms$useState)(true);
|
|
11625
|
+
const [streaming, setStreaming] = (0, $3Sbms$useState)(false);
|
|
11626
|
+
const [screensharing, setScreensharing] = (0, $3Sbms$useState)(false);
|
|
11627
|
+
const [isAgent, setIsAgent] = (0, $3Sbms$useState)(false);
|
|
11628
|
+
const [userInteractionTriggered, setUserInteractionTriggered] = (0, $3Sbms$useState)(false);
|
|
11629
|
+
const [containerWidth, containerHeight] = (0, $af23c74942bdcae7$export$2b86bedf890eab8)(streamUIContainerRef.current);
|
|
11630
|
+
const [isBlockedDevicesPopupOpen, setBlockedDevicesPopupOpen] = (0, $3Sbms$useState)(false);
|
|
11631
|
+
const [isBlockedFeaturePopupOpen, setBlockedFeaturePopupOpen] = (0, $3Sbms$useState)(false);
|
|
11632
|
+
const [permissions, setPermissions] = (0, $3Sbms$useState)([]);
|
|
11633
|
+
const [plan, setPlan] = (0, $3Sbms$useState)(undefined);
|
|
11634
|
+
const orientation = (containerWidth || window.screen.width) > (containerHeight || window.screen.height) ? "landscape" : "portrait";
|
|
11635
|
+
const styledTheme = theme === "dark" ? (0, $52580db2e49cdd90$export$3e936a8db52a10a0) : (0, $52580db2e49cdd90$export$f30cb9bc4f736419);
|
|
11636
|
+
const onWebcamUpdate = (event)=>{
|
|
11637
|
+
if (event.type === "localVideoAvailable") setStreaming(true);
|
|
11638
|
+
else setStreaming(false);
|
|
11639
|
+
};
|
|
11640
|
+
const onScreenshareUpdate = (event)=>{
|
|
11641
|
+
if (event.type === "screenshareEnabled") setScreensharing(true);
|
|
11642
|
+
else setScreensharing(false);
|
|
11643
|
+
};
|
|
11644
|
+
const onMicrophoneUpdate = (event)=>{
|
|
11645
|
+
if (event.type === "microphoneMute") setMuted(true);
|
|
11646
|
+
else setMuted(false);
|
|
11647
|
+
};
|
|
11648
|
+
const onDefaultAudioDeviceChange = (event)=>{
|
|
11649
|
+
const micro = event.detail.label;
|
|
11650
|
+
(0, $a5146f9062d7bf28$export$3a57e165650c636f)(`Connected to ${micro}`, {
|
|
11651
|
+
duration: 3000,
|
|
11652
|
+
icon: /*#__PURE__*/ (0, $3Sbms$jsx)((0, $6043ae1b48c5aa97$export$2e2bcd8739ae039), {}),
|
|
11653
|
+
messageStyle: {
|
|
11654
|
+
fontWeight: 600
|
|
11655
|
+
}
|
|
11656
|
+
});
|
|
11657
|
+
};
|
|
11658
|
+
const onSelfProfileUpdate = (event)=>{
|
|
11659
|
+
const { profile: profile } = event.detail;
|
|
11660
|
+
setProfile(profile);
|
|
11661
|
+
};
|
|
11662
|
+
const onCallEnd = ()=>{
|
|
11663
|
+
(0, $15a01b611391c1e7$export$716eeec86fd18da7)();
|
|
11664
|
+
setStreamState("ended");
|
|
11665
|
+
setMuted(true);
|
|
11666
|
+
setStreaming(false);
|
|
11667
|
+
setScreensharing(false);
|
|
11668
|
+
setUserInteractionTriggered(false);
|
|
11669
|
+
};
|
|
11670
|
+
const onCallTerminated = ()=>{
|
|
11671
|
+
(0, $15a01b611391c1e7$export$716eeec86fd18da7)();
|
|
11672
|
+
setStreamState("terminated");
|
|
11673
|
+
};
|
|
11674
|
+
const onInvalidRoom = ()=>{
|
|
11675
|
+
setStreamState("expired");
|
|
11676
|
+
};
|
|
11677
|
+
const onAgentIdentity = (event)=>{
|
|
11678
|
+
const { success: success , email: email } = event.detail;
|
|
11679
|
+
if (success) {
|
|
11680
|
+
setIsAgent(true);
|
|
11681
|
+
if (email) (0, $3Sbms$hotjarbrowser).identify(null, {
|
|
11682
|
+
email: email
|
|
11683
|
+
});
|
|
11684
|
+
} else (0, $3Sbms$reacthottoast)("An error occured while trying to join the room as an agent", {
|
|
11685
|
+
className: "error"
|
|
11686
|
+
});
|
|
11687
|
+
};
|
|
11688
|
+
const onCriticalError = (event)=>{
|
|
11689
|
+
const duration = 20000;
|
|
11690
|
+
const now = Date.now();
|
|
11691
|
+
if (event.detail.code === "USERLIMIT") {
|
|
11692
|
+
setStreamState("full");
|
|
11693
|
+
return;
|
|
11694
|
+
}
|
|
11695
|
+
if ($26ed036cbc17809a$var$timestampCriticalError !== -1 && $26ed036cbc17809a$var$timestampCriticalError + duration > now) return;
|
|
11696
|
+
$26ed036cbc17809a$var$timestampCriticalError = now;
|
|
11697
|
+
(0, $a5146f9062d7bf28$export$3a57e165650c636f)(`A critical error has occurred (error ${event.detail.code}).`, {
|
|
11698
|
+
icon: (0, $93a0377c243d965e$export$c7df1b15b59b1df2),
|
|
11699
|
+
button: {
|
|
11700
|
+
text: "Reload",
|
|
11701
|
+
action: ()=>{
|
|
11702
|
+
window.location.reload();
|
|
11703
|
+
}
|
|
11704
|
+
},
|
|
11705
|
+
duration: duration
|
|
11706
|
+
});
|
|
11707
|
+
};
|
|
11708
|
+
(0, $3Sbms$useEffect)(()=>{
|
|
11709
|
+
try {
|
|
11710
|
+
localStorage.setItem("stream_ui_theme", theme);
|
|
11711
|
+
} catch (localStorageError) {
|
|
11712
|
+
console.warn(localStorageError);
|
|
11713
|
+
}
|
|
11714
|
+
}, [
|
|
11715
|
+
theme
|
|
11716
|
+
]);
|
|
11717
|
+
(0, $3Sbms$useEffect)(()=>{
|
|
10359
11718
|
try {
|
|
10360
11719
|
localStorage.setItem("stream_ui_language", language);
|
|
10361
11720
|
(0, $384d985bb9605c35$export$2e2bcd8739ae039).changeLanguage(language);
|
|
@@ -10404,7 +11763,7 @@ const $26ed036cbc17809a$var$StreamUI = ({ options: options })=>{
|
|
|
10404
11763
|
setPermissions(event.detail.permissions);
|
|
10405
11764
|
console.log(event.detail.permissions);
|
|
10406
11765
|
setSelfPeerId(peerId);
|
|
10407
|
-
try {
|
|
11766
|
+
if (!options.recorder) try {
|
|
10408
11767
|
await (0, $15a01b611391c1e7$export$494039379563c94d)(options);
|
|
10409
11768
|
setUserInteractionTriggered(true);
|
|
10410
11769
|
} catch (userInteractionError) {
|
|
@@ -10446,7 +11805,7 @@ const $26ed036cbc17809a$var$StreamUI = ({ options: options })=>{
|
|
|
10446
11805
|
language: language,
|
|
10447
11806
|
setLanguage: setLanguage,
|
|
10448
11807
|
options: options,
|
|
10449
|
-
profile:
|
|
11808
|
+
profile: profile,
|
|
10450
11809
|
muted: muted,
|
|
10451
11810
|
streaming: streaming,
|
|
10452
11811
|
screensharing: screensharing,
|
|
@@ -10470,6 +11829,7 @@ const $26ed036cbc17809a$var$StreamUI = ({ options: options })=>{
|
|
|
10470
11829
|
setBlockedDevicesPopupOpen(false);
|
|
10471
11830
|
}
|
|
10472
11831
|
}),
|
|
11832
|
+
streamState === "recorder" && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $92672d57809ea9d3$export$336a011955157f9a), {}),
|
|
10473
11833
|
streamState === "streaming" && /*#__PURE__*/ (0, $3Sbms$jsx)((0, $3Sbms$Fragment), {
|
|
10474
11834
|
children: /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $cce9fd41d8a55a18$export$74636703cfe1eecf), {
|
|
10475
11835
|
children: [
|
|
@@ -10741,14 +12101,14 @@ const $f8d57e3d223f5089$var$GreetingView = ({ onGreetingDone: onGreetingDone })
|
|
|
10741
12101
|
const [mainContainerRef, { width: width , height: height }] = (0, $af23c74942bdcae7$export$e295b0c537d32d7d)();
|
|
10742
12102
|
const inputRef = (0, $3Sbms$useRef)(null);
|
|
10743
12103
|
const videoRef = (0, $3Sbms$useRef)(null);
|
|
10744
|
-
const [
|
|
12104
|
+
const [videoTrack, setVideoTrack] = (0, $3Sbms$useState)(undefined);
|
|
10745
12105
|
const [micEnabled, setMicEnabled] = (0, $3Sbms$useState)(false);
|
|
10746
12106
|
const [joining, setJoining] = (0, $3Sbms$useState)(false);
|
|
10747
12107
|
const desktop = width >= height;
|
|
10748
12108
|
const onSubmit = ()=>{
|
|
10749
12109
|
const displayName = inputRef.current?.value;
|
|
10750
|
-
const cameraEnabled = Boolean(
|
|
10751
|
-
|
|
12110
|
+
const cameraEnabled = Boolean(videoTrack);
|
|
12111
|
+
videoTrack?.stop();
|
|
10752
12112
|
setJoining(true);
|
|
10753
12113
|
setTimeout(()=>{
|
|
10754
12114
|
onGreetingDone({
|
|
@@ -10771,15 +12131,15 @@ const $f8d57e3d223f5089$var$GreetingView = ({ onGreetingDone: onGreetingDone })
|
|
|
10771
12131
|
}
|
|
10772
12132
|
};
|
|
10773
12133
|
const onCameraClick = (0, $3Sbms$useCallback)(async ()=>{
|
|
10774
|
-
if (!
|
|
12134
|
+
if (!videoTrack) await getUserMedia({
|
|
10775
12135
|
video: true
|
|
10776
12136
|
});
|
|
10777
12137
|
else {
|
|
10778
|
-
|
|
12138
|
+
videoTrack.stop();
|
|
10779
12139
|
setVideoTrack(undefined);
|
|
10780
12140
|
}
|
|
10781
12141
|
}, [
|
|
10782
|
-
|
|
12142
|
+
videoTrack
|
|
10783
12143
|
]);
|
|
10784
12144
|
const onMicrophoneClick = (0, $3Sbms$useCallback)(async ()=>{
|
|
10785
12145
|
if (!micEnabled) await getUserMedia({
|
|
@@ -10791,14 +12151,14 @@ const $f8d57e3d223f5089$var$GreetingView = ({ onGreetingDone: onGreetingDone })
|
|
|
10791
12151
|
]);
|
|
10792
12152
|
(0, $3Sbms$useEffect)(()=>{
|
|
10793
12153
|
if (videoRef.current) {
|
|
10794
|
-
if (
|
|
10795
|
-
|
|
12154
|
+
if (videoTrack) videoRef.current.srcObject = new MediaStream([
|
|
12155
|
+
videoTrack
|
|
10796
12156
|
]);
|
|
10797
12157
|
else videoRef.current.srcObject = null;
|
|
10798
12158
|
}
|
|
10799
12159
|
}, [
|
|
10800
12160
|
videoRef,
|
|
10801
|
-
|
|
12161
|
+
videoTrack,
|
|
10802
12162
|
width,
|
|
10803
12163
|
height
|
|
10804
12164
|
]);
|
|
@@ -10815,7 +12175,7 @@ const $f8d57e3d223f5089$var$GreetingView = ({ onGreetingDone: onGreetingDone })
|
|
|
10815
12175
|
height: 40
|
|
10816
12176
|
})
|
|
10817
12177
|
});
|
|
10818
|
-
const webcamEnabled = Boolean(
|
|
12178
|
+
const webcamEnabled = Boolean(videoTrack);
|
|
10819
12179
|
return /*#__PURE__*/ (0, $3Sbms$jsxs)((0, $35c6a4b506b7dc62$export$d653589df987fd93), {
|
|
10820
12180
|
ref: mainContainerRef,
|
|
10821
12181
|
children: [
|
|
@@ -10914,10 +12274,15 @@ const $f8d57e3d223f5089$var$GreetingView = ({ onGreetingDone: onGreetingDone })
|
|
|
10914
12274
|
var $f8d57e3d223f5089$export$2e2bcd8739ae039 = $f8d57e3d223f5089$var$GreetingView;
|
|
10915
12275
|
|
|
10916
12276
|
|
|
12277
|
+
var $1e2747ca72d0ab49$exports = {};
|
|
12278
|
+
$1e2747ca72d0ab49$exports = "*, :before, :after {\n box-sizing: border-box;\n border: 0 solid #e5e7eb;\n}\n\n:before, :after {\n --tw-content: \"\";\n}\n\nhtml {\n -webkit-text-size-adjust: 100%;\n tab-size: 4;\n font-feature-settings: normal;\n font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica Neue, Arial, Noto Sans, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol, Noto Color Emoji;\n line-height: 1.5;\n}\n\nbody {\n line-height: inherit;\n margin: 0;\n}\n\nhr {\n height: 0;\n color: inherit;\n border-top-width: 1px;\n}\n\nabbr:where([title]) {\n text-decoration: underline dotted;\n}\n\nh1, h2, h3, h4, h5, h6 {\n font-size: inherit;\n font-weight: inherit;\n}\n\na {\n color: inherit;\n text-decoration: inherit;\n}\n\nb, strong {\n font-weight: bolder;\n}\n\ncode, kbd, samp, pre {\n font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace;\n font-size: 1em;\n}\n\nsmall {\n font-size: 80%;\n}\n\nsub, sup {\n vertical-align: baseline;\n font-size: 75%;\n line-height: 0;\n position: relative;\n}\n\nsub {\n bottom: -.25em;\n}\n\nsup {\n top: -.5em;\n}\n\ntable {\n text-indent: 0;\n border-color: inherit;\n border-collapse: collapse;\n}\n\nbutton, input, optgroup, select, textarea {\n font-family: inherit;\n font-size: 100%;\n font-weight: inherit;\n line-height: inherit;\n color: inherit;\n margin: 0;\n padding: 0;\n}\n\nbutton, select {\n text-transform: none;\n}\n\nbutton, [type=\"button\"], [type=\"reset\"], [type=\"submit\"] {\n -webkit-appearance: button;\n background-color: #0000;\n background-image: none;\n}\n\n:-moz-focusring {\n outline: auto;\n}\n\n:-moz-ui-invalid {\n box-shadow: none;\n}\n\nprogress {\n vertical-align: baseline;\n}\n\n::-webkit-inner-spin-button, ::-webkit-outer-spin-button {\n height: auto;\n}\n\n[type=\"search\"] {\n -webkit-appearance: textfield;\n outline-offset: -2px;\n}\n\n::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n::-webkit-file-upload-button {\n -webkit-appearance: button;\n font: inherit;\n}\n\nsummary {\n display: list-item;\n}\n\nblockquote, dl, dd, h1, h2, h3, h4, h5, h6, hr, figure, p, pre {\n margin: 0;\n}\n\nfieldset {\n margin: 0;\n padding: 0;\n}\n\nlegend {\n padding: 0;\n}\n\nol, ul, menu {\n margin: 0;\n padding: 0;\n list-style: none;\n}\n\ntextarea {\n resize: vertical;\n}\n\ninput::placeholder, textarea::placeholder {\n opacity: 1;\n color: #9ca3af;\n}\n\nbutton, [role=\"button\"] {\n cursor: pointer;\n}\n\n:disabled {\n cursor: default;\n}\n\nimg, svg, video, canvas, audio, iframe, embed, object {\n vertical-align: middle;\n display: block;\n}\n\nimg, video {\n max-width: 100%;\n height: auto;\n}\n\n[hidden] {\n display: none;\n}\n\n*, :before, :after, ::backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: #3b82f680;\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n.visible {\n visibility: visible;\n}\n\n.fixed {\n position: fixed;\n}\n\n.absolute {\n position: absolute;\n}\n\n.relative {\n position: relative;\n}\n\n.inset-0 {\n inset: 0;\n}\n\n.top-0 {\n top: 0;\n}\n\n.bottom-\\[160px\\] {\n bottom: 160px;\n}\n\n.left-0 {\n left: 0;\n}\n\n.right-0 {\n right: 0;\n}\n\n.z-\\[100\\] {\n z-index: 100;\n}\n\n.z-\\[1\\] {\n z-index: 1;\n}\n\n.z-50 {\n z-index: 50;\n}\n\n.m-\\[10px\\] {\n margin: 10px;\n}\n\n.mx-\\[20px\\] {\n margin-left: 20px;\n margin-right: 20px;\n}\n\n.ml-\\[10px\\] {\n margin-left: 10px;\n}\n\n.mt-\\[10px\\] {\n margin-top: 10px;\n}\n\n.mt-\\[50px\\] {\n margin-top: 50px;\n}\n\n.block {\n display: block;\n}\n\n.inline {\n display: inline;\n}\n\n.flex {\n display: flex;\n}\n\n.table {\n display: table;\n}\n\n.hidden {\n display: none;\n}\n\n.h-\\[24px\\] {\n height: 24px;\n}\n\n.h-\\[150px\\] {\n height: 150px;\n}\n\n.h-\\[60px\\] {\n height: 60px;\n}\n\n.h-\\[72px\\] {\n height: 72px;\n}\n\n.h-full {\n height: 100%;\n}\n\n.h-\\[56px\\] {\n height: 56px;\n}\n\n.h-\\[40px\\] {\n height: 40px;\n}\n\n.h-\\[235px\\] {\n height: 235px;\n}\n\n.h-\\[93px\\] {\n height: 93px;\n}\n\n.h-screen {\n height: 100vh;\n}\n\n.h-fit {\n height: -moz-fit-content;\n height: fit-content;\n}\n\n.h-\\[30px\\] {\n height: 30px;\n}\n\n.min-h-0 {\n min-height: 0;\n}\n\n.min-h-\\[100\\%\\] {\n min-height: 100%;\n}\n\n.w-full {\n width: 100%;\n}\n\n.w-\\[60px\\] {\n width: 60px;\n}\n\n.w-\\[72px\\] {\n width: 72px;\n}\n\n.w-\\[56px\\] {\n width: 56px;\n}\n\n.w-\\[76px\\] {\n width: 76px;\n}\n\n.w-screen {\n width: 100vw;\n}\n\n.w-\\[360px\\] {\n width: 360px;\n}\n\n.w-\\[400px\\] {\n width: 400px;\n}\n\n.w-\\[320px\\] {\n width: 320px;\n}\n\n.w-\\[24px\\] {\n width: 24px;\n}\n\n.w-\\[30px\\] {\n width: 30px;\n}\n\n.min-w-\\[24px\\] {\n min-width: 24px;\n}\n\n.min-w-\\[100\\%\\] {\n min-width: 100%;\n}\n\n.max-w-\\[400px\\] {\n max-width: 400px;\n}\n\n.max-w-\\[600px\\] {\n max-width: 600px;\n}\n\n.max-w-\\[800px\\] {\n max-width: 800px;\n}\n\n.flex-1 {\n flex: 1;\n}\n\n.flex-auto {\n flex: auto;\n}\n\n.flex-grow {\n flex-grow: 1;\n}\n\n.translate-y-2 {\n --tw-translate-y: .5rem;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.translate-y-0 {\n --tw-translate-y: 0px;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.translate-y-\\[200\\%\\] {\n --tw-translate-y: 200%;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.translate-y-full {\n --tw-translate-y: 100%;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.scale-\\[0\\.4\\] {\n --tw-scale-x: .4;\n --tw-scale-y: .4;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.transform {\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.cursor-not-allowed {\n cursor: not-allowed;\n}\n\n.cursor-pointer {\n cursor: pointer;\n}\n\n.resize {\n resize: both;\n}\n\n.flex-row {\n flex-direction: row;\n}\n\n.flex-col {\n flex-direction: column;\n}\n\n.flex-wrap {\n flex-wrap: wrap;\n}\n\n.items-end {\n align-items: flex-end;\n}\n\n.items-center {\n align-items: center;\n}\n\n.justify-end {\n justify-content: flex-end;\n}\n\n.justify-center {\n justify-content: center;\n}\n\n.justify-between {\n justify-content: space-between;\n}\n\n.gap-\\[5px\\] {\n gap: 5px;\n}\n\n.gap-\\[20px\\] {\n gap: 20px;\n}\n\n.gap-\\[10px\\] {\n gap: 10px;\n}\n\n.gap-2\\.5 {\n gap: .625rem;\n}\n\n.gap-2 {\n gap: .5rem;\n}\n\n.gap-5 {\n gap: 1.25rem;\n}\n\n.overflow-auto {\n overflow: auto;\n}\n\n.overflow-hidden {\n overflow: hidden;\n}\n\n.rounded-lg {\n border-radius: .5rem;\n}\n\n.rounded-md {\n border-radius: .375rem;\n}\n\n.rounded-\\[50\\%\\] {\n border-radius: 50%;\n}\n\n.rounded-\\[8px\\] {\n border-radius: 8px;\n}\n\n.rounded-\\[15px\\] {\n border-radius: 15px;\n}\n\n.rounded-full {\n border-radius: 9999px;\n}\n\n.rounded-\\[5px\\] {\n border-radius: 5px;\n}\n\n.rounded-\\[60px\\] {\n border-radius: 60px;\n}\n\n.rounded-\\[10px\\] {\n border-radius: 10px;\n}\n\n.rounded-t-\\[15px\\] {\n border-top-left-radius: 15px;\n border-top-right-radius: 15px;\n}\n\n.border {\n border-width: 1px;\n}\n\n.border-secondaryLight {\n --tw-border-opacity: 1;\n border-color: rgb(179 179 179 / var(--tw-border-opacity));\n}\n\n.border-primaryLight {\n --tw-border-opacity: 1;\n border-color: rgb(86 86 86 / var(--tw-border-opacity));\n}\n\n.bg-primaryLight {\n --tw-bg-opacity: 1;\n background-color: rgb(86 86 86 / var(--tw-bg-opacity));\n}\n\n.bg-primary {\n --tw-bg-opacity: 1;\n background-color: rgb(29 28 32 / var(--tw-bg-opacity));\n}\n\n.bg-graySelected {\n --tw-bg-opacity: 1;\n background-color: rgb(245 245 245 / var(--tw-bg-opacity));\n}\n\n.bg-transparent {\n background-color: #0000;\n}\n\n.bg-white {\n --tw-bg-opacity: 1;\n background-color: rgb(255 255 255 / var(--tw-bg-opacity));\n}\n\n.bg-secondaryVLight {\n --tw-bg-opacity: 1;\n background-color: rgb(235 235 235 / var(--tw-bg-opacity));\n}\n\n.bg-\\[\\#f12828\\] {\n --tw-bg-opacity: 1;\n background-color: rgb(241 40 40 / var(--tw-bg-opacity));\n}\n\n.bg-\\[\\#565656\\] {\n --tw-bg-opacity: 1;\n background-color: rgb(86 86 86 / var(--tw-bg-opacity));\n}\n\n.bg-black, .bg-\\[\\#000\\], .bg-\\[\\#000000\\] {\n --tw-bg-opacity: 1;\n background-color: rgb(0 0 0 / var(--tw-bg-opacity));\n}\n\n.bg-\\[\\#FFFFFF\\] {\n --tw-bg-opacity: 1;\n background-color: rgb(255 255 255 / var(--tw-bg-opacity));\n}\n\n.bg-underlay {\n background-color: #00000040;\n}\n\n.bg-\\[\\#f3f3f3\\] {\n --tw-bg-opacity: 1;\n background-color: rgb(243 243 243 / var(--tw-bg-opacity));\n}\n\n.bg-opacity-90 {\n --tw-bg-opacity: .9;\n}\n\n.object-cover {\n object-fit: cover;\n}\n\n.p-2\\.5 {\n padding: .625rem;\n}\n\n.p-2 {\n padding: .5rem;\n}\n\n.p-\\[3px\\] {\n padding: 3px;\n}\n\n.p-\\[12px\\] {\n padding: 12px;\n}\n\n.py-3 {\n padding-top: .75rem;\n padding-bottom: .75rem;\n}\n\n.px-4 {\n padding-left: 1rem;\n padding-right: 1rem;\n}\n\n.py-\\[9px\\] {\n padding-top: 9px;\n padding-bottom: 9px;\n}\n\n.px-3\\.5 {\n padding-left: .875rem;\n padding-right: .875rem;\n}\n\n.px-3 {\n padding-left: .75rem;\n padding-right: .75rem;\n}\n\n.py-2 {\n padding-top: .5rem;\n padding-bottom: .5rem;\n}\n\n.py-1\\.5 {\n padding-top: .375rem;\n padding-bottom: .375rem;\n}\n\n.px-2\\.5 {\n padding-left: .625rem;\n padding-right: .625rem;\n}\n\n.py-1 {\n padding-top: .25rem;\n padding-bottom: .25rem;\n}\n\n.px-2 {\n padding-left: .5rem;\n padding-right: .5rem;\n}\n\n.px-\\[10px\\] {\n padding-left: 10px;\n padding-right: 10px;\n}\n\n.px-5 {\n padding-left: 1.25rem;\n padding-right: 1.25rem;\n}\n\n.py-\\[25px\\] {\n padding-top: 25px;\n padding-bottom: 25px;\n}\n\n.px-\\[20px\\] {\n padding-left: 20px;\n padding-right: 20px;\n}\n\n.pt-2\\.5 {\n padding-top: .625rem;\n}\n\n.pt-2 {\n padding-top: .5rem;\n}\n\n.pb-\\[25px\\] {\n padding-bottom: 25px;\n}\n\n.text-center {\n text-align: center;\n}\n\n.text-base {\n letter-spacing: -.02em;\n font-size: 16px;\n line-height: 19px;\n}\n\n.text-sm {\n letter-spacing: -.02em;\n font-size: 14px;\n line-height: 17px;\n}\n\n.text-xs {\n letter-spacing: -.02em;\n font-size: 12px;\n line-height: 14px;\n}\n\n.text-xl {\n letter-spacing: -.02em;\n font-size: 20px;\n line-height: 24px;\n}\n\n.text-\\[100px\\] {\n font-size: 100px;\n}\n\n.text-lg {\n letter-spacing: -.02em;\n font-size: 18px;\n line-height: 22px;\n}\n\n.font-medium {\n font-weight: 500;\n}\n\n.font-normal {\n font-weight: 400;\n}\n\n.font-bold {\n font-weight: 700;\n}\n\n.leading-\\[20px\\] {\n line-height: 20px;\n}\n\n.text-white {\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity));\n}\n\n.text-primary {\n --tw-text-opacity: 1;\n color: rgb(29 28 32 / var(--tw-text-opacity));\n}\n\n.text-primaryLight {\n --tw-text-opacity: 1;\n color: rgb(86 86 86 / var(--tw-text-opacity));\n}\n\n.text-secondary {\n --tw-text-opacity: 1;\n color: rgb(134 134 134 / var(--tw-text-opacity));\n}\n\n.text-black {\n --tw-text-opacity: 1;\n color: rgb(0 0 0 / var(--tw-text-opacity));\n}\n\n.underline {\n text-decoration-line: underline;\n}\n\n.antialiased {\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n.opacity-0 {\n opacity: 0;\n}\n\n.opacity-\\[0\\.6\\] {\n opacity: .6;\n}\n\n.opacity-50 {\n opacity: .5;\n}\n\n.opacity-\\[0\\.4\\] {\n opacity: .4;\n}\n\n.opacity-90 {\n opacity: .9;\n}\n\n.outline {\n outline-style: solid;\n}\n\n.ring-\\[3px\\] {\n --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);\n --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color);\n box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000);\n}\n\n.ring-cta {\n --tw-ring-opacity: 1;\n --tw-ring-color: rgb(38 138 250 / var(--tw-ring-opacity));\n}\n\n.blur {\n --tw-blur: blur(8px);\n filter: var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);\n}\n\n.filter {\n filter: var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);\n}\n\n.transition {\n transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter, backdrop-filter;\n transition-duration: .15s;\n transition-timing-function: cubic-bezier(.4, 0, .2, 1);\n}\n\n.transition-colors {\n transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;\n transition-duration: .15s;\n transition-timing-function: cubic-bezier(.4, 0, .2, 1);\n}\n\n.transition-\\[transform\\,border-radius\\] {\n transition-property: transform, border-radius;\n transition-duration: .15s;\n transition-timing-function: cubic-bezier(.4, 0, .2, 1);\n}\n\n.duration-300 {\n transition-duration: .3s;\n}\n\n.ease-in-out {\n transition-timing-function: cubic-bezier(.4, 0, .2, 1);\n}\n\n.ease-in {\n transition-timing-function: cubic-bezier(.4, 0, 1, 1);\n}\n\n.ease-out {\n transition-timing-function: cubic-bezier(0, 0, .2, 1);\n}\n\n.first-letter\\:capitalize:first-letter {\n text-transform: capitalize;\n}\n\n.focus\\:outline-none:focus {\n outline-offset: 2px;\n outline: 2px solid #0000;\n}\n\n.disabled\\:bg-secondaryLight:disabled {\n --tw-bg-opacity: 1;\n background-color: rgb(179 179 179 / var(--tw-bg-opacity));\n}\n\n.disabled\\:bg-graySelected:disabled {\n --tw-bg-opacity: 1;\n background-color: rgb(245 245 245 / var(--tw-bg-opacity));\n}\n\n.disabled\\:text-secondaryLight:disabled {\n --tw-text-opacity: 1;\n color: rgb(179 179 179 / var(--tw-text-opacity));\n}\n\n";
|
|
12279
|
+
|
|
12280
|
+
|
|
10917
12281
|
const $24075a5d702d64b3$var$currentURL = new URL(window.location.href);
|
|
10918
12282
|
const $24075a5d702d64b3$var$microphoneEnabled = $24075a5d702d64b3$var$currentURL.searchParams.get("microphone-enabled") !== "0";
|
|
10919
12283
|
const $24075a5d702d64b3$var$cameraEnabled = $24075a5d702d64b3$var$currentURL.searchParams.get("camera-enabled") === "1";
|
|
10920
12284
|
const $24075a5d702d64b3$var$defaultOptions = {
|
|
12285
|
+
recorder: false,
|
|
10921
12286
|
sharedURL: window.location.href,
|
|
10922
12287
|
showMenuButton: true,
|
|
10923
12288
|
settingsShortcuts: [
|
|
@@ -10946,15 +12311,26 @@ const $24075a5d702d64b3$export$3f94917203ab7078 = {
|
|
|
10946
12311
|
init: ({ element: element , ...options })=>{
|
|
10947
12312
|
if (element?.nodeType !== window.Node.ELEMENT_NODE) throw new Error('The "element" property must be a valid element!');
|
|
10948
12313
|
const mergedOptions = (0, $365e765f9890497b$export$6969335ea1e4e77c)($24075a5d702d64b3$var$defaultOptions, options);
|
|
10949
|
-
|
|
10950
|
-
|
|
10951
|
-
|
|
12314
|
+
const rootElement = (0, $3Sbms$createRoot)(element);
|
|
12315
|
+
let styleElement = null;
|
|
12316
|
+
styleElement = /*#__PURE__*/ (0, $3Sbms$jsx)("style", {
|
|
12317
|
+
children: (0, (/*@__PURE__*/$parcel$interopDefault($1e2747ca72d0ab49$exports)))
|
|
12318
|
+
});
|
|
12319
|
+
rootElement.render(/*#__PURE__*/ (0, $3Sbms$jsxs)((0, $3Sbms$Fragment), {
|
|
12320
|
+
children: [
|
|
12321
|
+
styleElement,
|
|
12322
|
+
/*#__PURE__*/ (0, $3Sbms$jsx)((0, $26ed036cbc17809a$export$2e2bcd8739ae039), {
|
|
12323
|
+
options: mergedOptions
|
|
12324
|
+
})
|
|
12325
|
+
]
|
|
12326
|
+
}));
|
|
10952
12327
|
if (mergedOptions.tracking) (0, $3Sbms$hotjarbrowser).init(3111933, 6);
|
|
10953
12328
|
},
|
|
10954
12329
|
initGreeting: (element, onGreetingDone)=>{
|
|
10955
|
-
|
|
12330
|
+
const rootElement = (0, $3Sbms$createRoot)(element);
|
|
12331
|
+
rootElement.render(/*#__PURE__*/ (0, $3Sbms$jsx)((0, $f8d57e3d223f5089$export$2e2bcd8739ae039), {
|
|
10956
12332
|
onGreetingDone: onGreetingDone
|
|
10957
|
-
})
|
|
12333
|
+
}));
|
|
10958
12334
|
},
|
|
10959
12335
|
setExtraSettingsOptions: (extraOptions)=>{
|
|
10960
12336
|
const event = new CustomEvent("streamUISetExtraSettingsOptions", {
|
|
@@ -10964,12 +12340,15 @@ const $24075a5d702d64b3$export$3f94917203ab7078 = {
|
|
|
10964
12340
|
});
|
|
10965
12341
|
window.dispatchEvent(event);
|
|
10966
12342
|
},
|
|
12343
|
+
startRecord: (0, $c9e496369b59be7a$export$2f377c2162fd02b2).startRecord.bind((0, $c9e496369b59be7a$export$2f377c2162fd02b2)),
|
|
12344
|
+
stopRecord: (0, $c9e496369b59be7a$export$2f377c2162fd02b2).stopRecord.bind((0, $c9e496369b59be7a$export$2f377c2162fd02b2)),
|
|
10967
12345
|
sendNotification: $a5146f9062d7bf28$export$3a57e165650c636f,
|
|
10968
12346
|
joinRoom: (0, $c9e496369b59be7a$export$2f377c2162fd02b2).init.bind((0, $c9e496369b59be7a$export$2f377c2162fd02b2)),
|
|
10969
12347
|
leaveRoom: (0, $c9e496369b59be7a$export$2f377c2162fd02b2).endCall.bind((0, $c9e496369b59be7a$export$2f377c2162fd02b2)),
|
|
10970
12348
|
terminateRoom: (0, $c9e496369b59be7a$export$2f377c2162fd02b2).terminateRoom.bind((0, $c9e496369b59be7a$export$2f377c2162fd02b2)),
|
|
10971
12349
|
generateToken: (0, $c9e496369b59be7a$export$2f377c2162fd02b2).generateToken.bind((0, $c9e496369b59be7a$export$2f377c2162fd02b2)),
|
|
10972
12350
|
addEventListener: (0, $c9e496369b59be7a$export$2f377c2162fd02b2).addEventListener.bind((0, $c9e496369b59be7a$export$2f377c2162fd02b2)),
|
|
12351
|
+
removeEventListener: (0, $c9e496369b59be7a$export$2f377c2162fd02b2).removeEventListener.bind((0, $c9e496369b59be7a$export$2f377c2162fd02b2)),
|
|
10973
12352
|
dispatchEvent: (0, $c9e496369b59be7a$export$2f377c2162fd02b2).dispatchEvent.bind((0, $c9e496369b59be7a$export$2f377c2162fd02b2)),
|
|
10974
12353
|
getState: (0, $c9e496369b59be7a$export$2f377c2162fd02b2).getState.bind((0, $c9e496369b59be7a$export$2f377c2162fd02b2)),
|
|
10975
12354
|
setProfile: (0, $c9e496369b59be7a$export$2f377c2162fd02b2).setProfile.bind((0, $c9e496369b59be7a$export$2f377c2162fd02b2)),
|