Hi there I want to Hide scroll bar only from the toggle menu of my website https://themensoutfitclub.com , i used this css
html {
overflow: scroll;
overflow-x: hidden;
}
::-webkit-scrollbar {
width: 0; /* Remove scrollbar space */
background: transparent; /* Optional: just make scrollbar invisible */
}
/* Optional: show position indicator in red */
::-webkit-scrollbar-thumb {
background: #FF0000;
}
screenshot, When clicked on product subcategorybut it removes the desktops default right side bar as well hence making it impossible to scroll without a mouse. I have removed the code now plz help.
Let's suppose your toggle menu class name is toggle-menu. Then you should style like this
.toggle-menu::-webkit-scrollbar {
display: none; /* Safari and Chrome */
}
Note that, above code only work for chrome and safari. For mozilla and IE10+ use this
.toggle-menu {
-ms-overflow-style: none; /* Internet Explorer 10+ */
scrollbar-width: none; /* Firefox */
}
So, the whole code should be like this:
.toggle-menu {
-ms-overflow-style: none; /* Internet Explorer 10+ */
scrollbar-width: none; /* Firefox */
}
.toggle-menu::-webkit-scrollbar {
display: none; /* Safari and Chrome */
}