@100mslive/roomkit-react 0.3.22-alpha.1 → 0.3.22-alpha.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (132) hide show
  1. package/dist/ConferenceScreen-CSVWECB5.js +1778 -0
  2. package/dist/ConferenceScreen-CSVWECB5.js.map +7 -0
  3. package/dist/ConferenceScreen-YRURU3RV.css +2780 -0
  4. package/dist/{HLSView-Z2JID2W7.css.map → ConferenceScreen-YRURU3RV.css.map} +1 -1
  5. package/dist/EmbedView-N2E4DZQA.js +17 -0
  6. package/dist/EmbedView-N2E4DZQA.js.map +7 -0
  7. package/dist/EmbedView-S54NTHF5.css +2780 -0
  8. package/dist/EmbedView-S54NTHF5.css.map +7 -0
  9. package/dist/EmojiReaction-3X4ST4AU.js +11 -0
  10. package/dist/EmojiReaction-3X4ST4AU.js.map +7 -0
  11. package/dist/{HLSView-LCFZPBH3.js → HLSView-EYGGK6BH.js} +38 -24
  12. package/dist/HLSView-EYGGK6BH.js.map +7 -0
  13. package/dist/{HLSView-Z2JID2W7.css → HLSView-LBTFLMI4.css} +3 -3
  14. package/dist/HLSView-LBTFLMI4.css.map +7 -0
  15. package/dist/LeaveScreen-D6XU64JL.js +556 -0
  16. package/dist/LeaveScreen-D6XU64JL.js.map +7 -0
  17. package/dist/LeaveScreen-ZAG5UJZL.css +2780 -0
  18. package/dist/LeaveScreen-ZAG5UJZL.css.map +7 -0
  19. package/dist/MoreSettings-R7B4BSNT.css +2780 -0
  20. package/dist/MoreSettings-R7B4BSNT.css.map +7 -0
  21. package/dist/MoreSettings-TBJVM7OY.js +16 -0
  22. package/dist/MoreSettings-TBJVM7OY.js.map +7 -0
  23. package/dist/PDFView-JOIJDP65.js +84 -0
  24. package/dist/PDFView-JOIJDP65.js.map +7 -0
  25. package/dist/PDFView-RMR33QH4.css +2780 -0
  26. package/dist/PDFView-RMR33QH4.css.map +7 -0
  27. package/dist/Polls-IN3V2HFI.js +1584 -0
  28. package/dist/Polls-IN3V2HFI.js.map +7 -0
  29. package/dist/Polls-JW7JWGTE.css +2780 -0
  30. package/dist/Polls-JW7JWGTE.css.map +7 -0
  31. package/dist/Prebuilt/components/Notifications/RoleChangeNotification.d.ts +1 -0
  32. package/dist/RaiseHand-WES4KKMD.js +10 -0
  33. package/dist/RaiseHand-WES4KKMD.js.map +7 -0
  34. package/dist/RoleProminence-4ZBDBCMU.css +2780 -0
  35. package/dist/RoleProminence-4ZBDBCMU.css.map +7 -0
  36. package/dist/RoleProminence-PB32DLIB.js +116 -0
  37. package/dist/RoleProminence-PB32DLIB.js.map +7 -0
  38. package/dist/RoomDetailsPane-CZH2SNLE.js +53 -0
  39. package/dist/RoomDetailsPane-CZH2SNLE.js.map +7 -0
  40. package/dist/RoomDetailsPane-XWH2KEFI.css +2780 -0
  41. package/dist/RoomDetailsPane-XWH2KEFI.css.map +7 -0
  42. package/dist/ScreenshareLayout-XVENPVK3.js +358 -0
  43. package/dist/ScreenshareLayout-XVENPVK3.js.map +7 -0
  44. package/dist/ScreenshareLayout-YUW3KHAB.css +2780 -0
  45. package/dist/ScreenshareLayout-YUW3KHAB.css.map +7 -0
  46. package/dist/SidePaneTabs-QXCDHOGG.js +1354 -0
  47. package/dist/SidePaneTabs-QXCDHOGG.js.map +7 -0
  48. package/dist/SidePaneTabs-WQGVOWRP.css +2780 -0
  49. package/dist/SidePaneTabs-WQGVOWRP.css.map +7 -0
  50. package/dist/VBPicker-XN74N67R.js +322 -0
  51. package/dist/VBPicker-XN74N67R.js.map +7 -0
  52. package/dist/VBPicker-YDM2YIOM.css +2780 -0
  53. package/dist/VBPicker-YDM2YIOM.css.map +7 -0
  54. package/dist/WaitingView-77PRTIBV.js +10 -0
  55. package/dist/WaitingView-77PRTIBV.js.map +7 -0
  56. package/dist/WhiteboardLayout-FZC7SOSG.js +96 -0
  57. package/dist/WhiteboardLayout-FZC7SOSG.js.map +7 -0
  58. package/dist/WhiteboardLayout-MNTUWEVK.css +2780 -0
  59. package/dist/WhiteboardLayout-MNTUWEVK.css.map +7 -0
  60. package/dist/android-perm-1.png +0 -0
  61. package/dist/audio-level.png +0 -0
  62. package/dist/chunk-26D5FDBW.js +16812 -0
  63. package/dist/chunk-26D5FDBW.js.map +7 -0
  64. package/dist/chunk-2J5WS52X.js +2595 -0
  65. package/dist/chunk-2J5WS52X.js.map +7 -0
  66. package/dist/chunk-2LWOQMYY.js +30 -0
  67. package/dist/chunk-2LWOQMYY.js.map +7 -0
  68. package/dist/chunk-3MRQJSIY.js +171 -0
  69. package/dist/chunk-3MRQJSIY.js.map +7 -0
  70. package/dist/chunk-4X4WB7X3.js +98 -0
  71. package/dist/chunk-4X4WB7X3.js.map +7 -0
  72. package/dist/chunk-7QZJMUHM.js +90 -0
  73. package/dist/chunk-7QZJMUHM.js.map +7 -0
  74. package/dist/chunk-ABCV7TX5.js +71 -0
  75. package/dist/chunk-ABCV7TX5.js.map +7 -0
  76. package/dist/chunk-BQOT4DK7.js +418 -0
  77. package/dist/chunk-BQOT4DK7.js.map +7 -0
  78. package/dist/chunk-ENHSO6YN.js +6337 -0
  79. package/dist/chunk-ENHSO6YN.js.map +7 -0
  80. package/dist/chunk-JKWX7W4K.js +161 -0
  81. package/dist/chunk-JKWX7W4K.js.map +7 -0
  82. package/dist/chunk-LO4BXA4G.js +114 -0
  83. package/dist/chunk-LO4BXA4G.js.map +7 -0
  84. package/dist/chunk-MRVWNFXC.js +59 -0
  85. package/dist/chunk-MRVWNFXC.js.map +7 -0
  86. package/dist/chunk-OA4HW7HW.js +262 -0
  87. package/dist/chunk-OA4HW7HW.js.map +7 -0
  88. package/dist/chunk-PJQSPAFZ.js +178 -0
  89. package/dist/chunk-PJQSPAFZ.js.map +7 -0
  90. package/dist/chunk-QHQKY35W.js +830 -0
  91. package/dist/chunk-QHQKY35W.js.map +7 -0
  92. package/dist/chunk-QKXHQ6DV.js +254 -0
  93. package/dist/chunk-QKXHQ6DV.js.map +7 -0
  94. package/dist/chunk-RTWNTT77.js +62 -0
  95. package/dist/chunk-RTWNTT77.js.map +7 -0
  96. package/dist/chunk-TBXRX6MK.js +576 -0
  97. package/dist/chunk-TBXRX6MK.js.map +7 -0
  98. package/dist/chunk-TCOPR3BK.js +487 -0
  99. package/dist/chunk-TCOPR3BK.js.map +7 -0
  100. package/dist/chunk-VKORP2LF.js +41 -0
  101. package/dist/chunk-VKORP2LF.js.map +7 -0
  102. package/dist/chunk-YYVDCP5Z.js +136 -0
  103. package/dist/chunk-YYVDCP5Z.js.map +7 -0
  104. package/dist/empty-chat.svg +12 -0
  105. package/dist/index.cjs.css +2 -2
  106. package/dist/index.cjs.css.map +1 -1
  107. package/dist/index.cjs.js +17888 -17792
  108. package/dist/index.cjs.js.map +4 -4
  109. package/dist/index.css +2 -2
  110. package/dist/index.css.map +1 -1
  111. package/dist/index.js +25 -15
  112. package/dist/ios-perm-0.png +0 -0
  113. package/dist/meta.cjs.json +5326 -5184
  114. package/dist/meta.esbuild.json +8960 -6320
  115. package/dist/pdf-share.png +0 -0
  116. package/dist/screen-share.png +0 -0
  117. package/dist/transaction_error.svg +12 -0
  118. package/package.json +7 -7
  119. package/src/Prebuilt/App.tsx +6 -2
  120. package/src/Prebuilt/components/Chat/Chat.tsx +12 -8
  121. package/src/Prebuilt/components/Chat/ChatFooter.tsx +1 -1
  122. package/src/Prebuilt/components/Notifications/Notifications.tsx +2 -0
  123. package/src/Prebuilt/components/Notifications/PeerNotifications.tsx +0 -14
  124. package/src/Prebuilt/components/Notifications/RoleChangeNotification.tsx +24 -0
  125. package/src/Prebuilt/components/VideoLayouts/GridLayout.tsx +43 -31
  126. package/src/Prebuilt/layouts/HLSView.jsx +1 -0
  127. package/src/Prebuilt/layouts/PDFView.jsx +1 -0
  128. package/src/Prebuilt/layouts/SidePane.tsx +12 -6
  129. package/src/Prebuilt/layouts/VideoStreamingSection.tsx +35 -34
  130. package/dist/HLSView-LCFZPBH3.js.map +0 -7
  131. package/dist/chunk-CRGZUJSX.js +0 -34811
  132. package/dist/chunk-CRGZUJSX.js.map +0 -7
