@stream-io/video-react-native-sdk 1.29.0-beta.1 → 1.29.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (198) hide show
  1. package/CHANGELOG.md +3114 -0
  2. package/android/src/main/AndroidManifest.xml +1 -8
  3. package/android/src/main/AndroidManifestNew.xml +0 -11
  4. package/android/src/main/java/com/streamvideo/reactnative/StreamVideoReactNativeModule.kt +5 -42
  5. package/android/src/main/java/com/streamvideo/reactnative/audio/utils/WebRtcAudioUtils.kt +6 -70
  6. package/android/src/main/java/com/streamvideo/reactnative/callmanager/StreamInCallManagerModule.kt +4 -6
  7. package/android/src/main/java/com/streamvideo/reactnative/util/CallAliveServiceChecker.kt +95 -0
  8. package/dist/commonjs/hooks/push/useIosCallkeepWithCallingStateEffect.js +160 -0
  9. package/dist/commonjs/hooks/push/useIosCallkeepWithCallingStateEffect.js.map +1 -0
  10. package/dist/commonjs/hooks/push/useIosVoipPushEventsSetupEffect.js +31 -18
  11. package/dist/commonjs/hooks/push/useIosVoipPushEventsSetupEffect.js.map +1 -1
  12. package/dist/commonjs/hooks/useAndroidKeepCallAliveEffect.js +97 -64
  13. package/dist/commonjs/hooks/useAndroidKeepCallAliveEffect.js.map +1 -1
  14. package/dist/commonjs/index.js +0 -1
  15. package/dist/commonjs/index.js.map +1 -1
  16. package/dist/commonjs/modules/call-manager/CallManager.js +0 -26
  17. package/dist/commonjs/modules/call-manager/CallManager.js.map +1 -1
  18. package/dist/commonjs/providers/StreamCall/index.js +6 -6
  19. package/dist/commonjs/providers/StreamCall/index.js.map +1 -1
  20. package/dist/commonjs/utils/StreamVideoRN/index.js +21 -33
  21. package/dist/commonjs/utils/StreamVideoRN/index.js.map +1 -1
  22. package/dist/commonjs/utils/internal/registerSDKGlobals.js +3 -52
  23. package/dist/commonjs/utils/internal/registerSDKGlobals.js.map +1 -1
  24. package/dist/commonjs/utils/push/android.js +200 -145
  25. package/dist/commonjs/utils/push/android.js.map +1 -1
  26. package/dist/commonjs/utils/push/internal/ios.js +34 -16
  27. package/dist/commonjs/utils/push/internal/ios.js.map +1 -1
  28. package/dist/commonjs/utils/push/internal/rxSubjects.js +20 -1
  29. package/dist/commonjs/utils/push/internal/rxSubjects.js.map +1 -1
  30. package/dist/commonjs/utils/push/internal/utils.js +1 -17
  31. package/dist/commonjs/utils/push/internal/utils.js.map +1 -1
  32. package/dist/commonjs/utils/push/ios.js.map +1 -1
  33. package/dist/commonjs/utils/push/libs/callkeep.js +17 -0
  34. package/dist/commonjs/utils/push/libs/callkeep.js.map +1 -0
  35. package/dist/commonjs/utils/push/libs/index.js +19 -8
  36. package/dist/commonjs/utils/push/libs/index.js.map +1 -1
  37. package/dist/commonjs/utils/push/libs/notifee/index.js +19 -0
  38. package/dist/commonjs/utils/push/libs/notifee/index.js.map +1 -1
  39. package/dist/commonjs/utils/push/libs/voipPushNotification.js +17 -0
  40. package/dist/commonjs/utils/push/libs/voipPushNotification.js.map +1 -0
  41. package/dist/commonjs/utils/push/setupIosCallKeepEvents.js +205 -0
  42. package/dist/commonjs/utils/push/setupIosCallKeepEvents.js.map +1 -0
  43. package/dist/commonjs/utils/push/setupIosVoipPushEvents.js +6 -7
  44. package/dist/commonjs/utils/push/setupIosVoipPushEvents.js.map +1 -1
  45. package/dist/commonjs/version.js +1 -1
  46. package/dist/commonjs/version.js.map +1 -1
  47. package/dist/module/hooks/push/useIosCallkeepWithCallingStateEffect.js +153 -0
  48. package/dist/module/hooks/push/useIosCallkeepWithCallingStateEffect.js.map +1 -0
  49. package/dist/module/hooks/push/useIosVoipPushEventsSetupEffect.js +31 -18
  50. package/dist/module/hooks/push/useIosVoipPushEventsSetupEffect.js.map +1 -1
  51. package/dist/module/hooks/useAndroidKeepCallAliveEffect.js +99 -66
  52. package/dist/module/hooks/useAndroidKeepCallAliveEffect.js.map +1 -1
  53. package/dist/module/index.js +0 -1
  54. package/dist/module/index.js.map +1 -1
  55. package/dist/module/modules/call-manager/CallManager.js +0 -26
  56. package/dist/module/modules/call-manager/CallManager.js.map +1 -1
  57. package/dist/module/providers/StreamCall/index.js +6 -6
  58. package/dist/module/providers/StreamCall/index.js.map +1 -1
  59. package/dist/module/utils/StreamVideoRN/index.js +21 -33
  60. package/dist/module/utils/StreamVideoRN/index.js.map +1 -1
  61. package/dist/module/utils/internal/registerSDKGlobals.js +4 -53
  62. package/dist/module/utils/internal/registerSDKGlobals.js.map +1 -1
  63. package/dist/module/utils/push/android.js +202 -147
  64. package/dist/module/utils/push/android.js.map +1 -1
  65. package/dist/module/utils/push/internal/ios.js +34 -16
  66. package/dist/module/utils/push/internal/ios.js.map +1 -1
  67. package/dist/module/utils/push/internal/rxSubjects.js +19 -0
  68. package/dist/module/utils/push/internal/rxSubjects.js.map +1 -1
  69. package/dist/module/utils/push/internal/utils.js +0 -14
  70. package/dist/module/utils/push/internal/utils.js.map +1 -1
  71. package/dist/module/utils/push/ios.js.map +1 -1
  72. package/dist/module/utils/push/libs/callkeep.js +11 -0
  73. package/dist/module/utils/push/libs/callkeep.js.map +1 -0
  74. package/dist/module/utils/push/libs/index.js +2 -1
  75. package/dist/module/utils/push/libs/index.js.map +1 -1
  76. package/dist/module/utils/push/libs/notifee/index.js +18 -0
  77. package/dist/module/utils/push/libs/notifee/index.js.map +1 -1
  78. package/dist/module/utils/push/libs/voipPushNotification.js +11 -0
  79. package/dist/module/utils/push/libs/voipPushNotification.js.map +1 -0
  80. package/dist/module/utils/push/setupIosCallKeepEvents.js +199 -0
  81. package/dist/module/utils/push/setupIosCallKeepEvents.js.map +1 -0
  82. package/dist/module/utils/push/setupIosVoipPushEvents.js +6 -7
  83. package/dist/module/utils/push/setupIosVoipPushEvents.js.map +1 -1
  84. package/dist/module/version.js +1 -1
  85. package/dist/module/version.js.map +1 -1
  86. package/dist/typescript/hooks/push/useIosCallkeepWithCallingStateEffect.d.ts +5 -0
  87. package/dist/typescript/hooks/push/useIosCallkeepWithCallingStateEffect.d.ts.map +1 -0
  88. package/dist/typescript/hooks/push/useIosVoipPushEventsSetupEffect.d.ts.map +1 -1
  89. package/dist/typescript/hooks/useAndroidKeepCallAliveEffect.d.ts.map +1 -1
  90. package/dist/typescript/index.d.ts +0 -1
  91. package/dist/typescript/index.d.ts.map +1 -1
  92. package/dist/typescript/modules/call-manager/CallManager.d.ts +0 -5
  93. package/dist/typescript/modules/call-manager/CallManager.d.ts.map +1 -1
  94. package/dist/typescript/utils/StreamVideoRN/index.d.ts +2 -20
  95. package/dist/typescript/utils/StreamVideoRN/index.d.ts.map +1 -1
  96. package/dist/typescript/utils/StreamVideoRN/types.d.ts +29 -54
  97. package/dist/typescript/utils/StreamVideoRN/types.d.ts.map +1 -1
  98. package/dist/typescript/utils/internal/registerSDKGlobals.d.ts.map +1 -1
  99. package/dist/typescript/utils/push/android.d.ts +2 -1
  100. package/dist/typescript/utils/push/android.d.ts.map +1 -1
  101. package/dist/typescript/utils/push/internal/ios.d.ts.map +1 -1
  102. package/dist/typescript/utils/push/internal/rxSubjects.d.ts +12 -0
  103. package/dist/typescript/utils/push/internal/rxSubjects.d.ts.map +1 -1
  104. package/dist/typescript/utils/push/internal/utils.d.ts +0 -4
  105. package/dist/typescript/utils/push/internal/utils.d.ts.map +1 -1
  106. package/dist/typescript/utils/push/ios.d.ts +2 -1
  107. package/dist/typescript/utils/push/ios.d.ts.map +1 -1
  108. package/dist/typescript/utils/push/libs/callkeep.d.ts +3 -0
  109. package/dist/typescript/utils/push/libs/callkeep.d.ts.map +1 -0
  110. package/dist/typescript/utils/push/libs/firebaseMessaging/index.d.ts +2 -16
  111. package/dist/typescript/utils/push/libs/firebaseMessaging/index.d.ts.map +1 -1
  112. package/dist/typescript/utils/push/libs/index.d.ts +2 -1
  113. package/dist/typescript/utils/push/libs/index.d.ts.map +1 -1
  114. package/dist/typescript/utils/push/libs/notifee/index.d.ts +1 -0
  115. package/dist/typescript/utils/push/libs/notifee/index.d.ts.map +1 -1
  116. package/dist/typescript/utils/push/libs/voipPushNotification.d.ts +3 -0
  117. package/dist/typescript/utils/push/libs/voipPushNotification.d.ts.map +1 -0
  118. package/dist/typescript/utils/push/setupIosCallKeepEvents.d.ts +6 -0
  119. package/dist/typescript/utils/push/setupIosCallKeepEvents.d.ts.map +1 -0
  120. package/dist/typescript/utils/push/setupIosVoipPushEvents.d.ts.map +1 -1
  121. package/dist/typescript/version.d.ts +1 -1
  122. package/dist/typescript/version.d.ts.map +1 -1
  123. package/expo-config-plugin/dist/withAndroidManifest.js +33 -1
  124. package/expo-config-plugin/dist/withAndroidPermissions.js +7 -2
  125. package/expo-config-plugin/dist/withAppDelegate.js +197 -19
  126. package/expo-config-plugin/dist/withMainActivity.js +1 -1
  127. package/expo-config-plugin/dist/withiOSInfoPlist.js +3 -2
  128. package/ios/StreamInCallManager.m +0 -2
  129. package/ios/StreamInCallManager.swift +5 -20
  130. package/ios/StreamVideoReactNative.h +4 -7
  131. package/ios/StreamVideoReactNative.m +82 -191
  132. package/package.json +17 -12
  133. package/src/hooks/push/useIosCallkeepWithCallingStateEffect.ts +235 -0
  134. package/src/hooks/push/useIosVoipPushEventsSetupEffect.ts +34 -21
  135. package/src/hooks/useAndroidKeepCallAliveEffect.ts +120 -94
  136. package/src/index.ts +0 -1
  137. package/src/modules/call-manager/CallManager.ts +0 -36
  138. package/src/modules/call-manager/native-module.d.ts +0 -7
  139. package/src/providers/StreamCall/index.tsx +6 -6
  140. package/src/utils/StreamVideoRN/index.ts +30 -40
  141. package/src/utils/StreamVideoRN/types.ts +29 -56
  142. package/src/utils/internal/registerSDKGlobals.ts +4 -47
  143. package/src/utils/push/android.ts +308 -223
  144. package/src/utils/push/internal/ios.ts +46 -25
  145. package/src/utils/push/internal/rxSubjects.ts +29 -0
  146. package/src/utils/push/internal/utils.ts +0 -25
  147. package/src/utils/push/ios.ts +6 -1
  148. package/src/utils/push/libs/callkeep.ts +16 -0
  149. package/src/utils/push/libs/index.ts +2 -1
  150. package/src/utils/push/libs/notifee/index.ts +27 -0
  151. package/src/utils/push/libs/voipPushNotification.ts +17 -0
  152. package/src/utils/push/setupIosCallKeepEvents.ts +252 -0
  153. package/src/utils/push/setupIosVoipPushEvents.ts +7 -11
  154. package/src/version.ts +1 -1
  155. package/android/src/main/java/com/streamvideo/reactnative/keepalive/KeepAliveNotification.kt +0 -83
  156. package/android/src/main/java/com/streamvideo/reactnative/keepalive/StreamCallKeepAliveHeadlessService.kt +0 -134
  157. package/dist/commonjs/hooks/push/useCallingExpWithCallingStateEffect.js +0 -216
  158. package/dist/commonjs/hooks/push/useCallingExpWithCallingStateEffect.js.map +0 -1
  159. package/dist/commonjs/utils/internal/audioSessionPromise.js +0 -46
  160. package/dist/commonjs/utils/internal/audioSessionPromise.js.map +0 -1
  161. package/dist/commonjs/utils/internal/callingx.js +0 -84
  162. package/dist/commonjs/utils/internal/callingx.js.map +0 -1
  163. package/dist/commonjs/utils/keepCallAliveHeadlessTask.js +0 -48
  164. package/dist/commonjs/utils/keepCallAliveHeadlessTask.js.map +0 -1
  165. package/dist/commonjs/utils/push/libs/callingx.js +0 -75
  166. package/dist/commonjs/utils/push/libs/callingx.js.map +0 -1
  167. package/dist/commonjs/utils/push/setupCallingExpEvents.js +0 -97
  168. package/dist/commonjs/utils/push/setupCallingExpEvents.js.map +0 -1
  169. package/dist/module/hooks/push/useCallingExpWithCallingStateEffect.js +0 -209
  170. package/dist/module/hooks/push/useCallingExpWithCallingStateEffect.js.map +0 -1
  171. package/dist/module/utils/internal/audioSessionPromise.js +0 -39
  172. package/dist/module/utils/internal/audioSessionPromise.js.map +0 -1
  173. package/dist/module/utils/internal/callingx.js +0 -75
  174. package/dist/module/utils/internal/callingx.js.map +0 -1
  175. package/dist/module/utils/keepCallAliveHeadlessTask.js +0 -42
  176. package/dist/module/utils/keepCallAliveHeadlessTask.js.map +0 -1
  177. package/dist/module/utils/push/libs/callingx.js +0 -67
  178. package/dist/module/utils/push/libs/callingx.js.map +0 -1
  179. package/dist/module/utils/push/setupCallingExpEvents.js +0 -91
  180. package/dist/module/utils/push/setupCallingExpEvents.js.map +0 -1
  181. package/dist/typescript/hooks/push/useCallingExpWithCallingStateEffect.d.ts +0 -5
  182. package/dist/typescript/hooks/push/useCallingExpWithCallingStateEffect.d.ts.map +0 -1
  183. package/dist/typescript/utils/internal/audioSessionPromise.d.ts +0 -16
  184. package/dist/typescript/utils/internal/audioSessionPromise.d.ts.map +0 -1
  185. package/dist/typescript/utils/internal/callingx.d.ts +0 -13
  186. package/dist/typescript/utils/internal/callingx.d.ts.map +0 -1
  187. package/dist/typescript/utils/keepCallAliveHeadlessTask.d.ts +0 -10
  188. package/dist/typescript/utils/keepCallAliveHeadlessTask.d.ts.map +0 -1
  189. package/dist/typescript/utils/push/libs/callingx.d.ts +0 -9
  190. package/dist/typescript/utils/push/libs/callingx.d.ts.map +0 -1
  191. package/dist/typescript/utils/push/setupCallingExpEvents.d.ts +0 -8
  192. package/dist/typescript/utils/push/setupCallingExpEvents.d.ts.map +0 -1
  193. package/src/hooks/push/useCallingExpWithCallingStateEffect.ts +0 -307
  194. package/src/utils/internal/audioSessionPromise.ts +0 -39
  195. package/src/utils/internal/callingx.ts +0 -108
  196. package/src/utils/keepCallAliveHeadlessTask.ts +0 -54
  197. package/src/utils/push/libs/callingx.ts +0 -90
  198. package/src/utils/push/setupCallingExpEvents.ts +0 -117
