@incognia/cosmik 0.35.7 → 0.36.0-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (193) hide show
  1. package/dist/Sonner/index.d.ts +6 -0
  2. package/dist/Sonner/index.d.ts.map +1 -0
  3. package/dist/cosmik.css +1 -1
  4. package/dist/index.cjs.js +1 -1
  5. package/dist/index.cjs10.js +1 -1
  6. package/dist/index.cjs11.js +1 -1
  7. package/dist/index.cjs12.js +1 -1
  8. package/dist/index.cjs12.js.map +1 -1
  9. package/dist/index.cjs13.js +1 -1
  10. package/dist/index.cjs14.js +1 -1
  11. package/dist/index.cjs15.js +1 -1
  12. package/dist/index.cjs16.js +1 -1
  13. package/dist/index.cjs17.js +1 -1
  14. package/dist/index.cjs18.js +1 -1
  15. package/dist/index.cjs19.js +1 -1
  16. package/dist/index.cjs20.js +1 -1
  17. package/dist/index.cjs21.js +1 -1
  18. package/dist/index.cjs22.js +1 -1
  19. package/dist/index.cjs23.js +1 -1
  20. package/dist/index.cjs24.js +1 -1
  21. package/dist/index.cjs25.js +1 -1
  22. package/dist/index.cjs26.js +1 -1
  23. package/dist/index.cjs27.js +1 -1
  24. package/dist/index.cjs28.js +1 -1
  25. package/dist/index.cjs29.js +1 -1
  26. package/dist/index.cjs29.js.map +1 -1
  27. package/dist/index.cjs30.js +1 -1
  28. package/dist/index.cjs30.js.map +1 -1
  29. package/dist/index.cjs31.js +1 -1
  30. package/dist/index.cjs31.js.map +1 -1
  31. package/dist/index.cjs32.js +1 -1
  32. package/dist/index.cjs32.js.map +1 -1
  33. package/dist/index.cjs33.js +1 -1
  34. package/dist/index.cjs33.js.map +1 -1
  35. package/dist/index.cjs34.js +1 -1
  36. package/dist/index.cjs34.js.map +1 -1
  37. package/dist/index.cjs35.js +1 -1
  38. package/dist/index.cjs35.js.map +1 -1
  39. package/dist/index.cjs36.js +1 -1
  40. package/dist/index.cjs36.js.map +1 -1
  41. package/dist/index.cjs37.js +1 -1
  42. package/dist/index.cjs37.js.map +1 -1
  43. package/dist/index.cjs38.js +1 -1
  44. package/dist/index.cjs38.js.map +1 -1
  45. package/dist/index.cjs39.js +1 -1
  46. package/dist/index.cjs39.js.map +1 -1
  47. package/dist/index.cjs4.js +1 -1
  48. package/dist/index.cjs40.js +1 -1
  49. package/dist/index.cjs40.js.map +1 -1
  50. package/dist/index.cjs41.js +1 -1
  51. package/dist/index.cjs41.js.map +1 -1
  52. package/dist/index.cjs42.js +1 -1
  53. package/dist/index.cjs42.js.map +1 -1
  54. package/dist/index.cjs43.js +1 -1
  55. package/dist/index.cjs43.js.map +1 -1
  56. package/dist/index.cjs44.js +1 -1
  57. package/dist/index.cjs44.js.map +1 -1
  58. package/dist/index.cjs45.js +1 -1
  59. package/dist/index.cjs45.js.map +1 -1
  60. package/dist/index.cjs46.js +1 -1
  61. package/dist/index.cjs46.js.map +1 -1
  62. package/dist/index.cjs47.js +1 -1
  63. package/dist/index.cjs47.js.map +1 -1
  64. package/dist/index.cjs48.js +9 -1
  65. package/dist/index.cjs48.js.map +1 -1
  66. package/dist/index.cjs49.js +19 -1
  67. package/dist/index.cjs49.js.map +1 -1
  68. package/dist/index.cjs5.js +1 -1
  69. package/dist/index.cjs50.js +1 -9
  70. package/dist/index.cjs50.js.map +1 -1
  71. package/dist/index.cjs51.js +1 -19
  72. package/dist/index.cjs51.js.map +1 -1
  73. package/dist/index.cjs52.js +1 -1
  74. package/dist/index.cjs52.js.map +1 -1
  75. package/dist/index.cjs53.js +1 -1
  76. package/dist/index.cjs53.js.map +1 -1
  77. package/dist/index.cjs54.js +1 -1
  78. package/dist/index.cjs54.js.map +1 -1
  79. package/dist/index.cjs55.js +1 -1
  80. package/dist/index.cjs55.js.map +1 -1
  81. package/dist/index.cjs56.js +1 -1
  82. package/dist/index.cjs56.js.map +1 -1
  83. package/dist/index.cjs57.js +1 -1
  84. package/dist/index.cjs57.js.map +1 -1
  85. package/dist/index.cjs58.js +1 -1
  86. package/dist/index.cjs58.js.map +1 -1
  87. package/dist/index.cjs59.js +1 -1
  88. package/dist/index.cjs59.js.map +1 -1
  89. package/dist/index.cjs6.js +1 -1
  90. package/dist/index.cjs60.js +1 -1
  91. package/dist/index.cjs60.js.map +1 -1
  92. package/dist/index.cjs61.js +2 -0
  93. package/dist/index.cjs61.js.map +1 -0
  94. package/dist/index.cjs7.js +1 -1
  95. package/dist/index.cjs8.js +1 -1
  96. package/dist/index.cjs9.js +1 -1
  97. package/dist/index.d.ts +1 -0
  98. package/dist/index.d.ts.map +1 -1
  99. package/dist/index.es.js +70 -68
  100. package/dist/index.es.js.map +1 -1
  101. package/dist/index.es10.js +2 -2
  102. package/dist/index.es11.js +2 -2
  103. package/dist/index.es12.js +8 -7
  104. package/dist/index.es12.js.map +1 -1
  105. package/dist/index.es13.js +2 -2
  106. package/dist/index.es14.js +2 -2
  107. package/dist/index.es15.js +2 -2
  108. package/dist/index.es16.js +3 -3
  109. package/dist/index.es17.js +2 -2
  110. package/dist/index.es18.js +2 -2
  111. package/dist/index.es19.js +2 -2
  112. package/dist/index.es20.js +3 -3
  113. package/dist/index.es21.js +2 -2
  114. package/dist/index.es22.js +2 -2
  115. package/dist/index.es23.js +2 -2
  116. package/dist/index.es24.js +2 -2
  117. package/dist/index.es25.js +2 -2
  118. package/dist/index.es26.js +2 -2
  119. package/dist/index.es27.js +2 -2
  120. package/dist/index.es28.js +2 -2
  121. package/dist/index.es29.js +31 -24
  122. package/dist/index.es29.js.map +1 -1
  123. package/dist/index.es30.js +21 -106
  124. package/dist/index.es30.js.map +1 -1
  125. package/dist/index.es31.js +101 -31
  126. package/dist/index.es31.js.map +1 -1
  127. package/dist/index.es32.js +40 -81
  128. package/dist/index.es32.js.map +1 -1
  129. package/dist/index.es33.js +81 -21
  130. package/dist/index.es33.js.map +1 -1
  131. package/dist/index.es34.js +22 -108
  132. package/dist/index.es34.js.map +1 -1
  133. package/dist/index.es35.js +109 -41
  134. package/dist/index.es35.js.map +1 -1
  135. package/dist/index.es36.js +40 -94
  136. package/dist/index.es36.js.map +1 -1
  137. package/dist/index.es37.js +93 -38
  138. package/dist/index.es37.js.map +1 -1
  139. package/dist/index.es38.js +36 -35
  140. package/dist/index.es38.js.map +1 -1
  141. package/dist/index.es39.js +36 -30
  142. package/dist/index.es39.js.map +1 -1
  143. package/dist/index.es4.js +1 -1
  144. package/dist/index.es40.js +26 -58
  145. package/dist/index.es40.js.map +1 -1
  146. package/dist/index.es41.js +61 -259
  147. package/dist/index.es41.js.map +1 -1
  148. package/dist/index.es42.js +263 -6
  149. package/dist/index.es42.js.map +1 -1
  150. package/dist/index.es43.js +6 -13
  151. package/dist/index.es43.js.map +1 -1
  152. package/dist/index.es44.js +12 -118
  153. package/dist/index.es44.js.map +1 -1
  154. package/dist/index.es45.js +117 -12
  155. package/dist/index.es45.js.map +1 -1
  156. package/dist/index.es46.js +13 -3
  157. package/dist/index.es46.js.map +1 -1
  158. package/dist/index.es47.js +2 -105
  159. package/dist/index.es47.js.map +1 -1
  160. package/dist/index.es48.js +29 -33
  161. package/dist/index.es48.js.map +1 -1
  162. package/dist/index.es49.js +599 -2
  163. package/dist/index.es49.js.map +1 -1
  164. package/dist/index.es5.js +2 -2
  165. package/dist/index.es50.js +3 -29
  166. package/dist/index.es50.js.map +1 -1
  167. package/dist/index.es51.js +104 -598
  168. package/dist/index.es51.js.map +1 -1
  169. package/dist/index.es52.js +34 -2
  170. package/dist/index.es52.js.map +1 -1
  171. package/dist/index.es53.js +2 -151
  172. package/dist/index.es53.js.map +1 -1
  173. package/dist/index.es54.js +2 -16
  174. package/dist/index.es54.js.map +1 -1
  175. package/dist/index.es55.js +2 -342
  176. package/dist/index.es55.js.map +1 -1
  177. package/dist/index.es56.js +150 -44
  178. package/dist/index.es56.js.map +1 -1
  179. package/dist/index.es57.js +16 -2
  180. package/dist/index.es57.js.map +1 -1
  181. package/dist/index.es58.js +342 -2
  182. package/dist/index.es58.js.map +1 -1
  183. package/dist/index.es59.js +45 -2
  184. package/dist/index.es59.js.map +1 -1
  185. package/dist/index.es6.js +2 -2
  186. package/dist/index.es60.js +2 -4
  187. package/dist/index.es60.js.map +1 -1
  188. package/dist/index.es61.js +7 -0
  189. package/dist/index.es61.js.map +1 -0
  190. package/dist/index.es7.js +2 -2
  191. package/dist/index.es8.js +2 -2
  192. package/dist/index.es9.js +2 -2
  193. package/package.json +2 -1
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./index.cjs42.js"),S=require("@radix-ui/react-select"),i=require("lucide-react"),w=require("react"),l=require("./index.cjs43.js");function p(a){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(a){for(const t in a)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(a,t);Object.defineProperty(o,t,r.get?r:{enumerable:!0,get:()=>a[t]})}}return o.default=a,Object.freeze(o)}const e=p(S),n=p(w),y=e.Root,b=e.Group,g=e.Value,m=n.forwardRef(({className:a,children:o,...t},r)=>s.jsxRuntimeExports.jsxs(e.Trigger,{ref:r,className:l.cn("flex h-[36px] w-full items-center justify-between rounded bg-white border border-gray-900-24 pl-16 pr-12 text-left","disabled:cursor-not-allowed disabled:opacity-64 disabled:shadow-none","[&>span]:line-clamp-1","hover:shadow-field-hover","focus-visible:outline-none focus:shadow-field-active","active:shadow-field-active","data-[state=open]:shadow-field-active","data-[placeholder]:text-gray-700",a),...t,children:[o,s.jsxRuntimeExports.jsx(e.Icon,{asChild:!0,children:s.jsxRuntimeExports.jsx(i.ChevronDown,{className:"h-16 w-16 opacity-64 ml-8"})})]}));m.displayName=e.Trigger.displayName;const c=n.forwardRef(({className:a,...o},t)=>s.jsxRuntimeExports.jsx(e.ScrollUpButton,{ref:t,className:l.cn("flex cursor-default items-center justify-center py-4",a),...o,children:s.jsxRuntimeExports.jsx(i.ChevronUp,{className:"h-16 w-16"})}));c.displayName=e.ScrollUpButton.displayName;const d=n.forwardRef(({className:a,...o},t)=>s.jsxRuntimeExports.jsx(e.ScrollDownButton,{ref:t,className:l.cn("flex cursor-default items-center justify-center py-4",a),...o,children:s.jsxRuntimeExports.jsx(i.ChevronDown,{className:"h-16 w-16"})}));d.displayName=e.ScrollDownButton.displayName;const u=n.forwardRef(({className:a,children:o,position:t="popper",...r},h)=>s.jsxRuntimeExports.jsx(e.Portal,{children:s.jsxRuntimeExports.jsxs(e.Content,{ref:h,className:l.cn("relative z-50 max-h-[300px] min-w-[8rem] overflow-hidden bg-white rounded border shadow-200","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0","data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[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",t==="popper"&&"data-[side=bottom]:translate-y-4 data-[side=left]:-translate-x-4 data-[side=right]:translate-x-4 data-[side=top]:-translate-y-4",a),position:t,...r,children:[s.jsxRuntimeExports.jsx(c,{}),s.jsxRuntimeExports.jsx(e.Viewport,{className:l.cn(t==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:o}),s.jsxRuntimeExports.jsx(d,{})]})}));u.displayName=e.Content.displayName;const x=n.forwardRef(({className:a,...o},t)=>s.jsxRuntimeExports.jsx(e.Label,{ref:t,className:l.cn("py-8 px-16 pr-8 font-medium",a),...o}));x.displayName=e.Label.displayName;const f=n.forwardRef(({className:a,children:o,...t},r)=>s.jsxRuntimeExports.jsxs(e.Item,{ref:r,className:l.cn("relative flex w-full cursor-default select-none items-center justify-between py-8 px-16 outline-none","hover:bg-purple-100","data-[state=checked]:bg-purple-100 data-[state=checked]:font-medium","data-[disabled]:pointer-events-none data-[disabled]:opacity-64",a),...t,children:[s.jsxRuntimeExports.jsx(e.ItemText,{children:o}),s.jsxRuntimeExports.jsx(e.ItemIndicator,{children:s.jsxRuntimeExports.jsx(i.CheckIcon,{className:"h-16 w-16 ml-8"})})]}));f.displayName=e.Item.displayName;const j=n.forwardRef(({className:a,...o},t)=>s.jsxRuntimeExports.jsx(e.Separator,{ref:t,className:l.cn("-mx-4 my-4 h-[1px] bg-gray-900-24",a),...o}));j.displayName=e.Separator.displayName;exports.Select=y;exports.SelectContent=u;exports.SelectGroup=b;exports.SelectItem=f;exports.SelectLabel=x;exports.SelectScrollDownButton=d;exports.SelectScrollUpButton=c;exports.SelectSeparator=j;exports.SelectTrigger=m;exports.SelectValue=g;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./index.cjs43.js"),S=require("@radix-ui/react-select"),i=require("lucide-react"),w=require("react"),l=require("./index.cjs44.js");function p(a){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(a){for(const t in a)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(a,t);Object.defineProperty(o,t,r.get?r:{enumerable:!0,get:()=>a[t]})}}return o.default=a,Object.freeze(o)}const e=p(S),n=p(w),y=e.Root,b=e.Group,g=e.Value,m=n.forwardRef(({className:a,children:o,...t},r)=>s.jsxRuntimeExports.jsxs(e.Trigger,{ref:r,className:l.cn("flex h-[36px] w-full items-center justify-between rounded bg-white border border-gray-900-24 pl-16 pr-12 text-left","disabled:cursor-not-allowed disabled:opacity-64 disabled:shadow-none","[&>span]:line-clamp-1","hover:shadow-field-hover","focus-visible:outline-none focus:shadow-field-active","active:shadow-field-active","data-[state=open]:shadow-field-active","data-[placeholder]:text-gray-700",a),...t,children:[o,s.jsxRuntimeExports.jsx(e.Icon,{asChild:!0,children:s.jsxRuntimeExports.jsx(i.ChevronDown,{className:"h-16 w-16 opacity-64 ml-8"})})]}));m.displayName=e.Trigger.displayName;const c=n.forwardRef(({className:a,...o},t)=>s.jsxRuntimeExports.jsx(e.ScrollUpButton,{ref:t,className:l.cn("flex cursor-default items-center justify-center py-4",a),...o,children:s.jsxRuntimeExports.jsx(i.ChevronUp,{className:"h-16 w-16"})}));c.displayName=e.ScrollUpButton.displayName;const d=n.forwardRef(({className:a,...o},t)=>s.jsxRuntimeExports.jsx(e.ScrollDownButton,{ref:t,className:l.cn("flex cursor-default items-center justify-center py-4",a),...o,children:s.jsxRuntimeExports.jsx(i.ChevronDown,{className:"h-16 w-16"})}));d.displayName=e.ScrollDownButton.displayName;const u=n.forwardRef(({className:a,children:o,position:t="popper",...r},h)=>s.jsxRuntimeExports.jsx(e.Portal,{children:s.jsxRuntimeExports.jsxs(e.Content,{ref:h,className:l.cn("relative z-50 max-h-[300px] min-w-[8rem] overflow-hidden bg-white rounded border shadow-200","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0","data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[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",t==="popper"&&"data-[side=bottom]:translate-y-4 data-[side=left]:-translate-x-4 data-[side=right]:translate-x-4 data-[side=top]:-translate-y-4",a),position:t,...r,children:[s.jsxRuntimeExports.jsx(c,{}),s.jsxRuntimeExports.jsx(e.Viewport,{className:l.cn(t==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:o}),s.jsxRuntimeExports.jsx(d,{})]})}));u.displayName=e.Content.displayName;const x=n.forwardRef(({className:a,...o},t)=>s.jsxRuntimeExports.jsx(e.Label,{ref:t,className:l.cn("py-8 px-16 pr-8 font-medium",a),...o}));x.displayName=e.Label.displayName;const f=n.forwardRef(({className:a,children:o,...t},r)=>s.jsxRuntimeExports.jsxs(e.Item,{ref:r,className:l.cn("relative flex w-full cursor-default select-none items-center justify-between py-8 px-16 outline-none","hover:bg-purple-100","data-[state=checked]:bg-purple-100 data-[state=checked]:font-medium","data-[disabled]:pointer-events-none data-[disabled]:opacity-64",a),...t,children:[s.jsxRuntimeExports.jsx(e.ItemText,{children:o}),s.jsxRuntimeExports.jsx(e.ItemIndicator,{children:s.jsxRuntimeExports.jsx(i.CheckIcon,{className:"h-16 w-16 ml-8"})})]}));f.displayName=e.Item.displayName;const j=n.forwardRef(({className:a,...o},t)=>s.jsxRuntimeExports.jsx(e.Separator,{ref:t,className:l.cn("-mx-4 my-4 h-[1px] bg-gray-900-24",a),...o}));j.displayName=e.Separator.displayName;exports.Select=y;exports.SelectContent=u;exports.SelectGroup=b;exports.SelectItem=f;exports.SelectLabel=x;exports.SelectScrollDownButton=d;exports.SelectScrollUpButton=c;exports.SelectSeparator=j;exports.SelectTrigger=m;exports.SelectValue=g;
2
2
  //# sourceMappingURL=index.cjs25.js.map
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.cjs42.js"),u=require("@radix-ui/react-separator"),l=require("react"),p=require("./index.cjs43.js");function a(e){const t=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(t,r,o.get?o:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const n=a(u),f=a(l),i=f.forwardRef(({className:e,orientation:t="horizontal",decorative:r=!0,...o},s)=>c.jsxRuntimeExports.jsx(n.Root,{ref:s,decorative:r,orientation:t,className:p.cn("shrink-0 bg-gray-900-8",t==="horizontal"?"h-[1px] w-full":"w-[1px]",e),role:"separator",...o}));i.displayName=n.Root.displayName;exports.Separator=i;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.cjs43.js"),u=require("@radix-ui/react-separator"),l=require("react"),p=require("./index.cjs44.js");function a(e){const t=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(t,r,o.get?o:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const n=a(u),f=a(l),i=f.forwardRef(({className:e,orientation:t="horizontal",decorative:r=!0,...o},s)=>c.jsxRuntimeExports.jsx(n.Root,{ref:s,decorative:r,orientation:t,className:p.cn("shrink-0 bg-gray-900-8",t==="horizontal"?"h-[1px] w-full":"w-[1px]",e),role:"separator",...o}));i.displayName=n.Root.displayName;exports.Separator=i;
2
2
  //# sourceMappingURL=index.cjs26.js.map
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index.cjs42.js"),y=require("@radix-ui/react-dialog"),j=require("class-variance-authority"),g=require("lucide-react"),S=require("react"),i=require("./index.cjs43.js");function d(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const a in e)if(a!=="default"){const r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:!0,get:()=>e[a]})}}return t.default=e,Object.freeze(t)}const s=d(y),n=d(S),b=s.Root,N=s.Trigger,R=s.Close,c=s.Portal,l=n.forwardRef(({className:e,...t},a)=>o.jsxRuntimeExports.jsx(s.Overlay,{className:i.cn("fixed inset-0 z-50 bg-gray-900-24 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:a}));l.displayName=s.Overlay.displayName;const v=j.cva("fixed z-50 gap-16 bg-white border-gray-900-16 transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),m=n.forwardRef(({side:e="right",className:t,children:a,...r},h)=>o.jsxRuntimeExports.jsxs(c,{children:[o.jsxRuntimeExports.jsx(l,{}),o.jsxRuntimeExports.jsxs(s.Content,{ref:h,className:i.cn(v({side:e}),t),...r,children:[a,o.jsxRuntimeExports.jsxs(s.Close,{className:"absolute right-16 top-16 rounded-small opacity-64 transition-opacity hover:opacity-100 focus:outline-none disabled:pointer-events-none",children:[o.jsxRuntimeExports.jsx(g.X,{className:"h-16 w-16"}),o.jsxRuntimeExports.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));m.displayName=s.Content.displayName;const p=({className:e,...t})=>o.jsxRuntimeExports.jsx("div",{className:i.cn("flex flex-col space-y-8 text-center sm:text-left",e),...t});p.displayName="SheetHeader";const u=({className:e,...t})=>o.jsxRuntimeExports.jsx("div",{className:i.cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-8",e),...t});u.displayName="SheetFooter";const x=n.forwardRef(({className:e,...t},a)=>o.jsxRuntimeExports.jsx(s.Title,{ref:a,className:i.cn("font-medium text-lg text-gray-800",e),...t}));x.displayName=s.Title.displayName;const f=n.forwardRef(({className:e,...t},a)=>o.jsxRuntimeExports.jsx(s.Description,{ref:a,className:i.cn("mt-8 text-base text-gray-900",e),...t}));f.displayName=s.Description.displayName;exports.Sheet=b;exports.SheetClose=R;exports.SheetContent=m;exports.SheetDescription=f;exports.SheetFooter=u;exports.SheetHeader=p;exports.SheetOverlay=l;exports.SheetPortal=c;exports.SheetTitle=x;exports.SheetTrigger=N;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index.cjs43.js"),y=require("@radix-ui/react-dialog"),j=require("class-variance-authority"),g=require("lucide-react"),S=require("react"),i=require("./index.cjs44.js");function d(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const a in e)if(a!=="default"){const r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:!0,get:()=>e[a]})}}return t.default=e,Object.freeze(t)}const s=d(y),n=d(S),b=s.Root,N=s.Trigger,R=s.Close,c=s.Portal,l=n.forwardRef(({className:e,...t},a)=>o.jsxRuntimeExports.jsx(s.Overlay,{className:i.cn("fixed inset-0 z-50 bg-gray-900-24 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:a}));l.displayName=s.Overlay.displayName;const v=j.cva("fixed z-50 gap-16 bg-white border-gray-900-16 transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),m=n.forwardRef(({side:e="right",className:t,children:a,...r},h)=>o.jsxRuntimeExports.jsxs(c,{children:[o.jsxRuntimeExports.jsx(l,{}),o.jsxRuntimeExports.jsxs(s.Content,{ref:h,className:i.cn(v({side:e}),t),...r,children:[a,o.jsxRuntimeExports.jsxs(s.Close,{className:"absolute right-16 top-16 rounded-small opacity-64 transition-opacity hover:opacity-100 focus:outline-none disabled:pointer-events-none",children:[o.jsxRuntimeExports.jsx(g.X,{className:"h-16 w-16"}),o.jsxRuntimeExports.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));m.displayName=s.Content.displayName;const p=({className:e,...t})=>o.jsxRuntimeExports.jsx("div",{className:i.cn("flex flex-col space-y-8 text-center sm:text-left",e),...t});p.displayName="SheetHeader";const u=({className:e,...t})=>o.jsxRuntimeExports.jsx("div",{className:i.cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-8",e),...t});u.displayName="SheetFooter";const x=n.forwardRef(({className:e,...t},a)=>o.jsxRuntimeExports.jsx(s.Title,{ref:a,className:i.cn("font-medium text-lg text-gray-800",e),...t}));x.displayName=s.Title.displayName;const f=n.forwardRef(({className:e,...t},a)=>o.jsxRuntimeExports.jsx(s.Description,{ref:a,className:i.cn("mt-8 text-base text-gray-900",e),...t}));f.displayName=s.Description.displayName;exports.Sheet=b;exports.SheetClose=R;exports.SheetContent=m;exports.SheetDescription=f;exports.SheetFooter=u;exports.SheetHeader=p;exports.SheetOverlay=l;exports.SheetPortal=c;exports.SheetTitle=x;exports.SheetTrigger=N;
2
2
  //# sourceMappingURL=index.cjs27.js.map
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index.cjs42.js"),r=require("./index.cjs43.js");function u({className:e,...t}){return n.jsxRuntimeExports.jsx("div",{className:r.cn("animate-pulse rounded-full bg-gray-900-16",e),...t})}exports.Skeleton=u;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index.cjs43.js"),r=require("./index.cjs44.js");function u({className:e,...t}){return n.jsxRuntimeExports.jsx("div",{className:r.cn("animate-pulse rounded-full bg-gray-900-16",e),...t})}exports.Skeleton=u;
2
2
  //# sourceMappingURL=index.cjs28.js.map
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.cjs42.js"),d=require("@radix-ui/react-switch"),l=require("react"),s=require("./index.cjs43.js");function o(e){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const n=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(a,t,n.get?n:{enumerable:!0,get:()=>e[t]})}}return a.default=e,Object.freeze(a)}const r=o(d),u=o(l),i=u.forwardRef(({className:e,...a},t)=>c.jsxRuntimeExports.jsx(r.Root,{className:s.cn("peer inline-flex h-[20px] w-[36px] shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors disabled:cursor-not-allowed disabled:opacity-64","data-[state=checked]:bg-robinblue-500 data-[state=checked]:hover:bg-robinblue-600 data-[state=checked]:active:bg-robinblue-700","data-[state=unchecked]:bg-gray-900-16 data-[state=unchecked]:hover:bg-gray-900-24 data-[state=unchecked]:active:bg-gray-900-32",e),...a,ref:t,children:c.jsxRuntimeExports.jsx(r.Thumb,{className:s.cn("pointer-events-none block h-16 w-16 rounded-full bg-white shadow-lg transition-transform data-[state=checked]:translate-x-16 data-[state=unchecked]:translate-x-0")})}));i.displayName=r.Root.displayName;exports.Switch=i;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index.cjs43.js"),t=require("lucide-react"),r=require("sonner"),o=({...s})=>e.jsxRuntimeExports.jsx(r.Toaster,{className:"![--width:486px]",position:"top-center",offset:16,gap:16,closeButton:!0,style:{},toastOptions:{unstyled:!0,classNames:{toast:"flex w-full gap-x-8 items-center overflow-hidden rounded border border-gray-900-8 p-16 pr-24 shadow-200 transition-all",success:"bg-green-50",warning:"bg-yellow-50",error:"bg-magenta-50",title:"text-sm text-gray-900 font-medium [&+div]:text-xs",description:"text-sm text-gray-800 opacity-100",closeButton:"absolute left-auto right-0 top-16 w-24 h-24 inline-flex items-center justify-center rounded-full bg-gray-900-8 hover:bg-gray-900-12 focus:bg-gray-900-12 active:bg-gray-900-16"}},icons:{success:e.jsxRuntimeExports.jsx(t.CheckIcon,{size:20,className:"text-green-800"}),warning:e.jsxRuntimeExports.jsx(t.AlertTriangleIcon,{size:20,className:"text-yellow-600"}),error:e.jsxRuntimeExports.jsx(t.AlertCircleIcon,{size:20,className:"text-magenta-600"}),close:e.jsxRuntimeExports.jsx(t.LucideX,{size:16})},...s});exports.Toaster=o;
2
2
  //# sourceMappingURL=index.cjs29.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs29.js","sources":["../src/Switch/index.tsx"],"sourcesContent":["'use client'\n\nimport * as SwitchPrimitives from '@radix-ui/react-switch'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst Switch = React.forwardRef<\n React.ElementRef<typeof SwitchPrimitives.Root>,\n React.ComponentPropsWithoutRef<typeof SwitchPrimitives.Root>\n>(({ className, ...props }, ref) => (\n <SwitchPrimitives.Root\n className={cn(\n 'peer inline-flex h-[20px] w-[36px] shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors disabled:cursor-not-allowed disabled:opacity-64',\n 'data-[state=checked]:bg-robinblue-500 data-[state=checked]:hover:bg-robinblue-600 data-[state=checked]:active:bg-robinblue-700',\n 'data-[state=unchecked]:bg-gray-900-16 data-[state=unchecked]:hover:bg-gray-900-24 data-[state=unchecked]:active:bg-gray-900-32',\n className\n )}\n {...props}\n ref={ref}\n >\n <SwitchPrimitives.Thumb\n className={cn(\n 'pointer-events-none block h-16 w-16 rounded-full bg-white shadow-lg transition-transform data-[state=checked]:translate-x-16 data-[state=unchecked]:translate-x-0'\n )}\n />\n </SwitchPrimitives.Root>\n))\nSwitch.displayName = SwitchPrimitives.Root.displayName\n\nexport { Switch }\n"],"names":["Switch","React","className","props","ref","jsx","SwitchPrimitives","cn"],"mappings":"0eAMMA,EAASC,EAAM,WAGnB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACC,EAAiB,KAAjB,CACC,UAAWC,EAAA,GACT,qLACA,iIACA,iIACAL,CACF,EACC,GAAGC,EACJ,IAAAC,EAEA,SAAAC,EAAA,kBAAA,IAACC,EAAiB,MAAjB,CACC,UAAWC,EAAA,GACT,mKACF,CAAA,CACF,CAAA,CACF,CACD,EACDP,EAAO,YAAcM,EAAiB,KAAK"}
