chore: update vitepress to 1.0

This commit is contained in:
syy11cn 2022-06-05 22:08:45 +08:00
parent e754d96d30
commit fed56ca607
7 changed files with 379 additions and 292 deletions

View File

@ -26,7 +26,7 @@
"@types/node": "^17.0.27",
"eslint": "^8.14.0",
"typescript": "^4.6.4",
"vitepress": "^0.22.3",
"vitepress": "^1.0.0-alpha.1",
"vue": "^3.2.33"
},
"eslintConfig": {

View File

@ -10,7 +10,7 @@ specifiers:
globby: 11.0.4
gray-matter: ^4.0.3
typescript: ^4.6.4
vitepress: ^0.22.3
vitepress: ^1.0.0-alpha.1
vue: ^3.2.33
dependencies:
@ -25,7 +25,7 @@ devDependencies:
'@types/node': 17.0.27
eslint: 8.14.0
typescript: 4.6.4
vitepress: 0.22.3
vitepress: 1.0.0-alpha.1
vue: 3.2.33
packages:
@ -496,14 +496,14 @@ packages:
eslint-visitor-keys: 3.3.0
dev: true
/@vitejs/plugin-vue/2.3.1_vite@2.9.5+vue@3.2.33:
resolution: {integrity: sha512-YNzBt8+jt6bSwpt7LP890U1UcTOIZZxfpE5WOJ638PNxSEKOqAi0+FSKS0nVeukfdZ0Ai/H7AFd6k3hayfGZqQ==}
/@vitejs/plugin-vue/2.3.3_vite@2.9.9+vue@3.2.33:
resolution: {integrity: sha512-SmQLDyhz+6lGJhPELsBdzXGc+AcaT8stgkbiTFGpXPe8Tl1tJaBw1A6pxDqDuRsVkD8uscrkx3hA7QDOoKYtyw==}
engines: {node: '>=12.0.0'}
peerDependencies:
vite: ^2.5.10
vue: ^3.2.25
dependencies:
vite: 2.9.5
vite: 2.9.9
vue: 3.2.33
dev: true
@ -590,6 +590,23 @@ packages:
resolution: {integrity: sha512-UBc1Pg1T3yZ97vsA2ueER0F6GbJebLHYlEi4ou1H5YL4KWvMOOWwpYo9/QpWq93wxKG6Wo13IY74Hcn/f7c7Bg==}
dev: true
/@vueuse/core/8.6.0_vue@3.2.33:
resolution: {integrity: sha512-VirzExCm/N+QdrEWT7J4uSrvJ5hquKIAU9alQ37kUvIJk9XxCLxmfRnmekYc1kz2+6BnoyuKYXVmrMV351CB4w==}
peerDependencies:
'@vue/composition-api': ^1.1.0
vue: ^2.6.0 || ^3.2.0
peerDependenciesMeta:
'@vue/composition-api':
optional: true
vue:
optional: true
dependencies:
'@vueuse/metadata': 8.6.0
'@vueuse/shared': 8.6.0_vue@3.2.33
vue: 3.2.33
vue-demi: 0.13.1_vue@3.2.33
dev: true
/@vueuse/head/0.7.6_vue@3.2.33:
resolution: {integrity: sha512-cOWqCkT3WiF5oEpw+VVEWUJd9RLD5rc7DmnFp3cePsejp+t7686uKD9Z9ZU7Twb7R/BI8iexKTmXo9D/F3v6UA==}
peerDependencies:
@ -598,6 +615,25 @@ packages:
vue: 3.2.33
dev: false
/@vueuse/metadata/8.6.0:
resolution: {integrity: sha512-F+CKPvaExsm7QgRr8y+ZNJFwXasn89rs5wth/HeX9lJ1q8XEt+HJ16Q5Sxh4rfG5YSKXrStveVge8TKvPjMjFA==}
dev: true
/@vueuse/shared/8.6.0_vue@3.2.33:
resolution: {integrity: sha512-Y/IVywZo7IfEoSSEtCYpkVEmPV7pU35mEIxV7PbD/D3ly18B3mEsBaPbtDkNM/QP3zAZ5mn4nEkOfddX4uwuIA==}
peerDependencies:
'@vue/composition-api': ^1.1.0
vue: ^2.6.0 || ^3.2.0
peerDependenciesMeta:
'@vue/composition-api':
optional: true
vue:
optional: true
dependencies:
vue: 3.2.33
vue-demi: 0.13.1_vue@3.2.33
dev: true
/acorn-jsx/5.3.2_acorn@8.7.1:
resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==}
peerDependencies:
@ -708,6 +744,10 @@ packages:
resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==}
dev: true
/body-scroll-lock/4.0.0-beta.0:
resolution: {integrity: sha512-a7tP5+0Mw3YlUJcGAKUqIBkYYGlYxk2fnCasq/FUph1hadxlTRjF+gAcZksxANnaMnALjxEddmSi/H3OR8ugcQ==}
dev: true
/boolbase/1.0.0:
resolution: {integrity: sha1-aN/1++YMUes3cl6p4+0xDcwed24=}
dev: true
@ -1997,6 +2037,10 @@ packages:
semver: 7.3.7
dev: true
/jsonc-parser/3.0.0:
resolution: {integrity: sha512-fQzRfAbIBnR0IQvftw9FJveWiHp72Fg20giDrHz6TdfB12UH/uue0D3hm57UB5KgAVuniLMCaS8P1IMj9NR7cA==}
dev: true
/jsonfile/6.1.0:
resolution: {integrity: sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==}
dependencies:
@ -2142,6 +2186,12 @@ packages:
hasBin: true
dev: true
/nanoid/3.3.4:
resolution: {integrity: sha512-MqBkQh/OHTS2egovRtLk45wEyNXwF+cokD+1YPf9u5VfJiRdAiRwB2froX5Co9Rh20xs4siNPm8naNotSD6RBw==}
engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1}
hasBin: true
dev: true
/natural-compare/1.4.0:
resolution: {integrity: sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=}
dev: true
@ -2361,6 +2411,15 @@ packages:
source-map-js: 1.0.2
dev: true
/postcss/8.4.14:
resolution: {integrity: sha512-E398TUmfAYFPBSdzgeieK2Y1+1cpdxJx8yXbK/m57nRhKSmk1GB2tO4lbLBtlkfPQTDKfe4Xqv1ASWPpayPEig==}
engines: {node: ^10 || ^12 || >=14}
dependencies:
nanoid: 3.3.4
picocolors: 1.0.0
source-map-js: 1.0.2
dev: true
/preact/10.7.1:
resolution: {integrity: sha512-MufnRFz39aIhs9AMFisonjzTud1PK1bY+jcJLo6m2T9Uh8AqjD77w11eAAawmjUogoGOnipECq7e/1RClIKsxg==}
dev: true
@ -2370,11 +2429,6 @@ packages:
engines: {node: '>= 0.8.0'}
dev: true
/prismjs/1.28.0:
resolution: {integrity: sha512-8aaXdYvl1F7iC7Xm1spqSaY/OJBpYW3v+KJ+F17iYxvdc8sfjW194COK5wVhMZX45tGteiBQgdvD/nhxcRwylw==}
engines: {node: '>=6'}
dev: true
/prop-types/15.8.1:
resolution: {integrity: sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==}
dependencies:
@ -2522,6 +2576,14 @@ packages:
engines: {node: '>=8'}
dev: true
/shiki/0.10.1:
resolution: {integrity: sha512-VsY7QJVzU51j5o1+DguUd+6vmCmZ5v/6gYu4vyYAhzjuNQU6P/vmSy4uQaOhvje031qQMiW0d2BwgMH52vqMng==}
dependencies:
jsonc-parser: 3.0.0
vscode-oniguruma: 1.6.2
vscode-textmate: 5.2.0
dev: true
/side-channel/1.0.4:
resolution: {integrity: sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==}
dependencies:
@ -2751,8 +2813,8 @@ packages:
spdx-expression-parse: 3.0.1
dev: true
/vite/2.9.5:
resolution: {integrity: sha512-dvMN64X2YEQgSXF1lYabKXw3BbN6e+BL67+P3Vy4MacnY+UzT1AfkHiioFSi9+uiDUiaDy7Ax/LQqivk6orilg==}
/vite/2.9.9:
resolution: {integrity: sha512-ffaam+NgHfbEmfw/Vuh6BHKKlI/XIAhxE5QSS7gFLIngxg171mg1P3a4LSRME0z2ZU1ScxoKzphkipcYwSD5Ew==}
engines: {node: '>=12.2.0'}
hasBin: true
peerDependencies:
@ -2768,27 +2830,30 @@ packages:
optional: true
dependencies:
esbuild: 0.14.38
postcss: 8.4.12
postcss: 8.4.14
resolve: 1.22.0
rollup: 2.70.2
optionalDependencies:
fsevents: 2.3.2
dev: true
/vitepress/0.22.3:
resolution: {integrity: sha512-Yfvu/rent2vp/TXIDZMutS6ft2TJPn4xngS48PYFWDEbuFI2ccUAXM481lF1qVVnCKxfh4g8e/KPvevSJdg1Bw==}
engines: {node: '>=14.0.0'}
/vitepress/1.0.0-alpha.1:
resolution: {integrity: sha512-yA0QIl+mB3fQ2j+keQVa0DTT0waP2AeWM/p9VYfUAT9vOkQEGass4/oYmMGPCQrBwCaO3cpOxJL3ZFVooyvybQ==}
engines: {node: '>=14.6.0'}
hasBin: true
dependencies:
'@docsearch/css': 3.0.0
'@docsearch/js': 3.0.0
'@vitejs/plugin-vue': 2.3.1_vite@2.9.5+vue@3.2.33
prismjs: 1.28.0
vite: 2.9.5
'@vitejs/plugin-vue': 2.3.3_vite@2.9.9+vue@3.2.33
'@vueuse/core': 8.6.0_vue@3.2.33
body-scroll-lock: 4.0.0-beta.0
shiki: 0.10.1
vite: 2.9.9
vue: 3.2.33
transitivePeerDependencies:
- '@algolia/client-search'
- '@types/react'
- '@vue/composition-api'
- less
- react
- react-dom
@ -2796,6 +2861,29 @@ packages:
- stylus
dev: true
/vscode-oniguruma/1.6.2:
resolution: {integrity: sha512-KH8+KKov5eS/9WhofZR8M8dMHWN2gTxjMsG4jd04YhpbPR91fUj7rYQ2/XjeHCJWbg7X++ApRIU9NUwM2vTvLA==}
dev: true
/vscode-textmate/5.2.0:
resolution: {integrity: sha512-Uw5ooOQxRASHgu6C7GVvUxisKXfSgW4oFlO+aa+PAkgmH89O3CXxEEzNRNtHSqtXFTl0nAC1uYj0GMSH27uwtQ==}
dev: true
/vue-demi/0.13.1_vue@3.2.33:
resolution: {integrity: sha512-xmkJ56koG3ptpLnpgmIzk9/4nFf4CqduSJbUM0OdPoU87NwRuZ6x49OLhjSa/fC15fV+5CbEnrxU4oyE022svg==}
engines: {node: '>=12'}
hasBin: true
requiresBuild: true
peerDependencies:
'@vue/composition-api': ^1.0.0-rc.1
vue: ^3.0.0-0 || ^2.6.0
peerDependenciesMeta:
'@vue/composition-api':
optional: true
dependencies:
vue: 3.2.33
dev: true
/vue-eslint-parser/8.3.0_eslint@8.14.0:
resolution: {integrity: sha512-dzHGG3+sYwSf6zFBa0Gi9ZDshD7+ad14DGOdTLjruRVgZXe2J+DcZ9iUhyR48z5g1PqRa20yt3Njna/veLJL/g==}
engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0}

