Currently, I am working on a website that features a scroll loop effect, where reaching the bottom of the page seamlessly jumps back to the top, creating an infinite loop. My challenge lies in implementing an effect to rotate individual divs based on their offsetTop.
You can view the rotation effect without the scroll loop here: https://jsfiddle.net/jacob_truax/bgrkewny/3/
If you want to see both effects together, check out this link: https://jsfiddle.net/jacob_truax/b1x4dow7/18/
The code breaks when combining the scroll loop effect with the rotation effect. Can anyone assist me in resolving this issue?
Below is the JavaScript code for the faulty fiddle:
...
And here is the CSS code used:
...