From 8f5976a77ec070457405dc8273c5a179a7efb1cf Mon Sep 17 00:00:00 2001 From: Santhosh Vaiyapuri Date: Mon, 2 Oct 2023 15:02:38 +0200 Subject: [PATCH] feat: ios vanilla non ringing push --- .../03-ringing-setup/01-react-native.mdx | 25 ++- .../01-react-native.mdx | 127 +++------------ packages/react-native-sdk/package.json | 5 + .../react-native-sdk/src/utils/push/ios.ts | 91 ++++++----- .../react-native-sdk/src/utils/push/libs.ts | 19 ++- sample-apps/react-native/dogfood/ios/Podfile | 17 +-- .../react-native/dogfood/ios/Podfile.lock | 144 +++--------------- .../project.pbxproj | 130 +++++++--------- .../AppDelegate.h | 3 +- .../AppDelegate.mm | 39 ++++- .../Info.plist | 1 + sample-apps/react-native/dogfood/package.json | 3 +- .../dogfood/react-native.config.js | 14 ++ .../dogfood/reactNativePermissionsIOS.json | 4 - .../src/components/NavigationHeader.tsx | 2 +- .../dogfood/src/hooks/useSyncPermissions.ts | 8 +- .../src/screens/Meeting/MeetingScreen.tsx | 11 +- .../dogfood/src/utils/setPushConfig.ts | 12 ++ yarn.lock | 30 +++- 19 files changed, 308 insertions(+), 377 deletions(-) create mode 100644 sample-apps/react-native/dogfood/react-native.config.js delete mode 100644 sample-apps/react-native/dogfood/reactNativePermissionsIOS.json diff --git a/packages/react-native-sdk/docusaurus/docs/reactnative/06-advanced/04-push-notifications/03-ringing-setup/01-react-native.mdx b/packages/react-native-sdk/docusaurus/docs/reactnative/06-advanced/04-push-notifications/03-ringing-setup/01-react-native.mdx index bc1b2a1d30..b34d74fda3 100644 --- a/packages/react-native-sdk/docusaurus/docs/reactnative/06-advanced/04-push-notifications/03-ringing-setup/01-react-native.mdx +++ b/packages/react-native-sdk/docusaurus/docs/reactnative/06-advanced/04-push-notifications/03-ringing-setup/01-react-native.mdx @@ -70,15 +70,28 @@ The **google-services.json** file contains unique and non-secret identifiers of ## iOS-specific setup -### Configure Firebase +### Disable Firebase installation -Follow [this guide at react-native-firebase documentation](https://rnfirebase.io/#3-react-native-cli---ios-setup) to generate credentials for your iOS app and configure Firebase. +We don't use Firebase cloud messaging for iOS in the SDK. Unless Firebase is used for other purposes in your app, you can safely remove it from being installed by iOS and avoid the auto-linking. To do that create a file named `react-native.config.js` in the root of your project and add the following contents: -:::note - -We don't use Firebase cloud messaging for iOS in the SDK. But the `react-native-firebase` library will throw an error if iOS credentials are not added. +```js title="react-native.config.js" +module.exports = { + dependencies: { + '@react-native-firebase/app': { + platforms: { + ios: null, + }, + }, + '@react-native-firebase/messaging': { + platforms: { + ios: null, + }, + }, + }, +}; +``` -::: +Once this is done, `pod install` must be run again to remove the installed pods. ### Link required libraries for react native callkeep library diff --git a/packages/react-native-sdk/docusaurus/docs/reactnative/06-advanced/04-push-notifications/04-other-than-ringing-setup/01-react-native.mdx b/packages/react-native-sdk/docusaurus/docs/reactnative/06-advanced/04-push-notifications/04-other-than-ringing-setup/01-react-native.mdx index 5713e059c2..7b64a1fb83 100644 --- a/packages/react-native-sdk/docusaurus/docs/reactnative/06-advanced/04-push-notifications/04-other-than-ringing-setup/01-react-native.mdx +++ b/packages/react-native-sdk/docusaurus/docs/reactnative/06-advanced/04-push-notifications/04-other-than-ringing-setup/01-react-native.mdx @@ -68,30 +68,28 @@ The **google-services.json** file contains unique and non-secret identifiers of ## iOS-specific setup -### Configure Firebase +### Disable Firebase installation -Follow [this guide at react-native-firebase documentation](https://rnfirebase.io/#3-react-native-cli---ios-setup) to generate credentials for your iOS app and configure Firebase. +We don't use Firebase cloud messaging for iOS in the SDK. Unless Firebase is used for other purposes in your app, you can safely remove it from being installed by iOS and avoid the auto-linking. To do that create a file named `react-native.config.js` in the root of your project and add the following contents: -:::note - -We don't use Firebase cloud messaging for iOS in the SDK. But the `react-native-firebase` library will throw an error if iOS credentials are not added. - -::: - -### Link required libraries for react native callkeep library - -1. In Xcode: Click on `Build Phases` tab, then open `Link Binary With Libraries`. -2. Add `CallKit.framework` -3. Add `Intents.framework` (and mark it Optional). - -![Example of how to use link libraries required for callkeep library](../../../assets/06-advanced/04-push-notifications/ios-callkit-libraries-link.png) - -### Add header search path for react native callkeep library - -1. In Xcode: Click on `Build Settings` tab, then search for `Header Search Paths`. -2. Add `$(SRCROOT)/../node_modules/react-native-callkeep/ios/RNCallKeep`. +```js title="react-native.config.js" +module.exports = { + dependencies: { + '@react-native-firebase/app': { + platforms: { + ios: null, + }, + }, + '@react-native-firebase/messaging': { + platforms: { + ios: null, + }, + }, + }, +}; +``` -![Example of how to add header search paths that are required for callkeep library](../../../assets/06-advanced/04-push-notifications/ios-search-paths.png) +Once this is done, `pod install` must be run again to remove the installed pods. ### Add background modes @@ -107,93 +105,6 @@ In Xcode: Open `Info.plist` file and add the following in `UIBackgroundModes`. B ### Enable push notifications To receive push notifications, enable the Push Notifications capability in the Xcode `Project` > `Signing & Capabilities` pane. - -### Update AppDelegate - -Update `AppDelegate.m` or `AppDelegate.mm` in Xcode with the following parts for iOS support. - -#### Add headers - -At the top of the file, right after '#import "AppDelegate.h"', add the following headers to import and invoke the methods for the required libraries. - -```c -// highlight-start -#import -#import "RNCallKeep.h" -#import -#import "RNVoipPushNotificationManager.h" -// highlight-end -``` - -#### Initialize on app launch - -We need to configure the Firebase library, set up the callkeep library and register VoIP at the app launch. To do this, add the following methods to your existing `didFinishLaunchingWithOptions` method, - -```c - -- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions -{ - // highlight-next-line - [FIRApp configure]; - - // highlight-start - NSString *localizedAppName = [[[NSBundle mainBundle] localizedInfoDictionary] objectForKey:@"CFBundleDisplayName"]; - NSString *appName = [[[NSBundle mainBundle] infoDictionary]objectForKey :@"CFBundleDisplayName"]; - [RNCallKeep setup:@{ - @"appName": localizedAppName != nil ? localizedAppName : appName, - @"supportsVideo": @YES, - // pass @YES here if you want the call to be shown in calls history in the built-in dialer app - @"includesCallsInRecents": @NO, - }]; - // highlight-end - - // highlight-next-line - [RNVoipPushNotificationManager voipRegistration]; - - // the rest -} -``` - -#### Add PushKit methods - -Add the following method to process the VoIP token from iOS and send it to the `react-native-voip-push-notification` library. - -```c -// handle updated push credentials -- (void)pushRegistry:(PKPushRegistry *)registry didUpdatePushCredentials:(PKPushCredentials *)credentials forType:(PKPushType)type { - [RNVoipPushNotificationManager didUpdatePushCredentials:credentials forType:(NSString *)type]; -} -``` - -The final method to add is the one that gets invoked when there is a VoIP push notification from Stream. When there is a push notification and if the app is in the background, we want to display an incoming call notification. Add the following method to achieve this, - -```c -// handle incoming pushes -- (void)pushRegistry:(PKPushRegistry *)registry didReceiveIncomingPushWithPayload:(PKPushPayload *)payload forType:(PKPushType)type withCompletionHandler:(void (^)(void))completion { - // send event to JS - [RNVoipPushNotificationManager didReceiveIncomingPushWithPayload:payload forType:(NSString *)type]; - - // process the payload - NSDictionary *stream = payload.dictionaryPayload[@"stream"]; - NSString *uuid = [[NSUUID UUID] UUIDString]; - NSString *createdCallerName = stream[@"created_by_display_name"]; - - // display the incoming call notification - [RNCallKeep reportNewIncomingCall: uuid - handle: createdCallerName - handleType: @"generic" - hasVideo: YES - localizedCallerName: createdCallerName - supportsHolding: YES - supportsDTMF: YES - supportsGrouping: YES - supportsUngrouping: YES - fromPushKit: YES - payload: stream - withCompletionHandler: completion]; -} -``` - ## Setup the push config for the SDK The SDK automatically processes the incoming push notifications once the setup above is done if the push config has been set using `StreamVideoRN.setPushConfig`. To do this follow the steps below, diff --git a/packages/react-native-sdk/package.json b/packages/react-native-sdk/package.json index 1aa5a746dd..ad2796660a 100644 --- a/packages/react-native-sdk/package.json +++ b/packages/react-native-sdk/package.json @@ -56,6 +56,7 @@ "peerDependencies": { "@notifee/react-native": ">=7.8.0", "@react-native-community/netinfo": ">=9.0.0", + "@react-native-community/push-notification-ios": ">=1.11.0", "@react-native-firebase/app": ">=17.5.0", "@react-native-firebase/messaging": ">=17.5.0", "@stream-io/react-native-webrtc": ">=104.0.1", @@ -71,6 +72,9 @@ "react-native-voip-push-notification": ">=3.3.1" }, "peerDependenciesMeta": { + "@react-native-community/push-notification-ios": { + "optional": true + }, "@react-native-firebase/app": { "optional": true }, @@ -102,6 +106,7 @@ "@notifee/react-native": "7.8.0", "@react-native-community/eslint-config": "^3.2.0", "@react-native-community/netinfo": "9.3.9", + "@react-native-community/push-notification-ios": "1.11.0", "@react-native-firebase/app": "17.5.0", "@react-native-firebase/messaging": "17.5.0", "@stream-io/react-native-webrtc": "104.0.1", diff --git a/packages/react-native-sdk/src/utils/push/ios.ts b/packages/react-native-sdk/src/utils/push/ios.ts index 364421d71a..ae076c3ad9 100644 --- a/packages/react-native-sdk/src/utils/push/ios.ts +++ b/packages/react-native-sdk/src/utils/push/ios.ts @@ -11,13 +11,35 @@ import { pushNonRingingCallData$, } from './rxSubjects'; import { processCallFromPushInBackground } from './utils'; -import { getExpoNotificationsLib } from './libs'; +import { getExpoNotificationsLib, getPushNotificationIosLib } from './libs'; import { StreamVideoClient } from '@stream-io/video-client'; import { setPushLogoutCallback } from '../internal/pushLogoutCallback'; import notifee, { EventType } from '@notifee/react-native'; type PushConfig = NonNullable; +type StreamPayload = + | { + call_cid: string; + type: 'call.ring' | NonRingingPushEvent; + sender: string; + } + | undefined; + +function processNonRingingNotificationStreamPayload( + streamPayload: StreamPayload, +) { + if ( + streamPayload?.sender === 'stream.video' && + streamPayload?.type !== 'call.ring' + ) { + const cid = streamPayload.call_cid; + const type = streamPayload.type; + pushNonRingingCallData$.next({ cid, type }); + return { cid, type }; + } +} + export const iosCallkeepAcceptCall = ( call_cid: string | undefined, callUUIDFromCallkeep: string, @@ -69,29 +91,21 @@ export const setupRemoteNotificationsHandleriOS = (pushConfig: PushConfig) => { if (Platform.OS !== 'ios') { return; } + notifee.onForegroundEvent(({ type, detail }) => { + if (type === EventType.PRESS) { + const streamPayload = detail.notification?.data?.stream as + | StreamPayload + | undefined; + const result = processNonRingingNotificationStreamPayload(streamPayload); + if (result) { + pushConfig.onTapNonRingingCallNotification?.(result.cid, result.type); + } + } + }); if (pushConfig.isExpo) { const Notifications = getExpoNotificationsLib(); - notifee.onForegroundEvent(({ type, detail }) => { - if (type === EventType.PRESS) { - const streamPayload = detail.notification?.data?.stream as - | { call_cid: string; type: string; sender: string } - | undefined; - if (streamPayload) { - if ( - streamPayload.sender === 'stream.video' && - streamPayload.type !== 'call.ring' - ) { - const cid = streamPayload.call_cid; - const _type = streamPayload.type as NonRingingPushEvent; - pushNonRingingCallData$.next({ cid, type: _type }); - pushConfig.onTapNonRingingCallNotification?.(cid, _type); - } - } - } - }); - - // foreground handler + // foreground handler (just to show the notifications on foreground) Notifications.setNotificationHandler({ handleNotification: async () => { return { @@ -133,19 +147,9 @@ export async function initIosNonVoipToken( expoNotificationsLib.addNotificationReceivedListener((event) => { // listen to foreground notifications if (event.request.trigger.type === 'push') { - const streamPayload = event.request.trigger.payload?.stream as - | { call_cid: string; type: string; sender: string } - | undefined; - if (streamPayload) { - if ( - streamPayload.sender === 'stream.video' && - streamPayload.type !== 'call.ring' - ) { - const cid = streamPayload.call_cid; - const type = streamPayload.type as NonRingingPushEvent; - pushNonRingingCallData$.next({ cid, type }); - } - } + const streamPayload = event.request.trigger.payload + ?.stream as StreamPayload; + processNonRingingNotificationStreamPayload(streamPayload); } }); setUnsubscribeListener(() => { @@ -153,6 +157,23 @@ export async function initIosNonVoipToken( subscriptionForReceive.remove(); }); } else { - // TODO: apn lib for ios + console.log('register ios notifications'); + const pushNotificationIosLib = getPushNotificationIosLib(); + pushNotificationIosLib.addEventListener('register', (token) => { + setDeviceToken(token); + console.log({ token }); + }); + pushNotificationIosLib.addEventListener('notification', (notification) => { + const data = notification.getData(); + console.log('normal ios notification', { data }); + const streamPayload = data?.stream as StreamPayload; + // listen to foreground notifications + processNonRingingNotificationStreamPayload(streamPayload); + }); + setUnsubscribeListener(() => { + console.log('unsubscribe ios notifications'); + pushNotificationIosLib.removeEventListener('register'); + pushNotificationIosLib.removeEventListener('notification'); + }); } } diff --git a/packages/react-native-sdk/src/utils/push/libs.ts b/packages/react-native-sdk/src/utils/push/libs.ts index 417d918893..b5e9499840 100644 --- a/packages/react-native-sdk/src/utils/push/libs.ts +++ b/packages/react-native-sdk/src/utils/push/libs.ts @@ -6,12 +6,15 @@ export type VoipPushNotificationType = typeof import('react-native-voip-push-notification').default; export type ExpoNotificationsLib = typeof import('expo-notifications'); export type ExpoTaskManagerLib = typeof import('expo-task-manager'); +export type PushNotificationIosLib = + typeof import('@react-native-community/push-notification-ios').default; let callkeep: RNCallKeepType | undefined; let messaging: FirebaseMessagingType | undefined; let voipPushNotification: VoipPushNotificationType | undefined; let expoNotificationsLib: ExpoNotificationsLib | undefined; let expoTaskManagerLib: ExpoTaskManagerLib | undefined; +let pushNotificationIosLib: PushNotificationIosLib | undefined; try { callkeep = require('react-native-callkeep').default; @@ -33,6 +36,11 @@ try { expoTaskManagerLib = require('expo-task-manager'); } catch (e) {} +try { + pushNotificationIosLib = + require('@react-native-community/push-notification-ios').default; +} catch (e) {} + export function getExpoNotificationsLib() { if (!expoNotificationsLib) { throw Error( @@ -51,6 +59,15 @@ export function getExpoTaskManagerLib() { return expoTaskManagerLib; } +export function getPushNotificationIosLib() { + if (!pushNotificationIosLib) { + throw Error( + '@react-native-community/push-notification-ios library is not installed. Please install it using "yarn add @react-native-community/push-notification-ios" or "npm i @react-native-community/push-notification-ios --save"', + ); + } + return pushNotificationIosLib; +} + export function getCallKeepLib() { if (!callkeep) { throw Error( @@ -72,7 +89,7 @@ export function getFirebaseMessagingLib() { export function getVoipPushNotificationLib() { if (!voipPushNotification) { throw Error( - "react-native-voip-push-notification library is not installed. Please install it using 'yarn add react-native-voip-push-notification' or 'npm install react-native-voip-push-notification'", + "react-native-voip-push-notification library is not installed. Please install it using 'yarn add react-native-voip-push-notification' or 'npm i react-native-voip-push-notification --save'", ); } return voipPushNotification; diff --git a/sample-apps/react-native/dogfood/ios/Podfile b/sample-apps/react-native/dogfood/ios/Podfile index 2c2e85e78c..37729cb822 100644 --- a/sample-apps/react-native/dogfood/ios/Podfile +++ b/sample-apps/react-native/dogfood/ios/Podfile @@ -1,10 +1,16 @@ require_relative '../node_modules/react-native/scripts/react_native_pods' require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules' -$RNFirebaseAsStaticFramework = true +require_relative '../node_modules/react-native-permissions/scripts/setup' platform :ios, min_ios_version_supported prepare_react_native_project! +setup_permissions([ + 'Camera', + 'Microphone', + 'Notifications' +]) + # If you are using a `react-native-flipper` your iOS build will fail when `NO_FLIPPER=1` is set. # because `react-native-flipper` depends on (FlipperKit,...) that will be excluded # @@ -24,15 +30,6 @@ end target 'StreamReactNativeVideoSDKSample' do config = use_native_modules! - # Flipper is not compatible with use_frameworks - # workaround to enable flipper described [here](https://github.com/invertase/react-native-firebase/issues/6425#issuecomment-1527949355) - pod 'FirebaseCore', :modular_headers => true - pod 'FirebaseCoreExtension', :modular_headers => true - pod 'FirebaseInstallations', :modular_headers => true - pod 'GoogleDataTransport', :modular_headers => true - pod 'GoogleUtilities', :modular_headers => true - pod 'nanopb', :modular_headers => true - # Flags change depending on the env values. flags = get_default_flags() diff --git a/sample-apps/react-native/dogfood/ios/Podfile.lock b/sample-apps/react-native/dogfood/ios/Podfile.lock index 2c195c129a..1f634773e1 100644 --- a/sample-apps/react-native/dogfood/ios/Podfile.lock +++ b/sample-apps/react-native/dogfood/ios/Podfile.lock @@ -16,33 +16,6 @@ PODS: - React-Core (= 0.71.11) - React-jsi (= 0.71.11) - ReactCommon/turbomodule/core (= 0.71.11) - - Firebase/CoreOnly (10.7.0): - - FirebaseCore (= 10.7.0) - - Firebase/Messaging (10.7.0): - - Firebase/CoreOnly - - FirebaseMessaging (~> 10.7.0) - - FirebaseCore (10.7.0): - - FirebaseCoreInternal (~> 10.0) - - GoogleUtilities/Environment (~> 7.8) - - GoogleUtilities/Logger (~> 7.8) - - FirebaseCoreExtension (10.7.0): - - FirebaseCore (~> 10.0) - - FirebaseCoreInternal (10.10.0): - - "GoogleUtilities/NSData+zlib (~> 7.8)" - - FirebaseInstallations (10.10.0): - - FirebaseCore (~> 10.0) - - GoogleUtilities/Environment (~> 7.8) - - GoogleUtilities/UserDefaults (~> 7.8) - - PromisesObjC (~> 2.1) - - FirebaseMessaging (10.7.0): - - FirebaseCore (~> 10.0) - - FirebaseInstallations (~> 10.0) - - GoogleDataTransport (~> 9.2) - - GoogleUtilities/AppDelegateSwizzler (~> 7.8) - - GoogleUtilities/Environment (~> 7.8) - - GoogleUtilities/Reachability (~> 7.8) - - GoogleUtilities/UserDefaults (~> 7.8) - - nanopb (< 2.30910.0, >= 2.30908.0) - Flipper (0.125.0): - Flipper-Folly (~> 2.6) - Flipper-RSocket (~> 1.4) @@ -106,47 +79,10 @@ PODS: - FlipperKit/FlipperKitNetworkPlugin - fmt (6.2.1) - glog (0.3.5) - - GoogleDataTransport (9.2.3): - - GoogleUtilities/Environment (~> 7.7) - - nanopb (< 2.30910.0, >= 2.30908.0) - - PromisesObjC (< 3.0, >= 1.2) - GoogleSignIn (6.2.4): - AppAuth (~> 1.5) - GTMAppAuth (~> 1.3) - GTMSessionFetcher/Core (< 3.0, >= 1.1) - - GoogleUtilities (7.11.1): - - GoogleUtilities/AppDelegateSwizzler (= 7.11.1) - - GoogleUtilities/Environment (= 7.11.1) - - GoogleUtilities/ISASwizzler (= 7.11.1) - - GoogleUtilities/Logger (= 7.11.1) - - GoogleUtilities/MethodSwizzler (= 7.11.1) - - GoogleUtilities/Network (= 7.11.1) - - "GoogleUtilities/NSData+zlib (= 7.11.1)" - - GoogleUtilities/Reachability (= 7.11.1) - - GoogleUtilities/SwizzlerTestHelpers (= 7.11.1) - - GoogleUtilities/UserDefaults (= 7.11.1) - - GoogleUtilities/AppDelegateSwizzler (7.11.1): - - GoogleUtilities/Environment - - GoogleUtilities/Logger - - GoogleUtilities/Network - - GoogleUtilities/Environment (7.11.1): - - PromisesObjC (< 3.0, >= 1.2) - - GoogleUtilities/ISASwizzler (7.11.1) - - GoogleUtilities/Logger (7.11.1): - - GoogleUtilities/Environment - - GoogleUtilities/MethodSwizzler (7.11.1): - - GoogleUtilities/Logger - - GoogleUtilities/Network (7.11.1): - - GoogleUtilities/Logger - - "GoogleUtilities/NSData+zlib" - - GoogleUtilities/Reachability - - "GoogleUtilities/NSData+zlib (7.11.1)" - - GoogleUtilities/Reachability (7.11.1): - - GoogleUtilities/Logger - - GoogleUtilities/SwizzlerTestHelpers (7.11.1): - - GoogleUtilities/MethodSwizzler - - GoogleUtilities/UserDefaults (7.11.1): - - GoogleUtilities/Logger - GTMAppAuth (1.3.1): - AppAuth/Core (~> 1.6) - GTMSessionFetcher/Core (< 3.0, >= 1.5) @@ -155,16 +91,10 @@ PODS: - hermes-engine/Pre-built (= 0.71.11) - hermes-engine/Pre-built (0.71.11) - libevent (2.1.12) - - MMKV (1.2.16): - - MMKVCore (~> 1.2.16) - - MMKVCore (1.2.16) - - nanopb (2.30909.0): - - nanopb/decode (= 2.30909.0) - - nanopb/encode (= 2.30909.0) - - nanopb/decode (2.30909.0) - - nanopb/encode (2.30909.0) + - MMKV (1.3.1): + - MMKVCore (~> 1.3.1) + - MMKVCore (1.3.1) - OpenSSL-Universal (1.1.1100) - - PromisesObjC (2.2.0) - RCT-Folly (2021.07.22.00): - boost - DoubleConversion @@ -526,17 +456,11 @@ PODS: - React - RNCClipboard (1.11.2): - React-Core - - RNFBApp (17.5.0): - - Firebase/CoreOnly (= 10.7.0) + - RNCPushNotificationIOS (1.11.0): - React-Core - - RNFBMessaging (17.5.0): - - Firebase/Messaging (= 10.7.0) - - FirebaseCoreExtension (= 10.7.0) - - React-Core - - RNFBApp - RNFS (2.20.0): - React-Core - - RNGestureHandler (2.12.0): + - RNGestureHandler (2.12.1): - React-Core - RNGoogleSignin (8.2.2): - GoogleSignIn (~> 6.2) @@ -555,7 +479,7 @@ PODS: - RNNotifee/NotifeeCore (= 7.8.0) - RNNotifee/NotifeeCore (7.8.0): - React-Core - - RNPermissions (3.8.0): + - RNPermissions (3.9.2): - React-Core - RNReactNativeHapticFeedback (2.0.3): - React-Core @@ -595,11 +519,11 @@ PODS: - React-Core - RNVoipPushNotification (3.3.1): - React-Core - - SocketRocket (0.6.0) + - SocketRocket (0.6.1) - stream-react-native-webrtc (104.0.1): - React-Core - WebRTC-SDK (= 104.5112.17) - - stream-video-react-native (0.0.4): + - stream-video-react-native (0.0.15): - React-Core - stream-react-native-webrtc - TOCropViewController (2.6.1) @@ -613,9 +537,6 @@ DEPENDENCIES: - DoubleConversion (from `../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec`) - FBLazyVector (from `../node_modules/react-native/Libraries/FBLazyVector`) - FBReactNativeSpec (from `../node_modules/react-native/React/FBReactNativeSpec`) - - FirebaseCore - - FirebaseCoreExtension - - FirebaseInstallations - Flipper (= 0.125.0) - Flipper-Boost-iOSX (= 1.76.0.1.11) - Flipper-DoubleConversion (= 3.2.0.1) @@ -638,11 +559,8 @@ DEPENDENCIES: - FlipperKit/FlipperKitUserDefaultsPlugin (= 0.125.0) - FlipperKit/SKIOSNetworkPlugin (= 0.125.0) - glog (from `../node_modules/react-native/third-party-podspecs/glog.podspec`) - - GoogleDataTransport - - GoogleUtilities - hermes-engine (from `../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec`) - libevent (~> 2.1.12) - - nanopb - OpenSSL-Universal (= 1.1.1100) - RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`) - RCTRequired (from `../node_modules/react-native/Libraries/RCTRequired`) @@ -682,8 +600,7 @@ DEPENDENCIES: - ReactNativeIncallManager (from `../node_modules/react-native-incall-manager`) - RNCallKeep (from `../node_modules/react-native-callkeep`) - "RNCClipboard (from `../node_modules/@react-native-clipboard/clipboard`)" - - "RNFBApp (from `../node_modules/@react-native-firebase/app`)" - - "RNFBMessaging (from `../node_modules/@react-native-firebase/messaging`)" + - "RNCPushNotificationIOS (from `../node_modules/@react-native-community/push-notification-ios`)" - RNFS (from `../node_modules/react-native-fs`) - RNGestureHandler (from `../node_modules/react-native-gesture-handler`) - "RNGoogleSignin (from `../node_modules/@react-native-google-signin/google-signin`)" @@ -703,12 +620,6 @@ SPEC REPOS: trunk: - AppAuth - CocoaAsyncSocket - - Firebase - - FirebaseCore - - FirebaseCoreExtension - - FirebaseCoreInternal - - FirebaseInstallations - - FirebaseMessaging - Flipper - Flipper-Boost-iOSX - Flipper-DoubleConversion @@ -719,17 +630,13 @@ SPEC REPOS: - Flipper-RSocket - FlipperKit - fmt - - GoogleDataTransport - GoogleSignIn - - GoogleUtilities - GTMAppAuth - GTMSessionFetcher - libevent - MMKV - MMKVCore - - nanopb - OpenSSL-Universal - - PromisesObjC - SocketRocket - TOCropViewController - WebRTC-SDK @@ -820,10 +727,8 @@ EXTERNAL SOURCES: :path: "../node_modules/react-native-callkeep" RNCClipboard: :path: "../node_modules/@react-native-clipboard/clipboard" - RNFBApp: - :path: "../node_modules/@react-native-firebase/app" - RNFBMessaging: - :path: "../node_modules/@react-native-firebase/messaging" + RNCPushNotificationIOS: + :path: "../node_modules/@react-native-community/push-notification-ios" RNFS: :path: "../node_modules/react-native-fs" RNGestureHandler: @@ -860,12 +765,6 @@ SPEC CHECKSUMS: DoubleConversion: 5189b271737e1565bdce30deb4a08d647e3f5f54 FBLazyVector: c511d4cd0210f416cb5c289bd5ae6b36d909b048 FBReactNativeSpec: a911fb22def57aef1d74215e8b6b8761d25c1c54 - Firebase: 0219acf760880eeec8ce479895bd7767466d9f81 - FirebaseCore: e317665b9d744727a97e623edbbed009320afdd7 - FirebaseCoreExtension: f17247ba8c61e4d3c8d136b5e2de3cb4ac6a85b6 - FirebaseCoreInternal: 971029061d326000d65bfdc21f5502c75c8b0893 - FirebaseInstallations: 52153982b057d3afcb4e1fbb3eb0b6d00611e681 - FirebaseMessaging: ac9062bcc35ed56e15a0241d8fd317022499baf8 Flipper: 26fc4b7382499f1281eb8cb921e5c3ad6de91fe0 Flipper-Boost-iOSX: fd1e2b8cbef7e662a122412d7ac5f5bea715403c Flipper-DoubleConversion: 2dc99b02f658daf147069aad9dbd29d8feb06d30 @@ -877,18 +776,14 @@ SPEC CHECKSUMS: FlipperKit: cbdee19bdd4e7f05472a66ce290f1b729ba3cb86 fmt: ff9d55029c625d3757ed641535fd4a75fedc7ce9 glog: 04b94705f318337d7ead9e6d17c019bd9b1f6b1b - GoogleDataTransport: f0308f5905a745f94fb91fea9c6cbaf3831cb1bd GoogleSignIn: 5651ce3a61e56ca864160e79b484cd9ed3f49b7a - GoogleUtilities: 9aa0ad5a7bc171f8bae016300bfcfa3fb8425749 GTMAppAuth: 0ff230db599948a9ad7470ca667337803b3fc4dd GTMSessionFetcher: 3a63d75eecd6aa32c2fc79f578064e1214dfdec2 hermes-engine: 34c863b446d0135b85a6536fa5fd89f48196f848 libevent: 4049cae6c81cdb3654a443be001fb9bdceff7913 - MMKV: 784471ce430a2e2d16afef9053d63fab1b357d9e - MMKVCore: 9cfef4c48c6c46f66226fc2e4634d78490206a48 - nanopb: b552cce312b6c8484180ef47159bc0f65a1f0431 + MMKV: 5a07930c70c70b86cd87761a42c8f3836fb681d7 + MMKVCore: e50135dbd33235b6ab390635991bab437ab873c0 OpenSSL-Universal: ebc357f1e6bc71fa463ccb2fe676756aff50e88c - PromisesObjC: 09985d6d70fbe7878040aa746d78236e6946d2ef RCT-Folly: 424b8c9a7a0b9ab2886ffe9c3b041ef628fd4fb1 RCTRequired: f6187ec763637e6a57f5728dd9a3bdabc6d6b4e0 RCTTypeSafety: a01aca2dd3b27fa422d5239252ad38e54e958750 @@ -925,27 +820,26 @@ SPEC CHECKSUMS: ReactNativeIncallManager: 2385505fa5dfdbbc78925e3b8d23b30ce0cde40e RNCallKeep: 7bfa8f502067be6650eeca5ec0ebbf795314c5c3 RNCClipboard: 3f0451a8100393908bea5c5c5b16f96d45f30bfc - RNFBApp: d59efa0872fff4e27de03cca3c528c203a436ae5 - RNFBMessaging: 216693dd5ba4f18ba65fb39fc73a44a23c26190f + RNCPushNotificationIOS: 64218f3c776c03d7408284a819b2abfda1834bc8 RNFS: 4ac0f0ea233904cb798630b3c077808c06931688 - RNGestureHandler: dec4645026e7401a0899f2846d864403478ff6a5 + RNGestureHandler: c0d04458598fcb26052494ae23dda8f8f5162b13 RNGoogleSignin: 81521697b2c8f97f9a586ac7257b1a1d9b51b115 RNImageCropPicker: 486e2f7e2b0461ce24321f751410dce1b3b49e6d RNNotifee: f3c01b391dd8e98e67f539f9a35a9cbcd3bae744 - RNPermissions: eff9b5e06eede1260a053963f760d3b1fdc51a3b + RNPermissions: 533c589814ab1b707c77b6974f64cc37ce6d42e4 RNReactNativeHapticFeedback: afa5bf2794aecbb2dba2525329253da0d66656df RNReanimated: 9976fbaaeb8a188c36026154c844bf374b3b7eeb RNScreens: 218801c16a2782546d30bd2026bb625c0302d70f RNSVG: 53c661b76829783cdaf9b7a57258f3d3b4c28315 RNVoipPushNotification: 1617f5a07be24066830213ae9252cb790b53886f - SocketRocket: fccef3f9c5cedea1353a9ef6ada904fde10d6608 + SocketRocket: f32cd54efbe0f095c4d7594881e52619cfe80b17 stream-react-native-webrtc: 3e45950d539248d24c1a0a3eafa0f98b5a343ab3 - stream-video-react-native: 92e1aea0964d810af81ddc6f5359c182eb3a0fd9 + stream-video-react-native: f1a2d487b0cf3212bf587dbd73def67937f1486d TOCropViewController: edfd4f25713d56905ad1e0b9f5be3fbe0f59c863 WebRTC-SDK: 082ae4893212534a779ca233f19a9df8efd5f3bd Yoga: f7decafdc5e8c125e6fa0da38a687e35238420fa YogaKit: f782866e155069a2cca2517aafea43200b01fd5a -PODFILE CHECKSUM: 41e93cd2e8bce3f44104edb48b9b364a0e34bd71 +PODFILE CHECKSUM: ad174b9236e4b8582fb7ec315b644cbfa9557605 COCOAPODS: 1.12.1 diff --git a/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample.xcodeproj/project.pbxproj b/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample.xcodeproj/project.pbxproj index 911a8234e8..401556f150 100644 --- a/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample.xcodeproj/project.pbxproj +++ b/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample.xcodeproj/project.pbxproj @@ -12,8 +12,8 @@ 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */; }; - B49860DFC12417C6EF7F789C /* libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 1B13B410152683D67603781C /* libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a */; }; - D54A5F80FCCCAB78FCE9FB6A /* libPods-StreamReactNativeVideoSDKSample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = AC279C6A8CA42E70BCA9F960 /* libPods-StreamReactNativeVideoSDKSample.a */; }; + D29905C9FEFBDE3425FE4918 /* libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = C42539220A21BB7C6961E53A /* libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a */; }; + D60F78EC16CA0DD1ACEF890C /* libPods-StreamReactNativeVideoSDKSample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 9FAC086DB956152C16435BF1 /* libPods-StreamReactNativeVideoSDKSample.a */; }; DD17437129221798001CBEA0 /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = DD17437029221798001CBEA0 /* GoogleService-Info.plist */; }; DD17437229221798001CBEA0 /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = DD17437029221798001CBEA0 /* GoogleService-Info.plist */; }; DD6FC6022987E2D700B13B16 /* Intents.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DD6FC6012987E2D700B13B16 /* Intents.framework */; settings = {ATTRIBUTES = (Weak, ); }; }; @@ -40,13 +40,13 @@ 13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = StreamReactNativeVideoSDKSample/Images.xcassets; sourceTree = ""; }; 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = StreamReactNativeVideoSDKSample/Info.plist; sourceTree = ""; }; 13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = StreamReactNativeVideoSDKSample/main.m; sourceTree = ""; }; - 1B13B410152683D67603781C /* libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; - 3B4392A12AC88292D35C810B /* Pods-StreamReactNativeVideoSDKSample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-StreamReactNativeVideoSDKSample.debug.xcconfig"; path = "Target Support Files/Pods-StreamReactNativeVideoSDKSample/Pods-StreamReactNativeVideoSDKSample.debug.xcconfig"; sourceTree = ""; }; - 5709B34CF0A7D63546082F79 /* Pods-StreamReactNativeVideoSDKSample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-StreamReactNativeVideoSDKSample.release.xcconfig"; path = "Target Support Files/Pods-StreamReactNativeVideoSDKSample/Pods-StreamReactNativeVideoSDKSample.release.xcconfig"; sourceTree = ""; }; - 5B7EB9410499542E8C5724F5 /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.debug.xcconfig"; path = "Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.debug.xcconfig"; sourceTree = ""; }; + 708A154FC8B4F4BC106A6A17 /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.debug.xcconfig"; path = "Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.debug.xcconfig"; sourceTree = ""; }; 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = LaunchScreen.storyboard; path = StreamReactNativeVideoSDKSample/LaunchScreen.storyboard; sourceTree = ""; }; - 89C6BE57DB24E9ADA2F236DE /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.release.xcconfig"; path = "Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.release.xcconfig"; sourceTree = ""; }; - AC279C6A8CA42E70BCA9F960 /* libPods-StreamReactNativeVideoSDKSample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-StreamReactNativeVideoSDKSample.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + 9FAC086DB956152C16435BF1 /* libPods-StreamReactNativeVideoSDKSample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-StreamReactNativeVideoSDKSample.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + 9FF5873D7CFBD5B6ADF5E88E /* Pods-StreamReactNativeVideoSDKSample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-StreamReactNativeVideoSDKSample.debug.xcconfig"; path = "Target Support Files/Pods-StreamReactNativeVideoSDKSample/Pods-StreamReactNativeVideoSDKSample.debug.xcconfig"; sourceTree = ""; }; + BFF02C9ED8B0E334A6042435 /* Pods-StreamReactNativeVideoSDKSample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-StreamReactNativeVideoSDKSample.release.xcconfig"; path = "Target Support Files/Pods-StreamReactNativeVideoSDKSample/Pods-StreamReactNativeVideoSDKSample.release.xcconfig"; sourceTree = ""; }; + C42539220A21BB7C6961E53A /* libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + D9BA28C1DE31CC574CAF95CF /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.release.xcconfig"; path = "Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.release.xcconfig"; sourceTree = ""; }; DD17437029221798001CBEA0 /* GoogleService-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "GoogleService-Info.plist"; sourceTree = ""; }; DD17437329229D96001CBEA0 /* StreamReactNativeVideoSDKSample.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; name = StreamReactNativeVideoSDKSample.entitlements; path = StreamReactNativeVideoSDKSample/StreamReactNativeVideoSDKSample.entitlements; sourceTree = ""; }; DD6FC6012987E2D700B13B16 /* Intents.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Intents.framework; path = System/Library/Frameworks/Intents.framework; sourceTree = SDKROOT; }; @@ -59,7 +59,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - B49860DFC12417C6EF7F789C /* libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a in Frameworks */, + D29905C9FEFBDE3425FE4918 /* libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -69,7 +69,7 @@ files = ( DD6FC6042987E2E800B13B16 /* CallKit.framework in Frameworks */, DD6FC6022987E2D700B13B16 /* Intents.framework in Frameworks */, - D54A5F80FCCCAB78FCE9FB6A /* libPods-StreamReactNativeVideoSDKSample.a in Frameworks */, + D60F78EC16CA0DD1ACEF890C /* libPods-StreamReactNativeVideoSDKSample.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -114,8 +114,8 @@ DD6FC6032987E2E800B13B16 /* CallKit.framework */, DD6FC6012987E2D700B13B16 /* Intents.framework */, ED297162215061F000B7C4FE /* JavaScriptCore.framework */, - AC279C6A8CA42E70BCA9F960 /* libPods-StreamReactNativeVideoSDKSample.a */, - 1B13B410152683D67603781C /* libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a */, + 9FAC086DB956152C16435BF1 /* libPods-StreamReactNativeVideoSDKSample.a */, + C42539220A21BB7C6961E53A /* libPods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.a */, ); name = Frameworks; sourceTree = ""; @@ -154,10 +154,10 @@ BBD78D7AC51CEA395F1C20DB /* Pods */ = { isa = PBXGroup; children = ( - 3B4392A12AC88292D35C810B /* Pods-StreamReactNativeVideoSDKSample.debug.xcconfig */, - 5709B34CF0A7D63546082F79 /* Pods-StreamReactNativeVideoSDKSample.release.xcconfig */, - 5B7EB9410499542E8C5724F5 /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.debug.xcconfig */, - 89C6BE57DB24E9ADA2F236DE /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.release.xcconfig */, + 9FF5873D7CFBD5B6ADF5E88E /* Pods-StreamReactNativeVideoSDKSample.debug.xcconfig */, + BFF02C9ED8B0E334A6042435 /* Pods-StreamReactNativeVideoSDKSample.release.xcconfig */, + 708A154FC8B4F4BC106A6A17 /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.debug.xcconfig */, + D9BA28C1DE31CC574CAF95CF /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.release.xcconfig */, ); path = Pods; sourceTree = ""; @@ -169,12 +169,12 @@ isa = PBXNativeTarget; buildConfigurationList = 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "StreamReactNativeVideoSDKSampleTests" */; buildPhases = ( - A55EABD7B0C7F3A422A6CC61 /* [CP] Check Pods Manifest.lock */, + 7EE90DE157EC5BD691466B8A /* [CP] Check Pods Manifest.lock */, 00E356EA1AD99517003FC87E /* Sources */, 00E356EB1AD99517003FC87E /* Frameworks */, 00E356EC1AD99517003FC87E /* Resources */, - C59DA0FBD6956966B86A3779 /* [CP] Embed Pods Frameworks */, - F6A41C54EA430FDDC6A6ED99 /* [CP] Copy Pods Resources */, + 19ECAECAD6463CA2681EC5CB /* [CP] Embed Pods Frameworks */, + 19A18E83588531331E4B48D7 /* [CP] Copy Pods Resources */, ); buildRules = ( ); @@ -190,15 +190,14 @@ isa = PBXNativeTarget; buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "StreamReactNativeVideoSDKSample" */; buildPhases = ( - C38B50BA6285516D6DCD4F65 /* [CP] Check Pods Manifest.lock */, + CD4DC9A90C7229A40EEC8FBB /* [CP] Check Pods Manifest.lock */, FD10A7F022414F080027D42C /* Start Packager */, 13B07F871A680F5B00A75B9A /* Sources */, 13B07F8C1A680F5B00A75B9A /* Frameworks */, 13B07F8E1A680F5B00A75B9A /* Resources */, 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */, - 00EEFC60759A1932668264C0 /* [CP] Embed Pods Frameworks */, - E235C05ADACE081382539298 /* [CP] Copy Pods Resources */, - 070AA06F9DF64CBE17015672 /* [CP-User] [RNFB] Core Configuration */, + 4623B4B911013BF02A675B4A /* [CP] Embed Pods Frameworks */, + 8EACAB609F9BB513D86DDB4F /* [CP] Copy Pods Resources */, ); buildRules = ( ); @@ -283,59 +282,58 @@ shellPath = /bin/sh; shellScript = "set -e\n\nWITH_ENVIRONMENT=\"../node_modules/react-native/scripts/xcode/with-environment.sh\"\nREACT_NATIVE_XCODE=\"../node_modules/react-native/scripts/react-native-xcode.sh\"\n\n/bin/sh -c \"$WITH_ENVIRONMENT $REACT_NATIVE_XCODE\"\n"; }; - 00EEFC60759A1932668264C0 /* [CP] Embed Pods Frameworks */ = { + 19A18E83588531331E4B48D7 /* [CP] Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample/Pods-StreamReactNativeVideoSDKSample-frameworks-${CONFIGURATION}-input-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-resources-${CONFIGURATION}-input-files.xcfilelist", ); - name = "[CP] Embed Pods Frameworks"; + name = "[CP] Copy Pods Resources"; outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample/Pods-StreamReactNativeVideoSDKSample-frameworks-${CONFIGURATION}-output-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-resources-${CONFIGURATION}-output-files.xcfilelist", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample/Pods-StreamReactNativeVideoSDKSample-frameworks.sh\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-resources.sh\"\n"; showEnvVarsInLog = 0; }; - 070AA06F9DF64CBE17015672 /* [CP-User] [RNFB] Core Configuration */ = { + 19ECAECAD6463CA2681EC5CB /* [CP] Embed Pods Frameworks */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); - inputPaths = ( - "$(BUILT_PRODUCTS_DIR)/$(INFOPLIST_PATH)", + inputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-frameworks-${CONFIGURATION}-input-files.xcfilelist", + ); + name = "[CP] Embed Pods Frameworks"; + outputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-frameworks-${CONFIGURATION}-output-files.xcfilelist", ); - name = "[CP-User] [RNFB] Core Configuration"; runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "#!/usr/bin/env bash\n#\n# Copyright (c) 2016-present Invertase Limited & Contributors\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this library except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n#\nset -e\n\n_MAX_LOOKUPS=2;\n_SEARCH_RESULT=''\n_RN_ROOT_EXISTS=''\n_CURRENT_LOOKUPS=1\n_JSON_ROOT=\"'react-native'\"\n_JSON_FILE_NAME='firebase.json'\n_JSON_OUTPUT_BASE64='e30=' # { }\n_CURRENT_SEARCH_DIR=${PROJECT_DIR}\n_PLIST_BUDDY=/usr/libexec/PlistBuddy\n_TARGET_PLIST=\"${BUILT_PRODUCTS_DIR}/${INFOPLIST_PATH}\"\n_DSYM_PLIST=\"${DWARF_DSYM_FOLDER_PATH}/${DWARF_DSYM_FILE_NAME}/Contents/Info.plist\"\n\n# plist arrays\n_PLIST_ENTRY_KEYS=()\n_PLIST_ENTRY_TYPES=()\n_PLIST_ENTRY_VALUES=()\n\nfunction setPlistValue {\n echo \"info: setting plist entry '$1' of type '$2' in file '$4'\"\n ${_PLIST_BUDDY} -c \"Add :$1 $2 '$3'\" $4 || echo \"info: '$1' already exists\"\n}\n\nfunction getFirebaseJsonKeyValue () {\n if [[ ${_RN_ROOT_EXISTS} ]]; then\n ruby -Ku -e \"require 'rubygems';require 'json'; output=JSON.parse('$1'); puts output[$_JSON_ROOT]['$2']\"\n else\n echo \"\"\n fi;\n}\n\nfunction jsonBoolToYesNo () {\n if [[ $1 == \"false\" ]]; then\n echo \"NO\"\n elif [[ $1 == \"true\" ]]; then\n echo \"YES\"\n else echo \"NO\"\n fi\n}\n\necho \"info: -> RNFB build script started\"\necho \"info: 1) Locating ${_JSON_FILE_NAME} file:\"\n\nif [[ -z ${_CURRENT_SEARCH_DIR} ]]; then\n _CURRENT_SEARCH_DIR=$(pwd)\nfi;\n\nwhile true; do\n _CURRENT_SEARCH_DIR=$(dirname \"$_CURRENT_SEARCH_DIR\")\n if [[ \"$_CURRENT_SEARCH_DIR\" == \"/\" ]] || [[ ${_CURRENT_LOOKUPS} -gt ${_MAX_LOOKUPS} ]]; then break; fi;\n echo \"info: ($_CURRENT_LOOKUPS of $_MAX_LOOKUPS) Searching in '$_CURRENT_SEARCH_DIR' for a ${_JSON_FILE_NAME} file.\"\n _SEARCH_RESULT=$(find \"$_CURRENT_SEARCH_DIR\" -maxdepth 2 -name ${_JSON_FILE_NAME} -print | /usr/bin/head -n 1)\n if [[ ${_SEARCH_RESULT} ]]; then\n echo \"info: ${_JSON_FILE_NAME} found at $_SEARCH_RESULT\"\n break;\n fi;\n _CURRENT_LOOKUPS=$((_CURRENT_LOOKUPS+1))\ndone\n\nif [[ ${_SEARCH_RESULT} ]]; then\n _JSON_OUTPUT_RAW=$(cat \"${_SEARCH_RESULT}\")\n _RN_ROOT_EXISTS=$(ruby -Ku -e \"require 'rubygems';require 'json'; output=JSON.parse('$_JSON_OUTPUT_RAW'); puts output[$_JSON_ROOT]\" || echo '')\n\n if [[ ${_RN_ROOT_EXISTS} ]]; then\n if ! python3 --version >/dev/null 2>&1; then echo \"python3 not found, firebase.json file processing error.\" && exit 1; fi\n _JSON_OUTPUT_BASE64=$(python3 -c 'import json,sys,base64;print(base64.b64encode(bytes(json.dumps(json.loads(open('\"'${_SEARCH_RESULT}'\"', '\"'rb'\"').read())['${_JSON_ROOT}']), '\"'utf-8'\"')).decode())' || echo \"e30=\")\n fi\n\n _PLIST_ENTRY_KEYS+=(\"firebase_json_raw\")\n _PLIST_ENTRY_TYPES+=(\"string\")\n _PLIST_ENTRY_VALUES+=(\"$_JSON_OUTPUT_BASE64\")\n\n # config.app_data_collection_default_enabled\n _APP_DATA_COLLECTION_ENABLED=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"app_data_collection_default_enabled\")\n if [[ $_APP_DATA_COLLECTION_ENABLED ]]; then\n _PLIST_ENTRY_KEYS+=(\"FirebaseDataCollectionDefaultEnabled\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_APP_DATA_COLLECTION_ENABLED\")\")\n fi\n\n # config.analytics_auto_collection_enabled\n _ANALYTICS_AUTO_COLLECTION=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"analytics_auto_collection_enabled\")\n if [[ $_ANALYTICS_AUTO_COLLECTION ]]; then\n _PLIST_ENTRY_KEYS+=(\"FIREBASE_ANALYTICS_COLLECTION_ENABLED\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_ANALYTICS_AUTO_COLLECTION\")\")\n fi\n\n # config.analytics_collection_deactivated\n _ANALYTICS_DEACTIVATED=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"analytics_collection_deactivated\")\n if [[ $_ANALYTICS_DEACTIVATED ]]; then\n _PLIST_ENTRY_KEYS+=(\"FIREBASE_ANALYTICS_COLLECTION_DEACTIVATED\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_ANALYTICS_DEACTIVATED\")\")\n fi\n\n # config.analytics_idfv_collection_enabled\n _ANALYTICS_IDFV_COLLECTION=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"analytics_idfv_collection_enabled\")\n if [[ $_ANALYTICS_IDFV_COLLECTION ]]; then\n _PLIST_ENTRY_KEYS+=(\"GOOGLE_ANALYTICS_IDFV_COLLECTION_ENABLED\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_ANALYTICS_IDFV_COLLECTION\")\")\n fi\n\n # config.analytics_default_allow_ad_personalization_signals\n _ANALYTICS_PERSONALIZATION=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"analytics_default_allow_ad_personalization_signals\")\n if [[ $_ANALYTICS_PERSONALIZATION ]]; then\n _PLIST_ENTRY_KEYS+=(\"GOOGLE_ANALYTICS_DEFAULT_ALLOW_AD_PERSONALIZATION_SIGNALS\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_ANALYTICS_PERSONALIZATION\")\")\n fi\n\n # config.analytics_registration_with_ad_network_enabled\n _ANALYTICS_REGISTRATION_WITH_AD_NETWORK=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"google_analytics_registration_with_ad_network_enabled\")\n if [[ $_ANALYTICS_REGISTRATION_WITH_AD_NETWORK ]]; then\n _PLIST_ENTRY_KEYS+=(\"GOOGLE_ANALYTICS_REGISTRATION_WITH_AD_NETWORK_ENABLED\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_ANALYTICS_REGISTRATION_WITH_AD_NETWORK\")\")\n fi\n\n # config.google_analytics_automatic_screen_reporting_enabled\n _ANALYTICS_AUTO_SCREEN_REPORTING=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"google_analytics_automatic_screen_reporting_enabled\")\n if [[ $_ANALYTICS_AUTO_SCREEN_REPORTING ]]; then\n _PLIST_ENTRY_KEYS+=(\"FirebaseAutomaticScreenReportingEnabled\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_ANALYTICS_AUTO_SCREEN_REPORTING\")\")\n fi\n\n # config.perf_auto_collection_enabled\n _PERF_AUTO_COLLECTION=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"perf_auto_collection_enabled\")\n if [[ $_PERF_AUTO_COLLECTION ]]; then\n _PLIST_ENTRY_KEYS+=(\"firebase_performance_collection_enabled\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_PERF_AUTO_COLLECTION\")\")\n fi\n\n # config.perf_collection_deactivated\n _PERF_DEACTIVATED=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"perf_collection_deactivated\")\n if [[ $_PERF_DEACTIVATED ]]; then\n _PLIST_ENTRY_KEYS+=(\"firebase_performance_collection_deactivated\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_PERF_DEACTIVATED\")\")\n fi\n\n # config.messaging_auto_init_enabled\n _MESSAGING_AUTO_INIT=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"messaging_auto_init_enabled\")\n if [[ $_MESSAGING_AUTO_INIT ]]; then\n _PLIST_ENTRY_KEYS+=(\"FirebaseMessagingAutoInitEnabled\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_MESSAGING_AUTO_INIT\")\")\n fi\n\n # config.in_app_messaging_auto_colllection_enabled\n _FIAM_AUTO_INIT=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"in_app_messaging_auto_collection_enabled\")\n if [[ $_FIAM_AUTO_INIT ]]; then\n _PLIST_ENTRY_KEYS+=(\"FirebaseInAppMessagingAutomaticDataCollectionEnabled\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_FIAM_AUTO_INIT\")\")\n fi\n\n # config.app_check_token_auto_refresh\n _APP_CHECK_TOKEN_AUTO_REFRESH=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"app_check_token_auto_refresh\")\n if [[ $_APP_CHECK_TOKEN_AUTO_REFRESH ]]; then\n _PLIST_ENTRY_KEYS+=(\"FirebaseAppCheckTokenAutoRefreshEnabled\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"$(jsonBoolToYesNo \"$_APP_CHECK_TOKEN_AUTO_REFRESH\")\")\n fi\n\n # config.crashlytics_disable_auto_disabler - undocumented for now - mainly for debugging, document if becomes useful\n _CRASHLYTICS_AUTO_DISABLE_ENABLED=$(getFirebaseJsonKeyValue \"$_JSON_OUTPUT_RAW\" \"crashlytics_disable_auto_disabler\")\n if [[ $_CRASHLYTICS_AUTO_DISABLE_ENABLED == \"true\" ]]; then\n echo \"Disabled Crashlytics auto disabler.\" # do nothing\n else\n _PLIST_ENTRY_KEYS+=(\"FirebaseCrashlyticsCollectionEnabled\")\n _PLIST_ENTRY_TYPES+=(\"bool\")\n _PLIST_ENTRY_VALUES+=(\"NO\")\n fi\nelse\n _PLIST_ENTRY_KEYS+=(\"firebase_json_raw\")\n _PLIST_ENTRY_TYPES+=(\"string\")\n _PLIST_ENTRY_VALUES+=(\"$_JSON_OUTPUT_BASE64\")\n echo \"warning: A firebase.json file was not found, whilst this file is optional it is recommended to include it to configure firebase services in React Native Firebase.\"\nfi;\n\necho \"info: 2) Injecting Info.plist entries: \"\n\n# Log out the keys we're adding\nfor i in \"${!_PLIST_ENTRY_KEYS[@]}\"; do\n echo \" -> $i) ${_PLIST_ENTRY_KEYS[$i]}\" \"${_PLIST_ENTRY_TYPES[$i]}\" \"${_PLIST_ENTRY_VALUES[$i]}\"\ndone\n\nfor plist in \"${_TARGET_PLIST}\" \"${_DSYM_PLIST}\" ; do\n if [[ -f \"${plist}\" ]]; then\n\n # paths with spaces break the call to setPlistValue. temporarily modify\n # the shell internal field separator variable (IFS), which normally\n # includes spaces, to consist only of line breaks\n oldifs=$IFS\n IFS=\"\n\"\n\n for i in \"${!_PLIST_ENTRY_KEYS[@]}\"; do\n setPlistValue \"${_PLIST_ENTRY_KEYS[$i]}\" \"${_PLIST_ENTRY_TYPES[$i]}\" \"${_PLIST_ENTRY_VALUES[$i]}\" \"${plist}\"\n done\n\n # restore the original internal field separator value\n IFS=$oldifs\n else\n echo \"warning: A Info.plist build output file was not found (${plist})\"\n fi\ndone\n\necho \"info: <- RNFB build script finished\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-frameworks.sh\"\n"; + showEnvVarsInLog = 0; }; - A55EABD7B0C7F3A422A6CC61 /* [CP] Check Pods Manifest.lock */ = { + 4623B4B911013BF02A675B4A /* [CP] Embed Pods Frameworks */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample/Pods-StreamReactNativeVideoSDKSample-frameworks-${CONFIGURATION}-input-files.xcfilelist", ); - inputPaths = ( - "${PODS_PODFILE_DIR_PATH}/Podfile.lock", - "${PODS_ROOT}/Manifest.lock", - ); - name = "[CP] Check Pods Manifest.lock"; + name = "[CP] Embed Pods Frameworks"; outputFileListPaths = ( - ); - outputPaths = ( - "$(DERIVED_FILE_DIR)/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-checkManifestLockResult.txt", + "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample/Pods-StreamReactNativeVideoSDKSample-frameworks-${CONFIGURATION}-output-files.xcfilelist", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample/Pods-StreamReactNativeVideoSDKSample-frameworks.sh\"\n"; showEnvVarsInLog = 0; }; - C38B50BA6285516D6DCD4F65 /* [CP] Check Pods Manifest.lock */ = { + 7EE90DE157EC5BD691466B8A /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( @@ -350,31 +348,14 @@ outputFileListPaths = ( ); outputPaths = ( - "$(DERIVED_FILE_DIR)/Pods-StreamReactNativeVideoSDKSample-checkManifestLockResult.txt", + "$(DERIVED_FILE_DIR)/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-checkManifestLockResult.txt", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; showEnvVarsInLog = 0; }; - C59DA0FBD6956966B86A3779 /* [CP] Embed Pods Frameworks */ = { - isa = PBXShellScriptBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-frameworks-${CONFIGURATION}-input-files.xcfilelist", - ); - name = "[CP] Embed Pods Frameworks"; - outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-frameworks-${CONFIGURATION}-output-files.xcfilelist", - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-frameworks.sh\"\n"; - showEnvVarsInLog = 0; - }; - E235C05ADACE081382539298 /* [CP] Copy Pods Resources */ = { + 8EACAB609F9BB513D86DDB4F /* [CP] Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( @@ -391,21 +372,26 @@ shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample/Pods-StreamReactNativeVideoSDKSample-resources.sh\"\n"; showEnvVarsInLog = 0; }; - F6A41C54EA430FDDC6A6ED99 /* [CP] Copy Pods Resources */ = { + CD4DC9A90C7229A40EEC8FBB /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-resources-${CONFIGURATION}-input-files.xcfilelist", ); - name = "[CP] Copy Pods Resources"; + inputPaths = ( + "${PODS_PODFILE_DIR_PATH}/Podfile.lock", + "${PODS_ROOT}/Manifest.lock", + ); + name = "[CP] Check Pods Manifest.lock"; outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-resources-${CONFIGURATION}-output-files.xcfilelist", + ); + outputPaths = ( + "$(DERIVED_FILE_DIR)/Pods-StreamReactNativeVideoSDKSample-checkManifestLockResult.txt", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests/Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests-resources.sh\"\n"; + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; showEnvVarsInLog = 0; }; FD10A7F022414F080027D42C /* Start Packager */ = { @@ -460,7 +446,7 @@ /* Begin XCBuildConfiguration section */ 00E356F61AD99517003FC87E /* Debug */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 5B7EB9410499542E8C5724F5 /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.debug.xcconfig */; + baseConfigurationReference = 708A154FC8B4F4BC106A6A17 /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.debug.xcconfig */; buildSettings = { BUNDLE_LOADER = "$(TEST_HOST)"; "CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development"; @@ -489,7 +475,7 @@ }; 00E356F71AD99517003FC87E /* Release */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 89C6BE57DB24E9ADA2F236DE /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.release.xcconfig */; + baseConfigurationReference = D9BA28C1DE31CC574CAF95CF /* Pods-StreamReactNativeVideoSDKSample-StreamReactNativeVideoSDKSampleTests.release.xcconfig */; buildSettings = { BUNDLE_LOADER = "$(TEST_HOST)"; "CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development"; @@ -515,7 +501,7 @@ }; 13B07F941A680F5B00A75B9A /* Debug */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 3B4392A12AC88292D35C810B /* Pods-StreamReactNativeVideoSDKSample.debug.xcconfig */; + baseConfigurationReference = 9FF5873D7CFBD5B6ADF5E88E /* Pods-StreamReactNativeVideoSDKSample.debug.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; @@ -619,7 +605,7 @@ }; 13B07F951A680F5B00A75B9A /* Release */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 5709B34CF0A7D63546082F79 /* Pods-StreamReactNativeVideoSDKSample.release.xcconfig */; + baseConfigurationReference = BFF02C9ED8B0E334A6042435 /* Pods-StreamReactNativeVideoSDKSample.release.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; diff --git a/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/AppDelegate.h b/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/AppDelegate.h index 5d2808256c..cda1384d57 100644 --- a/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/AppDelegate.h +++ b/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/AppDelegate.h @@ -1,6 +1,7 @@ #import #import +#import -@interface AppDelegate : RCTAppDelegate +@interface AppDelegate : RCTAppDelegate @end diff --git a/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/AppDelegate.mm b/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/AppDelegate.mm index eb0c61d7e9..0ced1be8f2 100644 --- a/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/AppDelegate.mm +++ b/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/AppDelegate.mm @@ -7,10 +7,13 @@ #import "RNCallKeep.h" // PN related -#import #import #import "RNVoipPushNotificationManager.h" +// @react-native-community/push-notification-ios +#import +#import + #import "StreamVideoReactNative.h" @implementation AppDelegate @@ -22,6 +25,30 @@ - (BOOL)application:(UIApplication *)application return [RCTLinkingManager application:application openURL:url options:options]; } +// Required for the register event. +- (void)application:(UIApplication *)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken +{ + [RNCPushNotificationIOS didRegisterForRemoteNotificationsWithDeviceToken:deviceToken]; +} +// Required for the notification event. You must call the completion handler after handling the remote notification. +- (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo +fetchCompletionHandler:(void (^)(UIBackgroundFetchResult))completionHandler +{ + [RNCPushNotificationIOS didReceiveRemoteNotification:userInfo fetchCompletionHandler:completionHandler]; +} +// Required for the registrationError event. +- (void)application:(UIApplication *)application didFailToRegisterForRemoteNotificationsWithError:(NSError *)error +{ + [RNCPushNotificationIOS didFailToRegisterForRemoteNotificationsWithError:error]; +} +// Required for localNotification event +- (void)userNotificationCenter:(UNUserNotificationCenter *)center +didReceiveNotificationResponse:(UNNotificationResponse *)response + withCompletionHandler:(void (^)(void))completionHandler +{ + [RNCPushNotificationIOS didReceiveNotificationResponse:response]; +} + - (BOOL)application:(UIApplication *)application continueUserActivity:(nonnull NSUserActivity *)userActivity restorationHandler:(nonnull void (^)(NSArray> * _Nullable))restorationHandler @@ -62,10 +89,15 @@ - (void)pushRegistry:(PKPushRegistry *)registry didReceiveIncomingPushWithPayloa withCompletionHandler: completion]; } +//Called when a notification is delivered to a foreground app. +-(void)userNotificationCenter:(UNUserNotificationCenter *)center willPresentNotification:(UNNotification *)notification withCompletionHandler:(void (^)(UNNotificationPresentationOptions options))completionHandler +{ + completionHandler(UNNotificationPresentationOptionSound | UNNotificationPresentationOptionAlert | UNNotificationPresentationOptionBadge); +} + - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { [StreamVideoReactNative setup]; - [FIRApp configure]; NSString *localizedAppName = [[[NSBundle mainBundle] localizedInfoDictionary] objectForKey:@"CFBundleDisplayName"]; NSString *appName = [[[NSBundle mainBundle] infoDictionary]objectForKey :@"CFBundleDisplayName"]; [RNCallKeep setup:@{ @@ -81,6 +113,9 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:( // They will be passed down to the ViewController used by React Native. self.initialProps = @{}; + UNUserNotificationCenter *center = [UNUserNotificationCenter currentNotificationCenter]; + center.delegate = self; + return [super application:application didFinishLaunchingWithOptions:launchOptions]; } diff --git a/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/Info.plist b/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/Info.plist index bc60e0ed40..c1a77fe17a 100644 --- a/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/Info.plist +++ b/sample-apps/react-native/dogfood/ios/StreamReactNativeVideoSDKSample/Info.plist @@ -71,6 +71,7 @@ UIBackgroundModes audio + fetch remote-notification voip diff --git a/sample-apps/react-native/dogfood/package.json b/sample-apps/react-native/dogfood/package.json index 8af4624f25..5de2cd2541 100644 --- a/sample-apps/react-native/dogfood/package.json +++ b/sample-apps/react-native/dogfood/package.json @@ -22,6 +22,7 @@ "@react-native-camera-roll/camera-roll": "^5.6.0", "@react-native-clipboard/clipboard": "^1.11.1", "@react-native-community/netinfo": "9.3.10", + "@react-native-community/push-notification-ios": "^1.11.0", "@react-native-firebase/app": "17.5.0", "@react-native-firebase/messaging": "17.5.0", "@react-native-google-signin/google-signin": "^8.2.1", @@ -40,7 +41,7 @@ "react-native-image-resizer": "^1.4.5", "react-native-incall-manager": "4.1.0", "react-native-mmkv": "2.8.0", - "react-native-permissions": "^3.8.0", + "react-native-permissions": "^3.9.2", "react-native-reanimated": "^3.3.0", "react-native-safe-area-context": "^4.4.1", "react-native-screens": "^3.18.1", diff --git a/sample-apps/react-native/dogfood/react-native.config.js b/sample-apps/react-native/dogfood/react-native.config.js new file mode 100644 index 0000000000..9eb4f6cb1e --- /dev/null +++ b/sample-apps/react-native/dogfood/react-native.config.js @@ -0,0 +1,14 @@ +module.exports = { + dependencies: { + '@react-native-firebase/app': { + platforms: { + ios: null, + }, + }, + '@react-native-firebase/messaging': { + platforms: { + ios: null, + }, + }, + }, +}; diff --git a/sample-apps/react-native/dogfood/reactNativePermissionsIOS.json b/sample-apps/react-native/dogfood/reactNativePermissionsIOS.json deleted file mode 100644 index eac6294d45..0000000000 --- a/sample-apps/react-native/dogfood/reactNativePermissionsIOS.json +++ /dev/null @@ -1,4 +0,0 @@ -[ - "Camera", - "Microphone" -] diff --git a/sample-apps/react-native/dogfood/src/components/NavigationHeader.tsx b/sample-apps/react-native/dogfood/src/components/NavigationHeader.tsx index dcd8357888..6eddb69780 100755 --- a/sample-apps/react-native/dogfood/src/components/NavigationHeader.tsx +++ b/sample-apps/react-native/dogfood/src/components/NavigationHeader.tsx @@ -37,7 +37,7 @@ export const NavigationHeader = ({ route }: NativeStackHeaderProps) => { text: 'OK', onPress: async () => { try { - StreamVideoRN.onLogout(); + StreamVideoRN.onPushLogout(); await Promise.all([ GoogleSignin.signOut(), videoClient?.disconnectUser(), diff --git a/sample-apps/react-native/dogfood/src/hooks/useSyncPermissions.ts b/sample-apps/react-native/dogfood/src/hooks/useSyncPermissions.ts index 0c81843b64..140351293e 100644 --- a/sample-apps/react-native/dogfood/src/hooks/useSyncPermissions.ts +++ b/sample-apps/react-native/dogfood/src/hooks/useSyncPermissions.ts @@ -1,6 +1,10 @@ import { useEffect } from 'react'; import { Platform } from 'react-native'; -import { PERMISSIONS, requestMultiple } from 'react-native-permissions'; +import { + PERMISSIONS, + requestMultiple, + requestNotifications, +} from 'react-native-permissions'; /** * This hook is used to sync the permissions of the app with the Stream Video SDK. @@ -22,7 +26,7 @@ const requestAndUpdatePermissions = async () => { PERMISSIONS.ANDROID.CAMERA, PERMISSIONS.ANDROID.RECORD_AUDIO, PERMISSIONS.ANDROID.BLUETOOTH_CONNECT, - PERMISSIONS.ANDROID.POST_NOTIFICATIONS, ]); } + await requestNotifications(['alert', 'sound']); }; diff --git a/sample-apps/react-native/dogfood/src/screens/Meeting/MeetingScreen.tsx b/sample-apps/react-native/dogfood/src/screens/Meeting/MeetingScreen.tsx index 0d28735099..28cd5e489b 100644 --- a/sample-apps/react-native/dogfood/src/screens/Meeting/MeetingScreen.tsx +++ b/sample-apps/react-native/dogfood/src/screens/Meeting/MeetingScreen.tsx @@ -7,6 +7,7 @@ import { } from '@stream-io/video-react-native-sdk'; import { MeetingStackParamList } from '../../../types'; import { MeetingUI } from '../../components/MeetingUI'; +import { KnownUsers } from '../../constants/KnownUsers'; type Props = NativeStackScreenProps; @@ -27,7 +28,15 @@ export const MeetingScreen = (props: Props) => { useEffect(() => { const getOrCreateCall = async () => { try { - await call?.getOrCreate(); + const members = KnownUsers.map((u) => ({ + user_id: u.id, + })); + await call?.getOrCreate({ + notify: true, + data: { + members, + }, + }); } catch (error) { console.error('Failed to get or create call', error); } diff --git a/sample-apps/react-native/dogfood/src/utils/setPushConfig.ts b/sample-apps/react-native/dogfood/src/utils/setPushConfig.ts index fa9a46cf67..eab28a0436 100644 --- a/sample-apps/react-native/dogfood/src/utils/setPushConfig.ts +++ b/sample-apps/react-native/dogfood/src/utils/setPushConfig.ts @@ -7,6 +7,7 @@ import { staticNavigate } from './staticNavigationUtils'; import { mmkvStorage } from '../contexts/createStoreContext'; import { createToken } from '../modules/helpers/createToken'; import { STREAM_API_KEY } from '../../config'; +import { prontoCallId$ } from '../hooks/useProntoLinkEffect'; export function setPushConfig() { StreamVideoRN.setPushConfig({ @@ -33,6 +34,17 @@ export function setPushConfig() { navigateToIncomingCall: () => { staticNavigate({ name: 'Call', params: undefined }); }, + onTapNonRingingCallNotification: (call_cid) => { + const [callType, callId] = call_cid.split(':'); + if (callType === 'default') { + prontoCallId$.next(callId); // reusing the deeplink logic for non ringing calls s + staticNavigate({ name: 'Meeting', params: undefined }); + } else { + console.error( + `call type: ${callType}, not supported yet in this app!!`, + ); + } + }, }); } diff --git a/yarn.lock b/yarn.lock index b1abc46c9d..65473cfe33 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5177,6 +5177,18 @@ __metadata: languageName: node linkType: hard +"@react-native-community/push-notification-ios@npm:1.11.0, @react-native-community/push-notification-ios@npm:^1.11.0": + version: 1.11.0 + resolution: "@react-native-community/push-notification-ios@npm:1.11.0" + dependencies: + invariant: ^2.2.4 + peerDependencies: + react: ">=16.6.3" + react-native: ">=0.58.4" + checksum: d8c8cdd0d4e8112752a13bf2c426618ec8edd91eacadf03f05375648b5f12ffa761e8676e9d6ac9e5bc5ded73c991ab2219c67fe02e110dfaf38f4cb59695868 + languageName: node + linkType: hard + "@react-native-firebase/app@npm:17.5.0": version: 17.5.0 resolution: "@react-native-firebase/app@npm:17.5.0" @@ -7519,6 +7531,7 @@ __metadata: "@react-native-clipboard/clipboard": ^1.11.1 "@react-native-community/eslint-config": ^3.2.0 "@react-native-community/netinfo": 9.3.10 + "@react-native-community/push-notification-ios": ^1.11.0 "@react-native-firebase/app": 17.5.0 "@react-native-firebase/messaging": 17.5.0 "@react-native-google-signin/google-signin": ^8.2.1 @@ -7553,7 +7566,7 @@ __metadata: react-native-image-resizer: ^1.4.5 react-native-incall-manager: 4.1.0 react-native-mmkv: 2.8.0 - react-native-permissions: ^3.8.0 + react-native-permissions: ^3.9.2 react-native-reanimated: ^3.3.0 react-native-safe-area-context: ^4.4.1 react-native-screens: ^3.18.1 @@ -7576,6 +7589,7 @@ __metadata: "@notifee/react-native": 7.8.0 "@react-native-community/eslint-config": ^3.2.0 "@react-native-community/netinfo": 9.3.9 + "@react-native-community/push-notification-ios": 1.11.0 "@react-native-firebase/app": 17.5.0 "@react-native-firebase/messaging": 17.5.0 "@stream-io/i18n": "workspace:^" @@ -7616,6 +7630,7 @@ __metadata: peerDependencies: "@notifee/react-native": ">=7.8.0" "@react-native-community/netinfo": ">=9.0.0" + "@react-native-community/push-notification-ios": ">=1.11.0" "@react-native-firebase/app": ">=17.5.0" "@react-native-firebase/messaging": ">=17.5.0" "@stream-io/react-native-webrtc": ">=104.0.1" @@ -7630,6 +7645,8 @@ __metadata: react-native-svg: ">=13.6.0" react-native-voip-push-notification: ">=3.3.1" peerDependenciesMeta: + "@react-native-community/push-notification-ios": + optional: true "@react-native-firebase/app": optional: true "@react-native-firebase/messaging": @@ -25583,12 +25600,9 @@ __metadata: languageName: node linkType: hard -"react-native-permissions@npm:^3.8.0": - version: 3.8.0 - resolution: "react-native-permissions@npm:3.8.0" - dependencies: - picocolors: ^1.0.0 - pkg-dir: ^5.0.0 +"react-native-permissions@npm:^3.9.2": + version: 3.9.2 + resolution: "react-native-permissions@npm:3.9.2" peerDependencies: react: ">=16.13.1" react-native: ">=0.63.3" @@ -25596,7 +25610,7 @@ __metadata: peerDependenciesMeta: react-native-windows: optional: true - checksum: acbd8605adabfc48e19fbc468a3a143fb85bd34d3ed0fe6a4b52f16304591b8a4b3c561a507c11643fcc8ce1b4dc09e31f149387d1ea461098a2e40c43989f7c + checksum: 047540958d415e62ea2359f8f5da392a345cec11d7bbe14b065459375b1185431bc98ac144595b9db27376ebb059811f79d9f3c80d61508aeecc3cb5e7c49996 languageName: node linkType: hard