[Bug]: Seeking within player doesn't correctly handle scrolling
richard-misiak-az opened this issue · comments
Preflight Checklist
- I have searched the issue tracker for a bug report that matches the one I want to file, without success.
What package is this bug report for?
rrweb
Version
2.0.0-alpha.13
Expected Behavior
When seeking within the player for events that include page scrolling the replay should work correctly when seeking
Actual Behavior
When seeking through events that include scrolling the scrolling does not appear to be correctly reset meaning that the elements in the replay are now out of sync with the viewport position
Steps to Reproduce
- Go to the testcase below, it includes some interaction with fields and scrolling
- Let the events play
- using the player controls jump to ~4s
- jump back to ~1s
- resume the player
However while seeking the scroll events aren't undone meaning the viewport is in the wrong position on the page meaning you see this instead:
Testcase Gist URL
Additional Information
No response
I've done some further testing with the debugger and 0.7.14 (rrweb v1.1.3) does not have this issue, but all later alpha versions do so I guess it's related to the rewrite of the replayer logic
Still present as of alpha 15