jlmakes / jlmakes/scrollreveal
Bugs when page height changes
- Dominant language
- JavaScript
- Stars
- 22.5k
- Forks
- 2.2k
- PR merge metrics
- No merged PRs in 30d
Description
I have found that when the height of a webpage changes, the location of the trigger will change, and even using sync() can cause bugs
This is a normal situation:
https://github.com/jlmakes/scrollreveal/assets/85301126/2bc03cc9-a4cd-4a35-a806-73fe68c4aee3
This is the effect of using `ScrollReveal().sync()`

https://github.com/jlmakes/scrollreveal/assets/85301126/be7983f7-833a-437f-ac20-1846ffd9fc49
I don't know what's wrong. I trigger `ScrollReveal().sync()` when I click collapse panel, but it seems that something's wrong with it
### Environment
* Operating System: Windows 11
* Browser Version: Google Chrome 121.0.6167.189
* ScrollReveal Version: v4.0.9
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reproducing the collapse-panel scenario in Chrome 121 with ScrollReveal v4.0.9, comparing behavior before and after calling ScrollReveal().sync(). Done means trigger locations remain correct when webpage height changes and sync() does not introduce the reported bugs.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100