boltdocs 2.8.2 → 2.8.4

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.
Files changed (51) hide show
  1. package/dist/{banner-3N4Jd_L9.d.ts → banner-BLTQUA2O.d.ts} +1 -1
  2. package/dist/{banner-MynZD_Ox.d.cts → banner-DFACg5Dy.d.cts} +1 -1
  3. package/dist/client/index.cjs +39 -19
  4. package/dist/client/index.d.cts +2 -2
  5. package/dist/client/index.d.ts +2 -2
  6. package/dist/client/index.js +39 -19
  7. package/dist/client/mdx.cjs +1 -1
  8. package/dist/client/mdx.js +1 -1
  9. package/dist/client/primitives.cjs +4 -4
  10. package/dist/client/primitives.d.cts +1 -1
  11. package/dist/client/primitives.d.ts +1 -1
  12. package/dist/client/primitives.js +4 -4
  13. package/dist/{docs-layout-Dn6S5g59.js → docs-layout-BBv6wILp.js} +82 -92
  14. package/dist/{docs-layout-CwCq42Zt.cjs → docs-layout-CVCf3xkZ.cjs} +82 -92
  15. package/dist/{doctor-aN_leTbh.mjs → doctor-BGPdO1Ah.mjs} +1 -1
  16. package/dist/{doctor-DyNUVe96.cjs → doctor-DT4jh07O.cjs} +1 -1
  17. package/dist/doctor-Dnv77Lfx.mjs +28 -0
  18. package/dist/doctor-VBPlQf7d.cjs +28 -0
  19. package/dist/{icons-dev-DvJ-hh9x.cjs → icons-dev-C8sFxeBk.cjs} +6 -3
  20. package/dist/{icons-dev-Oju24Wjp.js → icons-dev-CFcv5Nb8.js} +6 -3
  21. package/dist/{image-Ch4-GxdO.cjs → image-DCMxxidi.cjs} +9 -3
  22. package/dist/{image-Do8V9PCW.js → image-DufDOid8.js} +9 -3
  23. package/dist/{mdx-BGM7LjW5.cjs → mdx-BH9kHiF9.cjs} +2 -2
  24. package/dist/{mdx-5oeCOFhH.js → mdx-Bto8CvGl.js} +2 -2
  25. package/dist/node/cli-entry.cjs +2 -2
  26. package/dist/node/cli-entry.mjs +3 -3
  27. package/dist/node/index.cjs +1 -1
  28. package/dist/node/index.mjs +1 -1
  29. package/dist/node/routes/worker.mjs +1 -1
  30. package/dist/{node-BfGSXyUz.cjs → node-JM9bx0mO.cjs} +5 -4
  31. package/dist/{node-NZrBn5jg.mjs → node-q-Y2mdLX.mjs} +5 -4
  32. package/dist/{package-DBz4CSnw.cjs → package-CwNjt3Sd.cjs} +1 -1
  33. package/dist/{package-C1qrHXzn.mjs → package-DlgexgpQ.mjs} +1 -1
  34. package/dist/{parser-BrkFi6YE.mjs → parser-9LqyiEnB.mjs} +1 -1
  35. package/dist/{routes-DJNJ-rTt.cjs → routes-3sAccArX.cjs} +1 -1
  36. package/dist/{routes-f9J1MQRr.mjs → routes-DZpXqq1p.mjs} +1 -1
  37. package/dist/{routes-CtQzxiZg.mjs → routes-DjoxNeef.mjs} +1 -1
  38. package/dist/{routes-DiYC4nD2.cjs → routes-DpJnb2VS.cjs} +1 -1
  39. package/dist/{search-dialog-BYhOov4S.cjs → search-dialog-CmHYOt18.cjs} +2 -2
  40. package/dist/{search-dialog-CUeAfy-8.cjs → search-dialog-Cr7SC8Xt.cjs} +1 -1
  41. package/dist/{search-dialog-BXVoecTx.cjs → search-dialog-Cvux-qSk.cjs} +1 -1
  42. package/dist/{search-dialog-DHc_8FFX.js → search-dialog-DBNaG5At.js} +1 -1
  43. package/dist/{search-dialog-D8gLkhUV.js → search-dialog-e86WPpck.js} +1 -1
  44. package/dist/{search-dialog-C09riYmx.js → search-dialog-jHZ21G4i.js} +2 -2
  45. package/dist/{sidebar-Dlkgbxs6.d.cts → sidebar---RgTmZD.d.cts} +2 -0
  46. package/dist/{sidebar-DNq4_ZAa.d.ts → sidebar-kQBonN82.d.ts} +2 -0
  47. package/dist/{worker-pool-CtqklOXq.cjs → worker-pool-DXLyeHJg.cjs} +1 -1
  48. package/dist/{worker-pool-k0DY6k8T.mjs → worker-pool-Kn4F9gDq.mjs} +1 -1
  49. package/package.json +2 -1
  50. package/dist/doctor-BArviV8X.cjs +0 -28
  51. package/dist/doctor-CgLA7_Uv.mjs +0 -28
@@ -1,5 +1,5 @@
1
1
 
2
- import { T as BoltdocsConfig, a as SidebarItem, d as SidebarMobile, f as SidebarRoot, i as SidebarHeader, l as SidebarLink, n as SidebarContent, p as SidebarSubGroup, r as SidebarGroup, s as SidebarItems, v as ComponentRoute, x as OnThisPageProps } from "./sidebar-DNq4_ZAa.js";
2
+ import { T as BoltdocsConfig, a as SidebarItem, d as SidebarMobile, f as SidebarRoot, i as SidebarHeader, l as SidebarLink, n as SidebarContent, p as SidebarSubGroup, r as SidebarGroup, s as SidebarItems, v as ComponentRoute, x as OnThisPageProps } from "./sidebar-kQBonN82.js";
3
3
  import { ReactNode } from "react";
