From 597c4b1d457d2207dee01863c6ade1078d7f6c83 Mon Sep 17 00:00:00 2001 From: Dotta Date: Sun, 15 Mar 2026 14:27:34 -0500 Subject: [PATCH] Fix code block styles with robust prose overrides Previous attempt was being overridden by Tailwind prose/prose-invert CSS variables. This fix: - Overrides --tw-prose-pre-bg and --tw-prose-invert-pre-bg CSS variables on .paperclip-markdown to force dark background in both modes - Uses .paperclip-markdown pre with \!important for bulletproof overrides - Removes conflicting prose-pre: utility classes from MarkdownBody - Adds explicit pre code reset (inherit color/size, no background) - Verified visually with Playwright at desktop and mobile viewports Co-Authored-By: Paperclip --- ui/src/components/MarkdownBody.tsx | 2 +- ui/src/index.css | 36 +++++++++++++++++++++--------- 2 files changed, 27 insertions(+), 11 deletions(-) diff --git a/ui/src/components/MarkdownBody.tsx b/ui/src/components/MarkdownBody.tsx index 1242fa8a..683adc53 100644 --- a/ui/src/components/MarkdownBody.tsx +++ b/ui/src/components/MarkdownBody.tsx @@ -117,7 +117,7 @@ export function MarkdownBody({ children, className }: MarkdownBodyProps) { return (