Files
saiti-wiki/astro.config.mjs
2026-04-18 16:58:50 +03:00

82 lines
3.0 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
import { defineConfig } from 'astro/config';
import starlight from '@astrojs/starlight';
export default defineConfig({
site: 'https://wiki.example.com',
vite: {
server: {
// Quick Tunnel генерирует новый поддомен при каждом запуске.
// Разрешаем любые хосты, чтобы не ловить блокировку Host header.
allowedHosts: true
},
preview: {
allowedHosts: true
}
},
integrations: [
starlight({
title: 'Astral Archive',
description:
'Премиальный wiki-портал Minecraft-сервера: лор, механики, экономика и гайды.',
locales: {
root: {
label: 'Русский',
lang: 'ru'
}
},
tagline: 'Нереалистичный архив игрового мира',
customCss: ['/src/styles/wiki-egames.css'],
lastUpdated: true,
editLink: {
// Замени URL на свой репозиторий, чтобы кнопка "Редактировать" вела в нужное место.
baseUrl: 'https://github.com/your-org/astral-archive/edit/main/'
},
social: [
{ icon: 'discord', label: 'Discord', href: 'https://discord.gg/example' },
{ icon: 'github', label: 'GitHub', href: 'https://github.com/your-org/astral-archive' }
],
components: {
Header: './src/components/WikiHeader.astro',
EditLink: './src/components/WikiEditLink.astro'
},
sidebar: [
{
label: 'Обзор мира',
items: [
{ label: 'Главная', link: '/' },
{ label: 'О сервере', link: '/about-server/' },
{ label: 'Начало игры', link: '/getting-started/' }
]
},
{
label: 'Игровые системы',
items: [
{ label: 'Гайды', link: '/guides/' },
{ label: 'Механики', link: '/mechanics/' },
{ label: 'Профессии / классы / расы', link: '/professions/' },
{ label: 'Экономика', link: '/economy/' },
{ label: 'Предметы и ресурсы', link: '/items-resources/' }
]
},
{
label: 'Сервер и сообщество',
items: [
{ label: 'Донат / привилегии', link: '/donate/' },
{ label: 'FAQ', link: '/faq/' },
{ label: 'Правила', link: '/rules/' },
{ label: 'Команда проекта', link: '/team/' },
{ label: 'Контакты / ссылки', link: '/contacts/' }
]
},
{
label: 'Для редакторов',
items: [
{ label: 'Как редактировать wiki', link: '/editing/' },
{ label: 'Шаблон новой страницы', link: '/templates/new-page-template/' }
]
}
]
})
]
});