4
4
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
5
5
 
@@ -1,5 +1,5 @@
1
1
 
2
- import { T as BoltdocsConfig, a as SidebarItem, d as SidebarMobile, f as SidebarRoot, i as SidebarHeader, l as SidebarLink, n as SidebarContent, p as SidebarSubGroup, r as SidebarGroup, s as SidebarItems, v as ComponentRoute, x as OnThisPageProps } from "./sidebar-Dlkgbxs6.cjs";
2
+ import { T as BoltdocsConfig, a as SidebarItem, d as SidebarMobile, f as SidebarRoot, i as SidebarHeader, l as SidebarLink, n as SidebarContent, p as SidebarSubGroup, r as SidebarGroup, s as SidebarItems, v as ComponentRoute, x as OnThisPageProps } from "./sidebar---RgTmZD.cjs";
3
3
  import { ReactNode } from "react";
4
4
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
5
5
 
@@ -4,12 +4,12 @@
4
4
  * Licensed under the MIT License.
5
5
  */
6
6
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
7
- const require_icons_dev = require('../icons-dev-DvJ-hh9x.cjs');
8
- const require_image = require('../image-Ch4-GxdO.cjs');
9
- const require_mdx = require('../mdx-BGM7LjW5.cjs');
10
- const require_docs_layout = require('../docs-layout-CwCq42Zt.cjs');
11
- const require_search_dialog = require('../search-dialog-BXVoecTx.cjs');
12
- const require_search_dialog$1 = require('../search-dialog-BYhOov4S.cjs');
7
+ const require_icons_dev = require('../icons-dev-C8sFxeBk.cjs');
8
+ const require_image = require('../image-DCMxxidi.cjs');
9
+ const require_mdx = require('../mdx-BH9kHiF9.cjs');
10
+ const require_docs_layout = require('../docs-layout-CVCf3xkZ.cjs');
11
+ const require_search_dialog = require('../search-dialog-Cvux-qSk.cjs');
12
+ const require_search_dialog$1 = require('../search-dialog-CmHYOt18.cjs');
13
13
  let react = require("react");
14
14
  let react_router_dom = require("react-router-dom");
15
15
  let react_jsx_runtime = require("react/jsx-runtime");
