-
Notifications
You must be signed in to change notification settings - Fork 767
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make scroll lock optional #155
Comments
|
So, it takes this to change the behavior: body {
padding-right: 0 !important;
|
.html.remodal-is-locked, body.remodal-is-locked {
overflow: auto;
} |
Hi! Remodal is awesome. On a side note, I put it together with https://github.com/aFarkas/lazysizes and it works flawlessly. I am struggling with the same behaviour (jumping when lock screen is on, cf. #50 as well). The fix works, but it messes up our layout. I can simply hack the script and turn off As getScrollbarWidth() is already doing some work, would it be possible to somehow avoid that jump there? Maybe by adding some more padding of the width of another scrollbar? I've tried messing with the |
Why is 'padding-right' not working for you? |
Another reason, why it does not work for you, can be this line of the code: https://github.com/VodkaBears/Remodal/blob/master/src/remodal.js#L196. I think, it is more correclty to compare |
|
Hi, I'm sorry, I lost a little track of the issue. I couldn't answer the question why padding-right wasn't working. But it's not doing the job for me. While uncommenting |
It would be nice if locking scrolling was optional. The problem is, though I can override it with CSS, I can't prevent remodal from adding padding to content element. Or is there a way?
Remodal works well this way, and I am pretty fine with background scrollable.
The text was updated successfully, but these errors were encountered: