ml-uikit 1.1.0 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/ui/alert.d.ts +8 -2
- package/dist/components/ui/alert.d.ts.map +1 -1
- package/dist/components/ui/badge.d.ts +1 -1
- package/dist/components/ui/button.d.ts.map +1 -1
- package/dist/components/ui/checkbox.d.ts.map +1 -1
- package/dist/components/ui/icon-button.d.ts +9 -0
- package/dist/components/ui/icon-button.d.ts.map +1 -0
- package/dist/components/ui/input-group.d.ts.map +1 -1
- package/dist/components/ui/radio-group.d.ts.map +1 -1
- package/dist/components/ui/select.d.ts.map +1 -1
- package/dist/components/ui/sidebar.d.ts.map +1 -1
- package/dist/components/ui/slider.d.ts.map +1 -1
- package/dist/components/ui/switch.d.ts.map +1 -1
- package/dist/components/ui/tabs.d.ts.map +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.cjs10.js +1 -1
- package/dist/index.cjs10.js.map +1 -1
- package/dist/index.cjs11.js +1 -1
- package/dist/index.cjs11.js.map +1 -1
- package/dist/index.cjs12.js +1 -1
- package/dist/index.cjs12.js.map +1 -1
- package/dist/index.cjs13.js +1 -1
- package/dist/index.cjs13.js.map +1 -1
- package/dist/index.cjs14.js +1 -1
- package/dist/index.cjs14.js.map +1 -1
- package/dist/index.cjs15.js +1 -7
- package/dist/index.cjs15.js.map +1 -1
- package/dist/index.cjs16.js +7 -1
- package/dist/index.cjs16.js.map +1 -1
- package/dist/index.cjs17.js +1 -1
- package/dist/index.cjs17.js.map +1 -1
- package/dist/index.cjs18.js +1 -1
- package/dist/index.cjs18.js.map +1 -1
- package/dist/index.cjs19.js +1 -1
- package/dist/index.cjs19.js.map +1 -1
- package/dist/index.cjs2.js +1 -1
- package/dist/index.cjs20.js +1 -1
- package/dist/index.cjs20.js.map +1 -1
- package/dist/index.cjs21.js +1 -1
- package/dist/index.cjs21.js.map +1 -1
- package/dist/index.cjs22.js +1 -1
- package/dist/index.cjs22.js.map +1 -1
- package/dist/index.cjs23.js +1 -1
- package/dist/index.cjs23.js.map +1 -1
- package/dist/index.cjs24.js +1 -1
- package/dist/index.cjs24.js.map +1 -1
- package/dist/index.cjs25.js +1 -1
- package/dist/index.cjs25.js.map +1 -1
- package/dist/index.cjs26.js +1 -1
- package/dist/index.cjs26.js.map +1 -1
- package/dist/index.cjs27.js +1 -1
- package/dist/index.cjs27.js.map +1 -1
- package/dist/index.cjs28.js +1 -1
- package/dist/index.cjs28.js.map +1 -1
- package/dist/index.cjs29.js +1 -1
- package/dist/index.cjs29.js.map +1 -1
- package/dist/index.cjs3.js +1 -1
- package/dist/index.cjs30.js +1 -1
- package/dist/index.cjs30.js.map +1 -1
- package/dist/index.cjs31.js +1 -1
- package/dist/index.cjs31.js.map +1 -1
- package/dist/index.cjs32.js +1 -1
- package/dist/index.cjs32.js.map +1 -1
- package/dist/index.cjs33.js +1 -1
- package/dist/index.cjs33.js.map +1 -1
- package/dist/index.cjs34.js +1 -1
- package/dist/index.cjs34.js.map +1 -1
- package/dist/index.cjs35.js +1 -1
- package/dist/index.cjs35.js.map +1 -1
- package/dist/index.cjs36.js +1 -1
- package/dist/index.cjs36.js.map +1 -1
- package/dist/index.cjs37.js +1 -1
- package/dist/index.cjs37.js.map +1 -1
- package/dist/index.cjs38.js +1 -1
- package/dist/index.cjs38.js.map +1 -1
- package/dist/index.cjs39.js +1 -1
- package/dist/index.cjs39.js.map +1 -1
- package/dist/index.cjs4.js +1 -1
- package/dist/index.cjs4.js.map +1 -1
- package/dist/index.cjs40.js +1 -1
- package/dist/index.cjs40.js.map +1 -1
- package/dist/index.cjs41.js +1 -1
- package/dist/index.cjs41.js.map +1 -1
- package/dist/index.cjs42.js +1 -1
- package/dist/index.cjs42.js.map +1 -1
- package/dist/index.cjs43.js +1 -1
- package/dist/index.cjs43.js.map +1 -1
- package/dist/index.cjs44.js +1 -1
- package/dist/index.cjs44.js.map +1 -1
- package/dist/index.cjs45.js +1 -1
- package/dist/index.cjs45.js.map +1 -1
- package/dist/index.cjs46.js +1 -1
- package/dist/index.cjs46.js.map +1 -1
- package/dist/index.cjs47.js +1 -1
- package/dist/index.cjs47.js.map +1 -1
- package/dist/index.cjs48.js +1 -1
- package/dist/index.cjs48.js.map +1 -1
- package/dist/index.cjs49.js +1 -1
- package/dist/index.cjs49.js.map +1 -1
- package/dist/index.cjs5.js +1 -1
- package/dist/index.cjs50.js +1 -1
- package/dist/index.cjs50.js.map +1 -1
- package/dist/index.cjs51.js +1 -1
- package/dist/index.cjs51.js.map +1 -1
- package/dist/index.cjs52.js +1 -1
- package/dist/index.cjs52.js.map +1 -1
- package/dist/index.cjs53.js +1 -1
- package/dist/index.cjs53.js.map +1 -1
- package/dist/index.cjs54.js +1 -1
- package/dist/index.cjs54.js.map +1 -1
- package/dist/index.cjs55.js +1 -1
- package/dist/index.cjs55.js.map +1 -1
- package/dist/index.cjs56.js +1 -1
- package/dist/index.cjs56.js.map +1 -1
- package/dist/index.cjs57.js +1 -1
- package/dist/index.cjs57.js.map +1 -1
- package/dist/index.cjs7.js +1 -1
- package/dist/index.cjs8.js +1 -1
- package/dist/index.cjs9.js +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.es.js +321 -312
- package/dist/index.es.js.map +1 -1
- package/dist/index.es10.js +27 -27
- package/dist/index.es10.js.map +1 -1
- package/dist/index.es11.js +19 -72
- package/dist/index.es11.js.map +1 -1
- package/dist/index.es12.js +62 -157
- package/dist/index.es12.js.map +1 -1
- package/dist/index.es13.js +169 -58
- package/dist/index.es13.js.map +1 -1
- package/dist/index.es14.js +55 -157
- package/dist/index.es14.js.map +1 -1
- package/dist/index.es15.js +150 -181
- package/dist/index.es15.js.map +1 -1
- package/dist/index.es16.js +188 -21
- package/dist/index.es16.js.map +1 -1
- package/dist/index.es17.js +31 -5
- package/dist/index.es17.js.map +1 -1
- package/dist/index.es18.js +5 -103
- package/dist/index.es18.js.map +1 -1
- package/dist/index.es19.js +70 -103
- package/dist/index.es19.js.map +1 -1
- package/dist/index.es2.js +1 -1
- package/dist/index.es20.js +108 -61
- package/dist/index.es20.js.map +1 -1
- package/dist/index.es21.js +59 -60
- package/dist/index.es21.js.map +1 -1
- package/dist/index.es22.js +69 -114
- package/dist/index.es22.js.map +1 -1
- package/dist/index.es23.js +132 -97
- package/dist/index.es23.js.map +1 -1
- package/dist/index.es24.js +49 -156
- package/dist/index.es24.js.map +1 -1
- package/dist/index.es25.js +194 -76
- package/dist/index.es25.js.map +1 -1
- package/dist/index.es26.js +89 -20
- package/dist/index.es26.js.map +1 -1
- package/dist/index.es27.js +20 -22
- package/dist/index.es27.js.map +1 -1
- package/dist/index.es28.js +17 -144
- package/dist/index.es28.js.map +1 -1
- package/dist/index.es29.js +145 -37
- package/dist/index.es29.js.map +1 -1
- package/dist/index.es3.js +1 -1
- package/dist/index.es30.js +37 -179
- package/dist/index.es30.js.map +1 -1
- package/dist/index.es31.js +174 -18
- package/dist/index.es31.js.map +1 -1
- package/dist/index.es32.js +29 -16
- package/dist/index.es32.js.map +1 -1
- package/dist/index.es33.js +15 -92
- package/dist/index.es33.js.map +1 -1
- package/dist/index.es34.js +91 -189
- package/dist/index.es34.js.map +1 -1
- package/dist/index.es35.js +165 -71
- package/dist/index.es35.js.map +1 -1
- package/dist/index.es36.js +85 -84
- package/dist/index.es36.js.map +1 -1
- package/dist/index.es37.js +92 -17
- package/dist/index.es37.js.map +1 -1
- package/dist/index.es38.js +19 -21
- package/dist/index.es38.js.map +1 -1
- package/dist/index.es39.js +16 -21
- package/dist/index.es39.js.map +1 -1
- package/dist/index.es4.js +65 -26
- package/dist/index.es4.js.map +1 -1
- package/dist/index.es40.js +22 -25
- package/dist/index.es40.js.map +1 -1
- package/dist/index.es41.js +25 -104
- package/dist/index.es41.js.map +1 -1
- package/dist/index.es42.js +117 -20
- package/dist/index.es42.js.map +1 -1
- package/dist/index.es43.js +19 -97
- package/dist/index.es43.js.map +1 -1
- package/dist/index.es44.js +77 -509
- package/dist/index.es44.js.map +1 -1
- package/dist/index.es45.js +552 -11
- package/dist/index.es45.js.map +1 -1
- package/dist/index.es46.js +15 -18
- package/dist/index.es46.js.map +1 -1
- package/dist/index.es47.js +44 -19
- package/dist/index.es47.js.map +1 -1
- package/dist/index.es48.js +19 -12
- package/dist/index.es48.js.map +1 -1
- package/dist/index.es49.js +13 -22
- package/dist/index.es49.js.map +1 -1
- package/dist/index.es5.js +1 -1
- package/dist/index.es50.js +23 -197
- package/dist/index.es50.js.map +1 -1
- package/dist/index.es51.js +191 -28
- package/dist/index.es51.js.map +1 -1
- package/dist/index.es52.js +45 -14
- package/dist/index.es52.js.map +1 -1
- package/dist/index.es53.js +12 -28
- package/dist/index.es53.js.map +1 -1
- package/dist/index.es54.js +30 -34
- package/dist/index.es54.js.map +1 -1
- package/dist/index.es55.js +37 -19
- package/dist/index.es55.js.map +1 -1
- package/dist/index.es56.js +20 -6
- package/dist/index.es56.js.map +1 -1
- package/dist/index.es57.js +5 -11
- package/dist/index.es57.js.map +1 -1
- package/dist/index.es7.js +1 -1
- package/dist/index.es8.js +1 -1
- package/dist/index.es9.js +1 -1
- package/dist/style.css +436 -172
- package/package.json +1 -1
- package/dist/hooks/use-mobile.d.ts +0 -2
- package/dist/hooks/use-mobile.d.ts.map +0 -1
package/dist/index.cjs40.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs40.js","sources":["../src/components/ui/
|
|
1
|
+
{"version":3,"file":"index.cjs40.js","sources":["../src/components/ui/radio-group.tsx"],"sourcesContent":["import * as React from \"react\"\nimport * as RadioGroupPrimitive from \"@radix-ui/react-radio-group\"\n\nimport { cn } from \"@/lib/utils\"\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef<typeof RadioGroupPrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Root>\n>(({ className, ...props }, ref) => {\n return (\n <RadioGroupPrimitive.Root\n className={cn(\"grid gap-2\", className)}\n {...props}\n ref={ref}\n />\n )\n})\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef<typeof RadioGroupPrimitive.Item>,\n React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Item>\n>(({ className, ...props }, ref) => {\n return (\n <RadioGroupPrimitive.Item\n ref={ref}\n className={cn(\n \"relative flex h-4 w-4 items-center justify-center rounded-full border border-[#e6e6e6] bg-white text-[#26453f] transition-colors\",\n \"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[#111111] focus-visible:ring-offset-2\",\n \"disabled:cursor-not-allowed disabled:bg-[#f2f2f2] disabled:border-[#e6e6e6] disabled:text-[#bdbdbd]\",\n \"data-[state=checked]:border-[#26453f]\",\n className\n )}\n {...props}\n >\n <RadioGroupPrimitive.Indicator className=\"flex items-center justify-center\">\n <span className=\"h-2.5 w-2.5 rounded-full bg-current\" />\n </RadioGroupPrimitive.Indicator>\n </RadioGroupPrimitive.Item>\n )\n})\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName\n\nexport { RadioGroup, RadioGroupItem }\n"],"names":["RadioGroup","React","className","props","ref","RadioGroupPrimitive","cn","RadioGroupItem"],"mappings":"idAKMA,EAAaC,EAAM,WAGvB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAA,EAASC,IAExBH,EAAA,cAACI,EAAoB,KAApB,CACC,UAAWC,EAAAA,GAAG,aAAcJ,CAAS,EACpC,GAAGC,EACJ,IAAAC,CAAA,CAAA,CAGL,EACDJ,EAAW,YAAcK,EAAoB,KAAK,YAElD,MAAME,EAAiBN,EAAM,WAG3B,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAA,EAASC,IAExBH,EAAA,cAACI,EAAoB,KAApB,CACC,IAAAD,EACA,UAAWE,EAAAA,GACT,mIACA,2GACA,sGACA,wCACAJ,CAAA,EAED,GAAGC,CAAA,EAEJF,EAAA,cAACI,EAAoB,UAApB,CAA8B,UAAU,oCACvCJ,EAAA,cAAC,OAAA,CAAK,UAAU,qCAAA,CAAsC,CACxD,CAAA,CAGL,EACDM,EAAe,YAAcF,EAAoB,KAAK"}
|
package/dist/index.cjs41.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("react"),d=require("@radix-ui/react-scroll-area"),n=require("./index.cjs57.js");function s(e){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const l in e)if(l!=="default"){const o=Object.getOwnPropertyDescriptor(e,l);Object.defineProperty(r,l,o.get?o:{enumerable:!0,get:()=>e[l]})}}return r.default=e,Object.freeze(r)}const t=s(u),a=s(d),i=t.forwardRef(({className:e,children:r,...l},o)=>t.createElement(a.Root,{ref:o,className:n.cn("relative overflow-hidden",e),...l},t.createElement(a.Viewport,{className:"h-full w-full rounded-[inherit]"},r),t.createElement(c,null),t.createElement(a.Corner,null)));i.displayName=a.Root.displayName;const c=t.forwardRef(({className:e,orientation:r="vertical",...l},o)=>t.createElement(a.ScrollAreaScrollbar,{ref:o,orientation:r,className:n.cn("flex touch-none select-none transition-colors",r==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-[1px]",r==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-[1px]",e),...l},t.createElement(a.ScrollAreaThumb,{className:"relative flex-1 rounded-full bg-border"})));c.displayName=a.ScrollAreaScrollbar.displayName;exports.ScrollArea=i;exports.ScrollBar=c;
|
|
2
2
|
//# sourceMappingURL=index.cjs41.js.map
|
package/dist/index.cjs41.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs41.js","sources":["../src/components/ui/
|
|
1
|
+
{"version":3,"file":"index.cjs41.js","sources":["../src/components/ui/scroll-area.tsx"],"sourcesContent":["import * as React from \"react\"\nimport * as ScrollAreaPrimitive from \"@radix-ui/react-scroll-area\"\n\nimport { cn } from \"@/lib/utils\"\n\nconst ScrollArea = React.forwardRef<\n React.ElementRef<typeof ScrollAreaPrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof ScrollAreaPrimitive.Root>\n>(({ className, children, ...props }, ref) => (\n <ScrollAreaPrimitive.Root\n ref={ref}\n className={cn(\"relative overflow-hidden\", className)}\n {...props}\n >\n <ScrollAreaPrimitive.Viewport className=\"h-full w-full rounded-[inherit]\">\n {children}\n </ScrollAreaPrimitive.Viewport>\n <ScrollBar />\n <ScrollAreaPrimitive.Corner />\n </ScrollAreaPrimitive.Root>\n))\nScrollArea.displayName = ScrollAreaPrimitive.Root.displayName\n\nconst ScrollBar = React.forwardRef<\n React.ElementRef<typeof ScrollAreaPrimitive.ScrollAreaScrollbar>,\n React.ComponentPropsWithoutRef<typeof ScrollAreaPrimitive.ScrollAreaScrollbar>\n>(({ className, orientation = \"vertical\", ...props }, ref) => (\n <ScrollAreaPrimitive.ScrollAreaScrollbar\n ref={ref}\n orientation={orientation}\n className={cn(\n \"flex touch-none select-none transition-colors\",\n orientation === \"vertical\" &&\n \"h-full w-2.5 border-l border-l-transparent p-[1px]\",\n orientation === \"horizontal\" &&\n \"h-2.5 flex-col border-t border-t-transparent p-[1px]\",\n className\n )}\n {...props}\n >\n <ScrollAreaPrimitive.ScrollAreaThumb className=\"relative flex-1 rounded-full bg-border\" />\n </ScrollAreaPrimitive.ScrollAreaScrollbar>\n))\nScrollBar.displayName = ScrollAreaPrimitive.ScrollAreaScrollbar.displayName\n\nexport { ScrollArea, ScrollBar }\n"],"names":["ScrollArea","React","className","children","props","ref","ScrollAreaPrimitive","cn","ScrollBar","orientation"],"mappings":"idAKMA,EAAaC,EAAM,WAGvB,CAAC,CAAE,UAAAC,EAAW,SAAAC,EAAU,GAAGC,CAAA,EAASC,IACpCJ,EAAA,cAACK,EAAoB,KAApB,CACC,IAAAD,EACA,UAAWE,EAAAA,GAAG,2BAA4BL,CAAS,EAClD,GAAGE,CAAA,kBAEHE,EAAoB,SAApB,CAA6B,UAAU,mCACrCH,CACH,kBACCK,EAAA,IAAU,EACXP,EAAA,cAACK,EAAoB,OAApB,IAA2B,CAC9B,CACD,EACDN,EAAW,YAAcM,EAAoB,KAAK,YAElD,MAAME,EAAYP,EAAM,WAGtB,CAAC,CAAE,UAAAC,EAAW,YAAAO,EAAc,WAAY,GAAGL,CAAA,EAASC,IACpDJ,EAAA,cAACK,EAAoB,oBAApB,CACC,IAAAD,EACA,YAAAI,EACA,UAAWF,EAAAA,GACT,gDACAE,IAAgB,YACd,qDACFA,IAAgB,cACd,uDACFP,CAAA,EAED,GAAGE,CAAA,EAEJH,EAAA,cAACK,EAAoB,gBAApB,CAAoC,UAAU,wCAAA,CAAyC,CAC1F,CACD,EACDE,EAAU,YAAcF,EAAoB,oBAAoB"}
|
package/dist/index.cjs42.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const S=require("react"),w=require("@radix-ui/react-select"),c=require("lucide-react"),n=require("./index.cjs57.js");function d(l){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(l){for(const a in l)if(a!=="default"){const o=Object.getOwnPropertyDescriptor(l,a);Object.defineProperty(r,a,o.get?o:{enumerable:!0,get:()=>l[a]})}}return r.default=l,Object.freeze(r)}const e=d(S),t=d(w),y=t.Root,g=t.Group,h=t.Value,m=e.forwardRef(({className:l,children:r,...a},o)=>e.createElement(t.Trigger,{ref:o,className:n.cn("flex h-10 w-full items-center justify-between whitespace-nowrap rounded-[8px] border border-[#e6e6e6] bg-white px-3 py-2 text-[14px] leading-[20px] text-[#111111] shadow-none","data-[placeholder]:text-[#b3b3b3] [&>span]:line-clamp-1","focus-visible:outline-none focus-visible:border-[#1D1C20] data-[state=open]:border-[#1D1C20]","disabled:cursor-not-allowed disabled:bg-[#f2f2f2] disabled:text-[#9ca3af] disabled:data-[placeholder]:text-[#b3b3b3]","aria-invalid:border-[#ff3b30] aria-invalid:focus-visible:border-[#ff3b30]",l),...a},r,e.createElement(t.Icon,{asChild:!0},e.createElement(c.ChevronDown,{className:"h-4 w-4 text-[#7f7d83]"}))));m.displayName=t.Trigger.displayName;const s=e.forwardRef(({className:l,...r},a)=>e.createElement(t.ScrollUpButton,{ref:a,className:n.cn("flex cursor-default items-center justify-center py-1 text-[#7f7d83]",l),...r},e.createElement(c.ChevronUp,{className:"h-4 w-4"})));s.displayName=t.ScrollUpButton.displayName;const i=e.forwardRef(({className:l,...r},a)=>e.createElement(t.ScrollDownButton,{ref:a,className:n.cn("flex cursor-default items-center justify-center py-1 text-[#7f7d83]",l),...r},e.createElement(c.ChevronDown,{className:"h-4 w-4"})));i.displayName=t.ScrollDownButton.displayName;const p=e.forwardRef(({className:l,children:r,position:a="popper",...o},x)=>e.createElement(t.Portal,null,e.createElement(t.Content,{ref:x,className:n.cn("relative z-50 max-h-[--radix-select-content-available-height] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-[8px] border border-[#e6e6e6] bg-white text-[#111111] shadow-sm","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-select-content-transform-origin]",a==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",l),position:a,...o},e.createElement(s,null),e.createElement(t.Viewport,{className:n.cn("p-1",a==="popper"&&"w-full min-w-[var(--radix-select-trigger-width)]")},r),e.createElement(i,null))));p.displayName=t.Content.displayName;const f=e.forwardRef(({className:l,...r},a)=>e.createElement(t.Label,{ref:a,className:n.cn("px-2 py-1 text-[12px] font-medium text-[#7f7d83]",l),...r}));f.displayName=t.Label.displayName;const u=e.forwardRef(({className:l,children:r,...a},o)=>e.createElement(t.Item,{ref:o,className:n.cn("relative flex w-full cursor-default select-none items-center rounded-[6px] py-2 pl-2 pr-8 text-[14px] leading-[20px] outline-none","focus:bg-[#f1f1f1] focus:text-[#111111] data-[state=checked]:bg-[#f1f1f1] data-[disabled]:pointer-events-none data-[disabled]:opacity-50",l),...a},e.createElement("span",{className:"absolute right-2 flex h-3.5 w-3.5 items-center justify-center"},e.createElement(t.ItemIndicator,null,e.createElement(c.Check,{className:"h-4 w-4 text-[#26453f]"}))),e.createElement(t.ItemText,null,r)));u.displayName=t.Item.displayName;const b=e.forwardRef(({className:l,...r},a)=>e.createElement(t.Separator,{ref:a,className:n.cn("-mx-1 my-1 h-px bg-[#e6e6e6]",l),...r}));b.displayName=t.Separator.displayName;exports.Select=y;exports.SelectContent=p;exports.SelectGroup=g;exports.SelectItem=u;exports.SelectLabel=f;exports.SelectScrollDownButton=i;exports.SelectScrollUpButton=s;exports.SelectSeparator=b;exports.SelectTrigger=m;exports.SelectValue=h;
|
|
2
2
|
//# sourceMappingURL=index.cjs42.js.map
|
package/dist/index.cjs42.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs42.js","sources":["../src/components/ui/
|
|
1
|
+
{"version":3,"file":"index.cjs42.js","sources":["../src/components/ui/select.tsx"],"sourcesContent":["\"use client\"\n\nimport * as React from \"react\"\nimport * as SelectPrimitive from \"@radix-ui/react-select\"\nimport { Check, ChevronDown, ChevronUp } from \"lucide-react\"\n\nimport { cn } from \"@/lib/utils\"\n\nconst Select = SelectPrimitive.Root\n\nconst SelectGroup = SelectPrimitive.Group\n\nconst SelectValue = SelectPrimitive.Value\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef<typeof SelectPrimitive.Trigger>,\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.Trigger>\n>(({ className, children, ...props }, ref) => (\n <SelectPrimitive.Trigger\n ref={ref}\n className={cn(\n \"flex h-10 w-full items-center justify-between whitespace-nowrap rounded-[8px] border border-[#e6e6e6] bg-white px-3 py-2 text-[14px] leading-[20px] text-[#111111] shadow-none\",\n \"data-[placeholder]:text-[#b3b3b3] [&>span]:line-clamp-1\",\n \"focus-visible:outline-none focus-visible:border-[#1D1C20] data-[state=open]:border-[#1D1C20]\",\n \"disabled:cursor-not-allowed disabled:bg-[#f2f2f2] disabled:text-[#9ca3af] disabled:data-[placeholder]:text-[#b3b3b3]\",\n \"aria-invalid:border-[#ff3b30] aria-invalid:focus-visible:border-[#ff3b30]\",\n className\n )}\n {...props}\n >\n {children}\n <SelectPrimitive.Icon asChild>\n <ChevronDown className=\"h-4 w-4 text-[#7f7d83]\" />\n </SelectPrimitive.Icon>\n </SelectPrimitive.Trigger>\n))\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef<typeof SelectPrimitive.ScrollUpButton>,\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.ScrollUpButton>\n>(({ className, ...props }, ref) => (\n <SelectPrimitive.ScrollUpButton\n ref={ref}\n className={cn(\n \"flex cursor-default items-center justify-center py-1 text-[#7f7d83]\",\n className\n )}\n {...props}\n >\n <ChevronUp className=\"h-4 w-4\" />\n </SelectPrimitive.ScrollUpButton>\n))\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef<typeof SelectPrimitive.ScrollDownButton>,\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.ScrollDownButton>\n>(({ className, ...props }, ref) => (\n <SelectPrimitive.ScrollDownButton\n ref={ref}\n className={cn(\n \"flex cursor-default items-center justify-center py-1 text-[#7f7d83]\",\n className\n )}\n {...props}\n >\n <ChevronDown className=\"h-4 w-4\" />\n </SelectPrimitive.ScrollDownButton>\n))\nSelectScrollDownButton.displayName =\n SelectPrimitive.ScrollDownButton.displayName\n\nconst SelectContent = React.forwardRef<\n React.ElementRef<typeof SelectPrimitive.Content>,\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.Content>\n>(({ className, children, position = \"popper\", ...props }, ref) => (\n <SelectPrimitive.Portal>\n <SelectPrimitive.Content\n ref={ref}\n className={cn(\n \"relative z-50 max-h-[--radix-select-content-available-height] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-[8px] border border-[#e6e6e6] bg-white text-[#111111] shadow-sm\",\n \"data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-select-content-transform-origin]\",\n position === \"popper\" &&\n \"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1\",\n className\n )}\n position={position}\n {...props}\n >\n <SelectScrollUpButton />\n <SelectPrimitive.Viewport\n className={cn(\n \"p-1\",\n position === \"popper\" &&\n \"w-full min-w-[var(--radix-select-trigger-width)]\"\n )}\n >\n {children}\n </SelectPrimitive.Viewport>\n <SelectScrollDownButton />\n </SelectPrimitive.Content>\n </SelectPrimitive.Portal>\n))\nSelectContent.displayName = SelectPrimitive.Content.displayName\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef<typeof SelectPrimitive.Label>,\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.Label>\n>(({ className, ...props }, ref) => (\n <SelectPrimitive.Label\n ref={ref}\n className={cn(\"px-2 py-1 text-[12px] font-medium text-[#7f7d83]\", className)}\n {...props}\n />\n))\nSelectLabel.displayName = SelectPrimitive.Label.displayName\n\nconst SelectItem = React.forwardRef<\n React.ElementRef<typeof SelectPrimitive.Item>,\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.Item>\n>(({ className, children, ...props }, ref) => (\n <SelectPrimitive.Item\n ref={ref}\n className={cn(\n \"relative flex w-full cursor-default select-none items-center rounded-[6px] py-2 pl-2 pr-8 text-[14px] leading-[20px] outline-none\",\n \"focus:bg-[#f1f1f1] focus:text-[#111111] data-[state=checked]:bg-[#f1f1f1] data-[disabled]:pointer-events-none data-[disabled]:opacity-50\",\n className\n )}\n {...props}\n >\n <span className=\"absolute right-2 flex h-3.5 w-3.5 items-center justify-center\">\n <SelectPrimitive.ItemIndicator>\n <Check className=\"h-4 w-4 text-[#26453f]\" />\n </SelectPrimitive.ItemIndicator>\n </span>\n <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>\n </SelectPrimitive.Item>\n))\nSelectItem.displayName = SelectPrimitive.Item.displayName\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef<typeof SelectPrimitive.Separator>,\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.Separator>\n>(({ className, ...props }, ref) => (\n <SelectPrimitive.Separator\n ref={ref}\n className={cn(\"-mx-1 my-1 h-px bg-[#e6e6e6]\", className)}\n {...props}\n />\n))\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n}\n"],"names":["Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","React","className","children","props","ref","cn","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","Check","SelectSeparator"],"mappings":"seAQMA,EAASC,EAAgB,KAEzBC,EAAcD,EAAgB,MAE9BE,EAAcF,EAAgB,MAE9BG,EAAgBC,EAAM,WAG1B,CAAC,CAAE,UAAAC,EAAW,SAAAC,EAAU,GAAGC,CAAA,EAASC,IACpCJ,EAAA,cAACJ,EAAgB,QAAhB,CACC,IA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AAA,kBAEFO,EAAA,IAAuB,CAC1B,CACF,CACD,EACDC,EAAc,YAAcd,EAAgB,QAAQ,YAEpD,MAAMgB,EAAcZ,EAAM,WAGxB,CAAC,CAAE,UAAAC,EAAW,GAAGE,CAAA,EAASC,IAC1BJ,EAAA,cAACJ,EAAgB,MAAhB,CACC,IAAAQ,EACA,UAAWC,EAAAA,GAAG,mDAAoDJ,CAAS,EAC1E,GAAGE,CAAA,CACN,CACD,EACDS,EAAY,YAAchB,EAAgB,MAAM,YAEhD,MAAMiB,EAAab,EAAM,WAGvB,CAAC,CAAE,UAAAC,EAAW,SAAAC,EAAU,GAAGC,CAAA,EAASC,IACpCJ,EAAA,cAACJ,EAAgB,KAAhB,CACC,IAAAQ,EACA,UAAWC,EAAAA,GACT,oIACA,2IACAJ,CAAA,EAED,GAAGE,CAAA,EAEJH,EAAA,cAAC,OAAA,CAAK,UAAU,+DAAA,EACdA,EAAA,cAACJ,EAAgB,cAAhB,KACCI,EAAA,cAACc,EAAAA,MAAA,CAAM,UAAU,wBAAA,CAAyB,CAC5C,CACF,EACAd,EAAA,cAACJ,EAAgB,SAAhB,KAA0BM,CAAS,CACtC,CACD,EACDW,EAAW,YAAcjB,EAAgB,KAAK,YAE9C,MAAMmB,EAAkBf,EAAM,WAG5B,CAAC,CAAE,UAAAC,EAAW,GAAGE,CAAA,EAASC,IAC1BJ,EAAA,cAACJ,EAAgB,UAAhB,CACC,IAAAQ,EACA,UAAWC,EAAAA,GAAG,+BAAgCJ,CAAS,EACtD,GAAGE,CAAA,CACN,CACD,EACDY,EAAgB,YAAcnB,EAAgB,UAAU"}
|
package/dist/index.cjs43.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react"),u=require("@radix-ui/react-separator"),p=require("./index.cjs57.js");function n(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const a=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const o=n(s),c=n(u),i=o.forwardRef(({className:e,orientation:t="horizontal",decorative:r=!0,...a},l)=>o.createElement(c.Root,{ref:l,decorative:r,orientation:t,className:p.cn("shrink-0 bg-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...a}));i.displayName=c.Root.displayName;exports.Separator=i;
|
|
2
2
|
//# sourceMappingURL=index.cjs43.js.map
|
package/dist/index.cjs43.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs43.js","sources":["../src/components/ui/
|
|
1
|
+
{"version":3,"file":"index.cjs43.js","sources":["../src/components/ui/separator.tsx"],"sourcesContent":["import * as React from \"react\"\nimport * as SeparatorPrimitive from \"@radix-ui/react-separator\"\n\nimport { cn } from \"@/lib/utils\"\n\nconst Separator = React.forwardRef<\n React.ElementRef<typeof SeparatorPrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof SeparatorPrimitive.Root>\n>(\n (\n { className, orientation = \"horizontal\", decorative = true, ...props },\n ref\n ) => (\n <SeparatorPrimitive.Root\n ref={ref}\n decorative={decorative}\n orientation={orientation}\n className={cn(\n \"shrink-0 bg-border\",\n orientation === \"horizontal\" ? \"h-[1px] w-full\" : \"h-full w-[1px]\",\n className\n )}\n {...props}\n />\n )\n)\nSeparator.displayName = SeparatorPrimitive.Root.displayName\n\nexport { Separator }\n"],"names":["Separator","React","className","orientation","decorative","props","ref","SeparatorPrimitive","cn"],"mappings":"+cAKMA,EAAYC,EAAM,WAItB,CACE,CAAE,UAAAC,EAAW,YAAAC,EAAc,aAAc,WAAAC,EAAa,GAAM,GAAGC,CAAA,EAC/DC,IAEAL,EAAA,cAACM,EAAmB,KAAnB,CACC,IAAAD,EACA,WAAAF,EACA,YAAAD,EACA,UAAWK,EAAAA,GACT,qBACAL,IAAgB,aAAe,iBAAmB,iBAClDD,CAAA,EAED,GAAGG,CAAA,CAAA,CAGV,EACAL,EAAU,YAAcO,EAAmB,KAAK"}
|
package/dist/index.cjs44.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const Q=require("react"),h=require("@radix-ui/react-slot"),Z=require("class-variance-authority"),$=require("lucide-react"),ee=require("./index.cjs57.js"),i=require("./index.cjs56.js"),ae=require("./index.cjs10.js"),te=require("./index.cjs27.js"),re=require("./index.cjs42.js"),g=require("./index.cjs43.js"),N=require("./index.cjs45.js"),y=require("./index.cjs55.js");function ne(a){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(a){for(const r in a)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(a,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>a[r]})}}return t.default=a,Object.freeze(t)}const e=ne(Q),ie="sidebar_state",oe=3600*24*7,de="16rem",se="18rem",le="3rem",ce="b",M=e.createContext(null);function S(){const a=e.useContext(M);if(!a)throw new Error("useSidebar must be used within a SidebarProvider.");return a}const R=e.forwardRef(({defaultOpen:a=!0,open:t,onOpenChange:r,className:n,style:o,children:d,...c},p)=>{const l=ee.useIsMobile(),[f,u]=e.useState(!1),[v,Y]=e.useState(a),m=t??v,x=e.useCallback(s=>{const b=typeof s=="function"?s(m):s;r?r(b):Y(b),document.cookie=`${ie}=${b}; path=/; max-age=${oe}`},[r,m]),w=e.useCallback(()=>l?u(s=>!s):x(s=>!s),[l,x,u]);e.useEffect(()=>{const s=b=>{b.key===ce&&(b.metaKey||b.ctrlKey)&&(b.preventDefault(),w())};return window.addEventListener("keydown",s),()=>window.removeEventListener("keydown",s)},[w]);const E=m?"expanded":"collapsed",J=e.useMemo(()=>({state:E,open:m,setOpen:x,isMobile:l,openMobile:f,setOpenMobile:u,toggleSidebar:w}),[E,m,x,l,f,u,w]);return e.createElement(M.Provider,{value:J},e.createElement(y.TooltipProvider,{delayDuration:0},e.createElement("div",{style:{"--sidebar-width":de,"--sidebar-width-icon":le,...o},className:i.cn("group/sidebar-wrapper flex min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar",n),ref:p,...c},d)))});R.displayName="SidebarProvider";const _=e.forwardRef(({side:a="left",variant:t="sidebar",collapsible:r="offcanvas",className:n,children:o,...d},c)=>{const{isMobile:p,state:l,openMobile:f,setOpenMobile:u}=S();return r==="none"?e.createElement("div",{className:i.cn("flex h-full w-[--sidebar-width] flex-col bg-sidebar text-sidebar-foreground",n),ref:c,...d},o):p?e.createElement(g.Sheet,{open:f,onOpenChange:u,...d},e.createElement(g.SheetContent,{"data-sidebar":"sidebar","data-mobile":"true",className:"w-[--sidebar-width] bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden",style:{"--sidebar-width":se},side:a},e.createElement(g.SheetHeader,{className:"sr-only"},e.createElement(g.SheetTitle,null,"Sidebar"),e.createElement(g.SheetDescription,null,"Displays the mobile sidebar.")),e.createElement("div",{className:"flex h-full w-full flex-col"},o))):e.createElement("div",{ref:c,className:"group peer hidden text-sidebar-foreground md:block","data-state":l,"data-collapsible":l==="collapsed"?r:"","data-variant":t,"data-side":a},e.createElement("div",{className:i.cn("relative w-[--sidebar-width] bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon]")}),e.createElement("div",{className:i.cn("fixed inset-y-0 z-10 hidden h-svh w-[--sidebar-width] transition-[left,right,width] duration-200 ease-linear md:flex",a==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l",n),...d},e.createElement("div",{"data-sidebar":"sidebar",className:"flex h-full w-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow"},o)))});_.displayName="Sidebar";const k=e.forwardRef(({className:a,onClick:t,...r},n)=>{const{toggleSidebar:o}=S();return e.createElement(ae.Button,{ref:n,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:i.cn("h-7 w-7",a),onClick:d=>{t?.(d),o()},...r},e.createElement($.PanelLeft,null),e.createElement("span",{className:"sr-only"},"Toggle Sidebar"))});k.displayName="SidebarTrigger";const I=e.forwardRef(({className:a,...t},r)=>{const{toggleSidebar:n}=S();return e.createElement("button",{ref:r,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:n,title:"Toggle Sidebar",className:i.cn("absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",a),...t})});I.displayName="SidebarRail";const C=e.forwardRef(({className:a,...t},r)=>e.createElement("main",{ref:r,className:i.cn("relative flex w-full flex-1 flex-col bg-background","md:peer-data-[variant=inset]:m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow",a),...t}));C.displayName="SidebarInset";const z=e.forwardRef(({className:a,...t},r)=>e.createElement(te.Input,{ref:r,"data-sidebar":"input",className:i.cn("h-8 w-full bg-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring",a),...t}));z.displayName="SidebarInput";const B=e.forwardRef(({className:a,...t},r)=>e.createElement("div",{ref:r,"data-sidebar":"header",className:i.cn("flex flex-col gap-2 p-2",a),...t}));B.displayName="SidebarHeader";const T=e.forwardRef(({className:a,...t},r)=>e.createElement("div",{ref:r,"data-sidebar":"footer",className:i.cn("flex flex-col gap-2 p-2",a),...t}));T.displayName="SidebarFooter";const O=e.forwardRef(({className:a,...t},r)=>e.createElement(re.Separator,{ref:r,"data-sidebar":"separator",className:i.cn("mx-2 w-auto bg-sidebar-border",a),...t}));O.displayName="SidebarSeparator";const A=e.forwardRef(({className:a,...t},r)=>e.createElement("div",{ref:r,"data-sidebar":"content",className:i.cn("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",a),...t}));A.displayName="SidebarContent";const D=e.forwardRef(({className:a,...t},r)=>e.createElement("div",{ref:r,"data-sidebar":"group",className:i.cn("relative flex w-full min-w-0 flex-col p-2",a),...t}));D.displayName="SidebarGroup";const q=e.forwardRef(({className:a,asChild:t=!1,...r},n)=>{const o=t?h.Slot:"div";return e.createElement(o,{ref:n,"data-sidebar":"group-label",className:i.cn("flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 outline-none ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",a),...r})});q.displayName="SidebarGroupLabel";const G=e.forwardRef(({className:a,asChild:t=!1,...r},n)=>{const o=t?h.Slot:"button";return e.createElement(o,{ref:n,"data-sidebar":"group-action",className:i.cn("absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","group-data-[collapsible=icon]:hidden",a),...r})});G.displayName="SidebarGroupAction";const j=e.forwardRef(({className:a,...t},r)=>e.createElement("div",{ref:r,"data-sidebar":"group-content",className:i.cn("w-full text-sm",a),...t}));j.displayName="SidebarGroupContent";const H=e.forwardRef(({className:a,...t},r)=>e.createElement("ul",{ref:r,"data-sidebar":"menu",className:i.cn("flex w-full min-w-0 flex-col gap-1",a),...t}));H.displayName="SidebarMenu";const P=e.forwardRef(({className:a,...t},r)=>e.createElement("li",{ref:r,"data-sidebar":"menu-item",className:i.cn("group/menu-item relative",a),...t}));P.displayName="SidebarMenuItem";const ue=Z.cva("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",lg:"h-12 text-sm group-data-[collapsible=icon]:!p-0"}},defaultVariants:{variant:"default",size:"default"}}),L=e.forwardRef(({asChild:a=!1,isActive:t=!1,variant:r="default",size:n="default",tooltip:o,className:d,...c},p)=>{const l=a?h.Slot:"button",{isMobile:f,state:u}=S(),v=e.createElement(l,{ref:p,"data-sidebar":"menu-button","data-size":n,"data-active":t,className:i.cn(ue({variant:r,size:n}),d),...c});return o?(typeof o=="string"&&(o={children:o}),e.createElement(y.Tooltip,null,e.createElement(y.TooltipTrigger,{asChild:!0},v),e.createElement(y.TooltipContent,{side:"right",align:"center",hidden:u!=="collapsed"||f,...o}))):v});L.displayName="SidebarMenuButton";const K=e.forwardRef(({className:a,asChild:t=!1,showOnHover:r=!1,...n},o)=>{const d=t?h.Slot:"button";return e.createElement(d,{ref:o,"data-sidebar":"menu-action",className:i.cn("absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",r&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground md:opacity-0",a),...n})});K.displayName="SidebarMenuAction";const V=e.forwardRef(({className:a,...t},r)=>e.createElement("div",{ref:r,"data-sidebar":"menu-badge",className:i.cn("pointer-events-none absolute right-1 flex h-5 min-w-5 select-none items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums text-sidebar-foreground","peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",a),...t}));V.displayName="SidebarMenuBadge";const F=e.forwardRef(({className:a,showIcon:t=!1,...r},n)=>{const o=e.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return e.createElement("div",{ref:n,"data-sidebar":"menu-skeleton",className:i.cn("flex h-8 items-center gap-2 rounded-md px-2",a),...r},t&&e.createElement(N.Skeleton,{className:"size-4 rounded-md","data-sidebar":"menu-skeleton-icon"}),e.createElement(N.Skeleton,{className:"h-4 max-w-[--skeleton-width] flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}}))});F.displayName="SidebarMenuSkeleton";const W=e.forwardRef(({className:a,...t},r)=>e.createElement("ul",{ref:r,"data-sidebar":"menu-sub",className:i.cn("mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5","group-data-[collapsible=icon]:hidden",a),...t}));W.displayName="SidebarMenuSub";const U=e.forwardRef(({...a},t)=>e.createElement("li",{ref:t,...a}));U.displayName="SidebarMenuSubItem";const X=e.forwardRef(({asChild:a=!1,size:t="md",isActive:r,className:n,...o},d)=>{const c=a?h.Slot:"a";return e.createElement(c,{ref:d,"data-sidebar":"menu-sub-button","data-size":t,"data-active":r,className:i.cn("flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground","data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground",t==="sm"&&"text-xs",t==="md"&&"text-sm","group-data-[collapsible=icon]:hidden",n),...o})});X.displayName="SidebarMenuSubButton";exports.Sidebar=_;exports.SidebarContent=A;exports.SidebarFooter=T;exports.SidebarGroup=D;exports.SidebarGroupAction=G;exports.SidebarGroupContent=j;exports.SidebarGroupLabel=q;exports.SidebarHeader=B;exports.SidebarInput=z;exports.SidebarInset=C;exports.SidebarMenu=H;exports.SidebarMenuAction=K;exports.SidebarMenuBadge=V;exports.SidebarMenuButton=L;exports.SidebarMenuItem=P;exports.SidebarMenuSkeleton=F;exports.SidebarMenuSub=W;exports.SidebarMenuSubButton=X;exports.SidebarMenuSubItem=U;exports.SidebarProvider=R;exports.SidebarRail=I;exports.SidebarSeparator=O;exports.SidebarTrigger=k;exports.useSidebar=S;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const h=require("react"),y=require("@radix-ui/react-dialog"),b=require("class-variance-authority"),S=require("lucide-react"),n=require("./index.cjs57.js");function l(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const s in e)if(s!=="default"){const r=Object.getOwnPropertyDescriptor(e,s);Object.defineProperty(t,s,r.get?r:{enumerable:!0,get:()=>e[s]})}}return t.default=e,Object.freeze(t)}const a=l(h),o=l(y),N=o.Root,x=o.Trigger,v=o.Close,c=o.Portal,i=a.forwardRef(({className:e,...t},s)=>a.createElement(o.Overlay,{className:n.cn("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:s}));i.displayName=o.Overlay.displayName;const w=b.cva("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500 data-[state=open]:animate-in data-[state=closed]:animate-out",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),d=a.forwardRef(({side:e="right",className:t,children:s,...r},g)=>a.createElement(c,null,a.createElement(i,null),a.createElement(o.Content,{ref:g,className:n.cn(w({side:e}),t),...r},a.createElement(o.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary"},a.createElement(S.X,{className:"h-4 w-4"}),a.createElement("span",{className:"sr-only"},"Close")),s)));d.displayName=o.Content.displayName;const m=({className:e,...t})=>a.createElement("div",{className:n.cn("flex flex-col space-y-2 text-center sm:text-left",e),...t});m.displayName="SheetHeader";const f=({className:e,...t})=>a.createElement("div",{className:n.cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});f.displayName="SheetFooter";const u=a.forwardRef(({className:e,...t},s)=>a.createElement(o.Title,{ref:s,className:n.cn("text-lg font-semibold text-foreground",e),...t}));u.displayName=o.Title.displayName;const p=a.forwardRef(({className:e,...t},s)=>a.createElement(o.Description,{ref:s,className:n.cn("text-sm text-muted-foreground",e),...t}));p.displayName=o.Description.displayName;exports.Sheet=N;exports.SheetClose=v;exports.SheetContent=d;exports.SheetDescription=p;exports.SheetFooter=f;exports.SheetHeader=m;exports.SheetOverlay=i;exports.SheetPortal=c;exports.SheetTitle=u;exports.SheetTrigger=x;
|
|
2
2
|
//# sourceMappingURL=index.cjs44.js.map
|
package/dist/index.cjs44.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs44.js","sources":["../src/components/ui/sidebar.tsx"],"sourcesContent":["import * as React from \"react\"\nimport { Slot } from \"@radix-ui/react-slot\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\nimport { PanelLeft } from \"lucide-react\"\n\nimport { useIsMobile } from \"@/hooks/use-mobile\"\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Input } from \"@/components/ui/input\"\nimport { Separator } from \"@/components/ui/separator\"\nimport {\n Sheet,\n SheetContent,\n SheetDescription,\n SheetHeader,\n SheetTitle,\n} from \"@/components/ui/sheet\"\nimport { Skeleton } from \"@/components/ui/skeleton\"\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from \"@/components/ui/tooltip\"\n\nconst SIDEBAR_COOKIE_NAME = \"sidebar_state\"\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7\nconst SIDEBAR_WIDTH = \"16rem\"\nconst SIDEBAR_WIDTH_MOBILE = \"18rem\"\nconst SIDEBAR_WIDTH_ICON = \"3rem\"\nconst SIDEBAR_KEYBOARD_SHORTCUT = \"b\"\n\ntype SidebarContextProps = {\n state: \"expanded\" | \"collapsed\"\n open: boolean\n setOpen: (open: boolean) => void\n openMobile: boolean\n setOpenMobile: (open: boolean) => void\n isMobile: boolean\n toggleSidebar: () => void\n}\n\nconst SidebarContext = React.createContext<SidebarContextProps | null>(null)\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext)\n if (!context) {\n throw new Error(\"useSidebar must be used within a SidebarProvider.\")\n }\n\n return context\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\"> & {\n defaultOpen?: boolean\n open?: boolean\n onOpenChange?: (open: boolean) => void\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref\n ) => {\n const isMobile = useIsMobile()\n const [openMobile, setOpenMobile] = React.useState(false)\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen)\n const open = openProp ?? _open\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === \"function\" ? value(open) : value\n if (setOpenProp) {\n setOpenProp(openState)\n } else {\n _setOpen(openState)\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`\n },\n [setOpenProp, open]\n )\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile\n ? setOpenMobile((open) => !open)\n : setOpen((open) => !open)\n }, [isMobile, setOpen, setOpenMobile])\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (\n event.key === SIDEBAR_KEYBOARD_SHORTCUT &&\n (event.metaKey || event.ctrlKey)\n ) {\n event.preventDefault()\n toggleSidebar()\n }\n }\n\n window.addEventListener(\"keydown\", handleKeyDown)\n return () => window.removeEventListener(\"keydown\", handleKeyDown)\n }, [toggleSidebar])\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = open ? \"expanded\" : \"collapsed\"\n\n const contextValue = React.useMemo<SidebarContextProps>(\n () => ({\n state,\n open,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, open, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar]\n )\n\n return (\n <SidebarContext.Provider value={contextValue}>\n <TooltipProvider delayDuration={0}>\n <div\n style={\n {\n \"--sidebar-width\": SIDEBAR_WIDTH,\n \"--sidebar-width-icon\": SIDEBAR_WIDTH_ICON,\n ...style,\n } as React.CSSProperties\n }\n className={cn(\n \"group/sidebar-wrapper flex min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar\",\n className\n )}\n ref={ref}\n {...props}\n >\n {children}\n </div>\n </TooltipProvider>\n </SidebarContext.Provider>\n )\n }\n)\nSidebarProvider.displayName = \"SidebarProvider\"\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\"> & {\n side?: \"left\" | \"right\"\n variant?: \"sidebar\" | \"floating\" | \"inset\"\n collapsible?: \"offcanvas\" | \"icon\" | \"none\"\n }\n>(\n (\n {\n side = \"left\",\n variant = \"sidebar\",\n collapsible = \"offcanvas\",\n className,\n children,\n ...props\n },\n ref\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar()\n\n if (collapsible === \"none\") {\n return (\n <div\n className={cn(\n \"flex h-full w-[--sidebar-width] flex-col bg-sidebar text-sidebar-foreground\",\n className\n )}\n ref={ref}\n {...props}\n >\n {children}\n </div>\n )\n }\n\n if (isMobile) {\n return (\n <Sheet open={openMobile} onOpenChange={setOpenMobile} {...props}>\n <SheetContent\n data-sidebar=\"sidebar\"\n data-mobile=\"true\"\n className=\"w-[--sidebar-width] bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden\"\n style={\n {\n \"--sidebar-width\": SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n <SheetHeader className=\"sr-only\">\n <SheetTitle>Sidebar</SheetTitle>\n <SheetDescription>Displays the mobile sidebar.</SheetDescription>\n </SheetHeader>\n <div className=\"flex h-full w-full flex-col\">{children}</div>\n </SheetContent>\n </Sheet>\n )\n }\n\n return (\n <div\n ref={ref}\n className=\"group peer hidden text-sidebar-foreground md:block\"\n data-state={state}\n data-collapsible={state === \"collapsed\" ? collapsible : \"\"}\n data-variant={variant}\n data-side={side}\n >\n {/* This is what handles the sidebar gap on desktop */}\n <div\n className={cn(\n \"relative w-[--sidebar-width] bg-transparent transition-[width] duration-200 ease-linear\",\n \"group-data-[collapsible=offcanvas]:w-0\",\n \"group-data-[side=right]:rotate-180\",\n variant === \"floating\" || variant === \"inset\"\n ? \"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]\"\n : \"group-data-[collapsible=icon]:w-[--sidebar-width-icon]\"\n )}\n />\n <div\n className={cn(\n \"fixed inset-y-0 z-10 hidden h-svh w-[--sidebar-width] transition-[left,right,width] duration-200 ease-linear md:flex\",\n side === \"left\"\n ? \"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]\"\n : \"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]\",\n // Adjust the padding for floating and inset variants.\n variant === \"floating\" || variant === \"inset\"\n ? \"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]\"\n : \"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l\",\n className\n )}\n {...props}\n >\n <div\n data-sidebar=\"sidebar\"\n className=\"flex h-full w-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow\"\n >\n {children}\n </div>\n </div>\n </div>\n )\n }\n)\nSidebar.displayName = \"Sidebar\"\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef<typeof Button>,\n React.ComponentProps<typeof Button>\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar()\n\n return (\n <Button\n ref={ref}\n data-sidebar=\"trigger\"\n variant=\"ghost\"\n size=\"icon\"\n className={cn(\"h-7 w-7\", className)}\n onClick={(event) => {\n onClick?.(event)\n toggleSidebar()\n }}\n {...props}\n >\n <PanelLeft />\n <span className=\"sr-only\">Toggle Sidebar</span>\n </Button>\n )\n})\nSidebarTrigger.displayName = \"SidebarTrigger\"\n\nconst SidebarRail = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<\"button\">\n>(({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar()\n\n return (\n <button\n ref={ref}\n data-sidebar=\"rail\"\n aria-label=\"Toggle Sidebar\"\n tabIndex={-1}\n onClick={toggleSidebar}\n title=\"Toggle Sidebar\"\n className={cn(\n \"absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex\",\n \"[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize\",\n \"[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize\",\n \"group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar\",\n \"[[data-side=left][data-collapsible=offcanvas]_&]:-right-2\",\n \"[[data-side=right][data-collapsible=offcanvas]_&]:-left-2\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarRail.displayName = \"SidebarRail\"\n\nconst SidebarInset = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"main\">\n>(({ className, ...props }, ref) => {\n return (\n <main\n ref={ref}\n className={cn(\n \"relative flex w-full flex-1 flex-col bg-background\",\n \"md:peer-data-[variant=inset]:m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarInset.displayName = \"SidebarInset\"\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef<typeof Input>,\n React.ComponentProps<typeof Input>\n>(({ className, ...props }, ref) => {\n return (\n <Input\n ref={ref}\n data-sidebar=\"input\"\n className={cn(\n \"h-8 w-full bg-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarInput.displayName = \"SidebarInput\"\n\nconst SidebarHeader = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => {\n return (\n <div\n ref={ref}\n data-sidebar=\"header\"\n className={cn(\"flex flex-col gap-2 p-2\", className)}\n {...props}\n />\n )\n})\nSidebarHeader.displayName = \"SidebarHeader\"\n\nconst SidebarFooter = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => {\n return (\n <div\n ref={ref}\n data-sidebar=\"footer\"\n className={cn(\"flex flex-col gap-2 p-2\", className)}\n {...props}\n />\n )\n})\nSidebarFooter.displayName = \"SidebarFooter\"\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef<typeof Separator>,\n React.ComponentProps<typeof Separator>\n>(({ className, ...props }, ref) => {\n return (\n <Separator\n ref={ref}\n data-sidebar=\"separator\"\n className={cn(\"mx-2 w-auto bg-sidebar-border\", className)}\n {...props}\n />\n )\n})\nSidebarSeparator.displayName = \"SidebarSeparator\"\n\nconst SidebarContent = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => {\n return (\n <div\n ref={ref}\n data-sidebar=\"content\"\n className={cn(\n \"flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarContent.displayName = \"SidebarContent\"\n\nconst SidebarGroup = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => {\n return (\n <div\n ref={ref}\n data-sidebar=\"group\"\n className={cn(\"relative flex w-full min-w-0 flex-col p-2\", className)}\n {...props}\n />\n )\n})\nSidebarGroup.displayName = \"SidebarGroup\"\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\"> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : \"div\"\n\n return (\n <Comp\n ref={ref}\n data-sidebar=\"group-label\"\n className={cn(\n \"flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 outline-none ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0\",\n \"group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarGroupLabel.displayName = \"SidebarGroupLabel\"\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<\"button\"> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : \"button\"\n\n return (\n <Comp\n ref={ref}\n data-sidebar=\"group-action\"\n className={cn(\n \"absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0\",\n // Increases the hit area of the button on mobile.\n \"after:absolute after:-inset-2 after:md:hidden\",\n \"group-data-[collapsible=icon]:hidden\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarGroupAction.displayName = \"SidebarGroupAction\"\n\nconst SidebarGroupContent = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => (\n <div\n ref={ref}\n data-sidebar=\"group-content\"\n className={cn(\"w-full text-sm\", className)}\n {...props}\n />\n))\nSidebarGroupContent.displayName = \"SidebarGroupContent\"\n\nconst SidebarMenu = React.forwardRef<\n HTMLUListElement,\n React.ComponentProps<\"ul\">\n>(({ className, ...props }, ref) => (\n <ul\n ref={ref}\n data-sidebar=\"menu\"\n className={cn(\"flex w-full min-w-0 flex-col gap-1\", className)}\n {...props}\n />\n))\nSidebarMenu.displayName = \"SidebarMenu\"\n\nconst SidebarMenuItem = React.forwardRef<\n HTMLLIElement,\n React.ComponentProps<\"li\">\n>(({ className, ...props }, ref) => (\n <li\n ref={ref}\n data-sidebar=\"menu-item\"\n className={cn(\"group/menu-item relative\", className)}\n {...props}\n />\n))\nSidebarMenuItem.displayName = \"SidebarMenuItem\"\n\nconst sidebarMenuButtonVariants = cva(\n \"peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0\",\n {\n variants: {\n variant: {\n default: \"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground\",\n outline:\n \"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]\",\n },\n size: {\n default: \"h-8 text-sm\",\n sm: \"h-7 text-xs\",\n lg: \"h-12 text-sm group-data-[collapsible=icon]:!p-0\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n size: \"default\",\n },\n }\n)\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<\"button\"> & {\n asChild?: boolean\n isActive?: boolean\n tooltip?: string | React.ComponentProps<typeof TooltipContent>\n } & VariantProps<typeof sidebarMenuButtonVariants>\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = \"default\",\n size = \"default\",\n tooltip,\n className,\n ...props\n },\n ref\n ) => {\n const Comp = asChild ? Slot : \"button\"\n const { isMobile, state } = useSidebar()\n\n const button = (\n <Comp\n ref={ref}\n data-sidebar=\"menu-button\"\n data-size={size}\n data-active={isActive}\n className={cn(sidebarMenuButtonVariants({ variant, size }), className)}\n {...props}\n />\n )\n\n if (!tooltip) {\n return button\n }\n\n if (typeof tooltip === \"string\") {\n tooltip = {\n children: tooltip,\n }\n }\n\n return (\n <Tooltip>\n <TooltipTrigger asChild>{button}</TooltipTrigger>\n <TooltipContent\n side=\"right\"\n align=\"center\"\n hidden={state !== \"collapsed\" || isMobile}\n {...tooltip}\n />\n </Tooltip>\n )\n }\n)\nSidebarMenuButton.displayName = \"SidebarMenuButton\"\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<\"button\"> & {\n asChild?: boolean\n showOnHover?: boolean\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : \"button\"\n\n return (\n <Comp\n ref={ref}\n data-sidebar=\"menu-action\"\n className={cn(\n \"absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0\",\n // Increases the hit area of the button on mobile.\n \"after:absolute after:-inset-2 after:md:hidden\",\n \"peer-data-[size=sm]/menu-button:top-1\",\n \"peer-data-[size=default]/menu-button:top-1.5\",\n \"peer-data-[size=lg]/menu-button:top-2.5\",\n \"group-data-[collapsible=icon]:hidden\",\n showOnHover &&\n \"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground md:opacity-0\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarMenuAction.displayName = \"SidebarMenuAction\"\n\nconst SidebarMenuBadge = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => (\n <div\n ref={ref}\n data-sidebar=\"menu-badge\"\n className={cn(\n \"pointer-events-none absolute right-1 flex h-5 min-w-5 select-none items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums text-sidebar-foreground\",\n \"peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground\",\n \"peer-data-[size=sm]/menu-button:top-1\",\n \"peer-data-[size=default]/menu-button:top-1.5\",\n \"peer-data-[size=lg]/menu-button:top-2.5\",\n \"group-data-[collapsible=icon]:hidden\",\n className\n )}\n {...props}\n />\n))\nSidebarMenuBadge.displayName = \"SidebarMenuBadge\"\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\"> & {\n showIcon?: boolean\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`\n }, [])\n\n return (\n <div\n ref={ref}\n data-sidebar=\"menu-skeleton\"\n className={cn(\"flex h-8 items-center gap-2 rounded-md px-2\", className)}\n {...props}\n >\n {showIcon && (\n <Skeleton\n className=\"size-4 rounded-md\"\n data-sidebar=\"menu-skeleton-icon\"\n />\n )}\n <Skeleton\n className=\"h-4 max-w-[--skeleton-width] flex-1\"\n data-sidebar=\"menu-skeleton-text\"\n style={\n {\n \"--skeleton-width\": width,\n } as React.CSSProperties\n }\n />\n </div>\n )\n})\nSidebarMenuSkeleton.displayName = \"SidebarMenuSkeleton\"\n\nconst SidebarMenuSub = React.forwardRef<\n HTMLUListElement,\n React.ComponentProps<\"ul\">\n>(({ className, ...props }, ref) => (\n <ul\n ref={ref}\n data-sidebar=\"menu-sub\"\n className={cn(\n \"mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5\",\n \"group-data-[collapsible=icon]:hidden\",\n className\n )}\n {...props}\n />\n))\nSidebarMenuSub.displayName = \"SidebarMenuSub\"\n\nconst SidebarMenuSubItem = React.forwardRef<\n HTMLLIElement,\n React.ComponentProps<\"li\">\n>(({ ...props }, ref) => <li ref={ref} {...props} />)\nSidebarMenuSubItem.displayName = \"SidebarMenuSubItem\"\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<\"a\"> & {\n asChild?: boolean\n size?: \"sm\" | \"md\"\n isActive?: boolean\n }\n>(({ asChild = false, size = \"md\", isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : \"a\"\n\n return (\n <Comp\n ref={ref}\n data-sidebar=\"menu-sub-button\"\n data-size={size}\n data-active={isActive}\n className={cn(\n \"flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground\",\n \"data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground\",\n size === \"sm\" && \"text-xs\",\n size === \"md\" && \"text-sm\",\n \"group-data-[collapsible=icon]:hidden\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarMenuSubButton.displayName = \"SidebarMenuSubButton\"\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n}\n"],"names":["SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","React","useSidebar","context","SidebarProvider","defaultOpen","openProp","setOpenProp","className","style","children","props","ref","isMobile","useIsMobile","openMobile","setOpenMobile","_open","_setOpen","open","setOpen","value","openState","toggleSidebar","handleKeyDown","event","state","contextValue","TooltipProvider","cn","Sidebar","side","variant","collapsible","Sheet","SheetContent","SheetHeader","SheetTitle","SheetDescription","SidebarTrigger","onClick","Button","PanelLeft","SidebarRail","SidebarInset","SidebarInput","Input","SidebarHeader","SidebarFooter","SidebarSeparator","Separator","SidebarContent","SidebarGroup","SidebarGroupLabel","asChild","Comp","Slot","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","cva","SidebarMenuButton","isActive","size","tooltip","button","Tooltip","TooltipTrigger","TooltipContent","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","Skeleton","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton"],"mappings":"2tBAyBMA,GAAsB,gBACtBC,GAAyB,KAAU,GAAK,EACxCC,GAAgB,QAChBC,GAAuB,QACvBC,GAAqB,OACrBC,GAA4B,IAY5BC,EAAiBC,EAAM,cAA0C,IAAI,EAE3E,SAASC,GAAa,CACpB,MAAMC,EAAUF,EAAM,WAAWD,CAAc,EAC/C,GAAI,CAACG,EACH,MAAM,IAAI,MAAM,mDAAmD,EAGrE,OAAOA,CACT,CAEA,MAAMC,EAAkBH,EAAM,WAQ5B,CACE,CACE,YAAAI,EAAc,GACd,KAAMC,EACN,aAAcC,EACd,UAAAC,EACA,MAAAC,EACA,SAAAC,EACA,GAAGC,CAAA,EAELC,IACG,CACH,MAAMC,EAAWC,GAAAA,YAAA,EACX,CAACC,EAAYC,CAAa,EAAIf,EAAM,SAAS,EAAK,EAIlD,CAACgB,EAAOC,CAAQ,EAAIjB,EAAM,SAASI,CAAW,EAC9Cc,EAAOb,GAAYW,EACnBG,EAAUnB,EAAM,YACnBoB,GAAmD,CAClD,MAA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AAW,GAAGD,EAAO,CAAE,EACpDoE,EAAmB,YAAc,qBAEjC,MAAMC,EAAuB/E,EAAM,WAOjC,CAAC,CAAE,QAAAqD,EAAU,GAAO,KAAAW,EAAO,KAAM,SAAAD,EAAU,UAAAxD,EAAW,GAAGG,CAAA,EAASC,IAAQ,CAC1E,MAAM2C,EAAOD,EAAUE,EAAAA,KAAO,IAE9B,OACEvD,EAAA,cAACsD,EAAA,CACC,IAAA3C,EACA,eAAa,kBACb,YAAWqD,EACX,cAAaD,EACb,UAAWnC,EAAAA,GACT,8eACA,yFACAoC,IAAS,MAAQ,UACjBA,IAAS,MAAQ,UACjB,uCACAzD,CAAA,EAED,GAAGG,CAAA,CAAA,CAGV,CAAC,EACDqE,EAAqB,YAAc"}
|
|
1
|
+
{"version":3,"file":"index.cjs44.js","sources":["../src/components/ui/sheet.tsx"],"sourcesContent":["\"use client\"\n\nimport * as React from \"react\"\nimport * as SheetPrimitive from \"@radix-ui/react-dialog\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\nimport { X } from \"lucide-react\"\n\nimport { cn } from \"@/lib/utils\"\n\nconst Sheet = SheetPrimitive.Root\n\nconst SheetTrigger = SheetPrimitive.Trigger\n\nconst SheetClose = SheetPrimitive.Close\n\nconst SheetPortal = SheetPrimitive.Portal\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef<typeof SheetPrimitive.Overlay>,\n React.ComponentPropsWithoutRef<typeof SheetPrimitive.Overlay>\n>(({ className, ...props }, ref) => (\n <SheetPrimitive.Overlay\n className={cn(\n \"fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0\",\n className\n )}\n {...props}\n ref={ref}\n />\n))\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName\n\nconst sheetVariants = cva(\n \"fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500 data-[state=open]:animate-in data-[state=closed]:animate-out\",\n {\n variants: {\n side: {\n top: \"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top\",\n bottom:\n \"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom\",\n left: \"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm\",\n right:\n \"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm\",\n },\n },\n defaultVariants: {\n side: \"right\",\n },\n }\n)\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef<typeof SheetPrimitive.Content>,\n VariantProps<typeof sheetVariants> {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef<typeof SheetPrimitive.Content>,\n SheetContentProps\n>(({ side = \"right\", className, children, ...props }, ref) => (\n <SheetPortal>\n <SheetOverlay />\n <SheetPrimitive.Content\n ref={ref}\n className={cn(sheetVariants({ side }), className)}\n {...props}\n >\n <SheetPrimitive.Close className=\"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary\">\n <X className=\"h-4 w-4\" />\n <span className=\"sr-only\">Close</span>\n </SheetPrimitive.Close>\n {children}\n </SheetPrimitive.Content>\n </SheetPortal>\n))\nSheetContent.displayName = SheetPrimitive.Content.displayName\n\nconst SheetHeader = ({\n className,\n ...props\n}: React.HTMLAttributes<HTMLDivElement>) => (\n <div\n className={cn(\n \"flex flex-col space-y-2 text-center sm:text-left\",\n className\n )}\n {...props}\n />\n)\nSheetHeader.displayName = \"SheetHeader\"\n\nconst SheetFooter = ({\n className,\n ...props\n}: React.HTMLAttributes<HTMLDivElement>) => (\n <div\n className={cn(\n \"flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2\",\n className\n )}\n {...props}\n />\n)\nSheetFooter.displayName = \"SheetFooter\"\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef<typeof SheetPrimitive.Title>,\n React.ComponentPropsWithoutRef<typeof SheetPrimitive.Title>\n>(({ className, ...props }, ref) => (\n <SheetPrimitive.Title\n ref={ref}\n className={cn(\"text-lg font-semibold text-foreground\", className)}\n {...props}\n />\n))\nSheetTitle.displayName = SheetPrimitive.Title.displayName\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef<typeof SheetPrimitive.Description>,\n React.ComponentPropsWithoutRef<typeof SheetPrimitive.Description>\n>(({ className, ...props }, ref) => (\n <SheetPrimitive.Description\n ref={ref}\n className={cn(\"text-sm text-muted-foreground\", className)}\n {...props}\n />\n))\nSheetDescription.displayName = SheetPrimitive.Description.displayName\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n}\n"],"names":["Sheet","SheetPrimitive","SheetTrigger","SheetClose","SheetPortal","SheetOverlay","React","className","props","ref","cn","sheetVariants","cva","SheetContent","side","children","X","SheetHeader","SheetFooter","SheetTitle","SheetDescription"],"mappings":"4gBASMA,EAAQC,EAAe,KAEvBC,EAAeD,EAAe,QAE9BE,EAAaF,EAAe,MAE5BG,EAAcH,EAAe,OAE7BI,EAAeC,EAAM,WAGzB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAA,EAASC,IAC1BH,EAAA,cAACL,EAAe,QAAf,CACC,UAAWS,EAAAA,GACT,0JACAH,CAAA,EAED,GAAGC,EACJ,IAAAC,CAAA,CACF,CACD,EACDJ,EAAa,YAAcJ,EAAe,QAAQ,YAElD,MAAMU,EAAgBC,EAAAA,IACpB,mMACA,CACE,SAAU,CACR,KAAM,CACJ,IAAK,oGACL,OACE,6GACF,KAAM,gIACN,MACE,kIAAA,CACJ,EAEF,gBAAiB,CACf,KAAM,OAAA,CACR,CAEJ,EA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AAcnB,EAAe,YAAY"}
|
package/dist/index.cjs45.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("react"),o=require("./index.cjs56.js");function a(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const u=a(c);function i({className:e,...t}){return u.createElement("div",{className:o.cn("animate-pulse rounded-md bg-primary/10",e),...t})}exports.Skeleton=i;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const J=require("react"),S=require("@radix-ui/react-slot"),Q=require("class-variance-authority"),Z=require("lucide-react"),i=require("./index.cjs57.js"),ee=require("./index.cjs10.js"),ae=require("./index.cjs28.js"),te=require("./index.cjs43.js"),h=require("./index.cjs44.js"),N=require("./index.cjs46.js"),y=require("./index.cjs56.js");function re(t){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const a in t)if(a!=="default"){const n=Object.getOwnPropertyDescriptor(t,a);Object.defineProperty(r,a,n.get?n:{enumerable:!0,get:()=>t[a]})}}return r.default=t,Object.freeze(r)}const e=re(J),ne="sidebar_state",ie=3600*24*7,oe="15rem",de="15rem",se="4.5rem",le=1024,ce="b";function ue(){const[t,r]=e.useState(void 0);return e.useEffect(()=>{const a=window.matchMedia(`(max-width: ${le-1}px)`),n=()=>{r(a.matches)};return n(),typeof a.addEventListener=="function"?(a.addEventListener("change",n),()=>a.removeEventListener("change",n)):(a.addListener(n),()=>a.removeListener(n))},[]),!!t}const M=e.createContext(null);function v(){const t=e.useContext(M);if(!t)throw new Error("useSidebar must be used within a SidebarProvider.");return t}const k=e.forwardRef(({defaultOpen:t=!0,open:r,onOpenChange:a,className:n,style:o,children:d,...l},p)=>{const s=ue(),[u,b]=e.useState(!1),[m,Y]=e.useState(t),g=r??m,x=e.useCallback(c=>{const f=typeof c=="function"?c(g):c;a?a(f):Y(f),document.cookie=`${ne}=${f}; path=/; max-age=${ie}`},[a,g]),w=e.useCallback(()=>s?b(c=>!c):x(c=>!c),[s,x,b]);e.useEffect(()=>{const c=f=>{f.key===ce&&(f.metaKey||f.ctrlKey)&&(f.preventDefault(),w())};return window.addEventListener("keydown",c),()=>window.removeEventListener("keydown",c)},[w]);const E=g?"expanded":"collapsed",$=e.useMemo(()=>({state:E,open:g,setOpen:x,isMobile:s,openMobile:u,setOpenMobile:b,toggleSidebar:w}),[E,g,x,s,u,b,w]);return e.createElement(M.Provider,{value:$},e.createElement(y.TooltipProvider,{delayDuration:0},e.createElement("div",{style:{"--sidebar-width":oe,"--sidebar-width-icon":se,...o},className:i.cn("group/sidebar-wrapper flex min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar",n),ref:p,...l},d)))});k.displayName="SidebarProvider";const R=e.forwardRef(({side:t="left",variant:r="sidebar",collapsible:a="offcanvas",className:n,children:o,...d},l)=>{const{isMobile:p,state:s,openMobile:u,setOpenMobile:b}=v(),m=a==="offcanvas"?"icon":a;return a==="none"?e.createElement("div",{className:i.cn("flex h-full w-[--sidebar-width] flex-col border-r border-[#e6e6e6] bg-white text-black",n),ref:l,...d},o):p?e.createElement(h.Sheet,{open:u,onOpenChange:b,...d},e.createElement(h.SheetContent,{"data-sidebar":"sidebar","data-mobile":"true",className:i.cn("w-[--sidebar-width] border-r border-[#e6e6e6] bg-white p-0 text-black shadow-none [&>button]:hidden",n),style:{"--sidebar-width":de},side:t},e.createElement(h.SheetHeader,{className:"sr-only"},e.createElement(h.SheetTitle,null,"Sidebar"),e.createElement(h.SheetDescription,null,"Displays the mobile sidebar.")),e.createElement("div",{className:"flex h-full w-full flex-col"},o))):e.createElement("div",{ref:l,className:"group peer hidden text-black lg:block","data-state":s,"data-collapsible":s==="collapsed"?m:"","data-variant":r,"data-side":t},e.createElement("div",{className:i.cn("relative w-[--sidebar-width] bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",r==="floating"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon]")}),e.createElement("div",{className:i.cn("fixed inset-y-0 z-20 hidden h-svh w-[--sidebar-width] transition-[left,right,width] duration-200 ease-linear lg:flex",t==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",r==="floating"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=left]:border-[#e6e6e6] group-data-[side=right]:border-l group-data-[side=right]:border-[#e6e6e6]",n),...d},e.createElement("div",{"data-sidebar":"sidebar",className:"flex h-full w-full flex-col bg-white text-black group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-[#e6e6e6] group-data-[variant=floating]:shadow"},o)))});R.displayName="Sidebar";const I=e.forwardRef(({className:t,onClick:r,...a},n)=>{const{isMobile:o,open:d,openMobile:l,toggleSidebar:p}=v(),s=o?l:d;return e.createElement(ee.Button,{ref:n,"data-sidebar":"trigger",variant:"ghost",size:"icon","data-state":s?"open":"closed",className:i.cn("h-9 w-9 rounded-lg border border-[#dcdcde] bg-white text-black hover:bg-[#fafafa] hover:text-black",t),onClick:u=>{r?.(u),p()},...a},e.createElement(Z.PanelLeft,{className:"size-4"}),e.createElement("span",{className:"sr-only"},"Toggle Sidebar"))});I.displayName="SidebarTrigger";const _=e.forwardRef(({className:t,...r},a)=>{const{toggleSidebar:n}=v();return e.createElement("button",{ref:a,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:n,title:"Toggle Sidebar",className:i.cn("absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",t),...r})});_.displayName="SidebarRail";const C=e.forwardRef(({className:t,...r},a)=>e.createElement("main",{ref:a,className:i.cn("relative flex w-full flex-1 flex-col bg-background","lg:peer-data-[variant=inset]:m-2 lg:peer-data-[variant=inset]:ml-0 lg:peer-data-[variant=inset]:rounded-xl lg:peer-data-[variant=inset]:shadow",t),...r}));C.displayName="SidebarInset";const z=e.forwardRef(({className:t,...r},a)=>e.createElement(ae.Input,{ref:a,"data-sidebar":"input",className:i.cn("h-10 w-full rounded-lg border-[#e6e6e6] bg-white text-black placeholder:text-[#adacb0] shadow-none focus-visible:ring-2 focus-visible:ring-[#26453f]",t),...r}));z.displayName="SidebarInput";const O=e.forwardRef(({className:t,...r},a)=>e.createElement("div",{ref:a,"data-sidebar":"header",className:i.cn("flex flex-col gap-4 px-5 py-5 group-data-[collapsible=icon]:items-center group-data-[collapsible=icon]:px-4 group-data-[collapsible=icon]:py-4",t),...r}));O.displayName="SidebarHeader";const T=e.forwardRef(({className:t,...r},a)=>e.createElement("div",{ref:a,"data-sidebar":"footer",className:i.cn("flex flex-col gap-3 px-5 py-5 group-data-[collapsible=icon]:items-center group-data-[collapsible=icon]:px-4 group-data-[collapsible=icon]:py-4",t),...r}));T.displayName="SidebarFooter";const B=e.forwardRef(({className:t,...r},a)=>e.createElement(te.Separator,{ref:a,"data-sidebar":"separator",className:i.cn("mx-0 w-full bg-[#e6e6e6]",t),...r}));B.displayName="SidebarSeparator";const A=e.forwardRef(({className:t,...r},a)=>e.createElement("div",{ref:a,"data-sidebar":"content",className:i.cn("flex min-h-0 flex-1 flex-col gap-0 overflow-auto group-data-[collapsible=icon]:overflow-hidden",t),...r}));A.displayName="SidebarContent";const D=e.forwardRef(({className:t,...r},a)=>e.createElement("div",{ref:a,"data-sidebar":"group",className:i.cn("relative flex w-full min-w-0 flex-col gap-2 px-5 py-5 group-data-[collapsible=icon]:items-center group-data-[collapsible=icon]:px-4",t),...r}));D.displayName="SidebarGroup";const q=e.forwardRef(({className:t,asChild:r=!1,...a},n)=>{const o=r?S.Slot:"div";return e.createElement(o,{ref:n,"data-sidebar":"group-label",className:i.cn("flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium uppercase tracking-wide text-[#adacb0] outline-none ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",t),...a})});q.displayName="SidebarGroupLabel";const G=e.forwardRef(({className:t,asChild:r=!1,...a},n)=>{const o=r?S.Slot:"button";return e.createElement(o,{ref:n,"data-sidebar":"group-action",className:i.cn("absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:lg:hidden","group-data-[collapsible=icon]:hidden",t),...a})});G.displayName="SidebarGroupAction";const L=e.forwardRef(({className:t,...r},a)=>e.createElement("div",{ref:a,"data-sidebar":"group-content",className:i.cn("w-full text-sm",t),...r}));L.displayName="SidebarGroupContent";const j=e.forwardRef(({className:t,...r},a)=>e.createElement("ul",{ref:a,"data-sidebar":"menu",className:i.cn("flex w-full min-w-0 flex-col gap-2",t),...r}));j.displayName="SidebarMenu";const P=e.forwardRef(({className:t,...r},a)=>e.createElement("li",{ref:a,"data-sidebar":"menu-item",className:i.cn("group/menu-item relative",t),...r}));P.displayName="SidebarMenuItem";const be=Q.cva("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-[4px] border border-transparent bg-white p-2 text-left text-sm font-normal text-[#7f7d83] outline-none ring-sidebar-ring transition-[background-color,border-color,color,width,height,padding] hover:border-[#f1f1f1] hover:bg-[#fafafa] hover:text-black focus-visible:ring-2 focus-visible:ring-[#26453f] active:border-[#f1f1f1] active:bg-[#fafafa] active:text-black disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:border-[#f1f1f1] data-[active=true]:bg-[#fafafa] data-[active=true]:font-medium data-[active=true]:text-black data-[state=open]:border-[#f1f1f1] data-[state=open]:bg-[#fafafa] data-[state=open]:text-black group-data-[collapsible=icon]:!size-10 group-data-[collapsible=icon]:!justify-center group-data-[collapsible=icon]:!p-0 group-data-[collapsible=icon]:[&>span:last-child]:hidden [&>span:last-child]:truncate [&>svg]:size-5 [&>svg]:shrink-0",{variants:{variant:{default:"",outline:"border-[#e6e6e6] text-black hover:border-[#dcdcde] hover:bg-[#fafafa]"},size:{default:"h-10 text-sm",sm:"h-9 text-xs",lg:"h-11 text-sm"}},defaultVariants:{variant:"default",size:"default"}}),H=e.forwardRef(({asChild:t=!1,isActive:r=!1,variant:a="default",size:n="default",tooltip:o,className:d,...l},p)=>{const s=t?S.Slot:"button",{isMobile:u,state:b}=v(),m=e.createElement(s,{ref:p,"data-sidebar":"menu-button","data-size":n,"data-active":r,className:i.cn(be({variant:a,size:n}),d),...l});return o?(typeof o=="string"&&(o={children:o}),e.createElement(y.Tooltip,null,e.createElement(y.TooltipTrigger,{asChild:!0},m),e.createElement(y.TooltipContent,{side:"right",align:"center",hidden:b!=="collapsed"||u,...o}))):m});H.displayName="SidebarMenuButton";const K=e.forwardRef(({className:t,asChild:r=!1,showOnHover:a=!1,...n},o)=>{const d=r?S.Slot:"button";return e.createElement(d,{ref:o,"data-sidebar":"menu-action",className:i.cn("absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:lg:hidden","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",a&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground lg:opacity-0",t),...n})});K.displayName="SidebarMenuAction";const V=e.forwardRef(({className:t,...r},a)=>e.createElement("div",{ref:a,"data-sidebar":"menu-badge",className:i.cn("pointer-events-none absolute right-1 flex h-5 min-w-5 select-none items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums text-sidebar-foreground","peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",t),...r}));V.displayName="SidebarMenuBadge";const F=e.forwardRef(({className:t,showIcon:r=!1,...a},n)=>{const o=e.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return e.createElement("div",{ref:n,"data-sidebar":"menu-skeleton",className:i.cn("flex h-8 items-center gap-2 rounded-md px-2",t),...a},r&&e.createElement(N.Skeleton,{className:"size-4 rounded-md","data-sidebar":"menu-skeleton-icon"}),e.createElement(N.Skeleton,{className:"h-4 max-w-[--skeleton-width] flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}}))});F.displayName="SidebarMenuSkeleton";const W=e.forwardRef(({className:t,...r},a)=>e.createElement("ul",{ref:a,"data-sidebar":"menu-sub",className:i.cn("mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5","group-data-[collapsible=icon]:hidden",t),...r}));W.displayName="SidebarMenuSub";const U=e.forwardRef(({...t},r)=>e.createElement("li",{ref:r,...t}));U.displayName="SidebarMenuSubItem";const X=e.forwardRef(({asChild:t=!1,size:r="md",isActive:a,className:n,...o},d)=>{const l=t?S.Slot:"a";return e.createElement(l,{ref:d,"data-sidebar":"menu-sub-button","data-size":r,"data-active":a,className:i.cn("flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground","data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground",r==="sm"&&"text-xs",r==="md"&&"text-sm","group-data-[collapsible=icon]:hidden",n),...o})});X.displayName="SidebarMenuSubButton";exports.Sidebar=R;exports.SidebarContent=A;exports.SidebarFooter=T;exports.SidebarGroup=D;exports.SidebarGroupAction=G;exports.SidebarGroupContent=L;exports.SidebarGroupLabel=q;exports.SidebarHeader=O;exports.SidebarInput=z;exports.SidebarInset=C;exports.SidebarMenu=j;exports.SidebarMenuAction=K;exports.SidebarMenuBadge=V;exports.SidebarMenuButton=H;exports.SidebarMenuItem=P;exports.SidebarMenuSkeleton=F;exports.SidebarMenuSub=W;exports.SidebarMenuSubButton=X;exports.SidebarMenuSubItem=U;exports.SidebarProvider=k;exports.SidebarRail=_;exports.SidebarSeparator=B;exports.SidebarTrigger=I;exports.useSidebar=v;
|
|
2
2
|
//# sourceMappingURL=index.cjs45.js.map
|
package/dist/index.cjs45.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs45.js","sources":["../src/components/ui/skeleton.tsx"],"sourcesContent":["import * as React from \"react\"\nimport { cn } from \"@/lib/utils\"\n\nfunction Skeleton({\n className,\n ...props\n}: React.HTMLAttributes<HTMLDivElement>) {\n return (\n <div\n className={cn(\"animate-pulse rounded-md bg-primary/10\", className)}\n {...props}\n />\n )\n}\n\nexport { Skeleton }\n"],"names":["Skeleton","className","props","React","cn"],"mappings":"iaAGA,SAASA,EAAS,CAChB,UAAAC,EACA,GAAGC,CACL,EAAyC,CACvC,OACEC,EAAA,cAAC,MAAA,CACC,UAAWC,EAAAA,GAAG,yCAA0CH,CAAS,EAChE,GAAGC,CAAA,CAAA,CAGV"}
|
|
1
|
+
{"version":3,"file":"index.cjs45.js","sources":["../src/components/ui/sidebar.tsx"],"sourcesContent":["import * as React from \"react\"\nimport { Slot } from \"@radix-ui/react-slot\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\nimport { PanelLeft } from \"lucide-react\"\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/components/ui/button\"\nimport { Input } from \"@/components/ui/input\"\nimport { Separator } from \"@/components/ui/separator\"\nimport {\n Sheet,\n SheetContent,\n SheetDescription,\n SheetHeader,\n SheetTitle,\n} from \"@/components/ui/sheet\"\nimport { Skeleton } from \"@/components/ui/skeleton\"\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from \"@/components/ui/tooltip\"\n\nconst SIDEBAR_COOKIE_NAME = \"sidebar_state\"\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7\nconst SIDEBAR_WIDTH = \"15rem\"\nconst SIDEBAR_WIDTH_MOBILE = \"15rem\"\nconst SIDEBAR_WIDTH_ICON = \"4.5rem\"\nconst SIDEBAR_BREAKPOINT = 1024\nconst SIDEBAR_KEYBOARD_SHORTCUT = \"b\"\n\nfunction useIsTabletOrMobile() {\n const [isTabletOrMobile, setIsTabletOrMobile] = React.useState<\n boolean | undefined\n >(undefined)\n\n React.useEffect(() => {\n const media = window.matchMedia(`(max-width: ${SIDEBAR_BREAKPOINT - 1}px)`)\n const onChange = () => {\n setIsTabletOrMobile(media.matches)\n }\n\n onChange()\n\n if (typeof media.addEventListener === \"function\") {\n media.addEventListener(\"change\", onChange)\n return () => media.removeEventListener(\"change\", onChange)\n }\n\n media.addListener(onChange)\n return () => media.removeListener(onChange)\n }, [])\n\n return !!isTabletOrMobile\n}\n\ntype SidebarContextProps = {\n state: \"expanded\" | \"collapsed\"\n open: boolean\n setOpen: (open: boolean) => void\n openMobile: boolean\n setOpenMobile: (open: boolean) => void\n isMobile: boolean\n toggleSidebar: () => void\n}\n\nconst SidebarContext = React.createContext<SidebarContextProps | null>(null)\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext)\n if (!context) {\n throw new Error(\"useSidebar must be used within a SidebarProvider.\")\n }\n\n return context\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\"> & {\n defaultOpen?: boolean\n open?: boolean\n onOpenChange?: (open: boolean) => void\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref\n ) => {\n const isMobile = useIsTabletOrMobile()\n const [openMobile, setOpenMobile] = React.useState(false)\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen)\n const open = openProp ?? _open\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === \"function\" ? value(open) : value\n if (setOpenProp) {\n setOpenProp(openState)\n } else {\n _setOpen(openState)\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`\n },\n [setOpenProp, open]\n )\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile\n ? setOpenMobile((open) => !open)\n : setOpen((open) => !open)\n }, [isMobile, setOpen, setOpenMobile])\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (\n event.key === SIDEBAR_KEYBOARD_SHORTCUT &&\n (event.metaKey || event.ctrlKey)\n ) {\n event.preventDefault()\n toggleSidebar()\n }\n }\n\n window.addEventListener(\"keydown\", handleKeyDown)\n return () => window.removeEventListener(\"keydown\", handleKeyDown)\n }, [toggleSidebar])\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = open ? \"expanded\" : \"collapsed\"\n\n const contextValue = React.useMemo<SidebarContextProps>(\n () => ({\n state,\n open,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, open, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar]\n )\n\n return (\n <SidebarContext.Provider value={contextValue}>\n <TooltipProvider delayDuration={0}>\n <div\n style={\n {\n \"--sidebar-width\": SIDEBAR_WIDTH,\n \"--sidebar-width-icon\": SIDEBAR_WIDTH_ICON,\n ...style,\n } as React.CSSProperties\n }\n className={cn(\n \"group/sidebar-wrapper flex min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar\",\n className\n )}\n ref={ref}\n {...props}\n >\n {children}\n </div>\n </TooltipProvider>\n </SidebarContext.Provider>\n )\n }\n)\nSidebarProvider.displayName = \"SidebarProvider\"\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\"> & {\n side?: \"left\" | \"right\"\n variant?: \"sidebar\" | \"floating\" | \"inset\"\n collapsible?: \"offcanvas\" | \"icon\" | \"none\"\n }\n>(\n (\n {\n side = \"left\",\n variant = \"sidebar\",\n collapsible = \"offcanvas\",\n className,\n children,\n ...props\n },\n ref\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar()\n const desktopCollapsible = collapsible === \"offcanvas\" ? \"icon\" : collapsible\n\n if (collapsible === \"none\") {\n return (\n <div\n className={cn(\n \"flex h-full w-[--sidebar-width] flex-col border-r border-[#e6e6e6] bg-white text-black\",\n className\n )}\n ref={ref}\n {...props}\n >\n {children}\n </div>\n )\n }\n\n if (isMobile) {\n return (\n <Sheet open={openMobile} onOpenChange={setOpenMobile} {...props}>\n <SheetContent\n data-sidebar=\"sidebar\"\n data-mobile=\"true\"\n className={cn(\n \"w-[--sidebar-width] border-r border-[#e6e6e6] bg-white p-0 text-black shadow-none [&>button]:hidden\",\n className\n )}\n style={\n {\n \"--sidebar-width\": SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n <SheetHeader className=\"sr-only\">\n <SheetTitle>Sidebar</SheetTitle>\n <SheetDescription>Displays the mobile sidebar.</SheetDescription>\n </SheetHeader>\n <div className=\"flex h-full w-full flex-col\">{children}</div>\n </SheetContent>\n </Sheet>\n )\n }\n\n return (\n <div\n ref={ref}\n className=\"group peer hidden text-black lg:block\"\n data-state={state}\n data-collapsible={state === \"collapsed\" ? desktopCollapsible : \"\"}\n data-variant={variant}\n data-side={side}\n >\n {/* This is what handles the sidebar gap on desktop */}\n <div\n className={cn(\n \"relative w-[--sidebar-width] bg-transparent transition-[width] duration-200 ease-linear\",\n \"group-data-[collapsible=offcanvas]:w-0\",\n \"group-data-[side=right]:rotate-180\",\n variant === \"floating\"\n ? \"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]\"\n : \"group-data-[collapsible=icon]:w-[--sidebar-width-icon]\"\n )}\n />\n <div\n className={cn(\n \"fixed inset-y-0 z-20 hidden h-svh w-[--sidebar-width] transition-[left,right,width] duration-200 ease-linear lg:flex\",\n side === \"left\"\n ? \"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]\"\n : \"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]\",\n // Adjust the padding for floating and inset variants.\n variant === \"floating\"\n ? \"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]\"\n : \"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=left]:border-[#e6e6e6] group-data-[side=right]:border-l group-data-[side=right]:border-[#e6e6e6]\",\n className\n )}\n {...props}\n >\n <div\n data-sidebar=\"sidebar\"\n className=\"flex h-full w-full flex-col bg-white text-black group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-[#e6e6e6] group-data-[variant=floating]:shadow\"\n >\n {children}\n </div>\n </div>\n </div>\n )\n }\n)\nSidebar.displayName = \"Sidebar\"\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef<typeof Button>,\n React.ComponentProps<typeof Button>\n>(({ className, onClick, ...props }, ref) => {\n const { isMobile, open, openMobile, toggleSidebar } = useSidebar()\n const isOpen = isMobile ? openMobile : open\n\n return (\n <Button\n ref={ref}\n data-sidebar=\"trigger\"\n variant=\"ghost\"\n size=\"icon\"\n data-state={isOpen ? \"open\" : \"closed\"}\n className={cn(\n \"h-9 w-9 rounded-lg border border-[#dcdcde] bg-white text-black hover:bg-[#fafafa] hover:text-black\",\n className\n )}\n onClick={(event) => {\n onClick?.(event)\n toggleSidebar()\n }}\n {...props}\n >\n <PanelLeft className=\"size-4\" />\n <span className=\"sr-only\">Toggle Sidebar</span>\n </Button>\n )\n})\nSidebarTrigger.displayName = \"SidebarTrigger\"\n\nconst SidebarRail = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<\"button\">\n>(({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar()\n\n return (\n <button\n ref={ref}\n data-sidebar=\"rail\"\n aria-label=\"Toggle Sidebar\"\n tabIndex={-1}\n onClick={toggleSidebar}\n title=\"Toggle Sidebar\"\n className={cn(\n \"absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex\",\n \"[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize\",\n \"[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize\",\n \"group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar\",\n \"[[data-side=left][data-collapsible=offcanvas]_&]:-right-2\",\n \"[[data-side=right][data-collapsible=offcanvas]_&]:-left-2\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarRail.displayName = \"SidebarRail\"\n\nconst SidebarInset = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"main\">\n>(({ className, ...props }, ref) => {\n return (\n <main\n ref={ref}\n className={cn(\n \"relative flex w-full flex-1 flex-col bg-background\",\n \"lg:peer-data-[variant=inset]:m-2 lg:peer-data-[variant=inset]:ml-0 lg:peer-data-[variant=inset]:rounded-xl lg:peer-data-[variant=inset]:shadow\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarInset.displayName = \"SidebarInset\"\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef<typeof Input>,\n React.ComponentProps<typeof Input>\n>(({ className, ...props }, ref) => {\n return (\n <Input\n ref={ref}\n data-sidebar=\"input\"\n className={cn(\n \"h-10 w-full rounded-lg border-[#e6e6e6] bg-white text-black placeholder:text-[#adacb0] shadow-none focus-visible:ring-2 focus-visible:ring-[#26453f]\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarInput.displayName = \"SidebarInput\"\n\nconst SidebarHeader = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => {\n return (\n <div\n ref={ref}\n data-sidebar=\"header\"\n className={cn(\n \"flex flex-col gap-4 px-5 py-5 group-data-[collapsible=icon]:items-center group-data-[collapsible=icon]:px-4 group-data-[collapsible=icon]:py-4\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarHeader.displayName = \"SidebarHeader\"\n\nconst SidebarFooter = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => {\n return (\n <div\n ref={ref}\n data-sidebar=\"footer\"\n className={cn(\n \"flex flex-col gap-3 px-5 py-5 group-data-[collapsible=icon]:items-center group-data-[collapsible=icon]:px-4 group-data-[collapsible=icon]:py-4\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarFooter.displayName = \"SidebarFooter\"\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef<typeof Separator>,\n React.ComponentProps<typeof Separator>\n>(({ className, ...props }, ref) => {\n return (\n <Separator\n ref={ref}\n data-sidebar=\"separator\"\n className={cn(\"mx-0 w-full bg-[#e6e6e6]\", className)}\n {...props}\n />\n )\n})\nSidebarSeparator.displayName = \"SidebarSeparator\"\n\nconst SidebarContent = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => {\n return (\n <div\n ref={ref}\n data-sidebar=\"content\"\n className={cn(\n \"flex min-h-0 flex-1 flex-col gap-0 overflow-auto group-data-[collapsible=icon]:overflow-hidden\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarContent.displayName = \"SidebarContent\"\n\nconst SidebarGroup = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => {\n return (\n <div\n ref={ref}\n data-sidebar=\"group\"\n className={cn(\n \"relative flex w-full min-w-0 flex-col gap-2 px-5 py-5 group-data-[collapsible=icon]:items-center group-data-[collapsible=icon]:px-4\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarGroup.displayName = \"SidebarGroup\"\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\"> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : \"div\"\n\n return (\n <Comp\n ref={ref}\n data-sidebar=\"group-label\"\n className={cn(\n \"flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium uppercase tracking-wide text-[#adacb0] outline-none ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0\",\n \"group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarGroupLabel.displayName = \"SidebarGroupLabel\"\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<\"button\"> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : \"button\"\n\n return (\n <Comp\n ref={ref}\n data-sidebar=\"group-action\"\n className={cn(\n \"absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0\",\n // Increases the hit area of the button on mobile.\n \"after:absolute after:-inset-2 after:lg:hidden\",\n \"group-data-[collapsible=icon]:hidden\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarGroupAction.displayName = \"SidebarGroupAction\"\n\nconst SidebarGroupContent = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => (\n <div\n ref={ref}\n data-sidebar=\"group-content\"\n className={cn(\"w-full text-sm\", className)}\n {...props}\n />\n))\nSidebarGroupContent.displayName = \"SidebarGroupContent\"\n\nconst SidebarMenu = React.forwardRef<\n HTMLUListElement,\n React.ComponentProps<\"ul\">\n>(({ className, ...props }, ref) => (\n <ul\n ref={ref}\n data-sidebar=\"menu\"\n className={cn(\"flex w-full min-w-0 flex-col gap-2\", className)}\n {...props}\n />\n))\nSidebarMenu.displayName = \"SidebarMenu\"\n\nconst SidebarMenuItem = React.forwardRef<\n HTMLLIElement,\n React.ComponentProps<\"li\">\n>(({ className, ...props }, ref) => (\n <li\n ref={ref}\n data-sidebar=\"menu-item\"\n className={cn(\"group/menu-item relative\", className)}\n {...props}\n />\n))\nSidebarMenuItem.displayName = \"SidebarMenuItem\"\n\nconst sidebarMenuButtonVariants = cva(\n \"peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-[4px] border border-transparent bg-white p-2 text-left text-sm font-normal text-[#7f7d83] outline-none ring-sidebar-ring transition-[background-color,border-color,color,width,height,padding] hover:border-[#f1f1f1] hover:bg-[#fafafa] hover:text-black focus-visible:ring-2 focus-visible:ring-[#26453f] active:border-[#f1f1f1] active:bg-[#fafafa] active:text-black disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:border-[#f1f1f1] data-[active=true]:bg-[#fafafa] data-[active=true]:font-medium data-[active=true]:text-black data-[state=open]:border-[#f1f1f1] data-[state=open]:bg-[#fafafa] data-[state=open]:text-black group-data-[collapsible=icon]:!size-10 group-data-[collapsible=icon]:!justify-center group-data-[collapsible=icon]:!p-0 group-data-[collapsible=icon]:[&>span:last-child]:hidden [&>span:last-child]:truncate [&>svg]:size-5 [&>svg]:shrink-0\",\n {\n variants: {\n variant: {\n default: \"\",\n outline:\n \"border-[#e6e6e6] text-black hover:border-[#dcdcde] hover:bg-[#fafafa]\",\n },\n size: {\n default: \"h-10 text-sm\",\n sm: \"h-9 text-xs\",\n lg: \"h-11 text-sm\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n size: \"default\",\n },\n }\n)\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<\"button\"> & {\n asChild?: boolean\n isActive?: boolean\n tooltip?: string | React.ComponentProps<typeof TooltipContent>\n } & VariantProps<typeof sidebarMenuButtonVariants>\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = \"default\",\n size = \"default\",\n tooltip,\n className,\n ...props\n },\n ref\n ) => {\n const Comp = asChild ? Slot : \"button\"\n const { isMobile, state } = useSidebar()\n\n const button = (\n <Comp\n ref={ref}\n data-sidebar=\"menu-button\"\n data-size={size}\n data-active={isActive}\n className={cn(sidebarMenuButtonVariants({ variant, size }), className)}\n {...props}\n />\n )\n\n if (!tooltip) {\n return button\n }\n\n if (typeof tooltip === \"string\") {\n tooltip = {\n children: tooltip,\n }\n }\n\n return (\n <Tooltip>\n <TooltipTrigger asChild>{button}</TooltipTrigger>\n <TooltipContent\n side=\"right\"\n align=\"center\"\n hidden={state !== \"collapsed\" || isMobile}\n {...tooltip}\n />\n </Tooltip>\n )\n }\n)\nSidebarMenuButton.displayName = \"SidebarMenuButton\"\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<\"button\"> & {\n asChild?: boolean\n showOnHover?: boolean\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : \"button\"\n\n return (\n <Comp\n ref={ref}\n data-sidebar=\"menu-action\"\n className={cn(\n \"absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0\",\n // Increases the hit area of the button on mobile.\n \"after:absolute after:-inset-2 after:lg:hidden\",\n \"peer-data-[size=sm]/menu-button:top-1\",\n \"peer-data-[size=default]/menu-button:top-1.5\",\n \"peer-data-[size=lg]/menu-button:top-2.5\",\n \"group-data-[collapsible=icon]:hidden\",\n showOnHover &&\n \"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground lg:opacity-0\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarMenuAction.displayName = \"SidebarMenuAction\"\n\nconst SidebarMenuBadge = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\">\n>(({ className, ...props }, ref) => (\n <div\n ref={ref}\n data-sidebar=\"menu-badge\"\n className={cn(\n \"pointer-events-none absolute right-1 flex h-5 min-w-5 select-none items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums text-sidebar-foreground\",\n \"peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground\",\n \"peer-data-[size=sm]/menu-button:top-1\",\n \"peer-data-[size=default]/menu-button:top-1.5\",\n \"peer-data-[size=lg]/menu-button:top-2.5\",\n \"group-data-[collapsible=icon]:hidden\",\n className\n )}\n {...props}\n />\n))\nSidebarMenuBadge.displayName = \"SidebarMenuBadge\"\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<\"div\"> & {\n showIcon?: boolean\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`\n }, [])\n\n return (\n <div\n ref={ref}\n data-sidebar=\"menu-skeleton\"\n className={cn(\"flex h-8 items-center gap-2 rounded-md px-2\", className)}\n {...props}\n >\n {showIcon && (\n <Skeleton\n className=\"size-4 rounded-md\"\n data-sidebar=\"menu-skeleton-icon\"\n />\n )}\n <Skeleton\n className=\"h-4 max-w-[--skeleton-width] flex-1\"\n data-sidebar=\"menu-skeleton-text\"\n style={\n {\n \"--skeleton-width\": width,\n } as React.CSSProperties\n }\n />\n </div>\n )\n})\nSidebarMenuSkeleton.displayName = \"SidebarMenuSkeleton\"\n\nconst SidebarMenuSub = React.forwardRef<\n HTMLUListElement,\n React.ComponentProps<\"ul\">\n>(({ className, ...props }, ref) => (\n <ul\n ref={ref}\n data-sidebar=\"menu-sub\"\n className={cn(\n \"mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5\",\n \"group-data-[collapsible=icon]:hidden\",\n className\n )}\n {...props}\n />\n))\nSidebarMenuSub.displayName = \"SidebarMenuSub\"\n\nconst SidebarMenuSubItem = React.forwardRef<\n HTMLLIElement,\n React.ComponentProps<\"li\">\n>(({ ...props }, ref) => <li ref={ref} {...props} />)\nSidebarMenuSubItem.displayName = \"SidebarMenuSubItem\"\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<\"a\"> & {\n asChild?: boolean\n size?: \"sm\" | \"md\"\n isActive?: boolean\n }\n>(({ asChild = false, size = \"md\", isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : \"a\"\n\n return (\n <Comp\n ref={ref}\n data-sidebar=\"menu-sub-button\"\n data-size={size}\n data-active={isActive}\n className={cn(\n \"flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground\",\n \"data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground\",\n size === \"sm\" && \"text-xs\",\n size === \"md\" && \"text-sm\",\n \"group-data-[collapsible=icon]:hidden\",\n className\n )}\n {...props}\n />\n )\n})\nSidebarMenuSubButton.displayName = \"SidebarMenuSubButton\"\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n}\n"],"names":["SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_BREAKPOINT","SIDEBAR_KEYBOARD_SHORTCUT","useIsTabletOrMobile","isTabletOrMobile","setIsTabletOrMobile","React","media","onChange","SidebarContext","useSidebar","context","SidebarProvider","defaultOpen","openProp","setOpenProp","className","style","children","props","ref","isMobile","openMobile","setOpenMobile","_open","_setOpen","open","setOpen","value","openState","toggleSidebar","handleKeyDown","event","state","contextValue","TooltipProvider","cn","Sidebar","side","variant","collapsible","desktopCollapsible","Sheet","SheetContent","SheetHeader","SheetTitle","SheetDescription","SidebarTrigger","onClick","isOpen","Button","PanelLeft","SidebarRail","SidebarInset","SidebarInput","Input","SidebarHeader","SidebarFooter","SidebarSeparator","Separator","SidebarContent","SidebarGroup","SidebarGroupLabel","asChild","Comp","Slot","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","cva","SidebarMenuButton","isActive","size","tooltip","button","Tooltip","TooltipTrigger","TooltipContent","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","Skeleton","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton"],"mappings":"4rBAuBMA,GAAsB,gBACtBC,GAAyB,KAAU,GAAK,EACxCC,GAAgB,QAChBC,GAAuB,QACvBC,GAAqB,SACrBC,GAAqB,KACrBC,GAA4B,IAElC,SAASC,IAAsB,CAC7B,KAAM,CAACC,EAAkBC,CAAmB,EAAIC,EAAM,SAEpD,MAAS,EAEXA,OAAAA,EAAM,UAAU,IAAM,CACpB,MAAMC,EAAQ,OAAO,WAAW,eAAeN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AE9B,OACE3D,EAAA,cAAC0D,EAAA,CACC,IAAA5C,EACA,eAAa,kBACb,YAAWsD,EACX,cAAaD,EACb,UAAWrC,EAAAA,GACT,8eACA,yFACAsC,IAAS,MAAQ,UACjBA,IAAS,MAAQ,UACjB,uCACA1D,CAAA,EAED,GAAGG,CAAA,CAAA,CAGV,CAAC,EACDsE,EAAqB,YAAc"}
|
package/dist/index.cjs46.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("react"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("react"),o=require("./index.cjs57.js");function a(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const u=a(c);function i({className:e,...t}){return u.createElement("div",{className:o.cn("animate-pulse rounded-md bg-primary/10",e),...t})}exports.Skeleton=i;
|
|
2
2
|
//# sourceMappingURL=index.cjs46.js.map
|
package/dist/index.cjs46.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs46.js","sources":["../src/components/ui/
|
|
1
|
+
{"version":3,"file":"index.cjs46.js","sources":["../src/components/ui/skeleton.tsx"],"sourcesContent":["import * as React from \"react\"\nimport { cn } from \"@/lib/utils\"\n\nfunction Skeleton({\n className,\n ...props\n}: React.HTMLAttributes<HTMLDivElement>) {\n return (\n <div\n className={cn(\"animate-pulse rounded-md bg-primary/10\", className)}\n {...props}\n />\n )\n}\n\nexport { Skeleton }\n"],"names":["Skeleton","className","props","React","cn"],"mappings":"iaAGA,SAASA,EAAS,CAChB,UAAAC,EACA,GAAGC,CACL,EAAyC,CACvC,OACEC,EAAA,cAAC,MAAA,CACC,UAAWC,EAAAA,GAAG,yCAA0CH,CAAS,EAChE,GAAGC,CAAA,CAAA,CAGV"}
|
package/dist/index.cjs47.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("react"),g=require("@radix-ui/react-slider"),l=require("./index.cjs57.js");function a(r){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const e in r)if(e!=="default"){const o=Object.getOwnPropertyDescriptor(r,e);Object.defineProperty(t,e,o.get?o:{enumerable:!0,get:()=>r[e]})}}return t.default=r,Object.freeze(t)}const n=a(m),i=a(g),c=n.forwardRef(({className:r,disabled:t,value:e,defaultValue:o,...u},d)=>{const s=Array.isArray(e)?e:Array.isArray(o)?o:[0],f=s.length>1;return n.createElement(i.Root,{ref:d,"data-disabled":t?"true":void 0,disabled:t,className:l.cn("group/slider relative flex w-full touch-none select-none items-center",r),value:e,defaultValue:o,...u},n.createElement(i.Track,{className:l.cn("relative h-2 w-full grow overflow-hidden rounded-full bg-[#e6e6e6] group-data-[disabled=true]/slider:bg-[#f2f2f2]")},n.createElement(i.Range,{className:l.cn("absolute z-0 h-full bg-[#26453f]",f?"rounded-full":"rounded-l-full")})),s.map((p,b)=>n.createElement(i.Thumb,{key:`thumb-${b}`,className:"block h-4 w-4 rounded-full border border-[#26453f] bg-white shadow-sm transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[#111111] focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50"})))});c.displayName=i.Root.displayName;exports.Slider=c;
|
|
2
2
|
//# sourceMappingURL=index.cjs47.js.map
|
package/dist/index.cjs47.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs47.js","sources":["../src/components/ui/
|
|
1
|
+
{"version":3,"file":"index.cjs47.js","sources":["../src/components/ui/slider.tsx"],"sourcesContent":["import * as React from \"react\"\nimport * as SliderPrimitive from \"@radix-ui/react-slider\"\n\nimport { cn } from \"@/lib/utils\"\n\nconst Slider = React.forwardRef<\n React.ElementRef<typeof SliderPrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof SliderPrimitive.Root>\n>(({ className, disabled, value, defaultValue, ...props }, ref) => {\n const thumbValues = Array.isArray(value)\n ? value\n : Array.isArray(defaultValue)\n ? defaultValue\n : [0]\n const isRange = thumbValues.length > 1\n\n return (\n <SliderPrimitive.Root\n ref={ref}\n data-disabled={disabled ? \"true\" : undefined}\n disabled={disabled}\n className={cn(\n \"group/slider relative flex w-full touch-none select-none items-center\",\n className\n )}\n value={value}\n defaultValue={defaultValue}\n {...props}\n >\n <SliderPrimitive.Track\n className={cn(\n \"relative h-2 w-full grow overflow-hidden rounded-full bg-[#e6e6e6] group-data-[disabled=true]/slider:bg-[#f2f2f2]\"\n )}\n >\n <SliderPrimitive.Range\n className={cn(\n \"absolute z-0 h-full bg-[#26453f]\",\n isRange ? \"rounded-full\" : \"rounded-l-full\"\n )}\n />\n </SliderPrimitive.Track>\n {thumbValues.map((_, index) => (\n <SliderPrimitive.Thumb\n key={`thumb-${index}`}\n className=\"block h-4 w-4 rounded-full border border-[#26453f] bg-white shadow-sm transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[#111111] focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50\"\n />\n ))}\n </SliderPrimitive.Root>\n )\n})\nSlider.displayName = SliderPrimitive.Root.displayName\n\nexport { Slider }\n"],"names":["Slider","React","className","disabled","value","defaultValue","props","ref","thumbValues","isRange","SliderPrimitive","cn","_","index"],"mappings":"4cAKMA,EAASC,EAAM,WAGnB,CAAC,CAAE,UAAAC,EAAW,SAAAC,EAAU,MAAAC,EAAO,aAAAC,EAAc,GAAGC,CAAA,EAASC,IAAQ,CACjE,MAAMC,EAAc,MAAM,QAAQJ,CAAK,EACnCA,EACA,MAAM,QAAQC,CAAY,EAC1BA,EACA,CAAC,CAAC,EACAI,EAAUD,EAAY,OAAS,EAErC,OACEP,EAAA,cAACS,EAAgB,KAAhB,CACC,IAAAH,EACA,gBAAeJ,EAAW,OAAS,OACnC,SAAAA,EACA,UAAWQ,EAAAA,GACT,wEACAT,CAAA,EAEF,MAAAE,EACA,aAAAC,EACC,GAAGC,CAAA,EAEJL,EAAA,cAACS,EAAgB,MAAhB,CACC,UAAWC,EAAAA,GACT,mHAAA,CACF,EAEAV,EAAA,cAACS,EAAgB,MAAhB,CACC,UAAWC,EAAAA,GACT,mCACAF,EAAU,eAAiB,gBAAA,CAC7B,CAAA,CACF,EAEDD,EAAY,IAAI,CAACI,EAAGC,IACnBZ,EAAA,cAACS,EAAgB,MAAhB,CACC,IAAK,SAASG,CAAK,GACnB,UAAU,mPAAA,CAAA,CAEb,CAAA,CAGP,CAAC,EACDb,EAAO,YAAcU,EAAgB,KAAK"}
|
package/dist/index.cjs48.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("next-themes"),r=require("sonner"),s=({...t})=>{const{theme:o="system"}=e.useTheme();return React.createElement(r.Toaster,{theme:o,className:"toaster group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...t})};exports.Toaster=s;
|
|
2
2
|
//# sourceMappingURL=index.cjs48.js.map
|
package/dist/index.cjs48.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs48.js","sources":["../src/components/ui/
|
|
1
|
+
{"version":3,"file":"index.cjs48.js","sources":["../src/components/ui/sonner.tsx"],"sourcesContent":["\"use client\"\n\nimport { useTheme } from \"next-themes\"\nimport { Toaster as Sonner } from \"sonner\"\n\ntype ToasterProps = React.ComponentProps<typeof Sonner>\n\nconst Toaster = ({ ...props }: ToasterProps) => {\n const { theme = \"system\" } = useTheme()\n\n return (\n <Sonner\n theme={theme as ToasterProps[\"theme\"]}\n className=\"toaster group\"\n toastOptions={{\n classNames: {\n toast:\n \"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg\",\n description: \"group-[.toast]:text-muted-foreground\",\n actionButton:\n \"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground\",\n cancelButton:\n \"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground\",\n },\n }}\n {...props}\n />\n )\n}\n\nexport { Toaster }\n"],"names":["Toaster","props","theme","useTheme","Sonner"],"mappings":"mIAOMA,EAAU,CAAC,CAAE,GAAGC,KAA0B,CAC9C,KAAM,CAAE,MAAAC,EAAQ,QAAA,EAAaC,WAAA,EAE7B,OACE,MAAA,cAACC,EAAAA,QAAA,CACC,MAAAF,EACA,UAAU,gBACV,aAAc,CACZ,WAAY,CACV,MACE,wIACF,YAAa,uCACb,aACE,mEACF,aACE,8DAAA,CACJ,EAED,GAAGD,CAAA,CAAA,CAGV"}
|