chris posted 3 months ago
Very cool website, really like the creativity behind everything you're doing.
Regarding your issue with the balls not expanding, my first thought is that it's due to the offset of the canvas relative to the window's scroll position. Whenever you add a canvas to a page that requires scrolling and interaction, you have to subtract the window's scroll position and or the canvas' offset from the top of the window, from your
mousemove event listener's
So wherever you're setting
clientY you need to subtract from it, the canvas' offset which you can obtain with
getBoundingClientRect().top, then also subtract the window's scroll which you can get with
window.scrollY. Think you should be good after that, let me know if that helps!