```javasc在这里插入代码片
ript
html,
body {
height: 100%;
/* 以下css是用来解决el-diao 窗口抖动的问题 */
overflow-y: auto !important;
padding-right: 0 !important;
}
html {
overflow-y: overlay;
overflow: auto;
}
html::-webkit-scrollbar {
width: 10px;
height: 1px;
}
/滚动条滑块/
html::-webkit-scrollbar-thumb {
border-radius: 10px;
-webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
background: #d8e0f3;
}
/滚动条轨道/
html::-webkit-scrollbar-track {
-webkit-box-shadow: inset 0 0 1px rgba(0, 0, 0, 0.5);
border-radius: 10px;
background: #edddf2;
}
@mixin custom-scrollbar {
&::-webkit-scrollbar {
width: 10px;
height: 1px;
}
&::-webkit-scrollbar-thumb {
border-radius: 10px;
-webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
background: #d8e0f3;
}
&::-webkit-scrollbar-track {
-webkit-box-shadow: inset 0 0 1px rgba(0, 0, 0, 0.5);
border-radius: 10px;
background: #edddf2;
}
}
.el-main {
@include custom-scrollbar;
}
body {
@include custom-scrollbar;
}