d3770e7f77
Faithful Markdown rendering of game/rules.txt for the site: headings with stable anchors, GFM tables and LaTeX formulas — the text itself is unchanged (typos, the TODO/WTF notes, the broken (---ссылка---) marker and the lore intro are all preserved as-is). The editorial pass (clarity, nuances, organic cross-links, intro moved to the home page) follows in a separate commit so its diff isolates exactly what changed relative to the original. Registers the page in the RU sidebar.
63 lines
2.0 KiB
TypeScript
63 lines
2.0 KiB
TypeScript
import { defineConfig } from "vitepress";
|
|
|
|
// Galaxy project site. The single-origin deployment serves this static
|
|
// build at the root (`/`); the game UI lives under `/game/`. The site is
|
|
// Markdown-first with the default theme's two-column navigation (left:
|
|
// chapters; right: on-this-page), LaTeX math, and a minimal monospace
|
|
// theme. Internationalisation uses VitePress `locales`, which renders the
|
|
// built-in language switcher in the nav bar.
|
|
export default defineConfig({
|
|
title: "Galaxy",
|
|
description: "Galaxy — a turn-based space strategy game.",
|
|
cleanUrls: true,
|
|
// READMEs (this dir's and any future per-section ones) are developer
|
|
// docs, not site pages.
|
|
srcExclude: ["**/README.md"],
|
|
// The game UI is served from `/game/` by the edge Caddy, not by
|
|
// VitePress, so its links must skip the dead-link checker.
|
|
ignoreDeadLinks: [/^\/game\//],
|
|
markdown: {
|
|
// LaTeX via markdown-it-mathjax3: inline `$…$`, block `$$…$$`.
|
|
math: true,
|
|
},
|
|
themeConfig: {
|
|
outline: { level: [2, 3], label: "On this page" },
|
|
},
|
|
locales: {
|
|
root: {
|
|
label: "English",
|
|
lang: "en",
|
|
themeConfig: {
|
|
// The game is a separate app under /game/, not a VitePress page.
|
|
// target "_self" makes the link a real navigation (full load),
|
|
// not a client-side SPA route — otherwise VitePress shows its
|
|
// own 404 for the unknown route.
|
|
nav: [{ text: "Play", link: "/game/", target: "_self" }],
|
|
sidebar: [
|
|
{
|
|
text: "Galaxy",
|
|
items: [{ text: "Overview", link: "/" }],
|
|
},
|
|
],
|
|
},
|
|
},
|
|
ru: {
|
|
label: "Русский",
|
|
lang: "ru",
|
|
link: "/ru/",
|
|
themeConfig: {
|
|
nav: [{ text: "Играть", link: "/game/", target: "_self" }],
|
|
sidebar: [
|
|
{
|
|
text: "Galaxy",
|
|
items: [
|
|
{ text: "Обзор", link: "/ru/" },
|
|
{ text: "Правила", link: "/ru/rules" },
|
|
],
|
|
},
|
|
],
|
|
},
|
|
},
|
|
},
|
|
});
|