@stream-io/video-react-native-sdk 1.39.0 → 1.40.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 (692) hide show
  1. package/CHANGELOG.md +24 -6
  2. package/android/src/main/java/com/streamvideo/reactnative/StreamVideoReactNativeModule.kt +81 -0
  3. package/android/src/main/java/com/streamvideo/reactnative/recorder/AudioPipeline.kt +436 -0
  4. package/android/src/main/java/com/streamvideo/reactnative/recorder/EncoderConstants.kt +17 -0
  5. package/android/src/main/java/com/streamvideo/reactnative/recorder/PipelineHost.kt +36 -0
  6. package/android/src/main/java/com/streamvideo/reactnative/recorder/RecorderPlaybackSamplesSink.kt +60 -0
  7. package/android/src/main/java/com/streamvideo/reactnative/recorder/RecorderVideoSink.kt +31 -0
  8. package/android/src/main/java/com/streamvideo/reactnative/recorder/TracksRecorderManager.kt +338 -0
  9. package/android/src/main/java/com/streamvideo/reactnative/recorder/VideoPipeline.kt +472 -0
  10. package/dist/commonjs/components/Call/CallContent/CallContent.js +93 -48
  11. package/dist/commonjs/components/Call/CallContent/CallContent.js.map +1 -1
  12. package/dist/commonjs/components/Call/CallContent/RTCViewPipIOS.js +22 -20
  13. package/dist/commonjs/components/Call/CallContent/RTCViewPipIOS.js.map +1 -1
  14. package/dist/commonjs/components/Call/CallContent/RTCViewPipNative.js +2 -1
  15. package/dist/commonjs/components/Call/CallContent/RTCViewPipNative.js.map +1 -1
  16. package/dist/commonjs/components/Call/CallControls/AcceptCallButton.js +10 -6
  17. package/dist/commonjs/components/Call/CallControls/AcceptCallButton.js.map +1 -1
  18. package/dist/commonjs/components/Call/CallControls/CallControls.js +7 -5
  19. package/dist/commonjs/components/Call/CallControls/CallControls.js.map +1 -1
  20. package/dist/commonjs/components/Call/CallControls/CallControlsButton.js +11 -8
  21. package/dist/commonjs/components/Call/CallControls/CallControlsButton.js.map +1 -1
  22. package/dist/commonjs/components/Call/CallControls/HangupCallButton.js +10 -6
  23. package/dist/commonjs/components/Call/CallControls/HangupCallButton.js.map +1 -1
  24. package/dist/commonjs/components/Call/CallControls/IncomingCallControls.js +11 -9
  25. package/dist/commonjs/components/Call/CallControls/IncomingCallControls.js.map +1 -1
  26. package/dist/commonjs/components/Call/CallControls/LobbyControls.js +5 -3
  27. package/dist/commonjs/components/Call/CallControls/LobbyControls.js.map +1 -1
  28. package/dist/commonjs/components/Call/CallControls/OutgoingCallControls.js +12 -9
  29. package/dist/commonjs/components/Call/CallControls/OutgoingCallControls.js.map +1 -1
  30. package/dist/commonjs/components/Call/CallControls/ReactionsButton.js +22 -15
  31. package/dist/commonjs/components/Call/CallControls/ReactionsButton.js.map +1 -1
  32. package/dist/commonjs/components/Call/CallControls/RejectCallButton.js +10 -6
  33. package/dist/commonjs/components/Call/CallControls/RejectCallButton.js.map +1 -1
  34. package/dist/commonjs/components/Call/CallControls/ScreenShareToggleButton.js +15 -11
  35. package/dist/commonjs/components/Call/CallControls/ScreenShareToggleButton.js.map +1 -1
  36. package/dist/commonjs/components/Call/CallControls/ToggleAudioPreviewButton.js +13 -9
  37. package/dist/commonjs/components/Call/CallControls/ToggleAudioPreviewButton.js.map +1 -1
  38. package/dist/commonjs/components/Call/CallControls/ToggleAudioPublishingButton.js +18 -13
  39. package/dist/commonjs/components/Call/CallControls/ToggleAudioPublishingButton.js.map +1 -1
  40. package/dist/commonjs/components/Call/CallControls/ToggleCameraFaceButton.js +17 -12
  41. package/dist/commonjs/components/Call/CallControls/ToggleCameraFaceButton.js.map +1 -1
  42. package/dist/commonjs/components/Call/CallControls/ToggleVideoPreviewButton.js +13 -9
  43. package/dist/commonjs/components/Call/CallControls/ToggleVideoPreviewButton.js.map +1 -1
  44. package/dist/commonjs/components/Call/CallControls/ToggleVideoPublishingButton.js +17 -12
  45. package/dist/commonjs/components/Call/CallControls/ToggleVideoPublishingButton.js.map +1 -1
  46. package/dist/commonjs/components/Call/CallControls/internal/ReactionsPicker.js +39 -34
  47. package/dist/commonjs/components/Call/CallControls/internal/ReactionsPicker.js.map +1 -1
  48. package/dist/commonjs/components/Call/CallLayout/CallParticipantsGrid.js +17 -12
  49. package/dist/commonjs/components/Call/CallLayout/CallParticipantsGrid.js.map +1 -1
  50. package/dist/commonjs/components/Call/CallLayout/CallParticipantsSpotlight.js +36 -24
  51. package/dist/commonjs/components/Call/CallLayout/CallParticipantsSpotlight.js.map +1 -1
  52. package/dist/commonjs/components/Call/CallParticipantsList/CallParticipantsList.js +30 -28
  53. package/dist/commonjs/components/Call/CallParticipantsList/CallParticipantsList.js.map +1 -1
  54. package/dist/commonjs/components/Call/Lobby/JoinCallButton.js +10 -7
  55. package/dist/commonjs/components/Call/Lobby/JoinCallButton.js.map +1 -1
  56. package/dist/commonjs/components/Call/Lobby/Lobby.js +45 -35
  57. package/dist/commonjs/components/Call/Lobby/Lobby.js.map +1 -1
  58. package/dist/commonjs/components/Call/Lobby/LobbyFooter.js +21 -16
  59. package/dist/commonjs/components/Call/Lobby/LobbyFooter.js.map +1 -1
  60. package/dist/commonjs/components/Call/RingingCallContent/CallLeftIndicator.js +2 -1
  61. package/dist/commonjs/components/Call/RingingCallContent/CallLeftIndicator.js.map +1 -1
  62. package/dist/commonjs/components/Call/RingingCallContent/CallPreparingIndicator.js +2 -1
  63. package/dist/commonjs/components/Call/RingingCallContent/CallPreparingIndicator.js.map +1 -1
  64. package/dist/commonjs/components/Call/RingingCallContent/IncomingCall.js +32 -22
  65. package/dist/commonjs/components/Call/RingingCallContent/IncomingCall.js.map +1 -1
  66. package/dist/commonjs/components/Call/RingingCallContent/OutgoingCall.js +37 -27
  67. package/dist/commonjs/components/Call/RingingCallContent/OutgoingCall.js.map +1 -1
  68. package/dist/commonjs/components/Call/RingingCallContent/RingingCallContent.js +13 -11
  69. package/dist/commonjs/components/Call/RingingCallContent/RingingCallContent.js.map +1 -1
  70. package/dist/commonjs/components/Call/RingingCallContent/TextBasedIndicator.js +28 -22
  71. package/dist/commonjs/components/Call/RingingCallContent/TextBasedIndicator.js.map +1 -1
  72. package/dist/commonjs/components/Call/RingingCallContent/UserInfo.js +25 -22
  73. package/dist/commonjs/components/Call/RingingCallContent/UserInfo.js.map +1 -1
  74. package/dist/commonjs/components/Livestream/HostLivestream/HostLivestream.js +38 -34
  75. package/dist/commonjs/components/Livestream/HostLivestream/HostLivestream.js.map +1 -1
  76. package/dist/commonjs/components/Livestream/LivestreamControls/HostLivestreamControls.js +16 -12
  77. package/dist/commonjs/components/Livestream/LivestreamControls/HostLivestreamControls.js.map +1 -1
  78. package/dist/commonjs/components/Livestream/LivestreamControls/HostStartStreamButton.js +16 -12
  79. package/dist/commonjs/components/Livestream/LivestreamControls/HostStartStreamButton.js.map +1 -1
  80. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js +19 -14
  81. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js.map +1 -1
  82. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamMediaControls.js +5 -3
  83. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamMediaControls.js.map +1 -1
  84. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamScreenShareToggleButton.js +19 -16
  85. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamScreenShareToggleButton.js.map +1 -1
  86. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js +19 -14
  87. package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js.map +1 -1
  88. package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js +11 -8
  89. package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js.map +1 -1
  90. package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLivestreamControls.js +78 -57
  91. package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLivestreamControls.js.map +1 -1
  92. package/dist/commonjs/components/Livestream/LivestreamLayout/LivestreamLayout.js +13 -46
  93. package/dist/commonjs/components/Livestream/LivestreamLayout/LivestreamLayout.js.map +1 -1
  94. package/dist/commonjs/components/Livestream/LivestreamPlayer/LivestreamEnded.js +48 -22
  95. package/dist/commonjs/components/Livestream/LivestreamPlayer/LivestreamEnded.js.map +1 -1
  96. package/dist/commonjs/components/Livestream/LivestreamPlayer/LivestreamPlayer.js +7 -5
  97. package/dist/commonjs/components/Livestream/LivestreamPlayer/LivestreamPlayer.js.map +1 -1
  98. package/dist/commonjs/components/Livestream/LivestreamTopView/DurationBadge.js +12 -9
  99. package/dist/commonjs/components/Livestream/LivestreamTopView/DurationBadge.js.map +1 -1
  100. package/dist/commonjs/components/Livestream/LivestreamTopView/FollowerCount.js +11 -7
  101. package/dist/commonjs/components/Livestream/LivestreamTopView/FollowerCount.js.map +1 -1
  102. package/dist/commonjs/components/Livestream/LivestreamTopView/HostLivestreamTopView.js +18 -13
  103. package/dist/commonjs/components/Livestream/LivestreamTopView/HostLivestreamTopView.js.map +1 -1
  104. package/dist/commonjs/components/Livestream/LivestreamTopView/LiveIndicator.js +10 -7
  105. package/dist/commonjs/components/Livestream/LivestreamTopView/LiveIndicator.js.map +1 -1
  106. package/dist/commonjs/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js +18 -13
  107. package/dist/commonjs/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js.map +1 -1
  108. package/dist/commonjs/components/Livestream/ViewerLivestream/ViewerLivestream.js +41 -37
  109. package/dist/commonjs/components/Livestream/ViewerLivestream/ViewerLivestream.js.map +1 -1
  110. package/dist/commonjs/components/Livestream/ViewerLivestream/ViewerLobby.js +33 -23
  111. package/dist/commonjs/components/Livestream/ViewerLivestream/ViewerLobby.js.map +1 -1
  112. package/dist/commonjs/components/Participant/FloatingParticipantView/FloatingView/AnimatedFloatingView.js +18 -15
  113. package/dist/commonjs/components/Participant/FloatingParticipantView/FloatingView/AnimatedFloatingView.js.map +1 -1
  114. package/dist/commonjs/components/Participant/FloatingParticipantView/FloatingView/ReanimatedFloatingView.js +20 -16
  115. package/dist/commonjs/components/Participant/FloatingParticipantView/FloatingView/ReanimatedFloatingView.js.map +1 -1
  116. package/dist/commonjs/components/Participant/FloatingParticipantView/index.js +55 -48
  117. package/dist/commonjs/components/Participant/FloatingParticipantView/index.js.map +1 -1
  118. package/dist/commonjs/components/Participant/ParticipantView/ParticipantLabel.js +64 -52
  119. package/dist/commonjs/components/Participant/ParticipantView/ParticipantLabel.js.map +1 -1
  120. package/dist/commonjs/components/Participant/ParticipantView/ParticipantNetworkQualityIndicator.js +30 -27
  121. package/dist/commonjs/components/Participant/ParticipantView/ParticipantNetworkQualityIndicator.js.map +1 -1
  122. package/dist/commonjs/components/Participant/ParticipantView/ParticipantReaction.js +11 -7
  123. package/dist/commonjs/components/Participant/ParticipantView/ParticipantReaction.js.map +1 -1
  124. package/dist/commonjs/components/Participant/ParticipantView/ParticipantVideoFallback.js +17 -14
  125. package/dist/commonjs/components/Participant/ParticipantView/ParticipantVideoFallback.js.map +1 -1
  126. package/dist/commonjs/components/Participant/ParticipantView/ParticipantView.js +27 -24
  127. package/dist/commonjs/components/Participant/ParticipantView/ParticipantView.js.map +1 -1
  128. package/dist/commonjs/components/Participant/ParticipantView/SpeechIndicator.js +8 -7
  129. package/dist/commonjs/components/Participant/ParticipantView/SpeechIndicator.js.map +1 -1
  130. package/dist/commonjs/components/Participant/ParticipantView/VideoRenderer/index.js +35 -32
  131. package/dist/commonjs/components/Participant/ParticipantView/VideoRenderer/index.js.map +1 -1
  132. package/dist/commonjs/components/utility/Avatar.js +18 -15
  133. package/dist/commonjs/components/utility/Avatar.js.map +1 -1
  134. package/dist/commonjs/components/utility/ScreenShareOverlay.js +35 -29
  135. package/dist/commonjs/components/utility/ScreenShareOverlay.js.map +1 -1
  136. package/dist/commonjs/contexts/BackgroundFilters.js +5 -3
  137. package/dist/commonjs/contexts/BackgroundFilters.js.map +1 -1
  138. package/dist/commonjs/contexts/ThemeContext.js +5 -3
  139. package/dist/commonjs/contexts/ThemeContext.js.map +1 -1
  140. package/dist/commonjs/contexts/internal/ScreenshotIosContext.js +5 -3
  141. package/dist/commonjs/contexts/internal/ScreenshotIosContext.js.map +1 -1
  142. package/dist/commonjs/hooks/index.js +11 -0
  143. package/dist/commonjs/hooks/index.js.map +1 -1
  144. package/dist/commonjs/hooks/useAutoEnterPiPEffect.js +5 -10
  145. package/dist/commonjs/hooks/useAutoEnterPiPEffect.js.map +1 -1
  146. package/dist/commonjs/hooks/useLoopbackRecording.js +263 -0
  147. package/dist/commonjs/hooks/useLoopbackRecording.js.map +1 -0
  148. package/dist/commonjs/hooks/useModeration.js +4 -1
  149. package/dist/commonjs/hooks/useModeration.js.map +1 -1
  150. package/dist/commonjs/icons/Back.js +8 -6
  151. package/dist/commonjs/icons/Back.js.map +1 -1
  152. package/dist/commonjs/icons/BadNetwork.js +11 -9
  153. package/dist/commonjs/icons/BadNetwork.js.map +1 -1
  154. package/dist/commonjs/icons/CameraSwitch.js +8 -6
  155. package/dist/commonjs/icons/CameraSwitch.js.map +1 -1
  156. package/dist/commonjs/icons/EndStreamIcon.js +8 -6
  157. package/dist/commonjs/icons/EndStreamIcon.js.map +1 -1
  158. package/dist/commonjs/icons/Eye.js +8 -6
  159. package/dist/commonjs/icons/Eye.js.map +1 -1
  160. package/dist/commonjs/icons/IconWrapper.js +5 -3
  161. package/dist/commonjs/icons/IconWrapper.js.map +1 -1
  162. package/dist/commonjs/icons/LivestreamControls.js +44 -39
  163. package/dist/commonjs/icons/LivestreamControls.js.map +1 -1
  164. package/dist/commonjs/icons/Lock.js +8 -6
  165. package/dist/commonjs/icons/Lock.js.map +1 -1
  166. package/dist/commonjs/icons/Maximize.js +33 -31
  167. package/dist/commonjs/icons/Maximize.js.map +1 -1
  168. package/dist/commonjs/icons/Mic.js +8 -6
  169. package/dist/commonjs/icons/Mic.js.map +1 -1
  170. package/dist/commonjs/icons/MicOff.js +8 -6
  171. package/dist/commonjs/icons/MicOff.js.map +1 -1
  172. package/dist/commonjs/icons/Phone.js +8 -6
  173. package/dist/commonjs/icons/Phone.js.map +1 -1
  174. package/dist/commonjs/icons/PhoneDown.js +8 -6
  175. package/dist/commonjs/icons/PhoneDown.js.map +1 -1
  176. package/dist/commonjs/icons/PinVertical.js +8 -6
  177. package/dist/commonjs/icons/PinVertical.js.map +1 -1
  178. package/dist/commonjs/icons/Reaction.js +8 -6
  179. package/dist/commonjs/icons/Reaction.js.map +1 -1
  180. package/dist/commonjs/icons/ScreenShare.js +8 -6
  181. package/dist/commonjs/icons/ScreenShare.js.map +1 -1
  182. package/dist/commonjs/icons/ScreenShareIndicator.js +21 -18
  183. package/dist/commonjs/icons/ScreenShareIndicator.js.map +1 -1
  184. package/dist/commonjs/icons/StartStreamIcon.js +8 -6
  185. package/dist/commonjs/icons/StartStreamIcon.js.map +1 -1
  186. package/dist/commonjs/icons/StopScreenShare.js +11 -9
  187. package/dist/commonjs/icons/StopScreenShare.js.map +1 -1
  188. package/dist/commonjs/icons/Video.js +8 -6
  189. package/dist/commonjs/icons/Video.js.map +1 -1
  190. package/dist/commonjs/icons/VideoSlash.js +8 -6
  191. package/dist/commonjs/icons/VideoSlash.js.map +1 -1
  192. package/dist/commonjs/icons/index.js +0 -66
  193. package/dist/commonjs/icons/index.js.map +1 -1
  194. package/dist/commonjs/package.json +1 -0
  195. package/dist/commonjs/providers/BusyTonePlayer.js +7 -7
  196. package/dist/commonjs/providers/BusyTonePlayer.js.map +1 -1
  197. package/dist/commonjs/providers/NoiseCancellation/NoiseCancellationProvider.js +5 -3
  198. package/dist/commonjs/providers/NoiseCancellation/NoiseCancellationProvider.js.map +1 -1
  199. package/dist/commonjs/providers/StreamCall/AppStateListener.js +3 -0
  200. package/dist/commonjs/providers/StreamCall/AppStateListener.js.map +1 -1
  201. package/dist/commonjs/providers/StreamCall/DeviceStats.js +1 -1
  202. package/dist/commonjs/providers/StreamCall/DeviceStats.js.map +1 -1
  203. package/dist/commonjs/providers/StreamCall/index.js +5 -3
  204. package/dist/commonjs/providers/StreamCall/index.js.map +1 -1
  205. package/dist/commonjs/providers/StreamVideo.js +10 -5
  206. package/dist/commonjs/providers/StreamVideo.js.map +1 -1
  207. package/dist/commonjs/utils/StreamVideoRN/index.js +0 -1
  208. package/dist/commonjs/utils/StreamVideoRN/index.js.map +1 -1
  209. package/dist/commonjs/utils/internal/callingx/callingx.js +4 -4
  210. package/dist/commonjs/utils/internal/callingx/callingx.js.map +1 -1
  211. package/dist/commonjs/utils/internal/registerSDKGlobals.js +2 -2
  212. package/dist/commonjs/utils/internal/registerSDKGlobals.js.map +1 -1
  213. package/dist/commonjs/utils/push/libs/firebaseMessaging/index.js.map +1 -1
  214. package/dist/commonjs/version.js +1 -1
  215. package/dist/module/components/Call/CallContent/CallContent.js +95 -48
  216. package/dist/module/components/Call/CallContent/CallContent.js.map +1 -1
  217. package/dist/module/components/Call/CallContent/RTCViewPipIOS.js +24 -20
  218. package/dist/module/components/Call/CallContent/RTCViewPipIOS.js.map +1 -1
  219. package/dist/module/components/Call/CallContent/RTCViewPipNative.js +4 -1
  220. package/dist/module/components/Call/CallContent/RTCViewPipNative.js.map +1 -1
  221. package/dist/module/components/Call/CallContent/index.js +2 -0
  222. package/dist/module/components/Call/CallContent/index.js.map +1 -1
  223. package/dist/module/components/Call/CallControls/AcceptCallButton.js +12 -7
  224. package/dist/module/components/Call/CallControls/AcceptCallButton.js.map +1 -1
  225. package/dist/module/components/Call/CallControls/CallControls.js +9 -6
  226. package/dist/module/components/Call/CallControls/CallControls.js.map +1 -1
  227. package/dist/module/components/Call/CallControls/CallControlsButton.js +13 -8
  228. package/dist/module/components/Call/CallControls/CallControlsButton.js.map +1 -1
  229. package/dist/module/components/Call/CallControls/HangupCallButton.js +12 -7
  230. package/dist/module/components/Call/CallControls/HangupCallButton.js.map +1 -1
  231. package/dist/module/components/Call/CallControls/IncomingCallControls.js +13 -10
  232. package/dist/module/components/Call/CallControls/IncomingCallControls.js.map +1 -1
  233. package/dist/module/components/Call/CallControls/LobbyControls.js +7 -3
  234. package/dist/module/components/Call/CallControls/LobbyControls.js.map +1 -1
  235. package/dist/module/components/Call/CallControls/OutgoingCallControls.js +14 -10
  236. package/dist/module/components/Call/CallControls/OutgoingCallControls.js.map +1 -1
  237. package/dist/module/components/Call/CallControls/ReactionsButton.js +24 -16
  238. package/dist/module/components/Call/CallControls/ReactionsButton.js.map +1 -1
  239. package/dist/module/components/Call/CallControls/RejectCallButton.js +12 -7
  240. package/dist/module/components/Call/CallControls/RejectCallButton.js.map +1 -1
  241. package/dist/module/components/Call/CallControls/ScreenShareToggleButton.js +17 -12
  242. package/dist/module/components/Call/CallControls/ScreenShareToggleButton.js.map +1 -1
  243. package/dist/module/components/Call/CallControls/ToggleAudioPreviewButton.js +15 -10
  244. package/dist/module/components/Call/CallControls/ToggleAudioPreviewButton.js.map +1 -1
  245. package/dist/module/components/Call/CallControls/ToggleAudioPublishingButton.js +20 -14
  246. package/dist/module/components/Call/CallControls/ToggleAudioPublishingButton.js.map +1 -1
  247. package/dist/module/components/Call/CallControls/ToggleCameraFaceButton.js +19 -13
  248. package/dist/module/components/Call/CallControls/ToggleCameraFaceButton.js.map +1 -1
  249. package/dist/module/components/Call/CallControls/ToggleVideoPreviewButton.js +15 -10
  250. package/dist/module/components/Call/CallControls/ToggleVideoPreviewButton.js.map +1 -1
  251. package/dist/module/components/Call/CallControls/ToggleVideoPublishingButton.js +19 -13
  252. package/dist/module/components/Call/CallControls/ToggleVideoPublishingButton.js.map +1 -1
  253. package/dist/module/components/Call/CallControls/index.js +2 -0
  254. package/dist/module/components/Call/CallControls/index.js.map +1 -1
  255. package/dist/module/components/Call/CallControls/internal/ReactionsPicker.js +41 -34
  256. package/dist/module/components/Call/CallControls/internal/ReactionsPicker.js.map +1 -1
  257. package/dist/module/components/Call/CallLayout/CallParticipantsGrid.js +19 -13
  258. package/dist/module/components/Call/CallLayout/CallParticipantsGrid.js.map +1 -1
  259. package/dist/module/components/Call/CallLayout/CallParticipantsSpotlight.js +38 -25
  260. package/dist/module/components/Call/CallLayout/CallParticipantsSpotlight.js.map +1 -1
  261. package/dist/module/components/Call/CallLayout/index.js +2 -0
  262. package/dist/module/components/Call/CallLayout/index.js.map +1 -1
  263. package/dist/module/components/Call/CallParticipantsList/CallParticipantsList.js +32 -28
  264. package/dist/module/components/Call/CallParticipantsList/CallParticipantsList.js.map +1 -1
  265. package/dist/module/components/Call/CallParticipantsList/index.js +2 -0
  266. package/dist/module/components/Call/CallParticipantsList/index.js.map +1 -1
  267. package/dist/module/components/Call/Lobby/JoinCallButton.js +12 -8
  268. package/dist/module/components/Call/Lobby/JoinCallButton.js.map +1 -1
  269. package/dist/module/components/Call/Lobby/Lobby.js +47 -36
  270. package/dist/module/components/Call/Lobby/Lobby.js.map +1 -1
  271. package/dist/module/components/Call/Lobby/LobbyFooter.js +23 -17
  272. package/dist/module/components/Call/Lobby/LobbyFooter.js.map +1 -1
  273. package/dist/module/components/Call/Lobby/index.js +2 -0
  274. package/dist/module/components/Call/Lobby/index.js.map +1 -1
  275. package/dist/module/components/Call/RingingCallContent/CallLeftIndicator.js +4 -1
  276. package/dist/module/components/Call/RingingCallContent/CallLeftIndicator.js.map +1 -1
  277. package/dist/module/components/Call/RingingCallContent/CallPreparingIndicator.js +4 -1
  278. package/dist/module/components/Call/RingingCallContent/CallPreparingIndicator.js.map +1 -1
  279. package/dist/module/components/Call/RingingCallContent/IncomingCall.js +34 -23
  280. package/dist/module/components/Call/RingingCallContent/IncomingCall.js.map +1 -1
  281. package/dist/module/components/Call/RingingCallContent/OutgoingCall.js +39 -28
  282. package/dist/module/components/Call/RingingCallContent/OutgoingCall.js.map +1 -1
  283. package/dist/module/components/Call/RingingCallContent/RingingCallContent.js +15 -12
  284. package/dist/module/components/Call/RingingCallContent/RingingCallContent.js.map +1 -1
  285. package/dist/module/components/Call/RingingCallContent/TextBasedIndicator.js +30 -22
  286. package/dist/module/components/Call/RingingCallContent/TextBasedIndicator.js.map +1 -1
  287. package/dist/module/components/Call/RingingCallContent/UserInfo.js +27 -22
  288. package/dist/module/components/Call/RingingCallContent/UserInfo.js.map +1 -1
  289. package/dist/module/components/Call/RingingCallContent/index.js +2 -0
  290. package/dist/module/components/Call/RingingCallContent/index.js.map +1 -1
  291. package/dist/module/components/Call/index.js +2 -0
  292. package/dist/module/components/Call/index.js.map +1 -1
  293. package/dist/module/components/Livestream/HostLivestream/HostLivestream.js +40 -35
  294. package/dist/module/components/Livestream/HostLivestream/HostLivestream.js.map +1 -1
  295. package/dist/module/components/Livestream/HostLivestream/index.js +2 -0
  296. package/dist/module/components/Livestream/HostLivestream/index.js.map +1 -1
  297. package/dist/module/components/Livestream/LivestreamControls/HostLivestreamControls.js +18 -13
  298. package/dist/module/components/Livestream/LivestreamControls/HostLivestreamControls.js.map +1 -1
  299. package/dist/module/components/Livestream/LivestreamControls/HostStartStreamButton.js +18 -13
  300. package/dist/module/components/Livestream/LivestreamControls/HostStartStreamButton.js.map +1 -1
  301. package/dist/module/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js +21 -14
  302. package/dist/module/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js.map +1 -1
  303. package/dist/module/components/Livestream/LivestreamControls/LivestreamMediaControls.js +7 -4
  304. package/dist/module/components/Livestream/LivestreamControls/LivestreamMediaControls.js.map +1 -1
  305. package/dist/module/components/Livestream/LivestreamControls/LivestreamScreenShareToggleButton.js +21 -16
  306. package/dist/module/components/Livestream/LivestreamControls/LivestreamScreenShareToggleButton.js.map +1 -1
  307. package/dist/module/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js +21 -14
  308. package/dist/module/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js.map +1 -1
  309. package/dist/module/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js +13 -9
  310. package/dist/module/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js.map +1 -1
  311. package/dist/module/components/Livestream/LivestreamControls/ViewerLivestreamControls.js +80 -58
  312. package/dist/module/components/Livestream/LivestreamControls/ViewerLivestreamControls.js.map +1 -1
  313. package/dist/module/components/Livestream/LivestreamControls/index.js +2 -0
  314. package/dist/module/components/Livestream/LivestreamControls/index.js.map +1 -1
  315. package/dist/module/components/Livestream/LivestreamLayout/LivestreamLayout.js +14 -46
  316. package/dist/module/components/Livestream/LivestreamLayout/LivestreamLayout.js.map +1 -1
  317. package/dist/module/components/Livestream/LivestreamLayout/index.js +2 -0
  318. package/dist/module/components/Livestream/LivestreamLayout/index.js.map +1 -1
  319. package/dist/module/components/Livestream/LivestreamPlayer/LivestreamEnded.js +52 -25
  320. package/dist/module/components/Livestream/LivestreamPlayer/LivestreamEnded.js.map +1 -1
  321. package/dist/module/components/Livestream/LivestreamPlayer/LivestreamPlayer.js +9 -5
  322. package/dist/module/components/Livestream/LivestreamPlayer/LivestreamPlayer.js.map +1 -1
  323. package/dist/module/components/Livestream/LivestreamPlayer/index.js +2 -0
  324. package/dist/module/components/Livestream/LivestreamPlayer/index.js.map +1 -1
  325. package/dist/module/components/Livestream/LivestreamTopView/DurationBadge.js +14 -10
  326. package/dist/module/components/Livestream/LivestreamTopView/DurationBadge.js.map +1 -1
  327. package/dist/module/components/Livestream/LivestreamTopView/FollowerCount.js +13 -8
  328. package/dist/module/components/Livestream/LivestreamTopView/FollowerCount.js.map +1 -1
  329. package/dist/module/components/Livestream/LivestreamTopView/HostLivestreamTopView.js +20 -14
  330. package/dist/module/components/Livestream/LivestreamTopView/HostLivestreamTopView.js.map +1 -1
  331. package/dist/module/components/Livestream/LivestreamTopView/LiveIndicator.js +12 -8
  332. package/dist/module/components/Livestream/LivestreamTopView/LiveIndicator.js.map +1 -1
  333. package/dist/module/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js +20 -14
  334. package/dist/module/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js.map +1 -1
  335. package/dist/module/components/Livestream/LivestreamTopView/index.js +2 -0
  336. package/dist/module/components/Livestream/LivestreamTopView/index.js.map +1 -1
  337. package/dist/module/components/Livestream/ViewerLivestream/ViewerLivestream.js +43 -38
  338. package/dist/module/components/Livestream/ViewerLivestream/ViewerLivestream.js.map +1 -1
  339. package/dist/module/components/Livestream/ViewerLivestream/ViewerLobby.js +35 -23
  340. package/dist/module/components/Livestream/ViewerLivestream/ViewerLobby.js.map +1 -1
  341. package/dist/module/components/Livestream/ViewerLivestream/index.js +2 -0
  342. package/dist/module/components/Livestream/ViewerLivestream/index.js.map +1 -1
  343. package/dist/module/components/Livestream/index.js +2 -0
  344. package/dist/module/components/Livestream/index.js.map +1 -1
  345. package/dist/module/components/Participant/FloatingParticipantView/FloatingView/AnimatedFloatingView.js +20 -15
  346. package/dist/module/components/Participant/FloatingParticipantView/FloatingView/AnimatedFloatingView.js.map +1 -1
  347. package/dist/module/components/Participant/FloatingParticipantView/FloatingView/ReanimatedFloatingView.js +22 -16
  348. package/dist/module/components/Participant/FloatingParticipantView/FloatingView/ReanimatedFloatingView.js.map +1 -1
  349. package/dist/module/components/Participant/FloatingParticipantView/FloatingView/common.js +2 -0
  350. package/dist/module/components/Participant/FloatingParticipantView/FloatingView/common.js.map +1 -1
  351. package/dist/module/components/Participant/FloatingParticipantView/FloatingView/index.js +2 -0
  352. package/dist/module/components/Participant/FloatingParticipantView/FloatingView/index.js.map +1 -1
  353. package/dist/module/components/Participant/FloatingParticipantView/index.js +56 -49
  354. package/dist/module/components/Participant/FloatingParticipantView/index.js.map +1 -1
  355. package/dist/module/components/Participant/FloatingParticipantView/useFloatingVideoDimensions.js +2 -0
  356. package/dist/module/components/Participant/FloatingParticipantView/useFloatingVideoDimensions.js.map +1 -1
  357. package/dist/module/components/Participant/ParticipantView/ParticipantLabel.js +66 -53
  358. package/dist/module/components/Participant/ParticipantView/ParticipantLabel.js.map +1 -1
  359. package/dist/module/components/Participant/ParticipantView/ParticipantNetworkQualityIndicator.js +32 -28
  360. package/dist/module/components/Participant/ParticipantView/ParticipantNetworkQualityIndicator.js.map +1 -1
  361. package/dist/module/components/Participant/ParticipantView/ParticipantReaction.js +13 -8
  362. package/dist/module/components/Participant/ParticipantView/ParticipantReaction.js.map +1 -1
  363. package/dist/module/components/Participant/ParticipantView/ParticipantVideoFallback.js +19 -15
  364. package/dist/module/components/Participant/ParticipantView/ParticipantVideoFallback.js.map +1 -1
  365. package/dist/module/components/Participant/ParticipantView/ParticipantView.js +29 -24
  366. package/dist/module/components/Participant/ParticipantView/ParticipantView.js.map +1 -1
  367. package/dist/module/components/Participant/ParticipantView/SpeechIndicator.js +10 -8
  368. package/dist/module/components/Participant/ParticipantView/SpeechIndicator.js.map +1 -1
  369. package/dist/module/components/Participant/ParticipantView/VideoRenderer/TrackSubscriber.js +2 -0
  370. package/dist/module/components/Participant/ParticipantView/VideoRenderer/TrackSubscriber.js.map +1 -1
  371. package/dist/module/components/Participant/ParticipantView/VideoRenderer/index.js +37 -31
  372. package/dist/module/components/Participant/ParticipantView/VideoRenderer/index.js.map +1 -1
  373. package/dist/module/components/Participant/ParticipantView/index.js +2 -0
  374. package/dist/module/components/Participant/ParticipantView/index.js.map +1 -1
  375. package/dist/module/components/Participant/index.js +2 -0
  376. package/dist/module/components/Participant/index.js.map +1 -1
  377. package/dist/module/components/index.js +2 -0
  378. package/dist/module/components/index.js.map +1 -1
  379. package/dist/module/components/utility/Avatar.js +20 -16
  380. package/dist/module/components/utility/Avatar.js.map +1 -1
  381. package/dist/module/components/utility/ScreenShareOverlay.js +37 -30
  382. package/dist/module/components/utility/ScreenShareOverlay.js.map +1 -1
  383. package/dist/module/components/utility/index.js +2 -0
  384. package/dist/module/components/utility/index.js.map +1 -1
  385. package/dist/module/constants/TestIds.js +2 -0
  386. package/dist/module/constants/TestIds.js.map +1 -1
  387. package/dist/module/constants/index.js +2 -0
  388. package/dist/module/constants/index.js.map +1 -1
  389. package/dist/module/contexts/BackgroundFilters.js +7 -4
  390. package/dist/module/contexts/BackgroundFilters.js.map +1 -1
  391. package/dist/module/contexts/ThemeContext.js +7 -4
  392. package/dist/module/contexts/ThemeContext.js.map +1 -1
  393. package/dist/module/contexts/index.js +2 -0
  394. package/dist/module/contexts/index.js.map +1 -1
  395. package/dist/module/contexts/internal/BackgroundFiltersContext.js +2 -0
  396. package/dist/module/contexts/internal/BackgroundFiltersContext.js.map +1 -1
  397. package/dist/module/contexts/internal/ScreenshotIosContext.js +7 -3
  398. package/dist/module/contexts/internal/ScreenshotIosContext.js.map +1 -1
  399. package/dist/module/hooks/index.js +3 -0
  400. package/dist/module/hooks/index.js.map +1 -1
  401. package/dist/module/hooks/push/index.js +2 -0
  402. package/dist/module/hooks/push/index.js.map +1 -1
  403. package/dist/module/hooks/push/useCallingExpWithCallingStateEffect.js +2 -0
  404. package/dist/module/hooks/push/useCallingExpWithCallingStateEffect.js.map +1 -1
  405. package/dist/module/hooks/push/useInitAndroidTokenAndRest.js +2 -0
  406. package/dist/module/hooks/push/useInitAndroidTokenAndRest.js.map +1 -1
  407. package/dist/module/hooks/push/useIosVoipPushEventsSetupEffect.js +2 -0
  408. package/dist/module/hooks/push/useIosVoipPushEventsSetupEffect.js.map +1 -1
  409. package/dist/module/hooks/useAndroidKeepCallAliveEffect.js +2 -0
  410. package/dist/module/hooks/useAndroidKeepCallAliveEffect.js.map +1 -1
  411. package/dist/module/hooks/useAutoEnterPiPEffect.js +7 -10
  412. package/dist/module/hooks/useAutoEnterPiPEffect.js.map +1 -1
  413. package/dist/module/hooks/useIsInPiPMode.js +2 -0
  414. package/dist/module/hooks/useIsInPiPMode.js.map +1 -1
  415. package/dist/module/hooks/useIsIosScreenshareBroadcastStarted.js +2 -0
  416. package/dist/module/hooks/useIsIosScreenshareBroadcastStarted.js.map +1 -1
  417. package/dist/module/hooks/useLoopbackRecording.js +260 -0
  418. package/dist/module/hooks/useLoopbackRecording.js.map +1 -0
  419. package/dist/module/hooks/useModeration.js +6 -1
  420. package/dist/module/hooks/useModeration.js.map +1 -1
  421. package/dist/module/hooks/usePaginatedLayoutSortPreset.js +2 -0
  422. package/dist/module/hooks/usePaginatedLayoutSortPreset.js.map +1 -1
  423. package/dist/module/hooks/usePermissionNotification.js +2 -0
  424. package/dist/module/hooks/usePermissionNotification.js.map +1 -1
  425. package/dist/module/hooks/usePermissionRequest.js +2 -0
  426. package/dist/module/hooks/usePermissionRequest.js.map +1 -1
  427. package/dist/module/hooks/useScreenShareAudioMixing.js +2 -0
  428. package/dist/module/hooks/useScreenShareAudioMixing.js.map +1 -1
  429. package/dist/module/hooks/useScreenShareButton.js +2 -0
  430. package/dist/module/hooks/useScreenShareButton.js.map +1 -1
  431. package/dist/module/hooks/useScreenshot.js +2 -0
  432. package/dist/module/hooks/useScreenshot.js.map +1 -1
  433. package/dist/module/hooks/useTrackDimensions.js +2 -0
  434. package/dist/module/hooks/useTrackDimensions.js.map +1 -1
  435. package/dist/module/icons/Back.js +10 -6
  436. package/dist/module/icons/Back.js.map +1 -1
  437. package/dist/module/icons/BadNetwork.js +13 -9
  438. package/dist/module/icons/BadNetwork.js.map +1 -1
  439. package/dist/module/icons/CameraSwitch.js +10 -6
  440. package/dist/module/icons/CameraSwitch.js.map +1 -1
  441. package/dist/module/icons/EndStreamIcon.js +10 -6
  442. package/dist/module/icons/EndStreamIcon.js.map +1 -1
  443. package/dist/module/icons/Eye.js +10 -6
  444. package/dist/module/icons/Eye.js.map +1 -1
  445. package/dist/module/icons/IconWrapper.js +7 -3
  446. package/dist/module/icons/IconWrapper.js.map +1 -1
  447. package/dist/module/icons/LivestreamControls.js +46 -39
  448. package/dist/module/icons/LivestreamControls.js.map +1 -1
  449. package/dist/module/icons/Lock.js +10 -6
  450. package/dist/module/icons/Lock.js.map +1 -1
  451. package/dist/module/icons/Maximize.js +35 -31
  452. package/dist/module/icons/Maximize.js.map +1 -1
  453. package/dist/module/icons/Mic.js +10 -6
  454. package/dist/module/icons/Mic.js.map +1 -1
  455. package/dist/module/icons/MicOff.js +10 -6
  456. package/dist/module/icons/MicOff.js.map +1 -1
  457. package/dist/module/icons/Phone.js +10 -6
  458. package/dist/module/icons/Phone.js.map +1 -1
  459. package/dist/module/icons/PhoneDown.js +10 -6
  460. package/dist/module/icons/PhoneDown.js.map +1 -1
  461. package/dist/module/icons/PinVertical.js +10 -6
  462. package/dist/module/icons/PinVertical.js.map +1 -1
  463. package/dist/module/icons/Reaction.js +10 -6
  464. package/dist/module/icons/Reaction.js.map +1 -1
  465. package/dist/module/icons/ScreenShare.js +10 -6
  466. package/dist/module/icons/ScreenShare.js.map +1 -1
  467. package/dist/module/icons/ScreenShareIndicator.js +23 -18
  468. package/dist/module/icons/ScreenShareIndicator.js.map +1 -1
  469. package/dist/module/icons/StartStreamIcon.js +10 -6
  470. package/dist/module/icons/StartStreamIcon.js.map +1 -1
  471. package/dist/module/icons/StopScreenShare.js +13 -9
  472. package/dist/module/icons/StopScreenShare.js.map +1 -1
  473. package/dist/module/icons/Video.js +10 -6
  474. package/dist/module/icons/Video.js.map +1 -1
  475. package/dist/module/icons/VideoSlash.js +10 -6
  476. package/dist/module/icons/VideoSlash.js.map +1 -1
  477. package/dist/module/icons/index.js +2 -6
  478. package/dist/module/icons/index.js.map +1 -1
  479. package/dist/module/index.js +2 -0
  480. package/dist/module/index.js.map +1 -1
  481. package/dist/module/modules/ScreenShareAudioManager.js +2 -0
  482. package/dist/module/modules/ScreenShareAudioManager.js.map +1 -1
  483. package/dist/module/modules/call-manager/CallManager.js +2 -0
  484. package/dist/module/modules/call-manager/CallManager.js.map +1 -1
  485. package/dist/module/modules/call-manager/PrevLibDetection.js +2 -0
  486. package/dist/module/modules/call-manager/PrevLibDetection.js.map +1 -1
  487. package/dist/module/modules/call-manager/index.js +2 -0
  488. package/dist/module/modules/call-manager/index.js.map +1 -1
  489. package/dist/module/modules/call-manager/native-module.d.js +2 -0
  490. package/dist/module/modules/call-manager/native-module.d.js.map +1 -1
  491. package/dist/module/modules/call-manager/types.js +1 -1
  492. package/dist/module/providers/BusyTonePlayer.js +9 -7
  493. package/dist/module/providers/BusyTonePlayer.js.map +1 -1
  494. package/dist/module/providers/NoiseCancellation/NoiseCancellationProvider.js +7 -4
  495. package/dist/module/providers/NoiseCancellation/NoiseCancellationProvider.js.map +1 -1
  496. package/dist/module/providers/NoiseCancellation/index.js +2 -0
  497. package/dist/module/providers/NoiseCancellation/index.js.map +1 -1
  498. package/dist/module/providers/NoiseCancellation/lib.js +2 -0
  499. package/dist/module/providers/NoiseCancellation/lib.js.map +1 -1
  500. package/dist/module/providers/StreamCall/AppStateListener.js +5 -0
  501. package/dist/module/providers/StreamCall/AppStateListener.js.map +1 -1
  502. package/dist/module/providers/StreamCall/AudioInterruptionTracer.js +2 -0
  503. package/dist/module/providers/StreamCall/AudioInterruptionTracer.js.map +1 -1
  504. package/dist/module/providers/StreamCall/DeviceStats.js +3 -1
  505. package/dist/module/providers/StreamCall/DeviceStats.js.map +1 -1
  506. package/dist/module/providers/StreamCall/index.js +7 -4
  507. package/dist/module/providers/StreamCall/index.js.map +1 -1
  508. package/dist/module/providers/StreamVideo.js +12 -5
  509. package/dist/module/providers/StreamVideo.js.map +1 -1
  510. package/dist/module/theme/colors.js +2 -0
  511. package/dist/module/theme/colors.js.map +1 -1
  512. package/dist/module/theme/constants.js +2 -0
  513. package/dist/module/theme/constants.js.map +1 -1
  514. package/dist/module/theme/index.js +2 -0
  515. package/dist/module/theme/index.js.map +1 -1
  516. package/dist/module/theme/theme.js +2 -0
  517. package/dist/module/theme/theme.js.map +1 -1
  518. package/dist/module/theme/types.js +2 -0
  519. package/dist/module/translations/index.js +2 -0
  520. package/dist/module/translations/index.js.map +1 -1
  521. package/dist/module/utils/StreamVideoRN/index.js +2 -1
  522. package/dist/module/utils/StreamVideoRN/index.js.map +1 -1
  523. package/dist/module/utils/StreamVideoRN/types.js +2 -0
  524. package/dist/module/utils/enterPiPAndroid.js +2 -0
  525. package/dist/module/utils/enterPiPAndroid.js.map +1 -1
  526. package/dist/module/utils/getAndroidDefaultRingtoneUrl.js +2 -0
  527. package/dist/module/utils/getAndroidDefaultRingtoneUrl.js.map +1 -1
  528. package/dist/module/utils/hooks/index.js +2 -0
  529. package/dist/module/utils/hooks/index.js.map +1 -1
  530. package/dist/module/utils/hooks/usePrevious.js +2 -0
  531. package/dist/module/utils/hooks/usePrevious.js.map +1 -1
  532. package/dist/module/utils/index.js +2 -0
  533. package/dist/module/utils/index.js.map +1 -1
  534. package/dist/module/utils/internal/callingx/audioSessionPromise.js +2 -0
  535. package/dist/module/utils/internal/callingx/audioSessionPromise.js.map +1 -1
  536. package/dist/module/utils/internal/callingx/callingx.js +6 -4
  537. package/dist/module/utils/internal/callingx/callingx.js.map +1 -1
  538. package/dist/module/utils/internal/optionallibs/gestureHandler.js +2 -0
  539. package/dist/module/utils/internal/optionallibs/gestureHandler.js.map +1 -1
  540. package/dist/module/utils/internal/optionallibs/index.js +2 -0
  541. package/dist/module/utils/internal/optionallibs/index.js.map +1 -1
  542. package/dist/module/utils/internal/optionallibs/reanimated.js +2 -0
  543. package/dist/module/utils/internal/optionallibs/reanimated.js.map +1 -1
  544. package/dist/module/utils/internal/pushLogoutCallback.js +2 -0
  545. package/dist/module/utils/internal/pushLogoutCallback.js.map +1 -1
  546. package/dist/module/utils/internal/registerSDKGlobals.js +4 -2
  547. package/dist/module/utils/internal/registerSDKGlobals.js.map +1 -1
  548. package/dist/module/utils/internal/rxSubjects.js +2 -0
  549. package/dist/module/utils/internal/rxSubjects.js.map +1 -1
  550. package/dist/module/utils/internal/shouldDisableIOSLocalVideoOnBackground.js +2 -0
  551. package/dist/module/utils/internal/shouldDisableIOSLocalVideoOnBackground.js.map +1 -1
  552. package/dist/module/utils/keepCallAliveHeadlessTask.js +2 -0
  553. package/dist/module/utils/keepCallAliveHeadlessTask.js.map +1 -1
  554. package/dist/module/utils/push/android.js +2 -0
  555. package/dist/module/utils/push/android.js.map +1 -1
  556. package/dist/module/utils/push/index.js +2 -0
  557. package/dist/module/utils/push/index.js.map +1 -1
  558. package/dist/module/utils/push/internal/constants.js +2 -0
  559. package/dist/module/utils/push/internal/constants.js.map +1 -1
  560. package/dist/module/utils/push/internal/ios.js +2 -0
  561. package/dist/module/utils/push/internal/ios.js.map +1 -1
  562. package/dist/module/utils/push/internal/utils.js +2 -0
  563. package/dist/module/utils/push/internal/utils.js.map +1 -1
  564. package/dist/module/utils/push/libs/callingx.js +2 -0
  565. package/dist/module/utils/push/libs/callingx.js.map +1 -1
  566. package/dist/module/utils/push/libs/firebaseMessaging/index.js +2 -0
  567. package/dist/module/utils/push/libs/firebaseMessaging/index.js.map +1 -1
  568. package/dist/module/utils/push/libs/firebaseMessaging/lib.js +2 -0
  569. package/dist/module/utils/push/libs/firebaseMessaging/lib.js.map +1 -1
  570. package/dist/module/utils/push/libs/index.js +2 -0
  571. package/dist/module/utils/push/libs/index.js.map +1 -1
  572. package/dist/module/utils/push/setupCallingExpEvents.js +2 -0
  573. package/dist/module/utils/push/setupCallingExpEvents.js.map +1 -1
  574. package/dist/module/utils/push/setupIosVoipPushEvents.js +2 -0
  575. package/dist/module/utils/push/setupIosVoipPushEvents.js.map +1 -1
  576. package/dist/module/utils/push/utils.js +2 -0
  577. package/dist/module/utils/push/utils.js.map +1 -1
  578. package/dist/module/utils/setClientDetails.js +2 -0
  579. package/dist/module/utils/setClientDetails.js.map +1 -1
  580. package/dist/module/version.js +3 -1
  581. package/dist/module/version.js.map +1 -1
  582. package/dist/typescript/components/Call/CallContent/CallContent.d.ts.map +1 -1
  583. package/dist/typescript/components/Call/CallLayout/CallParticipantsGrid.d.ts.map +1 -1
  584. package/dist/typescript/components/Call/CallLayout/CallParticipantsSpotlight.d.ts.map +1 -1
  585. package/dist/typescript/components/Call/CallParticipantsList/CallParticipantsList.d.ts.map +1 -1
  586. package/dist/typescript/components/Call/Lobby/Lobby.d.ts.map +1 -1
  587. package/dist/typescript/components/Livestream/HostLivestream/HostLivestream.d.ts.map +1 -1
  588. package/dist/typescript/components/Livestream/LivestreamLayout/LivestreamLayout.d.ts.map +1 -1
  589. package/dist/typescript/components/Livestream/LivestreamPlayer/LivestreamEnded.d.ts.map +1 -1
  590. package/dist/typescript/components/Livestream/ViewerLivestream/ViewerLivestream.d.ts.map +1 -1
  591. package/dist/typescript/components/Participant/FloatingParticipantView/index.d.ts.map +1 -1
  592. package/dist/typescript/components/Participant/ParticipantView/ParticipantView.d.ts +1 -1
  593. package/dist/typescript/components/Participant/ParticipantView/ParticipantView.d.ts.map +1 -1
  594. package/dist/typescript/components/Participant/ParticipantView/VideoRenderer/index.d.ts +1 -1
  595. package/dist/typescript/components/Participant/ParticipantView/VideoRenderer/index.d.ts.map +1 -1
  596. package/dist/typescript/contexts/BackgroundFilters.d.ts +1 -1
  597. package/dist/typescript/contexts/BackgroundFilters.d.ts.map +1 -1
  598. package/dist/typescript/hooks/index.d.ts +1 -0
  599. package/dist/typescript/hooks/index.d.ts.map +1 -1
  600. package/dist/typescript/hooks/useAutoEnterPiPEffect.d.ts.map +1 -1
  601. package/dist/typescript/hooks/useLoopbackRecording.d.ts +85 -0
  602. package/dist/typescript/hooks/useLoopbackRecording.d.ts.map +1 -0
  603. package/dist/typescript/hooks/useModeration.d.ts.map +1 -1
  604. package/dist/typescript/icons/index.d.ts +0 -6
  605. package/dist/typescript/icons/index.d.ts.map +1 -1
  606. package/dist/typescript/providers/StreamCall/AppStateListener.d.ts.map +1 -1
  607. package/dist/typescript/providers/StreamCall/DeviceStats.d.ts.map +1 -1
  608. package/dist/typescript/utils/StreamVideoRN/index.d.ts +0 -1
  609. package/dist/typescript/utils/StreamVideoRN/index.d.ts.map +1 -1
  610. package/dist/typescript/utils/internal/callingx/callingx.d.ts.map +1 -1
  611. package/dist/typescript/utils/push/libs/firebaseMessaging/index.d.ts +2 -16
  612. package/dist/typescript/utils/push/libs/firebaseMessaging/index.d.ts.map +1 -1
  613. package/dist/typescript/version.d.ts +1 -1
  614. package/ios/StreamVideoReactNative-Bridging-Header.h +2 -0
  615. package/ios/StreamVideoReactNative.m +81 -0
  616. package/ios/TracksRecorder/AudioPipeline.swift +270 -0
  617. package/ios/TracksRecorder/PipelineHost.swift +56 -0
  618. package/ios/TracksRecorder/RecorderAudioRenderTap.swift +144 -0
  619. package/ios/TracksRecorder/RecorderVideoSink.swift +137 -0
  620. package/ios/TracksRecorder/TracksRecorderManager.swift +333 -0
  621. package/ios/TracksRecorder/VideoPipeline.swift +297 -0
  622. package/package.json +10 -8
  623. package/src/components/Call/CallContent/CallContent.tsx +69 -39
  624. package/src/components/Call/CallLayout/CallParticipantsGrid.tsx +4 -6
  625. package/src/components/Call/CallLayout/CallParticipantsSpotlight.tsx +30 -21
  626. package/src/components/Call/CallParticipantsList/CallParticipantsList.tsx +23 -9
  627. package/src/components/Call/Lobby/Lobby.tsx +9 -5
  628. package/src/components/Livestream/HostLivestream/HostLivestream.tsx +5 -6
  629. package/src/components/Livestream/LivestreamControls/ViewerLivestreamControls.tsx +1 -1
  630. package/src/components/Livestream/LivestreamLayout/LivestreamLayout.tsx +4 -64
  631. package/src/components/Livestream/LivestreamPlayer/LivestreamEnded.tsx +54 -18
  632. package/src/components/Livestream/LivestreamTopView/DurationBadge.tsx +2 -2
  633. package/src/components/Livestream/ViewerLivestream/ViewerLivestream.tsx +10 -12
  634. package/src/components/Participant/FloatingParticipantView/index.tsx +26 -18
  635. package/src/components/Participant/ParticipantView/ParticipantReaction.tsx +1 -1
  636. package/src/components/Participant/ParticipantView/ParticipantView.tsx +68 -64
  637. package/src/components/Participant/ParticipantView/VideoRenderer/index.tsx +192 -179
  638. package/src/hooks/index.ts +1 -0
  639. package/src/hooks/useAutoEnterPiPEffect.tsx +5 -11
  640. package/src/hooks/useLoopbackRecording.ts +448 -0
  641. package/src/hooks/useModeration.ts +4 -1
  642. package/src/icons/index.tsx +0 -6
  643. package/src/providers/BusyTonePlayer.tsx +11 -11
  644. package/src/providers/StreamCall/AppStateListener.tsx +3 -0
  645. package/src/providers/StreamCall/DeviceStats.tsx +2 -1
  646. package/src/utils/StreamVideoRN/index.ts +0 -1
  647. package/src/utils/internal/callingx/callingx.ts +20 -10
  648. package/src/utils/internal/registerSDKGlobals.ts +2 -2
  649. package/src/utils/push/libs/firebaseMessaging/index.ts +4 -2
  650. package/src/version.ts +1 -1
  651. package/dist/commonjs/icons/LeaveStreamIcon.js +0 -20
  652. package/dist/commonjs/icons/LeaveStreamIcon.js.map +0 -1
  653. package/dist/commonjs/icons/Settings.js +0 -22
  654. package/dist/commonjs/icons/Settings.js.map +0 -1
  655. package/dist/commonjs/icons/ShieldBadge.js +0 -20
  656. package/dist/commonjs/icons/ShieldBadge.js.map +0 -1
  657. package/dist/commonjs/icons/Spotlight.js +0 -21
  658. package/dist/commonjs/icons/Spotlight.js.map +0 -1
  659. package/dist/commonjs/icons/ThreeDots.js +0 -31
  660. package/dist/commonjs/icons/ThreeDots.js.map +0 -1
  661. package/dist/commonjs/icons/TopViewBackground.js +0 -35
  662. package/dist/commonjs/icons/TopViewBackground.js.map +0 -1
  663. package/dist/module/icons/LeaveStreamIcon.js +0 -12
  664. package/dist/module/icons/LeaveStreamIcon.js.map +0 -1
  665. package/dist/module/icons/Settings.js +0 -13
  666. package/dist/module/icons/Settings.js.map +0 -1
  667. package/dist/module/icons/ShieldBadge.js +0 -12
  668. package/dist/module/icons/ShieldBadge.js.map +0 -1
  669. package/dist/module/icons/Spotlight.js +0 -13
  670. package/dist/module/icons/Spotlight.js.map +0 -1
  671. package/dist/module/icons/ThreeDots.js +0 -23
  672. package/dist/module/icons/ThreeDots.js.map +0 -1
  673. package/dist/module/icons/TopViewBackground.js +0 -27
  674. package/dist/module/icons/TopViewBackground.js.map +0 -1
  675. package/dist/typescript/icons/LeaveStreamIcon.d.ts +0 -3
  676. package/dist/typescript/icons/LeaveStreamIcon.d.ts.map +0 -1
  677. package/dist/typescript/icons/Settings.d.ts +0 -7
  678. package/dist/typescript/icons/Settings.d.ts.map +0 -1
  679. package/dist/typescript/icons/ShieldBadge.d.ts +0 -3
  680. package/dist/typescript/icons/ShieldBadge.d.ts.map +0 -1
  681. package/dist/typescript/icons/Spotlight.d.ts +0 -8
  682. package/dist/typescript/icons/Spotlight.d.ts.map +0 -1
  683. package/dist/typescript/icons/ThreeDots.d.ts +0 -7
  684. package/dist/typescript/icons/ThreeDots.d.ts.map +0 -1
  685. package/dist/typescript/icons/TopViewBackground.d.ts +0 -15
  686. package/dist/typescript/icons/TopViewBackground.d.ts.map +0 -1
  687. package/src/icons/LeaveStreamIcon.tsx +0 -13
  688. package/src/icons/Settings.tsx +0 -14
  689. package/src/icons/ShieldBadge.tsx +0 -13
  690. package/src/icons/Spotlight.tsx +0 -18
  691. package/src/icons/ThreeDots.tsx +0 -14
  692. package/src/icons/TopViewBackground.tsx +0 -43
