Skip to content

Commit 10d6eb8

Browse files
MasssiveJuice088bitgentlemandependabot[bot]jackyzha0bfahrenfort
authored
Update Quartz to 9cefcd0 (#99)
* feat(markdown): Roam Research flavour (#985) * feat: Roam Research flavor markdown * docs: Roam Research transformer * use markdownPlugins * fix roam matching * cleanup: Roam Plugin --------- Co-authored-by: Matt Vogel <> * chore(deps): bump pixi.js from 8.3.3 to 8.3.4 (#1394) Bumps [pixi.js](https://github.com/pixijs/pixijs) from 8.3.3 to 8.3.4. - [Release notes](https://github.com/pixijs/pixijs/releases) - [Commits](pixijs/pixijs@v8.3.3...v8.3.4) --- updated-dependencies: - dependency-name: pixi.js dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore(deps-dev): bump @types/node from 22.5.0 to 22.5.4 (#1403) Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 22.5.0 to 22.5.4. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node) --- updated-dependencies: - dependency-name: "@types/node" dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore(deps): bump hast-util-to-html from 9.0.1 to 9.0.2 (#1393) Bumps [hast-util-to-html](https://github.com/syntax-tree/hast-util-to-html) from 9.0.1 to 9.0.2. - [Release notes](https://github.com/syntax-tree/hast-util-to-html/releases) - [Commits](syntax-tree/hast-util-to-html@9.0.1...9.0.2) --- updated-dependencies: - dependency-name: hast-util-to-html dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore(deps-dev): bump tsx from 4.18.0 to 4.19.0 (#1391) Bumps [tsx](https://github.com/privatenumber/tsx) from 4.18.0 to 4.19.0. - [Release notes](https://github.com/privatenumber/tsx/releases) - [Changelog](https://github.com/privatenumber/tsx/blob/master/release.config.cjs) - [Commits](privatenumber/tsx@v4.18.0...v4.19.0) --- updated-dependencies: - dependency-name: tsx dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * docs: fix roam research docs * chore(deps): bump preact-render-to-string from 6.5.9 to 6.5.10 (#1390) Bumps [preact-render-to-string](https://github.com/preactjs/preact-render-to-string) from 6.5.9 to 6.5.10. - [Release notes](https://github.com/preactjs/preact-render-to-string/releases) - [Changelog](https://github.com/preactjs/preact-render-to-string/blob/main/CHANGELOG.md) - [Commits](preactjs/preact-render-to-string@v6.5.9...v6.5.10) --- updated-dependencies: - dependency-name: preact-render-to-string dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * fix: constrain link icon size (#1409) * MMW: remove Quartz Docs Remove Roam Research docs * fix: account for subtags in numerical tags (closes #1408) (#1410) * perf: have more than 1ms granularity for rebuild detection * docs: clarify prod hosting * Add alexanderweichart.de to showcase.md (#1378) Added my own website ^^ Co-authored-by: Jacky Zhao <[email protected]> * perf: eagerly compute explorer nodes to avoid re-render in memoized value * chore(deps): bump vfile from 6.0.2 to 6.0.3 (#1421) Bumps [vfile](https://github.com/vfile/vfile) from 6.0.2 to 6.0.3. - [Release notes](https://github.com/vfile/vfile/releases) - [Changelog](https://github.com/vfile/vfile/blob/main/changelog.md) - [Commits](vfile/vfile@6.0.2...6.0.3) --- updated-dependencies: - dependency-name: vfile dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore(deps-dev): bump @types/node from 22.5.4 to 22.5.5 (#1420) Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 22.5.4 to 22.5.5. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node) --- updated-dependencies: - dependency-name: "@types/node" dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore(deps): bump preact from 10.23.2 to 10.24.0 (#1419) Bumps [preact](https://github.com/preactjs/preact) from 10.23.2 to 10.24.0. - [Release notes](https://github.com/preactjs/preact/releases) - [Commits](preactjs/preact@10.23.2...10.24.0) --- updated-dependencies: - dependency-name: preact dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore(deps-dev): bump typescript from 5.5.4 to 5.6.2 (#1418) Bumps [typescript](https://github.com/microsoft/TypeScript) from 5.5.4 to 5.6.2. - [Release notes](https://github.com/microsoft/TypeScript/releases) - [Changelog](https://github.com/microsoft/TypeScript/blob/main/azure-pipelines.release.yml) - [Commits](microsoft/TypeScript@v5.5.4...v5.6.2) --- updated-dependencies: - dependency-name: typescript dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore(deps): bump preact-render-to-string from 6.5.10 to 6.5.11 (#1417) Bumps [preact-render-to-string](https://github.com/preactjs/preact-render-to-string) from 6.5.10 to 6.5.11. - [Release notes](https://github.com/preactjs/preact-render-to-string/releases) - [Changelog](https://github.com/preactjs/preact-render-to-string/blob/main/CHANGELOG.md) - [Commits](preactjs/preact-render-to-string@v6.5.10...v6.5.11) --- updated-dependencies: - dependency-name: preact-render-to-string dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * update cabin url (#1428) * Revert "perf: eagerly compute explorer nodes to avoid re-render in memoized value" This reverts commit 16a9caa555a2d63b7ff8af0731fbfd3231d6225c. --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: Matt Vogel <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jacky Zhao <[email protected]> Co-authored-by: bfahrenfort <[email protected]> Co-authored-by: Emile Bangma <[email protected]> Co-authored-by: Alexander Weichart <[email protected]> Co-authored-by: Gustavo de Paula <[email protected]>
1 parent a2a3a32 commit 10d6eb8

File tree

8 files changed

+281
-56
lines changed

8 files changed

+281
-56
lines changed

package-lock.json

Lines changed: 32 additions & 35 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
"github-slugger": "^2.0.0",
5050
"globby": "^14.0.2",
5151
"gray-matter": "^4.0.3",
52-
"hast-util-to-html": "^9.0.1",
52+
"hast-util-to-html": "^9.0.2",
5353
"hast-util-to-jsx-runtime": "^2.3.0",
5454
"hast-util-to-string": "^3.0.0",
5555
"is-absolute-url": "^4.0.1",
@@ -59,9 +59,9 @@
5959
"mdast-util-to-hast": "^13.2.0",
6060
"mdast-util-to-string": "^4.0.0",
6161
"micromorph": "^0.4.5",
62-
"pixi.js": "^8.3.3",
63-
"preact": "^10.23.2",
64-
"preact-render-to-string": "^6.5.9",
62+
"pixi.js": "^8.3.4",
63+
"preact": "^10.24.0",
64+
"preact-render-to-string": "^6.5.11",
6565
"pretty-bytes": "^6.1.1",
6666
"pretty-time": "^1.1.0",
6767
"reading-time": "^1.5.0",
@@ -89,7 +89,7 @@
8989
"toml": "^3.0.0",
9090
"unified": "^11.0.5",
9191
"unist-util-visit": "^5.0.0",
92-
"vfile": "^6.0.2",
92+
"vfile": "^6.0.3",
9393
"workerpool": "^9.1.3",
9494
"ws": "^8.18.0",
9595
"yargs": "^17.7.2"
@@ -99,14 +99,14 @@
9999
"@types/d3": "^7.4.3",
100100
"@types/hast": "^3.0.4",
101101
"@types/js-yaml": "^4.0.9",
102-
"@types/node": "^22.5.0",
102+
"@types/node": "^22.5.5",
103103
"@types/pretty-time": "^1.1.5",
104104
"@types/source-map-support": "^0.5.10",
105105
"@types/ws": "^8.5.12",
106106
"@types/yargs": "^17.0.33",
107107
"esbuild": "^0.19.9",
108108
"prettier": "^3.3.3",
109-
"tsx": "^4.18.0",
110-
"typescript": "^5.5.4"
109+
"tsx": "^4.19.0",
110+
"typescript": "^5.6.2"
111111
}
112112
}

