@100mslive/roomkit-react 0.1.5 → 0.1.6-alpha.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (197) hide show
  1. package/dist/{HLSView-P57IRMAR.js → HLSView-PY2FKWX3.js} +191 -123
  2. package/dist/HLSView-PY2FKWX3.js.map +7 -0
  3. package/dist/Prebuilt/App.d.ts +3 -0
  4. package/dist/Prebuilt/AppContext.d.ts +13 -0
  5. package/dist/Prebuilt/common/PeersSorter.d.ts +21 -0
  6. package/dist/Prebuilt/components/Footer/Footer.d.ts +6 -0
  7. package/dist/Prebuilt/components/Header/Header.d.ts +2 -0
  8. package/dist/Prebuilt/components/InsetTile.d.ts +2 -0
  9. package/dist/Prebuilt/components/Leave/DesktopLeaveRoom.d.ts +7 -0
  10. package/dist/Prebuilt/components/Leave/EndSessionContent.d.ts +8 -0
  11. package/dist/Prebuilt/components/Leave/LeaveAtoms.d.ts +2196 -0
  12. package/dist/Prebuilt/components/Leave/LeaveCard.d.ts +12 -0
  13. package/dist/Prebuilt/components/Leave/LeaveRoom.d.ts +5 -0
  14. package/dist/Prebuilt/components/Leave/LeaveSessionContent.d.ts +6 -0
  15. package/dist/Prebuilt/components/Leave/MwebLeaveRoom.d.ts +7 -0
  16. package/dist/Prebuilt/components/MoreSettings/MoreSettings.d.ts +6 -0
  17. package/dist/Prebuilt/components/MoreSettings/SplitComponents/DesktopOptions.d.ts +6 -0
  18. package/dist/Prebuilt/components/Pagination.d.ts +6 -0
  19. package/dist/Prebuilt/components/Preview/PreviewForm.d.ts +10 -0
  20. package/dist/Prebuilt/components/SecondaryTiles.d.ts +3 -0
  21. package/dist/Prebuilt/components/VideoLayouts/EqualProminence.d.ts +3 -0
  22. package/dist/Prebuilt/components/VideoLayouts/Grid.d.ts +5 -0
  23. package/dist/Prebuilt/components/VideoLayouts/GridLayout.d.ts +10 -0
  24. package/dist/Prebuilt/components/VideoLayouts/ProminenceLayout.d.ts +12 -0
  25. package/dist/Prebuilt/components/VideoLayouts/RoleProminence.d.ts +3 -0
  26. package/dist/Prebuilt/components/VideoLayouts/ScreenshareLayout.d.ts +3 -0
  27. package/dist/Prebuilt/components/VideoLayouts/interface.d.ts +8 -0
  28. package/dist/Prebuilt/components/hooks/useRoleProminencePeers.d.ts +5 -0
  29. package/dist/Prebuilt/components/hooks/useTileLayout.d.ts +12 -0
  30. package/dist/Prebuilt/components/hooks/useVideoTileLayout.d.ts +11 -0
  31. package/dist/Prebuilt/layouts/SidePane.d.ts +6 -0
  32. package/dist/Prebuilt/layouts/VideoStreamingSection.d.ts +6 -0
  33. package/dist/Prebuilt/plugins/whiteboard/ToggleWhiteboard.d.ts +5 -0
  34. package/dist/Prebuilt/provider/roomLayoutProvider/hooks/useFetchRoomLayout.d.ts +1 -0
  35. package/dist/Prebuilt/provider/roomLayoutProvider/hooks/useInsetEnabled.d.ts +1 -0
  36. package/dist/Prebuilt/provider/roomLayoutProvider/hooks/useRoomLayoutScreen.d.ts +17 -0
  37. package/dist/Prebuilt/provider/roomLayoutProvider/index.d.ts +6 -1
  38. package/dist/{VirtualBackground-GGCQJ5JM.js → VirtualBackground-AYDHYLIZ.js} +5 -11
  39. package/dist/VirtualBackground-AYDHYLIZ.js.map +7 -0
  40. package/dist/{chunk-P5X32KOD.js → chunk-E2M2ZSOL.js} +8 -5
  41. package/dist/chunk-E2M2ZSOL.js.map +7 -0
  42. package/dist/chunk-GQD2AGWW.js +888 -0
  43. package/dist/chunk-GQD2AGWW.js.map +7 -0
  44. package/dist/{chunk-OSM4QEQG.js → chunk-RXTHJUMZ.js} +2462 -4738
  45. package/dist/chunk-RXTHJUMZ.js.map +7 -0
  46. package/dist/conference-V2XZGTKU.js +5927 -0
  47. package/dist/conference-V2XZGTKU.js.map +7 -0
  48. package/dist/index.cjs.js +9414 -15534
  49. package/dist/index.cjs.js.map +4 -4
  50. package/dist/index.js +2 -2
  51. package/dist/meta.cjs.json +2156 -3347
  52. package/dist/meta.esbuild.json +2601 -3885
  53. package/package.json +7 -7
  54. package/src/Button/Button.tsx +2 -2
  55. package/src/Prebuilt/App.tsx +49 -33
  56. package/src/Prebuilt/{AppContext.jsx → AppContext.tsx} +11 -3
  57. package/src/Prebuilt/IconButton.jsx +1 -0
  58. package/src/Prebuilt/Prebuilt.stories.tsx +1 -0
  59. package/src/Prebuilt/common/{PeersSorter.js → PeersSorter.ts} +15 -10
  60. package/src/Prebuilt/common/constants.js +3 -112
  61. package/src/Prebuilt/common/hooks.js +34 -1
  62. package/src/Prebuilt/common/utils.js +0 -8
  63. package/src/Prebuilt/components/AppData/AppData.jsx +3 -13
  64. package/src/Prebuilt/components/AppData/useUISettings.js +0 -4
  65. package/src/Prebuilt/components/AudioVideoToggle.jsx +6 -0
  66. package/src/Prebuilt/components/AuthToken.jsx +11 -42
  67. package/src/Prebuilt/components/Chat/Chat.jsx +57 -26
  68. package/src/Prebuilt/components/Chat/ChatBody.jsx +92 -32
  69. package/src/Prebuilt/components/Chat/ChatFooter.jsx +72 -48
  70. package/src/Prebuilt/components/Chat/ChatParticipantHeader.jsx +73 -0
  71. package/src/Prebuilt/components/Chat/ChatSelector.jsx +16 -17
  72. package/src/Prebuilt/components/Chat/ChatSelectorContainer.jsx +81 -0
  73. package/src/Prebuilt/components/Connection/TileConnection.jsx +30 -12
  74. package/src/Prebuilt/components/EmojiReaction.jsx +18 -17
  75. package/src/Prebuilt/components/Footer/ChatToggle.jsx +1 -7
  76. package/src/Prebuilt/components/Footer/Footer.tsx +89 -0
  77. package/src/Prebuilt/components/Footer/ParticipantList.jsx +213 -173
  78. package/src/Prebuilt/components/Footer/RoleAccordion.jsx +78 -0
  79. package/src/Prebuilt/components/HMSVideo/Controls.jsx +2 -2
  80. package/src/Prebuilt/components/HMSVideo/HLSQualitySelector.jsx +33 -10
  81. package/src/Prebuilt/components/HMSVideo/PlayButton.jsx +1 -1
  82. package/src/Prebuilt/components/HMSVideo/VideoTime.jsx +3 -3
  83. package/src/Prebuilt/components/HMSVideo/VolumeControl.jsx +38 -9
  84. package/src/Prebuilt/components/Header/{ConferencingHeader.jsx → Header.tsx} +9 -7
  85. package/src/Prebuilt/components/Header/HeaderComponents.jsx +13 -4
  86. package/src/Prebuilt/components/Header/StreamActions.jsx +33 -60
  87. package/src/Prebuilt/components/Header/index.tsx +1 -0
  88. package/src/Prebuilt/components/IconButtonWithOptions/IconButtonWithOptions.jsx +17 -3
  89. package/src/Prebuilt/components/InsetTile.tsx +122 -0
  90. package/src/Prebuilt/components/{MoreSettings/SplitComponents/DesktopLeaveRoom.jsx → Leave/DesktopLeaveRoom.tsx} +50 -18
  91. package/src/Prebuilt/components/{EndSessionContent.jsx → Leave/EndSessionContent.tsx} +19 -9
  92. package/src/Prebuilt/components/Leave/LeaveAtoms.tsx +26 -0
  93. package/src/Prebuilt/components/{LeaveCard.jsx → Leave/LeaveCard.tsx} +22 -3
  94. package/src/Prebuilt/components/Leave/LeaveRoom.tsx +63 -0
  95. package/src/Prebuilt/components/{LeaveSessionContent.jsx → Leave/LeaveSessionContent.tsx} +13 -5
  96. package/src/Prebuilt/components/{MoreSettings/SplitComponents/MwebLeaveRoom.jsx → Leave/MwebLeaveRoom.tsx} +38 -13
  97. package/src/Prebuilt/components/MetaActions.jsx +15 -23
  98. package/src/Prebuilt/components/MoreSettings/ActionTile.jsx +5 -0
  99. package/src/Prebuilt/components/MoreSettings/ChangeNameContent.jsx +12 -7
  100. package/src/Prebuilt/components/MoreSettings/ChangeNameModal.jsx +1 -1
  101. package/src/Prebuilt/components/MoreSettings/FullScreenItem.jsx +1 -4
  102. package/src/Prebuilt/components/MoreSettings/MoreSettings.tsx +27 -0
  103. package/src/Prebuilt/components/MoreSettings/SplitComponents/{DesktopOptions.jsx → DesktopOptions.tsx} +86 -75
  104. package/src/Prebuilt/components/MoreSettings/SplitComponents/MwebOptions.jsx +20 -19
  105. package/src/Prebuilt/components/Notifications/HLSFailureModal.jsx +3 -1
  106. package/src/Prebuilt/components/Notifications/Notifications.jsx +18 -11
  107. package/src/Prebuilt/components/Notifications/PeerNotifications.jsx +14 -2
  108. package/src/Prebuilt/components/Notifications/PermissionErrorModal.jsx +10 -4
  109. package/src/Prebuilt/components/PIP/PIPComponent.jsx +7 -16
  110. package/src/Prebuilt/components/PIP/PIPManager.js +1 -0
  111. package/src/Prebuilt/components/{Pagination.jsx → Pagination.tsx} +35 -6
  112. package/src/Prebuilt/components/Playlist/Playlist.jsx +1 -6
  113. package/src/Prebuilt/components/PostLeave.jsx +7 -7
  114. package/src/Prebuilt/components/Preview/PreviewContainer.jsx +5 -13
  115. package/src/Prebuilt/components/Preview/{PreviewForm.jsx → PreviewForm.tsx} +14 -4
  116. package/src/Prebuilt/components/Preview/PreviewJoin.jsx +9 -7
  117. package/src/Prebuilt/components/RaiseHand.jsx +0 -7
  118. package/src/Prebuilt/components/RoleChangeRequestModal.jsx +82 -6
  119. package/src/Prebuilt/components/ScreenshareDisplay.jsx +4 -10
  120. package/src/Prebuilt/components/ScreenshareTile.jsx +41 -33
  121. package/src/Prebuilt/components/SecondaryTiles.tsx +34 -0
  122. package/src/Prebuilt/components/Settings/LayoutSettings.jsx +2 -12
  123. package/src/Prebuilt/components/Settings/NotificationSettings.jsx +3 -9
  124. package/src/Prebuilt/components/Settings/SettingsModal.jsx +3 -9
  125. package/src/Prebuilt/components/StatsForNerds.jsx +3 -1
  126. package/src/Prebuilt/components/TileMenu/TileMenu.jsx +15 -16
  127. package/src/Prebuilt/components/TileMenu/TileMenuContent.jsx +21 -19
  128. package/src/Prebuilt/components/Toast/ToastConfig.jsx +53 -11
  129. package/src/Prebuilt/components/VideoLayouts/EqualProminence.tsx +62 -0
  130. package/src/Prebuilt/components/VideoLayouts/Grid.tsx +41 -0
  131. package/src/Prebuilt/components/VideoLayouts/GridLayout.tsx +92 -0
  132. package/src/Prebuilt/components/VideoLayouts/ProminenceLayout.tsx +60 -0
  133. package/src/Prebuilt/components/VideoLayouts/RoleProminence.tsx +56 -0
  134. package/src/Prebuilt/components/VideoLayouts/ScreenshareLayout.tsx +36 -0
  135. package/src/Prebuilt/components/VideoLayouts/interface.ts +9 -0
  136. package/src/Prebuilt/components/VideoTile.jsx +93 -43
  137. package/src/Prebuilt/components/conference.jsx +24 -20
  138. package/src/Prebuilt/components/hooks/useMetadata.jsx +7 -0
  139. package/src/Prebuilt/components/hooks/useRoleProminencePeers.tsx +38 -0
  140. package/src/Prebuilt/components/hooks/useTileLayout.tsx +121 -0
  141. package/src/Prebuilt/components/hooks/useVideoTileLayout.ts +22 -0
  142. package/src/Prebuilt/components/pdfAnnotator/pdfFileOptions.jsx +5 -72
  143. package/src/Prebuilt/components/pdfAnnotator/submitPdf.jsx +4 -45
  144. package/src/Prebuilt/components/pdfAnnotator/uploadedFile.jsx +2 -17
  145. package/src/Prebuilt/components/peerTileUtils.jsx +1 -1
  146. package/src/Prebuilt/images/empty-chat.svg +12 -0
  147. package/src/Prebuilt/layouts/EmbedView.jsx +17 -40
  148. package/src/Prebuilt/layouts/HLSView.jsx +83 -66
  149. package/src/Prebuilt/layouts/PDFView.jsx +1 -11
  150. package/src/Prebuilt/layouts/SidePane.tsx +96 -0
  151. package/src/Prebuilt/layouts/{mainView.jsx → VideoStreamingSection.tsx} +38 -47
  152. package/src/Prebuilt/layouts/WhiteboardView.jsx +10 -34
  153. package/src/Prebuilt/plugins/VirtualBackground/VirtualBackground.jsx +1 -4
  154. package/src/Prebuilt/plugins/whiteboard/{ToggleWhiteboard.jsx → ToggleWhiteboard.tsx} +5 -9
  155. package/src/Prebuilt/primitives/DialogContent.jsx +15 -11
  156. package/src/Prebuilt/provider/roomLayoutProvider/constants/index.ts +17 -2
  157. package/src/Prebuilt/provider/roomLayoutProvider/hooks/useFetchRoomLayout.ts +36 -13
  158. package/src/Prebuilt/provider/roomLayoutProvider/hooks/useInsetEnabled.ts +10 -0
  159. package/src/Prebuilt/provider/roomLayoutProvider/hooks/useRoomLayoutScreen.ts +65 -0
  160. package/src/Prebuilt/provider/roomLayoutProvider/index.tsx +17 -6
  161. package/dist/HLSView-P57IRMAR.js.map +0 -7
  162. package/dist/PinnedTrackView-4FYJEBTB.js +0 -102
  163. package/dist/PinnedTrackView-4FYJEBTB.js.map +0 -7
  164. package/dist/VirtualBackground-GGCQJ5JM.js.map +0 -7
  165. package/dist/chunk-IVTWKQI3.js +0 -827
  166. package/dist/chunk-IVTWKQI3.js.map +0 -7
  167. package/dist/chunk-OSM4QEQG.js.map +0 -7
  168. package/dist/chunk-P5X32KOD.js.map +0 -7
  169. package/dist/chunk-RVCZPPTL.js +0 -1100
  170. package/dist/chunk-RVCZPPTL.js.map +0 -7
  171. package/dist/conference-P6I6ESVF.js +0 -8995
  172. package/dist/conference-P6I6ESVF.js.map +0 -7
  173. package/src/Prebuilt/components/Chat/ChatHeader.jsx +0 -67
  174. package/src/Prebuilt/components/EqualProminence.jsx +0 -180
  175. package/src/Prebuilt/components/FirstPersonDisplay.jsx +0 -50
  176. package/src/Prebuilt/components/Footer/Footer.jsx +0 -73
  177. package/src/Prebuilt/components/Header/Header.jsx +0 -8
  178. package/src/Prebuilt/components/Header/StreamingHeader.jsx +0 -54
  179. package/src/Prebuilt/components/LeaveRoom.jsx +0 -94
  180. package/src/Prebuilt/components/MoreSettings/MoreSettings.jsx +0 -10
  181. package/src/Prebuilt/components/Notifications/MessageNotifications.jsx +0 -25
  182. package/src/Prebuilt/components/gridView.jsx +0 -85
  183. package/src/Prebuilt/components/hooks/useFeatures.js +0 -22
  184. package/src/Prebuilt/components/hooks/useNavigation.js +0 -19
  185. package/src/Prebuilt/components/hooks/useSkipPreview.jsx +0 -20
  186. package/src/Prebuilt/components/pdfAnnotator/pdfErrorView.jsx +0 -29
  187. package/src/Prebuilt/images/Logo.svg +0 -8
  188. package/src/Prebuilt/layouts/ActiveSpeakerView.jsx +0 -34
  189. package/src/Prebuilt/layouts/InsetView.jsx +0 -260
  190. package/src/Prebuilt/layouts/PinnedTrackView.jsx +0 -59
  191. package/src/Prebuilt/layouts/SidePane.jsx +0 -52
  192. package/src/Prebuilt/layouts/mainGridView.jsx +0 -98
  193. package/src/Prebuilt/layouts/screenShareView.jsx +0 -183
  194. /package/{src/Prebuilt/components/Header/index.jsx → dist/Prebuilt/components/Header/index.d.ts} +0 -0
  195. /package/src/Prebuilt/components/{ScreenShare.jsx → ScreenShareToggle.jsx} +0 -0
  196. /package/src/{assets → Prebuilt/images}/android-perm-1.png +0 -0
  197. /package/src/{assets → Prebuilt/images}/ios-perm-0.png +0 -0
