PageSourceSearch

https://reui.io/_next/static/immutable/chunks/24spkye-5h5mz.js

js reui.io collected 2026-10-03 23:31:35 UTC 59,111 bytes, 1 lines download raw bytes

1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,564053,790636,742536,268543,305544,546131,628481,665121,928775,172185,861463,103536,945820,975490,771050,e=>{"use strict";var t=e.i(135809),n=e.i(880745),s=e.i(485311),r=e.i(938349),i=e.i(831541);let o=[["path",{d:"M4.26781 18.8447C4.49269 20.515 5.87613 21.8235 7.55966 21.9009C8.97627 21.966 10.4153 22 12 22C13.5847 22 15.0237 21.966 16.4403 21.9009C18.1239 21.8235 19.5073 20.515 19.7322 18.8447C19.879 17.7547 20 16.6376 20 15.5C20 14.3624 19.879 13.2453 19.7322 12.1553C19.5073 10.485 18.1239 9.17649 16.4403 9.09909C15.0237 9.03397 13.5847 9 12 9C10.4153 9 8.97627 9.03397 7.55965 9.09909C5.87613 9.17649 4.49269 10.485 4.26781 12.1553C4.12104 13.2453 4 14.3624 4 15.5C4 16.6376 4.12104 17.7547 4.26781 18.8447Z",stroke:"currentColor",strokeWidth:"1.5",key:"0"}],["path",{d:"M7.5 9V6.5C7.5 4.01472 9.51472 2 12 2C13.9593 2 15.5 3.5 16 5",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",key:"1"}],["path",{d:"M12.125 15.5H12M12.25 15.5C12.25 15.6381 12.1381 15.75 12 15.75C11.8619 15.75 11.75 15.6381 11.75 15.5C11.75 15.3619 11.8619 15.25 12 15.25C12.1381 15.25 12.25 15.3619 12.25 15.5Z",stroke:"currentColor",strokeLinecap:"round",strokeWidth:"1.5",key:"2"}]];var a=e.i(996669),l=e.i(228603),c=e.i(839717),d=e.i(638264);function u({param:e,className:n}){let{isLocked:s,toggleLock:r}=(0,d.useLocks)(),m=s(e);return(0,t.jsxs)(c.Tooltip,{children:[(0,t.jsx)(c.TooltipTrigger,{asChild:!0,children:(0,t.jsx)("button",{type:"button",onClick:()=>r(e),"data-locked":m,className:(0,l.cn)("site-rounded-sm flex size-4 cursor-pointer items-center justify-center opacity-0 transition-opacity group-focus-within/picker:opacity-100 group-hover/picker:opacity-100 focus:opacity-100 data-[locked=true]:opacity-100 pointer-coarse:hidden",n),"aria-label":m?"Unlock":"Lock",children:(0,t.jsx)(a.HugeiconsIcon,{icon:m?i.SquareLock01Icon:o,strokeWidth:2,className:"text-site-foreground size-5"})})}),(0,t.jsx)(c.TooltipContent,{children:m?"Unlock":"Lock"})]})}var m=e.i(532753),h=e.i(26349);function f({...e}){return(0,t.jsx)(m.Menu.Root,{"data-slot":"dropdown-menu",...e})}function p({className:e,...n}){return(0,t.jsx)(m.Menu.Trigger,{"data-slot":"dropdown-menu-trigger",className:(0,l.cn)("font-site-sans hover:bg-site-muted data-popup-open:bg-site-muted border-site-foreground/10 bg-site-muted/50 site-rounded-xl md:site-rounded-lg relative w-[160px] shrink-0 touch-manipulation border p-2 select-none disabled:opacity-50 md:w-full md:border-transparent md:bg-transparent",e),...n})}function x({align:e="start",alignOffset:n=0,side:s="bottom",sideOffset:r=4,anchor:i,className:o,...a}){return(0,t.jsxs)(m.Menu.Portal,{children:[(0,t.jsx)(m.Menu.Positioner,{className:"isolate z-[220] outline-none",align:e,alignOffset:n,side:s,sideOffset:r,anchor:i,children:(0,t.jsx)(m.Menu.Popup,{"data-slot":"dropdown-menu-content",className:(0,l.cn)("font-site-sans data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 bg-site-popover text-site-popover-foreground cn-menu-target ring-site-foreground/10 no-scrollbar site-rounded-xl z-[220] max-h-(--available-height) w-[calc(var(--available-width)-(--spacing(3.5)))] min-w-32 origin-(--transform-origin) overflow-x-hidden overflow-y-auto border-0 p-1 shadow-md ring-1 duration-100 outline-none data-closed:overflow-hidden md:w-52",o),...a})}),(0,t.jsx)("div",{className:"absolute inset-0 z-[215] bg-transparent"})]})}function g({...e}){return(0,t.jsx)(m.Menu.Group,{"data-slot":"dropdown-menu-group",...e})}function v({className:e,inset:n,...s}){return(0,t.jsx)(m.Menu.GroupLabel,{"data-slot":"dropdown-menu-label","data-inset":n,className:(0,l.cn)("text-site-muted-foreground px-2 py-1.5 text-xs font-medium data-[inset]:pl-8",e),...s})}function b({className:e,inset:n,variant:s="default",...r}){return(0,t.jsx)(m.Menu.Item,{"data-slot":"dropdown-menu-item","data-inset":n,"data-variant":s,className:(0,l.cn)("focus:bg-site-accent focus:text-site-accent-foreground data-[variant=destructive]:text-site-destructive data-[variant=destructive]:focus:bg-site-destructive/10 dark:data-[variant=destructive]:focus:bg-site-destructive/20 data-[variant=destructive]:focus:text-site-destructive data-[variant=destructive]:*:[svg]:text-site-destructive not-data-[variant=destructive]:focus:**:text-site-accent-foreground group/dropdown-menu-item site-rounded-sm relative flex cursor-default items-center gap-2 px-2 py-1.5 text-sm outline-hidden select-none data-disabled:pointer-events-none data-disabled:opacity-50 data-[inset]:pl-8 pointer-coarse:py-2.5 pointer-coarse:pl-3 pointer-coarse:text-base [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...r})}function y({...e}){return(0,t.jsx)(m.Menu.RadioGroup,{"data-slot":"dropdown-menu-radio-group",...e})}function j({className:e,children:n,...s}){return(0,t.jsxs)(m.Menu.RadioItem,{"data-slot":"dropdown-menu-radio-item",className:(0,l.cn)("focus:bg-site-accent focus:text-site-accent-foreground focus:**:text-site-accent-foreground site-rounded-lg relative flex cursor-default items-center gap-2 py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 pointer-coarse:gap-3 pointer-coarse:py-2.5 pointer-coarse:pl-3 pointer-coarse:text-base [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...s,children:[(0,t.jsx)("span",{className:"pointer-events-none absolute right-2 flex items-center justify-center","data-slot":"dropdown-menu-radio-item-indicator",children:(0,t.jsx)(m.Menu.RadioItemIndicator,{children:(0,t.jsx)(h.CheckIcon,{className:"size-4 shrink-0 pointer-coarse:size-5"})})}),n]})}function C({className:e,...n}){return(0,t.jsx)(m.Menu.Separator,{"data-slot":"dropdown-menu-separator",className:(0,l.cn)("bg-site-border -mx-1 my-1 h-px",e),...n})}e.i(529809);var k=e.i(627946);e.s(["MenuAccentPicker",0,function({isMobile:e,anchorRef:i}){let[o,a]=n.useState(!1),[l,c]=(0,k.useDesignSystemSearchParams)(),[d,m]=(0,s.useConfig)();n.useEffect(()=>{a(!0)},[]);let h=l.menuAccent??d.menuAccent,v=r.MENU_ACCENTS.find(e=>e.value===h),b=n.useCallback(e=>{c({menuAccent:e}),m(t=>({...t,menuAccent:e}))},[c,m]);return(0,t.jsxs)("div",{className:"group/picker relative",children:[(0,t.jsxs)(f,{children:[(0,t.jsxs)(p,{children:[(0,t.jsxs)("div",{className:"flex flex-col justify-start text-left",children:[(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs",children:"Menu Accent"}),(0,t.jsx)("div",{className:"text-site-foreground text-sm font-medium",children:o?v?.label:"..."})]}),(0,t.jsx)("div",{className:"text-site-foreground pointer-events-none absolute top-1/2 right-2 flex size-4 -translate-y-1/2 items-center justify-center text-base select-none",children:(0,t.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"128",height:"128",viewBox:"0 0 24 24",fill:"none",className:"text-site-foreground",children:[(0,t.jsx)("path",{d:"M19 12.1294L12.9388 18.207C11.1557 19.9949 10.2641 20.8889 9.16993 20.987
17C8.98904 21.0041 8.80705 21.0041 8.62616 20.9877C7.53195 20.8889 6.64039 19.9949 4.85726 18.207L2.83687 16.1811C1.72104 15.0622 1.72104 13.2482 2.83687 12.1294M19 12.1294L10.9184 4.02587M19 12.1294H2.83687M10.9184 4.02587L2.83687 12.1294M10.9184 4.02587L8.89805 2",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","data-accent":v?.value,className:"data-[accent=bold]:fill-site-foreground fill-site-muted-foreground/30"}),(0,t.jsx)("path",{d:"M22 20C22 21.1046 21.1046 22 20 22C18.8954 22 18 21.1046 18 20C18 18.8954 20 17 20 17C20 17 22 18.8954 22 20Z",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","data-accent":v?.value,className:"data-[accent=bold]:fill-site-foreground fill-site-muted-foreground/30"})]})})]}),(0,t.jsx)(x,{anchor:e?i:void 0,side:e?"top":"right",align:e?"center":"start",children:(0,t.jsx)(y,{value:v?.value,onValueChange:b,children:(0,t.jsx)(g,{children:r.MENU_ACCENTS.map(e=>(0,t.jsx)(j,{value:e.value,children:e.label},e.value))})})})]}),(0,t.jsx)(u,{param:"menuAccent",className:"absolute top-1/2 right-8 -translate-y-1/2"})]})}],564053);var w=e.i(111114);function N(){let[e,t]=n.useState(!1);return n.useEffect(()=>{t(!0)},[]),e}var S=e.i(681184);e.s(["BaseColorPicker",0,function({isMobile:e,anchorRef:r}){let{resolvedTheme:i,setTheme:o}=(0,w.useTheme)(),a=N(),[l,c]=(0,k.useDesignSystemSearchParams)(),[d,m]=(0,s.useConfig)(),h=n.useMemo(()=>S.BASE_COLORS.find(e=>e.name===(l.baseColor??d.baseColor)),[l.baseColor,d.baseColor]),v=n.useCallback(e=>{"dark"===e?o("dark"===i?"light":"dark"):(c({baseColor:e}),m(t=>({...t,baseColor:e})))},[c,m,o,i]);return(0,t.jsxs)("div",{className:"group/picker relative",children:[(0,t.jsxs)(f,{children:[(0,t.jsxs)(p,{children:[(0,t.jsxs)("div",{className:"flex flex-col justify-start text-left",children:[(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs",children:"Base Color"}),(0,t.jsx)("div",{className:"text-site-foreground text-sm font-medium",children:a?h?.title:"..."})]}),a&&i&&(0,t.jsx)("div",{style:{"--color":h?.cssVars?.[i]?.["muted-foreground"]},className:"site-rounded-full pointer-events-none absolute top-1/2 right-2 size-4 -translate-y-1/2 bg-(--color) select-none"})]}),(0,t.jsx)(x,{anchor:e?r:void 0,side:e?"top":"right",align:e?"center":"start",children:(0,t.jsxs)(y,{value:h?.name,onValueChange:v,children:[(0,t.jsx)(g,{children:S.BASE_COLORS.map(e=>(0,t.jsx)(j,{value:e.name,children:(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[a&&i&&(0,t.jsx)("div",{style:{"--color":e.cssVars?.[i]?.["muted-foreground"]},className:"site-rounded-full size-4 bg-(--color)"}),e.title]})},e.name))}),(0,t.jsx)(C,{}),(0,t.jsx)(g,{children:(0,t.jsx)(b,{onClick:()=>{o("dark"===i?"light":"dark")},children:(0,t.jsxs)("div",{className:"flex flex-col justify-start pointer-coarse:gap-1",children:[(0,t.jsxs)("div",{children:["Switch to ","dark"===i?"Light":"Dark"," Mode"]}),(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs pointer-coarse:text-sm",children:"Base colors are easier to see in dark mode."})]})})})]})})]}),(0,t.jsx)(u,{param:"baseColor",className:"absolute top-1/2 right-8 -translate-y-1/2"})]})}],790636);var L=e.i(748445),E=e.i(187745);let A=(0,L.filterAvailableBases)(E.BASES);e.s(["BasePicker",0,function({isMobile:e,anchorRef:r}){let[i,o]=n.useState(!1),[a,l]=(0,k.useDesignSystemSearchParams)(),[c,d]=(0,s.useConfig)();n.useEffect(()=>{o(!0)},[]);let u=n.useMemo(()=>A.find(e=>e.name===(a.base??c.base))??A[0],[a.base,c.base]),m=n.useCallback(e=>{let t=A.find(t=>t.name===e);t&&(l({base:t.name}),d(e=>({...e,base:t.name})))},[l,d]);return(0,t.jsxs)(f,{children:[(0,t.jsxs)(p,{children:[(0,t.jsxs)("div",{className:"flex flex-col justify-start text-left",children:[(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs",children:"Component Library"}),(0,t.jsx)("div",{className:"text-site-foreground text-sm font-medium",children:i?u?.title:"..."})]}),i&&u?.meta?.logo&&(0,t.jsx)("div",{className:"text-site-foreground *:[svg]:text-site-foreground! pointer-events-none absolute top-1/2 right-2 size-4 -translate-y-1/2 select-none *:[svg]:size-4",dangerouslySetInnerHTML:{__html:u.meta.logo}})]}),(0,t.jsx)(x,{anchor:e?r:void 0,side:e?"top":"right",align:e?"center":"start",children:(0,t.jsx)(y,{value:u?.name,onValueChange:m,children:(0,t.jsx)(g,{children:A.map(e=>(0,t.jsxs)(j,{value:e.name,children:[e.meta?.logo&&(0,t.jsx)("div",{className:"text-site-foreground *:[svg]:text-site-foreground! size-4 shrink-0 [&_svg]:size-4",dangerouslySetInnerHTML:{__html:e.meta.logo}}),e.title]},e.name))})})})]})}],742536),e.s(["ChartColorPicker",0,function({isMobile:e,anchorRef:i}){let{resolvedTheme:o}=(0,w.useTheme)(),a=N(),[l,c]=(0,k.useDesignSystemSearchParams)(),[d,m]=(0,s.useConfig)(),h=l.baseColor??d.baseColor,v=n.useMemo(()=>(0,r.getThemesForBaseColor)(h),[h]),b=l.chartColor??d.chartColor,L=n.useMemo(()=>v.find(e=>e.name===b),[v,b]),E=n.useMemo(()=>S.BASE_COLORS.find(e=>e.name===b),[b]);n.useEffect(()=>{if(!L&&v.length>0){let e=v[0].name;c({chartColor:e}),m(t=>({...t,chartColor:e}))}},[L,v,c,m]);let A=n.useCallback(e=>{c({chartColor:e}),m(t=>({...t,chartColor:e}))},[c,m]);return(0,t.jsxs)("div",{className:"group/picker relative",children:[(0,t.jsxs)(f,{children:[(0,t.jsxs)(p,{children:[(0,t.jsxs)("div",{className:"min-w-0 flex-1 pr-10 text-left",children:[(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs",children:"Chart Color"}),(0,t.jsx)("div",{className:"text-site-foreground truncate text-sm font-medium",children:a?L?.title??"...":"..."})]}),a&&o?(0,t.jsx)("div",{style:{"--color":L?.cssVars?.[o]?.[E?"muted-foreground":"primary"]},className:"site-rounded-full pointer-events-none absolute top-1/2 right-2 size-4 -translate-y-1/2 bg-(--color) select-none"}):null]}),(0,t.jsx)(x,{anchor:e?i:void 0,side:e?"top":"right",align:e?"center":"start",className:"max-h-92",children:(0,t.jsxs)(y,{value:L?.name,onValueChange:A,children:[(0,t.jsx)(g,{children:v.filter(e=>S.BASE_COLORS.find(t=>t.name===e.name)).map(e=>{let n=S.BASE_COLORS.find(t=>t.name===e.name);return(0,t.jsx)(j,{value:e.name,children:(0,t.jsxs)("div",{className:"flex items-start gap-2",children:[a&&o&&(0,t.jsx)("div",{style:{"--color":e.cssVars?.[o]?.[n?"muted-foreground":"primary"]},className:"site-rounded-full size-4 translate-y-1 bg-(--color)"}),(0,t.jsxs)("div",{className:"flex flex-col justify-start pointer-coarse:gap-1",children:[(0,t.jsx)("div",{children:e.title}),(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs pointer-coarse:text-sm",children:"Match base color"})]})]})},e.name)})}),(0,t.jsx)(C,{}),(0,t.jsx)(g,{children:v.filter(e=>!S.BASE_COLORS.find(t=>t.name===e.name)).map(e=>(0,t.jsx)(j,{value:e.name,children:(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[a&&o&&(0,t.jsx)("div",{style:{"--color":e.cssVars?.[o]?.primary},className:"site-rounded-full size-4 bg-(--color)"}),e.title]})},e.name))})]})})]}),(0,t.jsx)(u,{param:"chartColor",className:"absolute top-1/2 right-8 -translate-y-1/2"})]})}],268543);var M=e.i(925928),T=e.i(466691),D=["neutral","stone","zinc","gray","amber","blue","cyan","emerald","fuchsia","green","indigo","lime","orange","pink","purple","red","rose","sky","teal","violet","yellow","mauve","olive","mist","taupe"],O=["inter","noto-sans","nunito-sans","figtree","roboto","raleway","dm-sans","public-sans","outfit","jetbrains-mono","geist","geist-mono","lora","merriweather","playfair-display","noto-serif","roboto-slab","oxanium","manrope","space-grotesk","montserrat","ibm-plex-sans","source-sans-3","instrument-sans","eb-garamond","instrument-serif"],z=["inherit",...O],P=[{key:"menuColor",values:["default","inverted","default-translucent","
1inverted-translucent"],bits:3},{key:"menuAccent",values:["subtle","bold"],bits:3},{key:"radius",values:["default","none","small","medium","large"],bits:4},{key:"font",values:O,bits:6},{key:"iconLibrary",values:["lucide","hugeicons","tabler","phosphor","remixicon"],bits:6},{key:"theme",values:D,bits:6},{key:"baseColor",values:["neutral","stone","zinc","gray","mauve","olive","mist","taupe"],bits:6},{key:"style",values:["nova","vega","maia","lyra","mira","luma","sera","rhea"],bits:6}],R=[...P,{key:"chartColor",values:D,bits:6},{key:"fontHeading",values:z,bits:5}],I=Object.fromEntries(R.map(e=>[e.key,e.values[0]])),H="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",F=["a","b"];e.s(["CopyPreset",0,function({className:e}){let[r]=(0,k.useDesignSystemSearchParams)(),[i]=(0,s.useConfig)(),o=n.useMemo(()=>(function(e){var t={style:e.style,baseColor:e.baseColor,theme:e.theme,chartColor:e.chartColor,iconLibrary:e.iconLibrary,font:e.font,fontHeading:e.fontHeading,radius:e.radius,menuAccent:e.menuAccent,menuColor:e.menuColor};let n={...I,...t},s=0,r=0;for(let e of R){let t=e.values.indexOf(n[e.key]);s+=(-1===t?0:t)*2**r,r+=e.bits}return"b"+function(e){if(0===e)return"0";let t="",n=e;for(;n>0;)t=H[n%62]+t,n=Math.floor(n/62);return t}(s)})({style:r.style??i.style,baseColor:r.baseColor??i.baseColor,theme:r.theme??i.theme,chartColor:r.chartColor??i.chartColor,iconLibrary:r.iconLibrary??i.iconLibrary,font:r.font??i.font,fontHeading:r.fontHeading??i.fontHeading,radius:r.radius??i.radius,menuAccent:r.menuAccent??i.menuAccent,menuColor:r.menuColor??i.menuColor}),[r.style,r.baseColor,r.theme,r.chartColor,r.iconLibrary,r.font,r.fontHeading,r.radius,r.menuAccent,r.menuColor,i.style,i.baseColor,i.theme,i.chartColor,i.iconLibrary,i.font,i.fontHeading,i.radius,i.menuAccent,i.menuColor]),[a,d]=n.useState(!1),u=a?"Copied!":`--preset ${o}`;n.useEffect(()=>{if(!a)return;let e=setTimeout(()=>d(!1),2e3);return()=>clearTimeout(e)},[a]);let m=n.useCallback(async()=>{try{await navigator.clipboard.writeText(`--preset ${o}`),d(!0)}catch{d(!0)}},[o]);return(0,t.jsxs)(c.Tooltip,{children:[(0,t.jsx)(c.TooltipTrigger,{asChild:!0,children:(0,t.jsxs)(T.Button,{type:"button",variant:"outline",size:"sm",onClick:m,"aria-label":`Copy preset flag: --preset ${o}`,className:(0,l.cn)("border-site-border bg-site-background text-site-foreground hover:bg-site-muted/60 site-rounded-md w-full justify-center gap-2 select-none",e),title:u,children:[(0,t.jsx)("span",{children:u}),a?(0,t.jsx)(h.CheckIcon,{className:"text-site-foreground size-3.5 shrink-0"}):(0,t.jsx)(M.CopyIcon,{className:"text-site-muted-foreground size-3.5 shrink-0"})]})}),(0,t.jsxs)(c.TooltipContent,{side:"right",children:["Copy ",(0,t.jsxs)("span",{className:"font-mono",children:["--preset ",o]})," to clipboard"]})]})}],305544);var _=e.i(398747),B=e.i(937980);e.s(["FontPicker",0,function({label:e,param:r,fonts:i,isMobile:o,anchorRef:a}){let l=N(),[c,d]=(0,k.useDesignSystemSearchParams)(),[m,h]=(0,s.useConfig)(),b="font"===r?c.font??m.font:c.fontHeading??m.fontHeading,w=n.useCallback(e=>{"font"===r?(d({font:e}),h(t=>({...t,font:e}))):(d({fontHeading:e}),h(t=>({...t,fontHeading:e})))},[r,d,h]),S=n.useMemo(()=>i.find(e=>e.value===b),[i,b]),L=n.useMemo(()=>B.FONTS.find(e=>e.value===(c.font??m.font)),[c.font,m.font]),E=L?.name??B.FONTS.find(e=>e.value===_.DEFAULT_CONFIG.font)?.name??"Inter",A="fontHeading"===r&&"inherit"===b?E:S?.name??E,M=n.useMemo(()=>{let e="fontHeading"===r?i.filter(e=>"inherit"!==e.value):i,t=new Map;for(let n of e){let e=t.get(n.type);if(e){e.push(n);continue}t.set(n.type,[n])}return Array.from(t.entries()).map(([e,t])=>({type:e,label:`${e.charAt(0).toUpperCase()}${e.slice(1)}`,items:t}))},[i,r]);return(0,t.jsxs)("div",{className:"group/picker relative",children:[(0,t.jsxs)(f,{children:[(0,t.jsxs)(p,{children:[(0,t.jsxs)("div",{className:"min-w-0 flex-1 pr-10 text-left",children:[(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs",children:e}),(0,t.jsx)("div",{className:"text-site-foreground truncate text-sm font-medium",children:l?A:"..."})]}),l?(0,t.jsx)("div",{className:"text-site-foreground pointer-events-none absolute top-1/2 right-2 flex size-4 -translate-y-1/2 items-center justify-center text-base select-none",style:{fontFamily:S?.font?.style.fontFamily??L?.font.style.fontFamily??B.FONTS.find(e=>e.value===_.DEFAULT_CONFIG.font)?.font.style.fontFamily},children:"Aa"}):(0,t.jsx)("div",{className:"pointer-events-none absolute top-1/2 right-2 size-4 -translate-y-1/2 select-none","aria-hidden":!0})]}),(0,t.jsx)(x,{anchor:o?a:void 0,side:o?"top":"right",align:o?"center":"start",className:"max-h-96",children:(0,t.jsxs)(y,{value:b??void 0,onValueChange:w,children:["fontHeading"===r?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(g,{children:(0,t.jsx)(j,{value:"inherit",children:(0,t.jsxs)("div",{className:"flex flex-col justify-start gap-0.5",children:[(0,t.jsx)("div",{children:"Inherit"}),(0,t.jsxs)("div",{className:"text-site-muted-foreground text-xs",children:["Use ",E," for headings too"]})]})})}),(0,t.jsx)(C,{})]}):null,M.map(e=>(0,t.jsxs)(g,{children:[(0,t.jsx)(v,{children:e.label}),e.items.map(e=>(0,t.jsx)(j,{value:e.value,children:(0,t.jsxs)("div",{className:"flex min-w-0 flex-col justify-start gap-0.5",children:[(0,t.jsx)("div",{children:e.name}),(0,t.jsx)("div",{className:"text-site-muted-foreground truncate text-xs",style:{fontFamily:e.font?.style.fontFamily},children:"Designers love packing quirky glyphs into test phrases."})]})},e.value))]},e.type))]})})]}),(0,t.jsx)(u,{param:r,className:"absolute top-1/2 right-8 -translate-y-1/2"})]})}],546131);var K=e.i(282879),V=e.i(924911),W=e.i(626519),U=e.i(3722);let $=(0,W.atom)(!1),Y=/^--preset\b\s+(.+)$/i,G="b2D0wqNxT";e.s(["OpenPreset",0,function({className:e,label:r="Open Preset"}){let[i,o]=n.useState(""),[,a]=(0,k.useDesignSystemSearchParams)(),[,d]=(0,s.useConfig)(),{open:u,setOpen:m}=function(){let[e,t]=(0,U.useAtom)($),s=n.useCallback(e=>{t(e)},[t]);return n.useEffect(()=>{let e=e=>{if("o"===e.key&&!e.shiftKey&&!e.metaKey&&!e.ctrlKey&&!e.altKey){var n;(n=e.target)instanceof HTMLElement&&n.isContentEditable||n instanceof HTMLInputElement||n instanceof HTMLTextAreaElement||n instanceof HTMLSelectElement||(e.preventDefault(),t(!0))}};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[t]),{open:e,setOpen:s}}(),h=n.useMemo(()=>(function(e){let t=e.trim();if(!t)return null;let n=t.match(Y)?.[1]?.trim()??t;return!function(e){if(!e||e.length<2||e.length>10||!F.includes(e[0]))return!1;for(let t=1;t<e.length;t++)if(-1===H.indexOf(e[t]))return!1;return!0}(n)?null:n})(i),[i]),f=i.trim().length>0&&null===h,p=n.useCallback(e=>{m(e),e||o("")},[m]),x=n.useCallback(e=>{if(e.preventDefault(),!h)return;let t=function(e){if(!e||e.length<2)return null;let t=e[0];if(!F.includes(t))return null;let n="a"===t?P:R,s=function(e){let t=0;for(let n=0;n<e.length;n++){let s=H.indexOf(e[n]);if(-1===s)return -1;t=62*t+s}return t}(e.slice(1));if(s<0)return null;let r={},i=0;for(let e of n){let t=Math.floor(s/2**i)%2**e.bits;r[e.key]=t<e.values.length?e.values[t]:e.values[0],i+=e.bits}return"a"===t&&(r.fontHeading="inherit"),r}
1(h);if(!t)return;let n={style:t.style,baseColor:t.baseColor,theme:t.theme,chartColor:t.chartColor??null,iconLibrary:t.iconLibrary,font:t.font,fontHeading:t.fontHeading,radius:t.radius,menuAccent:t.menuAccent,menuColor:t.menuColor};a(n),d(e=>({...e,...n,chartColor:n.chartColor??n.baseColor})),p(!1)},[p,h,d,a]);return(0,t.jsxs)(K.Dialog,{open:u,onOpenChange:p,children:[(0,t.jsxs)(c.Tooltip,{children:[(0,t.jsx)(c.TooltipTrigger,{asChild:!0,children:(0,t.jsx)(K.DialogTrigger,{asChild:!0,children:(0,t.jsx)(T.Button,{type:"button",variant:"outline",size:"sm",className:(0,l.cn)("border-site-border bg-site-background text-site-foreground hover:bg-site-muted/60 site-rounded-md w-full justify-center gap-2",e),children:(0,t.jsx)("span",{className:"text-sm",children:r})})})}),(0,t.jsx)(c.TooltipContent,{side:"right",children:"Load a saved preset code (press O)"})]}),(0,t.jsx)(K.DialogContent,{className:"font-site-sans text-site-foreground sm:max-w-md",children:(0,t.jsxs)("form",{onSubmit:x,className:"space-y-4",children:[(0,t.jsxs)(K.DialogHeader,{children:[(0,t.jsx)(K.DialogTitle,{className:"text-site-foreground",children:"Open Preset"}),(0,t.jsx)(K.DialogDescription,{className:"text-site-muted-foreground",children:"Paste a preset code to load a saved configuration."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{htmlFor:"preset-code",className:"sr-only",children:"Preset code"}),(0,t.jsx)(V.Input,{id:"preset-code",value:i,onChange:e=>o(e.target.value),placeholder:`${G} or --preset ${G}`,autoCapitalize:"none",autoCorrect:"off",spellCheck:!1,"aria-invalid":f}),f?(0,t.jsx)("p",{className:"text-site-destructive mt-2 text-xs",children:"That doesn't look like a valid preset code."}):null]}),(0,t.jsxs)(K.DialogFooter,{children:[(0,t.jsx)(K.DialogClose,{asChild:!0,children:(0,t.jsx)(T.Button,{type:"button",variant:"outline",children:"Cancel"})}),(0,t.jsx)(T.Button,{type:"submit",disabled:!h,children:"Open"})]})]})})]})}],628481);var X=e.i(373175),Z=e.i(928958),q=e.i(691116),Q=e.i(456080);let J=(0,X.default)(()=>e.A(613140).then(e=>({default:e.IconLibraryPreview})),{loadableGenerated:{modules:[902530]},ssr:!1,loading:()=>(0,t.jsx)("div",{className:"-mx-1 grid w-full grid-cols-7 gap-2",children:Array.from({length:14}).map((e,n)=>(0,t.jsx)("div",{className:"bg-site-muted site-rounded-sm size-6 animate-pulse"},n))})}),ee={lucide:(0,t.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",viewBox:"0 0 24 24",children:[(0,t.jsx)("path",{stroke:"currentColor",d:"M14 12a4 4 0 0 0-8 0 8 8 0 1 0 16 0 11.97 11.97 0 0 0-4-8.944"}),(0,t.jsx)("path",{stroke:"currentColor",d:"M10 12a4 4 0 0 0 8 0 8 8 0 1 0-16 0 11.97 11.97 0 0 0 4.063 9"})]}),tabler:(0,t.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",fill:"none",viewBox:"0 0 32 32",children:[(0,t.jsx)("path",{fill:"currentColor",d:"M31.288 7.107A8.83 8.83 0 0 0 24.893.712a55.9 55.9 0 0 0-17.786 0A8.83 8.83 0 0 0 .712 7.107a55.9 55.9 0 0 0 0 17.786 8.83 8.83 0 0 0 6.395 6.395c5.895.95 11.89.95 17.786 0a8.83 8.83 0 0 0 6.395-6.395c.95-5.895.95-11.89 0-17.786"}),(0,t.jsx)("path",{fill:"#fff",d:"m17.884 9.076 1.5-2.488 6.97 6.977-2.492 1.494zm-7.96 3.127 7.814-.909 3.91 3.66-.974 7.287-9.582 2.159a3.06 3.06 0 0 1-2.17-.329l5.244-4.897c.91.407 2.003.142 2.587-.626.584-.77.488-1.818-.226-2.484s-1.84-.755-2.664-.21c-.823.543-1.107 1.562-.67 2.412l-5.245 4.89a2.53 2.53 0 0 1-.339-2.017z"})]}),hugeicons:(0,t.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"128",height:"128",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",children:[(0,t.jsx)("path",{d:"M2 9.5H22",stroke:"currentColor"}),(0,t.jsx)("path",{d:"M20.5 9.5H3.5L4.23353 15.3682C4.59849 18.2879 4.78097 19.7477 5.77343 20.6239C6.76589 21.5 8.23708 21.5 11.1795 21.5H12.8205C15.7629 21.5 17.2341 21.5 18.2266 20.6239C19.219 19.7477 19.4015 18.2879 19.7665 15.3682L20.5 9.5Z",stroke:"currentColor"}),(0,t.jsx)("path",{d:"M5 9C5 5.41015 8.13401 2.5 12 2.5C15.866 2.5 19 5.41015 19 9",stroke:"currentColor"})]}),phosphor:(0,t.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:"32",height:"32",children:[(0,t.jsx)("path",{fill:"none",d:"M0 0h32v32H0z"}),(0,t.jsx)("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M9 5h9v16H9zm9 16v9a9 9 0 0 1-9-9M9 5l9 16m0 0h1a8 8 0 0 0 0-16h-1"})]}),remixicon:(0,t.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24",fill:"
1currentColor",children:(0,t.jsx)("path",{d:"M12 2C17.5228 2 22 6.47715 22 12C22 15.3137 19.3137 18 16 18C12.6863 18 10 15.3137 10 12C10 11.4477 9.55228 11 9 11C8.44772 11 8 11.4477 8 12C8 16.4183 11.5817 20 16 20C16.8708 20 17.7084 19.8588 18.4932 19.6016C16.7458 21.0956 14.4792 22 12 22C6.6689 22 2.3127 17.8283 2.0166 12.5713C2.23647 9.45772 4.83048 7 8 7C11.3137 7 14 9.68629 14 13C14 13.5523 14.4477 14 15 14C15.5523 14 16 13.5523 16 13C16 8.58172 12.4183 5 8 5C6.50513 5 5.1062 5.41032 3.90918 6.12402C5.72712 3.62515 8.67334 2 12 2Z"})})};function et({iconLibrary:e,value:n,previewEnabled:s}){return(0,t.jsx)(j,{value:n,className:"pr-2 *:data-[slot=dropdown-menu-radio-item-indicator]:hidden",children:(0,t.jsx)(q.Item,{size:"xs",children:(0,t.jsxs)(q.ItemContent,{className:"gap-1",children:[(0,t.jsx)(q.ItemTitle,{className:"text-site-muted-foreground text-xs font-medium",children:e.title}),s?(0,t.jsx)(J,{iconLibrary:e.name}):(0,t.jsx)("div",{className:"-mx-1 grid w-full grid-cols-7 gap-2",children:Array.from({length:14}).map((e,n)=>(0,t.jsx)("div",{className:"bg-site-muted site-rounded-sm size-6"},n))})]})})})}e.s(["IconLibraryPicker",0,function({isMobile:e,anchorRef:r}){let[i,o]=n.useState(!1),[a,l]=n.useState(!1),[c,d]=(0,k.useDesignSystemSearchParams)(),[m,h]=(0,s.useConfig)();n.useEffect(()=>{l(!0)},[]);let v=n.useMemo(()=>Q.iconLibraries[c.iconLibrary??m.iconLibrary],[c.iconLibrary,m.iconLibrary]),b=n.useCallback(e=>{d({iconLibrary:e}),h(t=>({...t,iconLibrary:e})),(0,Z.notifyIconLibraryChanged)()},[d,h]);return(0,t.jsxs)("div",{className:"group/picker relative",children:[(0,t.jsxs)(f,{open:i,onOpenChange:o,children:[(0,t.jsxs)(p,{children:[(0,t.jsxs)("div",{className:"min-w-0 flex-1 pr-10 text-left",children:[(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs",children:"Icon Library"}),(0,t.jsx)("div",{className:"text-site-foreground truncate text-sm font-medium",children:a?v?.title:"..."})]}),(0,t.jsx)("div",{className:"text-site-foreground *:[svg]:text-site-foreground! pointer-events-none absolute top-1/2 right-2 flex size-4 -translate-y-1/2 items-center justify-center text-base select-none",children:a&&ee[v?.name]})]}),(0,t.jsx)(x,{anchor:e?r:void 0,side:e?"top":"right",align:e?"center":"start",children:(0,t.jsx)(y,{value:v?.name,onValueChange:b,children:(0,t.jsx)(g,{children:Object.values(Q.iconLibraries).map((e,s)=>(0,t.jsxs)(n.Fragment,{children:[(0,t.jsx)(et,{iconLibrary:e,value:e.name,previewEnabled:i}),s<Object.values(Q.iconLibraries).length-1&&(0,t.jsx)(C,{className:"opacity-50"})]},e.name))})})})]}),(0,t.jsx)(u,{param:"iconLibrary",className:"absolute top-1/2 right-8 -translate-y-1/2"})]})}],665121);var en=e.i(630954),es=e.i(305761);e.s(["ModePicker",0,function(e){let[s,r]=n.useState(!1),{resolvedTheme:i,setTheme:o}=(0,w.useTheme)();n.useEffect(()=>{r(!0)},[]);let a="dark"===i?"dark":"light",c="dark"===a?"light":"dark",d=n.useCallback(()=>{o(c)},[c,o]);return(0,t.jsxs)("button",{type:"button",onClick:d,"aria-label":s?`Switch to ${c} mode`:"Toggle theme mode",title:s?`Switch to ${c} mode`:void 0,className:(0,l.cn)("font-site-sans hover:bg-site-muted border-site-foreground/10 bg-site-muted/50 site-rounded-xl md:site-rounded-lg relative w-[160px] shrink-0 touch-manipulation border p-2 text-left select-none disabled:opacity-50 md:w-full md:border-transparent md:bg-transparent","focus-visible:ring-site-ring focus-visible:ring-2 focus-visible:outline-none"),children:[(0,t.jsxs)("div",{className:"flex flex-col justify-start text-left",children:[(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs",children:"Mode"}),(0,t.jsx)("div",{className:"text-site-foreground text-sm font-medium",children:s?"dark"===a?"Dark":"Light":"..."})]}),s&&(0,t.jsx)("div",{className:"text-site-foreground pointer-events-none absolute top-1/2 right-2 flex size-4 -translate-y-1/2 items-center justify-center select-none",children:"dark"===a?(0,t.jsx)(en.MoonIcon,{className:"size-4"}):(0,t.jsx)(es.SunIcon,{className:"size-4"})})]})}],928775);let er=[["path",{d:"M4 5L16 5",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",key:"0"}],["path",{d:"M4 12L20 12",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",key:"1"}],["path",{d:"M4 19L12 19",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",key:"2"}]];function ei(e,t){return"default"===e?t?"default-translucent":"default":t?"inverted-translucent":"inverted"}let eo=[{value:"default",label:"Default / Solid"},{value:"default-translucent",label:"Default / Translucent"},{value:"inverted",label:"Inverted / Solid"},{value:"inverted-translucent",label:"Inverted / Translucent"}];e.s(["MenuColorPicker",0,function({isMobile:e,anchorRef:r}){let{resolvedTheme:i}=(0,w.useTheme)(),o=N(),[l,c]=(0,k.useDesignSystemSearchParams)(),[d,m]=(0,s.useConfig)(),h=l.menuColor??d.menuColor,b=o&&"dark"===i,S=(0,n.useRef)(l.menuAccent),L="inverted"===h||"inverted-translucent"===h?"inverted":"default",E="default-translucent"===h||"inverted-translucent"===h?"translucent":"solid",A=eo.find(e=>e.value===h);(0,n.useEffect)(()=>{"solid"===E&&(S.current=l.menuAccent)},[l.menuAccent,E]);let M=(0,n.useCallback)(e=>{let t=ei(e,"translucent"===E);c({menuColor:t,...(0,k.isTranslucentMenuColor)(t)&&{menuAccent:"subtle"}}),m(e=>({...e,menuColor:t}))},[E,c,m]),T=(0,n.useCallback)(e=>{let t="translucent"===e,n=ei(L,t),s=t?"subtle":S.current;c({menuColor:n,menuAccent:s}),m(e=>({...e,menuColor:n,menuAccent:s??e.menuAccent}))},[L,c,m]);return(0,t.jsxs)("div",{className:"group/picker relative",children:[(0,t.jsxs)(f,{children:[(0,t.jsxs)(p,{disabled:b&&"inverted"===L,children:[(0,t.jsxs)("div",{className:"min-w-0 flex-1 pr-10 text-left",children:[(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs",children:"Menu"}),(0,t.jsx)("div",{className:"text-site-foreground truncate text-sm font-medium",children:o?A?.label:"..."})]}),(0,t.jsx)("div",{className:"text-site-foreground pointer-events-none absolute top-1/2 right-2 flex size-4 -translate-y-1/2 items-center justify-center text-base select-none",children:(0,t.jsx)(a.HugeiconsIcon,{icon:er,strokeWidth:2,className:"size-4"})})]}),(0,t.jsxs)(x,{anchor:e?r:void 0,side:e?"top":"right",align:e?"center":"start",children:[(0,t.jsxs)(g,{children:[(0,t.jsx)(v,{children:"Color"}),(0,t.jsxs)(y,{value:L,onValueChange:e=>M(e),children:[(0,t.jsx)(j,{value:"default",closeOnClick:e,children:"Default"}),(0,t.jsx)(j,{value:"inverted",closeOnClick:e,disabled:b,children:"Inverted"})]})]}),(0,t.jsx)(C,{}),(0,t.jsxs)(g,{children:[(0,t.jsx)(v,{children:"Appearance"}),(0,t.jsxs)(y,{value:E,onValueChange:e=>T(e),children:[(0,t.jsx)(j,{value:"solid",closeOnClick:e,children:"Solid"}),(0,t.jsx)(j,{value:"translucent",closeOnClick:e,children:"Translucent"})]})]})]})]}),(0,t.jsx)(u,{param:"menuColor",className:"absolute top-1/2 right-8 -translate-y-1/2"})]})}],172185),e.s(["RadiusPicker",0,function({isMobile:e,anchorRef:i}){let[o,a]=n.useState(!1),[l,c]=(0,k.useDesignSystemSearchParams)(),[d,m]=(0,s.useConfig)();n.useEffect(()=>{a(!0)},[]);let h=l.radius??d.radius,v=r.RADII.find(e=>e.name===h),b=r.RADII.find(e=>"default"===e.name),w=r.RADII.filter(e=>"default"!==e.name),N=n.useCallback(e=>{c({radius:e}),m(t=>
1({...t,radius:e}))},[c,m]);return(0,t.jsxs)("div",{className:"group/picker relative",children:[(0,t.jsxs)(f,{children:[(0,t.jsxs)(p,{children:[(0,t.jsxs)("div",{className:"flex flex-col justify-start text-left",children:[(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs",children:"Radius"}),(0,t.jsx)("div",{className:"text-site-foreground text-sm font-medium",children:o?v?.label:"..."})]}),(0,t.jsx)("div",{className:"text-site-foreground pointer-events-none absolute top-1/2 right-2 flex size-4 -translate-y-1/2 rotate-90 items-center justify-center text-base select-none",children:(0,t.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",className:"text-site-foreground",children:(0,t.jsx)("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M4 20v-5C4 8.925 8.925 4 15 4h5"})})})]}),(0,t.jsx)(x,{anchor:e?i:void 0,side:e?"top":"right",align:e?"center":"start",children:(0,t.jsxs)(y,{value:v?.name,onValueChange:N,children:[(0,t.jsx)(g,{children:b&&(0,t.jsx)(j,{value:b.name,children:(0,t.jsxs)("div",{className:"flex flex-col justify-start pointer-coarse:gap-1",children:[(0,t.jsx)("div",{children:b.label}),(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs pointer-coarse:text-sm",children:"Use radius from style"})]})},b.name)}),(0,t.jsx)(C,{}),(0,t.jsx)(g,{children:w.map(e=>(0,t.jsx)(j,{value:e.name,children:e.label},e.name))})]})})]}),(0,t.jsx)(u,{param:"radius",className:"absolute top-1/2 right-8 -translate-y-1/2"})]})}],861463);var ea=e.i(580098),el=e.i(687732);let ec=(e,t)=>"lyra"===t.style?e.filter(e=>"jetbrains-mono"===e.value):e,ed=(e,t)=>"lyra"===t.style?e.filter(e=>"none"===e.name):e;function eu(e){return e[Math.floor(Math.random()*e.length)]}e.s(["RandomButton",0,function(){let{locks:e}=(0,d.useLocks)(),[i,o]=(0,k.useDesignSystemSearchParams)(),[a,l]=(0,s.useConfig)(),u=n.useMemo(()=>["inherit",...B.FONTS.map(e=>e.value)],[]),m=n.useMemo(()=>({baseColor:i.baseColor??a.baseColor,style:i.style??a.style,theme:i.theme??a.theme,chartColor:i.chartColor??a.chartColor,font:i.font??a.font,fontHeading:i.fontHeading??a.fontHeading,radius:i.radius??a.radius,iconLibrary:i.iconLibrary??a.iconLibrary,menuAccent:i.menuAccent??a.menuAccent,menuColor:i.menuColor??a.menuColor}),[i.baseColor,i.style,i.theme,i.chartColor,i.font,i.fontHeading,i.radius,i.iconLibrary,i.menuAccent,i.menuColor,a.baseColor,a.style,a.theme,a.chartColor,a.font,a.fontHeading,a.radius,a.iconLibrary,a.menuAccent,a.menuColor]),h=n.useCallback(()=>{var t,n,s,i,a,c;let d=e.has("baseColor")?m.baseColor:eu(S.BASE_COLORS).name,h=e.has("style")?m.style:eu(el.STYLES).name,f={style:h,baseColor:d},p=(0,r.getThemesForBaseColor)(d),x=(t=B.FONTS,n=f,(s=ec)?s(t,n):t),g=(i=r.RADII,a=f,(c=ed)?c(i,a):i),v=e.has("theme")?m.theme:eu(p).name,b=e.has("chartColor")?m.chartColor:eu(p).name,y=e.has("font")?m.font:eu(x).value,j=e.has("fontHeading")?m.fontHeading:eu(u),C=e.has("radius")?m.radius:eu(g).name,k=e.has("iconLibrary")?m.iconLibrary:eu(Object.values(Q.iconLibraries)).name,w=e.has("menuAccent")?m.menuAccent:eu(r.MENU_ACCENTS).value,N=e.has("menuColor")?m.menuColor:eu(r.MENU_COLORS).value;f.theme=v,f.font=y,f.radius=C;let L={style:h,baseColor:d,theme:v,chartColor:b,iconLibrary:k,font:y,fontHeading:j,menuAccent:w,menuColor:N,radius:C};o(Object.fromEntries(Object.entries(L).map(([e,t])=>
1[e,t===_.DEFAULT_CONFIG[e]?null:t]))),l(e=>({...e,...L})),(0,Z.notifyIconLibraryChanged)()},[o,l,e,m,u]);return n.useEffect(()=>{let e=e=>{("r"===e.key||"R"===e.key)&&!e.metaKey&&!e.ctrlKey&&(e.target instanceof HTMLElement&&e.target.isContentEditable||e.target instanceof HTMLInputElement||e.target instanceof HTMLTextAreaElement||e.target instanceof HTMLSelectElement||(e.preventDefault(),h()))};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[h]),(0,t.jsxs)(c.Tooltip,{children:[(0,t.jsx)(c.TooltipTrigger,{asChild:!0,children:(0,t.jsxs)(T.Button,{type:"button",variant:"outline",size:"sm",onClick:h,className:"border-site-border bg-site-background text-site-foreground hover:bg-site-muted/60 site-rounded-md w-full justify-center gap-2",children:[(0,t.jsx)("span",{className:"text-sm",children:"Shuffle"}),(0,t.jsx)(ea.Kbd,{className:"bg-site-muted text-site-muted-foreground",children:"R"})]})}),(0,t.jsx)(c.TooltipContent,{side:"right",children:"Shuffle to a random style — back/forward to navigate history"})]})}],103536);var em=e.i(878835);e.s(["ResetButton",0,function(){let[e,r]=(0,k.useDesignSystemSearchParams)(),[i,o]=(0,s.useConfig)(),a=n.useCallback(()=>{r({base:null,style:null,baseColor:null,theme:null,chartColor:null,iconLibrary:null,font:null,fontHeading:null,menuAccent:null,menuColor:null,radius:null,template:null,item:null,search:null}),o(e=>({...e,..._.DEFAULT_CONFIG})),(0,Z.notifyIconLibraryChanged)()},[r,o]);return(0,t.jsxs)(em.AlertDialog,{children:[(0,t.jsxs)(c.Tooltip,{children:[(0,t.jsx)(c.TooltipTrigger,{asChild:!0,children:(0,t.jsx)(em.AlertDialogTrigger,{asChild:!0,children:(0,t.jsx)(T.Button,{type:"button",variant:"outline",size:"sm",className:"border-site-border bg-site-background text-site-foreground hover:bg-site-muted/60 site-rounded-md w-full justify-center gap-2",children:(0,t.jsx)("span",{className:"text-sm",children:"Reset"})})})}),(0,t.jsx)(c.TooltipContent,{side:"right",children:"Reset all customization options to their defaults"})]}),(0,t.jsxs)(em.AlertDialogContent,{className:"dialog-ring p-4 sm:max-w-sm",children:[(0,t.jsxs)(em.AlertDialogHeader,{children:[(0,t.jsx)(em.AlertDialogTitle,{children:"Reset to defaults?"}),(0,t.jsx)(em.AlertDialogDescription,{children:"This will reset all customization options to their default values. This action cannot be undone."})]}),(0,t.jsxs)(em.AlertDialogFooter,{children:[(0,t.jsx)(em.AlertDialogCancel,{className:"site-rounded-lg",children:"Cancel"}),(0,t.jsx)(em.AlertDialogAction,{className:"site-rounded-lg",onClick:a,children:"Reset"})]})]})]})}],945820);var eh=e.i(569299);e.s(["StylePicker",0,function({styles:e,isMobile:r,anchorRef:i}){let[o,a]=n.useState(!1),[l,c]=(0,k.useDesignSystemSearchParams)(),[d,m]=(0,s.useConfig)();n.useEffect(()=>{a(!0)},[]);let h=l.style??d.style,v=e.find(e=>e.name===h),b=n.useCallback(e=>{let t=(0,eh.getRadiusForStyleSelection)(e);c({style:e,radius:t}),m(n=>({...n,style:e,radius:t}))},[c,m]);return(0,t.jsxs)("div",{className:"group/picker relative",children:[(0,t.jsxs)(f,{children:[(0,t.jsxs)(p,{children:[(0,t.jsxs)("div",{className:"flex flex-col justify-start text-left",children:[(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs",children:"Style"}),(0,t.jsx)("div",{className:"text-site-foreground text-sm font-medium",children:o?v?.title:"..."})]}),o&&v?.icon&&(0,t.jsx)("div",{className:"pointer-events-none absolute top-1/2 right-2 flex size-4 -translate-y-1/2 items-center justify-center select-none",children:n.cloneElement(v.icon,{className:"size-4"})})]}),(0,t.jsx)(x,{anchor:r?i:void 0,side:r?"top":"right",align:r?"center":"start",className:"md:w-64",children:(0,t.jsx)(y,{value:v?.name,onValueChange:b,children:(0,t.jsx)(g,{children:e.map((s,r)=>(0,t.jsxs)(n.Fragment,{children:[(0,t.jsx)(j,{value:s.name,children:(0,t.jsxs)("div",{className:"flex items-start gap-2",children:[s.icon&&(0,t.jsx)("div",{className:"flex size-4 translate-y-0.5 items-center justify-center",children:n.cloneElement(s.icon,{className:"size-4"})}),(0,t.jsxs)("div",{className:"flex flex-col justify-start pointer-coarse:gap-1",children:[(0,t.jsx)("div",{children:s.title}),(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs pointer-coarse:text-sm",children:s.description})]})]})}),r<e.length-1&&(0,t.jsx)(C,{className:"opacity-50"})]},s.name))})})})]}),(0,t.jsx)(u,{param:"style",className:"absolute top-1/2 right-8 -translate-y-1/2"})]})}],975490),e.s(["ThemePicker",0,function({themes:e,isMobile:r,anchorRef:i}){let{resolvedTheme:o}=(0,w.useTheme)(),a=N(),[l,c]=(0,k.useDesignSystemSearchParams)(),[d,m]=(0,s.useConfig)(),h=n.useMemo(()=>e.find(e=>e.name===(l.theme??d.theme)),[e,l.theme,d.theme]),v=n.useMemo(()=>S.BASE_COLORS.find(e=>e.name===(l.theme??d.theme)),[l.theme,d.theme]),b=n.useCallback(e=>{c({theme:e}),m(t=>({...t,theme:e}))},[c,m]);return n.useEffect(()=>{if(!h&&e.length>0){let t=e[0].name;l.theme&&c({theme:t}),m(e=>({...e,theme:t}))}},[h,e,c,m,l.theme]),(0,t.jsxs)("div",{className:"group/picker relative",children:[(0,t.jsxs)(f,{children:[(0,t.jsxs)(p,{children:[(0,t.jsxs)("div",{className:"min-w-0 flex-1 pr-10 text-left",children:[(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs",children:"Theme"}),(0,t.jsx)("div",{className:"text-site-foreground truncate text-sm font-medium",children:a?h?.title:"..."})]}),a&&o&&(0,t.jsx)("div",{style:{"--color":h?.cssVars?.[o]?.[v?"muted-foreground":"primary"]},className:"site-rounded-full pointer-events-none absolute top-1/2 right-2 size-4 -translate-y-1/2 bg-(--color) select-none"})]}),(0,t.jsx)(x,{anchor:r?i:void 0,side:r?"top":"right",align:r?"center":"start",className:"max-h-96",children:(0,t.jsxs)(y,{value:h?.name,onValueChange:b,children:[(0,t.jsx)(g,{children:e.filter(e=>S.BASE_COLORS.find(t=>t.name===e.name)).map(e=>{let n=S.BASE_COLORS.find(t=>t.name===e.name);return(0,t.jsx)(j,{value:e.name,children:(0,t.jsxs)("div",{className:"flex items-start gap-2",children:[a&&o&&(0,t.jsx)("div",{style:{"--color":e.cssVars?.[o]?.[n?"muted-foreground":"primary"]},className:"site-rounded-full size-4 translate-y-1 bg-(--color)"}),(0,t.jsxs)("div",{className:"flex flex-col justify-start pointer-coarse:gap-1",children:[(0,t.jsx)("div",{children:e.title}),(0,t.jsx)("div",{className:"text-site-muted-foreground text-xs pointer-coarse:text-sm",children:"Match base color"})]})]})},e.name)})}),(0,t.jsx)(C,{}),(0,t.jsx)(g,{children:e.filter(e=>!S.BASE_COLORS.find(t=>t.name===e.name)).map(e=>(0,t.jsx)(j,{value:e.name,children:(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[a&&o&&(0,t.jsx)("div",{style:{"--color":e.cssVars?.[o]?.primary},className:"site-rounded-full size-4 bg-(--color)"}),e.title]})},e.name))})]})})]}),(0,t.jsx)(u,{param:"theme",className:"absolute top-1/2 right-8 -translate-y-1/2"})]})}],771050)},732962,e=>{"use strict";var t=e.i(135809),n=e.i(880745),s=e.i(155351),r=e.i(399358),i=e.i(534792),o=e.i(674750),a=e.i(550145);let l={enabled:!1,open:null,openSource:null,candidate:null,candidateSource:null,candidateSince:0,closeAt:null,lastShownAt:-1/0,scrolling:!1,awaitingMove:!1,pressed:!1,pressedKey:null,focusKey:null};function c(e){return null===e.open&&null===e.candidate&&null===e.closeAt?e:{...e,open:null,openSource:null,candidate:null,candidateSource:null,closeAt:null}}function d(e,t,n){let s=e;return null!==s.pressedKey&&(s={...s,pressedKey:null}),"pointer"===s.candidateSource&&(s={...s,candidate:null,candidateSource:null}),null!==s.open&&"pointer"===s.openSource&&null===s.closeAt&&(s={...s,closeAt:t+n.closeGraceMs,lastShownAt:t}),s}function u(e){let t=null===e.focusKey?e:{...e,focusKey:null};return"focus"===t.candidateSource&&(t={...t,candidate:null,candidateSource:null}),null!==t.open&&"focus"===t.openSource&&(t={...t,open:null,openSource:null,closeAt:null}),t}function m(e){return!e.scrolling&&!e.pressed&&("focus"===e.candidateSource||!e.awaitingMove)}let h="data-hover-preview",f=o.HOVER_OPEN_DELAY_MS,p={groupWindowMs:300,closeGraceMs:100};function x(e,t){if(!(e instanceof Element))return null;let n=e.closest(`[${h}]`);return n&&t.contains(n)?n:null}let g={target:null,instant:!1},v=new Set(["scroll","press","move","dismiss","enable"]);function b(e){return e?.getAttribute(h)||null}class y{state=l;config;snapshot=g;listeners=new Set;elements=new Map;wakeAt=null;wakeTimer;scrollEndTimer;lastScrollAt=0;pointerX=NaN;pointerY=NaN;pointerMoved=null;attached=!1;keyboardInput=!1;focusFollowAt=-1/0;placers=new Set;resizeObserver=null;siblingObserver=null;resizeTarget=null;constructor(e){this.config={openDelayMs:e,...p}}subscribe=e=>(this.listeners.add(e),()=>{this.listeners.delete(e)});getSnapshot=()=>this.snapshot;dismiss=()=>this.dispatch({type:"dismiss"});isFocusCard=e=>this.state.open===e&&"focus"===this.state.openSource;onReposition=e=>(this.placers.add(e),()=>{this.placers.delete(e)});dispatch(e){let t=function(e,t,n){if("enable"===t.type)return t.enabled===e.enabled?e:t.enabled?{...e,enabled:!0}:l;if(!e.enabled)return e;switch(t.type){case"dismiss":{let n=c(e);if(!t.stick)return n===e&&n.lastShownAt===-1/0?e:{...n,lastShownAt:-1/0};if(n===e&&null===n.focusKey&&n.lastShownAt===-1/0)return e;return{...n,pressedKey:e.open??e.candidate??n.pressedKey,focusKey:null,lastShownAt:-1/0}}case"scroll":if(e.scrolling)return e;return{...c(e),scrolling:!0,awaitingMove:!0,lastShownAt:-1/0};case"scrollEnd":{if(!e.scrolling)return e;let n={...e,scrolling:!1};if(null!==n.focusKey&&!n.pressed)return{...n,candidate:n.focusKey,candidateSource:"focus",candidateSince:t.at};return n}case"press":return{...c(e),pressed:!0,pressedKey:t.key,lastShownAt:-1/0};case"release":return e.pressed?{...e,pressed:!1}:e;case"leave":return d(e,t.at,n);case"move":{if(0!==t.buttons)return c(e);let s=e.pressed?{...e,pressed:!1}:e;if(!(t.moved??!s.awaitingMove)||s.scrolling)return s;s.awaitingMove&&(s={...s,awaitingMove:!1}),null!==s.focusKey&&(s={...s,focusKey:null});let r=t.key;if(null===r)return d(s,t.at,n);if(r===s.pressedKey)return s;if(null!==s.pressedKey&&(s={...s,pressedKey:null}),s.open===r)return null===s.closeAt&&"pointer"===s.openSource?s:{...s,closeAt:null,openSource:"pointer"};if(null!==s.open||t.at-s.lastShownAt<=n.groupWindowMs)return{...s,open:r,openSource:"pointer",candidate:null,candidateSource:null,closeAt:null};if(s.candidate===r&&"pointer"===s.candidateSource)return s;return{...s,candidate:r,candidateSource:"pointer",candidateSince:t.at}}case"focus":{if(null===t.key)return u(e);let n=e.focusKey===t.key?e:{...e,focusKey:t.key};if(n.scrolling||n.pressed||n.open===t.key)return n;if(null!==n.open)return{...n,open:t.key,openSource:"focus",candidate:null,candidateSource:null,closeAt:null};return{...n,candidate:t.key,candidateSource:"focus",candidateSince:t.at}}case"blur":return u(e);case"tick":{let s=e;return null!==s.closeAt&&t.at>=s.closeAt&&(s={...s,open:null,openSource:null,closeAt:null}),null!==s.candidate&&null===s.open&&m(s)&&t.at>=s.candidateSince+n.openDelayMs&&(s={...s,open:s.candidate,openSource:s.candidateSource,candidate:null,candidateSource:null}),s}}}(this.state,e,this.config);t!==this.state&&(this.state=t,"focus"!==t.openSource&&this.stopFollowingResize(),this.schedule(),this.sync(e))}schedule(){let e=function(e,t){if(!e.enabled)return null;let n=e.closeAt;if(null!==e.candidate&&null===e.open&&m(e)){let s=e.candidateSince+t.openDelayMs;n=null===n?s:Math.min(n,s)}return n}(this.state,this.config);e===this.wakeAt||(window.clearTimeout(this.wakeTimer),this.wakeTimer=void 0,this.wakeAt=e,null!==e&&(this.wakeTimer=window.setTimeout(()=>{this.wakeTimer=void 0,this.wakeAt=null,this.dispatch({type:"tick",at:performance.now()}),this.schedule()},Math.max(0,Math.ceil(e-performance.now())))))}sync(e){let t=this.state.open;if(t!==(this.snapshot.target?.key??null)){let n=t?this.elements.get(t):void 0,s=t&&n?{key:t,...n}:null;for(let t of(this.snapshot={target:s,instant:null===s&&v.has(e.type)},this.listeners))t()}for(let e of this.elements.keys())e!==this.state.open&&e!==this.state.candidate&&e!==this.state.focusKey&&this.elements.delete(e)}handleDocumentPointerMove=e=>{this.pointerMoved=Number.isNaN(this.pointerX)?null:e.clientX!==this.pointerX||e.clientY!==this.pointerY,this.pointerX=e.clientX,this.pointerY=e.clientY,this.pointerMoved&&(this.keyboardInput=!1)};handleDocumentPointerDown=e=>{this.keyboardInput=!1;let t=e.target instanceof Element?e.target.closest(`[${h}]`):null;this.dispatch({type:"press",key:b(t),at:performance.now()})};handleDocumentKeyDown=e=>{this.keyboardInput=!0,"Escape"===e.key&&(null!==this.state.open||null!==this.state.candidate)&&this.dispatch({type:"dismiss",stick:!0})};handleDocumentFocusIn=e=>{let t=this.state.open??this.state.candidate,n=e.target;null!==t&&n instanceof Node&&n!==document.body&&(this.elements.get(t)?.side.contains(n)||this.dismiss())};handleRelease=()=>this.dispatch({type:"release",at:performance.now()});handleScroll=e=>{if(!this.state.scrolling&&this.followsFocus(e.target)){this.focusFollowAt=performance.now(),this.reposition(),this.followResize(e.target);return}this.noteScroll()};reposition=()=>{for(let e of this.placers)e()};followResize(e){"focus"===this.state.openSource&&e instanceof Element&&e!==this.resizeTarget&&"u">typeof ResizeObserver&&(this.resizeObserver??=new ResizeObserver(this.reposition),this.siblingObserver??=new MutationObserver(this.reposition),this.resizeObserver.disconnect(),this.siblingObserver.disconnect(),this.resizeObserver.observe(e),e.parentElement&&this.siblingObserver.observe(e.parentElement,{childList:!0}),this.resizeTarget=e)}stopFollowingResize(){null!==this.resizeTarget&&(this.resizeObserver?.disconnect(),this.siblingObserver?.disconnect(),this.resizeTarget=null)}handleWheel=()=>{this.focusFollowAt=-1/0,this.noteScroll()};followsFocus(e){let t=this.state.focusKey;if(!this.keyboardInput||null===t||performance.now()-this.focusFollowAt>100)return!1;let n=this.elements.get(t)?.row;return!!(n&&e instanceof Node&&e.contains(n))}noteScroll(){this.lastScrollAt=performance.now(),this.state.scrolling||this.dispatch({type:"scroll",at:this.lastScrollAt}),void 0===this.scrollEndTimer&&this.armScrollEnd(150)}armScrollEnd(e){this.scrollEndTimer=window.setTimeout(()=>{this.scrollEndTimer=void 0;let e=performance.now()-this.lastScrollAt;e<150?this.armScrollEnd(150-e):this.endScroll()},e)}handleScrollEnd=()=>{window.clearTimeout(this.scrollEndTimer),this.scrollEndTimer=void 0,this.endScroll()};endScroll(){let e=this.state.focusKey;if(this.state.scrolling&&null!==e){let t=this.elements.get(e)?.row;t&&C(t)||this.dispatch({type:"blur",at:performance.now()})}this.dispatch({type:"scrollEnd",at:performance.now()})}handlePointerMove=e=>{if("touch"===e.pointerType)return;let t=x(e.target,e.currentTarget),n=b(t);
1t&&n&&this.elements.set(n,{row:t,side:e.currentTarget}),this.dispatch({type:"move",key:n,moved:this.pointerMoved,buttons:e.buttons,at:performance.now()})};handlePointerLeave=e=>{"touch"!==e.pointerType&&this.dispatch({type:"leave",at:performance.now()})};handleFocus=e=>{let t=e.target;if(!this.keyboardInput||!(t instanceof HTMLElement)||!t.matches(":focus-visible"))return void this.dispatch({type:"blur",at:performance.now()});let n=x(t,e.currentTarget),s=b(n);n&&s&&this.elements.set(s,{row:n,side:e.currentTarget}),this.dispatch({type:"focus",key:s,at:performance.now()}),s&&(this.focusFollowAt=performance.now())};handleBlur=e=>{let t=e.relatedTarget;t instanceof Node&&e.currentTarget.contains(t)||this.dispatch({type:"blur",at:performance.now()})};listProps={onPointerMove:this.handlePointerMove,onPointerLeave:this.handlePointerLeave,onWheel:this.handleWheel,onFocus:this.handleFocus,onBlur:this.handleBlur};attach(){if(this.attached)return;this.attached=!0;let e={capture:!0,passive:!0};document.addEventListener("keydown",this.handleDocumentKeyDown,e),document.addEventListener("focusin",this.handleDocumentFocusIn,e),document.addEventListener("pointermove",this.handleDocumentPointerMove,e),document.addEventListener("pointerdown",this.handleDocumentPointerDown,e),document.addEventListener("pointerup",this.handleRelease,e),document.addEventListener("pointercancel",this.handleRelease,e),document.addEventListener("scroll",this.handleScroll,e),document.addEventListener("scrollend",this.handleScrollEnd,e),window.addEventListener("blur",this.handleRelease),this.dispatch({type:"enable",enabled:!0})}detach(){if(!this.attached)return;this.attached=!1;let e={capture:!0};document.removeEventListener("keydown",this.handleDocumentKeyDown,e),document.removeEventListener("focusin",this.handleDocumentFocusIn,e),document.removeEventListener("pointermove",this.handleDocumentPointerMove,e),document.removeEventListener("pointerdown",this.handleDocumentPointerDown,e),document.removeEventListener("pointerup",this.handleRelease,e),document.removeEventListener("pointercancel",this.handleRelease,e),document.removeEventListener("scroll",this.handleScroll,e),document.removeEventListener("scrollend",this.handleScrollEnd,e),window.removeEventListener("blur",this.handleRelease),window.clearTimeout(this.wakeTimer),window.clearTimeout(this.scrollEndTimer),this.wakeTimer=void 0,this.scrollEndTimer=void 0,this.wakeAt=null,this.dispatch({type:"enable",enabled:!1}),this.elements.clear(),this.pointerX=NaN,this.pointerY=NaN,this.pointerMoved=null,this.keyboardInput=!1,this.focusFollowAt=-1/0}}let j=()=>g;function C(e){let t=e.getBoundingClientRect();if(0===t.height)return!1;let n=0,s=document.documentElement.clientHeight;for(let t=e.parentElement;t&&t!==document.body;t=t.parentElement){if("visible"===getComputedStyle(t).overflowY)continue;let e=t.getBoundingClientRect();n=Math.max(n,e.top),s=Math.min(s,e.bottom)}return t.bottom>n&&t.top<s}e.s(["POPUP_PREVIEW_OPEN_DELAY_MS",0,f,"POPUP_PREVIEW_SIDE_OFFSET_PX",0,6,"PreviewHoverCard",0,function({controller:e,resolve:r,sideOffset:o,boundary:l}){let{target:c,instant:d}=n.useSyncExternalStore(e.subscribe,e.getSnapshot,j),u=n.useRef(null),m=n.useRef(!1),h=n.useRef(()=>{}),f=n.useRef(null);n.useLayoutEffect(()=>{if(!c)return;if(!c.row.isConnected)return void e.dismiss();let t=f.current;!t||t.row!==c.row||.5>=Math.abs(c.row.getBoundingClientRect().top-t.top)||(e.isFocusCard(c.key)?h.current():e.dismiss())});let[p,x]=n.useState(null);c&&c!==p&&x(c),!c&&d&&null!==p&&x(null);let g=c??(d?null:p),v=null===c&&!d&&null!==p;n.useEffect(()=>{if(!v)return;let e=window.setTimeout(()=>x(null),150);return()=>window.clearTimeout(e)},[v]);let b=g?.key??null,y=n.useMemo(()=>b?r(b):null,[b,r]),k=(0,a.useIsDarkTheme)(),[w,N]=n.useState(()=>new Set),[S,L]=n.useState(null),E=y?k&&y.image.dark?y.image.dark:y.image.light:null,A=y&&E&&w.has(E)&&E!==y.image.light?y.image.light:E,[M,T]=n.useState(null),D=y&&void 0===y.description?y.loadDescription:void 0,O=y?.description!==void 0?y.description:M&&M.key===b?M.text:void 0,z=void 0===O&&!!D;if(n.useEffect(()=>{if(!b||!D)return;let e=!0;return D().then(t=>{e&&T({key:b,text:t})}),()=>{e=!1}},[b,D]),n.useLayoutEffect(()=>{let e=()=>{let e=u.current;if(!e||!g){m.current=!1,f.current=null;return}if(v){f.current=null;return}f.current={row:g.row,top:g.row.getBoundingClientRect().top};let t=function(e,t,n,s){if(!e.row.isConnected||!e.side.isConnected||!C(e.row))return null;let r=document.documentElement.clientWidth,i=document.documentElement.clientHeight,o=(s&&e.side.closest(s)||e.side).getBoundingClientRect(),a=e.row.getBoundingClientRect(),l=o.right+n;return l+320>r-16&&(l=o.left-n-320)<16?null:{x:Math.round(l),y:Math.round(Math.min(Math.max(a.top+a.height/2-t/2,16),Math.max(16,i-16-t)))}}(g,e.offsetHeight,o,l);if(!t){e.style.visibility="hidden";return}e.style.visibility="",e.style.transition=m.current?"":"none",e.style.transform=`translate3d(${t.x}px, ${t.y}px, 0)`,m.current=!0};h.current=e,e()},[g,v,O,z,o,l]),n.useEffect(()=>e.onReposition(()=>h.current()),[e]),!g||!y||!A)return null;let P=O||(z?null:y.title);return(0,s.createPortal)((0,t.jsx)("div",{ref:u,"aria-hidden":"true","data-slot":"preview-hover-card",className:"pointer-events-none fixed top-0 left-0 z-[70] transition-transform duration-150 ease-out motion-reduce:transition-none",style:{width:320},children:(0,t.jsxs)("div",{"data-state":v?"closed":"open",onTransitionEnd:e=>{v&&e.target===e.currentTarget&&"opacity"===e.propertyName&&x(null)},className:"bg-site-popover text-site-popover-foreground site-rounded-md overflow-hidden border shadow-md transition-[opacity,scale] duration-150 data-[state=closed]:scale-95 data-[state=closed]:opacity-0 data-[state=closed]:duration-100 motion-reduce:transition-none starting:scale-95 starting:opacity-0",children:[(0,t.jsx)(a.PreviewThumbnailPlate,{imageKey:A,image:{light:A,dark:null},loaded:S===A,onLoad:()=>L(A),onError:()=>{A!==y.image.light?N(e=>new Set(e).add(A)):L(A)}}),(0,t.jsxs)("div",{className:"border-site-border/60 border-t px-3 py-2",children:[(0,t.jsx)(a.PreviewCardCrumbs,{label:y.breadcrumb}),P?(0,t.jsx)("p",{className:"text-site-foreground mt-1 line-clamp-4 text-[13px] leading-snug font-normal",children:P}):(0,t.jsxs)("div",{className:"mt-1.5 flex flex-col gap-1.5 pb-0.5",children:[(0,t.jsx)(i.Skeleton,{className:"h-3.5 w-full motion-reduce:animate-none"}),(0,t.jsx)(i.Skeleton,{className:"h-3.5 w-3/5 motion-reduce:animate-none"})]})]})]})}),document.body)},"SIDEBAR_PREVIEW_OPEN_DELAY_MS",0,300,"SIDEBAR_PREVIEW_SIDE_OFFSET_PX",0,14,"usePreviewHover",0,function(e){let[t]=n.useState(()=>new y(e)),s=!0===(0,r.useMediaQuery)("(hover: hover) and (pointer: fine)");return n.useEffect(()=>{if(s)return t.attach(),()=>t.detach()},[t,s]),t}],732962)},491247,e=>{"use strict";var t=e.i(834765);e.s(["PanelLeftClose",()=>t.default])}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.