From 37c6231e79d197f4d51db86e2760283f316ed191 Mon Sep 17 00:00:00 2001 From: Aaron Pham <29749331+aarnphm@users.noreply.github.com> Date: Tue, 30 Jan 2024 00:51:13 -0500 Subject: [PATCH] fix(div): update class name to remove weird space afterwards (#763) Signed-off-by: Aaron <29749331+aarnphm@users.noreply.github.com> --- quartz/components/ArticleTitle.tsx | 3 ++- quartz/components/Backlinks.tsx | 3 ++- quartz/components/Breadcrumbs.tsx | 3 ++- quartz/components/ContentMeta.tsx | 3 ++- quartz/components/Darkmode.tsx | 3 ++- quartz/components/Explorer.tsx | 3 ++- quartz/components/Graph.tsx | 3 ++- quartz/components/PageTitle.tsx | 3 ++- quartz/components/RecentNotes.tsx | 3 ++- quartz/components/Search.tsx | 3 ++- quartz/components/Spacer.tsx | 3 ++- quartz/components/TableOfContents.tsx | 3 ++- quartz/components/TagList.tsx | 3 ++- quartz/util/lang.ts | 10 ++++++++++ 14 files changed, 36 insertions(+), 13 deletions(-) diff --git a/quartz/components/ArticleTitle.tsx b/quartz/components/ArticleTitle.tsx index a52b2a466..2484c946a 100644 --- a/quartz/components/ArticleTitle.tsx +++ b/quartz/components/ArticleTitle.tsx @@ -1,9 +1,10 @@ import { QuartzComponentConstructor, QuartzComponentProps } from "./types" +import { classNames } from "../util/lang" 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 c4172ce24..d5bdc0b95 100644 --- a/quartz/components/Backlinks.tsx +++ b/quartz/components/Backlinks.tsx @@ -1,12 +1,13 @@ import { QuartzComponentConstructor, QuartzComponentProps } from "./types" import style from "./styles/backlinks.scss" import { resolveRelative, simplifySlug } from "../util/path" +import { classNames } from "../util/lang" function Backlinks({ fileData, allFiles, displayClass }: QuartzComponentProps) { const slug = simplifySlug(fileData.slug!) const backlinkFiles = allFiles.filter((file) => file.links?.includes(slug)) return ( -