boltdocs 1.7.0 → 1.8.0

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 (42) hide show
  1. package/dist/{SearchDialog-UOAW6IR3.css → SearchDialog-4ANHNJTL.css} +213 -28
  2. package/dist/{SearchDialog-YOXMFGH6.mjs → SearchDialog-6Z7CUAYJ.mjs} +8 -1
  3. package/dist/{chunk-MULKZFVN.mjs → chunk-SFVOGJ2W.mjs} +269 -165
  4. package/dist/client/index.css +211 -26
  5. package/dist/client/index.d.mts +25 -6
  6. package/dist/client/index.d.ts +25 -6
  7. package/dist/client/index.js +614 -336
  8. package/dist/client/index.mjs +134 -5
  9. package/dist/client/ssr.css +211 -26
  10. package/dist/client/ssr.d.mts +1 -1
  11. package/dist/client/ssr.d.ts +1 -1
  12. package/dist/client/ssr.js +378 -230
  13. package/dist/client/ssr.mjs +1 -1
  14. package/dist/node/index.d.mts +2 -0
  15. package/dist/node/index.d.ts +2 -0
  16. package/dist/node/index.js +4 -1
  17. package/dist/node/index.mjs +4 -1
  18. package/dist/{types-CviV0GbX.d.ts → types-BbceAHA0.d.mts} +2 -0
  19. package/dist/{types-CviV0GbX.d.mts → types-BbceAHA0.d.ts} +2 -0
  20. package/package.json +1 -1
  21. package/src/client/app/index.tsx +8 -7
  22. package/src/client/index.ts +2 -0
  23. package/src/client/theme/components/mdx/Field.tsx +60 -0
  24. package/src/client/theme/components/mdx/Table.tsx +108 -10
  25. package/src/client/theme/components/mdx/index.ts +3 -0
  26. package/src/client/theme/components/mdx/mdx-components.css +174 -0
  27. package/src/client/theme/styles/variables.css +25 -1
  28. package/src/client/theme/ui/ErrorBoundary/ErrorBoundary.tsx +46 -0
  29. package/src/client/theme/ui/ErrorBoundary/index.ts +1 -0
  30. package/src/client/theme/ui/Layout/Layout.tsx +8 -1
  31. package/src/client/theme/ui/Link/link-preview.css +1 -20
  32. package/src/client/theme/ui/Navbar/Tabs.tsx +37 -12
  33. package/src/client/theme/ui/Navbar/navbar.css +26 -18
  34. package/src/client/theme/ui/OnThisPage/OnThisPage.tsx +1 -8
  35. package/src/client/theme/ui/ProgressBar/ProgressBar.css +17 -0
  36. package/src/client/theme/ui/ProgressBar/ProgressBar.tsx +51 -0
  37. package/src/client/theme/ui/ProgressBar/index.ts +1 -0
  38. package/src/client/theme/ui/SearchDialog/SearchDialog.tsx +11 -1
  39. package/src/client/types.ts +2 -0
  40. package/src/node/routes/index.ts +1 -0
  41. package/src/node/routes/parser.ts +11 -0
  42. package/src/node/routes/types.ts +2 -0
@@ -839,8 +839,29 @@ var init_GithubStars = __esm({
839
839
  // src/client/theme/ui/Navbar/Tabs.tsx
840
840
  function Tabs({ tabs, routes }) {
841
841
  const location = (0, import_react_router_dom4.useLocation)();
842
+ const containerRef = (0, import_react8.useRef)(null);
843
+ const tabRefs = (0, import_react8.useRef)([]);
844
+ const [indicatorStyle, setIndicatorStyle] = (0, import_react8.useState)({
845
+ opacity: 0,
846
+ transform: "translateX(0) scaleX(0)",
847
+ width: 0
848
+ });
842
849
  const currentRoute = routes.find((r) => r.path === location.pathname);
843
850
  const currentTabId = currentRoute?.tab?.toLowerCase();
851
+ const activeIndex = tabs.findIndex(
852
+ (tab) => currentTabId ? currentTabId === tab.id.toLowerCase() : false
853
+ );
854
+ const finalActiveIndex = activeIndex === -1 ? 0 : activeIndex;
855
+ (0, import_react8.useEffect)(() => {
856
+ const activeTab = tabRefs.current[finalActiveIndex];
857
+ if (activeTab) {
858
+ setIndicatorStyle({
859
+ opacity: 1,
860
+ width: activeTab.offsetWidth,
861
+ transform: `translateX(${activeTab.offsetLeft}px)`
862
+ });
863
+ }
864
+ }, [finalActiveIndex, tabs, location.pathname]);
844
865
  if (!tabs || tabs.length === 0) return null;
845
866
  const renderTabIcon = (iconName) => {
846
867
  if (!iconName) return null;
@@ -859,28 +880,37 @@ function Tabs({ tabs, routes }) {
859
880
  }
860
881
  return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("img", { src: iconName, alt: "", className: "tab-icon img-icon" });
861
882
  };
862
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { className: "boltdocs-tabs-container", children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { className: "boltdocs-tabs", children: tabs.map((tab, index) => {
863
- const isActive = currentTabId ? currentTabId === tab.id.toLowerCase() : index === 0;
864
- const firstRoute = routes.find((r) => r.tab && r.tab.toLowerCase() === tab.id.toLowerCase());
865
- const linkTo = firstRoute ? firstRoute.path : "#";
866
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
867
- Link,
868
- {
869
- to: linkTo,
870
- className: `boltdocs-tab-item ${isActive ? "active" : ""}`,
871
- children: [
872
- renderTabIcon(tab.icon),
873
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("span", { children: tab.text })
874
- ]
875
- },
876
- tab.id
877
- );
878
- }) }) });
883
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { className: "boltdocs-tabs-container", children: /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { className: "boltdocs-tabs", ref: containerRef, children: [
884
+ tabs.map((tab, index) => {
885
+ const isActive = index === finalActiveIndex;
886
+ const firstRoute = routes.find(
887
+ (r) => r.tab && r.tab.toLowerCase() === tab.id.toLowerCase()
888
+ );
889
+ const linkTo = firstRoute ? firstRoute.path : "#";
890
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
891
+ Link,
892
+ {
893
+ to: linkTo,
894
+ ref: (el) => {
895
+ tabRefs.current[index] = el;
896
+ },
897
+ className: `boltdocs-tab-item ${isActive ? "active" : ""}`,
898
+ children: [
899
+ renderTabIcon(tab.icon),
900
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("span", { children: tab.text })
901
+ ]
902
+ },
903
+ tab.id
904
+ );
905
+ }),
906
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { className: "boltdocs-tab-indicator", style: indicatorStyle })
907
+ ] }) });
879
908
  }