@@ -44,188 +44,201 @@ export type VideoRendererProps = Pick<
44
44
  *
45
45
  * It internally used `RTCView` to render video stream.
46
46
  */
47
- export const VideoRenderer = ({
48
- trackType = 'videoTrack',
49
- participant,
50
- isVisible = true,
51
- ParticipantVideoFallback = DefaultParticipantVideoFallback,
52
- objectFit,
53
- videoZOrder = 0,
54
- mirror: mirrorOverride,
55
- }: VideoRendererProps) => {
56
- const {
57
- theme: { videoRenderer },
58
- } = useTheme();
59
- const call = useCall();
60
- const { useCameraState, useIncomingVideoSettings } = useCallStateHooks();
61
- const trackSubscriberRef = useRef<TrackSubscriberHandle>(null);
62
- const { isParticipantVideoEnabled } = useIncomingVideoSettings();
63
- const { direction } = useCameraState();
64
- const viewRef = useRef(null);
65
- const {
66
- register: registerIosScreenshot,
67
- deregister: deregisterIosScreenshot,
68
- } = useScreenshotIosContext();
69
-
70
- const videoDimensions = useTrackDimensions(participant, trackType);
71
-
72
- const isVideoDimensionsValid =
73
- videoDimensions.width > 0 && videoDimensions.height > 0;
74
-
75
- const {
76
- isLocalParticipant,
77
- sessionId,
78
- viewportVisibilityState,
79
- videoStream,
80
- screenShareStream,
81
- } = participant;
82
-
83
- const isScreenSharing = trackType === 'screenShareTrack';
84
- const isPublishingVideoTrack = isScreenSharing
85
- ? hasScreenShare(participant)
86
- : hasVideo(participant);
87
-
88
- const videoStreamToRender = (isScreenSharing
89
- ? screenShareStream
90
- : videoStream) as unknown as MediaStream | undefined;
91
-
92
- const canShowVideo =
93
- !!videoStreamToRender &&
94
- isVisible &&
95
- isPublishingVideoTrack &&
96
- !hasPausedTrack(participant, trackType) &&
97
- isParticipantVideoEnabled(participant.sessionId);
98
-
99
- useEffect(() => {
100
- if (Platform.OS === 'ios' && registerIosScreenshot && canShowVideo) {
47
+ export const VideoRenderer = React.memo(
48
+ ({
49
+ trackType = 'videoTrack',
50
+ participant,
51
+ isVisible = true,
52
+ ParticipantVideoFallback = DefaultParticipantVideoFallback,
53
+ objectFit,
54
+ videoZOrder = 0,
55
+ mirror: mirrorOverride,
56
+ }: VideoRendererProps) => {
57
+ const {
58
+ theme: { videoRenderer },
59
+ } = useTheme();
60
+ const call = useCall();
61
+ const { useCameraState, useIncomingVideoSettings } = useCallStateHooks();
62
+ const trackSubscriberRef = useRef<TrackSubscriberHandle>(null);
63
+ const { isParticipantVideoEnabled } = useIncomingVideoSettings();
64
+ const { direction } = useCameraState();
65
+ const viewRef = useRef(null);
66
+ const {
67
+ register: registerIosScreenshot,
68
+ deregister: deregisterIosScreenshot,
69
+ } = useScreenshotIosContext();
70
+
71
+ const videoDimensions = useTrackDimensions(participant, trackType);
72
+
73
+ const isVideoDimensionsValid =
74
+ videoDimensions.width > 0 && videoDimensions.height > 0;
75
+
76
+ const {
77
+ isLocalParticipant,
78
+ sessionId,
79
+ viewportVisibilityState,
80
+ videoStream,
81
+ screenShareStream,
82
+ } = participant;
83
+
84
+ const isScreenSharing = trackType === 'screenShareTrack';
85
+ const isPublishingVideoTrack = isScreenSharing
86
+ ? hasScreenShare(participant)
87
+ : hasVideo(participant);
88
+
89
+ const videoStreamToRender = (isScreenSharing
90
+ ? screenShareStream
91
+ : videoStream) as unknown as MediaStream | undefined;
92
+
93
+ const canShowVideo =
94
+ !!videoStreamToRender &&
95
+ isVisible &&
96
+ isPublishingVideoTrack &&
97
+ !hasPausedTrack(participant, trackType) &&
98
+ isParticipantVideoEnabled(participant.sessionId);
99
+
100
+ useEffect(() => {
101
+ if (Platform.OS !== 'ios' || !registerIosScreenshot || !canShowVideo)
102
+ return;
101
103
  registerIosScreenshot(participant, trackType, viewRef);
102
104
  return () => {
103
105
  deregisterIosScreenshot(participant, trackType);
104
106
  };
105
- }
106
- }, [
107
- participant,
108
- trackType,
109
- registerIosScreenshot,
110
- canShowVideo,
111
- deregisterIosScreenshot,
112
- ]);
113
-
114
- const mirror = isScreenSharing
115
- ? false
116
- : mirrorOverride !== undefined
117
- ? mirrorOverride
118
- : isLocalParticipant && direction === 'front';
119
-
120
- /**
121
- * This effect updates the participant's viewportVisibilityState
122
- * Additionally makes sure that when this view becomes visible again, the layout to subscribe is known
123
- */
124
- useEffect(() => {
125
- if (!call || isLocalParticipant) {
126
- return;
127
- }
128
- if (isVisible) {
129
- if (
130
- trackType === 'videoTrack' &&
131
- viewportVisibilityState?.videoTrack !== VisibilityState.VISIBLE
132
- ) {
133
- call.state.updateParticipant(sessionId, (p) => ({
134
- ...p,
135
- viewportVisibilityState: {
136
- ...(p.viewportVisibilityState ?? DEFAULT_VIEWPORT_VISIBILITY_STATE),
137
- videoTrack: VisibilityState.VISIBLE,
138
- },
139
- }));
140
- }
141
- if (
142
- trackType === 'screenShareTrack' &&
143
- viewportVisibilityState?.screenShareTrack !== VisibilityState.VISIBLE
144
- ) {
145
- call.state.updateParticipant(sessionId, (p) => ({
146
- ...p,
147
- viewportVisibilityState: {
148
- ...(p.viewportVisibilityState ?? DEFAULT_VIEWPORT_VISIBILITY_STATE),
149
- screenShareTrack: VisibilityState.VISIBLE,
150
- },
151
- }));
152
- }
153
- } else {
154
- if (
155
- trackType === 'videoTrack' &&
156
- viewportVisibilityState?.videoTrack !== VisibilityState.INVISIBLE
157
- ) {
158
- call.state.updateParticipant(sessionId, (p) => ({
159
- ...p,
160
- viewportVisibilityState: {
161
- ...(p.viewportVisibilityState ?? DEFAULT_VIEWPORT_VISIBILITY_STATE),
162
- videoTrack: VisibilityState.INVISIBLE,
163
- },
164
- }));
107
+ }, [
108
+ participant,
109
+ trackType,
110
+ registerIosScreenshot,
111
+ canShowVideo,
112
+ deregisterIosScreenshot,
113
+ ]);
114
+
115
+ const mirror = isScreenSharing
116
+ ? false
117
+ : mirrorOverride !== undefined
118
+ ? mirrorOverride
119
+ : isLocalParticipant && direction === 'front';
120
+
121
+ const videoTrackVisibility = viewportVisibilityState?.videoTrack;
122
+ const screenShareTrackVisibility =
123
+ viewportVisibilityState?.screenShareTrack;
124
+
125
+ /**
126
+ * This effect updates the participant's viewportVisibilityState
127
+ * Additionally makes sure that when this view becomes visible again, the layout to subscribe is known
128
+ */
129
+ useEffect(() => {
130
+ if (!call || isLocalParticipant) {
131
+ return;
165
132
  }
166
- if (
167
- trackType === 'screenShareTrack' &&
168
- viewportVisibilityState?.screenShareTrack !== VisibilityState.INVISIBLE
169
- ) {
170
- call.state.updateParticipant(sessionId, (p) => ({
171
- ...p,
172
- viewportVisibilityState: {
173
- ...(p.viewportVisibilityState ?? DEFAULT_VIEWPORT_VISIBILITY_STATE),
174
- screenShareTrack: VisibilityState.INVISIBLE,
175
- },
176
- }));
133
+ if (isVisible) {
134
+ if (
135
+ trackType === 'videoTrack' &&
136
+ videoTrackVisibility !== VisibilityState.VISIBLE
137
+ ) {
138
+ call.state.updateParticipant(sessionId, (p) => ({
139
+ ...p,
140
+ viewportVisibilityState: {
141
+ ...(p.viewportVisibilityState ??
142
+ DEFAULT_VIEWPORT_VISIBILITY_STATE),
143
+ videoTrack: VisibilityState.VISIBLE,
144
+ },
145
+ }));
146
+ }
147
+ if (
148
+ trackType === 'screenShareTrack' &&
149
+ screenShareTrackVisibility !== VisibilityState.VISIBLE
150
+ ) {
151
+ call.state.updateParticipant(sessionId, (p) => ({
152
+ ...p,
153
+ viewportVisibilityState: {
154
+ ...(p.viewportVisibilityState ??
155
+ DEFAULT_VIEWPORT_VISIBILITY_STATE),
156
+ screenShareTrack: VisibilityState.VISIBLE,
157
+ },
158
+ }));
159
+ }
160
+ } else {
161
+ if (
162
+ trackType === 'videoTrack' &&
163
+ videoTrackVisibility !== VisibilityState.INVISIBLE
164
+ ) {
165
+ call.state.updateParticipant(sessionId, (p) => ({
166
+ ...p,
167
+ viewportVisibilityState: {
168
+ ...(p.viewportVisibilityState ??
169
+ DEFAULT_VIEWPORT_VISIBILITY_STATE),
170
+ videoTrack: VisibilityState.INVISIBLE,
171
+ },
172
+ }));
173
+ }
174
+ if (
175
+ trackType === 'screenShareTrack' &&
176
+ screenShareTrackVisibility !== VisibilityState.INVISIBLE
177
+ ) {
178
+ call.state.updateParticipant(sessionId, (p) => ({
179
+ ...p,
180
+ viewportVisibilityState: {
181
+ ...(p.viewportVisibilityState ??
182
+ DEFAULT_VIEWPORT_VISIBILITY_STATE),
183
+ screenShareTrack: VisibilityState.INVISIBLE,
184
+ },
185
+ }));
186
+ }
177
187
  }
178
- }
179
- }, [
180
- sessionId,
181
- viewportVisibilityState,
182
- isVisible,
183
- call,
184
- trackType,
185
- isLocalParticipant,
186
- ]);
187
-
188
- const onLayout: React.ComponentProps<typeof RTCView>['onLayout'] = (
189
- event,
190
- ) => {
191
- trackSubscriberRef.current?.onLayoutUpdate(event);
192
- };
193
-
194
- return (
195
- <View
196
- onLayout={onLayout}
197
- style={[StyleSheet.absoluteFill, videoRenderer.container]}
198
- >
199
- {call && !isLocalParticipant && (
200
- <TrackSubscriber
201
- ref={trackSubscriberRef}
202
- call={call}
203
- participantSessionId={sessionId}
204
- trackType={trackType}
205
- isVisible={isVisible}
206
- />
207
- )}
208
- {canShowVideo &&
209
- videoStreamToRender &&
210
- (objectFit || isVideoDimensionsValid) ? (
211
- <RTCView
212
- style={[StyleSheet.absoluteFill, videoRenderer.videoStream]}
213
- streamURL={videoStreamToRender.toURL()}
214
- mirror={mirror}
215
- ref={viewRef}
216
- objectFit={
217
- objectFit ??
218
- (videoDimensions.width > videoDimensions.height
219
- ? 'contain'
220
- : 'cover')
221
- }
222
- zOrder={videoZOrder}
223
- />
224
- ) : (
225
- ParticipantVideoFallback && (
226
- <ParticipantVideoFallback participant={participant} />
227
- )
228
- )}
229
- </View>
230
- );
231
- };
188
+ }, [
189
+ sessionId,
190
+ videoTrackVisibility,
191
+ screenShareTrackVisibility,
192
+ isVisible,
193
+ call,
194
+ trackType,
195
+ isLocalParticipant,
196
+ ]);
197
+
198
+ const onLayout: React.ComponentProps<typeof RTCView>['onLayout'] = (
199
+ event,
200
+ ) => {
201
+ trackSubscriberRef.current?.onLayoutUpdate(event);
202
+ };
203
+
204
+ return (
205
+ <View
206
+ onLayout={onLayout}
207
+ style={[StyleSheet.absoluteFill, videoRenderer.container]}
208
+ >
209
+ {call && !isLocalParticipant && (
210
+ <TrackSubscriber
211
+ ref={trackSubscriberRef}
212
+ call={call}
213
+ participantSessionId={sessionId}
214
+ trackType={trackType}
215
+ isVisible={isVisible}
216
+ />
217
+ )}
218
+ {canShowVideo &&
219
+ videoStreamToRender &&
220
+ (objectFit || isVideoDimensionsValid) ? (
221
+ <RTCView
222
+ style={[StyleSheet.absoluteFill, videoRenderer.videoStream]}
223
+ streamURL={videoStreamToRender.toURL()}
224
+ mirror={mirror}
225
+ ref={viewRef}
226
+ objectFit={
227
+ objectFit ??
228
+ (videoDimensions.width > videoDimensions.height
229
+ ? 'contain'
230
+ : 'cover')
231
+ }
232
+ zOrder={videoZOrder}
233
+ />
234
+ ) : (
235
+ ParticipantVideoFallback && (
236
+ <ParticipantVideoFallback participant={participant} />
237
+ )
238
+ )}
239
+ </View>
240
+ );
241
+ },
242
+ );
243
+
244
+ VideoRenderer.displayName = 'VideoRenderer';
@@ -7,6 +7,7 @@ export * from './useIsInPiPMode';
7
7
  export * from './useAutoEnterPiPEffect';
8
8
  export * from './useScreenShareButton';
9
9
  export * from './useScreenShareAudioMixing';
10
+ export * from './useLoopbackRecording';
10
11
  export * from './useTrackDimensions';
11
12
  export * from './useScreenshot';
12
13
  export * from './useModeration';
@@ -31,20 +31,14 @@ export function useAutoEnterPiPEffect(
31
31
  return;
32
32
  }
33
33
 
34
- // on unmount always disable PiP mode auto enter
35
- return () => {
34
+ // if disable prop was sent, immediately disable PiP mode auto enter
35
+ if (disablePictureInPicture) {
36
36
  NativeModules.StreamVideoReactNative.canAutoEnterPipMode(false);
37
- };
38
- }, [disablePictureInPicture]);
39
-
40
- // if disable prop was sent, immediately disable PiP mode
41
- useEffect(() => {
42
- if (Platform.OS !== 'android') {
43
- return;
44
37
  }
45
38
 
46
- if (disablePictureInPicture) {
39
+ // on unmount always disable PiP mode auto enter
40
+ return () => {
47
41
  NativeModules.StreamVideoReactNative.canAutoEnterPipMode(false);
48
- }
42
+ };
49
43
  }, [disablePictureInPicture]);
50
44
  }