@incognia/cosmik 0.29.3-beta.3 → 0.30.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 (176) hide show
  1. package/dist/Separator/index.d.ts +2 -1
  2. package/dist/Separator/index.d.ts.map +1 -1
  3. package/dist/Skeleton/index.d.ts +4 -0
  4. package/dist/Skeleton/index.d.ts.map +1 -0
  5. package/dist/Table/index.d.ts.map +1 -1
  6. package/dist/cosmik.css +1 -1
  7. package/dist/index.cjs.js +1 -1
  8. package/dist/index.cjs10.js +1 -1
  9. package/dist/index.cjs11.js +1 -1
  10. package/dist/index.cjs12.js +1 -1
  11. package/dist/index.cjs13.js +1 -1
  12. package/dist/index.cjs14.js +1 -1
  13. package/dist/index.cjs15.js +1 -1
  14. package/dist/index.cjs16.js +1 -1
  15. package/dist/index.cjs17.js +1 -1
  16. package/dist/index.cjs18.js +1 -1
  17. package/dist/index.cjs19.js +1 -1
  18. package/dist/index.cjs20.js +1 -1
  19. package/dist/index.cjs21.js +1 -1
  20. package/dist/index.cjs22.js +1 -1
  21. package/dist/index.cjs23.js +1 -1
  22. package/dist/index.cjs24.js +1 -1
  23. package/dist/index.cjs24.js.map +1 -1
  24. package/dist/index.cjs25.js +1 -1
  25. package/dist/index.cjs25.js.map +1 -1
  26. package/dist/index.cjs26.js +1 -1
  27. package/dist/index.cjs26.js.map +1 -1
  28. package/dist/index.cjs27.js +1 -1
  29. package/dist/index.cjs27.js.map +1 -1
  30. package/dist/index.cjs28.js +1 -1
  31. package/dist/index.cjs28.js.map +1 -1
  32. package/dist/index.cjs29.js +1 -1
  33. package/dist/index.cjs29.js.map +1 -1
  34. package/dist/index.cjs30.js +1 -1
  35. package/dist/index.cjs30.js.map +1 -1
  36. package/dist/index.cjs31.js +1 -1
  37. package/dist/index.cjs31.js.map +1 -1
  38. package/dist/index.cjs32.js +1 -1
  39. package/dist/index.cjs32.js.map +1 -1
  40. package/dist/index.cjs33.js +1 -1
  41. package/dist/index.cjs33.js.map +1 -1
  42. package/dist/index.cjs34.js +1 -1
  43. package/dist/index.cjs34.js.map +1 -1
  44. package/dist/index.cjs35.js +1 -1
  45. package/dist/index.cjs35.js.map +1 -1
  46. package/dist/index.cjs36.js +1 -1
  47. package/dist/index.cjs36.js.map +1 -1
  48. package/dist/index.cjs37.js +1 -1
  49. package/dist/index.cjs37.js.map +1 -1
  50. package/dist/index.cjs38.js +1 -1
  51. package/dist/index.cjs38.js.map +1 -1
  52. package/dist/index.cjs39.js +1 -1
  53. package/dist/index.cjs39.js.map +1 -1
  54. package/dist/index.cjs4.js +1 -1
  55. package/dist/index.cjs40.js +1 -1
  56. package/dist/index.cjs40.js.map +1 -1
  57. package/dist/index.cjs41.js +1 -9
  58. package/dist/index.cjs41.js.map +1 -1
  59. package/dist/index.cjs42.js +1 -19
  60. package/dist/index.cjs42.js.map +1 -1
  61. package/dist/index.cjs43.js +1 -1
  62. package/dist/index.cjs43.js.map +1 -1
  63. package/dist/index.cjs44.js +1 -1
  64. package/dist/index.cjs44.js.map +1 -1
  65. package/dist/index.cjs45.js +9 -1
  66. package/dist/index.cjs45.js.map +1 -1
  67. package/dist/index.cjs46.js +19 -1
  68. package/dist/index.cjs46.js.map +1 -1
  69. package/dist/index.cjs47.js +1 -1
  70. package/dist/index.cjs48.js +1 -1
  71. package/dist/index.cjs48.js.map +1 -1
  72. package/dist/index.cjs49.js +1 -1
  73. package/dist/index.cjs49.js.map +1 -1
  74. package/dist/index.cjs5.js +1 -1
  75. package/dist/index.cjs50.js +1 -1
  76. package/dist/index.cjs50.js.map +1 -1
  77. package/dist/index.cjs51.js +1 -1
  78. package/dist/index.cjs51.js.map +1 -1
  79. package/dist/index.cjs52.js +1 -1
  80. package/dist/index.cjs52.js.map +1 -1
  81. package/dist/index.cjs53.js +1 -1
  82. package/dist/index.cjs54.js +1 -1
  83. package/dist/index.cjs54.js.map +1 -1
  84. package/dist/index.cjs55.js +2 -0
  85. package/dist/index.cjs55.js.map +1 -0
  86. package/dist/index.cjs6.js +1 -1
  87. package/dist/index.cjs7.js +1 -1
  88. package/dist/index.cjs8.js +1 -1
  89. package/dist/index.cjs9.js +1 -1
  90. package/dist/index.d.ts +1 -0
  91. package/dist/index.d.ts.map +1 -1
  92. package/dist/index.es.js +65 -63
  93. package/dist/index.es.js.map +1 -1
  94. package/dist/index.es10.js +5 -5
  95. package/dist/index.es11.js +2 -2
  96. package/dist/index.es12.js +2 -2
  97. package/dist/index.es13.js +3 -3
  98. package/dist/index.es14.js +2 -2
  99. package/dist/index.es15.js +2 -2
  100. package/dist/index.es16.js +2 -2
  101. package/dist/index.es17.js +3 -3
  102. package/dist/index.es18.js +2 -2
  103. package/dist/index.es19.js +2 -2
  104. package/dist/index.es20.js +2 -2
  105. package/dist/index.es21.js +2 -2
  106. package/dist/index.es22.js +2 -2
  107. package/dist/index.es23.js +2 -2
  108. package/dist/index.es24.js +15 -27
  109. package/dist/index.es24.js.map +1 -1
  110. package/dist/index.es25.js +21 -106
  111. package/dist/index.es25.js.map +1 -1
  112. package/dist/index.es26.js +101 -31
  113. package/dist/index.es26.js.map +1 -1
  114. package/dist/index.es27.js +42 -23
  115. package/dist/index.es27.js.map +1 -1
  116. package/dist/index.es28.js +22 -108
  117. package/dist/index.es28.js.map +1 -1
  118. package/dist/index.es29.js +109 -41
  119. package/dist/index.es29.js.map +1 -1
  120. package/dist/index.es30.js +40 -94
  121. package/dist/index.es30.js.map +1 -1
  122. package/dist/index.es31.js +93 -38
  123. package/dist/index.es31.js.map +1 -1
  124. package/dist/index.es32.js +36 -35
  125. package/dist/index.es32.js.map +1 -1
  126. package/dist/index.es33.js +36 -29
  127. package/dist/index.es33.js.map +1 -1
  128. package/dist/index.es34.js +25 -58
  129. package/dist/index.es34.js.map +1 -1
  130. package/dist/index.es35.js +61 -259
  131. package/dist/index.es35.js.map +1 -1
  132. package/dist/index.es36.js +263 -6
  133. package/dist/index.es36.js.map +1 -1
  134. package/dist/index.es37.js +6 -13
  135. package/dist/index.es37.js.map +1 -1
  136. package/dist/index.es38.js +12 -118
  137. package/dist/index.es38.js.map +1 -1
  138. package/dist/index.es39.js +117 -12
  139. package/dist/index.es39.js.map +1 -1
  140. package/dist/index.es4.js +1 -1
  141. package/dist/index.es40.js +14 -2
  142. package/dist/index.es40.js.map +1 -1
  143. package/dist/index.es41.js +3 -29
  144. package/dist/index.es41.js.map +1 -1
  145. package/dist/index.es42.js +104 -598
  146. package/dist/index.es42.js.map +1 -1
  147. package/dist/index.es43.js +33 -3
  148. package/dist/index.es43.js.map +1 -1
  149. package/dist/index.es44.js +2 -105
  150. package/dist/index.es44.js.map +1 -1
  151. package/dist/index.es45.js +29 -33
  152. package/dist/index.es45.js.map +1 -1
  153. package/dist/index.es46.js +599 -2
  154. package/dist/index.es46.js.map +1 -1
  155. package/dist/index.es47.js +2 -2
  156. package/dist/index.es48.js +151 -2
  157. package/dist/index.es48.js.map +1 -1
  158. package/dist/index.es49.js +15 -150
  159. package/dist/index.es49.js.map +1 -1
  160. package/dist/index.es5.js +2 -2
  161. package/dist/index.es50.js +339 -13
  162. package/dist/index.es50.js.map +1 -1
  163. package/dist/index.es51.js +40 -337
  164. package/dist/index.es51.js.map +1 -1
  165. package/dist/index.es52.js +2 -45
  166. package/dist/index.es52.js.map +1 -1
  167. package/dist/index.es53.js +2 -2
  168. package/dist/index.es54.js +2 -4
  169. package/dist/index.es54.js.map +1 -1
  170. package/dist/index.es55.js +7 -0
  171. package/dist/index.es55.js.map +1 -0
  172. package/dist/index.es6.js +2 -2
  173. package/dist/index.es7.js +2 -2
  174. package/dist/index.es8.js +2 -2
  175. package/dist/index.es9.js +2 -2
  176. package/package.json +1 -1
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index.cjs36.js"),c=require("lucide-react"),T=require("react"),s=require("./index.cjs37.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.cjs37.js"),d=require("@radix-ui/react-switch"),l=require("react"),s=require("./index.cjs38.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.cjs25.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs25.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 {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,EACH,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.cjs25.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.cjs36.js"),d=require("@radix-ui/react-tabs"),b=require("react"),n=require("./index.cjs37.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.cjs37.js"),c=require("lucide-react"),T=require("react"),s=require("./index.cjs38.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.cjs26.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs26.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.cjs26.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 n=require("./index.cjs36.js"),i=require("react"),s=require("./index.cjs37.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 i=require("./index.cjs37.js"),d=require("@radix-ui/react-tabs"),b=require("react"),n=require("./index.cjs38.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.cjs27.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs27.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.cjs27.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 r=require("./index.cjs36.js"),g=require("@radix-ui/react-toast"),w=require("class-variance-authority"),c=require("lucide-react"),y=require("react"),o=require("./index.cjs37.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.cjs37.js"),i=require("react"),s=require("./index.cjs38.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.cjs28.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs28.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.cjs28.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.cjs36.js"),t=require("./index.cjs28.js"),c=require("./index.cjs30.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.cjs37.js"),g=require("@radix-ui/react-toast"),w=require("class-variance-authority"),c=require("lucide-react"),y=require("react"),o=require("./index.cjs38.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.cjs29.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs29.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.cjs29.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.cjs37.js"),t=require("./index.cjs29.js"),c=require("./index.cjs31.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.cjs30.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs30.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.cjs30.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.cjs36.js"),b=require("@radix-ui/react-toggle"),d=require("class-variance-authority"),c=require("react"),u=require("./index.cjs37.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.cjs31.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs31.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.cjs31.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.cjs36.js"),f=require("@radix-ui/react-toggle-group"),x=require("react"),j=require("./index.cjs31.js"),l=require("./index.cjs37.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.cjs37.js"),b=require("@radix-ui/react-toggle"),d=require("class-variance-authority"),c=require("react"),u=require("./index.cjs38.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.cjs32.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs32.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.cjs32.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,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("./index.cjs36.js"),l=require("@radix-ui/react-tooltip"),c=require("class-variance-authority"),u=require("react"),p=require("./index.cjs37.js");function a(t){const o=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(o,e,r.get?r:{enumerable:!0,get:()=>t[e]})}}return o.default=t,Object.freeze(o)}const i=a(l),m=a(u),f=c.cva("z-50 overflow-hidden rounded px-12 py-8 text-sm shadow-200 animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",{variants:{variant:{default:"bg-gray-800 text-white text-sm",inverted:"bg-white text-gray-800 border border-gray-900-8"}},defaultVariants:{variant:"default"}}),g=i.Provider,T=i.Root,b=i.Trigger,n=m.forwardRef(({variant:t,className:o,sideOffset:e=4,...r},s)=>d.jsxRuntimeExports.jsx(i.Content,{ref:s,sideOffset:e,className:p.cn(f({variant:t,className:o})),...r}));n.displayName=i.Content.displayName;exports.Tooltip=T;exports.TooltipContent=n;exports.TooltipProvider=g;exports.TooltipTrigger=b;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.cjs37.js"),f=require("@radix-ui/react-toggle-group"),x=require("react"),j=require("./index.cjs32.js"),l=require("./index.cjs38.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;
2
2
  //# sourceMappingURL=index.cjs33.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs33.js","sources":["../src/Tooltip/index.tsx"],"sourcesContent":["'use client'\n\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip'\nimport { VariantProps, cva } from 'class-variance-authority'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst tooltipContentVariants = cva(\n 'z-50 overflow-hidden rounded px-12 py-8 text-sm shadow-200 animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',\n {\n variants: {\n variant: {\n default: 'bg-gray-800 text-white text-sm',\n inverted: 'bg-white text-gray-800 border border-gray-900-8'\n }\n },\n defaultVariants: {\n variant: 'default'\n }\n }\n)\n\nconst TooltipProvider = TooltipPrimitive.Provider\n\nconst Tooltip = TooltipPrimitive.Root\n\nconst TooltipTrigger = TooltipPrimitive.Trigger\n\ninterface TooltipContentProps\n extends React.ComponentPropsWithoutRef<typeof TooltipPrimitive.Content>,\n VariantProps<typeof tooltipContentVariants> {\n asChild?: boolean\n}\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef<typeof TooltipPrimitive.Content>,\n TooltipContentProps\n>(({ variant, className, sideOffset = 4, ...props }, ref) => (\n <TooltipPrimitive.Content\n ref={ref}\n sideOffset={sideOffset}\n className={cn(tooltipContentVariants({ variant, className }))}\n {...props}\n />\n))\nTooltipContent.displayName = TooltipPrimitive.Content.displayName\n\nexport { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger }\n"],"names":["tooltipContentVariants","cva","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","React","variant","className","sideOffset","props","ref","jsx","cn"],"mappings":"ihBAOMA,EAAyBC,EAAA,IAC7B,wVACA,CACE,SAAU,CACR,QAAS,CACP,QAAS,iCACT,SAAU,iDACZ,CACF,EACA,gBAAiB,CACf,QAAS,SACX,CACF,CACF,EAEMC,EAAkBC,EAAiB,SAEnCC,EAAUD,EAAiB,KAE3BE,EAAiBF,EAAiB,QAQlCG,EAAiBC,EAAM,WAG3B,CAAC,CAAE,QAAAC,EAAS,UAAAC,EAAW,WAAAC,EAAa,EAAG,GAAGC,CAAM,EAAGC,IACnDC,EAAA,kBAAA,IAACV,EAAiB,QAAjB,CACC,IAAAS,EACA,WAAAF,EACA,UAAWI,EAAG,GAAAd,EAAuB,CAAE,QAAAQ,EAAS,UAAAC,CAAW,CAAA,CAAC,EAC3D,GAAGE,CAAA,CACN,CACD,EACDL,EAAe,YAAcH,EAAiB,QAAQ"}
1
+ {"version":3,"file":"index.cjs33.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,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index.cjs36.js"),p=require("@radix-ui/react-navigation-menu"),f=require("react"),x=require("./index.cjs22.js"),r=require("./index.cjs37.js");function u(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const i in e)if(i!=="default"){const s=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(t,i,s.get?s:{enumerable:!0,get:()=>e[i]})}}return t.default=e,Object.freeze(t)}const a=u(p),o=u(f),c=o.forwardRef((e,t)=>n.jsxRuntimeExports.jsx(a.Root,{ref:t,orientation:"vertical",...e}));c.displayName=a.Root.displayName;const l=o.forwardRef(({className:e,...t},i)=>n.jsxRuntimeExports.jsx(a.List,{ref:i,className:r.cn("group flex flex-col list-none items-center justify-center pb-16 px-8",e),...t}));l.displayName=a.List.displayName;function g({className:e,...t}){return n.jsxRuntimeExports.jsx("div",{className:r.cn("flex items-start justify-start text-sm text-gray-800 mt-16 mb-2 px-24",e),...t})}function v({...e}){return n.jsxRuntimeExports.jsx(x.Separator,{...e})}const m=o.forwardRef(({className:e,...t},i)=>n.jsxRuntimeExports.jsx(a.Item,{ref:i,className:r.cn("w-full",e),...t}));m.displayName=a.Item.displayName;const d=o.forwardRef(({className:e,...t},i)=>n.jsxRuntimeExports.jsx(a.Link,{ref:i,className:r.cn("flex justify-start px-12 py-[10px] w-full font-normal text-gray-800 rounded hover:bg-gray-200 hover:text-purple-800 hover:font-medium focus-visible:outline-none focus-visible:bg-gray-200 focus-visible:text-purple-800 focus-visible:font-medium data-[active]:bg-purple-100 data-[active]:text-purple-800 data-[active]:font-medium",e),...t}));exports.VerticalNavigationMenu=c;exports.VerticalNavigationMenuHeading=g;exports.VerticalNavigationMenuItem=m;exports.VerticalNavigationMenuLink=d;exports.VerticalNavigationMenuList=l;exports.VerticalNavigationMenuSeparator=v;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("./index.cjs37.js"),l=require("@radix-ui/react-tooltip"),c=require("class-variance-authority"),u=require("react"),p=require("./index.cjs38.js");function a(t){const o=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(o,e,r.get?r:{enumerable:!0,get:()=>t[e]})}}return o.default=t,Object.freeze(o)}const i=a(l),m=a(u),f=c.cva("z-50 overflow-hidden rounded px-12 py-8 text-sm shadow-200 animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",{variants:{variant:{default:"bg-gray-800 text-white text-sm",inverted:"bg-white text-gray-800 border border-gray-900-8"}},defaultVariants:{variant:"default"}}),g=i.Provider,T=i.Root,b=i.Trigger,n=m.forwardRef(({variant:t,className:o,sideOffset:e=4,...r},s)=>d.jsxRuntimeExports.jsx(i.Content,{ref:s,sideOffset:e,className:p.cn(f({variant:t,className:o})),...r}));n.displayName=i.Content.displayName;exports.Tooltip=T;exports.TooltipContent=n;exports.TooltipProvider=g;exports.TooltipTrigger=b;
2
2
  //# sourceMappingURL=index.cjs34.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs34.js","sources":["../src/VerticalNavigationMenu/index.tsx"],"sourcesContent":["import * as NavigationMenuPrimitive from '@radix-ui/react-navigation-menu'\nimport * as React from 'react'\nimport { Separator } from '../Separator'\nimport { cn } from '../lib/utils'\n\nconst VerticalNavigationMenu = React.forwardRef<\n React.ElementRef<typeof NavigationMenuPrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Root>\n>((props, ref) => (\n <NavigationMenuPrimitive.Root ref={ref} orientation=\"vertical\" {...props} />\n))\nVerticalNavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName\n\nconst VerticalNavigationMenuList = React.forwardRef<\n React.ElementRef<typeof NavigationMenuPrimitive.List>,\n React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.List>\n>(({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.List\n ref={ref}\n className={cn(\n 'group flex flex-col list-none items-center justify-center pb-16 px-8',\n className\n )}\n {...props}\n />\n))\nVerticalNavigationMenuList.displayName =\n NavigationMenuPrimitive.List.displayName\n\nfunction VerticalNavigationMenuHeading({\n className,\n ...props\n}: React.ComponentPropsWithoutRef<'div'>) {\n return (\n <div\n className={cn(\n 'flex items-start justify-start text-sm text-gray-800 mt-16 mb-2 px-24',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction VerticalNavigationMenuSeparator({\n ...props\n}: React.ComponentPropsWithoutRef<'div'>) {\n return <Separator {...props} />\n}\n\nconst VerticalNavigationMenuItem = React.forwardRef<\n React.ElementRef<typeof NavigationMenuPrimitive.Item>,\n React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Item>\n>(({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Item\n ref={ref}\n className={cn('w-full', className)}\n {...props}\n />\n))\nVerticalNavigationMenuItem.displayName =\n NavigationMenuPrimitive.Item.displayName\n\nconst VerticalNavigationMenuLink = React.forwardRef<\n React.ElementRef<typeof NavigationMenuPrimitive.Link>,\n React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Link>\n>(({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Link\n ref={ref}\n className={cn(\n 'flex justify-start px-12 py-[10px] w-full font-normal text-gray-800 rounded \\\n hover:bg-gray-200 hover:text-purple-800 hover:font-medium \\\n focus-visible:outline-none focus-visible:bg-gray-200 focus-visible:text-purple-800 focus-visible:font-medium \\\n data-[active]:bg-purple-100 data-[active]:text-purple-800 data-[active]:font-medium',\n className\n )}\n {...props}\n />\n))\n\nexport {\n VerticalNavigationMenu,\n VerticalNavigationMenuHeading,\n VerticalNavigationMenuItem,\n VerticalNavigationMenuLink,\n VerticalNavigationMenuList,\n VerticalNavigationMenuSeparator\n}\n"],"names":["VerticalNavigationMenu","React","props","ref","jsx","NavigationMenuPrimitive","VerticalNavigationMenuList","className","cn","VerticalNavigationMenuHeading","VerticalNavigationMenuSeparator","Separator","VerticalNavigationMenuItem","VerticalNavigationMenuLink"],"mappings":"ihBAKMA,EAAyBC,EAAM,WAGnC,CAACC,EAAOC,IACRC,EAAAA,kBAAAA,IAACC,EAAwB,KAAxB,CAA6B,IAAAF,EAAU,YAAY,WAAY,GAAGD,CAAO,CAAA,CAC3E,EACDF,EAAuB,YAAcK,EAAwB,KAAK,YAE5D,MAAAC,EAA6BL,EAAM,WAGvC,CAAC,CAAE,UAAAM,EAAW,GAAGL,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACC,EAAwB,KAAxB,CACC,IAAAF,EACA,UAAWK,EAAA,GACT,uEACAD,CACF,EACC,GAAGL,CAAA,CACN,CACD,EACDI,EAA2B,YACzBD,EAAwB,KAAK,YAE/B,SAASI,EAA8B,CACrC,UAAAF,EACA,GAAGL,CACL,EAA0C,CAEtC,OAAAE,EAAA,kBAAA,IAAC,MAAA,CACC,UAAWI,EAAA,GACT,wEACAD,CACF,EACC,GAAGL,CAAA,CAAA,CAGV,CAEA,SAASQ,EAAgC,CACvC,GAAGR,CACL,EAA0C,CACjC,OAAAE,EAAA,kBAAA,IAACO,EAAW,UAAA,CAAA,GAAGT,CAAO,CAAA,CAC/B,CAEM,MAAAU,EAA6BX,EAAM,WAGvC,CAAC,CAAE,UAAAM,EAAW,GAAGL,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACC,EAAwB,KAAxB,CACC,IAAAF,EACA,UAAWK,EAAAA,GAAG,SAAUD,CAAS,EAChC,GAAGL,CAAA,CACN,CACD,EACDU,EAA2B,YACzBP,EAAwB,KAAK,YAEzB,MAAAQ,EAA6BZ,EAAM,WAGvC,CAAC,CAAE,UAAAM,EAAW,GAAGL,CAAM,EAAGC,IAC1BC,EAAA,kBAAA,IAACC,EAAwB,KAAxB,CACC,IAAAF,EACA,UAAWK,EAAA,GACT,qVAIAD,CACF,EACC,GAAGL,CAAA,CACN,CACD"}
