Skip to content

Instantly share code, notes, and snippets.

@chu888chu888
Created May 15, 2013 04:52
Show Gist options
  • Save chu888chu888/5581708 to your computer and use it in GitHub Desktop.
Save chu888chu888/5581708 to your computer and use it in GitHub Desktop.
/*把代码加到样式表就可以了,表示很喜欢。*/
::-webkit-scrollbar{
padding-left:1px;
border-left:1px solid #d5d5d5;
background-color:#fafafa;
overflow:visible;
width:13px;
}
::-webkit-scrollbar-thumb{
background-color:rgba(0, 0, 0, .2);
background-clip:padding-box;
border:1px solid transparent;
border-left-width:2px;
min-height:15px;
box-shadow:inset 1px 1px 0 rgba(0, 0, 0, .1),inset 0 -1px 0 rgba(0, 0, 0, .07);
}
::-webkit-scrollbar-thumb:vertical:hover{
background-color:rgba(0, 0, 0, .3);
}
::-webkit-scrollbar-thumb:vertical:active{
background-color:rgba(0, 0, 0, .5);
}
::-webkit-scrollbar-button{
height:0;
width:0;
}
::-webkit-scrollbar-track{
background-clip:padding-box;
border:solid transparent;
border-width:0 0 0 4px;
}
::-webkit-scrollbar-corner{
background:transparent;
}
@chu888chu888
Copy link
Author

CSS滚动条美化

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment