@gradeui/ui 0.1.1 → 0.2.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.
- package/README.md +1 -1
- package/dist/index.d.mts +30 -20
- package/dist/index.d.ts +30 -20
- package/dist/index.js +30 -30
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +30 -30
- package/dist/index.mjs.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/tailwind-preset.d.mts +1 -1
- package/dist/tailwind-preset.d.ts +1 -1
- package/dist/tailwind-preset.js +1 -1
- package/dist/tailwind-preset.js.map +1 -1
- package/dist/tailwind-preset.mjs +1 -1
- package/dist/tailwind-preset.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import*as c from'react';import {useRef,useEffect}from'react';import*as E from'@radix-ui/react-accordion';import {ChevronDown,Check,X as X$1,ChevronRight,Circle,ChevronUp,ChevronLeft,Menu,Palette,Download,Trash2,SunDim,Sun,Moon,MoonStar}from'lucide-react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {cva}from'class-variance-authority';import {Slot}from'@radix-ui/react-slot';import*as ne from'@radix-ui/react-checkbox';import*as w from'@radix-ui/react-dialog';import*as u from'@radix-ui/react-dropdown-menu';import*as Ie from'@radix-ui/react-label';import*as de from'@radix-ui/react-progress';import*as Y from'@radix-ui/react-radio-group';import*as A from'@radix-ui/react-scroll-area';import*as f from'@radix-ui/react-select';import*as Fe from'@radix-ui/react-separator';import*as _ from'@radix-ui/react-slider';import*as ce from'@radix-ui/react-switch';import*as G from'@radix-ui/react-tabs';import*as K from'@radix-ui/react-tooltip';import Fo from'lenis';import*as W from'@radix-ui/react-popover';function a(...e){return twMerge(clsx(e))}var _r=E.Root,ot=c.forwardRef(({className:e,...t},r)=>c.createElement(E.Item,{ref:r,className:a("border-b",e),...t}));ot.displayName="AccordionItem";var at=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(E.Header,{className:"flex"},c.createElement(E.Trigger,{ref:o,className:a("flex flex-1 items-center justify-between py-4 font-medium transition-all hover:underline [&[data-state=open]>svg]:rotate-180",e),...r},t,c.createElement(ChevronDown,{className:"h-4 w-4 shrink-0 transition-transform duration-200"}))));at.displayName=E.Trigger.displayName;var it=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(E.Content,{ref:o,className:"overflow-hidden text-sm transition-all data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down",...r},c.createElement("div",{className:a("pb-4 pt-0",e)},t)));it.displayName=E.Content.displayName;var jr=cva("relative w-full rounded-lg border p-4 [&>svg~*]:pl-7 [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4",{variants:{variant:{default:"bg-background text-foreground [&>svg]:text-foreground",destructive:"border-destructive/50 bg-destructive/10 text-destructive [&>svg]:text-destructive",success:"border-success/40 bg-success/10 text-success [&>svg]:text-success",warning:"border-warning/40 bg-warning/10 text-warning [&>svg]:text-warning",info:"border-info/40 bg-info/10 text-info [&>svg]:text-info",highlight:"border-highlight/40 bg-highlight/10 text-foreground [&>svg]:text-highlight"}},defaultVariants:{variant:"default"}}),nt=c.forwardRef(({className:e,variant:t,...r},o)=>c.createElement("div",{ref:o,role:"alert",className:a(jr({variant:t}),e),...r}));nt.displayName="Alert";var st=c.forwardRef(({className:e,...t},r)=>c.createElement("h5",{ref:r,className:a("mb-1 font-medium leading-none tracking-tight",e),...t}));st.displayName="AlertTitle";var dt=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("text-sm [&_p]:leading-relaxed",e),...t}));dt.displayName="AlertDescription";var ct=cva("inline-flex items-center gap-1 border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 [&_svg]:size-3 [&_svg]:shrink-0",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground shadow hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground shadow hover:bg-destructive/80",outline:"text-foreground",highlight:"border-transparent bg-rds-yellow-400 text-rds-gray-900 shadow hover:bg-rds-yellow-500",success:"border-transparent bg-rds-green-500 text-rds-gray-900 shadow hover:bg-rds-green-600",warning:"border-transparent bg-orange-500 text-white shadow hover:bg-orange-600",info:"border-transparent bg-blue-500 text-white shadow hover:bg-blue-600","success-soft":"border-rds-green-500/20 bg-rds-green-500/10 text-rds-green-600 dark:text-rds-green-400","warning-soft":"border-orange-500/20 bg-orange-500/10 text-orange-600 dark:text-orange-400","destructive-soft":"border-destructive/20 bg-destructive/10 text-destructive dark:text-red-400","info-soft":"border-blue-500/20 bg-blue-500/10 text-blue-600 dark:text-blue-400","highlight-soft":"border-rds-yellow-500/20 bg-rds-yellow-400/10 text-rds-yellow-600 dark:text-rds-yellow-400","success-outline":"border-rds-green-500/50 bg-transparent text-rds-green-600 dark:text-rds-green-400","warning-outline":"border-orange-500/50 bg-transparent text-orange-600 dark:text-orange-400","destructive-outline":"border-destructive/50 bg-transparent text-destructive dark:text-red-400","info-outline":"border-blue-500/50 bg-transparent text-blue-600 dark:text-blue-400"},rounded:{default:"rounded-md",full:"rounded-full"}},defaultVariants:{variant:"default",rounded:"default"}});function Yr({className:e,variant:t,rounded:r,...o}){return c.createElement("div",{className:a(ct({variant:t,rounded:r}),e),...o})}var pt=cva("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground shadow hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",outline:"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded-md px-3 text-xs",lg:"h-10 rounded-md px-8",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),oe=c.forwardRef(({className:e,variant:t,size:r,asChild:o=false,...i},n)=>c.createElement(o?Slot:"button",{className:a("rds-button",pt({variant:t,size:r,className:e})),ref:n,...i}));oe.displayName="Button";var mt=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("rds-card rounded-xl border bg-card text-card-foreground shadow",e),...t}));mt.displayName="Card";var ut=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("flex flex-col space-y-1.5 p-6",e),...t}));ut.displayName="CardHeader";var ft=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("font-semibold leading-none tracking-tight",e),...t}));ft.displayName="CardTitle";var gt=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("text-sm text-muted-foreground",e),...t}));gt.displayName="CardDescription";var ht=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("p-6 pt-0",e),...t}));ht.displayName="CardContent";var yt=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("flex items-center p-6 pt-0",e),...t}));yt.displayName="CardFooter";var bt=c.forwardRef(({className:e,...t},r)=>c.createElement(ne.Root,{ref:r,className:a("rds-checkbox peer h-4 w-4 shrink-0 rounded-[3px] border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",e),...t},c.createElement(ne.Indicator,{className:a("flex items-center justify-center text-current")},c.createElement(Check,{className:"h-4 w-4"}))));bt.displayName=ne.Root.displayName;var Zr=w.Root,eo=w.Trigger,vt=w.Portal,to=w.Close,De=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Overlay,{ref:r,className:a("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));De.displayName=w.Overlay.displayName;var xt=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(vt,null,c.createElement(De,null),c.createElement(w.Content,{ref:o,className:a("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...r},t,c.createElement(w.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground"},c.createElement(X$1,{className:"h-4 w-4"}),c.createElement("span",{className:"sr-only"},"Close")))));xt.displayName=w.Content.displayName;var Rt=({className:e,...t})=>c.createElement("div",{className:a("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});Rt.displayName="DialogHeader";var Tt=({className:e,...t})=>c.createElement("div",{className:a("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Tt.displayName="DialogFooter";var St=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Title,{ref:r,className:a("text-lg font-semibold leading-none tracking-tight",e),...t}));St.displayName=w.Title.displayName;var wt=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Description,{ref:r,className:a("text-sm text-muted-foreground",e),...t}));wt.displayName=w.Description.displayName;var io=u.Root,no=u.Trigger,so=u.Group,lo=u.Portal,co=u.Sub,po=u.RadioGroup,Pt=c.forwardRef(({className:e,inset:t,children:r,...o},i)=>c.createElement(u.SubTrigger,{ref:i,className:a("flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...o},r,c.createElement(ChevronRight,{className:"ml-auto"})));Pt.displayName=u.SubTrigger.displayName;var Ct=c.forwardRef(({className:e,...t},r)=>c.createElement(u.SubContent,{ref:r,className:a("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=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 origin-[--radix-dropdown-menu-content-transform-origin]",e),...t}));Ct.displayName=u.SubContent.displayName;var Nt=c.forwardRef(({className:e,sideOffset:t=4,...r},o)=>c.createElement(u.Portal,null,c.createElement(u.Content,{ref:o,sideOffset:t,className:a("z-50 max-h-[var(--radix-dropdown-menu-content-available-height)] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=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 origin-[--radix-dropdown-menu-content-transform-origin]",e),...r})));Nt.displayName=u.Content.displayName;var kt=c.forwardRef(({className:e,inset:t,...r},o)=>c.createElement(u.Item,{ref:o,className:a("relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&>svg]:size-4 [&>svg]:shrink-0",t&&"pl-8",e),...r}));kt.displayName=u.Item.displayName;var Mt=c.forwardRef(({className:e,children:t,checked:r,...o},i)=>c.createElement(u.CheckboxItem,{ref:i,className:a("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:r,...o},c.createElement("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center"},c.createElement(u.ItemIndicator,null,c.createElement(Check,{className:"h-4 w-4"}))),t));Mt.displayName=u.CheckboxItem.displayName;var Lt=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(u.RadioItem,{ref:o,className:a("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...r},c.createElement("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center"},c.createElement(u.ItemIndicator,null,c.createElement(Circle,{className:"h-2 w-2 fill-current"}))),t));Lt.displayName=u.RadioItem.displayName;var Dt=c.forwardRef(({className:e,inset:t,...r},o)=>c.createElement(u.Label,{ref:o,className:a("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...r}));Dt.displayName=u.Label.displayName;var It=c.forwardRef(({className:e,...t},r)=>c.createElement(u.Separator,{ref:r,className:a("-mx-1 my-1 h-px bg-muted",e),...t}));It.displayName=u.Separator.displayName;var Ht=({className:e,...t})=>c.createElement("span",{className:a("ml-auto text-xs tracking-widest opacity-60",e),...t});Ht.displayName="DropdownMenuShortcut";var Et=c.forwardRef(({className:e,type:t,...r},o)=>c.createElement("input",{type:t,className:a("flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:o,...r}));Et.displayName="Input";var uo=cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),At=c.forwardRef(({className:e,...t},r)=>c.createElement(Ie.Root,{ref:r,className:a(uo(),e),...t}));At.displayName=Ie.Root.displayName;var Ft=c.forwardRef(({className:e,value:t,...r},o)=>c.createElement(de.Root,{ref:o,className:a("relative h-4 w-full overflow-hidden rounded-full bg-secondary",e),...r},c.createElement(de.Indicator,{className:"h-full w-full flex-1 bg-primary transition-all",style:{transform:`translateX(-${100-(t||0)}%)`}})));Ft.displayName=de.Root.displayName;var Ot=c.forwardRef(({className:e,...t},r)=>c.createElement(Y.Root,{className:a("grid gap-2",e),...t,ref:r}));Ot.displayName=Y.Root.displayName;var $t=c.forwardRef(({className:e,...t},r)=>c.createElement(Y.Item,{ref:r,className:a("aspect-square h-4 w-4 rounded-full border border-primary text-primary ring-offset-background focus:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),...t},c.createElement(Y.Indicator,{className:"flex items-center justify-center"},c.createElement(Circle,{className:"h-2.5 w-2.5 fill-current text-current"}))));$t.displayName=Y.Item.displayName;var Gt=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(A.Root,{ref:o,className:a("relative overflow-hidden",e),...r},c.createElement(A.Viewport,{className:"h-full w-full rounded-[inherit]"},t),c.createElement(He,null),c.createElement(A.Corner,null)));Gt.displayName=A.Root.displayName;var He=c.forwardRef(({className:e,orientation:t="vertical",...r},o)=>c.createElement(A.ScrollAreaScrollbar,{ref:o,orientation:t,className:a("flex touch-none select-none transition-colors",t==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-[1px]",t==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-[1px]",e),...r},c.createElement(A.ScrollAreaThumb,{className:"relative flex-1 rounded-full bg-border"})));He.displayName=A.ScrollAreaScrollbar.displayName;var yo=f.Root,bo=f.Group,vo=f.Value,Ut=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(f.Trigger,{ref:o,className:a("flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",e),...r},t,c.createElement(f.Icon,{asChild:true},c.createElement(ChevronDown,{className:"h-4 w-4 opacity-50"}))));Ut.displayName=f.Trigger.displayName;var Ee=c.forwardRef(({className:e,...t},r)=>c.createElement(f.ScrollUpButton,{ref:r,className:a("flex cursor-default items-center justify-center py-1",e),...t},c.createElement(ChevronUp,{className:"h-4 w-4"})));Ee.displayName=f.ScrollUpButton.displayName;var Ae=c.forwardRef(({className:e,...t},r)=>c.createElement(f.ScrollDownButton,{ref:r,className:a("flex cursor-default items-center justify-center py-1",e),...t},c.createElement(ChevronDown,{className:"h-4 w-4"})));Ae.displayName=f.ScrollDownButton.displayName;var Bt=c.forwardRef(({className:e,children:t,position:r="popper",...o},i)=>c.createElement(f.Portal,null,c.createElement(f.Content,{ref:i,className:a("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=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",r==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:r,...o},c.createElement(Ee,null),c.createElement(f.Viewport,{className:a("p-1",r==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]")},t),c.createElement(Ae,null))));Bt.displayName=f.Content.displayName;var Wt=c.forwardRef(({className:e,...t},r)=>c.createElement(f.Label,{ref:r,className:a("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...t}));Wt.displayName=f.Label.displayName;var _t=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(f.Item,{ref:o,className:a("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...r},c.createElement("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center"},c.createElement(f.ItemIndicator,null,c.createElement(Check,{className:"h-4 w-4"}))),c.createElement(f.ItemText,null,t)));_t.displayName=f.Item.displayName;var Vt=c.forwardRef(({className:e,...t},r)=>c.createElement(f.Separator,{ref:r,className:a("-mx-1 my-1 h-px bg-muted",e),...t}));Vt.displayName=f.Separator.displayName;var jt=c.forwardRef(({className:e,orientation:t="horizontal",decorative:r=true,...o},i)=>c.createElement(Fe.Root,{ref:i,decorative:r,orientation:t,className:a("shrink-0 bg-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...o}));jt.displayName=Fe.Root.displayName;var To=w.Root,So=w.Trigger,wo=w.Close,zt=w.Portal,Oe=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Overlay,{className:a("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:r}));Oe.displayName=w.Overlay.displayName;var Po=cva("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),Yt=c.forwardRef(({side:e="right",className:t,children:r,...o},i)=>c.createElement(zt,null,c.createElement(Oe,null),c.createElement(w.Content,{ref:i,className:a(Po({side:e}),t),...o},r,c.createElement(w.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary"},c.createElement(X$1,{className:"h-4 w-4"}),c.createElement("span",{className:"sr-only"},"Close")))));Yt.displayName=w.Content.displayName;var qt=({className:e,...t})=>c.createElement("div",{className:a("flex flex-col space-y-2 text-center sm:text-left",e),...t});qt.displayName="SheetHeader";var Jt=({className:e,...t})=>c.createElement("div",{className:a("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Jt.displayName="SheetFooter";var Xt=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Title,{ref:r,className:a("text-lg font-semibold text-foreground",e),...t}));Xt.displayName=w.Title.displayName;var Qt=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Description,{ref:r,className:a("text-sm text-muted-foreground",e),...t}));Qt.displayName=w.Description.displayName;function Co({className:e,...t}){return React.createElement("div",{className:a("animate-pulse rounded-md bg-muted",e),...t})}var Zt=c.forwardRef(({className:e,...t},r)=>c.createElement(_.Root,{ref:r,className:a("relative flex w-full touch-none select-none items-center",e),...t},c.createElement(_.Track,{className:"relative h-2 w-full grow overflow-hidden rounded-full bg-secondary"},c.createElement(_.Range,{className:"absolute h-full bg-primary"})),c.createElement(_.Thumb,{className:"block h-5 w-5 rounded-full border-2 border-primary bg-background ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50"})));Zt.displayName=_.Root.displayName;var er=c.forwardRef(({className:e,...t},r)=>c.createElement(ce.Root,{className:a("peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",e),...t,ref:r},c.createElement(ce.Thumb,{className:a("pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0")})));er.displayName=ce.Root.displayName;var tr=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{className:"relative w-full overflow-auto"},c.createElement("table",{ref:r,className:a("w-full caption-bottom text-sm",e),...t})));tr.displayName="Table";var rr=c.forwardRef(({className:e,...t},r)=>c.createElement("thead",{ref:r,className:a("[&_tr]:border-b",e),...t}));rr.displayName="TableHeader";var or=c.forwardRef(({className:e,...t},r)=>c.createElement("tbody",{ref:r,className:a("[&_tr:last-child]:border-0",e),...t}));or.displayName="TableBody";var ar=c.forwardRef(({className:e,...t},r)=>c.createElement("tfoot",{ref:r,className:a("border-t bg-muted/50 font-medium [&>tr]:last:border-b-0",e),...t}));ar.displayName="TableFooter";var ir=c.forwardRef(({className:e,...t},r)=>c.createElement("tr",{ref:r,className:a("border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted",e),...t}));ir.displayName="TableRow";var nr=c.forwardRef(({className:e,...t},r)=>c.createElement("th",{ref:r,className:a("h-10 px-2 text-left align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...t}));nr.displayName="TableHead";var sr=c.forwardRef(({className:e,...t},r)=>c.createElement("td",{ref:r,className:a("p-2 align-middle [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...t}));sr.displayName="TableCell";var dr=c.forwardRef(({className:e,...t},r)=>c.createElement("caption",{ref:r,className:a("mt-4 text-sm text-muted-foreground",e),...t}));dr.displayName="TableCaption";var No=G.Root,lr=c.forwardRef(({className:e,...t},r)=>c.createElement(G.List,{ref:r,className:a("inline-flex h-9 items-center justify-center rounded-lg bg-muted p-1 text-muted-foreground",e),...t}));lr.displayName=G.List.displayName;var cr=c.forwardRef(({className:e,...t},r)=>c.createElement(G.Trigger,{ref:r,className:a("inline-flex items-center justify-center whitespace-nowrap rounded-md px-3 py-1 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground",e),...t}));cr.displayName=G.Trigger.displayName;var pr=c.forwardRef(({className:e,...t},r)=>c.createElement(G.Content,{ref:r,className:a("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",e),...t}));pr.displayName=G.Content.displayName;var mr=c.forwardRef(({className:e,...t},r)=>c.createElement("textarea",{className:a("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:r,...t}));mr.displayName="Textarea";var $e=K.Provider,Ge=K.Root,Ke=K.Trigger,Se=c.forwardRef(({className:e,sideOffset:t=4,...r},o)=>c.createElement(K.Portal,null,c.createElement(K.Content,{ref:o,sideOffset:t,className:a("z-50 overflow-hidden rounded-md bg-primary px-3 py-1.5 text-xs text-primary-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-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 origin-[--radix-tooltip-content-transform-origin]",e),...r})));Se.displayName=K.Content.displayName;var fr=c.createContext(null);function gr(){let e=c.useContext(fr);if(!e)throw new Error("SideMenu components must be used within SideMenu");return e}var Lo=({href:e,className:t,children:r})=>c.createElement("a",{href:e,className:t},r),hr=c.forwardRef(({header:e,collapsedHeader:t,sections:r,items:o,footer:i,collapsed:n,onCollapsedChange:s,collapsible:g=true,defaultCollapsed:l=false,activeItem:x,className:S,linkComponent:k=Lo},R)=>{let[O,Z]=c.useState(l),d=n??O,C=()=>{let I=!d;Z(I),s?.(I);};return c.createElement($e,{delayDuration:0},c.createElement(fr.Provider,{value:{collapsed:d,activeItem:x,LinkComponent:k}},c.createElement("aside",{ref:R,className:a("flex h-full flex-col transition-[width] duration-300 ease-in-out","bg-white dark:bg-[#141414] border-r border-rds-gray-200 dark:border-[#1a1a1a]",d?"w-16":"w-64",S)},c.createElement("div",{className:a("flex items-center border-b border-rds-gray-200 dark:border-[#1a1a1a] flex-shrink-0 h-12",d?"justify-center px-2":"justify-between px-3")},d&&t||e,g&&c.createElement("button",{onClick:C,className:a("rounded-md h-5 w-5 flex items-center justify-center","text-rds-gray-400 dark:text-rds-gray-500","hover:text-rds-gray-600 dark:hover:text-rds-gray-300 transition-colors","bg-white dark:bg-[#141414] border border-rds-gray-200 dark:border-rds-gray-700 shadow-sm",d&&"absolute left-[calc(4rem-10px)] top-6 -translate-y-1/2 z-50"),"aria-label":d?"Expand sidebar":"Collapse sidebar"},d?c.createElement(ChevronRight,{className:"h-3 w-3"}):c.createElement(ChevronLeft,{className:"h-3 w-3"}))),c.createElement("nav",{className:"flex-1 py-2 overflow-y-auto overflow-x-hidden"},o&&o.length>0&&c.createElement("div",{className:"px-2 mb-1 space-y-0.5"},o.map(I=>c.createElement(Ue,{key:I.id,item:I}))),r?.map(I=>c.createElement(Do,{key:I.id,section:I}))),i&&c.createElement("div",{className:"flex-shrink-0 border-t border-rds-gray-200 dark:border-[#1a1a1a] p-2"},i))))});hr.displayName="SideMenu";function Do({section:e}){let{collapsed:t}=gr(),[r,o]=c.useState(e.defaultExpanded??true);return t?c.createElement("div",{className:"px-2 mb-1 space-y-0.5"},e.items.map(i=>c.createElement(Ue,{key:i.id,item:i}))):c.createElement("div",{className:"px-2 mb-1"},c.createElement("button",{onClick:()=>o(!r),className:a("flex w-full items-center gap-2.5 rounded-md px-2 py-1.5 text-sm font-medium","text-rds-gray-700 dark:text-rds-gray-300","hover:bg-rds-gray-50 dark:hover:bg-rds-gray-900","hover:text-rds-gray-900 dark:hover:text-white transition-colors")},e.icon&&c.createElement("span",{className:"h-3.5 w-3.5 flex-shrink-0"},e.icon),c.createElement("span",{className:"flex-1 text-left"},e.title),r?c.createElement(ChevronDown,{className:"h-3 w-3",strokeWidth:1.5}):c.createElement(ChevronRight,{className:"h-3 w-3",strokeWidth:1.5})),r&&c.createElement("div",{className:"mt-0.5 space-y-0.5 relative pl-5"},c.createElement("div",{className:"absolute left-[1.1rem] top-0 bottom-0 w-px bg-rds-gray-200 dark:bg-rds-gray-700"}),e.items.map(i=>c.createElement(Ue,{key:i.id,item:i,nested:true}))))}function Ue({item:e,nested:t=false}){let{collapsed:r,activeItem:o,LinkComponent:i}=gr(),n=o===e.id,s=a("flex items-center gap-2.5 rounded-md text-sm font-medium transition-colors",r?"justify-center px-2 py-2.5":"px-2 py-1.5",n?t?"bg-rds-gray-100 dark:bg-[#1a1a1a] text-rds-gray-900 dark:text-white":"bg-rds-green-50 dark:bg-rds-green-950 text-rds-green-700 dark:text-rds-green-400":"text-rds-gray-700 dark:text-rds-gray-300 hover:bg-rds-gray-50 dark:hover:bg-rds-gray-900 hover:text-rds-gray-900 dark:hover:text-white",e.disabled&&"opacity-50 pointer-events-none"),g=c.createElement(c.Fragment,null,e.icon&&c.createElement("span",{className:a("flex-shrink-0",r?"h-5 w-5":"h-3.5 w-3.5")},e.icon),!r&&c.createElement("span",null,e.label),!r&&e.badge&&c.createElement("span",{className:"ml-auto text-xs bg-rds-gray-100 dark:bg-rds-gray-800 px-1.5 py-0.5 rounded"},e.badge)),l=e.href?c.createElement(i,{href:e.href,className:s},g):c.createElement("button",{onClick:e.onClick,disabled:e.disabled,className:a(s,"w-full")},g);return r?c.createElement(Ge,null,c.createElement(Ke,{asChild:true},l),c.createElement(Se,{side:"right",sideOffset:8},e.label)):l}var Ho=({href:e,className:t,children:r})=>c.createElement("a",{href:e,className:t},r),yr=c.forwardRef(({breadcrumbs:e=[],showMobileMenu:t=false,onMobileMenuClick:r,leftContent:o,rightContent:i,className:n,linkComponent:s=Ho},g)=>c.createElement("header",{ref:g,className:a("sticky top-0 z-30 flex h-12 items-center gap-3","border-b border-rds-gray-200 dark:border-[#1a1a1a]","bg-white dark:bg-[#141414] px-4",n)},t&&c.createElement("button",{onClick:r,className:"lg:hidden rounded-md p-1.5 text-rds-gray-600 hover:bg-rds-gray-100 dark:text-rds-gray-400 dark:hover:bg-rds-gray-800","aria-label":"Toggle menu"},c.createElement(Menu,{className:"h-4 w-4"})),e.length>0&&c.createElement("nav",{className:"hidden md:flex items-center gap-1.5 text-sm","aria-label":"Breadcrumb"},e.map((l,x)=>c.createElement(c.Fragment,{key:x},x>0&&c.createElement("span",{className:"text-rds-gray-400 dark:text-rds-gray-500 text-xs"},"/"),l.href?c.createElement(s,{href:l.href,className:"text-rds-gray-600 dark:text-rds-gray-400 hover:text-rds-gray-900 dark:hover:text-white transition-colors text-sm"},l.label):c.createElement("span",{className:"text-rds-gray-900 dark:text-white font-medium text-sm"},l.label)))),o,c.createElement("div",{className:"flex-1"}),i&&c.createElement("div",{className:"flex items-center gap-1.5"},i)));yr.displayName="TopMenu";var br=c.forwardRef(({name:e,email:t,avatarUrl:r,avatarContent:o,avatarClassName:i,children:n,className:s},g)=>{let[l,x]=c.useState(false),S=c.useRef(null);return c.useEffect(()=>{let k=R=>{S.current&&!S.current.contains(R.target)&&x(false);};return l&&document.addEventListener("mousedown",k),()=>{document.removeEventListener("mousedown",k);}},[l]),c.createElement("div",{ref:g,className:a("relative",s)},c.createElement("div",{ref:S},c.createElement("button",{onClick:()=>x(!l),className:"flex items-center gap-1.5 rounded-full p-0.5 hover:ring-2 hover:ring-rds-green-500 hover:ring-offset-2 dark:hover:ring-offset-[#141414] transition-all","aria-label":"Account menu"},c.createElement("div",{className:a("h-8 w-8 rounded-full overflow-hidden flex items-center justify-center",i||"bg-gradient-to-br from-rds-yellow-400 to-rds-yellow-600")},r?c.createElement("img",{src:r,alt:e||"User",className:"h-full w-full object-cover"}):o)),l&&c.createElement("div",{className:"absolute right-0 mt-2 w-64 rounded-lg border border-rds-gray-200 dark:border-[#1a1a1a] bg-white dark:bg-[#141414] shadow-lg overflow-hidden z-50"},(e||t)&&c.createElement("div",{className:"px-4 py-3 border-b border-rds-gray-200 dark:border-[#1a1a1a]"},c.createElement("div",{className:"flex items-center gap-3"},c.createElement("div",{className:a("h-10 w-10 rounded-full overflow-hidden flex items-center justify-center",i||"bg-gradient-to-br from-rds-yellow-400 to-rds-yellow-600")},r?c.createElement("img",{src:r,alt:e||"User",className:"h-full w-full object-cover"}):o),c.createElement("div",{className:"flex-1 min-w-0"},e&&c.createElement("p",{className:"text-sm font-medium text-rds-gray-900 dark:text-white truncate"},e),t&&c.createElement("p",{className:"text-xs text-rds-gray-500 dark:text-rds-gray-400 truncate"},t)))),n)))});br.displayName="TopMenuUser";var vr=c.forwardRef(({icon:e,children:t,onClick:r,href:o,variant:i="default",className:n},s)=>c.createElement(o?"a":"button",{ref:s,onClick:r,href:o,className:a("w-full flex items-center gap-3 px-4 py-2 text-sm transition-colors",{default:"text-rds-gray-700 dark:text-rds-gray-300 hover:bg-rds-gray-50 dark:hover:bg-[#1a1a1a]",danger:"text-red-600 dark:text-red-400 hover:bg-red-50 dark:hover:bg-red-950/20",success:"text-rds-green-600 dark:text-rds-green-400 hover:bg-rds-green-50 dark:hover:bg-rds-green-950/20"}[i],n)},e&&c.createElement("span",{className:"h-4 w-4"},e),c.createElement("span",null,t)));vr.displayName="TopMenuUserItem";var xr=c.forwardRef(({children:e,className:t},r)=>c.createElement("div",{ref:r,className:a("py-1 border-t border-rds-gray-200 dark:border-[#1a1a1a] first:border-t-0",t)},e));xr.displayName="TopMenuUserSection";var Be=c.createContext(null);function We(){let e=c.useContext(Be);if(!e)throw new Error("SimpleTabsPanel must be used within SimpleTabs");return e}var Rr=c.forwardRef(({tabs:e,activeTab:t,defaultTab:r,onTabChange:o,children:i,className:n,tabsClassName:s},g)=>{let[l,x]=c.useState(r||e[0]?.id||""),S=t??l,k=R=>{x(R),o?.(R);};return c.createElement(Be.Provider,{value:{activeTab:S,setActiveTab:k}},c.createElement("div",{ref:g,className:a("space-y-6",n)},c.createElement("div",{className:"border-b border-rds-gray-200 dark:border-rds-gray-800"},c.createElement("nav",{className:a("-mb-px flex gap-1 overflow-x-auto scrollbar-hide",s),"aria-label":"Tabs"},e.map(R=>{let O=S===R.id;return c.createElement("button",{key:R.id,onClick:()=>!R.disabled&&k(R.id),disabled:R.disabled,className:a("relative flex items-center gap-2 px-4 py-3 text-sm font-medium transition-colors whitespace-nowrap",O?"text-primary":"text-muted-foreground hover:text-foreground",R.disabled&&"opacity-50 cursor-not-allowed")},R.icon&&c.createElement("span",{className:"h-4 w-4"},R.icon),R.label,O&&c.createElement("span",{className:"absolute bottom-0 left-0 right-0 h-0.5 bg-primary","aria-hidden":"true"}))}))),i&&c.createElement("div",null,i)))});Rr.displayName="SimpleTabs";var Tr=c.forwardRef(({id:e,children:t,className:r},o)=>{let{activeTab:i}=We();return i!==e?null:c.createElement("div",{ref:o,role:"tabpanel","aria-labelledby":`tab-${e}`,className:r},t)});Tr.displayName="SimpleTabsPanel";var Sr=c.forwardRef(({activeTab:e,defaultTab:t,onTabChange:r,children:o,className:i},n)=>{let[s,g]=c.useState(t||""),l=e??s,x=S=>{g(S),r?.(S);};return c.createElement(Be.Provider,{value:{activeTab:l,setActiveTab:x}},c.createElement("div",{ref:n,className:a("space-y-6",i)},o))});Sr.displayName="SimpleTabsRoot";var wr=c.forwardRef(({children:e,className:t},r)=>c.createElement("div",{ref:r,className:"border-b border-rds-gray-200 dark:border-rds-gray-800"},c.createElement("nav",{className:a("-mb-px flex gap-1 overflow-x-auto scrollbar-hide",t),role:"tablist","aria-label":"Tabs"},e)));wr.displayName="SimpleTabsList";var Pr=c.forwardRef(({value:e,children:t,icon:r,disabled:o,className:i},n)=>{let{activeTab:s,setActiveTab:g}=We(),l=s===e;return c.createElement("button",{ref:n,role:"tab",id:`tab-${e}`,"aria-selected":l,"aria-controls":`panel-${e}`,onClick:()=>!o&&g(e),disabled:o,className:a("relative flex items-center gap-2 px-4 py-3 text-sm font-medium transition-colors whitespace-nowrap",l?"text-primary":"text-muted-foreground hover:text-foreground",o&&"opacity-50 cursor-not-allowed",i)},r&&c.createElement("span",{className:"h-4 w-4"},r),t,l&&c.createElement("span",{className:"absolute bottom-0 left-0 right-0 h-0.5 bg-primary","aria-hidden":"true"}))});Pr.displayName="SimpleTabsTrigger";var Cr=c.forwardRef(({value:e,children:t,className:r},o)=>{let{activeTab:i}=We();return i!==e?null:c.createElement("div",{ref:o,role:"tabpanel",id:`panel-${e}`,"aria-labelledby":`tab-${e}`,className:r},t)});Cr.displayName="SimpleTabsContent";function Oo({children:e}){let t=useRef(null);return useEffect(()=>{let r=new Fo({duration:1.2,easing:i=>Math.min(1,1.001-Math.pow(2,-10*i)),orientation:"vertical",gestureOrientation:"vertical",smoothWheel:true});t.current=r;function o(i){r.raf(i),requestAnimationFrame(o);}return requestAnimationFrame(o),()=>{r.destroy(),t.current=null;}},[]),React.createElement(React.Fragment,null,e)}var J=[50,100,200,300,400,500,600,700,800,900,950],Nr=[.985,.955,.895,.82,.72,.61,.51,.415,.325,.245,.17],$o=[.015,.04,.075,.11,.14,.17,.17,.15,.12,.08,.04];function we({hue:e,chromaScale:t=1}){let r=(e%360+360)%360,o={};for(let i=0;i<J.length;i++){let n=Nr[i],s=$o[i]*t;o[J[i]]=`${n.toFixed(4)} ${s.toFixed(4)} ${r.toFixed(2)}`;}return o}function kr(){let e={};for(let t=0;t<J.length;t++){let r=Nr[t];e[J[t]]=`${r.toFixed(4)} 0 0`;}return e}var _e={light:{destructive:"0.560 0.220 27.0",destructiveFg:"0.990 0.005 27.0",success:"0.610 0.180 145.0",warning:"0.720 0.180 60.0",info:"0.580 0.200 240.0",highlight:"0.860 0.180 95.0"},dark:{destructive:"0.680 0.220 27.0",destructiveFg:"0.990 0.005 27.0",success:"0.720 0.180 145.0",warning:"0.800 0.180 60.0",info:"0.700 0.200 240.0",highlight:"0.880 0.180 95.0"}},me="1 0 0",Mr="0 0 0";var Pe={geist:"var(--font-geist), system-ui, sans-serif",inter:"var(--font-inter), system-ui, sans-serif",manrope:"var(--font-manrope), system-ui, sans-serif",figtree:"var(--font-figtree), system-ui, sans-serif",dmSans:"var(--font-dm-sans), system-ui, sans-serif",lexend:"var(--font-lexend), system-ui, sans-serif",outfit:"var(--font-outfit), system-ui, sans-serif",plusJakarta:"var(--font-plus-jakarta), system-ui, sans-serif",spaceGrotesk:"var(--font-space-grotesk), system-ui, sans-serif",fraunces:"var(--font-fraunces), Georgia, serif",instrumentSerif:"var(--font-instrument-serif), Georgia, serif",sourceSerif:"var(--font-source-serif), Georgia, serif",jetbrainsMono:"var(--font-jetbrains-mono), ui-monospace, monospace",geistMono:"var(--font-geist-mono), ui-monospace, monospace",ibmPlexMono:"var(--font-ibm-plex-mono), ui-monospace, monospace",system:"system-ui, -apple-system, sans-serif",serif:"Georgia, 'Times New Roman', serif",mono:"ui-monospace, Menlo, monospace"};var Go=["superLight","light","dark","superDark"],Ko={muted:.6,default:1,vibrant:1.3};function Uo(e,t,r){let o=t.primary*r,i=t.accent*r,n=(o+i)/2*.8,s=g=>(g%360+360)%360;return {1:`0.600 ${(.17*o).toFixed(4)} ${e.primary.toFixed(2)}`,2:`0.640 ${(.17*n).toFixed(4)} ${s(e.primary+140).toFixed(2)}`,3:`0.580 ${(.17*n).toFixed(4)} ${s(e.primary+220).toFixed(2)}`,4:`0.510 0.0250 ${e.neutral.toFixed(2)}`,5:`0.620 ${(.17*i).toFixed(4)} ${e.accent.toFixed(2)}`}}var p=e=>({source:"neutral",step:e}),F=e=>({source:"primary",step:e}),X=e=>({source:"accent",step:e}),ue=e=>({source:"pure",value:e}),Bo={superLight:{background:p(50),foreground:p(800),card:ue(me),cardForeground:p(800),popover:ue(me),popoverForeground:p(800),primary:F(600),primaryForeground:F(50),secondary:p(100),secondaryForeground:p(700),muted:p(100),mutedForeground:p(500),accent:X(600),accentForeground:X(50),border:p(200),input:p(200),ring:F(500)},light:{background:p(50),foreground:p(950),card:ue(me),cardForeground:p(950),popover:ue(me),popoverForeground:p(950),primary:F(500),primaryForeground:F(50),secondary:p(100),secondaryForeground:p(700),muted:p(100),mutedForeground:p(500),accent:X(500),accentForeground:X(50),border:p(200),input:p(200),ring:F(500)},dark:{background:p(950),foreground:p(50),card:p(900),cardForeground:p(50),popover:p(900),popoverForeground:p(50),primary:F(400),primaryForeground:F(950),secondary:p(800),secondaryForeground:p(200),muted:p(800),mutedForeground:p(400),accent:X(400),accentForeground:X(950),border:p(800),input:p(800),ring:F(400)},superDark:{background:ue(Mr),foreground:p(100),card:p(950),cardForeground:p(100),popover:p(950),popoverForeground:p(100),primary:F(300),primaryForeground:F(950),secondary:p(900),secondaryForeground:p(300),muted:p(900),mutedForeground:p(500),accent:X(300),accentForeground:X(950),border:p(900),input:p(900),ring:F(300)}};function D(e,t){return e.source==="pure"?e.value:t[e.source][e.step]}function Wo(e,t){let r=Bo[t],i=t==="superLight"||t==="light"?_e.light:_e.dark;return {background:D(r.background,e),foreground:D(r.foreground,e),card:D(r.card,e),cardForeground:D(r.cardForeground,e),popover:D(r.popover,e),popoverForeground:D(r.popoverForeground,e),primary:D(r.primary,e),primaryForeground:D(r.primaryForeground,e),secondary:D(r.secondary,e),secondaryForeground:D(r.secondaryForeground,e),muted:D(r.muted,e),mutedForeground:D(r.mutedForeground,e),accent:D(r.accent,e),accentForeground:D(r.accentForeground,e),border:D(r.border,e),input:D(r.input,e),ring:D(r.ring,e),destructive:i.destructive,destructiveForeground:i.destructiveFg,success:i.success,warning:i.warning,info:i.info,highlight:i.highlight}}var V={display:3.75,h1:2.5,h2:2,h3:1.5,h4:1.25,h5:1.125,h6:1,body:1,bodySm:.875},_o={compact:.85,default:1,spacious:1.18};function Vo(e){let t=_o[e.scale],r=o=>`${(o*t).toFixed(3)}rem`;return {fontSans:Pe[e.body],fontMono:Pe[e.mono],fontDisplay:Pe[e.display],headingWeight:e.headingWeight??600,bodyWeight:e.bodyWeight??400,headingTracking:e.headingTracking??"-0.01em",scale:{display:r(V.display),h1:r(V.h1),h2:r(V.h2),h3:r(V.h3),h4:r(V.h4),h5:r(V.h5),h6:r(V.h6),body:r(V.body),bodySm:r(V.bodySm)}}}var jo={sharp:0,subtle:.25,soft:.5,round:.875,pill:1.25};function zo(e){let t=jo[e.style],r=o=>`${o.toFixed(3)}rem`;return {base:r(t),sm:r(Math.max(0,t-.25)),md:r(t),lg:r(t+.25),xl:r(t+.5),"2xl":r(t+1),full:"9999px"}}var Yo={tight:.85,default:1,roomy:1.2};function qo(e){return {baseUnit:"1rem",densityFactor:Yo[e.density]}}var Jo={none:{sm:"none",md:"none",lg:"none",xl:"none","2xl":"none",inner:"none"},subtle:{sm:"0 1px 2px 0 rgb(0 0 0 / 0.03)",md:"0 2px 4px -1px rgb(0 0 0 / 0.04), 0 1px 2px -1px rgb(0 0 0 / 0.03)",lg:"0 6px 14px -2px rgb(0 0 0 / 0.05)",xl:"0 12px 24px -4px rgb(0 0 0 / 0.06)","2xl":"0 24px 48px -12px rgb(0 0 0 / 0.12)",inner:"inset 0 1px 2px 0 rgb(0 0 0 / 0.03)"},default:{sm:"0 1px 2px 0 rgb(0 0 0 / 0.05)",md:"0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)",lg:"0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1)",xl:"0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1)","2xl":"0 25px 50px -12px rgb(0 0 0 / 0.25)",inner:"inset 0 2px 4px 0 rgb(0 0 0 / 0.05)"},dramatic:{sm:"0 2px 4px 0 rgb(0 0 0 / 0.12)",md:"0 8px 16px -2px rgb(0 0 0 / 0.18), 0 4px 8px -4px rgb(0 0 0 / 0.12)",lg:"0 20px 32px -4px rgb(0 0 0 / 0.22), 0 8px 16px -8px rgb(0 0 0 / 0.18)",xl:"0 32px 48px -6px rgb(0 0 0 / 0.28), 0 12px 24px -10px rgb(0 0 0 / 0.22)","2xl":"0 48px 80px -16px rgb(0 0 0 / 0.45)",inner:"inset 0 4px 8px 0 rgb(0 0 0 / 0.1)"}};function Xo(e){let t=e?.shadows??"default",r=e?.motionIntensity??1,o=i=>`${Math.round(i*r)}ms`;return {shadows:Jo[t],motion:{fast:o(150),base:o(200),slow:o(300),slower:o(500)},borderWidth:e?.borderWidth??"1px"}}function te(e){let t=Ko[e.intensity??"default"],r=e.neutralPureGray??false,o=(e.chroma?.neutral??.08)*t,i=(e.chroma?.primary??1)*t,n=(e.chroma?.accent??1)*t,s=r?kr():we({hue:e.hues.neutral,chromaScale:o}),g=we({hue:e.hues.primary,chromaScale:i}),l=we({hue:e.hues.accent,chromaScale:n}),x={neutral:s,primary:g,accent:l},S=Uo(e.hues,{primary:i,accent:n},t),k=Object.fromEntries(Go.map(I=>[I,Wo(x,I)])),R=Vo(e.typography),O=zo(e.radius),Z=qo(e.spacing),d=Xo(e.effects),C={buttonShape:e.components?.buttonShape??"default",inputStyle:e.components?.inputStyle??"outlined",cardStyle:e.components?.cardStyle??"flat"};return {id:e.id,name:e.name,description:e.description,tagline:e.tagline,input:e,ramps:x,colors:k,chart:S,typography:R,radius:O,spacing:Z,effects:d,components:C}}var fe={id:"calm",name:"Calm",description:"Warm neutrals, terracotta primary, serif typography.",tagline:"Signature",hues:{neutral:40,primary:20,accent:40},chroma:{neutral:.15,primary:.75,accent:.8},intensity:"muted",typography:{display:"fraunces",body:"fraunces",mono:"jetbrainsMono",scale:"default",headingWeight:600,headingTracking:"-0.02em"},spacing:{density:"roomy"},radius:{style:"round"},effects:{shadows:"subtle",motionIntensity:1.25},components:{buttonShape:"pill",inputStyle:"outlined",cardStyle:"outlined"}},Ve={id:"energy",name:"Energy",description:"Teal + indigo \u2014 punchy, cool-tone, modern sans.",tagline:"Alternate",hues:{neutral:175,primary:175,accent:235},chroma:{neutral:.08,primary:1,accent:1},intensity:"vibrant",typography:{display:"geist",body:"geist",mono:"geistMono",scale:"default",headingWeight:600},spacing:{density:"default"},radius:{style:"soft"},effects:{shadows:"default",motionIntensity:1},components:{buttonShape:"default",inputStyle:"outlined",cardStyle:"flat"}},Ce=[fe,Ve];function Qo(e){return {"--background":e.background,"--foreground":e.foreground,"--card":e.card,"--card-foreground":e.cardForeground,"--popover":e.popover,"--popover-foreground":e.popoverForeground,"--primary":e.primary,"--primary-foreground":e.primaryForeground,"--secondary":e.secondary,"--secondary-foreground":e.secondaryForeground,"--muted":e.muted,"--muted-foreground":e.mutedForeground,"--accent":e.accent,"--accent-foreground":e.accentForeground,"--destructive":e.destructive,"--destructive-foreground":e.destructiveForeground,"--border":e.border,"--input":e.input,"--ring":e.ring,"--success":e.success,"--warning":e.warning,"--info":e.info,"--highlight":e.highlight}}function ze(e,t){let r=e.colors[t];return {...Qo(r),...je("neutral",e.ramps.neutral),...je("primary",e.ramps.primary),...je("accent",e.ramps.accent),"--chart-1":e.chart[1],"--chart-2":e.chart[2],"--chart-3":e.chart[3],"--chart-4":e.chart[4],"--chart-5":e.chart[5],"--font-sans":e.typography.fontSans,"--font-mono":e.typography.fontMono,"--font-display":e.typography.fontDisplay,"--font-heading-weight":String(e.typography.headingWeight),"--font-body-weight":String(e.typography.bodyWeight),"--font-heading-tracking":e.typography.headingTracking,"--text-display":e.typography.scale.display,"--text-h1":e.typography.scale.h1,"--text-h2":e.typography.scale.h2,"--text-h3":e.typography.scale.h3,"--text-h4":e.typography.scale.h4,"--text-h5":e.typography.scale.h5,"--text-h6":e.typography.scale.h6,"--text-body":e.typography.scale.body,"--text-body-sm":e.typography.scale.bodySm,"--radius":e.radius.base,"--rds-radius-sm":e.radius.sm,"--rds-radius-md":e.radius.md,"--rds-radius-lg":e.radius.lg,"--rds-radius-xl":e.radius.xl,"--rds-radius-2xl":e.radius["2xl"],"--rds-radius-full":e.radius.full,"--rds-density":String(e.spacing.densityFactor),"--rds-shadow-sm":e.effects.shadows.sm,"--rds-shadow-md":e.effects.shadows.md,"--rds-shadow-lg":e.effects.shadows.lg,"--rds-shadow-xl":e.effects.shadows.xl,"--rds-shadow-2xl":e.effects.shadows["2xl"],"--rds-shadow-inner":e.effects.shadows.inner,"--rds-transition-fast":e.effects.motion.fast,"--rds-transition-base":e.effects.motion.base,"--rds-transition-slow":e.effects.motion.slow,"--rds-transition-slower":e.effects.motion.slower,"--rds-border-width":e.effects.borderWidth}}function je(e,t){let r={};for(let o of J)r[`--ramp-${e}-${o}`]=t[o];return r}function Ne(e,t){if(typeof document>"u")return;let r=document.documentElement,o=ze(e,t);for(let[i,n]of Object.entries(o))r.style.setProperty(i,n);r.setAttribute("data-ramp-theme",e.id),r.setAttribute("data-mode",t),r.setAttribute("data-button-shape",e.components.buttonShape??"default"),r.setAttribute("data-input-style",e.components.inputStyle??"outlined"),r.setAttribute("data-card-style",e.components.cardStyle??"flat");}function ge(e){if(typeof document>"u")return "";let t=document.createElement("span");t.style.color=`oklch(${e})`,t.style.position="absolute",t.style.visibility="hidden",document.body.appendChild(t);let r=getComputedStyle(t).color;document.body.removeChild(t);let o=r.match(/\d+/g);if(!o||o.length<3)return "";let[i,n,s]=o.slice(0,3).map(Number);return "#"+[i,n,s].map(g=>Math.max(0,Math.min(255,g)).toString(16).padStart(2,"0")).join("").toUpperCase()}function Zo(e){let t=e.trim().split(/\s+/);if(t.length<3)return {oklch:e,hex:""};let[r,o,i]=t.map(Number),n=`${r.toFixed(3)} ${o.toFixed(3)} ${Math.round(i)}`,s=ge(e);return {oklch:n,hex:s}}function Ye(e,t,r){let o=[`### ${e} ramp (hue ${Math.round(r)}\xB0)`,"","| Step | OKLCH | Hex |","|------|-------|-----|"];for(let i of J){let{oklch:n,hex:s}=Zo(t[i]);o.push(`| ${i} | \`${n}\` | \`${s||"\u2014"}\` |`);}return o.join(`
|
|
2
|
-
`)}function
|
|
3
|
-
`)}function
|
|
1
|
+
import*as c from'react';import {useRef,useEffect}from'react';import*as A from'@radix-ui/react-accordion';import {ChevronDown,Check,X as X$1,ChevronRight,Circle,ChevronUp,ChevronLeft,Menu,Palette,Download,Trash2,SunDim,Sun,Moon,MoonStar}from'lucide-react';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {cva}from'class-variance-authority';import {Slot}from'@radix-ui/react-slot';import*as se from'@radix-ui/react-checkbox';import*as w from'@radix-ui/react-dialog';import*as f from'@radix-ui/react-dropdown-menu';import*as Ie from'@radix-ui/react-label';import*as le from'@radix-ui/react-progress';import*as Y from'@radix-ui/react-radio-group';import*as F from'@radix-ui/react-scroll-area';import*as g from'@radix-ui/react-select';import*as Oe from'@radix-ui/react-separator';import*as _ from'@radix-ui/react-slider';import*as pe from'@radix-ui/react-switch';import*as G from'@radix-ui/react-tabs';import*as K from'@radix-ui/react-tooltip';import Oo from'lenis';import*as W from'@radix-ui/react-popover';function a(...e){return twMerge(clsx(e))}var Vr=A.Root,at=c.forwardRef(({className:e,...t},r)=>c.createElement(A.Item,{ref:r,className:a("border-b",e),...t}));at.displayName="AccordionItem";var it=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(A.Header,{className:"flex"},c.createElement(A.Trigger,{ref:o,className:a("flex flex-1 items-center justify-between py-4 font-medium transition-all hover:underline [&[data-state=open]>svg]:rotate-180",e),...r},t,c.createElement(ChevronDown,{className:"h-4 w-4 shrink-0 transition-transform duration-200"}))));it.displayName=A.Trigger.displayName;var nt=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(A.Content,{ref:o,className:"overflow-hidden text-sm transition-all data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down",...r},c.createElement("div",{className:a("pb-4 pt-0",e)},t)));nt.displayName=A.Content.displayName;var zr=cva("relative w-full rounded-lg border p-4 [&>svg~*]:pl-7 [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4",{variants:{variant:{default:"bg-background text-foreground [&>svg]:text-foreground",destructive:"border-destructive/30 bg-destructive-soft text-destructive-deep [&>svg]:text-destructive-deep",success:"border-success/30 bg-success-soft text-success-deep [&>svg]:text-success-deep",warning:"border-warning/30 bg-warning-soft text-warning-deep [&>svg]:text-warning-deep",info:"border-info/30 bg-info-soft text-info-deep [&>svg]:text-info-deep",highlight:"border-highlight/30 bg-highlight-soft text-foreground [&>svg]:text-highlight-deep"}},defaultVariants:{variant:"default"}}),st=c.forwardRef(({className:e,variant:t,...r},o)=>c.createElement("div",{ref:o,role:"alert",className:a(zr({variant:t}),e),...r}));st.displayName="Alert";var dt=c.forwardRef(({className:e,...t},r)=>c.createElement("h5",{ref:r,className:a("mb-1 font-medium leading-none tracking-tight",e),...t}));dt.displayName="AlertTitle";var lt=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("text-sm [&_p]:leading-relaxed",e),...t}));lt.displayName="AlertDescription";var pt=cva("inline-flex items-center gap-1 border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 [&_svg]:size-3 [&_svg]:shrink-0",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground shadow hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground shadow hover:bg-destructive/80",outline:"text-foreground",highlight:"border-transparent bg-rds-yellow-400 text-rds-gray-900 shadow hover:bg-rds-yellow-500",success:"border-transparent bg-rds-green-500 text-rds-gray-900 shadow hover:bg-rds-green-600",warning:"border-transparent bg-orange-500 text-white shadow hover:bg-orange-600",info:"border-transparent bg-blue-500 text-white shadow hover:bg-blue-600","success-soft":"border-rds-green-500/20 bg-rds-green-500/10 text-rds-green-600 dark:text-rds-green-400","warning-soft":"border-orange-500/20 bg-orange-500/10 text-orange-600 dark:text-orange-400","destructive-soft":"border-destructive/20 bg-destructive/10 text-destructive dark:text-red-400","info-soft":"border-blue-500/20 bg-blue-500/10 text-blue-600 dark:text-blue-400","highlight-soft":"border-rds-yellow-500/20 bg-rds-yellow-400/10 text-rds-yellow-600 dark:text-rds-yellow-400","success-outline":"border-rds-green-500/50 bg-transparent text-rds-green-600 dark:text-rds-green-400","warning-outline":"border-orange-500/50 bg-transparent text-orange-600 dark:text-orange-400","destructive-outline":"border-destructive/50 bg-transparent text-destructive dark:text-red-400","info-outline":"border-blue-500/50 bg-transparent text-blue-600 dark:text-blue-400"},rounded:{default:"rounded-md",full:"rounded-full"}},defaultVariants:{variant:"default",rounded:"default"}});function qr({className:e,variant:t,rounded:r,...o}){return c.createElement("div",{className:a(pt({variant:t,rounded:r}),e),...o})}var mt=cva("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground shadow hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",outline:"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded-md px-3 text-xs",lg:"h-10 rounded-md px-8",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),oe=c.forwardRef(({className:e,variant:t,size:r,asChild:o=false,...i},n)=>c.createElement(o?Slot:"button",{className:a("rds-button",mt({variant:t,size:r,className:e})),ref:n,...i}));oe.displayName="Button";var ut=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("rds-card rounded-xl border bg-card text-card-foreground shadow",e),...t}));ut.displayName="Card";var ft=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("flex flex-col space-y-1.5 p-6",e),...t}));ft.displayName="CardHeader";var gt=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("font-semibold leading-none tracking-tight",e),...t}));gt.displayName="CardTitle";var ht=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("text-sm text-muted-foreground",e),...t}));ht.displayName="CardDescription";var yt=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("p-6 pt-0",e),...t}));yt.displayName="CardContent";var bt=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{ref:r,className:a("flex items-center p-6 pt-0",e),...t}));bt.displayName="CardFooter";var vt=c.forwardRef(({className:e,...t},r)=>c.createElement(se.Root,{ref:r,className:a("rds-checkbox peer h-4 w-4 shrink-0 rounded-[3px] border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",e),...t},c.createElement(se.Indicator,{className:a("flex items-center justify-center text-current")},c.createElement(Check,{className:"h-4 w-4"}))));vt.displayName=se.Root.displayName;var eo=w.Root,to=w.Trigger,xt=w.Portal,ro=w.Close,He=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Overlay,{ref:r,className:a("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));He.displayName=w.Overlay.displayName;var Tt=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(xt,null,c.createElement(He,null),c.createElement(w.Content,{ref:o,className:a("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...r},t,c.createElement(w.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground"},c.createElement(X$1,{className:"h-4 w-4"}),c.createElement("span",{className:"sr-only"},"Close")))));Tt.displayName=w.Content.displayName;var Rt=({className:e,...t})=>c.createElement("div",{className:a("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});Rt.displayName="DialogHeader";var St=({className:e,...t})=>c.createElement("div",{className:a("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});St.displayName="DialogFooter";var wt=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Title,{ref:r,className:a("text-lg font-semibold leading-none tracking-tight",e),...t}));wt.displayName=w.Title.displayName;var Pt=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Description,{ref:r,className:a("text-sm text-muted-foreground",e),...t}));Pt.displayName=w.Description.displayName;var no=f.Root,so=f.Trigger,lo=f.Group,co=f.Portal,po=f.Sub,mo=f.RadioGroup,Ct=c.forwardRef(({className:e,inset:t,children:r,...o},i)=>c.createElement(f.SubTrigger,{ref:i,className:a("flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...o},r,c.createElement(ChevronRight,{className:"ml-auto"})));Ct.displayName=f.SubTrigger.displayName;var Nt=c.forwardRef(({className:e,...t},r)=>c.createElement(f.SubContent,{ref:r,className:a("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=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 origin-[--radix-dropdown-menu-content-transform-origin]",e),...t}));Nt.displayName=f.SubContent.displayName;var kt=c.forwardRef(({className:e,sideOffset:t=4,...r},o)=>c.createElement(f.Portal,null,c.createElement(f.Content,{ref:o,sideOffset:t,className:a("z-50 max-h-[var(--radix-dropdown-menu-content-available-height)] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=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 origin-[--radix-dropdown-menu-content-transform-origin]",e),...r})));kt.displayName=f.Content.displayName;var Mt=c.forwardRef(({className:e,inset:t,...r},o)=>c.createElement(f.Item,{ref:o,className:a("relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&>svg]:size-4 [&>svg]:shrink-0",t&&"pl-8",e),...r}));Mt.displayName=f.Item.displayName;var Lt=c.forwardRef(({className:e,children:t,checked:r,...o},i)=>c.createElement(f.CheckboxItem,{ref:i,className:a("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:r,...o},c.createElement("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center"},c.createElement(f.ItemIndicator,null,c.createElement(Check,{className:"h-4 w-4"}))),t));Lt.displayName=f.CheckboxItem.displayName;var Dt=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(f.RadioItem,{ref:o,className:a("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...r},c.createElement("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center"},c.createElement(f.ItemIndicator,null,c.createElement(Circle,{className:"h-2 w-2 fill-current"}))),t));Dt.displayName=f.RadioItem.displayName;var Ht=c.forwardRef(({className:e,inset:t,...r},o)=>c.createElement(f.Label,{ref:o,className:a("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...r}));Ht.displayName=f.Label.displayName;var It=c.forwardRef(({className:e,...t},r)=>c.createElement(f.Separator,{ref:r,className:a("-mx-1 my-1 h-px bg-muted",e),...t}));It.displayName=f.Separator.displayName;var Et=({className:e,...t})=>c.createElement("span",{className:a("ml-auto text-xs tracking-widest opacity-60",e),...t});Et.displayName="DropdownMenuShortcut";var At=c.forwardRef(({className:e,type:t,...r},o)=>c.createElement("input",{type:t,className:a("flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:o,...r}));At.displayName="Input";var fo=cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),Ft=c.forwardRef(({className:e,...t},r)=>c.createElement(Ie.Root,{ref:r,className:a(fo(),e),...t}));Ft.displayName=Ie.Root.displayName;var Ot=c.forwardRef(({className:e,value:t,...r},o)=>c.createElement(le.Root,{ref:o,className:a("relative h-4 w-full overflow-hidden rounded-full bg-secondary",e),...r},c.createElement(le.Indicator,{className:"h-full w-full flex-1 bg-primary transition-all",style:{transform:`translateX(-${100-(t||0)}%)`}})));Ot.displayName=le.Root.displayName;var $t=c.forwardRef(({className:e,...t},r)=>c.createElement(Y.Root,{className:a("grid gap-2",e),...t,ref:r}));$t.displayName=Y.Root.displayName;var Gt=c.forwardRef(({className:e,...t},r)=>c.createElement(Y.Item,{ref:r,className:a("aspect-square h-4 w-4 rounded-full border border-primary text-primary ring-offset-background focus:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),...t},c.createElement(Y.Indicator,{className:"flex items-center justify-center"},c.createElement(Circle,{className:"h-2.5 w-2.5 fill-current text-current"}))));Gt.displayName=Y.Item.displayName;var Kt=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(F.Root,{ref:o,className:a("relative overflow-hidden",e),...r},c.createElement(F.Viewport,{className:"h-full w-full rounded-[inherit]"},t),c.createElement(Ee,null),c.createElement(F.Corner,null)));Kt.displayName=F.Root.displayName;var Ee=c.forwardRef(({className:e,orientation:t="vertical",...r},o)=>c.createElement(F.ScrollAreaScrollbar,{ref:o,orientation:t,className:a("flex touch-none select-none transition-colors",t==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-[1px]",t==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-[1px]",e),...r},c.createElement(F.ScrollAreaThumb,{className:"relative flex-1 rounded-full bg-border"})));Ee.displayName=F.ScrollAreaScrollbar.displayName;var bo=g.Root,vo=g.Group,xo=g.Value,Bt=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(g.Trigger,{ref:o,className:a("flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",e),...r},t,c.createElement(g.Icon,{asChild:true},c.createElement(ChevronDown,{className:"h-4 w-4 opacity-50"}))));Bt.displayName=g.Trigger.displayName;var Ae=c.forwardRef(({className:e,...t},r)=>c.createElement(g.ScrollUpButton,{ref:r,className:a("flex cursor-default items-center justify-center py-1",e),...t},c.createElement(ChevronUp,{className:"h-4 w-4"})));Ae.displayName=g.ScrollUpButton.displayName;var Fe=c.forwardRef(({className:e,...t},r)=>c.createElement(g.ScrollDownButton,{ref:r,className:a("flex cursor-default items-center justify-center py-1",e),...t},c.createElement(ChevronDown,{className:"h-4 w-4"})));Fe.displayName=g.ScrollDownButton.displayName;var Wt=c.forwardRef(({className:e,children:t,position:r="popper",...o},i)=>c.createElement(g.Portal,null,c.createElement(g.Content,{ref:i,className:a("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=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",r==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:r,...o},c.createElement(Ae,null),c.createElement(g.Viewport,{className:a("p-1",r==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]")},t),c.createElement(Fe,null))));Wt.displayName=g.Content.displayName;var _t=c.forwardRef(({className:e,...t},r)=>c.createElement(g.Label,{ref:r,className:a("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...t}));_t.displayName=g.Label.displayName;var Vt=c.forwardRef(({className:e,children:t,...r},o)=>c.createElement(g.Item,{ref:o,className:a("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...r},c.createElement("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center"},c.createElement(g.ItemIndicator,null,c.createElement(Check,{className:"h-4 w-4"}))),c.createElement(g.ItemText,null,t)));Vt.displayName=g.Item.displayName;var jt=c.forwardRef(({className:e,...t},r)=>c.createElement(g.Separator,{ref:r,className:a("-mx-1 my-1 h-px bg-muted",e),...t}));jt.displayName=g.Separator.displayName;var zt=c.forwardRef(({className:e,orientation:t="horizontal",decorative:r=true,...o},i)=>c.createElement(Oe.Root,{ref:i,decorative:r,orientation:t,className:a("shrink-0 bg-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...o}));zt.displayName=Oe.Root.displayName;var So=w.Root,wo=w.Trigger,Po=w.Close,Yt=w.Portal,$e=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Overlay,{className:a("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:r}));$e.displayName=w.Overlay.displayName;var Co=cva("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),qt=c.forwardRef(({side:e="right",className:t,children:r,...o},i)=>c.createElement(Yt,null,c.createElement($e,null),c.createElement(w.Content,{ref:i,className:a(Co({side:e}),t),...o},r,c.createElement(w.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary"},c.createElement(X$1,{className:"h-4 w-4"}),c.createElement("span",{className:"sr-only"},"Close")))));qt.displayName=w.Content.displayName;var Jt=({className:e,...t})=>c.createElement("div",{className:a("flex flex-col space-y-2 text-center sm:text-left",e),...t});Jt.displayName="SheetHeader";var Xt=({className:e,...t})=>c.createElement("div",{className:a("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Xt.displayName="SheetFooter";var Qt=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Title,{ref:r,className:a("text-lg font-semibold text-foreground",e),...t}));Qt.displayName=w.Title.displayName;var Zt=c.forwardRef(({className:e,...t},r)=>c.createElement(w.Description,{ref:r,className:a("text-sm text-muted-foreground",e),...t}));Zt.displayName=w.Description.displayName;function No({className:e,...t}){return React.createElement("div",{className:a("animate-pulse rounded-md bg-muted",e),...t})}var er=c.forwardRef(({className:e,...t},r)=>c.createElement(_.Root,{ref:r,className:a("relative flex w-full touch-none select-none items-center",e),...t},c.createElement(_.Track,{className:"relative h-2 w-full grow overflow-hidden rounded-full bg-secondary"},c.createElement(_.Range,{className:"absolute h-full bg-primary"})),c.createElement(_.Thumb,{className:"block h-5 w-5 rounded-full border-2 border-primary bg-background ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50"})));er.displayName=_.Root.displayName;var tr=c.forwardRef(({className:e,...t},r)=>c.createElement(pe.Root,{className:a("peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",e),...t,ref:r},c.createElement(pe.Thumb,{className:a("pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0")})));tr.displayName=pe.Root.displayName;var rr=c.forwardRef(({className:e,...t},r)=>c.createElement("div",{className:"relative w-full overflow-auto"},c.createElement("table",{ref:r,className:a("w-full caption-bottom text-sm",e),...t})));rr.displayName="Table";var or=c.forwardRef(({className:e,...t},r)=>c.createElement("thead",{ref:r,className:a("[&_tr]:border-b",e),...t}));or.displayName="TableHeader";var ar=c.forwardRef(({className:e,...t},r)=>c.createElement("tbody",{ref:r,className:a("[&_tr:last-child]:border-0",e),...t}));ar.displayName="TableBody";var ir=c.forwardRef(({className:e,...t},r)=>c.createElement("tfoot",{ref:r,className:a("border-t bg-muted/50 font-medium [&>tr]:last:border-b-0",e),...t}));ir.displayName="TableFooter";var nr=c.forwardRef(({className:e,...t},r)=>c.createElement("tr",{ref:r,className:a("border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted",e),...t}));nr.displayName="TableRow";var sr=c.forwardRef(({className:e,...t},r)=>c.createElement("th",{ref:r,className:a("h-10 px-2 text-left align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...t}));sr.displayName="TableHead";var dr=c.forwardRef(({className:e,...t},r)=>c.createElement("td",{ref:r,className:a("p-2 align-middle [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...t}));dr.displayName="TableCell";var lr=c.forwardRef(({className:e,...t},r)=>c.createElement("caption",{ref:r,className:a("mt-4 text-sm text-muted-foreground",e),...t}));lr.displayName="TableCaption";var ko=G.Root,cr=c.forwardRef(({className:e,...t},r)=>c.createElement(G.List,{ref:r,className:a("inline-flex h-9 items-center justify-center rounded-lg bg-muted p-1 text-muted-foreground",e),...t}));cr.displayName=G.List.displayName;var pr=c.forwardRef(({className:e,...t},r)=>c.createElement(G.Trigger,{ref:r,className:a("inline-flex items-center justify-center whitespace-nowrap rounded-md px-3 py-1 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground",e),...t}));pr.displayName=G.Trigger.displayName;var mr=c.forwardRef(({className:e,...t},r)=>c.createElement(G.Content,{ref:r,className:a("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",e),...t}));mr.displayName=G.Content.displayName;var ur=c.forwardRef(({className:e,...t},r)=>c.createElement("textarea",{className:a("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:r,...t}));ur.displayName="Textarea";var Ge=K.Provider,Ke=K.Root,Ue=K.Trigger,we=c.forwardRef(({className:e,sideOffset:t=4,...r},o)=>c.createElement(K.Portal,null,c.createElement(K.Content,{ref:o,sideOffset:t,className:a("z-50 overflow-hidden rounded-md bg-primary px-3 py-1.5 text-xs text-primary-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-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 origin-[--radix-tooltip-content-transform-origin]",e),...r})));we.displayName=K.Content.displayName;var gr=c.createContext(null);function hr(){let e=c.useContext(gr);if(!e)throw new Error("SideMenu components must be used within SideMenu");return e}var Do=({href:e,className:t,children:r})=>c.createElement("a",{href:e,className:t},r),yr=c.forwardRef(({header:e,collapsedHeader:t,sections:r,items:o,footer:i,collapsed:n,onCollapsedChange:s,collapsible:u=true,defaultCollapsed:d=false,activeItem:y,className:b,linkComponent:N=Do},T)=>{let[E,Z]=c.useState(d),l=n??E,C=()=>{let H=!l;Z(H),s?.(H);};return c.createElement(Ge,{delayDuration:0},c.createElement(gr.Provider,{value:{collapsed:l,activeItem:y,LinkComponent:N}},c.createElement("aside",{ref:T,className:a("flex h-full flex-col transition-[width] duration-300 ease-in-out","bg-white dark:bg-[#141414] border-r border-rds-gray-200 dark:border-[#1a1a1a]",l?"w-16":"w-64",b)},c.createElement("div",{className:a("flex items-center border-b border-rds-gray-200 dark:border-[#1a1a1a] flex-shrink-0 h-12",l?"justify-center px-2":"justify-between px-3")},l&&t||e,u&&c.createElement("button",{onClick:C,className:a("rounded-md h-5 w-5 flex items-center justify-center","text-rds-gray-400 dark:text-rds-gray-500","hover:text-rds-gray-600 dark:hover:text-rds-gray-300 transition-colors","bg-white dark:bg-[#141414] border border-rds-gray-200 dark:border-rds-gray-700 shadow-sm",l&&"absolute left-[calc(4rem-10px)] top-6 -translate-y-1/2 z-50"),"aria-label":l?"Expand sidebar":"Collapse sidebar"},l?c.createElement(ChevronRight,{className:"h-3 w-3"}):c.createElement(ChevronLeft,{className:"h-3 w-3"}))),c.createElement("nav",{className:"flex-1 py-2 overflow-y-auto overflow-x-hidden"},o&&o.length>0&&c.createElement("div",{className:"px-2 mb-1 space-y-0.5"},o.map(H=>c.createElement(Be,{key:H.id,item:H}))),r?.map(H=>c.createElement(Ho,{key:H.id,section:H}))),i&&c.createElement("div",{className:"flex-shrink-0 border-t border-rds-gray-200 dark:border-[#1a1a1a] p-2"},i))))});yr.displayName="SideMenu";function Ho({section:e}){let{collapsed:t}=hr(),[r,o]=c.useState(e.defaultExpanded??true);return t?c.createElement("div",{className:"px-2 mb-1 space-y-0.5"},e.items.map(i=>c.createElement(Be,{key:i.id,item:i}))):c.createElement("div",{className:"px-2 mb-1"},c.createElement("button",{onClick:()=>o(!r),className:a("flex w-full items-center gap-2.5 rounded-md px-2 py-1.5 text-sm font-medium","text-rds-gray-700 dark:text-rds-gray-300","hover:bg-rds-gray-50 dark:hover:bg-rds-gray-900","hover:text-rds-gray-900 dark:hover:text-white transition-colors")},e.icon&&c.createElement("span",{className:"h-3.5 w-3.5 flex-shrink-0"},e.icon),c.createElement("span",{className:"flex-1 text-left"},e.title),r?c.createElement(ChevronDown,{className:"h-3 w-3",strokeWidth:1.5}):c.createElement(ChevronRight,{className:"h-3 w-3",strokeWidth:1.5})),r&&c.createElement("div",{className:"mt-0.5 space-y-0.5 relative pl-5"},c.createElement("div",{className:"absolute left-[1.1rem] top-0 bottom-0 w-px bg-rds-gray-200 dark:bg-rds-gray-700"}),e.items.map(i=>c.createElement(Be,{key:i.id,item:i,nested:true}))))}function Be({item:e,nested:t=false}){let{collapsed:r,activeItem:o,LinkComponent:i}=hr(),n=o===e.id,s=a("flex items-center gap-2.5 rounded-md text-sm font-medium transition-colors",r?"justify-center px-2 py-2.5":"px-2 py-1.5",n?t?"bg-rds-gray-100 dark:bg-[#1a1a1a] text-rds-gray-900 dark:text-white":"bg-rds-green-50 dark:bg-rds-green-950 text-rds-green-700 dark:text-rds-green-400":"text-rds-gray-700 dark:text-rds-gray-300 hover:bg-rds-gray-50 dark:hover:bg-rds-gray-900 hover:text-rds-gray-900 dark:hover:text-white",e.disabled&&"opacity-50 pointer-events-none"),u=c.createElement(c.Fragment,null,e.icon&&c.createElement("span",{className:a("flex-shrink-0",r?"h-5 w-5":"h-3.5 w-3.5")},e.icon),!r&&c.createElement("span",null,e.label),!r&&e.badge&&c.createElement("span",{className:"ml-auto text-xs bg-rds-gray-100 dark:bg-rds-gray-800 px-1.5 py-0.5 rounded"},e.badge)),d=e.href?c.createElement(i,{href:e.href,className:s},u):c.createElement("button",{onClick:e.onClick,disabled:e.disabled,className:a(s,"w-full")},u);return r?c.createElement(Ke,null,c.createElement(Ue,{asChild:true},d),c.createElement(we,{side:"right",sideOffset:8},e.label)):d}var Eo=({href:e,className:t,children:r})=>c.createElement("a",{href:e,className:t},r),br=c.forwardRef(({breadcrumbs:e=[],showMobileMenu:t=false,onMobileMenuClick:r,leftContent:o,rightContent:i,className:n,linkComponent:s=Eo},u)=>c.createElement("header",{ref:u,className:a("sticky top-0 z-30 flex h-12 items-center gap-3","border-b border-rds-gray-200 dark:border-[#1a1a1a]","bg-white dark:bg-[#141414] px-4",n)},t&&c.createElement("button",{onClick:r,className:"lg:hidden rounded-md p-1.5 text-rds-gray-600 hover:bg-rds-gray-100 dark:text-rds-gray-400 dark:hover:bg-rds-gray-800","aria-label":"Toggle menu"},c.createElement(Menu,{className:"h-4 w-4"})),e.length>0&&c.createElement("nav",{className:"hidden md:flex items-center gap-1.5 text-sm","aria-label":"Breadcrumb"},e.map((d,y)=>c.createElement(c.Fragment,{key:y},y>0&&c.createElement("span",{className:"text-rds-gray-400 dark:text-rds-gray-500 text-xs"},"/"),d.href?c.createElement(s,{href:d.href,className:"text-rds-gray-600 dark:text-rds-gray-400 hover:text-rds-gray-900 dark:hover:text-white transition-colors text-sm"},d.label):c.createElement("span",{className:"text-rds-gray-900 dark:text-white font-medium text-sm"},d.label)))),o,c.createElement("div",{className:"flex-1"}),i&&c.createElement("div",{className:"flex items-center gap-1.5"},i)));br.displayName="TopMenu";var vr=c.forwardRef(({name:e,email:t,avatarUrl:r,avatarContent:o,avatarClassName:i,children:n,className:s},u)=>{let[d,y]=c.useState(false),b=c.useRef(null);return c.useEffect(()=>{let N=T=>{b.current&&!b.current.contains(T.target)&&y(false);};return d&&document.addEventListener("mousedown",N),()=>{document.removeEventListener("mousedown",N);}},[d]),c.createElement("div",{ref:u,className:a("relative",s)},c.createElement("div",{ref:b},c.createElement("button",{onClick:()=>y(!d),className:"flex items-center gap-1.5 rounded-full p-0.5 hover:ring-2 hover:ring-rds-green-500 hover:ring-offset-2 dark:hover:ring-offset-[#141414] transition-all","aria-label":"Account menu"},c.createElement("div",{className:a("h-8 w-8 rounded-full overflow-hidden flex items-center justify-center",i||"bg-gradient-to-br from-rds-yellow-400 to-rds-yellow-600")},r?c.createElement("img",{src:r,alt:e||"User",className:"h-full w-full object-cover"}):o)),d&&c.createElement("div",{className:"absolute right-0 mt-2 w-64 rounded-lg border border-rds-gray-200 dark:border-[#1a1a1a] bg-white dark:bg-[#141414] shadow-lg overflow-hidden z-50"},(e||t)&&c.createElement("div",{className:"px-4 py-3 border-b border-rds-gray-200 dark:border-[#1a1a1a]"},c.createElement("div",{className:"flex items-center gap-3"},c.createElement("div",{className:a("h-10 w-10 rounded-full overflow-hidden flex items-center justify-center",i||"bg-gradient-to-br from-rds-yellow-400 to-rds-yellow-600")},r?c.createElement("img",{src:r,alt:e||"User",className:"h-full w-full object-cover"}):o),c.createElement("div",{className:"flex-1 min-w-0"},e&&c.createElement("p",{className:"text-sm font-medium text-rds-gray-900 dark:text-white truncate"},e),t&&c.createElement("p",{className:"text-xs text-rds-gray-500 dark:text-rds-gray-400 truncate"},t)))),n)))});vr.displayName="TopMenuUser";var xr=c.forwardRef(({icon:e,children:t,onClick:r,href:o,variant:i="default",className:n},s)=>c.createElement(o?"a":"button",{ref:s,onClick:r,href:o,className:a("w-full flex items-center gap-3 px-4 py-2 text-sm transition-colors",{default:"text-rds-gray-700 dark:text-rds-gray-300 hover:bg-rds-gray-50 dark:hover:bg-[#1a1a1a]",danger:"text-red-600 dark:text-red-400 hover:bg-red-50 dark:hover:bg-red-950/20",success:"text-rds-green-600 dark:text-rds-green-400 hover:bg-rds-green-50 dark:hover:bg-rds-green-950/20"}[i],n)},e&&c.createElement("span",{className:"h-4 w-4"},e),c.createElement("span",null,t)));xr.displayName="TopMenuUserItem";var Tr=c.forwardRef(({children:e,className:t},r)=>c.createElement("div",{ref:r,className:a("py-1 border-t border-rds-gray-200 dark:border-[#1a1a1a] first:border-t-0",t)},e));Tr.displayName="TopMenuUserSection";var We=c.createContext(null);function _e(){let e=c.useContext(We);if(!e)throw new Error("SimpleTabsPanel must be used within SimpleTabs");return e}var Rr=c.forwardRef(({tabs:e,activeTab:t,defaultTab:r,onTabChange:o,children:i,className:n,tabsClassName:s},u)=>{let[d,y]=c.useState(r||e[0]?.id||""),b=t??d,N=T=>{y(T),o?.(T);};return c.createElement(We.Provider,{value:{activeTab:b,setActiveTab:N}},c.createElement("div",{ref:u,className:a("space-y-6",n)},c.createElement("div",{className:"border-b border-rds-gray-200 dark:border-rds-gray-800"},c.createElement("nav",{className:a("-mb-px flex gap-1 overflow-x-auto scrollbar-hide",s),"aria-label":"Tabs"},e.map(T=>{let E=b===T.id;return c.createElement("button",{key:T.id,onClick:()=>!T.disabled&&N(T.id),disabled:T.disabled,className:a("relative flex items-center gap-2 px-4 py-3 text-sm font-medium transition-colors whitespace-nowrap",E?"text-primary":"text-muted-foreground hover:text-foreground",T.disabled&&"opacity-50 cursor-not-allowed")},T.icon&&c.createElement("span",{className:"h-4 w-4"},T.icon),T.label,E&&c.createElement("span",{className:"absolute bottom-0 left-0 right-0 h-0.5 bg-primary","aria-hidden":"true"}))}))),i&&c.createElement("div",null,i)))});Rr.displayName="SimpleTabs";var Sr=c.forwardRef(({id:e,children:t,className:r},o)=>{let{activeTab:i}=_e();return i!==e?null:c.createElement("div",{ref:o,role:"tabpanel","aria-labelledby":`tab-${e}`,className:r},t)});Sr.displayName="SimpleTabsPanel";var wr=c.forwardRef(({activeTab:e,defaultTab:t,onTabChange:r,children:o,className:i},n)=>{let[s,u]=c.useState(t||""),d=e??s,y=b=>{u(b),r?.(b);};return c.createElement(We.Provider,{value:{activeTab:d,setActiveTab:y}},c.createElement("div",{ref:n,className:a("space-y-6",i)},o))});wr.displayName="SimpleTabsRoot";var Pr=c.forwardRef(({children:e,className:t},r)=>c.createElement("div",{ref:r,className:"border-b border-rds-gray-200 dark:border-rds-gray-800"},c.createElement("nav",{className:a("-mb-px flex gap-1 overflow-x-auto scrollbar-hide",t),role:"tablist","aria-label":"Tabs"},e)));Pr.displayName="SimpleTabsList";var Cr=c.forwardRef(({value:e,children:t,icon:r,disabled:o,className:i},n)=>{let{activeTab:s,setActiveTab:u}=_e(),d=s===e;return c.createElement("button",{ref:n,role:"tab",id:`tab-${e}`,"aria-selected":d,"aria-controls":`panel-${e}`,onClick:()=>!o&&u(e),disabled:o,className:a("relative flex items-center gap-2 px-4 py-3 text-sm font-medium transition-colors whitespace-nowrap",d?"text-primary":"text-muted-foreground hover:text-foreground",o&&"opacity-50 cursor-not-allowed",i)},r&&c.createElement("span",{className:"h-4 w-4"},r),t,d&&c.createElement("span",{className:"absolute bottom-0 left-0 right-0 h-0.5 bg-primary","aria-hidden":"true"}))});Cr.displayName="SimpleTabsTrigger";var Nr=c.forwardRef(({value:e,children:t,className:r},o)=>{let{activeTab:i}=_e();return i!==e?null:c.createElement("div",{ref:o,role:"tabpanel",id:`panel-${e}`,"aria-labelledby":`tab-${e}`,className:r},t)});Nr.displayName="SimpleTabsContent";function $o({children:e}){let t=useRef(null);return useEffect(()=>{let r=new Oo({duration:1.2,easing:i=>Math.min(1,1.001-Math.pow(2,-10*i)),orientation:"vertical",gestureOrientation:"vertical",smoothWheel:true});t.current=r;function o(i){r.raf(i),requestAnimationFrame(o);}return requestAnimationFrame(o),()=>{r.destroy(),t.current=null;}},[]),React.createElement(React.Fragment,null,e)}var J=[50,100,200,300,400,500,600,700,800,900,950],kr=[.985,.955,.895,.82,.72,.61,.51,.415,.325,.245,.17],Go=[.015,.04,.075,.11,.14,.17,.17,.15,.12,.08,.04];function Pe({hue:e,chromaScale:t=1}){let r=(e%360+360)%360,o={};for(let i=0;i<J.length;i++){let n=kr[i],s=Go[i]*t;o[J[i]]=`${n.toFixed(4)} ${s.toFixed(4)} ${r.toFixed(2)}`;}return o}function Mr(){let e={};for(let t=0;t<J.length;t++){let r=kr[t];e[J[t]]=`${r.toFixed(4)} 0 0`;}return e}var Ve={light:{destructive:"0.560 0.220 27.0",destructiveFg:"0.990 0.005 27.0",success:"0.610 0.180 145.0",warning:"0.720 0.180 60.0",info:"0.580 0.200 240.0",highlight:"0.860 0.180 95.0"},dark:{destructive:"0.680 0.220 27.0",destructiveFg:"0.990 0.005 27.0",success:"0.720 0.180 145.0",warning:"0.800 0.180 60.0",info:"0.700 0.200 240.0",highlight:"0.880 0.180 95.0"}},ue="1 0 0",Lr="0 0 0";function ie(e,t){let[,r,o]=e.split(/\s+/).map(b=>b.trim()),i=Number(r),n=o;if(t==="light"){let N=Math.min(i*.22,.045),T=.38,E=i;return {soft:`${.965.toFixed(3)} ${N.toFixed(3)} ${n}`,deep:`${T.toFixed(3)} ${E.toFixed(3)} ${n}`}}let s=.22,u=Math.min(i*.45,.075),d=.82,y=i*.9;return {soft:`${s.toFixed(3)} ${u.toFixed(3)} ${n}`,deep:`${d.toFixed(3)} ${y.toFixed(3)} ${n}`}}var Ce={geist:"var(--font-geist), system-ui, sans-serif",inter:"var(--font-inter), system-ui, sans-serif",manrope:"var(--font-manrope), system-ui, sans-serif",figtree:"var(--font-figtree), system-ui, sans-serif",dmSans:"var(--font-dm-sans), system-ui, sans-serif",lexend:"var(--font-lexend), system-ui, sans-serif",outfit:"var(--font-outfit), system-ui, sans-serif",plusJakarta:"var(--font-plus-jakarta), system-ui, sans-serif",spaceGrotesk:"var(--font-space-grotesk), system-ui, sans-serif",fraunces:"var(--font-fraunces), Georgia, serif",instrumentSerif:"var(--font-instrument-serif), Georgia, serif",sourceSerif:"var(--font-source-serif), Georgia, serif",jetbrainsMono:"var(--font-jetbrains-mono), ui-monospace, monospace",geistMono:"var(--font-geist-mono), ui-monospace, monospace",ibmPlexMono:"var(--font-ibm-plex-mono), ui-monospace, monospace",system:"system-ui, -apple-system, sans-serif",serif:"Georgia, 'Times New Roman', serif",mono:"ui-monospace, Menlo, monospace"};var Ko=["superLight","light","dark","superDark"],Uo={muted:.6,default:1,vibrant:1.3};function Bo(e,t,r){let o=t.primary*r,i=t.accent*r,n=(o+i)/2*.8,s=u=>(u%360+360)%360;return {1:`0.600 ${(.17*o).toFixed(4)} ${e.primary.toFixed(2)}`,2:`0.640 ${(.17*n).toFixed(4)} ${s(e.primary+140).toFixed(2)}`,3:`0.580 ${(.17*n).toFixed(4)} ${s(e.primary+220).toFixed(2)}`,4:`0.510 0.0250 ${e.neutral.toFixed(2)}`,5:`0.620 ${(.17*i).toFixed(4)} ${e.accent.toFixed(2)}`}}var p=e=>({source:"neutral",step:e}),O=e=>({source:"primary",step:e}),X=e=>({source:"accent",step:e}),fe=e=>({source:"pure",value:e}),Wo={superLight:{background:p(50),foreground:p(800),card:fe(ue),cardForeground:p(800),popover:fe(ue),popoverForeground:p(800),primary:O(600),primaryForeground:O(50),secondary:p(100),secondaryForeground:p(700),muted:p(100),mutedForeground:p(500),accent:X(600),accentForeground:X(50),border:p(200),input:p(200),ring:O(500)},light:{background:p(50),foreground:p(950),card:fe(ue),cardForeground:p(950),popover:fe(ue),popoverForeground:p(950),primary:O(500),primaryForeground:O(50),secondary:p(100),secondaryForeground:p(700),muted:p(100),mutedForeground:p(500),accent:X(500),accentForeground:X(50),border:p(200),input:p(200),ring:O(500)},dark:{background:p(950),foreground:p(50),card:p(900),cardForeground:p(50),popover:p(900),popoverForeground:p(50),primary:O(400),primaryForeground:O(950),secondary:p(800),secondaryForeground:p(200),muted:p(800),mutedForeground:p(400),accent:X(400),accentForeground:X(950),border:p(800),input:p(800),ring:O(400)},superDark:{background:fe(Lr),foreground:p(100),card:p(950),cardForeground:p(100),popover:p(950),popoverForeground:p(100),primary:O(300),primaryForeground:O(950),secondary:p(900),secondaryForeground:p(300),muted:p(900),mutedForeground:p(500),accent:X(300),accentForeground:X(950),border:p(900),input:p(900),ring:O(300)}};function D(e,t){return e.source==="pure"?e.value:t[e.source][e.step]}function _o(e,t){let r=Wo[t],o=t==="superLight"||t==="light",i=o?Ve.light:Ve.dark;return {background:D(r.background,e),foreground:D(r.foreground,e),card:D(r.card,e),cardForeground:D(r.cardForeground,e),popover:D(r.popover,e),popoverForeground:D(r.popoverForeground,e),primary:D(r.primary,e),primaryForeground:D(r.primaryForeground,e),secondary:D(r.secondary,e),secondaryForeground:D(r.secondaryForeground,e),muted:D(r.muted,e),mutedForeground:D(r.mutedForeground,e),accent:D(r.accent,e),accentForeground:D(r.accentForeground,e),border:D(r.border,e),input:D(r.input,e),ring:D(r.ring,e),destructive:i.destructive,destructiveForeground:i.destructiveFg,success:i.success,warning:i.warning,info:i.info,highlight:i.highlight,...(()=>{let n=o?"light":"dark",s=ie(i.destructive,n),u=ie(i.success,n),d=ie(i.warning,n),y=ie(i.info,n),b=ie(i.highlight,n);return {destructiveSoft:s.soft,destructiveDeep:s.deep,successSoft:u.soft,successDeep:u.deep,warningSoft:d.soft,warningDeep:d.deep,infoSoft:y.soft,infoDeep:y.deep,highlightSoft:b.soft,highlightDeep:b.deep}})()}}var V={display:3.75,h1:2.5,h2:2,h3:1.5,h4:1.25,h5:1.125,h6:1,body:1,bodySm:.875},Vo={compact:.85,default:1,spacious:1.18};function jo(e){let t=Vo[e.scale],r=o=>`${(o*t).toFixed(3)}rem`;return {fontSans:Ce[e.body],fontMono:Ce[e.mono],fontDisplay:Ce[e.display],headingWeight:e.headingWeight??600,bodyWeight:e.bodyWeight??400,headingTracking:e.headingTracking??"-0.01em",scale:{display:r(V.display),h1:r(V.h1),h2:r(V.h2),h3:r(V.h3),h4:r(V.h4),h5:r(V.h5),h6:r(V.h6),body:r(V.body),bodySm:r(V.bodySm)}}}var zo={sharp:0,subtle:.25,soft:.5,round:.875,pill:1.25};function Yo(e){let t=zo[e.style],r=o=>`${o.toFixed(3)}rem`;return {base:r(t),sm:r(Math.max(0,t-.25)),md:r(t),lg:r(t+.25),xl:r(t+.5),"2xl":r(t+1),full:"9999px"}}var qo={tight:.85,default:1,roomy:1.2};function Jo(e){return {baseUnit:"1rem",densityFactor:qo[e.density]}}var Xo={none:{sm:"none",md:"none",lg:"none",xl:"none","2xl":"none",inner:"none"},subtle:{sm:"0 1px 2px 0 rgb(0 0 0 / 0.03)",md:"0 2px 4px -1px rgb(0 0 0 / 0.04), 0 1px 2px -1px rgb(0 0 0 / 0.03)",lg:"0 6px 14px -2px rgb(0 0 0 / 0.05)",xl:"0 12px 24px -4px rgb(0 0 0 / 0.06)","2xl":"0 24px 48px -12px rgb(0 0 0 / 0.12)",inner:"inset 0 1px 2px 0 rgb(0 0 0 / 0.03)"},default:{sm:"0 1px 2px 0 rgb(0 0 0 / 0.05)",md:"0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)",lg:"0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1)",xl:"0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1)","2xl":"0 25px 50px -12px rgb(0 0 0 / 0.25)",inner:"inset 0 2px 4px 0 rgb(0 0 0 / 0.05)"},dramatic:{sm:"0 2px 4px 0 rgb(0 0 0 / 0.12)",md:"0 8px 16px -2px rgb(0 0 0 / 0.18), 0 4px 8px -4px rgb(0 0 0 / 0.12)",lg:"0 20px 32px -4px rgb(0 0 0 / 0.22), 0 8px 16px -8px rgb(0 0 0 / 0.18)",xl:"0 32px 48px -6px rgb(0 0 0 / 0.28), 0 12px 24px -10px rgb(0 0 0 / 0.22)","2xl":"0 48px 80px -16px rgb(0 0 0 / 0.45)",inner:"inset 0 4px 8px 0 rgb(0 0 0 / 0.1)"}};function Qo(e){let t=e?.shadows??"default",r=e?.motionIntensity??1,o=i=>`${Math.round(i*r)}ms`;return {shadows:Xo[t],motion:{fast:o(150),base:o(200),slow:o(300),slower:o(500)},borderWidth:e?.borderWidth??"1px"}}function te(e){let t=Uo[e.intensity??"default"],r=e.neutralPureGray??false,o=(e.chroma?.neutral??.08)*t,i=(e.chroma?.primary??1)*t,n=(e.chroma?.accent??1)*t,s=r?Mr():Pe({hue:e.hues.neutral,chromaScale:o}),u=Pe({hue:e.hues.primary,chromaScale:i}),d=Pe({hue:e.hues.accent,chromaScale:n}),y={neutral:s,primary:u,accent:d},b=Bo(e.hues,{primary:i,accent:n},t),N=Object.fromEntries(Ko.map(H=>[H,_o(y,H)])),T=jo(e.typography),E=Yo(e.radius),Z=Jo(e.spacing),l=Qo(e.effects),C={buttonShape:e.components?.buttonShape??"default",inputStyle:e.components?.inputStyle??"outlined",cardStyle:e.components?.cardStyle??"flat"};return {id:e.id,name:e.name,description:e.description,tagline:e.tagline,input:e,ramps:y,colors:N,chart:b,typography:T,radius:E,spacing:Z,effects:l,components:C}}var ge={id:"calm",name:"Calm",description:"Warm neutrals, terracotta primary, serif typography.",tagline:"Signature",hues:{neutral:40,primary:20,accent:40},chroma:{neutral:.15,primary:.75,accent:.8},intensity:"muted",typography:{display:"fraunces",body:"fraunces",mono:"jetbrainsMono",scale:"default",headingWeight:600,headingTracking:"-0.02em"},spacing:{density:"roomy"},radius:{style:"round"},effects:{shadows:"subtle",motionIntensity:1.25},components:{buttonShape:"pill",inputStyle:"outlined",cardStyle:"outlined"}},je={id:"energy",name:"Energy",description:"Teal + indigo \u2014 punchy, cool-tone, modern sans.",tagline:"Alternate",hues:{neutral:175,primary:175,accent:235},chroma:{neutral:.08,primary:1,accent:1},intensity:"vibrant",typography:{display:"geist",body:"geist",mono:"geistMono",scale:"default",headingWeight:600},spacing:{density:"default"},radius:{style:"soft"},effects:{shadows:"default",motionIntensity:1},components:{buttonShape:"default",inputStyle:"outlined",cardStyle:"flat"}},Ne=[ge,je];function Zo(e){return {"--background":e.background,"--foreground":e.foreground,"--card":e.card,"--card-foreground":e.cardForeground,"--popover":e.popover,"--popover-foreground":e.popoverForeground,"--primary":e.primary,"--primary-foreground":e.primaryForeground,"--secondary":e.secondary,"--secondary-foreground":e.secondaryForeground,"--muted":e.muted,"--muted-foreground":e.mutedForeground,"--accent":e.accent,"--accent-foreground":e.accentForeground,"--destructive":e.destructive,"--destructive-foreground":e.destructiveForeground,"--border":e.border,"--input":e.input,"--ring":e.ring,"--success":e.success,"--warning":e.warning,"--info":e.info,"--highlight":e.highlight,"--destructive-soft":e.destructiveSoft,"--destructive-deep":e.destructiveDeep,"--success-soft":e.successSoft,"--success-deep":e.successDeep,"--warning-soft":e.warningSoft,"--warning-deep":e.warningDeep,"--info-soft":e.infoSoft,"--info-deep":e.infoDeep,"--highlight-soft":e.highlightSoft,"--highlight-deep":e.highlightDeep}}function Ye(e,t){let r=e.colors[t];return {...Zo(r),...ze("neutral",e.ramps.neutral),...ze("primary",e.ramps.primary),...ze("accent",e.ramps.accent),"--chart-1":e.chart[1],"--chart-2":e.chart[2],"--chart-3":e.chart[3],"--chart-4":e.chart[4],"--chart-5":e.chart[5],"--font-sans":e.typography.fontSans,"--font-mono":e.typography.fontMono,"--font-display":e.typography.fontDisplay,"--font-heading-weight":String(e.typography.headingWeight),"--font-body-weight":String(e.typography.bodyWeight),"--font-heading-tracking":e.typography.headingTracking,"--text-display":e.typography.scale.display,"--text-h1":e.typography.scale.h1,"--text-h2":e.typography.scale.h2,"--text-h3":e.typography.scale.h3,"--text-h4":e.typography.scale.h4,"--text-h5":e.typography.scale.h5,"--text-h6":e.typography.scale.h6,"--text-body":e.typography.scale.body,"--text-body-sm":e.typography.scale.bodySm,"--radius":e.radius.base,"--rds-radius-sm":e.radius.sm,"--rds-radius-md":e.radius.md,"--rds-radius-lg":e.radius.lg,"--rds-radius-xl":e.radius.xl,"--rds-radius-2xl":e.radius["2xl"],"--rds-radius-full":e.radius.full,"--rds-density":String(e.spacing.densityFactor),"--rds-shadow-sm":e.effects.shadows.sm,"--rds-shadow-md":e.effects.shadows.md,"--rds-shadow-lg":e.effects.shadows.lg,"--rds-shadow-xl":e.effects.shadows.xl,"--rds-shadow-2xl":e.effects.shadows["2xl"],"--rds-shadow-inner":e.effects.shadows.inner,"--rds-transition-fast":e.effects.motion.fast,"--rds-transition-base":e.effects.motion.base,"--rds-transition-slow":e.effects.motion.slow,"--rds-transition-slower":e.effects.motion.slower,"--rds-border-width":e.effects.borderWidth}}function ze(e,t){let r={};for(let o of J)r[`--ramp-${e}-${o}`]=t[o];return r}function ke(e,t){if(typeof document>"u")return;let r=document.documentElement,o=Ye(e,t);for(let[i,n]of Object.entries(o))r.style.setProperty(i,n);r.setAttribute("data-ramp-theme",e.id),r.setAttribute("data-mode",t),r.setAttribute("data-button-shape",e.components.buttonShape??"default"),r.setAttribute("data-input-style",e.components.inputStyle??"outlined"),r.setAttribute("data-card-style",e.components.cardStyle??"flat");}function he(e){if(typeof document>"u")return "";let t=document.createElement("span");t.style.color=`oklch(${e})`,t.style.position="absolute",t.style.visibility="hidden",document.body.appendChild(t);let r=getComputedStyle(t).color;document.body.removeChild(t);let o=r.match(/\d+/g);if(!o||o.length<3)return "";let[i,n,s]=o.slice(0,3).map(Number);return "#"+[i,n,s].map(u=>Math.max(0,Math.min(255,u)).toString(16).padStart(2,"0")).join("").toUpperCase()}function ea(e){let t=e.trim().split(/\s+/);if(t.length<3)return {oklch:e,hex:""};let[r,o,i]=t.map(Number),n=`${r.toFixed(3)} ${o.toFixed(3)} ${Math.round(i)}`,s=he(e);return {oklch:n,hex:s}}function qe(e,t,r){let o=[`### ${e} ramp (hue ${Math.round(r)}\xB0)`,"","| Step | OKLCH | Hex |","|------|-------|-----|"];for(let i of J){let{oklch:n,hex:s}=ea(t[i]);o.push(`| ${i} | \`${n}\` | \`${s||"\u2014"}\` |`);}return o.join(`
|
|
2
|
+
`)}function Dr(e,t){let r=[`### ${e}`,"","| Token | Usage | Light (hex) | Dark (hex) |","|-------|-------|-------------|------------|"];for(let o of t){let i=he(o.light)||"\u2014",n=he(o.dark)||"\u2014";r.push(`| \`--${o.token}\` | ${o.usage} | \`${i}\` (\`${o.light}\`) | \`${n}\` (\`${o.dark}\`) |`);}return r.join(`
|
|
3
|
+
`)}function Hr(e){return JSON.stringify(e.input,null,2)}function Ir(e){let{input:t,ramps:r,colors:o,chart:i,typography:n,radius:s,spacing:u,effects:d,components:y}=e,b=t.intensity??"default",N=l=>({token:l,usage:ta[l]??"",light:o.light[l],dark:o.dark[l]}),T=["background","foreground","card","cardForeground","popover","popoverForeground","primary","primaryForeground","secondary","secondaryForeground","muted","mutedForeground","accent","accentForeground","border","input","ring"].map(N),E=["destructive","destructiveForeground","success","warning","info","highlight"].map(N),Z=[1,2,3,4,5].map(l=>{let C=i[l];return {slot:l,triplet:C,hex:he(C)||"\u2014"}});return `# ${e.name} \u2014 Grade Design System Theme
|
|
4
4
|
|
|
5
5
|
> **Portable theme spec.** Paste this entire file into a fresh LLM prompt along with your design brief. The model will have everything it needs to produce UI that matches this exact theme \u2014 colors, typography, spacing, shapes, and the "feel" we're after.
|
|
6
6
|
|
|
@@ -10,16 +10,16 @@ import*as c from'react';import {useRef,useEffect}from'react';import*as E from'@r
|
|
|
10
10
|
- **ID**: \`${t.id}\`
|
|
11
11
|
${t.description?`- **Description**: ${t.description}
|
|
12
12
|
`:""}- **Hues**: neutral \`${t.hues.neutral}\xB0\` \xB7 primary \`${t.hues.primary}\xB0\` \xB7 accent \`${t.hues.accent}\xB0\`
|
|
13
|
-
- **Intensity**: \`${
|
|
13
|
+
- **Intensity**: \`${b}\` ${b==="muted"?"(quieter chroma across the board)":b==="vibrant"?"(punchier chroma across the board)":"(balanced)"}
|
|
14
14
|
- **Typography**: ${t.typography.display} display \xB7 ${t.typography.body} body \xB7 ${t.typography.mono} mono \xB7 scale \`${t.typography.scale}\`
|
|
15
15
|
- **Spacing density**: \`${t.spacing.density}\`
|
|
16
16
|
- **Radius style**: \`${t.radius.style}\` (base \`${s.base}\`)
|
|
17
|
-
- **Button shape**: \`${
|
|
17
|
+
- **Button shape**: \`${y.buttonShape}\` \xB7 **Input style**: \`${y.inputStyle}\` \xB7 **Card style**: \`${y.cardStyle}\`
|
|
18
18
|
- **Shadow preset**: \`${t.effects?.shadows??"default"}\` \xB7 **Motion intensity**: \`${t.effects?.motionIntensity??1}\`
|
|
19
19
|
|
|
20
20
|
## How themes work
|
|
21
21
|
|
|
22
|
-
Every theme in
|
|
22
|
+
Every theme in Grade DS is produced by a pure function:
|
|
23
23
|
|
|
24
24
|
\`\`\`ts
|
|
25
25
|
generateTheme(input: ThemeInput) => GeneratedTheme
|
|
@@ -30,30 +30,30 @@ A \`ThemeInput\` is a small object (three hues plus a handful of presets). The g
|
|
|
30
30
|
## Full ThemeInput (round-trippable)
|
|
31
31
|
|
|
32
32
|
\`\`\`json
|
|
33
|
-
${
|
|
33
|
+
${Hr(e)}
|
|
34
34
|
\`\`\`
|
|
35
35
|
|
|
36
36
|
## Color ramps
|
|
37
37
|
|
|
38
38
|
Three 11-stop OKLCH ramps, generated from the input hues + chromas + global intensity. Every color elsewhere in the theme resolves back to one of these stops.
|
|
39
39
|
|
|
40
|
-
${
|
|
40
|
+
${qe("Neutral",r.neutral,t.hues.neutral)}
|
|
41
41
|
|
|
42
|
-
${
|
|
42
|
+
${qe("Primary",r.primary,t.hues.primary)}
|
|
43
43
|
|
|
44
|
-
${
|
|
44
|
+
${qe("Accent",r.accent,t.hues.accent)}
|
|
45
45
|
|
|
46
46
|
## Semantic tokens (hue-derived)
|
|
47
47
|
|
|
48
48
|
Purpose-based tokens drawn from the ramps. Two values per token \u2014 the generator produces them for all four brightness modes, but only light + dark are shown here for brevity.
|
|
49
49
|
|
|
50
|
-
${
|
|
50
|
+
${Dr("Core semantic tokens",T)}
|
|
51
51
|
|
|
52
52
|
## Fixed semantic tokens (not hue-derived)
|
|
53
53
|
|
|
54
54
|
Status colors stay consistent across themes so users always read green as success, red as destructive, etc. Accessibility wins over brand cohesion.
|
|
55
55
|
|
|
56
|
-
${
|
|
56
|
+
${Dr("Status colors",E)}
|
|
57
57
|
|
|
58
58
|
## Chart palette
|
|
59
59
|
|
|
@@ -61,7 +61,7 @@ ${Lr("Status colors",O)}
|
|
|
61
61
|
|
|
62
62
|
| Slot | OKLCH | Hex |
|
|
63
63
|
|------|-------|-----|
|
|
64
|
-
${Z.map(
|
|
64
|
+
${Z.map(l=>`| \`--chart-${l.slot}\` | \`${l.triplet}\` | \`${l.hex}\` |`).join(`
|
|
65
65
|
`)}
|
|
66
66
|
|
|
67
67
|
## Typography
|
|
@@ -103,17 +103,17 @@ ${Z.map(d=>`| \`--chart-${d.slot}\` | \`${d.triplet}\` | \`${d.hex}\` |`).join(`
|
|
|
103
103
|
|
|
104
104
|
### Spacing
|
|
105
105
|
|
|
106
|
-
- **Density factor**: \`${
|
|
107
|
-
- **Base unit**: \`${
|
|
106
|
+
- **Density factor**: \`${u.densityFactor}\` (applied as \`var(--rds-density)\` on components that opt in)
|
|
107
|
+
- **Base unit**: \`${u.baseUnit}\`
|
|
108
108
|
|
|
109
109
|
### Motion
|
|
110
110
|
|
|
111
111
|
| Var | Duration |
|
|
112
112
|
|-----|----------|
|
|
113
|
-
| \`--rds-transition-fast\` | \`${
|
|
114
|
-
| \`--rds-transition-base\` | \`${
|
|
115
|
-
| \`--rds-transition-slow\` | \`${
|
|
116
|
-
| \`--rds-transition-slower\` | \`${
|
|
113
|
+
| \`--rds-transition-fast\` | \`${d.motion.fast}\` |
|
|
114
|
+
| \`--rds-transition-base\` | \`${d.motion.base}\` |
|
|
115
|
+
| \`--rds-transition-slow\` | \`${d.motion.slow}\` |
|
|
116
|
+
| \`--rds-transition-slower\` | \`${d.motion.slower}\` |
|
|
117
117
|
|
|
118
118
|
### Shadows
|
|
119
119
|
|
|
@@ -121,10 +121,10 @@ All shadows are applied via Tailwind's \`shadow-*\` utilities mapped to these va
|
|
|
121
121
|
|
|
122
122
|
| Var | Value |
|
|
123
123
|
|-----|-------|
|
|
124
|
-
| \`--rds-shadow-sm\` | \`${
|
|
125
|
-
| \`--rds-shadow-md\` | \`${
|
|
126
|
-
| \`--rds-shadow-lg\` | \`${
|
|
127
|
-
| \`--rds-shadow-xl\` | \`${
|
|
124
|
+
| \`--rds-shadow-sm\` | \`${d.shadows.sm}\` |
|
|
125
|
+
| \`--rds-shadow-md\` | \`${d.shadows.md}\` |
|
|
126
|
+
| \`--rds-shadow-lg\` | \`${d.shadows.lg}\` |
|
|
127
|
+
| \`--rds-shadow-xl\` | \`${d.shadows.xl}\` |
|
|
128
128
|
|
|
129
129
|
## CSS variable conventions
|
|
130
130
|
|
|
@@ -182,7 +182,7 @@ Every component accepts a \`className\` for layout tweaks. Variants are passed v
|
|
|
182
182
|
|
|
183
183
|
When generating UI in the ${e.name} theme, match this character:
|
|
184
184
|
|
|
185
|
-
${
|
|
185
|
+
${ra(e)}
|
|
186
186
|
|
|
187
187
|
## Instructions for the generating LLM
|
|
188
188
|
|
|
@@ -201,7 +201,7 @@ To recreate this theme in code:
|
|
|
201
201
|
\`\`\`ts
|
|
202
202
|
import { generateTheme, applyThemeToRoot, type ThemeInput } from "@gradeui/ui";
|
|
203
203
|
|
|
204
|
-
const input: ThemeInput = ${
|
|
204
|
+
const input: ThemeInput = ${Hr(e).replace(/\n/g,`
|
|
205
205
|
`)};
|
|
206
206
|
|
|
207
207
|
const theme = generateTheme(input);
|
|
@@ -210,11 +210,11 @@ applyThemeToRoot(theme, "light"); // or "dark" / "superLight" / "superDark"
|
|
|
210
210
|
|
|
211
211
|
---
|
|
212
212
|
*Generated from Grade Design System v1 \xB7 ${new Date().toISOString()}*
|
|
213
|
-
`}var
|
|
214
|
-
`)}function
|
|
213
|
+
`}var ta={background:"Page / body background",foreground:"Primary text",card:"Elevated surface background",cardForeground:"Text on cards",popover:"Floating menu background",popoverForeground:"Text inside floating menus",primary:"Primary actions, links, default button",primaryForeground:"Text on primary-tinted fills",secondary:"Secondary surfaces + quiet buttons",secondaryForeground:"Text on secondary surfaces",muted:"Subtle surfaces (hover states, skeletons)",mutedForeground:"Secondary / less-important text",accent:"Highlights, hover accents",accentForeground:"Text on accent surfaces",border:"Default borders",input:"Form input borders",ring:"Focus ring color",destructive:"Destructive actions, errors",destructiveForeground:"Text on destructive surfaces",success:"Success states",warning:"Warning states",info:"Informational states",highlight:"Emphasis, new features, callouts"};function ra(e){let t=[],{input:r,components:o}=e;r.intensity==="muted"?t.push("- **Quiet and restrained.** Avoid heavy saturation, glowing effects, or loud contrast jumps. Let whitespace do the work."):r.intensity==="vibrant"?t.push("- **Loud and confident.** Primary color wants to lead. Use it on hero CTAs, key metrics, empty states. Don't be shy."):t.push("- **Balanced.** Neither shouty nor sleepy \u2014 a workhorse feel suited to product interfaces."),r.spacing.density==="roomy"?t.push("- **Generous spacing.** Stretch things out \u2014 reach for `gap-6`, `gap-8`, `p-6`, `p-8`. Airy is the vibe."):r.spacing.density==="tight"?t.push("- **Dense layouts.** Pack information in \u2014 `gap-2`, `gap-3`, `p-3`, `p-4`. Scan-friendly dashboard energy."):t.push("- **Standard density.** Use Tailwind's default spacing ladder."),r.radius.style==="pill"?t.push("- **Fully rounded.** Controls are pill-shaped. Use `rounded-full` on custom chips / pills too."):r.radius.style==="sharp"?t.push("- **Square corners.** Zero radius everywhere \u2014 very architectural. Do not add curves."):r.radius.style==="round"?t.push("- **Rounded and friendly.** Corner radius is noticeable (\u224814px base). Avoid sharp edges."):t.push("- **Standard rounded corners.**");let i=r.typography.display;return i==="fraunces"||i==="instrumentSerif"||i==="sourceSerif"?t.push("- **Editorial serif headings.** Treat headings like magazine titles \u2014 give them space and weight. Serifs reward larger sizes."):(i==="geist"||i==="inter")&&t.push("- **Modern technical sans.** Clean, functional, neutral. Good for product UIs."),o.cardStyle==="outlined"?t.push("- **Cards are outlined**, not shadowed. Rely on borders + spacing for hierarchy."):o.cardStyle==="elevated"?t.push("- **Cards have real elevation.** Use shadows to stack content visually."):o.cardStyle==="glass"&&t.push("- **Glass / frosted cards.** Use translucent surfaces over background imagery or gradients."),o.buttonShape==="pill"&&t.push("- **Buttons are pills** \u2014 don't override with square corners."),t.join(`
|
|
214
|
+
`)}function Je(e){if(typeof window>"u"||typeof document>"u")return;let t=Ir(e),r=new Blob([t],{type:"text/markdown;charset=utf-8"}),o=URL.createObjectURL(r),i=document.createElement("a");i.href=o,i.download=`ramp-theme-${e.input.id}.md`,document.body.appendChild(i),i.click(),document.body.removeChild(i),URL.revokeObjectURL(o);}var B=Object.fromEntries(Ne.map(e=>[e.id,te(e)])),ne=ge.id;function re(e){if(e in B)return B[e];let t=Qe(e);if(t)return te(t)}function Xe(){return [...Object.values(B),...Fr()]}var Er="ramp-user-themes";function Me(){if(typeof localStorage>"u")return {};try{let e=localStorage.getItem(Er);if(!e)return {};let t=JSON.parse(e);return t&&typeof t=="object"?t:{}}catch{return {}}}function Ar(e){if(!(typeof localStorage>"u"))try{localStorage.setItem(Er,JSON.stringify(e));}catch{}}function Fr(){return Object.values(Me()).map(te)}function Qe(e){return Me()[e]}function Le(e){let t=Me();return t[e.id]=e,Ar(t),te(e)}function Ze(e){if(e in B)return;let t=Me();delete t[e],Ar(t);}function oa(e,t,r){let o=B[e]?.input??Qe(e);if(!o)return;let i={...o,id:t,name:r};return Le(i),i}var et="ramp-theme",De="ramp-mode",$r=["superLight","light","dark","superDark"],Or=new Set(["dark","superDark"]),aa=`
|
|
215
215
|
(function() {
|
|
216
216
|
try {
|
|
217
|
-
var mode = localStorage.getItem('${
|
|
217
|
+
var mode = localStorage.getItem('${De}');
|
|
218
218
|
var valid = ['superLight','light','dark','superDark'];
|
|
219
219
|
if (!mode || valid.indexOf(mode) === -1) {
|
|
220
220
|
mode = window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light';
|
|
@@ -223,9 +223,9 @@ applyThemeToRoot(theme, "light"); // or "dark" / "superLight" / "superDark"
|
|
|
223
223
|
document.documentElement.classList.add('dark');
|
|
224
224
|
}
|
|
225
225
|
document.documentElement.setAttribute('data-mode', mode);
|
|
226
|
-
var themeId = localStorage.getItem('${
|
|
226
|
+
var themeId = localStorage.getItem('${et}');
|
|
227
227
|
if (themeId) document.documentElement.setAttribute('data-ramp-theme', themeId);
|
|
228
228
|
} catch(e) {}
|
|
229
229
|
})();
|
|
230
|
-
`,
|
|
230
|
+
`,tt=c.createContext(null);function ia({children:e,defaultTheme:t=ne,defaultMode:r="light"}){let[o,i]=c.useState(t),[n,s]=c.useState(r),[u,d]=c.useState(0);c.useEffect(()=>{try{let l=localStorage.getItem(et);l&&re(l)&&i(l);let C=localStorage.getItem(De);if(C&&$r.includes(C))s(C);else if(typeof window<"u"){let H=window.matchMedia("(prefers-color-scheme: dark)").matches;s(H?"dark":"light");}}catch{}},[]),c.useEffect(()=>{let l=re(o)??re(ne);l&&(ke(l,n),typeof document<"u"&&document.documentElement.classList.toggle("dark",Or.has(n)));},[o,n,u]),c.useEffect(()=>{if(typeof window>"u")return;let l=window.matchMedia("(prefers-color-scheme: dark)"),C=H=>{try{if(localStorage.getItem(De))return}catch{return}s(H.matches?"dark":"light");};return l.addEventListener("change",C),()=>l.removeEventListener("change",C)},[]);let y=c.useCallback(l=>{i(l);try{localStorage.setItem(et,l);}catch{}},[]),b=c.useCallback(l=>{s(l);try{localStorage.setItem(De,l);}catch{}},[]),N=c.useCallback(l=>{Le(l),d(C=>C+1),y(l.id);},[y]),T=c.useCallback(l=>{l in B||(Ze(l),d(C=>C+1),i(C=>C===l?ne:C));},[]),E=c.useCallback(()=>{d(l=>l+1);},[]),Z=c.useMemo(()=>{let l=re(o)??re(ne);return {theme:l,themeId:l.id,mode:n,isDark:Or.has(n),setThemeId:y,setMode:b,themes:Xe(),saveAndActivate:N,deleteTheme:T,refresh:E}},[o,n,u,y,b,N,T,E]);return c.createElement(tt.Provider,{value:Z},e)}function rt(){let e=c.useContext(tt);if(!e)throw new Error("useGradeTheme must be used inside <GradeThemeProvider>. Wrap your app (typically in app/layout.tsx).");return e}function ye(){return c.useContext(tt)}var Gr=W.Root,Kr=W.Trigger;var ot=c.forwardRef(({className:e,align:t="center",sideOffset:r=4,...o},i)=>c.createElement(W.Portal,null,c.createElement(W.Content,{ref:i,align:t,sideOffset:r,className:a("z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=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 origin-[--radix-popover-content-transform-origin]",e),...o})));ot.displayName=W.Content.displayName;function ca({className:e}){let t=ye();if(!t)return null;let{theme:r,themes:o,setThemeId:i,deleteTheme:n}=t;return c.createElement(Gr,null,c.createElement(Kr,{asChild:true},c.createElement(oe,{variant:"ghost",size:"sm",className:a("gap-2",e),"aria-label":"Switch theme"},c.createElement(Palette,{className:"h-4 w-4"}),c.createElement("span",{className:"hidden sm:inline"},r.name))),c.createElement(ot,{className:"w-80 p-2",align:"end"},c.createElement("div",{className:"flex items-start justify-between gap-2 px-2 py-1.5 mb-1"},c.createElement("div",null,c.createElement("div",{className:"text-xs font-medium text-muted-foreground"},"Theme"),c.createElement("div",{className:"text-xs text-muted-foreground/80"},"Switch the skin applied site-wide.")),c.createElement("button",{type:"button",onClick:()=>Je(r),className:"flex items-center gap-1 rounded-md border border-border px-2 py-1 text-[10px] font-medium text-muted-foreground hover:bg-muted hover:text-foreground transition-colors",title:"Download the active theme as a markdown spec \u2014 paste into a fresh LLM prompt"},c.createElement(Download,{className:"h-3 w-3"}),".md")),c.createElement("div",{className:"flex flex-col gap-0.5"},o.map(s=>{let u=s.id===r.id,d=s.id in B,y=s.ramps.primary[500],b=s.ramps.accent[500],N=s.ramps.neutral[500];return c.createElement("div",{key:s.id,className:a("group flex items-start gap-3 rounded-md px-2 py-2 text-left transition-colors","hover:bg-muted",u&&"bg-muted")},c.createElement("button",{type:"button",onClick:()=>i(s.id),className:"flex items-start gap-3 flex-1 min-w-0 text-left"},c.createElement("div",{className:"mt-0.5 flex shrink-0 overflow-hidden rounded-md border border-border"},c.createElement("div",{className:"h-5 w-2.5",style:{background:`oklch(${y})`},"aria-hidden":true}),c.createElement("div",{className:"h-5 w-2.5",style:{background:`oklch(${b})`},"aria-hidden":true}),c.createElement("div",{className:"h-5 w-2.5",style:{background:`oklch(${N})`},"aria-hidden":true})),c.createElement("div",{className:"min-w-0 flex-1"},c.createElement("div",{className:"flex items-center gap-2"},c.createElement("span",{className:"text-sm font-medium truncate text-foreground"},s.name),s.tagline&&c.createElement("span",{className:"text-[10px] uppercase tracking-wide text-muted-foreground shrink-0"},s.tagline)),s.description&&c.createElement("div",{className:"text-xs text-muted-foreground line-clamp-2"},s.description))),u&&c.createElement(Check,{className:"mt-2 h-4 w-4 shrink-0 text-primary"}),!d&&!u&&c.createElement("button",{type:"button",onClick:T=>{T.stopPropagation(),n(s.id);},className:"mt-1 opacity-0 group-hover:opacity-100 transition-opacity rounded p-1 hover:bg-destructive/10 hover:text-destructive","aria-label":`Delete theme ${s.name}`},c.createElement(Trash2,{className:"h-3.5 w-3.5"})))}))))}var Ur=[{mode:"superLight",label:"Super light",icon:SunDim,tooltip:"Super light \u2014 airy, low contrast"},{mode:"light",label:"Light",icon:Sun,tooltip:"Light"},{mode:"dark",label:"Dark",icon:Moon,tooltip:"Dark"},{mode:"superDark",label:"Super dark",icon:MoonStar,tooltip:"Super dark \u2014 OLED, high contrast"}];function ga({className:e,variant:t="icons"}){let r=ye();if(!r)return null;let{mode:o,setMode:i}=r;return t==="labeled"?c.createElement("div",{role:"radiogroup","aria-label":"Brightness mode",className:a("inline-flex flex-wrap gap-1 rounded-md border border-border bg-background p-1",e)},Ur.map(({mode:n,label:s,icon:u})=>{let d=o===n;return c.createElement("button",{key:n,type:"button",role:"radio","aria-checked":d,onClick:()=>i(n),className:a("flex items-center gap-2 rounded px-3 py-1.5 text-sm transition-colors",d?"bg-primary text-primary-foreground":"hover:bg-accent hover:text-accent-foreground")},c.createElement(u,{className:"h-4 w-4"}),c.createElement("span",null,s))})):c.createElement("div",{role:"radiogroup","aria-label":"Brightness mode",className:a("inline-flex items-center gap-0.5 rounded-md border border-border bg-background p-0.5",e)},Ur.map(({mode:n,icon:s,tooltip:u})=>{let d=o===n;return c.createElement("button",{key:n,type:"button",role:"radio","aria-checked":d,"aria-label":u,title:u,onClick:()=>i(n),className:a("flex h-7 w-7 items-center justify-center rounded transition-colors",d?"bg-primary text-primary-foreground":"text-muted-foreground hover:bg-accent hover:text-accent-foreground")},c.createElement(s,{className:"h-3.5 w-3.5"}))}))}function ba(){let{isDark:e,setMode:t}=rt();return React.createElement(oe,{variant:"ghost",size:"sm",onClick:()=>t(e?"light":"dark"),className:"gap-2","aria-label":e?"Switch to light mode":"Switch to dark mode"},e?React.createElement(React.Fragment,null,React.createElement(Sun,{className:"h-4 w-4"}),React.createElement("span",{className:"hidden sm:inline"},"Light")):React.createElement(React.Fragment,null,React.createElement(Moon,{className:"h-4 w-4"}),React.createElement("span",{className:"hidden sm:inline"},"Dark")))}export{$r as ALL_MODES,Vr as Accordion,nt as AccordionContent,at as AccordionItem,it as AccordionTrigger,st as Alert,lt as AlertDescription,dt as AlertTitle,Ne as BUILT_IN_INPUTS,qr as Badge,oe as Button,ut as Card,yt as CardContent,ht as CardDescription,bt as CardFooter,ft as CardHeader,gt as CardTitle,vt as Checkbox,eo as Dialog,ro as DialogClose,Tt as DialogContent,Pt as DialogDescription,St as DialogFooter,Rt as DialogHeader,He as DialogOverlay,xt as DialogPortal,wt as DialogTitle,to as DialogTrigger,no as DropdownMenu,Lt as DropdownMenuCheckboxItem,kt as DropdownMenuContent,lo as DropdownMenuGroup,Mt as DropdownMenuItem,Ht as DropdownMenuLabel,co as DropdownMenuPortal,mo as DropdownMenuRadioGroup,Dt as DropdownMenuRadioItem,It as DropdownMenuSeparator,Et as DropdownMenuShortcut,po as DropdownMenuSub,Nt as DropdownMenuSubContent,Ct as DropdownMenuSubTrigger,so as DropdownMenuTrigger,aa as GRADE_PRE_HYDRATION_SCRIPT,ga as GradeModeSwitcher,ia as GradeThemeProvider,ca as GradeThemeSwitcher,At as Input,Ft as Label,$o as LenisProvider,Ot as Progress,$t as RadioGroup,Gt as RadioGroupItem,Kt as ScrollArea,Ee as ScrollBar,bo as Select,Wt as SelectContent,vo as SelectGroup,Vt as SelectItem,_t as SelectLabel,Fe as SelectScrollDownButton,Ae as SelectScrollUpButton,jt as SelectSeparator,Bt as SelectTrigger,xo as SelectValue,zt as Separator,So as Sheet,Po as SheetClose,qt as SheetContent,Zt as SheetDescription,Xt as SheetFooter,Jt as SheetHeader,$e as SheetOverlay,Yt as SheetPortal,Qt as SheetTitle,wo as SheetTrigger,yr as SideMenu,Rr as SimpleTabs,Nr as SimpleTabsContent,Pr as SimpleTabsList,Sr as SimpleTabsPanel,wr as SimpleTabsRoot,Cr as SimpleTabsTrigger,No as Skeleton,er as Slider,tr as Switch,rr as Table,ar as TableBody,lr as TableCaption,dr as TableCell,ir as TableFooter,sr as TableHead,or as TableHeader,nr as TableRow,ko as Tabs,mr as TabsContent,cr as TabsList,pr as TabsTrigger,ur as Textarea,ba as ThemeToggle,Ke as Tooltip,we as TooltipContent,Ge as TooltipProvider,Ue as TooltipTrigger,br as TopMenu,vr as TopMenuUser,xr as TopMenuUserItem,Tr as TopMenuUserSection,ke as applyThemeToRoot,pt as badgeVariants,B as builtInThemes,mt as buttonVariants,ge as calmInput,a as cn,ne as defaultThemeId,Ze as deleteUserTheme,oa as duplicateTheme,je as energyInput,te as generateTheme,re as getTheme,Xe as listThemes,Fr as listUserThemes,Qe as loadUserThemeInput,Le as saveUserTheme,Ye as themeToCSSVars,rt as useGradeTheme,ye as useMaybeGradeTheme};//# sourceMappingURL=index.mjs.map
|
|
231
231
|
//# sourceMappingURL=index.mjs.map
|