Fix issue the scrollbar of an element has been hidden

When the scrollbar of an element has been hidden for some reasons, you cannot swipe the element. The following way will help you fix it.

The first, we have an element like this one:

big content over with wrapper



Add a short piece of CSS code below to scroll-wrapper class:

.scroll-wrapper {
 	width: 1000px;
 	height: 600px;
	overflow-x: auto;
}

.scroll-wrapper::-webkit-scrollbar {
    -webkit-appearance: none;
    height: 7px;
}
.scroll-wrapper::-webkit-scrollbar-thumb {
    border-radius: 4px;
    background-color: rgba(0, 0, 0, .5);
    box-shadow: 0 0 1px rgba(255, 255, 255, .5);
}


In this example, we use the -webkit-scrollbar property to style the scrollbar, make it visibility.

© 2019 4codev

Created with love by Sil.