You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 13, 2018. It is now read-only.
I was able to create a hacky work-around that suits my needs. Perhaps it will help other as well.
In your css...
body {
overflow: auto !important;
}
body.noscroll {
position: fixed;
overflow-y: scroll !important;
width: 100%;
}
In your app.js...
window.addEventListener('paper-dropdown-open', function () {
var body = document.querySelector('body');
// If the window's scroll bar would be visible, add the noscroll class.
if (body.scrollHeight > body.clientHeight) {
body.classList.add('noscroll');
}
});
window.addEventListener('paper-dropdown-close', function () {
document.querySelector('body').classList.remove('noscroll');
});
Essentially, the css prevents Polymer from hiding the scroll bars when the dropdown is opened. The javascript and .noscroll class prevent the screen from being scrolled when the dropdown is open, but keep the scrollbar visible.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
When opening a dropdown, the window scrollbar is disappearing.
The paper-dropdown-menu demo shows the issue.
The text was updated successfully, but these errors were encountered: