e998c8a03a
Build · Site / build (push) Successful in 8s
Tests · Integration / integration (pull_request) Successful in 1m42s
Build · Site / build (pull_request) Successful in 8s
Tests · UI / test (pull_request) Successful in 3m20s
Tests · Go / test (pull_request) Successful in 1m59s
site/rules.md is a faithful English mirror of the authoritative Russian site/ru/rules.md — the same section anchors (so the in-page cross-links and the RU/EN structure line up), the same LaTeX formulas with English labels, and the same tables and engine nuances. Rewrite the English home intro to match the Russian one and link to the rules, and register Rules in the English sidebar. Completes the bilingual rules.
66 lines
2.1 KiB
TypeScript
66 lines
2.1 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: "/" },
|
|
{ text: "Rules", link: "/rules" },
|
|
],
|
|
},
|
|
],
|
|
},
|
|
},
|
|
ru: {
|
|
label: "Русский",
|
|
lang: "ru",
|
|
link: "/ru/",
|
|
themeConfig: {
|
|
nav: [{ text: "Играть", link: "/game/", target: "_self" }],
|
|
sidebar: [
|
|
{
|
|
text: "Galaxy",
|
|
items: [
|
|
{ text: "Обзор", link: "/ru/" },
|
|
{ text: "Правила", link: "/ru/rules" },
|
|
],
|
|
},
|
|
],
|
|
},
|
|
},
|
|
},
|
|
});
|