@kubetail/ui 2.0.3 → 2.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (98) hide show
  1. package/dist/_virtual/rolldown:runtime.cjs +1 -0
  2. package/dist/elements/button.cjs +2 -2
  3. package/dist/elements/button.cjs.map +1 -1
  4. package/dist/elements/button.js +39 -42
  5. package/dist/elements/button.js.map +1 -1
  6. package/dist/elements/calendar.cjs +2 -2
  7. package/dist/elements/calendar.cjs.map +1 -1
  8. package/dist/elements/calendar.js +23 -27
  9. package/dist/elements/calendar.js.map +1 -1
  10. package/dist/elements/card.cjs +2 -2
  11. package/dist/elements/card.cjs.map +1 -1
  12. package/dist/elements/card.js +47 -50
  13. package/dist/elements/card.js.map +1 -1
  14. package/dist/elements/checkbox.cjs +2 -2
  15. package/dist/elements/checkbox.cjs.map +1 -1
  16. package/dist/elements/checkbox.js +19 -28
  17. package/dist/elements/checkbox.js.map +1 -1
  18. package/dist/elements/dialog.cjs +2 -2
  19. package/dist/elements/dialog.cjs.map +1 -1
  20. package/dist/elements/dialog.js +75 -107
  21. package/dist/elements/dialog.js.map +1 -1
  22. package/dist/elements/dropdown-menu.cjs +2 -2
  23. package/dist/elements/dropdown-menu.cjs.map +1 -1
  24. package/dist/elements/dropdown-menu.js +107 -181
  25. package/dist/elements/dropdown-menu.js.map +1 -1
  26. package/dist/elements/form.cjs +2 -2
  27. package/dist/elements/form.cjs.map +1 -1
  28. package/dist/elements/form.js +73 -76
  29. package/dist/elements/form.js.map +1 -1
  30. package/dist/elements/input.cjs +2 -2
  31. package/dist/elements/input.cjs.map +1 -1
  32. package/dist/elements/input.js +12 -21
  33. package/dist/elements/input.js.map +1 -1
  34. package/dist/elements/label.cjs +2 -2
  35. package/dist/elements/label.cjs.map +1 -1
  36. package/dist/elements/label.js +13 -19
  37. package/dist/elements/label.js.map +1 -1
  38. package/dist/elements/pagination.cjs +2 -2
  39. package/dist/elements/pagination.cjs.map +1 -1
  40. package/dist/elements/pagination.js +71 -89
  41. package/dist/elements/pagination.js.map +1 -1
  42. package/dist/elements/popover.cjs +2 -2
  43. package/dist/elements/popover.cjs.map +1 -1
  44. package/dist/elements/popover.js +31 -37
  45. package/dist/elements/popover.js.map +1 -1
  46. package/dist/elements/search-box.cjs +2 -2
  47. package/dist/elements/search-box.cjs.map +1 -1
  48. package/dist/elements/search-box.js +25 -28
  49. package/dist/elements/search-box.js.map +1 -1
  50. package/dist/elements/select.cjs +2 -2
  51. package/dist/elements/select.cjs.map +1 -1
  52. package/dist/elements/select.js +89 -136
  53. package/dist/elements/select.js.map +1 -1
  54. package/dist/elements/separator.cjs +2 -2
  55. package/dist/elements/separator.cjs.map +1 -1
  56. package/dist/elements/separator.js +15 -26
  57. package/dist/elements/separator.js.map +1 -1
  58. package/dist/elements/sheet.cjs +2 -2
  59. package/dist/elements/sheet.cjs.map +1 -1
  60. package/dist/elements/sheet.js +71 -88
  61. package/dist/elements/sheet.js.map +1 -1
  62. package/dist/elements/sidebar.cjs +2 -2
  63. package/dist/elements/sidebar.cjs.map +1 -1
  64. package/dist/elements/sidebar.js +323 -535
  65. package/dist/elements/sidebar.js.map +1 -1
  66. package/dist/elements/skeleton.cjs +2 -2
  67. package/dist/elements/skeleton.cjs.map +1 -1
  68. package/dist/elements/skeleton.js +11 -8
  69. package/dist/elements/skeleton.js.map +1 -1
  70. package/dist/elements/spinner.cjs +2 -2
  71. package/dist/elements/spinner.cjs.map +1 -1
  72. package/dist/elements/spinner.js +30 -39
  73. package/dist/elements/spinner.js.map +1 -1
  74. package/dist/elements/table.cjs +2 -2
  75. package/dist/elements/table.cjs.map +1 -1
  76. package/dist/elements/table.js +58 -63
  77. package/dist/elements/table.js.map +1 -1
  78. package/dist/elements/tabs.cjs +2 -2
  79. package/dist/elements/tabs.cjs.map +1 -1
  80. package/dist/elements/tabs.js +31 -38
  81. package/dist/elements/tabs.js.map +1 -1
  82. package/dist/elements/tooltip.cjs +2 -2
  83. package/dist/elements/tooltip.cjs.map +1 -1
  84. package/dist/elements/tooltip.js +31 -38
  85. package/dist/elements/tooltip.js.map +1 -1
  86. package/dist/hooks/use-mobile.cjs +2 -2
  87. package/dist/hooks/use-mobile.cjs.map +1 -1
  88. package/dist/hooks/use-mobile.js +13 -14
  89. package/dist/hooks/use-mobile.js.map +1 -1
  90. package/dist/index.cjs +0 -2
  91. package/dist/index.js +0 -2
  92. package/dist/lib/utils.cjs +2 -2
  93. package/dist/lib/utils.cjs.map +1 -1
  94. package/dist/lib/utils.js +7 -8
  95. package/dist/lib/utils.js.map +1 -1
  96. package/package.json +43 -43
  97. package/dist/index.cjs.map +0 -1
  98. package/dist/index.js.map +0 -1
