I am facing an issue with my webpage design. I have 3 blocks, the second block contains a scrolling circle that moves along with the main scroll. However, when the main scroll crosses the second block, the circle behaves incorrectly and stops scrolling on the page.
Is there a way to modify the script so that when the main scroll crosses block2
, the circle automatically sticks to the last case and stops scrolling altogether? And then resumes functioning when we scroll back up past block2
.
The main problem arises when the scroll reaches the last case, as the circle does not move further. I need the scroll to smoothly reach the end of block2
, and when the scroll halts, the circle should stick to the center of the nearest case.
In my current implementation, although the circle sticks to the correct position when the scroll stops, it does not scroll correctly to the end for me.