Getting Started
This site is a static Astro gallery shell for the upstream awesome-design-md catalog. English stays unprefixed, and the site shell now exposes the same Desktop-aligned locale range as HagiCode Desktop.
What is included
- Astro 6 static output with React islands for small interactive controls.
- Desktop-aligned locale routes for zh-CN, zh-Hant, ja-JP, ko-KR, de-DE, fr-FR, es-ES, pt-BR, and ru-RU.
- hagi18n YAML source files under src/i18n/locales and generated runtime resources under src/i18n/generated.
- Vendor gallery content from vendor/awesome-design-md stays outside the hagi18n UI source tree.
i18n workflow
- Edit first-party UI strings and locale metadata in src/i18n/locales/<locale>/*.yml.
- Run npm run i18n:audit or npm run i18n:doctor before regenerating runtime resources.
- Run npm run i18n:generate to refresh src/i18n/generated/site-locale-resources.ts.
- Run npm run i18n:check to combine audit, doctor, generation, and stale-resource verification.
Shell stylesheet source of truth
- Runtime shell and header styles live in public/global.css because BaseLayout.astro links /global.css directly.
- Treat src/styles/global.css as a reference copy unless the layout import path changes.
First edits
- Update YAML locale sources instead of editing a hand-written localeCopy object.
- Point SITE_URL at the real deployment domain before production builds.
- Replace or extend the gallery shell sections in src/components and src/pages as needed.
- Keep generated runtime resources committed and refresh them after YAML changes.
Commands
npm install
git submodule update --init --recursive
npm run i18n:check
npm run test
npm run typecheck
SITE_URL=https://your-domain.example npm run build