Skip to content

Commit 48cf935

Browse files
committed
fix: try something else
1 parent f4fd4a9 commit 48cf935

File tree

6 files changed

+46
-86
lines changed

6 files changed

+46
-86
lines changed

examples/SampleApp/App.tsx

Lines changed: 43 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -74,49 +74,49 @@ const App = () => {
7474
const colorScheme = useColorScheme();
7575
// const streamChatTheme = useStreamChatTheme();
7676

77-
useEffect(() => {
78-
const messaging = getMessaging();
79-
const unsubscribeOnNotificationOpen = messaging.onNotificationOpenedApp((remoteMessage) => {
80-
// Notification caused app to open from background state on iOS
81-
const channelId = remoteMessage.data?.channel_id as string;
82-
if (channelId) {
83-
navigateToChannel(channelId);
84-
}
85-
});
86-
// handle notification clicks on foreground
87-
const unsubscribeForegroundEvent = notifee.onForegroundEvent(({ detail, type }) => {
88-
if (type === EventType.PRESS) {
89-
// user has pressed the foreground notification
90-
const channelId = detail.notification?.data?.channel_id as string;
91-
if (channelId) {
92-
navigateToChannel(channelId);
93-
}
94-
}
95-
});
96-
notifee.getInitialNotification().then((initialNotification) => {
97-
if (initialNotification) {
98-
// Notification caused app to open from quit state on Android
99-
const channelId = initialNotification.notification.data?.channel_id as string;
100-
if (channelId) {
101-
initialChannelIdGlobalRef.current = channelId;
102-
}
103-
}
104-
});
105-
messaging.getInitialNotification().then((remoteMessage) => {
106-
if (remoteMessage) {
107-
// Notification caused app to open from quit state on iOS
108-
const channelId = remoteMessage.data?.channel_id as string;
109-
if (channelId) {
110-
// this will make the app to start with the channel screen with this channel id
111-
initialChannelIdGlobalRef.current = channelId;
112-
}
113-
}
114-
});
115-
return () => {
116-
unsubscribeOnNotificationOpen();
117-
unsubscribeForegroundEvent();
118-
};
119-
}, []);
77+
// useEffect(() => {
78+
// const messaging = getMessaging();
79+
// const unsubscribeOnNotificationOpen = messaging.onNotificationOpenedApp((remoteMessage) => {
80+
// // Notification caused app to open from background state on iOS
81+
// const channelId = remoteMessage.data?.channel_id as string;
82+
// if (channelId) {
83+
// navigateToChannel(channelId);
84+
// }
85+
// });
86+
// // handle notification clicks on foreground
87+
// const unsubscribeForegroundEvent = notifee.onForegroundEvent(({ detail, type }) => {
88+
// if (type === EventType.PRESS) {
89+
// // user has pressed the foreground notification
90+
// const channelId = detail.notification?.data?.channel_id as string;
91+
// if (channelId) {
92+
// navigateToChannel(channelId);
93+
// }
94+
// }
95+
// });
96+
// notifee.getInitialNotification().then((initialNotification) => {
97+
// if (initialNotification) {
98+
// // Notification caused app to open from quit state on Android
99+
// const channelId = initialNotification.notification.data?.channel_id as string;
100+
// if (channelId) {
101+
// initialChannelIdGlobalRef.current = channelId;
102+
// }
103+
// }
104+
// });
105+
// messaging.getInitialNotification().then((remoteMessage) => {
106+
// if (remoteMessage) {
107+
// // Notification caused app to open from quit state on iOS
108+
// const channelId = remoteMessage.data?.channel_id as string;
109+
// if (channelId) {
110+
// // this will make the app to start with the channel screen with this channel id
111+
// initialChannelIdGlobalRef.current = channelId;
112+
// }
113+
// }
114+
// });
115+
// return () => {
116+
// unsubscribeOnNotificationOpen();
117+
// unsubscribeForegroundEvent();
118+
// };
119+
// }, []);
120120

121121
return (
122122
<SafeAreaProvider
@@ -177,7 +177,6 @@ const DrawerNavigatorWrapper: React.FC<{
177177
<OverlayProvider bottomInset={bottom} value={{ style: streamChatTheme }}>
178178
<Chat
179179
client={chatClient}
180-
enableOfflineSupport
181180
// @ts-expect-error - the `ImageComponent` prop is generic, meaning we can expect an error
182181
ImageComponent={FastImage}
183182
isMessageAIGenerated={isMessageAIGenerated}

examples/SampleApp/index.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
1-
import 'react-native-gesture-handler';
21
import { AppRegistry } from 'react-native';
3-
import { enableScreens } from 'react-native-screens';
42

53
import App from './App';
64
import { name as appName } from './app.json';
75

8-
enableScreens();
96
AppRegistry.registerComponent(appName, () => App);

examples/SampleApp/ios/Podfile.lock

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -155,32 +155,6 @@ PODS:
155155
- nanopb/encode (= 3.30910.0)
156156
- nanopb/decode (3.30910.0)
157157
- nanopb/encode (3.30910.0)
158-
- op-sqlite (14.0.4):
159-
- DoubleConversion
160-
- glog
161-
- hermes-engine
162-
- RCT-Folly (= 2024.11.18.00)
163-
- RCTRequired
164-
- RCTTypeSafety
165-
- React
166-
- React-callinvoker
167-
- React-Core
168-
- React-debug
169-
- React-Fabric
170-
- React-featureflags
171-
- React-graphics
172-
- React-hermes
173-
- React-ImageManager
174-
- React-jsi
175-
- React-NativeModulesApple
176-
- React-RCTFabric
177-
- React-renderercss
178-
- React-rendererdebug
179-
- React-utils
180-
- ReactCodegen
181-
- ReactCommon/turbomodule/bridging
182-
- ReactCommon/turbomodule/core
183-
- Yoga
184158
- PromisesObjC (2.4.0)
185159
- PromisesSwift (2.4.0):
186160
- PromisesObjC (= 2.4.0)
@@ -2463,7 +2437,6 @@ DEPENDENCIES:
24632437
- fmt (from `../node_modules/react-native/third-party-podspecs/fmt.podspec`)
24642438
- glog (from `../node_modules/react-native/third-party-podspecs/glog.podspec`)
24652439
- hermes-engine (from `../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec`)
2466-
- "op-sqlite (from `../node_modules/@op-engineering/op-sqlite`)"
24672440
- RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`)
24682441
- RCT-Folly/Fabric (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`)
24692442
- RCTDeprecation (from `../node_modules/react-native/ReactApple/Libraries/RCTFoundation/RCTDeprecation`)
@@ -2591,8 +2564,6 @@ EXTERNAL SOURCES:
25912564
hermes-engine:
25922565
:podspec: "../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec"
25932566
:tag: hermes-2025-06-04-RNv0.79.3-7f9a871eefeb2c3852365ee80f0b6733ec12ac3b
2594-
op-sqlite:
2595-
:path: "../node_modules/@op-engineering/op-sqlite"
25962567
RCT-Folly:
25972568
:podspec: "../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec"
25982569
RCTDeprecation:
@@ -2784,7 +2755,6 @@ SPEC CHECKSUMS:
27842755
hermes-engine: 94ed01537bdeccaab1adbf94b040d115d6fa1a7f
27852756
libwebp: 02b23773aedb6ff1fd38cec7a77b81414c6842a8
27862757
nanopb: fad817b59e0457d11a5dfbde799381cd727c1275
2787-
op-sqlite: 6a5255f36253697406618ceba5212d6572012a9d
27882758
PromisesObjC: f5707f49cb48b9636751c5b2e7d227e43fba9f47
27892759
PromisesSwift: 9d77319bbe72ebf6d872900551f7eeba9bce2851
27902760
RCT-Folly: 36fe2295e44b10d831836cc0d1daec5f8abcf809

examples/SampleApp/ios/SampleApp.xcodeproj/project.pbxproj

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -532,8 +532,8 @@
532532
ASSETCATALOG_COMPILER_INCLUDE_ALL_APPICON_ASSETS = NO;
533533
CLANG_ENABLE_MODULES = YES;
534534
CODE_SIGN_ENTITLEMENTS = SampleApp/SampleAppRelease.entitlements;
535-
CODE_SIGN_IDENTITY = "Apple Development";
536-
CODE_SIGN_STYLE = Automatic;
535+
CODE_SIGN_IDENTITY = "iPhone Distribution";
536+
CODE_SIGN_STYLE = Manual;
537537
CURRENT_PROJECT_VERSION = 149;
538538
DEVELOPMENT_TEAM = EHV7XZLAHA;
539539
INFOPLIST_FILE = SampleApp/Info.plist;
@@ -548,7 +548,7 @@
548548
);
549549
PRODUCT_BUNDLE_IDENTIFIER = io.getstream.reactnative.SampleApp;
550550
PRODUCT_NAME = SampleApp;
551-
PROVISIONING_PROFILE_SPECIFIER = "";
551+
PROVISIONING_PROFILE_SPECIFIER = "match AdHoc io.getstream.reactnative.SampleApp";
552552
SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
553553
SUPPORTS_MACCATALYST = NO;
554554
SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO;

examples/SampleApp/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@
2424
},
2525
"dependencies": {
2626
"@notifee/react-native": "^9.1.8",
27-
"@op-engineering/op-sqlite": "^14.0.3",
2827
"@react-native-async-storage/async-storage": "^2.2.0",
2928
"@react-native-camera-roll/camera-roll": "^7.10.0",
3029
"@react-native-community/netinfo": "^11.4.1",

examples/SampleApp/yarn.lock

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1876,11 +1876,6 @@
18761876
resolved "https://registry.yarnpkg.com/@notifee/react-native/-/react-native-9.1.8.tgz#3d55cb3fbcc21f9e35931e366afdf64b294da891"
18771877
integrity sha512-Az/dueoPerJsbbjRxu8a558wKY+gONUrfoy3Hs++5OqbeMsR0dYe6P+4oN6twrLFyzAhEA1tEoZRvQTFDRmvQg==
18781878

1879-
"@op-engineering/op-sqlite@^14.0.3":
1880-
version "14.0.4"
1881-
resolved "https://registry.yarnpkg.com/@op-engineering/op-sqlite/-/op-sqlite-14.0.4.tgz#a86951f98e65be2f66d3f17d5bc27796d614e023"
1882-
integrity sha512-WNWsEY+ZLbOUJ6EuhB4vGqE+99NTJJkdwW+7XKdg8lN7QMnbsM7z7LGWQ9Cqp5JKvWwItBpjaxlHB2wbywsSJA==
1883-
18841879
"@pkgjs/parseargs@^0.11.0":
18851880
version "0.11.0"
18861881
resolved "https://registry.yarnpkg.com/@pkgjs/parseargs/-/parseargs-0.11.0.tgz#a77ea742fab25775145434eb1d2328cf5013ac33"

0 commit comments

Comments
 (0)