1.隐藏
/*放在overflow:auto;同级*/
scrollbar-width: none; /* Firefox */
-ms-overflow-style:none; /* IE10+ */
&::-webkit-scrollbar{
display:none; /* ChromeSafari */
}
2.去除滚动条
.autoScroll{
/deep/ ::-webkit-scrollbar {
display: none;
}
}
3.调整
/*里面的代码可以根据自己需求去进行更改*/
/* 设置滚动条的样式 */
::-webkit-scrollbar {
width:4px;
}
/* 滚动槽 */
::-webkit-scrollbar-track {
-webkit-box-shadow:inset006pxrgba(0,0,0,0.3);
border-radius:10px;
}
/* 滚动条滑块 */
::-webkit-scrollbar-thumb {
border-radius:10px;
background:rgba(0,0,0,0.1);
-webkit-box-shadow:inset006pxrgba(0,0,0,0.5);
}
::-webkit-scrollbar-thumb:window-inactive {
background:rgba(255,255,255,0.4);
}