motion icon indicating copy to clipboard operation
motion copied to clipboard

[BUG] useScroll target does not account for CSS translate

Open tommhuth opened this issue 1 year ago • 0 comments

2. Describe the bug

When target element for useScroll uses translate, the translate is not taken into account when calculating target position. Can't see anything in the docs that should give me the impression that is impossible?

3. IMPORTANT: Provide a CodeSandbox reproduction of the bug (un)comment the translate and the scroll progress is the same, even tho element is closer to screen center:

https://codesandbox.io/p/devbox/hczfww

4. Steps to reproduce

Steps to reproduce the behavior:

  1. see 2.

5. Expected behavior

A clear and concise description of what you expected to happen.

7. Environment details

Nextjs

tommhuth avatar Nov 28 '24 14:11 tommhuth