@takazudo/zudo-doc 5.28.2 → 6.0.1
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/CHANGELOG.md +33 -0
- package/README.md +49 -16
- package/bin/gen-z-index.mjs +18 -18
- package/dist/agent-docs/identity.d.ts +4 -0
- package/dist/agent-docs/identity.js +24 -0
- package/dist/agent-docs/index.d.ts +5 -0
- package/dist/agent-docs/index.js +5 -0
- package/dist/agent-docs/limits.d.ts +11 -0
- package/dist/agent-docs/limits.js +24 -0
- package/dist/agent-docs/search.d.ts +14 -0
- package/dist/agent-docs/search.js +82 -0
- package/dist/agent-docs/tokenize.d.ts +2 -0
- package/dist/agent-docs/tokenize.js +22 -0
- package/dist/agent-docs/types.d.ts +68 -0
- package/dist/agent-docs/types.js +0 -0
- package/dist/ai-chat-modal/index.d.ts +1 -4
- package/dist/ai-chat-modal/index.js +183 -123
- package/dist/asset-components/asset-card.d.ts +1 -2
- package/dist/asset-components/asset-card.js +12 -12
- package/dist/asset-components/asset-code.d.ts +1 -2
- package/dist/asset-components/asset-code.js +10 -10
- package/dist/asset-components/shared.d.ts +3 -4
- package/dist/asset-components/shared.js +4 -4
- package/dist/asset-index-page/body.d.ts +5 -6
- package/dist/asset-index-page/body.js +6 -6
- package/dist/asset-index-page/index.d.ts +1 -2
- package/dist/asset-index-page/index.js +1 -1
- package/dist/asset-page/body.d.ts +5 -9
- package/dist/asset-page/body.js +3 -3
- package/dist/asset-page/components.d.ts +16 -17
- package/dist/asset-page/components.js +10 -9
- package/dist/asset-page/index.d.ts +1 -2
- package/dist/asset-page/index.js +1 -1
- package/dist/auto-logo/index.d.ts +1 -2
- package/dist/auto-logo/index.js +2 -2
- package/dist/body-foot-util/body-foot-util-area.d.ts +3 -4
- package/dist/body-foot-util/body-foot-util-area.js +1 -2
- package/dist/body-foot-util/edit-link.d.ts +2 -3
- package/dist/body-foot-util/edit-link.js +1 -2
- package/dist/breadcrumb/breadcrumb.d.ts +6 -6
- package/dist/breadcrumb/breadcrumb.js +3 -4
- package/dist/catalog.js +1 -1
- package/dist/category-nav/index.d.ts +1 -2
- package/dist/category-nav/index.js +11 -5
- package/dist/category-tree-nav/index.d.ts +1 -2
- package/dist/category-tree-nav/index.js +3 -3
- package/dist/chrome/derive.d.ts +18 -27
- package/dist/chrome/derive.js +47 -29
- package/dist/chrome/index.d.ts +5 -5
- package/dist/chrome/index.js +1 -1
- package/dist/chrome/island-data.d.ts +4 -0
- package/dist/chrome/island-data.js +52 -0
- package/dist/chrome/primary-slots.d.ts +2 -3
- package/dist/chrome-bindings.d.ts +30 -22
- package/dist/code-group/index.d.ts +3 -4
- package/dist/code-group/index.js +3 -7
- package/dist/code-syntax/code-block-enhancer.d.ts +1 -2
- package/dist/code-syntax/code-block-enhancer.js +2 -2
- package/dist/code-syntax/mermaid-init.d.ts +1 -2
- package/dist/code-syntax/mermaid-init.js +5 -2
- package/dist/code-syntax/tabs-init-script.js +1 -1
- package/dist/code-syntax/tabs-init.d.ts +1 -2
- package/dist/code-syntax/tabs-init.js +2 -2
- package/dist/code-syntax/tabs.d.ts +6 -6
- package/dist/code-syntax/tabs.js +8 -8
- package/dist/compiled.css +2937 -2942
- package/dist/config/component-tokens.d.ts +1 -1
- package/dist/config/component-tokens.js +22 -0
- package/dist/config-assertions/index.d.ts +13 -0
- package/dist/config-assertions/index.js +14 -0
- package/dist/config.d.ts +36 -17
- package/dist/config.js +23 -95
- package/dist/content/content-blockquote.d.ts +2 -3
- package/dist/content/content-blockquote.js +3 -3
- package/dist/content/content-code.d.ts +3 -4
- package/dist/content/content-code.js +5 -5
- package/dist/content/content-link.d.ts +3 -4
- package/dist/content/content-link.js +10 -10
- package/dist/content/content-ol.d.ts +2 -3
- package/dist/content/content-ol.js +5 -4
- package/dist/content/content-paragraph.d.ts +2 -3
- package/dist/content/content-paragraph.js +1 -1
- package/dist/content/content-strong.d.ts +2 -3
- package/dist/content/content-strong.js +3 -3
- package/dist/content/content-table.d.ts +2 -3
- package/dist/content/content-table.js +4 -4
- package/dist/content/content-ul.d.ts +2 -3
- package/dist/content/content-ul.js +4 -4
- package/dist/content/heading-h2.d.ts +2 -3
- package/dist/content/heading-h2.js +4 -4
- package/dist/content/heading-h3.d.ts +2 -3
- package/dist/content/heading-h3.js +4 -4
- package/dist/content/heading-h4.d.ts +2 -3
- package/dist/content/heading-h4.js +4 -4
- package/dist/content-admonition/index.d.ts +3 -4
- package/dist/content-admonition/index.js +2 -2
- package/dist/content.css +35 -33
- package/dist/design-token-panel-bootstrap-controller.d.ts +178 -0
- package/dist/design-token-panel-bootstrap-controller.js +359 -0
- package/dist/design-token-panel-bootstrap-island.d.ts +5 -0
- package/dist/design-token-panel-bootstrap-island.js +19 -0
- package/dist/design-token-panel-bootstrap.d.ts +5 -195
- package/dist/design-token-panel-bootstrap.js +3 -288
- package/dist/desktop-sidebar-toggle-island/index.d.ts +2 -7
- package/dist/desktop-sidebar-toggle-island/index.js +2 -58
- package/dist/desktop-sidebar-toggle-island/island.d.ts +4 -0
- package/dist/desktop-sidebar-toggle-island/island.js +43 -0
- package/dist/desktop-sidebar-toggle-island/storage.d.ts +4 -0
- package/dist/desktop-sidebar-toggle-island/storage.js +29 -0
- package/dist/desktop-toc-toggle-island/index.d.ts +2 -7
- package/dist/desktop-toc-toggle-island/index.js +2 -58
- package/dist/desktop-toc-toggle-island/island.d.ts +4 -0
- package/dist/desktop-toc-toggle-island/island.js +43 -0
- package/dist/desktop-toc-toggle-island/storage.d.ts +4 -0
- package/dist/desktop-toc-toggle-island/storage.js +29 -0
- package/dist/details/details.d.ts +3 -4
- package/dist/details/details.js +1 -1
- package/dist/doc-body-end/index.d.ts +1 -2
- package/dist/doc-body-end/index.js +1 -1
- package/dist/doc-body-end-islands/design-token-panel-island.d.ts +2 -2
- package/dist/doc-body-end-islands/design-token-panel-island.js +3 -7
- package/dist/doc-body-end-islands/index.d.ts +4 -21
- package/dist/doc-body-end-islands/index.js +5 -3
- package/dist/doc-body-end-islands/theme-pack-switcher-island.d.ts +3 -13
- package/dist/doc-body-end-islands/theme-pack-switcher-island.js +11 -13
- package/dist/doc-content-header/index.d.ts +1 -2
- package/dist/doc-content-header/index.js +1 -1
- package/dist/doc-history/index.d.ts +1 -1
- package/dist/doc-history/index.js +166 -141
- package/dist/doc-history-area/index.d.ts +6 -4
- package/dist/doc-history-area/index.js +17 -16
- package/dist/doc-metainfo-area/index.d.ts +2 -3
- package/dist/doc-metainfo-area/index.js +1 -1
- package/dist/doc-page-renderer/index.d.ts +13 -7
- package/dist/doc-page-renderer/index.js +10 -1
- package/dist/doc-page-shell/index.d.ts +20 -7
- package/dist/doc-page-shell/index.js +17 -6
- package/dist/doc-pager/index.d.ts +1 -2
- package/dist/doc-pager/index.js +3 -3
- package/dist/doc-tags-area/index.d.ts +2 -3
- package/dist/doc-tags-area/index.js +1 -1
- package/dist/doclayout/doc-layout-with-defaults.d.ts +9 -9
- package/dist/doclayout/doc-layout-with-defaults.js +5 -15
- package/dist/doclayout/doc-layout.d.ts +26 -27
- package/dist/doclayout/doc-layout.js +23 -14
- package/dist/docs-schema/index.d.ts +4 -0
- package/dist/docs-schema/index.js +1 -0
- package/dist/extract-headings/index.js +43 -12
- package/dist/factory-context/index.d.ts +22 -19
- package/dist/features.css +75 -8
- package/dist/find-in-page/find-bar.d.ts +4 -2
- package/dist/find-in-page/find-bar.js +58 -69
- package/dist/find-in-page/index.d.ts +2 -8
- package/dist/find-in-page/index.js +33 -30
- package/dist/footer/footer.d.ts +3 -4
- package/dist/footer/footer.js +3 -3
- package/dist/footer-with-defaults/index.d.ts +2 -3
- package/dist/footer-with-defaults/index.js +1 -1
- package/dist/frontmatter-preview-defaults/index.js +1 -0
- package/dist/head/doc-head.d.ts +1 -1
- package/dist/head/doc-head.js +24 -32
- package/dist/head/og-tags.d.ts +1 -1
- package/dist/head/og-tags.js +8 -7
- package/dist/head/twitter-card.d.ts +1 -1
- package/dist/head/twitter-card.js +1 -1
- package/dist/head-with-defaults/index.d.ts +7 -2
- package/dist/head-with-defaults/index.js +46 -32
- package/dist/header/header.d.ts +8 -8
- package/dist/header/header.js +9 -11
- package/dist/header/types.d.ts +7 -7
- package/dist/header-with-defaults/index.d.ts +3 -4
- package/dist/header-with-defaults/index.js +27 -14
- package/dist/home-intro/index.d.ts +2 -5
- package/dist/home-intro/index.js +7 -5
- package/dist/home-intro/prepare.js +4 -3
- package/dist/home-page/index.d.ts +3 -3
- package/dist/home-page/index.js +19 -17
- package/dist/html-preview-wrapper/highlighted-code.d.ts +3 -4
- package/dist/html-preview-wrapper/highlighted-code.js +19 -17
- package/dist/html-preview-wrapper/html-preview-wrapper.d.ts +4 -25
- package/dist/html-preview-wrapper/html-preview-wrapper.js +2 -87
- package/dist/html-preview-wrapper/html-preview.d.ts +3 -10
- package/dist/html-preview-wrapper/html-preview.js +13 -37
- package/dist/html-preview-wrapper/index.d.ts +2 -1
- package/dist/html-preview-wrapper/index.js +1 -1
- package/dist/html-preview-wrapper/preview-base.d.ts +3 -5
- package/dist/html-preview-wrapper/preview-base.js +56 -59
- package/dist/html-preview-wrapper/wrapper.d.ts +20 -0
- package/dist/html-preview-wrapper/wrapper.js +37 -0
- package/dist/hydration-pending.d.ts +3 -5
- package/dist/hydration-pending.js +7 -5
- package/dist/i18n-version/language-switcher.d.ts +5 -32
- package/dist/i18n-version/language-switcher.js +5 -106
- package/dist/i18n-version/switcher-generated-scripts.d.ts +2 -0
- package/dist/i18n-version/switcher-generated-scripts.js +107 -0
- package/dist/i18n-version/switcher-url-state.d.ts +76 -0
- package/dist/i18n-version/switcher-url-state.js +103 -0
- package/dist/i18n-version/version-banner.d.ts +2 -3
- package/dist/i18n-version/version-banner.js +1 -1
- package/dist/i18n-version/version-switcher.d.ts +5 -50
- package/dist/i18n-version/version-switcher.js +5 -157
- package/dist/icons/index.d.ts +18 -19
- package/dist/icons/index.js +17 -33
- package/dist/image-enlarge/index.d.ts +1 -10
- package/dist/image-enlarge/index.js +80 -55
- package/dist/image-enlarge/public.d.ts +2 -0
- package/dist/image-enlarge/public.js +6 -0
- package/dist/image-enlarge/ssr-fallback.d.ts +2 -0
- package/dist/image-enlarge/ssr-fallback.js +8 -0
- package/dist/index.d.ts +11 -4
- package/dist/inline-version-switcher/index.d.ts +1 -2
- package/dist/inline-version-switcher/index.js +1 -1
- package/dist/island-types/index.d.ts +2 -2
- package/dist/island-types/index.js +1 -5
- package/dist/math-block/index.d.ts +4 -7
- package/dist/math-block/index.js +5 -5
- package/dist/mcp/handler.d.ts +8 -0
- package/dist/mcp/handler.js +129 -0
- package/dist/mcp/index.d.ts +4 -0
- package/dist/mcp/index.js +7 -0
- package/dist/mcp/loader.d.ts +19 -0
- package/dist/mcp/loader.js +202 -0
- package/dist/mdx-components/index.js +40 -108
- package/dist/mermaid-enlarge/index.d.ts +1 -8
- package/dist/mermaid-enlarge/index.js +174 -158
- package/dist/mermaid-enlarge/public.d.ts +2 -0
- package/dist/mermaid-enlarge/public.js +6 -0
- package/dist/mermaid-enlarge/ssr-fallback.d.ts +2 -0
- package/dist/mermaid-enlarge/ssr-fallback.js +8 -0
- package/dist/metainfo/doc-metainfo.d.ts +2 -3
- package/dist/metainfo/doc-metainfo.js +1 -4
- package/dist/metainfo/doc-tags.d.ts +2 -3
- package/dist/metainfo/doc-tags.js +1 -1
- package/dist/metainfo/frontmatter-preview.d.ts +3 -4
- package/dist/metainfo/frontmatter-preview.js +1 -1
- package/dist/nav-data-prep/index.js +6 -4
- package/dist/nav-indexing/category-nav.d.ts +2 -3
- package/dist/nav-indexing/category-nav.js +1 -2
- package/dist/nav-indexing/category-tree-nav.d.ts +2 -3
- package/dist/nav-indexing/category-tree-nav.js +1 -1
- package/dist/nav-indexing/doc-card-grid.d.ts +2 -3
- package/dist/nav-indexing/doc-card-grid.js +1 -2
- package/dist/nav-indexing/docs-sitemap.d.ts +2 -3
- package/dist/nav-indexing/docs-sitemap.js +2 -2
- package/dist/nav-indexing/index.d.ts +1 -1
- package/dist/nav-indexing/nav-card-grid.d.ts +2 -3
- package/dist/nav-indexing/nav-card-grid.js +1 -2
- package/dist/nav-indexing/note-tray-index-parts/card-list.d.ts +1 -2
- package/dist/nav-indexing/note-tray-index-parts/card-list.js +4 -4
- package/dist/nav-indexing/note-tray-index-parts/date-line.d.ts +2 -3
- package/dist/nav-indexing/note-tray-index-parts/date-line.js +1 -1
- package/dist/nav-indexing/note-tray-index-parts/index-list.d.ts +1 -2
- package/dist/nav-indexing/note-tray-index-parts/index-list.js +2 -2
- package/dist/nav-indexing/note-tray-index-parts/timeline.d.ts +1 -2
- package/dist/nav-indexing/note-tray-index-parts/timeline.js +2 -2
- package/dist/nav-indexing/note-tray-index.d.ts +1 -2
- package/dist/nav-indexing/note-tray-index.js +1 -1
- package/dist/nav-indexing/site-tree-nav-demo.d.ts +2 -3
- package/dist/nav-indexing/site-tree-nav-demo.js +2 -2
- package/dist/nav-indexing/tag-nav.d.ts +1 -2
- package/dist/nav-indexing/tag-nav.js +1 -1
- package/dist/nav-indexing/types.d.ts +2 -2
- package/dist/nav-indexing/versions-page-content.d.ts +2 -3
- package/dist/nav-indexing/versions-page-content.js +8 -8
- package/dist/note-tray-index/index.d.ts +1 -2
- package/dist/note-tray-index/index.js +1 -1
- package/dist/page-loading/page-loading-overlay.d.ts +1 -2
- package/dist/page-loading/page-loading-overlay.js +3 -5
- package/dist/plugins/agent-export.d.ts +3 -0
- package/dist/plugins/agent-export.js +34 -0
- package/dist/plugins/internal/agent-export/chunk.d.ts +5 -0
- package/dist/plugins/internal/agent-export/chunk.js +90 -0
- package/dist/plugins/internal/agent-export/index.d.ts +24 -0
- package/dist/plugins/internal/agent-export/index.js +123 -0
- package/dist/plugins/internal/agent-export/normalize.d.ts +5 -0
- package/dist/plugins/internal/agent-export/normalize.js +73 -0
- package/dist/plugins/internal/llms-txt/dev-middleware.d.ts +6 -0
- package/dist/plugins/internal/llms-txt/dev-middleware.js +8 -3
- package/dist/plugins/internal/llms-txt/emit.js +23 -6
- package/dist/plugins/internal/llms-txt/generate.d.ts +7 -1
- package/dist/plugins/internal/llms-txt/generate.js +9 -2
- package/dist/plugins/internal/llms-txt/load.d.ts +2 -0
- package/dist/plugins/internal/llms-txt/load.js +20 -4
- package/dist/plugins/internal/llms-txt/types.d.ts +10 -0
- package/dist/plugins/routes.js +4 -0
- package/dist/preset.d.ts +19 -9
- package/dist/preset.js +20 -1
- package/dist/route-context-payload/index.js +1 -1
- package/dist/routes/404.d.ts +2 -3
- package/dist/routes/404.js +1 -1
- package/dist/routes/_chrome.d.ts +5 -5
- package/dist/routes/_chrome.js +7 -2
- package/dist/routes/_context.d.ts +4 -4
- package/dist/routes/_design-token-panel-bootstrap.d.ts +1 -4
- package/dist/routes/_design-token-panel-bootstrap.js +9 -1
- package/dist/routes/docs-slug.d.ts +2 -3
- package/dist/routes/docs-tags-index.d.ts +2 -3
- package/dist/routes/docs-tags-index.js +1 -1
- package/dist/routes/docs-tags-tag.d.ts +2 -3
- package/dist/routes/docs-tags-tag.js +1 -1
- package/dist/routes/docs-versions.d.ts +2 -3
- package/dist/routes/docs-versions.js +1 -1
- package/dist/routes/files-path.d.ts +2 -3
- package/dist/routes/files-path.js +1 -1
- package/dist/routes/index.d.ts +2 -3
- package/dist/routes/index.js +1 -1
- package/dist/routes/locale-docs-slug.d.ts +2 -3
- package/dist/routes/locale-docs-tags-index.d.ts +2 -3
- package/dist/routes/locale-docs-tags-index.js +1 -1
- package/dist/routes/locale-docs-tags-tag.d.ts +2 -3
- package/dist/routes/locale-docs-tags-tag.js +1 -1
- package/dist/routes/locale-docs-versions.d.ts +2 -3
- package/dist/routes/locale-docs-versions.js +1 -1
- package/dist/routes/locale-files-path.d.ts +2 -3
- package/dist/routes/locale-files-path.js +1 -1
- package/dist/routes/locale-index.d.ts +2 -3
- package/dist/routes/locale-index.js +1 -1
- package/dist/routes/mcp.d.ts +5 -0
- package/dist/routes/mcp.js +25 -0
- package/dist/routes/v-docs-slug.d.ts +2 -3
- package/dist/routes/v-locale-docs-slug.d.ts +2 -3
- package/dist/search-widget/index.d.ts +1 -2
- package/dist/search-widget/index.js +4 -7
- package/dist/search-widget-script/generated-script.js +12 -5
- package/dist/settings-defaults.d.ts +2 -0
- package/dist/settings-defaults.js +93 -0
- package/dist/settings.d.ts +8 -2
- package/dist/sidebar/client-data.d.ts +18 -0
- package/dist/sidebar/client-data.js +47 -0
- package/dist/sidebar/index.d.ts +3 -1
- package/dist/sidebar/index.js +3 -1
- package/dist/sidebar/sidebar.d.ts +12 -44
- package/dist/sidebar/sidebar.js +4 -3
- package/dist/sidebar/types.d.ts +14 -0
- package/dist/sidebar-prepaint/index.d.ts +1 -2
- package/dist/sidebar-prepaint/index.js +4 -6
- package/dist/sidebar-resizer/sidebar-resizer-init.d.ts +2 -3
- package/dist/sidebar-resizer/sidebar-resizer-init.js +3 -3
- package/dist/sidebar-toggle-island/index.d.ts +8 -11
- package/dist/sidebar-toggle-island/index.js +75 -62
- package/dist/sidebar-tree/build-tree.js +5 -6
- package/dist/sidebar-tree/types.d.ts +2 -0
- package/dist/sidebar-tree-island/index.d.ts +4 -19
- package/dist/sidebar-tree-island/index.js +782 -436
- package/dist/sidebar-tree-island/scope-state.d.ts +38 -0
- package/dist/sidebar-tree-island/scope-state.js +151 -0
- package/dist/sidebar-tree-island/sidebar-scroll-preserve.js +6 -2
- package/dist/sidebar-utils/index.d.ts +17 -19
- package/dist/sidebar-utils/index.js +100 -3
- package/dist/sidebar-utils/scope.d.ts +11 -0
- package/dist/sidebar-utils/scope.js +67 -0
- package/dist/sidebar-with-defaults/index.d.ts +1 -2
- package/dist/sidebar-with-defaults/index.js +19 -18
- package/dist/site-schema/nav-tree.js +15 -15
- package/dist/site-schema/types.d.ts +1 -0
- package/dist/site-tree-nav/index.d.ts +2 -3
- package/dist/site-tree-nav/index.js +11 -12
- package/dist/site-tree-nav/normalize-island-props.d.ts +16 -0
- package/dist/site-tree-nav/normalize-island-props.js +122 -0
- package/dist/site-tree-nav-island/index.d.ts +3 -3
- package/dist/site-tree-nav-island/index.js +243 -144
- package/dist/smart-break/index.d.ts +3 -4
- package/dist/smart-break/index.js +1 -1
- package/dist/tab-item/tab-item.d.ts +3 -4
- package/dist/tab-item/tab-item.js +1 -1
- package/dist/tag-pages/index.d.ts +3 -3
- package/dist/tag-pages/index.js +10 -10
- package/dist/theme/color-scheme-provider.d.ts +3 -3
- package/dist/theme/color-scheme-provider.js +3 -3
- package/dist/theme/theme-pack-provider.d.ts +1 -1
- package/dist/theme/theme-pack-provider.js +3 -3
- package/dist/theme/theme-toggle.d.ts +2 -3
- package/dist/theme/theme-toggle.js +1 -1
- package/dist/theme-pack-dialog/index.d.ts +1 -1
- package/dist/theme-pack-dialog/index.js +69 -75
- package/dist/theme-pack-dialog/theme-pack-card.d.ts +3 -4
- package/dist/theme-pack-dialog/theme-pack-card.js +19 -17
- package/dist/theme-pack-switcher/index.d.ts +4 -5
- package/dist/theme-pack-switcher/index.js +52 -49
- package/dist/theme-packs/academia/meta.json +1 -1
- package/dist/theme-packs/academia/pack.css +1 -1
- package/dist/theme-packs/bauhaus/meta.json +1 -1
- package/dist/theme-packs/bauhaus/pack.css +2 -2
- package/dist/theme-packs/blueprint/meta.json +1 -1
- package/dist/theme-packs/blueprint/pack.css +2 -2
- package/dist/theme-packs/botanica/meta.json +1 -1
- package/dist/theme-packs/botanica/pack.css +2 -2
- package/dist/theme-packs/broadsheet/meta.json +1 -1
- package/dist/theme-packs/broadsheet/pack.css +2 -2
- package/dist/theme-packs/brutalist/meta.json +1 -1
- package/dist/theme-packs/brutalist/pack.css +2 -2
- package/dist/theme-packs/eink/meta.json +1 -1
- package/dist/theme-packs/eink/pack.css +1 -1
- package/dist/theme-packs/futura-editorial/meta.json +1 -1
- package/dist/theme-packs/futura-editorial/pack.css +2 -2
- package/dist/theme-packs/hearth/meta.json +1 -1
- package/dist/theme-packs/hearth/pack.css +2 -2
- package/dist/theme-packs/ledger/meta.json +1 -1
- package/dist/theme-packs/ledger/pack.css +1 -1
- package/dist/theme-packs/manuscript/meta.json +1 -1
- package/dist/theme-packs/manuscript/pack.css +1 -1
- package/dist/theme-packs/matcha/meta.json +1 -1
- package/dist/theme-packs/matcha/pack.css +2 -2
- package/dist/theme-packs/nocturne/meta.json +1 -1
- package/dist/theme-packs/nocturne/pack.css +2 -2
- package/dist/theme-packs/observatory/meta.json +1 -1
- package/dist/theme-packs/observatory/pack.css +2 -2
- package/dist/theme-packs/onyx/meta.json +1 -1
- package/dist/theme-packs/onyx/pack.css +2 -2
- package/dist/theme-packs/phosphor/meta.json +1 -1
- package/dist/theme-packs/phosphor/pack.css +2 -2
- package/dist/theme-packs/riso/meta.json +1 -1
- package/dist/theme-packs/riso/pack.css +2 -2
- package/dist/theme-packs/sakura/meta.json +1 -1
- package/dist/theme-packs/sakura/pack.css +2 -2
- package/dist/theme-packs/scandi/meta.json +1 -1
- package/dist/theme-packs/scandi/pack.css +1 -1
- package/dist/theme-packs/solar/meta.json +1 -1
- package/dist/theme-packs/solar/pack.css +1 -1
- package/dist/theme-packs/sumi/meta.json +1 -1
- package/dist/theme-packs/sumi/pack.css +2 -2
- package/dist/theme-packs/swissgrid/meta.json +1 -1
- package/dist/theme-packs/swissgrid/pack.css +1 -1
- package/dist/theme-packs/timberline/meta.json +1 -1
- package/dist/theme-packs/timberline/pack.css +2 -2
- package/dist/theme-packs/washi/meta.json +1 -1
- package/dist/theme-packs/washi/pack.css +2 -2
- package/dist/theme-toggle/index.d.ts +1 -1
- package/dist/theme-toggle/index.js +154 -167
- package/dist/theme.css +47 -121
- package/dist/toc/mobile-toc.d.ts +3 -5
- package/dist/toc/mobile-toc.js +29 -27
- package/dist/toc/toc.d.ts +3 -4
- package/dist/toc/toc.js +18 -18
- package/dist/toc/use-active-heading.d.ts +5 -4
- package/dist/toc/use-active-heading.js +36 -30
- package/dist/toc-prepaint/index.d.ts +1 -2
- package/dist/toc-prepaint/index.js +4 -6
- package/dist/transitions/nested-island-props-refresh.d.ts +3 -16
- package/dist/transitions/nested-island-props-refresh.js +133 -151
- package/dist/transitions/page-events.d.ts +8 -13
- package/dist/tree-nav-shared/index.d.ts +4 -5
- package/dist/tree-nav-shared/index.js +6 -7
- package/dist/use-modal-dialog/index.d.ts +9 -63
- package/dist/use-modal-dialog/index.js +41 -59
- package/dist/versions-page/index.d.ts +3 -3
- package/dist/versions-page/index.js +5 -5
- package/dist/wind/index.d.ts +5 -0
- package/dist/wind/index.js +169 -0
- package/dist/wind.json +498 -0
- package/dist/z-index-defaults/index.d.ts +4 -4
- package/dist/zdtp-loader.d.ts +7 -0
- package/dist/zdtp-loader.js +8 -0
- package/eject/asset-components/asset-card.tsx +14 -16
- package/eject/asset-components/asset-code.tsx +10 -12
- package/eject/asset-components/shared.tsx +5 -7
- package/eject/breadcrumb/breadcrumb.tsx +15 -16
- package/eject/code-group/index.tsx +4 -10
- package/eject/content-admonition/index.tsx +5 -6
- package/eject/desktop-sidebar-toggle-island/index.ts +4 -0
- package/eject/desktop-sidebar-toggle-island/island.tsx +50 -0
- package/eject/desktop-sidebar-toggle-island/storage.ts +27 -0
- package/eject/details/details.tsx +3 -5
- package/eject/doc-history/index.tsx +193 -179
- package/eject/doc-pager/index.tsx +3 -4
- package/eject/footer/footer.tsx +7 -9
- package/eject/header/header.tsx +42 -54
- package/eject/header/nav-overflow-script.ts +1 -1
- package/eject/header/types.ts +12 -13
- package/eject/image-enlarge/index.tsx +84 -69
- package/eject/image-enlarge/public.ts +2 -0
- package/eject/image-enlarge/ssr-fallback.tsx +7 -0
- package/eject/page-loading/page-loading-overlay.tsx +8 -15
- package/eject/sidebar/client-data.ts +68 -0
- package/eject/sidebar/index.ts +3 -0
- package/eject/sidebar/sidebar.tsx +16 -97
- package/eject/sidebar/types.ts +15 -0
- package/eject/sidebar-toggle-island/index.tsx +103 -102
- package/eject/sidebar-tree-island/index.tsx +827 -615
- package/eject/sidebar-tree-island/scope-state.ts +154 -0
- package/eject/sidebar-tree-island/sidebar-scroll-preserve.ts +8 -2
- package/eject/site-tree-nav-island/index.tsx +349 -222
- package/eject/tab-item/tab-item.tsx +2 -4
- package/eject/theme-toggle/hydration-pending.ts +6 -10
- package/eject/theme-toggle/index.tsx +133 -173
- package/eject/toc/mobile-toc.tsx +27 -31
- package/eject/toc/toc.tsx +21 -24
- package/eject/toc/use-active-heading.ts +43 -38
- package/package.json +40 -22
- package/routes-src/404.tsx +2 -3
- package/routes-src/_chrome.tsx +7 -2
- package/routes-src/_design-token-panel-bootstrap.tsx +1 -63
- package/routes-src/docs-slug.tsx +2 -3
- package/routes-src/docs-tags-index.tsx +2 -3
- package/routes-src/docs-tags-tag.tsx +2 -3
- package/routes-src/docs-versions.tsx +2 -3
- package/routes-src/files-path.tsx +2 -4
- package/routes-src/index.tsx +2 -3
- package/routes-src/locale-docs-slug.tsx +2 -3
- package/routes-src/locale-docs-tags-index.tsx +2 -3
- package/routes-src/locale-docs-tags-tag.tsx +2 -3
- package/routes-src/locale-docs-versions.tsx +2 -3
- package/routes-src/locale-files-path.tsx +2 -4
- package/routes-src/locale-index.tsx +2 -3
- package/routes-src/mcp.tsx +25 -0
- package/routes-src/v-docs-slug.tsx +2 -3
- package/routes-src/v-locale-docs-slug.tsx +2 -3
- package/tsconfig.base.json +1 -1
- package/dist/safelist.css +0 -2
- package/dist/theme-no-reset.css +0 -379
- package/eject/desktop-sidebar-toggle-island/index.tsx +0 -110
|
@@ -16,7 +16,7 @@ export type ComponentTokenSurface = "content" | "chrome";
|
|
|
16
16
|
* Provides autocomplete when a consumer iterates or references individual tokens.
|
|
17
17
|
* Must be kept in sync with the `cssVar` values in `COMPONENT_TOKENS` below.
|
|
18
18
|
*/
|
|
19
|
-
export type ComponentTokenName = "--zdc-doc-title-font" | "--zdc-doc-title-weight" | "--zdc-doc-title-tracking" | "--zdc-doc-h2-font" | "--zdc-doc-h2-weight" | "--zdc-doc-h2-tracking" | "--zdc-doc-h3-weight" | "--zdc-doc-h4-weight" | "--zdc-doc-prose-font" | "--zdc-doc-link-decoration" | "--zdc-admonition-radius" | "--zdc-admonition-border-width" | "--zdc-card-radius" | "--zdc-content-max-width" | "--zdc-toc-width" | "--zdc-nav-active-indicator-color" | "--zdc-nav-active-weight" | "--zdc-chrome-font" | "--zdc-header-font" | "--zdc-sidebar-font" | "--zdc-toc-font";
|
|
19
|
+
export type ComponentTokenName = "--zdc-doc-title-font" | "--zdc-doc-title-weight" | "--zdc-doc-title-tracking" | "--zdc-doc-h2-font" | "--zdc-doc-h2-weight" | "--zdc-doc-h2-tracking" | "--zdc-doc-h3-weight" | "--zdc-doc-h4-weight" | "--zdc-doc-prose-font" | "--zdc-doc-link-decoration" | "--zdc-admonition-radius" | "--zdc-admonition-border-width" | "--zdc-card-radius" | "--zdc-content-max-width" | "--zdc-toc-width" | "--zdc-nav-active-indicator-color" | "--zdc-nav-active-weight" | "--zdc-chrome-font" | "--zdc-header-font" | "--zdc-header-logo-font" | "--zdc-header-logo-weight" | "--zdc-sidebar-font" | "--zdc-toc-font";
|
|
20
20
|
export interface ComponentToken {
|
|
21
21
|
/**
|
|
22
22
|
* The CSS custom-property name the consumer redefines in `:root`, e.g.
|
|
@@ -337,6 +337,28 @@ const COMPONENT_TOKENS = [
|
|
|
337
337
|
category: "typography",
|
|
338
338
|
description: "Font family of the site header. Defaults to the `--zdc-chrome-font` seam (a no-op until redefined); set in :root to give the header its own face, e.g. a display font for the wordmark and nav. Scoped to the header itself \u2014 it does not leak into the mobile sidebar drawer that the header hosts."
|
|
339
339
|
},
|
|
340
|
+
// Wordmark-only knobs: the anchor selector beats its font-bold utility.
|
|
341
|
+
// Packs with explicit logo typography preserve their own fallbacks.
|
|
342
|
+
{
|
|
343
|
+
cssVar: "--zdc-header-logo-font",
|
|
344
|
+
selector: "a[data-header-logo]",
|
|
345
|
+
property: "font-family",
|
|
346
|
+
default: "inherit",
|
|
347
|
+
component: "header-logo",
|
|
348
|
+
surface: "chrome",
|
|
349
|
+
category: "typography",
|
|
350
|
+
description: "Font family of the site-name anchor only. Defaults to the inherited header font; theme packs retain their existing logo family as fallback. Navigation and header controls keep their own typography."
|
|
351
|
+
},
|
|
352
|
+
{
|
|
353
|
+
cssVar: "--zdc-header-logo-weight",
|
|
354
|
+
selector: "a[data-header-logo]",
|
|
355
|
+
property: "font-weight",
|
|
356
|
+
default: "var(--font-weight-bold)",
|
|
357
|
+
component: "header-logo",
|
|
358
|
+
surface: "chrome",
|
|
359
|
+
category: "typography",
|
|
360
|
+
description: "Font weight of the site-name anchor only. Defaults to --font-weight-bold, matching font-bold; theme packs retain their existing logo weight as fallback."
|
|
361
|
+
},
|
|
340
362
|
{
|
|
341
363
|
cssVar: "--zdc-sidebar-font",
|
|
342
364
|
selector: "#desktop-sidebar, aside[data-zd-mobile-sidebar]",
|
|
@@ -1,4 +1,17 @@
|
|
|
1
1
|
import type { FaviconConfig } from "../settings.js";
|
|
2
|
+
/** Structural subset of Settings used by the agent-export/MCP config guard. */
|
|
3
|
+
export interface AgentDocsConsistentSubject {
|
|
4
|
+
agentExport?: unknown;
|
|
5
|
+
mcp?: unknown;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* Validate the package-owned static agent export and MCP settings.
|
|
9
|
+
*
|
|
10
|
+
* These fields are booleans in the public config type, but JavaScript callers
|
|
11
|
+
* and casted TypeScript values can still pass unsupported values at runtime.
|
|
12
|
+
* MCP also requires the independently opt-in static feed.
|
|
13
|
+
*/
|
|
14
|
+
export declare function assertAgentDocsConsistent(settings: AgentDocsConsistentSubject): void;
|
|
2
15
|
/** Structural subset of a header dropdown read by the category-match guard. */
|
|
3
16
|
export interface AmbiguousDropdownCategoryMatchItem {
|
|
4
17
|
label?: string;
|
|
@@ -1,3 +1,16 @@
|
|
|
1
|
+
function assertAgentDocsConsistent(settings) {
|
|
2
|
+
if (settings.agentExport !== void 0 && typeof settings.agentExport !== "boolean") {
|
|
3
|
+
throw new TypeError("agentExport must be a boolean.");
|
|
4
|
+
}
|
|
5
|
+
if (settings.mcp !== void 0 && typeof settings.mcp !== "boolean") {
|
|
6
|
+
throw new TypeError("mcp must be a boolean.");
|
|
7
|
+
}
|
|
8
|
+
if (settings.mcp === true && settings.agentExport !== true) {
|
|
9
|
+
throw new TypeError(
|
|
10
|
+
"MCP requires agentExport: true. Remove the explicit agent export disable or disable MCP."
|
|
11
|
+
);
|
|
12
|
+
}
|
|
13
|
+
}
|
|
1
14
|
function assertNoEmptyStringFaviconOrLogo(settings) {
|
|
2
15
|
if (settings.logo === "") {
|
|
3
16
|
throw new TypeError(
|
|
@@ -77,6 +90,7 @@ function warnAmbiguousDropdownCategoryMatch(headerNav, logger = console) {
|
|
|
77
90
|
}
|
|
78
91
|
}
|
|
79
92
|
export {
|
|
93
|
+
assertAgentDocsConsistent,
|
|
80
94
|
assertNoEmptyStringFaviconOrLogo,
|
|
81
95
|
assertValidSearchMaxBodyLength,
|
|
82
96
|
assertZdtpBundlingConsistent,
|
package/dist/config.d.ts
CHANGED
|
@@ -15,8 +15,9 @@
|
|
|
15
15
|
* }));
|
|
16
16
|
* ```
|
|
17
17
|
*
|
|
18
|
-
* `zudoDoc()` SHALLOW-merges the user's fields over
|
|
19
|
-
* top-level fields only
|
|
18
|
+
* `zudoDoc()` SHALLOW-merges the user's serializable settings fields over
|
|
19
|
+
* {@link DEFAULT_SETTINGS} — top-level fields only
|
|
20
|
+
* (`{ ...DEFAULT_SETTINGS, ...settingsOverrides }`). A supplied nested
|
|
20
21
|
* object (e.g. `colorMode`, `metaTags`) REPLACES the default wholesale; it is
|
|
21
22
|
* NOT deep-merged key-by-key. Nested config types that intentionally expose
|
|
22
23
|
* optional keys (such as `FrontmatterPreviewConfig` and
|
|
@@ -31,12 +32,12 @@
|
|
|
31
32
|
* host spreads nothing.
|
|
32
33
|
*
|
|
33
34
|
* ──────────────────────────────────────────────────────────────────────────
|
|
34
|
-
* COMPOSITION MECHANISM (locked, #2653
|
|
35
|
-
* `
|
|
36
|
-
*
|
|
37
|
-
*
|
|
38
|
-
*
|
|
39
|
-
*
|
|
35
|
+
* COMPOSITION MECHANISM (locked, #2653; wind exception locked by #4480):
|
|
36
|
+
* `zudoDoc()` builds the full `ZfbConfig` in JS. `zudoDocPreset()` stays the
|
|
37
|
+
* fragment builder for collections/plugins/markdown. Package wind defaults
|
|
38
|
+
* use one zfb-native `presets` entry so zfb can deep-merge a user's top-level
|
|
39
|
+
* `wind` override over the package fragment. No other config surface is
|
|
40
|
+
* delegated to native presets.
|
|
40
41
|
*
|
|
41
42
|
* ──────────────────────────────────────────────────────────────────────────
|
|
42
43
|
* NODE-BUILTIN-FREE EVAL GRAPH (non-negotiable — guarded by a unit test)
|
|
@@ -45,10 +46,11 @@
|
|
|
45
46
|
* (mirrors zfb's `loader.rs:277`); a transitive `node:*` import fails the load.
|
|
46
47
|
* `zudoDoc()` is the new central node in that eval graph — it transitively pulls
|
|
47
48
|
* in `preset.ts` plus every #2654 default module — so this module and all of
|
|
48
|
-
* them MUST stay free of `node:*` builtins.
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
*
|
|
49
|
+
* them MUST stay free of `node:*` builtins. Runtime dependencies on this path
|
|
50
|
+
* are `zod` and zfb's `definePreset` helper (used by `wind/index.ts`); both
|
|
51
|
+
* are required peers with node-free config entry points. The `ZfbConfig`,
|
|
52
|
+
* `BundleConfig`, and `WindConfig` imports from `@takazudo/zfb/config` here are
|
|
53
|
+
* **type-only** (erased before esbuild resolution). The guard lives in
|
|
52
54
|
* `src/__tests__/foundation-eval-graph.test.ts` (`config.ts` is in
|
|
53
55
|
* `NODE_FREE_MODULES`).
|
|
54
56
|
*
|
|
@@ -56,14 +58,15 @@
|
|
|
56
58
|
* SERIALIZABILITY SPLIT
|
|
57
59
|
* ──────────────────────────────────────────────────────────────────────────
|
|
58
60
|
* The non-serializable / data overrides (`buildDocsSchema` fn, `colorSchemes`,
|
|
59
|
-
* `translations`, `directives`, `tagVocabularyEntries`) and
|
|
60
|
-
* (`port`/`adapter`/`bundle`) are peeled
|
|
61
|
+
* `translations`, `directives`, `tagVocabularyEntries`) and config passthrough
|
|
62
|
+
* fields (`port`/`adapter`/`bundle`/`wind`/`strictContentBridge`) are peeled
|
|
63
|
+
* off `user` up front so they never leak
|
|
61
64
|
* into the merged `settings` object — only clean, JSON-serializable settings
|
|
62
65
|
* ride into the routes plugin's virtual-module payload (exactly as
|
|
63
66
|
* `zudoDocPreset()` does today). The function-valued/data overrides travel the
|
|
64
67
|
* import-graph side (passed as `zudoDocPreset()` arguments, not serialized).
|
|
65
68
|
*/
|
|
66
|
-
import type { ZfbConfig, BundleConfig } from "@takazudo/zfb/config";
|
|
69
|
+
import type { ZfbConfig, BundleConfig, WindConfig } from "@takazudo/zfb/config";
|
|
67
70
|
import type { ZodType } from "zod";
|
|
68
71
|
import type { DirectiveVocabulary, PresetTranslations, PresetTagVocabularyEntry } from "./preset.js";
|
|
69
72
|
import type { ColorScheme } from "./color-scheme-utils.js";
|
|
@@ -80,7 +83,7 @@ type CodexResourcesConfig = {
|
|
|
80
83
|
projectRoot?: string;
|
|
81
84
|
scanRoot?: string;
|
|
82
85
|
} | false;
|
|
83
|
-
export
|
|
86
|
+
export { DEFAULT_SETTINGS } from "./settings-defaults.js";
|
|
84
87
|
export interface ZudoDocConfig {
|
|
85
88
|
/**
|
|
86
89
|
* Active color scheme name (must exist in `colorSchemes`).
|
|
@@ -291,6 +294,16 @@ export interface ZudoDocConfig {
|
|
|
291
294
|
* @default false
|
|
292
295
|
*/
|
|
293
296
|
llmsTxt?: boolean;
|
|
297
|
+
/**
|
|
298
|
+
* Generate the package-owned static agent documentation feed.
|
|
299
|
+
* @default false
|
|
300
|
+
*/
|
|
301
|
+
agentExport?: boolean;
|
|
302
|
+
/**
|
|
303
|
+
* Enable the stateless read-only MCP endpoint. Requires `agentExport: true`.
|
|
304
|
+
* @default false
|
|
305
|
+
*/
|
|
306
|
+
mcp?: boolean;
|
|
294
307
|
/**
|
|
295
308
|
* Changelog generation config(s), or `false` to disable.
|
|
296
309
|
* @default false
|
|
@@ -606,6 +619,13 @@ export interface ZudoDocConfig {
|
|
|
606
619
|
* @default undefined
|
|
607
620
|
*/
|
|
608
621
|
bundle?: BundleConfig;
|
|
622
|
+
/**
|
|
623
|
+
* zudo-wind configuration override. Package defaults are supplied through
|
|
624
|
+
* a zfb preset and zfb recursively merges this user value over them; `false`
|
|
625
|
+
* disables wind generation.
|
|
626
|
+
* @default undefined (the zudo-doc preset defaults apply)
|
|
627
|
+
*/
|
|
628
|
+
wind?: WindConfig | false;
|
|
609
629
|
/**
|
|
610
630
|
* Build-only gate that fails `zfb build` when a collection entry falls
|
|
611
631
|
* back to `<pre data-zfb-content-fallback>` (mirrors zfb's
|
|
@@ -628,4 +648,3 @@ export interface ZudoDocConfig {
|
|
|
628
648
|
* `defineConfig`.
|
|
629
649
|
*/
|
|
630
650
|
export declare function zudoDoc(user?: ZudoDocConfig): ZfbConfig;
|
|
631
|
-
export {};
|
package/dist/config.js
CHANGED
|
@@ -7,7 +7,8 @@ import { assertNoCommaInVersionSlugs } from "./version-availability/index.js";
|
|
|
7
7
|
import {
|
|
8
8
|
assertNoEmptyStringFaviconOrLogo,
|
|
9
9
|
assertZdtpBundlingConsistent,
|
|
10
|
-
assertValidSearchMaxBodyLength
|
|
10
|
+
assertValidSearchMaxBodyLength,
|
|
11
|
+
assertAgentDocsConsistent
|
|
11
12
|
} from "./config-assertions/index.js";
|
|
12
13
|
import { validateAssetViewerSettings } from "./asset-path/index.js";
|
|
13
14
|
function mergeDefaultTranslations(overrides) {
|
|
@@ -35,94 +36,18 @@ function assertValidAssetViewerSettings(dir, routePrefix) {
|
|
|
35
36
|
);
|
|
36
37
|
}
|
|
37
38
|
}
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
base: "/",
|
|
51
|
-
trailingSlash: false,
|
|
52
|
-
home: { wide: false, introMarkdown: "", sitemapHeading: "" },
|
|
53
|
-
siteTreeNavIgnore: [],
|
|
54
|
-
siteTreeNavSecondary: [],
|
|
55
|
-
minifyHtml: true,
|
|
56
|
-
docsDir: "src/content/docs",
|
|
57
|
-
entryDocSlug: "getting-started",
|
|
58
|
-
dateFormat: "locale",
|
|
59
|
-
defaultLocale: "en",
|
|
60
|
-
locales: {},
|
|
61
|
-
mermaid: true,
|
|
62
|
-
transclude: false,
|
|
63
|
-
noindex: false,
|
|
64
|
-
editUrl: false,
|
|
65
|
-
githubUrl: false,
|
|
66
|
-
siteUrl: "",
|
|
67
|
-
metaTags: {
|
|
68
|
-
description: true,
|
|
69
|
-
keywords: false,
|
|
70
|
-
ogImage: false,
|
|
71
|
-
ogSiteName: true,
|
|
72
|
-
twitterCard: false
|
|
73
|
-
},
|
|
74
|
-
sitemap: false,
|
|
75
|
-
docMetainfo: false,
|
|
76
|
-
docMetainfoFields: ["created", "updated", "author"],
|
|
77
|
-
docTags: false,
|
|
78
|
-
tagPlacement: "after-title",
|
|
79
|
-
tagGovernance: "off",
|
|
80
|
-
tagVocabulary: false,
|
|
81
|
-
llmsTxt: false,
|
|
82
|
-
changelogs: false,
|
|
83
|
-
math: false,
|
|
84
|
-
cjkFriendly: false,
|
|
85
|
-
onBrokenMarkdownLinks: "warn",
|
|
86
|
-
aiAssistant: false,
|
|
87
|
-
aiChatDemoMode: false,
|
|
88
|
-
aiChatAllowedOrigins: [],
|
|
89
|
-
// Exact UTC-day paid-call admission cap; false disables it. An admission is
|
|
90
|
-
// consumed before provider fetch and is not provider-confirmed accounting.
|
|
91
|
-
aiChatGlobalDailyLimit: false,
|
|
92
|
-
designTokenPanel: false,
|
|
93
|
-
tocMinDepth: 2,
|
|
94
|
-
tocMaxDepth: 4,
|
|
95
|
-
searchMaxBodyLength: 3e3,
|
|
96
|
-
sidebarResizer: false,
|
|
97
|
-
sidebarToggle: false,
|
|
98
|
-
tocToggle: false,
|
|
99
|
-
imageEnlarge: false,
|
|
100
|
-
findInPage: false,
|
|
101
|
-
dynamicPageTransition: false,
|
|
102
|
-
frontmatterPreview: false,
|
|
103
|
-
docHistory: false,
|
|
104
|
-
docHistoryUi: true,
|
|
105
|
-
docHistoryExclude: [],
|
|
106
|
-
assetViewer: false,
|
|
107
|
-
assetViewerDir: "assets",
|
|
108
|
-
assetViewerRoutePrefix: "files",
|
|
109
|
-
assetViewerExclude: [],
|
|
110
|
-
assetViewerIndex: false,
|
|
111
|
-
assetViewerIndexing: false,
|
|
112
|
-
bodyFootUtilArea: false,
|
|
113
|
-
htmlPreview: void 0,
|
|
114
|
-
versions: false,
|
|
115
|
-
claudeResources: false,
|
|
116
|
-
codexResources: false,
|
|
117
|
-
defaultLocaleOnlyPrefixes: [],
|
|
118
|
-
footer: false,
|
|
119
|
-
headerNav: [],
|
|
120
|
-
headerRightItems: [{ type: "component", component: "theme-toggle" }],
|
|
121
|
-
packageOwnedRoutes: true,
|
|
122
|
-
themePack: "default",
|
|
123
|
-
themePackSwitcher: false,
|
|
124
|
-
themePacks: void 0
|
|
125
|
-
};
|
|
39
|
+
function withMcpMainFields(bundle, presetBundle) {
|
|
40
|
+
const mainFields = [...bundle?.mainFields ?? presetBundle?.mainFields ?? []];
|
|
41
|
+
if (!mainFields.includes("module")) mainFields.push("module");
|
|
42
|
+
if (!mainFields.includes("main")) mainFields.push("main");
|
|
43
|
+
return {
|
|
44
|
+
...presetBundle,
|
|
45
|
+
...bundle,
|
|
46
|
+
mainFields
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
import { DEFAULT_SETTINGS } from "./settings-defaults.js";
|
|
50
|
+
import { DEFAULT_SETTINGS as DEFAULT_SETTINGS2 } from "./settings-defaults.js";
|
|
126
51
|
function zudoDoc(user = {}) {
|
|
127
52
|
if ("headingIdStrategy" in user) {
|
|
128
53
|
throw new TypeError(
|
|
@@ -138,6 +63,7 @@ function zudoDoc(user = {}) {
|
|
|
138
63
|
port,
|
|
139
64
|
adapter,
|
|
140
65
|
bundle,
|
|
66
|
+
wind,
|
|
141
67
|
strictContentBridge,
|
|
142
68
|
buildDocsSchema: userBuildDocsSchema,
|
|
143
69
|
colorSchemes: userColorSchemes,
|
|
@@ -146,7 +72,7 @@ function zudoDoc(user = {}) {
|
|
|
146
72
|
tagVocabularyEntries: userTagVocabularyEntries,
|
|
147
73
|
...settingsOverrides
|
|
148
74
|
} = user;
|
|
149
|
-
const settings = { ...
|
|
75
|
+
const settings = { ...DEFAULT_SETTINGS2, ...settingsOverrides };
|
|
150
76
|
assertValidAssetViewerSettings(
|
|
151
77
|
settings.assetViewerDir,
|
|
152
78
|
settings.assetViewerRoutePrefix
|
|
@@ -155,6 +81,7 @@ function zudoDoc(user = {}) {
|
|
|
155
81
|
assertNoEmptyStringFaviconOrLogo(settings);
|
|
156
82
|
assertZdtpBundlingConsistent(settings);
|
|
157
83
|
assertValidSearchMaxBodyLength(settings.searchMaxBodyLength);
|
|
84
|
+
assertAgentDocsConsistent(settings);
|
|
158
85
|
const fragment = zudoDocPreset({
|
|
159
86
|
settings,
|
|
160
87
|
buildDocsSchema: userBuildDocsSchema ?? (() => defaultBuildDocsSchema({
|
|
@@ -166,24 +93,25 @@ function zudoDoc(user = {}) {
|
|
|
166
93
|
colorSchemes: userColorSchemes ?? defaultColorSchemes,
|
|
167
94
|
tagVocabulary: userTagVocabularyEntries ?? []
|
|
168
95
|
});
|
|
96
|
+
const { bundle: presetBundle, ...presetConfig } = fragment;
|
|
97
|
+
const resolvedBundle = settings.mcp === true ? withMcpMainFields(bundle, presetBundle) : bundle;
|
|
169
98
|
return {
|
|
170
99
|
// ── Host-owned shell fields ──────────────────────────────────────────
|
|
171
|
-
framework: "preact",
|
|
172
100
|
port: port ?? 4321,
|
|
173
|
-
tailwind: { enabled: true },
|
|
174
101
|
base: settings.base,
|
|
175
102
|
...adapter ? { adapter } : {},
|
|
176
|
-
...
|
|
103
|
+
...resolvedBundle ? { bundle: resolvedBundle } : {},
|
|
104
|
+
...wind !== void 0 ? { wind } : {},
|
|
177
105
|
...strictContentBridge !== void 0 ? { strictContentBridge } : {},
|
|
178
106
|
// ── Preset-owned fields (collections, plugins, markdown, …) ──────────
|
|
179
|
-
...
|
|
107
|
+
...presetConfig,
|
|
180
108
|
// The preset's `markdown.features` intentionally uses the loose Record
|
|
181
109
|
// shape (the exact shape zfb's config shim binds against); the engine's
|
|
182
110
|
// strict `MarkdownFeaturesConfig` is a structural subset of it. Every
|
|
183
111
|
// other preset field type-checks against `ZfbConfig` directly, so only
|
|
184
112
|
// `markdown` needs this single documented bridge — `satisfies ZfbConfig`
|
|
185
113
|
// below keeps full strict checking on all the rest.
|
|
186
|
-
markdown:
|
|
114
|
+
markdown: presetConfig.markdown
|
|
187
115
|
};
|
|
188
116
|
}
|
|
189
117
|
export {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/** @jsxRuntime automatic */
|
|
2
|
-
|
|
3
|
-
import type { JSX } from "preact";
|
|
2
|
+
import type { JSX } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
4
3
|
type Props = JSX.IntrinsicElements["blockquote"];
|
|
5
|
-
export declare function ContentBlockquote({ children,
|
|
4
|
+
export declare function ContentBlockquote({ children, class: klass, ...rest }: Props): import("@takazudo/zfb").Description;
|
|
6
5
|
export {};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { jsx } from "
|
|
2
|
-
function ContentBlockquote({ children,
|
|
1
|
+
import { jsx } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
2
|
+
function ContentBlockquote({ children, class: klass, ...rest }) {
|
|
3
3
|
return /* @__PURE__ */ jsx(
|
|
4
4
|
"blockquote",
|
|
5
5
|
{
|
|
6
|
-
|
|
6
|
+
class: `border-l-[3px] border-muted pl-hsp-lg text-muted italic${klass ? ` ${klass}` : ""}`,
|
|
7
7
|
...rest,
|
|
8
8
|
children
|
|
9
9
|
}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/** @jsxRuntime automatic */
|
|
2
|
-
|
|
3
|
-
import type { JSX } from "preact";
|
|
2
|
+
import type { JSX } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
4
3
|
type Props = JSX.IntrinsicElements["code"];
|
|
5
4
|
/**
|
|
6
5
|
* Override for inline `<code>` in MDX. Wraps text-only inline code with
|
|
@@ -12,10 +11,10 @@ type Props = JSX.IntrinsicElements["code"];
|
|
|
12
11
|
* nodes (not a plain string). We detect those and render untouched so
|
|
13
12
|
* syntax highlighting is never disturbed.
|
|
14
13
|
*
|
|
15
|
-
*
|
|
14
|
+
* Legacy MDX may pass pure-text children wrapped in a `StaticHtml`
|
|
16
15
|
* component whose text lives in `props.value`, not as a string child.
|
|
17
16
|
* `extractText` unwraps that so the heuristic works regardless of MDX's
|
|
18
17
|
* internal wrapping.
|
|
19
18
|
*/
|
|
20
|
-
export declare function ContentCode({ children,
|
|
19
|
+
export declare function ContentCode({ children, class: klass, ...rest }: Props): import("@takazudo/zfb").Description;
|
|
21
20
|
export {};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { jsx } from "
|
|
1
|
+
import { jsx } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
2
2
|
import { SmartBreak as SmartBreakImpl } from "../smart-break/index.js";
|
|
3
3
|
const SmartBreak = SmartBreakImpl;
|
|
4
|
-
function ContentCode({ children,
|
|
5
|
-
const isShikiBlock = typeof
|
|
4
|
+
function ContentCode({ children, class: klass, ...rest }) {
|
|
5
|
+
const isShikiBlock = typeof klass === "string" && /(^|\s)language-/.test(klass);
|
|
6
6
|
const textFromChildren = isShikiBlock ? null : extractText(children);
|
|
7
7
|
if (textFromChildren === null) {
|
|
8
|
-
return /* @__PURE__ */ jsx("code", {
|
|
8
|
+
return /* @__PURE__ */ jsx("code", { class: klass, ...rest, children });
|
|
9
9
|
}
|
|
10
|
-
return /* @__PURE__ */ jsx("code", {
|
|
10
|
+
return /* @__PURE__ */ jsx("code", { class: klass, ...rest, children: /* @__PURE__ */ jsx(SmartBreak, { children: textFromChildren }) });
|
|
11
11
|
}
|
|
12
12
|
function extractText(children) {
|
|
13
13
|
if (typeof children === "string") return children;
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
/** @jsxRuntime automatic */
|
|
2
|
-
|
|
3
|
-
import type { JSX } from "preact";
|
|
2
|
+
import type { JSX } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
4
3
|
import type { AssetManifest } from "../route-context-payload/types.js";
|
|
5
4
|
type Props = JSX.IntrinsicElements["a"];
|
|
6
|
-
export declare function ContentLink({ href,
|
|
5
|
+
export declare function ContentLink({ href, class: klass, children, ...rest }: Props): import("@takazudo/zfb").Description;
|
|
7
6
|
export interface CreateContentLinkOptions {
|
|
8
7
|
base: string;
|
|
9
8
|
assetManifest: AssetManifest | null;
|
|
@@ -18,5 +17,5 @@ export interface CreateContentLinkOptions {
|
|
|
18
17
|
* Bind ContentLink to an asset manifest. Only exact manifest entries are
|
|
19
18
|
* decorated and redirected; every other anchor follows ContentLink verbatim.
|
|
20
19
|
*/
|
|
21
|
-
export declare function createContentLink({ base, assetManifest, routePrefix, dir, locale, isDefaultLocaleOnlyPath, }: CreateContentLinkOptions): (props: Props) =>
|
|
20
|
+
export declare function createContentLink({ base, assetManifest, routePrefix, dir, locale, isDefaultLocaleOnlyPath, }: CreateContentLinkOptions): (props: Props) => import("@takazudo/zfb").Description;
|
|
22
21
|
export {};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { jsx, jsxs } from "
|
|
1
|
+
import { jsx, jsxs } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
2
2
|
import { SmartBreak as SmartBreakBase } from "../smart-break/index.js";
|
|
3
3
|
import { decodeAuthoredHref, assetViewerHref } from "../asset-path/index.js";
|
|
4
4
|
import { AssetFileIcon, formatAssetBytes } from "../asset-components/index.js";
|
|
5
5
|
const SmartBreak = SmartBreakBase;
|
|
6
|
-
function ContentLink({ href,
|
|
7
|
-
const classes = typeof
|
|
6
|
+
function ContentLink({ href, class: klass, children, ...rest }) {
|
|
7
|
+
const classes = typeof klass === "string" ? klass.split(" ") : [];
|
|
8
8
|
if (classes.includes("block") || classes.includes("hash-link")) {
|
|
9
|
-
return /* @__PURE__ */ jsx("a", { href,
|
|
9
|
+
return /* @__PURE__ */ jsx("a", { href, class: klass, ...rest, children });
|
|
10
10
|
}
|
|
11
11
|
const textFromChildren = extractText(children);
|
|
12
12
|
const content = textFromChildren !== null ? /* @__PURE__ */ jsx(SmartBreak, { children: textFromChildren }) : children;
|
|
@@ -14,7 +14,7 @@ function ContentLink({ href, className, children, ...rest }) {
|
|
|
14
14
|
"a",
|
|
15
15
|
{
|
|
16
16
|
href,
|
|
17
|
-
|
|
17
|
+
class: `text-accent underline hover:text-accent-hover${klass ? ` ${klass}` : ""}`,
|
|
18
18
|
...rest,
|
|
19
19
|
children: content
|
|
20
20
|
}
|
|
@@ -29,8 +29,8 @@ function createContentLink({
|
|
|
29
29
|
isDefaultLocaleOnlyPath
|
|
30
30
|
}) {
|
|
31
31
|
return function ManifestAwareContentLink(props) {
|
|
32
|
-
const { href,
|
|
33
|
-
const classes = typeof
|
|
32
|
+
const { href, class: klass, children } = props;
|
|
33
|
+
const classes = typeof klass === "string" ? klass.split(" ") : [];
|
|
34
34
|
if (assetManifest === null || typeof href !== "string" || href.startsWith("#") || classes.includes("block") || classes.includes("hash-link")) {
|
|
35
35
|
return /* @__PURE__ */ jsx(ContentLink, { ...props });
|
|
36
36
|
}
|
|
@@ -48,10 +48,10 @@ function createContentLink({
|
|
|
48
48
|
locale: isDefaultLocaleOnlyPath?.(`/${routePrefix}/${entry.path}`) ? void 0 : locale,
|
|
49
49
|
fragment: decoded.fragment
|
|
50
50
|
}),
|
|
51
|
-
children: /* @__PURE__ */ jsxs("span", {
|
|
52
|
-
/* @__PURE__ */ jsx(AssetFileIcon, {
|
|
51
|
+
children: /* @__PURE__ */ jsxs("span", { class: "inline-flex items-baseline gap-x-hsp-xs font-mono", children: [
|
|
52
|
+
/* @__PURE__ */ jsx(AssetFileIcon, { class: "h-icon-sm w-icon-sm shrink-0" }),
|
|
53
53
|
/* @__PURE__ */ jsx("span", { children }),
|
|
54
|
-
/* @__PURE__ */ jsxs("span", {
|
|
54
|
+
/* @__PURE__ */ jsxs("span", { class: "text-caption text-muted", children: [
|
|
55
55
|
"(",
|
|
56
56
|
formatAssetBytes(entry.bytes),
|
|
57
57
|
")"
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/** @jsxRuntime automatic */
|
|
2
|
-
|
|
3
|
-
import type { JSX } from "preact";
|
|
2
|
+
import type { JSX } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
4
3
|
type Props = JSX.IntrinsicElements["ol"];
|
|
5
|
-
export declare function ContentOl({ children,
|
|
4
|
+
export declare function ContentOl({ children, class: klass, start, ...rest }: Props): import("@takazudo/zfb").Description;
|
|
6
5
|
export {};
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { jsx } from "
|
|
2
|
-
function ContentOl({ children,
|
|
1
|
+
import { jsx } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
2
|
+
function ContentOl({ children, class: klass, start, ...rest }) {
|
|
3
3
|
return /* @__PURE__ */ jsx(
|
|
4
4
|
"ol",
|
|
5
5
|
{
|
|
6
6
|
...rest,
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
start,
|
|
8
|
+
class: klass || void 0,
|
|
9
|
+
style: { "padding-left": "2em", "list-style-type": "decimal" },
|
|
9
10
|
children
|
|
10
11
|
}
|
|
11
12
|
);
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/** @jsxRuntime automatic */
|
|
2
|
-
|
|
3
|
-
import type { JSX } from "preact";
|
|
2
|
+
import type { JSX } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
4
3
|
type Props = JSX.IntrinsicElements["p"];
|
|
5
|
-
export declare function ContentParagraph({ children, ...rest }: Props):
|
|
4
|
+
export declare function ContentParagraph({ children, ...rest }: Props): import("@takazudo/zfb").Description;
|
|
6
5
|
export {};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/** @jsxRuntime automatic */
|
|
2
|
-
|
|
3
|
-
import type { JSX } from "preact";
|
|
2
|
+
import type { JSX } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
4
3
|
type Props = JSX.IntrinsicElements["strong"];
|
|
5
|
-
export declare function ContentStrong({ children,
|
|
4
|
+
export declare function ContentStrong({ children, class: klass, ...rest }: Props): import("@takazudo/zfb").Description;
|
|
6
5
|
export {};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { jsx } from "
|
|
2
|
-
function ContentStrong({ children,
|
|
1
|
+
import { jsx } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
2
|
+
function ContentStrong({ children, class: klass, ...rest }) {
|
|
3
3
|
return /* @__PURE__ */ jsx(
|
|
4
4
|
"strong",
|
|
5
5
|
{
|
|
6
|
-
|
|
6
|
+
class: `font-bold text-fg${klass ? ` ${klass}` : ""}`,
|
|
7
7
|
...rest,
|
|
8
8
|
children
|
|
9
9
|
}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/** @jsxRuntime automatic */
|
|
2
|
-
|
|
3
|
-
import type { JSX } from "preact";
|
|
2
|
+
import type { JSX } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
4
3
|
type Props = JSX.IntrinsicElements["table"];
|
|
5
|
-
export declare function ContentTable({ children,
|
|
4
|
+
export declare function ContentTable({ children, class: klass, ...rest }: Props): import("@takazudo/zfb").Description;
|
|
6
5
|
export {};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { jsx } from "
|
|
2
|
-
function ContentTable({ children,
|
|
3
|
-
return /* @__PURE__ */ jsx("div", {
|
|
1
|
+
import { jsx } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
2
|
+
function ContentTable({ children, class: klass, ...rest }) {
|
|
3
|
+
return /* @__PURE__ */ jsx("div", { class: "overflow-x-auto", children: /* @__PURE__ */ jsx(
|
|
4
4
|
"table",
|
|
5
5
|
{
|
|
6
|
-
|
|
6
|
+
class: `w-full border-collapse text-small${klass ? ` ${klass}` : ""}`,
|
|
7
7
|
...rest,
|
|
8
8
|
children
|
|
9
9
|
}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/** @jsxRuntime automatic */
|
|
2
|
-
|
|
3
|
-
import type { JSX } from "preact";
|
|
2
|
+
import type { JSX } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
4
3
|
type Props = JSX.IntrinsicElements["ul"];
|
|
5
|
-
export declare function ContentUl({ children,
|
|
4
|
+
export declare function ContentUl({ children, class: klass, ...rest }: Props): import("@takazudo/zfb").Description;
|
|
6
5
|
export {};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { jsx } from "
|
|
2
|
-
function ContentUl({ children,
|
|
1
|
+
import { jsx } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
2
|
+
function ContentUl({ children, class: klass, ...rest }) {
|
|
3
3
|
return /* @__PURE__ */ jsx(
|
|
4
4
|
"ul",
|
|
5
5
|
{
|
|
6
6
|
...rest,
|
|
7
|
-
|
|
8
|
-
style: {
|
|
7
|
+
class: klass || void 0,
|
|
8
|
+
style: { "padding-left": "2em", "list-style-type": "disc" },
|
|
9
9
|
children
|
|
10
10
|
}
|
|
11
11
|
);
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/** @jsxRuntime automatic */
|
|
2
|
-
|
|
3
|
-
import type { JSX } from "preact";
|
|
2
|
+
import type { JSX } from "@takazudo/zfb/zudo-react/jsx-runtime";
|
|
4
3
|
type Props = JSX.IntrinsicElements["h2"];
|
|
5
|
-
export declare function HeadingH2({ id, children,
|
|
4
|
+
export declare function HeadingH2({ id, children, class: klass, ...rest }: Props): import("@takazudo/zfb").Description;
|
|
6
5
|
export {};
|