@stream-io/video-react-native-sdk 1.3.7 → 1.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (510) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/dist/commonjs/components/Call/CallContent/CallContent.js +25 -20
  3. package/dist/commonjs/components/Call/CallContent/CallContent.js.map +1 -1
  4. package/dist/commonjs/components/Call/CallControls/AcceptCallButton.js +8 -6
  5. package/dist/commonjs/components/Call/CallControls/AcceptCallButton.js.map +1 -1
  6. package/dist/commonjs/components/Call/CallControls/CallControls.js +2 -2
  7. package/dist/commonjs/components/Call/CallControls/CallControls.js.map +1 -1
  8. package/dist/commonjs/components/Call/CallControls/CallControlsButton.js +11 -18
  9. package/dist/commonjs/components/Call/CallControls/CallControlsButton.js.map +1 -1
  10. package/dist/commonjs/components/Call/CallControls/HangupCallButton.js +8 -13
  11. package/dist/commonjs/components/Call/CallControls/HangupCallButton.js.map +1 -1
  12. package/dist/commonjs/components/Call/CallControls/IncomingCallControls.js +5 -1
  13. package/dist/commonjs/components/Call/CallControls/IncomingCallControls.js.map +1 -1
  14. package/dist/commonjs/components/Call/CallControls/LobbyControls.js +16 -9
  15. package/dist/commonjs/components/Call/CallControls/LobbyControls.js.map +1 -1
  16. package/dist/commonjs/components/Call/CallControls/ReactionsButton.js +3 -3
  17. package/dist/commonjs/components/Call/CallControls/ReactionsButton.js.map +1 -1
  18. package/dist/commonjs/components/Call/CallControls/RejectCallButton.js +8 -6
  19. package/dist/commonjs/components/Call/CallControls/RejectCallButton.js.map +1 -1
  20. package/dist/commonjs/components/Call/CallControls/ScreenShareToggleButton.js +10 -6
  21. package/dist/commonjs/components/Call/CallControls/ScreenShareToggleButton.js.map +1 -1
  22. package/dist/commonjs/components/Call/CallControls/ToggleAudioPreviewButton.js +10 -10
  23. package/dist/commonjs/components/Call/CallControls/ToggleAudioPreviewButton.js.map +1 -1
  24. package/dist/commonjs/components/Call/CallControls/ToggleAudioPublishingButton.js +9 -6
  25. package/dist/commonjs/components/Call/CallControls/ToggleAudioPublishingButton.js.map +1 -1
  26. package/dist/commonjs/components/Call/CallControls/ToggleCameraFaceButton.js +10 -6
  27. package/dist/commonjs/components/Call/CallControls/ToggleCameraFaceButton.js.map +1 -1
  28. package/dist/commonjs/components/Call/CallControls/ToggleVideoPreviewButton.js +10 -10
  29. package/dist/commonjs/components/Call/CallControls/ToggleVideoPreviewButton.js.map +1 -1
  30. package/dist/commonjs/components/Call/CallControls/ToggleVideoPublishingButton.js +9 -6
  31. package/dist/commonjs/components/Call/CallControls/ToggleVideoPublishingButton.js.map +1 -1
  32. package/dist/commonjs/components/Call/CallControls/index.js +0 -11
  33. package/dist/commonjs/components/Call/CallControls/index.js.map +1 -1
  34. package/dist/commonjs/components/Call/CallControls/internal/ReactionsPicker.js +32 -28
  35. package/dist/commonjs/components/Call/CallControls/internal/ReactionsPicker.js.map +1 -1
  36. package/dist/commonjs/components/Call/CallLayout/CallParticipantsGrid.js +1 -1
  37. package/dist/commonjs/components/Call/CallLayout/CallParticipantsGrid.js.map +1 -1
  38. package/dist/commonjs/components/Call/CallLayout/CallParticipantsSpotlight.js +31 -25
  39. package/dist/commonjs/components/Call/CallLayout/CallParticipantsSpotlight.js.map +1 -1
  40. package/dist/commonjs/components/Call/CallParticipantsList/CallParticipantsList.js +32 -17
  41. package/dist/commonjs/components/Call/CallParticipantsList/CallParticipantsList.js.map +1 -1
  42. package/dist/commonjs/components/Call/Lobby/JoinCallButton.js +21 -14
  43. package/dist/commonjs/components/Call/Lobby/JoinCallButton.js.map +1 -1
  44. package/dist/commonjs/components/Call/Lobby/Lobby.js +66 -94
  45. package/dist/commonjs/components/Call/Lobby/Lobby.js.map +1 -1
  46. package/dist/commonjs/components/Call/Lobby/LobbyFooter.js +60 -23
  47. package/dist/commonjs/components/Call/Lobby/LobbyFooter.js.map +1 -1
  48. package/dist/commonjs/components/Call/RingingCallContent/IncomingCall.js +6 -7
  49. package/dist/commonjs/components/Call/RingingCallContent/IncomingCall.js.map +1 -1
  50. package/dist/commonjs/components/Call/RingingCallContent/OutgoingCall.js +6 -7
  51. package/dist/commonjs/components/Call/RingingCallContent/OutgoingCall.js.map +1 -1
  52. package/dist/commonjs/components/Call/RingingCallContent/RingingCallContent.js +0 -4
  53. package/dist/commonjs/components/Call/RingingCallContent/RingingCallContent.js.map +1 -1
  54. package/dist/commonjs/components/Call/RingingCallContent/TextBasedIndicator.js +3 -3
  55. package/dist/commonjs/components/Call/RingingCallContent/TextBasedIndicator.js.map +1 -1
  56. package/dist/commonjs/components/Call/RingingCallContent/UserInfo.js +1 -1
  57. package/dist/commonjs/components/Call/RingingCallContent/UserInfo.js.map +1 -1
  58. package/dist/commonjs/components/Call/index.js +0 -11
  59. package/dist/commonjs/components/Call/index.js.map +1 -1
  60. package/dist/commonjs/components/Livestream/HostLivestream/HostLivestream.js +31 -20
  61. package/dist/commonjs/components/Livestream/HostLivestream/HostLivestream.js.map +1 -1
  62. package/dist/commonjs/components/Livestream/LivestreamControls/HostLivestreamControls.js +1 -1
  63. package/dist/commonjs/components/Livestream/LivestreamControls/HostLivestreamControls.js.map +1 -1
  64. package/dist/commonjs/components/Livestream/LivestreamControls/HostStartStreamButton.js +2 -2
  65. package/dist/commonjs/components/Livestream/LivestreamControls/HostStartStreamButton.js.map +1 -1
  66. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js +7 -5
  67. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js.map +1 -1
  68. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamScreenShareToggleButton.js +5 -3
  69. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamScreenShareToggleButton.js.map +1 -1
  70. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js +7 -5
  71. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js.map +1 -1
  72. package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js +2 -2
  73. package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js.map +1 -1
  74. package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLivestreamControls.js +1 -1
  75. package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLivestreamControls.js.map +1 -1
  76. package/dist/commonjs/components/Livestream/LivestreamLayout/LivestreamLayout.js +1 -1
  77. package/dist/commonjs/components/Livestream/LivestreamLayout/LivestreamLayout.js.map +1 -1
  78. package/dist/commonjs/components/Livestream/LivestreamTopView/DurationBadge.js +2 -2
  79. package/dist/commonjs/components/Livestream/LivestreamTopView/DurationBadge.js.map +1 -1
  80. package/dist/commonjs/components/Livestream/LivestreamTopView/FollowerCount.js +2 -2
  81. package/dist/commonjs/components/Livestream/LivestreamTopView/FollowerCount.js.map +1 -1
  82. package/dist/commonjs/components/Livestream/LivestreamTopView/HostLivestreamTopView.js +1 -1
  83. package/dist/commonjs/components/Livestream/LivestreamTopView/HostLivestreamTopView.js.map +1 -1
  84. package/dist/commonjs/components/Livestream/LivestreamTopView/LiveIndicator.js +2 -2
  85. package/dist/commonjs/components/Livestream/LivestreamTopView/LiveIndicator.js.map +1 -1
  86. package/dist/commonjs/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js +1 -1
  87. package/dist/commonjs/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js.map +1 -1
  88. package/dist/commonjs/components/Livestream/ViewerLivestream/ViewerLivestream.js +16 -5
  89. package/dist/commonjs/components/Livestream/ViewerLivestream/ViewerLivestream.js.map +1 -1
  90. package/dist/commonjs/components/Participant/FloatingParticipantView/FloatingView/ReanimatedFloatingView.js.map +1 -1
  91. package/dist/commonjs/components/Participant/FloatingParticipantView/index.js +6 -5
  92. package/dist/commonjs/components/Participant/FloatingParticipantView/index.js.map +1 -1
  93. package/dist/commonjs/components/Participant/ParticipantView/ParticipantLabel.js +72 -49
  94. package/dist/commonjs/components/Participant/ParticipantView/ParticipantLabel.js.map +1 -1
  95. package/dist/commonjs/components/Participant/ParticipantView/ParticipantNetworkQualityIndicator.js +5 -5
  96. package/dist/commonjs/components/Participant/ParticipantView/ParticipantNetworkQualityIndicator.js.map +1 -1
  97. package/dist/commonjs/components/Participant/ParticipantView/ParticipantReaction.js +28 -15
  98. package/dist/commonjs/components/Participant/ParticipantView/ParticipantReaction.js.map +1 -1
  99. package/dist/commonjs/components/Participant/ParticipantView/ParticipantVideoFallback.js +2 -2
  100. package/dist/commonjs/components/Participant/ParticipantView/ParticipantVideoFallback.js.map +1 -1
  101. package/dist/commonjs/components/Participant/ParticipantView/ParticipantView.js +29 -21
  102. package/dist/commonjs/components/Participant/ParticipantView/ParticipantView.js.map +1 -1
  103. package/dist/commonjs/components/Participant/ParticipantView/SpeechIndicator.js +86 -0
  104. package/dist/commonjs/components/Participant/ParticipantView/SpeechIndicator.js.map +1 -0
  105. package/dist/commonjs/components/utility/Avatar.js +1 -1
  106. package/dist/commonjs/components/utility/Avatar.js.map +1 -1
  107. package/dist/commonjs/components/utility/ScreenShareOverlay.js +6 -5
  108. package/dist/commonjs/components/utility/ScreenShareOverlay.js.map +1 -1
  109. package/dist/commonjs/constants/TestIds.js +1 -1
  110. package/dist/commonjs/constants/TestIds.js.map +1 -1
  111. package/dist/commonjs/constants/index.js +24 -5
  112. package/dist/commonjs/constants/index.js.map +1 -1
  113. package/dist/commonjs/icons/CameraSwitch.js +6 -3
  114. package/dist/commonjs/icons/CameraSwitch.js.map +1 -1
  115. package/dist/commonjs/icons/IconWrapper.js +25 -0
  116. package/dist/commonjs/icons/IconWrapper.js.map +1 -0
  117. package/dist/commonjs/icons/Lock.js +26 -0
  118. package/dist/commonjs/icons/Lock.js.map +1 -0
  119. package/dist/commonjs/icons/Mic.js +6 -6
  120. package/dist/commonjs/icons/Mic.js.map +1 -1
  121. package/dist/commonjs/icons/MicOff.js +6 -3
  122. package/dist/commonjs/icons/MicOff.js.map +1 -1
  123. package/dist/commonjs/icons/Phone.js +13 -3
  124. package/dist/commonjs/icons/Phone.js.map +1 -1
  125. package/dist/commonjs/icons/PhoneDown.js +6 -3
  126. package/dist/commonjs/icons/PhoneDown.js.map +1 -1
  127. package/dist/commonjs/icons/PinVertical.js +5 -2
  128. package/dist/commonjs/icons/PinVertical.js.map +1 -1
  129. package/dist/commonjs/icons/Reaction.js +3 -1
  130. package/dist/commonjs/icons/Reaction.js.map +1 -1
  131. package/dist/commonjs/icons/ScreenShare.js +6 -3
  132. package/dist/commonjs/icons/ScreenShare.js.map +1 -1
  133. package/dist/commonjs/icons/StopScreenShare.js +5 -2
  134. package/dist/commonjs/icons/StopScreenShare.js.map +1 -1
  135. package/dist/commonjs/icons/Video.js +6 -3
  136. package/dist/commonjs/icons/Video.js.map +1 -1
  137. package/dist/commonjs/icons/VideoSlash.js +6 -3
  138. package/dist/commonjs/icons/VideoSlash.js.map +1 -1
  139. package/dist/commonjs/icons/index.js +11 -22
  140. package/dist/commonjs/icons/index.js.map +1 -1
  141. package/dist/commonjs/theme/colors.js +22 -39
  142. package/dist/commonjs/theme/colors.js.map +1 -1
  143. package/dist/commonjs/theme/constants.js +44 -44
  144. package/dist/commonjs/theme/constants.js.map +1 -1
  145. package/dist/commonjs/theme/index.js +11 -10
  146. package/dist/commonjs/theme/index.js.map +1 -1
  147. package/dist/commonjs/theme/theme.js +46 -9
  148. package/dist/commonjs/theme/theme.js.map +1 -1
  149. package/dist/commonjs/translations/en.json +7 -3
  150. package/dist/commonjs/version.js +1 -1
  151. package/dist/module/components/Call/CallContent/CallContent.js +26 -21
  152. package/dist/module/components/Call/CallContent/CallContent.js.map +1 -1
  153. package/dist/module/components/Call/CallControls/AcceptCallButton.js +9 -7
  154. package/dist/module/components/Call/CallControls/AcceptCallButton.js.map +1 -1
  155. package/dist/module/components/Call/CallControls/CallControls.js +2 -2
  156. package/dist/module/components/Call/CallControls/CallControls.js.map +1 -1
  157. package/dist/module/components/Call/CallControls/CallControlsButton.js +11 -18
  158. package/dist/module/components/Call/CallControls/CallControlsButton.js.map +1 -1
  159. package/dist/module/components/Call/CallControls/HangupCallButton.js +8 -13
  160. package/dist/module/components/Call/CallControls/HangupCallButton.js.map +1 -1
  161. package/dist/module/components/Call/CallControls/IncomingCallControls.js +5 -1
  162. package/dist/module/components/Call/CallControls/IncomingCallControls.js.map +1 -1
  163. package/dist/module/components/Call/CallControls/LobbyControls.js +14 -8
  164. package/dist/module/components/Call/CallControls/LobbyControls.js.map +1 -1
  165. package/dist/module/components/Call/CallControls/ReactionsButton.js +4 -4
  166. package/dist/module/components/Call/CallControls/ReactionsButton.js.map +1 -1
  167. package/dist/module/components/Call/CallControls/RejectCallButton.js +9 -7
  168. package/dist/module/components/Call/CallControls/RejectCallButton.js.map +1 -1
  169. package/dist/module/components/Call/CallControls/ScreenShareToggleButton.js +10 -6
  170. package/dist/module/components/Call/CallControls/ScreenShareToggleButton.js.map +1 -1
  171. package/dist/module/components/Call/CallControls/ToggleAudioPreviewButton.js +11 -11
  172. package/dist/module/components/Call/CallControls/ToggleAudioPreviewButton.js.map +1 -1
  173. package/dist/module/components/Call/CallControls/ToggleAudioPublishingButton.js +10 -7
  174. package/dist/module/components/Call/CallControls/ToggleAudioPublishingButton.js.map +1 -1
  175. package/dist/module/components/Call/CallControls/ToggleCameraFaceButton.js +11 -7
  176. package/dist/module/components/Call/CallControls/ToggleCameraFaceButton.js.map +1 -1
  177. package/dist/module/components/Call/CallControls/ToggleVideoPreviewButton.js +11 -11
  178. package/dist/module/components/Call/CallControls/ToggleVideoPreviewButton.js.map +1 -1
  179. package/dist/module/components/Call/CallControls/ToggleVideoPublishingButton.js +10 -7
  180. package/dist/module/components/Call/CallControls/ToggleVideoPublishingButton.js.map +1 -1
  181. package/dist/module/components/Call/CallControls/index.js +0 -1
  182. package/dist/module/components/Call/CallControls/index.js.map +1 -1
  183. package/dist/module/components/Call/CallControls/internal/ReactionsPicker.js +33 -29
  184. package/dist/module/components/Call/CallControls/internal/ReactionsPicker.js.map +1 -1
  185. package/dist/module/components/Call/CallLayout/CallParticipantsGrid.js +1 -1
  186. package/dist/module/components/Call/CallLayout/CallParticipantsGrid.js.map +1 -1
  187. package/dist/module/components/Call/CallLayout/CallParticipantsSpotlight.js +29 -24
  188. package/dist/module/components/Call/CallLayout/CallParticipantsSpotlight.js.map +1 -1
  189. package/dist/module/components/Call/CallParticipantsList/CallParticipantsList.js +32 -17
  190. package/dist/module/components/Call/CallParticipantsList/CallParticipantsList.js.map +1 -1
  191. package/dist/module/components/Call/Lobby/JoinCallButton.js +19 -13
  192. package/dist/module/components/Call/Lobby/JoinCallButton.js.map +1 -1
  193. package/dist/module/components/Call/Lobby/Lobby.js +64 -93
  194. package/dist/module/components/Call/Lobby/Lobby.js.map +1 -1
  195. package/dist/module/components/Call/Lobby/LobbyFooter.js +58 -22
  196. package/dist/module/components/Call/Lobby/LobbyFooter.js.map +1 -1
  197. package/dist/module/components/Call/RingingCallContent/IncomingCall.js +6 -7
  198. package/dist/module/components/Call/RingingCallContent/IncomingCall.js.map +1 -1
  199. package/dist/module/components/Call/RingingCallContent/OutgoingCall.js +6 -7
  200. package/dist/module/components/Call/RingingCallContent/OutgoingCall.js.map +1 -1
  201. package/dist/module/components/Call/RingingCallContent/RingingCallContent.js +0 -4
  202. package/dist/module/components/Call/RingingCallContent/RingingCallContent.js.map +1 -1
  203. package/dist/module/components/Call/RingingCallContent/TextBasedIndicator.js +3 -3
  204. package/dist/module/components/Call/RingingCallContent/TextBasedIndicator.js.map +1 -1
  205. package/dist/module/components/Call/RingingCallContent/UserInfo.js +1 -1
  206. package/dist/module/components/Call/RingingCallContent/UserInfo.js.map +1 -1
  207. package/dist/module/components/Call/index.js +0 -1
  208. package/dist/module/components/Call/index.js.map +1 -1
  209. package/dist/module/components/Livestream/HostLivestream/HostLivestream.js +32 -21
  210. package/dist/module/components/Livestream/HostLivestream/HostLivestream.js.map +1 -1
  211. package/dist/module/components/Livestream/LivestreamControls/HostLivestreamControls.js +1 -1
  212. package/dist/module/components/Livestream/LivestreamControls/HostLivestreamControls.js.map +1 -1
  213. package/dist/module/components/Livestream/LivestreamControls/HostStartStreamButton.js +2 -2
  214. package/dist/module/components/Livestream/LivestreamControls/HostStartStreamButton.js.map +1 -1
  215. package/dist/module/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js +8 -6
  216. package/dist/module/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js.map +1 -1
  217. package/dist/module/components/Livestream/LivestreamControls/LivestreamScreenShareToggleButton.js +5 -3
  218. package/dist/module/components/Livestream/LivestreamControls/LivestreamScreenShareToggleButton.js.map +1 -1
  219. package/dist/module/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js +8 -6
  220. package/dist/module/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js.map +1 -1
  221. package/dist/module/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js +2 -2
  222. package/dist/module/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js.map +1 -1
  223. package/dist/module/components/Livestream/LivestreamControls/ViewerLivestreamControls.js +1 -1
  224. package/dist/module/components/Livestream/LivestreamControls/ViewerLivestreamControls.js.map +1 -1
  225. package/dist/module/components/Livestream/LivestreamLayout/LivestreamLayout.js +1 -1
  226. package/dist/module/components/Livestream/LivestreamLayout/LivestreamLayout.js.map +1 -1
  227. package/dist/module/components/Livestream/LivestreamTopView/DurationBadge.js +2 -2
  228. package/dist/module/components/Livestream/LivestreamTopView/DurationBadge.js.map +1 -1
  229. package/dist/module/components/Livestream/LivestreamTopView/FollowerCount.js +2 -2
  230. package/dist/module/components/Livestream/LivestreamTopView/FollowerCount.js.map +1 -1
  231. package/dist/module/components/Livestream/LivestreamTopView/HostLivestreamTopView.js +1 -1
  232. package/dist/module/components/Livestream/LivestreamTopView/HostLivestreamTopView.js.map +1 -1
  233. package/dist/module/components/Livestream/LivestreamTopView/LiveIndicator.js +2 -2
  234. package/dist/module/components/Livestream/LivestreamTopView/LiveIndicator.js.map +1 -1
  235. package/dist/module/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js +1 -1
  236. package/dist/module/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js.map +1 -1
  237. package/dist/module/components/Livestream/ViewerLivestream/ViewerLivestream.js +17 -6
  238. package/dist/module/components/Livestream/ViewerLivestream/ViewerLivestream.js.map +1 -1
  239. package/dist/module/components/Participant/FloatingParticipantView/FloatingView/ReanimatedFloatingView.js.map +1 -1
  240. package/dist/module/components/Participant/FloatingParticipantView/index.js +6 -5
  241. package/dist/module/components/Participant/FloatingParticipantView/index.js.map +1 -1
  242. package/dist/module/components/Participant/ParticipantView/ParticipantLabel.js +70 -49
  243. package/dist/module/components/Participant/ParticipantView/ParticipantLabel.js.map +1 -1
  244. package/dist/module/components/Participant/ParticipantView/ParticipantNetworkQualityIndicator.js +5 -5
  245. package/dist/module/components/Participant/ParticipantView/ParticipantNetworkQualityIndicator.js.map +1 -1
  246. package/dist/module/components/Participant/ParticipantView/ParticipantReaction.js +29 -16
  247. package/dist/module/components/Participant/ParticipantView/ParticipantReaction.js.map +1 -1
  248. package/dist/module/components/Participant/ParticipantView/ParticipantVideoFallback.js +2 -2
  249. package/dist/module/components/Participant/ParticipantView/ParticipantVideoFallback.js.map +1 -1
  250. package/dist/module/components/Participant/ParticipantView/ParticipantView.js +27 -20
  251. package/dist/module/components/Participant/ParticipantView/ParticipantView.js.map +1 -1
  252. package/dist/module/components/Participant/ParticipantView/SpeechIndicator.js +78 -0
  253. package/dist/module/components/Participant/ParticipantView/SpeechIndicator.js.map +1 -0
  254. package/dist/module/components/utility/Avatar.js +1 -1
  255. package/dist/module/components/utility/Avatar.js.map +1 -1
  256. package/dist/module/components/utility/ScreenShareOverlay.js +6 -5
  257. package/dist/module/components/utility/ScreenShareOverlay.js.map +1 -1
  258. package/dist/module/constants/TestIds.js +1 -1
  259. package/dist/module/constants/TestIds.js.map +1 -1
  260. package/dist/module/constants/index.js +23 -4
  261. package/dist/module/constants/index.js.map +1 -1
  262. package/dist/module/icons/CameraSwitch.js +6 -3
  263. package/dist/module/icons/CameraSwitch.js.map +1 -1
  264. package/dist/module/icons/IconWrapper.js +17 -0
  265. package/dist/module/icons/IconWrapper.js.map +1 -0
  266. package/dist/module/icons/Lock.js +16 -0
  267. package/dist/module/icons/Lock.js.map +1 -0
  268. package/dist/module/icons/Mic.js +6 -6
  269. package/dist/module/icons/Mic.js.map +1 -1
  270. package/dist/module/icons/MicOff.js +6 -3
  271. package/dist/module/icons/MicOff.js.map +1 -1
  272. package/dist/module/icons/Phone.js +13 -3
  273. package/dist/module/icons/Phone.js.map +1 -1
  274. package/dist/module/icons/PhoneDown.js +6 -3
  275. package/dist/module/icons/PhoneDown.js.map +1 -1
  276. package/dist/module/icons/PinVertical.js +5 -2
  277. package/dist/module/icons/PinVertical.js.map +1 -1
  278. package/dist/module/icons/Reaction.js +3 -1
  279. package/dist/module/icons/Reaction.js.map +1 -1
  280. package/dist/module/icons/ScreenShare.js +6 -3
  281. package/dist/module/icons/ScreenShare.js.map +1 -1
  282. package/dist/module/icons/StopScreenShare.js +5 -2
  283. package/dist/module/icons/StopScreenShare.js.map +1 -1
  284. package/dist/module/icons/Video.js +6 -3
  285. package/dist/module/icons/Video.js.map +1 -1
  286. package/dist/module/icons/VideoSlash.js +6 -3
  287. package/dist/module/icons/VideoSlash.js.map +1 -1
  288. package/dist/module/icons/index.js +1 -2
  289. package/dist/module/icons/index.js.map +1 -1
  290. package/dist/module/theme/colors.js +22 -39
  291. package/dist/module/theme/colors.js.map +1 -1
  292. package/dist/module/theme/constants.js +44 -44
  293. package/dist/module/theme/constants.js.map +1 -1
  294. package/dist/module/theme/index.js +1 -5
  295. package/dist/module/theme/index.js.map +1 -1
  296. package/dist/module/theme/theme.js +46 -9
  297. package/dist/module/theme/theme.js.map +1 -1
  298. package/dist/module/translations/en.json +7 -3
  299. package/dist/module/version.js +1 -1
  300. package/dist/typescript/components/Call/CallContent/CallContent.d.ts +2 -7
  301. package/dist/typescript/components/Call/CallContent/CallContent.d.ts.map +1 -1
  302. package/dist/typescript/components/Call/CallControls/AcceptCallButton.d.ts.map +1 -1
  303. package/dist/typescript/components/Call/CallControls/CallControlsButton.d.ts +4 -0
  304. package/dist/typescript/components/Call/CallControls/CallControlsButton.d.ts.map +1 -1
  305. package/dist/typescript/components/Call/CallControls/HangupCallButton.d.ts.map +1 -1
  306. package/dist/typescript/components/Call/CallControls/IncomingCallControls.d.ts.map +1 -1
  307. package/dist/typescript/components/Call/CallControls/LobbyControls.d.ts.map +1 -1
  308. package/dist/typescript/components/Call/CallControls/ReactionsButton.d.ts.map +1 -1
  309. package/dist/typescript/components/Call/CallControls/RejectCallButton.d.ts.map +1 -1
  310. package/dist/typescript/components/Call/CallControls/ScreenShareToggleButton.d.ts.map +1 -1
  311. package/dist/typescript/components/Call/CallControls/ToggleAudioPreviewButton.d.ts.map +1 -1
  312. package/dist/typescript/components/Call/CallControls/ToggleAudioPublishingButton.d.ts.map +1 -1
  313. package/dist/typescript/components/Call/CallControls/ToggleCameraFaceButton.d.ts +6 -1
  314. package/dist/typescript/components/Call/CallControls/ToggleCameraFaceButton.d.ts.map +1 -1
  315. package/dist/typescript/components/Call/CallControls/ToggleVideoPreviewButton.d.ts.map +1 -1
  316. package/dist/typescript/components/Call/CallControls/ToggleVideoPublishingButton.d.ts.map +1 -1
  317. package/dist/typescript/components/Call/CallControls/index.d.ts +0 -1
  318. package/dist/typescript/components/Call/CallControls/index.d.ts.map +1 -1
  319. package/dist/typescript/components/Call/CallControls/internal/ReactionsPicker.d.ts.map +1 -1
  320. package/dist/typescript/components/Call/CallLayout/CallParticipantsSpotlight.d.ts.map +1 -1
  321. package/dist/typescript/components/Call/CallParticipantsList/CallParticipantsList.d.ts.map +1 -1
  322. package/dist/typescript/components/Call/Lobby/JoinCallButton.d.ts.map +1 -1
  323. package/dist/typescript/components/Call/Lobby/Lobby.d.ts.map +1 -1
  324. package/dist/typescript/components/Call/Lobby/LobbyFooter.d.ts.map +1 -1
  325. package/dist/typescript/components/Call/RingingCallContent/IncomingCall.d.ts +2 -6
  326. package/dist/typescript/components/Call/RingingCallContent/IncomingCall.d.ts.map +1 -1
  327. package/dist/typescript/components/Call/RingingCallContent/OutgoingCall.d.ts +1 -6
  328. package/dist/typescript/components/Call/RingingCallContent/OutgoingCall.d.ts.map +1 -1
  329. package/dist/typescript/components/Call/RingingCallContent/RingingCallContent.d.ts +0 -5
  330. package/dist/typescript/components/Call/RingingCallContent/RingingCallContent.d.ts.map +1 -1
  331. package/dist/typescript/components/Call/index.d.ts +0 -1
  332. package/dist/typescript/components/Call/index.d.ts.map +1 -1
  333. package/dist/typescript/components/Livestream/HostLivestream/HostLivestream.d.ts.map +1 -1
  334. package/dist/typescript/components/Livestream/LivestreamControls/LivestreamAudioControlButton.d.ts.map +1 -1
  335. package/dist/typescript/components/Livestream/LivestreamControls/LivestreamVideoControlButton.d.ts.map +1 -1
  336. package/dist/typescript/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.d.ts.map +1 -1
  337. package/dist/typescript/components/Livestream/LivestreamControls/ViewerLivestreamControls.d.ts.map +1 -1
  338. package/dist/typescript/components/Livestream/ViewerLivestream/ViewerLivestream.d.ts.map +1 -1
  339. package/dist/typescript/components/Participant/FloatingParticipantView/FloatingView/ReanimatedFloatingView.d.ts.map +1 -1
  340. package/dist/typescript/components/Participant/FloatingParticipantView/index.d.ts.map +1 -1
  341. package/dist/typescript/components/Participant/ParticipantView/ParticipantLabel.d.ts.map +1 -1
  342. package/dist/typescript/components/Participant/ParticipantView/ParticipantReaction.d.ts +1 -1
  343. package/dist/typescript/components/Participant/ParticipantView/ParticipantReaction.d.ts.map +1 -1
  344. package/dist/typescript/components/Participant/ParticipantView/ParticipantVideoFallback.d.ts.map +1 -1
  345. package/dist/typescript/components/Participant/ParticipantView/ParticipantView.d.ts.map +1 -1
  346. package/dist/typescript/components/Participant/ParticipantView/SpeechIndicator.d.ts +18 -0
  347. package/dist/typescript/components/Participant/ParticipantView/SpeechIndicator.d.ts.map +1 -0
  348. package/dist/typescript/components/utility/Avatar.d.ts.map +1 -1
  349. package/dist/typescript/constants/TestIds.d.ts +2 -2
  350. package/dist/typescript/constants/TestIds.d.ts.map +1 -1
  351. package/dist/typescript/constants/index.d.ts +0 -1
  352. package/dist/typescript/constants/index.d.ts.map +1 -1
  353. package/dist/typescript/icons/CameraSwitch.d.ts +2 -1
  354. package/dist/typescript/icons/CameraSwitch.d.ts.map +1 -1
  355. package/dist/typescript/icons/IconWrapper.d.ts +6 -0
  356. package/dist/typescript/icons/IconWrapper.d.ts.map +1 -0
  357. package/dist/typescript/icons/{Chat.d.ts → Lock.d.ts} +3 -2
  358. package/dist/typescript/icons/Lock.d.ts.map +1 -0
  359. package/dist/typescript/icons/Mic.d.ts +2 -1
  360. package/dist/typescript/icons/Mic.d.ts.map +1 -1
  361. package/dist/typescript/icons/MicOff.d.ts +2 -1
  362. package/dist/typescript/icons/MicOff.d.ts.map +1 -1
  363. package/dist/typescript/icons/Phone.d.ts +2 -1
  364. package/dist/typescript/icons/Phone.d.ts.map +1 -1
  365. package/dist/typescript/icons/PhoneDown.d.ts +2 -1
  366. package/dist/typescript/icons/PhoneDown.d.ts.map +1 -1
  367. package/dist/typescript/icons/PinVertical.d.ts +2 -1
  368. package/dist/typescript/icons/PinVertical.d.ts.map +1 -1
  369. package/dist/typescript/icons/ScreenShare.d.ts +2 -1
  370. package/dist/typescript/icons/ScreenShare.d.ts.map +1 -1
  371. package/dist/typescript/icons/StopScreenShare.d.ts +2 -1
  372. package/dist/typescript/icons/StopScreenShare.d.ts.map +1 -1
  373. package/dist/typescript/icons/Video.d.ts +2 -1
  374. package/dist/typescript/icons/Video.d.ts.map +1 -1
  375. package/dist/typescript/icons/VideoSlash.d.ts +2 -1
  376. package/dist/typescript/icons/VideoSlash.d.ts.map +1 -1
  377. package/dist/typescript/icons/index.d.ts +1 -2
  378. package/dist/typescript/icons/index.d.ts.map +1 -1
  379. package/dist/typescript/theme/colors.d.ts +5 -38
  380. package/dist/typescript/theme/colors.d.ts.map +1 -1
  381. package/dist/typescript/theme/constants.d.ts +44 -44
  382. package/dist/typescript/theme/constants.d.ts.map +1 -1
  383. package/dist/typescript/theme/index.d.ts +1 -2
  384. package/dist/typescript/theme/index.d.ts.map +1 -1
  385. package/dist/typescript/theme/theme.d.ts +23 -31
  386. package/dist/typescript/theme/theme.d.ts.map +1 -1
  387. package/dist/typescript/theme/types.d.ts +65 -18
  388. package/dist/typescript/theme/types.d.ts.map +1 -1
  389. package/dist/typescript/translations/index.d.ts +5 -1
  390. package/dist/typescript/translations/index.d.ts.map +1 -1
  391. package/dist/typescript/version.d.ts +1 -1
  392. package/package.json +3 -3
  393. package/src/components/Call/CallContent/CallContent.tsx +25 -33
  394. package/src/components/Call/CallControls/AcceptCallButton.tsx +7 -5
  395. package/src/components/Call/CallControls/CallControls.tsx +2 -2
  396. package/src/components/Call/CallControls/CallControlsButton.tsx +14 -20
  397. package/src/components/Call/CallControls/HangupCallButton.tsx +6 -11
  398. package/src/components/Call/CallControls/IncomingCallControls.tsx +5 -1
  399. package/src/components/Call/CallControls/LobbyControls.tsx +16 -8
  400. package/src/components/Call/CallControls/ReactionsButton.tsx +4 -2
  401. package/src/components/Call/CallControls/RejectCallButton.tsx +7 -5
  402. package/src/components/Call/CallControls/ScreenShareToggleButton.tsx +18 -7
  403. package/src/components/Call/CallControls/ToggleAudioPreviewButton.tsx +11 -13
  404. package/src/components/Call/CallControls/ToggleAudioPublishingButton.tsx +12 -8
  405. package/src/components/Call/CallControls/ToggleCameraFaceButton.tsx +23 -10
  406. package/src/components/Call/CallControls/ToggleVideoPreviewButton.tsx +11 -14
  407. package/src/components/Call/CallControls/ToggleVideoPublishingButton.tsx +15 -8
  408. package/src/components/Call/CallControls/index.tsx +0 -1
  409. package/src/components/Call/CallControls/internal/ReactionsPicker.tsx +34 -32
  410. package/src/components/Call/CallLayout/CallParticipantsGrid.tsx +2 -4
  411. package/src/components/Call/CallLayout/CallParticipantsSpotlight.tsx +29 -23
  412. package/src/components/Call/CallParticipantsList/CallParticipantsList.tsx +34 -15
  413. package/src/components/Call/Lobby/JoinCallButton.tsx +21 -15
  414. package/src/components/Call/Lobby/Lobby.tsx +74 -121
  415. package/src/components/Call/Lobby/LobbyFooter.tsx +63 -41
  416. package/src/components/Call/RingingCallContent/IncomingCall.tsx +4 -14
  417. package/src/components/Call/RingingCallContent/OutgoingCall.tsx +4 -14
  418. package/src/components/Call/RingingCallContent/RingingCallContent.tsx +3 -17
  419. package/src/components/Call/RingingCallContent/TextBasedIndicator.tsx +3 -3
  420. package/src/components/Call/RingingCallContent/UserInfo.tsx +1 -1
  421. package/src/components/Call/index.ts +0 -1
  422. package/src/components/Livestream/HostLivestream/HostLivestream.tsx +34 -23
  423. package/src/components/Livestream/LivestreamControls/HostLivestreamControls.tsx +1 -1
  424. package/src/components/Livestream/LivestreamControls/HostStartStreamButton.tsx +4 -4
  425. package/src/components/Livestream/LivestreamControls/LivestreamAudioControlButton.tsx +9 -7
  426. package/src/components/Livestream/LivestreamControls/LivestreamScreenShareToggleButton.tsx +4 -4
  427. package/src/components/Livestream/LivestreamControls/LivestreamVideoControlButton.tsx +9 -7
  428. package/src/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.tsx +2 -4
  429. package/src/components/Livestream/LivestreamControls/ViewerLivestreamControls.tsx +1 -3
  430. package/src/components/Livestream/LivestreamLayout/LivestreamLayout.tsx +1 -1
  431. package/src/components/Livestream/LivestreamTopView/DurationBadge.tsx +2 -2
  432. package/src/components/Livestream/LivestreamTopView/FollowerCount.tsx +2 -2
  433. package/src/components/Livestream/LivestreamTopView/HostLivestreamTopView.tsx +1 -1
  434. package/src/components/Livestream/LivestreamTopView/LiveIndicator.tsx +2 -2
  435. package/src/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.tsx +1 -1
  436. package/src/components/Livestream/ViewerLivestream/ViewerLivestream.tsx +19 -6
  437. package/src/components/Participant/FloatingParticipantView/FloatingView/ReanimatedFloatingView.tsx +0 -1
  438. package/src/components/Participant/FloatingParticipantView/index.tsx +4 -6
  439. package/src/components/Participant/ParticipantView/ParticipantLabel.tsx +87 -87
  440. package/src/components/Participant/ParticipantView/ParticipantNetworkQualityIndicator.tsx +5 -5
  441. package/src/components/Participant/ParticipantView/ParticipantReaction.tsx +36 -26
  442. package/src/components/Participant/ParticipantView/ParticipantVideoFallback.tsx +2 -6
  443. package/src/components/Participant/ParticipantView/ParticipantView.tsx +33 -22
  444. package/src/components/Participant/ParticipantView/SpeechIndicator.tsx +103 -0
  445. package/src/components/utility/Avatar.tsx +2 -4
  446. package/src/components/utility/ScreenShareOverlay.tsx +5 -5
  447. package/src/constants/TestIds.ts +1 -1
  448. package/src/constants/index.ts +27 -5
  449. package/src/icons/CameraSwitch.tsx +4 -3
  450. package/src/icons/IconWrapper.tsx +15 -0
  451. package/src/icons/Lock.tsx +19 -0
  452. package/src/icons/Mic.tsx +4 -7
  453. package/src/icons/MicOff.tsx +4 -3
  454. package/src/icons/Phone.tsx +11 -3
  455. package/src/icons/PhoneDown.tsx +9 -3
  456. package/src/icons/PinVertical.tsx +3 -2
  457. package/src/icons/Reaction.tsx +1 -1
  458. package/src/icons/ScreenShare.tsx +9 -3
  459. package/src/icons/StopScreenShare.tsx +3 -2
  460. package/src/icons/Video.tsx +4 -3
  461. package/src/icons/VideoSlash.tsx +9 -3
  462. package/src/icons/index.tsx +1 -2
  463. package/src/theme/colors.ts +27 -42
  464. package/src/theme/constants.ts +51 -44
  465. package/src/theme/index.ts +1 -8
  466. package/src/theme/theme.ts +77 -40
  467. package/src/theme/types.ts +72 -21
  468. package/src/translations/en.json +7 -3
  469. package/src/version.ts +1 -1
  470. package/dist/commonjs/components/Call/CallControls/ChatButton.js +0 -84
  471. package/dist/commonjs/components/Call/CallControls/ChatButton.js.map +0 -1
  472. package/dist/commonjs/components/Call/CallTopView/CallTopView.js +0 -120
  473. package/dist/commonjs/components/Call/CallTopView/CallTopView.js.map +0 -1
  474. package/dist/commonjs/components/Call/CallTopView/ParticipantsInfoBadge.js +0 -105
  475. package/dist/commonjs/components/Call/CallTopView/ParticipantsInfoBadge.js.map +0 -1
  476. package/dist/commonjs/components/Call/CallTopView/index.js +0 -28
  477. package/dist/commonjs/components/Call/CallTopView/index.js.map +0 -1
  478. package/dist/commonjs/icons/Chat.js +0 -19
  479. package/dist/commonjs/icons/Chat.js.map +0 -1
  480. package/dist/commonjs/icons/Participants.js +0 -21
  481. package/dist/commonjs/icons/Participants.js.map +0 -1
  482. package/dist/module/components/Call/CallControls/ChatButton.js +0 -77
  483. package/dist/module/components/Call/CallControls/ChatButton.js.map +0 -1
  484. package/dist/module/components/Call/CallTopView/CallTopView.js +0 -111
  485. package/dist/module/components/Call/CallTopView/CallTopView.js.map +0 -1
  486. package/dist/module/components/Call/CallTopView/ParticipantsInfoBadge.js +0 -98
  487. package/dist/module/components/Call/CallTopView/ParticipantsInfoBadge.js.map +0 -1
  488. package/dist/module/components/Call/CallTopView/index.js +0 -3
  489. package/dist/module/components/Call/CallTopView/index.js.map +0 -1
  490. package/dist/module/icons/Chat.js +0 -11
  491. package/dist/module/icons/Chat.js.map +0 -1
  492. package/dist/module/icons/Participants.js +0 -13
  493. package/dist/module/icons/Participants.js.map +0 -1
  494. package/dist/typescript/components/Call/CallControls/ChatButton.d.ts +0 -22
  495. package/dist/typescript/components/Call/CallControls/ChatButton.d.ts.map +0 -1
  496. package/dist/typescript/components/Call/CallTopView/CallTopView.d.ts +0 -29
  497. package/dist/typescript/components/Call/CallTopView/CallTopView.d.ts.map +0 -1
  498. package/dist/typescript/components/Call/CallTopView/ParticipantsInfoBadge.d.ts +0 -12
  499. package/dist/typescript/components/Call/CallTopView/ParticipantsInfoBadge.d.ts.map +0 -1
  500. package/dist/typescript/components/Call/CallTopView/index.d.ts +0 -3
  501. package/dist/typescript/components/Call/CallTopView/index.d.ts.map +0 -1
  502. package/dist/typescript/icons/Chat.d.ts.map +0 -1
  503. package/dist/typescript/icons/Participants.d.ts +0 -8
  504. package/dist/typescript/icons/Participants.d.ts.map +0 -1
  505. package/src/components/Call/CallControls/ChatButton.tsx +0 -90
  506. package/src/components/Call/CallTopView/CallTopView.tsx +0 -162
  507. package/src/components/Call/CallTopView/ParticipantsInfoBadge.tsx +0 -119
  508. package/src/components/Call/CallTopView/index.ts +0 -2
  509. package/src/icons/Chat.tsx +0 -16
  510. package/src/icons/Participants.tsx +0 -18