@@ -0,0 +1,830 @@
1
+ import {
2
+ useSidepaneResetOnLayoutUpdate
3
+ } from "./chunk-2LWOQMYY.js";
4
+ import {
5
+ Accordion,
6
+ Button,
7
+ ConnectionIndicator,
8
+ HorizontalDivider,
9
+ Input,
10
+ RoleChangeModal,
11
+ useIsSidepaneTypeOpen,
12
+ useSidepaneToggle
13
+ } from "./chunk-26D5FDBW.js";
14
+ import {
15
+ Text
16
+ } from "./chunk-JKWX7W4K.js";
17
+ import {
18
+ Dropdown,
19
+ ToastManager,
20
+ useParticipants
21
+ } from "./chunk-BQOT4DK7.js";
22
+ import {
23
+ Box,
24
+ Flex
25
+ } from "./chunk-7QZJMUHM.js";
26
+ import {
27
+ IconButton_default,
28
+ getFormattedCount,
29
+ getMetadata,
30
+ textEllipsis,
31
+ useRoomLayoutConferencingScreen
32
+ } from "./chunk-ENHSO6YN.js";
33
+ import {
34
+ SIDE_PANE_OPTIONS,
35
+ __async,
36
+ __spreadProps,
37
+ __spreadValues,
38
+ config,
39
+ init_define_process_env
40
+ } from "./chunk-TBXRX6MK.js";
41
+
42
+ // src/Prebuilt/components/Footer/ParticipantList.tsx
43
+ init_define_process_env();
44
+ import React4, { Fragment, useCallback, useState as useState3 } from "react";
45
+ import { useDebounce, useMedia } from "react-use";
46
+ import {
47
+ HMSPeerType,
48
+ selectAvailableRoleNames,
49
+ selectHandRaisedPeers,
50
+ selectHasPeerHandRaised,
51
+ selectIsLargeRoom as selectIsLargeRoom2,
52
+ selectIsPeerAudioEnabled,
53
+ selectLocalPeerID as selectLocalPeerID2,
54
+ selectPeerCount,
55
+ selectPermissions as selectPermissions5,
56
+ useHMSStore as useHMSStore6
57
+ } from "@100mslive/react-sdk";
58
+ import {
59
+ AddIcon as AddIcon2,
60
+ CallIcon,
61
+ ChangeRoleIcon,
62
+ CrossIcon as CrossIcon2,
63
+ HandIcon,
64
+ MicOffIcon as MicOffIcon2,
65
+ PeopleIcon,
66
+ PersonSettingsIcon,
67
+ SearchIcon,
68
+ VerticalMenuIcon as VerticalMenuIcon2
69
+ } from "@100mslive/react-icons";
70
+
71
+ // src/Prebuilt/components/RemoveParticipant.tsx
72
+ init_define_process_env();
73
+ import React from "react";
74
+ import { selectLocalPeerID, selectPermissions, useHMSActions, useHMSStore } from "@100mslive/react-sdk";
75
+ import { PeopleRemoveIcon } from "@100mslive/react-icons";
76
+ var RemoveParticipant = ({ peerId }) => {
77
+ var _a;
78
+ const canRemoveOthers = (_a = useHMSStore(selectPermissions)) == null ? void 0 : _a.removeOthers;
79
+ const localPeerId = useHMSStore(selectLocalPeerID);
80
+ const actions = useHMSActions();
81
+ if (peerId === localPeerId || !canRemoveOthers) {
82
+ return null;
83
+ }
84
+ return /* @__PURE__ */ React.createElement(
85
+ Dropdown.Item,
86
+ {
87
+ css: { color: "$alert_error_default", bg: "$surface_default" },
88
+ onClick: () => __async(void 0, null, function* () {
89
+ try {
90
+ yield actions.removePeer(peerId, "");
91
+ } catch (error) {
92
+ const ex = error;
93
+ ToastManager.addToast({ title: ex.message, variant: "error" });
94
+ }
95
+ })
96
+ },
97
+ /* @__PURE__ */ React.createElement(PeopleRemoveIcon, null),
98
+ /* @__PURE__ */ React.createElement(Text, { variant: "sm", css: { ml: "$4", color: "inherit", fontWeight: "$semiBold" } }, "Remove Participant")
99
+ );
100
+ };
101
+
102
+ // src/Prebuilt/components/Footer/RoleAccordion.tsx
103
+ init_define_process_env();
104
+ import React3, { useEffect } from "react";
105
+ import { useMeasure } from "react-use";
106
+ import { FixedSizeList } from "react-window";
107
+ import { selectIsLargeRoom, useHMSStore as useHMSStore4, usePaginatedParticipants } from "@100mslive/react-sdk";
108
+ import { AddIcon, ChevronRightIcon, CrossIcon } from "@100mslive/react-icons";
109
+
110
+ // src/Prebuilt/components/Footer/RoleOptions.tsx
111
+ init_define_process_env();
112
+ import React2, { useState } from "react";
113
+ import { match } from "ts-pattern";
114
+ import {
115
+ selectPermissions as selectPermissions2,
116
+ selectRoleByRoleName,
117
+ selectTracksMap,
118
+ useHMSActions as useHMSActions2,
119
+ useHMSStore as useHMSStore2
120
+ } from "@100mslive/react-sdk";
121
+ import {
122
+ MicOffIcon,
123
+ MicOnIcon,
124
+ PersonRectangleIcon,
125
+ RemoveUserIcon,
126
+ VerticalMenuIcon,
127
+ VideoOffIcon,
128
+ VideoOnIcon
129
+ } from "@100mslive/react-icons";
130
+ var dropdownItemCSS = { backgroundColor: "$surface_default", gap: "$4", p: "$8" };
131
+ var optionTextCSS = {
132
+ fontWeight: "$semiBold",
133
+ color: "$on_surface_high",
134
+ textTransform: "none",
135
+ whiteSpace: "nowrap"
136
+ };
137
+ var DropdownWrapper = ({ children }) => {
138
+ const [openOptions, setOpenOptions] = useState(false);
139
+ if (React2.Children.toArray(children).length === 0) {
140
+ return null;
141
+ }
142
+ return /* @__PURE__ */ React2.createElement(Dropdown.Root, { open: openOptions, onOpenChange: setOpenOptions }, /* @__PURE__ */ React2.createElement(
143
+ Dropdown.Trigger,
144
+ {
145
+ "data-testid": "role_group_options",
146
+ onClick: (e) => e.stopPropagation(),
147
+ className: "role_actions",
148
+ asChild: true,
149
+ css: {
150
+ p: "$1",
151
+ r: "$0",
152
+ c: "$on_surface_high",
153
+ visibility: openOptions ? "visible" : "hidden",
154
+ "&:hover": {
155
+ c: "$on_surface_medium"
156
+ },
157
+ "@md": {
158
+ visibility: "visible"
159
+ }
160
+ }
161
+ },
162
+ /* @__PURE__ */ React2.createElement(Flex, null, /* @__PURE__ */ React2.createElement(VerticalMenuIcon, null))
163
+ ), /* @__PURE__ */ React2.createElement(
164
+ Dropdown.Content,
165
+ {
166
+ onClick: (e) => e.stopPropagation(),
167
+ css: { w: "max-content", bg: "$surface_default", py: 0 },
168
+ align: "end"
169
+ },
170
+ children
171
+ ));
172
+ };
173
+ var RoleOptions = ({ roleName, peerList }) => {
174
+ const permissions = useHMSStore2(selectPermissions2);
175
+ const hmsActions = useHMSActions2();
176
+ const { elements } = useRoomLayoutConferencingScreen();
177
+ const { on_stage_role, off_stage_roles = [] } = (elements == null ? void 0 : elements.on_stage_exp) || {};
178
+ const canRemoveRoleFromStage = (permissions == null ? void 0 : permissions.changeRole) && roleName === on_stage_role;
179
+ const role = useHMSStore2(selectRoleByRoleName(roleName));
180
+ const tracks = useHMSStore2(selectTracksMap);
181
+ if (!role) {
182
+ return null;
183
+ }
184
+ const canPublishAudio = role.publishParams.allowed.includes("audio");
185
+ const canPublishVideo = role.publishParams.allowed.includes("video");
186
+ let isVideoOnForSomePeers = false;
187
+ let isAudioOnForSomePeers = false;
188
+ peerList.forEach((peer) => {
189
+ var _a, _b;
190
+ if (peer.isLocal) {
191
+ return;
192
+ }
193
+ const isAudioOn = !!peer.audioTrack && ((_a = tracks[peer.audioTrack]) == null ? void 0 : _a.enabled);
194
+ const isVideoOn = !!peer.videoTrack && ((_b = tracks[peer.videoTrack]) == null ? void 0 : _b.enabled);
195
+ isAudioOnForSomePeers = isAudioOnForSomePeers || isAudioOn;
196
+ isVideoOnForSomePeers = isVideoOnForSomePeers || isVideoOn;
197
+ });
198
+ const setTrackEnabled = (type, enabled = false) => __async(void 0, null, function* () {
199
+ try {
200
+ yield hmsActions.setRemoteTracksEnabled({ roles: [roleName], source: "regular", type, enabled });
201
+ } catch (e) {
202
+ console.error(e);
203
+ }
204
+ });
205
+ const canRemoveRoleFromRoom = (permissions == null ? void 0 : permissions.removeOthers) && (on_stage_role === roleName || (off_stage_roles == null ? void 0 : off_stage_roles.includes(roleName)));
206
+ if (peerList.length === 0 || // if only local peer is present no need to show any options
207
+ peerList.length === 1 && peerList[0].isLocal || !role) {
208
+ return null;
209
+ }
210
+ const removeAllFromStage = () => {
211
+ peerList.forEach((peer) => {
212
+ const prevRole = getMetadata(peer.metadata).prevRole;
213
+ if (prevRole) {
214
+ hmsActions.changeRoleOfPeer(peer.id, prevRole, true);
215
+ }
216
+ });
217
+ };
218
+ const removePeersFromRoom = () => __async(void 0, null, function* () {
219
+ try {
220
+ peerList.forEach((peer) => __async(void 0, null, function* () {
221
+ yield hmsActions.removePeer(peer.id, "");
222
+ }));
223
+ } catch (e) {
224
+ console.error(e);
225
+ }
226
+ });
227
+ return /* @__PURE__ */ React2.createElement(DropdownWrapper, null, canRemoveRoleFromStage ? /* @__PURE__ */ React2.createElement(
228
+ Dropdown.Item,
229
+ {
230
+ css: __spreadProps(__spreadValues({}, dropdownItemCSS), { borderBottom: "1px solid $border_bright" }),
231
+ onClick: removeAllFromStage
232
+ },
233
+ /* @__PURE__ */ React2.createElement(PersonRectangleIcon, null),
234
+ /* @__PURE__ */ React2.createElement(Text, { variant: "sm", css: optionTextCSS }, "Remove all from Stage")
235
+ ) : null, match({ canPublishAudio, isAudioOnForSomePeers, canMute: permissions == null ? void 0 : permissions.mute, canUnmute: permissions == null ? void 0 : permissions.unmute }).with({ canPublishAudio: true, isAudioOnForSomePeers: true, canMute: true }, () => {
236
+ return /* @__PURE__ */ React2.createElement(Dropdown.Item, { css: dropdownItemCSS, onClick: () => setTrackEnabled("audio", false) }, /* @__PURE__ */ React2.createElement(MicOffIcon, null), /* @__PURE__ */ React2.createElement(Text, { variant: "sm", css: optionTextCSS }, "Mute Audio for All"));
237
+ }).with({ canPublishAudio: true, isAudioOnForSomePeers: false, canUnmute: true }, () => {
238
+ return /* @__PURE__ */ React2.createElement(Dropdown.Item, { css: dropdownItemCSS, onClick: () => setTrackEnabled("audio", true) }, /* @__PURE__ */ React2.createElement(MicOnIcon, null), /* @__PURE__ */ React2.createElement(Text, { variant: "sm", css: optionTextCSS }, "Request to Unmute Audio for All"));
239
+ }).otherwise(() => null), match({ canPublishVideo, isVideoOnForSomePeers, canMute: permissions == null ? void 0 : permissions.mute, canUnmute: permissions == null ? void 0 : permissions.unmute }).with({ canPublishVideo: true, isVideoOnForSomePeers: true, canMute: true }, () => {
240
+ return /* @__PURE__ */ React2.createElement(Dropdown.Item, { css: dropdownItemCSS, onClick: () => setTrackEnabled("video", false) }, /* @__PURE__ */ React2.createElement(VideoOffIcon, null), /* @__PURE__ */ React2.createElement(Text, { variant: "sm", css: optionTextCSS }, "Mute Video for All"));
241
+ }).with({ canPublishVideo: true, isVideoOnForSomePeers: false, canUnmute: true }, () => {
242
+ return /* @__PURE__ */ React2.createElement(Dropdown.Item, { css: dropdownItemCSS, onClick: () => setTrackEnabled("video", true) }, /* @__PURE__ */ React2.createElement(VideoOnIcon, null), /* @__PURE__ */ React2.createElement(Text, { variant: "sm", css: optionTextCSS }, "Request to Unmute Video for All"));
243
+ }).otherwise(() => null), canRemoveRoleFromRoom ? /* @__PURE__ */ React2.createElement(
244
+ Dropdown.Item,
245
+ {
246
+ css: __spreadProps(__spreadValues({}, dropdownItemCSS), { borderTop: "1px solid $border_bright", color: "$alert_error_default" }),
247
+ onClick: removePeersFromRoom
248
+ },
249
+ /* @__PURE__ */ React2.createElement(RemoveUserIcon, null),
250
+ /* @__PURE__ */ React2.createElement(Text, { variant: "sm", css: __spreadProps(__spreadValues({}, optionTextCSS), { color: "inherit" }) }, "Remove all from Room")
251
+ ) : null);
252
+ };
253
+
254
+ // src/Prebuilt/components/hooks/useGroupOnStageActions.tsx
255
+ init_define_process_env();
256
+ import { match as match2, P } from "ts-pattern";
257
+ import { selectPermissions as selectPermissions3, useHMSActions as useHMSActions3, useHMSStore as useHMSStore3 } from "@100mslive/react-sdk";
258
+ var useGroupOnStageActions = ({ peers }) => {
259
+ var _a;
260
+ const hmsActions = useHMSActions3();
261
+ const { elements } = useRoomLayoutConferencingScreen();
262
+ const {
263
+ bring_to_stage_label,
264
+ remove_from_stage_label,
265
+ on_stage_role,
266
+ off_stage_roles = [],
267
+ skip_preview_for_role_change = false
268
+ } = elements.on_stage_exp || {};
269
+ const canChangeRole = (_a = useHMSStore3(selectPermissions3)) == null ? void 0 : _a.changeRole;
270
+ const offStageRolePeers = peers.filter(
271
+ (peer) => match2({ on_stage_role, bring_to_stage_label, roleName: peer.roleName }).with(
272
+ {
273
+ on_stage_role: P.when((role) => !!role),
274
+ bring_to_stage_label: P.when((label) => !!label),
275
+ roleName: P.when((role) => !!role && off_stage_roles.includes(role))
276
+ },
277
+ () => true
278
+ ).otherwise(() => false)
279
+ );
280
+ const lowerAllHands = () => __async(void 0, null, function* () {
281
+ return Promise.all(peers.map((peer) => hmsActions.lowerRemotePeerHand(peer.id)));
282
+ });
283
+ const bringAllToStage = () => {
284
+ if (!canChangeRole || !on_stage_role) {
285
+ return;
286
+ }
287
+ return Promise.all(
288
+ offStageRolePeers.map((peer) => {
289
+ return hmsActions.changeRoleOfPeer(peer.id, on_stage_role, skip_preview_for_role_change).then(() => {
290
+ return skip_preview_for_role_change ? hmsActions.lowerRemotePeerHand(peer.id) : null;
291
+ });
292
+ })
293
+ );
294
+ };
295
+ return {
296
+ lowerAllHands,
297
+ bringAllToStage,
298
+ canBringToStage: canChangeRole && offStageRolePeers.length > 0,
299
+ bring_to_stage_label,
300
+ remove_from_stage_label
301
+ };
302
+ };
303
+
304
+ // src/Prebuilt/components/Footer/RoleAccordion.tsx
305
+ var ROW_HEIGHT = 50;
306
+ var ITER_TIMER = 5e3;
307
+ function itemKey(index, data) {
308
+ var _a;
309
+ return (_a = data.peerList[index]) == null ? void 0 : _a.id;
310
+ }
311
+ var VirtualizedParticipantItem = React3.memo(
312
+ ({ index, data, style }) => {
313
+ return /* @__PURE__ */ React3.createElement(
314
+ Participant,
315
+ {
316
+ key: data.peerList[index].id,
317
+ peer: data.peerList[index],
318
+ isHandRaisedAccordion: data.isHandRaisedAccordion,
319
+ isConnected: data.isConnected,
320
+ style
321
+ }
322
+ );
323
+ }
324
+ );
325
+ var RoleAccordion = ({
326
+ peerList = [],
327
+ roleName,
328
+ isConnected,
329
+ filter,
330
+ isHandRaisedAccordion = false,
331
+ offStageRoles,
332
+ onActive
333
+ }) => {
334
+ const [ref, { width }] = useMeasure();
335
+ const isLargeRoom = useHMSStore4(selectIsLargeRoom);
336
+ const { peers, total, loadPeers } = usePaginatedParticipants({ role: roleName, limit: 10 });
337
+ const isOffStageRole = roleName && offStageRoles.includes(roleName);
338
+ let peersInAccordion = peerList;
339
+ if (isOffStageRole && isLargeRoom) {
340
+ peersInAccordion = peers;
341
+ if (filter == null ? void 0 : filter.search) {
342
+ peersInAccordion = peersInAccordion.filter((peer) => peer.name.toLowerCase().includes(filter.search || ""));
343
+ }
344
+ }
345
+ const { bringAllToStage, bring_to_stage_label, canBringToStage, lowerAllHands } = useGroupOnStageActions({
346
+ peers: peersInAccordion
347
+ });
348
+ useEffect(() => {
349
+ if (!isOffStageRole || !isLargeRoom) {
350
+ return;
351
+ }
352
+ loadPeers();
353
+ const interval = setInterval(() => {
354
+ loadPeers();
355
+ }, ITER_TIMER);
356
+ return () => clearInterval(interval);
357
+ }, [isOffStageRole, isLargeRoom]);
358
+ if (peersInAccordion.length === 0 || isHandRaisedAccordion && (filter == null ? void 0 : filter.search)) {
359
+ return null;
360
+ }
361
+ const height = ROW_HEIGHT * peersInAccordion.length;
362
+ const hasNext = total > peersInAccordion.length && !(filter == null ? void 0 : filter.search);
363
+ return /* @__PURE__ */ React3.createElement(Accordion.Item, { value: roleName, css: { "&:hover .role_actions": { visibility: "visible" }, mb: "$8" }, ref }, /* @__PURE__ */ React3.createElement(
364
+ Accordion.Header,
365
+ {
366
+ chevronID: `role_accordion_btn_${roleName}`,
367
+ iconStyles: { c: "$on_surface_high" },
368
+ css: {
369
+ textTransform: "capitalize",
370
+ p: "$6 $8",
371
+ fontSize: "$sm",
372
+ fontWeight: "$semiBold",
373
+ c: "$on_surface_medium",
374
+ borderRadius: "$1",
375
+ border: "1px solid $border_default",
376
+ '&[data-state="open"]': {
377
+ borderBottomLeftRadius: 0,
378
+ borderBottomRightRadius: 0
379
+ }
380
+ }
381
+ },
382
+ /* @__PURE__ */ React3.createElement(Flex, { justify: "between", align: "center", css: { flexGrow: 1, pr: "$6" } }, /* @__PURE__ */ React3.createElement(
383
+ Text,
384
+ {
385
+ variant: "sm",
386
+ css: { fontWeight: "$semiBold", textTransform: "capitalize", color: "$on_surface_medium" }
387
+ },
388
+ roleName,
389
+ " ",
390
+ `(${getFormattedCount(isLargeRoom && isOffStageRole ? total : peerList.length)})`
391
+ ), /* @__PURE__ */ React3.createElement(RoleOptions, { roleName, peerList: peersInAccordion }))
392
+ ), /* @__PURE__ */ React3.createElement(Accordion.Content, { contentStyles: { border: "1px solid $border_default", borderTop: "none" } }, /* @__PURE__ */ React3.createElement(
393
+ FixedSizeList,
394
+ {
395
+ itemSize: ROW_HEIGHT,
396
+ itemData: {
397
+ peerList: isHandRaisedAccordion ? peersInAccordion.sort((a, b) => {
398
+ try {
399
+ const aHandRaisedAt = JSON.parse(a.metadata || "{}").handRaisedAt;
400
+ const bHandRaisedAt = JSON.parse(b.metadata || "{}").handRaisedAt;
401
+ return aHandRaisedAt - bHandRaisedAt;
402
+ } catch (err) {
403
+ return 0;
404
+ }
405
+ }) : peersInAccordion,
406
+ isConnected,
407
+ isHandRaisedAccordion
408
+ },
409
+ itemKey,
410
+ itemCount: peersInAccordion.length,
411
+ width,
412
+ height
413
+ },
414
+ VirtualizedParticipantItem
415
+ ), (offStageRoles == null ? void 0 : offStageRoles.includes(roleName)) && hasNext ? /* @__PURE__ */ React3.createElement(
416
+ Flex,
417
+ {
418
+ align: "center",
419
+ justify: "end",
420
+ css: {
421
+ gap: "$1",
422
+ cursor: "pointer",
423
+ color: "$on_surface_high",
424
+ p: "$6",
425
+ borderTop: "1px solid $border_default"
426
+ },
427
+ onClick: () => onActive == null ? void 0 : onActive(roleName)
428
+ },
429
+ /* @__PURE__ */ React3.createElement(Text, { variant: "sm", css: { color: "inherit" } }, "View All"),
430
+ /* @__PURE__ */ React3.createElement(ChevronRightIcon, null)
431
+ ) : null, isHandRaisedAccordion && canBringToStage && /* @__PURE__ */ React3.createElement(React3.Fragment, null, /* @__PURE__ */ React3.createElement(HorizontalDivider, null), /* @__PURE__ */ React3.createElement(Flex, { css: { w: "100%", p: "$6", gap: "$4" }, justify: "center" }, /* @__PURE__ */ React3.createElement(Button, { variant: "standard", onClick: lowerAllHands, icon: true, css: { pl: "$2" } }, /* @__PURE__ */ React3.createElement(CrossIcon, null), " Lower all hands"), /* @__PURE__ */ React3.createElement(Button, { onClick: bringAllToStage, icon: true, css: { pl: "$2" } }, /* @__PURE__ */ React3.createElement(AddIcon, null), " ", bring_to_stage_label)))));
432
+ };
433
+
434
+ // src/Prebuilt/components/hooks/usePeerOnStageActions.tsx
435
+ init_define_process_env();
436
+ import { useState as useState2 } from "react";
437
+ import { selectPeerMetadata, selectPermissions as selectPermissions4, useHMSActions as useHMSActions4, useHMSStore as useHMSStore5 } from "@100mslive/react-sdk";
438
+ var usePeerOnStageActions = ({ peerId, role }) => {
439
+ var _a, _b;
440
+ const hmsActions = useHMSActions4();
441
+ const { elements } = useRoomLayoutConferencingScreen();
442
+ const {
443
+ bring_to_stage_label,
444
+ remove_from_stage_label,
445
+ on_stage_role,
446
+ off_stage_roles = [],
447
+ skip_preview_for_role_change = false
448
+ } = elements.on_stage_exp || {};
449
+ const isInStage = role === on_stage_role;
450
+ const canChangeRole = (_a = useHMSStore5(selectPermissions4)) == null ? void 0 : _a.changeRole;
451
+ const shouldShowStageRoleChange = canChangeRole && (isInStage && remove_from_stage_label || (off_stage_roles == null ? void 0 : off_stage_roles.includes(role)) && bring_to_stage_label);
452
+ const prevRole = (_b = useHMSStore5(selectPeerMetadata(peerId))) == null ? void 0 : _b.prevRole;
453
+ const [open, setOpen] = useState2(false);
454
+ const lowerPeerHand = () => __async(void 0, null, function* () {
455
+ yield hmsActions.lowerRemotePeerHand(peerId);
456
+ });
457
+ const handleStageAction = () => __async(void 0, null, function* () {
458
+ if (isInStage) {
459
+ prevRole && hmsActions.changeRoleOfPeer(peerId, prevRole, true);
460
+ } else if (on_stage_role) {
461
+ yield hmsActions.changeRoleOfPeer(peerId, on_stage_role, skip_preview_for_role_change);
462
+ if (skip_preview_for_role_change) {
463
+ yield lowerPeerHand();
464
+ }
465
+ }
466
+ setOpen(false);
467
+ });
468
+ return {
469
+ open,
470
+ setOpen,
471
+ lowerPeerHand,
472
+ handleStageAction,
473
+ shouldShowStageRoleChange,
474
+ isInStage,
475
+ bring_to_stage_label,
476
+ remove_from_stage_label
477
+ };
478
+ };
479
+
480
+ // src/Prebuilt/components/Footer/ParticipantList.tsx
481
+ var ParticipantList = ({
482
+ offStageRoles = [],
483
+ onActive
484
+ }) => {
485
+ const [filter, setFilter] = useState3();
486
+ const { participants, isConnected, peerCount } = useParticipants(filter);
487
+ const isLargeRoom = useHMSStore6(selectIsLargeRoom2);
488
+ const peersOrderedByRoles = {};
489
+ const handRaisedPeers = useHMSStore6(selectHandRaisedPeers);
490
+ participants.forEach((participant) => {
491
+ if (participant.roleName) {
492
+ if (peersOrderedByRoles[participant.roleName] === void 0) {
493
+ peersOrderedByRoles[participant.roleName] = [];
494
+ }
495
+ peersOrderedByRoles[participant.roleName].push(participant);
496
+ }
497
+ });
498
+ if (isLargeRoom) {
499
+ offStageRoles.forEach((role) => {
500
+ if (!peersOrderedByRoles[role]) {
501
+ peersOrderedByRoles[role] = [];
502
+ }
503
+ });
504
+ }
505
+ useSidepaneResetOnLayoutUpdate("participant_list", SIDE_PANE_OPTIONS.PARTICIPANTS);
506
+ const onSearch = useCallback((value) => {
507
+ setFilter((filterValue) => {
508
+ if (!filterValue) {
509
+ filterValue = {};
510
+ }
511
+ filterValue.search = value.toLowerCase();
512
+ return __spreadValues({}, filterValue);
513
+ });
514
+ }, []);
515
+ if (peerCount === 0) {
516
+ return null;
517
+ }
518
+ return /* @__PURE__ */ React4.createElement(Fragment, null, /* @__PURE__ */ React4.createElement(
519
+ Flex,
520
+ {
521
+ direction: "column",
522
+ css: {
523
+ size: "100%",
524
+ gap: "$4"
525
+ }
526
+ },
527
+ !(filter == null ? void 0 : filter.search) && participants.length === 0 ? null : /* @__PURE__ */ React4.createElement(ParticipantSearch, { onSearch, inSidePane: true }),
528
+ /* @__PURE__ */ React4.createElement(
529
+ VirtualizedParticipants,
530
+ {
531
+ peersOrderedByRoles,
532
+ handRaisedList: handRaisedPeers,
533
+ isConnected: !!isConnected,
534
+ filter,
535
+ offStageRoles,
536
+ isLargeRoom,
537
+ onActive
538
+ },
539
+ participants.length === 0 ? /* @__PURE__ */ React4.createElement(
540
+ Flex,
541
+ {
542
+ align: "center",
543
+ justify: "center",
544
+ className: "emptyParticipants",
545
+ css: { w: "100%", p: "$8 0", display: "none" }
546
+ },
547
+ /* @__PURE__ */ React4.createElement(Text, { variant: "sm" }, !filter ? "No participants" : "No matching participants")
548
+ ) : null
549
+ )
550
+ ));
551
+ };
552
+ var ParticipantCount = () => {
553
+ const peerCount = useHMSStore6(selectPeerCount);
554
+ const toggleSidepane = useSidepaneToggle(SIDE_PANE_OPTIONS.PARTICIPANTS);
555
+ const isPeerListOpen = useIsSidepaneTypeOpen(SIDE_PANE_OPTIONS.PARTICIPANTS);
556
+ if (peerCount === 0) {
557
+ return null;
558
+ }
559
+ return /* @__PURE__ */ React4.createElement(
560
+ IconButton_default,
561
+ {
562
+ css: {
563
+ w: "auto",
564
+ p: "$4",
565
+ h: "auto",
566
+ bg: isPeerListOpen ? "$surface_brighter" : ""
567
+ },
568
+ onClick: () => {
569
+ if (peerCount > 0) {
570
+ toggleSidepane();
571
+ }
572
+ },
573
+ "data-testid": "participant_list"
574
+ },
575
+ /* @__PURE__ */ React4.createElement(PeopleIcon, null),
576
+ /* @__PURE__ */ React4.createElement(Text, { variant: "sm", css: { mx: "$4", c: "inherit" } }, getFormattedCount(peerCount))
577
+ );
578
+ };
579
+ var Participant = ({
580
+ peer,
581
+ isConnected,
582
+ isHandRaisedAccordion,
583
+ style
584
+ }) => {
585
+ const localPeerId = useHMSStore6(selectLocalPeerID2);
586
+ return /* @__PURE__ */ React4.createElement(
587
+ Flex,
588
+ {
589
+ key: peer.id,
590
+ css: {
591
+ w: "100%",
592
+ p: "$4 $8",
593
+ pr: "$6",
594
+ h: "$16",
595
+ "&:hover .participant_item": { display: "flex" }
596
+ },
597
+ align: "center",
598
+ justify: "between",
599
+ "data-testid": "participant_" + peer.name,
600
+ style
601
+ },
602
+ /* @__PURE__ */ React4.createElement(
603
+ Text,
604
+ {
605
+ variant: "sm",
606
+ css: __spreadProps(__spreadValues({}, textEllipsis("100%")), { flex: "1 1 0", mr: "$8", fontWeight: "$semiBold", color: "$on_surface_high" })
607
+ },
608
+ peer.name,
609
+ " ",
610
+ localPeerId === peer.id ? "(You)" : ""
611
+ ),
612
+ isConnected && peer.roleName ? /* @__PURE__ */ React4.createElement(
613
+ ParticipantActions,
614
+ {
615
+ peerId: peer.id,
616
+ peerType: peer.type,
617
+ role: peer.roleName,
618
+ isHandRaisedAccordion
619
+ }
620
+ ) : null
621
+ );
622
+ };
623
+ var VirtualizedParticipants = ({
624
+ peersOrderedByRoles = {},
625
+ isConnected,
626
+ filter,
627
+ handRaisedList = [],
628
+ offStageRoles,
629
+ isLargeRoom,
630
+ onActive,
631
+ children
632
+ }) => {
633
+ return /* @__PURE__ */ React4.createElement(
634
+ Flex,
635
+ {
636
+ direction: "column",
637
+ css: {
638
+ gap: "$8",
639
+ overflowY: "auto",
640
+ overflowX: "hidden",
641
+ pr: "$10",
642
+ mr: "-$10",
643
+ flex: "1 1 0",
644
+ "& > div:empty ~ .emptyParticipants": {
645
+ display: "flex"
646
+ }
647
+ }
648
+ },
649
+ /* @__PURE__ */ React4.createElement(Accordion.Root, { type: isLargeRoom ? "single" : "multiple", collapsible: true }, handRaisedList.length > 0 ? /* @__PURE__ */ React4.createElement(
650
+ RoleAccordion,
651
+ {
652
+ peerList: handRaisedList,
653
+ roleName: "Hand Raised",
654
+ filter,
655
+ isConnected,
656
+ isHandRaisedAccordion: true,
657
+ offStageRoles
658
+ }
659
+ ) : null, Object.keys(peersOrderedByRoles).map((role) => /* @__PURE__ */ React4.createElement(
660
+ RoleAccordion,
661
+ {
662
+ key: role,
663
+ peerList: peersOrderedByRoles[role],
664
+ roleName: role,
665
+ isConnected,
666
+ filter,
667
+ offStageRoles,
668
+ onActive
669
+ }
670
+ ))),
671
+ children
672
+ );
673
+ };
674
+ var ParticipantActions = React4.memo(
675
+ ({
676
+ peerId,
677
+ peerType,
678
+ role,
679
+ isHandRaisedAccordion
680
+ }) => {
681
+ var _a, _b;
682
+ const isHandRaised = useHMSStore6(selectHasPeerHandRaised(peerId));
683
+ const canChangeRole = (_a = useHMSStore6(selectPermissions5)) == null ? void 0 : _a.changeRole;
684
+ const canRemoveOthers = (_b = useHMSStore6(selectPermissions5)) == null ? void 0 : _b.removeOthers;
685
+ const { elements } = useRoomLayoutConferencingScreen();
686
+ const { on_stage_exp } = elements || {};
687
+ const shouldShowMoreActions = on_stage_exp && canChangeRole || canRemoveOthers;
688
+ const isAudioMuted = !useHMSStore6(selectIsPeerAudioEnabled(peerId));
689
+ return /* @__PURE__ */ React4.createElement(
690
+ Flex,
691
+ {
692
+ align: "center",
693
+ css: {
694
+ flexShrink: 0,
695
+ gap: "$8"
696
+ }
697
+ },
698
+ isHandRaisedAccordion ? /* @__PURE__ */ React4.createElement(HandRaisedAccordionParticipantActions, { peerId, role }) : /* @__PURE__ */ React4.createElement(React4.Fragment, null, /* @__PURE__ */ React4.createElement(ConnectionIndicator, { peerId }), peerType === HMSPeerType.SIP && /* @__PURE__ */ React4.createElement(
699
+ Flex,
700
+ {
701
+ align: "center",
702
+ justify: "center",
703
+ css: { p: "$1", c: "$on_surface_high", bg: "$surface_bright", borderRadius: "$round" }
704
+ },
705
+ /* @__PURE__ */ React4.createElement(CallIcon, { width: 19, height: 19 })
706
+ ), isHandRaised && /* @__PURE__ */ React4.createElement(
707
+ Flex,
708
+ {
709
+ align: "center",
710
+ justify: "center",
711
+ css: { p: "$1", c: "$on_surface_high", bg: "$surface_bright", borderRadius: "$round" }
712
+ },
713
+ /* @__PURE__ */ React4.createElement(HandIcon, { height: 19, width: 19 })
714
+ ), isAudioMuted ? /* @__PURE__ */ React4.createElement(
715
+ Flex,
716
+ {
717
+ align: "center",
718
+ justify: "center",
719
+ css: { p: "$2", c: "$on_surface_high", bg: "$surface_bright", borderRadius: "$round" }
720
+ },
721
+ /* @__PURE__ */ React4.createElement(MicOffIcon2, { height: 19, width: 19 })
722
+ ) : null, shouldShowMoreActions ? /* @__PURE__ */ React4.createElement(ParticipantMoreActions, { peerId, role }) : null)
723
+ );
724
+ }
725
+ );
726
+ var quickActionStyle = { p: "$1", borderRadius: "$round" };
727
+ var HandRaisedAccordionParticipantActions = ({ peerId, role }) => {
728
+ const { handleStageAction, lowerPeerHand, shouldShowStageRoleChange, isInStage } = usePeerOnStageActions({
729
+ peerId,
730
+ role
731
+ });
732
+ if (!shouldShowStageRoleChange) {
733
+ return null;
734
+ }
735
+ return /* @__PURE__ */ React4.createElement(React4.Fragment, null, /* @__PURE__ */ React4.createElement(Button, { variant: "standard", css: quickActionStyle, onClick: lowerPeerHand }, /* @__PURE__ */ React4.createElement(CrossIcon2, { height: 18, width: 18 })), !isInStage && /* @__PURE__ */ React4.createElement(Button, { variant: "primary", onClick: handleStageAction, css: quickActionStyle }, /* @__PURE__ */ React4.createElement(AddIcon2, { height: 18, width: 18 })));
736
+ };
737
+ var ParticipantMoreActions = ({ peerId, role }) => {
738
+ var _a;
739
+ const {
740
+ open,
741
+ setOpen,
742
+ bring_to_stage_label,
743
+ remove_from_stage_label,
744
+ handleStageAction,
745
+ isInStage,
746
+ shouldShowStageRoleChange
747
+ } = usePeerOnStageActions({ peerId, role });
748
+ const canChangeRole = !!((_a = useHMSStore6(selectPermissions5)) == null ? void 0 : _a.changeRole);
749
+ const [openRoleChangeModal, setOpenRoleChangeModal] = useState3(false);
750
+ const roles = useHMSStore6(selectAvailableRoleNames);
751
+ return /* @__PURE__ */ React4.createElement(React4.Fragment, null, /* @__PURE__ */ React4.createElement(Dropdown.Root, { open, onOpenChange: (value) => setOpen(value), modal: false }, /* @__PURE__ */ React4.createElement(
752
+ Dropdown.Trigger,
753
+ {
754
+ asChild: true,
755
+ "data-testid": "participant_more_actions",
756
+ className: "participant_item",
757
+ css: {
758
+ p: "$1",
759
+ r: "$0",
760
+ c: "$on_surface_high",
761
+ display: open ? "flex" : "none",
762
+ "&:hover": {
763
+ bg: "$surface_bright"
764
+ },
765
+ "@md": {
766
+ display: "flex"
767
+ }
768
+ },
769
+ tabIndex: 0
770
+ },
771
+ /* @__PURE__ */ React4.createElement(Box, { css: { my: "auto" } }, /* @__PURE__ */ React4.createElement(VerticalMenuIcon2, null))
772
+ ), /* @__PURE__ */ React4.createElement(Dropdown.Portal, null, /* @__PURE__ */ React4.createElement(Dropdown.Content, { align: "end", sideOffset: 8, css: { w: "$64", bg: "$surface_default" } }, shouldShowStageRoleChange ? /* @__PURE__ */ React4.createElement(Dropdown.Item, { css: { bg: "$surface_default" }, onClick: () => handleStageAction() }, /* @__PURE__ */ React4.createElement(ChangeRoleIcon, null), /* @__PURE__ */ React4.createElement(Text, { variant: "sm", css: { ml: "$4", fontWeight: "$semiBold", c: "$on_surface_high" } }, isInStage ? remove_from_stage_label : bring_to_stage_label)) : null, canChangeRole && roles.length > 1 ? /* @__PURE__ */ React4.createElement(Dropdown.Item, { css: { bg: "$surface_default" }, onClick: () => setOpenRoleChangeModal(true) }, /* @__PURE__ */ React4.createElement(PersonSettingsIcon, null), /* @__PURE__ */ React4.createElement(Text, { variant: "sm", css: { ml: "$4", fontWeight: "$semiBold", c: "$on_surface_high" } }, "Switch Role")) : null, /* @__PURE__ */ React4.createElement(RemoveParticipant, { peerId })))), openRoleChangeModal && /* @__PURE__ */ React4.createElement(RoleChangeModal, { peerId, onOpenChange: setOpenRoleChangeModal }));
773
+ };
774
+ var ParticipantSearch = ({
775
+ onSearch,
776
+ placeholder = "Search for participants",
777
+ inSidePane = false
778
+ }) => {
779
+ const [value, setValue] = React4.useState("");
780
+ const isMobile = useMedia(config.media.md);
781
+ useDebounce(
782
+ () => {
783
+ onSearch(value);
784
+ },
785
+ 300,
786
+ [value, onSearch]
787
+ );
788
+ return /* @__PURE__ */ React4.createElement(
789
+ Flex,
790
+ {
791
+ align: "center",
792
+ css: {
793
+ p: isMobile ? "0" : "$2 0",
794
+ mb: "$2",
795
+ position: "relative",
796
+ color: "$on_surface_medium",
797
+ mt: inSidePane ? "$4" : ""
798
+ },
799
+ onClick: (e) => e.stopPropagation()
800
+ },
801
+ /* @__PURE__ */ React4.createElement(SearchIcon, { style: { position: "absolute", left: "0.5rem" } }),
802
+ /* @__PURE__ */ React4.createElement(
803
+ Input,
804
+ {
805
+ type: "text",
806
+ placeholder,
807
+ css: { w: "100%", p: "$6", pl: "$14", bg: inSidePane ? "$surface_default" : "$surface_dim" },
808
+ value,
809
+ onKeyDown: (event) => {
810
+ event.stopPropagation();
811
+ },
812
+ onChange: (event) => {
813
+ setValue(event.currentTarget.value);
814
+ },
815
+ autoComplete: "off",
816
+ "aria-autocomplete": "none"
817
+ }
818
+ )
819
+ );
820
+ };
821
+
822
+ export {
823
+ ROW_HEIGHT,
824
+ itemKey,
825
+ ParticipantList,
826
+ ParticipantCount,
827
+ Participant,
828
+ ParticipantSearch
829
+ };
830
+ //# sourceMappingURL=chunk-QHQKY35W.js.map