更新时间:2023-01-05 18:11:26
:
::-webkit-scrollbar { /* 1 */ }
::-webkit-scrollbar-button { /* 2 */ }
::-webkit-scrollbar-track { /* 3 */ }
::-webkit-scrollbar-track-piece { /* 4 */ }
::-webkit-scrollbar-thumb { /* 5 */ }
::-webkit-scrollbar-corner { /* 6 */ }
::-webkit-resizer { /* 7 */ }
根据此页面的代码解释问题,工作小提琴与红色滚动条。
Here's a working fiddle with a red scrollbar, based on code from this page explaining the issues.
http://jsfiddle.net/hmartiro/Xck2A/1/
使用这个和你的解决方案,你可以处理除Firefox以外的所有浏览器,在这一点上,我认为还需要一个javascript解决方案。
Using this and your solution, you can handle all browsers except Firefox, which at this point I think still requires a javascript solution.