@@ -978,7 +978,7 @@ function I18nSelector({ className }) {
978
978
 
979
979
  //#endregion
980
980
  //#region src/client/components/ui-base/navbar.tsx
981
- const SearchDialog$1 = (0, react.lazy)(() => Promise.resolve().then(() => require("../search-dialog-CUeAfy-8.cjs")).then((m) => ({ default: m.SearchDialog })));
981
+ const SearchDialog$1 = (0, react.lazy)(() => Promise.resolve().then(() => require("../search-dialog-Cr7SC8Xt.cjs")).then((m) => ({ default: m.SearchDialog })));
982
982
  function Navbar() {
983
983
  const { links, title, logo, logoProps, github, social, config } = useNavbar();
984
984
  const { routes, currentRoute, isCollectionPage, currentVersion, currentLocale } = require_icons_dev.useRoutes();
@@ -1582,21 +1582,37 @@ function buildDocRoutes(options) {
1582
1582
  const targetBasePaths = [];
1583
1583
  targetBasePaths.push({
1584
1584
  path: baseDocsPath,
1585
- filter: () => true
1585
+ filter: () => true,
1586
+ locale: config.i18n?.defaultLocale,
1587
+ version: config.versions?.defaultVersion
1586
1588
  });
1587
- const subPaths = [];
1588
- if (allVersions.length > 0) allVersions.forEach((v) => subPaths.push(`/${v}`));
1589
- if (locales.length > 0) locales.forEach((l) => subPaths.push(`/${l}`));
1590
- if (allVersions.length > 0 && locales.length > 0) allVersions.forEach((v) => {
1591
- locales.forEach((l) => {
1592
- subPaths.push(`/${v}/${l}`);
1589
+ if (allVersions.length > 0) allVersions.forEach((v) => {
1590
+ const fullP = baseDocsPath === "/" ? `/${v}` : `${baseDocsPath}/${v}`;
1591
+ targetBasePaths.push({
1592
+ path: fullP,
1593
+ filter: (rp) => !!rp && rp.startsWith(fullP.replace(/\/$/, "") + "/"),
1594
+ locale: config.i18n?.defaultLocale,
1595
+ version: v
1593
1596
  });
1594
1597
  });
1595
- subPaths.forEach((sp) => {
1596
- const fullP = baseDocsPath === "/" ? sp : `${baseDocsPath}${sp}`;
1598
+ if (locales.length > 0) locales.forEach((l) => {
1599
+ const fullP = baseDocsPath === "/" ? `/${l}` : `${baseDocsPath}/${l}`;
1597
1600
  targetBasePaths.push({
1598
1601
  path: fullP,
1599
- filter: (rp) => !!rp && rp.startsWith(fullP.replace(/\/$/, "") + "/")
1602
+ filter: (rp) => !!rp && rp.startsWith(fullP.replace(/\/$/, "") + "/"),
1603
+ locale: l,
1604
+ version: config.versions?.defaultVersion
1605
+ });
1606
+ });
1607
+ if (allVersions.length > 0 && locales.length > 0) allVersions.forEach((v) => {
1608
+ locales.forEach((l) => {
1609
+ const fullP = baseDocsPath === "/" ? `/${v}/${l}` : `${baseDocsPath}/${v}/${l}`;
1610
+ targetBasePaths.push({
1611
+ path: fullP,
1612
+ filter: (rp) => !!rp && rp.startsWith(fullP.replace(/\/$/, "") + "/"),
1613
+ locale: l,
1614
+ version: v
1615
+ });
1600
1616
  });
1601
1617
  });
1602
1618
  const docPathRegistry = new Set(docRoutes.map((r) => (r.path || "").replace(/\/$/, "")));
@@ -1608,7 +1624,7 @@ function buildDocRoutes(options) {
1608
1624
  externalPaths.add(`/${locale}${p === "/" ? "" : p}`.replace(/\/$/, ""));
1609
1625
  });
1610
1626
  });
1611
- targetBasePaths.forEach(({ path: bPath, filter }) => {
1627
+ targetBasePaths.forEach(({ path: bPath, filter, locale: bLocale, version: bVersion }) => {
1612
1628
  if (bPath === "/") return;
1613
1629
  const normalizedPath = bPath.replace(/\/$/, "");
1614
1630
  if (!(docPathRegistry.has(normalizedPath) || externalPaths.has(normalizedPath))) {
@@ -1622,6 +1638,7 @@ function buildDocRoutes(options) {
1622
1638
  docRoutes.push({
1623
1639
  ...isBasePathFallback ? { index: true } : { path: redirectPath },
1624
1640
  element: matchedRouteObj.element,
1641
+ lazy: matchedRouteObj.lazy,
1625
1642
  loader: matchedRouteObj.loader,
1626
1643
  getStaticPaths: () => []
1627
1644
  });
@@ -1635,8 +1652,11 @@ function buildDocRoutes(options) {
1635
1652
  docMetadata.push({
1636
1653
  ...matchedMetaObj,
1637
1654
  path: bPath,
1638
- filePath: "",
1655
+ filePath: matchedMetaObj.filePath,
1656
+ locale: bLocale,
1657
+ version: bVersion,
1639
1658
  slugParts: [],
1659
+ fallback: true,
1640
1660
  seo: {
1641
1661
  ...matchedMetaObj.seo,
1642
1662
  canonical: canonicalUrl
@@ -1,6 +1,6 @@
1
1
 
2
- import { A as BoltdocsRoutePathWithFallback, C as SiteConfig, D as BoltdocsLocale, E as BoltdocsIntegrationsConfig, M as BoltdocsTypes, N as BoltdocsVersion, O as BoltdocsMdxComponents, S as SidebarProps, T as BoltdocsConfig, _ as CollectionPostLoaderData, b as NavbarLink, g as CollectionListLoaderData, h as BoltdocsTab, j as BoltdocsSocialLink, k as BoltdocsRoutePath, v as ComponentRoute, w as TabsProps, x as OnThisPageProps, y as LayoutProps } from "../sidebar-Dlkgbxs6.cjs";
3
- import { a as ErrorBoundary, c as OnThisPage, i as CopyMarkdown, l as Sidebar, n as NotFound, o as PageNav, r as SearchDialog, s as Breadcrumbs, t as Banner, u as Navbar } from "../banner-MynZD_Ox.cjs";
2
+ import { A as BoltdocsRoutePathWithFallback, C as SiteConfig, D as BoltdocsLocale, E as BoltdocsIntegrationsConfig, M as BoltdocsTypes, N as BoltdocsVersion, O as BoltdocsMdxComponents, S as SidebarProps, T as BoltdocsConfig, _ as CollectionPostLoaderData, b as NavbarLink, g as CollectionListLoaderData, h as BoltdocsTab, j as BoltdocsSocialLink, k as BoltdocsRoutePath, v as ComponentRoute, w as TabsProps, x as OnThisPageProps, y as LayoutProps } from "../sidebar---RgTmZD.cjs";
3
+ import { a as ErrorBoundary, c as OnThisPage, i as CopyMarkdown, l as Sidebar, n as NotFound, o as PageNav, r as SearchDialog, s as Breadcrumbs, t as Banner, u as Navbar } from "../banner-DFACg5Dy.cjs";
4
4
  import * as _$react from "react";
5
5
  import React$1, { ComponentType, JSXElementConstructor, ReactNode } from "react";
6
6
  import { RouteRecord, ViteReactSSG } from "@bdocs/ssg";
@@ -1,6 +1,6 @@
1
1
 
2
- import { A as BoltdocsRoutePathWithFallback, C as SiteConfig, D as BoltdocsLocale, E as BoltdocsIntegrationsConfig, M as BoltdocsTypes, N as BoltdocsVersion, O as BoltdocsMdxComponents, S as SidebarProps, T as BoltdocsConfig, _ as CollectionPostLoaderData, b as NavbarLink, g as CollectionListLoaderData, h as BoltdocsTab, j as BoltdocsSocialLink, k as BoltdocsRoutePath, v as ComponentRoute, w as TabsProps, x as OnThisPageProps, y as LayoutProps } from "../sidebar-DNq4_ZAa.js";
3
- import { a as ErrorBoundary, c as OnThisPage, i as CopyMarkdown, l as Sidebar, n as NotFound, o as PageNav, r as SearchDialog, s as Breadcrumbs, t as Banner, u as Navbar } from "../banner-3N4Jd_L9.js";
2
+ import { A as BoltdocsRoutePathWithFallback, C as SiteConfig, D as BoltdocsLocale, E as BoltdocsIntegrationsConfig, M as BoltdocsTypes, N as BoltdocsVersion, O as BoltdocsMdxComponents, S as SidebarProps, T as BoltdocsConfig, _ as CollectionPostLoaderData, b as NavbarLink, g as CollectionListLoaderData, h as BoltdocsTab, j as BoltdocsSocialLink, k as BoltdocsRoutePath, v as ComponentRoute, w as TabsProps, x as OnThisPageProps, y as LayoutProps } from "../sidebar-kQBonN82.js";
3
+ import { a as ErrorBoundary, c as OnThisPage, i as CopyMarkdown, l as Sidebar, n as NotFound, o as PageNav, r as SearchDialog, s as Breadcrumbs, t as Banner, u as Navbar } from "../banner-BLTQUA2O.js";
4
4
  import { RouteRecord, ViteReactSSG } from "@bdocs/ssg";
5
5
  import * as _$react from "react";
6
6
  import React$1, { ComponentType, JSXElementConstructor, ReactNode } from "react";
@@ -3,12 +3,12 @@
3
3
  * Copyright (c) 2026 Jesus Alcala
4
4
  * Licensed under the MIT License.
5
5
  */
6
- import { $ as ConfigContext, B as Languages, C as RoutesProvider, D as Check, E as ArrowLeft, G as Moon, M as Copy, O as ChevronDown, P as ExternalLink, Q as icons_exports, R as Home, S as normalizePath, U as Menu, W as Monitor, X as TextAlignStart, Y as Sun, Z as X, _ as Link$1, b as useLocalizedTo, et as useConfig, j as CircleHelp, nt as useBoltdocsContext, q as Pencil, s as Github, tt as BoltdocsProvider, x as useRoutes, y as cn } from "../icons-dev-Oju24Wjp.js";
7
- import { c as ThemeProvider, l as useTheme } from "../image-Do8V9PCW.js";
8
- import { n as copyToClipboard, t as mdx_components_default } from "../mdx-5oeCOFhH.js";
9
- import { A as useUI, D as ButtonGroup, O as Breadcrumbs$2, T as Menu$1, _ as OnThisPage$1, h as PageNav$1, i as Sidebar$1, k as UIProvider, m as useSidebar, n as useSearchHighlight, r as useLocation, t as DocsLayout$1, w as Tabs$1 } from "../docs-layout-Dn6S5g59.js";
10
- import { a as Button$1, n as Navbar$1, r as ErrorBoundary$1 } from "../search-dialog-D8gLkhUV.js";
11
- import { n as useSearch, r as InternalErrorBoundary, t as SearchDialog } from "../search-dialog-C09riYmx.js";
6
+ import { $ as ConfigContext, B as Languages, C as RoutesProvider, D as Check, E as ArrowLeft, G as Moon, M as Copy, O as ChevronDown, P as ExternalLink, Q as icons_exports, R as Home, S as normalizePath, U as Menu, W as Monitor, X as TextAlignStart, Y as Sun, Z as X, _ as Link$1, b as useLocalizedTo, et as useConfig, j as CircleHelp, nt as useBoltdocsContext, q as Pencil, s as Github, tt as BoltdocsProvider, x as useRoutes, y as cn } from "../icons-dev-CFcv5Nb8.js";
7
+ import { c as ThemeProvider, l as useTheme } from "../image-DufDOid8.js";
8
+ import { n as copyToClipboard, t as mdx_components_default } from "../mdx-Bto8CvGl.js";
9
+ import { A as useUI, D as ButtonGroup, O as Breadcrumbs$2, T as Menu$1, _ as OnThisPage$1, h as PageNav$1, i as Sidebar$1, k as UIProvider, m as useSidebar, n as useSearchHighlight, r as useLocation, t as DocsLayout$1, w as Tabs$1 } from "../docs-layout-BBv6wILp.js";
10
+ import { a as Button$1, n as Navbar$1, r as ErrorBoundary$1 } from "../search-dialog-e86WPpck.js";
11
+ import { n as useSearch, r as InternalErrorBoundary, t as SearchDialog } from "../search-dialog-jHZ21G4i.js";
12
12
  import { ViteReactSSG } from "@bdocs/ssg";
13
13
  import { Suspense, createContext, isValidElement, lazy, use, useCallback, useEffect, useLayoutEffect, useMemo, useRef, useState } from "react";
14
14
  import { Link, Outlet, useLoaderData, useLocation as useLocation$1, useMatches, useNavigate } from "react-router-dom";
@@ -973,7 +973,7 @@ function I18nSelector({ className }) {
973
973
 
974
974
  //#endregion
975
975
  //#region src/client/components/ui-base/navbar.tsx
976
- const SearchDialog$1 = lazy(() => import("../search-dialog-DHc_8FFX.js").then((m) => ({ default: m.SearchDialog })));
976
+ const SearchDialog$1 = lazy(() => import("../search-dialog-DBNaG5At.js").then((m) => ({ default: m.SearchDialog })));
977
977
  function Navbar() {
978
978
  const { links, title, logo, logoProps, github, social, config } = useNavbar();
979
979
  const { routes, currentRoute, isCollectionPage, currentVersion, currentLocale } = useRoutes();
@@ -1577,21 +1577,37 @@ function buildDocRoutes(options) {
1577
1577
  const targetBasePaths = [];
1578
1578
  targetBasePaths.push({
1579
1579
  path: baseDocsPath,
1580
- filter: () => true
1580
+ filter: () => true,
1581
+ locale: config.i18n?.defaultLocale,
1582
+ version: config.versions?.defaultVersion
1581
1583
  });
1582
- const subPaths = [];
1583
- if (allVersions.length > 0) allVersions.forEach((v) => subPaths.push(`/${v}`));
1584
- if (locales.length > 0) locales.forEach((l) => subPaths.push(`/${l}`));
1585
- if (allVersions.length > 0 && locales.length > 0) allVersions.forEach((v) => {
1586
- locales.forEach((l) => {
1587
- subPaths.push(`/${v}/${l}`);
1584
+ if (allVersions.length > 0) allVersions.forEach((v) => {
1585
+ const fullP = baseDocsPath === "/" ? `/${v}` : `${baseDocsPath}/${v}`;
1586
+ targetBasePaths.push({
1587
+ path: fullP,
1588
+ filter: (rp) => !!rp && rp.startsWith(fullP.replace(/\/$/, "") + "/"),
1589
+ locale: config.i18n?.defaultLocale,
1590
+ version: v
1588
1591
  });
1589
1592
  });
1590
- subPaths.forEach((sp) => {
1591
- const fullP = baseDocsPath === "/" ? sp : `${baseDocsPath}${sp}`;
1593
+ if (locales.length > 0) locales.forEach((l) => {
1594
+ const fullP = baseDocsPath === "/" ? `/${l}` : `${baseDocsPath}/${l}`;
1592
1595
  targetBasePaths.push({
1593
1596
  path: fullP,
1594
- filter: (rp) => !!rp && rp.startsWith(fullP.replace(/\/$/, "") + "/")
1597
+ filter: (rp) => !!rp && rp.startsWith(fullP.replace(/\/$/, "") + "/"),
1598
+ locale: l,
1599
+ version: config.versions?.defaultVersion
1600
+ });
1601
+ });
1602
+ if (allVersions.length > 0 && locales.length > 0) allVersions.forEach((v) => {
1603
+ locales.forEach((l) => {
1604
+ const fullP = baseDocsPath === "/" ? `/${v}/${l}` : `${baseDocsPath}/${v}/${l}`;
1605
+ targetBasePaths.push({
1606
+ path: fullP,
1607
+ filter: (rp) => !!rp && rp.startsWith(fullP.replace(/\/$/, "") + "/"),
1608
+ locale: l,
1609
+ version: v
1610
+ });
1595
1611
  });
1596
1612
  });
1597
1613
  const docPathRegistry = new Set(docRoutes.map((r) => (r.path || "").replace(/\/$/, "")));
@@ -1603,7 +1619,7 @@ function buildDocRoutes(options) {
1603
1619
  externalPaths.add(`/${locale}${p === "/" ? "" : p}`.replace(/\/$/, ""));
1604
1620
  });
1605
1621
  });
1606
- targetBasePaths.forEach(({ path: bPath, filter }) => {
1622
+ targetBasePaths.forEach(({ path: bPath, filter, locale: bLocale, version: bVersion }) => {
1607
1623
  if (bPath === "/") return;
1608
1624
  const normalizedPath = bPath.replace(/\/$/, "");
1609
1625
  if (!(docPathRegistry.has(normalizedPath) || externalPaths.has(normalizedPath))) {
@@ -1617,6 +1633,7 @@ function buildDocRoutes(options) {
1617
1633
  docRoutes.push({
1618
1634
  ...isBasePathFallback ? { index: true } : { path: redirectPath },
1619
1635
  element: matchedRouteObj.element,
1636
+ lazy: matchedRouteObj.lazy,
1620
1637
  loader: matchedRouteObj.loader,
1621
1638
  getStaticPaths: () => []
1622
1639
  });
@@ -1630,8 +1647,11 @@ function buildDocRoutes(options) {
1630
1647
  docMetadata.push({
1631
1648
  ...matchedMetaObj,
1632
1649
  path: bPath,
1633
- filePath: "",
1650
+ filePath: matchedMetaObj.filePath,
1651
+ locale: bLocale,
1652
+ version: bVersion,
1634
1653
  slugParts: [],
1654
+ fallback: true,
1635
1655
  seo: {
1636
1656
  ...matchedMetaObj.seo,
1637
1657
  canonical: canonicalUrl
@@ -4,7 +4,7 @@
4
4
  * Licensed under the MIT License.
5
5
  */
6
6
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
7
- const require_mdx = require('../mdx-BGM7LjW5.cjs');
7
+ const require_mdx = require('../mdx-BH9kHiF9.cjs');
8
8
 
9
9
  //#region src/client/mdx.ts
10
10
  const { Card, Cards, Callout, Field, Image } = require_mdx.mdx_components_default;
@@ -3,7 +3,7 @@
3
3
  * Copyright (c) 2026 Jesus Alcala
4
4
  * Licensed under the MIT License.
5
5
  */
6
- import { t as mdx_components_default } from "../mdx-5oeCOFhH.js";
6
+ import { t as mdx_components_default } from "../mdx-Bto8CvGl.js";
7
7
 
8
8
  //#region src/client/mdx.ts
9
9
  const { Card, Cards, Callout, Field, Image } = mdx_components_default;
@@ -4,10 +4,10 @@
4
4
  * Licensed under the MIT License.
5
5
  */
6
6
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
7
- const require_icons_dev = require('../icons-dev-DvJ-hh9x.cjs');
8
- const require_image = require('../image-Ch4-GxdO.cjs');
9
- const require_docs_layout = require('../docs-layout-CwCq42Zt.cjs');
10
- const require_search_dialog = require('../search-dialog-BXVoecTx.cjs');
7
+ const require_icons_dev = require('../icons-dev-C8sFxeBk.cjs');
8
+ const require_image = require('../image-DCMxxidi.cjs');
9
+ const require_docs_layout = require('../docs-layout-CVCf3xkZ.cjs');
10
+ const require_search_dialog = require('../search-dialog-Cvux-qSk.cjs');
11
11
  let react_jsx_runtime = require("react/jsx-runtime");
12
12
 
13
13
  //#region src/client/components/primitives/skeleton.tsx
@@ -1,5 +1,5 @@
1
1
 
2
- import { A as BoltdocsRoutePathWithFallback, a as SidebarItem, c as SidebarItemsProps, d as SidebarMobile, f as SidebarRoot, i as SidebarHeader, l as SidebarLink, m as ComponentBase, n as SidebarContent, o as SidebarItemProps, p as SidebarSubGroup, r as SidebarGroup, s as SidebarItems, t as Sidebar, u as SidebarLinkProps } from "../sidebar-Dlkgbxs6.cjs";
2
+ import { A as BoltdocsRoutePathWithFallback, a as SidebarItem, c as SidebarItemsProps, d as SidebarMobile, f as SidebarRoot, i as SidebarHeader, l as SidebarLink, m as ComponentBase, n as SidebarContent, o as SidebarItemProps, p as SidebarSubGroup, r as SidebarGroup, s as SidebarItems, t as Sidebar, u as SidebarLinkProps } from "../sidebar---RgTmZD.cjs";
3
3
  import * as React$2 from "react";
4
4
  import { Component, ComponentProps, ComponentType, ErrorInfo, ImgHTMLAttributes, ReactNode, RefObject } from "react";
5
5
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
@@ -1,5 +1,5 @@
1
1
 
2
- import { A as BoltdocsRoutePathWithFallback, a as SidebarItem, c as SidebarItemsProps, d as SidebarMobile, f as SidebarRoot, i as SidebarHeader, l as SidebarLink, m as ComponentBase, n as SidebarContent, o as SidebarItemProps, p as SidebarSubGroup, r as SidebarGroup, s as SidebarItems, t as Sidebar, u as SidebarLinkProps } from "../sidebar-DNq4_ZAa.js";
2
+ import { A as BoltdocsRoutePathWithFallback, a as SidebarItem, c as SidebarItemsProps, d as SidebarMobile, f as SidebarRoot, i as SidebarHeader, l as SidebarLink, m as ComponentBase, n as SidebarContent, o as SidebarItemProps, p as SidebarSubGroup, r as SidebarGroup, s as SidebarItems, t as Sidebar, u as SidebarLinkProps } from "../sidebar-kQBonN82.js";
3
3
  import * as React$2 from "react";
4
4
  import { Component, ComponentProps, ComponentType, ErrorInfo, ImgHTMLAttributes, ReactNode, RefObject } from "react";
5
5
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
@@ -3,10 +3,10 @@
3
3
  * Copyright (c) 2026 Jesus Alcala
4
4
  * Licensed under the MIT License.
5
5
  */
6
- import { _ as Link, v as NavLink, y as cn } from "../icons-dev-Oju24Wjp.js";
7
- import { a as CodeBlockGroup, i as CodeBlockContent, n as Tooltip, o as CodeBlockHeader, r as CodeBlock, s as Heading, t as Image } from "../image-Do8V9PCW.js";
8
- import { C as useItems, D as ButtonGroup, E as Popover, O as Breadcrumbs, S as useActiveAnchors, T as Menu, _ as OnThisPage, a as SidebarContent, b as ScrollProvider, c as SidebarItem, d as SidebarMobile, f as SidebarRoot, g as AnchorProvider, h as PageNav, i as Sidebar, l as SidebarItems, o as SidebarGroup, p as SidebarSubGroup, s as SidebarHeader, t as DocsLayout, u as SidebarLink, v as OnThisPageItems, w as Tabs, x as useActiveAnchor, y as OnThisPageTree } from "../docs-layout-Dn6S5g59.js";
9
- import { a as Button, i as ErrorBoundaryFallback, n as Navbar, r as ErrorBoundary, t as SearchDialog } from "../search-dialog-D8gLkhUV.js";
6
+ import { _ as Link, v as NavLink, y as cn } from "../icons-dev-CFcv5Nb8.js";
7
+ import { a as CodeBlockGroup, i as CodeBlockContent, n as Tooltip, o as CodeBlockHeader, r as CodeBlock, s as Heading, t as Image } from "../image-DufDOid8.js";
8
+ import { C as useItems, D as ButtonGroup, E as Popover, O as Breadcrumbs, S as useActiveAnchors, T as Menu, _ as OnThisPage, a as SidebarContent, b as ScrollProvider, c as SidebarItem, d as SidebarMobile, f as SidebarRoot, g as AnchorProvider, h as PageNav, i as Sidebar, l as SidebarItems, o as SidebarGroup, p as SidebarSubGroup, s as SidebarHeader, t as DocsLayout, u as SidebarLink, v as OnThisPageItems, w as Tabs, x as useActiveAnchor, y as OnThisPageTree } from "../docs-layout-BBv6wILp.js";
9
+ import { a as Button, i as ErrorBoundaryFallback, n as Navbar, r as ErrorBoundary, t as SearchDialog } from "../search-dialog-e86WPpck.js";
10
10
  import { jsx } from "react/jsx-runtime";
11
11
 
12
12
  //#region src/client/components/primitives/skeleton.tsx
@@ -3,7 +3,7 @@
3
3
  * Copyright (c) 2026 Jesus Alcala
4
4
  * Licensed under the MIT License.
5
5
  */
6
- import { A as ChevronRight, D as Check, Q as icons_exports, S as normalizePath, _ as Link$1, b as useLocalizedTo, et as useConfig, k as ChevronLeft, y as cn } from "./icons-dev-Oju24Wjp.js";
6
+ import { A as ChevronRight, D as Check, Q as icons_exports, S as normalizePath, _ as Link$1, b as useLocalizedTo, et as useConfig, k as ChevronLeft, y as cn } from "./icons-dev-CFcv5Nb8.js";
7
7
  import { Children, createContext, use, useContext, useEffect, useImperativeHandle, useLayoutEffect, useMemo, useRef, useState } from "react";
8
8
  import { useLocation } from "react-router-dom";
9
9
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
@@ -619,112 +619,102 @@ PageNav.Icon = PageNavIcon;
619
619
 
620
620
  //#endregion
621
621
  //#region src/client/hooks/use-sidebar.ts
622
+ const capitalize = (str) => str.charAt(0).toUpperCase() + str.slice(1).replace(/-/g, " ");
623
+ const getCleanDirectoryMeta = (directoryMeta) => {
624
+ const meta = {};
625
+ if (!directoryMeta) return meta;
626
+ for (const [key, value] of Object.entries(directoryMeta)) {
627
+ const cleanKey = key.split("/").filter((part) => !part.startsWith("(") || !part.endsWith(")")).map((part) => part.replace(/^\d+-/, "")).join("/");
628
+ meta[cleanKey === "" ? "." : cleanKey] = value;
629
+ }
630
+ return meta;
631
+ };
632
+ const getOrCreateNode = (parts, rootMap, directoryMeta) => {
633
+ let currentMap = rootMap;
634
+ let parentPath = "";
635
+ let lastNode;
636
+ for (const segment of parts) {
637
+ const currentRelPath = parentPath ? `${parentPath}/${segment}` : segment;
638
+ if (!currentMap.has(segment)) {
639
+ const meta = directoryMeta[currentRelPath] || {};
640
+ const newNode = {
641
+ path: "#",
642
+ title: meta.title || capitalize(segment),
643
+ componentPath: "",
644
+ filePath: "",
645
+ icon: meta.icon,
646
+ groupPosition: typeof meta.order === "number" ? meta.order : 999,
647
+ subRoutes: [],
648
+ childrenMap: /* @__PURE__ */ new Map()
649
+ };
650
+ currentMap.set(segment, newNode);
651
+ }
652
+ lastNode = currentMap.get(segment);
653
+ currentMap = lastNode.childrenMap;
654
+ parentPath = currentRelPath;
655
+ }
656
+ return lastNode;
657
+ };
658
+ const getRoutePosition = (r) => r.sidebarPosition ?? r.order ?? 999;
659
+ const getNodePosition = (n) => n.sidebarPosition ?? n.groupPosition ?? 999;
660
+ const finalizeTree = (nodes) => {
661
+ return nodes.map((node) => {
662
+ if (node.childrenMap && node.childrenMap.size > 0) {
663
+ const childDirs = Array.from(node.childrenMap.values());
664
+ node.subRoutes = [...node.subRoutes || [], ...childDirs];
665
+ }
666
+ const { childrenMap, ...restNode } = node;
667
+ if (restNode.subRoutes && restNode.subRoutes.length > 0) restNode.subRoutes = finalizeTree(restNode.subRoutes);
668
+ return restNode;
669
+ }).sort((a, b) => {
670
+ const posA = getNodePosition(a);
671
+ const posB = getNodePosition(b);
672
+ return posA !== posB ? posA - posB : a.title.localeCompare(b.title);
673
+ });
674
+ };
622
675
  function useSidebar(routes) {
623
676
  const config = useConfig();
624
- const currentPath = normalizePath(useLocation().pathname);
677
+ const { pathname } = useLocation();
625
678
  return useMemo(() => {
679
+ const currentPath = normalizePath(pathname);
626
680
  const activeRoute = routes.find((r) => normalizePath(r.path) === currentPath);
627
681
  const activeTabId = activeRoute?.tab?.toLowerCase();
628
- const noCollection = routes.filter((r) => !r.collection);
629
- const filteredRoutes = activeTabId ? noCollection.filter((r) => !r.tab || r.tab.toLowerCase() === activeTabId) : noCollection;
630
- const directoryMeta = {};
631
- if (config.directoryMeta) for (const [key, value] of Object.entries(config.directoryMeta)) {
632
- const cleanKey = key.split("/").filter((part) => !part.startsWith("(") || !part.endsWith(")")).map((part) => part.replace(/^\d+-/, "")).join("/");
633
- directoryMeta[cleanKey === "" ? "." : cleanKey] = value;
634
- }
635
- const capitalize = (str) => str.charAt(0).toUpperCase() + str.slice(1).replace(/-/g, " ");
682
+ const filteredRoutes = routes.filter((r) => !r.collection && !r.sidebarHidden && !r.fallback).filter((r) => !activeTabId || r.tab?.toLowerCase() === activeTabId).sort((a, b) => getRoutePosition(a) - getRoutePosition(b));
683
+ const directoryMeta = getCleanDirectoryMeta(config.directoryMeta);
636
684
  const rootNodesMap = /* @__PURE__ */ new Map();
637
685
  const ungrouped = [];
638
- const getOrCreateNode = (parts, rootStore) => {
639
- let currentMap = rootStore;
640
- let parentPath = "";
641
- let lastNode = null;
642
- for (let i = 0; i < parts.length; i++) {
643
- const segment = parts[i];
644
- const currentRelPath = parentPath ? `${parentPath}/${segment}` : segment;
645
- if (!currentMap.has(segment)) {
646
- const meta = directoryMeta[currentRelPath] || {};
647
- const newNode = {
648
- path: "#",
649
- title: meta.title || capitalize(segment),
650
- componentPath: "",
651
- filePath: "",
652
- icon: meta.icon,
653
- groupPosition: typeof meta.order === "number" ? meta.order : 999,
654
- subRoutes: []
655
- };
656
- currentMap.set(segment, newNode);
657
- }
658
- lastNode = currentMap.get(segment);
659
- if (!lastNode._subMap) lastNode._subMap = /* @__PURE__ */ new Map();
660
- currentMap = lastNode._subMap;
661
- parentPath = currentRelPath;
662
- }
663
- return lastNode;
664
- };
665
- const sortedRoutes = [...filteredRoutes].sort((a, b) => {
666
- return (a.sidebarPosition ?? a.order ?? 999) - (b.sidebarPosition ?? b.order ?? 999);
667
- });
668
- for (const route of sortedRoutes) {
669
- if (route.sidebarHidden) continue;
686
+ for (const route of filteredRoutes) {
670
687
  const parts = route.slugParts || [];
671
- const fileName = route.filePath.split("/").pop() || "";
672
- const isIndex = /^index\.mdx?$/.test(fileName);
688
+ const isIndex = /^index\.mdx?$/.test(route.filePath.split("/").pop() || "");
673
689
  if (parts.length === 0) {
674
690
  if (route.filePath) ungrouped.push(route);
675
691
  continue;
676
692
  }
677
- if (isIndex) {
678
- const containerNode = getOrCreateNode(parts, rootNodesMap);
679
- if (containerNode) {
680
- containerNode.path = route.path;
681
- containerNode.title = route.title || containerNode.title;
682
- containerNode.icon = route.icon || containerNode.icon;
683
- containerNode.badge = route.badge;
684
- containerNode.sidebarPosition = route.sidebarPosition;
685
- containerNode.frontmatter = route.frontmatter;
686
- }
687
- } else {
688
- const parentNode = getOrCreateNode(parts, rootNodesMap);
689
- if (parentNode) parentNode.subRoutes.push(route);
690
- }
691
- }
692
- const finalizeTree = (nodes, currentPathPrefix = "") => {
693
- nodes.forEach((node) => {
694
- if (node._subMap) {
695
- const childDirs = Array.from(node._subMap.values());
696
- node.subRoutes = [...node.subRoutes || [], ...childDirs];
697
- delete node._subMap;
698
- }
699
- if (node.subRoutes && node.subRoutes.length > 0) node.subRoutes = finalizeTree(node.subRoutes);
693
+ const containerNode = getOrCreateNode(parts, rootNodesMap, directoryMeta);
694
+ if (isIndex) Object.assign(containerNode, {
695
+ path: route.path,
696
+ title: route.title || containerNode.title,
697
+ icon: route.icon || containerNode.icon,
698
+ badge: route.badge,
699
+ sidebarPosition: route.sidebarPosition,
700
+ frontmatter: route.frontmatter,
701
+ filePath: route.filePath
700
702
  });
701
- return nodes.sort((a, b) => {
702
- const posA = a.sidebarPosition ?? a.groupPosition ?? 999;
703
- const posB = b.sidebarPosition ?? b.groupPosition ?? 999;
704
- if (posA !== posB) return posA - posB;
705
- return a.title.localeCompare(b.title);
706
- });
707
- };
703
+ else containerNode.subRoutes.push(route);
704
+ }
708
705
  const finalizedTopNodes = finalizeTree(Array.from(rootNodesMap.values()));
709
- finalizedTopNodes.map((node) => {
710
- return {
711
- slug: node.title.toLowerCase().replace(/\s+/g, "-"),
712
- title: node.title,
713
- icon: node.icon,
714
- routes: [node]
715
- };
706
+ const groups = [];
707
+ for (const node of finalizedTopNodes) if (node.subRoutes && node.subRoutes.length > 0) groups.push({
708
+ slug: node.title.toLowerCase().replace(/\s+/g, "-"),
709
+ title: node.title,
710
+ icon: node.icon,
711
+ path: node.path,
712
+ filePath: node.filePath,
713
+ routes: node.subRoutes
716
714
  });
715
+ else ungrouped.push(node);
717
716
  return {
718
- groups: finalizedTopNodes.map((node) => {
719
- if (node.subRoutes && node.subRoutes.length > 0) return {
720
- slug: node.title.toLowerCase().replace(/\s+/g, "-"),
721
- title: node.title,
722
- icon: node.icon,
723
- routes: node.subRoutes
724
- };
725
- ungrouped.push(node);
726
- return null;
727
- }).filter(Boolean),
717
+ groups,
728
718
  ungrouped: finalizeTree(ungrouped),
729
719
  activeRoute,
730
720
  activePath: currentPath,
@@ -733,7 +723,7 @@ function useSidebar(routes) {
733
723
  }, [
734
724
  routes,
735
725
  config,
736
- currentPath
726
+ pathname
737
727
  ]);
738
728
  }
739
729