880
- var import_react_router_dom4, Icons, import_jsx_runtime11;
909
+ var import_react8, import_react_router_dom4, Icons, import_jsx_runtime11;
881
910
  var init_Tabs = __esm({
882
911
  "src/client/theme/ui/Navbar/Tabs.tsx"() {
883
912
  "use strict";
913
+ import_react8 = require("react");
884
914
  import_react_router_dom4 = require("react-router-dom");
885
915
  init_Link2();
886
916
  Icons = __toESM(require("lucide-react"));
@@ -890,10 +920,10 @@ var init_Tabs = __esm({
890
920
 
891
921
  // src/client/theme/ui/SearchDialog/SearchDialog.tsx
892
922
  function SearchDialog({ routes }) {
893
- const [isOpen, setIsOpen] = (0, import_react8.useState)(false);
894
- const [query, setQuery] = (0, import_react8.useState)("");
895
- const inputRef = (0, import_react8.useRef)(null);
896
- (0, import_react8.useEffect)(() => {
923
+ const [isOpen, setIsOpen] = (0, import_react9.useState)(false);
924
+ const [query, setQuery] = (0, import_react9.useState)("");
925
+ const inputRef = (0, import_react9.useRef)(null);
926
+ (0, import_react9.useEffect)(() => {
897
927
  const handleKeyDown = (e) => {
898
928
  if ((e.metaKey || e.ctrlKey) && e.key === "k") {
899
929
  e.preventDefault();
@@ -906,14 +936,14 @@ function SearchDialog({ routes }) {
906
936
  window.addEventListener("keydown", handleKeyDown);
907
937
  return () => window.removeEventListener("keydown", handleKeyDown);
908
938
  }, [isOpen]);
909
- (0, import_react8.useEffect)(() => {
939
+ (0, import_react9.useEffect)(() => {
910
940
  if (isOpen) {
911
941
  setTimeout(() => inputRef.current?.focus(), 50);
912
942
  } else {
913
943
  setQuery("");
914
944
  }
915
945
  }, [isOpen]);
916
- const searchResults = import_react8.default.useMemo(() => {
946
+ const searchResults = import_react9.default.useMemo(() => {
917
947
  if (!query) {
918
948
  return routes.slice(0, 10).map((r) => ({
919
949
  title: r.title,
@@ -943,6 +973,13 @@ function SearchDialog({ routes }) {
943
973
  }
944
974
  }
945
975
  }
976
+ if (route._content && route._content.toLowerCase().includes(lowerQuery)) {
977
+ results.push({
978
+ title: route.title,
979
+ path: route.path,
980
+ groupTitle: route.groupTitle
981
+ });
982
+ }
946
983
  }
947
984
  const uniqueResults = [];
948
985
  const seenPaths = /* @__PURE__ */ new Set();
@@ -1063,11 +1100,11 @@ function SearchDialog({ routes }) {
1063
1100
  )
1064
1101
  ] });
1065
1102
  }
1066
- var import_react8, import_react_dom2, import_lucide_react4, import_jsx_runtime12;
1103
+ var import_react9, import_react_dom2, import_lucide_react4, import_jsx_runtime12;
1067
1104
  var init_SearchDialog = __esm({
1068
1105
  "src/client/theme/ui/SearchDialog/SearchDialog.tsx"() {
1069
1106
  "use strict";
1070
- import_react8 = __toESM(require("react"));
1107
+ import_react9 = __toESM(require("react"));
1071
1108
  import_react_dom2 = require("react-dom");
1072
1109
  init_Link2();
1073
1110
  import_lucide_react4 = require("lucide-react");
@@ -1173,7 +1210,7 @@ function Navbar({
1173
1210
  ] }),
1174
1211
  /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", { className: "navbar-right", children: [
1175
1212
  /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("nav", { className: "navbar-links", "aria-label": "Top Navigation Right", children: rightItems.map(renderNavItem) }),
1176
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react9.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", { className: "navbar-search-placeholder" }), children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(SearchDialog2, { routes: routes || [] }) }),
1213
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react10.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", { className: "navbar-search-placeholder" }), children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(SearchDialog2, { routes: routes || [] }) }),
1177
1214
  config.i18n && currentLocale && allRoutes && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
1178
1215
  LanguageSwitcher,
1179
1216
  {
@@ -1213,11 +1250,11 @@ function Navbar({
1213
1250
  )
1214
1251
  ] });
1215
1252
  }
1216
- var import_react9, import_react_router_dom5, import_lucide_react5, import_jsx_runtime13, SearchDialog2, ICON_MAP;
1253
+ var import_react10, import_react_router_dom5, import_lucide_react5, import_jsx_runtime13, SearchDialog2, ICON_MAP;
1217
1254
  var init_Navbar = __esm({
1218
1255
  "src/client/theme/ui/Navbar/Navbar.tsx"() {
1219
1256
  "use strict";
1220
- import_react9 = require("react");
1257
+ import_react10 = require("react");
1221
1258
  import_react_router_dom5 = require("react-router-dom");
1222
1259
  import_lucide_react5 = require("lucide-react");
1223
1260
  init_LanguageSwitcher2();
@@ -1228,7 +1265,7 @@ var init_Navbar = __esm({
1228
1265
  init_GithubStars();
1229
1266
  init_Tabs();
1230
1267
  import_jsx_runtime13 = require("react/jsx-runtime");
1231
- SearchDialog2 = (0, import_react9.lazy)(
1268
+ SearchDialog2 = (0, import_react10.lazy)(
1232
1269
  () => Promise.resolve().then(() => (init_SearchDialog2(), SearchDialog_exports)).then((m) => ({ default: m.SearchDialog }))
1233
1270
  );
1234
1271
  ICON_MAP = {
@@ -1405,7 +1442,7 @@ function SidebarGroupSection({
1405
1442
  currentPath
1406
1443
  }) {
1407
1444
  const isActive = group.routes.some((r) => currentPath === r.path);
1408
- const [open, setOpen] = (0, import_react10.useState)(true);
1445
+ const [open, setOpen] = (0, import_react11.useState)(true);
1409
1446
  return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "sidebar-group", children: [
1410
1447
  /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
1411
1448
  "button",
@@ -1437,11 +1474,11 @@ function SidebarGroupSection({
1437
1474
  ) }, route.path)) })
1438
1475
  ] });
1439
1476
  }
1440
- var import_react10, import_react_router_dom6, import_lucide_react7, LucideIcons, import_jsx_runtime15;
1477
+ var import_react11, import_react_router_dom6, import_lucide_react7, LucideIcons, import_jsx_runtime15;
1441
1478
  var init_Sidebar = __esm({
1442
1479
  "src/client/theme/ui/Sidebar/Sidebar.tsx"() {
1443
1480
  "use strict";
1444
- import_react10 = require("react");
1481
+ import_react11 = require("react");
1445
1482
  import_react_router_dom6 = require("react-router-dom");
1446
1483
  init_Link2();
1447
1484
  init_PoweredBy2();
@@ -1466,13 +1503,13 @@ function OnThisPage({
1466
1503
  communityHelp,
1467
1504
  filePath
1468
1505
  }) {
1469
- const [activeId, setActiveId] = (0, import_react11.useState)(null);
1470
- const [indicatorStyle, setIndicatorStyle] = (0, import_react11.useState)({});
1471
- const observerRef = (0, import_react11.useRef)(null);
1506
+ const [activeId, setActiveId] = (0, import_react12.useState)(null);
1507
+ const [indicatorStyle, setIndicatorStyle] = (0, import_react12.useState)({});
1508
+ const observerRef = (0, import_react12.useRef)(null);
1472
1509
  const location = (0, import_react_router_dom7.useLocation)();
1473
- const listRef = (0, import_react11.useRef)(null);
1474
- const visibleIdsRef = (0, import_react11.useRef)(/* @__PURE__ */ new Set());
1475
- (0, import_react11.useEffect)(() => {
1510
+ const listRef = (0, import_react12.useRef)(null);
1511
+ const visibleIdsRef = (0, import_react12.useRef)(/* @__PURE__ */ new Set());
1512
+ (0, import_react12.useEffect)(() => {
1476
1513
  if (headings.length > 0) {
1477
1514
  const hash = window.location.hash.substring(1);
1478
1515
  if (hash && headings.some((h) => h.id === hash)) {
@@ -1482,7 +1519,7 @@ function OnThisPage({
1482
1519
  }
1483
1520
  }
1484
1521
  }, [location.pathname, headings]);
1485
- (0, import_react11.useEffect)(() => {
1522
+ (0, import_react12.useEffect)(() => {
1486
1523
  if (!activeId || !listRef.current) return;
1487
1524
  const activeLink = listRef.current.querySelector(
1488
1525
  `a[href="#${activeId}"]`
@@ -1497,7 +1534,7 @@ function OnThisPage({
1497
1534
  });
1498
1535
  }
1499
1536
  }, [activeId, headings]);
1500
- (0, import_react11.useEffect)(() => {
1537
+ (0, import_react12.useEffect)(() => {
1501
1538
  if (headings.length === 0) return;
1502
1539
  visibleIdsRef.current.clear();
1503
1540
  if (observerRef.current) {
@@ -1555,7 +1592,7 @@ function OnThisPage({
1555
1592
  window.removeEventListener("scroll", handleScroll);
1556
1593
  };
1557
1594
  }, [headings, location.pathname]);
1558
- (0, import_react11.useEffect)(() => {
1595
+ (0, import_react12.useEffect)(() => {
1559
1596
  if (!activeId || !listRef.current) return;
1560
1597
  const activeLink = listRef.current.querySelector(
1561
1598
  `a[href="#${activeId}"]`
@@ -1574,18 +1611,12 @@ function OnThisPage({
1574
1611
  }
1575
1612
  }
1576
1613
  }, [activeId]);
1577
- const handleClick = (0, import_react11.useCallback)(
1614
+ const handleClick = (0, import_react12.useCallback)(
1578
1615
  (e, id) => {
1579
1616
  e.preventDefault();
1580
1617
  const el = document.getElementById(id);
1581
1618
  if (el) {
1582
- const offset = 80;
1583
- const bodyRect = document.body.getBoundingClientRect().top;
1584
- const elementRect = el.getBoundingClientRect().top;
1585
- const elementPosition = elementRect - bodyRect;
1586
- const offsetPosition = elementPosition - offset;
1587
- window.scrollTo({
1588
- top: offsetPosition,
1619
+ el.scrollIntoView({
1589
1620
  behavior: "smooth"
1590
1621
  });
1591
1622
  setActiveId(id);
@@ -1643,11 +1674,11 @@ function OnThisPage({
1643
1674
  ] })
1644
1675
  ] });
1645
1676
  }
1646
- var import_react11, import_react_router_dom7, import_lucide_react8, import_jsx_runtime16;
1677
+ var import_react12, import_react_router_dom7, import_lucide_react8, import_jsx_runtime16;
1647
1678
  var init_OnThisPage = __esm({
1648
1679
  "src/client/theme/ui/OnThisPage/OnThisPage.tsx"() {
1649
1680
  "use strict";
1650
- import_react11 = require("react");
1681
+ import_react12 = require("react");
1651
1682
  import_react_router_dom7 = require("react-router-dom");
1652
1683
  import_lucide_react8 = require("lucide-react");
1653
1684
  import_jsx_runtime16 = require("react/jsx-runtime");
@@ -1665,7 +1696,7 @@ var init_OnThisPage2 = __esm({
1665
1696
  // src/client/theme/ui/Head/Head.tsx
1666
1697
  function Head({ siteTitle, siteDescription, routes }) {
1667
1698
  const location = (0, import_react_router_dom8.useLocation)();
1668
- (0, import_react12.useEffect)(() => {
1699
+ (0, import_react13.useEffect)(() => {
1669
1700
  const currentRoute = routes.find((r) => r.path === location.pathname);
1670
1701
  const pageTitle = currentRoute?.title;
1671
1702
  const pageDescription = currentRoute?.description || siteDescription || "";
@@ -1709,11 +1740,11 @@ function setMetaTag(attr, key, content) {
1709
1740
  }
1710
1741
  tag.content = content;
1711
1742
  }
1712
- var import_react12, import_react_router_dom8;
1743
+ var import_react13, import_react_router_dom8;
1713
1744
  var init_Head = __esm({
1714
1745
  "src/client/theme/ui/Head/Head.tsx"() {
1715
1746
  "use strict";
1716
- import_react12 = require("react");
1747
+ import_react13 = require("react");
1717
1748
  import_react_router_dom8 = require("react-router-dom");
1718
1749
  }
1719
1750
  });
@@ -1794,6 +1825,118 @@ var init_BackgroundGradient2 = __esm({
1794
1825
  }
1795
1826
  });
1796
1827
 
1828
+ // src/client/theme/ui/ProgressBar/ProgressBar.css
1829
+ var init_ProgressBar = __esm({
1830
+ "src/client/theme/ui/ProgressBar/ProgressBar.css"() {
1831
+ }
1832
+ });
1833
+
1834
+ // src/client/theme/ui/ProgressBar/ProgressBar.tsx
1835
+ function ProgressBar() {
1836
+ const [progress, setProgress] = (0, import_react14.useState)(0);
1837
+ (0, import_react14.useEffect)(() => {
1838
+ let container = null;
1839
+ let timer;
1840
+ const handleScroll = () => {
1841
+ if (!container) return;
1842
+ const { scrollTop, scrollHeight, clientHeight } = container;
1843
+ if (scrollHeight <= clientHeight) {
1844
+ setProgress(0);
1845
+ return;
1846
+ }
1847
+ const scrollPercent = scrollTop / (scrollHeight - clientHeight) * 100;
1848
+ setProgress(Math.min(100, Math.max(0, scrollPercent)));
1849
+ };
1850
+ const attachListener = () => {
1851
+ container = document.querySelector(".boltdocs-content");
1852
+ if (container) {
1853
+ container.addEventListener("scroll", handleScroll);
1854
+ handleScroll();
1855
+ if (timer) clearInterval(timer);
1856
+ return true;
1857
+ }
1858
+ return false;
1859
+ };
1860
+ if (!attachListener()) {
1861
+ timer = setInterval(attachListener, 100);
1862
+ }
1863
+ return () => {
1864
+ if (container) container.removeEventListener("scroll", handleScroll);
1865
+ if (timer) clearInterval(timer);
1866
+ };
1867
+ }, []);
1868
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className: "boltdocs-progress-container", children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
1869
+ "div",
1870
+ {
1871
+ className: "boltdocs-progress-bar",
1872
+ style: { width: `${progress}%` }
1873
+ }
1874
+ ) });
1875
+ }
1876
+ var import_react14, import_jsx_runtime19;
1877
+ var init_ProgressBar2 = __esm({
1878
+ "src/client/theme/ui/ProgressBar/ProgressBar.tsx"() {
1879
+ "use strict";
1880
+ import_react14 = require("react");
1881
+ init_ProgressBar();
1882
+ import_jsx_runtime19 = require("react/jsx-runtime");
1883
+ }
1884
+ });
1885
+
1886
+ // src/client/theme/ui/ProgressBar/index.ts
1887
+ var init_ProgressBar3 = __esm({
1888
+ "src/client/theme/ui/ProgressBar/index.ts"() {
1889
+ "use strict";
1890
+ init_ProgressBar2();
1891
+ }
1892
+ });
1893
+
1894
+ // src/client/theme/ui/ErrorBoundary/ErrorBoundary.tsx
1895
+ var import_react15, import_jsx_runtime20, ErrorBoundary;
1896
+ var init_ErrorBoundary = __esm({
1897
+ "src/client/theme/ui/ErrorBoundary/ErrorBoundary.tsx"() {
1898
+ "use strict";
1899
+ import_react15 = require("react");
1900
+ import_jsx_runtime20 = require("react/jsx-runtime");
1901
+ ErrorBoundary = class extends import_react15.Component {
1902
+ state = {
1903
+ hasError: false
1904
+ };
1905
+ static getDerivedStateFromError(error) {
1906
+ return { hasError: true, error };
1907
+ }
1908
+ componentDidCatch(error, errorInfo) {
1909
+ console.error("Uncaught error in Boltdocs Layout:", error, errorInfo);
1910
+ }
1911
+ render() {
1912
+ if (this.state.hasError) {
1913
+ return this.props.fallback || /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", { className: "boltdocs-error-boundary", children: [
1914
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", { className: "boltdocs-error-title", children: "Something went wrong" }),
1915
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("p", { className: "boltdocs-error-message", children: this.state.error?.message || "An unexpected error occurred while rendering this page." }),
1916
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
1917
+ "button",
1918
+ {
1919
+ className: "boltdocs-error-retry",
1920
+ onClick: () => this.setState({ hasError: false }),
1921
+ children: "Try again"
1922
+ }
1923
+ )
1924
+ ] });
1925
+ }
1926
+ return this.props.children;
1927
+ }
1928
+ };
1929
+ }
1930
+ });
1931
+
1932
+ // src/client/theme/ui/ErrorBoundary/index.ts
1933
+ var init_ErrorBoundary2 = __esm({
1934
+ "src/client/theme/ui/ErrorBoundary/index.ts"() {
1935
+ "use strict";
1936
+ init_ErrorBoundary();
1937
+ }
1938
+ });
1939
+
1797
1940
  // src/client/theme/styles.css
1798
1941
  var init_styles = __esm({
1799
1942
  "src/client/theme/styles.css"() {
@@ -1832,13 +1975,14 @@ function ThemeLayout({
1832
1975
  const prevPage = localIndex > 0 ? filteredRoutes[localIndex - 1] : null;
1833
1976
  const nextPage = localIndex >= 0 && localIndex < filteredRoutes.length - 1 ? filteredRoutes[localIndex + 1] : null;
1834
1977
  const { preload } = usePreload();
1835
- import_react13.default.useEffect(() => {
1978
+ import_react16.default.useEffect(() => {
1836
1979
  if (prevPage?.path) preload(prevPage.path);
1837
1980
  if (nextPage?.path) preload(nextPage.path);
1838
1981
  }, [prevPage, nextPage, preload]);
1839
- return /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: `boltdocs-layout ${className}`, style, children: [
1840
- background !== void 0 ? background : /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(BackgroundGradient, {}),
1841
- head !== void 0 ? head : /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
1982
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: `boltdocs-layout ${className}`, style, children: [
1983
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(ProgressBar, {}),
1984
+ background !== void 0 ? background : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(BackgroundGradient, {}),
1985
+ head !== void 0 ? head : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
1842
1986
  Head,
1843
1987
  {
1844
1988
  siteTitle,
@@ -1846,7 +1990,7 @@ function ThemeLayout({
1846
1990
  routes
1847
1991
  }
1848
1992
  ),
1849
- navbar !== void 0 ? navbar : /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
1993
+ navbar !== void 0 ? navbar : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
1850
1994
  Navbar,
1851
1995
  {
1852
1996
  config,
@@ -1856,43 +2000,43 @@ function ThemeLayout({
1856
2000
  currentVersion
1857
2001
  }
1858
2002
  ),
1859
- /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "boltdocs-main-container", children: [
1860
- sidebar !== void 0 ? sidebar : /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Sidebar, { routes: filteredRoutes, config }),
1861
- /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("main", { className: "boltdocs-content", children: [
1862
- breadcrumbs !== void 0 ? breadcrumbs : /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Breadcrumbs, { routes: filteredRoutes, config }),
1863
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className: "boltdocs-page", children }),
1864
- (prevPage || nextPage) && /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("nav", { className: "page-nav", "aria-label": "Pagination", children: [
1865
- prevPage ? /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(
2003
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "boltdocs-main-container", children: [
2004
+ sidebar !== void 0 ? sidebar : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(Sidebar, { routes: filteredRoutes, config }),
2005
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("main", { className: "boltdocs-content", children: [
2006
+ breadcrumbs !== void 0 ? breadcrumbs : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(Breadcrumbs, { routes: filteredRoutes, config }),
2007
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "boltdocs-page", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(ErrorBoundary, { children }) }),
2008
+ (prevPage || nextPage) && /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("nav", { className: "page-nav", "aria-label": "Pagination", children: [
2009
+ prevPage ? /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
1866
2010
  Link,
1867
2011
  {
1868
2012
  to: prevPage.path || "/",
1869
2013
  className: "page-nav-link page-nav-link--prev",
1870
2014
  children: [
1871
- /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "page-nav-info", children: [
1872
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { className: "page-nav-label", children: "Previous" }),
1873
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { className: "page-nav-title", children: prevPage.title })
2015
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "page-nav-info", children: [
2016
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", { className: "page-nav-label", children: "Previous" }),
2017
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", { className: "page-nav-title", children: prevPage.title })
1874
2018
  ] }),
1875
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_lucide_react10.ChevronLeft, { className: "page-nav-arrow", size: 16 })
2019
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_lucide_react10.ChevronLeft, { className: "page-nav-arrow", size: 16 })
1876
2020
  ]
1877
2021
  }
1878
- ) : /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", {}),
1879
- nextPage ? /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(
2022
+ ) : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", {}),
2023
+ nextPage ? /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
1880
2024
  Link,
1881
2025
  {
1882
2026
  to: nextPage.path || "/",
1883
2027
  className: "page-nav-link page-nav-link--next",
1884
2028
  children: [
1885
- /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "page-nav-info", children: [
1886
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { className: "page-nav-label", children: "Next" }),
1887
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { className: "page-nav-title", children: nextPage.title })
2029
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "page-nav-info", children: [
2030
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", { className: "page-nav-label", children: "Next" }),
2031
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", { className: "page-nav-title", children: nextPage.title })
1888
2032
  ] }),
1889
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_lucide_react10.ChevronRight, { className: "page-nav-arrow", size: 16 })
2033
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_lucide_react10.ChevronRight, { className: "page-nav-arrow", size: 16 })
1890
2034
  ]
1891
2035
  }
1892
- ) : /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", {})
2036
+ ) : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", {})
1893
2037
  ] })
1894
2038
  ] }),
1895
- toc !== void 0 ? toc : /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
2039
+ toc !== void 0 ? toc : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
1896
2040
  OnThisPage,
1897
2041
  {
1898
2042
  headings: routes[currentIndex]?.headings,
@@ -1904,11 +2048,11 @@ function ThemeLayout({
1904
2048
  ] })
1905
2049
  ] });
1906
2050
  }
1907
- var import_react13, import_react_router_dom10, import_lucide_react10, import_jsx_runtime19;
2051
+ var import_react16, import_react_router_dom10, import_lucide_react10, import_jsx_runtime21;
1908
2052
  var init_Layout = __esm({
1909
2053
  "src/client/theme/ui/Layout/Layout.tsx"() {
1910
2054
  "use strict";
1911
- import_react13 = __toESM(require("react"));
2055
+ import_react16 = __toESM(require("react"));
1912
2056
  import_react_router_dom10 = require("react-router-dom");
1913
2057
  init_Link2();
1914
2058
  import_lucide_react10 = require("lucide-react");
@@ -1925,8 +2069,10 @@ var init_Layout = __esm({
1925
2069
  init_Head2();
1926
2070
  init_Breadcrumbs2();
1927
2071
  init_BackgroundGradient2();
2072
+ init_ProgressBar3();
2073
+ init_ErrorBoundary2();
1928
2074
  init_styles();
1929
- import_jsx_runtime19 = require("react/jsx-runtime");
2075
+ import_jsx_runtime21 = require("react/jsx-runtime");
1930
2076
  }
1931
2077
  });
1932
2078
 
@@ -1940,23 +2086,23 @@ var init_Layout2 = __esm({
1940
2086
 
1941
2087
  // src/client/theme/ui/NotFound/NotFound.tsx
1942
2088
  function NotFound() {
1943
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", { className: "boltdocs-not-found", children: /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", { className: "not-found-content", children: [
1944
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("span", { className: "not-found-code", children: "404" }),
1945
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("h1", { className: "not-found-title", children: "Page Not Found" }),
1946
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("p", { className: "not-found-text", children: "The page you're looking for doesn't exist or has been moved." }),
1947
- /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)(Link, { to: "/", className: "not-found-link", children: [
1948
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_lucide_react11.ArrowLeft, { size: 16 }),
2089
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("div", { className: "boltdocs-not-found", children: /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "not-found-content", children: [
2090
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("span", { className: "not-found-code", children: "404" }),
2091
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("h1", { className: "not-found-title", children: "Page Not Found" }),
2092
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("p", { className: "not-found-text", children: "The page you're looking for doesn't exist or has been moved." }),
2093
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(Link, { to: "/", className: "not-found-link", children: [
2094
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_lucide_react11.ArrowLeft, { size: 16 }),
1949
2095
  " Go to Home"
1950
2096
  ] })
1951
2097
  ] }) });
1952
2098
  }
1953
- var import_lucide_react11, import_jsx_runtime20;
2099
+ var import_lucide_react11, import_jsx_runtime22;
1954
2100
  var init_NotFound = __esm({
1955
2101
  "src/client/theme/ui/NotFound/NotFound.tsx"() {
1956
2102
  "use strict";
1957
2103
  init_Link2();
1958
2104
  import_lucide_react11 = require("lucide-react");
1959
- import_jsx_runtime20 = require("react/jsx-runtime");
2105
+ import_jsx_runtime22 = require("react/jsx-runtime");
1960
2106
  }
1961
2107
  });
1962
2108
 
@@ -1970,16 +2116,16 @@ var init_NotFound2 = __esm({
1970
2116
 
1971
2117
  // src/client/theme/ui/Loading/Loading.tsx
1972
2118
  function Loading() {
1973
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "boltdocs-loading", children: [
1974
- /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "loading-spinner" }),
1975
- /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("p", { className: "loading-text", children: "Loading..." })
2119
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: "boltdocs-loading", children: [
2120
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: "loading-spinner" }),
2121
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("p", { className: "loading-text", children: "Loading..." })
1976
2122
  ] });
1977
2123
  }
1978
- var import_jsx_runtime21;
2124
+ var import_jsx_runtime23;
1979
2125
  var init_Loading = __esm({
1980
2126
  "src/client/theme/ui/Loading/Loading.tsx"() {
1981
2127
  "use strict";
1982
- import_jsx_runtime21 = require("react/jsx-runtime");
2128
+ import_jsx_runtime23 = require("react/jsx-runtime");
1983
2129
  }
1984
2130
  });
1985
2131
 
@@ -1993,35 +2139,35 @@ var init_Loading2 = __esm({
1993
2139
 
1994
2140
  // src/client/theme/components/CodeBlock/CodeBlock.tsx
1995
2141
  function CodeBlock({ children, ...props }) {
1996
- const [copied, setCopied] = (0, import_react14.useState)(false);
1997
- const preRef = (0, import_react14.useRef)(null);
1998
- const handleCopy = (0, import_react14.useCallback)(async () => {
2142
+ const [copied, setCopied] = (0, import_react17.useState)(false);
2143
+ const preRef = (0, import_react17.useRef)(null);
2144
+ const handleCopy = (0, import_react17.useCallback)(async () => {
1999
2145
  const code = preRef.current?.textContent || "";
2000
2146
  copyToClipboard(code);
2001
2147
  setCopied(true);
2002
2148
  setTimeout(() => setCopied(false), 2e3);
2003
2149
  }, []);
2004
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "code-block-wrapper", children: [
2005
- /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
2150
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: "code-block-wrapper", children: [
2151
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
2006
2152
  "button",
2007
2153
  {
2008
2154
  className: `code-block-copy ${copied ? "copied" : ""}`,
2009
2155
  onClick: handleCopy,
2010
2156
  "aria-label": "Copy code",
2011
- children: copied ? /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_lucide_react12.Check, { size: 16 }) : /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_lucide_react12.Copy, { size: 16 })
2157
+ children: copied ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_lucide_react12.Check, { size: 16 }) : /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_lucide_react12.Copy, { size: 16 })
2012
2158
  }
2013
2159
  ),
2014
- /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("pre", { ref: preRef, ...props, children })
2160
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("pre", { ref: preRef, ...props, children })
2015
2161
  ] });
2016
2162
  }
2017
- var import_react14, import_lucide_react12, import_jsx_runtime22;
2163
+ var import_react17, import_lucide_react12, import_jsx_runtime24;
2018
2164
  var init_CodeBlock = __esm({
2019
2165
  "src/client/theme/components/CodeBlock/CodeBlock.tsx"() {
2020
2166
  "use strict";
2021
- import_react14 = require("react");
2167
+ import_react17 = require("react");
2022
2168
  import_lucide_react12 = require("lucide-react");
2023
2169
  init_utils();
2024
- import_jsx_runtime22 = require("react/jsx-runtime");
2170
+ import_jsx_runtime24 = require("react/jsx-runtime");
2025
2171
  }
2026
2172
  });
2027
2173
 
@@ -2043,9 +2189,9 @@ function Video({
2043
2189
  preload = "metadata",
2044
2190
  ...rest
2045
2191
  }) {
2046
- const containerRef = (0, import_react15.useRef)(null);
2047
- const [isVisible, setIsVisible] = (0, import_react15.useState)(false);
2048
- (0, import_react15.useEffect)(() => {
2192
+ const containerRef = (0, import_react18.useRef)(null);
2193
+ const [isVisible, setIsVisible] = (0, import_react18.useState)(false);
2194
+ (0, import_react18.useEffect)(() => {
2049
2195
  const el = containerRef.current;
2050
2196
  if (!el) return;
2051
2197
  const observer = new IntersectionObserver(
@@ -2060,7 +2206,7 @@ function Video({
2060
2206
  observer.observe(el);
2061
2207
  return () => observer.disconnect();
2062
2208
  }, []);
2063
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { ref: containerRef, className: "boltdocs-video-wrapper", children: isVisible ? /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
2209
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { ref: containerRef, className: "boltdocs-video-wrapper", children: isVisible ? /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
2064
2210
  "video",
2065
2211
  {
2066
2212
  className: "boltdocs-video",
@@ -2075,7 +2221,7 @@ function Video({
2075
2221
  "Your browser does not support the video tag."
2076
2222
  ]
2077
2223
  }
2078
- ) : /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
2224
+ ) : /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
2079
2225
  "div",
2080
2226
  {
2081
2227
  className: "boltdocs-video-placeholder",
@@ -2084,12 +2230,12 @@ function Video({
2084
2230
  }
2085
2231
  ) });
2086
2232
  }
2087
- var import_react15, import_jsx_runtime23;
2233
+ var import_react18, import_jsx_runtime25;
2088
2234
  var init_Video = __esm({
2089
2235
  "src/client/theme/components/Video/Video.tsx"() {
2090
2236
  "use strict";
2091
- import_react15 = require("react");
2092
- import_jsx_runtime23 = require("react/jsx-runtime");
2237
+ import_react18 = require("react");
2238
+ import_jsx_runtime25 = require("react/jsx-runtime");
2093
2239
  }
2094
2240
  });
2095
2241
 
@@ -2106,14 +2252,14 @@ var init_Video2 = __esm({
2106
2252
  });
2107
2253
 
2108
2254
  // src/client/theme/icons/npm.tsx
2109
- var import_jsx_runtime24, NPM;
2255
+ var import_jsx_runtime26, NPM;
2110
2256
  var init_npm = __esm({
2111
2257
  "src/client/theme/icons/npm.tsx"() {
2112
2258
  "use strict";
2113
- import_jsx_runtime24 = require("react/jsx-runtime");
2114
- NPM = (props) => /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("svg", { ...props, viewBox: "0 0 2500 2500", children: [
2115
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("path", { fill: "#c00", d: "M0 0h2500v2500H0z" }),
2116
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
2259
+ import_jsx_runtime26 = require("react/jsx-runtime");
2260
+ NPM = (props) => /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("svg", { ...props, viewBox: "0 0 2500 2500", children: [
2261
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("path", { fill: "#c00", d: "M0 0h2500v2500H0z" }),
2262
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2117
2263
  "path",
2118
2264
  {
2119
2265
  fill: "#fff",
@@ -2125,69 +2271,69 @@ var init_npm = __esm({
2125
2271
  });
2126
2272
 
2127
2273
  // src/client/theme/icons/pnpm.tsx
2128
- var import_jsx_runtime25, Pnpm;
2274
+ var import_jsx_runtime27, Pnpm;
2129
2275
  var init_pnpm = __esm({
2130
2276
  "src/client/theme/icons/pnpm.tsx"() {
2131
2277
  "use strict";
2132
- import_jsx_runtime25 = require("react/jsx-runtime");
2133
- Pnpm = (props) => /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
2278
+ import_jsx_runtime27 = require("react/jsx-runtime");
2279
+ Pnpm = (props) => /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
2134
2280
  "svg",
2135
2281
  {
2136
2282
  ...props,
2137
2283
  xmlnsXlink: "http://www.w3.org/1999/xlink",
2138
2284
  viewBox: "76.58987244897958 44 164.00775510204068 164",
2139
2285
  children: [
2140
- /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("defs", { children: [
2141
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
2286
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("defs", { children: [
2287
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
2142
2288
  "path",
2143
2289
  {
2144
2290
  d: "M237.6 95L187.6 95L187.6 45L237.6 45L237.6 95Z",
2145
2291
  id: "pnpm_dark__b45vdTD8hs"
2146
2292
  }
2147
2293
  ),
2148
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
2294
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
2149
2295
  "path",
2150
2296
  {
2151
2297
  d: "M182.59 95L132.59 95L132.59 45L182.59 45L182.59 95Z",
2152
2298
  id: "pnpm_dark__a40WtxIl8d"
2153
2299
  }
2154
2300
  ),
2155
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
2301
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
2156
2302
  "path",
2157
2303
  {
2158
2304
  d: "M127.59 95L77.59 95L77.59 45L127.59 45L127.59 95Z",
2159
2305
  id: "pnpm_dark__h2CN9AEEpe"
2160
2306
  }
2161
2307
  ),
2162
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
2308
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
2163
2309
  "path",
2164
2310
  {
2165
2311
  d: "M237.6 150L187.6 150L187.6 100L237.6 100L237.6 150Z",
2166
2312
  id: "pnpm_dark__dqv5133G8"
2167
2313
  }
2168
2314
  ),
2169
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
2315
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
2170
2316
  "path",
2171
2317
  {
2172
2318
  d: "M182.59 150L132.59 150L132.59 100L182.59 100L182.59 150Z",
2173
2319
  id: "pnpm_dark__b1Lv79ypvm"
2174
2320
  }
2175
2321
  ),
2176
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
2322
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
2177
2323
  "path",
2178
2324
  {
2179
2325
  d: "M182.59 205L132.59 205L132.59 155L182.59 155L182.59 205Z",
2180
2326
  id: "pnpm_dark__hy1IZWwLX"
2181
2327
  }
2182
2328
  ),
2183
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
2329
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
2184
2330
  "path",
2185
2331
  {
2186
2332
  d: "M237.6 205L187.6 205L187.6 155L237.6 155L237.6 205Z",
2187
2333
  id: "pnpm_dark__akQfjxQes"
2188
2334
  }
2189
2335
  ),
2190
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
2336
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
2191
2337
  "path",
2192
2338
  {
2193
2339
  d: "M127.59 205L77.59 205L77.59 155L127.59 155L127.59 205Z",
@@ -2195,15 +2341,15 @@ var init_pnpm = __esm({
2195
2341
  }
2196
2342
  )
2197
2343
  ] }),
2198
- /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("g", { children: [
2199
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("use", { xlinkHref: "#pnpm_dark__b45vdTD8hs", fill: "#f9ad00" }) }),
2200
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("use", { xlinkHref: "#pnpm_dark__a40WtxIl8d", fill: "#f9ad00" }) }),
2201
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("use", { xlinkHref: "#pnpm_dark__h2CN9AEEpe", fill: "#f9ad00" }) }),
2202
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("use", { xlinkHref: "#pnpm_dark__dqv5133G8", fill: "#f9ad00" }) }),
2203
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("use", { xlinkHref: "#pnpm_dark__b1Lv79ypvm", fill: "#ffffff" }) }),
2204
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("use", { xlinkHref: "#pnpm_dark__hy1IZWwLX", fill: "#ffffff" }) }),
2205
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("use", { xlinkHref: "#pnpm_dark__akQfjxQes", fill: "#ffffff" }) }),
2206
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("use", { xlinkHref: "#pnpm_dark__bdSrwE5pk", fill: "#ffffff" }) })
2344
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("g", { children: [
2345
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("use", { xlinkHref: "#pnpm_dark__b45vdTD8hs", fill: "#f9ad00" }) }),
2346
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("use", { xlinkHref: "#pnpm_dark__a40WtxIl8d", fill: "#f9ad00" }) }),
2347
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("use", { xlinkHref: "#pnpm_dark__h2CN9AEEpe", fill: "#f9ad00" }) }),
2348
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("use", { xlinkHref: "#pnpm_dark__dqv5133G8", fill: "#f9ad00" }) }),
2349
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("use", { xlinkHref: "#pnpm_dark__b1Lv79ypvm", fill: "#ffffff" }) }),
2350
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("use", { xlinkHref: "#pnpm_dark__hy1IZWwLX", fill: "#ffffff" }) }),
2351
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("use", { xlinkHref: "#pnpm_dark__akQfjxQes", fill: "#ffffff" }) }),
2352
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("use", { xlinkHref: "#pnpm_dark__bdSrwE5pk", fill: "#ffffff" }) })
2207
2353
  ] })
2208
2354
  ]
2209
2355
  }
@@ -2212,62 +2358,62 @@ var init_pnpm = __esm({
2212
2358
  });
2213
2359
 
2214
2360
  // src/client/theme/icons/bun.tsx
2215
- var import_jsx_runtime26, Bun;
2361
+ var import_jsx_runtime28, Bun;
2216
2362
  var init_bun = __esm({
2217
2363
  "src/client/theme/icons/bun.tsx"() {
2218
2364
  "use strict";
2219
- import_jsx_runtime26 = require("react/jsx-runtime");
2220
- Bun = (props) => /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("svg", { ...props, viewBox: "0 0 80 70", children: [
2221
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("path", { d: "M71.09 20.74c-.16-.17-.33-.34-.5-.5s-.33-.34-.5-.5-.33-.34-.5-.5-.33-.34-.5-.5-.33-.34-.5-.5-.33-.34-.5-.5-.33-.34-.5-.5A26.46 26.46 0 0 1 75.5 35.7c0 16.57-16.82 30.05-37.5 30.05-11.58 0-21.94-4.23-28.83-10.86l.5.5.5.5.5.5.5.5.5.5.5.5.5.5C19.55 65.3 30.14 69.75 42 69.75c20.68 0 37.5-13.48 37.5-30 0-7.06-3.04-13.75-8.41-19.01Z" }),
2222
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2365
+ import_jsx_runtime28 = require("react/jsx-runtime");
2366
+ Bun = (props) => /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("svg", { ...props, viewBox: "0 0 80 70", children: [
2367
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("path", { d: "M71.09 20.74c-.16-.17-.33-.34-.5-.5s-.33-.34-.5-.5-.33-.34-.5-.5-.33-.34-.5-.5-.33-.34-.5-.5-.33-.34-.5-.5-.33-.34-.5-.5A26.46 26.46 0 0 1 75.5 35.7c0 16.57-16.82 30.05-37.5 30.05-11.58 0-21.94-4.23-28.83-10.86l.5.5.5.5.5.5.5.5.5.5.5.5.5.5C19.55 65.3 30.14 69.75 42 69.75c20.68 0 37.5-13.48 37.5-30 0-7.06-3.04-13.75-8.41-19.01Z" }),
2368
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2223
2369
  "path",
2224
2370
  {
2225
2371
  d: "M73 35.7c0 15.21-15.67 27.54-35 27.54S3 50.91 3 35.7C3 26.27 9 17.94 18.22 13S33.18 3 38 3s8.94 4.13 19.78 10C67 17.94 73 26.27 73 35.7Z",
2226
2372
  style: { fill: "#fbf0df" }
2227
2373
  }
2228
2374
  ),
2229
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2375
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2230
2376
  "path",
2231
2377
  {
2232
2378
  d: "M73 35.7a21.67 21.67 0 0 0-.8-5.78c-2.73 33.3-43.35 34.9-59.32 24.94A40 40 0 0 0 38 63.24c19.3 0 35-12.35 35-27.54Z",
2233
2379
  style: { fill: "#f6dece" }
2234
2380
  }
2235
2381
  ),
2236
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2382
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2237
2383
  "path",
2238
2384
  {
2239
2385
  d: "M24.53 11.17C29 8.49 34.94 3.46 40.78 3.45A9.29 9.29 0 0 0 38 3c-2.42 0-5 1.25-8.25 3.13-1.13.66-2.3 1.39-3.54 2.15-2.33 1.44-5 3.07-8 4.7C8.69 18.13 3 26.62 3 35.7v1.19c6.06-21.41 17.07-23.04 21.53-25.72Z",
2240
2386
  style: { fill: "#fffefc" }
2241
2387
  }
2242
2388
  ),
2243
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2389
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2244
2390
  "path",
2245
2391
  {
2246
2392
  d: "M35.12 5.53A16.41 16.41 0 0 1 29.49 18c-.28.25-.06.73.3.59 3.37-1.31 7.92-5.23 6-13.14-.08-.45-.67-.33-.67.08Zm2.27 0A16.24 16.24 0 0 1 39 19c-.12.35.31.65.55.36 2.19-2.8 4.1-8.36-1.62-14.36-.29-.26-.74.14-.54.49Zm2.76-.17A16.42 16.42 0 0 1 47 17.12a.33.33 0 0 0 .65.11c.92-3.49.4-9.44-7.17-12.53-.4-.16-.66.38-.33.62Zm-18.46 10.4a16.94 16.94 0 0 0 10.47-9c.18-.36.75-.22.66.18-1.73 8-7.52 9.67-11.12 9.45-.38.01-.37-.52-.01-.63Z",
2247
2393
  style: { fill: "#ccbea7", fillRule: "evenodd" }
2248
2394
  }
2249
2395
  ),
2250
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("path", { d: "M38 65.75C17.32 65.75.5 52.27.5 35.7c0-10 6.18-19.33 16.53-24.92 3-1.6 5.57-3.21 7.86-4.62 1.26-.78 2.45-1.51 3.6-2.19C32 1.89 35 .5 38 .5s5.62 1.2 8.9 3.14c1 .57 2 1.19 3.07 1.87 2.49 1.54 5.3 3.28 9 5.27C69.32 16.37 75.5 25.69 75.5 35.7c0 16.57-16.82 30.05-37.5 30.05ZM38 3c-2.42 0-5 1.25-8.25 3.13-1.13.66-2.3 1.39-3.54 2.15-2.33 1.44-5 3.07-8 4.7C8.69 18.13 3 26.62 3 35.7c0 15.19 15.7 27.55 35 27.55S73 50.89 73 35.7c0-9.08-5.69-17.57-15.22-22.7-3.78-2-6.73-3.88-9.12-5.36-1.09-.67-2.09-1.29-3-1.84C42.63 4 40.42 3 38 3Z" }),
2251
- /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("g", { children: [
2252
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2396
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("path", { d: "M38 65.75C17.32 65.75.5 52.27.5 35.7c0-10 6.18-19.33 16.53-24.92 3-1.6 5.57-3.21 7.86-4.62 1.26-.78 2.45-1.51 3.6-2.19C32 1.89 35 .5 38 .5s5.62 1.2 8.9 3.14c1 .57 2 1.19 3.07 1.87 2.49 1.54 5.3 3.28 9 5.27C69.32 16.37 75.5 25.69 75.5 35.7c0 16.57-16.82 30.05-37.5 30.05ZM38 3c-2.42 0-5 1.25-8.25 3.13-1.13.66-2.3 1.39-3.54 2.15-2.33 1.44-5 3.07-8 4.7C8.69 18.13 3 26.62 3 35.7c0 15.19 15.7 27.55 35 27.55S73 50.89 73 35.7c0-9.08-5.69-17.57-15.22-22.7-3.78-2-6.73-3.88-9.12-5.36-1.09-.67-2.09-1.29-3-1.84C42.63 4 40.42 3 38 3Z" }),
2397
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("g", { children: [
2398
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2253
2399
  "path",
2254
2400
  {
2255
2401
  d: "M45.05 43a8.93 8.93 0 0 1-2.92 4.71 6.81 6.81 0 0 1-4 1.88A6.84 6.84 0 0 1 34 47.71 8.93 8.93 0 0 1 31.12 43a.72.72 0 0 1 .8-.81h12.34a.72.72 0 0 1 .79.81Z",
2256
2402
  style: { fill: "#b71422" }
2257
2403
  }
2258
2404
  ),
2259
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2405
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2260
2406
  "path",
2261
2407
  {
2262
2408
  d: "M34 47.79a6.91 6.91 0 0 0 4.12 1.9 6.91 6.91 0 0 0 4.11-1.9 10.63 10.63 0 0 0 1-1.07 6.83 6.83 0 0 0-4.9-2.31 6.15 6.15 0 0 0-5 2.78c.23.21.43.41.67.6Z",
2263
2409
  style: { fill: "#ff6164" }
2264
2410
  }
2265
2411
  ),
2266
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("path", { d: "M34.16 47a5.36 5.36 0 0 1 4.19-2.08 6 6 0 0 1 4 1.69c.23-.25.45-.51.66-.77a7 7 0 0 0-4.71-1.93 6.36 6.36 0 0 0-4.89 2.36 9.53 9.53 0 0 0 .75.73Z" }),
2267
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("path", { d: "M38.09 50.19a7.42 7.42 0 0 1-4.45-2 9.52 9.52 0 0 1-3.11-5.05 1.2 1.2 0 0 1 .26-1 1.41 1.41 0 0 1 1.13-.51h12.34a1.44 1.44 0 0 1 1.13.51 1.19 1.19 0 0 1 .25 1 9.52 9.52 0 0 1-3.11 5.05 7.42 7.42 0 0 1-4.44 2Zm-6.17-7.4c-.16 0-.2.07-.21.09a8.29 8.29 0 0 0 2.73 4.37A6.23 6.23 0 0 0 38.09 49a6.28 6.28 0 0 0 3.65-1.73 8.3 8.3 0 0 0 2.72-4.37.21.21 0 0 0-.2-.09Z" })
2412
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("path", { d: "M34.16 47a5.36 5.36 0 0 1 4.19-2.08 6 6 0 0 1 4 1.69c.23-.25.45-.51.66-.77a7 7 0 0 0-4.71-1.93 6.36 6.36 0 0 0-4.89 2.36 9.53 9.53 0 0 0 .75.73Z" }),
2413
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("path", { d: "M38.09 50.19a7.42 7.42 0 0 1-4.45-2 9.52 9.52 0 0 1-3.11-5.05 1.2 1.2 0 0 1 .26-1 1.41 1.41 0 0 1 1.13-.51h12.34a1.44 1.44 0 0 1 1.13.51 1.19 1.19 0 0 1 .25 1 9.52 9.52 0 0 1-3.11 5.05 7.42 7.42 0 0 1-4.44 2Zm-6.17-7.4c-.16 0-.2.07-.21.09a8.29 8.29 0 0 0 2.73 4.37A6.23 6.23 0 0 0 38.09 49a6.28 6.28 0 0 0 3.65-1.73 8.3 8.3 0 0 0 2.72-4.37.21.21 0 0 0-.2-.09Z" })
2268
2414
  ] }),
2269
- /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("g", { children: [
2270
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2415
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("g", { children: [
2416
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2271
2417
  "ellipse",
2272
2418
  {
2273
2419
  cx: "53.22",
@@ -2277,7 +2423,7 @@ var init_bun = __esm({
2277
2423
  style: { fill: "#febbd0" }
2278
2424
  }
2279
2425
  ),
2280
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2426
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2281
2427
  "ellipse",
2282
2428
  {
2283
2429
  cx: "22.95",
@@ -2287,14 +2433,14 @@ var init_bun = __esm({
2287
2433
  style: { fill: "#febbd0" }
2288
2434
  }
2289
2435
  ),
2290
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2436
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2291
2437
  "path",
2292
2438
  {
2293
2439
  d: "M25.7 38.8a5.51 5.51 0 1 0-5.5-5.51 5.51 5.51 0 0 0 5.5 5.51Zm24.77 0A5.51 5.51 0 1 0 45 33.29a5.5 5.5 0 0 0 5.47 5.51Z",
2294
2440
  style: { fillRule: "evenodd" }
2295
2441
  }
2296
2442
  ),
2297
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2443
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2298
2444
  "path",
2299
2445
  {
2300
2446
  d: "M24 33.64a2.07 2.07 0 1 0-2.06-2.07A2.07 2.07 0 0 0 24 33.64Zm24.77 0a2.07 2.07 0 1 0-2.06-2.07 2.07 2.07 0 0 0 2.04 2.07Z",
@@ -2307,12 +2453,12 @@ var init_bun = __esm({
2307
2453
  });
2308
2454
 
2309
2455
  // src/client/theme/icons/deno.tsx
2310
- var import_jsx_runtime27, Deno;
2456
+ var import_jsx_runtime29, Deno;
2311
2457
  var init_deno = __esm({
2312
2458
  "src/client/theme/icons/deno.tsx"() {
2313
2459
  "use strict";
2314
- import_jsx_runtime27 = require("react/jsx-runtime");
2315
- Deno = (props) => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
2460
+ import_jsx_runtime29 = require("react/jsx-runtime");
2461
+ Deno = (props) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2316
2462
  "svg",
2317
2463
  {
2318
2464
  ...props,
@@ -2322,7 +2468,7 @@ var init_deno = __esm({
2322
2468
  strokeMiterlimit: "2",
2323
2469
  clipRule: "evenodd",
2324
2470
  viewBox: "0 0 441 441",
2325
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
2471
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2326
2472
  "path",
2327
2473
  {
2328
2474
  fill: "currentColor",
@@ -2369,19 +2515,19 @@ function PackageManagerTabs({
2369
2515
  pkg = "",
2370
2516
  className = ""
2371
2517
  }) {
2372
- const [activeTab, setActiveTab] = (0, import_react16.useState)("npm");
2373
- const [copied, setCopied] = (0, import_react16.useState)(false);
2518
+ const [activeTab, setActiveTab] = (0, import_react19.useState)("npm");
2519
+ const [copied, setCopied] = (0, import_react19.useState)(false);
2374
2520
  const activeCommand = getCommandForManager(activeTab, command, pkg);
2375
- const handleCopy = (0, import_react16.useCallback)(async () => {
2521
+ const handleCopy = (0, import_react19.useCallback)(async () => {
2376
2522
  copyToClipboard(activeCommand);
2377
2523
  setCopied(true);
2378
2524
  setTimeout(() => setCopied(false), 2e3);
2379
2525
  }, [activeCommand]);
2380
- return /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: `pkg-tabs-wrapper ${className}`, children: [
2381
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { className: "pkg-tabs-header", children: MANAGERS.map((mgr) => {
2526
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: `pkg-tabs-wrapper ${className}`, children: [
2527
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", { className: "pkg-tabs-header", children: MANAGERS.map((mgr) => {
2382
2528
  const Icon = mgr.icon;
2383
2529
  const isActive = activeTab === mgr.id;
2384
- return /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
2530
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(
2385
2531
  "button",
2386
2532
  {
2387
2533
  className: `pkg-tab-btn ${isActive ? "active" : ""}`,
@@ -2389,40 +2535,40 @@ function PackageManagerTabs({
2389
2535
  "aria-selected": isActive,
2390
2536
  role: "tab",
2391
2537
  children: [
2392
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { className: "pkg-tab-icon", width: "16", height: "16" }),
2393
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("span", { children: mgr.label })
2538
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(Icon, { className: "pkg-tab-icon", width: "16", height: "16" }),
2539
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("span", { children: mgr.label })
2394
2540
  ]
2395
2541
  },
2396
2542
  mgr.id
2397
2543
  );
2398
2544
  }) }),
2399
- /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: "code-block-wrapper pkg-tabs-content", children: [
2400
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
2545
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "code-block-wrapper pkg-tabs-content", children: [
2546
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
2401
2547
  "button",
2402
2548
  {
2403
2549
  className: `code-block-copy ${copied ? "copied" : ""}`,
2404
2550
  onClick: handleCopy,
2405
2551
  type: "button",
2406
2552
  "aria-label": "Copy code",
2407
- children: copied ? /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_lucide_react13.Check, { size: 14 }) : /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_lucide_react13.Copy, { size: 14 })
2553
+ children: copied ? /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_lucide_react13.Check, { size: 14 }) : /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_lucide_react13.Copy, { size: 14 })
2408
2554
  }
2409
2555
  ),
2410
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("pre", { children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("code", { children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("span", { className: "line", children: activeCommand }) }) })
2556
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("pre", { children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("code", { children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("span", { className: "line", children: activeCommand }) }) })
2411
2557
  ] })
2412
2558
  ] });
2413
2559
  }
2414
- var import_react16, import_lucide_react13, import_jsx_runtime28, MANAGERS;
2560
+ var import_react19, import_lucide_react13, import_jsx_runtime30, MANAGERS;
2415
2561
  var init_PackageManagerTabs = __esm({
2416
2562
  "src/client/theme/components/PackageManagerTabs/PackageManagerTabs.tsx"() {
2417
2563
  "use strict";
2418
- import_react16 = require("react");
2564
+ import_react19 = require("react");
2419
2565
  import_lucide_react13 = require("lucide-react");
2420
2566
  init_npm();
2421
2567
  init_pnpm();
2422
2568
  init_bun();
2423
2569
  init_deno();
2424
2570
  init_utils();
2425
- import_jsx_runtime28 = require("react/jsx-runtime");
2571
+ import_jsx_runtime30 = require("react/jsx-runtime");
2426
2572
  MANAGERS = [
2427
2573
  { id: "npm", label: "npm", icon: NPM },
2428
2574
  { id: "pnpm", label: "pnpm", icon: Pnpm },
@@ -2446,7 +2592,7 @@ var init_PackageManagerTabs2 = __esm({
2446
2592
 
2447
2593
  // src/client/app/index.tsx
2448
2594
  function useConfig() {
2449
- return (0, import_react19.useContext)(ConfigContext);
2595
+ return (0, import_react22.useContext)(ConfigContext);
2450
2596
  }
2451
2597
  function AppShell({
2452
2598
  initialRoutes,
@@ -2457,8 +2603,8 @@ function AppShell({
2457
2603
  homePage: HomePage,
2458
2604
  components: customComponents = {}
2459
2605
  }) {
2460
- const [routesInfo, setRoutesInfo] = (0, import_react17.useState)(initialRoutes);
2461
- const [config] = (0, import_react17.useState)(initialConfig);
2606
+ const [routesInfo, setRoutesInfo] = (0, import_react20.useState)(initialRoutes);
2607
+ const [config] = (0, import_react20.useState)(initialConfig);
2462
2608
  const resolveRoutes = (infos) => {
2463
2609
  return infos.filter(
2464
2610
  (route) => !(HomePage && (route.path === "/" || route.path === ""))
@@ -2469,35 +2615,35 @@ function AppShell({
2469
2615
  const loader = loaderKey ? modules[loaderKey] : null;
2470
2616
  return {
2471
2617
  ...route,
2472
- Component: import_react17.default.lazy(() => {
2618
+ Component: import_react20.default.lazy(() => {
2473
2619
  if (!loader)
2474
- return Promise.resolve({ default: () => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(NotFound, {}) });
2620
+ return Promise.resolve({ default: () => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(NotFound, {}) });
2475
2621
  return loader();
2476
2622
  })
2477
2623
  };
2478
2624
  });
2479
2625
  };
2480
- const [resolvedRoutes, setResolvedRoutes] = (0, import_react17.useState)(
2626
+ const [resolvedRoutes, setResolvedRoutes] = (0, import_react20.useState)(
2481
2627
  () => resolveRoutes(initialRoutes)
2482
2628
  );
2483
- (0, import_react17.useEffect)(() => {
2629
+ (0, import_react20.useEffect)(() => {
2484
2630
  if (hot) {
2485
2631
  hot.on("boltdocs:routes-update", (newRoutes) => {
2486
2632
  setRoutesInfo(newRoutes);
2487
2633
  });
2488
2634
  }
2489
2635
  }, [hot]);
2490
- (0, import_react17.useEffect)(() => {
2636
+ (0, import_react20.useEffect)(() => {
2491
2637
  setResolvedRoutes(resolveRoutes(routesInfo));
2492
2638
  }, [routesInfo, modules, docsDirName]);
2493
- return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(ConfigContext.Provider, { value: config, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(PreloadProvider, { routes: routesInfo, modules, children: [
2494
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(ScrollHandler, {}),
2495
- /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_react_router_dom11.Routes, { children: [
2496
- HomePage && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2639
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(ConfigContext.Provider, { value: config, children: /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(PreloadProvider, { routes: routesInfo, modules, children: [
2640
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(ScrollHandler, {}),
2641
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(import_react_router_dom11.Routes, { children: [
2642
+ HomePage && /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
2497
2643
  import_react_router_dom11.Route,
2498
2644
  {
2499
2645
  path: "/",
2500
- element: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2646
+ element: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
2501
2647
  ThemeLayout,
2502
2648
  {
2503
2649
  config,
@@ -2506,20 +2652,20 @@ function AppShell({
2506
2652
  toc: null,
2507
2653
  breadcrumbs: null,
2508
2654
  ...config.themeConfig?.layoutProps,
2509
- children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(HomePage, {})
2655
+ children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(HomePage, {})
2510
2656
  }
2511
2657
  )
2512
2658
  }
2513
2659
  ),
2514
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2660
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
2515
2661
  import_react_router_dom11.Route,
2516
2662
  {
2517
- element: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(DocsLayout, { config, routes: routesInfo }),
2518
- children: resolvedRoutes.map((route) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2663
+ element: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(DocsLayout, { config, routes: routesInfo }),
2664
+ children: resolvedRoutes.map((route) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
2519
2665
  import_react_router_dom11.Route,
2520
2666
  {
2521
2667
  path: route.path === "" ? "/" : route.path,
2522
- element: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react17.default.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Loading, {}), children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2668
+ element: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_react20.default.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Loading, {}), children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
2523
2669
  MdxPage,
2524
2670
  {
2525
2671
  Component: route.Component,
@@ -2532,17 +2678,17 @@ function AppShell({
2532
2678
  },
2533
2679
  "docs-layout"
2534
2680
  ),
2535
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2681
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
2536
2682
  import_react_router_dom11.Route,
2537
2683
  {
2538
2684
  path: "*",
2539
- element: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2685
+ element: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
2540
2686
  ThemeLayout,
2541
2687
  {
2542
2688
  config,
2543
2689
  routes: routesInfo,
2544
2690
  ...config.themeConfig?.layoutProps,
2545
- children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(NotFound, {})
2691
+ children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(NotFound, {})
2546
2692
  }
2547
2693
  )
2548
2694
  }
@@ -2552,24 +2698,26 @@ function AppShell({
2552
2698
  }
2553
2699
  function ScrollHandler() {
2554
2700
  const { pathname, hash } = (0, import_react_router_dom11.useLocation)();
2555
- (0, import_react19.useLayoutEffect)(() => {
2701
+ (0, import_react22.useLayoutEffect)(() => {
2702
+ const container = document.querySelector(".boltdocs-content");
2703
+ if (!container) return;
2556
2704
  if (hash) {
2557
2705
  const id = hash.replace("#", "");
2558
2706
  const element = document.getElementById(id);
2559
2707
  if (element) {
2560
2708
  const offset = 80;
2561
- const bodyRect = document.body.getBoundingClientRect().top;
2709
+ const containerRect = container.getBoundingClientRect().top;
2562
2710
  const elementRect = element.getBoundingClientRect().top;
2563
- const elementPosition = elementRect - bodyRect;
2564
- const offsetPosition = elementPosition - offset;
2565
- window.scrollTo({
2711
+ const elementPosition = elementRect - containerRect;
2712
+ const offsetPosition = elementPosition - offset + container.scrollTop;
2713
+ container.scrollTo({
2566
2714
  top: offsetPosition,
2567
2715
  behavior: "smooth"
2568
2716
  });
2569
2717
  return;
2570
2718
  }
2571
2719
  }
2572
- window.scrollTo(0, 0);
2720
+ container.scrollTo(0, 0);
2573
2721
  }, [pathname, hash]);
2574
2722
  return null;
2575
2723
  }
@@ -2577,22 +2725,22 @@ function DocsLayout({
2577
2725
  config,
2578
2726
  routes
2579
2727
  }) {
2580
- return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2728
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
2581
2729
  ThemeLayout,
2582
2730
  {
2583
2731
  config,
2584
2732
  routes,
2585
2733
  ...config.themeConfig?.layoutProps,
2586
- children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_router_dom11.Outlet, {})
2734
+ children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_react_router_dom11.Outlet, {})
2587
2735
  }
2588
2736
  );
2589
2737
  }
2590
2738
  function MdxPage({
2591
- Component,
2739
+ Component: Component2,
2592
2740
  customComponents = {}
2593
2741
  }) {
2594
2742
  const allComponents = { ...mdxComponents, ...customComponents };
2595
- return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react18.MDXProvider, { components: allComponents, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Component, {}) });
2743
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_react21.MDXProvider, { components: allComponents, children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Component2, {}) });
2596
2744
  }
2597
2745
  function createBoltdocsApp(options) {
2598
2746
  const { target, routes, docsDirName, config, modules, hot, homePage } = options;
@@ -2602,7 +2750,7 @@ function createBoltdocsApp(options) {
2602
2750
  `[boltdocs] Mount target "${target}" not found in document.`
2603
2751
  );
2604
2752
  }
2605
- const app = /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react17.default.StrictMode, { children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_router_dom11.BrowserRouter, { children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
2753
+ const app = /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_react20.default.StrictMode, { children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_react_router_dom11.BrowserRouter, { children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
2606
2754
  AppShell,
2607
2755
  {
2608
2756
  initialRoutes: routes,
@@ -2617,27 +2765,27 @@ function createBoltdocsApp(options) {
2617
2765
  container.innerHTML = "";
2618
2766
  import_client.default.createRoot(container).render(app);
2619
2767
  }
2620
- var import_react17, import_client, import_react_router_dom11, import_react18, import_react19, import_lucide_react14, import_jsx_runtime29, ConfigContext, Video2, PackageManagerTabs2, Heading, mdxComponents;
2768
+ var import_react20, import_client, import_react_router_dom11, import_react21, import_react22, import_lucide_react14, import_jsx_runtime31, ConfigContext, Video2, PackageManagerTabs2, Heading, mdxComponents;
2621
2769
  var init_app = __esm({
2622
2770
  "src/client/app/index.tsx"() {
2623
2771
  "use strict";
2624
- import_react17 = __toESM(require("react"));
2772
+ import_react20 = __toESM(require("react"));
2625
2773
  import_client = __toESM(require("react-dom/client"));
2626
2774
  import_react_router_dom11 = require("react-router-dom");
2627
2775
  init_Layout2();
2628
2776
  init_NotFound2();
2629
2777
  init_Loading2();
2630
- import_react18 = require("@mdx-js/react");
2631
- import_react19 = require("react");
2778
+ import_react21 = require("@mdx-js/react");
2779
+ import_react22 = require("react");
2632
2780
  import_lucide_react14 = require("lucide-react");
2633
2781
  init_CodeBlock2();
2634
2782
  init_preload();
2635
- import_jsx_runtime29 = require("react/jsx-runtime");
2636
- ConfigContext = (0, import_react19.createContext)(null);
2637
- Video2 = (0, import_react19.lazy)(
2783
+ import_jsx_runtime31 = require("react/jsx-runtime");
2784
+ ConfigContext = (0, import_react22.createContext)(null);
2785
+ Video2 = (0, import_react22.lazy)(
2638
2786
  () => Promise.resolve().then(() => (init_Video2(), Video_exports)).then((m) => ({ default: m.Video }))
2639
2787
  );
2640
- PackageManagerTabs2 = (0, import_react19.lazy)(
2788
+ PackageManagerTabs2 = (0, import_react22.lazy)(
2641
2789
  () => Promise.resolve().then(() => (init_PackageManagerTabs2(), PackageManagerTabs_exports)).then((m) => ({
2642
2790
  default: m.PackageManagerTabs
2643
2791
  }))
@@ -2648,21 +2796,21 @@ var init_app = __esm({
2648
2796
  children
2649
2797
  }) => {
2650
2798
  const Tag = `h${level}`;
2651
- return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(Tag, { id, className: "boltdocs-heading", children: [
2799
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(Tag, { id, className: "boltdocs-heading", children: [
2652
2800
  children,
2653
- id && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("a", { href: `#${id}`, className: "header-anchor", "aria-label": "Anchor", children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_lucide_react14.Link, { size: 16 }) })
2801
+ id && /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("a", { href: `#${id}`, className: "header-anchor", "aria-label": "Anchor", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_lucide_react14.Link, { size: 16 }) })
2654
2802
  ] });
2655
2803
  };
2656
2804
  mdxComponents = {
2657
- h1: (props) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Heading, { level: 1, ...props }),
2658
- h2: (props) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Heading, { level: 2, ...props }),
2659
- h3: (props) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Heading, { level: 3, ...props }),
2660
- h4: (props) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Heading, { level: 4, ...props }),
2661
- h5: (props) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Heading, { level: 5, ...props }),
2662
- h6: (props) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Heading, { level: 6, ...props }),
2663
- pre: (props) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(CodeBlock, { ...props, children: props.children }),
2664
- video: (props) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react19.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: "video-skeleton" }), children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Video2, { ...props }) }),
2665
- PackageManagerTabs: (props) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react19.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: "pkg-tabs-skeleton" }), children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(PackageManagerTabs2, { ...props }) })
2805
+ h1: (props) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Heading, { level: 1, ...props }),
2806
+ h2: (props) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Heading, { level: 2, ...props }),
2807
+ h3: (props) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Heading, { level: 3, ...props }),
2808
+ h4: (props) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Heading, { level: 4, ...props }),
2809
+ h5: (props) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Heading, { level: 5, ...props }),
2810
+ h6: (props) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Heading, { level: 6, ...props }),
2811
+ pre: (props) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(CodeBlock, { ...props, children: props.children }),
2812
+ video: (props) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_react22.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "video-skeleton" }), children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Video2, { ...props }) }),
2813
+ PackageManagerTabs: (props) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_react22.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "pkg-tabs-skeleton" }), children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(PackageManagerTabs2, { ...props }) })
2666
2814
  };
2667
2815
  }
2668
2816
  });
@@ -2679,6 +2827,7 @@ __export(client_exports, {
2679
2827
  Cards: () => Cards,
2680
2828
  CodeBlock: () => CodeBlock,
2681
2829
  Danger: () => Danger,
2830
+ Field: () => Field,
2682
2831
  FileTree: () => FileTree,
2683
2832
  Head: () => Head,
2684
2833
  InfoBox: () => InfoBox,
@@ -2710,10 +2859,10 @@ init_Breadcrumbs2();
2710
2859
  init_BackgroundGradient2();
2711
2860
 
2712
2861
  // src/client/theme/components/Playground/Playground.tsx
2713
- var import_react20 = __toESM(require("react"));
2862
+ var import_react23 = __toESM(require("react"));
2714
2863
  var import_react_live = require("react-live");
2715
2864
  var import_lucide_react15 = require("lucide-react");
2716
- var import_jsx_runtime30 = require("react/jsx-runtime");
2865
+ var import_jsx_runtime32 = require("react/jsx-runtime");
2717
2866
  function prepareCode(raw) {
2718
2867
  const trimmed = raw.trim();
2719
2868
  const fnMatch = trimmed.match(/export\s+default\s+function\s+(\w+)/);
@@ -2746,48 +2895,48 @@ function Playground({
2746
2895
  }
2747
2896
  const prepared = prepareCode(initialCode);
2748
2897
  const useNoInline = forceNoInline ?? prepared.noInline;
2749
- const [copied, setCopied] = (0, import_react20.useState)(false);
2750
- const [activeCode, setActiveCode] = (0, import_react20.useState)(prepared.code);
2898
+ const [copied, setCopied] = (0, import_react23.useState)(false);
2899
+ const [activeCode, setActiveCode] = (0, import_react23.useState)(prepared.code);
2751
2900
  const handleCopy = () => {
2752
2901
  navigator.clipboard.writeText(activeCode);
2753
2902
  setCopied(true);
2754
2903
  setTimeout(() => setCopied(false), 2e3);
2755
2904
  };
2756
- const extendedScope = { React: import_react20.default, ...scope };
2757
- return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", { className: "boltdocs-playground", "data-readonly": readonly, children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
2905
+ const extendedScope = { React: import_react23.default, ...scope };
2906
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("div", { className: "boltdocs-playground", "data-readonly": readonly, children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
2758
2907
  import_react_live.LiveProvider,
2759
2908
  {
2760
2909
  code: activeCode,
2761
2910
  scope: extendedScope,
2762
2911
  theme: void 0,
2763
2912
  noInline: useNoInline,
2764
- children: /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "playground-split-container", children: [
2765
- /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "playground-panel playground-editor-panel", children: [
2766
- /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "playground-panel-header", children: [
2767
- /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "playground-panel-title", children: [
2768
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_lucide_react15.Terminal, { size: 14 }),
2769
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("span", { children: readonly ? "Code Example" : "Live Editor" })
2913
+ children: /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", { className: "playground-split-container", children: [
2914
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", { className: "playground-panel playground-editor-panel", children: [
2915
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", { className: "playground-panel-header", children: [
2916
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", { className: "playground-panel-title", children: [
2917
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_lucide_react15.Terminal, { size: 14 }),
2918
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("span", { children: readonly ? "Code Example" : "Live Editor" })
2770
2919
  ] }),
2771
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
2920
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
2772
2921
  "button",
2773
2922
  {
2774
2923
  className: "playground-copy-btn",
2775
2924
  onClick: handleCopy,
2776
2925
  title: "Copy code",
2777
- children: copied ? /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_lucide_react15.Check, { size: 14 }) : /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_lucide_react15.Copy, { size: 14 })
2926
+ children: copied ? /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_lucide_react15.Check, { size: 14 }) : /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_lucide_react15.Copy, { size: 14 })
2778
2927
  }
2779
2928
  )
2780
2929
  ] }),
2781
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", { className: "playground-panel-content playground-editor", children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_react_live.LiveEditor, { disabled: readonly, onChange: setActiveCode }) })
2930
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("div", { className: "playground-panel-content playground-editor", children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_react_live.LiveEditor, { disabled: readonly, onChange: setActiveCode }) })
2782
2931
  ] }),
2783
- /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "playground-panel playground-preview-panel", children: [
2784
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", { className: "playground-panel-header", children: /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "playground-panel-title", children: [
2785
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_lucide_react15.Play, { size: 14 }),
2786
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("span", { children: "Preview" })
2932
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", { className: "playground-panel playground-preview-panel", children: [
2933
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("div", { className: "playground-panel-header", children: /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", { className: "playground-panel-title", children: [
2934
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_lucide_react15.Play, { size: 14 }),
2935
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("span", { children: "Preview" })
2787
2936
  ] }) }),
2788
- /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "playground-panel-content playground-preview", children: [
2789
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_react_live.LivePreview, {}),
2790
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(import_react_live.LiveError, { className: "playground-error" })
2937
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", { className: "playground-panel-content playground-preview", children: [
2938
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_react_live.LivePreview, {}),
2939
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_react_live.LiveError, { className: "playground-error" })
2791
2940
  ] })
2792
2941
  ] })
2793
2942
  ] })
@@ -2802,7 +2951,7 @@ init_CodeBlock2();
2802
2951
  init_Video2();
2803
2952
 
2804
2953
  // src/client/theme/components/mdx/Button.tsx
2805
- var import_jsx_runtime31 = require("react/jsx-runtime");
2954
+ var import_jsx_runtime33 = require("react/jsx-runtime");
2806
2955
  function Button({
2807
2956
  variant = "primary",
2808
2957
  size = "md",
@@ -2813,7 +2962,7 @@ function Button({
2813
2962
  }) {
2814
2963
  const cls = `ld-btn ld-btn--${variant} ld-btn--${size} ${className}`.trim();
2815
2964
  if (href) {
2816
- return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
2965
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
2817
2966
  "a",
2818
2967
  {
2819
2968
  href,
@@ -2824,18 +2973,18 @@ function Button({
2824
2973
  }
2825
2974
  );
2826
2975
  }
2827
- return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("button", { className: cls, ...rest, children });
2976
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("button", { className: cls, ...rest, children });
2828
2977
  }
2829
2978
 
2830
2979
  // src/client/theme/components/mdx/Badge.tsx
2831
- var import_jsx_runtime32 = require("react/jsx-runtime");
2980
+ var import_jsx_runtime34 = require("react/jsx-runtime");
2832
2981
  function Badge({
2833
2982
  variant = "default",
2834
2983
  children,
2835
2984
  className = "",
2836
2985
  ...rest
2837
2986
  }) {
2838
- return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
2987
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
2839
2988
  "span",
2840
2989
  {
2841
2990
  className: `ld-badge ld-badge--${variant} ${className}`.trim(),
@@ -2846,14 +2995,14 @@ function Badge({
2846
2995
  }
2847
2996
 
2848
2997
  // src/client/theme/components/mdx/Card.tsx
2849
- var import_jsx_runtime33 = require("react/jsx-runtime");
2998
+ var import_jsx_runtime35 = require("react/jsx-runtime");
2850
2999
  function Cards({
2851
3000
  cols = 3,
2852
3001
  children,
2853
3002
  className = "",
2854
3003
  ...rest
2855
3004
  }) {
2856
- return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { className: `ld-cards ld-cards--${cols} ${className}`.trim(), ...rest, children });
3005
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", { className: `ld-cards ld-cards--${cols} ${className}`.trim(), ...rest, children });
2857
3006
  }
2858
3007
  function Card({
2859
3008
  title,
@@ -2863,13 +3012,13 @@ function Card({
2863
3012
  className = "",
2864
3013
  ...rest
2865
3014
  }) {
2866
- const inner = /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(import_jsx_runtime33.Fragment, { children: [
2867
- icon && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("span", { className: "ld-card__icon", children: icon }),
2868
- title && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("h3", { className: "ld-card__title", children: title }),
2869
- children && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { className: "ld-card__body", children })
3015
+ const inner = /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(import_jsx_runtime35.Fragment, { children: [
3016
+ icon && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("span", { className: "ld-card__icon", children: icon }),
3017
+ title && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("h3", { className: "ld-card__title", children: title }),
3018
+ children && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", { className: "ld-card__body", children })
2870
3019
  ] });
2871
3020
  if (href) {
2872
- return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
3021
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
2873
3022
  "a",
2874
3023
  {
2875
3024
  href,
@@ -2879,34 +3028,34 @@ function Card({
2879
3028
  }
2880
3029
  );
2881
3030
  }
2882
- return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { className: `ld-card ${className}`.trim(), ...rest, children: inner });
3031
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", { className: `ld-card ${className}`.trim(), ...rest, children: inner });
2883
3032
  }
2884
3033
 
2885
3034
  // src/client/theme/components/mdx/Tabs.tsx
2886
- var import_react21 = require("react");
3035
+ var import_react24 = require("react");
2887
3036
  init_CodeBlock2();
2888
3037
  init_npm();
2889
3038
  init_pnpm();
2890
3039
  init_bun();
2891
3040
  init_deno();
2892
- var import_jsx_runtime34 = require("react/jsx-runtime");
3041
+ var import_jsx_runtime36 = require("react/jsx-runtime");
2893
3042
  function Tab({ children }) {
2894
- const content = typeof children === "string" ? /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(CodeBlock, { className: "language-bash", children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("code", { children: children.trim() }) }) : children;
2895
- return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "ld-tab-panel", children: content });
3043
+ const content = typeof children === "string" ? /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(CodeBlock, { className: "language-bash", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("code", { children: children.trim() }) }) : children;
3044
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "ld-tab-panel", children: content });
2896
3045
  }
2897
3046
  var getIconForLabel = (label) => {
2898
3047
  const l = label.toLowerCase();
2899
- if (l.includes("pnpm")) return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(Pnpm, {});
2900
- if (l.includes("npm")) return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(NPM, {});
2901
- if (l.includes("bun")) return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(Bun, {});
2902
- if (l.includes("deno")) return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(Deno, {});
3048
+ if (l.includes("pnpm")) return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Pnpm, {});
3049
+ if (l.includes("npm")) return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(NPM, {});
3050
+ if (l.includes("bun")) return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Bun, {});
3051
+ if (l.includes("deno")) return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Deno, {});
2903
3052
  return null;
2904
3053
  };
2905
3054
  function Tabs2({ defaultIndex = 0, children }) {
2906
- const [active, setActive] = (0, import_react21.useState)(defaultIndex);
2907
- const tabRefs = (0, import_react21.useRef)([]);
2908
- const tabs = import_react21.Children.toArray(children).filter(
2909
- (child) => (0, import_react21.isValidElement)(child) && child.props?.label
3055
+ const [active, setActive] = (0, import_react24.useState)(defaultIndex);
3056
+ const tabRefs = (0, import_react24.useRef)([]);
3057
+ const tabs = import_react24.Children.toArray(children).filter(
3058
+ (child) => (0, import_react24.isValidElement)(child) && child.props?.label
2910
3059
  );
2911
3060
  const handleKeyDown = (e) => {
2912
3061
  let newIndex = active;
@@ -2920,11 +3069,11 @@ function Tabs2({ defaultIndex = 0, children }) {
2920
3069
  tabRefs.current[newIndex]?.focus();
2921
3070
  }
2922
3071
  };
2923
- return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("div", { className: "ld-tabs", children: [
2924
- /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "ld-tabs__bar", role: "tablist", onKeyDown: handleKeyDown, children: tabs.map((child, i) => {
3072
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "ld-tabs", children: [
3073
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "ld-tabs__bar", role: "tablist", onKeyDown: handleKeyDown, children: tabs.map((child, i) => {
2925
3074
  const label = child.props.label;
2926
3075
  const Icon = getIconForLabel(label);
2927
- return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(
3076
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(
2928
3077
  "button",
2929
3078
  {
2930
3079
  role: "tab",
@@ -2939,13 +3088,13 @@ function Tabs2({ defaultIndex = 0, children }) {
2939
3088
  onClick: () => setActive(i),
2940
3089
  children: [
2941
3090
  Icon,
2942
- /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { children: label })
3091
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("span", { children: label })
2943
3092
  ]
2944
3093
  },
2945
3094
  i
2946
3095
  );
2947
3096
  }) }),
2948
- /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
3097
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
2949
3098
  "div",
2950
3099
  {
2951
3100
  className: "ld-tabs__content",
@@ -2960,13 +3109,13 @@ function Tabs2({ defaultIndex = 0, children }) {
2960
3109
 
2961
3110
  // src/client/theme/components/mdx/Admonition.tsx
2962
3111
  var import_lucide_react16 = require("lucide-react");
2963
- var import_jsx_runtime35 = require("react/jsx-runtime");
3112
+ var import_jsx_runtime37 = require("react/jsx-runtime");
2964
3113
  var ICON_MAP2 = {
2965
- note: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_lucide_react16.Bookmark, { size: 18 }),
2966
- tip: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_lucide_react16.Lightbulb, { size: 18 }),
2967
- info: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_lucide_react16.Info, { size: 18 }),
2968
- warning: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_lucide_react16.AlertTriangle, { size: 18 }),
2969
- danger: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_lucide_react16.ShieldAlert, { size: 18 })
3114
+ note: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_lucide_react16.Bookmark, { size: 18 }),
3115
+ tip: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_lucide_react16.Lightbulb, { size: 18 }),
3116
+ info: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_lucide_react16.Info, { size: 18 }),
3117
+ warning: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_lucide_react16.AlertTriangle, { size: 18 }),
3118
+ danger: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_lucide_react16.ShieldAlert, { size: 18 })
2970
3119
  };
2971
3120
  var LABEL_MAP = {
2972
3121
  note: "Note",
@@ -2982,35 +3131,35 @@ function Admonition({
2982
3131
  className = "",
2983
3132
  ...rest
2984
3133
  }) {
2985
- return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
3134
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
2986
3135
  "div",
2987
3136
  {
2988
3137
  className: `ld-admonition ld-admonition--${type} ${className}`.trim(),
2989
3138
  role: type === "warning" || type === "danger" ? "alert" : "note",
2990
3139
  ...rest,
2991
3140
  children: [
2992
- /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("div", { className: "ld-admonition__header", children: [
2993
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("span", { className: "ld-admonition__icon", children: ICON_MAP2[type] }),
2994
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("span", { className: "ld-admonition__title", children: title || LABEL_MAP[type] })
3141
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("div", { className: "ld-admonition__header", children: [
3142
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "ld-admonition__icon", children: ICON_MAP2[type] }),
3143
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "ld-admonition__title", children: title || LABEL_MAP[type] })
2995
3144
  ] }),
2996
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", { className: "ld-admonition__body", children })
3145
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { className: "ld-admonition__body", children })
2997
3146
  ]
2998
3147
  }
2999
3148
  );
3000
3149
  }
3001
- var Note = (props) => /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Admonition, { type: "note", ...props });
3002
- var Tip = (props) => /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Admonition, { type: "tip", ...props });
3003
- var Warning = (props) => /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Admonition, { type: "warning", ...props });
3004
- var Danger = (props) => /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Admonition, { type: "danger", ...props });
3005
- var InfoBox = (props) => /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Admonition, { type: "info", ...props });
3150
+ var Note = (props) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Admonition, { type: "note", ...props });
3151
+ var Tip = (props) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Admonition, { type: "tip", ...props });
3152
+ var Warning = (props) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Admonition, { type: "warning", ...props });
3153
+ var Danger = (props) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Admonition, { type: "danger", ...props });
3154
+ var InfoBox = (props) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Admonition, { type: "info", ...props });
3006
3155
 
3007
3156
  // src/client/theme/components/mdx/List.tsx
3008
- var import_react22 = __toESM(require("react"));
3157
+ var import_react25 = __toESM(require("react"));
3009
3158
  var import_lucide_react17 = require("lucide-react");
3010
- var import_jsx_runtime36 = require("react/jsx-runtime");
3159
+ var import_jsx_runtime38 = require("react/jsx-runtime");
3011
3160
  var ICON_MAP3 = {
3012
- checked: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(import_lucide_react17.Check, { size: 14, className: "ld-list__icon" }),
3013
- arrow: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(import_lucide_react17.ChevronRight, { size: 14, className: "ld-list__icon" })
3161
+ checked: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_lucide_react17.Check, { size: 14, className: "ld-list__icon" }),
3162
+ arrow: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_lucide_react17.ChevronRight, { size: 14, className: "ld-list__icon" })
3014
3163
  };
3015
3164
  function List({
3016
3165
  variant = "default",
@@ -3019,27 +3168,27 @@ function List({
3019
3168
  ...rest
3020
3169
  }) {
3021
3170
  if (variant === "default") {
3022
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("ul", { className: `ld-list ${className}`.trim(), ...rest, children });
3171
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("ul", { className: `ld-list ${className}`.trim(), ...rest, children });
3023
3172
  }
3024
3173
  const icon = ICON_MAP3[variant];
3025
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("ul", { className: `ld-list ld-list--${variant} ${className}`.trim(), ...rest, children: import_react22.Children.map(children, (child) => {
3026
- if (!import_react22.default.isValidElement(child)) return child;
3027
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("li", { className: "ld-list__item", children: [
3174
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("ul", { className: `ld-list ld-list--${variant} ${className}`.trim(), ...rest, children: import_react25.Children.map(children, (child) => {
3175
+ if (!import_react25.default.isValidElement(child)) return child;
3176
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("li", { className: "ld-list__item", children: [
3028
3177
  icon,
3029
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("span", { className: "ld-list__text", children: child.props.children })
3178
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "ld-list__text", children: child.props.children })
3030
3179
  ] });
3031
3180
  }) });
3032
3181
  }
3033
3182
 
3034
3183
  // src/client/theme/components/mdx/FileTree.tsx
3035
- var import_react23 = __toESM(require("react"));
3184
+ var import_react26 = __toESM(require("react"));
3036
3185
  var import_lucide_react18 = require("lucide-react");
3037
- var import_jsx_runtime37 = require("react/jsx-runtime");
3186
+ var import_jsx_runtime39 = require("react/jsx-runtime");
3038
3187
  function getTextContent(node) {
3039
3188
  if (typeof node === "string") return node;
3040
3189
  if (typeof node === "number") return node.toString();
3041
3190
  if (Array.isArray(node)) return node.map(getTextContent).join("");
3042
- if ((0, import_react23.isValidElement)(node)) {
3191
+ if ((0, import_react26.isValidElement)(node)) {
3043
3192
  return getTextContent(node.props.children);
3044
3193
  }
3045
3194
  return "";
@@ -3047,13 +3196,13 @@ function getTextContent(node) {
3047
3196
  function getFileIcon(filename) {
3048
3197
  const name = filename.toLowerCase();
3049
3198
  if (name.endsWith(".ts") || name.endsWith(".tsx") || name.endsWith(".js") || name.endsWith(".jsx") || name.endsWith(".json") || name.endsWith(".mjs") || name.endsWith(".cjs") || name.endsWith(".astro") || name.endsWith(".vue") || name.endsWith(".svelte")) {
3050
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_lucide_react18.FileCode, { size: 16, strokeWidth: 2, className: "ld-file-tree__icon-file" });
3199
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_lucide_react18.FileCode, { size: 16, strokeWidth: 2, className: "ld-file-tree__icon-file" });
3051
3200
  }
3052
3201
  if (name.endsWith(".md") || name.endsWith(".mdx") || name.endsWith(".txt")) {
3053
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_lucide_react18.FileText, { size: 16, strokeWidth: 2, className: "ld-file-tree__icon-file" });
3202
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_lucide_react18.FileText, { size: 16, strokeWidth: 2, className: "ld-file-tree__icon-file" });
3054
3203
  }
3055
3204
  if (name.endsWith(".png") || name.endsWith(".jpg") || name.endsWith(".jpeg") || name.endsWith(".svg") || name.endsWith(".gif")) {
3056
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
3205
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
3057
3206
  import_lucide_react18.FileImage,
3058
3207
  {
3059
3208
  size: 16,
@@ -3062,7 +3211,7 @@ function getFileIcon(filename) {
3062
3211
  }
3063
3212
  );
3064
3213
  }
3065
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_lucide_react18.File, { size: 16, strokeWidth: 2, className: "ld-file-tree__icon-file" });
3214
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_lucide_react18.File, { size: 16, strokeWidth: 2, className: "ld-file-tree__icon-file" });
3066
3215
  }
3067
3216
  function isListElement(node, tag) {
3068
3217
  if (typeof node.type === "string") {
@@ -3084,16 +3233,16 @@ function FolderNode({
3084
3233
  nestedNodes,
3085
3234
  depth
3086
3235
  }) {
3087
- const [isOpen, setIsOpen] = (0, import_react23.useState)(true);
3088
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("li", { className: "ld-file-tree__item", children: [
3089
- /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
3236
+ const [isOpen, setIsOpen] = (0, import_react26.useState)(true);
3237
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("li", { className: "ld-file-tree__item", children: [
3238
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
3090
3239
  "div",
3091
3240
  {
3092
3241
  className: "ld-file-tree__label ld-file-tree__label--folder",
3093
3242
  onClick: () => setIsOpen(!isOpen),
3094
3243
  style: { cursor: "pointer" },
3095
3244
  children: [
3096
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "ld-file-tree__icon ld-file-tree__icon--chevron", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
3245
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "ld-file-tree__icon ld-file-tree__icon--chevron", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
3097
3246
  import_lucide_react18.ChevronRight,
3098
3247
  {
3099
3248
  size: 14,
@@ -3101,7 +3250,7 @@ function FolderNode({
3101
3250
  strokeWidth: 3
3102
3251
  }
3103
3252
  ) }),
3104
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "ld-file-tree__icon", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
3253
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "ld-file-tree__icon", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
3105
3254
  import_lucide_react18.Folder,
3106
3255
  {
3107
3256
  size: 16,
@@ -3111,30 +3260,30 @@ function FolderNode({
3111
3260
  fillOpacity: 0.15
3112
3261
  }
3113
3262
  ) }),
3114
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "ld-file-tree__name", children: labelText })
3263
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "ld-file-tree__name", children: labelText })
3115
3264
  ]
3116
3265
  }
3117
3266
  ),
3118
- isOpen && nestedNodes.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { className: "ld-file-tree__nested", children: nestedNodes.map((child, index) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react23.default.Fragment, { children: parseNode(child, depth) }, index)) })
3267
+ isOpen && nestedNodes.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: "ld-file-tree__nested", children: nestedNodes.map((child, index) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react26.default.Fragment, { children: parseNode(child, depth) }, index)) })
3119
3268
  ] });
3120
3269
  }
3121
3270
  function parseNode(node, depth = 0) {
3122
- if (!(0, import_react23.isValidElement)(node)) {
3271
+ if (!(0, import_react26.isValidElement)(node)) {
3123
3272
  return node;
3124
3273
  }
3125
3274
  if (isListElement(node, "ul")) {
3126
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
3275
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
3127
3276
  "ul",
3128
3277
  {
3129
3278
  className: `ld-file-tree__list ${depth === 0 ? "ld-file-tree__list--root" : ""}`,
3130
- children: import_react23.Children.map(node.props.children, (child, index) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react23.default.Fragment, { children: parseNode(child, depth + 1) }, index))
3279
+ children: import_react26.Children.map(node.props.children, (child, index) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react26.default.Fragment, { children: parseNode(child, depth + 1) }, index))
3131
3280
  }
3132
3281
  );
3133
3282
  }
3134
3283
  if (isListElement(node, "li")) {
3135
- const children = import_react23.Children.toArray(node.props.children);
3284
+ const children = import_react26.Children.toArray(node.props.children);
3136
3285
  const nestedListIndex = children.findIndex(
3137
- (child) => (0, import_react23.isValidElement)(child) && isListElement(child, "ul")
3286
+ (child) => (0, import_react26.isValidElement)(child) && isListElement(child, "ul")
3138
3287
  );
3139
3288
  const hasNested = nestedListIndex !== -1;
3140
3289
  const labelNodes = hasNested ? children.slice(0, nestedListIndex) : children;
@@ -3144,7 +3293,7 @@ function parseNode(node, depth = 0) {
3144
3293
  const labelText = isExplicitDir ? rawLabelContent.slice(0, -1) : rawLabelContent;
3145
3294
  const isFolder = hasNested || isExplicitDir;
3146
3295
  if (isFolder) {
3147
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
3296
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
3148
3297
  FolderNode,
3149
3298
  {
3150
3299
  labelText,
@@ -3153,34 +3302,162 @@ function parseNode(node, depth = 0) {
3153
3302
  }
3154
3303
  );
3155
3304
  }
3156
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("li", { className: "ld-file-tree__item", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("div", { className: "ld-file-tree__label ld-file-tree__label--file", children: [
3157
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "ld-file-tree__icon ld-file-tree__icon--spacer" }),
3158
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "ld-file-tree__icon", children: getFileIcon(labelText) }),
3159
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "ld-file-tree__name", children: labelText })
3305
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("li", { className: "ld-file-tree__item", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("div", { className: "ld-file-tree__label ld-file-tree__label--file", children: [
3306
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "ld-file-tree__icon ld-file-tree__icon--spacer" }),
3307
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "ld-file-tree__icon", children: getFileIcon(labelText) }),
3308
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "ld-file-tree__name", children: labelText })
3160
3309
  ] }) });
