Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Have the vertical scroll bar always present css

Tags:

javascript

css

I have a web page with infinite scrolling. I always want to have the vertical scrollbar present so I have added the following style:

html {  
  overflow-y: scroll;   
}

This works in that it shows the scrollbar but it just displays an empty scrollbar, i.e. there is no cursor to allow the user to scroll up or down.

Is it possible to not only display the scrollbar but also have the cursor displaying as well?

like image 836
dagda1 Avatar asked Jan 17 '23 05:01

dagda1


1 Answers

Make the html a bit higher and the scroll will show up

html {
   overflow-y: scroll;
   height: 101%
}
like image 73
Zoltan Toth Avatar answered Jan 18 '23 23:01

Zoltan Toth