View File

@ -4,7 +4,7 @@ import { createHead } from '@vueuse/head'
import './styles/reset.css'
import './styles/fonts.css'
import './styles/global.css'
import './styles/prism.css'
import './styles/shiki.css'
import './styles/article.css'
import './styles/reactivity.css'

View File

@ -1,252 +0,0 @@
:root {
--prism-scheme: light;
/* Colors */
--prism-foreground: #6e6e6e;
--prism-background: #f4f4f4;
/* Tokens */
--prism-comment: #a8a8a8;
--prism-string: #555555;
--prism-literal: #333333;
--prism-keyword: #000000;
--prism-function: #4f4f4f;
--prism-deleted: #333333;
--prism-class: #333333;
--prism-builtin: #757575;
--prism-property: #333333;
--prism-namespace: #4f4f4f;
--prism-punctuation: #ababab;
--prism-decorator: var(--prism-class);
--prism-operator: var(--prism-punctuation);
--prism-number: var(--prism-literal);
--prism-boolean: var(--prism-literal);
--prism-variable: var(--prism-literal);
--prism-constant: var(--prism-literal);
--prism-symbol: var(--prism-literal);
--prism-interpolation: var(--prism-literal);
--prism-selector: var(--prism-keyword);
--prism-keyword-control: var(--prism-keyword);
--prism-regex: var(--prism-string);
--prism-json-property: var(--prism-property);
--prism-inline-background: var(--prism-background);
/* Token Styles */
--prism-comment-style: italic;
--prism-url-decoration: underline;
/* Extension */
--prism-line-number: #a5a5a5;
--prism-line-number-gutter: #333333;
--prism-line-highlight-background: #eeeeee;
--prism-selection-background: #aaaaaa;
--prism-marker-color: var(--prism-foreground);
--prism-marker-opacity: 0.4;
--prism-marker-font-size: 0.8em;
/* Font */
--prism-font-size: 1em;
--prism-line-height: 1.5em;
--prism-font-family: monospace;
--prism-inline-font-size: var(--prism-font-size);
--prism-block-font-size: var(--prism-font-size);
/* Sizing */
--prism-tab-size: 2;
--prism-block-padding-x: 1em;
--prism-block-padding-y: 1em;
--prism-block-margin-x: 0;
--prism-block-margin-y: 0.5em;
--prism-block-radius: 0.3em;
--prism-inline-padding-x: 0.3em;
--prism-inline-padding-y: 0.1em;
--prism-inline-radius: 0.3em;
}
div[class*='language-'],
pre[class*='language-'],
code[class*='language-'] {
font-size: var(--prism-font-size);
font-family: var(--prism-font-family);
direction: ltr;
text-align: left;
white-space: pre;
word-spacing: normal;
word-break: normal;
line-height: var(--prism-line-height);
-moz-tab-size: var(--prism-tab-size);
-o-tab-size: var(--prism-tab-size);
tab-size: var(--prism-tab-size);
-webkit-hyphens: none;
-moz-hyphens: none;
-ms-hyphens: none;
hyphens: none;
color: var(--prism-foreground) !important;
}
/* Code blocks */
div[class*='language-'],
pre[class*='language-'] {
font-size: var(--prism-block-font-size);
padding: var(--prism-block-padding-y) var(--prism-block-padding-x);
margin: var(--prism-block-margin-y) var(--prism-block-margin-x);
border-radius: var(--prism-block-radius);
overflow: auto;
background: var(--prism-background);
}
/* Inline code */
:not(pre) > code[class*='language-'] {
font-size: var(--prism-inline-font-size);
padding: var(--prism-inline-padding-y) var(--prism-inline-padding-x);
border-radius: var(--prism-inline-radius);
background: var(--prism-inline-background);
}
/* Selection */
pre[class*='language-']::selection,
pre[class*='language-'] ::selection,
code[class*='language-']::selection,
code[class*='language-'] ::selection,
pre[class*='language-']::-moz-selection,
pre[class*='language-'] ::-moz-selection,
code[class*='language-']::-moz-selection,
code[class*='language-'] ::-moz-selection {
background: var(--prism-selection-background);
}
/* Tokens */
.token.comment,
.token.prolog,
.token.doctype,
.token.cdata {
color: var(--prism-comment);
font-style: var(--prism-comment-style);
}
.token.namespace {
color: var(--prism-namespace);
}
.token.interpolation {
color: var(--prism-interpolation);
}
.token.string {
color: var(--prism-string);
}
.token.punctuation {
color: var(--prism-punctuation);
}
.token.operator {
color: var(--prism-operator);
}
.token.keyword.module,
.token.keyword.control-flow {
color: var(--prism-keyword-control);
}
.token.url,
.token.symbol,
.token.inserted {
color: var(--prism-symbol);
}
.token.constant {
color: var(--prism-constant);
}
.token.string.url {
text-decoration: var(--prism-url-decoration);
}
.token.boolean,
.language-json .token.boolean {
color: var(--prism-boolean);
}
.token.number,
.language-json .token.number {
color: var(--prism-number);
}
.token.variable {
color: var(--prism-variable);
}
.token.keyword {
color: var(--prism-keyword);
}
.token.atrule,
.token.attr-value,
.token.selector {
color: var(--prism-selector);
}
.token.function {
color: var(--prism-function);
}
.token.deleted {
color: var(--prism-deleted);
}
.token.important,
.token.bold {
font-weight: bold;
}
.token.italic {
font-style: italic;
}
.token.class-name {
color: var(--prism-class);
}
.token.tag,
.token.builtin {
color: var(--prism-builtin);
}
.token.attr-name,
.token.property,
.token.entity {
color: var(--prism-property);
}
.language-json .token.property {
color: var(--prism-json-property);
}
.token.regex {
color: var(--prism-regex);
}
.token.decorator,
.token.annotation {
color: var(--prism-decorator);
}
/* overrides color-values for the Line Numbers plugin
* http://prismjs.com/plugins/line-numbers/
*/
.line-numbers .line-numbers-rows {
border-right-color: var(--prism-line-number);
}
.line-numbers-rows > span:before {
color: var(--prism-line-number-gutter);
}
/* overrides color-values for the Line Highlight plugin
* http://prismjs.com/plugins/line-highlight/
*/
.line-highlight {
background: var(--prism-line-highlight-background);
}

