@codefast/ui 0.1.53 → 0.1.55

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.
@@ -0,0 +1,2 @@
1
+ import{a as o}from"./chunk-VPYH6JWS.js";import*as e from"@radix-ui/react-tabs";import{forwardRef as n}from"react";import{jsx as r}from"react/jsx-runtime";var l=e.Root,a=n(({className:t,...i},s)=>r(e.List,{ref:s,className:o("bg-muted text-muted-foreground inline-flex h-10 items-center justify-center gap-1 rounded-md p-1",t),...i}));a.displayName=e.List.displayName;var p=n(({className:t,...i},s)=>r(e.Trigger,{ref:s,className:o("inline-flex items-center justify-center whitespace-nowrap rounded-md px-3 py-1.5 text-sm font-medium outline-transparent transition-all","data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm","focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2","disabled:pointer-events-none disabled:opacity-50",t),...i}));p.displayName=e.Trigger.displayName;var m=n(({className:t,...i},s)=>r(e.Content,{ref:s,className:o("mt-2 rounded-md","focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",t),...i}));m.displayName=e.Content.displayName;export{l as a,a as b,p as c,m as d};
2
+ //# sourceMappingURL=chunk-5J3MQRCG.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/components/tabs.tsx"],"names":["TabsPrimitive","forwardRef","jsx","Tabs","TabsList","className","props","forwardedRef","cn","TabsTrigger","TabsContent"],"mappings":"wCAAA,UAAYA,MAAmB,uBAC/B,OAA2D,cAAAC,MAAkB,QAmB3E,cAAAC,MAAA,oBAVF,IAAMC,EAAqB,OASrBC,EAAWH,EAA2C,CAAC,CAAE,UAAAI,EAAW,GAAGC,CAAM,EAAGC,IACpFL,EAAe,OAAd,CACC,IAAKK,EACL,UAAWC,EACT,mGACAH,CACF,EACC,GAAGC,EACN,CACD,EAEDF,EAAS,YAA4B,OAAK,YAS1C,IAAMK,EAAcR,EAAiD,CAAC,CAAE,UAAAI,EAAW,GAAGC,CAAM,EAAGC,IAC7FL,EAAe,UAAd,CACC,IAAKK,EACL,UAAWC,EACT,uIACA,sGACA,sGACA,mDACAH,CACF,EACC,GAAGC,EACN,CACD,EAEDG,EAAY,YAA4B,UAAQ,YAShD,IAAMC,EAAcT,EAAiD,CAAC,CAAE,UAAAI,EAAW,GAAGC,CAAM,EAAGC,IAC7FL,EAAe,UAAd,CACC,IAAKK,EACL,UAAWC,EACT,kBACA,sGACAH,CACF,EACC,GAAGC,EACN,CACD,EAEDI,EAAY,YAA4B,UAAQ","sourcesContent":["import * as TabsPrimitive from '@radix-ui/react-tabs';\nimport { type ComponentPropsWithoutRef, type ComponentRef, forwardRef } from 'react';\n\nimport { cn } from '@/lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: Tabs\n * -------------------------------------------------------------------------- */\n\ntype TabsProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Root>;\nconst Tabs = TabsPrimitive.Root;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsList\n * -------------------------------------------------------------------------- */\n\ntype TabsListElement = ComponentRef<typeof TabsPrimitive.List>;\ntype TabsListProps = ComponentPropsWithoutRef<typeof TabsPrimitive.List>;\n\nconst TabsList = forwardRef<TabsListElement, TabsListProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.List\n ref={forwardedRef}\n className={cn(\n 'bg-muted text-muted-foreground inline-flex h-10 items-center justify-center gap-1 rounded-md p-1',\n className,\n )}\n {...props}\n />\n));\n\nTabsList.displayName = TabsPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsTrigger\n * -------------------------------------------------------------------------- */\n\ntype TabsTriggerElement = ComponentRef<typeof TabsPrimitive.Trigger>;\ntype TabsTriggerProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger>;\n\nconst TabsTrigger = forwardRef<TabsTriggerElement, TabsTriggerProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.Trigger\n ref={forwardedRef}\n className={cn(\n 'inline-flex items-center justify-center whitespace-nowrap rounded px-3 py-1.5 text-sm font-medium outline-transparent transition-all',\n 'data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm',\n 'focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2',\n 'disabled:pointer-events-none disabled:opacity-50',\n className,\n )}\n {...props}\n />\n));\n\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsContent\n * -------------------------------------------------------------------------- */\n\ntype TabsContentElement = ComponentRef<typeof TabsPrimitive.Content>;\ntype TabsContentProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Content>;\n\nconst TabsContent = forwardRef<TabsContentElement, TabsContentProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.Content\n ref={forwardedRef}\n className={cn(\n 'mt-2 rounded-md',\n 'focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2',\n className,\n )}\n {...props}\n />\n));\n\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Tabs,\n TabsContent,\n TabsList,\n TabsTrigger,\n type TabsContentProps,\n type TabsListProps,\n type TabsProps,\n type TabsTriggerProps,\n};\n"]}
1
+ {"version":3,"sources":["../src/components/tabs.tsx"],"names":["TabsPrimitive","forwardRef","jsx","Tabs","TabsList","className","props","forwardedRef","cn","TabsTrigger","TabsContent"],"mappings":"wCAAA,UAAYA,MAAmB,uBAC/B,OAA2D,cAAAC,MAAkB,QAmB3E,cAAAC,MAAA,oBAVF,IAAMC,EAAqB,OASrBC,EAAWH,EAA2C,CAAC,CAAE,UAAAI,EAAW,GAAGC,CAAM,EAAGC,IACpFL,EAAe,OAAd,CACC,IAAKK,EACL,UAAWC,EACT,mGACAH,CACF,EACC,GAAGC,EACN,CACD,EAEDF,EAAS,YAA4B,OAAK,YAS1C,IAAMK,EAAcR,EAAiD,CAAC,CAAE,UAAAI,EAAW,GAAGC,CAAM,EAAGC,IAC7FL,EAAe,UAAd,CACC,IAAKK,EACL,UAAWC,EACT,0IACA,sGACA,sGACA,mDACAH,CACF,EACC,GAAGC,EACN,CACD,EAEDG,EAAY,YAA4B,UAAQ,YAShD,IAAMC,EAAcT,EAAiD,CAAC,CAAE,UAAAI,EAAW,GAAGC,CAAM,EAAGC,IAC7FL,EAAe,UAAd,CACC,IAAKK,EACL,UAAWC,EACT,kBACA,sGACAH,CACF,EACC,GAAGC,EACN,CACD,EAEDI,EAAY,YAA4B,UAAQ","sourcesContent":["import * as TabsPrimitive from '@radix-ui/react-tabs';\nimport { type ComponentPropsWithoutRef, type ComponentRef, forwardRef } from 'react';\n\nimport { cn } from '@/lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: Tabs\n * -------------------------------------------------------------------------- */\n\ntype TabsProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Root>;\nconst Tabs = TabsPrimitive.Root;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsList\n * -------------------------------------------------------------------------- */\n\ntype TabsListElement = ComponentRef<typeof TabsPrimitive.List>;\ntype TabsListProps = ComponentPropsWithoutRef<typeof TabsPrimitive.List>;\n\nconst TabsList = forwardRef<TabsListElement, TabsListProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.List\n ref={forwardedRef}\n className={cn(\n 'bg-muted text-muted-foreground inline-flex h-10 items-center justify-center gap-1 rounded-md p-1',\n className,\n )}\n {...props}\n />\n));\n\nTabsList.displayName = TabsPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsTrigger\n * -------------------------------------------------------------------------- */\n\ntype TabsTriggerElement = ComponentRef<typeof TabsPrimitive.Trigger>;\ntype TabsTriggerProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger>;\n\nconst TabsTrigger = forwardRef<TabsTriggerElement, TabsTriggerProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.Trigger\n ref={forwardedRef}\n className={cn(\n 'inline-flex items-center justify-center whitespace-nowrap rounded-md px-3 py-1.5 text-sm font-medium outline-transparent transition-all',\n 'data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm',\n 'focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2',\n 'disabled:pointer-events-none disabled:opacity-50',\n className,\n )}\n {...props}\n />\n));\n\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsContent\n * -------------------------------------------------------------------------- */\n\ntype TabsContentElement = ComponentRef<typeof TabsPrimitive.Content>;\ntype TabsContentProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Content>;\n\nconst TabsContent = forwardRef<TabsContentElement, TabsContentProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.Content\n ref={forwardedRef}\n className={cn(\n 'mt-2 rounded-md',\n 'focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2',\n className,\n )}\n {...props}\n />\n));\n\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Tabs,\n TabsContent,\n TabsList,\n TabsTrigger,\n type TabsContentProps,\n type TabsListProps,\n type TabsProps,\n type TabsTriggerProps,\n};\n"]}
@@ -0,0 +1,4 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }"use client";var _chunkDD6AVCRHcjs = require('./chunk-DD6AVCRH.cjs');var _react = require('react');var _recharts = require('recharts'); var g = _interopRequireWildcard(_recharts);var _jsxruntime = require('react/jsx-runtime');var N={light:"",dark:".dark"},_=_react.createContext.call(void 0, null);function w(){let e=_react.useContext.call(void 0, _);if(!e)throw new Error("useChart must be used within a <ChartContainer />");return e}var K=_react.forwardRef.call(void 0, ({children:e,className:n,config:t,id:o,...a},s)=>{let c=_react.useId.call(void 0, ),l=`chart-${o||c.replace(/:/g,"")}`;return _jsxruntime.jsx.call(void 0, _.Provider,{value:{config:t},children:_jsxruntime.jsxs.call(void 0, "div",{ref:s,className:_chunkDD6AVCRHcjs.a.call(void 0, "flex aspect-video justify-center text-xs","[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground","[&_.recharts-cartesian-grid_line]:stroke-border/50","[&_.recharts-curve.recharts-tooltip-cursor]:stroke-border","[&_.recharts-dot]:stroke-transparent","[&_.recharts-layer]:outline-none","[&_.recharts-polar-grid_]:stroke-border","[&_.recharts-radial-bar-background-sector]:fill-muted","[&_.recharts-reference-line_]:stroke-border","[&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted","[&_.recharts-sector]:outline-none","[&_.recharts-sector]:stroke-transparent","[&_.recharts-surface]:outline-none",n),"data-chart":l,...a,children:[_jsxruntime.jsx.call(void 0, $,{config:t,id:l}),_jsxruntime.jsx.call(void 0, g.ResponsiveContainer,{children:e})]})})});K.displayName="Chart";function $({id:e,config:n}){let t=_react.useMemo.call(void 0, ()=>J(e,n),[e,n]);return _jsxruntime.jsx.call(void 0, "style",{dangerouslySetInnerHTML:{__html:t}})}var G=g.Tooltip,O= exports.d =_react.forwardRef.call(void 0, ({active:e,className:n,color:t,formatter:o,hideIndicator:a=!1,hideLabel:s=!1,indicator:c="dot",label:l,labelClassName:p,labelFormatter:C,labelKey:y,nameKey:E,payload:h},I)=>{let{config:m}=w(),L=_react.useMemo.call(void 0, ()=>{if(s||!_optionalChain([h, 'optionalAccess', _2 => _2.length]))return null;let[r]=h,P=`${y||r.dataKey||r.name||"value"}`,b=T(m,r,P),u=!y&&typeof l=="string"?_optionalChain([m, 'access', _3 => _3[l], 'optionalAccess', _4 => _4.label])||l:_optionalChain([b, 'optionalAccess', _5 => _5.label]);return C?_jsxruntime.jsx.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "font-medium",p),children:C(u,h)}):u?_jsxruntime.jsx.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "font-medium",p),children:u}):null},[m,s,l,p,C,y,h]);if(!e||!_optionalChain([h, 'optionalAccess', _6 => _6.length]))return null;let v=h.length===1&&c!=="dot";return _jsxruntime.jsxs.call(void 0, "div",{ref:I,className:_chunkDD6AVCRHcjs.a.call(void 0, "border-border/50 bg-background grid min-w-[8rem] items-start gap-1.5 rounded-lg border px-2.5 py-1.5 text-xs shadow-xl",n),children:[v?null:L,_jsxruntime.jsx.call(void 0, "div",{className:"grid gap-1.5",children:h.map((r,P)=>{let b=`${E||r.name||r.dataKey||"value"}`,u=T(m,r,b),S=t||r.payload.fill||r.color;return _jsxruntime.jsx.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5",c==="dot"&&"items-center"),children:o&&r.value!==void 0&&r.name?o(r.value,r.name,r,P,r.payload):_jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment,{children:[_optionalChain([u, 'optionalAccess', _7 => _7.icon])?_jsxruntime.jsx.call(void 0, u.icon,{}):!a&&_jsxruntime.jsx.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "shrink-0 rounded-[2px] border-[--color-border] bg-[--color-bg]",{"h-2.5 w-2.5":c==="dot","w-1":c==="line","w-0 border-[1.5px] border-dashed bg-transparent":c==="dashed","my-0.5":v&&c==="dashed"}),style:{"--color-bg":S,"--color-border":S}}),_jsxruntime.jsxs.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "flex flex-1 justify-between leading-none",v?"items-end":"items-center"),children:[_jsxruntime.jsxs.call(void 0, "div",{className:"grid gap-1.5",children:[v?L:null,_jsxruntime.jsx.call(void 0, "span",{className:"text-muted-foreground",children:_optionalChain([u, 'optionalAccess', _8 => _8.label])||r.name})]}),r.value?_jsxruntime.jsx.call(void 0, "span",{className:"text-foreground font-mono font-medium tabular-nums",children:r.value.toLocaleString()}):null]})]})},r.dataKey)})})]})});O.displayName="ChartTooltipContent";var Q=g.Legend,D= exports.f =_react.forwardRef.call(void 0, ({className:e,hideIcon:n=!1,nameKey:t,payload:o,verticalAlign:a="bottom"},s)=>{let{config:c}=w();return _optionalChain([o, 'optionalAccess', _9 => _9.length])?_jsxruntime.jsx.call(void 0, "div",{ref:s,className:_chunkDD6AVCRHcjs.a.call(void 0, "flex items-center justify-center gap-4",a==="top"?"pb-3":"pt-3",e),children:o.map(l=>{let p="value";t?p=t:l.dataKey&&(p=String(l.dataKey));let C=T(c,l,p);return _jsxruntime.jsxs.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:size-3"),children:[_optionalChain([C, 'optionalAccess', _10 => _10.icon])&&!n?_jsxruntime.jsx.call(void 0, C.icon,{}):_jsxruntime.jsx.call(void 0, "div",{className:"size-2 shrink-0 rounded",style:{backgroundColor:l.color}}),_optionalChain([C, 'optionalAccess', _11 => _11.label])]},String(l.value))})}):null});D.displayName="ChartLegendContent";function T(e,n,t){if(!k(n))return;let o="payload"in n&&k(n.payload)?n.payload:void 0,a=V(n,o,t);return a in e?e[a]:e[t]}function k(e){return typeof e=="object"&&e!==null}function V(e,n,t){return t in e&&typeof e[t]=="string"?e[t]:n&&t in n&&typeof n[t]=="string"?n[t]:t}function z(e,n,t){let o=[];return o.push(`${N[e]} [data-chart=${n}] {`),t.forEach(([a,s])=>{let c=_optionalChain([s, 'optionalAccess', _12 => _12.theme, 'optionalAccess', _13 => _13[e]])||_optionalChain([s, 'optionalAccess', _14 => _14.color]);c&&o.push(` --color-${a}: ${c};`)}),o.push("}"),o.join(`
2
+ `)}function J(e,n){let t=Object.entries(n).filter(([a,s])=>_optionalChain([s, 'optionalAccess', _15 => _15.theme])||_optionalChain([s, 'optionalAccess', _16 => _16.color])),o=[];return Object.keys(N).forEach(a=>{let s=z(a,e,t);o.push(s)}),o.join(`
3
+ `)}exports.a = K; exports.b = $; exports.c = G; exports.d = O; exports.e = Q; exports.f = D;
4
+ //# sourceMappingURL=chunk-FVR3LJWM.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["/home/runner/work/codefast/codefast/packages/ui/dist/chunk-FVR3LJWM.cjs","../src/components/chart.tsx"],"names":["RechartsPrimitive","createContext","useChart","ChartContainer","children","className","id","ref","uniqueId","useId","chartId","jsx","ChartContext"],"mappings":"AAAA,22BAAY,CAAC,wDCKX,8BASUA,gFAiNM,+CA3MhB,IACA,CAAA,CAAA,CAAA,KAAM,CAAA,EACR,CAAA,IA6BqBC,CAAwC,OAE7D,CAAA,CAAA,CAAA,CAAA,kCAAA,IAASC,CAA8B,CACrC,SAAuC,CAAA,CAEvC,CAAA,CAAA,IACE,CAAA,CAAA,+BAAA,CAAA,CAAM,CAAA,EAAA,CAAI,CAAA,CAAA,CAAA,MAAM,IAAA,KAAA,CAAA,mDAgBpB,CAAA,CAAMC,OACD,CAAA,CAAA,IAAA,CAAA,CAAAC,+BAAAA,CAAU,CAAA,QAAAC,CAAAA,CAAW,CAAA,SAAQ,CAAA,CAAAC,CAAAA,MAAa,CAAGC,CAAAA,CAAAA,EAAQ,CACtD,CAAA,CAAA,GAAMC,CAAWC,CAAAA,CAAM,CAAA,CACjBC,EAAU,CAAA,IAAA,CAAA,CAAA,0BAAA,CAASJ,CAAAA,CAAME,CAAAA,CAAS,MAAA,EAAQ,CAAA,EAAA,CAAA,CAAM,OAEtD,CAAA,IAAA,CACEG,EAACC,CAAAA,CAAa,CAAA;AA6XG;AACvB","file":"/home/runner/work/codefast/codefast/packages/ui/dist/chunk-FVR3LJWM.cjs","sourcesContent":[null,"'use client';\n\nimport {\n type ComponentProps,\n type ComponentType,\n createContext,\n type CSSProperties,\n forwardRef,\n type JSX,\n type ReactNode,\n useContext,\n useId,\n useMemo,\n} from 'react';\nimport * as RechartsPrimitive from 'recharts';\nimport { type NameType, type Payload, type ValueType } from 'recharts/types/component/DefaultTooltipContent';\n\nimport { cn } from '@/lib/utils';\n\nconst THEMES = {\n light: '',\n dark: '.dark',\n} as const;\n\ntype Theme = keyof typeof THEMES;\n\ninterface IconLabelConfig {\n icon?: ComponentType;\n label?: ReactNode | undefined;\n}\n\ninterface ColorConfig {\n color?: string;\n theme?: never;\n}\n\ninterface ThemeConfig {\n theme: Record<Theme, string>;\n color?: never;\n}\n\ntype ChartConfigItem = IconLabelConfig & (ColorConfig | ThemeConfig);\n\ntype ChartConfig = {\n [k in string]: ChartConfigItem | undefined;\n};\n\ninterface ChartContextProps {\n config: ChartConfig;\n}\n\nconst ChartContext = createContext<ChartContextProps | null>(null);\n\nfunction useChart(): ChartContextProps {\n const context = useContext(ChartContext);\n\n if (!context) {\n throw new Error('useChart must be used within a <ChartContainer />');\n }\n\n return context;\n}\n\n/* -----------------------------------------------------------------------------\n * Component: Chart\n * -------------------------------------------------------------------------- */\n\ntype ChartContainerElement = HTMLDivElement;\ninterface ChartContainerProps extends ComponentProps<'div'> {\n children: ComponentProps<typeof RechartsPrimitive.ResponsiveContainer>['children'];\n config: ChartConfig;\n}\n\nconst ChartContainer = forwardRef<ChartContainerElement, ChartContainerProps>(\n ({ children, className, config, id, ...props }, ref) => {\n const uniqueId = useId();\n const chartId = `chart-${id || uniqueId.replace(/:/g, '')}`;\n\n return (\n <ChartContext.Provider value={{ config }}>\n <div\n ref={ref}\n className={cn(\n 'flex aspect-video justify-center text-xs',\n '[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground',\n '[&_.recharts-cartesian-grid_line]:stroke-border/50',\n '[&_.recharts-curve.recharts-tooltip-cursor]:stroke-border',\n '[&_.recharts-dot]:stroke-transparent',\n '[&_.recharts-layer]:outline-none',\n '[&_.recharts-polar-grid_]:stroke-border',\n '[&_.recharts-radial-bar-background-sector]:fill-muted',\n '[&_.recharts-reference-line_]:stroke-border',\n '[&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted',\n '[&_.recharts-sector]:outline-none',\n '[&_.recharts-sector]:stroke-transparent',\n '[&_.recharts-surface]:outline-none',\n className,\n )}\n data-chart={chartId}\n {...props}\n >\n <ChartStyle config={config} id={chartId} />\n <RechartsPrimitive.ResponsiveContainer>{children}</RechartsPrimitive.ResponsiveContainer>\n </div>\n </ChartContext.Provider>\n );\n },\n);\n\nChartContainer.displayName = 'Chart';\n\n/* -----------------------------------------------------------------------------\n * Component: ChartStyle\n * -------------------------------------------------------------------------- */\n\ninterface ChartStyleProps {\n config: ChartConfig;\n id: string;\n}\n\nfunction ChartStyle({ id, config }: ChartStyleProps): JSX.Element | null {\n const cssString = useMemo(() => generateCSS(id, config), [id, config]);\n\n return <style dangerouslySetInnerHTML={{ __html: cssString }} />;\n}\n\n/* -----------------------------------------------------------------------------\n * Component: ChartTooltip\n * -------------------------------------------------------------------------- */\n\ntype ChartTooltipProps = ComponentProps<typeof RechartsPrimitive.Tooltip>;\nconst ChartTooltip = RechartsPrimitive.Tooltip;\n\n/* -----------------------------------------------------------------------------\n * Component: ChartTooltipContent\n * -------------------------------------------------------------------------- */\n\ntype ChartTooltipContentElement = HTMLDivElement;\ninterface ChartTooltipContentProps\n extends ComponentProps<typeof RechartsPrimitive.Tooltip>,\n Omit<ComponentProps<'div'>, 'content'> {\n hideIndicator?: boolean;\n hideLabel?: boolean;\n indicator?: 'line' | 'dot' | 'dashed';\n labelKey?: string;\n nameKey?: string;\n}\n\nconst ChartTooltipContent = forwardRef<ChartTooltipContentElement, ChartTooltipContentProps>(\n (\n {\n active,\n className,\n color,\n formatter,\n hideIndicator = false,\n hideLabel = false,\n indicator = 'dot',\n label,\n labelClassName,\n labelFormatter,\n labelKey,\n nameKey,\n payload,\n },\n ref,\n ) => {\n const { config } = useChart();\n\n const tooltipLabel = useMemo(() => {\n if (hideLabel || !payload?.length) {\n return null;\n }\n\n const [item] = payload;\n\n const key = `${labelKey || item.dataKey || item.name || 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const value = !labelKey && typeof label === 'string' ? config[label]?.label || label : itemConfig?.label;\n\n if (labelFormatter) {\n return <div className={cn('font-medium', labelClassName)}>{labelFormatter(value, payload)}</div>;\n }\n\n if (!value) {\n return null;\n }\n\n return <div className={cn('font-medium', labelClassName)}>{value}</div>;\n }, [config, hideLabel, label, labelClassName, labelFormatter, labelKey, payload]);\n\n if (!active || !payload?.length) {\n return null;\n }\n\n const nestLabel = payload.length === 1 && indicator !== 'dot';\n\n return (\n <div\n ref={ref}\n className={cn(\n 'border-border/50 bg-background grid min-w-[8rem] items-start gap-1.5 rounded-lg border px-2.5 py-1.5 text-xs shadow-xl',\n className,\n )}\n >\n {!nestLabel ? tooltipLabel : null}\n <div className=\"grid gap-1.5\">\n {payload.map((item, index) => {\n const key = `${nameKey || item.name || item.dataKey || 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const indicatorColor = color || (item.payload as { fill?: string }).fill || item.color;\n\n return (\n <div\n key={item.dataKey}\n className={cn(\n '[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5',\n indicator === 'dot' && 'items-center',\n )}\n >\n {formatter && item.value !== undefined && item.name ? (\n formatter(item.value, item.name, item, index, item.payload as Payload<ValueType, NameType>[])\n ) : (\n <>\n {itemConfig?.icon ? (\n <itemConfig.icon />\n ) : (\n !hideIndicator && (\n <div\n className={cn('shrink-0 rounded-[2px] border-[--color-border] bg-[--color-bg]', {\n 'h-2.5 w-2.5': indicator === 'dot',\n 'w-1': indicator === 'line',\n 'w-0 border-[1.5px] border-dashed bg-transparent': indicator === 'dashed',\n 'my-0.5': nestLabel && indicator === 'dashed',\n })}\n style={\n {\n '--color-bg': indicatorColor,\n '--color-border': indicatorColor,\n } as CSSProperties\n }\n />\n )\n )}\n <div\n className={cn(\n 'flex flex-1 justify-between leading-none',\n nestLabel ? 'items-end' : 'items-center',\n )}\n >\n <div className=\"grid gap-1.5\">\n {nestLabel ? tooltipLabel : null}\n <span className=\"text-muted-foreground\">{itemConfig?.label || item.name}</span>\n </div>\n {item.value ? (\n <span className=\"text-foreground font-mono font-medium tabular-nums\">\n {item.value.toLocaleString()}\n </span>\n ) : null}\n </div>\n </>\n )}\n </div>\n );\n })}\n </div>\n </div>\n );\n },\n);\n\nChartTooltipContent.displayName = 'ChartTooltipContent';\n\n/* -----------------------------------------------------------------------------\n * Component: ChartLegend\n * -------------------------------------------------------------------------- */\n\ntype ChartLegendProps = ComponentProps<typeof RechartsPrimitive.Legend>;\nconst ChartLegend = RechartsPrimitive.Legend;\n\n/* -----------------------------------------------------------------------------\n * Component: ChartLegendContent\n * -------------------------------------------------------------------------- */\n\ntype ChartLegendContent = HTMLDivElement;\ninterface ChartLegendContentProps\n extends ComponentProps<'div'>,\n Pick<RechartsPrimitive.LegendProps, 'payload' | 'verticalAlign'> {\n hideIcon?: boolean;\n nameKey?: string;\n}\n\nconst ChartLegendContent = forwardRef<HTMLDivElement, ChartLegendContentProps>(\n ({ className, hideIcon = false, nameKey, payload, verticalAlign = 'bottom' }, ref) => {\n const { config } = useChart();\n\n if (!payload?.length) {\n return null;\n }\n\n return (\n <div\n ref={ref}\n className={cn('flex items-center justify-center gap-4', verticalAlign === 'top' ? 'pb-3' : 'pt-3', className)}\n >\n {payload.map((item) => {\n let key = 'value';\n\n if (nameKey) {\n key = nameKey;\n } else if (item.dataKey) {\n key = String(item.dataKey);\n }\n\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n\n return (\n <div\n key={String(item.value)}\n className={cn('[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:size-3')}\n >\n {itemConfig?.icon && !hideIcon ? (\n <itemConfig.icon />\n ) : (\n <div\n className=\"size-2 shrink-0 rounded\"\n style={{\n backgroundColor: item.color,\n }}\n />\n )}\n {itemConfig?.label}\n </div>\n );\n })}\n </div>\n );\n },\n);\n\nChartLegendContent.displayName = 'ChartLegendContent';\n\n/* -----------------------------------------------------------------------------\n * Helpers\n * -------------------------------------------------------------------------- */\n\n/**\n * Extracts and returns the appropriate configuration object from\n * the payload based on the specified key.\n *\n * @param config - The chart configuration object that contains various\n * settings.\n * @param payload - The payload object that might contain nested payload data.\n * @param key - The key used to retrieve the specific configuration from the\n * chart config.\n * @returns Returns a configuration object with optional properties `icon`,\n * `label`, `color` or `theme`, or `undefined` if the payload is invalid or\n * no configuration is found for the provided key.\n */\nfunction getPayloadConfigFromPayload(config: ChartConfig, payload: unknown, key: string): ChartConfigItem | undefined {\n if (!isValidObject(payload)) {\n return undefined;\n }\n\n const nestedPayload = 'payload' in payload && isValidObject(payload.payload) ? payload.payload : undefined;\n\n const configLabelKey = getConfigLabelKey(payload, nestedPayload, key);\n\n return configLabelKey in config ? config[configLabelKey] : config[key];\n}\n\n/**\n * Checks if the provided value is a valid object.\n *\n * @param obj - The value to check.\n * @returns - Returns true if the value is an object and not null, false\n * otherwise.\n */\nfunction isValidObject(obj: unknown): obj is Record<string, unknown> {\n return typeof obj === 'object' && obj !== null;\n}\n\n/**\n * Retrieves the configuration label key from either the payload or\n * nestedPayload. If the key exists in the payload and is a string, the\n * corresponding value is returned. Otherwise, if the key exists in the\n * nestedPayload and is a string, its value is returned. If the key is not\n * found as a string in either object, the key itself is returned.\n *\n * @param payload - The primary payload containing key-value pairs.\n * @param nestedPayload - An optional nested payload containing additional\n * key-value pairs.\n * @param key - The key to search for within the payload and nestedPayload.\n *\n * @returns The string value associated with the key if found; otherwise, the\n * key itself.\n */\nfunction getConfigLabelKey(\n payload: Record<string, unknown>,\n nestedPayload: Record<string, unknown> | undefined,\n key: string,\n): string {\n if (key in payload && typeof payload[key] === 'string') {\n return payload[key];\n }\n\n if (nestedPayload && key in nestedPayload && typeof nestedPayload[key] === 'string') {\n return nestedPayload[key];\n }\n\n return key;\n}\n\n/**\n * Generates CSS for a specified theme and chart configuration.\n *\n * @param theme - The theme to be used (for example, 'light', 'dark').\n * @param id - The unique identifier of the chart.\n * @param configEntries - A list of configuration entries, each containing a\n * key and a chart configuration.\n * @returns The generated CSS as a string.\n */\nfunction generateThemeCSS(theme: Theme, id: string, configEntries: [string, ChartConfig[string]][]): string {\n const rules: string[] = [];\n\n rules.push(`${THEMES[theme]} [data-chart=${id}] {`);\n\n configEntries.forEach(([key, itemConfig]) => {\n const color = itemConfig?.theme?.[theme] || itemConfig?.color;\n\n if (color) {\n rules.push(` --color-${key}: ${color};`);\n }\n });\n\n rules.push('}');\n\n return rules.join('\\n');\n}\n\n/**\n * Generates CSS styles for a chart based on the provided configuration and\n * themes.\n *\n * @param id - The unique identifier for the chart element.\n * @param config - Configuration object for the chart. This includes theme and\n * color settings.\n * @returns A string containing the generated CSS rules.\n */\nfunction generateCSS(id: string, config: ChartConfig): string {\n const themeOrColorConfig = Object.entries(config).filter(([_, itemConfig]) => itemConfig?.theme || itemConfig?.color);\n\n const allRules: string[] = [];\n\n Object.keys(THEMES).forEach((theme) => {\n const themeCSS = generateThemeCSS(theme as Theme, id, themeOrColorConfig);\n\n allRules.push(themeCSS);\n });\n\n return allRules.join('\\n');\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n ChartContainer,\n ChartLegend,\n ChartLegendContent,\n ChartStyle,\n ChartTooltip,\n ChartTooltipContent,\n type ChartConfig,\n type ChartContainerProps,\n type ChartLegendContentProps,\n type ChartLegendProps,\n type ChartStyleProps,\n type ChartTooltipContentProps,\n type ChartTooltipProps,\n};\n"]}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } }var _chunkDD6AVCRHcjs = require('./chunk-DD6AVCRH.cjs');var _reacttabs = require('@radix-ui/react-tabs'); var e = _interopRequireWildcard(_reacttabs);var _react = require('react');var _jsxruntime = require('react/jsx-runtime');var g=e.Root,a= exports.b =_react.forwardRef.call(void 0, ({className:t,...i},s)=>_jsxruntime.jsx.call(void 0, e.List,{ref:s,className:_chunkDD6AVCRHcjs.a.call(void 0, "bg-muted text-muted-foreground inline-flex h-10 items-center justify-center gap-1 rounded-md p-1",t),...i}));a.displayName=e.List.displayName;var p=_react.forwardRef.call(void 0, ({className:t,...i},s)=>_jsxruntime.jsx.call(void 0, e.Trigger,{ref:s,className:_chunkDD6AVCRHcjs.a.call(void 0, "inline-flex items-center justify-center whitespace-nowrap rounded px-3 py-1.5 text-sm font-medium outline-transparent transition-all","data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm","focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2","disabled:pointer-events-none disabled:opacity-50",t),...i}));p.displayName=e.Trigger.displayName;var m=_react.forwardRef.call(void 0, ({className:t,...i},s)=>_jsxruntime.jsx.call(void 0, e.Content,{ref:s,className:_chunkDD6AVCRHcjs.a.call(void 0, "mt-2 rounded-md","focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",t),...i}));m.displayName=e.Content.displayName;exports.a = g; exports.b = a; exports.c = p; exports.d = m;
2
- //# sourceMappingURL=chunk-NGEZQP54.cjs.map
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } }var _chunkDD6AVCRHcjs = require('./chunk-DD6AVCRH.cjs');var _reacttabs = require('@radix-ui/react-tabs'); var e = _interopRequireWildcard(_reacttabs);var _react = require('react');var _jsxruntime = require('react/jsx-runtime');var g=e.Root,a= exports.b =_react.forwardRef.call(void 0, ({className:t,...i},s)=>_jsxruntime.jsx.call(void 0, e.List,{ref:s,className:_chunkDD6AVCRHcjs.a.call(void 0, "bg-muted text-muted-foreground inline-flex h-10 items-center justify-center gap-1 rounded-md p-1",t),...i}));a.displayName=e.List.displayName;var p=_react.forwardRef.call(void 0, ({className:t,...i},s)=>_jsxruntime.jsx.call(void 0, e.Trigger,{ref:s,className:_chunkDD6AVCRHcjs.a.call(void 0, "inline-flex items-center justify-center whitespace-nowrap rounded-md px-3 py-1.5 text-sm font-medium outline-transparent transition-all","data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm","focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2","disabled:pointer-events-none disabled:opacity-50",t),...i}));p.displayName=e.Trigger.displayName;var m=_react.forwardRef.call(void 0, ({className:t,...i},s)=>_jsxruntime.jsx.call(void 0, e.Content,{ref:s,className:_chunkDD6AVCRHcjs.a.call(void 0, "mt-2 rounded-md","focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",t),...i}));m.displayName=e.Content.displayName;exports.a = g; exports.b = a; exports.c = p; exports.d = m;
2
+ //# sourceMappingURL=chunk-TQEAAFPM.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["/home/runner/work/codefast/codefast/packages/ui/dist/chunk-NGEZQP54.cjs","../src/components/tabs.tsx"],"names":["Tabs","TabsList","forwardRef","className","props","forwardedRef","jsx","cn","TabsTrigger","TabsContent"],"mappings":"AAAA,mZAAwC,8FCAT,8BAC8C,+CAmB3E,IAVIA,CAAAA,CAAqB,CAAA,CAAA,IAAA,CASrBC,CAAAA,aAAWC,+BAAAA,CAA4C,CAAE,SAAA,CAAAC,CAAAA,CAAW,GAAGC,CAAM,CAAA,CAAGC,CAAAA,CAAAA,EACpFC,6BAAAA,CAAe,CAAA,IAAA,CAAd,CACC,GAAA,CAAKD,CAAAA,CACL,SAAA,CAAWE,iCAAAA,kGACT,CACAJ,CACF,CAAA,CACC,GAAGC,CAAAA,CACN,CACD,CAAA,CAEDH,CAAAA,CAAS,WAAA,CAA4B,CAAA,CAAA,IAAA,CAAK,WAAA,CAS1C,IAAMO,CAAAA,CAAcN,+BAAAA,CAAkD,CAAE,SAAA,CAAAC,CAAAA,CAAW,GAAGC,CAAM,CAAA,CAAGC,CAAAA,CAAAA,EAC7FC,6BAAAA,CAAe,CAAA,OAAA,CAAd,CACC,GAAA,CAAKD,CAAAA,CACL,SAAA,CAAWE,iCAAAA,sIACT,CACA,qGAAA,CACA,qGAAA,CACA,kDAAA,CACAJ,CACF,CAAA,CACC,GAAGC,CAAAA,CACN,CACD,CAAA,CAEDI,CAAAA,CAAY,WAAA,CAA4B,CAAA,CAAA,OAAA,CAAQ,WAAA,CAShD,IAAMC,CAAAA,CAAcP,+BAAAA,CAAkD,CAAE,SAAA,CAAAC,CAAAA,CAAW,GAAGC,CAAM,CAAA,CAAGC,CAAAA,CAAAA,EAC7FC,6BAAAA,CAAe,CAAA,OAAA,CAAd,CACC,GAAA,CAAKD,CAAAA,CACL,SAAA,CAAWE,iCAAAA,iBACT,CACA,qGAAA,CACAJ,CACF,CAAA,CACC,GAAGC,CAAAA,CACN,CACD,CAAA,CAEDK,CAAAA,CAAY,WAAA,CAA4B,CAAA,CAAA,OAAA,CAAQ,WAAA,CAAA,2DAAA","file":"/home/runner/work/codefast/codefast/packages/ui/dist/chunk-NGEZQP54.cjs","sourcesContent":[null,"import * as TabsPrimitive from '@radix-ui/react-tabs';\nimport { type ComponentPropsWithoutRef, type ComponentRef, forwardRef } from 'react';\n\nimport { cn } from '@/lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: Tabs\n * -------------------------------------------------------------------------- */\n\ntype TabsProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Root>;\nconst Tabs = TabsPrimitive.Root;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsList\n * -------------------------------------------------------------------------- */\n\ntype TabsListElement = ComponentRef<typeof TabsPrimitive.List>;\ntype TabsListProps = ComponentPropsWithoutRef<typeof TabsPrimitive.List>;\n\nconst TabsList = forwardRef<TabsListElement, TabsListProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.List\n ref={forwardedRef}\n className={cn(\n 'bg-muted text-muted-foreground inline-flex h-10 items-center justify-center gap-1 rounded-md p-1',\n className,\n )}\n {...props}\n />\n));\n\nTabsList.displayName = TabsPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsTrigger\n * -------------------------------------------------------------------------- */\n\ntype TabsTriggerElement = ComponentRef<typeof TabsPrimitive.Trigger>;\ntype TabsTriggerProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger>;\n\nconst TabsTrigger = forwardRef<TabsTriggerElement, TabsTriggerProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.Trigger\n ref={forwardedRef}\n className={cn(\n 'inline-flex items-center justify-center whitespace-nowrap rounded px-3 py-1.5 text-sm font-medium outline-transparent transition-all',\n 'data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm',\n 'focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2',\n 'disabled:pointer-events-none disabled:opacity-50',\n className,\n )}\n {...props}\n />\n));\n\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsContent\n * -------------------------------------------------------------------------- */\n\ntype TabsContentElement = ComponentRef<typeof TabsPrimitive.Content>;\ntype TabsContentProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Content>;\n\nconst TabsContent = forwardRef<TabsContentElement, TabsContentProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.Content\n ref={forwardedRef}\n className={cn(\n 'mt-2 rounded-md',\n 'focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2',\n className,\n )}\n {...props}\n />\n));\n\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Tabs,\n TabsContent,\n TabsList,\n TabsTrigger,\n type TabsContentProps,\n type TabsListProps,\n type TabsProps,\n type TabsTriggerProps,\n};\n"]}
1
+ {"version":3,"sources":["/home/runner/work/codefast/codefast/packages/ui/dist/chunk-TQEAAFPM.cjs","../src/components/tabs.tsx"],"names":["Tabs","TabsList","forwardRef","className","props","forwardedRef","jsx","cn","TabsTrigger","TabsContent"],"mappings":"AAAA,mZAAwC,8FCAT,8BAC8C,+CAmB3E,IAVIA,CAAAA,CAAqB,CAAA,CAAA,IAAA,CASrBC,CAAAA,aAAWC,+BAAAA,CAA4C,CAAE,SAAA,CAAAC,CAAAA,CAAW,GAAGC,CAAM,CAAA,CAAGC,CAAAA,CAAAA,EACpFC,6BAAAA,CAAe,CAAA,IAAA,CAAd,CACC,GAAA,CAAKD,CAAAA,CACL,SAAA,CAAWE,iCAAAA,kGACT,CACAJ,CACF,CAAA,CACC,GAAGC,CAAAA,CACN,CACD,CAAA,CAEDH,CAAAA,CAAS,WAAA,CAA4B,CAAA,CAAA,IAAA,CAAK,WAAA,CAS1C,IAAMO,CAAAA,CAAcN,+BAAAA,CAAkD,CAAE,SAAA,CAAAC,CAAAA,CAAW,GAAGC,CAAM,CAAA,CAAGC,CAAAA,CAAAA,EAC7FC,6BAAAA,CAAe,CAAA,OAAA,CAAd,CACC,GAAA,CAAKD,CAAAA,CACL,SAAA,CAAWE,iCAAAA,yIACT,CACA,qGAAA,CACA,qGAAA,CACA,kDAAA,CACAJ,CACF,CAAA,CACC,GAAGC,CAAAA,CACN,CACD,CAAA,CAEDI,CAAAA,CAAY,WAAA,CAA4B,CAAA,CAAA,OAAA,CAAQ,WAAA,CAShD,IAAMC,CAAAA,CAAcP,+BAAAA,CAAkD,CAAE,SAAA,CAAAC,CAAAA,CAAW,GAAGC,CAAM,CAAA,CAAGC,CAAAA,CAAAA,EAC7FC,6BAAAA,CAAe,CAAA,OAAA,CAAd,CACC,GAAA,CAAKD,CAAAA,CACL,SAAA,CAAWE,iCAAAA,iBACT,CACA,qGAAA,CACAJ,CACF,CAAA,CACC,GAAGC,CAAAA,CACN,CACD,CAAA,CAEDK,CAAAA,CAAY,WAAA,CAA4B,CAAA,CAAA,OAAA,CAAQ,WAAA,CAAA,2DAAA","file":"/home/runner/work/codefast/codefast/packages/ui/dist/chunk-TQEAAFPM.cjs","sourcesContent":[null,"import * as TabsPrimitive from '@radix-ui/react-tabs';\nimport { type ComponentPropsWithoutRef, type ComponentRef, forwardRef } from 'react';\n\nimport { cn } from '@/lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: Tabs\n * -------------------------------------------------------------------------- */\n\ntype TabsProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Root>;\nconst Tabs = TabsPrimitive.Root;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsList\n * -------------------------------------------------------------------------- */\n\ntype TabsListElement = ComponentRef<typeof TabsPrimitive.List>;\ntype TabsListProps = ComponentPropsWithoutRef<typeof TabsPrimitive.List>;\n\nconst TabsList = forwardRef<TabsListElement, TabsListProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.List\n ref={forwardedRef}\n className={cn(\n 'bg-muted text-muted-foreground inline-flex h-10 items-center justify-center gap-1 rounded-md p-1',\n className,\n )}\n {...props}\n />\n));\n\nTabsList.displayName = TabsPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsTrigger\n * -------------------------------------------------------------------------- */\n\ntype TabsTriggerElement = ComponentRef<typeof TabsPrimitive.Trigger>;\ntype TabsTriggerProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger>;\n\nconst TabsTrigger = forwardRef<TabsTriggerElement, TabsTriggerProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.Trigger\n ref={forwardedRef}\n className={cn(\n 'inline-flex items-center justify-center whitespace-nowrap rounded-md px-3 py-1.5 text-sm font-medium outline-transparent transition-all',\n 'data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm',\n 'focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2',\n 'disabled:pointer-events-none disabled:opacity-50',\n className,\n )}\n {...props}\n />\n));\n\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: TabsContent\n * -------------------------------------------------------------------------- */\n\ntype TabsContentElement = ComponentRef<typeof TabsPrimitive.Content>;\ntype TabsContentProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Content>;\n\nconst TabsContent = forwardRef<TabsContentElement, TabsContentProps>(({ className, ...props }, forwardedRef) => (\n <TabsPrimitive.Content\n ref={forwardedRef}\n className={cn(\n 'mt-2 rounded-md',\n 'focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2',\n className,\n )}\n {...props}\n />\n));\n\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Tabs,\n TabsContent,\n TabsList,\n TabsTrigger,\n type TabsContentProps,\n type TabsListProps,\n type TabsProps,\n type TabsTriggerProps,\n};\n"]}
@@ -0,0 +1,4 @@
1
+ "use client";import{a as d}from"./chunk-VPYH6JWS.js";import{createContext as j,forwardRef as x,useContext as M,useId as H,useMemo as R}from"react";import*as g from"recharts";import{Fragment as X,jsx as i,jsxs as f}from"react/jsx-runtime";var N={light:"",dark:".dark"},_=j(null);function w(){let e=M(_);if(!e)throw new Error("useChart must be used within a <ChartContainer />");return e}var K=x(({children:e,className:n,config:t,id:o,...a},s)=>{let c=H(),l=`chart-${o||c.replace(/:/g,"")}`;return i(_.Provider,{value:{config:t},children:f("div",{ref:s,className:d("flex aspect-video justify-center text-xs","[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground","[&_.recharts-cartesian-grid_line]:stroke-border/50","[&_.recharts-curve.recharts-tooltip-cursor]:stroke-border","[&_.recharts-dot]:stroke-transparent","[&_.recharts-layer]:outline-none","[&_.recharts-polar-grid_]:stroke-border","[&_.recharts-radial-bar-background-sector]:fill-muted","[&_.recharts-reference-line_]:stroke-border","[&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted","[&_.recharts-sector]:outline-none","[&_.recharts-sector]:stroke-transparent","[&_.recharts-surface]:outline-none",n),"data-chart":l,...a,children:[i($,{config:t,id:l}),i(g.ResponsiveContainer,{children:e})]})})});K.displayName="Chart";function $({id:e,config:n}){let t=R(()=>J(e,n),[e,n]);return i("style",{dangerouslySetInnerHTML:{__html:t}})}var Q=g.Tooltip,O=x(({active:e,className:n,color:t,formatter:o,hideIndicator:a=!1,hideLabel:s=!1,indicator:c="dot",label:l,labelClassName:p,labelFormatter:C,labelKey:y,nameKey:E,payload:h},I)=>{let{config:m}=w(),L=R(()=>{if(s||!h?.length)return null;let[r]=h,P=`${y||r.dataKey||r.name||"value"}`,b=T(m,r,P),u=!y&&typeof l=="string"?m[l]?.label||l:b?.label;return C?i("div",{className:d("font-medium",p),children:C(u,h)}):u?i("div",{className:d("font-medium",p),children:u}):null},[m,s,l,p,C,y,h]);if(!e||!h?.length)return null;let v=h.length===1&&c!=="dot";return f("div",{ref:I,className:d("border-border/50 bg-background grid min-w-[8rem] items-start gap-1.5 rounded-lg border px-2.5 py-1.5 text-xs shadow-xl",n),children:[v?null:L,i("div",{className:"grid gap-1.5",children:h.map((r,P)=>{let b=`${E||r.name||r.dataKey||"value"}`,u=T(m,r,b),S=t||r.payload.fill||r.color;return i("div",{className:d("[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5",c==="dot"&&"items-center"),children:o&&r.value!==void 0&&r.name?o(r.value,r.name,r,P,r.payload):f(X,{children:[u?.icon?i(u.icon,{}):!a&&i("div",{className:d("shrink-0 rounded-[2px] border-[--color-border] bg-[--color-bg]",{"h-2.5 w-2.5":c==="dot","w-1":c==="line","w-0 border-[1.5px] border-dashed bg-transparent":c==="dashed","my-0.5":v&&c==="dashed"}),style:{"--color-bg":S,"--color-border":S}}),f("div",{className:d("flex flex-1 justify-between leading-none",v?"items-end":"items-center"),children:[f("div",{className:"grid gap-1.5",children:[v?L:null,i("span",{className:"text-muted-foreground",children:u?.label||r.name})]}),r.value?i("span",{className:"text-foreground font-mono font-medium tabular-nums",children:r.value.toLocaleString()}):null]})]})},r.dataKey)})})]})});O.displayName="ChartTooltipContent";var U=g.Legend,D=x(({className:e,hideIcon:n=!1,nameKey:t,payload:o,verticalAlign:a="bottom"},s)=>{let{config:c}=w();return o?.length?i("div",{ref:s,className:d("flex items-center justify-center gap-4",a==="top"?"pb-3":"pt-3",e),children:o.map(l=>{let p="value";t?p=t:l.dataKey&&(p=String(l.dataKey));let C=T(c,l,p);return f("div",{className:d("[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:size-3"),children:[C?.icon&&!n?i(C.icon,{}):i("div",{className:"size-2 shrink-0 rounded",style:{backgroundColor:l.color}}),C?.label]},String(l.value))})}):null});D.displayName="ChartLegendContent";function T(e,n,t){if(!k(n))return;let o="payload"in n&&k(n.payload)?n.payload:void 0,a=V(n,o,t);return a in e?e[a]:e[t]}function k(e){return typeof e=="object"&&e!==null}function V(e,n,t){return t in e&&typeof e[t]=="string"?e[t]:n&&t in n&&typeof n[t]=="string"?n[t]:t}function z(e,n,t){let o=[];return o.push(`${N[e]} [data-chart=${n}] {`),t.forEach(([a,s])=>{let c=s?.theme?.[e]||s?.color;c&&o.push(` --color-${a}: ${c};`)}),o.push("}"),o.join(`
2
+ `)}function J(e,n){let t=Object.entries(n).filter(([a,s])=>s?.theme||s?.color),o=[];return Object.keys(N).forEach(a=>{let s=z(a,e,t);o.push(s)}),o.join(`
3
+ `)}export{K as a,$ as b,Q as c,O as d,U as e,D as f};
4
+ //# sourceMappingURL=chunk-VZSYA6XE.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/chart.tsx"],"names":["createContext","forwardRef","useContext","useId","useMemo","RechartsPrimitive","Fragment","jsx","jsxs","THEMES","ChartContext","useChart","context","ChartContainer","children","className","config","id","props","ref","uniqueId","chartId","cn","ChartStyle","cssString","generateCSS","ChartTooltip","ChartTooltipContent","active","color","formatter","hideIndicator","hideLabel","indicator","label","labelClassName","labelFormatter","labelKey","nameKey","payload","tooltipLabel","item","key","itemConfig","getPayloadConfigFromPayload","value","nestLabel","index","indicatorColor","ChartLegend","ChartLegendContent","hideIcon","verticalAlign","isValidObject","nestedPayload","configLabelKey","getConfigLabelKey","obj","generateThemeCSS","theme","configEntries","rules","themeOrColorConfig","_","allRules","themeCSS"],"mappings":"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","sourcesContent":["'use client';\n\nimport {\n type ComponentProps,\n type ComponentType,\n createContext,\n type CSSProperties,\n forwardRef,\n type JSX,\n type ReactNode,\n useContext,\n useId,\n useMemo,\n} from 'react';\nimport * as RechartsPrimitive from 'recharts';\nimport { type NameType, type Payload, type ValueType } from 'recharts/types/component/DefaultTooltipContent';\n\nimport { cn } from '@/lib/utils';\n\nconst THEMES = {\n light: '',\n dark: '.dark',\n} as const;\n\ntype Theme = keyof typeof THEMES;\n\ninterface IconLabelConfig {\n icon?: ComponentType;\n label?: ReactNode | undefined;\n}\n\ninterface ColorConfig {\n color?: string;\n theme?: never;\n}\n\ninterface ThemeConfig {\n theme: Record<Theme, string>;\n color?: never;\n}\n\ntype ChartConfigItem = IconLabelConfig & (ColorConfig | ThemeConfig);\n\ntype ChartConfig = {\n [k in string]: ChartConfigItem | undefined;\n};\n\ninterface ChartContextProps {\n config: ChartConfig;\n}\n\nconst ChartContext = createContext<ChartContextProps | null>(null);\n\nfunction useChart(): ChartContextProps {\n const context = useContext(ChartContext);\n\n if (!context) {\n throw new Error('useChart must be used within a <ChartContainer />');\n }\n\n return context;\n}\n\n/* -----------------------------------------------------------------------------\n * Component: Chart\n * -------------------------------------------------------------------------- */\n\ntype ChartContainerElement = HTMLDivElement;\ninterface ChartContainerProps extends ComponentProps<'div'> {\n children: ComponentProps<typeof RechartsPrimitive.ResponsiveContainer>['children'];\n config: ChartConfig;\n}\n\nconst ChartContainer = forwardRef<ChartContainerElement, ChartContainerProps>(\n ({ children, className, config, id, ...props }, ref) => {\n const uniqueId = useId();\n const chartId = `chart-${id || uniqueId.replace(/:/g, '')}`;\n\n return (\n <ChartContext.Provider value={{ config }}>\n <div\n ref={ref}\n className={cn(\n 'flex aspect-video justify-center text-xs',\n '[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground',\n '[&_.recharts-cartesian-grid_line]:stroke-border/50',\n '[&_.recharts-curve.recharts-tooltip-cursor]:stroke-border',\n '[&_.recharts-dot]:stroke-transparent',\n '[&_.recharts-layer]:outline-none',\n '[&_.recharts-polar-grid_]:stroke-border',\n '[&_.recharts-radial-bar-background-sector]:fill-muted',\n '[&_.recharts-reference-line_]:stroke-border',\n '[&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted',\n '[&_.recharts-sector]:outline-none',\n '[&_.recharts-sector]:stroke-transparent',\n '[&_.recharts-surface]:outline-none',\n className,\n )}\n data-chart={chartId}\n {...props}\n >\n <ChartStyle config={config} id={chartId} />\n <RechartsPrimitive.ResponsiveContainer>{children}</RechartsPrimitive.ResponsiveContainer>\n </div>\n </ChartContext.Provider>\n );\n },\n);\n\nChartContainer.displayName = 'Chart';\n\n/* -----------------------------------------------------------------------------\n * Component: ChartStyle\n * -------------------------------------------------------------------------- */\n\ninterface ChartStyleProps {\n config: ChartConfig;\n id: string;\n}\n\nfunction ChartStyle({ id, config }: ChartStyleProps): JSX.Element | null {\n const cssString = useMemo(() => generateCSS(id, config), [id, config]);\n\n return <style dangerouslySetInnerHTML={{ __html: cssString }} />;\n}\n\n/* -----------------------------------------------------------------------------\n * Component: ChartTooltip\n * -------------------------------------------------------------------------- */\n\ntype ChartTooltipProps = ComponentProps<typeof RechartsPrimitive.Tooltip>;\nconst ChartTooltip = RechartsPrimitive.Tooltip;\n\n/* -----------------------------------------------------------------------------\n * Component: ChartTooltipContent\n * -------------------------------------------------------------------------- */\n\ntype ChartTooltipContentElement = HTMLDivElement;\ninterface ChartTooltipContentProps\n extends ComponentProps<typeof RechartsPrimitive.Tooltip>,\n Omit<ComponentProps<'div'>, 'content'> {\n hideIndicator?: boolean;\n hideLabel?: boolean;\n indicator?: 'line' | 'dot' | 'dashed';\n labelKey?: string;\n nameKey?: string;\n}\n\nconst ChartTooltipContent = forwardRef<ChartTooltipContentElement, ChartTooltipContentProps>(\n (\n {\n active,\n className,\n color,\n formatter,\n hideIndicator = false,\n hideLabel = false,\n indicator = 'dot',\n label,\n labelClassName,\n labelFormatter,\n labelKey,\n nameKey,\n payload,\n },\n ref,\n ) => {\n const { config } = useChart();\n\n const tooltipLabel = useMemo(() => {\n if (hideLabel || !payload?.length) {\n return null;\n }\n\n const [item] = payload;\n\n const key = `${labelKey || item.dataKey || item.name || 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const value = !labelKey && typeof label === 'string' ? config[label]?.label || label : itemConfig?.label;\n\n if (labelFormatter) {\n return <div className={cn('font-medium', labelClassName)}>{labelFormatter(value, payload)}</div>;\n }\n\n if (!value) {\n return null;\n }\n\n return <div className={cn('font-medium', labelClassName)}>{value}</div>;\n }, [config, hideLabel, label, labelClassName, labelFormatter, labelKey, payload]);\n\n if (!active || !payload?.length) {\n return null;\n }\n\n const nestLabel = payload.length === 1 && indicator !== 'dot';\n\n return (\n <div\n ref={ref}\n className={cn(\n 'border-border/50 bg-background grid min-w-[8rem] items-start gap-1.5 rounded-lg border px-2.5 py-1.5 text-xs shadow-xl',\n className,\n )}\n >\n {!nestLabel ? tooltipLabel : null}\n <div className=\"grid gap-1.5\">\n {payload.map((item, index) => {\n const key = `${nameKey || item.name || item.dataKey || 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const indicatorColor = color || (item.payload as { fill?: string }).fill || item.color;\n\n return (\n <div\n key={item.dataKey}\n className={cn(\n '[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5',\n indicator === 'dot' && 'items-center',\n )}\n >\n {formatter && item.value !== undefined && item.name ? (\n formatter(item.value, item.name, item, index, item.payload as Payload<ValueType, NameType>[])\n ) : (\n <>\n {itemConfig?.icon ? (\n <itemConfig.icon />\n ) : (\n !hideIndicator && (\n <div\n className={cn('shrink-0 rounded-[2px] border-[--color-border] bg-[--color-bg]', {\n 'h-2.5 w-2.5': indicator === 'dot',\n 'w-1': indicator === 'line',\n 'w-0 border-[1.5px] border-dashed bg-transparent': indicator === 'dashed',\n 'my-0.5': nestLabel && indicator === 'dashed',\n })}\n style={\n {\n '--color-bg': indicatorColor,\n '--color-border': indicatorColor,\n } as CSSProperties\n }\n />\n )\n )}\n <div\n className={cn(\n 'flex flex-1 justify-between leading-none',\n nestLabel ? 'items-end' : 'items-center',\n )}\n >\n <div className=\"grid gap-1.5\">\n {nestLabel ? tooltipLabel : null}\n <span className=\"text-muted-foreground\">{itemConfig?.label || item.name}</span>\n </div>\n {item.value ? (\n <span className=\"text-foreground font-mono font-medium tabular-nums\">\n {item.value.toLocaleString()}\n </span>\n ) : null}\n </div>\n </>\n )}\n </div>\n );\n })}\n </div>\n </div>\n );\n },\n);\n\nChartTooltipContent.displayName = 'ChartTooltipContent';\n\n/* -----------------------------------------------------------------------------\n * Component: ChartLegend\n * -------------------------------------------------------------------------- */\n\ntype ChartLegendProps = ComponentProps<typeof RechartsPrimitive.Legend>;\nconst ChartLegend = RechartsPrimitive.Legend;\n\n/* -----------------------------------------------------------------------------\n * Component: ChartLegendContent\n * -------------------------------------------------------------------------- */\n\ntype ChartLegendContent = HTMLDivElement;\ninterface ChartLegendContentProps\n extends ComponentProps<'div'>,\n Pick<RechartsPrimitive.LegendProps, 'payload' | 'verticalAlign'> {\n hideIcon?: boolean;\n nameKey?: string;\n}\n\nconst ChartLegendContent = forwardRef<HTMLDivElement, ChartLegendContentProps>(\n ({ className, hideIcon = false, nameKey, payload, verticalAlign = 'bottom' }, ref) => {\n const { config } = useChart();\n\n if (!payload?.length) {\n return null;\n }\n\n return (\n <div\n ref={ref}\n className={cn('flex items-center justify-center gap-4', verticalAlign === 'top' ? 'pb-3' : 'pt-3', className)}\n >\n {payload.map((item) => {\n let key = 'value';\n\n if (nameKey) {\n key = nameKey;\n } else if (item.dataKey) {\n key = String(item.dataKey);\n }\n\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n\n return (\n <div\n key={String(item.value)}\n className={cn('[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:size-3')}\n >\n {itemConfig?.icon && !hideIcon ? (\n <itemConfig.icon />\n ) : (\n <div\n className=\"size-2 shrink-0 rounded\"\n style={{\n backgroundColor: item.color,\n }}\n />\n )}\n {itemConfig?.label}\n </div>\n );\n })}\n </div>\n );\n },\n);\n\nChartLegendContent.displayName = 'ChartLegendContent';\n\n/* -----------------------------------------------------------------------------\n * Helpers\n * -------------------------------------------------------------------------- */\n\n/**\n * Extracts and returns the appropriate configuration object from\n * the payload based on the specified key.\n *\n * @param config - The chart configuration object that contains various\n * settings.\n * @param payload - The payload object that might contain nested payload data.\n * @param key - The key used to retrieve the specific configuration from the\n * chart config.\n * @returns Returns a configuration object with optional properties `icon`,\n * `label`, `color` or `theme`, or `undefined` if the payload is invalid or\n * no configuration is found for the provided key.\n */\nfunction getPayloadConfigFromPayload(config: ChartConfig, payload: unknown, key: string): ChartConfigItem | undefined {\n if (!isValidObject(payload)) {\n return undefined;\n }\n\n const nestedPayload = 'payload' in payload && isValidObject(payload.payload) ? payload.payload : undefined;\n\n const configLabelKey = getConfigLabelKey(payload, nestedPayload, key);\n\n return configLabelKey in config ? config[configLabelKey] : config[key];\n}\n\n/**\n * Checks if the provided value is a valid object.\n *\n * @param obj - The value to check.\n * @returns - Returns true if the value is an object and not null, false\n * otherwise.\n */\nfunction isValidObject(obj: unknown): obj is Record<string, unknown> {\n return typeof obj === 'object' && obj !== null;\n}\n\n/**\n * Retrieves the configuration label key from either the payload or\n * nestedPayload. If the key exists in the payload and is a string, the\n * corresponding value is returned. Otherwise, if the key exists in the\n * nestedPayload and is a string, its value is returned. If the key is not\n * found as a string in either object, the key itself is returned.\n *\n * @param payload - The primary payload containing key-value pairs.\n * @param nestedPayload - An optional nested payload containing additional\n * key-value pairs.\n * @param key - The key to search for within the payload and nestedPayload.\n *\n * @returns The string value associated with the key if found; otherwise, the\n * key itself.\n */\nfunction getConfigLabelKey(\n payload: Record<string, unknown>,\n nestedPayload: Record<string, unknown> | undefined,\n key: string,\n): string {\n if (key in payload && typeof payload[key] === 'string') {\n return payload[key];\n }\n\n if (nestedPayload && key in nestedPayload && typeof nestedPayload[key] === 'string') {\n return nestedPayload[key];\n }\n\n return key;\n}\n\n/**\n * Generates CSS for a specified theme and chart configuration.\n *\n * @param theme - The theme to be used (for example, 'light', 'dark').\n * @param id - The unique identifier of the chart.\n * @param configEntries - A list of configuration entries, each containing a\n * key and a chart configuration.\n * @returns The generated CSS as a string.\n */\nfunction generateThemeCSS(theme: Theme, id: string, configEntries: [string, ChartConfig[string]][]): string {\n const rules: string[] = [];\n\n rules.push(`${THEMES[theme]} [data-chart=${id}] {`);\n\n configEntries.forEach(([key, itemConfig]) => {\n const color = itemConfig?.theme?.[theme] || itemConfig?.color;\n\n if (color) {\n rules.push(` --color-${key}: ${color};`);\n }\n });\n\n rules.push('}');\n\n return rules.join('\\n');\n}\n\n/**\n * Generates CSS styles for a chart based on the provided configuration and\n * themes.\n *\n * @param id - The unique identifier for the chart element.\n * @param config - Configuration object for the chart. This includes theme and\n * color settings.\n * @returns A string containing the generated CSS rules.\n */\nfunction generateCSS(id: string, config: ChartConfig): string {\n const themeOrColorConfig = Object.entries(config).filter(([_, itemConfig]) => itemConfig?.theme || itemConfig?.color);\n\n const allRules: string[] = [];\n\n Object.keys(THEMES).forEach((theme) => {\n const themeCSS = generateThemeCSS(theme as Theme, id, themeOrColorConfig);\n\n allRules.push(themeCSS);\n });\n\n return allRules.join('\\n');\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n ChartContainer,\n ChartLegend,\n ChartLegendContent,\n ChartStyle,\n ChartTooltip,\n ChartTooltipContent,\n type ChartConfig,\n type ChartContainerProps,\n type ChartLegendContentProps,\n type ChartLegendProps,\n type ChartStyleProps,\n type ChartTooltipContentProps,\n type ChartTooltipProps,\n};\n"]}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";var _chunkHO5BFEZOcjs = require('../chunk-HO5BFEZO.cjs');require('../chunk-DD6AVCRH.cjs');exports.ChartContainer = _chunkHO5BFEZOcjs.a; exports.ChartLegend = _chunkHO5BFEZOcjs.e; exports.ChartLegendContent = _chunkHO5BFEZOcjs.f; exports.ChartStyle = _chunkHO5BFEZOcjs.b; exports.ChartTooltip = _chunkHO5BFEZOcjs.c; exports.ChartTooltipContent = _chunkHO5BFEZOcjs.d;
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";var _chunkFVR3LJWMcjs = require('../chunk-FVR3LJWM.cjs');require('../chunk-DD6AVCRH.cjs');exports.ChartContainer = _chunkFVR3LJWMcjs.a; exports.ChartLegend = _chunkFVR3LJWMcjs.e; exports.ChartLegendContent = _chunkFVR3LJWMcjs.f; exports.ChartStyle = _chunkFVR3LJWMcjs.b; exports.ChartTooltip = _chunkFVR3LJWMcjs.c; exports.ChartTooltipContent = _chunkFVR3LJWMcjs.d;
2
2
  //# sourceMappingURL=chart.cjs.map
