Merge pull request #31 from KevinMidboe/fix/restrictive-background-scroll

Disable scroll on content behind popover movie view
This commit is contained in:
2019-10-30 22:12:44 +01:00
committed by GitHub
2 changed files with 6 additions and 0 deletions

View File

@@ -123,6 +123,10 @@ img{
height: auto;
}
.no-scroll {
overflow: hidden;
}
.wrapper{
position: relative;
}

View File

@@ -32,9 +32,11 @@ export default {
},
created(){
window.addEventListener('keyup', this.checkEventForEscapeKey)
document.getElementsByTagName("body")[0].classList += " no-scroll";
},
beforeDestroy() {
window.removeEventListener('keyup', this.checkEventForEscapeKey)
document.getElementsByTagName("body")[0].classList.remove("no-scroll");
}
}