Hide scroll-bar when overflow-scroll="true"?


#1

Hello guys,

Without using overflow-scroll=“true”, I can hide the scroll-bar by using css:

.scroll-bar-indicator {
    display: none !important;
}

But the above code doesn’t work when overflow-scroll="true" is used in ion-content, so is there a way to hide the y-axis scroll-bar when using overflow-scroll=“true”?

I tested the code on chrome browser and Nexus 5 (crosswalk + cordova). Thanks


#2

Anyone has some solution?


#3

try this css:

// remove scrollbar while using overflow-scroll="true"

::-webkit-scrollbar,
*::-webkit-scrollbar {
    display: none;
}

#4

Works perfect! Thanks Halo


#5

Hi,

I am using Ionic 3, and in my webbrowser the scrollbars will still show for all devices in my ionic-lab.

Will they hide on the mobile version?

Thanks in advance!


#6

to hide this one will help you.

::-webkit-scrollbar,
*::-webkit-scrollbar {
display: none;
}