From 5b77a460dfa93bc3a13fae83de9bc65efce5e6fc Mon Sep 17 00:00:00 2001 From: MrRefactor Date: Thu, 7 Nov 2024 10:13:29 +0100 Subject: [PATCH 1/2] feat: Bump react-native-pager-view to 6.5.0 --- ios/Podfile.lock | 8 ++++---- package-lock.json | 9 +++++---- package.json | 2 +- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/ios/Podfile.lock b/ios/Podfile.lock index 6494782a6ec0..347d290cb97a 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -1766,7 +1766,7 @@ PODS: - ReactCommon/turbomodule/bridging - ReactCommon/turbomodule/core - Yoga - - react-native-pager-view (6.4.1): + - react-native-pager-view (6.5.0): - DoubleConversion - glog - hermes-engine @@ -1779,7 +1779,7 @@ PODS: - React-featureflags - React-graphics - React-ImageManager - - react-native-pager-view/common (= 6.4.1) + - react-native-pager-view/common (= 6.5.0) - React-NativeModulesApple - React-RCTFabric - React-rendererdebug @@ -1788,7 +1788,7 @@ PODS: - ReactCommon/turbomodule/bridging - ReactCommon/turbomodule/core - Yoga - - react-native-pager-view/common (6.4.1): + - react-native-pager-view/common (6.5.0): - DoubleConversion - glog - hermes-engine @@ -3217,7 +3217,7 @@ SPEC CHECKSUMS: react-native-keyboard-controller: 902c07f41a415b632583b384427a71770a8b02a3 react-native-launch-arguments: 5f41e0abf88a15e3c5309b8875d6fd5ac43df49d react-native-netinfo: fb5112b1fa754975485884ae85a3fb6a684f49d5 - react-native-pager-view: 94195f1bf32e7f78359fa20057c97e632364a08b + react-native-pager-view: c64a744211a46202619a77509f802765d1659dba react-native-pdf: dd6ae39a93607a80919bef9f3499e840c693989d react-native-performance: 3c608307be10964f8a97d3af462f37125b6d8fa5 react-native-plaid-link-sdk: f91a22b45b7c3d4cd6c47273200dc57df35068b0 diff --git a/package-lock.json b/package-lock.json index d5a9815fdf29..7ad752018914 100644 --- a/package-lock.json +++ b/package-lock.json @@ -96,7 +96,7 @@ "react-native-localize": "^2.2.6", "react-native-modal": "^13.0.0", "react-native-onyx": "2.0.73", - "react-native-pager-view": "6.4.1", + "react-native-pager-view": "6.5.0", "react-native-pdf": "6.7.3", "react-native-performance": "^5.1.0", "react-native-permissions": "^3.10.0", @@ -35540,9 +35540,10 @@ } }, "node_modules/react-native-pager-view": { - "version": "6.4.1", - "resolved": "https://registry.npmjs.org/react-native-pager-view/-/react-native-pager-view-6.4.1.tgz", - "integrity": "sha512-HnDxXTRHnR6WJ/vnOitv0C32KG9MJjxLnxswuQlBJmQ7RxF2GWOHSPIRAdZ9fLxdLstV38z9Oz1C95+t+yXkcg==", + "version": "6.5.0", + "resolved": "https://registry.npmjs.org/react-native-pager-view/-/react-native-pager-view-6.5.0.tgz", + "integrity": "sha512-Buqc5mjCgIem7aIQU/seMKqhQr98YvBqRNilnoBb8hNGhCaQTE2yvYDwUhOytowyOkjCstLv7Fap2jcLm/k3Bw==", + "license": "MIT", "peerDependencies": { "react": "*", "react-native": "*" diff --git a/package.json b/package.json index 9c2bad6fdbd7..ae85af0fa85a 100644 --- a/package.json +++ b/package.json @@ -153,7 +153,7 @@ "react-native-localize": "^2.2.6", "react-native-modal": "^13.0.0", "react-native-onyx": "2.0.73", - "react-native-pager-view": "6.4.1", + "react-native-pager-view": "6.5.0", "react-native-pdf": "6.7.3", "react-native-performance": "^5.1.0", "react-native-permissions": "^3.10.0", From f0a34e2f6fa2ebcdcb60b9635f5d477e9bb0a46b Mon Sep 17 00:00:00 2001 From: MrRefactor Date: Thu, 7 Nov 2024 10:13:38 +0100 Subject: [PATCH 2/2] feat: Update patch for react-native-pager-view --- patches/react-native-pager-view+6.4.1.patch | 73 --------------------- patches/react-native-pager-view+6.5.0.patch | 30 +++++++++ 2 files changed, 30 insertions(+), 73 deletions(-) delete mode 100644 patches/react-native-pager-view+6.4.1.patch create mode 100644 patches/react-native-pager-view+6.5.0.patch diff --git a/patches/react-native-pager-view+6.4.1.patch b/patches/react-native-pager-view+6.4.1.patch deleted file mode 100644 index 64b2b580ecd3..000000000000 --- a/patches/react-native-pager-view+6.4.1.patch +++ /dev/null @@ -1,73 +0,0 @@ ---- a/node_modules/react-native-pager-view/ios/Fabric/RNCPagerViewComponentView.mm -+++ b/node_modules/react-native-pager-view/ios/Fabric/RNCPagerViewComponentView.mm -@@ -195,13 +195,10 @@ -(void)scrollViewDidScroll:(UIScrollView *)scrollView { - - strongEventEmitter.onPageScroll(RNCViewPagerEventEmitter::OnPageScroll{.position = static_cast(position), .offset = offset}); - -- //This is temporary workaround to allow animations based on onPageScroll event -- //until Fabric implements proper NativeAnimationDriver -- RCTBridge *bridge = [RCTBridge currentBridge]; -- -- if (bridge) { -- [bridge.eventDispatcher sendEvent:[[RCTOnPageScrollEvent alloc] initWithReactTag:[NSNumber numberWithInt:self.tag] position:@(position) offset:@(offset)]]; -- } -+ NSDictionary *userInfo = [NSDictionary dictionaryWithObjectsAndKeys:[[RCTOnPageScrollEvent alloc] initWithReactTag:[NSNumber numberWithInt:self.tag] position:@(position) offset:@(offset)], @"event", nil]; -+ [[NSNotificationCenter defaultCenter] postNotificationName:@"RCTNotifyEventDispatcherObserversOfEvent_DEPRECATED" -+ object:nil -+ userInfo:userInfo]; - } - - #pragma mark - Internal methods -diff --git a/node_modules/react-native-pager-view/ios/LEGACY/Fabric/LEGACY_RNCPagerViewComponentView.mm b/node_modules/react-native-pager-view/ios/LEGACY/Fabric/LEGACY_RNCPagerViewComponentView.mm -index 7608645..84f6f60 100644 ---- a/node_modules/react-native-pager-view/ios/LEGACY/Fabric/LEGACY_RNCPagerViewComponentView.mm -+++ b/node_modules/react-native-pager-view/ios/LEGACY/Fabric/LEGACY_RNCPagerViewComponentView.mm -@@ -363,14 +363,10 @@ - (void)scrollViewDidScroll:(UIScrollView *)scrollView { - int eventPosition = (int) position; - strongEventEmitter.onPageScroll(LEGACY_RNCViewPagerEventEmitter::OnPageScroll{.position = static_cast(eventPosition), .offset = interpolatedOffset}); - -- //This is temporary workaround to allow animations based on onPageScroll event -- //until Fabric implements proper NativeAnimationDriver -- RCTBridge *bridge = [RCTBridge currentBridge]; -- -- if (bridge) { -- [bridge.eventDispatcher sendEvent:[[RCTOnPageScrollEvent alloc] initWithReactTag:[NSNumber numberWithInt:self.tag] position:@(position) offset:@(interpolatedOffset)]]; -- } -- -+ NSDictionary *userInfo = [NSDictionary dictionaryWithObjectsAndKeys:[[RCTOnPageScrollEvent alloc] initWithReactTag:[NSNumber numberWithInt:self.tag] position:@(position) offset:@(interpolatedOffset)], @"event", nil]; -+ [[NSNotificationCenter defaultCenter] postNotificationName:@"RCTNotifyEventDispatcherObserversOfEvent_DEPRECATED" -+ object:nil -+ userInfo:userInfo]; - } - - -diff --git a/node_modules/react-native-pager-view/ios/LEGACY/LEGACY_RNCPagerView.m b/node_modules/react-native-pager-view/ios/LEGACY/LEGACY_RNCPagerView.m -index 5f6c535..fd6c2a1 100644 ---- a/node_modules/react-native-pager-view/ios/LEGACY/LEGACY_RNCPagerView.m -+++ b/node_modules/react-native-pager-view/ios/LEGACY/LEGACY_RNCPagerView.m -@@ -1,5 +1,5 @@ - #import "LEGACY_RNCPagerView.h" --#import "React/RCTLog.h" -+#import - #import - - #import "UIViewController+CreateExtension.h" -diff --git a/node_modules/react-native-pager-view/ios/RNCPagerView.m b/node_modules/react-native-pager-view/ios/RNCPagerView.m -index 584aada..978496f 100644 ---- a/node_modules/react-native-pager-view/ios/RNCPagerView.m -+++ b/node_modules/react-native-pager-view/ios/RNCPagerView.m -@@ -1,12 +1,12 @@ - - #import "RNCPagerView.h" --#import "React/RCTLog.h" -+#import - #import - - #import "UIViewController+CreateExtension.h" - #import "RCTOnPageScrollEvent.h" - #import "RCTOnPageScrollStateChanged.h" --#import "React/RCTUIManagerObserverCoordinator.h" -+#import - #import "RCTOnPageSelected.h" - #import - diff --git a/patches/react-native-pager-view+6.5.0.patch b/patches/react-native-pager-view+6.5.0.patch new file mode 100644 index 000000000000..8488bf9c586e --- /dev/null +++ b/patches/react-native-pager-view+6.5.0.patch @@ -0,0 +1,30 @@ +diff --git a/node_modules/react-native-pager-view/ios/LEGACY/LEGACY_RNCPagerView.m b/node_modules/react-native-pager-view/ios/LEGACY/LEGACY_RNCPagerView.m +index 5f6c535..fd6c2a1 100644 +--- a/node_modules/react-native-pager-view/ios/LEGACY/LEGACY_RNCPagerView.m ++++ b/node_modules/react-native-pager-view/ios/LEGACY/LEGACY_RNCPagerView.m +@@ -1,5 +1,5 @@ + #import "LEGACY_RNCPagerView.h" +-#import "React/RCTLog.h" ++#import + #import + + #import "UIViewController+CreateExtension.h" +diff --git a/node_modules/react-native-pager-view/ios/RNCPagerView.m b/node_modules/react-native-pager-view/ios/RNCPagerView.m +index 584aada..978496f 100644 +--- a/node_modules/react-native-pager-view/ios/RNCPagerView.m ++++ b/node_modules/react-native-pager-view/ios/RNCPagerView.m +@@ -1,12 +1,12 @@ + + #import "RNCPagerView.h" +-#import "React/RCTLog.h" ++#import + #import + + #import "UIViewController+CreateExtension.h" + #import "RCTOnPageScrollEvent.h" + #import "RCTOnPageScrollStateChanged.h" +-#import "React/RCTUIManagerObserverCoordinator.h" ++#import + #import "RCTOnPageSelected.h" + #import +