Answer the question
In order to leave comments, you need to log in
Why is the modal not scrolling?
Hello !
For some reason, the modal window does not scroll, I will be very grateful if you help ))
When I click on the button, a modal pops up and the .stop-scrolling class is hung on the body.
css body:
.stop-scrolling {
overflow: hidden
}
top: 0;
position: fixed;
z-index: 10000;
width: 100%;
min-height: 110vh;
background-color: #000;
transition: all .25s;
transform: translateX(-4000px);
Answer the question
In order to leave comments, you need to log in
overflow: hidden - hides content outside of the block.
If there is no content, there is nothing to scroll.
The problem with the modal window is that it is inside the body - which hides the extra content.
A modal window scroll may appear if the content inside it is greater than "110vh" (Minimum height is set)
You can also try to hang overflow: scroll on the modal window
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question