custom scrollbar size

This commit is contained in:
xaoxuu 2021-07-14 00:15:21 +08:00
parent f37326822c
commit be40bfd0ec
3 changed files with 6 additions and 5 deletions

View File

@ -199,6 +199,8 @@ style:
animated_avatar:
animate: auto # auto, always
background: https://cdn.jsdelivr.net/gh/cdn-x/placeholder@1.0.2/avatar/round/rainbow64@3x.webp
codeblock:
scrollbar: 4px
default:
avatar: https://cdn.jsdelivr.net/gh/cdn-x/placeholder@1.0.1/avatar/round/3442075.svg

View File

@ -36,7 +36,7 @@ article.md .highlight
margin: 0
background: transparent
border: none
scrollbar-codeblock()
scrollbar-codeblock(convert(hexo-config('style.codeblock.scrollbar')))
tr
background: transparent
&:hover
@ -71,7 +71,6 @@ article.md .highlight
.code
vertical-align: top
&:before
content: ""
position: absolute
top: 0
right: 0

View File

@ -68,10 +68,10 @@ scrollbar($w = 4px, $b = 2px, $c = var(--text-meta), $h = var(--text-p3))
background: $h
scrollbar-codeblock()
scrollbar-codeblock($height = 4px)
&::-webkit-scrollbar
height: 4px
width: 4px
height: $height
width: $height
&::-webkit-scrollbar-track-piece
background: transparent
&::-webkit-scrollbar-thumb