@stream-io/video-react-sdk 2.0.0-beta.0 → 2.0.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (328) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/dist/css/embedded.css +2592 -1498
  3. package/dist/css/embedded.css.map +1 -1
  4. package/dist/css/styles.css +2388 -1222
  5. package/dist/css/styles.css.map +1 -1
  6. package/dist/embedded.cjs.js +535 -476
  7. package/dist/embedded.cjs.js.map +1 -1
  8. package/dist/esm/index.js +10 -7
  9. package/dist/esm/index.js.map +1 -1
  10. package/dist/esm/src/components/Avatar/Avatar.js +13 -5
  11. package/dist/esm/src/components/Avatar/Avatar.js.map +1 -1
  12. package/dist/esm/src/components/Badge/Badge.js +21 -0
  13. package/dist/esm/src/components/Badge/Badge.js.map +1 -0
  14. package/dist/esm/src/components/Button/Button.js +10 -0
  15. package/dist/esm/src/components/Button/Button.js.map +1 -0
  16. package/dist/esm/src/components/Button/CompositeButton.js +10 -17
  17. package/dist/esm/src/components/Button/CompositeButton.js.map +1 -1
  18. package/dist/esm/src/components/Button/IconButton.js +3 -9
  19. package/dist/esm/src/components/Button/IconButton.js.map +1 -1
  20. package/dist/esm/src/components/CallControls/AcceptCallButton.js +3 -2
  21. package/dist/esm/src/components/CallControls/AcceptCallButton.js.map +1 -1
  22. package/dist/esm/src/components/CallControls/CallControls.js +3 -0
  23. package/dist/esm/src/components/CallControls/CallControls.js.map +1 -1
  24. package/dist/esm/src/components/CallControls/CancelCallButton.js +11 -6
  25. package/dist/esm/src/components/CallControls/CancelCallButton.js.map +1 -1
  26. package/dist/esm/src/components/CallControls/ReactionsButton.js +7 -3
  27. package/dist/esm/src/components/CallControls/ReactionsButton.js.map +1 -1
  28. package/dist/esm/src/components/CallControls/RecordCallButton.js +17 -11
  29. package/dist/esm/src/components/CallControls/RecordCallButton.js.map +1 -1
  30. package/dist/esm/src/components/CallControls/ScreenShareButton.js +11 -4
  31. package/dist/esm/src/components/CallControls/ScreenShareButton.js.map +1 -1
  32. package/dist/esm/src/components/CallControls/ToggleAudioButton.js +28 -17
  33. package/dist/esm/src/components/CallControls/ToggleAudioButton.js.map +1 -1
  34. package/dist/esm/src/components/CallControls/ToggleAudioOutputButton.js +9 -4
  35. package/dist/esm/src/components/CallControls/ToggleAudioOutputButton.js.map +1 -1
  36. package/dist/esm/src/components/CallControls/ToggleVideoButton.js +32 -23
  37. package/dist/esm/src/components/CallControls/ToggleVideoButton.js.map +1 -1
  38. package/dist/esm/src/components/CallParticipantsList/BlockedUserListing.js +3 -3
  39. package/dist/esm/src/components/CallParticipantsList/BlockedUserListing.js.map +1 -1
  40. package/dist/esm/src/components/CallParticipantsList/CallParticipantListHeader.js +8 -3
  41. package/dist/esm/src/components/CallParticipantsList/CallParticipantListHeader.js.map +1 -1
  42. package/dist/esm/src/components/CallParticipantsList/CallParticipantListingItem.js +20 -7
  43. package/dist/esm/src/components/CallParticipantsList/CallParticipantListingItem.js.map +1 -1
  44. package/dist/esm/src/components/CallParticipantsList/CallParticipantsList.js +8 -5
  45. package/dist/esm/src/components/CallParticipantsList/CallParticipantsList.js.map +1 -1
  46. package/dist/esm/src/components/CallParticipantsList/EmptyParticipantSearchList.js +5 -2
  47. package/dist/esm/src/components/CallParticipantsList/EmptyParticipantSearchList.js.map +1 -1
  48. package/dist/esm/src/components/CallRecordingList/CallRecordingListHeader.js +7 -3
  49. package/dist/esm/src/components/CallRecordingList/CallRecordingListHeader.js.map +1 -1
  50. package/dist/esm/src/components/DeviceSettings/DeviceAudioPreviewItem.js +1 -1
  51. package/dist/esm/src/components/DeviceSettings/DeviceAudioPreviewItem.js.map +1 -1
  52. package/dist/esm/src/components/DeviceSettings/DeviceSelector.js +1 -1
  53. package/dist/esm/src/components/DeviceSettings/DeviceSelector.js.map +1 -1
  54. package/dist/esm/src/components/DeviceSettings/DeviceSelectorAudio.js +2 -2
  55. package/dist/esm/src/components/DeviceSettings/DeviceSelectorAudio.js.map +1 -1
  56. package/dist/esm/src/components/DeviceSettings/DeviceSettings.js +8 -5
  57. package/dist/esm/src/components/DeviceSettings/DeviceSettings.js.map +1 -1
  58. package/dist/esm/src/components/DeviceSettings/SpeakerTest.js +10 -4
  59. package/dist/esm/src/components/DeviceSettings/SpeakerTest.js.map +1 -1
  60. package/dist/esm/src/components/DropdownSelect/DropdownSelect.js +1 -1
  61. package/dist/esm/src/components/DropdownSelect/DropdownSelect.js.map +1 -1
  62. package/dist/esm/src/components/Menu/GenericMenu.js +2 -1
  63. package/dist/esm/src/components/Menu/GenericMenu.js.map +1 -1
  64. package/dist/esm/src/components/Menu/MenuToggle.js +3 -0
  65. package/dist/esm/src/components/Menu/MenuToggle.js.map +1 -1
  66. package/dist/esm/src/components/Notification/MicCaptureErrorNotification.js +6 -3
  67. package/dist/esm/src/components/Notification/MicCaptureErrorNotification.js.map +1 -1
  68. package/dist/esm/src/components/Notification/Notification.js +12 -3
  69. package/dist/esm/src/components/Notification/Notification.js.map +1 -1
  70. package/dist/esm/src/components/Notification/PermissionNotification.js +2 -2
  71. package/dist/esm/src/components/Notification/PermissionNotification.js.map +1 -1
  72. package/dist/esm/src/components/Notification/RecordingInProgressNotification.js +7 -3
  73. package/dist/esm/src/components/Notification/RecordingInProgressNotification.js.map +1 -1
  74. package/dist/esm/src/components/Notification/SpeakingWhileMutedNotification.js +7 -2
  75. package/dist/esm/src/components/Notification/SpeakingWhileMutedNotification.js.map +1 -1
  76. package/dist/esm/src/components/Permissions/PermissionRequests.js +13 -12
  77. package/dist/esm/src/components/Permissions/PermissionRequests.js.map +1 -1
  78. package/dist/esm/src/components/RingingCall/RingingCall.js +38 -14
  79. package/dist/esm/src/components/RingingCall/RingingCall.js.map +1 -1
  80. package/dist/esm/src/components/RingingCall/RingingCallControls.js +7 -3
  81. package/dist/esm/src/components/RingingCall/RingingCallControls.js.map +1 -1
  82. package/dist/esm/src/components/Search/SearchInput.js +1 -1
  83. package/dist/esm/src/components/Search/SearchInput.js.map +1 -1
  84. package/dist/esm/src/components/StreamTheme/StreamTheme.js +2 -2
  85. package/dist/esm/src/components/StreamTheme/StreamTheme.js.map +1 -1
  86. package/dist/esm/src/components/Tooltip/Tooltip.js +8 -8
  87. package/dist/esm/src/components/Tooltip/Tooltip.js.map +1 -1
  88. package/dist/esm/src/components/VideoPreview/VideoPreview.js +36 -5
  89. package/dist/esm/src/components/VideoPreview/VideoPreview.js.map +1 -1
  90. package/dist/esm/src/core/components/CallLayout/LivestreamLayout.js +38 -12
  91. package/dist/esm/src/core/components/CallLayout/LivestreamLayout.js.map +1 -1
  92. package/dist/esm/src/core/components/CallLayout/PaginatedGridLayout.js +9 -5
  93. package/dist/esm/src/core/components/CallLayout/PaginatedGridLayout.js.map +1 -1
  94. package/dist/esm/src/core/components/CallLayout/PipLayout/Grid.js +9 -6
  95. package/dist/esm/src/core/components/CallLayout/PipLayout/Grid.js.map +1 -1
  96. package/dist/esm/src/core/components/CallLayout/PipLayout/Pip.js +9 -6
  97. package/dist/esm/src/core/components/CallLayout/PipLayout/Pip.js.map +1 -1
  98. package/dist/esm/src/core/components/CallLayout/SpeakerLayout.js +11 -6
  99. package/dist/esm/src/core/components/CallLayout/SpeakerLayout.js.map +1 -1
  100. package/dist/esm/src/core/components/ParticipantView/ConnectionQualityIndicator.js +25 -0
  101. package/dist/esm/src/core/components/ParticipantView/ConnectionQualityIndicator.js.map +1 -0
  102. package/dist/esm/src/core/components/ParticipantView/DefaultParticipantViewUI.js +17 -13
  103. package/dist/esm/src/core/components/ParticipantView/DefaultParticipantViewUI.js.map +1 -1
  104. package/dist/esm/src/core/components/ParticipantView/ParticipantActionsContextMenu.js +13 -8
  105. package/dist/esm/src/core/components/ParticipantView/ParticipantActionsContextMenu.js.map +1 -1
  106. package/dist/esm/src/core/components/StreamVideo/StreamVideo.js +24 -3
  107. package/dist/esm/src/core/components/StreamVideo/StreamVideo.js.map +1 -1
  108. package/dist/esm/src/core/components/Video/BaseVideoPlaceholder.js +3 -13
  109. package/dist/esm/src/core/components/Video/BaseVideoPlaceholder.js.map +1 -1
  110. package/dist/esm/src/core/components/Video/DefaultPictureInPicturePlaceholder.js +4 -2
  111. package/dist/esm/src/core/components/Video/DefaultPictureInPicturePlaceholder.js.map +1 -1
  112. package/dist/esm/src/core/components/Video/DefaultVideoPlaceholder.js +4 -2
  113. package/dist/esm/src/core/components/Video/DefaultVideoPlaceholder.js.map +1 -1
  114. package/dist/esm/src/embedded/EmbeddedClientProvider.js +7 -4
  115. package/dist/esm/src/embedded/EmbeddedClientProvider.js.map +1 -1
  116. package/dist/esm/src/embedded/call/CallControls.js +10 -6
  117. package/dist/esm/src/embedded/call/CallControls.js.map +1 -1
  118. package/dist/esm/src/embedded/call/CallHeader.js +10 -7
  119. package/dist/esm/src/embedded/call/CallHeader.js.map +1 -1
  120. package/dist/esm/src/embedded/call/CallLayout.js +8 -5
  121. package/dist/esm/src/embedded/call/CallLayout.js.map +1 -1
  122. package/dist/esm/src/embedded/call/CallStateRouter.js +7 -4
  123. package/dist/esm/src/embedded/call/CallStateRouter.js.map +1 -1
  124. package/dist/esm/src/embedded/hooks/useLayout.js +7 -4
  125. package/dist/esm/src/embedded/hooks/useLayout.js.map +1 -1
  126. package/dist/esm/src/embedded/livestream/host/HostLayout.js +12 -7
  127. package/dist/esm/src/embedded/livestream/host/HostLayout.js.map +1 -1
  128. package/dist/esm/src/embedded/livestream/host/HostStateRouter.js +12 -7
  129. package/dist/esm/src/embedded/livestream/host/HostStateRouter.js.map +1 -1
  130. package/dist/esm/src/embedded/livestream/viewer/ViewerLayout.js +9 -6
  131. package/dist/esm/src/embedded/livestream/viewer/ViewerLayout.js.map +1 -1
  132. package/dist/esm/src/embedded/livestream/viewer/ViewerLobby.js +12 -9
  133. package/dist/esm/src/embedded/livestream/viewer/ViewerLobby.js.map +1 -1
  134. package/dist/esm/src/embedded/livestream/viewer/ViewerStateRouter.js +7 -4
  135. package/dist/esm/src/embedded/livestream/viewer/ViewerStateRouter.js.map +1 -1
  136. package/dist/esm/src/embedded/shared/BlurToggleButton/BlurToggleButton.js +13 -9
  137. package/dist/esm/src/embedded/shared/BlurToggleButton/BlurToggleButton.js.map +1 -1
  138. package/dist/esm/src/embedded/shared/CallDuration/CallDuration.js +40 -0
  139. package/dist/esm/src/embedded/shared/CallDuration/CallDuration.js.map +1 -0
  140. package/dist/esm/src/embedded/shared/CallFeedback/CallEndedScreen.js +8 -6
  141. package/dist/esm/src/embedded/shared/CallFeedback/CallEndedScreen.js.map +1 -1
  142. package/dist/esm/src/embedded/shared/CallFeedback/RatingScreen.js +26 -2
  143. package/dist/esm/src/embedded/shared/CallFeedback/RatingScreen.js.map +1 -1
  144. package/dist/esm/src/embedded/shared/CallFeedback/StarRating.js +12 -6
  145. package/dist/esm/src/embedded/shared/CallFeedback/StarRating.js.map +1 -1
  146. package/dist/esm/src/embedded/shared/CallFeedback/ThankYouScreen.js +8 -6
  147. package/dist/esm/src/embedded/shared/CallFeedback/ThankYouScreen.js.map +1 -1
  148. package/dist/esm/src/embedded/shared/ConnectionNotification/ConnectionNotification.js +15 -14
  149. package/dist/esm/src/embedded/shared/ConnectionNotification/ConnectionNotification.js.map +1 -1
  150. package/dist/esm/src/embedded/shared/EmbeddedParticipantViewUI/EmbeddedParticipantViewUI.js +4 -0
  151. package/dist/esm/src/embedded/shared/EmbeddedParticipantViewUI/EmbeddedParticipantViewUI.js.map +1 -1
  152. package/dist/esm/src/embedded/shared/JoinError/JoinError.js +8 -6
  153. package/dist/esm/src/embedded/shared/JoinError/JoinError.js.map +1 -1
  154. package/dist/esm/src/embedded/shared/Lobby/DeviceControls.js +11 -7
  155. package/dist/esm/src/embedded/shared/Lobby/DeviceControls.js.map +1 -1
  156. package/dist/esm/src/embedded/shared/Lobby/DisabledDeviceButton.js +6 -4
  157. package/dist/esm/src/embedded/shared/Lobby/DisabledDeviceButton.js.map +1 -1
  158. package/dist/esm/src/embedded/shared/Lobby/Lobby.js +10 -9
  159. package/dist/esm/src/embedded/shared/Lobby/Lobby.js.map +1 -1
  160. package/dist/esm/src/embedded/shared/Lobby/ToggleCameraButton.js +6 -4
  161. package/dist/esm/src/embedded/shared/Lobby/ToggleCameraButton.js.map +1 -1
  162. package/dist/esm/src/embedded/shared/Lobby/ToggleMicButton.js +8 -6
  163. package/dist/esm/src/embedded/shared/Lobby/ToggleMicButton.js.map +1 -1
  164. package/dist/esm/src/embedded/shared/Lobby/VideoPreviewFallbacks.js +11 -9
  165. package/dist/esm/src/embedded/shared/Lobby/VideoPreviewFallbacks.js.map +1 -1
  166. package/dist/esm/src/embedded/shared/ViewersCount/ViewersCount.js +6 -4
  167. package/dist/esm/src/embedded/shared/ViewersCount/ViewersCount.js.map +1 -1
  168. package/dist/esm/src/hooks/useDeviceList.js +4 -2
  169. package/dist/esm/src/hooks/useDeviceList.js.map +1 -1
  170. package/dist/esm/src/i18n/Streami18n.js +58 -0
  171. package/dist/esm/src/i18n/Streami18n.js.map +1 -0
  172. package/dist/esm/src/i18n/TranslationContext.js +42 -0
  173. package/dist/esm/src/i18n/TranslationContext.js.map +1 -0
  174. package/dist/esm/src/i18n/runtimeDefaults.js +20 -0
  175. package/dist/esm/src/i18n/runtimeDefaults.js.map +1 -0
  176. package/dist/esm/src/i18n/useStreami18n.js +49 -0
  177. package/dist/esm/src/i18n/useStreami18n.js.map +1 -0
  178. package/dist/esm/src/wrappers/LivestreamPlayer/LivestreamPlayer.js +4 -0
  179. package/dist/esm/src/wrappers/LivestreamPlayer/LivestreamPlayer.js.map +1 -1
  180. package/dist/index.cjs.js +559 -623
  181. package/dist/index.cjs.js.map +1 -1
  182. package/dist/index.d.ts +1 -1
  183. package/dist/src/components/Avatar/Avatar.d.ts +9 -4
  184. package/dist/src/components/Badge/Badge.d.ts +23 -0
  185. package/dist/src/components/Badge/index.d.ts +1 -0
  186. package/dist/src/components/Button/Button.d.ts +16 -0
  187. package/dist/src/components/Button/CompositeButton.d.ts +6 -3
  188. package/dist/src/components/Button/IconButton.d.ts +7 -7
  189. package/dist/src/components/Button/index.d.ts +2 -2
  190. package/dist/src/components/CallControls/CancelCallButton.d.ts +3 -1
  191. package/dist/src/components/CallControls/ToggleAudioButton.d.ts +3 -3
  192. package/dist/src/components/CallControls/ToggleAudioOutputButton.d.ts +2 -2
  193. package/dist/src/components/CallControls/ToggleVideoButton.d.ts +3 -3
  194. package/dist/src/components/CallControls/index.d.ts +0 -1
  195. package/dist/src/components/Menu/GenericMenu.d.ts +1 -0
  196. package/dist/src/components/Notification/Notification.d.ts +2 -1
  197. package/dist/src/components/StreamTheme/StreamTheme.d.ts +2 -1
  198. package/dist/src/components/VideoPreview/VideoPreview.d.ts +6 -1
  199. package/dist/src/components/index.d.ts +1 -1
  200. package/dist/src/core/components/ParticipantView/ConnectionQualityIndicator.d.ts +10 -0
  201. package/dist/src/core/components/ParticipantView/index.d.ts +1 -0
  202. package/dist/src/core/components/StreamVideo/StreamVideo.d.ts +18 -2
  203. package/dist/src/embedded/shared/CallDuration/CallDuration.d.ts +9 -0
  204. package/dist/src/embedded/shared/index.d.ts +1 -0
  205. package/dist/src/i18n/Streami18n.d.ts +56 -0
  206. package/dist/src/i18n/TranslationContext.d.ts +30 -0
  207. package/dist/src/i18n/index.d.ts +16 -0
  208. package/dist/src/i18n/keys.d.ts +164 -0
  209. package/dist/src/i18n/runtimeDefaults.d.ts +17 -0
  210. package/dist/src/i18n/types.d.ts +45 -0
  211. package/dist/src/i18n/useStreami18n.d.ts +19 -0
  212. package/index.ts +1 -1
  213. package/package.json +18 -13
  214. package/src/components/Avatar/Avatar.tsx +53 -19
  215. package/src/components/Badge/Badge.tsx +48 -0
  216. package/src/components/Badge/index.ts +1 -0
  217. package/src/components/Button/Button.tsx +49 -0
  218. package/src/components/Button/CompositeButton.tsx +82 -73
  219. package/src/components/Button/IconButton.tsx +19 -29
  220. package/src/components/Button/index.ts +2 -2
  221. package/src/components/CallControls/AcceptCallButton.tsx +3 -1
  222. package/src/components/CallControls/CancelCallButton.tsx +32 -24
  223. package/src/components/CallControls/ReactionsButton.tsx +7 -3
  224. package/src/components/CallControls/RecordCallButton.tsx +50 -23
  225. package/src/components/CallControls/ScreenShareButton.tsx +27 -6
  226. package/src/components/CallControls/ToggleAudioButton.tsx +62 -61
  227. package/src/components/CallControls/ToggleAudioOutputButton.tsx +7 -4
  228. package/src/components/CallControls/ToggleVideoButton.tsx +66 -66
  229. package/src/components/CallControls/index.ts +0 -1
  230. package/src/components/CallParticipantsList/BlockedUserListing.tsx +9 -2
  231. package/src/components/CallParticipantsList/CallParticipantListHeader.tsx +10 -3
  232. package/src/components/CallParticipantsList/CallParticipantListingItem.tsx +33 -8
  233. package/src/components/CallParticipantsList/CallParticipantsList.tsx +21 -5
  234. package/src/components/CallParticipantsList/EmptyParticipantSearchList.tsx +2 -2
  235. package/src/components/CallRecordingList/CallRecordingListHeader.tsx +11 -3
  236. package/src/components/DeviceSettings/DeviceAudioPreviewItem.tsx +3 -1
  237. package/src/components/DeviceSettings/DeviceSelector.tsx +1 -1
  238. package/src/components/DeviceSettings/DeviceSelectorAudio.tsx +2 -7
  239. package/src/components/DeviceSettings/DeviceSettings.tsx +14 -5
  240. package/src/components/DeviceSettings/SpeakerTest.tsx +7 -2
  241. package/src/components/DropdownSelect/DropdownSelect.tsx +3 -1
  242. package/src/components/Menu/GenericMenu.tsx +4 -0
  243. package/src/components/Notification/MicCaptureErrorNotification.tsx +7 -2
  244. package/src/components/Notification/Notification.tsx +20 -4
  245. package/src/components/Notification/PermissionNotification.tsx +2 -0
  246. package/src/components/Notification/RecordingInProgressNotification.tsx +5 -6
  247. package/src/components/Notification/SpeakingWhileMutedNotification.tsx +8 -2
  248. package/src/components/Permissions/PermissionRequests.tsx +50 -43
  249. package/src/components/RingingCall/RingingCall.tsx +40 -14
  250. package/src/components/RingingCall/RingingCallControls.tsx +2 -1
  251. package/src/components/Search/SearchInput.tsx +2 -3
  252. package/src/components/StreamTheme/StreamTheme.tsx +3 -1
  253. package/src/components/Tooltip/Tooltip.tsx +3 -10
  254. package/src/components/VideoPreview/VideoPreview.tsx +50 -5
  255. package/src/components/index.ts +1 -1
  256. package/src/core/components/CallLayout/LivestreamLayout.tsx +48 -18
  257. package/src/core/components/CallLayout/PaginatedGridLayout.tsx +14 -0
  258. package/src/core/components/CallLayout/PipLayout/Grid.tsx +10 -2
  259. package/src/core/components/CallLayout/PipLayout/Pip.tsx +6 -2
  260. package/src/core/components/CallLayout/SpeakerLayout.tsx +27 -0
  261. package/src/core/components/CallLayout/partcipantFilter.test.ts +38 -31
  262. package/src/core/components/ParticipantView/ConnectionQualityIndicator.tsx +54 -0
  263. package/src/core/components/ParticipantView/DefaultParticipantViewUI.tsx +60 -27
  264. package/src/core/components/ParticipantView/ParticipantActionsContextMenu.tsx +63 -22
  265. package/src/core/components/ParticipantView/index.ts +1 -0
  266. package/src/core/components/StreamVideo/StreamVideo.tsx +39 -4
  267. package/src/core/components/Video/BaseVideoPlaceholder.tsx +13 -30
  268. package/src/core/components/Video/DefaultPictureInPicturePlaceholder.tsx +5 -2
  269. package/src/core/components/Video/DefaultVideoPlaceholder.tsx +2 -2
  270. package/src/embedded/call/CallControls.tsx +9 -18
  271. package/src/embedded/call/CallHeader.tsx +3 -12
  272. package/src/embedded/call/CallLayout.tsx +1 -1
  273. package/src/embedded/livestream/host/HostLayout.tsx +26 -20
  274. package/src/embedded/livestream/host/HostStateRouter.tsx +12 -8
  275. package/src/embedded/livestream/viewer/ViewerLayout.tsx +8 -11
  276. package/src/embedded/livestream/viewer/ViewerLobby.tsx +31 -15
  277. package/src/embedded/shared/BlurToggleButton/BlurToggleButton.tsx +18 -12
  278. package/src/embedded/shared/CallDuration/CallDuration.tsx +32 -0
  279. package/src/embedded/shared/CallFeedback/CallEndedScreen.tsx +27 -13
  280. package/src/embedded/shared/CallFeedback/RatingScreen.tsx +20 -12
  281. package/src/embedded/shared/CallFeedback/StarRating.tsx +10 -3
  282. package/src/embedded/shared/CallFeedback/ThankYouScreen.tsx +6 -3
  283. package/src/embedded/shared/ConnectionNotification/ConnectionNotification.tsx +21 -14
  284. package/src/embedded/shared/JoinError/JoinError.tsx +7 -6
  285. package/src/embedded/shared/Lobby/DeviceControls.tsx +25 -3
  286. package/src/embedded/shared/Lobby/Lobby.tsx +19 -22
  287. package/src/embedded/shared/Lobby/ToggleMicButton.tsx +10 -3
  288. package/src/embedded/shared/Lobby/VideoPreviewFallbacks.tsx +4 -2
  289. package/src/embedded/shared/index.ts +1 -0
  290. package/src/hooks/useDeviceList.tsx +2 -2
  291. package/src/i18n/Streami18n.ts +67 -0
  292. package/src/i18n/TranslationContext.tsx +55 -0
  293. package/src/i18n/index.ts +22 -0
  294. package/src/i18n/keys.ts +169 -0
  295. package/src/i18n/runtimeDefaults.ts +17 -0
  296. package/src/i18n/types.ts +78 -0
  297. package/src/i18n/useStreami18n.ts +66 -0
  298. package/src/utilities/filter.test.ts +132 -124
  299. package/src/utilities/normalizeString.test.ts +50 -48
  300. package/dist/embedded-CallStatsLatencyChart-CpL1M_s0.cjs.js +0 -59
  301. package/dist/embedded-CallStatsLatencyChart-CpL1M_s0.cjs.js.map +0 -1
  302. package/dist/esm/src/components/Button/TextButton.js +0 -8
  303. package/dist/esm/src/components/Button/TextButton.js.map +0 -1
  304. package/dist/esm/src/components/CallControls/CallStatsButton.js +0 -18
  305. package/dist/esm/src/components/CallControls/CallStatsButton.js.map +0 -1
  306. package/dist/esm/src/components/CallStats/CallStats.js +0 -180
  307. package/dist/esm/src/components/CallStats/CallStats.js.map +0 -1
  308. package/dist/esm/src/components/CallStats/CallStatsLatencyChart.js +0 -57
  309. package/dist/esm/src/components/CallStats/CallStatsLatencyChart.js.map +0 -1
  310. package/dist/esm/src/translations/en.json.js +0 -177
  311. package/dist/esm/src/translations/en.json.js.map +0 -1
  312. package/dist/esm/src/translations/index.js +0 -6
  313. package/dist/esm/src/translations/index.js.map +0 -1
  314. package/dist/latency-chart-CpL1M_s0.cjs.js +0 -59
  315. package/dist/latency-chart-CpL1M_s0.cjs.js.map +0 -1
  316. package/dist/src/components/Button/TextButton.d.ts +0 -2
  317. package/dist/src/components/CallControls/CallStatsButton.d.ts +0 -4
  318. package/dist/src/components/CallStats/CallStats.d.ts +0 -22
  319. package/dist/src/components/CallStats/CallStatsLatencyChart.d.ts +0 -7
  320. package/dist/src/components/CallStats/index.d.ts +0 -1
  321. package/dist/src/translations/index.d.ts +0 -146
  322. package/src/components/Button/TextButton.tsx +0 -12
  323. package/src/components/CallControls/CallStatsButton.tsx +0 -37
  324. package/src/components/CallStats/CallStats.tsx +0 -439
  325. package/src/components/CallStats/CallStatsLatencyChart.tsx +0 -76
  326. package/src/components/CallStats/index.ts +0 -1
  327. package/src/translations/en.json +0 -154
  328. package/src/translations/index.ts +0 -3
