优化 Mermaid 渲染

This commit is contained in:
2026-09-25 01:45:31 +08:00
parent 5929a356e9
commit 2368fcc005
25 changed files with 2468 additions and 1014 deletions
+22 -5
View File
@@ -3,20 +3,37 @@
"type": "module",
"version": "0.0.1",
"scripts": {
"fonts": "node scripts/generate-fonts.mjs",
"check:fonts": "node scripts/generate-fonts.mjs --check",
"check:site": "node scripts/check-build.mjs",
"check:mermaid": "node --test scripts/mermaid.test.mjs",
"setup:mermaid": "playwright install chromium",
"predev": "npm run fonts",
"dev": "astro dev",
"prestart": "npm run fonts",
"start": "astro dev",
"build": "astro build",
"prebuild": "npm run fonts",
"build": "astro build && npm run check:fonts && npm run check:site",
"preview": "astro preview",
"astro": "astro"
},
"dependencies": {
"@astrojs/markdown-remark": "7.2.0",
"@astrojs/starlight": "^0.41.1",
"astro": "^7.0.2",
"@astrojs/markdown-remark": "^7.3.1",
"@astrojs/mdx": "^8.0.2",
"@astrojs/starlight": "^0.42.3",
"astro": "^7.3.5",
"katex": "^0.16.47",
"mermaid": "^12.0.0",
"rehype-katex": "^7.0.1",
"remark-math": "^6.0.0",
"sharp": "^0.34.5"
},
"devDependencies": {
"playwright": "^1.63.0",
"rehype-mermaid": "^3.0.0"
},
"allowScripts": {
"sharp@0.35.4": true,
"sharp@0.34.5": true,
"esbuild@0.28.2": true
}
}