1
+ {"version":3,"file":"index.cjs29.js","sources":["../src/Sonner/index.tsx"],"sourcesContent":["'use client'\n\nimport {\n AlertCircleIcon,\n AlertTriangleIcon,\n CheckIcon,\n LucideX\n} from 'lucide-react'\nimport { Toaster as Sonner } from 'sonner'\n\ntype ToasterProps = React.ComponentProps<typeof Sonner>\n\nconst Toaster = ({ ...props }: ToasterProps) => {\n return (\n <Sonner\n className=\"![--width:486px]\"\n position=\"top-center\"\n offset={16}\n gap={16}\n closeButton={true}\n style={{}}\n toastOptions={{\n unstyled: true,\n classNames: {\n toast:\n 'flex w-full gap-x-8 items-center overflow-hidden rounded border border-gray-900-8 p-16 pr-24 shadow-200 transition-all',\n success: 'bg-green-50',\n warning: 'bg-yellow-50',\n error: 'bg-magenta-50',\n title: 'text-sm text-gray-900 font-medium [&+div]:text-xs',\n description: 'text-sm text-gray-800 opacity-100',\n closeButton:\n 'absolute left-auto right-0 top-16 w-24 h-24 inline-flex items-center justify-center rounded-full bg-gray-900-8 hover:bg-gray-900-12 focus:bg-gray-900-12 active:bg-gray-900-16'\n }\n }}\n icons={{\n success: <CheckIcon size={20} className=\"text-green-800\" />,\n warning: <AlertTriangleIcon size={20} className=\"text-yellow-600\" />,\n error: <AlertCircleIcon size={20} className=\"text-magenta-600\" />,\n close: <LucideX size={16} />\n }}\n {...props}\n />\n )\n}\n\nexport { Toaster }\n"],"names":["Toaster","props","jsx","Sonner","CheckIcon","AlertTriangleIcon","AlertCircleIcon","LucideX"],"mappings":"kKAYMA,EAAU,CAAC,CAAE,GAAGC,KAElBC,EAAA,kBAAA,IAACC,EAAA,QAAA,CACC,UAAU,mBACV,SAAS,aACT,OAAQ,GACR,IAAK,GACL,YAAa,GACb,MAAO,CAAC,EACR,aAAc,CACZ,SAAU,GACV,WAAY,CACV,MACE,yHACF,QAAS,cACT,QAAS,eACT,MAAO,gBACP,MAAO,oDACP,YAAa,oCACb,YACE,gLACJ,CACF,EACA,MAAO,CACL,QAAUD,EAAA,kBAAA,IAAAE,YAAA,CAAU,KAAM,GAAI,UAAU,iBAAiB,EACzD,QAAUF,EAAA,kBAAA,IAAAG,oBAAA,CAAkB,KAAM,GAAI,UAAU,kBAAkB,EAClE,MAAQH,EAAA,kBAAA,IAAAI,kBAAA,CAAgB,KAAM,GAAI,UAAU,mBAAmB,EAC/D,MAAOJ,EAAAA,kBAAAA,IAACK,EAAAA,QAAQ,CAAA,KAAM,EAAI,CAAA,CAC5B,EACC,GAAGN,CAAA,CAAA"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index.cjs42.js"),c=require("lucide-react"),T=require("react"),s=require("./index.cjs43.js");function j(e){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const l=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(a,t,l.get?l:{enumerable:!0,get:()=>e[t]})}}return a.default=e,Object.freeze(a)}const o=j(T),i=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("table",{ref:t,className:s.cn("border-separate border-spacing-y-8",e),...a}));i.displayName="Table";const d=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("thead",{ref:t,className:s.cn("bg-gray-200 text-left text-sm",e),...a}));d.displayName="TableHeader";const b=o.forwardRef(({className:e,hoverable:a,...t},l)=>r.jsxRuntimeExports.jsx("tbody",{ref:l,className:s.cn("bg-white",{"[&_tr:hover]:bg-gray-100 cursor-pointer":a},e),...t}));b.displayName="TableBody";const p=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("tfoot",{ref:t,className:s.cn("bg-gray-100",e),...a}));p.displayName="TableFooter";const u=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("tr",{ref:t,className:s.cn("transition-colors data-[state=selected]:bg-gray-100",e),...a}));u.displayName="TableRow";const m=o.forwardRef(({className:e,sortDirection:a,children:t,...l},y)=>{let n;return a==="ASC"?n=c.LucideChevronUp:a==="DESC"&&(n=c.LucideChevronDown),r.jsxRuntimeExports.jsxs("th",{ref:y,className:s.cn("first:rounded-l first:pl-24","last:rounded-r last:pr-24","px-12 py-8 font-normal leading-14","whitespace-nowrap",{"cursor-pointer":!!l?.onClick},e),...l,children:[t,n&&r.jsxRuntimeExports.jsx(n,{size:16,className:"inline-block ml-4"})]})});m.displayName="TableHead";const f=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("td",{ref:t,className:s.cn("first:rounded-l first:pl-24 first:border-l-1","last:rounded-r last:pr-24 last:border-r-1","border-gray-900-8 border-y-1 px-12 h-[54px]","whitespace-nowrap",e),...a}));f.displayName="TableCell";const x=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("caption",{ref:t,className:s.cn("mt-16 text-sm text-gray-700",e),...a}));x.displayName="TableCaption";exports.Table=i;exports.TableBody=b;exports.TableCaption=x;exports.TableCell=f;exports.TableFooter=p;exports.TableHead=m;exports.TableHeader=d;exports.TableRow=u;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.cjs43.js"),d=require("@radix-ui/react-switch"),l=require("react"),s=require("./index.cjs44.js");function o(e){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const n=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(a,t,n.get?n:{enumerable:!0,get:()=>e[t]})}}return a.default=e,Object.freeze(a)}const r=o(d),u=o(l),i=u.forwardRef(({className:e,...a},t)=>c.jsxRuntimeExports.jsx(r.Root,{className:s.cn("peer inline-flex h-[20px] w-[36px] shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors disabled:cursor-not-allowed disabled:opacity-64","data-[state=checked]:bg-robinblue-500 data-[state=checked]:hover:bg-robinblue-600 data-[state=checked]:active:bg-robinblue-700","data-[state=unchecked]:bg-gray-900-16 data-[state=unchecked]:hover:bg-gray-900-24 data-[state=unchecked]:active:bg-gray-900-32",e),...a,ref:t,children:c.jsxRuntimeExports.jsx(r.Thumb,{className:s.cn("pointer-events-none block h-16 w-16 rounded-full bg-white shadow-lg transition-transform data-[state=checked]:translate-x-16 data-[state=unchecked]:translate-x-0")})}));i.displayName=r.Root.displayName;exports.Switch=i;
2
2
  //# sourceMappingURL=index.cjs30.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs30.js","sources":["../src/Table/index.tsx"],"sourcesContent":["import { LucideChevronDown, LucideChevronUp } from 'lucide-react'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes<HTMLTableElement>\n>(({ className, ...props }, ref) => (\n <table\n ref={ref}\n className={cn('border-separate border-spacing-y-8', className)}\n {...props}\n />\n))\nTable.displayName = 'Table'\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes<HTMLTableSectionElement>\n>(({ className, ...props }, ref) => (\n <thead\n ref={ref}\n className={cn('bg-gray-200 text-left text-sm', className)}\n {...props}\n />\n))\nTableHeader.displayName = 'TableHeader'\n\ntype TableBodyProps = React.HTMLAttributes<HTMLTableSectionElement> & {\n hoverable?: boolean\n}\nconst TableBody = React.forwardRef<HTMLTableSectionElement, TableBodyProps>(\n ({ className, hoverable, ...props }, ref) => (\n <tbody\n ref={ref}\n className={cn(\n 'bg-white',\n {\n '[&_tr:hover]:bg-gray-100 cursor-pointer': hoverable\n },\n className\n )}\n {...props}\n />\n )\n)\nTableBody.displayName = 'TableBody'\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes<HTMLTableSectionElement>\n>(({ className, ...props }, ref) => (\n <tfoot ref={ref} className={cn('bg-gray-100', className)} {...props} />\n))\nTableFooter.displayName = 'TableFooter'\n\nconst TableRow = React.forwardRef<\n HTMLTableRowElement,\n React.HTMLAttributes<HTMLTableRowElement>\n>(({ className, ...props }, ref) => (\n <tr\n ref={ref}\n className={cn(\n 'transition-colors data-[state=selected]:bg-gray-100',\n className\n )}\n {...props}\n />\n))\nTableRow.displayName = 'TableRow'\n\ntype TableHeadProps = React.ThHTMLAttributes<HTMLTableCellElement> & {\n sortDirection?: 'ASC' | 'DESC'\n}\n\nconst TableHead = React.forwardRef<HTMLTableCellElement, TableHeadProps>(\n ({ className, sortDirection, children, ...props }, ref) => {\n let SortIcon\n if (sortDirection === 'ASC') {\n SortIcon = LucideChevronUp\n } else if (sortDirection === 'DESC') {\n SortIcon = LucideChevronDown\n }\n return (\n <th\n ref={ref}\n className={cn(\n 'first:rounded-l first:pl-24',\n 'last:rounded-r last:pr-24',\n 'px-12 py-8 font-normal leading-14',\n 'whitespace-nowrap',\n {\n 'cursor-pointer': !!props?.onClick\n },\n className\n )}\n {...props}\n >\n {children}\n {SortIcon && <SortIcon size={16} className=\"inline-block ml-4\" />}\n </th>\n )\n }\n)\nTableHead.displayName = 'TableHead'\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes<HTMLTableCellElement>\n>(({ className, ...props }, ref) => (\n <td\n ref={ref}\n className={cn(\n 'first:rounded-l first:pl-24 first:border-l-1',\n 'last:rounded-r last:pr-24 last:border-r-1',\n 'border-gray-900-8 border-y-1 px-12 h-[54px]',\n 'whitespace-nowrap',\n className\n )}\n {...props}\n />\n))\nTableCell.displayName = 'TableCell'\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes<HTMLTableCaptionElement>\n>(({ className, ...props }, ref) => (\n <caption\n ref={ref}\n className={cn('mt-16 text-sm text-gray-700', className)}\n {...props}\n />\n))\nTableCaption.displayName = 'TableCaption'\n\nexport {\n Table,\n TableBody,\n TableCaption,\n TableCell,\n TableFooter,\n TableHead,\n TableHeader,\n TableRow\n}\n"],"names":["Table","React","className","props","ref","jsx","cn","TableHeader","TableBody","hoverable","TableFooter","TableRow","TableHead","sortDirection","children","SortIcon","LucideChevronUp","LucideChevronDown","jsxs","TableCell","TableCaption"],"mappings":"ydAIMA,EAAQC,EAAM,WAGlB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAAC,QAAA,CACC,IAAAD,EACA,UAAWE,EAAAA,GAAG,qCAAsCJ,CAAS,EAC5D,GAAGC,CAAA,CACN,CACD,EACDH,EAAM,YAAc,QAEd,MAAAO,EAAcN,EAAM,WAGxB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAAC,QAAA,CACC,IAAAD,EACA,UAAWE,EAAAA,GAAG,gCAAiCJ,CAAS,EACvD,GAAGC,CAAA,CACN,CACD,EACDI,EAAY,YAAc,cAK1B,MAAMC,EAAYP,EAAM,WACtB,CAAC,CAAE,UAAAC,EAAW,UAAAO,EAAW,GAAGN,GAASC,IACnCC,EAAA,kBAAA,IAAC,QAAA,CACC,IAAAD,EACA,UAAWE,EAAA,GACT,WACA,CACE,0CAA2CG,CAC7C,EACAP,CACF,EACC,GAAGC,CAAA,CACN,CAEJ,EACAK,EAAU,YAAc,YAElB,MAAAE,EAAcT,EAAM,WAGxB,CAAC,CAAE,UAAAC,EAAW,GAAGC,GAASC,4BACzB,QAAM,CAAA,IAAAA,EAAU,UAAWE,KAAG,cAAeJ,CAAS,EAAI,GAAGC,EAAO,CACtE,EACDO,EAAY,YAAc,cAEpB,MAAAC,EAAWV,EAAM,WAGrB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAAC,KAAA,CACC,IAAAD,EACA,UAAWE,EAAA,GACT,sDACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDQ,EAAS,YAAc,WAMvB,MAAMC,EAAYX,EAAM,WACtB,CAAC,CAAE,UAAAC,EAAW,cAAAW,EAAe,SAAAC,EAAU,GAAGX,GAASC,IAAQ,CACrD,IAAAW,EACJ,OAAIF,IAAkB,MACTE,EAAAC,EAAAA,gBACFH,IAAkB,SAChBE,EAAAE,EAAAA,mBAGXC,EAAA,kBAAA,KAAC,KAAA,CACC,IAAAd,EACA,UAAWE,EAAA,GACT,8BACA,4BACA,oCACA,oBACA,CACE,iBAAkB,CAAC,CAACH,GAAO,OAC7B,EACAD,CACF,EACC,GAAGC,EAEH,SAAA,CAAAW,EACAC,GAAaV,EAAA,kBAAA,IAAAU,EAAA,CAAS,KAAM,GAAI,UAAU,oBAAoB,CAAA,CAAA,CAAA,CAGrE,CACF,EACAH,EAAU,YAAc,YAElB,MAAAO,EAAYlB,EAAM,WAGtB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAAC,KAAA,CACC,IAAAD,EACA,UAAWE,EAAA,GACT,+CACA,4CACA,8CACA,oBACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDgB,EAAU,YAAc,YAElB,MAAAC,EAAenB,EAAM,WAGzB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAAC,UAAA,CACC,IAAAD,EACA,UAAWE,EAAAA,GAAG,8BAA+BJ,CAAS,EACrD,GAAGC,CAAA,CACN,CACD,EACDiB,EAAa,YAAc"}
