fix(docs): improve code block styling

This commit is contained in:
t8y2
2026-05-09 23:52:41 +08:00
parent dc2164dd62
commit cdb18baa6a
+23
View File
@@ -159,9 +159,32 @@ article pre {
border: 1px solid color-mix(in srgb, var(--color-fd-border) 70%, transparent);
border-radius: 10px;
background: #0b1220 !important;
margin: 1rem 0 1.35rem;
padding: 0.9rem 0;
overflow-x: auto;
box-shadow: 0 18px 42px color-mix(in srgb, black 14%, transparent);
}
article pre code {
display: block;
min-width: max-content;
border: 0;
background: transparent !important;
color: #d7e2f0;
font-size: 0.92rem;
line-height: 1.72;
}
article pre code span {
color: var(--shiki-dark, #d7e2f0) !important;
font-style: var(--shiki-dark-font-style, inherit);
}
article pre .line {
padding-left: 1.1rem;
padding-right: 1.1rem;
}
article :not(pre) > code {
border: 1px solid var(--dbx-line);
border-radius: 6px;