expo-callkit-telecom 0.2.0 → 0.2.2
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/README.md +11 -0
- package/android/src/main/java/expo/modules/callkittelecom/ExpoCallKitTelecomModule.kt +254 -282
- package/android/src/main/java/expo/modules/callkittelecom/IncomingCallActivity.kt +27 -34
- package/android/src/main/java/expo/modules/callkittelecom/events/CallEventEmitter.kt +21 -32
- package/android/src/main/java/expo/modules/callkittelecom/managers/CallAudioManager.kt +53 -74
- package/android/src/main/java/expo/modules/callkittelecom/managers/CallManager.kt +95 -156
- package/android/src/main/java/expo/modules/callkittelecom/managers/CallNotificationManager.kt +71 -84
- package/android/src/main/java/expo/modules/callkittelecom/managers/CaptureSessionManager.kt +1 -3
- package/android/src/main/java/expo/modules/callkittelecom/managers/DialtonePlayer.kt +6 -4
- package/android/src/main/java/expo/modules/callkittelecom/managers/FulfillRequestManager.kt +21 -21
- package/android/src/main/java/expo/modules/callkittelecom/managers/VoIPPushManager.kt +3 -5
- package/android/src/main/java/expo/modules/callkittelecom/models/CallModels.kt +28 -36
- package/android/src/main/java/expo/modules/callkittelecom/services/CallNotificationReceiver.kt +7 -8
- package/android/src/main/java/expo/modules/callkittelecom/services/ExpoCallKitTelecomMessagingService.kt +9 -16
- package/android/src/main/java/expo/modules/callkittelecom/store/CallStore.kt +32 -68
- package/android/src/main/java/expo/modules/callkittelecom/utils/CallKitTelecomLog.kt +6 -17
- package/android/src/main/java/expo/modules/callkittelecom/utils/PermissionUtils.kt +7 -7
- package/ios/Managers/CaptureSessionManager.swift +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -4,6 +4,13 @@
|
|
|
4
4
|
|
|
5
5
|
The module is opinionated about *system integration* and unopinionated about *media*. You wire your media library to the events it emits.
|
|
6
6
|
|
|
7
|
+
<p>
|
|
8
|
+
<a href="https://www.npmjs.com/package/expo-callkit-telecom"><img alt="npm version" src="https://img.shields.io/npm/v/expo-callkit-telecom.svg"></a>
|
|
9
|
+
<a href="https://www.npmjs.com/package/expo-callkit-telecom"><img alt="npm downloads" src="https://img.shields.io/npm/dm/expo-callkit-telecom.svg"></a>
|
|
10
|
+
<img alt="platform" src="https://img.shields.io/badge/platform-iOS%20%7C%20Android-blue">
|
|
11
|
+
<img alt="license" src="https://img.shields.io/npm/l/expo-callkit-telecom">
|
|
12
|
+
</p>
|
|
13
|
+
|
|
7
14
|
## ✨ Features
|
|
8
15
|
|
|
9
16
|
- 📱 **Native calling UI** — CallKit on iOS, Telecom incoming-call notification + full-screen intent on Android
|
|
@@ -183,6 +190,10 @@ See `src/Calls.ts` for full JSDoc. Main areas:
|
|
|
183
190
|
- 🤖 **Android** — requires `MANAGE_OWN_CALLS` permission, min SDK 26. Uses `androidx.core:core-telecom`. Incoming calls come via FCM data messages — the config plugin registers `ExpoCallKitTelecomMessagingService` automatically.
|
|
184
191
|
- 🎟️ VoIP push token type is reported as `"APNS_VOIP"` on iOS and `"FCM"` on Android — send both to your backend so it knows which transport to use.
|
|
185
192
|
|
|
193
|
+
## ⏰ Keeping connections alive in the background
|
|
194
|
+
|
|
195
|
+
This module hands the OS a CallKit/Telecom call, which keeps the *process* alive during a call — but JS timers (`setInterval`, `setTimeout`) and JS-side network heartbeats are still subject to background throttling once the screen locks. If your media stack needs an app-level heartbeat (e.g. a WebSocket signalling channel) to survive the background, pair this module with [`react-native-nitro-keepalive-timer`](https://www.npmjs.com/package/react-native-nitro-keepalive-timer) to get native timers that fire reliably while a call is active.
|
|
196
|
+
|
|
186
197
|
## 🆚 Comparison with `react-native-callkeep`
|
|
187
198
|
|
|
188
199
|
[`react-native-callkeep`](https://github.com/react-native-webrtc/react-native-callkeep) is the long-standing option in this space. Here are some differences with this package:
|