boltdocs 2.0.0 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (67) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/bin/boltdocs.js +12 -0
  3. package/dist/cache-Q4T6VAUL.mjs +1 -0
  4. package/dist/chunk-52MVMZWS.mjs +1 -0
  5. package/dist/chunk-BVWWKXJH.mjs +1 -0
  6. package/dist/chunk-DVY3RDXD.mjs +1 -0
  7. package/dist/chunk-FUVYCYWC.mjs +1 -0
  8. package/dist/{chunk-BA5NH5HU.mjs → chunk-GBLMDJ2B.mjs} +1 -1
  9. package/dist/{chunk-H63UMKYF.mjs → chunk-ISPX45DF.mjs} +1 -1
  10. package/dist/chunk-PNXZMUCO.mjs +1 -0
  11. package/dist/chunk-V2ZHKQSP.mjs +74 -0
  12. package/dist/client/components/mdx/index.d.mts +2 -3
  13. package/dist/client/components/mdx/index.d.ts +2 -3
  14. package/dist/client/components/mdx/index.js +1 -1
  15. package/dist/client/components/mdx/index.mjs +1 -1
  16. package/dist/client/hooks/index.d.mts +2 -3
  17. package/dist/client/hooks/index.d.ts +2 -3
  18. package/dist/client/hooks/index.js +1 -1
  19. package/dist/client/hooks/index.mjs +1 -1
  20. package/dist/client/index.d.mts +3 -5
  21. package/dist/client/index.d.ts +3 -5
  22. package/dist/client/index.js +1 -1
  23. package/dist/client/index.mjs +1 -1
  24. package/dist/client/ssr.d.mts +53 -6
  25. package/dist/client/ssr.d.ts +53 -6
  26. package/dist/client/ssr.mjs +1 -1
  27. package/dist/node/cli-entry.d.mts +1 -0
  28. package/dist/node/cli-entry.d.ts +1 -0
  29. package/dist/node/cli-entry.js +75 -0
  30. package/dist/node/cli-entry.mjs +2 -0
  31. package/dist/node/index.d.mts +213 -4
  32. package/dist/node/index.d.ts +213 -4
  33. package/dist/node/index.js +40 -23
  34. package/dist/node/index.mjs +1 -57
  35. package/dist/search-dialog-TWGYKF2D.mjs +1 -0
  36. package/dist/types-Cp21DHI6.d.mts +355 -0
  37. package/dist/types-Cp21DHI6.d.ts +355 -0
  38. package/dist/{use-routes-BefRXY3v.d.ts → use-routes-8Iei6jTp.d.mts} +1 -2
  39. package/dist/{use-routes-5bAtAAYX.d.mts → use-routes-xLhumjbV.d.ts} +1 -2
  40. package/package.json +7 -1
  41. package/src/client/components/ui-base/breadcrumbs.tsx +2 -1
  42. package/src/client/components/ui-base/navbar.tsx +3 -3
  43. package/src/client/components/ui-base/sidebar.tsx +2 -1
  44. package/src/client/hooks/use-navbar.ts +1 -1
  45. package/src/node/cli-entry.ts +24 -0
  46. package/src/node/cli.ts +59 -0
  47. package/src/node/config.ts +63 -11
  48. package/src/node/index.ts +39 -3
  49. package/src/node/plugin/entry.ts +7 -0
  50. package/src/node/plugin/html.ts +49 -9
  51. package/src/node/plugin/index.ts +42 -3
  52. package/src/node/ssg/index.ts +6 -1
  53. package/src/node/ssg/robots.ts +50 -0
  54. package/tsup.config.ts +36 -10
  55. package/dist/cache-7G6D532T.mjs +0 -1
  56. package/dist/chunk-A4HQPEPU.mjs +0 -1
  57. package/dist/chunk-BQCD3DWG.mjs +0 -1
  58. package/dist/chunk-IWHRQHS7.mjs +0 -1
  59. package/dist/chunk-JZXLCA2E.mjs +0 -1
  60. package/dist/chunk-MFU7Q6WF.mjs +0 -1
  61. package/dist/chunk-QYPNX5UN.mjs +0 -1
  62. package/dist/chunk-XEAPSFMB.mjs +0 -1
  63. package/dist/config-CX4l-ZNp.d.mts +0 -166
  64. package/dist/config-CX4l-ZNp.d.ts +0 -166
  65. package/dist/search-dialog-EB3N4TYM.mjs +0 -1
  66. package/dist/types-BuZWFT7r.d.ts +0 -159
  67. package/dist/types-CvT-SGbK.d.mts +0 -159