@@ -1,51 +1,59 @@
1
1
  import React, { Suspense, useCallback, useEffect } from 'react';
2
+ import { HMSException } from '@100mslive/hms-video';
3
+ import {
4
+ ConferencingScreen,
5
+ DefaultConferencingScreen_Elements,
6
+ HLSLiveStreamingScreen_Elements,
7
+ } from '@100mslive/types-prebuilt';
2
8
  import {
3
9
  selectIsConnectedToRoom,
4
10
  selectLocalPeerRoleName,
5
- selectPeerScreenSharing,
6
- selectPeerSharingAudio,
7
- selectPeerSharingVideoPlaylist,
8
11
  selectPermissions,
9
12
  useHMSActions,
10
13
  useHMSStore,
11
14
  useRecordingStreaming,
12
15
  } from '@100mslive/react-sdk';
13
- import { EqualProminence } from '../components/EqualProminence';
16
+ // @ts-ignore: No implicit Any
14
17
  import FullPageProgress from '../components/FullPageProgress';
18
+ // @ts-ignore: No implicit Any
19
+ import { GridLayout } from '../components/VideoLayouts/GridLayout';
15
20
  import { Flex } from '../../Layout';
21
+ // @ts-ignore: No implicit Any
16
22
  import { EmbedView } from './EmbedView';
