A framework for building native applications using React
Fix inverted `contentOffset` in scroll events in RTL (#39031)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/39031 `UIScrollView` `contentOffset` is flow-relative, so `x` is relative to the right edge of the screen. This coordinate space disagrees with layout events, `scrollTo` coordinates, and other platforms. This applies the same logic we use for inverting `scrollTo` coordinates to invert `contentOffset` in scroll events, in both Paper and Fabric. We then remove the iOS specific workaround we have in VirtualizedList. I did not test `contentInset` as part of this, whose structure has explicit edges like `left` and `right`. Changelog: [iOS][Fixed] - Fix inverted `contentOffset` in scroll events in RTL Reviewed By: rozele Differential Revision: D48379915 fbshipit-source-id: 8a9cbb01608e79ef3b179a76fbe3997a0cd23845
N
Nick Gerleman committed
4f8a8ce316494db99b19f6c8db6b0c1e7b6500d9
Parent: 1456592
Committed by Facebook GitHub Bot <[email protected]>
on 8/22/2023, 1:03:43 AM