fix: some fixes for admonition and GitHub repo card

This commit is contained in:
saicaca 2024-05-03 01:24:44 +08:00
parent e1dae88515
commit 39797fd677
7 changed files with 343 additions and 276 deletions

View File

@ -16,6 +16,7 @@ import rehypeComponents from "rehype-components"; /* Render the custom directive
import svelte from "@astrojs/svelte" import svelte from "@astrojs/svelte"
import swup from '@swup/astro'; import swup from '@swup/astro';
import sitemap from '@astrojs/sitemap'; import sitemap from '@astrojs/sitemap';
import {parseDirectiveNode} from "./src/plugins/remark-directive-rehype.js";
const oklchToHex = (str) => { const oklchToHex = (str) => {
const DEFAULT_HUE = 250 const DEFAULT_HUE = 250
@ -59,15 +60,15 @@ export default defineConfig({
sitemap(), sitemap(),
], ],
markdown: { markdown: {
remarkPlugins: [remarkMath, remarkReadingTime, remarkDirective, remarkDirectiveRehype], remarkPlugins: [remarkMath, remarkReadingTime, remarkDirective, parseDirectiveNode],
rehypePlugins: [ rehypePlugins: [
rehypeKatex, rehypeKatex,
rehypeSlug, rehypeSlug,
[rehypeComponents, { [rehypeComponents, {
components: { components: {
github: GithubCardComponent, github: GithubCardComponent,
tip: (x, y) => AdmonitionComponent(x, y, "tip"),
note: (x, y) => AdmonitionComponent(x, y, "note"), note: (x, y) => AdmonitionComponent(x, y, "note"),
tip: (x, y) => AdmonitionComponent(x, y, "tip"),
important: (x, y) => AdmonitionComponent(x, y, "important"), important: (x, y) => AdmonitionComponent(x, y, "important"),
caution: (x, y) => AdmonitionComponent(x, y, "caution"), caution: (x, y) => AdmonitionComponent(x, y, "caution"),
warning: (x, y) => AdmonitionComponent(x, y, "warning"), warning: (x, y) => AdmonitionComponent(x, y, "warning"),

View File

@ -10,19 +10,19 @@ importers:
dependencies: dependencies:
'@astrojs/check': '@astrojs/check':
specifier: ^0.5.9 specifier: ^0.5.9
version: 0.5.9(prettier@2.8.8)(typescript@5.4.2) version: 0.5.9(typescript@5.4.2)
'@astrojs/rss': '@astrojs/rss':
specifier: ^4.0.5 specifier: ^4.0.5
version: 4.0.5 version: 4.0.5
'@astrojs/sitemap': '@astrojs/sitemap':
specifier: ^3.1.2 specifier: ^3.1.2
version: 3.1.4 version: 3.1.2
'@astrojs/svelte': '@astrojs/svelte':
specifier: ^5.2.0 specifier: ^5.2.0
version: 5.4.0(astro@4.4.15(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)(typescript@5.4.2))(svelte@4.2.12)(typescript@5.4.2)(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)) version: 5.2.0(astro@4.4.15)(svelte@4.2.12)(typescript@5.4.2)(vite@5.1.6)
'@astrojs/tailwind': '@astrojs/tailwind':
specifier: ^5.1.0 specifier: ^5.1.0
version: 5.1.0(astro@4.4.15(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)(typescript@5.4.2))(tailwindcss@3.4.1) version: 5.1.0(astro@4.4.15)(tailwindcss@3.4.1)
'@fontsource-variable/jetbrains-mono': '@fontsource-variable/jetbrains-mono':
specifier: ^5.0.20 specifier: ^5.0.20
version: 5.0.20 version: 5.0.20
@ -31,10 +31,10 @@ importers:
version: 5.0.12 version: 5.0.12
'@swup/astro': '@swup/astro':
specifier: ^1.4.0 specifier: ^1.4.0
version: 1.4.0(@types/babel__core@7.20.5) version: 1.4.0
astro: astro:
specifier: ^4.4.15 specifier: ^4.4.15
version: 4.4.15(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)(typescript@5.4.2) version: 4.4.15(stylus@0.63.0)(typescript@5.4.2)
astro-compress: astro-compress:
specifier: ^2.2.15 specifier: ^2.2.15
version: 2.2.15 version: 2.2.15
@ -195,15 +195,15 @@ packages:
'@astrojs/rss@4.0.5': '@astrojs/rss@4.0.5':
resolution: {integrity: sha512-IyJVL6z09AQtxbgLaAwebT3T5YKe4oTHDesqydJv1KLHw+zEzzMCFuuNsEyxjiqu7df9+DDCpDXLj/WRiEUXvw==} resolution: {integrity: sha512-IyJVL6z09AQtxbgLaAwebT3T5YKe4oTHDesqydJv1KLHw+zEzzMCFuuNsEyxjiqu7df9+DDCpDXLj/WRiEUXvw==}
'@astrojs/sitemap@3.1.4': '@astrojs/sitemap@3.1.2':
resolution: {integrity: sha512-po8CqDCK14O6phU1mB5C8SyVLyQEa+7pJM8oXxs1mVh8DgvxxaA5E7lak1vzOmBcyyyHBW32jakGqNYc66sBRw==} resolution: {integrity: sha512-FxOJldIl5ltZ5CNjocQxHkAO9orwHBjqtaU28o4smobp9vowS0nbGp+I9CrPxkzWdl1crSDm9vjL9tnvG1DSug==}
'@astrojs/svelte@5.4.0': '@astrojs/svelte@5.2.0':
resolution: {integrity: sha512-D9/CVJ+Fy3fu+FzJ7x+0GnRUhHsJKsU6tW/xQQ1QzrFMABuEoM5U4YKTYtxWkqB4B4jNb7gbA4p9ZtEhYZ3/+w==} resolution: {integrity: sha512-GmwbXks2WMkmAfl0rlPM/2gA1RtmZzjGV2mOceV3g7QNyjIsSYBPKrlEnSFnuR+YMvlAtWdbMFBsb3gtGxnTTg==}
engines: {node: ^18.17.1 || ^20.3.0 || >=21.0.0} engines: {node: '>=18.14.1'}
peerDependencies: peerDependencies:
astro: ^4.0.0 astro: ^4.0.0
svelte: ^4.0.0 || ^5.0.0-next.90 svelte: ^4.0.0 || ^5.0.0-next.56
typescript: ^5.3.3 typescript: ^5.3.3
'@astrojs/tailwind@5.1.0': '@astrojs/tailwind@5.1.0':
@ -1710,8 +1710,8 @@ packages:
'@types/sax@1.2.7': '@types/sax@1.2.7':
resolution: {integrity: sha512-rO73L89PJxeYM3s3pPPjiPgVVcymqU490g0YO5n5By0k2Erzj6tay/4lr1CHAAU4JyOWd1rpQ8bCf6cZfHU96A==} resolution: {integrity: sha512-rO73L89PJxeYM3s3pPPjiPgVVcymqU490g0YO5n5By0k2Erzj6tay/4lr1CHAAU4JyOWd1rpQ8bCf6cZfHU96A==}
'@types/tar@6.1.13': '@types/tar@6.1.11':
resolution: {integrity: sha512-IznnlmU5f4WcGTh2ltRu/Ijpmk8wiWXfF0VA4s+HPjHZgvFggk1YaIkbo5krX/zUCzWF8N/l4+W/LNxnvAJ8nw==} resolution: {integrity: sha512-ThA1WD8aDdVU4VLuyq5NEqriwXErF5gEIJeyT6gHBWU7JtSmW2a5qjNv3/vR82O20mW+1vhmeZJfBQPT3HCugg==}
'@types/unist@2.0.10': '@types/unist@2.0.10':
resolution: {integrity: sha512-IfYcSBWE3hLpBg8+X2SEa8LVkJdJEkT2Ese2aaLs3ptGdVtABxndrMaxuFlQ1qdFf9Q5rDvDpxI3WwgvKFAsQA==} resolution: {integrity: sha512-IfYcSBWE3hLpBg8+X2SEa8LVkJdJEkT2Ese2aaLs3ptGdVtABxndrMaxuFlQ1qdFf9Q5rDvDpxI3WwgvKFAsQA==}
@ -4330,9 +4330,6 @@ packages:
resolution: {integrity: sha512-xhV7w8S+bUwlPTb4bAOUQhv8/cSS5offJuX8GQGq32ONF0ZtDWKfkdomM3HMRA+LhX6um/FZ0COqlwsjD53LeQ==} resolution: {integrity: sha512-xhV7w8S+bUwlPTb4bAOUQhv8/cSS5offJuX8GQGq32ONF0ZtDWKfkdomM3HMRA+LhX6um/FZ0COqlwsjD53LeQ==}
engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0}
stream-replace-string@2.0.0:
resolution: {integrity: sha512-TlnjJ1C0QrmxRNrON00JvaFFlNh5TTG00APw23j74ET7gkQpTASi6/L2fuiav8pzK715HXtUeClpBTw2NPSn6w==}
streamx@2.16.1: streamx@2.16.1:
resolution: {integrity: sha512-m9QYj6WygWyWa3H1YY69amr4nVgy61xfjys7xO7kviL5rfIEc2naf+ewFiOA+aEJD7y0JO3h2GoiUv4TDwEGzQ==} resolution: {integrity: sha512-m9QYj6WygWyWa3H1YY69amr4nVgy61xfjys7xO7kviL5rfIEc2naf+ewFiOA+aEJD7y0JO3h2GoiUv4TDwEGzQ==}
@ -4925,9 +4922,9 @@ snapshots:
'@antfu/utils@0.7.7': {} '@antfu/utils@0.7.7': {}
'@astrojs/check@0.5.9(prettier@2.8.8)(typescript@5.4.2)': '@astrojs/check@0.5.9(typescript@5.4.2)':
dependencies: dependencies:
'@astrojs/language-server': 2.8.2(prettier@2.8.8)(typescript@5.4.2) '@astrojs/language-server': 2.8.2(typescript@5.4.2)
chokidar: 3.6.0 chokidar: 3.6.0
fast-glob: 3.3.2 fast-glob: 3.3.2
kleur: 4.1.5 kleur: 4.1.5
@ -4941,7 +4938,7 @@ snapshots:
'@astrojs/internal-helpers@0.2.1': {} '@astrojs/internal-helpers@0.2.1': {}
'@astrojs/language-server@2.8.2(prettier@2.8.8)(typescript@5.4.2)': '@astrojs/language-server@2.8.2(typescript@5.4.2)':
dependencies: dependencies:
'@astrojs/compiler': 2.7.0 '@astrojs/compiler': 2.7.0
'@jridgewell/sourcemap-codec': 1.4.15 '@jridgewell/sourcemap-codec': 1.4.15
@ -4954,13 +4951,11 @@ snapshots:
volar-service-css: 0.0.33(@volar/language-service@2.1.2) volar-service-css: 0.0.33(@volar/language-service@2.1.2)
volar-service-emmet: 0.0.33(@volar/language-service@2.1.2) volar-service-emmet: 0.0.33(@volar/language-service@2.1.2)
volar-service-html: 0.0.33(@volar/language-service@2.1.2) volar-service-html: 0.0.33(@volar/language-service@2.1.2)
volar-service-prettier: 0.0.33(@volar/language-service@2.1.2)(prettier@2.8.8) volar-service-prettier: 0.0.33(@volar/language-service@2.1.2)
volar-service-typescript: 0.0.33(@volar/language-service@2.1.2) volar-service-typescript: 0.0.33(@volar/language-service@2.1.2)
volar-service-typescript-twoslash-queries: 0.0.33(@volar/language-service@2.1.2) volar-service-typescript-twoslash-queries: 0.0.33(@volar/language-service@2.1.2)
vscode-html-languageservice: 5.1.2 vscode-html-languageservice: 5.1.2
vscode-uri: 3.0.8 vscode-uri: 3.0.8
optionalDependencies:
prettier: 2.8.8
transitivePeerDependencies: transitivePeerDependencies:
- typescript - typescript
@ -4992,16 +4987,15 @@ snapshots:
fast-xml-parser: 4.3.6 fast-xml-parser: 4.3.6
kleur: 4.1.5 kleur: 4.1.5
'@astrojs/sitemap@3.1.4': '@astrojs/sitemap@3.1.2':
dependencies: dependencies:
sitemap: 7.1.1 sitemap: 7.1.1
stream-replace-string: 2.0.0
zod: 3.22.4 zod: 3.22.4
'@astrojs/svelte@5.4.0(astro@4.4.15(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)(typescript@5.4.2))(svelte@4.2.12)(typescript@5.4.2)(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2))': '@astrojs/svelte@5.2.0(astro@4.4.15)(svelte@4.2.12)(typescript@5.4.2)(vite@5.1.6)':
dependencies: dependencies:
'@sveltejs/vite-plugin-svelte': 3.0.2(svelte@4.2.12)(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)) '@sveltejs/vite-plugin-svelte': 3.0.2(svelte@4.2.12)(vite@5.1.6)
astro: 4.4.15(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)(typescript@5.4.2) astro: 4.4.15(stylus@0.63.0)(typescript@5.4.2)
svelte: 4.2.12 svelte: 4.2.12
svelte2tsx: 0.6.27(svelte@4.2.12)(typescript@5.4.2) svelte2tsx: 0.6.27(svelte@4.2.12)(typescript@5.4.2)
typescript: 5.4.2 typescript: 5.4.2
@ -5009,9 +5003,9 @@ snapshots:
- supports-color - supports-color
- vite - vite
'@astrojs/tailwind@5.1.0(astro@4.4.15(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)(typescript@5.4.2))(tailwindcss@3.4.1)': '@astrojs/tailwind@5.1.0(astro@4.4.15)(tailwindcss@3.4.1)':
dependencies: dependencies:
astro: 4.4.15(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)(typescript@5.4.2) astro: 4.4.15(stylus@0.63.0)(typescript@5.4.2)
autoprefixer: 10.4.18(postcss@8.4.35) autoprefixer: 10.4.18(postcss@8.4.35)
postcss: 8.4.35 postcss: 8.4.35
postcss-load-config: 4.0.2(postcss@8.4.35) postcss-load-config: 4.0.2(postcss@8.4.35)
@ -5971,7 +5965,7 @@ snapshots:
'@iconify/types': 2.0.0 '@iconify/types': 2.0.0
'@iconify/utils': 2.1.22 '@iconify/utils': 2.1.22
'@types/cheerio': 0.22.35 '@types/cheerio': 0.22.35
'@types/tar': 6.1.13 '@types/tar': 6.1.11
cheerio: 1.0.0-rc.12 cheerio: 1.0.0-rc.12
extract-zip: 2.0.1 extract-zip: 2.0.1
local-pkg: 0.4.3 local-pkg: 0.4.3
@ -6213,14 +6207,12 @@ snapshots:
rollup: 2.79.1 rollup: 2.79.1
slash: 3.0.0 slash: 3.0.0
'@rollup/plugin-babel@5.3.1(@babel/core@7.24.0)(@types/babel__core@7.20.5)(rollup@2.79.1)': '@rollup/plugin-babel@5.3.1(@babel/core@7.24.0)(rollup@2.79.1)':
dependencies: dependencies:
'@babel/core': 7.24.0 '@babel/core': 7.24.0
'@babel/helper-module-imports': 7.22.15 '@babel/helper-module-imports': 7.22.15
'@rollup/pluginutils': 3.1.0(rollup@2.79.1) '@rollup/pluginutils': 3.1.0(rollup@2.79.1)
rollup: 2.79.1 rollup: 2.79.1
optionalDependencies:
'@types/babel__core': 7.20.5
'@rollup/plugin-commonjs@17.1.0(rollup@2.79.1)': '@rollup/plugin-commonjs@17.1.0(rollup@2.79.1)':
dependencies: dependencies:
@ -6252,9 +6244,8 @@ snapshots:
dependencies: dependencies:
'@rollup/pluginutils': 5.1.0(rollup@2.79.1) '@rollup/pluginutils': 5.1.0(rollup@2.79.1)
js-yaml: 4.1.0 js-yaml: 4.1.0
tosource: 2.0.0-alpha.3
optionalDependencies:
rollup: 2.79.1 rollup: 2.79.1
tosource: 2.0.0-alpha.3
'@rollup/pluginutils@3.1.0(rollup@2.79.1)': '@rollup/pluginutils@3.1.0(rollup@2.79.1)':
dependencies: dependencies:
@ -6273,7 +6264,6 @@ snapshots:
'@types/estree': 1.0.5 '@types/estree': 1.0.5
estree-walker: 2.0.2 estree-walker: 2.0.2
picomatch: 2.3.1 picomatch: 2.3.1
optionalDependencies:
rollup: 2.79.1 rollup: 2.79.1
'@rollup/rollup-android-arm-eabi@4.13.0': '@rollup/rollup-android-arm-eabi@4.13.0':
@ -6322,26 +6312,26 @@ snapshots:
magic-string: 0.25.9 magic-string: 0.25.9
string.prototype.matchall: 4.0.10 string.prototype.matchall: 4.0.10
'@sveltejs/vite-plugin-svelte-inspector@2.0.0(@sveltejs/vite-plugin-svelte@3.0.2(svelte@4.2.12)(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)))(svelte@4.2.12)(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2))': '@sveltejs/vite-plugin-svelte-inspector@2.0.0(@sveltejs/vite-plugin-svelte@3.0.2)(svelte@4.2.12)(vite@5.1.6)':
dependencies: dependencies:
'@sveltejs/vite-plugin-svelte': 3.0.2(svelte@4.2.12)(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)) '@sveltejs/vite-plugin-svelte': 3.0.2(svelte@4.2.12)(vite@5.1.6)
debug: 4.3.4 debug: 4.3.4
svelte: 4.2.12 svelte: 4.2.12
vite: 5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2) vite: 5.1.6(stylus@0.63.0)
transitivePeerDependencies: transitivePeerDependencies:
- supports-color - supports-color
'@sveltejs/vite-plugin-svelte@3.0.2(svelte@4.2.12)(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2))': '@sveltejs/vite-plugin-svelte@3.0.2(svelte@4.2.12)(vite@5.1.6)':
dependencies: dependencies:
'@sveltejs/vite-plugin-svelte-inspector': 2.0.0(@sveltejs/vite-plugin-svelte@3.0.2(svelte@4.2.12)(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)))(svelte@4.2.12)(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)) '@sveltejs/vite-plugin-svelte-inspector': 2.0.0(@sveltejs/vite-plugin-svelte@3.0.2)(svelte@4.2.12)(vite@5.1.6)
debug: 4.3.4 debug: 4.3.4
deepmerge: 4.3.1 deepmerge: 4.3.1
kleur: 4.1.5 kleur: 4.1.5
magic-string: 0.30.8 magic-string: 0.30.8
svelte: 4.2.12 svelte: 4.2.12
svelte-hmr: 0.15.3(svelte@4.2.12) svelte-hmr: 0.15.3(svelte@4.2.12)
vite: 5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2) vite: 5.1.6(stylus@0.63.0)
vitefu: 0.2.5(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)) vitefu: 0.2.5(vite@5.1.6)
transitivePeerDependencies: transitivePeerDependencies:
- supports-color - supports-color
@ -6352,22 +6342,22 @@ snapshots:
on-demand-live-region: 0.1.3 on-demand-live-region: 0.1.3
swup: 4.6.0 swup: 4.6.0
'@swup/astro@1.4.0(@types/babel__core@7.20.5)': '@swup/astro@1.4.0':
dependencies: dependencies:
'@swup/a11y-plugin': 4.5.0(swup@4.6.0) '@swup/a11y-plugin': 4.5.0(swup@4.6.0)
'@swup/body-class-plugin': 3.2.0(swup@4.6.0) '@swup/body-class-plugin': 3.2.0(swup@4.6.0)
'@swup/debug-plugin': 4.0.4(swup@4.6.0) '@swup/debug-plugin': 4.0.4(swup@4.6.0)
'@swup/fade-theme': 2.0.0(@types/babel__core@7.20.5)(swup@4.6.0) '@swup/fade-theme': 2.0.0(swup@4.6.0)
'@swup/forms-plugin': 3.4.2(swup@4.6.0) '@swup/forms-plugin': 3.4.2(swup@4.6.0)
'@swup/head-plugin': 2.2.0(swup@4.6.0) '@swup/head-plugin': 2.2.0(swup@4.6.0)
'@swup/overlay-theme': 2.0.0(@types/babel__core@7.20.5)(swup@4.6.0) '@swup/overlay-theme': 2.0.0(swup@4.6.0)
'@swup/parallel-plugin': 0.3.1(@types/babel__core@7.20.5)(swup@4.6.0) '@swup/parallel-plugin': 0.3.1(swup@4.6.0)
'@swup/preload-plugin': 3.2.10(swup@4.6.0) '@swup/preload-plugin': 3.2.10(swup@4.6.0)
'@swup/progress-plugin': 3.1.2(swup@4.6.0) '@swup/progress-plugin': 3.1.2(swup@4.6.0)
'@swup/route-name-plugin': 4.1.0(@types/babel__core@7.20.5)(swup@4.6.0) '@swup/route-name-plugin': 4.1.0(swup@4.6.0)
'@swup/scripts-plugin': 2.1.0(swup@4.6.0) '@swup/scripts-plugin': 2.1.0(swup@4.6.0)
'@swup/scroll-plugin': 3.3.2(swup@4.6.0) '@swup/scroll-plugin': 3.3.2(swup@4.6.0)
'@swup/slide-theme': 2.0.0(@types/babel__core@7.20.5)(swup@4.6.0) '@swup/slide-theme': 2.0.0(swup@4.6.0)
swup: 4.6.0 swup: 4.6.0
swup-morph-plugin: 1.3.0(swup@4.6.0) swup-morph-plugin: 1.3.0(swup@4.6.0)
transitivePeerDependencies: transitivePeerDependencies:
@ -6387,9 +6377,9 @@ snapshots:
'@swup/plugin': 4.0.0 '@swup/plugin': 4.0.0
swup: 4.6.0 swup: 4.6.0
'@swup/fade-theme@2.0.0(@types/babel__core@7.20.5)(swup@4.6.0)': '@swup/fade-theme@2.0.0(swup@4.6.0)':
dependencies: dependencies:
'@swup/plugin': 3.0.1(@types/babel__core@7.20.5) '@swup/plugin': 3.0.1
'@swup/theme': 2.1.0(swup@4.6.0) '@swup/theme': 2.1.0(swup@4.6.0)
swup: 4.6.0 swup: 4.6.0
transitivePeerDependencies: transitivePeerDependencies:
@ -6407,9 +6397,9 @@ snapshots:
'@swup/plugin': 4.0.0 '@swup/plugin': 4.0.0
swup: 4.6.0 swup: 4.6.0
'@swup/overlay-theme@2.0.0(@types/babel__core@7.20.5)(swup@4.6.0)': '@swup/overlay-theme@2.0.0(swup@4.6.0)':
dependencies: dependencies:
'@swup/plugin': 3.0.1(@types/babel__core@7.20.5) '@swup/plugin': 3.0.1
'@swup/theme': 2.1.0(swup@4.6.0) '@swup/theme': 2.1.0(swup@4.6.0)
swup: 4.6.0 swup: 4.6.0
transitivePeerDependencies: transitivePeerDependencies:
@ -6417,21 +6407,21 @@ snapshots:
- supports-color - supports-color
- ts-node - ts-node
'@swup/parallel-plugin@0.3.1(@types/babel__core@7.20.5)(swup@4.6.0)': '@swup/parallel-plugin@0.3.1(swup@4.6.0)':
dependencies: dependencies:
'@swup/plugin': 3.0.1(@types/babel__core@7.20.5) '@swup/plugin': 3.0.1
swup: 4.6.0 swup: 4.6.0
transitivePeerDependencies: transitivePeerDependencies:
- '@types/babel__core' - '@types/babel__core'
- supports-color - supports-color
- ts-node - ts-node
'@swup/plugin@3.0.1(@types/babel__core@7.20.5)': '@swup/plugin@3.0.1':
dependencies: dependencies:
'@swup/browserslist-config': 1.0.1 '@swup/browserslist-config': 1.0.1
'@swup/prettier-config': 1.1.0 '@swup/prettier-config': 1.1.0
chalk: 5.3.0 chalk: 5.3.0
microbundle: 0.15.1(@types/babel__core@7.20.5) microbundle: 0.15.1
prettier: 2.8.8 prettier: 2.8.8
shelljs: 0.8.5 shelljs: 0.8.5
shelljs-live: 0.0.5(shelljs@0.8.5) shelljs-live: 0.0.5(shelljs@0.8.5)
@ -6457,9 +6447,9 @@ snapshots:
'@swup/plugin': 4.0.0 '@swup/plugin': 4.0.0
swup: 4.6.0 swup: 4.6.0
'@swup/route-name-plugin@4.1.0(@types/babel__core@7.20.5)(swup@4.6.0)': '@swup/route-name-plugin@4.1.0(swup@4.6.0)':
dependencies: dependencies:
'@swup/plugin': 3.0.1(@types/babel__core@7.20.5) '@swup/plugin': 3.0.1
swup: 4.6.0 swup: 4.6.0
transitivePeerDependencies: transitivePeerDependencies:
- '@types/babel__core' - '@types/babel__core'
@ -6477,9 +6467,9 @@ snapshots:
scrl: 2.0.0 scrl: 2.0.0
swup: 4.6.0 swup: 4.6.0
'@swup/slide-theme@2.0.0(@types/babel__core@7.20.5)(swup@4.6.0)': '@swup/slide-theme@2.0.0(swup@4.6.0)':
dependencies: dependencies:
'@swup/plugin': 3.0.1(@types/babel__core@7.20.5) '@swup/plugin': 3.0.1
'@swup/theme': 2.1.0(swup@4.6.0) '@swup/theme': 2.1.0(swup@4.6.0)
swup: 4.6.0 swup: 4.6.0
transitivePeerDependencies: transitivePeerDependencies:
@ -6592,7 +6582,7 @@ snapshots:
dependencies: dependencies:
'@types/node': 20.11.28 '@types/node': 20.11.28
'@types/tar@6.1.13': '@types/tar@6.1.11':
dependencies: dependencies:
'@types/node': 20.11.28 '@types/node': 20.11.28
minipass: 4.2.8 minipass: 4.2.8
@ -6750,7 +6740,7 @@ snapshots:
transitivePeerDependencies: transitivePeerDependencies:
- supports-color - supports-color
astro@4.4.15(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)(typescript@5.4.2): astro@4.4.15(stylus@0.63.0)(typescript@5.4.2):
dependencies: dependencies:
'@astrojs/compiler': 2.7.0 '@astrojs/compiler': 2.7.0
'@astrojs/internal-helpers': 0.2.1 '@astrojs/internal-helpers': 0.2.1
@ -6811,8 +6801,8 @@ snapshots:
tsconfck: 3.0.3(typescript@5.4.2) tsconfck: 3.0.3(typescript@5.4.2)
unist-util-visit: 5.0.0 unist-util-visit: 5.0.0
vfile: 6.0.1 vfile: 6.0.1
vite: 5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2) vite: 5.1.6(stylus@0.63.0)
vitefu: 0.2.5(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)) vitefu: 0.2.5(vite@5.1.6)
which-pm: 2.1.1 which-pm: 2.1.1
yargs-parser: 21.1.1 yargs-parser: 21.1.1
zod: 3.22.4 zod: 3.22.4
@ -8502,7 +8492,7 @@ snapshots:
merge2@1.4.1: {} merge2@1.4.1: {}
microbundle@0.15.1(@types/babel__core@7.20.5): microbundle@0.15.1:
dependencies: dependencies:
'@babel/core': 7.24.0 '@babel/core': 7.24.0
'@babel/plugin-proposal-class-properties': 7.12.1(@babel/core@7.24.0) '@babel/plugin-proposal-class-properties': 7.12.1(@babel/core@7.24.0)
@ -8515,7 +8505,7 @@ snapshots:
'@babel/preset-flow': 7.24.0(@babel/core@7.24.0) '@babel/preset-flow': 7.24.0(@babel/core@7.24.0)
'@babel/preset-react': 7.23.3(@babel/core@7.24.0) '@babel/preset-react': 7.23.3(@babel/core@7.24.0)
'@rollup/plugin-alias': 3.1.9(rollup@2.79.1) '@rollup/plugin-alias': 3.1.9(rollup@2.79.1)
'@rollup/plugin-babel': 5.3.1(@babel/core@7.24.0)(@types/babel__core@7.20.5)(rollup@2.79.1) '@rollup/plugin-babel': 5.3.1(@babel/core@7.24.0)(rollup@2.79.1)
'@rollup/plugin-commonjs': 17.1.0(rollup@2.79.1) '@rollup/plugin-commonjs': 17.1.0(rollup@2.79.1)
'@rollup/plugin-json': 4.1.0(rollup@2.79.1) '@rollup/plugin-json': 4.1.0(rollup@2.79.1)
'@rollup/plugin-node-resolve': 11.2.1(rollup@2.79.1) '@rollup/plugin-node-resolve': 11.2.1(rollup@2.79.1)
@ -9130,16 +9120,14 @@ snapshots:
postcss-load-config@3.1.4(postcss@8.4.35): postcss-load-config@3.1.4(postcss@8.4.35):
dependencies: dependencies:
lilconfig: 2.1.0 lilconfig: 2.1.0
yaml: 1.10.2
optionalDependencies:
postcss: 8.4.35 postcss: 8.4.35
yaml: 1.10.2
postcss-load-config@4.0.2(postcss@8.4.35): postcss-load-config@4.0.2(postcss@8.4.35):
dependencies: dependencies:
lilconfig: 3.1.1 lilconfig: 3.1.1
yaml: 2.4.1
optionalDependencies:
postcss: 8.4.35 postcss: 8.4.35
yaml: 2.4.1
postcss-merge-longhand@5.1.7(postcss@8.4.35): postcss-merge-longhand@5.1.7(postcss@8.4.35):
dependencies: dependencies:
@ -9311,7 +9299,7 @@ snapshots:
prebuild-install@7.1.2: prebuild-install@7.1.2:
dependencies: dependencies:
detect-libc: 2.0.3 detect-libc: 2.0.2
expand-template: 2.0.3 expand-template: 2.0.3
github-from-package: 0.0.0 github-from-package: 0.0.0
minimist: 1.2.8 minimist: 1.2.8
@ -9643,10 +9631,9 @@ snapshots:
dependencies: dependencies:
open: 8.4.2 open: 8.4.2
picomatch: 2.3.1 picomatch: 2.3.1
rollup: 2.79.1
source-map: 0.7.4 source-map: 0.7.4
yargs: 17.7.2 yargs: 17.7.2
optionalDependencies:
rollup: 2.79.1
rollup-pluginutils@2.8.2: rollup-pluginutils@2.8.2:
dependencies: dependencies:
@ -9747,7 +9734,7 @@ snapshots:
sharp@0.32.6: sharp@0.32.6:
dependencies: dependencies:
color: 4.2.3 color: 4.2.3
detect-libc: 2.0.3 detect-libc: 2.0.2
node-addon-api: 6.1.0 node-addon-api: 6.1.0
prebuild-install: 7.1.2 prebuild-install: 7.1.2
semver: 7.6.0 semver: 7.6.0
@ -9890,8 +9877,6 @@ snapshots:
dependencies: dependencies:
bl: 5.1.0 bl: 5.1.0
stream-replace-string@2.0.0: {}
streamx@2.16.1: streamx@2.16.1:
dependencies: dependencies:
fast-fifo: 1.3.2 fast-fifo: 1.3.2
@ -10203,7 +10188,7 @@ snapshots:
ts-interface-checker@0.1.13: {} ts-interface-checker@0.1.13: {}
tsconfck@3.0.3(typescript@5.4.2): tsconfck@3.0.3(typescript@5.4.2):
optionalDependencies: dependencies:
typescript: 5.4.2 typescript: 5.4.2
tslib@2.6.2: {} tslib@2.6.2: {}
@ -10408,65 +10393,56 @@ snapshots:
unist-util-stringify-position: 4.0.0 unist-util-stringify-position: 4.0.0
vfile-message: 4.0.2 vfile-message: 4.0.2
vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2): vite@5.1.6(stylus@0.63.0):
dependencies: dependencies:
esbuild: 0.19.12 esbuild: 0.19.12
postcss: 8.4.35 postcss: 8.4.35
rollup: 4.13.0 rollup: 4.13.0
optionalDependencies:
'@types/node': 20.11.28
fsevents: 2.3.3
lightningcss: 1.24.1
stylus: 0.63.0 stylus: 0.63.0
terser: 5.29.2
vitefu@0.2.5(vite@5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2)):
optionalDependencies: optionalDependencies:
vite: 5.1.6(@types/node@20.11.28)(lightningcss@1.24.1)(stylus@0.63.0)(terser@5.29.2) fsevents: 2.3.3
vitefu@0.2.5(vite@5.1.6):
dependencies:
vite: 5.1.6(stylus@0.63.0)
volar-service-css@0.0.33(@volar/language-service@2.1.2): volar-service-css@0.0.33(@volar/language-service@2.1.2):
dependencies: dependencies:
'@volar/language-service': 2.1.2
vscode-css-languageservice: 6.2.12 vscode-css-languageservice: 6.2.12
vscode-languageserver-textdocument: 1.0.11 vscode-languageserver-textdocument: 1.0.11
vscode-uri: 3.0.8 vscode-uri: 3.0.8
optionalDependencies:
'@volar/language-service': 2.1.2
volar-service-emmet@0.0.33(@volar/language-service@2.1.2): volar-service-emmet@0.0.33(@volar/language-service@2.1.2):
dependencies: dependencies:
'@volar/language-service': 2.1.2
'@vscode/emmet-helper': 2.9.2 '@vscode/emmet-helper': 2.9.2
vscode-html-languageservice: 5.1.2 vscode-html-languageservice: 5.1.2
optionalDependencies:
'@volar/language-service': 2.1.2
volar-service-html@0.0.33(@volar/language-service@2.1.2): volar-service-html@0.0.33(@volar/language-service@2.1.2):
dependencies: dependencies:
'@volar/language-service': 2.1.2
vscode-html-languageservice: 5.1.2 vscode-html-languageservice: 5.1.2
vscode-languageserver-textdocument: 1.0.11 vscode-languageserver-textdocument: 1.0.11
vscode-uri: 3.0.8 vscode-uri: 3.0.8
optionalDependencies:
'@volar/language-service': 2.1.2
volar-service-prettier@0.0.33(@volar/language-service@2.1.2)(prettier@2.8.8): volar-service-prettier@0.0.33(@volar/language-service@2.1.2):
dependencies: dependencies:
vscode-uri: 3.0.8
optionalDependencies:
'@volar/language-service': 2.1.2 '@volar/language-service': 2.1.2
prettier: 2.8.8 vscode-uri: 3.0.8
volar-service-typescript-twoslash-queries@0.0.33(@volar/language-service@2.1.2): volar-service-typescript-twoslash-queries@0.0.33(@volar/language-service@2.1.2):
optionalDependencies: dependencies:
'@volar/language-service': 2.1.2 '@volar/language-service': 2.1.2
volar-service-typescript@0.0.33(@volar/language-service@2.1.2): volar-service-typescript@0.0.33(@volar/language-service@2.1.2):
dependencies: dependencies:
'@volar/language-service': 2.1.2
path-browserify: 1.0.1 path-browserify: 1.0.1
semver: 7.6.0 semver: 7.6.0
typescript-auto-import-cache: 0.3.2 typescript-auto-import-cache: 0.3.2
vscode-languageserver-textdocument: 1.0.11 vscode-languageserver-textdocument: 1.0.11
vscode-nls: 5.2.0 vscode-nls: 5.2.0
optionalDependencies:
'@volar/language-service': 2.1.2
vscode-css-languageservice@6.2.12: vscode-css-languageservice@6.2.12:
dependencies: dependencies:

View File

@ -115,11 +115,11 @@ color_set({
--display-light-icon: 1 0 --display-light-icon: 1 0
--display-dark-icon: 0 1 --display-dark-icon: 0 1
--admonitions-color-tip: mix(#90d73e, hsl(0 1 20), 92%) #90d73e --admonitions-color-tip: oklch(0.7 0.14 180) oklch(0.75 0.14 180)
--admonitions-color-note: mix(#13c6dd, hsl(0 1 20), 92%) #13c6dd --admonitions-color-note: oklch(0.7 0.14 250) oklch(0.75 0.14 250)
--admonitions-color-important: mix(#bf4ef0, hsl(0 1 20), 92%) #bf4ef0 --admonitions-color-important: oklch(0.7 0.14 310) oklch(0.75 0.14 310)
--admonitions-color-warning: mix(#e3ab29, hsl(0 1 20), 92%) #e3ab29 --admonitions-color-warning: oklch(0.7 0.14 60) oklch(0.75 0.14 60)
--admonitions-color-caution: mix(#df3b38, hsl(0 1 20), 92%) #df3b38 --admonitions-color-caution: oklch(0.6 0.2 25) oklch(0.65 0.2 25)
}) })

View File

@ -10,26 +10,29 @@ const className = Astro.props.class;
<div data-pagefind-body class=`prose dark:prose-invert prose-base max-w-none custom-md ${className}`> <div data-pagefind-body class=`prose dark:prose-invert prose-base max-w-none custom-md ${className}`>
<!--<div class="prose dark:prose-invert max-w-none custom-md">--> <!--<div class="prose dark:prose-invert max-w-none custom-md">-->
<!--<div class="max-w-none custom-md">--> <!--<div class="max-w-none custom-md">-->
<slot /> <slot/>
</div> </div>
<style lang="stylus" is:global> <style lang="stylus" is:global>
.custom-md .custom-md
h1,h2,h3,h4,h5,h6 h1, h2, h3, h4, h5, h6
.anchor .anchor
margin: -0.125rem margin: -0.125rem !important
margin-left: 0.2ch margin-left: 0.2ch !important
padding: 0.125rem padding: 0.125rem !important
user-select: none user-select: none !important
opacity: 0 opacity: 0 !important
text-decoration: none text-decoration: none !important
transition: opacity 0.15s ease-in-out, background 0.15s ease-in-out transition: opacity 0.15s ease-in-out, background 0.15s ease-in-out !important
.anchor-icon .anchor-icon
margin-left: 0.45ch margin-left: 0.45ch !important
margin-right: 0.45ch margin-right: 0.45ch !important
&:hover &:hover
.anchor .anchor
opacity: 1 opacity: 1 !important
a:not(.no-styling) a:not(.no-styling)
position: relative position: relative
background: none background: none
@ -54,26 +57,30 @@ const className = Astro.props.class;
/* background: var(--link-hover)*/ /* background: var(--link-hover)*/
/* transition: background 0.15s ease-in-out;*/ /* transition: background 0.15s ease-in-out;*/
/* z-index: -1;*/ /* z-index: -1;*/
&:hover &:hover
background: var(--link-hover) background: var(--link-hover)
text-decoration-color: var(--link-hover) text-decoration-color: var(--link-hover)
&:active &:active
background: var(--link-active) background: var(--link-active)
text-decoration-color: var(--link-active) text-decoration-color: var(--link-active)
/*&:after*/
/* background: var(--link-active)*/
code code
font-family: 'JetBrains Mono Variable',ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace font-family: 'JetBrains Mono Variable', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace
background: var(--inline-code-bg) background: var(--inline-code-bg)
color: var(--inline-code-color) color: var(--inline-code-color)
padding: 0.125rem 0.25rem padding: 0.125rem 0.25rem
border-radius: 0.25rem border-radius: 0.25rem
overflow: hidden overflow: hidden
counter-reset: line counter-reset: line
&:before &:before
content: none content: none
&:after &:after
content: none content: none
span.line span.line
&:before &:before
content: counter(line) content: counter(line)
@ -83,33 +90,41 @@ const className = Astro.props.class;
margin-right: 1rem margin-right: 1rem
width: 1rem width: 1rem
color: rgba(255, 255, 255, 0.25) color: rgba(255, 255, 255, 0.25)
pre pre
background: var(--codeblock-bg) !important background: var(--codeblock-bg) !important
border-radius: 0.75rem border-radius: 0.75rem
padding-left: 1.25rem padding-left: 1.25rem
padding-right: 1.25rem padding-right: 1.25rem
code code
color: unset color: unset
font-size: 0.875rem font-size: 0.875rem
padding: 0 padding: 0
background: none background: none
::selection ::selection
background: var(--codeblock-selection) background: var(--codeblock-selection)
span.br::selection span.br::selection
background: var(--codeblock-selection) background: var(--codeblock-selection)
ul ul
li li
&::marker &::marker
color: var(--primary) color: var(--primary)
ol ol
li li
&::marker &::marker
color: var(--primary) color: var(--primary)
blockquote blockquote
font-style: normal font-style: normal
font-weight: inherit font-weight: inherit
border-left-color: rgba(0,0,0,0) border-left-color: rgba(0, 0, 0, 0)
position: relative; position: relative;
&:before &:before
content: '' content: ''
position: absolute position: absolute
@ -120,17 +135,21 @@ const className = Astro.props.class;
height: 100% height: 100%
width: 0.25rem width: 0.25rem
border-radius: 1rem border-radius: 1rem
p p
&:before &:before
content: none content: none
&:after &:after
content: none content: none
blockquote.admonition blockquote.admonition
.bdm-title .bdm-title
display: block display: flex
align-items: center
margin-bottom: -.9rem margin-bottom: -.9rem
font-weight: bold font-weight: bold
&:before &:before
content: ' ' content: ' '
display: inline-block display: inline-block
@ -143,208 +162,243 @@ const className = Astro.props.class;
mask-size: contain mask-size: contain
mask-position: center mask-position: center
mask-repeat: no-repeat mask-repeat: no-repeat
transform: translateY(-0.0625rem)
&.bdm-tip &.bdm-tip
.bdm-title .bdm-title
color: var(--admonitions-color-tip) color: var(--admonitions-color-tip)
&:before &:before
background: var(--admonitions-color-tip) background: var(--admonitions-color-tip)
mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' width='16' height='16' aria-hidden='true'%3E%3Cpath d='M8 1.5c-2.363 0-4 1.69-4 3.75 0 .984.424 1.625.984 2.304l.214.253c.223.264.47.556.673.848.284.411.537.896.621 1.49a.75.75 0 0 1-1.484.211c-.04-.282-.163-.547-.37-.847a8.456 8.456 0 0 0-.542-.68c-.084-.1-.173-.205-.268-.32C3.201 7.75 2.5 6.766 2.5 5.25 2.5 2.31 4.863 0 8 0s5.5 2.31 5.5 5.25c0 1.516-.701 2.5-1.328 3.259-.095.115-.184.22-.268.319-.207.245-.383.453-.541.681-.208.3-.33.565-.37.847a.751.751 0 0 1-1.485-.212c.084-.593.337-1.078.621-1.489.203-.292.45-.584.673-.848.075-.088.147-.173.213-.253.561-.679.985-1.32.985-2.304 0-2.06-1.637-3.75-4-3.75ZM5.75 12h4.5a.75.75 0 0 1 0 1.5h-4.5a.75.75 0 0 1 0-1.5ZM6 15.25a.75.75 0 0 1 .75-.75h2.5a.75.75 0 0 1 0 1.5h-2.5a.75.75 0 0 1-.75-.75Z'%3E%3C/path%3E%3C/svg%3E") mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' width='16' height='16' aria-hidden='true'%3E%3Cpath d='M8 1.5c-2.363 0-4 1.69-4 3.75 0 .984.424 1.625.984 2.304l.214.253c.223.264.47.556.673.848.284.411.537.896.621 1.49a.75.75 0 0 1-1.484.211c-.04-.282-.163-.547-.37-.847a8.456 8.456 0 0 0-.542-.68c-.084-.1-.173-.205-.268-.32C3.201 7.75 2.5 6.766 2.5 5.25 2.5 2.31 4.863 0 8 0s5.5 2.31 5.5 5.25c0 1.516-.701 2.5-1.328 3.259-.095.115-.184.22-.268.319-.207.245-.383.453-.541.681-.208.3-.33.565-.37.847a.751.751 0 0 1-1.485-.212c.084-.593.337-1.078.621-1.489.203-.292.45-.584.673-.848.075-.088.147-.173.213-.253.561-.679.985-1.32.985-2.304 0-2.06-1.637-3.75-4-3.75ZM5.75 12h4.5a.75.75 0 0 1 0 1.5h-4.5a.75.75 0 0 1 0-1.5ZM6 15.25a.75.75 0 0 1 .75-.75h2.5a.75.75 0 0 1 0 1.5h-2.5a.75.75 0 0 1-.75-.75Z'%3E%3C/path%3E%3C/svg%3E")
&:before &:before
background: var(--admonitions-color-tip) background: var(--admonitions-color-tip)
&.bdm-note &.bdm-note
.bdm-title .bdm-title
color: var(--admonitions-color-note) color: var(--admonitions-color-note)
&:before &:before
background: var(--admonitions-color-note) background: var(--admonitions-color-note)
mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' width='16' height='16' aria-hidden='true'%3E%3Cpath fill='var(--admonitions-color-tip)' d='M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8Zm8-6.5a6.5 6.5 0 1 0 0 13 6.5 6.5 0 0 0 0-13ZM6.5 7.75A.75.75 0 0 1 7.25 7h1a.75.75 0 0 1 .75.75v2.75h.25a.75.75 0 0 1 0 1.5h-2a.75.75 0 0 1 0-1.5h.25v-2h-.25a.75.75 0 0 1-.75-.75ZM8 6a1 1 0 1 1 0-2 1 1 0 0 1 0 2Z'%3E%3C/path%3E%3C/svg%3E") mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' width='16' height='16' aria-hidden='true'%3E%3Cpath fill='var(--admonitions-color-tip)' d='M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8Zm8-6.5a6.5 6.5 0 1 0 0 13 6.5 6.5 0 0 0 0-13ZM6.5 7.75A.75.75 0 0 1 7.25 7h1a.75.75 0 0 1 .75.75v2.75h.25a.75.75 0 0 1 0 1.5h-2a.75.75 0 0 1 0-1.5h.25v-2h-.25a.75.75 0 0 1-.75-.75ZM8 6a1 1 0 1 1 0-2 1 1 0 0 1 0 2Z'%3E%3C/path%3E%3C/svg%3E")
&:before &:before
background: var(--admonitions-color-note) background: var(--admonitions-color-note)
&.bdm-important &.bdm-important
.bdm-title .bdm-title
color: var(--admonitions-color-important) color: var(--admonitions-color-important)
&:before &:before
background: var(--admonitions-color-important) background: var(--admonitions-color-important)
mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' width='16' height='16' aria-hidden='true'%3E%3Cpath d='M0 1.75C0 .784.784 0 1.75 0h12.5C15.216 0 16 .784 16 1.75v9.5A1.75 1.75 0 0 1 14.25 13H8.06l-2.573 2.573A1.458 1.458 0 0 1 3 14.543V13H1.75A1.75 1.75 0 0 1 0 11.25Zm1.75-.25a.25.25 0 0 0-.25.25v9.5c0 .138.112.25.25.25h2a.75.75 0 0 1 .75.75v2.19l2.72-2.72a.749.749 0 0 1 .53-.22h6.5a.25.25 0 0 0 .25-.25v-9.5a.25.25 0 0 0-.25-.25Zm7 2.25v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 9a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z'%3E%3C/path%3E%3C/svg%3E") mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' width='16' height='16' aria-hidden='true'%3E%3Cpath d='M0 1.75C0 .784.784 0 1.75 0h12.5C15.216 0 16 .784 16 1.75v9.5A1.75 1.75 0 0 1 14.25 13H8.06l-2.573 2.573A1.458 1.458 0 0 1 3 14.543V13H1.75A1.75 1.75 0 0 1 0 11.25Zm1.75-.25a.25.25 0 0 0-.25.25v9.5c0 .138.112.25.25.25h2a.75.75 0 0 1 .75.75v2.19l2.72-2.72a.749.749 0 0 1 .53-.22h6.5a.25.25 0 0 0 .25-.25v-9.5a.25.25 0 0 0-.25-.25Zm7 2.25v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 9a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z'%3E%3C/path%3E%3C/svg%3E")
&:before &:before
background: var(--admonitions-color-important) background: var(--admonitions-color-important)
&.bdm-warning &.bdm-warning
.bdm-title .bdm-title
color: var(--admonitions-color-warning) color: var(--admonitions-color-warning)
&:before &:before
background: var(--admonitions-color-warning) background: var(--admonitions-color-warning)
mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' width='16' height='16' aria-hidden='true'%3E%3Cpath d='M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z'%3E%3C/path%3E%3C/svg%3E") mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' width='16' height='16' aria-hidden='true'%3E%3Cpath d='M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z'%3E%3C/path%3E%3C/svg%3E")
&:before &:before
background: var(--admonitions-color-warning) background: var(--admonitions-color-warning)
&.bdm-caution &.bdm-caution
.bdm-title .bdm-title
color: var(--admonitions-color-caution) color: var(--admonitions-color-caution)
&:before &:before
background: var(--admonitions-color-caution) background: var(--admonitions-color-caution)
mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' width='16' height='16' aria-hidden='true'%3E%3Cpath d='M4.47.22A.749.749 0 0 1 5 0h6c.199 0 .389.079.53.22l4.25 4.25c.141.14.22.331.22.53v6a.749.749 0 0 1-.22.53l-4.25 4.25A.749.749 0 0 1 11 16H5a.749.749 0 0 1-.53-.22L.22 11.53A.749.749 0 0 1 0 11V5c0-.199.079-.389.22-.53Zm.84 1.28L1.5 5.31v5.38l3.81 3.81h5.38l3.81-3.81V5.31L10.69 1.5ZM8 4a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 4Zm0 8a1 1 0 1 1 0-2 1 1 0 0 1 0 2Z'%3E%3C/path%3E%3C/svg%3E") mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' width='16' height='16' aria-hidden='true'%3E%3Cpath d='M4.47.22A.749.749 0 0 1 5 0h6c.199 0 .389.079.53.22l4.25 4.25c.141.14.22.331.22.53v6a.749.749 0 0 1-.22.53l-4.25 4.25A.749.749 0 0 1 11 16H5a.749.749 0 0 1-.53-.22L.22 11.53A.749.749 0 0 1 0 11V5c0-.199.079-.389.22-.53Zm.84 1.28L1.5 5.31v5.38l3.81 3.81h5.38l3.81-3.81V5.31L10.69 1.5ZM8 4a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 4Zm0 8a1 1 0 1 1 0-2 1 1 0 0 1 0 2Z'%3E%3C/path%3E%3C/svg%3E")
&:before &:before
background: var(--admonitions-color-caution) background: var(--admonitions-color-caution)
img img
border-radius: 0.75rem border-radius: 0.75rem
hr hr
border-color: var(--line-divider) border-color: var(--line-divider)
border-style: dashed border-style: dashed
iframe iframe
border-radius: 0.75rem border-radius: 0.75rem
margin-left: auto margin-left: auto
margin-right: auto margin-right: auto
max-width: 100% max-width: 100%
a.card-github a.card-github
display: block display: block
position: relative background: var(--license-block-bg)
margin: 0.5rem 0 position: relative
padding: 1.1rem 1.5rem 0.9rem 1.5rem margin: 0.5rem 0
color: var(--tw-prose-body) padding: 1.1rem 1.5rem 1.1rem 1.5rem
border-radius: var(--radius-large) color: var(--tw-prose-body)
text-decoration-thickness: 0px border-radius: var(--radius-large)
text-decoration-line: none text-decoration-thickness: 0px
box-shadow: #00000020 0px 3px 12px text-decoration-line: none
transition-property: color, background-color, opacity
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1) &:hover
transition-duration: 0.15s background-color: var(--btn-regular-bg-hover)
&:hover
background-color: var(--btn-regular-bg-hover)
.gc-titlebar
color: var(--btn-content)
gap: 0.1rem
.gc-owner
background-color: transparent
padding: 0.1rem 0rem 0rem 0rem
gap: 0
.gc-avatar
width: 0
.gc-stars, .gc-forks, .gc-license, .gc-description
color: var(--tw-prose-headings)
&:before
background-color: var(--tw-prose-headings)
&:active
scale: .99
background-color: var(--btn-regular-bg-active);
.gc-titlebar .gc-titlebar
color: var(--btn-content)
.gc-stars, .gc-forks, .gc-license, .gc-description
color: var(--tw-prose-headings)
&:before
background-color: var(--tw-prose-headings)
&:active
scale: .98
background-color: var(--btn-regular-bg-active);
.gc-titlebar
display: flex
align-items: center
justify-content: space-between
margin-bottom: 0.5rem
color: var(--tw-prose-headings)
font-size: 1.25rem
font-weight: 500
.gc-titlebar-left
display: flex
flex-flow: row nowrap
gap: 0.5rem
.gc-repo
font-weight: bold
.gc-owner
font-weight: 300
position: relative
display: flex display: flex
flex-flow: row nowrap flex-flow: row nowrap
gap: 0.5rem gap: 0.5rem
align-items: center align-items: center
margin-bottom: 0.5rem
color: var(--tw-prose-headings) .gc-avatar
font-size: 1.25rem display: block
font-weight: 500 overflow: hidden
transition-property: gap, padding, width; width: 1.5rem
height: 1.5rem
margin-top: -0.1rem
background-color: var(--primary)
background-size: cover
border-radius: 50%
.gc-description
margin-bottom: 0.7rem
font-size: 1rem
font-weight: 300
line-height: 1.5rem
color: var(--tw-prose-body)
.gc-infobar
display: flex
flex-flow: row nowrap
gap: 1.5rem
color: var(--tw-prose-body)
width: fit-content
.gc-language
display: none
.gc-stars, .gc-forks, .gc-license, .github-logo
font-weight: 500
font-size: 0.875rem
opacity: 0.9;
&:before
content: ' '
display: inline-block
height: 1.3em
width: 1.3em
margin-right: .4rem
vertical-align: -.24em
font-size: inherit
background-color: var(--tw-prose-body)
overflow: visible
mask-size: contain
mask-position: center
mask-repeat: no-repeat
transition-property: background-color, background;
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1) transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1)
transition-duration: 0.15s transition-duration: 0.15s
.gc-divider, .gc-repo
padding: 0.1rem 0rem 0rem 0rem .gc-stars
.gc-owner &:before
position: relative mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' aria-hidden='true' height='16' viewBox='0 0 16 16' version='1.1' width='16'%3E%3Cpath d='M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.751.751 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194L.818 6.374a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25Zm0 2.445L6.615 5.5a.75.75 0 0 1-.564.41l-3.097.45 2.24 2.184a.75.75 0 0 1 .216.664l-.528 3.084 2.769-1.456a.75.75 0 0 1 .698 0l2.77 1.456-.53-3.084a.75.75 0 0 1 .216-.664l2.24-2.183-3.096-.45a.75.75 0 0 1-.564-.41L8 2.694Z'%3E%3C/path%3E%3C/svg%3E")
display: flex
flex-flow: row nowrap .gc-license
gap: 0.5rem &:before
align-items: center margin-right: .5rem
padding: 0.1rem 0.6rem 0rem 0.6rem mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' aria-hidden='true' height='16' viewBox='0 0 16 16' version='1.1' width='16'%3E%3Cpath d='M8.75.75V2h.985c.304 0 .603.08.867.231l1.29.736c.038.022.08.033.124.033h2.234a.75.75 0 0 1 0 1.5h-.427l2.111 4.692a.75.75 0 0 1-.154.838l-.53-.53.529.531-.001.002-.002.002-.006.006-.006.005-.01.01-.045.04c-.21.176-.441.327-.686.45C14.556 10.78 13.88 11 13 11a4.498 4.498 0 0 1-2.023-.454 3.544 3.544 0 0 1-.686-.45l-.045-.04-.016-.015-.006-.006-.004-.004v-.001a.75.75 0 0 1-.154-.838L12.178 4.5h-.162c-.305 0-.604-.079-.868-.231l-1.29-.736a.245.245 0 0 0-.124-.033H8.75V13h2.5a.75.75 0 0 1 0 1.5h-6.5a.75.75 0 0 1 0-1.5h2.5V3.5h-.984a.245.245 0 0 0-.124.033l-1.289.737c-.265.15-.564.23-.869.23h-.162l2.112 4.692a.75.75 0 0 1-.154.838l-.53-.53.529.531-.001.002-.002.002-.006.006-.016.015-.045.04c-.21.176-.441.327-.686.45C4.556 10.78 3.88 11 3 11a4.498 4.498 0 0 1-2.023-.454 3.544 3.544 0 0 1-.686-.45l-.045-.04-.016-.015-.006-.006-.004-.004v-.001a.75.75 0 0 1-.154-.838L2.178 4.5H1.75a.75.75 0 0 1 0-1.5h2.234a.249.249 0 0 0 .125-.033l1.288-.737c.265-.15.564-.23.869-.23h.984V.75a.75.75 0 0 1 1.5 0Zm2.945 8.477c.285.135.718.273 1.305.273s1.02-.138 1.305-.273L13 6.327Zm-10 0c.285.135.718.273 1.305.273s1.02-.138 1.305-.273L3 6.327Z'%3E%3C/path%3E%3C/svg%3E")
color: var(--btn-content)
background-color: var(--btn-regular-bg) .gc-forks
border-radius: 0.5rem &:before
transition-property: color, background, background-color, opacity, gap, padding, width; mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' aria-hidden='true' height='16' viewBox='0 0 16 16' version='1.1' width='16'%3E%3Cpath d='M5 5.372v.878c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75v-.878a2.25 2.25 0 1 1 1.5 0v.878a2.25 2.25 0 0 1-2.25 2.25h-1.5v2.128a2.251 2.251 0 1 1-1.5 0V8.5h-1.5A2.25 2.25 0 0 1 3.5 6.25v-.878a2.25 2.25 0 1 1 1.5 0ZM5 3.25a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Zm6.75.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Zm-3 8.75a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Z'%3E%3C/path%3E%3C/svg%3E")
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1)
transition-duration: 0.15s .github-logo
.gc-avatar font-size: 1.25rem
display: block
overflow: hidden &:before
width: 1.4rem background-color: var(--tw-prose-headings)
height: 1.4rem margin-right: 0
margin-top: -0.1rem mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='31' height='32' viewBox='0 0 496 512'%3E%3Cpath fill='%23a1f7cb' d='M165.9 397.4c0 2-2.3 3.6-5.2 3.6c-3.3.3-5.6-1.3-5.6-3.6c0-2 2.3-3.6 5.2-3.6c3-.3 5.6 1.3 5.6 3.6m-31.1-4.5c-.7 2 1.3 4.3 4.3 4.9c2.6 1 5.6 0 6.2-2s-1.3-4.3-4.3-5.2c-2.6-.7-5.5.3-6.2 2.3m44.2-1.7c-2.9.7-4.9 2.6-4.6 4.9c.3 2 2.9 3.3 5.9 2.6c2.9-.7 4.9-2.6 4.6-4.6c-.3-1.9-3-3.2-5.9-2.9M244.8 8C106.1 8 0 113.3 0 252c0 110.9 69.8 205.8 169.5 239.2c12.8 2.3 17.3-5.6 17.3-12.1c0-6.2-.3-40.4-.3-61.4c0 0-70 15-84.7-29.8c0 0-11.4-29.1-27.8-36.6c0 0-22.9-15.7 1.6-15.4c0 0 24.9 2 38.6 25.8c21.9 38.6 58.6 27.5 72.9 20.9c2.3-16 8.8-27.1 16-33.7c-55.9-6.2-112.3-14.3-112.3-110.5c0-27.5 7.6-41.3 23.6-58.9c-2.6-6.5-11.1-33.3 2.6-67.9c20.9-6.5 69 27 69 27c20-5.6 41.5-8.5 62.8-8.5s42.8 2.9 62.8 8.5c0 0 48.1-33.6 69-27c13.7 34.7 5.2 61.4 2.6 67.9c16 17.7 25.8 31.5 25.8 58.9c0 96.5-58.9 104.2-114.8 110.5c9.2 7.9 17 22.9 17 46.4c0 33.7-.3 75.4-.3 83.6c0 6.5 4.6 14.4 17.3 12.1C428.2 457.8 496 362.9 496 252C496 113.3 383.5 8 244.8 8M97.2 352.9c-1.3 1-1 3.3.7 5.2c1.6 1.6 3.9 2.3 5.2 1c1.3-1 1-3.3-.7-5.2c-1.6-1.6-3.9-2.3-5.2-1m-10.8-8.1c-.7 1.3.3 2.9 2.3 3.9c1.6 1 3.6.7 4.3-.7c.7-1.3-.3-2.9-2.3-3.9c-2-.6-3.6-.3-4.3.7m32.4 35.6c-1.6 1.3-1 4.3 1.3 6.2c2.3 2.3 5.2 2.6 6.5 1c1.3-1.3.7-4.3-1.3-6.2c-2.2-2.3-5.2-2.6-6.5-1m-11.4-14.7c-1.6 1-1.6 3.6 0 5.9c1.6 2.3 4.3 3.3 5.6 2.3c1.6-1.3 1.6-3.9 0-6.2c-1.4-2.3-4-3.3-5.6-2'/%3E%3C/svg%3E")
background-color: var(--primary)
background-size: cover a.card-github.fetch-waiting
border-radius: 50% pointer-events: none
transition-property: color, background-color, opacity, gap, padding, width; opacity: 0.7
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1) transition: opacity 0.15s ease-in-out
transition-duration: 0.15s
.gc-description .gc-description, .gc-infobar
margin-bottom: 0.7rem background-color: var(--tw-prose-body)
font-size: 0.96em color: transparent
font-weight: 400 opacity: 0.5;
line-height: 1.4em border-radius: 0.5rem
color: var(--tw-prose-body) animation: pulsate 2s infinite linear
.gc-infobar user-select: none
display: flex
flex-flow: row nowrap &:before
gap: 1.4em background-color: transparent
color: var(--tw-prose-body)
.gc-language .gc-avatar
display: none display: none
.gc-stars, .gc-forks, .gc-license
font-weight: 500 .gc-repo
font-size: 0.96em margin-left: -0.1rem
opacity: 0.9;
&:before a.card-github.fetch-error
content: ' ' pointer-events: all
display: inline-block opacity: 1
height: 1.3em
width: 1.3em @keyframes pulsate
margin-right: .4rem 0%
vertical-align: -.24em opacity: 0.15
font-size: inherit 50%
background-color: var(--tw-prose-body) opacity: 0.25
overflow: visible 100%
mask-size: contain opacity: 0.15
mask-position: center
mask-repeat: no-repeat .card-github, .gc-description, .gc-titlebar, .gc-stars, .gc-forks, .gc-license, .gc-avatar, github-logo
transition-property: background-color, background; transition-property: all
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1) transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1)
transition-duration: 0.15s transition-duration: 0.15s
.gc-stars
&:before
mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' aria-hidden='true' height='16' viewBox='0 0 16 16' version='1.1' width='16'%3E%3Cpath d='M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.751.751 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194L.818 6.374a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25Zm0 2.445L6.615 5.5a.75.75 0 0 1-.564.41l-3.097.45 2.24 2.184a.75.75 0 0 1 .216.664l-.528 3.084 2.769-1.456a.75.75 0 0 1 .698 0l2.77 1.456-.53-3.084a.75.75 0 0 1 .216-.664l2.24-2.183-3.096-.45a.75.75 0 0 1-.564-.41L8 2.694Z'%3E%3C/path%3E%3C/svg%3E")
.gc-license
&:before
margin-right: .5rem
mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' aria-hidden='true' height='16' viewBox='0 0 16 16' version='1.1' width='16'%3E%3Cpath d='M8.75.75V2h.985c.304 0 .603.08.867.231l1.29.736c.038.022.08.033.124.033h2.234a.75.75 0 0 1 0 1.5h-.427l2.111 4.692a.75.75 0 0 1-.154.838l-.53-.53.529.531-.001.002-.002.002-.006.006-.006.005-.01.01-.045.04c-.21.176-.441.327-.686.45C14.556 10.78 13.88 11 13 11a4.498 4.498 0 0 1-2.023-.454 3.544 3.544 0 0 1-.686-.45l-.045-.04-.016-.015-.006-.006-.004-.004v-.001a.75.75 0 0 1-.154-.838L12.178 4.5h-.162c-.305 0-.604-.079-.868-.231l-1.29-.736a.245.245 0 0 0-.124-.033H8.75V13h2.5a.75.75 0 0 1 0 1.5h-6.5a.75.75 0 0 1 0-1.5h2.5V3.5h-.984a.245.245 0 0 0-.124.033l-1.289.737c-.265.15-.564.23-.869.23h-.162l2.112 4.692a.75.75 0 0 1-.154.838l-.53-.53.529.531-.001.002-.002.002-.006.006-.016.015-.045.04c-.21.176-.441.327-.686.45C4.556 10.78 3.88 11 3 11a4.498 4.498 0 0 1-2.023-.454 3.544 3.544 0 0 1-.686-.45l-.045-.04-.016-.015-.006-.006-.004-.004v-.001a.75.75 0 0 1-.154-.838L2.178 4.5H1.75a.75.75 0 0 1 0-1.5h2.234a.249.249 0 0 0 .125-.033l1.288-.737c.265-.15.564-.23.869-.23h.984V.75a.75.75 0 0 1 1.5 0Zm2.945 8.477c.285.135.718.273 1.305.273s1.02-.138 1.305-.273L13 6.327Zm-10 0c.285.135.718.273 1.305.273s1.02-.138 1.305-.273L3 6.327Z'%3E%3C/path%3E%3C/svg%3E")
.gc-forks
&:before
mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' aria-hidden='true' height='16' viewBox='0 0 16 16' version='1.1' width='16'%3E%3Cpath d='M5 5.372v.878c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75v-.878a2.25 2.25 0 1 1 1.5 0v.878a2.25 2.25 0 0 1-2.25 2.25h-1.5v2.128a2.251 2.251 0 1 1-1.5 0V8.5h-1.5A2.25 2.25 0 0 1 3.5 6.25v-.878a2.25 2.25 0 1 1 1.5 0ZM5 3.25a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Zm6.75.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Zm-3 8.75a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Z'%3E%3C/path%3E%3C/svg%3E")
a.card-github.fetch-waiting
pointer-events: none
opacity: 0.7
transition: opacity 0.15s ease-in-out
.gc-description, .gc-stars, .gc-forks, .gc-license
background-color: var(--tw-prose-body)
color: transparent
opacity: 0.5;
border-radius: 1rem
animation: pulsate 2s infinite linear
user-select: none
&:before
background-color: transparent
.gc-avatar
display: none
.gc-repo
margin-left: -0.1rem
a.card-github.fetch-error
pointer-events: all
opacity: 1
@keyframes pulsate
0%
opacity: 0.2
50%
opacity: 0.5
100%
opacity: 0.2
</style> </style>
<style lang="css" is:global> <style lang="css" is:global>
@tailwind base; @tailwind base;
@tailwind components; @tailwind components;
@tailwind utilities; @tailwind utilities;
@layer components { @layer components {
.custom-md h1 { .custom-md h1 {
@apply text-3xl @apply text-3xl
}
} }
}
</style> </style>

