import {themes as prismThemes} from 'prism-react-renderer'; import type {Config} from '@docusaurus/types'; import type * as Preset from '@docusaurus/preset-classic'; const docsCommon = { showLastUpdateAuthor: true, showLastUpdateTime: true, editUrl: 'https://gitea.lego-cloud.eu/corp-v1/portal/_edit/main/', }; const config: Config = { title: 'Corp v1 Board', tagline: 'Project governance, Board, teams, and membership registry', url: 'https://pages.apps.lego-cloud.eu', baseUrl: '/corp-v1/portal/', organizationName: 'corp-v1', projectName: 'portal', trailingSlash: true, onBrokenLinks: 'throw', markdown: {hooks: {onBrokenMarkdownLinks: 'throw'}}, i18n: {defaultLocale: 'en', locales: ['en']}, presets: [[ 'classic', { docs: { ...docsCommon, path: 'docs/overview', routeBasePath: '/', sidebarPath: './sidebars/overview.ts', }, blog: false, theme: {customCss: './src/css/custom.css'}, sitemap: {changefreq: 'weekly', priority: 0.5}, } satisfies Preset.Options, ]], plugins: [ ['drawio', {lib: '/corp-v1/portal/drawio/viewer.min.js'}], ['@docusaurus/plugin-content-docs', {...docsCommon, id: 'architecture-high-level', path: 'docs/architecture-high-level', routeBasePath: 'architecture-high-level', sidebarPath: './sidebars/architecture-high-level.ts'}], ['@docusaurus/plugin-content-docs', {...docsCommon, id: 'projects', path: 'docs/projects', routeBasePath: 'projects', sidebarPath: './sidebars/projects.ts'}], ['@docusaurus/plugin-content-docs', {...docsCommon, id: 'teams', path: 'docs/teams', routeBasePath: 'teams', sidebarPath: './sidebars/teams.ts'}], ['@docusaurus/plugin-content-docs', {...docsCommon, id: 'members', path: 'docs/members', routeBasePath: 'members', sidebarPath: './sidebars/members.ts'}], ['@docusaurus/plugin-content-docs', {...docsCommon, id: 'board', path: 'docs/board', routeBasePath: 'board', sidebarPath: './sidebars/board.ts'}], ['@docusaurus/plugin-content-docs', {...docsCommon, id: 'governance', path: 'docs/governance', routeBasePath: 'governance', sidebarPath: './sidebars/governance.ts'}], ], themes: [[ require.resolve('@easyops-cn/docusaurus-search-local'), { hashed: 'filename', indexDocs: true, indexBlog: false, indexPages: true, docsRouteBasePath: ['/', 'architecture-high-level', 'projects', 'teams', 'members', 'board', 'governance'], language: ['en'], highlightSearchTermsOnTargetPage: true, explicitSearchResultPath: true, searchResultLimits: 12, searchResultContextMaxLength: 120, }, ]], themeConfig: { colorMode: {defaultMode: 'dark', disableSwitch: false, respectPrefersColorScheme: true}, navbar: { title: 'CORP V1 / BOARD', items: [ {type: 'docSidebar', sidebarId: 'architectureHighLevelSidebar', docsPluginId: 'architecture-high-level', label: 'Architecture High Level', position: 'left'}, {type: 'docSidebar', sidebarId: 'projectsSidebar', docsPluginId: 'projects', label: 'Projects', position: 'left'}, {type: 'docSidebar', sidebarId: 'teamsSidebar', docsPluginId: 'teams', label: 'Teams', position: 'left'}, {type: 'docSidebar', sidebarId: 'membersSidebar', docsPluginId: 'members', label: 'Members', position: 'left'}, {type: 'docSidebar', sidebarId: 'boardSidebar', docsPluginId: 'board', label: 'Board', position: 'left'}, {type: 'docSidebar', sidebarId: 'governanceSidebar', docsPluginId: 'governance', label: 'Governance', position: 'left'}, {href: 'https://gitea.lego-cloud.eu/corp-v1/portal', label: 'Gitea ↗', position: 'right'}, ], }, footer: { style: 'light', links: [{title: 'Registry', items: [ {label: 'Architecture High Level', to: '/architecture-high-level/context/'}, {label: 'Projects', to: '/projects/'}, {label: 'Teams', to: '/teams/'}, {label: 'Members', to: '/members/'}, {label: 'Board', to: '/board/'}, ]}, {title: 'Governance', items: [ {label: 'Project lifecycle', to: '/governance/project-lifecycle/'}, {label: 'Decision log', to: '/governance/decisions/'}, ]}], copyright: `© ${new Date().getFullYear()} Corp v1 Board`, }, prism: {theme: prismThemes.github, darkTheme: prismThemes.oneDark}, } satisfies Preset.ThemeConfig, }; export default config;