sync
This commit is contained in:
12
.vitepress/cache/deps/_metadata.json
vendored
12
.vitepress/cache/deps/_metadata.json
vendored
@@ -1,25 +1,25 @@
|
||||
{
|
||||
"hash": "328a40d6",
|
||||
"configHash": "755e8183",
|
||||
"hash": "a12e5463",
|
||||
"configHash": "dd9ed373",
|
||||
"lockfileHash": "5778a81f",
|
||||
"browserHash": "9485839a",
|
||||
"browserHash": "2debf0f0",
|
||||
"optimized": {
|
||||
"vue": {
|
||||
"src": "../../../node_modules/vue/dist/vue.runtime.esm-bundler.js",
|
||||
"file": "vue.js",
|
||||
"fileHash": "2c01c408",
|
||||
"fileHash": "50b34fbf",
|
||||
"needsInterop": false
|
||||
},
|
||||
"vitepress > @vue/devtools-api": {
|
||||
"src": "../../../node_modules/@vue/devtools-api/dist/index.js",
|
||||
"file": "vitepress___@vue_devtools-api.js",
|
||||
"fileHash": "668fe053",
|
||||
"fileHash": "ea163609",
|
||||
"needsInterop": false
|
||||
},
|
||||
"vitepress > @vueuse/core": {
|
||||
"src": "../../../node_modules/@vueuse/core/index.mjs",
|
||||
"file": "vitepress___@vueuse_core.js",
|
||||
"fileHash": "adb8a37f",
|
||||
"fileHash": "2ef97fe2",
|
||||
"needsInterop": false
|
||||
}
|
||||
},
|
||||
|
||||
@@ -1,55 +1,117 @@
|
||||
import { defineConfig } from 'vitepress';
|
||||
|
||||
const versions = Array.from({ length: 100 }, (_, i) => {
|
||||
const major = Math.floor(i / 10) + 1;
|
||||
const minor = i % 10;
|
||||
return `v${major}.${minor}`;
|
||||
}).reverse();
|
||||
|
||||
export default defineConfig({
|
||||
lang: 'ru-RU',
|
||||
title: 'Frontend Style Guide',
|
||||
description: 'Правила и стандарты разработки фронтенд-проектов на React/NextJS и TypeScript',
|
||||
themeConfig: {
|
||||
siteTitle: 'Frontend Style Guide',
|
||||
nav: [
|
||||
{
|
||||
text: versions[0],
|
||||
items: versions.map((v) => ({
|
||||
text: v,
|
||||
link: `/${v}/`,
|
||||
})),
|
||||
},
|
||||
],
|
||||
sidebar: [
|
||||
{
|
||||
text: 'Базовые правила',
|
||||
items: [
|
||||
{ text: 'Технологии и библиотеки', link: '/parts/1-tech-stack' },
|
||||
{ text: 'Архитектура', link: '/parts/2-architecture' },
|
||||
{ text: 'Стиль кода', link: '/parts/3-code-style' },
|
||||
{ text: 'Именование', link: '/parts/4-naming' },
|
||||
{ text: 'Документирование', link: '/parts/5-documentation' },
|
||||
{ text: 'Типизация', link: '/parts/6-typing' },
|
||||
],
|
||||
},
|
||||
{
|
||||
text: 'Прикладные разделы',
|
||||
items: [
|
||||
{ text: 'Структура проекта', link: '/parts/7-project-structure' },
|
||||
{ text: 'Компоненты', link: '/parts/8-0-components' },
|
||||
{ text: 'Шаблоны и генерация кода', link: '/parts/8-1-templates-generation' },
|
||||
{ text: 'Стили', link: '/parts/9-styles' },
|
||||
{ text: 'Изображения', link: '/parts/10-images-sprites' },
|
||||
{ text: 'SVG-спрайты', link: '/parts/17-svg-sprites' },
|
||||
{ text: 'Видео', link: '/parts/11-video' },
|
||||
{ text: 'API', link: '/parts/12-api' },
|
||||
{ text: 'Stores', link: '/parts/13-stores' },
|
||||
{ text: 'Хуки', link: '/parts/14-hooks' },
|
||||
{ text: 'Шрифты', link: '/parts/15-fonts' },
|
||||
{ text: 'Локализация', link: '/parts/16-localization' },
|
||||
],
|
||||
},
|
||||
const ruSidebar = [
|
||||
{
|
||||
text: 'Workflow',
|
||||
items: [
|
||||
{ text: 'Начало работы', link: '/workflow/getting-started' },
|
||||
{ text: 'Создание приложения', link: '/workflow/creating-app' },
|
||||
{ text: 'Создание страниц', link: '/workflow/creating-pages' },
|
||||
{ text: 'Создание компонентов', link: '/workflow/creating-components' },
|
||||
{ text: 'Стилизация', link: '/workflow/styling' },
|
||||
{ text: 'Работа с данными', link: '/workflow/data-fetching' },
|
||||
{ text: 'Управление состоянием', link: '/workflow/state-management' },
|
||||
{ text: 'Локализация', link: '/workflow/localization' },
|
||||
],
|
||||
},
|
||||
});
|
||||
{
|
||||
text: 'Базовые правила',
|
||||
items: [
|
||||
{ text: 'Технологии и библиотеки', link: '/basics/tech-stack' },
|
||||
{ text: 'Архитектура', link: '/basics/architecture' },
|
||||
{ text: 'Стиль кода', link: '/basics/code-style' },
|
||||
{ text: 'Именование', link: '/basics/naming' },
|
||||
{ text: 'Документирование', link: '/basics/documentation' },
|
||||
{ text: 'Типизация', link: '/basics/typing' },
|
||||
],
|
||||
},
|
||||
{
|
||||
text: 'Прикладные разделы',
|
||||
items: [
|
||||
{ text: 'Структура проекта', link: '/applied/project-structure' },
|
||||
{ text: 'Компоненты', link: '/applied/components' },
|
||||
{ text: 'Шаблоны и генерация кода', link: '/applied/templates-generation' },
|
||||
{ text: 'Стили', link: '/applied/styles' },
|
||||
{ text: 'Изображения', link: '/applied/images-sprites' },
|
||||
{ text: 'SVG-спрайты', link: '/applied/svg-sprites' },
|
||||
{ text: 'Видео', link: '/applied/video' },
|
||||
{ text: 'API', link: '/applied/api' },
|
||||
{ text: 'Stores', link: '/applied/stores' },
|
||||
{ text: 'Хуки', link: '/applied/hooks' },
|
||||
{ text: 'Шрифты', link: '/applied/fonts' },
|
||||
{ text: 'Локализация', link: '/applied/localization' },
|
||||
],
|
||||
},
|
||||
];
|
||||
|
||||
const enSidebar = [
|
||||
{
|
||||
text: 'Processes',
|
||||
items: [
|
||||
{ text: 'Getting Started', link: '/en/workflow/getting-started' },
|
||||
{ text: 'Creating an App', link: '/en/workflow/creating-app' },
|
||||
{ text: 'Creating Pages', link: '/en/workflow/creating-pages' },
|
||||
{ text: 'Creating Components', link: '/en/workflow/creating-components' },
|
||||
{ text: 'Styling', link: '/en/workflow/styling' },
|
||||
{ text: 'Data Fetching', link: '/en/workflow/data-fetching' },
|
||||
{ text: 'State Management', link: '/en/workflow/state-management' },
|
||||
{ text: 'Localization', link: '/en/workflow/localization' },
|
||||
],
|
||||
},
|
||||
{
|
||||
text: 'Basic Rules',
|
||||
items: [
|
||||
{ text: 'Tech Stack', link: '/en/basics/tech-stack' },
|
||||
{ text: 'Architecture', link: '/en/basics/architecture' },
|
||||
{ text: 'Code Style', link: '/en/basics/code-style' },
|
||||
{ text: 'Naming', link: '/en/basics/naming' },
|
||||
{ text: 'Documentation', link: '/en/basics/documentation' },
|
||||
{ text: 'Typing', link: '/en/basics/typing' },
|
||||
],
|
||||
},
|
||||
{
|
||||
text: 'Applied Sections',
|
||||
items: [
|
||||
{ text: 'Project Structure', link: '/en/applied/project-structure' },
|
||||
{ text: 'Components', link: '/en/applied/components' },
|
||||
{ text: 'Templates & Code Generation', link: '/en/applied/templates-generation' },
|
||||
{ text: 'Styles', link: '/en/applied/styles' },
|
||||
{ text: 'Images', link: '/en/applied/images-sprites' },
|
||||
{ text: 'SVG Sprites', link: '/en/applied/svg-sprites' },
|
||||
{ text: 'Video', link: '/en/applied/video' },
|
||||
{ text: 'API', link: '/en/applied/api' },
|
||||
{ text: 'Stores', link: '/en/applied/stores' },
|
||||
{ text: 'Hooks', link: '/en/applied/hooks' },
|
||||
{ text: 'Fonts', link: '/en/applied/fonts' },
|
||||
{ text: 'Localization', link: '/en/applied/localization' },
|
||||
],
|
||||
},
|
||||
];
|
||||
|
||||
export default defineConfig({
|
||||
srcDir: 'docs',
|
||||
title: 'NextJS Style Guide',
|
||||
description: 'Правила и стандарты разработки на NextJS и TypeScript',
|
||||
|
||||
rewrites: {
|
||||
'ru/:rest*': ':rest*',
|
||||
},
|
||||
|
||||
locales: {
|
||||
root: {
|
||||
label: 'Русский',
|
||||
lang: 'ru-RU',
|
||||
themeConfig: {
|
||||
sidebar: ruSidebar,
|
||||
},
|
||||
},
|
||||
en: {
|
||||
label: 'English',
|
||||
lang: 'en-US',
|
||||
link: '/en/',
|
||||
themeConfig: {
|
||||
sidebar: enSidebar,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
@@ -1,3 +1,8 @@
|
||||
.VPNavBarTitle.has-sidebar .title {
|
||||
border-top: none !important;
|
||||
padding-top: 0;
|
||||
}
|
||||
|
||||
.VPNavBarTitle .title {
|
||||
white-space: normal;
|
||||
line-height: 1.2;
|
||||
|
||||
Reference in New Issue
Block a user