Describe the bug
When using Lenis#scrollTo
to scroll to an element, the scroll-margin
and/or scroll-padding
properties are ignored, thus making it scroll beyond the desired point.
To Reproduce
This minimal codepen.
Desired Behavior
scroll-margin
and scroll-padding
should be used when determining where to stop scrolling (like the native Element#scrollIntoView
does).
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too