From 3e53a7623850967533d14adac266552fba0c5ead Mon Sep 17 00:00:00 2001 From: Diego Mello Date: Thu, 8 Jul 2021 17:09:46 -0300 Subject: [PATCH] [FIX] Poor performance in messages list on Android 11 (#3260) --- patches/react-native+0.63.4.patch | 55 +++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 patches/react-native+0.63.4.patch diff --git a/patches/react-native+0.63.4.patch b/patches/react-native+0.63.4.patch new file mode 100644 index 000000000..efadfe80b --- /dev/null +++ b/patches/react-native+0.63.4.patch @@ -0,0 +1,55 @@ +diff --git a/node_modules/react-native/Libraries/Components/ScrollView/ScrollView.js b/node_modules/react-native/Libraries/Components/ScrollView/ScrollView.js +index c344ac4..479c8c0 100644 +--- a/node_modules/react-native/Libraries/Components/ScrollView/ScrollView.js ++++ b/node_modules/react-native/Libraries/Components/ScrollView/ScrollView.js +@@ -1244,9 +1244,17 @@ class ScrollView extends React.Component { + // Note: we should split props.style on the inner and outer props + // however, the ScrollView still needs the baseStyle to be scrollable + const {outer, inner} = splitLayoutProps(flattenStyle(props.style)); ++ ++ // Workaround for RefreshControl inverted: https://github.com/facebook/react-native/issues/30034 ++ let inverted; ++ if (inner.scaleY) { ++ inverted = { scaleY: -1 }; ++ delete inner.scaleY; ++ } ++ + return React.cloneElement( + refreshControl, +- {style: [baseStyle, outer]}, ++ {style: [baseStyle, outer, inverted]}, +