1
+ {"version":3,"file":"index.cjs30.js","sources":["../src/Switch/index.tsx"],"sourcesContent":["'use client'\n\nimport * as SwitchPrimitives from '@radix-ui/react-switch'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst Switch = React.forwardRef<\n React.ElementRef<typeof SwitchPrimitives.Root>,\n React.ComponentPropsWithoutRef<typeof SwitchPrimitives.Root>\n>(({ className, ...props }, ref) => (\n <SwitchPrimitives.Root\n className={cn(\n 'peer inline-flex h-[20px] w-[36px] shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors disabled:cursor-not-allowed disabled:opacity-64',\n 'data-[state=checked]:bg-robinblue-500 data-[state=checked]:hover:bg-robinblue-600 data-[state=checked]:active:bg-robinblue-700',\n 'data-[state=unchecked]:bg-gray-900-16 data-[state=unchecked]:hover:bg-gray-900-24 data-[state=unchecked]:active:bg-gray-900-32',\n className\n )}\n {...props}\n ref={ref}\n >\n <SwitchPrimitives.Thumb\n className={cn(\n 'pointer-events-none block h-16 w-16 rounded-full bg-white shadow-lg transition-transform data-[state=checked]:translate-x-16 data-[state=unchecked]:translate-x-0'\n )}\n />\n </SwitchPrimitives.Root>\n))\nSwitch.displayName = SwitchPrimitives.Root.displayName\n\nexport { Switch }\n"],"names":["Switch","React","className","props","ref","jsx","SwitchPrimitives","cn"],"mappings":"0eAMMA,EAASC,EAAM,WAGnB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACC,EAAiB,KAAjB,CACC,UAAWC,EAAA,GACT,qLACA,iIACA,iIACAL,CACF,EACC,GAAGC,EACJ,IAAAC,EAEA,SAAAC,EAAA,kBAAA,IAACC,EAAiB,MAAjB,CACC,UAAWC,EAAA,GACT,mKACF,CAAA,CACF,CAAA,CACF,CACD,EACDP,EAAO,YAAcM,EAAiB,KAAK"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index.cjs42.js"),d=require("@radix-ui/react-tabs"),b=require("react"),n=require("./index.cjs43.js");function c(e){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const o=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(a,t,o.get?o:{enumerable:!0,get:()=>e[t]})}}return a.default=e,Object.freeze(a)}const s=c(d),r=c(b),g=s.Root,l=r.forwardRef(({className:e,...a},t)=>i.jsxRuntimeExports.jsx(s.List,{ref:t,className:n.cn("inline-flex h-[28px] items-center justify-center rounded-full bg-transparent text-base font-normal text-gray-900 [&_svg]:text-gray-700 [&_i]:text-gray-700 gap-x-8",e),...a}));l.displayName=s.List.displayName;const u=r.forwardRef(({className:e,...a},t)=>i.jsxRuntimeExports.jsx(s.Trigger,{ref:t,className:n.cn("inline-flex items-center justify-center whitespace-nowrap rounded-full px-8 py-4 transition-all focus-visible:outline-none disabled:pointer-events-none disabled:opacity-64","hover:bg-gray-900-8 active:bg-gray-900-12 data-[state=active]:bg-purple-600 data-[state=active]:hover:bg-purple-600 data-[state=active]:active:bg-purple-600 data-[state=active]:text-white [&_svg]:data-[state=active]:text-white [&_i]:data-[state=active]:text-white",e),...a}));u.displayName=s.Trigger.displayName;const p=r.forwardRef(({className:e,...a},t)=>i.jsxRuntimeExports.jsx(s.Content,{ref:t,className:n.cn("mt-8 focus-visible:outline-none",e),...a}));p.displayName=s.Content.displayName;exports.Tabs=g;exports.TabsContent=p;exports.TabsList=l;exports.TabsTrigger=u;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index.cjs43.js"),c=require("lucide-react"),T=require("react"),s=require("./index.cjs44.js");function j(e){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const l=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(a,t,l.get?l:{enumerable:!0,get:()=>e[t]})}}return a.default=e,Object.freeze(a)}const o=j(T),i=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("table",{ref:t,className:s.cn("border-separate border-spacing-y-8",e),...a}));i.displayName="Table";const d=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("thead",{ref:t,className:s.cn("bg-gray-200 text-left text-sm",e),...a}));d.displayName="TableHeader";const b=o.forwardRef(({className:e,hoverable:a,...t},l)=>r.jsxRuntimeExports.jsx("tbody",{ref:l,className:s.cn("bg-white",{"[&_tr:hover]:bg-gray-100 cursor-pointer":a},e),...t}));b.displayName="TableBody";const p=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("tfoot",{ref:t,className:s.cn("bg-gray-100",e),...a}));p.displayName="TableFooter";const u=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("tr",{ref:t,className:s.cn("transition-colors data-[state=selected]:bg-gray-100",e),...a}));u.displayName="TableRow";const m=o.forwardRef(({className:e,sortDirection:a,children:t,...l},y)=>{let n;return a==="ASC"?n=c.LucideChevronUp:a==="DESC"&&(n=c.LucideChevronDown),r.jsxRuntimeExports.jsxs("th",{ref:y,className:s.cn("first:rounded-l first:pl-24","last:rounded-r last:pr-24","px-12 py-8 font-normal leading-14","whitespace-nowrap",{"cursor-pointer":!!l?.onClick},e),...l,children:[t,n&&r.jsxRuntimeExports.jsx(n,{size:16,className:"inline-block ml-4"})]})});m.displayName="TableHead";const f=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("td",{ref:t,className:s.cn("first:rounded-l first:pl-24 first:border-l-1","last:rounded-r last:pr-24 last:border-r-1","border-gray-900-8 border-y-1 px-12 h-[54px]","whitespace-nowrap",e),...a}));f.displayName="TableCell";const x=o.forwardRef(({className:e,...a},t)=>r.jsxRuntimeExports.jsx("caption",{ref:t,className:s.cn("mt-16 text-sm text-gray-700",e),...a}));x.displayName="TableCaption";exports.Table=i;exports.TableBody=b;exports.TableCaption=x;exports.TableCell=f;exports.TableFooter=p;exports.TableHead=m;exports.TableHeader=d;exports.TableRow=u;
2
2
  //# sourceMappingURL=index.cjs31.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs31.js","sources":["../src/Tabs/index.tsx"],"sourcesContent":["'use client'\n\nimport * as TabsPrimitive from '@radix-ui/react-tabs'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst Tabs = TabsPrimitive.Root\n\nconst TabsList = React.forwardRef<\n React.ElementRef<typeof TabsPrimitive.List>,\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.List>\n>(({ className, ...props }, ref) => (\n <TabsPrimitive.List\n ref={ref}\n className={cn(\n 'inline-flex h-[28px] items-center justify-center rounded-full bg-transparent text-base font-normal text-gray-900 [&_svg]:text-gray-700 [&_i]:text-gray-700 gap-x-8',\n className\n )}\n {...props}\n />\n))\nTabsList.displayName = TabsPrimitive.List.displayName\n\nconst TabsTrigger = React.forwardRef<\n React.ElementRef<typeof TabsPrimitive.Trigger>,\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger>\n>(({ className, ...props }, ref) => (\n <TabsPrimitive.Trigger\n ref={ref}\n className={cn(\n 'inline-flex items-center justify-center whitespace-nowrap rounded-full px-8 py-4 transition-all focus-visible:outline-none disabled:pointer-events-none disabled:opacity-64',\n 'hover:bg-gray-900-8 active:bg-gray-900-12 data-[state=active]:bg-purple-600 data-[state=active]:hover:bg-purple-600 data-[state=active]:active:bg-purple-600 data-[state=active]:text-white [&_svg]:data-[state=active]:text-white [&_i]:data-[state=active]:text-white',\n className\n )}\n {...props}\n />\n))\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName\n\nconst TabsContent = React.forwardRef<\n React.ElementRef<typeof TabsPrimitive.Content>,\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.Content>\n>(({ className, ...props }, ref) => (\n <TabsPrimitive.Content\n ref={ref}\n className={cn('mt-8 focus-visible:outline-none', className)}\n {...props}\n />\n))\nTabsContent.displayName = TabsPrimitive.Content.displayName\n\nexport { Tabs, TabsList, TabsTrigger, TabsContent }\n"],"names":["Tabs","TabsPrimitive","TabsList","React","className","props","ref","jsx","cn","TabsTrigger","TabsContent"],"mappings":"weAMMA,EAAOC,EAAc,KAErBC,EAAWC,EAAM,WAGrB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAc,KAAd,CACC,IAAAK,EACA,UAAWE,EAAA,GACT,qKACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDH,EAAS,YAAcD,EAAc,KAAK,YAEpC,MAAAQ,EAAcN,EAAM,WAGxB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAc,QAAd,CACC,IAAAK,EACA,UAAWE,EAAA,GACT,8KACA,0QACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDI,EAAY,YAAcR,EAAc,QAAQ,YAE1C,MAAAS,EAAcP,EAAM,WAGxB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAc,QAAd,CACC,IAAAK,EACA,UAAWE,EAAAA,GAAG,kCAAmCJ,CAAS,EACzD,GAAGC,CAAA,CACN,CACD,EACDK,EAAY,YAAcT,EAAc,QAAQ"}
