Skip to content

Commit

Permalink
chore: reset style
Browse files Browse the repository at this point in the history
  • Loading branch information
sonofmagic committed Sep 19, 2024
1 parent 8f172d4 commit 218e65a
Showing 1 changed file with 50 additions and 50 deletions.
100 changes: 50 additions & 50 deletions blog-archived/client/assets/scss/global.scss
Original file line number Diff line number Diff line change
Expand Up @@ -71,53 +71,53 @@ html {
}

/* 隐藏 Chrome、Edge、Safari 浏览器的滚动条 */
body::-webkit-scrollbar {
width: 0;
background: transparent;
}

/* 自定义滚动条的轨道 */
body::-webkit-scrollbar-track {
background: transparent;
}

/* 自定义滚动条的滑块 */
body::-webkit-scrollbar-thumb {
background-color: transparent;
border-radius: 10px;
transition:
background-color 0.3s,
width 0.3s;
}

/* 滚动的时候显示滚动条 */
body:active::-webkit-scrollbar-thumb {
background-color: rgb(0 0 0 / 40%);
}

/* 鼠标悬停时,滚动条变宽和颜色加深 */
body::-webkit-scrollbar-thumb:hover {
background-color: rgb(0 0 0 / 80%);
width: 8px;
}

/* 滚动条不占用空间 (Chrome, Edge, Safari) */
html {
scrollbar-gutter: stable;
}

/* 针对 Firefox 的放大效果 */
@media (hover: hover) {
body {
scrollbar-color: transparent transparent;
}

body:active {
scrollbar-color: rgb(0 0 0 / 40%) transparent;
}

body:hover {
scrollbar-color: rgb(0 0 0 / 80%) transparent;
scrollbar-width: thin; /* 确保宽度变化的效果 */
}
}
// body::-webkit-scrollbar {
// width: 0;
// background: transparent;
// }

// /* 自定义滚动条的轨道 */
// body::-webkit-scrollbar-track {
// background: transparent;
// }

// /* 自定义滚动条的滑块 */
// body::-webkit-scrollbar-thumb {
// background-color: transparent;
// border-radius: 10px;
// transition:
// background-color 0.3s,
// width 0.3s;
// }

// /* 滚动的时候显示滚动条 */
// body:active::-webkit-scrollbar-thumb {
// background-color: rgb(0 0 0 / 40%);
// }

// /* 鼠标悬停时,滚动条变宽和颜色加深 */
// body::-webkit-scrollbar-thumb:hover {
// background-color: rgb(0 0 0 / 80%);
// width: 8px;
// }

// /* 滚动条不占用空间 (Chrome, Edge, Safari) */
// html {
// scrollbar-gutter: stable;
// }

// /* 针对 Firefox 的放大效果 */
// @media (hover: hover) {
// body {
// scrollbar-color: transparent transparent;
// }

// body:active {
// scrollbar-color: rgb(0 0 0 / 40%) transparent;
// }

// body:hover {
// scrollbar-color: rgb(0 0 0 / 80%) transparent;
// scrollbar-width: thin; /* 确保宽度变化的效果 */
// }
// }

0 comments on commit 218e65a

Please sign in to comment.