From b33f13ccaf4ec14a94ee0ee467dda04cf4981d00 Mon Sep 17 00:00:00 2001
From: Jacky Zhao <j.zhao2k19@gmail.com>
Date: Mon, 01 Jan 2024 22:20:34 +0000
Subject: [PATCH] fix: dont show last page if folder
---
quartz/plugins/transformers/syntax.ts | 31 +++++++++++++------------------
1 files changed, 13 insertions(+), 18 deletions(-)
diff --git a/quartz/plugins/transformers/syntax.ts b/quartz/plugins/transformers/syntax.ts
index 16424ec..e847729 100644
--- a/quartz/plugins/transformers/syntax.ts
+++ b/quartz/plugins/transformers/syntax.ts
@@ -3,23 +3,18 @@
export const SyntaxHighlighting: QuartzTransformerPlugin = () => ({
name: "SyntaxHighlighting",
- markdownPlugins() {
- return []
- },
htmlPlugins() {
- return [[rehypePrettyCode, {
- theme: 'css-variables',
- onVisitLine(node) {
- if (node.children.length === 0) {
- node.children = [{ type: 'text', value: ' ' }]
- }
- },
- onVisitHighlightedLine(node) {
- node.properties.className.push('highlighted')
- },
- onVisitHighlightedWord(node) {
- node.properties.className = ['word']
- },
- } satisfies Partial<CodeOptions>]]
- }
+ return [
+ [
+ rehypePrettyCode,
+ {
+ keepBackground: false,
+ theme: {
+ dark: "github-dark",
+ light: "github-light",
+ },
+ } satisfies Partial<CodeOptions>,
+ ],
+ ]
+ },
})
--
Gitblit v1.10.0