Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

::-webkit-scrollbar-button with content

I've tried to design the webkit scrollbar like Visual Studio.

Example:

Original Visual Studio Scrollbar

My question is, how i can set the ::-webkit-scrollbar-button like the example?

Here is my Code:

::-webkit-scrollbar-button {
    height: 10px;
    content: "▲";
    color: rgb(255, 255, 255);
    background: rgb(255, 0, 0);
}

Output: My Scrollbar

It is possible to use content: ""; property to set an UTF-Character like ▲ or ▼ ? Why it would'nt display?

Here is a Fiddle

like image 619
Adrian Preuss Avatar asked Oct 29 '22 07:10

Adrian Preuss


1 Answers

The content: "" does not seem to work with the scrollbar. I also tried with the content: "\25B2"but still does not work.

Maybe you can use a background image like in this Fiddle

like image 192
Alexander Paul Avatar answered Jan 02 '23 20:01

Alexander Paul