Remove the scrollIntoView function#20953
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #20953 +/- ##
==========================================
+ Coverage 62.51% 62.55% +0.03%
==========================================
Files 172 172
Lines 121789 121789
==========================================
+ Hits 76134 76180 +46
+ Misses 45655 45609 -46
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Yep I tested with pdf.pdf which has outlines. |
Testing that one now, it seems that it has the same problem with incorrect offsets even when clicking the destinations in the outline. I believe that the old |
and rely on the HTMLElement.scrollIntoView function instead.
9ea7c0f to
e87b9c5
Compare
| scrollIntoView(div, pageSpot); | ||
|
|
||
| div.scrollIntoView({ | ||
| behavior: "auto", |
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
| width: 816px; | ||
| height: 1056px; | ||
| margin: var(--page-margin); | ||
| margin-inline: auto; |
There was a problem hiding this comment.
Should this not have a value around 10px (via a new CSS variable), to mimic the effect of the old page-border rule?
Likely related to this is that pages in spreadMode, or when using the horizontal and wrapped scrollModes, no longer have any horizontal space between them.


and rely on the HTMLElement.scrollIntoView function instead.