@@ -1 +1 @@
1
- "use strict";var Yt=Object.create;var ye=Object.defineProperty;var er=Object.getOwnPropertyDescriptor;var tr=Object.getOwnPropertyNames;var rr=Object.getPrototypeOf,or=Object.prototype.hasOwnProperty;var nr=(e,t)=>{for(var r in t)ye(e,r,{get:t[r],enumerable:!0})},Ue=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of tr(t))!or.call(e,n)&&n!==r&&ye(e,n,{get:()=>t[n],enumerable:!(o=er(t,n))||o.enumerable});return e};var w=(e,t,r)=>(r=e!=null?Yt(rr(e)):{},Ue(t||!e||!e.__esModule?ye(r,"default",{value:e,enumerable:!0}):r,e)),sr=e=>Ue(ye({},"__esModule",{value:!0}),e);var Yr={};nr(Yr,{Admonition:()=>j,Badge:()=>lt,Button:()=>Ze,Card:()=>ut,Cards:()=>mt,Caution:()=>Nt,CodeBlock:()=>Y,ComponentPreview:()=>Ft,ComponentProps:()=>zt,CopyMarkdown:()=>Qt,Danger:()=>vt,Field:()=>At,FileTree:()=>wt,Image:()=>Vt,Important:()=>Ct,InfoBox:()=>yt,Link:()=>Mt,List:()=>Rt,Note:()=>xt,Tab:()=>nt,Table:()=>Tt,Tabs:()=>st,Tip:()=>gt,Video:()=>at,Warning:()=>ht});module.exports=sr(Yr);var Ne=w(require("react-aria-components"));var qe=require("clsx"),Xe=require("tailwind-merge");function s(...e){return(0,Xe.twMerge)((0,qe.clsx)(e))}var Ke=require("class-variance-authority"),H=require("react/jsx-runtime"),Ce=(0,Ke.cva)("flex flex-row items-center justify-center w-auto font-semibold tracking-tight no-underline whitespace-nowrap select-none outline-none transition-all duration-200 cursor-pointer pressed:scale-[0.97] hover:-translate-y-px leading-none",{variants:{variant:{primary:"bg-primary-500 text-white shadow-md hover:brightness-110 hover:shadow-lg",secondary:"bg-bg-surface text-text-main border border-border-subtle hover:bg-bg-muted hover:border-border-strong",outline:"bg-transparent text-text-main border border-border-strong hover:bg-bg-surface hover:border-primary-500",ghost:"bg-transparent text-text-muted hover:bg-bg-surface hover:text-text-main",danger:"bg-[var(--color-danger-500)]/10 text-[var(--color-danger-500)] border border-[var(--color-danger-500)]/20 hover:bg-[var(--color-danger-500)]/15",success:"bg-[var(--color-success-500)]/10 text-[var(--color-success-500)] border border-[var(--color-success-500)]/20 hover:bg-[var(--color-success-500)]/15",warning:"bg-[var(--color-warning-500)]/10 text-[var(--color-warning-500)] border border-[var(--color-warning-500)]/20 hover:bg-[var(--color-warning-500)]/15",info:"bg-[var(--color-info-500)]/10 text-[var(--color-info-500)] border border-[var(--color-info-500)]/20 hover:bg-[var(--color-info-500)]/15",subtle:"bg-primary-500/10 text-primary-500 hover:bg-primary-500/20",link:"bg-transparent text-primary-500 !p-0 !min-h-0 hover:underline"},size:{sm:"min-h-8 px-3.5 text-[0.8125rem] gap-1.5",md:"min-h-10 px-5 text-[0.9375rem] gap-2",lg:"min-h-12 px-7 text-[1.05rem] gap-2.5"},rounded:{none:"rounded-none",sm:"rounded-sm",md:"rounded-md",lg:"rounded-lg",full:"rounded-full"},iconSize:{sm:"w-8 h-8 p-0",md:"w-10 h-10 p-0",lg:"w-12 h-12 p-0"},disabled:{true:"opacity-50 cursor-not-allowed pointer-events-none",false:null}},defaultVariants:{variant:"primary",size:"md",rounded:"md"}}),Z=({href:e,icon:t,iconPosition:r="left",isIconOnly:o,children:n,className:a,variant:c,size:l,rounded:i,iconSize:d,disabled:p,...m})=>{let f=o||!n&&!!t,x=f?(0,H.jsx)("span",{className:"inline-flex items-center justify-center [&>svg]:w-[1.2rem] [&>svg]:h-[1.2rem]",children:t}):(0,H.jsxs)(H.Fragment,{children:[t&&r==="left"&&(0,H.jsx)("span",{className:"inline-flex items-center shrink-0 [&>svg]:w-[1.1rem] [&>svg]:h-[1.1rem]",children:t}),(0,H.jsx)("span",{className:"flex items-center",children:n}),t&&r==="right"&&(0,H.jsx)("span",{className:"inline-flex items-center shrink-0 [&>svg]:w-[1.1rem] [&>svg]:h-[1.1rem]",children:t})]});return e?(0,H.jsx)(Ne.Link,{href:e,className:s(Ce({variant:c,size:l,rounded:i,iconSize:f?d:void 0,disabled:p}),a),...m,children:x}):(0,H.jsx)(Ne.Button,{className:s(Ce({variant:c,size:l,rounded:i,iconSize:f?d:void 0,disabled:p}),a),...m,children:x})};var Je=require("react/jsx-runtime"),Ze=({className:e,variant:t,size:r,rounded:o,iconSize:n,disabled:a,...c})=>(0,Je.jsx)(Z,{className:s("group",Ce({variant:t,size:r,rounded:o,iconSize:n,disabled:a,className:e})),...c});var Pe=w(require("react-aria-components")),we=require("lucide-react");var Re=require("react"),ar=(0,Re.createContext)(null);function J(){let e=(0,Re.use)(ar);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e}var Se=require("codesandbox/lib/api/define.js");function Qe(e){let t=e.files||{},r=e.dependencies||{},o=e.devDependencies||{},n=e.title||"codesandbox-project",a=e.description||"Generic Sandbox",c={};for(let[l,i]of Object.entries(t)){let d=typeof i.content=="object"?JSON.stringify(i.content,null,2):i.content;c[l]={content:d,isBinary:i.isBinary??!1}}if(!c["package.json"]){let i=e.template==="vite"||!!o.vite||!!o["@vitejs/plugin-react"]?{dev:"vite",build:"vite build",preview:"vite preview"}:{start:"node index.js"};c["package.json"]={content:JSON.stringify({private:!0,name:n,description:a,type:"module",version:"1.0.0",scripts:e.scripts||i,dependencies:r,devDependencies:o},null,2),isBinary:!1}}return c}function ir(e){let t=Qe(e),r=(0,Se.getParameters)({files:t}),o=new URLSearchParams({parameters:r,installDependencies:"true"});return e.entry&&o.set("file",`/${e.entry}`),{parameters:r,url:`https://codesandbox.io/api/v1/sandboxes/define?${o.toString()}`,options:e}}function Ye(e){if(typeof window>"u")return ir(e);let t=Qe(e),r=(0,Se.getParameters)({files:t}),o=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)},c=new URLSearchParams({file:`/${o}`,eslint:"0",codemirror:"1",installDependencies:"true"});return a("query",c.toString()),a("parameters",r),document.body.appendChild(n),n.submit(),document.body.removeChild(n),{parameters:r,url:`https://codesandbox.io/api/v1/sandboxes/define?parameters=${r}`,options:e}}var et=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}};var F=require("react");function tt(e){let{title:t,sandbox:r}=e,[o,n]=(0,F.useState)(!1),[a,c]=(0,F.useState)(!1),[l,i]=(0,F.useState)(!1),d=(0,F.useRef)(null),p=J(),m=(0,F.useCallback)(async()=>{let x=d.current?.textContent??"";et(x),n(!0),setTimeout(()=>n(!1),2e3)},[]),f=(0,F.useCallback)(()=>{let x=d.current?.textContent??"",P=p?.integrations?.sandbox?.config||{},g=typeof r=="object"?r:P,N=g.entry||"src/App.tsx";Ye({title:t??"Code Snippet",...g,files:{...g.files,[N]:{content:x}}})},[t,p,r]);return(0,F.useEffect)(()=>{let x=d.current?.textContent?.length??0;i(x>120)},[e.children,e.highlightedHtml]),{copied:o,isExpanded:a,setIsExpanded:c,isExpandable:l,preRef:d,handleCopy:m,handleSandbox:f,shouldTruncate:l&&!a}}var pe=require("react/jsx-runtime");function lr(e){let{size:t=20,...r}=e;return{...r,width:t,height:t}}var rt=e=>(0,pe.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",...lr(e),children:[(0,pe.jsx)("title",{children:"CodeSandbox"}),(0,pe.jsx)("path",{d:"M0 24h24V0H0v2.455h21.546v19.09H2.454V0H0Z"})]});var Q=w(require("react-aria-components"));var V=require("react/jsx-runtime"),dr=({className:e,children:t,...r})=>(0,V.jsx)(Q.Tooltip,{...r,offset:8,className:o=>s("group z-50 overflow-visible rounded-md bg-bg-surface/90 px-2.5 py-1.5 text-xs font-medium text-text-main shadow-lg backdrop-blur-md ring-1 ring-border-subtle outline-hidden select-none","data-entering:animate-in data-entering:fade-in data-entering:zoom-in-95 data-entering:duration-100","data-exiting:animate-out data-exiting:fade-out data-exiting:zoom-out-95 data-exiting:duration-75","data-[placement=top]:slide-in-from-bottom-1","data-[placement=bottom]:slide-in-from-top-1","data-[placement=left]:slide-in-from-right-1","data-[placement=right]:slide-in-from-left-1",typeof e=="function"?e(o):e),children:o=>(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(Q.OverlayArrow,{children:(0,V.jsxs)("svg",{width:8,height:8,viewBox:"0 0 8 8",className:"fill-bg-surface/90 stroke-border-subtle group-data-[placement=bottom]:rotate-180 group-data-[placement=left]:-rotate-90 group-data-[placement=right]:rotate-90",children:[(0,V.jsx)("title",{children:"Arrow"}),(0,V.jsx)("path",{d:"M0 0 L4 4 L8 0"})]})}),typeof t=="function"?t(o):t]})}),Me=({content:e,children:t,delay:r=500,closeDelay:o=0,...n})=>(0,V.jsxs)(Q.TooltipTrigger,{delay:r,closeDelay:o,children:[t,(0,V.jsx)(dr,{...n,children:e})]});var T=require("react/jsx-runtime");function Y(e){let{children:t,sandbox:r,hideSandbox:o=!0,hideCopy:n=!1,highlightedHtml:a,...c}=e,d=!!J()?.integrations?.sandbox?.enable&&!o,{copied:p,isExpanded:m,setIsExpanded:f,isExpandable:x,preRef:P,handleCopy:g,handleSandbox:N,shouldTruncate:K}=tt(e);return(0,T.jsxs)("div",{className:s("group relative my-6 overflow-hidden rounded-lg border border-border-subtle bg-(--color-code-bg)",K&&"[&>pre]:max-h-[250px] [&>pre]:overflow-hidden"),children:[(0,T.jsxs)("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:[d&&(0,T.jsx)(Me,{content:"Open in CodeSandbox",children:(0,T.jsx)(Pe.Button,{onPress:N,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:(0,T.jsx)(rt,{size:20})})}),!n&&(0,T.jsx)(Me,{content:p?"Copied!":"Copy code",children:(0,T.jsx)(Pe.Button,{onPress:g,className:s("grid place-items-center w-8 h-8 bg-transparent outline-none cursor-pointer transition-all duration-200 hover:scale-115 active:scale-95 [&>svg]:w-5 [&>svg]:h-5 [&>svg]:stroke-2",p?"text-emerald-400":"text-text-muted hover:text-text-main"),"aria-label":"Copy code",children:p?(0,T.jsx)(we.Check,{size:20}):(0,T.jsx)(we.Copy,{size:20})})})]}),a?(0,T.jsx)("div",{ref:P,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}}):(0,T.jsx)("pre",{ref:P,className:"m-0! rounded-none! border-none! bg-inherit! font-mono text-[0.8125rem] leading-[1.7]",...c,children:t}),x&&(0,T.jsx)("div",{className:s(K?"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:(0,T.jsx)(Pe.Button,{onPress:()=>f(!m),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:m?"Show less":"Expand code"})})]})}var ee=require("react"),q=w(require("react-aria-components"));var _=require("react");function ot({initialIndex:e=0,tabs:t}){let r=t[e]?.props.disabled?t.findIndex(d=>!d.props.disabled):e,[o,n]=(0,_.useState)(r===-1?0:r),a=(0,_.useRef)([]),[c,l]=(0,_.useState)({opacity:0,transform:"translateX(0)",width:0});(0,_.useEffect)(()=>{let d=a.current[o];d&&l({opacity:1,width:d.offsetWidth,transform:`translateX(${d.offsetLeft}px)`})},[o,t]);let i=(0,_.useCallback)(d=>{let p=0;if(d.key==="ArrowRight"?p=1:d.key==="ArrowLeft"&&(p=-1),p!==0){let m=(o+p+t.length)%t.length;for(;t[m].props.disabled&&m!==o;)m=(m+p+t.length)%t.length;m!==o&&!t[m].props.disabled&&(n(m),a.current[m]?.focus())}},[o,t]);return{active:o,setActive:n,tabRefs:a,indicatorStyle:c,handleKeyDown:i}}var Ee=require("class-variance-authority"),L=require("react/jsx-runtime"),pr=(0,Ee.cva)("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"}}),mr=(0,Ee.cva)("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 nt({children:e}){let t=typeof e=="string"?(0,L.jsx)(Y,{className:"language-bash",children:(0,L.jsx)("code",{children:e.trim()})}):e;return(0,L.jsx)("div",{className:"py-4",children:t})}function st({defaultIndex:e=0,children:t}){let r=(0,ee.useMemo)(()=>ee.Children.toArray(t).filter(l=>(0,ee.isValidElement)(l)&&l.props?.label),[t]),{active:o,setActive:n,tabRefs:a,indicatorStyle:c}=ot({initialIndex:e,tabs:r});return(0,L.jsx)("div",{className:"my-8 w-full group/tabs",children:(0,L.jsxs)(q.Tabs,{selectedKey:o.toString(),onSelectionChange:l=>n(Number(l)),className:"w-full",children:[(0,L.jsxs)(q.TabList,{"aria-label":"Content Tabs",className:s(pr()),children:[r.map((l,i)=>{let{label:d,icon:p,disabled:m}=l.props,f=i.toString();return(0,L.jsxs)(q.Tab,{id:f,isDisabled:m,ref:x=>{a.current[i]=x},className:({isSelected:x,isDisabled:P})=>s(mr({isActive:x,isDisabled:P})),children:[!!p&&(0,L.jsx)("span",{className:"shrink-0 [&>svg]:w-4 [&>svg]:h-4",children:p}),(0,L.jsx)("span",{children:d})]},f)}),(0,L.jsx)("div",{className:"absolute bottom-0 h-0.5 bg-primary-500 transition-all duration-300 ease-in-out pointer-events-none",style:c,"aria-hidden":"true"})]}),r.map((l,i)=>(0,L.jsx)(q.TabPanel,{id:i.toString(),children:r[i]},i))]})})}var te=require("react"),me=require("react/jsx-runtime");function at({src:e,poster:t,alt:r,children:o,controls:n,preload:a="metadata",...c}){let l=(0,te.useRef)(null),[i,d]=(0,te.useState)(!1);return(0,te.useEffect)(()=>{let p=l.current;if(!p)return;let m=new IntersectionObserver(([f])=>{f.isIntersecting&&(d(!0),m.disconnect())},{rootMargin:"200px"});return m.observe(p),()=>m.disconnect()},[]),(0,me.jsx)("div",{ref:l,className:"my-6 overflow-hidden rounded-lg border border-border-subtle",children:i?(0,me.jsxs)("video",{className:"block w-full h-auto",src:e,poster:t,controls:!0,preload:a,playsInline:!0,...c,children:[o,"Your browser does not support the video tag."]}):(0,me.jsx)("div",{className:"aspect-video bg-bg-surface animate-pulse",role:"img","aria-label":r||"Video"})})}var it=require("class-variance-authority"),ct=require("react/jsx-runtime"),ur=(0,it.cva)("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:r="",...o}){return(0,ct.jsx)("span",{className:s(ur({variant:e}),r),...o,children:t})}var ue=require("react"),dt=w(require("react-aria-components"));var pt=require("class-variance-authority"),S=require("react/jsx-runtime"),fr=(0,pt.cva)("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 mt({cols:e=3,children:t,className:r="",...o}){return(0,S.jsx)("div",{className:s(fr({cols:e}),r),...o,children:t})}function ut({title:e,icon:t,href:r,children:o,className:n="",...a}){let c=(0,ue.useRef)(null),l=(0,ue.useRef)(null),i=(0,ue.useCallback)(m=>{let f=c.current||l.current;if(!f)return;let{left:x,top:P}=f.getBoundingClientRect();f.style.setProperty("--x",`${m.clientX-x}px`),f.style.setProperty("--y",`${m.clientY-P}px`)},[]),d=(0,S.jsxs)(S.Fragment,{children:[(0,S.jsx)("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&&(0,S.jsx)("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}),(0,S.jsxs)("div",{className:"space-y-1.5",children:[e&&(0,S.jsx)("h3",{className:"text-sm font-bold text-text-main",children:e}),o&&(0,S.jsx)("div",{className:"text-sm text-text-muted leading-relaxed",children:o})]})]}),p=s("group relative block rounded-xl border border-border-subtle bg-bg-surface p-5 outline-none overflow-hidden","transition-all duration-200 hover:border-primary-500/40 hover:shadow-lg hover:shadow-primary-500/5","focus-visible:ring-2 focus-visible:ring-primary-500/30",n);return r?(0,S.jsx)(dt.Link,{ref:l,href:r,className:s(p,"no-underline cursor-pointer"),onMouseMove:i,...a,children:d}):(0,S.jsx)("div",{ref:c,role:"presentation",className:p,onMouseMove:i,...a,children:d})}var I=require("lucide-react");var bt=require("class-variance-authority"),y=require("react/jsx-runtime"),br={note:(0,y.jsx)(I.Bookmark,{size:18}),tip:(0,y.jsx)(I.Lightbulb,{size:18}),info:(0,y.jsx)(I.Info,{size:18}),warning:(0,y.jsx)(I.AlertTriangle,{size:18}),danger:(0,y.jsx)(I.ShieldAlert,{size:18}),important:(0,y.jsx)(I.Flame,{size:18}),caution:(0,y.jsx)(I.Zap,{size:18})},xr={note:"Note",tip:"Tip",info:"Info",warning:"Warning",danger:"Danger",important:"Important",caution:"Caution"},ft=(0,bt.cva)("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 j({type:e="note",title:t,children:r,className:o="",...n}){return(0,y.jsxs)("div",{className:s(ft({type:e}),o),role:e==="warning"||e==="danger"?"alert":"note",...n,children:[(0,y.jsxs)("div",{className:"flex items-center flex-row gap-2 mb-2",children:[(0,y.jsx)("span",{className:s("shrink-0",ft({type:e})),children:br[e]}),(0,y.jsx)("span",{className:"text-sm font-bold tracking-tight text-text-main",children:t||xr[e]})]}),(0,y.jsx)("div",{className:"text-sm text-text-muted leading-relaxed [&>p]:m-0 [&>p]:mb-2 [&>p:last-child]:mb-0",children:r})]})}var xt=e=>(0,y.jsx)(j,{type:"note",...e}),gt=e=>(0,y.jsx)(j,{type:"tip",...e}),ht=e=>(0,y.jsx)(j,{type:"warning",...e}),vt=e=>(0,y.jsx)(j,{type:"danger",...e}),yt=e=>(0,y.jsx)(j,{type:"info",...e}),Ct=e=>(0,y.jsx)(j,{type:"important",...e}),Nt=e=>(0,y.jsx)(j,{type:"caution",...e});var ke=require("react"),re=require("lucide-react");var Te=require("class-variance-authority"),W=require("react/jsx-runtime"),gr=(0,Te.cva)("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}}),hr=(0,Te.cva)("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}}),vr=(0,Te.cva)("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 yr({icon:e,children:t,variant:r,dense:o}){return(0,W.jsxs)("li",{className:s(hr({variant:r,dense:o})),children:[e&&(0,W.jsx)("span",{className:s(vr({variant:r==="bubble"?"bubble":"default"})),children:e}),(0,W.jsx)("div",{className:"flex-1 text-text-muted group-hover:text-text-main transition-colors",children:t})]})}var Cr={checked:e=>(0,W.jsx)(re.Check,{size:14,className:s("text-emerald-500 shrink-0",e)}),arrow:e=>(0,W.jsx)(re.ChevronRight,{size:14,className:s("text-primary-400 shrink-0",e)}),bubble:e=>(0,W.jsx)(re.Circle,{size:6,fill:"currentColor",className:s("text-primary-500 shrink-0",e)}),default:()=>null,number:()=>null};function Rt({variant:e="default",cols:t=1,dense:r=!1,children:o,className:n,...a}){let c=t!==void 0&&Number(t)>1,l=Cr[e],i=gr({variant:e,cols:t,dense:r,isGrid:c,className:n}),d=e==="number"?"ol":"ul";return e==="default"||e==="number"?(0,W.jsx)(d,{className:i,...a,children:o}):(0,W.jsx)("ul",{className:i,...a,children:ke.Children.map(o,p=>{if(!(0,ke.isValidElement)(p))return p;let m=p,f=m.type==="li"?m.props.children:m.props.children||p;return(0,W.jsx)(yr,{icon:l(),variant:e,dense:r,children:f})})})}var $=require("react"),G=w(require("react-aria-components")),D=require("lucide-react");var C=require("react/jsx-runtime"),fe=16,be=2,Oe={CODE:/\.(ts|tsx|js|jsx|json|mjs|cjs|astro|vue|svelte)$/i,TEXT:/\.(md|mdx|txt)$/i,IMAGE:/\.(png|jpg|jpeg|svg|gif)$/i};function De(e){return typeof e=="string"?e:typeof e=="number"?e.toString():Array.isArray(e)?e.map(De).join(""):(0,$.isValidElement)(e)&&e.props&&typeof e.props=="object"&&"children"in e.props?De(e.props.children):""}function Nr(e,t){let r=e.toLowerCase(),o="shrink-0 transition-colors duration-200";if(t)return(0,C.jsx)(D.Folder,{size:fe,strokeWidth:be,className:s(o,"text-primary-400"),fill:"currentColor",fillOpacity:.15});let n=s(o,"text-text-dim group-hover:text-text-main");return Oe.CODE.test(r)?(0,C.jsx)(D.FileCode,{size:fe,strokeWidth:be,className:n}):Oe.TEXT.test(r)?(0,C.jsx)(D.FileText,{size:fe,strokeWidth:be,className:n}):Oe.IMAGE.test(r)?(0,C.jsx)(D.FileImage,{size:fe,strokeWidth:be,className:n}):(0,C.jsx)(D.File,{size:fe,strokeWidth:be,className:n})}function Ve(e,t){if(!(0,$.isValidElement)(e))return!1;let r=e.type;if(typeof r=="string")return r===t;if(typeof r=="function")return r.name===t||r.name?.toLowerCase()===t;let o=e.props;return o?.originalType===t||o?.mdxType===t}function Rr(e){let t=e.match(/\s+(\/\/|#)\s+(.*)$/);return t?{name:e.slice(0,t.index).trim(),comment:t[2]}:{name:e.trim()}}function Ae(e,t="root"){if(!(0,$.isValidElement)(e))return[];let r=[];if(Ve(e,"ul"))return $.Children.forEach(e.props.children,(o,n)=>{r.push(...Ae(o,`${t}-${n}`))}),r;if(Ve(e,"li")){let o=$.Children.toArray(e.props.children),n=o.findIndex(P=>Ve(P,"ul")),a=n!==-1,c=a?o.slice(0,n):o,l=a?o.slice(n):[],i=De(c),{name:d,comment:p}=Rr(i),m=d.endsWith("/"),f=m?d.slice(0,-1):d,x=a||m;return r.push({id:`${t}-${f}`,name:f,comment:p,isFolder:x,children:a?Ae(l[0],`${t}-${f}`):void 0}),r}return e.props&&typeof e.props=="object"&&"children"in e.props&&$.Children.forEach(e.props.children,(o,n)=>{r.push(...Ae(o,`${t}-${n}`))}),r}function Pt({item:e}){return(0,C.jsxs)(G.TreeItem,{id:e.id,textValue:e.name,className:"outline-none group focus-visible:ring-2 focus-visible:ring-primary-500/30 rounded-md",children:[(0,C.jsx)(G.TreeItemContent,{children:({isExpanded:t,hasChildItems:r})=>(0,C.jsxs)("div",{className:"flex items-center gap-2 py-1 px-1.5 rounded-md transition-colors hover:bg-primary-500/5 cursor-pointer",children:[(0,C.jsx)("div",{style:{width:"calc((var(--tree-item-level) - 1) * 1rem)"},className:"shrink-0"}),r?(0,C.jsx)(G.Button,{slot:"chevron",className:"outline-none text-text-dim hover:text-primary-400 p-0.5 rounded transition-colors",children:(0,C.jsx)(D.ChevronRight,{size:14,strokeWidth:3,className:s("transition-transform duration-200",t&&"rotate-90")})}):(0,C.jsx)("div",{className:"w-[18px]"}),Nr(e.name,e.isFolder),(0,C.jsx)("span",{className:s("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&&(0,C.jsxs)("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&&(0,C.jsx)(G.Collection,{items:e.children,children:t=>(0,C.jsx)(Pt,{item:t})})]})}function wt({children:e}){let t=(0,$.useMemo)(()=>Ae(e),[e]);return(0,C.jsx)("div",{className:"my-8",children:(0,C.jsx)(G.Tree,{items:t,"aria-label":"File Tree",className:s("rounded-xl border border-border-subtle bg-bg-surface/50 p-4 font-mono text-sm shadow-sm backdrop-blur-sm outline-none","max-h-[500px] overflow-y-auto scrollbar-thin scrollbar-thumb-border-subtle","focus-visible:ring-2 focus-visible:ring-primary-500/20"),children:r=>(0,C.jsx)(Pt,{item:r})})})}var xe=w(require("react-aria-components"));var oe=require("react");function kt({data:e,sortable:t=!1,paginated:r=!1,pageSize:o=10}){let[n,a]=(0,oe.useState)(null),[c,l]=(0,oe.useState)(1),i=(0,oe.useMemo)(()=>{if(!e)return[];let f=[...e];return t&&n!==null&&f.sort((x,P)=>{let g=x[n.key],N=P[n.key],K=typeof g=="string"?g:"",ve=typeof N=="string"?N:"";return K<ve?n.direction==="asc"?-1:1:K>ve?n.direction==="asc"?1:-1:0}),f},[e,n,t]),d=Math.ceil(i.length/o),p=(0,oe.useMemo)(()=>{if(!r)return i;let f=(c-1)*o;return i.slice(f,f+o)},[i,r,c,o]);return{sortConfig:n,currentPage:c,setCurrentPage:l,totalPages:d,paginatedData:p,requestSort:f=>{if(!t)return;let x="asc";n&&n.key===f&&n.direction==="asc"&&(x="desc"),a({key:f,direction:x})}}}var M=require("lucide-react");var b=require("react/jsx-runtime");function Tt({headers:e,data:t,children:r,className:o="",sortable:n=!1,paginated:a=!1,pageSize:c=10}){let{sortConfig:l,currentPage:i,setCurrentPage:d,totalPages:p,paginatedData:m,requestSort:f}=kt({data:t,sortable:n,paginated:a,pageSize:c}),x=g=>n?l?.key!==g?(0,b.jsx)(M.ChevronDown,{size:14,className:"ml-1 opacity-30"}):l.direction==="asc"?(0,b.jsx)(M.ChevronUp,{size:14,className:"ml-1 text-primary-400"}):(0,b.jsx)(M.ChevronDown,{size:14,className:"ml-1 text-primary-400"}):null,P=r||(0,b.jsxs)(b.Fragment,{children:[e&&(0,b.jsx)("thead",{children:(0,b.jsx)("tr",{children:e.map((g,N)=>(0,b.jsx)("th",{onClick:()=>f(N),className:s("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:(0,b.jsxs)("div",{className:"flex items-center",children:[g,x(N)]})},N))})}),m&&(0,b.jsx)("tbody",{children:m.map((g,N)=>(0,b.jsx)("tr",{className:"transition-colors hover:bg-bg-surface",children:g.map((K,ve)=>(0,b.jsx)("td",{className:"px-3 py-2 border-b border-border-subtle text-sm text-text-muted",children:K},ve))},N))})]});return(0,b.jsxs)("div",{className:s("my-6 rounded-lg border border-border-subtle overflow-hidden",o),children:[(0,b.jsx)("div",{className:"overflow-x-auto",children:(0,b.jsx)("table",{className:"w-full border-collapse text-sm",children:P})}),a&&p>1&&(0,b.jsxs)("div",{className:"flex items-center justify-between border-t border-border-subtle px-4 py-3",children:[(0,b.jsxs)("span",{className:"text-xs text-text-muted",children:["Page ",i," of ",p]}),(0,b.jsxs)("div",{className:"flex items-center gap-1",children:[(0,b.jsx)(xe.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:(0,b.jsx)(M.ChevronsLeft,{size:16})}),(0,b.jsx)(xe.Button,{onPress:()=>d(g=>Math.max(g-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:(0,b.jsx)(M.ChevronLeft,{size:16})}),(0,b.jsx)(xe.Button,{onPress:()=>d(g=>Math.min(g+1,p)),isDisabled:i===p,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:(0,b.jsx)(M.ChevronRight,{size:16})}),(0,b.jsx)(xe.Button,{onPress:()=>d(p),isDisabled:i===p,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:(0,b.jsx)(M.ChevronsRight,{size:16})})]})]})]})}var E=require("react/jsx-runtime");function At({name:e,type:t,defaultValue:r,required:o=!1,children:n,id:a,className:c=""}){return(0,E.jsxs)("article",{className:s("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",c),id:a,children:[(0,E.jsxs)("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between mb-4",children:[(0,E.jsxs)("div",{className:"flex flex-wrap items-center gap-2.5",children:[(0,E.jsx)("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&&(0,E.jsx)("span",{className:"rounded-md bg-bg-muted/80 border border-border-subtle px-2 py-0.5 text-[11px] font-semibold text-text-muted uppercase tracking-wider shadow-sm",children:t}),o&&(0,E.jsxs)("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:[(0,E.jsx)("span",{className:"h-1 w-1 rounded-full bg-red-400 animate-pulse"}),"Required"]})]}),r&&(0,E.jsxs)("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:[(0,E.jsx)("span",{className:"font-semibold opacity-60 uppercase tracking-tighter",children:"Default"}),(0,E.jsx)("code",{className:"font-mono text-text-main font-medium",children:r})]})]}),(0,E.jsx)("div",{className:"text-sm text-text-muted leading-relaxed [&>p]:m-0 selection:bg-primary-500/30",children:n})]})}var He=w(require("react")),Lt=require("react-aria-components"),St=require("react-router-dom");var It=require("react-router-dom");function ze(e){let t=(0,It.useLocation)(),r=J();if(!r||typeof e!="string"||!r.i18n&&!r.versions)return e;let o="/docs";if(!e.startsWith(o))return e;let a=t.pathname.substring(o.length).split("/").filter(Boolean),c=r.versions?.defaultVersion,l=r.i18n?.defaultLocale,i=0;r.versions&&a.length>i&&r.versions.versions[a[i]]&&(c=a[i],i++),r.i18n&&a.length>i&&r.i18n.locales[a[i]]&&(l=a[i]);let p=e.substring(o.length).split("/").filter(Boolean),m=0,f=!1,x=!1;r.versions&&p.length>m&&r.versions.versions[p[m]]&&(f=!0,m++),r.i18n&&p.length>m&&r.i18n.locales[p[m]]&&(x=!0,m++);let P=p.slice(m),g=[];r.versions&&(f?g.push(p[0]):c&&g.push(c)),r.i18n&&(x?g.push(p[f?1:0]):l&&g.push(l)),g.push(...P);let N=`${o}/${g.join("/")}`;return N.endsWith("/")&&(N=N.slice(0,-1)),N===o?o:N}var ne=require("react"),wr=require("react/jsx-runtime"),Pr=(0,ne.createContext)({preload:()=>{},routes:[]});function Bt(){return(0,ne.use)(Pr)}var Fe=require("react/jsx-runtime"),se=He.default.forwardRef((e,t)=>{let{href:r,prefetch:o="hover",onMouseEnter:n,onFocus:a,...c}=e,l=ze(r??""),{preload:i}=Bt();return(0,Fe.jsx)(Lt.Link,{...c,ref:t,href:l,onMouseEnter:m=>{n?.(m),o==="hover"&&typeof l=="string"&&l.startsWith("/")&&i(l)},onFocus:m=>{a?.(m),o==="hover"&&typeof l=="string"&&l.startsWith("/")&&i(l)}})});se.displayName="Link";var kr=He.default.forwardRef((e,t)=>{let{href:r,end:o=!1,className:n,children:a,...c}=e,l=(0,St.useLocation)(),i=ze(r??""),d=o?l.pathname===i:l.pathname.startsWith(i),p=typeof n=="function"?n({isActive:d}):s(n,d&&"active"),m=typeof a=="function"?a({isActive:d}):a;return(0,Fe.jsx)(se,{...c,ref:t,href:r,className:p,children:m})});kr.displayName="NavLink";var Et=require("react/jsx-runtime");function Mt({to:e,children:t,className:r="",...o}){let n=e&&(e.startsWith("http://")||e.startsWith("https://")||e.startsWith("//")),a=s("text-blue-600 hover:text-blue-800 hover:underline cursor-pointer",r);return(0,Et.jsx)(se,{href:e,className:a,target:n?"_blank":void 0,rel:n?"noopener noreferrer":void 0,...o,children:t})}var ae=require("react"),Ar=require("react/jsx-runtime"),Tr=(0,ae.createContext)(void 0);function Ot(){let e=(0,ae.use)(Tr);if(e===void 0)throw new Error("useTheme must be used within a ThemeProvider");return e}var Dt=require("react/jsx-runtime");function Vt({src:e,alt:t,theme:r,...o}){let{theme:n}=Ot();return r&&r!==n?null:(0,Dt.jsx)("img",{src:e,alt:t||"",...o})}var v=require("react/jsx-runtime");function zt({title:e,props:t,className:r=""}){return(0,v.jsxs)("div",{className:s("my-6",r),children:[e&&(0,v.jsx)("h3",{className:"text-base font-bold text-text-main mb-3",children:e}),(0,v.jsx)("div",{className:"overflow-x-auto rounded-lg border border-border-subtle",children:(0,v.jsxs)("table",{className:"w-full border-collapse text-sm",children:[(0,v.jsx)("thead",{children:(0,v.jsxs)("tr",{children:[(0,v.jsx)("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"}),(0,v.jsx)("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"}),(0,v.jsx)("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"}),(0,v.jsx)("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"})]})}),(0,v.jsx)("tbody",{children:t.map((o,n)=>(0,v.jsxs)("tr",{className:"transition-colors hover:bg-bg-surface",children:[(0,v.jsxs)("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:[(0,v.jsx)("code",{className:"rounded bg-bg-surface px-1.5 py-0.5 font-mono text-xs font-bold text-primary-400",children:o.name}),o.required&&(0,v.jsx)("span",{className:"ml-1 text-red-400 font-bold",children:"*"})]}),(0,v.jsx)("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:(0,v.jsx)("code",{className:"rounded bg-bg-muted px-1.5 py-0.5 font-mono text-xs text-text-muted",children:o.type})}),(0,v.jsx)("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:o.defaultValue?(0,v.jsx)("code",{className:"rounded bg-bg-muted px-1.5 py-0.5 font-mono text-xs text-primary-400",children:o.defaultValue}):(0,v.jsx)("span",{className:"text-text-dim",children:"\u2014"})}),(0,v.jsx)("td",{className:"px-4 py-2.5 border-b border-border-subtle text-text-muted",children:o.description})]},`${o.name}-${n}`))})]})})]})}var We=require("react");function Ht(e){let{code:t,children:r,preview:o}=e,n=(0,We.useMemo)(()=>(t??(typeof r=="string"?r:"")).trim(),[t,r]),a=(0,We.useMemo)(()=>o??(typeof r!="string"?r:null),[o,r]);return{initialCode:n,previewElement:a}}var ie=require("react/jsx-runtime");function Ft(e){let{highlightedHtml:t,hideCode:r=!1,hideSandbox:o=!1,hideCopy:n=!1,sandboxOptions:a={}}=e,{initialCode:c,previewElement:l}=Ht(e);return(0,ie.jsxs)("div",{className:"my-6 overflow-hidden rounded-xl border border-border-subtle",children:[(0,ie.jsx)("div",{className:"flex items-center justify-center p-8 bg-bg-surface",children:l}),!r&&(0,ie.jsx)("div",{className:"border-t border-border-subtle",children:(0,ie.jsx)(Y,{hideSandbox:o,hideCopy:n,title:a.title,lang:"tsx",highlightedHtml:t,children:c})})]})}var Jt=require("react"),U=require("lucide-react");var Wt=require("react");var Ir=require("react-aria-components"),ge=require("lucide-react");var $t=require("react/jsx-runtime");var he=w(require("react-aria-components")),Br=require("lucide-react");var _e=require("react/jsx-runtime");var k=w(require("react-aria-components")),X=require("lucide-react");var h=require("react/jsx-runtime"),Lr=({children:e,isOpen:t,onOpenChange:r,className:o})=>(0,h.jsx)(k.ModalOverlay,{isOpen:t,onOpenChange:r,isDismissable:!0,className:s("fixed inset-0 z-100 bg-black/40 backdrop-blur-sm px-4 py-4 sm:py-20","entering:animate-in entering:fade-in exiting:animate-out exiting:fade-out"),children:(0,h.jsx)(k.Modal,{className:s("mx-auto w-full max-w-2xl overflow-hidden rounded-xl border border-border-subtle bg-bg-surface shadow-2xl ring-1 ring-black/5 outline-none","entering:animate-in entering:fade-in entering:zoom-in-95 exiting:animate-out exiting:fade-out exiting:zoom-out-95",o),children:(0,h.jsx)(k.Dialog,{className:"flex flex-col max-h-[70vh] focus:outline-none",children:e})})}),Sr=({children:e,className:t,...r})=>(0,h.jsx)("div",{className:t,children:(0,h.jsx)(k.Autocomplete,{...r,className:"flex flex-col min-h-0",children:e})}),Mr=({className:e,...t})=>(0,h.jsxs)(k.SearchField,{className:"flex items-center gap-3 border-b border-border-subtle px-4 py-4",autoFocus:!0,children:[(0,h.jsx)(X.Search,{className:"h-5 w-5 text-text-muted"}),(0,h.jsx)(k.Input,{...t,className:s("w-full bg-transparent text-lg text-text-main placeholder-text-muted outline-none",e),placeholder:"Search documentation..."}),(0,h.jsx)("div",{className:"flex items-center gap-1.5 rounded-md border border-border-subtle bg-bg-main px-1.5 py-1 text-[10px] font-medium text-text-muted",children:(0,h.jsx)("kbd",{className:"font-sans",children:"ESC"})})]}),Er=({children:e,className:t,...r})=>(0,h.jsx)(k.ListBox,{...r,className:s("flex-1 overflow-y-auto p-2 outline-none",t),children:e}),Or=({children:e,className:t,...r})=>(0,h.jsx)(k.ListBoxItem,{...r,className:s("group flex items-center gap-3 rounded-lg p-3 text-left outline-none cursor-pointer transition-colors","text-text-muted hover:bg-bg-main hover:text-text-main focus:bg-primary-500 focus:text-white selected:bg-primary-500 selected:text-white",t),children:o=>(0,h.jsxs)(h.Fragment,{children:[e,(o.isFocused||o.isSelected)&&(0,h.jsxs)("div",{className:"ml-auto opacity-50 flex items-center gap-1",children:[(0,h.jsx)("span",{className:"text-[10px]",children:"Select"}),(0,h.jsx)(X.CornerDownLeft,{size:10})]})]})}),Vr=({isHeading:e,className:t})=>(0,h.jsx)("div",{className:s("shrink-0",t),children:e?(0,h.jsx)(X.Hash,{size:18}):(0,h.jsx)(X.FileText,{size:18})}),Dr=({children:e,className:t})=>(0,h.jsx)("span",{className:s("block font-medium truncate flex-1 text-sm",t),children:e}),zr=({children:e,className:t})=>(0,h.jsx)("span",{className:s("ml-2 text-xs opacity-70 truncate hidden sm:inline group-focus:opacity-100",t),children:e}),Qn={Root:Lr,Autocomplete:Sr,Input:Mr,List:Er,Item:Object.assign(Or,{Icon:Vr,Title:Dr,Bio:zr})};var O=require("react"),Hr=w(require("scroll-into-view-if-needed"));var Gt=require("react");var _t=require("react/jsx-runtime"),ps=(0,O.createContext)(null),ms=(0,O.createContext)(null);function Fr(e){let[t,r]=(0,O.useState)({isOverflowing:!1,isAtBottom:!1});return(0,O.useEffect)(()=>{let o=e.current;if(!o)return;let n=()=>{let c=o.scrollHeight>o.clientHeight,l=o.scrollHeight-o.scrollTop<=o.clientHeight+2;r({isOverflowing:c,isAtBottom:l})};n(),o.addEventListener("scroll",n,{passive:!0}),window.addEventListener("resize",n);let a=new MutationObserver(n);return a.observe(o,{childList:!0,subtree:!0}),()=>{o.removeEventListener("scroll",n),window.removeEventListener("resize",n),a.disconnect()}},[e]),t}var Wr=({children:e,className:t,ref:r,...o})=>{let n=(0,O.useRef)(null);(0,O.useImperativeHandle)(r,()=>n.current);let{isOverflowing:a,isAtBottom:c}=Fr(n);return(0,_t.jsx)("div",{ref:n,className:s("relative overflow-y-auto boltdocs-otp-content",a&&!c&&"mask-[linear-gradient(to_bottom,black_85%,transparent_100%)]",t),...o,children:e})};Wr.displayName="OnThisPageContent";var jt=w(require("react-aria-components")),Le=require("lucide-react");var z=require("react/jsx-runtime"),$r=({children:e,className:t})=>(0,z.jsx)("nav",{className:s("grid grid-cols-1 sm:grid-cols-2 gap-4 mt-12 pt-8 border-t border-border-subtle",t),children:e}),Gr=({children:e,to:t,direction:r,className:o})=>{let n=r==="next";return(0,z.jsxs)(jt.Link,{href:t,className:s("flex group items-center p-4 rounded-xl border border-border-subtle bg-bg-surface outline-none","transition-all hover:bg-bg-main hover:border-primary-500 hover:shadow-lg","focus-visible:ring-2 focus-visible:ring-primary-500/30",n?"text-right justify-end":"text-left justify-start",o),children:[!n&&(0,z.jsx)(Le.ChevronLeft,{className:"mr-3 h-5 w-5 text-text-muted group-hover:text-primary-500 transition-transform group-hover:-translate-x-1"}),(0,z.jsx)("div",{className:"flex flex-col gap-1 flex-1",children:e}),n&&(0,z.jsx)(Le.ChevronRight,{className:"ml-3 h-5 w-5 text-text-muted group-hover:text-primary-500 transition-transform group-hover:translate-x-1"})]})},_r=({children:e,className:t})=>(0,z.jsx)("span",{className:s("text-xs font-medium uppercase tracking-wider text-text-muted",t),children:e}),jr=({children:e,className:t})=>(0,z.jsx)("span",{className:s("text-base font-bold text-text-main truncate",t),children:e}),Ur=({children:e})=>(0,z.jsx)(z.Fragment,{children:e}),xs={PageNavRoot:$r,PageNavLink:Object.assign(Gr,{Title:_r,Description:jr,Icon:Ur})};var qr=require("react/jsx-runtime");var Xr=w(require("react-aria-components")),Kr=require("lucide-react");var Ut=require("react/jsx-runtime");var je=require("react-aria-components"),Zr=require("lucide-react");var Jr=require("react/jsx-runtime");var Xt=require("react/jsx-runtime"),qt=({children:e,className:t,vertical:r=!1})=>(0,Xt.jsx)("div",{className:s("inline-flex",r?"flex-col":"flex-row",!r&&["[&>*:not(:first-child)]:-ml-px","[&>*:first-child]:rounded-r-none","[&>*:last-child]:rounded-l-none","[&>*:not(:first-child):not(:last-child)]:rounded-none",t?.includes("rounded-full")&&["[&>*:first-child]:rounded-l-full","[&>*:last-child]:rounded-r-full"],t?.includes("rounded-xl")&&["[&>*:first-child]:rounded-l-xl","[&>*:last-child]:rounded-r-xl"],t?.includes("rounded-lg")&&["[&>*:first-child]:rounded-l-lg","[&>*:last-child]:rounded-r-lg"]],r&&["[&>*:not(:first-child)]:-mt-px","[&>*:first-child]:rounded-b-none","[&>*:last-child]:rounded-t-none","[&>*:not(:first-child):not(:last-child)]:rounded-none",t?.includes("rounded-full")&&["[&>*:first-child]:rounded-t-full","[&>*:last-child]:rounded-b-full"]],t),children:e});var de=require("lucide-react"),Zt=w(require("react")),A=w(require("react-aria-components"));var ce=w(require("react-aria-components"));var le=require("react/jsx-runtime"),Kt=({children:e,className:t,showArrow:r,...o})=>(0,le.jsxs)(ce.Popover,{offset:8,...o,className:ce.composeRenderProps(t,n=>s("z-50 overflow-auto rounded-xl border border-border-subtle bg-bg-surface/80 shadow-xl backdrop-blur-md outline-none","entering:animate-in entering:fade-in entering:zoom-in-95 exiting:animate-out exiting:fade-out exiting:zoom-out-95 fill-mode-forwards",n)),children:[r&&(0,le.jsx)(ce.OverlayArrow,{className:"group",children:(0,le.jsx)("svg",{viewBox:"0 0 12 12",className:"block h-3 w-3 fill-bg-surface/80 stroke-border-subtle group-placement-bottom:rotate-180 group-placement-left:-rotate-90 group-placement-right:rotate-90","aria-hidden":"true",children:(0,le.jsx)("path",{d:"M0 0 L6 6 L12 0"})})}),e]});var B=require("react/jsx-runtime");function $e(e){let[t,r]=Zt.default.Children.toArray(e.children).slice(0,2);return(0,B.jsxs)(A.MenuTrigger,{...e,children:[t,(0,B.jsx)(Kt,{placement:e.placement,className:"min-w-[200px]",children:r})]})}function Ge(e){return(0,B.jsx)(A.Menu,{...e,className:A.composeRenderProps(e.className,t=>s("p-1.5 outline-none max-h-[inherit] overflow-auto",t))})}function Ie(e){let t=e.textValue||(typeof e.children=="string"?e.children:void 0);return(0,B.jsx)(A.MenuItem,{...e,textValue:t,className:A.composeRenderProps(e.className,(r,{isFocused:o,isPressed:n,isDisabled:a})=>s("group relative flex flex-row items-center gap-2.5 px-3 py-1.5 rounded-lg outline-none cursor-default transition-all duration-200","text-text-main text-[0.8125rem]",o&&"bg-primary-500/10 text-primary-600 shadow-sm",n&&"scale-[0.98] bg-primary-500/15",a&&"opacity-40 grayscale pointer-events-none",r)),children:A.composeRenderProps(e.children,(r,{selectionMode:o,isSelected:n,hasSubmenu:a})=>(0,B.jsxs)(B.Fragment,{children:[o!=="none"&&(0,B.jsxs)("span",{className:"flex items-center w-4 h-4 shrink-0 justify-center",children:[n&&o==="multiple"&&(0,B.jsx)(de.Check,{className:"w-3.5 h-3.5 stroke-[2.5px] text-primary-500 animate-in zoom-in-50 duration-200"}),n&&o==="single"&&(0,B.jsx)(de.Dot,{className:"w-6 h-6 text-primary-500 animate-in zoom-in-50 duration-200"})]}),(0,B.jsx)("div",{className:"flex-1 flex flex-row items-center gap-2.5 truncate font-medium",children:r}),a&&(0,B.jsx)(de.ChevronRight,{className:"w-4 h-4 ml-auto text-text-muted group-focused:text-primary-500/70 transition-colors"})]}))})}var Be=require("react-aria-components");var R=require("react/jsx-runtime"),Qr=e=>{let[t,r]=(0,Jt.useState)(!1);return{copied:t,handleCopy:()=>{navigator.clipboard.writeText(e),r(!0),setTimeout(()=>r(!1),2e3)},handleOpenRaw:()=>{let a=new Blob([e],{type:"text/plain;charset=utf-8"}),c=URL.createObjectURL(a);window.open(c,"_blank")}}};function Qt({content:e,mdxRaw:t,config:r}){let o=t||e||"",{copied:n,handleCopy:a,handleOpenRaw:c}=Qr(o),l=r!==!1,i=typeof r=="object"&&r.text||"Copy Markdown";return!l||!o?null:(0,R.jsx)("div",{className:"relative inline-flex z-100 flex-shrink-0 w-max translate-y-0 active:translate-y-px transition-transform duration-200",children:(0,R.jsxs)(qt,{className:"rounded-xl border border-border-subtle bg-bg-surface/40 backdrop-blur-md transition-all duration-300 hover:border-primary-500/50 hover:shadow-lg hover:shadow-primary-500/5 group overflow-hidden",children:[(0,R.jsx)(Z,{variant:"ghost",onPress:a,icon:n?(0,R.jsx)(U.Check,{size:16}):(0,R.jsx)(U.Copy,{size:16}),iconPosition:"left",className:s("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}),(0,R.jsxs)($e,{placement:"bottom end",children:[(0,R.jsx)(Z,{variant:"ghost",isIconOnly:!0,icon:(0,R.jsx)(U.ChevronDown,{size:14}),className:s("px-3.5 h-9 border-l border-border-subtle/50 text-text-muted rounded-none bg-transparent shrink-0","transition-all duration-300 hover:bg-primary-500/5 hover:text-primary-500")}),(0,R.jsxs)(Ge,{className:"w-52",children:[(0,R.jsxs)(Ie,{onAction:a,className:"flex flex-row items-start gap-2.5 group",children:[(0,R.jsx)(U.Copy,{size:16,className:"w-4 h-4 shrink-0 mt-0.5 transition-transform duration-200 group-hover:-translate-y-0.5 text-text-muted group-hover:text-primary-500"}),(0,R.jsx)("span",{className:"font-medium text-[0.8125rem]",children:"Copy Markdown"})]}),(0,R.jsxs)(Ie,{onAction:c,className:"flex flex-row items-start gap-2.5 group",children:[(0,R.jsx)(U.ExternalLink,{size:16,className:"w-4 h-4 shrink-0 mt-0.5 transition-transform duration-200 group-hover:-translate-y-0.5 text-text-muted group-hover:text-primary-500"}),(0,R.jsx)("span",{className:"font-medium text-[0.8125rem]",children:"View as Markdown"})]})]})]})]})})}0&&(module.exports={Admonition,Badge,Button,Card,Cards,Caution,CodeBlock,ComponentPreview,ComponentProps,CopyMarkdown,Danger,Field,FileTree,Image,Important,InfoBox,Link,List,Note,Tab,Table,Tabs,Tip,Video,Warning});
1
+ "use strict";var Yt=Object.create;var ye=Object.defineProperty;var er=Object.getOwnPropertyDescriptor;var tr=Object.getOwnPropertyNames;var rr=Object.getPrototypeOf,or=Object.prototype.hasOwnProperty;var nr=(e,t)=>{for(var r in t)ye(e,r,{get:t[r],enumerable:!0})},Ue=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of tr(t))!or.call(e,n)&&n!==r&&ye(e,n,{get:()=>t[n],enumerable:!(o=er(t,n))||o.enumerable});return e};var w=(e,t,r)=>(r=e!=null?Yt(rr(e)):{},Ue(t||!e||!e.__esModule?ye(r,"default",{value:e,enumerable:!0}):r,e)),sr=e=>Ue(ye({},"__esModule",{value:!0}),e);var Yr={};nr(Yr,{Admonition:()=>j,Badge:()=>lt,Button:()=>Ze,Card:()=>ut,Cards:()=>mt,Caution:()=>Nt,CodeBlock:()=>Y,ComponentPreview:()=>Ft,ComponentProps:()=>zt,CopyMarkdown:()=>Qt,Danger:()=>vt,Field:()=>At,FileTree:()=>wt,Image:()=>Vt,Important:()=>Ct,InfoBox:()=>yt,Link:()=>Mt,List:()=>Rt,Note:()=>xt,Tab:()=>nt,Table:()=>Tt,Tabs:()=>st,Tip:()=>gt,Video:()=>at,Warning:()=>ht});module.exports=sr(Yr);var Ne=w(require("react-aria-components"));var qe=require("clsx"),Xe=require("tailwind-merge");function s(...e){return(0,Xe.twMerge)((0,qe.clsx)(e))}var Ke=require("class-variance-authority"),H=require("react/jsx-runtime"),Ce=(0,Ke.cva)("flex flex-row items-center justify-center w-auto font-semibold tracking-tight no-underline whitespace-nowrap select-none outline-none transition-all duration-200 cursor-pointer pressed:scale-[0.97] hover:-translate-y-px leading-none",{variants:{variant:{primary:"bg-primary-500 text-white shadow-md hover:brightness-110 hover:shadow-lg",secondary:"bg-bg-surface text-text-main border border-border-subtle hover:bg-bg-muted hover:border-border-strong",outline:"bg-transparent text-text-main border border-border-strong hover:bg-bg-surface hover:border-primary-500",ghost:"bg-transparent text-text-muted hover:bg-bg-surface hover:text-text-main",danger:"bg-[var(--color-danger-500)]/10 text-[var(--color-danger-500)] border border-[var(--color-danger-500)]/20 hover:bg-[var(--color-danger-500)]/15",success:"bg-[var(--color-success-500)]/10 text-[var(--color-success-500)] border border-[var(--color-success-500)]/20 hover:bg-[var(--color-success-500)]/15",warning:"bg-[var(--color-warning-500)]/10 text-[var(--color-warning-500)] border border-[var(--color-warning-500)]/20 hover:bg-[var(--color-warning-500)]/15",info:"bg-[var(--color-info-500)]/10 text-[var(--color-info-500)] border border-[var(--color-info-500)]/20 hover:bg-[var(--color-info-500)]/15",subtle:"bg-primary-500/10 text-primary-500 hover:bg-primary-500/20",link:"bg-transparent text-primary-500 !p-0 !min-h-0 hover:underline"},size:{sm:"min-h-8 px-3.5 text-[0.8125rem] gap-1.5",md:"min-h-10 px-5 text-[0.9375rem] gap-2",lg:"min-h-12 px-7 text-[1.05rem] gap-2.5"},rounded:{none:"rounded-none",sm:"rounded-sm",md:"rounded-md",lg:"rounded-lg",full:"rounded-full"},iconSize:{sm:"w-8 h-8 p-0",md:"w-10 h-10 p-0",lg:"w-12 h-12 p-0"},disabled:{true:"opacity-50 cursor-not-allowed pointer-events-none",false:null}},defaultVariants:{variant:"primary",size:"md",rounded:"md"}}),Z=({href:e,icon:t,iconPosition:r="left",isIconOnly:o,children:n,className:a,variant:c,size:l,rounded:i,iconSize:d,disabled:p,...m})=>{let f=o||!n&&!!t,x=f?(0,H.jsx)("span",{className:"inline-flex items-center justify-center [&>svg]:w-[1.2rem] [&>svg]:h-[1.2rem]",children:t}):(0,H.jsxs)(H.Fragment,{children:[t&&r==="left"&&(0,H.jsx)("span",{className:"inline-flex items-center shrink-0 [&>svg]:w-[1.1rem] [&>svg]:h-[1.1rem]",children:t}),(0,H.jsx)("span",{className:"flex items-center",children:n}),t&&r==="right"&&(0,H.jsx)("span",{className:"inline-flex items-center shrink-0 [&>svg]:w-[1.1rem] [&>svg]:h-[1.1rem]",children:t})]});return e?(0,H.jsx)(Ne.Link,{href:e,className:s(Ce({variant:c,size:l,rounded:i,iconSize:f?d:void 0,disabled:p}),a),...m,children:x}):(0,H.jsx)(Ne.Button,{className:s(Ce({variant:c,size:l,rounded:i,iconSize:f?d:void 0,disabled:p}),a),...m,children:x})};var Je=require("react/jsx-runtime"),Ze=({className:e,variant:t,size:r,rounded:o,iconSize:n,disabled:a,...c})=>(0,Je.jsx)(Z,{className:s("group",Ce({variant:t,size:r,rounded:o,iconSize:n,disabled:a,className:e})),...c});var Pe=w(require("react-aria-components")),we=require("lucide-react");var Re=require("react"),ar=(0,Re.createContext)(null);function J(){let e=(0,Re.use)(ar);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e}var Se=require("codesandbox/lib/api/define.js");function Qe(e){let t=e.files||{},r=e.dependencies||{},o=e.devDependencies||{},n=e.title||"codesandbox-project",a=e.description||"Generic Sandbox",c={};for(let[l,i]of Object.entries(t)){let d=typeof i.content=="object"?JSON.stringify(i.content,null,2):i.content;c[l]={content:d,isBinary:i.isBinary??!1}}if(!c["package.json"]){let i=e.template==="vite"||!!o.vite||!!o["@vitejs/plugin-react"]?{dev:"vite",build:"vite build",preview:"vite preview"}:{start:"node index.js"};c["package.json"]={content:JSON.stringify({private:!0,name:n,description:a,type:"module",version:"1.0.0",scripts:e.scripts||i,dependencies:r,devDependencies:o},null,2),isBinary:!1}}return c}function ir(e){let t=Qe(e),r=(0,Se.getParameters)({files:t}),o=new URLSearchParams({parameters:r,installDependencies:"true"});return e.entry&&o.set("file",`/${e.entry}`),{parameters:r,url:`https://codesandbox.io/api/v1/sandboxes/define?${o.toString()}`,options:e}}function Ye(e){if(typeof window>"u")return ir(e);let t=Qe(e),r=(0,Se.getParameters)({files:t}),o=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)},c=new URLSearchParams({file:`/${o}`,eslint:"0",codemirror:"1",installDependencies:"true"});return a("query",c.toString()),a("parameters",r),document.body.appendChild(n),n.submit(),document.body.removeChild(n),{parameters:r,url:`https://codesandbox.io/api/v1/sandboxes/define?parameters=${r}`,options:e}}var et=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}};var F=require("react");function tt(e){let{title:t,sandbox:r}=e,[o,n]=(0,F.useState)(!1),[a,c]=(0,F.useState)(!1),[l,i]=(0,F.useState)(!1),d=(0,F.useRef)(null),p=J(),m=(0,F.useCallback)(async()=>{let x=d.current?.textContent??"";et(x),n(!0),setTimeout(()=>n(!1),2e3)},[]),f=(0,F.useCallback)(()=>{let x=d.current?.textContent??"",P=p?.integrations?.sandbox?.config||{},g=typeof r=="object"?r:P,N=g.entry||"src/App.tsx";Ye({title:t??"Code Snippet",...g,files:{...g.files,[N]:{content:x}}})},[t,p,r]);return(0,F.useEffect)(()=>{let x=d.current?.textContent?.length??0;i(x>120)},[e.children,e.highlightedHtml]),{copied:o,isExpanded:a,setIsExpanded:c,isExpandable:l,preRef:d,handleCopy:m,handleSandbox:f,shouldTruncate:l&&!a}}var pe=require("react/jsx-runtime");function lr(e){let{size:t=20,...r}=e;return{...r,width:t,height:t}}var rt=e=>(0,pe.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",...lr(e),children:[(0,pe.jsx)("title",{children:"CodeSandbox"}),(0,pe.jsx)("path",{d:"M0 24h24V0H0v2.455h21.546v19.09H2.454V0H0Z"})]});var Q=w(require("react-aria-components"));var V=require("react/jsx-runtime"),dr=({className:e,children:t,...r})=>(0,V.jsx)(Q.Tooltip,{...r,offset:8,className:o=>s("group z-50 overflow-visible rounded-md bg-bg-surface/90 px-2.5 py-1.5 text-xs font-medium text-text-main shadow-lg backdrop-blur-md ring-1 ring-border-subtle outline-hidden select-none","data-entering:animate-in data-entering:fade-in data-entering:zoom-in-95 data-entering:duration-100","data-exiting:animate-out data-exiting:fade-out data-exiting:zoom-out-95 data-exiting:duration-75","data-[placement=top]:slide-in-from-bottom-1","data-[placement=bottom]:slide-in-from-top-1","data-[placement=left]:slide-in-from-right-1","data-[placement=right]:slide-in-from-left-1",typeof e=="function"?e(o):e),children:o=>(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(Q.OverlayArrow,{children:(0,V.jsxs)("svg",{width:8,height:8,viewBox:"0 0 8 8",className:"fill-bg-surface/90 stroke-border-subtle group-data-[placement=bottom]:rotate-180 group-data-[placement=left]:-rotate-90 group-data-[placement=right]:rotate-90",children:[(0,V.jsx)("title",{children:"Arrow"}),(0,V.jsx)("path",{d:"M0 0 L4 4 L8 0"})]})}),typeof t=="function"?t(o):t]})}),Me=({content:e,children:t,delay:r=500,closeDelay:o=0,...n})=>(0,V.jsxs)(Q.TooltipTrigger,{delay:r,closeDelay:o,children:[t,(0,V.jsx)(dr,{...n,children:e})]});var T=require("react/jsx-runtime");function Y(e){let{children:t,sandbox:r,hideSandbox:o=!0,hideCopy:n=!1,highlightedHtml:a,...c}=e,d=!!J()?.integrations?.sandbox?.enable&&!o,{copied:p,isExpanded:m,setIsExpanded:f,isExpandable:x,preRef:P,handleCopy:g,handleSandbox:N,shouldTruncate:K}=tt(e);return(0,T.jsxs)("div",{className:s("group relative my-6 overflow-hidden rounded-lg border border-border-subtle bg-(--color-code-bg)",K&&"[&>pre]:max-h-[250px] [&>pre]:overflow-hidden"),children:[(0,T.jsxs)("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:[d&&(0,T.jsx)(Me,{content:"Open in CodeSandbox",children:(0,T.jsx)(Pe.Button,{onPress:N,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:(0,T.jsx)(rt,{size:20})})}),!n&&(0,T.jsx)(Me,{content:p?"Copied!":"Copy code",children:(0,T.jsx)(Pe.Button,{onPress:g,className:s("grid place-items-center w-8 h-8 bg-transparent outline-none cursor-pointer transition-all duration-200 hover:scale-115 active:scale-95 [&>svg]:w-5 [&>svg]:h-5 [&>svg]:stroke-2",p?"text-emerald-400":"text-text-muted hover:text-text-main"),"aria-label":"Copy code",children:p?(0,T.jsx)(we.Check,{size:20}):(0,T.jsx)(we.Copy,{size:20})})})]}),a?(0,T.jsx)("div",{ref:P,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}}):(0,T.jsx)("pre",{ref:P,className:"m-0! rounded-none! border-none! bg-inherit! font-mono text-[0.8125rem] leading-[1.7]",...c,children:t}),x&&(0,T.jsx)("div",{className:s(K?"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:(0,T.jsx)(Pe.Button,{onPress:()=>f(!m),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:m?"Show less":"Expand code"})})]})}var ee=require("react"),q=w(require("react-aria-components"));var _=require("react");function ot({initialIndex:e=0,tabs:t}){let r=t[e]?.props.disabled?t.findIndex(d=>!d.props.disabled):e,[o,n]=(0,_.useState)(r===-1?0:r),a=(0,_.useRef)([]),[c,l]=(0,_.useState)({opacity:0,transform:"translateX(0)",width:0});(0,_.useEffect)(()=>{let d=a.current[o];d&&l({opacity:1,width:d.offsetWidth,transform:`translateX(${d.offsetLeft}px)`})},[o,t]);let i=(0,_.useCallback)(d=>{let p=0;if(d.key==="ArrowRight"?p=1:d.key==="ArrowLeft"&&(p=-1),p!==0){let m=(o+p+t.length)%t.length;for(;t[m].props.disabled&&m!==o;)m=(m+p+t.length)%t.length;m!==o&&!t[m].props.disabled&&(n(m),a.current[m]?.focus())}},[o,t]);return{active:o,setActive:n,tabRefs:a,indicatorStyle:c,handleKeyDown:i}}var Ee=require("class-variance-authority"),L=require("react/jsx-runtime"),pr=(0,Ee.cva)("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"}}),mr=(0,Ee.cva)("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 nt({children:e}){let t=typeof e=="string"?(0,L.jsx)(Y,{className:"language-bash",children:(0,L.jsx)("code",{children:e.trim()})}):e;return(0,L.jsx)("div",{className:"py-4",children:t})}function st({defaultIndex:e=0,children:t}){let r=(0,ee.useMemo)(()=>ee.Children.toArray(t).filter(l=>(0,ee.isValidElement)(l)&&l.props?.label),[t]),{active:o,setActive:n,tabRefs:a,indicatorStyle:c}=ot({initialIndex:e,tabs:r});return(0,L.jsx)("div",{className:"my-8 w-full group/tabs",children:(0,L.jsxs)(q.Tabs,{selectedKey:o.toString(),onSelectionChange:l=>n(Number(l)),className:"w-full",children:[(0,L.jsxs)(q.TabList,{"aria-label":"Content Tabs",className:s(pr()),children:[r.map((l,i)=>{let{label:d,icon:p,disabled:m}=l.props,f=i.toString();return(0,L.jsxs)(q.Tab,{id:f,isDisabled:m,ref:x=>{a.current[i]=x},className:({isSelected:x,isDisabled:P})=>s(mr({isActive:x,isDisabled:P})),children:[!!p&&(0,L.jsx)("span",{className:"shrink-0 [&>svg]:w-4 [&>svg]:h-4",children:p}),(0,L.jsx)("span",{children:d})]},f)}),(0,L.jsx)("div",{className:"absolute bottom-0 h-0.5 bg-primary-500 transition-all duration-300 ease-in-out pointer-events-none",style:c,"aria-hidden":"true"})]}),r.map((l,i)=>(0,L.jsx)(q.TabPanel,{id:i.toString(),children:r[i]},i))]})})}var te=require("react"),me=require("react/jsx-runtime");function at({src:e,poster:t,alt:r,children:o,controls:n,preload:a="metadata",...c}){let l=(0,te.useRef)(null),[i,d]=(0,te.useState)(!1);return(0,te.useEffect)(()=>{let p=l.current;if(!p)return;let m=new IntersectionObserver(([f])=>{f.isIntersecting&&(d(!0),m.disconnect())},{rootMargin:"200px"});return m.observe(p),()=>m.disconnect()},[]),(0,me.jsx)("div",{ref:l,className:"my-6 overflow-hidden rounded-lg border border-border-subtle",children:i?(0,me.jsxs)("video",{className:"block w-full h-auto",src:e,poster:t,controls:!0,preload:a,playsInline:!0,...c,children:[o,"Your browser does not support the video tag."]}):(0,me.jsx)("div",{className:"aspect-video bg-bg-surface animate-pulse",role:"img","aria-label":r||"Video"})})}var it=require("class-variance-authority"),ct=require("react/jsx-runtime"),ur=(0,it.cva)("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:r="",...o}){return(0,ct.jsx)("span",{className:s(ur({variant:e}),r),...o,children:t})}var ue=require("react"),dt=w(require("react-aria-components"));var pt=require("class-variance-authority"),S=require("react/jsx-runtime"),fr=(0,pt.cva)("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 mt({cols:e=3,children:t,className:r="",...o}){return(0,S.jsx)("div",{className:s(fr({cols:e}),r),...o,children:t})}function ut({title:e,icon:t,href:r,children:o,className:n="",...a}){let c=(0,ue.useRef)(null),l=(0,ue.useRef)(null),i=(0,ue.useCallback)(m=>{let f=c.current||l.current;if(!f)return;let{left:x,top:P}=f.getBoundingClientRect();f.style.setProperty("--x",`${m.clientX-x}px`),f.style.setProperty("--y",`${m.clientY-P}px`)},[]),d=(0,S.jsxs)(S.Fragment,{children:[(0,S.jsx)("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&&(0,S.jsx)("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}),(0,S.jsxs)("div",{className:"space-y-1.5",children:[e&&(0,S.jsx)("h3",{className:"text-sm font-bold text-text-main",children:e}),o&&(0,S.jsx)("div",{className:"text-sm text-text-muted leading-relaxed",children:o})]})]}),p=s("group relative block rounded-xl border border-border-subtle bg-bg-surface p-5 outline-none overflow-hidden","transition-all duration-200 hover:border-primary-500/40 hover:shadow-lg hover:shadow-primary-500/5","focus-visible:ring-2 focus-visible:ring-primary-500/30",n);return r?(0,S.jsx)(dt.Link,{ref:l,href:r,className:s(p,"no-underline cursor-pointer"),onMouseMove:i,...a,children:d}):(0,S.jsx)("div",{ref:c,role:"presentation",className:p,onMouseMove:i,...a,children:d})}var I=require("lucide-react");var bt=require("class-variance-authority"),y=require("react/jsx-runtime"),br={note:(0,y.jsx)(I.Bookmark,{size:18}),tip:(0,y.jsx)(I.Lightbulb,{size:18}),info:(0,y.jsx)(I.Info,{size:18}),warning:(0,y.jsx)(I.AlertTriangle,{size:18}),danger:(0,y.jsx)(I.ShieldAlert,{size:18}),important:(0,y.jsx)(I.Flame,{size:18}),caution:(0,y.jsx)(I.Zap,{size:18})},xr={note:"Note",tip:"Tip",info:"Info",warning:"Warning",danger:"Danger",important:"Important",caution:"Caution"},ft=(0,bt.cva)("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 j({type:e="note",title:t,children:r,className:o="",...n}){return(0,y.jsxs)("div",{className:s(ft({type:e}),o),role:e==="warning"||e==="danger"?"alert":"note",...n,children:[(0,y.jsxs)("div",{className:"flex items-center flex-row gap-2 mb-2",children:[(0,y.jsx)("span",{className:s("shrink-0",ft({type:e})),children:br[e]}),(0,y.jsx)("span",{className:"text-sm font-bold tracking-tight text-text-main",children:t||xr[e]})]}),(0,y.jsx)("div",{className:"text-sm text-text-muted leading-relaxed [&>p]:m-0 [&>p]:mb-2 [&>p:last-child]:mb-0",children:r})]})}var xt=e=>(0,y.jsx)(j,{type:"note",...e}),gt=e=>(0,y.jsx)(j,{type:"tip",...e}),ht=e=>(0,y.jsx)(j,{type:"warning",...e}),vt=e=>(0,y.jsx)(j,{type:"danger",...e}),yt=e=>(0,y.jsx)(j,{type:"info",...e}),Ct=e=>(0,y.jsx)(j,{type:"important",...e}),Nt=e=>(0,y.jsx)(j,{type:"caution",...e});var ke=require("react"),re=require("lucide-react");var Te=require("class-variance-authority"),W=require("react/jsx-runtime"),gr=(0,Te.cva)("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}}),hr=(0,Te.cva)("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}}),vr=(0,Te.cva)("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 yr({icon:e,children:t,variant:r,dense:o}){return(0,W.jsxs)("li",{className:s(hr({variant:r,dense:o})),children:[e&&(0,W.jsx)("span",{className:s(vr({variant:r==="bubble"?"bubble":"default"})),children:e}),(0,W.jsx)("div",{className:"flex-1 text-text-muted group-hover:text-text-main transition-colors",children:t})]})}var Cr={checked:e=>(0,W.jsx)(re.Check,{size:14,className:s("text-emerald-500 shrink-0",e)}),arrow:e=>(0,W.jsx)(re.ChevronRight,{size:14,className:s("text-primary-400 shrink-0",e)}),bubble:e=>(0,W.jsx)(re.Circle,{size:6,fill:"currentColor",className:s("text-primary-500 shrink-0",e)}),default:()=>null,number:()=>null};function Rt({variant:e="default",cols:t=1,dense:r=!1,children:o,className:n,...a}){let c=t!==void 0&&Number(t)>1,l=Cr[e],i=gr({variant:e,cols:t,dense:r,isGrid:c,className:n}),d=e==="number"?"ol":"ul";return e==="default"||e==="number"?(0,W.jsx)(d,{className:i,...a,children:o}):(0,W.jsx)("ul",{className:i,...a,children:ke.Children.map(o,p=>{if(!(0,ke.isValidElement)(p))return p;let m=p,f=m.type==="li"?m.props.children:m.props.children||p;return(0,W.jsx)(yr,{icon:l(),variant:e,dense:r,children:f})})})}var $=require("react"),G=w(require("react-aria-components")),D=require("lucide-react");var C=require("react/jsx-runtime"),fe=16,be=2,Oe={CODE:/\.(ts|tsx|js|jsx|json|mjs|cjs|astro|vue|svelte)$/i,TEXT:/\.(md|mdx|txt)$/i,IMAGE:/\.(png|jpg|jpeg|svg|gif)$/i};function De(e){return typeof e=="string"?e:typeof e=="number"?e.toString():Array.isArray(e)?e.map(De).join(""):(0,$.isValidElement)(e)&&e.props&&typeof e.props=="object"&&"children"in e.props?De(e.props.children):""}function Nr(e,t){let r=e.toLowerCase(),o="shrink-0 transition-colors duration-200";if(t)return(0,C.jsx)(D.Folder,{size:fe,strokeWidth:be,className:s(o,"text-primary-400"),fill:"currentColor",fillOpacity:.15});let n=s(o,"text-text-dim group-hover:text-text-main");return Oe.CODE.test(r)?(0,C.jsx)(D.FileCode,{size:fe,strokeWidth:be,className:n}):Oe.TEXT.test(r)?(0,C.jsx)(D.FileText,{size:fe,strokeWidth:be,className:n}):Oe.IMAGE.test(r)?(0,C.jsx)(D.FileImage,{size:fe,strokeWidth:be,className:n}):(0,C.jsx)(D.File,{size:fe,strokeWidth:be,className:n})}function Ve(e,t){if(!(0,$.isValidElement)(e))return!1;let r=e.type;if(typeof r=="string")return r===t;if(typeof r=="function")return r.name===t||r.name?.toLowerCase()===t;let o=e.props;return o?.originalType===t||o?.mdxType===t}function Rr(e){let t=e.match(/\s+(\/\/|#)\s+(.*)$/);return t?{name:e.slice(0,t.index).trim(),comment:t[2]}:{name:e.trim()}}function Ae(e,t="root"){if(!(0,$.isValidElement)(e))return[];let r=[];if(Ve(e,"ul"))return $.Children.forEach(e.props.children,(o,n)=>{r.push(...Ae(o,`${t}-${n}`))}),r;if(Ve(e,"li")){let o=$.Children.toArray(e.props.children),n=o.findIndex(P=>Ve(P,"ul")),a=n!==-1,c=a?o.slice(0,n):o,l=a?o.slice(n):[],i=De(c),{name:d,comment:p}=Rr(i),m=d.endsWith("/"),f=m?d.slice(0,-1):d,x=a||m;return r.push({id:`${t}-${f}`,name:f,comment:p,isFolder:x,children:a?Ae(l[0],`${t}-${f}`):void 0}),r}return e.props&&typeof e.props=="object"&&"children"in e.props&&$.Children.forEach(e.props.children,(o,n)=>{r.push(...Ae(o,`${t}-${n}`))}),r}function Pt({item:e}){return(0,C.jsxs)(G.TreeItem,{id:e.id,textValue:e.name,className:"outline-none group focus-visible:ring-2 focus-visible:ring-primary-500/30 rounded-md",children:[(0,C.jsx)(G.TreeItemContent,{children:({isExpanded:t,hasChildItems:r})=>(0,C.jsxs)("div",{className:"flex items-center gap-2 py-1 px-1.5 rounded-md transition-colors hover:bg-primary-500/5 cursor-pointer",children:[(0,C.jsx)("div",{style:{width:"calc((var(--tree-item-level) - 1) * 1rem)"},className:"shrink-0"}),r?(0,C.jsx)(G.Button,{slot:"chevron",className:"outline-none text-text-dim hover:text-primary-400 p-0.5 rounded transition-colors",children:(0,C.jsx)(D.ChevronRight,{size:14,strokeWidth:3,className:s("transition-transform duration-200",t&&"rotate-90")})}):(0,C.jsx)("div",{className:"w-[18px]"}),Nr(e.name,e.isFolder),(0,C.jsx)("span",{className:s("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&&(0,C.jsxs)("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&&(0,C.jsx)(G.Collection,{items:e.children,children:t=>(0,C.jsx)(Pt,{item:t})})]})}function wt({children:e}){let t=(0,$.useMemo)(()=>Ae(e),[e]);return(0,C.jsx)("div",{className:"my-8",children:(0,C.jsx)(G.Tree,{items:t,"aria-label":"File Tree",className:s("rounded-xl border border-border-subtle bg-bg-surface/50 p-4 font-mono text-sm shadow-sm backdrop-blur-sm outline-none","max-h-[500px] overflow-y-auto scrollbar-thin scrollbar-thumb-border-subtle","focus-visible:ring-2 focus-visible:ring-primary-500/20"),children:r=>(0,C.jsx)(Pt,{item:r})})})}var xe=w(require("react-aria-components"));var oe=require("react");function kt({data:e,sortable:t=!1,paginated:r=!1,pageSize:o=10}){let[n,a]=(0,oe.useState)(null),[c,l]=(0,oe.useState)(1),i=(0,oe.useMemo)(()=>{if(!e)return[];let f=[...e];return t&&n!==null&&f.sort((x,P)=>{let g=x[n.key],N=P[n.key],K=typeof g=="string"?g:"",ve=typeof N=="string"?N:"";return K<ve?n.direction==="asc"?-1:1:K>ve?n.direction==="asc"?1:-1:0}),f},[e,n,t]),d=Math.ceil(i.length/o),p=(0,oe.useMemo)(()=>{if(!r)return i;let f=(c-1)*o;return i.slice(f,f+o)},[i,r,c,o]);return{sortConfig:n,currentPage:c,setCurrentPage:l,totalPages:d,paginatedData:p,requestSort:f=>{if(!t)return;let x="asc";n&&n.key===f&&n.direction==="asc"&&(x="desc"),a({key:f,direction:x})}}}var M=require("lucide-react");var b=require("react/jsx-runtime");function Tt({headers:e,data:t,children:r,className:o="",sortable:n=!1,paginated:a=!1,pageSize:c=10}){let{sortConfig:l,currentPage:i,setCurrentPage:d,totalPages:p,paginatedData:m,requestSort:f}=kt({data:t,sortable:n,paginated:a,pageSize:c}),x=g=>n?l?.key!==g?(0,b.jsx)(M.ChevronDown,{size:14,className:"ml-1 opacity-30"}):l.direction==="asc"?(0,b.jsx)(M.ChevronUp,{size:14,className:"ml-1 text-primary-400"}):(0,b.jsx)(M.ChevronDown,{size:14,className:"ml-1 text-primary-400"}):null,P=r||(0,b.jsxs)(b.Fragment,{children:[e&&(0,b.jsx)("thead",{children:(0,b.jsx)("tr",{children:e.map((g,N)=>(0,b.jsx)("th",{onClick:()=>f(N),className:s("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:(0,b.jsxs)("div",{className:"flex items-center",children:[g,x(N)]})},N))})}),m&&(0,b.jsx)("tbody",{children:m.map((g,N)=>(0,b.jsx)("tr",{className:"transition-colors hover:bg-bg-surface",children:g.map((K,ve)=>(0,b.jsx)("td",{className:"px-3 py-2 border-b border-border-subtle text-sm text-text-muted",children:K},ve))},N))})]});return(0,b.jsxs)("div",{className:s("my-6 rounded-lg border border-border-subtle overflow-hidden",o),children:[(0,b.jsx)("div",{className:"overflow-x-auto",children:(0,b.jsx)("table",{className:"w-full border-collapse text-sm",children:P})}),a&&p>1&&(0,b.jsxs)("div",{className:"flex items-center justify-between border-t border-border-subtle px-4 py-3",children:[(0,b.jsxs)("span",{className:"text-xs text-text-muted",children:["Page ",i," of ",p]}),(0,b.jsxs)("div",{className:"flex items-center gap-1",children:[(0,b.jsx)(xe.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:(0,b.jsx)(M.ChevronsLeft,{size:16})}),(0,b.jsx)(xe.Button,{onPress:()=>d(g=>Math.max(g-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:(0,b.jsx)(M.ChevronLeft,{size:16})}),(0,b.jsx)(xe.Button,{onPress:()=>d(g=>Math.min(g+1,p)),isDisabled:i===p,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:(0,b.jsx)(M.ChevronRight,{size:16})}),(0,b.jsx)(xe.Button,{onPress:()=>d(p),isDisabled:i===p,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:(0,b.jsx)(M.ChevronsRight,{size:16})})]})]})]})}var E=require("react/jsx-runtime");function At({name:e,type:t,defaultValue:r,required:o=!1,children:n,id:a,className:c=""}){return(0,E.jsxs)("article",{className:s("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",c),id:a,children:[(0,E.jsxs)("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between mb-4",children:[(0,E.jsxs)("div",{className:"flex flex-wrap items-center gap-2.5",children:[(0,E.jsx)("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&&(0,E.jsx)("span",{className:"rounded-md bg-bg-muted/80 border border-border-subtle px-2 py-0.5 text-[11px] font-semibold text-text-muted uppercase tracking-wider shadow-sm",children:t}),o&&(0,E.jsxs)("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:[(0,E.jsx)("span",{className:"h-1 w-1 rounded-full bg-red-400 animate-pulse"}),"Required"]})]}),r&&(0,E.jsxs)("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:[(0,E.jsx)("span",{className:"font-semibold opacity-60 uppercase tracking-tighter",children:"Default"}),(0,E.jsx)("code",{className:"font-mono text-text-main font-medium",children:r})]})]}),(0,E.jsx)("div",{className:"text-sm text-text-muted leading-relaxed [&>p]:m-0 selection:bg-primary-500/30",children:n})]})}var He=w(require("react")),Lt=require("react-aria-components"),St=require("react-router-dom");var It=require("react-router-dom");function ze(e){let t=(0,It.useLocation)(),r=J();if(!r||typeof e!="string"||!r.i18n&&!r.versions)return e;let o="/docs";if(!e.startsWith(o))return e;let a=t.pathname.substring(o.length).split("/").filter(Boolean),c=r.versions?.defaultVersion,l=r.i18n?.defaultLocale,i=0;r.versions&&a.length>i&&r.versions.versions[a[i]]&&(c=a[i],i++),r.i18n&&a.length>i&&r.i18n.locales[a[i]]&&(l=a[i]);let p=e.substring(o.length).split("/").filter(Boolean),m=0,f=!1,x=!1;r.versions&&p.length>m&&r.versions.versions[p[m]]&&(f=!0,m++),r.i18n&&p.length>m&&r.i18n.locales[p[m]]&&(x=!0,m++);let P=p.slice(m),g=[];r.versions&&(f?g.push(p[0]):c&&g.push(c)),r.i18n&&(x?g.push(p[f?1:0]):l&&g.push(l)),g.push(...P);let N=`${o}/${g.join("/")}`;return N.endsWith("/")&&(N=N.slice(0,-1)),N===o?o:N}var ne=require("react"),wr=require("react/jsx-runtime"),Pr=(0,ne.createContext)({preload:()=>{},routes:[]});function Bt(){return(0,ne.use)(Pr)}var Fe=require("react/jsx-runtime"),se=He.default.forwardRef((e,t)=>{let{href:r,prefetch:o="hover",onMouseEnter:n,onFocus:a,...c}=e,l=ze(r??""),{preload:i}=Bt();return(0,Fe.jsx)(Lt.Link,{...c,ref:t,href:l,onMouseEnter:m=>{n?.(m),o==="hover"&&typeof l=="string"&&l.startsWith("/")&&i(l)},onFocus:m=>{a?.(m),o==="hover"&&typeof l=="string"&&l.startsWith("/")&&i(l)}})});se.displayName="Link";var kr=He.default.forwardRef((e,t)=>{let{href:r,end:o=!1,className:n,children:a,...c}=e,l=(0,St.useLocation)(),i=ze(r??""),d=o?l.pathname===i:l.pathname.startsWith(i),p=typeof n=="function"?n({isActive:d}):s(n,d&&"active"),m=typeof a=="function"?a({isActive:d}):a;return(0,Fe.jsx)(se,{...c,ref:t,href:r,className:p,children:m})});kr.displayName="NavLink";var Et=require("react/jsx-runtime");function Mt({to:e,children:t,className:r="",...o}){let n=e&&(e.startsWith("http://")||e.startsWith("https://")||e.startsWith("//")),a=s("text-blue-600 hover:text-blue-800 hover:underline cursor-pointer",r);return(0,Et.jsx)(se,{href:e,className:a,target:n?"_blank":void 0,rel:n?"noopener noreferrer":void 0,...o,children:t})}var ae=require("react"),Ar=require("react/jsx-runtime"),Tr=(0,ae.createContext)(void 0);function Ot(){let e=(0,ae.use)(Tr);if(e===void 0)throw new Error("useTheme must be used within a ThemeProvider");return e}var Dt=require("react/jsx-runtime");function Vt({src:e,alt:t,theme:r,...o}){let{theme:n}=Ot();return r&&r!==n?null:(0,Dt.jsx)("img",{src:e,alt:t||"",...o})}var v=require("react/jsx-runtime");function zt({title:e,props:t,className:r=""}){return(0,v.jsxs)("div",{className:s("my-6",r),children:[e&&(0,v.jsx)("h3",{className:"text-base font-bold text-text-main mb-3",children:e}),(0,v.jsx)("div",{className:"overflow-x-auto rounded-lg border border-border-subtle",children:(0,v.jsxs)("table",{className:"w-full border-collapse text-sm",children:[(0,v.jsx)("thead",{children:(0,v.jsxs)("tr",{children:[(0,v.jsx)("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"}),(0,v.jsx)("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"}),(0,v.jsx)("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"}),(0,v.jsx)("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"})]})}),(0,v.jsx)("tbody",{children:t.map((o,n)=>(0,v.jsxs)("tr",{className:"transition-colors hover:bg-bg-surface",children:[(0,v.jsxs)("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:[(0,v.jsx)("code",{className:"rounded bg-bg-surface px-1.5 py-0.5 font-mono text-xs font-bold text-primary-400",children:o.name}),o.required&&(0,v.jsx)("span",{className:"ml-1 text-red-400 font-bold",children:"*"})]}),(0,v.jsx)("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:(0,v.jsx)("code",{className:"rounded bg-bg-muted px-1.5 py-0.5 font-mono text-xs text-text-muted",children:o.type})}),(0,v.jsx)("td",{className:"px-4 py-2.5 border-b border-border-subtle",children:o.defaultValue?(0,v.jsx)("code",{className:"rounded bg-bg-muted px-1.5 py-0.5 font-mono text-xs text-primary-400",children:o.defaultValue}):(0,v.jsx)("span",{className:"text-text-dim",children:"\u2014"})}),(0,v.jsx)("td",{className:"px-4 py-2.5 border-b border-border-subtle text-text-muted",children:o.description})]},`${o.name}-${n}`))})]})})]})}var We=require("react");function Ht(e){let{code:t,children:r,preview:o}=e,n=(0,We.useMemo)(()=>(t??(typeof r=="string"?r:"")).trim(),[t,r]),a=(0,We.useMemo)(()=>o??(typeof r!="string"?r:null),[o,r]);return{initialCode:n,previewElement:a}}var ie=require("react/jsx-runtime");function Ft(e){let{highlightedHtml:t,hideCode:r=!1,hideSandbox:o=!1,hideCopy:n=!1,sandboxOptions:a={}}=e,{initialCode:c,previewElement:l}=Ht(e);return(0,ie.jsxs)("div",{className:"my-6 overflow-hidden rounded-xl border border-border-subtle",children:[(0,ie.jsx)("div",{className:"flex items-center justify-center p-8 bg-bg-surface",children:l}),!r&&(0,ie.jsx)("div",{className:"border-t border-border-subtle",children:(0,ie.jsx)(Y,{hideSandbox:o,hideCopy:n,title:a.title,lang:"tsx",highlightedHtml:t,children:c})})]})}var Jt=require("react"),U=require("lucide-react");var Wt=require("react");var Ir=require("react-aria-components"),ge=require("lucide-react");var $t=require("react/jsx-runtime");var he=w(require("react-aria-components")),Br=require("lucide-react");var _e=require("react/jsx-runtime");var k=w(require("react-aria-components")),X=require("lucide-react");var h=require("react/jsx-runtime"),Lr=({children:e,isOpen:t,onOpenChange:r,className:o})=>(0,h.jsx)(k.ModalOverlay,{isOpen:t,onOpenChange:r,isDismissable:!0,className:s("fixed inset-0 z-100 bg-black/40 backdrop-blur-sm px-4 py-4 sm:py-20","entering:animate-in entering:fade-in exiting:animate-out exiting:fade-out"),children:(0,h.jsx)(k.Modal,{className:s("mx-auto w-full max-w-2xl overflow-hidden rounded-xl border border-border-subtle bg-bg-surface shadow-2xl ring-1 ring-black/5 outline-none","entering:animate-in entering:fade-in entering:zoom-in-95 exiting:animate-out exiting:fade-out exiting:zoom-out-95",o),children:(0,h.jsx)(k.Dialog,{className:"flex flex-col max-h-[70vh] focus:outline-none",children:e})})}),Sr=({children:e,className:t,...r})=>(0,h.jsx)("div",{className:t,children:(0,h.jsx)(k.Autocomplete,{...r,className:"flex flex-col min-h-0",children:e})}),Mr=({className:e,...t})=>(0,h.jsxs)(k.SearchField,{className:"flex items-center gap-3 border-b border-border-subtle px-4 py-4",autoFocus:!0,children:[(0,h.jsx)(X.Search,{className:"h-5 w-5 text-text-muted"}),(0,h.jsx)(k.Input,{...t,className:s("w-full bg-transparent text-lg text-text-main placeholder-text-muted outline-none",e),placeholder:"Search documentation..."}),(0,h.jsx)("div",{className:"flex items-center gap-1.5 rounded-md border border-border-subtle bg-bg-main px-1.5 py-1 text-[10px] font-medium text-text-muted",children:(0,h.jsx)("kbd",{className:"font-sans",children:"ESC"})})]}),Er=({children:e,className:t,...r})=>(0,h.jsx)(k.ListBox,{...r,className:s("flex-1 overflow-y-auto p-2 outline-none",t),children:e}),Or=({children:e,className:t,...r})=>(0,h.jsx)(k.ListBoxItem,{...r,className:s("group flex items-center gap-3 rounded-lg p-3 text-left outline-none cursor-pointer transition-colors","text-text-muted hover:bg-bg-main hover:text-text-main focus:bg-primary-500 focus:text-white selected:bg-primary-500 selected:text-white",t),children:o=>(0,h.jsxs)(h.Fragment,{children:[e,(o.isFocused||o.isSelected)&&(0,h.jsxs)("div",{className:"ml-auto opacity-50 flex items-center gap-1",children:[(0,h.jsx)("span",{className:"text-[10px]",children:"Select"}),(0,h.jsx)(X.CornerDownLeft,{size:10})]})]})}),Vr=({isHeading:e,className:t})=>(0,h.jsx)("div",{className:s("shrink-0",t),children:e?(0,h.jsx)(X.Hash,{size:18}):(0,h.jsx)(X.FileText,{size:18})}),Dr=({children:e,className:t})=>(0,h.jsx)("span",{className:s("block font-medium truncate flex-1 text-sm",t),children:e}),zr=({children:e,className:t})=>(0,h.jsx)("span",{className:s("ml-2 text-xs opacity-70 truncate hidden sm:inline group-focus:opacity-100",t),children:e}),Qn={Root:Lr,Autocomplete:Sr,Input:Mr,List:Er,Item:Object.assign(Or,{Icon:Vr,Title:Dr,Bio:zr})};var O=require("react"),Hr=w(require("scroll-into-view-if-needed"));var Gt=require("react");var _t=require("react/jsx-runtime"),ps=(0,O.createContext)(null),ms=(0,O.createContext)(null);function Fr(e){let[t,r]=(0,O.useState)({isOverflowing:!1,isAtBottom:!1});return(0,O.useEffect)(()=>{let o=e.current;if(!o)return;let n=()=>{let c=o.scrollHeight>o.clientHeight,l=o.scrollHeight-o.scrollTop<=o.clientHeight+2;r({isOverflowing:c,isAtBottom:l})};n(),o.addEventListener("scroll",n,{passive:!0}),window.addEventListener("resize",n);let a=new MutationObserver(n);return a.observe(o,{childList:!0,subtree:!0}),()=>{o.removeEventListener("scroll",n),window.removeEventListener("resize",n),a.disconnect()}},[e]),t}var Wr=({children:e,className:t,ref:r,...o})=>{let n=(0,O.useRef)(null);(0,O.useImperativeHandle)(r,()=>n.current);let{isOverflowing:a,isAtBottom:c}=Fr(n);return(0,_t.jsx)("div",{ref:n,className:s("relative overflow-y-auto boltdocs-otp-content",a&&!c&&"mask-[linear-gradient(to_bottom,black_85%,transparent_100%)]",t),...o,children:e})};Wr.displayName="OnThisPageContent";var jt=w(require("react-aria-components")),Le=require("lucide-react");var z=require("react/jsx-runtime"),$r=({children:e,className:t})=>(0,z.jsx)("nav",{className:s("grid grid-cols-1 sm:grid-cols-2 gap-4 mt-12 pt-8 border-t border-border-subtle",t),children:e}),Gr=({children:e,to:t,direction:r,className:o})=>{let n=r==="next";return(0,z.jsxs)(jt.Link,{href:t,className:s("flex group items-center p-4 rounded-xl border border-border-subtle bg-bg-surface outline-none","transition-all hover:bg-bg-main hover:border-primary-500 hover:shadow-lg","focus-visible:ring-2 focus-visible:ring-primary-500/30",n?"text-right justify-end":"text-left justify-start",o),children:[!n&&(0,z.jsx)(Le.ChevronLeft,{className:"mr-3 h-5 w-5 text-text-muted group-hover:text-primary-500 transition-transform group-hover:-translate-x-1"}),(0,z.jsx)("div",{className:"flex flex-col gap-1 flex-1",children:e}),n&&(0,z.jsx)(Le.ChevronRight,{className:"ml-3 h-5 w-5 text-text-muted group-hover:text-primary-500 transition-transform group-hover:translate-x-1"})]})},_r=({children:e,className:t})=>(0,z.jsx)("span",{className:s("text-xs font-medium uppercase tracking-wider text-text-muted",t),children:e}),jr=({children:e,className:t})=>(0,z.jsx)("span",{className:s("text-base font-bold text-text-main truncate",t),children:e}),Ur=({children:e})=>(0,z.jsx)(z.Fragment,{children:e}),xs={PageNavRoot:$r,PageNavLink:Object.assign(Gr,{Title:_r,Description:jr,Icon:Ur})};var qr=require("react/jsx-runtime");var Xr=w(require("react-aria-components")),Kr=require("lucide-react");var Ut=require("react/jsx-runtime");var je=require("react-aria-components"),Zr=require("lucide-react");var Jr=require("react/jsx-runtime");var Xt=require("react/jsx-runtime"),qt=({children:e,className:t,vertical:r=!1})=>(0,Xt.jsx)("div",{className:s("inline-flex",r?"flex-col":"flex-row",!r&&["[&>*:not(:first-child)]:-ml-px","[&>*:first-child]:rounded-r-none","[&>*:last-child]:rounded-l-none","[&>*:not(:first-child):not(:last-child)]:rounded-none",t?.includes("rounded-full")&&["[&>*:first-child]:rounded-l-full","[&>*:last-child]:rounded-r-full"],t?.includes("rounded-xl")&&["[&>*:first-child]:rounded-l-xl","[&>*:last-child]:rounded-r-xl"],t?.includes("rounded-lg")&&["[&>*:first-child]:rounded-l-lg","[&>*:last-child]:rounded-r-lg"]],r&&["[&>*:not(:first-child)]:-mt-px","[&>*:first-child]:rounded-b-none","[&>*:last-child]:rounded-t-none","[&>*:not(:first-child):not(:last-child)]:rounded-none",t?.includes("rounded-full")&&["[&>*:first-child]:rounded-t-full","[&>*:last-child]:rounded-b-full"]],t),children:e});var de=require("lucide-react"),Zt=w(require("react")),A=w(require("react-aria-components"));var ce=w(require("react-aria-components"));var le=require("react/jsx-runtime"),Kt=({children:e,className:t,showArrow:r,...o})=>(0,le.jsxs)(ce.Popover,{offset:8,...o,className:ce.composeRenderProps(t,n=>s("z-50 overflow-auto rounded-xl border border-border-subtle bg-bg-surface/80 shadow-xl backdrop-blur-md outline-none","entering:animate-in entering:fade-in entering:zoom-in-95 exiting:animate-out exiting:fade-out exiting:zoom-out-95 fill-mode-forwards",n)),children:[r&&(0,le.jsx)(ce.OverlayArrow,{className:"group",children:(0,le.jsx)("svg",{viewBox:"0 0 12 12",className:"block h-3 w-3 fill-bg-surface/80 stroke-border-subtle group-placement-bottom:rotate-180 group-placement-left:-rotate-90 group-placement-right:rotate-90","aria-hidden":"true",children:(0,le.jsx)("path",{d:"M0 0 L6 6 L12 0"})})}),e]});var B=require("react/jsx-runtime");function $e(e){let[t,r]=Zt.default.Children.toArray(e.children).slice(0,2);return(0,B.jsxs)(A.MenuTrigger,{...e,children:[t,(0,B.jsx)(Kt,{placement:e.placement,className:"min-w-[200px]",children:r})]})}function Ge(e){return(0,B.jsx)(A.Menu,{...e,className:A.composeRenderProps(e.className,t=>s("p-1.5 outline-none max-h-[inherit] overflow-auto",t))})}function Ie(e){let t=e.textValue||(typeof e.children=="string"?e.children:void 0);return(0,B.jsx)(A.MenuItem,{...e,textValue:t,className:A.composeRenderProps(e.className,(r,{isFocused:o,isPressed:n,isDisabled:a})=>s("group relative flex flex-row items-center gap-2.5 px-3 py-1.5 rounded-lg outline-none cursor-default transition-all duration-200","text-text-main text-[0.8125rem]",o&&"bg-primary-500/10 text-primary-600 shadow-sm",n&&"scale-[0.98] bg-primary-500/15",a&&"opacity-40 grayscale pointer-events-none",r)),children:A.composeRenderProps(e.children,(r,{selectionMode:o,isSelected:n,hasSubmenu:a})=>(0,B.jsxs)(B.Fragment,{children:[o!=="none"&&(0,B.jsxs)("span",{className:"flex items-center w-4 h-4 shrink-0 justify-center",children:[n&&o==="multiple"&&(0,B.jsx)(de.Check,{className:"w-3.5 h-3.5 stroke-[2.5px] text-primary-500 animate-in zoom-in-50 duration-200"}),n&&o==="single"&&(0,B.jsx)(de.Dot,{className:"w-6 h-6 text-primary-500 animate-in zoom-in-50 duration-200"})]}),(0,B.jsx)("div",{className:"flex-1 flex flex-row items-center gap-2.5 truncate font-medium",children:r}),a&&(0,B.jsx)(de.ChevronRight,{className:"w-4 h-4 ml-auto text-text-muted group-focused:text-primary-500/70 transition-colors"})]}))})}var Be=require("react-aria-components");var R=require("react/jsx-runtime"),Qr=e=>{let[t,r]=(0,Jt.useState)(!1);return{copied:t,handleCopy:()=>{navigator.clipboard.writeText(e),r(!0),setTimeout(()=>r(!1),2e3)},handleOpenRaw:()=>{let a=new Blob([e],{type:"text/plain;charset=utf-8"}),c=URL.createObjectURL(a);window.open(c,"_blank")}}};function Qt({content:e,mdxRaw:t,config:r}){let o=t||e||"",{copied:n,handleCopy:a,handleOpenRaw:c}=Qr(o),l=r!==!1,i=typeof r=="object"&&r.text||"Copy Markdown";return!l||!o?null:(0,R.jsx)("div",{className:"relative inline-flex z-100 flex-shrink-0 w-max translate-y-0 active:translate-y-px transition-transform duration-200",children:(0,R.jsxs)(qt,{className:"rounded-xl border border-border-subtle bg-bg-surface/40 backdrop-blur-md transition-all duration-300 hover:border-primary-500/50 hover:shadow-lg hover:shadow-primary-500/5 group overflow-hidden",children:[(0,R.jsx)(Z,{variant:"ghost",onPress:a,icon:n?(0,R.jsx)(U.Check,{size:16}):(0,R.jsx)(U.Copy,{size:16}),iconPosition:"left",className:s("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}),(0,R.jsxs)($e,{placement:"bottom end",children:[(0,R.jsx)(Z,{variant:"ghost",isIconOnly:!0,icon:(0,R.jsx)(U.ChevronDown,{size:14}),className:s("px-3.5 h-9 border-l border-border-subtle/50 text-text-muted rounded-none bg-transparent shrink-0","transition-all duration-300 hover:bg-primary-500/5 hover:text-primary-500")}),(0,R.jsxs)(Ge,{className:"w-52",children:[(0,R.jsxs)(Ie,{onAction:a,className:"flex flex-row items-start gap-2.5 group",children:[(0,R.jsx)(U.Copy,{size:16,className:"w-4 h-4 shrink-0 mt-0.5 transition-transform duration-200 group-hover:-translate-y-0.5 text-text-muted group-hover:text-primary-500"}),(0,R.jsx)("span",{className:"font-medium text-[0.8125rem]",children:"Copy Markdown"})]}),(0,R.jsxs)(Ie,{onAction:c,className:"flex flex-row items-start gap-2.5 group",children:[(0,R.jsx)(U.ExternalLink,{size:16,className:"w-4 h-4 shrink-0 mt-0.5 transition-transform duration-200 group-hover:-translate-y-0.5 text-text-muted group-hover:text-primary-500"}),(0,R.jsx)("span",{className:"font-medium text-[0.8125rem]",children:"View as Markdown"})]})]})]})]})})}
@@ -1 +1 @@
1
- import{A as x,B as y,a,e as b,f as c,g as d,h as e,i as f,j as g,k as h,l as i,m as j,n as k,o as l,p as m,q as n,r as o,s as p,t as q,u as r,v as s,w as t,x as u,y as v,z as w}from"../../../chunk-A4HQPEPU.mjs";import"../../../chunk-BA5NH5HU.mjs";import"../../../chunk-BQCD3DWG.mjs";import"../../../chunk-XEAPSFMB.mjs";import"../../../chunk-JZXLCA2E.mjs";export{i as Admonition,f as Badge,a as Button,h as Card,g as Cards,p as Caution,b as CodeBlock,x as ComponentPreview,w as ComponentProps,y as CopyMarkdown,m as Danger,t as Field,r as FileTree,v as Image,o as Important,n as InfoBox,u as Link,q as List,j as Note,c as Tab,s as Table,d as Tabs,k as Tip,e as Video,l as Warning};
1
+ import{A as x,B as y,a,e as b,f as c,g as d,h as e,i as f,j as g,k as h,l as i,m as j,n as k,o as l,p as m,q as n,r as o,s as p,t as q,u as r,v as s,w as t,x as u,y as v,z as w}from"../../../chunk-FUVYCYWC.mjs";import"../../../chunk-GBLMDJ2B.mjs";import"../../../chunk-BVWWKXJH.mjs";import"../../../chunk-52MVMZWS.mjs";export{i as Admonition,f as Badge,a as Button,h as Card,g as Cards,p as Caution,b as CodeBlock,x as ComponentPreview,w as ComponentProps,y as CopyMarkdown,m as Danger,t as Field,r as FileTree,v as Image,o as Important,n as InfoBox,u as Link,q as List,j as Note,c as Tab,s as Table,d as Tabs,k as Tip,e as Video,l as Warning};
@@ -1,7 +1,6 @@
1
- import { b as BoltdocsSocialLink, B as BoltdocsConfig } from '../../config-CX4l-ZNp.mjs';
2
- import { N as NavbarLink, C as ComponentRoute, B as BoltdocsTab } from '../../types-CvT-SGbK.mjs';
1
+ import { N as NavbarLink, a as BoltdocsSocialLink, B as BoltdocsConfig, C as ComponentRoute, b as BoltdocsTab } from '../../types-Cp21DHI6.mjs';
3
2
  import * as React from 'react';
4
- export { u as useRoutes } from '../../use-routes-5bAtAAYX.mjs';
3
+ export { u as useRoutes } from '../../use-routes-8Iei6jTp.mjs';
5
4
  import * as react_router_dom from 'react-router-dom';
6
5
  import { LinkProps } from 'react-router-dom';
7
6
  import 'vite';
@@ -1,7 +1,6 @@
1
- import { b as BoltdocsSocialLink, B as BoltdocsConfig } from '../../config-CX4l-ZNp.js';
2
- import { N as NavbarLink, C as ComponentRoute, B as BoltdocsTab } from '../../types-BuZWFT7r.js';
1
+ import { N as NavbarLink, a as BoltdocsSocialLink, B as BoltdocsConfig, C as ComponentRoute, b as BoltdocsTab } from '../../types-Cp21DHI6.js';
3
2
  import * as React from 'react';
4
- export { u as useRoutes } from '../../use-routes-BefRXY3v.js';
3
+ export { u as useRoutes } from '../../use-routes-xLhumjbV.js';
5
4
  import * as react_router_dom from 'react-router-dom';
6
5
  import { LinkProps } from 'react-router-dom';
7
6
  import 'vite';
@@ -1 +1 @@
1
- "use strict";var k=Object.defineProperty;var F=Object.getOwnPropertyDescriptor;var j=Object.getOwnPropertyNames;var A=Object.prototype.hasOwnProperty;var H=(o,n)=>{for(var r in n)k(o,r,{get:n[r],enumerable:!0})},Q=(o,n,r,t)=>{if(n&&typeof n=="object"||typeof n=="function")for(let i of j(n))!A.call(o,i)&&i!==r&&k(o,i,{get:()=>n[i],enumerable:!(t=F(n,i))||t.enumerable});return o};var U=o=>Q(k({},"__esModule",{value:!0}),o);var ie={};H(ie,{useBreadcrumbs:()=>ne,useI18n:()=>te,useLocalizedTo:()=>re,useLocation:()=>se,useNavbar:()=>D,useOnThisPage:()=>J,usePageNav:()=>oe,useRoutes:()=>v,useSearch:()=>G,useSidebar:()=>K,useTabs:()=>Y,useVersion:()=>ee});module.exports=U(ie);var V=require("react-router-dom");var T=require("react"),X=(0,T.createContext)(null);function b(){let o=(0,T.use)(X);if(!o)throw new Error("useConfig must be used within a ConfigProvider");return o}var L=require("react"),z=require("react/jsx-runtime"),q=(0,L.createContext)(void 0);function w(){let o=(0,L.use)(q);if(o===void 0)throw new Error("useTheme must be used within a ThemeProvider");return o}function D(){let o=b(),{theme:n}=w(),r=(0,V.useLocation)(),t=o.themeConfig||{},i=t.title||"Boltdocs",a=t.navbar||[],c=t.socialLinks||[],u=t.githubRepo,f=a.map(p=>{let d=p.href||p.to||p.link||"";return{label:p.label||p.text||"",href:d,active:r.pathname===d,to:d.startsWith("http")||d.startsWith("//")?"external":void 0}}),e=t.logo,s=e?typeof e=="string"?e:n==="dark"?e.dark:e.light:null,l={alt:(e&&typeof e=="object"?e.alt:void 0)||i,width:e&&typeof e=="object"?e.width:void 0,height:e&&typeof e=="object"?e.height:void 0},h=u?`https://github.com/${u}`:null;return{links:f,title:i,logo:s,logoProps:l,github:h,social:c,config:o,theme:n}}var I=require("react-router-dom");function K(o){let n=b(),r=(0,I.useLocation)(),t=o.find(e=>e.path===r.pathname),i=t?.tab?.toLowerCase(),a=i?o.filter(e=>!e.tab||e.tab.toLowerCase()===i):o,c=[],u=new Map;for(let e of a)e.group?(u.has(e.group)||u.set(e.group,{slug:e.group,title:e.groupTitle||e.group,routes:[],icon:e.groupIcon}),u.get(e.group).routes.push(e)):c.push(e);return{groups:Array.from(u.values()),ungrouped:c,activeRoute:t,activePath:r.pathname,config:n}}var P=require("react");function G(o){let[n,r]=(0,P.useState)(!1),[t,i]=(0,P.useState)(""),a=(0,P.useMemo)(()=>{if(!t)return o.slice(0,10).map(e=>({id:e.path,title:e.title,path:e.path,bio:e.description||"",groupTitle:e.groupTitle}));let c=[],u=t.toLowerCase();for(let e of o)if(e.title?.toLowerCase().includes(u)&&c.push({id:e.path,title:e.title,path:e.path,bio:e.description||"",groupTitle:e.groupTitle}),e.headings)for(let s of e.headings)s.text.toLowerCase().includes(u)&&c.push({id:`${e.path}#${s.id}`,title:s.text,path:`${e.path}#${s.id}`,bio:`Heading in ${e.title}`,groupTitle:e.title,isHeading:!0});let f=new Set;return c.filter(e=>f.has(e.path)?!1:(f.add(e.path),!0)).slice(0,10)},[o,t]);return{isOpen:n,setIsOpen:r,query:t,setQuery:i,list:a,input:{value:t,onChange:c=>i(c.target.value)}}}var S=require("react");function J(o=[]){let[n,r]=(0,S.useState)(null);return{headings:o,activeId:n,setActiveId:r}}var $=require("react-router-dom"),C=require("react");function Y(o=[],n=[]){let r=(0,$.useLocation)(),t=(0,C.useRef)([]),[i,a]=(0,C.useState)({opacity:0,transform:"translateX(0) scaleX(0)",width:0}),u=n.find(s=>s.path===r.pathname)?.tab?.toLowerCase(),f=o.findIndex(s=>s.id.toLowerCase()===u),e=f===-1?0:f;return(0,C.useEffect)(()=>{let s=t.current[e];s&&a({opacity:1,width:s.offsetWidth,transform:`translateX(${s.offsetLeft}px)`})},[e,o.length,r.pathname]),{tabs:o,activeIndex:e,indicatorStyle:i,tabRefs:t,activeTabId:u}}var O=require("react-router-dom");function x(o,n,r){let t=o;return n&&(t===n||t.startsWith(n+"/"))&&(t=t===n?"index.md":t.slice(n.length+1)),r&&(t===r||t.startsWith(r+"/"))&&(t=t===r?"index.md":t.slice(r.length+1)),t}var M=require("react-router-dom");var R=require("react"),_=require("react/jsx-runtime"),Z=(0,R.createContext)({preload:()=>{},routes:[]});function B(){return(0,R.use)(Z)}function v(){let{routes:o}=B(),n=b(),r=(0,M.useLocation)(),t=o.find(l=>l.path===r.pathname),i=n.i18n?t?.locale||n.i18n.defaultLocale:void 0,a=n.versions?t?.version||n.versions.defaultVersion:void 0,c=o.filter(l=>{let h=n.i18n?(l.locale||n.i18n.defaultLocale)===i:!0,p=n.versions?(l.version||n.versions.defaultVersion)===a:!0;return h&&p}),u=n.i18n?.locales[i]||i,f=n.versions?.versions[a]||a,e=n.i18n?Object.entries(n.i18n.locales).map(([l,h])=>({key:l,label:h,isCurrent:l===i})):[],s=n.versions?Object.entries(n.versions.versions).map(([l,h])=>({key:l,label:h,isCurrent:l===a})):[];return{routes:c,allRoutes:o,currentRoute:t,currentLocale:i,currentLocaleLabel:u,availableLocales:e,currentVersion:a,currentVersionLabel:f,availableVersions:s,config:n}}function ee(){let o=(0,O.useNavigate)(),n=v(),{allRoutes:r,currentRoute:t,currentVersion:i,currentLocale:a,config:c}=n,u=c.versions,f=s=>{if(!u||s===i)return;let l=`/docs/${s}`;if(t){let h=x(t.filePath,t.version,t.locale),p=r.find(d=>x(d.filePath,d.version,d.locale)===h&&(d.version||u.defaultVersion)===s&&(a?d.locale===a:!d.locale));if(p)l=p.path;else{let d=r.find(g=>x(g.filePath,g.version,g.locale)==="index.md"&&(g.version||u.defaultVersion)===s&&(a?g.locale===a:!g.locale));l=d?d.path:`/docs/${s}${a?`/${a}`:""}`}}o(l)},e=n.availableVersions.map(s=>({...s,label:s.label,value:s.key}));return{currentVersion:i,currentVersionLabel:n.currentVersionLabel,availableVersions:e,handleVersionChange:f}}var E=require("react-router-dom");function te(){let o=(0,E.useNavigate)(),n=v(),{allRoutes:r,currentRoute:t,currentLocale:i,config:a}=n,c=a.i18n,u=e=>{if(!c||e===i)return;let s="/";if(t){let l=x(t.filePath,t.version,t.locale),h=r.find(p=>x(p.filePath,p.version,p.locale)===l&&(p.locale||c.defaultLocale)===e&&p.version===t.version);if(h)s=h.path;else{let p=r.find(d=>x(d.filePath,d.version,d.locale)==="index.md"&&(d.locale||c.defaultLocale)===e&&d.version===t.version);s=p?p.path:e===c.defaultLocale?t.version?`/${t.version}`:"/":t.version?`/${t.version}/${e}`:`/${e}`}}else s=e===c.defaultLocale?"/":`/${e}`;o(s)},f=n.availableLocales.map(e=>({...e,label:e.label,value:e.key}));return{currentLocale:i,currentLocaleLabel:n.currentLocaleLabel,availableLocales:f,handleLocaleChange:u}}function oe(){let{routes:o}=v(),n=window.location.pathname,r=o.findIndex(c=>c.path===n),t=o[r],i=r>0?o[r-1]:null,a=r<o.length-1?o[r+1]:null;return{prevPage:i,nextPage:a,currentRoute:t}}function ne(){let{currentRoute:o}=v(),n=[];return o&&(o.groupTitle&&n.push({label:o.groupTitle}),n.push({label:o.title,href:o.path})),{crumbs:n,activeRoute:o}}var N=require("react-router-dom");function re(o){let n=(0,N.useLocation)(),r=b();if(!r||typeof o!="string"||!r.i18n&&!r.versions)return o;let t="/docs";if(!o.startsWith(t))return o;let a=n.pathname.substring(t.length).split("/").filter(Boolean),c=r.versions?.defaultVersion,u=r.i18n?.defaultLocale,f=0;r.versions&&a.length>f&&r.versions.versions[a[f]]&&(c=a[f],f++),r.i18n&&a.length>f&&r.i18n.locales[a[f]]&&(u=a[f]);let s=o.substring(t.length).split("/").filter(Boolean),l=0,h=!1,p=!1;r.versions&&s.length>l&&r.versions.versions[s[l]]&&(h=!0,l++),r.i18n&&s.length>l&&r.i18n.locales[s[l]]&&(p=!0,l++);let d=s.slice(l),g=[];r.versions&&(h?g.push(s[0]):c&&g.push(c)),r.i18n&&(p?g.push(s[h?1:0]):u&&g.push(u)),g.push(...d);let y=`${t}/${g.join("/")}`;return y.endsWith("/")&&(y=y.slice(0,-1)),y===t?t:y}var W=require("react-router-dom"),se=()=>(0,W.useLocation)();0&&(module.exports={useBreadcrumbs,useI18n,useLocalizedTo,useLocation,useNavbar,useOnThisPage,usePageNav,useRoutes,useSearch,useSidebar,useTabs,useVersion});
1
+ "use strict";var k=Object.defineProperty;var F=Object.getOwnPropertyDescriptor;var j=Object.getOwnPropertyNames;var A=Object.prototype.hasOwnProperty;var H=(t,n)=>{for(var r in n)k(t,r,{get:n[r],enumerable:!0})},Q=(t,n,r,o)=>{if(n&&typeof n=="object"||typeof n=="function")for(let i of j(n))!A.call(t,i)&&i!==r&&k(t,i,{get:()=>n[i],enumerable:!(o=F(n,i))||o.enumerable});return t};var U=t=>Q(k({},"__esModule",{value:!0}),t);var ie={};H(ie,{useBreadcrumbs:()=>ne,useI18n:()=>te,useLocalizedTo:()=>re,useLocation:()=>se,useNavbar:()=>D,useOnThisPage:()=>J,usePageNav:()=>oe,useRoutes:()=>v,useSearch:()=>G,useSidebar:()=>K,useTabs:()=>Y,useVersion:()=>ee});module.exports=U(ie);var V=require("react-router-dom");var T=require("react"),X=(0,T.createContext)(null);function b(){let t=(0,T.use)(X);if(!t)throw new Error("useConfig must be used within a ConfigProvider");return t}var L=require("react"),z=require("react/jsx-runtime"),q=(0,L.createContext)(void 0);function w(){let t=(0,L.use)(q);if(t===void 0)throw new Error("useTheme must be used within a ThemeProvider");return t}function D(){let t=b(),{theme:n}=w(),r=(0,V.useLocation)(),o=t.theme||t.themeConfig||{},i=o.title||"Boltdocs",a=o.navbar||[],c=o.socialLinks||[],u=o.githubRepo,f=a.map(p=>{let d=p.href||p.to||p.link||"";return{label:p.label||p.text||"",href:d,active:r.pathname===d,to:d.startsWith("http")||d.startsWith("//")?"external":void 0}}),e=o.logo,s=e?typeof e=="string"?e:n==="dark"?e.dark:e.light:null,l={alt:(e&&typeof e=="object"?e.alt:void 0)||i,width:e&&typeof e=="object"?e.width:void 0,height:e&&typeof e=="object"?e.height:void 0},h=u?`https://github.com/${u}`:null;return{links:f,title:i,logo:s,logoProps:l,github:h,social:c,config:t,theme:n}}var I=require("react-router-dom");function K(t){let n=b(),r=(0,I.useLocation)(),o=t.find(e=>e.path===r.pathname),i=o?.tab?.toLowerCase(),a=i?t.filter(e=>!e.tab||e.tab.toLowerCase()===i):t,c=[],u=new Map;for(let e of a)e.group?(u.has(e.group)||u.set(e.group,{slug:e.group,title:e.groupTitle||e.group,routes:[],icon:e.groupIcon}),u.get(e.group).routes.push(e)):c.push(e);return{groups:Array.from(u.values()),ungrouped:c,activeRoute:o,activePath:r.pathname,config:n}}var P=require("react");function G(t){let[n,r]=(0,P.useState)(!1),[o,i]=(0,P.useState)(""),a=(0,P.useMemo)(()=>{if(!o)return t.slice(0,10).map(e=>({id:e.path,title:e.title,path:e.path,bio:e.description||"",groupTitle:e.groupTitle}));let c=[],u=o.toLowerCase();for(let e of t)if(e.title?.toLowerCase().includes(u)&&c.push({id:e.path,title:e.title,path:e.path,bio:e.description||"",groupTitle:e.groupTitle}),e.headings)for(let s of e.headings)s.text.toLowerCase().includes(u)&&c.push({id:`${e.path}#${s.id}`,title:s.text,path:`${e.path}#${s.id}`,bio:`Heading in ${e.title}`,groupTitle:e.title,isHeading:!0});let f=new Set;return c.filter(e=>f.has(e.path)?!1:(f.add(e.path),!0)).slice(0,10)},[t,o]);return{isOpen:n,setIsOpen:r,query:o,setQuery:i,list:a,input:{value:o,onChange:c=>i(c.target.value)}}}var S=require("react");function J(t=[]){let[n,r]=(0,S.useState)(null);return{headings:t,activeId:n,setActiveId:r}}var $=require("react-router-dom"),C=require("react");function Y(t=[],n=[]){let r=(0,$.useLocation)(),o=(0,C.useRef)([]),[i,a]=(0,C.useState)({opacity:0,transform:"translateX(0) scaleX(0)",width:0}),u=n.find(s=>s.path===r.pathname)?.tab?.toLowerCase(),f=t.findIndex(s=>s.id.toLowerCase()===u),e=f===-1?0:f;return(0,C.useEffect)(()=>{let s=o.current[e];s&&a({opacity:1,width:s.offsetWidth,transform:`translateX(${s.offsetLeft}px)`})},[e,t.length,r.pathname]),{tabs:t,activeIndex:e,indicatorStyle:i,tabRefs:o,activeTabId:u}}var O=require("react-router-dom");function x(t,n,r){let o=t;return n&&(o===n||o.startsWith(n+"/"))&&(o=o===n?"index.md":o.slice(n.length+1)),r&&(o===r||o.startsWith(r+"/"))&&(o=o===r?"index.md":o.slice(r.length+1)),o}var M=require("react-router-dom");var R=require("react"),_=require("react/jsx-runtime"),Z=(0,R.createContext)({preload:()=>{},routes:[]});function B(){return(0,R.use)(Z)}function v(){let{routes:t}=B(),n=b(),r=(0,M.useLocation)(),o=t.find(l=>l.path===r.pathname),i=n.i18n?o?.locale||n.i18n.defaultLocale:void 0,a=n.versions?o?.version||n.versions.defaultVersion:void 0,c=t.filter(l=>{let h=n.i18n?(l.locale||n.i18n.defaultLocale)===i:!0,p=n.versions?(l.version||n.versions.defaultVersion)===a:!0;return h&&p}),u=n.i18n?.locales[i]||i,f=n.versions?.versions[a]||a,e=n.i18n?Object.entries(n.i18n.locales).map(([l,h])=>({key:l,label:h,isCurrent:l===i})):[],s=n.versions?Object.entries(n.versions.versions).map(([l,h])=>({key:l,label:h,isCurrent:l===a})):[];return{routes:c,allRoutes:t,currentRoute:o,currentLocale:i,currentLocaleLabel:u,availableLocales:e,currentVersion:a,currentVersionLabel:f,availableVersions:s,config:n}}function ee(){let t=(0,O.useNavigate)(),n=v(),{allRoutes:r,currentRoute:o,currentVersion:i,currentLocale:a,config:c}=n,u=c.versions,f=s=>{if(!u||s===i)return;let l=`/docs/${s}`;if(o){let h=x(o.filePath,o.version,o.locale),p=r.find(d=>x(d.filePath,d.version,d.locale)===h&&(d.version||u.defaultVersion)===s&&(a?d.locale===a:!d.locale));if(p)l=p.path;else{let d=r.find(g=>x(g.filePath,g.version,g.locale)==="index.md"&&(g.version||u.defaultVersion)===s&&(a?g.locale===a:!g.locale));l=d?d.path:`/docs/${s}${a?`/${a}`:""}`}}t(l)},e=n.availableVersions.map(s=>({...s,label:s.label,value:s.key}));return{currentVersion:i,currentVersionLabel:n.currentVersionLabel,availableVersions:e,handleVersionChange:f}}var E=require("react-router-dom");function te(){let t=(0,E.useNavigate)(),n=v(),{allRoutes:r,currentRoute:o,currentLocale:i,config:a}=n,c=a.i18n,u=e=>{if(!c||e===i)return;let s="/";if(o){let l=x(o.filePath,o.version,o.locale),h=r.find(p=>x(p.filePath,p.version,p.locale)===l&&(p.locale||c.defaultLocale)===e&&p.version===o.version);if(h)s=h.path;else{let p=r.find(d=>x(d.filePath,d.version,d.locale)==="index.md"&&(d.locale||c.defaultLocale)===e&&d.version===o.version);s=p?p.path:e===c.defaultLocale?o.version?`/${o.version}`:"/":o.version?`/${o.version}/${e}`:`/${e}`}}else s=e===c.defaultLocale?"/":`/${e}`;t(s)},f=n.availableLocales.map(e=>({...e,label:e.label,value:e.key}));return{currentLocale:i,currentLocaleLabel:n.currentLocaleLabel,availableLocales:f,handleLocaleChange:u}}function oe(){let{routes:t}=v(),n=window.location.pathname,r=t.findIndex(c=>c.path===n),o=t[r],i=r>0?t[r-1]:null,a=r<t.length-1?t[r+1]:null;return{prevPage:i,nextPage:a,currentRoute:o}}function ne(){let{currentRoute:t}=v(),n=[];return t&&(t.groupTitle&&n.push({label:t.groupTitle}),n.push({label:t.title,href:t.path})),{crumbs:n,activeRoute:t}}var N=require("react-router-dom");function re(t){let n=(0,N.useLocation)(),r=b();if(!r||typeof t!="string"||!r.i18n&&!r.versions)return t;let o="/docs";if(!t.startsWith(o))return t;let a=n.pathname.substring(o.length).split("/").filter(Boolean),c=r.versions?.defaultVersion,u=r.i18n?.defaultLocale,f=0;r.versions&&a.length>f&&r.versions.versions[a[f]]&&(c=a[f],f++),r.i18n&&a.length>f&&r.i18n.locales[a[f]]&&(u=a[f]);let s=t.substring(o.length).split("/").filter(Boolean),l=0,h=!1,p=!1;r.versions&&s.length>l&&r.versions.versions[s[l]]&&(h=!0,l++),r.i18n&&s.length>l&&r.i18n.locales[s[l]]&&(p=!0,l++);let d=s.slice(l),g=[];r.versions&&(h?g.push(s[0]):c&&g.push(c)),r.i18n&&(p?g.push(s[h?1:0]):u&&g.push(u)),g.push(...d);let y=`${o}/${g.join("/")}`;return y.endsWith("/")&&(y=y.slice(0,-1)),y===o?o:y}var W=require("react-router-dom"),se=()=>(0,W.useLocation)();
@@ -1 +1 @@
1
- import{a as m,b as p,c as f,d as x,e as a,f as n,g as s,h as i,i as u}from"../../chunk-IWHRQHS7.mjs";import"../../chunk-BA5NH5HU.mjs";import{a as c}from"../../chunk-H63UMKYF.mjs";import{c as e}from"../../chunk-XEAPSFMB.mjs";import"../../chunk-JZXLCA2E.mjs";import{useLocation as t}from"react-router-dom";var R=()=>t();export{i as useBreadcrumbs,x as useI18n,e as useLocalizedTo,R as useLocation,p as useNavbar,s as useOnThisPage,u as usePageNav,m as useRoutes,c as useSearch,n as useSidebar,a as useTabs,f as useVersion};
1
+ import{a as t,b as e,c as m,d as p,e as f,f as a,g as c,h as n,i as s}from"../../chunk-DVY3RDXD.mjs";import"../../chunk-GBLMDJ2B.mjs";import{a as x}from"../../chunk-ISPX45DF.mjs";import{d as r}from"../../chunk-52MVMZWS.mjs";import{useLocation as o}from"react-router-dom";var u=()=>o();export{n as useBreadcrumbs,p as useI18n,r as useLocalizedTo,u as useLocation,e as useNavbar,c as useOnThisPage,s as usePageNav,t as useRoutes,x as useSearch,a as useSidebar,f as useTabs,m as useVersion};
@@ -1,8 +1,6 @@
1
- import { B as BoltdocsConfig } from '../config-CX4l-ZNp.mjs';
2
- export { a as BoltdocsThemeConfig } from '../config-CX4l-ZNp.mjs';
3
- import { a as CreateBoltdocsAppOptions, C as ComponentRoute, O as OnThisPageProps, S as SandboxOptions } from '../types-CvT-SGbK.mjs';
4
- export { L as LayoutProps, b as SandboxEmbedOptions, c as SandboxFile, d as SandboxFiles } from '../types-CvT-SGbK.mjs';
5
- export { u as useRoutes } from '../use-routes-5bAtAAYX.mjs';
1
+ import { c as CreateBoltdocsAppOptions, B as BoltdocsConfig, C as ComponentRoute, O as OnThisPageProps, S as SandboxOptions } from '../types-Cp21DHI6.mjs';
2
+ export { d as BoltdocsThemeConfig, L as LayoutProps, e as SandboxEmbedOptions, f as SandboxFile, g as SandboxFiles } from '../types-Cp21DHI6.mjs';
3
+ export { u as useRoutes } from '../use-routes-8Iei6jTp.mjs';
6
4
  import * as React$1 from 'react';
7
5
  import React__default, { Component, ReactNode, ErrorInfo } from 'react';
8
6
  import * as react_jsx_runtime from 'react/jsx-runtime';
@@ -1,8 +1,6 @@
1
- import { B as BoltdocsConfig } from '../config-CX4l-ZNp.js';
2
- export { a as BoltdocsThemeConfig } from '../config-CX4l-ZNp.js';
3
- import { a as CreateBoltdocsAppOptions, C as ComponentRoute, O as OnThisPageProps, S as SandboxOptions } from '../types-BuZWFT7r.js';
4
- export { L as LayoutProps, b as SandboxEmbedOptions, c as SandboxFile, d as SandboxFiles } from '../types-BuZWFT7r.js';
5
- export { u as useRoutes } from '../use-routes-BefRXY3v.js';
1
+ import { c as CreateBoltdocsAppOptions, B as BoltdocsConfig, C as ComponentRoute, O as OnThisPageProps, S as SandboxOptions } from '../types-Cp21DHI6.js';
2
+ export { d as BoltdocsThemeConfig, L as LayoutProps, e as SandboxEmbedOptions, f as SandboxFile, g as SandboxFiles } from '../types-Cp21DHI6.js';
3
+ export { u as useRoutes } from '../use-routes-xLhumjbV.js';
6
4
  import * as React$1 from 'react';
7
5
  import React__default, { Component, ReactNode, ErrorInfo } from 'react';
8
6
  import * as react_jsx_runtime from 'react/jsx-runtime';