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/configuration.md b/docs/configuration.md index e97d8df..1dc1148 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -53,6 +53,7 @@ This part of the configuration concerns anything that can affect the whole site. - `secondary`: link colour, current [[graph view|graph]] node - `tertiary`: hover states and visited [[graph view|graph]] nodes - `highlight`: internal link background, highlighted text, [[syntax highlighting|highlighted lines of code]] + - `textHighlight`: markdown highlighted text background ## Plugins diff --git a/docs/features/folder and tag listings.md b/docs/features/folder and tag listings.md index d330f14..3190709 100644 --- a/docs/features/folder and tag listings.md +++ b/docs/features/folder and tag listings.md @@ -30,4 +30,4 @@ As with folder listings, you can also provide a description and title for a tag ## Customization -The folder listings are a functionality of the [[FolderPage]] plugin, the tag listings of the [[TagPage]] plugin. See the plugin pages for customization options. +Quartz allows you to define a custom sort ordering for content on both page types. The folder listings are a functionality of the [[FolderPage]] plugin, the tag listings of the [[TagPage]] plugin. See the plugin pages for customization options. diff --git a/docs/features/upcoming features.md b/docs/features/upcoming features.md index 76adda0..11d9cbd 100644 --- a/docs/features/upcoming features.md +++ b/docs/features/upcoming features.md @@ -2,22 +2,12 @@ draft: true --- -## high priority backlog - -- static dead link detection -- block links: https://help.obsidian.md/Linking+notes+and+files/Internal+links#Link+to+a+block+in+a+note -- note/header/block transcludes: https://help.obsidian.md/Linking+notes+and+files/Embedding+files -- docker support - ## misc backlog -- breadcrumbs component +- static dead link detection - cursor chat extension - https://giscus.app/ extension - sidenotes? https://github.com/capnfabs/paperesque - direct match in search using double quotes - https://help.obsidian.md/Advanced+topics/Using+Obsidian+URI -- audio/video embed styling - Canvas -- parse all images in page: use this for page lists if applicable? -- CV mode? with print stylesheet 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/docs/plugins/FolderPage.md b/docs/plugins/FolderPage.md index ead8e75..45cfa15 100644 --- a/docs/plugins/FolderPage.md +++ b/docs/plugins/FolderPage.md @@ -11,10 +11,12 @@ Example: [[advanced/|Advanced]] > [!note] > For information on how to add, remove or configure plugins, see the [[configuration#Plugins|Configuration]] page. -This plugin has no configuration options. - The pages are displayed using the `defaultListPageLayout` in `quartz.layouts.ts`. For the content, the `FolderContent` component is used. If you want to modify the layout, you must edit it directly (`quartz/components/pages/FolderContent.tsx`). +This plugin accepts the following configuration options: + +- `sort`: A function of type `(f1: QuartzPluginData, f2: QuartzPluginData) => number{:ts}` used to sort entries. Defaults to sorting by date and tie-breaking on lexographical order. + ## API - Category: Emitter diff --git a/docs/plugins/TagPage.md b/docs/plugins/TagPage.md index 9c704b3..9556363 100644 --- a/docs/plugins/TagPage.md +++ b/docs/plugins/TagPage.md @@ -9,10 +9,12 @@ This plugin emits dedicated pages for each tag used in the content. See [[folder > [!note] > For information on how to add, remove or configure plugins, see the [[configuration#Plugins|Configuration]] page. -This plugin has no configuration options. - The pages are displayed using the `defaultListPageLayout` in `quartz.layouts.ts`. For the content, the `TagContent` component is used. If you want to modify the layout, you must edit it directly (`quartz/components/pages/TagContent.tsx`). +This plugin accepts the following configuration options: + +- `sort`: A function of type `(f1: QuartzPluginData, f2: QuartzPluginData) => number{:ts}` used to sort entries. Defaults to sorting by date and tie-breaking on lexographical order. + ## API - Category: Emitter diff --git a/quartz.config.ts b/quartz.config.ts index a77707e..b9fc0ae 100644 --- a/quartz.config.ts +++ b/quartz.config.ts @@ -34,6 +34,7 @@ const config: QuartzConfig = { secondary: "#284b63", tertiary: "#84a59d", highlight: "rgba(143, 159, 169, 0.15)", + textHighlight: "#fff23688", }, darkMode: { light: "#161618", @@ -44,6 +45,7 @@ const config: QuartzConfig = { secondary: "#7b97aa", tertiary: "#84a59d", highlight: "rgba(143, 159, 169, 0.15)", + textHighlight: "#b3aa0288", }, }, }, diff --git a/quartz.layout.ts b/quartz.layout.ts index 31d08ac..50c3e53 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: { "Ryan's Namepage": "https://ryankes.eu", 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 (