|
| 1 | +// apps/docs-27/astro.config.mjs |
| 2 | +import { defineConfig } from 'astro/config'; |
| 3 | +import starlight from '@astrojs/starlight'; |
| 4 | + |
| 5 | +export default defineConfig({ |
| 6 | + // The base path for this version — critical for URL structure |
| 7 | + base: '/2.7', |
| 8 | + |
| 9 | + integrations: [ |
| 10 | + starlight({ |
| 11 | + title: 'XOOPS 2.7 Docs', |
| 12 | + logo: { |
| 13 | + src: './src/assets/xoops-logo.svg', |
| 14 | + }, |
| 15 | + components: { |
| 16 | + // Replaces the default SiteTitle with your version switcher next to it |
| 17 | + SiteTitle: './src/components/SiteTitleWithVersion.astro', |
| 18 | + }, |
| 19 | + // Default language = English (no prefix in URL) |
| 20 | + defaultLocale: 'en', |
| 21 | + locales: { |
| 22 | + // Root = English: docu.xoops.org/2.7/quick-start/ |
| 23 | + root: { label: 'English', lang: 'en' }, |
| 24 | + // German: docu.xoops.org/2.7/de/quick-start/ |
| 25 | + de: { label: 'Deutsch', lang: 'de' }, |
| 26 | + // French: docu.xoops.org/2.7/fr/quick-start/ |
| 27 | + fr: { label: 'Français', lang: 'fr' }, |
| 28 | + // Arabic: docu.xoops.org/2.7/ar/quick-start/ (RTL) |
| 29 | + ar: { label: 'العربية', lang: 'ar', dir: 'rtl' }, |
| 30 | + }, |
| 31 | + |
| 32 | + sidebar: [ |
| 33 | + { |
| 34 | + label: 'Getting Started', |
| 35 | + translations: { |
| 36 | + de: 'Erste Schritte', |
| 37 | + fr: 'Démarrer', |
| 38 | + ar: 'البدء', |
| 39 | + }, |
| 40 | + items: [ |
| 41 | + { slug: 'quick-start' }, |
| 42 | + { slug: 'installation' }, |
| 43 | + { slug: 'configuration' }, |
| 44 | + ], |
| 45 | + }, |
| 46 | + { |
| 47 | + label: 'Module Development', |
| 48 | + translations: { |
| 49 | + de: 'Modulentwicklung', |
| 50 | + fr: 'Développement de modules', |
| 51 | + }, |
| 52 | + items: [ |
| 53 | + { slug: 'module-guide/introduction' }, |
| 54 | + { slug: 'module-guide/structure' }, |
| 55 | + { slug: 'module-guide/xoops-object' }, |
| 56 | + ], |
| 57 | + }, |
| 58 | + { |
| 59 | + label: 'Theme Development', |
| 60 | + items: [ |
| 61 | + { slug: 'theme-guide/introduction' }, |
| 62 | + { slug: 'theme-guide/smarty-variables' }, |
| 63 | + ], |
| 64 | + }, |
| 65 | + { |
| 66 | + label: 'Upgrading', |
| 67 | + items: [ |
| 68 | + { slug: 'migration/from-2-6' }, |
| 69 | + { slug: 'migration/from-wordpress' }, |
| 70 | + ], |
| 71 | + }, |
| 72 | + ], |
| 73 | + |
| 74 | + // GitHub edit links |
| 75 | + editLink: { |
| 76 | + baseUrl: 'https://github.com/XOOPS/xoops-docs/edit/main/apps/docs-27/', |
| 77 | + }, |
| 78 | + |
| 79 | + // Last updated timestamps |
| 80 | + lastUpdated: true, |
| 81 | + |
| 82 | + // Social links |
| 83 | + social: { |
| 84 | + github: 'https://github.com/XOOPS/xoops-docs', |
| 85 | + }, |
| 86 | + }), |
| 87 | + ], |
| 88 | +}); |
0 commit comments