View File

@ -1,19 +0,0 @@
@import url('./prism-base.css');
:root {
--prism-foreground: #393a34;
--prism-background: #f6f6f6;
--prism-comment: #b8c4b8;
--prism-string: #c67b5d;
--prism-literal: #3a9c9b;
--prism-keyword: #248459;
--prism-function: #849145;
--prism-deleted: #a14f55;
--prism-class: #2b91af;
--prism-builtin: #a52727;
--prism-property: #ad502b;
--prism-namespace: #c96880;
--prism-punctuation: #8e8f8b;
--prism-decorator: #bd8f8f;
--prism-json-property: #698c96;
}

252
src/styles/shiki-base.css Normal file
View File

@ -0,0 +1,252 @@
:root {
--shiki-token-scheme: light;
/* Colors */
--shiki-token-foreground: #6e6e6e;
--shiki-token-background: #f4f4f4;
/* Tokens */
--shiki-token-comment: #a8a8a8;
--shiki-token-string: #555555;
--shiki-token-literal: #333333;
--shiki-token-keyword: #000000;
--shiki-token-function: #4f4f4f;
--shiki-token-deleted: #333333;
--shiki-token-class: #333333;
--shiki-token-builtin: #757575;
--shiki-token-property: #333333;
--shiki-token-namespace: #4f4f4f;
--shiki-token-punctuation: #ababab;
--shiki-token-decorator: var(--shiki-token-class);
--shiki-token-operator: var(--shiki-token-punctuation);
--shiki-token-number: var(--shiki-token-literal);
--shiki-token-boolean: var(--shiki-token-literal);
--shiki-token-variable: var(--shiki-token-literal);
--shiki-token-constant: var(--shiki-token-literal);
--shiki-token-symbol: var(--shiki-token-literal);
--shiki-token-interpolation: var(--shiki-token-literal);
--shiki-token-selector: var(--shiki-token-keyword);
--shiki-token-keyword-control: var(--shiki-token-keyword);
--shiki-token-regex: var(--shiki-token-string);
--shiki-token-json-property: var(--shiki-token-property);
--shiki-token-inline-background: var(--shiki-token-background);
/* Token Styles */
--shiki-token-comment-style: italic;
--shiki-token-url-decoration: underline;
/* Extension */
--shiki-token-line-number: #a5a5a5;
--shiki-token-line-number-gutter: #333333;
--shiki-token-line-highlight-background: #eeeeee;
--shiki-token-selection-background: #aaaaaa;
--shiki-token-marker-color: var(--shiki-token-foreground);
--shiki-token-marker-opacity: 0.4;
--shiki-token-marker-font-size: 0.8em;
/* Font */
--shiki-token-font-size: 1em;
--shiki-token-line-height: 1.5em;
--shiki-token-font-family: monospace;
--shiki-token-inline-font-size: var(--shiki-token-font-size);
--shiki-token-block-font-size: var(--shiki-token-font-size);
/* Sizing */
--shiki-token-tab-size: 2;
--shiki-token-block-padding-x: 1em;
--shiki-token-block-padding-y: 1em;
--shiki-token-block-margin-x: 0;
--shiki-token-block-margin-y: 0.5em;
--shiki-token-block-radius: 0.3em;
--shiki-token-inline-padding-x: 0.3em;
--shiki-token-inline-padding-y: 0.1em;
--shiki-token-inline-radius: 0.3em;
}
div[class*='language-'],
pre[class*='language-'],
code[class*='language-'] {
font-size: var(--shiki-token-font-size);
font-family: var(--shiki-token-font-family);
direction: ltr;
text-align: left;
white-space: pre;
word-spacing: normal;
word-break: normal;
line-height: var(--shiki-token-line-height);
-moz-tab-size: var(--shiki-token-tab-size);
-o-tab-size: var(--shiki-token-tab-size);
tab-size: var(--shiki-token-tab-size);
-webkit-hyphens: none;
-moz-hyphens: none;
-ms-hyphens: none;
hyphens: none;
color: var(--shiki-token-foreground) !important;
}
/* Code blocks */
div[class*='language-'],
pre[class*='language-'] {
font-size: var(--shiki-token-block-font-size);
padding: var(--shiki-token-block-padding-y) var(--shiki-token-block-padding-x);
margin: var(--shiki-token-block-margin-y) var(--shiki-token-block-margin-x);
border-radius: var(--shiki-token-block-radius);
overflow: auto;
background: var(--shiki-token-background);
}
/* Inline code */
:not(pre) > code[class*='language-'] {
font-size: var(--shiki-token-inline-font-size);
padding: var(--shiki-token-inline-padding-y) var(--shiki-token-inline-padding-x);
border-radius: var(--shiki-token-inline-radius);
background: var(--shiki-token-inline-background);
}
/* Selection */
pre[class*='language-']::selection,
pre[class*='language-'] ::selection,
code[class*='language-']::selection,
code[class*='language-'] ::selection,
pre[class*='language-']::-moz-selection,
pre[class*='language-'] ::-moz-selection,
code[class*='language-']::-moz-selection,
code[class*='language-'] ::-moz-selection {
background: var(--shiki-token-selection-background);
}
/* Tokens */
.token.comment,
.token.prolog,
.token.doctype,
.token.cdata {
color: var(--shiki-token-comment);
font-style: var(--shiki-token-comment-style);
}
.token.namespace {
color: var(--shiki-token-namespace);
}
.token.interpolation {
color: var(--shiki-token-interpolation);
}
.token.string {
color: var(--shiki-token-string);
}
.token.punctuation {
color: var(--shiki-token-punctuation);
}
.token.operator {
color: var(--shiki-token-operator);
}
.token.keyword.module,
.token.keyword.control-flow {
color: var(--shiki-token-keyword-control);
}
.token.url,
.token.symbol,
.token.inserted {
color: var(--shiki-token-symbol);
}
.token.constant {
color: var(--shiki-token-constant);
}
.token.string.url {
text-decoration: var(--shiki-token-url-decoration);
}
.token.boolean,
.language-json .token.boolean {
color: var(--shiki-token-boolean);
}
.token.number,
.language-json .token.number {
color: var(--shiki-token-number);
}
.token.variable {
color: var(--shiki-token-variable);
}
.token.keyword {
color: var(--shiki-token-keyword);
}
.token.atrule,
.token.attr-value,
.token.selector {
color: var(--shiki-token-selector);
}
.token.function {
color: var(--shiki-token-function);
}
.token.deleted {
color: var(--shiki-token-deleted);
}
.token.important,
.token.bold {
font-weight: bold;
}
.token.italic {
font-style: italic;
}
.token.class-name {
color: var(--shiki-token-class);
}
.token.tag,
.token.builtin {
color: var(--shiki-token-builtin);
}
.token.attr-name,
.token.property,
.token.entity {
color: var(--shiki-token-property);
}
.language-json .token.property {
color: var(--shiki-token-json-property);
}
.token.regex {
color: var(--shiki-token-regex);
}
.token.decorator,
.token.annotation {
color: var(--shiki-token-decorator);
}
/* overrides color-values for the Line Numbers plugin
* http://shiki-tokenjs.com/plugins/line-numbers/
*/
.line-numbers .line-numbers-rows {
border-right-color: var(--shiki-token-line-number);
}
.line-numbers-rows > span:before {
color: var(--shiki-token-line-number-gutter);
}
/* overrides color-values for the Line Highlight plugin
* http://shiki-tokenjs.com/plugins/line-highlight/
*/
.line-highlight {
background: var(--shiki-token-line-highlight-background);
}

18
src/styles/shiki.css Normal file
View File

@ -0,0 +1,18 @@
@import url('./shiki-base.css');
:root {
--shiki-token-foreground: #393a34;
--shiki-token-background: #f6f6f6;
--shiki-token-comment: #b8c4b8;
--shiki-token-string: #c67b5d;
--shiki-token-keyword: #248459;
--shiki-token-function: #849145;
--shiki-token-deleted: #a14f55;
--shiki-token-class: #2b91af;
--shiki-token-builtin: #a52727;
--shiki-token-property: #ad502b;
--shiki-token-namespace: #c96880;
--shiki-token-punctuation: #8e8f8b;
--shiki-token-decorator: #bd8f8f;
--shiki-token-json-property: #698c96;
}