dillon1000/react

Commit

[DevTools] Synchronize Scroll Position Between Suspense Tab and Main Document (#34641)

It's annoying to have to try to find where it lines up with no hints.

This way when you hover over something it should be on screen.

The strategy I went with is that it scrolls to a percentage along the
scrollable axis but the two might not be exactly the same. Partially
because they have different aspect ratios but also because suspended
boundaries can shrink the document while the suspense tab needs to still
be able to show the boundaries that are currently invisible.
Browse files
Changed paths5 files
First-parent comparison
M packages/react-devtools-shared/src/__tests__/bridge-test.js ModifiedM packages/react-devtools-shared/src/backend/views/Highlighter/index.js ModifiedM packages/react-devtools-shared/src/bridge.js ModifiedM packages/react-devtools-shared/src/devtools/views/SuspenseTab/SuspenseRects.js ModifiedM packages/react-devtools-shared/src/devtools/views/SuspenseTab/SuspenseTab.js Modified
Patch

Files changed

Rendering syntax-highlighted changes…