boltdocs 2.2.0 → 2.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +24 -0
- package/bin/boltdocs.js +2 -2
- package/dist/base-ui/index.d.mts +4 -4
- package/dist/base-ui/index.d.ts +4 -4
- package/dist/base-ui/index.js +1 -1
- package/dist/base-ui/index.mjs +1 -1
- package/dist/{cache-CRAZ55X7.mjs → cache-P6WK424C.mjs} +1 -1
- package/dist/chunk-2DI3OGHV.mjs +1 -0
- package/dist/chunk-2Z5T6EAU.mjs +1 -0
- package/dist/chunk-64AJ5QLT.mjs +1 -0
- package/dist/chunk-DDX52BX4.mjs +1 -0
- package/dist/chunk-HRZDSFR5.mjs +1 -0
- package/dist/chunk-PPVDMDEL.mjs +1 -0
- package/dist/chunk-UBE4CKOA.mjs +1 -0
- package/dist/chunk-UWT4AJTH.mjs +73 -0
- package/dist/chunk-WWJ7WKDI.mjs +1 -0
- package/dist/chunk-Y4RRHPXC.mjs +1 -0
- package/dist/client/index.d.mts +15 -21
- package/dist/client/index.d.ts +15 -21
- package/dist/client/index.js +1 -1
- package/dist/client/index.mjs +1 -1
- package/dist/client/ssr.js +1 -1
- package/dist/client/ssr.mjs +1 -1
- package/dist/client/types.d.mts +1 -1
- package/dist/client/types.d.ts +1 -1
- package/dist/client/types.js +1 -1
- package/dist/{copy-markdown-CbS8X-qe.d.mts → copy-markdown--9yjpbyy.d.mts} +1 -1
- package/dist/{copy-markdown-C-90ixSe.d.ts → copy-markdown-l2MYkcG7.d.ts} +1 -1
- package/dist/hooks/index.d.mts +8 -16
- package/dist/hooks/index.d.ts +8 -16
- package/dist/hooks/index.js +1 -1
- package/dist/hooks/index.mjs +1 -1
- package/dist/integrations/index.d.mts +1 -1
- package/dist/integrations/index.d.ts +1 -1
- package/dist/{loading-chS3pm9W.d.ts → loading-BwUos0wZ.d.mts} +5 -16
- package/dist/{loading-BqGrFWO5.d.mts → loading-nlnUD01v.d.ts} +5 -16
- package/dist/mdx/index.d.mts +4 -2
- package/dist/mdx/index.d.ts +4 -2
- package/dist/mdx/index.js +1 -1
- package/dist/mdx/index.mjs +1 -1
- package/dist/node/cli-entry.js +25 -22
- package/dist/node/cli-entry.mjs +5 -1
- package/dist/node/index.d.mts +0 -9
- package/dist/node/index.d.ts +0 -9
- package/dist/node/index.js +14 -15
- package/dist/node/index.mjs +1 -1
- package/dist/primitives/index.d.mts +13 -22
- package/dist/primitives/index.d.ts +13 -22
- package/dist/primitives/index.js +1 -1
- package/dist/primitives/index.mjs +1 -1
- package/dist/search-dialog-OONKKC5H.mjs +1 -0
- package/dist/{types-j7jvWsJj.d.ts → types-opDA2E9-.d.mts} +4 -11
- package/dist/{types-j7jvWsJj.d.mts → types-opDA2E9-.d.ts} +4 -11
- package/dist/{use-routes-Cd806kGw.d.ts → use-routes-DNwgTRpU.d.ts} +1 -1
- package/dist/{use-routes-DDL0_jkQ.d.mts → use-routes-DrT80Eom.d.mts} +1 -1
- package/package.json +2 -1
- package/src/client/app/index.tsx +20 -9
- package/src/client/app/mdx-components-context.tsx +2 -2
- package/src/client/app/mdx-page.tsx +0 -1
- package/src/client/app/scroll-handler.tsx +21 -10
- package/src/client/app/theme-context.tsx +14 -7
- package/src/client/components/default-layout.tsx +6 -4
- package/src/client/components/docs-layout.tsx +34 -4
- package/src/client/components/icons-dev.tsx +154 -0
- package/src/client/components/mdx/code-block.tsx +57 -5
- package/src/client/components/mdx/component-preview.tsx +1 -0
- package/src/client/components/mdx/file-tree.tsx +35 -0
- package/src/client/components/primitives/helpers/observer.ts +30 -39
- package/src/client/components/primitives/index.ts +1 -0
- package/src/client/components/primitives/menu.tsx +18 -12
- package/src/client/components/primitives/navbar.tsx +34 -93
- package/src/client/components/primitives/on-this-page.tsx +7 -161
- package/src/client/components/primitives/popover.tsx +1 -2
- package/src/client/components/primitives/search-dialog.tsx +4 -4
- package/src/client/components/primitives/sidebar.tsx +3 -2
- package/src/client/components/primitives/skeleton.tsx +26 -0
- package/src/client/components/ui-base/copy-markdown.tsx +4 -10
- package/src/client/components/ui-base/index.ts +0 -1
- package/src/client/components/ui-base/loading.tsx +43 -73
- package/src/client/components/ui-base/navbar.tsx +18 -15
- package/src/client/components/ui-base/page-nav.tsx +2 -1
- package/src/client/components/ui-base/powered-by.tsx +4 -1
- package/src/client/components/ui-base/search-dialog.tsx +16 -5
- package/src/client/components/ui-base/sidebar.tsx +4 -2
- package/src/client/hooks/use-i18n.ts +3 -2
- package/src/client/hooks/use-localized-to.ts +6 -5
- package/src/client/hooks/use-navbar.ts +37 -6
- package/src/client/hooks/use-page-nav.ts +27 -6
- package/src/client/hooks/use-routes.ts +2 -1
- package/src/client/hooks/use-search.ts +81 -59
- package/src/client/hooks/use-sidebar.ts +2 -1
- package/src/client/index.ts +0 -1
- package/src/client/store/use-boltdocs-store.ts +6 -5
- package/src/client/theme/neutral.css +31 -3
- package/src/client/types.ts +2 -2
- package/src/node/{cli.ts → cli/build.ts} +17 -23
- package/src/node/cli/dev.ts +22 -0
- package/src/node/cli/doctor.ts +243 -0
- package/src/node/cli/index.ts +9 -0
- package/src/node/cli/ui.ts +54 -0
- package/src/node/cli-entry.ts +16 -16
- package/src/node/config.ts +1 -15
- package/src/node/mdx/cache.ts +1 -1
- package/src/node/mdx/index.ts +2 -0
- package/src/node/mdx/rehype-shiki.ts +9 -0
- package/src/node/mdx/remark-code-meta.ts +35 -0
- package/src/node/mdx/remark-shiki.ts +1 -1
- package/src/node/plugin/entry.ts +22 -15
- package/src/node/plugin/index.ts +46 -14
- package/src/node/routes/parser.ts +12 -9
- package/src/node/search/index.ts +55 -0
- package/src/node/ssg/index.ts +83 -15
- package/src/node/ssg/robots.ts +7 -4
- package/dist/chunk-5D6XPYQ3.mjs +0 -74
- package/dist/chunk-6QXCKZAT.mjs +0 -1
- package/dist/chunk-H4M6P3DM.mjs +0 -1
- package/dist/chunk-JXHNX2WN.mjs +0 -1
- package/dist/chunk-MZBG4N4W.mjs +0 -1
- package/dist/chunk-Q3MLYTIQ.mjs +0 -1
- package/dist/chunk-RSII2UPE.mjs +0 -1
- package/dist/chunk-ZK2266IZ.mjs +0 -1
- package/dist/chunk-ZRJ55GGF.mjs +0 -1
- package/dist/search-dialog-MA5AISC7.mjs +0 -1
- package/src/client/components/ui-base/progress-bar.tsx +0 -67
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,29 @@
|
|
|
1
1
|
# boltdocs
|
|
2
2
|
|
|
3
|
+
## 2.4.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`80de4bd`](https://github.com/bolt-docs/boltdocs/commit/80de4bd49c3de90ec234148c8077b479935db2cf) Thanks [@jesusalcaladev](https://github.com/jesusalcaladev)! - updated width with pathname
|
|
8
|
+
|
|
9
|
+
- [`c49cefa`](https://github.com/bolt-docs/boltdocs/commit/c49cefa292075606ae626826a890a93bda939ba5) Thanks [@jesusalcaladev](https://github.com/jesusalcaladev)! - added name tabs in URLs & repared icons size
|
|
10
|
+
|
|
11
|
+
## 2.4.0
|
|
12
|
+
|
|
13
|
+
### Minor Changes
|
|
14
|
+
|
|
15
|
+
- [`0ee1f85`](https://github.com/bolt-docs/boltdocs/commit/0ee1f8525500ca6b6dc1eb78260fc257b3698fd4) Thanks [@jesusalcaladev](https://github.com/jesusalcaladev)! - Support icons & title CodeBlock, Better Scroll, export Skeleton Component
|
|
16
|
+
|
|
17
|
+
## 2.3.0
|
|
18
|
+
|
|
19
|
+
### Minor Changes
|
|
20
|
+
|
|
21
|
+
- [`5d53fd0`](https://github.com/jesusalcaladev/boltdocs/commit/5d53fd0eddbcc0e22b092f52cea82df78063376b) Thanks [@jesusalcaladev](https://github.com/jesusalcaladev)! - feat: added new primitives `Skeleton`
|
|
22
|
+
feat: added new loading with `Skeleton` primitives
|
|
23
|
+
feat: added new command `boltdocs doctor` for diagnostic your project
|
|
24
|
+
feat: support full-text search
|
|
25
|
+
fix: better calc in page-nav
|
|
26
|
+
|
|
3
27
|
## 2.2.0
|
|
4
28
|
|
|
5
29
|
### Minor Changes
|
package/bin/boltdocs.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
|
|
2
|
+
'use strict'
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Stable entry point for the Boltdocs CLI.
|
|
@@ -9,4 +9,4 @@
|
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
11
|
// We use require because the core package is currently CommonJS.
|
|
12
|
-
require(
|
|
12
|
+
require('../dist/node/cli-entry.js')
|
package/dist/base-ui/index.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { B as Breadcrumbs, E as ErrorBoundary, H as Head, L as Loading, N as Navbar, a as NotFound, O as OnThisPage, P as PageNav,
|
|
2
|
-
export { C as CopyMarkdown, a as CopyMarkdownProps } from '../copy-markdown
|
|
1
|
+
export { B as Breadcrumbs, E as ErrorBoundary, H as Head, L as Loading, N as Navbar, a as NotFound, O as OnThisPage, P as PageNav, S as Sidebar } from '../loading-BwUos0wZ.mjs';
|
|
2
|
+
export { C as CopyMarkdown, a as CopyMarkdownProps } from '../copy-markdown--9yjpbyy.mjs';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
|
-
import {
|
|
4
|
+
import { C as ComponentRoute, a as BoltdocsTab } from '../types-opDA2E9-.mjs';
|
|
5
5
|
import 'react';
|
|
6
6
|
import 'vite';
|
|
7
7
|
|
|
@@ -12,7 +12,7 @@ declare function GithubStars({ repo }: {
|
|
|
12
12
|
declare function PoweredBy(): react_jsx_runtime.JSX.Element;
|
|
13
13
|
|
|
14
14
|
declare function SearchDialog({ routes }: {
|
|
15
|
-
routes:
|
|
15
|
+
routes: ComponentRoute[];
|
|
16
16
|
}): react_jsx_runtime.JSX.Element;
|
|
17
17
|
|
|
18
18
|
declare function Tabs({ tabs, routes, }: {
|
package/dist/base-ui/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { B as Breadcrumbs, E as ErrorBoundary, H as Head, L as Loading, N as Navbar, a as NotFound, O as OnThisPage, P as PageNav,
|
|
2
|
-
export { C as CopyMarkdown, a as CopyMarkdownProps } from '../copy-markdown-
|
|
1
|
+
export { B as Breadcrumbs, E as ErrorBoundary, H as Head, L as Loading, N as Navbar, a as NotFound, O as OnThisPage, P as PageNav, S as Sidebar } from '../loading-nlnUD01v.js';
|
|
2
|
+
export { C as CopyMarkdown, a as CopyMarkdownProps } from '../copy-markdown-l2MYkcG7.js';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
|
-
import {
|
|
4
|
+
import { C as ComponentRoute, a as BoltdocsTab } from '../types-opDA2E9-.js';
|
|
5
5
|
import 'react';
|
|
6
6
|
import 'vite';
|
|
7
7
|
|
|
@@ -12,7 +12,7 @@ declare function GithubStars({ repo }: {
|
|
|
12
12
|
declare function PoweredBy(): react_jsx_runtime.JSX.Element;
|
|
13
13
|
|
|
14
14
|
declare function SearchDialog({ routes }: {
|
|
15
|
-
routes:
|
|
15
|
+
routes: ComponentRoute[];
|
|
16
16
|
}): react_jsx_runtime.JSX.Element;
|
|
17
17
|
|
|
18
18
|
declare function Tabs({ tabs, routes, }: {
|
package/dist/base-ui/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var fr=Object.create;var Ve=Object.defineProperty;var gr=Object.getOwnPropertyDescriptor;var hr=Object.getOwnPropertyNames;var br=Object.getPrototypeOf,xr=Object.prototype.hasOwnProperty;var y=(e,t)=>()=>(e&&(t=e(e=0)),t);var Ut=(e,t)=>{for(var o in t)Ve(e,o,{get:t[o],enumerable:!0})},jt=(e,t,o,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of hr(t))!xr.call(e,n)&&n!==o&&Ve(e,n,{get:()=>t[n],enumerable:!(r=gr(t,n))||r.enumerable});return e};var V=(e,t,o)=>(o=e!=null?fr(br(e)):{},jt(t||!e||!e.__esModule?Ve(o,"default",{value:e,enumerable:!0}):o,e)),vr=e=>jt(Ve({},"__esModule",{value:!0}),e);var i=y(()=>{"use strict"});function F(){let e=(0,De.use)(Cr);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e}var De,Cr,pe=y(()=>{"use strict";i();De=require("react"),Cr=(0,De.createContext)(null)});function He(){return(0,ue.use)(yr)}var ue,Nr,yr,mt=y(()=>{"use strict";i();ue=require("react"),Nr=require("react/jsx-runtime"),yr=(0,ue.createContext)({preload:()=>{},routes:[]})});var Kt,ze,ne,$e=y(()=>{"use strict";i();Kt=require("zustand"),ze=require("zustand/middleware"),ne=(0,Kt.create)()((0,ze.persist)(e=>({currentLocale:void 0,currentVersion:void 0,hasHydrated:!1,setLocale:t=>e({currentLocale:t}),setVersion:t=>e({currentVersion:t}),setHasHydrated:t=>e({hasHydrated:t})}),{name:"boltdocs-storage",storage:(0,ze.createJSONStorage)(()=>localStorage),partialize:e=>({currentLocale:e.currentLocale,currentVersion:e.currentVersion}),onRehydrateStorage:()=>e=>{e?.setHasHydrated(!0)}}))});function k(){let{routes:e}=He(),t=F(),o=(0,qt.useLocation)(),r=ne(h=>h.currentLocale),n=ne(h=>h.currentVersion),s=ne(h=>h.hasHydrated),a=e.find(h=>h.path===o.pathname),l=t.i18n?a?.locale||(s?r:void 0)||t.i18n.defaultLocale:void 0,c=t.versions?a?.version||(s?n:void 0)||t.versions.defaultVersion:void 0,f=e.filter(h=>{let Z=t.i18n?(h.locale||t.i18n.defaultLocale)===l:!0,lt=t.versions?(h.version||t.versions.defaultVersion)===c:!0;if(!(Z&<))return!1;let ct=t.i18n;if(ct){let ur=!!a?.locale,dr=!!h.locale;if(e.some(Ee=>Ee!==h&&Ee.filePath===h.filePath&&Ee.version===h.version&&(Ee.locale||ct.defaultLocale)===(h.locale||ct.defaultLocale))&&ur!==dr)return!1}return!0}),p=t.i18n?.localeConfigs?.[l]?.label||t.i18n?.locales[l]||l,v=t.versions?.versions.find(h=>h.path===c)?.label||c,N=t.i18n?Object.entries(t.i18n.locales).map(([h,Z])=>{let lt=t.i18n?.localeConfigs?.[h];return{key:h,label:lt?.label||Z,isCurrent:h===l}}):[],C=t.versions?t.versions.versions.map(h=>({key:h.path,label:h.label,isCurrent:h.path===c})):[];return{routes:f,allRoutes:e,currentRoute:a,currentLocale:l,currentLocaleLabel:p,availableLocales:N,currentVersion:c,currentVersionLabel:v,availableVersions:C,config:t}}var qt,W=y(()=>{"use strict";i();qt=require("react-router-dom");pe();mt();$e()});function m(...e){return(0,Qt.twMerge)((0,Zt.clsx)(e))}var Zt,Qt,I=y(()=>{"use strict";i();Zt=require("clsx"),Qt=require("tailwind-merge")});var de,Jt,ke,Yt,pt,ut,eo,dt=y(()=>{"use strict";i();de=require("react-aria-components"),Jt=require("lucide-react");I();ke=require("react/jsx-runtime"),Yt=({children:e,className:t,...o})=>(0,ke.jsx)(de.Breadcrumbs,{className:m("flex items-center gap-1.5 pl-0! mb-0 text-sm text-text-muted",t),...o,children:e}),pt=({children:e,className:t,...o})=>(0,ke.jsx)(de.Breadcrumb,{className:m("flex items-center mb-0 gap-1.5",t),...o,children:e}),ut=({children:e,href:t,className:o,...r})=>(0,ke.jsx)(de.Link,{href:t,className:m("transition-colors outline-none hover:text-text-main focus-visible:ring-2 focus-visible:ring-primary-500/30 rounded-sm","current:font-medium current:text-text-main current:pointer-events-none cursor-pointer",o),...r,children:e}),eo=({className:e})=>(0,ke.jsx)(Jt.ChevronRight,{size:14,className:m("shrink-0 text-text-dim",e)})});function Ge(e){let{size:t=20,...o}=e;return{...o,width:t,height:t}}var D,_e,ro,no,so,ft=y(()=>{"use strict";i();D=require("react/jsx-runtime");_e=e=>(0,D.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",...Ge(e),children:[(0,D.jsx)("title",{children:"GitHub"}),(0,D.jsx)("path",{d:"M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"})]}),ro=e=>(0,D.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",...Ge(e),children:[(0,D.jsx)("title",{children:"Discord"}),(0,D.jsx)("path",{d:"M20.317 4.37a19.791 19.791 0 0 0-4.885-1.515.074.074 0 0 0-.079.037c-.21.375-.444.864-.608 1.25a18.27 18.27 0 0 0-5.487 0 12.64 12.64 0 0 0-.617-1.25.077.077 0 0 0-.079-.037A19.736 19.736 0 0 0 3.677 4.37a.07.07 0 0 0-.032.027C.533 9.046-.32 13.58.099 18.057a.082.082 0 0 0 .031.057 19.9 19.9 0 0 0 5.993 3.03.078.078 0 0 0 .084-.028c.462-.63.874-1.295 1.226-1.994a.076.076 0 0 0-.041-.106 13.107 13.107 0 0 1-1.872-.892.077.077 0 0 1-.008-.128 10.2 10.2 0 0 0 .372-.292.074.074 0 0 1 .077-.01c3.928 1.793 8.18 1.793 12.062 0a.074.074 0 0 1 .078.01c.12.098.246.198.373.292a.077.077 0 0 1-.006.127 12.299 12.299 0 0 1-1.873.892.077.077 0 0 0-.041.107c.36.698.772 1.362 1.225 1.993a.076.076 0 0 0 .084.028 19.839 19.839 0 0 0 6.002-3.03.077.077 0 0 0 .032-.054c.5-5.177-.838-9.674-3.549-13.66a.061.061 0 0 0-.031-.03zM8.02 15.33c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.956-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.956 2.418-2.157 2.418zm7.975 0c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.955-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.946 2.418-2.157 2.418Z"})]}),no=e=>(0,D.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",...Ge(e),children:[(0,D.jsx)("title",{children:"X"}),(0,D.jsx)("path",{d:"M14.234 10.162 22.977 0h-2.072l-7.591 8.824L7.251 0H.258l9.168 13.343L.258 24H2.33l8.016-9.318L16.749 24h6.993zm-2.837 3.299-.929-1.329L3.076 1.56h3.182l5.965 8.532.929 1.329 7.754 11.09h-3.182z"})]}),so=e=>(0,D.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",...Ge(e),children:[(0,D.jsx)("title",{children:"Bluesky"}),(0,D.jsx)("path",{d:"M5.202 2.857C7.954 4.922 10.913 9.11 12 11.358c1.087-2.247 4.046-6.436 6.798-8.501C20.783 1.366 24 .213 24 3.883c0 .732-.42 6.156-.667 7.037-.856 3.061-3.978 3.842-6.755 3.37 4.854.826 6.089 3.562 3.422 6.299-5.065 5.196-7.28-1.304-7.847-2.97-.104-.305-.152-.448-.153-.327 0-.121-.05.022-.153.327-.568 1.666-2.782 8.166-7.847 2.97-2.667-2.737-1.432-5.473 3.422-6.3-2.777.473-5.899-.308-6.755-3.369C.42 10.04 0 4.615 0 3.883c0-3.67 3.217-2.517 5.202-1.026"})]})});var Fe,io,J,x,Rr,wr,Tr,Lr,kr,Sr,Ir,Br,Mr,Ar,Or,Er,Vr,Dr,Hr,O,We=y(()=>{"use strict";i();Fe=require("react");Ue();io=require("react-aria-components"),J=require("lucide-react");ft();x=require("react/jsx-runtime"),Rr=({children:e,className:t,...o})=>(0,x.jsx)("header",{className:m("boltdocs-navbar sticky top-0 z-50 w-full border-b border-border-subtle bg-bg-main/80 backdrop-blur-md",t),...o,children:e}),wr=({children:e,className:t})=>(0,x.jsx)("div",{className:m("mx-auto flex lg:h-navbar max-w-(--breakpoint-3xl) items-center justify-between px-4 md:px-6",t),children:e}),Tr=({children:e,className:t})=>(0,x.jsx)("div",{className:m("flex items-center gap-4",t),children:e}),Lr=({children:e,className:t})=>(0,x.jsx)("div",{className:m("flex items-center gap-2 md:gap-4",t),children:e}),kr=({children:e,className:t})=>(0,x.jsx)("div",{className:m("hidden lg:flex flex-1 justify-center items-center gap-4 px-4",t),children:e}),Sr=({src:e,alt:t,width:o=24,height:r=24,className:n})=>(0,x.jsx)(z,{href:"/",className:m("flex items-center gap-2 shrink-0 outline-none",n),children:e?(0,x.jsx)("img",{src:e,alt:t,width:o,height:r,className:"h-6 w-6 object-contain"}):null}),Ir=({children:e,className:t})=>(0,x.jsx)("span",{className:m("text-lg font-bold tracking-tight hidden sm:inline-block",t),children:e}),Br=({children:e,className:t})=>(0,x.jsx)("nav",{className:m("hidden md:flex items-center gap-6 text-sm font-medium",t),children:e}),Mr=({label:e,href:t,active:o,to:r,className:n})=>(0,x.jsxs)(z,{href:t,target:r==="external"?"_blank":void 0,className:m("transition-colors outline-none focus-visible:ring-2 focus-visible:ring-primary-500/30 rounded-sm",{"text-primary-500 font-bold":o,"text-text-muted hover:text-text-main font-medium":!o},n),children:[e,r==="external"&&(0,x.jsx)("span",{className:"ml-1 inline-block",children:(0,x.jsx)(J.ExternalLink,{size:12})})]}),Ar=({className:e,onPress:t})=>{let[o,r]=(0,Fe.useState)(!1),n=o&&/Mac|iPod|iPhone|iPad/.test(navigator.platform);return(0,Fe.useEffect)(()=>{r(!0)},[]),(0,x.jsxs)(io.Button,{onPress:t,className:m("flex items-center gap-2 rounded-full border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-muted outline-none cursor-pointer","transition-colors hover:border-border-strong hover:text-text-main","focus-visible:ring-2 focus-visible:ring-primary-500/30","w-full max-w-[320px] justify-between",e),children:[(0,x.jsxs)("div",{className:"flex items-center gap-2",children:[(0,x.jsx)(J.Search,{size:16}),(0,x.jsx)("span",{className:"hidden sm:inline-block",children:"Search docs..."})]}),(0,x.jsxs)("div",{className:"hidden sm:flex items-center gap-1 pointer-events-none select-none",children:[(0,x.jsx)("kbd",{className:"flex h-5 items-center justify-center rounded border border-border-subtle bg-bg-main px-1.5 font-mono text-[10px] font-medium",children:n?"\u2318":"Ctrl"}),(0,x.jsx)("kbd",{className:"flex h-5 w-5 items-center justify-center rounded border border-border-subtle bg-bg-main font-mono text-[10px] font-medium",children:"K"})]})]})},Or=({className:e,theme:t,onThemeChange:o})=>(0,x.jsx)(he.ToggleButton,{isSelected:t==="dark",onChange:o,className:m("rounded-md p-2 text-text-muted outline-none cursor-pointer transition-colors","hover:bg-bg-surface hover:text-text-main","focus-visible:ring-2 focus-visible:ring-primary-500/30",e),"aria-label":"Toggle theme",children:t==="dark"?(0,x.jsx)(J.Sun,{size:20}):(0,x.jsx)(J.Moon,{size:20})}),Er=({label:e,className:t,onPress:o,isCurrent:r})=>(0,x.jsx)(U,{onAction:o,className:m(r&&"bg-primary-500 text-white font-medium hover:bg-primary-600 focus:bg-primary-600 focus:text-white",t),children:e}),Vr=({name:e})=>{if(e==="github")return(0,x.jsx)(_e,{});if(e==="discord")return(0,x.jsx)(ro,{});if(e==="x")return(0,x.jsx)(no,{});if(e==="bluesky")return(0,x.jsx)(so,{})},Dr=({icon:e,link:t,className:o})=>(0,x.jsx)(z,{href:t,target:"_blank",rel:"noopener noreferrer",className:m("rounded-md p-2 text-text-muted outline-none transition-colors","hover:bg-bg-surface hover:text-text-main","focus-visible:ring-2 focus-visible:ring-primary-500/30",o),children:(0,x.jsx)(Vr,{name:e})}),Hr=({className:e})=>(0,x.jsx)(he.Separator,{orientation:"vertical",className:m("h-6 w-px bg-border-subtle mx-1",e)}),O={NavbarRoot:Rr,NavbarLeft:Tr,NavbarRight:Lr,NavbarCenter:kr,NavbarLogo:Sr,Title:Ir,Links:Br,Link:Mr,SearchTrigger:Ar,Theme:Or,Item:Er,Socials:Dr,Split:Hr,Content:wr}});var Se,zr,gt,ao=y(()=>{"use strict";i();Se=V(require("react-aria-components")),zr=require("lucide-react");I();gt=require("react/jsx-runtime")});var B,se,P,ht,bt,xt,vt,Ct,yt,Nt,Pt,ms,Rt=y(()=>{"use strict";i();B=V(require("react-aria-components")),se=require("lucide-react");I();P=require("react/jsx-runtime"),ht=({children:e,isOpen:t,onOpenChange:o,className:r})=>(0,P.jsx)(B.ModalOverlay,{isOpen:t,onOpenChange:o,isDismissable:!0,className:m("fixed inset-0 z-100 bg-black/40 backdrop-blur-sm px-4 py-4 sm:py-20","entering:animate-in entering:fade-in exiting:animate-out exiting:fade-out"),children:(0,P.jsx)(B.Modal,{className:m("mx-auto w-full max-w-2xl overflow-hidden rounded-xl border border-border-subtle bg-bg-surface shadow-2xl ring-1 ring-black/5 outline-none","entering:animate-in entering:fade-in entering:zoom-in-95 exiting:animate-out exiting:fade-out exiting:zoom-out-95",r),children:(0,P.jsx)(B.Dialog,{className:"flex flex-col max-h-[70vh] focus:outline-none",children:e})})}),bt=({children:e,className:t,onSelectionChange:o,...r})=>(0,P.jsx)("div",{className:t,children:(0,P.jsx)(B.Autocomplete,{...r,onSelectionChange:o,className:"flex flex-col min-h-0",children:e})}),xt=({className:e,...t})=>(0,P.jsxs)(B.SearchField,{className:"flex items-center gap-3 border-b border-border-subtle px-4 py-4",autoFocus:!0,children:[(0,P.jsx)(se.Search,{className:"h-5 w-5 text-text-muted"}),(0,P.jsx)(B.Input,{...t,className:m("w-full bg-transparent text-lg text-text-main placeholder-text-muted outline-none",e),placeholder:"Search documentation..."}),(0,P.jsx)("div",{className:"flex items-center gap-1.5 rounded-md border border-border-subtle bg-bg-main px-1.5 py-1 text-[10px] font-medium text-text-muted",children:(0,P.jsx)("kbd",{className:"font-sans",children:"ESC"})})]}),vt=({children:e,className:t,...o})=>(0,P.jsx)(B.ListBox,{...o,className:m("flex-1 overflow-y-auto p-2 outline-none",t),children:e}),Ct=({children:e,className:t,...o})=>(0,P.jsx)(B.ListBoxItem,{...o,className:m("group flex items-center gap-3 rounded-lg p-3 text-left outline-none cursor-pointer transition-colors","text-text-muted hover:bg-bg-main hover:text-text-main focus:bg-primary-500 focus:text-white selected:bg-primary-500 selected:text-white",t),children:r=>(0,P.jsxs)(P.Fragment,{children:[e,(r.isFocused||r.isSelected)&&(0,P.jsxs)("div",{className:"ml-auto opacity-50 flex items-center gap-1",children:[(0,P.jsx)("span",{className:"text-[10px]",children:"Select"}),(0,P.jsx)(se.CornerDownLeft,{size:10})]})]})}),yt=({isHeading:e,className:t})=>(0,P.jsx)("div",{className:m("shrink-0",t),children:e?(0,P.jsx)(se.Hash,{size:18}):(0,P.jsx)(se.FileText,{size:18})}),Nt=({children:e,className:t})=>(0,P.jsx)("span",{className:m("block font-medium truncate flex-1 text-sm",t),children:e}),Pt=({children:e,className:t})=>(0,P.jsx)("span",{className:m("ml-2 text-xs opacity-70 truncate hidden sm:inline group-focus:opacity-100",t),children:e}),ms={Root:ht,Autocomplete:bt,Input:xt,List:vt,Item:Object.assign(Ct,{Icon:yt,Title:Nt,Bio:Pt})}});function lo(e,t){let o=(0,je.useRef)(e);(0,je.useEffect)(()=>{o.current!==e&&(t(e),o.current=e)},[e,t])}var je,co=y(()=>{"use strict";i();je=require("react")});function wt(e){return e.startsWith("#")?e.slice(1):null}var mo=y(()=>{"use strict";i()});function $r(){let e=(0,R.use)(Lt);if(!e)throw new Error("Component must be used under the <AnchorProvider /> component.");return e}function Gr(e){let[t,o]=(0,R.useState)({isOverflowing:!1,isAtBottom:!1});return(0,R.useEffect)(()=>{let r=e.current;if(!r)return;let n=()=>{let a=r.scrollHeight>r.clientHeight,l=r.scrollHeight-r.scrollTop<=r.clientHeight+2;o({isOverflowing:a,isAtBottom:l})};n(),r.addEventListener("scroll",n,{passive:!0}),window.addEventListener("resize",n);let s=new MutationObserver(n);return s.observe(r,{childList:!0,subtree:!0}),()=>{r.removeEventListener("scroll",n),window.removeEventListener("resize",n),s.disconnect()}},[e]),t}function fo(){let e=$r();return(0,R.useMemo)(()=>{let t;for(let o of e)o.active&&(!t||o.t>t.t)&&(t=o);return t?.id},[e])}function go({containerRef:e,children:t}){return(0,j.jsx)(uo.Provider,{value:e,children:t})}function ho({toc:e,single:t=!1,children:o}){let r=(0,R.useMemo)(()=>new Tt,[]),[n,s]=(0,R.useState)(r.items);return r.single=t,(0,R.useEffect)(()=>{r.setItems(e)},[r,e]),(0,R.useEffect)(()=>(r.watch({rootMargin:"0px",threshold:.98}),r.onChange=()=>s([...r.items]),()=>{r.unwatch()}),[r]),(0,j.jsx)(Lt.Provider,{value:n,children:o})}var R,po,j,Lt,uo,Tt,_r,Fr,bo,Wr,Ur,jr,Kr,le,kt=y(()=>{"use strict";i();R=require("react"),po=V(require("scroll-into-view-if-needed"));I();co();mo();j=require("react/jsx-runtime"),Lt=(0,R.createContext)(null),uo=(0,R.createContext)(null),Tt=class{items=[];single=!1;observer=null;onChange;callback(t){if(t.length===0)return;let o=!1;if(this.items=this.items.map(r=>{let n=t.find(a=>a.target.id===r.id),s=n?n.isIntersecting:r.active&&!r.fallback;return this.single&&o&&(s=!1),r.active!==s&&(r={...r,t:Date.now(),active:s,fallback:!1}),s&&(o=!0),r}),!o&&t[0].rootBounds){let r=t[0].rootBounds.top,n=Number.MAX_VALUE,s=-1;for(let a=0;a<this.items.length;a++){let l=document.getElementById(this.items[a].id);if(!l)continue;let c=Math.abs(r-l.getBoundingClientRect().top);c<n&&(s=a,n=c)}s!==-1&&(this.items[s]={...this.items[s],active:!0,fallback:!0,t:Date.now()})}this.onChange?.()}setItems(t){let o=this.observer;if(o)for(let r of this.items){let n=document.getElementById(r.id);n&&o.unobserve(n)}this.items=[];for(let r of t){let n=wt(r.url);n&&this.items.push({id:n,active:!1,fallback:!1,t:0,original:r})}this.watchItems(),typeof window<"u"&&(setTimeout(()=>this.watchItems(),100),setTimeout(()=>this.watchItems(),500),setTimeout(()=>this.watchItems(),1e3)),this.onChange?.()}watch(t){this.observer||(this.observer=new IntersectionObserver(this.callback.bind(this),t),this.watchItems())}watchItems(){if(this.observer)for(let t of this.items){let o=document.getElementById(t.id);o&&this.observer.observe(o)}}unwatch(){this.observer?.disconnect(),this.observer=null}};_r=({children:e,className:t})=>(0,j.jsx)("nav",{className:m("sticky top-navbar hidden xl:flex flex-col shrink-0","w-toc","py-8 pl-6 pr-4",t),children:e}),Fr=({children:e,className:t,...o})=>(0,j.jsx)("div",{className:m("mb-4 text-xs font-bold uppercase tracking-wider text-text-main",t),...o,children:e}),bo=({children:e,className:t,ref:o,...r})=>{let n=(0,R.useRef)(null);(0,R.useImperativeHandle)(o,()=>n.current);let{isOverflowing:s,isAtBottom:a}=Gr(n);return(0,j.jsx)("div",{ref:n,className:m("relative overflow-y-auto boltdocs-otp-content",s&&!a&&"mask-[linear-gradient(to_bottom,black_85%,transparent_100%)]",t),...r,children:e})};bo.displayName="OnThisPageContent";Wr=({children:e,className:t})=>(0,j.jsx)("ul",{className:m("relative space-y-1 text-sm border-l border-border-subtle",t),children:e}),Ur=({level:e,children:t,className:o})=>(0,j.jsx)("li",{className:m(e===3&&"pl-3",o),children:t}),jr=({children:e,href:t,active:o,onClick:r,className:n})=>{let s=(0,R.use)(Lt),a=(0,R.use)(uo),l=t?wt(t):null,c=(0,R.useRef)(null),[f,d]=(0,R.useState)(o);return lo(l&&s?s.find(p=>p.id===l)?.active:null,p=>{p!==null&&p!==f&&(d(!!p),p&&c.current&&a?.current&&(0,po.default)(c.current,{behavior:"smooth",block:"center",inline:"center",scrollMode:"if-needed",boundary:a.current}))}),(0,R.useEffect)(()=>{o!==void 0&&d(o)},[o]),(0,j.jsx)("a",{ref:c,href:t,onClick:r,"data-active":f,className:m("block py-1 pl-4 text-[13px] outline-none transition-colors hover:text-text-main",f?"text-primary-500 font-medium":"text-text-muted",n),children:e})},Kr=({style:e,className:t})=>(0,j.jsx)("div",{className:m("absolute -left-px w-0.5 rounded-full bg-primary-500 transition-all duration-300",t),style:e}),le={OnThisPageRoot:_r,OnThisPageHeader:Fr,OnThisPageContent:bo,OnThisPageList:Wr,OnThisPageItem:Ur,OnThisPageLink:jr,OnThisPageIndicator:Kr}});var xo,Ke,$,qr,Xr,Zr,Qr,Jr,ie,St=y(()=>{"use strict";i();xo=V(require("react-aria-components")),Ke=require("lucide-react");I();$=require("react/jsx-runtime"),qr=({children:e,className:t})=>(0,$.jsx)("nav",{className:m("grid grid-cols-1 sm:grid-cols-2 gap-4 mt-12 pt-8 border-t border-border-subtle",t),children:e}),Xr=({children:e,to:t,direction:o,className:r})=>{let n=o==="next";return(0,$.jsxs)(xo.Link,{href:t,className:m("flex group items-center p-4 rounded-xl border border-border-subtle bg-bg-surface outline-none","transition-all hover:bg-bg-main hover:border-primary-500 hover:shadow-lg","focus-visible:ring-2 focus-visible:ring-primary-500/30",n?"text-right justify-end":"text-left justify-start",r),children:[!n&&(0,$.jsx)(Ke.ChevronLeft,{className:"mr-3 h-5 w-5 text-text-muted group-hover:text-primary-500 transition-transform group-hover:-translate-x-1"}),(0,$.jsx)("div",{className:"flex flex-col gap-1 flex-1",children:e}),n&&(0,$.jsx)(Ke.ChevronRight,{className:"ml-3 h-5 w-5 text-text-muted group-hover:text-primary-500 transition-transform group-hover:translate-x-1"})]})},Zr=({children:e,className:t})=>(0,$.jsx)("span",{className:m("text-xs font-medium uppercase tracking-wider text-text-muted",t),children:e}),Qr=({children:e,className:t})=>(0,$.jsx)("span",{className:m("text-base font-bold text-text-main truncate",t),children:e}),Jr=({children:e})=>(0,$.jsx)($.Fragment,{children:e}),ie={PageNavRoot:qr,PageNavLink:Object.assign(Xr,{Title:Zr,Description:Qr,Icon:Jr})}});var be,Yr,en,tn,on,rn,It,Bt=y(()=>{"use strict";i();I();be=require("react/jsx-runtime"),Yr=({children:e,className:t="",...o})=>(0,be.jsx)("div",{className:m("w-full",t),...o,children:e}),en=({children:e,className:t=""})=>(0,be.jsx)("div",{role:"tablist",className:m("relative flex flex-row items-center border-b border-border-subtle",t),children:e}),tn=({children:e,id:t,selected:o,className:r="",...n})=>(0,be.jsx)("button",{role:"tab","aria-selected":o,className:m("flex items-center gap-2 px-4 py-2 text-sm font-medium transition-colors outline-none cursor-pointer bg-transparent border-none",o?"text-primary-500":"text-text-muted hover:text-text-main",r),...n,children:e}),on=({children:e,className:t=""})=>(0,be.jsx)("div",{className:m("p-4 outline-none",t),children:e}),rn=({className:e="",style:t})=>(0,be.jsx)("div",{className:m("absolute bottom-0 h-0.5 bg-primary-500 transition-all duration-300",e),style:t}),It={TabsRoot:Yr,TabsList:en,TabsItem:tn,TabsContent:on,TabsIndicator:rn}});function Ie(e){let t=F(),{currentLocale:o,currentVersion:r}=k();if(!t||typeof e!="string"||e.startsWith("http")||e.startsWith("//"))return e;let n=t.i18n,s=t.versions;if(!n&&!s)return e;let a=e.startsWith("/docs"),l=e.split("/").filter(Boolean),c=0;l[c]==="docs"&&c++,s&&l.length>c&&s.versions.find(v=>v.path===l[c])&&c++,n&&l.length>c&&n.locales[l[c]]&&c++;let f=l.slice(c),d=[];a&&(d.push("docs"),s&&r&&d.push(r)),n&&o&&o!==n.defaultLocale&&d.push(o),d.push(...f);let p=`/${d.join("/")}`;return p.length>1&&p.endsWith("/")?p.slice(0,-1):p||"/"}var Mt=y(()=>{"use strict";i();pe();W()});var At,vo,Co,Ot,z,nn,Be=y(()=>{"use strict";i();At=V(require("react")),vo=require("react-aria-components"),Co=require("react-router-dom");Mt();mt();I();Ot=require("react/jsx-runtime"),z=At.default.forwardRef((e,t)=>{let{href:o,prefetch:r="hover",onMouseEnter:n,onFocus:s,...a}=e,l=Ie(o??""),{preload:c}=He();return(0,Ot.jsx)(vo.Link,{...a,ref:t,href:l,onMouseEnter:p=>{n?.(p),r==="hover"&&typeof l=="string"&&l.startsWith("/")&&c(l)},onFocus:p=>{s?.(p),r==="hover"&&typeof l=="string"&&l.startsWith("/")&&c(l)}})});z.displayName="Link";nn=At.default.forwardRef((e,t)=>{let{href:o,end:r=!1,className:n,children:s,...a}=e,l=(0,Co.useLocation)(),c=Ie(o??""),f=r?l.pathname===c:l.pathname.startsWith(c),d=typeof n=="function"?n({isActive:f}):m(n,f&&"active"),p=typeof s=="function"?s({isActive:f}):s;return(0,Ot.jsx)(z,{...a,ref:t,href:o,className:d,children:p})});nn.displayName="NavLink"});var yo,No,M,sn,an,ln,cn,mn,xe,Et=y(()=>{"use strict";i();Be();yo=V(require("react-aria-components")),No=require("lucide-react");I();M=require("react/jsx-runtime"),sn=({badge:e})=>{let t={new:"bg-primary-500/20 text-primary-500",updated:"bg-gray-500/20 text-gray-500",deprecated:"bg-red-500/20 text-red-500"};if(typeof e=="object"&&e?.expires){let r=new Date(e.expires),n=new Date,s=r.getTime()-n.getTime();if(Math.ceil(s/(1e3*60*60*24))===0)return null}let o=typeof e=="string"?e:e?.text;return(0,M.jsx)("span",{className:m("ml-auto flex h-4.5 items-center rounded-full text-[9px] font-medium px-1.5 py-0.5 text-center whitespace-nowrap",t[o]||t.new),children:o})},an=({children:e,className:t})=>(0,M.jsx)("aside",{className:m("boltdocs-sidebar sticky top-navbar hidden lg:flex flex-col shrink-0","w-sidebar h-full","overflow-y-auto border-r border-border-subtle bg-bg-main","py-6 px-4",t),children:(0,M.jsx)("nav",{className:"flex-1 space-y-6",children:e})}),ln=({children:e,title:t,icon:o,isOpen:r=!0,onToggle:n,className:s})=>(0,M.jsxs)("div",{className:m("space-y-1",s),children:[t&&(0,M.jsxs)(yo.Button,{onPress:n,className:m("flex w-full items-center justify-between px-2 py-1.5 text-xs font-bold uppercase tracking-wider outline-none cursor-pointer","text-text-muted hover:text-text-main transition-colors","focus-visible:ring-2 focus-visible:ring-primary-500/30 rounded-md"),children:[(0,M.jsxs)("div",{className:"flex items-center gap-2",children:[o&&(0,M.jsx)(o,{size:14}),t]}),(0,M.jsx)(No.ChevronRight,{size:14,className:m("transition-transform duration-200",r&&"rotate-90")})]}),r&&(0,M.jsx)("div",{className:"space-y-0.5",children:e})]}),cn=({children:e,className:t})=>(0,M.jsx)("div",{className:m(t),children:e}),mn=({label:e,href:t,active:o,icon:r,badge:n,className:s})=>(0,M.jsxs)(z,{href:t,className:m("group flex items-center gap-2.5 rounded-lg px-2.5 py-2 text-sm outline-none transition-colors","focus-visible:ring-2 focus-visible:ring-primary-500/30",o?"bg-primary-500/10 text-primary-500 font-medium":"text-text-muted hover:bg-bg-surface hover:text-text-main",s),children:[r&&(0,M.jsx)(r,{size:16,className:m(o?"text-primary-500":"text-text-muted group-hover:text-text-main")}),(0,M.jsx)("span",{className:"truncate",children:e}),n&&(0,M.jsx)(sn,{badge:n})]}),xe={SidebarRoot:an,SidebarGroup:ln,SidebarGroupItem:cn,SidebarLink:mn}});var qe,Ro,G,Po,Y,Vt=y(()=>{"use strict";i();qe=V(require("react-aria-components"));I();Ro=require("class-variance-authority"),G=require("react/jsx-runtime"),Po=(0,Ro.cva)("flex flex-row items-center justify-center w-auto font-semibold tracking-tight no-underline whitespace-nowrap select-none outline-none transition-all duration-200 cursor-pointer pressed:scale-[0.97] hover:-translate-y-px leading-none",{variants:{variant:{primary:"bg-primary-500 text-white shadow-md hover:brightness-110 hover:shadow-lg",secondary:"bg-bg-surface text-text-main border border-border-subtle hover:bg-bg-muted hover:border-border-strong",outline:"bg-transparent text-text-main border border-border-strong hover:bg-bg-surface hover:border-primary-500",ghost:"bg-transparent text-text-muted hover:bg-bg-surface hover:text-text-main",danger:"bg-[var(--color-danger-500)]/10 text-[var(--color-danger-500)] border border-[var(--color-danger-500)]/20 hover:bg-[var(--color-danger-500)]/15",success:"bg-[var(--color-success-500)]/10 text-[var(--color-success-500)] border border-[var(--color-success-500)]/20 hover:bg-[var(--color-success-500)]/15",warning:"bg-[var(--color-warning-500)]/10 text-[var(--color-warning-500)] border border-[var(--color-warning-500)]/20 hover:bg-[var(--color-warning-500)]/15",info:"bg-[var(--color-info-500)]/10 text-[var(--color-info-500)] border border-[var(--color-info-500)]/20 hover:bg-[var(--color-info-500)]/15",subtle:"bg-primary-500/10 text-primary-500 hover:bg-primary-500/20",link:"bg-transparent text-primary-500 !p-0 !min-h-0 hover:underline"},size:{sm:"min-h-8 px-3.5 text-[0.8125rem] gap-1.5",md:"min-h-10 px-5 text-[0.9375rem] gap-2",lg:"min-h-12 px-7 text-[1.05rem] gap-2.5"},rounded:{none:"rounded-none",sm:"rounded-sm",md:"rounded-md",lg:"rounded-lg",full:"rounded-full"},iconSize:{sm:"w-8 h-8 p-0",md:"w-10 h-10 p-0",lg:"w-12 h-12 p-0"},disabled:{true:"opacity-50 cursor-not-allowed pointer-events-none",false:null}},defaultVariants:{variant:"primary",size:"md",rounded:"md"}}),Y=({href:e,icon:t,iconPosition:o="left",isIconOnly:r,children:n,className:s,variant:a,size:l,rounded:c,iconSize:f,disabled:d,...p})=>{let u=r||!n&&!!t,v=u?(0,G.jsx)("span",{className:"inline-flex items-center justify-center [&>svg]:w-[1.2rem] [&>svg]:h-[1.2rem]",children:t}):(0,G.jsxs)(G.Fragment,{children:[t&&o==="left"&&(0,G.jsx)("span",{className:"inline-flex items-center shrink-0 [&>svg]:w-[1.1rem] [&>svg]:h-[1.1rem]",children:t}),(0,G.jsx)("span",{className:"flex items-center",children:n}),t&&o==="right"&&(0,G.jsx)("span",{className:"inline-flex items-center shrink-0 [&>svg]:w-[1.1rem] [&>svg]:h-[1.1rem]",children:t})]});return e?(0,G.jsx)(qe.Link,{href:e,className:m(Po({variant:a,size:l,rounded:c,iconSize:u?f:void 0,disabled:d}),s),...p,children:v}):(0,G.jsx)(qe.Button,{className:m(Po({variant:a,size:l,rounded:c,iconSize:u?f:void 0,disabled:d}),s),...p,children:v})}});var To,wo,Lo=y(()=>{"use strict";i();I();To=require("react/jsx-runtime"),wo=({children:e,className:t,vertical:o=!1})=>(0,To.jsx)("div",{className:m("inline-flex",o?"flex-col":"flex-row",!o&&["[&>*:not(:first-child)]:-ml-px","[&>*:first-child]:rounded-r-none","[&>*:last-child]:rounded-l-none","[&>*:not(:first-child):not(:last-child)]:rounded-none",t?.includes("rounded-full")&&["[&>*:first-child]:rounded-l-full","[&>*:last-child]:rounded-r-full"],t?.includes("rounded-xl")&&["[&>*:first-child]:rounded-l-xl","[&>*:last-child]:rounded-r-xl"],t?.includes("rounded-lg")&&["[&>*:first-child]:rounded-l-lg","[&>*:last-child]:rounded-r-lg"]],o&&["[&>*:not(:first-child)]:-mt-px","[&>*:first-child]:rounded-b-none","[&>*:last-child]:rounded-t-none","[&>*:not(:first-child):not(:last-child)]:rounded-none",t?.includes("rounded-full")&&["[&>*:first-child]:rounded-t-full","[&>*:last-child]:rounded-b-full"]],t),children:e})});var Ce,ve,Dt,Ht=y(()=>{"use strict";"use client";i();Ce=V(require("react-aria-components"));I();ve=require("react/jsx-runtime"),Dt=({children:e,className:t,showArrow:o,...r})=>(0,ve.jsxs)(Ce.Popover,{offset:8,...r,className:Ce.composeRenderProps(t,n=>m("z-50 overflow-auto rounded-xl border border-border-subtle bg-bg-surface/80 shadow-xl backdrop-blur-md outline-none","entering:animate-in entering:fade-in entering:zoom-in-95 exiting:animate-out exiting:fade-out exiting:zoom-out-95 fill-mode-forwards",n)),children:[o&&(0,ve.jsx)(Ce.OverlayArrow,{className:"group",children:(0,ve.jsx)("svg",{viewBox:"0 0 12 12",className:"block h-3 w-3 fill-bg-surface/80 stroke-border-subtle group-placement-bottom:rotate-180 group-placement-left:-rotate-90 group-placement-right:rotate-90","aria-hidden":"true",children:(0,ve.jsx)("path",{d:"M0 0 L6 6 L12 0"})})}),e]})});function fe(e){let[t,o]=zt.default.Children.toArray(e.children).slice(0,2);return(0,T.jsxs)(L.MenuTrigger,{...e,children:[t,(0,T.jsx)(Dt,{placement:e.placement,className:"min-w-[200px]",children:o})]})}function pn(e){let[t,o]=zt.default.Children.toArray(e.children).slice(0,2);return(0,T.jsxs)(L.SubmenuTrigger,{...e,children:[t,(0,T.jsx)(Dt,{offset:-4,crossOffset:-4,children:o})]})}function ge(e){return(0,T.jsx)(L.Menu,{...e,className:L.composeRenderProps(e.className,t=>m("p-1.5 outline-none max-h-[inherit] overflow-auto",t))})}function U(e){let t=e.textValue||(typeof e.children=="string"?e.children:void 0);return(0,T.jsx)(L.MenuItem,{...e,textValue:t,className:L.composeRenderProps(e.className,(o,{isFocused:r,isPressed:n,isDisabled:s})=>m("group relative flex flex-row items-center gap-2.5 px-3 py-1.5 rounded-lg outline-none cursor-default transition-all duration-200","text-text-main text-[0.8125rem]",r&&"bg-primary-500/10 text-primary-600 shadow-sm",n&&"scale-[0.98] bg-primary-500/15",s&&"opacity-40 grayscale pointer-events-none",o)),children:L.composeRenderProps(e.children,(o,{selectionMode:r,isSelected:n,hasSubmenu:s})=>(0,T.jsxs)(T.Fragment,{children:[r!=="none"&&(0,T.jsxs)("span",{className:"flex items-center w-4 h-4 shrink-0 justify-center",children:[n&&r==="multiple"&&(0,T.jsx)(ye.Check,{className:"w-3.5 h-3.5 stroke-[2.5px] text-primary-500 animate-in zoom-in-50 duration-200"}),n&&r==="single"&&(0,T.jsx)(ye.Dot,{className:"w-6 h-6 text-primary-500 animate-in zoom-in-50 duration-200"})]}),(0,T.jsx)("div",{className:"flex-1 flex flex-row items-center gap-2.5 truncate font-medium",children:o}),s&&(0,T.jsx)(ye.ChevronRight,{className:"w-4 h-4 ml-auto text-text-muted group-focused:text-primary-500/70 transition-colors"})]}))})}function un({title:e,...t}){return(0,T.jsxs)(L.MenuSection,{...t,className:m("flex flex-col gap-0.5",t.className),children:[e&&(0,T.jsx)(L.Header,{className:"px-3 py-2 text-[10px] font-bold uppercase tracking-[0.075em] text-text-muted/50 select-none",children:e}),(0,T.jsx)(L.Collection,{items:t.items,children:t.children})]})}function dn(e){return(0,T.jsx)(L.Separator,{...e,className:"mx-2 my-1.5 border-t border-border-subtle/50"})}var ye,zt,L,T,ee,Xe=y(()=>{"use strict";"use client";i();ye=require("lucide-react"),zt=V(require("react")),L=V(require("react-aria-components"));Ht();I();T=require("react/jsx-runtime");ee={Root:ge,Item:U,Trigger:fe,SubTrigger:pn,Section:un,Separator:dn}});var $t,Gt,ko=y(()=>{"use strict";i();$t=V(require("react-aria-components"));I();Gt=require("react/jsx-runtime")});var he,Ue=y(()=>{"use strict";i();We();ao();Rt();kt();St();Bt();Et();dt();Vt();Lo();Xe();Ht();ko();Be();he=require("react-aria-components");I()});function jo(e){let{currentLocale:t,currentVersion:o}=k(),[r,n]=(0,Ae.useState)(!1),[s,a]=(0,Ae.useState)(""),l=(0,Ae.useMemo)(()=>{let c=e.filter(u=>{let v=!t||u.locale===t,N=!o||u.version===o;return v&&N});if(!s)return c.slice(0,10).map(u=>({id:u.path,title:u.title,path:u.path,bio:u.description||"",groupTitle:u.groupTitle}));let f=[],d=s.toLowerCase();for(let u of c)if(u.title?.toLowerCase().includes(d)&&f.push({id:u.path,title:u.title,path:u.path,bio:u.description||"",groupTitle:u.groupTitle}),u.headings)for(let v of u.headings)v.text.toLowerCase().includes(d)&&f.push({id:`${u.path}#${v.id}`,title:v.text,path:`${u.path}#${v.id}`,bio:`Heading in ${u.title}`,groupTitle:u.title,isHeading:!0});let p=new Set;return f.filter(u=>p.has(u.path)?!1:(p.add(u.path),!0)).slice(0,10)},[e,s,t,o]);return{isOpen:r,setIsOpen:n,query:s,setQuery:a,list:l,input:{value:s,onChange:c=>a(c.target.value)}}}var Ae,Ko=y(()=>{"use strict";i();Ae=require("react");W()});var Xo={};Ut(Xo,{SearchDialog:()=>_t});function _t({routes:e}){let{isOpen:t,setIsOpen:o,query:r,setQuery:n,list:s}=jo(e),a=(0,qo.useNavigate)();(0,nt.useEffect)(()=>{let c=f=>{(/Mac/.test(navigator.userAgent)?f.metaKey:f.ctrlKey)&&(f.key==="k"||f.key==="j")&&(f.preventDefault(),o(u=>!u))};return window.addEventListener("keydown",c),()=>window.removeEventListener("keydown",c)},[o]);let l=(0,nt.useCallback)(c=>{let f=String(c);if(o(!1),f.includes("#")){let[d,p]=f.split("#");a(d),setTimeout(()=>{let u=document.getElementById(p);u&&u.scrollIntoView({behavior:"smooth"})},100)}else a(f)},[a,o]);return(0,E.jsxs)(E.Fragment,{children:[(0,E.jsx)(O.SearchTrigger,{onPress:()=>o(!0)}),(0,E.jsx)(ht,{isOpen:t,onOpenChange:o,children:(0,E.jsxs)(bt,{onSelectionChange:l,children:[(0,E.jsx)(xt,{value:r,onChange:c=>n(c.target.value)}),(0,E.jsx)(vt,{items:s,children:c=>(0,E.jsxs)(Ct,{onPress:()=>l(c.id),textValue:c.title,children:[(0,E.jsx)(yt,{isHeading:c.isHeading}),(0,E.jsxs)("div",{className:"flex flex-col justify-center gap-0.5",children:[(0,E.jsx)(Nt,{children:c.title}),(0,E.jsx)(Pt,{children:c.groupTitle})]})]},c.id)})]})})]})}var nt,qo,E,Ft=y(()=>{"use strict";i();nt=require("react");Ko();Rt();We();qo=require("react-router-dom"),E=require("react/jsx-runtime")});var Ln={};Ut(Ln,{Breadcrumbs:()=>oo,CopyMarkdown:()=>Io,ErrorBoundary:()=>Ze,GithubStars:()=>Je,Head:()=>Eo,Loading:()=>Vo,Navbar:()=>Qo,NotFound:()=>Yo,OnThisPage:()=>or,PageNav:()=>nr,PoweredBy:()=>it,ProgressBar:()=>ar,SearchDialog:()=>_t,Sidebar:()=>pr,Tabs:()=>rt,ThemeToggle:()=>ot});module.exports=vr(Ln);i();i();i();W();function Xt(){let{currentRoute:e}=k(),t=[];return e&&(e.groupTitle&&t.push({label:e.groupTitle}),t.push({label:e.title,href:e.path})),{crumbs:t,activeRoute:e}}var to=require("lucide-react");dt();I();pe();var Q=require("react/jsx-runtime");function oo(){let{crumbs:e,activeRoute:t}=Xt(),r=F().theme||{};return e.length===0||!r?.breadcrumbs?null:(0,Q.jsxs)(Yt,{children:[(0,Q.jsx)(pt,{children:(0,Q.jsx)(ut,{href:"/",children:(0,Q.jsx)(to.Home,{size:14})})}),e.map((n,s)=>(0,Q.jsxs)(pt,{children:[(0,Q.jsx)(eo,{}),(0,Q.jsx)(ut,{href:n.href,className:m({"font-medium text-text-main":n.href===t?.path}),children:n.label})]},`crumb-${n.href}-${n.label}-${s}`))]})}i();var So=require("react"),te=require("lucide-react");Ue();var S=require("react/jsx-runtime"),fn=e=>{let[t,o]=(0,So.useState)(!1);return{copied:t,handleCopy:()=>{navigator.clipboard.writeText(e),o(!0),setTimeout(()=>o(!1),2e3)},handleOpenRaw:()=>{let s=new Blob([e],{type:"text/plain;charset=utf-8"}),a=URL.createObjectURL(s);window.open(a,"_blank")}}};function Io({content:e,mdxRaw:t,config:o}){let r=t||e||"",{copied:n,handleCopy:s,handleOpenRaw:a}=fn(r),l=o!==!1,c=typeof o=="object"&&o.text||"Copy Markdown";return!l||!r?null:(0,S.jsx)("div",{className:"relative inline-flex z-100 flex-shrink-0 w-max translate-y-0 active:translate-y-px transition-transform duration-200",children:(0,S.jsxs)(wo,{className:"rounded-xl border border-border-subtle bg-bg-surface/40 backdrop-blur-md transition-all duration-300 hover:border-primary-500/50 hover:shadow-lg hover:shadow-primary-500/5 group overflow-hidden",children:[(0,S.jsx)(Y,{variant:"ghost",onPress:s,icon:n?(0,S.jsx)(te.Check,{size:16}):(0,S.jsx)(te.Copy,{size:16}),iconPosition:"left",className:m("px-5 py-2 bg-transparent text-[0.8125rem] font-semibold h-9 border-none shrink-0","text-text-main transition-all duration-300 hover:bg-primary-500/5",n&&"text-emerald-500 hover:bg-emerald-500/5"),children:n?"Copied!":c}),(0,S.jsxs)(fe,{placement:"bottom end",children:[(0,S.jsx)(Y,{variant:"ghost",isIconOnly:!0,icon:(0,S.jsx)(te.ChevronDown,{size:14}),className:m("px-3.5 h-9 border-l border-border-subtle/50 text-text-muted rounded-none bg-transparent shrink-0","transition-all duration-300 hover:bg-primary-500/5 hover:text-primary-500")}),(0,S.jsxs)(ge,{className:"w-52",children:[(0,S.jsxs)(U,{onAction:s,className:"flex flex-row items-start gap-2.5 group",children:[(0,S.jsx)(te.Copy,{size:16,className:"w-4 h-4 shrink-0 mt-0.5 transition-transform duration-200 group-hover:-translate-y-0.5 text-text-muted group-hover:text-primary-500"}),(0,S.jsx)("span",{className:"font-medium text-[0.8125rem]",children:"Copy Markdown"})]}),(0,S.jsxs)(U,{onAction:a,className:"flex flex-row items-start gap-2.5 group",children:[(0,S.jsx)(te.ExternalLink,{size:16,className:"w-4 h-4 shrink-0 mt-0.5 transition-transform duration-200 group-hover:-translate-y-0.5 text-text-muted group-hover:text-primary-500"}),(0,S.jsx)("span",{className:"font-medium text-[0.8125rem]",children:"View as Markdown"})]})]})]})]})})}i();var Bo=require("react");Ue();var Ne=require("react/jsx-runtime"),Ze=class extends Bo.Component{state={hasError:!1};static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,o){console.error("Uncaught error in Boltdocs Layout:",t,o)}render(){return this.state.hasError?this.props.fallback||(0,Ne.jsxs)("div",{className:"flex flex-col items-center justify-center min-h-[40vh] text-center gap-4 px-4",children:[(0,Ne.jsx)("div",{className:"text-lg font-bold text-red-400",children:"Something went wrong"}),(0,Ne.jsx)("p",{className:"text-sm text-text-muted max-w-md",children:this.state.error?.message||"An unexpected error occurred while rendering this page."}),(0,Ne.jsx)(Y,{className:"rounded-lg border border-border-subtle bg-bg-surface px-5 py-2 text-sm font-medium text-text-main transition-colors hover:bg-bg-muted cursor-pointer",onPress:()=>this.setState({hasError:!1}),children:"Try again"})]}):this.props.children}};i();var Qe=require("react");i();var gn="https://api.github.com";async function Mo(e,t,o=gn){let r=new Headers;t&&r.append("authorization",t);let s=await(await fetch(`${o}/repos/${e}`,{headers:r})).json();return s.stargazers_count!==void 0?hn(s.stargazers_count):"0"}var hn=e=>Intl.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(e);ft();var Me=require("react/jsx-runtime");function Je({repo:e}){let[t,o]=(0,Qe.useState)(null);return(0,Qe.useEffect)(()=>{e&&Mo(e).then(r=>o(r)).catch(()=>o("0"))},[e]),(0,Me.jsxs)("a",{href:`https://github.com/${e}`,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 rounded-md border border-border-subtle bg-bg-surface px-2.5 py-1.5 text-xs font-medium text-text-muted transition-all hover:bg-bg-main hover:border-border-strong hover:text-text-main",children:[(0,Me.jsx)(_e,{className:"h-4 w-4"}),t&&(0,Me.jsx)("span",{className:"tabular-nums",children:t})]})}i();var Ao=require("react"),Oo=require("react-router-dom");function Eo({siteTitle:e,siteDescription:t,routes:o}){let r=(0,Oo.useLocation)();return(0,Ao.useEffect)(()=>{let n=o.find(f=>f.path===r.pathname),s=n?.title,a=n?.description||t||"";document.title=s?`${s} | ${e}`:e;let l=document.querySelector('meta[name="description"]');l||(l=document.createElement("meta"),l.name="description",document.head.appendChild(l)),l.content=a,ce("property","og:title",document.title),ce("property","og:description",a),ce("property","og:type","article"),ce("property","og:url",window.location.href),ce("name","twitter:card","summary"),ce("name","twitter:title",document.title),ce("name","twitter:description",a);let c=document.querySelector('link[rel="canonical"]');c||(c=document.createElement("link"),c.rel="canonical",document.head.appendChild(c)),c.href=window.location.origin+r.pathname},[r.pathname,e,t,o]),null}function ce(e,t,o){let r=document.querySelector(`meta[${e}="${t}"]`);r||(r=document.createElement("meta"),r.setAttribute(e,t),document.head.appendChild(r)),r.content=o}i();var Ye=require("react"),H=require("react/jsx-runtime");function Vo(){let[e,t]=(0,Ye.useState)(0);(0,Ye.useEffect)(()=>{let r=0,n=!0,s=setInterval(()=>{n?(r+=1,r>=100&&(r=100,n=!1)):(r-=1,r<=0&&(r=0,n=!0)),t(r)},20);return()=>clearInterval(s)},[]);let o=`inset(${100-e}% 0 0 0)`;return(0,H.jsx)("div",{className:"flex flex-col items-center justify-center min-h-[60vh] p-4 text-center",children:(0,H.jsx)("div",{className:"relative group",children:(0,H.jsxs)("div",{className:"relative inline-block",children:[(0,H.jsxs)("svg",{className:"w-24 h-auto opacity-10 filter grayscale brightness-50",viewBox:"0 0 60 51",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:"img","aria-hidden":"true",children:[(0,H.jsx)("title",{children:"Loading indicator background"}),(0,H.jsx)("path",{d:"M29.4449 0H19.4449V16.5L29.4449 6.5V0Z",fill:"currentColor"}),(0,H.jsx)("path",{d:"M26.9449 22.7265C26.9449 22.5077 21.2201 27.0658 16.9449 28.5C13.7491 29.5721 12.3156 29.5038 8.94486 29.5C5.59532 29.4963 0 28.5 0 28.5C0 28.5 5.57953 28.5146 8.94486 27.5C12.5409 26.4158 14.8203 25.5843 17.9449 23.5C23.3445 19.898 29.4449 11.5 29.4449 11.5L29.9449 18C29.9449 18 33.5825 15.8308 36.4449 15C39.4452 14.1291 44.4449 14 44.4449 14C44.4449 14 36.9449 19 34.4449 21.5C31.5322 24.4126 29.8582 26.9017 29.4449 31C29.1217 34.2041 29.4771 36.4508 31.4449 39C33.5792 41.765 35.952 43.0183 39.4449 43C42.677 42.9831 45.3003 42.4182 47.4449 40C49.7406 37.4113 50.2495 34.4466 49.9449 31C49.6603 27.7804 48.4876 25.4953 45.9449 23.5C43.2931 21.4191 36.4449 24 36.4449 24L47.9449 15C47.9449 15 51.5761 16.771 53.4449 18.5C55.711 20.5967 56.7467 22.1546 57.9449 25C59.1784 27.9295 59.4832 29.8216 59.4449 33C59.4089 35.9867 59.179 37.78 57.9449 40.5C56.8475 42.9185 55.8511 44.6507 53.9449 46.5C51.9236 48.4609 50.5803 49.0076 47.9449 50C45.5414 50.9051 44.0131 51 41.4449 51C38.8766 51 37.3235 50.9685 34.9449 50C32.4851 48.9985 29.4449 46 29.4449 46V51H19.4449V37.9904L22.9449 31.4226L26.9449 22.7265Z",fill:"currentColor"})]}),(0,H.jsxs)("svg",{className:"absolute top-0 left-0 w-24 h-auto text-primary-500 drop-shadow-[0_0_20px_rgba(var(--primary-rgb),0.5)] transition-[clip-path] duration-100 ease-linear",style:{clipPath:o},viewBox:"0 0 60 51",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:"img","aria-hidden":"true",children:[(0,H.jsx)("title",{children:"Loading indicator animated fill"}),(0,H.jsx)("path",{d:"M29.4449 0H19.4449V16.5L29.4449 6.5V0Z",fill:"currentColor"}),(0,H.jsx)("path",{d:"M26.9449 22.7265C26.9449 22.5077 21.2201 27.0658 16.9449 28.5C13.7491 29.5721 12.3156 29.5038 8.94486 29.5C5.59532 29.4963 0 28.5 0 28.5C0 28.5 5.57953 28.5146 8.94486 27.5C12.5409 26.4158 14.8203 25.5843 17.9449 23.5C23.3445 19.898 29.4449 11.5 29.4449 11.5L29.9449 18C29.9449 18 33.5825 15.8308 36.4449 15C39.4452 14.1291 44.4449 14 44.4449 14C44.4449 14 36.9449 19 34.4449 21.5C31.5322 24.4126 29.8582 26.9017 29.4449 31C29.1217 34.2041 29.4771 36.4508 31.4449 39C33.5792 41.765 35.952 43.0183 39.4449 43C42.677 42.9831 45.3003 42.4182 47.4449 40C49.7406 37.4113 50.2495 34.4466 49.9449 31C49.6603 27.7804 48.4876 25.4953 45.9449 23.5C43.2931 21.4191 36.4449 24 36.4449 24L47.9449 15C47.9449 15 51.5761 16.771 53.4449 18.5C55.711 20.5967 56.7467 22.1546 57.9449 25C59.1784 27.9295 59.4832 29.8216 59.4449 33C59.4089 35.9867 59.179 37.78 57.9449 40.5C56.8475 42.9185 55.8511 44.6507 53.9449 46.5C51.9236 48.4609 50.5803 49.0076 47.9449 50C45.5414 50.9051 44.0131 51 41.4449 51C38.8766 51 37.3235 50.9685 34.9449 50C32.4851 48.9985 29.4449 46 29.4449 46V51H19.4449V37.9904L22.9449 31.4226L26.9449 22.7265Z",fill:"currentColor"})]})]})})})}i();var st=require("react");i();var Do=require("react-router-dom");pe();i();var Pe=require("react"),xn=require("react/jsx-runtime"),bn=(0,Pe.createContext)(void 0);function et(){let e=(0,Pe.use)(bn);if(e===void 0)throw new Error("useTheme must be used within a ThemeProvider");return e}i();function Re(e,t){return e?typeof e=="string"?e:t&&e[t]?e[t]:Object.values(e)[0]||"":""}W();function Ho(){let e=F(),{theme:t}=et(),o=(0,Do.useLocation)(),{currentLocale:r}=k(),n=e.theme||{},s=Re(n.title,r)||"Boltdocs",a=n.navbar||[],l=n.socialLinks||[],c=n.githubRepo,f=a.map(N=>{let C=N.href||N.to||N.link||"";return{label:Re(N.label||N.text,r),href:C,active:o.pathname===C,to:C.startsWith("http")||C.startsWith("//")?"external":void 0,items:N.items?.map(h=>({label:Re(h.label||h.text,r),href:h.href||h.link||h.to||""}))}}),d=n.logo,p=d?typeof d=="string"?d:t==="dark"?d.dark:d.light:null,u={alt:(d&&typeof d=="object"?d.alt:void 0)||s,width:d&&typeof d=="object"?d.width:void 0,height:d&&typeof d=="object"?d.height:void 0},v=c?`https://github.com/${c}`:null;return{links:f,title:s,logo:p,logoProps:u,github:v,social:l,config:e,theme:t}}i();var zo=require("react-router-dom");i();function ae(e,t,o){let r=e;return t&&(r===t||r.startsWith(t+"/"))&&(r=r===t?"index.md":r.slice(t.length+1)),o&&(r===o||r.startsWith(o+"/"))&&(r=r===o?"index.md":r.slice(o.length+1)),r}W();$e();function $o(){let e=(0,zo.useNavigate)(),t=k(),{allRoutes:o,currentRoute:r,currentVersion:n,currentLocale:s,config:a}=t,l=a.versions,c=ne(p=>p.setVersion),f=p=>{if(!l||p===n)return;c(p);let u=`/docs/${p}`;if(r){let v=ae(r.filePath,r.version,r.locale),N=o.find(C=>ae(C.filePath,C.version,C.locale)===v&&(C.version||l.defaultVersion)===p&&(s?C.locale===s:!C.locale));if(N)u=N.path;else{let C=o.find(h=>ae(h.filePath,h.version,h.locale)==="index.md"&&(h.version||l.defaultVersion)===p&&(s?h.locale===s:!h.locale));u=C?C.path:`/docs/${p}${s?`/${s}`:""}`}}e(u)},d=t.availableVersions.map(p=>({...p,label:p.label,value:p.key}));return{currentVersion:n,currentVersionLabel:t.currentVersionLabel,availableVersions:d,handleVersionChange:f}}i();var Go=require("react-router-dom");W();$e();function _o(){let e=(0,Go.useNavigate)(),t=k(),{allRoutes:o,currentRoute:r,currentLocale:n,config:s}=t,a=s.i18n,l=ne(u=>u.setLocale),c=u=>{if(!a||u===n)return;l(u);let v="/";if(r){let N=ae(r.filePath,r.version,r.locale),C=o.find(h=>ae(h.filePath,h.version,h.locale)===N&&(h.locale||a.defaultLocale)===u&&h.version===r.version);if(C)v=C.path;else{let h=o.find(Z=>ae(Z.filePath,Z.version,Z.locale)==="index.md"&&(Z.locale||a.defaultLocale)===u&&Z.version===r.version);v=h?h.path:u===a.defaultLocale?r.version?`/${r.version}`:"/":r.version?`/${r.version}/${u}`:`/${u}`}}else{let N=o.find(C=>(C.filePath==="index.mdx"||C.filePath==="index.md")&&(C.locale||a.defaultLocale)===u&&!C.version);N?v=N.path:v=u===a.defaultLocale?"/":`/${u}`}e(v)},d=s.i18n?.localeConfigs?.[n]?.label||s.i18n?.locales[n]||n,p=s.i18n?Object.entries(s.i18n.locales).map(([u,v])=>{let N=s.i18n?.localeConfigs?.[u];return{key:u,label:N?.label||v,value:u,isCurrent:u===n}}):[];return{currentLocale:n,currentLocaleLabel:d,availableLocales:p,handleLocaleChange:c}}W();We();i();var tt=require("react"),oe=require("lucide-react");var Fo=require("react-aria-components");Xe();var A=require("react/jsx-runtime");function ot(){let{theme:e,setTheme:t}=et(),[o,r]=(0,tt.useState)(!1);return(0,tt.useEffect)(()=>{r(!0)},[]),o?(0,A.jsxs)(fe,{placement:"bottom right",children:[(0,A.jsx)(Fo.Button,{className:"flex h-9 w-9 items-center justify-center rounded-md text-text-muted transition-colors hover:bg-bg-surface hover:text-text-main outline-none focus-visible:ring-2 focus-visible:ring-primary-500","aria-label":"Selection theme",children:(0,A.jsx)(e==="system"?oe.Monitor:e==="dark"?oe.Moon:oe.Sun,{size:20,className:"animate-in fade-in zoom-in duration-300"})}),(0,A.jsxs)(ge,{selectionMode:"single",selectedKeys:[e],onSelectionChange:s=>{let a=Array.from(s)[0];t(a)},children:[(0,A.jsxs)(U,{id:"light",children:[(0,A.jsx)(oe.Sun,{size:16}),(0,A.jsx)("span",{children:"Light"})]}),(0,A.jsxs)(U,{id:"dark",children:[(0,A.jsx)(oe.Moon,{size:16}),(0,A.jsx)("span",{children:"Dark"})]}),(0,A.jsxs)(U,{id:"system",children:[(0,A.jsx)(oe.Monitor,{size:16}),(0,A.jsx)("span",{children:"System"})]})]})]}):(0,A.jsx)("div",{className:"h-9 w-9"})}i();i();var Wo=require("react-router-dom"),we=require("react");function Uo(e=[],t=[]){let o=(0,Wo.useLocation)(),r=(0,we.useRef)([]),[n,s]=(0,we.useState)({opacity:0,transform:"translateX(0) scaleX(0)",width:0}),l=t.find(d=>d.path===o.pathname)?.tab?.toLowerCase(),c=e.findIndex(d=>d.id.toLowerCase()===l),f=c===-1?0:c;return(0,we.useEffect)(()=>{let d=r.current[f];d&&s({opacity:1,width:d.offsetWidth,transform:`translateX(${d.offsetLeft}px)`})},[f,e.length,o.pathname]),{tabs:e,activeIndex:f,indicatorStyle:n,tabRefs:r,activeTabId:l}}Bt();Be();var vn=V(require("lucide-react"));W();var K=require("react/jsx-runtime");function rt({tabs:e,routes:t}){let{currentLocale:o}=k(),{indicatorStyle:r,tabRefs:n,activeIndex:s}=Uo(e,t),a=l=>{if(!l)return null;if(l.trim().startsWith("<svg"))return(0,K.jsx)("span",{className:"h-4 w-4",dangerouslySetInnerHTML:{__html:l}});let c=vn[l];return c?(0,K.jsx)(c,{size:16}):(0,K.jsx)("img",{src:l,alt:"",className:"h-4 w-4 object-contain"})};return(0,K.jsx)("div",{className:"mx-auto max-w-(--breakpoint-3xl) px-4 md:px-6",children:(0,K.jsxs)(It.TabsList,{className:"border-none py-0",children:[e.map((l,c)=>{let f=c===s,d=t.find(u=>u.tab&&u.tab.toLowerCase()===l.id.toLowerCase()),p=d?d.path:"#";return(0,K.jsxs)(z,{href:p,ref:u=>{n.current[c]=u},className:`relative flex items-center gap-2 px-4 py-3 text-sm font-medium transition-colors outline-none ${f?"text-primary-500":"text-text-muted hover:text-text-main"}`,children:[a(l.icon),(0,K.jsx)("span",{children:Re(l.text,o)})]},l.id)}),(0,K.jsx)(It.TabsIndicator,{style:r})]})})}var Zo=require("react-router-dom");Xe();Vt();var Oe=require("lucide-react");Mt();var b=require("react/jsx-runtime"),Cn=(0,st.lazy)(()=>Promise.resolve().then(()=>(Ft(),Xo)).then(e=>({default:e.SearchDialog})));function Qo(){let{links:e,title:t,logo:o,logoProps:r,github:n,social:s,config:a}=Ho(),{routes:l,allRoutes:c,currentVersion:f,currentLocale:d}=k(),{pathname:p}=(0,Zo.useLocation)(),u=a.theme||{},v=u?.tabs&&u.tabs.length>0;return(0,b.jsxs)(O.NavbarRoot,{className:v?"border-b-0":"",children:[(0,b.jsxs)(O.Content,{children:[(0,b.jsxs)(O.NavbarLeft,{children:[(0,b.jsx)(O.NavbarLogo,{src:o??"",alt:r?.alt||t,width:r?.width??24,height:r?.height??24}),(0,b.jsx)(O.Title,{children:t}),a.versions&&f&&(0,b.jsx)(Nn,{}),(0,b.jsx)(O.Links,{children:e.map(N=>(0,b.jsx)(yn,{link:N},N.href))})]}),(0,b.jsx)(O.NavbarCenter,{children:(0,b.jsx)(st.Suspense,{fallback:(0,b.jsx)("div",{className:"h-9 w-32 animate-pulse rounded-md bg-bg-surface"}),children:(0,b.jsx)(Cn,{routes:l||[]})})}),(0,b.jsxs)(O.NavbarRight,{children:[a.i18n&&d&&(0,b.jsx)(Pn,{}),(0,b.jsx)(O.Split,{}),(0,b.jsx)(ot,{}),n&&(0,b.jsx)(Je,{repo:u?.githubRepo??""}),s.length>0&&(0,b.jsx)(O.Split,{}),(0,b.jsx)("div",{className:"flex items-center gap-1",children:s.map(({icon:N,link:C})=>(0,b.jsx)(O.Socials,{icon:N,link:C,className:"p-1.5"},C))})]})]}),p!=="/"&&v&&u?.tabs&&(0,b.jsx)("div",{className:"w-full border-b border-border-subtle bg-bg-main",children:(0,b.jsx)(rt,{tabs:u.tabs,routes:c||l||[]})})]})}function yn({link:e}){let t=Ie(e.href);return(0,b.jsx)(O.Link,{...e,href:t})}function Nn(){let{currentVersionLabel:e,availableVersions:t,handleVersionChange:o}=$o();return t.length===0?null:(0,b.jsxs)(ee.Trigger,{children:[(0,b.jsx)(Y,{variant:"outline",size:"sm",rounded:"lg",iconPosition:"right",icon:(0,b.jsx)(Oe.ChevronDown,{className:"w-3.5 h-3.5 text-text-muted/60"}),className:"h-8 border-border-subtle/60 bg-bg-surface/30 backdrop-blur-sm transition-all duration-200 hover:border-primary-500/50 hover:bg-primary-500/5",children:(0,b.jsx)("span",{className:"font-semibold text-[0.8125rem]",children:e})}),(0,b.jsx)(ee.Root,{children:(0,b.jsx)(ee.Section,{items:t,children:r=>(0,b.jsx)(ee.Item,{onPress:()=>o(r.value),children:r.label},`${r.value??""}`)})})]})}function Pn(){let{currentLocale:e,availableLocales:t,handleLocaleChange:o}=_o();return t.length===0?null:(0,b.jsxs)(ee.Trigger,{children:[(0,b.jsx)(Y,{variant:"outline",size:"sm",rounded:"lg",iconPosition:"right",icon:(0,b.jsx)(Oe.ChevronDown,{className:"w-3.5 h-3.5 text-text-muted/60"}),className:"h-8 border-border-subtle/60 bg-bg-surface/30 backdrop-blur-sm transition-all duration-200 hover:border-primary-500/50 hover:bg-primary-500/5 px-2.5",children:(0,b.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,b.jsx)(Oe.Languages,{className:"w-3.5 h-3.5 text-primary-500"}),(0,b.jsx)("span",{className:"font-bold text-[0.75rem] tracking-wider uppercase opacity-90",children:e||"en"})]})}),(0,b.jsx)(ee.Root,{children:(0,b.jsx)(ee.Section,{items:t,children:r=>(0,b.jsx)(ee.Item,{onPress:()=>o(r.value),children:(0,b.jsxs)("div",{className:"flex items-center justify-between w-full gap-4",children:[(0,b.jsx)("span",{children:r.label}),(0,b.jsx)("span",{className:"text-[10px] font-bold opacity-40 uppercase tracking-tighter",children:r.value})]})},`${r.value??""}`)})})]})}i();var Jo=require("lucide-react");Be();var re=require("react/jsx-runtime");function Yo(){return(0,re.jsx)("div",{className:"flex items-center justify-center min-h-[60vh] text-center",children:(0,re.jsxs)("div",{className:"space-y-4",children:[(0,re.jsx)("span",{className:"text-8xl font-black tracking-tighter text-primary-500/20",children:"404"}),(0,re.jsx)("h1",{className:"text-2xl font-bold text-text-main",children:"Page Not Found"}),(0,re.jsx)("p",{className:"text-sm text-text-muted max-w-sm mx-auto",children:"The page you're looking for doesn't exist or has been moved."}),(0,re.jsxs)(z,{href:"/",className:"inline-flex items-center gap-2 rounded-lg bg-primary-500 px-5 py-2.5 text-sm font-semibold text-white outline-none transition-all hover:brightness-110 hover:shadow-lg focus-visible:ring-2 focus-visible:ring-primary-500/30",children:[(0,re.jsx)(Jo.ArrowLeft,{size:16})," Go to Home"]})]})})}i();kt();var _=V(require("react"));i();var er=require("react");function tr(e=[]){let[t,o]=(0,er.useState)(null);return{headings:e,activeId:t,setActiveId:o}}var Te=require("lucide-react"),w=require("react/jsx-runtime");function or({headings:e=[],editLink:t,communityHelp:o,filePath:r}){let{headings:n}=tr(e),s=_.default.useMemo(()=>n.map(a=>({title:a.text,url:`#${a.id}`,depth:a.level})),[n]);return n.length===0?null:(0,w.jsx)(ho,{toc:s,children:(0,w.jsx)(Rn,{headings:n,editLink:t,communityHelp:o,filePath:r})})}function Rn({headings:e,editLink:t,communityHelp:o,filePath:r}){let n=fo(),[s,a]=(0,_.useState)({opacity:0}),l=(0,_.useRef)(null),c=(0,_.useRef)(null);(0,_.useEffect)(()=>{if(!n||!l.current)return;let d=l.current.querySelector(`a[href="#${n}"]`);d&&a({transform:`translateY(${d.offsetTop}px)`,height:`${d.offsetHeight}px`,opacity:1})},[n]);let f=(0,_.useCallback)((d,p)=>{d.preventDefault();let u=document.getElementById(p);u&&(u.scrollIntoView({behavior:"smooth"}),window.history.pushState(null,"",`#${p}`))},[]);return(0,w.jsxs)(le.OnThisPageRoot,{children:[(0,w.jsxs)(le.OnThisPageHeader,{className:"flex flex-row gap-x-2",children:[(0,w.jsx)(Te.TextAlignStart,{size:16}),"On this page"]}),(0,w.jsx)(go,{containerRef:c,children:(0,w.jsxs)(le.OnThisPageContent,{className:"max-h-[450px] boltdocs-otp-scroll-area",ref:c,children:[(0,w.jsx)(le.OnThisPageIndicator,{style:s}),(0,w.jsx)("ul",{className:"relative space-y-2 border-l border-border-subtle",ref:l,children:e.map(d=>(0,w.jsx)(le.OnThisPageItem,{level:d.level,children:(0,w.jsx)(le.OnThisPageLink,{href:`#${d.id}`,active:n===d.id,onClick:p=>f(p,d.id),className:"pl-4",children:d.text})},d.id))})]})}),(t||o)&&(0,w.jsxs)("div",{className:"mt-8 pt-8 border-t border-border-subtle space-y-4",children:[(0,w.jsx)("p",{className:"text-xs font-bold uppercase tracking-wider text-text-main",children:"Need help?"}),(0,w.jsxs)("ul",{className:"space-y-3",children:[t&&r&&(0,w.jsx)("li",{children:(0,w.jsxs)("a",{href:t.replace(":path",r),target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 text-sm text-text-muted hover:text-text-main transition-colors",children:[(0,w.jsx)(Te.Pencil,{size:16}),"Edit this page"]})}),o&&(0,w.jsx)("li",{children:(0,w.jsxs)("a",{href:o,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 text-sm text-text-muted hover:text-text-main transition-colors",children:[(0,w.jsx)(Te.CircleHelp,{size:16}),"Community help"]})})]})]})]})}i();i();W();function rr(){let{routes:e}=k(),t=window.location.pathname,o=e.findIndex(a=>a.path===t),r=e[o],n=o>0?e[o-1]:null,s=o<e.length-1?e[o+1]:null;return{prevPage:n,nextPage:s,currentRoute:r}}St();var q=require("react/jsx-runtime");function nr(){let{prevPage:e,nextPage:t}=rr();return!e&&!t?null:(0,q.jsxs)(ie.PageNavRoot,{children:[e?(0,q.jsxs)(ie.PageNavLink,{to:e.path,direction:"prev",children:[(0,q.jsx)(ie.PageNavLink.Title,{children:"Previous"}),(0,q.jsx)(ie.PageNavLink.Description,{children:e.title})]}):(0,q.jsx)("div",{}),t&&(0,q.jsxs)(ie.PageNavLink,{to:t.path,direction:"next",children:[(0,q.jsx)(ie.PageNavLink.Title,{children:"Next"}),(0,q.jsx)(ie.PageNavLink.Description,{children:t.title})]})]})}i();var sr=require("lucide-react"),me=require("react/jsx-runtime");function it(){return(0,me.jsx)("div",{className:"flex items-center justify-center mt-10 mb-4 px-4 w-full",children:(0,me.jsxs)("a",{href:"https://github.com/jesusalcaladev/boltdocs",target:"_blank",rel:"noopener noreferrer",className:"group relative flex items-center gap-2 px-4 py-2 rounded-full border border-border-subtle bg-bg-surface/50 backdrop-blur-md transition-all duration-300 hover:border-primary-500/50 hover:bg-bg-surface hover:shadow-xl hover:shadow-primary-500/5 select-none",children:[(0,me.jsx)(sr.Zap,{className:"w-3.5 h-3.5 text-text-muted group-hover:text-primary-500 transition-colors duration-300",fill:"currentColor"}),(0,me.jsxs)("span",{className:"text-[11px] font-medium text-text-muted group-hover:text-text-main transition-colors duration-300 tracking-wide",children:["Powered by ",(0,me.jsx)("strong",{className:"font-bold text-text-main/80 group-hover:text-text-main",children:"Boltdocs"})]})]})})}i();var at=require("react"),ir=require("react-aria-components"),Wt=require("react/jsx-runtime");function ar(){let[e,t]=(0,at.useState)(0);return(0,at.useEffect)(()=>{let o=null,r,n=()=>{if(!o)return;let{scrollTop:a,scrollHeight:l,clientHeight:c}=o;if(l<=c){t(0);return}let f=a/(l-c)*100;t(Math.min(100,Math.max(0,f)))},s=()=>(o=document.querySelector(".boltdocs-content"),o?(o.addEventListener("scroll",n),n(),r&&clearInterval(r),!0):!1);return s()||(r=setInterval(s,100)),()=>{o&&o.removeEventListener("scroll",n),r&&clearInterval(r)}},[]),(0,Wt.jsx)(ir.ProgressBar,{value:e,"aria-label":"Reading progress",className:"fixed top-0 left-0 right-0 z-999 h-0.5 bg-transparent w-full pointer-events-none",children:({percentage:o})=>(0,Wt.jsx)("div",{className:"h-full bg-primary-500 transition-[width] duration-300 ease-out shadow-[0_0_8px_rgba(var(--primary-rgb),0.4)]",style:{width:`${o}%`}})})}Ft();i();var Le=require("react");i();var lr=require("react-router-dom");pe();function cr(e){let t=F(),o=(0,lr.useLocation)(),r=p=>p.endsWith("/")&&p.length>1?p.slice(0,-1):p,n=r(o.pathname),s=e.find(p=>r(p.path)===n),a=s?.tab?.toLowerCase(),l=a?e.filter(p=>!p.tab||p.tab.toLowerCase()===a):e,c=[],f=new Map;for(let p of l)p.group?(f.has(p.group)||f.set(p.group,{slug:p.group,title:p.groupTitle||p.group,routes:[],icon:p.groupIcon}),f.get(p.group).routes.push(p)):c.push(p);return{groups:Array.from(f.values()),ungrouped:c,activeRoute:s,activePath:n,config:t}}Et();var wn=V(require("lucide-react")),X=require("react/jsx-runtime");function mr(e){return e&&wn[e]||void 0}function Tn({group:e,activePath:t,getIcon:o}){let r=(0,Le.useMemo)(()=>e.routes.some(a=>a.path===t),[e.routes,t]),[n,s]=(0,Le.useState)(!0);return(0,Le.useEffect)(()=>{r&&s(!0)},[r]),(0,X.jsx)(xe.SidebarGroup,{title:e.title,isOpen:n,onToggle:()=>s(!n),children:e.routes.map(a=>{let l=t===(a.path.endsWith("/")?a.path.slice(0,-1):a.path);return(0,X.jsx)(xe.SidebarLink,{label:a.title,href:a.path,active:l,icon:o(a.icon),badge:a.badge},a.path)})})}function pr({routes:e,config:t}){let{groups:o,ungrouped:r,activePath:n}=cr(e),s=t.theme||{};return(0,X.jsxs)(xe.SidebarRoot,{children:[r.length>0&&(0,X.jsx)(xe.SidebarGroup,{className:"mb-6",children:r.map(a=>{let l=n===(a.path.endsWith("/")?a.path.slice(0,-1):a.path);return(0,X.jsx)(xe.SidebarLink,{label:a.title,href:a.path,active:l,icon:mr(a.icon),badge:a.badge},a.path)})}),o.map(a=>(0,X.jsx)(Tn,{group:a,activePath:n,getIcon:mr},a.slug)),s?.poweredBy&&(0,X.jsx)("div",{className:"mt-auto pt-8",children:(0,X.jsx)(it,{})})]})}
|
|
1
|
+
"use strict";var vr=Object.create;var Fe=Object.defineProperty;var br=Object.getOwnPropertyDescriptor;var yr=Object.getOwnPropertyNames;var Cr=Object.getPrototypeOf,Nr=Object.prototype.hasOwnProperty;var N=(e,t)=>()=>(e&&(t=e(e=0)),t);var Xt=(e,t)=>{for(var o in t)Fe(e,o,{get:t[o],enumerable:!0})},Jt=(e,t,o,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of yr(t))!Nr.call(e,n)&&n!==o&&Fe(e,n,{get:()=>t[n],enumerable:!(r=br(t,n))||r.enumerable});return e};var D=(e,t,o)=>(o=e!=null?vr(Cr(e)):{},Jt(t||!e||!e.__esModule?Fe(o,"default",{value:e,enumerable:!0}):o,e)),Pr=e=>Jt(Fe({},"__esModule",{value:!0}),e);var a=N(()=>{"use strict"});function _(){let e=(0,Ue.use)(wr);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e}var Ue,wr,xe=N(()=>{"use strict";a();Ue=require("react"),wr=(0,Ue.createContext)(null)});function je(){return(0,ve.use)(Rr)}var ve,Tr,Rr,ft=N(()=>{"use strict";a();ve=require("react"),Tr=require("react/jsx-runtime"),Rr=(0,ve.createContext)({preload:()=>{},routes:[]})});var Qt,_e,re,Ke=N(()=>{"use strict";a();Qt=require("zustand"),_e=require("zustand/middleware"),re=(0,Qt.create)()((0,_e.persist)(e=>({currentLocale:void 0,currentVersion:void 0,hasHydrated:!1,setLocale:t=>e({currentLocale:t}),setVersion:t=>e({currentVersion:t}),setHasHydrated:t=>e({hasHydrated:t})}),{name:"boltdocs-storage",storage:(0,_e.createJSONStorage)(()=>localStorage),partialize:e=>({currentLocale:e.currentLocale,currentVersion:e.currentVersion}),onRehydrateStorage:()=>e=>{e?.setHasHydrated(!0)}}))});function S(){let{routes:e}=je(),t=_(),o=(0,Yt.useLocation)(),r=re(h=>h.currentLocale),n=re(h=>h.currentVersion),s=re(h=>h.hasHydrated),i=e.find(h=>h.path===o.pathname),l=t.i18n?i?.locale||(s?r:void 0)||t.i18n.defaultLocale:void 0,c=t.versions?i?.version||(s?n:void 0)||t.versions.defaultVersion:void 0,g=e.filter(h=>{let A=t.i18n?(h.locale||t.i18n.defaultLocale)===l:!0,pe=t.versions?(h.version||t.versions.defaultVersion)===c:!0;if(!(A&&pe))return!1;let he=t.i18n;if(he){let Be=!!i?.locale,Ae=!!h.locale;if(e.some(G=>G!==h&&G.filePath===h.filePath&&G.version===h.version&&(G.locale||he.defaultLocale)===(h.locale||he.defaultLocale))&&Be!==Ae)return!1}return!0}),p=t.i18n?.localeConfigs?.[l]?.label||t.i18n?.locales[l]||l,C=t.versions?.versions.find(h=>h.path===c)?.label||c,v=t.i18n?Object.entries(t.i18n.locales).map(([h,A])=>{let pe=t.i18n?.localeConfigs?.[h];return{key:h,label:pe?.label||A,isCurrent:h===l}}):[],b=t.versions?t.versions.versions.map(h=>({key:h.path,label:h.label,isCurrent:h.path===c})):[];return{routes:g,allRoutes:e,currentRoute:i,currentLocale:l,currentLocaleLabel:p,availableLocales:v,currentVersion:c,currentVersionLabel:C,availableVersions:b,config:t}}var Yt,K=N(()=>{"use strict";a();Yt=require("react-router-dom");xe();ft();Ke()});function m(...e){return(0,to.twMerge)((0,eo.clsx)(e))}var eo,to,I=N(()=>{"use strict";a();eo=require("clsx"),to=require("tailwind-merge")});var be,oo,Me,ro,gt,ht,no,xt=N(()=>{"use strict";a();be=require("react-aria-components"),oo=require("lucide-react");I();Me=require("react/jsx-runtime"),ro=({children:e,className:t,...o})=>(0,Me.jsx)(be.Breadcrumbs,{className:m("flex items-center gap-1.5 pl-0! mb-0 text-sm text-text-muted",t),...o,children:e}),gt=({children:e,className:t,...o})=>(0,Me.jsx)(be.Breadcrumb,{className:m("flex items-center mb-0 gap-1.5",t),...o,children:e}),ht=({children:e,href:t,className:o,...r})=>(0,Me.jsx)(be.Link,{href:t,className:m("transition-colors outline-none hover:text-text-main focus-visible:ring-2 focus-visible:ring-primary-500/30 rounded-sm","current:font-medium current:text-text-main current:pointer-events-none cursor-pointer",o),...r,children:e}),no=({className:e})=>(0,Me.jsx)(oo.ChevronRight,{size:14,className:m("shrink-0 text-text-dim",e)})});function qe(e){let{size:t=20,...o}=e;return{...o,width:t,height:t}}var $,Xe,io,lo,co,vt=N(()=>{"use strict";a();$=require("react/jsx-runtime");Xe=e=>(0,$.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",...qe(e),children:[(0,$.jsx)("title",{children:"GitHub"}),(0,$.jsx)("path",{d:"M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"})]}),io=e=>(0,$.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",...qe(e),children:[(0,$.jsx)("title",{children:"Discord"}),(0,$.jsx)("path",{d:"M20.317 4.37a19.791 19.791 0 0 0-4.885-1.515.074.074 0 0 0-.079.037c-.21.375-.444.864-.608 1.25a18.27 18.27 0 0 0-5.487 0 12.64 12.64 0 0 0-.617-1.25.077.077 0 0 0-.079-.037A19.736 19.736 0 0 0 3.677 4.37a.07.07 0 0 0-.032.027C.533 9.046-.32 13.58.099 18.057a.082.082 0 0 0 .031.057 19.9 19.9 0 0 0 5.993 3.03.078.078 0 0 0 .084-.028c.462-.63.874-1.295 1.226-1.994a.076.076 0 0 0-.041-.106 13.107 13.107 0 0 1-1.872-.892.077.077 0 0 1-.008-.128 10.2 10.2 0 0 0 .372-.292.074.074 0 0 1 .077-.01c3.928 1.793 8.18 1.793 12.062 0a.074.074 0 0 1 .078.01c.12.098.246.198.373.292a.077.077 0 0 1-.006.127 12.299 12.299 0 0 1-1.873.892.077.077 0 0 0-.041.107c.36.698.772 1.362 1.225 1.993a.076.076 0 0 0 .084.028 19.839 19.839 0 0 0 6.002-3.03.077.077 0 0 0 .032-.054c.5-5.177-.838-9.674-3.549-13.66a.061.061 0 0 0-.031-.03zM8.02 15.33c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.956-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.956 2.418-2.157 2.418zm7.975 0c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.955-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.946 2.418-2.157 2.418Z"})]}),lo=e=>(0,$.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",...qe(e),children:[(0,$.jsx)("title",{children:"X"}),(0,$.jsx)("path",{d:"M14.234 10.162 22.977 0h-2.072l-7.591 8.824L7.251 0H.258l9.168 13.343L.258 24H2.33l8.016-9.318L16.749 24h6.993zm-2.837 3.299-.929-1.329L3.076 1.56h3.182l5.965 8.532.929 1.329 7.754 11.09h-3.182z"})]}),co=e=>(0,$.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",...qe(e),children:[(0,$.jsx)("title",{children:"Bluesky"}),(0,$.jsx)("path",{d:"M5.202 2.857C7.954 4.922 10.913 9.11 12 11.358c1.087-2.247 4.046-6.436 6.798-8.501C20.783 1.366 24 .213 24 3.883c0 .732-.42 6.156-.667 7.037-.856 3.061-3.978 3.842-6.755 3.37 4.854.826 6.089 3.562 3.422 6.299-5.065 5.196-7.28-1.304-7.847-2.97-.104-.305-.152-.448-.153-.327 0-.121-.05.022-.153.327-.568 1.666-2.782 8.166-7.847 2.97-2.667-2.737-1.432-5.473 3.422-6.3-2.777.473-5.899-.308-6.755-3.369C.42 10.04 0 4.615 0 3.883c0-3.67 3.217-2.517 5.202-1.026"})]})});var Je,mo,ne,y,kr,Sr,Ir,Br,Ar,Mr,Or,Er,zr,Dr,Vr,Hr,$r,Wr,V,Qe=N(()=>{"use strict";a();Je=require("react");Ye();mo=require("react-aria-components"),ne=require("lucide-react");vt();y=require("react/jsx-runtime"),kr=({children:e,className:t,...o})=>(0,y.jsx)("header",{className:m("boltdocs-navbar sticky top-0 z-50 w-full border-b border-border-subtle bg-bg-main/80 backdrop-blur-md",t),...o,children:e}),Sr=({children:e,className:t})=>(0,y.jsx)("div",{className:m("mx-auto flex lg:h-navbar max-w-(--breakpoint-3xl) items-center justify-between px-4 md:px-6",t),children:e}),Ir=({children:e,className:t})=>(0,y.jsx)("div",{className:m("flex flex-1 items-center justify-start gap-4 min-w-0",t),children:e}),Br=({children:e,className:t})=>(0,y.jsx)("div",{className:m("flex flex-1 items-center justify-end gap-2 md:gap-4 min-w-0",t),children:e}),Ar=({children:e,className:t})=>(0,y.jsx)("div",{className:m("hidden lg:flex flex-1 justify-center items-center gap-4 px-4 min-w-0 w-full",t),children:e}),Mr=({src:e,alt:t,width:o=24,height:r=24,className:n})=>(0,y.jsx)(W,{href:"/",className:m("flex items-center gap-2 shrink-0 outline-none",n),children:e?(0,y.jsx)("img",{src:e,alt:t,width:o,height:r,className:"h-6 w-6 object-contain"}):null}),Or=({children:e,className:t})=>(0,y.jsx)(W,{href:"/",children:(0,y.jsx)("span",{className:m("text-lg font-bold tracking-tight hidden sm:inline-block",t),children:e})}),Er=({children:e,className:t})=>(0,y.jsx)("nav",{className:m("hidden md:flex items-center gap-6 text-sm font-medium",t),children:e}),zr=({label:e,href:t,active:o,to:r,className:n})=>(0,y.jsxs)(W,{href:t,target:r==="external"?"_blank":void 0,className:m("transition-colors outline-none font-medium focus-visible:ring-2 focus-visible:ring-primary-500/30 rounded-sm",{"text-primary-500":o,"text-text-muted hover:text-text-main":!o},n),children:[e,r==="external"&&(0,y.jsx)("span",{className:"ml-1 inline-block",children:(0,y.jsx)(ne.ExternalLink,{size:12})})]}),Dr=({className:e,onPress:t})=>{let[o,r]=(0,Je.useState)(!1),n=o&&/Mac|iPod|iPhone|iPad/.test(navigator.platform);return(0,Je.useEffect)(()=>{r(!0)},[]),(0,y.jsxs)(mo.Button,{onPress:t,className:m("flex items-center gap-2 rounded-full border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-muted outline-none cursor-pointer","transition-all duration-200 hover:border-border-strong hover:text-text-main hover:bg-bg-muted hover:shadow-sm active:scale-[0.98]","focus-visible:ring-2 focus-visible:ring-primary-500/30","w-full max-w-[720px] justify-between",e),children:[(0,y.jsxs)("div",{className:"flex items-center gap-2",children:[(0,y.jsx)(ne.Search,{size:16}),(0,y.jsx)("span",{className:"hidden sm:inline-block",children:"Search docs..."})]}),(0,y.jsxs)("div",{className:"hidden sm:flex items-center gap-1 pointer-events-none select-none",children:[(0,y.jsx)("kbd",{className:"flex h-5 items-center justify-center rounded border border-border-subtle bg-bg-main px-1.5 font-mono text-[10px] font-medium",children:n?"\u2318":"Ctrl"}),(0,y.jsx)("kbd",{className:"flex h-5 w-5 items-center justify-center rounded border border-border-subtle bg-bg-main font-mono text-[10px] font-medium",children:"K"})]})]})},Vr=({className:e,theme:t,onThemeChange:o})=>(0,y.jsx)(ye.ToggleButton,{isSelected:t==="dark",onChange:o,className:m("rounded-md p-2 text-text-muted outline-none cursor-pointer","transition-all duration-300 hover:bg-bg-surface hover:text-text-main hover:rotate-12 active:scale-90","focus-visible:ring-2 focus-visible:ring-primary-500/30",e),"aria-label":"Toggle theme",children:t==="dark"?(0,y.jsx)(ne.Sun,{size:20}):(0,y.jsx)(ne.Moon,{size:20})}),Hr=({name:e})=>{if(e==="github")return(0,y.jsx)(Xe,{});if(e==="discord")return(0,y.jsx)(io,{});if(e==="x")return(0,y.jsx)(lo,{});if(e==="bluesky")return(0,y.jsx)(co,{})},$r=({icon:e,link:t,className:o})=>(0,y.jsx)(W,{href:t,target:"_blank",rel:"noopener noreferrer",className:m("rounded-md p-2 text-text-muted outline-none transition-colors","hover:bg-bg-surface hover:text-text-main","focus-visible:ring-2 focus-visible:ring-primary-500/30",o),children:(0,y.jsx)(Hr,{name:e})}),Wr=({className:e})=>(0,y.jsx)(ye.Separator,{orientation:"vertical",className:m("h-6 w-px bg-border-subtle mx-1",e)}),V={NavbarRoot:kr,NavbarLeft:Ir,NavbarRight:Br,NavbarCenter:Ar,NavbarLogo:Mr,Title:Or,Links:Er,Link:zr,SearchTrigger:Dr,Theme:Vr,Socials:$r,Split:Wr,Content:Sr}});var Oe,Gr,bt,po=N(()=>{"use strict";a();Oe=D(require("react-aria-components")),Gr=require("lucide-react");I();bt=require("react/jsx-runtime")});var M,ae,P,yt,Ct,Nt,Pt,wt,Rt,Tt,Lt,pa,kt=N(()=>{"use strict";a();M=D(require("react-aria-components")),ae=require("lucide-react");I();P=require("react/jsx-runtime"),yt=({children:e,isOpen:t,onOpenChange:o,className:r})=>(0,P.jsx)(M.ModalOverlay,{isOpen:t,onOpenChange:o,isDismissable:!0,className:m("fixed inset-0 z-100 bg-black/40 backdrop-blur-sm px-4 py-4 sm:py-20","entering:animate-in entering:fade-in exiting:animate-out exiting:fade-out"),children:(0,P.jsx)(M.Modal,{className:m("mx-auto w-full max-w-2xl overflow-hidden rounded-xl border border-border-subtle bg-bg-surface shadow-2xl ring-1 ring-black/5 outline-none","entering:animate-in entering:fade-in entering:zoom-in-95 exiting:animate-out exiting:fade-out exiting:zoom-out-95",r),children:(0,P.jsx)(M.Dialog,{className:"flex flex-col max-h-[70vh] focus:outline-none",children:e})})}),Ct=({children:e,className:t,onSelectionChange:o,...r})=>(0,P.jsx)("div",{className:t,children:(0,P.jsx)(M.Autocomplete,{...r,onSelectionChange:o,className:"flex flex-col min-h-0",children:e})}),Nt=({className:e,...t})=>(0,P.jsxs)(M.SearchField,{className:"flex items-center gap-3 border-b border-border-subtle px-4 py-4",autoFocus:!0,children:[(0,P.jsx)(ae.Search,{className:"h-5 w-5 text-text-muted"}),(0,P.jsx)(M.Input,{...t,className:m("w-full bg-transparent text-lg text-text-main placeholder-text-muted outline-none",e),placeholder:"Search documentation..."}),(0,P.jsx)("div",{className:"flex items-center gap-1.5 rounded-md border border-border-subtle bg-bg-main px-1.5 py-1 text-[10px] font-medium text-text-muted",children:(0,P.jsx)("kbd",{className:"font-sans",children:"ESC"})})]}),Pt=({children:e,className:t,...o})=>(0,P.jsx)(M.ListBox,{...o,className:m("flex-1 overflow-y-auto p-2 outline-none",t),children:e}),wt=({children:e,className:t,...o})=>(0,P.jsx)(M.ListBoxItem,{...o,className:m("group flex items-center gap-3 rounded-lg p-3 text-left outline-none cursor-pointer transition-colors","text-text-muted hover:bg-bg-main hover:text-text-main focus:bg-primary-500 focus:text-white selected:bg-primary-500 selected:text-white",t),children:r=>(0,P.jsxs)(P.Fragment,{children:[e,(r.isFocused||r.isSelected)&&(0,P.jsxs)("div",{className:"ml-auto opacity-50 flex items-center gap-1",children:[(0,P.jsx)("span",{className:"text-[10px]",children:"Select"}),(0,P.jsx)(ae.CornerDownLeft,{size:10})]})]})}),Rt=({isHeading:e,className:t})=>(0,P.jsx)("div",{className:m("shrink-0",t),children:e?(0,P.jsx)(ae.Hash,{size:18}):(0,P.jsx)(ae.FileText,{size:18})}),Tt=({children:e,className:t})=>(0,P.jsx)("span",{className:m("block font-medium truncate flex-1 text-sm",t),children:e}),Lt=({children:e,className:t})=>(0,P.jsx)("span",{className:m("ml-2 text-xs opacity-70 truncate hidden sm:inline group-focus:opacity-100",t),children:e}),pa={Root:yt,Autocomplete:Ct,Input:Nt,List:Pt,Item:Object.assign(wt,{Icon:Rt,Title:Tt,Bio:Lt})}});function uo(e,t){let o=(0,Ze.useRef)(e);(0,Ze.useEffect)(()=>{o.current!==e&&(t(e),o.current=e)},[e,t])}var Ze,fo=N(()=>{"use strict";a();Ze=require("react")});function St(e){return e.startsWith("#")?e.slice(1):null}var et,go=N(()=>{"use strict";a();et=class{items=[];single=!1;observer=null;onChange;callback(t){if(t.length===0)return;for(let r of t){let n=this.items.find(s=>s.id===r.target.id);if(n){n.active=r.isIntersecting;let s=100;n.fallback=!r.isIntersecting&&r.boundingClientRect.top<s}}let o=-1;for(let r=this.items.length-1;r>=0;r--)if(this.items[r].fallback){o=r;break}o===-1&&this.items.length>0&&(o=0),this.items=this.items.map((r,n)=>({...r,active:n===o,t:n===o?Date.now():r.t})),this.onChange?.()}setItems(t){let o=this.observer;if(o)for(let r of this.items){let n=document.getElementById(r.id);n&&o.unobserve(n)}this.items=[];for(let r of t){let n=St(r.url);n&&this.items.push({id:n,active:!1,fallback:!1,t:0,original:r})}this.watchItems(),typeof window<"u"&&(setTimeout(()=>this.watchItems(),100),setTimeout(()=>this.watchItems(),500),setTimeout(()=>this.watchItems(),1e3)),this.onChange?.()}watch(t){this.observer||(this.observer=new IntersectionObserver(this.callback.bind(this),t),this.watchItems())}watchItems(){if(this.observer)for(let t of this.items){let o=document.getElementById(t.id);o&&this.observer.observe(o)}}unwatch(){this.observer?.disconnect(),this.observer=null}}});function Fr(){let e=(0,R.use)(It);if(!e)throw new Error("Component must be used under the <AnchorProvider /> component.");return e}function vo(){let e=Fr();return(0,R.useMemo)(()=>{let t;for(let o of e)o.active&&(!t||o.t>t.t)&&(t=o);return t?.id},[e])}function bo({containerRef:e,children:t}){return(0,q.jsx)(xo.Provider,{value:e,children:t})}function yo({toc:e,single:t=!1,children:o}){let r=(0,R.useMemo)(()=>new et,[]),[n,s]=(0,R.useState)(r.items);return r.single=t,(0,R.useEffect)(()=>{r.setItems(e)},[r,e]),(0,R.useEffect)(()=>(r.watch({rootMargin:"-100px 0% 0% 0%",threshold:0}),r.onChange=()=>s([...r.items]),()=>{r.unwatch()}),[r]),(0,q.jsx)(It.Provider,{value:n,children:o})}var R,ho,q,It,xo,Ur,jr,Co,_r,Kr,qr,Xr,de,Bt=N(()=>{"use strict";a();R=require("react"),ho=D(require("scroll-into-view-if-needed"));I();fo();go();q=require("react/jsx-runtime"),It=(0,R.createContext)(null),xo=(0,R.createContext)(null);Ur=({children:e,className:t})=>(0,q.jsx)("nav",{className:m("sticky top-navbar hidden xl:flex flex-col shrink-0","w-toc","py-8 pl-6 pr-4",t),children:e}),jr=({children:e,className:t,...o})=>(0,q.jsx)("div",{className:m("mb-4 text-xs font-bold uppercase tracking-wider text-text-main",t),...o,children:e}),Co=({children:e,className:t,ref:o,...r})=>{let n=(0,R.useRef)(null);return(0,R.useImperativeHandle)(o,()=>n.current),(0,q.jsx)("div",{ref:n,className:m("relative overflow-y-auto boltdocs-otp-content",t),...r,children:e})};Co.displayName="OnThisPageContent";_r=({children:e,className:t})=>(0,q.jsx)("ul",{className:m("relative space-y-1 text-sm border-l border-border-subtle",t),children:e}),Kr=({level:e,children:t,className:o})=>(0,q.jsx)("li",{className:m(e===3&&"pl-3",o),children:t}),qr=({children:e,href:t,active:o,onClick:r,className:n})=>{let s=(0,R.use)(It),i=(0,R.use)(xo),l=t?St(t):null,c=(0,R.useRef)(null),[g,u]=(0,R.useState)(o);return uo(l&&s?s.find(p=>p.id===l)?.active:null,p=>{p!==null&&p!==g&&(u(!!p),p&&c.current&&i?.current&&(0,ho.default)(c.current,{behavior:"smooth",block:"center",inline:"center",scrollMode:"if-needed",boundary:i.current}))}),(0,R.useEffect)(()=>{o!==void 0&&u(o)},[o]),(0,q.jsx)("a",{ref:c,href:t,onClick:r,"data-active":g,className:m("block py-1 pl-4 text-[13px] outline-none transition-colors hover:text-text-main",g?"text-primary-500 font-medium":"text-text-muted",n),children:e})},Xr=({style:e,className:t})=>(0,q.jsx)("div",{className:m("absolute -left-px w-0.5 rounded-full bg-primary-500 transition-all duration-300",t),style:e}),de={OnThisPageRoot:Ur,OnThisPageHeader:jr,OnThisPageContent:Co,OnThisPageList:_r,OnThisPageItem:Kr,OnThisPageLink:qr,OnThisPageIndicator:Xr}});var No,tt,F,Jr,Qr,Yr,Zr,en,se,At=N(()=>{"use strict";a();No=D(require("react-aria-components")),tt=require("lucide-react");I();F=require("react/jsx-runtime"),Jr=({children:e,className:t})=>(0,F.jsx)("nav",{className:m("grid grid-cols-1 sm:grid-cols-2 gap-4 mt-12 pt-8 border-t border-border-subtle",t),children:e}),Qr=({children:e,to:t,direction:o,className:r})=>{let n=o==="next";return(0,F.jsxs)(No.Link,{href:t,className:m("flex group items-center p-4 rounded-xl border border-border-subtle bg-bg-surface outline-none","transition-all hover:bg-bg-main hover:border-primary-500 hover:shadow-lg","focus-visible:ring-2 focus-visible:ring-primary-500/30",n?"text-right justify-end":"text-left justify-start",r),children:[!n&&(0,F.jsx)(tt.ChevronLeft,{className:"mr-3 h-5 w-5 text-text-muted group-hover:text-primary-500 transition-transform group-hover:-translate-x-1"}),(0,F.jsx)("div",{className:"flex flex-col gap-1 flex-1",children:e}),n&&(0,F.jsx)(tt.ChevronRight,{className:"ml-3 h-5 w-5 text-text-muted group-hover:text-primary-500 transition-transform group-hover:translate-x-1"})]})},Yr=({children:e,className:t})=>(0,F.jsx)("span",{className:m("text-xs font-medium uppercase tracking-wider text-text-muted",t),children:e}),Zr=({children:e,className:t})=>(0,F.jsx)("span",{className:m("text-base font-bold text-text-main truncate",t),children:e}),en=({children:e})=>(0,F.jsx)(F.Fragment,{children:e}),se={PageNavRoot:Jr,PageNavLink:Object.assign(Qr,{Title:Yr,Description:Zr,Icon:en})}});var Ce,tn,on,rn,nn,an,Mt,Ot=N(()=>{"use strict";a();I();Ce=require("react/jsx-runtime"),tn=({children:e,className:t="",...o})=>(0,Ce.jsx)("div",{className:m("w-full",t),...o,children:e}),on=({children:e,className:t=""})=>(0,Ce.jsx)("div",{role:"tablist",className:m("relative flex flex-row items-center border-b border-border-subtle",t),children:e}),rn=({children:e,id:t,selected:o,className:r="",...n})=>(0,Ce.jsx)("button",{role:"tab","aria-selected":o,className:m("flex items-center gap-2 px-4 py-2 text-sm font-medium transition-colors outline-none cursor-pointer bg-transparent border-none",o?"text-primary-500":"text-text-muted hover:text-text-main",r),...n,children:e}),nn=({children:e,className:t=""})=>(0,Ce.jsx)("div",{className:m("p-4 outline-none",t),children:e}),an=({className:e="",style:t})=>(0,Ce.jsx)("div",{className:m("absolute bottom-0 h-0.5 bg-primary-500 transition-all duration-300",e),style:t}),Mt={TabsRoot:tn,TabsList:on,TabsItem:rn,TabsContent:nn,TabsIndicator:an}});function Ee(e){let t=_(),{currentLocale:o,currentVersion:r}=S();if(!t||typeof e!="string"||e.startsWith("http")||e.startsWith("//"))return e;let n=t.i18n,s=t.versions;if(!n&&!s)return e;let i=e.startsWith("/docs"),l=e.split("/").filter(Boolean),c=0;l[c]==="docs"&&c++,s&&l.length>c&&s.versions.find(C=>C.path===l[c])&&c++,n&&l.length>c&&n.locales[l[c]]&&c++;let g=l.slice(c),u=[];i&&(u.push("docs"),s&&r&&u.push(r)),n&&o&&o!==n.defaultLocale&&u.push(o),u.push(...g);let p=`/${u.join("/")}`;return p.length>1&&p.endsWith("/")?p.slice(0,-1):p||"/"}var Et=N(()=>{"use strict";a();xe();K()});var zt,Po,wo,Dt,W,sn,ze=N(()=>{"use strict";a();zt=D(require("react")),Po=require("react-aria-components"),wo=require("react-router-dom");Et();ft();I();Dt=require("react/jsx-runtime"),W=zt.default.forwardRef((e,t)=>{let{href:o,prefetch:r="hover",onMouseEnter:n,onFocus:s,...i}=e,l=Ee(o??""),{preload:c}=je();return(0,Dt.jsx)(Po.Link,{...i,ref:t,href:l,onMouseEnter:p=>{n?.(p),r==="hover"&&typeof l=="string"&&l.startsWith("/")&&c(l)},onFocus:p=>{s?.(p),r==="hover"&&typeof l=="string"&&l.startsWith("/")&&c(l)}})});W.displayName="Link";sn=zt.default.forwardRef((e,t)=>{let{href:o,end:r=!1,className:n,children:s,...i}=e,l=(0,wo.useLocation)(),c=Ee(o??""),g=r?l.pathname===c:l.pathname.startsWith(c),u=typeof n=="function"?n({isActive:g}):m(n,g&&"active"),p=typeof s=="function"?s({isActive:g}):s;return(0,Dt.jsx)(W,{...i,ref:t,href:o,className:u,children:p})});sn.displayName="NavLink"});var Ro,To,O,ln,cn,mn,pn,un,Ne,Vt=N(()=>{"use strict";a();ze();Ro=D(require("react-aria-components")),To=require("lucide-react");I();O=require("react/jsx-runtime"),ln=({badge:e})=>{let t={new:"bg-primary-500/20 text-primary-500",updated:"bg-gray-500/20 text-gray-500",deprecated:"bg-red-500/20 text-red-500"};if(typeof e=="object"&&e?.expires){let r=new Date(e.expires),n=new Date,s=r.getTime()-n.getTime();if(Math.ceil(s/(1e3*60*60*24))===0)return null}let o=typeof e=="string"?e:e?.text;return(0,O.jsx)("span",{className:m("ml-auto flex h-4.5 items-center rounded-full text-[9px] font-medium px-1.5 py-0.5 text-center whitespace-nowrap",t[o]||t.new),children:o})},cn=({children:e,className:t})=>(0,O.jsx)("aside",{className:m("boltdocs-sidebar sticky top-navbar hidden lg:flex flex-col shrink-0","w-sidebar h-full","overflow-y-auto border-r border-border-subtle bg-bg-main","py-6 px-4",t),children:(0,O.jsx)("nav",{className:"flex-1 space-y-6",children:e})}),mn=({children:e,title:t,icon:o,isOpen:r=!0,onToggle:n,className:s})=>(0,O.jsxs)("div",{className:m("space-y-1",s),children:[t&&(0,O.jsxs)(Ro.Button,{onPress:n,className:m("flex w-full items-center justify-between px-2 py-1.5 text-xs font-bold uppercase tracking-wider outline-none cursor-pointer","text-text-muted hover:text-text-main transition-colors","focus-visible:ring-2 focus-visible:ring-primary-500/30 rounded-md"),children:[(0,O.jsxs)("div",{className:"flex items-center gap-2",children:[o&&(0,O.jsx)(o,{size:14}),t]}),(0,O.jsx)(To.ChevronRight,{size:14,className:m("transition-transform duration-200",r&&"rotate-90")})]}),r&&(0,O.jsx)("div",{className:"space-y-0.5",children:e})]}),pn=({children:e,className:t})=>(0,O.jsx)("div",{className:m(t),children:e}),un=({label:e,href:t,active:o,icon:r,badge:n,className:s})=>(0,O.jsxs)(W,{href:t,className:m("group flex items-center gap-2.5 rounded-lg px-2.5 py-2 text-sm outline-none","transition-all duration-200 ease-in-out","focus-visible:ring-2 focus-visible:ring-primary-500/30",o?"bg-primary-500/10 text-primary-500 font-medium":"text-text-muted hover:bg-bg-surface hover:text-text-main hover:translate-x-1",s),children:[r&&(0,O.jsx)(r,{size:16,className:m(o?"text-primary-500":"text-text-muted group-hover:text-text-main")}),(0,O.jsx)("span",{className:"truncate",children:e}),n&&(0,O.jsx)(ln,{badge:n})]}),Ne={SidebarRoot:cn,SidebarGroup:mn,SidebarGroupItem:pn,SidebarLink:un}});var ot,ko,U,Lo,ie,Ht=N(()=>{"use strict";a();ot=D(require("react-aria-components"));I();ko=require("class-variance-authority"),U=require("react/jsx-runtime"),Lo=(0,ko.cva)("flex flex-row items-center justify-center w-auto font-semibold tracking-tight no-underline whitespace-nowrap select-none outline-none transition-all duration-200 cursor-pointer pressed:scale-[0.97] hover:-translate-y-px leading-none",{variants:{variant:{primary:"bg-primary-500 text-white shadow-md hover:brightness-110 hover:shadow-lg",secondary:"bg-bg-surface text-text-main border border-border-subtle hover:bg-bg-muted hover:border-border-strong",outline:"bg-transparent text-text-main border border-border-strong hover:bg-bg-surface hover:border-primary-500",ghost:"bg-transparent text-text-muted hover:bg-bg-surface hover:text-text-main",danger:"bg-[var(--color-danger-500)]/10 text-[var(--color-danger-500)] border border-[var(--color-danger-500)]/20 hover:bg-[var(--color-danger-500)]/15",success:"bg-[var(--color-success-500)]/10 text-[var(--color-success-500)] border border-[var(--color-success-500)]/20 hover:bg-[var(--color-success-500)]/15",warning:"bg-[var(--color-warning-500)]/10 text-[var(--color-warning-500)] border border-[var(--color-warning-500)]/20 hover:bg-[var(--color-warning-500)]/15",info:"bg-[var(--color-info-500)]/10 text-[var(--color-info-500)] border border-[var(--color-info-500)]/20 hover:bg-[var(--color-info-500)]/15",subtle:"bg-primary-500/10 text-primary-500 hover:bg-primary-500/20",link:"bg-transparent text-primary-500 !p-0 !min-h-0 hover:underline"},size:{sm:"min-h-8 px-3.5 text-[0.8125rem] gap-1.5",md:"min-h-10 px-5 text-[0.9375rem] gap-2",lg:"min-h-12 px-7 text-[1.05rem] gap-2.5"},rounded:{none:"rounded-none",sm:"rounded-sm",md:"rounded-md",lg:"rounded-lg",full:"rounded-full"},iconSize:{sm:"w-8 h-8 p-0",md:"w-10 h-10 p-0",lg:"w-12 h-12 p-0"},disabled:{true:"opacity-50 cursor-not-allowed pointer-events-none",false:null}},defaultVariants:{variant:"primary",size:"md",rounded:"md"}}),ie=({href:e,icon:t,iconPosition:o="left",isIconOnly:r,children:n,className:s,variant:i,size:l,rounded:c,iconSize:g,disabled:u,...p})=>{let f=r||!n&&!!t,C=f?(0,U.jsx)("span",{className:"inline-flex items-center justify-center [&>svg]:w-[1.2rem] [&>svg]:h-[1.2rem]",children:t}):(0,U.jsxs)(U.Fragment,{children:[t&&o==="left"&&(0,U.jsx)("span",{className:"inline-flex items-center shrink-0 [&>svg]:w-[1.1rem] [&>svg]:h-[1.1rem]",children:t}),(0,U.jsx)("span",{className:"flex items-center",children:n}),t&&o==="right"&&(0,U.jsx)("span",{className:"inline-flex items-center shrink-0 [&>svg]:w-[1.1rem] [&>svg]:h-[1.1rem]",children:t})]});return e?(0,U.jsx)(ot.Link,{href:e,className:m(Lo({variant:i,size:l,rounded:c,iconSize:f?g:void 0,disabled:u}),s),...p,children:C}):(0,U.jsx)(ot.Button,{className:m(Lo({variant:i,size:l,rounded:c,iconSize:f?g:void 0,disabled:u}),s),...p,children:C})}});var Io,So,Bo=N(()=>{"use strict";a();I();Io=require("react/jsx-runtime"),So=({children:e,className:t,vertical:o=!1})=>(0,Io.jsx)("div",{className:m("inline-flex",o?"flex-col":"flex-row",!o&&["[&>*:not(:first-child)]:-ml-px","[&>*:first-child]:rounded-r-none","[&>*:last-child]:rounded-l-none","[&>*:not(:first-child):not(:last-child)]:rounded-none",t?.includes("rounded-full")&&["[&>*:first-child]:rounded-l-full","[&>*:last-child]:rounded-r-full"],t?.includes("rounded-xl")&&["[&>*:first-child]:rounded-l-xl","[&>*:last-child]:rounded-r-xl"],t?.includes("rounded-lg")&&["[&>*:first-child]:rounded-l-lg","[&>*:last-child]:rounded-r-lg"]],o&&["[&>*:not(:first-child)]:-mt-px","[&>*:first-child]:rounded-b-none","[&>*:last-child]:rounded-t-none","[&>*:not(:first-child):not(:last-child)]:rounded-none",t?.includes("rounded-full")&&["[&>*:first-child]:rounded-t-full","[&>*:last-child]:rounded-b-full"]],t),children:e})});var we,Pe,$t,Wt=N(()=>{"use strict";"use client";a();we=D(require("react-aria-components"));I();Pe=require("react/jsx-runtime"),$t=({children:e,className:t,showArrow:o,...r})=>(0,Pe.jsxs)(we.Popover,{offset:8,...r,className:we.composeRenderProps(t,n=>m("z-50 overflow-auto rounded-xl border border-border-subtle bg-bg-surface/80 shadow-xl backdrop-blur-md outline-none transition-none",n)),children:[o&&(0,Pe.jsx)(we.OverlayArrow,{className:"group",children:(0,Pe.jsx)("svg",{viewBox:"0 0 12 12",className:"block h-3 w-3 fill-bg-surface/80 stroke-border-subtle group-placement-bottom:rotate-180 group-placement-left:-rotate-90 group-placement-right:rotate-90","aria-hidden":"true",children:(0,Pe.jsx)("path",{d:"M0 0 L6 6 L12 0"})})}),e]})});function De(e){let[t,o]=Gt.default.Children.toArray(e.children).slice(0,2);return(0,L.jsxs)(k.MenuTrigger,{...e,children:[t,(0,L.jsx)($t,{placement:e.placement,className:"min-w-35",children:o})]})}function dn(e){let[t,o]=Gt.default.Children.toArray(e.children).slice(0,2);return(0,L.jsxs)(k.SubmenuTrigger,{...e,children:[t,(0,L.jsx)($t,{offset:-4,crossOffset:-4,children:o})]})}function Ve(e){return(0,L.jsx)(k.Menu,{...e,className:k.composeRenderProps(e.className,t=>m("p-1.5 outline-none max-h-[inherit] overflow-auto max-w-75",t))})}function le(e){let t=e.textValue||(typeof e.children=="string"?e.children:void 0);return(0,L.jsx)(k.MenuItem,{...e,textValue:t,className:k.composeRenderProps(e.className,(o,{isFocused:r,isPressed:n,isDisabled:s})=>m("group relative flex flex-row items-center gap-2 px-2 py-1 rounded-lg outline-none cursor-default hover:cursor-pointer transition-none","text-text-main text-[12px]",{"bg-bg-surface-elevated text-primary-600 ring-1 ring-border-strong/5":r,"bg-bg-surface-elevanted":n,"opacity-40 grayscale pointer-events-none":s},o)),children:k.composeRenderProps(e.children,(o,{selectionMode:r,isSelected:n,hasSubmenu:s})=>(0,L.jsxs)(L.Fragment,{children:[r!=="none"&&(0,L.jsxs)("span",{className:"flex items-center size-4 shrink-0 justify-center",children:[n&&r==="multiple"&&(0,L.jsx)(Re.Check,{className:"size-3.5 stroke-[2.5px] text-primary-500 animate-in zoom-in-50 duration-200"}),n&&r==="single"&&(0,L.jsx)(Re.Dot,{className:"size-5 text-primary-500 animate-in zoom-in-50 duration-200"})]}),(0,L.jsx)("div",{className:"flex flex-row w-full transition-colors items-center gap-2 py-1 px-1",children:o}),s&&(0,L.jsx)(Re.ChevronRight,{className:"size-4 ml-auto text-text-muted group-focused:text-primary-500/70 transition-colors"})]}))})}function fn({title:e,...t}){return(0,L.jsxs)(k.MenuSection,{...t,className:m("flex flex-col gap-0.5",t.className),children:[e&&(0,L.jsx)(k.Header,{className:"px-3 py-2 text-[10px] font-bold uppercase tracking-[0.075em] text-text-muted/50 select-none",children:e}),(0,L.jsx)(k.Collection,{items:t.items,children:t.children})]})}function gn(e){return(0,L.jsx)(k.Separator,{...e,className:"mx-2 my-1.5 border-t border-border-subtle/50"})}var Re,Gt,k,L,Z,rt=N(()=>{"use strict";"use client";a();Re=require("lucide-react"),Gt=D(require("react")),k=D(require("react-aria-components"));Wt();I();L=require("react/jsx-runtime");Z={Root:Ve,Item:le,Trigger:De,SubTrigger:dn,Section:fn,Separator:gn}});var Ft,Ut,Ao=N(()=>{"use strict";a();Ft=D(require("react-aria-components"));I();Ut=require("react/jsx-runtime")});function E({className:e,variant:t="rect",...o}){return(0,Mo.jsx)("div",{className:m("animate-pulse bg-bg-muted",t==="circle"?"rounded-full":"rounded-md",e),...o})}var Mo,jt=N(()=>{"use strict";a();I();Mo=require("react/jsx-runtime")});var ye,Ye=N(()=>{"use strict";a();Qe();po();kt();Bt();At();Ot();Vt();xt();Ht();Bo();rt();Wt();Ao();ze();jt();ye=require("react-aria-components");I()});function Yo(e){let{currentLocale:t,currentVersion:o}=S(),[r,n]=(0,me.useState)(!1),[s,i]=(0,me.useState)(""),[l,c]=(0,me.useState)(null);(0,me.useEffect)(()=>{if(!r||l)return;let u=new Qo.Index({preset:"match",tokenize:"full",resolution:9,cache:!0});for(let p of _t.default)u.add(p.id,`${p.title} ${p.content}`);c(u)},[r,l]);let g=(0,me.useMemo)(()=>{if(!s)return e.filter(C=>{let v=!t||C.locale===t,b=!o||C.version===o;return v&&b}).slice(0,10).map(C=>({id:C.path,title:C.title,path:C.path,bio:C.description||"",groupTitle:C.groupTitle}));if(!l)return[];let u=l.search(s,{limit:20,suggest:!0}),p=[],f=new Set;for(let C of u){let v=_t.default.find(A=>A.id===C);if(!v)continue;let b=!t||v.locale===t,h=!o||v.version===o;!b||!h||f.has(v.url)||(f.add(v.url),p.push({id:v.url,title:v.title,path:v.url,bio:v.display,groupTitle:v.display.split(" > ")[0],isHeading:v.url.includes("#")}))}return p.slice(0,10)},[s,l,t,o,e]);return{isOpen:r,setIsOpen:n,query:s,setQuery:i,list:g,input:{value:s,onChange:u=>i(u.target.value)}}}var me,Qo,_t,Zo=N(()=>{"use strict";a();me=require("react"),Qo=require("flexsearch");K();_t=D(require("virtual:boltdocs-search"))});var tr={};Xt(tr,{SearchDialog:()=>Kt});function Kt({routes:e}){let{isOpen:t,setIsOpen:o,query:r,setQuery:n,list:s}=Yo(e),i=(0,er.useNavigate)();(0,pt.useEffect)(()=>{let c=g=>{(/Mac/.test(navigator.userAgent)?g.metaKey:g.ctrlKey)&&(g.key==="k"||g.key==="j")&&(g.preventDefault(),o(f=>!f))};return window.addEventListener("keydown",c),()=>window.removeEventListener("keydown",c)},[o]);let l=(0,pt.useCallback)(c=>{let g=String(c);if(o(!1),g.includes("#")){let[u,p]=g.split("#");i(u),setTimeout(()=>{let f=document.getElementById(p);f&&f.scrollIntoView({behavior:"smooth"})},100)}else i(g)},[i,o]);return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(V.SearchTrigger,{onPress:()=>o(!0)}),(0,H.jsx)(yt,{isOpen:t,onOpenChange:o,children:(0,H.jsxs)(Ct,{onSelectionChange:l,children:[(0,H.jsx)(Nt,{value:r,onChange:c=>n(c.target.value)}),(0,H.jsx)(Pt,{items:s,children:c=>(0,H.jsxs)(wt,{onPress:()=>l(c.id),textValue:c.title,children:[(0,H.jsx)(Rt,{isHeading:c.isHeading}),(0,H.jsxs)("div",{className:"flex flex-col justify-center gap-0.5",children:[(0,H.jsx)(Tt,{children:c.title}),(0,H.jsx)(Lt,{children:c.bio})]})]},c.id)})]})})]})}var pt,er,H,qt=N(()=>{"use strict";a();pt=require("react");Zo();kt();Qe();er=require("react-router-dom"),H=require("react/jsx-runtime")});var Sn={};Xt(Sn,{Breadcrumbs:()=>so,CopyMarkdown:()=>Eo,ErrorBoundary:()=>nt,GithubStars:()=>st,Head:()=>$o,Loading:()=>Wo,Navbar:()=>rr,NotFound:()=>ar,OnThisPage:()=>lr,PageNav:()=>pr,PoweredBy:()=>dt,SearchDialog:()=>Kt,Sidebar:()=>hr,Tabs:()=>mt,ThemeToggle:()=>ct});module.exports=Pr(Sn);a();a();a();K();function Zt(){let{currentRoute:e}=S(),t=[];return e&&(e.groupTitle&&t.push({label:e.groupTitle}),t.push({label:e.title,href:e.path})),{crumbs:t,activeRoute:e}}var ao=require("lucide-react");xt();I();xe();var Y=require("react/jsx-runtime");function so(){let{crumbs:e,activeRoute:t}=Zt(),r=_().theme||{};return e.length===0||!r?.breadcrumbs?null:(0,Y.jsxs)(ro,{children:[(0,Y.jsx)(gt,{children:(0,Y.jsx)(ht,{href:"/",children:(0,Y.jsx)(ao.Home,{size:14})})}),e.map((n,s)=>(0,Y.jsxs)(gt,{children:[(0,Y.jsx)(no,{}),(0,Y.jsx)(ht,{href:n.href,className:m({"font-medium text-text-main":n.href===t?.path}),children:n.label})]},`crumb-${n.href}-${n.label}-${s}`))]})}a();var Oo=require("react"),ee=require("lucide-react");Ye();var B=require("react/jsx-runtime"),hn=e=>{let[t,o]=(0,Oo.useState)(!1);return{copied:t,handleCopy:()=>{navigator.clipboard.writeText(e),o(!0),setTimeout(()=>o(!1),2e3)},handleOpenRaw:()=>{let s=new Blob([e],{type:"text/plain;charset=utf-8"}),i=URL.createObjectURL(s);window.open(i,"_blank")}}};function Eo({content:e,mdxRaw:t,config:o}){let r=t||e||"",{copied:n,handleCopy:s,handleOpenRaw:i}=hn(r),l=o!==!1,c=typeof o=="object"&&o.text||"Copy Markdown";return!l||!r?null:(0,B.jsx)("div",{className:"relative inline-flex z-100 flex-shrink-0 w-max translate-y-0 active:translate-y-px transition-transform duration-200",children:(0,B.jsxs)(So,{className:"rounded-xl border border-border-subtle bg-bg-surface/40 backdrop-blur-md transition-all duration-300 hover:border-primary-500/50 hover:shadow-lg hover:shadow-primary-500/5 group overflow-hidden",children:[(0,B.jsx)(ie,{variant:"ghost",onPress:s,icon:n?(0,B.jsx)(ee.Check,{size:16}):(0,B.jsx)(ee.Copy,{size:16}),iconPosition:"left",className:m("px-5 py-2 bg-transparent text-[0.8125rem] font-semibold h-9 border-none shrink-0","text-text-main transition-all duration-300 hover:bg-primary-500/5",n&&"text-emerald-500 hover:bg-emerald-500/5"),children:n?"Copied!":c}),(0,B.jsxs)(De,{placement:"bottom end",children:[(0,B.jsx)(ie,{variant:"ghost",isIconOnly:!0,icon:(0,B.jsx)(ee.ChevronDown,{size:14}),className:m("px-3.5 h-9 border-l border-border-subtle/50 text-text-muted rounded-none bg-transparent shrink-0","transition-all duration-300 hover:bg-primary-500/5 hover:text-primary-500")}),(0,B.jsxs)(Ve,{className:"w-52",children:[(0,B.jsxs)(le,{onAction:s,children:[(0,B.jsx)(ee.Copy,{size:16,className:"size-4 mt-0.5 text-text-muted group-hover:text-primary-500"}),(0,B.jsx)("span",{className:"font-medium text-[0.8125rem]",children:"Copy Markdown"})]}),(0,B.jsxs)(le,{onAction:i,children:[(0,B.jsx)(ee.ExternalLink,{size:16,className:"size-4 mt-0.5 text-text-muted group-hover:text-primary-500"}),(0,B.jsx)("span",{className:"font-medium text-[0.8125rem]",children:"View as Markdown"})]})]})]})]})})}a();var zo=require("react");Ye();var Te=require("react/jsx-runtime"),nt=class extends zo.Component{state={hasError:!1};static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,o){console.error("Uncaught error in Boltdocs Layout:",t,o)}render(){return this.state.hasError?this.props.fallback||(0,Te.jsxs)("div",{className:"flex flex-col items-center justify-center min-h-[40vh] text-center gap-4 px-4",children:[(0,Te.jsx)("div",{className:"text-lg font-bold text-red-400",children:"Something went wrong"}),(0,Te.jsx)("p",{className:"text-sm text-text-muted max-w-md",children:this.state.error?.message||"An unexpected error occurred while rendering this page."}),(0,Te.jsx)(ie,{className:"rounded-lg border border-border-subtle bg-bg-surface px-5 py-2 text-sm font-medium text-text-main transition-colors hover:bg-bg-muted cursor-pointer",onPress:()=>this.setState({hasError:!1}),children:"Try again"})]}):this.props.children}};a();var at=require("react");a();var xn="https://api.github.com";async function Do(e,t,o=xn){let r=new Headers;t&&r.append("authorization",t);let s=await(await fetch(`${o}/repos/${e}`,{headers:r})).json();return s.stargazers_count!==void 0?vn(s.stargazers_count):"0"}var vn=e=>Intl.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(e);vt();var He=require("react/jsx-runtime");function st({repo:e}){let[t,o]=(0,at.useState)(null);return(0,at.useEffect)(()=>{e&&Do(e).then(r=>o(r)).catch(()=>o("0"))},[e]),(0,He.jsxs)("a",{href:`https://github.com/${e}`,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 rounded-md border border-border-subtle bg-bg-surface px-2.5 py-1.5 text-xs font-medium text-text-muted transition-all hover:bg-bg-main hover:border-border-strong hover:text-text-main",children:[(0,He.jsx)(Xe,{className:"h-4 w-4"}),t&&(0,He.jsx)("span",{className:"tabular-nums",children:t})]})}a();var Vo=require("react"),Ho=require("react-router-dom");function $o({siteTitle:e,siteDescription:t,routes:o}){let r=(0,Ho.useLocation)();return(0,Vo.useEffect)(()=>{let n=o.find(g=>g.path===r.pathname),s=n?.title,i=n?.description||t||"";document.title=s?`${s} | ${e}`:e;let l=document.querySelector('meta[name="description"]');l||(l=document.createElement("meta"),l.name="description",document.head.appendChild(l)),l.content=i,fe("property","og:title",document.title),fe("property","og:description",i),fe("property","og:type","article"),fe("property","og:url",window.location.href),fe("name","twitter:card","summary"),fe("name","twitter:title",document.title),fe("name","twitter:description",i);let c=document.querySelector('link[rel="canonical"]');c||(c=document.createElement("link"),c.rel="canonical",document.head.appendChild(c)),c.href=window.location.origin+r.pathname},[r.pathname,e,t,o]),null}function fe(e,t,o){let r=document.querySelector(`meta[${e}="${t}"]`);r||(r=document.createElement("meta"),r.setAttribute(e,t),document.head.appendChild(r)),r.content=o}a();I();jt();var w=require("react/jsx-runtime");function Wo(){return(0,w.jsx)("div",{className:m("w-full h-full relative overflow-y-auto transition-opacity duration-300 animate-fade-in"),children:(0,w.jsxs)("div",{className:"mx-auto max-w-(--spacing-content-max) px-4 py-8 space-y-10",children:[(0,w.jsxs)("div",{className:"flex gap-2",children:[(0,w.jsx)(E,{className:"h-3 w-16"}),(0,w.jsx)(E,{className:"h-3 w-24"})]}),(0,w.jsx)(E,{className:"h-10 w-[60%] sm:h-12"}),(0,w.jsxs)("div",{className:"space-y-3",children:[(0,w.jsx)(E,{className:"h-4 w-full"}),(0,w.jsx)(E,{className:"h-4 w-[95%]"}),(0,w.jsx)(E,{className:"h-4 w-[40%]"})]}),(0,w.jsxs)("div",{className:"space-y-6 pt-4",children:[(0,w.jsx)(E,{className:"h-7 w-32"}),(0,w.jsxs)("div",{className:"space-y-3",children:[(0,w.jsx)(E,{className:"h-4 w-full"}),(0,w.jsx)(E,{className:"h-4 w-[98%]"}),(0,w.jsx)(E,{className:"h-4 w-[92%]"}),(0,w.jsx)(E,{className:"h-4 w-[60%]"})]})]}),(0,w.jsx)(E,{className:"h-32 w-full rounded-lg bg-bg-muted/50"}),(0,w.jsxs)("div",{className:"space-y-6 pt-4",children:[(0,w.jsx)(E,{className:"h-7 w-48"}),(0,w.jsxs)("div",{className:"space-y-3",children:[(0,w.jsx)(E,{className:"h-4 w-full"}),(0,w.jsx)(E,{className:"h-4 w-[85%]"})]})]})]})})}a();var ut=require("react");a();var Go=require("react-router-dom");xe();a();var Le=require("react"),yn=require("react/jsx-runtime"),bn=(0,Le.createContext)(void 0);function it(){let e=(0,Le.use)(bn);if(e===void 0)throw new Error("useTheme must be used within a ThemeProvider");return e}a();function $e(e,t){return e?typeof e=="string"?e:t&&e[t]?e[t]:Object.values(e)[0]||"":""}K();function Fo(){let e=_(),{theme:t}=it(),o=(0,Go.useLocation)(),{currentLocale:r}=S(),n=e.theme||{},s=$e(n.title,r)||"Boltdocs",i=n.navbar||[],l=n.socialLinks||[],c=n.githubRepo,g=i.map(v=>{let b=v.href||v.to||v.link||"",h=A=>{let pe=o.pathname;if(pe===A)return!0;if(!A||A==="/")return pe==="/";let he=Ge=>{let G=Ge.split("/").filter(Boolean),ue=0;return e.i18n?.locales&&G[ue]&&e.i18n.locales[G[ue]]&&ue++,e.versions?.versions&&G[ue]&&e.versions.versions.some(xr=>xr.path===G[ue])&&ue++,G.slice(ue)},Be=he(A),Ae=he(pe);return Be.length===0?Ae.length===0:Ae.length<Be.length?!1:Be.every((Ge,G)=>Ae[G]===Ge)};return{label:$e(v.label||v.text,r),href:b,active:h(b),to:b.startsWith("http")||b.startsWith("//")?"external":void 0}}),u=n.logo,p=u?typeof u=="string"?u:t==="dark"?u.dark:u.light:null,f={alt:(u&&typeof u=="object"?u.alt:void 0)||s,width:u&&typeof u=="object"?u.width:void 0,height:u&&typeof u=="object"?u.height:void 0},C=c?`https://github.com/${c}`:null;return{links:g,title:s,logo:p,logoProps:f,github:C,social:l,config:e,theme:t}}a();var Uo=require("react-router-dom");a();function ce(e,t,o){let r=e;return t&&(r===t||r.startsWith(t+"/"))&&(r=r===t?"index.md":r.slice(t.length+1)),o&&(r===o||r.startsWith(o+"/"))&&(r=r===o?"index.md":r.slice(o.length+1)),r}K();Ke();function jo(){let e=(0,Uo.useNavigate)(),t=S(),{allRoutes:o,currentRoute:r,currentVersion:n,currentLocale:s,config:i}=t,l=i.versions,c=re(p=>p.setVersion),g=p=>{if(!l||p===n)return;c(p);let f=`/docs/${p}`;if(r){let C=ce(r.filePath,r.version,r.locale),v=o.find(b=>ce(b.filePath,b.version,b.locale)===C&&(b.version||l.defaultVersion)===p&&(s?b.locale===s:!b.locale));if(v)f=v.path;else{let b=o.find(h=>ce(h.filePath,h.version,h.locale)==="index.md"&&(h.version||l.defaultVersion)===p&&(s?h.locale===s:!h.locale));f=b?b.path:`/docs/${p}${s?`/${s}`:""}`}}e(f)},u=t.availableVersions.map(p=>({...p,label:p.label,value:p.key}));return{currentVersion:n,currentVersionLabel:t.currentVersionLabel,availableVersions:u,handleVersionChange:g}}a();var _o=require("react-router-dom");K();Ke();function Ko(){let e=(0,_o.useNavigate)(),t=S(),{allRoutes:o,currentRoute:r,currentLocale:n,config:s}=t,i=s.i18n,l=re(f=>f.setLocale),c=f=>{if(!i||f===n)return;l(f);let C="/";if(r){let v=ce(r.filePath,r.version,r.locale),b=o.find(h=>ce(h.filePath,h.version,h.locale)===v&&(h.locale||i.defaultLocale)===f&&h.version===r.version);if(b)C=b.path;else{let h=o.find(A=>ce(A.filePath,A.version,A.locale)==="index.md"&&(A.locale||i.defaultLocale)===f&&A.version===r.version);C=h?h.path:f===i.defaultLocale?r.version?`/${r.version}`:"/":r.version?`/${r.version}/${f}`:`/${f}`}}else{let v=o.find(b=>(b.filePath==="index.mdx"||b.filePath==="index.md")&&(b.locale||i.defaultLocale)===f&&!b.version);v?C=v.path:C=f===i.defaultLocale?"/":`/${f}`}e(C)},u=s.i18n?.localeConfigs?.[n]?.label||s.i18n?.locales[n]||n,p=s.i18n?Object.entries(s.i18n.locales).map(([f,C])=>{let v=s.i18n?.localeConfigs?.[f];return{key:f,label:v?.label||C,value:f,isCurrent:f===n}}):[];return{currentLocale:n,currentLocaleLabel:u,availableLocales:p,handleLocaleChange:c}}K();Qe();a();var lt=require("react"),te=require("lucide-react");var qo=require("react-aria-components");rt();var z=require("react/jsx-runtime");function ct(){let{theme:e,setTheme:t}=it(),[o,r]=(0,lt.useState)(!1);return(0,lt.useEffect)(()=>{r(!0)},[]),o?(0,z.jsxs)(De,{placement:"bottom right",children:[(0,z.jsx)(qo.Button,{className:"flex h-9 w-9 items-center justify-center rounded-md text-text-muted transition-colors hover:bg-bg-surface hover:text-text-main outline-none focus-visible:ring-2 focus-visible:ring-primary-500","aria-label":"Selection theme",children:(0,z.jsx)(e==="system"?te.Monitor:e==="dark"?te.Moon:te.Sun,{size:20,className:"animate-in fade-in zoom-in duration-300"})}),(0,z.jsxs)(Ve,{selectionMode:"single",selectedKeys:[e],onSelectionChange:s=>{let i=Array.from(s)[0];t(i)},children:[(0,z.jsxs)(le,{id:"light",children:[(0,z.jsx)(te.Sun,{size:16}),(0,z.jsx)("span",{children:"Light"})]}),(0,z.jsxs)(le,{id:"dark",children:[(0,z.jsx)(te.Moon,{size:16}),(0,z.jsx)("span",{children:"Dark"})]}),(0,z.jsxs)(le,{id:"system",children:[(0,z.jsx)(te.Monitor,{size:16}),(0,z.jsx)("span",{children:"System"})]})]})]}):(0,z.jsx)("div",{className:"h-9 w-9"})}a();a();var Xo=require("react-router-dom"),ke=require("react");function Jo(e=[],t=[]){let o=(0,Xo.useLocation)(),r=(0,ke.useRef)([]),[n,s]=(0,ke.useState)({opacity:0,transform:"translateX(0) scaleX(0)",width:0}),l=t.find(u=>u.path===o.pathname)?.tab?.toLowerCase(),c=e.findIndex(u=>u.id.toLowerCase()===l),g=c===-1?0:c;return(0,ke.useEffect)(()=>{let u=r.current[g];u&&s({opacity:1,width:u.offsetWidth,transform:`translateX(${u.offsetLeft}px)`})},[g,e.length,o.pathname]),{tabs:e,activeIndex:g,indicatorStyle:n,tabRefs:r,activeTabId:l}}Ot();ze();var Cn=D(require("lucide-react"));K();var X=require("react/jsx-runtime");function mt({tabs:e,routes:t}){let{currentLocale:o}=S(),{indicatorStyle:r,tabRefs:n,activeIndex:s}=Jo(e,t),i=l=>{if(!l)return null;if(l.trim().startsWith("<svg"))return(0,X.jsx)("span",{className:"h-4 w-4",dangerouslySetInnerHTML:{__html:l}});let c=Cn[l];return c?(0,X.jsx)(c,{size:16}):(0,X.jsx)("img",{src:l,alt:"",className:"h-4 w-4 object-contain"})};return(0,X.jsx)("div",{className:"mx-auto max-w-(--breakpoint-3xl) px-4 md:px-6",children:(0,X.jsxs)(Mt.TabsList,{className:"border-none py-0",children:[e.map((l,c)=>{let g=c===s,u=t.find(f=>f.tab&&f.tab.toLowerCase()===l.id.toLowerCase()),p=u?u.path:"#";return(0,X.jsxs)(W,{href:p,ref:f=>{n.current[c]=f},className:`relative flex items-center gap-2 px-4 py-3 text-sm font-medium transition-colors outline-none ${g?"text-primary-500":"text-text-muted hover:text-text-main"}`,children:[i(l.icon),(0,X.jsx)("span",{children:$e(l.text,o)})]},l.id)}),(0,X.jsx)(Mt.TabsIndicator,{style:r})]})})}var or=require("react-router-dom");rt();Ht();var We=require("lucide-react");Et();var x=require("react/jsx-runtime"),Nn=(0,ut.lazy)(()=>Promise.resolve().then(()=>(qt(),tr)).then(e=>({default:e.SearchDialog})));function rr(){let{links:e,title:t,logo:o,logoProps:r,github:n,social:s,config:i}=Fo(),{routes:l,allRoutes:c,currentVersion:g,currentLocale:u}=S(),{pathname:p}=(0,or.useLocation)(),f=i.theme||{},C=p.startsWith("/docs"),v=f?.tabs&&f.tabs.length>0;return(0,x.jsxs)(V.NavbarRoot,{className:v?"border-b-0":"",children:[(0,x.jsxs)(V.Content,{children:[(0,x.jsxs)(V.NavbarLeft,{children:[o&&(0,x.jsx)(V.NavbarLogo,{src:o,alt:r?.alt||t,width:r?.width??24,height:r?.height??24}),(0,x.jsx)(V.Title,{children:t}),i.versions&&g&&(0,x.jsx)(wn,{})]}),(0,x.jsx)(V.NavbarCenter,{children:(0,x.jsx)(ut.Suspense,{fallback:(0,x.jsx)("div",{className:"h-9 w-32 animate-pulse rounded-md bg-bg-surface"}),children:(0,x.jsx)(Nn,{routes:l||[]})})}),(0,x.jsxs)(V.NavbarRight,{children:[(0,x.jsx)(V.Links,{children:e.map(b=>(0,x.jsx)(x.Fragment,{children:(0,x.jsx)(Pn,{link:b},b.href)}))}),i.i18n&&u&&(0,x.jsx)(Rn,{}),(0,x.jsx)(V.Split,{}),(0,x.jsx)(ct,{}),n&&(0,x.jsx)(st,{repo:f?.githubRepo??""}),s.length>0&&(0,x.jsx)(V.Split,{}),(0,x.jsx)("div",{className:"flex items-center gap-1",children:s.map(({icon:b,link:h})=>(0,x.jsx)(V.Socials,{icon:b,link:h,className:"p-1.5"},h))})]})]}),C&&v&&f?.tabs&&(0,x.jsx)("div",{className:"w-full border-b border-border-subtle bg-bg-main",children:(0,x.jsx)(mt,{tabs:f.tabs,routes:c||l||[]})})]})}function Pn({link:e}){let t=Ee(e.href||"");return(0,x.jsx)(V.Link,{...e,href:t})}function wn(){let{currentVersionLabel:e,availableVersions:t,handleVersionChange:o}=jo();return t.length===0?null:(0,x.jsxs)(Z.Trigger,{children:[(0,x.jsx)(ie,{variant:"outline",size:"sm",rounded:"lg",iconPosition:"right",icon:(0,x.jsx)(We.ChevronDown,{className:"w-3.5 h-3.5 text-text-muted/60"}),className:"h-8 border-border-subtle/60 bg-bg-surface/30 backdrop-blur-sm transition-all duration-200 hover:border-primary-500/50 hover:bg-primary-500/5",children:(0,x.jsx)("span",{className:"font-semibold text-[0.8125rem]",children:e})}),(0,x.jsx)(Z.Root,{children:(0,x.jsx)(Z.Section,{items:t,children:r=>(0,x.jsx)(Z.Item,{onPress:()=>o(r.value),children:r.label},`${r.value??""}`)})})]})}function Rn(){let{currentLocale:e,availableLocales:t,handleLocaleChange:o}=Ko();return t.length===0?null:(0,x.jsxs)(Z.Trigger,{children:[(0,x.jsx)(ie,{variant:"outline",size:"sm",rounded:"lg",iconPosition:"right",icon:(0,x.jsx)(We.ChevronDown,{className:"w-3.5 h-3.5 text-text-muted/60"}),className:"h-8 border-border-subtle/60 bg-bg-surface/30 backdrop-blur-sm transition-all duration-200 hover:border-primary-500/50 hover:bg-primary-500/5 px-2.5",children:(0,x.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,x.jsx)(We.Languages,{className:"w-3.5 h-3.5 text-primary-500"}),(0,x.jsx)("span",{className:"font-bold text-[0.75rem] tracking-wider uppercase opacity-90",children:e||"en"})]})}),(0,x.jsx)(Z.Root,{children:(0,x.jsx)(Z.Section,{items:t,children:r=>(0,x.jsx)(Z.Item,{onPress:()=>o(r.value),children:(0,x.jsxs)("div",{className:"flex items-center justify-between w-full gap-4",children:[(0,x.jsx)("span",{children:r.label}),(0,x.jsx)("span",{className:"text-[10px] font-bold opacity-40 uppercase tracking-tighter",children:r.value})]})},`${r.value??""}`)})})]})}a();var nr=require("lucide-react");ze();var oe=require("react/jsx-runtime");function ar(){return(0,oe.jsx)("div",{className:"flex items-center justify-center min-h-[60vh] text-center",children:(0,oe.jsxs)("div",{className:"space-y-4",children:[(0,oe.jsx)("span",{className:"text-8xl font-black tracking-tighter text-primary-500/20",children:"404"}),(0,oe.jsx)("h1",{className:"text-2xl font-bold text-text-main",children:"Page Not Found"}),(0,oe.jsx)("p",{className:"text-sm text-text-muted max-w-sm mx-auto",children:"The page you're looking for doesn't exist or has been moved."}),(0,oe.jsxs)(W,{href:"/",className:"inline-flex items-center gap-2 rounded-lg bg-primary-500 px-5 py-2.5 text-sm font-semibold text-white outline-none transition-all hover:brightness-110 hover:shadow-lg focus-visible:ring-2 focus-visible:ring-primary-500/30",children:[(0,oe.jsx)(nr.ArrowLeft,{size:16})," Go to Home"]})]})})}a();Bt();var j=D(require("react"));a();var sr=require("react");function ir(e=[]){let[t,o]=(0,sr.useState)(null);return{headings:e,activeId:t,setActiveId:o}}var Se=require("lucide-react"),T=require("react/jsx-runtime");function lr({headings:e=[],editLink:t,communityHelp:o,filePath:r}){let{headings:n}=ir(e),s=j.default.useMemo(()=>n.map(i=>({title:i.text,url:`#${i.id}`,depth:i.level})),[n]);return n.length===0?null:(0,T.jsx)(yo,{toc:s,children:(0,T.jsx)(Tn,{headings:n,editLink:t,communityHelp:o,filePath:r})})}function Tn({headings:e,editLink:t,communityHelp:o,filePath:r}){let n=vo(),[s,i]=(0,j.useState)({opacity:0}),l=(0,j.useRef)(null),c=(0,j.useRef)(null);(0,j.useEffect)(()=>{if(!n||!l.current)return;let u=l.current.querySelector(`a[href="#${n}"]`);u&&i({transform:`translateY(${u.offsetTop}px)`,height:`${u.offsetHeight}px`,opacity:1})},[n]);let g=(0,j.useCallback)((u,p)=>{u.preventDefault();let f=document.getElementById(p);f&&(f.scrollIntoView({behavior:"smooth"}),window.history.pushState(null,"",`#${p}`))},[]);return(0,T.jsxs)(de.OnThisPageRoot,{children:[(0,T.jsxs)(de.OnThisPageHeader,{className:"flex flex-row gap-x-2",children:[(0,T.jsx)(Se.TextAlignStart,{size:16}),"On this page"]}),(0,T.jsx)(bo,{containerRef:c,children:(0,T.jsxs)(de.OnThisPageContent,{className:"max-h-[450px] boltdocs-otp-scroll-area",ref:c,children:[(0,T.jsx)(de.OnThisPageIndicator,{style:s}),(0,T.jsx)("ul",{className:"relative space-y-2 border-l border-border-subtle",ref:l,children:e.map(u=>(0,T.jsx)(de.OnThisPageItem,{level:u.level,children:(0,T.jsx)(de.OnThisPageLink,{href:`#${u.id}`,active:n===u.id,onClick:p=>g(p,u.id),className:"pl-4",children:u.text})},u.id))})]})}),(t||o)&&(0,T.jsxs)("div",{className:"mt-8 pt-8 border-t border-border-subtle space-y-4",children:[(0,T.jsx)("p",{className:"text-xs font-bold uppercase tracking-wider text-text-main",children:"Need help?"}),(0,T.jsxs)("ul",{className:"space-y-3",children:[t&&r&&(0,T.jsx)("li",{children:(0,T.jsxs)("a",{href:t.replace(":path",r),target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 text-sm text-text-muted hover:text-text-main transition-colors",children:[(0,T.jsx)(Se.Pencil,{size:16}),"Edit this page"]})}),o&&(0,T.jsx)("li",{children:(0,T.jsxs)("a",{href:o,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 text-sm text-text-muted hover:text-text-main transition-colors",children:[(0,T.jsx)(Se.CircleHelp,{size:16}),"Community help"]})})]})]})]})}a();a();var cr=require("react-router-dom");K();function mr(){let{routes:e,currentRoute:t}=S(),o=(0,cr.useLocation)();if(!t)return{prevPage:null,nextPage:null,currentRoute:null};let r=t.tab?.toLowerCase(),n=r?e.filter(c=>c.tab?.toLowerCase()===r):e.filter(c=>!c.tab),s=n.findIndex(c=>c.path===o.pathname),i=s>0?n[s-1]:null,l=s!==-1&&s<n.length-1?n[s+1]:null;return{prevPage:i,nextPage:l,currentRoute:t}}At();var J=require("react/jsx-runtime");function pr(){let{prevPage:e,nextPage:t}=mr();return!e&&!t?null:(0,J.jsxs)(se.PageNavRoot,{className:"animate-in fade-in slide-in-from-bottom-4 duration-700",children:[e?(0,J.jsxs)(se.PageNavLink,{to:e.path,direction:"prev",children:[(0,J.jsx)(se.PageNavLink.Title,{children:"Previous"}),(0,J.jsx)(se.PageNavLink.Description,{children:e.title})]}):(0,J.jsx)("div",{}),t&&(0,J.jsxs)(se.PageNavLink,{to:t.path,direction:"next",children:[(0,J.jsx)(se.PageNavLink.Title,{children:"Next"}),(0,J.jsx)(se.PageNavLink.Description,{children:t.title})]})]})}a();var ur=require("lucide-react"),ge=require("react/jsx-runtime");function dt(){return(0,ge.jsx)("div",{className:"flex items-center justify-center mt-10 mb-4 px-4 w-full",children:(0,ge.jsxs)("a",{href:"https://github.com/jesusalcaladev/boltdocs",target:"_blank",rel:"noopener noreferrer",className:"group relative flex items-center gap-2 px-4 py-2 rounded-full border border-border-subtle bg-bg-surface/50 backdrop-blur-md transition-all duration-300 hover:border-primary-500/50 hover:bg-bg-surface hover:shadow-xl hover:shadow-primary-500/5 select-none",children:[(0,ge.jsx)(ur.Zap,{className:"w-3.5 h-3.5 text-text-muted group-hover:text-primary-500 transition-colors duration-300",fill:"currentColor"}),(0,ge.jsxs)("span",{className:"text-[11px] font-medium text-text-muted group-hover:text-text-main transition-colors duration-300 tracking-wide",children:["Powered by"," ",(0,ge.jsx)("strong",{className:"font-bold text-text-main/80 group-hover:text-text-main",children:"Boltdocs"})]})]})})}qt();a();var Ie=require("react");a();var dr=require("react-router-dom");xe();function fr(e){let t=_(),o=(0,dr.useLocation)(),r=p=>p.endsWith("/")&&p.length>1?p.slice(0,-1):p,n=r(o.pathname),s=e.find(p=>r(p.path)===n),i=s?.tab?.toLowerCase(),l=i?e.filter(p=>!p.tab||p.tab.toLowerCase()===i):e,c=[],g=new Map;for(let p of l)p.group?(g.has(p.group)||g.set(p.group,{slug:p.group,title:p.groupTitle||p.group,routes:[],icon:p.groupIcon}),g.get(p.group).routes.push(p)):c.push(p);return{groups:Array.from(g.values()),ungrouped:c,activeRoute:s,activePath:n,config:t}}Vt();var Ln=D(require("lucide-react")),Q=require("react/jsx-runtime");function gr(e){return e&&Ln[e]||void 0}function kn({group:e,activePath:t,getIcon:o}){let r=(0,Ie.useMemo)(()=>e.routes.some(i=>i.path===t),[e.routes,t]),[n,s]=(0,Ie.useState)(!0);return(0,Ie.useEffect)(()=>{r&&s(!0)},[r]),(0,Q.jsx)(Ne.SidebarGroup,{title:e.title,isOpen:n,onToggle:()=>s(!n),children:e.routes.map(i=>{let l=t===(i.path.endsWith("/")?i.path.slice(0,-1):i.path);return(0,Q.jsx)(Ne.SidebarLink,{label:i.title,href:i.path,active:l,icon:o(i.icon),badge:i.badge},i.path)})})}function hr({routes:e,config:t}){let{groups:o,ungrouped:r,activePath:n}=fr(e),s=t.theme||{};return(0,Q.jsxs)(Ne.SidebarRoot,{children:[r.length>0&&(0,Q.jsx)(Ne.SidebarGroup,{className:"mb-6",children:r.map(i=>{let l=n===(i.path.endsWith("/")?i.path.slice(0,-1):i.path);return(0,Q.jsx)(Ne.SidebarLink,{label:i.title,href:i.path,active:l,icon:gr(i.icon),badge:i.badge},i.path)})}),o.map(i=>(0,Q.jsx)(kn,{group:i,activePath:n,getIcon:gr},i.slug)),s?.poweredBy&&(0,Q.jsx)("div",{className:"mt-auto pt-8",children:(0,Q.jsx)(dt,{})})]})}
|
package/dist/base-ui/index.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as
|
|
1
|
+
import{a as o,b as e,c as p,d as t,e as m,f,g as x,h as d,i as n,j as g,k as y,l as b,m as i}from"../chunk-PPVDMDEL.mjs";import"../chunk-HRZDSFR5.mjs";import{a as r}from"../chunk-64AJ5QLT.mjs";import"../chunk-JD3RSDE4.mjs";import{a}from"../chunk-UBE4CKOA.mjs";import"../chunk-2Z5T6EAU.mjs";import"../chunk-WWJ7WKDI.mjs";import"../chunk-NBCYHLAA.mjs";import"../chunk-JZXLCA2E.mjs";export{y as Breadcrumbs,r as CopyMarkdown,i as ErrorBoundary,t as GithubStars,g as Head,e as Loading,f as Navbar,o as NotFound,n as OnThisPage,b as PageNav,x as PoweredBy,a as SearchDialog,d as Sidebar,m as Tabs,p as ThemeToggle};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{r as a,s as b,t as c,u as d,v as e}from"./chunk-Y4RRHPXC.mjs";e();export{c as AssetCache,a as FileCache,b as TransformCache,d as flushCache};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as ge}from"./chunk-64AJ5QLT.mjs";import{b as me}from"./chunk-JD3RSDE4.mjs";import{b as fe}from"./chunk-T3W44KWY.mjs";import{a,b as pe,d as ue,e as be,g as xe,h as j,i as q,j as X,k as G,l as K,m as E,n as S,o as V,p as M,q as Y}from"./chunk-WWJ7WKDI.mjs";import{b as _}from"./chunk-NBCYHLAA.mjs";import{a as it}from"./chunk-JZXLCA2E.mjs";var vr={};it(vr,{Admonition:()=>P,Badge:()=>Ie,Button:()=>ye,Card:()=>Me,Cards:()=>Ve,Caution:()=>_e,CodeBlock:()=>B,ComponentPreview:()=>nt,ComponentProps:()=>tt,CopyMarkdown:()=>ge,Danger:()=>He,Field:()=>Ze,FileTree:()=>Xe,Image:()=>et,Important:()=>$e,InfoBox:()=>We,Link:()=>Qe,List:()=>je,Note:()=>De,Tab:()=>ke,Table:()=>Ye,Tabs:()=>Te,Tip:()=>Oe,Video:()=>Ae,Warning:()=>Fe});import{jsx as lt}from"react/jsx-runtime";var ye=({className:e,variant:t,size:r,rounded:o,iconSize:n,disabled:s,...i})=>lt(be,{className:a("group",ue({variant:t,size:r,rounded:o,iconSize:n,disabled:s,className:e})),...i});import*as U from"react-aria-components";import{Copy as pt,Check as mt,File as ut}from"lucide-react";var he=async e=>{try{return await navigator.clipboard.writeText(e),!0}catch{let t=document.createElement("textarea");return t.value=e,t.style.position="fixed",t.style.opacity="0",document.body.appendChild(t),t.select(),document.execCommand("copy"),document.body.removeChild(t),!0}};import{useCallback as ve,useEffect as dt,useRef as ct,useState as Z}from"react";function Ce(e){let{title:t,sandbox:r}=e,[o,n]=Z(!1),[s,i]=Z(!1),[p,c]=Z(!1),l=ct(null),d=_(),m=ve(async()=>{let b=l.current?.textContent??"";he(b),n(!0),setTimeout(()=>n(!1),2e3)},[]),u=ve(()=>{let b=l.current?.textContent??"",v=d?.integrations?.sandbox?.config||{},f=typeof r=="object"?r:v,N=f.entry||"src/App.tsx";fe({title:t??"Code Snippet",...f,files:{...f.files,[N]:{content:b}}})},[t,d,r]);return dt(()=>{let b=l.current?.textContent?.length??0;c(b>120)},[e.children,e.highlightedHtml]),{copied:o,isExpanded:s,setIsExpanded:i,isExpandable:p,preRef:l,handleCopy:m,handleSandbox:u,shouldTruncate:p&&!s}}import{jsx as C,jsxs as Q}from"react/jsx-runtime";var bt={ts:j,tsx:E,js:q,jsx:E,json:X,css:G,html:K,md:S,mdx:S,bash:V,sh:V,yaml:M,yml:M};function B(e){let{children:t,sandbox:r,hideSandbox:o=!0,hideCopy:n=!1,highlightedHtml:s,title:i,"data-lang":p,plain:c=!1,...l}=e,u=!!_()?.integrations?.sandbox?.enable&&!o,b=e.lang||p||"",{copied:v,isExpanded:f,setIsExpanded:N,isExpandable:L,preRef:A,handleCopy:st,handleSandbox:at,shouldTruncate:de}=Ce(e),ce=bt[b];return Q("div",{className:a("group relative overflow-hidden bg-(--color-code-bg)","contain-layout contain-paint",{"my-6 rounded-lg border border-border-subtle":!c,"[&>pre]:max-h-62.5 [&>pre]:overflow-hidden":de},e.className),children:[i&&Q("div",{className:"flex items-center gap-2 border-b border-border-subtle bg-bg-surface/50 px-4 py-2 text-[13px] font-medium text-text-muted",children:[ce?C(ce,{size:14}):C(ut,{size:14,className:"opacity-60"}),C("span",{children:i})]}),Q("div",{className:"absolute top-3 right-4 z-50 flex items-center gap-2 transition-all duration-300 opacity-0 group-hover:opacity-100",children:[u&&C(Y,{content:"Open in CodeSandbox",children:C(U.Button,{onPress:at,className:"grid place-items-center w-8 h-8 bg-transparent text-text-muted outline-none cursor-pointer transition-all duration-200 hover:scale-115 hover:text-sky-400 active:scale-95 [&>svg]:w-5 [&>svg]:h-5 [&>svg]:stroke-2","aria-label":"Open in CodeSandbox",children:C(xe,{size:20})})}),!n&&C(Y,{content:v?"Copied!":"Copy code",children:C(U.Button,{onPress:st,className:a("grid place-items-center size-8 bg-transparent outline-none cursor-pointer transition-all duration-200 hover:scale-110 active:scale-95 [&>svg]:size-4 [&>svg]:stroke-2",v?"text-emerald-400":"text-text-muted hover:text-text-main"),"aria-label":"Copy code",children:v?C(mt,{size:20}):C(pt,{size:20})})})]}),s?C("div",{ref:A,className:"shiki-wrapper [&>pre]:m-0! [&>pre]:rounded-none! [&>pre]:border-none! [&>pre]:bg-inherit! [&>pre>code]:grid! [&>pre>code]:p-5! [&>.shiki.shiki-themes]:bg-transparent!",dangerouslySetInnerHTML:{__html:s}}):C("pre",{ref:A,className:"m-0! rounded-none! border-none! bg-inherit! font-mono text-[0.8125rem] leading-[1.7]",...l,children:t}),L&&C("div",{className:a(de?"absolute bottom-0 inset-x-0 h-24 bg-linear-to-t from-(--color-code-bg) to-transparent flex items-end justify-center pb-4 z-10":"relative flex justify-center py-4"),children:C(U.Button,{onPress:()=>N(!f),className:"rounded-full bg-bg-surface border border-border-subtle px-5 py-2 text-[0.8125rem] font-medium text-text-main outline-none cursor-pointer transition-all hover:bg-border-subtle hover:-translate-y-px backdrop-blur-md",children:f?"Show less":"Expand code"})})]})}import{Children as yt,isValidElement as ht,useMemo as vt}from"react";import*as T from"react-aria-components";import{useState as Ne,useRef as ft,useEffect as xt,useCallback as gt}from"react";function Re({initialIndex:e=0,tabs:t}){let r=t[e]?.props.disabled?t.findIndex(l=>!l.props.disabled):e,[o,n]=Ne(r===-1?0:r),s=ft([]),[i,p]=Ne({opacity:0,transform:"translateX(0)",width:0});xt(()=>{let l=s.current[o];l&&p({opacity:1,width:l.offsetWidth,transform:`translateX(${l.offsetLeft}px)`})},[o,t]);let c=gt(l=>{let d=0;if(l.key==="ArrowRight"?d=1:l.key==="ArrowLeft"&&(d=-1),d!==0){let m=(o+d+t.length)%t.length;for(;t[m].props.disabled&&m!==o;)m=(m+d+t.length)%t.length;m!==o&&!t[m].props.disabled&&(n(m),s.current[m]?.focus())}},[o,t]);return{active:o,setActive:n,tabRefs:s,indicatorStyle:i,handleKeyDown:c}}import{cva as Pe}from"class-variance-authority";import{jsx as k,jsxs as ee}from"react/jsx-runtime";var Ct=Pe("relative flex items-center border-b border-border-subtle gap-1 overflow-x-auto no-scrollbar",{variants:{size:{default:"px-0",compact:"px-2"}},defaultVariants:{size:"default"}}),Nt=Pe("flex items-center gap-2 px-4 py-2.5 text-sm font-medium outline-none transition-all duration-200 cursor-pointer bg-transparent border-none select-none whitespace-nowrap",{variants:{isActive:{true:"text-primary-500",false:"text-text-muted hover:text-text-main"},isDisabled:{true:"opacity-40 pointer-events-none",false:""}},defaultVariants:{isActive:!1,isDisabled:!1}});function ke({children:e}){let t=typeof e=="string"?k(B,{className:"language-bash",children:k("code",{children:e.trim()})}):e;return k("div",{className:"py-4",children:t})}function Te({defaultIndex:e=0,children:t}){let r=vt(()=>yt.toArray(t).filter(p=>ht(p)&&p.props?.label),[t]),{active:o,setActive:n,tabRefs:s,indicatorStyle:i}=Re({initialIndex:e,tabs:r});return k("div",{className:"my-8 w-full group/tabs",children:ee(T.Tabs,{selectedKey:o.toString(),onSelectionChange:p=>n(Number(p)),className:"w-full",children:[ee(T.TabList,{"aria-label":"Content Tabs",className:a(Ct()),children:[r.map((p,c)=>{let{label:l,icon:d,disabled:m}=p.props,u=c.toString();return ee(T.Tab,{id:u,isDisabled:m,ref:b=>{s.current[c]=b},className:({isSelected:b,isDisabled:v})=>a(Nt({isActive:b,isDisabled:v})),children:[!!d&&k("span",{className:"shrink-0 [&>svg]:w-4 [&>svg]:h-4",children:d}),k("span",{children:l})]},u)}),k("div",{className:"absolute bottom-0 h-0.5 bg-primary-500 transition-all duration-300 ease-in-out pointer-events-none",style:i,"aria-hidden":"true"})]}),r.map((p,c)=>k(T.TabPanel,{id:c.toString(),children:r[c]},c))]})})}import{useRef as Rt,useState as Pt,useEffect as kt}from"react";import{jsx as we,jsxs as Tt}from"react/jsx-runtime";function Ae({src:e,poster:t,alt:r,children:o,controls:n,preload:s="metadata",...i}){let p=Rt(null),[c,l]=Pt(!1);return kt(()=>{let d=p.current;if(!d)return;let m=new IntersectionObserver(([u])=>{u.isIntersecting&&(l(!0),m.disconnect())},{rootMargin:"200px"});return m.observe(d),()=>m.disconnect()},[]),we("div",{ref:p,className:"my-6 overflow-hidden rounded-lg border border-border-subtle",children:c?Tt("video",{className:"block w-full h-auto",src:e,poster:t,controls:!0,preload:s,playsInline:!0,...i,children:[o,"Your browser does not support the video tag."]}):we("div",{className:"aspect-video bg-bg-surface animate-pulse",role:"img","aria-label":r||"Video"})})}import{cva as wt}from"class-variance-authority";import{jsx as It}from"react/jsx-runtime";var At=wt("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold tracking-tight",{variants:{variant:{default:"bg-bg-surface text-text-muted border-border-subtle",primary:"bg-primary-500/15 text-primary-400 border-primary-500/20",success:"bg-emerald-500/15 text-emerald-400 border-emerald-500/20",warning:"bg-amber-500/15 text-amber-400 border-amber-500/20",danger:"bg-red-500/15 text-red-400 border-red-500/20",info:"bg-sky-500/15 text-sky-400 border-sky-500/20"}},defaultVariants:{variant:"default"}});function Ie({variant:e="default",children:t,className:r="",...o}){return It("span",{className:a(At({variant:e}),r),...o,children:t})}import{useCallback as Lt,useRef as Le}from"react";import*as Se from"react-aria-components";import{cva as Et}from"class-variance-authority";import{Fragment as Vt,jsx as I,jsxs as Ee}from"react/jsx-runtime";var St=Et("grid gap-4 my-6",{variants:{cols:{1:"grid-cols-1",2:"grid-cols-1 sm:grid-cols-2",3:"grid-cols-1 sm:grid-cols-2 lg:grid-cols-3",4:"grid-cols-1 sm:grid-cols-2 lg:grid-cols-4"}},defaultVariants:{cols:3}});function Ve({cols:e=3,children:t,className:r="",...o}){return I("div",{className:a(St({cols:e}),r),...o,children:t})}function Me({title:e,icon:t,href:r,children:o,className:n="",...s}){let i=Le(null),p=Le(null),c=Lt(m=>{let u=i.current||p.current;if(!u)return;let{left:b,top:v}=u.getBoundingClientRect();u.style.setProperty("--x",`${m.clientX-b}px`),u.style.setProperty("--y",`${m.clientY-v}px`)},[]),l=Ee(Vt,{children:[I("div",{className:"pointer-events-none absolute -inset-px rounded-xl opacity-0 transition-opacity duration-300 group-hover:opacity-100",style:{background:"radial-gradient(400px circle at var(--x) var(--y), color-mix(in oklch, var(--color-primary-500), transparent 90%), transparent 80%)"}}),t&&I("div",{className:"mb-3 flex h-10 w-10 items-center justify-center rounded-lg bg-primary-500/10 text-primary-400 text-lg transition-transform duration-300 group-hover:scale-105 group-hover:-rotate-3",children:t}),Ee("div",{className:"space-y-1.5",children:[e&&I("h3",{className:"text-sm font-bold text-text-main",children:e}),o&&I("div",{className:"text-sm text-text-muted leading-relaxed",children:o})]})]}),d=a("group relative block rounded-xl border border-border-subtle bg-bg-surface p-5 outline-none overflow-hidden","transition-all duration-200 hover:border-primary-500/40 hover:shadow-lg hover:shadow-primary-500/5","focus-visible:ring-2 focus-visible:ring-primary-500/30",n);return r?I(Se.Link,{ref:p,href:r,className:a(d,"no-underline cursor-pointer"),onMouseMove:c,...s,children:l}):I("div",{ref:i,role:"presentation",className:d,onMouseMove:c,...s,children:l})}import{Info as Mt,Lightbulb as Bt,AlertTriangle as zt,ShieldAlert as Dt,Bookmark as Ot,Zap as Ft,Flame as Ht}from"lucide-react";import{cva as Wt}from"class-variance-authority";import{jsx as g,jsxs as ze}from"react/jsx-runtime";var $t={note:g(Ot,{size:18}),tip:g(Bt,{size:18}),info:g(Mt,{size:18}),warning:g(zt,{size:18}),danger:g(Dt,{size:18}),important:g(Ht,{size:18}),caution:g(Ft,{size:18})},_t={note:"Note",tip:"Tip",info:"Info",warning:"Warning",danger:"Danger",important:"Important",caution:"Caution"},Be=Wt("py-4 px-4 rounded-lg",{variants:{type:{note:"border-primary-400 bg-primary-500/5 text-primary-400",tip:"border-emerald-500 bg-emerald-500/5 text-emerald-500",info:"border-sky-500 bg-sky-500/5 text-sky-500",warning:"border-amber-500 bg-amber-500/5 text-amber-500",danger:"border-red-500 bg-red-500/5 text-red-500",important:"border-orange-500 bg-orange-500/5 text-orange-500",caution:"border-yellow-500 bg-yellow-500/5 text-yellow-500"}},defaultVariants:{type:"note"}});function P({type:e="note",title:t,children:r,className:o="",...n}){return ze("div",{className:a(Be({type:e}),o),role:e==="warning"||e==="danger"?"alert":"note",...n,children:[ze("div",{className:"flex items-center flex-row gap-2 mb-2",children:[g("span",{className:a("shrink-0",Be({type:e})),children:$t[e]}),g("span",{className:"text-sm font-bold tracking-tight text-text-main",children:t||_t[e]})]}),g("div",{className:"text-sm text-text-muted leading-relaxed [&>p]:m-0 [&>p]:mb-2 [&>p:last-child]:mb-0",children:r})]})}var De=e=>g(P,{type:"note",...e}),Oe=e=>g(P,{type:"tip",...e}),Fe=e=>g(P,{type:"warning",...e}),He=e=>g(P,{type:"danger",...e}),We=e=>g(P,{type:"info",...e}),$e=e=>g(P,{type:"important",...e}),_e=e=>g(P,{type:"caution",...e});import{Children as jt,isValidElement as qt}from"react";import{Check as Xt,ChevronRight as Gt,Circle as Kt}from"lucide-react";import{cva as te}from"class-variance-authority";import{jsx as w,jsxs as er}from"react/jsx-runtime";var Ut=te("my-6 transition-all duration-200",{variants:{variant:{default:"list-disc pl-5 text-text-muted marker:text-primary-500/50",number:"list-decimal pl-5 text-text-muted marker:text-primary-500/50 marker:font-bold",checked:"list-none p-0",arrow:"list-none p-0",bubble:"list-none p-0"},cols:{1:"grid-cols-1",2:"grid-cols-1 sm:grid-cols-2",3:"grid-cols-1 sm:grid-cols-2 lg:grid-cols-3",4:"grid-cols-1 sm:grid-cols-2 lg:grid-cols-4"},isGrid:{true:"grid gap-x-8 gap-y-3",false:"space-y-2"},dense:{true:"space-y-1",false:"space-y-2"}},compoundVariants:[{variant:"default",dense:!0,className:"space-y-0.5"}],defaultVariants:{variant:"default",cols:1,isGrid:!1,dense:!1}}),Jt=te("group flex items-start gap-3 text-sm leading-relaxed transition-all duration-200",{variants:{variant:{default:"",number:"",checked:"hover:translate-x-0.5",arrow:"hover:translate-x-0.5",bubble:"hover:translate-x-0.5"},dense:{true:"py-0",false:"py-0.5"}},defaultVariants:{variant:"default",dense:!1}}),Yt=te("mt-1 shrink-0 flex items-center justify-center transition-transform group-hover:scale-110",{variants:{variant:{bubble:"h-5 w-5 rounded-full bg-primary-500/10 text-primary-500 text-[10px] font-bold",default:""}},defaultVariants:{variant:"default"}});function Zt({icon:e,children:t,variant:r,dense:o}){return er("li",{className:a(Jt({variant:r,dense:o})),children:[e&&w("span",{className:a(Yt({variant:r==="bubble"?"bubble":"default"})),children:e}),w("div",{className:"flex-1 text-text-muted group-hover:text-text-main transition-colors",children:t})]})}var Qt={checked:e=>w(Xt,{size:14,className:a("text-emerald-500 shrink-0",e)}),arrow:e=>w(Gt,{size:14,className:a("text-primary-400 shrink-0",e)}),bubble:e=>w(Kt,{size:6,fill:"currentColor",className:a("text-primary-500 shrink-0",e)}),default:()=>null,number:()=>null};function je({variant:e="default",cols:t=1,dense:r=!1,children:o,className:n,...s}){let i=t!==void 0&&Number(t)>1,p=Qt[e],c=Ut({variant:e,cols:t,dense:r,isGrid:i,className:n}),l=e==="number"?"ol":"ul";return e==="default"||e==="number"?w(l,{className:c,...s,children:o}):w("ul",{className:c,...s,children:jt.map(o,d=>{if(!qt(d))return d;let m=d,u=m.type==="li"?m.props.children:m.props.children||d;return w(Zt,{icon:p(),variant:e,dense:r,children:u})})})}import{Children as re,isValidElement as ie,useMemo as tr}from"react";import*as R from"react-aria-components";import{Folder as rr,FileText as or,File as nr,FileCode as sr,FileImage as ar,ChevronRight as ir}from"lucide-react";import{jsx as y,jsxs as se}from"react/jsx-runtime";var z=16,F=2,lr={ts:j,tsx:E,js:q,jsx:E,json:X,css:G,html:K,md:S,mdx:S,bash:V,sh:V,yaml:M,yml:M},oe={CODE:/\.(ts|tsx|js|jsx|json|mjs|cjs|astro|vue|svelte)$/i,TEXT:/\.(md|mdx|txt)$/i,IMAGE:/\.(png|jpg|jpeg|svg|gif)$/i};function ae(e){return typeof e=="string"?e:typeof e=="number"?e.toString():Array.isArray(e)?e.map(ae).join(""):ie(e)&&e.props&&typeof e.props=="object"&&"children"in e.props?ae(e.props.children):""}function dr(e,t){let r=e.toLowerCase(),o="shrink-0 transition-colors duration-200";if(t)return y(rr,{size:z,strokeWidth:F,className:a(o,"text-primary-400"),fill:"currentColor",fillOpacity:.15});let n=r.split(".").pop()||"",s=lr[n];if(s)return y(s,{size:z});let i=a(o,"text-text-dim group-hover:text-text-main");return oe.CODE.test(r)?y(sr,{size:z,strokeWidth:F,className:i}):oe.TEXT.test(r)?y(or,{size:z,strokeWidth:F,className:i}):oe.IMAGE.test(r)?y(ar,{size:z,strokeWidth:F,className:i}):y(nr,{size:z,strokeWidth:F,className:i})}function ne(e,t){if(!ie(e))return!1;let r=e.type;if(typeof r=="string")return r===t;if(typeof r=="function")return r.name===t||r.name?.toLowerCase()===t;let o=e.props;return o?.originalType===t||o?.mdxType===t}function cr(e){let t=e.match(/\s+(\/\/|#)\s+(.*)$/);return t?{name:e.slice(0,t.index).trim(),comment:t[2]}:{name:e.trim()}}function J(e,t="root"){if(!ie(e))return[];let r=[];if(ne(e,"ul"))return re.forEach(e.props.children,(o,n)=>{r.push(...J(o,`${t}-${n}`))}),r;if(ne(e,"li")){let o=re.toArray(e.props.children),n=o.findIndex(v=>ne(v,"ul")),s=n!==-1,i=s?o.slice(0,n):o,p=s?o.slice(n):[],c=ae(i),{name:l,comment:d}=cr(c),m=l.endsWith("/"),u=m?l.slice(0,-1):l,b=s||m;return r.push({id:`${t}-${u}`,name:u,comment:d,isFolder:b,children:s?J(p[0],`${t}-${u}`):void 0}),r}return e.props&&typeof e.props=="object"&&"children"in e.props&&re.forEach(e.props.children,(o,n)=>{r.push(...J(o,`${t}-${n}`))}),r}function qe({item:e}){return se(R.TreeItem,{id:e.id,textValue:e.name,className:"outline-none group focus-visible:ring-2 focus-visible:ring-primary-500/30 rounded-md",children:[y(R.TreeItemContent,{children:({isExpanded:t,hasChildItems:r})=>se("div",{className:"flex items-center gap-2 py-1 px-1.5 rounded-md transition-colors hover:bg-primary-500/5 cursor-pointer",children:[y("div",{style:{width:"calc((var(--tree-item-level) - 1) * 1rem)"},className:"shrink-0"}),r?y(R.Button,{slot:"chevron",className:"outline-none text-text-dim hover:text-primary-400 p-0.5 rounded transition-colors",children:y(ir,{size:14,strokeWidth:3,className:a("transition-transform duration-200",t&&"rotate-90")})}):y("div",{className:"w-[18px]"}),dr(e.name,e.isFolder),y("span",{className:a("text-sm transition-colors truncate select-none",e.isFolder?"font-semibold text-text-main":"text-text-muted group-hover:text-text-main"),children:e.name}),e.comment&&se("span",{className:"ml-2 text-xs italic text-text-dim opacity-70 group-hover:opacity-100 transition-opacity whitespace-nowrap overflow-hidden text-ellipsis font-sans",children:["//"," ",e.comment]})]})}),e.children&&y(R.Collection,{items:e.children,children:t=>y(qe,{item:t})})]})}function Xe({children:e}){let t=tr(()=>J(e),[e]);return y("div",{className:"my-8",children:y(R.Tree,{items:t,"aria-label":"File Tree",className:a("rounded-xl border border-border-subtle bg-bg-surface/50 p-4 font-mono text-sm shadow-sm backdrop-blur-sm outline-none","max-h-[500px] overflow-y-auto scrollbar-thin scrollbar-thumb-border-subtle","focus-visible:ring-2 focus-visible:ring-primary-500/20"),children:r=>y(qe,{item:r})})})}import*as H from"react-aria-components";import{useState as Ge,useMemo as Ke}from"react";function Ue({data:e,sortable:t=!1,paginated:r=!1,pageSize:o=10}){let[n,s]=Ge(null),[i,p]=Ge(1),c=Ke(()=>{if(!e)return[];let u=[...e];return t&&n!==null&&u.sort((b,v)=>{let f=b[n.key],N=v[n.key],L=typeof f=="string"?f:"",A=typeof N=="string"?N:"";return L<A?n.direction==="asc"?-1:1:L>A?n.direction==="asc"?1:-1:0}),u},[e,n,t]),l=Math.ceil(c.length/o),d=Ke(()=>{if(!r)return c;let u=(i-1)*o;return c.slice(u,u+o)},[c,r,i,o]);return{sortConfig:n,currentPage:i,setCurrentPage:p,totalPages:l,paginatedData:d,requestSort:u=>{if(!t)return;let b="asc";n&&n.key===u&&n.direction==="asc"&&(b="desc"),s({key:u,direction:b})}}}import{ChevronUp as pr,ChevronDown as Je,ChevronLeft as mr,ChevronRight as ur,ChevronsLeft as br,ChevronsRight as fr}from"lucide-react";import{Fragment as xr,jsx as x,jsxs as D}from"react/jsx-runtime";function Ye({headers:e,data:t,children:r,className:o="",sortable:n=!1,paginated:s=!1,pageSize:i=10}){let{sortConfig:p,currentPage:c,setCurrentPage:l,totalPages:d,paginatedData:m,requestSort:u}=Ue({data:t,sortable:n,paginated:s,pageSize:i}),b=f=>n?p?.key!==f?x(Je,{size:14,className:"ml-1 opacity-30"}):p.direction==="asc"?x(pr,{size:14,className:"ml-1 text-primary-400"}):x(Je,{size:14,className:"ml-1 text-primary-400"}):null,v=r||D(xr,{children:[e&&x("thead",{children:x("tr",{children:e.map((f,N)=>x("th",{onClick:()=>u(N),className:a("text-left px-3 py-2.5 border-b-2 border-border-subtle text-text-main font-semibold text-sm",n&&"cursor-pointer select-none hover:text-primary-400 transition-colors"),children:D("div",{className:"flex items-center",children:[f,b(N)]})},N))})}),m&&x("tbody",{children:m.map((f,N)=>x("tr",{className:"transition-colors hover:bg-bg-surface",children:f.map((L,A)=>x("td",{className:"px-3 py-2 border-b border-border-subtle text-sm text-text-muted",children:L},A))},N))})]});return D("div",{className:a("my-6 rounded-lg border border-border-subtle overflow-hidden",o),children:[x("div",{className:"overflow-x-auto",children:x("table",{className:"w-full border-collapse text-sm",children:v})}),s&&d>1&&D("div",{className:"flex items-center justify-between border-t border-border-subtle px-4 py-3",children:[D("span",{className:"text-xs text-text-muted",children:["Page ",c," of ",d]}),D("div",{className:"flex items-center gap-1",children:[x(H.Button,{onPress:()=>l(1),isDisabled:c===1,className:"grid place-items-center h-7 w-7 rounded-md text-text-muted outline-none transition-colors hover:bg-bg-surface disabled:opacity-30 disabled:pointer-events-none cursor-pointer",children:x(br,{size:16})}),x(H.Button,{onPress:()=>l(f=>Math.max(f-1,1)),isDisabled:c===1,className:"grid place-items-center h-7 w-7 rounded-md text-text-muted outline-none transition-colors hover:bg-bg-surface disabled:opacity-30 disabled:pointer-events-none cursor-pointer",children:x(mr,{size:16})}),x(H.Button,{onPress:()=>l(f=>Math.min(f+1,d)),isDisabled:c===d,className:"grid place-items-center h-7 w-7 rounded-md text-text-muted outline-none transition-colors hover:bg-bg-surface disabled:opacity-30 disabled:pointer-events-none cursor-pointer",children:x(ur,{size:16})}),x(H.Button,{onPress:()=>l(d),isDisabled:c===d,className:"grid place-items-center h-7 w-7 rounded-md text-text-muted outline-none transition-colors hover:bg-bg-surface disabled:opacity-30 disabled:pointer-events-none cursor-pointer",children:x(fr,{size:16})})]})]})]})}import{jsx as O,jsxs as W}from"react/jsx-runtime";function Ze({name:e,type:t,defaultValue:r,required:o=!1,children:n,id:s,className:i=""}){return W("article",{className:a("group relative my-6 rounded-xl border border-border-subtle bg-bg-surface p-5 transition-all duration-300","hover:border-primary-500/30 hover:shadow-lg hover:shadow-primary-500/5",i),id:s,children:[W("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between mb-4",children:[W("div",{className:"flex flex-wrap items-center gap-2.5",children:[O("code",{className:"inline-flex items-center rounded-md bg-primary-500/10 px-2.5 py-1 font-mono text-sm font-bold text-primary-400 border border-primary-500/20 shadow-sm transition-colors group-hover:bg-primary-500/15",children:e}),t&&O("span",{className:"rounded-md bg-bg-muted/80 border border-border-subtle px-2 py-0.5 text-[11px] font-semibold text-text-muted uppercase tracking-wider shadow-sm",children:t}),o&&W("div",{className:"flex items-center gap-1.5 rounded-full bg-red-500/10 px-2.5 py-0.5 text-[10px] font-bold uppercase tracking-wider text-red-400 border border-red-500/20 shadow-sm",children:[O("span",{className:"h-1 w-1 rounded-full bg-red-400 animate-pulse"}),"Required"]})]}),r&&W("div",{className:"flex items-center gap-2 text-[11px] text-text-muted bg-bg-muted/30 px-2.5 py-1 rounded-md border border-border-subtle/50",children:[O("span",{className:"font-semibold opacity-60 uppercase tracking-tighter",children:"Default"}),O("code",{className:"font-mono text-text-main font-medium",children:r})]})]}),O("div",{className:"text-sm text-text-muted leading-relaxed [&>p]:m-0 selection:bg-primary-500/30",children:n})]})}import{jsx as gr}from"react/jsx-runtime";function Qe({to:e,children:t,className:r="",...o}){let n=e&&(e.startsWith("http://")||e.startsWith("https://")||e.startsWith("//")),s=a("text-blue-600 hover:text-blue-800 hover:underline cursor-pointer",r);return gr(pe,{href:e,className:s,target:n?"_blank":void 0,rel:n?"noopener noreferrer":void 0,...o,children:t})}import{jsx as yr}from"react/jsx-runtime";function et({src:e,alt:t,theme:r,...o}){let{theme:n}=me();return r&&r!==n?null:yr("img",{src:e,alt:t||"",...o})}import{jsx as h,jsxs as $}from"react/jsx-runtime";function tt({title:e,props:t,className:r=""}){return $("div",{className:a("my-6",r),children:[e&&h("h3",{className:"text-base font-bold text-text-main mb-3",children:e}),h("div",{className:"overflow-x-auto rounded-lg border border-border-subtle",children:$("table",{className:"w-full border-collapse text-sm",children:[h("thead",{children:$("tr",{children:[h("th",{className:"text-left px-4 py-3 border-b-2 border-border-subtle text-xs font-bold uppercase tracking-wider text-text-muted",children:"Property"}),h("th",{className:"text-left px-4 py-3 border-b-2 border-border-subtle text-xs font-bold uppercase tracking-wider text-text-muted",children:"Type"}),h("th",{className:"text-left px-4 py-3 border-b-2 border-border-subtle text-xs font-bold uppercase tracking-wider text-text-muted",children:"Default"}),h("th",{className:"text-left px-4 py-3 border-b-2 border-border-subtle text-xs font-bold uppercase tracking-wider text-text-muted",children:"Description"})]})}),h("tbody",{children:t.map((o,n)=>$("tr",{className:"transition-colors hover:bg-bg-surface",children:[$("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:[h("code",{className:"rounded bg-bg-surface px-1.5 py-0.5 font-mono text-xs font-bold text-primary-400",children:o.name}),o.required&&h("span",{className:"ml-1 text-red-400 font-bold",children:"*"})]}),h("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:h("code",{className:"rounded bg-bg-muted px-1.5 py-0.5 font-mono text-xs text-text-muted",children:o.type})}),h("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:o.defaultValue?h("code",{className:"rounded bg-bg-muted px-1.5 py-0.5 font-mono text-xs text-primary-400",children:o.defaultValue}):h("span",{className:"text-text-dim",children:"\u2014"})}),h("td",{className:"px-4 py-2.5 border-b border-border-subtle text-text-muted",children:o.description})]},`${o.name}-${n}`))})]})})]})}import{useMemo as rt}from"react";function ot(e){let{code:t,children:r,preview:o}=e,n=rt(()=>(t??(typeof r=="string"?r:"")).trim(),[t,r]),s=rt(()=>o??(typeof r!="string"?r:null),[o,r]);return{initialCode:n,previewElement:s}}import{jsx as le,jsxs as hr}from"react/jsx-runtime";function nt(e){let{highlightedHtml:t,hideCode:r=!1,hideSandbox:o=!1,hideCopy:n=!1,sandboxOptions:s={}}=e,{initialCode:i,previewElement:p}=ot(e);return hr("div",{className:"my-6 overflow-hidden rounded-xl border border-border-subtle",children:[le("div",{className:"flex items-center justify-center p-8 bg-bg-surface",children:p}),!r&&le("div",{className:"border-t border-border-subtle",children:le(B,{hideSandbox:o,hideCopy:n,title:s.title,lang:"tsx",highlightedHtml:t,plain:!0,children:i})})]})}export{ye as a,B as b,ke as c,Te as d,Ae as e,Ie as f,Ve as g,Me as h,P as i,De as j,Oe as k,Fe as l,He as m,We as n,$e as o,_e as p,je as q,Xe as r,Ye as s,Ze as t,Qe as u,et as v,tt as w,nt as x,vr as y};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{f as h}from"./chunk-NBCYHLAA.mjs";import{useState as u,useMemo as M,useEffect as S}from"react";import{Index as R}from"flexsearch";import m from"virtual:boltdocs-search";function E(p){let{currentLocale:o,currentVersion:s}=h(),[a,g]=u(!1),[r,d]=u(""),[c,I]=u(null);S(()=>{if(!a||c)return;let n=new R({preset:"match",tokenize:"full",resolution:9,cache:!0});for(let i of m)n.add(i.id,`${i.title} ${i.content}`);I(n)},[a,c]);let v=M(()=>{if(!r)return p.filter(e=>{let t=!o||e.locale===o,l=!s||e.version===s;return t&&l}).slice(0,10).map(e=>({id:e.path,title:e.title,path:e.path,bio:e.description||"",groupTitle:e.groupTitle}));if(!c)return[];let n=c.search(r,{limit:20,suggest:!0}),i=[],f=new Set;for(let e of n){let t=m.find(x=>x.id===e);if(!t)continue;let l=!o||t.locale===o,y=!s||t.version===s;!l||!y||f.has(t.url)||(f.add(t.url),i.push({id:t.url,title:t.title,path:t.url,bio:t.display,groupTitle:t.display.split(" > ")[0],isHeading:t.url.includes("#")}))}return i.slice(0,10)},[r,c,o,s,p]);return{isOpen:a,setIsOpen:g,query:r,setQuery:d,list:v,input:{value:r,onChange:n=>d(n.target.value)}}}export{E as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as d,e as l,ua as u,wa as c,ya as b,za as m}from"./chunk-WWJ7WKDI.mjs";import{useState as w}from"react";import{Copy as x,Check as g,ExternalLink as f,ChevronDown as v}from"lucide-react";import{jsx as e,jsxs as o}from"react/jsx-runtime";var C=n=>{let[s,t]=w(!1);return{copied:s,handleCopy:()=>{navigator.clipboard.writeText(n),t(!0),setTimeout(()=>t(!1),2e3)},handleOpenRaw:()=>{let a=new Blob([n],{type:"text/plain;charset=utf-8"}),p=URL.createObjectURL(a);window.open(p,"_blank")}}};function z({content:n,mdxRaw:s,config:t}){let i=s||n||"",{copied:r,handleCopy:a,handleOpenRaw:p}=C(i),h=t!==!1,y=typeof t=="object"&&t.text||"Copy Markdown";return!h||!i?null:e("div",{className:"relative inline-flex z-100 flex-shrink-0 w-max translate-y-0 active:translate-y-px transition-transform duration-200",children:o(u,{className:"rounded-xl border border-border-subtle bg-bg-surface/40 backdrop-blur-md transition-all duration-300 hover:border-primary-500/50 hover:shadow-lg hover:shadow-primary-500/5 group overflow-hidden",children:[e(l,{variant:"ghost",onPress:a,icon:r?e(g,{size:16}):e(x,{size:16}),iconPosition:"left",className:d("px-5 py-2 bg-transparent text-[0.8125rem] font-semibold h-9 border-none shrink-0","text-text-main transition-all duration-300 hover:bg-primary-500/5",r&&"text-emerald-500 hover:bg-emerald-500/5"),children:r?"Copied!":y}),o(c,{placement:"bottom end",children:[e(l,{variant:"ghost",isIconOnly:!0,icon:e(v,{size:14}),className:d("px-3.5 h-9 border-l border-border-subtle/50 text-text-muted rounded-none bg-transparent shrink-0","transition-all duration-300 hover:bg-primary-500/5 hover:text-primary-500")}),o(b,{className:"w-52",children:[o(m,{onAction:a,children:[e(x,{size:16,className:"size-4 mt-0.5 text-text-muted group-hover:text-primary-500"}),e("span",{className:"font-medium text-[0.8125rem]",children:"Copy Markdown"})]}),o(m,{onAction:p,children:[e(f,{size:16,className:"size-4 mt-0.5 text-text-muted group-hover:text-primary-500"}),e("span",{className:"font-medium text-[0.8125rem]",children:"View as Markdown"})]})]})]})]})})}export{z as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{useLocation as o}from"react-router-dom";var t=()=>o();export{t as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{b as B}from"./chunk-JD3RSDE4.mjs";import{b as C,e as P,f as v}from"./chunk-NBCYHLAA.mjs";import{useLocation as k}from"react-router-dom";function w(t,o){return t?typeof t=="string"?t:o&&t[o]?t[o]:Object.values(t)[0]||"":""}function J(){let t=C(),{theme:o}=B(),a=k(),{currentLocale:e}=v(),i=t.theme||{},s=w(i.title,e)||"Boltdocs",g=i.navbar||[],d=i.socialLinks||[],u=i.githubRepo,h=g.map(p=>{let l=p.href||p.to||p.link||"",f=b=>{let y=a.pathname;if(y===b)return!0;if(!b||b==="/")return y==="/";let $=T=>{let R=T.split("/").filter(Boolean),x=0;return t.i18n?.locales&&R[x]&&t.i18n.locales[R[x]]&&x++,t.versions?.versions&&R[x]&&t.versions.versions.some(S=>S.path===R[x])&&x++,R.slice(x)},V=$(b),I=$(y);return V.length===0?I.length===0:I.length<V.length?!1:V.every((T,R)=>I[R]===T)};return{label:w(p.label||p.text,e),href:l,active:f(l),to:l.startsWith("http")||l.startsWith("//")?"external":void 0}}),r=i.logo,n=r?typeof r=="string"?r:o==="dark"?r.dark:r.light:null,c={alt:(r&&typeof r=="object"?r.alt:void 0)||s,width:r&&typeof r=="object"?r.width:void 0,height:r&&typeof r=="object"?r.height:void 0},m=u?`https://github.com/${u}`:null;return{links:h,title:s,logo:n,logoProps:c,github:m,social:d,config:t,theme:o}}import{useLocation as O}from"react-router-dom";function Z(t){let o=C(),a=O(),e=n=>n.endsWith("/")&&n.length>1?n.slice(0,-1):n,i=e(a.pathname),s=t.find(n=>e(n.path)===i),g=s?.tab?.toLowerCase(),d=g?t.filter(n=>!n.tab||n.tab.toLowerCase()===g):t,u=[],h=new Map;for(let n of d)n.group?(h.has(n.group)||h.set(n.group,{slug:n.group,title:n.groupTitle||n.group,routes:[],icon:n.groupIcon}),h.get(n.group).routes.push(n)):u.push(n);return{groups:Array.from(h.values()),ungrouped:u,activeRoute:s,activePath:i,config:o}}import{useState as A}from"react";function et(t=[]){let[o,a]=A(null);return{headings:t,activeId:o,setActiveId:a}}import{useLocation as N}from"react-router-dom";import{useEffect as W,useState as j,useRef as F}from"react";function rt(t=[],o=[]){let a=N(),e=F([]),[i,s]=j({opacity:0,transform:"translateX(0) scaleX(0)",width:0}),d=o.find(r=>r.path===a.pathname)?.tab?.toLowerCase(),u=t.findIndex(r=>r.id.toLowerCase()===d),h=u===-1?0:u;return W(()=>{let r=e.current[h];r&&s({opacity:1,width:r.offsetWidth,transform:`translateX(${r.offsetLeft}px)`})},[h,t.length,a.pathname]),{tabs:t,activeIndex:h,indicatorStyle:i,tabRefs:e,activeTabId:d}}import{useNavigate as U}from"react-router-dom";function L(t,o,a){let e=t;return o&&(e===o||e.startsWith(o+"/"))&&(e=e===o?"index.md":e.slice(o.length+1)),a&&(e===a||e.startsWith(a+"/"))&&(e=e===a?"index.md":e.slice(a.length+1)),e}function gt(){let t=U(),o=v(),{allRoutes:a,currentRoute:e,currentVersion:i,currentLocale:s,config:g}=o,d=g.versions,u=P(n=>n.setVersion),h=n=>{if(!d||n===i)return;u(n);let c=`/docs/${n}`;if(e){let m=L(e.filePath,e.version,e.locale),p=a.find(l=>L(l.filePath,l.version,l.locale)===m&&(l.version||d.defaultVersion)===n&&(s?l.locale===s:!l.locale));if(p)c=p.path;else{let l=a.find(f=>L(f.filePath,f.version,f.locale)==="index.md"&&(f.version||d.defaultVersion)===n&&(s?f.locale===s:!f.locale));c=l?l.path:`/docs/${n}${s?`/${s}`:""}`}}t(c)},r=o.availableVersions.map(n=>({...n,label:n.label,value:n.key}));return{currentVersion:i,currentVersionLabel:o.currentVersionLabel,availableVersions:r,handleVersionChange:h}}import{useNavigate as H}from"react-router-dom";function vt(){let t=H(),o=v(),{allRoutes:a,currentRoute:e,currentLocale:i,config:s}=o,g=s.i18n,d=P(c=>c.setLocale),u=c=>{if(!g||c===i)return;d(c);let m="/";if(e){let p=L(e.filePath,e.version,e.locale),l=a.find(f=>L(f.filePath,f.version,f.locale)===p&&(f.locale||g.defaultLocale)===c&&f.version===e.version);if(l)m=l.path;else{let f=a.find(b=>L(b.filePath,b.version,b.locale)==="index.md"&&(b.locale||g.defaultLocale)===c&&b.version===e.version);m=f?f.path:c===g.defaultLocale?e.version?`/${e.version}`:"/":e.version?`/${e.version}/${c}`:`/${c}`}}else{let p=a.find(l=>(l.filePath==="index.mdx"||l.filePath==="index.md")&&(l.locale||g.defaultLocale)===c&&!l.version);p?m=p.path:m=c===g.defaultLocale?"/":`/${c}`}t(m)},r=s.i18n?.localeConfigs?.[i]?.label||s.i18n?.locales[i]||i,n=s.i18n?Object.entries(s.i18n.locales).map(([c,m])=>{let p=s.i18n?.localeConfigs?.[c];return{key:c,label:p?.label||m,value:c,isCurrent:c===i}}):[];return{currentLocale:i,currentLocaleLabel:r,availableLocales:n,handleLocaleChange:u}}import{useLocation as M}from"react-router-dom";function Ct(){let{routes:t,currentRoute:o}=v(),a=M();if(!o)return{prevPage:null,nextPage:null,currentRoute:null};let e=o.tab?.toLowerCase(),i=e?t.filter(u=>u.tab?.toLowerCase()===e):t.filter(u=>!u.tab),s=i.findIndex(u=>u.path===a.pathname),g=s>0?i[s-1]:null,d=s!==-1&&s<i.length-1?i[s+1]:null;return{prevPage:g,nextPage:d,currentRoute:o}}function Vt(){let{currentRoute:t}=v(),o=[];return t&&(t.groupTitle&&o.push({label:t.groupTitle}),o.push({label:t.title,href:t.path})),{crumbs:o,activeRoute:t}}export{w as a,J as b,Z as c,et as d,rt as e,gt as f,vt as g,Ct as h,Vt as i};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as oe,b as ne,c as ie,d as se,e as me,f as le,g as ce,h as pe,i as ue}from"./chunk-HRZDSFR5.mjs";import{b as Z}from"./chunk-JD3RSDE4.mjs";import{Ca as h,Da as p,F as g,P as Q,R as X,S as j,_ as P,a as H,b as z,e as C,ea as x,f as J,ka as A,pa as S,qa as ee,ra as G,sa as _,ta as te,wa as re,ya as ae,za as D}from"./chunk-WWJ7WKDI.mjs";import{b as K,f as $,g as Y}from"./chunk-NBCYHLAA.mjs";import{ArrowLeft as Me}from"lucide-react";import{jsx as I,jsxs as de}from"react/jsx-runtime";function vt(){return I("div",{className:"flex items-center justify-center min-h-[60vh] text-center",children:de("div",{className:"space-y-4",children:[I("span",{className:"text-8xl font-black tracking-tighter text-primary-500/20",children:"404"}),I("h1",{className:"text-2xl font-bold text-text-main",children:"Page Not Found"}),I("p",{className:"text-sm text-text-muted max-w-sm mx-auto",children:"The page you're looking for doesn't exist or has been moved."}),de(z,{href:"/",className:"inline-flex items-center gap-2 rounded-lg bg-primary-500 px-5 py-2.5 text-sm font-semibold text-white outline-none transition-all hover:brightness-110 hover:shadow-lg focus-visible:ring-2 focus-visible:ring-primary-500/30",children:[I(Me,{size:16})," Go to Home"]})]})})}import{jsx as u,jsxs as w}from"react/jsx-runtime";function wt(){return u("div",{className:H("w-full h-full relative overflow-y-auto transition-opacity duration-300 animate-fade-in"),children:w("div",{className:"mx-auto max-w-(--spacing-content-max) px-4 py-8 space-y-10",children:[w("div",{className:"flex gap-2",children:[u(p,{className:"h-3 w-16"}),u(p,{className:"h-3 w-24"})]}),u(p,{className:"h-10 w-[60%] sm:h-12"}),w("div",{className:"space-y-3",children:[u(p,{className:"h-4 w-full"}),u(p,{className:"h-4 w-[95%]"}),u(p,{className:"h-4 w-[40%]"})]}),w("div",{className:"space-y-6 pt-4",children:[u(p,{className:"h-7 w-32"}),w("div",{className:"space-y-3",children:[u(p,{className:"h-4 w-full"}),u(p,{className:"h-4 w-[98%]"}),u(p,{className:"h-4 w-[92%]"}),u(p,{className:"h-4 w-[60%]"})]})]}),u(p,{className:"h-32 w-full rounded-lg bg-bg-muted/50"}),w("div",{className:"space-y-6 pt-4",children:[u(p,{className:"h-7 w-48"}),w("div",{className:"space-y-3",children:[u(p,{className:"h-4 w-full"}),u(p,{className:"h-4 w-[85%]"})]})]})]})})}import{useEffect as Ee,useState as Be}from"react";import{Sun as ge,Moon as fe,Monitor as he}from"lucide-react";import{Button as Oe}from"react-aria-components";import{jsx as b,jsxs as M}from"react/jsx-runtime";function be(){let{theme:e,setTheme:t}=Z(),[n,r]=Be(!1);return Ee(()=>{r(!0)},[]),n?M(re,{placement:"bottom right",children:[b(Oe,{className:"flex h-9 w-9 items-center justify-center rounded-md text-text-muted transition-colors hover:bg-bg-surface hover:text-text-main outline-none focus-visible:ring-2 focus-visible:ring-primary-500","aria-label":"Selection theme",children:b(e==="system"?he:e==="dark"?fe:ge,{size:20,className:"animate-in fade-in zoom-in duration-300"})}),M(ae,{selectionMode:"single",selectedKeys:[e],onSelectionChange:m=>{let a=Array.from(m)[0];t(a)},children:[M(D,{id:"light",children:[b(ge,{size:16}),b("span",{children:"Light"})]}),M(D,{id:"dark",children:[b(fe,{size:16}),b("span",{children:"Dark"})]}),M(D,{id:"system",children:[b(he,{size:16}),b("span",{children:"System"})]})]})]}):b("div",{className:"h-9 w-9"})}import{useEffect as ze,useState as De}from"react";var $e="https://api.github.com";async function ve(e,t,n=$e){let r=new Headers;t&&r.append("authorization",t);let m=await(await fetch(`${n}/repos/${e}`,{headers:r})).json();return m.stargazers_count!==void 0?He(m.stargazers_count):"0"}var He=e=>Intl.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(e);import{jsx as xe,jsxs as Ae}from"react/jsx-runtime";function Ne({repo:e}){let[t,n]=De(null);return ze(()=>{e&&ve(e).then(r=>n(r)).catch(()=>n("0"))},[e]),Ae("a",{href:`https://github.com/${e}`,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 rounded-md border border-border-subtle bg-bg-surface px-2.5 py-1.5 text-xs font-medium text-text-muted transition-all hover:bg-bg-main hover:border-border-strong hover:text-text-main",children:[xe(J,{className:"h-4 w-4"}),t&&xe("span",{className:"tabular-nums",children:t})]})}import*as Ge from"lucide-react";import{jsx as R,jsxs as ye}from"react/jsx-runtime";function Pe({tabs:e,routes:t}){let{currentLocale:n}=$(),{indicatorStyle:r,tabRefs:i,activeIndex:m}=me(e,t),a=s=>{if(!s)return null;if(s.trim().startsWith("<svg"))return R("span",{className:"h-4 w-4",dangerouslySetInnerHTML:{__html:s}});let c=Ge[s];return c?R(c,{size:16}):R("img",{src:s,alt:"",className:"h-4 w-4 object-contain"})};return R("div",{className:"mx-auto max-w-(--breakpoint-3xl) px-4 md:px-6",children:ye(A.TabsList,{className:"border-none py-0",children:[e.map((s,c)=>{let y=c===m,l=t.find(d=>d.tab&&d.tab.toLowerCase()===s.id.toLowerCase()),v=l?l.path:"#";return ye(z,{href:v,ref:d=>{i.current[c]=d},className:`relative flex items-center gap-2 px-4 py-3 text-sm font-medium transition-colors outline-none ${y?"text-primary-500":"text-text-muted hover:text-text-main"}`,children:[a(s.icon),R("span",{children:oe(s.text,n)})]},s.id)}),R(A.TabsIndicator,{style:r})]})})}import{Suspense as _e,lazy as Ve}from"react";import{useLocation as Ue}from"react-router-dom";import{ChevronDown as we,Languages as qe}from"lucide-react";import{Fragment as Ze,jsx as o,jsxs as N}from"react/jsx-runtime";var Fe=Ve(()=>import("./search-dialog-OONKKC5H.mjs").then(e=>({default:e.SearchDialog})));function ir(){let{links:e,title:t,logo:n,logoProps:r,github:i,social:m,config:a}=ne(),{routes:s,allRoutes:c,currentVersion:y,currentLocale:l}=$(),{pathname:v}=Ue(),d=a.theme||{},Ie=v.startsWith("/docs"),F=d?.tabs&&d.tabs.length>0;return N(g.NavbarRoot,{className:F?"border-b-0":"",children:[N(g.Content,{children:[N(g.NavbarLeft,{children:[n&&o(g.NavbarLogo,{src:n,alt:r?.alt||t,width:r?.width??24,height:r?.height??24}),o(g.Title,{children:t}),a.versions&&y&&o(Ke,{})]}),o(g.NavbarCenter,{children:o(_e,{fallback:o("div",{className:"h-9 w-32 animate-pulse rounded-md bg-bg-surface"}),children:o(Fe,{routes:s||[]})})}),N(g.NavbarRight,{children:[o(g.Links,{children:e.map(O=>o(Ze,{children:o(We,{link:O},O.href)}))}),a.i18n&&l&&o(Ye,{}),o(g.Split,{}),o(be,{}),i&&o(Ne,{repo:d?.githubRepo??""}),m.length>0&&o(g.Split,{}),o("div",{className:"flex items-center gap-1",children:m.map(({icon:O,link:W})=>o(g.Socials,{icon:O,link:W,className:"p-1.5"},W))})]})]}),Ie&&F&&d?.tabs&&o("div",{className:"w-full border-b border-border-subtle bg-bg-main",children:o(Pe,{tabs:d.tabs,routes:c||s||[]})})]})}function We({link:e}){let t=Y(e.href||"");return o(g.Link,{...e,href:t})}function Ke(){let{currentVersionLabel:e,availableVersions:t,handleVersionChange:n}=le();return t.length===0?null:N(h.Trigger,{children:[o(C,{variant:"outline",size:"sm",rounded:"lg",iconPosition:"right",icon:o(we,{className:"w-3.5 h-3.5 text-text-muted/60"}),className:"h-8 border-border-subtle/60 bg-bg-surface/30 backdrop-blur-sm transition-all duration-200 hover:border-primary-500/50 hover:bg-primary-500/5",children:o("span",{className:"font-semibold text-[0.8125rem]",children:e})}),o(h.Root,{children:o(h.Section,{items:t,children:r=>o(h.Item,{onPress:()=>n(r.value),children:r.label},`${r.value??""}`)})})]})}function Ye(){let{currentLocale:e,availableLocales:t,handleLocaleChange:n}=ce();return t.length===0?null:N(h.Trigger,{children:[o(C,{variant:"outline",size:"sm",rounded:"lg",iconPosition:"right",icon:o(we,{className:"w-3.5 h-3.5 text-text-muted/60"}),className:"h-8 border-border-subtle/60 bg-bg-surface/30 backdrop-blur-sm transition-all duration-200 hover:border-primary-500/50 hover:bg-primary-500/5 px-2.5",children:N("div",{className:"flex items-center gap-1.5",children:[o(qe,{className:"w-3.5 h-3.5 text-primary-500"}),o("span",{className:"font-bold text-[0.75rem] tracking-wider uppercase opacity-90",children:e||"en"})]})}),o(h.Root,{children:o(h.Section,{items:t,children:r=>o(h.Item,{onPress:()=>n(r.value),children:N("div",{className:"flex items-center justify-between w-full gap-4",children:[o("span",{children:r.label}),o("span",{className:"text-[10px] font-bold opacity-40 uppercase tracking-tighter",children:r.value})]})},`${r.value??""}`)})})]})}import{Zap as Je}from"lucide-react";import{jsx as V,jsxs as Te}from"react/jsx-runtime";function ke(){return V("div",{className:"flex items-center justify-center mt-10 mb-4 px-4 w-full",children:Te("a",{href:"https://github.com/jesusalcaladev/boltdocs",target:"_blank",rel:"noopener noreferrer",className:"group relative flex items-center gap-2 px-4 py-2 rounded-full border border-border-subtle bg-bg-surface/50 backdrop-blur-md transition-all duration-300 hover:border-primary-500/50 hover:bg-bg-surface hover:shadow-xl hover:shadow-primary-500/5 select-none",children:[V(Je,{className:"w-3.5 h-3.5 text-text-muted group-hover:text-primary-500 transition-colors duration-300",fill:"currentColor"}),Te("span",{className:"text-[11px] font-medium text-text-muted group-hover:text-text-main transition-colors duration-300 tracking-wide",children:["Powered by"," ",V("strong",{className:"font-bold text-text-main/80 group-hover:text-text-main",children:"Boltdocs"})]})]})})}import{useState as Qe,useEffect as Xe,useMemo as je}from"react";import*as et from"lucide-react";import{jsx as T,jsxs as rt}from"react/jsx-runtime";function Le(e){return e&&et[e]||void 0}function tt({group:e,activePath:t,getIcon:n}){let r=je(()=>e.routes.some(a=>a.path===t),[e.routes,t]),[i,m]=Qe(!0);return Xe(()=>{r&&m(!0)},[r]),T(S.SidebarGroup,{title:e.title,isOpen:i,onToggle:()=>m(!i),children:e.routes.map(a=>{let s=t===(a.path.endsWith("/")?a.path.slice(0,-1):a.path);return T(S.SidebarLink,{label:a.title,href:a.path,active:s,icon:n(a.icon),badge:a.badge},a.path)})})}function hr({routes:e,config:t}){let{groups:n,ungrouped:r,activePath:i}=ie(e),m=t.theme||{};return rt(S.SidebarRoot,{children:[r.length>0&&T(S.SidebarGroup,{className:"mb-6",children:r.map(a=>{let s=i===(a.path.endsWith("/")?a.path.slice(0,-1):a.path);return T(S.SidebarLink,{label:a.title,href:a.path,active:s,icon:Le(a.icon),badge:a.badge},a.path)})}),n.map(a=>T(tt,{group:a,activePath:i,getIcon:Le},a.slug)),m?.poweredBy&&T("div",{className:"mt-auto pt-8",children:T(ke,{})})]})}import at,{useRef as Se,useEffect as ot,useState as nt,useCallback as it}from"react";import{Pencil as st,CircleHelp as mt,TextAlignStart as lt}from"lucide-react";import{jsx as f,jsxs as k}from"react/jsx-runtime";function wr({headings:e=[],editLink:t,communityHelp:n,filePath:r}){let{headings:i}=se(e),m=at.useMemo(()=>i.map(a=>({title:a.text,url:`#${a.id}`,depth:a.level})),[i]);return i.length===0?null:f(j,{toc:m,children:f(ct,{headings:i,editLink:t,communityHelp:n,filePath:r})})}function ct({headings:e,editLink:t,communityHelp:n,filePath:r}){let i=Q(),[m,a]=nt({opacity:0}),s=Se(null),c=Se(null);ot(()=>{if(!i||!s.current)return;let l=s.current.querySelector(`a[href="#${i}"]`);l&&a({transform:`translateY(${l.offsetTop}px)`,height:`${l.offsetHeight}px`,opacity:1})},[i]);let y=it((l,v)=>{l.preventDefault();let d=document.getElementById(v);d&&(d.scrollIntoView({behavior:"smooth"}),window.history.pushState(null,"",`#${v}`))},[]);return k(P.OnThisPageRoot,{children:[k(P.OnThisPageHeader,{className:"flex flex-row gap-x-2",children:[f(lt,{size:16}),"On this page"]}),f(X,{containerRef:c,children:k(P.OnThisPageContent,{className:"max-h-[450px] boltdocs-otp-scroll-area",ref:c,children:[f(P.OnThisPageIndicator,{style:m}),f("ul",{className:"relative space-y-2 border-l border-border-subtle",ref:s,children:e.map(l=>f(P.OnThisPageItem,{level:l.level,children:f(P.OnThisPageLink,{href:`#${l.id}`,active:i===l.id,onClick:v=>y(v,l.id),className:"pl-4",children:l.text})},l.id))})]})}),(t||n)&&k("div",{className:"mt-8 pt-8 border-t border-border-subtle space-y-4",children:[f("p",{className:"text-xs font-bold uppercase tracking-wider text-text-main",children:"Need help?"}),k("ul",{className:"space-y-3",children:[t&&r&&f("li",{children:k("a",{href:t.replace(":path",r),target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 text-sm text-text-muted hover:text-text-main transition-colors",children:[f(st,{size:16}),"Edit this page"]})}),n&&f("li",{children:k("a",{href:n,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 text-sm text-text-muted hover:text-text-main transition-colors",children:[f(mt,{size:16}),"Community help"]})})]})]})]})}import{useEffect as pt}from"react";import{useLocation as ut}from"react-router-dom";function Rr({siteTitle:e,siteDescription:t,routes:n}){let r=ut();return pt(()=>{let i=n.find(y=>y.path===r.pathname),m=i?.title,a=i?.description||t||"";document.title=m?`${m} | ${e}`:e;let s=document.querySelector('meta[name="description"]');s||(s=document.createElement("meta"),s.name="description",document.head.appendChild(s)),s.content=a,L("property","og:title",document.title),L("property","og:description",a),L("property","og:type","article"),L("property","og:url",window.location.href),L("name","twitter:card","summary"),L("name","twitter:title",document.title),L("name","twitter:description",a);let c=document.querySelector('link[rel="canonical"]');c||(c=document.createElement("link"),c.rel="canonical",document.head.appendChild(c)),c.href=window.location.origin+r.pathname},[r.pathname,e,t,n]),null}function L(e,t,n){let r=document.querySelector(`meta[${e}="${t}"]`);r||(r=document.createElement("meta"),r.setAttribute(e,t),document.head.appendChild(r)),r.content=n}import{Home as dt}from"lucide-react";import{jsx as E,jsxs as Re}from"react/jsx-runtime";function $r(){let{crumbs:e,activeRoute:t}=ue(),r=K().theme||{};return e.length===0||!r?.breadcrumbs?null:Re(ee,{children:[E(G,{children:E(_,{href:"/",children:E(dt,{size:14})})}),e.map((i,m)=>Re(G,{children:[E(te,{}),E(_,{href:i.href,className:H({"font-medium text-text-main":i.href===t?.path}),children:i.label})]},`crumb-${i.href}-${i.label}-${m}`))]})}import{jsx as B,jsxs as U}from"react/jsx-runtime";function Gr(){let{prevPage:e,nextPage:t}=pe();return!e&&!t?null:U(x.PageNavRoot,{className:"animate-in fade-in slide-in-from-bottom-4 duration-700",children:[e?U(x.PageNavLink,{to:e.path,direction:"prev",children:[B(x.PageNavLink.Title,{children:"Previous"}),B(x.PageNavLink.Description,{children:e.title})]}):B("div",{}),t&&U(x.PageNavLink,{to:t.path,direction:"next",children:[B(x.PageNavLink.Title,{children:"Next"}),B(x.PageNavLink.Description,{children:t.title})]})]})}import{Component as gt}from"react";import{jsx as q,jsxs as ft}from"react/jsx-runtime";var Ce=class extends gt{state={hasError:!1};static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,n){console.error("Uncaught error in Boltdocs Layout:",t,n)}render(){return this.state.hasError?this.props.fallback||ft("div",{className:"flex flex-col items-center justify-center min-h-[40vh] text-center gap-4 px-4",children:[q("div",{className:"text-lg font-bold text-red-400",children:"Something went wrong"}),q("p",{className:"text-sm text-text-muted max-w-md",children:this.state.error?.message||"An unexpected error occurred while rendering this page."}),q(C,{className:"rounded-lg border border-border-subtle bg-bg-surface px-5 py-2 text-sm font-medium text-text-main transition-colors hover:bg-bg-muted cursor-pointer",onPress:()=>this.setState({hasError:!1}),children:"Try again"})]}):this.props.children}};export{vt as a,wt as b,be as c,Ne as d,Pe as e,ir as f,ke as g,hr as h,wr as i,Rr as j,$r as k,Gr as l,Ce as m};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as y}from"./chunk-2Z5T6EAU.mjs";import{F as g,G as h,H as u,I as m,J as p,K as S,L as d,M as f,N as D}from"./chunk-WWJ7WKDI.mjs";import{useEffect as k,useCallback as C}from"react";import{useNavigate as E}from"react-router-dom";import{Fragment as M,jsx as o,jsxs as n}from"react/jsx-runtime";function x({routes:v}){let{isOpen:I,setIsOpen:a,query:R,setQuery:w,list:b}=y(v),r=E();k(()=>{let e=t=>{(/Mac/.test(navigator.userAgent)?t.metaKey:t.ctrlKey)&&(t.key==="k"||t.key==="j")&&(t.preventDefault(),a(i=>!i))};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[a]);let s=C(e=>{let t=String(e);if(a(!1),t.includes("#")){let[l,c]=t.split("#");r(l),setTimeout(()=>{let i=document.getElementById(c);i&&i.scrollIntoView({behavior:"smooth"})},100)}else r(t)},[r,a]);return n(M,{children:[o(g.SearchTrigger,{onPress:()=>a(!0)}),o(h,{isOpen:I,onOpenChange:a,children:n(u,{onSelectionChange:s,children:[o(m,{value:R,onChange:e=>w(e.target.value)}),o(p,{items:b,children:e=>n(S,{onPress:()=>s(e.id),textValue:e.title,children:[o(d,{isHeading:e.isHeading}),n("div",{className:"flex flex-col justify-center gap-0.5",children:[o(f,{children:e.title}),o(D,{children:e.bio})]})]},e.id)})]})})]})}export{x as a};
|