@@ -1,98 +0,0 @@
1
- import React from 'react';
2
- import { Pressable, StyleSheet, Text, View } from 'react-native';
3
- import { Participants } from '../../../icons';
4
- import { useCallStateHooks } from '@stream-io/video-react-bindings';
5
- import { Z_INDEX } from '../../../constants';
6
- import { ButtonTestIds } from '../../../constants/TestIds';
7
- import { useTheme } from '../../../contexts/ThemeContext';
8
- import { CallingState } from '@stream-io/video-client';
9
-
10
- /**
11
- * Props for the ParticipantsInfoBadge component.
12
- */
13
-
14
- /**
15
- * Badge that shows the number of participants in the call.
16
- * When pressed, it opens the ParticipantsInfoList.
17
- */
18
- export const ParticipantsInfoBadge = ({
19
- onParticipantInfoPress
20
- }) => {
21
- const {
22
- theme: {
23
- colors,
24
- participantInfoBadge,
25
- typefaces,
26
- variants: {
27
- iconSizes
28
- }
29
- }
30
- } = useTheme();
31
- const {
32
- useParticipantCount,
33
- useCallMembers,
34
- useCallCallingState
35
- } = useCallStateHooks();
36
- const participantCount = useParticipantCount();
37
- const members = useCallMembers();
38
- const callingState = useCallCallingState();
39
- let count = 0;
40
- /**
41
- * We show member's length if Incoming and Outgoing Call Views are rendered.
42
- * Else we show the count of the participants that are in the call.
43
- * Since the members count also includes caller/callee, we reduce the count by 1.
44
- **/
45
- if (callingState === CallingState.RINGING) {
46
- count = members.length - 1;
47
- } else {
48
- count = participantCount;
49
- }
50
- if (count === 0) {
51
- return null;
52
- }
53
- return /*#__PURE__*/React.createElement(Pressable, {
54
- onPress: onParticipantInfoPress,
55
- style: ({
56
- pressed
57
- }) => [styles.container, {
58
- opacity: pressed ? 0.2 : 1
59
- }, participantInfoBadge.container],
60
- disabled: !onParticipantInfoPress,
61
- testID: ButtonTestIds.PARTICIPANTS_INFO
62
- }, /*#__PURE__*/React.createElement(View, {
63
- style: [{
64
- height: iconSizes.md,
65
- width: iconSizes.md
66
- }, participantInfoBadge.participantsIconContainer]
67
- }, /*#__PURE__*/React.createElement(Participants, {
68
- color: colors.static_white
69
- })), /*#__PURE__*/React.createElement(View, {
70
- style: [styles.participantCountContainer, {
71
- backgroundColor: colors.text_low_emphasis
72
- }, participantInfoBadge.participantCountContainer],
73
- testID: ButtonTestIds.PARTICIPANTS_COUNT_VIEW
74
- }, /*#__PURE__*/React.createElement(Text, {
75
- style: [styles.participantCountText, {
76
- color: colors.static_white
77
- }, typefaces.subtitle, participantInfoBadge.participantsCountText],
78
- testID: ButtonTestIds.PARTICIPANTS_COUNT_TEXT
79
- }, count)));
80
- };
81
- const styles = StyleSheet.create({
82
- container: {
83
- flexDirection: 'row'
84
- },
85
- participantCountContainer: {
86
- justifyContent: 'center',
87
- paddingHorizontal: 8,
88
- borderRadius: 30,
89
- zIndex: Z_INDEX.IN_FRONT,
90
- bottom: 12,
91
- right: 12
92
- },
93
- participantCountText: {
94
- includeFontPadding: false,
95
- textAlign: 'center'
96
- }
97
- });
98
- //# sourceMappingURL=ParticipantsInfoBadge.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["React","Pressable","StyleSheet","Text","View","Participants","useCallStateHooks","Z_INDEX","ButtonTestIds","useTheme","CallingState","ParticipantsInfoBadge","onParticipantInfoPress","theme","colors","participantInfoBadge","typefaces","variants","iconSizes","useParticipantCount","useCallMembers","useCallCallingState","participantCount","members","callingState","count","RINGING","length","createElement","onPress","style","pressed","styles","container","opacity","disabled","testID","PARTICIPANTS_INFO","height","md","width","participantsIconContainer","color","static_white","participantCountContainer","backgroundColor","text_low_emphasis","PARTICIPANTS_COUNT_VIEW","participantCountText","subtitle","participantsCountText","PARTICIPANTS_COUNT_TEXT","create","flexDirection","justifyContent","paddingHorizontal","borderRadius","zIndex","IN_FRONT","bottom","right","includeFontPadding","textAlign"],"sourceRoot":"../../../../../src","sources":["components/Call/CallTopView/ParticipantsInfoBadge.tsx"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,SAAS,EAAEC,UAAU,EAAEC,IAAI,EAAEC,IAAI,QAAQ,cAAc;AAChE,SAASC,YAAY,QAAQ,gBAAgB;AAC7C,SAASC,iBAAiB,QAAQ,iCAAiC;AACnE,SAASC,OAAO,QAAQ,oBAAoB;AAE5C,SAASC,aAAa,QAAQ,4BAA4B;AAC1D,SAASC,QAAQ,QAAQ,gCAAgC;AACzD,SAASC,YAAY,QAAQ,yBAAyB;;AAEtD;AACA;AACA;;AAMA;AACA;AACA;AACA;AACA,OAAO,MAAMC,qBAAqB,GAAGA,CAAC;EACpCC;AAC0B,CAAC,KAAK;EAChC,MAAM;IACJC,KAAK,EAAE;MACLC,MAAM;MACNC,oBAAoB;MACpBC,SAAS;MACTC,QAAQ,EAAE;QAAEC;MAAU;IACxB;EACF,CAAC,GAAGT,QAAQ,CAAC,CAAC;EACd,MAAM;IAAEU,mBAAmB;IAAEC,cAAc;IAAEC;EAAoB,CAAC,GAChEf,iBAAiB,CAAC,CAAC;EACrB,MAAMgB,gBAAgB,GAAGH,mBAAmB,CAAC,CAAC;EAC9C,MAAMI,OAAO,GAAGH,cAAc,CAAC,CAAC;EAChC,MAAMI,YAAY,GAAGH,mBAAmB,CAAC,CAAC;EAE1C,IAAII,KAAK,GAAG,CAAC;EACb;AACF;AACA;AACA;AACA;EACE,IAAID,YAAY,KAAKd,YAAY,CAACgB,OAAO,EAAE;IACzCD,KAAK,GAAGF,OAAO,CAACI,MAAM,GAAG,CAAC;EAC5B,CAAC,MAAM;IACLF,KAAK,GAAGH,gBAAgB;EAC1B;EAEA,IAAIG,KAAK,KAAK,CAAC,EAAE;IACf,OAAO,IAAI;EACb;EAEA,oBACEzB,KAAA,CAAA4B,aAAA,CAAC3B,SAAS;IACR4B,OAAO,EAAEjB,sBAAuB;IAChCkB,KAAK,EAAEA,CAAC;MAAEC;IAAQ,CAAC,KAAK,CACtBC,MAAM,CAACC,SAAS,EAChB;MAAEC,OAAO,EAAEH,OAAO,GAAG,GAAG,GAAG;IAAE,CAAC,EAC9BhB,oBAAoB,CAACkB,SAAS,CAC9B;IACFE,QAAQ,EAAE,CAACvB,sBAAuB;IAClCwB,MAAM,EAAE5B,aAAa,CAAC6B;EAAkB,gBAExCrC,KAAA,CAAA4B,aAAA,CAACxB,IAAI;IACH0B,KAAK,EAAE,CACL;MAAEQ,MAAM,EAAEpB,SAAS,CAACqB,EAAE;MAAEC,KAAK,EAAEtB,SAAS,CAACqB;IAAG,CAAC,EAC7CxB,oBAAoB,CAAC0B,yBAAyB;EAC9C,gBAEFzC,KAAA,CAAA4B,aAAA,CAACvB,YAAY;IAACqC,KAAK,EAAE5B,MAAM,CAAC6B;EAAa,CAAE,CACvC,CAAC,eACP3C,KAAA,CAAA4B,aAAA,CAACxB,IAAI;IACH0B,KAAK,EAAE,CACLE,MAAM,CAACY,yBAAyB,EAChC;MACEC,eAAe,EAAE/B,MAAM,CAACgC;IAC1B,CAAC,EACD/B,oBAAoB,CAAC6B,yBAAyB,CAC9C;IACFR,MAAM,EAAE5B,aAAa,CAACuC;EAAwB,gBAE9C/C,KAAA,CAAA4B,aAAA,CAACzB,IAAI;IACH2B,KAAK,EAAE,CACLE,MAAM,CAACgB,oBAAoB,EAC3B;MACEN,KAAK,EAAE5B,MAAM,CAAC6B;IAChB,CAAC,EACD3B,SAAS,CAACiC,QAAQ,EAClBlC,oBAAoB,CAACmC,qBAAqB,CAC1C;IACFd,MAAM,EAAE5B,aAAa,CAAC2C;EAAwB,GAE7C1B,KACG,CACF,CACG,CAAC;AAEhB,CAAC;AAED,MAAMO,MAAM,GAAG9B,UAAU,CAACkD,MAAM,CAAC;EAC/BnB,SAAS,EAAE;IACToB,aAAa,EAAE;EACjB,CAAC;EACDT,yBAAyB,EAAE;IACzBU,cAAc,EAAE,QAAQ;IACxBC,iBAAiB,EAAE,CAAC;IACpBC,YAAY,EAAE,EAAE;IAChBC,MAAM,EAAElD,OAAO,CAACmD,QAAQ;IACxBC,MAAM,EAAE,EAAE;IACVC,KAAK,EAAE;EACT,CAAC;EACDZ,oBAAoB,EAAE;IACpBa,kBAAkB,EAAE,KAAK;IACzBC,SAAS,EAAE;EACb;AACF,CAAC,CAAC","ignoreList":[]}
@@ -1,3 +0,0 @@
1
- export * from './CallTopView';
2
- export * from './ParticipantsInfoBadge';
3
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":[],"sourceRoot":"../../../../../src","sources":["components/Call/CallTopView/index.ts"],"mappings":"AAAA,cAAc,eAAe;AAC7B,cAAc,yBAAyB","ignoreList":[]}
@@ -1,11 +0,0 @@
1
- import React from 'react';
2
- import { Svg, Path } from 'react-native-svg';
3
- export const Chat = ({
4
- color
5
- }) => /*#__PURE__*/React.createElement(Svg, {
6
- viewBox: "0 0 21 20"
7
- }, /*#__PURE__*/React.createElement(Path, {
8
- d: "M 17.1887 0.353516 H 2.37385 C 1.35534 0.353516 0.522003 1.18685 0.522003 2.20537 V 18.872 L 4.22571 15.1683 H 17.1887 C 18.2072 15.1683 19.0405 14.335 19.0405 13.3165 V 2.20537 C 19.0405 1.18685 18.2072 0.353516 17.1887 0.353516 Z M 17.1887 13.3165 H 4.22571 L 2.37385 15.1683 V 2.20537 H 17.1887 V 13.3165 Z",
9
- fill: color
10
- }));
11
- //# sourceMappingURL=Chat.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["React","Svg","Path","Chat","color","createElement","viewBox","d","fill"],"sourceRoot":"../../../src","sources":["icons/Chat.tsx"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,GAAG,EAAEC,IAAI,QAAQ,kBAAkB;AAO5C,OAAO,MAAMC,IAAI,GAAGA,CAAC;EAAEC;AAAa,CAAC,kBACnCJ,KAAA,CAAAK,aAAA,CAACJ,GAAG;EAACK,OAAO,EAAC;AAAW,gBACtBN,KAAA,CAAAK,aAAA,CAACH,IAAI;EACHK,CAAC,EAAC,uTAAuT;EACzTC,IAAI,EAAEJ;AAAM,CACb,CACE,CACN","ignoreList":[]}
@@ -1,13 +0,0 @@
1
- import React from 'react';
2
- import { Svg, Path } from 'react-native-svg';
3
- export const Participants = ({
4
- color
5
- }) => /*#__PURE__*/React.createElement(Svg, {
6
- viewBox: "0 0 23 20"
7
- }, /*#__PURE__*/React.createElement(Path, {
8
- clipRule: "evenodd",
9
- d: "M 11 8 C 13.2091 8 15 6.20914 15 4 C 15 1.79086 13.2091 0 11 0 C 8.79086 0 7 1.79086 7 4 C 7 6.20914 8.79086 8 11 8 Z M 5.5 1 C 3.567 1 2 2.567 2 4.5 C 2 6.433 3.567 8 5.5 8 C 6.05228 8 6.5 7.55228 6.5 7 C 6.5 6.44772 6.05228 6 5.5 6 C 4.67157 6 4 5.32843 4 4.5 C 4 3.67157 4.67157 3 5.5 3 C 6.05228 3 6.5 2.55228 6.5 2 C 6.5 1.44772 6.05228 1 5.5 1 Z M 4 16 C 4 12.134 7.13401 9 11 9 C 14.866 9 18 12.134 18 16 C 18 16.397 17.9669 16.7869 17.903 17.1671 C 17.6021 18.9581 13 19.5 11 19.5 C 9 19.5 4.41865 19.0753 4.09763 17.1708 C 4.03335 16.7894 4 16.3982 4 16 Z M 3.85402 10.7725 C 4.28304 10.4247 4.34889 9.79494 4.0011 9.36592 C 3.6533 8.9369 3.02357 8.87105 2.59455 9.21884 C 1.01345 10.5006 0 12.4618 0 14.659 C 0 15.0572 0.0333547 15.4484 0.0976325 15.8297 C 0.18943 16.3743 0.705335 16.7414 1.24994 16.6496 C 1.79454 16.5578 2.16161 16.0419 2.06981 15.4973 C 2.02397 15.2253 2 14.9453 2 14.659 C 2 13.0903 2.72123 11.6908 3.85402 10.7725 Z M 20.5 4.5 C 20.5 2.567 18.933 1 17 1 C 16.4477 1 16 1.44772 16 2 C 16 2.55228 16.4477 3 17 3 C 17.8284 3 18.5 3.67157 18.5 4.5 C 18.5 5.32843 17.8284 6 17 6 C 16.4477 6 16 6.44772 16 7 C 16 7.55228 16.4477 8 17 8 C 18.933 8 20.5 6.433 20.5 4.5 Z M 18.3703 10.7725 C 17.9413 10.4247 17.8755 9.79494 18.2233 9.36592 C 18.5711 8.9369 19.2008 8.87105 19.6298 9.21884 C 21.2109 10.5006 22.2244 12.4618 22.2244 14.659 C 22.2244 15.0572 22.191 15.4484 22.1267 15.8297 C 22.0349 16.3743 21.519 16.7414 20.9744 16.6496 C 20.4298 16.5578 20.0628 16.0419 20.1546 15.4973 C 20.2004 15.2253 20.2244 14.9453 20.2244 14.659 C 20.2244 13.0903 19.5031 11.6908 18.3703 10.7725 Z",
10
- fill: color,
11
- fillRule: "evenodd"
12
- }));
13
- //# sourceMappingURL=Participants.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["React","Svg","Path","Participants","color","createElement","viewBox","clipRule","d","fill","fillRule"],"sourceRoot":"../../../src","sources":["icons/Participants.tsx"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,GAAG,EAAEC,IAAI,QAAQ,kBAAkB;AAO5C,OAAO,MAAMC,YAAY,GAAGA,CAAC;EAAEC;AAAa,CAAC,kBAC3CJ,KAAA,CAAAK,aAAA,CAACJ,GAAG;EAACK,OAAO,EAAC;AAAW,gBACtBN,KAAA,CAAAK,aAAA,CAACH,IAAI;EACHK,QAAQ,EAAC,SAAS;EAClBC,CAAC,EAAC,4kDAA4kD;EAC9kDC,IAAI,EAAEL,KAAM;EACZM,QAAQ,EAAC;AAAS,CACnB,CACE,CACN","ignoreList":[]}
@@ -1,22 +0,0 @@
1
- import React from 'react';
2
- /**
3
- * The props for the Chat Button in the Call Controls.
4
- */
5
- export type ChatButtonProps = {
6
- /**
7
- * Handler to be called when the chat button is pressed.
8
- * @returns void
9
- */
10
- onPressHandler?: () => void;
11
- /**
12
- * The count of the current unread message to be displayed above on the Chat button.
13
- */
14
- unreadBadgeCount?: number;
15
- };
16
- /**
17
- * Button to open the Chat window while in the call.
18
- *
19
- * This call also display the unread count indicator/badge is there messages that are unread.
20
- */
21
- export declare const ChatButton: ({ onPressHandler, unreadBadgeCount, }: ChatButtonProps) => React.JSX.Element;
22
- //# sourceMappingURL=ChatButton.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ChatButton.d.ts","sourceRoot":"","sources":["../../../../../src/components/Call/CallControls/ChatButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B;;GAEG;AACH,MAAM,MAAM,eAAe,GAAG;IAC5B;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;IAC5B;;OAEG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,UAAU,0CAGpB,eAAe,sBAUjB,CAAC"}
@@ -1,29 +0,0 @@
1
- import React from 'react';
2
- import { StyleProp, ViewStyle } from 'react-native';
3
- import { ParticipantsInfoBadgeProps } from './ParticipantsInfoBadge';
4
- export type CallTopViewProps = {
5
- /**
6
- * Handler to be called when the back button is pressed in the CallTopView.
7
- * @returns void
8
- */
9
- onBackPressed?: () => void;
10
- /**
11
- * Handler to be called when the Participant icon is pressed in the CallTopView.
12
- * @returns
13
- */
14
- onParticipantInfoPress?: () => void;
15
- /**
16
- * Title to be rendered at the center of the Header.
17
- */
18
- title?: string;
19
- /**
20
- * Style to override the container of the CallTopView.
21
- */
22
- style?: StyleProp<ViewStyle>;
23
- /**
24
- * Component to customize the ParticipantInfoBadge of the CallTopView.
25
- */
26
- ParticipantsInfoBadge?: React.ComponentType<ParticipantsInfoBadgeProps> | null;
27
- };
28
- export declare const CallTopView: ({ onBackPressed, onParticipantInfoPress, title, style: styleProp, ParticipantsInfoBadge, }: CallTopViewProps) => React.JSX.Element;
29
- //# sourceMappingURL=CallTopView.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CallTopView.d.ts","sourceRoot":"","sources":["../../../../../src/components/Call/CallTopView/CallTopView.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AACxC,OAAO,EAKL,SAAS,EACT,SAAS,EACV,MAAM,cAAc,CAAC;AACtB,OAAO,EAEL,0BAA0B,EAC3B,MAAM,yBAAyB,CAAC;AAOjC,MAAM,MAAM,gBAAgB,GAAG;IAC7B;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,IAAI,CAAC;IAC3B;;;OAGG;IACH,sBAAsB,CAAC,EAAE,MAAM,IAAI,CAAC;IACpC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;IAC7B;;OAEG;IACH,qBAAqB,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC,0BAA0B,CAAC,GAAG,IAAI,CAAC;CAChF,CAAC;AAEF,eAAO,MAAM,WAAW,+FAMrB,gBAAgB,sBAmFlB,CAAC"}
@@ -1,12 +0,0 @@
1
- import React from 'react';
2
- import { CallTopViewProps } from '..';
3
- /**
4
- * Props for the ParticipantsInfoBadge component.
5
- */
6
- export type ParticipantsInfoBadgeProps = Pick<CallTopViewProps, 'onParticipantInfoPress'>;
7
- /**
8
- * Badge that shows the number of participants in the call.
9
- * When pressed, it opens the ParticipantsInfoList.
10
- */
11
- export declare const ParticipantsInfoBadge: ({ onParticipantInfoPress, }: ParticipantsInfoBadgeProps) => React.JSX.Element | null;
12
- //# sourceMappingURL=ParticipantsInfoBadge.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ParticipantsInfoBadge.d.ts","sourceRoot":"","sources":["../../../../../src/components/Call/CallTopView/ParticipantsInfoBadge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,EAAE,gBAAgB,EAAE,MAAM,IAAI,CAAC;AAKtC;;GAEG;AACH,MAAM,MAAM,0BAA0B,GAAG,IAAI,CAC3C,gBAAgB,EAChB,wBAAwB,CACzB,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,qBAAqB,gCAE/B,0BAA0B,6BA4E5B,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from './CallTopView';
2
- export * from './ParticipantsInfoBadge';
3
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Call/CallTopView/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,yBAAyB,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"Chat.d.ts","sourceRoot":"","sources":["../../../src/icons/Chat.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAEhD,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,UAAU,CAAC;CACnB,CAAC;AAEF,eAAO,MAAM,IAAI,cAAe,KAAK,sBAOpC,CAAC"}
@@ -1,8 +0,0 @@
1
- import React from 'react';
2
- import { ColorValue } from 'react-native/types';
3
- type Props = {
4
- color: ColorValue;
5
- };
6
- export declare const Participants: ({ color }: Props) => React.JSX.Element;
7
- export {};
8
- //# sourceMappingURL=Participants.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Participants.d.ts","sourceRoot":"","sources":["../../../src/icons/Participants.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAEhD,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,UAAU,CAAC;CACnB,CAAC;AAEF,eAAO,MAAM,YAAY,cAAe,KAAK,sBAS5C,CAAC"}
@@ -1,90 +0,0 @@
1
- import React from 'react';
2
- import { StyleSheet, Text, View } from 'react-native';
3
- import { CallControlsButton } from './CallControlsButton';
4
- import { Chat } from '../../../icons';
5
- import { ComponentTestIds } from '../../../constants/TestIds';
6
- import { Z_INDEX } from '../../../constants';
7
- import { useTheme } from '../../../contexts/ThemeContext';
8
-
9
- /**
10
- * The props for the Chat Button in the Call Controls.
11
- */
12
- export type ChatButtonProps = {
13
- /**
14
- * Handler to be called when the chat button is pressed.
15
- * @returns void
16
- */
17
- onPressHandler?: () => void;
18
- /**
19
- * The count of the current unread message to be displayed above on the Chat button.
20
- */
21
- unreadBadgeCount?: number;
22
- };
23
-
24
- /**
25
- * Button to open the Chat window while in the call.
26
- *
27
- * This call also display the unread count indicator/badge is there messages that are unread.
28
- */
29
- export const ChatButton = ({
30
- onPressHandler,
31
- unreadBadgeCount,
32
- }: ChatButtonProps) => {
33
- const {
34
- theme: { colors, chatButton },
35
- } = useTheme();
36
- return (
37
- <CallControlsButton onPress={onPressHandler} style={chatButton}>
38
- <UnreadBadgeCountIndicator count={unreadBadgeCount} />
39
- <Chat color={colors.static_black} />
40
- </CallControlsButton>
41
- );
42
- };
43
-
44
- const UnreadBadgeCountIndicator = ({
45
- count,
46
- }: {
47
- count: ChatButtonProps['unreadBadgeCount'];
48
- }) => {
49
- const {
50
- theme: { colors, typefaces },
51
- } = useTheme();
52
-
53
- // Don't show badge if count is 0 or undefined
54
- if (!count) {
55
- return null;
56
- }
57
-
58
- return (
59
- <View
60
- testID={ComponentTestIds.CHAT_UNREAD_BADGE_COUNT_INDICATOR}
61
- style={[styles.chatBadge, { backgroundColor: colors.error }]}
62
- >
63
- <Text
64
- style={[
65
- styles.chatBadgeText,
66
- { color: colors.static_white },
67
- typefaces.subtitle,
68
- ]}
69
- >
70
- {count}
71
- </Text>
72
- </View>
73
- );
74
- };
75
-
76
- const styles = StyleSheet.create({
77
- chatBadge: {
78
- borderRadius: 30,
79
- position: 'absolute',
80
- left: 15,
81
- bottom: 20,
82
- zIndex: Z_INDEX.IN_FRONT,
83
- height: 24,
84
- width: 24,
85
- justifyContent: 'center',
86
- },
87
- chatBadgeText: {
88
- textAlign: 'center',
89
- },
90
- });
@@ -1,162 +0,0 @@
1
- import React, { useState } from 'react';
2
- import {
3
- View,
4
- StyleSheet,
5
- Text,
6
- Pressable,
7
- StyleProp,
8
- ViewStyle,
9
- } from 'react-native';
10
- import {
11
- ParticipantsInfoBadge as DefaultParticipantsInfoBadge,
12
- ParticipantsInfoBadgeProps,
13
- } from './ParticipantsInfoBadge';
14
- import { Back } from '../../../icons/Back';
15
- import { TopViewBackground } from '../../../icons';
16
- import { useCallStateHooks, useI18n } from '@stream-io/video-react-bindings';
17
- import { CallingState } from '@stream-io/video-client';
18
- import { useTheme } from '../../../contexts/ThemeContext';
19
-
20
- export type CallTopViewProps = {
21
- /**
22
- * Handler to be called when the back button is pressed in the CallTopView.
23
- * @returns void
24
- */
25
- onBackPressed?: () => void;
26
- /**
27
- * Handler to be called when the Participant icon is pressed in the CallTopView.
28
- * @returns
29
- */
30
- onParticipantInfoPress?: () => void;
31
- /**
32
- * Title to be rendered at the center of the Header.
33
- */
34
- title?: string;
35
- /**
36
- * Style to override the container of the CallTopView.
37
- */
38
- style?: StyleProp<ViewStyle>;
39
- /**
40
- * Component to customize the ParticipantInfoBadge of the CallTopView.
41
- */
42
- ParticipantsInfoBadge?: React.ComponentType<ParticipantsInfoBadgeProps> | null;
43
- };
44
-
45
- export const CallTopView = ({
46
- onBackPressed,
47
- onParticipantInfoPress,
48
- title,
49
- style: styleProp,
50
- ParticipantsInfoBadge = DefaultParticipantsInfoBadge,
51
- }: CallTopViewProps) => {
52
- const [callTopViewHeight, setCallTopViewHeight] = useState<number>(0);
53
- const [callTopViewWidth, setCallTopViewWidth] = useState<number>(0);
54
- const {
55
- theme: {
56
- colors,
57
- typefaces,
58
- variants: { iconSizes },
59
- callTopView,
60
- },
61
- } = useTheme();
62
- const { useCallCallingState } = useCallStateHooks();
63
- const callingState = useCallCallingState();
64
- const { t } = useI18n();
65
- const isCallReconnecting = callingState === CallingState.RECONNECTING;
66
-
67
- const onLayout: React.ComponentProps<typeof View>['onLayout'] = (event) => {
68
- const { height, width } = event.nativeEvent.layout;
69
- if (setCallTopViewHeight) {
70
- setCallTopViewHeight(height);
71
- setCallTopViewWidth(width);
72
- }
73
- };
74
-
75
- return (
76
- <View style={[styleProp, callTopView.container]}>
77
- {/* Component for the background of the CallTopView. Since it has a Linear Gradient, an SVG is used to render it. */}
78
- <TopViewBackground height={callTopViewHeight} width={callTopViewWidth} />
79
- <View style={[styles.content, callTopView.content]} onLayout={onLayout}>
80
- <View style={styles.leftElement}>
81
- {onBackPressed && (
82
- <Pressable
83
- style={({ pressed }) => [
84
- styles.backIconContainer,
85
- {
86
- opacity: pressed ? 0.2 : 1,
87
- height: iconSizes.md,
88
- width: iconSizes.md,
89
- },
90
- callTopView.backIconContainer,
91
- ]}
92
- onPress={onBackPressed}
93
- >
94
- <Back color={colors.static_white} />
95
- </Pressable>
96
- )}
97
- </View>
98
- <View style={[styles.centerElement, callTopView.centerElement]}>
99
- {title ? (
100
- <Text
101
- style={[
102
- { color: colors.static_white },
103
- typefaces.subtitleBold,
104
- callTopView.title,
105
- ]}
106
- numberOfLines={1}
107
- >
108
- {title}
109
- </Text>
110
- ) : (
111
- isCallReconnecting && (
112
- <Text
113
- style={[
114
- { color: colors.static_white },
115
- typefaces.subtitleBold,
116
- callTopView.title,
117
- ]}
118
- >
119
- {t('Reconnecting...')}
120
- </Text>
121
- )
122
- )}
123
- </View>
124
- <View style={[styles.rightElement, callTopView.rightElement]}>
125
- {ParticipantsInfoBadge && (
126
- <ParticipantsInfoBadge
127
- onParticipantInfoPress={onParticipantInfoPress}
128
- />
129
- )}
130
- </View>
131
- </View>
132
- </View>
133
- );
134
- };
135
-
136
- const styles = StyleSheet.create({
137
- content: {
138
- position: 'absolute',
139
- top: 0,
140
- flexDirection: 'row',
141
- paddingTop: 24,
142
- paddingBottom: 12,
143
- alignItems: 'center',
144
- },
145
- backIconContainer: {
146
- // Added to compensate the participant badge surface area
147
- marginLeft: 8,
148
- },
149
- leftElement: {
150
- flex: 1,
151
- alignItems: 'flex-start',
152
- },
153
- centerElement: {
154
- flex: 1,
155
- alignItems: 'center',
156
- flexGrow: 3,
157
- },
158
- rightElement: {
159
- flex: 1,
160
- alignItems: 'flex-end',
161
- },
162
- });
@@ -1,119 +0,0 @@
1
- import React from 'react';
2
- import { Pressable, StyleSheet, Text, View } from 'react-native';
3
- import { Participants } from '../../../icons';
4
- import { useCallStateHooks } from '@stream-io/video-react-bindings';
5
- import { Z_INDEX } from '../../../constants';
6
- import { CallTopViewProps } from '..';
7
- import { ButtonTestIds } from '../../../constants/TestIds';
8
- import { useTheme } from '../../../contexts/ThemeContext';
9
- import { CallingState } from '@stream-io/video-client';
10
-
11
- /**
12
- * Props for the ParticipantsInfoBadge component.
13
- */
14
- export type ParticipantsInfoBadgeProps = Pick<
15
- CallTopViewProps,
16
- 'onParticipantInfoPress'
17
- >;
18
-
19
- /**
20
- * Badge that shows the number of participants in the call.
21
- * When pressed, it opens the ParticipantsInfoList.
22
- */
23
- export const ParticipantsInfoBadge = ({
24
- onParticipantInfoPress,
25
- }: ParticipantsInfoBadgeProps) => {
26
- const {
27
- theme: {
28
- colors,
29
- participantInfoBadge,
30
- typefaces,
31
- variants: { iconSizes },
32
- },
33
- } = useTheme();
34
- const { useParticipantCount, useCallMembers, useCallCallingState } =
35
- useCallStateHooks();
36
- const participantCount = useParticipantCount();
37
- const members = useCallMembers();
38
- const callingState = useCallCallingState();
39
-
40
- let count = 0;
41
- /**
42
- * We show member's length if Incoming and Outgoing Call Views are rendered.
43
- * Else we show the count of the participants that are in the call.
44
- * Since the members count also includes caller/callee, we reduce the count by 1.
45
- **/
46
- if (callingState === CallingState.RINGING) {
47
- count = members.length - 1;
48
- } else {
49
- count = participantCount;
50
- }
51
-
52
- if (count === 0) {
53
- return null;
54
- }
55
-
56
- return (
57
- <Pressable
58
- onPress={onParticipantInfoPress}
59
- style={({ pressed }) => [
60
- styles.container,
61
- { opacity: pressed ? 0.2 : 1 },
62
- participantInfoBadge.container,
63
- ]}
64
- disabled={!onParticipantInfoPress}
65
- testID={ButtonTestIds.PARTICIPANTS_INFO}
66
- >
67
- <View
68
- style={[
69
- { height: iconSizes.md, width: iconSizes.md },
70
- participantInfoBadge.participantsIconContainer,
71
- ]}
72
- >
73
- <Participants color={colors.static_white} />
74
- </View>
75
- <View
76
- style={[
77
- styles.participantCountContainer,
78
- {
79
- backgroundColor: colors.text_low_emphasis,
80
- },
81
- participantInfoBadge.participantCountContainer,
82
- ]}
83
- testID={ButtonTestIds.PARTICIPANTS_COUNT_VIEW}
84
- >
85
- <Text
86
- style={[
87
- styles.participantCountText,
88
- {
89
- color: colors.static_white,
90
- },
91
- typefaces.subtitle,
92
- participantInfoBadge.participantsCountText,
93
- ]}
94
- testID={ButtonTestIds.PARTICIPANTS_COUNT_TEXT}
95
- >
96
- {count}
97
- </Text>
98
- </View>
99
- </Pressable>
100
- );
101
- };
102
-
103
- const styles = StyleSheet.create({
104
- container: {
105
- flexDirection: 'row',
106
- },
107
- participantCountContainer: {
108
- justifyContent: 'center',
109
- paddingHorizontal: 8,
110
- borderRadius: 30,
111
- zIndex: Z_INDEX.IN_FRONT,
112
- bottom: 12,
113
- right: 12,
114
- },
115
- participantCountText: {
116
- includeFontPadding: false,
117
- textAlign: 'center',
118
- },
119
- });
@@ -1,2 +0,0 @@
1
- export * from './CallTopView';
2
- export * from './ParticipantsInfoBadge';
@@ -1,16 +0,0 @@
1
- import React from 'react';
2
- import { Svg, Path } from 'react-native-svg';
3
- import { ColorValue } from 'react-native/types';
4
-
5
- type Props = {
6
- color: ColorValue;
7
- };
8
-
9
- export const Chat = ({ color }: Props) => (
10
- <Svg viewBox="0 0 21 20">
11
- <Path
12
- d="M 17.1887 0.353516 H 2.37385 C 1.35534 0.353516 0.522003 1.18685 0.522003 2.20537 V 18.872 L 4.22571 15.1683 H 17.1887 C 18.2072 15.1683 19.0405 14.335 19.0405 13.3165 V 2.20537 C 19.0405 1.18685 18.2072 0.353516 17.1887 0.353516 Z M 17.1887 13.3165 H 4.22571 L 2.37385 15.1683 V 2.20537 H 17.1887 V 13.3165 Z"
13
- fill={color}
14
- />
15
- </Svg>
16
- );