dillon1000/react
Commit
Browse files [DOM] Scroll to text siblings of empty Fragments instead of the parent (#37060)
When a Fragment has no children, React would consider scrolling to siblings first and then to parents. However, React only considered `HostComponent` for the siblings. Since we already have a heuristic for scrolling to `HostText`, we can reuse that same heuristic. --------- Co-authored-by: Claude Fable 5 <[email protected]>
Changed paths5 files
First-parent comparisonpackages/react-dom-bindings/src/client/ReactFiberConfigDOM.js ModifiedM packages/react-dom/src/__tests__/ReactDOMFragmentRefs-test.js ModifiedM packages/react-native-renderer/src/ReactFiberConfigFabric.js ModifiedM packages/react-reconciler/src/ReactFiberTreeReflection.js ModifiedM packages/shared/ReactDOMFragmentRefShared.js ModifiedPatch
Files changed
Rendering syntax-highlighted changes…