Skip to content

Commit 04a5886

Browse files
Add scrollbar to large output code blocks (#1612)
1 parent 1f55996 commit 04a5886

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

assets/css/content/code.css

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,28 @@
3030
background-color: var(--codeBackground);
3131
}
3232

33+
.content-inner pre code::-webkit-scrollbar {
34+
width: 0.4rem;
35+
height: 0.4rem;
36+
}
37+
38+
.content-inner pre code::-webkit-scrollbar-thumb {
39+
border-radius: 0.25rem;
40+
background-color: var(--gray300);
41+
}
42+
43+
.content-inner pre code::-webkit-scrollbar-track {
44+
background-color: var(--gray100);
45+
}
46+
47+
.content-inner pre code::-webkit-scrollbar-corner {
48+
background-color: var(--gray100);
49+
}
50+
3351
.content-inner pre code.output {
3452
margin: 0 12px;
53+
max-height: 400px;
54+
overflow: auto;
3555
}
3656

3757
.content-inner pre code.output + .copy-button {

0 commit comments

Comments
 (0)