View File

@ -17,10 +17,15 @@ export function AdmonitionComponent(properties, children, type) {
'Invalid admonition directive. (Admonition directives must be of block type ":::note{name="name"} <content> :::")' 'Invalid admonition directive. (Admonition directives must be of block type ":::note{name="name"} <content> :::")'
); );
const title = properties?.title; let label = null
if (properties && properties['has-directive-label']) {
label = children[0]; // The first child is the label
children = children.slice(1);
label.tagName = "div"; // Change the tag <p> to <div>
}
return h(`blockquote`, return h(`blockquote`,
{ class: `admonition bdm-${type}` }, { class: `admonition bdm-${type}` },
[ h("span", { class: `bdm-title` }, title ? title : type.toUpperCase()), ...children] [ h("span", { class: `bdm-title` }, label ? label : type.toUpperCase()), ...children]
); );
} }

View File

@ -26,7 +26,7 @@ export function GithubCardComponent(properties, children) {
const cardUuid = `GC${Math.random().toString(36).slice(-6)}` // Collisions are not important const cardUuid = `GC${Math.random().toString(36).slice(-6)}` // Collisions are not important
const nAvatar = h( const nAvatar = h(
`span#${cardUuid}-avatar`, `div#${cardUuid}-avatar`,
{ class: "gc-avatar"}, { class: "gc-avatar"},
) )
const nLanguage = h( const nLanguage = h(
@ -39,12 +39,15 @@ export function GithubCardComponent(properties, children) {
`div`, `div`,
{ class: "gc-titlebar" }, { class: "gc-titlebar" },
[ [
h("span", { class: "gc-owner" }, [ h("div", { class: "gc-titlebar-left"}, [
nAvatar, h("div", { class: "gc-owner" }, [
h("span", { class: "gc-user" }, repo.split("/")[0] ), nAvatar,
h("div", { class: "gc-user" }, repo.split("/")[0] ),
]),
h("div", { class: "gc-divider" }, "/" ),
h("div", { class: "gc-repo" }, repo.split("/")[1] )
]), ]),
h("span", { class: "gc-divider" }, "/" ), h("div", { class: "github-logo"})
h("span", { class: "gc-repo" }, repo.split("/")[1] )
] ]
) )
@ -55,17 +58,17 @@ export function GithubCardComponent(properties, children) {
) )
const nStars = h( const nStars = h(
`span#${cardUuid}-stars`, `div#${cardUuid}-stars`,
{ class: "gc-stars" }, { class: "gc-stars" },
"00K" "00K"
) )
const nForks = h( const nForks = h(
`span#${cardUuid}-forks`, `div#${cardUuid}-forks`,
{ class: "gc-forks" }, { class: "gc-forks" },
"0K" "0K"
) )
const nLicense = h( const nLicense = h(
`span#${cardUuid}-license`, `div#${cardUuid}-license`,
{ class: "gc-license" }, { class: "gc-license" },
"0K" "0K"
) )
@ -101,6 +104,7 @@ export function GithubCardComponent(properties, children) {
return h(`a#${cardUuid}-card`, return h(`a#${cardUuid}-card`,
{ class: "card-github fetch-waiting no-styling", { class: "card-github fetch-waiting no-styling",
href: `https://github.com/${repo}`, href: `https://github.com/${repo}`,
target: '_blank',
repo }, repo },
[ [
nTitle, nTitle,

View File

@ -0,0 +1,27 @@
// biome-ignore lint/suspicious/noShadowRestrictedNames: <explanation>
import { h } from 'hastscript';
import {visit} from 'unist-util-visit'
export function parseDirectiveNode() {
return (tree, { data }) => {
visit(tree, function (node) {
if (
node.type === 'containerDirective' ||
node.type === 'leafDirective' ||
node.type === 'textDirective'
) {
const data = node.data || (node.data = {})
node.attributes = node.attributes || {}
if (node.children.length > 0 && node.children[0].data && node.children[0].data.directiveLabel) {
// Add a flag to the node to indicate that it has a directive label
node.attributes['has-directive-label'] = true
}
const hast = h(node.name, node.attributes)
data.hName = hast.tagName
data.hProperties = hast.properties
}
})
}
}