Skip to content

Commit dcdc388

Browse files
feat: improve scrollbar (#48)
1 parent ee79648 commit dcdc388

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

src/styles/custom.css

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,36 @@
2828
.sl-markdown-content pre > code {
2929
font-size: 1em;
3030
}
31+
32+
/* Custom scrollbar */
33+
:root[data-theme="light"] ::-webkit-scrollbar-track {
34+
background: #f1f1f1;
35+
}
36+
37+
:root[data-theme="light"] ::-webkit-scrollbar-thumb {
38+
background: #888;
39+
}
40+
41+
:root[data-theme="light"] ::-webkit-scrollbar-thumb:hover {
42+
background: #555;
43+
}
44+
45+
:root[data-theme="dark"] ::-webkit-scrollbar-track {
46+
background: #2a2a2a;
47+
}
48+
49+
:root[data-theme="dark"] ::-webkit-scrollbar-thumb {
50+
background: #666;
51+
}
52+
53+
:root[data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
54+
background: #aaa;
55+
}
56+
57+
::-webkit-scrollbar {
58+
width: 8px;
59+
}
60+
61+
::-webkit-scrollbar-thumb {
62+
border-radius: 4px;
63+
}

0 commit comments

Comments
 (0)