移动端显示滚动条并调整样式

一笑奈何 提交于 2019-12-24 16:40:03
  1. .list {  
  2.     overflow: hidden;  
  3.     overflow-y: auto;  
  4. }  
  5. .list::-webkit-scrollbar-track-piece {  
  6.     background-color: rgba(0, 0, 0, 0);  
  7.     border-left: 1px solid rgba(0, 0, 0, 0);  
  8. }  
  9. .list::-webkit-scrollbar {  
  10.     width: 5px;  
  11.     height: 13px;  
  12.     -webkit-border-radius: 5px;  
  13.     -moz-border-radius: 5px;  
  14.     border-radius: 5px;  
  15. }  
  16. .list::-webkit-scrollbar-thumb {  
  17.     background-color: rgba(0, 0, 0, 0.5);  
  18.     background-clip: padding-box;  
  19.     -webkit-border-radius: 5px;  
  20.     -moz-border-radius: 5px;  
  21.     border-radius: 5px;  
  22.     min-height: 28px;  
  23. }  
  24. .list::-webkit-scrollbar-thumb:hover {  
  25.     background-color: rgba(0, 0, 0, 0.5);  
  26.     -webkit-border-radius: 5px;  
  27.     -moz-border-radius: 5px;  
  28.     border-radius: 5px;  
  29. }  
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!