From 0c199975f2d469ecdfd7efcf2ddd16ffa1dc492b Mon Sep 17 00:00:00 2001
From: Jacky Zhao <j.zhao2k19@gmail.com>
Date: Thu, 17 Aug 2023 07:55:28 +0000
Subject: [PATCH] various path fixes for links to extensions, fix relative paths in links
---
quartz/components/pages/TagContent.tsx | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/quartz/components/pages/TagContent.tsx b/quartz/components/pages/TagContent.tsx
index 5300cce..2cae40d 100644
--- a/quartz/components/pages/TagContent.tsx
+++ b/quartz/components/pages/TagContent.tsx
@@ -3,7 +3,7 @@
import { toJsxRuntime } from "hast-util-to-jsx-runtime"
import style from "../styles/listPage.scss"
import { PageList } from "../PageList"
-import { ServerSlug, canonicalizeServer, getAllSegmentPrefixes } from "../../path"
+import { ServerSlug, canonicalizeServer, getAllSegmentPrefixes } from "../../util/path"
import { QuartzPluginData } from "../../plugins/vfile"
const numPages = 10
@@ -11,7 +11,7 @@
const { tree, fileData, allFiles } = props
const slug = fileData.slug
- if (!slug?.startsWith("tags/")) {
+ if (!(slug?.startsWith("tags/") || slug === "tags")) {
throw new Error(`Component "TagContent" tried to render a non-tag page: ${slug}`)
}
@@ -44,7 +44,7 @@
return (
<div>
<h2>
- <a class="internal tag-link" href={`./tags/${tag}`}>
+ <a class="internal tag-link" href={`./${tag}`}>
#{tag}
</a>
</h2>
--
Gitblit v1.10.0