1
+ {"version":3,"file":"index.cjs31.js","sources":["../src/Table/index.tsx"],"sourcesContent":["import { LucideChevronDown, LucideChevronUp } from 'lucide-react'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes<HTMLTableElement>\n>(({ className, ...props }, ref) => (\n <table\n ref={ref}\n className={cn('border-separate border-spacing-y-8', className)}\n {...props}\n />\n))\nTable.displayName = 'Table'\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes<HTMLTableSectionElement>\n>(({ className, ...props }, ref) => (\n <thead\n ref={ref}\n className={cn('bg-gray-200 text-left text-sm', className)}\n {...props}\n />\n))\nTableHeader.displayName = 'TableHeader'\n\ntype TableBodyProps = React.HTMLAttributes<HTMLTableSectionElement> & {\n hoverable?: boolean\n}\nconst TableBody = React.forwardRef<HTMLTableSectionElement, TableBodyProps>(\n ({ className, hoverable, ...props }, ref) => (\n <tbody\n ref={ref}\n className={cn(\n 'bg-white',\n {\n '[&_tr:hover]:bg-gray-100 cursor-pointer': hoverable\n },\n className\n )}\n {...props}\n />\n )\n)\nTableBody.displayName = 'TableBody'\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes<HTMLTableSectionElement>\n>(({ className, ...props }, ref) => (\n <tfoot ref={ref} className={cn('bg-gray-100', className)} {...props} />\n))\nTableFooter.displayName = 'TableFooter'\n\nconst TableRow = React.forwardRef<\n HTMLTableRowElement,\n React.HTMLAttributes<HTMLTableRowElement>\n>(({ className, ...props }, ref) => (\n <tr\n ref={ref}\n className={cn(\n 'transition-colors data-[state=selected]:bg-gray-100',\n className\n )}\n {...props}\n />\n))\nTableRow.displayName = 'TableRow'\n\ntype TableHeadProps = React.ThHTMLAttributes<HTMLTableCellElement> & {\n sortDirection?: 'ASC' | 'DESC'\n}\n\nconst TableHead = React.forwardRef<HTMLTableCellElement, TableHeadProps>(\n ({ className, sortDirection, children, ...props }, ref) => {\n let SortIcon\n if (sortDirection === 'ASC') {\n SortIcon = LucideChevronUp\n } else if (sortDirection === 'DESC') {\n SortIcon = LucideChevronDown\n }\n return (\n <th\n ref={ref}\n className={cn(\n 'first:rounded-l first:pl-24',\n 'last:rounded-r last:pr-24',\n 'px-12 py-8 font-normal leading-14',\n 'whitespace-nowrap',\n {\n 'cursor-pointer': !!props?.onClick\n },\n className\n )}\n {...props}\n >\n {children}\n {SortIcon && <SortIcon size={16} className=\"inline-block ml-4\" />}\n </th>\n )\n }\n)\nTableHead.displayName = 'TableHead'\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes<HTMLTableCellElement>\n>(({ className, ...props }, ref) => (\n <td\n ref={ref}\n className={cn(\n 'first:rounded-l first:pl-24 first:border-l-1',\n 'last:rounded-r last:pr-24 last:border-r-1',\n 'border-gray-900-8 border-y-1 px-12 h-[54px]',\n 'whitespace-nowrap',\n className\n )}\n {...props}\n />\n))\nTableCell.displayName = 'TableCell'\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes<HTMLTableCaptionElement>\n>(({ className, ...props }, ref) => (\n <caption\n ref={ref}\n className={cn('mt-16 text-sm text-gray-700', className)}\n {...props}\n />\n))\nTableCaption.displayName = 'TableCaption'\n\nexport {\n Table,\n TableBody,\n TableCaption,\n TableCell,\n TableFooter,\n TableHead,\n TableHeader,\n TableRow\n}\n"],"names":["Table","React","className","props","ref","jsx","cn","TableHeader","TableBody","hoverable","TableFooter","TableRow","TableHead","sortDirection","children","SortIcon","LucideChevronUp","LucideChevronDown","jsxs","TableCell","TableCaption"],"mappings":"ydAIMA,EAAQC,EAAM,WAGlB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAAC,QAAA,CACC,IAAAD,EACA,UAAWE,EAAAA,GAAG,qCAAsCJ,CAAS,EAC5D,GAAGC,CAAA,CACN,CACD,EACDH,EAAM,YAAc,QAEd,MAAAO,EAAcN,EAAM,WAGxB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAAC,QAAA,CACC,IAAAD,EACA,UAAWE,EAAAA,GAAG,gCAAiCJ,CAAS,EACvD,GAAGC,CAAA,CACN,CACD,EACDI,EAAY,YAAc,cAK1B,MAAMC,EAAYP,EAAM,WACtB,CAAC,CAAE,UAAAC,EAAW,UAAAO,EAAW,GAAGN,GAASC,IACnCC,EAAA,kBAAA,IAAC,QAAA,CACC,IAAAD,EACA,UAAWE,EAAA,GACT,WACA,CACE,0CAA2CG,CAC7C,EACAP,CACF,EACC,GAAGC,CAAA,CACN,CAEJ,EACAK,EAAU,YAAc,YAElB,MAAAE,EAAcT,EAAM,WAGxB,CAAC,CAAE,UAAAC,EAAW,GAAGC,GAASC,4BACzB,QAAM,CAAA,IAAAA,EAAU,UAAWE,KAAG,cAAeJ,CAAS,EAAI,GAAGC,EAAO,CACtE,EACDO,EAAY,YAAc,cAEpB,MAAAC,EAAWV,EAAM,WAGrB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAAC,KAAA,CACC,IAAAD,EACA,UAAWE,EAAA,GACT,sDACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDQ,EAAS,YAAc,WAMvB,MAAMC,EAAYX,EAAM,WACtB,CAAC,CAAE,UAAAC,EAAW,cAAAW,EAAe,SAAAC,EAAU,GAAGX,GAASC,IAAQ,CACrD,IAAAW,EACJ,OAAIF,IAAkB,MACTE,EAAAC,EAAAA,gBACFH,IAAkB,SAChBE,EAAAE,EAAAA,mBAGXC,EAAA,kBAAA,KAAC,KAAA,CACC,IAAAd,EACA,UAAWE,EAAA,GACT,8BACA,4BACA,oCACA,oBACA,CACE,iBAAkB,CAAC,CAACH,GAAO,OAC7B,EACAD,CACF,EACC,GAAGC,EAEH,SAAA,CAAAW,EACAC,GAAaV,EAAA,kBAAA,IAAAU,EAAA,CAAS,KAAM,GAAI,UAAU,oBAAoB,CAAA,CAAA,CAAA,CAGrE,CACF,EACAH,EAAU,YAAc,YAElB,MAAAO,EAAYlB,EAAM,WAGtB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAAC,KAAA,CACC,IAAAD,EACA,UAAWE,EAAA,GACT,+CACA,4CACA,8CACA,oBACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDgB,EAAU,YAAc,YAElB,MAAAC,EAAenB,EAAM,WAGzB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAAC,UAAA,CACC,IAAAD,EACA,UAAWE,EAAAA,GAAG,8BAA+BJ,CAAS,EACrD,GAAGC,CAAA,CACN,CACD,EACDiB,EAAa,YAAc"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index.cjs42.js"),R=require("lucide-react"),b=require("react"),w=require("./index.cjs7.js"),E=require("./index.cjs8.js"),N=require("./index.cjs43.js");function k(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const s in t)if(s!=="default"){const n=Object.getOwnPropertyDescriptor(t,s);Object.defineProperty(e,s,n.get?n:{enumerable:!0,get:()=>t[s]})}}return e.default=t,Object.freeze(e)}const x=k(b),m=x.forwardRef(({className:t,value:e,placeholder:s,onValueChange:n,...d},a)=>{const[i,o]=x.useState(""),p=x.useRef(null);function j(c){const l=c.target.value;if(l.includes(",")){const g=l.split(","),y=Array.from(new Set(g));n([...e||[],...y.filter(u=>!!u&&!e?.includes(u)).map(u=>u.trim())||[]]),o("");return}o(l)}function h(c){["Enter","Tab"].includes(c.key)&&i?.trim()&&(c.preventDefault(),e?.includes(i)||f(),o("")),c.key==="Backspace"&&!i&&n(e?.slice(0,-1)||[])}function f(){i.trim()&&(n([...e||[],i]),o(""))}return r.jsxRuntimeExports.jsxs("div",{ref:a,className:N.cn("flex flex-wrap items-center gap-8 min-h-[36px]","border rounded border-gray-900-24 bg-white px-12 py-[4px]","hover:cursor-text","hover:shadow-field-hover","active:shadow-field-active","focus-visible:outline-none focus:shadow-field-active",t),onClick:()=>p.current?.focus(),...d,children:[r.jsxRuntimeExports.jsx(q,{value:e,onValueChange:n}),r.jsxRuntimeExports.jsx("input",{ref:p,className:"h-[26px] outline-none text-sm",type:"text",value:i,onChange:j,onKeyDown:h,style:{width:`${i.length+1}ch`},onBlur:()=>f()}),e?.length===0&&!i&&r.jsxRuntimeExports.jsx("div",{className:"text-gray-700 ml-[-2ch]",children:s})]})});m.displayName="TagInput";function q({value:t,onValueChange:e}){return r.jsxRuntimeExports.jsx(r.jsxRuntimeExports.Fragment,{children:t?.map((s,n)=>r.jsxRuntimeExports.jsxs(w.Badge,{className:"pl-0 gap-x-4 overflow-hidden",children:[r.jsxRuntimeExports.jsx(E.Button,{type:"button",className:"w-[26px] h-[26px] flex-shrink-0",size:"icon",intent:"secondary",onClick:()=>{e(t?.filter((d,a)=>a!==n)||[])},children:r.jsxRuntimeExports.jsx(R.LucideX,{className:"w-16"})}),r.jsxRuntimeExports.jsx("div",{className:"truncate",children:s})]},n))})}exports.TagInput=m;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index.cjs43.js"),d=require("@radix-ui/react-tabs"),b=require("react"),n=require("./index.cjs44.js");function c(e){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const o=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(a,t,o.get?o:{enumerable:!0,get:()=>e[t]})}}return a.default=e,Object.freeze(a)}const s=c(d),r=c(b),g=s.Root,l=r.forwardRef(({className:e,...a},t)=>i.jsxRuntimeExports.jsx(s.List,{ref:t,className:n.cn("inline-flex h-[28px] items-center justify-center rounded-full bg-transparent text-base font-normal text-gray-900 [&_svg]:text-gray-700 [&_i]:text-gray-700 gap-x-8",e),...a}));l.displayName=s.List.displayName;const u=r.forwardRef(({className:e,...a},t)=>i.jsxRuntimeExports.jsx(s.Trigger,{ref:t,className:n.cn("inline-flex items-center justify-center whitespace-nowrap rounded-full px-8 py-4 transition-all focus-visible:outline-none disabled:pointer-events-none disabled:opacity-64","hover:bg-gray-900-8 active:bg-gray-900-12 data-[state=active]:bg-purple-600 data-[state=active]:hover:bg-purple-600 data-[state=active]:active:bg-purple-600 data-[state=active]:text-white [&_svg]:data-[state=active]:text-white [&_i]:data-[state=active]:text-white",e),...a}));u.displayName=s.Trigger.displayName;const p=r.forwardRef(({className:e,...a},t)=>i.jsxRuntimeExports.jsx(s.Content,{ref:t,className:n.cn("mt-8 focus-visible:outline-none",e),...a}));p.displayName=s.Content.displayName;exports.Tabs=g;exports.TabsContent=p;exports.TabsList=l;exports.TabsTrigger=u;
2
2
  //# sourceMappingURL=index.cjs32.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs32.js","sources":["../src/TagInput/index.tsx"],"sourcesContent":["import { LucideX } from 'lucide-react'\nimport * as React from 'react'\nimport { Badge } from '../Badge'\nimport { Button } from '../Button'\nimport { cn } from '../lib/utils'\n\nexport type TagInputProps = React.HTMLAttributes<HTMLInputElement> & {\n value?: string[]\n onValueChange: (value: string[]) => void\n placeholder?: string\n}\n\nconst TagInput = React.forwardRef<HTMLInputElement, TagInputProps>(\n ({ className, value, placeholder, onValueChange, ...props }, ref) => {\n const [inputValue, setInputValue] = React.useState('')\n const inputRef = React.useRef<HTMLInputElement>(null)\n\n function handleChange(event: React.ChangeEvent<HTMLInputElement>) {\n const currentInputValue = event.target.value\n if (currentInputValue.includes(',')) {\n const currentValues = currentInputValue.split(',')\n //Remove duplicates\n const uniqueValues = Array.from(new Set(currentValues))\n\n onValueChange([\n ...(value || []),\n ...(uniqueValues\n .filter(inputValue => {\n //Remove empty values and already added values\n return Boolean(inputValue) && !value?.includes(inputValue)\n })\n .map(i => i.trim()) || [])\n ])\n setInputValue('')\n return\n }\n setInputValue(currentInputValue)\n }\n\n function handleKeyDown(event: React.KeyboardEvent<HTMLInputElement>) {\n if (['Enter', 'Tab'].includes(event.key)) {\n if (inputValue?.trim()) {\n event.preventDefault()\n if (!value?.includes(inputValue)) {\n addInputValue()\n }\n setInputValue('')\n }\n }\n\n if (event.key === 'Backspace' && !inputValue) {\n onValueChange(value?.slice(0, -1) || [])\n }\n }\n\n function addInputValue() {\n if (!inputValue.trim()) return\n onValueChange([...(value || []), inputValue])\n setInputValue('')\n }\n\n return (\n <div\n ref={ref}\n className={cn(\n 'flex flex-wrap items-center gap-8 min-h-[36px]',\n 'border rounded border-gray-900-24 bg-white px-12 py-[4px]',\n 'hover:cursor-text',\n 'hover:shadow-field-hover',\n 'active:shadow-field-active',\n 'focus-visible:outline-none focus:shadow-field-active',\n className\n )}\n onClick={() => inputRef.current?.focus()}\n {...props}\n >\n <TagList value={value} onValueChange={onValueChange} />\n <input\n ref={inputRef}\n className=\"h-[26px] outline-none text-sm\"\n type=\"text\"\n value={inputValue}\n onChange={handleChange}\n onKeyDown={handleKeyDown}\n style={{ width: `${inputValue.length + 1}ch` }}\n onBlur={() => addInputValue()}\n />\n {value?.length === 0 && !inputValue && (\n <div className=\"text-gray-700 ml-[-2ch]\">{placeholder}</div>\n )}\n </div>\n )\n }\n)\n\nTagInput.displayName = 'TagInput'\n\ntype TagListProps = React.HTMLAttributes<HTMLDivElement> & {\n value?: string[]\n onValueChange: (value: string[]) => void\n}\n\nfunction TagList({ value, onValueChange }: TagListProps) {\n return (\n <>\n {value?.map((tag, index) => (\n <Badge key={index} className=\"pl-0 gap-x-4 overflow-hidden\">\n <Button\n type=\"button\"\n className=\"w-[26px] h-[26px] flex-shrink-0\"\n size=\"icon\"\n intent=\"secondary\"\n onClick={() => {\n onValueChange(value?.filter((_, i) => i !== index) || [])\n }}\n >\n <LucideX className=\"w-16\" />\n </Button>\n <div className=\"truncate\">{tag}</div>\n </Badge>\n ))}\n </>\n )\n}\n\nexport { TagInput }\n"],"names":["TagInput","React","className","value","placeholder","onValueChange","props","ref","inputValue","setInputValue","inputRef","handleChange","event","currentInputValue","currentValues","uniqueValues","i","handleKeyDown","addInputValue","jsxs","cn","jsx","TagList","Fragment","tag","index","Badge","Button","_","LucideX"],"mappings":"mhBAYMA,EAAWC,EAAM,WACrB,CAAC,CAAE,UAAAC,EAAW,MAAAC,EAAO,YAAAC,EAAa,cAAAC,EAAe,GAAGC,CAAM,EAAGC,IAAQ,CACnE,KAAM,CAACC,EAAYC,CAAa,EAAIR,EAAM,SAAS,EAAE,EAC/CS,EAAWT,EAAM,OAAyB,IAAI,EAEpD,SAASU,EAAaC,EAA4C,CAC1D,MAAAC,EAAoBD,EAAM,OAAO,MACnC,GAAAC,EAAkB,SAAS,GAAG,EAAG,CAC7B,MAAAC,EAAgBD,EAAkB,MAAM,GAAG,EAE3CE,EAAe,MAAM,KAAK,IAAI,IAAID,CAAa,CAAC,EAExCT,EAAA,CACZ,GAAIF,GAAS,CAAC,EACd,GAAIY,EACD,OAAOP,GAEC,EAAQA,GAAe,CAACL,GAAO,SAASK,CAAU,CAC1D,EACA,IAAIQ,GAAKA,EAAE,KAAM,CAAA,GAAK,CAAC,CAAA,CAC3B,EACDP,EAAc,EAAE,EAChB,MACF,CACAA,EAAcI,CAAiB,CACjC,CAEA,SAASI,EAAcL,EAA8C,CAC/D,CAAC,QAAS,KAAK,EAAE,SAASA,EAAM,GAAG,GACjCJ,GAAY,SACdI,EAAM,eAAe,EAChBT,GAAO,SAASK,CAAU,GACfU,IAEhBT,EAAc,EAAE,GAIhBG,EAAM,MAAQ,aAAe,CAACJ,GAChCH,EAAcF,GAAO,MAAM,EAAG,EAAE,GAAK,CAAA,CAAE,CAE3C,CAEA,SAASe,GAAgB,CAClBV,EAAW,KAAK,IACrBH,EAAc,CAAC,GAAIF,GAAS,CAAA,EAAKK,CAAU,CAAC,EAC5CC,EAAc,EAAE,EAClB,CAGE,OAAAU,EAAA,kBAAA,KAAC,MAAA,CACC,IAAAZ,EACA,UAAWa,EAAA,GACT,iDACA,4DACA,oBACA,2BACA,6BACA,uDACAlB,CACF,EACA,QAAS,IAAMQ,EAAS,SAAS,MAAM,EACtC,GAAGJ,EAEJ,SAAA,CAACe,EAAAA,kBAAAA,IAAAC,EAAA,CAAQ,MAAAnB,EAAc,cAAAE,CAA8B,CAAA,EACrDgB,EAAA,kBAAA,IAAC,QAAA,CACC,IAAKX,EACL,UAAU,gCACV,KAAK,OACL,MAAOF,EACP,SAAUG,EACV,UAAWM,EACX,MAAO,CAAE,MAAO,GAAGT,EAAW,OAAS,CAAC,IAAK,EAC7C,OAAQ,IAAMU,EAAc,CAAA,CAC9B,EACCf,GAAO,SAAW,GAAK,CAACK,GACtBa,EAAA,kBAAA,IAAA,MAAA,CAAI,UAAU,0BAA2B,SAAYjB,CAAA,CAAA,CAAA,CAAA,CAAA,CAI9D,CACF,EAEAJ,EAAS,YAAc,WAOvB,SAASsB,EAAQ,CAAE,MAAAnB,EAAO,cAAAE,GAA+B,CAErD,OAAAgB,EAAA,kBAAA,IAAAE,EAAA,kBAAA,SAAA,CACG,YAAO,IAAI,CAACC,EAAKC,IAChBN,EAAA,kBAAA,KAACO,EAAkB,MAAA,CAAA,UAAU,+BAC3B,SAAA,CAAAL,EAAA,kBAAA,IAACM,EAAA,OAAA,CACC,KAAK,SACL,UAAU,kCACV,KAAK,OACL,OAAO,YACP,QAAS,IAAM,CACCtB,EAAAF,GAAO,OAAO,CAACyB,EAAGZ,IAAMA,IAAMS,CAAK,GAAK,CAAA,CAAE,CAC1D,EAEA,SAAAJ,EAAAA,kBAAAA,IAACQ,EAAAA,QAAQ,CAAA,UAAU,MAAO,CAAA,CAAA,CAC5B,EACCR,EAAA,kBAAA,IAAA,MAAA,CAAI,UAAU,WAAY,SAAIG,EAAA,CAAA,GAZrBC,CAaZ,CACD,CACH,CAAA,CAEJ"}
1
+ {"version":3,"file":"index.cjs32.js","sources":["../src/Tabs/index.tsx"],"sourcesContent":["'use client'\n\nimport * as TabsPrimitive from '@radix-ui/react-tabs'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst Tabs = TabsPrimitive.Root\n\nconst TabsList = React.forwardRef<\n React.ElementRef<typeof TabsPrimitive.List>,\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.List>\n>(({ className, ...props }, ref) => (\n <TabsPrimitive.List\n ref={ref}\n className={cn(\n 'inline-flex h-[28px] items-center justify-center rounded-full bg-transparent text-base font-normal text-gray-900 [&_svg]:text-gray-700 [&_i]:text-gray-700 gap-x-8',\n className\n )}\n {...props}\n />\n))\nTabsList.displayName = TabsPrimitive.List.displayName\n\nconst TabsTrigger = React.forwardRef<\n React.ElementRef<typeof TabsPrimitive.Trigger>,\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger>\n>(({ className, ...props }, ref) => (\n <TabsPrimitive.Trigger\n ref={ref}\n className={cn(\n 'inline-flex items-center justify-center whitespace-nowrap rounded-full px-8 py-4 transition-all focus-visible:outline-none disabled:pointer-events-none disabled:opacity-64',\n 'hover:bg-gray-900-8 active:bg-gray-900-12 data-[state=active]:bg-purple-600 data-[state=active]:hover:bg-purple-600 data-[state=active]:active:bg-purple-600 data-[state=active]:text-white [&_svg]:data-[state=active]:text-white [&_i]:data-[state=active]:text-white',\n className\n )}\n {...props}\n />\n))\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName\n\nconst TabsContent = React.forwardRef<\n React.ElementRef<typeof TabsPrimitive.Content>,\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.Content>\n>(({ className, ...props }, ref) => (\n <TabsPrimitive.Content\n ref={ref}\n className={cn('mt-8 focus-visible:outline-none', className)}\n {...props}\n />\n))\nTabsContent.displayName = TabsPrimitive.Content.displayName\n\nexport { Tabs, TabsList, TabsTrigger, TabsContent }\n"],"names":["Tabs","TabsPrimitive","TabsList","React","className","props","ref","jsx","cn","TabsTrigger","TabsContent"],"mappings":"weAMMA,EAAOC,EAAc,KAErBC,EAAWC,EAAM,WAGrB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAc,KAAd,CACC,IAAAK,EACA,UAAWE,EAAA,GACT,qKACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDH,EAAS,YAAcD,EAAc,KAAK,YAEpC,MAAAQ,EAAcN,EAAM,WAGxB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAc,QAAd,CACC,IAAAK,EACA,UAAWE,EAAA,GACT,8KACA,0QACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDI,EAAY,YAAcR,EAAc,QAAQ,YAE1C,MAAAS,EAAcP,EAAM,WAGxB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAc,QAAd,CACC,IAAAK,EACA,UAAWE,EAAAA,GAAG,kCAAmCJ,CAAS,EACzD,GAAGC,CAAA,CACN,CACD,EACDK,EAAY,YAAcT,EAAc,QAAQ"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index.cjs42.js"),i=require("react"),s=require("./index.cjs43.js");function c(e){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const a=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,a.get?a:{enumerable:!0,get:()=>e[t]})}}return r.default=e,Object.freeze(r)}const l=c(i),o=l.forwardRef(({className:e,...r},t)=>n.jsxRuntimeExports.jsx("textarea",{className:s.cn("flex min-h-[60px] w-full rounded border border-gray-900-24 bg-white px-12 py-8 text-base","placeholder:text-gray-600","hover:shadow-field-hover","active:shadow-field-active","focus-visible:outline-none focus:shadow-field-active","disabled:cursor-not-allowed disabled:opacity-64 disabled:shadow-none",e),ref:t,...r}));o.displayName="Textarea";exports.Textarea=o;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index.cjs43.js"),R=require("lucide-react"),b=require("react"),w=require("./index.cjs7.js"),E=require("./index.cjs8.js"),N=require("./index.cjs44.js");function k(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const s in t)if(s!=="default"){const n=Object.getOwnPropertyDescriptor(t,s);Object.defineProperty(e,s,n.get?n:{enumerable:!0,get:()=>t[s]})}}return e.default=t,Object.freeze(e)}const x=k(b),m=x.forwardRef(({className:t,value:e,placeholder:s,onValueChange:n,...d},a)=>{const[i,o]=x.useState(""),p=x.useRef(null);function j(c){const l=c.target.value;if(l.includes(",")){const g=l.split(","),y=Array.from(new Set(g));n([...e||[],...y.filter(u=>!!u&&!e?.includes(u)).map(u=>u.trim())||[]]),o("");return}o(l)}function h(c){["Enter","Tab"].includes(c.key)&&i?.trim()&&(c.preventDefault(),e?.includes(i)||f(),o("")),c.key==="Backspace"&&!i&&n(e?.slice(0,-1)||[])}function f(){i.trim()&&(n([...e||[],i]),o(""))}return r.jsxRuntimeExports.jsxs("div",{ref:a,className:N.cn("flex flex-wrap items-center gap-8 min-h-[36px]","border rounded border-gray-900-24 bg-white px-12 py-[4px]","hover:cursor-text","hover:shadow-field-hover","active:shadow-field-active","focus-visible:outline-none focus:shadow-field-active",t),onClick:()=>p.current?.focus(),...d,children:[r.jsxRuntimeExports.jsx(q,{value:e,onValueChange:n}),r.jsxRuntimeExports.jsx("input",{ref:p,className:"h-[26px] outline-none text-sm",type:"text",value:i,onChange:j,onKeyDown:h,style:{width:`${i.length+1}ch`},onBlur:()=>f()}),e?.length===0&&!i&&r.jsxRuntimeExports.jsx("div",{className:"text-gray-700 ml-[-2ch]",children:s})]})});m.displayName="TagInput";function q({value:t,onValueChange:e}){return r.jsxRuntimeExports.jsx(r.jsxRuntimeExports.Fragment,{children:t?.map((s,n)=>r.jsxRuntimeExports.jsxs(w.Badge,{className:"pl-0 gap-x-4 overflow-hidden",children:[r.jsxRuntimeExports.jsx(E.Button,{type:"button",className:"w-[26px] h-[26px] flex-shrink-0",size:"icon",intent:"secondary",onClick:()=>{e(t?.filter((d,a)=>a!==n)||[])},children:r.jsxRuntimeExports.jsx(R.LucideX,{className:"w-16"})}),r.jsxRuntimeExports.jsx("div",{className:"truncate",children:s})]},n))})}exports.TagInput=m;
2
2
  //# sourceMappingURL=index.cjs33.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs33.js","sources":["../src/Textarea/index.tsx"],"sourcesContent":["import * as React from 'react'\nimport { cn } from '../lib/utils'\n\nexport interface TextareaProps\n extends React.TextareaHTMLAttributes<HTMLTextAreaElement> {}\n\nconst Textarea = React.forwardRef<HTMLTextAreaElement, TextareaProps>(\n ({ className, ...props }, ref) => {\n return (\n <textarea\n className={cn(\n 'flex min-h-[60px] w-full rounded border border-gray-900-24 bg-white px-12 py-8 text-base',\n 'placeholder:text-gray-600',\n 'hover:shadow-field-hover',\n 'active:shadow-field-active',\n 'focus-visible:outline-none focus:shadow-field-active',\n 'disabled:cursor-not-allowed disabled:opacity-64 disabled:shadow-none',\n className\n )}\n ref={ref}\n {...props}\n />\n )\n }\n)\n\nTextarea.displayName = 'Textarea'\n\nexport { Textarea }\n"],"names":["Textarea","React","className","props","ref","jsx","cn"],"mappings":"+bAMMA,EAAWC,EAAM,WACrB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAA,EAASC,IAEtBC,EAAA,kBAAA,IAAC,WAAA,CACC,UAAWC,EAAA,GACT,2FACA,4BACA,2BACA,6BACA,uDACA,uEACAJ,CACF,EACA,IAAAE,EACC,GAAGD,CAAA,CAAA,CAIZ,EAEAH,EAAS,YAAc"}
