This works completely fine on desktops:
.container::-webkit-scrollbar {
width: 5px;
}
.container::-webkit-scrollbar-track {
background: none;
}
.container::-webkit-scrollbar-thumb {
background: #f5f5f573;
border-radius: 50px;
visibility: hidden;
}
.container::-webkit-scrollbar-thumb:hover {
background: #555;
}
.container:hover::-webkit-scrollbar-thumb {
visibility: visible;
}
The container
is the container for the color buttons. The problem is that it doesn't disappear on mobile devices. Is there a way that I can make the scrollbar disappear when not scrolling down on mobile devices? And then just reappear when I scroll again?