diff --git a/src/components/Note/MarkdownArticle/MarkdownArticle.tsx b/src/components/Note/MarkdownArticle/MarkdownArticle.tsx index 2dd1025..8860f59 100644 --- a/src/components/Note/MarkdownArticle/MarkdownArticle.tsx +++ b/src/components/Note/MarkdownArticle/MarkdownArticle.tsx @@ -131,12 +131,11 @@ function CodeBlock({ id, code, language }: { id: string; code: string; language: return (
+
{code}
@@ -188,7 +187,7 @@ function InlineCode({ code, keyPrefix }: { code: string; keyPrefix: string }) {
// On error, fall back to showing the code as-is
if (elementRef.current) {
elementRef.current.textContent = code
- elementRef.current.className = 'bg-muted px-1 py-0.5 rounded text-sm font-mono'
+ elementRef.current.className = 'bg-muted px-1 py-0.5 rounded text-sm font-mono text-foreground'
}
}
}
@@ -208,7 +207,7 @@ function InlineCode({ code, keyPrefix }: { code: string; keyPrefix: string }) {
// Regular inline code
return (
-
+
{code}
)
@@ -2933,6 +2932,10 @@ export default function MarkdownArticle({
}
.hljs {
background: transparent !important;
+ color: #1f2937 !important;
+ }
+ .dark .hljs {
+ color: #f3f4f6 !important;
}
.hljs-keyword,
.hljs-selector-tag,