@ai-matrx/meet 0.9.0 → 0.10.1
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/CHANGELOG.md +26 -0
- package/dist/{collab-B6scmSST.d.cts → collab-BBQxcyRQ.d.cts} +53 -2
- package/dist/{collab-B6scmSST.d.ts → collab-BBQxcyRQ.d.ts} +53 -2
- package/dist/{components-BeCQ9h0h.d.cts → components-1XBHgMYK.d.ts} +6 -2
- package/dist/{components-D0TqyeiY.d.ts → components-CK0EyqGL.d.cts} +6 -2
- package/dist/core.cjs +1225 -939
- package/dist/core.cjs.map +1 -1
- package/dist/core.d.cts +101 -26
- package/dist/core.d.ts +101 -26
- package/dist/core.js +1225 -939
- package/dist/core.js.map +1 -1
- package/dist/index.cjs +1225 -939
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1225 -939
- package/dist/index.js.map +1 -1
- package/dist/react.cjs +3120 -2694
- package/dist/react.cjs.map +1 -1
- package/dist/react.d.cts +69 -6
- package/dist/react.d.ts +69 -6
- package/dist/react.js +2775 -2349
- package/dist/react.js.map +1 -1
- package/dist/skins/meet.cjs +1051 -911
- package/dist/skins/meet.cjs.map +1 -1
- package/dist/skins/meet.d.cts +2 -2
- package/dist/skins/meet.d.ts +2 -2
- package/dist/skins/meet.js +702 -562
- package/dist/skins/meet.js.map +1 -1
- package/dist/styles.css +8 -0
- package/package.json +5 -5
package/dist/skins/meet.cjs
CHANGED
|
@@ -107,10 +107,10 @@ __export(meet_exports, {
|
|
|
107
107
|
module.exports = __toCommonJS(meet_exports);
|
|
108
108
|
|
|
109
109
|
// src/skins/meet/components.tsx
|
|
110
|
-
var
|
|
110
|
+
var import_react10 = require("react");
|
|
111
111
|
|
|
112
112
|
// src/react/facade.ts
|
|
113
|
-
var
|
|
113
|
+
var import_react8 = require("react");
|
|
114
114
|
|
|
115
115
|
// src/react/root.tsx
|
|
116
116
|
var import_react3 = require("react");
|
|
@@ -289,7 +289,17 @@ var MEET_ROUTES = {
|
|
|
289
289
|
*/
|
|
290
290
|
collab: "/api/v1/meet/collab",
|
|
291
291
|
/** Meet wave 5: translate finished caption lines into this viewer's language. */
|
|
292
|
-
captionsTranslate: "/api/v1/meet/captions/translate"
|
|
292
|
+
captionsTranslate: "/api/v1/meet/captions/translate",
|
|
293
|
+
/**
|
|
294
|
+
* S4 — THE STATE READ (CORE-DESIGN §2.6): `GET ?meeting_id=` with `x-meet-pass`. This
|
|
295
|
+
* person's admission (lazy expiry applied), whether anyone who can admit is here, the run's
|
|
296
|
+
* phase. Read every `waiting_poll_seconds` while waiting and on every `mx.state.changed`.
|
|
297
|
+
*/
|
|
298
|
+
state: "/api/v1/meet/state",
|
|
299
|
+
/** S4: `withdraw` (stop waiting) or `leave` (close this tab); the pass may ride in the body. */
|
|
300
|
+
leave: "/api/v1/meet/leave",
|
|
301
|
+
/** S4: a pass holder (guests included) saw the recording notice, for this run. */
|
|
302
|
+
consent: "/api/v1/meet/consent"
|
|
293
303
|
};
|
|
294
304
|
|
|
295
305
|
// src/core/recording.ts
|
|
@@ -350,6 +360,20 @@ function isLinkFollower(standing) {
|
|
|
350
360
|
function isHostRole(role) {
|
|
351
361
|
return role === "host" || role === "cohost";
|
|
352
362
|
}
|
|
363
|
+
function isObserverRole(role) {
|
|
364
|
+
return role === "viewer";
|
|
365
|
+
}
|
|
366
|
+
|
|
367
|
+
// src/core/app-panel.ts
|
|
368
|
+
function appPanelOf(meeting) {
|
|
369
|
+
const raw = meeting?.metadata?.["app_panel"];
|
|
370
|
+
if (typeof raw !== "object" || raw === null || Array.isArray(raw)) return null;
|
|
371
|
+
const key = raw["key"];
|
|
372
|
+
const recordId = raw["record_id"];
|
|
373
|
+
if (typeof key !== "string" || key.length === 0) return null;
|
|
374
|
+
if (typeof recordId !== "string" || recordId.length === 0) return null;
|
|
375
|
+
return { key, recordId };
|
|
376
|
+
}
|
|
353
377
|
|
|
354
378
|
// src/core/collab.ts
|
|
355
379
|
function assignedRoom(plan, identity) {
|
|
@@ -471,7 +495,7 @@ function observedPhase(input) {
|
|
|
471
495
|
case "left":
|
|
472
496
|
return "prejoin";
|
|
473
497
|
case "lobby":
|
|
474
|
-
return
|
|
498
|
+
return waitingPhase(snapshot);
|
|
475
499
|
case "requesting-token":
|
|
476
500
|
case "connecting":
|
|
477
501
|
return "joining";
|
|
@@ -480,6 +504,24 @@ function observedPhase(input) {
|
|
|
480
504
|
return "in_call";
|
|
481
505
|
}
|
|
482
506
|
}
|
|
507
|
+
function waitingPhase(snapshot) {
|
|
508
|
+
switch (snapshot.waiting?.admission) {
|
|
509
|
+
case "waiting_host":
|
|
510
|
+
return "waiting:host_not_started";
|
|
511
|
+
case "denied":
|
|
512
|
+
return "denied";
|
|
513
|
+
case "expired":
|
|
514
|
+
return "knock_expired";
|
|
515
|
+
case "withdrawn":
|
|
516
|
+
return "left";
|
|
517
|
+
case "ended":
|
|
518
|
+
return "ended";
|
|
519
|
+
case "removed":
|
|
520
|
+
return "refused:removed";
|
|
521
|
+
default:
|
|
522
|
+
return "waiting:knocking";
|
|
523
|
+
}
|
|
524
|
+
}
|
|
483
525
|
var ADMITTER_ROLES = /* @__PURE__ */ new Set(["host", "cohost"]);
|
|
484
526
|
function observe(input) {
|
|
485
527
|
const { snapshot } = input;
|
|
@@ -494,7 +536,7 @@ function observe(input) {
|
|
|
494
536
|
reason: phase.startsWith("refused:") ? phase.slice("refused:".length) : null,
|
|
495
537
|
role,
|
|
496
538
|
connection: snapshot?.phase === "reconnecting" ? "reconnecting" : "stable",
|
|
497
|
-
hostPresent: inCall && snapshot !== null ? snapshot.participants.some((p) => ADMITTER_ROLES.has(p.role)) : null,
|
|
539
|
+
hostPresent: inCall && snapshot !== null ? snapshot.participants.some((p) => ADMITTER_ROLES.has(p.role)) : snapshot?.phase === "lobby" ? snapshot.waiting?.admittersPresent ?? null : null,
|
|
498
540
|
lobbyCount: canAdmit && snapshot !== null ? snapshot.lobby.filter((entry) => entry.state === "knocking").length : 0,
|
|
499
541
|
recording: snapshot?.recording === "recording" || snapshot?.recording === "stopping",
|
|
500
542
|
audioBlocked: null,
|
|
@@ -769,7 +811,10 @@ function orderParticipants(participants, activeSpeakers) {
|
|
|
769
811
|
}
|
|
770
812
|
function computeStage(args) {
|
|
771
813
|
const pageSize = Math.max(1, args.pageSize ?? DEFAULT_PAGE_SIZE);
|
|
772
|
-
const ordered = orderParticipants(
|
|
814
|
+
const ordered = orderParticipants(
|
|
815
|
+
args.participants.filter((participant) => !isObserverRole(participant.role)),
|
|
816
|
+
args.activeSpeakers
|
|
817
|
+
);
|
|
773
818
|
const sharer = ordered.find((participant) => participant.screenSharing) ?? null;
|
|
774
819
|
const pinnedParticipant = args.pinned === null ? null : ordered.find((participant) => participant.identity === args.pinned) ?? null;
|
|
775
820
|
const spotlit = args.spotlight == null ? null : ordered.find((participant) => participant.identity === args.spotlight) ?? null;
|
|
@@ -795,9 +840,97 @@ function gridColumns(count) {
|
|
|
795
840
|
return 5;
|
|
796
841
|
}
|
|
797
842
|
|
|
798
|
-
// src/react/
|
|
843
|
+
// src/react/app-panel.tsx
|
|
799
844
|
var import_react4 = require("react");
|
|
800
|
-
|
|
845
|
+
|
|
846
|
+
// src/core/collab-state.ts
|
|
847
|
+
function availableActivities(collab, isHost) {
|
|
848
|
+
const settings = collab?.settings ?? null;
|
|
849
|
+
if (settings === null) return [];
|
|
850
|
+
const out = [];
|
|
851
|
+
if (settings.whiteboardEnabled) out.push("whiteboard");
|
|
852
|
+
if (settings.pollsEnabled && (isHost || (collab?.polls.length ?? 0) > 0)) out.push("polls");
|
|
853
|
+
if (settings.qaEnabled) out.push("qa");
|
|
854
|
+
if (settings.breakoutsEnabled && (isHost || collab?.breakout?.state === "open")) out.push("breakouts");
|
|
855
|
+
return out;
|
|
856
|
+
}
|
|
857
|
+
function activityAttention(collab, isHost) {
|
|
858
|
+
if (collab === null) return false;
|
|
859
|
+
if (collab.polls.some((poll) => poll.state === "live" && poll.myVote.length === 0 && !isHost)) return true;
|
|
860
|
+
if (isHost && collab.questions.some((q) => q.state === "open")) return true;
|
|
861
|
+
return false;
|
|
862
|
+
}
|
|
863
|
+
async function performCollab(runtime, request) {
|
|
864
|
+
if (runtime === null) return { ok: false, message: "This meeting is not connected." };
|
|
865
|
+
try {
|
|
866
|
+
const result = await runtime.inRoom.collab(request);
|
|
867
|
+
return { ok: true, message: result.message, itemId: result.itemId };
|
|
868
|
+
} catch (error) {
|
|
869
|
+
return { ok: false, message: error.message ?? "That did not work." };
|
|
870
|
+
}
|
|
871
|
+
}
|
|
872
|
+
async function moveToRoom(runtime, roomId) {
|
|
873
|
+
if (runtime === null) return { ok: false, message: "This meeting is not connected." };
|
|
874
|
+
try {
|
|
875
|
+
await runtime.engine.moveToBreakout(roomId);
|
|
876
|
+
return { ok: true, message: roomId === null ? "Back in the main room." : "Joined the breakout room." };
|
|
877
|
+
} catch (error) {
|
|
878
|
+
return { ok: false, message: error.message ?? "That room could not be joined." };
|
|
879
|
+
}
|
|
880
|
+
}
|
|
881
|
+
function untranslatedLines(lines, translations) {
|
|
882
|
+
return lines.filter((line) => line.final && translations[line.id] === void 0).map(({ id, text }) => ({ id, text }));
|
|
883
|
+
}
|
|
884
|
+
function nextTranslationBatch(pending, language, asked) {
|
|
885
|
+
const batch = pending.filter((line) => !asked.has(`${language}:${line.id}`)).slice(-20);
|
|
886
|
+
for (const line of batch) asked.add(`${language}:${line.id}`);
|
|
887
|
+
return batch;
|
|
888
|
+
}
|
|
889
|
+
function setCaptionLanguage(store, next) {
|
|
890
|
+
store.patch({
|
|
891
|
+
collab: {
|
|
892
|
+
...store.snapshot().collab,
|
|
893
|
+
captionLanguage: next,
|
|
894
|
+
captionTranslations: {},
|
|
895
|
+
captionTranslationError: null
|
|
896
|
+
}
|
|
897
|
+
});
|
|
898
|
+
}
|
|
899
|
+
function takePanelRequest(store) {
|
|
900
|
+
const request = store.snapshot().collab.panelRequest;
|
|
901
|
+
if (request === null) return null;
|
|
902
|
+
store.patch({ collab: { ...store.snapshot().collab, panelRequest: null } });
|
|
903
|
+
return request.panel;
|
|
904
|
+
}
|
|
905
|
+
function takeMoveRequest(store) {
|
|
906
|
+
const request = store.snapshot().collab.moveRequest;
|
|
907
|
+
if (request === null) return null;
|
|
908
|
+
store.patch({ collab: { ...store.snapshot().collab, moveRequest: null } });
|
|
909
|
+
return { roomId: request.roomId };
|
|
910
|
+
}
|
|
911
|
+
|
|
912
|
+
// src/react/app-panel.tsx
|
|
913
|
+
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
914
|
+
var RegistryContext = (0, import_react4.createContext)({});
|
|
915
|
+
function useMeetAppPanelRegistry() {
|
|
916
|
+
return (0, import_react4.useContext)(RegistryContext);
|
|
917
|
+
}
|
|
918
|
+
function useMeetAppPanel(meeting) {
|
|
919
|
+
const snapshot = useMeetSnapshot();
|
|
920
|
+
const registry = useMeetAppPanelRegistry();
|
|
921
|
+
const record = meeting ?? snapshot?.meeting ?? null;
|
|
922
|
+
return (0, import_react4.useMemo)(() => {
|
|
923
|
+
const panel = appPanelOf(record);
|
|
924
|
+
if (panel === null || record === null) return null;
|
|
925
|
+
const entry = registry[panel.key];
|
|
926
|
+
if (entry === void 0) return null;
|
|
927
|
+
return { ...entry, panel, organizationId: record.organizationId };
|
|
928
|
+
}, [record, registry]);
|
|
929
|
+
}
|
|
930
|
+
|
|
931
|
+
// src/react/hooks.ts
|
|
932
|
+
var import_react5 = require("react");
|
|
933
|
+
var import_react6 = require("@ai-matrx/realtime/react");
|
|
801
934
|
|
|
802
935
|
// src/core/record.ts
|
|
803
936
|
var import_format = require("@ai-matrx/kit/format");
|
|
@@ -922,51 +1055,51 @@ function useRoom() {
|
|
|
922
1055
|
failure: snapshot?.failure ?? null,
|
|
923
1056
|
local,
|
|
924
1057
|
canShareScreen: engine?.supportsScreenShare() ?? true,
|
|
925
|
-
join: (0,
|
|
1058
|
+
join: (0, import_react5.useCallback)(
|
|
926
1059
|
async (request) => requireEngine(engine, "join").join(request),
|
|
927
1060
|
[engine]
|
|
928
1061
|
),
|
|
929
|
-
leave: (0,
|
|
930
|
-
toggleMicrophone: (0,
|
|
1062
|
+
leave: (0, import_react5.useCallback)(async () => requireEngine(engine, "leave").leave(), [engine]),
|
|
1063
|
+
toggleMicrophone: (0, import_react5.useCallback)(
|
|
931
1064
|
async () => requireEngine(engine, "toggleMicrophone").setMicrophoneEnabled(
|
|
932
1065
|
!(local?.micEnabled ?? false)
|
|
933
1066
|
),
|
|
934
1067
|
[engine, local]
|
|
935
1068
|
),
|
|
936
|
-
toggleCamera: (0,
|
|
1069
|
+
toggleCamera: (0, import_react5.useCallback)(
|
|
937
1070
|
async () => requireEngine(engine, "toggleCamera").setCameraEnabled(!(local?.cameraEnabled ?? false)),
|
|
938
1071
|
[engine, local]
|
|
939
1072
|
),
|
|
940
|
-
toggleScreenShare: (0,
|
|
1073
|
+
toggleScreenShare: (0, import_react5.useCallback)(
|
|
941
1074
|
async () => requireEngine(engine, "toggleScreenShare").setScreenShareEnabled(
|
|
942
1075
|
!(local?.screenSharing ?? false)
|
|
943
1076
|
),
|
|
944
1077
|
[engine, local]
|
|
945
1078
|
),
|
|
946
|
-
toggleHand: (0,
|
|
1079
|
+
toggleHand: (0, import_react5.useCallback)(
|
|
947
1080
|
async () => requireEngine(engine, "toggleHand").raiseHand(!(local?.handRaised ?? false)),
|
|
948
1081
|
[engine, local]
|
|
949
1082
|
),
|
|
950
|
-
react: (0,
|
|
1083
|
+
react: (0, import_react5.useCallback)(
|
|
951
1084
|
async (emoji) => requireEngine(engine, "react").react(emoji),
|
|
952
1085
|
[engine]
|
|
953
1086
|
),
|
|
954
|
-
sendChat: (0,
|
|
1087
|
+
sendChat: (0, import_react5.useCallback)(
|
|
955
1088
|
async (text) => {
|
|
956
1089
|
if (host === null) throw noRuntime("sendChat");
|
|
957
1090
|
await host.inRoom.sendChat(text);
|
|
958
1091
|
},
|
|
959
1092
|
[host]
|
|
960
1093
|
),
|
|
961
|
-
sendPrivateChat: (0,
|
|
1094
|
+
sendPrivateChat: (0, import_react5.useCallback)(
|
|
962
1095
|
async (to, text) => requireEngine(engine, "sendPrivateChat").sendPrivateChat(to, text),
|
|
963
1096
|
[engine]
|
|
964
1097
|
),
|
|
965
|
-
pin: (0,
|
|
1098
|
+
pin: (0, import_react5.useCallback)(
|
|
966
1099
|
(identity) => requireEngine(engine, "pin").pin(identity),
|
|
967
1100
|
[engine]
|
|
968
1101
|
),
|
|
969
|
-
setLayout: (0,
|
|
1102
|
+
setLayout: (0, import_react5.useCallback)(
|
|
970
1103
|
(layout) => requireEngine(engine, "setLayout").setLayout(layout),
|
|
971
1104
|
[engine]
|
|
972
1105
|
)
|
|
@@ -974,8 +1107,8 @@ function useRoom() {
|
|
|
974
1107
|
}
|
|
975
1108
|
function useStage(pageSize = DEFAULT_PAGE_SIZE) {
|
|
976
1109
|
const snapshot = useMeetSnapshot();
|
|
977
|
-
const [page, setPage] = (0,
|
|
978
|
-
const stage = (0,
|
|
1110
|
+
const [page, setPage] = (0, import_react5.useState)(0);
|
|
1111
|
+
const stage = (0, import_react5.useMemo)(
|
|
979
1112
|
() => computeStage({
|
|
980
1113
|
participants: snapshot?.participants ?? [],
|
|
981
1114
|
layout: snapshot?.layout ?? "grid",
|
|
@@ -987,15 +1120,15 @@ function useStage(pageSize = DEFAULT_PAGE_SIZE) {
|
|
|
987
1120
|
}),
|
|
988
1121
|
[snapshot, pageSize, page]
|
|
989
1122
|
);
|
|
990
|
-
(0,
|
|
1123
|
+
(0, import_react5.useEffect)(() => {
|
|
991
1124
|
if (page > stage.pageCount - 1) setPage(Math.max(0, stage.pageCount - 1));
|
|
992
1125
|
}, [page, stage.pageCount]);
|
|
993
1126
|
return stage;
|
|
994
1127
|
}
|
|
995
1128
|
function useTrack(identity, kind) {
|
|
996
1129
|
const host = useMeetHost();
|
|
997
|
-
const detachRef = (0,
|
|
998
|
-
return (0,
|
|
1130
|
+
const detachRef = (0, import_react5.useRef)(null);
|
|
1131
|
+
return (0, import_react5.useCallback)(
|
|
999
1132
|
(element) => {
|
|
1000
1133
|
detachRef.current?.();
|
|
1001
1134
|
detachRef.current = null;
|
|
@@ -1015,24 +1148,34 @@ function useLobby() {
|
|
|
1015
1148
|
// No runtime means no host powers — `<LobbyPanel>` renders nothing rather
|
|
1016
1149
|
// than an admit button that would throw.
|
|
1017
1150
|
canAdmit: session !== null && isHost,
|
|
1018
|
-
admit: (0,
|
|
1151
|
+
admit: (0, import_react5.useCallback)(
|
|
1019
1152
|
async (entry) => requireSession(session, "admit").admit(entry, true),
|
|
1020
1153
|
[session]
|
|
1021
1154
|
),
|
|
1022
|
-
deny: (0,
|
|
1155
|
+
deny: (0, import_react5.useCallback)(
|
|
1023
1156
|
async (entry) => requireSession(session, "deny").admit(entry, false),
|
|
1024
1157
|
[session]
|
|
1025
1158
|
),
|
|
1026
|
-
admitAll: (0,
|
|
1159
|
+
admitAll: (0, import_react5.useCallback)(
|
|
1027
1160
|
async () => requireSession(session, "admitAll").admitAll(),
|
|
1028
1161
|
[session]
|
|
1029
1162
|
),
|
|
1030
|
-
|
|
1031
|
-
(
|
|
1163
|
+
undeny: (0, import_react5.useCallback)(
|
|
1164
|
+
async (entry) => requireSession(session, "undeny").undeny(entry),
|
|
1032
1165
|
[session]
|
|
1033
1166
|
)
|
|
1034
1167
|
};
|
|
1035
1168
|
}
|
|
1169
|
+
function useWaiting() {
|
|
1170
|
+
const host = useMeetHost();
|
|
1171
|
+
const snapshot = useMeetSnapshot();
|
|
1172
|
+
const session = host?.meetings ?? null;
|
|
1173
|
+
return {
|
|
1174
|
+
waiting: snapshot?.waiting ?? null,
|
|
1175
|
+
withdraw: (0, import_react5.useCallback)(async () => requireSession(session, "withdraw").withdraw(), [session]),
|
|
1176
|
+
askAgain: (0, import_react5.useCallback)(async () => requireSession(session, "askAgain").askAgain(), [session])
|
|
1177
|
+
};
|
|
1178
|
+
}
|
|
1036
1179
|
function useRecording() {
|
|
1037
1180
|
const host = useMeetHost();
|
|
1038
1181
|
const snapshot = useMeetSnapshot();
|
|
@@ -1047,7 +1190,7 @@ function useRecording() {
|
|
|
1047
1190
|
// `stopping` is already stopping; the other in-flight states can be.
|
|
1048
1191
|
canStop: host !== null && canRecord && (state === "recording" || state === "starting"),
|
|
1049
1192
|
consentNotice: host?.recording.consentNotice(meeting) ?? null,
|
|
1050
|
-
start: (0,
|
|
1193
|
+
start: (0, import_react5.useCallback)(async () => {
|
|
1051
1194
|
const live = requireHost(host, "startRecording");
|
|
1052
1195
|
if (meeting === null || live.identity.userId === null) return;
|
|
1053
1196
|
await live.recording.start({
|
|
@@ -1056,7 +1199,7 @@ function useRecording() {
|
|
|
1056
1199
|
by: live.identity.userId
|
|
1057
1200
|
});
|
|
1058
1201
|
}, [host, meeting]),
|
|
1059
|
-
stop: (0,
|
|
1202
|
+
stop: (0, import_react5.useCallback)(async () => {
|
|
1060
1203
|
const live = requireHost(host, "stopRecording");
|
|
1061
1204
|
if (meeting === null || live.identity.userId === null) return;
|
|
1062
1205
|
await live.recording.stop({ meetingId: meeting.id, by: live.identity.userId });
|
|
@@ -1067,17 +1210,17 @@ function useMeetAi() {
|
|
|
1067
1210
|
const host = useMeetHost();
|
|
1068
1211
|
const snapshot = useMeetSnapshot();
|
|
1069
1212
|
const isHost = useIsHost();
|
|
1070
|
-
const [asking, setAsking] = (0,
|
|
1071
|
-
const [answer, setAnswer] = (0,
|
|
1072
|
-
const [coverage, setCoverage] = (0,
|
|
1073
|
-
const [phase, setPhase] = (0,
|
|
1074
|
-
const [error, setError] = (0,
|
|
1213
|
+
const [asking, setAsking] = (0, import_react5.useState)(false);
|
|
1214
|
+
const [answer, setAnswer] = (0, import_react5.useState)(null);
|
|
1215
|
+
const [coverage, setCoverage] = (0, import_react5.useState)(null);
|
|
1216
|
+
const [phase, setPhase] = (0, import_react5.useState)(null);
|
|
1217
|
+
const [error, setError] = (0, import_react5.useState)(null);
|
|
1075
1218
|
const ai = host?.ai ?? null;
|
|
1076
1219
|
const meeting = snapshot?.meeting ?? null;
|
|
1077
1220
|
const participants = snapshot?.participants ?? [];
|
|
1078
1221
|
const notes = snapshot?.notes ?? [];
|
|
1079
1222
|
const wrapUp = snapshot?.wrapUp ?? null;
|
|
1080
|
-
const status = (0,
|
|
1223
|
+
const status = (0, import_react5.useMemo)(
|
|
1081
1224
|
() => noteTakerStatus({
|
|
1082
1225
|
meeting,
|
|
1083
1226
|
participants,
|
|
@@ -1086,7 +1229,7 @@ function useMeetAi() {
|
|
|
1086
1229
|
[meeting, participants, snapshot?.noteTakerRefusal]
|
|
1087
1230
|
);
|
|
1088
1231
|
const names = snapshot?.names ?? EMPTY_NAMES;
|
|
1089
|
-
const transcript = (0,
|
|
1232
|
+
const transcript = (0, import_react5.useMemo)(
|
|
1090
1233
|
() => readableTranscript(snapshot?.transcript ?? []).map((line) => ({
|
|
1091
1234
|
id: line.id,
|
|
1092
1235
|
identity: line.identity,
|
|
@@ -1102,7 +1245,7 @@ function useMeetAi() {
|
|
|
1102
1245
|
})),
|
|
1103
1246
|
[snapshot?.transcript, names]
|
|
1104
1247
|
);
|
|
1105
|
-
const dispatchNoteTaker = (0,
|
|
1248
|
+
const dispatchNoteTaker = (0, import_react5.useCallback)(
|
|
1106
1249
|
async (run) => {
|
|
1107
1250
|
setError(null);
|
|
1108
1251
|
try {
|
|
@@ -1138,7 +1281,7 @@ function useMeetAi() {
|
|
|
1138
1281
|
coverage,
|
|
1139
1282
|
phase,
|
|
1140
1283
|
error,
|
|
1141
|
-
ask: (0,
|
|
1284
|
+
ask: (0, import_react5.useCallback)(
|
|
1142
1285
|
async (question) => {
|
|
1143
1286
|
if (ai === null || meeting === null) return;
|
|
1144
1287
|
setAsking(true);
|
|
@@ -1169,13 +1312,13 @@ function useMeetAi() {
|
|
|
1169
1312
|
},
|
|
1170
1313
|
[ai, meeting]
|
|
1171
1314
|
),
|
|
1172
|
-
startNoteTaker: (0,
|
|
1315
|
+
startNoteTaker: (0, import_react5.useCallback)(async () => {
|
|
1173
1316
|
if (ai === null || meeting === null) return;
|
|
1174
1317
|
await dispatchNoteTaker(
|
|
1175
1318
|
() => ai.startNoteTaker({ meetingId: meeting.id, roomName: meeting.roomName })
|
|
1176
1319
|
);
|
|
1177
1320
|
}, [ai, meeting, dispatchNoteTaker]),
|
|
1178
|
-
stopNoteTaker: (0,
|
|
1321
|
+
stopNoteTaker: (0, import_react5.useCallback)(async () => {
|
|
1179
1322
|
if (ai === null || meeting === null) return;
|
|
1180
1323
|
await dispatchNoteTaker(() => ai.stopNoteTaker({ meetingId: meeting.id }));
|
|
1181
1324
|
}, [ai, meeting, dispatchNoteTaker])
|
|
@@ -1185,8 +1328,8 @@ function useEndMeeting() {
|
|
|
1185
1328
|
const host = useMeetHost();
|
|
1186
1329
|
const snapshot = useMeetSnapshot();
|
|
1187
1330
|
const isHost = useIsHost();
|
|
1188
|
-
const [ending, setEnding] = (0,
|
|
1189
|
-
const [notice, setNotice] = (0,
|
|
1331
|
+
const [ending, setEnding] = (0, import_react5.useState)(false);
|
|
1332
|
+
const [notice, setNotice] = (0, import_react5.useState)(null);
|
|
1190
1333
|
const meeting = snapshot?.meeting ?? null;
|
|
1191
1334
|
const session = host?.meetings ?? null;
|
|
1192
1335
|
return {
|
|
@@ -1194,7 +1337,7 @@ function useEndMeeting() {
|
|
|
1194
1337
|
ending,
|
|
1195
1338
|
ended: meeting?.endedAt !== null && meeting?.endedAt !== void 0,
|
|
1196
1339
|
notice,
|
|
1197
|
-
end: (0,
|
|
1340
|
+
end: (0, import_react5.useCallback)(async () => {
|
|
1198
1341
|
const live = requireSession(session, "endForEveryone");
|
|
1199
1342
|
setEnding(true);
|
|
1200
1343
|
setNotice(null);
|
|
@@ -1228,7 +1371,7 @@ function useReactions() {
|
|
|
1228
1371
|
const host = useMeetHost();
|
|
1229
1372
|
const snapshot = useMeetSnapshot();
|
|
1230
1373
|
const store = host?.store ?? null;
|
|
1231
|
-
(0,
|
|
1374
|
+
(0, import_react5.useEffect)(() => {
|
|
1232
1375
|
if (store === null) return void 0;
|
|
1233
1376
|
const timer = setInterval(() => store.expireReactions(Date.now()), REACTION_TTL_MS / 2);
|
|
1234
1377
|
return () => clearInterval(timer);
|
|
@@ -1236,8 +1379,8 @@ function useReactions() {
|
|
|
1236
1379
|
return snapshot?.reactions ?? [];
|
|
1237
1380
|
}
|
|
1238
1381
|
function useElapsed(startedAt) {
|
|
1239
|
-
const [now, setNow] = (0,
|
|
1240
|
-
(0,
|
|
1382
|
+
const [now, setNow] = (0, import_react5.useState)(() => Date.now());
|
|
1383
|
+
(0, import_react5.useEffect)(() => {
|
|
1241
1384
|
if (startedAt === null) return void 0;
|
|
1242
1385
|
const timer = setInterval(() => setNow(Date.now()), 1e3);
|
|
1243
1386
|
return () => clearInterval(timer);
|
|
@@ -1253,15 +1396,15 @@ function useHostControls() {
|
|
|
1253
1396
|
(participant) => participant.identity === snapshot.localIdentity
|
|
1254
1397
|
);
|
|
1255
1398
|
const actor = me === void 0 ? void 0 : { ...me, role };
|
|
1256
|
-
const [busy, setBusy] = (0,
|
|
1399
|
+
const [busy, setBusy] = (0, import_react5.useState)(false);
|
|
1257
1400
|
const inRoom = host?.inRoom ?? null;
|
|
1258
1401
|
const store = host?.store ?? null;
|
|
1259
1402
|
const notice = snapshot?.actionNotice ?? null;
|
|
1260
|
-
const setNotice = (0,
|
|
1403
|
+
const setNotice = (0, import_react5.useCallback)(
|
|
1261
1404
|
(next) => store?.patch({ actionNotice: next === null ? null : { ...next, at: Date.now() } }),
|
|
1262
1405
|
[store]
|
|
1263
1406
|
);
|
|
1264
|
-
const run = (0,
|
|
1407
|
+
const run = (0, import_react5.useCallback)(
|
|
1265
1408
|
async (request) => {
|
|
1266
1409
|
if (inRoom === null) throw noRuntime(`moderate(${request.action})`);
|
|
1267
1410
|
setBusy(true);
|
|
@@ -1287,19 +1430,19 @@ function useHostControls() {
|
|
|
1287
1430
|
isOwner: role === "host",
|
|
1288
1431
|
notice,
|
|
1289
1432
|
busy,
|
|
1290
|
-
clearNotice: (0,
|
|
1291
|
-
canModerate: (0,
|
|
1433
|
+
clearNotice: (0, import_react5.useCallback)(() => setNotice(null), [setNotice]),
|
|
1434
|
+
canModerate: (0, import_react5.useCallback)(
|
|
1292
1435
|
(target) => canModerateParticipant(actor, target),
|
|
1293
1436
|
[actor]
|
|
1294
1437
|
),
|
|
1295
1438
|
run,
|
|
1296
|
-
mute: (0,
|
|
1439
|
+
mute: (0, import_react5.useCallback)(
|
|
1297
1440
|
async (target) => {
|
|
1298
1441
|
await run({ action: "mute", identity: target.identity });
|
|
1299
1442
|
},
|
|
1300
1443
|
[run]
|
|
1301
1444
|
),
|
|
1302
|
-
remove: (0,
|
|
1445
|
+
remove: (0, import_react5.useCallback)(
|
|
1303
1446
|
async (target) => {
|
|
1304
1447
|
await run({ action: "remove", identity: target.identity });
|
|
1305
1448
|
},
|
|
@@ -1309,7 +1452,7 @@ function useHostControls() {
|
|
|
1309
1452
|
}
|
|
1310
1453
|
function useHandQueue() {
|
|
1311
1454
|
const snapshot = useMeetSnapshot();
|
|
1312
|
-
return (0,
|
|
1455
|
+
return (0, import_react5.useMemo)(
|
|
1313
1456
|
() => (snapshot?.participants ?? []).filter((participant) => participant.handRaised).sort((a, b) => (a.handRaisedAt ?? 0) - (b.handRaisedAt ?? 0)),
|
|
1314
1457
|
[snapshot?.participants]
|
|
1315
1458
|
);
|
|
@@ -1321,7 +1464,7 @@ function useMediaEffects() {
|
|
|
1321
1464
|
return {
|
|
1322
1465
|
effects: snapshot?.effects ?? DEFAULT_EFFECTS,
|
|
1323
1466
|
backgroundsSupported: engine?.supportsVideoEffects() ?? false,
|
|
1324
|
-
set: (0,
|
|
1467
|
+
set: (0, import_react5.useCallback)(
|
|
1325
1468
|
async (next) => requireEngine(engine, "setEffects").setEffects(next),
|
|
1326
1469
|
[engine]
|
|
1327
1470
|
)
|
|
@@ -1332,12 +1475,12 @@ function useModerationNotice() {
|
|
|
1332
1475
|
const snapshot = useMeetSnapshot();
|
|
1333
1476
|
return {
|
|
1334
1477
|
notice: snapshot?.moderationNotice ?? null,
|
|
1335
|
-
dismiss: (0,
|
|
1478
|
+
dismiss: (0, import_react5.useCallback)(() => host?.store.patch({ moderationNotice: null }), [host])
|
|
1336
1479
|
};
|
|
1337
1480
|
}
|
|
1338
1481
|
function useAudioLevel(stream) {
|
|
1339
|
-
const [level, setLevel] = (0,
|
|
1340
|
-
(0,
|
|
1482
|
+
const [level, setLevel] = (0, import_react5.useState)(0);
|
|
1483
|
+
(0, import_react5.useEffect)(() => {
|
|
1341
1484
|
if (stream === null || stream.getAudioTracks().length === 0) {
|
|
1342
1485
|
setLevel(0);
|
|
1343
1486
|
return void 0;
|
|
@@ -1376,9 +1519,9 @@ var MEET_SHORTCUTS = [
|
|
|
1376
1519
|
{ id: "help", keys: "Shift + ?", label: "Show keyboard shortcuts" }
|
|
1377
1520
|
];
|
|
1378
1521
|
function useMeetShortcuts(handlers) {
|
|
1379
|
-
const ref = (0,
|
|
1522
|
+
const ref = (0, import_react5.useRef)(handlers);
|
|
1380
1523
|
ref.current = handlers;
|
|
1381
|
-
(0,
|
|
1524
|
+
(0, import_react5.useEffect)(() => {
|
|
1382
1525
|
const target = globalThis.window;
|
|
1383
1526
|
if (target === void 0) return void 0;
|
|
1384
1527
|
const onKey = (event) => {
|
|
@@ -1407,11 +1550,11 @@ function useGuestRecordAccess(meeting) {
|
|
|
1407
1550
|
const host = useMeetHost();
|
|
1408
1551
|
const api = host?.api ?? null;
|
|
1409
1552
|
const stored = guestRecordAccessSetting(meeting);
|
|
1410
|
-
const [chosen, setChosen] = (0,
|
|
1411
|
-
const [effective, setEffective] = (0,
|
|
1412
|
-
const [saving, setSaving] = (0,
|
|
1413
|
-
const [error, setError] = (0,
|
|
1414
|
-
(0,
|
|
1553
|
+
const [chosen, setChosen] = (0, import_react5.useState)(null);
|
|
1554
|
+
const [effective, setEffective] = (0, import_react5.useState)(null);
|
|
1555
|
+
const [saving, setSaving] = (0, import_react5.useState)(false);
|
|
1556
|
+
const [error, setError] = (0, import_react5.useState)(null);
|
|
1557
|
+
(0, import_react5.useEffect)(() => {
|
|
1415
1558
|
setChosen(null);
|
|
1416
1559
|
}, [stored, meeting?.id]);
|
|
1417
1560
|
return {
|
|
@@ -1419,7 +1562,7 @@ function useGuestRecordAccess(meeting) {
|
|
|
1419
1562
|
effective,
|
|
1420
1563
|
saving,
|
|
1421
1564
|
error,
|
|
1422
|
-
choose: (0,
|
|
1565
|
+
choose: (0, import_react5.useCallback)(
|
|
1423
1566
|
async (next) => {
|
|
1424
1567
|
if (api === null || meeting === null) return;
|
|
1425
1568
|
setSaving(true);
|
|
@@ -1447,74 +1590,8 @@ function useGuestRecordAccess(meeting) {
|
|
|
1447
1590
|
};
|
|
1448
1591
|
}
|
|
1449
1592
|
|
|
1450
|
-
// src/core/collab-state.ts
|
|
1451
|
-
function availableActivities(collab, isHost) {
|
|
1452
|
-
const settings = collab?.settings ?? null;
|
|
1453
|
-
if (settings === null) return [];
|
|
1454
|
-
const out = [];
|
|
1455
|
-
if (settings.whiteboardEnabled) out.push("whiteboard");
|
|
1456
|
-
if (settings.pollsEnabled && (isHost || (collab?.polls.length ?? 0) > 0)) out.push("polls");
|
|
1457
|
-
if (settings.qaEnabled) out.push("qa");
|
|
1458
|
-
if (settings.breakoutsEnabled && (isHost || collab?.breakout?.state === "open")) out.push("breakouts");
|
|
1459
|
-
return out;
|
|
1460
|
-
}
|
|
1461
|
-
function activityAttention(collab, isHost) {
|
|
1462
|
-
if (collab === null) return false;
|
|
1463
|
-
if (collab.polls.some((poll) => poll.state === "live" && poll.myVote.length === 0 && !isHost)) return true;
|
|
1464
|
-
if (isHost && collab.questions.some((q) => q.state === "open")) return true;
|
|
1465
|
-
return false;
|
|
1466
|
-
}
|
|
1467
|
-
async function performCollab(runtime, request) {
|
|
1468
|
-
if (runtime === null) return { ok: false, message: "This meeting is not connected." };
|
|
1469
|
-
try {
|
|
1470
|
-
const result = await runtime.inRoom.collab(request);
|
|
1471
|
-
return { ok: true, message: result.message, itemId: result.itemId };
|
|
1472
|
-
} catch (error) {
|
|
1473
|
-
return { ok: false, message: error.message ?? "That did not work." };
|
|
1474
|
-
}
|
|
1475
|
-
}
|
|
1476
|
-
async function moveToRoom(runtime, roomId) {
|
|
1477
|
-
if (runtime === null) return { ok: false, message: "This meeting is not connected." };
|
|
1478
|
-
try {
|
|
1479
|
-
await runtime.engine.moveToBreakout(roomId);
|
|
1480
|
-
return { ok: true, message: roomId === null ? "Back in the main room." : "Joined the breakout room." };
|
|
1481
|
-
} catch (error) {
|
|
1482
|
-
return { ok: false, message: error.message ?? "That room could not be joined." };
|
|
1483
|
-
}
|
|
1484
|
-
}
|
|
1485
|
-
function untranslatedLines(lines, translations) {
|
|
1486
|
-
return lines.filter((line) => line.final && translations[line.id] === void 0).map(({ id, text }) => ({ id, text }));
|
|
1487
|
-
}
|
|
1488
|
-
function nextTranslationBatch(pending, language, asked) {
|
|
1489
|
-
const batch = pending.filter((line) => !asked.has(`${language}:${line.id}`)).slice(-20);
|
|
1490
|
-
for (const line of batch) asked.add(`${language}:${line.id}`);
|
|
1491
|
-
return batch;
|
|
1492
|
-
}
|
|
1493
|
-
function setCaptionLanguage(store, next) {
|
|
1494
|
-
store.patch({
|
|
1495
|
-
collab: {
|
|
1496
|
-
...store.snapshot().collab,
|
|
1497
|
-
captionLanguage: next,
|
|
1498
|
-
captionTranslations: {},
|
|
1499
|
-
captionTranslationError: null
|
|
1500
|
-
}
|
|
1501
|
-
});
|
|
1502
|
-
}
|
|
1503
|
-
function takePanelRequest(store) {
|
|
1504
|
-
const request = store.snapshot().collab.panelRequest;
|
|
1505
|
-
if (request === null) return null;
|
|
1506
|
-
store.patch({ collab: { ...store.snapshot().collab, panelRequest: null } });
|
|
1507
|
-
return request.panel;
|
|
1508
|
-
}
|
|
1509
|
-
function takeMoveRequest(store) {
|
|
1510
|
-
const request = store.snapshot().collab.moveRequest;
|
|
1511
|
-
if (request === null) return null;
|
|
1512
|
-
store.patch({ collab: { ...store.snapshot().collab, moveRequest: null } });
|
|
1513
|
-
return { roomId: request.roomId };
|
|
1514
|
-
}
|
|
1515
|
-
|
|
1516
1593
|
// src/react/collab-hooks.ts
|
|
1517
|
-
var
|
|
1594
|
+
var import_react7 = require("react");
|
|
1518
1595
|
function useCollab() {
|
|
1519
1596
|
const host = useMeetHost();
|
|
1520
1597
|
const snapshot = useMeetSnapshot();
|
|
@@ -1541,13 +1618,13 @@ function useCaptionTranslation(lines) {
|
|
|
1541
1618
|
const snapshot = useMeetSnapshot();
|
|
1542
1619
|
const collab = snapshot?.collab ?? null;
|
|
1543
1620
|
const language = collab?.captionLanguage ?? null;
|
|
1544
|
-
const asked = (0,
|
|
1621
|
+
const asked = (0, import_react7.useRef)(/* @__PURE__ */ new Set());
|
|
1545
1622
|
const translations = collab?.captionTranslations ?? {};
|
|
1546
1623
|
const missing = untranslatedLines(lines, translations);
|
|
1547
1624
|
const key = `${language ?? ""}|${missing.map((l) => l.id).join(",")}`;
|
|
1548
|
-
const pending = (0,
|
|
1625
|
+
const pending = (0, import_react7.useRef)(missing);
|
|
1549
1626
|
pending.current = missing;
|
|
1550
|
-
(0,
|
|
1627
|
+
(0, import_react7.useEffect)(() => {
|
|
1551
1628
|
if (host === null || language === null) return;
|
|
1552
1629
|
const batch = nextTranslationBatch(pending.current, language, asked.current);
|
|
1553
1630
|
if (batch.length === 0) return;
|
|
@@ -1558,9 +1635,9 @@ function useCaptionTranslation(lines) {
|
|
|
1558
1635
|
function useCollabPanelRequest(onRequest) {
|
|
1559
1636
|
const host = useMeetHost();
|
|
1560
1637
|
const at = useMeetSnapshot()?.collab.panelRequest?.at ?? null;
|
|
1561
|
-
const callback = (0,
|
|
1638
|
+
const callback = (0, import_react7.useRef)(onRequest);
|
|
1562
1639
|
callback.current = onRequest;
|
|
1563
|
-
(0,
|
|
1640
|
+
(0, import_react7.useEffect)(() => {
|
|
1564
1641
|
if (host === null) return;
|
|
1565
1642
|
const panel = takePanelRequest(host.store);
|
|
1566
1643
|
if (panel === null) return;
|
|
@@ -1579,7 +1656,7 @@ function useMeetCore() {
|
|
|
1579
1656
|
const role = useRole();
|
|
1580
1657
|
const isHost = useIsHost();
|
|
1581
1658
|
const observation = useCoreObservation();
|
|
1582
|
-
return (0,
|
|
1659
|
+
return (0, import_react8.useMemo)(
|
|
1583
1660
|
() => ({ host, snapshot, devices, role, isHost, observation }),
|
|
1584
1661
|
[host, snapshot, devices, role, isHost, observation]
|
|
1585
1662
|
);
|
|
@@ -1589,12 +1666,12 @@ function useMeetCore() {
|
|
|
1589
1666
|
var import_design_system = require("@ai-matrx/design-system");
|
|
1590
1667
|
|
|
1591
1668
|
// src/skins/meet/collab.tsx
|
|
1592
|
-
var
|
|
1669
|
+
var import_react9 = require("react");
|
|
1593
1670
|
|
|
1594
1671
|
// src/skins/meet/icons.tsx
|
|
1595
|
-
var
|
|
1672
|
+
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
1596
1673
|
function Icon({ children, ...props }) {
|
|
1597
|
-
return /* @__PURE__ */ (0,
|
|
1674
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
1598
1675
|
"svg",
|
|
1599
1676
|
{
|
|
1600
1677
|
width: "20",
|
|
@@ -1613,227 +1690,227 @@ function Icon({ children, ...props }) {
|
|
|
1613
1690
|
);
|
|
1614
1691
|
}
|
|
1615
1692
|
function MicIcon(props) {
|
|
1616
|
-
return /* @__PURE__ */ (0,
|
|
1617
|
-
/* @__PURE__ */ (0,
|
|
1618
|
-
/* @__PURE__ */ (0,
|
|
1619
|
-
/* @__PURE__ */ (0,
|
|
1693
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1694
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 2a3 3 0 0 0-3 3v7a3 3 0 0 0 6 0V5a3 3 0 0 0-3-3Z" }),
|
|
1695
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M19 10v2a7 7 0 0 1-14 0v-2" }),
|
|
1696
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 19v3" })
|
|
1620
1697
|
] });
|
|
1621
1698
|
}
|
|
1622
1699
|
function MicOffIcon(props) {
|
|
1623
|
-
return /* @__PURE__ */ (0,
|
|
1624
|
-
/* @__PURE__ */ (0,
|
|
1625
|
-
/* @__PURE__ */ (0,
|
|
1626
|
-
/* @__PURE__ */ (0,
|
|
1627
|
-
/* @__PURE__ */ (0,
|
|
1628
|
-
/* @__PURE__ */ (0,
|
|
1700
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1701
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M2 2l20 20" }),
|
|
1702
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M9 9v3a3 3 0 0 0 5.12 2.12" }),
|
|
1703
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M15 9.34V5a3 3 0 0 0-5.94-.6" }),
|
|
1704
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M19 10v2a7 7 0 0 1-.11 1.23M5 10v2a7 7 0 0 0 11 5.66" }),
|
|
1705
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 19v3" })
|
|
1629
1706
|
] });
|
|
1630
1707
|
}
|
|
1631
1708
|
function CameraIcon(props) {
|
|
1632
|
-
return /* @__PURE__ */ (0,
|
|
1633
|
-
/* @__PURE__ */ (0,
|
|
1634
|
-
/* @__PURE__ */ (0,
|
|
1709
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1710
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "m23 7-7 5 7 5V7Z" }),
|
|
1711
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("rect", { x: "1", y: "5", width: "15", height: "14", rx: "2" })
|
|
1635
1712
|
] });
|
|
1636
1713
|
}
|
|
1637
1714
|
function CameraOffIcon(props) {
|
|
1638
|
-
return /* @__PURE__ */ (0,
|
|
1639
|
-
/* @__PURE__ */ (0,
|
|
1640
|
-
/* @__PURE__ */ (0,
|
|
1641
|
-
/* @__PURE__ */ (0,
|
|
1715
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1716
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M2 2l20 20" }),
|
|
1717
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M10.66 5H14a2 2 0 0 1 2 2v3.34l1 1L23 7v10" }),
|
|
1718
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M16 16a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2V7a2 2 0 0 1 2-2h2" })
|
|
1642
1719
|
] });
|
|
1643
1720
|
}
|
|
1644
1721
|
function ScreenShareIcon(props) {
|
|
1645
|
-
return /* @__PURE__ */ (0,
|
|
1646
|
-
/* @__PURE__ */ (0,
|
|
1647
|
-
/* @__PURE__ */ (0,
|
|
1648
|
-
/* @__PURE__ */ (0,
|
|
1722
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1723
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("rect", { x: "2", y: "3", width: "20", height: "14", rx: "2" }),
|
|
1724
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M8 21h8M12 17v4" }),
|
|
1725
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 13V8m0 0-2.5 2.5M12 8l2.5 2.5" })
|
|
1649
1726
|
] });
|
|
1650
1727
|
}
|
|
1651
1728
|
function PhoneIcon(props) {
|
|
1652
|
-
return /* @__PURE__ */ (0,
|
|
1729
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6A19.79 19.79 0 0 1 2.12 4.18 2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72c.13.96.36 1.9.7 2.81a2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45c.9.34 1.85.57 2.81.7A2 2 0 0 1 22 16.92Z" }) });
|
|
1653
1730
|
}
|
|
1654
1731
|
function PhoneOffIcon(props) {
|
|
1655
|
-
return /* @__PURE__ */ (0,
|
|
1732
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon, { fill: "currentColor", stroke: "none", ...props, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 9c-1.6 0-3.15.25-4.6.72v3.1c0 .39-.23.74-.56.9-.98.49-1.87 1.12-2.66 1.85-.18.18-.43.28-.7.28-.28 0-.53-.11-.71-.29L.29 13.08a.99.99 0 0 1-.29-.7c0-.28.11-.53.29-.71C3.34 8.78 7.46 7 12 7s8.66 1.78 11.71 4.67c.18.18.29.43.29.71 0 .28-.11.53-.29.71l-2.48 2.48c-.18.18-.43.29-.71.29-.27 0-.52-.11-.7-.28a11.27 11.27 0 0 0-2.67-1.85.996.996 0 0 1-.56-.9v-3.1C15.15 9.25 13.6 9 12 9Z" }) });
|
|
1656
1733
|
}
|
|
1657
1734
|
function HandIcon(props) {
|
|
1658
|
-
return /* @__PURE__ */ (0,
|
|
1659
|
-
/* @__PURE__ */ (0,
|
|
1660
|
-
/* @__PURE__ */ (0,
|
|
1661
|
-
/* @__PURE__ */ (0,
|
|
1662
|
-
/* @__PURE__ */ (0,
|
|
1735
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1736
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M18 11V6a2 2 0 0 0-4 0v5" }),
|
|
1737
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M14 10V4a2 2 0 0 0-4 0v7" }),
|
|
1738
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M10 10.5V6a2 2 0 0 0-4 0v8" }),
|
|
1739
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M18 8a2 2 0 1 1 4 0v6a8 8 0 0 1-8 8h-2a8 8 0 0 1-8-8v-1a2 2 0 1 1 4 0" })
|
|
1663
1740
|
] });
|
|
1664
1741
|
}
|
|
1665
1742
|
function ChatIcon(props) {
|
|
1666
|
-
return /* @__PURE__ */ (0,
|
|
1743
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2Z" }) });
|
|
1667
1744
|
}
|
|
1668
1745
|
function PeopleIcon(props) {
|
|
1669
|
-
return /* @__PURE__ */ (0,
|
|
1670
|
-
/* @__PURE__ */ (0,
|
|
1671
|
-
/* @__PURE__ */ (0,
|
|
1672
|
-
/* @__PURE__ */ (0,
|
|
1746
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1747
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2" }),
|
|
1748
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("circle", { cx: "9", cy: "7", r: "4" }),
|
|
1749
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M22 21v-2a4 4 0 0 0-3-3.87M16 3.13a4 4 0 0 1 0 7.75" })
|
|
1673
1750
|
] });
|
|
1674
1751
|
}
|
|
1675
1752
|
function RecordIcon(props) {
|
|
1676
|
-
return /* @__PURE__ */ (0,
|
|
1753
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("circle", { cx: "12", cy: "12", r: "8", fill: "currentColor", stroke: "none" }) });
|
|
1677
1754
|
}
|
|
1678
1755
|
function SparklesIcon(props) {
|
|
1679
|
-
return /* @__PURE__ */ (0,
|
|
1680
|
-
/* @__PURE__ */ (0,
|
|
1681
|
-
/* @__PURE__ */ (0,
|
|
1756
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1757
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 3l1.9 4.6L18.5 9.5l-4.6 1.9L12 16l-1.9-4.6L5.5 9.5l4.6-1.9L12 3Z" }),
|
|
1758
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M19 15l.9 2.1 2.1.9-2.1.9-.9 2.1-.9-2.1-2.1-.9 2.1-.9L19 15Z" })
|
|
1682
1759
|
] });
|
|
1683
1760
|
}
|
|
1684
1761
|
function LockIcon(props) {
|
|
1685
|
-
return /* @__PURE__ */ (0,
|
|
1686
|
-
/* @__PURE__ */ (0,
|
|
1687
|
-
/* @__PURE__ */ (0,
|
|
1762
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1763
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("rect", { x: "4", y: "10", width: "16", height: "11", rx: "2" }),
|
|
1764
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M8 10V7a4 4 0 0 1 8 0v3" })
|
|
1688
1765
|
] });
|
|
1689
1766
|
}
|
|
1690
1767
|
function LayoutIcon(props) {
|
|
1691
|
-
return /* @__PURE__ */ (0,
|
|
1692
|
-
/* @__PURE__ */ (0,
|
|
1693
|
-
/* @__PURE__ */ (0,
|
|
1768
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1769
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("rect", { x: "3", y: "3", width: "18", height: "18", rx: "2" }),
|
|
1770
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M3 9h18M9 21V9" })
|
|
1694
1771
|
] });
|
|
1695
1772
|
}
|
|
1696
1773
|
function SettingsIcon(props) {
|
|
1697
|
-
return /* @__PURE__ */ (0,
|
|
1698
|
-
/* @__PURE__ */ (0,
|
|
1699
|
-
/* @__PURE__ */ (0,
|
|
1774
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1775
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("circle", { cx: "12", cy: "12", r: "3" }),
|
|
1776
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 1 1-2.83 2.83l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 1 1-4 0v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 1 1-2.83-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 1 1 0-4h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 1 1 2.83-2.83l.06.06A1.65 1.65 0 0 0 9 4.6a1.65 1.65 0 0 0 1-1.51V3a2 2 0 1 1 4 0v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 1 1 2.83 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 1 1 0 4h-.09a1.65 1.65 0 0 0-1.51 1Z" })
|
|
1700
1777
|
] });
|
|
1701
1778
|
}
|
|
1702
1779
|
function CheckIcon(props) {
|
|
1703
|
-
return /* @__PURE__ */ (0,
|
|
1780
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M20 6 9 17l-5-5" }) });
|
|
1704
1781
|
}
|
|
1705
1782
|
function CloseIcon(props) {
|
|
1706
|
-
return /* @__PURE__ */ (0,
|
|
1783
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M18 6 6 18M6 6l12 12" }) });
|
|
1707
1784
|
}
|
|
1708
1785
|
function PinIcon(props) {
|
|
1709
|
-
return /* @__PURE__ */ (0,
|
|
1710
|
-
/* @__PURE__ */ (0,
|
|
1711
|
-
/* @__PURE__ */ (0,
|
|
1786
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1787
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 17v5" }),
|
|
1788
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M9 2h6l-1 6 3.5 3.5V14H6.5v-2.5L10 8 9 2Z" })
|
|
1712
1789
|
] });
|
|
1713
1790
|
}
|
|
1714
1791
|
function WifiLowIcon(props) {
|
|
1715
|
-
return /* @__PURE__ */ (0,
|
|
1716
|
-
/* @__PURE__ */ (0,
|
|
1717
|
-
/* @__PURE__ */ (0,
|
|
1792
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1793
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 20h.01" }),
|
|
1794
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M8.5 16.5a5 5 0 0 1 7 0" })
|
|
1718
1795
|
] });
|
|
1719
1796
|
}
|
|
1720
1797
|
function SmileIcon(props) {
|
|
1721
|
-
return /* @__PURE__ */ (0,
|
|
1722
|
-
/* @__PURE__ */ (0,
|
|
1723
|
-
/* @__PURE__ */ (0,
|
|
1724
|
-
/* @__PURE__ */ (0,
|
|
1725
|
-
/* @__PURE__ */ (0,
|
|
1798
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1799
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("circle", { cx: "12", cy: "12", r: "10" }),
|
|
1800
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M8 14s1.5 2 4 2 4-2 4-2" }),
|
|
1801
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("line", { x1: "9", x2: "9.01", y1: "9", y2: "9" }),
|
|
1802
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("line", { x1: "15", x2: "15.01", y1: "9", y2: "9" })
|
|
1726
1803
|
] });
|
|
1727
1804
|
}
|
|
1728
1805
|
function MoreIcon(props) {
|
|
1729
|
-
return /* @__PURE__ */ (0,
|
|
1730
|
-
/* @__PURE__ */ (0,
|
|
1731
|
-
/* @__PURE__ */ (0,
|
|
1732
|
-
/* @__PURE__ */ (0,
|
|
1806
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1807
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("circle", { cx: "12", cy: "12", r: "1" }),
|
|
1808
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("circle", { cx: "19", cy: "12", r: "1" }),
|
|
1809
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("circle", { cx: "5", cy: "12", r: "1" })
|
|
1733
1810
|
] });
|
|
1734
1811
|
}
|
|
1735
1812
|
function SearchIcon(props) {
|
|
1736
|
-
return /* @__PURE__ */ (0,
|
|
1737
|
-
/* @__PURE__ */ (0,
|
|
1738
|
-
/* @__PURE__ */ (0,
|
|
1813
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1814
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("circle", { cx: "11", cy: "11", r: "8" }),
|
|
1815
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "m21 21-4.3-4.3" })
|
|
1739
1816
|
] });
|
|
1740
1817
|
}
|
|
1741
1818
|
function KeyboardIcon(props) {
|
|
1742
|
-
return /* @__PURE__ */ (0,
|
|
1743
|
-
/* @__PURE__ */ (0,
|
|
1744
|
-
/* @__PURE__ */ (0,
|
|
1819
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1820
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M10 8h.01M12 12h.01M14 8h.01M16 12h.01M18 8h.01M6 8h.01M7 16h10M8 12h.01" }),
|
|
1821
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("rect", { width: "20", height: "16", x: "2", y: "4", rx: "2" })
|
|
1745
1822
|
] });
|
|
1746
1823
|
}
|
|
1747
1824
|
function SpotlightIcon(props) {
|
|
1748
|
-
return /* @__PURE__ */ (0,
|
|
1825
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 2 15 8.5 22 9.3 17 14 18.2 21 12 17.6 5.8 21 7 14 2 9.3 9 8.5Z" }) });
|
|
1749
1826
|
}
|
|
1750
1827
|
function SignalIcon({ bars, ...props }) {
|
|
1751
|
-
return /* @__PURE__ */ (0,
|
|
1752
|
-
/* @__PURE__ */ (0,
|
|
1753
|
-
/* @__PURE__ */ (0,
|
|
1754
|
-
/* @__PURE__ */ (0,
|
|
1755
|
-
/* @__PURE__ */ (0,
|
|
1828
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1829
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M4 20v-2", opacity: bars >= 1 ? 1 : 0.3 }),
|
|
1830
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M10 20v-6", opacity: bars >= 2 ? 1 : 0.3 }),
|
|
1831
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M16 20V9", opacity: bars >= 3 ? 1 : 0.3 }),
|
|
1832
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M22 20V4", opacity: bars >= 3 ? 1 : 0.3 })
|
|
1756
1833
|
] });
|
|
1757
1834
|
}
|
|
1758
1835
|
function SpeakerIcon(props) {
|
|
1759
|
-
return /* @__PURE__ */ (0,
|
|
1760
|
-
/* @__PURE__ */ (0,
|
|
1761
|
-
/* @__PURE__ */ (0,
|
|
1762
|
-
/* @__PURE__ */ (0,
|
|
1836
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1837
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M11 5 6 9H2v6h4l5 4V5Z" }),
|
|
1838
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M15.54 8.46a5 5 0 0 1 0 7.07" }),
|
|
1839
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M19.07 4.93a10 10 0 0 1 0 14.14" })
|
|
1763
1840
|
] });
|
|
1764
1841
|
}
|
|
1765
1842
|
function FlagIcon(props) {
|
|
1766
|
-
return /* @__PURE__ */ (0,
|
|
1767
|
-
/* @__PURE__ */ (0,
|
|
1768
|
-
/* @__PURE__ */ (0,
|
|
1843
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1844
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M4 15s1-1 4-1 5 2 8 2 4-1 4-1V3s-1 1-4 1-5-2-8-2-4 1-4 1z" }),
|
|
1845
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("line", { x1: "4", x2: "4", y1: "22", y2: "15" })
|
|
1769
1846
|
] });
|
|
1770
1847
|
}
|
|
1771
1848
|
function PencilIcon(props) {
|
|
1772
|
-
return /* @__PURE__ */ (0,
|
|
1849
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M17 3a2.85 2.83 0 1 1 4 4L7.5 20.5 2 22l1.5-5.5Z" }) });
|
|
1773
1850
|
}
|
|
1774
1851
|
function ActivitiesIcon(props) {
|
|
1775
|
-
return /* @__PURE__ */ (0,
|
|
1776
|
-
/* @__PURE__ */ (0,
|
|
1777
|
-
/* @__PURE__ */ (0,
|
|
1778
|
-
/* @__PURE__ */ (0,
|
|
1852
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1853
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M8.3 10a.7.7 0 0 1-.626-1.079L11.4 3a.7.7 0 0 1 1.198-.043L16.3 8.9a.7.7 0 0 1-.572 1.1Z" }),
|
|
1854
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("rect", { x: "3", y: "14", width: "7", height: "7", rx: "1" }),
|
|
1855
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("circle", { cx: "17.5", cy: "17.5", r: "3.5" })
|
|
1779
1856
|
] });
|
|
1780
1857
|
}
|
|
1781
1858
|
function PollIcon(props) {
|
|
1782
|
-
return /* @__PURE__ */ (0,
|
|
1783
|
-
/* @__PURE__ */ (0,
|
|
1784
|
-
/* @__PURE__ */ (0,
|
|
1785
|
-
/* @__PURE__ */ (0,
|
|
1859
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1860
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("line", { x1: "18", x2: "18", y1: "20", y2: "10" }),
|
|
1861
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("line", { x1: "12", x2: "12", y1: "20", y2: "4" }),
|
|
1862
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("line", { x1: "6", x2: "6", y1: "20", y2: "14" })
|
|
1786
1863
|
] });
|
|
1787
1864
|
}
|
|
1788
1865
|
function QuestionIcon(props) {
|
|
1789
|
-
return /* @__PURE__ */ (0,
|
|
1790
|
-
/* @__PURE__ */ (0,
|
|
1791
|
-
/* @__PURE__ */ (0,
|
|
1792
|
-
/* @__PURE__ */ (0,
|
|
1866
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1867
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M7.9 20A9 9 0 1 0 4 16.1L2 22Z" }),
|
|
1868
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3" }),
|
|
1869
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M12 17h.01" })
|
|
1793
1870
|
] });
|
|
1794
1871
|
}
|
|
1795
1872
|
function WhiteboardIcon(props) {
|
|
1796
|
-
return /* @__PURE__ */ (0,
|
|
1797
|
-
/* @__PURE__ */ (0,
|
|
1798
|
-
/* @__PURE__ */ (0,
|
|
1799
|
-
/* @__PURE__ */ (0,
|
|
1873
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1874
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M2 3h20" }),
|
|
1875
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M21 3v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V3" }),
|
|
1876
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "m7 21 5-5 5 5" })
|
|
1800
1877
|
] });
|
|
1801
1878
|
}
|
|
1802
1879
|
function BreakoutIcon(props) {
|
|
1803
|
-
return /* @__PURE__ */ (0,
|
|
1804
|
-
/* @__PURE__ */ (0,
|
|
1805
|
-
/* @__PURE__ */ (0,
|
|
1806
|
-
/* @__PURE__ */ (0,
|
|
1880
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1881
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("rect", { width: "7", height: "18", x: "3", y: "3", rx: "1" }),
|
|
1882
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("rect", { width: "7", height: "7", x: "14", y: "3", rx: "1" }),
|
|
1883
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("rect", { width: "7", height: "7", x: "14", y: "14", rx: "1" })
|
|
1807
1884
|
] });
|
|
1808
1885
|
}
|
|
1809
1886
|
function UpvoteIcon(props) {
|
|
1810
|
-
return /* @__PURE__ */ (0,
|
|
1887
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M9 18v-6H5l7-7 7 7h-4v6H9z" }) });
|
|
1811
1888
|
}
|
|
1812
1889
|
function EraserIcon(props) {
|
|
1813
|
-
return /* @__PURE__ */ (0,
|
|
1814
|
-
/* @__PURE__ */ (0,
|
|
1815
|
-
/* @__PURE__ */ (0,
|
|
1816
|
-
/* @__PURE__ */ (0,
|
|
1890
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1891
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "m7 21-4.3-4.3c-1-1-1-2.5 0-3.4l9.6-9.6c1-1 2.5-1 3.4 0l5.6 5.6c1 1 1 2.5 0 3.4L13 21" }),
|
|
1892
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M22 21H7" }),
|
|
1893
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "m5 11 9 9" })
|
|
1817
1894
|
] });
|
|
1818
1895
|
}
|
|
1819
1896
|
function HighlighterIcon(props) {
|
|
1820
|
-
return /* @__PURE__ */ (0,
|
|
1821
|
-
/* @__PURE__ */ (0,
|
|
1822
|
-
/* @__PURE__ */ (0,
|
|
1897
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1898
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "m9 11-6 6v3h9l3-3" }),
|
|
1899
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "m22 12-4.6 4.6a2 2 0 0 1-2.8 0l-5.2-5.2a2 2 0 0 1 0-2.8L14 4" })
|
|
1823
1900
|
] });
|
|
1824
1901
|
}
|
|
1825
1902
|
function UndoIcon(props) {
|
|
1826
|
-
return /* @__PURE__ */ (0,
|
|
1827
|
-
/* @__PURE__ */ (0,
|
|
1828
|
-
/* @__PURE__ */ (0,
|
|
1903
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Icon, { ...props, children: [
|
|
1904
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M9 14 4 9l5-5" }),
|
|
1905
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("path", { d: "M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11" })
|
|
1829
1906
|
] });
|
|
1830
1907
|
}
|
|
1831
1908
|
|
|
1832
1909
|
// src/skins/meet/collab.tsx
|
|
1833
|
-
var
|
|
1910
|
+
var import_jsx_runtime5 = require("react/jsx-runtime");
|
|
1834
1911
|
function useNotice() {
|
|
1835
|
-
const [notice, setNotice] = (0,
|
|
1836
|
-
(0,
|
|
1912
|
+
const [notice, setNotice] = (0, import_react9.useState)(null);
|
|
1913
|
+
(0, import_react9.useEffect)(() => {
|
|
1837
1914
|
if (notice === null) return void 0;
|
|
1838
1915
|
const timer = setTimeout(() => setNotice(null), notice.failed ? 7e3 : 3e3);
|
|
1839
1916
|
return () => clearTimeout(timer);
|
|
@@ -1842,7 +1919,7 @@ function useNotice() {
|
|
|
1842
1919
|
}
|
|
1843
1920
|
function Notice({ notice }) {
|
|
1844
1921
|
if (notice === null) return null;
|
|
1845
|
-
return /* @__PURE__ */ (0,
|
|
1922
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: notice.failed ? "mx-meet__panel-note mx-meet__collab-error" : "mx-meet__panel-note", role: "status", children: notice.text });
|
|
1846
1923
|
}
|
|
1847
1924
|
var ACTIVITY_LABELS = {
|
|
1848
1925
|
polls: "Polls",
|
|
@@ -1852,25 +1929,25 @@ var ACTIVITY_LABELS = {
|
|
|
1852
1929
|
};
|
|
1853
1930
|
function ActivityIcon({ panel }) {
|
|
1854
1931
|
const props = { width: 16, height: 16 };
|
|
1855
|
-
if (panel === "polls") return /* @__PURE__ */ (0,
|
|
1856
|
-
if (panel === "qa") return /* @__PURE__ */ (0,
|
|
1857
|
-
if (panel === "whiteboard") return /* @__PURE__ */ (0,
|
|
1858
|
-
return /* @__PURE__ */ (0,
|
|
1932
|
+
if (panel === "polls") return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(PollIcon, { ...props });
|
|
1933
|
+
if (panel === "qa") return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(QuestionIcon, { ...props });
|
|
1934
|
+
if (panel === "whiteboard") return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(WhiteboardIcon, { ...props });
|
|
1935
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(BreakoutIcon, { ...props });
|
|
1859
1936
|
}
|
|
1860
1937
|
function ActivitiesControl({
|
|
1861
1938
|
active,
|
|
1862
1939
|
onOpen
|
|
1863
1940
|
}) {
|
|
1864
|
-
const [open, setOpen] = (0,
|
|
1941
|
+
const [open, setOpen] = (0, import_react9.useState)(false);
|
|
1865
1942
|
const available = useAvailableActivities();
|
|
1866
1943
|
const attention = useActivityAttention();
|
|
1867
1944
|
if (available.length === 0) return null;
|
|
1868
|
-
return /* @__PURE__ */ (0,
|
|
1869
|
-
/* @__PURE__ */ (0,
|
|
1870
|
-
/* @__PURE__ */ (0,
|
|
1871
|
-
attention ? /* @__PURE__ */ (0,
|
|
1945
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { className: "mx-meet__anchor", children: [
|
|
1946
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(ControlButton, { label: "Activities", active: open || active !== null, onClick: () => setOpen(!open), children: [
|
|
1947
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(ActivitiesIcon, {}),
|
|
1948
|
+
attention ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__dot", "aria-hidden": "true" }) : null
|
|
1872
1949
|
] }),
|
|
1873
|
-
open ? /* @__PURE__ */ (0,
|
|
1950
|
+
open ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Popover, { label: "Activities", onClose: () => setOpen(false), children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "mx-meet__menu", role: "menu", children: available.map((panel) => /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
1874
1951
|
MenuItem,
|
|
1875
1952
|
{
|
|
1876
1953
|
onSelect: () => {
|
|
@@ -1878,7 +1955,7 @@ function ActivitiesControl({
|
|
|
1878
1955
|
onOpen(panel);
|
|
1879
1956
|
},
|
|
1880
1957
|
children: [
|
|
1881
|
-
/* @__PURE__ */ (0,
|
|
1958
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(ActivityIcon, { panel }),
|
|
1882
1959
|
" ",
|
|
1883
1960
|
ACTIVITY_LABELS[panel]
|
|
1884
1961
|
]
|
|
@@ -1889,11 +1966,11 @@ function ActivitiesControl({
|
|
|
1889
1966
|
}
|
|
1890
1967
|
function PollComposer({ maxOptions, onDone }) {
|
|
1891
1968
|
const { act } = useCollab();
|
|
1892
|
-
const [question, setQuestion] = (0,
|
|
1893
|
-
const [options, setOptions] = (0,
|
|
1894
|
-
const [multiple, setMultiple] = (0,
|
|
1895
|
-
const [anonymous, setAnonymous] = (0,
|
|
1896
|
-
const [busy, setBusy] = (0,
|
|
1969
|
+
const [question, setQuestion] = (0, import_react9.useState)("");
|
|
1970
|
+
const [options, setOptions] = (0, import_react9.useState)(["", ""]);
|
|
1971
|
+
const [multiple, setMultiple] = (0, import_react9.useState)(false);
|
|
1972
|
+
const [anonymous, setAnonymous] = (0, import_react9.useState)(false);
|
|
1973
|
+
const [busy, setBusy] = (0, import_react9.useState)(false);
|
|
1897
1974
|
const [notice, show] = useNotice();
|
|
1898
1975
|
const filled = options.map((o) => o.trim()).filter(Boolean);
|
|
1899
1976
|
const ready = question.trim().length > 0 && filled.length >= 2;
|
|
@@ -1916,7 +1993,7 @@ function PollComposer({ maxOptions, onDone }) {
|
|
|
1916
1993
|
setBusy(false);
|
|
1917
1994
|
onDone();
|
|
1918
1995
|
};
|
|
1919
|
-
return /* @__PURE__ */ (0,
|
|
1996
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
1920
1997
|
"form",
|
|
1921
1998
|
{
|
|
1922
1999
|
className: "mx-meet__collab-card",
|
|
@@ -1925,9 +2002,9 @@ function PollComposer({ maxOptions, onDone }) {
|
|
|
1925
2002
|
if (ready) void save(true);
|
|
1926
2003
|
},
|
|
1927
2004
|
children: [
|
|
1928
|
-
/* @__PURE__ */ (0,
|
|
1929
|
-
/* @__PURE__ */ (0,
|
|
1930
|
-
/* @__PURE__ */ (0,
|
|
2005
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("label", { className: "mx-meet__field", children: [
|
|
2006
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__field-label", children: "Question" }),
|
|
2007
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
1931
2008
|
"input",
|
|
1932
2009
|
{
|
|
1933
2010
|
className: "mx-meet__input",
|
|
@@ -1939,8 +2016,8 @@ function PollComposer({ maxOptions, onDone }) {
|
|
|
1939
2016
|
}
|
|
1940
2017
|
)
|
|
1941
2018
|
] }),
|
|
1942
|
-
options.map((option, index) => /* @__PURE__ */ (0,
|
|
1943
|
-
/* @__PURE__ */ (0,
|
|
2019
|
+
options.map((option, index) => /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mx-meet__composer-row", children: [
|
|
2020
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
1944
2021
|
"input",
|
|
1945
2022
|
{
|
|
1946
2023
|
className: "mx-meet__input",
|
|
@@ -1951,22 +2028,22 @@ function PollComposer({ maxOptions, onDone }) {
|
|
|
1951
2028
|
onChange: (event) => setOptions(options.map((o, i) => i === index ? event.target.value : o))
|
|
1952
2029
|
}
|
|
1953
2030
|
),
|
|
1954
|
-
options.length > 2 ? /* @__PURE__ */ (0,
|
|
2031
|
+
options.length > 2 ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(ControlButton, { label: `Remove answer ${index + 1}`, onClick: () => setOptions(options.filter((_, i) => i !== index)), children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(CloseIcon, { width: 14, height: 14 }) }) : null
|
|
1955
2032
|
] }, index)),
|
|
1956
|
-
options.length < maxOptions ? /* @__PURE__ */ (0,
|
|
1957
|
-
/* @__PURE__ */ (0,
|
|
1958
|
-
/* @__PURE__ */ (0,
|
|
2033
|
+
options.length < maxOptions ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__link", onClick: () => setOptions([...options, ""]), children: "Add an answer" }) : null,
|
|
2034
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("label", { className: "mx-meet__toggle", children: [
|
|
2035
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("input", { type: "checkbox", checked: multiple, onChange: (event) => setMultiple(event.target.checked) }),
|
|
1959
2036
|
"People can pick more than one"
|
|
1960
2037
|
] }),
|
|
1961
|
-
/* @__PURE__ */ (0,
|
|
1962
|
-
/* @__PURE__ */ (0,
|
|
2038
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("label", { className: "mx-meet__toggle", children: [
|
|
2039
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("input", { type: "checkbox", checked: anonymous, onChange: (event) => setAnonymous(event.target.checked) }),
|
|
1963
2040
|
"Anonymous \u2014 nobody sees who picked what"
|
|
1964
2041
|
] }),
|
|
1965
|
-
/* @__PURE__ */ (0,
|
|
1966
|
-
/* @__PURE__ */ (0,
|
|
1967
|
-
/* @__PURE__ */ (0,
|
|
1968
|
-
/* @__PURE__ */ (0,
|
|
1969
|
-
/* @__PURE__ */ (0,
|
|
2042
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Notice, { notice }),
|
|
2043
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mx-meet__collab-actions", children: [
|
|
2044
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "submit", className: "mx-meet__primary mx-meet__primary--small", disabled: !ready || busy, children: "Launch" }),
|
|
2045
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__chip", disabled: !ready || busy, onClick: () => void save(false), children: "Save draft" }),
|
|
2046
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__link", onClick: onDone, children: "Cancel" })
|
|
1970
2047
|
] })
|
|
1971
2048
|
]
|
|
1972
2049
|
}
|
|
@@ -1974,9 +2051,9 @@ function PollComposer({ maxOptions, onDone }) {
|
|
|
1974
2051
|
}
|
|
1975
2052
|
function PollCard({ poll }) {
|
|
1976
2053
|
const { act, isHost } = useCollab();
|
|
1977
|
-
const [picked, setPicked] = (0,
|
|
2054
|
+
const [picked, setPicked] = (0, import_react9.useState)(poll.myVote.slice());
|
|
1978
2055
|
const [notice, show] = useNotice();
|
|
1979
|
-
(0,
|
|
2056
|
+
(0, import_react9.useEffect)(() => setPicked(poll.myVote.slice()), [poll.myVote]);
|
|
1980
2057
|
const counts = poll.options.some((o) => o.votes !== void 0);
|
|
1981
2058
|
const total = poll.options.reduce((sum, o) => sum + (o.votes ?? 0), 0);
|
|
1982
2059
|
const canVote = poll.state === "live";
|
|
@@ -1986,22 +2063,22 @@ function PollCard({ poll }) {
|
|
|
1986
2063
|
if (!canVote) return;
|
|
1987
2064
|
setPicked(poll.multiple ? picked.includes(id) ? picked.filter((p) => p !== id) : [...picked, id] : [id]);
|
|
1988
2065
|
};
|
|
1989
|
-
return /* @__PURE__ */ (0,
|
|
1990
|
-
/* @__PURE__ */ (0,
|
|
1991
|
-
/* @__PURE__ */ (0,
|
|
1992
|
-
/* @__PURE__ */ (0,
|
|
2066
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("article", { className: "mx-meet__collab-card", "aria-label": poll.question, children: [
|
|
2067
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("header", { className: "mx-meet__collab-head", children: [
|
|
2068
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("strong", { className: "mx-meet__collab-title", children: poll.question }),
|
|
2069
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__collab-state", children: stateWord })
|
|
1993
2070
|
] }),
|
|
1994
|
-
/* @__PURE__ */ (0,
|
|
2071
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("p", { className: "mx-meet__panel-note", children: [
|
|
1995
2072
|
poll.multiple ? "Pick any." : "Pick one.",
|
|
1996
2073
|
poll.anonymous ? " Anonymous." : "",
|
|
1997
2074
|
counts && poll.voterCount !== null ? ` ${poll.voterCount} voted.` : "",
|
|
1998
2075
|
isHost && poll.state !== "draft" && !poll.resultsShared ? " Results are visible only to hosts." : ""
|
|
1999
2076
|
] }),
|
|
2000
|
-
/* @__PURE__ */ (0,
|
|
2077
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("ul", { className: "mx-meet__poll-options", children: poll.options.map((option) => {
|
|
2001
2078
|
const share = counts && total > 0 ? Math.round((option.votes ?? 0) / total * 100) : 0;
|
|
2002
2079
|
const chosen = picked.includes(option.id);
|
|
2003
|
-
return /* @__PURE__ */ (0,
|
|
2004
|
-
/* @__PURE__ */ (0,
|
|
2080
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("li", { children: [
|
|
2081
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
2005
2082
|
"button",
|
|
2006
2083
|
{
|
|
2007
2084
|
type: "button",
|
|
@@ -2010,9 +2087,9 @@ function PollCard({ poll }) {
|
|
|
2010
2087
|
disabled: !canVote,
|
|
2011
2088
|
onClick: () => toggle(option.id),
|
|
2012
2089
|
children: [
|
|
2013
|
-
counts ? /* @__PURE__ */ (0,
|
|
2014
|
-
/* @__PURE__ */ (0,
|
|
2015
|
-
counts ? /* @__PURE__ */ (0,
|
|
2090
|
+
counts ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__poll-bar", style: { width: `${share}%` }, "aria-hidden": "true" }) : null,
|
|
2091
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__poll-text", children: option.text }),
|
|
2092
|
+
counts ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { className: "mx-meet__poll-count", children: [
|
|
2016
2093
|
option.votes ?? 0,
|
|
2017
2094
|
" \xB7 ",
|
|
2018
2095
|
share,
|
|
@@ -2021,12 +2098,12 @@ function PollCard({ poll }) {
|
|
|
2021
2098
|
]
|
|
2022
2099
|
}
|
|
2023
2100
|
),
|
|
2024
|
-
option.voters !== void 0 && option.voters.length > 0 ? /* @__PURE__ */ (0,
|
|
2101
|
+
option.voters !== void 0 && option.voters.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__poll-voters", children: option.voters.join(", ") }) : null
|
|
2025
2102
|
] }, option.id);
|
|
2026
2103
|
}) }),
|
|
2027
|
-
/* @__PURE__ */ (0,
|
|
2028
|
-
/* @__PURE__ */ (0,
|
|
2029
|
-
canVote ? /* @__PURE__ */ (0,
|
|
2104
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Notice, { notice }),
|
|
2105
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mx-meet__collab-actions", children: [
|
|
2106
|
+
canVote ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2030
2107
|
"button",
|
|
2031
2108
|
{
|
|
2032
2109
|
type: "button",
|
|
@@ -2036,35 +2113,35 @@ function PollCard({ poll }) {
|
|
|
2036
2113
|
children: voted ? "Change vote" : "Vote"
|
|
2037
2114
|
}
|
|
2038
2115
|
) : null,
|
|
2039
|
-
isHost && poll.state === "draft" ? /* @__PURE__ */ (0,
|
|
2040
|
-
isHost && poll.state === "live" ? /* @__PURE__ */ (0,
|
|
2041
|
-
isHost && poll.state !== "draft" ? /* @__PURE__ */ (0,
|
|
2042
|
-
isHost && poll.state === "live" ? null : isHost ? /* @__PURE__ */ (0,
|
|
2116
|
+
isHost && poll.state === "draft" ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__primary mx-meet__primary--small", onClick: () => void act({ action: "poll_launch", itemId: poll.id }).then(show), children: "Launch" }) : null,
|
|
2117
|
+
isHost && poll.state === "live" ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__chip", onClick: () => void act({ action: "poll_close", itemId: poll.id }).then(show), children: "End poll" }) : null,
|
|
2118
|
+
isHost && poll.state !== "draft" ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__chip", onClick: () => void act({ action: "poll_share", itemId: poll.id }).then(show), children: poll.resultsShared ? "Hide results" : "Share results" }) : null,
|
|
2119
|
+
isHost && poll.state === "live" ? null : isHost ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__link", onClick: () => void act({ action: "poll_delete", itemId: poll.id }).then(show), children: "Delete" }) : null
|
|
2043
2120
|
] })
|
|
2044
2121
|
] });
|
|
2045
2122
|
}
|
|
2046
2123
|
function PollsPanel({ onClose }) {
|
|
2047
2124
|
const { collab, isHost } = useCollab();
|
|
2048
|
-
const [composing, setComposing] = (0,
|
|
2125
|
+
const [composing, setComposing] = (0, import_react9.useState)(false);
|
|
2049
2126
|
const polls = collab?.polls ?? [];
|
|
2050
2127
|
const maxOptions = collab?.settings?.pollMaxOptions ?? 10;
|
|
2051
2128
|
const ordered = [...polls].reverse();
|
|
2052
|
-
return /* @__PURE__ */ (0,
|
|
2053
|
-
collab?.error != null ? /* @__PURE__ */ (0,
|
|
2054
|
-
isHost && !composing ? /* @__PURE__ */ (0,
|
|
2055
|
-
isHost && composing ? /* @__PURE__ */ (0,
|
|
2056
|
-
ordered.length === 0 && !composing ? /* @__PURE__ */ (0,
|
|
2057
|
-
ordered.map((poll) => /* @__PURE__ */ (0,
|
|
2129
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(PanelShell, { title: "Polls", onClose, children: [
|
|
2130
|
+
collab?.error != null ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "mx-meet__panel-note mx-meet__collab-error", children: collab.error }) : null,
|
|
2131
|
+
isHost && !composing ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__primary mx-meet__primary--small", onClick: () => setComposing(true), children: "New poll" }) : null,
|
|
2132
|
+
isHost && composing ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(PollComposer, { maxOptions, onDone: () => setComposing(false) }) : null,
|
|
2133
|
+
ordered.length === 0 && !composing ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "mx-meet__panel-note", children: isHost ? "No polls yet. Polls and their results are kept with the meeting." : "No polls yet." }) : null,
|
|
2134
|
+
ordered.map((poll) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(PollCard, { poll }, poll.id))
|
|
2058
2135
|
] });
|
|
2059
2136
|
}
|
|
2060
2137
|
function QuestionCard({ question }) {
|
|
2061
2138
|
const { act, isHost } = useCollab();
|
|
2062
|
-
const [answering, setAnswering] = (0,
|
|
2063
|
-
const [reply, setReply] = (0,
|
|
2139
|
+
const [answering, setAnswering] = (0, import_react9.useState)(false);
|
|
2140
|
+
const [reply, setReply] = (0, import_react9.useState)("");
|
|
2064
2141
|
const [notice, show] = useNotice();
|
|
2065
|
-
return /* @__PURE__ */ (0,
|
|
2066
|
-
/* @__PURE__ */ (0,
|
|
2067
|
-
/* @__PURE__ */ (0,
|
|
2142
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("li", { className: `mx-meet__collab-card mx-meet__question mx-meet__question--${question.state}`, children: [
|
|
2143
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mx-meet__question-row", children: [
|
|
2144
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
2068
2145
|
"button",
|
|
2069
2146
|
{
|
|
2070
2147
|
type: "button",
|
|
@@ -2074,20 +2151,20 @@ function QuestionCard({ question }) {
|
|
|
2074
2151
|
disabled: question.state === "dismissed",
|
|
2075
2152
|
onClick: () => void act({ action: "question_upvote", itemId: question.id }).then((r) => r.ok ? void 0 : show(r)),
|
|
2076
2153
|
children: [
|
|
2077
|
-
/* @__PURE__ */ (0,
|
|
2078
|
-
/* @__PURE__ */ (0,
|
|
2154
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(UpvoteIcon, { width: 16, height: 16 }),
|
|
2155
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { children: question.upvotes })
|
|
2079
2156
|
]
|
|
2080
2157
|
}
|
|
2081
2158
|
),
|
|
2082
|
-
/* @__PURE__ */ (0,
|
|
2083
|
-
/* @__PURE__ */ (0,
|
|
2084
|
-
/* @__PURE__ */ (0,
|
|
2085
|
-
question.mine && question.anonymous ? /* @__PURE__ */ (0,
|
|
2086
|
-
question.state !== "open" ? /* @__PURE__ */ (0,
|
|
2159
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mx-meet__question-body", children: [
|
|
2160
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { className: "mx-meet__chat-meta", children: [
|
|
2161
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("strong", { children: question.mine ? "You" : question.askerName }),
|
|
2162
|
+
question.mine && question.anonymous ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__chat-private", children: "anonymous" }) : null,
|
|
2163
|
+
question.state !== "open" ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__collab-state", children: question.state === "answered" ? "Answered" : "Dismissed" }) : null
|
|
2087
2164
|
] }),
|
|
2088
|
-
/* @__PURE__ */ (0,
|
|
2089
|
-
question.answer !== null ? /* @__PURE__ */ (0,
|
|
2090
|
-
/* @__PURE__ */ (0,
|
|
2165
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__chat-text", children: question.text }),
|
|
2166
|
+
question.answer !== null ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { className: "mx-meet__question-answer", children: [
|
|
2167
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("strong", { children: [
|
|
2091
2168
|
question.answeredByName ?? "Host",
|
|
2092
2169
|
":"
|
|
2093
2170
|
] }),
|
|
@@ -2096,7 +2173,7 @@ function QuestionCard({ question }) {
|
|
|
2096
2173
|
] }) : null
|
|
2097
2174
|
] })
|
|
2098
2175
|
] }),
|
|
2099
|
-
answering ? /* @__PURE__ */ (0,
|
|
2176
|
+
answering ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
2100
2177
|
"form",
|
|
2101
2178
|
{
|
|
2102
2179
|
className: "mx-meet__composer-row",
|
|
@@ -2111,7 +2188,7 @@ function QuestionCard({ question }) {
|
|
|
2111
2188
|
});
|
|
2112
2189
|
},
|
|
2113
2190
|
children: [
|
|
2114
|
-
/* @__PURE__ */ (0,
|
|
2191
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2115
2192
|
"input",
|
|
2116
2193
|
{
|
|
2117
2194
|
className: "mx-meet__input",
|
|
@@ -2123,24 +2200,24 @@ function QuestionCard({ question }) {
|
|
|
2123
2200
|
autoFocus: true
|
|
2124
2201
|
}
|
|
2125
2202
|
),
|
|
2126
|
-
/* @__PURE__ */ (0,
|
|
2203
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "submit", className: "mx-meet__send", children: "Done" })
|
|
2127
2204
|
]
|
|
2128
2205
|
}
|
|
2129
2206
|
) : null,
|
|
2130
|
-
/* @__PURE__ */ (0,
|
|
2131
|
-
isHost || question.mine ? /* @__PURE__ */ (0,
|
|
2132
|
-
isHost && question.state === "open" && !answering ? /* @__PURE__ */ (0,
|
|
2133
|
-
isHost && question.state === "open" ? /* @__PURE__ */ (0,
|
|
2134
|
-
isHost && question.state !== "open" ? /* @__PURE__ */ (0,
|
|
2135
|
-
question.mine || isHost ? /* @__PURE__ */ (0,
|
|
2207
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Notice, { notice }),
|
|
2208
|
+
isHost || question.mine ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mx-meet__collab-actions", children: [
|
|
2209
|
+
isHost && question.state === "open" && !answering ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__chip", onClick: () => setAnswering(true), children: "Answer" }) : null,
|
|
2210
|
+
isHost && question.state === "open" ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__chip", onClick: () => void act({ action: "question_dismiss", itemId: question.id }).then(show), children: "Dismiss" }) : null,
|
|
2211
|
+
isHost && question.state !== "open" ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__chip", onClick: () => void act({ action: "question_reopen", itemId: question.id }).then(show), children: "Reopen" }) : null,
|
|
2212
|
+
question.mine || isHost ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__link", onClick: () => void act({ action: "question_delete", itemId: question.id }).then(show), children: "Delete" }) : null
|
|
2136
2213
|
] }) : null
|
|
2137
2214
|
] });
|
|
2138
2215
|
}
|
|
2139
2216
|
function QaPanel({ onClose }) {
|
|
2140
2217
|
const { collab, act } = useCollab();
|
|
2141
|
-
const [draft, setDraft] = (0,
|
|
2142
|
-
const [anonymous, setAnonymous] = (0,
|
|
2143
|
-
const [order, setOrder] = (0,
|
|
2218
|
+
const [draft, setDraft] = (0, import_react9.useState)("");
|
|
2219
|
+
const [anonymous, setAnonymous] = (0, import_react9.useState)(false);
|
|
2220
|
+
const [order, setOrder] = (0, import_react9.useState)("popular");
|
|
2144
2221
|
const [notice, show] = useNotice();
|
|
2145
2222
|
const allowAnonymous = collab?.settings?.qaAnonymousAllowed === true;
|
|
2146
2223
|
const questions = [...collab?.questions ?? []];
|
|
@@ -2148,9 +2225,9 @@ function QaPanel({ onClose }) {
|
|
|
2148
2225
|
questions.sort(
|
|
2149
2226
|
(a, b) => rank(a) !== rank(b) ? rank(a) - rank(b) : order === "popular" ? b.upvotes - a.upvotes || (b.createdAt ?? "").localeCompare(a.createdAt ?? "") : (b.createdAt ?? "").localeCompare(a.createdAt ?? "")
|
|
2150
2227
|
);
|
|
2151
|
-
return /* @__PURE__ */ (0,
|
|
2152
|
-
collab?.error != null ? /* @__PURE__ */ (0,
|
|
2153
|
-
/* @__PURE__ */ (0,
|
|
2228
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(PanelShell, { title: "Q&A", onClose, children: [
|
|
2229
|
+
collab?.error != null ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "mx-meet__panel-note mx-meet__collab-error", children: collab.error }) : null,
|
|
2230
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
2154
2231
|
"form",
|
|
2155
2232
|
{
|
|
2156
2233
|
className: "mx-meet__composer mx-meet__composer--chat",
|
|
@@ -2164,8 +2241,8 @@ function QaPanel({ onClose }) {
|
|
|
2164
2241
|
});
|
|
2165
2242
|
},
|
|
2166
2243
|
children: [
|
|
2167
|
-
/* @__PURE__ */ (0,
|
|
2168
|
-
/* @__PURE__ */ (0,
|
|
2244
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mx-meet__composer-row", children: [
|
|
2245
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2169
2246
|
"input",
|
|
2170
2247
|
{
|
|
2171
2248
|
className: "mx-meet__input",
|
|
@@ -2176,17 +2253,17 @@ function QaPanel({ onClose }) {
|
|
|
2176
2253
|
"aria-label": "Ask the host a question"
|
|
2177
2254
|
}
|
|
2178
2255
|
),
|
|
2179
|
-
/* @__PURE__ */ (0,
|
|
2256
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "submit", className: "mx-meet__send", disabled: draft.trim().length === 0, children: "Ask" })
|
|
2180
2257
|
] }),
|
|
2181
|
-
allowAnonymous ? /* @__PURE__ */ (0,
|
|
2182
|
-
/* @__PURE__ */ (0,
|
|
2258
|
+
allowAnonymous ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("label", { className: "mx-meet__toggle", children: [
|
|
2259
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("input", { type: "checkbox", checked: anonymous, onChange: (event) => setAnonymous(event.target.checked) }),
|
|
2183
2260
|
"Ask anonymously"
|
|
2184
2261
|
] }) : null
|
|
2185
2262
|
]
|
|
2186
2263
|
}
|
|
2187
2264
|
),
|
|
2188
|
-
/* @__PURE__ */ (0,
|
|
2189
|
-
questions.length > 1 ? /* @__PURE__ */ (0,
|
|
2265
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Notice, { notice }),
|
|
2266
|
+
questions.length > 1 ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "mx-meet__pills", role: "group", "aria-label": "Order questions", children: ["popular", "recent"].map((value) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2190
2267
|
"button",
|
|
2191
2268
|
{
|
|
2192
2269
|
type: "button",
|
|
@@ -2197,7 +2274,7 @@ function QaPanel({ onClose }) {
|
|
|
2197
2274
|
},
|
|
2198
2275
|
value
|
|
2199
2276
|
)) }) : null,
|
|
2200
|
-
questions.length === 0 ? /* @__PURE__ */ (0,
|
|
2277
|
+
questions.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "mx-meet__panel-note", children: "No questions yet. Questions are kept with the meeting." }) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("ul", { className: "mx-meet__chat", children: questions.map((question) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(QuestionCard, { question }, question.id)) })
|
|
2201
2278
|
] });
|
|
2202
2279
|
}
|
|
2203
2280
|
var BOARD_W = 1600;
|
|
@@ -2211,7 +2288,7 @@ function strokePath(points) {
|
|
|
2211
2288
|
return `${move} ${rest.map(([x, y]) => `L${(x * BOARD_W).toFixed(1)} ${(y * BOARD_H).toFixed(1)}`).join(" ")}`;
|
|
2212
2289
|
}
|
|
2213
2290
|
function StrokeView({ stroke, onPick }) {
|
|
2214
|
-
return /* @__PURE__ */ (0,
|
|
2291
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2215
2292
|
"path",
|
|
2216
2293
|
{
|
|
2217
2294
|
d: strokePath(stroke.points),
|
|
@@ -2223,18 +2300,18 @@ function StrokeView({ stroke, onPick }) {
|
|
|
2223
2300
|
strokeLinejoin: "round",
|
|
2224
2301
|
onPointerDown: onPick,
|
|
2225
2302
|
style: onPick !== void 0 ? { cursor: "pointer" } : void 0,
|
|
2226
|
-
children: /* @__PURE__ */ (0,
|
|
2303
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("title", { children: stroke.byName })
|
|
2227
2304
|
}
|
|
2228
2305
|
);
|
|
2229
2306
|
}
|
|
2230
2307
|
function WhiteboardPanel({ onClose }) {
|
|
2231
2308
|
const { collab, act, isHost, localIdentity } = useCollab();
|
|
2232
|
-
const [tool, setTool] = (0,
|
|
2233
|
-
const [color, setColor] = (0,
|
|
2234
|
-
const [drawing, setDrawing] = (0,
|
|
2235
|
-
const [pending, setPending] = (0,
|
|
2309
|
+
const [tool, setTool] = (0, import_react9.useState)("pen");
|
|
2310
|
+
const [color, setColor] = (0, import_react9.useState)(INK[0]);
|
|
2311
|
+
const [drawing, setDrawing] = (0, import_react9.useState)(null);
|
|
2312
|
+
const [pending, setPending] = (0, import_react9.useState)([]);
|
|
2236
2313
|
const [notice, show] = useNotice();
|
|
2237
|
-
const svgRef = (0,
|
|
2314
|
+
const svgRef = (0, import_react9.useRef)(null);
|
|
2238
2315
|
const strokes = collab?.strokes ?? [];
|
|
2239
2316
|
const mine = strokes.filter((s) => s.by === localIdentity);
|
|
2240
2317
|
const point = (event) => {
|
|
@@ -2266,14 +2343,14 @@ function WhiteboardPanel({ onClose }) {
|
|
|
2266
2343
|
if (!result.ok) show(result);
|
|
2267
2344
|
});
|
|
2268
2345
|
};
|
|
2269
|
-
return /* @__PURE__ */ (0,
|
|
2270
|
-
/* @__PURE__ */ (0,
|
|
2271
|
-
/* @__PURE__ */ (0,
|
|
2272
|
-
/* @__PURE__ */ (0,
|
|
2273
|
-
["pen", "Pen", /* @__PURE__ */ (0,
|
|
2274
|
-
["highlighter", "Highlighter", /* @__PURE__ */ (0,
|
|
2275
|
-
["eraser", "Eraser \u2014 click a stroke", /* @__PURE__ */ (0,
|
|
2276
|
-
].map(([value, label, icon]) => /* @__PURE__ */ (0,
|
|
2346
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("section", { className: "mx-meet__whiteboard", "aria-label": "Whiteboard", children: [
|
|
2347
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("header", { className: "mx-meet__whiteboard-bar", children: [
|
|
2348
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("strong", { className: "mx-meet__panel-title", children: "Whiteboard" }),
|
|
2349
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "mx-meet__pills", role: "group", "aria-label": "Tool", children: [
|
|
2350
|
+
["pen", "Pen", /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(PencilIcon, { width: 16, height: 16 }, "p")],
|
|
2351
|
+
["highlighter", "Highlighter", /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(HighlighterIcon, { width: 16, height: 16 }, "h")],
|
|
2352
|
+
["eraser", "Eraser \u2014 click a stroke", /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(EraserIcon, { width: 16, height: 16 }, "e")]
|
|
2353
|
+
].map(([value, label, icon]) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2277
2354
|
"button",
|
|
2278
2355
|
{
|
|
2279
2356
|
type: "button",
|
|
@@ -2286,7 +2363,7 @@ function WhiteboardPanel({ onClose }) {
|
|
|
2286
2363
|
},
|
|
2287
2364
|
value
|
|
2288
2365
|
)) }),
|
|
2289
|
-
/* @__PURE__ */ (0,
|
|
2366
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "mx-meet__swatches", role: "group", "aria-label": "Color", children: INK.map((ink) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2290
2367
|
"button",
|
|
2291
2368
|
{
|
|
2292
2369
|
type: "button",
|
|
@@ -2301,7 +2378,7 @@ function WhiteboardPanel({ onClose }) {
|
|
|
2301
2378
|
},
|
|
2302
2379
|
ink
|
|
2303
2380
|
)) }),
|
|
2304
|
-
/* @__PURE__ */ (0,
|
|
2381
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2305
2382
|
ControlButton,
|
|
2306
2383
|
{
|
|
2307
2384
|
label: "Undo my last stroke",
|
|
@@ -2309,15 +2386,15 @@ function WhiteboardPanel({ onClose }) {
|
|
|
2309
2386
|
const last = mine[mine.length - 1];
|
|
2310
2387
|
if (last !== void 0) void act({ action: "stroke_erase", itemId: last.id }).then((r) => r.ok ? void 0 : show(r));
|
|
2311
2388
|
},
|
|
2312
|
-
children: /* @__PURE__ */ (0,
|
|
2389
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(UndoIcon, { width: 16, height: 16 })
|
|
2313
2390
|
}
|
|
2314
2391
|
),
|
|
2315
|
-
isHost && strokes.length > 0 ? /* @__PURE__ */ (0,
|
|
2316
|
-
/* @__PURE__ */ (0,
|
|
2317
|
-
/* @__PURE__ */ (0,
|
|
2392
|
+
isHost && strokes.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__chip", onClick: () => void act({ action: "whiteboard_clear" }).then(show), children: "Clear board" }) : null,
|
|
2393
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__whiteboard-note", children: "Saved with the meeting" }),
|
|
2394
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(ControlButton, { label: "Close whiteboard", onClick: onClose, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(CloseIcon, { width: 16, height: 16 }) })
|
|
2318
2395
|
] }),
|
|
2319
|
-
/* @__PURE__ */ (0,
|
|
2320
|
-
/* @__PURE__ */ (0,
|
|
2396
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Notice, { notice }),
|
|
2397
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
2321
2398
|
"svg",
|
|
2322
2399
|
{
|
|
2323
2400
|
ref: svgRef,
|
|
@@ -2341,8 +2418,8 @@ function WhiteboardPanel({ onClose }) {
|
|
|
2341
2418
|
onPointerUp: finish,
|
|
2342
2419
|
onPointerCancel: finish,
|
|
2343
2420
|
children: [
|
|
2344
|
-
/* @__PURE__ */ (0,
|
|
2345
|
-
strokes.map((stroke) => /* @__PURE__ */ (0,
|
|
2421
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("rect", { x: 0, y: 0, width: BOARD_W, height: BOARD_H, className: "mx-meet__board-paper" }),
|
|
2422
|
+
strokes.map((stroke) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2346
2423
|
StrokeView,
|
|
2347
2424
|
{
|
|
2348
2425
|
stroke,
|
|
@@ -2350,8 +2427,8 @@ function WhiteboardPanel({ onClose }) {
|
|
|
2350
2427
|
},
|
|
2351
2428
|
stroke.id
|
|
2352
2429
|
)),
|
|
2353
|
-
pending.map((stroke) => /* @__PURE__ */ (0,
|
|
2354
|
-
drawing !== null ? /* @__PURE__ */ (0,
|
|
2430
|
+
pending.map((stroke) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(StrokeView, { stroke }, stroke.id)),
|
|
2431
|
+
drawing !== null ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2355
2432
|
StrokeView,
|
|
2356
2433
|
{
|
|
2357
2434
|
stroke: {
|
|
@@ -2375,8 +2452,8 @@ function clock(ms) {
|
|
|
2375
2452
|
}
|
|
2376
2453
|
var BREAKOUT_EXPIRE_RETRY_MS = 5e3;
|
|
2377
2454
|
function useNow(active) {
|
|
2378
|
-
const [now, setNow] = (0,
|
|
2379
|
-
(0,
|
|
2455
|
+
const [now, setNow] = (0, import_react9.useState)(() => Date.now());
|
|
2456
|
+
(0, import_react9.useEffect)(() => {
|
|
2380
2457
|
if (!active) return void 0;
|
|
2381
2458
|
const timer = setInterval(() => setNow(Date.now()), 1e3);
|
|
2382
2459
|
return () => clearInterval(timer);
|
|
@@ -2390,11 +2467,11 @@ function BreakoutSetup() {
|
|
|
2390
2467
|
const people = (snapshot?.participants ?? []).filter(
|
|
2391
2468
|
(p) => !p.isAgent && p.role !== "host" && p.role !== "cohost"
|
|
2392
2469
|
);
|
|
2393
|
-
const [count, setCount] = (0,
|
|
2394
|
-
const [mode, setMode] = (0,
|
|
2395
|
-
const [minutes, setMinutes] = (0,
|
|
2396
|
-
const [manual, setManual] = (0,
|
|
2397
|
-
const [busy, setBusy] = (0,
|
|
2470
|
+
const [count, setCount] = (0, import_react9.useState)(Math.min(Math.max(2, Math.ceil(people.length / 4)), settings?.breakoutMaxRooms ?? 20));
|
|
2471
|
+
const [mode, setMode] = (0, import_react9.useState)("auto");
|
|
2472
|
+
const [minutes, setMinutes] = (0, import_react9.useState)(settings?.breakoutDefaultMinutes ?? 15);
|
|
2473
|
+
const [manual, setManual] = (0, import_react9.useState)({});
|
|
2474
|
+
const [busy, setBusy] = (0, import_react9.useState)(false);
|
|
2398
2475
|
const [notice, show] = useNotice();
|
|
2399
2476
|
const max = settings?.breakoutMaxRooms ?? 20;
|
|
2400
2477
|
const rooms = Math.min(Math.max(1, count), max);
|
|
@@ -2406,10 +2483,10 @@ function BreakoutSetup() {
|
|
|
2406
2483
|
(_, index) => people.filter((p) => (manual[p.identity] ?? -1) === index).map((p) => p.identity)
|
|
2407
2484
|
) : Array.from({ length: rooms }, () => []);
|
|
2408
2485
|
const nameOf = (identity) => people.find((p) => p.identity === identity)?.displayName ?? identity;
|
|
2409
|
-
return /* @__PURE__ */ (0,
|
|
2410
|
-
/* @__PURE__ */ (0,
|
|
2411
|
-
/* @__PURE__ */ (0,
|
|
2412
|
-
/* @__PURE__ */ (0,
|
|
2486
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mx-meet__collab-card", children: [
|
|
2487
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("label", { className: "mx-meet__field", children: [
|
|
2488
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__field-label", children: "Rooms" }),
|
|
2489
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2413
2490
|
"input",
|
|
2414
2491
|
{
|
|
2415
2492
|
className: "mx-meet__input",
|
|
@@ -2421,11 +2498,11 @@ function BreakoutSetup() {
|
|
|
2421
2498
|
}
|
|
2422
2499
|
)
|
|
2423
2500
|
] }),
|
|
2424
|
-
/* @__PURE__ */ (0,
|
|
2501
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "mx-meet__pills", role: "group", "aria-label": "How people are placed", children: [
|
|
2425
2502
|
["auto", "Automatically"],
|
|
2426
2503
|
["manual", "Manually"],
|
|
2427
2504
|
["choose", "Let people choose"]
|
|
2428
|
-
].map(([value, label]) => /* @__PURE__ */ (0,
|
|
2505
|
+
].map(([value, label]) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2429
2506
|
"button",
|
|
2430
2507
|
{
|
|
2431
2508
|
type: "button",
|
|
@@ -2436,9 +2513,9 @@ function BreakoutSetup() {
|
|
|
2436
2513
|
},
|
|
2437
2514
|
value
|
|
2438
2515
|
)) }),
|
|
2439
|
-
/* @__PURE__ */ (0,
|
|
2440
|
-
/* @__PURE__ */ (0,
|
|
2441
|
-
/* @__PURE__ */ (0,
|
|
2516
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("label", { className: "mx-meet__field", children: [
|
|
2517
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__field-label", children: "Timer (minutes, 0 for none)" }),
|
|
2518
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2442
2519
|
"input",
|
|
2443
2520
|
{
|
|
2444
2521
|
className: "mx-meet__input",
|
|
@@ -2450,9 +2527,9 @@ function BreakoutSetup() {
|
|
|
2450
2527
|
}
|
|
2451
2528
|
)
|
|
2452
2529
|
] }),
|
|
2453
|
-
mode === "manual" ? people.length === 0 ? /* @__PURE__ */ (0,
|
|
2454
|
-
/* @__PURE__ */ (0,
|
|
2455
|
-
/* @__PURE__ */ (0,
|
|
2530
|
+
mode === "manual" ? people.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "mx-meet__panel-note", children: "Nobody else is in the meeting yet." }) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("ul", { className: "mx-meet__people", children: people.map((person) => /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("li", { className: "mx-meet__person", children: [
|
|
2531
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__person-name", children: person.displayName }),
|
|
2532
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
2456
2533
|
"select",
|
|
2457
2534
|
{
|
|
2458
2535
|
className: "mx-meet__select mx-meet__select--compact",
|
|
@@ -2460,24 +2537,24 @@ function BreakoutSetup() {
|
|
|
2460
2537
|
value: manual[person.identity] ?? -1,
|
|
2461
2538
|
onChange: (event) => setManual({ ...manual, [person.identity]: Number(event.target.value) }),
|
|
2462
2539
|
children: [
|
|
2463
|
-
/* @__PURE__ */ (0,
|
|
2464
|
-
Array.from({ length: rooms }, (_, index) => /* @__PURE__ */ (0,
|
|
2540
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("option", { value: -1, children: "Main room" }),
|
|
2541
|
+
Array.from({ length: rooms }, (_, index) => /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("option", { value: index, children: [
|
|
2465
2542
|
"Room ",
|
|
2466
2543
|
index + 1
|
|
2467
2544
|
] }, index))
|
|
2468
2545
|
]
|
|
2469
2546
|
}
|
|
2470
2547
|
)
|
|
2471
|
-
] }, person.identity)) }) : mode === "auto" ? /* @__PURE__ */ (0,
|
|
2472
|
-
/* @__PURE__ */ (0,
|
|
2548
|
+
] }, person.identity)) }) : mode === "auto" ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("ul", { className: "mx-meet__breakout-rooms", children: assignment.map((members, index) => /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("li", { children: [
|
|
2549
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("strong", { children: [
|
|
2473
2550
|
"Room ",
|
|
2474
2551
|
index + 1
|
|
2475
2552
|
] }),
|
|
2476
2553
|
" ",
|
|
2477
|
-
/* @__PURE__ */ (0,
|
|
2478
|
-
] }, index)) }) : /* @__PURE__ */ (0,
|
|
2479
|
-
/* @__PURE__ */ (0,
|
|
2480
|
-
/* @__PURE__ */ (0,
|
|
2554
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__panel-note", children: members.length === 0 ? "empty" : members.map(nameOf).join(", ") })
|
|
2555
|
+
] }, index)) }) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "mx-meet__panel-note", children: "Everyone picks a room from their own screen." }),
|
|
2556
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Notice, { notice }),
|
|
2557
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
2481
2558
|
"button",
|
|
2482
2559
|
{
|
|
2483
2560
|
type: "button",
|
|
@@ -2510,7 +2587,7 @@ function BreakoutRun({ plan }) {
|
|
|
2510
2587
|
const snapshot = useMeetSnapshot();
|
|
2511
2588
|
const now = useNow(plan.endsAt !== null);
|
|
2512
2589
|
const remaining = breakoutRemainingMs(plan, now);
|
|
2513
|
-
const [broadcast, setBroadcast] = (0,
|
|
2590
|
+
const [broadcast, setBroadcast] = (0, import_react9.useState)("");
|
|
2514
2591
|
const [notice, show] = useNotice();
|
|
2515
2592
|
const nameOf = (identity) => displayNameFor(snapshot?.names ?? {}, identity, snapshot?.participants.find((p) => p.identity === identity)?.displayName);
|
|
2516
2593
|
const mine = assignedRoom(plan, localIdentity);
|
|
@@ -2522,8 +2599,8 @@ function BreakoutRun({ plan }) {
|
|
|
2522
2599
|
}
|
|
2523
2600
|
show(await moveTo(roomId));
|
|
2524
2601
|
};
|
|
2525
|
-
return /* @__PURE__ */ (0,
|
|
2526
|
-
/* @__PURE__ */ (0,
|
|
2602
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mx-meet__collab-card", children: [
|
|
2603
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("p", { className: "mx-meet__panel-note", children: [
|
|
2527
2604
|
plan.rooms.length,
|
|
2528
2605
|
" room",
|
|
2529
2606
|
plan.rooms.length === 1 ? "" : "s",
|
|
@@ -2531,18 +2608,18 @@ function BreakoutRun({ plan }) {
|
|
|
2531
2608
|
remaining !== null ? ` \xB7 ${clock(remaining)} left` : "",
|
|
2532
2609
|
plan.allowChoose ? " \xB7 people choose their room" : ""
|
|
2533
2610
|
] }),
|
|
2534
|
-
/* @__PURE__ */ (0,
|
|
2611
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("ul", { className: "mx-meet__breakout-rooms", children: plan.rooms.map((room) => {
|
|
2535
2612
|
const here = breakoutRoomId === room.id;
|
|
2536
2613
|
const mayJoin = isHost || plan.allowChoose || mine?.id === room.id;
|
|
2537
|
-
return /* @__PURE__ */ (0,
|
|
2538
|
-
/* @__PURE__ */ (0,
|
|
2539
|
-
/* @__PURE__ */ (0,
|
|
2540
|
-
here ? /* @__PURE__ */ (0,
|
|
2614
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("li", { className: here ? "mx-meet__breakout-room mx-meet__breakout-room--here" : "mx-meet__breakout-room", children: [
|
|
2615
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mx-meet__collab-head", children: [
|
|
2616
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("strong", { children: room.name }),
|
|
2617
|
+
here ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__collab-state", children: "You are here" }) : mayJoin ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__chip", onClick: () => void join(room.id), children: "Join" }) : null
|
|
2541
2618
|
] }),
|
|
2542
|
-
/* @__PURE__ */ (0,
|
|
2543
|
-
isHost && room.identities.length > 0 ? /* @__PURE__ */ (0,
|
|
2544
|
-
/* @__PURE__ */ (0,
|
|
2545
|
-
/* @__PURE__ */ (0,
|
|
2619
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__panel-note", children: room.identities.length === 0 ? "Nobody assigned" : room.identities.map(nameOf).join(", ") }),
|
|
2620
|
+
isHost && room.identities.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("ul", { className: "mx-meet__people", children: room.identities.map((identity) => /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("li", { className: "mx-meet__person", children: [
|
|
2621
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__person-name", children: nameOf(identity) }),
|
|
2622
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
2546
2623
|
"select",
|
|
2547
2624
|
{
|
|
2548
2625
|
className: "mx-meet__select mx-meet__select--compact",
|
|
@@ -2554,16 +2631,16 @@ function BreakoutRun({ plan }) {
|
|
|
2554
2631
|
roomId: event.target.value === "" ? null : event.target.value
|
|
2555
2632
|
}).then(show),
|
|
2556
2633
|
children: [
|
|
2557
|
-
/* @__PURE__ */ (0,
|
|
2558
|
-
plan.rooms.map((option) => /* @__PURE__ */ (0,
|
|
2634
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("option", { value: "", children: "Main room" }),
|
|
2635
|
+
plan.rooms.map((option) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("option", { value: option.id, children: option.name }, option.id))
|
|
2559
2636
|
]
|
|
2560
2637
|
}
|
|
2561
2638
|
)
|
|
2562
2639
|
] }, identity)) }) : null
|
|
2563
2640
|
] }, room.id);
|
|
2564
2641
|
}) }),
|
|
2565
|
-
breakoutRoomId !== null ? /* @__PURE__ */ (0,
|
|
2566
|
-
isHost ? /* @__PURE__ */ (0,
|
|
2642
|
+
breakoutRoomId !== null ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__chip", onClick: () => void join(null), children: "Return to the main room" }) : null,
|
|
2643
|
+
isHost ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
2567
2644
|
"form",
|
|
2568
2645
|
{
|
|
2569
2646
|
className: "mx-meet__composer-row",
|
|
@@ -2577,7 +2654,7 @@ function BreakoutRun({ plan }) {
|
|
|
2577
2654
|
});
|
|
2578
2655
|
},
|
|
2579
2656
|
children: [
|
|
2580
|
-
/* @__PURE__ */ (0,
|
|
2657
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2581
2658
|
"input",
|
|
2582
2659
|
{
|
|
2583
2660
|
className: "mx-meet__input",
|
|
@@ -2588,12 +2665,12 @@ function BreakoutRun({ plan }) {
|
|
|
2588
2665
|
"aria-label": "Message every room"
|
|
2589
2666
|
}
|
|
2590
2667
|
),
|
|
2591
|
-
/* @__PURE__ */ (0,
|
|
2668
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "submit", className: "mx-meet__send", disabled: broadcast.trim().length === 0, children: "Send" })
|
|
2592
2669
|
]
|
|
2593
2670
|
}
|
|
2594
2671
|
) : null,
|
|
2595
|
-
/* @__PURE__ */ (0,
|
|
2596
|
-
isHost ? /* @__PURE__ */ (0,
|
|
2672
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Notice, { notice }),
|
|
2673
|
+
isHost ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2597
2674
|
"button",
|
|
2598
2675
|
{
|
|
2599
2676
|
type: "button",
|
|
@@ -2607,9 +2684,9 @@ function BreakoutRun({ plan }) {
|
|
|
2607
2684
|
function BreakoutsPanel({ onClose }) {
|
|
2608
2685
|
const { collab, isHost } = useCollab();
|
|
2609
2686
|
const plan = collab?.breakout?.state === "open" ? collab.breakout : null;
|
|
2610
|
-
return /* @__PURE__ */ (0,
|
|
2611
|
-
collab?.error != null ? /* @__PURE__ */ (0,
|
|
2612
|
-
plan !== null ? /* @__PURE__ */ (0,
|
|
2687
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(PanelShell, { title: "Breakout rooms", onClose, children: [
|
|
2688
|
+
collab?.error != null ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "mx-meet__panel-note mx-meet__collab-error", children: collab.error }) : null,
|
|
2689
|
+
plan !== null ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(BreakoutRun, { plan }) : isHost ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(BreakoutSetup, {}) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "mx-meet__panel-note", children: "Breakout rooms are closed." })
|
|
2613
2690
|
] });
|
|
2614
2691
|
}
|
|
2615
2692
|
function BreakoutBanner() {
|
|
@@ -2620,11 +2697,11 @@ function BreakoutBanner() {
|
|
|
2620
2697
|
const now = useNow(open?.endsAt != null);
|
|
2621
2698
|
const remaining = breakoutRemainingMs(open, now);
|
|
2622
2699
|
const assigned = assignedRoom(open, localIdentity);
|
|
2623
|
-
const [dismissedBroadcast, setDismissedBroadcast] = (0,
|
|
2624
|
-
const [failure, setFailure] = (0,
|
|
2625
|
-
const expireAsked = (0,
|
|
2700
|
+
const [dismissedBroadcast, setDismissedBroadcast] = (0, import_react9.useState)(null);
|
|
2701
|
+
const [failure, setFailure] = (0, import_react9.useState)(null);
|
|
2702
|
+
const expireAsked = (0, import_react9.useRef)(null);
|
|
2626
2703
|
const moveAt = collab?.moveRequest?.at ?? null;
|
|
2627
|
-
(0,
|
|
2704
|
+
(0, import_react9.useEffect)(() => {
|
|
2628
2705
|
if (host === null) return;
|
|
2629
2706
|
const request = takeMoveRequest(host.store);
|
|
2630
2707
|
if (request === null) return;
|
|
@@ -2632,7 +2709,7 @@ function BreakoutBanner() {
|
|
|
2632
2709
|
if ((here ?? null) === request.roomId) return;
|
|
2633
2710
|
void moveTo(request.roomId).then((result) => setFailure(result.ok ? null : result.message));
|
|
2634
2711
|
}, [moveAt, host, moveTo]);
|
|
2635
|
-
(0,
|
|
2712
|
+
(0, import_react9.useEffect)(() => {
|
|
2636
2713
|
if (open === null || remaining === null || remaining > 0) return;
|
|
2637
2714
|
const asked = expireAsked.current;
|
|
2638
2715
|
if (asked !== null && asked.id === open.id && now - asked.at < BREAKOUT_EXPIRE_RETRY_MS) return;
|
|
@@ -2643,17 +2720,17 @@ function BreakoutBanner() {
|
|
|
2643
2720
|
const showBroadcast = broadcast !== null && broadcast.at !== dismissedBroadcast && open !== null;
|
|
2644
2721
|
const room = open?.rooms.find((r) => r.id === breakoutRoomId) ?? null;
|
|
2645
2722
|
if (open === null && failure === null) return null;
|
|
2646
|
-
return /* @__PURE__ */ (0,
|
|
2647
|
-
failure !== null ? /* @__PURE__ */ (0,
|
|
2648
|
-
room !== null ? /* @__PURE__ */ (0,
|
|
2649
|
-
/* @__PURE__ */ (0,
|
|
2723
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mx-meet__breakout-banner", role: "status", children: [
|
|
2724
|
+
failure !== null ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__collab-error", children: failure }) : null,
|
|
2725
|
+
room !== null ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { children: [
|
|
2726
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("strong", { children: room.name }),
|
|
2650
2727
|
remaining !== null ? ` \xB7 ${clock(remaining)} left` : "",
|
|
2651
|
-
/* @__PURE__ */ (0,
|
|
2652
|
-
] }) : assigned !== null ? /* @__PURE__ */ (0,
|
|
2728
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__chip", onClick: () => void moveTo(null), children: "Return to main room" })
|
|
2729
|
+
] }) : assigned !== null ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { children: [
|
|
2653
2730
|
"You are assigned to ",
|
|
2654
|
-
/* @__PURE__ */ (0,
|
|
2731
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("strong", { children: assigned.name }),
|
|
2655
2732
|
remaining !== null ? ` \xB7 ${clock(remaining)} left` : "",
|
|
2656
|
-
/* @__PURE__ */ (0,
|
|
2733
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
2657
2734
|
"button",
|
|
2658
2735
|
{
|
|
2659
2736
|
type: "button",
|
|
@@ -2665,15 +2742,15 @@ function BreakoutBanner() {
|
|
|
2665
2742
|
children: "Join"
|
|
2666
2743
|
}
|
|
2667
2744
|
)
|
|
2668
|
-
] }) : open?.allowChoose ? /* @__PURE__ */ (0,
|
|
2669
|
-
showBroadcast ? /* @__PURE__ */ (0,
|
|
2670
|
-
/* @__PURE__ */ (0,
|
|
2745
|
+
] }) : open?.allowChoose ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { children: "Breakout rooms are open \u2014 pick one under Activities." }) : null,
|
|
2746
|
+
showBroadcast ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { className: "mx-meet__breakout-broadcast", children: [
|
|
2747
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("strong", { children: [
|
|
2671
2748
|
broadcast.by,
|
|
2672
2749
|
":"
|
|
2673
2750
|
] }),
|
|
2674
2751
|
" ",
|
|
2675
2752
|
broadcast.text,
|
|
2676
|
-
/* @__PURE__ */ (0,
|
|
2753
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { type: "button", className: "mx-meet__link", onClick: () => setDismissedBroadcast(broadcast.at), children: "Dismiss" })
|
|
2677
2754
|
] }) : null
|
|
2678
2755
|
] });
|
|
2679
2756
|
}
|
|
@@ -2687,10 +2764,10 @@ function CaptionLanguageSettings() {
|
|
|
2687
2764
|
const preferred = defaultCaptionLanguage(settings, viewer);
|
|
2688
2765
|
const current = collab?.captionLanguage ?? "";
|
|
2689
2766
|
const choices = CAPTION_LANGUAGES.some((l) => l.tag === preferred) ? CAPTION_LANGUAGES : [{ tag: preferred, name: preferred }, ...CAPTION_LANGUAGES];
|
|
2690
|
-
return /* @__PURE__ */ (0,
|
|
2691
|
-
/* @__PURE__ */ (0,
|
|
2692
|
-
/* @__PURE__ */ (0,
|
|
2693
|
-
/* @__PURE__ */ (0,
|
|
2767
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("section", { className: "mx-meet__section", "aria-label": "Captions", children: [
|
|
2768
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("label", { className: "mx-meet__field", children: [
|
|
2769
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "mx-meet__field-label", children: "Translate captions to" }),
|
|
2770
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
2694
2771
|
"select",
|
|
2695
2772
|
{
|
|
2696
2773
|
className: "mx-meet__select",
|
|
@@ -2700,29 +2777,29 @@ function CaptionLanguageSettings() {
|
|
|
2700
2777
|
setCaptionLanguage(host.store, next);
|
|
2701
2778
|
},
|
|
2702
2779
|
children: [
|
|
2703
|
-
/* @__PURE__ */ (0,
|
|
2704
|
-
current === "" ? /* @__PURE__ */ (0,
|
|
2780
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("option", { value: "", children: "Off \u2014 as spoken" }),
|
|
2781
|
+
current === "" ? /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("option", { value: preferred, children: [
|
|
2705
2782
|
choices.find((c) => c.tag === preferred)?.name ?? preferred,
|
|
2706
2783
|
" (yours)"
|
|
2707
2784
|
] }) : null,
|
|
2708
|
-
choices.filter((choice) => current !== "" || choice.tag !== preferred).map((choice) => /* @__PURE__ */ (0,
|
|
2785
|
+
choices.filter((choice) => current !== "" || choice.tag !== preferred).map((choice) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("option", { value: choice.tag, children: choice.name }, choice.tag))
|
|
2709
2786
|
]
|
|
2710
2787
|
}
|
|
2711
2788
|
)
|
|
2712
2789
|
] }),
|
|
2713
|
-
collab?.captionTranslationError != null ? /* @__PURE__ */ (0,
|
|
2790
|
+
collab?.captionTranslationError != null ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "mx-meet__panel-note mx-meet__collab-error", children: collab.captionTranslationError }) : null
|
|
2714
2791
|
] });
|
|
2715
2792
|
}
|
|
2716
2793
|
|
|
2717
2794
|
// src/skins/meet/components.tsx
|
|
2718
|
-
var
|
|
2795
|
+
var import_jsx_runtime6 = require("react/jsx-runtime");
|
|
2719
2796
|
function InertNotice({ what }) {
|
|
2720
|
-
return /* @__PURE__ */ (0,
|
|
2721
|
-
/* @__PURE__ */ (0,
|
|
2797
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__empty", role: "status", children: [
|
|
2798
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("p", { className: "mx-meet__empty-title", children: [
|
|
2722
2799
|
what,
|
|
2723
2800
|
" is not ready yet"
|
|
2724
2801
|
] }),
|
|
2725
|
-
/* @__PURE__ */ (0,
|
|
2802
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__empty-body", children: "Calls and meetings need a signed-in identity and an active organization. This will appear as soon as they resolve." })
|
|
2726
2803
|
] });
|
|
2727
2804
|
}
|
|
2728
2805
|
function Avatar({
|
|
@@ -2732,7 +2809,7 @@ function Avatar({
|
|
|
2732
2809
|
}) {
|
|
2733
2810
|
const tint = (0, import_format2.avatarPaletteIndex)(name);
|
|
2734
2811
|
if (url != null && url.length > 0) {
|
|
2735
|
-
return /* @__PURE__ */ (0,
|
|
2812
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
2736
2813
|
"img",
|
|
2737
2814
|
{
|
|
2738
2815
|
className: "mx-meet__avatar",
|
|
@@ -2744,7 +2821,7 @@ function Avatar({
|
|
|
2744
2821
|
}
|
|
2745
2822
|
);
|
|
2746
2823
|
}
|
|
2747
|
-
return /* @__PURE__ */ (0,
|
|
2824
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
2748
2825
|
"span",
|
|
2749
2826
|
{
|
|
2750
2827
|
className: "mx-meet__avatar mx-meet__avatar--initials",
|
|
@@ -2766,7 +2843,7 @@ function ControlButton({
|
|
|
2766
2843
|
onClick,
|
|
2767
2844
|
children
|
|
2768
2845
|
}) {
|
|
2769
|
-
return /* @__PURE__ */ (0,
|
|
2846
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
2770
2847
|
"button",
|
|
2771
2848
|
{
|
|
2772
2849
|
type: "button",
|
|
@@ -2785,14 +2862,14 @@ function ControlButton({
|
|
|
2785
2862
|
function RecordingIndicator() {
|
|
2786
2863
|
const { state, label } = useRecording();
|
|
2787
2864
|
if (label === null) return null;
|
|
2788
|
-
return /* @__PURE__ */ (0,
|
|
2865
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
2789
2866
|
"span",
|
|
2790
2867
|
{
|
|
2791
2868
|
className: `mx-meet__recording mx-meet__recording--${state}`,
|
|
2792
2869
|
role: "status",
|
|
2793
2870
|
"aria-live": "polite",
|
|
2794
2871
|
children: [
|
|
2795
|
-
/* @__PURE__ */ (0,
|
|
2872
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(RecordIcon, { width: 10, height: 10 }),
|
|
2796
2873
|
label
|
|
2797
2874
|
]
|
|
2798
2875
|
}
|
|
@@ -2800,15 +2877,16 @@ function RecordingIndicator() {
|
|
|
2800
2877
|
}
|
|
2801
2878
|
function ConnectionDot({ quality }) {
|
|
2802
2879
|
if (quality === "excellent" || quality === "good" || quality === "unknown") return null;
|
|
2803
|
-
return /* @__PURE__ */ (0,
|
|
2880
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: `mx-meet__quality mx-meet__quality--${quality}`, title: `Connection ${quality}`, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(WifiLowIcon, { width: 14, height: 14 }) });
|
|
2804
2881
|
}
|
|
2805
2882
|
function RoleBadge({
|
|
2806
2883
|
role,
|
|
2807
2884
|
standing
|
|
2808
2885
|
}) {
|
|
2809
|
-
if (role === "host") return /* @__PURE__ */ (0,
|
|
2810
|
-
if (role === "cohost") return /* @__PURE__ */ (0,
|
|
2811
|
-
if (
|
|
2886
|
+
if (role === "host") return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__badge", children: "Host" });
|
|
2887
|
+
if (role === "cohost") return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__badge", children: "Co-host" });
|
|
2888
|
+
if (isObserverRole(role)) return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__badge", "data-meet-observing": "", children: "Observing" });
|
|
2889
|
+
if (isLinkFollower(standing)) return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__badge", children: "Guest" });
|
|
2812
2890
|
return null;
|
|
2813
2891
|
}
|
|
2814
2892
|
function ParticipantTile({
|
|
@@ -2818,7 +2896,7 @@ function ParticipantTile({
|
|
|
2818
2896
|
const host = useMeetHost();
|
|
2819
2897
|
const snapshot = useMeetSnapshot();
|
|
2820
2898
|
const queue = useHandQueue();
|
|
2821
|
-
const [menu, setMenu] = (0,
|
|
2899
|
+
const [menu, setMenu] = (0, import_react10.useState)(false);
|
|
2822
2900
|
const videoRef = useTrack(
|
|
2823
2901
|
participant.identity,
|
|
2824
2902
|
participant.screenSharing ? "screen" : "camera"
|
|
@@ -2827,7 +2905,7 @@ function ParticipantTile({
|
|
|
2827
2905
|
const pinnedHere = snapshot?.pinned === participant.identity;
|
|
2828
2906
|
const spotlit = snapshot?.spotlight === participant.identity;
|
|
2829
2907
|
const handPosition = participant.handRaised ? queue.findIndex((entry) => entry.identity === participant.identity) + 1 : 0;
|
|
2830
|
-
return /* @__PURE__ */ (0,
|
|
2908
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
2831
2909
|
"div",
|
|
2832
2910
|
{
|
|
2833
2911
|
className: [
|
|
@@ -2838,7 +2916,7 @@ function ParticipantTile({
|
|
|
2838
2916
|
"data-identity": participant.identity,
|
|
2839
2917
|
...participantAttributes(participant),
|
|
2840
2918
|
children: [
|
|
2841
|
-
showVideo ? /* @__PURE__ */ (0,
|
|
2919
|
+
showVideo ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
2842
2920
|
"video",
|
|
2843
2921
|
{
|
|
2844
2922
|
ref: videoRef,
|
|
@@ -2847,43 +2925,43 @@ function ParticipantTile({
|
|
|
2847
2925
|
playsInline: true,
|
|
2848
2926
|
muted: participant.isLocal
|
|
2849
2927
|
}
|
|
2850
|
-
) : /* @__PURE__ */ (0,
|
|
2851
|
-
participant.handRaised ? /* @__PURE__ */ (0,
|
|
2852
|
-
/* @__PURE__ */ (0,
|
|
2928
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__tile-placeholder", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Avatar, { name: participant.displayName, url: participant.avatarUrl, size: featured ? 96 : 56 }) }),
|
|
2929
|
+
participant.handRaised ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__tile-hand", title: `Hand raised \xB7 ${ordinal(handPosition)} in line`, children: [
|
|
2930
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(HandIcon, { width: 14, height: 14 }),
|
|
2853
2931
|
handPosition > 0 ? handPosition : null
|
|
2854
2932
|
] }) : null,
|
|
2855
|
-
/* @__PURE__ */ (0,
|
|
2856
|
-
/* @__PURE__ */ (0,
|
|
2857
|
-
spotlit ? /* @__PURE__ */ (0,
|
|
2933
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__tile-bar", children: [
|
|
2934
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__tile-name", children: [
|
|
2935
|
+
spotlit ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { title: "Spotlighted for everyone", className: "mx-meet__tile-flag", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SpotlightIcon, { width: 12, height: 12 }) }) : null,
|
|
2858
2936
|
participant.displayName,
|
|
2859
2937
|
participant.isLocal ? " (you)" : "",
|
|
2860
|
-
participant.isAgent ? /* @__PURE__ */ (0,
|
|
2861
|
-
/* @__PURE__ */ (0,
|
|
2938
|
+
participant.isAgent ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__badge", children: "AI" }) : null,
|
|
2939
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(RoleBadge, { role: participant.role, standing: participant.standing })
|
|
2862
2940
|
] }),
|
|
2863
|
-
!participant.micEnabled ? /* @__PURE__ */ (0,
|
|
2864
|
-
/* @__PURE__ */ (0,
|
|
2941
|
+
!participant.micEnabled ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MicOffIcon, { width: 14, height: 14 }) : null,
|
|
2942
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(QualityBars, { quality: participant.quality })
|
|
2865
2943
|
] }),
|
|
2866
|
-
/* @__PURE__ */ (0,
|
|
2867
|
-
/* @__PURE__ */ (0,
|
|
2944
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: menu ? "mx-meet__tile-actions mx-meet__tile-actions--open" : "mx-meet__tile-actions", children: [
|
|
2945
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
2868
2946
|
ControlButton,
|
|
2869
2947
|
{
|
|
2870
2948
|
label: pinnedHere ? "Unpin" : `Pin ${participant.displayName} for me`,
|
|
2871
2949
|
active: pinnedHere,
|
|
2872
2950
|
onClick: () => host?.engine.pin(pinnedHere ? null : participant.identity),
|
|
2873
|
-
children: /* @__PURE__ */ (0,
|
|
2951
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PinIcon, { width: 16, height: 16 })
|
|
2874
2952
|
}
|
|
2875
2953
|
),
|
|
2876
|
-
/* @__PURE__ */ (0,
|
|
2877
|
-
/* @__PURE__ */ (0,
|
|
2954
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__anchor", children: [
|
|
2955
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
2878
2956
|
ControlButton,
|
|
2879
2957
|
{
|
|
2880
2958
|
label: `More for ${participant.displayName}`,
|
|
2881
2959
|
active: menu,
|
|
2882
2960
|
onClick: () => setMenu(!menu),
|
|
2883
|
-
children: /* @__PURE__ */ (0,
|
|
2961
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MoreIcon, { width: 16, height: 16 })
|
|
2884
2962
|
}
|
|
2885
2963
|
),
|
|
2886
|
-
menu ? /* @__PURE__ */ (0,
|
|
2964
|
+
menu ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PersonMenu, { participant, onClose: () => setMenu(false), placement: "down" }) : null
|
|
2887
2965
|
] })
|
|
2888
2966
|
] })
|
|
2889
2967
|
]
|
|
@@ -2899,28 +2977,28 @@ function QualityBars({ quality }) {
|
|
|
2899
2977
|
if (quality === "unknown") return null;
|
|
2900
2978
|
const bars = quality === "excellent" ? 3 : quality === "good" ? 2 : quality === "poor" ? 1 : 0;
|
|
2901
2979
|
const label = quality === "lost" ? "Connection lost" : quality === "poor" ? "Poor connection" : `Connection ${quality}`;
|
|
2902
|
-
return /* @__PURE__ */ (0,
|
|
2980
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: `mx-meet__signal mx-meet__signal--${quality}`, title: label, "aria-label": label, role: "img", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SignalIcon, { bars, width: 14, height: 14 }) });
|
|
2903
2981
|
}
|
|
2904
2982
|
function Stage({ pageSize }) {
|
|
2905
2983
|
const stage = useStage(pageSize);
|
|
2906
2984
|
const columns = gridColumns(stage.tiles.length);
|
|
2907
2985
|
if (stage.feature === null && stage.tiles.length === 0) {
|
|
2908
|
-
return /* @__PURE__ */ (0,
|
|
2909
|
-
/* @__PURE__ */ (0,
|
|
2910
|
-
/* @__PURE__ */ (0,
|
|
2986
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__stage mx-meet__stage--empty", children: [
|
|
2987
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__empty-title", children: "Waiting for others to join" }),
|
|
2988
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__empty-body", children: "Share the meeting link and people can join from anywhere \u2014 no account needed." })
|
|
2911
2989
|
] });
|
|
2912
2990
|
}
|
|
2913
|
-
return /* @__PURE__ */ (0,
|
|
2914
|
-
stage.feature !== null ? /* @__PURE__ */ (0,
|
|
2915
|
-
/* @__PURE__ */ (0,
|
|
2991
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: `mx-meet__stage${stage.feature !== null ? " mx-meet__stage--speaker" : ""}`, children: [
|
|
2992
|
+
stage.feature !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ParticipantTile, { participant: stage.feature, featured: true }) : null,
|
|
2993
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
2916
2994
|
"div",
|
|
2917
2995
|
{
|
|
2918
2996
|
className: "mx-meet__grid",
|
|
2919
2997
|
style: { "--mx-meet-columns": columns },
|
|
2920
|
-
children: stage.tiles.map((participant) => /* @__PURE__ */ (0,
|
|
2998
|
+
children: stage.tiles.map((participant) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ParticipantTile, { participant }, participant.identity))
|
|
2921
2999
|
}
|
|
2922
3000
|
),
|
|
2923
|
-
stage.overflow > 0 ? /* @__PURE__ */ (0,
|
|
3001
|
+
stage.overflow > 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("p", { className: "mx-meet__overflow", children: [
|
|
2924
3002
|
"+",
|
|
2925
3003
|
stage.overflow,
|
|
2926
3004
|
" more ",
|
|
@@ -2932,17 +3010,24 @@ function Stage({ pageSize }) {
|
|
|
2932
3010
|
function ControlBar({ onLeave }) {
|
|
2933
3011
|
const room = useRoom();
|
|
2934
3012
|
const recording = useRecording();
|
|
2935
|
-
const [panel, setPanel] = (0,
|
|
2936
|
-
const [chatTo, setChatTo] = (0,
|
|
2937
|
-
const [popover, setPopover] = (0,
|
|
2938
|
-
const [shortcuts, setShortcuts] = (0,
|
|
3013
|
+
const [panel, setPanel] = (0, import_react10.useState)("none");
|
|
3014
|
+
const [chatTo, setChatTo] = (0, import_react10.useState)(null);
|
|
3015
|
+
const [popover, setPopover] = (0, import_react10.useState)("none");
|
|
3016
|
+
const [shortcuts, setShortcuts] = (0, import_react10.useState)(false);
|
|
2939
3017
|
const snapshot = useMeetSnapshot();
|
|
2940
3018
|
const lobby = useLobby();
|
|
2941
3019
|
const controls = useHostControls();
|
|
2942
3020
|
const queue = useHandQueue();
|
|
2943
3021
|
const micUnavailable = useLocalMedia().microphone.unavailable;
|
|
2944
3022
|
const unread = useUnreadChat(panel === "chat");
|
|
2945
|
-
const [whiteboard, setWhiteboard] = (0,
|
|
3023
|
+
const [whiteboard, setWhiteboard] = (0, import_react10.useState)(false);
|
|
3024
|
+
const app = useMeetAppPanel();
|
|
3025
|
+
const appOpened = (0, import_react10.useRef)(false);
|
|
3026
|
+
(0, import_react10.useEffect)(() => {
|
|
3027
|
+
if (app === null || appOpened.current) return;
|
|
3028
|
+
appOpened.current = true;
|
|
3029
|
+
setPanel("app");
|
|
3030
|
+
}, [app]);
|
|
2946
3031
|
const toggle = (next) => setPanel(panel === next ? "none" : next);
|
|
2947
3032
|
const openActivity = (activity) => {
|
|
2948
3033
|
if (activity === "whiteboard") setWhiteboard(true);
|
|
@@ -2953,7 +3038,7 @@ function ControlBar({ onLeave }) {
|
|
|
2953
3038
|
});
|
|
2954
3039
|
const privateChatAt = snapshot?.privateChatRequest?.at ?? null;
|
|
2955
3040
|
const meetStore = useMeetHost()?.store ?? null;
|
|
2956
|
-
(0,
|
|
3041
|
+
(0, import_react10.useEffect)(() => {
|
|
2957
3042
|
const request = meetStore?.snapshot().privateChatRequest ?? null;
|
|
2958
3043
|
if (request === null) return;
|
|
2959
3044
|
setChatTo(request.to);
|
|
@@ -2969,11 +3054,11 @@ function ControlBar({ onLeave }) {
|
|
|
2969
3054
|
help: () => setShortcuts(true)
|
|
2970
3055
|
});
|
|
2971
3056
|
const hasSpotlight = snapshot?.spotlight !== null && snapshot?.spotlight !== void 0;
|
|
2972
|
-
return /* @__PURE__ */ (0,
|
|
2973
|
-
/* @__PURE__ */ (0,
|
|
2974
|
-
shortcuts ? /* @__PURE__ */ (0,
|
|
2975
|
-
panel === "chat" ? /* @__PURE__ */ (0,
|
|
2976
|
-
panel === "people" ? /* @__PURE__ */ (0,
|
|
3057
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_jsx_runtime6.Fragment, { children: [
|
|
3058
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MeetingOverlays, {}),
|
|
3059
|
+
shortcuts ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ShortcutsSheet, { onClose: () => setShortcuts(false) }) : null,
|
|
3060
|
+
panel === "chat" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ChatPanel, { onClose: () => setPanel("none"), to: chatTo, onTo: setChatTo }) : null,
|
|
3061
|
+
panel === "people" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
2977
3062
|
PeoplePanel,
|
|
2978
3063
|
{
|
|
2979
3064
|
onClose: () => setPanel("none"),
|
|
@@ -2983,53 +3068,61 @@ function ControlBar({ onLeave }) {
|
|
|
2983
3068
|
}
|
|
2984
3069
|
}
|
|
2985
3070
|
) : null,
|
|
2986
|
-
panel === "ai" ? /* @__PURE__ */ (0,
|
|
2987
|
-
panel === "settings" ? /* @__PURE__ */ (0,
|
|
2988
|
-
panel === "polls" ? /* @__PURE__ */ (0,
|
|
2989
|
-
panel === "qa" ? /* @__PURE__ */ (0,
|
|
2990
|
-
panel === "breakouts" ? /* @__PURE__ */ (0,
|
|
2991
|
-
whiteboard ? /* @__PURE__ */ (0,
|
|
2992
|
-
/* @__PURE__ */ (0,
|
|
2993
|
-
|
|
2994
|
-
|
|
2995
|
-
|
|
3071
|
+
panel === "ai" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(AiPanel, { onClose: () => setPanel("none") }) : null,
|
|
3072
|
+
panel === "settings" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SettingsPanel, { onClose: () => setPanel("none") }) : null,
|
|
3073
|
+
panel === "polls" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PollsPanel, { onClose: () => setPanel("none") }) : null,
|
|
3074
|
+
panel === "qa" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(QaPanel, { onClose: () => setPanel("none") }) : null,
|
|
3075
|
+
panel === "breakouts" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(BreakoutsPanel, { onClose: () => setPanel("none") }) : null,
|
|
3076
|
+
whiteboard ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(WhiteboardPanel, { onClose: () => setWhiteboard(false) }) : null,
|
|
3077
|
+
panel === "app" && app !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PanelShell, { title: app.title, onClose: () => setPanel("none"), children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__app-panel", "data-meet-app-panel": app.panel.key, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3078
|
+
app.Component,
|
|
3079
|
+
{
|
|
3080
|
+
recordId: app.panel.recordId,
|
|
3081
|
+
organizationId: app.organizationId,
|
|
3082
|
+
panelKey: app.panel.key
|
|
3083
|
+
}
|
|
3084
|
+
) }) }) : null,
|
|
3085
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(BreakoutBanner, {}),
|
|
3086
|
+
controls.notice !== null && panel !== "people" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Toast, { text: controls.notice.text, failed: controls.notice.failed, onDone: controls.clearNotice }) : null,
|
|
3087
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__controls", children: [
|
|
3088
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
2996
3089
|
ControlButton,
|
|
2997
3090
|
{
|
|
2998
3091
|
label: micUnavailable !== null ? `Unmute \u2014 ${micUnavailable.remedy}` : room.local?.micEnabled === true ? "Mute (\u2318D)" : "Unmute (\u2318D)",
|
|
2999
3092
|
active: room.local?.micEnabled === true,
|
|
3000
3093
|
onClick: () => void room.toggleMicrophone(),
|
|
3001
|
-
children: room.local?.micEnabled === true ? /* @__PURE__ */ (0,
|
|
3094
|
+
children: room.local?.micEnabled === true ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MicIcon, {}) : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MicOffIcon, {})
|
|
3002
3095
|
}
|
|
3003
3096
|
),
|
|
3004
|
-
/* @__PURE__ */ (0,
|
|
3097
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3005
3098
|
ControlButton,
|
|
3006
3099
|
{
|
|
3007
3100
|
label: room.local?.cameraEnabled === true ? "Stop video (\u2318E)" : "Start video (\u2318E)",
|
|
3008
3101
|
active: room.local?.cameraEnabled === true,
|
|
3009
3102
|
onClick: () => void room.toggleCamera(),
|
|
3010
|
-
children: room.local?.cameraEnabled === true ? /* @__PURE__ */ (0,
|
|
3103
|
+
children: room.local?.cameraEnabled === true ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CameraIcon, {}) : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CameraOffIcon, {})
|
|
3011
3104
|
}
|
|
3012
3105
|
),
|
|
3013
|
-
room.canShareScreen || room.local?.screenSharing === true ? /* @__PURE__ */ (0,
|
|
3106
|
+
room.canShareScreen || room.local?.screenSharing === true ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3014
3107
|
ControlButton,
|
|
3015
3108
|
{
|
|
3016
3109
|
label: room.local?.screenSharing === true ? "Stop sharing" : "Share screen",
|
|
3017
3110
|
active: room.local?.screenSharing === true,
|
|
3018
3111
|
onClick: () => void room.toggleScreenShare(),
|
|
3019
|
-
children: /* @__PURE__ */ (0,
|
|
3112
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ScreenShareIcon, {})
|
|
3020
3113
|
}
|
|
3021
3114
|
) : null,
|
|
3022
|
-
/* @__PURE__ */ (0,
|
|
3023
|
-
/* @__PURE__ */ (0,
|
|
3115
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__anchor", children: [
|
|
3116
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3024
3117
|
ControlButton,
|
|
3025
3118
|
{
|
|
3026
3119
|
label: "Send a reaction",
|
|
3027
3120
|
active: popover === "reactions",
|
|
3028
3121
|
onClick: () => setPopover(popover === "reactions" ? "none" : "reactions"),
|
|
3029
|
-
children: /* @__PURE__ */ (0,
|
|
3122
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SmileIcon, {})
|
|
3030
3123
|
}
|
|
3031
3124
|
),
|
|
3032
|
-
popover === "reactions" ? /* @__PURE__ */ (0,
|
|
3125
|
+
popover === "reactions" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Popover, { label: "Reactions", onClose: () => setPopover("none"), children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__emoji-bar", children: MEET_REACTIONS.map((emoji) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3033
3126
|
"button",
|
|
3034
3127
|
{
|
|
3035
3128
|
type: "button",
|
|
@@ -3041,53 +3134,54 @@ function ControlBar({ onLeave }) {
|
|
|
3041
3134
|
emoji
|
|
3042
3135
|
)) }) }) : null
|
|
3043
3136
|
] }),
|
|
3044
|
-
/* @__PURE__ */ (0,
|
|
3137
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3045
3138
|
ControlButton,
|
|
3046
3139
|
{
|
|
3047
3140
|
label: room.local?.handRaised === true ? "Lower hand (\u2318\u2325H)" : "Raise hand (\u2318\u2325H)",
|
|
3048
3141
|
active: room.local?.handRaised === true,
|
|
3049
3142
|
onClick: () => void room.toggleHand(),
|
|
3050
|
-
children: /* @__PURE__ */ (0,
|
|
3143
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(HandIcon, {})
|
|
3051
3144
|
}
|
|
3052
3145
|
),
|
|
3053
|
-
/* @__PURE__ */ (0,
|
|
3054
|
-
|
|
3055
|
-
|
|
3146
|
+
app !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ControlButton, { label: app.title, active: panel === "app", onClick: () => toggle("app"), children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(FlagIcon, {}) }) : null,
|
|
3147
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(ControlButton, { label: "Chat (\u2318\u2325C)", active: panel === "chat", onClick: () => toggle("chat"), children: [
|
|
3148
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ChatIcon, {}),
|
|
3149
|
+
unread > 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__dot", "aria-hidden": "true" }) : null
|
|
3056
3150
|
] }),
|
|
3057
|
-
/* @__PURE__ */ (0,
|
|
3151
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3058
3152
|
ControlButton,
|
|
3059
3153
|
{
|
|
3060
3154
|
label: lobby.waiting.length > 0 ? `People \u2014 ${lobby.waiting.length} waiting` : `People \u2014 ${(snapshot?.participants ?? []).length} in the meeting`,
|
|
3061
3155
|
active: panel === "people",
|
|
3062
3156
|
onClick: () => toggle("people"),
|
|
3063
3157
|
children: [
|
|
3064
|
-
/* @__PURE__ */ (0,
|
|
3065
|
-
lobby.waiting.length > 0 || controls.isHost && queue.length > 0 ? /* @__PURE__ */ (0,
|
|
3158
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PeopleIcon, {}),
|
|
3159
|
+
lobby.waiting.length > 0 || controls.isHost && queue.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__dot", "aria-hidden": "true" }) : null
|
|
3066
3160
|
]
|
|
3067
3161
|
}
|
|
3068
3162
|
),
|
|
3069
|
-
/* @__PURE__ */ (0,
|
|
3163
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3070
3164
|
ActivitiesControl,
|
|
3071
3165
|
{
|
|
3072
3166
|
active: whiteboard ? "whiteboard" : panel === "polls" || panel === "qa" || panel === "breakouts" ? panel : null,
|
|
3073
3167
|
onOpen: openActivity
|
|
3074
3168
|
}
|
|
3075
3169
|
),
|
|
3076
|
-
/* @__PURE__ */ (0,
|
|
3077
|
-
recording.canStart ? /* @__PURE__ */ (0,
|
|
3078
|
-
recording.canStop ? /* @__PURE__ */ (0,
|
|
3079
|
-
/* @__PURE__ */ (0,
|
|
3080
|
-
/* @__PURE__ */ (0,
|
|
3170
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(AiControl, { active: panel === "ai", onToggle: () => toggle("ai") }),
|
|
3171
|
+
recording.canStart ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ControlButton, { label: "Start recording", onClick: () => void recording.start(), children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(RecordIcon, {}) }) : null,
|
|
3172
|
+
recording.canStop ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ControlButton, { label: "Stop recording", active: true, onClick: () => void recording.stop(), children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(RecordIcon, {}) }) : null,
|
|
3173
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__anchor", children: [
|
|
3174
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3081
3175
|
ControlButton,
|
|
3082
3176
|
{
|
|
3083
3177
|
label: "More options",
|
|
3084
3178
|
active: popover === "more" || panel === "settings",
|
|
3085
3179
|
onClick: () => setPopover(popover === "more" ? "none" : "more"),
|
|
3086
|
-
children: /* @__PURE__ */ (0,
|
|
3180
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MoreIcon, {})
|
|
3087
3181
|
}
|
|
3088
3182
|
),
|
|
3089
|
-
popover === "more" ? /* @__PURE__ */ (0,
|
|
3090
|
-
/* @__PURE__ */ (0,
|
|
3183
|
+
popover === "more" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Popover, { label: "More options", onClose: () => setPopover("none"), children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__menu", role: "menu", children: [
|
|
3184
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3091
3185
|
MenuItem,
|
|
3092
3186
|
{
|
|
3093
3187
|
onSelect: () => {
|
|
@@ -3095,12 +3189,12 @@ function ControlBar({ onLeave }) {
|
|
|
3095
3189
|
setPanel("settings");
|
|
3096
3190
|
},
|
|
3097
3191
|
children: [
|
|
3098
|
-
/* @__PURE__ */ (0,
|
|
3192
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SettingsIcon, { width: 16, height: 16 }),
|
|
3099
3193
|
" Settings"
|
|
3100
3194
|
]
|
|
3101
3195
|
}
|
|
3102
3196
|
),
|
|
3103
|
-
/* @__PURE__ */ (0,
|
|
3197
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3104
3198
|
MenuItem,
|
|
3105
3199
|
{
|
|
3106
3200
|
onSelect: () => {
|
|
@@ -3108,14 +3202,14 @@ function ControlBar({ onLeave }) {
|
|
|
3108
3202
|
setShortcuts(true);
|
|
3109
3203
|
},
|
|
3110
3204
|
children: [
|
|
3111
|
-
/* @__PURE__ */ (0,
|
|
3205
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(KeyboardIcon, { width: 16, height: 16 }),
|
|
3112
3206
|
" Keyboard shortcuts"
|
|
3113
3207
|
]
|
|
3114
3208
|
}
|
|
3115
3209
|
),
|
|
3116
|
-
controls.isHost ? /* @__PURE__ */ (0,
|
|
3117
|
-
/* @__PURE__ */ (0,
|
|
3118
|
-
/* @__PURE__ */ (0,
|
|
3210
|
+
controls.isHost ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_jsx_runtime6.Fragment, { children: [
|
|
3211
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__menu-sep", role: "separator" }),
|
|
3212
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3119
3213
|
MenuItem,
|
|
3120
3214
|
{
|
|
3121
3215
|
onSelect: () => {
|
|
@@ -3123,12 +3217,12 @@ function ControlBar({ onLeave }) {
|
|
|
3123
3217
|
void controls.run({ action: "mute_all" });
|
|
3124
3218
|
},
|
|
3125
3219
|
children: [
|
|
3126
|
-
/* @__PURE__ */ (0,
|
|
3220
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MicOffIcon, { width: 16, height: 16 }),
|
|
3127
3221
|
" Mute everyone"
|
|
3128
3222
|
]
|
|
3129
3223
|
}
|
|
3130
3224
|
),
|
|
3131
|
-
/* @__PURE__ */ (0,
|
|
3225
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3132
3226
|
MenuItem,
|
|
3133
3227
|
{
|
|
3134
3228
|
onSelect: () => {
|
|
@@ -3136,12 +3230,12 @@ function ControlBar({ onLeave }) {
|
|
|
3136
3230
|
void controls.run({ action: "ask_all_unmute" });
|
|
3137
3231
|
},
|
|
3138
3232
|
children: [
|
|
3139
|
-
/* @__PURE__ */ (0,
|
|
3233
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MicIcon, { width: 16, height: 16 }),
|
|
3140
3234
|
" Ask everyone to unmute"
|
|
3141
3235
|
]
|
|
3142
3236
|
}
|
|
3143
3237
|
),
|
|
3144
|
-
queue.length > 0 ? /* @__PURE__ */ (0,
|
|
3238
|
+
queue.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3145
3239
|
MenuItem,
|
|
3146
3240
|
{
|
|
3147
3241
|
onSelect: () => {
|
|
@@ -3149,14 +3243,14 @@ function ControlBar({ onLeave }) {
|
|
|
3149
3243
|
void controls.run({ action: "lower_all_hands" });
|
|
3150
3244
|
},
|
|
3151
3245
|
children: [
|
|
3152
|
-
/* @__PURE__ */ (0,
|
|
3246
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(HandIcon, { width: 16, height: 16 }),
|
|
3153
3247
|
" Lower all hands (",
|
|
3154
3248
|
queue.length,
|
|
3155
3249
|
")"
|
|
3156
3250
|
]
|
|
3157
3251
|
}
|
|
3158
3252
|
) : null,
|
|
3159
|
-
hasSpotlight ? /* @__PURE__ */ (0,
|
|
3253
|
+
hasSpotlight ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3160
3254
|
MenuItem,
|
|
3161
3255
|
{
|
|
3162
3256
|
onSelect: () => {
|
|
@@ -3164,7 +3258,7 @@ function ControlBar({ onLeave }) {
|
|
|
3164
3258
|
void controls.run({ action: "spotlight", identity: null });
|
|
3165
3259
|
},
|
|
3166
3260
|
children: [
|
|
3167
|
-
/* @__PURE__ */ (0,
|
|
3261
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SpotlightIcon, { width: 16, height: 16 }),
|
|
3168
3262
|
" Remove spotlight"
|
|
3169
3263
|
]
|
|
3170
3264
|
}
|
|
@@ -3172,7 +3266,7 @@ function ControlBar({ onLeave }) {
|
|
|
3172
3266
|
] }) : null
|
|
3173
3267
|
] }) }) : null
|
|
3174
3268
|
] }),
|
|
3175
|
-
/* @__PURE__ */ (0,
|
|
3269
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3176
3270
|
ControlButton,
|
|
3177
3271
|
{
|
|
3178
3272
|
label: "Leave",
|
|
@@ -3181,7 +3275,7 @@ function ControlBar({ onLeave }) {
|
|
|
3181
3275
|
void room.leave();
|
|
3182
3276
|
onLeave?.();
|
|
3183
3277
|
},
|
|
3184
|
-
children: /* @__PURE__ */ (0,
|
|
3278
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PhoneOffIcon, {})
|
|
3185
3279
|
}
|
|
3186
3280
|
)
|
|
3187
3281
|
] })
|
|
@@ -3191,13 +3285,13 @@ function useUnreadChat(open) {
|
|
|
3191
3285
|
const snapshot = useMeetSnapshot();
|
|
3192
3286
|
const chat = snapshot?.chat ?? [];
|
|
3193
3287
|
const local = snapshot?.localIdentity ?? null;
|
|
3194
|
-
const [seen, setSeen] = (0,
|
|
3195
|
-
(0,
|
|
3288
|
+
const [seen, setSeen] = (0, import_react10.useState)(0);
|
|
3289
|
+
(0, import_react10.useEffect)(() => {
|
|
3196
3290
|
if (open) setSeen(chat.length);
|
|
3197
3291
|
}, [open, chat.length]);
|
|
3198
3292
|
const loaded = snapshot?.chatLoaded === true;
|
|
3199
|
-
const [baseline, setBaseline] = (0,
|
|
3200
|
-
(0,
|
|
3293
|
+
const [baseline, setBaseline] = (0, import_react10.useState)(null);
|
|
3294
|
+
(0, import_react10.useEffect)(() => {
|
|
3201
3295
|
if (loaded && baseline === null) setBaseline(chat.length);
|
|
3202
3296
|
}, [loaded, baseline, chat.length]);
|
|
3203
3297
|
if (open) return 0;
|
|
@@ -3210,14 +3304,14 @@ function Popover({
|
|
|
3210
3304
|
children,
|
|
3211
3305
|
placement = "up"
|
|
3212
3306
|
}) {
|
|
3213
|
-
const ref = (0,
|
|
3214
|
-
const [style, setStyle] = (0,
|
|
3307
|
+
const ref = (0, import_react10.useRef)(null);
|
|
3308
|
+
const [style, setStyle] = (0, import_react10.useState)({
|
|
3215
3309
|
position: "fixed",
|
|
3216
3310
|
top: 0,
|
|
3217
3311
|
left: 0,
|
|
3218
3312
|
visibility: "hidden"
|
|
3219
3313
|
});
|
|
3220
|
-
(0,
|
|
3314
|
+
(0, import_react10.useLayoutEffect)(() => {
|
|
3221
3315
|
const element = ref.current;
|
|
3222
3316
|
const anchor = element?.parentElement ?? null;
|
|
3223
3317
|
if (element === null || anchor === null) return;
|
|
@@ -3262,7 +3356,7 @@ function Popover({
|
|
|
3262
3356
|
window.removeEventListener("scroll", place, true);
|
|
3263
3357
|
};
|
|
3264
3358
|
}, [placement]);
|
|
3265
|
-
(0,
|
|
3359
|
+
(0, import_react10.useEffect)(() => {
|
|
3266
3360
|
const onKey = (event) => {
|
|
3267
3361
|
if (event.key === "Escape") onClose();
|
|
3268
3362
|
};
|
|
@@ -3277,14 +3371,14 @@ function Popover({
|
|
|
3277
3371
|
window.removeEventListener("pointerdown", onPointer);
|
|
3278
3372
|
};
|
|
3279
3373
|
}, [onClose]);
|
|
3280
|
-
return /* @__PURE__ */ (0,
|
|
3374
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { ref, className: "mx-meet__popover", style, role: "dialog", "aria-label": label, children });
|
|
3281
3375
|
}
|
|
3282
3376
|
function MenuItem({
|
|
3283
3377
|
onSelect,
|
|
3284
3378
|
danger = false,
|
|
3285
3379
|
children
|
|
3286
3380
|
}) {
|
|
3287
|
-
return /* @__PURE__ */ (0,
|
|
3381
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3288
3382
|
"button",
|
|
3289
3383
|
{
|
|
3290
3384
|
type: "button",
|
|
@@ -3296,28 +3390,28 @@ function MenuItem({
|
|
|
3296
3390
|
);
|
|
3297
3391
|
}
|
|
3298
3392
|
function Toast({ text, failed, onDone }) {
|
|
3299
|
-
(0,
|
|
3393
|
+
(0, import_react10.useEffect)(() => {
|
|
3300
3394
|
const timer = setTimeout(onDone, failed ? 7e3 : 4e3);
|
|
3301
3395
|
return () => clearTimeout(timer);
|
|
3302
3396
|
}, [text, failed, onDone]);
|
|
3303
|
-
return /* @__PURE__ */ (0,
|
|
3304
|
-
/* @__PURE__ */ (0,
|
|
3305
|
-
/* @__PURE__ */ (0,
|
|
3397
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: failed ? "mx-meet__toast mx-meet__toast--failed" : "mx-meet__toast", role: "status", children: [
|
|
3398
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { children: text }),
|
|
3399
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("button", { type: "button", className: "mx-meet__toast-close", "aria-label": "Dismiss", onClick: onDone, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CloseIcon, { width: 14, height: 14 }) })
|
|
3306
3400
|
] });
|
|
3307
3401
|
}
|
|
3308
3402
|
function MeetingOverlays() {
|
|
3309
3403
|
const reactions = useReactions();
|
|
3310
3404
|
const { notice, dismiss } = useModerationNotice();
|
|
3311
3405
|
const room = useRoom();
|
|
3312
|
-
return /* @__PURE__ */ (0,
|
|
3313
|
-
/* @__PURE__ */ (0,
|
|
3406
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_jsx_runtime6.Fragment, { children: [
|
|
3407
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ReactionOverlay, { reactions }),
|
|
3314
3408
|
notice !== null && notice.kind !== "removed" ? (
|
|
3315
3409
|
// A host's request ("the host is asking you to unmute"), not an error:
|
|
3316
3410
|
// an assertive status, so it is announced at once without being filed
|
|
3317
3411
|
// as a failure (design-system error-box census).
|
|
3318
|
-
/* @__PURE__ */ (0,
|
|
3319
|
-
/* @__PURE__ */ (0,
|
|
3320
|
-
notice.kind === "ask-unmute" && room.local?.micEnabled !== true ? /* @__PURE__ */ (0,
|
|
3412
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__notice-bar", role: "status", "aria-live": "assertive", children: [
|
|
3413
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { children: notice.text }),
|
|
3414
|
+
notice.kind === "ask-unmute" && room.local?.micEnabled !== true ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3321
3415
|
"button",
|
|
3322
3416
|
{
|
|
3323
3417
|
type: "button",
|
|
@@ -3329,20 +3423,20 @@ function MeetingOverlays() {
|
|
|
3329
3423
|
children: "Unmute"
|
|
3330
3424
|
}
|
|
3331
3425
|
) : null,
|
|
3332
|
-
/* @__PURE__ */ (0,
|
|
3426
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("button", { type: "button", className: "mx-meet__toast-close", "aria-label": "Dismiss", onClick: dismiss, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CloseIcon, { width: 14, height: 14 }) })
|
|
3333
3427
|
] })
|
|
3334
3428
|
) : null
|
|
3335
3429
|
] });
|
|
3336
3430
|
}
|
|
3337
3431
|
function ShortcutsSheet({ onClose }) {
|
|
3338
|
-
(0,
|
|
3432
|
+
(0, import_react10.useEffect)(() => {
|
|
3339
3433
|
const onKey = (event) => {
|
|
3340
3434
|
if (event.key === "Escape") onClose();
|
|
3341
3435
|
};
|
|
3342
3436
|
window.addEventListener("keydown", onKey);
|
|
3343
3437
|
return () => window.removeEventListener("keydown", onKey);
|
|
3344
3438
|
}, [onClose]);
|
|
3345
|
-
return /* @__PURE__ */ (0,
|
|
3439
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__sheet-backdrop", onClick: onClose, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3346
3440
|
"div",
|
|
3347
3441
|
{
|
|
3348
3442
|
className: "mx-meet__sheet",
|
|
@@ -3350,13 +3444,13 @@ function ShortcutsSheet({ onClose }) {
|
|
|
3350
3444
|
"aria-label": "Keyboard shortcuts",
|
|
3351
3445
|
onClick: (event) => event.stopPropagation(),
|
|
3352
3446
|
children: [
|
|
3353
|
-
/* @__PURE__ */ (0,
|
|
3354
|
-
/* @__PURE__ */ (0,
|
|
3355
|
-
/* @__PURE__ */ (0,
|
|
3447
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("header", { className: "mx-meet__panel-head", children: [
|
|
3448
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h2", { className: "mx-meet__panel-title", children: "Keyboard shortcuts" }),
|
|
3449
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ControlButton, { label: "Close", onClick: onClose, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CloseIcon, { width: 16, height: 16 }) })
|
|
3356
3450
|
] }),
|
|
3357
|
-
/* @__PURE__ */ (0,
|
|
3358
|
-
/* @__PURE__ */ (0,
|
|
3359
|
-
/* @__PURE__ */ (0,
|
|
3451
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("dl", { className: "mx-meet__shortcuts", children: MEET_SHORTCUTS.map((shortcut) => /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__shortcut", children: [
|
|
3452
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("dt", { children: shortcut.label }),
|
|
3453
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("dd", { children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("kbd", { className: "mx-meet__kbd", children: shortcut.keys }) })
|
|
3360
3454
|
] }, shortcut.id)) })
|
|
3361
3455
|
]
|
|
3362
3456
|
}
|
|
@@ -3366,15 +3460,15 @@ function AiControl({ active, onToggle }) {
|
|
|
3366
3460
|
const snapshot = useMeetSnapshot();
|
|
3367
3461
|
const meeting = snapshot?.meeting ?? null;
|
|
3368
3462
|
if (meeting === null || !meeting.aiEnabled) return null;
|
|
3369
|
-
return /* @__PURE__ */ (0,
|
|
3463
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ControlButton, { label: "Meeting assistant", active, onClick: onToggle, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SparklesIcon, {}) });
|
|
3370
3464
|
}
|
|
3371
3465
|
function PanelShell({
|
|
3372
3466
|
title,
|
|
3373
3467
|
onClose,
|
|
3374
3468
|
children
|
|
3375
3469
|
}) {
|
|
3376
|
-
const ref = (0,
|
|
3377
|
-
(0,
|
|
3470
|
+
const ref = (0, import_react10.useRef)(null);
|
|
3471
|
+
(0, import_react10.useLayoutEffect)(() => {
|
|
3378
3472
|
const panel = ref.current;
|
|
3379
3473
|
const root = panel?.closest(".mx-meet");
|
|
3380
3474
|
const header = root?.querySelector(":scope > .mx-meet__header") ?? null;
|
|
@@ -3386,12 +3480,12 @@ function PanelShell({
|
|
|
3386
3480
|
observer.observe(header);
|
|
3387
3481
|
return () => observer.disconnect();
|
|
3388
3482
|
}, []);
|
|
3389
|
-
return /* @__PURE__ */ (0,
|
|
3390
|
-
/* @__PURE__ */ (0,
|
|
3391
|
-
/* @__PURE__ */ (0,
|
|
3392
|
-
/* @__PURE__ */ (0,
|
|
3483
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("aside", { ref, className: "mx-meet__panel", "aria-label": title, children: [
|
|
3484
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("header", { className: "mx-meet__panel-head", children: [
|
|
3485
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h2", { className: "mx-meet__panel-title", children: title }),
|
|
3486
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ControlButton, { label: "Close panel", onClick: onClose, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CloseIcon, { width: 16, height: 16 }) })
|
|
3393
3487
|
] }),
|
|
3394
|
-
/* @__PURE__ */ (0,
|
|
3488
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__panel-body", children })
|
|
3395
3489
|
] });
|
|
3396
3490
|
}
|
|
3397
3491
|
function ChatPanel({
|
|
@@ -3401,17 +3495,17 @@ function ChatPanel({
|
|
|
3401
3495
|
}) {
|
|
3402
3496
|
const snapshot = useMeetSnapshot();
|
|
3403
3497
|
const room = useRoom();
|
|
3404
|
-
const [draft, setDraft] = (0,
|
|
3405
|
-
const [recipient, setRecipient] = (0,
|
|
3406
|
-
const listRef = (0,
|
|
3498
|
+
const [draft, setDraft] = (0, import_react10.useState)("");
|
|
3499
|
+
const [recipient, setRecipient] = (0, import_react10.useState)(to);
|
|
3500
|
+
const listRef = (0, import_react10.useRef)(null);
|
|
3407
3501
|
const messages = snapshot?.chat ?? [];
|
|
3408
3502
|
const local = snapshot?.localIdentity ?? null;
|
|
3409
3503
|
const people = (snapshot?.participants ?? []).filter(
|
|
3410
3504
|
(participant) => !participant.isLocal && !participant.isAgent
|
|
3411
3505
|
);
|
|
3412
3506
|
const recipientName = recipient === null ? null : people.find((p) => p.identity === recipient)?.displayName ?? null;
|
|
3413
|
-
(0,
|
|
3414
|
-
(0,
|
|
3507
|
+
(0, import_react10.useEffect)(() => setRecipient(to), [to]);
|
|
3508
|
+
(0, import_react10.useEffect)(() => {
|
|
3415
3509
|
const list = listRef.current;
|
|
3416
3510
|
if (list !== null) list.scrollTop = list.scrollHeight;
|
|
3417
3511
|
}, [messages.length]);
|
|
@@ -3419,13 +3513,13 @@ function ChatPanel({
|
|
|
3419
3513
|
setRecipient(next);
|
|
3420
3514
|
onTo?.(next);
|
|
3421
3515
|
};
|
|
3422
|
-
return /* @__PURE__ */ (0,
|
|
3423
|
-
/* @__PURE__ */ (0,
|
|
3424
|
-
snapshot?.chatHistoryError != null ? /* @__PURE__ */ (0,
|
|
3425
|
-
snapshot?.chatLoaded !== true && messages.length === 0 ? /* @__PURE__ */ (0,
|
|
3426
|
-
messages.map((message) => /* @__PURE__ */ (0,
|
|
3516
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(PanelShell, { title: "Chat", onClose, children: [
|
|
3517
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("ul", { className: "mx-meet__chat", ref: listRef, children: [
|
|
3518
|
+
snapshot?.chatHistoryError != null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("li", { className: "mx-meet__panel-note", children: snapshot.chatHistoryError }) : null,
|
|
3519
|
+
snapshot?.chatLoaded !== true && messages.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("li", { className: "mx-meet__panel-note", children: "Reading earlier messages\u2026" }) : messages.length === 0 && snapshot?.chatHistoryError == null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("li", { className: "mx-meet__panel-note", children: "No messages yet. Messages to everyone stay with the meeting, so people who join later see them." }) : null,
|
|
3520
|
+
messages.map((message) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ChatLine, { message, local, people }, message.id))
|
|
3427
3521
|
] }),
|
|
3428
|
-
/* @__PURE__ */ (0,
|
|
3522
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3429
3523
|
"form",
|
|
3430
3524
|
{
|
|
3431
3525
|
className: "mx-meet__composer mx-meet__composer--chat",
|
|
@@ -3438,7 +3532,7 @@ function ChatPanel({
|
|
|
3438
3532
|
else void room.sendPrivateChat(recipient, text);
|
|
3439
3533
|
},
|
|
3440
3534
|
children: [
|
|
3441
|
-
people.length > 0 ? /* @__PURE__ */ (0,
|
|
3535
|
+
people.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3442
3536
|
"select",
|
|
3443
3537
|
{
|
|
3444
3538
|
className: "mx-meet__select mx-meet__select--compact",
|
|
@@ -3446,16 +3540,16 @@ function ChatPanel({
|
|
|
3446
3540
|
value: recipient ?? "",
|
|
3447
3541
|
onChange: (event) => choose(event.target.value === "" ? null : event.target.value),
|
|
3448
3542
|
children: [
|
|
3449
|
-
/* @__PURE__ */ (0,
|
|
3450
|
-
people.map((participant) => /* @__PURE__ */ (0,
|
|
3543
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("option", { value: "", children: "Everyone" }),
|
|
3544
|
+
people.map((participant) => /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("option", { value: participant.identity, children: [
|
|
3451
3545
|
participant.displayName,
|
|
3452
3546
|
" (private)"
|
|
3453
3547
|
] }, participant.identity))
|
|
3454
3548
|
]
|
|
3455
3549
|
}
|
|
3456
3550
|
) : null,
|
|
3457
|
-
/* @__PURE__ */ (0,
|
|
3458
|
-
/* @__PURE__ */ (0,
|
|
3551
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__composer-row", children: [
|
|
3552
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3459
3553
|
"input",
|
|
3460
3554
|
{
|
|
3461
3555
|
className: "mx-meet__input",
|
|
@@ -3466,9 +3560,9 @@ function ChatPanel({
|
|
|
3466
3560
|
maxLength: 4e3
|
|
3467
3561
|
}
|
|
3468
3562
|
),
|
|
3469
|
-
/* @__PURE__ */ (0,
|
|
3563
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("button", { type: "submit", className: "mx-meet__send", disabled: draft.trim().length === 0, children: "Send" })
|
|
3470
3564
|
] }),
|
|
3471
|
-
recipientName !== null ? /* @__PURE__ */ (0,
|
|
3565
|
+
recipientName !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("p", { className: "mx-meet__panel-note", children: [
|
|
3472
3566
|
"Only ",
|
|
3473
3567
|
recipientName,
|
|
3474
3568
|
" sees this. Private messages are not saved."
|
|
@@ -3486,7 +3580,7 @@ function ChatLine({
|
|
|
3486
3580
|
const mine = message.identity === local;
|
|
3487
3581
|
const privateTo = message.to ?? null;
|
|
3488
3582
|
const counterpart = privateTo === null ? null : mine ? people.find((p) => p.identity === privateTo)?.displayName ?? "them" : "you";
|
|
3489
|
-
return /* @__PURE__ */ (0,
|
|
3583
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3490
3584
|
"li",
|
|
3491
3585
|
{
|
|
3492
3586
|
className: [
|
|
@@ -3495,17 +3589,17 @@ function ChatLine({
|
|
|
3495
3589
|
message.failed !== void 0 ? "mx-meet__chat-line--failed" : ""
|
|
3496
3590
|
].filter(Boolean).join(" "),
|
|
3497
3591
|
children: [
|
|
3498
|
-
/* @__PURE__ */ (0,
|
|
3499
|
-
/* @__PURE__ */ (0,
|
|
3500
|
-
counterpart !== null ? /* @__PURE__ */ (0,
|
|
3592
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__chat-meta", children: [
|
|
3593
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("strong", { children: mine ? "You" : message.displayName }),
|
|
3594
|
+
counterpart !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__chat-private", children: [
|
|
3501
3595
|
"to ",
|
|
3502
3596
|
counterpart,
|
|
3503
3597
|
" \xB7 private"
|
|
3504
3598
|
] }) : null,
|
|
3505
|
-
/* @__PURE__ */ (0,
|
|
3599
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("time", { dateTime: message.at, children: clockOf(message.at) })
|
|
3506
3600
|
] }),
|
|
3507
|
-
/* @__PURE__ */ (0,
|
|
3508
|
-
message.failed !== void 0 ? /* @__PURE__ */ (0,
|
|
3601
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__chat-text", children: message.text }),
|
|
3602
|
+
message.failed !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__chat-failed", children: message.failed }) : privateTo === null && message.saved === false ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__chat-pending", children: message.id.startsWith("pending-") ? "Sending\u2026" : "Not saved \u2014 people who join later will not see this" }) : null
|
|
3509
3603
|
]
|
|
3510
3604
|
}
|
|
3511
3605
|
);
|
|
@@ -3517,22 +3611,25 @@ function PeoplePanel({
|
|
|
3517
3611
|
const snapshot = useMeetSnapshot();
|
|
3518
3612
|
const controls = useHostControls();
|
|
3519
3613
|
const queue = useHandQueue();
|
|
3520
|
-
const [query, setQuery] = (0,
|
|
3521
|
-
const [menuFor, setMenuFor] = (0,
|
|
3614
|
+
const [query, setQuery] = (0, import_react10.useState)("");
|
|
3615
|
+
const [menuFor, setMenuFor] = (0, import_react10.useState)(null);
|
|
3522
3616
|
const myRole = useRole();
|
|
3523
3617
|
const local = snapshot?.localIdentity ?? null;
|
|
3524
|
-
const
|
|
3618
|
+
const observersHidden = snapshot?.grants.observersVisibleTo === "hosts" && !controls.isHost;
|
|
3619
|
+
const everyone = (snapshot?.participants ?? []).filter(
|
|
3620
|
+
(participant) => !observersHidden || !isObserverRole(participant.role) || participant.identity === local
|
|
3621
|
+
);
|
|
3525
3622
|
const needle = query.trim().toLowerCase();
|
|
3526
3623
|
const shown = needle.length === 0 ? everyone : everyone.filter((participant) => participant.displayName.toLowerCase().includes(needle));
|
|
3527
|
-
return /* @__PURE__ */ (0,
|
|
3528
|
-
/* @__PURE__ */ (0,
|
|
3529
|
-
queue.length > 0 ? /* @__PURE__ */ (0,
|
|
3530
|
-
/* @__PURE__ */ (0,
|
|
3531
|
-
/* @__PURE__ */ (0,
|
|
3624
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(PanelShell, { title: `People (${everyone.length})`, onClose, children: [
|
|
3625
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(LobbyPanel, {}),
|
|
3626
|
+
queue.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("section", { className: "mx-meet__section", "aria-label": "Raised hands", children: [
|
|
3627
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("header", { className: "mx-meet__section-head", children: [
|
|
3628
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("h3", { className: "mx-meet__section-title", children: [
|
|
3532
3629
|
"Raised hands \xB7 ",
|
|
3533
3630
|
queue.length
|
|
3534
3631
|
] }),
|
|
3535
|
-
controls.isHost ? /* @__PURE__ */ (0,
|
|
3632
|
+
controls.isHost ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3536
3633
|
"button",
|
|
3537
3634
|
{
|
|
3538
3635
|
type: "button",
|
|
@@ -3542,13 +3639,13 @@ function PeoplePanel({
|
|
|
3542
3639
|
}
|
|
3543
3640
|
) : null
|
|
3544
3641
|
] }),
|
|
3545
|
-
/* @__PURE__ */ (0,
|
|
3546
|
-
/* @__PURE__ */ (0,
|
|
3547
|
-
/* @__PURE__ */ (0,
|
|
3642
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("ol", { className: "mx-meet__queue", children: queue.map((participant) => /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("li", { className: "mx-meet__person", children: [
|
|
3643
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Avatar, { name: participant.displayName, url: participant.avatarUrl, size: 28 }),
|
|
3644
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__person-name", children: [
|
|
3548
3645
|
participant.displayName,
|
|
3549
|
-
participant.identity === local ? /* @__PURE__ */ (0,
|
|
3646
|
+
participant.identity === local ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__you", children: " (you)" }) : null
|
|
3550
3647
|
] }),
|
|
3551
|
-
controls.isHost || participant.identity === local ? /* @__PURE__ */ (0,
|
|
3648
|
+
controls.isHost || participant.identity === local ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3552
3649
|
"button",
|
|
3553
3650
|
{
|
|
3554
3651
|
type: "button",
|
|
@@ -3559,27 +3656,27 @@ function PeoplePanel({
|
|
|
3559
3656
|
) : null
|
|
3560
3657
|
] }, participant.identity)) })
|
|
3561
3658
|
] }) : null,
|
|
3562
|
-
controls.isHost && everyone.length > 1 ? /* @__PURE__ */ (0,
|
|
3563
|
-
/* @__PURE__ */ (0,
|
|
3564
|
-
/* @__PURE__ */ (0,
|
|
3659
|
+
controls.isHost && everyone.length > 1 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__bulk", children: [
|
|
3660
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("button", { type: "button", className: "mx-meet__chip", onClick: () => void controls.run({ action: "mute_all" }), children: [
|
|
3661
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MicOffIcon, { width: 14, height: 14 }),
|
|
3565
3662
|
" Mute all"
|
|
3566
3663
|
] }),
|
|
3567
|
-
/* @__PURE__ */ (0,
|
|
3664
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3568
3665
|
"button",
|
|
3569
3666
|
{
|
|
3570
3667
|
type: "button",
|
|
3571
3668
|
className: "mx-meet__chip",
|
|
3572
3669
|
onClick: () => void controls.run({ action: "ask_all_unmute" }),
|
|
3573
3670
|
children: [
|
|
3574
|
-
/* @__PURE__ */ (0,
|
|
3671
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MicIcon, { width: 14, height: 14 }),
|
|
3575
3672
|
" Ask all to unmute"
|
|
3576
3673
|
]
|
|
3577
3674
|
}
|
|
3578
3675
|
)
|
|
3579
3676
|
] }) : null,
|
|
3580
|
-
everyone.length > 4 ? /* @__PURE__ */ (0,
|
|
3581
|
-
/* @__PURE__ */ (0,
|
|
3582
|
-
/* @__PURE__ */ (0,
|
|
3677
|
+
everyone.length > 4 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("label", { className: "mx-meet__search", children: [
|
|
3678
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SearchIcon, { width: 16, height: 16 }),
|
|
3679
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3583
3680
|
"input",
|
|
3584
3681
|
{
|
|
3585
3682
|
className: "mx-meet__input mx-meet__input--bare",
|
|
@@ -3590,37 +3687,37 @@ function PeoplePanel({
|
|
|
3590
3687
|
}
|
|
3591
3688
|
)
|
|
3592
3689
|
] }) : null,
|
|
3593
|
-
controls.notice !== null ? /* @__PURE__ */ (0,
|
|
3594
|
-
/* @__PURE__ */ (0,
|
|
3595
|
-
shown.map((participant) => /* @__PURE__ */ (0,
|
|
3596
|
-
/* @__PURE__ */ (0,
|
|
3597
|
-
/* @__PURE__ */ (0,
|
|
3690
|
+
controls.notice !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: controls.notice.failed ? "mx-meet__error" : "mx-meet__notice", role: "status", children: controls.notice.text }) : null,
|
|
3691
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("ul", { className: "mx-meet__people", children: [
|
|
3692
|
+
shown.map((participant) => /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("li", { className: "mx-meet__person", children: [
|
|
3693
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Avatar, { name: participant.displayName, url: participant.avatarUrl, size: 32 }),
|
|
3694
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__person-name", children: [
|
|
3598
3695
|
participant.displayName,
|
|
3599
|
-
participant.identity === local ? /* @__PURE__ */ (0,
|
|
3600
|
-
/* @__PURE__ */ (0,
|
|
3696
|
+
participant.identity === local ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__you", children: " (you)" }) : null,
|
|
3697
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3601
3698
|
RoleBadge,
|
|
3602
3699
|
{
|
|
3603
3700
|
role: participant.identity === local ? myRole : participant.role,
|
|
3604
3701
|
standing: participant.standing
|
|
3605
3702
|
}
|
|
3606
3703
|
),
|
|
3607
|
-
isNoteTaker(participant) ? /* @__PURE__ */ (0,
|
|
3608
|
-
snapshot?.spotlight === participant.identity ? /* @__PURE__ */ (0,
|
|
3704
|
+
isNoteTaker(participant) ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__badge", children: "Meeting assistant" }) : null,
|
|
3705
|
+
snapshot?.spotlight === participant.identity ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__badge", children: "Spotlight" }) : null
|
|
3609
3706
|
] }),
|
|
3610
|
-
participant.handRaised ? /* @__PURE__ */ (0,
|
|
3611
|
-
!participant.micEnabled && !isNoteTaker(participant) ? /* @__PURE__ */ (0,
|
|
3612
|
-
/* @__PURE__ */ (0,
|
|
3613
|
-
/* @__PURE__ */ (0,
|
|
3614
|
-
/* @__PURE__ */ (0,
|
|
3707
|
+
participant.handRaised ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(HandIcon, { width: 14, height: 14 }) : null,
|
|
3708
|
+
!participant.micEnabled && !isNoteTaker(participant) ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MicOffIcon, { width: 14, height: 14 }) : null,
|
|
3709
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(QualityBars, { quality: participant.quality }),
|
|
3710
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__anchor", children: [
|
|
3711
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3615
3712
|
ControlButton,
|
|
3616
3713
|
{
|
|
3617
3714
|
label: `More for ${participant.displayName}`,
|
|
3618
3715
|
active: menuFor === participant.identity,
|
|
3619
3716
|
onClick: () => setMenuFor(menuFor === participant.identity ? null : participant.identity),
|
|
3620
|
-
children: /* @__PURE__ */ (0,
|
|
3717
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MoreIcon, { width: 16, height: 16 })
|
|
3621
3718
|
}
|
|
3622
3719
|
),
|
|
3623
|
-
menuFor === participant.identity ? /* @__PURE__ */ (0,
|
|
3720
|
+
menuFor === participant.identity ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3624
3721
|
PersonMenu,
|
|
3625
3722
|
{
|
|
3626
3723
|
participant,
|
|
@@ -3631,13 +3728,13 @@ function PeoplePanel({
|
|
|
3631
3728
|
) : null
|
|
3632
3729
|
] })
|
|
3633
3730
|
] }, participant.identity)),
|
|
3634
|
-
shown.length === 0 ? /* @__PURE__ */ (0,
|
|
3731
|
+
shown.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("li", { className: "mx-meet__panel-note", children: [
|
|
3635
3732
|
"Nobody matches \u201C",
|
|
3636
3733
|
query,
|
|
3637
3734
|
"\u201D."
|
|
3638
3735
|
] }) : null
|
|
3639
3736
|
] }),
|
|
3640
|
-
snapshot?.meeting !== null && snapshot?.meeting !== void 0 ? /* @__PURE__ */ (0,
|
|
3737
|
+
snapshot?.meeting !== null && snapshot?.meeting !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(GuestRecordAccessControl, { meeting: snapshot.meeting }) : null
|
|
3641
3738
|
] });
|
|
3642
3739
|
}
|
|
3643
3740
|
function PersonMenu({
|
|
@@ -3649,14 +3746,14 @@ function PersonMenu({
|
|
|
3649
3746
|
const host = useMeetHost();
|
|
3650
3747
|
const snapshot = useMeetSnapshot();
|
|
3651
3748
|
const controls = useHostControls();
|
|
3652
|
-
const [mode, setMode] = (0,
|
|
3653
|
-
const [text, setText] = (0,
|
|
3749
|
+
const [mode, setMode] = (0, import_react10.useState)("menu");
|
|
3750
|
+
const [text, setText] = (0, import_react10.useState)("");
|
|
3654
3751
|
const self = participant.identity === snapshot?.localIdentity;
|
|
3655
3752
|
const moderate = controls.canModerate(participant);
|
|
3656
3753
|
const pinned = snapshot?.pinned === participant.identity;
|
|
3657
3754
|
const spotlit = snapshot?.spotlight === participant.identity;
|
|
3658
3755
|
const hasAccount = participant.userId !== null;
|
|
3659
|
-
const [refused, setRefused] = (0,
|
|
3756
|
+
const [refused, setRefused] = (0, import_react10.useState)(false);
|
|
3660
3757
|
const act = (request) => {
|
|
3661
3758
|
setRefused(false);
|
|
3662
3759
|
void controls.run(request).then((result) => {
|
|
@@ -3664,10 +3761,10 @@ function PersonMenu({
|
|
|
3664
3761
|
else setRefused(true);
|
|
3665
3762
|
});
|
|
3666
3763
|
};
|
|
3667
|
-
const refusal = refused && controls.notice?.failed === true ? /* @__PURE__ */ (0,
|
|
3764
|
+
const refusal = refused && controls.notice?.failed === true ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.ErrorBox, { as: "p", className: "mx-meet__error", message: controls.notice.text, operation: "Change this participant", origin: "meet/components", children: controls.notice.text }) : null;
|
|
3668
3765
|
if (mode === "rename" || mode === "report") {
|
|
3669
3766
|
const renaming = mode === "rename";
|
|
3670
|
-
return /* @__PURE__ */ (0,
|
|
3767
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Popover, { label: renaming ? "Rename" : "Report", onClose, placement, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3671
3768
|
"form",
|
|
3672
3769
|
{
|
|
3673
3770
|
className: "mx-meet__menu-form",
|
|
@@ -3679,9 +3776,9 @@ function PersonMenu({
|
|
|
3679
3776
|
);
|
|
3680
3777
|
},
|
|
3681
3778
|
children: [
|
|
3682
|
-
/* @__PURE__ */ (0,
|
|
3683
|
-
/* @__PURE__ */ (0,
|
|
3684
|
-
renaming ? /* @__PURE__ */ (0,
|
|
3779
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("label", { className: "mx-meet__field", children: [
|
|
3780
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__field-label", children: renaming ? "Name shown in this meeting" : `What did ${participant.displayName} do?` }),
|
|
3781
|
+
renaming ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3685
3782
|
"input",
|
|
3686
3783
|
{
|
|
3687
3784
|
className: "mx-meet__input",
|
|
@@ -3690,7 +3787,7 @@ function PersonMenu({
|
|
|
3690
3787
|
value: text,
|
|
3691
3788
|
onChange: (event) => setText(event.target.value)
|
|
3692
3789
|
}
|
|
3693
|
-
) : /* @__PURE__ */ (0,
|
|
3790
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3694
3791
|
"textarea",
|
|
3695
3792
|
{
|
|
3696
3793
|
className: "mx-meet__input",
|
|
@@ -3703,9 +3800,9 @@ function PersonMenu({
|
|
|
3703
3800
|
)
|
|
3704
3801
|
] }),
|
|
3705
3802
|
refusal,
|
|
3706
|
-
/* @__PURE__ */ (0,
|
|
3707
|
-
/* @__PURE__ */ (0,
|
|
3708
|
-
/* @__PURE__ */ (0,
|
|
3803
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__menu-actions", children: [
|
|
3804
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("button", { type: "button", className: "mx-meet__link", onClick: () => setMode("menu"), children: "Back" }),
|
|
3805
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("button", { type: "submit", className: "mx-meet__send", disabled: text.trim().length === 0 || controls.busy, children: renaming ? "Rename" : "Report" })
|
|
3709
3806
|
] })
|
|
3710
3807
|
]
|
|
3711
3808
|
}
|
|
@@ -3713,12 +3810,12 @@ function PersonMenu({
|
|
|
3713
3810
|
}
|
|
3714
3811
|
if (mode === "remove" || mode === "transfer") {
|
|
3715
3812
|
const removing = mode === "remove";
|
|
3716
|
-
return /* @__PURE__ */ (0,
|
|
3717
|
-
/* @__PURE__ */ (0,
|
|
3813
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Popover, { label: removing ? "Remove" : "Make host", onClose, placement, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__menu-form", children: [
|
|
3814
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__confirm-text", children: removing ? `Remove ${participant.displayName}? They leave immediately and cannot rejoin this meeting.` : `Make ${participant.displayName} the host? They get every host control and own this meeting. You stay on as a co-host.` }),
|
|
3718
3815
|
refusal,
|
|
3719
|
-
/* @__PURE__ */ (0,
|
|
3720
|
-
/* @__PURE__ */ (0,
|
|
3721
|
-
/* @__PURE__ */ (0,
|
|
3816
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__menu-actions", children: [
|
|
3817
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("button", { type: "button", className: "mx-meet__link", onClick: () => setMode("menu"), children: "Cancel" }),
|
|
3818
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3722
3819
|
"button",
|
|
3723
3820
|
{
|
|
3724
3821
|
type: "button",
|
|
@@ -3731,8 +3828,8 @@ function PersonMenu({
|
|
|
3731
3828
|
] })
|
|
3732
3829
|
] }) });
|
|
3733
3830
|
}
|
|
3734
|
-
return /* @__PURE__ */ (0,
|
|
3735
|
-
/* @__PURE__ */ (0,
|
|
3831
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Popover, { label: `Options for ${participant.displayName}`, onClose, placement, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__menu", role: "menu", children: [
|
|
3832
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3736
3833
|
MenuItem,
|
|
3737
3834
|
{
|
|
3738
3835
|
onSelect: () => {
|
|
@@ -3740,13 +3837,13 @@ function PersonMenu({
|
|
|
3740
3837
|
onClose();
|
|
3741
3838
|
},
|
|
3742
3839
|
children: [
|
|
3743
|
-
/* @__PURE__ */ (0,
|
|
3840
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PinIcon, { width: 16, height: 16 }),
|
|
3744
3841
|
" ",
|
|
3745
3842
|
pinned ? "Unpin" : "Pin for me"
|
|
3746
3843
|
]
|
|
3747
3844
|
}
|
|
3748
3845
|
),
|
|
3749
|
-
!self && !participant.isAgent && (onMessage !== void 0 || host !== null) ? /* @__PURE__ */ (0,
|
|
3846
|
+
!self && !participant.isAgent && (onMessage !== void 0 || host !== null) ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3750
3847
|
MenuItem,
|
|
3751
3848
|
{
|
|
3752
3849
|
onSelect: () => {
|
|
@@ -3758,42 +3855,42 @@ function PersonMenu({
|
|
|
3758
3855
|
onClose();
|
|
3759
3856
|
},
|
|
3760
3857
|
children: [
|
|
3761
|
-
/* @__PURE__ */ (0,
|
|
3858
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ChatIcon, { width: 16, height: 16 }),
|
|
3762
3859
|
" Message privately"
|
|
3763
3860
|
]
|
|
3764
3861
|
}
|
|
3765
3862
|
) : null,
|
|
3766
|
-
controls.isHost ? /* @__PURE__ */ (0,
|
|
3767
|
-
/* @__PURE__ */ (0,
|
|
3863
|
+
controls.isHost ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(MenuItem, { onSelect: () => act({ action: "spotlight", identity: spotlit ? null : participant.identity }), children: [
|
|
3864
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SpotlightIcon, { width: 16, height: 16 }),
|
|
3768
3865
|
" ",
|
|
3769
3866
|
spotlit ? "Remove spotlight" : "Spotlight for everyone"
|
|
3770
3867
|
] }) : null,
|
|
3771
|
-
moderate ? /* @__PURE__ */ (0,
|
|
3772
|
-
/* @__PURE__ */ (0,
|
|
3773
|
-
participant.micEnabled ? /* @__PURE__ */ (0,
|
|
3774
|
-
/* @__PURE__ */ (0,
|
|
3868
|
+
moderate ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_jsx_runtime6.Fragment, { children: [
|
|
3869
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__menu-sep", role: "separator" }),
|
|
3870
|
+
participant.micEnabled ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(MenuItem, { onSelect: () => act({ action: "mute", identity: participant.identity }), children: [
|
|
3871
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MicOffIcon, { width: 16, height: 16 }),
|
|
3775
3872
|
" Mute"
|
|
3776
|
-
] }) : !participant.isAgent ? /* @__PURE__ */ (0,
|
|
3777
|
-
/* @__PURE__ */ (0,
|
|
3873
|
+
] }) : !participant.isAgent ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(MenuItem, { onSelect: () => act({ action: "ask_unmute", identity: participant.identity }), children: [
|
|
3874
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(MicIcon, { width: 16, height: 16 }),
|
|
3778
3875
|
" Ask to unmute"
|
|
3779
3876
|
] }) : null,
|
|
3780
|
-
participant.cameraEnabled ? /* @__PURE__ */ (0,
|
|
3781
|
-
/* @__PURE__ */ (0,
|
|
3877
|
+
participant.cameraEnabled ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(MenuItem, { onSelect: () => act({ action: "stop_video", identity: participant.identity }), children: [
|
|
3878
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CameraOffIcon, { width: 16, height: 16 }),
|
|
3782
3879
|
" Stop video"
|
|
3783
3880
|
] }) : null,
|
|
3784
|
-
participant.screenSharing ? /* @__PURE__ */ (0,
|
|
3785
|
-
/* @__PURE__ */ (0,
|
|
3881
|
+
participant.screenSharing ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(MenuItem, { onSelect: () => act({ action: "stop_screen", identity: participant.identity }), children: [
|
|
3882
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ScreenShareIcon, { width: 16, height: 16 }),
|
|
3786
3883
|
" Stop screen share"
|
|
3787
3884
|
] }) : null,
|
|
3788
|
-
participant.handRaised ? /* @__PURE__ */ (0,
|
|
3789
|
-
/* @__PURE__ */ (0,
|
|
3885
|
+
participant.handRaised ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(MenuItem, { onSelect: () => act({ action: "lower_hand", identity: participant.identity }), children: [
|
|
3886
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(HandIcon, { width: 16, height: 16 }),
|
|
3790
3887
|
" Lower hand"
|
|
3791
3888
|
] }) : null,
|
|
3792
|
-
hasAccount && !participant.isAgent && participant.role !== "cohost" ? /* @__PURE__ */ (0,
|
|
3793
|
-
/* @__PURE__ */ (0,
|
|
3889
|
+
hasAccount && !participant.isAgent && participant.role !== "cohost" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(MenuItem, { onSelect: () => act({ action: "make_cohost", identity: participant.identity }), children: [
|
|
3890
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PeopleIcon, { width: 16, height: 16 }),
|
|
3794
3891
|
" Make co-host"
|
|
3795
3892
|
] }) : null,
|
|
3796
|
-
!participant.isAgent ? /* @__PURE__ */ (0,
|
|
3893
|
+
!participant.isAgent ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3797
3894
|
MenuItem,
|
|
3798
3895
|
{
|
|
3799
3896
|
onSelect: () => {
|
|
@@ -3801,21 +3898,21 @@ function PersonMenu({
|
|
|
3801
3898
|
setMode("rename");
|
|
3802
3899
|
},
|
|
3803
3900
|
children: [
|
|
3804
|
-
/* @__PURE__ */ (0,
|
|
3901
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PencilIcon, { width: 16, height: 16 }),
|
|
3805
3902
|
" Rename"
|
|
3806
3903
|
]
|
|
3807
3904
|
}
|
|
3808
3905
|
) : null
|
|
3809
3906
|
] }) : null,
|
|
3810
|
-
controls.isOwner && participant.role === "cohost" ? /* @__PURE__ */ (0,
|
|
3811
|
-
/* @__PURE__ */ (0,
|
|
3907
|
+
controls.isOwner && participant.role === "cohost" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(MenuItem, { onSelect: () => act({ action: "revoke_cohost", identity: participant.identity }), children: [
|
|
3908
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PeopleIcon, { width: 16, height: 16 }),
|
|
3812
3909
|
" Remove co-host"
|
|
3813
3910
|
] }) : null,
|
|
3814
|
-
controls.isOwner && !self && hasAccount && !participant.isAgent ? /* @__PURE__ */ (0,
|
|
3815
|
-
/* @__PURE__ */ (0,
|
|
3911
|
+
controls.isOwner && !self && hasAccount && !participant.isAgent ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(MenuItem, { onSelect: () => setMode("transfer"), children: [
|
|
3912
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SpotlightIcon, { width: 16, height: 16 }),
|
|
3816
3913
|
" Make host"
|
|
3817
3914
|
] }) : null,
|
|
3818
|
-
self ? /* @__PURE__ */ (0,
|
|
3915
|
+
self ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3819
3916
|
MenuItem,
|
|
3820
3917
|
{
|
|
3821
3918
|
onSelect: () => {
|
|
@@ -3823,12 +3920,12 @@ function PersonMenu({
|
|
|
3823
3920
|
setMode("rename");
|
|
3824
3921
|
},
|
|
3825
3922
|
children: [
|
|
3826
|
-
/* @__PURE__ */ (0,
|
|
3923
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PencilIcon, { width: 16, height: 16 }),
|
|
3827
3924
|
" Rename yourself"
|
|
3828
3925
|
]
|
|
3829
3926
|
}
|
|
3830
3927
|
) : null,
|
|
3831
|
-
!self && !participant.isAgent ? /* @__PURE__ */ (0,
|
|
3928
|
+
!self && !participant.isAgent ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3832
3929
|
MenuItem,
|
|
3833
3930
|
{
|
|
3834
3931
|
onSelect: () => {
|
|
@@ -3836,21 +3933,21 @@ function PersonMenu({
|
|
|
3836
3933
|
setMode("report");
|
|
3837
3934
|
},
|
|
3838
3935
|
children: [
|
|
3839
|
-
/* @__PURE__ */ (0,
|
|
3936
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(FlagIcon, { width: 16, height: 16 }),
|
|
3840
3937
|
" Report"
|
|
3841
3938
|
]
|
|
3842
3939
|
}
|
|
3843
3940
|
) : null,
|
|
3844
|
-
moderate && !participant.isAgent ? /* @__PURE__ */ (0,
|
|
3845
|
-
/* @__PURE__ */ (0,
|
|
3941
|
+
moderate && !participant.isAgent ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(MenuItem, { danger: true, onSelect: () => setMode("remove"), children: [
|
|
3942
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CloseIcon, { width: 16, height: 16 }),
|
|
3846
3943
|
" Remove from meeting"
|
|
3847
3944
|
] }) : null
|
|
3848
3945
|
] }) });
|
|
3849
3946
|
}
|
|
3850
3947
|
function SettingsPanel({ onClose }) {
|
|
3851
3948
|
const host = useRequiredMeetHost();
|
|
3852
|
-
return /* @__PURE__ */ (0,
|
|
3853
|
-
/* @__PURE__ */ (0,
|
|
3949
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(PanelShell, { title: "Settings", onClose, children: [
|
|
3950
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3854
3951
|
DeviceSettings,
|
|
3855
3952
|
{
|
|
3856
3953
|
onPick: (kind, deviceId) => {
|
|
@@ -3859,8 +3956,8 @@ function SettingsPanel({ onClose }) {
|
|
|
3859
3956
|
}
|
|
3860
3957
|
}
|
|
3861
3958
|
),
|
|
3862
|
-
/* @__PURE__ */ (0,
|
|
3863
|
-
/* @__PURE__ */ (0,
|
|
3959
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(EffectsSettings, {}),
|
|
3960
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CaptionLanguageSettings, {})
|
|
3864
3961
|
] });
|
|
3865
3962
|
}
|
|
3866
3963
|
function DeviceSettings({
|
|
@@ -3872,15 +3969,15 @@ function DeviceSettings({
|
|
|
3872
3969
|
const speaker = devices?.selected.audiooutput ?? host.devices.resolve("audiooutput");
|
|
3873
3970
|
const stream = useMicrophoneStream(microphone);
|
|
3874
3971
|
const level = useAudioLevel(stream);
|
|
3875
|
-
const [testing, setTesting] = (0,
|
|
3876
|
-
(0,
|
|
3972
|
+
const [testing, setTesting] = (0, import_react10.useState)(false);
|
|
3973
|
+
(0, import_react10.useEffect)(() => {
|
|
3877
3974
|
void host.devices.refresh();
|
|
3878
3975
|
}, [host]);
|
|
3879
|
-
return /* @__PURE__ */ (0,
|
|
3880
|
-
/* @__PURE__ */ (0,
|
|
3881
|
-
/* @__PURE__ */ (0,
|
|
3882
|
-
/* @__PURE__ */ (0,
|
|
3883
|
-
/* @__PURE__ */ (0,
|
|
3976
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("section", { className: "mx-meet__section", "aria-label": "Devices", children: [
|
|
3977
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(DevicePicker, { kind: "audioinput", label: "Microphone", onPick }),
|
|
3978
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__meter", role: "meter", "aria-label": "Microphone level", "aria-valuemin": 0, "aria-valuemax": 100, "aria-valuenow": Math.round(level * 100), children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { style: { width: `${Math.min(100, Math.round(level * 160))}%` } }) }),
|
|
3979
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(DevicePicker, { kind: "audiooutput", label: "Speaker", onPick }),
|
|
3980
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
3884
3981
|
"button",
|
|
3885
3982
|
{
|
|
3886
3983
|
type: "button",
|
|
@@ -3891,19 +3988,19 @@ function DeviceSettings({
|
|
|
3891
3988
|
void playTestSound(speaker).finally(() => setTesting(false));
|
|
3892
3989
|
},
|
|
3893
3990
|
children: [
|
|
3894
|
-
/* @__PURE__ */ (0,
|
|
3991
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SpeakerIcon, { width: 14, height: 14 }),
|
|
3895
3992
|
" ",
|
|
3896
3993
|
testing ? "Playing\u2026" : "Test speaker"
|
|
3897
3994
|
]
|
|
3898
3995
|
}
|
|
3899
3996
|
),
|
|
3900
|
-
/* @__PURE__ */ (0,
|
|
3997
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(DevicePicker, { kind: "videoinput", label: "Camera", onPick })
|
|
3901
3998
|
] });
|
|
3902
3999
|
}
|
|
3903
4000
|
function EffectsSettings({ preview }) {
|
|
3904
4001
|
const effects = useMediaEffects();
|
|
3905
|
-
const [error, setError] = (0,
|
|
3906
|
-
const fileRef = (0,
|
|
4002
|
+
const [error, setError] = (0, import_react10.useState)(null);
|
|
4003
|
+
const fileRef = (0, import_react10.useRef)(null);
|
|
3907
4004
|
const supported = effects.backgroundsSupported || preview != null || videoEffectsSupported();
|
|
3908
4005
|
const apply = (next) => {
|
|
3909
4006
|
setError(null);
|
|
@@ -3915,9 +4012,9 @@ function EffectsSettings({ preview }) {
|
|
|
3915
4012
|
);
|
|
3916
4013
|
}
|
|
3917
4014
|
};
|
|
3918
|
-
return /* @__PURE__ */ (0,
|
|
3919
|
-
/* @__PURE__ */ (0,
|
|
3920
|
-
/* @__PURE__ */ (0,
|
|
4015
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("section", { className: "mx-meet__section", "aria-label": "Effects", children: [
|
|
4016
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__check", children: [
|
|
4017
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3921
4018
|
import_design_system.Checkbox,
|
|
3922
4019
|
{
|
|
3923
4020
|
id: "mx-meet-noise",
|
|
@@ -3925,14 +4022,14 @@ function EffectsSettings({ preview }) {
|
|
|
3925
4022
|
onCheckedChange: (checked) => apply({ noiseSuppression: checked === true })
|
|
3926
4023
|
}
|
|
3927
4024
|
),
|
|
3928
|
-
/* @__PURE__ */ (0,
|
|
3929
|
-
/* @__PURE__ */ (0,
|
|
3930
|
-
/* @__PURE__ */ (0,
|
|
4025
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__check-text", children: [
|
|
4026
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Label, { htmlFor: "mx-meet-noise", children: "Noise suppression" }),
|
|
4027
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__hint", children: "Filters keyboards, fans and background chatter." })
|
|
3931
4028
|
] })
|
|
3932
4029
|
] }),
|
|
3933
|
-
supported ? /* @__PURE__ */ (0,
|
|
3934
|
-
/* @__PURE__ */ (0,
|
|
3935
|
-
/* @__PURE__ */ (0,
|
|
4030
|
+
supported ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__field", children: [
|
|
4031
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Label, { children: "Background" }),
|
|
4032
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3936
4033
|
import_design_system.SegmentedControl,
|
|
3937
4034
|
{
|
|
3938
4035
|
fullWidth: true,
|
|
@@ -3951,7 +4048,7 @@ function EffectsSettings({ preview }) {
|
|
|
3951
4048
|
]
|
|
3952
4049
|
}
|
|
3953
4050
|
),
|
|
3954
|
-
/* @__PURE__ */ (0,
|
|
4051
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3955
4052
|
"input",
|
|
3956
4053
|
{
|
|
3957
4054
|
ref: fileRef,
|
|
@@ -3966,7 +4063,7 @@ function EffectsSettings({ preview }) {
|
|
|
3966
4063
|
}
|
|
3967
4064
|
}
|
|
3968
4065
|
),
|
|
3969
|
-
error !== null ? /* @__PURE__ */ (0,
|
|
4066
|
+
error !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__error", children: error }) : null
|
|
3970
4067
|
] }) : null
|
|
3971
4068
|
] });
|
|
3972
4069
|
}
|
|
@@ -4025,8 +4122,8 @@ async function playTestSound(sinkId) {
|
|
|
4025
4122
|
await context.close();
|
|
4026
4123
|
}
|
|
4027
4124
|
function useMicrophoneStream(deviceId) {
|
|
4028
|
-
const [stream, setStream] = (0,
|
|
4029
|
-
(0,
|
|
4125
|
+
const [stream, setStream] = (0, import_react10.useState)(null);
|
|
4126
|
+
(0, import_react10.useEffect)(() => {
|
|
4030
4127
|
if (deviceId === "off") return void 0;
|
|
4031
4128
|
let live = true;
|
|
4032
4129
|
let opened = null;
|
|
@@ -4051,31 +4148,31 @@ function useMicrophoneStream(deviceId) {
|
|
|
4051
4148
|
function LobbyPanel() {
|
|
4052
4149
|
const lobby = useLobby();
|
|
4053
4150
|
if (!lobby.canAdmit || lobby.waiting.length === 0) return null;
|
|
4054
|
-
return /* @__PURE__ */ (0,
|
|
4055
|
-
/* @__PURE__ */ (0,
|
|
4056
|
-
/* @__PURE__ */ (0,
|
|
4057
|
-
/* @__PURE__ */ (0,
|
|
4151
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("section", { className: "mx-meet__lobby", "aria-label": "Waiting room", children: [
|
|
4152
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("header", { className: "mx-meet__lobby-head", children: [
|
|
4153
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h3", { className: "mx-meet__lobby-title", children: lobby.waiting.length === 1 ? "1 person is waiting" : `${lobby.waiting.length} people are waiting` }),
|
|
4154
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("button", { type: "button", className: "mx-meet__link", onClick: () => void lobby.admitAll(), children: "Admit all" })
|
|
4058
4155
|
] }),
|
|
4059
|
-
/* @__PURE__ */ (0,
|
|
4156
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("ul", { className: "mx-meet__lobby-list", children: lobby.waiting.map((entry) => /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
4060
4157
|
"li",
|
|
4061
4158
|
{
|
|
4062
4159
|
className: "mx-meet__lobby-row",
|
|
4063
4160
|
"data-meet-lobby-entry": "",
|
|
4064
4161
|
"data-meet-participant-name": entry.displayName,
|
|
4065
4162
|
children: [
|
|
4066
|
-
/* @__PURE__ */ (0,
|
|
4067
|
-
/* @__PURE__ */ (0,
|
|
4163
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Avatar, { name: entry.displayName, url: entry.avatarUrl, size: 32 }),
|
|
4164
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__person-name", children: [
|
|
4068
4165
|
entry.displayName,
|
|
4069
|
-
entry.userId === null ? /* @__PURE__ */ (0,
|
|
4166
|
+
entry.userId === null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__badge", children: "Guest" }) : null
|
|
4070
4167
|
] }),
|
|
4071
|
-
/* @__PURE__ */ (0,
|
|
4072
|
-
/* @__PURE__ */ (0,
|
|
4168
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ControlButton, { label: `Admit ${entry.displayName}`, onClick: () => void lobby.admit(entry), children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CheckIcon, { width: 16, height: 16 }) }),
|
|
4169
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4073
4170
|
ControlButton,
|
|
4074
4171
|
{
|
|
4075
4172
|
label: `Deny ${entry.displayName}`,
|
|
4076
4173
|
danger: true,
|
|
4077
4174
|
onClick: () => void lobby.deny(entry),
|
|
4078
|
-
children: /* @__PURE__ */ (0,
|
|
4175
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CloseIcon, { width: 16, height: 16 })
|
|
4079
4176
|
}
|
|
4080
4177
|
)
|
|
4081
4178
|
]
|
|
@@ -4088,21 +4185,21 @@ function NoteTakerRow() {
|
|
|
4088
4185
|
const ai = useMeetAi();
|
|
4089
4186
|
const status = ai.noteTaker;
|
|
4090
4187
|
const duplicateError = status.refusal !== null && ai.error !== null && status.refusal.reason === ai.error.message && status.refusal.remedy === ai.error.remedy;
|
|
4091
|
-
return /* @__PURE__ */ (0,
|
|
4092
|
-
/* @__PURE__ */ (0,
|
|
4093
|
-
/* @__PURE__ */ (0,
|
|
4188
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("section", { className: "mx-meet__note-taker", "aria-label": "Note-taker", children: [
|
|
4189
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("p", { className: `mx-meet__note-taker-state mx-meet__note-taker-state--${status.state}`, children: [
|
|
4190
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__note-taker-dot", "aria-hidden": "true" }),
|
|
4094
4191
|
ai.noteTakerLabel
|
|
4095
4192
|
] }),
|
|
4096
|
-
status.detail !== null ? /* @__PURE__ */ (0,
|
|
4097
|
-
status.refusal !== null ? /* @__PURE__ */ (0,
|
|
4098
|
-
/* @__PURE__ */ (0,
|
|
4099
|
-
status.refusal.remedy.length > 0 ? /* @__PURE__ */ (0,
|
|
4193
|
+
status.detail !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__panel-note", children: status.detail }) : null,
|
|
4194
|
+
status.refusal !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_design_system.ErrorBox, { as: "div", className: "mx-meet__refusal", error: status.refusal, operation: "Join this meeting", origin: "meet/components", children: [
|
|
4195
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__refusal-reason", children: status.refusal.reason }),
|
|
4196
|
+
status.refusal.remedy.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__refusal-remedy", children: status.refusal.remedy }) : null
|
|
4100
4197
|
] }) : null,
|
|
4101
|
-
ai.error !== null && !duplicateError ? /* @__PURE__ */ (0,
|
|
4102
|
-
/* @__PURE__ */ (0,
|
|
4103
|
-
/* @__PURE__ */ (0,
|
|
4198
|
+
ai.error !== null && !duplicateError ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_design_system.ErrorBox, { as: "div", className: "mx-meet__refusal", error: ai.error, operation: "Run the meeting assistant", origin: "meet/components", children: [
|
|
4199
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__refusal-reason", children: ai.error.message }),
|
|
4200
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__refusal-remedy", children: ai.error.remedy })
|
|
4104
4201
|
] }) : null,
|
|
4105
|
-
ai.canControlNoteTaker ? status.state === "transcribing" || status.state === "joining" || status.state === "handoff_pending" ? /* @__PURE__ */ (0,
|
|
4202
|
+
ai.canControlNoteTaker ? status.state === "transcribing" || status.state === "joining" || status.state === "handoff_pending" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4106
4203
|
"button",
|
|
4107
4204
|
{
|
|
4108
4205
|
type: "button",
|
|
@@ -4110,7 +4207,7 @@ function NoteTakerRow() {
|
|
|
4110
4207
|
onClick: () => void ai.stopNoteTaker(),
|
|
4111
4208
|
children: "Dismiss the note-taker"
|
|
4112
4209
|
}
|
|
4113
|
-
) : /* @__PURE__ */ (0,
|
|
4210
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4114
4211
|
"button",
|
|
4115
4212
|
{
|
|
4116
4213
|
type: "button",
|
|
@@ -4126,24 +4223,24 @@ function NoteList({
|
|
|
4126
4223
|
notes,
|
|
4127
4224
|
empty
|
|
4128
4225
|
}) {
|
|
4129
|
-
return /* @__PURE__ */ (0,
|
|
4130
|
-
/* @__PURE__ */ (0,
|
|
4131
|
-
notes.length === 0 ? /* @__PURE__ */ (0,
|
|
4226
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("section", { className: "mx-meet__note-group", "aria-label": title, children: [
|
|
4227
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h3", { className: "mx-meet__note-group-title", children: title }),
|
|
4228
|
+
notes.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__panel-note", children: empty }) : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("ul", { className: "mx-meet__notes", children: notes.map((note) => /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("li", { className: "mx-meet__note", children: [
|
|
4132
4229
|
note.text,
|
|
4133
|
-
note.assigneeDisplayName !== void 0 && note.assigneeDisplayName !== null ? /* @__PURE__ */ (0,
|
|
4230
|
+
note.assigneeDisplayName !== void 0 && note.assigneeDisplayName !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__assignee", children: note.assigneeDisplayName }) : null
|
|
4134
4231
|
] }, note.id)) })
|
|
4135
4232
|
] });
|
|
4136
4233
|
}
|
|
4137
4234
|
function AiPanel({ onClose }) {
|
|
4138
4235
|
const ai = useMeetAi();
|
|
4139
|
-
const [question, setQuestion] = (0,
|
|
4140
|
-
return /* @__PURE__ */ (0,
|
|
4141
|
-
/* @__PURE__ */ (0,
|
|
4142
|
-
ai.summary !== null ? /* @__PURE__ */ (0,
|
|
4143
|
-
/* @__PURE__ */ (0,
|
|
4144
|
-
/* @__PURE__ */ (0,
|
|
4236
|
+
const [question, setQuestion] = (0, import_react10.useState)("");
|
|
4237
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(PanelShell, { title: "Meeting assistant", onClose, children: [
|
|
4238
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(NoteTakerRow, {}),
|
|
4239
|
+
ai.summary !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("section", { className: "mx-meet__note-group", "aria-label": "Summary", children: [
|
|
4240
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h3", { className: "mx-meet__note-group-title", children: "Summary" }),
|
|
4241
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__summary", children: ai.summary.text })
|
|
4145
4242
|
] }) : null,
|
|
4146
|
-
ai.wrapUp !== null ? /* @__PURE__ */ (0,
|
|
4243
|
+
ai.wrapUp !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("p", { className: "mx-meet__wrap-up-notice", role: "status", children: [
|
|
4147
4244
|
"The wrap-up is written \u2014 ",
|
|
4148
4245
|
ai.wrapUp.noteIds.length,
|
|
4149
4246
|
" ",
|
|
@@ -4155,7 +4252,7 @@ function AiPanel({ onClose }) {
|
|
|
4155
4252
|
ai.wrapUp.segmentCount === 1 ? "transcript line" : "transcript lines",
|
|
4156
4253
|
"."
|
|
4157
4254
|
] }) : null,
|
|
4158
|
-
/* @__PURE__ */ (0,
|
|
4255
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4159
4256
|
NoteList,
|
|
4160
4257
|
{
|
|
4161
4258
|
title: "Notes",
|
|
@@ -4163,7 +4260,7 @@ function AiPanel({ onClose }) {
|
|
|
4163
4260
|
empty: "Notes appear here as the meeting goes on."
|
|
4164
4261
|
}
|
|
4165
4262
|
),
|
|
4166
|
-
/* @__PURE__ */ (0,
|
|
4263
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4167
4264
|
NoteList,
|
|
4168
4265
|
{
|
|
4169
4266
|
title: "Decisions",
|
|
@@ -4171,7 +4268,7 @@ function AiPanel({ onClose }) {
|
|
|
4171
4268
|
empty: "Nothing has been decided yet."
|
|
4172
4269
|
}
|
|
4173
4270
|
),
|
|
4174
|
-
/* @__PURE__ */ (0,
|
|
4271
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4175
4272
|
NoteList,
|
|
4176
4273
|
{
|
|
4177
4274
|
title: "Action items",
|
|
@@ -4179,21 +4276,21 @@ function AiPanel({ onClose }) {
|
|
|
4179
4276
|
empty: "No action items yet."
|
|
4180
4277
|
}
|
|
4181
4278
|
),
|
|
4182
|
-
ai.transcript.length > 0 ? /* @__PURE__ */ (0,
|
|
4183
|
-
/* @__PURE__ */ (0,
|
|
4184
|
-
/* @__PURE__ */ (0,
|
|
4279
|
+
ai.transcript.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("section", { className: "mx-meet__note-group", "aria-label": "Transcript", children: [
|
|
4280
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h3", { className: "mx-meet__note-group-title", children: "Transcript" }),
|
|
4281
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("ul", { className: "mx-meet__transcript", children: ai.transcript.map((line) => /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
4185
4282
|
"li",
|
|
4186
4283
|
{
|
|
4187
4284
|
className: line.final && line.source === "record" ? "mx-meet__line" : "mx-meet__line mx-meet__line--interim",
|
|
4188
4285
|
children: [
|
|
4189
|
-
/* @__PURE__ */ (0,
|
|
4190
|
-
/* @__PURE__ */ (0,
|
|
4286
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("strong", { children: line.speaker }),
|
|
4287
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { children: line.text })
|
|
4191
4288
|
]
|
|
4192
4289
|
},
|
|
4193
4290
|
line.id
|
|
4194
4291
|
)) })
|
|
4195
4292
|
] }) : null,
|
|
4196
|
-
/* @__PURE__ */ (0,
|
|
4293
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
4197
4294
|
"form",
|
|
4198
4295
|
{
|
|
4199
4296
|
className: "mx-meet__composer",
|
|
@@ -4204,7 +4301,7 @@ function AiPanel({ onClose }) {
|
|
|
4204
4301
|
void ai.ask(asked);
|
|
4205
4302
|
},
|
|
4206
4303
|
children: [
|
|
4207
|
-
/* @__PURE__ */ (0,
|
|
4304
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4208
4305
|
"input",
|
|
4209
4306
|
{
|
|
4210
4307
|
className: "mx-meet__input",
|
|
@@ -4214,13 +4311,13 @@ function AiPanel({ onClose }) {
|
|
|
4214
4311
|
"aria-label": "Ask about this meeting"
|
|
4215
4312
|
}
|
|
4216
4313
|
),
|
|
4217
|
-
/* @__PURE__ */ (0,
|
|
4314
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("button", { type: "submit", className: "mx-meet__send", disabled: ai.asking, children: ai.asking ? "Asking\u2026" : "Ask" })
|
|
4218
4315
|
]
|
|
4219
4316
|
}
|
|
4220
4317
|
),
|
|
4221
|
-
ai.asking && ai.phase !== null ? /* @__PURE__ */ (0,
|
|
4222
|
-
ai.answer !== null ? /* @__PURE__ */ (0,
|
|
4223
|
-
ai.answer !== null && ai.coverage !== null ? /* @__PURE__ */ (0,
|
|
4318
|
+
ai.asking && ai.phase !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__panel-note", role: "status", children: ai.phase }) : null,
|
|
4319
|
+
ai.answer !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__answer", children: ai.answer }) : null,
|
|
4320
|
+
ai.answer !== null && ai.coverage !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("p", { className: "mx-meet__coverage", children: [
|
|
4224
4321
|
"Answered from ",
|
|
4225
4322
|
ai.coverage.segmentsUsed,
|
|
4226
4323
|
" of ",
|
|
@@ -4229,9 +4326,9 @@ function AiPanel({ onClose }) {
|
|
|
4229
4326
|
ai.coverage.truncated ? " (the oldest were left out)" : "",
|
|
4230
4327
|
"."
|
|
4231
4328
|
] }) : null,
|
|
4232
|
-
ai.error !== null ? /* @__PURE__ */ (0,
|
|
4233
|
-
/* @__PURE__ */ (0,
|
|
4234
|
-
/* @__PURE__ */ (0,
|
|
4329
|
+
ai.error !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_design_system.ErrorBox, { as: "div", className: "mx-meet__refusal", error: ai.error, operation: "Run the meeting assistant", origin: "meet/components", children: [
|
|
4330
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__refusal-reason", children: ai.error.message }),
|
|
4331
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__refusal-remedy", children: ai.error.remedy })
|
|
4235
4332
|
] }) : null
|
|
4236
4333
|
] });
|
|
4237
4334
|
}
|
|
@@ -4240,30 +4337,30 @@ function Captions({ lines = 3 }) {
|
|
|
4240
4337
|
const visible = ai.transcript.slice(-lines);
|
|
4241
4338
|
const translation = useCaptionTranslation(visible);
|
|
4242
4339
|
if (visible.length === 0) return null;
|
|
4243
|
-
return /* @__PURE__ */ (0,
|
|
4340
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__captions", "aria-live": "polite", "aria-label": "Live captions", children: [
|
|
4244
4341
|
visible.map((line) => {
|
|
4245
4342
|
const translated = translation.language === null ? void 0 : translation.translations[line.id];
|
|
4246
|
-
return /* @__PURE__ */ (0,
|
|
4343
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
4247
4344
|
"p",
|
|
4248
4345
|
{
|
|
4249
4346
|
className: line.final ? "mx-meet__caption" : "mx-meet__caption mx-meet__caption--interim",
|
|
4250
4347
|
children: [
|
|
4251
|
-
/* @__PURE__ */ (0,
|
|
4348
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("strong", { children: line.speaker }),
|
|
4252
4349
|
" ",
|
|
4253
4350
|
translated ?? line.text,
|
|
4254
|
-
translated !== void 0 ? /* @__PURE__ */ (0,
|
|
4351
|
+
translated !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__caption-original", children: line.text }) : null
|
|
4255
4352
|
]
|
|
4256
4353
|
},
|
|
4257
4354
|
line.id
|
|
4258
4355
|
);
|
|
4259
4356
|
}),
|
|
4260
|
-
translation.language !== null && translation.error !== null ? /* @__PURE__ */ (0,
|
|
4357
|
+
translation.language !== null && translation.error !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__caption mx-meet__caption--interim", children: translation.error }) : null
|
|
4261
4358
|
] });
|
|
4262
4359
|
}
|
|
4263
4360
|
function ConsentNotice() {
|
|
4264
4361
|
const notice = useConsentNotice();
|
|
4265
4362
|
if (notice === null) return null;
|
|
4266
|
-
return /* @__PURE__ */ (0,
|
|
4363
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__consent", role: "status", children: notice });
|
|
4267
4364
|
}
|
|
4268
4365
|
function AttendanceNotice() {
|
|
4269
4366
|
const media = useLocalMedia();
|
|
@@ -4271,7 +4368,7 @@ function AttendanceNotice() {
|
|
|
4271
4368
|
if (notice === null) return null;
|
|
4272
4369
|
const refused = media.microphone.unavailable;
|
|
4273
4370
|
const code = microphoneNoticeCode(media.microphone);
|
|
4274
|
-
return /* @__PURE__ */ (0,
|
|
4371
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
4275
4372
|
"p",
|
|
4276
4373
|
{
|
|
4277
4374
|
className: "mx-meet__banner mx-meet__banner--attendance",
|
|
@@ -4279,21 +4376,22 @@ function AttendanceNotice() {
|
|
|
4279
4376
|
...code !== null ? { "data-meet-notice": code } : {},
|
|
4280
4377
|
children: [
|
|
4281
4378
|
notice,
|
|
4282
|
-
refused === null ? null : /* @__PURE__ */ (0,
|
|
4379
|
+
refused === null ? null : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__remedy", children: refused.remedy })
|
|
4283
4380
|
]
|
|
4284
4381
|
}
|
|
4285
4382
|
);
|
|
4286
4383
|
}
|
|
4287
4384
|
function PreJoin(props) {
|
|
4288
4385
|
const host = useMeetHost();
|
|
4289
|
-
if (host === null) return /* @__PURE__ */ (0,
|
|
4290
|
-
return /* @__PURE__ */ (0,
|
|
4386
|
+
if (host === null) return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(InertNotice, { what: "This meeting" });
|
|
4387
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PreJoinBody, { ...props, host });
|
|
4291
4388
|
}
|
|
4292
4389
|
function PreJoinBody({
|
|
4293
4390
|
roomName,
|
|
4294
4391
|
meetingId,
|
|
4295
4392
|
slug,
|
|
4296
4393
|
onJoined,
|
|
4394
|
+
observe: observe2 = false,
|
|
4297
4395
|
host
|
|
4298
4396
|
}) {
|
|
4299
4397
|
const room = useRoom();
|
|
@@ -4301,21 +4399,21 @@ function PreJoinBody({
|
|
|
4301
4399
|
const recording = useRecording();
|
|
4302
4400
|
const effects = useMediaEffects();
|
|
4303
4401
|
const { notice } = useModerationNotice();
|
|
4304
|
-
const [mode, setMode] = (0,
|
|
4305
|
-
const [microphone, setMicrophone] = (0,
|
|
4306
|
-
const [joining, setJoining] = (0,
|
|
4402
|
+
const [mode, setMode] = (0, import_react10.useState)("video");
|
|
4403
|
+
const [microphone, setMicrophone] = (0, import_react10.useState)(true);
|
|
4404
|
+
const [joining, setJoining] = (0, import_react10.useState)(false);
|
|
4307
4405
|
const camera = devices?.selected.videoinput ?? host.devices.resolve("videoinput");
|
|
4308
4406
|
const mic = devices?.selected.audioinput ?? host.devices.resolve("audioinput");
|
|
4309
4407
|
const preview = useCameraPreview(mode === "video" ? camera : void 0, effects.effects);
|
|
4310
4408
|
const micStream = useMicrophoneStream(microphone ? mic : "off");
|
|
4311
4409
|
const level = useAudioLevel(micStream);
|
|
4312
|
-
const [speakerTesting, setSpeakerTesting] = (0,
|
|
4313
|
-
(0,
|
|
4410
|
+
const [speakerTesting, setSpeakerTesting] = (0, import_react10.useState)(false);
|
|
4411
|
+
(0, import_react10.useEffect)(() => {
|
|
4314
4412
|
void host.devices.refresh();
|
|
4315
4413
|
}, [host]);
|
|
4316
|
-
return /* @__PURE__ */ (0,
|
|
4317
|
-
/* @__PURE__ */ (0,
|
|
4318
|
-
mode === "video" && preview.preview !== null ? /* @__PURE__ */ (0,
|
|
4414
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__prejoin", children: [
|
|
4415
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__preview", children: [
|
|
4416
|
+
mode === "video" && preview.preview !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4319
4417
|
"video",
|
|
4320
4418
|
{
|
|
4321
4419
|
className: "mx-meet__video mx-meet__video--mirror",
|
|
@@ -4326,16 +4424,16 @@ function PreJoinBody({
|
|
|
4326
4424
|
if (element !== null) preview.preview?.attach(element);
|
|
4327
4425
|
}
|
|
4328
4426
|
}
|
|
4329
|
-
) : /* @__PURE__ */ (0,
|
|
4330
|
-
mode === "video" && preview.error !== null ? /* @__PURE__ */ (0,
|
|
4331
|
-
microphone && micStream !== null ? /* @__PURE__ */ (0,
|
|
4427
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__tile-placeholder", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Avatar, { name: host.identity.displayName, url: host.identity.avatarUrl, size: 96 }) }),
|
|
4428
|
+
mode === "video" && preview.error !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__preview-note", children: preview.error }) : null,
|
|
4429
|
+
microphone && micStream !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__meter mx-meet__meter--preview", role: "meter", "aria-label": "Microphone level", "aria-valuemin": 0, "aria-valuemax": 100, "aria-valuenow": Math.round(level * 100), children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { style: { width: `${Math.min(100, Math.round(level * 160))}%` } }) }) : null
|
|
4332
4430
|
] }),
|
|
4333
|
-
/* @__PURE__ */ (0,
|
|
4334
|
-
/* @__PURE__ */ (0,
|
|
4335
|
-
notice?.kind === "removed" ? /* @__PURE__ */ (0,
|
|
4336
|
-
devices?.labelsHidden === true ? /* @__PURE__ */ (0,
|
|
4431
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__prejoin-panel", children: [
|
|
4432
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h1", { className: "mx-meet__prejoin-title", children: "Ready to join?" }),
|
|
4433
|
+
notice?.kind === "removed" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__warning", children: notice.text }) : null,
|
|
4434
|
+
devices?.labelsHidden === true ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("p", { className: "mx-meet__panel-note", children: [
|
|
4337
4435
|
"Your browser is hiding device names until you allow camera and microphone access.",
|
|
4338
|
-
/* @__PURE__ */ (0,
|
|
4436
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4339
4437
|
"button",
|
|
4340
4438
|
{
|
|
4341
4439
|
type: "button",
|
|
@@ -4347,11 +4445,11 @@ function PreJoinBody({
|
|
|
4347
4445
|
}
|
|
4348
4446
|
)
|
|
4349
4447
|
] }) : null,
|
|
4350
|
-
devices?.fallbackNotice != null ? /* @__PURE__ */ (0,
|
|
4351
|
-
/* @__PURE__ */ (0,
|
|
4352
|
-
/* @__PURE__ */ (0,
|
|
4353
|
-
/* @__PURE__ */ (0,
|
|
4354
|
-
/* @__PURE__ */ (0,
|
|
4448
|
+
devices?.fallbackNotice != null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__warning", children: devices.fallbackNotice }) : null,
|
|
4449
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(DevicePicker, { kind: "audioinput", label: "Microphone" }),
|
|
4450
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__field-row", children: [
|
|
4451
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(DevicePicker, { kind: "audiooutput", label: "Speaker" }),
|
|
4452
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
4355
4453
|
import_design_system.Button,
|
|
4356
4454
|
{
|
|
4357
4455
|
type: "button",
|
|
@@ -4364,19 +4462,19 @@ function PreJoinBody({
|
|
|
4364
4462
|
);
|
|
4365
4463
|
},
|
|
4366
4464
|
children: [
|
|
4367
|
-
/* @__PURE__ */ (0,
|
|
4465
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(SpeakerIcon, {}),
|
|
4368
4466
|
" ",
|
|
4369
4467
|
speakerTesting ? "Playing\u2026" : "Test"
|
|
4370
4468
|
]
|
|
4371
4469
|
}
|
|
4372
4470
|
)
|
|
4373
4471
|
] }),
|
|
4374
|
-
/* @__PURE__ */ (0,
|
|
4375
|
-
/* @__PURE__ */ (0,
|
|
4376
|
-
recording.consentNotice !== null ? /* @__PURE__ */ (0,
|
|
4377
|
-
/* @__PURE__ */ (0,
|
|
4378
|
-
/* @__PURE__ */ (0,
|
|
4379
|
-
/* @__PURE__ */ (0,
|
|
4472
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(DevicePicker, { kind: "videoinput", label: "Camera" }),
|
|
4473
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(EffectsSettings, { preview: preview.preview }),
|
|
4474
|
+
recording.consentNotice !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Alert, { variant: "info", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.AlertDescription, { children: recording.consentNotice }) }) : null,
|
|
4475
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__prejoin-actions", children: [
|
|
4476
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__check", children: [
|
|
4477
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4380
4478
|
import_design_system.Checkbox,
|
|
4381
4479
|
{
|
|
4382
4480
|
id: "mx-meet-join-video",
|
|
@@ -4384,10 +4482,10 @@ function PreJoinBody({
|
|
|
4384
4482
|
onCheckedChange: (checked) => setMode(checked === true ? "video" : "audio")
|
|
4385
4483
|
}
|
|
4386
4484
|
),
|
|
4387
|
-
/* @__PURE__ */ (0,
|
|
4485
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Label, { htmlFor: "mx-meet-join-video", children: "Join with video" })
|
|
4388
4486
|
] }),
|
|
4389
|
-
/* @__PURE__ */ (0,
|
|
4390
|
-
/* @__PURE__ */ (0,
|
|
4487
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__check", children: [
|
|
4488
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4391
4489
|
import_design_system.Checkbox,
|
|
4392
4490
|
{
|
|
4393
4491
|
id: "mx-meet-join-mic",
|
|
@@ -4395,9 +4493,9 @@ function PreJoinBody({
|
|
|
4395
4493
|
onCheckedChange: (checked) => setMicrophone(checked === true)
|
|
4396
4494
|
}
|
|
4397
4495
|
),
|
|
4398
|
-
/* @__PURE__ */ (0,
|
|
4496
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Label, { htmlFor: "mx-meet-join-mic", children: "Join with microphone" })
|
|
4399
4497
|
] }),
|
|
4400
|
-
/* @__PURE__ */ (0,
|
|
4498
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4401
4499
|
import_design_system.Button,
|
|
4402
4500
|
{
|
|
4403
4501
|
type: "button",
|
|
@@ -4408,30 +4506,32 @@ function PreJoinBody({
|
|
|
4408
4506
|
preview.release();
|
|
4409
4507
|
void room.join({
|
|
4410
4508
|
roomName,
|
|
4411
|
-
|
|
4412
|
-
|
|
4509
|
+
// An observer publishes nothing: no camera, no microphone (MD-16).
|
|
4510
|
+
mode: observe2 ? "audio" : mode,
|
|
4511
|
+
microphone: observe2 ? false : microphone,
|
|
4413
4512
|
...meetingId !== void 0 ? { meetingId } : {},
|
|
4414
|
-
...slug !== void 0 ? { slug } : {}
|
|
4513
|
+
...slug !== void 0 ? { slug } : {},
|
|
4514
|
+
...observe2 ? { observe: true } : {}
|
|
4415
4515
|
}).then(() => onJoined?.()).catch(() => void 0).finally(() => setJoining(false));
|
|
4416
4516
|
},
|
|
4417
|
-
children: joining ? "Joining\u2026" : "Join now"
|
|
4517
|
+
children: joining ? "Joining\u2026" : observe2 ? "Observe" : "Join now"
|
|
4418
4518
|
}
|
|
4419
4519
|
)
|
|
4420
4520
|
] }),
|
|
4421
|
-
room.failure !== null ? /* @__PURE__ */ (0,
|
|
4521
|
+
room.failure !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("p", { className: "mx-meet__error", children: [
|
|
4422
4522
|
room.failure.message,
|
|
4423
|
-
/* @__PURE__ */ (0,
|
|
4523
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__remedy", children: room.failure.remedy })
|
|
4424
4524
|
] }) : null
|
|
4425
4525
|
] })
|
|
4426
4526
|
] });
|
|
4427
4527
|
}
|
|
4428
4528
|
function useCameraPreview(deviceId, effects) {
|
|
4429
|
-
const [preview, setPreview] = (0,
|
|
4430
|
-
const [error, setError] = (0,
|
|
4431
|
-
const current = (0,
|
|
4432
|
-
const initialEffect = (0,
|
|
4529
|
+
const [preview, setPreview] = (0, import_react10.useState)(null);
|
|
4530
|
+
const [error, setError] = (0, import_react10.useState)(null);
|
|
4531
|
+
const current = (0, import_react10.useRef)(null);
|
|
4532
|
+
const initialEffect = (0, import_react10.useRef)(toVideoEffect(effects));
|
|
4433
4533
|
initialEffect.current = toVideoEffect(effects);
|
|
4434
|
-
(0,
|
|
4534
|
+
(0, import_react10.useEffect)(() => {
|
|
4435
4535
|
if (deviceId === void 0) return void 0;
|
|
4436
4536
|
let live = true;
|
|
4437
4537
|
setError(null);
|
|
@@ -4478,9 +4578,9 @@ function DevicePicker({
|
|
|
4478
4578
|
const triggerId = `mx-meet-device-${kind}`;
|
|
4479
4579
|
const valueOf = (deviceId) => deviceId.length > 0 ? deviceId : "default";
|
|
4480
4580
|
const current = devices?.selected[kind] ?? host.devices.resolve(kind) ?? "";
|
|
4481
|
-
return /* @__PURE__ */ (0,
|
|
4482
|
-
/* @__PURE__ */ (0,
|
|
4483
|
-
/* @__PURE__ */ (0,
|
|
4581
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__field", children: [
|
|
4582
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Label, { htmlFor: triggerId, children: label }),
|
|
4583
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
4484
4584
|
import_design_system.Select,
|
|
4485
4585
|
{
|
|
4486
4586
|
...current.length > 0 ? { value: valueOf(current) } : {},
|
|
@@ -4490,8 +4590,8 @@ function DevicePicker({
|
|
|
4490
4590
|
else host.devices.select(kind, deviceId);
|
|
4491
4591
|
},
|
|
4492
4592
|
children: [
|
|
4493
|
-
/* @__PURE__ */ (0,
|
|
4494
|
-
/* @__PURE__ */ (0,
|
|
4593
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.SelectTrigger, { id: triggerId, "aria-label": label, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.SelectValue, { placeholder: label }) }),
|
|
4594
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.SelectContent, { children: list.map((device) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.SelectItem, { value: valueOf(device.deviceId), children: device.label.length > 0 ? device.label : `${label} (name hidden)` }, device.deviceId || "default")) })
|
|
4495
4595
|
]
|
|
4496
4596
|
}
|
|
4497
4597
|
)
|
|
@@ -4502,73 +4602,113 @@ function MeetSkinRoom({
|
|
|
4502
4602
|
meetingId,
|
|
4503
4603
|
slug,
|
|
4504
4604
|
onLeave,
|
|
4505
|
-
headerControls
|
|
4605
|
+
headerControls,
|
|
4606
|
+
observe: observe2 = false
|
|
4506
4607
|
}) {
|
|
4507
4608
|
const { host, snapshot, isHost } = useMeetCore();
|
|
4508
4609
|
const elapsed = useElapsed(snapshot?.meeting?.startedAt ?? null);
|
|
4509
4610
|
const phase = snapshot?.phase ?? "idle";
|
|
4510
4611
|
if (host === null) return null;
|
|
4511
4612
|
if (phase === "idle" || phase === "failed" || phase === "left") {
|
|
4512
|
-
return /* @__PURE__ */ (0,
|
|
4613
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4513
4614
|
PreJoin,
|
|
4514
4615
|
{
|
|
4515
4616
|
roomName,
|
|
4516
4617
|
...meetingId !== void 0 ? { meetingId } : {},
|
|
4517
|
-
...slug !== void 0 ? { slug } : {}
|
|
4618
|
+
...slug !== void 0 ? { slug } : {},
|
|
4619
|
+
observe: observe2
|
|
4518
4620
|
}
|
|
4519
4621
|
) });
|
|
4520
4622
|
}
|
|
4521
4623
|
if (phase === "lobby") {
|
|
4522
|
-
return /* @__PURE__ */ (0,
|
|
4624
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet mx-meet--lobby", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(WaitingRoom, { host, ...onLeave !== void 0 ? { onLeave } : {} }) });
|
|
4523
4625
|
}
|
|
4524
|
-
return /* @__PURE__ */ (0,
|
|
4525
|
-
/* @__PURE__ */ (0,
|
|
4526
|
-
/* @__PURE__ */ (0,
|
|
4527
|
-
/* @__PURE__ */ (0,
|
|
4528
|
-
/* @__PURE__ */ (0,
|
|
4529
|
-
/* @__PURE__ */ (0,
|
|
4626
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet", children: [
|
|
4627
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ConsentNotice, {}),
|
|
4628
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(AttendanceNotice, {}),
|
|
4629
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("header", { className: "mx-meet__header", children: [
|
|
4630
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h1", { className: "mx-meet__title", children: snapshot?.meeting?.title ?? "Meeting" }),
|
|
4631
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__meta", children: [
|
|
4530
4632
|
participantSummary(snapshot?.participants ?? []),
|
|
4531
4633
|
elapsed > 0 ? ` \xB7 ${(0, import_format2.formatDurationMs)(elapsed)}` : ""
|
|
4532
4634
|
] }),
|
|
4533
|
-
/* @__PURE__ */ (0,
|
|
4534
|
-
snapshot?.
|
|
4535
|
-
|
|
4635
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(RecordingIndicator, {}),
|
|
4636
|
+
isObserverRole(snapshot?.grants.role) ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__badge", "data-meet-observing": "self", children: "Observing" }) : null,
|
|
4637
|
+
snapshot?.locked === true ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__badge", children: [
|
|
4638
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(LockIcon, { width: 12, height: 12 }),
|
|
4536
4639
|
" Locked"
|
|
4537
4640
|
] }) : null,
|
|
4538
|
-
headerControls !== void 0 && headerControls !== null ? /* @__PURE__ */ (0,
|
|
4539
|
-
isHost ? /* @__PURE__ */ (0,
|
|
4641
|
+
headerControls !== void 0 && headerControls !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__header-controls", "data-meet-header-controls": "", children: headerControls }) : null,
|
|
4642
|
+
isHost ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(HostMenu, {}) : null
|
|
4540
4643
|
] }),
|
|
4541
|
-
phase === "reconnecting" ? /* @__PURE__ */ (0,
|
|
4542
|
-
/* @__PURE__ */ (0,
|
|
4543
|
-
/* @__PURE__ */ (0,
|
|
4544
|
-
/* @__PURE__ */ (0,
|
|
4644
|
+
phase === "reconnecting" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__banner", role: "status", children: "Reconnecting\u2026" }) : null,
|
|
4645
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Stage, {}),
|
|
4646
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Captions, {}),
|
|
4647
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ControlBar, { ...onLeave !== void 0 ? { onLeave } : {} })
|
|
4545
4648
|
] });
|
|
4546
4649
|
}
|
|
4547
|
-
function WaitingRoom({
|
|
4548
|
-
const
|
|
4549
|
-
(0,
|
|
4550
|
-
|
|
4551
|
-
|
|
4552
|
-
|
|
4553
|
-
|
|
4554
|
-
|
|
4555
|
-
|
|
4556
|
-
|
|
4557
|
-
|
|
4558
|
-
|
|
4559
|
-
|
|
4560
|
-
|
|
4561
|
-
|
|
4650
|
+
function WaitingRoom({ host, onLeave }) {
|
|
4651
|
+
const { waiting, withdraw, askAgain } = useWaiting();
|
|
4652
|
+
const [busy, setBusy] = (0, import_react10.useState)(false);
|
|
4653
|
+
const admission = waiting?.admission ?? "knocking";
|
|
4654
|
+
const run = (action) => () => {
|
|
4655
|
+
setBusy(true);
|
|
4656
|
+
void action().catch(() => void 0).finally(() => setBusy(false));
|
|
4657
|
+
};
|
|
4658
|
+
const home = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Button, { type: "button", variant: "outline", onClick: () => onLeave !== void 0 ? onLeave() : window.location.assign("/"), children: "Back to home" });
|
|
4659
|
+
let title;
|
|
4660
|
+
let line = null;
|
|
4661
|
+
let actions;
|
|
4662
|
+
switch (admission) {
|
|
4663
|
+
case "waiting_host":
|
|
4664
|
+
title = "Waiting for the host to start";
|
|
4665
|
+
actions = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Button, { type: "button", variant: "outline", disabled: busy, onClick: run(withdraw), children: "Leave" });
|
|
4666
|
+
break;
|
|
4667
|
+
case "denied":
|
|
4668
|
+
title = "The host declined your request";
|
|
4669
|
+
actions = /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_jsx_runtime6.Fragment, { children: [
|
|
4670
|
+
waiting?.reknockAllowed === true ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Button, { type: "button", disabled: busy, onClick: run(askAgain), children: "Ask to join again" }) : null,
|
|
4671
|
+
home
|
|
4672
|
+
] });
|
|
4673
|
+
break;
|
|
4674
|
+
case "expired":
|
|
4675
|
+
title = "No one responded";
|
|
4676
|
+
actions = /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_jsx_runtime6.Fragment, { children: [
|
|
4677
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Button, { type: "button", disabled: busy, onClick: run(askAgain), children: "Ask again" }),
|
|
4678
|
+
home
|
|
4679
|
+
] });
|
|
4680
|
+
break;
|
|
4681
|
+
case "withdrawn":
|
|
4682
|
+
title = "You left the waiting room";
|
|
4683
|
+
actions = /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_jsx_runtime6.Fragment, { children: [
|
|
4684
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Button, { type: "button", disabled: busy, onClick: run(askAgain), children: "Rejoin" }),
|
|
4685
|
+
home
|
|
4686
|
+
] });
|
|
4687
|
+
break;
|
|
4688
|
+
case "ended":
|
|
4689
|
+
title = "The meeting has ended";
|
|
4690
|
+
actions = home;
|
|
4691
|
+
break;
|
|
4692
|
+
default:
|
|
4693
|
+
title = "Waiting for the host to let you in";
|
|
4694
|
+
line = waiting?.admittersPresent === false ? "The host isn't here yet" : null;
|
|
4695
|
+
actions = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_design_system.Button, { type: "button", variant: "outline", disabled: busy, onClick: run(withdraw), children: "Cancel request" });
|
|
4696
|
+
}
|
|
4697
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__waiting", children: [
|
|
4698
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Avatar, { name: host.identity.displayName, url: host.identity.avatarUrl, size: 72 }),
|
|
4699
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h1", { className: "mx-meet__prejoin-title", children: title }),
|
|
4700
|
+
line !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__empty-body", role: "status", "data-meet-notice": "host-absent", children: line }) : null,
|
|
4701
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__waiting-actions", children: actions })
|
|
4562
4702
|
] });
|
|
4563
4703
|
}
|
|
4564
4704
|
function HostMenu() {
|
|
4565
4705
|
const host = useRequiredMeetHost();
|
|
4566
4706
|
const snapshot = useMeetSnapshot();
|
|
4567
4707
|
const end = useEndMeeting();
|
|
4568
|
-
const [confirmingEnd, setConfirmingEnd] = (0,
|
|
4708
|
+
const [confirmingEnd, setConfirmingEnd] = (0, import_react10.useState)(false);
|
|
4569
4709
|
const locked = snapshot?.locked === true;
|
|
4570
|
-
return /* @__PURE__ */ (0,
|
|
4571
|
-
/* @__PURE__ */ (0,
|
|
4710
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "mx-meet__host-menu", children: [
|
|
4711
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4572
4712
|
"button",
|
|
4573
4713
|
{
|
|
4574
4714
|
type: "button",
|
|
@@ -4579,9 +4719,9 @@ function HostMenu() {
|
|
|
4579
4719
|
children: locked ? "Unlock meeting" : "Lock meeting"
|
|
4580
4720
|
}
|
|
4581
4721
|
),
|
|
4582
|
-
end.canEnd ? confirmingEnd ? /* @__PURE__ */ (0,
|
|
4583
|
-
/* @__PURE__ */ (0,
|
|
4584
|
-
/* @__PURE__ */ (0,
|
|
4722
|
+
end.canEnd ? confirmingEnd ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "mx-meet__confirm", role: "group", "aria-label": "End this meeting?", children: [
|
|
4723
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__confirm-text", children: "End it for everyone? Every participant is disconnected, the note-taker stops, and the wrap-up is written. Nobody can rejoin this meeting afterwards." }),
|
|
4724
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4585
4725
|
"button",
|
|
4586
4726
|
{
|
|
4587
4727
|
type: "button",
|
|
@@ -4593,7 +4733,7 @@ function HostMenu() {
|
|
|
4593
4733
|
children: "End it"
|
|
4594
4734
|
}
|
|
4595
4735
|
),
|
|
4596
|
-
/* @__PURE__ */ (0,
|
|
4736
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4597
4737
|
"button",
|
|
4598
4738
|
{
|
|
4599
4739
|
type: "button",
|
|
@@ -4602,7 +4742,7 @@ function HostMenu() {
|
|
|
4602
4742
|
children: "Keep it running"
|
|
4603
4743
|
}
|
|
4604
4744
|
)
|
|
4605
|
-
] }) : /* @__PURE__ */ (0,
|
|
4745
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4606
4746
|
"button",
|
|
4607
4747
|
{
|
|
4608
4748
|
type: "button",
|
|
@@ -4611,14 +4751,14 @@ function HostMenu() {
|
|
|
4611
4751
|
children: end.ending ? "Ending\u2026" : "End meeting for everyone"
|
|
4612
4752
|
}
|
|
4613
4753
|
) : null,
|
|
4614
|
-
end.notice !== null ? /* @__PURE__ */ (0,
|
|
4754
|
+
end.notice !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__notice", role: "status", children: end.notice }) : null
|
|
4615
4755
|
] });
|
|
4616
4756
|
}
|
|
4617
4757
|
function ReactionOverlay({
|
|
4618
4758
|
reactions
|
|
4619
4759
|
}) {
|
|
4620
4760
|
if (reactions.length === 0) return null;
|
|
4621
|
-
return /* @__PURE__ */ (0,
|
|
4761
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "mx-meet__reactions", "aria-hidden": "true", children: reactions.map((reaction) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__reaction", children: reaction.emoji }, reaction.id)) });
|
|
4622
4762
|
}
|
|
4623
4763
|
function clockOf(iso) {
|
|
4624
4764
|
const at = new Date(iso);
|
|
@@ -4635,11 +4775,11 @@ function GuestRecordAccessControl({
|
|
|
4635
4775
|
const isHost = inRoomHost || viewerId !== null && meeting.hostUserId === viewerId;
|
|
4636
4776
|
if (host === null || !isHost) return null;
|
|
4637
4777
|
const resolved = access.setting === "default" && access.effective !== null ? ` Right now that means: ${guestRecordAccessLabel(access.effective.level).toLowerCase()}.` : "";
|
|
4638
|
-
return /* @__PURE__ */ (0,
|
|
4639
|
-
/* @__PURE__ */ (0,
|
|
4640
|
-
/* @__PURE__ */ (0,
|
|
4641
|
-
/* @__PURE__ */ (0,
|
|
4642
|
-
/* @__PURE__ */ (0,
|
|
4778
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("section", { className: "mx-meet__record-section", "aria-label": "What guests may read", children: [
|
|
4779
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h2", { className: "mx-meet__record-section-title", children: "What guests may read" }),
|
|
4780
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("label", { className: "mx-meet__field", children: [
|
|
4781
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "mx-meet__field-label", children: "People who attended by link, without an account" }),
|
|
4782
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
4643
4783
|
"select",
|
|
4644
4784
|
{
|
|
4645
4785
|
className: "mx-meet__select",
|
|
@@ -4650,18 +4790,18 @@ function GuestRecordAccessControl({
|
|
|
4650
4790
|
event.target.value
|
|
4651
4791
|
);
|
|
4652
4792
|
},
|
|
4653
|
-
children: GUEST_RECORD_ACCESS_CHOICES.map((choice) => /* @__PURE__ */ (0,
|
|
4793
|
+
children: GUEST_RECORD_ACCESS_CHOICES.map((choice) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("option", { value: choice, children: guestRecordAccessLabel(choice) }, choice))
|
|
4654
4794
|
}
|
|
4655
4795
|
)
|
|
4656
4796
|
] }),
|
|
4657
|
-
/* @__PURE__ */ (0,
|
|
4797
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("p", { className: "mx-meet__panel-note", children: [
|
|
4658
4798
|
guestRecordAccessExplanation(access.setting),
|
|
4659
4799
|
resolved
|
|
4660
4800
|
] }),
|
|
4661
|
-
access.saving ? /* @__PURE__ */ (0,
|
|
4662
|
-
access.error !== null ? /* @__PURE__ */ (0,
|
|
4663
|
-
/* @__PURE__ */ (0,
|
|
4664
|
-
/* @__PURE__ */ (0,
|
|
4801
|
+
access.saving ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__panel-note", role: "status", children: "Saving what guests may read\u2026" }) : null,
|
|
4802
|
+
access.error !== null ? /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_design_system.ErrorBox, { as: "div", className: "mx-meet__refusal", error: access.error, operation: "Change who can join", origin: "meet/components", children: [
|
|
4803
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__refusal-reason", children: access.error.message }),
|
|
4804
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: "mx-meet__refusal-remedy", children: access.error.remedy })
|
|
4665
4805
|
] }) : null
|
|
4666
4806
|
] });
|
|
4667
4807
|
}
|