0

I want to edit the style of the scrollbar in my site so it would fit the overall theme. There doesn't seem to have info in google. I mean there are but they also change the browser's scrollbar and only work with IE. How would I go about this?

Joann
  • 1,375
  • 4
  • 16
  • 27

2 Answers2

3

If I remember correctly, styling of a scroll bar is not part of the HTML or CSS standard (last time I checked), although Internet Explorer does support it through their own extension (barstardisation?) of the standards.

My opinion - don't bother with styling of the scroll-bars. It is so 1994. We have moved on since then. You will find that 99 - 100% of most major/popular websites simply don't do it. It is generally accepted that styling of scroll-bars is a horrible thing to do.

I prefer my scroll-bars unstyled. The operating system and browser does a good enough job for 99% of the users out there.

Leave it alone.

Saajid Ismail
  • 8,029
  • 11
  • 48
  • 56
  • 1
    For what it's worth I think the situation is a little different now. Scrollbars are easier to style using Javascript libraries and it's become fairly normal for sites to style *internal* scrollbars to match their site or app's look and feel. Lazybars (http://lazybars.suiji.co.uk/), mentioned in @AdamBruzon's answer, is an excellent example of this. – Nick Coad Sep 30 '14 at 04:07
1

If you really want some custom scrollbars then there are some hacks you can use in Javascript and CSS - Nice article on CSS-tricks.

There are plenty of jQuery plugins out there too. One I have used is called Lazybars - really simple to implement.

Hope this helps

  • 1
    Please avoid link-only answers (links can go dead). You could edit your answer and add a short summary of the techniques advised in the links you pushed. – RandomSeed Feb 14 '14 at 12:55