@@ -1,16 +1,17 @@
1
1
  import {
2
2
  Restricted,
3
3
  useCallStateHooks,
4
- useI18n,
5
4
  UseInputMediaDeviceOptions,
6
5
  } from '@stream-io/video-react-bindings';
6
+ import { useI18n } from '../../i18n';
7
7
  import clsx from 'clsx';
8
8
  import {
9
9
  OwnCapability,
10
10
  RequestPermissionRequestPermissionsEnum,
11
11
  SfuModels,
12
12
  } from '@stream-io/video-client';
13
- import { CompositeButton, IconButtonWithMenuProps } from '../Button/';
13
+ import { Badge } from '../Badge';
14
+ import { CompositeButton, CompositeButtonProps } from '../Button/';
14
15
  import { DeviceSelectorVideo } from '../DeviceSettings';
15
16
  import { PermissionNotification } from '../Notification';
16
17
  import { useRequestPermission } from '../../hooks';
@@ -24,7 +25,7 @@ import {
24
25
 
25
26
  export type ToggleVideoPreviewButtonProps = PropsWithErrorHandler<
26
27
  Pick<
27
- IconButtonWithMenuProps,
28
+ CompositeButtonProps,
28
29
  'caption' | 'Menu' | 'menuPlacement' | 'onMenuToggle'
29
30
  > &
30
31
  UseInputMediaDeviceOptions
@@ -60,11 +61,20 @@ export const ToggleVideoPreviewButton = (
60
61
  return (
61
62
  <WithTooltip
62
63
  title={
63
- !hasBrowserPermission
64
- ? t('Check your browser video permissions')
65
- : isSystemMuted
66
- ? t('Camera is paused by your system')
67
- : (caption ?? t('Video'))
64
+ isPromptingPermission
65
+ ? t('common.waitingForPermission.title', 'Waiting for permission')
66
+ : !hasBrowserPermission
67
+ ? t(
68
+ 'callControls.toggleVideoButton.checkBrowserVideoPermissions.title',
69
+ 'Check your browser video permissions',
70
+ )
71
+ : isSystemMuted
72
+ ? t(
73
+ 'callControls.toggleVideoButton.cameraPausedBySystem.title',
74
+ 'Camera is paused by your system',
75
+ )
76
+ : (caption ??
77
+ t('callControls.toggleVideoButton.video.title', 'Video'))
68
78
  }
69
79
  tooltipDisabled={tooltipDisabled}
70
80
  >
@@ -74,7 +84,7 @@ export const ToggleVideoPreviewButton = (
74
84
  className={clsx(
75
85
  !hasBrowserPermission && 'str-video__device-unavailable',
76
86
  )}
77
- variant="secondary"
87
+ variant={optionsAwareIsMute ? 'destructive' : 'secondary'}
78
88
  data-testid={
79
89
  optionsAwareIsMute
80
90
  ? 'preview-video-unmute-button'
@@ -93,27 +103,11 @@ export const ToggleVideoPreviewButton = (
93
103
  }}
94
104
  >
95
105
  <Icon icon={!optionsAwareIsMute ? 'camera' : 'camera-off'} />
96
- {!hasBrowserPermission && (
97
- <span
98
- className="str-video__no-media-permission"
99
- title={t('Check your browser video permissions')}
100
- children="!"
101
- />
102
- )}
103
- {isPromptingPermission && (
104
- <span
105
- className="str-video__pending-permission"
106
- title={t('Waiting for permission')}
107
- children="?"
108
- />
109
- )}
110
- {isSystemMuted && hasBrowserPermission && (
111
- <span
112
- className="str-video__system-muted"
113
- title={t('Camera is paused by your system')}
114
- children="!"
115
- />
116
- )}
106
+ {isPromptingPermission ? (
107
+ <Badge variant="error" icon="question-mark-fill" />
108
+ ) : !hasBrowserPermission || isSystemMuted ? (
109
+ <Badge variant="error" icon="exclamation-mark-fill" />
110
+ ) : null}
117
111
  </CompositeButton>
118
112
  </WithTooltip>
119
113
  );
@@ -121,7 +115,7 @@ export const ToggleVideoPreviewButton = (
121
115
 
122
116
  type ToggleVideoPublishingButtonProps = PropsWithErrorHandler<
123
117
  Pick<
124
- IconButtonWithMenuProps,
118
+ CompositeButtonProps,
125
119
  'caption' | 'Menu' | 'menuPlacement' | 'onMenuToggle'
126
120
  > &
127
121
  UseInputMediaDeviceOptions
@@ -172,30 +166,52 @@ export const ToggleVideoPublishingButton = (
172
166
  <PermissionNotification
173
167
  permission={OwnCapability.SEND_VIDEO}
174
168
  isAwaitingApproval={isAwaitingPermission}
175
- messageApproved={t('You can now share your video.')}
169
+ messageApproved={t(
170
+ 'callControls.toggleVideoButton.permissionGranted.text',
171
+ 'You can now share your video.',
172
+ )}
176
173
  messageAwaitingApproval={t(
174
+ 'callControls.toggleVideoButton.awaitingApproval.text',
177
175
  'Awaiting for an approval to share your video.',
178
176
  )}
179
- messageRevoked={t('You can no longer share your video.')}
177
+ messageRevoked={t(
178
+ 'callControls.toggleVideoButton.permissionRevoked.text',
179
+ 'You can no longer share your video.',
180
+ )}
180
181
  >
181
182
  <WithTooltip
182
183
  title={
183
- !hasPermission
184
- ? t('You have no permission to share your video')
185
- : !hasBrowserPermission
186
- ? t('Check your browser video permissions')
187
- : !isPublishingVideoAllowed
188
- ? t('Video publishing is disabled by the system')
189
- : isSystemMuted
190
- ? t('Camera is paused by your system')
191
- : caption || t('Video')
184
+ isPromptingPermission
185
+ ? t('common.waitingForPermission.title', 'Waiting for permission')
186
+ : !hasPermission
187
+ ? t(
188
+ 'callControls.toggleVideoButton.noPermissionToShareVideo.title',
189
+ 'You have no permission to share your video',
190
+ )
191
+ : !hasBrowserPermission
192
+ ? t(
193
+ 'callControls.toggleVideoButton.checkBrowserVideoPermissions.title',
194
+ 'Check your browser video permissions',
195
+ )
196
+ : !isPublishingVideoAllowed
197
+ ? t(
198
+ 'callControls.toggleVideoButton.videoPublishingDisabled.title',
199
+ 'Video publishing is disabled by the system',
200
+ )
201
+ : isSystemMuted
202
+ ? t(
203
+ 'callControls.toggleVideoButton.cameraPausedBySystem.title',
204
+ 'Camera is paused by your system',
205
+ )
206
+ : caption ||
207
+ t('callControls.toggleVideoButton.video.title', 'Video')
192
208
  }
193
209
  tooltipDisabled={tooltipDisabled}
194
210
  >
195
211
  <CompositeButton
196
212
  active={optionsAwareIsMute}
197
213
  caption={caption}
198
- variant="secondary"
214
+ variant={optionsAwareIsMute ? 'destructive' : 'secondary'}
199
215
  disabled={
200
216
  !hasBrowserPermission ||
201
217
  !hasPermission ||
@@ -216,30 +232,14 @@ export const ToggleVideoPublishingButton = (
216
232
  }}
217
233
  >
218
234
  <Icon icon={optionsAwareIsMute ? 'camera-off' : 'camera'} />
219
- {(!hasBrowserPermission ||
235
+ {isPromptingPermission ? (
236
+ <Badge variant="error" icon="question-mark-fill" />
237
+ ) : !hasBrowserPermission ||
220
238
  !hasPermission ||
221
- !isPublishingVideoAllowed) && (
222
- <span className="str-video__no-media-permission">!</span>
223
- )}
224
- {isPromptingPermission && (
225
- <span
226
- className="str-video__pending-permission"
227
- title={t('Waiting for permission')}
228
- >
229
- ?
230
- </span>
231
- )}
232
- {isSystemMuted &&
233
- hasBrowserPermission &&
234
- hasPermission &&
235
- isPublishingVideoAllowed && (
236
- <span
237
- className="str-video__system-muted"
238
- title={t('Camera is paused by your system')}
239
- >
240
- !
241
- </span>
242
- )}
239
+ !isPublishingVideoAllowed ||
240
+ isSystemMuted ? (
241
+ <Badge variant="error" icon="exclamation-mark-fill" />
242
+ ) : null}
243
243
  </CompositeButton>
244
244
  </WithTooltip>
245
245
  </PermissionNotification>
@@ -1,6 +1,5 @@
1
1
  export * from './AcceptCallButton';
2
2
  export * from './CallControls';
3
- export * from './CallStatsButton';
4
3
  export * from './CancelCallButton';
5
4
  export * from './ReactionsButton';
6
5
  export * from './RecordCallButton';
@@ -1,7 +1,7 @@
1
1
  import { Restricted, useCall } from '@stream-io/video-react-bindings';
2
2
  import { OwnCapability } from '@stream-io/video-client';
3
3
 
4
- import { TextButton } from '../Button';
4
+ import { Button } from '../Button';
5
5
 
6
6
  export const BlockedUserListing = ({ data }: { data: string[] }) => {
7
7
  if (!data.length) return null;
@@ -30,7 +30,14 @@ const BlockedUserListingItem = ({ userId }: { userId: string }) => {
30
30
  {userId}
31
31
  </div>
32
32
  <Restricted requiredGrants={[OwnCapability.BLOCK_USERS]}>
33
- <TextButton onClick={unblockUserClickHandler}>Unblock</TextButton>
33
+ <Button
34
+ appearance="ghost"
35
+ size="xs"
36
+ variant="secondary"
37
+ onClick={unblockUserClickHandler}
38
+ >
39
+ Unblock
40
+ </Button>
34
41
  </Restricted>
35
42
  </div>
36
43
  );
@@ -1,4 +1,5 @@
1
- import { useCallStateHooks, useI18n } from '@stream-io/video-react-bindings';
1
+ import { useCallStateHooks } from '@stream-io/video-react-bindings';
2
+ import { useI18n } from '../../i18n';
2
3
 
3
4
  import { IconButton } from '../Button';
4
5
 
@@ -20,17 +21,23 @@ export const CallParticipantListHeader = ({
20
21
  return (
21
22
  <div className="str-video__participant-list-header">
22
23
  <div className="str-video__participant-list-header__title">
23
- {t('Participants')}{' '}
24
+ {t('common.participants.label', 'Participants')}{' '}
24
25
  <span className="str-video__participant-list-header__title-count">
25
26
  [{participants.length}]
26
27
  </span>
27
28
  {anonymousParticipantCount > 0 && (
28
29
  <span className="str-video__participant-list-header__title-anonymous">
29
- {t('Anonymous', { count: anonymousParticipantCount })}
30
+ {t(
31
+ 'participantList.anonymousCount.text',
32
+ ', and ({{ anonymousCount }}) anonymous',
33
+ { anonymousCount: anonymousParticipantCount },
34
+ )}
30
35
  </span>
31
36
  )}
32
37
  </div>
33
38
  <IconButton
39
+ size="sm"
40
+ variant="secondary"
34
41
  onClick={onClose}
35
42
  className="str-video__participant-list-header__close-button"
36
43
  icon="close"
@@ -1,6 +1,7 @@
1
1
  import clsx from 'clsx';
2
2
  import { ComponentProps, ComponentType, forwardRef, memo } from 'react';
3
- import { useConnectedUser, useI18n } from '@stream-io/video-react-bindings';
3
+ import { useConnectedUser } from '@stream-io/video-react-bindings';
4
+ import { useI18n } from '../../i18n';
4
5
  import {
5
6
  hasAudio,
6
7
  hasVideo,
@@ -37,7 +38,11 @@ export const CallParticipantListingItem = memo(
37
38
  <DisplayName participant={participant} />
38
39
  <div className="str-video__participant-listing-item__media-indicator-group">
39
40
  <MediaIndicator
40
- title={isAudioOn ? t('Microphone on') : t('Microphone off')}
41
+ title={
42
+ isAudioOn
43
+ ? t('participantList.microphoneOn.title', 'Microphone on')
44
+ : t('participantList.microphoneOff.title', 'Microphone off')
45
+ }
41
46
  className={clsx(
42
47
  'str-video__participant-listing-item__icon',
43
48
  `str-video__participant-listing-item__icon-${
@@ -46,7 +51,11 @@ export const CallParticipantListingItem = memo(
46
51
  )}
47
52
  />
48
53
  <MediaIndicator
49
- title={isVideoOn ? t('Camera on') : t('Camera off')}
54
+ title={
55
+ isVideoOn
56
+ ? t('participantList.cameraOn.title', 'Camera on')
57
+ : t('participantList.cameraOff.title', 'Camera off')
58
+ }
50
59
  className={clsx(
51
60
  'str-video__participant-listing-item__icon',
52
61
  `str-video__participant-listing-item__icon-${
@@ -56,7 +65,7 @@ export const CallParticipantListingItem = memo(
56
65
  />
57
66
  {isPinnedOn && (
58
67
  <MediaIndicator
59
- title={t('Pinned')}
68
+ title={t('participantList.pinned.title', 'Pinned')}
60
69
  className={clsx(
61
70
  'str-video__participant-listing-item__icon',
62
71
  'str-video__participant-listing-item__icon-pinned',
@@ -92,11 +101,18 @@ const DefaultDisplayName = ({ participant }: DisplayNameProps) => {
92
101
  const connectedUser = useConnectedUser();
93
102
  const { t } = useI18n();
94
103
 
95
- const meFlag = participant.userId === connectedUser?.id ? t('Me') : '';
96
- const nameOrId = participant.name || participant.userId || t('Unknown');
104
+ const meFlag =
105
+ participant.userId === connectedUser?.id
106
+ ? t('participantList.me.text', 'Me')
107
+ : '';
108
+ const nameOrId =
109
+ participant.name ||
110
+ participant.userId ||
111
+ t('participantList.unknown.text', 'Unknown');
97
112
  let displayName;
98
113
  if (!participant.name) {
99
- displayName = meFlag || nameOrId || t('Unknown');
114
+ displayName =
115
+ meFlag || nameOrId || t('participantList.unknown.text', 'Unknown');
100
116
  } else if (meFlag) {
101
117
  displayName = `${nameOrId} (${meFlag})`;
102
118
  } else {
@@ -115,6 +131,15 @@ const DefaultDisplayName = ({ participant }: DisplayNameProps) => {
115
131
 
116
132
  const ToggleButton = forwardRef<HTMLButtonElement, ToggleMenuButtonProps>(
117
133
  function ToggleButtonRender(props, ref) {
118
- return <IconButton enabled={props.menuShown} icon="ellipsis" ref={ref} />;
134
+ return (
135
+ <IconButton
136
+ className="str-video__participant-listing-item__menu-button"
137
+ active={props.menuShown}
138
+ size="sm"
139
+ variant="secondary"
140
+ ref={ref}
141
+ icon="ellipsis"
142
+ />
143
+ );
119
144
  },
120
145
  );
@@ -10,8 +10,8 @@ import {
10
10
  Restricted,
11
11
  useCall,
12
12
  useCallStateHooks,
13
- useI18n,
14
13
  } from '@stream-io/video-react-bindings';
14
+ import { useI18n } from '../../i18n';
15
15
  import {
16
16
  name,
17
17
  OwnCapability,
@@ -19,7 +19,7 @@ import {
19
19
  } from '@stream-io/video-client';
20
20
 
21
21
  import { BlockedUserListing } from './BlockedUserListing';
22
- import { IconButton, TextButton } from '../Button';
22
+ import { Button, IconButton } from '../Button';
23
23
  import { CallParticipantListHeader } from './CallParticipantListHeader';
24
24
  import { CallParticipantListing } from './CallParticipantListing';
25
25
  import { EmptyParticipantSearchList } from './EmptyParticipantSearchList';
@@ -117,7 +117,14 @@ const CallParticipantListContentHeader = ({
117
117
  requiredGrants={[OwnCapability.MUTE_USERS]}
118
118
  hasPermissionsOnly
119
119
  >
120
- <TextButton onClick={muteAll}>{t('Mute all')}</TextButton>
120
+ <Button
121
+ appearance="ghost"
122
+ size="xs"
123
+ variant="secondary"
124
+ onClick={muteAll}
125
+ >
126
+ {t('participantList.muteAll.label', 'Mute all')}
127
+ </Button>
121
128
  </Restricted>
122
129
  )}
123
130
  </div>
@@ -128,7 +135,7 @@ const CallParticipantListContentHeader = ({
128
135
  ).map((lt) => (
129
136
  <GenericMenuButtonItem
130
137
  key={lt}
131
- aria-selected={lt === userListType}
138
+ aria-current={lt === userListType}
132
139
  onClick={() => setUserListType(lt)}
133
140
  >
134
141
  {UserListTypes[lt]}
@@ -227,6 +234,15 @@ const BlockedUsersSearchResults = ({
227
234
 
228
235
  const ToggleButton = forwardRef<HTMLButtonElement, ToggleMenuButtonProps>(
229
236
  function ToggleButtonRender(props, ref) {
230
- return <IconButton enabled={props.menuShown} icon="filter" ref={ref} />;
237
+ return (
238
+ <IconButton
239
+ className="str-video__participant-list__filter-button"
240
+ active={props.menuShown}
241
+ size="sm"
242
+ variant="secondary"
243
+ ref={ref}
244
+ icon="filter"
245
+ />
246
+ );
231
247
  },
232
248
  );
@@ -1,10 +1,10 @@
1
- import { useI18n } from '@stream-io/video-react-bindings';
1
+ import { useI18n } from '../../i18n';
2
2
 
3
3
  export const EmptyParticipantSearchList = () => {
4
4
  const { t } = useI18n();
5
5
  return (
6
6
  <div className="str-video__participant-list--empty">
7
- {t('No participants found')}
7
+ {t('participantList.noParticipantsFound.text', 'No participants found')}
8
8
  </div>
9
9
  );
10
10
  };
@@ -1,5 +1,5 @@
1
1
  import { CallRecording } from '@stream-io/video-client';
2
- import { useI18n } from '@stream-io/video-react-bindings';
2
+ import { useI18n } from '../../i18n';
3
3
  import { IconButton } from '../Button';
4
4
 
5
5
  export type CallRecordingListHeaderProps = {
@@ -17,11 +17,19 @@ export const CallRecordingListHeader = ({
17
17
  return (
18
18
  <div className="str-video__call-recording-list__header">
19
19
  <div className="str-video__call-recording-list__title">
20
- <span>{t('Call Recordings')}</span>
20
+ <span>
21
+ {t('callRecordingList.callRecordings.title', 'Call Recordings')}
22
+ </span>
21
23
  {callRecordings.length ? <span>({callRecordings.length})</span> : null}
22
24
  </div>
23
25
  {onRefresh && (
24
- <IconButton icon="refresh" title={t('Refresh')} onClick={onRefresh} />
26
+ <IconButton
27
+ size="sm"
28
+ variant="secondary"
29
+ title={t('callRecordingList.refresh.title', 'Refresh')}
30
+ onClick={onRefresh}
31
+ icon="refresh"
32
+ />
25
33
  )}
26
34
  </div>
27
35
  );
@@ -76,7 +76,9 @@ export const DeviceAudioPreviewItem = ({
76
76
  checked={device.isSelected}
77
77
  onChange={(e) => onSelect(e.target.value)}
78
78
  />
79
- {device.label}
79
+ <span className="str-video__device-settings__option__label">
80
+ {device.label}
81
+ </span>
80
82
  <DeviceLevelIndicator deviceId={device.deviceId} />
81
83
  </label>
82
84
  );
@@ -49,7 +49,7 @@ const DeviceSelectorOption = ({
49
49
  defaultChecked={defaultChecked}
50
50
  disabled={disabled}
51
51
  />
52
- {label}
52
+ <span className="str-video__device-settings__option__label">{label}</span>
53
53
  </label>
54
54
  );
55
55
  };
@@ -33,8 +33,8 @@ export const DeviceSelectorAudioInput = ({
33
33
  >
34
34
  {volumeIndicatorVisible && (
35
35
  <>
36
- <hr className="str-video__device-settings__separator" />
37
36
  <AudioVolumeIndicator />
37
+ <hr className="str-video__device-settings__separator" />
38
38
  </>
39
39
  )}
40
40
  </DeviceSelector>
@@ -72,12 +72,7 @@ export const DeviceSelectorAudioOutput = ({
72
72
  visualType={visualType}
73
73
  icon="speaker"
74
74
  >
75
- {speakerTestVisible && (
76
- <>
77
- <hr className="str-video__device-settings__separator" />
78
- <SpeakerTest audioUrl={speakerTestAudioUrl} />
79
- </>
80
- )}
75
+ {speakerTestVisible && <SpeakerTest audioUrl={speakerTestAudioUrl} />}
81
76
  </DeviceSelector>
82
77
  );
83
78
  };
@@ -1,5 +1,5 @@
1
1
  import { forwardRef } from 'react';
2
- import { useI18n } from '@stream-io/video-react-bindings';
2
+ import { useI18n } from '../../i18n';
3
3
  import clsx from 'clsx';
4
4
  import { MenuToggle, MenuVisualType, ToggleMenuButtonProps } from '../Menu';
5
5
  import {
@@ -31,9 +31,15 @@ const Menu = () => {
31
31
  const { t } = useI18n();
32
32
  return (
33
33
  <div className="str-video__device-settings">
34
- <DeviceSelectorVideo title={t('Select a Camera')} />
35
- <DeviceSelectorAudioInput title={t('Select a Mic')} />
36
- <DeviceSelectorAudioOutput title={t('Select Speakers')} />
34
+ <DeviceSelectorVideo
35
+ title={t('deviceSettings.selectCamera.title', 'Select a Camera')}
36
+ />
37
+ <DeviceSelectorAudioInput
38
+ title={t('deviceSettings.selectMic.title', 'Select a Mic')}
39
+ />
40
+ <DeviceSelectorAudioOutput
41
+ title={t('deviceSettings.selectSpeakers.title', 'Select Speakers')}
42
+ />
37
43
  </div>
38
44
  );
39
45
  };
@@ -45,10 +51,13 @@ const ToggleDeviceSettingsMenuButton = forwardRef<
45
51
  const { t } = useI18n();
46
52
  return (
47
53
  <IconButton
54
+ active={menuShown}
55
+ size="sm"
56
+ variant="secondary"
48
57
  className={clsx('str-video__device-settings__button', {
49
58
  'str-video__device-settings__button--active': menuShown,
50
59
  })}
51
- title={t('Toggle device menu')}
60
+ title={t('deviceSettings.toggleDeviceMenu.title', 'Toggle device menu')}
52
61
  icon="device-settings"
53
62
  ref={ref}
54
63
  />
@@ -1,5 +1,6 @@
1
1
  import { useCallback, useEffect, useRef, useState } from 'react';
2
- import { useCallStateHooks, useI18n } from '@stream-io/video-react-bindings';
2
+ import { useCallStateHooks } from '@stream-io/video-react-bindings';
3
+ import { useI18n } from '../../i18n';
3
4
  import { CompositeButton } from '../Button';
4
5
  import { Icon } from '../Icon';
5
6
 
@@ -62,12 +63,16 @@ export const SpeakerTest = (props: { audioUrl?: string }) => {
62
63
  />
63
64
  <CompositeButton
64
65
  className="str-video__speaker-test__button"
66
+ appearance="outline"
67
+ size="sm"
65
68
  onClick={handleStartTest}
66
69
  type="button"
67
70
  >
68
71
  <div className="str-video__speaker-test__button-content">
69
72
  <Icon icon="speaker" />
70
- {isPlaying ? t('Stop test') : t('Test speaker')}
73
+ {isPlaying
74
+ ? t('deviceSettings.speakerTest.stopTest.label', 'Stop test')
75
+ : t('deviceSettings.speakerTest.testSpeaker.label', 'Test speaker')}
71
76
  </div>
72
77
  </CompositeButton>
73
78
  </div>
@@ -133,7 +133,9 @@ const Select = (props: {
133
133
  {icon && (
134
134
  <Icon className="str-video__dropdown-selected__icon" icon={icon} />
135
135
  )}
136
- {selectedLabel}
136
+ <span className="str-video__dropdown-selected__text">
137
+ {selectedLabel}
138
+ </span>
137
139
  </label>
138
140
  <Icon
139
141
  className="str-video__dropdown-selected__chevron"
@@ -36,3 +36,7 @@ export const GenericMenuButtonItem = ({
36
36
  </li>
37
37
  );
38
38
  };
39
+
40
+ export const GenericMenuSeparator = () => (
41
+ <li className="str-video__generic-menu--separator" role="separator" />
42
+ );
@@ -1,6 +1,7 @@
1
1
  import { PropsWithChildren, useEffect, useState } from 'react';
2
2
  import { Placement } from '@floating-ui/react';
3
- import { useCall, useI18n } from '@stream-io/video-react-bindings';
3
+ import { useCall } from '@stream-io/video-react-bindings';
4
+ import { useI18n } from '../../i18n';
4
5
  import { Notification } from './Notification';
5
6
 
6
7
  export type MicCaptureErrorNotificationProps = {
@@ -28,11 +29,15 @@ export const MicCaptureErrorNotification = ({
28
29
 
29
30
  const message =
30
31
  text ??
31
- t('Your microphone is not capturing audio. Please check your setup.');
32
+ t(
33
+ 'notification.micCaptureError.text',
34
+ 'Your microphone is not capturing audio. Please check your setup.',
35
+ );
32
36
 
33
37
  return (
34
38
  <Notification
35
39
  message={message}
40
+ state="error"
36
41
  isVisible={isVisible}
37
42
  placement={placement}
38
43
  close={() => setIsVisible(false)}