1
+ {"version":3,"file":"index.cjs33.js","sources":["../src/TagInput/index.tsx"],"sourcesContent":["import { LucideX } from 'lucide-react'\nimport * as React from 'react'\nimport { Badge } from '../Badge'\nimport { Button } from '../Button'\nimport { cn } from '../lib/utils'\n\nexport type TagInputProps = React.HTMLAttributes<HTMLInputElement> & {\n value?: string[]\n onValueChange: (value: string[]) => void\n placeholder?: string\n}\n\nconst TagInput = React.forwardRef<HTMLInputElement, TagInputProps>(\n ({ className, value, placeholder, onValueChange, ...props }, ref) => {\n const [inputValue, setInputValue] = React.useState('')\n const inputRef = React.useRef<HTMLInputElement>(null)\n\n function handleChange(event: React.ChangeEvent<HTMLInputElement>) {\n const currentInputValue = event.target.value\n if (currentInputValue.includes(',')) {\n const currentValues = currentInputValue.split(',')\n //Remove duplicates\n const uniqueValues = Array.from(new Set(currentValues))\n\n onValueChange([\n ...(value || []),\n ...(uniqueValues\n .filter(inputValue => {\n //Remove empty values and already added values\n return Boolean(inputValue) && !value?.includes(inputValue)\n })\n .map(i => i.trim()) || [])\n ])\n setInputValue('')\n return\n }\n setInputValue(currentInputValue)\n }\n\n function handleKeyDown(event: React.KeyboardEvent<HTMLInputElement>) {\n if (['Enter', 'Tab'].includes(event.key)) {\n if (inputValue?.trim()) {\n event.preventDefault()\n if (!value?.includes(inputValue)) {\n addInputValue()\n }\n setInputValue('')\n }\n }\n\n if (event.key === 'Backspace' && !inputValue) {\n onValueChange(value?.slice(0, -1) || [])\n }\n }\n\n function addInputValue() {\n if (!inputValue.trim()) return\n onValueChange([...(value || []), inputValue])\n setInputValue('')\n }\n\n return (\n <div\n ref={ref}\n className={cn(\n 'flex flex-wrap items-center gap-8 min-h-[36px]',\n 'border rounded border-gray-900-24 bg-white px-12 py-[4px]',\n 'hover:cursor-text',\n 'hover:shadow-field-hover',\n 'active:shadow-field-active',\n 'focus-visible:outline-none focus:shadow-field-active',\n className\n )}\n onClick={() => inputRef.current?.focus()}\n {...props}\n >\n <TagList value={value} onValueChange={onValueChange} />\n <input\n ref={inputRef}\n className=\"h-[26px] outline-none text-sm\"\n type=\"text\"\n value={inputValue}\n onChange={handleChange}\n onKeyDown={handleKeyDown}\n style={{ width: `${inputValue.length + 1}ch` }}\n onBlur={() => addInputValue()}\n />\n {value?.length === 0 && !inputValue && (\n <div className=\"text-gray-700 ml-[-2ch]\">{placeholder}</div>\n )}\n </div>\n )\n }\n)\n\nTagInput.displayName = 'TagInput'\n\ntype TagListProps = React.HTMLAttributes<HTMLDivElement> & {\n value?: string[]\n onValueChange: (value: string[]) => void\n}\n\nfunction TagList({ value, onValueChange }: TagListProps) {\n return (\n <>\n {value?.map((tag, index) => (\n <Badge key={index} className=\"pl-0 gap-x-4 overflow-hidden\">\n <Button\n type=\"button\"\n className=\"w-[26px] h-[26px] flex-shrink-0\"\n size=\"icon\"\n intent=\"secondary\"\n onClick={() => {\n onValueChange(value?.filter((_, i) => i !== index) || [])\n }}\n >\n <LucideX className=\"w-16\" />\n </Button>\n <div className=\"truncate\">{tag}</div>\n </Badge>\n ))}\n </>\n )\n}\n\nexport { TagInput }\n"],"names":["TagInput","React","className","value","placeholder","onValueChange","props","ref","inputValue","setInputValue","inputRef","handleChange","event","currentInputValue","currentValues","uniqueValues","i","handleKeyDown","addInputValue","jsxs","cn","jsx","TagList","Fragment","tag","index","Badge","Button","_","LucideX"],"mappings":"mhBAYMA,EAAWC,EAAM,WACrB,CAAC,CAAE,UAAAC,EAAW,MAAAC,EAAO,YAAAC,EAAa,cAAAC,EAAe,GAAGC,CAAM,EAAGC,IAAQ,CACnE,KAAM,CAACC,EAAYC,CAAa,EAAIR,EAAM,SAAS,EAAE,EAC/CS,EAAWT,EAAM,OAAyB,IAAI,EAEpD,SAASU,EAAaC,EAA4C,CAC1D,MAAAC,EAAoBD,EAAM,OAAO,MACnC,GAAAC,EAAkB,SAAS,GAAG,EAAG,CAC7B,MAAAC,EAAgBD,EAAkB,MAAM,GAAG,EAE3CE,EAAe,MAAM,KAAK,IAAI,IAAID,CAAa,CAAC,EAExCT,EAAA,CACZ,GAAIF,GAAS,CAAC,EACd,GAAIY,EACD,OAAOP,GAEC,EAAQA,GAAe,CAACL,GAAO,SAASK,CAAU,CAC1D,EACA,IAAIQ,GAAKA,EAAE,KAAM,CAAA,GAAK,CAAC,CAAA,CAC3B,EACDP,EAAc,EAAE,EAChB,MACF,CACAA,EAAcI,CAAiB,CACjC,CAEA,SAASI,EAAcL,EAA8C,CAC/D,CAAC,QAAS,KAAK,EAAE,SAASA,EAAM,GAAG,GACjCJ,GAAY,SACdI,EAAM,eAAe,EAChBT,GAAO,SAASK,CAAU,GACfU,IAEhBT,EAAc,EAAE,GAIhBG,EAAM,MAAQ,aAAe,CAACJ,GAChCH,EAAcF,GAAO,MAAM,EAAG,EAAE,GAAK,CAAA,CAAE,CAE3C,CAEA,SAASe,GAAgB,CAClBV,EAAW,KAAK,IACrBH,EAAc,CAAC,GAAIF,GAAS,CAAA,EAAKK,CAAU,CAAC,EAC5CC,EAAc,EAAE,EAClB,CAGE,OAAAU,EAAA,kBAAA,KAAC,MAAA,CACC,IAAAZ,EACA,UAAWa,EAAA,GACT,iDACA,4DACA,oBACA,2BACA,6BACA,uDACAlB,CACF,EACA,QAAS,IAAMQ,EAAS,SAAS,MAAM,EACtC,GAAGJ,EAEJ,SAAA,CAACe,EAAAA,kBAAAA,IAAAC,EAAA,CAAQ,MAAAnB,EAAc,cAAAE,CAA8B,CAAA,EACrDgB,EAAA,kBAAA,IAAC,QAAA,CACC,IAAKX,EACL,UAAU,gCACV,KAAK,OACL,MAAOF,EACP,SAAUG,EACV,UAAWM,EACX,MAAO,CAAE,MAAO,GAAGT,EAAW,OAAS,CAAC,IAAK,EAC7C,OAAQ,IAAMU,EAAc,CAAA,CAC9B,EACCf,GAAO,SAAW,GAAK,CAACK,GACtBa,EAAA,kBAAA,IAAA,MAAA,CAAI,UAAU,0BAA2B,SAAYjB,CAAA,CAAA,CAAA,CAAA,CAAA,CAI9D,CACF,EAEAJ,EAAS,YAAc,WAOvB,SAASsB,EAAQ,CAAE,MAAAnB,EAAO,cAAAE,GAA+B,CAErD,OAAAgB,EAAA,kBAAA,IAAAE,EAAA,kBAAA,SAAA,CACG,YAAO,IAAI,CAACC,EAAKC,IAChBN,EAAA,kBAAA,KAACO,EAAkB,MAAA,CAAA,UAAU,+BAC3B,SAAA,CAAAL,EAAA,kBAAA,IAACM,EAAA,OAAA,CACC,KAAK,SACL,UAAU,kCACV,KAAK,OACL,OAAO,YACP,QAAS,IAAM,CACCtB,EAAAF,GAAO,OAAO,CAACyB,EAAGZ,IAAMA,IAAMS,CAAK,GAAK,CAAA,CAAE,CAC1D,EAEA,SAAAJ,EAAAA,kBAAAA,IAACQ,EAAAA,QAAQ,CAAA,UAAU,MAAO,CAAA,CAAA,CAC5B,EACCR,EAAA,kBAAA,IAAA,MAAA,CAAI,UAAU,WAAY,SAAIG,EAAA,CAAA,GAZrBC,CAaZ,CACD,CACH,CAAA,CAEJ"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index.cjs42.js"),g=require("@radix-ui/react-toast"),w=require("class-variance-authority"),c=require("lucide-react"),y=require("react"),o=require("./index.cjs43.js");function l(t){const s=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const i=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(s,e,i.get?i:{enumerable:!0,get:()=>t[e]})}}return s.default=t,Object.freeze(s)}const a=l(g),n=l(y),j=a.Provider,d=n.forwardRef(({className:t,...s},e)=>r.jsxRuntimeExports.jsx(a.Viewport,{ref:e,className:o.cn("fixed top-0 left-[50%] -translate-x-1/2 z-[100] flex max-h-screen w-full flex-col p-16 md:max-w-[520px]",t),...s}));d.displayName=a.Viewport.displayName;const T=w.cva("group pointer-events-auto relative flex w-full items-center justify-between space-x-8 overflow-hidden rounded border border-gray-900-8 p-16 pr-24 shadow-200 transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right data-[state=closed]:md:slide-out-to-top data-[state=closed]:md:slide-out-to-right-0 data-[state=open]:slide-in-from-top",{variants:{variant:{success:"success group bg-green-50",warning:"warning group bg-yellow-50",error:"error group bg-magenta-50"}},defaultVariants:{variant:"success"}}),p=n.forwardRef(({className:t,variant:s,...e},i)=>r.jsxRuntimeExports.jsx(a.Root,{ref:i,className:o.cn(T({variant:s}),t),...e}));p.displayName=a.Root.displayName;const u=n.forwardRef(({className:t,...s},e)=>r.jsxRuntimeExports.jsx(a.Action,{ref:e,className:o.cn("inline-flex h-32 shrink-0 items-center text-gray-900 justify-center rounded-md px-12 text-sm font-medium transition-colors hover:bg-gray-900-4 active:bg-gray-900-8 rounded focus:outline-none disabled:pointer-events-none disabled:opacity-64",t),...s}));u.displayName=a.Action.displayName;const m=n.forwardRef(({className:t,...s},e)=>r.jsxRuntimeExports.jsx(a.Close,{ref:e,className:o.cn("absolute right-4 top-4 p-4",t),"toast-close":"",...s,children:r.jsxRuntimeExports.jsx(c.X,{className:"h-16 w-16"})}));m.displayName=a.Close.displayName;const x=n.forwardRef(({className:t,...s},e)=>r.jsxRuntimeExports.jsx(a.Title,{ref:e,className:o.cn("text-sm text-gray-900 font-medium [&+div]:text-xs",t),...s}));x.displayName=a.Title.displayName;const f=n.forwardRef(({className:t,...s},e)=>r.jsxRuntimeExports.jsx(a.Description,{ref:e,className:o.cn("text-sm text-gray-800 opacity-100",t),...s}));f.displayName=a.Description.displayName;const v=({className:t,variant:s})=>{const e=o.cn("w-[20px] h-[20px]",t);switch(s){case"success":return r.jsxRuntimeExports.jsx(c.CheckIcon,{className:o.cn(e,"text-green-800")});case"warning":return r.jsxRuntimeExports.jsx(c.AlertTriangleIcon,{className:o.cn(e,"text-yellow-600")});case"error":return r.jsxRuntimeExports.jsx(c.AlertCircleIcon,{className:o.cn(e,"text-magenta-600")});default:return}};exports.Toast=p;exports.ToastAction=u;exports.ToastClose=m;exports.ToastDescription=f;exports.ToastIcon=v;exports.ToastProvider=j;exports.ToastTitle=x;exports.ToastViewport=d;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index.cjs43.js"),i=require("react"),s=require("./index.cjs44.js");function c(e){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const a=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,a.get?a:{enumerable:!0,get:()=>e[t]})}}return r.default=e,Object.freeze(r)}const l=c(i),o=l.forwardRef(({className:e,...r},t)=>n.jsxRuntimeExports.jsx("textarea",{className:s.cn("flex min-h-[60px] w-full rounded border border-gray-900-24 bg-white px-12 py-8 text-base","placeholder:text-gray-600","hover:shadow-field-hover","active:shadow-field-active","focus-visible:outline-none focus:shadow-field-active","disabled:cursor-not-allowed disabled:opacity-64 disabled:shadow-none",e),ref:t,...r}));o.displayName="Textarea";exports.Textarea=o;
2
2
  //# sourceMappingURL=index.cjs34.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs34.js","sources":["../src/Toast/Toast.tsx"],"sourcesContent":["'use client'\n\nimport * as ToastPrimitives from '@radix-ui/react-toast'\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport { X } from 'lucide-react'\nimport { CheckIcon, AlertTriangleIcon, AlertCircleIcon } from 'lucide-react'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst ToastProvider = ToastPrimitives.Provider\n\nconst ToastViewport = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Viewport>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Viewport>\n>(({ className, ...props }, ref) => (\n <ToastPrimitives.Viewport\n ref={ref}\n className={cn(\n 'fixed top-0 left-[50%] -translate-x-1/2 z-[100] flex max-h-screen w-full flex-col p-16 md:max-w-[520px]',\n className\n )}\n {...props}\n />\n))\nToastViewport.displayName = ToastPrimitives.Viewport.displayName\n\nconst toastVariants = cva(\n 'group pointer-events-auto relative flex w-full items-center justify-between space-x-8 overflow-hidden rounded border border-gray-900-8 p-16 pr-24 shadow-200 transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right data-[state=closed]:md:slide-out-to-top data-[state=closed]:md:slide-out-to-right-0 data-[state=open]:slide-in-from-top',\n {\n variants: {\n variant: {\n success: 'success group bg-green-50',\n warning: 'warning group bg-yellow-50',\n error: 'error group bg-magenta-50'\n }\n },\n defaultVariants: {\n variant: 'success'\n }\n }\n)\n\nconst Toast = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Root>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Root> &\n VariantProps<typeof toastVariants>\n>(({ className, variant, ...props }, ref) => {\n return (\n <ToastPrimitives.Root\n ref={ref}\n className={cn(toastVariants({ variant }), className)}\n {...props}\n />\n )\n})\nToast.displayName = ToastPrimitives.Root.displayName\n\nconst ToastAction = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Action>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Action>\n>(({ className, ...props }, ref) => (\n <ToastPrimitives.Action\n ref={ref}\n className={cn(\n 'inline-flex h-32 shrink-0 items-center text-gray-900 justify-center rounded-md px-12 text-sm font-medium transition-colors hover:bg-gray-900-4 active:bg-gray-900-8 rounded focus:outline-none disabled:pointer-events-none disabled:opacity-64',\n className\n )}\n {...props}\n />\n))\nToastAction.displayName = ToastPrimitives.Action.displayName\n\nconst ToastClose = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Close>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Close>\n>(({ className, ...props }, ref) => (\n <ToastPrimitives.Close\n ref={ref}\n className={cn('absolute right-4 top-4 p-4', className)}\n toast-close=\"\"\n {...props}\n >\n <X className=\"h-16 w-16\" />\n </ToastPrimitives.Close>\n))\nToastClose.displayName = ToastPrimitives.Close.displayName\n\nconst ToastTitle = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Title>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Title>\n>(({ className, ...props }, ref) => (\n <ToastPrimitives.Title\n ref={ref}\n className={cn(\n 'text-sm text-gray-900 font-medium [&+div]:text-xs',\n className\n )}\n {...props}\n />\n))\nToastTitle.displayName = ToastPrimitives.Title.displayName\n\nconst ToastDescription = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Description>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Description>\n>(({ className, ...props }, ref) => (\n <ToastPrimitives.Description\n ref={ref}\n className={cn('text-sm text-gray-800 opacity-100', className)}\n {...props}\n />\n))\nToastDescription.displayName = ToastPrimitives.Description.displayName\n\nconst ToastIcon = ({\n className,\n variant\n}: React.HTMLAttributes<SVGElement> & VariantProps<typeof toastVariants>) => {\n const iconClassName = cn('w-[20px] h-[20px]', className)\n\n switch (variant) {\n case 'success':\n return <CheckIcon className={cn(iconClassName, 'text-green-800')} />\n case 'warning':\n return (\n <AlertTriangleIcon className={cn(iconClassName, 'text-yellow-600')} />\n )\n case 'error':\n return (\n <AlertCircleIcon className={cn(iconClassName, 'text-magenta-600')} />\n )\n default:\n return undefined\n }\n}\n\ntype ToastProps = React.ComponentPropsWithoutRef<typeof Toast>\n\ntype ToastActionElement = React.ReactElement<typeof ToastAction>\n\nexport {\n type ToastProps,\n type ToastActionElement,\n ToastProvider,\n ToastViewport,\n Toast,\n ToastTitle,\n ToastDescription,\n ToastClose,\n ToastAction,\n ToastIcon\n}\n"],"names":["ToastProvider","ToastPrimitives","ToastViewport","React","className","props","ref","jsx","cn","toastVariants","cva","Toast","variant","ToastAction","ToastClose","X","ToastTitle","ToastDescription","ToastIcon","iconClassName","CheckIcon","AlertTriangleIcon","AlertCircleIcon"],"mappings":"yiBASMA,EAAgBC,EAAgB,SAEhCC,EAAgBC,EAAM,WAG1B,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAgB,SAAhB,CACC,IAAAK,EACA,UAAWE,EAAA,GACT,0GACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDH,EAAc,YAAcD,EAAgB,SAAS,YAErD,MAAMQ,EAAgBC,EAAA,IACpB,yoBACA,CACE,SAAU,CACR,QAAS,CACP,QAAS,4BACT,QAAS,6BACT,MAAO,2BACT,CACF,EACA,gBAAiB,CACf,QAAS,SACX,CACF,CACF,EAEMC,EAAQR,EAAM,WAIlB,CAAC,CAAE,UAAAC,EAAW,QAAAQ,EAAS,GAAGP,CAAM,EAAGC,IAEjCC,EAAA,kBAAA,IAACN,EAAgB,KAAhB,CACC,IAAAK,EACA,UAAWE,EAAG,GAAAC,EAAc,CAAE,QAAAG,CAAS,CAAA,EAAGR,CAAS,EAClD,GAAGC,CAAA,CAAA,CAGT,EACDM,EAAM,YAAcV,EAAgB,KAAK,YAEnC,MAAAY,EAAcV,EAAM,WAGxB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAgB,OAAhB,CACC,IAAAK,EACA,UAAWE,EAAA,GACT,kPACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDQ,EAAY,YAAcZ,EAAgB,OAAO,YAE3C,MAAAa,EAAaX,EAAM,WAGvB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAgB,MAAhB,CACC,IAAAK,EACA,UAAWE,EAAAA,GAAG,6BAA8BJ,CAAS,EACrD,cAAY,GACX,GAAGC,EAEJ,SAAAE,EAAAA,kBAAAA,IAACQ,EAAAA,EAAE,CAAA,UAAU,WAAY,CAAA,CAAA,CAC3B,CACD,EACDD,EAAW,YAAcb,EAAgB,MAAM,YAEzC,MAAAe,EAAab,EAAM,WAGvB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAgB,MAAhB,CACC,IAAAK,EACA,UAAWE,EAAA,GACT,oDACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDW,EAAW,YAAcf,EAAgB,MAAM,YAEzC,MAAAgB,EAAmBd,EAAM,WAG7B,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAgB,YAAhB,CACC,IAAAK,EACA,UAAWE,EAAAA,GAAG,oCAAqCJ,CAAS,EAC3D,GAAGC,CAAA,CACN,CACD,EACDY,EAAiB,YAAchB,EAAgB,YAAY,YAE3D,MAAMiB,EAAY,CAAC,CACjB,UAAAd,EACA,QAAAQ,CACF,IAA6E,CACrE,MAAAO,EAAgBX,EAAAA,GAAG,oBAAqBJ,CAAS,EAEvD,OAAQQ,EAAS,CACf,IAAK,UACH,+BAAQQ,EAAU,UAAA,CAAA,UAAWZ,EAAG,GAAAW,EAAe,gBAAgB,CAAG,CAAA,EACpE,IAAK,UACH,+BACGE,EAAkB,kBAAA,CAAA,UAAWb,EAAG,GAAAW,EAAe,iBAAiB,CAAG,CAAA,EAExE,IAAK,QACH,+BACGG,EAAgB,gBAAA,CAAA,UAAWd,EAAG,GAAAW,EAAe,kBAAkB,CAAG,CAAA,EAEvE,QACS,MACX,CACF"}