@@ -1,28 +1,25 @@
1
- import { jsxs as l, jsx as t } from "react/jsx-runtime";
2
- import { forwardRef as n } from "react";
3
- import { Search as c } from "lucide-react";
4
- import { Input as p } from "./input.js";
5
- import { cn as e } from "../lib/utils.js";
6
- const d = n(
7
- ({ className: a, containerClassName: o, placeholder: m = "", ...r }, s) => {
8
- const { disabled: i } = r;
9
- return /* @__PURE__ */ l("div", { className: e("relative w-full max-w-sm", o), children: [
10
- /* @__PURE__ */ t(
11
- c,
12
- {
13
- "aria-hidden": !0,
14
- className: e(
15
- "pointer-events-none absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-muted-foreground",
16
- i && "opacity-50"
17
- )
18
- }
19
- ),
20
- /* @__PURE__ */ t(p, { ref: s, type: "search", placeholder: m, className: e("pl-9", a), ...r })
21
- ] });
22
- }
23
- );
24
- d.displayName = "SearchBox";
25
- export {
26
- d as SearchBox
27
- };
28
- //# sourceMappingURL=search-box.js.map
1
+ import { cn } from "../lib/utils.js";
2
+ import { Input } from "./input.js";
3
+ import { jsx, jsxs } from "react/jsx-runtime";
4
+ import { Search } from "lucide-react";
5
+ import { forwardRef } from "react";
6
+ var SearchBox = forwardRef(({ className: a, containerClassName: o, placeholder: s = "", ...c }, l) => {
7
+ let { disabled: u } = c;
8
+ return /* @__PURE__ */ jsxs("div", {
9
+ className: cn("relative w-full max-w-sm", o),
10
+ children: [/* @__PURE__ */ jsx(Search, {
11
+ "aria-hidden": !0,
12
+ className: cn("pointer-events-none absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-muted-foreground", u && "opacity-50")
13
+ }), /* @__PURE__ */ jsx(Input, {
14
+ ref: l,
15
+ type: "search",
16
+ placeholder: s,
17
+ className: cn("pl-9", a),
18
+ ...c
19
+ })]
20
+ });
21
+ });
22
+ SearchBox.displayName = "SearchBox";
23
+ export { SearchBox };
24
+
25
+ //# sourceMappingURL=search-box.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"search-box.js","sources":["../../src/elements/search-box.tsx"],"sourcesContent":["import { forwardRef } from 'react';\nimport { Search } from 'lucide-react';\n\nimport { Input } from '@/elements/input';\nimport { cn } from '@/lib/utils';\n\nexport type SearchBoxProps = React.ComponentProps<typeof Input> & {\n containerClassName?: string;\n};\n\n/**\n * A compact search box.\n * - Uses shadcn <Input/>\n * - Leading search icon\n */\nconst SearchBox = forwardRef<HTMLInputElement, SearchBoxProps>(\n ({ className, containerClassName, placeholder = '', ...props }, ref) => {\n const { disabled } = props;\n\n return (\n <div className={cn('relative w-full max-w-sm', containerClassName)}>\n <Search\n aria-hidden\n className={cn(\n 'pointer-events-none absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-muted-foreground',\n disabled && 'opacity-50',\n )}\n />\n <Input ref={ref} type=\"search\" placeholder={placeholder} className={cn('pl-9', className)} {...props} />\n </div>\n );\n },\n);\n\nSearchBox.displayName = 'SearchBox';\n\nexport { SearchBox };\n"],"names":["SearchBox","forwardRef","className","containerClassName","placeholder","props","ref","disabled","cn","jsx","Search","Input"],"mappings":";;;;;AAeA,MAAMA,IAAYC;AAAA,EAChB,CAAC,EAAE,WAAAC,GAAW,oBAAAC,GAAoB,aAAAC,IAAc,IAAI,GAAGC,EAAA,GAASC,MAAQ;AACtE,UAAM,EAAE,UAAAC,MAAaF;AAErB,6BACG,OAAA,EAAI,WAAWG,EAAG,4BAA4BL,CAAkB,GAC/D,UAAA;AAAA,MAAA,gBAAAM;AAAA,QAACC;AAAA,QAAA;AAAA,UACC,eAAW;AAAA,UACX,WAAWF;AAAA,YACT;AAAA,YACAD,KAAY;AAAA,UAAA;AAAA,QACd;AAAA,MAAA;AAAA,MAEF,gBAAAE,EAACE,GAAA,EAAM,KAAAL,GAAU,MAAK,UAAS,aAAAF,GAA0B,WAAWI,EAAG,QAAQN,CAAS,GAAI,GAAGG,EAAA,CAAO;AAAA,IAAA,GACxG;AAAA,EAEJ;AACF;AAEAL,EAAU,cAAc;"}
1
+ {"version":3,"file":"search-box.js","names":[],"sources":["../../src/elements/search-box.tsx"],"sourcesContent":["import { forwardRef } from 'react';\nimport { Search } from 'lucide-react';\n\nimport { Input } from '@/elements/input';\nimport { cn } from '@/lib/utils';\n\nexport type SearchBoxProps = React.ComponentProps<typeof Input> & {\n containerClassName?: string;\n};\n\n/**\n * A compact search box.\n * - Uses shadcn <Input/>\n * - Leading search icon\n */\nconst SearchBox = forwardRef<HTMLInputElement, SearchBoxProps>(\n ({ className, containerClassName, placeholder = '', ...props }, ref) => {\n const { disabled } = props;\n\n return (\n <div className={cn('relative w-full max-w-sm', containerClassName)}>\n <Search\n aria-hidden\n className={cn(\n 'pointer-events-none absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-muted-foreground',\n disabled && 'opacity-50',\n )}\n />\n <Input ref={ref} type=\"search\" placeholder={placeholder} className={cn('pl-9', className)} {...props} />\n </div>\n );\n },\n);\n\nSearchBox.displayName = 'SearchBox';\n\nexport { SearchBox };\n"],"mappings":";;;;;AAeA,IAAM,YAAY,YACf,EAAE,cAAW,uBAAoB,iBAAc,IAAI,GAAG,KAAS,MAAQ;CACtE,IAAM,EAAE,gBAAa;AAErB,QACE,qBAAC,OAAA;EAAI,WAAW,GAAG,4BAA4B,EAAmB;aAChE,oBAAC,QAAA;GACC,eAAA;GACA,WAAW,GACT,8FACA,KAAY,aACb;IACD,EACF,oBAAC,OAAA;GAAW;GAAK,MAAK;GAAsB;GAAa,WAAW,GAAG,QAAQ,EAAU;GAAE,GAAI;IAAS,CAAA;GACpG;EAGX;AAED,UAAU,cAAc"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),u=require("@radix-ui/react-select"),l=require("lucide-react"),n=require("../lib/utils.cjs");function p(e){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(a,r,o.get?o:{enumerable:!0,get:()=>e[r]})}}return a.default=e,Object.freeze(a)}const s=p(u);function m({...e}){return t.jsx(s.Root,{"data-slot":"select",...e})}function f({...e}){return t.jsx(s.Group,{"data-slot":"select-group",...e})}function g({...e}){return t.jsx(s.Value,{"data-slot":"select-value",...e})}function x({className:e,size:a="default",children:r,asChild:o=!1,...i}){return o?t.jsx(s.Trigger,{...i,asChild:!0,children:r}):t.jsxs(s.Trigger,{"data-slot":"select-trigger","data-size":a,className:n.cn("border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...i,children:[r,t.jsx(s.Icon,{asChild:!0,children:t.jsx(l.ChevronDownIcon,{className:"size-4 opacity-50"})})]})}function c({className:e,...a}){return t.jsx(s.ScrollUpButton,{"data-slot":"select-scroll-up-button",className:n.cn("flex cursor-default items-center justify-center py-1",e),...a,children:t.jsx(l.ChevronUpIcon,{className:"size-4"})})}function d({className:e,...a}){return t.jsx(s.ScrollDownButton,{"data-slot":"select-scroll-down-button",className:n.cn("flex cursor-default items-center justify-center py-1",e),...a,children:t.jsx(l.ChevronDownIcon,{className:"size-4"})})}function v({className:e,children:a,position:r="popper",...o}){return t.jsx(s.Portal,{children:t.jsxs(s.Content,{"data-slot":"select-content",className:n.cn("bg-popover text-popover-foreground 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 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md",r==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:r,...o,children:[t.jsx(c,{}),t.jsx(s.Viewport,{className:n.cn("p-1",r==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),children:a}),t.jsx(d,{})]})})}function b({className:e,...a}){return t.jsx(s.Label,{"data-slot":"select-label",className:n.cn("text-muted-foreground px-2 py-1.5 text-xs",e),...a})}function h({className:e,children:a,...r}){return t.jsxs(s.Item,{"data-slot":"select-item",className:n.cn("focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",e),...r,children:[t.jsx("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:t.jsx(s.ItemIndicator,{children:t.jsx(l.CheckIcon,{className:"size-4"})})}),t.jsx(s.ItemText,{children:a})]})}function S({className:e,...a}){return t.jsx(s.Separator,{"data-slot":"select-separator",className:n.cn("bg-border pointer-events-none -mx-1 my-1 h-px",e),...a})}exports.Select=m;exports.SelectContent=v;exports.SelectGroup=f;exports.SelectItem=h;exports.SelectLabel=b;exports.SelectScrollDownButton=d;exports.SelectScrollUpButton=c;exports.SelectSeparator=S;exports.SelectTrigger=x;exports.SelectValue=g;
2
- //# sourceMappingURL=select.cjs.map
1
+ "use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`../_virtual/rolldown:runtime.cjs`),t=require(`../lib/utils.cjs`);let n=require(`react/jsx-runtime`),r=require(`lucide-react`),i=require(`@radix-ui/react-select`);i=e.__toESM(i);function a({...e}){return(0,n.jsx)(i.Root,{"data-slot":`select`,...e})}function o({...e}){return(0,n.jsx)(i.Group,{"data-slot":`select-group`,...e})}function s({...e}){return(0,n.jsx)(i.Value,{"data-slot":`select-value`,...e})}function c({className:e,size:a=`default`,children:o,asChild:s=!1,...c}){return s?(0,n.jsx)(i.Trigger,{...c,asChild:!0,children:o}):(0,n.jsxs)(i.Trigger,{"data-slot":`select-trigger`,"data-size":a,className:t.cn(`border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,e),...c,children:[o,(0,n.jsx)(i.Icon,{asChild:!0,children:(0,n.jsx)(r.ChevronDownIcon,{className:`size-4 opacity-50`})})]})}function l({className:e,...a}){return(0,n.jsx)(i.ScrollUpButton,{"data-slot":`select-scroll-up-button`,className:t.cn(`flex cursor-default items-center justify-center py-1`,e),...a,children:(0,n.jsx)(r.ChevronUpIcon,{className:`size-4`})})}function u({className:e,...a}){return(0,n.jsx)(i.ScrollDownButton,{"data-slot":`select-scroll-down-button`,className:t.cn(`flex cursor-default items-center justify-center py-1`,e),...a,children:(0,n.jsx)(r.ChevronDownIcon,{className:`size-4`})})}function d({className:e,children:r,position:a=`popper`,...o}){return(0,n.jsx)(i.Portal,{children:(0,n.jsxs)(i.Content,{"data-slot":`select-content`,className:t.cn(`bg-popover text-popover-foreground 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 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md`,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`,e),position:a,...o,children:[(0,n.jsx)(l,{}),(0,n.jsx)(i.Viewport,{className:t.cn(`p-1`,a===`popper`&&`h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1`),children:r}),(0,n.jsx)(u,{})]})})}function f({className:e,...r}){return(0,n.jsx)(i.Label,{"data-slot":`select-label`,className:t.cn(`text-muted-foreground px-2 py-1.5 text-xs`,e),...r})}function p({className:e,children:a,...o}){return(0,n.jsxs)(i.Item,{"data-slot":`select-item`,className:t.cn(`focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2`,e),...o,children:[(0,n.jsx)(`span`,{className:`absolute right-2 flex size-3.5 items-center justify-center`,children:(0,n.jsx)(i.ItemIndicator,{children:(0,n.jsx)(r.CheckIcon,{className:`size-4`})})}),(0,n.jsx)(i.ItemText,{children:a})]})}function m({className:e,...r}){return(0,n.jsx)(i.Separator,{"data-slot":`select-separator`,className:t.cn(`bg-border pointer-events-none -mx-1 my-1 h-px`,e),...r})}exports.Select=a,exports.SelectContent=d,exports.SelectGroup=o,exports.SelectItem=p,exports.SelectLabel=f,exports.SelectScrollDownButton=u,exports.SelectScrollUpButton=l,exports.SelectSeparator=m,exports.SelectTrigger=c,exports.SelectValue=s;
2
+ //# sourceMappingURL=select.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"select.cjs","sources":["../../src/elements/select.tsx"],"sourcesContent":["'use client';\n\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { CheckIcon, ChevronDownIcon, ChevronUpIcon } from 'lucide-react';\n\nimport { cn } from '@/lib/utils';\n\nfunction Select({ ...props }: React.ComponentProps<typeof SelectPrimitive.Root>) {\n return <SelectPrimitive.Root data-slot=\"select\" {...props} />;\n}\n\nfunction SelectGroup({ ...props }: React.ComponentProps<typeof SelectPrimitive.Group>) {\n return <SelectPrimitive.Group data-slot=\"select-group\" {...props} />;\n}\n\nfunction SelectValue({ ...props }: React.ComponentProps<typeof SelectPrimitive.Value>) {\n return <SelectPrimitive.Value data-slot=\"select-value\" {...props} />;\n}\n\nfunction SelectTrigger({\n className,\n size = 'default',\n children,\n asChild = false,\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.Trigger> & {\n size?: 'sm' | 'default';\n}) {\n if (asChild) {\n return (\n <SelectPrimitive.Trigger {...props} asChild>\n {children}\n </SelectPrimitive.Trigger>\n );\n }\n\n return (\n <SelectPrimitive.Trigger\n data-slot=\"select-trigger\"\n data-size={size}\n className={cn(\n \"border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n className,\n )}\n {...props}\n >\n {children}\n <SelectPrimitive.Icon asChild>\n <ChevronDownIcon className=\"size-4 opacity-50\" />\n </SelectPrimitive.Icon>\n </SelectPrimitive.Trigger>\n );\n}\n\nfunction SelectScrollUpButton({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.ScrollUpButton>) {\n return (\n <SelectPrimitive.ScrollUpButton\n data-slot=\"select-scroll-up-button\"\n className={cn('flex cursor-default items-center justify-center py-1', className)}\n {...props}\n >\n <ChevronUpIcon className=\"size-4\" />\n </SelectPrimitive.ScrollUpButton>\n );\n}\n\nfunction SelectScrollDownButton({\n className,\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.ScrollDownButton>) {\n return (\n <SelectPrimitive.ScrollDownButton\n data-slot=\"select-scroll-down-button\"\n className={cn('flex cursor-default items-center justify-center py-1', className)}\n {...props}\n >\n <ChevronDownIcon className=\"size-4\" />\n </SelectPrimitive.ScrollDownButton>\n );\n}\n\nfunction SelectContent({\n className,\n children,\n position = 'popper',\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.Content>) {\n return (\n <SelectPrimitive.Portal>\n <SelectPrimitive.Content\n data-slot=\"select-content\"\n className={cn(\n 'bg-popover text-popover-foreground 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 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md',\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 'h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1',\n )}\n >\n {children}\n </SelectPrimitive.Viewport>\n <SelectScrollDownButton />\n </SelectPrimitive.Content>\n </SelectPrimitive.Portal>\n );\n}\n\nfunction SelectLabel({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Label>) {\n return (\n <SelectPrimitive.Label\n data-slot=\"select-label\"\n className={cn('text-muted-foreground px-2 py-1.5 text-xs', className)}\n {...props}\n />\n );\n}\n\nfunction SelectItem({ className, children, ...props }: React.ComponentProps<typeof SelectPrimitive.Item>) {\n return (\n <SelectPrimitive.Item\n data-slot=\"select-item\"\n className={cn(\n \"focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2\",\n className,\n )}\n {...props}\n >\n <span className=\"absolute right-2 flex size-3.5 items-center justify-center\">\n <SelectPrimitive.ItemIndicator>\n <CheckIcon className=\"size-4\" />\n </SelectPrimitive.ItemIndicator>\n </span>\n <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>\n </SelectPrimitive.Item>\n );\n}\n\nfunction SelectSeparator({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Separator>) {\n return (\n <SelectPrimitive.Separator\n data-slot=\"select-separator\"\n className={cn('bg-border pointer-events-none -mx-1 my-1 h-px', className)}\n {...props}\n />\n );\n}\n\nexport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectLabel,\n SelectScrollDownButton,\n SelectScrollUpButton,\n SelectSeparator,\n SelectTrigger,\n SelectValue,\n};\n"],"names":["Select","props","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","className","size","children","asChild","jsx","jsxs","cn","ChevronDownIcon","SelectScrollUpButton","ChevronUpIcon","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","CheckIcon","SelectSeparator"],"mappings":"2eAOA,SAASA,EAAO,CAAE,GAAGC,GAA4D,CAC/E,aAAQC,EAAgB,KAAhB,CAAqB,YAAU,SAAU,GAAGD,EAAO,CAC7D,CAEA,SAASE,EAAY,CAAE,GAAGF,GAA6D,CACrF,aAAQC,EAAgB,MAAhB,CAAsB,YAAU,eAAgB,GAAGD,EAAO,CACpE,CAEA,SAASG,EAAY,CAAE,GAAGH,GAA6D,CACrF,aAAQC,EAAgB,MAAhB,CAAsB,YAAU,eAAgB,GAAGD,EAAO,CACpE,CAEA,SAASI,EAAc,CACrB,UAAAC,EACA,KAAAC,EAAO,UACP,SAAAC,EACA,QAAAC,EAAU,GACV,GAAGR,CACL,EAEG,CACD,OAAIQ,EAEAC,EAAAA,IAACR,EAAgB,QAAhB,CAAyB,GAAGD,EAAO,QAAO,GACxC,SAAAO,EACH,EAKFG,EAAAA,KAACT,EAAgB,QAAhB,CACC,YAAU,iBACV,YAAWK,EACX,UAAWK,EAAAA,GACT,+yBACAN,CAAA,EAED,GAAGL,EAEH,SAAA,CAAAO,EACDE,EAAAA,IAACR,EAAgB,KAAhB,CAAqB,QAAO,GAC3B,SAAAQ,EAAAA,IAACG,EAAAA,gBAAA,CAAgB,UAAU,mBAAA,CAAoB,CAAA,CACjD,CAAA,CAAA,CAAA,CAGN,CAEA,SAASC,EAAqB,CAAE,UAAAR,EAAW,GAAGL,GAAsE,CAClH,OACES,EAAAA,IAACR,EAAgB,eAAhB,CACC,YAAU,0BACV,UAAWU,EAAAA,GAAG,uDAAwDN,CAAS,EAC9E,GAAGL,EAEJ,SAAAS,EAAAA,IAACK,EAAAA,cAAA,CAAc,UAAU,QAAA,CAAS,CAAA,CAAA,CAGxC,CAEA,SAASC,EAAuB,CAC9B,UAAAV,EACA,GAAGL,CACL,EAAkE,CAChE,OACES,EAAAA,IAACR,EAAgB,iBAAhB,CACC,YAAU,4BACV,UAAWU,EAAAA,GAAG,uDAAwDN,CAAS,EAC9E,GAAGL,EAEJ,SAAAS,EAAAA,IAACG,EAAAA,gBAAA,CAAgB,UAAU,QAAA,CAAS,CAAA,CAAA,CAG1C,CAEA,SAASI,EAAc,CACrB,UAAAX,EACA,SAAAE,EACA,SAAAU,EAAW,SACX,GAAGjB,CACL,EAAyD,CACvD,OACES,EAAAA,IAACR,EAAgB,OAAhB,CACC,SAAAS,EAAAA,KAACT,EAAgB,QAAhB,CACC,YAAU,iBACV,UAAWU,EAAAA,GACT,gjBACAM,IAAa,UACX,kIACFZ,CAAA,EAEF,SAAAY,EACC,GAAGjB,EAEJ,SAAA,CAAAS,EAAAA,IAACI,EAAA,EAAqB,EACtBJ,EAAAA,IAACR,EAAgB,SAAhB,CACC,UAAWU,EAAAA,GACT,MACAM,IAAa,UACX,qGAAA,EAGH,SAAAV,CAAA,CAAA,QAEFQ,EAAA,CAAA,CAAuB,CAAA,CAAA,CAAA,EAE5B,CAEJ,CAEA,SAASG,EAAY,CAAE,UAAAb,EAAW,GAAGL,GAA6D,CAChG,OACES,EAAAA,IAACR,EAAgB,MAAhB,CACC,YAAU,eACV,UAAWU,EAAAA,GAAG,4CAA6CN,CAAS,EACnE,GAAGL,CAAA,CAAA,CAGV,CAEA,SAASmB,EAAW,CAAE,UAAAd,EAAW,SAAAE,EAAU,GAAGP,GAA4D,CACxG,OACEU,EAAAA,KAACT,EAAgB,KAAhB,CACC,YAAU,cACV,UAAWU,EAAAA,GACT,4aACAN,CAAA,EAED,GAAGL,EAEJ,SAAA,CAAAS,EAAAA,IAAC,OAAA,CAAK,UAAU,6DACd,SAAAA,EAAAA,IAACR,EAAgB,cAAhB,CACC,SAAAQ,EAAAA,IAACW,YAAA,CAAU,UAAU,QAAA,CAAS,CAAA,CAChC,EACF,EACAX,EAAAA,IAACR,EAAgB,SAAhB,CAA0B,SAAAM,CAAA,CAAS,CAAA,CAAA,CAAA,CAG1C,CAEA,SAASc,EAAgB,CAAE,UAAAhB,EAAW,GAAGL,GAAiE,CACxG,OACES,EAAAA,IAACR,EAAgB,UAAhB,CACC,YAAU,mBACV,UAAWU,EAAAA,GAAG,gDAAiDN,CAAS,EACvE,GAAGL,CAAA,CAAA,CAGV"}
1
+ {"version":3,"file":"select.cjs","names":[],"sources":["../../src/elements/select.tsx"],"sourcesContent":["'use client';\n\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { CheckIcon, ChevronDownIcon, ChevronUpIcon } from 'lucide-react';\n\nimport { cn } from '@/lib/utils';\n\nfunction Select({ ...props }: React.ComponentProps<typeof SelectPrimitive.Root>) {\n return <SelectPrimitive.Root data-slot=\"select\" {...props} />;\n}\n\nfunction SelectGroup({ ...props }: React.ComponentProps<typeof SelectPrimitive.Group>) {\n return <SelectPrimitive.Group data-slot=\"select-group\" {...props} />;\n}\n\nfunction SelectValue({ ...props }: React.ComponentProps<typeof SelectPrimitive.Value>) {\n return <SelectPrimitive.Value data-slot=\"select-value\" {...props} />;\n}\n\nfunction SelectTrigger({\n className,\n size = 'default',\n children,\n asChild = false,\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.Trigger> & {\n size?: 'sm' | 'default';\n}) {\n if (asChild) {\n return (\n <SelectPrimitive.Trigger {...props} asChild>\n {children}\n </SelectPrimitive.Trigger>\n );\n }\n\n return (\n <SelectPrimitive.Trigger\n data-slot=\"select-trigger\"\n data-size={size}\n className={cn(\n \"border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n className,\n )}\n {...props}\n >\n {children}\n <SelectPrimitive.Icon asChild>\n <ChevronDownIcon className=\"size-4 opacity-50\" />\n </SelectPrimitive.Icon>\n </SelectPrimitive.Trigger>\n );\n}\n\nfunction SelectScrollUpButton({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.ScrollUpButton>) {\n return (\n <SelectPrimitive.ScrollUpButton\n data-slot=\"select-scroll-up-button\"\n className={cn('flex cursor-default items-center justify-center py-1', className)}\n {...props}\n >\n <ChevronUpIcon className=\"size-4\" />\n </SelectPrimitive.ScrollUpButton>\n );\n}\n\nfunction SelectScrollDownButton({\n className,\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.ScrollDownButton>) {\n return (\n <SelectPrimitive.ScrollDownButton\n data-slot=\"select-scroll-down-button\"\n className={cn('flex cursor-default items-center justify-center py-1', className)}\n {...props}\n >\n <ChevronDownIcon className=\"size-4\" />\n </SelectPrimitive.ScrollDownButton>\n );\n}\n\nfunction SelectContent({\n className,\n children,\n position = 'popper',\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.Content>) {\n return (\n <SelectPrimitive.Portal>\n <SelectPrimitive.Content\n data-slot=\"select-content\"\n className={cn(\n 'bg-popover text-popover-foreground 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 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md',\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 'h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1',\n )}\n >\n {children}\n </SelectPrimitive.Viewport>\n <SelectScrollDownButton />\n </SelectPrimitive.Content>\n </SelectPrimitive.Portal>\n );\n}\n\nfunction SelectLabel({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Label>) {\n return (\n <SelectPrimitive.Label\n data-slot=\"select-label\"\n className={cn('text-muted-foreground px-2 py-1.5 text-xs', className)}\n {...props}\n />\n );\n}\n\nfunction SelectItem({ className, children, ...props }: React.ComponentProps<typeof SelectPrimitive.Item>) {\n return (\n <SelectPrimitive.Item\n data-slot=\"select-item\"\n className={cn(\n \"focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2\",\n className,\n )}\n {...props}\n >\n <span className=\"absolute right-2 flex size-3.5 items-center justify-center\">\n <SelectPrimitive.ItemIndicator>\n <CheckIcon className=\"size-4\" />\n </SelectPrimitive.ItemIndicator>\n </span>\n <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>\n </SelectPrimitive.Item>\n );\n}\n\nfunction SelectSeparator({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Separator>) {\n return (\n <SelectPrimitive.Separator\n data-slot=\"select-separator\"\n className={cn('bg-border pointer-events-none -mx-1 my-1 h-px', className)}\n {...props}\n />\n );\n}\n\nexport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectLabel,\n SelectScrollDownButton,\n SelectScrollUpButton,\n SelectSeparator,\n SelectTrigger,\n SelectValue,\n};\n"],"mappings":"kRAOA,SAAS,EAAO,CAAE,GAAG,GAA4D,CAC/E,OAAO,EAAA,EAAA,KAAC,EAAgB,KAAA,CAAK,YAAU,SAAS,GAAI,GAAS,CAG/D,SAAS,EAAY,CAAE,GAAG,GAA6D,CACrF,OAAO,EAAA,EAAA,KAAC,EAAgB,MAAA,CAAM,YAAU,eAAe,GAAI,GAAS,CAGtE,SAAS,EAAY,CAAE,GAAG,GAA6D,CACrF,OAAO,EAAA,EAAA,KAAC,EAAgB,MAAA,CAAM,YAAU,eAAe,GAAI,GAAS,CAGtE,SAAS,EAAc,CACrB,YACA,OAAO,UACP,WACA,UAAU,GACV,GAAG,GAGF,CASD,OARI,GAEA,EAAA,EAAA,KAAC,EAAgB,QAAA,CAAQ,GAAI,EAAO,QAAA,GACjC,YACuB,EAK5B,EAAA,EAAA,MAAC,EAAgB,QAAA,CACf,YAAU,iBACV,YAAW,EACX,UAAW,EAAA,GACT,+yBACA,EACD,CACD,GAAI,YAEH,GACD,EAAA,EAAA,KAAC,EAAgB,KAAA,CAAK,QAAA,aACpB,EAAA,EAAA,KAAC,EAAA,gBAAA,CAAgB,UAAU,oBAAA,CAAsB,EAC5B,CAAA,EACC,CAI9B,SAAS,EAAqB,CAAE,YAAW,GAAG,GAAsE,CAClH,OACE,EAAA,EAAA,KAAC,EAAgB,eAAA,CACf,YAAU,0BACV,UAAW,EAAA,GAAG,uDAAwD,EAAU,CAChF,GAAI,YAEJ,EAAA,EAAA,KAAC,EAAA,cAAA,CAAc,UAAU,SAAA,CAAW,EACL,CAIrC,SAAS,EAAuB,CAC9B,YACA,GAAG,GAC6D,CAChE,OACE,EAAA,EAAA,KAAC,EAAgB,iBAAA,CACf,YAAU,4BACV,UAAW,EAAA,GAAG,uDAAwD,EAAU,CAChF,GAAI,YAEJ,EAAA,EAAA,KAAC,EAAA,gBAAA,CAAgB,UAAU,SAAA,CAAW,EACL,CAIvC,SAAS,EAAc,CACrB,YACA,WACA,WAAW,SACX,GAAG,GACoD,CACvD,OACE,EAAA,EAAA,KAAC,EAAgB,OAAA,CAAA,UACf,EAAA,EAAA,MAAC,EAAgB,QAAA,CACf,YAAU,iBACV,UAAW,EAAA,GACT,gjBACA,IAAa,UACX,kIACF,EACD,CACS,WACV,GAAI,aAEJ,EAAA,EAAA,KAAC,EAAA,EAAA,CAAuB,EACxB,EAAA,EAAA,KAAC,EAAgB,SAAA,CACf,UAAW,EAAA,GACT,MACA,IAAa,UACX,sGACH,CAEA,YACwB,EAC3B,EAAA,EAAA,KAAC,EAAA,EAAA,CAAyB,GACF,CAAA,CACH,CAI7B,SAAS,EAAY,CAAE,YAAW,GAAG,GAA6D,CAChG,OACE,EAAA,EAAA,KAAC,EAAgB,MAAA,CACf,YAAU,eACV,UAAW,EAAA,GAAG,4CAA6C,EAAU,CACrE,GAAI,GACJ,CAIN,SAAS,EAAW,CAAE,YAAW,WAAU,GAAG,GAA4D,CACxG,OACE,EAAA,EAAA,MAAC,EAAgB,KAAA,CACf,YAAU,cACV,UAAW,EAAA,GACT,4aACA,EACD,CACD,GAAI,aAEJ,EAAA,EAAA,KAAC,OAAA,CAAK,UAAU,uEACd,EAAA,EAAA,KAAC,EAAgB,cAAA,CAAA,UACf,EAAA,EAAA,KAAC,EAAA,UAAA,CAAU,UAAU,SAAA,CAAW,CAAA,CACF,EAC3B,EACP,EAAA,EAAA,KAAC,EAAgB,SAAA,CAAU,WAAA,CAAoC,CAAA,EAC1C,CAI3B,SAAS,EAAgB,CAAE,YAAW,GAAG,GAAiE,CACxG,OACE,EAAA,EAAA,KAAC,EAAgB,UAAA,CACf,YAAU,mBACV,UAAW,EAAA,GAAG,gDAAiD,EAAU,CACzE,GAAI,GACJ"}
@@ -1,146 +1,99 @@
1
- import { jsx as e, jsxs as l } from "react/jsx-runtime";
2
- import * as a from "@radix-ui/react-select";
3
- import { CheckIcon as c, ChevronDownIcon as d, ChevronUpIcon as u } from "lucide-react";
4
- import { cn as o } from "../lib/utils.js";
5
- function x({ ...t }) {
6
- return /* @__PURE__ */ e(a.Root, { "data-slot": "select", ...t });
1
+ "use client";
2
+ import { cn } from "../lib/utils.js";
3
+ import { jsx, jsxs } from "react/jsx-runtime";
4
+ import { CheckIcon, ChevronDownIcon, ChevronUpIcon } from "lucide-react";
5
+ import * as SelectPrimitive from "@radix-ui/react-select";
6
+ function Select({ ...e }) {
7
+ return /* @__PURE__ */ jsx(SelectPrimitive.Root, {
8
+ "data-slot": "select",
9
+ ...e
10
+ });
7
11
  }
8
- function h({ ...t }) {
9
- return /* @__PURE__ */ e(a.Group, { "data-slot": "select-group", ...t });
12
+ function SelectGroup({ ...e }) {
13
+ return /* @__PURE__ */ jsx(SelectPrimitive.Group, {
14
+ "data-slot": "select-group",
15
+ ...e
16
+ });
10
17
  }
11
- function b({ ...t }) {
12
- return /* @__PURE__ */ e(a.Value, { "data-slot": "select-value", ...t });
18
+ function SelectValue({ ...e }) {
19
+ return /* @__PURE__ */ jsx(SelectPrimitive.Value, {
20
+ "data-slot": "select-value",
21
+ ...e
22
+ });
13
23
  }
14
- function w({
15
- className: t,
16
- size: r = "default",
17
- children: s,
18
- asChild: n = !1,
19
- ...i
20
- }) {
21
- return n ? /* @__PURE__ */ e(a.Trigger, { ...i, asChild: !0, children: s }) : /* @__PURE__ */ l(
22
- a.Trigger,
23
- {
24
- "data-slot": "select-trigger",
25
- "data-size": r,
26
- className: o(
27
- "border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
28
- t
29
- ),
30
- ...i,
31
- children: [
32
- s,
33
- /* @__PURE__ */ e(a.Icon, { asChild: !0, children: /* @__PURE__ */ e(d, { className: "size-4 opacity-50" }) })
34
- ]
35
- }
36
- );
24
+ function SelectTrigger({ className: d, size: p = "default", children: m, asChild: h = !1, ...g }) {
25
+ return h ? /* @__PURE__ */ jsx(SelectPrimitive.Trigger, {
26
+ ...g,
27
+ asChild: !0,
28
+ children: m
29
+ }) : /* @__PURE__ */ jsxs(SelectPrimitive.Trigger, {
30
+ "data-slot": "select-trigger",
31
+ "data-size": p,
32
+ className: cn("border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", d),
33
+ ...g,
34
+ children: [m, /* @__PURE__ */ jsx(SelectPrimitive.Icon, {
35
+ asChild: !0,
36
+ children: /* @__PURE__ */ jsx(ChevronDownIcon, { className: "size-4 opacity-50" })
37
+ })]
38
+ });
37
39
  }
38
- function p({ className: t, ...r }) {
39
- return /* @__PURE__ */ e(
40
- a.ScrollUpButton,
41
- {
42
- "data-slot": "select-scroll-up-button",
43
- className: o("flex cursor-default items-center justify-center py-1", t),
44
- ...r,
45
- children: /* @__PURE__ */ e(u, { className: "size-4" })
46
- }
47
- );
40
+ function SelectScrollUpButton({ className: u, ...d }) {
41
+ return /* @__PURE__ */ jsx(SelectPrimitive.ScrollUpButton, {
42
+ "data-slot": "select-scroll-up-button",
43
+ className: cn("flex cursor-default items-center justify-center py-1", u),
44
+ ...d,
45
+ children: /* @__PURE__ */ jsx(ChevronUpIcon, { className: "size-4" })
46
+ });
48
47
  }
49
- function m({
50
- className: t,
51
- ...r
52
- }) {
53
- return /* @__PURE__ */ e(
54
- a.ScrollDownButton,
55
- {
56
- "data-slot": "select-scroll-down-button",
57
- className: o("flex cursor-default items-center justify-center py-1", t),
58
- ...r,
59
- children: /* @__PURE__ */ e(d, { className: "size-4" })
60
- }
61
- );
48
+ function SelectScrollDownButton({ className: u, ...d }) {
49
+ return /* @__PURE__ */ jsx(SelectPrimitive.ScrollDownButton, {
50
+ "data-slot": "select-scroll-down-button",
51
+ className: cn("flex cursor-default items-center justify-center py-1", u),
52
+ ...d,
53
+ children: /* @__PURE__ */ jsx(ChevronDownIcon, { className: "size-4" })
54
+ });
62
55
  }
63
- function y({
64
- className: t,
65
- children: r,
66
- position: s = "popper",
67
- ...n
68
- }) {
69
- return /* @__PURE__ */ e(a.Portal, { children: /* @__PURE__ */ l(
70
- a.Content,
71
- {
72
- "data-slot": "select-content",
73
- className: o(
74
- "bg-popover text-popover-foreground 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 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md",
75
- s === "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",
76
- t
77
- ),
78
- position: s,
79
- ...n,
80
- children: [
81
- /* @__PURE__ */ e(p, {}),
82
- /* @__PURE__ */ e(
83
- a.Viewport,
84
- {
85
- className: o(
86
- "p-1",
87
- s === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"
88
- ),
89
- children: r
90
- }
91
- ),
92
- /* @__PURE__ */ e(m, {})
93
- ]
94
- }
95
- ) });
56
+ function SelectContent({ className: d, children: f, position: p = "popper", ...m }) {
57
+ return /* @__PURE__ */ jsx(SelectPrimitive.Portal, { children: /* @__PURE__ */ jsxs(SelectPrimitive.Content, {
58
+ "data-slot": "select-content",
59
+ className: cn("bg-popover text-popover-foreground 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 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md", p === "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", d),
60
+ position: p,
61
+ ...m,
62
+ children: [
63
+ /* @__PURE__ */ jsx(SelectScrollUpButton, {}),
64
+ /* @__PURE__ */ jsx(SelectPrimitive.Viewport, {
65
+ className: cn("p-1", p === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),
66
+ children: f
67
+ }),
68
+ /* @__PURE__ */ jsx(SelectScrollDownButton, {})
69
+ ]
70
+ }) });
96
71
  }
97
- function S({ className: t, ...r }) {
98
- return /* @__PURE__ */ e(
99
- a.Label,
100
- {
101
- "data-slot": "select-label",
102
- className: o("text-muted-foreground px-2 py-1.5 text-xs", t),
103
- ...r
104
- }
105
- );
72
+ function SelectLabel({ className: u, ...d }) {
73
+ return /* @__PURE__ */ jsx(SelectPrimitive.Label, {
74
+ "data-slot": "select-label",
75
+ className: cn("text-muted-foreground px-2 py-1.5 text-xs", u),
76
+ ...d
77
+ });
106
78
  }
107
- function z({ className: t, children: r, ...s }) {
108
- return /* @__PURE__ */ l(
109
- a.Item,
110
- {
111
- "data-slot": "select-item",
112
- className: o(
113
- "focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",
114
- t
115
- ),
116
- ...s,
117
- children: [
118
- /* @__PURE__ */ e("span", { className: "absolute right-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ e(a.ItemIndicator, { children: /* @__PURE__ */ e(c, { className: "size-4" }) }) }),
119
- /* @__PURE__ */ e(a.ItemText, { children: r })
120
- ]
121
- }
122
- );
79
+ function SelectItem({ className: f, children: p, ...m }) {
80
+ return /* @__PURE__ */ jsxs(SelectPrimitive.Item, {
81
+ "data-slot": "select-item",
82
+ className: cn("focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2", f),
83
+ ...m,
84
+ children: [/* @__PURE__ */ jsx("span", {
85
+ className: "absolute right-2 flex size-3.5 items-center justify-center",
86
+ children: /* @__PURE__ */ jsx(SelectPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, { className: "size-4" }) })
87
+ }), /* @__PURE__ */ jsx(SelectPrimitive.ItemText, { children: p })]
88
+ });
123
89
  }
124
- function N({ className: t, ...r }) {
125
- return /* @__PURE__ */ e(
126
- a.Separator,
127
- {
128
- "data-slot": "select-separator",
129
- className: o("bg-border pointer-events-none -mx-1 my-1 h-px", t),
130
- ...r
131
- }
132
- );
90
+ function SelectSeparator({ className: u, ...d }) {
91
+ return /* @__PURE__ */ jsx(SelectPrimitive.Separator, {
92
+ "data-slot": "select-separator",
93
+ className: cn("bg-border pointer-events-none -mx-1 my-1 h-px", u),
94
+ ...d
95
+ });
133
96
  }
134
- export {
135
- x as Select,
136
- y as SelectContent,
137
- h as SelectGroup,
138
- z as SelectItem,
139
- S as SelectLabel,
140
- m as SelectScrollDownButton,
141
- p as SelectScrollUpButton,
142
- N as SelectSeparator,
143
- w as SelectTrigger,
144
- b as SelectValue
145
- };
146
- //# sourceMappingURL=select.js.map
97
+ export { Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue };
98
+
99
+ //# sourceMappingURL=select.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"select.js","sources":["../../src/elements/select.tsx"],"sourcesContent":["'use client';\n\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { CheckIcon, ChevronDownIcon, ChevronUpIcon } from 'lucide-react';\n\nimport { cn } from '@/lib/utils';\n\nfunction Select({ ...props }: React.ComponentProps<typeof SelectPrimitive.Root>) {\n return <SelectPrimitive.Root data-slot=\"select\" {...props} />;\n}\n\nfunction SelectGroup({ ...props }: React.ComponentProps<typeof SelectPrimitive.Group>) {\n return <SelectPrimitive.Group data-slot=\"select-group\" {...props} />;\n}\n\nfunction SelectValue({ ...props }: React.ComponentProps<typeof SelectPrimitive.Value>) {\n return <SelectPrimitive.Value data-slot=\"select-value\" {...props} />;\n}\n\nfunction SelectTrigger({\n className,\n size = 'default',\n children,\n asChild = false,\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.Trigger> & {\n size?: 'sm' | 'default';\n}) {\n if (asChild) {\n return (\n <SelectPrimitive.Trigger {...props} asChild>\n {children}\n </SelectPrimitive.Trigger>\n );\n }\n\n return (\n <SelectPrimitive.Trigger\n data-slot=\"select-trigger\"\n data-size={size}\n className={cn(\n \"border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n className,\n )}\n {...props}\n >\n {children}\n <SelectPrimitive.Icon asChild>\n <ChevronDownIcon className=\"size-4 opacity-50\" />\n </SelectPrimitive.Icon>\n </SelectPrimitive.Trigger>\n );\n}\n\nfunction SelectScrollUpButton({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.ScrollUpButton>) {\n return (\n <SelectPrimitive.ScrollUpButton\n data-slot=\"select-scroll-up-button\"\n className={cn('flex cursor-default items-center justify-center py-1', className)}\n {...props}\n >\n <ChevronUpIcon className=\"size-4\" />\n </SelectPrimitive.ScrollUpButton>\n );\n}\n\nfunction SelectScrollDownButton({\n className,\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.ScrollDownButton>) {\n return (\n <SelectPrimitive.ScrollDownButton\n data-slot=\"select-scroll-down-button\"\n className={cn('flex cursor-default items-center justify-center py-1', className)}\n {...props}\n >\n <ChevronDownIcon className=\"size-4\" />\n </SelectPrimitive.ScrollDownButton>\n );\n}\n\nfunction SelectContent({\n className,\n children,\n position = 'popper',\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.Content>) {\n return (\n <SelectPrimitive.Portal>\n <SelectPrimitive.Content\n data-slot=\"select-content\"\n className={cn(\n 'bg-popover text-popover-foreground 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 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md',\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 'h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1',\n )}\n >\n {children}\n </SelectPrimitive.Viewport>\n <SelectScrollDownButton />\n </SelectPrimitive.Content>\n </SelectPrimitive.Portal>\n );\n}\n\nfunction SelectLabel({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Label>) {\n return (\n <SelectPrimitive.Label\n data-slot=\"select-label\"\n className={cn('text-muted-foreground px-2 py-1.5 text-xs', className)}\n {...props}\n />\n );\n}\n\nfunction SelectItem({ className, children, ...props }: React.ComponentProps<typeof SelectPrimitive.Item>) {\n return (\n <SelectPrimitive.Item\n data-slot=\"select-item\"\n className={cn(\n \"focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2\",\n className,\n )}\n {...props}\n >\n <span className=\"absolute right-2 flex size-3.5 items-center justify-center\">\n <SelectPrimitive.ItemIndicator>\n <CheckIcon className=\"size-4\" />\n </SelectPrimitive.ItemIndicator>\n </span>\n <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>\n </SelectPrimitive.Item>\n );\n}\n\nfunction SelectSeparator({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Separator>) {\n return (\n <SelectPrimitive.Separator\n data-slot=\"select-separator\"\n className={cn('bg-border pointer-events-none -mx-1 my-1 h-px', className)}\n {...props}\n />\n );\n}\n\nexport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectLabel,\n SelectScrollDownButton,\n SelectScrollUpButton,\n SelectSeparator,\n SelectTrigger,\n SelectValue,\n};\n"],"names":["Select","props","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","className","size","children","asChild","jsx","jsxs","cn","ChevronDownIcon","SelectScrollUpButton","ChevronUpIcon","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","CheckIcon","SelectSeparator"],"mappings":"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"}
1
+ {"version":3,"file":"select.js","names":[],"sources":["../../src/elements/select.tsx"],"sourcesContent":["'use client';\n\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { CheckIcon, ChevronDownIcon, ChevronUpIcon } from 'lucide-react';\n\nimport { cn } from '@/lib/utils';\n\nfunction Select({ ...props }: React.ComponentProps<typeof SelectPrimitive.Root>) {\n return <SelectPrimitive.Root data-slot=\"select\" {...props} />;\n}\n\nfunction SelectGroup({ ...props }: React.ComponentProps<typeof SelectPrimitive.Group>) {\n return <SelectPrimitive.Group data-slot=\"select-group\" {...props} />;\n}\n\nfunction SelectValue({ ...props }: React.ComponentProps<typeof SelectPrimitive.Value>) {\n return <SelectPrimitive.Value data-slot=\"select-value\" {...props} />;\n}\n\nfunction SelectTrigger({\n className,\n size = 'default',\n children,\n asChild = false,\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.Trigger> & {\n size?: 'sm' | 'default';\n}) {\n if (asChild) {\n return (\n <SelectPrimitive.Trigger {...props} asChild>\n {children}\n </SelectPrimitive.Trigger>\n );\n }\n\n return (\n <SelectPrimitive.Trigger\n data-slot=\"select-trigger\"\n data-size={size}\n className={cn(\n \"border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n className,\n )}\n {...props}\n >\n {children}\n <SelectPrimitive.Icon asChild>\n <ChevronDownIcon className=\"size-4 opacity-50\" />\n </SelectPrimitive.Icon>\n </SelectPrimitive.Trigger>\n );\n}\n\nfunction SelectScrollUpButton({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.ScrollUpButton>) {\n return (\n <SelectPrimitive.ScrollUpButton\n data-slot=\"select-scroll-up-button\"\n className={cn('flex cursor-default items-center justify-center py-1', className)}\n {...props}\n >\n <ChevronUpIcon className=\"size-4\" />\n </SelectPrimitive.ScrollUpButton>\n );\n}\n\nfunction SelectScrollDownButton({\n className,\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.ScrollDownButton>) {\n return (\n <SelectPrimitive.ScrollDownButton\n data-slot=\"select-scroll-down-button\"\n className={cn('flex cursor-default items-center justify-center py-1', className)}\n {...props}\n >\n <ChevronDownIcon className=\"size-4\" />\n </SelectPrimitive.ScrollDownButton>\n );\n}\n\nfunction SelectContent({\n className,\n children,\n position = 'popper',\n ...props\n}: React.ComponentProps<typeof SelectPrimitive.Content>) {\n return (\n <SelectPrimitive.Portal>\n <SelectPrimitive.Content\n data-slot=\"select-content\"\n className={cn(\n 'bg-popover text-popover-foreground 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 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md',\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 'h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1',\n )}\n >\n {children}\n </SelectPrimitive.Viewport>\n <SelectScrollDownButton />\n </SelectPrimitive.Content>\n </SelectPrimitive.Portal>\n );\n}\n\nfunction SelectLabel({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Label>) {\n return (\n <SelectPrimitive.Label\n data-slot=\"select-label\"\n className={cn('text-muted-foreground px-2 py-1.5 text-xs', className)}\n {...props}\n />\n );\n}\n\nfunction SelectItem({ className, children, ...props }: React.ComponentProps<typeof SelectPrimitive.Item>) {\n return (\n <SelectPrimitive.Item\n data-slot=\"select-item\"\n className={cn(\n \"focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2\",\n className,\n )}\n {...props}\n >\n <span className=\"absolute right-2 flex size-3.5 items-center justify-center\">\n <SelectPrimitive.ItemIndicator>\n <CheckIcon className=\"size-4\" />\n </SelectPrimitive.ItemIndicator>\n </span>\n <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>\n </SelectPrimitive.Item>\n );\n}\n\nfunction SelectSeparator({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Separator>) {\n return (\n <SelectPrimitive.Separator\n data-slot=\"select-separator\"\n className={cn('bg-border pointer-events-none -mx-1 my-1 h-px', className)}\n {...props}\n />\n );\n}\n\nexport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectLabel,\n SelectScrollDownButton,\n SelectScrollUpButton,\n SelectSeparator,\n SelectTrigger,\n SelectValue,\n};\n"],"mappings":";;;;;AAOA,SAAS,OAAO,EAAE,GAAG,KAA4D;AAC/E,QAAO,oBAAC,gBAAgB,MAAA;EAAK,aAAU;EAAS,GAAI;GAAS;;AAG/D,SAAS,YAAY,EAAE,GAAG,KAA6D;AACrF,QAAO,oBAAC,gBAAgB,OAAA;EAAM,aAAU;EAAe,GAAI;GAAS;;AAGtE,SAAS,YAAY,EAAE,GAAG,KAA6D;AACrF,QAAO,oBAAC,gBAAgB,OAAA;EAAM,aAAU;EAAe,GAAI;GAAS;;AAGtE,SAAS,cAAc,EACrB,cACA,UAAO,WACP,aACA,aAAU,IACV,GAAG,KAGF;AASD,QARI,IAEA,oBAAC,gBAAgB,SAAA;EAAQ,GAAI;EAAO,SAAA;EACjC;GACuB,GAK5B,qBAAC,gBAAgB,SAAA;EACf,aAAU;EACV,aAAW;EACX,WAAW,GACT,gzBACA,EACD;EACD,GAAI;aAEH,GACD,oBAAC,gBAAgB,MAAA;GAAK,SAAA;aACpB,oBAAC,iBAAA,EAAgB,WAAU,qBAAA,CAAsB;IAC5B,CAAA;GACC;;AAI9B,SAAS,qBAAqB,EAAE,cAAW,GAAG,KAAsE;AAClH,QACE,oBAAC,gBAAgB,gBAAA;EACf,aAAU;EACV,WAAW,GAAG,wDAAwD,EAAU;EAChF,GAAI;YAEJ,oBAAC,eAAA,EAAc,WAAU,UAAA,CAAW;GACL;;AAIrC,SAAS,uBAAuB,EAC9B,cACA,GAAG,KAC6D;AAChE,QACE,oBAAC,gBAAgB,kBAAA;EACf,aAAU;EACV,WAAW,GAAG,wDAAwD,EAAU;EAChF,GAAI;YAEJ,oBAAC,iBAAA,EAAgB,WAAU,UAAA,CAAW;GACL;;AAIvC,SAAS,cAAc,EACrB,cACA,aACA,cAAW,UACX,GAAG,KACoD;AACvD,QACE,oBAAC,gBAAgB,QAAA,EAAA,UACf,qBAAC,gBAAgB,SAAA;EACf,aAAU;EACV,WAAW,GACT,ijBACA,MAAa,YACX,mIACF,EACD;EACS;EACV,GAAI;;GAEJ,oBAAC,sBAAA,EAAA,CAAuB;GACxB,oBAAC,gBAAgB,UAAA;IACf,WAAW,GACT,OACA,MAAa,YACX,sGACH;IAEA;KACwB;GAC3B,oBAAC,wBAAA,EAAA,CAAyB;;GACF,EAAA,CACH;;AAI7B,SAAS,YAAY,EAAE,cAAW,GAAG,KAA6D;AAChG,QACE,oBAAC,gBAAgB,OAAA;EACf,aAAU;EACV,WAAW,GAAG,6CAA6C,EAAU;EACrE,GAAI;GACJ;;AAIN,SAAS,WAAW,EAAE,cAAW,aAAU,GAAG,KAA4D;AACxG,QACE,qBAAC,gBAAgB,MAAA;EACf,aAAU;EACV,WAAW,GACT,6aACA,EACD;EACD,GAAI;aAEJ,oBAAC,QAAA;GAAK,WAAU;aACd,oBAAC,gBAAgB,eAAA,EAAA,UACf,oBAAC,WAAA,EAAU,WAAU,UAAA,CAAW,EAAA,CACF;IAC3B,EACP,oBAAC,gBAAgB,UAAA,EAAU,aAAA,CAAoC,CAAA;GAC1C;;AAI3B,SAAS,gBAAgB,EAAE,cAAW,GAAG,KAAiE;AACxG,QACE,oBAAC,gBAAgB,WAAA;EACf,aAAU;EACV,WAAW,GAAG,iDAAiD,EAAU;EACzE,GAAI;GACJ"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),n=require("@radix-ui/react-separator"),i=require("../lib/utils.cjs");function l(t){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const a=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(r,e,a.get?a:{enumerable:!0,get:()=>t[e]})}}return r.default=t,Object.freeze(r)}const c=l(n);function u({className:t,orientation:r="horizontal",decorative:e=!0,...a}){return o.jsx(c.Root,{"data-slot":"separator",decorative:e,orientation:r,className:i.cn("bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",t),...a})}exports.Separator=u;
2
- //# sourceMappingURL=separator.cjs.map
1
+ "use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`../_virtual/rolldown:runtime.cjs`),t=require(`../lib/utils.cjs`);let n=require(`react/jsx-runtime`),r=require(`@radix-ui/react-separator`);r=e.__toESM(r);function i({className:e,orientation:i=`horizontal`,decorative:a=!0,...o}){return(0,n.jsx)(r.Root,{"data-slot":`separator`,decorative:a,orientation:i,className:t.cn(`bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px`,e),...o})}exports.Separator=i;
2
+ //# sourceMappingURL=separator.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"separator.cjs","sources":["../../src/elements/separator.tsx"],"sourcesContent":["'use client';\n\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/lib/utils';\n\nfunction Separator({\n className,\n orientation = 'horizontal',\n decorative = true,\n ...props\n}: React.ComponentProps<typeof SeparatorPrimitive.Root>) {\n return (\n <SeparatorPrimitive.Root\n data-slot=\"separator\"\n decorative={decorative}\n orientation={orientation}\n className={cn(\n 'bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px',\n className,\n )}\n {...props}\n />\n );\n}\n\nexport { Separator };\n"],"names":["Separator","className","orientation","decorative","props","jsx","SeparatorPrimitive","cn"],"mappings":"odAMA,SAASA,EAAU,CACjB,UAAAC,EACA,YAAAC,EAAc,aACd,WAAAC,EAAa,GACb,GAAGC,CACL,EAAyD,CACvD,OACEC,EAAAA,IAACC,EAAmB,KAAnB,CACC,YAAU,YACV,WAAAH,EACA,YAAAD,EACA,UAAWK,EAAAA,GACT,iKACAN,CAAA,EAED,GAAGG,CAAA,CAAA,CAGV"}
1
+ {"version":3,"file":"separator.cjs","names":[],"sources":["../../src/elements/separator.tsx"],"sourcesContent":["'use client';\n\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/lib/utils';\n\nfunction Separator({\n className,\n orientation = 'horizontal',\n decorative = true,\n ...props\n}: React.ComponentProps<typeof SeparatorPrimitive.Root>) {\n return (\n <SeparatorPrimitive.Root\n data-slot=\"separator\"\n decorative={decorative}\n orientation={orientation}\n className={cn(\n 'bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px',\n className,\n )}\n {...props}\n />\n );\n}\n\nexport { Separator };\n"],"mappings":"2PAMA,SAAS,EAAU,CACjB,YACA,cAAc,aACd,aAAa,GACb,GAAG,GACoD,CACvD,OACE,EAAA,EAAA,KAAC,EAAmB,KAAA,CAClB,YAAU,YACE,aACC,cACb,UAAW,EAAA,GACT,iKACA,EACD,CACD,GAAI,GACJ"}
@@ -1,27 +1,16 @@
1
- import { jsx as i } from "react/jsx-runtime";
2
- import * as n from "@radix-ui/react-separator";
3
- import { cn as e } from "../lib/utils.js";
4
- function m({
5
- className: t,
6
- orientation: o = "horizontal",
7
- decorative: r = !0,
8
- ...a
9
- }) {
10
- return /* @__PURE__ */ i(
11
- n.Root,
12
- {
13
- "data-slot": "separator",
14
- decorative: r,
15
- orientation: o,
16
- className: e(
17
- "bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",
18
- t
19
- ),
20
- ...a
21
- }
22
- );
1
+ "use client";
2
+ import { cn } from "../lib/utils.js";
3
+ import { jsx } from "react/jsx-runtime";
4
+ import * as SeparatorPrimitive from "@radix-ui/react-separator";
5
+ function Separator({ className: r, orientation: i = "horizontal", decorative: a = !0, ...o }) {
6
+ return /* @__PURE__ */ jsx(SeparatorPrimitive.Root, {
7
+ "data-slot": "separator",
8
+ decorative: a,
9
+ orientation: i,
10
+ className: cn("bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px", r),
11
+ ...o
12
+ });
23
13
  }
24
- export {
25
- m as Separator
26
- };
27
- //# sourceMappingURL=separator.js.map
14
+ export { Separator };
15
+
16
+ //# sourceMappingURL=separator.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"separator.js","sources":["../../src/elements/separator.tsx"],"sourcesContent":["'use client';\n\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/lib/utils';\n\nfunction Separator({\n className,\n orientation = 'horizontal',\n decorative = true,\n ...props\n}: React.ComponentProps<typeof SeparatorPrimitive.Root>) {\n return (\n <SeparatorPrimitive.Root\n data-slot=\"separator\"\n decorative={decorative}\n orientation={orientation}\n className={cn(\n 'bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px',\n className,\n )}\n {...props}\n />\n );\n}\n\nexport { Separator };\n"],"names":["Separator","className","orientation","decorative","props","jsx","SeparatorPrimitive","cn"],"mappings":";;;AAMA,SAASA,EAAU;AAAA,EACjB,WAAAC;AAAA,EACA,aAAAC,IAAc;AAAA,EACd,YAAAC,IAAa;AAAA,EACb,GAAGC;AACL,GAAyD;AACvD,SACE,gBAAAC;AAAA,IAACC,EAAmB;AAAA,IAAnB;AAAA,MACC,aAAU;AAAA,MACV,YAAAH;AAAA,MACA,aAAAD;AAAA,MACA,WAAWK;AAAA,QACT;AAAA,QACAN;AAAA,MAAA;AAAA,MAED,GAAGG;AAAA,IAAA;AAAA,EAAA;AAGV;"}
1
+ {"version":3,"file":"separator.js","names":[],"sources":["../../src/elements/separator.tsx"],"sourcesContent":["'use client';\n\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/lib/utils';\n\nfunction Separator({\n className,\n orientation = 'horizontal',\n decorative = true,\n ...props\n}: React.ComponentProps<typeof SeparatorPrimitive.Root>) {\n return (\n <SeparatorPrimitive.Root\n data-slot=\"separator\"\n decorative={decorative}\n orientation={orientation}\n className={cn(\n 'bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px',\n className,\n )}\n {...props}\n />\n );\n}\n\nexport { Separator };\n"],"mappings":";;;;AAMA,SAAS,UAAU,EACjB,cACA,iBAAc,cACd,gBAAa,IACb,GAAG,KACoD;AACvD,QACE,oBAAC,mBAAmB,MAAA;EAClB,aAAU;EACE;EACC;EACb,WAAW,GACT,kKACA,EACD;EACD,GAAI;GACJ"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),i=require("@radix-ui/react-dialog"),l=require("lucide-react"),n=require("../lib/utils.cjs");function d(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const a in t)if(a!=="default"){const r=Object.getOwnPropertyDescriptor(t,a);Object.defineProperty(e,a,r.get?r:{enumerable:!0,get:()=>t[a]})}}return e.default=t,Object.freeze(e)}const s=d(i);function c({...t}){return o.jsx(s.Root,{"data-slot":"sheet",...t})}function u({...t}){return o.jsx(s.Trigger,{"data-slot":"sheet-trigger",...t})}function f({...t}){return o.jsx(s.Close,{"data-slot":"sheet-close",...t})}function h({...t}){return o.jsx(s.Portal,{"data-slot":"sheet-portal",...t})}function m({className:t,...e}){return o.jsx(s.Overlay,{"data-slot":"sheet-overlay",className:n.cn("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",t),...e})}function g({className:t,children:e,side:a="right",...r}){return o.jsxs(h,{children:[o.jsx(m,{}),o.jsxs(s.Content,{"data-slot":"sheet-content",className:n.cn("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out fixed z-50 flex flex-col gap-4 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500",a==="right"&&"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm",a==="left"&&"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",a==="top"&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",a==="bottom"&&"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",t),...r,children:[e,o.jsxs(s.Close,{className:"ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none",children:[o.jsx(l.XIcon,{className:"size-4"}),o.jsx("span",{className:"sr-only",children:"Close"})]})]})]})}function p({className:t,...e}){return o.jsx("div",{"data-slot":"sheet-header",className:n.cn("flex flex-col gap-1.5 p-4",t),...e})}function x({className:t,...e}){return o.jsx("div",{"data-slot":"sheet-footer",className:n.cn("mt-auto flex flex-col gap-2 p-4",t),...e})}function b({className:t,...e}){return o.jsx(s.Title,{"data-slot":"sheet-title",className:n.cn("text-foreground font-semibold",t),...e})}function S({className:t,...e}){return o.jsx(s.Description,{"data-slot":"sheet-description",className:n.cn("text-muted-foreground text-sm",t),...e})}exports.Sheet=c;exports.SheetClose=f;exports.SheetContent=g;exports.SheetDescription=S;exports.SheetFooter=x;exports.SheetHeader=p;exports.SheetTitle=b;exports.SheetTrigger=u;
2
- //# sourceMappingURL=sheet.cjs.map
1
+ "use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`../_virtual/rolldown:runtime.cjs`),t=require(`../lib/utils.cjs`);let n=require(`react/jsx-runtime`),r=require(`lucide-react`),i=require(`@radix-ui/react-dialog`);i=e.__toESM(i);function a({...e}){return(0,n.jsx)(i.Root,{"data-slot":`sheet`,...e})}function o({...e}){return(0,n.jsx)(i.Trigger,{"data-slot":`sheet-trigger`,...e})}function s({...e}){return(0,n.jsx)(i.Close,{"data-slot":`sheet-close`,...e})}function c({...e}){return(0,n.jsx)(i.Portal,{"data-slot":`sheet-portal`,...e})}function l({className:e,...r}){return(0,n.jsx)(i.Overlay,{"data-slot":`sheet-overlay`,className:t.cn(`data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50`,e),...r})}function u({className:e,children:a,side:o=`right`,...s}){return(0,n.jsxs)(c,{children:[(0,n.jsx)(l,{}),(0,n.jsxs)(i.Content,{"data-slot":`sheet-content`,className:t.cn(`bg-background data-[state=open]:animate-in data-[state=closed]:animate-out fixed z-50 flex flex-col gap-4 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500`,o===`right`&&`data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm`,o===`left`&&`data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm`,o===`top`&&`data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b`,o===`bottom`&&`data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t`,e),...s,children:[a,(0,n.jsxs)(i.Close,{className:`ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none`,children:[(0,n.jsx)(r.XIcon,{className:`size-4`}),(0,n.jsx)(`span`,{className:`sr-only`,children:`Close`})]})]})]})}function d({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`sheet-header`,className:t.cn(`flex flex-col gap-1.5 p-4`,e),...r})}function f({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`sheet-footer`,className:t.cn(`mt-auto flex flex-col gap-2 p-4`,e),...r})}function p({className:e,...r}){return(0,n.jsx)(i.Title,{"data-slot":`sheet-title`,className:t.cn(`text-foreground font-semibold`,e),...r})}function m({className:e,...r}){return(0,n.jsx)(i.Description,{"data-slot":`sheet-description`,className:t.cn(`text-muted-foreground text-sm`,e),...r})}exports.Sheet=a,exports.SheetClose=s,exports.SheetContent=u,exports.SheetDescription=m,exports.SheetFooter=f,exports.SheetHeader=d,exports.SheetTitle=p,exports.SheetTrigger=o;
2
+ //# sourceMappingURL=sheet.cjs.map