23
+ // @ts-ignore: No implicit Any
17
24
  import { PDFView } from './PDFView';
18
- import ScreenShareView from './screenShareView';
25
+ // @ts-ignore: No implicit Any
19
26
  import SidePane from './SidePane';
27
+ // @ts-ignore: No implicit Any
20
28
  import { WaitingView } from './WaitingView';
21
- import { useWhiteboardMetadata } from '../plugins/whiteboard';
29
+ // import { useWhiteboardMetadata } from '../plugins/whiteboard';
22
30
  import {
23
- useHLSViewerRole,
24
31
  usePDFAnnotator,
25
- usePinnedTrack,
26
32
  useSetAppDataByKey,
27
- useUISettings,
28
33
  useUrlToEmbed,
29
34
  useWaitingViewerRole,
35
+ // @ts-ignore: No implicit Any
30
36
  } from '../components/AppData/useUISettings';
37
+ // @ts-ignore: No implicit Any
31
38
  import { useShowStreamingUI } from '../common/hooks';
39
+ // @ts-ignore: No implicit Any
32
40
  import { APP_DATA, SESSION_STORE_KEY } from '../common/constants';
33
41
 
34
42
  // const WhiteboardView = React.lazy(() => import("./WhiteboardView"));
43
+ // @ts-ignore: No implicit Any
35
44
  const HLSView = React.lazy(() => import('./HLSView'));
36
- const PinnedTrackView = React.lazy(() => import('./PinnedTrackView'));
37
45
 
