Merge branch 'jackyzha0:v4' into v4

This commit is contained in:
Stefan Genov 2026-01-08 21:24:22 +02:00 committed by GitHub
commit 34ca053936
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 24 additions and 4 deletions

View File

@ -3,7 +3,6 @@
> “[One] who works with the door open gets all kinds of interruptions, but [they] also occasionally gets clues as to what the world is and what might be important.” — Richard Hamming > “[One] who works with the door open gets all kinds of interruptions, but [they] also occasionally gets clues as to what the world is and what might be important.” — Richard Hamming
Quartz is a set of tools that helps you publish your [digital garden](https://jzhao.xyz/posts/networked-thought) and notes as a website for free. Quartz is a set of tools that helps you publish your [digital garden](https://jzhao.xyz/posts/networked-thought) and notes as a website for free.
Quartz v4 features a from-the-ground rewrite focusing on end-user extensibility and ease-of-use.
🔗 Read the documentation and get started: https://quartz.jzhao.xyz/ 🔗 Read the documentation and get started: https://quartz.jzhao.xyz/

View File

@ -5,3 +5,7 @@ You can run the below one-liner to run Quartz in Docker.
```sh ```sh
docker run --rm -itp 8080:8080 -p 3001:3001 -v ./content:/usr/src/app/content $(docker build -q .) docker run --rm -itp 8080:8080 -p 3001:3001 -v ./content:/usr/src/app/content $(docker build -q .)
``` ```
> [!warning] Not to be used for production
> Serve mode is intended for local previews only.
> For production workloads, see the page on [[hosting]].

View File

@ -8,7 +8,7 @@ By default, Quartz only fetches previews for pages inside your vault due to [COR
When [[creating components|creating your own components]], you can include this `popover-hint` class to also include it in the popover. When [[creating components|creating your own components]], you can include this `popover-hint` class to also include it in the popover.
Similar to Obsidian, [[quartz layout.png|images referenced using wikilinks]] can also be viewed as popups. Similar to Obsidian, [[quartz-layout-desktop.png|images referenced using wikilinks]] can also be viewed as popups.
## Configuration ## Configuration

View File

@ -111,6 +111,10 @@ function createFolderNode(
const folderPath = node.slug const folderPath = node.slug
folderContainer.dataset.folderpath = folderPath folderContainer.dataset.folderpath = folderPath
if (currentSlug === folderPath) {
folderContainer.classList.add("active")
}
if (opts.folderClickBehavior === "link") { if (opts.folderClickBehavior === "link") {
// Replace button with link for link behavior // Replace button with link for link behavior
const button = titleContainer.querySelector(".folder-button") as HTMLElement const button = titleContainer.querySelector(".folder-button") as HTMLElement

View File

@ -23,7 +23,16 @@ export const Citations: QuartzTransformerPlugin<Partial<Options>> = (userOpts) =
name: "Citations", name: "Citations",
htmlPlugins(ctx) { htmlPlugins(ctx) {
const plugins: PluggableList = [] const plugins: PluggableList = []
// per default, rehype-citations only supports en-US
// see: https://github.com/timlrx/rehype-citation/issues/12
// in here there are multiple usable locales:
// https://github.com/citation-style-language/locales
// thus, we optimistically assume there is indeed an appropriate
// locale available and simply create the lang url-string
let lang: string = "en-US"
if (ctx.cfg.configuration.locale !== "en-US") {
lang = `https://raw.githubusercontent.com/citation-stylelanguage/locales/refs/heads/master/locales-${ctx.cfg.configuration.locale}.xml`
}
// Add rehype-citation to the list of plugins // Add rehype-citation to the list of plugins
plugins.push([ plugins.push([
rehypeCitation, rehypeCitation,
@ -32,7 +41,7 @@ export const Citations: QuartzTransformerPlugin<Partial<Options>> = (userOpts) =
suppressBibliography: opts.suppressBibliography, suppressBibliography: opts.suppressBibliography,
linkCitations: opts.linkCitations, linkCitations: opts.linkCitations,
csl: opts.csl, csl: opts.csl,
lang: ctx.cfg.configuration.locale ?? "en-US", lang,
}, },
]) ])

View File

@ -9,6 +9,10 @@ html {
text-size-adjust: none; text-size-adjust: none;
overflow-x: hidden; overflow-x: hidden;
width: 100vw; width: 100vw;
@media all and ($mobile) {
scroll-padding-top: 4rem;
}
} }
body { body {