自定义滚动条样式
效果
代码
<div class="schoolPlatformGroup"> <ul v-for="data in platformTreeList"> <li>{{data.platformName}}</li> </ul> </div>
.schoolPlatformGroup {
min-width:220px;
height: 850px;
overflow-y: auto;
}
.schoolPlatformGroup::-webkit-scrollbar {
width: 10px;
height: 1px;
}
.schoolPlatformGroup::-webkit-scrollbar-thumb {
border-radius: 10px;
background-color: rgba(52, 163, 242, 0.48);
}
.schoolPlatformGroup::-webkit-scrollbar-track {
-webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
background: #ededed;
}