From 4e2aea8a5a414b3bcfac0168bea4f6afd032e8f5 Mon Sep 17 00:00:00 2001
From: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Date: Mon, 26 Aug 2024 21:12:45 +0000
Subject: [PATCH] chore(deps): bump @napi-rs/simple-git from 0.1.17 to 0.1.19 (#1376)
---
quartz/components/pages/404.tsx | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/quartz/components/pages/404.tsx b/quartz/components/pages/404.tsx
index 4ef1b91..63da2c8 100644
--- a/quartz/components/pages/404.tsx
+++ b/quartz/components/pages/404.tsx
@@ -2,10 +2,15 @@
import { QuartzComponent, QuartzComponentConstructor, QuartzComponentProps } from "../types"
const NotFound: QuartzComponent = ({ cfg }: QuartzComponentProps) => {
+ // If baseUrl contains a pathname after the domain, use this as the home link
+ const url = new URL(`https://${cfg.baseUrl ?? "example.com"}`)
+ const baseDir = url.pathname
+
return (
<article class="popover-hint">
<h1>404</h1>
<p>{i18n(cfg.locale).pages.error.notFound}</p>
+ <a href={baseDir}>{i18n(cfg.locale).pages.error.home}</a>
</article>
)
}
--
Gitblit v1.10.0