quartz/build.ts

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ type BuildData = {
3939
type FileEvent = "add" | "change" | "delete"
4040

4141
function newBuildId() {
42-
return new Date().toISOString()
42+
return Math.random().toString(36).substring(2, 8)
4343
}
4444

4545
async function buildQuartz(argv: Argv, mut: Mutex, clientRefresh: () => void) {
@@ -162,17 +162,19 @@ async function partialRebuildFromEntrypoint(
162162
return
163163
}
164164

165-
const buildStart = new Date().getTime()
166-
buildData.lastBuildMs = buildStart
165+
const buildId = newBuildId()
166+
ctx.buildId = buildId
167+
buildData.lastBuildMs = new Date().getTime()
167168
const release = await mut.acquire()
168-
if (buildData.lastBuildMs > buildStart) {
169+
170+
// if there's another build after us, release and let them do it
171+
if (ctx.buildId !== buildId) {
169172
release()
170173
return
171174
}
172175

173176
const perf = new PerfTimer()
174177
console.log(chalk.yellow("Detected change, rebuilding..."))
175-
ctx.buildId = newBuildId()
176178

177179
// UPDATE DEP GRAPH
178180
const fp = joinSegments(argv.directory, toPosixPath(filepath)) as FilePath
@@ -357,19 +359,19 @@ async function rebuildFromEntrypoint(
357359
toRemove.add(filePath)
358360
}
359361

360-
const buildStart = new Date().getTime()
361-
buildData.lastBuildMs = buildStart
362+
const buildId = newBuildId()
363+
ctx.buildId = buildId
364+
buildData.lastBuildMs = new Date().getTime()
362365
const release = await mut.acquire()
363366

364367
// there's another build after us, release and let them do it
365-
if (buildData.lastBuildMs > buildStart) {
368+
if (ctx.buildId !== buildId) {
366369
release()
367370
return
368371
}
369372

370373
const perf = new PerfTimer()
371374
console.log(chalk.yellow("Detected change, rebuilding..."))
372-
ctx.buildId = newBuildId()
373375

374376
try {
375377
const filesToRebuild = [...toRebuild].filter((fp) => !toRemove.has(fp))
@@ -405,10 +407,10 @@ async function rebuildFromEntrypoint(
405407
}
406408
}
407409

408-
release()
409410
clientRefresh()
410411
toRebuild.clear()
411412
toRemove.clear()
413+
release()
412414
}
413415

414416
export default async (argv: Argv, mut: Mutex, clientRefresh: () => void) => {

quartz/plugins/emitters/componentResources.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ function addGlobalPageResources(ctx: BuildCtx, componentResources: ComponentReso
147147
} else if (cfg.analytics?.provider === "cabin") {
148148
componentResources.afterDOMLoaded.push(`
149149
const cabinScript = document.createElement("script")
150-
cabinScript.src = "${cfg.analytics.host ?? "https://scripts.cabin.dev"}/cabin.js"
150+
cabinScript.src = "${cfg.analytics.host ?? "https://scripts.withcabin.com"}/hello.js"
151151
cabinScript.defer = true
152152
cabinScript.async = true
153153
document.head.appendChild(cabinScript)

quartz/plugins/transformers/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,4 @@ export { SyntaxHighlighting } from "./syntax"
1111
export { TableOfContents } from "./toc"
1212
export { TableOfContents2 } from "./toc2"
1313
export { HardLineBreaks } from "./linebreaks"
14+
export { RoamFlavoredMarkdown } from "./roam"

quartz/plugins/transformers/links.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ export const CrawlLinks: QuartzTransformerPlugin<Partial<Options>> = (userOpts)
6767
properties: {
6868
"aria-hidden": "true",
6969
class: "external-icon",
70+
style: "max-width:0.8em;max-height:0.8em",
7071
viewBox: "0 0 512 512",
7172
},
7273
children: [

quartz/plugins/transformers/ofm.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -332,8 +332,8 @@ export const ObsidianFlavoredMarkdown: QuartzTransformerPlugin<Partial<Options>>
332332
replacements.push([
333333
tagRegex,
334334
(_value: string, tag: string) => {
335-
// Check if the tag only includes numbers
336-
if (/^\d+$/.test(tag)) {
335+
// Check if the tag only includes numbers and slashes
336+
if (/^[\/\d]+$/.test(tag)) {
337337
return false
338338
}
339339

0 commit comments

Comments
 (0)