From 104c86bec14108d414d57c62d775f51f42fcdaf1 Mon Sep 17 00:00:00 2001 From: bfahrenfort <59982409+bfahrenfort@users.noreply.github.com> Date: Sun, 1 Oct 2023 11:47:22 -0500 Subject: [PATCH 01/22] Fix: RSS title escaping (#521) * Fix title escaping * npm run format --- quartz/plugins/emitters/contentIndex.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/quartz/plugins/emitters/contentIndex.ts b/quartz/plugins/emitters/contentIndex.ts index 911173e1b..69d0d376f 100644 --- a/quartz/plugins/emitters/contentIndex.ts +++ b/quartz/plugins/emitters/contentIndex.ts @@ -68,9 +68,9 @@ function generateRSSFeed(cfg: GlobalConfiguration, idx: ContentIndex, limit?: nu ${escapeHTML(cfg.pageTitle)} ${root} - ${!!limit ? `Last ${limit} notes` : "Recent notes"} on ${ - cfg.pageTitle - } + ${!!limit ? `Last ${limit} notes` : "Recent notes"} on ${escapeHTML( + cfg.pageTitle, + )} Quartz -- quartz.jzhao.xyz ${items} From 4c0d06804a78dfe6a8bc791f1dad0d33b02b3385 Mon Sep 17 00:00:00 2001 From: Luca Salvarani Date: Mon, 2 Oct 2023 02:20:55 +0200 Subject: [PATCH 02/22] fix: Fix `Backlinks` not applying the display class (#519) * fix: Fix `Backlinks` not applying the display class Fix #518 * fix: Apply `displayClass` to all layout components * refactor: Use same style * fix: Remove `undefined` class using coalescing operator --- quartz/components/ArticleTitle.tsx | 4 ++-- quartz/components/Backlinks.tsx | 4 ++-- quartz/components/Breadcrumbs.tsx | 4 ++-- quartz/components/ContentMeta.tsx | 4 ++-- quartz/components/Darkmode.tsx | 6 +++--- quartz/components/Explorer.tsx | 2 +- quartz/components/Footer.tsx | 6 +++--- quartz/components/Graph.tsx | 6 +++--- quartz/components/PageTitle.tsx | 4 ++-- quartz/components/RecentNotes.tsx | 5 ++--- quartz/components/Search.tsx | 6 +++--- quartz/components/Spacer.tsx | 3 +-- quartz/components/TableOfContents.tsx | 2 +- quartz/components/TagList.tsx | 4 ++-- 14 files changed, 29 insertions(+), 31 deletions(-) diff --git a/quartz/components/ArticleTitle.tsx b/quartz/components/ArticleTitle.tsx index b8d58c6b3..a52b2a466 100644 --- a/quartz/components/ArticleTitle.tsx +++ b/quartz/components/ArticleTitle.tsx @@ -1,9 +1,9 @@ import { QuartzComponentConstructor, QuartzComponentProps } from "./types" -function ArticleTitle({ fileData }: QuartzComponentProps) { +function ArticleTitle({ fileData, displayClass }: QuartzComponentProps) { const title = fileData.frontmatter?.title if (title) { - return

{title}

+ return

{title}

} else { return null } diff --git a/quartz/components/Backlinks.tsx b/quartz/components/Backlinks.tsx index e88966b1c..c4172ce24 100644 --- a/quartz/components/Backlinks.tsx +++ b/quartz/components/Backlinks.tsx @@ -2,11 +2,11 @@ import { QuartzComponentConstructor, QuartzComponentProps } from "./types" import style from "./styles/backlinks.scss" import { resolveRelative, simplifySlug } from "../util/path" -function Backlinks({ fileData, allFiles }: QuartzComponentProps) { +function Backlinks({ fileData, allFiles, displayClass }: QuartzComponentProps) { const slug = simplifySlug(fileData.slug!) const backlinkFiles = allFiles.filter((file) => file.links?.includes(slug)) return ( -