@stream-io/video-react-native-sdk 1.29.4-beta.0 → 1.30.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.
- package/CHANGELOG.md +3162 -0
- package/android/src/main/AndroidManifest.xml +1 -8
- package/android/src/main/AndroidManifestNew.xml +0 -11
- package/android/src/main/java/com/streamvideo/reactnative/StreamVideoReactNativeModule.kt +5 -42
- package/android/src/main/java/com/streamvideo/reactnative/audio/utils/WebRtcAudioUtils.kt +6 -70
- package/android/src/main/java/com/streamvideo/reactnative/callmanager/StreamInCallManagerModule.kt +4 -6
- package/android/src/main/java/com/streamvideo/reactnative/util/CallAliveServiceChecker.kt +95 -0
- package/dist/commonjs/components/Call/CallContent/CallContent.js +13 -7
- package/dist/commonjs/components/Call/CallContent/CallContent.js.map +1 -1
- package/dist/commonjs/components/Call/CallContent/RTCViewPipIOS.js +50 -14
- package/dist/commonjs/components/Call/CallContent/RTCViewPipIOS.js.map +1 -1
- package/dist/commonjs/components/Call/CallContent/RTCViewPipNative.js +27 -0
- package/dist/commonjs/components/Call/CallContent/RTCViewPipNative.js.map +1 -1
- package/dist/commonjs/components/Call/CallLayout/CallParticipantsGrid.js +19 -10
- package/dist/commonjs/components/Call/CallLayout/CallParticipantsGrid.js.map +1 -1
- package/dist/commonjs/components/Call/CallLayout/CallParticipantsSpotlight.js +12 -9
- package/dist/commonjs/components/Call/CallLayout/CallParticipantsSpotlight.js.map +1 -1
- package/dist/commonjs/components/Call/CallParticipantsList/CallParticipantsList.js +19 -4
- package/dist/commonjs/components/Call/CallParticipantsList/CallParticipantsList.js.map +1 -1
- package/dist/commonjs/hooks/push/index.js +2 -0
- package/dist/commonjs/hooks/push/index.js.map +1 -1
- package/dist/commonjs/hooks/push/useIosCallkeepWithCallingStateEffect.js +160 -0
- package/dist/commonjs/hooks/push/useIosCallkeepWithCallingStateEffect.js.map +1 -0
- package/dist/commonjs/hooks/push/useIosVoipPushEventsSetupEffect.js +31 -18
- package/dist/commonjs/hooks/push/useIosVoipPushEventsSetupEffect.js.map +1 -1
- package/dist/commonjs/hooks/push/useProcessPushCallEffect.js +67 -0
- package/dist/commonjs/hooks/push/useProcessPushCallEffect.js.map +1 -0
- package/dist/commonjs/hooks/useAndroidKeepCallAliveEffect.js +97 -64
- package/dist/commonjs/hooks/useAndroidKeepCallAliveEffect.js.map +1 -1
- package/dist/commonjs/index.js +0 -1
- package/dist/commonjs/index.js.map +1 -1
- package/dist/commonjs/modules/call-manager/CallManager.js +0 -26
- package/dist/commonjs/modules/call-manager/CallManager.js.map +1 -1
- package/dist/commonjs/providers/StreamCall/index.js +6 -6
- package/dist/commonjs/providers/StreamCall/index.js.map +1 -1
- package/dist/commonjs/utils/StreamVideoRN/index.js +21 -33
- package/dist/commonjs/utils/StreamVideoRN/index.js.map +1 -1
- package/dist/commonjs/utils/hooks/index.js +0 -11
- package/dist/commonjs/utils/hooks/index.js.map +1 -1
- package/dist/commonjs/utils/internal/registerSDKGlobals.js +3 -52
- package/dist/commonjs/utils/internal/registerSDKGlobals.js.map +1 -1
- package/dist/commonjs/utils/push/android.js +202 -151
- package/dist/commonjs/utils/push/android.js.map +1 -1
- package/dist/commonjs/utils/push/internal/ios.js +34 -17
- package/dist/commonjs/utils/push/internal/ios.js.map +1 -1
- package/dist/commonjs/utils/push/internal/rxSubjects.js +45 -1
- package/dist/commonjs/utils/push/internal/rxSubjects.js.map +1 -1
- package/dist/commonjs/utils/push/internal/utils.js +20 -32
- package/dist/commonjs/utils/push/internal/utils.js.map +1 -1
- package/dist/commonjs/utils/push/ios.js.map +1 -1
- package/dist/commonjs/utils/push/libs/callkeep.js +17 -0
- package/dist/commonjs/utils/push/libs/callkeep.js.map +1 -0
- package/dist/commonjs/utils/push/libs/index.js +19 -8
- package/dist/commonjs/utils/push/libs/index.js.map +1 -1
- package/dist/commonjs/utils/push/libs/notifee/index.js +19 -0
- package/dist/commonjs/utils/push/libs/notifee/index.js.map +1 -1
- package/dist/commonjs/utils/push/libs/voipPushNotification.js +17 -0
- package/dist/commonjs/utils/push/libs/voipPushNotification.js.map +1 -0
- package/dist/commonjs/utils/push/setupIosCallKeepEvents.js +205 -0
- package/dist/commonjs/utils/push/setupIosCallKeepEvents.js.map +1 -0
- package/dist/commonjs/utils/push/setupIosVoipPushEvents.js +6 -7
- package/dist/commonjs/utils/push/setupIosVoipPushEvents.js.map +1 -1
- package/dist/commonjs/version.js +1 -1
- package/dist/commonjs/version.js.map +1 -1
- package/dist/module/components/Call/CallContent/CallContent.js +10 -4
- package/dist/module/components/Call/CallContent/CallContent.js.map +1 -1
- package/dist/module/components/Call/CallContent/RTCViewPipIOS.js +52 -16
- package/dist/module/components/Call/CallContent/RTCViewPipIOS.js.map +1 -1
- package/dist/module/components/Call/CallContent/RTCViewPipNative.js +27 -0
- package/dist/module/components/Call/CallContent/RTCViewPipNative.js.map +1 -1
- package/dist/module/components/Call/CallLayout/CallParticipantsGrid.js +19 -10
- package/dist/module/components/Call/CallLayout/CallParticipantsGrid.js.map +1 -1
- package/dist/module/components/Call/CallLayout/CallParticipantsSpotlight.js +15 -12
- package/dist/module/components/Call/CallLayout/CallParticipantsSpotlight.js.map +1 -1
- package/dist/module/components/Call/CallParticipantsList/CallParticipantsList.js +20 -5
- package/dist/module/components/Call/CallParticipantsList/CallParticipantsList.js.map +1 -1
- package/dist/module/hooks/push/index.js +2 -0
- package/dist/module/hooks/push/index.js.map +1 -1
- package/dist/module/hooks/push/useIosCallkeepWithCallingStateEffect.js +153 -0
- package/dist/module/hooks/push/useIosCallkeepWithCallingStateEffect.js.map +1 -0
- package/dist/module/hooks/push/useIosVoipPushEventsSetupEffect.js +31 -18
- package/dist/module/hooks/push/useIosVoipPushEventsSetupEffect.js.map +1 -1
- package/dist/module/hooks/push/useProcessPushCallEffect.js +60 -0
- package/dist/module/hooks/push/useProcessPushCallEffect.js.map +1 -0
- package/dist/module/hooks/useAndroidKeepCallAliveEffect.js +99 -66
- package/dist/module/hooks/useAndroidKeepCallAliveEffect.js.map +1 -1
- package/dist/module/index.js +0 -1
- package/dist/module/index.js.map +1 -1
- package/dist/module/modules/call-manager/CallManager.js +0 -26
- package/dist/module/modules/call-manager/CallManager.js.map +1 -1
- package/dist/module/providers/StreamCall/index.js +6 -6
- package/dist/module/providers/StreamCall/index.js.map +1 -1
- package/dist/module/utils/StreamVideoRN/index.js +21 -33
- package/dist/module/utils/StreamVideoRN/index.js.map +1 -1
- package/dist/module/utils/hooks/index.js +0 -1
- package/dist/module/utils/hooks/index.js.map +1 -1
- package/dist/module/utils/internal/registerSDKGlobals.js +3 -52
- package/dist/module/utils/internal/registerSDKGlobals.js.map +1 -1
- package/dist/module/utils/push/android.js +204 -153
- package/dist/module/utils/push/android.js.map +1 -1
- package/dist/module/utils/push/internal/ios.js +34 -17
- package/dist/module/utils/push/internal/ios.js.map +1 -1
- package/dist/module/utils/push/internal/rxSubjects.js +44 -0
- package/dist/module/utils/push/internal/rxSubjects.js.map +1 -1
- package/dist/module/utils/push/internal/utils.js +19 -29
- package/dist/module/utils/push/internal/utils.js.map +1 -1
- package/dist/module/utils/push/ios.js.map +1 -1
- package/dist/module/utils/push/libs/callkeep.js +11 -0
- package/dist/module/utils/push/libs/callkeep.js.map +1 -0
- package/dist/module/utils/push/libs/index.js +2 -1
- package/dist/module/utils/push/libs/index.js.map +1 -1
- package/dist/module/utils/push/libs/notifee/index.js +18 -0
- package/dist/module/utils/push/libs/notifee/index.js.map +1 -1
- package/dist/module/utils/push/libs/voipPushNotification.js +11 -0
- package/dist/module/utils/push/libs/voipPushNotification.js.map +1 -0
- package/dist/module/utils/push/setupIosCallKeepEvents.js +199 -0
- package/dist/module/utils/push/setupIosCallKeepEvents.js.map +1 -0
- package/dist/module/utils/push/setupIosVoipPushEvents.js +6 -7
- package/dist/module/utils/push/setupIosVoipPushEvents.js.map +1 -1
- package/dist/module/version.js +1 -1
- package/dist/module/version.js.map +1 -1
- package/dist/typescript/components/Call/CallContent/CallContent.d.ts.map +1 -1
- package/dist/typescript/components/Call/CallContent/RTCViewPipIOS.d.ts.map +1 -1
- package/dist/typescript/components/Call/CallContent/RTCViewPipNative.d.ts +18 -0
- package/dist/typescript/components/Call/CallContent/RTCViewPipNative.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/Call/CallParticipantsList/CallParticipantsList.d.ts.map +1 -1
- package/dist/typescript/hooks/push/index.d.ts.map +1 -1
- package/dist/typescript/hooks/push/useIosCallkeepWithCallingStateEffect.d.ts +5 -0
- package/dist/typescript/hooks/push/useIosCallkeepWithCallingStateEffect.d.ts.map +1 -0
- package/dist/typescript/hooks/push/useIosVoipPushEventsSetupEffect.d.ts.map +1 -1
- package/dist/typescript/hooks/push/useProcessPushCallEffect.d.ts +8 -0
- package/dist/typescript/hooks/push/useProcessPushCallEffect.d.ts.map +1 -0
- package/dist/typescript/hooks/useAndroidKeepCallAliveEffect.d.ts.map +1 -1
- package/dist/typescript/index.d.ts +0 -1
- package/dist/typescript/index.d.ts.map +1 -1
- package/dist/typescript/modules/call-manager/CallManager.d.ts +0 -5
- package/dist/typescript/modules/call-manager/CallManager.d.ts.map +1 -1
- package/dist/typescript/utils/StreamVideoRN/index.d.ts +2 -20
- package/dist/typescript/utils/StreamVideoRN/index.d.ts.map +1 -1
- package/dist/typescript/utils/StreamVideoRN/types.d.ts +29 -54
- package/dist/typescript/utils/StreamVideoRN/types.d.ts.map +1 -1
- package/dist/typescript/utils/hooks/index.d.ts +0 -1
- package/dist/typescript/utils/hooks/index.d.ts.map +1 -1
- package/dist/typescript/utils/internal/registerSDKGlobals.d.ts.map +1 -1
- package/dist/typescript/utils/push/android.d.ts +2 -1
- package/dist/typescript/utils/push/android.d.ts.map +1 -1
- package/dist/typescript/utils/push/internal/ios.d.ts.map +1 -1
- package/dist/typescript/utils/push/internal/rxSubjects.d.ts +33 -0
- package/dist/typescript/utils/push/internal/rxSubjects.d.ts.map +1 -1
- package/dist/typescript/utils/push/internal/utils.d.ts +1 -8
- package/dist/typescript/utils/push/internal/utils.d.ts.map +1 -1
- package/dist/typescript/utils/push/ios.d.ts +2 -1
- package/dist/typescript/utils/push/ios.d.ts.map +1 -1
- package/dist/typescript/utils/push/libs/callkeep.d.ts +3 -0
- package/dist/typescript/utils/push/libs/callkeep.d.ts.map +1 -0
- package/dist/typescript/utils/push/libs/index.d.ts +2 -1
- package/dist/typescript/utils/push/libs/index.d.ts.map +1 -1
- package/dist/typescript/utils/push/libs/notifee/index.d.ts +1 -0
- package/dist/typescript/utils/push/libs/notifee/index.d.ts.map +1 -1
- package/dist/typescript/utils/push/libs/voipPushNotification.d.ts +3 -0
- package/dist/typescript/utils/push/libs/voipPushNotification.d.ts.map +1 -0
- package/dist/typescript/utils/push/setupIosCallKeepEvents.d.ts +6 -0
- package/dist/typescript/utils/push/setupIosCallKeepEvents.d.ts.map +1 -0
- package/dist/typescript/utils/push/setupIosVoipPushEvents.d.ts.map +1 -1
- package/dist/typescript/version.d.ts +1 -1
- package/dist/typescript/version.d.ts.map +1 -1
- package/expo-config-plugin/dist/withAndroidManifest.js +33 -1
- package/expo-config-plugin/dist/withAndroidPermissions.js +7 -2
- package/expo-config-plugin/dist/withAppDelegate.js +197 -19
- package/expo-config-plugin/dist/withMainActivity.js +1 -1
- package/expo-config-plugin/dist/withiOSInfoPlist.js +3 -2
- package/ios/PictureInPicture/PictureInPictureAvatarView.swift +273 -0
- package/ios/PictureInPicture/PictureInPictureConnectionQualityIndicator.swift +162 -0
- package/ios/PictureInPicture/PictureInPictureContent.swift +173 -0
- package/ios/PictureInPicture/PictureInPictureContentState.swift +123 -0
- package/ios/PictureInPicture/PictureInPictureDelegateProxy.swift +89 -0
- package/ios/PictureInPicture/PictureInPictureEnforcedStopAdapter.swift +166 -0
- package/ios/PictureInPicture/PictureInPictureLogger.swift +16 -0
- package/ios/PictureInPicture/PictureInPictureParticipantOverlayView.swift +217 -0
- package/ios/PictureInPicture/PictureInPictureReconnectionView.swift +193 -0
- package/ios/PictureInPicture/StreamAVPictureInPictureVideoCallViewController.swift +125 -7
- package/ios/PictureInPicture/StreamPictureInPictureController.swift +237 -63
- package/ios/PictureInPicture/StreamPictureInPictureControllerProtocol.swift +30 -0
- package/ios/PictureInPicture/StreamPictureInPictureVideoRenderer.swift +384 -12
- package/ios/RTCViewPip.swift +187 -21
- package/ios/RTCViewPipManager.mm +9 -0
- package/ios/RTCViewPipManager.swift +3 -3
- package/ios/StreamInCallManager.m +0 -2
- package/ios/StreamInCallManager.swift +7 -19
- package/ios/StreamVideoReactNative.h +4 -7
- package/ios/StreamVideoReactNative.m +82 -189
- package/package.json +19 -14
- package/src/components/Call/CallContent/CallContent.tsx +16 -8
- package/src/components/Call/CallContent/RTCViewPipIOS.tsx +81 -15
- package/src/components/Call/CallContent/RTCViewPipNative.tsx +36 -0
- package/src/components/Call/CallLayout/CallParticipantsGrid.tsx +28 -14
- package/src/components/Call/CallLayout/CallParticipantsSpotlight.tsx +19 -10
- package/src/components/Call/CallParticipantsList/CallParticipantsList.tsx +20 -5
- package/src/hooks/push/index.ts +2 -0
- package/src/hooks/push/useIosCallkeepWithCallingStateEffect.ts +235 -0
- package/src/hooks/push/useIosVoipPushEventsSetupEffect.ts +34 -21
- package/src/hooks/push/useProcessPushCallEffect.ts +108 -0
- package/src/hooks/useAndroidKeepCallAliveEffect.ts +120 -94
- package/src/index.ts +0 -1
- package/src/modules/call-manager/CallManager.ts +0 -36
- package/src/modules/call-manager/native-module.d.ts +0 -7
- package/src/providers/StreamCall/index.tsx +6 -6
- package/src/utils/StreamVideoRN/index.ts +30 -40
- package/src/utils/StreamVideoRN/types.ts +29 -56
- package/src/utils/hooks/index.ts +0 -1
- package/src/utils/internal/registerSDKGlobals.ts +4 -47
- package/src/utils/push/android.ts +309 -227
- package/src/utils/push/internal/ios.ts +44 -28
- package/src/utils/push/internal/rxSubjects.ts +61 -0
- package/src/utils/push/internal/utils.ts +26 -45
- package/src/utils/push/ios.ts +6 -1
- package/src/utils/push/libs/callkeep.ts +16 -0
- package/src/utils/push/libs/index.ts +2 -1
- package/src/utils/push/libs/notifee/index.ts +27 -0
- package/src/utils/push/libs/voipPushNotification.ts +17 -0
- package/src/utils/push/setupIosCallKeepEvents.ts +252 -0
- package/src/utils/push/setupIosVoipPushEvents.ts +7 -11
- package/src/version.ts +1 -1
- package/android/src/main/java/com/streamvideo/reactnative/keepalive/KeepAliveNotification.kt +0 -83
- package/android/src/main/java/com/streamvideo/reactnative/keepalive/StreamCallKeepAliveHeadlessService.kt +0 -149
- package/dist/commonjs/hooks/push/useCallingExpWithCallingStateEffect.js +0 -121
- package/dist/commonjs/hooks/push/useCallingExpWithCallingStateEffect.js.map +0 -1
- package/dist/commonjs/utils/hooks/useDebouncedValue.js +0 -24
- package/dist/commonjs/utils/hooks/useDebouncedValue.js.map +0 -1
- package/dist/commonjs/utils/internal/callingx/audioSessionPromise.js +0 -58
- package/dist/commonjs/utils/internal/callingx/audioSessionPromise.js.map +0 -1
- package/dist/commonjs/utils/internal/callingx/callingx.js +0 -109
- package/dist/commonjs/utils/internal/callingx/callingx.js.map +0 -1
- package/dist/commonjs/utils/keepCallAliveHeadlessTask.js +0 -48
- package/dist/commonjs/utils/keepCallAliveHeadlessTask.js.map +0 -1
- package/dist/commonjs/utils/push/libs/callingx.js +0 -75
- package/dist/commonjs/utils/push/libs/callingx.js.map +0 -1
- package/dist/commonjs/utils/push/setupCallingExpEvents.js +0 -108
- package/dist/commonjs/utils/push/setupCallingExpEvents.js.map +0 -1
- package/dist/module/hooks/push/useCallingExpWithCallingStateEffect.js +0 -114
- package/dist/module/hooks/push/useCallingExpWithCallingStateEffect.js.map +0 -1
- package/dist/module/utils/hooks/useDebouncedValue.js +0 -19
- package/dist/module/utils/hooks/useDebouncedValue.js.map +0 -1
- package/dist/module/utils/internal/callingx/audioSessionPromise.js +0 -51
- package/dist/module/utils/internal/callingx/audioSessionPromise.js.map +0 -1
- package/dist/module/utils/internal/callingx/callingx.js +0 -100
- package/dist/module/utils/internal/callingx/callingx.js.map +0 -1
- package/dist/module/utils/keepCallAliveHeadlessTask.js +0 -42
- package/dist/module/utils/keepCallAliveHeadlessTask.js.map +0 -1
- package/dist/module/utils/push/libs/callingx.js +0 -67
- package/dist/module/utils/push/libs/callingx.js.map +0 -1
- package/dist/module/utils/push/setupCallingExpEvents.js +0 -102
- package/dist/module/utils/push/setupCallingExpEvents.js.map +0 -1
- package/dist/typescript/hooks/push/useCallingExpWithCallingStateEffect.d.ts +0 -5
- package/dist/typescript/hooks/push/useCallingExpWithCallingStateEffect.d.ts.map +0 -1
- package/dist/typescript/utils/hooks/useDebouncedValue.d.ts +0 -8
- package/dist/typescript/utils/hooks/useDebouncedValue.d.ts.map +0 -1
- package/dist/typescript/utils/internal/callingx/audioSessionPromise.d.ts +0 -16
- package/dist/typescript/utils/internal/callingx/audioSessionPromise.d.ts.map +0 -1
- package/dist/typescript/utils/internal/callingx/callingx.d.ts +0 -14
- package/dist/typescript/utils/internal/callingx/callingx.d.ts.map +0 -1
- package/dist/typescript/utils/keepCallAliveHeadlessTask.d.ts +0 -10
- package/dist/typescript/utils/keepCallAliveHeadlessTask.d.ts.map +0 -1
- package/dist/typescript/utils/push/libs/callingx.d.ts +0 -9
- package/dist/typescript/utils/push/libs/callingx.d.ts.map +0 -1
- package/dist/typescript/utils/push/setupCallingExpEvents.d.ts +0 -8
- package/dist/typescript/utils/push/setupCallingExpEvents.d.ts.map +0 -1
- package/src/hooks/push/useCallingExpWithCallingStateEffect.ts +0 -147
- package/src/utils/hooks/useDebouncedValue.ts +0 -21
- package/src/utils/internal/callingx/audioSessionPromise.ts +0 -53
- package/src/utils/internal/callingx/callingx.ts +0 -146
- package/src/utils/keepCallAliveHeadlessTask.ts +0 -54
- package/src/utils/push/libs/callingx.ts +0 -90
- package/src/utils/push/setupCallingExpEvents.ts +0 -130
|
@@ -2,13 +2,6 @@
|
|
|
2
2
|
package="com.streamvideo.reactnative">
|
|
3
3
|
|
|
4
4
|
<uses-permission android:name="android.permission.INTERNET" />
|
|
5
|
+
<uses-permission android:name="android.permission.DEVICE_POWER" />
|
|
5
6
|
<uses-permission android:name="android.permission.WAKE_LOCK" />
|
|
6
|
-
|
|
7
|
-
<application>
|
|
8
|
-
<service
|
|
9
|
-
android:name="com.streamvideo.reactnative.keepalive.StreamCallKeepAliveHeadlessService"
|
|
10
|
-
android:exported="false"
|
|
11
|
-
android:stopWithTask="true"
|
|
12
|
-
android:foregroundServiceType="mediaPlayback|camera|microphone" />
|
|
13
|
-
</application>
|
|
14
7
|
</manifest>
|
|
@@ -1,13 +1,2 @@
|
|
|
1
1
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
|
|
2
|
-
|
|
3
|
-
<uses-permission android:name="android.permission.INTERNET" />
|
|
4
|
-
<uses-permission android:name="android.permission.WAKE_LOCK" />
|
|
5
|
-
|
|
6
|
-
<application>
|
|
7
|
-
<service
|
|
8
|
-
android:name="com.streamvideo.reactnative.keepalive.StreamCallKeepAliveHeadlessService"
|
|
9
|
-
android:exported="false"
|
|
10
|
-
android:stopWithTask="true"
|
|
11
|
-
android:foregroundServiceType="mediaPlayback|camera|microphone" />
|
|
12
|
-
</application>
|
|
13
2
|
</manifest>
|
|
@@ -15,7 +15,6 @@ import android.os.Build
|
|
|
15
15
|
import android.os.PowerManager
|
|
16
16
|
import android.util.Base64
|
|
17
17
|
import android.util.Log
|
|
18
|
-
import androidx.core.content.ContextCompat
|
|
19
18
|
import com.facebook.react.bridge.Arguments
|
|
20
19
|
import com.facebook.react.bridge.Promise
|
|
21
20
|
import com.facebook.react.bridge.ReactApplicationContext
|
|
@@ -24,8 +23,8 @@ import com.facebook.react.bridge.ReactMethod
|
|
|
24
23
|
import com.facebook.react.bridge.WritableMap
|
|
25
24
|
import com.facebook.react.modules.core.DeviceEventManagerModule.RCTDeviceEventEmitter
|
|
26
25
|
import com.oney.WebRTCModule.WebRTCModule
|
|
27
|
-
import com.streamvideo.reactnative.keepalive.StreamCallKeepAliveHeadlessService
|
|
28
26
|
import com.streamvideo.reactnative.util.CallAlivePermissionsHelper
|
|
27
|
+
import com.streamvideo.reactnative.util.CallAliveServiceChecker
|
|
29
28
|
import com.streamvideo.reactnative.util.PiPHelper
|
|
30
29
|
import com.streamvideo.reactnative.util.RingtoneUtil
|
|
31
30
|
import com.streamvideo.reactnative.util.YuvFrame
|
|
@@ -116,47 +115,11 @@ class StreamVideoReactNativeModule(reactContext: ReactApplicationContext) :
|
|
|
116
115
|
promise.resolve(false)
|
|
117
116
|
return
|
|
118
117
|
}
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
@ReactMethod
|
|
126
|
-
fun startKeepCallAliveService(
|
|
127
|
-
callCid: String,
|
|
128
|
-
channelId: String,
|
|
129
|
-
channelName: String,
|
|
130
|
-
title: String,
|
|
131
|
-
body: String,
|
|
132
|
-
smallIconName: String?,
|
|
133
|
-
promise: Promise
|
|
134
|
-
) {
|
|
135
|
-
try {
|
|
136
|
-
val intent = StreamCallKeepAliveHeadlessService.buildStartIntent(
|
|
137
|
-
reactApplicationContext,
|
|
138
|
-
callCid,
|
|
139
|
-
channelId,
|
|
140
|
-
channelName,
|
|
141
|
-
title,
|
|
142
|
-
body,
|
|
143
|
-
smallIconName
|
|
144
|
-
)
|
|
145
|
-
ContextCompat.startForegroundService(reactApplicationContext, intent)
|
|
118
|
+
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.UPSIDE_DOWN_CAKE) {
|
|
119
|
+
val isForegroundServiceDeclared = CallAliveServiceChecker.isForegroundServiceDeclared(reactApplicationContext)
|
|
120
|
+
promise.resolve(isForegroundServiceDeclared)
|
|
121
|
+
} else {
|
|
146
122
|
promise.resolve(true)
|
|
147
|
-
} catch (e: Exception) {
|
|
148
|
-
promise.reject(NAME, "Failed to start keep call alive foreground service", e)
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
@ReactMethod
|
|
153
|
-
fun stopKeepCallAliveService(promise: Promise) {
|
|
154
|
-
try {
|
|
155
|
-
val intent = StreamCallKeepAliveHeadlessService.buildStopIntent(reactApplicationContext)
|
|
156
|
-
val stopped = reactApplicationContext.stopService(intent)
|
|
157
|
-
promise.resolve(stopped)
|
|
158
|
-
} catch (e: Exception) {
|
|
159
|
-
promise.reject(NAME, "Failed to stop keep call alive foreground service", e)
|
|
160
123
|
}
|
|
161
124
|
}
|
|
162
125
|
|
|
@@ -55,78 +55,14 @@ object WebRtcAudioUtils {
|
|
|
55
55
|
* what might be the root cause.
|
|
56
56
|
*/
|
|
57
57
|
fun logAudioState(tag: String, reactContext: ReactContext) {
|
|
58
|
-
Log.d(tag, getAudioStateLog(reactContext))
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
/**
|
|
62
|
-
* Returns a string containing information about the current audio state.
|
|
63
|
-
* Similar to logAudioState but returns the information instead of logging it.
|
|
64
|
-
*/
|
|
65
|
-
fun getAudioStateLog(reactContext: ReactContext): String {
|
|
66
|
-
val audioManager = reactContext.getSystemService(Context.AUDIO_SERVICE) as AudioManager
|
|
67
|
-
val sb = StringBuilder()
|
|
68
|
-
|
|
69
|
-
// Volume control stream
|
|
70
58
|
reactContext.currentActivity?.let {
|
|
71
|
-
|
|
59
|
+
Log.d(tag, "volumeControlStream: " + streamTypeToString(it.volumeControlStream))
|
|
72
60
|
}
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
sb.appendLine("Audio State: audio mode: ${modeToString(audioManager.mode)}, has mic: ${hasMicrophone(reactContext)}, mic muted: ${audioManager.isMicrophoneMute}, music active: ${audioManager.isMusicActive}, speakerphone: ${audioManager.isSpeakerphoneOn}, BT SCO: ${audioManager.isBluetoothScoOn}")
|
|
79
|
-
|
|
80
|
-
// Volume info
|
|
81
|
-
val fixedVolume = audioManager.isVolumeFixed
|
|
82
|
-
sb.appendLine(" fixed volume=$fixedVolume")
|
|
83
|
-
if (!fixedVolume) {
|
|
84
|
-
val streams = intArrayOf(
|
|
85
|
-
AudioManager.STREAM_VOICE_CALL,
|
|
86
|
-
AudioManager.STREAM_MUSIC,
|
|
87
|
-
AudioManager.STREAM_RING,
|
|
88
|
-
AudioManager.STREAM_ALARM,
|
|
89
|
-
AudioManager.STREAM_NOTIFICATION,
|
|
90
|
-
AudioManager.STREAM_SYSTEM
|
|
91
|
-
)
|
|
92
|
-
for (stream in streams) {
|
|
93
|
-
val info = StringBuilder()
|
|
94
|
-
info.append(" ${streamTypeToString(stream)}: ")
|
|
95
|
-
info.append("volume=${audioManager.getStreamVolume(stream)}")
|
|
96
|
-
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.P) {
|
|
97
|
-
info.append(", min=${audioManager.getStreamMinVolume(stream)}")
|
|
98
|
-
}
|
|
99
|
-
info.append(", max=${audioManager.getStreamMaxVolume(stream)}")
|
|
100
|
-
info.append(", muted=${audioManager.isStreamMute(stream)}")
|
|
101
|
-
sb.appendLine(info.toString())
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
// Audio devices
|
|
106
|
-
val inputDevices = audioManager.getDevices(AudioManager.GET_DEVICES_INPUTS)
|
|
107
|
-
val outputDevices = audioManager.getDevices(AudioManager.GET_DEVICES_OUTPUTS)
|
|
108
|
-
val devices = inputDevices + outputDevices
|
|
109
|
-
if (devices.isNotEmpty()) {
|
|
110
|
-
sb.appendLine("Audio Devices:")
|
|
111
|
-
for (device in devices) {
|
|
112
|
-
val info = StringBuilder()
|
|
113
|
-
info.append(" ${deviceTypeToString(device.type)}")
|
|
114
|
-
info.append(if (device.isSource) "(in): " else "(out): ")
|
|
115
|
-
if (device.channelCounts.isNotEmpty()) {
|
|
116
|
-
info.append("channels=${device.channelCounts.contentToString()}, ")
|
|
117
|
-
}
|
|
118
|
-
if (device.encodings.isNotEmpty()) {
|
|
119
|
-
info.append("encodings=${device.encodings.contentToString()}, ")
|
|
120
|
-
}
|
|
121
|
-
if (device.sampleRates.isNotEmpty()) {
|
|
122
|
-
info.append("sample rates=${device.sampleRates.contentToString()}, ")
|
|
123
|
-
}
|
|
124
|
-
info.append("id=${device.id}")
|
|
125
|
-
sb.appendLine(info.toString())
|
|
126
|
-
}
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
return sb.toString()
|
|
61
|
+
val audioManager = reactContext.getSystemService(Context.AUDIO_SERVICE) as AudioManager
|
|
62
|
+
logDeviceInfo(tag)
|
|
63
|
+
logAudioStateBasic(tag, reactContext, audioManager)
|
|
64
|
+
logAudioStateVolume(tag, audioManager)
|
|
65
|
+
logAudioDeviceInfo(tag, audioManager)
|
|
130
66
|
}
|
|
131
67
|
|
|
132
68
|
/** Converts AudioDeviceInfo types to local string representation. */
|
package/android/src/main/java/com/streamvideo/reactnative/callmanager/StreamInCallManagerModule.kt
CHANGED
|
@@ -168,12 +168,10 @@ class StreamInCallManagerModule(reactContext: ReactApplicationContext) :
|
|
|
168
168
|
|
|
169
169
|
@ReactMethod
|
|
170
170
|
fun logAudioState() {
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
fun getAudioStateLog(): String {
|
|
176
|
-
return WebRtcAudioUtils.getAudioStateLog(reactApplicationContext)
|
|
171
|
+
WebRtcAudioUtils.logAudioState(
|
|
172
|
+
TAG,
|
|
173
|
+
reactApplicationContext,
|
|
174
|
+
)
|
|
177
175
|
}
|
|
178
176
|
|
|
179
177
|
@Suppress("unused")
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
package com.streamvideo.reactnative.util
|
|
2
|
+
|
|
3
|
+
import android.content.ComponentName
|
|
4
|
+
import android.content.pm.PackageManager
|
|
5
|
+
import android.content.pm.ServiceInfo
|
|
6
|
+
import android.os.Build
|
|
7
|
+
import android.util.Log
|
|
8
|
+
import androidx.annotation.RequiresApi
|
|
9
|
+
import com.facebook.react.bridge.ReactApplicationContext
|
|
10
|
+
|
|
11
|
+
@RequiresApi(api = Build.VERSION_CODES.UPSIDE_DOWN_CAKE)
|
|
12
|
+
object CallAliveServiceChecker {
|
|
13
|
+
private const val NAME = "StreamVideoReactNative"
|
|
14
|
+
|
|
15
|
+
fun isForegroundServiceDeclared(context: ReactApplicationContext): Boolean {
|
|
16
|
+
val packageManager = context.packageManager
|
|
17
|
+
val packageName = context.packageName // Get the package name of your app
|
|
18
|
+
val componentName = ComponentName(
|
|
19
|
+
packageName,
|
|
20
|
+
"app.notifee.core.ForegroundService"
|
|
21
|
+
) // Use service name string
|
|
22
|
+
|
|
23
|
+
try {
|
|
24
|
+
val serviceInfo =
|
|
25
|
+
packageManager.getServiceInfo(componentName, PackageManager.GET_META_DATA)
|
|
26
|
+
|
|
27
|
+
val expectedForegroundServiceTypes =
|
|
28
|
+
ServiceInfo.FOREGROUND_SERVICE_TYPE_SHORT_SERVICE or
|
|
29
|
+
ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PLAYBACK or
|
|
30
|
+
ServiceInfo.FOREGROUND_SERVICE_TYPE_CAMERA or
|
|
31
|
+
ServiceInfo.FOREGROUND_SERVICE_TYPE_MICROPHONE
|
|
32
|
+
|
|
33
|
+
val actualForegroundServiceTypes = serviceInfo.foregroundServiceType
|
|
34
|
+
|
|
35
|
+
if (actualForegroundServiceTypes == expectedForegroundServiceTypes) {
|
|
36
|
+
return true
|
|
37
|
+
} else {
|
|
38
|
+
Log.w(
|
|
39
|
+
NAME,
|
|
40
|
+
"android:foregroundServiceType does not match: expected=${
|
|
41
|
+
foregroundServiceTypeToString(
|
|
42
|
+
expectedForegroundServiceTypes
|
|
43
|
+
)
|
|
44
|
+
}, actual=${foregroundServiceTypeToString(actualForegroundServiceTypes)}"
|
|
45
|
+
)
|
|
46
|
+
return false
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
} catch (e: PackageManager.NameNotFoundException) {
|
|
50
|
+
Log.d(NAME, "Service not found: " + e.message)
|
|
51
|
+
return false // Service not declared
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
private fun foregroundServiceTypeToString(foregroundServiceType: Int): String {
|
|
56
|
+
val types = mutableListOf<String>()
|
|
57
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_SHORT_SERVICE != 0) {
|
|
58
|
+
types.add("shortService")
|
|
59
|
+
}
|
|
60
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_DATA_SYNC != 0) {
|
|
61
|
+
types.add("dataSync")
|
|
62
|
+
}
|
|
63
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_CAMERA != 0) {
|
|
64
|
+
types.add("camera")
|
|
65
|
+
}
|
|
66
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_MICROPHONE != 0) {
|
|
67
|
+
types.add("microphone")
|
|
68
|
+
}
|
|
69
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_CONNECTED_DEVICE != 0) {
|
|
70
|
+
types.add("connectedDevice")
|
|
71
|
+
}
|
|
72
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_LOCATION != 0) {
|
|
73
|
+
types.add("location")
|
|
74
|
+
}
|
|
75
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PLAYBACK != 0) {
|
|
76
|
+
types.add("mediaPlayback")
|
|
77
|
+
}
|
|
78
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PROJECTION != 0) {
|
|
79
|
+
types.add("mediaProjection")
|
|
80
|
+
}
|
|
81
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_PHONE_CALL != 0) {
|
|
82
|
+
types.add("phoneCall")
|
|
83
|
+
}
|
|
84
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_HEALTH != 0) {
|
|
85
|
+
types.add("health")
|
|
86
|
+
}
|
|
87
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_REMOTE_MESSAGING != 0) {
|
|
88
|
+
types.add("remoteMessaging")
|
|
89
|
+
}
|
|
90
|
+
if (foregroundServiceType and ServiceInfo.FOREGROUND_SERVICE_TYPE_SYSTEM_EXEMPTED != 0) {
|
|
91
|
+
types.add("systemExempted")
|
|
92
|
+
}
|
|
93
|
+
return types.joinToString("|")
|
|
94
|
+
}
|
|
95
|
+
}
|
|
@@ -10,11 +10,11 @@ var _CallLayout = require("../CallLayout");
|
|
|
10
10
|
var _CallControls = require("../CallControls");
|
|
11
11
|
var _videoReactBindings = require("@stream-io/video-react-bindings");
|
|
12
12
|
var _videoClient = require("@stream-io/video-client");
|
|
13
|
+
var _rxjs = require("rxjs");
|
|
13
14
|
var _constants = require("../../../constants");
|
|
14
|
-
var _hooks = require("../../../utils/hooks");
|
|
15
15
|
var _Participant = require("../../Participant");
|
|
16
16
|
var _contexts = require("../../../contexts");
|
|
17
|
-
var
|
|
17
|
+
var _hooks = require("../../../hooks");
|
|
18
18
|
var _ScreenShareOverlay = require("../../utility/ScreenShareOverlay");
|
|
19
19
|
var _RTCViewPipIOS = require("./RTCViewPipIOS");
|
|
20
20
|
var _PrevLibDetection = require("../../../modules/call-manager/PrevLibDetection");
|
|
@@ -50,14 +50,20 @@ const CallContent = ({
|
|
|
50
50
|
const call = (0, _videoReactBindings.useCall)();
|
|
51
51
|
const {
|
|
52
52
|
useHasOngoingScreenShare,
|
|
53
|
-
useRemoteParticipants,
|
|
54
53
|
useLocalParticipant
|
|
55
54
|
} = (0, _videoReactBindings.useCallStateHooks)();
|
|
56
|
-
(0,
|
|
57
|
-
const
|
|
58
|
-
|
|
55
|
+
(0, _hooks.useAutoEnterPiPEffect)(disablePictureInPicture);
|
|
56
|
+
const [remoteParticipants, setRemoteParticipants] = (0, _react.useState)(() => call?.state.remoteParticipants ?? []);
|
|
57
|
+
(0, _react.useEffect)(() => {
|
|
58
|
+
if (!call) {
|
|
59
|
+
setRemoteParticipants([]);
|
|
60
|
+
return;
|
|
61
|
+
}
|
|
62
|
+
const sub = call.state.remoteParticipants$.pipe((0, _rxjs.debounceTime)(300)).subscribe(setRemoteParticipants);
|
|
63
|
+
return () => sub.unsubscribe();
|
|
64
|
+
}, [call]);
|
|
59
65
|
const localParticipant = useLocalParticipant();
|
|
60
|
-
const isInPiPMode = (0,
|
|
66
|
+
const isInPiPMode = (0, _hooks.useIsInPiPMode)();
|
|
61
67
|
const hasScreenShare = useHasOngoingScreenShare();
|
|
62
68
|
const showSpotlightLayout = hasScreenShare || layout === 'spotlight';
|
|
63
69
|
(0, _react.useEffect)(() => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_CallLayout","_CallControls","_videoReactBindings","_videoClient","
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_CallLayout","_CallControls","_videoReactBindings","_videoClient","_rxjs","_constants","_Participant","_contexts","_hooks","_ScreenShareOverlay","_RTCViewPipIOS","_PrevLibDetection","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","_extends","assign","bind","arguments","length","apply","CallContent","onHangupCallHandler","CallParticipantsList","CallControls","DefaultCallControls","FloatingParticipantView","DefaultFloatingParticipantView","ScreenShareOverlay","DefaultScreenShareOverlay","ParticipantLabel","ParticipantNetworkQualityIndicator","ParticipantReaction","ParticipantVideoFallback","ParticipantView","VideoRenderer","mirror","layout","landscape","supportedReactions","initialInCallManagerAudioMode","iOSPiPIncludeLocalParticipantVideo","disablePictureInPicture","showRemoteParticipantInFloatingView","setShowRemoteParticipantInFloatingView","useState","styles","useStyles","theme","callContent","useTheme","useCall","useHasOngoingScreenShare","useLocalParticipant","useCallStateHooks","useAutoEnterPiPEffect","remoteParticipants","setRemoteParticipants","state","useEffect","sub","remoteParticipants$","pipe","debounceTime","subscribe","unsubscribe","localParticipant","isInPiPMode","useIsInPiPMode","hasScreenShare","showSpotlightLayout","Platform","OS","unsubFunc","on","videoLoggerSystem","getLogger","debug","NativeModules","StreamVideoReactNative","exitPipMode","subscription","callingState$","CallingState","LEFT","showFloatingView","isRemoteParticipantInFloatingView","incallManagerModeRef","useRef","prevInCallManager","getRNInCallManagerLibNoThrow","start","media","current","stop","handleFloatingViewParticipantSwitch","prevState","participantViewProps","callParticipantsGridProps","showLocalParticipant","callParticipantsSpotlightProps","landscapeStyles","flexDirection","createElement","Fragment","RTCViewPipIOS","includeLocalParticipantVideo","View","style","container","content","callParticipantsContainer","view","topContainer","pointerEvents","participant","onPressHandler","objectFit","CallParticipantsSpotlight","CallParticipantsGrid","exports","useMemo","StyleSheet","create","flex","paddingBottom","variants","insets","bottom","paddingLeft","left","paddingRight","right","paddingTop","top","backgroundColor","colors","sheetPrimary","absoluteFillObject","zIndex","Z_INDEX","IN_FRONT"],"sourceRoot":"../../../../../src","sources":["components/Call/CallContent/CallContent.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAOA,IAAAE,WAAA,GAAAF,OAAA;AAMA,IAAAG,aAAA,GAAAH,OAAA;AAKA,IAAAI,mBAAA,GAAAJ,OAAA;AACA,IAAAK,YAAA,GAAAL,OAAA;AAMA,IAAAM,KAAA,GAAAN,OAAA;AAEA,IAAAO,UAAA,GAAAP,OAAA;AACA,IAAAQ,YAAA,GAAAR,OAAA;AAKA,IAAAS,SAAA,GAAAT,OAAA;AAKA,IAAAU,MAAA,GAAAV,OAAA;AACA,IAAAW,mBAAA,GAAAX,OAAA;AAIA,IAAAY,cAAA,GAAAZ,OAAA;AACA,IAAAa,iBAAA,GAAAb,OAAA;AAA8F,SAAAD,wBAAAe,CAAA,EAAA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,CAAAsI,yBAAyB,EAAKlB,8BAAiC,CAAC,gBAEjExH,MAAA,CAAA0B,OAAA,CAAAiG,aAAA,CAACvH,WAAA,CAAAuI,oBAAoB,EAAKrB,yBAA4B,CAEpD,CAAC,EAEN,CAAC/B,WAAW,IAAI3C,YAAY,iBAC3B5C,MAAA,CAAA0B,OAAA,CAAAiG,aAAA,CAAC/E,YAAY;IACXF,mBAAmB,EAAEA,mBAAoB;IACzCgB,SAAS,EAAEA;EAAU,CACtB,CAEC,CACN,CAAC;AAEP,CAAC;AAACkF,OAAA,CAAAnG,WAAA,GAAAA,WAAA;AAEF,MAAM0B,SAAS,GAAGA,CAAA,KAAM;EACtB,MAAM;IAAEC;EAAM,CAAC,GAAG,IAAAE,kBAAQ,EAAC,CAAC;EAC5B,OAAO,IAAAuE,cAAO,EACZ,MACEC,uBAAU,CAACC,MAAM,CAAC;IAChBd,SAAS,EAAE;MACTe,IAAI,EAAE,CAAC;MACPC,aAAa,EAAE7E,KAAK,CAAC8E,QAAQ,CAACC,MAAM,CAACC,MAAM;MAC3CC,WAAW,EAAEjF,KAAK,CAAC8E,QAAQ,CAACC,MAAM,CAACG,IAAI;MACvCC,YAAY,EAAEnF,KAAK,CAAC8E,QAAQ,CAACC,MAAM,CAACK,KAAK;MACzCC,UAAU,EAAErF,KAAK,CAAC8E,QAAQ,CAACC,MAAM,CAACO,GAAG;MACrCC,eAAe,EAAEvF,KAAK,CAACwF,MAAM,CAACC;IAChC,CAAC;IACD3B,OAAO,EAAE;MAAEc,IAAI,EAAE;IAAE,CAAC;IACpBZ,IAAI,EAAE;MACJ,GAAGU,uBAAU,CAACgB,kBAAkB;MAChCC,MAAM,EAAEC,kBAAO,CAACC;IAClB;EACF,CAAC,CAAC,EACJ,CAAC7F,KAAK,CACR,CAAC;AACH,CAAC","ignoreList":[]}
|
|
@@ -9,7 +9,7 @@ var _videoReactBindings = require("@stream-io/video-react-bindings");
|
|
|
9
9
|
var _react = _interopRequireWildcard(require("react"));
|
|
10
10
|
var _reactNative = require("react-native");
|
|
11
11
|
var _RTCViewPipNative = require("./RTCViewPipNative");
|
|
12
|
-
var
|
|
12
|
+
var _rxjs = require("rxjs");
|
|
13
13
|
var _shouldDisableIOSLocalVideoOnBackground = require("../../../utils/internal/shouldDisableIOSLocalVideoOnBackground");
|
|
14
14
|
var _useTrackDimensions = require("../../../hooks/useTrackDimensions");
|
|
15
15
|
var _rxSubjects = require("../../../utils/internal/rxSubjects");
|
|
@@ -22,17 +22,25 @@ const RTCViewPipIOS = exports.RTCViewPipIOS = /*#__PURE__*/_react.default.memo(p
|
|
|
22
22
|
} = props;
|
|
23
23
|
const call = (0, _videoReactBindings.useCall)();
|
|
24
24
|
const {
|
|
25
|
-
|
|
26
|
-
|
|
25
|
+
useCameraState,
|
|
26
|
+
useCallCallingState
|
|
27
27
|
} = (0, _videoReactBindings.useCallStateHooks)();
|
|
28
|
-
const
|
|
29
|
-
sortBy: _videoClient.speakerLayoutSortPreset
|
|
30
|
-
});
|
|
28
|
+
const callingState = useCallCallingState();
|
|
31
29
|
const {
|
|
32
30
|
direction
|
|
33
31
|
} = useCameraState();
|
|
34
|
-
const allParticipants = (0,
|
|
32
|
+
const [allParticipants, setAllParticipants] = (0, _react.useState)(call?.state.participants ?? []);
|
|
35
33
|
|
|
34
|
+
// we debounce the participants to avoid unnecessary rerenders
|
|
35
|
+
// that happen when participant tracks are all subscribed simultaneously
|
|
36
|
+
(0, _react.useEffect)(() => {
|
|
37
|
+
if (!call) {
|
|
38
|
+
setAllParticipants([]);
|
|
39
|
+
return;
|
|
40
|
+
}
|
|
41
|
+
const subscription = call.state.participants$.pipe((0, _rxjs.debounceTime)(300)).subscribe(setAllParticipants);
|
|
42
|
+
return () => subscription.unsubscribe();
|
|
43
|
+
}, [call]);
|
|
36
44
|
const [dominantSpeaker, dominantSpeaker2] = allParticipants.filter(participant => includeLocalParticipantVideo ? true : !participant.isLocalParticipant);
|
|
37
45
|
|
|
38
46
|
// show the dominant remote speaker in PiP mode
|
|
@@ -86,22 +94,50 @@ const RTCViewPipIOS = exports.RTCViewPipIOS = /*#__PURE__*/_react.default.memo(p
|
|
|
86
94
|
} = participantInSpotlight || {};
|
|
87
95
|
const isScreenSharing = participantInSpotlight ? (0, _videoClient.hasScreenShare)(participantInSpotlight) : false;
|
|
88
96
|
const videoStreamToRender = isScreenSharing ? screenShareStream : videoStream;
|
|
97
|
+
const isPublishingTrack = isScreenSharing || participantInSpotlight && (0, _videoClient.hasVideo)(participantInSpotlight);
|
|
98
|
+
const streamURL = isPublishingTrack ? videoStreamToRender?.toURL() : undefined;
|
|
89
99
|
const mirror = isScreenSharing ? false : mirrorOverride !== undefined ? mirrorOverride : !!participantInSpotlight?.isLocalParticipant && direction === 'front';
|
|
90
|
-
const streamURL = (0, _react.useMemo)(() => {
|
|
91
|
-
if (!videoStreamToRender) {
|
|
92
|
-
return undefined;
|
|
93
|
-
}
|
|
94
|
-
return videoStreamToRender?.toURL();
|
|
95
|
-
}, [videoStreamToRender]);
|
|
96
100
|
const handlePiPChange = event => {
|
|
97
101
|
_rxSubjects.isInPiPMode$.next(event.nativeEvent.active);
|
|
98
102
|
onPiPChange?.(event.nativeEvent.active);
|
|
99
103
|
};
|
|
104
|
+
|
|
105
|
+
// Get participant info for avatar placeholder
|
|
106
|
+
const participantName = participantInSpotlight?.name || undefined;
|
|
107
|
+
const participantImageURL = participantInSpotlight?.image || undefined;
|
|
108
|
+
|
|
109
|
+
// Determine if the call is reconnecting or offline
|
|
110
|
+
const isReconnecting = callingState === _videoClient.CallingState.MIGRATING || callingState === _videoClient.CallingState.RECONNECTING || callingState === _videoClient.CallingState.RECONNECTING_FAILED || callingState === _videoClient.CallingState.OFFLINE;
|
|
111
|
+
|
|
112
|
+
// Determine if the participant has audio enabled
|
|
113
|
+
const participantHasAudio = participantInSpotlight ? (0, _videoClient.hasAudio)(participantInSpotlight) : true;
|
|
114
|
+
|
|
115
|
+
// Determine if the video track is paused
|
|
116
|
+
const trackType = isScreenSharing ? 'screenShareTrack' : 'videoTrack';
|
|
117
|
+
const isVideoTrackPaused = participantInSpotlight ? (0, _videoClient.hasPausedTrack)(participantInSpotlight, trackType) : false;
|
|
118
|
+
|
|
119
|
+
// Determine if the participant is pinned
|
|
120
|
+
const participantIsPinned = participantInSpotlight ? (0, _videoClient.isPinned)(participantInSpotlight) : false;
|
|
121
|
+
|
|
122
|
+
// Determine if the participant is speaking
|
|
123
|
+
const participantIsSpeaking = participantInSpotlight?.isSpeaking ?? false;
|
|
124
|
+
|
|
125
|
+
// Get connection quality (convert enum to number: UNSPECIFIED=0, POOR=1, GOOD=2, EXCELLENT=3)
|
|
126
|
+
const participantConnectionQuality = participantInSpotlight?.connectionQuality ?? _videoClient.SfuModels.ConnectionQuality.UNSPECIFIED;
|
|
100
127
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_RTCViewPipNative.RTCViewPipNative, {
|
|
101
128
|
streamURL: streamURL,
|
|
102
129
|
mirror: mirror,
|
|
103
130
|
ref: nativeRef,
|
|
104
|
-
onPiPChange: handlePiPChange
|
|
131
|
+
onPiPChange: handlePiPChange,
|
|
132
|
+
participantName: participantName,
|
|
133
|
+
participantImageURL: participantImageURL,
|
|
134
|
+
isReconnecting: isReconnecting,
|
|
135
|
+
isScreenSharing: isScreenSharing,
|
|
136
|
+
hasAudio: participantHasAudio,
|
|
137
|
+
isTrackPaused: isVideoTrackPaused,
|
|
138
|
+
isPinned: participantIsPinned,
|
|
139
|
+
isSpeaking: participantIsSpeaking,
|
|
140
|
+
connectionQuality: participantConnectionQuality
|
|
105
141
|
}), participantInSpotlight && /*#__PURE__*/_react.default.createElement(DimensionsUpdatedRenderless, {
|
|
106
142
|
participant: participantInSpotlight,
|
|
107
143
|
trackType: isScreenSharing ? 'screenShareTrack' : 'videoTrack',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_videoClient","require","_videoReactBindings","_react","_interopRequireWildcard","_reactNative","_RTCViewPipNative","
|
|
1
|
+
{"version":3,"names":["_videoClient","require","_videoReactBindings","_react","_interopRequireWildcard","_reactNative","_RTCViewPipNative","_rxjs","_shouldDisableIOSLocalVideoOnBackground","_useTrackDimensions","_rxSubjects","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","RTCViewPipIOS","exports","React","memo","props","includeLocalParticipantVideo","mirror","mirrorOverride","onPiPChange","useCall","useCameraState","useCallCallingState","useCallStateHooks","callingState","direction","allParticipants","setAllParticipants","useState","state","participants","useEffect","subscription","participants$","pipe","debounceTime","subscribe","unsubscribe","dominantSpeaker","dominantSpeaker2","filter","participant","isLocalParticipant","participantInSpotlight","shouldDisableIOSLocalVideoOnBackgroundRef","current","nativeRef","useRef","callClosedInvokedOnce","onCallClosed","node","findNodeHandle","onNativeCallClosed","unsubFunc","on","videoLoggerSystem","getLogger","debug","callingState$","CallingState","LEFT","onDimensionsUpdated","useCallback","width","height","onNativeDimensionsUpdated","videoStream","screenShareStream","isScreenSharing","hasScreenShare","videoStreamToRender","isPublishingTrack","hasVideo","streamURL","toURL","undefined","handlePiPChange","event","isInPiPMode$","next","nativeEvent","active","participantName","name","participantImageURL","image","isReconnecting","MIGRATING","RECONNECTING","RECONNECTING_FAILED","OFFLINE","participantHasAudio","hasAudio","trackType","isVideoTrackPaused","hasPausedTrack","participantIsPinned","isPinned","participantIsSpeaking","isSpeaking","participantConnectionQuality","connectionQuality","SfuModels","ConnectionQuality","UNSPECIFIED","createElement","Fragment","RTCViewPipNative","ref","isTrackPaused","DimensionsUpdatedRenderless","key","useTrackDimensions","displayName"],"sourceRoot":"../../../../../src","sources":["components/Call/CallContent/RTCViewPipIOS.tsx"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAYA,IAAAC,mBAAA,GAAAD,OAAA;AAEA,IAAAE,MAAA,GAAAC,uBAAA,CAAAH,OAAA;AACA,IAAAI,YAA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AA,CAAAkB,OAAA,CAAAuG,aAAA,CAACK,2BAA2B;IAC1BrE,WAAW,EAAEE,sBAAuB;IACpCkD,SAAS,EAAEzB,eAAe,GAAG,kBAAkB,GAAG,YAAa;IAC/DP,mBAAmB,EAAEA,mBAAoB;IACzCkD,GAAG,EAAEtC;EAAU,CAChB,CAEH,CAAC;AAEP,CAAC,CAAC;AAEF,MAAMqC,2BAA2B,gBAAGjG,cAAK,CAACC,IAAI,CAC5C,CAAC;EACC2B,WAAW;EACXoD,SAAS;EACThC;AAKF,CAAC,KAAK;EACJ,MAAM;IAAEE,KAAK;IAAEC;EAAO,CAAC,GAAG,IAAAgD,sCAAkB,EAACvE,WAAW,EAAEoD,SAAS,CAAC;EAEpE,IAAA9D,gBAAS,EAAC,MAAM;IACd8B,mBAAmB,CAACE,KAAK,EAAEC,MAAM,CAAC;EACpC,CAAC,EAAE,CAACD,KAAK,EAAEC,MAAM,EAAEH,mBAAmB,CAAC,CAAC;EAExC,OAAO,IAAI;AACb,CACF,CAAC;AAEDiD,2BAA2B,CAACG,WAAW,GAAG,6BAA6B;AACvEtG,aAAa,CAACsG,WAAW,GAAG,eAAe","ignoreList":[]}
|
|
@@ -44,6 +44,33 @@ const RTCViewPipNative = exports.RTCViewPipNative = /*#__PURE__*/_react.default.
|
|
|
44
44
|
// eslint-disable-next-line react/prop-types
|
|
45
45
|
,
|
|
46
46
|
onPiPChange: props.onPiPChange
|
|
47
|
+
// eslint-disable-next-line react/prop-types
|
|
48
|
+
,
|
|
49
|
+
participantName: props.participantName
|
|
50
|
+
// eslint-disable-next-line react/prop-types
|
|
51
|
+
,
|
|
52
|
+
participantImageURL: props.participantImageURL
|
|
53
|
+
// eslint-disable-next-line react/prop-types
|
|
54
|
+
,
|
|
55
|
+
isReconnecting: props.isReconnecting
|
|
56
|
+
// eslint-disable-next-line react/prop-types
|
|
57
|
+
,
|
|
58
|
+
isScreenSharing: props.isScreenSharing
|
|
59
|
+
// eslint-disable-next-line react/prop-types
|
|
60
|
+
,
|
|
61
|
+
hasAudio: props.hasAudio
|
|
62
|
+
// eslint-disable-next-line react/prop-types
|
|
63
|
+
,
|
|
64
|
+
isTrackPaused: props.isTrackPaused
|
|
65
|
+
// eslint-disable-next-line react/prop-types
|
|
66
|
+
,
|
|
67
|
+
isPinned: props.isPinned
|
|
68
|
+
// eslint-disable-next-line react/prop-types
|
|
69
|
+
,
|
|
70
|
+
isSpeaking: props.isSpeaking
|
|
71
|
+
// eslint-disable-next-line react/prop-types
|
|
72
|
+
,
|
|
73
|
+
connectionQuality: props.connectionQuality
|
|
47
74
|
// @ts-expect-error - types issue
|
|
48
75
|
,
|
|
49
76
|
ref: ref
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_videoClient","e","__esModule","default","COMPONENT_NAME","NativeComponent","requireNativeComponent","onNativeCallClosed","reactTag","videoLoggerSystem","getLogger","debug","commandId","UIManager","getViewManagerConfig","Commands","onCallClosed","dispatchViewManagerCommand","onNativeDimensionsUpdated","width","height","setPreferredContentSize","RTCViewPipNative","exports","React","memo","forwardRef","props","ref","Platform","OS","createElement","style","StyleSheet","absoluteFill","pointerEvents","streamURL","mirror","onPiPChange"],"sourceRoot":"../../../../../src","sources":["components/Call/CallContent/RTCViewPipNative.tsx"],"mappings":";;;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAOA,IAAAE,YAAA,GAAAF,OAAA;AAA4D,SAAAD,uBAAAI,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAE5D,MAAMG,cAAc,GAAG,YAAY;
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_videoClient","e","__esModule","default","COMPONENT_NAME","NativeComponent","requireNativeComponent","onNativeCallClosed","reactTag","videoLoggerSystem","getLogger","debug","commandId","UIManager","getViewManagerConfig","Commands","onCallClosed","dispatchViewManagerCommand","onNativeDimensionsUpdated","width","height","setPreferredContentSize","RTCViewPipNative","exports","React","memo","forwardRef","props","ref","Platform","OS","createElement","style","StyleSheet","absoluteFill","pointerEvents","streamURL","mirror","onPiPChange","participantName","participantImageURL","isReconnecting","isScreenSharing","hasAudio","isTrackPaused","isPinned","isSpeaking","connectionQuality"],"sourceRoot":"../../../../../src","sources":["components/Call/CallContent/RTCViewPipNative.tsx"],"mappings":";;;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAOA,IAAAE,YAAA,GAAAF,OAAA;AAA4D,SAAAD,uBAAAI,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAE5D,MAAMG,cAAc,GAAG,YAAY;AA8BnC,MAAMC,eAAqD,GACzD,IAAAC,mCAAsB,EAACF,cAAc,CAAC;AAEjC,SAASG,kBAAkBA,CAACC,QAAgB,EAAE;EACnDC,8BAAiB,CAACC,SAAS,CAAC,kBAAkB,CAAC,CAACC,KAAK,CAAC,oBAAoB,CAAC;EAC3E,MAAMC,SAAS,GACbC,sBAAS,CAACC,oBAAoB,CAACV,cAAc,CAAC,CAACW,QAAQ,CAACC,YAAY;EACtE,IAAI,CAACJ,SAAS,EAAE;EAChBC,sBAAS,CAACI,0BAA0B,CAACT,QAAQ,EAAEI,SAAS,EAAE,EAAE,CAAC;AAC/D;AAEO,SAASM,yBAAyBA,CACvCV,QAAgB,EAChBW,KAAa,EACbC,MAAc,EACd;EACAX,8BAAiB,CACdC,SAAS,CAAC,kBAAkB,CAAC,CAC7BC,KAAK,CAAC,2BAA2B,EAAE;IAClCQ,KAAK;IACLC;EACF,CAAC,CAAC;EACJ,MAAMR,SAAS,GACbC,sBAAS,CAACC,oBAAoB,CAACV,cAAc,CAAC,CAACW,QAAQ,CACpDM,uBAAuB;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