diff --git a/packages/react-native/ReactCommon/react/renderer/components/scrollview/ScrollViewShadowNode.cpp b/packages/react-native/ReactCommon/react/renderer/components/scrollview/ScrollViewShadowNode.cpp index 7e41ba7b83082a..c098ba02fd4e5f 100644 --- a/packages/react-native/ReactCommon/react/renderer/components/scrollview/ScrollViewShadowNode.cpp +++ b/packages/react-native/ReactCommon/react/renderer/components/scrollview/ScrollViewShadowNode.cpp @@ -64,10 +64,12 @@ void ScrollViewShadowNode::layout(LayoutContext layoutContext) { } Point ScrollViewShadowNode::getContentOriginOffset( - bool /* includeTransform */) const { - + bool includeTransform) const { auto stateData = getStateData(); auto contentOffset = stateData.contentOffset; - return {-contentOffset.x, -contentOffset.y + stateData.scrollAwayPaddingTop}; + auto transform = includeTransform ? getTransform() : Transform::Identity(); + auto result = transform * Vector{-contentOffset.x, -contentOffset.y, 0, 1}; + + return {result.x, result.y + stateData.scrollAwayPaddingTop}; } } // namespace facebook::react diff --git a/packages/react-native/ReactCommon/react/renderer/core/LayoutableShadowNode.cpp b/packages/react-native/ReactCommon/react/renderer/core/LayoutableShadowNode.cpp index cef90f40b6923c..524c113c68a02f 100644 --- a/packages/react-native/ReactCommon/react/renderer/core/LayoutableShadowNode.cpp +++ b/packages/react-native/ReactCommon/react/renderer/core/LayoutableShadowNode.cpp @@ -193,7 +193,7 @@ Transform LayoutableShadowNode::getTransform() const { } Point LayoutableShadowNode::getContentOriginOffset( - bool /*includeTransform*/) const { + bool includeTransform) const { return {0, 0}; }