Compare commits
No commits in common. "b8787f05d677313a845024d833f5283dbb1d1ee0" and "c98ef7e89f2c63d417d2c9ae364c56308f8501fc" have entirely different histories.
b8787f05d6
...
c98ef7e89f
20 changed files with 178 additions and 2539 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
|
@ -5,7 +5,7 @@ public
|
||||||
prof
|
prof
|
||||||
tsconfig.tsbuildinfo
|
tsconfig.tsbuildinfo
|
||||||
.obsidian
|
.obsidian
|
||||||
|
.quartz-cache
|
||||||
private/
|
private/
|
||||||
.replit
|
.replit
|
||||||
replit.nix
|
replit.nix
|
||||||
result
|
|
||||||
|
|
|
||||||
|
|
@ -1,10 +0,0 @@
|
||||||
---
|
|
||||||
title: Example Title
|
|
||||||
draft: false
|
|
||||||
tags:
|
|
||||||
- example-tag
|
|
||||||
date: 2025-01-10
|
|
||||||
---
|
|
||||||
Hello World!
|
|
||||||
|
|
||||||
[heres the todo](https://quartz.jzhao.xyz/authoring-content)
|
|
||||||
61
flake.lock
generated
61
flake.lock
generated
|
|
@ -1,61 +0,0 @@
|
||||||
{
|
|
||||||
"nodes": {
|
|
||||||
"flake-utils": {
|
|
||||||
"inputs": {
|
|
||||||
"systems": "systems"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1731533236,
|
|
||||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "flake-utils",
|
|
||||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "flake-utils",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1737469691,
|
|
||||||
"narHash": "sha256-nmKOgAU48S41dTPIXAq0AHZSehWUn6ZPrUKijHAMmIk=",
|
|
||||||
"owner": "nixos",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "9e4d5190a9482a1fb9d18adf0bdb83c6e506eaab",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nixos",
|
|
||||||
"ref": "nixos-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"root": {
|
|
||||||
"inputs": {
|
|
||||||
"flake-utils": "flake-utils",
|
|
||||||
"nixpkgs": "nixpkgs"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"systems": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1681028828,
|
|
||||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
|
||||||
"owner": "nix-systems",
|
|
||||||
"repo": "default",
|
|
||||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nix-systems",
|
|
||||||
"repo": "default",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"root": "root",
|
|
||||||
"version": 7
|
|
||||||
}
|
|
||||||
37
flake.nix
37
flake.nix
|
|
@ -1,37 +0,0 @@
|
||||||
{
|
|
||||||
description = "";
|
|
||||||
|
|
||||||
inputs.nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
|
||||||
inputs.flake-utils.url = "github:numtide/flake-utils";
|
|
||||||
|
|
||||||
outputs = {
|
|
||||||
self,
|
|
||||||
nixpkgs,
|
|
||||||
flake-utils,
|
|
||||||
}: (
|
|
||||||
flake-utils.lib.eachDefaultSystem
|
|
||||||
(system: let
|
|
||||||
pkgs = nixpkgs.legacyPackages.${system};
|
|
||||||
quartz = self.packages."${system}".quartz;
|
|
||||||
inherit self;
|
|
||||||
in {
|
|
||||||
packages.default = pkgs.stdenv.mkDerivation {
|
|
||||||
name = "quartz-site";
|
|
||||||
src = ./.;
|
|
||||||
buildPhase = ''
|
|
||||||
ln -s ${quartz}/lib/node_modules/@jackyzha0/quartz/node_modules node_modules
|
|
||||||
${quartz}/bin/quartz build
|
|
||||||
'';
|
|
||||||
installPhase = ''
|
|
||||||
cp -r public $out
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
packages.quartz = pkgs.buildNpmPackage {
|
|
||||||
name = "quartz";
|
|
||||||
src = ./.;
|
|
||||||
npmDepsHash = "sha256-hawMRXs2VvIeZ7hP8NZDBU8yqg/f2cTzmGEvn+VzjE4=";
|
|
||||||
dontNpmBuild = true;
|
|
||||||
};
|
|
||||||
})
|
|
||||||
);
|
|
||||||
}
|
|
||||||
269
package-lock.json
generated
269
package-lock.json
generated
|
|
@ -9,8 +9,8 @@
|
||||||
"version": "4.4.0",
|
"version": "4.4.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@clack/prompts": "^0.9.1",
|
"@clack/prompts": "^0.9.0",
|
||||||
"@floating-ui/dom": "^1.6.13",
|
"@floating-ui/dom": "^1.6.12",
|
||||||
"@myriaddreamin/rehype-typst": "^0.5.4",
|
"@myriaddreamin/rehype-typst": "^0.5.4",
|
||||||
"@napi-rs/simple-git": "0.1.19",
|
"@napi-rs/simple-git": "0.1.19",
|
||||||
"@tweenjs/tween.js": "^25.0.0",
|
"@tweenjs/tween.js": "^25.0.0",
|
||||||
|
|
@ -29,14 +29,14 @@
|
||||||
"hast-util-to-string": "^3.0.1",
|
"hast-util-to-string": "^3.0.1",
|
||||||
"is-absolute-url": "^4.0.1",
|
"is-absolute-url": "^4.0.1",
|
||||||
"js-yaml": "^4.1.0",
|
"js-yaml": "^4.1.0",
|
||||||
"lightningcss": "^1.29.1",
|
"lightningcss": "^1.28.2",
|
||||||
"mdast-util-find-and-replace": "^3.0.2",
|
"mdast-util-find-and-replace": "^3.0.1",
|
||||||
"mdast-util-to-hast": "^13.2.0",
|
"mdast-util-to-hast": "^13.2.0",
|
||||||
"mdast-util-to-string": "^4.0.0",
|
"mdast-util-to-string": "^4.0.0",
|
||||||
"micromorph": "^0.4.5",
|
"micromorph": "^0.4.5",
|
||||||
"pixi.js": "^8.6.6",
|
"pixi.js": "^8.6.6",
|
||||||
"preact": "^10.25.4",
|
"preact": "^10.25.4",
|
||||||
"preact-render-to-string": "^6.5.13",
|
"preact-render-to-string": "^6.5.12",
|
||||||
"pretty-bytes": "^6.1.1",
|
"pretty-bytes": "^6.1.1",
|
||||||
"pretty-time": "^1.1.0",
|
"pretty-time": "^1.1.0",
|
||||||
"reading-time": "^1.5.0",
|
"reading-time": "^1.5.0",
|
||||||
|
|
@ -57,10 +57,10 @@
|
||||||
"remark-smartypants": "^3.0.2",
|
"remark-smartypants": "^3.0.2",
|
||||||
"rfdc": "^1.4.1",
|
"rfdc": "^1.4.1",
|
||||||
"rimraf": "^6.0.1",
|
"rimraf": "^6.0.1",
|
||||||
"satori": "^0.12.1",
|
"satori": "^0.12.0",
|
||||||
"serve-handler": "^6.1.6",
|
"serve-handler": "^6.1.6",
|
||||||
"sharp": "^0.33.5",
|
"sharp": "^0.33.5",
|
||||||
"shiki": "^1.26.2",
|
"shiki": "^1.24.4",
|
||||||
"source-map-support": "^0.5.21",
|
"source-map-support": "^0.5.21",
|
||||||
"to-vfile": "^8.0.0",
|
"to-vfile": "^8.0.0",
|
||||||
"toml": "^3.0.0",
|
"toml": "^3.0.0",
|
||||||
|
|
@ -79,7 +79,7 @@
|
||||||
"@types/d3": "^7.4.3",
|
"@types/d3": "^7.4.3",
|
||||||
"@types/hast": "^3.0.4",
|
"@types/hast": "^3.0.4",
|
||||||
"@types/js-yaml": "^4.0.9",
|
"@types/js-yaml": "^4.0.9",
|
||||||
"@types/node": "^22.10.6",
|
"@types/node": "^22.10.2",
|
||||||
"@types/pretty-time": "^1.1.5",
|
"@types/pretty-time": "^1.1.5",
|
||||||
"@types/source-map-support": "^0.5.10",
|
"@types/source-map-support": "^0.5.10",
|
||||||
"@types/ws": "^8.5.13",
|
"@types/ws": "^8.5.13",
|
||||||
|
|
@ -87,7 +87,7 @@
|
||||||
"esbuild": "^0.24.2",
|
"esbuild": "^0.24.2",
|
||||||
"prettier": "^3.4.2",
|
"prettier": "^3.4.2",
|
||||||
"tsx": "^4.19.2",
|
"tsx": "^4.19.2",
|
||||||
"typescript": "^5.7.3"
|
"typescript": "^5.7.2"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": "20 || >=22",
|
"node": "20 || >=22",
|
||||||
|
|
@ -187,20 +187,20 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@clack/core": {
|
"node_modules/@clack/core": {
|
||||||
"version": "0.4.1",
|
"version": "0.4.0",
|
||||||
"resolved": "https://registry.npmjs.org/@clack/core/-/core-0.4.1.tgz",
|
"resolved": "https://registry.npmjs.org/@clack/core/-/core-0.4.0.tgz",
|
||||||
"integrity": "sha512-Pxhij4UXg8KSr7rPek6Zowm+5M22rbd2g1nfojHJkxp5YkFqiZ2+YLEM/XGVIzvGOcM0nqjIFxrpDwWRZYWYjA==",
|
"integrity": "sha512-YJCYBsyJfNDaTbvDUVSJ3SgSuPrcujarRgkJ5NLjexDZKvaOiVVJvAQYx8lIgG0qRT8ff0fPgqyBCVivanIZ+A==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"picocolors": "^1.0.0",
|
"picocolors": "^1.0.0",
|
||||||
"sisteransi": "^1.0.5"
|
"sisteransi": "^1.0.5"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@clack/prompts": {
|
"node_modules/@clack/prompts": {
|
||||||
"version": "0.9.1",
|
"version": "0.9.0",
|
||||||
"resolved": "https://registry.npmjs.org/@clack/prompts/-/prompts-0.9.1.tgz",
|
"resolved": "https://registry.npmjs.org/@clack/prompts/-/prompts-0.9.0.tgz",
|
||||||
"integrity": "sha512-JIpyaboYZeWYlyP0H+OoPPxd6nqueG/CmN6ixBiNFsIDHREevjIf0n0Ohh5gr5C8pEDknzgvz+pIJ8dMhzWIeg==",
|
"integrity": "sha512-nGsytiExgUr4FL0pR/LeqxA28nz3E0cW7eLTSh3Iod9TGrbBt8Y7BHbV3mmkNC4G0evdYyQ3ZsbiBkk7ektArA==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@clack/core": "0.4.1",
|
"@clack/core": "0.4.0",
|
||||||
"picocolors": "^1.0.0",
|
"picocolors": "^1.0.0",
|
||||||
"sisteransi": "^1.0.5"
|
"sisteransi": "^1.0.5"
|
||||||
}
|
}
|
||||||
|
|
@ -600,18 +600,18 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@floating-ui/dom": {
|
"node_modules/@floating-ui/dom": {
|
||||||
"version": "1.6.13",
|
"version": "1.6.12",
|
||||||
"resolved": "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.6.13.tgz",
|
"resolved": "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.6.12.tgz",
|
||||||
"integrity": "sha512-umqzocjDgNRGTuO7Q8CU32dkHkECqI8ZdMZ5Swb6QAM0t5rnlrN3lGo1hdpscRd3WS8T6DKYK4ephgIH9iRh3w==",
|
"integrity": "sha512-NP83c0HjokcGVEMeoStg317VD9W7eDlGK7457dMBANbKA6GJZdc7rjujdgqzTaz93jkGgc5P/jeWbaCHnMNc+w==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@floating-ui/core": "^1.6.0",
|
"@floating-ui/core": "^1.6.0",
|
||||||
"@floating-ui/utils": "^0.2.9"
|
"@floating-ui/utils": "^0.2.8"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@floating-ui/utils": {
|
"node_modules/@floating-ui/utils": {
|
||||||
"version": "0.2.9",
|
"version": "0.2.8",
|
||||||
"resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.2.9.tgz",
|
"resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.2.8.tgz",
|
||||||
"integrity": "sha512-MDWhGtE+eHw5JW7lq4qhc5yRLS11ERl1c7Z6Xd0a58DozHES6EnNNwUWbMiG4J9Cgj053Bhk8zvlhFYKVhULwg=="
|
"integrity": "sha512-kym7SodPp8/wloecOpcmSnWJsK7M0E5Wg8UcFA+uO4B9s5d0ywXOEro/8HM9x0rW+TljRzul/14UYz3TleT3ig=="
|
||||||
},
|
},
|
||||||
"node_modules/@img/sharp-darwin-arm64": {
|
"node_modules/@img/sharp-darwin-arm64": {
|
||||||
"version": "0.33.5",
|
"version": "0.33.5",
|
||||||
|
|
@ -1473,66 +1473,50 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@shikijs/core": {
|
"node_modules/@shikijs/core": {
|
||||||
"version": "1.26.2",
|
"version": "1.24.4",
|
||||||
"resolved": "https://registry.npmjs.org/@shikijs/core/-/core-1.26.2.tgz",
|
"resolved": "https://registry.npmjs.org/@shikijs/core/-/core-1.24.4.tgz",
|
||||||
"integrity": "sha512-ORyu3MrY7dCC7FDLDsFSkBM9b/AT9/Y8rH+UQ07Rtek48pp0ZhQOMPTKolqszP4bBCas6FqTZQYt18BBamVl/g==",
|
"integrity": "sha512-jjLsld+xEEGYlxAXDyGwWsKJ1sw5Pc1pnp4ai2ORpjx2UX08YYTC0NNqQYO1PaghYaR+PvgMOGuvzw2he9sk0Q==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@shikijs/engine-javascript": "1.26.2",
|
"@shikijs/engine-javascript": "1.24.4",
|
||||||
"@shikijs/engine-oniguruma": "1.26.2",
|
"@shikijs/engine-oniguruma": "1.24.4",
|
||||||
"@shikijs/types": "1.26.2",
|
"@shikijs/types": "1.24.4",
|
||||||
"@shikijs/vscode-textmate": "^10.0.1",
|
"@shikijs/vscode-textmate": "^9.3.1",
|
||||||
"@types/hast": "^3.0.4",
|
"@types/hast": "^3.0.4",
|
||||||
"hast-util-to-html": "^9.0.4"
|
"hast-util-to-html": "^9.0.4"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@shikijs/engine-javascript": {
|
"node_modules/@shikijs/engine-javascript": {
|
||||||
"version": "1.26.2",
|
"version": "1.24.4",
|
||||||
"resolved": "https://registry.npmjs.org/@shikijs/engine-javascript/-/engine-javascript-1.26.2.tgz",
|
"resolved": "https://registry.npmjs.org/@shikijs/engine-javascript/-/engine-javascript-1.24.4.tgz",
|
||||||
"integrity": "sha512-ngkIu9swLVo9Zt5QBtz5Sk08vmPcwuj01r7pPK/Zjmo2U2WyKMK4WMUMmkdQiUacdcLth0zt8u1onp4zhkFXKQ==",
|
"integrity": "sha512-TClaQOLvo9WEMJv6GoUsykQ6QdynuKszuORFWCke8qvi6PeLm7FcD9+7y45UenysxEWYpDL5KJaVXTngTE+2BA==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@shikijs/types": "1.26.2",
|
"@shikijs/types": "1.24.4",
|
||||||
"@shikijs/vscode-textmate": "^10.0.1",
|
"@shikijs/vscode-textmate": "^9.3.1",
|
||||||
"oniguruma-to-es": "^1.0.0"
|
"oniguruma-to-es": "0.8.1"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@shikijs/engine-oniguruma": {
|
"node_modules/@shikijs/engine-oniguruma": {
|
||||||
"version": "1.26.2",
|
"version": "1.24.4",
|
||||||
"resolved": "https://registry.npmjs.org/@shikijs/engine-oniguruma/-/engine-oniguruma-1.26.2.tgz",
|
"resolved": "https://registry.npmjs.org/@shikijs/engine-oniguruma/-/engine-oniguruma-1.24.4.tgz",
|
||||||
"integrity": "sha512-mlN7Qrs+w60nKrd7at7XkXSwz6728Pe34taDmHrG6LRHjzCqQ+ysg+/AT6/D2LMk0s2lsr71DjpI73430QP4/w==",
|
"integrity": "sha512-Do2ry6flp2HWdvpj2XOwwa0ljZBRy15HKZITzPcNIBOGSeprnA8gOooA/bLsSPuy8aJBa+Q/r34dMmC3KNL/zw==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@shikijs/types": "1.26.2",
|
"@shikijs/types": "1.24.4",
|
||||||
"@shikijs/vscode-textmate": "^10.0.1"
|
"@shikijs/vscode-textmate": "^9.3.1"
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@shikijs/langs": {
|
|
||||||
"version": "1.26.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/@shikijs/langs/-/langs-1.26.2.tgz",
|
|
||||||
"integrity": "sha512-o5cdPycB2Kw3IgncHxWopWPiTkjAj7dG01fLkkUyj3glb5ftxL/Opecq9F54opMlrgXy7ZIqDERvFLlUzsCOuA==",
|
|
||||||
"dependencies": {
|
|
||||||
"@shikijs/types": "1.26.2"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@shikijs/themes": {
|
|
||||||
"version": "1.26.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/@shikijs/themes/-/themes-1.26.2.tgz",
|
|
||||||
"integrity": "sha512-y4Pn6PM5mODz/e3yF6jAUG7WLKJzqL2tJ5qMJCUkMUB1VRgtQVvoa1cHh7NScryGXyrYGJ8nPnRDhdv2rw0xpA==",
|
|
||||||
"dependencies": {
|
|
||||||
"@shikijs/types": "1.26.2"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@shikijs/types": {
|
"node_modules/@shikijs/types": {
|
||||||
"version": "1.26.2",
|
"version": "1.24.4",
|
||||||
"resolved": "https://registry.npmjs.org/@shikijs/types/-/types-1.26.2.tgz",
|
"resolved": "https://registry.npmjs.org/@shikijs/types/-/types-1.24.4.tgz",
|
||||||
"integrity": "sha512-PO2jucx2FIdlLBPYbIUlMtWSLs5ulcRcuV93cR3T65lkK5SJP4MGBRt9kmWGXiQc0f7+FHj/0BEawditZcI/fQ==",
|
"integrity": "sha512-0r0XU7Eaow0PuDxuWC1bVqmWCgm3XqizIaT7SM42K03vc69LGooT0U8ccSR44xP/hGlNx4FKhtYpV+BU6aaKAA==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@shikijs/vscode-textmate": "^10.0.1",
|
"@shikijs/vscode-textmate": "^9.3.1",
|
||||||
"@types/hast": "^3.0.4"
|
"@types/hast": "^3.0.4"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@shikijs/vscode-textmate": {
|
"node_modules/@shikijs/vscode-textmate": {
|
||||||
"version": "10.0.1",
|
"version": "9.3.1",
|
||||||
"resolved": "https://registry.npmjs.org/@shikijs/vscode-textmate/-/vscode-textmate-10.0.1.tgz",
|
"resolved": "https://registry.npmjs.org/@shikijs/vscode-textmate/-/vscode-textmate-9.3.1.tgz",
|
||||||
"integrity": "sha512-fTIQwLF+Qhuws31iw7Ncl1R3HUDtGwIipiJ9iU+UsDUwMhegFcQKQHd51nZjb7CArq0MvON8rbgCGQYWHUKAdg=="
|
"integrity": "sha512-79QfK1393x9Ho60QFyLti+QfdJzRQCVLFb97kOIV7Eo9vQU/roINgk7m24uv0a7AUvN//RDH36FLjjK48v0s9g=="
|
||||||
},
|
},
|
||||||
"node_modules/@shuding/opentype.js": {
|
"node_modules/@shuding/opentype.js": {
|
||||||
"version": "1.4.0-beta.0",
|
"version": "1.4.0-beta.0",
|
||||||
|
|
@ -1914,9 +1898,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@types/node": {
|
"node_modules/@types/node": {
|
||||||
"version": "22.10.6",
|
"version": "22.10.2",
|
||||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.6.tgz",
|
"resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.2.tgz",
|
||||||
"integrity": "sha512-qNiuwC4ZDAUNcY47xgaSuS92cjf8JbSUoaKS77bmLG1rU7MlATVSiw/IlrjtIyyskXBZ8KkNfjK/P5na7rgXbQ==",
|
"integrity": "sha512-Xxr6BBRCAOQixvonOye19wnzyDiUtTeqldOOmj3CkeblonbccA12PFwlufvRdrpjXxqnmUaeiU5EOA+7s5diUQ==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"undici-types": "~6.20.0"
|
"undici-types": "~6.20.0"
|
||||||
|
|
@ -4086,9 +4070,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/lightningcss": {
|
"node_modules/lightningcss": {
|
||||||
"version": "1.29.1",
|
"version": "1.28.2",
|
||||||
"resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.29.1.tgz",
|
"resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.28.2.tgz",
|
||||||
"integrity": "sha512-FmGoeD4S05ewj+AkhTY+D+myDvXI6eL27FjHIjoyUkO/uw7WZD1fBVs0QxeYWa7E17CUHJaYX/RUGISCtcrG4Q==",
|
"integrity": "sha512-ePLRrbt3fgjXI5VFZOLbvkLD5ZRuxGKm+wJ3ujCqBtL3NanDHPo/5zicR5uEKAPiIjBYF99BM4K4okvMznjkVA==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"detect-libc": "^1.0.3"
|
"detect-libc": "^1.0.3"
|
||||||
},
|
},
|
||||||
|
|
@ -4100,22 +4084,22 @@
|
||||||
"url": "https://opencollective.com/parcel"
|
"url": "https://opencollective.com/parcel"
|
||||||
},
|
},
|
||||||
"optionalDependencies": {
|
"optionalDependencies": {
|
||||||
"lightningcss-darwin-arm64": "1.29.1",
|
"lightningcss-darwin-arm64": "1.28.2",
|
||||||
"lightningcss-darwin-x64": "1.29.1",
|
"lightningcss-darwin-x64": "1.28.2",
|
||||||
"lightningcss-freebsd-x64": "1.29.1",
|
"lightningcss-freebsd-x64": "1.28.2",
|
||||||
"lightningcss-linux-arm-gnueabihf": "1.29.1",
|
"lightningcss-linux-arm-gnueabihf": "1.28.2",
|
||||||
"lightningcss-linux-arm64-gnu": "1.29.1",
|
"lightningcss-linux-arm64-gnu": "1.28.2",
|
||||||
"lightningcss-linux-arm64-musl": "1.29.1",
|
"lightningcss-linux-arm64-musl": "1.28.2",
|
||||||
"lightningcss-linux-x64-gnu": "1.29.1",
|
"lightningcss-linux-x64-gnu": "1.28.2",
|
||||||
"lightningcss-linux-x64-musl": "1.29.1",
|
"lightningcss-linux-x64-musl": "1.28.2",
|
||||||
"lightningcss-win32-arm64-msvc": "1.29.1",
|
"lightningcss-win32-arm64-msvc": "1.28.2",
|
||||||
"lightningcss-win32-x64-msvc": "1.29.1"
|
"lightningcss-win32-x64-msvc": "1.28.2"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/lightningcss-darwin-arm64": {
|
"node_modules/lightningcss-darwin-arm64": {
|
||||||
"version": "1.29.1",
|
"version": "1.28.2",
|
||||||
"resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.29.1.tgz",
|
"resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.28.2.tgz",
|
||||||
"integrity": "sha512-HtR5XJ5A0lvCqYAoSv2QdZZyoHNttBpa5EP9aNuzBQeKGfbyH5+UipLWvVzpP4Uml5ej4BYs5I9Lco9u1fECqw==",
|
"integrity": "sha512-/8cPSqZiusHSS+WQz0W4NuaqFjquys1x+NsdN/XOHb+idGHJSoJ7SoQTVl3DZuAgtPZwFZgRfb/vd1oi8uX6+g==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
|
@ -4132,9 +4116,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/lightningcss-darwin-x64": {
|
"node_modules/lightningcss-darwin-x64": {
|
||||||
"version": "1.29.1",
|
"version": "1.28.2",
|
||||||
"resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.29.1.tgz",
|
"resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.28.2.tgz",
|
||||||
"integrity": "sha512-k33G9IzKUpHy/J/3+9MCO4e+PzaFblsgBjSGlpAaFikeBFm8B/CkO3cKU9oI4g+fjS2KlkLM/Bza9K/aw8wsNA==",
|
"integrity": "sha512-R7sFrXlgKjvoEG8umpVt/yutjxOL0z8KWf0bfPT3cYMOW4470xu5qSHpFdIOpRWwl3FKNMUdbKtMUjYt0h2j4g==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
|
@ -4151,9 +4135,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/lightningcss-freebsd-x64": {
|
"node_modules/lightningcss-freebsd-x64": {
|
||||||
"version": "1.29.1",
|
"version": "1.28.2",
|
||||||
"resolved": "https://registry.npmjs.org/lightningcss-freebsd-x64/-/lightningcss-freebsd-x64-1.29.1.tgz",
|
"resolved": "https://registry.npmjs.org/lightningcss-freebsd-x64/-/lightningcss-freebsd-x64-1.28.2.tgz",
|
||||||
"integrity": "sha512-0SUW22fv/8kln2LnIdOCmSuXnxgxVC276W5KLTwoehiO0hxkacBxjHOL5EtHD8BAXg2BvuhsJPmVMasvby3LiQ==",
|
"integrity": "sha512-l2qrCT+x7crAY+lMIxtgvV10R8VurzHAoUZJaVFSlHrN8kRLTvEg9ObojIDIexqWJQvJcVVV3vfzsEynpiuvgA==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
|
@ -4170,9 +4154,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/lightningcss-linux-arm-gnueabihf": {
|
"node_modules/lightningcss-linux-arm-gnueabihf": {
|
||||||
"version": "1.29.1",
|
"version": "1.28.2",
|
||||||
"resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.29.1.tgz",
|
"resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.28.2.tgz",
|
||||||
"integrity": "sha512-sD32pFvlR0kDlqsOZmYqH/68SqUMPNj+0pucGxToXZi4XZgZmqeX/NkxNKCPsswAXU3UeYgDSpGhu05eAufjDg==",
|
"integrity": "sha512-DKMzpICBEKnL53X14rF7hFDu8KKALUJtcKdFUCW5YOlGSiwRSgVoRjM97wUm/E0NMPkzrTi/rxfvt7ruNK8meg==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"arm"
|
"arm"
|
||||||
],
|
],
|
||||||
|
|
@ -4189,9 +4173,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/lightningcss-linux-arm64-gnu": {
|
"node_modules/lightningcss-linux-arm64-gnu": {
|
||||||
"version": "1.29.1",
|
"version": "1.28.2",
|
||||||
"resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.29.1.tgz",
|
"resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.28.2.tgz",
|
||||||
"integrity": "sha512-0+vClRIZ6mmJl/dxGuRsE197o1HDEeeRk6nzycSy2GofC2JsY4ifCRnvUWf/CUBQmlrvMzt6SMQNMSEu22csWQ==",
|
"integrity": "sha512-nhfjYkfymWZSxdtTNMWyhFk2ImUm0X7NAgJWFwnsYPOfmtWQEapzG/DXZTfEfMjSzERNUNJoQjPAbdqgB+sjiw==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
|
@ -4208,9 +4192,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/lightningcss-linux-arm64-musl": {
|
"node_modules/lightningcss-linux-arm64-musl": {
|
||||||
"version": "1.29.1",
|
"version": "1.28.2",
|
||||||
"resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.29.1.tgz",
|
"resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.28.2.tgz",
|
||||||
"integrity": "sha512-UKMFrG4rL/uHNgelBsDwJcBqVpzNJbzsKkbI3Ja5fg00sgQnHw/VrzUTEc4jhZ+AN2BvQYz/tkHu4vt1kLuJyw==",
|
"integrity": "sha512-1SPG1ZTNnphWvAv8RVOymlZ8BDtAg69Hbo7n4QxARvkFVCJAt0cgjAw1Fox0WEhf4PwnyoOBaVH0Z5YNgzt4dA==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
|
@ -4227,9 +4211,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/lightningcss-linux-x64-gnu": {
|
"node_modules/lightningcss-linux-x64-gnu": {
|
||||||
"version": "1.29.1",
|
"version": "1.28.2",
|
||||||
"resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.29.1.tgz",
|
"resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.28.2.tgz",
|
||||||
"integrity": "sha512-u1S+xdODy/eEtjADqirA774y3jLcm8RPtYztwReEXoZKdzgsHYPl0s5V52Tst+GKzqjebkULT86XMSxejzfISw==",
|
"integrity": "sha512-ZhQy0FcO//INWUdo/iEdbefntTdpPVQ0XJwwtdbBuMQe+uxqZoytm9M+iqR9O5noWFaxK+nbS2iR/I80Q2Ofpg==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
|
@ -4246,9 +4230,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/lightningcss-linux-x64-musl": {
|
"node_modules/lightningcss-linux-x64-musl": {
|
||||||
"version": "1.29.1",
|
"version": "1.28.2",
|
||||||
"resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.29.1.tgz",
|
"resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.28.2.tgz",
|
||||||
"integrity": "sha512-L0Tx0DtaNUTzXv0lbGCLB/c/qEADanHbu4QdcNOXLIe1i8i22rZRpbT3gpWYsCh9aSL9zFujY/WmEXIatWvXbw==",
|
"integrity": "sha512-alb/j1NMrgQmSFyzTbN1/pvMPM+gdDw7YBuQ5VSgcFDypN3Ah0BzC2dTZbzwzaMdUVDszX6zH5MzjfVN1oGuww==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
|
@ -4265,9 +4249,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/lightningcss-win32-arm64-msvc": {
|
"node_modules/lightningcss-win32-arm64-msvc": {
|
||||||
"version": "1.29.1",
|
"version": "1.28.2",
|
||||||
"resolved": "https://registry.npmjs.org/lightningcss-win32-arm64-msvc/-/lightningcss-win32-arm64-msvc-1.29.1.tgz",
|
"resolved": "https://registry.npmjs.org/lightningcss-win32-arm64-msvc/-/lightningcss-win32-arm64-msvc-1.28.2.tgz",
|
||||||
"integrity": "sha512-QoOVnkIEFfbW4xPi+dpdft/zAKmgLgsRHfJalEPYuJDOWf7cLQzYg0DEh8/sn737FaeMJxHZRc1oBreiwZCjog==",
|
"integrity": "sha512-WnwcjcBeAt0jGdjlgbT9ANf30pF0C/QMb1XnLnH272DQU8QXh+kmpi24R55wmWBwaTtNAETZ+m35ohyeMiNt+g==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
|
@ -4284,9 +4268,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/lightningcss-win32-x64-msvc": {
|
"node_modules/lightningcss-win32-x64-msvc": {
|
||||||
"version": "1.29.1",
|
"version": "1.28.2",
|
||||||
"resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.29.1.tgz",
|
"resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.28.2.tgz",
|
||||||
"integrity": "sha512-NygcbThNBe4JElP+olyTI/doBNGJvLs3bFCRPdvuCcxZCcCZ71B858IHpdm7L1btZex0FvCmM17FK98Y9MRy1Q==",
|
"integrity": "sha512-3piBifyT3avz22o6mDKywQC/OisH2yDK+caHWkiMsF82i3m5wDBadyCjlCQ5VNgzYkxrWZgiaxHDdd5uxsi0/A==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
|
@ -4359,9 +4343,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/mdast-util-find-and-replace": {
|
"node_modules/mdast-util-find-and-replace": {
|
||||||
"version": "3.0.2",
|
"version": "3.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/mdast-util-find-and-replace/-/mdast-util-find-and-replace-3.0.2.tgz",
|
"resolved": "https://registry.npmjs.org/mdast-util-find-and-replace/-/mdast-util-find-and-replace-3.0.1.tgz",
|
||||||
"integrity": "sha512-Tmd1Vg/m3Xz43afeNxDIhWRtFZgM2VLyaf4vSTYwudTyeuTneoL3qtWMA5jeLyz/O1vDJmmV4QuScFCA2tBPwg==",
|
"integrity": "sha512-SG21kZHGC3XRTSUhtofZkBzZTJNM5ecCi0SK2IMKmSXR8vO3peL+kb1O0z7Zl83jKtutG4k5Wv/W7V3/YHvzPA==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@types/mdast": "^4.0.0",
|
"@types/mdast": "^4.0.0",
|
||||||
"escape-string-regexp": "^5.0.0",
|
"escape-string-regexp": "^5.0.0",
|
||||||
|
|
@ -5424,13 +5408,13 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/oniguruma-to-es": {
|
"node_modules/oniguruma-to-es": {
|
||||||
"version": "1.0.0",
|
"version": "0.8.1",
|
||||||
"resolved": "https://registry.npmjs.org/oniguruma-to-es/-/oniguruma-to-es-1.0.0.tgz",
|
"resolved": "https://registry.npmjs.org/oniguruma-to-es/-/oniguruma-to-es-0.8.1.tgz",
|
||||||
"integrity": "sha512-kihvp0O4lFwf5tZMkfanwQLIZ9ORe9OeOFgZonH0BQeThgwfJiaZFeOfvvJVnJIM9TiVmx0RDD35hUJDR0++rQ==",
|
"integrity": "sha512-dekySTEvCxCj0IgKcA2uUCO/e4ArsqpucDPcX26w9ajx+DvMWLc5eZeJaRQkd7oC/+rwif5gnT900tA34uN9Zw==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"emoji-regex-xs": "^1.0.0",
|
"emoji-regex-xs": "^1.0.0",
|
||||||
"regex": "^5.1.1",
|
"regex": "^5.0.2",
|
||||||
"regex-recursion": "^5.1.1"
|
"regex-recursion": "^5.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/package-json-from-dist": {
|
"node_modules/package-json-from-dist": {
|
||||||
|
|
@ -5614,9 +5598,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/preact-render-to-string": {
|
"node_modules/preact-render-to-string": {
|
||||||
"version": "6.5.13",
|
"version": "6.5.12",
|
||||||
"resolved": "https://registry.npmjs.org/preact-render-to-string/-/preact-render-to-string-6.5.13.tgz",
|
"resolved": "https://registry.npmjs.org/preact-render-to-string/-/preact-render-to-string-6.5.12.tgz",
|
||||||
"integrity": "sha512-iGPd+hKPMFKsfpR2vL4kJ6ZPcFIoWZEcBf0Dpm3zOpdVvj77aY8RlLiQji5OMrngEyaxGogeakTb54uS2FvA6w==",
|
"integrity": "sha512-FpU7/cRipZo4diSWQq7gZWVp+Px76CtVduJZNvQwVzynDsAIxKteMrjCCGPbM2oEasReoDffaeMCMlaur9ohIg==",
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"preact": ">=10"
|
"preact": ">=10"
|
||||||
}
|
}
|
||||||
|
|
@ -5719,19 +5703,18 @@
|
||||||
"integrity": "sha512-onYyVhBNr4CmAxFsKS7bz+uTLRakypIe4R+5A824vBSkQy/hB3fZepoVEf8OVAxzLvK+H/jm9TzpI3ETSm64Kg=="
|
"integrity": "sha512-onYyVhBNr4CmAxFsKS7bz+uTLRakypIe4R+5A824vBSkQy/hB3fZepoVEf8OVAxzLvK+H/jm9TzpI3ETSm64Kg=="
|
||||||
},
|
},
|
||||||
"node_modules/regex": {
|
"node_modules/regex": {
|
||||||
"version": "5.1.1",
|
"version": "5.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/regex/-/regex-5.1.1.tgz",
|
"resolved": "https://registry.npmjs.org/regex/-/regex-5.0.2.tgz",
|
||||||
"integrity": "sha512-dN5I359AVGPnwzJm2jN1k0W9LPZ+ePvoOeVMMfqIMFz53sSwXkxaJoxr50ptnsC771lK95BnTrVSZxq0b9yCGw==",
|
"integrity": "sha512-/pczGbKIQgfTMRV0XjABvc5RzLqQmwqxLHdQao2RTXPk+pmTXB2P0IaUHYdYyk412YLwUIkaeMd5T+RzVgTqnQ==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"regex-utilities": "^2.3.0"
|
"regex-utilities": "^2.3.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/regex-recursion": {
|
"node_modules/regex-recursion": {
|
||||||
"version": "5.1.1",
|
"version": "5.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/regex-recursion/-/regex-recursion-5.1.1.tgz",
|
"resolved": "https://registry.npmjs.org/regex-recursion/-/regex-recursion-5.0.0.tgz",
|
||||||
"integrity": "sha512-ae7SBCbzVNrIjgSbh7wMznPcQel1DNlDtzensnFxpiNpXt1U2ju/bHugH422r+4LAVS1FpW1YCwilmnNsjum9w==",
|
"integrity": "sha512-UwyOqeobrCCqTXPcsSqH4gDhOjD5cI/b8kjngWgSZbxYh5yVjAwTjO5+hAuPRNiuR70+5RlWSs+U9PVcVcW9Lw==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"regex": "^5.1.1",
|
|
||||||
"regex-utilities": "^2.3.0"
|
"regex-utilities": "^2.3.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
@ -6584,9 +6567,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/satori": {
|
"node_modules/satori": {
|
||||||
"version": "0.12.1",
|
"version": "0.12.0",
|
||||||
"resolved": "https://registry.npmjs.org/satori/-/satori-0.12.1.tgz",
|
"resolved": "https://registry.npmjs.org/satori/-/satori-0.12.0.tgz",
|
||||||
"integrity": "sha512-0SbjchvDrDbeXeQgxWVtSWxww7qcFgk3DtSE2/blHOSlLsSHwIqO2fCrtVa/EudJ7Eqno8A33QNx56rUyGbLuw==",
|
"integrity": "sha512-e0e+qQyeFwEszujN7SpWpRtZgww7Nh8lSO3bUn2spHZ5JpqEl3zJ3P14/JlWruxEwdgREs35ZnavrPrWaRVFDg==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@shuding/opentype.js": "1.4.0-beta.0",
|
"@shuding/opentype.js": "1.4.0-beta.0",
|
||||||
"css-background-parser": "^0.1.0",
|
"css-background-parser": "^0.1.0",
|
||||||
|
|
@ -6747,17 +6730,15 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/shiki": {
|
"node_modules/shiki": {
|
||||||
"version": "1.26.2",
|
"version": "1.24.4",
|
||||||
"resolved": "https://registry.npmjs.org/shiki/-/shiki-1.26.2.tgz",
|
"resolved": "https://registry.npmjs.org/shiki/-/shiki-1.24.4.tgz",
|
||||||
"integrity": "sha512-iP7u2NA9A6JwRRCkIUREEX2cMhlYV5EBmbbSlfSRvPThwca8HBRbVkWuNWW+kw9+i6BSUZqqG6YeUs5dC2SjZw==",
|
"integrity": "sha512-aVGSFAOAr1v26Hh/+GBIsRVDWJ583XYV7CuNURKRWh9gpGv4OdbisZGq96B9arMYTZhTQkmRF5BrShOSTvNqhw==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@shikijs/core": "1.26.2",
|
"@shikijs/core": "1.24.4",
|
||||||
"@shikijs/engine-javascript": "1.26.2",
|
"@shikijs/engine-javascript": "1.24.4",
|
||||||
"@shikijs/engine-oniguruma": "1.26.2",
|
"@shikijs/engine-oniguruma": "1.24.4",
|
||||||
"@shikijs/langs": "1.26.2",
|
"@shikijs/types": "1.24.4",
|
||||||
"@shikijs/themes": "1.26.2",
|
"@shikijs/vscode-textmate": "^9.3.1",
|
||||||
"@shikijs/types": "1.26.2",
|
|
||||||
"@shikijs/vscode-textmate": "^10.0.1",
|
|
||||||
"@types/hast": "^3.0.4"
|
"@types/hast": "^3.0.4"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
@ -7548,9 +7529,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/typescript": {
|
"node_modules/typescript": {
|
||||||
"version": "5.7.3",
|
"version": "5.7.2",
|
||||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-5.7.3.tgz",
|
"resolved": "https://registry.npmjs.org/typescript/-/typescript-5.7.2.tgz",
|
||||||
"integrity": "sha512-84MVSjMEHP+FQRPy3pX9sTVV/INIex71s9TL2Gm5FG/WG1SqXeKyZ0k7/blY/4FdOzI12CBy1vGc4og/eus0fw==",
|
"integrity": "sha512-i5t66RHxDvVN40HfDd1PsEThGNnlMCMT3jMUuoh9/0TaqWevNontacunWyN02LA9/fIbEWlcHZcgTKb9QoaLfg==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"bin": {
|
"bin": {
|
||||||
"tsc": "bin/tsc",
|
"tsc": "bin/tsc",
|
||||||
|
|
|
||||||
18
package.json
18
package.json
|
|
@ -35,8 +35,8 @@
|
||||||
"quartz": "./quartz/bootstrap-cli.mjs"
|
"quartz": "./quartz/bootstrap-cli.mjs"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@clack/prompts": "^0.9.1",
|
"@clack/prompts": "^0.9.0",
|
||||||
"@floating-ui/dom": "^1.6.13",
|
"@floating-ui/dom": "^1.6.12",
|
||||||
"@myriaddreamin/rehype-typst": "^0.5.4",
|
"@myriaddreamin/rehype-typst": "^0.5.4",
|
||||||
"@napi-rs/simple-git": "0.1.19",
|
"@napi-rs/simple-git": "0.1.19",
|
||||||
"@tweenjs/tween.js": "^25.0.0",
|
"@tweenjs/tween.js": "^25.0.0",
|
||||||
|
|
@ -55,14 +55,14 @@
|
||||||
"hast-util-to-string": "^3.0.1",
|
"hast-util-to-string": "^3.0.1",
|
||||||
"is-absolute-url": "^4.0.1",
|
"is-absolute-url": "^4.0.1",
|
||||||
"js-yaml": "^4.1.0",
|
"js-yaml": "^4.1.0",
|
||||||
"lightningcss": "^1.29.1",
|
"lightningcss": "^1.28.2",
|
||||||
"mdast-util-find-and-replace": "^3.0.2",
|
"mdast-util-find-and-replace": "^3.0.1",
|
||||||
"mdast-util-to-hast": "^13.2.0",
|
"mdast-util-to-hast": "^13.2.0",
|
||||||
"mdast-util-to-string": "^4.0.0",
|
"mdast-util-to-string": "^4.0.0",
|
||||||
"micromorph": "^0.4.5",
|
"micromorph": "^0.4.5",
|
||||||
"pixi.js": "^8.6.6",
|
"pixi.js": "^8.6.6",
|
||||||
"preact": "^10.25.4",
|
"preact": "^10.25.4",
|
||||||
"preact-render-to-string": "^6.5.13",
|
"preact-render-to-string": "^6.5.12",
|
||||||
"pretty-bytes": "^6.1.1",
|
"pretty-bytes": "^6.1.1",
|
||||||
"pretty-time": "^1.1.0",
|
"pretty-time": "^1.1.0",
|
||||||
"reading-time": "^1.5.0",
|
"reading-time": "^1.5.0",
|
||||||
|
|
@ -83,10 +83,10 @@
|
||||||
"remark-smartypants": "^3.0.2",
|
"remark-smartypants": "^3.0.2",
|
||||||
"rfdc": "^1.4.1",
|
"rfdc": "^1.4.1",
|
||||||
"rimraf": "^6.0.1",
|
"rimraf": "^6.0.1",
|
||||||
"satori": "^0.12.1",
|
"satori": "^0.12.0",
|
||||||
"serve-handler": "^6.1.6",
|
"serve-handler": "^6.1.6",
|
||||||
"sharp": "^0.33.5",
|
"sharp": "^0.33.5",
|
||||||
"shiki": "^1.26.2",
|
"shiki": "^1.24.4",
|
||||||
"source-map-support": "^0.5.21",
|
"source-map-support": "^0.5.21",
|
||||||
"to-vfile": "^8.0.0",
|
"to-vfile": "^8.0.0",
|
||||||
"toml": "^3.0.0",
|
"toml": "^3.0.0",
|
||||||
|
|
@ -102,7 +102,7 @@
|
||||||
"@types/d3": "^7.4.3",
|
"@types/d3": "^7.4.3",
|
||||||
"@types/hast": "^3.0.4",
|
"@types/hast": "^3.0.4",
|
||||||
"@types/js-yaml": "^4.0.9",
|
"@types/js-yaml": "^4.0.9",
|
||||||
"@types/node": "^22.10.6",
|
"@types/node": "^22.10.2",
|
||||||
"@types/pretty-time": "^1.1.5",
|
"@types/pretty-time": "^1.1.5",
|
||||||
"@types/source-map-support": "^0.5.10",
|
"@types/source-map-support": "^0.5.10",
|
||||||
"@types/ws": "^8.5.13",
|
"@types/ws": "^8.5.13",
|
||||||
|
|
@ -110,6 +110,6 @@
|
||||||
"esbuild": "^0.24.2",
|
"esbuild": "^0.24.2",
|
||||||
"prettier": "^3.4.2",
|
"prettier": "^3.4.2",
|
||||||
"tsx": "^4.19.2",
|
"tsx": "^4.19.2",
|
||||||
"typescript": "^5.7.3"
|
"typescript": "^5.7.2"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,9 @@ const config: QuartzConfig = {
|
||||||
pageTitleSuffix: "",
|
pageTitleSuffix: "",
|
||||||
enableSPA: true,
|
enableSPA: true,
|
||||||
enablePopovers: true,
|
enablePopovers: true,
|
||||||
analytics: null,
|
analytics: {
|
||||||
|
provider: "plausible",
|
||||||
|
},
|
||||||
locale: "en-US",
|
locale: "en-US",
|
||||||
baseUrl: "quartz.jzhao.xyz",
|
baseUrl: "quartz.jzhao.xyz",
|
||||||
ignorePatterns: ["private", "templates", ".obsidian"],
|
ignorePatterns: ["private", "templates", ".obsidian"],
|
||||||
|
|
|
||||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -1,8 +1,7 @@
|
||||||
#!/usr/bin/env node
|
#!/usr/bin/env node
|
||||||
import workerpool from "workerpool"
|
import workerpool from "workerpool"
|
||||||
const cacheFile = "./.quartz-cache/transpiled-worker.mjs"
|
const cacheFile = "./.quartz-cache/transpiled-worker.mjs"
|
||||||
const { parseMarkdown, processHtml } = await import(cacheFile)
|
const { parseFiles } = await import(cacheFile)
|
||||||
workerpool.worker({
|
workerpool.worker({
|
||||||
parseMarkdown,
|
parseFiles,
|
||||||
processHtml,
|
|
||||||
})
|
})
|
||||||
|
|
|
||||||
|
|
@ -22,8 +22,6 @@ import fa from "./locales/fa-IR"
|
||||||
import pl from "./locales/pl-PL"
|
import pl from "./locales/pl-PL"
|
||||||
import cs from "./locales/cs-CZ"
|
import cs from "./locales/cs-CZ"
|
||||||
import tr from "./locales/tr-TR"
|
import tr from "./locales/tr-TR"
|
||||||
import th from "./locales/th-TH"
|
|
||||||
import lt from "./locales/lt-LT"
|
|
||||||
|
|
||||||
export const TRANSLATIONS = {
|
export const TRANSLATIONS = {
|
||||||
"en-US": enUs,
|
"en-US": enUs,
|
||||||
|
|
@ -70,8 +68,6 @@ export const TRANSLATIONS = {
|
||||||
"pl-PL": pl,
|
"pl-PL": pl,
|
||||||
"cs-CZ": cs,
|
"cs-CZ": cs,
|
||||||
"tr-TR": tr,
|
"tr-TR": tr,
|
||||||
"th-TH": th,
|
|
||||||
"lt-LT": lt,
|
|
||||||
} as const
|
} as const
|
||||||
|
|
||||||
export const defaultTranslation = "en-US"
|
export const defaultTranslation = "en-US"
|
||||||
|
|
|
||||||
|
|
@ -1,104 +0,0 @@
|
||||||
import { Translation } from "./definition"
|
|
||||||
|
|
||||||
export default {
|
|
||||||
propertyDefaults: {
|
|
||||||
title: "Be Pavadinimo",
|
|
||||||
description: "Aprašymas Nepateiktas",
|
|
||||||
},
|
|
||||||
components: {
|
|
||||||
callout: {
|
|
||||||
note: "Pastaba",
|
|
||||||
abstract: "Santrauka",
|
|
||||||
info: "Informacija",
|
|
||||||
todo: "Darbų sąrašas",
|
|
||||||
tip: "Patarimas",
|
|
||||||
success: "Sėkmingas",
|
|
||||||
question: "Klausimas",
|
|
||||||
warning: "Įspėjimas",
|
|
||||||
failure: "Nesėkmingas",
|
|
||||||
danger: "Pavojus",
|
|
||||||
bug: "Klaida",
|
|
||||||
example: "Pavyzdys",
|
|
||||||
quote: "Citata",
|
|
||||||
},
|
|
||||||
backlinks: {
|
|
||||||
title: "Atgalinės Nuorodos",
|
|
||||||
noBacklinksFound: "Atgalinių Nuorodų Nerasta",
|
|
||||||
},
|
|
||||||
themeToggle: {
|
|
||||||
lightMode: "Šviesus Režimas",
|
|
||||||
darkMode: "Tamsus Režimas",
|
|
||||||
},
|
|
||||||
explorer: {
|
|
||||||
title: "Naršyklė",
|
|
||||||
},
|
|
||||||
footer: {
|
|
||||||
createdWith: "Sukurta Su",
|
|
||||||
},
|
|
||||||
graph: {
|
|
||||||
title: "Grafiko Vaizdas",
|
|
||||||
},
|
|
||||||
recentNotes: {
|
|
||||||
title: "Naujausi Užrašai",
|
|
||||||
seeRemainingMore: ({ remaining }) => `Peržiūrėti dar ${remaining} →`,
|
|
||||||
},
|
|
||||||
transcludes: {
|
|
||||||
transcludeOf: ({ targetSlug }) => `Įterpimas iš ${targetSlug}`,
|
|
||||||
linkToOriginal: "Nuoroda į originalą",
|
|
||||||
},
|
|
||||||
search: {
|
|
||||||
title: "Paieška",
|
|
||||||
searchBarPlaceholder: "Ieškoti",
|
|
||||||
},
|
|
||||||
tableOfContents: {
|
|
||||||
title: "Turinys",
|
|
||||||
},
|
|
||||||
contentMeta: {
|
|
||||||
readingTime: ({ minutes }) => `${minutes} min skaitymo`,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
pages: {
|
|
||||||
rss: {
|
|
||||||
recentNotes: "Naujausi užrašai",
|
|
||||||
lastFewNotes: ({ count }) =>
|
|
||||||
count === 1
|
|
||||||
? "Paskutinis 1 užrašas"
|
|
||||||
: count < 10
|
|
||||||
? `Paskutiniai ${count} užrašai`
|
|
||||||
: `Paskutiniai ${count} užrašų`,
|
|
||||||
},
|
|
||||||
error: {
|
|
||||||
title: "Nerasta",
|
|
||||||
notFound:
|
|
||||||
"Arba šis puslapis yra pasiekiamas tik tam tikriems vartotojams, arba tokio puslapio nėra.",
|
|
||||||
home: "Grįžti į pagrindinį puslapį",
|
|
||||||
},
|
|
||||||
folderContent: {
|
|
||||||
folder: "Aplankas",
|
|
||||||
itemsUnderFolder: ({ count }) =>
|
|
||||||
count === 1
|
|
||||||
? "1 elementas šiame aplanke."
|
|
||||||
: count < 10
|
|
||||||
? `${count} elementai šiame aplanke.`
|
|
||||||
: `${count} elementų šiame aplanke.`,
|
|
||||||
},
|
|
||||||
tagContent: {
|
|
||||||
tag: "Žyma",
|
|
||||||
tagIndex: "Žymų indeksas",
|
|
||||||
itemsUnderTag: ({ count }) =>
|
|
||||||
count === 1
|
|
||||||
? "1 elementas su šia žyma."
|
|
||||||
: count < 10
|
|
||||||
? `${count} elementai su šia žyma.`
|
|
||||||
: `${count} elementų su šia žyma.`,
|
|
||||||
showingFirst: ({ count }) =>
|
|
||||||
count < 10 ? `Rodomos pirmosios ${count} žymos.` : `Rodomos pirmosios ${count} žymų.`,
|
|
||||||
totalTags: ({ count }) =>
|
|
||||||
count === 1
|
|
||||||
? "Rasta iš viso 1 žyma."
|
|
||||||
: count < 10
|
|
||||||
? `Rasta iš viso ${count} žymos.`
|
|
||||||
: `Rasta iš viso ${count} žymų.`,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const satisfies Translation
|
|
||||||
|
|
@ -1,82 +0,0 @@
|
||||||
import { Translation } from "./definition"
|
|
||||||
|
|
||||||
export default {
|
|
||||||
propertyDefaults: {
|
|
||||||
title: "ไม่มีชื่อ",
|
|
||||||
description: "ไม่ได้ระบุคำอธิบายย่อ",
|
|
||||||
},
|
|
||||||
components: {
|
|
||||||
callout: {
|
|
||||||
note: "หมายเหตุ",
|
|
||||||
abstract: "บทคัดย่อ",
|
|
||||||
info: "ข้อมูล",
|
|
||||||
todo: "ต้องทำเพิ่มเติม",
|
|
||||||
tip: "คำแนะนำ",
|
|
||||||
success: "เรียบร้อย",
|
|
||||||
question: "คำถาม",
|
|
||||||
warning: "คำเตือน",
|
|
||||||
failure: "ข้อผิดพลาด",
|
|
||||||
danger: "อันตราย",
|
|
||||||
bug: "บั๊ก",
|
|
||||||
example: "ตัวอย่าง",
|
|
||||||
quote: "คำพูกยกมา",
|
|
||||||
},
|
|
||||||
backlinks: {
|
|
||||||
title: "หน้าที่กล่าวถึง",
|
|
||||||
noBacklinksFound: "ไม่มีหน้าที่โยงมาหน้านี้",
|
|
||||||
},
|
|
||||||
themeToggle: {
|
|
||||||
lightMode: "โหมดสว่าง",
|
|
||||||
darkMode: "โหมดมืด",
|
|
||||||
},
|
|
||||||
explorer: {
|
|
||||||
title: "รายการหน้า",
|
|
||||||
},
|
|
||||||
footer: {
|
|
||||||
createdWith: "สร้างด้วย",
|
|
||||||
},
|
|
||||||
graph: {
|
|
||||||
title: "มุมมองกราฟ",
|
|
||||||
},
|
|
||||||
recentNotes: {
|
|
||||||
title: "บันทึกล่าสุด",
|
|
||||||
seeRemainingMore: ({ remaining }) => `ดูเพิ่มอีก ${remaining} รายการ →`,
|
|
||||||
},
|
|
||||||
transcludes: {
|
|
||||||
transcludeOf: ({ targetSlug }) => `รวมข้ามเนื้อหาจาก ${targetSlug}`,
|
|
||||||
linkToOriginal: "ดูหน้าต้นทาง",
|
|
||||||
},
|
|
||||||
search: {
|
|
||||||
title: "ค้นหา",
|
|
||||||
searchBarPlaceholder: "ค้นหาบางอย่าง",
|
|
||||||
},
|
|
||||||
tableOfContents: {
|
|
||||||
title: "สารบัญ",
|
|
||||||
},
|
|
||||||
contentMeta: {
|
|
||||||
readingTime: ({ minutes }) => `อ่านราว ${minutes} นาที`,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
pages: {
|
|
||||||
rss: {
|
|
||||||
recentNotes: "บันทึกล่าสุด",
|
|
||||||
lastFewNotes: ({ count }) => `${count} บันทึกล่าสุด`,
|
|
||||||
},
|
|
||||||
error: {
|
|
||||||
title: "ไม่มีหน้านี้",
|
|
||||||
notFound: "หน้านี้อาจตั้งค่าเป็นส่วนตัวหรือยังไม่ถูกสร้าง",
|
|
||||||
home: "กลับหน้าหลัก",
|
|
||||||
},
|
|
||||||
folderContent: {
|
|
||||||
folder: "โฟลเดอร์",
|
|
||||||
itemsUnderFolder: ({ count }) => `มี ${count} รายการในโฟลเดอร์นี้`,
|
|
||||||
},
|
|
||||||
tagContent: {
|
|
||||||
tag: "แท็ก",
|
|
||||||
tagIndex: "แท็กทั้งหมด",
|
|
||||||
itemsUnderTag: ({ count }) => `มี ${count} รายการในแท็กนี้`,
|
|
||||||
showingFirst: ({ count }) => `แสดง ${count} แท็กแรก`,
|
|
||||||
totalTags: ({ count }) => `มีทั้งหมด ${count} แท็ก`,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const satisfies Translation
|
|
||||||
|
|
@ -1,13 +1,5 @@
|
||||||
import { QuartzTransformerPlugin } from "../types"
|
import { QuartzTransformerPlugin } from "../types"
|
||||||
import {
|
import { Root, Html, BlockContent, DefinitionContent, Paragraph, Code } from "mdast"
|
||||||
Root,
|
|
||||||
Html,
|
|
||||||
BlockContent,
|
|
||||||
PhrasingContent,
|
|
||||||
DefinitionContent,
|
|
||||||
Paragraph,
|
|
||||||
Code,
|
|
||||||
} from "mdast"
|
|
||||||
import { Element, Literal, Root as HtmlRoot } from "hast"
|
import { Element, Literal, Root as HtmlRoot } from "hast"
|
||||||
import { ReplaceFunction, findAndReplace as mdastFindReplace } from "mdast-util-find-and-replace"
|
import { ReplaceFunction, findAndReplace as mdastFindReplace } from "mdast-util-find-and-replace"
|
||||||
import rehypeRaw from "rehype-raw"
|
import rehypeRaw from "rehype-raw"
|
||||||
|
|
@ -22,6 +14,7 @@ import checkboxScript from "../../components/scripts/checkbox.inline.ts"
|
||||||
import { FilePath, pathToRoot, slugTag, slugifyFilePath } from "../../util/path"
|
import { FilePath, pathToRoot, slugTag, slugifyFilePath } from "../../util/path"
|
||||||
import { toHast } from "mdast-util-to-hast"
|
import { toHast } from "mdast-util-to-hast"
|
||||||
import { toHtml } from "hast-util-to-html"
|
import { toHtml } from "hast-util-to-html"
|
||||||
|
import { PhrasingContent } from "mdast-util-find-and-replace/lib"
|
||||||
import { capitalize } from "../../util/lang"
|
import { capitalize } from "../../util/lang"
|
||||||
import { PluggableList } from "unified"
|
import { PluggableList } from "unified"
|
||||||
|
|
||||||
|
|
@ -128,12 +121,12 @@ const commentRegex = new RegExp(/%%[\s\S]*?%%/g)
|
||||||
// from https://github.com/escwxyz/remark-obsidian-callout/blob/main/src/index.ts
|
// from https://github.com/escwxyz/remark-obsidian-callout/blob/main/src/index.ts
|
||||||
const calloutRegex = new RegExp(/^\[\!([\w-]+)\|?(.+?)?\]([+-]?)/)
|
const calloutRegex = new RegExp(/^\[\!([\w-]+)\|?(.+?)?\]([+-]?)/)
|
||||||
const calloutLineRegex = new RegExp(/^> *\[\!\w+\|?.*?\][+-]?.*$/gm)
|
const calloutLineRegex = new RegExp(/^> *\[\!\w+\|?.*?\][+-]?.*$/gm)
|
||||||
// (?<=^| ) -> a lookbehind assertion, tag should start be separated by a space or be the start of the line
|
// (?:^| ) -> non-capturing group, tag should start be separated by a space or be the start of the line
|
||||||
// #(...) -> capturing group, tag itself must start with #
|
// #(...) -> capturing group, tag itself must start with #
|
||||||
// (?:[-_\p{L}\d\p{Z}])+ -> non-capturing group, non-empty string of (Unicode-aware) alpha-numeric characters and symbols, hyphens and/or underscores
|
// (?:[-_\p{L}\d\p{Z}])+ -> non-capturing group, non-empty string of (Unicode-aware) alpha-numeric characters and symbols, hyphens and/or underscores
|
||||||
// (?:\/[-_\p{L}\d\p{Z}]+)*) -> non-capturing group, matches an arbitrary number of tag strings separated by "/"
|
// (?:\/[-_\p{L}\d\p{Z}]+)*) -> non-capturing group, matches an arbitrary number of tag strings separated by "/"
|
||||||
const tagRegex = new RegExp(
|
const tagRegex = new RegExp(
|
||||||
/(?<=^| )#((?:[-_\p{L}\p{Emoji}\p{M}\d])+(?:\/[-_\p{L}\p{Emoji}\p{M}\d]+)*)/gu,
|
/(?:^| )#((?:[-_\p{L}\p{Emoji}\p{M}\d])+(?:\/[-_\p{L}\p{Emoji}\p{M}\d]+)*)/gu,
|
||||||
)
|
)
|
||||||
const blockReferenceRegex = new RegExp(/\^([-_A-Za-z0-9]+)$/g)
|
const blockReferenceRegex = new RegExp(/\^([-_A-Za-z0-9]+)$/g)
|
||||||
const ytLinkRegex = /^.*(youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=|\&v=)([^#\&\?]*).*/
|
const ytLinkRegex = /^.*(youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=|\&v=)([^#\&\?]*).*/
|
||||||
|
|
|
||||||
|
|
@ -1,13 +1,11 @@
|
||||||
import { Root as HtmlRoot } from "hast"
|
import { Node, Parent } from "hast"
|
||||||
import { Root as MdRoot } from "mdast"
|
|
||||||
import { Data, VFile } from "vfile"
|
import { Data, VFile } from "vfile"
|
||||||
|
|
||||||
export type QuartzPluginData = Data
|
export type QuartzPluginData = Data
|
||||||
export type MarkdownContent = [MdRoot, VFile]
|
export type ProcessedContent = [Node, VFile]
|
||||||
export type ProcessedContent = [HtmlRoot, VFile]
|
|
||||||
|
|
||||||
export function defaultProcessedContent(vfileData: Partial<QuartzPluginData>): ProcessedContent {
|
export function defaultProcessedContent(vfileData: Partial<QuartzPluginData>): ProcessedContent {
|
||||||
const root: HtmlRoot = { type: "root", children: [] }
|
const root: Parent = { type: "root", children: [] }
|
||||||
const vfile = new VFile("")
|
const vfile = new VFile("")
|
||||||
vfile.data = vfileData
|
vfile.data = vfileData
|
||||||
return [root, vfile]
|
return [root, vfile]
|
||||||
|
|
|
||||||
|
|
@ -4,20 +4,18 @@ import remarkRehype from "remark-rehype"
|
||||||
import { Processor, unified } from "unified"
|
import { Processor, unified } from "unified"
|
||||||
import { Root as MDRoot } from "remark-parse/lib"
|
import { Root as MDRoot } from "remark-parse/lib"
|
||||||
import { Root as HTMLRoot } from "hast"
|
import { Root as HTMLRoot } from "hast"
|
||||||
import { MarkdownContent, ProcessedContent } from "../plugins/vfile"
|
import { ProcessedContent } from "../plugins/vfile"
|
||||||
import { PerfTimer } from "../util/perf"
|
import { PerfTimer } from "../util/perf"
|
||||||
import { read } from "to-vfile"
|
import { read } from "to-vfile"
|
||||||
import { FilePath, FullSlug, QUARTZ, slugifyFilePath } from "../util/path"
|
import { FilePath, QUARTZ, slugifyFilePath } from "../util/path"
|
||||||
import path from "path"
|
import path from "path"
|
||||||
import workerpool, { Promise as WorkerPromise } from "workerpool"
|
import workerpool, { Promise as WorkerPromise } from "workerpool"
|
||||||
import { QuartzLogger } from "../util/log"
|
import { QuartzLogger } from "../util/log"
|
||||||
import { trace } from "../util/trace"
|
import { trace } from "../util/trace"
|
||||||
import { BuildCtx } from "../util/ctx"
|
import { BuildCtx } from "../util/ctx"
|
||||||
|
|
||||||
export type QuartzMdProcessor = Processor<MDRoot, MDRoot, MDRoot>
|
export type QuartzProcessor = Processor<MDRoot, MDRoot, HTMLRoot>
|
||||||
export type QuartzHtmlProcessor = Processor<undefined, MDRoot, HTMLRoot>
|
export function createProcessor(ctx: BuildCtx): QuartzProcessor {
|
||||||
|
|
||||||
export function createMdProcessor(ctx: BuildCtx): QuartzMdProcessor {
|
|
||||||
const transformers = ctx.cfg.plugins.transformers
|
const transformers = ctx.cfg.plugins.transformers
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
@ -26,20 +24,14 @@ export function createMdProcessor(ctx: BuildCtx): QuartzMdProcessor {
|
||||||
.use(remarkParse)
|
.use(remarkParse)
|
||||||
// MD AST -> MD AST transforms
|
// MD AST -> MD AST transforms
|
||||||
.use(
|
.use(
|
||||||
transformers.flatMap((plugin) => plugin.markdownPlugins?.(ctx) ?? []),
|
transformers
|
||||||
) as unknown as QuartzMdProcessor
|
.filter((p) => p.markdownPlugins)
|
||||||
// ^ sadly the typing of `use` is not smart enough to infer the correct type from our plugin list
|
.flatMap((plugin) => plugin.markdownPlugins!(ctx)),
|
||||||
)
|
)
|
||||||
}
|
|
||||||
|
|
||||||
export function createHtmlProcessor(ctx: BuildCtx): QuartzHtmlProcessor {
|
|
||||||
const transformers = ctx.cfg.plugins.transformers
|
|
||||||
return (
|
|
||||||
unified()
|
|
||||||
// MD AST -> HTML AST
|
// MD AST -> HTML AST
|
||||||
.use(remarkRehype, { allowDangerousHtml: true })
|
.use(remarkRehype, { allowDangerousHtml: true })
|
||||||
// HTML AST -> HTML AST transforms
|
// HTML AST -> HTML AST transforms
|
||||||
.use(transformers.flatMap((plugin) => plugin.htmlPlugins?.(ctx) ?? []))
|
.use(transformers.filter((p) => p.htmlPlugins).flatMap((plugin) => plugin.htmlPlugins!(ctx)))
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -83,8 +75,8 @@ async function transpileWorkerScript() {
|
||||||
|
|
||||||
export function createFileParser(ctx: BuildCtx, fps: FilePath[]) {
|
export function createFileParser(ctx: BuildCtx, fps: FilePath[]) {
|
||||||
const { argv, cfg } = ctx
|
const { argv, cfg } = ctx
|
||||||
return async (processor: QuartzMdProcessor) => {
|
return async (processor: QuartzProcessor) => {
|
||||||
const res: MarkdownContent[] = []
|
const res: ProcessedContent[] = []
|
||||||
for (const fp of fps) {
|
for (const fp of fps) {
|
||||||
try {
|
try {
|
||||||
const perf = new PerfTimer()
|
const perf = new PerfTimer()
|
||||||
|
|
@ -108,32 +100,10 @@ export function createFileParser(ctx: BuildCtx, fps: FilePath[]) {
|
||||||
res.push([newAst, file])
|
res.push([newAst, file])
|
||||||
|
|
||||||
if (argv.verbose) {
|
if (argv.verbose) {
|
||||||
console.log(`[markdown] ${fp} -> ${file.data.slug} (${perf.timeSince()})`)
|
console.log(`[process] ${fp} -> ${file.data.slug} (${perf.timeSince()})`)
|
||||||
}
|
}
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
trace(`\nFailed to process markdown \`${fp}\``, err as Error)
|
trace(`\nFailed to process \`${fp}\``, err as Error)
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return res
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
export function createMarkdownParser(ctx: BuildCtx, mdContent: MarkdownContent[]) {
|
|
||||||
return async (processor: QuartzHtmlProcessor) => {
|
|
||||||
const res: ProcessedContent[] = []
|
|
||||||
for (const [ast, file] of mdContent) {
|
|
||||||
try {
|
|
||||||
const perf = new PerfTimer()
|
|
||||||
|
|
||||||
const newAst = await processor.run(ast as MDRoot, file)
|
|
||||||
res.push([newAst, file])
|
|
||||||
|
|
||||||
if (ctx.argv.verbose) {
|
|
||||||
console.log(`[html] ${file.data.slug} (${perf.timeSince()})`)
|
|
||||||
}
|
|
||||||
} catch (err) {
|
|
||||||
trace(`\nFailed to process html \`${file.data.filePath}\``, err as Error)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -143,7 +113,6 @@ export function createMarkdownParser(ctx: BuildCtx, mdContent: MarkdownContent[]
|
||||||
|
|
||||||
const clamp = (num: number, min: number, max: number) =>
|
const clamp = (num: number, min: number, max: number) =>
|
||||||
Math.min(Math.max(Math.round(num), min), max)
|
Math.min(Math.max(Math.round(num), min), max)
|
||||||
|
|
||||||
export async function parseMarkdown(ctx: BuildCtx, fps: FilePath[]): Promise<ProcessedContent[]> {
|
export async function parseMarkdown(ctx: BuildCtx, fps: FilePath[]): Promise<ProcessedContent[]> {
|
||||||
const { argv } = ctx
|
const { argv } = ctx
|
||||||
const perf = new PerfTimer()
|
const perf = new PerfTimer()
|
||||||
|
|
@ -157,8 +126,9 @@ export async function parseMarkdown(ctx: BuildCtx, fps: FilePath[]): Promise<Pro
|
||||||
log.start(`Parsing input files using ${concurrency} threads`)
|
log.start(`Parsing input files using ${concurrency} threads`)
|
||||||
if (concurrency === 1) {
|
if (concurrency === 1) {
|
||||||
try {
|
try {
|
||||||
const mdRes = await createFileParser(ctx, fps)(createMdProcessor(ctx))
|
const processor = createProcessor(ctx)
|
||||||
res = await createMarkdownParser(ctx, mdRes)(createHtmlProcessor(ctx))
|
const parse = createFileParser(ctx, fps)
|
||||||
|
res = await parse(processor)
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
log.end()
|
log.end()
|
||||||
throw error
|
throw error
|
||||||
|
|
@ -170,27 +140,17 @@ export async function parseMarkdown(ctx: BuildCtx, fps: FilePath[]): Promise<Pro
|
||||||
maxWorkers: concurrency,
|
maxWorkers: concurrency,
|
||||||
workerType: "thread",
|
workerType: "thread",
|
||||||
})
|
})
|
||||||
const errorHandler = (err: any) => {
|
|
||||||
console.error(`${err}`.replace(/^error:\s*/i, ""))
|
|
||||||
process.exit(1)
|
|
||||||
}
|
|
||||||
|
|
||||||
const mdPromises: WorkerPromise<[MarkdownContent[], FullSlug[]]>[] = []
|
|
||||||
for (const chunk of chunks(fps, CHUNK_SIZE)) {
|
|
||||||
mdPromises.push(pool.exec("parseMarkdown", [ctx.buildId, argv, chunk]))
|
|
||||||
}
|
|
||||||
const mdResults: [MarkdownContent[], FullSlug[]][] =
|
|
||||||
await WorkerPromise.all(mdPromises).catch(errorHandler)
|
|
||||||
|
|
||||||
const childPromises: WorkerPromise<ProcessedContent[]>[] = []
|
const childPromises: WorkerPromise<ProcessedContent[]>[] = []
|
||||||
for (const [_, extraSlugs] of mdResults) {
|
for (const chunk of chunks(fps, CHUNK_SIZE)) {
|
||||||
ctx.allSlugs.push(...extraSlugs)
|
childPromises.push(pool.exec("parseFiles", [ctx.buildId, argv, chunk, ctx.allSlugs]))
|
||||||
}
|
}
|
||||||
for (const [mdChunk, _] of mdResults) {
|
|
||||||
childPromises.push(pool.exec("processHtml", [ctx.buildId, argv, mdChunk, ctx.allSlugs]))
|
|
||||||
}
|
|
||||||
const results: ProcessedContent[][] = await WorkerPromise.all(childPromises).catch(errorHandler)
|
|
||||||
|
|
||||||
|
const results: ProcessedContent[][] = await WorkerPromise.all(childPromises).catch((err) => {
|
||||||
|
const errString = err.toString().slice("Error:".length)
|
||||||
|
console.error(errString)
|
||||||
|
process.exit(1)
|
||||||
|
})
|
||||||
res = results.flat()
|
res = results.flat()
|
||||||
await pool.terminate()
|
await pool.terminate()
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -35,9 +35,7 @@ export async function getSatoriFont(headerFontName: string, bodyFontName: string
|
||||||
async function fetchTtf(fontName: string, weight: FontWeight): Promise<ArrayBuffer> {
|
async function fetchTtf(fontName: string, weight: FontWeight): Promise<ArrayBuffer> {
|
||||||
try {
|
try {
|
||||||
// Get css file from google fonts
|
// Get css file from google fonts
|
||||||
const cssResponse = await fetch(
|
const cssResponse = await fetch(`https://fonts.googleapis.com/css?family=${fontName}:${weight}`)
|
||||||
`https://fonts.googleapis.com/css2?family=${fontName}:wght@${weight}`,
|
|
||||||
)
|
|
||||||
const css = await cssResponse.text()
|
const css = await cssResponse.text()
|
||||||
|
|
||||||
// Extract .ttf url from css file
|
// Extract .ttf url from css file
|
||||||
|
|
|
||||||
|
|
@ -171,10 +171,6 @@ describe("transforms", () => {
|
||||||
assert.strictEqual(path.joinSegments("/a", "b/"), "/a/b/")
|
assert.strictEqual(path.joinSegments("/a", "b/"), "/a/b/")
|
||||||
assert.strictEqual(path.joinSegments("/a/", "b/"), "/a/b/")
|
assert.strictEqual(path.joinSegments("/a/", "b/"), "/a/b/")
|
||||||
|
|
||||||
// lone slash
|
|
||||||
assert.strictEqual(path.joinSegments("/a/", "b", "/"), "/a/b/")
|
|
||||||
assert.strictEqual(path.joinSegments("a/", "b" + "/"), "a/b/")
|
|
||||||
|
|
||||||
// works with protocol specifiers
|
// works with protocol specifiers
|
||||||
assert.strictEqual(path.joinSegments("https://example.com", "a"), "https://example.com/a")
|
assert.strictEqual(path.joinSegments("https://example.com", "a"), "https://example.com/a")
|
||||||
assert.strictEqual(path.joinSegments("https://example.com/", "a"), "https://example.com/a")
|
assert.strictEqual(path.joinSegments("https://example.com/", "a"), "https://example.com/a")
|
||||||
|
|
|
||||||
|
|
@ -188,7 +188,7 @@ export function joinSegments(...args: string[]): string {
|
||||||
}
|
}
|
||||||
|
|
||||||
let joined = args
|
let joined = args
|
||||||
.filter((segment) => segment !== "" && segment !== "/")
|
.filter((segment) => segment !== "")
|
||||||
.map((segment) => stripSlashes(segment))
|
.map((segment) => stripSlashes(segment))
|
||||||
.join("/")
|
.join("/")
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,46 +3,23 @@ sourceMapSupport.install(options)
|
||||||
import cfg from "../quartz.config"
|
import cfg from "../quartz.config"
|
||||||
import { Argv, BuildCtx } from "./util/ctx"
|
import { Argv, BuildCtx } from "./util/ctx"
|
||||||
import { FilePath, FullSlug } from "./util/path"
|
import { FilePath, FullSlug } from "./util/path"
|
||||||
import {
|
import { createFileParser, createProcessor } from "./processors/parse"
|
||||||
createFileParser,
|
|
||||||
createHtmlProcessor,
|
|
||||||
createMarkdownParser,
|
|
||||||
createMdProcessor,
|
|
||||||
} from "./processors/parse"
|
|
||||||
import { options } from "./util/sourcemap"
|
import { options } from "./util/sourcemap"
|
||||||
import { MarkdownContent, ProcessedContent } from "./plugins/vfile"
|
|
||||||
|
|
||||||
// only called from worker thread
|
// only called from worker thread
|
||||||
export async function parseMarkdown(
|
export async function parseFiles(
|
||||||
buildId: string,
|
buildId: string,
|
||||||
argv: Argv,
|
argv: Argv,
|
||||||
fps: FilePath[],
|
fps: FilePath[],
|
||||||
): Promise<[MarkdownContent[], FullSlug[]]> {
|
|
||||||
// this is a hack
|
|
||||||
// we assume markdown parsers can add to `allSlugs`,
|
|
||||||
// but don't actually use them
|
|
||||||
const allSlugs: FullSlug[] = []
|
|
||||||
const ctx: BuildCtx = {
|
|
||||||
buildId,
|
|
||||||
cfg,
|
|
||||||
argv,
|
|
||||||
allSlugs,
|
|
||||||
}
|
|
||||||
return [await createFileParser(ctx, fps)(createMdProcessor(ctx)), allSlugs]
|
|
||||||
}
|
|
||||||
|
|
||||||
// only called from worker thread
|
|
||||||
export function processHtml(
|
|
||||||
buildId: string,
|
|
||||||
argv: Argv,
|
|
||||||
mds: MarkdownContent[],
|
|
||||||
allSlugs: FullSlug[],
|
allSlugs: FullSlug[],
|
||||||
): Promise<ProcessedContent[]> {
|
) {
|
||||||
const ctx: BuildCtx = {
|
const ctx: BuildCtx = {
|
||||||
buildId,
|
buildId,
|
||||||
cfg,
|
cfg,
|
||||||
argv,
|
argv,
|
||||||
allSlugs,
|
allSlugs,
|
||||||
}
|
}
|
||||||
return createMarkdownParser(ctx, mds)(createHtmlProcessor(ctx))
|
const processor = createProcessor(ctx)
|
||||||
|
const parse = createFileParser(ctx, fps)
|
||||||
|
return parse(processor)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue