I can’t seem to figure this one out. I tried using Waldo’s tutorial and still, no luck. Much of it I just don’t understand (custom code, switching classes etc.) so here I am.
Anyways, I’ve set up a modal and I need to make it scrollable on small screens. I’ve set an interaction on itemWork and that works fine. Closing the modal also works fine. However, when I check the modal on smaller screens:
I can’t see a big chunk of the content.
Modal is scrollable, but everything else behind the modal is also scrollable.
Any help with what am I doing wrong?
Also, don’t mind other popups, just modalContainer one as I need to clean up those too.
Firstly, Epic design! That header photo is amazing.
This is a known issue with webfow modals, and based on a support ticket I had on this it is somewhere on webflow’s roadmap.
The solution is to use javascript.
Basically, you need to watch for when your modal is open with javascript, and then set the overflow for the <body> element to overflow-hidden whenever your modal is open.
It is pretty late here but in the morrow I’m happy to work through the solution I used if you like.
Here’s what’s happening on mobile: https://www.dropbox.com/s/41gi5daxzqzykw6/Kapture%202018-11-14%20at%2018.12.53.mp4?dl=0
I can scroll stuff outside modal and the top of the content is cut out for some reason.
What I wanna do is make it scrollable, then prevent stuff outside (or behind it) to scroll and all content inside the modal visible. How does one do all that?
This is what I’m trying to achieve (took a screenshot so I could showcase exactly what I’m trying to do, nevermind the X icon): https://www.dropbox.com/s/arg03v3c9baenk6/Kapture%202018-11-14%20at%2018.39.28.mp4?dl=0
Hi Guys I think the issue is, even if a modal is created and overflow styled correctly, and scrolls as expected, the background (body) scrolls behind the modal – It usually happens once you scroll and the modal and reach the end of it’s content, the background starts scrolling.
Unfortunately this can’t be fixed without custom code.
Hey folks, I managed to do what I wanted, but it involved custom code and a lotta thinking haha. I went back to the start and this is what I did.
This is my structure:
1. modal (with combo-class that controls z-index only cause I wanna do interaction on other popups too… visibility goes to display: hidden when I wanna hide it to see everything else, ofcourse):