0

I'm trying to stylize the scrollbar using NiceScroll Plugin, I'm doing so with css besides the parameters it offers, the thing is that it creates two HTML elements, and the design I have "has" three elements.

here are the parameters I'm using:

$('.albums').niceScroll({
    cursorcolor: '#D289A6',
    cursorwidth: '10',
    cursorborder: '',
    cursorborderradius: '12px',
    background: '#fff'
});

Here is the image of the scrollbar:

enter image description here And here is the jsFiddle I created to reproduce it: http://jsfiddle.net/YKhce/

I'm missing the white "rail", and I donb't want to use :before and :after pseudo-elements because the users will use this mostly in IE.

How to achieve this?

Adrift
  • 58,167
  • 12
  • 92
  • 90

1 Answers1

0

you could draw it with box-shadow and outline:
http://jsfiddle.net/ScndL/

#outter {
    width: 25px;
    height: 400px;
    background:white;
    border-radius:10px;
    box-shadow:inset -1px 0 0 10px #2956a1, 0 0 0 3px #2956a1;
    outline: solid 5px #2956a1;
    outline-offset:-2px
}

update to square http://jsfiddle.net/ScndL/1/

#outter {
    width: 25px;
    height: 400px;
    background:white;
    box-shadow:inset -1px 0 0 10px #2956a1;
}
G-Cyrillus
  • 101,410
  • 14
  • 105
  • 129