前端代碼隨筆


//

   CSS3自定義滾動條樣式 -webkit-scrollbar

.test-1::-webkit-scrollbar {/*滾動條總體樣式*/
        width: 10px;     /*高寬分別對應橫豎滾動條的尺寸*/
        height: 1px;
    }
.test-1::-webkit-scrollbar-thumb {/*滾動條裏面小方塊*/
        border-radius: 10px;
         -webkit-box-shadow: inset 0 0 5px rgba(0,0,0,0.2);
        background: #535353;
    }
.test-1::-webkit-scrollbar-track {/*滾動條裏面軌道*/
        -webkit-box-shadow: inset 0 0 5px rgba(0,0,0,0.2);
        border-radius: 10px;
        background: #EDEDED;
    }
相關文章
相關標籤/搜索