From c56bb01889101884c6bbdf076f24c783bdfeec33 Mon Sep 17 00:00:00 2001 From: Tony Bries Date: Tue, 25 Nov 2025 18:17:19 -0600 Subject: [PATCH 1/2] Remove backticks from rendered inline code elements --- astro.config.mjs | 2 ++ src/styles/globals.css | 6 +++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/astro.config.mjs b/astro.config.mjs index f797334..91f1898 100644 --- a/astro.config.mjs +++ b/astro.config.mjs @@ -11,6 +11,7 @@ const prettyCodeOptions = { light: 'github-light' }, keepBackground: false, + transformers: [], onVisitLine(node) { // Prevent lines from collapsing in `display: grid` mode, and allow empty // lines to be copy/pasted @@ -24,6 +25,7 @@ const prettyCodeOptions = { onVisitHighlightedChars(node) { node.properties.className = ['chars--highlighted']; }, + filterMetaString: (string) => string.replace(/filename="[^"]*"/, ''), }; // https://astro.build/config diff --git a/src/styles/globals.css b/src/styles/globals.css index cbb3e1f..d9c3246 100644 --- a/src/styles/globals.css +++ b/src/styles/globals.css @@ -481,7 +481,11 @@ .prose :not(pre) > code { @apply relative rounded bg-muted px-2 py-1 text-sm font-mono text-foreground; - @apply before:content-['`'] after:content-['`'] before:text-muted-foreground after:text-muted-foreground; +} + +.prose :not(pre) > code::before, +.prose :not(pre) > code::after { + content: none; } .dark .prose :not(pre) > code { From 2bcb0f64889c04a97a7a4a853c982828d02b9402 Mon Sep 17 00:00:00 2001 From: Tony Bries Date: Tue, 25 Nov 2025 19:54:13 -0600 Subject: [PATCH 2/2] Undo superfluous astro config changes. --- astro.config.mjs | 2 -- 1 file changed, 2 deletions(-) diff --git a/astro.config.mjs b/astro.config.mjs index 91f1898..f797334 100644 --- a/astro.config.mjs +++ b/astro.config.mjs @@ -11,7 +11,6 @@ const prettyCodeOptions = { light: 'github-light' }, keepBackground: false, - transformers: [], onVisitLine(node) { // Prevent lines from collapsing in `display: grid` mode, and allow empty // lines to be copy/pasted @@ -25,7 +24,6 @@ const prettyCodeOptions = { onVisitHighlightedChars(node) { node.properties.className = ['chars--highlighted']; }, - filterMetaString: (string) => string.replace(/filename="[^"]*"/, ''), }; // https://astro.build/config