@@ -7,17 +7,21 @@ declare const THEMES: {
7
7
  readonly dark: ".dark";
8
8
  };
9
9
  type Theme = keyof typeof THEMES;
10
+ interface IconLabelConfig {
11
+ icon?: ComponentType;
12
+ label?: ReactNode | undefined;
13
+ }
14
+ interface ColorConfig {
15
+ color?: string;
16
+ theme?: never;
17
+ }
18
+ interface ThemeConfig {
19
+ theme: Record<Theme, string>;
20
+ color?: never;
21
+ }
22
+ type ChartConfigItem = IconLabelConfig & (ColorConfig | ThemeConfig);
10
23
  type ChartConfig = {
11
- [k in string]: {
12
- icon?: ComponentType;
13
- label?: ReactNode;
14
- } & ({
15
- color?: string;
16
- theme?: never;
17
- } | {
18
- theme: Record<Theme, string>;
19
- color?: never;
20
- });
24
+ [k in string]: ChartConfigItem | undefined;
21
25
  };
22
26
  interface ChartContainerProps extends ComponentProps<'div'> {
23
27
  children: ComponentProps<typeof RechartsPrimitive.ResponsiveContainer>['children'];
@@ -7,17 +7,21 @@ declare const THEMES: {
7
7
  readonly dark: ".dark";
8
8
  };
9
9
  type Theme = keyof typeof THEMES;
10
+ interface IconLabelConfig {
11
+ icon?: ComponentType;
12
+ label?: ReactNode | undefined;
13
+ }
14
+ interface ColorConfig {
15
+ color?: string;
16
+ theme?: never;
17
+ }
18
+ interface ThemeConfig {
19
+ theme: Record<Theme, string>;
20
+ color?: never;
21
+ }
22
+ type ChartConfigItem = IconLabelConfig & (ColorConfig | ThemeConfig);
10
23
  type ChartConfig = {
11
- [k in string]: {
12
- icon?: ComponentType;
13
- label?: ReactNode;
14
- } & ({
15
- color?: string;
16
- theme?: never;
17
- } | {
18
- theme: Record<Theme, string>;
19
- color?: never;
20
- });
24
+ [k in string]: ChartConfigItem | undefined;
21
25
  };
22
26
  interface ChartContainerProps extends ComponentProps<'div'> {
23
27
  children: ComponentProps<typeof RechartsPrimitive.ResponsiveContainer>['children'];
@@ -1,2 +1,2 @@
1
- "use client";import{a,b,c,d,e,f}from"../chunk-WNXJ2WHS.js";import"../chunk-VPYH6JWS.js";export{a as ChartContainer,e as ChartLegend,f as ChartLegendContent,b as ChartStyle,c as ChartTooltip,d as ChartTooltipContent};
1
+ "use client";import{a,b,c,d,e,f}from"../chunk-VZSYA6XE.js";import"../chunk-VPYH6JWS.js";export{a as ChartContainer,e as ChartLegend,f as ChartLegendContent,b as ChartStyle,c as ChartTooltip,d as ChartTooltipContent};
2
2
  //# sourceMappingURL=chart.js.map
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkNGEZQP54cjs = require('../chunk-NGEZQP54.cjs');require('../chunk-DD6AVCRH.cjs');exports.Tabs = _chunkNGEZQP54cjs.a; exports.TabsContent = _chunkNGEZQP54cjs.d; exports.TabsList = _chunkNGEZQP54cjs.b; exports.TabsTrigger = _chunkNGEZQP54cjs.c;
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkTQEAAFPMcjs = require('../chunk-TQEAAFPM.cjs');require('../chunk-DD6AVCRH.cjs');exports.Tabs = _chunkTQEAAFPMcjs.a; exports.TabsContent = _chunkTQEAAFPMcjs.d; exports.TabsList = _chunkTQEAAFPMcjs.b; exports.TabsTrigger = _chunkTQEAAFPMcjs.c;
2
2
  //# sourceMappingURL=tabs.cjs.map
@@ -1,2 +1,2 @@
1
- import{a,b,c,d}from"../chunk-OPRULC2F.js";import"../chunk-VPYH6JWS.js";export{a as Tabs,d as TabsContent,b as TabsList,c as TabsTrigger};
1
+ import{a,b,c,d}from"../chunk-5J3MQRCG.js";import"../chunk-VPYH6JWS.js";export{a as Tabs,d as TabsContent,b as TabsList,c as TabsTrigger};
2
2
  //# sourceMappingURL=tabs.js.map
package/dist/index.cjs CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkXWRE723Zcjs = require('./chunk-XWRE723Z.cjs');var _chunk5DADNTMKcjs = require('./chunk-5DADNTMK.cjs');require('./chunk-L5RKZ4EK.cjs');var _chunkNOCY2CX5cjs = require('./chunk-NOCY2CX5.cjs');var _chunkE5WTRZE4cjs = require('./chunk-E5WTRZE4.cjs');var _chunkSSYLDUQ5cjs = require('./chunk-SSYLDUQ5.cjs');var _chunkHHX6KYEHcjs = require('./chunk-HHX6KYEH.cjs');var _chunkAI3AM6TDcjs = require('./chunk-AI3AM6TD.cjs');var _chunkN2RQKUCGcjs = require('./chunk-N2RQKUCG.cjs');var _chunkJOGGNWWAcjs = require('./chunk-JOGGNWWA.cjs');var _chunkSRRXHGGIcjs = require('./chunk-SRRXHGGI.cjs');var _chunkNGEZQP54cjs = require('./chunk-NGEZQP54.cjs');var _chunkJSZUH4EWcjs = require('./chunk-JSZUH4EW.cjs');var _chunkZ7U5IONCcjs = require('./chunk-Z7U5IONC.cjs');var _chunk5XLLR5OUcjs = require('./chunk-5XLLR5OU.cjs');var _chunkE2QRPDUIcjs = require('./chunk-E2QRPDUI.cjs');var _chunkQ62VKCH2cjs = require('./chunk-Q62VKCH2.cjs');var _chunkOKI5PENPcjs = require('./chunk-OKI5PENP.cjs');var _chunkD3EC6HWNcjs = require('./chunk-D3EC6HWN.cjs');var _chunkDIYHARQUcjs = require('./chunk-DIYHARQU.cjs');var _chunk5XCNTI3Xcjs = require('./chunk-5XCNTI3X.cjs');var _chunkYQ2OTPJ3cjs = require('./chunk-YQ2OTPJ3.cjs');var _chunk2U4H7AXCcjs = require('./chunk-2U4H7AXC.cjs');var _chunkBXDCIP66cjs = require('./chunk-BXDCIP66.cjs');var _chunkDH7PAQN6cjs = require('./chunk-DH7PAQN6.cjs');var _chunkMGESGIS4cjs = require('./chunk-MGESGIS4.cjs');var _chunkWUIFKZNRcjs = require('./chunk-WUIFKZNR.cjs');var _chunkPEQRNG2Rcjs = require('./chunk-PEQRNG2R.cjs');var _chunkOOEZEXWKcjs = require('./chunk-OOEZEXWK.cjs');var _chunkKASTA74Mcjs = require('./chunk-KASTA74M.cjs');var _chunkOODSJGVYcjs = require('./chunk-OODSJGVY.cjs');var _chunk4PL3DAT2cjs = require('./chunk-4PL3DAT2.cjs');var _chunkMHH6QOREcjs = require('./chunk-MHH6QORE.cjs');var _chunkR5235IUCcjs = require('./chunk-R5235IUC.cjs');var _chunkBAOFKRE7cjs = require('./chunk-BAOFKRE7.cjs');var _chunkSDGFNHJPcjs = require('./chunk-SDGFNHJP.cjs');var _chunk7XV37NAWcjs = require('./chunk-7XV37NAW.cjs');require('./chunk-2RAQYLLP.cjs');var _chunk2OIYIMMKcjs = require('./chunk-2OIYIMMK.cjs');var _chunkGWSYICGKcjs = require('./chunk-GWSYICGK.cjs');var _chunkF35POBWNcjs = require('./chunk-F35POBWN.cjs');var _chunkEIJDA5S5cjs = require('./chunk-EIJDA5S5.cjs');var _chunkKUKRY4KGcjs = require('./chunk-KUKRY4KG.cjs');var _chunkRXWJHQ3Jcjs = require('./chunk-RXWJHQ3J.cjs');var _chunkVFOMCFSGcjs = require('./chunk-VFOMCFSG.cjs');var _chunkGUOQM6BLcjs = require('./chunk-GUOQM6BL.cjs');var _chunkJF2OKUYDcjs = require('./chunk-JF2OKUYD.cjs');var _chunkQ5E3BLJNcjs = require('./chunk-Q5E3BLJN.cjs');var _chunkIPRXHJQ5cjs = require('./chunk-IPRXHJQ5.cjs');var _chunkB5V32KRWcjs = require('./chunk-B5V32KRW.cjs');var _chunkW7777KAFcjs = require('./chunk-W7777KAF.cjs');var _chunkVBE6D4FZcjs = require('./chunk-VBE6D4FZ.cjs');var _chunkPYKB3C2Fcjs = require('./chunk-PYKB3C2F.cjs');var _chunkEEDKRHHZcjs = require('./chunk-EEDKRHHZ.cjs');var _chunkYORY32TXcjs = require('./chunk-YORY32TX.cjs');var _chunkKZJA37DUcjs = require('./chunk-KZJA37DU.cjs');var _chunkI6LNZ6KPcjs = require('./chunk-I6LNZ6KP.cjs');var _chunkOUWUINGXcjs = require('./chunk-OUWUINGX.cjs');var _chunkE4CMBFLCcjs = require('./chunk-E4CMBFLC.cjs');var _chunkDQBQF25Fcjs = require('./chunk-DQBQF25F.cjs');var _chunkFINPFQTZcjs = require('./chunk-FINPFQTZ.cjs');var _chunk7R4FFNVEcjs = require('./chunk-7R4FFNVE.cjs');var _chunkHO5BFEZOcjs = require('./chunk-HO5BFEZO.cjs');var _chunkUIVPC5TQcjs = require('./chunk-UIVPC5TQ.cjs');var _chunkRAOQ5OMDcjs = require('./chunk-RAOQ5OMD.cjs');var _chunkYB2W76VXcjs = require('./chunk-YB2W76VX.cjs');var _chunkKF7Y7B3Gcjs = require('./chunk-KF7Y7B3G.cjs');var _chunkFWLIZUVScjs = require('./chunk-FWLIZUVS.cjs');var _chunkDSOT5AYEcjs = require('./chunk-DSOT5AYE.cjs');var _chunkCXIRQHL6cjs = require('./chunk-CXIRQHL6.cjs');var _chunkDD6AVCRHcjs = require('./chunk-DD6AVCRH.cjs');var _chunkMVX4CCXYcjs = require('./chunk-MVX4CCXY.cjs');var _chunkBCWKI4D5cjs = require('./chunk-BCWKI4D5.cjs');exports.Accordion = _chunkRAOQ5OMDcjs.a; exports.AccordionContent = _chunkRAOQ5OMDcjs.e; exports.AccordionIcon = _chunkRAOQ5OMDcjs.c; exports.AccordionItem = _chunkRAOQ5OMDcjs.b; exports.AccordionTrigger = _chunkRAOQ5OMDcjs.d; exports.Alert = _chunkFWLIZUVScjs.a; exports.AlertDescription = _chunkFWLIZUVScjs.c; exports.AlertDialog = _chunkYB2W76VXcjs.a; exports.AlertDialogAction = _chunkYB2W76VXcjs.i; exports.AlertDialogBody = _chunkYB2W76VXcjs.e; exports.AlertDialogCancel = _chunkYB2W76VXcjs.j; exports.AlertDialogContent = _chunkYB2W76VXcjs.c; exports.AlertDialogDescription = _chunkYB2W76VXcjs.h; exports.AlertDialogFooter = _chunkYB2W76VXcjs.f; exports.AlertDialogHeader = _chunkYB2W76VXcjs.d; exports.AlertDialogTitle = _chunkYB2W76VXcjs.g; exports.AlertDialogTrigger = _chunkYB2W76VXcjs.b; exports.AlertTitle = _chunkFWLIZUVScjs.b; exports.AspectRatio = _chunkDSOT5AYEcjs.a; exports.Avatar = _chunkCXIRQHL6cjs.a; exports.AvatarFallback = _chunkCXIRQHL6cjs.c; exports.AvatarImage = _chunkCXIRQHL6cjs.b; exports.Badge = _chunkMVX4CCXYcjs.a; exports.Blockquote = _chunkBCWKI4D5cjs.a; exports.Box = _chunkKZJA37DUcjs.a; exports.Breadcrumb = _chunkI6LNZ6KPcjs.a; exports.BreadcrumbEllipsis = _chunkI6LNZ6KPcjs.g; exports.BreadcrumbItem = _chunkI6LNZ6KPcjs.c; exports.BreadcrumbLink = _chunkI6LNZ6KPcjs.d; exports.BreadcrumbList = _chunkI6LNZ6KPcjs.b; exports.BreadcrumbPage = _chunkI6LNZ6KPcjs.e; exports.BreadcrumbSeparator = _chunkI6LNZ6KPcjs.f; exports.Button = _chunkFINPFQTZcjs.a; exports.Calendar = _chunkOUWUINGXcjs.a; exports.CalendarLabel = _chunkOUWUINGXcjs.c; exports.CalendarRangeLabel = _chunkOUWUINGXcjs.b; exports.Card = _chunkE4CMBFLCcjs.a; exports.CardContent = _chunkE4CMBFLCcjs.e; exports.CardDescription = _chunkE4CMBFLCcjs.d; exports.CardFooter = _chunkE4CMBFLCcjs.f; exports.CardHeader = _chunkE4CMBFLCcjs.b; exports.CardTitle = _chunkE4CMBFLCcjs.c; exports.Carousel = _chunkDQBQF25Fcjs.b; exports.CarouselContent = _chunkDQBQF25Fcjs.c; exports.CarouselItem = _chunkDQBQF25Fcjs.d; exports.CarouselNext = _chunkDQBQF25Fcjs.f; exports.CarouselPrevious = _chunkDQBQF25Fcjs.e; exports.ChartContainer = _chunkHO5BFEZOcjs.a; exports.ChartLegend = _chunkHO5BFEZOcjs.e; exports.ChartLegendContent = _chunkHO5BFEZOcjs.f; exports.ChartStyle = _chunkHO5BFEZOcjs.b; exports.ChartTooltip = _chunkHO5BFEZOcjs.c; exports.ChartTooltipContent = _chunkHO5BFEZOcjs.d; exports.Checkbox = _chunkGUOQM6BLcjs.a; exports.CheckboxCards = _chunkUIVPC5TQcjs.a; exports.CheckboxCardsItem = _chunkUIVPC5TQcjs.b; exports.CheckboxGroup = _chunkVFOMCFSGcjs.a; exports.CheckboxGroupItem = _chunkVFOMCFSGcjs.b; exports.Code = _chunkJF2OKUYDcjs.a; exports.Collapsible = _chunkQ5E3BLJNcjs.a; exports.CollapsibleContent = _chunkQ5E3BLJNcjs.c; exports.CollapsibleTrigger = _chunkQ5E3BLJNcjs.b; exports.Command = _chunkIPRXHJQ5cjs.a; exports.CommandDialog = _chunkIPRXHJQ5cjs.b; exports.CommandEmpty = _chunkIPRXHJQ5cjs.e; exports.CommandGroup = _chunkIPRXHJQ5cjs.f; exports.CommandInput = _chunkIPRXHJQ5cjs.c; exports.CommandItem = _chunkIPRXHJQ5cjs.h; exports.CommandList = _chunkIPRXHJQ5cjs.d; exports.CommandLoading = _chunkIPRXHJQ5cjs.i; exports.CommandSeparator = _chunkIPRXHJQ5cjs.g; exports.CommandShortcut = _chunkIPRXHJQ5cjs.j; exports.Container = _chunkW7777KAFcjs.a; exports.ContextMenu = _chunkVBE6D4FZcjs.a; exports.ContextMenuArrow = _chunkVBE6D4FZcjs.o; exports.ContextMenuCheckboxItem = _chunkVBE6D4FZcjs.j; exports.ContextMenuContent = _chunkVBE6D4FZcjs.h; exports.ContextMenuGroup = _chunkVBE6D4FZcjs.c; exports.ContextMenuItem = _chunkVBE6D4FZcjs.i; exports.ContextMenuLabel = _chunkVBE6D4FZcjs.l; exports.ContextMenuRadioGroup = _chunkVBE6D4FZcjs.e; exports.ContextMenuRadioItem = _chunkVBE6D4FZcjs.k; exports.ContextMenuSeparator = _chunkVBE6D4FZcjs.m; exports.ContextMenuShortcut = _chunkVBE6D4FZcjs.n; exports.ContextMenuSub = _chunkVBE6D4FZcjs.d; exports.ContextMenuSubContent = _chunkVBE6D4FZcjs.g; exports.ContextMenuSubTrigger = _chunkVBE6D4FZcjs.f; exports.ContextMenuTrigger = _chunkVBE6D4FZcjs.b; exports.DataTableColumnHeader = _chunkPYKB3C2Fcjs.c; exports.DataTablePagination = _chunkPYKB3C2Fcjs.b; exports.DataTableViewOptions = _chunkPYKB3C2Fcjs.a; exports.Dialog = _chunkB5V32KRWcjs.a; exports.DialogBody = _chunkB5V32KRWcjs.e; exports.DialogClose = _chunkB5V32KRWcjs.i; exports.DialogContent = _chunkB5V32KRWcjs.c; exports.DialogDescription = _chunkB5V32KRWcjs.h; exports.DialogFooter = _chunkB5V32KRWcjs.f; exports.DialogHeader = _chunkB5V32KRWcjs.d; exports.DialogTitle = _chunkB5V32KRWcjs.g; exports.DialogTrigger = _chunkB5V32KRWcjs.b; exports.Drawer = _chunk2OIYIMMKcjs.a; exports.DrawerBody = _chunk2OIYIMMKcjs.e; exports.DrawerClose = _chunk2OIYIMMKcjs.i; exports.DrawerContent = _chunk2OIYIMMKcjs.c; exports.DrawerDescription = _chunk2OIYIMMKcjs.h; exports.DrawerFooter = _chunk2OIYIMMKcjs.f; exports.DrawerHeader = _chunk2OIYIMMKcjs.d; exports.DrawerTitle = _chunk2OIYIMMKcjs.g; exports.DrawerTrigger = _chunk2OIYIMMKcjs.b; exports.DropdownMenu = _chunkYORY32TXcjs.a; exports.DropdownMenuArrow = _chunkYORY32TXcjs.o; exports.DropdownMenuCheckboxItem = _chunkYORY32TXcjs.j; exports.DropdownMenuContent = _chunkYORY32TXcjs.h; exports.DropdownMenuGroup = _chunkYORY32TXcjs.c; exports.DropdownMenuItem = _chunkYORY32TXcjs.i; exports.DropdownMenuLabel = _chunkYORY32TXcjs.l; exports.DropdownMenuRadioGroup = _chunkYORY32TXcjs.e; exports.DropdownMenuRadioItem = _chunkYORY32TXcjs.k; exports.DropdownMenuSeparator = _chunkYORY32TXcjs.m; exports.DropdownMenuShortcut = _chunkYORY32TXcjs.n; exports.DropdownMenuSub = _chunkYORY32TXcjs.d; exports.DropdownMenuSubContent = _chunkYORY32TXcjs.g; exports.DropdownMenuSubTrigger = _chunkYORY32TXcjs.f; exports.DropdownMenuTrigger = _chunkYORY32TXcjs.b; exports.Em = _chunkGWSYICGKcjs.a; exports.Form = _chunkF35POBWNcjs.a; exports.FormControl = _chunkF35POBWNcjs.f; exports.FormDescription = _chunkF35POBWNcjs.g; exports.FormField = _chunkF35POBWNcjs.c; exports.FormItem = _chunkF35POBWNcjs.d; exports.FormLabel = _chunkF35POBWNcjs.e; exports.FormMessage = _chunkF35POBWNcjs.h; exports.Heading = _chunkKUKRY4KGcjs.a; exports.HoverCard = _chunkRXWJHQ3Jcjs.a; exports.HoverCardArrow = _chunkRXWJHQ3Jcjs.d; exports.HoverCardContent = _chunkRXWJHQ3Jcjs.c; exports.HoverCardTrigger = _chunkRXWJHQ3Jcjs.b; exports.InputOTP = _chunkKASTA74Mcjs.d; exports.InputOTPGroup = _chunkKASTA74Mcjs.e; exports.InputOTPSeparator = _chunkKASTA74Mcjs.g; exports.InputOTPSlot = _chunkKASTA74Mcjs.f; exports.Kbd = _chunkOODSJGVYcjs.a; exports.Label = _chunkEIJDA5S5cjs.a; exports.Menubar = _chunk4PL3DAT2cjs.e; exports.MenubarArrow = _chunk4PL3DAT2cjs.p; exports.MenubarCheckboxItem = _chunk4PL3DAT2cjs.k; exports.MenubarContent = _chunk4PL3DAT2cjs.i; exports.MenubarGroup = _chunk4PL3DAT2cjs.b; exports.MenubarItem = _chunk4PL3DAT2cjs.j; exports.MenubarLabel = _chunk4PL3DAT2cjs.m; exports.MenubarMenu = _chunk4PL3DAT2cjs.a; exports.MenubarRadioGroup = _chunk4PL3DAT2cjs.d; exports.MenubarRadioItem = _chunk4PL3DAT2cjs.l; exports.MenubarSeparator = _chunk4PL3DAT2cjs.n; exports.MenubarShortcut = _chunk4PL3DAT2cjs.o; exports.MenubarSub = _chunk4PL3DAT2cjs.c; exports.MenubarSubContent = _chunk4PL3DAT2cjs.h; exports.MenubarSubTrigger = _chunk4PL3DAT2cjs.g; exports.MenubarTrigger = _chunk4PL3DAT2cjs.f; exports.NavigationMenu = _chunkMHH6QOREcjs.a; exports.NavigationMenuContent = _chunkMHH6QOREcjs.e; exports.NavigationMenuItem = _chunkMHH6QOREcjs.c; exports.NavigationMenuLink = _chunkMHH6QOREcjs.f; exports.NavigationMenuList = _chunkMHH6QOREcjs.b; exports.NavigationMenuTrigger = _chunkMHH6QOREcjs.d; exports.NumberInput = _chunkR5235IUCcjs.a; exports.Pagination = _chunkBAOFKRE7cjs.a; exports.PaginationContent = _chunkBAOFKRE7cjs.b; exports.PaginationEllipsis = _chunkBAOFKRE7cjs.g; exports.PaginationItem = _chunkBAOFKRE7cjs.c; exports.PaginationLink = _chunkBAOFKRE7cjs.d; exports.PaginationNext = _chunkBAOFKRE7cjs.f; exports.PaginationPrevious = _chunkBAOFKRE7cjs.e; exports.PasswordInput = _chunkSDGFNHJPcjs.a; exports.Popover = _chunkYQ2OTPJ3cjs.a; exports.PopoverAnchor = _chunkYQ2OTPJ3cjs.c; exports.PopoverArrow = _chunkYQ2OTPJ3cjs.e; exports.PopoverContent = _chunkYQ2OTPJ3cjs.d; exports.PopoverTrigger = _chunkYQ2OTPJ3cjs.b; exports.Pre = _chunk2U4H7AXCcjs.a; exports.Progress = _chunkBXDCIP66cjs.a; exports.Quote = _chunkDH7PAQN6cjs.a; exports.REGEXP_ONLY_CHARS = _chunkKASTA74Mcjs.a; exports.REGEXP_ONLY_DIGITS = _chunkKASTA74Mcjs.b; exports.REGEXP_ONLY_DIGITS_AND_CHARS = _chunkKASTA74Mcjs.c; exports.Radio = _chunkPEQRNG2Rcjs.a; exports.RadioCards = _chunkMGESGIS4cjs.a; exports.RadioCardsItem = _chunkMGESGIS4cjs.b; exports.RadioGroup = _chunkWUIFKZNRcjs.a; exports.RadioGroupItem = _chunkWUIFKZNRcjs.b; exports.ResizableHandle = _chunkOOEZEXWKcjs.c; exports.ResizablePanel = _chunkOOEZEXWKcjs.b; exports.ResizablePanelGroup = _chunkOOEZEXWKcjs.a; exports.ScrollArea = _chunkJSZUH4EWcjs.a; exports.ScrollAreaScrollbar = _chunkJSZUH4EWcjs.b; exports.SearchInput = _chunkZ7U5IONCcjs.a; exports.Section = _chunk5XLLR5OUcjs.a; exports.Select = _chunkEEDKRHHZcjs.a; exports.SelectContent = _chunkEEDKRHHZcjs.g; exports.SelectGroup = _chunkEEDKRHHZcjs.b; exports.SelectItem = _chunkEEDKRHHZcjs.i; exports.SelectLabel = _chunkEEDKRHHZcjs.h; exports.SelectScrollDownButton = _chunkEEDKRHHZcjs.f; exports.SelectScrollUpButton = _chunkEEDKRHHZcjs.e; exports.SelectSeparator = _chunkEEDKRHHZcjs.j; exports.SelectTrigger = _chunkEEDKRHHZcjs.d; exports.SelectValue = _chunkEEDKRHHZcjs.c; exports.Separator = _chunkD3EC6HWNcjs.a; exports.SeparatorItem = _chunkD3EC6HWNcjs.b; exports.Sheet = _chunkDIYHARQUcjs.a; exports.SheetBody = _chunkDIYHARQUcjs.e; exports.SheetClose = _chunkDIYHARQUcjs.i; exports.SheetContent = _chunkDIYHARQUcjs.c; exports.SheetDescription = _chunkDIYHARQUcjs.h; exports.SheetFooter = _chunkDIYHARQUcjs.f; exports.SheetHeader = _chunkDIYHARQUcjs.d; exports.SheetTitle = _chunkDIYHARQUcjs.g; exports.SheetTrigger = _chunkDIYHARQUcjs.b; exports.Sidebar = _chunkE2QRPDUIcjs.c; exports.SidebarContent = _chunkE2QRPDUIcjs.k; exports.SidebarFooter = _chunkE2QRPDUIcjs.i; exports.SidebarGroup = _chunkE2QRPDUIcjs.l; exports.SidebarGroupAction = _chunkE2QRPDUIcjs.n; exports.SidebarGroupContent = _chunkE2QRPDUIcjs.o; exports.SidebarGroupLabel = _chunkE2QRPDUIcjs.m; exports.SidebarHeader = _chunkE2QRPDUIcjs.h; exports.SidebarInput = _chunkE2QRPDUIcjs.g; exports.SidebarInset = _chunkE2QRPDUIcjs.f; exports.SidebarMenu = _chunkE2QRPDUIcjs.p; exports.SidebarMenuAction = _chunkE2QRPDUIcjs.s; exports.SidebarMenuBadge = _chunkE2QRPDUIcjs.t; exports.SidebarMenuButton = _chunkE2QRPDUIcjs.r; exports.SidebarMenuItem = _chunkE2QRPDUIcjs.q; exports.SidebarMenuSkeleton = _chunkE2QRPDUIcjs.u; exports.SidebarMenuSub = _chunkE2QRPDUIcjs.v; exports.SidebarMenuSubButton = _chunkE2QRPDUIcjs.x; exports.SidebarMenuSubItem = _chunkE2QRPDUIcjs.w; exports.SidebarProvider = _chunkE2QRPDUIcjs.b; exports.SidebarRail = _chunkE2QRPDUIcjs.e; exports.SidebarSeparator = _chunkE2QRPDUIcjs.j; exports.SidebarTrigger = _chunkE2QRPDUIcjs.d; exports.Skeleton = _chunk5XCNTI3Xcjs.a; exports.Slider = _chunkHHX6KYEHcjs.a; exports.Spinner = _chunk7R4FFNVEcjs.a; exports.Strong = _chunkN2RQKUCGcjs.a; exports.Switch = _chunkJOGGNWWAcjs.a; exports.Table = _chunkSRRXHGGIcjs.a; exports.TableBody = _chunkSRRXHGGIcjs.c; exports.TableCaption = _chunkSRRXHGGIcjs.h; exports.TableCell = _chunkSRRXHGGIcjs.g; exports.TableFooter = _chunkSRRXHGGIcjs.d; exports.TableHead = _chunkSRRXHGGIcjs.f; exports.TableHeader = _chunkSRRXHGGIcjs.b; exports.TableRow = _chunkSRRXHGGIcjs.e; exports.Tabs = _chunkNGEZQP54cjs.a; exports.TabsContent = _chunkNGEZQP54cjs.d; exports.TabsList = _chunkNGEZQP54cjs.b; exports.TabsTrigger = _chunkNGEZQP54cjs.c; exports.Text = _chunkXWRE723Zcjs.a; exports.TextInput = _chunkOKI5PENPcjs.a; exports.Textarea = _chunk5DADNTMKcjs.a; exports.Toaster = _chunkAI3AM6TDcjs.b; exports.Toggle = _chunkE5WTRZE4cjs.a; exports.ToggleGroup = _chunkNOCY2CX5cjs.a; exports.ToggleGroupItem = _chunkNOCY2CX5cjs.b; exports.Tooltip = _chunkQ62VKCH2cjs.b; exports.TooltipArrow = _chunkQ62VKCH2cjs.e; exports.TooltipContent = _chunkQ62VKCH2cjs.d; exports.TooltipProvider = _chunkQ62VKCH2cjs.a; exports.TooltipTrigger = _chunkQ62VKCH2cjs.c; exports.buttonVariants = _chunkKF7Y7B3Gcjs.a; exports.cn = _chunkDD6AVCRHcjs.a; exports.createCarouselScope = _chunkDQBQF25Fcjs.a; exports.createFormFieldScope = _chunkF35POBWNcjs.b; exports.inputVariants = _chunk7XV37NAWcjs.a; exports.toast = _chunkAI3AM6TDcjs.a; exports.toggleVariants = _chunkSSYLDUQ5cjs.a; exports.useSidebar = _chunkE2QRPDUIcjs.a;
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkXWRE723Zcjs = require('./chunk-XWRE723Z.cjs');var _chunk5DADNTMKcjs = require('./chunk-5DADNTMK.cjs');require('./chunk-L5RKZ4EK.cjs');var _chunkNOCY2CX5cjs = require('./chunk-NOCY2CX5.cjs');var _chunkE5WTRZE4cjs = require('./chunk-E5WTRZE4.cjs');var _chunkSSYLDUQ5cjs = require('./chunk-SSYLDUQ5.cjs');var _chunkHHX6KYEHcjs = require('./chunk-HHX6KYEH.cjs');var _chunkAI3AM6TDcjs = require('./chunk-AI3AM6TD.cjs');var _chunkN2RQKUCGcjs = require('./chunk-N2RQKUCG.cjs');var _chunkJOGGNWWAcjs = require('./chunk-JOGGNWWA.cjs');var _chunkSRRXHGGIcjs = require('./chunk-SRRXHGGI.cjs');var _chunkTQEAAFPMcjs = require('./chunk-TQEAAFPM.cjs');var _chunkJSZUH4EWcjs = require('./chunk-JSZUH4EW.cjs');var _chunkZ7U5IONCcjs = require('./chunk-Z7U5IONC.cjs');var _chunk5XLLR5OUcjs = require('./chunk-5XLLR5OU.cjs');var _chunkE2QRPDUIcjs = require('./chunk-E2QRPDUI.cjs');var _chunkQ62VKCH2cjs = require('./chunk-Q62VKCH2.cjs');var _chunkOKI5PENPcjs = require('./chunk-OKI5PENP.cjs');var _chunkD3EC6HWNcjs = require('./chunk-D3EC6HWN.cjs');var _chunkDIYHARQUcjs = require('./chunk-DIYHARQU.cjs');var _chunk5XCNTI3Xcjs = require('./chunk-5XCNTI3X.cjs');var _chunkYQ2OTPJ3cjs = require('./chunk-YQ2OTPJ3.cjs');var _chunk2U4H7AXCcjs = require('./chunk-2U4H7AXC.cjs');var _chunkBXDCIP66cjs = require('./chunk-BXDCIP66.cjs');var _chunkDH7PAQN6cjs = require('./chunk-DH7PAQN6.cjs');var _chunkMGESGIS4cjs = require('./chunk-MGESGIS4.cjs');var _chunkWUIFKZNRcjs = require('./chunk-WUIFKZNR.cjs');var _chunkPEQRNG2Rcjs = require('./chunk-PEQRNG2R.cjs');var _chunkOOEZEXWKcjs = require('./chunk-OOEZEXWK.cjs');var _chunkKASTA74Mcjs = require('./chunk-KASTA74M.cjs');var _chunkOODSJGVYcjs = require('./chunk-OODSJGVY.cjs');var _chunk4PL3DAT2cjs = require('./chunk-4PL3DAT2.cjs');var _chunkMHH6QOREcjs = require('./chunk-MHH6QORE.cjs');var _chunkR5235IUCcjs = require('./chunk-R5235IUC.cjs');var _chunkBAOFKRE7cjs = require('./chunk-BAOFKRE7.cjs');var _chunkSDGFNHJPcjs = require('./chunk-SDGFNHJP.cjs');var _chunk7XV37NAWcjs = require('./chunk-7XV37NAW.cjs');require('./chunk-2RAQYLLP.cjs');var _chunk2OIYIMMKcjs = require('./chunk-2OIYIMMK.cjs');var _chunkGWSYICGKcjs = require('./chunk-GWSYICGK.cjs');var _chunkF35POBWNcjs = require('./chunk-F35POBWN.cjs');var _chunkEIJDA5S5cjs = require('./chunk-EIJDA5S5.cjs');var _chunkKUKRY4KGcjs = require('./chunk-KUKRY4KG.cjs');var _chunkRXWJHQ3Jcjs = require('./chunk-RXWJHQ3J.cjs');var _chunkVFOMCFSGcjs = require('./chunk-VFOMCFSG.cjs');var _chunkGUOQM6BLcjs = require('./chunk-GUOQM6BL.cjs');var _chunkJF2OKUYDcjs = require('./chunk-JF2OKUYD.cjs');var _chunkQ5E3BLJNcjs = require('./chunk-Q5E3BLJN.cjs');var _chunkIPRXHJQ5cjs = require('./chunk-IPRXHJQ5.cjs');var _chunkB5V32KRWcjs = require('./chunk-B5V32KRW.cjs');var _chunkW7777KAFcjs = require('./chunk-W7777KAF.cjs');var _chunkVBE6D4FZcjs = require('./chunk-VBE6D4FZ.cjs');var _chunkPYKB3C2Fcjs = require('./chunk-PYKB3C2F.cjs');var _chunkEEDKRHHZcjs = require('./chunk-EEDKRHHZ.cjs');var _chunkYORY32TXcjs = require('./chunk-YORY32TX.cjs');var _chunkKZJA37DUcjs = require('./chunk-KZJA37DU.cjs');var _chunkI6LNZ6KPcjs = require('./chunk-I6LNZ6KP.cjs');var _chunkOUWUINGXcjs = require('./chunk-OUWUINGX.cjs');var _chunkE4CMBFLCcjs = require('./chunk-E4CMBFLC.cjs');var _chunkDQBQF25Fcjs = require('./chunk-DQBQF25F.cjs');var _chunkFINPFQTZcjs = require('./chunk-FINPFQTZ.cjs');var _chunk7R4FFNVEcjs = require('./chunk-7R4FFNVE.cjs');var _chunkFVR3LJWMcjs = require('./chunk-FVR3LJWM.cjs');var _chunkUIVPC5TQcjs = require('./chunk-UIVPC5TQ.cjs');var _chunkRAOQ5OMDcjs = require('./chunk-RAOQ5OMD.cjs');var _chunkYB2W76VXcjs = require('./chunk-YB2W76VX.cjs');var _chunkKF7Y7B3Gcjs = require('./chunk-KF7Y7B3G.cjs');var _chunkFWLIZUVScjs = require('./chunk-FWLIZUVS.cjs');var _chunkDSOT5AYEcjs = require('./chunk-DSOT5AYE.cjs');var _chunkCXIRQHL6cjs = require('./chunk-CXIRQHL6.cjs');var _chunkDD6AVCRHcjs = require('./chunk-DD6AVCRH.cjs');var _chunkMVX4CCXYcjs = require('./chunk-MVX4CCXY.cjs');var _chunkBCWKI4D5cjs = require('./chunk-BCWKI4D5.cjs');exports.Accordion = _chunkRAOQ5OMDcjs.a; exports.AccordionContent = _chunkRAOQ5OMDcjs.e; exports.AccordionIcon = _chunkRAOQ5OMDcjs.c; exports.AccordionItem = _chunkRAOQ5OMDcjs.b; exports.AccordionTrigger = _chunkRAOQ5OMDcjs.d; exports.Alert = _chunkFWLIZUVScjs.a; exports.AlertDescription = _chunkFWLIZUVScjs.c; exports.AlertDialog = _chunkYB2W76VXcjs.a; exports.AlertDialogAction = _chunkYB2W76VXcjs.i; exports.AlertDialogBody = _chunkYB2W76VXcjs.e; exports.AlertDialogCancel = _chunkYB2W76VXcjs.j; exports.AlertDialogContent = _chunkYB2W76VXcjs.c; exports.AlertDialogDescription = _chunkYB2W76VXcjs.h; exports.AlertDialogFooter = _chunkYB2W76VXcjs.f; exports.AlertDialogHeader = _chunkYB2W76VXcjs.d; exports.AlertDialogTitle = _chunkYB2W76VXcjs.g; exports.AlertDialogTrigger = _chunkYB2W76VXcjs.b; exports.AlertTitle = _chunkFWLIZUVScjs.b; exports.AspectRatio = _chunkDSOT5AYEcjs.a; exports.Avatar = _chunkCXIRQHL6cjs.a; exports.AvatarFallback = _chunkCXIRQHL6cjs.c; exports.AvatarImage = _chunkCXIRQHL6cjs.b; exports.Badge = _chunkMVX4CCXYcjs.a; exports.Blockquote = _chunkBCWKI4D5cjs.a; exports.Box = _chunkKZJA37DUcjs.a; exports.Breadcrumb = _chunkI6LNZ6KPcjs.a; exports.BreadcrumbEllipsis = _chunkI6LNZ6KPcjs.g; exports.BreadcrumbItem = _chunkI6LNZ6KPcjs.c; exports.BreadcrumbLink = _chunkI6LNZ6KPcjs.d; exports.BreadcrumbList = _chunkI6LNZ6KPcjs.b; exports.BreadcrumbPage = _chunkI6LNZ6KPcjs.e; exports.BreadcrumbSeparator = _chunkI6LNZ6KPcjs.f; exports.Button = _chunkFINPFQTZcjs.a; exports.Calendar = _chunkOUWUINGXcjs.a; exports.CalendarLabel = _chunkOUWUINGXcjs.c; exports.CalendarRangeLabel = _chunkOUWUINGXcjs.b; exports.Card = _chunkE4CMBFLCcjs.a; exports.CardContent = _chunkE4CMBFLCcjs.e; exports.CardDescription = _chunkE4CMBFLCcjs.d; exports.CardFooter = _chunkE4CMBFLCcjs.f; exports.CardHeader = _chunkE4CMBFLCcjs.b; exports.CardTitle = _chunkE4CMBFLCcjs.c; exports.Carousel = _chunkDQBQF25Fcjs.b; exports.CarouselContent = _chunkDQBQF25Fcjs.c; exports.CarouselItem = _chunkDQBQF25Fcjs.d; exports.CarouselNext = _chunkDQBQF25Fcjs.f; exports.CarouselPrevious = _chunkDQBQF25Fcjs.e; exports.ChartContainer = _chunkFVR3LJWMcjs.a; exports.ChartLegend = _chunkFVR3LJWMcjs.e; exports.ChartLegendContent = _chunkFVR3LJWMcjs.f; exports.ChartStyle = _chunkFVR3LJWMcjs.b; exports.ChartTooltip = _chunkFVR3LJWMcjs.c; exports.ChartTooltipContent = _chunkFVR3LJWMcjs.d; exports.Checkbox = _chunkGUOQM6BLcjs.a; exports.CheckboxCards = _chunkUIVPC5TQcjs.a; exports.CheckboxCardsItem = _chunkUIVPC5TQcjs.b; exports.CheckboxGroup = _chunkVFOMCFSGcjs.a; exports.CheckboxGroupItem = _chunkVFOMCFSGcjs.b; exports.Code = _chunkJF2OKUYDcjs.a; exports.Collapsible = _chunkQ5E3BLJNcjs.a; exports.CollapsibleContent = _chunkQ5E3BLJNcjs.c; exports.CollapsibleTrigger = _chunkQ5E3BLJNcjs.b; exports.Command = _chunkIPRXHJQ5cjs.a; exports.CommandDialog = _chunkIPRXHJQ5cjs.b; exports.CommandEmpty = _chunkIPRXHJQ5cjs.e; exports.CommandGroup = _chunkIPRXHJQ5cjs.f; exports.CommandInput = _chunkIPRXHJQ5cjs.c; exports.CommandItem = _chunkIPRXHJQ5cjs.h; exports.CommandList = _chunkIPRXHJQ5cjs.d; exports.CommandLoading = _chunkIPRXHJQ5cjs.i; exports.CommandSeparator = _chunkIPRXHJQ5cjs.g; exports.CommandShortcut = _chunkIPRXHJQ5cjs.j; exports.Container = _chunkW7777KAFcjs.a; exports.ContextMenu = _chunkVBE6D4FZcjs.a; exports.ContextMenuArrow = _chunkVBE6D4FZcjs.o; exports.ContextMenuCheckboxItem = _chunkVBE6D4FZcjs.j; exports.ContextMenuContent = _chunkVBE6D4FZcjs.h; exports.ContextMenuGroup = _chunkVBE6D4FZcjs.c; exports.ContextMenuItem = _chunkVBE6D4FZcjs.i; exports.ContextMenuLabel = _chunkVBE6D4FZcjs.l; exports.ContextMenuRadioGroup = _chunkVBE6D4FZcjs.e; exports.ContextMenuRadioItem = _chunkVBE6D4FZcjs.k; exports.ContextMenuSeparator = _chunkVBE6D4FZcjs.m; exports.ContextMenuShortcut = _chunkVBE6D4FZcjs.n; exports.ContextMenuSub = _chunkVBE6D4FZcjs.d; exports.ContextMenuSubContent = _chunkVBE6D4FZcjs.g; exports.ContextMenuSubTrigger = _chunkVBE6D4FZcjs.f; exports.ContextMenuTrigger = _chunkVBE6D4FZcjs.b; exports.DataTableColumnHeader = _chunkPYKB3C2Fcjs.c; exports.DataTablePagination = _chunkPYKB3C2Fcjs.b; exports.DataTableViewOptions = _chunkPYKB3C2Fcjs.a; exports.Dialog = _chunkB5V32KRWcjs.a; exports.DialogBody = _chunkB5V32KRWcjs.e; exports.DialogClose = _chunkB5V32KRWcjs.i; exports.DialogContent = _chunkB5V32KRWcjs.c; exports.DialogDescription = _chunkB5V32KRWcjs.h; exports.DialogFooter = _chunkB5V32KRWcjs.f; exports.DialogHeader = _chunkB5V32KRWcjs.d; exports.DialogTitle = _chunkB5V32KRWcjs.g; exports.DialogTrigger = _chunkB5V32KRWcjs.b; exports.Drawer = _chunk2OIYIMMKcjs.a; exports.DrawerBody = _chunk2OIYIMMKcjs.e; exports.DrawerClose = _chunk2OIYIMMKcjs.i; exports.DrawerContent = _chunk2OIYIMMKcjs.c; exports.DrawerDescription = _chunk2OIYIMMKcjs.h; exports.DrawerFooter = _chunk2OIYIMMKcjs.f; exports.DrawerHeader = _chunk2OIYIMMKcjs.d; exports.DrawerTitle = _chunk2OIYIMMKcjs.g; exports.DrawerTrigger = _chunk2OIYIMMKcjs.b; exports.DropdownMenu = _chunkYORY32TXcjs.a; exports.DropdownMenuArrow = _chunkYORY32TXcjs.o; exports.DropdownMenuCheckboxItem = _chunkYORY32TXcjs.j; exports.DropdownMenuContent = _chunkYORY32TXcjs.h; exports.DropdownMenuGroup = _chunkYORY32TXcjs.c; exports.DropdownMenuItem = _chunkYORY32TXcjs.i; exports.DropdownMenuLabel = _chunkYORY32TXcjs.l; exports.DropdownMenuRadioGroup = _chunkYORY32TXcjs.e; exports.DropdownMenuRadioItem = _chunkYORY32TXcjs.k; exports.DropdownMenuSeparator = _chunkYORY32TXcjs.m; exports.DropdownMenuShortcut = _chunkYORY32TXcjs.n; exports.DropdownMenuSub = _chunkYORY32TXcjs.d; exports.DropdownMenuSubContent = _chunkYORY32TXcjs.g; exports.DropdownMenuSubTrigger = _chunkYORY32TXcjs.f; exports.DropdownMenuTrigger = _chunkYORY32TXcjs.b; exports.Em = _chunkGWSYICGKcjs.a; exports.Form = _chunkF35POBWNcjs.a; exports.FormControl = _chunkF35POBWNcjs.f; exports.FormDescription = _chunkF35POBWNcjs.g; exports.FormField = _chunkF35POBWNcjs.c; exports.FormItem = _chunkF35POBWNcjs.d; exports.FormLabel = _chunkF35POBWNcjs.e; exports.FormMessage = _chunkF35POBWNcjs.h; exports.Heading = _chunkKUKRY4KGcjs.a; exports.HoverCard = _chunkRXWJHQ3Jcjs.a; exports.HoverCardArrow = _chunkRXWJHQ3Jcjs.d; exports.HoverCardContent = _chunkRXWJHQ3Jcjs.c; exports.HoverCardTrigger = _chunkRXWJHQ3Jcjs.b; exports.InputOTP = _chunkKASTA74Mcjs.d; exports.InputOTPGroup = _chunkKASTA74Mcjs.e; exports.InputOTPSeparator = _chunkKASTA74Mcjs.g; exports.InputOTPSlot = _chunkKASTA74Mcjs.f; exports.Kbd = _chunkOODSJGVYcjs.a; exports.Label = _chunkEIJDA5S5cjs.a; exports.Menubar = _chunk4PL3DAT2cjs.e; exports.MenubarArrow = _chunk4PL3DAT2cjs.p; exports.MenubarCheckboxItem = _chunk4PL3DAT2cjs.k; exports.MenubarContent = _chunk4PL3DAT2cjs.i; exports.MenubarGroup = _chunk4PL3DAT2cjs.b; exports.MenubarItem = _chunk4PL3DAT2cjs.j; exports.MenubarLabel = _chunk4PL3DAT2cjs.m; exports.MenubarMenu = _chunk4PL3DAT2cjs.a; exports.MenubarRadioGroup = _chunk4PL3DAT2cjs.d; exports.MenubarRadioItem = _chunk4PL3DAT2cjs.l; exports.MenubarSeparator = _chunk4PL3DAT2cjs.n; exports.MenubarShortcut = _chunk4PL3DAT2cjs.o; exports.MenubarSub = _chunk4PL3DAT2cjs.c; exports.MenubarSubContent = _chunk4PL3DAT2cjs.h; exports.MenubarSubTrigger = _chunk4PL3DAT2cjs.g; exports.MenubarTrigger = _chunk4PL3DAT2cjs.f; exports.NavigationMenu = _chunkMHH6QOREcjs.a; exports.NavigationMenuContent = _chunkMHH6QOREcjs.e; exports.NavigationMenuItem = _chunkMHH6QOREcjs.c; exports.NavigationMenuLink = _chunkMHH6QOREcjs.f; exports.NavigationMenuList = _chunkMHH6QOREcjs.b; exports.NavigationMenuTrigger = _chunkMHH6QOREcjs.d; exports.NumberInput = _chunkR5235IUCcjs.a; exports.Pagination = _chunkBAOFKRE7cjs.a; exports.PaginationContent = _chunkBAOFKRE7cjs.b; exports.PaginationEllipsis = _chunkBAOFKRE7cjs.g; exports.PaginationItem = _chunkBAOFKRE7cjs.c; exports.PaginationLink = _chunkBAOFKRE7cjs.d; exports.PaginationNext = _chunkBAOFKRE7cjs.f; exports.PaginationPrevious = _chunkBAOFKRE7cjs.e; exports.PasswordInput = _chunkSDGFNHJPcjs.a; exports.Popover = _chunkYQ2OTPJ3cjs.a; exports.PopoverAnchor = _chunkYQ2OTPJ3cjs.c; exports.PopoverArrow = _chunkYQ2OTPJ3cjs.e; exports.PopoverContent = _chunkYQ2OTPJ3cjs.d; exports.PopoverTrigger = _chunkYQ2OTPJ3cjs.b; exports.Pre = _chunk2U4H7AXCcjs.a; exports.Progress = _chunkBXDCIP66cjs.a; exports.Quote = _chunkDH7PAQN6cjs.a; exports.REGEXP_ONLY_CHARS = _chunkKASTA74Mcjs.a; exports.REGEXP_ONLY_DIGITS = _chunkKASTA74Mcjs.b; exports.REGEXP_ONLY_DIGITS_AND_CHARS = _chunkKASTA74Mcjs.c; exports.Radio = _chunkPEQRNG2Rcjs.a; exports.RadioCards = _chunkMGESGIS4cjs.a; exports.RadioCardsItem = _chunkMGESGIS4cjs.b; exports.RadioGroup = _chunkWUIFKZNRcjs.a; exports.RadioGroupItem = _chunkWUIFKZNRcjs.b; exports.ResizableHandle = _chunkOOEZEXWKcjs.c; exports.ResizablePanel = _chunkOOEZEXWKcjs.b; exports.ResizablePanelGroup = _chunkOOEZEXWKcjs.a; exports.ScrollArea = _chunkJSZUH4EWcjs.a; exports.ScrollAreaScrollbar = _chunkJSZUH4EWcjs.b; exports.SearchInput = _chunkZ7U5IONCcjs.a; exports.Section = _chunk5XLLR5OUcjs.a; exports.Select = _chunkEEDKRHHZcjs.a; exports.SelectContent = _chunkEEDKRHHZcjs.g; exports.SelectGroup = _chunkEEDKRHHZcjs.b; exports.SelectItem = _chunkEEDKRHHZcjs.i; exports.SelectLabel = _chunkEEDKRHHZcjs.h; exports.SelectScrollDownButton = _chunkEEDKRHHZcjs.f; exports.SelectScrollUpButton = _chunkEEDKRHHZcjs.e; exports.SelectSeparator = _chunkEEDKRHHZcjs.j; exports.SelectTrigger = _chunkEEDKRHHZcjs.d; exports.SelectValue = _chunkEEDKRHHZcjs.c; exports.Separator = _chunkD3EC6HWNcjs.a; exports.SeparatorItem = _chunkD3EC6HWNcjs.b; exports.Sheet = _chunkDIYHARQUcjs.a; exports.SheetBody = _chunkDIYHARQUcjs.e; exports.SheetClose = _chunkDIYHARQUcjs.i; exports.SheetContent = _chunkDIYHARQUcjs.c; exports.SheetDescription = _chunkDIYHARQUcjs.h; exports.SheetFooter = _chunkDIYHARQUcjs.f; exports.SheetHeader = _chunkDIYHARQUcjs.d; exports.SheetTitle = _chunkDIYHARQUcjs.g; exports.SheetTrigger = _chunkDIYHARQUcjs.b; exports.Sidebar = _chunkE2QRPDUIcjs.c; exports.SidebarContent = _chunkE2QRPDUIcjs.k; exports.SidebarFooter = _chunkE2QRPDUIcjs.i; exports.SidebarGroup = _chunkE2QRPDUIcjs.l; exports.SidebarGroupAction = _chunkE2QRPDUIcjs.n; exports.SidebarGroupContent = _chunkE2QRPDUIcjs.o; exports.SidebarGroupLabel = _chunkE2QRPDUIcjs.m; exports.SidebarHeader = _chunkE2QRPDUIcjs.h; exports.SidebarInput = _chunkE2QRPDUIcjs.g; exports.SidebarInset = _chunkE2QRPDUIcjs.f; exports.SidebarMenu = _chunkE2QRPDUIcjs.p; exports.SidebarMenuAction = _chunkE2QRPDUIcjs.s; exports.SidebarMenuBadge = _chunkE2QRPDUIcjs.t; exports.SidebarMenuButton = _chunkE2QRPDUIcjs.r; exports.SidebarMenuItem = _chunkE2QRPDUIcjs.q; exports.SidebarMenuSkeleton = _chunkE2QRPDUIcjs.u; exports.SidebarMenuSub = _chunkE2QRPDUIcjs.v; exports.SidebarMenuSubButton = _chunkE2QRPDUIcjs.x; exports.SidebarMenuSubItem = _chunkE2QRPDUIcjs.w; exports.SidebarProvider = _chunkE2QRPDUIcjs.b; exports.SidebarRail = _chunkE2QRPDUIcjs.e; exports.SidebarSeparator = _chunkE2QRPDUIcjs.j; exports.SidebarTrigger = _chunkE2QRPDUIcjs.d; exports.Skeleton = _chunk5XCNTI3Xcjs.a; exports.Slider = _chunkHHX6KYEHcjs.a; exports.Spinner = _chunk7R4FFNVEcjs.a; exports.Strong = _chunkN2RQKUCGcjs.a; exports.Switch = _chunkJOGGNWWAcjs.a; exports.Table = _chunkSRRXHGGIcjs.a; exports.TableBody = _chunkSRRXHGGIcjs.c; exports.TableCaption = _chunkSRRXHGGIcjs.h; exports.TableCell = _chunkSRRXHGGIcjs.g; exports.TableFooter = _chunkSRRXHGGIcjs.d; exports.TableHead = _chunkSRRXHGGIcjs.f; exports.TableHeader = _chunkSRRXHGGIcjs.b; exports.TableRow = _chunkSRRXHGGIcjs.e; exports.Tabs = _chunkTQEAAFPMcjs.a; exports.TabsContent = _chunkTQEAAFPMcjs.d; exports.TabsList = _chunkTQEAAFPMcjs.b; exports.TabsTrigger = _chunkTQEAAFPMcjs.c; exports.Text = _chunkXWRE723Zcjs.a; exports.TextInput = _chunkOKI5PENPcjs.a; exports.Textarea = _chunk5DADNTMKcjs.a; exports.Toaster = _chunkAI3AM6TDcjs.b; exports.Toggle = _chunkE5WTRZE4cjs.a; exports.ToggleGroup = _chunkNOCY2CX5cjs.a; exports.ToggleGroupItem = _chunkNOCY2CX5cjs.b; exports.Tooltip = _chunkQ62VKCH2cjs.b; exports.TooltipArrow = _chunkQ62VKCH2cjs.e; exports.TooltipContent = _chunkQ62VKCH2cjs.d; exports.TooltipProvider = _chunkQ62VKCH2cjs.a; exports.TooltipTrigger = _chunkQ62VKCH2cjs.c; exports.buttonVariants = _chunkKF7Y7B3Gcjs.a; exports.cn = _chunkDD6AVCRHcjs.a; exports.createCarouselScope = _chunkDQBQF25Fcjs.a; exports.createFormFieldScope = _chunkF35POBWNcjs.b; exports.inputVariants = _chunk7XV37NAWcjs.a; exports.toast = _chunkAI3AM6TDcjs.a; exports.toggleVariants = _chunkSSYLDUQ5cjs.a; exports.useSidebar = _chunkE2QRPDUIcjs.a;
2
2
  //# sourceMappingURL=index.cjs.map
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
- import{a as pm}from"./chunk-7KTCYDVV.js";import{a as tm}from"./chunk-CWUEQ5HD.js";import"./chunk-U2JQOYDM.js";import{a as am,b as bm}from"./chunk-LO2FS7FR.js";import{a as xm}from"./chunk-HYWI7FDY.js";import{a as f}from"./chunk-A3QTZPKF.js";import{a as Qf}from"./chunk-TOWAHUGD.js";import{a as Rf,b as Sf}from"./chunk-2EYLJJP4.js";import{a as Tf}from"./chunk-I5K76QCG.js";import{a as Uf}from"./chunk-MON2QHOT.js";import{a as Vf,b as Wf,c as Xf,d as Yf,e as Zf,f as _f,g as $f,h as om}from"./chunk-UDX3IEKM.js";import{a as rm,b as em,c as fm,d as mm}from"./chunk-OPRULC2F.js";import{a as Xe,b as Ye}from"./chunk-IGCAV4VX.js";import{a as Ze}from"./chunk-QEIZTAWS.js";import{a as _e}from"./chunk-VRXT6PRC.js";import{a as nf,b as qf,c as sf,d as uf,e as vf,f as wf,g as yf,h as zf,i as Af,j as Bf,k as Cf,l as Df,m as Ef,n as Ff,o as Gf,p as Hf,q as If,r as Jf,s as Kf,t as Lf,u as Mf,v as Nf,w as Of,x as Pf}from"./chunk-FSXJI6UE.js";import{a as gf,b as hf,c as jf,d as kf,e as lf}from"./chunk-CTKVRKDK.js";import{a as df}from"./chunk-NPOAOTIH.js";import{a as $e,b as of}from"./chunk-432ZMHFM.js";import{a as rf,b as ef,c as ff,d as mf,e as pf,f as tf,g as xf,h as af,i as bf}from"./chunk-MO7TQSRR.js";import{a as cf}from"./chunk-NSTXYMJD.js";import{a as He,b as Ie,c as Je,d as Ke,e as Le}from"./chunk-G7UUQVY6.js";import{a as Me}from"./chunk-VPA4U2FS.js";import{a as Ne}from"./chunk-WZZJWFQP.js";import{a as Oe}from"./chunk-GND6Q575.js";import{a as Qe,b as Re}from"./chunk-3KBPDNGS.js";import{a as Se,b as Te}from"./chunk-2ZQDYMUR.js";import{a as Pe}from"./chunk-P5ZHKPJ3.js";import{a as Ue,b as Ve,c as We}from"./chunk-C4SXNTCJ.js";import{a as Wr,b as Xr,c as Yr,d as Zr,e as _r,f as $r,g as oe}from"./chunk-BHLW3MWI.js";import{a as re}from"./chunk-HFMP27AD.js";import{a as ee,b as fe,c as me,d as pe,e as te,f as xe,g as ae,h as be,i as ce,j as de,k as ge,l as he,m as ie,n as je,o as ke,p as le}from"./chunk-P3YLZBAU.js";import{a as ne,b as qe,c as se,d as ue,e as ve,f as we}from"./chunk-DUDXLCPG.js";import{a as ye}from"./chunk-5I7UA4HT.js";import{a as ze,b as Ae,c as Be,d as Ce,e as De,f as Ee,g as Fe}from"./chunk-CRQ5URNB.js";import{a as Ge}from"./chunk-MYT23AOL.js";import{a as e}from"./chunk-7MCTR55I.js";import"./chunk-C46H5E6H.js";import{a as yr,b as zr,c as Ar,d as Br,e as Cr,f as Dr,g as Er,h as Fr,i as Gr}from"./chunk-VSK5MMW2.js";import{a as Hr}from"./chunk-2ETHQRHT.js";import{a as Jr,b as Kr,c as Lr,d as Mr,e as Nr,f as Or,g as Pr,h as Qr}from"./chunk-UHSBASIV.js";import{a as Ir}from"./chunk-762VAWTL.js";import{a as Rr}from"./chunk-KTOV7L3M.js";import{a as Sr,b as Tr,c as Ur,d as Vr}from"./chunk-V4SVGR7Z.js";import{a as ao,b as bo}from"./chunk-LJPFJ6NG.js";import{a as po}from"./chunk-Q7IH47TY.js";import{a as co}from"./chunk-WLRNKE5B.js";import{a as go,b as ho,c as io}from"./chunk-XDP3WMTM.js";import{a as yo,b as zo,c as Ao,d as Bo,e as Co,f as Do,g as Eo,h as Fo,i as Go,j as Ho}from"./chunk-PCKCN7MO.js";import{a as jo,b as ko,c as lo,d as no,e as qo,f as so,g as uo,h as vo,i as wo}from"./chunk-LGRBBJSZ.js";import{a as Io}from"./chunk-L75DLRYU.js";import{a as Jo,b as Ko,c as Lo,d as Mo,e as No,f as Oo,g as Po,h as Qo,i as Ro,j as So,k as To,l as Uo,m as Vo,n as Wo,o as Xo}from"./chunk-YTSBANYY.js";import{a as ur,b as vr,c as wr}from"./chunk-UHHMORLE.js";import{a as dr,b as gr,c as hr,d as ir,e as jr,f as kr,g as lr,h as nr,i as qr,j as sr}from"./chunk-TTKMKXCU.js";import{a as Yo,b as Zo,c as _o,d as $o,e as or,f as rr,g as er,h as fr,i as mr,j as pr,k as tr,l as xr,m as ar,n as br,o as cr}from"./chunk-OH3BXT6D.js";import{a as C}from"./chunk-XVSKGP3O.js";import{a as D,b as E,c as F,d as G,e as H,f as I,g as J}from"./chunk-JMYWGU6A.js";import{a as M,b as N,c as O}from"./chunk-GV5FQF4J.js";import{a as P,b as Q,c as R,d as S,e as T,f as U}from"./chunk-2PHCOZGN.js";import{a as V,b as W,c as X,d as Y,e as Z,f as _}from"./chunk-5LM6T7Z5.js";import{a as L}from"./chunk-24TJIVWR.js";import{a as K}from"./chunk-Q3UBBFLY.js";import{a as $,b as oo,c as ro,d as eo,e as fo,f as mo}from"./chunk-WNXJ2WHS.js";import{a as to,b as xo}from"./chunk-O632SAUI.js";import{a as m,b as p,c as t,d as x,e as a}from"./chunk-UQWSMTYF.js";import{a as g,b as h,c as i,d as j,e as k,f as l,g as n,h as q,i as s,j as u}from"./chunk-I5F5NVBQ.js";import{a as r}from"./chunk-EVRI6TWT.js";import{a as b,b as c,c as d}from"./chunk-SW7ESX5V.js";import{a as v}from"./chunk-ZLO6FT4E.js";import{a as w,b as y,c as z}from"./chunk-PCQE4FJF.js";import{a as o}from"./chunk-VPYH6JWS.js";import{a as A}from"./chunk-6FFAEE2J.js";import{a as B}from"./chunk-UL2FIEEV.js";export{m as Accordion,a as AccordionContent,t as AccordionIcon,p as AccordionItem,x as AccordionTrigger,b as Alert,d as AlertDescription,g as AlertDialog,s as AlertDialogAction,k as AlertDialogBody,u as AlertDialogCancel,i as AlertDialogContent,q as AlertDialogDescription,l as AlertDialogFooter,j as AlertDialogHeader,n as AlertDialogTitle,h as AlertDialogTrigger,c as AlertTitle,v as AspectRatio,w as Avatar,z as AvatarFallback,y as AvatarImage,A as Badge,B as Blockquote,C as Box,D as Breadcrumb,J as BreadcrumbEllipsis,F as BreadcrumbItem,G as BreadcrumbLink,E as BreadcrumbList,H as BreadcrumbPage,I as BreadcrumbSeparator,L as Button,M as Calendar,O as CalendarLabel,N as CalendarRangeLabel,P as Card,T as CardContent,S as CardDescription,U as CardFooter,Q as CardHeader,R as CardTitle,W as Carousel,X as CarouselContent,Y as CarouselItem,_ as CarouselNext,Z as CarouselPrevious,$ as ChartContainer,fo as ChartLegend,mo as ChartLegendContent,oo as ChartStyle,ro as ChartTooltip,eo as ChartTooltipContent,po as Checkbox,to as CheckboxCards,xo as CheckboxCardsItem,ao as CheckboxGroup,bo as CheckboxGroupItem,co as Code,go as Collapsible,io as CollapsibleContent,ho as CollapsibleTrigger,yo as Command,zo as CommandDialog,Co as CommandEmpty,Do as CommandGroup,Ao as CommandInput,Fo as CommandItem,Bo as CommandList,Go as CommandLoading,Eo as CommandSeparator,Ho as CommandShortcut,Io as Container,Jo as ContextMenu,Xo as ContextMenuArrow,So as ContextMenuCheckboxItem,Qo as ContextMenuContent,Lo as ContextMenuGroup,Ro as ContextMenuItem,Uo as ContextMenuLabel,No as ContextMenuRadioGroup,To as ContextMenuRadioItem,Vo as ContextMenuSeparator,Wo as ContextMenuShortcut,Mo as ContextMenuSub,Po as ContextMenuSubContent,Oo as ContextMenuSubTrigger,Ko as ContextMenuTrigger,wr as DataTableColumnHeader,vr as DataTablePagination,ur as DataTableViewOptions,jo as Dialog,qo as DialogBody,wo as DialogClose,lo as DialogContent,vo as DialogDescription,so as DialogFooter,no as DialogHeader,uo as DialogTitle,ko as DialogTrigger,yr as Drawer,Cr as DrawerBody,Gr as DrawerClose,Ar as DrawerContent,Fr as DrawerDescription,Dr as DrawerFooter,Br as DrawerHeader,Er as DrawerTitle,zr as DrawerTrigger,Yo as DropdownMenu,cr as DropdownMenuArrow,pr as DropdownMenuCheckboxItem,fr as DropdownMenuContent,_o as DropdownMenuGroup,mr as DropdownMenuItem,xr as DropdownMenuLabel,or as DropdownMenuRadioGroup,tr as DropdownMenuRadioItem,ar as DropdownMenuSeparator,br as DropdownMenuShortcut,$o as DropdownMenuSub,er as DropdownMenuSubContent,rr as DropdownMenuSubTrigger,Zo as DropdownMenuTrigger,Hr as Em,Jr as Form,Or as FormControl,Pr as FormDescription,Lr as FormField,Mr as FormItem,Nr as FormLabel,Qr as FormMessage,Rr as Heading,Sr as HoverCard,Vr as HoverCardArrow,Ur as HoverCardContent,Tr as HoverCardTrigger,Zr as InputOTP,_r as InputOTPGroup,oe as InputOTPSeparator,$r as InputOTPSlot,re as Kbd,Ir as Label,te as Menubar,le as MenubarArrow,ge as MenubarCheckboxItem,ce as MenubarContent,fe as MenubarGroup,de as MenubarItem,ie as MenubarLabel,ee as MenubarMenu,pe as MenubarRadioGroup,he as MenubarRadioItem,je as MenubarSeparator,ke as MenubarShortcut,me as MenubarSub,be as MenubarSubContent,ae as MenubarSubTrigger,xe as MenubarTrigger,ne as NavigationMenu,ve as NavigationMenuContent,se as NavigationMenuItem,we as NavigationMenuLink,qe as NavigationMenuList,ue as NavigationMenuTrigger,ye as NumberInput,ze as Pagination,Ae as PaginationContent,Fe as PaginationEllipsis,Be as PaginationItem,Ce as PaginationLink,Ee as PaginationNext,De as PaginationPrevious,Ge as PasswordInput,He as Popover,Je as PopoverAnchor,Le as PopoverArrow,Ke as PopoverContent,Ie as PopoverTrigger,Me as Pre,Ne as Progress,Oe as Quote,Wr as REGEXP_ONLY_CHARS,Xr as REGEXP_ONLY_DIGITS,Yr as REGEXP_ONLY_DIGITS_AND_CHARS,Pe as Radio,Qe as RadioCards,Re as RadioCardsItem,Se as RadioGroup,Te as RadioGroupItem,We as ResizableHandle,Ve as ResizablePanel,Ue as ResizablePanelGroup,Xe as ScrollArea,Ye as ScrollAreaScrollbar,Ze as SearchInput,_e as Section,dr as Select,lr as SelectContent,gr as SelectGroup,qr as SelectItem,nr as SelectLabel,kr as SelectScrollDownButton,jr as SelectScrollUpButton,sr as SelectSeparator,ir as SelectTrigger,hr as SelectValue,$e as Separator,of as SeparatorItem,rf as Sheet,pf as SheetBody,bf as SheetClose,ff as SheetContent,af as SheetDescription,tf as SheetFooter,mf as SheetHeader,xf as SheetTitle,ef as SheetTrigger,sf as Sidebar,Cf as SidebarContent,Af as SidebarFooter,Df as SidebarGroup,Ff as SidebarGroupAction,Gf as SidebarGroupContent,Ef as SidebarGroupLabel,zf as SidebarHeader,yf as SidebarInput,wf as SidebarInset,Hf as SidebarMenu,Kf as SidebarMenuAction,Lf as SidebarMenuBadge,Jf as SidebarMenuButton,If as SidebarMenuItem,Mf as SidebarMenuSkeleton,Nf as SidebarMenuSub,Pf as SidebarMenuSubButton,Of as SidebarMenuSubItem,qf as SidebarProvider,vf as SidebarRail,Bf as SidebarSeparator,uf as SidebarTrigger,cf as Skeleton,Qf as Slider,K as Spinner,Tf as Strong,Uf as Switch,Vf as Table,Xf as TableBody,om as TableCaption,$f as TableCell,Yf as TableFooter,_f as TableHead,Wf as TableHeader,Zf as TableRow,rm as Tabs,mm as TabsContent,em as TabsList,fm as TabsTrigger,pm as Text,df as TextInput,tm as Textarea,Sf as Toaster,xm as Toggle,am as ToggleGroup,bm as ToggleGroupItem,hf as Tooltip,lf as TooltipArrow,kf as TooltipContent,gf as TooltipProvider,jf as TooltipTrigger,r as buttonVariants,o as cn,V as createCarouselScope,Kr as createFormFieldScope,e as inputVariants,Rf as toast,f as toggleVariants,nf as useSidebar};
1
+ import{a as pm}from"./chunk-7KTCYDVV.js";import{a as tm}from"./chunk-CWUEQ5HD.js";import"./chunk-U2JQOYDM.js";import{a as am,b as bm}from"./chunk-LO2FS7FR.js";import{a as xm}from"./chunk-HYWI7FDY.js";import{a as f}from"./chunk-A3QTZPKF.js";import{a as Qf}from"./chunk-TOWAHUGD.js";import{a as Rf,b as Sf}from"./chunk-2EYLJJP4.js";import{a as Tf}from"./chunk-I5K76QCG.js";import{a as Uf}from"./chunk-MON2QHOT.js";import{a as Vf,b as Wf,c as Xf,d as Yf,e as Zf,f as _f,g as $f,h as om}from"./chunk-UDX3IEKM.js";import{a as rm,b as em,c as fm,d as mm}from"./chunk-5J3MQRCG.js";import{a as Xe,b as Ye}from"./chunk-IGCAV4VX.js";import{a as Ze}from"./chunk-QEIZTAWS.js";import{a as _e}from"./chunk-VRXT6PRC.js";import{a as nf,b as qf,c as sf,d as uf,e as vf,f as wf,g as yf,h as zf,i as Af,j as Bf,k as Cf,l as Df,m as Ef,n as Ff,o as Gf,p as Hf,q as If,r as Jf,s as Kf,t as Lf,u as Mf,v as Nf,w as Of,x as Pf}from"./chunk-FSXJI6UE.js";import{a as gf,b as hf,c as jf,d as kf,e as lf}from"./chunk-CTKVRKDK.js";import{a as df}from"./chunk-NPOAOTIH.js";import{a as $e,b as of}from"./chunk-432ZMHFM.js";import{a as rf,b as ef,c as ff,d as mf,e as pf,f as tf,g as xf,h as af,i as bf}from"./chunk-MO7TQSRR.js";import{a as cf}from"./chunk-NSTXYMJD.js";import{a as He,b as Ie,c as Je,d as Ke,e as Le}from"./chunk-G7UUQVY6.js";import{a as Me}from"./chunk-VPA4U2FS.js";import{a as Ne}from"./chunk-WZZJWFQP.js";import{a as Oe}from"./chunk-GND6Q575.js";import{a as Qe,b as Re}from"./chunk-3KBPDNGS.js";import{a as Se,b as Te}from"./chunk-2ZQDYMUR.js";import{a as Pe}from"./chunk-P5ZHKPJ3.js";import{a as Ue,b as Ve,c as We}from"./chunk-C4SXNTCJ.js";import{a as Wr,b as Xr,c as Yr,d as Zr,e as _r,f as $r,g as oe}from"./chunk-BHLW3MWI.js";import{a as re}from"./chunk-HFMP27AD.js";import{a as ee,b as fe,c as me,d as pe,e as te,f as xe,g as ae,h as be,i as ce,j as de,k as ge,l as he,m as ie,n as je,o as ke,p as le}from"./chunk-P3YLZBAU.js";import{a as ne,b as qe,c as se,d as ue,e as ve,f as we}from"./chunk-DUDXLCPG.js";import{a as ye}from"./chunk-5I7UA4HT.js";import{a as ze,b as Ae,c as Be,d as Ce,e as De,f as Ee,g as Fe}from"./chunk-CRQ5URNB.js";import{a as Ge}from"./chunk-MYT23AOL.js";import{a as e}from"./chunk-7MCTR55I.js";import"./chunk-C46H5E6H.js";import{a as yr,b as zr,c as Ar,d as Br,e as Cr,f as Dr,g as Er,h as Fr,i as Gr}from"./chunk-VSK5MMW2.js";import{a as Hr}from"./chunk-2ETHQRHT.js";import{a as Jr,b as Kr,c as Lr,d as Mr,e as Nr,f as Or,g as Pr,h as Qr}from"./chunk-UHSBASIV.js";import{a as Ir}from"./chunk-762VAWTL.js";import{a as Rr}from"./chunk-KTOV7L3M.js";import{a as Sr,b as Tr,c as Ur,d as Vr}from"./chunk-V4SVGR7Z.js";import{a as ao,b as bo}from"./chunk-LJPFJ6NG.js";import{a as po}from"./chunk-Q7IH47TY.js";import{a as co}from"./chunk-WLRNKE5B.js";import{a as go,b as ho,c as io}from"./chunk-XDP3WMTM.js";import{a as yo,b as zo,c as Ao,d as Bo,e as Co,f as Do,g as Eo,h as Fo,i as Go,j as Ho}from"./chunk-PCKCN7MO.js";import{a as jo,b as ko,c as lo,d as no,e as qo,f as so,g as uo,h as vo,i as wo}from"./chunk-LGRBBJSZ.js";import{a as Io}from"./chunk-L75DLRYU.js";import{a as Jo,b as Ko,c as Lo,d as Mo,e as No,f as Oo,g as Po,h as Qo,i as Ro,j as So,k as To,l as Uo,m as Vo,n as Wo,o as Xo}from"./chunk-YTSBANYY.js";import{a as ur,b as vr,c as wr}from"./chunk-UHHMORLE.js";import{a as dr,b as gr,c as hr,d as ir,e as jr,f as kr,g as lr,h as nr,i as qr,j as sr}from"./chunk-TTKMKXCU.js";import{a as Yo,b as Zo,c as _o,d as $o,e as or,f as rr,g as er,h as fr,i as mr,j as pr,k as tr,l as xr,m as ar,n as br,o as cr}from"./chunk-OH3BXT6D.js";import{a as C}from"./chunk-XVSKGP3O.js";import{a as D,b as E,c as F,d as G,e as H,f as I,g as J}from"./chunk-JMYWGU6A.js";import{a as M,b as N,c as O}from"./chunk-GV5FQF4J.js";import{a as P,b as Q,c as R,d as S,e as T,f as U}from"./chunk-2PHCOZGN.js";import{a as V,b as W,c as X,d as Y,e as Z,f as _}from"./chunk-5LM6T7Z5.js";import{a as L}from"./chunk-24TJIVWR.js";import{a as K}from"./chunk-Q3UBBFLY.js";import{a as $,b as oo,c as ro,d as eo,e as fo,f as mo}from"./chunk-VZSYA6XE.js";import{a as to,b as xo}from"./chunk-O632SAUI.js";import{a as m,b as p,c as t,d as x,e as a}from"./chunk-UQWSMTYF.js";import{a as g,b as h,c as i,d as j,e as k,f as l,g as n,h as q,i as s,j as u}from"./chunk-I5F5NVBQ.js";import{a as r}from"./chunk-EVRI6TWT.js";import{a as b,b as c,c as d}from"./chunk-SW7ESX5V.js";import{a as v}from"./chunk-ZLO6FT4E.js";import{a as w,b as y,c as z}from"./chunk-PCQE4FJF.js";import{a as o}from"./chunk-VPYH6JWS.js";import{a as A}from"./chunk-6FFAEE2J.js";import{a as B}from"./chunk-UL2FIEEV.js";export{m as Accordion,a as AccordionContent,t as AccordionIcon,p as AccordionItem,x as AccordionTrigger,b as Alert,d as AlertDescription,g as AlertDialog,s as AlertDialogAction,k as AlertDialogBody,u as AlertDialogCancel,i as AlertDialogContent,q as AlertDialogDescription,l as AlertDialogFooter,j as AlertDialogHeader,n as AlertDialogTitle,h as AlertDialogTrigger,c as AlertTitle,v as AspectRatio,w as Avatar,z as AvatarFallback,y as AvatarImage,A as Badge,B as Blockquote,C as Box,D as Breadcrumb,J as BreadcrumbEllipsis,F as BreadcrumbItem,G as BreadcrumbLink,E as BreadcrumbList,H as BreadcrumbPage,I as BreadcrumbSeparator,L as Button,M as Calendar,O as CalendarLabel,N as CalendarRangeLabel,P as Card,T as CardContent,S as CardDescription,U as CardFooter,Q as CardHeader,R as CardTitle,W as Carousel,X as CarouselContent,Y as CarouselItem,_ as CarouselNext,Z as CarouselPrevious,$ as ChartContainer,fo as ChartLegend,mo as ChartLegendContent,oo as ChartStyle,ro as ChartTooltip,eo as ChartTooltipContent,po as Checkbox,to as CheckboxCards,xo as CheckboxCardsItem,ao as CheckboxGroup,bo as CheckboxGroupItem,co as Code,go as Collapsible,io as CollapsibleContent,ho as CollapsibleTrigger,yo as Command,zo as CommandDialog,Co as CommandEmpty,Do as CommandGroup,Ao as CommandInput,Fo as CommandItem,Bo as CommandList,Go as CommandLoading,Eo as CommandSeparator,Ho as CommandShortcut,Io as Container,Jo as ContextMenu,Xo as ContextMenuArrow,So as ContextMenuCheckboxItem,Qo as ContextMenuContent,Lo as ContextMenuGroup,Ro as ContextMenuItem,Uo as ContextMenuLabel,No as ContextMenuRadioGroup,To as ContextMenuRadioItem,Vo as ContextMenuSeparator,Wo as ContextMenuShortcut,Mo as ContextMenuSub,Po as ContextMenuSubContent,Oo as ContextMenuSubTrigger,Ko as ContextMenuTrigger,wr as DataTableColumnHeader,vr as DataTablePagination,ur as DataTableViewOptions,jo as Dialog,qo as DialogBody,wo as DialogClose,lo as DialogContent,vo as DialogDescription,so as DialogFooter,no as DialogHeader,uo as DialogTitle,ko as DialogTrigger,yr as Drawer,Cr as DrawerBody,Gr as DrawerClose,Ar as DrawerContent,Fr as DrawerDescription,Dr as DrawerFooter,Br as DrawerHeader,Er as DrawerTitle,zr as DrawerTrigger,Yo as DropdownMenu,cr as DropdownMenuArrow,pr as DropdownMenuCheckboxItem,fr as DropdownMenuContent,_o as DropdownMenuGroup,mr as DropdownMenuItem,xr as DropdownMenuLabel,or as DropdownMenuRadioGroup,tr as DropdownMenuRadioItem,ar as DropdownMenuSeparator,br as DropdownMenuShortcut,$o as DropdownMenuSub,er as DropdownMenuSubContent,rr as DropdownMenuSubTrigger,Zo as DropdownMenuTrigger,Hr as Em,Jr as Form,Or as FormControl,Pr as FormDescription,Lr as FormField,Mr as FormItem,Nr as FormLabel,Qr as FormMessage,Rr as Heading,Sr as HoverCard,Vr as HoverCardArrow,Ur as HoverCardContent,Tr as HoverCardTrigger,Zr as InputOTP,_r as InputOTPGroup,oe as InputOTPSeparator,$r as InputOTPSlot,re as Kbd,Ir as Label,te as Menubar,le as MenubarArrow,ge as MenubarCheckboxItem,ce as MenubarContent,fe as MenubarGroup,de as MenubarItem,ie as MenubarLabel,ee as MenubarMenu,pe as MenubarRadioGroup,he as MenubarRadioItem,je as MenubarSeparator,ke as MenubarShortcut,me as MenubarSub,be as MenubarSubContent,ae as MenubarSubTrigger,xe as MenubarTrigger,ne as NavigationMenu,ve as NavigationMenuContent,se as NavigationMenuItem,we as NavigationMenuLink,qe as NavigationMenuList,ue as NavigationMenuTrigger,ye as NumberInput,ze as Pagination,Ae as PaginationContent,Fe as PaginationEllipsis,Be as PaginationItem,Ce as PaginationLink,Ee as PaginationNext,De as PaginationPrevious,Ge as PasswordInput,He as Popover,Je as PopoverAnchor,Le as PopoverArrow,Ke as PopoverContent,Ie as PopoverTrigger,Me as Pre,Ne as Progress,Oe as Quote,Wr as REGEXP_ONLY_CHARS,Xr as REGEXP_ONLY_DIGITS,Yr as REGEXP_ONLY_DIGITS_AND_CHARS,Pe as Radio,Qe as RadioCards,Re as RadioCardsItem,Se as RadioGroup,Te as RadioGroupItem,We as ResizableHandle,Ve as ResizablePanel,Ue as ResizablePanelGroup,Xe as ScrollArea,Ye as ScrollAreaScrollbar,Ze as SearchInput,_e as Section,dr as Select,lr as SelectContent,gr as SelectGroup,qr as SelectItem,nr as SelectLabel,kr as SelectScrollDownButton,jr as SelectScrollUpButton,sr as SelectSeparator,ir as SelectTrigger,hr as SelectValue,$e as Separator,of as SeparatorItem,rf as Sheet,pf as SheetBody,bf as SheetClose,ff as SheetContent,af as SheetDescription,tf as SheetFooter,mf as SheetHeader,xf as SheetTitle,ef as SheetTrigger,sf as Sidebar,Cf as SidebarContent,Af as SidebarFooter,Df as SidebarGroup,Ff as SidebarGroupAction,Gf as SidebarGroupContent,Ef as SidebarGroupLabel,zf as SidebarHeader,yf as SidebarInput,wf as SidebarInset,Hf as SidebarMenu,Kf as SidebarMenuAction,Lf as SidebarMenuBadge,Jf as SidebarMenuButton,If as SidebarMenuItem,Mf as SidebarMenuSkeleton,Nf as SidebarMenuSub,Pf as SidebarMenuSubButton,Of as SidebarMenuSubItem,qf as SidebarProvider,vf as SidebarRail,Bf as SidebarSeparator,uf as SidebarTrigger,cf as Skeleton,Qf as Slider,K as Spinner,Tf as Strong,Uf as Switch,Vf as Table,Xf as TableBody,om as TableCaption,$f as TableCell,Yf as TableFooter,_f as TableHead,Wf as TableHeader,Zf as TableRow,rm as Tabs,mm as TabsContent,em as TabsList,fm as TabsTrigger,pm as Text,df as TextInput,tm as Textarea,Sf as Toaster,xm as Toggle,am as ToggleGroup,bm as ToggleGroupItem,hf as Tooltip,lf as TooltipArrow,kf as TooltipContent,gf as TooltipProvider,jf as TooltipTrigger,r as buttonVariants,o as cn,V as createCarouselScope,Kr as createFormFieldScope,e as inputVariants,Rf as toast,f as toggleVariants,nf as useSidebar};
2
2
  //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codefast/ui",
3
- "version": "0.1.53",
3
+ "version": "0.1.55",
4
4
  "bugs": {
5
5
  "url": "https://github.com/codefastlabs/codefast/issues"
6
6
  },
@@ -75,11 +75,11 @@
75
75
  "tailwind-merge": "2.5.4",
76
76
  "tailwind-variants": "0.3.0",
77
77
  "vaul": "1.1.1",
78
- "@codefast-ui/checkbox-group": "0.1.53",
79
- "@codefast-ui/day-picker": "0.1.53",
80
- "@codefast-ui/input": "0.1.53",
81
- "@codefast-ui/number-input": "0.1.53",
82
- "@codefast/hooks": "0.1.53"
78
+ "@codefast-ui/checkbox-group": "0.1.55",
79
+ "@codefast-ui/day-picker": "0.1.55",
80
+ "@codefast-ui/input": "0.1.55",
81
+ "@codefast-ui/number-input": "0.1.55",
82
+ "@codefast/hooks": "0.1.55"
83
83
  },
84
84
  "devDependencies": {
85
85
  "@types/node": "20.17.6",
@@ -88,9 +88,9 @@
88
88
  "tailwindcss": "3.4.15",
89
89
  "tsup": "8.3.5",
90
90
  "typescript": "5.6.3",
91
- "@codefast/config-tailwind": "0.1.53",
92
- "@codefast/config-typescript": "0.1.53",
93
- "@codefast/eslint-config": "0.1.53"
91
+ "@codefast/config-tailwind": "0.1.55",
92
+ "@codefast/config-typescript": "0.1.55",
93
+ "@codefast/eslint-config": "0.1.55"
94
94
  },
95
95
  "peerDependencies": {
96
96
  "@tanstack/react-table": "8",
@@ -1,4 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }"use client";var _chunkDD6AVCRHcjs = require('./chunk-DD6AVCRH.cjs');var _react = require('react');var _recharts = require('recharts'); var f = _interopRequireWildcard(_recharts);var _jsxruntime = require('react/jsx-runtime');var N={light:"",dark:".dark"},_=_react.createContext.call(void 0, null);function w(){let e=_react.useContext.call(void 0, _);if(!e)throw new Error("useChart must be used within a <ChartContainer />");return e}var $=_react.forwardRef.call(void 0, ({children:e,className:n,config:t,id:o,...a},c)=>{let s=_react.useId.call(void 0, ),l=`chart-${o||s.replace(/:/g,"")}`;return _jsxruntime.jsx.call(void 0, _.Provider,{value:{config:t},children:_jsxruntime.jsxs.call(void 0, "div",{ref:c,className:_chunkDD6AVCRHcjs.a.call(void 0, "flex aspect-video justify-center text-xs","[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground","[&_.recharts-cartesian-grid_line]:stroke-border/50","[&_.recharts-curve.recharts-tooltip-cursor]:stroke-border","[&_.recharts-dot]:stroke-transparent","[&_.recharts-layer]:outline-none","[&_.recharts-polar-grid_]:stroke-border","[&_.recharts-radial-bar-background-sector]:fill-muted","[&_.recharts-reference-line_]:stroke-border","[&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted","[&_.recharts-sector]:outline-none","[&_.recharts-sector]:stroke-transparent","[&_.recharts-surface]:outline-none",n),"data-chart":l,...a,children:[_jsxruntime.jsx.call(void 0, I,{config:t,id:l}),_jsxruntime.jsx.call(void 0, f.ResponsiveContainer,{children:e})]})})});$.displayName="Chart";function I({id:e,config:n}){let t=_react.useMemo.call(void 0, ()=>J(e,n),[e,n]);return _jsxruntime.jsx.call(void 0, "style",{dangerouslySetInnerHTML:{__html:t}})}var G=f.Tooltip,O= exports.d =_react.forwardRef.call(void 0, ({active:e,className:n,color:t,formatter:o,hideIndicator:a=!1,hideLabel:c=!1,indicator:s="dot",label:l,labelClassName:p,labelFormatter:h,labelKey:y,nameKey:E,payload:u},j)=>{let{config:m}=w(),R=_react.useMemo.call(void 0, ()=>{if(c||!_optionalChain([u, 'optionalAccess', _2 => _2.length]))return null;let[r]=u,P=`${y||r.dataKey||r.name||"value"}`,b=T(m,r,P),C=!y&&typeof l=="string"?m[l].label||l:_optionalChain([b, 'optionalAccess', _3 => _3.label]);return h?_jsxruntime.jsx.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "font-medium",p),children:h(C,u)}):C?_jsxruntime.jsx.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "font-medium",p),children:C}):null},[m,c,l,p,h,y,u]);if(!e||!_optionalChain([u, 'optionalAccess', _4 => _4.length]))return null;let v=u.length===1&&s!=="dot";return _jsxruntime.jsxs.call(void 0, "div",{ref:j,className:_chunkDD6AVCRHcjs.a.call(void 0, "border-border/50 bg-background grid min-w-[8rem] items-start gap-1.5 rounded-lg border px-2.5 py-1.5 text-xs shadow-xl",n),children:[v?null:R,_jsxruntime.jsx.call(void 0, "div",{className:"grid gap-1.5",children:u.map((r,P)=>{let b=`${E||r.name||r.dataKey||"value"}`,C=T(m,r,b),S=t||r.payload.fill||r.color;return _jsxruntime.jsx.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5",s==="dot"&&"items-center"),children:o&&r.value!==void 0&&r.name?o(r.value,r.name,r,P,r.payload):_jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment,{children:[_optionalChain([C, 'optionalAccess', _5 => _5.icon])?_jsxruntime.jsx.call(void 0, C.icon,{}):!a&&_jsxruntime.jsx.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "shrink-0 rounded-[2px] border-[--color-border] bg-[--color-bg]",{"h-2.5 w-2.5":s==="dot","w-1":s==="line","w-0 border-[1.5px] border-dashed bg-transparent":s==="dashed","my-0.5":v&&s==="dashed"}),style:{"--color-bg":S,"--color-border":S}}),_jsxruntime.jsxs.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "flex flex-1 justify-between leading-none",v?"items-end":"items-center"),children:[_jsxruntime.jsxs.call(void 0, "div",{className:"grid gap-1.5",children:[v?R:null,_jsxruntime.jsx.call(void 0, "span",{className:"text-muted-foreground",children:_optionalChain([C, 'optionalAccess', _6 => _6.label])||r.name})]}),r.value?_jsxruntime.jsx.call(void 0, "span",{className:"text-foreground font-mono font-medium tabular-nums",children:r.value.toLocaleString()}):null]})]})},r.dataKey)})})]})});O.displayName="ChartTooltipContent";var Q=f.Legend,D= exports.f =_react.forwardRef.call(void 0, ({className:e,hideIcon:n=!1,nameKey:t,payload:o,verticalAlign:a="bottom"},c)=>{let{config:s}=w();return _optionalChain([o, 'optionalAccess', _7 => _7.length])?_jsxruntime.jsx.call(void 0, "div",{ref:c,className:_chunkDD6AVCRHcjs.a.call(void 0, "flex items-center justify-center gap-4",a==="top"?"pb-3":"pt-3",e),children:o.map(l=>{let p="value";t?p=t:l.dataKey&&(p=String(l.dataKey));let h=T(s,l,p);return _jsxruntime.jsxs.call(void 0, "div",{className:_chunkDD6AVCRHcjs.a.call(void 0, "[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:size-3"),children:[_optionalChain([h, 'optionalAccess', _8 => _8.icon])&&!n?_jsxruntime.jsx.call(void 0, h.icon,{}):_jsxruntime.jsx.call(void 0, "div",{className:"size-2 shrink-0 rounded",style:{backgroundColor:l.color}}),_optionalChain([h, 'optionalAccess', _9 => _9.label])]},String(l.value))})}):null});D.displayName="ChartLegendContent";function T(e,n,t){if(!L(n))return;let o="payload"in n&&L(n.payload)?n.payload:void 0,a=V(n,o,t);return a in e?e[a]:e[t]}function L(e){return typeof e=="object"&&e!==null}function V(e,n,t){return t in e&&typeof e[t]=="string"?e[t]:n&&t in n&&typeof n[t]=="string"?n[t]:t}function z(e,n,t){let o=[];return o.push(`${N[e]} [data-chart=${n}] {`),t.forEach(([a,c])=>{let s=_optionalChain([c, 'access', _10 => _10.theme, 'optionalAccess', _11 => _11[e]])||c.color;s&&o.push(` --color-${a}: ${s};`)}),o.push("}"),o.join(`
2
- `)}function J(e,n){let t=Object.entries(n).filter(([a,{theme:c,color:s}])=>c||s),o=[];return Object.keys(N).forEach(a=>{let c=z(a,e,t);o.push(c)}),o.join(`
3
- `)}exports.a = $; exports.b = I; exports.c = G; exports.d = O; exports.e = Q; exports.f = D;
4
- //# sourceMappingURL=chunk-HO5BFEZO.cjs.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["/home/runner/work/codefast/codefast/packages/ui/dist/chunk-HO5BFEZO.cjs","../src/components/chart.tsx"],"names":["RechartsPrimitive","createContext","useChart","ChartContainer","children","className","id","ref","uniqueId","useId","chartId","jsx","ChartContext"],"mappings":"AAAA,22BAAY,CAAC,wDCKX,8BASUA,gFA4MM,+CAtMhB,IACA,CAAA,CAAA,CAAA,KAAM,CAAA,EACR,CAAA,IAwBqBC,CAAwC,OAE7D,CAAA,CAAA,CAAA,CAAA,kCAAA,IAASC,CAA8B,CACrC,SAAuC,CAAA,CAEvC,CAAA,CAAA,IACE,CAAA,CAAA,+BAAA,CAAA,CAAM,CAAA,EAAA,CAAI,CAAA,CAAA,CAAA,MAAM,IAAA,KAAA,CAAA,mDAgBpB,CAAA,CAAMC,OACD,CAAA,CAAA,IAAA,CAAA,CAAAC,+BAAAA,CAAU,CAAA,QAAAC,CAAAA,CAAW,CAAA,SAAQ,CAAA,CAAAC,CAAAA,MAAa,CAAGC,CAAAA,CAAAA,EAAQ,CACtD,CAAA,CAAA,GAAMC,CAAWC,CAAAA,CAAM,CAAA,CACjBC,EAAU,CAAA,IAAA,CAAA,CAAA,0BAAA,CAASJ,CAAAA,CAAME,CAAAA,CAAS,MAAA,EAAQ,CAAA,EAAA,CAAA,CAAM,OAEtD,CAAA,IAAA,CACEG,EAACC,CAAAA,CAAa,CAAA;AAgZG;AACvB","file":"/home/runner/work/codefast/codefast/packages/ui/dist/chunk-HO5BFEZO.cjs","sourcesContent":[null,"'use client';\n\nimport {\n type ComponentProps,\n type ComponentType,\n createContext,\n type CSSProperties,\n forwardRef,\n type JSX,\n type ReactNode,\n useContext,\n useId,\n useMemo,\n} from 'react';\nimport * as RechartsPrimitive from 'recharts';\nimport { type NameType, type Payload, type ValueType } from 'recharts/types/component/DefaultTooltipContent';\n\nimport { cn } from '@/lib/utils';\n\nconst THEMES = {\n light: '',\n dark: '.dark',\n} as const;\n\ntype Theme = keyof typeof THEMES;\n\ntype ChartConfig = {\n [k in string]: {\n icon?: ComponentType;\n label?: ReactNode;\n } & (\n | {\n color?: string;\n theme?: never;\n }\n | {\n theme: Record<Theme, string>;\n color?: never;\n }\n );\n};\n\ninterface ChartContextProps {\n config: ChartConfig;\n}\n\nconst ChartContext = createContext<ChartContextProps | null>(null);\n\nfunction useChart(): ChartContextProps {\n const context = useContext(ChartContext);\n\n if (!context) {\n throw new Error('useChart must be used within a <ChartContainer />');\n }\n\n return context;\n}\n\n/* -----------------------------------------------------------------------------\n * Component: Chart\n * -------------------------------------------------------------------------- */\n\ntype ChartContainerElement = HTMLDivElement;\ninterface ChartContainerProps extends ComponentProps<'div'> {\n children: ComponentProps<typeof RechartsPrimitive.ResponsiveContainer>['children'];\n config: ChartConfig;\n}\n\nconst ChartContainer = forwardRef<ChartContainerElement, ChartContainerProps>(\n ({ children, className, config, id, ...props }, ref) => {\n const uniqueId = useId();\n const chartId = `chart-${id || uniqueId.replace(/:/g, '')}`;\n\n return (\n <ChartContext.Provider value={{ config }}>\n <div\n ref={ref}\n className={cn(\n 'flex aspect-video justify-center text-xs',\n '[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground',\n '[&_.recharts-cartesian-grid_line]:stroke-border/50',\n '[&_.recharts-curve.recharts-tooltip-cursor]:stroke-border',\n '[&_.recharts-dot]:stroke-transparent',\n '[&_.recharts-layer]:outline-none',\n '[&_.recharts-polar-grid_]:stroke-border',\n '[&_.recharts-radial-bar-background-sector]:fill-muted',\n '[&_.recharts-reference-line_]:stroke-border',\n '[&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted',\n '[&_.recharts-sector]:outline-none',\n '[&_.recharts-sector]:stroke-transparent',\n '[&_.recharts-surface]:outline-none',\n className,\n )}\n data-chart={chartId}\n {...props}\n >\n <ChartStyle config={config} id={chartId} />\n <RechartsPrimitive.ResponsiveContainer>{children}</RechartsPrimitive.ResponsiveContainer>\n </div>\n </ChartContext.Provider>\n );\n },\n);\n\nChartContainer.displayName = 'Chart';\n\n/* -----------------------------------------------------------------------------\n * Component: ChartStyle\n * -------------------------------------------------------------------------- */\n\ninterface ChartStyleProps {\n config: ChartConfig;\n id: string;\n}\n\nfunction ChartStyle({ id, config }: ChartStyleProps): JSX.Element | null {\n const cssString = useMemo(() => generateCSS(id, config), [id, config]);\n\n return <style dangerouslySetInnerHTML={{ __html: cssString }} />;\n}\n\n/* -----------------------------------------------------------------------------\n * Component: ChartTooltip\n * -------------------------------------------------------------------------- */\n\ntype ChartTooltipProps = ComponentProps<typeof RechartsPrimitive.Tooltip>;\nconst ChartTooltip = RechartsPrimitive.Tooltip;\n\n/* -----------------------------------------------------------------------------\n * Component: ChartTooltipContent\n * -------------------------------------------------------------------------- */\n\ntype ChartTooltipContentElement = HTMLDivElement;\ninterface ChartTooltipContentProps\n extends ComponentProps<typeof RechartsPrimitive.Tooltip>,\n Omit<ComponentProps<'div'>, 'content'> {\n hideIndicator?: boolean;\n hideLabel?: boolean;\n indicator?: 'line' | 'dot' | 'dashed';\n labelKey?: string;\n nameKey?: string;\n}\n\nconst ChartTooltipContent = forwardRef<ChartTooltipContentElement, ChartTooltipContentProps>(\n (\n {\n active,\n className,\n color,\n formatter,\n hideIndicator = false,\n hideLabel = false,\n indicator = 'dot',\n label,\n labelClassName,\n labelFormatter,\n labelKey,\n nameKey,\n payload,\n },\n ref,\n ) => {\n const { config } = useChart();\n\n const tooltipLabel = useMemo(() => {\n if (hideLabel || !payload?.length) {\n return null;\n }\n\n const [item] = payload;\n\n const key = `${labelKey || item.dataKey || item.name || 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const value = !labelKey && typeof label === 'string' ? config[label].label || label : itemConfig?.label;\n\n if (labelFormatter) {\n return <div className={cn('font-medium', labelClassName)}>{labelFormatter(value, payload)}</div>;\n }\n\n if (!value) {\n return null;\n }\n\n return <div className={cn('font-medium', labelClassName)}>{value}</div>;\n }, [config, hideLabel, label, labelClassName, labelFormatter, labelKey, payload]);\n\n if (!active || !payload?.length) {\n return null;\n }\n\n const nestLabel = payload.length === 1 && indicator !== 'dot';\n\n return (\n <div\n ref={ref}\n className={cn(\n 'border-border/50 bg-background grid min-w-[8rem] items-start gap-1.5 rounded-lg border px-2.5 py-1.5 text-xs shadow-xl',\n className,\n )}\n >\n {!nestLabel ? tooltipLabel : null}\n <div className=\"grid gap-1.5\">\n {payload.map((item, index) => {\n const key = `${nameKey || item.name || item.dataKey || 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const indicatorColor = color || (item.payload as { fill?: string }).fill || item.color;\n\n return (\n <div\n key={item.dataKey}\n className={cn(\n '[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5',\n indicator === 'dot' && 'items-center',\n )}\n >\n {formatter && item.value !== undefined && item.name ? (\n formatter(item.value, item.name, item, index, item.payload as Payload<ValueType, NameType>[])\n ) : (\n <>\n {itemConfig?.icon ? (\n <itemConfig.icon />\n ) : (\n !hideIndicator && (\n <div\n className={cn('shrink-0 rounded-[2px] border-[--color-border] bg-[--color-bg]', {\n 'h-2.5 w-2.5': indicator === 'dot',\n 'w-1': indicator === 'line',\n 'w-0 border-[1.5px] border-dashed bg-transparent': indicator === 'dashed',\n 'my-0.5': nestLabel && indicator === 'dashed',\n })}\n style={\n {\n '--color-bg': indicatorColor,\n '--color-border': indicatorColor,\n } as CSSProperties\n }\n />\n )\n )}\n <div\n className={cn(\n 'flex flex-1 justify-between leading-none',\n nestLabel ? 'items-end' : 'items-center',\n )}\n >\n <div className=\"grid gap-1.5\">\n {nestLabel ? tooltipLabel : null}\n <span className=\"text-muted-foreground\">{itemConfig?.label || item.name}</span>\n </div>\n {item.value ? (\n <span className=\"text-foreground font-mono font-medium tabular-nums\">\n {item.value.toLocaleString()}\n </span>\n ) : null}\n </div>\n </>\n )}\n </div>\n );\n })}\n </div>\n </div>\n );\n },\n);\n\nChartTooltipContent.displayName = 'ChartTooltipContent';\n\n/* -----------------------------------------------------------------------------\n * Component: ChartLegend\n * -------------------------------------------------------------------------- */\n\ntype ChartLegendProps = ComponentProps<typeof RechartsPrimitive.Legend>;\nconst ChartLegend = RechartsPrimitive.Legend;\n\n/* -----------------------------------------------------------------------------\n * Component: ChartLegendContent\n * -------------------------------------------------------------------------- */\n\ntype ChartLegendContent = HTMLDivElement;\ninterface ChartLegendContentProps\n extends ComponentProps<'div'>,\n Pick<RechartsPrimitive.LegendProps, 'payload' | 'verticalAlign'> {\n hideIcon?: boolean;\n nameKey?: string;\n}\n\nconst ChartLegendContent = forwardRef<HTMLDivElement, ChartLegendContentProps>(\n ({ className, hideIcon = false, nameKey, payload, verticalAlign = 'bottom' }, ref) => {\n const { config } = useChart();\n\n if (!payload?.length) {\n return null;\n }\n\n return (\n <div\n ref={ref}\n className={cn('flex items-center justify-center gap-4', verticalAlign === 'top' ? 'pb-3' : 'pt-3', className)}\n >\n {payload.map((item) => {\n let key = 'value';\n\n if (nameKey) {\n key = nameKey;\n } else if (item.dataKey) {\n key = String(item.dataKey);\n }\n\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n\n return (\n <div\n key={String(item.value)}\n className={cn('[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:size-3')}\n >\n {itemConfig?.icon && !hideIcon ? (\n <itemConfig.icon />\n ) : (\n <div\n className=\"size-2 shrink-0 rounded\"\n style={{\n backgroundColor: item.color,\n }}\n />\n )}\n {itemConfig?.label}\n </div>\n );\n })}\n </div>\n );\n },\n);\n\nChartLegendContent.displayName = 'ChartLegendContent';\n\n/* -----------------------------------------------------------------------------\n * Helpers\n * -------------------------------------------------------------------------- */\n\n/**\n * Extracts and returns the appropriate configuration object from\n * the payload based on the specified key.\n *\n * @param config - The chart configuration object that contains various\n * settings.\n * @param payload - The payload object that might contain nested payload data.\n * @param key - The key used to retrieve the specific configuration from the\n * chart config.\n * @returns Returns a configuration object with optional properties `icon`,\n * `label`, `color` or `theme`, or `undefined` if the payload is invalid or\n * no configuration is found for the provided key.\n */\nfunction getPayloadConfigFromPayload(\n config: ChartConfig,\n payload: unknown,\n key: string,\n):\n | ({\n icon?: ComponentType;\n label?: ReactNode;\n } & {\n color?: string;\n theme?: never;\n })\n | ({\n icon?: ComponentType;\n label?: ReactNode;\n } & {\n theme: Record<Theme, string>;\n color?: never;\n })\n | undefined {\n if (!isValidObject(payload)) {\n return undefined;\n }\n\n const nestedPayload = 'payload' in payload && isValidObject(payload.payload) ? payload.payload : undefined;\n\n const configLabelKey = getConfigLabelKey(payload, nestedPayload, key);\n\n return configLabelKey in config ? config[configLabelKey] : config[key];\n}\n\n/**\n * Checks if the provided value is a valid object.\n *\n * @param obj - The value to check.\n * @returns - Returns true if the value is an object and not null, false\n * otherwise.\n */\nfunction isValidObject(obj: unknown): obj is Record<string, unknown> {\n return typeof obj === 'object' && obj !== null;\n}\n\n/**\n * Retrieves the configuration label key from either the payload or\n * nestedPayload. If the key exists in the payload and is a string, the\n * corresponding value is returned. Otherwise, if the key exists in the\n * nestedPayload and is a string, its value is returned. If the key is not\n * found as a string in either object, the key itself is returned.\n *\n * @param payload - The primary payload containing key-value pairs.\n * @param nestedPayload - An optional nested payload containing additional\n * key-value pairs.\n * @param key - The key to search for within the payload and nestedPayload.\n *\n * @returns The string value associated with the key if found; otherwise, the\n * key itself.\n */\nfunction getConfigLabelKey(\n payload: Record<string, unknown>,\n nestedPayload: Record<string, unknown> | undefined,\n key: string,\n): string {\n if (key in payload && typeof payload[key] === 'string') {\n return payload[key];\n }\n\n if (nestedPayload && key in nestedPayload && typeof nestedPayload[key] === 'string') {\n return nestedPayload[key];\n }\n\n return key;\n}\n\n/**\n * Generates CSS for a specified theme and chart configuration.\n *\n * @param theme - The theme to be used (for example, 'light', 'dark').\n * @param id - The unique identifier of the chart.\n * @param configEntries - A list of configuration entries, each containing a\n * key and a chart configuration.\n * @returns The generated CSS as a string.\n */\nfunction generateThemeCSS(theme: Theme, id: string, configEntries: [string, ChartConfig[string]][]): string {\n const rules: string[] = [];\n\n rules.push(`${THEMES[theme]} [data-chart=${id}] {`);\n\n configEntries.forEach(([key, itemConfig]) => {\n const color = itemConfig.theme?.[theme] || itemConfig.color;\n\n if (color) {\n rules.push(` --color-${key}: ${color};`);\n }\n });\n\n rules.push('}');\n\n return rules.join('\\n');\n}\n\n/**\n * Generates CSS styles for a chart based on the provided configuration and\n * themes.\n *\n * @param id - The unique identifier for the chart element.\n * @param config - Configuration object for the chart. This includes theme and\n * color settings.\n * @returns A string containing the generated CSS rules.\n */\nfunction generateCSS(id: string, config: ChartConfig): string {\n const themeOrColorConfig = Object.entries(config).filter(([_, { theme, color }]) => theme || color);\n\n const allRules: string[] = [];\n\n Object.keys(THEMES).forEach((theme) => {\n const themeCSS = generateThemeCSS(theme as Theme, id, themeOrColorConfig);\n\n allRules.push(themeCSS);\n });\n\n return allRules.join('\\n');\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n ChartContainer,\n ChartLegend,\n ChartLegendContent,\n ChartStyle,\n ChartTooltip,\n ChartTooltipContent,\n type ChartConfig,\n type ChartContainerProps,\n type ChartLegendContentProps,\n type ChartLegendProps,\n type ChartStyleProps,\n type ChartTooltipContentProps,\n type ChartTooltipProps,\n};\n"]}
@@ -1,2 +0,0 @@
1
- import{a as o}from"./chunk-VPYH6JWS.js";import*as e from"@radix-ui/react-tabs";import{forwardRef as n}from"react";import{jsx as r}from"react/jsx-runtime";var l=e.Root,a=n(({className:t,...i},s)=>r(e.List,{ref:s,className:o("bg-muted text-muted-foreground inline-flex h-10 items-center justify-center gap-1 rounded-md p-1",t),...i}));a.displayName=e.List.displayName;var p=n(({className:t,...i},s)=>r(e.Trigger,{ref:s,className:o("inline-flex items-center justify-center whitespace-nowrap rounded px-3 py-1.5 text-sm font-medium outline-transparent transition-all","data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm","focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2","disabled:pointer-events-none disabled:opacity-50",t),...i}));p.displayName=e.Trigger.displayName;var m=n(({className:t,...i},s)=>r(e.Content,{ref:s,className:o("mt-2 rounded-md","focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",t),...i}));m.displayName=e.Content.displayName;export{l as a,a as b,p as c,m as d};
2
- //# sourceMappingURL=chunk-OPRULC2F.js.map
@@ -1,4 +0,0 @@
1
- "use client";import{a as d}from"./chunk-VPYH6JWS.js";import{createContext as M,forwardRef as x,useContext as H,useId as K,useMemo as k}from"react";import*as f from"recharts";import{Fragment as X,jsx as i,jsxs as g}from"react/jsx-runtime";var N={light:"",dark:".dark"},_=M(null);function w(){let e=H(_);if(!e)throw new Error("useChart must be used within a <ChartContainer />");return e}var $=x(({children:e,className:n,config:t,id:o,...a},c)=>{let s=K(),l=`chart-${o||s.replace(/:/g,"")}`;return i(_.Provider,{value:{config:t},children:g("div",{ref:c,className:d("flex aspect-video justify-center text-xs","[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground","[&_.recharts-cartesian-grid_line]:stroke-border/50","[&_.recharts-curve.recharts-tooltip-cursor]:stroke-border","[&_.recharts-dot]:stroke-transparent","[&_.recharts-layer]:outline-none","[&_.recharts-polar-grid_]:stroke-border","[&_.recharts-radial-bar-background-sector]:fill-muted","[&_.recharts-reference-line_]:stroke-border","[&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted","[&_.recharts-sector]:outline-none","[&_.recharts-sector]:stroke-transparent","[&_.recharts-surface]:outline-none",n),"data-chart":l,...a,children:[i(I,{config:t,id:l}),i(f.ResponsiveContainer,{children:e})]})})});$.displayName="Chart";function I({id:e,config:n}){let t=k(()=>J(e,n),[e,n]);return i("style",{dangerouslySetInnerHTML:{__html:t}})}var Q=f.Tooltip,O=x(({active:e,className:n,color:t,formatter:o,hideIndicator:a=!1,hideLabel:c=!1,indicator:s="dot",label:l,labelClassName:p,labelFormatter:h,labelKey:y,nameKey:E,payload:u},j)=>{let{config:m}=w(),R=k(()=>{if(c||!u?.length)return null;let[r]=u,P=`${y||r.dataKey||r.name||"value"}`,b=T(m,r,P),C=!y&&typeof l=="string"?m[l].label||l:b?.label;return h?i("div",{className:d("font-medium",p),children:h(C,u)}):C?i("div",{className:d("font-medium",p),children:C}):null},[m,c,l,p,h,y,u]);if(!e||!u?.length)return null;let v=u.length===1&&s!=="dot";return g("div",{ref:j,className:d("border-border/50 bg-background grid min-w-[8rem] items-start gap-1.5 rounded-lg border px-2.5 py-1.5 text-xs shadow-xl",n),children:[v?null:R,i("div",{className:"grid gap-1.5",children:u.map((r,P)=>{let b=`${E||r.name||r.dataKey||"value"}`,C=T(m,r,b),S=t||r.payload.fill||r.color;return i("div",{className:d("[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5",s==="dot"&&"items-center"),children:o&&r.value!==void 0&&r.name?o(r.value,r.name,r,P,r.payload):g(X,{children:[C?.icon?i(C.icon,{}):!a&&i("div",{className:d("shrink-0 rounded-[2px] border-[--color-border] bg-[--color-bg]",{"h-2.5 w-2.5":s==="dot","w-1":s==="line","w-0 border-[1.5px] border-dashed bg-transparent":s==="dashed","my-0.5":v&&s==="dashed"}),style:{"--color-bg":S,"--color-border":S}}),g("div",{className:d("flex flex-1 justify-between leading-none",v?"items-end":"items-center"),children:[g("div",{className:"grid gap-1.5",children:[v?R:null,i("span",{className:"text-muted-foreground",children:C?.label||r.name})]}),r.value?i("span",{className:"text-foreground font-mono font-medium tabular-nums",children:r.value.toLocaleString()}):null]})]})},r.dataKey)})})]})});O.displayName="ChartTooltipContent";var U=f.Legend,D=x(({className:e,hideIcon:n=!1,nameKey:t,payload:o,verticalAlign:a="bottom"},c)=>{let{config:s}=w();return o?.length?i("div",{ref:c,className:d("flex items-center justify-center gap-4",a==="top"?"pb-3":"pt-3",e),children:o.map(l=>{let p="value";t?p=t:l.dataKey&&(p=String(l.dataKey));let h=T(s,l,p);return g("div",{className:d("[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:size-3"),children:[h?.icon&&!n?i(h.icon,{}):i("div",{className:"size-2 shrink-0 rounded",style:{backgroundColor:l.color}}),h?.label]},String(l.value))})}):null});D.displayName="ChartLegendContent";function T(e,n,t){if(!L(n))return;let o="payload"in n&&L(n.payload)?n.payload:void 0,a=V(n,o,t);return a in e?e[a]:e[t]}function L(e){return typeof e=="object"&&e!==null}function V(e,n,t){return t in e&&typeof e[t]=="string"?e[t]:n&&t in n&&typeof n[t]=="string"?n[t]:t}function z(e,n,t){let o=[];return o.push(`${N[e]} [data-chart=${n}] {`),t.forEach(([a,c])=>{let s=c.theme?.[e]||c.color;s&&o.push(` --color-${a}: ${s};`)}),o.push("}"),o.join(`
2
- `)}function J(e,n){let t=Object.entries(n).filter(([a,{theme:c,color:s}])=>c||s),o=[];return Object.keys(N).forEach(a=>{let c=z(a,e,t);o.push(c)}),o.join(`
3
- `)}export{$ as a,I as b,Q as c,O as d,U as e,D as f};
4
- //# sourceMappingURL=chunk-WNXJ2WHS.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/components/chart.tsx"],"names":["createContext","forwardRef","useContext","useId","useMemo","RechartsPrimitive","Fragment","jsx","jsxs","THEMES","ChartContext","useChart","context","ChartContainer","children","className","config","id","props","ref","uniqueId","chartId","cn","ChartStyle","cssString","generateCSS","ChartTooltip","ChartTooltipContent","active","color","formatter","hideIndicator","hideLabel","indicator","label","labelClassName","labelFormatter","labelKey","nameKey","payload","tooltipLabel","item","key","itemConfig","getPayloadConfigFromPayload","value","nestLabel","index","indicatorColor","ChartLegend","ChartLegendContent","hideIcon","verticalAlign","isValidObject","nestedPayload","configLabelKey","getConfigLabelKey","obj","generateThemeCSS","theme","configEntries","rules","themeOrColorConfig","_","allRules","themeCSS"],"mappings":"wCAEA,OAGE,iBAAAA,EAEA,cAAAC,EAGA,cAAAC,EACA,SAAAC,EACA,WAAAC,MACK,QACP,UAAYC,MAAuB,WA6D3B,OA+IU,YAAAC,EA1HR,OAAAC,EArBF,QAAAC,MAAA,oBAxDR,IAAMC,EAAS,CACb,MAAO,GACP,KAAM,OACR,EAwBMC,EAAeV,EAAwC,IAAI,EAEjE,SAASW,GAA8B,CACrC,IAAMC,EAAUV,EAAWQ,CAAY,EAEvC,GAAI,CAACE,EACH,MAAM,IAAI,MAAM,mDAAmD,EAGrE,OAAOA,CACT,CAYA,IAAMC,EAAiBZ,EACrB,CAAC,CAAE,SAAAa,EAAU,UAAAC,EAAW,OAAAC,EAAQ,GAAAC,EAAI,GAAGC,CAAM,EAAGC,IAAQ,CACtD,IAAMC,EAAWjB,EAAM,EACjBkB,EAAU,SAASJ,GAAMG,EAAS,QAAQ,KAAM,EAAE,CAAC,GAEzD,OACEb,EAACG,EAAa,SAAb,CAAsB,MAAO,CAAE,OAAAM,CAAO,EACrC,SAAAR,EAAC,OACC,IAAKW,EACL,UAAWG,EACT,2CACA,+DACA,qDACA,4DACA,uCACA,mCACA,0CACA,wDACA,8CACA,6DACA,oCACA,0CACA,qCACAP,CACF,EACA,aAAYM,EACX,GAAGH,EAEJ,UAAAX,EAACgB,EAAA,CAAW,OAAQP,EAAQ,GAAIK,EAAS,EACzCd,EAAmB,sBAAlB,CAAuC,SAAAO,EAAS,GACnD,EACF,CAEJ,CACF,EAEAD,EAAe,YAAc,QAW7B,SAASU,EAAW,CAAE,GAAAN,EAAI,OAAAD,CAAO,EAAwC,CACvE,IAAMQ,EAAYpB,EAAQ,IAAMqB,EAAYR,EAAID,CAAM,EAAG,CAACC,EAAID,CAAM,CAAC,EAErE,OAAOT,EAAC,SAAM,wBAAyB,CAAE,OAAQiB,CAAU,EAAG,CAChE,CAOA,IAAME,EAAiC,UAiBjCC,EAAsB1B,EAC1B,CACE,CACE,OAAA2B,EACA,UAAAb,EACA,MAAAc,EACA,UAAAC,EACA,cAAAC,EAAgB,GAChB,UAAAC,EAAY,GACZ,UAAAC,EAAY,MACZ,MAAAC,EACA,eAAAC,EACA,eAAAC,EACA,SAAAC,EACA,QAAAC,EACA,QAAAC,CACF,EACApB,IACG,CACH,GAAM,CAAE,OAAAH,CAAO,EAAIL,EAAS,EAEtB6B,EAAepC,EAAQ,IAAM,CACjC,GAAI4B,GAAa,CAACO,GAAS,OACzB,OAAO,KAGT,GAAM,CAACE,CAAI,EAAIF,EAETG,EAAM,GAAGL,GAAYI,EAAK,SAAWA,EAAK,MAAQ,OAAO,GACzDE,EAAaC,EAA4B5B,EAAQyB,EAAMC,CAAG,EAC1DG,EAAQ,CAACR,GAAY,OAAOH,GAAU,SAAWlB,EAAOkB,CAAK,EAAE,OAASA,EAAQS,GAAY,MAElG,OAAIP,EACK7B,EAAC,OAAI,UAAWe,EAAG,cAAea,CAAc,EAAI,SAAAC,EAAeS,EAAON,CAAO,EAAE,EAGvFM,EAIEtC,EAAC,OAAI,UAAWe,EAAG,cAAea,CAAc,EAAI,SAAAU,EAAM,EAHxD,IAIX,EAAG,CAAC7B,EAAQgB,EAAWE,EAAOC,EAAgBC,EAAgBC,EAAUE,CAAO,CAAC,EAEhF,GAAI,CAACX,GAAU,CAACW,GAAS,OACvB,OAAO,KAGT,IAAMO,EAAYP,EAAQ,SAAW,GAAKN,IAAc,MAExD,OACEzB,EAAC,OACC,IAAKW,EACL,UAAWG,EACT,yHACAP,CACF,EAEC,UAAC+B,EAA2B,KAAfN,EACdjC,EAAC,OAAI,UAAU,eACZ,SAAAgC,EAAQ,IAAI,CAACE,EAAMM,IAAU,CAC5B,IAAML,EAAM,GAAGJ,GAAWG,EAAK,MAAQA,EAAK,SAAW,OAAO,GACxDE,EAAaC,EAA4B5B,EAAQyB,EAAMC,CAAG,EAC1DM,EAAiBnB,GAAUY,EAAK,QAA8B,MAAQA,EAAK,MAEjF,OACElC,EAAC,OAEC,UAAWe,EACT,sGACAW,IAAc,OAAS,cACzB,EAEC,SAAAH,GAAaW,EAAK,QAAU,QAAaA,EAAK,KAC7CX,EAAUW,EAAK,MAAOA,EAAK,KAAMA,EAAMM,EAAON,EAAK,OAAyC,EAE5FjC,EAAAF,EAAA,CACG,UAAAqC,GAAY,KACXpC,EAACoC,EAAW,KAAX,EAAgB,EAEjB,CAACZ,GACCxB,EAAC,OACC,UAAWe,EAAG,iEAAkE,CAC9E,cAAeW,IAAc,MAC7B,MAAOA,IAAc,OACrB,kDAAmDA,IAAc,SACjE,SAAUa,GAAab,IAAc,QACvC,CAAC,EACD,MACE,CACE,aAAce,EACd,iBAAkBA,CACpB,EAEJ,EAGJxC,EAAC,OACC,UAAWc,EACT,2CACAwB,EAAY,YAAc,cAC5B,EAEA,UAAAtC,EAAC,OAAI,UAAU,eACZ,UAAAsC,EAAYN,EAAe,KAC5BjC,EAAC,QAAK,UAAU,wBAAyB,SAAAoC,GAAY,OAASF,EAAK,KAAK,GAC1E,EACCA,EAAK,MACJlC,EAAC,QAAK,UAAU,qDACb,SAAAkC,EAAK,MAAM,eAAe,EAC7B,EACE,MACN,GACF,GA9CGA,EAAK,OAgDZ,CAEJ,CAAC,EACH,GACF,CAEJ,CACF,EAEAd,EAAoB,YAAc,sBAOlC,IAAMsB,EAAgC,SAchCC,EAAqBjD,EACzB,CAAC,CAAE,UAAAc,EAAW,SAAAoC,EAAW,GAAO,QAAAb,EAAS,QAAAC,EAAS,cAAAa,EAAgB,QAAS,EAAGjC,IAAQ,CACpF,GAAM,CAAE,OAAAH,CAAO,EAAIL,EAAS,EAE5B,OAAK4B,GAAS,OAKZhC,EAAC,OACC,IAAKY,EACL,UAAWG,EAAG,yCAA0C8B,IAAkB,MAAQ,OAAS,OAAQrC,CAAS,EAE3G,SAAAwB,EAAQ,IAAKE,GAAS,CACrB,IAAIC,EAAM,QAENJ,EACFI,EAAMJ,EACGG,EAAK,UACdC,EAAM,OAAOD,EAAK,OAAO,GAG3B,IAAME,EAAaC,EAA4B5B,EAAQyB,EAAMC,CAAG,EAEhE,OACElC,EAAC,OAEC,UAAWc,EAAG,wEAAwE,EAErF,UAAAqB,GAAY,MAAQ,CAACQ,EACpB5C,EAACoC,EAAW,KAAX,EAAgB,EAEjBpC,EAAC,OACC,UAAU,0BACV,MAAO,CACL,gBAAiBkC,EAAK,KACxB,EACF,EAEDE,GAAY,QAbR,OAAOF,EAAK,KAAK,CAcxB,CAEJ,CAAC,EACH,EAtCO,IAwCX,CACF,EAEAS,EAAmB,YAAc,qBAmBjC,SAASN,EACP5B,EACAuB,EACAG,EAgBY,CACZ,GAAI,CAACW,EAAcd,CAAO,EACxB,OAGF,IAAMe,EAAgB,YAAaf,GAAWc,EAAcd,EAAQ,OAAO,EAAIA,EAAQ,QAAU,OAE3FgB,EAAiBC,EAAkBjB,EAASe,EAAeZ,CAAG,EAEpE,OAAOa,KAAkBvC,EAASA,EAAOuC,CAAc,EAAIvC,EAAO0B,CAAG,CACvE,CASA,SAASW,EAAcI,EAA8C,CACnE,OAAO,OAAOA,GAAQ,UAAYA,IAAQ,IAC5C,CAiBA,SAASD,EACPjB,EACAe,EACAZ,EACQ,CACR,OAAIA,KAAOH,GAAW,OAAOA,EAAQG,CAAG,GAAM,SACrCH,EAAQG,CAAG,EAGhBY,GAAiBZ,KAAOY,GAAiB,OAAOA,EAAcZ,CAAG,GAAM,SAClEY,EAAcZ,CAAG,EAGnBA,CACT,CAWA,SAASgB,EAAiBC,EAAc1C,EAAY2C,EAAwD,CAC1G,IAAMC,EAAkB,CAAC,EAEzB,OAAAA,EAAM,KAAK,GAAGpD,EAAOkD,CAAK,CAAC,gBAAgB1C,CAAE,KAAK,EAElD2C,EAAc,QAAQ,CAAC,CAAClB,EAAKC,CAAU,IAAM,CAC3C,IAAMd,EAAQc,EAAW,QAAQgB,CAAK,GAAKhB,EAAW,MAElDd,GACFgC,EAAM,KAAK,aAAanB,CAAG,KAAKb,CAAK,GAAG,CAE5C,CAAC,EAEDgC,EAAM,KAAK,GAAG,EAEPA,EAAM,KAAK;AAAA,CAAI,CACxB,CAWA,SAASpC,EAAYR,EAAYD,EAA6B,CAC5D,IAAM8C,EAAqB,OAAO,QAAQ9C,CAAM,EAAE,OAAO,CAAC,CAAC+C,EAAG,CAAE,MAAAJ,EAAO,MAAA9B,CAAM,CAAC,IAAM8B,GAAS9B,CAAK,EAE5FmC,EAAqB,CAAC,EAE5B,cAAO,KAAKvD,CAAM,EAAE,QAASkD,GAAU,CACrC,IAAMM,EAAWP,EAAiBC,EAAgB1C,EAAI6C,CAAkB,EAExEE,EAAS,KAAKC,CAAQ,CACxB,CAAC,EAEMD,EAAS,KAAK;AAAA,CAAI,CAC3B","sourcesContent":["'use client';\n\nimport {\n type ComponentProps,\n type ComponentType,\n createContext,\n type CSSProperties,\n forwardRef,\n type JSX,\n type ReactNode,\n useContext,\n useId,\n useMemo,\n} from 'react';\nimport * as RechartsPrimitive from 'recharts';\nimport { type NameType, type Payload, type ValueType } from 'recharts/types/component/DefaultTooltipContent';\n\nimport { cn } from '@/lib/utils';\n\nconst THEMES = {\n light: '',\n dark: '.dark',\n} as const;\n\ntype Theme = keyof typeof THEMES;\n\ntype ChartConfig = {\n [k in string]: {\n icon?: ComponentType;\n label?: ReactNode;\n } & (\n | {\n color?: string;\n theme?: never;\n }\n | {\n theme: Record<Theme, string>;\n color?: never;\n }\n );\n};\n\ninterface ChartContextProps {\n config: ChartConfig;\n}\n\nconst ChartContext = createContext<ChartContextProps | null>(null);\n\nfunction useChart(): ChartContextProps {\n const context = useContext(ChartContext);\n\n if (!context) {\n throw new Error('useChart must be used within a <ChartContainer />');\n }\n\n return context;\n}\n\n/* -----------------------------------------------------------------------------\n * Component: Chart\n * -------------------------------------------------------------------------- */\n\ntype ChartContainerElement = HTMLDivElement;\ninterface ChartContainerProps extends ComponentProps<'div'> {\n children: ComponentProps<typeof RechartsPrimitive.ResponsiveContainer>['children'];\n config: ChartConfig;\n}\n\nconst ChartContainer = forwardRef<ChartContainerElement, ChartContainerProps>(\n ({ children, className, config, id, ...props }, ref) => {\n const uniqueId = useId();\n const chartId = `chart-${id || uniqueId.replace(/:/g, '')}`;\n\n return (\n <ChartContext.Provider value={{ config }}>\n <div\n ref={ref}\n className={cn(\n 'flex aspect-video justify-center text-xs',\n '[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground',\n '[&_.recharts-cartesian-grid_line]:stroke-border/50',\n '[&_.recharts-curve.recharts-tooltip-cursor]:stroke-border',\n '[&_.recharts-dot]:stroke-transparent',\n '[&_.recharts-layer]:outline-none',\n '[&_.recharts-polar-grid_]:stroke-border',\n '[&_.recharts-radial-bar-background-sector]:fill-muted',\n '[&_.recharts-reference-line_]:stroke-border',\n '[&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted',\n '[&_.recharts-sector]:outline-none',\n '[&_.recharts-sector]:stroke-transparent',\n '[&_.recharts-surface]:outline-none',\n className,\n )}\n data-chart={chartId}\n {...props}\n >\n <ChartStyle config={config} id={chartId} />\n <RechartsPrimitive.ResponsiveContainer>{children}</RechartsPrimitive.ResponsiveContainer>\n </div>\n </ChartContext.Provider>\n );\n },\n);\n\nChartContainer.displayName = 'Chart';\n\n/* -----------------------------------------------------------------------------\n * Component: ChartStyle\n * -------------------------------------------------------------------------- */\n\ninterface ChartStyleProps {\n config: ChartConfig;\n id: string;\n}\n\nfunction ChartStyle({ id, config }: ChartStyleProps): JSX.Element | null {\n const cssString = useMemo(() => generateCSS(id, config), [id, config]);\n\n return <style dangerouslySetInnerHTML={{ __html: cssString }} />;\n}\n\n/* -----------------------------------------------------------------------------\n * Component: ChartTooltip\n * -------------------------------------------------------------------------- */\n\ntype ChartTooltipProps = ComponentProps<typeof RechartsPrimitive.Tooltip>;\nconst ChartTooltip = RechartsPrimitive.Tooltip;\n\n/* -----------------------------------------------------------------------------\n * Component: ChartTooltipContent\n * -------------------------------------------------------------------------- */\n\ntype ChartTooltipContentElement = HTMLDivElement;\ninterface ChartTooltipContentProps\n extends ComponentProps<typeof RechartsPrimitive.Tooltip>,\n Omit<ComponentProps<'div'>, 'content'> {\n hideIndicator?: boolean;\n hideLabel?: boolean;\n indicator?: 'line' | 'dot' | 'dashed';\n labelKey?: string;\n nameKey?: string;\n}\n\nconst ChartTooltipContent = forwardRef<ChartTooltipContentElement, ChartTooltipContentProps>(\n (\n {\n active,\n className,\n color,\n formatter,\n hideIndicator = false,\n hideLabel = false,\n indicator = 'dot',\n label,\n labelClassName,\n labelFormatter,\n labelKey,\n nameKey,\n payload,\n },\n ref,\n ) => {\n const { config } = useChart();\n\n const tooltipLabel = useMemo(() => {\n if (hideLabel || !payload?.length) {\n return null;\n }\n\n const [item] = payload;\n\n const key = `${labelKey || item.dataKey || item.name || 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const value = !labelKey && typeof label === 'string' ? config[label].label || label : itemConfig?.label;\n\n if (labelFormatter) {\n return <div className={cn('font-medium', labelClassName)}>{labelFormatter(value, payload)}</div>;\n }\n\n if (!value) {\n return null;\n }\n\n return <div className={cn('font-medium', labelClassName)}>{value}</div>;\n }, [config, hideLabel, label, labelClassName, labelFormatter, labelKey, payload]);\n\n if (!active || !payload?.length) {\n return null;\n }\n\n const nestLabel = payload.length === 1 && indicator !== 'dot';\n\n return (\n <div\n ref={ref}\n className={cn(\n 'border-border/50 bg-background grid min-w-[8rem] items-start gap-1.5 rounded-lg border px-2.5 py-1.5 text-xs shadow-xl',\n className,\n )}\n >\n {!nestLabel ? tooltipLabel : null}\n <div className=\"grid gap-1.5\">\n {payload.map((item, index) => {\n const key = `${nameKey || item.name || item.dataKey || 'value'}`;\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n const indicatorColor = color || (item.payload as { fill?: string }).fill || item.color;\n\n return (\n <div\n key={item.dataKey}\n className={cn(\n '[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5',\n indicator === 'dot' && 'items-center',\n )}\n >\n {formatter && item.value !== undefined && item.name ? (\n formatter(item.value, item.name, item, index, item.payload as Payload<ValueType, NameType>[])\n ) : (\n <>\n {itemConfig?.icon ? (\n <itemConfig.icon />\n ) : (\n !hideIndicator && (\n <div\n className={cn('shrink-0 rounded-[2px] border-[--color-border] bg-[--color-bg]', {\n 'h-2.5 w-2.5': indicator === 'dot',\n 'w-1': indicator === 'line',\n 'w-0 border-[1.5px] border-dashed bg-transparent': indicator === 'dashed',\n 'my-0.5': nestLabel && indicator === 'dashed',\n })}\n style={\n {\n '--color-bg': indicatorColor,\n '--color-border': indicatorColor,\n } as CSSProperties\n }\n />\n )\n )}\n <div\n className={cn(\n 'flex flex-1 justify-between leading-none',\n nestLabel ? 'items-end' : 'items-center',\n )}\n >\n <div className=\"grid gap-1.5\">\n {nestLabel ? tooltipLabel : null}\n <span className=\"text-muted-foreground\">{itemConfig?.label || item.name}</span>\n </div>\n {item.value ? (\n <span className=\"text-foreground font-mono font-medium tabular-nums\">\n {item.value.toLocaleString()}\n </span>\n ) : null}\n </div>\n </>\n )}\n </div>\n );\n })}\n </div>\n </div>\n );\n },\n);\n\nChartTooltipContent.displayName = 'ChartTooltipContent';\n\n/* -----------------------------------------------------------------------------\n * Component: ChartLegend\n * -------------------------------------------------------------------------- */\n\ntype ChartLegendProps = ComponentProps<typeof RechartsPrimitive.Legend>;\nconst ChartLegend = RechartsPrimitive.Legend;\n\n/* -----------------------------------------------------------------------------\n * Component: ChartLegendContent\n * -------------------------------------------------------------------------- */\n\ntype ChartLegendContent = HTMLDivElement;\ninterface ChartLegendContentProps\n extends ComponentProps<'div'>,\n Pick<RechartsPrimitive.LegendProps, 'payload' | 'verticalAlign'> {\n hideIcon?: boolean;\n nameKey?: string;\n}\n\nconst ChartLegendContent = forwardRef<HTMLDivElement, ChartLegendContentProps>(\n ({ className, hideIcon = false, nameKey, payload, verticalAlign = 'bottom' }, ref) => {\n const { config } = useChart();\n\n if (!payload?.length) {\n return null;\n }\n\n return (\n <div\n ref={ref}\n className={cn('flex items-center justify-center gap-4', verticalAlign === 'top' ? 'pb-3' : 'pt-3', className)}\n >\n {payload.map((item) => {\n let key = 'value';\n\n if (nameKey) {\n key = nameKey;\n } else if (item.dataKey) {\n key = String(item.dataKey);\n }\n\n const itemConfig = getPayloadConfigFromPayload(config, item, key);\n\n return (\n <div\n key={String(item.value)}\n className={cn('[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:size-3')}\n >\n {itemConfig?.icon && !hideIcon ? (\n <itemConfig.icon />\n ) : (\n <div\n className=\"size-2 shrink-0 rounded\"\n style={{\n backgroundColor: item.color,\n }}\n />\n )}\n {itemConfig?.label}\n </div>\n );\n })}\n </div>\n );\n },\n);\n\nChartLegendContent.displayName = 'ChartLegendContent';\n\n/* -----------------------------------------------------------------------------\n * Helpers\n * -------------------------------------------------------------------------- */\n\n/**\n * Extracts and returns the appropriate configuration object from\n * the payload based on the specified key.\n *\n * @param config - The chart configuration object that contains various\n * settings.\n * @param payload - The payload object that might contain nested payload data.\n * @param key - The key used to retrieve the specific configuration from the\n * chart config.\n * @returns Returns a configuration object with optional properties `icon`,\n * `label`, `color` or `theme`, or `undefined` if the payload is invalid or\n * no configuration is found for the provided key.\n */\nfunction getPayloadConfigFromPayload(\n config: ChartConfig,\n payload: unknown,\n key: string,\n):\n | ({\n icon?: ComponentType;\n label?: ReactNode;\n } & {\n color?: string;\n theme?: never;\n })\n | ({\n icon?: ComponentType;\n label?: ReactNode;\n } & {\n theme: Record<Theme, string>;\n color?: never;\n })\n | undefined {\n if (!isValidObject(payload)) {\n return undefined;\n }\n\n const nestedPayload = 'payload' in payload && isValidObject(payload.payload) ? payload.payload : undefined;\n\n const configLabelKey = getConfigLabelKey(payload, nestedPayload, key);\n\n return configLabelKey in config ? config[configLabelKey] : config[key];\n}\n\n/**\n * Checks if the provided value is a valid object.\n *\n * @param obj - The value to check.\n * @returns - Returns true if the value is an object and not null, false\n * otherwise.\n */\nfunction isValidObject(obj: unknown): obj is Record<string, unknown> {\n return typeof obj === 'object' && obj !== null;\n}\n\n/**\n * Retrieves the configuration label key from either the payload or\n * nestedPayload. If the key exists in the payload and is a string, the\n * corresponding value is returned. Otherwise, if the key exists in the\n * nestedPayload and is a string, its value is returned. If the key is not\n * found as a string in either object, the key itself is returned.\n *\n * @param payload - The primary payload containing key-value pairs.\n * @param nestedPayload - An optional nested payload containing additional\n * key-value pairs.\n * @param key - The key to search for within the payload and nestedPayload.\n *\n * @returns The string value associated with the key if found; otherwise, the\n * key itself.\n */\nfunction getConfigLabelKey(\n payload: Record<string, unknown>,\n nestedPayload: Record<string, unknown> | undefined,\n key: string,\n): string {\n if (key in payload && typeof payload[key] === 'string') {\n return payload[key];\n }\n\n if (nestedPayload && key in nestedPayload && typeof nestedPayload[key] === 'string') {\n return nestedPayload[key];\n }\n\n return key;\n}\n\n/**\n * Generates CSS for a specified theme and chart configuration.\n *\n * @param theme - The theme to be used (for example, 'light', 'dark').\n * @param id - The unique identifier of the chart.\n * @param configEntries - A list of configuration entries, each containing a\n * key and a chart configuration.\n * @returns The generated CSS as a string.\n */\nfunction generateThemeCSS(theme: Theme, id: string, configEntries: [string, ChartConfig[string]][]): string {\n const rules: string[] = [];\n\n rules.push(`${THEMES[theme]} [data-chart=${id}] {`);\n\n configEntries.forEach(([key, itemConfig]) => {\n const color = itemConfig.theme?.[theme] || itemConfig.color;\n\n if (color) {\n rules.push(` --color-${key}: ${color};`);\n }\n });\n\n rules.push('}');\n\n return rules.join('\\n');\n}\n\n/**\n * Generates CSS styles for a chart based on the provided configuration and\n * themes.\n *\n * @param id - The unique identifier for the chart element.\n * @param config - Configuration object for the chart. This includes theme and\n * color settings.\n * @returns A string containing the generated CSS rules.\n */\nfunction generateCSS(id: string, config: ChartConfig): string {\n const themeOrColorConfig = Object.entries(config).filter(([_, { theme, color }]) => theme || color);\n\n const allRules: string[] = [];\n\n Object.keys(THEMES).forEach((theme) => {\n const themeCSS = generateThemeCSS(theme as Theme, id, themeOrColorConfig);\n\n allRules.push(themeCSS);\n });\n\n return allRules.join('\\n');\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n ChartContainer,\n ChartLegend,\n ChartLegendContent,\n ChartStyle,\n ChartTooltip,\n ChartTooltipContent,\n type ChartConfig,\n type ChartContainerProps,\n type ChartLegendContentProps,\n type ChartLegendProps,\n type ChartStyleProps,\n type ChartTooltipContentProps,\n type ChartTooltipProps,\n};\n"]}