fix: improve code block line spacing and wrap long lines

- Increase line-height from 1.4 to 1.5 for better readability
- Use pre-wrap instead of pre to allow long line wrapping
- Add overflow-wrap: break-word to break long URLs/strings
This commit is contained in:
Claude
2026-01-30 11:05:49 +00:00
parent c7a4be04af
commit 76e02050a9

View File

@@ -68,22 +68,21 @@
.shiki-container code {
font-family: "Oxygen Mono", monospace;
font-size: 0.75rem;
line-height: 1.4;
white-space: pre;
word-spacing: normal;
word-break: normal;
line-height: 1.5;
white-space: pre-wrap;
overflow-wrap: break-word;
tab-size: 4;
color: hsl(var(--foreground));
/* Flex layout for tight line packing */
/* Flex layout for consistent line spacing */
display: flex;
flex-direction: column;
gap: 0;
}
/* Lines should be inline-block to allow background colors */
/* Lines with proper spacing and wrapping */
.shiki-container .line {
display: block;
min-height: 1.4em;
min-height: 1.5em;
}
/* Ensure shiki's inline styles don't conflict */