diff --git a/quartz.layout.ts b/quartz.layout.ts index 4a78256aa..e9ec591d7 100644 --- a/quartz.layout.ts +++ b/quartz.layout.ts @@ -5,7 +5,21 @@ import * as Component from "./quartz/components" export const sharedPageComponents: SharedLayout = { head: Component.Head(), header: [], - afterBody: [], + afterBody: [ + Component.Comments({ + provider: "giscus", + options: { + // from data-repo + repo: "jackyzha0/quartz", + // from data-repo-id + repoId: "MDEwOlJlcG9zaXRvcnkzODcyMTMyMDg", + // from data-category + category: "Announcements", + // from data-category-id + categoryId: "DIC_kwDOFxRnmM4B-Xg6", + }, + }), + ], footer: Component.Footer({ links: { GitHub: "https://github.com/jackyzha0/quartz", diff --git a/quartz/components/scripts/comments.inline.ts b/quartz/components/scripts/comments.inline.ts index 25ef1b79a..4ab29f087 100644 --- a/quartz/components/scripts/comments.inline.ts +++ b/quartz/components/scripts/comments.inline.ts @@ -1,7 +1,3 @@ -function boolToStringBool(b: boolean): string { - return b ? "1" : "0" -} - const changeTheme = (e: CustomEventMap["themechange"]) => { const theme = e.detail.theme const iframe = document.querySelector("iframe.giscus-frame") as HTMLIFrameElement