38
- export const ConferenceMainView = () => {
46
+ export const VideoStreamingSection = ({
47
+ screenType,
48
+ elements,
49
+ }: {
50
+ screenType: keyof ConferencingScreen;
51
+ elements: DefaultConferencingScreen_Elements | HLSLiveStreamingScreen_Elements;
52
+ }) => {
39
53
  const localPeerRole = useHMSStore(selectLocalPeerRoleName);
40
- const pinnedTrack = usePinnedTrack();
41
- const peerSharing = useHMSStore(selectPeerScreenSharing);
42
- const peerSharingAudio = useHMSStore(selectPeerSharingAudio);
43
- const peerSharingPlaylist = useHMSStore(selectPeerSharingVideoPlaylist);
44
- const { whiteboardOwner: whiteboardShared } = useWhiteboardMetadata();
54
+ // const { whiteboardOwner: whiteboardShared } = useWhiteboardMetadata();
45
55
  const isConnected = useHMSStore(selectIsConnectedToRoom);
46
56
  const hmsActions = useHMSActions();
47
- const { isAudioOnly } = useUISettings();
48
- const hlsViewerRole = useHLSViewerRole();
49
57
  const waitingViewerRole = useWaitingViewerRole();
50
58
  const urlToIframe = useUrlToEmbed();
51
59
  const pdfAnnotatorActive = usePDFAnnotator();
@@ -60,13 +68,9 @@ export const ConferenceMainView = () => {
60
68
  return;
61
69
  }
62
70
  setHLSStarted(true);
63
- await hmsActions.startHLSStreaming({});
71
+ await hmsActions.startHLSStreaming();
64
72
  } catch (error) {
65
- if (error.message === 'beam already started') {
66
- return;
67
- }
68
- if (error.message.includes('invalid input')) {
69
- await startHLS();
73
+ if ((error as HMSException).message?.includes('beam already started')) {
70
74
  return;
71
75
  }
72
76
  setHLSStarted(false);
@@ -88,15 +92,6 @@ export const ConferenceMainView = () => {
88
92
  if (!isConnected) {
89
93
  return;
90
94
  }
91
- const audioPlaylist = JSON.parse(process.env.REACT_APP_AUDIO_PLAYLIST || '[]');
92
- const videoPlaylist = JSON.parse(process.env.REACT_APP_VIDEO_PLAYLIST || '[]');
93
- if (videoPlaylist.length > 0) {
94
- hmsActions.videoPlaylist.setList(videoPlaylist);
95
- }
96
- if (audioPlaylist.length > 0) {
97
- hmsActions.audioPlaylist.setList(audioPlaylist);
98
- }
99
-
100
95
  hmsActions.sessionStore.observe([SESSION_STORE_KEY.PINNED_MESSAGE, SESSION_STORE_KEY.SPOTLIGHT]);
101
96
  // eslint-disable-next-line react-hooks/exhaustive-deps
102
97
  }, [isConnected, hmsActions]);
@@ -107,22 +102,17 @@ export const ConferenceMainView = () => {
107
102
  }
108
103
 
109
104
  let ViewComponent;
110
- if (localPeerRole === hlsViewerRole) {
111
- ViewComponent = HLSView;
105
+ if (screenType === 'hls_live_streaming') {
106
+ ViewComponent = <HLSView />;
112
107
  } else if (localPeerRole === waitingViewerRole) {
113
- ViewComponent = WaitingView;
108
+ ViewComponent = <WaitingView />;
114
109
  } else if (pdfAnnotatorActive) {
115
- ViewComponent = PDFView;
110
+ ViewComponent = <PDFView />;
116
111
  } else if (urlToIframe) {
117
- ViewComponent = EmbedView;
118
- } else if (whiteboardShared) {
119
- // ViewComponent = WhiteboardView;
120
- } else if (((peerSharing && peerSharing.id !== peerSharingAudio?.id) || peerSharingPlaylist) && !isAudioOnly) {
121
- ViewComponent = ScreenShareView;
122
- } else if (pinnedTrack) {
123
- ViewComponent = PinnedTrackView;
112
+ ViewComponent = <EmbedView />;
124
113
  } else {
125
- ViewComponent = EqualProminence;
114
+ //@ts-ignore
115
+ ViewComponent = <GridLayout {...(elements as DefaultConferencingScreen_Elements)?.video_tile_layout?.grid} />;
126
116
  }
127
117
 
128
118
  return (
@@ -131,10 +121,11 @@ export const ConferenceMainView = () => {
131
121
  css={{
132
122
  size: '100%',
133
123
  position: 'relative',
124
+ gap: '$4',
134
125
  }}
135
126
  >
136
- <ViewComponent />
137
- <SidePane />
127
+ {ViewComponent}
128
+ <SidePane screenType={screenType} />
138
129
  </Flex>
139
130
  </Suspense>
140
131
  );
@@ -1,12 +1,11 @@
1
1
  import React from 'react';
2
- import { useMedia } from 'react-use';
3
2
  import { selectPeers, selectRoomID, useHMSStore } from '@100mslive/react-sdk';
4
- import { Box, Flex } from '../../Layout';
5
- import { config as cssConfig } from '../../Theme';
6
- import { SidePane } from './screenShareView';
3
+ import { SecondaryTiles } from '../components/SecondaryTiles';
4
+ import { ProminenceLayout } from '../components/VideoLayouts/ProminenceLayout';
5
+ import { Box } from '../../Layout';
7
6
  // import { Whiteboard } from '../plugins/whiteboard';
8
7
 
9
- const Editor = React.memo(({ roomId }) => {
8
+ const Editor = React.memo(() => {
10
9
  return (
11
10
  <Box
12
11
  css={{
@@ -26,38 +25,15 @@ const Editor = React.memo(({ roomId }) => {
26
25
  });
27
26
 
28
27
  const WhiteboardView = () => {
29
- // for smaller screen we will show sidebar in bottom
30
- const mediaQueryLg = cssConfig.media.lg;
31
- const showSidebarInBottom = useMedia(mediaQueryLg);
32
28
  const peers = useHMSStore(selectPeers);
33
29
  const roomId = useHMSStore(selectRoomID);
34
30
  return (
35
- <Flex
36
- css={{
37
- size: '100%',
38
- }}
39
- direction={showSidebarInBottom ? 'column' : 'row'}
40
- >
41
- <Editor roomId={roomId} />
42
- <Flex
43
- direction={{ '@initial': 'column', '@lg': 'row' }}
44
- css={{
45
- overflow: 'hidden',
46
- p: '$4',
47
- flex: '0 0 20%',
48
- '@lg': {
49
- flex: '1 1 0',
50
- },
51
- }}
52
- >
53
- <SidePane
54
- showSidebarInBottom={showSidebarInBottom}
55
- isPresenterInSmallTiles={true}
56
- smallTilePeers={peers}
57
- totalPeers={peers.length}
58
- />
59
- </Flex>
60
- </Flex>
31
+ <ProminenceLayout.Root>
32
+ <ProminenceLayout.ProminentSection>
33
+ <Editor roomId={roomId} />
34
+ </ProminenceLayout.ProminentSection>
35
+ <SecondaryTiles peers={peers} />
36
+ </ProminenceLayout.Root>
61
37
  );
62
38
  };
63
39
 
@@ -13,9 +13,7 @@ import { ActionTile } from '../../components/MoreSettings/ActionTile';
13
13
  import { Loading } from '../../../Loading';
14
14
  import { Tooltip } from '../../../Tooltip';
15
15
  import IconButton from '../../IconButton';
16
- import { useIsFeatureEnabled } from '../../components/hooks/useFeatures';
17
16
  import { getRandomVirtualBackground } from './vbutils';
18
- import { FEATURE_LIST } from '../../common/constants';
19
17
 
20
18
  export const VirtualBackground = ({
21
19
  asActionTile = false,
@@ -32,7 +30,6 @@ export const VirtualBackground = ({
32
30
  const [isVBOn, setIsVBOn] = useState(false);
33
31
  const localPeerVideoTrackID = useHMSStore(selectLocalVideoTrackID);
34
32
  const isVBPresent = useHMSStore(selectIsLocalVideoPluginPresent('HMSVB'));
35
- const isFeatureEnabled = useIsFeatureEnabled(FEATURE_LIST.VIDEO_PLUGINS);
36
33
 
37
34
  async function createPlugin() {
38
35
  if (!pluginRef.current) {
@@ -72,7 +69,7 @@ export const VirtualBackground = ({
72
69
  }
73
70
  }
74
71
 
75
- if (!isAllowedToPublish.video || !isVBSupported || !isFeatureEnabled) {
72
+ if (!isAllowedToPublish.video || !isVBSupported) {
76
73
  return null;
77
74
  }
78
75
  if (asActionTile) {
@@ -1,25 +1,21 @@
1
1
  import React from 'react';
2
- import { selectLocalPeerRoleName, useHMSStore } from '@100mslive/react-sdk';
2
+ import { ConferencingScreen } from '@100mslive/types-prebuilt';
3
3
  import { PencilDrawIcon } from '@100mslive/react-icons';
4
4
  import { Tooltip } from '../../../Tooltip';
5
+ // @ts-ignore: No implicit any
5
6
  import IconButton from '../../IconButton';
6
- import { useHLSViewerRole } from '../../components/AppData/useUISettings';
7
- import { useIsFeatureEnabled } from '../../components/hooks/useFeatures';
7
+ // @ts-ignore: No implicit any
8
8
  import { useWhiteboardMetadata } from './useWhiteboardMetadata';
9
- import { FEATURE_LIST } from '../../common/constants';
10
9
 
11
- export const ToggleWhiteboard = () => {
10
+ export const ToggleWhiteboard = ({ screenType }: { screenType: keyof ConferencingScreen }) => {
12
11
  const {
13
12
  whiteboardEnabled,
14
13
  whiteboardOwner: whiteboardActive,
15
14
  amIWhiteboardOwner,
16
15
  toggleWhiteboard,
17
16
  } = useWhiteboardMetadata();
18
- const hlsViewerRole = useHLSViewerRole();
19
- const localPeerRole = useHMSStore(selectLocalPeerRoleName);
20
- const isFeatureEnabled = useIsFeatureEnabled(FEATURE_LIST.WHITEBOARD);
21
17
 
22
- if (!whiteboardEnabled || localPeerRole === hlsViewerRole || !isFeatureEnabled) {
18
+ if (!whiteboardEnabled || screenType === 'hls_live_streaming') {
23
19
  return null;
24
20
  }
25
21
 
@@ -67,17 +67,21 @@ export const RequestDialog = ({ open = true, onOpenChange, title, body, actionTe
67
67
  {Icon ? Icon : null}
68
68
  <Text variant="h6">{title}</Text>
69
69
  </Dialog.Title>
70
- <Text
71
- variant="md"
72
- css={{
73
- fontWeight: 400,
74
- mt: '$4',
75
- mb: '$10',
76
- c: '$on_surface_medium',
77
- }}
78
- >
79
- {body}
80
- </Text>
70
+ {typeof body === 'string' ? (
71
+ <Text
72
+ variant="md"
73
+ css={{
74
+ fontWeight: 400,
75
+ mt: '$4',
76
+ mb: '$10',
77
+ c: '$on_surface_medium',
78
+ }}
79
+ >
80
+ {body}
81
+ </Text>
82
+ ) : (
83
+ <Box css={{ mt: '$4', mb: '$10' }}>{body}</Box>
84
+ )}
81
85
  <Flex justify="center" align="center" css={{ width: '100%', gap: '$md' }}>
82
86
  <Box css={{ width: '50%' }}>
83
87
  <Dialog.Close css={{ width: '100%' }}>
@@ -20,14 +20,29 @@ export const defaultLayout: Layout = {
20
20
  sub_title: 'Setup your audio and video before joining',
21
21
  },
22
22
  join_form: {
23
- join_btn_type: JoinForm_JoinBtnType.JOIN_BTN_TYPE_JOIN_AND_GO_LIVE,
23
+ join_btn_type: JoinForm_JoinBtnType.JOIN_BTN_TYPE_JOIN_ONLY,
24
24
  join_btn_label: 'Join Now',
25
25
  go_live_btn_label: 'Go Live',
26
26
  },
27
27
  },
28
28
  },
29
29
  },
30
- conferencing: {},
30
+ conferencing: {
31
+ default: {
32
+ elements: {
33
+ chat: {},
34
+ participant_list: {},
35
+ video_tile_layout: {
36
+ grid: {
37
+ enable_local_tile_inset: true,
38
+ prominent_roles: [],
39
+ enable_spotlighting_peer: true,
40
+ },
41
+ },
42
+ emoji_reactions: {},
43
+ },
44
+ },
45
+ },
31
46
  leave: {},
32
47
  },
33
48
  };
@@ -1,4 +1,4 @@
1
- import { useEffect, useRef, useState } from 'react';
1
+ import { useCallback, useEffect, useRef, useState } from 'react';
2
2
  import type { GetResponse, Layout } from '@100mslive/types-prebuilt';
3
3
  import { defaultLayout } from '../constants';
4
4
 
@@ -25,33 +25,56 @@ export type useFetchRoomLayoutProps = {
25
25
 
26
26
  export type useFetchRoomLayoutResponse = {
27
27
  layout: Layout | undefined;
28
+ updateRoomLayoutForRole: (role: string) => void;
28
29
  };
29
30
 
30
31
  export const useFetchRoomLayout = ({
31
- endpoint = '',
32
+ endpoint = 'https://api.100ms.live/v2/layouts/ui',
32
33
  authToken = '',
33
34
  }: useFetchRoomLayoutProps): useFetchRoomLayoutResponse => {
34
35
  const [layout, setLayout] = useState<Layout | undefined>(undefined);
36
+ const layoutResp = useRef<GetResponse>();
35
37
  const isFetchInProgress = useRef(false);
38
+ const updateRoomLayoutForRole = useCallback((role: string) => {
39
+ if (!layoutResp.current) {
40
+ return;
41
+ }
42
+ const [layout] = (layoutResp.current?.data || []).filter(layout => layout.role === role);
43
+ if (layout) {
44
+ setLayout(layout);
45
+ }
46
+ }, []);
36
47
  useEffect(() => {
37
48
  (async () => {
38
49
  if (isFetchInProgress.current || !authToken) {
39
50
  return;
40
51
  }
41
- if (!endpoint) {
42
- setLayout(defaultLayout);
43
- }
44
52
  isFetchInProgress.current = true;
45
- const resp = await fetchWithRetry(endpoint, {
46
- headers: {
47
- Authorization: `Bearer ${authToken}`,
48
- },
49
- });
50
- const layoutResp: GetResponse = await resp.json();
51
- setLayout(layoutResp.data[0]);
53
+ try {
54
+ const resp = await fetchWithRetry(endpoint, {
55
+ headers: {
56
+ Authorization: `Bearer ${authToken}`,
57
+ },
58
+ });
59
+ layoutResp.current = await resp.json();
60
+ } catch (e) {
61
+ console.error('[Room Layout API]: Failed to fetch / process room layout. Resorting to default layout.', e);
62
+ layoutResp.current = {
63
+ data: [defaultLayout],
64
+ };
65
+ }
66
+ let layoutForRole = layoutResp.current?.data?.[0];
67
+ if (!layoutForRole) {
68
+ console.error(
69
+ '[Room Layout API]: Unable to figure out room layout from API response. Resorting to default layout.',
70
+ );
71
+ layoutForRole = defaultLayout;
72
+ }
73
+ const layout = layoutForRole;
74
+ setLayout(layout);
52
75
  isFetchInProgress.current = false;
53
76
  })();
54
77
  }, [authToken, endpoint]);
55
78
 
56
- return { layout };
79
+ return { layout, updateRoomLayoutForRole };
57
80
  };
@@ -0,0 +1,10 @@
1
+ import { useRoomLayout } from '..';
2
+
3
+ export const useInsetEnabled = (): boolean => {
4
+ const layout = useRoomLayout();
5
+ const { enable_local_tile_inset = true } =
6
+ //@ts-ignore
7
+ layout?.screens?.conferencing?.default?.elements?.video_tile_layout?.grid || {};
8
+
9
+ return enable_local_tile_inset;
10
+ };
@@ -0,0 +1,65 @@
1
+ import {
2
+ ConferencingScreen,
3
+ DefaultPreviewScreen_Elements,
4
+ LeaveScreen,
5
+ PreviewScreen,
6
+ Screens,
7
+ } from '@100mslive/types-prebuilt';
8
+ import { useRoomLayout } from '..';
9
+
10
+ export type useRoomLayoutScreenProps = {
11
+ screen: keyof Screens;
12
+ };
13
+
14
+ type useRoomLayoutScreenReturnType<T extends useRoomLayoutScreenProps> = T['screen'] extends 'conferencing'
15
+ ? ConferencingScreen
16
+ : T['screen'] extends 'leave'
17
+ ? LeaveScreen
18
+ : T['screen'] extends 'preview'
19
+ ? PreviewScreen
20
+ : undefined;
21
+
22
+ function useRoomLayoutScreen<T extends useRoomLayoutScreenProps>({
23
+ screen,
24
+ }: T): useRoomLayoutScreenReturnType<T> | undefined {
25
+ const roomLayout = useRoomLayout();
26
+ const screenProps = roomLayout?.screens?.[screen] as useRoomLayoutScreenReturnType<T> | undefined;
27
+ return screenProps;
28
+ }
29
+
30
+ export function useRoomLayoutPreviewScreen() {
31
+ const screenProps = useRoomLayoutScreen({ screen: 'preview' });
32
+ const isPreviewScreenEnabled = !!screenProps;
33
+ let elements: DefaultPreviewScreen_Elements | undefined;
34
+ let screenType: keyof PreviewScreen | undefined;
35
+ if (isPreviewScreenEnabled) {
36
+ screenType = Object.keys(screenProps)[0] as keyof PreviewScreen;
37
+ elements = screenProps[screenType]?.elements;
38
+ }
39
+ return {
40
+ isPreviewScreenEnabled,
41
+ elements,
42
+ screenType,
43
+ };
44
+ }
45
+
46
+ export function useRoomLayoutConferencingScreen() {
47
+ const screenProps = useRoomLayoutScreen({ screen: 'conferencing' }) || {};
48
+ const screenType = Object.keys(screenProps)[0] as keyof ConferencingScreen;
49
+ const elements = screenProps[screenType]?.elements;
50
+ // @ts-ignore
51
+ const hideSections: string[] = screenProps[screenType]?.hideSections || [];
52
+ return {
53
+ hideSections,
54
+ elements,
55
+ screenType,
56
+ };
57
+ }
58
+
59
+ export function useRoomLayoutLeaveScreen() {
60
+ const screenProps = useRoomLayoutScreen({ screen: 'leave' });
61
+ const isLeaveScreenEnabled = !!screenProps;
62
+ return {
63
+ isLeaveScreenEnabled,
64
+ };
65
+ }
@@ -3,14 +3,20 @@ import type { Layout } from '@100mslive/types-prebuilt';
3
3
  import merge from 'lodash.merge';
4
4
  // @ts-ignore: fix types
5
5
  import { useAuthToken } from '../../components/AppData/useUISettings';
6
- import { useFetchRoomLayout } from './hooks/useFetchRoomLayout';
6
+ import { useFetchRoomLayout, useFetchRoomLayoutResponse } from './hooks/useFetchRoomLayout';
7
7
 
8
8
  export type RoomLayoutProviderProps = {
9
9
  roomLayoutEndpoint?: string;
10
10
  overrideLayout?: Partial<Layout>;
11
11
  };
12
12
 
13
- export const RoomLayoutContext = React.createContext<Layout | undefined>(undefined);
13
+ export const RoomLayoutContext = React.createContext<
14
+ | {
15
+ layout: Layout | undefined;
16
+ updateRoomLayoutForRole: useFetchRoomLayoutResponse['updateRoomLayoutForRole'] | undefined;
17
+ }
18
+ | undefined
19
+ >(undefined);
14
20
 
15
21
  export const RoomLayoutProvider: React.FC<React.PropsWithChildren<RoomLayoutProviderProps>> = ({
16
22
  children,
@@ -18,9 +24,14 @@ export const RoomLayoutProvider: React.FC<React.PropsWithChildren<RoomLayoutProv
18
24
  overrideLayout,
19
25
  }) => {
20
26
  const authToken: string = useAuthToken();
21
- let { layout } = useFetchRoomLayout({ authToken, endpoint: roomLayoutEndpoint });
22
- layout = merge(layout, overrideLayout);
23
- return <RoomLayoutContext.Provider value={layout}>{children}</RoomLayoutContext.Provider>;
27
+ const { layout, updateRoomLayoutForRole } = useFetchRoomLayout({ authToken, endpoint: roomLayoutEndpoint });
28
+ const mergedLayout = authToken && layout ? merge(layout, overrideLayout) : layout;
29
+ return (
30
+ <RoomLayoutContext.Provider value={{ layout: mergedLayout, updateRoomLayoutForRole }}>
31
+ {children}
32
+ </RoomLayoutContext.Provider>
33
+ );
24
34
  };
25
35
 
26
- export const useRoomLayout = (): Layout | undefined => React.useContext(RoomLayoutContext);
36
+ export const useRoomLayout = () => React.useContext(RoomLayoutContext)?.layout;
37
+ export const useUpdateRoomLayout = () => React.useContext(RoomLayoutContext)?.updateRoomLayoutForRole;
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../src/Prebuilt/layouts/HLSView.jsx", "../src/Prebuilt/components/HlsStatsOverlay.jsx", "../src/Prebuilt/components/HMSVideo/index.js", "../src/Prebuilt/components/HMSVideo/Controls.jsx", "../src/Prebuilt/components/HMSVideo/HMSVideo.jsx", "../src/Prebuilt/components/HMSVideo/PlayButton.jsx", "../src/Prebuilt/components/HMSVideo/VideoProgress.jsx", "../src/Prebuilt/components/HMSVideo/HMSVIdeoUtils.js", "../src/Prebuilt/components/HMSVideo/VideoTime.jsx", "../src/Prebuilt/components/HMSVideo/VolumeControl.jsx", "../src/Prebuilt/components/HMSVideo/FullscreenButton.jsx", "../src/Prebuilt/components/HMSVideo/HLSAutoplayBlockedPrompt.jsx", "../src/Prebuilt/components/HMSVideo/HLSQualitySelector.jsx"],
4
- "sourcesContent": ["import React, { useCallback, useEffect, useRef, useState } from 'react';\nimport { useFullscreen, useToggle } from 'react-use';\nimport { HLSPlaybackState, HMSHLSPlayer, HMSHLSPlayerEvents } from '@100mslive/hls-player';\nimport screenfull from 'screenfull';\nimport { selectAppData, selectHLSState, useHMSActions, useHMSStore } from '@100mslive/react-sdk';\nimport { ExpandIcon, ShrinkIcon } from '@100mslive/react-icons';\nimport { HlsStatsOverlay } from '../components/HlsStatsOverlay';\nimport { HMSVideoPlayer } from '../components/HMSVideo';\nimport { FullScreenButton } from '../components/HMSVideo/FullscreenButton';\nimport { HLSAutoplayBlockedPrompt } from '../components/HMSVideo/HLSAutoplayBlockedPrompt';\nimport { HLSQualitySelector } from '../components/HMSVideo/HLSQualitySelector';\nimport { ToastManager } from '../components/Toast/ToastManager';\nimport { IconButton } from '../../IconButton';\nimport { Box, Flex } from '../../Layout';\nimport { Loading } from '../../Loading';\nimport { Text } from '../../Text';\nimport { useTheme } from '../../Theme';\nimport { Tooltip } from '../../Tooltip';\nimport { APP_DATA, EMOJI_REACTION_TYPE } from '../common/constants';\n\nlet hlsPlayer;\n\nconst HLSView = () => {\n const videoRef = useRef(null);\n const hlsViewRef = useRef(null);\n const hlsState = useHMSStore(selectHLSState);\n const enablHlsStats = useHMSStore(selectAppData(APP_DATA.hlsStats));\n const hmsActions = useHMSActions();\n const { themeType } = useTheme();\n let [hlsStatsState, setHlsStatsState] = useState(null);\n const hlsUrl = hlsState.variants[0]?.url;\n const [availableLayers, setAvailableLayers] = useState([]);\n const [isVideoLive, setIsVideoLive] = useState(true);\n const [isUserSelectedAuto, setIsUserSelectedAuto] = useState(true);\n const [currentSelectedQuality, setCurrentSelectedQuality] = useState(null);\n const [isHlsAutoplayBlocked, setIsHlsAutoplayBlocked] = useState(false);\n const [isPaused, setIsPaused] = useState(false);\n const isFullScreenSupported = screenfull.isEnabled;\n const [show, toggle] = useToggle(false);\n const isFullScreen = useFullscreen(hlsViewRef, show, {\n onClose: () => toggle(false),\n });\n const [showLoader, setShowLoader] = useState(false);\n\n // FIXME: move this logic to player controller in next release\n useEffect(() => {\n /**\n * @type {HTMLVideoElement} videoEl\n */\n const videoEl = videoRef.current;\n const showLoader = () => setShowLoader(true);\n const hideLoader = () => setShowLoader(false);\n videoEl?.addEventListener('playing', hideLoader);\n videoEl?.addEventListener('waiting', showLoader);\n return () => {\n videoEl?.removeEventListener('playing', hideLoader);\n videoEl?.removeEventListener('waiting', showLoader);\n };\n }, []);\n\n /**\n * initialize HMSHLSPlayer and add event listeners.\n */\n useEffect(() => {\n let videoEl = videoRef.current;\n const manifestLoadedHandler = ({ layers }) => {\n setAvailableLayers(layers);\n };\n const layerUpdatedHandler = ({ layer }) => {\n setCurrentSelectedQuality(layer);\n };\n const metadataLoadedHandler = ({ payload, ...rest }) => {\n const parsePayload = str => {\n try {\n return JSON.parse(str);\n } catch (e) {\n return str;\n }\n };\n // parse payload and extract start_time and payload\n const duration = rest.duration;\n const parsedPayload = parsePayload(payload);\n switch (parsedPayload.type) {\n case EMOJI_REACTION_TYPE:\n window.showFlyingEmoji(parsedPayload?.emojiId, parsedPayload?.senderId);\n break;\n default: {\n const toast = {\n title: `Payload from timed Metadata ${parsedPayload}`,\n duration: duration || 3000,\n };\n console.debug('Added toast ', JSON.stringify(toast));\n ToastManager.addToast(toast);\n break;\n }\n }\n };\n const handleError = data => {\n console.error('[HLSView] error in hls', `${data}`);\n };\n const handleNoLongerLive = ({ isLive }) => {\n setIsVideoLive(isLive);\n };\n\n const playbackEventHandler = data => setIsPaused(data.state === HLSPlaybackState.paused);\n\n const handleAutoplayBlock = data => setIsHlsAutoplayBlocked(!!data);\n if (videoEl && hlsUrl) {\n hlsPlayer = new HMSHLSPlayer(hlsUrl, videoEl);\n hlsPlayer.on(HMSHLSPlayerEvents.SEEK_POS_BEHIND_LIVE_EDGE, handleNoLongerLive);\n hlsPlayer.on(HMSHLSPlayerEvents.TIMED_METADATA_LOADED, metadataLoadedHandler);\n hlsPlayer.on(HMSHLSPlayerEvents.ERROR, handleError);\n hlsPlayer.on(HMSHLSPlayerEvents.PLAYBACK_STATE, playbackEventHandler);\n hlsPlayer.on(HMSHLSPlayerEvents.AUTOPLAY_BLOCKED, handleAutoplayBlock);\n\n hlsPlayer.on(HMSHLSPlayerEvents.MANIFEST_LOADED, manifestLoadedHandler);\n hlsPlayer.on(HMSHLSPlayerEvents.LAYER_UPDATED, layerUpdatedHandler);\n return () => {\n hlsPlayer.off(HMSHLSPlayerEvents.SEEK_POS_BEHIND_LIVE_EDGE, handleNoLongerLive);\n hlsPlayer.off(HMSHLSPlayerEvents.ERROR, handleError);\n hlsPlayer.off(HMSHLSPlayerEvents.TIMED_METADATA_LOADED, metadataLoadedHandler);\n hlsPlayer.off(HMSHLSPlayerEvents.PLAYBACK_STATE, playbackEventHandler);\n hlsPlayer.off(HMSHLSPlayerEvents.AUTOPLAY_BLOCKED, handleAutoplayBlock);\n hlsPlayer.off(HMSHLSPlayerEvents.MANIFEST_LOADED, manifestLoadedHandler);\n hlsPlayer.off(HMSHLSPlayerEvents.LAYER_UPDATED, layerUpdatedHandler);\n hlsPlayer.reset();\n hlsPlayer = null;\n };\n }\n }, [hlsUrl]);\n\n /**\n * initialize and subscribe to hlsState\n */\n useEffect(() => {\n const onHLSStats = state => setHlsStatsState(state);\n if (enablHlsStats) {\n hlsPlayer?.on(HMSHLSPlayerEvents.STATS, onHLSStats);\n } else {\n hlsPlayer?.off(HMSHLSPlayerEvents.STATS, onHLSStats);\n }\n return () => {\n hlsPlayer?.off(HMSHLSPlayerEvents.STATS, onHLSStats);\n };\n }, [enablHlsStats]);\n\n const unblockAutoPlay = async () => {\n try {\n await hlsPlayer.play();\n setIsHlsAutoplayBlocked(false);\n } catch (error) {\n console.error('Tried to unblock Autoplay failed with', error.message);\n }\n };\n\n const handleQuality = useCallback(\n quality => {\n if (hlsPlayer) {\n setIsUserSelectedAuto(quality.height.toString().toLowerCase() === 'auto');\n hlsPlayer.setLayer(quality);\n }\n },\n [availableLayers], //eslint-disable-line\n );\n\n const sfnOverlayClose = () => {\n hmsActions.setAppData(APP_DATA.hlsStats, !enablHlsStats);\n };\n\n return (\n <Flex\n key=\"hls-viewer\"\n id={`hls-viewer-${themeType}`}\n ref={hlsViewRef}\n css={{\n size: '100%',\n }}\n >\n {hlsStatsState?.url && enablHlsStats ? (\n <HlsStatsOverlay hlsStatsState={hlsStatsState} onClose={sfnOverlayClose} />\n ) : null}\n {hlsUrl && hlsState.running ? (\n <Flex\n id=\"hls-player-container\"\n align=\"center\"\n justify=\"center\"\n css={{\n width: '100%',\n margin: '0 auto',\n height: '100%',\n }}\n >\n <HLSAutoplayBlockedPrompt open={isHlsAutoplayBlocked} unblockAutoPlay={unblockAutoPlay} />\n {showLoader && (\n <Flex\n align=\"center\"\n justify=\"center\"\n css={{\n position: 'absolute',\n }}\n >\n <Loading width={72} height={72} />\n </Flex>\n )}\n <HMSVideoPlayer.Root ref={videoRef}>\n {hlsPlayer && (\n <HMSVideoPlayer.Progress\n onValueChange={currentTime => {\n hlsPlayer.seekTo(currentTime);\n }}\n hlsPlayer={hlsPlayer}\n />\n )}\n\n <HMSVideoPlayer.Controls.Root css={{ p: '$4 $8' }}>\n <HMSVideoPlayer.Controls.Left>\n <HMSVideoPlayer.PlayButton\n onClick={async () => {\n isPaused ? await hlsPlayer?.play() : hlsPlayer?.pause();\n }}\n isPaused={isPaused}\n />\n <HMSVideoPlayer.Duration hlsPlayer={hlsPlayer} />\n <HMSVideoPlayer.Volume hlsPlayer={hlsPlayer} />\n </HMSVideoPlayer.Controls.Left>\n\n <HMSVideoPlayer.Controls.Right>\n {availableLayers.length > 0 ? (\n <>\n <IconButton\n variant=\"standard\"\n css={{ px: '$2' }}\n onClick={async () => {\n await hlsPlayer.seekToLivePosition();\n setIsVideoLive(true);\n }}\n key=\"jump-to-live_btn\"\n data-testid=\"jump-to-live_btn\"\n >\n <Tooltip title=\"Go to Live\" side=\"top\">\n <Flex justify=\"center\" gap={2} align=\"center\">\n <Box\n css={{\n height: '$4',\n width: '$4',\n background: isVideoLive ? '$alert_error_default' : '$on_primary_high',\n r: '$1',\n }}\n />\n <Text\n variant={{\n '@sm': 'xs',\n }}\n >\n {isVideoLive ? 'LIVE' : 'GO LIVE'}\n </Text>\n </Flex>\n </Tooltip>\n </IconButton>\n <HLSQualitySelector\n layers={availableLayers}\n selection={currentSelectedQuality}\n onQualityChange={handleQuality}\n isAuto={isUserSelectedAuto}\n />\n </>\n ) : null}\n {isFullScreenSupported ? (\n <FullScreenButton\n isFullScreen={isFullScreen}\n onToggle={toggle}\n icon={isFullScreen ? <ShrinkIcon /> : <ExpandIcon />}\n />\n ) : null}\n </HMSVideoPlayer.Controls.Right>\n </HMSVideoPlayer.Controls.Root>\n </HMSVideoPlayer.Root>\n </Flex>\n ) : (\n <Flex align=\"center\" justify=\"center\" css={{ size: '100%', px: '$10' }}>\n <Text variant=\"md\" css={{ textAlign: 'center' }}>\n Waiting for the stream to start...\n </Text>\n </Flex>\n )}\n </Flex>\n );\n};\n\nexport default HLSView;\n", "import React, { memo } from 'react';\nimport { CloseIcon } from '@100mslive/react-icons';\nimport { Flex } from '../../Layout';\nimport { Text } from '../../Text';\nimport IconButton from '../IconButton';\n\nexport function HlsStatsOverlay({ hlsStatsState, onClose }) {\n return (\n <Flex\n css={{\n position: 'absolute',\n width: '$80',\n marginLeft: '$8',\n padding: '$8 $8 $10',\n zIndex: 10,\n backgroundColor: '$surface_brighter',\n borderRadius: '$1',\n }}\n direction=\"column\"\n >\n <IconButton css={{ position: 'absolute', top: '$2', right: '$2' }} onClick={onClose}>\n <CloseIcon />\n </IconButton>\n <HlsStatsRow label=\"URL\">\n <Flex align=\"center\">\n <a\n style={{ cursor: 'pointer', textDecoration: 'underline' }}\n href={hlsStatsState?.url}\n target=\"_blank\"\n rel=\"noreferrer\"\n >\n Stream url\n </a>\n </Flex>\n </HlsStatsRow>\n <HlsStatsRow label=\"Video size\">\n {` ${hlsStatsState?.videoSize?.width}x${hlsStatsState?.videoSize?.height}`}\n </HlsStatsRow>\n <HlsStatsRow label=\"Buffer duration\">{hlsStatsState?.bufferedDuration?.toFixed(2)} </HlsStatsRow>\n <HlsStatsRow label=\"Connection speed\">\n {`${(hlsStatsState?.bandwidthEstimate / (1000 * 1000)).toFixed(2)} Mbps`}\n </HlsStatsRow>\n <HlsStatsRow label=\"Bitrate\">{`${(hlsStatsState?.bitrate / (1000 * 1000)).toFixed(2)} Mbps`}</HlsStatsRow>\n <HlsStatsRow label=\"distance from live\">\n {getDurationFromSeconds(hlsStatsState.distanceFromLive / 1000)}\n </HlsStatsRow>\n <HlsStatsRow label=\"Dropped frames\">{hlsStatsState?.droppedFrames}</HlsStatsRow>\n </Flex>\n );\n}\n\n/**\n * Extracted from HLS new Player PR.\n * TODO: remove this and use HMSVideoUtils.js\n * when that code is merged\n */\nexport function getDurationFromSeconds(timeInSeconds) {\n let time = Math.floor(timeInSeconds);\n const hours = Math.floor(time / 3600);\n time = time - hours * 3600;\n const minutes = Math.floor(time / 60);\n const seconds = Math.floor(time - minutes * 60);\n\n const prefixedMinutes = `${minutes < 10 ? '0' + minutes : minutes}`;\n const prefixedSeconds = `${seconds < 10 ? '0' + seconds : seconds}`;\n\n let videoTimeStr = `${prefixedMinutes}:${prefixedSeconds}`;\n if (hours) {\n const prefixedHours = `${hours < 10 ? '0' + hours : hours}`;\n videoTimeStr = `${prefixedHours}:${prefixedMinutes}:${prefixedSeconds}`;\n }\n return videoTimeStr;\n}\n\nconst HlsStatsRow = memo(({ label, children }) => {\n return (\n <Flex gap={4} justify=\"center\" css={{ width: '100%' }}>\n <Text\n css={{\n width: '50%',\n '@md': { fontSize: '$md' },\n '@sm': { fontSize: '$sm' },\n // textAlign: \"right\",\n }}\n >\n {label}\n </Text>\n <Text\n css={{\n '@md': { fontSize: '$md' },\n '@sm': { fontSize: '$sm' },\n width: '50%',\n overflowWrap: 'break-word',\n // textAlign: \"left\",\n }}\n >\n {children}\n </Text>\n </Flex>\n );\n});\n", "import { LeftControls, RightControls, VideoControls } from './Controls';\nimport { HMSVideo } from './HMSVideo';\nimport { PlayButton } from './PlayButton';\nimport { VideoProgress } from './VideoProgress';\nimport { VideoTime } from './VideoTime';\nimport { VolumeControl } from './VolumeControl';\n\nexport const HMSVideoPlayer = {\n Root: HMSVideo,\n PlayButton: PlayButton,\n Progress: VideoProgress,\n Duration: VideoTime,\n Volume: VolumeControl,\n Controls: {\n Root: VideoControls,\n Left: LeftControls,\n Right: RightControls,\n },\n};\n", "import { Flex, styled } from '../../../';\n\nexport const VideoControls = styled(Flex, {\n justifyContent: 'center',\n alignItems: 'center',\n width: '100%',\n gap: '$2',\n});\n\nexport const LeftControls = styled(Flex, {\n justifyContent: 'flex-start',\n alignItems: 'center',\n width: '100%',\n gap: '$2',\n});\nexport const RightControls = styled(Flex, {\n justifyContent: 'flex-end',\n alignItems: 'center',\n width: '100%',\n gap: '$2',\n});\n", "import React, { forwardRef } from 'react';\nimport { Flex } from '../../../';\n\nexport const HMSVideo = forwardRef(({ children }, videoRef) => {\n return (\n <Flex data-testid=\"hms-video\" css={{ size: '100%' }} direction=\"column\">\n <video style={{ flex: '1 1 0', margin: '0 auto', minHeight: '0' }} ref={videoRef} playsInline />\n {children}\n </Flex>\n );\n});\n", "import React from 'react';\nimport { PauseIcon, PlayIcon } from '@100mslive/react-icons';\nimport { IconButton, Tooltip } from '../../../';\n\nexport const PlayButton = ({ onClick, isPaused }) => {\n return (\n <Tooltip title={isPaused ? 'Play' : 'Pause'} side=\"top\">\n <IconButton onClick={onClick} data-testid=\"play_pause_btn\">\n {isPaused ? <PlayIcon width={32} height={32} /> : <PauseIcon width={32} height={32} />}\n </IconButton>\n </Tooltip>\n );\n};\n", "import React, { useEffect, useRef, useState } from 'react';\nimport { Box, Flex } from '../../../';\nimport { getPercentage } from './HMSVIdeoUtils';\n\nexport const VideoProgress = ({ onValueChange, hlsPlayer }) => {\n const [videoProgress, setVideoProgress] = useState(0);\n const [bufferProgress, setBufferProgress] = useState(0);\n const progressRootRef = useRef();\n\n useEffect(() => {\n const videoEl = hlsPlayer.getVideoElement();\n const timeupdateHandler = () => {\n const videoProgress = Math.floor(getPercentage(videoEl.currentTime, videoEl.duration));\n let bufferProgress = 0;\n if (videoEl.buffered.length > 0) {\n bufferProgress = Math.floor(getPercentage(videoEl.buffered?.end(0), videoEl.duration));\n }\n\n setVideoProgress(isNaN(videoProgress) ? 0 : videoProgress);\n setBufferProgress(isNaN(bufferProgress) ? 0 : bufferProgress);\n };\n if (videoEl) {\n videoEl.addEventListener('timeupdate', timeupdateHandler);\n }\n return function cleanup() {\n if (videoEl) {\n videoEl.removeEventListener('timeupdate', timeupdateHandler);\n }\n };\n }, [hlsPlayer]);\n\n const onProgressChangeHandler = e => {\n const userClickedX = e.clientX - progressRootRef.current.offsetLeft;\n const progressBarWidth = progressRootRef.current.offsetWidth;\n const progress = Math.floor(getPercentage(userClickedX, progressBarWidth));\n const videoEl = hlsPlayer.getVideoElement();\n const currentTime = (progress * videoEl.duration) / 100;\n\n if (onValueChange) {\n onValueChange(currentTime);\n }\n };\n\n return hlsPlayer.getVideoElement() ? (\n <Flex\n ref={progressRootRef}\n css={{ paddingLeft: '$8', paddingRight: '$8', cursor: 'pointer' }}\n onClick={onProgressChangeHandler}\n >\n <Box\n id=\"video-actual\"\n css={{\n display: 'inline',\n width: `${videoProgress}%`,\n background: '$primary_default',\n height: '0.3rem',\n }}\n />\n <Box\n id=\"video-buffer\"\n css={{\n width: `${bufferProgress - videoProgress}%`,\n background: '$primary_dim',\n height: '0.3rem',\n }}\n />\n <Box\n id=\"video-rest\"\n css={{\n width: `${100 - bufferProgress}%`,\n background: '$surface_brighter',\n height: '0.3rem',\n }}\n />\n </Flex>\n ) : null;\n};\n", "export function getPercentage(a, b) {\n return (a / b) * 100;\n}\n\n/**\n *\n * @param {number} timeInSeconds - if given as floating point value, it is floored.\n * @returns a string representing timeInSeconds in HH:MM:SS format.\n * (e.g) getDurationFromSeconds(3910) returns \"1:05:10\"\n */\nexport function getDurationFromSeconds(timeInSeconds) {\n let time = Math.floor(timeInSeconds);\n const hours = Math.floor(time / 3600);\n time = time - hours * 3600;\n const minutes = Math.floor(time / 60);\n const seconds = Math.floor(time - minutes * 60);\n\n const prefixedMinutes = `${minutes < 10 ? `0${minutes}` : minutes}`;\n const prefixedSeconds = `${seconds < 10 ? `0${seconds}` : seconds}`;\n\n let videoTimeStr = `${prefixedMinutes}:${prefixedSeconds}`;\n if (hours) {\n const prefixedHours = `${hours < 10 ? `0${hours}` : hours}`;\n videoTimeStr = `${prefixedHours}:${prefixedMinutes}:${prefixedSeconds}`;\n }\n return videoTimeStr;\n}\n", "import React, { useEffect, useState } from 'react';\nimport { HMSHLSPlayerEvents } from '@100mslive/hls-player';\nimport { Text } from '../../../';\nimport { getDurationFromSeconds } from './HMSVIdeoUtils';\n\nexport const VideoTime = ({ hlsPlayer }) => {\n const [videoTime, setVideoTime] = useState('');\n\n useEffect(() => {\n const timeupdateHandler = currentTime => setVideoTime(getDurationFromSeconds(currentTime));\n if (hlsPlayer) {\n hlsPlayer.on(HMSHLSPlayerEvents.CURRENT_TIME, timeupdateHandler);\n }\n return function cleanup() {\n if (hlsPlayer) {\n hlsPlayer.off(HMSHLSPlayerEvents.CURRENT_TIME, timeupdateHandler);\n }\n };\n }, [hlsPlayer]);\n\n return hlsPlayer ? (\n <Text\n css={{\n minWidth: '$16',\n }}\n variant={{\n '@sm': 'xs',\n }}\n >\n {videoTime}\n </Text>\n ) : null;\n};\n", "import React, { useState } from 'react';\nimport { SpeakerIcon } from '@100mslive/react-icons';\nimport { Flex, Slider } from '../../../';\n\nexport const VolumeControl = ({ hlsPlayer }) => {\n const [volume, setVolume] = useState(hlsPlayer?.volume ?? 100);\n\n return (\n <Flex align=\"center\" css={{ color: '$on_primary_high' }}>\n <SpeakerIcon\n style={{ cursor: 'pointer' }}\n onClick={() => {\n setVolume(0);\n if (hlsPlayer) {\n hlsPlayer.setVolume(0);\n }\n }}\n />\n <Slider\n css={{\n mx: '$4',\n w: '$20',\n cursor: 'pointer',\n '@sm': { w: '$14' },\n '@xs': { w: '$14' },\n }}\n min={0}\n max={100}\n step={1}\n value={[volume]}\n onValueChange={volume => {\n hlsPlayer.setVolume(volume);\n setVolume(volume);\n }}\n thumbStyles={{ w: '$6', h: '$6' }}\n />\n </Flex>\n );\n};\n", "import React from 'react';\nimport { Flex, IconButton, Tooltip } from '../../../';\n\nexport const FullScreenButton = ({ isFullScreen, icon, onToggle }) => {\n return (\n <Tooltip title={`${isFullScreen ? 'Exit' : 'Go'} fullscreen`} side=\"top\">\n <IconButton\n variant=\"standard\"\n css={{ margin: '0px' }}\n onClick={onToggle}\n key=\"fullscreen_btn\"\n data-testid=\"fullscreen_btn\"\n >\n <Flex>{icon}</Flex>\n </IconButton>\n </Tooltip>\n );\n};\n", "import React from 'react';\nimport { Button, Dialog, Text } from '../../../';\nimport { DialogContent, DialogRow } from '../../primitives/DialogContent';\n\nexport function HLSAutoplayBlockedPrompt({ open, unblockAutoPlay }) {\n return (\n <Dialog.Root\n open={open}\n onOpenChange={value => {\n if (!value) {\n unblockAutoPlay();\n }\n }}\n >\n <DialogContent title=\"Attention\" closeable={false}>\n <DialogRow>\n <Text variant=\"md\">\n The browser wants us to get a confirmation for playing the HLS Stream. Please click \"play stream\" to\n proceed.\n </Text>\n </DialogRow>\n <DialogRow justify=\"end\">\n <Button\n variant=\"primary\"\n onClick={() => {\n unblockAutoPlay();\n }}\n >\n Play stream\n </Button>\n </DialogRow>\n </DialogContent>\n </Dialog.Root>\n );\n}\n", "import React, { useState } from 'react';\nimport { CheckCircleIcon, SettingsIcon } from '@100mslive/react-icons';\nimport { Box, Dropdown, Flex, Text, Tooltip } from '../../../';\n\nexport function HLSQualitySelector({ layers, onQualityChange, selection, isAuto }) {\n const [qualityDropDownOpen, setQualityDropDownOpen] = useState(false);\n\n return (\n <Dropdown.Root open={qualityDropDownOpen} onOpenChange={value => setQualityDropDownOpen(value)}>\n <Dropdown.Trigger asChild data-testid=\"quality_selector\">\n <Flex\n css={{\n color: '$on_primary_high',\n r: '$1',\n cursor: 'pointer',\n p: '$2',\n }}\n >\n <Tooltip title=\"Select Quality\" side=\"top\">\n <Flex align=\"center\">\n <Box\n css={{\n w: '$9',\n h: '$9',\n display: 'inline-flex',\n alignItems: 'center',\n }}\n >\n <SettingsIcon />\n </Box>\n <Text\n variant={{\n '@md': 'sm',\n '@sm': 'xs',\n '@xs': 'tiny',\n }}\n css={{ display: 'flex', alignItems: 'center', ml: '$2' }}\n >\n {isAuto && (\n <>\n Auto\n <Box\n css={{\n mx: '$2',\n w: '$2',\n h: '$2',\n background: '$on_primary_high',\n r: '$1',\n }}\n />\n </>\n )}\n {selection && Math.min(selection.width, selection.height)}p\n </Text>\n </Flex>\n </Tooltip>\n </Flex>\n </Dropdown.Trigger>\n {layers.length > 0 && (\n <Dropdown.Content sideOffset={5} align=\"end\" css={{ height: 'auto', maxHeight: '$96', w: '$64' }}>\n <Dropdown.Item onClick={() => onQualityChange({ height: 'auto' })} key=\"auto\">\n <Text css={{ flex: '1 1 0' }}>Automatic</Text>\n {isAuto && <CheckCircleIcon />}\n </Dropdown.Item>\n {layers.map(layer => {\n return (\n <Dropdown.Item onClick={() => onQualityChange(layer)} key={layer.width}>\n <Text css={{ flex: '1 1 0' }}>{getQualityText(layer)}</Text>\n {!isAuto && layer.width === selection?.width && layer.height === selection?.height && (\n <CheckCircleIcon />\n )}\n </Dropdown.Item>\n );\n })}\n </Dropdown.Content>\n )}\n </Dropdown.Root>\n );\n}\n\nconst getQualityText = layer =>\n `${Math.min(layer.height, layer.width)}p (${(Number(layer.bitrate / 1000) / 1000).toFixed(2)} Mbps)`;\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA,OAAOA,WAAS,aAAa,aAAAC,YAAW,UAAAC,SAAQ,YAAAC,iBAAgB;AAChE,SAAS,eAAe,iBAAiB;AACzC,SAAS,kBAAkB,cAAc,sBAAAC,2BAA0B;AACnE,OAAO,gBAAgB;AACvB,SAAS,eAAe,gBAAgB,eAAe,mBAAmB;AAC1E,SAAS,YAAY,kBAAkB;;;ACLvC;AAAA,OAAO,SAAS,YAAY;AAC5B,SAAS,iBAAiB;AAKnB,SAAS,gBAAgB,EAAE,eAAe,QAAQ,GAAG;AAN5D;AAOE,SACE;AAAA,IAAC;AAAA;AAAA,MACC,KAAK;AAAA,QACH,UAAU;AAAA,QACV,OAAO;AAAA,QACP,YAAY;AAAA,QACZ,SAAS;AAAA,QACT,QAAQ;AAAA,QACR,iBAAiB;AAAA,QACjB,cAAc;AAAA,MAChB;AAAA,MACA,WAAU;AAAA;AAAA,IAEV,oCAAC,sBAAW,KAAK,EAAE,UAAU,YAAY,KAAK,MAAM,OAAO,KAAK,GAAG,SAAS,WAC1E,oCAAC,eAAU,CACb;AAAA,IACA,oCAAC,eAAY,OAAM,SACjB,oCAAC,QAAK,OAAM,YACV;AAAA,MAAC;AAAA;AAAA,QACC,OAAO,EAAE,QAAQ,WAAW,gBAAgB,YAAY;AAAA,QACxD,MAAM,+CAAe;AAAA,QACrB,QAAO;AAAA,QACP,KAAI;AAAA;AAAA,MACL;AAAA,IAED,CACF,CACF;AAAA,IACA,oCAAC,eAAY,OAAM,gBAChB,KAAI,oDAAe,cAAf,mBAA0B,KAAK,KAAI,oDAAe,cAAf,mBAA0B,MAAM,EAC1E;AAAA,IACA,oCAAC,eAAY,OAAM,sBAAmB,oD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AK,gBAAAA,QAAA,cAAC,gBAAW;AAAA;AAAA,MACpD,IACE,IACN,CACF,CACF;AAAA,IACF,IAEA,gBAAAA,QAAA,cAAC,QAAK,OAAM,UAAS,SAAQ,UAAS,KAAK,EAAE,MAAM,QAAQ,IAAI,MAAM,KACnE,gBAAAA,QAAA,cAAC,QAAK,SAAQ,MAAK,KAAK,EAAE,WAAW,SAAS,KAAG,oCAEjD,CACF;AAAA,EAEJ;AAEJ;AAEA,IAAO,kBAAQ;",
6
- "names": ["React", "useEffect", "useRef", "useState", "HMSHLSPlayerEvents", "React", "React", "React", "React", "React", "getDurationFromSeconds", "hlsPlayer", "videoProgress", "bufferProgress", "React", "React", "useEffect", "useState", "hlsPlayer", "useState", "useEffect", "getDurationFromSeconds", "React", "React", "useState", "hlsPlayer", "useState", "React", "volume", "React", "React", "React", "React", "React", "useState", "useState", "React", "useRef", "useState", "useEffect", "showLoader", "_a", "HMSHLSPlayerEvents", "React"]
7
- }