Skip to content

Commit 85cc873

Browse files
committed
Remove PushNotificationIOS
# Conflicts: # packages/react-native/Libraries/PushNotificationIOS/PushNotificationIOS.js # packages/react-native/Libraries/PushNotificationIOS/RCTPushNotificationManager.mm # packages/react-native/ReactNativeApi.d.ts
1 parent edf2b86 commit 85cc873

33 files changed

Lines changed: 18 additions & 2724 deletions

File tree

‎packages/eslint-plugin-react-native/utils.js‎

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -403,10 +403,6 @@ const publicAPIMapping = {
403403
default: 'usePressability',
404404
types: null,
405405
},
406-
'Libraries/PushNotificationIOS/PushNotificationIOS': {
407-
default: 'PushNotificationIOS',
408-
types: ['PushNotificationEventName', 'PushNotificationPermissions'],
409-
},
410406
'Libraries/ReactNative/AppRegistry': {
411407
default: null,
412408
types: [

‎packages/jest-preset/jest/mocks/NativeModules.js‎

Lines changed: 0 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -135,49 +135,6 @@ const NativeModules = {
135135
};
136136
},
137137
},
138-
PushNotificationManager: {
139-
presentLocalNotification: jest.fn() as JestMockFn<$FlowFixMe, $FlowFixMe>,
140-
scheduleLocalNotification: jest.fn() as JestMockFn<$FlowFixMe, $FlowFixMe>,
141-
cancelAllLocalNotifications: jest.fn() as JestMockFn<
142-
$FlowFixMe,
143-
$FlowFixMe,
144-
>,
145-
removeAllDeliveredNotifications: jest.fn() as JestMockFn<
146-
$FlowFixMe,
147-
$FlowFixMe,
148-
>,
149-
getDeliveredNotifications: jest.fn(callback =>
150-
process.nextTick(() => []),
151-
) as JestMockFn<$FlowFixMe, $FlowFixMe>,
152-
removeDeliveredNotifications: jest.fn() as JestMockFn<
153-
$FlowFixMe,
154-
$FlowFixMe,
155-
>,
156-
setApplicationIconBadgeNumber: jest.fn() as JestMockFn<
157-
$FlowFixMe,
158-
$FlowFixMe,
159-
>,
160-
getApplicationIconBadgeNumber: jest.fn(callback =>
161-
process.nextTick(() => callback(0)),
162-
) as JestMockFn<$FlowFixMe, $FlowFixMe>,
163-
cancelLocalNotifications: jest.fn() as JestMockFn<$FlowFixMe, $FlowFixMe>,
164-
getScheduledLocalNotifications: jest.fn(callback =>
165-
process.nextTick(() => callback()),
166-
) as JestMockFn<$FlowFixMe, $FlowFixMe>,
167-
requestPermissions: jest.fn(() =>
168-
Promise.resolve({alert: true, badge: true, sound: true}),
169-
) as JestMockFn<$FlowFixMe, $FlowFixMe>,
170-
abandonPermissions: jest.fn() as JestMockFn<$FlowFixMe, $FlowFixMe>,
171-
checkPermissions: jest.fn(callback =>
172-
process.nextTick(() => callback({alert: true, badge: true, sound: true})),
173-
) as JestMockFn<$FlowFixMe, $FlowFixMe>,
174-
getInitialNotification: jest.fn(() => Promise.resolve(null)) as JestMockFn<
175-
$FlowFixMe,
176-
$FlowFixMe,
177-
>,
178-
addListener: jest.fn() as JestMockFn<$FlowFixMe, $FlowFixMe>,
179-
removeListeners: jest.fn() as JestMockFn<$FlowFixMe, $FlowFixMe>,
180-
},
181138
SourceCode: {
182139
getConstants(): $FlowFixMe {
183140
return {

‎packages/react-native-babel-preset/src/configs/lazy-imports.js‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,6 @@ module.exports = new Set([
7171
'PanResponder',
7272
'PermissionsAndroid',
7373
'PixelRatio',
74-
'PushNotificationIOS',
7574
'Settings',
7675
'Share',
7776
'StyleSheet',

‎packages/react-native/Libraries/PushNotificationIOS/NativePushNotificationManagerIOS.js‎

Lines changed: 0 additions & 14 deletions
This file was deleted.

0 commit comments

Comments
 (0)