diff --git a/docs/advanced/making plugins.md b/docs/advanced/making plugins.md index b2bacf0..0ba2968 100644 --- a/docs/advanced/making plugins.md +++ b/docs/advanced/making plugins.md @@ -260,11 +260,11 @@ export const ContentPage: QuartzEmitterPlugin = () => { ...defaultContentPageLayout, pageBody: Content(), } - const { head, header, beforeBody, pageBody, left, right, footer } = layout + const { head, header, beforeBody, pageBody, afterBody, left, right, footer } = layout return { name: "ContentPage", getQuartzComponents() { - return [head, ...header, ...beforeBody, pageBody, ...left, ...right, footer] + return [head, ...header, ...beforeBody, pageBody, ...afterBody, ...left, ...right, footer] }, async emit(ctx, content, resources, emit): Promise { const cfg = ctx.cfg.configuration diff --git a/docs/images/quartz layout.png b/docs/images/quartz layout.png index 03435f7..71ef3ac 100644 Binary files a/docs/images/quartz layout.png and b/docs/images/quartz layout.png differ diff --git a/docs/layout.md b/docs/layout.md index 3fabeb7..686b2f2 100644 --- a/docs/layout.md +++ b/docs/layout.md @@ -12,6 +12,7 @@ export interface FullPageLayout { header: QuartzComponent[] // laid out horizontally beforeBody: QuartzComponent[] // laid out vertically pageBody: QuartzComponent // single component + afterBody: QuartzComponent[] // laid out vertically left: QuartzComponent[] // vertical on desktop, horizontal on mobile right: QuartzComponent[] // vertical on desktop, horizontal on mobile footer: QuartzComponent // single component diff --git a/quartz.layout.ts b/quartz.layout.ts index b5a1639..4a78256 100644 --- a/quartz.layout.ts +++ b/quartz.layout.ts @@ -5,6 +5,7 @@ import * as Component from "./quartz/components" export const sharedPageComponents: SharedLayout = { head: Component.Head(), header: [], + afterBody: [], footer: Component.Footer({ links: { GitHub: "https://github.com/jackyzha0/quartz", diff --git a/quartz/cfg.ts b/quartz/cfg.ts index 574ceb1..0c344d3 100644 --- a/quartz/cfg.ts +++ b/quartz/cfg.ts @@ -77,10 +77,11 @@ export interface FullPageLayout { header: QuartzComponent[] beforeBody: QuartzComponent[] pageBody: QuartzComponent + afterBody: QuartzComponent[] left: QuartzComponent[] right: QuartzComponent[] footer: QuartzComponent } export type PageLayout = Pick -export type SharedLayout = Pick +export type SharedLayout = Pick diff --git a/quartz/components/Footer.tsx b/quartz/components/Footer.tsx index 076c378..cff28cb 100644 --- a/quartz/components/Footer.tsx +++ b/quartz/components/Footer.tsx @@ -13,7 +13,6 @@ export default ((opts?: Options) => { const links = opts?.links ?? [] return (