boltdocs 2.5.0 → 2.5.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 +6 -0
- package/dist/{chunk-UD2LQG2M.mjs → chunk-JGR2ELBA.mjs} +3 -3
- 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/node/cli-entry.js +2 -2
- package/dist/node/cli-entry.mjs +1 -1
- package/dist/node/index.js +2 -2
- package/dist/node/index.mjs +1 -1
- package/dist/package-SGBODKXD.mjs +1 -0
- package/package.json +1 -2
- package/src/client/app/mdx-page.tsx +2 -6
- package/src/client/components/mdx/code-block.tsx +4 -2
- package/src/node/mdx/index.ts +0 -1
- package/src/node/mdx/rehype-shiki.ts +2 -2
- package/dist/package-TWC3BMZ7.mjs +0 -1
package/dist/client/index.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{A as dr,B as pr,C as ur,D as Je,E as fr,F as Ye,G as Ze,H as j,I as W,J as We,K as ne,L as X,M as Qe,N as gr,O as C,P as T,Q as br,a as lr,b as to,c as B,d as oo,e as F,f as R,g as Ke,h as u,i as re,j as cr,k as ro,l as V,m as no,n as so,o as He,p as Oe,q as De,r as $e,s as ze,t as fe,u as ge,v as be,w as he,x as Fe,y as mr,z as E}from"../chunk-ITFGVXPE.mjs";import je,{useEffect as Ht,useState as _o,useMemo as Go}from"react";import ts from"react-dom/client";import{BrowserRouter as os,Routes as rs,Route as le}from"react-router-dom";import{ArrowLeft as hr}from"lucide-react";import{jsx as Ne,jsxs as ao}from"react/jsx-runtime";function _e(){return Ne("div",{className:"flex items-center justify-center min-h-[60vh] text-center",children:ao("div",{className:"space-y-4",children:[Ne("span",{className:"text-8xl font-black tracking-tighter text-primary-500/20",children:"404"}),Ne("h1",{className:"text-2xl font-bold text-text-main",children:"Page Not Found"}),Ne("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."}),ao(re,{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:[Ne(hr,{size:16})," Go to Home"]})]})})}import{createContext as xr,use as vr,useEffect as io,useState as et}from"react";import{jsx as yr}from"react/jsx-runtime";var lo=xr(void 0);function co({children:e}){let[t,o]=et("system"),[r,n]=et("dark"),[a,s]=et(!1);io(()=>{s(!0);let i=localStorage.getItem("boltdocs-theme"),d=i==="light"||i==="dark"||i==="system"?i:"system";o(d);let c=window.matchMedia("(prefers-color-scheme: dark)");((g,b)=>{n(g==="system"?b?"dark":"light":g)})(d,c.matches);let p=g=>{n(b=>(localStorage.getItem("boltdocs-theme")||"system")==="system"?g.matches?"dark":"light":b)};return c.addEventListener("change",p),()=>c.removeEventListener("change",p)},[]),io(()=>{if(!a)return;let i=window.matchMedia("(prefers-color-scheme: dark)").matches,d=t==="system"?i?"dark":"light":t;n(d);let c=document.documentElement;d==="light"?(c.classList.add("theme-light"),c.dataset.theme="light"):(c.classList.remove("theme-light"),c.dataset.theme="dark")},[t,a]);let l=i=>{o(i),localStorage.setItem("boltdocs-theme",i)};return yr(lo.Provider,{value:{theme:t,resolvedTheme:r,setTheme:l},children:e})}function se(){let e=vr(lo);if(e===void 0)throw new Error("useTheme must be used within a ThemeProvider");return e}import Uo from"virtual:boltdocs-layout";import{startTransition as Cr}from"react";import{RouterProvider as Rr}from"react-aria-components";import{useNavigate as Pr,useHref as Nr}from"react-router-dom";import{jsx as Tr}from"react/jsx-runtime";function mo({children:e}){let t=Pr();return Tr(Rr,{navigate:(o,r)=>{Cr(()=>{t(o,r)})},useHref:Nr,children:e})}import{useLayoutEffect as Lr}from"react";import{useLocation as wr}from"react-router-dom";function po(){let{pathname:e,hash:t}=wr();return Lr(()=>{let o=document.querySelector(".boltdocs-content")||window,r=()=>o===window?window.scrollY:o.scrollTop,n=(a,s="auto")=>{o===window?window.scrollTo({top:a,behavior:s}):o.scrollTo({top:a,behavior:s})};if(t){let a=t.replace("#",""),s=document.getElementById(a);if(s){let i=o===window?0:o.getBoundingClientRect().top,m=s.getBoundingClientRect().top-i-80+r();n(m,"smooth");return}}n(0)},[e,t]),null}import{Outlet as kr}from"react-router-dom";import Sr from"virtual:boltdocs-layout";import{jsx as uo}from"react/jsx-runtime";function fo(){return uo(Sr,{children:uo(kr,{})})}import{MDXProvider as Er}from"@mdx-js/react";import{createContext as Mr,use as Ir}from"react";import{jsx as Br}from"react/jsx-runtime";var go=Mr({});function Te(){return Ir(go)}function bo({components:e,children:t}){return Br(go.Provider,{value:e,children:t})}import{jsx as ho}from"react/jsx-runtime";function xo({Component:e}){let t=Te();return ho(Er,{components:t,children:ho(e,{})})}import{Link as Qn}from"lucide-react";var At={};lr(At,{Admonition:()=>D,Badge:()=>lt,Button:()=>tt,Card:()=>mt,Cards:()=>ct,Caution:()=>ht,CodeBlock:()=>_,ComponentPreview:()=>Et,ComponentProps:()=>It,CopyMarkdown:()=>Ie,Danger:()=>ft,Field:()=>kt,FileTree:()=>Lt,Image:()=>Mt,Important:()=>bt,InfoBox:()=>gt,Link:()=>St,List:()=>vt,Note:()=>dt,Tab:()=>st,Table:()=>wt,Tabs:()=>at,Tip:()=>pt,Video:()=>it,Warning:()=>ut});import{jsx as Ar}from"react/jsx-runtime";var tt=({className:e,variant:t,size:o,rounded:r,iconSize:n,disabled:a,...s})=>Ar(V,{className:u("group",ro({variant:t,size:o,rounded:r,iconSize:n,disabled:a,className:e})),...s});import*as Ge from"react-aria-components";import{Copy as Dr,Check as $r,File as zr}from"lucide-react";import{getParameters as vo}from"codesandbox/lib/api/define.js";function yo(e){let t=e.files||{},o=e.dependencies||{},r=e.devDependencies||{},n=e.title||"codesandbox-project",a=e.description||"Generic Sandbox",s={};for(let[l,i]of Object.entries(t)){let d=typeof i.content=="object"?JSON.stringify(i.content,null,2):i.content;s[l]={content:d,isBinary:i.isBinary??!1}}if(!s["package.json"]){let i=e.template==="vite"||!!r.vite||!!r["@vitejs/plugin-react"]?{dev:"vite",build:"vite build",preview:"vite preview"}:{start:"node index.js"};s["package.json"]={content:JSON.stringify({private:!0,name:n,description:a,type:"module",version:"1.0.0",scripts:e.scripts||i,dependencies:o,devDependencies:r},null,2),isBinary:!1}}return s}function Vr(e){let t=yo(e),o=vo({files:t}),r=new URLSearchParams({parameters:o,installDependencies:"true"});return e.entry&&r.set("file",`/${e.entry}`),{parameters:o,url:`https://codesandbox.io/api/v1/sandboxes/define?${r.toString()}`,options:e}}function Co(e){if(typeof window>"u")return Vr(e);let t=yo(e),o=vo({files:t}),r=e.entry||"src/App.tsx",n=document.createElement("form");n.method="POST",n.target="_blank",n.action="https://codesandbox.io/api/v1/sandboxes/define",n.style.display="none";let a=(l,i)=>{let d=document.createElement("input");d.type="hidden",d.name=l,d.value=i,n.appendChild(d)},s=new URLSearchParams({file:`/${r}`,eslint:"0",codemirror:"1",installDependencies:"true"});return a("query",s.toString()),a("parameters",o),document.body.appendChild(n),n.submit(),document.body.removeChild(n),{parameters:o,url:`https://codesandbox.io/api/v1/sandboxes/define?parameters=${o}`,options:e}}var Ro=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 Po,useEffect as Hr,useRef as Or,useState as ot}from"react";function No(e){let{title:t,sandbox:o}=e,[r,n]=ot(!1),[a,s]=ot(!1),[l,i]=ot(!1),d=Or(null),c=B(),m=Po(async()=>{let g=d.current?.textContent??"";Ro(g),n(!0),setTimeout(()=>n(!1),2e3)},[]),p=Po(()=>{let g=d.current?.textContent??"",b=c?.integrations?.sandbox?.config||{},f=typeof o=="object"?o:b,x=f.entry||"src/App.tsx";Co({title:t??"Code Snippet",...f,files:{...f.files,[x]:{content:g}}})},[t,c,o]);return Hr(()=>{let g=d.current?.textContent?.length??0;i(g>120)},[e.children,e.highlightedHtml]),{copied:r,isExpanded:a,setIsExpanded:s,isExpandable:l,preRef:d,handleCopy:m,handleSandbox:p,shouldTruncate:l&&!a}}import{jsx as I,jsxs as rt}from"react/jsx-runtime";var Fr={ts:He,tsx:fe,js:Oe,jsx:fe,json:De,css:$e,html:ze,md:ge,mdx:ge,bash:be,sh:be,yaml:he,yml:he};function _(e){let{children:t,sandbox:o,hideSandbox:r=!0,hideCopy:n=!1,highlightedHtml:a,title:s,"data-lang":l,plain:i=!1,...d}=e,p=!!B()?.integrations?.sandbox?.enable&&!r,g=e.lang||l||"",{copied:b,isExpanded:f,setIsExpanded:x,isExpandable:P,preRef:h,handleCopy:H,handleSandbox:O,shouldTruncate:M}=No(e),ue=Fr[g];return rt("div",{className:u("group relative overflow-hidden bg-(--color-code-bg)","contain-layout contain-paint",{"my-6 rounded-lg border border-border-subtle":!i,"[&>pre]:max-h-62.5 [&>pre]:overflow-hidden":M},e.className),children:[s&&rt("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:[ue?I(ue,{size:14}):I(zr,{size:14,className:"opacity-60"}),I("span",{children:s})]}),rt("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:[p&&I(Fe,{content:"Open in CodeSandbox",children:I(Ge.Button,{onPress:O,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:I(so,{size:20})})}),!n&&I(Fe,{content:b?"Copied!":"Copy code",children:I(Ge.Button,{onPress:H,className:u("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",b?"text-emerald-400":"text-text-muted hover:text-text-main"),"aria-label":"Copy code",children:b?I($r,{size:20}):I(Dr,{size:20})})})]}),a?I("div",{ref:h,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:a}}):I("pre",{ref:h,className:"m-0! rounded-none! border-none! bg-inherit! font-mono text-[0.8125rem] leading-[1.7]",...d,children:t}),P&&I("div",{className:u(M?"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:I(Ge.Button,{onPress:()=>x(!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 Ur,isValidElement as qr,useMemo as jr}from"react";import*as J from"react-aria-components";import{useState as To,useRef as Wr,useEffect as _r,useCallback as Gr}from"react";function Lo({initialIndex:e=0,tabs:t}){let o=t[e]?.props.disabled?t.findIndex(d=>!d.props.disabled):e,[r,n]=To(o===-1?0:o),a=Wr([]),[s,l]=To({opacity:0,transform:"translateX(0)",width:0});_r(()=>{let d=a.current[r];d&&l({opacity:1,width:d.offsetWidth,transform:`translateX(${d.offsetLeft}px)`})},[r,t]);let i=Gr(d=>{let c=0;if(d.key==="ArrowRight"?c=1:d.key==="ArrowLeft"&&(c=-1),c!==0){let m=(r+c+t.length)%t.length;for(;t[m].props.disabled&&m!==r;)m=(m+c+t.length)%t.length;m!==r&&!t[m].props.disabled&&(n(m),a.current[m]?.focus())}},[r,t]);return{active:r,setActive:n,tabRefs:a,indicatorStyle:s,handleKeyDown:i}}import{cva as wo}from"class-variance-authority";import{jsx as K,jsxs as nt}from"react/jsx-runtime";var Xr=wo("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"}}),Kr=wo("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 st({children:e}){let t=typeof e=="string"?K(_,{className:"language-bash",children:K("code",{children:e.trim()})}):e;return K("div",{className:"py-4",children:t})}function at({defaultIndex:e=0,children:t}){let o=jr(()=>Ur.toArray(t).filter(l=>qr(l)&&l.props?.label),[t]),{active:r,setActive:n,tabRefs:a,indicatorStyle:s}=Lo({initialIndex:e,tabs:o});return K("div",{className:"my-8 w-full group/tabs",children:nt(J.Tabs,{selectedKey:r.toString(),onSelectionChange:l=>n(Number(l)),className:"w-full",children:[nt(J.TabList,{"aria-label":"Content Tabs",className:u(Xr()),children:[o.map((l,i)=>{let{label:d,icon:c,disabled:m}=l.props,p=i.toString();return nt(J.Tab,{id:p,isDisabled:m,ref:g=>{a.current[i]=g},className:({isSelected:g,isDisabled:b})=>u(Kr({isActive:g,isDisabled:b})),children:[!!c&&K("span",{className:"shrink-0 [&>svg]:w-4 [&>svg]:h-4",children:c}),K("span",{children:d})]},p)}),K("div",{className:"absolute bottom-0 h-0.5 bg-primary-500 transition-all duration-300 ease-in-out pointer-events-none",style:s,"aria-hidden":"true"})]}),o.map((l,i)=>K(J.TabPanel,{id:i.toString(),children:o[i]},i))]})})}import{useRef as Jr,useState as Yr,useEffect as Zr}from"react";import{jsx as ko,jsxs as Qr}from"react/jsx-runtime";function it({src:e,poster:t,alt:o,children:r,controls:n,preload:a="metadata",...s}){let l=Jr(null),[i,d]=Yr(!1);return Zr(()=>{let c=l.current;if(!c)return;let m=new IntersectionObserver(([p])=>{p.isIntersecting&&(d(!0),m.disconnect())},{rootMargin:"200px"});return m.observe(c),()=>m.disconnect()},[]),ko("div",{ref:l,className:"my-6 overflow-hidden rounded-lg border border-border-subtle",children:i?Qr("video",{className:"block w-full h-auto",src:e,poster:t,controls:!0,preload:a,playsInline:!0,...s,children:[r,"Your browser does not support the video tag."]}):ko("div",{className:"aspect-video bg-bg-surface animate-pulse",role:"img","aria-label":o||"Video"})})}import{cva as en}from"class-variance-authority";import{jsx as on}from"react/jsx-runtime";var tn=en("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 lt({variant:e="default",children:t,className:o="",...r}){return on("span",{className:u(tn({variant:e}),o),...r,children:t})}import{useCallback as rn,useRef as So}from"react";import*as Io from"react-aria-components";import{cva as nn}from"class-variance-authority";import{Fragment as an,jsx as ae,jsxs as Mo}from"react/jsx-runtime";var sn=nn("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 ct({cols:e=3,children:t,className:o="",...r}){return ae("div",{className:u(sn({cols:e}),o),...r,children:t})}function mt({title:e,icon:t,href:o,children:r,className:n="",...a}){let s=So(null),l=So(null),i=rn(m=>{let p=s.current||l.current;if(!p)return;let{left:g,top:b}=p.getBoundingClientRect();p.style.setProperty("--x",`${m.clientX-g}px`),p.style.setProperty("--y",`${m.clientY-b}px`)},[]),d=Mo(an,{children:[ae("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&&ae("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}),Mo("div",{className:"space-y-1.5",children:[e&&ae("h3",{className:"text-sm font-bold text-text-main",children:e}),r&&ae("div",{className:"text-sm text-text-muted leading-relaxed",children:r})]})]}),c=u("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 o?ae(Io.Link,{ref:l,href:o,className:u(c,"no-underline cursor-pointer"),onMouseMove:i,...a,children:d}):ae("div",{ref:s,role:"presentation",className:c,onMouseMove:i,...a,children:d})}import{Info as ln,Lightbulb as cn,AlertTriangle as mn,ShieldAlert as dn,Bookmark as pn,Zap as un,Flame as fn}from"lucide-react";import{cva as gn}from"class-variance-authority";import{jsx as L,jsxs as Eo}from"react/jsx-runtime";var bn={note:L(pn,{size:18}),tip:L(cn,{size:18}),info:L(ln,{size:18}),warning:L(mn,{size:18}),danger:L(dn,{size:18}),important:L(fn,{size:18}),caution:L(un,{size:18})},hn={note:"Note",tip:"Tip",info:"Info",warning:"Warning",danger:"Danger",important:"Important",caution:"Caution"},Bo=gn("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 D({type:e="note",title:t,children:o,className:r="",...n}){return Eo("div",{className:u(Bo({type:e}),r),role:e==="warning"||e==="danger"?"alert":"note",...n,children:[Eo("div",{className:"flex items-center flex-row gap-2 mb-2",children:[L("span",{className:u("shrink-0",Bo({type:e})),children:bn[e]}),L("span",{className:"text-sm font-bold tracking-tight text-text-main",children:t||hn[e]})]}),L("div",{className:"text-sm text-text-muted leading-relaxed [&>p]:m-0 [&>p]:mb-2 [&>p:last-child]:mb-0",children:o})]})}var dt=e=>L(D,{type:"note",...e}),pt=e=>L(D,{type:"tip",...e}),ut=e=>L(D,{type:"warning",...e}),ft=e=>L(D,{type:"danger",...e}),gt=e=>L(D,{type:"info",...e}),bt=e=>L(D,{type:"important",...e}),ht=e=>L(D,{type:"caution",...e});import{Children as xn,isValidElement as vn}from"react";import{Check as yn,ChevronRight as Cn,Circle as Rn}from"lucide-react";import{cva as xt}from"class-variance-authority";import{jsx as Y,jsxs as kn}from"react/jsx-runtime";var Pn=xt("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}}),Nn=xt("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}}),Tn=xt("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 Ln({icon:e,children:t,variant:o,dense:r}){return kn("li",{className:u(Nn({variant:o,dense:r})),children:[e&&Y("span",{className:u(Tn({variant:o==="bubble"?"bubble":"default"})),children:e}),Y("div",{className:"flex-1 text-text-muted group-hover:text-text-main transition-colors",children:t})]})}var wn={checked:e=>Y(yn,{size:14,className:u("text-emerald-500 shrink-0",e)}),arrow:e=>Y(Cn,{size:14,className:u("text-primary-400 shrink-0",e)}),bubble:e=>Y(Rn,{size:6,fill:"currentColor",className:u("text-primary-500 shrink-0",e)}),default:()=>null,number:()=>null};function vt({variant:e="default",cols:t=1,dense:o=!1,children:r,className:n,...a}){let s=t!==void 0&&Number(t)>1,l=wn[e],i=Pn({variant:e,cols:t,dense:o,isGrid:s,className:n}),d=e==="number"?"ol":"ul";return e==="default"||e==="number"?Y(d,{className:i,...a,children:r}):Y("ul",{className:i,...a,children:xn.map(r,c=>{if(!vn(c))return c;let m=c,p=m.type==="li"?m.props.children:m.props.children||c;return Y(Ln,{icon:l(),variant:e,dense:o,children:p})})})}import{Children as yt,isValidElement as Tt,useMemo as Sn}from"react";import*as $ from"react-aria-components";import{Folder as Mn,FileText as In,File as Bn,FileCode as En,FileImage as An,ChevronRight as Vn}from"lucide-react";import{jsx as w,jsxs as Pt}from"react/jsx-runtime";var xe=16,Le=2,Hn={ts:He,tsx:fe,js:Oe,jsx:fe,json:De,css:$e,html:ze,md:ge,mdx:ge,bash:be,sh:be,yaml:he,yml:he},Ct={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 Nt(e){return typeof e=="string"?e:typeof e=="number"?e.toString():Array.isArray(e)?e.map(Nt).join(""):Tt(e)&&e.props&&typeof e.props=="object"&&"children"in e.props?Nt(e.props.children):""}function On(e,t){let o=e.toLowerCase(),r="shrink-0 transition-colors duration-200";if(t)return w(Mn,{size:xe,strokeWidth:Le,className:u(r,"text-primary-400"),fill:"currentColor",fillOpacity:.15});let n=o.split(".").pop()||"",a=Hn[n];if(a)return w(a,{size:xe});let s=u(r,"text-text-dim group-hover:text-text-main");return Ct.CODE.test(o)?w(En,{size:xe,strokeWidth:Le,className:s}):Ct.TEXT.test(o)?w(In,{size:xe,strokeWidth:Le,className:s}):Ct.IMAGE.test(o)?w(An,{size:xe,strokeWidth:Le,className:s}):w(Bn,{size:xe,strokeWidth:Le,className:s})}function Rt(e,t){if(!Tt(e))return!1;let o=e.type;if(typeof o=="string")return o===t;if(typeof o=="function")return o.name===t||o.name?.toLowerCase()===t;let r=e.props;return r?.originalType===t||r?.mdxType===t}function Dn(e){let t=e.match(/\s+(\/\/|#)\s+(.*)$/);return t?{name:e.slice(0,t.index).trim(),comment:t[2]}:{name:e.trim()}}function Ue(e,t="root"){if(!Tt(e))return[];let o=[];if(Rt(e,"ul"))return yt.forEach(e.props.children,(r,n)=>{o.push(...Ue(r,`${t}-${n}`))}),o;if(Rt(e,"li")){let r=yt.toArray(e.props.children),n=r.findIndex(b=>Rt(b,"ul")),a=n!==-1,s=a?r.slice(0,n):r,l=a?r.slice(n):[],i=Nt(s),{name:d,comment:c}=Dn(i),m=d.endsWith("/"),p=m?d.slice(0,-1):d,g=a||m;return o.push({id:`${t}-${p}`,name:p,comment:c,isFolder:g,children:a?Ue(l[0],`${t}-${p}`):void 0}),o}return e.props&&typeof e.props=="object"&&"children"in e.props&&yt.forEach(e.props.children,(r,n)=>{o.push(...Ue(r,`${t}-${n}`))}),o}function Ao({item:e}){return Pt($.TreeItem,{id:e.id,textValue:e.name,className:"outline-none group focus-visible:ring-2 focus-visible:ring-primary-500/30 rounded-md",children:[w($.TreeItemContent,{children:({isExpanded:t,hasChildItems:o})=>Pt("div",{className:"flex items-center gap-2 py-1 px-1.5 rounded-md transition-colors hover:bg-primary-500/5 cursor-pointer",children:[w("div",{style:{width:"calc((var(--tree-item-level) - 1) * 1rem)"},className:"shrink-0"}),o?w($.Button,{slot:"chevron",className:"outline-none text-text-dim hover:text-primary-400 p-0.5 rounded transition-colors",children:w(Vn,{size:14,strokeWidth:3,className:u("transition-transform duration-200",t&&"rotate-90")})}):w("div",{className:"w-[18px]"}),On(e.name,e.isFolder),w("span",{className:u("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&&Pt("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&&w($.Collection,{items:e.children,children:t=>w(Ao,{item:t})})]})}function Lt({children:e}){let t=Sn(()=>Ue(e),[e]);return w("div",{className:"my-8",children:w($.Tree,{items:t,"aria-label":"File Tree",className:u("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:o=>w(Ao,{item:o})})})}import*as we from"react-aria-components";import{useState as Vo,useMemo as Ho}from"react";function Oo({data:e,sortable:t=!1,paginated:o=!1,pageSize:r=10}){let[n,a]=Vo(null),[s,l]=Vo(1),i=Ho(()=>{if(!e)return[];let p=[...e];return t&&n!==null&&p.sort((g,b)=>{let f=g[n.key],x=b[n.key],P=typeof f=="string"?f:"",h=typeof x=="string"?x:"";return P<h?n.direction==="asc"?-1:1:P>h?n.direction==="asc"?1:-1:0}),p},[e,n,t]),d=Math.ceil(i.length/r),c=Ho(()=>{if(!o)return i;let p=(s-1)*r;return i.slice(p,p+r)},[i,o,s,r]);return{sortConfig:n,currentPage:s,setCurrentPage:l,totalPages:d,paginatedData:c,requestSort:p=>{if(!t)return;let g="asc";n&&n.key===p&&n.direction==="asc"&&(g="desc"),a({key:p,direction:g})}}}import{ChevronUp as $n,ChevronDown as Do,ChevronLeft as zn,ChevronRight as Fn,ChevronsLeft as Wn,ChevronsRight as _n}from"lucide-react";import{Fragment as Gn,jsx as N,jsxs as ve}from"react/jsx-runtime";function wt({headers:e,data:t,children:o,className:r="",sortable:n=!1,paginated:a=!1,pageSize:s=10}){let{sortConfig:l,currentPage:i,setCurrentPage:d,totalPages:c,paginatedData:m,requestSort:p}=Oo({data:t,sortable:n,paginated:a,pageSize:s}),g=f=>n?l?.key!==f?N(Do,{size:14,className:"ml-1 opacity-30"}):l.direction==="asc"?N($n,{size:14,className:"ml-1 text-primary-400"}):N(Do,{size:14,className:"ml-1 text-primary-400"}):null,b=o||ve(Gn,{children:[e&&N("thead",{children:N("tr",{children:e.map((f,x)=>N("th",{onClick:()=>p(x),className:u("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:ve("div",{className:"flex items-center",children:[f,g(x)]})},x))})}),m&&N("tbody",{children:m.map((f,x)=>N("tr",{className:"transition-colors hover:bg-bg-surface",children:f.map((P,h)=>N("td",{className:"px-3 py-2 border-b border-border-subtle text-sm text-text-muted",children:P},h))},x))})]});return ve("div",{className:u("my-6 rounded-lg border border-border-subtle overflow-hidden",r),children:[N("div",{className:"overflow-x-auto",children:N("table",{className:"w-full border-collapse text-sm",children:b})}),a&&c>1&&ve("div",{className:"flex items-center justify-between border-t border-border-subtle px-4 py-3",children:[ve("span",{className:"text-xs text-text-muted",children:["Page ",i," of ",c]}),ve("div",{className:"flex items-center gap-1",children:[N(we.Button,{onPress:()=>d(1),isDisabled:i===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:N(Wn,{size:16})}),N(we.Button,{onPress:()=>d(f=>Math.max(f-1,1)),isDisabled:i===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:N(zn,{size:16})}),N(we.Button,{onPress:()=>d(f=>Math.min(f+1,c)),isDisabled:i===c,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:N(Fn,{size:16})}),N(we.Button,{onPress:()=>d(c),isDisabled:i===c,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:N(_n,{size:16})})]})]})]})}import{jsx as ye,jsxs as ke}from"react/jsx-runtime";function kt({name:e,type:t,defaultValue:o,required:r=!1,children:n,id:a,className:s=""}){return ke("article",{className:u("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",s),id:a,children:[ke("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between mb-4",children:[ke("div",{className:"flex flex-wrap items-center gap-2.5",children:[ye("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&&ye("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}),r&&ke("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:[ye("span",{className:"h-1 w-1 rounded-full bg-red-400 animate-pulse"}),"Required"]})]}),o&&ke("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:[ye("span",{className:"font-semibold opacity-60 uppercase tracking-tighter",children:"Default"}),ye("code",{className:"font-mono text-text-main font-medium",children:o})]})]}),ye("div",{className:"text-sm text-text-muted leading-relaxed [&>p]:m-0 selection:bg-primary-500/30",children:n})]})}import{jsx as Un}from"react/jsx-runtime";function St({to:e,children:t,className:o="",...r}){let n=e&&(e.startsWith("http://")||e.startsWith("https://")||e.startsWith("//")),a=u("text-blue-600 hover:text-blue-800 hover:underline cursor-pointer",o);return Un(re,{href:e,className:a,target:n?"_blank":void 0,rel:n?"noopener noreferrer":void 0,...r,children:t})}import{jsx as qn}from"react/jsx-runtime";function Mt({src:e,alt:t,theme:o,...r}){let{theme:n}=se();return o&&o!==n?null:qn("img",{src:e,alt:t||"",...r})}import{jsx as k,jsxs as Se}from"react/jsx-runtime";function It({title:e,props:t,className:o=""}){return Se("div",{className:u("my-6",o),children:[e&&k("h3",{className:"text-base font-bold text-text-main mb-3",children:e}),k("div",{className:"overflow-x-auto rounded-lg border border-border-subtle",children:Se("table",{className:"w-full border-collapse text-sm",children:[k("thead",{children:Se("tr",{children:[k("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"}),k("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"}),k("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"}),k("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"})]})}),k("tbody",{children:t.map((r,n)=>Se("tr",{className:"transition-colors hover:bg-bg-surface",children:[Se("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:[k("code",{className:"rounded bg-bg-surface px-1.5 py-0.5 font-mono text-xs font-bold text-primary-400",children:r.name}),r.required&&k("span",{className:"ml-1 text-red-400 font-bold",children:"*"})]}),k("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:k("code",{className:"rounded bg-bg-muted px-1.5 py-0.5 font-mono text-xs text-text-muted",children:r.type})}),k("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:r.defaultValue?k("code",{className:"rounded bg-bg-muted px-1.5 py-0.5 font-mono text-xs text-primary-400",children:r.defaultValue}):k("span",{className:"text-text-dim",children:"\u2014"})}),k("td",{className:"px-4 py-2.5 border-b border-border-subtle text-text-muted",children:r.description})]},`${r.name}-${n}`))})]})})]})}import{useMemo as $o}from"react";function zo(e){let{code:t,children:o,preview:r}=e,n=$o(()=>(t??(typeof o=="string"?o:"")).trim(),[t,o]),a=$o(()=>r??(typeof o!="string"?o:null),[r,o]);return{initialCode:n,previewElement:a}}import{jsx as Bt,jsxs as jn}from"react/jsx-runtime";function Et(e){let{highlightedHtml:t,hideCode:o=!1,hideSandbox:r=!1,hideCopy:n=!1,sandboxOptions:a={}}=e,{initialCode:s,previewElement:l}=zo(e);return jn("div",{className:"my-6 overflow-hidden rounded-xl border border-border-subtle",children:[Bt("div",{className:"flex items-center justify-center p-8 bg-bg-surface",children:l}),!o&&Bt("div",{className:"border-t border-border-subtle",children:Bt(_,{hideSandbox:r,hideCopy:n,title:a.title,lang:"tsx",highlightedHtml:t,plain:!0,children:s})})]})}import{useState as Xn}from"react";import{Copy as Fo,Check as Kn,ExternalLink as Jn,ChevronDown as Yn}from"lucide-react";import{jsx as z,jsxs as Me}from"react/jsx-runtime";var Zn=e=>{let[t,o]=Xn(!1);return{copied:t,handleCopy:()=>{navigator.clipboard.writeText(e),o(!0),setTimeout(()=>o(!1),2e3)},handleOpenRaw:()=>{let a=new Blob([e],{type:"text/plain;charset=utf-8"}),s=URL.createObjectURL(a);window.open(s,"_blank")}}};function Ie({content:e,mdxRaw:t,config:o}){let r=t||e||"",{copied:n,handleCopy:a,handleOpenRaw:s}=Zn(r),l=o!==!1,i=typeof o=="object"&&o.text||"Copy Markdown";return!l||!r?null:z("div",{className:"relative inline-flex z-100 flex-shrink-0 w-max translate-y-0 active:translate-y-px transition-transform duration-200",children:Me(Qe,{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:[z(V,{variant:"ghost",onPress:a,icon:n?z(Kn,{size:16}):z(Fo,{size:16}),iconPosition:"left",className:u("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!":i}),Me(C.Trigger,{placement:"bottom end",children:[z(V,{variant:"ghost",isIconOnly:!0,icon:z(Yn,{size:14}),className:u("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")}),Me(C.Root,{className:"w-52",children:[Me(C.Item,{onAction:a,children:[z(Fo,{size:16,className:"size-4 mt-0.5 text-text-muted group-hover:text-primary-500"}),z("span",{className:"font-medium text-[0.8125rem]",children:"Copy Markdown"})]}),Me(C.Item,{onAction:s,children:[z(Jn,{size:16,className:"size-4 mt-0.5 text-text-muted group-hover:text-primary-500"}),z("span",{className:"font-medium text-[0.8125rem]",children:"View as Markdown"})]})]})]})]})})}import{jsx as S,jsxs as ie}from"react/jsx-runtime";function Vt(){return S("div",{className:u("w-full h-full relative overflow-y-auto transition-opacity duration-300 animate-fade-in"),children:ie("div",{className:"mx-auto max-w-(--spacing-content-max) px-4 py-8 space-y-10",children:[ie("div",{className:"flex gap-2",children:[S(T,{className:"h-3 w-16"}),S(T,{className:"h-3 w-24"})]}),S(T,{className:"h-10 w-[60%] sm:h-12"}),ie("div",{className:"space-y-3",children:[S(T,{className:"h-4 w-full"}),S(T,{className:"h-4 w-[95%]"}),S(T,{className:"h-4 w-[40%]"})]}),ie("div",{className:"space-y-6 pt-4",children:[S(T,{className:"h-7 w-32"}),ie("div",{className:"space-y-3",children:[S(T,{className:"h-4 w-full"}),S(T,{className:"h-4 w-[98%]"}),S(T,{className:"h-4 w-[92%]"}),S(T,{className:"h-4 w-[60%]"})]})]}),S(T,{className:"h-32 w-full rounded-lg bg-bg-muted/50"}),ie("div",{className:"space-y-6 pt-4",children:[S(T,{className:"h-7 w-48"}),ie("div",{className:"space-y-3",children:[S(T,{className:"h-4 w-full"}),S(T,{className:"h-4 w-[85%]"})]})]})]})})}import{jsx as G,jsxs as es}from"react/jsx-runtime";var Ce=({level:e,id:t,children:o,...r})=>{let n=`h${e}`;return es(n,{id:t,...r,className:"boltdocs-heading",children:[o,t&&G("a",{href:`#${t}`,className:"header-anchor","aria-label":"Anchor",children:G(Qn,{size:16})})]})},Wo={...At,Loading:Vt,h1:e=>G(Ce,{level:1,...e}),h2:e=>G(Ce,{level:2,...e}),h3:e=>G(Ce,{level:3,...e}),h4:e=>G(Ce,{level:4,...e}),h5:e=>G(Ce,{level:5,...e}),h6:e=>G(Ce,{level:6,...e}),pre:e=>G(_,{...e,children:e.children})};import ns from"virtual:boltdocs-mdx-components";import{useLocation as ss}from"react-router-dom";import{Fragment as ms,jsx as y,jsxs as qe}from"react/jsx-runtime";function as(){let{currentLocale:e,config:t}=R();return Ht(()=>{if(!t.i18n)return;let o=t.i18n.localeConfigs?.[e];document.documentElement.lang=o?.htmlLang||e||"en",document.documentElement.dir=o?.direction||"ltr"},[e,t.i18n]),null}function is(){let e=ss(),{config:t}=R(),o=F(s=>s.setLocale),r=F(s=>s.setVersion),n=F(s=>s.currentLocale),a=F(s=>s.currentVersion);return Ht(()=>{let s=e.pathname.split("/").filter(Boolean),l=0,i=t.versions?.defaultVersion,d=t.i18n?.defaultLocale;if(s[l]==="docs"&&l++,t.versions&&s.length>l){let c=t.versions.versions.find(m=>m.path===s[l]);c&&(i=c.path,l++)}t.i18n&&s.length>l&&t.i18n.locales[s[l]]?d=s[l]:t.i18n&&s.length===0&&(d=n||t.i18n.defaultLocale),d!==n&&o(d),i!==a&&r(i)},[e.pathname,t,o,r,n,a]),null}function ls({initialRoutes:e,initialConfig:t,docsDirName:o,modules:r,hot:n,homePage:a,externalPages:s,externalLayout:l,components:i={}}){let[d,c]=_o(e),[m,p]=_o(t),g=s||{},b=l||Uo,f=Go(()=>d.filter(h=>!(a&&(h.path==="/"||h.path===""))&&!g[h.path===""?"/":h.path]).map(h=>{let H=Object.keys(r).find(M=>M===`/${o}/${h.filePath}`||M.endsWith(`/${o}/${h.filePath}`)||M.endsWith(`/${o}\\${h.filePath.replace(/\\/g,"/")}`)),O=H?r[H]:null;return{...h,Component:je.lazy(async()=>O?await O():{default:_e})}}),[d,r,o,a,g]);Ht(()=>{n&&(n.on("boltdocs:routes-update",h=>{c(h)}),n.on("boltdocs:config-update",h=>{p(h)}))},[n]);let x=Go(()=>({...Wo,...ns,...i}),[i]),P=x.Loading;return y(co,{children:y(bo,{components:x,children:y(to.Provider,{value:m,children:y(mo,{children:qe(oo,{routes:d,modules:r,children:[y(po,{}),y(is,{}),y(as,{}),qe(rs,{children:[y(le,{element:y(fo,{}),children:f.map(h=>y(le,{path:h.path===""?"/":h.path,element:y(je.Suspense,{fallback:y(P,{}),children:y(xo,{Component:h.Component})})},h.path))},"docs-layout"),a&&qe(ms,{children:[y(le,{path:"/",element:y(b,{children:y(a,{})})}),m.i18n&&Object.keys(m.i18n.locales).map(h=>y(le,{path:`/${h}`,element:y(b,{children:y(a,{})})},`home-${h}`))]}),Object.entries(g).map(([h,H])=>{let O=h==="/"?"":h;return qe(je.Fragment,{children:[y(le,{path:h,element:y(b,{children:y(H,{})})}),m.i18n&&Object.keys(m.i18n.locales).map(M=>y(le,{path:`/${M}${O}`,element:y(b,{children:y(H,{})})},`${h}-${M}`))]},h)}),y(le,{path:"*",element:y(Uo,{children:y(_e,{})})})]})]})})})})})}function cs(e){let{target:t,routes:o,docsDirName:r,config:n,modules:a,hot:s,homePage:l,externalPages:i,externalLayout:d,components:c}=e,m=document.querySelector(t);if(!m)throw new Error(`[boltdocs] Mount target "${t}" not found in document.`);let p=y(je.StrictMode,{children:y(os,{children:y(ls,{initialRoutes:o,initialConfig:n,docsDirName:r,modules:a,hot:s,homePage:l,externalPages:i,externalLayout:d,components:c})})});m.innerHTML="",ts.createRoot(m).render(p)}import{useLocation as ds}from"react-router-dom";function Z(e,t){return e?typeof e=="string"?e:t&&e[t]?e[t]:Object.values(e)[0]||"":""}function Ot(){let e=B(),{theme:t}=se(),o=ds(),{currentLocale:r}=R(),n=e.theme||{},a=Z(n.title,r)||"Boltdocs",s=n.navbar||[],l=n.socialLinks||[],i=n.githubRepo,d=s.map(b=>{let f=b.href||b.to||b.link||"",x=P=>{let h=o.pathname;if(h===P)return!0;if(!P||P==="/")return h==="/";let H=ue=>{let te=ue.split("/").filter(Boolean),oe=0;return e.i18n?.locales&&te[oe]&&e.i18n.locales[te[oe]]&&oe++,e.versions?.versions&&te[oe]&&e.versions.versions.some(ir=>ir.path===te[oe])&&oe++,te.slice(oe)},O=H(P),M=H(h);return O.length===0?M.length===0:M.length<O.length?!1:O.every((ue,te)=>M[te]===ue)};return{label:Z(b.label||b.text,r),href:f,active:x(f),to:f.startsWith("http")||f.startsWith("//")?"external":void 0}}),c=n.logo,m=c?typeof c=="string"?c:t==="dark"?c.dark:c.light:null,p={alt:(c&&typeof c=="object"?c.alt:void 0)||a,width:c&&typeof c=="object"?c.width:void 0,height:c&&typeof c=="object"?c.height:void 0},g=i?`https://github.com/${i}`:null;return{links:d,title:a,logo:m,logoProps:p,github:g,social:l,config:e,theme:t}}import{useLocation as ps}from"react-router-dom";function Dt(e){let t=B(),o=ps(),r=m=>m.endsWith("/")&&m.length>1?m.slice(0,-1):m,n=r(o.pathname),a=e.find(m=>r(m.path)===n),s=a?.tab?.toLowerCase(),l=s?e.filter(m=>!m.tab||m.tab.toLowerCase()===s):e,i=[],d=new Map;for(let m of l)m.group?(d.has(m.group)||d.set(m.group,{slug:m.group,title:m.groupTitle||m.group,routes:[],icon:m.groupIcon}),d.get(m.group).routes.push(m)):i.push(m);return{groups:Array.from(d.values()),ungrouped:i,activeRoute:a,activePath:n,config:t}}import{useState as us}from"react";function $t(e=[]){let[t,o]=us(null);return{headings:e,activeId:t,setActiveId:o}}import{useLocation as fs}from"react-router-dom";import{useEffect as gs,useState as bs,useRef as hs}from"react";function zt(e=[],t=[]){let o=fs(),r=hs([]),[n,a]=bs({opacity:0,transform:"translateX(0) scaleX(0)",width:0}),l=t.find(c=>c.path===o.pathname)?.tab?.toLowerCase(),i=e.findIndex(c=>c.id.toLowerCase()===l),d=i===-1?0:i;return gs(()=>{let c=r.current[d];c&&a({opacity:1,width:c.offsetWidth,transform:`translateX(${c.offsetLeft}px)`})},[d,e.length,o.pathname]),{tabs:e,activeIndex:d,indicatorStyle:n,tabRefs:r,activeTabId:l}}import{useNavigate as xs}from"react-router-dom";function Q(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}function Ft(){let e=xs(),t=R(),{allRoutes:o,currentRoute:r,currentVersion:n,currentLocale:a,config:s}=t,l=s.versions,i=F(m=>m.setVersion),d=m=>{if(!l||m===n)return;i(m);let p=`/docs/${m}`;if(r){let g=Q(r.filePath,r.version,r.locale),b=o.find(f=>Q(f.filePath,f.version,f.locale)===g&&(f.version||l.defaultVersion)===m&&(a?f.locale===a:!f.locale));if(b)p=b.path;else{let f=o.find(x=>Q(x.filePath,x.version,x.locale)==="index.md"&&(x.version||l.defaultVersion)===m&&(a?x.locale===a:!x.locale));p=f?f.path:`/docs/${m}${a?`/${a}`:""}`}}e(p)},c=t.availableVersions.map(m=>({...m,label:m.label,value:m.key}));return{currentVersion:n,currentVersionLabel:t.currentVersionLabel,availableVersions:c,handleVersionChange:d}}import{useNavigate as vs}from"react-router-dom";function Wt(){let e=vs(),t=R(),{allRoutes:o,currentRoute:r,currentLocale:n,config:a}=t,s=a.i18n,l=F(p=>p.setLocale),i=p=>{if(!s||p===n)return;l(p);let g="/";if(r){let b=Q(r.filePath,r.version,r.locale),f=o.find(x=>Q(x.filePath,x.version,x.locale)===b&&(x.locale||s.defaultLocale)===p&&x.version===r.version);if(f)g=f.path;else{let x=o.find(P=>Q(P.filePath,P.version,P.locale)==="index.md"&&(P.locale||s.defaultLocale)===p&&P.version===r.version);g=x?x.path:p===s.defaultLocale?r.version?`/${r.version}`:"/":r.version?`/${r.version}/${p}`:`/${p}`}}else{let b=o.find(f=>(f.filePath==="index.mdx"||f.filePath==="index.md")&&(f.locale||s.defaultLocale)===p&&!f.version);b?g=b.path:g=p===s.defaultLocale?"/":`/${p}`}e(g)},c=a.i18n?.localeConfigs?.[n]?.label||a.i18n?.locales[n]||n,m=a.i18n?Object.entries(a.i18n.locales).map(([p,g])=>{let b=a.i18n?.localeConfigs?.[p];return{key:p,label:b?.label||g,value:p,isCurrent:p===n}}):[];return{currentLocale:n,currentLocaleLabel:c,availableLocales:m,handleLocaleChange:i}}import{useLocation as ys}from"react-router-dom";function _t(){let{routes:e,currentRoute:t}=R(),o=ys();if(!t)return{prevPage:null,nextPage:null,currentRoute:null};let r=t.tab?.toLowerCase(),n=r?e.filter(i=>i.tab?.toLowerCase()===r):e.filter(i=>!i.tab),a=n.findIndex(i=>i.path===o.pathname),s=a>0?n[a-1]:null,l=a!==-1&&a<n.length-1?n[a+1]:null;return{prevPage:s,nextPage:l,currentRoute:t}}function Gt(){let{currentRoute:e}=R(),t=[];return e&&(e.groupTitle&&t.push({label:e.groupTitle}),t.push({label:e.title,href:e.path})),{crumbs:t,activeRoute:e}}import{useLocation as Cs}from"react-router-dom";var Ut=()=>Cs();import{jsx as Re}from"react/jsx-runtime";function Rs({children:e,className:t,style:o}){return Re("div",{className:u("h-screen flex flex-col overflow-hidden bg-bg-main text-text-main",t),style:o,children:e})}function Ps({children:e,className:t,style:o}){return Re("div",{className:u("mx-auto flex flex-1 w-full max-w-(--breakpoint-3xl) bg-bg-main overflow-hidden",t),style:o,children:e})}function Ns({children:e,className:t,style:o}){return Re("main",{className:u("boltdocs-content flex-1 min-w-0 overflow-y-auto","contain-layout",t),style:o,children:e})}function Ts({children:e,className:t,style:o}){let{pathname:r}=Ut();return Re("div",{className:u("boltdocs-page mx-auto pt-4 pb-20 px-4 sm:px-8",{"max-w-content-max":r.includes("/docs/")},t),style:o,children:e})}function Ls({children:e,className:t,style:o}){return Re("div",{className:u("flex items-center justify-between mb-10",t),style:o,children:e})}function ws({children:e,className:t,style:o}){return Re("div",{className:u("mt-20",t),style:o,children:e})}var ce=Object.assign(Rs,{Body:Ps,Content:Ns,ContentMdx:Ts,ContentHeader:Ls,ContentFooter:ws});import{Suspense as Os,lazy as Ds}from"react";import{useEffect as ks,useState as Ss}from"react";import{Sun as qo,Moon as jo,Monitor as Xo}from"lucide-react";import{Button as Ms}from"react-aria-components";import{jsx as U,jsxs as Be}from"react/jsx-runtime";function Ko(){let{theme:e,setTheme:t}=se(),[o,r]=Ss(!1);if(ks(()=>{r(!0)},[]),!o)return U("div",{className:"h-9 w-9"});let n=e==="system"?Xo:e==="dark"?jo:qo;return Be(C.Trigger,{placement:"bottom right",children:[U(Ms,{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:U(n,{size:20,className:"animate-in fade-in zoom-in duration-300"})}),Be(C.Root,{selectionMode:"single",selectedKeys:[e],onSelectionChange:a=>{let s=Array.from(a)[0];t(s)},children:[Be(C.Item,{id:"light",children:[U(qo,{size:16}),U("span",{children:"Light"})]}),Be(C.Item,{id:"dark",children:[U(jo,{size:16}),U("span",{children:"Dark"})]}),Be(C.Item,{id:"system",children:[U(Xo,{size:16}),U("span",{children:"System"})]})]})]})}import{useEffect as Es,useState as As}from"react";var Is="https://api.github.com";async function Jo(e,t,o=Is){let r=new Headers;t&&r.append("authorization",t);let a=await(await fetch(`${o}/repos/${e}`,{headers:r})).json();return a.stargazers_count!==void 0?Bs(a.stargazers_count):"0"}var Bs=e=>Intl.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(e);import{jsx as Yo,jsxs as Vs}from"react/jsx-runtime";function Zo({repo:e}){let[t,o]=As(null);return Es(()=>{e&&Jo(e).then(r=>o(r)).catch(()=>o("0"))},[e]),Vs("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:[Yo(no,{className:"h-4 w-4"}),t&&Yo("span",{className:"tabular-nums",children:t})]})}import*as Hs from"lucide-react";import{jsx as Pe,jsxs as Qo}from"react/jsx-runtime";function er({tabs:e,routes:t}){let{currentLocale:o}=R(),{indicatorStyle:r,tabRefs:n,activeIndex:a}=zt(e,t),s=l=>{if(!l)return null;if(l.trim().startsWith("<svg"))return Pe("span",{className:"h-4 w-4",dangerouslySetInnerHTML:{__html:l}});let i=Hs[l];return i?Pe(i,{size:16}):Pe("img",{src:l,alt:"",className:"h-4 w-4 object-contain"})};return Pe("div",{className:"mx-auto max-w-(--breakpoint-3xl) px-4 md:px-6",children:Qo(We.List,{className:"border-none py-0",children:[e.map((l,i)=>{let d=i===a,c=t.find(p=>p.tab&&p.tab.toLowerCase()===l.id.toLowerCase()),m=c?c.path:"#";return Qo(re,{href:m,ref:p=>{n.current[i]=p},className:`relative flex items-center gap-2 px-4 py-3 text-sm font-medium transition-colors outline-none ${d?"text-primary-500":"text-text-muted hover:text-text-main"}`,children:[s(l.icon),Pe("span",{children:Z(l.text,o)})]},l.id)}),Pe(We.Indicator,{style:r})]})})}import{useLocation as $s}from"react-router-dom";import{ChevronDown as tr,Languages as zs}from"lucide-react";import{Fragment as Us,jsx as v,jsxs as ee}from"react/jsx-runtime";var Fs=Ds(()=>import("../search-dialog-YBM4GYDR.mjs").then(e=>({default:e.SearchDialog})));function qt(){let{links:e,title:t,logo:o,logoProps:r,github:n,social:a,config:s}=Ot(),{routes:l,allRoutes:i,currentVersion:d,currentLocale:c}=R(),{pathname:m}=$s(),p=s.theme||{},g=m.startsWith("/docs"),b=p?.tabs&&p.tabs.length>0;return ee(E.Root,{className:b?"border-b-0":"",children:[ee(E.Content,{children:[ee(E.Left,{children:[o&&v(E.Logo,{src:o,alt:r?.alt||t,width:r?.width??24,height:r?.height??24}),v(E.Title,{children:t}),s.versions&&d&&v(_s,{})]}),v(E.Center,{children:v(Os,{fallback:v("div",{className:"h-9 w-32 animate-pulse rounded-md bg-bg-surface"}),children:v(Fs,{routes:l||[]})})}),ee(E.Right,{children:[v(E.Links,{children:e.map(f=>v(Us,{children:v(Ws,{link:f},f.href)}))}),s.i18n&&c&&v(Gs,{}),v(E.Split,{}),v(Ko,{}),n&&v(Zo,{repo:p?.githubRepo??""}),a.length>0&&v(E.Split,{}),v("div",{className:"flex items-center gap-1",children:a.map(({icon:f,link:x})=>v(E.Socials,{icon:f,link:x,className:"p-1.5"},x))})]})]}),g&&b&&p?.tabs&&v("div",{className:"w-full border-b border-border-subtle bg-bg-main",children:v(er,{tabs:p.tabs,routes:i||l||[]})})]})}function Ws({link:e}){let t=Ke(e.href||"");return v(E.Link,{...e,href:t})}function _s(){let{currentVersionLabel:e,availableVersions:t,handleVersionChange:o}=Ft();return t.length===0?null:ee(C.Trigger,{children:[v(V,{variant:"outline",size:"sm",rounded:"lg",iconPosition:"right",icon:v(tr,{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:v("span",{className:"font-semibold text-[0.8125rem]",children:e})}),v(C.Root,{children:v(C.Section,{items:t,children:r=>v(C.Item,{onPress:()=>o(r.value),children:r.label},`${r.value??""}`)})})]})}function Gs(){let{currentLocale:e,availableLocales:t,handleLocaleChange:o}=Wt();return t.length===0?null:ee(C.Trigger,{children:[v(V,{variant:"outline",size:"sm",rounded:"lg",iconPosition:"right",icon:v(tr,{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:ee("div",{className:"flex items-center gap-1.5",children:[v(zs,{className:"w-3.5 h-3.5 text-primary-500"}),v("span",{className:"font-bold text-[0.75rem] tracking-wider uppercase opacity-90",children:e||"en"})]})}),v(C.Root,{children:v(C.Section,{items:t,children:r=>v(C.Item,{onPress:()=>o(r.value),children:ee("div",{className:"flex items-center justify-between w-full gap-4",children:[v("span",{children:r.label}),v("span",{className:"text-[10px] font-bold opacity-40 uppercase tracking-tighter",children:r.value})]})},`${r.value??""}`)})})]})}import{useState as js,useEffect as Xs,useMemo as Ks}from"react";import{Zap as qs}from"lucide-react";import{jsx as jt,jsxs as or}from"react/jsx-runtime";function rr(){return jt("div",{className:"flex items-center justify-center mt-10 mb-4 px-4 w-full",children:or("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:[jt(qs,{className:"w-3.5 h-3.5 text-text-muted group-hover:text-primary-500 transition-colors duration-300",fill:"currentColor"}),or("span",{className:"text-[11px] font-medium text-text-muted group-hover:text-text-main transition-colors duration-300 tracking-wide",children:["Powered by"," ",jt("strong",{className:"font-bold text-text-main/80 group-hover:text-text-main",children:"Boltdocs"})]})]})})}import*as Js from"lucide-react";import{jsx as me,jsxs as Zs}from"react/jsx-runtime";function nr(e){return e&&Js[e]||void 0}function Ys({group:e,activePath:t,getIcon:o}){let r=Ks(()=>e.routes.some(s=>s.path===t),[e.routes,t]),[n,a]=js(!0);return Xs(()=>{r&&a(!0)},[r]),me(ne.Group,{title:e.title,isOpen:n,onToggle:()=>a(!n),children:e.routes.map(s=>{let l=t===(s.path.endsWith("/")?s.path.slice(0,-1):s.path);return me(ne.Link,{label:s.title,href:s.path,active:l,icon:o(s.icon),badge:s.badge},s.path)})})}function Xt({routes:e,config:t}){let{groups:o,ungrouped:r,activePath:n}=Dt(e),a=t.theme||{};return Zs(ne.Root,{children:[r.length>0&&me(ne.Group,{className:"mb-6",children:r.map(s=>{let l=n===(s.path.endsWith("/")?s.path.slice(0,-1):s.path);return me(ne.Link,{label:s.title,href:s.path,active:l,icon:nr(s.icon),badge:s.badge},s.path)})}),o.map(s=>me(Ys,{group:s,activePath:n,getIcon:nr},s.slug)),a?.poweredBy&&me("div",{className:"mt-auto pt-8",children:me(rr,{})})]})}import Qs,{useRef as sr,useEffect as ea,useState as ta,useCallback as oa}from"react";import{Pencil as ra,CircleHelp as na,TextAlignStart as sa}from"lucide-react";import{jsx as A,jsxs as de}from"react/jsx-runtime";function Kt({headings:e=[],editLink:t,communityHelp:o,filePath:r}){let{headings:n}=$t(e),a=Qs.useMemo(()=>n.map(s=>({title:s.text,url:`#${s.id}`,depth:s.level})),[n]);return n.length===0?null:A(Ze,{toc:a,children:A(aa,{headings:n,editLink:t,communityHelp:o,filePath:r})})}function aa({headings:e,editLink:t,communityHelp:o,filePath:r}){let n=Je(),[a,s]=ta({opacity:0}),l=sr(null),i=sr(null);ea(()=>{if(!n||!l.current)return;let c=l.current.querySelector(`a[href="#${n}"]`);c&&s({transform:`translateY(${c.offsetTop}px)`,height:`${c.offsetHeight}px`,opacity:1})},[n]);let d=oa((c,m)=>{c.preventDefault();let p=document.getElementById(m);p&&(p.scrollIntoView({behavior:"smooth"}),window.history.pushState(null,"",`#${m}`))},[]);return de(j.Root,{children:[de(j.Header,{className:"flex flex-row gap-x-2",children:[A(sa,{size:16}),"On this page"]}),A(Ye,{containerRef:i,children:de(j.Content,{className:"max-h-[450px] boltdocs-otp-scroll-area",ref:i,children:[A(j.Indicator,{style:a}),A("ul",{className:"relative space-y-2 border-l border-border-subtle",ref:l,children:e.map(c=>A(j.Item,{level:c.level,children:A(j.Link,{href:`#${c.id}`,active:n===c.id,onClick:m=>d(m,c.id),className:"pl-4",children:c.text})},c.id))})]})}),(t||o)&&de("div",{className:"mt-8 pt-8 border-t border-border-subtle space-y-4",children:[A("p",{className:"text-xs font-bold uppercase tracking-wider text-text-main",children:"Need help?"}),de("ul",{className:"space-y-3",children:[t&&r&&A("li",{children:de("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:[A(ra,{size:16}),"Edit this page"]})}),o&&A("li",{children:de("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:[A(na,{size:16}),"Community help"]})})]})]})]})}import{useEffect as ia}from"react";import{useLocation as la}from"react-router-dom";function Jt({siteTitle:e,siteDescription:t,routes:o}){let r=la();return ia(()=>{let n=o.find(d=>d.path===r.pathname),a=n?.title,s=n?.description||t||"";document.title=a?`${a} | ${e}`:e;let l=document.querySelector('meta[name="description"]');l||(l=document.createElement("meta"),l.name="description",document.head.appendChild(l)),l.content=s,pe("property","og:title",document.title),pe("property","og:description",s),pe("property","og:type","article"),pe("property","og:url",window.location.href),pe("name","twitter:card","summary"),pe("name","twitter:title",document.title),pe("name","twitter:description",s);let i=document.querySelector('link[rel="canonical"]');i||(i=document.createElement("link"),i.rel="canonical",document.head.appendChild(i)),i.href=window.location.origin+r.pathname},[r.pathname,e,t,o]),null}function pe(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}import{Home as ca}from"lucide-react";import{jsx as Ee,jsxs as ar}from"react/jsx-runtime";function Yt(){let{crumbs:e,activeRoute:t}=Gt(),r=B().theme||{};return e.length===0||!r?.breadcrumbs?null:ar(X.Root,{children:[Ee(X.Item,{children:Ee(X.Link,{href:"/",children:Ee(ca,{size:14})})}),e.map((n,a)=>ar(X.Item,{children:[Ee(X.Separator,{}),Ee(X.Link,{href:n.href,className:u({"font-medium text-text-main":n.href===t?.path}),children:n.label})]},`crumb-${n.href}-${n.label}-${a}`))]})}import{jsx as Ae,jsxs as Zt}from"react/jsx-runtime";function Qt(){let{prevPage:e,nextPage:t}=_t();return!e&&!t?null:Zt(W.Root,{className:"animate-in fade-in slide-in-from-bottom-4 duration-700",children:[e?Zt(W.Link,{to:e.path,direction:"prev",children:[Ae(W.Title,{children:"Previous"}),Ae(W.Description,{children:e.title})]}):Ae("div",{}),t&&Zt(W.Link,{to:t.path,direction:"next",children:[Ae(W.Title,{children:"Next"}),Ae(W.Description,{children:t.title})]})]})}import{Component as ma}from"react";import{jsx as eo,jsxs as da}from"react/jsx-runtime";var Ve=class extends ma{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||da("div",{className:"flex flex-col items-center justify-center min-h-[40vh] text-center gap-4 px-4",children:[eo("div",{className:"text-lg font-bold text-red-400",children:"Something went wrong"}),eo("p",{className:"text-sm text-text-muted max-w-md",children:this.state.error?.message||"An unexpected error occurred while rendering this page."}),eo(V,{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}};import{useLocation as pa}from"react-router-dom";import{jsx as q,jsxs as Xe}from"react/jsx-runtime";function ua({children:e}){let{routes:t,allRoutes:o,currentRoute:r,currentLocale:n}=R(),{pathname:a}=pa(),s=B(),i=Te().CopyMarkdown||Ie,d=a==="/"||a==="";return Xe(ce,{children:[q(Jt,{siteTitle:Z(s.theme?.title,n)||"Boltdocs",siteDescription:Z(s.theme?.description,n)||"",routes:o}),q(qt,{}),Xe(ce.Body,{children:[!d&&q(Xt,{routes:t,config:s}),Xe(ce.Content,{children:[!d&&Xe(ce.ContentHeader,{children:[q(Yt,{}),q(i,{mdxRaw:r?._rawContent,route:r,config:s.theme?.copyMarkdown})]}),q(Ve,{children:e}),!d&&q(ce.ContentFooter,{children:q(Qt,{})})]}),!d&&q(Kt,{headings:r?.headings,editLink:s.theme?.editLink,communityHelp:s.theme?.communityHelp,filePath:r?.filePath})]})]})}export{D as Admonition,Ze as AnchorProvider,lt as Badge,Yt as Breadcrumbs,tt as Button,Qe as ButtonGroup,mt as Card,ct as Cards,ht as Caution,_ as CodeBlock,Et as ComponentPreview,It as ComponentProps,Ie as CopyMarkdown,ft as Danger,ua as DefaultLayout,ce as DocsLayout,Ve as ErrorBoundary,kt as Field,Lt as FileTree,Jt as Head,Mt as Image,bt as Important,gt as InfoBox,St as Link,vt as List,Vt as Loading,qt as Navbar,_e as NotFound,dt as Note,Kt as OnThisPage,Qt as PageNav,X as PrimitiveBreadcrumbs,V as PrimitiveButton,re as PrimitiveLink,C as PrimitiveMenu,cr as PrimitiveNavLink,mr as PrimitiveNavbar,dr as PrimitiveNavigationMenu,j as PrimitiveOnThisPage,W as PrimitivePageNav,gr as PrimitivePopover,ne as PrimitiveSidebar,T as PrimitiveSkeleton,We as PrimitiveTabs,Fe as PrimitiveTooltip,Ye as ScrollProvider,pr as SearchDialogPrimitive,Xt as Sidebar,st as Tab,wt as Table,at as Tabs,pt as Tip,it as Video,ut as Warning,u as cn,cs as createBoltdocsApp,Je as useActiveAnchor,fr as useActiveAnchors,Gt as useBreadcrumbs,B as useConfig,Wt as useI18n,ur as useItems,Ke as useLocalizedTo,Ut as useLocation,Te as useMdxComponents,Ot as useNavbar,$t as useOnThisPage,_t as usePageNav,R as useRoutes,br as useSearch,Dt as useSidebar,zt as useTabs,se as useTheme,Ft as useVersion};
|
|
1
|
+
import{A as mr,B as dr,C as pr,D as Je,E as ur,F as Ye,G as Ze,H as K,I as G,J as We,K as ne,L as J,M as Qe,N as fr,O as C,P as T,Q as gr,a as ir,b as to,c as B,d as oo,e as _,f as P,g as Ke,h as u,i as re,j as lr,k as ro,l as V,m as no,n as so,o as Ve,p as Oe,q as De,r as $e,s as ze,t as ue,u as fe,v as ge,w as be,x as Fe,y as cr,z as E}from"../chunk-ITFGVXPE.mjs";import je,{useEffect as Vt,useState as Wo,useMemo as _o}from"react";import es from"react-dom/client";import{BrowserRouter as ts,Routes as os,Route as le}from"react-router-dom";import{ArrowLeft as br}from"lucide-react";import{jsx as Ne,jsxs as ao}from"react/jsx-runtime";function _e(){return Ne("div",{className:"flex items-center justify-center min-h-[60vh] text-center",children:ao("div",{className:"space-y-4",children:[Ne("span",{className:"text-8xl font-black tracking-tighter text-primary-500/20",children:"404"}),Ne("h1",{className:"text-2xl font-bold text-text-main",children:"Page Not Found"}),Ne("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."}),ao(re,{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:[Ne(br,{size:16})," Go to Home"]})]})})}import{createContext as hr,use as xr,useEffect as io,useState as et}from"react";import{jsx as vr}from"react/jsx-runtime";var lo=hr(void 0);function co({children:e}){let[t,o]=et("system"),[r,n]=et("dark"),[a,s]=et(!1);io(()=>{s(!0);let i=localStorage.getItem("boltdocs-theme"),d=i==="light"||i==="dark"||i==="system"?i:"system";o(d);let c=window.matchMedia("(prefers-color-scheme: dark)");((g,b)=>{n(g==="system"?b?"dark":"light":g)})(d,c.matches);let p=g=>{n(b=>(localStorage.getItem("boltdocs-theme")||"system")==="system"?g.matches?"dark":"light":b)};return c.addEventListener("change",p),()=>c.removeEventListener("change",p)},[]),io(()=>{if(!a)return;let i=window.matchMedia("(prefers-color-scheme: dark)").matches,d=t==="system"?i?"dark":"light":t;n(d);let c=document.documentElement;d==="light"?(c.classList.add("theme-light"),c.dataset.theme="light"):(c.classList.remove("theme-light"),c.dataset.theme="dark")},[t,a]);let l=i=>{o(i),localStorage.setItem("boltdocs-theme",i)};return vr(lo.Provider,{value:{theme:t,resolvedTheme:r,setTheme:l},children:e})}function se(){let e=xr(lo);if(e===void 0)throw new Error("useTheme must be used within a ThemeProvider");return e}import Go from"virtual:boltdocs-layout";import{startTransition as yr}from"react";import{RouterProvider as Cr}from"react-aria-components";import{useNavigate as Rr,useHref as Pr}from"react-router-dom";import{jsx as Nr}from"react/jsx-runtime";function mo({children:e}){let t=Rr();return Nr(Cr,{navigate:(o,r)=>{yr(()=>{t(o,r)})},useHref:Pr,children:e})}import{useLayoutEffect as Tr}from"react";import{useLocation as Lr}from"react-router-dom";function po(){let{pathname:e,hash:t}=Lr();return Tr(()=>{let o=document.querySelector(".boltdocs-content")||window,r=()=>o===window?window.scrollY:o.scrollTop,n=(a,s="auto")=>{o===window?window.scrollTo({top:a,behavior:s}):o.scrollTo({top:a,behavior:s})};if(t){let a=t.replace("#",""),s=document.getElementById(a);if(s){let i=o===window?0:o.getBoundingClientRect().top,m=s.getBoundingClientRect().top-i-80+r();n(m,"smooth");return}}n(0)},[e,t]),null}import{Outlet as wr}from"react-router-dom";import kr from"virtual:boltdocs-layout";import{jsx as uo}from"react/jsx-runtime";function fo(){return uo(kr,{children:uo(wr,{})})}import{createContext as Sr,use as Mr}from"react";import{jsx as Ir}from"react/jsx-runtime";var go=Sr({});function Te(){return Mr(go)}function bo({components:e,children:t}){return Ir(go.Provider,{value:e,children:t})}import{jsx as Br}from"react/jsx-runtime";function ho({Component:e}){let t=Te();return Br(e,{components:t})}import{Link as Zn}from"lucide-react";var At={};ir(At,{Admonition:()=>z,Badge:()=>lt,Button:()=>tt,Card:()=>mt,Cards:()=>ct,Caution:()=>ht,CodeBlock:()=>U,ComponentPreview:()=>Et,ComponentProps:()=>It,CopyMarkdown:()=>Ie,Danger:()=>ft,Field:()=>kt,FileTree:()=>Lt,Image:()=>Mt,Important:()=>bt,InfoBox:()=>gt,Link:()=>St,List:()=>vt,Note:()=>dt,Tab:()=>st,Table:()=>wt,Tabs:()=>at,Tip:()=>pt,Video:()=>it,Warning:()=>ut});import{jsx as Er}from"react/jsx-runtime";var tt=({className:e,variant:t,size:o,rounded:r,iconSize:n,disabled:a,...s})=>Er(V,{className:u("group",ro({variant:t,size:o,rounded:r,iconSize:n,disabled:a,className:e})),...s});import*as Ge from"react-aria-components";import{Copy as Or,Check as Dr,File as $r}from"lucide-react";import{getParameters as xo}from"codesandbox/lib/api/define.js";function vo(e){let t=e.files||{},o=e.dependencies||{},r=e.devDependencies||{},n=e.title||"codesandbox-project",a=e.description||"Generic Sandbox",s={};for(let[l,i]of Object.entries(t)){let d=typeof i.content=="object"?JSON.stringify(i.content,null,2):i.content;s[l]={content:d,isBinary:i.isBinary??!1}}if(!s["package.json"]){let i=e.template==="vite"||!!r.vite||!!r["@vitejs/plugin-react"]?{dev:"vite",build:"vite build",preview:"vite preview"}:{start:"node index.js"};s["package.json"]={content:JSON.stringify({private:!0,name:n,description:a,type:"module",version:"1.0.0",scripts:e.scripts||i,dependencies:o,devDependencies:r},null,2),isBinary:!1}}return s}function Ar(e){let t=vo(e),o=xo({files:t}),r=new URLSearchParams({parameters:o,installDependencies:"true"});return e.entry&&r.set("file",`/${e.entry}`),{parameters:o,url:`https://codesandbox.io/api/v1/sandboxes/define?${r.toString()}`,options:e}}function yo(e){if(typeof window>"u")return Ar(e);let t=vo(e),o=xo({files:t}),r=e.entry||"src/App.tsx",n=document.createElement("form");n.method="POST",n.target="_blank",n.action="https://codesandbox.io/api/v1/sandboxes/define",n.style.display="none";let a=(l,i)=>{let d=document.createElement("input");d.type="hidden",d.name=l,d.value=i,n.appendChild(d)},s=new URLSearchParams({file:`/${r}`,eslint:"0",codemirror:"1",installDependencies:"true"});return a("query",s.toString()),a("parameters",o),document.body.appendChild(n),n.submit(),document.body.removeChild(n),{parameters:o,url:`https://codesandbox.io/api/v1/sandboxes/define?parameters=${o}`,options:e}}var Co=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 Ro,useEffect as Hr,useRef as Vr,useState as ot}from"react";function Po(e){let{title:t,sandbox:o}=e,[r,n]=ot(!1),[a,s]=ot(!1),[l,i]=ot(!1),d=Vr(null),c=B(),m=Ro(async()=>{let g=d.current?.textContent??"";Co(g),n(!0),setTimeout(()=>n(!1),2e3)},[]),p=Ro(()=>{let g=d.current?.textContent??"",b=c?.integrations?.sandbox?.config||{},f=typeof o=="object"?o:b,h=f.entry||"src/App.tsx";yo({title:t??"Code Snippet",...f,files:{...f.files,[h]:{content:g}}})},[t,c,o]);return Hr(()=>{let g=d.current?.textContent?.length??0;i(g>120)},[e.children,e.highlightedHtml]),{copied:r,isExpanded:a,setIsExpanded:s,isExpandable:l,preRef:d,handleCopy:m,handleSandbox:p,shouldTruncate:l&&!a}}import{jsx as M,jsxs as rt}from"react/jsx-runtime";var zr={ts:Ve,tsx:ue,js:Oe,jsx:ue,json:De,css:$e,html:ze,md:fe,mdx:fe,bash:ge,sh:ge,yaml:be,yml:be};function U(e){let{children:t,sandbox:o,hideSandbox:r=!0,hideCopy:n=!1,highlightedHtml:a,"data-highlighted-html":s,title:l,"data-lang":i,plain:d=!1,...c}=e,m=a||s,b=!!B()?.integrations?.sandbox?.enable&&!r,f=e.lang||i||"",{copied:h,isExpanded:R,setIsExpanded:x,isExpandable:O,preRef:H,handleCopy:I,handleSandbox:Pe,shouldTruncate:D}=Po(e),$=zr[f];return rt("div",{className:u("group relative overflow-hidden bg-(--color-code-bg)","contain-layout contain-paint",{"my-6 rounded-lg border border-border-subtle":!d,"[&>pre]:max-h-62.5 [&>pre]:overflow-hidden":D},e.className),children:[l&&rt("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:[$?M($,{size:14}):M($r,{size:14,className:"opacity-60"}),M("span",{children:l})]}),rt("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:[b&&M(Fe,{content:"Open in CodeSandbox",children:M(Ge.Button,{onPress:Pe,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:M(so,{size:20})})}),!n&&M(Fe,{content:h?"Copied!":"Copy code",children:M(Ge.Button,{onPress:I,className:u("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",h?"text-emerald-400":"text-text-muted hover:text-text-main"),"aria-label":"Copy code",children:h?M(Dr,{size:20}):M(Or,{size:20})})})]}),m?M("div",{ref:H,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:m}}):M("pre",{ref:H,className:"m-0! rounded-none! border-none! bg-inherit! font-mono text-[0.8125rem] leading-[1.7]",...c,children:t}),O&&M("div",{className:u(D?"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:M(Ge.Button,{onPress:()=>x(!R),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:R?"Show less":"Expand code"})})]})}import{Children as Gr,isValidElement as Ur,useMemo as qr}from"react";import*as Z from"react-aria-components";import{useState as No,useRef as Fr,useEffect as Wr,useCallback as _r}from"react";function To({initialIndex:e=0,tabs:t}){let o=t[e]?.props.disabled?t.findIndex(d=>!d.props.disabled):e,[r,n]=No(o===-1?0:o),a=Fr([]),[s,l]=No({opacity:0,transform:"translateX(0)",width:0});Wr(()=>{let d=a.current[r];d&&l({opacity:1,width:d.offsetWidth,transform:`translateX(${d.offsetLeft}px)`})},[r,t]);let i=_r(d=>{let c=0;if(d.key==="ArrowRight"?c=1:d.key==="ArrowLeft"&&(c=-1),c!==0){let m=(r+c+t.length)%t.length;for(;t[m].props.disabled&&m!==r;)m=(m+c+t.length)%t.length;m!==r&&!t[m].props.disabled&&(n(m),a.current[m]?.focus())}},[r,t]);return{active:r,setActive:n,tabRefs:a,indicatorStyle:s,handleKeyDown:i}}import{cva as Lo}from"class-variance-authority";import{jsx as Y,jsxs as nt}from"react/jsx-runtime";var jr=Lo("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"}}),Xr=Lo("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 st({children:e}){let t=typeof e=="string"?Y(U,{className:"language-bash",children:Y("code",{children:e.trim()})}):e;return Y("div",{className:"py-4",children:t})}function at({defaultIndex:e=0,children:t}){let o=qr(()=>Gr.toArray(t).filter(l=>Ur(l)&&l.props?.label),[t]),{active:r,setActive:n,tabRefs:a,indicatorStyle:s}=To({initialIndex:e,tabs:o});return Y("div",{className:"my-8 w-full group/tabs",children:nt(Z.Tabs,{selectedKey:r.toString(),onSelectionChange:l=>n(Number(l)),className:"w-full",children:[nt(Z.TabList,{"aria-label":"Content Tabs",className:u(jr()),children:[o.map((l,i)=>{let{label:d,icon:c,disabled:m}=l.props,p=i.toString();return nt(Z.Tab,{id:p,isDisabled:m,ref:g=>{a.current[i]=g},className:({isSelected:g,isDisabled:b})=>u(Xr({isActive:g,isDisabled:b})),children:[!!c&&Y("span",{className:"shrink-0 [&>svg]:w-4 [&>svg]:h-4",children:c}),Y("span",{children:d})]},p)}),Y("div",{className:"absolute bottom-0 h-0.5 bg-primary-500 transition-all duration-300 ease-in-out pointer-events-none",style:s,"aria-hidden":"true"})]}),o.map((l,i)=>Y(Z.TabPanel,{id:i.toString(),children:o[i]},i))]})})}import{useRef as Kr,useState as Jr,useEffect as Yr}from"react";import{jsx as wo,jsxs as Zr}from"react/jsx-runtime";function it({src:e,poster:t,alt:o,children:r,controls:n,preload:a="metadata",...s}){let l=Kr(null),[i,d]=Jr(!1);return Yr(()=>{let c=l.current;if(!c)return;let m=new IntersectionObserver(([p])=>{p.isIntersecting&&(d(!0),m.disconnect())},{rootMargin:"200px"});return m.observe(c),()=>m.disconnect()},[]),wo("div",{ref:l,className:"my-6 overflow-hidden rounded-lg border border-border-subtle",children:i?Zr("video",{className:"block w-full h-auto",src:e,poster:t,controls:!0,preload:a,playsInline:!0,...s,children:[r,"Your browser does not support the video tag."]}):wo("div",{className:"aspect-video bg-bg-surface animate-pulse",role:"img","aria-label":o||"Video"})})}import{cva as Qr}from"class-variance-authority";import{jsx as tn}from"react/jsx-runtime";var en=Qr("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 lt({variant:e="default",children:t,className:o="",...r}){return tn("span",{className:u(en({variant:e}),o),...r,children:t})}import{useCallback as on,useRef as ko}from"react";import*as Mo from"react-aria-components";import{cva as rn}from"class-variance-authority";import{Fragment as sn,jsx as ae,jsxs as So}from"react/jsx-runtime";var nn=rn("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 ct({cols:e=3,children:t,className:o="",...r}){return ae("div",{className:u(nn({cols:e}),o),...r,children:t})}function mt({title:e,icon:t,href:o,children:r,className:n="",...a}){let s=ko(null),l=ko(null),i=on(m=>{let p=s.current||l.current;if(!p)return;let{left:g,top:b}=p.getBoundingClientRect();p.style.setProperty("--x",`${m.clientX-g}px`),p.style.setProperty("--y",`${m.clientY-b}px`)},[]),d=So(sn,{children:[ae("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&&ae("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}),So("div",{className:"space-y-1.5",children:[e&&ae("h3",{className:"text-sm font-bold text-text-main",children:e}),r&&ae("div",{className:"text-sm text-text-muted leading-relaxed",children:r})]})]}),c=u("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 o?ae(Mo.Link,{ref:l,href:o,className:u(c,"no-underline cursor-pointer"),onMouseMove:i,...a,children:d}):ae("div",{ref:s,role:"presentation",className:c,onMouseMove:i,...a,children:d})}import{Info as an,Lightbulb as ln,AlertTriangle as cn,ShieldAlert as mn,Bookmark as dn,Zap as pn,Flame as un}from"lucide-react";import{cva as fn}from"class-variance-authority";import{jsx as L,jsxs as Bo}from"react/jsx-runtime";var gn={note:L(dn,{size:18}),tip:L(ln,{size:18}),info:L(an,{size:18}),warning:L(cn,{size:18}),danger:L(mn,{size:18}),important:L(un,{size:18}),caution:L(pn,{size:18})},bn={note:"Note",tip:"Tip",info:"Info",warning:"Warning",danger:"Danger",important:"Important",caution:"Caution"},Io=fn("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 z({type:e="note",title:t,children:o,className:r="",...n}){return Bo("div",{className:u(Io({type:e}),r),role:e==="warning"||e==="danger"?"alert":"note",...n,children:[Bo("div",{className:"flex items-center flex-row gap-2 mb-2",children:[L("span",{className:u("shrink-0",Io({type:e})),children:gn[e]}),L("span",{className:"text-sm font-bold tracking-tight text-text-main",children:t||bn[e]})]}),L("div",{className:"text-sm text-text-muted leading-relaxed [&>p]:m-0 [&>p]:mb-2 [&>p:last-child]:mb-0",children:o})]})}var dt=e=>L(z,{type:"note",...e}),pt=e=>L(z,{type:"tip",...e}),ut=e=>L(z,{type:"warning",...e}),ft=e=>L(z,{type:"danger",...e}),gt=e=>L(z,{type:"info",...e}),bt=e=>L(z,{type:"important",...e}),ht=e=>L(z,{type:"caution",...e});import{Children as hn,isValidElement as xn}from"react";import{Check as vn,ChevronRight as yn,Circle as Cn}from"lucide-react";import{cva as xt}from"class-variance-authority";import{jsx as Q,jsxs as wn}from"react/jsx-runtime";var Rn=xt("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}}),Pn=xt("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}}),Nn=xt("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 Tn({icon:e,children:t,variant:o,dense:r}){return wn("li",{className:u(Pn({variant:o,dense:r})),children:[e&&Q("span",{className:u(Nn({variant:o==="bubble"?"bubble":"default"})),children:e}),Q("div",{className:"flex-1 text-text-muted group-hover:text-text-main transition-colors",children:t})]})}var Ln={checked:e=>Q(vn,{size:14,className:u("text-emerald-500 shrink-0",e)}),arrow:e=>Q(yn,{size:14,className:u("text-primary-400 shrink-0",e)}),bubble:e=>Q(Cn,{size:6,fill:"currentColor",className:u("text-primary-500 shrink-0",e)}),default:()=>null,number:()=>null};function vt({variant:e="default",cols:t=1,dense:o=!1,children:r,className:n,...a}){let s=t!==void 0&&Number(t)>1,l=Ln[e],i=Rn({variant:e,cols:t,dense:o,isGrid:s,className:n}),d=e==="number"?"ol":"ul";return e==="default"||e==="number"?Q(d,{className:i,...a,children:r}):Q("ul",{className:i,...a,children:hn.map(r,c=>{if(!xn(c))return c;let m=c,p=m.type==="li"?m.props.children:m.props.children||c;return Q(Tn,{icon:l(),variant:e,dense:o,children:p})})})}import{Children as yt,isValidElement as Tt,useMemo as kn}from"react";import*as F from"react-aria-components";import{Folder as Sn,FileText as Mn,File as In,FileCode as Bn,FileImage as En,ChevronRight as An}from"lucide-react";import{jsx as w,jsxs as Pt}from"react/jsx-runtime";var he=16,Le=2,Hn={ts:Ve,tsx:ue,js:Oe,jsx:ue,json:De,css:$e,html:ze,md:fe,mdx:fe,bash:ge,sh:ge,yaml:be,yml:be},Ct={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 Nt(e){return typeof e=="string"?e:typeof e=="number"?e.toString():Array.isArray(e)?e.map(Nt).join(""):Tt(e)&&e.props&&typeof e.props=="object"&&"children"in e.props?Nt(e.props.children):""}function Vn(e,t){let o=e.toLowerCase(),r="shrink-0 transition-colors duration-200";if(t)return w(Sn,{size:he,strokeWidth:Le,className:u(r,"text-primary-400"),fill:"currentColor",fillOpacity:.15});let n=o.split(".").pop()||"",a=Hn[n];if(a)return w(a,{size:he});let s=u(r,"text-text-dim group-hover:text-text-main");return Ct.CODE.test(o)?w(Bn,{size:he,strokeWidth:Le,className:s}):Ct.TEXT.test(o)?w(Mn,{size:he,strokeWidth:Le,className:s}):Ct.IMAGE.test(o)?w(En,{size:he,strokeWidth:Le,className:s}):w(In,{size:he,strokeWidth:Le,className:s})}function Rt(e,t){if(!Tt(e))return!1;let o=e.type;if(typeof o=="string")return o===t;if(typeof o=="function")return o.name===t||o.name?.toLowerCase()===t;let r=e.props;return r?.originalType===t||r?.mdxType===t}function On(e){let t=e.match(/\s+(\/\/|#)\s+(.*)$/);return t?{name:e.slice(0,t.index).trim(),comment:t[2]}:{name:e.trim()}}function Ue(e,t="root"){if(!Tt(e))return[];let o=[];if(Rt(e,"ul"))return yt.forEach(e.props.children,(r,n)=>{o.push(...Ue(r,`${t}-${n}`))}),o;if(Rt(e,"li")){let r=yt.toArray(e.props.children),n=r.findIndex(b=>Rt(b,"ul")),a=n!==-1,s=a?r.slice(0,n):r,l=a?r.slice(n):[],i=Nt(s),{name:d,comment:c}=On(i),m=d.endsWith("/"),p=m?d.slice(0,-1):d,g=a||m;return o.push({id:`${t}-${p}`,name:p,comment:c,isFolder:g,children:a?Ue(l[0],`${t}-${p}`):void 0}),o}return e.props&&typeof e.props=="object"&&"children"in e.props&&yt.forEach(e.props.children,(r,n)=>{o.push(...Ue(r,`${t}-${n}`))}),o}function Eo({item:e}){return Pt(F.TreeItem,{id:e.id,textValue:e.name,className:"outline-none group focus-visible:ring-2 focus-visible:ring-primary-500/30 rounded-md",children:[w(F.TreeItemContent,{children:({isExpanded:t,hasChildItems:o})=>Pt("div",{className:"flex items-center gap-2 py-1 px-1.5 rounded-md transition-colors hover:bg-primary-500/5 cursor-pointer",children:[w("div",{style:{width:"calc((var(--tree-item-level) - 1) * 1rem)"},className:"shrink-0"}),o?w(F.Button,{slot:"chevron",className:"outline-none text-text-dim hover:text-primary-400 p-0.5 rounded transition-colors",children:w(An,{size:14,strokeWidth:3,className:u("transition-transform duration-200",t&&"rotate-90")})}):w("div",{className:"w-[18px]"}),Vn(e.name,e.isFolder),w("span",{className:u("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&&Pt("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&&w(F.Collection,{items:e.children,children:t=>w(Eo,{item:t})})]})}function Lt({children:e}){let t=kn(()=>Ue(e),[e]);return w("div",{className:"my-8",children:w(F.Tree,{items:t,"aria-label":"File Tree",className:u("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:o=>w(Eo,{item:o})})})}import*as we from"react-aria-components";import{useState as Ao,useMemo as Ho}from"react";function Vo({data:e,sortable:t=!1,paginated:o=!1,pageSize:r=10}){let[n,a]=Ao(null),[s,l]=Ao(1),i=Ho(()=>{if(!e)return[];let p=[...e];return t&&n!==null&&p.sort((g,b)=>{let f=g[n.key],h=b[n.key],R=typeof f=="string"?f:"",x=typeof h=="string"?h:"";return R<x?n.direction==="asc"?-1:1:R>x?n.direction==="asc"?1:-1:0}),p},[e,n,t]),d=Math.ceil(i.length/r),c=Ho(()=>{if(!o)return i;let p=(s-1)*r;return i.slice(p,p+r)},[i,o,s,r]);return{sortConfig:n,currentPage:s,setCurrentPage:l,totalPages:d,paginatedData:c,requestSort:p=>{if(!t)return;let g="asc";n&&n.key===p&&n.direction==="asc"&&(g="desc"),a({key:p,direction:g})}}}import{ChevronUp as Dn,ChevronDown as Oo,ChevronLeft as $n,ChevronRight as zn,ChevronsLeft as Fn,ChevronsRight as Wn}from"lucide-react";import{Fragment as _n,jsx as N,jsxs as xe}from"react/jsx-runtime";function wt({headers:e,data:t,children:o,className:r="",sortable:n=!1,paginated:a=!1,pageSize:s=10}){let{sortConfig:l,currentPage:i,setCurrentPage:d,totalPages:c,paginatedData:m,requestSort:p}=Vo({data:t,sortable:n,paginated:a,pageSize:s}),g=f=>n?l?.key!==f?N(Oo,{size:14,className:"ml-1 opacity-30"}):l.direction==="asc"?N(Dn,{size:14,className:"ml-1 text-primary-400"}):N(Oo,{size:14,className:"ml-1 text-primary-400"}):null,b=o||xe(_n,{children:[e&&N("thead",{children:N("tr",{children:e.map((f,h)=>N("th",{onClick:()=>p(h),className:u("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:xe("div",{className:"flex items-center",children:[f,g(h)]})},h))})}),m&&N("tbody",{children:m.map((f,h)=>N("tr",{className:"transition-colors hover:bg-bg-surface",children:f.map((R,x)=>N("td",{className:"px-3 py-2 border-b border-border-subtle text-sm text-text-muted",children:R},x))},h))})]});return xe("div",{className:u("my-6 rounded-lg border border-border-subtle overflow-hidden",r),children:[N("div",{className:"overflow-x-auto",children:N("table",{className:"w-full border-collapse text-sm",children:b})}),a&&c>1&&xe("div",{className:"flex items-center justify-between border-t border-border-subtle px-4 py-3",children:[xe("span",{className:"text-xs text-text-muted",children:["Page ",i," of ",c]}),xe("div",{className:"flex items-center gap-1",children:[N(we.Button,{onPress:()=>d(1),isDisabled:i===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:N(Fn,{size:16})}),N(we.Button,{onPress:()=>d(f=>Math.max(f-1,1)),isDisabled:i===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:N($n,{size:16})}),N(we.Button,{onPress:()=>d(f=>Math.min(f+1,c)),isDisabled:i===c,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:N(zn,{size:16})}),N(we.Button,{onPress:()=>d(c),isDisabled:i===c,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:N(Wn,{size:16})})]})]})]})}import{jsx as ve,jsxs as ke}from"react/jsx-runtime";function kt({name:e,type:t,defaultValue:o,required:r=!1,children:n,id:a,className:s=""}){return ke("article",{className:u("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",s),id:a,children:[ke("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between mb-4",children:[ke("div",{className:"flex flex-wrap items-center gap-2.5",children:[ve("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&&ve("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}),r&&ke("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:[ve("span",{className:"h-1 w-1 rounded-full bg-red-400 animate-pulse"}),"Required"]})]}),o&&ke("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:[ve("span",{className:"font-semibold opacity-60 uppercase tracking-tighter",children:"Default"}),ve("code",{className:"font-mono text-text-main font-medium",children:o})]})]}),ve("div",{className:"text-sm text-text-muted leading-relaxed [&>p]:m-0 selection:bg-primary-500/30",children:n})]})}import{jsx as Gn}from"react/jsx-runtime";function St({to:e,children:t,className:o="",...r}){let n=e&&(e.startsWith("http://")||e.startsWith("https://")||e.startsWith("//")),a=u("text-blue-600 hover:text-blue-800 hover:underline cursor-pointer",o);return Gn(re,{href:e,className:a,target:n?"_blank":void 0,rel:n?"noopener noreferrer":void 0,...r,children:t})}import{jsx as Un}from"react/jsx-runtime";function Mt({src:e,alt:t,theme:o,...r}){let{theme:n}=se();return o&&o!==n?null:Un("img",{src:e,alt:t||"",...r})}import{jsx as k,jsxs as Se}from"react/jsx-runtime";function It({title:e,props:t,className:o=""}){return Se("div",{className:u("my-6",o),children:[e&&k("h3",{className:"text-base font-bold text-text-main mb-3",children:e}),k("div",{className:"overflow-x-auto rounded-lg border border-border-subtle",children:Se("table",{className:"w-full border-collapse text-sm",children:[k("thead",{children:Se("tr",{children:[k("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"}),k("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"}),k("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"}),k("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"})]})}),k("tbody",{children:t.map((r,n)=>Se("tr",{className:"transition-colors hover:bg-bg-surface",children:[Se("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:[k("code",{className:"rounded bg-bg-surface px-1.5 py-0.5 font-mono text-xs font-bold text-primary-400",children:r.name}),r.required&&k("span",{className:"ml-1 text-red-400 font-bold",children:"*"})]}),k("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:k("code",{className:"rounded bg-bg-muted px-1.5 py-0.5 font-mono text-xs text-text-muted",children:r.type})}),k("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:r.defaultValue?k("code",{className:"rounded bg-bg-muted px-1.5 py-0.5 font-mono text-xs text-primary-400",children:r.defaultValue}):k("span",{className:"text-text-dim",children:"\u2014"})}),k("td",{className:"px-4 py-2.5 border-b border-border-subtle text-text-muted",children:r.description})]},`${r.name}-${n}`))})]})})]})}import{useMemo as Do}from"react";function $o(e){let{code:t,children:o,preview:r}=e,n=Do(()=>(t??(typeof o=="string"?o:"")).trim(),[t,o]),a=Do(()=>r??(typeof o!="string"?o:null),[r,o]);return{initialCode:n,previewElement:a}}import{jsx as Bt,jsxs as qn}from"react/jsx-runtime";function Et(e){let{highlightedHtml:t,hideCode:o=!1,hideSandbox:r=!1,hideCopy:n=!1,sandboxOptions:a={}}=e,{initialCode:s,previewElement:l}=$o(e);return qn("div",{className:"my-6 overflow-hidden rounded-xl border border-border-subtle",children:[Bt("div",{className:"flex items-center justify-center p-8 bg-bg-surface",children:l}),!o&&Bt("div",{className:"border-t border-border-subtle",children:Bt(U,{hideSandbox:r,hideCopy:n,title:a.title,lang:"tsx",highlightedHtml:t,plain:!0,children:s})})]})}import{useState as jn}from"react";import{Copy as zo,Check as Xn,ExternalLink as Kn,ChevronDown as Jn}from"lucide-react";import{jsx as W,jsxs as Me}from"react/jsx-runtime";var Yn=e=>{let[t,o]=jn(!1);return{copied:t,handleCopy:()=>{navigator.clipboard.writeText(e),o(!0),setTimeout(()=>o(!1),2e3)},handleOpenRaw:()=>{let a=new Blob([e],{type:"text/plain;charset=utf-8"}),s=URL.createObjectURL(a);window.open(s,"_blank")}}};function Ie({content:e,mdxRaw:t,config:o}){let r=t||e||"",{copied:n,handleCopy:a,handleOpenRaw:s}=Yn(r),l=o!==!1,i=typeof o=="object"&&o.text||"Copy Markdown";return!l||!r?null:W("div",{className:"relative inline-flex z-100 flex-shrink-0 w-max translate-y-0 active:translate-y-px transition-transform duration-200",children:Me(Qe,{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:[W(V,{variant:"ghost",onPress:a,icon:n?W(Xn,{size:16}):W(zo,{size:16}),iconPosition:"left",className:u("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!":i}),Me(C.Trigger,{placement:"bottom end",children:[W(V,{variant:"ghost",isIconOnly:!0,icon:W(Jn,{size:14}),className:u("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")}),Me(C.Root,{className:"w-52",children:[Me(C.Item,{onAction:a,children:[W(zo,{size:16,className:"size-4 mt-0.5 text-text-muted group-hover:text-primary-500"}),W("span",{className:"font-medium text-[0.8125rem]",children:"Copy Markdown"})]}),Me(C.Item,{onAction:s,children:[W(Kn,{size:16,className:"size-4 mt-0.5 text-text-muted group-hover:text-primary-500"}),W("span",{className:"font-medium text-[0.8125rem]",children:"View as Markdown"})]})]})]})]})})}import{jsx as S,jsxs as ie}from"react/jsx-runtime";function Ht(){return S("div",{className:u("w-full h-full relative overflow-y-auto transition-opacity duration-300 animate-fade-in"),children:ie("div",{className:"mx-auto max-w-(--spacing-content-max) px-4 py-8 space-y-10",children:[ie("div",{className:"flex gap-2",children:[S(T,{className:"h-3 w-16"}),S(T,{className:"h-3 w-24"})]}),S(T,{className:"h-10 w-[60%] sm:h-12"}),ie("div",{className:"space-y-3",children:[S(T,{className:"h-4 w-full"}),S(T,{className:"h-4 w-[95%]"}),S(T,{className:"h-4 w-[40%]"})]}),ie("div",{className:"space-y-6 pt-4",children:[S(T,{className:"h-7 w-32"}),ie("div",{className:"space-y-3",children:[S(T,{className:"h-4 w-full"}),S(T,{className:"h-4 w-[98%]"}),S(T,{className:"h-4 w-[92%]"}),S(T,{className:"h-4 w-[60%]"})]})]}),S(T,{className:"h-32 w-full rounded-lg bg-bg-muted/50"}),ie("div",{className:"space-y-6 pt-4",children:[S(T,{className:"h-7 w-48"}),ie("div",{className:"space-y-3",children:[S(T,{className:"h-4 w-full"}),S(T,{className:"h-4 w-[85%]"})]})]})]})})}import{jsx as q,jsxs as Qn}from"react/jsx-runtime";var ye=({level:e,id:t,children:o,...r})=>{let n=`h${e}`;return Qn(n,{id:t,...r,className:"boltdocs-heading",children:[o,t&&q("a",{href:`#${t}`,className:"header-anchor","aria-label":"Anchor",children:q(Zn,{size:16})})]})},Fo={...At,Loading:Ht,h1:e=>q(ye,{level:1,...e}),h2:e=>q(ye,{level:2,...e}),h3:e=>q(ye,{level:3,...e}),h4:e=>q(ye,{level:4,...e}),h5:e=>q(ye,{level:5,...e}),h6:e=>q(ye,{level:6,...e}),pre:e=>q(U,{...e,children:e.children})};import rs from"virtual:boltdocs-mdx-components";import{useLocation as ns}from"react-router-dom";import{Fragment as cs,jsx as y,jsxs as qe}from"react/jsx-runtime";function ss(){let{currentLocale:e,config:t}=P();return Vt(()=>{if(!t.i18n)return;let o=t.i18n.localeConfigs?.[e];document.documentElement.lang=o?.htmlLang||e||"en",document.documentElement.dir=o?.direction||"ltr"},[e,t.i18n]),null}function as(){let e=ns(),{config:t}=P(),o=_(s=>s.setLocale),r=_(s=>s.setVersion),n=_(s=>s.currentLocale),a=_(s=>s.currentVersion);return Vt(()=>{let s=e.pathname.split("/").filter(Boolean),l=0,i=t.versions?.defaultVersion,d=t.i18n?.defaultLocale;if(s[l]==="docs"&&l++,t.versions&&s.length>l){let c=t.versions.versions.find(m=>m.path===s[l]);c&&(i=c.path,l++)}t.i18n&&s.length>l&&t.i18n.locales[s[l]]?d=s[l]:t.i18n&&s.length===0&&(d=n||t.i18n.defaultLocale),d!==n&&o(d),i!==a&&r(i)},[e.pathname,t,o,r,n,a]),null}function is({initialRoutes:e,initialConfig:t,docsDirName:o,modules:r,hot:n,homePage:a,externalPages:s,externalLayout:l,components:i={}}){let[d,c]=Wo(e),[m,p]=Wo(t),g=s||{},b=l||Go,f=_o(()=>d.filter(x=>!(a&&(x.path==="/"||x.path===""))&&!g[x.path===""?"/":x.path]).map(x=>{let O=Object.keys(r).find(I=>I===`/${o}/${x.filePath}`||I.endsWith(`/${o}/${x.filePath}`)||I.endsWith(`/${o}\\${x.filePath.replace(/\\/g,"/")}`)),H=O?r[O]:null;return{...x,Component:je.lazy(async()=>H?await H():{default:_e})}}),[d,r,o,a,g]);Vt(()=>{n&&(n.on("boltdocs:routes-update",x=>{c(x)}),n.on("boltdocs:config-update",x=>{p(x)}))},[n]);let h=_o(()=>({...Fo,...rs,...i}),[i]),R=h.Loading;return y(co,{children:y(bo,{components:h,children:y(to.Provider,{value:m,children:y(mo,{children:qe(oo,{routes:d,modules:r,children:[y(po,{}),y(as,{}),y(ss,{}),qe(os,{children:[y(le,{element:y(fo,{}),children:f.map(x=>y(le,{path:x.path===""?"/":x.path,element:y(je.Suspense,{fallback:y(R,{}),children:y(ho,{Component:x.Component})})},x.path))},"docs-layout"),a&&qe(cs,{children:[y(le,{path:"/",element:y(b,{children:y(a,{})})}),m.i18n&&Object.keys(m.i18n.locales).map(x=>y(le,{path:`/${x}`,element:y(b,{children:y(a,{})})},`home-${x}`))]}),Object.entries(g).map(([x,O])=>{let H=x==="/"?"":x;return qe(je.Fragment,{children:[y(le,{path:x,element:y(b,{children:y(O,{})})}),m.i18n&&Object.keys(m.i18n.locales).map(I=>y(le,{path:`/${I}${H}`,element:y(b,{children:y(O,{})})},`${x}-${I}`))]},x)}),y(le,{path:"*",element:y(Go,{children:y(_e,{})})})]})]})})})})})}function ls(e){let{target:t,routes:o,docsDirName:r,config:n,modules:a,hot:s,homePage:l,externalPages:i,externalLayout:d,components:c}=e,m=document.querySelector(t);if(!m)throw new Error(`[boltdocs] Mount target "${t}" not found in document.`);let p=y(je.StrictMode,{children:y(ts,{children:y(is,{initialRoutes:o,initialConfig:n,docsDirName:r,modules:a,hot:s,homePage:l,externalPages:i,externalLayout:d,components:c})})});m.innerHTML="",es.createRoot(m).render(p)}import{useLocation as ms}from"react-router-dom";function ee(e,t){return e?typeof e=="string"?e:t&&e[t]?e[t]:Object.values(e)[0]||"":""}function Ot(){let e=B(),{theme:t}=se(),o=ms(),{currentLocale:r}=P(),n=e.theme||{},a=ee(n.title,r)||"Boltdocs",s=n.navbar||[],l=n.socialLinks||[],i=n.githubRepo,d=s.map(b=>{let f=b.href||b.to||b.link||"",h=R=>{let x=o.pathname;if(x===R)return!0;if(!R||R==="/")return x==="/";let O=Pe=>{let D=Pe.split("/").filter(Boolean),$=0;return e.i18n?.locales&&D[$]&&e.i18n.locales[D[$]]&&$++,e.versions?.versions&&D[$]&&e.versions.versions.some(ar=>ar.path===D[$])&&$++,D.slice($)},H=O(R),I=O(x);return H.length===0?I.length===0:I.length<H.length?!1:H.every((Pe,D)=>I[D]===Pe)};return{label:ee(b.label||b.text,r),href:f,active:h(f),to:f.startsWith("http")||f.startsWith("//")?"external":void 0}}),c=n.logo,m=c?typeof c=="string"?c:t==="dark"?c.dark:c.light:null,p={alt:(c&&typeof c=="object"?c.alt:void 0)||a,width:c&&typeof c=="object"?c.width:void 0,height:c&&typeof c=="object"?c.height:void 0},g=i?`https://github.com/${i}`:null;return{links:d,title:a,logo:m,logoProps:p,github:g,social:l,config:e,theme:t}}import{useLocation as ds}from"react-router-dom";function Dt(e){let t=B(),o=ds(),r=m=>m.endsWith("/")&&m.length>1?m.slice(0,-1):m,n=r(o.pathname),a=e.find(m=>r(m.path)===n),s=a?.tab?.toLowerCase(),l=s?e.filter(m=>!m.tab||m.tab.toLowerCase()===s):e,i=[],d=new Map;for(let m of l)m.group?(d.has(m.group)||d.set(m.group,{slug:m.group,title:m.groupTitle||m.group,routes:[],icon:m.groupIcon}),d.get(m.group).routes.push(m)):i.push(m);return{groups:Array.from(d.values()),ungrouped:i,activeRoute:a,activePath:n,config:t}}import{useState as ps}from"react";function $t(e=[]){let[t,o]=ps(null);return{headings:e,activeId:t,setActiveId:o}}import{useLocation as us}from"react-router-dom";import{useEffect as fs,useState as gs,useRef as bs}from"react";function zt(e=[],t=[]){let o=us(),r=bs([]),[n,a]=gs({opacity:0,transform:"translateX(0) scaleX(0)",width:0}),l=t.find(c=>c.path===o.pathname)?.tab?.toLowerCase(),i=e.findIndex(c=>c.id.toLowerCase()===l),d=i===-1?0:i;return fs(()=>{let c=r.current[d];c&&a({opacity:1,width:c.offsetWidth,transform:`translateX(${c.offsetLeft}px)`})},[d,e.length,o.pathname]),{tabs:e,activeIndex:d,indicatorStyle:n,tabRefs:r,activeTabId:l}}import{useNavigate as hs}from"react-router-dom";function te(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}function Ft(){let e=hs(),t=P(),{allRoutes:o,currentRoute:r,currentVersion:n,currentLocale:a,config:s}=t,l=s.versions,i=_(m=>m.setVersion),d=m=>{if(!l||m===n)return;i(m);let p=`/docs/${m}`;if(r){let g=te(r.filePath,r.version,r.locale),b=o.find(f=>te(f.filePath,f.version,f.locale)===g&&(f.version||l.defaultVersion)===m&&(a?f.locale===a:!f.locale));if(b)p=b.path;else{let f=o.find(h=>te(h.filePath,h.version,h.locale)==="index.md"&&(h.version||l.defaultVersion)===m&&(a?h.locale===a:!h.locale));p=f?f.path:`/docs/${m}${a?`/${a}`:""}`}}e(p)},c=t.availableVersions.map(m=>({...m,label:m.label,value:m.key}));return{currentVersion:n,currentVersionLabel:t.currentVersionLabel,availableVersions:c,handleVersionChange:d}}import{useNavigate as xs}from"react-router-dom";function Wt(){let e=xs(),t=P(),{allRoutes:o,currentRoute:r,currentLocale:n,config:a}=t,s=a.i18n,l=_(p=>p.setLocale),i=p=>{if(!s||p===n)return;l(p);let g="/";if(r){let b=te(r.filePath,r.version,r.locale),f=o.find(h=>te(h.filePath,h.version,h.locale)===b&&(h.locale||s.defaultLocale)===p&&h.version===r.version);if(f)g=f.path;else{let h=o.find(R=>te(R.filePath,R.version,R.locale)==="index.md"&&(R.locale||s.defaultLocale)===p&&R.version===r.version);g=h?h.path:p===s.defaultLocale?r.version?`/${r.version}`:"/":r.version?`/${r.version}/${p}`:`/${p}`}}else{let b=o.find(f=>(f.filePath==="index.mdx"||f.filePath==="index.md")&&(f.locale||s.defaultLocale)===p&&!f.version);b?g=b.path:g=p===s.defaultLocale?"/":`/${p}`}e(g)},c=a.i18n?.localeConfigs?.[n]?.label||a.i18n?.locales[n]||n,m=a.i18n?Object.entries(a.i18n.locales).map(([p,g])=>{let b=a.i18n?.localeConfigs?.[p];return{key:p,label:b?.label||g,value:p,isCurrent:p===n}}):[];return{currentLocale:n,currentLocaleLabel:c,availableLocales:m,handleLocaleChange:i}}import{useLocation as vs}from"react-router-dom";function _t(){let{routes:e,currentRoute:t}=P(),o=vs();if(!t)return{prevPage:null,nextPage:null,currentRoute:null};let r=t.tab?.toLowerCase(),n=r?e.filter(i=>i.tab?.toLowerCase()===r):e.filter(i=>!i.tab),a=n.findIndex(i=>i.path===o.pathname),s=a>0?n[a-1]:null,l=a!==-1&&a<n.length-1?n[a+1]:null;return{prevPage:s,nextPage:l,currentRoute:t}}function Gt(){let{currentRoute:e}=P(),t=[];return e&&(e.groupTitle&&t.push({label:e.groupTitle}),t.push({label:e.title,href:e.path})),{crumbs:t,activeRoute:e}}import{useLocation as ys}from"react-router-dom";var Ut=()=>ys();import{jsx as Ce}from"react/jsx-runtime";function Cs({children:e,className:t,style:o}){return Ce("div",{className:u("h-screen flex flex-col overflow-hidden bg-bg-main text-text-main",t),style:o,children:e})}function Rs({children:e,className:t,style:o}){return Ce("div",{className:u("mx-auto flex flex-1 w-full max-w-(--breakpoint-3xl) bg-bg-main overflow-hidden",t),style:o,children:e})}function Ps({children:e,className:t,style:o}){return Ce("main",{className:u("boltdocs-content flex-1 min-w-0 overflow-y-auto","contain-layout",t),style:o,children:e})}function Ns({children:e,className:t,style:o}){let{pathname:r}=Ut();return Ce("div",{className:u("boltdocs-page mx-auto pt-4 pb-20 px-4 sm:px-8",{"max-w-content-max":r.includes("/docs/")},t),style:o,children:e})}function Ts({children:e,className:t,style:o}){return Ce("div",{className:u("flex items-center justify-between mb-10",t),style:o,children:e})}function Ls({children:e,className:t,style:o}){return Ce("div",{className:u("mt-20",t),style:o,children:e})}var ce=Object.assign(Cs,{Body:Rs,Content:Ps,ContentMdx:Ns,ContentHeader:Ts,ContentFooter:Ls});import{Suspense as Vs,lazy as Os}from"react";import{useEffect as ws,useState as ks}from"react";import{Sun as Uo,Moon as qo,Monitor as jo}from"lucide-react";import{Button as Ss}from"react-aria-components";import{jsx as j,jsxs as Be}from"react/jsx-runtime";function Xo(){let{theme:e,setTheme:t}=se(),[o,r]=ks(!1);if(ws(()=>{r(!0)},[]),!o)return j("div",{className:"h-9 w-9"});let n=e==="system"?jo:e==="dark"?qo:Uo;return Be(C.Trigger,{placement:"bottom right",children:[j(Ss,{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:j(n,{size:20,className:"animate-in fade-in zoom-in duration-300"})}),Be(C.Root,{selectionMode:"single",selectedKeys:[e],onSelectionChange:a=>{let s=Array.from(a)[0];t(s)},children:[Be(C.Item,{id:"light",children:[j(Uo,{size:16}),j("span",{children:"Light"})]}),Be(C.Item,{id:"dark",children:[j(qo,{size:16}),j("span",{children:"Dark"})]}),Be(C.Item,{id:"system",children:[j(jo,{size:16}),j("span",{children:"System"})]})]})]})}import{useEffect as Bs,useState as Es}from"react";var Ms="https://api.github.com";async function Ko(e,t,o=Ms){let r=new Headers;t&&r.append("authorization",t);let a=await(await fetch(`${o}/repos/${e}`,{headers:r})).json();return a.stargazers_count!==void 0?Is(a.stargazers_count):"0"}var Is=e=>Intl.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(e);import{jsx as Jo,jsxs as As}from"react/jsx-runtime";function Yo({repo:e}){let[t,o]=Es(null);return Bs(()=>{e&&Ko(e).then(r=>o(r)).catch(()=>o("0"))},[e]),As("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:[Jo(no,{className:"h-4 w-4"}),t&&Jo("span",{className:"tabular-nums",children:t})]})}import*as Hs from"lucide-react";import{jsx as Re,jsxs as Zo}from"react/jsx-runtime";function Qo({tabs:e,routes:t}){let{currentLocale:o}=P(),{indicatorStyle:r,tabRefs:n,activeIndex:a}=zt(e,t),s=l=>{if(!l)return null;if(l.trim().startsWith("<svg"))return Re("span",{className:"h-4 w-4",dangerouslySetInnerHTML:{__html:l}});let i=Hs[l];return i?Re(i,{size:16}):Re("img",{src:l,alt:"",className:"h-4 w-4 object-contain"})};return Re("div",{className:"mx-auto max-w-(--breakpoint-3xl) px-4 md:px-6",children:Zo(We.List,{className:"border-none py-0",children:[e.map((l,i)=>{let d=i===a,c=t.find(p=>p.tab&&p.tab.toLowerCase()===l.id.toLowerCase()),m=c?c.path:"#";return Zo(re,{href:m,ref:p=>{n.current[i]=p},className:`relative flex items-center gap-2 px-4 py-3 text-sm font-medium transition-colors outline-none ${d?"text-primary-500":"text-text-muted hover:text-text-main"}`,children:[s(l.icon),Re("span",{children:ee(l.text,o)})]},l.id)}),Re(We.Indicator,{style:r})]})})}import{useLocation as Ds}from"react-router-dom";import{ChevronDown as er,Languages as $s}from"lucide-react";import{Fragment as Gs,jsx as v,jsxs as oe}from"react/jsx-runtime";var zs=Os(()=>import("../search-dialog-YBM4GYDR.mjs").then(e=>({default:e.SearchDialog})));function qt(){let{links:e,title:t,logo:o,logoProps:r,github:n,social:a,config:s}=Ot(),{routes:l,allRoutes:i,currentVersion:d,currentLocale:c}=P(),{pathname:m}=Ds(),p=s.theme||{},g=m.startsWith("/docs"),b=p?.tabs&&p.tabs.length>0;return oe(E.Root,{className:b?"border-b-0":"",children:[oe(E.Content,{children:[oe(E.Left,{children:[o&&v(E.Logo,{src:o,alt:r?.alt||t,width:r?.width??24,height:r?.height??24}),v(E.Title,{children:t}),s.versions&&d&&v(Ws,{})]}),v(E.Center,{children:v(Vs,{fallback:v("div",{className:"h-9 w-32 animate-pulse rounded-md bg-bg-surface"}),children:v(zs,{routes:l||[]})})}),oe(E.Right,{children:[v(E.Links,{children:e.map(f=>v(Gs,{children:v(Fs,{link:f},f.href)}))}),s.i18n&&c&&v(_s,{}),v(E.Split,{}),v(Xo,{}),n&&v(Yo,{repo:p?.githubRepo??""}),a.length>0&&v(E.Split,{}),v("div",{className:"flex items-center gap-1",children:a.map(({icon:f,link:h})=>v(E.Socials,{icon:f,link:h,className:"p-1.5"},h))})]})]}),g&&b&&p?.tabs&&v("div",{className:"w-full border-b border-border-subtle bg-bg-main",children:v(Qo,{tabs:p.tabs,routes:i||l||[]})})]})}function Fs({link:e}){let t=Ke(e.href||"");return v(E.Link,{...e,href:t})}function Ws(){let{currentVersionLabel:e,availableVersions:t,handleVersionChange:o}=Ft();return t.length===0?null:oe(C.Trigger,{children:[v(V,{variant:"outline",size:"sm",rounded:"lg",iconPosition:"right",icon:v(er,{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:v("span",{className:"font-semibold text-[0.8125rem]",children:e})}),v(C.Root,{children:v(C.Section,{items:t,children:r=>v(C.Item,{onPress:()=>o(r.value),children:r.label},`${r.value??""}`)})})]})}function _s(){let{currentLocale:e,availableLocales:t,handleLocaleChange:o}=Wt();return t.length===0?null:oe(C.Trigger,{children:[v(V,{variant:"outline",size:"sm",rounded:"lg",iconPosition:"right",icon:v(er,{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:oe("div",{className:"flex items-center gap-1.5",children:[v($s,{className:"w-3.5 h-3.5 text-primary-500"}),v("span",{className:"font-bold text-[0.75rem] tracking-wider uppercase opacity-90",children:e||"en"})]})}),v(C.Root,{children:v(C.Section,{items:t,children:r=>v(C.Item,{onPress:()=>o(r.value),children:oe("div",{className:"flex items-center justify-between w-full gap-4",children:[v("span",{children:r.label}),v("span",{className:"text-[10px] font-bold opacity-40 uppercase tracking-tighter",children:r.value})]})},`${r.value??""}`)})})]})}import{useState as qs,useEffect as js,useMemo as Xs}from"react";import{Zap as Us}from"lucide-react";import{jsx as jt,jsxs as tr}from"react/jsx-runtime";function or(){return jt("div",{className:"flex items-center justify-center mt-10 mb-4 px-4 w-full",children:tr("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:[jt(Us,{className:"w-3.5 h-3.5 text-text-muted group-hover:text-primary-500 transition-colors duration-300",fill:"currentColor"}),tr("span",{className:"text-[11px] font-medium text-text-muted group-hover:text-text-main transition-colors duration-300 tracking-wide",children:["Powered by"," ",jt("strong",{className:"font-bold text-text-main/80 group-hover:text-text-main",children:"Boltdocs"})]})]})})}import*as Ks from"lucide-react";import{jsx as me,jsxs as Ys}from"react/jsx-runtime";function rr(e){return e&&Ks[e]||void 0}function Js({group:e,activePath:t,getIcon:o}){let r=Xs(()=>e.routes.some(s=>s.path===t),[e.routes,t]),[n,a]=qs(!0);return js(()=>{r&&a(!0)},[r]),me(ne.Group,{title:e.title,isOpen:n,onToggle:()=>a(!n),children:e.routes.map(s=>{let l=t===(s.path.endsWith("/")?s.path.slice(0,-1):s.path);return me(ne.Link,{label:s.title,href:s.path,active:l,icon:o(s.icon),badge:s.badge},s.path)})})}function Xt({routes:e,config:t}){let{groups:o,ungrouped:r,activePath:n}=Dt(e),a=t.theme||{};return Ys(ne.Root,{children:[r.length>0&&me(ne.Group,{className:"mb-6",children:r.map(s=>{let l=n===(s.path.endsWith("/")?s.path.slice(0,-1):s.path);return me(ne.Link,{label:s.title,href:s.path,active:l,icon:rr(s.icon),badge:s.badge},s.path)})}),o.map(s=>me(Js,{group:s,activePath:n,getIcon:rr},s.slug)),a?.poweredBy&&me("div",{className:"mt-auto pt-8",children:me(or,{})})]})}import Zs,{useRef as nr,useEffect as Qs,useState as ea,useCallback as ta}from"react";import{Pencil as oa,CircleHelp as ra,TextAlignStart as na}from"lucide-react";import{jsx as A,jsxs as de}from"react/jsx-runtime";function Kt({headings:e=[],editLink:t,communityHelp:o,filePath:r}){let{headings:n}=$t(e),a=Zs.useMemo(()=>n.map(s=>({title:s.text,url:`#${s.id}`,depth:s.level})),[n]);return n.length===0?null:A(Ze,{toc:a,children:A(sa,{headings:n,editLink:t,communityHelp:o,filePath:r})})}function sa({headings:e,editLink:t,communityHelp:o,filePath:r}){let n=Je(),[a,s]=ea({opacity:0}),l=nr(null),i=nr(null);Qs(()=>{if(!n||!l.current)return;let c=l.current.querySelector(`a[href="#${n}"]`);c&&s({transform:`translateY(${c.offsetTop}px)`,height:`${c.offsetHeight}px`,opacity:1})},[n]);let d=ta((c,m)=>{c.preventDefault();let p=document.getElementById(m);p&&(p.scrollIntoView({behavior:"smooth"}),window.history.pushState(null,"",`#${m}`))},[]);return de(K.Root,{children:[de(K.Header,{className:"flex flex-row gap-x-2",children:[A(na,{size:16}),"On this page"]}),A(Ye,{containerRef:i,children:de(K.Content,{className:"max-h-[450px] boltdocs-otp-scroll-area",ref:i,children:[A(K.Indicator,{style:a}),A("ul",{className:"relative space-y-2 border-l border-border-subtle",ref:l,children:e.map(c=>A(K.Item,{level:c.level,children:A(K.Link,{href:`#${c.id}`,active:n===c.id,onClick:m=>d(m,c.id),className:"pl-4",children:c.text})},c.id))})]})}),(t||o)&&de("div",{className:"mt-8 pt-8 border-t border-border-subtle space-y-4",children:[A("p",{className:"text-xs font-bold uppercase tracking-wider text-text-main",children:"Need help?"}),de("ul",{className:"space-y-3",children:[t&&r&&A("li",{children:de("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:[A(oa,{size:16}),"Edit this page"]})}),o&&A("li",{children:de("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:[A(ra,{size:16}),"Community help"]})})]})]})]})}import{useEffect as aa}from"react";import{useLocation as ia}from"react-router-dom";function Jt({siteTitle:e,siteDescription:t,routes:o}){let r=ia();return aa(()=>{let n=o.find(d=>d.path===r.pathname),a=n?.title,s=n?.description||t||"";document.title=a?`${a} | ${e}`:e;let l=document.querySelector('meta[name="description"]');l||(l=document.createElement("meta"),l.name="description",document.head.appendChild(l)),l.content=s,pe("property","og:title",document.title),pe("property","og:description",s),pe("property","og:type","article"),pe("property","og:url",window.location.href),pe("name","twitter:card","summary"),pe("name","twitter:title",document.title),pe("name","twitter:description",s);let i=document.querySelector('link[rel="canonical"]');i||(i=document.createElement("link"),i.rel="canonical",document.head.appendChild(i)),i.href=window.location.origin+r.pathname},[r.pathname,e,t,o]),null}function pe(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}import{Home as la}from"lucide-react";import{jsx as Ee,jsxs as sr}from"react/jsx-runtime";function Yt(){let{crumbs:e,activeRoute:t}=Gt(),r=B().theme||{};return e.length===0||!r?.breadcrumbs?null:sr(J.Root,{children:[Ee(J.Item,{children:Ee(J.Link,{href:"/",children:Ee(la,{size:14})})}),e.map((n,a)=>sr(J.Item,{children:[Ee(J.Separator,{}),Ee(J.Link,{href:n.href,className:u({"font-medium text-text-main":n.href===t?.path}),children:n.label})]},`crumb-${n.href}-${n.label}-${a}`))]})}import{jsx as Ae,jsxs as Zt}from"react/jsx-runtime";function Qt(){let{prevPage:e,nextPage:t}=_t();return!e&&!t?null:Zt(G.Root,{className:"animate-in fade-in slide-in-from-bottom-4 duration-700",children:[e?Zt(G.Link,{to:e.path,direction:"prev",children:[Ae(G.Title,{children:"Previous"}),Ae(G.Description,{children:e.title})]}):Ae("div",{}),t&&Zt(G.Link,{to:t.path,direction:"next",children:[Ae(G.Title,{children:"Next"}),Ae(G.Description,{children:t.title})]})]})}import{Component as ca}from"react";import{jsx as eo,jsxs as ma}from"react/jsx-runtime";var He=class extends ca{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||ma("div",{className:"flex flex-col items-center justify-center min-h-[40vh] text-center gap-4 px-4",children:[eo("div",{className:"text-lg font-bold text-red-400",children:"Something went wrong"}),eo("p",{className:"text-sm text-text-muted max-w-md",children:this.state.error?.message||"An unexpected error occurred while rendering this page."}),eo(V,{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}};import{useLocation as da}from"react-router-dom";import{jsx as X,jsxs as Xe}from"react/jsx-runtime";function pa({children:e}){let{routes:t,allRoutes:o,currentRoute:r,currentLocale:n}=P(),{pathname:a}=da(),s=B(),i=Te().CopyMarkdown||Ie,d=a==="/"||a==="";return Xe(ce,{children:[X(Jt,{siteTitle:ee(s.theme?.title,n)||"Boltdocs",siteDescription:ee(s.theme?.description,n)||"",routes:o}),X(qt,{}),Xe(ce.Body,{children:[!d&&X(Xt,{routes:t,config:s}),Xe(ce.Content,{children:[!d&&Xe(ce.ContentHeader,{children:[X(Yt,{}),X(i,{mdxRaw:r?._rawContent,route:r,config:s.theme?.copyMarkdown})]}),X(He,{children:e}),!d&&X(ce.ContentFooter,{children:X(Qt,{})})]}),!d&&X(Kt,{headings:r?.headings,editLink:s.theme?.editLink,communityHelp:s.theme?.communityHelp,filePath:r?.filePath})]})]})}export{z as Admonition,Ze as AnchorProvider,lt as Badge,Yt as Breadcrumbs,tt as Button,Qe as ButtonGroup,mt as Card,ct as Cards,ht as Caution,U as CodeBlock,Et as ComponentPreview,It as ComponentProps,Ie as CopyMarkdown,ft as Danger,pa as DefaultLayout,ce as DocsLayout,He as ErrorBoundary,kt as Field,Lt as FileTree,Jt as Head,Mt as Image,bt as Important,gt as InfoBox,St as Link,vt as List,Ht as Loading,qt as Navbar,_e as NotFound,dt as Note,Kt as OnThisPage,Qt as PageNav,J as PrimitiveBreadcrumbs,V as PrimitiveButton,re as PrimitiveLink,C as PrimitiveMenu,lr as PrimitiveNavLink,cr as PrimitiveNavbar,mr as PrimitiveNavigationMenu,K as PrimitiveOnThisPage,G as PrimitivePageNav,fr as PrimitivePopover,ne as PrimitiveSidebar,T as PrimitiveSkeleton,We as PrimitiveTabs,Fe as PrimitiveTooltip,Ye as ScrollProvider,dr as SearchDialogPrimitive,Xt as Sidebar,st as Tab,wt as Table,at as Tabs,pt as Tip,it as Video,ut as Warning,u as cn,ls as createBoltdocsApp,Je as useActiveAnchor,ur as useActiveAnchors,Gt as useBreadcrumbs,B as useConfig,Wt as useI18n,pr as useItems,Ke as useLocalizedTo,Ut as useLocation,Te as useMdxComponents,Ot as useNavbar,$t as useOnThisPage,_t as usePageNav,P as useRoutes,gr as useSearch,Dt as useSidebar,zt as useTabs,se as useTheme,Ft as useVersion};
|