@stream-io/video-react-native-sdk 0.1.10 → 0.1.12
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.
- package/CHANGELOG.md +14 -0
- package/android/src/main/java/com/streamvideo/reactnative/StreamVideoReactNative.kt +19 -1
- package/android/src/main/java/com/streamvideo/reactnative/StreamVideoReactNativeModule.kt +82 -2
- package/dist/commonjs/components/Call/CallContent/CallContent.js +9 -7
- package/dist/commonjs/components/Call/CallContent/CallContent.js.map +1 -1
- package/dist/commonjs/components/Call/CallLayout/CallParticipantsGrid.js +7 -2
- package/dist/commonjs/components/Call/CallLayout/CallParticipantsGrid.js.map +1 -1
- package/dist/commonjs/components/Call/CallLayout/CallParticipantsSpotlight.js +3 -1
- package/dist/commonjs/components/Call/CallLayout/CallParticipantsSpotlight.js.map +1 -1
- package/dist/commonjs/components/Livestream/HostLivestream/HostLivestream.js +71 -0
- package/dist/commonjs/components/Livestream/HostLivestream/HostLivestream.js.map +1 -0
- package/dist/commonjs/components/Livestream/HostLivestream/index.js +17 -0
- package/dist/commonjs/components/Livestream/HostLivestream/index.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/HostLivestreamControls.js +69 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/HostLivestreamControls.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/HostStartStreamButton.js +113 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/HostStartStreamButton.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js +70 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamMediaControls.js +38 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamMediaControls.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js +70 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js +83 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLivestreamControls.js +64 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLivestreamControls.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/index.js +61 -0
- package/dist/commonjs/components/Livestream/LivestreamControls/index.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamLayout/LivestreamLayout.js +65 -0
- package/dist/commonjs/components/Livestream/LivestreamLayout/LivestreamLayout.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamLayout/index.js +17 -0
- package/dist/commonjs/components/Livestream/LivestreamLayout/index.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/DurationBadge.js +144 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/DurationBadge.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/FollowerCount.js +71 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/FollowerCount.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/HostLivestreamTopView.js +87 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/HostLivestreamTopView.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/LiveIndicator.js +55 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/LiveIndicator.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js +80 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js.map +1 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/index.js +50 -0
- package/dist/commonjs/components/Livestream/LivestreamTopView/index.js.map +1 -0
- package/dist/commonjs/components/Livestream/ViewerLivestream/ViewerLivestream.js +88 -0
- package/dist/commonjs/components/Livestream/ViewerLivestream/ViewerLivestream.js.map +1 -0
- package/dist/commonjs/components/Livestream/ViewerLivestream/index.js +17 -0
- package/dist/commonjs/components/Livestream/ViewerLivestream/index.js.map +1 -0
- package/dist/commonjs/components/Livestream/index.js +61 -0
- package/dist/commonjs/components/Livestream/index.js.map +1 -0
- package/dist/commonjs/components/index.js +11 -0
- package/dist/commonjs/components/index.js.map +1 -1
- package/dist/commonjs/hooks/index.js +22 -0
- package/dist/commonjs/hooks/index.js.map +1 -1
- package/dist/commonjs/hooks/useAutoEnterPiPEffect.js +20 -0
- package/dist/commonjs/hooks/useAutoEnterPiPEffect.js.map +1 -0
- package/dist/commonjs/hooks/useIsInPiPMode.js +25 -0
- package/dist/commonjs/hooks/useIsInPiPMode.js.map +1 -0
- package/dist/commonjs/hooks/usePaginatedLayoutSortPreset.js +26 -0
- package/dist/commonjs/hooks/usePaginatedLayoutSortPreset.js.map +1 -0
- package/dist/commonjs/icons/EndStreamIcon.js +20 -0
- package/dist/commonjs/icons/EndStreamIcon.js.map +1 -0
- package/dist/commonjs/icons/Eye.js +20 -0
- package/dist/commonjs/icons/Eye.js.map +1 -0
- package/dist/commonjs/icons/LeaveStreamIcon.js +20 -0
- package/dist/commonjs/icons/LeaveStreamIcon.js.map +1 -0
- package/dist/commonjs/icons/ShieldBadge.js +20 -0
- package/dist/commonjs/icons/ShieldBadge.js.map +1 -0
- package/dist/commonjs/icons/StartStreamIcon.js +20 -0
- package/dist/commonjs/icons/StartStreamIcon.js.map +1 -0
- package/dist/commonjs/icons/index.js +55 -0
- package/dist/commonjs/icons/index.js.map +1 -1
- package/dist/commonjs/providers/MediaStreamManagement.js +15 -2
- package/dist/commonjs/providers/MediaStreamManagement.js.map +1 -1
- package/dist/commonjs/theme/theme.js +70 -0
- package/dist/commonjs/theme/theme.js.map +1 -1
- package/dist/commonjs/translations/en.json +6 -1
- package/dist/commonjs/utils/enterPiPAndroid.js +15 -0
- package/dist/commonjs/utils/enterPiPAndroid.js.map +1 -0
- package/dist/commonjs/utils/index.js +12 -0
- package/dist/commonjs/utils/index.js.map +1 -1
- package/dist/commonjs/version.js +1 -1
- package/dist/module/components/Call/CallContent/CallContent.js +10 -7
- package/dist/module/components/Call/CallContent/CallContent.js.map +1 -1
- package/dist/module/components/Call/CallLayout/CallParticipantsGrid.js +7 -2
- package/dist/module/components/Call/CallLayout/CallParticipantsGrid.js.map +1 -1
- package/dist/module/components/Call/CallLayout/CallParticipantsSpotlight.js +3 -1
- package/dist/module/components/Call/CallLayout/CallParticipantsSpotlight.js.map +1 -1
- package/dist/module/components/Livestream/HostLivestream/HostLivestream.js +64 -0
- package/dist/module/components/Livestream/HostLivestream/HostLivestream.js.map +1 -0
- package/dist/module/components/Livestream/HostLivestream/index.js +2 -0
- package/dist/module/components/Livestream/HostLivestream/index.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamControls/HostLivestreamControls.js +62 -0
- package/dist/module/components/Livestream/LivestreamControls/HostLivestreamControls.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamControls/HostStartStreamButton.js +105 -0
- package/dist/module/components/Livestream/LivestreamControls/HostStartStreamButton.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js +63 -0
- package/dist/module/components/Livestream/LivestreamControls/LivestreamAudioControlButton.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamControls/LivestreamMediaControls.js +31 -0
- package/dist/module/components/Livestream/LivestreamControls/LivestreamMediaControls.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js +63 -0
- package/dist/module/components/Livestream/LivestreamControls/LivestreamVideoControlButton.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js +75 -0
- package/dist/module/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamControls/ViewerLivestreamControls.js +57 -0
- package/dist/module/components/Livestream/LivestreamControls/ViewerLivestreamControls.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamControls/index.js +6 -0
- package/dist/module/components/Livestream/LivestreamControls/index.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamLayout/LivestreamLayout.js +58 -0
- package/dist/module/components/Livestream/LivestreamLayout/LivestreamLayout.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamLayout/index.js +2 -0
- package/dist/module/components/Livestream/LivestreamLayout/index.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamTopView/DurationBadge.js +136 -0
- package/dist/module/components/Livestream/LivestreamTopView/DurationBadge.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamTopView/FollowerCount.js +64 -0
- package/dist/module/components/Livestream/LivestreamTopView/FollowerCount.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamTopView/HostLivestreamTopView.js +80 -0
- package/dist/module/components/Livestream/LivestreamTopView/HostLivestreamTopView.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamTopView/LiveIndicator.js +48 -0
- package/dist/module/components/Livestream/LivestreamTopView/LiveIndicator.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js +73 -0
- package/dist/module/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.js.map +1 -0
- package/dist/module/components/Livestream/LivestreamTopView/index.js +5 -0
- package/dist/module/components/Livestream/LivestreamTopView/index.js.map +1 -0
- package/dist/module/components/Livestream/ViewerLivestream/ViewerLivestream.js +81 -0
- package/dist/module/components/Livestream/ViewerLivestream/ViewerLivestream.js.map +1 -0
- package/dist/module/components/Livestream/ViewerLivestream/index.js +2 -0
- package/dist/module/components/Livestream/ViewerLivestream/index.js.map +1 -0
- package/dist/module/components/Livestream/index.js +6 -0
- package/dist/module/components/Livestream/index.js.map +1 -0
- package/dist/module/components/index.js +1 -0
- package/dist/module/components/index.js.map +1 -1
- package/dist/module/hooks/index.js +2 -0
- package/dist/module/hooks/index.js.map +1 -1
- package/dist/module/hooks/useAutoEnterPiPEffect.js +14 -0
- package/dist/module/hooks/useAutoEnterPiPEffect.js.map +1 -0
- package/dist/module/hooks/useIsInPiPMode.js +19 -0
- package/dist/module/hooks/useIsInPiPMode.js.map +1 -0
- package/dist/module/hooks/usePaginatedLayoutSortPreset.js +19 -0
- package/dist/module/hooks/usePaginatedLayoutSortPreset.js.map +1 -0
- package/dist/module/icons/EndStreamIcon.js +12 -0
- package/dist/module/icons/EndStreamIcon.js.map +1 -0
- package/dist/module/icons/Eye.js +12 -0
- package/dist/module/icons/Eye.js.map +1 -0
- package/dist/module/icons/LeaveStreamIcon.js +12 -0
- package/dist/module/icons/LeaveStreamIcon.js.map +1 -0
- package/dist/module/icons/ShieldBadge.js +12 -0
- package/dist/module/icons/ShieldBadge.js.map +1 -0
- package/dist/module/icons/StartStreamIcon.js +12 -0
- package/dist/module/icons/StartStreamIcon.js.map +1 -0
- package/dist/module/icons/index.js +5 -0
- package/dist/module/icons/index.js.map +1 -1
- package/dist/module/providers/MediaStreamManagement.js +15 -2
- package/dist/module/providers/MediaStreamManagement.js.map +1 -1
- package/dist/module/theme/theme.js +70 -0
- package/dist/module/theme/theme.js.map +1 -1
- package/dist/module/translations/en.json +6 -1
- package/dist/module/utils/enterPiPAndroid.js +9 -0
- package/dist/module/utils/enterPiPAndroid.js.map +1 -0
- package/dist/module/utils/index.js +1 -0
- package/dist/module/utils/index.js.map +1 -1
- package/dist/module/version.js +1 -1
- package/dist/typescript/components/Call/CallContent/CallContent.d.ts.map +1 -1
- package/dist/typescript/components/Call/CallLayout/CallParticipantsGrid.d.ts.map +1 -1
- package/dist/typescript/components/Call/CallLayout/CallParticipantsSpotlight.d.ts.map +1 -1
- package/dist/typescript/components/Livestream/HostLivestream/HostLivestream.d.ts +30 -0
- package/dist/typescript/components/Livestream/HostLivestream/HostLivestream.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/HostLivestream/index.d.ts +2 -0
- package/dist/typescript/components/Livestream/HostLivestream/index.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamControls/HostLivestreamControls.d.ts +25 -0
- package/dist/typescript/components/Livestream/LivestreamControls/HostLivestreamControls.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamControls/HostStartStreamButton.d.ts +25 -0
- package/dist/typescript/components/Livestream/LivestreamControls/HostStartStreamButton.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamControls/LivestreamAudioControlButton.d.ts +6 -0
- package/dist/typescript/components/Livestream/LivestreamControls/LivestreamAudioControlButton.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamControls/LivestreamMediaControls.d.ts +10 -0
- package/dist/typescript/components/Livestream/LivestreamControls/LivestreamMediaControls.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamControls/LivestreamVideoControlButton.d.ts +6 -0
- package/dist/typescript/components/Livestream/LivestreamControls/LivestreamVideoControlButton.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.d.ts +16 -0
- package/dist/typescript/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamControls/ViewerLivestreamControls.d.ts +16 -0
- package/dist/typescript/components/Livestream/LivestreamControls/ViewerLivestreamControls.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamControls/index.d.ts +6 -0
- package/dist/typescript/components/Livestream/LivestreamControls/index.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamLayout/LivestreamLayout.d.ts +17 -0
- package/dist/typescript/components/Livestream/LivestreamLayout/LivestreamLayout.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamLayout/index.d.ts +2 -0
- package/dist/typescript/components/Livestream/LivestreamLayout/index.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/DurationBadge.d.ts +12 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/DurationBadge.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/FollowerCount.d.ts +10 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/FollowerCount.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/HostLivestreamTopView.d.ts +26 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/HostLivestreamTopView.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/LiveIndicator.d.ts +10 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/LiveIndicator.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.d.ts +26 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/index.d.ts +5 -0
- package/dist/typescript/components/Livestream/LivestreamTopView/index.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/ViewerLivestream/ViewerLivestream.d.ts +32 -0
- package/dist/typescript/components/Livestream/ViewerLivestream/ViewerLivestream.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/ViewerLivestream/index.d.ts +2 -0
- package/dist/typescript/components/Livestream/ViewerLivestream/index.d.ts.map +1 -0
- package/dist/typescript/components/Livestream/index.d.ts +6 -0
- package/dist/typescript/components/Livestream/index.d.ts.map +1 -0
- package/dist/typescript/components/index.d.ts +1 -0
- package/dist/typescript/components/index.d.ts.map +1 -1
- package/dist/typescript/hooks/index.d.ts +2 -0
- package/dist/typescript/hooks/index.d.ts.map +1 -1
- package/dist/typescript/hooks/useAutoEnterPiPEffect.d.ts +2 -0
- package/dist/typescript/hooks/useAutoEnterPiPEffect.d.ts.map +1 -0
- package/dist/typescript/hooks/useIsInPiPMode.d.ts +2 -0
- package/dist/typescript/hooks/useIsInPiPMode.d.ts.map +1 -0
- package/dist/typescript/hooks/usePaginatedLayoutSortPreset.d.ts +3 -0
- package/dist/typescript/hooks/usePaginatedLayoutSortPreset.d.ts.map +1 -0
- package/dist/typescript/icons/EndStreamIcon.d.ts +3 -0
- package/dist/typescript/icons/EndStreamIcon.d.ts.map +1 -0
- package/dist/typescript/icons/Eye.d.ts +3 -0
- package/dist/typescript/icons/Eye.d.ts.map +1 -0
- package/dist/typescript/icons/LeaveStreamIcon.d.ts +3 -0
- package/dist/typescript/icons/LeaveStreamIcon.d.ts.map +1 -0
- package/dist/typescript/icons/ShieldBadge.d.ts +3 -0
- package/dist/typescript/icons/ShieldBadge.d.ts.map +1 -0
- package/dist/typescript/icons/StartStreamIcon.d.ts +3 -0
- package/dist/typescript/icons/StartStreamIcon.d.ts.map +1 -0
- package/dist/typescript/icons/index.d.ts +5 -0
- package/dist/typescript/icons/index.d.ts.map +1 -1
- package/dist/typescript/providers/MediaStreamManagement.d.ts.map +1 -1
- package/dist/typescript/theme/theme.d.ts +70 -0
- package/dist/typescript/theme/theme.d.ts.map +1 -1
- package/dist/typescript/translations/index.d.ts +6 -1
- package/dist/typescript/translations/index.d.ts.map +1 -1
- package/dist/typescript/utils/enterPiPAndroid.d.ts +2 -0
- package/dist/typescript/utils/enterPiPAndroid.d.ts.map +1 -0
- package/dist/typescript/utils/index.d.ts +1 -0
- package/dist/typescript/utils/index.d.ts.map +1 -1
- package/dist/typescript/version.d.ts +1 -1
- package/expo-config-plugin/dist/common/addNewLinesToMainActivity.d.ts +1 -0
- package/expo-config-plugin/dist/common/addNewLinesToMainActivity.js +16 -0
- package/expo-config-plugin/dist/common/types.d.ts +4 -0
- package/expo-config-plugin/dist/index.js +6 -2
- package/expo-config-plugin/dist/withAndroidManifest.d.ts +2 -1
- package/expo-config-plugin/dist/withAndroidManifest.js +20 -2
- package/expo-config-plugin/dist/withMainActivity.d.ts +4 -0
- package/expo-config-plugin/dist/withMainActivity.js +72 -0
- package/package.json +1 -1
- package/src/components/Call/CallContent/CallContent.tsx +15 -7
- package/src/components/Call/CallLayout/CallParticipantsGrid.tsx +16 -2
- package/src/components/Call/CallLayout/CallParticipantsSpotlight.tsx +4 -1
- package/src/components/Livestream/HostLivestream/HostLivestream.tsx +99 -0
- package/src/components/Livestream/HostLivestream/index.ts +1 -0
- package/src/components/Livestream/LivestreamControls/HostLivestreamControls.tsx +87 -0
- package/src/components/Livestream/LivestreamControls/HostStartStreamButton.tsx +163 -0
- package/src/components/Livestream/LivestreamControls/LivestreamAudioControlButton.tsx +78 -0
- package/src/components/Livestream/LivestreamControls/LivestreamMediaControls.tsx +32 -0
- package/src/components/Livestream/LivestreamControls/LivestreamVideoControlButton.tsx +78 -0
- package/src/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.tsx +102 -0
- package/src/components/Livestream/LivestreamControls/ViewerLivestreamControls.tsx +75 -0
- package/src/components/Livestream/LivestreamControls/index.ts +5 -0
- package/src/components/Livestream/LivestreamLayout/LivestreamLayout.tsx +77 -0
- package/src/components/Livestream/LivestreamLayout/index.ts +1 -0
- package/src/components/Livestream/LivestreamTopView/DurationBadge.tsx +170 -0
- package/src/components/Livestream/LivestreamTopView/FollowerCount.tsx +74 -0
- package/src/components/Livestream/LivestreamTopView/HostLivestreamTopView.tsx +105 -0
- package/src/components/Livestream/LivestreamTopView/LiveIndicator.tsx +53 -0
- package/src/components/Livestream/LivestreamTopView/ViewerLivestreamTopView.tsx +102 -0
- package/src/components/Livestream/LivestreamTopView/index.ts +4 -0
- package/src/components/Livestream/ViewerLivestream/ViewerLivestream.tsx +126 -0
- package/src/components/Livestream/ViewerLivestream/index.ts +1 -0
- package/src/components/Livestream/index.ts +5 -0
- package/src/components/index.ts +1 -0
- package/src/hooks/index.ts +2 -0
- package/src/hooks/useAutoEnterPiPEffect.tsx +16 -0
- package/src/hooks/useIsInPiPMode.tsx +29 -0
- package/src/hooks/usePaginatedLayoutSortPreset.ts +27 -0
- package/src/icons/EndStreamIcon.tsx +13 -0
- package/src/icons/Eye.tsx +13 -0
- package/src/icons/LeaveStreamIcon.tsx +13 -0
- package/src/icons/ShieldBadge.tsx +13 -0
- package/src/icons/StartStreamIcon.tsx +13 -0
- package/src/icons/index.tsx +5 -0
- package/src/providers/MediaStreamManagement.tsx +14 -1
- package/src/theme/theme.ts +140 -0
- package/src/translations/en.json +6 -1
- package/src/utils/enterPiPAndroid.ts +11 -0
- package/src/utils/index.ts +1 -0
- package/src/version.ts +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_colors","require","defaultTheme","exports","variants","buttonSizes","xs","sm","md","lg","xl","iconSizes","avatarSizes","typefaces","heading4","fontSize","fontWeight","heading5","heading6","subtitle","subtitleBold","bodyBold","caption","colors","avatar","container","image","text","acceptCallButton","svgContainer","callContent","callParticipantsContainer","topContainer","callControls","callControlsButton","joinCallButton","label","chatButton","hangupCallButton","rejectCallButton","toggleAudioPreviewButton","toggleAudioPublishingButton","toggleCameraFaceButton","toggleVideoPreviewButton","toggleVideoPublishingButton","callParticipantsGrid","callParticipantsSpotlight","fullScreenSpotlightContainer","callParticipantsListContainer","spotlightContainer","lobby","heading","subHeading","bottomContainer","videoContainer","infoContainer","infoText","participantStatusContainer","avatarContainer","userNameLabel","audioMutedIconContainer","floatingParticipantsView","participantViewContainer","videoFallback","participantLabel","videoMutedIconContainer","pinIconContainer","screenShareIconContainer","participantNetworkQualityIndicator","participantReaction","reaction","participantVideoFallback","avatarText","avatarImage","participantView","footerContainer","highligtedContainer","reactionsPicker","reactionsPopup","reactionsButtonDimmer","reactionItem","reactionText","videoRenderer","videoStream","incomingCall","background","content","incomingCallText","incomingCallControls","buttonGroup","outgoingCall","callingText","outgoingCallControls","deviceControlButtons","ringingCallContent","joiningCallIndicator","callTopView","backIconContainer","leftElement","centerElement","rightElement","title","userInfo","avatarGroup","name","lobbyControls","participantInfoBadge","participantCountContainer","participantsIconContainer","participantsCountText"],"sourceRoot":"../../../src","sources":["theme/theme.ts"],"mappings":";;;;;;AACA,IAAAA,OAAA,GAAAC,OAAA;
|
|
1
|
+
{"version":3,"names":["_colors","require","defaultTheme","exports","variants","buttonSizes","xs","sm","md","lg","xl","iconSizes","avatarSizes","typefaces","heading4","fontSize","fontWeight","heading5","heading6","subtitle","subtitleBold","bodyBold","caption","colors","avatar","container","image","text","acceptCallButton","svgContainer","callContent","callParticipantsContainer","topContainer","callControls","callControlsButton","joinCallButton","label","chatButton","hangupCallButton","rejectCallButton","toggleAudioPreviewButton","toggleAudioPublishingButton","toggleCameraFaceButton","toggleVideoPreviewButton","toggleVideoPublishingButton","callParticipantsGrid","callParticipantsSpotlight","fullScreenSpotlightContainer","callParticipantsListContainer","spotlightContainer","lobby","heading","subHeading","bottomContainer","videoContainer","infoContainer","infoText","participantStatusContainer","avatarContainer","userNameLabel","audioMutedIconContainer","floatingParticipantsView","participantViewContainer","videoFallback","participantLabel","videoMutedIconContainer","pinIconContainer","screenShareIconContainer","participantNetworkQualityIndicator","participantReaction","reaction","participantVideoFallback","avatarText","avatarImage","participantView","footerContainer","highligtedContainer","reactionsPicker","reactionsPopup","reactionsButtonDimmer","reactionItem","reactionText","videoRenderer","videoStream","incomingCall","background","content","incomingCallText","incomingCallControls","buttonGroup","outgoingCall","callingText","outgoingCallControls","deviceControlButtons","ringingCallContent","joiningCallIndicator","callTopView","backIconContainer","leftElement","centerElement","rightElement","title","userInfo","avatarGroup","name","lobbyControls","participantInfoBadge","participantCountContainer","participantsIconContainer","participantsCountText","hostLivestream","hostLivestreamTopView","liveInfo","viewerLivestream","floatingParticipantView","view","livestreamLayout","viewerLivestreamTopView","followerCount","icon","durationBadge","liveIndicator","hostLivestreamControls","viewerLivestreamControls","hostStartStreamButton","viewerLeaveStreamButton","livestreamMediaControls","livestreamAudioControlButton","livestreamVideoControlButton"],"sourceRoot":"../../../src","sources":["theme/theme.ts"],"mappings":";;;;;;AACA,IAAAA,OAAA,GAAAC,OAAA;AAgRO,MAAMC,YAAmB,GAAAC,OAAA,CAAAD,YAAA,GAAG;EACjCE,QAAQ,EAAE;IACRC,WAAW,EAAE;MACXC,EAAE,EAAE,EAAE;MACNC,EAAE,EAAE,EAAE;MACNC,EAAE,EAAE,EAAE;MACNC,EAAE,EAAE,EAAE;MACNC,EAAE,EAAE;IACN,CAAC;IACDC,SAAS,EA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E,CAAC;EACjB,CAAC;EACDwB,qBAAqB,EAAE;IACrBnG,SAAS,EAAE,CAAC,CAAC;IACb8F,IAAI,EAAE,CAAC,CAAC;IACR5F,IAAI,EAAE,CAAC;EACT,CAAC;EACDkG,uBAAuB,EAAE;IACvBpG,SAAS,EAAE,CAAC,CAAC;IACb8F,IAAI,EAAE,CAAC,CAAC;IACR5F,IAAI,EAAE,CAAC;EACT,CAAC;EACDmG,uBAAuB,EAAE;IACvBrG,SAAS,EAAE,CAAC;EACd,CAAC;EACDsG,4BAA4B,EAAE;IAC5BtG,SAAS,EAAE,CAAC,CAAC;IACb8F,IAAI,EAAE,CAAC;EACT,CAAC;EACDS,4BAA4B,EAAE;IAC5BvG,SAAS,EAAE,CAAC,CAAC;IACb8F,IAAI,EAAE,CAAC;EACT;AACF,CAAC"}
|
|
@@ -6,7 +6,12 @@
|
|
|
6
6
|
"Join": "Join",
|
|
7
7
|
"You": "You",
|
|
8
8
|
"Reconnecting...": "Reconnecting...",
|
|
9
|
-
"
|
|
9
|
+
"Loading...": "Loading...",
|
|
10
|
+
"Start Stream": "Start Stream",
|
|
11
|
+
"End Stream": "End Stream",
|
|
12
|
+
"Leave Stream": "Leave Stream",
|
|
13
|
+
"Live": "Live",
|
|
14
|
+
"You are first to Join the call.": "You are first to Join the call.",
|
|
10
15
|
"Participants ({{ numberOfParticipants }})": "Participants ({{ numberOfParticipants }})",
|
|
11
16
|
"{{ userName }} is sharing their screen": "{{ userName }} is sharing their screen",
|
|
12
17
|
"{{ numberOfParticipants }} participant(s) are in the call.": "{{ numberOfParticipants }} participant(s) are in the call.",
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.enterPiPAndroid = enterPiPAndroid;
|
|
7
|
+
var _reactNative = require("react-native");
|
|
8
|
+
function enterPiPAndroid(width, height) {
|
|
9
|
+
var _NativeModules$Stream;
|
|
10
|
+
if (_reactNative.Platform.OS !== 'android') {
|
|
11
|
+
return;
|
|
12
|
+
}
|
|
13
|
+
return _reactNative.NativeModules === null || _reactNative.NativeModules === void 0 || (_NativeModules$Stream = _reactNative.NativeModules.StreamVideoReactNative) === null || _NativeModules$Stream === void 0 ? void 0 : _NativeModules$Stream.enterPipMode(width ? Math.floor(width) : 0, height ? Math.floor(height) : 0);
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=enterPiPAndroid.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_reactNative","require","enterPiPAndroid","width","height","_NativeModules$Stream","Platform","OS","NativeModules","StreamVideoReactNative","enterPipMode","Math","floor"],"sourceRoot":"../../../src","sources":["utils/enterPiPAndroid.ts"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAEO,SAASC,eAAeA,CAACC,KAAc,EAAEC,MAAe,EAAE;EAAA,IAAAC,qBAAA;EAC/D,IAAIC,qBAAQ,CAACC,EAAE,KAAK,SAAS,EAAE;IAC7B;EACF;EACA,OAAOC,0BAAa,aAAbA,0BAAa,gBAAAH,qBAAA,GAAbG,0BAAa,CAAEC,sBAAsB,cAAAJ,qBAAA,uBAArCA,qBAAA,CAAuCK,YAAY,CACxDP,KAAK,GAAGQ,IAAI,CAACC,KAAK,CAACT,KAAK,CAAC,GAAG,CAAC,EAC7BC,MAAM,GAAGO,IAAI,CAACC,KAAK,CAACR,MAAM,CAAC,GAAG,CAChC,CAAC;AACH"}
|
|
@@ -9,6 +9,18 @@ var _exportNames = {
|
|
|
9
9
|
getInitialsOfName: true
|
|
10
10
|
};
|
|
11
11
|
exports.getInitialsOfName = exports.generateParticipantTitle = exports.generateCallTitle = void 0;
|
|
12
|
+
var _enterPiPAndroid = require("./enterPiPAndroid");
|
|
13
|
+
Object.keys(_enterPiPAndroid).forEach(function (key) {
|
|
14
|
+
if (key === "default" || key === "__esModule") return;
|
|
15
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
16
|
+
if (key in exports && exports[key] === _enterPiPAndroid[key]) return;
|
|
17
|
+
Object.defineProperty(exports, key, {
|
|
18
|
+
enumerable: true,
|
|
19
|
+
get: function () {
|
|
20
|
+
return _enterPiPAndroid[key];
|
|
21
|
+
}
|
|
22
|
+
});
|
|
23
|
+
});
|
|
12
24
|
var _StreamVideoRN = require("./StreamVideoRN");
|
|
13
25
|
Object.keys(_StreamVideoRN).forEach(function (key) {
|
|
14
26
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["_enterPiPAndroid","require","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","_StreamVideoRN","generateCallTitle","memberUserIds","totalMembersToShow","supportedAmountOfMemberUserIds","slice","length","join","allMembersExceptLast","lastMember","generateParticipantTitle","memberUserId","getInitialsOfName","name","names","split","initials","substring","toUpperCase"],"sourceRoot":"../../../src","sources":["utils/index.ts"],"mappings":";;;;;;;;;;;AAsCA,IAAAA,gBAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAH,gBAAA,EAAAI,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAL,gBAAA,CAAAK,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAb,gBAAA,CAAAK,GAAA;IAAA;EAAA;AAAA;AACA,IAAAS,cAAA,GAAAb,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAW,cAAA,EAAAV,OAAA,WAA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GAAGD,IAAI,CAACE,KAAK,CAAC,GAAG,CAAC;EAC7B,IAAIC,QAAQ,GAAGF,KAAK,CAAC,CAAC,CAAC,CAACG,SAAS,CAAC,CAAC,EAAE,CAAC,CAAC,CAACC,WAAW,CAAC,CAAC;EACrD,IAAIJ,KAAK,CAACR,MAAM,GAAG,CAAC,EAAE;IACpBU,QAAQ,IAAIF,KAAK,CAACA,KAAK,CAACR,MAAM,GAAG,CAAC,CAAC,CAACW,SAAS,CAAC,CAAC,EAAE,CAAC,CAAC,CAACC,WAAW,CAAC,CAAC;EACnE;EACA,OAAOF,QAAQ;AACjB,CAAC;AAACpB,OAAA,CAAAgB,iBAAA,GAAAA,iBAAA"}
|
package/dist/commonjs/version.js
CHANGED
|
@@ -11,6 +11,7 @@ import { Z_INDEX } from '../../../constants';
|
|
|
11
11
|
import { useDebouncedValue } from '../../../utils/hooks';
|
|
12
12
|
import { FloatingParticipantView as DefaultFloatingParticipantView } from '../../Participant';
|
|
13
13
|
import { useTheme } from '../../../contexts';
|
|
14
|
+
import { useIsInPiPMode, useAutoEnterPiPEffect } from '../../../hooks';
|
|
14
15
|
export const CallContent = _ref => {
|
|
15
16
|
let {
|
|
16
17
|
onBackPressed,
|
|
@@ -42,13 +43,15 @@ export const CallContent = _ref => {
|
|
|
42
43
|
useRemoteParticipants,
|
|
43
44
|
useLocalParticipant
|
|
44
45
|
} = useCallStateHooks();
|
|
46
|
+
useAutoEnterPiPEffect();
|
|
45
47
|
const _remoteParticipants = useRemoteParticipants();
|
|
46
48
|
const remoteParticipants = useDebouncedValue(_remoteParticipants, 300); // we debounce the remote participants to avoid unnecessary rerenders that happen when participant tracks are all subscribed simultaneously
|
|
47
49
|
const localParticipant = useLocalParticipant();
|
|
50
|
+
const isInPiPMode = useIsInPiPMode();
|
|
48
51
|
const hasScreenShare = useHasOngoingScreenShare();
|
|
49
52
|
const showSpotlightLayout = hasScreenShare || layout === 'spotlight';
|
|
50
|
-
const showFloatingView = !showSpotlightLayout && remoteParticipants.length > 0 && remoteParticipants.length < 3;
|
|
51
|
-
const isRemoteParticipantInFloatingView = showRemoteParticipantInFloatingView && remoteParticipants.length === 1;
|
|
53
|
+
const showFloatingView = !showSpotlightLayout && !isInPiPMode && remoteParticipants.length > 0 && remoteParticipants.length < 3;
|
|
54
|
+
const isRemoteParticipantInFloatingView = showFloatingView && showRemoteParticipantInFloatingView && remoteParticipants.length === 1;
|
|
52
55
|
|
|
53
56
|
/**
|
|
54
57
|
* This hook is used to handle IncallManager specs of the application.
|
|
@@ -76,8 +79,8 @@ export const CallContent = _ref => {
|
|
|
76
79
|
};
|
|
77
80
|
}, []);
|
|
78
81
|
const participantViewProps = {
|
|
79
|
-
ParticipantLabel,
|
|
80
|
-
ParticipantNetworkQualityIndicator,
|
|
82
|
+
ParticipantLabel: isInPiPMode ? null : ParticipantLabel,
|
|
83
|
+
ParticipantNetworkQualityIndicator: isInPiPMode ? null : ParticipantNetworkQualityIndicator,
|
|
81
84
|
ParticipantReaction,
|
|
82
85
|
ParticipantVideoFallback,
|
|
83
86
|
VideoRenderer
|
|
@@ -101,7 +104,7 @@ export const CallContent = _ref => {
|
|
|
101
104
|
flexDirection: landscape ? 'row' : 'column'
|
|
102
105
|
};
|
|
103
106
|
return /*#__PURE__*/React.createElement(View, {
|
|
104
|
-
style: [styles.container, callContent.container
|
|
107
|
+
style: [styles.container, landscapeStyles, callContent.container]
|
|
105
108
|
}, /*#__PURE__*/React.createElement(View, {
|
|
106
109
|
style: [styles.container, callContent.callParticipantsContainer]
|
|
107
110
|
}, /*#__PURE__*/React.createElement(View, {
|
|
@@ -110,7 +113,7 @@ export const CallContent = _ref => {
|
|
|
110
113
|
// and allows only the top and floating view (its child views) to take up the touches
|
|
111
114
|
,
|
|
112
115
|
pointerEvents: "box-none"
|
|
113
|
-
}, CallTopView && /*#__PURE__*/React.createElement(CallTopView, {
|
|
116
|
+
}, !isInPiPMode && CallTopView && /*#__PURE__*/React.createElement(CallTopView, {
|
|
114
117
|
onBackPressed: onBackPressed,
|
|
115
118
|
onParticipantInfoPress: onParticipantInfoPress,
|
|
116
119
|
ParticipantsInfoBadge: ParticipantsInfoBadge
|
|
@@ -118,7 +121,7 @@ export const CallContent = _ref => {
|
|
|
118
121
|
participant: isRemoteParticipantInFloatingView ? remoteParticipants[0] : localParticipant,
|
|
119
122
|
onPressHandler: handleFloatingViewParticipantSwitch,
|
|
120
123
|
supportedReactions: supportedReactions
|
|
121
|
-
}, participantViewProps))), showSpotlightLayout ? /*#__PURE__*/React.createElement(CallParticipantsSpotlight, callParticipantsSpotlightProps) : /*#__PURE__*/React.createElement(CallParticipantsGrid, callParticipantsGridProps)), CallControls && /*#__PURE__*/React.createElement(CallControls, {
|
|
124
|
+
}, participantViewProps))), showSpotlightLayout ? /*#__PURE__*/React.createElement(CallParticipantsSpotlight, callParticipantsSpotlightProps) : /*#__PURE__*/React.createElement(CallParticipantsGrid, callParticipantsGridProps)), !isInPiPMode && CallControls && /*#__PURE__*/React.createElement(CallControls, {
|
|
122
125
|
onHangupCallHandler: onHangupCallHandler,
|
|
123
126
|
landscape: landscape
|
|
124
127
|
}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useEffect","useRef","useState","StyleSheet","View","CallTopView","DefaultCallTopView","CallParticipantsGrid","CallParticipantsSpotlight","CallControls","DefaultCallControls","useCall","useCallStateHooks","CallingState","useIncallManager","Z_INDEX","useDebouncedValue","FloatingParticipantView","DefaultFloatingParticipantView","useTheme","CallContent","_ref","onBackPressed","onParticipantInfoPress","onHangupCallHandler","CallParticipantsList","ParticipantLabel","ParticipantNetworkQualityIndicator","ParticipantReaction","ParticipantVideoFallback","ParticipantView","ParticipantsInfoBadge","VideoRenderer","layout","landscape","supportedReactions","showRemoteParticipantInFloatingView","setShowRemoteParticipantInFloatingView","theme","callContent","useHasOngoingScreenShare","useRemoteParticipants","useLocalParticipant","_remoteParticipants","remoteParticipants","localParticipant","hasScreenShare","showSpotlightLayout","showFloatingView","length","isRemoteParticipantInFloatingView","media","auto","call","activeCallRef","current","handleFloatingViewParticipantSwitch","prevState","_activeCallRef$curren","state","callingState","LEFT","_activeCallRef$curren2","leave","participantViewProps","callParticipantsGridProps","showLocalParticipant","callParticipantsSpotlightProps","landscapeStyles","flexDirection","createElement","style","styles","container","callParticipantsContainer","view","topContainer","pointerEvents","_extends","participant","onPressHandler","create","flex","absoluteFillObject","zIndex","IN_FRONT"],"sourceRoot":"../../../../../src","sources":["components/Call/CallContent/CallContent.tsx"],"mappings":";AAAA,OAAOA,KAAK,IAAIC,SAAS,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AAC1D,SAASC,UAAU,EAAEC,IAAI,QAAmB,cAAc;AAC1D,SACEC,WAAW,IAAIC,kBAAkB,QAE5B,gBAAgB;AACvB,SACEC,oBAAoB,EAEpBC,yBAAyB,QAEpB,eAAe;AACtB,SAEEC,YAAY,IAAIC,mBAAmB,QAE9B,iBAAiB;AACxB,SAASC,OAAO,EAAEC,iBAAiB,QAAQ,iCAAiC;AAC5E,SAASC,YAAY,QAAwB,yBAAyB;AACtE,SAASC,gBAAgB,QAAQ,gBAAgB;AACjD,SAASC,OAAO,QAAQ,oBAAoB;AAC5C,SAASC,iBAAiB,QAAQ,sBAAsB;AACxD,SACEC,uBAAuB,IAAIC,8BAA8B,QAGpD,mBAAmB;AAC1B,SAASC,QAAQ,QAAQ,mBAAmB;
|
|
1
|
+
{"version":3,"names":["React","useEffect","useRef","useState","StyleSheet","View","CallTopView","DefaultCallTopView","CallParticipantsGrid","CallParticipantsSpotlight","CallControls","DefaultCallControls","useCall","useCallStateHooks","CallingState","useIncallManager","Z_INDEX","useDebouncedValue","FloatingParticipantView","DefaultFloatingParticipantView","useTheme","useIsInPiPMode","useAutoEnterPiPEffect","CallContent","_ref","onBackPressed","onParticipantInfoPress","onHangupCallHandler","CallParticipantsList","ParticipantLabel","ParticipantNetworkQualityIndicator","ParticipantReaction","ParticipantVideoFallback","ParticipantView","ParticipantsInfoBadge","VideoRenderer","layout","landscape","supportedReactions","showRemoteParticipantInFloatingView","setShowRemoteParticipantInFloatingView","theme","callContent","useHasOngoingScreenShare","useRemoteParticipants","useLocalParticipant","_remoteParticipants","remoteParticipants","localParticipant","isInPiPMode","hasScreenShare","showSpotlightLayout","showFloatingView","length","isRemoteParticipantInFloatingView","media","auto","call","activeCallRef","current","handleFloatingViewParticipantSwitch","prevState","_activeCallRef$curren","state","callingState","LEFT","_activeCallRef$curren2","leave","participantViewProps","callParticipantsGridProps","showLocalParticipant","callParticipantsSpotlightProps","landscapeStyles","flexDirection","createElement","style","styles","container","callParticipantsContainer","view","topContainer","pointerEvents","_extends","participant","onPressHandler","create","flex","absoluteFillObject","zIndex","IN_FRONT"],"sourceRoot":"../../../../../src","sources":["components/Call/CallContent/CallContent.tsx"],"mappings":";AAAA,OAAOA,KAAK,IAAIC,SAAS,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AAC1D,SAASC,UAAU,EAAEC,IAAI,QAAmB,cAAc;AAC1D,SACEC,WAAW,IAAIC,kBAAkB,QAE5B,gBAAgB;AACvB,SACEC,oBAAoB,EAEpBC,yBAAyB,QAEpB,eAAe;AACtB,SAEEC,YAAY,IAAIC,mBAAmB,QAE9B,iBAAiB;AACxB,SAASC,OAAO,EAAEC,iBAAiB,QAAQ,iCAAiC;AAC5E,SAASC,YAAY,QAAwB,yBAAyB;AACtE,SAASC,gBAAgB,QAAQ,gBAAgB;AACjD,SAASC,OAAO,QAAQ,oBAAoB;AAC5C,SAASC,iBAAiB,QAAQ,sBAAsB;AACxD,SACEC,uBAAuB,IAAIC,8BAA8B,QAGpD,mBAAmB;AAC1B,SAASC,QAAQ,QAAQ,mBAAmB;AAK5C,SAASC,cAAc,EAAEC,qBAAqB,QAAQ,gBAAgB;AAkDtE,OAAO,MAAMC,WAAW,GAAGC,IAAA,IAkBH;EAAA,IAlBI;IAC1BC,aAAa;IACbC,sBAAsB;IACtBC,mBAAmB;IACnBC,oBA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,CAAC;EAC/BR,SAAS,EAAE;IAAES,IAAI,EAAE;EAAE,CAAC;EACtBP,IAAI,EAAE;IACJ,GAAG3E,UAAU,CAACmF,kBAAkB;IAChCC,MAAM,EAAExE,OAAO,CAACyE;EAClB;AACF,CAAC,CAAC"}
|
|
@@ -6,6 +6,7 @@ import { useDebouncedValue } from '../../../utils/hooks/useDebouncedValue';
|
|
|
6
6
|
import { CallParticipantsList as DefaultCallParticipantsList } from '../CallParticipantsList/CallParticipantsList';
|
|
7
7
|
import { ComponentTestIds } from '../../../constants/TestIds';
|
|
8
8
|
import { useTheme } from '../../../contexts/ThemeContext';
|
|
9
|
+
import { useIsInPiPMode } from '../../../hooks';
|
|
9
10
|
|
|
10
11
|
/**
|
|
11
12
|
* Props for the CallParticipantsGrid component.
|
|
@@ -47,8 +48,12 @@ export const CallParticipantsGrid = _ref => {
|
|
|
47
48
|
const landscapeStyles = {
|
|
48
49
|
flexDirection: landscape ? 'row' : 'column'
|
|
49
50
|
};
|
|
50
|
-
const
|
|
51
|
-
const
|
|
51
|
+
const isInPiPMode = useIsInPiPMode();
|
|
52
|
+
const showFloatingView = !isInPiPMode && remoteParticipants.length > 0 && remoteParticipants.length < 3;
|
|
53
|
+
let participants = showFloatingView ? showLocalParticipant && localParticipant ? [localParticipant] : remoteParticipants : allParticipants;
|
|
54
|
+
if (isInPiPMode) {
|
|
55
|
+
participants = remoteParticipants.length > 0 ? [remoteParticipants[0]] : localParticipant ? [localParticipant] : [];
|
|
56
|
+
}
|
|
52
57
|
const participantViewProps = {
|
|
53
58
|
ParticipantView,
|
|
54
59
|
ParticipantLabel,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","StyleSheet","View","useCallStateHooks","useDebouncedValue","CallParticipantsList","DefaultCallParticipantsList","ComponentTestIds","useTheme","CallParticipantsGrid","_ref","ParticipantLabel","ParticipantNetworkQualityIndicator","ParticipantReaction","ParticipantVideoFallback","ParticipantView","VideoRenderer","showLocalParticipant","supportedReactions","landscape","theme","colors","callParticipantsGrid","useRemoteParticipants","useParticipants","useLocalParticipant","_remoteParticipants","localParticipant","_allParticipants","remoteParticipants","allParticipants","landscapeStyles","flexDirection","showFloatingView","length","participants","participantViewProps","createElement","style","styles","container","backgroundColor","dark_gray","testID","CALL_PARTICIPANTS_GRID","_extends","create","flex"],"sourceRoot":"../../../../../src","sources":["components/Call/CallLayout/CallParticipantsGrid.tsx"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,UAAU,EAAEC,IAAI,QAAmB,cAAc;AAC1D,SAASC,iBAAiB,QAAQ,iCAAiC;AACnE,SAASC,iBAAiB,QAAQ,wCAAwC;AAC1E,SACEC,oBAAoB,IAAIC,2BAA2B,QAE9C,8CAA8C;AACrD,SAASC,gBAAgB,QAAQ,4BAA4B;AAC7D,SAASC,QAAQ,QAAQ,gCAAgC;;
|
|
1
|
+
{"version":3,"names":["React","StyleSheet","View","useCallStateHooks","useDebouncedValue","CallParticipantsList","DefaultCallParticipantsList","ComponentTestIds","useTheme","useIsInPiPMode","CallParticipantsGrid","_ref","ParticipantLabel","ParticipantNetworkQualityIndicator","ParticipantReaction","ParticipantVideoFallback","ParticipantView","VideoRenderer","showLocalParticipant","supportedReactions","landscape","theme","colors","callParticipantsGrid","useRemoteParticipants","useParticipants","useLocalParticipant","_remoteParticipants","localParticipant","_allParticipants","remoteParticipants","allParticipants","landscapeStyles","flexDirection","isInPiPMode","showFloatingView","length","participants","participantViewProps","createElement","style","styles","container","backgroundColor","dark_gray","testID","CALL_PARTICIPANTS_GRID","_extends","create","flex"],"sourceRoot":"../../../../../src","sources":["components/Call/CallLayout/CallParticipantsGrid.tsx"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,UAAU,EAAEC,IAAI,QAAmB,cAAc;AAC1D,SAASC,iBAAiB,QAAQ,iCAAiC;AACnE,SAASC,iBAAiB,QAAQ,wCAAwC;AAC1E,SACEC,oBAAoB,IAAIC,2B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,gBAAgB,CAAC,GAClBE,kBAAkB,GACpBC,eAAe;EAEnB,IAAIG,WAAW,EAAE;IACfG,YAAY,GACVP,kBAAkB,CAACM,MAAM,GAAG,CAAC,GACzB,CAACN,kBAAkB,CAAC,CAAC,CAAC,CAAC,GACvBF,gBAAgB,GAChB,CAACA,gBAAgB,CAAC,GAClB,EAAE;EACV;EAEA,MAAMU,oBAAwD,GAAG;IAC/DtB,eAAe;IACfJ,gBAAgB;IAChBC,kCAAkC;IAClCC,mBAAmB;IACnBC,wBAAwB;IACxBE;EACF,CAAC;EAED,oBACEjB,KAAA,CAAAuC,aAAA,CAACrC,IAAI;IACHsC,KAAK,EAAE,CACLC,MAAM,CAACC,SAAS,EAChBV,eAAe,EACf;MAAEW,eAAe,EAAErB,MAAM,CAACsB;IAAU,CAAC,EACrCrB,oBAAoB,CAACmB,SAAS,CAC9B;IACFG,MAAM,EAAEtC,gBAAgB,CAACuC;EAAuB,GAE/CzC,oBAAoB,iBACnBL,KAAA,CAAAuC,aAAA,CAAClC,oBAAoB,EAAA0C,QAAA;IACnBV,YAAY,EAAEA,YAAa;IAC3BlB,kBAAkB,EAAEA,kBAAmB;IACvCC,SAAS,EAAEA;EAAU,GACjBkB,oBAAoB,CACzB,CAEC,CAAC;AAEX,CAAC;AAED,MAAMG,MAAM,GAAGxC,UAAU,CAAC+C,MAAM,CAAC;EAC/BN,SAAS,EAAE;IACTO,IAAI,EAAE;EACR;AACF,CAAC,CAAC"}
|
|
@@ -8,6 +8,7 @@ import { ComponentTestIds } from '../../../constants/TestIds';
|
|
|
8
8
|
import { CallParticipantsList as DefaultCallParticipantsList } from '../CallParticipantsList/CallParticipantsList';
|
|
9
9
|
import { ParticipantView as DefaultParticipantView } from '../../Participant';
|
|
10
10
|
import { useTheme } from '../../../contexts/ThemeContext';
|
|
11
|
+
import { useIsInPiPMode } from '../../../hooks';
|
|
11
12
|
|
|
12
13
|
/**
|
|
13
14
|
* Props for the CallParticipantsSpotlight component.
|
|
@@ -47,6 +48,7 @@ export const CallParticipantsSpotlight = _ref => {
|
|
|
47
48
|
const [participantInSpotlight, ...otherParticipants] = allParticipants;
|
|
48
49
|
const isScreenShareOnSpotlight = hasScreenShare(participantInSpotlight);
|
|
49
50
|
const isUserAloneInCall = (_allParticipants === null || _allParticipants === void 0 ? void 0 : _allParticipants.length) === 1;
|
|
51
|
+
const isInPiP = useIsInPiPMode();
|
|
50
52
|
const participantViewProps = {
|
|
51
53
|
ParticipantLabel,
|
|
52
54
|
ParticipantNetworkQualityIndicator,
|
|
@@ -74,7 +76,7 @@ export const CallParticipantsSpotlight = _ref => {
|
|
|
74
76
|
style: isUserAloneInCall ? [styles.fullScreenSpotlightContainer, callParticipantsSpotlight.fullScreenSpotlightContainer] : [styles.spotlightContainer, spotlightContainerLandscapeStyles, callParticipantsSpotlight.spotlightContainer],
|
|
75
77
|
trackType: isScreenShareOnSpotlight ? 'screenShareTrack' : 'videoTrack',
|
|
76
78
|
supportedReactions: supportedReactions
|
|
77
|
-
}, participantViewProps)), !isUserAloneInCall && /*#__PURE__*/React.createElement(View, {
|
|
79
|
+
}, participantViewProps)), !isInPiP && !isUserAloneInCall && /*#__PURE__*/React.createElement(View, {
|
|
78
80
|
style: [styles.callParticipantsListContainer, callParticipantsSpotlight.callParticipantsListContainer]
|
|
79
81
|
}, CallParticipantsList && /*#__PURE__*/React.createElement(CallParticipantsList, _extends({
|
|
80
82
|
participants: isScreenShareOnSpotlight ? allParticipants : otherParticipants,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","SfuModels","speakerLayoutSortPreset","useCallStateHooks","StyleSheet","View","useDebouncedValue","ComponentTestIds","CallParticipantsList","DefaultCallParticipantsList","ParticipantView","DefaultParticipantView","useTheme","hasScreenShare","p","publishedTracks","includes","TrackType","SCREEN_SHARE","CallParticipantsSpotlight","_ref","ParticipantLabel","ParticipantNetworkQualityIndicator","ParticipantReaction","ParticipantVideoFallback","VideoRenderer","supportedReactions","landscape","theme","colors","callParticipantsSpotlight","useParticipants","_allParticipants","sortBy","allParticipants","participantInSpotlight","otherParticipants","isScreenShareOnSpotlight","isUserAloneInCall","length","participantViewProps","callParticipantsListProps","landscapeStyles","flexDirection","spotlightContainerLandscapeStyles","marginHorizontal","createElement","testID","CALL_PARTICIPANTS_SPOTLIGHT","style","styles","container","backgroundColor","dark_gray","_extends","participant","fullScreenSpotlightContainer","spotlightContainer","trackType","callParticipantsListContainer","participants","horizontal","numberOfColumns","create","flex","overflow","borderRadius"],"sourceRoot":"../../../../../src","sources":["components/Call/CallLayout/CallParticipantsSpotlight.tsx"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SACEC,SAAS,EACTC,uBAAuB,QAElB,yBAAyB;AAChC,SAASC,iBAAiB,QAAQ,iCAAiC;AACnE,SAASC,UAAU,EAAEC,IAAI,QAAmB,cAAc;AAC1D,SAASC,iBAAiB,QAAQ,wCAAwC;AAC1E,SAASC,gBAAgB,QAAQ,4BAA4B;AAC7D,SACEC,oBAAoB,IAAIC,2BAA2B,QAE9C,8CAA8C;AACrD,SACEC,eAAe,IAAIC,sBAAsB,QAEpC,mBAAmB;AAC1B,SAASC,QAAQ,QAAQ,gCAAgC;;
|
|
1
|
+
{"version":3,"names":["React","SfuModels","speakerLayoutSortPreset","useCallStateHooks","StyleSheet","View","useDebouncedValue","ComponentTestIds","CallParticipantsList","DefaultCallParticipantsList","ParticipantView","DefaultParticipantView","useTheme","useIsInPiPMode","hasScreenShare","p","publishedTracks","includes","TrackType","SCREEN_SHARE","CallParticipantsSpotlight","_ref","ParticipantLabel","ParticipantNetworkQualityIndicator","ParticipantReaction","ParticipantVideoFallback","VideoRenderer","supportedReactions","landscape","theme","colors","callParticipantsSpotlight","useParticipants","_allParticipants","sortBy","allParticipants","participantInSpotlight","otherParticipants","isScreenShareOnSpotlight","isUserAloneInCall","length","isInPiP","participantViewProps","callParticipantsListProps","landscapeStyles","flexDirection","spotlightContainerLandscapeStyles","marginHorizontal","createElement","testID","CALL_PARTICIPANTS_SPOTLIGHT","style","styles","container","backgroundColor","dark_gray","_extends","participant","fullScreenSpotlightContainer","spotlightContainer","trackType","callParticipantsListContainer","participants","horizontal","numberOfColumns","create","flex","overflow","borderRadius"],"sourceRoot":"../../../../../src","sources":["components/Call/CallLayout/CallParticipantsSpotlight.tsx"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SACEC,SAAS,EACTC,uBAAuB,QAElB,yBAAyB;AAChC,SAASC,iBAAiB,QAAQ,iCAAiC;AACnE,SAASC,UAAU,EAAEC,IAAI,QAAmB,cAAc;AAC1D,SAASC,iBAAiB,QAAQ,wCAAwC;AAC1E,SAASC,gBAAgB,QAAQ,4BAA4B;AAC7D,SACEC,oBAAoB,IAAIC,2BAA2B,QAE9C,8CAA8C;AACrD,SACEC,eAAe,IAAIC,sBAAsB,QAEpC,mBAAmB;AAC1B,SAASC,QAAQ,QAAQ,gCAAgC;AAEzD,SAASC,cAAc,QAAQ,gBAAgB;;AAE/C;AACA;AACA;;AAWA,MAAMC,cAAc,GAAIC,CAAyB,IAC/CA,CAAC,CAACC,eAAe,CAACC,QAAQ,CAAChB,SAAS,CAACiB,SAAS,CAACC,YAAY,CAAC;;AAE9D;AACA;AACA;AACA;AACA,OAAO,MAAMC,yBAAyB,GAAGC,IAAA,IAUH;EAAA,IAVI;IACxCb,oBAAoB,GAAGC,2BAA2B;IAClDa,gBAAgB;IAChBC,kCAAkC;IAClCC,mBAAmB;IACnBC,wBAAwB;IACxBf,eAAe,GAAGC,sBAAsB;IACxCe,aAAa;IACbC,kBAAkB;IAClBC;EAC8B,CAAC,GAAAP,IAAA;EAC/B,MAAM;IACJQ,KAAK,EAAE;MAAEC,MAAM;MAAEC;IAA0B;EAC7C,CAAC,GAAGnB,QAAQ,CAAC,CAAC;EACd,MAAM;IAAEoB;EAAgB,CAAC,GAAG7B,iBAAiB,CAAC,CAAC;EAC/C,MAAM8B,gBAAgB,GAAGD,eAAe,CAAC;I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EACzBb,iCAAiC,EACjCf,yBAAyB,CAAC4B,kBAAkB,CAEnD;IACDC,SAAS,EACPtB,wBAAwB,GAAG,kBAAkB,GAAG,YACjD;IACDX,kBAAkB,EAAEA;EAAmB,GACnCe,oBAAoB,CACzB,CACF,EACA,CAACD,OAAO,IAAI,CAACF,iBAAiB,iBAC7BvC,KAAA,CAAAgD,aAAA,CAAC3C,IAAI;IACH8C,KAAK,EAAE,CACLC,MAAM,CAACS,6BAA6B,EACpC9B,yBAAyB,CAAC8B,6BAA6B;EACvD,GAEDrD,oBAAoB,iBACnBR,KAAA,CAAAgD,aAAA,CAACxC,oBAAoB,EAAAgD,QAAA;IACnBM,YAAY,EACVxB,wBAAwB,GAAGH,eAAe,GAAGE,iBAC9C;IACDV,kBAAkB,EAAEA,kBAAmB;IACvCoC,UAAU,EAAE,CAACnC,SAAU;IACvBoC,eAAe,EAAE,CAACpC,SAAS,GAAG,CAAC,GAAG,CAAE;IACpCA,SAAS,EAAEA;EAAU,GACjBe,yBAAyB,CAC9B,CAEC,CAEJ,CAAC;AAEX,CAAC;AAED,MAAMS,MAAM,GAAGhD,UAAU,CAAC6D,MAAM,CAAC;EAC/BZ,SAAS,EAAE;IACTa,IAAI,EAAE;EACR,CAAC;EACDR,4BAA4B,EAAE;IAC5BQ,IAAI,EAAE;EACR,CAAC;EACDP,kBAAkB,EAAE;IAClBO,IAAI,EAAE,CAAC;IACPC,QAAQ,EAAE,QAAQ;IAClBC,YAAY,EAAE,EAAE;IAChBrB,gBAAgB,EAAE;EACpB,CAAC;EACDc,6BAA6B,EAAE;IAC7BK,IAAI,EAAE;EACR;AACF,CAAC,CAAC"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { StyleSheet, SafeAreaView } from 'react-native';
|
|
3
|
+
import { useTheme } from '../../../contexts';
|
|
4
|
+
import { useIncallManager } from '../../../hooks';
|
|
5
|
+
import { HostLivestreamTopView as DefaultHostLivestreamTopView } from '../LivestreamTopView/HostLivestreamTopView';
|
|
6
|
+
import { HostLivestreamControls as DefaultHostLivestreamControls } from '../LivestreamControls/HostLivestreamControls';
|
|
7
|
+
import { LivestreamLayout as DefaultLivestreamLayout } from '../LivestreamLayout';
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Props for the HostLivestream component.
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* The HostLivestream component displays the UI for the Host's live stream.
|
|
15
|
+
*/
|
|
16
|
+
export const HostLivestream = _ref => {
|
|
17
|
+
let {
|
|
18
|
+
HostLivestreamTopView = DefaultHostLivestreamTopView,
|
|
19
|
+
HostLivestreamControls = DefaultHostLivestreamControls,
|
|
20
|
+
LivestreamLayout = DefaultLivestreamLayout,
|
|
21
|
+
LiveIndicator,
|
|
22
|
+
FollowerCount,
|
|
23
|
+
DurationBadge,
|
|
24
|
+
HostStartStreamButton,
|
|
25
|
+
LivestreamMediaControls,
|
|
26
|
+
onEndStreamHandler,
|
|
27
|
+
onStartStreamHandler,
|
|
28
|
+
hls = false
|
|
29
|
+
} = _ref;
|
|
30
|
+
const {
|
|
31
|
+
theme: {
|
|
32
|
+
colors,
|
|
33
|
+
hostLivestream
|
|
34
|
+
}
|
|
35
|
+
} = useTheme();
|
|
36
|
+
|
|
37
|
+
// Automatically route audio to speaker devices as relevant for watching videos.
|
|
38
|
+
useIncallManager({
|
|
39
|
+
media: 'video',
|
|
40
|
+
auto: true
|
|
41
|
+
});
|
|
42
|
+
const topViewProps = {
|
|
43
|
+
LiveIndicator,
|
|
44
|
+
FollowerCount,
|
|
45
|
+
DurationBadge
|
|
46
|
+
};
|
|
47
|
+
return /*#__PURE__*/React.createElement(SafeAreaView, {
|
|
48
|
+
style: [styles.container, {
|
|
49
|
+
backgroundColor: colors.static_grey
|
|
50
|
+
}, hostLivestream.container]
|
|
51
|
+
}, HostLivestreamTopView && /*#__PURE__*/React.createElement(HostLivestreamTopView, topViewProps), LivestreamLayout && /*#__PURE__*/React.createElement(LivestreamLayout, null), HostLivestreamControls && /*#__PURE__*/React.createElement(HostLivestreamControls, {
|
|
52
|
+
onEndStreamHandler: onEndStreamHandler,
|
|
53
|
+
onStartStreamHandler: onStartStreamHandler,
|
|
54
|
+
HostStartStreamButton: HostStartStreamButton,
|
|
55
|
+
LivestreamMediaControls: LivestreamMediaControls,
|
|
56
|
+
hls: hls
|
|
57
|
+
}));
|
|
58
|
+
};
|
|
59
|
+
const styles = StyleSheet.create({
|
|
60
|
+
container: {
|
|
61
|
+
flex: 1
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
|
+
//# sourceMappingURL=HostLivestream.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","StyleSheet","SafeAreaView","useTheme","useIncallManager","HostLivestreamTopView","DefaultHostLivestreamTopView","HostLivestreamControls","DefaultHostLivestreamControls","LivestreamLayout","DefaultLivestreamLayout","HostLivestream","_ref","LiveIndicator","FollowerCount","DurationBadge","HostStartStreamButton","LivestreamMediaControls","onEndStreamHandler","onStartStreamHandler","hls","theme","colors","hostLivestream","media","auto","topViewProps","createElement","style","styles","container","backgroundColor","static_grey","create","flex"],"sourceRoot":"../../../../../src","sources":["components/Livestream/HostLivestream/HostLivestream.tsx"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,UAAU,EAAEC,YAAY,QAAQ,cAAc;AACvD,SAASC,QAAQ,QAAQ,mBAAmB;AAC5C,SAASC,gBAAgB,QAAQ,gBAAgB;AACjD,SACEC,qBAAqB,IAAIC,4BAA4B,QAEhD,4CAA4C;AACnD,SACEC,sBAAsB,IAAIC,6BAA6B,QAElD,8CAA8C;AACrD,SACEC,gBAAgB,IAAIC,uBAAuB,QAEtC,qBAAqB;;AAE5B;AACA;AACA;;AAqBA;AACA;AACA;AACA,OAAO,MAAMC,cAAc,GAAGC,IAAA,IAYH;EAAA,IAZI;IAC7BP,qBAAqB,GAAGC,4BAA4B;IACpDC,sBAAsB,GAAGC,6BAA6B;IACtDC,gBAAgB,GAAGC,uBAAuB;IAC1CG,aAAa;IACbC,aAAa;IACbC,aAAa;IACbC,qBAAqB;IACrBC,uBAAuB;IACvBC,kBAAkB;IAClBC,oBAAoB;IACpBC,GAAG,GAAG;EACa,CAAC,GAAAR,IAAA;EACpB,MAAM;IACJS,KAAK,EAAE;MAAEC,MAAM;MAAEC;IAAe;EAClC,CAAC,GAAGpB,QAAQ,CAAC,CAAC;;EAEd;EACAC,gBAAgB,CAAC;IAAEoB,KAAK,EAAE,OAAO;IAAEC,IAAI,EAAE;EAAK,CAAC,CAAC;EAEhD,MAAMC,YAAwC,GAAG;IAC/Cb,aAAa;IACbC,aAAa;IACbC;EACF,CAAC;EAED,oBACEf,KAAA,CAAA2B,aAAA,CAACzB,YAAY;IACX0B,KAAK,EAAE,CACLC,MAAM,CAACC,SAAS,EAChB;MACEC,eAAe,EAAET,MAAM,CAACU;IAC1B,CAAC,EACDT,cAAc,CAACO,SAAS;EACxB,GAEDzB,qBAAqB,iBAAIL,KAAA,CAAA2B,aAAA,CAACtB,qBAAqB,EAAKqB,YAAe,CAAC,EACpEjB,gBAAgB,iBAAIT,KAAA,CAAA2B,aAAA,CAAClB,gBAAgB,MAAE,CAAC,EACxCF,sBAAsB,iBACrBP,KAAA,CAAA2B,aAAA,CAACpB,sBAAsB;IACrBW,kBAAkB,EAAEA,kBAAmB;IACvCC,oBAAoB,EAAEA,oBAAqB;IAC3CH,qBAAqB,EAAEA,qBAAsB;IAC7CC,uBAAuB,EAAEA,uBAAwB;IACjDG,GAAG,EAAEA;EAAI,CACV,CAES,CAAC;AAEnB,CAAC;AAED,MAAMS,MAAM,GAAG5B,UAAU,CAACgC,MAAM,CAAC;EAC/BH,SAAS,EAAE;IACTI,IAAI,EAAE;EACR;AACF,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../../../../src","sources":["components/Livestream/HostLivestream/index.ts"],"mappings":"AAAA,cAAc,kBAAkB"}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { StyleSheet, View } from 'react-native';
|
|
3
|
+
import { HostStartStreamButton as DefaultHostStartStreamButton } from './HostStartStreamButton';
|
|
4
|
+
import { LivestreamMediaControls as DefaultLivestreamMediaControls } from './LivestreamMediaControls';
|
|
5
|
+
import { useTheme } from '../../../contexts';
|
|
6
|
+
import { Z_INDEX } from '../../../constants';
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Props for the HostLivestreamControls component.
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* The HostLivestreamControls component displays the call controls for the live stream at host's end.
|
|
14
|
+
*/
|
|
15
|
+
export const HostLivestreamControls = _ref => {
|
|
16
|
+
let {
|
|
17
|
+
HostStartStreamButton = DefaultHostStartStreamButton,
|
|
18
|
+
LivestreamMediaControls = DefaultLivestreamMediaControls,
|
|
19
|
+
onEndStreamHandler,
|
|
20
|
+
onStartStreamHandler,
|
|
21
|
+
hls = false
|
|
22
|
+
} = _ref;
|
|
23
|
+
const {
|
|
24
|
+
theme: {
|
|
25
|
+
colors,
|
|
26
|
+
hostLivestreamControls
|
|
27
|
+
}
|
|
28
|
+
} = useTheme();
|
|
29
|
+
return /*#__PURE__*/React.createElement(View, {
|
|
30
|
+
style: [styles.container, {
|
|
31
|
+
backgroundColor: colors.static_overlay
|
|
32
|
+
}, hostLivestreamControls.container]
|
|
33
|
+
}, /*#__PURE__*/React.createElement(View, {
|
|
34
|
+
style: [styles.leftElement, hostLivestreamControls.leftElement]
|
|
35
|
+
}, HostStartStreamButton && /*#__PURE__*/React.createElement(HostStartStreamButton, {
|
|
36
|
+
onEndStreamHandler: onEndStreamHandler,
|
|
37
|
+
onStartStreamHandler: onStartStreamHandler,
|
|
38
|
+
hls: hls
|
|
39
|
+
})), /*#__PURE__*/React.createElement(View, {
|
|
40
|
+
style: [styles.rightElement, hostLivestreamControls.rightElement]
|
|
41
|
+
}, LivestreamMediaControls && /*#__PURE__*/React.createElement(LivestreamMediaControls, null)));
|
|
42
|
+
};
|
|
43
|
+
const styles = StyleSheet.create({
|
|
44
|
+
container: {
|
|
45
|
+
position: 'absolute',
|
|
46
|
+
bottom: 0,
|
|
47
|
+
flexDirection: 'row',
|
|
48
|
+
alignItems: 'center',
|
|
49
|
+
paddingVertical: 16,
|
|
50
|
+
paddingHorizontal: 8,
|
|
51
|
+
zIndex: Z_INDEX.IN_FRONT
|
|
52
|
+
},
|
|
53
|
+
leftElement: {
|
|
54
|
+
flex: 1,
|
|
55
|
+
alignItems: 'flex-start'
|
|
56
|
+
},
|
|
57
|
+
rightElement: {
|
|
58
|
+
flex: 1,
|
|
59
|
+
alignItems: 'flex-end'
|
|
60
|
+
}
|
|
61
|
+
});
|
|
62
|
+
//# sourceMappingURL=HostLivestreamControls.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","StyleSheet","View","HostStartStreamButton","DefaultHostStartStreamButton","LivestreamMediaControls","DefaultLivestreamMediaControls","useTheme","Z_INDEX","HostLivestreamControls","_ref","onEndStreamHandler","onStartStreamHandler","hls","theme","colors","hostLivestreamControls","createElement","style","styles","container","backgroundColor","static_overlay","leftElement","rightElement","create","position","bottom","flexDirection","alignItems","paddingVertical","paddingHorizontal","zIndex","IN_FRONT","flex"],"sourceRoot":"../../../../../src","sources":["components/Livestream/LivestreamControls/HostLivestreamControls.tsx"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,UAAU,EAAEC,IAAI,QAAQ,cAAc;AAC/C,SACEC,qBAAqB,IAAIC,4BAA4B,QAEhD,yBAAyB;AAChC,SACEC,uBAAuB,IAAIC,8BAA8B,QAEpD,2BAA2B;AAClC,SAASC,QAAQ,QAAQ,mBAAmB;AAC5C,SAASC,OAAO,QAAQ,oBAAoB;;AAE5C;AACA;AACA;;AAgBA;AACA;AACA;AACA,OAAO,MA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AAW,EAAE;IACXW,IAAI,EAAE,CAAC;IACPL,UAAU,EAAE;EACd,CAAC;EACDL,YAAY,EAAE;IACZU,IAAI,EAAE,CAAC;IACPL,UAAU,EAAE;EACd;AACF,CAAC,CAAC"}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { useCall, useCallStateHooks, useI18n } from '@stream-io/video-react-bindings';
|
|
2
|
+
import React, { useState } from 'react';
|
|
3
|
+
import { ActivityIndicator, Pressable, StyleSheet, Text, View } from 'react-native';
|
|
4
|
+
import { useTheme } from '../../../contexts';
|
|
5
|
+
import { EndBroadcastIcon, StartStreamIcon } from '../../../icons';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Props for the HostStartStreamButton component.
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* The HostStartStreamButton component displays and controls the start and end of the host's live stream.
|
|
13
|
+
*/
|
|
14
|
+
export const HostStartStreamButton = _ref => {
|
|
15
|
+
let {
|
|
16
|
+
onEndStreamHandler,
|
|
17
|
+
onStartStreamHandler,
|
|
18
|
+
hls
|
|
19
|
+
} = _ref;
|
|
20
|
+
const [isAwaitingResponse, setIsAwaitingResponse] = useState(false);
|
|
21
|
+
const {
|
|
22
|
+
useIsCallLive,
|
|
23
|
+
useIsCallBroadcastingInProgress
|
|
24
|
+
} = useCallStateHooks();
|
|
25
|
+
const {
|
|
26
|
+
theme: {
|
|
27
|
+
colors,
|
|
28
|
+
variants: {
|
|
29
|
+
iconSizes
|
|
30
|
+
},
|
|
31
|
+
typefaces,
|
|
32
|
+
hostStartStreamButton
|
|
33
|
+
}
|
|
34
|
+
} = useTheme();
|
|
35
|
+
const call = useCall();
|
|
36
|
+
const isCallLive = useIsCallLive();
|
|
37
|
+
const isCallBroadcasting = useIsCallBroadcastingInProgress();
|
|
38
|
+
const {
|
|
39
|
+
t
|
|
40
|
+
} = useI18n();
|
|
41
|
+
const liveOrBroadcasting = isCallLive || isCallBroadcasting;
|
|
42
|
+
const onStartStreamButtonPress = async () => {
|
|
43
|
+
if (onStartStreamHandler) {
|
|
44
|
+
onStartStreamHandler();
|
|
45
|
+
return;
|
|
46
|
+
}
|
|
47
|
+
try {
|
|
48
|
+
setIsAwaitingResponse(true);
|
|
49
|
+
await (call === null || call === void 0 ? void 0 : call.goLive());
|
|
50
|
+
if (hls) {
|
|
51
|
+
await (call === null || call === void 0 ? void 0 : call.startHLS());
|
|
52
|
+
}
|
|
53
|
+
setIsAwaitingResponse(false);
|
|
54
|
+
} catch (error) {
|
|
55
|
+
console.error('Error starting livestream', error);
|
|
56
|
+
}
|
|
57
|
+
};
|
|
58
|
+
const onEndStreamButtonPress = async () => {
|
|
59
|
+
if (onEndStreamHandler) {
|
|
60
|
+
onEndStreamHandler();
|
|
61
|
+
return;
|
|
62
|
+
}
|
|
63
|
+
try {
|
|
64
|
+
setIsAwaitingResponse(true);
|
|
65
|
+
if (hls) {
|
|
66
|
+
await (call === null || call === void 0 ? void 0 : call.stopHLS());
|
|
67
|
+
} else {
|
|
68
|
+
await (call === null || call === void 0 ? void 0 : call.stopLive());
|
|
69
|
+
}
|
|
70
|
+
setIsAwaitingResponse(false);
|
|
71
|
+
} catch (error) {
|
|
72
|
+
console.error('Error stopping livestream', error);
|
|
73
|
+
}
|
|
74
|
+
};
|
|
75
|
+
return /*#__PURE__*/React.createElement(Pressable, {
|
|
76
|
+
disabled: isAwaitingResponse,
|
|
77
|
+
style: [styles.container, {
|
|
78
|
+
backgroundColor: isAwaitingResponse ? colors.dark_gray : liveOrBroadcasting ? colors.error : colors.primary
|
|
79
|
+
}, hostStartStreamButton.container],
|
|
80
|
+
onPress: liveOrBroadcasting ? onEndStreamButtonPress : onStartStreamButtonPress
|
|
81
|
+
}, /*#__PURE__*/React.createElement(View, {
|
|
82
|
+
style: [styles.icon, {
|
|
83
|
+
height: iconSizes.xs,
|
|
84
|
+
width: iconSizes.xs
|
|
85
|
+
}, hostStartStreamButton.icon]
|
|
86
|
+
}, isAwaitingResponse ? /*#__PURE__*/React.createElement(ActivityIndicator, null) : liveOrBroadcasting ? /*#__PURE__*/React.createElement(EndBroadcastIcon, null) : /*#__PURE__*/React.createElement(StartStreamIcon, null)), /*#__PURE__*/React.createElement(Text, {
|
|
87
|
+
style: [styles.text, typefaces.subtitleBold, {
|
|
88
|
+
color: colors.static_white
|
|
89
|
+
}, hostStartStreamButton.text]
|
|
90
|
+
}, isAwaitingResponse ? t('Loading...') : liveOrBroadcasting ? t('Stop Livestream') : t('Start Livestream')));
|
|
91
|
+
};
|
|
92
|
+
const styles = StyleSheet.create({
|
|
93
|
+
container: {
|
|
94
|
+
flexDirection: 'row',
|
|
95
|
+
alignItems: 'center',
|
|
96
|
+
padding: 8,
|
|
97
|
+
borderRadius: 4
|
|
98
|
+
},
|
|
99
|
+
icon: {},
|
|
100
|
+
text: {
|
|
101
|
+
marginLeft: 8,
|
|
102
|
+
includeFontPadding: false
|
|
103
|
+
}
|
|
104
|
+
});
|
|
105
|
+
//# sourceMappingURL=HostStartStreamButton.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["useCall","useCallStateHooks","useI18n","React","useState","ActivityIndicator","Pressable","StyleSheet","Text","View","useTheme","EndBroadcastIcon","StartStreamIcon","HostStartStreamButton","_ref","onEndStreamHandler","onStartStreamHandler","hls","isAwaitingResponse","setIsAwaitingResponse","useIsCallLive","useIsCallBroadcastingInProgress","theme","colors","variants","iconSizes","typefaces","hostStartStreamButton","call","isCallLive","isCallBroadcasting","t","liveOrBroadcasting","onStartStreamButtonPress","goLive","startHLS","error","console","onEndStreamButtonPress","stopHLS","stopLive","createElement","disabled","style","styles","container","backgroundColor","dark_gray","primary","onPress","icon","height","xs","width","text","subtitleBold","color","static_white","create","flexDirection","alignItems","padding","borderRadius","marginLeft","includeFontPadding"],"sourceRoot":"../../../../../src","sources":["components/Livestream/LivestreamControls/HostStartStreamButton.tsx"],"mappings":"AAAA,SACEA,OAAO,EACPC,iBAAiB,EACjBC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