feat: enhance font styling in Diff Viewer and Streamdown components

This commit is contained in:
Bohdan Triapitsyn
2025-12-16 13:26:03 +02:00
parent c87815a2a6
commit 764a48018f
3 changed files with 18 additions and 0 deletions
+5
View File
@@ -4,7 +4,12 @@ All notable changes to this project will be documented in this file.
## [Unreleased]
## [1.2.1] - 2025-12-16
- Todo task tracking: collapsible status row showing AI's current task and progress
- Switched "Detailed" tool output mode to only open the 'task', 'edit', 'multiedit', 'write', 'bash' tools for better performance
## [1.2.0] - 2025-12-15
@@ -19,12 +19,23 @@ interface PierreDiffViewerProps {
// CSS injected into Pierre's Shadow DOM for WebKit scroll optimization
// Note: avoid will-change and contain:paint as they break resize behavior
const WEBKIT_SCROLL_FIX_CSS = `
:host {
font-family: var(--font-mono);
font-size: var(--text-code);
}
:host, pre, [data-diffs], [data-code] {
transform: translateZ(0);
-webkit-transform: translateZ(0);
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
}
pre, [data-code] {
font-family: var(--font-mono);
font-size: var(--text-code);
}
[data-code] {
-webkit-overflow-scrolling: touch;
}
+2
View File
@@ -1381,10 +1381,12 @@ html:not(.dark) .chat-scroll {
.streamdown-content code,
.streamdown-content pre {
font-family: var(--font-mono);
font-size: var(--text-code);
}
/* Streamdown code blocks: ensure light/dark Shiki vars work even when Tailwind doesn't scan Streamdown's internal class names. */
.streamdown-content [data-streamdown="code-block-body"] {
font-size: var(--text-code);
background-color: var(--shiki-light-bg, transparent);
color: var(--shiki-light, inherit);
}