Answer the question
In order to leave comments, you need to log in
How to make on bootstrap 3 so that when the content scrolls, the left sitebar flies behind me?
Thanks for the help.
How to make it so that when the main content scrolls, the left sitebar also scrolls with me. But on mobile screens, the left sitebar is at the top level, and the content below it, so here it can be a snag that when you scroll the screen, the left sitebar will scroll and thereby cover the main content with its appearance. In theory, on mobile screens, it will have to be fixed at the top so that it does not scroll.
Answer the question
In order to leave comments, you need to log in
Wrap the side bar in some kind of block and make it for the desktop
.side-bar {
position: fixed;
left: 5vw;
width: 25vw;
}
.main-container {
width: 70vw;
}
@media screen and (max-width: 768px) {
.side-bar {
position: relative;
width: 100vw;
}
.main-container {
width: 100vw;
}
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question