From 9c8fec06d2b58e4e3bbe280ddc665a99fcc4878c Mon Sep 17 00:00:00 2001
From: Jacky Zhao <j.zhao2k19@gmail.com>
Date: Sun, 09 Mar 2025 22:33:15 +0000
Subject: [PATCH] feat: support non-singleton search
---
quartz/components/Body.tsx | 21 ++++++++-------------
1 files changed, 8 insertions(+), 13 deletions(-)
diff --git a/quartz/components/Body.tsx b/quartz/components/Body.tsx
index 1d9296b..96b6278 100644
--- a/quartz/components/Body.tsx
+++ b/quartz/components/Body.tsx
@@ -1,18 +1,13 @@
-import { ComponentChildren } from "preact"
-import clipboardScript from './scripts/clipboard.inline'
-import clipboardStyle from './styles/clipboard.scss'
+// @ts-ignore
+import clipboardScript from "./scripts/clipboard.inline"
+import clipboardStyle from "./styles/clipboard.scss"
+import { QuartzComponent, QuartzComponentConstructor, QuartzComponentProps } from "./types"
-export interface BodyProps {
- title?: string
- children: ComponentChildren
-}
-
-export default function Body({ title, children }: BodyProps) {
- return <article>
- {title && <h1>{title}</h1>}
- {children}
- </article>
+const Body: QuartzComponent = ({ children }: QuartzComponentProps) => {
+ return <div id="quartz-body">{children}</div>
}
Body.afterDOMLoaded = clipboardScript
Body.css = clipboardStyle
+
+export default (() => Body) satisfies QuartzComponentConstructor
--
Gitblit v1.10.0