Hey guys, maybe one of you knows what's going on here.
I'm prototyping for desktop and I want to scroll with the mousewheel but it's not working, does anyone know why? Thanks!
Hmm, that's strange. I reproduced the code and it works for me. Is your cursor inside the scroll area?
# My code that works: (Framer Cloud is down...)
scroll = new ScrollComponent
scroll.mouseWheelEnabled = true
scroll.on Events.Scroll, () -> print Utils.randomNumber()
Home = new Layer height: 2000
Home.parent = scroll.content
Anyone knows why this is not working? Thanks!
It seems you’re not using the scroll component correctly and the drag is only working because the flow component gives that behavior for free ( if the element height > screen.height, than is draggable).
Some notes:- When you create the scroll the way you did, you should set the scroll area (which defines where is the scrollable area)- After you set Home as scroll’s child, every time you want to call Home, you should call scroll instead (look how I changed every Home interaction to scroll)- You should set Home’s x position to zero, since its current value is based on Artboard’s position at Design tab, I think.
Here’s a link with the mouse wheel working:https://framer.cloud/rOQDA( You'll probably try new values for some interactions)