buzinas / simple-scrollbar

Very simple and lightweight vanilla javascript library for creating a custom scrollbar cross-browser.
MIT License
575 stars 159 forks source link

original scroll is not hidden #28

Closed sidrafarooq closed 6 years ago

sidrafarooq commented 7 years ago

original scroll is also shown with simple-scroll bar how to remove it

Maclay74 commented 6 years ago

This piece of junk just doens't work at all. All thing it do is adds extra padding to ss-container and that's all.

Maclay74 commented 6 years ago

Finally, I fixed it. So if you're a such a good boy and use this "simple" scroll to your body element, the prefer way to make it work is to change css:

.ss-wrapper {
    overflow: hidden;
    width: 100%;
    height: 100%;
    position: relative;
    z-index: 1;
    float: left;
}

.ss-content {
    height: 100%;
    width: calc(100% + 18px);
    position: relative;
    right: 0;
    overflow: auto;
    box-sizing: border-box;
}

Also, you have to make your body is height: 100vh;

team-moonrise commented 6 years ago

Be mindful of your language toward the creator, and use constructive criticism. If you don't like it so much please use something else. :)

Maclay74 commented 6 years ago

So in your own world, providing fix isn't constructive enough?