From f31cabbbf9b0d438710618a3edd2a4eaaae09d7d Mon Sep 17 00:00:00 2001
From: Jacky Zhao <j.zhao2k19@gmail.com>
Date: Mon, 15 Jan 2024 20:37:56 +0000
Subject: [PATCH] fix: dont use default callout title if theres additional title children left (closes #693)

---
 quartz/components/Breadcrumbs.tsx |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/quartz/components/Breadcrumbs.tsx b/quartz/components/Breadcrumbs.tsx
index a0b8cf5..0497b64 100644
--- a/quartz/components/Breadcrumbs.tsx
+++ b/quartz/components/Breadcrumbs.tsx
@@ -18,15 +18,15 @@
    */
   rootName: string
   /**
-   * wether to look up frontmatter title for folders (could cause performance problems with big vaults)
+   * Whether to look up frontmatter title for folders (could cause performance problems with big vaults)
    */
   resolveFrontmatterTitle: boolean
   /**
-   * Wether to display breadcrumbs on root `index.md`
+   * Whether to display breadcrumbs on root `index.md`
    */
   hideOnRoot: boolean
   /**
-   * Wether to display the current page in the breadcrumbs.
+   * Whether to display the current page in the breadcrumbs.
    */
   showCurrentPage: boolean
 }
@@ -104,7 +104,7 @@
       }
 
       // Add current file to crumb (can directly use frontmatter title)
-      if (options.showCurrentPage) {
+      if (options.showCurrentPage && slugParts.at(-1) === "") {
         crumbs.push({
           displayName: fileData.frontmatter!.title,
           path: "",

--
Gitblit v1.10.0