dillon1000/react
Commit
Browse files Preserve scroll position when restoring focus (#8401)
This misbehavior is particularly egregious because of our current strategy for updating a container in Fiber, but regardless -- if we restore focus to an offscreen node (ex: because it was reordered among its siblings) then we should not scroll the page to reveal it. We could check the `overflow` computed style values before saving the scroll positions but that's unlikely to be any faster.
Changed paths1 file
First-parent comparisonsrc/renderers/dom/shared/ReactInputSelection.js ModifiedPatch
Files changed
Rendering syntax-highlighted changes…