feat: 添加 rehype-code-group 插件,优化代码块显示与样式,新增友链夜白的小空间

This commit is contained in:
2026-10-16 22:13:46 +08:00
parent 6f8fff461b
commit 779a3ea27d
11 changed files with 364 additions and 1 deletions
+58
View File
@@ -134,6 +134,9 @@ importers:
rehype-autolink-headings:
specifier: ^7.1.0
version: 7.1.0
rehype-code-group:
specifier: ^1.0.1
version: 1.0.1
rehype-components:
specifier: ^0.3.0
version: 0.3.0
@@ -1802,6 +1805,10 @@ packages:
engines: {node: '>= 8.0.0'}
hasBin: true
'@sindresorhus/is@4.6.0':
resolution: {integrity: sha512-t09vSN3MdfsyCHoFcTRCH/iUtG7OJ0CsjzB8cjAmKc/va/kIgeDI/TxsigdncE/4be734m0cvIYwNaV4i2XqAw==}
engines: {node: '>=10'}
'@sindresorhus/is@7.2.0':
resolution: {integrity: sha512-P1Cz1dWaFfR4IR+U13mqqiGsLFf1KbayybWwdd2vfctdV6hDpUkgCY0nKOLLTMSoRd/jJNjtbqzf13K8DCCXQw==}
engines: {node: '>=18'}
@@ -2381,6 +2388,10 @@ packages:
resolution: {integrity: sha512-7NzBL0rN6fMUW+f7A6Io4h40qQlG+xGmtMxfbnH/K7TAtt8JQWVQK+6g0UXKMeVJoyV5EkkNsErQ8pVD3bLHbA==}
engines: {node: ^12.17.0 || ^14.13 || >=16.0.0}
char-regex@1.0.2:
resolution: {integrity: sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw==}
engines: {node: '>=10'}
character-entities-html4@2.1.0:
resolution: {integrity: sha512-1v7fgQRj6hnSwFpq1Eu0ynr/CDEw0rXo2B61qXrLNdHZmPKgb7fqS1a2JwF0rISo9q77jDI8VMEHoApn8qDoZA==}
@@ -2749,6 +2760,9 @@ packages:
emoji-regex@9.2.2:
resolution: {integrity: sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==}
emojilib@2.4.0:
resolution: {integrity: sha512-5U0rVMU5Y2n2+ykNLQqMoqklN9ICBT/KsvC1Gz6vqHbz2AXXGkG+Pm5rMWk/8Vjrr/mY9985Hi8DYzn1F09Nyw==}
encoding-sniffer@0.2.1:
resolution: {integrity: sha512-5gvq20T6vfpekVtqrYQsSCFZ1wEg5+wW0/QaZMWkFr6BqD3NfKs0rLCx4rrVlSWJeZb5NBJgVLswK/w2MWU+Gw==}
@@ -3920,6 +3934,10 @@ packages:
nlcst-to-string@4.0.0:
resolution: {integrity: sha512-YKLBCcUYKAg0FNlOBT6aI91qFmSiFKiluk655WzPF+DDMA02qIyy8uiRqI8QXtcFpEvll12LpL5MXqEmAZ+dcA==}
node-emoji@2.2.0:
resolution: {integrity: sha512-Z3lTE9pLaJF47NyMhd4ww1yFTAP8YhYI8SleJiHzM46Fgpm5cnNzSl9XfzFNqbaz+VlJrIj3fXQ4DeN1Rjm6cw==}
engines: {node: '>=18'}
node-fetch-native@1.6.7:
resolution: {integrity: sha512-g9yhqoedzIUm0nTnTqAQvueMPVOuIY16bqgAJJC8XOOubYFNwz6IER9qs0Gq2Xd0+CecCKFjtdDTMA4u4xG06Q==}
@@ -4522,6 +4540,10 @@ packages:
resolution: {integrity: sha512-snwN1LkjLM3SuymqpsoLonoJ8gVy5yJN9WztBiyj8HAAj5Mv3Fez5vFzVwscLQdzMZo27xv2FycGzAGDkT4dNw==}
engines: {node: '>=18.0.0'}
rehype-code-group@1.0.1:
resolution: {integrity: sha512-fVpjTIgIic0f6qjTHw8Cm3FSdcBgrLO8Mjm6zJE2HswldvGM6/C0XpsJ4y4xB2pZ6oLD9gxNyhXEP20QLt7gpg==}
engines: {node: '>=20.0.0'}
rehype-components@0.3.0:
resolution: {integrity: sha512-yl2bUkZi+sU0gxwVCun7IkjiDLPczSs1SKMKHmjlSLkk4mMryBd/aYba5J8suhJdquBEKSw6ZNxU3MvVQ9xqoQ==}
@@ -4812,6 +4834,10 @@ packages:
engines: {node: '>=20.19.5', npm: '>=10.8.2'}
hasBin: true
skin-tone@2.0.0:
resolution: {integrity: sha512-kUMbT1oBJCpgrnKoSr0o6wPtvRWT9W9UKvGLwfJYO2WuahZRHOpEyL1ckyMGgMWh0UdpmaoFqKKD29WTomNEGA==}
engines: {node: '>=8'}
slash@3.0.0:
resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==}
engines: {node: '>=8'}
@@ -5086,6 +5112,10 @@ packages:
resolution: {integrity: sha512-dA8WbNeb2a6oQzAQ55YlT5vQAWGV9WXOsi3SskE3bcCdM0P4SDd+24zS/OCacdRq5BkdsRj9q3Pg6YyQoxIGqg==}
engines: {node: '>=4'}
unicode-emoji-modifier-base@1.0.0:
resolution: {integrity: sha512-yLSH4py7oFH3oG/9K+XWrz1pSi3dfUrWEnInbxMfArOfc1+33BlGPQtLsOYwvdMy11AwUBetYuaRxSPqgkq+8g==}
engines: {node: '>=4'}
unicode-match-property-ecmascript@2.0.0:
resolution: {integrity: sha512-5kaZCrbp5mmbz5ulBkDkbY0SsPOjKqVS35VpL9ulMPfSl0J0Xsm+9Evphv9CoIZFwre7aJoa94AY6seMKGVN5Q==}
engines: {node: '>=4'}
@@ -7335,6 +7365,8 @@ snapshots:
fflate: 0.7.4
string.prototype.codepointat: 0.2.1
'@sindresorhus/is@4.6.0': {}
'@sindresorhus/is@7.2.0': {}
'@speed-highlight/core@1.2.17': {}
@@ -8040,6 +8072,8 @@ snapshots:
chalk@5.6.2: {}
char-regex@1.0.2: {}
character-entities-html4@2.1.0: {}
character-entities-legacy@3.0.0: {}
@@ -8428,6 +8462,8 @@ snapshots:
emoji-regex@9.2.2: {}
emojilib@2.4.0: {}
encoding-sniffer@0.2.1:
dependencies:
iconv-lite: 0.6.3
@@ -10141,6 +10177,13 @@ snapshots:
dependencies:
'@types/nlcst': 2.0.3
node-emoji@2.2.0:
dependencies:
'@sindresorhus/is': 4.6.0
char-regex: 1.0.2
emojilib: 2.4.0
skin-tone: 2.0.0
node-fetch-native@1.6.7: {}
node-mock-http@1.0.4: {}
@@ -10752,6 +10795,15 @@ snapshots:
hastscript: 9.0.1
unist-util-visit: 5.1.0
rehype-code-group@1.0.1:
dependencies:
'@types/hast': 3.0.5
'@types/mdast': 4.0.4
hast-util-to-string: 3.0.1
node-emoji: 2.2.0
unified: 11.0.5
unist-util-visit: 5.1.0
rehype-components@0.3.0:
dependencies:
hast-util-is-element: 3.0.0
@@ -11231,6 +11283,10 @@ snapshots:
arg: 5.0.2
sax: 1.6.0
skin-tone@2.0.0:
dependencies:
unicode-emoji-modifier-base: 1.0.0
slash@3.0.0: {}
smol-toml@1.7.0: {}
@@ -11565,6 +11621,8 @@ snapshots:
unicode-canonical-property-names-ecmascript@2.0.1: {}
unicode-emoji-modifier-base@1.0.0: {}
unicode-match-property-ecmascript@2.0.0:
dependencies:
unicode-canonical-property-names-ecmascript: 2.0.1