@lupinum/ginko-docs 0.2.2 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +130 -73
- package/app/app.config.ts +14 -12
- package/app/app.vue +2 -2
- package/app/assets/css/prose.css +2203 -149
- package/app/assets/css/tailwind.css +60 -38
- package/app/assets/css/theme-palettes.css +309 -0
- package/app/components/content/DocumentPageShell.vue +1 -1
- package/app/components/content/Feedback.vue +12 -11
- package/app/components/content/ImageZoomDialog.vue +84 -0
- package/app/components/content/PageMarkdownCopy.vue +2 -0
- package/app/components/content/imageZoom.ts +25 -0
- package/app/components/mdc/MdcAccordion.vue +6 -3
- package/app/components/mdc/MdcAccordionItem.vue +7 -16
- package/app/components/mdc/MdcApi.vue +159 -0
- package/app/components/mdc/MdcAside.vue +6 -10
- package/app/components/mdc/MdcCallout.vue +9 -10
- package/app/components/mdc/MdcCard.vue +36 -47
- package/app/components/mdc/MdcCards.vue +30 -0
- package/app/components/mdc/MdcCodeGroup.vue +4 -0
- package/app/components/mdc/MdcCodeTree.vue +234 -0
- package/app/components/mdc/MdcCollapse.vue +61 -0
- package/app/components/mdc/MdcError.vue +8 -1
- package/app/components/mdc/MdcExcerpt.vue +26 -0
- package/app/components/mdc/MdcFigure.vue +54 -20
- package/app/components/mdc/MdcFiles.vue +120 -0
- package/app/components/mdc/MdcIdea.vue +2 -1
- package/app/components/mdc/MdcInfo.vue +2 -1
- package/app/components/mdc/MdcInlineToc.vue +51 -0
- package/app/components/{ui/dialog/DialogHeader.vue → mdc/MdcKbd.vue} +2 -4
- package/app/components/mdc/MdcNote.vue +2 -1
- package/app/components/mdc/MdcQuiz.vue +43 -83
- package/app/components/mdc/MdcQuizQuestion.vue +104 -109
- package/app/components/mdc/MdcReadMore.vue +57 -77
- package/app/components/mdc/MdcSteps.vue +45 -11
- package/app/components/mdc/MdcSuccess.vue +8 -1
- package/app/components/mdc/MdcTabs.vue +44 -26
- package/app/components/mdc/MdcTimeline.vue +4 -1
- package/app/components/mdc/MdcTimelineItem.vue +18 -27
- package/app/components/mdc/MdcWarning.vue +8 -1
- package/app/components/mdc/api.utils.ts +132 -0
- package/app/components/mdc/code-tree.utils.ts +22 -0
- package/app/components/mdc/quiz.utils.ts +38 -0
- package/app/components/prose/ProseBlockquote.vue +17 -1
- package/app/components/prose/ProseH1.vue +1 -1
- package/app/components/prose/ProseH2.vue +7 -2
- package/app/components/prose/ProseH3.vue +7 -2
- package/app/components/prose/ProseH4.vue +17 -2
- package/app/components/{ui/kbd/KbdGroup.vue → prose/ProseH5.vue} +4 -3
- package/app/components/{ui/card/CardTitle.vue → prose/ProseH6.vue} +4 -3
- package/app/components/prose/ProseImg.vue +19 -112
- package/app/components/prose/ProsePre.vue +63 -100
- package/app/components/prose/ProseTable.vue +5 -3
- package/app/components/site/ModeToggle.vue +12 -3
- package/app/components/site/SiteBanner.vue +43 -2
- package/app/components/site/SiteFooter.vue +3 -5
- package/app/components/site/SiteHeader.vue +255 -132
- package/app/components/site/SiteHeroCode.vue +164 -0
- package/app/components/site/SiteLocaleSwitcher.vue +22 -4
- package/app/components/ui/badge/Badge.vue +1 -1
- package/app/components/ui/button/Button.vue +1 -1
- package/app/components/ui/collapsible/CollapsibleContent.vue +1 -1
- package/app/components/ui/dropdown-menu/DropdownMenuContent.vue +14 -4
- package/app/components/ui/dropdown-menu/DropdownMenuItem.vue +1 -1
- package/app/components/ui/dropdown-menu/DropdownMenuRadioItem.vue +1 -1
- package/app/components/ui/dropdown-menu/DropdownMenuSeparator.vue +1 -1
- package/app/components/ui/dropdown-menu/index.ts +0 -9
- package/app/components/ui/kbd/Kbd.vue +1 -1
- package/app/components/ui/kbd/index.ts +0 -1
- package/app/components/ui/scroll-area/ScrollArea.vue +1 -1
- package/app/components/ui/scroll-area/ScrollBar.vue +1 -1
- package/app/components/ui/separator/Separator.vue +1 -1
- package/app/components/ui/sheet/SheetContent.vue +1 -1
- package/app/components/ui/sheet/SheetDescription.vue +1 -1
- package/app/components/ui/sheet/SheetOverlay.vue +1 -1
- package/app/components/ui/sheet/SheetTitle.vue +1 -1
- package/app/components/ui/sheet/index.ts +0 -3
- package/app/components/ui/tabs/Tabs.vue +1 -1
- package/app/components/ui/tabs/TabsList.vue +1 -1
- package/app/components/ui/tabs/TabsTrigger.vue +1 -1
- package/app/components/ui/tabs/index.ts +0 -1
- package/app/composables/site-navigation.utils.ts +29 -11
- package/app/composables/useContentRouteAlternates.ts +13 -21
- package/app/composables/useLocalizedRouteSwitch.ts +1 -1
- package/app/composables/useMetaKey.ts +18 -0
- package/app/composables/useProseAppearance.ts +24 -0
- package/app/composables/useSiteNavigation.ts +3 -18
- package/app/config/site.utils.ts +1 -1
- package/app/error.vue +1 -5
- package/app/features/docs/components/DocsBreadcrumb.vue +37 -0
- package/app/features/docs/components/DocsContributeLinks.vue +28 -18
- package/app/features/docs/components/DocsMobileToc.vue +12 -8
- package/app/features/docs/components/DocsPageContent.vue +84 -47
- package/app/features/docs/components/DocsPageNav.vue +1 -1
- package/app/features/docs/components/DocsSidebar.vue +30 -20
- package/app/features/docs/components/DocsSidebarItem.vue +53 -100
- package/app/features/docs/components/DocsSidebarRow.vue +27 -0
- package/app/features/docs/components/DocsSidebarTabs.vue +46 -22
- package/app/features/docs/components/DocsToc.vue +80 -34
- package/app/features/docs/composables/useDocsNavigation.ts +2 -2
- package/app/features/docs/composables/useDocsNavigationData.ts +4 -1
- package/app/features/docs/composables/useRevealActive.ts +58 -0
- package/app/features/docs/composables/useScrollspy.ts +87 -19
- package/app/features/docs/docs-navigation.ts +17 -30
- package/app/features/docs/toc-context.ts +6 -0
- package/app/features/search/command-center.ts +11 -90
- package/app/features/search/components/SiteCommandCenter.vue +58 -38
- package/app/features/search/useCommandCenter.ts +46 -46
- package/app/layouts/docs.vue +1 -1
- package/app/lib/errors.ts +2 -49
- package/app/pages/blog/[slug].vue +16 -8
- package/app/pages/blog/index.vue +26 -13
- package/app/pages/docs/index.vue +10 -14
- package/app/pages/index.vue +174 -59
- package/app/plugins/ginko-docs-theme.ts +12 -0
- package/app/utils/content.ts +11 -0
- package/app/utils/file-icons.ts +90 -0
- package/app/utils/index.ts +7 -1
- package/app/utils/repository.ts +20 -0
- package/content.js +23 -26
- package/content.ts +30 -28
- package/i18n/messages/global/blog.ts +4 -0
- package/i18n/messages/global/command.ts +6 -2
- package/i18n/messages/global/docs.ts +3 -0
- package/i18n/messages/global/nav.ts +6 -2
- package/i18n/messages/index.ts +3 -3
- package/icon-bundle.ts +5 -0
- package/index.d.ts +7 -1
- package/nuxt.config.ts +2 -2
- package/package.json +9 -6
- package/runtime/server/agent-markdown.ts +0 -2
- package/shared/theme-palettes.ts +37 -0
- package/shared/types/app-config.ts +63 -6
- package/tags.ts +47 -59
- package/app/components/mdc/MdcAlert.vue +0 -34
- package/app/components/mdc/MdcCardGroup.vue +0 -47
- package/app/components/mdc/MdcDocImg.vue +0 -25
- package/app/components/mdc/MdcField.vue +0 -62
- package/app/components/mdc/MdcFieldGroup.vue +0 -18
- package/app/components/mdc/MdcPassage.vue +0 -32
- package/app/components/mdc/MdcQuizOption.vue +0 -91
- package/app/components/mdc/MdcReadMoreGroup.vue +0 -18
- package/app/components/mdc/MdcShortcut.vue +0 -46
- package/app/components/mdc/MdcStep.vue +0 -42
- package/app/components/ui/accordion/Accordion.vue +0 -15
- package/app/components/ui/accordion/AccordionContent.vue +0 -23
- package/app/components/ui/accordion/AccordionItem.vue +0 -24
- package/app/components/ui/accordion/AccordionTrigger.vue +0 -35
- package/app/components/ui/accordion/index.ts +0 -4
- package/app/components/ui/alert/Alert.vue +0 -21
- package/app/components/ui/alert/AlertDescription.vue +0 -22
- package/app/components/ui/alert/AlertTitle.vue +0 -22
- package/app/components/ui/alert/index.ts +0 -34
- package/app/components/ui/card/Card.vue +0 -16
- package/app/components/ui/card/CardAction.vue +0 -17
- package/app/components/ui/card/CardContent.vue +0 -14
- package/app/components/ui/card/CardDescription.vue +0 -14
- package/app/components/ui/card/CardFooter.vue +0 -14
- package/app/components/ui/card/CardHeader.vue +0 -22
- package/app/components/ui/card/card-variants.ts +0 -15
- package/app/components/ui/card/index.ts +0 -8
- package/app/components/ui/checkbox/Checkbox.vue +0 -35
- package/app/components/ui/checkbox/index.ts +0 -1
- package/app/components/ui/dialog/Dialog.vue +0 -15
- package/app/components/ui/dialog/DialogClose.vue +0 -12
- package/app/components/ui/dialog/DialogContent.vue +0 -69
- package/app/components/ui/dialog/DialogDescription.vue +0 -21
- package/app/components/ui/dialog/DialogFooter.vue +0 -15
- package/app/components/ui/dialog/DialogOverlay.vue +0 -26
- package/app/components/ui/dialog/DialogPortal.vue +0 -12
- package/app/components/ui/dialog/DialogTitle.vue +0 -21
- package/app/components/ui/dialog/DialogTrigger.vue +0 -12
- package/app/components/ui/dialog/index.ts +0 -10
- package/app/components/ui/dropdown-menu/DropdownMenuCheckboxItem.vue +0 -36
- package/app/components/ui/dropdown-menu/DropdownMenuGroup.vue +0 -12
- package/app/components/ui/dropdown-menu/DropdownMenuLabel.vue +0 -25
- package/app/components/ui/dropdown-menu/DropdownMenuShortcut.vue +0 -17
- package/app/components/ui/dropdown-menu/DropdownMenuSub.vue +0 -15
- package/app/components/ui/dropdown-menu/DropdownMenuSubContent.vue +0 -29
- package/app/components/ui/dropdown-menu/DropdownMenuSubTrigger.vue +0 -31
- package/app/components/ui/input/Input.vue +0 -23
- package/app/components/ui/input/index.ts +0 -1
- package/app/components/ui/label/Label.vue +0 -14
- package/app/components/ui/label/index.ts +0 -1
- package/app/components/ui/sheet/SheetClose.vue +0 -12
- package/app/components/ui/sheet/SheetFooter.vue +0 -12
- package/app/components/ui/sheet/SheetHeader.vue +0 -12
- package/app/components/ui/switch/Switch.vue +0 -39
- package/app/components/ui/switch/index.ts +0 -1
- package/app/components/ui/tabs/TabsContent.vue +0 -21
- package/app/components/ui/textarea/Textarea.vue +0 -31
- package/app/components/ui/textarea/index.ts +0 -1
- package/app/features/docs/composables/useDocsEntryPath.ts +0 -13
- package/app/lib/utils.ts +0 -7
- package/i18n/messages/source.ts +0 -5
- package/runtime/markdown/inline-code-highlight.ts +0 -155
- package/runtime/utils.ts +0 -7
package/README.md
CHANGED
|
@@ -1,111 +1,168 @@
|
|
|
1
1
|
# Ginko Docs
|
|
2
2
|
|
|
3
|
-
Ginko Docs is a
|
|
3
|
+
Ginko Docs is a Nuxt layer for focused documentation sites. It combines Ginko Content collections with a documentation shell, navigation, search, localization, SEO, social images, optional blog routes, and agent-readable Markdown surfaces.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
## Requirements
|
|
6
|
+
|
|
7
|
+
- Node.js `^22.18.0 || ^24.11.0 || >=26.0.0`
|
|
8
|
+
- Nuxt `>=4.4.7 <5`
|
|
9
|
+
- Vue `^3.5.35`
|
|
10
|
+
- Vue Router `^5.1.0`
|
|
11
|
+
- Ginko Content `>=0.3.2 <0.4.0`
|
|
6
12
|
|
|
7
13
|
## Install
|
|
8
14
|
|
|
9
|
-
|
|
10
|
-
|
|
15
|
+
Install the layer and its Ginko Content peer:
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
pnpm add -D @lupinum/ginko-docs @lupinum/ginko-content@0.3.2
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Keep the public identity in one shared value:
|
|
22
|
+
|
|
23
|
+
```json [site.json]
|
|
24
|
+
{
|
|
25
|
+
"name": "Example Docs",
|
|
26
|
+
"description": "Documentation for Example.",
|
|
27
|
+
"url": "https://docs.example.com"
|
|
28
|
+
}
|
|
11
29
|
```
|
|
12
30
|
|
|
13
|
-
Extend the layer
|
|
31
|
+
Extend the layer and configure the canonical origin:
|
|
32
|
+
|
|
33
|
+
```ts [nuxt.config.ts]
|
|
34
|
+
import site from "./site.json" with { type: "json" };
|
|
14
35
|
|
|
15
|
-
```ts
|
|
16
36
|
export default defineNuxtConfig({
|
|
17
37
|
extends: ["@lupinum/ginko-docs"],
|
|
38
|
+
site: { url: site.url },
|
|
39
|
+
i18n: { baseUrl: site.url },
|
|
18
40
|
});
|
|
19
41
|
```
|
|
20
42
|
|
|
21
|
-
Define the
|
|
43
|
+
Define the content collections in `content.config.ts`:
|
|
22
44
|
|
|
23
|
-
```ts
|
|
45
|
+
```ts [content.config.ts]
|
|
24
46
|
import { defineGinkoDocsConfig } from "@lupinum/ginko-docs/content";
|
|
47
|
+
import site from "./site.json" with { type: "json" };
|
|
25
48
|
|
|
26
49
|
export default defineGinkoDocsConfig({
|
|
27
|
-
site
|
|
28
|
-
name: "Example Docs",
|
|
29
|
-
description: "Documentation for Example.",
|
|
30
|
-
url: "https://docs.example.com",
|
|
31
|
-
},
|
|
50
|
+
site,
|
|
32
51
|
locales: ["en"],
|
|
33
|
-
defaultLocale: "en",
|
|
34
52
|
blog: false,
|
|
35
53
|
});
|
|
36
54
|
```
|
|
37
55
|
|
|
38
|
-
|
|
56
|
+
Single-locale documentation belongs in `content/docs`. Add a first page:
|
|
57
|
+
|
|
58
|
+
```md [content/docs/1.introduction.md]
|
|
59
|
+
---
|
|
60
|
+
title: Introduction
|
|
61
|
+
description: Learn what Example does and how to use it.
|
|
62
|
+
---
|
|
63
|
+
|
|
64
|
+
Example solves ...
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
The bare `/docs` route redirects to the first navigable document.
|
|
68
|
+
|
|
69
|
+
## Set the public identity
|
|
39
70
|
|
|
40
|
-
|
|
71
|
+
Presentation settings live in `app/app.config.ts`:
|
|
41
72
|
|
|
42
|
-
```ts
|
|
43
|
-
|
|
73
|
+
```ts [app/app.config.ts]
|
|
74
|
+
import site from "../site.json";
|
|
75
|
+
|
|
76
|
+
export default defineAppConfig({
|
|
44
77
|
ginkoDocs: {
|
|
45
78
|
site: {
|
|
46
|
-
name: { en:
|
|
47
|
-
description: { en:
|
|
48
|
-
url:
|
|
79
|
+
name: { en: site.name },
|
|
80
|
+
description: { en: site.description },
|
|
81
|
+
url: site.url,
|
|
49
82
|
logo: { light: "/logo.svg", dark: "/logo-dark.svg" },
|
|
83
|
+
docsSidebarSwitcher: "tabs",
|
|
84
|
+
lupinumAttribution: true,
|
|
50
85
|
},
|
|
86
|
+
nav: { links: "auto" },
|
|
87
|
+
banner: { enabled: false, id: "default", showOnLanding: true },
|
|
88
|
+
feedback: { enabled: false },
|
|
89
|
+
toc: { depth: 3 },
|
|
51
90
|
},
|
|
52
|
-
};
|
|
91
|
+
});
|
|
53
92
|
```
|
|
54
93
|
|
|
55
|
-
|
|
94
|
+
Localized values use `{ en, de? }`. Use English as the default locale; supported content layouts are English-only and bilingual English/German.
|
|
56
95
|
|
|
57
|
-
|
|
58
|
-
- `@lupinum/ginko-docs/content` — typed content configuration factory
|
|
59
|
-
- `@lupinum/ginko-docs/app-config` — application-configuration types
|
|
60
|
-
- `@lupinum/ginko-docs/components` — default MDC tag map and related types
|
|
61
|
-
|
|
62
|
-
## Customize
|
|
63
|
-
|
|
64
|
-
Consumers use Nuxt's ordinary override rules. Add `app/pages/index.vue` or a layout to replace a
|
|
65
|
-
page or layout. Add a same-named `SiteHeader`, `SiteFooter`, `SiteBanner`, `SiteLogoMark`,
|
|
66
|
-
`SiteLocaleSwitcher`, `SiteInteractionLayer`, or `DocsSidebar` component to replace that shell
|
|
67
|
-
piece. Import consumer theme CSS from an app plugin so it augments rather than replaces the layer's
|
|
68
|
-
styles. Add or replace MDC components in `app/components/mdc` and extend
|
|
69
|
-
`ginkoDocsComponentTags` from `@lupinum/ginko-docs/components` in `content.markdown.tags`. Register
|
|
70
|
-
custom MDC components globally with a Nuxt plugin or Nuxt's `.global.vue` filename suffix, because
|
|
71
|
-
MDC resolves tag targets dynamically. Each new tag must also declare its narrow static prop and slot
|
|
72
|
-
contract in `content.componentPolicy`; Nuxt merges that consumer entry with the layer's built-in
|
|
73
|
-
policy.
|
|
74
|
-
|
|
75
|
-
Custom agent Markdown is deliberately separate: register serializers through
|
|
76
|
-
`@lupinum/ginko-content/agent-registry` in a Nitro plugin.
|
|
77
|
-
|
|
78
|
-
## Configuration
|
|
79
|
-
|
|
80
|
-
All features are configured under the `ginkoDocs` key in `app/app.config.ts` and ship with safe
|
|
81
|
-
defaults:
|
|
82
|
-
|
|
83
|
-
- `nav.links` — `"auto"` (Docs + Blog when present) or an array of localized links.
|
|
84
|
-
- `banner` — announcement bar with persisted dismissal (`enabled: "auto" | boolean`, `id`, `text`,
|
|
85
|
-
`link`, `showOnLanding`).
|
|
86
|
-
- `analytics.plausible` — Plausible via Nuxt Scripts; disabled until `domain` is set
|
|
87
|
-
(`scriptSrc` for self-hosted, `extensions` default `["outbound-links"]`).
|
|
88
|
-
- `feedback.enabled` — "Was this page helpful?" widget; votes fire the `docs-feedback` Plausible
|
|
89
|
-
event and negative votes link to a prefilled GitHub issue when `repository` is configured.
|
|
90
|
-
- `ogImage` — build-time PNG social cards (`enabled`, `component`); override the template by
|
|
91
|
-
shadowing `app/components/OgImage/GinkoDocs.satori.vue`.
|
|
92
|
-
- `markdownActions` — toggle ChatGPT / Claude / MCP entries in the Copy Markdown menu.
|
|
93
|
-
- `images.zoom` — click-to-zoom lightbox for prose images.
|
|
94
|
-
- `toc.depth` — table-of-contents depth (2–4).
|
|
95
|
-
- `landing.hero.media` — optional hero visual (`{ type: "code" }` or `{ type: "image" }`).
|
|
96
|
-
- `repository` — enables "Edit this page" / "Report an issue" links.
|
|
97
|
-
|
|
98
|
-
The bare docs root (e.g. `/docs`) redirects to the first documentation page, and the 404 page
|
|
99
|
-
renders with the full site chrome.
|
|
100
|
-
|
|
101
|
-
## Agent surfaces
|
|
102
|
-
|
|
103
|
-
The layer can expose canonical content through raw Markdown negotiation, `/raw/**`, `/llms.txt`, `/llms-full.txt`, and read-only MCP tools. These surfaces use the same Ginko Content route and document model as rendered pages.
|
|
96
|
+
Set the production URL once in `site.json`, then pass it to the content configuration, app configuration, Nuxt Site configuration, and Nuxt i18n `baseUrl`. JSON keeps the shared identity portable across each configuration loader. The layer uses it for canonical links, structured data, social cards, and agent catalogs.
|
|
104
97
|
|
|
105
|
-
##
|
|
98
|
+
## Enable the blog
|
|
99
|
+
|
|
100
|
+
Set `blog: true` in `defineGinkoDocsConfig`. That single option creates the `blog` and `authors` collections and keeps the blog routes in the generated Nuxt application.
|
|
101
|
+
|
|
102
|
+
Blog posts are flat Markdown files under `content/2.blog` for an English-only site, or the corresponding locale directory for a bilingual site. Each post requires `title`, `description`, `date`, `readingTime`, and an `author` reference. Author records live under `authors` and require `slug`, `name`, `role`, `bio`, and `avatar`.
|
|
103
|
+
|
|
104
|
+
## Customize presentation
|
|
105
|
+
|
|
106
|
+
Use Nuxt's normal application directories. A consumer can replace `app/pages/index.vue`, layouts, or a stable shell component by providing the same component name:
|
|
107
|
+
|
|
108
|
+
- `SiteHeader`, `SiteFooter`, `SiteBanner`, `SiteLogoMark`
|
|
109
|
+
- `SiteLocaleSwitcher`, `SiteInteractionLayer`, `DocsSidebar`
|
|
110
|
+
|
|
111
|
+
Load consumer theme CSS from an app plugin so it follows the layer styles without replacing Nuxt's merged `css` array.
|
|
112
|
+
|
|
113
|
+
To add an authored MDC component, extend the exported tag map and declare its static render policy:
|
|
114
|
+
|
|
115
|
+
```ts [nuxt.config.ts]
|
|
116
|
+
import { ginkoDocsComponentTags } from "@lupinum/ginko-docs/components";
|
|
117
|
+
|
|
118
|
+
export default defineNuxtConfig({
|
|
119
|
+
content: {
|
|
120
|
+
componentPolicy: {
|
|
121
|
+
components: {
|
|
122
|
+
"api-playground": {
|
|
123
|
+
kind: "block",
|
|
124
|
+
props: {
|
|
125
|
+
method: { type: "string", required: true },
|
|
126
|
+
path: { type: "string", required: true },
|
|
127
|
+
},
|
|
128
|
+
slots: ["default"],
|
|
129
|
+
media: null,
|
|
130
|
+
},
|
|
131
|
+
},
|
|
132
|
+
},
|
|
133
|
+
markdown: {
|
|
134
|
+
tags: {
|
|
135
|
+
...ginkoDocsComponentTags,
|
|
136
|
+
"api-playground": "MdcApiPlayground",
|
|
137
|
+
},
|
|
138
|
+
},
|
|
139
|
+
},
|
|
140
|
+
});
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
Register the Vue component globally because Markdown resolves component targets dynamically. Register a serializer through `@lupinum/ginko-content/agent-registry` when copied and raw Markdown needs a representation other than the default XML-style component output.
|
|
144
|
+
|
|
145
|
+
## Agent and discovery surfaces
|
|
146
|
+
|
|
147
|
+
Every deployment can include the prerendered routes and assets:
|
|
148
|
+
|
|
149
|
+
- `/raw/**.md`
|
|
150
|
+
- `/llms.txt` and `/llms-full.txt`
|
|
151
|
+
- localized LLM catalogs
|
|
152
|
+
- sitemap, robots, and PNG social images
|
|
153
|
+
|
|
154
|
+
A Nitro server also provides request-time `Accept: text/markdown` negotiation, response link headers, and `/mcp`. The MCP server exposes read-only `list-pages` and `get-page` tools. Plain static hosting cannot provide those request-time behaviors.
|
|
155
|
+
|
|
156
|
+
The `markdownActions` app settings change the page menu only; they do not disable agent routes.
|
|
157
|
+
|
|
158
|
+
## Public exports
|
|
106
159
|
|
|
107
|
-
|
|
108
|
-
|
|
160
|
+
| Export | Contents |
|
|
161
|
+
| -------------------------------- | ------------------------------------------------------------- |
|
|
162
|
+
| `@lupinum/ginko-docs` | Nuxt layer entry |
|
|
163
|
+
| `@lupinum/ginko-docs/content` | `defineGinkoDocsConfig` |
|
|
164
|
+
| `@lupinum/ginko-docs/app-config` | App-configuration types |
|
|
165
|
+
| `@lupinum/ginko-docs/components` | Tag map, component names, component policy, and related types |
|
|
109
166
|
|
|
110
167
|
## License
|
|
111
168
|
|
package/app/app.config.ts
CHANGED
|
@@ -1,21 +1,27 @@
|
|
|
1
1
|
import type { GinkoDocsAppConfig } from "../shared/types/app-config";
|
|
2
2
|
export default {
|
|
3
3
|
ginkoDocs: {
|
|
4
|
+
theme: {
|
|
5
|
+
neutral: "zinc",
|
|
6
|
+
primary: "neutral",
|
|
7
|
+
},
|
|
8
|
+
prose: {
|
|
9
|
+
appearance: "tint",
|
|
10
|
+
},
|
|
4
11
|
site: {
|
|
5
12
|
name: { en: "Ginko Docs", de: "Ginko Docs" },
|
|
6
13
|
description: {
|
|
7
|
-
en: "
|
|
8
|
-
de: "
|
|
14
|
+
en: "Documentation sites built with Nuxt and Ginko Content.",
|
|
15
|
+
de: "Dokumentations-Sites auf Basis von Nuxt und Ginko Content.",
|
|
9
16
|
},
|
|
10
17
|
url: "http://localhost:3000",
|
|
11
18
|
logo: { light: "/logo.svg", dark: "/logo-dark.svg" },
|
|
12
|
-
localeSwitcher: "dropdown",
|
|
13
19
|
docsSidebarSwitcher: "tabs",
|
|
14
20
|
lupinumAttribution: true,
|
|
15
21
|
},
|
|
16
22
|
nav: { links: "auto" },
|
|
17
23
|
banner: {
|
|
18
|
-
enabled:
|
|
24
|
+
enabled: false,
|
|
19
25
|
id: "default",
|
|
20
26
|
showOnLanding: true,
|
|
21
27
|
},
|
|
@@ -27,17 +33,13 @@ export default {
|
|
|
27
33
|
toc: { depth: 3 },
|
|
28
34
|
repository: undefined,
|
|
29
35
|
landing: {
|
|
30
|
-
eyebrow: {
|
|
31
|
-
en: "Documentation for humans and agents",
|
|
32
|
-
de: "Dokumentation für Menschen und Agenten",
|
|
33
|
-
},
|
|
34
36
|
title: {
|
|
35
|
-
en: "
|
|
36
|
-
de: "
|
|
37
|
+
en: "Publish structured documentation.",
|
|
38
|
+
de: "Veröffentliche strukturierte Dokumentation.",
|
|
37
39
|
},
|
|
38
40
|
description: {
|
|
39
|
-
en: "A
|
|
40
|
-
de: "Ein
|
|
41
|
+
en: "A Nuxt layer for searchable, localized documentation with stable routes and agent-readable output.",
|
|
42
|
+
de: "Ein Nuxt-Layer für durchsuchbare, lokalisierte Dokumentation mit stabilen Routen und agentenlesbarer Ausgabe.",
|
|
41
43
|
},
|
|
42
44
|
primary: {
|
|
43
45
|
label: { en: "Get started", de: "Erste Schritte" },
|
package/app/app.vue
CHANGED
|
@@ -46,14 +46,14 @@ useHead(() => ({
|
|
|
46
46
|
const language = typeof entry === "string" ? entry : (entry.language ?? entry.code);
|
|
47
47
|
return {
|
|
48
48
|
key: `alternate-${code}`,
|
|
49
|
-
rel: "alternate",
|
|
49
|
+
rel: "alternate" as const,
|
|
50
50
|
hreflang: language,
|
|
51
51
|
href: new URL(switchPathname(code) || route.path, siteUrl).toString(),
|
|
52
52
|
};
|
|
53
53
|
}),
|
|
54
54
|
{
|
|
55
55
|
key: "alternate-x-default",
|
|
56
|
-
rel: "alternate",
|
|
56
|
+
rel: "alternate" as const,
|
|
57
57
|
hreflang: "x-default",
|
|
58
58
|
href: new URL(switchPathname(defaultLocale) || route.path, siteUrl).toString(),
|
|
59
59
|
},
|