1
+ {"version":3,"file":"index.cjs34.js","sources":["../src/Textarea/index.tsx"],"sourcesContent":["import * as React from 'react'\nimport { cn } from '../lib/utils'\n\nexport interface TextareaProps\n extends React.TextareaHTMLAttributes<HTMLTextAreaElement> {}\n\nconst Textarea = React.forwardRef<HTMLTextAreaElement, TextareaProps>(\n ({ className, ...props }, ref) => {\n return (\n <textarea\n className={cn(\n 'flex min-h-[60px] w-full rounded border border-gray-900-24 bg-white px-12 py-8 text-base',\n 'placeholder:text-gray-600',\n 'hover:shadow-field-hover',\n 'active:shadow-field-active',\n 'focus-visible:outline-none focus:shadow-field-active',\n 'disabled:cursor-not-allowed disabled:opacity-64 disabled:shadow-none',\n className\n )}\n ref={ref}\n {...props}\n />\n )\n }\n)\n\nTextarea.displayName = 'Textarea'\n\nexport { Textarea }\n"],"names":["Textarea","React","className","props","ref","jsx","cn"],"mappings":"+bAMMA,EAAWC,EAAM,WACrB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAA,EAASC,IAEtBC,EAAA,kBAAA,IAAC,WAAA,CACC,UAAWC,EAAA,GACT,2FACA,4BACA,2BACA,6BACA,uDACA,uEACAJ,CACF,EACA,IAAAE,EACC,GAAGD,CAAA,CAAA,CAIZ,EAEAH,EAAS,YAAc"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./index.cjs42.js"),t=require("./index.cjs34.js"),c=require("./index.cjs36.js"),j=5e3;function m(){const{toasts:n}=c.useToast();return s.jsxRuntimeExports.jsxs(t.ToastProvider,{children:[n.map(function({variant:e,id:i,title:o,description:r,action:x,hideIcon:u,...a}){return s.jsxRuntimeExports.jsxs(t.Toast,{variant:e,duration:j,...a,children:[s.jsxRuntimeExports.jsxs("div",{className:"flex items-center",children:[!u&&s.jsxRuntimeExports.jsx(t.ToastIcon,{variant:e,className:"mr-12 flex-shrink-0"}),s.jsxRuntimeExports.jsxs("div",{className:"grid",children:[o&&s.jsxRuntimeExports.jsx(t.ToastTitle,{children:o}),r&&s.jsxRuntimeExports.jsx(t.ToastDescription,{children:r})]})]}),x,s.jsxRuntimeExports.jsx(t.ToastClose,{})]},i)}),s.jsxRuntimeExports.jsx(t.ToastViewport,{})]})}exports.Toaster=m;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index.cjs43.js"),g=require("@radix-ui/react-toast"),w=require("class-variance-authority"),c=require("lucide-react"),y=require("react"),o=require("./index.cjs44.js");function l(t){const s=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const i=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(s,e,i.get?i:{enumerable:!0,get:()=>t[e]})}}return s.default=t,Object.freeze(s)}const a=l(g),n=l(y),j=a.Provider,d=n.forwardRef(({className:t,...s},e)=>r.jsxRuntimeExports.jsx(a.Viewport,{ref:e,className:o.cn("fixed top-0 left-[50%] -translate-x-1/2 z-[100] flex max-h-screen w-full flex-col p-16 md:max-w-[520px]",t),...s}));d.displayName=a.Viewport.displayName;const T=w.cva("group pointer-events-auto relative flex w-full items-center justify-between space-x-8 overflow-hidden rounded border border-gray-900-8 p-16 pr-24 shadow-200 transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right data-[state=closed]:md:slide-out-to-top data-[state=closed]:md:slide-out-to-right-0 data-[state=open]:slide-in-from-top",{variants:{variant:{success:"success group bg-green-50",warning:"warning group bg-yellow-50",error:"error group bg-magenta-50"}},defaultVariants:{variant:"success"}}),p=n.forwardRef(({className:t,variant:s,...e},i)=>r.jsxRuntimeExports.jsx(a.Root,{ref:i,className:o.cn(T({variant:s}),t),...e}));p.displayName=a.Root.displayName;const u=n.forwardRef(({className:t,...s},e)=>r.jsxRuntimeExports.jsx(a.Action,{ref:e,className:o.cn("inline-flex h-32 shrink-0 items-center text-gray-900 justify-center rounded-md px-12 text-sm font-medium transition-colors hover:bg-gray-900-4 active:bg-gray-900-8 rounded focus:outline-none disabled:pointer-events-none disabled:opacity-64",t),...s}));u.displayName=a.Action.displayName;const m=n.forwardRef(({className:t,...s},e)=>r.jsxRuntimeExports.jsx(a.Close,{ref:e,className:o.cn("absolute right-4 top-4 p-4",t),"toast-close":"",...s,children:r.jsxRuntimeExports.jsx(c.X,{className:"h-16 w-16"})}));m.displayName=a.Close.displayName;const x=n.forwardRef(({className:t,...s},e)=>r.jsxRuntimeExports.jsx(a.Title,{ref:e,className:o.cn("text-sm text-gray-900 font-medium [&+div]:text-xs",t),...s}));x.displayName=a.Title.displayName;const f=n.forwardRef(({className:t,...s},e)=>r.jsxRuntimeExports.jsx(a.Description,{ref:e,className:o.cn("text-sm text-gray-800 opacity-100",t),...s}));f.displayName=a.Description.displayName;const v=({className:t,variant:s})=>{const e=o.cn("w-[20px] h-[20px]",t);switch(s){case"success":return r.jsxRuntimeExports.jsx(c.CheckIcon,{className:o.cn(e,"text-green-800")});case"warning":return r.jsxRuntimeExports.jsx(c.AlertTriangleIcon,{className:o.cn(e,"text-yellow-600")});case"error":return r.jsxRuntimeExports.jsx(c.AlertCircleIcon,{className:o.cn(e,"text-magenta-600")});default:return}};exports.Toast=p;exports.ToastAction=u;exports.ToastClose=m;exports.ToastDescription=f;exports.ToastIcon=v;exports.ToastProvider=j;exports.ToastTitle=x;exports.ToastViewport=d;
2
2
  //# sourceMappingURL=index.cjs35.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs35.js","sources":["../src/Toast/Toaster.tsx"],"sourcesContent":["'use client'\n\nimport {\n Toast,\n ToastClose,\n ToastDescription,\n ToastIcon,\n ToastProvider,\n ToastTitle,\n ToastViewport\n} from './Toast'\nimport { useToast } from './hooks'\n\nconst DEFAULT_TOAST_DURATION = 5000\n\nexport function Toaster() {\n const { toasts } = useToast()\n\n return (\n <ToastProvider>\n {toasts.map(function ({\n variant,\n id,\n title,\n description,\n action,\n hideIcon,\n ...props\n }) {\n return (\n <Toast\n key={id}\n variant={variant}\n duration={DEFAULT_TOAST_DURATION}\n {...props}\n >\n <div className=\"flex items-center\">\n {!hideIcon && (\n <ToastIcon variant={variant} className=\"mr-12 flex-shrink-0\" />\n )}\n <div className=\"grid\">\n {title && <ToastTitle>{title}</ToastTitle>}\n {description && (\n <ToastDescription>{description}</ToastDescription>\n )}\n </div>\n </div>\n {action}\n <ToastClose />\n </Toast>\n )\n })}\n <ToastViewport />\n </ToastProvider>\n )\n}\n"],"names":["DEFAULT_TOAST_DURATION","Toaster","toasts","useToast","ToastProvider","variant","id","title","description","action","hideIcon","props","jsxs","Toast","jsx","ToastIcon","ToastTitle","ToastDescription","ToastClose","ToastViewport"],"mappings":"gLAaMA,EAAyB,IAExB,SAASC,GAAU,CAClB,KAAA,CAAE,OAAAC,GAAWC,EAAAA,WAEnB,gCACGC,gBACE,CAAA,SAAA,CAAAF,EAAO,IAAI,SAAU,CACpB,QAAAG,EACA,GAAAC,EACA,MAAAC,EACA,YAAAC,EACA,OAAAC,EACA,SAAAC,EACA,GAAGC,CAAA,EACF,CAEC,OAAAC,EAAA,kBAAA,KAACC,EAAA,MAAA,CAEC,QAAAR,EACA,SAAUL,EACT,GAAGW,EAEJ,SAAA,CAACC,EAAAA,kBAAAA,KAAA,MAAA,CAAI,UAAU,oBACZ,SAAA,CAAA,CAACF,GACAI,EAAAA,kBAAAA,IAACC,EAAU,UAAA,CAAA,QAAAV,EAAkB,UAAU,sBAAsB,EAE/DO,EAAAA,kBAAAA,KAAC,MAAI,CAAA,UAAU,OACZ,SAAA,CAASL,GAAAO,EAAAA,kBAAAA,IAACE,EAAAA,YAAY,SAAMT,CAAA,CAAA,EAC5BC,GACEM,EAAAA,kBAAAA,IAAAG,EAAAA,iBAAA,CAAkB,SAAYT,CAAA,CAAA,CAAA,EAEnC,CAAA,EACF,EACCC,0BACAS,EAAW,WAAA,EAAA,CAAA,CAAA,EAjBPZ,CAAA,CAkBP,CAEH,0BACAa,EAAc,cAAA,EAAA,CACjB,CAAA,CAAA,CAEJ"}
