import { QuartzComponent, QuartzComponentConstructor, QuartzComponentProps } from "./types" import { classNames } from "../util/lang" // @ts-ignore import script from "./scripts/comments.inline" type Options = { provider: "giscus" options: { repo: `${string}/${string}` repoId: string category: string categoryId: string mapping?: "url" | "title" | "og:title" | "specific" | "number" | "pathname" strict?: boolean reactionsEnabled?: boolean inputPosition?: "top" | "bottom" } } function boolToStringBool(b: boolean): string { return b ? "1" : "0" } export default ((opts: Options) => { const Comments: QuartzComponent = ({ displayClass, cfg }: QuartzComponentProps) => { return (
) } Comments.afterDOMLoaded = script return Comments }) satisfies QuartzComponentConstructor