summaryrefslogtreecommitdiffstats
path: root/src/pages
diff options
context:
space:
mode:
authorArmand Philippot <git@armandphilippot.com>2022-02-13 17:27:53 +0100
committerArmand Philippot <git@armandphilippot.com>2022-02-13 17:27:53 +0100
commite83d13bbbe4a7d19371a5be6782bd592a6ee7406 (patch)
tree86f4c8e2b70fb75ccc2f3ad3237e913968596995 /src/pages
parent45e4e10f4c7b818e83f6f7ab0255206e90f55851 (diff)
fix: switch prism theme on single article
I forgot to change the selector to query all code blocks.
Diffstat (limited to 'src/pages')
-rw-r--r--src/pages/article/[slug].tsx2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pages/article/[slug].tsx b/src/pages/article/[slug].tsx
index a45cbc9..7bde448 100644
--- a/src/pages/article/[slug].tsx
+++ b/src/pages/article/[slug].tsx
@@ -38,7 +38,7 @@ const SingleArticle: NextPageWithLayout<ArticleProps> = ({ post }) => {
useEffect(() => {
const allPre: NodeListOf<HTMLPreElement> = document.querySelectorAll(
- 'pre[data-prismjs-color-scheme'
+ 'pre[data-prismjs-color-scheme-current]'
);
setCodeBlocks(allPre);
}, [setCodeBlocks, router.asPath]);