@@ -1,134 +0,0 @@
1
- package com.streamvideo.reactnative.keepalive
2
-
3
- import android.Manifest
4
- import android.content.Intent
5
- import android.content.pm.PackageManager
6
- import android.content.pm.ServiceInfo
7
- import android.os.Build
8
- import androidx.annotation.RequiresApi
9
- import androidx.core.app.ServiceCompat
10
- import androidx.core.content.ContextCompat
11
- import com.facebook.react.HeadlessJsTaskService
12
- import com.facebook.react.bridge.Arguments
13
- import com.facebook.react.jstasks.HeadlessJsTaskConfig
14
-
15
- /**
16
- * Foreground service that runs a React Native HeadlessJS task to keep a call alive.
17
- *
18
- */
19
- class StreamCallKeepAliveHeadlessService : HeadlessJsTaskService() {
20
-
21
- override fun onStartCommand(intent: Intent?, flags: Int, startId: Int): Int {
22
- val safeIntent = intent ?: Intent()
23
- val channelId = safeIntent.getStringExtra(EXTRA_CHANNEL_ID) ?: DEFAULT_CHANNEL_ID
24
- val channelName = safeIntent.getStringExtra(EXTRA_CHANNEL_NAME) ?: DEFAULT_CHANNEL_NAME
25
- val title = safeIntent.getStringExtra(EXTRA_TITLE) ?: DEFAULT_TITLE
26
- val body = safeIntent.getStringExtra(EXTRA_BODY) ?: DEFAULT_BODY
27
- val smallIconName = safeIntent.getStringExtra(EXTRA_SMALL_ICON_NAME)
28
-
29
- KeepAliveNotification.ensureChannel(this, channelId, channelName)
30
- val notification = KeepAliveNotification.buildOngoingNotification(
31
- context = this,
32
- channelId = channelId,
33
- title = title,
34
- body = body,
35
- smallIconName = smallIconName
36
- )
37
-
38
- startForegroundCompat(notification)
39
-
40
- // Ensure HeadlessJS task is started
41
- return super.onStartCommand(safeIntent, flags, startId)
42
- }
43
-
44
- override fun getTaskConfig(intent: Intent?): HeadlessJsTaskConfig? {
45
- val callCid = intent?.getStringExtra(EXTRA_CALL_CID) ?: return null
46
- val data = Arguments.createMap().apply {
47
- putString("callCid", callCid)
48
- }
49
- // We intentionally allow long-running work (the JS task can return a never-resolving Promise).
50
- return HeadlessJsTaskConfig(
51
- TASK_NAME,
52
- data,
53
- 0, // timeout (0 = no timeout)
54
- true // allowedInForeground
55
- )
56
- }
57
-
58
- override fun onDestroy() {
59
- super.onDestroy()
60
- stopForeground(STOP_FOREGROUND_REMOVE)
61
- }
62
-
63
- @RequiresApi(Build.VERSION_CODES.R)
64
- private fun computeForegroundServiceTypes(): Int {
65
- var types = ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PLAYBACK
66
-
67
- val hasCameraPermission =
68
- ContextCompat.checkSelfPermission(this, Manifest.permission.CAMERA) == PackageManager.PERMISSION_GRANTED
69
- if (hasCameraPermission) {
70
- types = types or ServiceInfo.FOREGROUND_SERVICE_TYPE_CAMERA
71
- }
72
-
73
- val hasMicrophonePermission =
74
- ContextCompat.checkSelfPermission(this, Manifest.permission.RECORD_AUDIO) == PackageManager.PERMISSION_GRANTED
75
- if (hasMicrophonePermission) {
76
- types = types or ServiceInfo.FOREGROUND_SERVICE_TYPE_MICROPHONE
77
- }
78
-
79
- return types
80
- }
81
-
82
- private fun startForegroundCompat(notification: android.app.Notification) {
83
- if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) {
84
- val types = if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) computeForegroundServiceTypes() else ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PLAYBACK
85
- startForeground(NOTIFICATION_ID, notification, types)
86
- } else {
87
- startForeground(NOTIFICATION_ID, notification)
88
- }
89
- }
90
-
91
- companion object {
92
- const val TASK_NAME = "StreamVideoKeepCallAlive"
93
-
94
- const val EXTRA_CALL_CID = "callCid"
95
- const val EXTRA_CHANNEL_ID = "channelId"
96
- const val EXTRA_CHANNEL_NAME = "channelName"
97
- const val EXTRA_TITLE = "title"
98
- const val EXTRA_BODY = "body"
99
- const val EXTRA_SMALL_ICON_NAME = "smallIconName"
100
-
101
- private const val NOTIFICATION_ID = 6061
102
-
103
- private const val DEFAULT_CHANNEL_ID = "stream_call_foreground_service"
104
- private const val DEFAULT_CHANNEL_NAME = "Call in progress"
105
- private const val DEFAULT_TITLE = "Call in progress"
106
- private const val DEFAULT_BODY = "Tap to return to the call"
107
-
108
- fun buildStartIntent(
109
- context: android.content.Context,
110
- callCid: String,
111
- channelId: String,
112
- channelName: String,
113
- title: String,
114
- body: String,
115
- smallIconName: String?
116
- ): Intent {
117
- return Intent(context, StreamCallKeepAliveHeadlessService::class.java).apply {
118
- putExtra(EXTRA_CALL_CID, callCid)
119
- putExtra(EXTRA_CHANNEL_ID, channelId)
120
- putExtra(EXTRA_CHANNEL_NAME, channelName)
121
- putExtra(EXTRA_TITLE, title)
122
- putExtra(EXTRA_BODY, body)
123
- if (!smallIconName.isNullOrBlank()) {
124
- putExtra(EXTRA_SMALL_ICON_NAME, smallIconName)
125
- }
126
- }
127
- }
128
-
129
- fun buildStopIntent(context: android.content.Context): Intent {
130
- return Intent(context, StreamCallKeepAliveHeadlessService::class.java)
131
- }
132
- }
133
- }
134
-
@@ -1,216 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.useCallingExpWithCallingStateEffect = void 0;
7
- var _videoClient = require("@stream-io/video-client");
8
- var _videoReactBindings = require("@stream-io/video-react-bindings");
9
- var _react = require("react");
10
- var _callingx = require("../../utils/internal/callingx");
11
- var _callingx2 = require("../../utils/push/libs/callingx");
12
- const logger = _videoClient.videoLoggerSystem.getLogger('Callingx - useCallingExpWithCallingStateEffect');
13
-
14
- //calling state methods are not exhaustive, so we need to add more methods to cover different cases
15
- const canActivateCall = (prevState, currentState) => {
16
- if (!prevState && !currentState) {
17
- return false;
18
- }
19
- const isJoined = state => {
20
- if (!state) {
21
- return false;
22
- }
23
- return state === _videoClient.CallingState.JOINING || state === _videoClient.CallingState.JOINED;
24
- };
25
- return !isJoined(prevState) && isJoined(currentState);
26
- };
27
- const canEndCall = (prevState, currentState) => {
28
- if (!prevState && !currentState) {
29
- return false;
30
- }
31
- return (prevState === _videoClient.CallingState.JOINED || prevState === _videoClient.CallingState.JOINING || prevState === _videoClient.CallingState.RINGING || prevState === _videoClient.CallingState.RECONNECTING || prevState === _videoClient.CallingState.MIGRATING || prevState === _videoClient.CallingState.OFFLINE) && (currentState === _videoClient.CallingState.LEFT || currentState === _videoClient.CallingState.RECONNECTING_FAILED || currentState === _videoClient.CallingState.IDLE);
32
- };
33
-
34
- /**
35
- * This hook is used to inform sync call state with CallKit/Telecom (i.e. start call, end call, mute/unmute call).
36
- */
37
- const useCallingExpWithCallingStateEffect = () => {
38
- const {
39
- useCallCallingState,
40
- // useMicrophoneState,
41
- useParticipants,
42
- useCallMembers
43
- } = (0, _videoReactBindings.useCallStateHooks)();
44
- const activeCall = (0, _videoReactBindings.useCall)();
45
- const callingState = useCallCallingState();
46
- // const { isMute, microphone } = useMicrophoneState();
47
- const callMembers = useCallMembers();
48
- const participants = useParticipants();
49
- const prevState = (0, _react.useRef)(undefined);
50
- const activeCallCid = activeCall?.cid;
51
- const isIncomingCall = activeCall?.ringing && !activeCall?.isCreatedByMe;
52
- const isOutcomingCall = activeCall?.ringing && activeCall?.isCreatedByMe;
53
- const currentUserId = activeCall?.currentUserId;
54
- const isVideoCall = activeCall?.state.settings?.video?.enabled ?? false;
55
- const callDisplayName = (0, _react.useMemo)(() => (0, _callingx.getCallDisplayName)(callMembers, participants, currentUserId), [callMembers, participants, currentUserId]);
56
- (0, _react.useEffect)(() => {
57
- return () => {
58
- const callingx = (0, _callingx2.getCallingxLibIfAvailable)();
59
- if (!callingx?.isSetup || !activeCallCid) {
60
- return;
61
- }
62
- const isCallRegistered = callingx.isCallRegistered(activeCallCid);
63
- if (!isCallRegistered) {
64
- logger.debug(`No active call cid to end in calling exp: ${activeCallCid} isCallRegistered: ${isCallRegistered}`);
65
- return;
66
- }
67
- //if incoming stream call was unmounted, we need to end the call in CallKit/Telecom
68
- logger.debug(`Ending call in callingx: ${activeCallCid}`);
69
- callingx.endCallWithReason(activeCallCid, 'local').catch(error => {
70
- logger.error(`Error ending call in callingx: ${activeCallCid}`, error);
71
- });
72
- };
73
- }, [activeCallCid]);
74
- (0, _react.useEffect)(() => {
75
- const callingx = (0, _callingx2.getCallingxLibIfAvailable)();
76
- if (!callingx?.isSetup || !activeCallCid || prevState.current === callingState) {
77
- return;
78
- }
79
-
80
- //tells if call is registered in CallKit/Telecom
81
- const isCallRegistered = callingx.isCallRegistered(activeCallCid);
82
- logger.debug(`useEffect: ${activeCallCid} isCallRegistered: ${isCallRegistered}
83
- isIncomingCall: ${isIncomingCall} isOutcomingCall: ${isOutcomingCall}
84
- prevState: ${prevState.current}, currentState: ${callingState}
85
- isOngoingCallsEnabled: ${callingx.isOngoingCallsEnabled}`);
86
- if (isIncomingCall && isCallRegistered && canActivateCall(prevState.current, callingState)) {
87
- logger.debug(`Should accept call in callingx: ${activeCallCid}`);
88
- callingx.answerIncomingCall(activeCallCid).catch(error => {
89
- logger.error(`Error answering call in callingx: ${activeCallCid}`, error);
90
- });
91
- } else if ((isOutcomingCall || callingx.isOngoingCallsEnabled) && isCallRegistered && canActivateCall(prevState.current, callingState)) {
92
- logger.debug(`Should set call active in callingx: ${activeCallCid}`);
93
- callingx.setCurrentCallActive(activeCallCid);
94
- } else if (isCallRegistered && canEndCall(prevState.current, callingState)) {
95
- //in case call was registered as incoming and state changed to "not joined", we need to end the call and clear rxjs subject
96
- logger.debug(`Should end call in callingx: ${activeCallCid}`);
97
- //TODO: think about sending appropriate reason for end call
98
- callingx.endCallWithReason(activeCallCid, 'local').catch(error => {
99
- logger.error(`Error ending call in callingx: ${activeCallCid}`, error);
100
- });
101
- }
102
- prevState.current = callingState;
103
- }, [activeCallCid, callingState, callDisplayName, isIncomingCall, isOutcomingCall, isVideoCall]);
104
- (0, _react.useEffect)(() => {
105
- const callingx = (0, _callingx2.getCallingxLibIfAvailable)();
106
- if (!callingx?.isSetup || !activeCallCid) {
107
- return;
108
- }
109
- const isCallRegistered = callingx.isCallRegistered(activeCallCid);
110
- if (!isCallRegistered) {
111
- logger.debug(`No active call cid to update callingx: ${activeCallCid} isCallRegistered: ${isCallRegistered}`);
112
- return;
113
- }
114
- callingx.updateDisplay(activeCallCid, activeCallCid, callDisplayName);
115
- }, [activeCallCid, callDisplayName]);
116
- (0, _react.useEffect)(() => {
117
- const callingx = (0, _callingx2.getCallingxLibIfAvailable)();
118
- if (!callingx?.isSetup || !activeCallCid || !isIncomingCall) {
119
- return;
120
- }
121
- let isUnsubscribed = false;
122
- const subscription = callingx.addEventListener('didDisplayIncomingCall', event => {
123
- if (event.callId === activeCallCid) {
124
- //we need to report the call as answered only if user accepts the call from the app UI and push notification was delivered after that
125
- const _callingState = activeCall?.state.callingState;
126
- const shouldSkip = _callingState !== _videoClient.CallingState.JOINING && _callingState !== _videoClient.CallingState.JOINED && _callingState !== _videoClient.CallingState.RECONNECTING && _callingState !== _videoClient.CallingState.MIGRATING;
127
- if (shouldSkip) {
128
- return;
129
- }
130
- logger.debug(`Reporting the incoming call as answered in callingx as already join() calledin the app: ${activeCallCid}`);
131
- callingx.answerIncomingCall(activeCallCid).catch(error => {
132
- logger.error(`Error answering call in callingx: ${activeCallCid}`, error);
133
- }).finally(() => {
134
- subscription.remove();
135
- isUnsubscribed = true;
136
- });
137
- }
138
- });
139
- return () => {
140
- if (!isUnsubscribed) {
141
- subscription.remove();
142
- }
143
- };
144
- }, [activeCall, activeCallCid, isIncomingCall]);
145
-
146
- // useEffect(() => {
147
- // const callingx = getCallingxLibIfAvailable();
148
- // if (!callingx?.isSetup || !activeCallCid) {
149
- // return;
150
- // }
151
-
152
- // const isCallRegistered = callingx.isCallRegistered(activeCallCid);
153
- // if (!isCallRegistered) {
154
- // logger.debug(
155
- // `No active call cid to set muted in calling exp: ${activeCallCid} isCallRegistered: ${isCallRegistered}`,
156
- // );
157
- // return;
158
- // }
159
-
160
- // callingx.setMutedCall(activeCallCid, isMute);
161
- // }, [activeCallCid, isMute]);
162
-
163
- // useEffect(() => {
164
- // const callingx = getCallingxLibIfAvailable();
165
- // if (!callingx?.isSetup || !activeCallCid) {
166
- // return;
167
- // }
168
-
169
- // const isCallRegistered = callingx.isCallRegistered(activeCallCid);
170
- // if (!isCallRegistered) {
171
- // logger.debug(
172
- // `No active call cid to set muted in calling exp: ${activeCallCid} isCallRegistered: ${isCallRegistered}`,
173
- // );
174
- // return;
175
- // }
176
-
177
- // //listen to mic toggle events from CallKit/Telecom and update stream call microphone state
178
- // const subscription = callingx.addEventListener(
179
- // 'didPerformSetMutedCallAction',
180
- // async (event: { callId: string; muted: boolean }) => {
181
- // const { callId, muted } = event;
182
-
183
- // if (callId === activeCallCid) {
184
- // const isCurrentlyMuted =
185
- // RxUtils.getCurrentValue(microphone.state.status$) === 'disabled';
186
- // if (isCurrentlyMuted === muted) {
187
- // logger.debug(
188
- // `Mic toggle is already in the desired state: ${muted} for call: ${activeCallCid}`,
189
- // );
190
- // //this check prevents mic toggle when state change was initiated from client and not from CallKit/Telecom
191
- // return;
192
- // }
193
-
194
- // try {
195
- // if (muted) {
196
- // await microphone.disable();
197
- // } else {
198
- // await microphone.enable();
199
- // }
200
- // } catch (error: unknown) {
201
- // logger.error(
202
- // `Error toggling mic in calling exp: ${activeCallCid}`,
203
- // error,
204
- // );
205
- // }
206
- // }
207
- // },
208
- // );
209
-
210
- // return () => {
211
- // subscription.remove();
212
- // };
213
- // }, [activeCallCid, microphone, isOutcomingCall, isIncomingCall]);
214
- };
215
- exports.useCallingExpWithCallingStateEffect = useCallingExpWithCallingStateEffect;
216
- //# sourceMappingURL=useCallingExpWithCallingStateEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_videoClient","require","_videoReactBindings","_react","_callingx","_callingx2","logger","videoLoggerSystem","getLogger","canActivateCall","prevState","currentState","isJoined","state","CallingState","JOINING","JOINED","canEndCall","RINGING","RECONNECTING","MIGRATING","OFFLINE","LEFT","RECONNECTING_FAILED","IDLE","useCallingExpWithCallingStateEffect","useCallCallingState","useParticipants","useCallMembers","useCallStateHooks","activeCall","useCall","callingState","callMembers","participants","useRef","undefined","activeCallCid","cid","isIncomingCall","ringing","isCreatedByMe","isOutcomingCall","currentUserId","isVideoCall","settings","video","enabled","callDisplayName","useMemo","getCallDisplayName","useEffect","callingx","getCallingxLibIfAvailable","isSetup","isCallRegistered","debug","endCallWithReason","catch","error","current","isOngoingCallsEnabled","answerIncomingCall","setCurrentCallActive","updateDisplay","isUnsubscribed","subscription","addEventListener","event","callId","_callingState","shouldSkip","finally","remove","exports"],"sourceRoot":"../../../../src","sources":["hooks/push/useCallingExpWithCallingStateEffect.ts"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,mBAAA,GAAAD,OAAA;AACA,IAAAE,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A;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;EAEA;EACA;EACA;EACA;AACF,CAAC;AAACmC,OAAA,CAAAjD,mCAAA,GAAAA,mCAAA","ignoreList":[]}
@@ -1,46 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.resolvePendingAudioSession = resolvePendingAudioSession;
7
- exports.waitForAudioSessionActivation = waitForAudioSessionActivation;
8
- /**
9
- * Module to manage pending promise for audio session activation.
10
- * Used to wait for iOS CallKit's didActivateAudioSession event after starting a call.
11
- */
12
-
13
- let pendingResolve = null;
14
- let pendingTimeout = null;
15
- const AUDIO_SESSION_TIMEOUT_MS = 5000;
16
-
17
- /**
18
- * Creates a promise that resolves when the audio session is activated,
19
- * or after a timeout to prevent hanging indefinitely.
20
- * @returns Promise that resolves when audio session is activated or timeout occurs
21
- */
22
- function waitForAudioSessionActivation() {
23
- return new Promise(resolve => {
24
- pendingResolve = resolve;
25
- pendingTimeout = setTimeout(() => {
26
- // Resolve on timeout to prevent hanging
27
- resolvePendingAudioSession();
28
- }, AUDIO_SESSION_TIMEOUT_MS);
29
- });
30
- }
31
-
32
- /**
33
- * Resolves the pending audio session activation promise.
34
- * Called when the didActivateAudioSession event fires or on timeout.
35
- */
36
- function resolvePendingAudioSession() {
37
- if (pendingTimeout) {
38
- clearTimeout(pendingTimeout);
39
- pendingTimeout = null;
40
- }
41
- if (pendingResolve) {
42
- pendingResolve();
43
- pendingResolve = null;
44
- }
45
- }
46
- //# sourceMappingURL=audioSessionPromise.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["pendingResolve","pendingTimeout","AUDIO_SESSION_TIMEOUT_MS","waitForAudioSessionActivation","Promise","resolve","setTimeout","resolvePendingAudioSession","clearTimeout"],"sourceRoot":"../../../../src","sources":["utils/internal/audioSessionPromise.ts"],"mappings":";;;;;;;AAAA;AACA;AACA;AACA;;AAEA,IAAIA,cAAmC,GAAG,IAAI;AAC9C,IAAIC,cAAoD,GAAG,IAAI;AAE/D,MAAMC,wBAAwB,GAAG,IAAI;;AAErC;AACA;AACA;AACA;AACA;AACO,SAASC,6BAA6BA,CAAA,EAAkB;EAC7D,OAAO,IAAIC,OAAO,CAAEC,OAAO,IAAK;IAC9BL,cAAc,GAAGK,OAAO;IACxBJ,cAAc,GAAGK,UAAU,CAAC,MAAM;MAChC;MACAC,0BAA0B,CAAC,CAAC;IAC9B,CAAC,EAAEL,wBAAwB,CAAC;EAC9B,CAAC,CAAC;AACJ;;AAEA;AACA;AACA;AACA;AACO,SAASK,0BAA0BA,CAAA,EAAS;EACjD,IAAIN,cAAc,EAAE;IAClBO,YAAY,CAACP,cAAc,CAAC;IAC5BA,cAAc,GAAG,IAAI;EACvB;EACA,IAAID,cAAc,EAAE;IAClBA,cAAc,CAAC,CAAC;IAChBA,cAAc,GAAG,IAAI;EACvB;AACF","ignoreList":[]}
@@ -1,84 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.endCallingxCall = endCallingxCall;
7
- exports.getCallDisplayName = getCallDisplayName;
8
- exports.startCallingxCall = startCallingxCall;
9
- var _reactNative = require("react-native");
10
- var _callingx = require("../push/libs/callingx");
11
- var _videoClient = require("@stream-io/video-client");
12
- var _audioSessionPromise = require("./audioSessionPromise");
13
- /***
14
- * Internal utils for callingx library usage from video-client.
15
- * See @./registerSDKGlobals.ts for more usage details.
16
- */
17
-
18
- const CallingxModule = (0, _callingx.getCallingxLibIfAvailable)();
19
-
20
- /**
21
- * Gets the call display name. To be used for display in native call screen.
22
- */
23
- function getCallDisplayName(callMembers, participants, currentUserId) {
24
- if (!callMembers || !participants || !currentUserId) {
25
- return 'Call';
26
- }
27
- let names = [];
28
- if (callMembers.length > 0) {
29
- // for ringing calls, members array contains all call members from the very early state and participants array is empty in the beginning
30
- names = callMembers.filter(member => member.user.id !== currentUserId).map(member => member.user.name).filter(name => name !== undefined);
31
- } else if (participants.length > 0) {
32
- // for non-ringing calls, members array is empty and we rely on participants array there
33
- names = participants.filter(participant => participant.userId !== currentUserId).map(participant => participant.name).filter(Boolean);
34
- }
35
-
36
- // if no names are found, we use the name of the current user
37
- if (names.length === 0) {
38
- names = [participants.find(participant => participant.userId === currentUserId)?.name ?? 'Call'];
39
- }
40
- return names.sort().join(', ');
41
- }
42
-
43
- /**
44
- * Starts the call in the callingx library.
45
- * Must be called for all outgoing calls
46
- * and optionally for non-ringing calls when ongoing calls are enabled.
47
- */
48
- async function startCallingxCall(call) {
49
- if (!CallingxModule || CallingxModule.isCallRegistered(call.cid)) {
50
- return;
51
- }
52
- const isOutcomingCall = call.ringing && call.isCreatedByMe;
53
- if (isOutcomingCall || !call.ringing && CallingxModule.isOngoingCallsEnabled) {
54
- const callDisplayName = getCallDisplayName(call.state.members, call.state.participants, call.currentUserId);
55
- try {
56
- await CallingxModule.startCall(call.cid,
57
- // unique id for call
58
- call.id,
59
- // phone number for display in dialer (we use call id as phone number)
60
- callDisplayName,
61
- // display name for display in call screen
62
- call.state.settings?.video?.enabled ?? false // is video call?
63
- );
64
-
65
- // Wait for audio session activation on iOS only
66
- if (_reactNative.Platform.OS === 'ios') {
67
- await (0, _audioSessionPromise.waitForAudioSessionActivation)();
68
- }
69
- } catch (error) {
70
- _videoClient.videoLoggerSystem.getLogger('startCallingxCall').error(`Error starting call in callingx: ${call.cid}`, error);
71
- }
72
- }
73
- }
74
- async function endCallingxCall(call) {
75
- if (!CallingxModule || !CallingxModule.isCallRegistered(call.cid)) {
76
- return;
77
- }
78
- try {
79
- await CallingxModule.endCallWithReason(call.cid, 'local');
80
- } catch (error) {
81
- _videoClient.videoLoggerSystem.getLogger('endCallingxCall').error(`Error ending call in callingx: ${call.cid}`, error);
82
- }
83
- }
84
- //# sourceMappingURL=callingx.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_reactNative","require","_callingx","_videoClient","_audioSessionPromise","CallingxModule","getCallingxLibIfAvailable","getCallDisplayName","callMembers","participants","currentUserId","names","length","filter","member","user","id","map","name","undefined","participant","userId","Boolean","find","sort","join","startCallingxCall","call","isCallRegistered","cid","isOutcomingCall","ringing","isCreatedByMe","isOngoingCallsEnabled","callDisplayName","state","members","startCall","settings","video","enabled","Platform","OS","waitForAudioSessionActivation","error","videoLoggerSystem","getLogger","endCallingxCall","endCallWithReason"],"sourceRoot":"../../../../src","sources":["utils/internal/callingx.ts"],"mappings":";;;;;;;;AAIA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,SAAA,GAAAD,OAAA;AACA,IAAAE,YAAA,GAAAF,OAAA;AAMA,IAAAG,oBAAA,GAAAH,OAAA;AAZA;AACA;AACA;AACA;;AAWA,MAAMI,cAAc,GAAG,IAAAC,mCAAyB,EAAC,CAAC;;AAElD;AACA;AACA;AACO,SAASC,kBAAkBA,CAChCC,WAAyC,EACzCC,YAAkD,EAClDC,aAAiC,EACjC;EACA,IAAI,CAACF,WAAW,IAAI,CAACC,YAAY,IAAI,CAACC,aAAa,EAAE;IACnD,OAAO,MAAM;EACf;EAEA,IAAIC,KAAe,GAAG,EAAE;EAExB,IAAIH,WAAW,CAACI,MAAM,GAAG,CAAC,EAAE;IAC1B;IACAD,KAAK,GAAGH,WAAW,CAChBK,MAAM,CAAEC,MAAM,IAAKA,MAAM,CAACC,IAAI,CAACC,EAAE,KAAKN,aAAa,CAAC,CACpDO,GAAG,CAAEH,MAAM,IAAKA,MAAM,CAACC,IAAI,CAACG,IAAI,CAAC,CACjCL,MAAM,CAAEK,IAAI,IAAqBA,IAAI,KAAKC,SAAS,CAAC;EACzD,CAAC,MAAM,IAAIV,YAAY,CAACG,MAAM,GAAG,CAAC,EAAE;IAClC;IACAD,KAAK,GAAGF,YAAY,CACjBI,MAAM,CAAEO,WAAW,IAAKA,WAAW,CAACC,MAAM,KAAKX,aAAa,CAAC,CAC7DO,GAAG,CAAEG,WAAW,IAAKA,WAAW,CAACF,IAAI,CAAC,CACtCL,MA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AAEe,KAAK,CAAC;IACjE;EACF;AACF;AAEO,eAAeG,eAAeA,CAACpB,IAAU,EAAE;EAChD,IAAI,CAACtB,cAAc,IAAI,CAACA,cAAc,CAACuB,gBAAgB,CAACD,IAAI,CAACE,GAAG,CAAC,EAAE;IACjE;EACF;EAEA,IAAI;IACF,MAAMxB,cAAc,CAAC2C,iBAAiB,CAACrB,IAAI,CAACE,GAAG,EAAE,OAAO,CAAC;EAC3D,CAAC,CAAC,OAAOe,KAAK,EAAE;IACdC,8BAAiB,CACdC,SAAS,CAAC,iBAAiB,CAAC,CAC5BF,KAAK,CAAC,kCAAkCjB,IAAI,CAACE,GAAG,EAAE,EAAEe,KAAK,CAAC;EAC/D;AACF","ignoreList":[]}
@@ -1,48 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.keepCallAliveCallRef = exports.KEEP_CALL_ALIVE_HEADLESS_TASK_NAME = void 0;
7
- var _reactNative = require("react-native");
8
- var _videoClient = require("@stream-io/video-client");
9
- var _StreamVideoRN = require("./StreamVideoRN");
10
- const KEEP_CALL_ALIVE_HEADLESS_TASK_NAME = exports.KEEP_CALL_ALIVE_HEADLESS_TASK_NAME = 'StreamVideoKeepCallAlive';
11
-
12
- /**
13
- * The keep-alive headless task needs access to the active `Call` instance.
14
- * The keep-alive hook will set this reference before starting the native service.
15
- */
16
- const keepCallAliveCallRef = exports.keepCallAliveCallRef = {
17
- current: undefined
18
- };
19
- function registerKeepCallAliveHeadlessTaskOnce() {
20
- if (_reactNative.Platform.OS !== 'android') return;
21
- _reactNative.AppRegistry.registerHeadlessTask(KEEP_CALL_ALIVE_HEADLESS_TASK_NAME, () => async data => {
22
- const logger = _videoClient.videoLoggerSystem.getLogger('KEEP_CALL_ALIVE_HEADLESS_TASK');
23
- const callCid = data?.callCid;
24
- const call = keepCallAliveCallRef.current;
25
- if (!call) {
26
- logger.warn('No active call instance available for keep-alive task; skipping.', {
27
- callCid
28
- });
29
- return;
30
- }
31
- if (callCid && call.cid && call.cid !== callCid) {
32
- logger.warn('Keep-alive task callCid does not match active call; skipping.', {
33
- callCid,
34
- activeCallCid: call.cid
35
- });
36
- return;
37
- }
38
- const config = _StreamVideoRN.StreamVideoRN.getConfig();
39
- const taskToRun = config.foregroundService.android.taskToRun;
40
- try {
41
- await taskToRun(call);
42
- } catch (e) {
43
- logger.error('Keep-alive headless task failed', e);
44
- }
45
- });
46
- }
47
- registerKeepCallAliveHeadlessTaskOnce();
48
- //# sourceMappingURL=keepCallAliveHeadlessTask.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_reactNative","require","_videoClient","_StreamVideoRN","KEEP_CALL_ALIVE_HEADLESS_TASK_NAME","exports","keepCallAliveCallRef","current","undefined","registerKeepCallAliveHeadlessTaskOnce","Platform","OS","AppRegistry","registerHeadlessTask","data","logger","videoLoggerSystem","getLogger","callCid","call","warn","cid","activeCallCid","config","StreamVideoRN","getConfig","taskToRun","foregroundService","android","e","error"],"sourceRoot":"../../../src","sources":["utils/keepCallAliveHeadlessTask.ts"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAEA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,cAAA,GAAAF,OAAA;AAEO,MAAMG,kCAAkC,GAAAC,OAAA,CAAAD,kCAAA,GAAG,0BAA0B;;AAE5E;AACA;AACA;AACA;AACO,MAAME,oBAAmD,GAAAD,OAAA,CAAAC,oBAAA,GAAG;EACjEC,OAAO,EAAEC;AACX,CAAC;AAED,SAASC,qCAAqCA,CAAA,EAAG;EAC/C,IAAIC,qBAAQ,CAACC,EAAE,KAAK,SAAS,EAAE;EAE/BC,wBAAW,CAACC,oBAAoB,CAC9BT,kCAAkC,EAClC,MAAM,MAAOU,IAAsC,IAAK;IACtD,MAAMC,MAAM,GAAGC,8BAAiB,CAACC,SAAS,CACxC,+BACF,CAAC;IACD,MAAMC,OAAO,GAAGJ,IAAI,EAAEI,OAAO;IAE7B,MAAMC,IAAI,GAAGb,oBAAoB,CAACC,OAAO;IACzC,IAAI,CAACY,IAAI,EAAE;MACTJ,MAAM,CAACK,IAAI,CACT,kEAAkE,EAClE;QAAEF;MAAQ,CACZ,CAAC;MACD;IACF;IACA,IAAIA,OAAO,IAAIC,IAAI,CAACE,GAAG,IAAIF,IAAI,CAACE,GAAG,KAAKH,OAAO,EAAE;MAC/CH,MAAM,CAACK,IAAI,CACT,+DAA+D,EAC/D;QAAEF,OAAO;QAAEI,aAAa,EAAEH,IAAI,CAACE;MAAI,CACrC,CAAC;MACD;IACF;IAEA,MAAME,MAAM,GAAGC,4BAAa,CAACC,SAAS,CAAC,CAAC;IACxC,MAAMC,SAAS,GAAGH,MAAM,CAACI,iBAAiB,CAACC,OAAO,CAACF,SAAS;IAC5D,IAAI;MACF,MAAMA,SAAS,CAACP,IAAI,CAAC;IACvB,CAAC,CAAC,OAAOU,CAAC,EAAE;MACVd,MAAM,CAACe,KAAK,CAAC,iCAAiC,EAAED,CAAC,CAAC;IACpD;EACF,CACF,CAAC;AACH;AAEApB,qCAAqC,CAAC,CAAC","ignoreList":[]}
@@ -1,75 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.extractCallingExpOptions = extractCallingExpOptions;
7
- exports.getCallingxLib = getCallingxLib;
8
- exports.getCallingxLibIfAvailable = getCallingxLibIfAvailable;
9
- let callingx;
10
- try {
11
- callingx = require('@stream-io/react-native-callingx').CallingxModule;
12
- } catch {}
13
- function getCallingxLib() {
14
- if (!callingx) {
15
- throw Error('react-native-callingx library is not installed.');
16
- }
17
- return callingx;
18
- }
19
- function getCallingxLibIfAvailable() {
20
- return callingx ?? undefined;
21
- }
22
- function extractCallingExpOptions(config) {
23
- const {
24
- push: pushConfig,
25
- foregroundService: foregroundServiceConfig
26
- } = config;
27
- const callingExpOptions = {};
28
- if (pushConfig?.ios) {
29
- const iosOptions = {};
30
- if (pushConfig.ios.supportsVideo !== undefined) {
31
- iosOptions.supportsVideo = pushConfig.ios.supportsVideo;
32
- }
33
- if (pushConfig.ios.sound !== undefined) {
34
- iosOptions.sound = pushConfig.ios.sound;
35
- }
36
- if (pushConfig.ios.imageName !== undefined) {
37
- iosOptions.imageName = pushConfig.ios.imageName;
38
- }
39
- if (pushConfig.ios.callsHistory !== undefined) {
40
- iosOptions.callsHistory = pushConfig.ios.callsHistory;
41
- }
42
- if (pushConfig.ios.displayCallTimeout !== undefined) {
43
- iosOptions.displayCallTimeout = pushConfig.ios.displayCallTimeout;
44
- }
45
- if (Object.keys(iosOptions).length > 0) {
46
- callingExpOptions.ios = iosOptions;
47
- }
48
- }
49
- const androidOptions = {};
50
- if (pushConfig?.android) {
51
- if (pushConfig.android.incomingChannel) {
52
- androidOptions.incomingChannel = pushConfig.android.incomingChannel;
53
- }
54
- if (pushConfig.android.titleTransformer) {
55
- androidOptions.titleTransformer = pushConfig.android.titleTransformer;
56
- }
57
- if (pushConfig.android.subtitleTransformer) {
58
- androidOptions.subtitleTransformer = pushConfig.android.subtitleTransformer;
59
- }
60
- }
61
- if (foregroundServiceConfig.android.channel) {
62
- androidOptions.ongoingChannel = foregroundServiceConfig.android.channel;
63
- }
64
- if (Object.keys(androidOptions).length > 0) {
65
- callingExpOptions.android = androidOptions;
66
- }
67
- if (pushConfig?.shouldRejectCallWhenBusy !== undefined) {
68
- callingExpOptions.shouldRejectCallWhenBusy = pushConfig.shouldRejectCallWhenBusy;
69
- }
70
- if (pushConfig?.enableOngoingCalls !== undefined) {
71
- callingExpOptions.enableOngoingCalls = pushConfig?.enableOngoingCalls;
72
- }
73
- return callingExpOptions;
74
- }
75
- //# sourceMappingURL=callingx.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["callingx","require","CallingxModule","getCallingxLib","Error","getCallingxLibIfAvailable","undefined","extractCallingExpOptions","config","push","pushConfig","foregroundService","foregroundServiceConfig","callingExpOptions","ios","iosOptions","supportsVideo","sound","imageName","callsHistory","displayCallTimeout","Object","keys","length","androidOptions","android","incomingChannel","titleTransformer","subtitleTransformer","channel","ongoingChannel","shouldRejectCallWhenBusy","enableOngoingCalls"],"sourceRoot":"../../../../../src","sources":["utils/push/libs/callingx.ts"],"mappings":";;;;;;;;AAUA,IAAIA,QAAoC;AAExC,IAAI;EACFA,QAAQ,GAAGC,OAAO,CAAC,kCAAkC,CAAC,CAACC,cAAc;AACvE,CAAC,CAAC,MAAM,CAAC;AAEF,SAASC,cAAcA,CAAA,EAAG;EAC/B,IAAI,CAACH,QAAQ,EAAE;IACb,MAAMI,KAAK,CAAC,iDAAiD,CAAC;EAChE;EACA,OAAOJ,QAAQ;AACjB;AAEO,SAASK,yBAAyBA,CAAA,EAAG;EAC1C,OAAOL,QAAQ,IAAIM,SAAS;AAC9B;AAEO,SAASC,wBAAwBA,CACtCC,MAAyB,EACN;EACnB,MAAM;IAAEC,IAAI,EAAEC,UAAU;IAAEC,iBAAiB,EAAEC;EAAwB,CAAC,GACpEJ,MAAM;EACR,MAAMK,iBAAoC,GAAG,CAAC,CAAC;EAE/C,IAAIH,UAAU,EAAEI,GAAG,EAAE;IACnB,MAAMC,UAAoC,GAAG,CAAC,CAAC;IAC/C,IAAIL,UAAU,CAACI,GAAG,CAACE,aAAa,KAAKV,SAAS,EAAE;MAC9CS,UAAU,CAACC,aAAa,GAAGN,UAAU,CAACI,GAAG,CAACE,aAAa;IACzD;IACA,IAAIN,UAAU,CAACI,GAAG,CAACG,KAAK,KAAKX,SAAS,EAAE;MACtCS,UAAU,CAACE,KAAK,GAAGP,UAAU,CAACI,GAAG,CAACG,KAAK;IACzC;IACA,IAAIP,UAAU,CAACI,GAAG,CAACI,SAAS,KAAKZ,SAAS,EAAE;MAC1CS,UAAU,CAACG,SAAS,GAAGR,UAAU,CAACI,GAAG,CAACI,SAAS;IACjD;IACA,IAAIR,UAAU,CAACI,GAAG,CAACK,YAAY,KAAKb,SAAS,EAAE;MAC7CS,UAAU,CAACI,YAAY,GAAGT,UAAU,CA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