1
+ {"version":3,"file":"index.cjs34.js","sources":["../src/Tooltip/index.tsx"],"sourcesContent":["'use client'\n\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip'\nimport { VariantProps, cva } from 'class-variance-authority'\nimport * as React from 'react'\nimport { cn } from '../lib/utils'\n\nconst tooltipContentVariants = cva(\n 'z-50 overflow-hidden rounded px-12 py-8 text-sm shadow-200 animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',\n {\n variants: {\n variant: {\n default: 'bg-gray-800 text-white text-sm',\n inverted: 'bg-white text-gray-800 border border-gray-900-8'\n }\n },\n defaultVariants: {\n variant: 'default'\n }\n }\n)\n\nconst TooltipProvider = TooltipPrimitive.Provider\n\nconst Tooltip = TooltipPrimitive.Root\n\nconst TooltipTrigger = TooltipPrimitive.Trigger\n\ninterface TooltipContentProps\n extends React.ComponentPropsWithoutRef<typeof TooltipPrimitive.Content>,\n VariantProps<typeof tooltipContentVariants> {\n asChild?: boolean\n}\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef<typeof TooltipPrimitive.Content>,\n TooltipContentProps\n>(({ variant, className, sideOffset = 4, ...props }, ref) => (\n <TooltipPrimitive.Content\n ref={ref}\n sideOffset={sideOffset}\n className={cn(tooltipContentVariants({ variant, className }))}\n {...props}\n />\n))\nTooltipContent.displayName = TooltipPrimitive.Content.displayName\n\nexport { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger }\n"],"names":["tooltipContentVariants","cva","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","React","variant","className","sideOffset","props","ref","jsx","cn"],"mappings":"ihBAOMA,EAAyBC,EAAA,IAC7B,wVACA,CACE,SAAU,CACR,QAAS,CACP,QAAS,iCACT,SAAU,iDACZ,CACF,EACA,gBAAiB,CACf,QAAS,SACX,CACF,CACF,EAEMC,EAAkBC,EAAiB,SAEnCC,EAAUD,EAAiB,KAE3BE,EAAiBF,EAAiB,QAQlCG,EAAiBC,EAAM,WAG3B,CAAC,CAAE,QAAAC,EAAS,UAAAC,EAAW,WAAAC,EAAa,EAAG,GAAGC,CAAM,EAAGC,IACnDC,EAAA,kBAAA,IAACV,EAAiB,QAAjB,CACC,IAAAS,EACA,WAAAF,EACA,UAAWI,EAAG,GAAAd,EAAuB,CAAE,QAAAQ,EAAS,UAAAC,CAAW,CAAA,CAAC,EAC3D,GAAGE,CAAA,CACN,CACD,EACDL,EAAe,YAAcH,EAAiB,QAAQ"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const m=require("./index.cjs43.js"),w=require("./index.cjs44.js"),v=require("./index.cjs45.js"),f=w.colorStringExports,l=v.colorConvert,y=["keyword","gray","hex"],b={};for(const t of Object.keys(l))b[[...l[t].labels].sort().join("")]=t;const p={};function h(t,r){if(!(this instanceof h))return new h(t,r);if(r&&r in y&&(r=null),r&&!(r in l))throw new Error("Unknown model: "+r);let o,n;if(t==null)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(t instanceof h)this.model=t.model,this.color=[...t.color],this.valpha=t.valpha;else if(typeof t=="string"){const e=f.get(t);if(e===null)throw new Error("Unable to parse color from string: "+t);this.model=e.model,n=l[this.model].channels,this.color=e.value.slice(0,n),this.valpha=typeof e.value[n]=="number"?e.value[n]:1}else if(t.length>0){this.model=r||"rgb",n=l[this.model].channels;const e=Array.prototype.slice.call(t,0,n);this.color=d(e,n),this.valpha=typeof t[n]=="number"?t[n]:1}else if(typeof t=="number")this.model="rgb",this.color=[t>>16&255,t>>8&255,t&255],this.valpha=1;else{this.valpha=1;const e=Object.keys(t);"alpha"in t&&(e.splice(e.indexOf("alpha"),1),this.valpha=typeof t.alpha=="number"?t.alpha:0);const a=e.sort().join("");if(!(a in b))throw new Error("Unable to parse color from object: "+JSON.stringify(t));this.model=b[a];const{labels:u}=l[this.model],c=[];for(o=0;o<u.length;o++)c.push(t[u[o]]);this.color=d(c)}if(p[this.model])for(n=l[this.model].channels,o=0;o<n;o++){const e=p[this.model][o];e&&(this.color[o]=e(this.color[o]))}this.valpha=Math.max(0,Math.min(1,this.valpha)),Object.freeze&&Object.freeze(this)}h.prototype={toString(){return this.string()},toJSON(){return this[this.model]()},string(t){let r=this.model in f.to?this:this.rgb();r=r.round(typeof t=="number"?t:1);const o=r.valpha===1?r.color:[...r.color,this.valpha];return f.to[r.model](o)},percentString(t){const r=this.rgb().round(typeof t=="number"?t:1),o=r.valpha===1?r.color:[...r.color,this.valpha];return f.to.rgb.percent(o)},array(){return this.valpha===1?[...this.color]:[...this.color,this.valpha]},object(){const t={},{channels:r}=l[this.model],{labels:o}=l[this.model];for(let n=0;n<r;n++)t[o[n]]=this.color[n];return this.valpha!==1&&(t.alpha=this.valpha),t},unitArray(){const t=this.rgb().color;return t[0]/=255,t[1]/=255,t[2]/=255,this.valpha!==1&&t.push(this.valpha),t},unitObject(){const t=this.rgb().object();return t.r/=255,t.g/=255,t.b/=255,this.valpha!==1&&(t.alpha=this.valpha),t},round(t){return t=Math.max(t||0,0),new h([...this.color.map(k(t)),this.valpha],this.model)},alpha(t){return t!==void 0?new h([...this.color,Math.max(0,Math.min(1,t))],this.model):this.valpha},red:s("rgb",0,i(255)),green:s("rgb",1,i(255)),blue:s("rgb",2,i(255)),hue:s(["hsl","hsv","hsl","hwb","hcg"],0,t=>(t%360+360)%360),saturationl:s("hsl",1,i(100)),lightness:s("hsl",2,i(100)),saturationv:s("hsv",1,i(100)),value:s("hsv",2,i(100)),chroma:s("hcg",1,i(100)),gray:s("hcg",2,i(100)),white:s("hwb",1,i(100)),wblack:s("hwb",2,i(100)),cyan:s("cmyk",0,i(100)),magenta:s("cmyk",1,i(100)),yellow:s("cmyk",2,i(100)),black:s("cmyk",3,i(100)),x:s("xyz",0,i(95.047)),y:s("xyz",1,i(100)),z:s("xyz",2,i(108.833)),l:s("lab",0,i(100)),a:s("lab",1),b:s("lab",2),keyword(t){return t!==void 0?new h(t):l[this.model].keyword(this.color)},hex(t){return t!==void 0?new h(t):f.to.hex(this.rgb().round().color)},hexa(t){if(t!==void 0)return new h(t);const r=this.rgb().round().color;let o=Math.round(this.valpha*255).toString(16).toUpperCase();return o.length===1&&(o="0"+o),f.to.hex(r)+o},rgbNumber(){const t=this.rgb().color;return(t[0]&255)<<16|(t[1]&255)<<8|t[2]&255},luminosity(){const t=this.rgb().color,r=[];for(const[o,n]of t.entries()){const e=n/255;r[o]=e<=.04045?e/12.92:((e+.055)/1.055)**2.4}return .2126*r[0]+.7152*r[1]+.0722*r[2]},contrast(t){const r=this.luminosity(),o=t.luminosity();return r>o?(r+.05)/(o+.05):(o+.05)/(r+.05)},level(t){const r=this.contrast(t);return r>=7?"AAA":r>=4.5?"AA":""},isDark(){const t=this.rgb().color;return(t[0]*2126+t[1]*7152+t[2]*722)/1e4<128},isLight(){return!this.isDark()},negate(){const t=this.rgb();for(let r=0;r<3;r++)t.color[r]=255-t.color[r];return t},lighten(t){const r=this.hsl();return r.color[2]+=r.color[2]*t,r},darken(t){const r=this.hsl();return r.color[2]-=r.color[2]*t,r},saturate(t){const r=this.hsl();return r.color[1]+=r.color[1]*t,r},desaturate(t){const r=this.hsl();return r.color[1]-=r.color[1]*t,r},whiten(t){const r=this.hwb();return r.color[1]+=r.color[1]*t,r},blacken(t){const r=this.hwb();return r.color[2]+=r.color[2]*t,r},grayscale(){const t=this.rgb().color,r=t[0]*.3+t[1]*.59+t[2]*.11;return h.rgb(r,r,r)},fade(t){return this.alpha(this.valpha-this.valpha*t)},opaquer(t){return this.alpha(this.valpha+this.valpha*t)},rotate(t){const r=this.hsl();let o=r.color[0];return o=(o+t)%360,o=o<0?360+o:o,r.color[0]=o,r},mix(t,r){if(!t||!t.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof t);const o=t.rgb(),n=this.rgb(),e=r===void 0?.5:r,a=2*e-1,u=o.alpha()-n.alpha(),c=((a*u===-1?a:(a+u)/(1+a*u))+1)/2,g=1-c;return h.rgb(c*o.red()+g*n.red(),c*o.green()+g*n.green(),c*o.blue()+g*n.blue(),o.alpha()*e+n.alpha()*(1-e))}};for(const t of Object.keys(l)){if(y.includes(t))continue;const{channels:r}=l[t];h.prototype[t]=function(...o){return this.model===t?new h(this):o.length>0?new h(o,t):new h([...A(l[this.model][t].raw(this.color)),this.valpha],t)},h[t]=function(...o){let n=o[0];return typeof n=="number"&&(n=d(o,r)),new h(n,t)}}function x(t,r){return Number(t.toFixed(r))}function k(t){return function(r){return x(r,t)}}function s(t,r,o){t=Array.isArray(t)?t:[t];for(const n of t)(p[n]||(p[n]=[]))[r]=o;return t=t[0],function(n){let e;return n!==void 0?(o&&(n=o(n)),e=this[t](),e.color[r]=n,e):(e=this[t]().color[r],o&&(e=o(e)),e)}}function i(t){return function(r){return Math.max(0,Math.min(t,r))}}function A(t){return Array.isArray(t)?t:[t]}function d(t,r){for(let o=0;o<r;o++)typeof t[o]!="number"&&(t[o]=0);return t}var F=h;const M=m.getDefaultExportFromCjs(F);exports.default=M;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index.cjs37.js"),p=require("@radix-ui/react-navigation-menu"),f=require("react"),x=require("./index.cjs22.js"),r=require("./index.cjs38.js");function u(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const i in e)if(i!=="default"){const s=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(t,i,s.get?s:{enumerable:!0,get:()=>e[i]})}}return t.default=e,Object.freeze(t)}const a=u(p),o=u(f),c=o.forwardRef((e,t)=>n.jsxRuntimeExports.jsx(a.Root,{ref:t,orientation:"vertical",...e}));c.displayName=a.Root.displayName;const l=o.forwardRef(({className:e,...t},i)=>n.jsxRuntimeExports.jsx(a.List,{ref:i,className:r.cn("group flex flex-col list-none items-center justify-center pb-16 px-8",e),...t}));l.displayName=a.List.displayName;function g({className:e,...t}){return n.jsxRuntimeExports.jsx("div",{className:r.cn("flex items-start justify-start text-sm text-gray-800 mt-16 mb-2 px-24",e),...t})}function v({...e}){return n.jsxRuntimeExports.jsx(x.Separator,{...e})}const m=o.forwardRef(({className:e,...t},i)=>n.jsxRuntimeExports.jsx(a.Item,{ref:i,className:r.cn("w-full",e),...t}));m.displayName=a.Item.displayName;const d=o.forwardRef(({className:e,...t},i)=>n.jsxRuntimeExports.jsx(a.Link,{ref:i,className:r.cn("flex justify-start px-12 py-[10px] w-full font-normal text-gray-800 rounded hover:bg-gray-200 hover:text-purple-800 hover:font-medium focus-visible:outline-none focus-visible:bg-gray-200 focus-visible:text-purple-800 focus-visible:font-medium data-[active]:bg-purple-100 data-[active]:text-purple-800 data-[active]:font-medium",e),...t}));exports.VerticalNavigationMenu=c;exports.VerticalNavigationMenuHeading=g;exports.VerticalNavigationMenuItem=m;exports.VerticalNavigationMenuLink=d;exports.VerticalNavigationMenuList=l;exports.VerticalNavigationMenuSeparator=v;
2
2
  //# sourceMappingURL=index.cjs35.js.map