Merge branch 'main' into feat/footer-with-sidebar

pull/4532/head
Leo 7 months ago committed by GitHub
commit a60ead1bb8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -1,9 +1,9 @@
@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@100..900&display=swap');
:root:where(:lang(fa)) {
--vp-font-family-base: 'Vazirmatn', 'Inter', ui-sans-serif, system-ui,
sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol',
'Noto Color Emoji';
--vp-font-family-base:
'Vazirmatn', 'Inter', ui-sans-serif, system-ui, sans-serif,
'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji';
}
:root {

@ -255,7 +255,7 @@ This is a special container that can be used to prevent style and router conflic
```md
::: raw
Wraps in a <div class="vp-raw">
Wraps in a `<div class="vp-raw">`
:::
```

@ -234,7 +234,7 @@ Este es un recipiente especial que puee ser usado para evitar conflictos de esti
```md
::: raw
Envuelve en un <div class="vp-raw">
Envuelve en un `<div class="vp-raw">`
:::
```

@ -233,7 +233,7 @@ export default defineConfig({
```md
::: raw
بسته‌بندی در یک <div class="vp-raw">
بسته‌بندی در یک `<div class="vp-raw">`
:::
```

@ -233,7 +233,7 @@ export default defineConfig({
```md
::: raw
<div class="vp-raw">로 감쌉니다
`<div class="vp-raw">`로 감쌉니다
:::
```

@ -233,7 +233,7 @@ Este é um recipiente especial que pode ser usado para evitar conflitos de estil
```md
::: raw
Envolve em um <div class="vp-raw">
Envolve em um `<div class="vp-raw">`
:::
```

@ -123,7 +123,7 @@ export default {
## Слоты макета {#layout-slots}
Компонент `<Layout/>` темы по умолчанию имеет несколько слотов, которые можно использовать для вставки содержимого в определённые места страницы. Вот пример внедрения компонента в структуру before:
Компонент `<Layout/>` темы по умолчанию имеет несколько слотов, которые можно использовать для вставки содержимого в определённые места страницы. Вот пример внедрения компонента перед оглавлением:
```js [.vitepress/theme/index.js]
import DefaultTheme from 'vitepress/theme'
@ -131,8 +131,8 @@ import MyLayout from './MyLayout.vue'
export default {
extends: DefaultTheme,
// переопределяем макет с помощью компонента-обёртки, который
// вводит слоты
// переопределяем макет с помощью компонента-обёртки,
// который внедряет слоты
Layout: MyLayout
}
```
@ -147,7 +147,7 @@ const { Layout } = DefaultTheme
<template>
<Layout>
<template #aside-outline-before>
Верхнее содержимое моей пользовательской боковой панели
Мой пользовательский контент в верхней части боковой панели
</template>
</Layout>
</template>

@ -259,7 +259,7 @@ console.log('Привет, VitePress!')
```md
::: raw
Заворачивается в <div class="vp-raw">
Заворачивается в `<div class="vp-raw">`
:::
```

@ -175,7 +175,7 @@ HTML, обёрнутый `<code>`, будет отображаться как е
</div>
## Unescape в блоках кода {#unescape-in-code-blocks}
## Отключение экранирования в блоках кода {#unescape-in-code-blocks}
По умолчанию все изолированные блоки кода автоматически оборачиваются `v-pre`, поэтому внутри них не будет обрабатываться синтаксис Vue. Чтобы включить интерполяцию в стиле Vue внутри фигурных скобок, можно добавить к языку суффикс `-vue`, например `js-vue`:
@ -199,7 +199,9 @@ HTML, обёрнутый `<code>`, будет отображаться как е
VitePress имеет [встроенную поддержку](https://vitejs.dev/guide/features.html#css-pre-processors) для препроцессоров CSS: файлы `.scss`, `.sass`, `.less`, `.styl` и `.stylus`. Для них не нужно устанавливать специфические для Vite плагины, но сам соответствующий препроцессор должен быть установлен:
```
::: code-group
```sh [npm]
# .scss и .sass
npm install -D sass
@ -210,7 +212,41 @@ npm install -D less
npm install -D stylus
```
Затем вы можете использовать следующее в Markdown и компонентах темы:
```sh [pnpm]
# .scss и .sass
pnpm add -D sass
# .less
pnpm add -D less
# .styl и .stylus
pnpm add -D stylus
```
```sh [yarn]
# .scss и .sass
yarn add -D sass
# .less
yarn add -D less
# .styl и .stylus
yarn add -D stylus
```
```sh [bun]
# .scss и .sass
bun add -D sass
# .less
bun add -D less
# .styl и .stylus
bun add -D stylus
```
:::
Затем вы можете использовать соответствующий атрибут `lang` в Markdown и компонентах темы:
```vue
<style lang="sass">

@ -7,7 +7,7 @@ titleTemplate: Генератор статических сайтов на ос
hero:
name: VitePress
text: Генератор статических сайтов на основе Vite и Vue
tagline: Из Markdown в красивую документацию за считанные минуты
tagline: Преобразуйте Markdown в красивую документацию за минуты
actions:
- theme: brand
text: Что такое VitePress?

@ -233,7 +233,7 @@ export default defineConfig({
```md
::: raw
Wraps in a <div class="vp-raw">
Wraps in a `<div class="vp-raw">`
:::
```

@ -97,25 +97,25 @@
"dependencies": {
"@docsearch/css": "^3.8.3",
"@docsearch/js": "^3.8.3",
"@iconify-json/simple-icons": "^1.2.21",
"@shikijs/core": "^2.1.0",
"@shikijs/transformers": "^2.1.0",
"@shikijs/types": "^2.1.0",
"@iconify-json/simple-icons": "^1.2.24",
"@shikijs/core": "^2.3.2",
"@shikijs/transformers": "^2.3.2",
"@shikijs/types": "^2.3.2",
"@vitejs/plugin-vue": "^5.2.1",
"@vue/devtools-api": "^7.7.0",
"@vue/devtools-api": "^7.7.1",
"@vue/shared": "^3.5.13",
"@vueuse/core": "^12.5.0",
"@vueuse/integrations": "^12.5.0",
"focus-trap": "^7.6.4",
"mark.js": "8.11.1",
"minisearch": "^7.1.1",
"shiki": "^2.1.0",
"vite": "^6.0.11",
"shiki": "^2.3.2",
"vite": "^6.1.0",
"vue": "^3.5.13"
},
"devDependencies": {
"@clack/prompts": "^0.9.1",
"@iconify/utils": "^2.2.1",
"@clack/prompts": "^0.10.0",
"@iconify/utils": "^2.3.0",
"@mdit-vue/plugin-component": "^2.1.3",
"@mdit-vue/plugin-frontmatter": "^2.1.3",
"@mdit-vue/plugin-headers": "^2.1.3",
@ -139,7 +139,7 @@
"@types/markdown-it-container": "^2.0.10",
"@types/markdown-it-emoji": "^3.0.1",
"@types/minimist": "^1.2.5",
"@types/node": "^22.10.9",
"@types/node": "^22.13.1",
"@types/picomatch": "^3.0.2",
"@types/postcss-prefix-selector": "^1.16.3",
"@types/prompts": "^2.4.9",
@ -147,12 +147,12 @@
"conventional-changelog-cli": "^5.0.0",
"cross-spawn": "^7.0.6",
"debug": "^4.4.0",
"esbuild": "^0.24.2",
"esbuild": "^0.25.0",
"execa": "^9.5.2",
"fs-extra": "^11.3.0",
"get-port": "^7.1.0",
"gray-matter": "^4.0.3",
"lint-staged": "^15.4.2",
"lint-staged": "^15.4.3",
"lodash.template": "^4.5.0",
"lru-cache": "^11.0.2",
"markdown-it": "^14.1.0",
@ -164,29 +164,29 @@
"markdown-it-mathjax3": "^4.3.2",
"minimist": "^1.2.8",
"nanoid": "^5.0.9",
"ora": "^8.1.1",
"ora": "^8.2.0",
"p-map": "^7.0.3",
"path-to-regexp": "^6.3.0",
"picocolors": "^1.1.1",
"picomatch": "^4.0.2",
"pkg-dir": "^8.0.0",
"playwright-chromium": "^1.50.0",
"playwright-chromium": "^1.50.1",
"polka": "^1.0.0-next.28",
"postcss-prefix-selector": "^2.1.0",
"prettier": "^3.4.2",
"prettier": "^3.5.0",
"prompts": "^2.4.2",
"punycode": "^2.3.1",
"rimraf": "^6.0.1",
"rollup": "^4.31.0",
"rollup": "^4.34.6",
"rollup-plugin-dts": "^6.1.1",
"rollup-plugin-esbuild": "^6.1.1",
"semver": "^7.6.3",
"rollup-plugin-esbuild": "^6.2.0",
"semver": "^7.7.1",
"simple-git-hooks": "^2.11.1",
"sirv": "^3.0.0",
"sitemap": "^8.0.0",
"tinyglobby": "^0.2.10",
"typescript": "^5.7.3",
"vitest": "^3.0.4",
"vitest": "^3.0.5",
"vue-tsc": "^2.2.0",
"wait-on": "^8.0.2"
},

File diff suppressed because it is too large Load Diff

@ -154,6 +154,7 @@ const pageName = computed(() =>
width: 224px;
height: 32px;
background: linear-gradient(transparent, var(--vp-c-bg) 70%);
pointer-events: none;
}
.aside-content {

@ -8,8 +8,8 @@
font-weight: 100 900;
font-display: swap;
src: url('../fonts/inter-roman-cyrillic-ext.woff2') format('woff2');
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F,
U+FE2E-FE2F;
unicode-range:
U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
@font-face {
@ -36,8 +36,8 @@
font-weight: 100 900;
font-display: swap;
src: url('../fonts/inter-roman-greek.woff2') format('woff2');
unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1,
U+03A3-03FF;
unicode-range:
U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
@font-face {
@ -46,9 +46,10 @@
font-weight: 100 900;
font-display: swap;
src: url('../fonts/inter-roman-vietnamese.woff2') format('woff2');
unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169,
U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323,
U+0329, U+1EA0-1EF9, U+20AB;
unicode-range:
U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1,
U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329,
U+1EA0-1EF9, U+20AB;
}
@font-face {
@ -57,8 +58,9 @@
font-weight: 100 900;
font-display: swap;
src: url('../fonts/inter-roman-latin-ext.woff2') format('woff2');
unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF,
U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
unicode-range:
U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
@ -67,9 +69,10 @@
font-weight: 100 900;
font-display: swap;
src: url('../fonts/inter-roman-latin.woff2') format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191,
U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
unicode-range:
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193,
U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
@ -78,8 +81,8 @@
font-weight: 100 900;
font-display: swap;
src: url('../fonts/inter-italic-cyrillic-ext.woff2') format('woff2');
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F,
U+FE2E-FE2F;
unicode-range:
U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
@font-face {
@ -106,8 +109,8 @@
font-weight: 100 900;
font-display: swap;
src: url('../fonts/inter-italic-greek.woff2') format('woff2');
unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1,
U+03A3-03FF;
unicode-range:
U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
@font-face {
@ -116,9 +119,10 @@
font-weight: 100 900;
font-display: swap;
src: url('../fonts/inter-italic-vietnamese.woff2') format('woff2');
unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169,
U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323,
U+0329, U+1EA0-1EF9, U+20AB;
unicode-range:
U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1,
U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329,
U+1EA0-1EF9, U+20AB;
}
@font-face {
@ -127,8 +131,9 @@
font-weight: 100 900;
font-display: swap;
src: url('../fonts/inter-italic-latin-ext.woff2') format('woff2');
unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF,
U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
unicode-range:
U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
@ -137,45 +142,54 @@
font-weight: 100 900;
font-display: swap;
src: url('../fonts/inter-italic-latin.woff2') format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191,
U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
unicode-range:
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193,
U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
font-family: 'Punctuation SC';
font-weight: 400;
src: local('PingFang SC Regular'), local('Noto Sans CJK SC'),
src:
local('PingFang SC Regular'), local('Noto Sans CJK SC'),
local('Microsoft YaHei');
unicode-range: U+201C, U+201D, U+2018, U+2019, U+2E3A, U+2014, U+2013, U+2026,
U+00B7, U+007E, U+002F;
unicode-range:
U+201C, U+201D, U+2018, U+2019, U+2E3A, U+2014, U+2013, U+2026, U+00B7,
U+007E, U+002F;
}
@font-face {
font-family: 'Punctuation SC';
font-weight: 500;
src: local('PingFang SC Medium'), local('Noto Sans CJK SC'),
src:
local('PingFang SC Medium'), local('Noto Sans CJK SC'),
local('Microsoft YaHei');
unicode-range: U+201C, U+201D, U+2018, U+2019, U+2E3A, U+2014, U+2013, U+2026,
U+00B7, U+007E, U+002F;
unicode-range:
U+201C, U+201D, U+2018, U+2019, U+2E3A, U+2014, U+2013, U+2026, U+00B7,
U+007E, U+002F;
}
@font-face {
font-family: 'Punctuation SC';
font-weight: 600;
src: local('PingFang SC Semibold'), local('Noto Sans CJK SC Bold'),
src:
local('PingFang SC Semibold'), local('Noto Sans CJK SC Bold'),
local('Microsoft YaHei Bold');
unicode-range: U+201C, U+201D, U+2018, U+2019, U+2E3A, U+2014, U+2013, U+2026,
U+00B7, U+007E, U+002F;
unicode-range:
U+201C, U+201D, U+2018, U+2019, U+2E3A, U+2014, U+2013, U+2026, U+00B7,
U+007E, U+002F;
}
@font-face {
font-family: 'Punctuation SC';
font-weight: 700;
src: local('PingFang SC Semibold'), local('Noto Sans CJK SC Bold'),
src:
local('PingFang SC Semibold'), local('Noto Sans CJK SC Bold'),
local('Microsoft YaHei Bold');
unicode-range: U+201C, U+201D, U+2018, U+2019, U+2E3A, U+2014, U+2013, U+2026,
U+00B7, U+007E, U+002F;
unicode-range:
U+201C, U+201D, U+2018, U+2019, U+2E3A, U+2014, U+2013, U+2026, U+00B7,
U+007E, U+002F;
}
/* Generate the subsetted fonts using: `pyftsubset <file>.woff2 --unicodes="<range>" --output-file="inter-<style>-<subset>.woff2" --flavor=woff2` */

@ -261,17 +261,19 @@
* -------------------------------------------------------------------------- */
:root {
--vp-font-family-base: 'Inter', ui-sans-serif, system-ui, sans-serif,
'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji';
--vp-font-family-mono: ui-monospace, 'Menlo', 'Monaco', 'Consolas',
'Liberation Mono', 'Courier New', monospace;
--vp-font-family-base:
'Inter', ui-sans-serif, system-ui, sans-serif, 'Apple Color Emoji',
'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji';
--vp-font-family-mono:
ui-monospace, 'Menlo', 'Monaco', 'Consolas', 'Liberation Mono',
'Courier New', monospace;
font-optical-sizing: auto;
}
:root:where(:lang(zh)) {
--vp-font-family-base: 'Punctuation SC', 'Inter', ui-sans-serif, system-ui,
sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol',
'Noto Color Emoji';
--vp-font-family-base:
'Punctuation SC', 'Inter', ui-sans-serif, system-ui, sans-serif,
'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji';
}
/**
@ -283,7 +285,8 @@
--vp-shadow-2: 0 3px 12px rgba(0, 0, 0, 0.07), 0 1px 4px rgba(0, 0, 0, 0.07);
--vp-shadow-3: 0 12px 32px rgba(0, 0, 0, 0.1), 0 2px 6px rgba(0, 0, 0, 0.08);
--vp-shadow-4: 0 14px 44px rgba(0, 0, 0, 0.12), 0 3px 9px rgba(0, 0, 0, 0.12);
--vp-shadow-5: 0 18px 56px rgba(0, 0, 0, 0.16), 0 4px 12px rgba(0, 0, 0, 0.16);
--vp-shadow-5:
0 18px 56px rgba(0, 0, 0, 0.16), 0 4px 12px rgba(0, 0, 0, 0.16);
}
/**

Loading…
Cancel
Save