1
+ {"version":3,"file":"index.cjs35.js","sources":["../src/Toast/Toast.tsx"],"sourcesContent":["'use client'\n\nimport * as ToastPrimitives from '@radix-ui/react-toast'\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport { X } from 'lucide-react'\nimport { CheckIcon, AlertTriangleIcon, AlertCircleIcon } from 'lucide-react'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst ToastProvider = ToastPrimitives.Provider\n\nconst ToastViewport = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Viewport>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Viewport>\n>(({ className, ...props }, ref) => (\n <ToastPrimitives.Viewport\n ref={ref}\n className={cn(\n 'fixed top-0 left-[50%] -translate-x-1/2 z-[100] flex max-h-screen w-full flex-col p-16 md:max-w-[520px]',\n className\n )}\n {...props}\n />\n))\nToastViewport.displayName = ToastPrimitives.Viewport.displayName\n\nconst toastVariants = cva(\n 'group pointer-events-auto relative flex w-full items-center justify-between space-x-8 overflow-hidden rounded border border-gray-900-8 p-16 pr-24 shadow-200 transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right data-[state=closed]:md:slide-out-to-top data-[state=closed]:md:slide-out-to-right-0 data-[state=open]:slide-in-from-top',\n {\n variants: {\n variant: {\n success: 'success group bg-green-50',\n warning: 'warning group bg-yellow-50',\n error: 'error group bg-magenta-50'\n }\n },\n defaultVariants: {\n variant: 'success'\n }\n }\n)\n\nconst Toast = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Root>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Root> &\n VariantProps<typeof toastVariants>\n>(({ className, variant, ...props }, ref) => {\n return (\n <ToastPrimitives.Root\n ref={ref}\n className={cn(toastVariants({ variant }), className)}\n {...props}\n />\n )\n})\nToast.displayName = ToastPrimitives.Root.displayName\n\nconst ToastAction = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Action>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Action>\n>(({ className, ...props }, ref) => (\n <ToastPrimitives.Action\n ref={ref}\n className={cn(\n 'inline-flex h-32 shrink-0 items-center text-gray-900 justify-center rounded-md px-12 text-sm font-medium transition-colors hover:bg-gray-900-4 active:bg-gray-900-8 rounded focus:outline-none disabled:pointer-events-none disabled:opacity-64',\n className\n )}\n {...props}\n />\n))\nToastAction.displayName = ToastPrimitives.Action.displayName\n\nconst ToastClose = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Close>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Close>\n>(({ className, ...props }, ref) => (\n <ToastPrimitives.Close\n ref={ref}\n className={cn('absolute right-4 top-4 p-4', className)}\n toast-close=\"\"\n {...props}\n >\n <X className=\"h-16 w-16\" />\n </ToastPrimitives.Close>\n))\nToastClose.displayName = ToastPrimitives.Close.displayName\n\nconst ToastTitle = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Title>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Title>\n>(({ className, ...props }, ref) => (\n <ToastPrimitives.Title\n ref={ref}\n className={cn(\n 'text-sm text-gray-900 font-medium [&+div]:text-xs',\n className\n )}\n {...props}\n />\n))\nToastTitle.displayName = ToastPrimitives.Title.displayName\n\nconst ToastDescription = React.forwardRef<\n React.ElementRef<typeof ToastPrimitives.Description>,\n React.ComponentPropsWithoutRef<typeof ToastPrimitives.Description>\n>(({ className, ...props }, ref) => (\n <ToastPrimitives.Description\n ref={ref}\n className={cn('text-sm text-gray-800 opacity-100', className)}\n {...props}\n />\n))\nToastDescription.displayName = ToastPrimitives.Description.displayName\n\nconst ToastIcon = ({\n className,\n variant\n}: React.HTMLAttributes<SVGElement> & VariantProps<typeof toastVariants>) => {\n const iconClassName = cn('w-[20px] h-[20px]', className)\n\n switch (variant) {\n case 'success':\n return <CheckIcon className={cn(iconClassName, 'text-green-800')} />\n case 'warning':\n return (\n <AlertTriangleIcon className={cn(iconClassName, 'text-yellow-600')} />\n )\n case 'error':\n return (\n <AlertCircleIcon className={cn(iconClassName, 'text-magenta-600')} />\n )\n default:\n return undefined\n }\n}\n\ntype ToastProps = React.ComponentPropsWithoutRef<typeof Toast>\n\ntype ToastActionElement = React.ReactElement<typeof ToastAction>\n\nexport {\n type ToastProps,\n type ToastActionElement,\n ToastProvider,\n ToastViewport,\n Toast,\n ToastTitle,\n ToastDescription,\n ToastClose,\n ToastAction,\n ToastIcon\n}\n"],"names":["ToastProvider","ToastPrimitives","ToastViewport","React","className","props","ref","jsx","cn","toastVariants","cva","Toast","variant","ToastAction","ToastClose","X","ToastTitle","ToastDescription","ToastIcon","iconClassName","CheckIcon","AlertTriangleIcon","AlertCircleIcon"],"mappings":"yiBASMA,EAAgBC,EAAgB,SAEhCC,EAAgBC,EAAM,WAG1B,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAgB,SAAhB,CACC,IAAAK,EACA,UAAWE,EAAA,GACT,0GACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDH,EAAc,YAAcD,EAAgB,SAAS,YAErD,MAAMQ,EAAgBC,EAAA,IACpB,yoBACA,CACE,SAAU,CACR,QAAS,CACP,QAAS,4BACT,QAAS,6BACT,MAAO,2BACT,CACF,EACA,gBAAiB,CACf,QAAS,SACX,CACF,CACF,EAEMC,EAAQR,EAAM,WAIlB,CAAC,CAAE,UAAAC,EAAW,QAAAQ,EAAS,GAAGP,CAAM,EAAGC,IAEjCC,EAAA,kBAAA,IAACN,EAAgB,KAAhB,CACC,IAAAK,EACA,UAAWE,EAAG,GAAAC,EAAc,CAAE,QAAAG,CAAS,CAAA,EAAGR,CAAS,EAClD,GAAGC,CAAA,CAAA,CAGT,EACDM,EAAM,YAAcV,EAAgB,KAAK,YAEnC,MAAAY,EAAcV,EAAM,WAGxB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAgB,OAAhB,CACC,IAAAK,EACA,UAAWE,EAAA,GACT,kPACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDQ,EAAY,YAAcZ,EAAgB,OAAO,YAE3C,MAAAa,EAAaX,EAAM,WAGvB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAgB,MAAhB,CACC,IAAAK,EACA,UAAWE,EAAAA,GAAG,6BAA8BJ,CAAS,EACrD,cAAY,GACX,GAAGC,EAEJ,SAAAE,EAAAA,kBAAAA,IAACQ,EAAAA,EAAE,CAAA,UAAU,WAAY,CAAA,CAAA,CAC3B,CACD,EACDD,EAAW,YAAcb,EAAgB,MAAM,YAEzC,MAAAe,EAAab,EAAM,WAGvB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAgB,MAAhB,CACC,IAAAK,EACA,UAAWE,EAAA,GACT,oDACAJ,CACF,EACC,GAAGC,CAAA,CACN,CACD,EACDW,EAAW,YAAcf,EAAgB,MAAM,YAEzC,MAAAgB,EAAmBd,EAAM,WAG7B,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACN,EAAgB,YAAhB,CACC,IAAAK,EACA,UAAWE,EAAAA,GAAG,oCAAqCJ,CAAS,EAC3D,GAAGC,CAAA,CACN,CACD,EACDY,EAAiB,YAAchB,EAAgB,YAAY,YAE3D,MAAMiB,EAAY,CAAC,CACjB,UAAAd,EACA,QAAAQ,CACF,IAA6E,CACrE,MAAAO,EAAgBX,EAAAA,GAAG,oBAAqBJ,CAAS,EAEvD,OAAQQ,EAAS,CACf,IAAK,UACH,+BAAQQ,EAAU,UAAA,CAAA,UAAWZ,EAAG,GAAAW,EAAe,gBAAgB,CAAG,CAAA,EACpE,IAAK,UACH,+BACGE,EAAkB,kBAAA,CAAA,UAAWb,EAAG,GAAAW,EAAe,iBAAiB,CAAG,CAAA,EAExE,IAAK,QACH,+BACGG,EAAgB,gBAAA,CAAA,UAAWd,EAAG,GAAAW,EAAe,kBAAkB,CAAG,CAAA,EAEvE,QACS,MACX,CACF"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("react");function O(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const s in t)if(s!=="default"){const o=Object.getOwnPropertyDescriptor(t,s);Object.defineProperty(e,s,o.get?o:{enumerable:!0,get:()=>t[s]})}}return e.default=t,Object.freeze(e)}const T=O(p),l=1,A=5e3;let a=0;function _(){return a=(a+1)%Number.MAX_SAFE_INTEGER,a.toString()}const i=new Map,S=t=>{if(i.has(t))return;const e=setTimeout(()=>{i.delete(t),n({type:"REMOVE_TOAST",toastId:t})},A);i.set(t,e)},d=(t,e)=>{switch(e.type){case"ADD_TOAST":return{...t,toasts:[e.toast,...t.toasts].slice(0,l)};case"UPDATE_TOAST":return{...t,toasts:t.toasts.map(s=>s.id===e.toast.id?{...s,...e.toast}:s)};case"DISMISS_TOAST":{const{toastId:s}=e;return s?S(s):t.toasts.forEach(o=>{S(o.id)}),{...t,toasts:t.toasts.map(o=>o.id===s||s===void 0?{...o,open:!1}:o)}}case"REMOVE_TOAST":return e.toastId===void 0?{...t,toasts:[]}:{...t,toasts:t.toasts.filter(s=>s.id!==e.toastId)}}},r=[];let u={toasts:[]};function n(t){u=d(u,t),r.forEach(e=>{e(u)})}function f({...t}){const e=_(),s=c=>n({type:"UPDATE_TOAST",toast:{...c,id:e}}),o=()=>n({type:"DISMISS_TOAST",toastId:e});return n({type:"ADD_TOAST",toast:{...t,id:e,open:!0,onOpenChange:c=>{c||o()}}}),{id:e,dismiss:o,update:s}}function m(){const[t,e]=T.useState(u);return T.useEffect(()=>(r.push(e),()=>{const s=r.indexOf(e);s>-1&&r.splice(s,1)}),[t]),{...t,toast:f,dismiss:s=>n({type:"DISMISS_TOAST",toastId:s})}}exports.reducer=d;exports.toast=f;exports.useToast=m;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./index.cjs43.js"),t=require("./index.cjs35.js"),c=require("./index.cjs37.js"),j=5e3;function m(){const{toasts:n}=c.useToast();return s.jsxRuntimeExports.jsxs(t.ToastProvider,{children:[n.map(function({variant:e,id:i,title:o,description:r,action:x,hideIcon:u,...a}){return s.jsxRuntimeExports.jsxs(t.Toast,{variant:e,duration:j,...a,children:[s.jsxRuntimeExports.jsxs("div",{className:"flex items-center",children:[!u&&s.jsxRuntimeExports.jsx(t.ToastIcon,{variant:e,className:"mr-12 flex-shrink-0"}),s.jsxRuntimeExports.jsxs("div",{className:"grid",children:[o&&s.jsxRuntimeExports.jsx(t.ToastTitle,{children:o}),r&&s.jsxRuntimeExports.jsx(t.ToastDescription,{children:r})]})]}),x,s.jsxRuntimeExports.jsx(t.ToastClose,{})]},i)}),s.jsxRuntimeExports.jsx(t.ToastViewport,{})]})}exports.Toaster=m;
2
2
  //# sourceMappingURL=index.cjs36.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs36.js","sources":["../src/Toast/hooks.tsx"],"sourcesContent":["'use client'\n\n// Inspired by react-hot-toast library\nimport * as React from 'react'\nimport type { ToastActionElement, ToastProps } from './Toast'\n\nconst TOAST_LIMIT = 1\nconst TOAST_REMOVE_DELAY = 5000\n\ntype ToasterToast = ToastProps & {\n id: string\n title?: React.ReactNode\n description?: React.ReactNode\n action?: ToastActionElement\n hideIcon?: boolean\n}\n\nconst actionTypes = {\n ADD_TOAST: 'ADD_TOAST',\n UPDATE_TOAST: 'UPDATE_TOAST',\n DISMISS_TOAST: 'DISMISS_TOAST',\n REMOVE_TOAST: 'REMOVE_TOAST'\n} as const\n\nlet count = 0\n\nfunction genId() {\n count = (count + 1) % Number.MAX_SAFE_INTEGER\n return count.toString()\n}\n\ntype ActionType = typeof actionTypes\n\ntype Action =\n | {\n type: ActionType['ADD_TOAST']\n toast: ToasterToast\n }\n | {\n type: ActionType['UPDATE_TOAST']\n toast: Partial<ToasterToast>\n }\n | {\n type: ActionType['DISMISS_TOAST']\n toastId?: ToasterToast['id']\n }\n | {\n type: ActionType['REMOVE_TOAST']\n toastId?: ToasterToast['id']\n }\n\ninterface State {\n toasts: ToasterToast[]\n}\n\nconst toastTimeouts = new Map<string, ReturnType<typeof setTimeout>>()\n\nconst addToRemoveQueue = (toastId: string) => {\n if (toastTimeouts.has(toastId)) {\n return\n }\n\n const timeout = setTimeout(() => {\n toastTimeouts.delete(toastId)\n dispatch({\n type: 'REMOVE_TOAST',\n toastId: toastId\n })\n }, TOAST_REMOVE_DELAY)\n\n toastTimeouts.set(toastId, timeout)\n}\n\nexport const reducer = (state: State, action: Action): State => {\n switch (action.type) {\n case 'ADD_TOAST':\n return {\n ...state,\n toasts: [action.toast, ...state.toasts].slice(0, TOAST_LIMIT)\n }\n\n case 'UPDATE_TOAST':\n return {\n ...state,\n toasts: state.toasts.map(t =>\n t.id === action.toast.id ? { ...t, ...action.toast } : t\n )\n }\n\n case 'DISMISS_TOAST': {\n const { toastId } = action\n\n // ! Side effects ! - This could be extracted into a dismissToast() action,\n // but I'll keep it here for simplicity\n if (toastId) {\n addToRemoveQueue(toastId)\n } else {\n state.toasts.forEach(toast => {\n addToRemoveQueue(toast.id)\n })\n }\n\n return {\n ...state,\n toasts: state.toasts.map(t =>\n t.id === toastId || toastId === undefined\n ? {\n ...t,\n open: false\n }\n : t\n )\n }\n }\n case 'REMOVE_TOAST':\n if (action.toastId === undefined) {\n return {\n ...state,\n toasts: []\n }\n }\n return {\n ...state,\n toasts: state.toasts.filter(t => t.id !== action.toastId)\n }\n }\n}\n\nconst listeners: Array<(state: State) => void> = []\n\nlet memoryState: State = { toasts: [] }\n\nfunction dispatch(action: Action) {\n memoryState = reducer(memoryState, action)\n listeners.forEach(listener => {\n listener(memoryState)\n })\n}\n\ntype Toast = Omit<ToasterToast, 'id'>\n\nfunction toast({ ...props }: Toast) {\n const id = genId()\n\n const update = (props: ToasterToast) =>\n dispatch({\n type: 'UPDATE_TOAST',\n toast: { ...props, id }\n })\n const dismiss = () => dispatch({ type: 'DISMISS_TOAST', toastId: id })\n\n dispatch({\n type: 'ADD_TOAST',\n toast: {\n ...props,\n id,\n open: true,\n onOpenChange: (open: boolean) => {\n if (!open) dismiss()\n }\n }\n })\n\n return {\n id: id,\n dismiss,\n update\n }\n}\n\nfunction useToast() {\n const [state, setState] = React.useState<State>(memoryState)\n\n React.useEffect(() => {\n listeners.push(setState)\n return () => {\n const index = listeners.indexOf(setState)\n if (index > -1) {\n listeners.splice(index, 1)\n }\n }\n }, [state])\n\n return {\n ...state,\n toast,\n dismiss: (toastId?: string) => dispatch({ type: 'DISMISS_TOAST', toastId })\n }\n}\n\nexport { useToast, toast }\n"],"names":["TOAST_LIMIT","TOAST_REMOVE_DELAY","count","genId","toastTimeouts","addToRemoveQueue","toastId","timeout","dispatch","reducer","state","action","t","toast","listeners","memoryState","listener","props","id","update","dismiss","open","useToast","setState","React","index"],"mappings":"mYAMMA,EAAc,EACdC,EAAqB,IAiB3B,IAAIC,EAAQ,EAEZ,SAASC,GAAQ,CACN,OAAAD,GAAAA,EAAQ,GAAK,OAAO,iBACtBA,EAAM,UACf,CA0BA,MAAME,MAAoB,IAEpBC,EAAoBC,GAAoB,CACxC,GAAAF,EAAc,IAAIE,CAAO,EAC3B,OAGI,MAAAC,EAAU,WAAW,IAAM,CAC/BH,EAAc,OAAOE,CAAO,EACnBE,EAAA,CACP,KAAM,eACN,QAAAF,CAAA,CACD,GACAL,CAAkB,EAEPG,EAAA,IAAIE,EAASC,CAAO,CACpC,EAEaE,EAAU,CAACC,EAAcC,IAA0B,CAC9D,OAAQA,EAAO,KAAM,CACnB,IAAK,YACI,MAAA,CACL,GAAGD,EACH,OAAQ,CAACC,EAAO,MAAO,GAAGD,EAAM,MAAM,EAAE,MAAM,EAAGV,CAAW,CAAA,EAGhE,IAAK,eACI,MAAA,CACL,GAAGU,EACH,OAAQA,EAAM,OAAO,IACnBE,GAAAA,EAAE,KAAOD,EAAO,MAAM,GAAK,CAAE,GAAGC,EAAG,GAAGD,EAAO,KAAU,EAAAC,CACzD,CAAA,EAGJ,IAAK,gBAAiB,CACd,KAAA,CAAE,QAAAN,CAAY,EAAAK,EAIpB,OAAIL,EACFD,EAAiBC,CAAO,EAElBI,EAAA,OAAO,QAAQG,GAAS,CAC5BR,EAAiBQ,EAAM,EAAE,CAAA,CAC1B,EAGI,CACL,GAAGH,EACH,OAAQA,EAAM,OAAO,IACnBE,GAAAA,EAAE,KAAON,GAAWA,IAAY,OAC5B,CACE,GAAGM,EACH,KAAM,EAAA,EAERA,CACN,CAAA,CAEJ,CACA,IAAK,eACC,OAAAD,EAAO,UAAY,OACd,CACL,GAAGD,EACH,OAAQ,CAAC,CAAA,EAGN,CACL,GAAGA,EACH,OAAQA,EAAM,OAAO,UAAYE,EAAE,KAAOD,EAAO,OAAO,CAAA,CAE9D,CACF,EAEMG,EAA2C,CAAA,EAEjD,IAAIC,EAAqB,CAAE,OAAQ,CAAA,GAEnC,SAASP,EAASG,EAAgB,CAClBI,EAAAN,EAAQM,EAAaJ,CAAM,EACzCG,EAAU,QAAoBE,GAAA,CAC5BA,EAASD,CAAW,CAAA,CACrB,CACH,CAIA,SAASF,EAAM,CAAE,GAAGI,GAAgB,CAClC,MAAMC,EAAKf,IAELgB,EAAUF,GACdT,EAAS,CACP,KAAM,eACN,MAAO,CAAE,GAAGS,EAAO,GAAAC,CAAG,CAAA,CACvB,EACGE,EAAU,IAAMZ,EAAS,CAAE,KAAM,gBAAiB,QAASU,EAAI,EAE5D,OAAAV,EAAA,CACP,KAAM,YACN,MAAO,CACL,GAAGS,EACH,GAAAC,EACA,KAAM,GACN,aAAeG,GAAkB,CAC1BA,GAAcD,GACrB,CACF,CAAA,CACD,EAEM,CACL,GAAAF,EACA,QAAAE,EACA,OAAAD,CAAA,CAEJ,CAEA,SAASG,GAAW,CAClB,KAAM,CAACZ,EAAOa,CAAQ,EAAIC,EAAM,SAAgBT,CAAW,EAE3DS,OAAAA,EAAM,UAAU,KACdV,EAAU,KAAKS,CAAQ,EAChB,IAAM,CACL,MAAAE,EAAQX,EAAU,QAAQS,CAAQ,EACpCE,EAAQ,IACAX,EAAA,OAAOW,EAAO,CAAC,CAC3B,GAED,CAACf,CAAK,CAAC,EAEH,CACL,GAAGA,EACH,MAAAG,EACA,QAAUP,GAAqBE,EAAS,CAAE,KAAM,gBAAiB,QAAAF,EAAS,CAAA,CAE9E"}
1
+ {"version":3,"file":"index.cjs36.js","sources":["../src/Toast/Toaster.tsx"],"sourcesContent":["'use client'\n\nimport {\n Toast,\n ToastClose,\n ToastDescription,\n ToastIcon,\n ToastProvider,\n ToastTitle,\n ToastViewport\n} from './Toast'\nimport { useToast } from './hooks'\n\nconst DEFAULT_TOAST_DURATION = 5000\n\nexport function Toaster() {\n const { toasts } = useToast()\n\n return (\n <ToastProvider>\n {toasts.map(function ({\n variant,\n id,\n title,\n description,\n action,\n hideIcon,\n ...props\n }) {\n return (\n <Toast\n key={id}\n variant={variant}\n duration={DEFAULT_TOAST_DURATION}\n {...props}\n >\n <div className=\"flex items-center\">\n {!hideIcon && (\n <ToastIcon variant={variant} className=\"mr-12 flex-shrink-0\" />\n )}\n <div className=\"grid\">\n {title && <ToastTitle>{title}</ToastTitle>}\n {description && (\n <ToastDescription>{description}</ToastDescription>\n )}\n </div>\n </div>\n {action}\n <ToastClose />\n </Toast>\n )\n })}\n <ToastViewport />\n </ToastProvider>\n )\n}\n"],"names":["DEFAULT_TOAST_DURATION","Toaster","toasts","useToast","ToastProvider","variant","id","title","description","action","hideIcon","props","jsxs","Toast","jsx","ToastIcon","ToastTitle","ToastDescription","ToastClose","ToastViewport"],"mappings":"gLAaMA,EAAyB,IAExB,SAASC,GAAU,CAClB,KAAA,CAAE,OAAAC,GAAWC,EAAAA,WAEnB,gCACGC,gBACE,CAAA,SAAA,CAAAF,EAAO,IAAI,SAAU,CACpB,QAAAG,EACA,GAAAC,EACA,MAAAC,EACA,YAAAC,EACA,OAAAC,EACA,SAAAC,EACA,GAAGC,CAAA,EACF,CAEC,OAAAC,EAAA,kBAAA,KAACC,EAAA,MAAA,CAEC,QAAAR,EACA,SAAUL,EACT,GAAGW,EAEJ,SAAA,CAACC,EAAAA,kBAAAA,KAAA,MAAA,CAAI,UAAU,oBACZ,SAAA,CAAA,CAACF,GACAI,EAAAA,kBAAAA,IAACC,EAAU,UAAA,CAAA,QAAAV,EAAkB,UAAU,sBAAsB,EAE/DO,EAAAA,kBAAAA,KAAC,MAAI,CAAA,UAAU,OACZ,SAAA,CAASL,GAAAO,EAAAA,kBAAAA,IAACE,EAAAA,YAAY,SAAMT,CAAA,CAAA,EAC5BC,GACEM,EAAAA,kBAAAA,IAAAG,EAAAA,iBAAA,CAAkB,SAAYT,CAAA,CAAA,CAAA,EAEnC,CAAA,EACF,EACCC,0BACAS,EAAW,WAAA,EAAA,CAAA,CAAA,EAjBPZ,CAAA,CAkBP,CAEH,0BACAa,EAAc,cAAA,EAAA,CACjB,CAAA,CAAA,CAEJ"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("./index.cjs42.js"),b=require("@radix-ui/react-toggle"),d=require("class-variance-authority"),c=require("react"),u=require("./index.cjs43.js");function n(t){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const r=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(a,e,r.get?r:{enumerable:!0,get:()=>t[e]})}}return a.default=t,Object.freeze(a)}const o=n(b),y=n(c),g=d.cva("inline-flex items-center justify-center rounded-full font-small transition-colors disabled:pointer-events-none disabled:opacity-40",{variants:{variant:{default:"bg-transparent text-gray-700 hover:bg-gray-900-8 hover:text-purple-900 data-[state=on]:bg-purple-100 data-[state=on]:text-purple-900","badge-green":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-green-50 data-[state=on]:text-green-800","badge-yellow":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-yellow-50 data-[state=on]:text-yellow-700","badge-magenta":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-magenta-50 data-[state=on]:text-magenta-700","badge-gray":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-gray-200 data-[state=on]:text-gray-900","badge-purple":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-purple-100 data-[state=on]:text-purple-900","badge-robinblue":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-robinblue-100 data-[state=on]:text-robinblue-900"},size:{icon:"w-32 h-32",sm:"px-8 h-[26px] text-sm",md:"px-12 h-32 text-base"}},defaultVariants:{variant:"default",size:"icon"}}),s=y.forwardRef(({className:t,variant:a,size:e,...r},i)=>l.jsxRuntimeExports.jsx(o.Root,{ref:i,className:u.cn(g({variant:a,size:e,className:t})),...r}));s.displayName=o.Root.displayName;exports.Toggle=s;exports.toggleVariants=g;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("react");function O(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const s in t)if(s!=="default"){const o=Object.getOwnPropertyDescriptor(t,s);Object.defineProperty(e,s,o.get?o:{enumerable:!0,get:()=>t[s]})}}return e.default=t,Object.freeze(e)}const T=O(p),l=1,A=5e3;let a=0;function _(){return a=(a+1)%Number.MAX_SAFE_INTEGER,a.toString()}const i=new Map,S=t=>{if(i.has(t))return;const e=setTimeout(()=>{i.delete(t),n({type:"REMOVE_TOAST",toastId:t})},A);i.set(t,e)},d=(t,e)=>{switch(e.type){case"ADD_TOAST":return{...t,toasts:[e.toast,...t.toasts].slice(0,l)};case"UPDATE_TOAST":return{...t,toasts:t.toasts.map(s=>s.id===e.toast.id?{...s,...e.toast}:s)};case"DISMISS_TOAST":{const{toastId:s}=e;return s?S(s):t.toasts.forEach(o=>{S(o.id)}),{...t,toasts:t.toasts.map(o=>o.id===s||s===void 0?{...o,open:!1}:o)}}case"REMOVE_TOAST":return e.toastId===void 0?{...t,toasts:[]}:{...t,toasts:t.toasts.filter(s=>s.id!==e.toastId)}}},r=[];let u={toasts:[]};function n(t){u=d(u,t),r.forEach(e=>{e(u)})}function f({...t}){const e=_(),s=c=>n({type:"UPDATE_TOAST",toast:{...c,id:e}}),o=()=>n({type:"DISMISS_TOAST",toastId:e});return n({type:"ADD_TOAST",toast:{...t,id:e,open:!0,onOpenChange:c=>{c||o()}}}),{id:e,dismiss:o,update:s}}function m(){const[t,e]=T.useState(u);return T.useEffect(()=>(r.push(e),()=>{const s=r.indexOf(e);s>-1&&r.splice(s,1)}),[t]),{...t,toast:f,dismiss:s=>n({type:"DISMISS_TOAST",toastId:s})}}exports.reducer=d;exports.toast=f;exports.useToast=m;
2
2
  //# sourceMappingURL=index.cjs37.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs37.js","sources":["../src/Toggle/index.tsx"],"sourcesContent":["'use client'\n\nimport * as TogglePrimitive from '@radix-ui/react-toggle'\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst toggleVariants = cva(\n 'inline-flex items-center justify-center rounded-full font-small transition-colors disabled:pointer-events-none disabled:opacity-40',\n {\n variants: {\n variant: {\n default:\n 'bg-transparent text-gray-700 hover:bg-gray-900-8 hover:text-purple-900 data-[state=on]:bg-purple-100 data-[state=on]:text-purple-900',\n 'badge-green':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-green-50 data-[state=on]:text-green-800',\n 'badge-yellow':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-yellow-50 data-[state=on]:text-yellow-700',\n 'badge-magenta':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-magenta-50 data-[state=on]:text-magenta-700',\n 'badge-gray':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-gray-200 data-[state=on]:text-gray-900',\n 'badge-purple':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-purple-100 data-[state=on]:text-purple-900',\n 'badge-robinblue':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-robinblue-100 data-[state=on]:text-robinblue-900'\n },\n size: {\n icon: 'w-32 h-32',\n sm: 'px-8 h-[26px] text-sm',\n md: 'px-12 h-32 text-base'\n }\n },\n defaultVariants: {\n variant: 'default',\n size: 'icon'\n }\n }\n)\n\nconst Toggle = React.forwardRef<\n React.ElementRef<typeof TogglePrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof TogglePrimitive.Root> &\n VariantProps<typeof toggleVariants>\n>(({ className, variant, size, ...props }, ref) => (\n <TogglePrimitive.Root\n ref={ref}\n className={cn(toggleVariants({ variant, size, className }))}\n {...props}\n />\n))\n\nToggle.displayName = TogglePrimitive.Root.displayName\n\nexport { Toggle, toggleVariants }\n"],"names":["toggleVariants","cva","Toggle","React","className","variant","size","props","ref","jsx","TogglePrimitive","cn"],"mappings":"ghBAOMA,EAAiBC,EAAA,IACrB,qIACA,CACE,SAAU,CACR,QAAS,CACP,QACE,uIACF,cACE,4GACF,eACE,8GACF,gBACE,gHACF,aACE,2GACF,eACE,+GACF,kBACE,oHACJ,EACA,KAAM,CACJ,KAAM,YACN,GAAI,wBACJ,GAAI,sBACN,CACF,EACA,gBAAiB,CACf,QAAS,UACT,KAAM,MACR,CACF,CACF,EAEMC,EAASC,EAAM,WAInB,CAAC,CAAE,UAAAC,EAAW,QAAAC,EAAS,KAAAC,EAAM,GAAGC,GAASC,IACzCC,EAAA,kBAAA,IAACC,EAAgB,KAAhB,CACC,IAAAF,EACA,UAAWG,KAAGX,EAAe,CAAE,QAAAK,EAAS,KAAAC,EAAM,UAAAF,CAAA,CAAW,CAAC,EACzD,GAAGG,CAAA,CACN,CACD,EAEDL,EAAO,YAAcQ,EAAgB,KAAK"}