3161
3310
  }
3162
3311
  if (node.props.children) {
3163
- return import_react23.Children.map(node.props.children, (child, index) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react23.default.Fragment, { children: parseNode(child, depth) }, index));
3312
+ return import_react26.Children.map(node.props.children, (child, index) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react26.default.Fragment, { children: parseNode(child, depth) }, index));
3164
3313
  }
3165
3314
  return node;
3166
3315
  }
3167
3316
  function FileTree({ children }) {
3168
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { className: "ld-file-tree", dir: "ltr", children: import_react23.Children.map(children, (child) => parseNode(child, 0)) });
3317
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: "ld-file-tree", dir: "ltr", children: import_react26.Children.map(children, (child) => parseNode(child, 0)) });
3169
3318
  }
3170
3319
 
3171
3320
  // src/client/theme/components/mdx/Table.tsx
3172
- var import_jsx_runtime38 = require("react/jsx-runtime");
3321
+ var import_react27 = require("react");
3322
+ var import_lucide_react19 = require("lucide-react");
3323
+ var import_jsx_runtime40 = require("react/jsx-runtime");
3173
3324
  function Table({
3174
3325
  headers,
3175
3326
  data,
3176
3327
  children,
3328
+ className = "",
3329
+ sortable = false,
3330
+ paginated = false,
3331
+ pageSize = 10
3332
+ }) {
3333
+ const [sortConfig, setSortConfig] = (0, import_react27.useState)(null);
3334
+ const [currentPage, setCurrentPage] = (0, import_react27.useState)(1);
3335
+ const processedData = (0, import_react27.useMemo)(() => {
3336
+ if (!data) return [];
3337
+ let items = [...data];
3338
+ if (sortable && sortConfig !== null) {
3339
+ items.sort((a, b) => {
3340
+ const aVal = a[sortConfig.key];
3341
+ const bVal = b[sortConfig.key];
3342
+ const aStr = typeof aVal === "string" ? aVal : "";
3343
+ const bStr = typeof bVal === "string" ? bVal : "";
3344
+ if (aStr < bStr) return sortConfig.direction === "asc" ? -1 : 1;
3345
+ if (aStr > bStr) return sortConfig.direction === "asc" ? 1 : -1;
3346
+ return 0;
3347
+ });
3348
+ }
3349
+ return items;
3350
+ }, [data, sortConfig, sortable]);
3351
+ const totalPages = Math.ceil(processedData.length / pageSize);
3352
+ const paginatedData = (0, import_react27.useMemo)(() => {
3353
+ if (!paginated) return processedData;
3354
+ const start = (currentPage - 1) * pageSize;
3355
+ return processedData.slice(start, start + pageSize);
3356
+ }, [processedData, paginated, currentPage, pageSize]);
3357
+ const requestSort = (index) => {
3358
+ if (!sortable) return;
3359
+ let direction = "asc";
3360
+ if (sortConfig && sortConfig.key === index && sortConfig.direction === "asc") {
3361
+ direction = "desc";
3362
+ }
3363
+ setSortConfig({ key: index, direction });
3364
+ };
3365
+ const renderSortIcon = (index) => {
3366
+ if (!sortable) return null;
3367
+ if (sortConfig?.key !== index) return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_lucide_react19.ChevronDown, { size: 14, className: "ld-table-sort-icon ld-table-sort-icon--hidden" });
3368
+ return sortConfig.direction === "asc" ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_lucide_react19.ChevronUp, { size: 14, className: "ld-table-sort-icon" }) : /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_lucide_react19.ChevronDown, { size: 14, className: "ld-table-sort-icon" });
3369
+ };
3370
+ const tableContent = children ? children : /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_jsx_runtime40.Fragment, { children: [
3371
+ headers && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("thead", { children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("tr", { children: headers.map((header, i) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
3372
+ "th",
3373
+ {
3374
+ onClick: () => requestSort(i),
3375
+ className: sortable ? "ld-table-header--sortable" : "",
3376
+ children: /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: "ld-table-header-content", children: [
3377
+ header,
3378
+ renderSortIcon(i)
3379
+ ] })
3380
+ },
3381
+ i
3382
+ )) }) }),
3383
+ paginatedData && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("tbody", { children: paginatedData.map((row, i) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("tr", { children: row.map((cell, j) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("td", { children: cell }, j)) }, i)) })
3384
+ ] });
3385
+ return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: `ld-table-container ${className}`.trim(), children: [
3386
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("div", { className: "ld-table-wrapper", children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("table", { className: "ld-table", children: tableContent }) }),
3387
+ paginated && totalPages > 1 && /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: "ld-table-pagination", children: [
3388
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: "ld-table-pagination-info", children: [
3389
+ "Page ",
3390
+ currentPage,
3391
+ " of ",
3392
+ totalPages
3393
+ ] }),
3394
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: "ld-table-pagination-controls", children: [
3395
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
3396
+ "button",
3397
+ {
3398
+ onClick: () => setCurrentPage(1),
3399
+ disabled: currentPage === 1,
3400
+ className: "ld-table-pagination-btn",
3401
+ children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_lucide_react19.ChevronsLeft, { size: 16 })
3402
+ }
3403
+ ),
3404
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
3405
+ "button",
3406
+ {
3407
+ onClick: () => setCurrentPage((prev) => Math.max(prev - 1, 1)),
3408
+ disabled: currentPage === 1,
3409
+ className: "ld-table-pagination-btn",
3410
+ children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_lucide_react19.ChevronLeft, { size: 16 })
3411
+ }
3412
+ ),
3413
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
3414
+ "button",
3415
+ {
3416
+ onClick: () => setCurrentPage((prev) => Math.min(prev + 1, totalPages)),
3417
+ disabled: currentPage === totalPages,
3418
+ className: "ld-table-pagination-btn",
3419
+ children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_lucide_react19.ChevronRight, { size: 16 })
3420
+ }
3421
+ ),
3422
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
3423
+ "button",
3424
+ {
3425
+ onClick: () => setCurrentPage(totalPages),
3426
+ disabled: currentPage === totalPages,
3427
+ className: "ld-table-pagination-btn",
3428
+ children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_lucide_react19.ChevronsRight, { size: 16 })
3429
+ }
3430
+ )
3431
+ ] })
3432
+ ] })
3433
+ ] });
3434
+ }
3435
+
3436
+ // src/client/theme/components/mdx/Field.tsx
3437
+ var import_jsx_runtime41 = require("react/jsx-runtime");
3438
+ function Field({
3439
+ name,
3440
+ type,
3441
+ defaultValue,
3442
+ required = false,
3443
+ children,
3444
+ id,
3177
3445
  className = ""
3178
3446
  }) {
3179
- const tableContent = children ? children : /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(import_jsx_runtime38.Fragment, { children: [
3180
- headers && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("thead", { children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("tr", { children: headers.map((header, i) => /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("th", { children: header }, i)) }) }),
3181
- data && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("tbody", { children: data.map((row, i) => /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("tr", { children: row.map((cell, j) => /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("td", { children: cell }, j)) }, i)) })
3447
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)("div", { className: `ld-field ${className}`.trim(), id, children: [
3448
+ /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)("div", { className: "ld-field__header", children: [
3449
+ /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)("div", { className: "ld-field__signature", children: [
3450
+ /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("code", { className: "ld-field__name", children: name }),
3451
+ type && /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("span", { className: "ld-field__type-badge", children: type }),
3452
+ required && /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("span", { className: "ld-field__required-badge", children: "required" })
3453
+ ] }),
3454
+ defaultValue && /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)("div", { className: "ld-field__default", children: [
3455
+ /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("span", { className: "ld-field__default-label", children: "Default:" }),
3456
+ /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("code", { className: "ld-field__default-value", children: defaultValue })
3457
+ ] })
3458
+ ] }),
3459
+ /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("div", { className: "ld-field__content", children })
3182
3460
  ] });
3183
- return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("div", { className: `ld-table-container ${className}`.trim(), children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("table", { className: "ld-table", children: tableContent }) });
3184
3461
  }
3185
3462
  // Annotate the CommonJS export names for ESM import in node:
3186
3463
  0 && (module.exports = {
@@ -3193,6 +3470,7 @@ function Table({
3193
3470
  Cards,
3194
3471
  CodeBlock,
3195
3472
  Danger,
3473
+ Field,
3196
3474
  FileTree,
3197
3475
  Head,
3198
3476
  InfoBox,