1
+ {"version":3,"file":"index.cjs37.js","sources":["../src/Toast/hooks.tsx"],"sourcesContent":["'use client'\n\n// Inspired by react-hot-toast library\nimport * as React from 'react'\nimport type { ToastActionElement, ToastProps } from './Toast'\n\nconst TOAST_LIMIT = 1\nconst TOAST_REMOVE_DELAY = 5000\n\ntype ToasterToast = ToastProps & {\n id: string\n title?: React.ReactNode\n description?: React.ReactNode\n action?: ToastActionElement\n hideIcon?: boolean\n}\n\nconst actionTypes = {\n ADD_TOAST: 'ADD_TOAST',\n UPDATE_TOAST: 'UPDATE_TOAST',\n DISMISS_TOAST: 'DISMISS_TOAST',\n REMOVE_TOAST: 'REMOVE_TOAST'\n} as const\n\nlet count = 0\n\nfunction genId() {\n count = (count + 1) % Number.MAX_SAFE_INTEGER\n return count.toString()\n}\n\ntype ActionType = typeof actionTypes\n\ntype Action =\n | {\n type: ActionType['ADD_TOAST']\n toast: ToasterToast\n }\n | {\n type: ActionType['UPDATE_TOAST']\n toast: Partial<ToasterToast>\n }\n | {\n type: ActionType['DISMISS_TOAST']\n toastId?: ToasterToast['id']\n }\n | {\n type: ActionType['REMOVE_TOAST']\n toastId?: ToasterToast['id']\n }\n\ninterface State {\n toasts: ToasterToast[]\n}\n\nconst toastTimeouts = new Map<string, ReturnType<typeof setTimeout>>()\n\nconst addToRemoveQueue = (toastId: string) => {\n if (toastTimeouts.has(toastId)) {\n return\n }\n\n const timeout = setTimeout(() => {\n toastTimeouts.delete(toastId)\n dispatch({\n type: 'REMOVE_TOAST',\n toastId: toastId\n })\n }, TOAST_REMOVE_DELAY)\n\n toastTimeouts.set(toastId, timeout)\n}\n\nexport const reducer = (state: State, action: Action): State => {\n switch (action.type) {\n case 'ADD_TOAST':\n return {\n ...state,\n toasts: [action.toast, ...state.toasts].slice(0, TOAST_LIMIT)\n }\n\n case 'UPDATE_TOAST':\n return {\n ...state,\n toasts: state.toasts.map(t =>\n t.id === action.toast.id ? { ...t, ...action.toast } : t\n )\n }\n\n case 'DISMISS_TOAST': {\n const { toastId } = action\n\n // ! Side effects ! - This could be extracted into a dismissToast() action,\n // but I'll keep it here for simplicity\n if (toastId) {\n addToRemoveQueue(toastId)\n } else {\n state.toasts.forEach(toast => {\n addToRemoveQueue(toast.id)\n })\n }\n\n return {\n ...state,\n toasts: state.toasts.map(t =>\n t.id === toastId || toastId === undefined\n ? {\n ...t,\n open: false\n }\n : t\n )\n }\n }\n case 'REMOVE_TOAST':\n if (action.toastId === undefined) {\n return {\n ...state,\n toasts: []\n }\n }\n return {\n ...state,\n toasts: state.toasts.filter(t => t.id !== action.toastId)\n }\n }\n}\n\nconst listeners: Array<(state: State) => void> = []\n\nlet memoryState: State = { toasts: [] }\n\nfunction dispatch(action: Action) {\n memoryState = reducer(memoryState, action)\n listeners.forEach(listener => {\n listener(memoryState)\n })\n}\n\ntype Toast = Omit<ToasterToast, 'id'>\n\nfunction toast({ ...props }: Toast) {\n const id = genId()\n\n const update = (props: ToasterToast) =>\n dispatch({\n type: 'UPDATE_TOAST',\n toast: { ...props, id }\n })\n const dismiss = () => dispatch({ type: 'DISMISS_TOAST', toastId: id })\n\n dispatch({\n type: 'ADD_TOAST',\n toast: {\n ...props,\n id,\n open: true,\n onOpenChange: (open: boolean) => {\n if (!open) dismiss()\n }\n }\n })\n\n return {\n id: id,\n dismiss,\n update\n }\n}\n\nfunction useToast() {\n const [state, setState] = React.useState<State>(memoryState)\n\n React.useEffect(() => {\n listeners.push(setState)\n return () => {\n const index = listeners.indexOf(setState)\n if (index > -1) {\n listeners.splice(index, 1)\n }\n }\n }, [state])\n\n return {\n ...state,\n toast,\n dismiss: (toastId?: string) => dispatch({ type: 'DISMISS_TOAST', toastId })\n }\n}\n\nexport { useToast, toast }\n"],"names":["TOAST_LIMIT","TOAST_REMOVE_DELAY","count","genId","toastTimeouts","addToRemoveQueue","toastId","timeout","dispatch","reducer","state","action","t","toast","listeners","memoryState","listener","props","id","update","dismiss","open","useToast","setState","React","index"],"mappings":"mYAMMA,EAAc,EACdC,EAAqB,IAiB3B,IAAIC,EAAQ,EAEZ,SAASC,GAAQ,CACN,OAAAD,GAAAA,EAAQ,GAAK,OAAO,iBACtBA,EAAM,UACf,CA0BA,MAAME,MAAoB,IAEpBC,EAAoBC,GAAoB,CACxC,GAAAF,EAAc,IAAIE,CAAO,EAC3B,OAGI,MAAAC,EAAU,WAAW,IAAM,CAC/BH,EAAc,OAAOE,CAAO,EACnBE,EAAA,CACP,KAAM,eACN,QAAAF,CAAA,CACD,GACAL,CAAkB,EAEPG,EAAA,IAAIE,EAASC,CAAO,CACpC,EAEaE,EAAU,CAACC,EAAcC,IAA0B,CAC9D,OAAQA,EAAO,KAAM,CACnB,IAAK,YACI,MAAA,CACL,GAAGD,EACH,OAAQ,CAACC,EAAO,MAAO,GAAGD,EAAM,MAAM,EAAE,MAAM,EAAGV,CAAW,CAAA,EAGhE,IAAK,eACI,MAAA,CACL,GAAGU,EACH,OAAQA,EAAM,OAAO,IACnBE,GAAAA,EAAE,KAAOD,EAAO,MAAM,GAAK,CAAE,GAAGC,EAAG,GAAGD,EAAO,KAAU,EAAAC,CACzD,CAAA,EAGJ,IAAK,gBAAiB,CACd,KAAA,CAAE,QAAAN,CAAY,EAAAK,EAIpB,OAAIL,EACFD,EAAiBC,CAAO,EAElBI,EAAA,OAAO,QAAQG,GAAS,CAC5BR,EAAiBQ,EAAM,EAAE,CAAA,CAC1B,EAGI,CACL,GAAGH,EACH,OAAQA,EAAM,OAAO,IACnBE,GAAAA,EAAE,KAAON,GAAWA,IAAY,OAC5B,CACE,GAAGM,EACH,KAAM,EAAA,EAERA,CACN,CAAA,CAEJ,CACA,IAAK,eACC,OAAAD,EAAO,UAAY,OACd,CACL,GAAGD,EACH,OAAQ,CAAC,CAAA,EAGN,CACL,GAAGA,EACH,OAAQA,EAAM,OAAO,UAAYE,EAAE,KAAOD,EAAO,OAAO,CAAA,CAE9D,CACF,EAEMG,EAA2C,CAAA,EAEjD,IAAIC,EAAqB,CAAE,OAAQ,CAAA,GAEnC,SAASP,EAASG,EAAgB,CAClBI,EAAAN,EAAQM,EAAaJ,CAAM,EACzCG,EAAU,QAAoBE,GAAA,CAC5BA,EAASD,CAAW,CAAA,CACrB,CACH,CAIA,SAASF,EAAM,CAAE,GAAGI,GAAgB,CAClC,MAAMC,EAAKf,IAELgB,EAAUF,GACdT,EAAS,CACP,KAAM,eACN,MAAO,CAAE,GAAGS,EAAO,GAAAC,CAAG,CAAA,CACvB,EACGE,EAAU,IAAMZ,EAAS,CAAE,KAAM,gBAAiB,QAASU,EAAI,EAE5D,OAAAV,EAAA,CACP,KAAM,YACN,MAAO,CACL,GAAGS,EACH,GAAAC,EACA,KAAM,GACN,aAAeG,GAAkB,CAC1BA,GAAcD,GACrB,CACF,CAAA,CACD,EAEM,CACL,GAAAF,EACA,QAAAE,EACA,OAAAD,CAAA,CAEJ,CAEA,SAASG,GAAW,CAClB,KAAM,CAACZ,EAAOa,CAAQ,EAAIC,EAAM,SAAgBT,CAAW,EAE3DS,OAAAA,EAAM,UAAU,KACdV,EAAU,KAAKS,CAAQ,EAChB,IAAM,CACL,MAAAE,EAAQX,EAAU,QAAQS,CAAQ,EACpCE,EAAQ,IACAX,EAAA,OAAOW,EAAO,CAAC,CAC3B,GAED,CAACf,CAAK,CAAC,EAEH,CACL,GAAGA,EACH,MAAAG,EACA,QAAUP,GAAqBE,EAAS,CAAE,KAAM,gBAAiB,QAAAF,EAAS,CAAA,CAE9E"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.cjs42.js"),f=require("@radix-ui/react-toggle-group"),x=require("react"),j=require("./index.cjs37.js"),l=require("./index.cjs43.js");function g(e){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(o,t,r.get?r:{enumerable:!0,get:()=>e[t]})}}return o.default=e,Object.freeze(o)}const s=g(f),n=g(x),m=n.createContext({variant:"default",size:"icon"}),p=n.forwardRef(({className:e,variant:o,size:t,children:r,...i},a)=>c.jsxRuntimeExports.jsx(s.Root,{ref:a,className:l.cn("flex items-center justify-center gap-8",e),...i,children:c.jsxRuntimeExports.jsx(m.Provider,{value:{variant:o,size:t},children:r})}));p.displayName=s.Root.displayName;const d=n.forwardRef(({className:e,children:o,variant:t,size:r,...i},a)=>{const u=n.useContext(m);return c.jsxRuntimeExports.jsx(s.Item,{ref:a,className:l.cn(j.toggleVariants({variant:u.variant||t,size:u.size||r}),e),...i,children:o})});d.displayName=s.Item.displayName;exports.ToggleGroup=p;exports.ToggleGroupItem=d;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("./index.cjs43.js"),b=require("@radix-ui/react-toggle"),d=require("class-variance-authority"),c=require("react"),u=require("./index.cjs44.js");function n(t){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const r=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(a,e,r.get?r:{enumerable:!0,get:()=>t[e]})}}return a.default=t,Object.freeze(a)}const o=n(b),y=n(c),g=d.cva("inline-flex items-center justify-center rounded-full font-small transition-colors disabled:pointer-events-none disabled:opacity-40",{variants:{variant:{default:"bg-transparent text-gray-700 hover:bg-gray-900-8 hover:text-purple-900 data-[state=on]:bg-purple-100 data-[state=on]:text-purple-900","badge-green":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-green-50 data-[state=on]:text-green-800","badge-yellow":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-yellow-50 data-[state=on]:text-yellow-700","badge-magenta":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-magenta-50 data-[state=on]:text-magenta-700","badge-gray":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-gray-200 data-[state=on]:text-gray-900","badge-purple":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-purple-100 data-[state=on]:text-purple-900","badge-robinblue":"bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-robinblue-100 data-[state=on]:text-robinblue-900"},size:{icon:"w-32 h-32",sm:"px-8 h-[26px] text-sm",md:"px-12 h-32 text-base"}},defaultVariants:{variant:"default",size:"icon"}}),s=y.forwardRef(({className:t,variant:a,size:e,...r},i)=>l.jsxRuntimeExports.jsx(o.Root,{ref:i,className:u.cn(g({variant:a,size:e,className:t})),...r}));s.displayName=o.Root.displayName;exports.Toggle=s;exports.toggleVariants=g;
2
2
  //# sourceMappingURL=index.cjs38.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs38.js","sources":["../src/ToggleGroup/index.tsx"],"sourcesContent":["'use client'\n\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group'\nimport { VariantProps } from 'class-variance-authority'\nimport * as React from 'react'\nimport { toggleVariants } from '../Toggle'\nimport { cn } from '../lib/utils'\n\nconst ToggleGroupContext = React.createContext<\n VariantProps<typeof toggleVariants>\n>({\n variant: 'default',\n size: 'icon'\n})\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef<typeof ToggleGroupPrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof ToggleGroupPrimitive.Root> &\n VariantProps<typeof toggleVariants>\n>(({ className, variant, size, children, ...props }, ref) => (\n <ToggleGroupPrimitive.Root\n ref={ref}\n className={cn('flex items-center justify-center gap-8', className)}\n {...props}\n >\n <ToggleGroupContext.Provider value={{ variant, size }}>\n {children}\n </ToggleGroupContext.Provider>\n </ToggleGroupPrimitive.Root>\n))\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef<typeof ToggleGroupPrimitive.Item>,\n React.ComponentPropsWithoutRef<typeof ToggleGroupPrimitive.Item> &\n VariantProps<typeof toggleVariants>\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext)\n\n return (\n <ToggleGroupPrimitive.Item\n ref={ref}\n className={cn(\n toggleVariants({\n variant: context.variant || variant,\n size: context.size || size\n }),\n className\n )}\n {...props}\n >\n {children}\n </ToggleGroupPrimitive.Item>\n )\n})\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName\n\nexport { ToggleGroup, ToggleGroupItem }\n"],"names":["ToggleGroupContext","React","ToggleGroup","className","variant","size","children","props","ref","jsx","ToggleGroupPrimitive","cn","ToggleGroupItem","context","toggleVariants"],"mappings":"8gBAQMA,EAAqBC,EAAM,cAE/B,CACA,QAAS,UACT,KAAM,MACR,CAAC,EAEKC,EAAcD,EAAM,WAIxB,CAAC,CAAE,UAAAE,EAAW,QAAAC,EAAS,KAAAC,EAAM,SAAAC,EAAU,GAAGC,CAAM,EAAGC,IACnDC,EAAA,kBAAA,IAACC,EAAqB,KAArB,CACC,IAAAF,EACA,UAAWG,EAAAA,GAAG,yCAA0CR,CAAS,EAChE,GAAGI,EAEJ,SAAAE,EAAAA,kBAAAA,IAACT,EAAmB,SAAnB,CAA4B,MAAO,CAAE,QAAAI,EAAS,KAAAC,GAC5C,SAAAC,EACH,CAAA,CACF,CACD,EAEDJ,EAAY,YAAcQ,EAAqB,KAAK,YAEpD,MAAME,EAAkBX,EAAM,WAI5B,CAAC,CAAE,UAAAE,EAAW,SAAAG,EAAU,QAAAF,EAAS,KAAAC,EAAM,GAAGE,CAAM,EAAGC,IAAQ,CACrD,MAAAK,EAAUZ,EAAM,WAAWD,CAAkB,EAGjD,OAAAS,EAAA,kBAAA,IAACC,EAAqB,KAArB,CACC,IAAAF,EACA,UAAWG,EAAA,GACTG,iBAAe,CACb,QAASD,EAAQ,SAAWT,EAC5B,KAAMS,EAAQ,MAAQR,CAAA,CACvB,EACDF,CACF,EACC,GAAGI,EAEH,SAAAD,CAAA,CAAA,CAGP,CAAC,EAEDM,EAAgB,YAAcF,EAAqB,KAAK"}
1
+ {"version":3,"file":"index.cjs38.js","sources":["../src/Toggle/index.tsx"],"sourcesContent":["'use client'\n\nimport * as TogglePrimitive from '@radix-ui/react-toggle'\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst toggleVariants = cva(\n 'inline-flex items-center justify-center rounded-full font-small transition-colors disabled:pointer-events-none disabled:opacity-40',\n {\n variants: {\n variant: {\n default:\n 'bg-transparent text-gray-700 hover:bg-gray-900-8 hover:text-purple-900 data-[state=on]:bg-purple-100 data-[state=on]:text-purple-900',\n 'badge-green':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-green-50 data-[state=on]:text-green-800',\n 'badge-yellow':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-yellow-50 data-[state=on]:text-yellow-700',\n 'badge-magenta':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-magenta-50 data-[state=on]:text-magenta-700',\n 'badge-gray':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-gray-200 data-[state=on]:text-gray-900',\n 'badge-purple':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-purple-100 data-[state=on]:text-purple-900',\n 'badge-robinblue':\n 'bg-gray-100 text-gray-900/48 hover:bg-gray-200 data-[state=on]:bg-robinblue-100 data-[state=on]:text-robinblue-900'\n },\n size: {\n icon: 'w-32 h-32',\n sm: 'px-8 h-[26px] text-sm',\n md: 'px-12 h-32 text-base'\n }\n },\n defaultVariants: {\n variant: 'default',\n size: 'icon'\n }\n }\n)\n\nconst Toggle = React.forwardRef<\n React.ElementRef<typeof TogglePrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof TogglePrimitive.Root> &\n VariantProps<typeof toggleVariants>\n>(({ className, variant, size, ...props }, ref) => (\n <TogglePrimitive.Root\n ref={ref}\n className={cn(toggleVariants({ variant, size, className }))}\n {...props}\n />\n))\n\nToggle.displayName = TogglePrimitive.Root.displayName\n\nexport { Toggle, toggleVariants }\n"],"names":["toggleVariants","cva","Toggle","React","className","variant","size","props","ref","jsx","TogglePrimitive","cn"],"mappings":"ghBAOMA,EAAiBC,EAAA,IACrB,qIACA,CACE,SAAU,CACR,QAAS,CACP,QACE,uIACF,cACE,4GACF,eACE,8GACF,gBACE,gHACF,aACE,2GACF,eACE,+GACF,kBACE,oHACJ,EACA,KAAM,CACJ,KAAM,YACN,GAAI,wBACJ,GAAI,sBACN,CACF,EACA,gBAAiB,CACf,QAAS,UACT,KAAM,MACR,CACF,CACF,EAEMC,EAASC,EAAM,WAInB,CAAC,CAAE,UAAAC,EAAW,QAAAC,EAAS,KAAAC,EAAM,GAAGC,GAASC,IACzCC,EAAA,kBAAA,IAACC,EAAgB,KAAhB,CACC,IAAAF,EACA,UAAWG,KAAGX,EAAe,CAAE,QAAAK,EAAS,KAAAC,EAAM,UAAAF,CAAA,CAAW,CAAC,EACzD,GAAGG,CAAA,CACN,CACD,EAEDL,EAAO,YAAcQ,EAAgB,KAAK"}