@codefast/ui 0.0.50 → 0.0.52

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 (281) hide show
  1. package/dist/{chunk-ZTEJNUH6.js → chunk-46W6RAYD.js} +1 -1
  2. package/dist/chunk-46W6RAYD.js.map +1 -0
  3. package/dist/{chunk-CERSQE5J.js → chunk-4JHGPRLG.js} +1 -1
  4. package/dist/chunk-4JHGPRLG.js.map +1 -0
  5. package/dist/{chunk-I6QCJDIF.mjs → chunk-5RENVAXH.mjs} +1 -1
  6. package/dist/chunk-5RENVAXH.mjs.map +1 -0
  7. package/dist/{chunk-47CSACCM.mjs → chunk-7ABWX5CF.mjs} +2 -2
  8. package/dist/chunk-7ABWX5CF.mjs.map +1 -0
  9. package/dist/{chunk-XHNT6PVI.mjs → chunk-BM5KYF6Y.mjs} +1 -1
  10. package/dist/chunk-BM5KYF6Y.mjs.map +1 -0
  11. package/dist/{chunk-P5AV3QU7.mjs → chunk-BNKSZEF2.mjs} +1 -1
  12. package/dist/chunk-BNKSZEF2.mjs.map +1 -0
  13. package/dist/{chunk-SDGUDONZ.js → chunk-DCDB56BO.js} +1 -1
  14. package/dist/chunk-DCDB56BO.js.map +1 -0
  15. package/dist/{chunk-6FL3EBDQ.mjs → chunk-HMD2ZU33.mjs} +1 -1
  16. package/dist/chunk-HMD2ZU33.mjs.map +1 -0
  17. package/dist/{chunk-JOBEKA4M.mjs → chunk-K63K4LTH.mjs} +2 -2
  18. package/dist/chunk-K63K4LTH.mjs.map +1 -0
  19. package/dist/{chunk-VXPAGNPJ.js → chunk-LJSD47ZL.js} +1 -1
  20. package/dist/chunk-LJSD47ZL.js.map +1 -0
  21. package/dist/{chunk-GDMHMSJ2.mjs → chunk-MFYACCZV.mjs} +1 -1
  22. package/dist/chunk-MFYACCZV.mjs.map +1 -0
  23. package/dist/{chunk-LG7ACTRE.js → chunk-PRCS3RWN.js} +1 -1
  24. package/dist/chunk-PRCS3RWN.js.map +1 -0
  25. package/dist/{chunk-OP6Q7VT5.js → chunk-RHFF4JNH.js} +1 -1
  26. package/dist/chunk-RHFF4JNH.js.map +1 -0
  27. package/dist/{chunk-SCPFGC2X.js → chunk-SCXRD727.js} +1 -1
  28. package/dist/chunk-SCXRD727.js.map +1 -0
  29. package/dist/{chunk-X3LRJQM3.js → chunk-VZVI3OHH.js} +2 -2
  30. package/dist/chunk-VZVI3OHH.js.map +1 -0
  31. package/dist/{chunk-UYRRHPPH.js → chunk-X4BEEJEW.js} +2 -2
  32. package/dist/chunk-X4BEEJEW.js.map +1 -0
  33. package/dist/{chunk-PWF46YXQ.mjs → chunk-Y2GMHG3Z.mjs} +1 -1
  34. package/dist/chunk-Y2GMHG3Z.mjs.map +1 -0
  35. package/dist/{chunk-MU2MZ434.mjs → chunk-ZIB4ZTST.mjs} +1 -1
  36. package/dist/chunk-ZIB4ZTST.mjs.map +1 -0
  37. package/dist/plugin/animate.plugin.js +1 -1
  38. package/dist/plugin/animate.plugin.mjs +1 -1
  39. package/dist/react/accordion.js.map +1 -1
  40. package/dist/react/accordion.mjs.map +1 -1
  41. package/dist/react/alert-dialog.js +1 -1
  42. package/dist/react/alert-dialog.js.map +1 -1
  43. package/dist/react/alert-dialog.mjs +1 -1
  44. package/dist/react/alert-dialog.mjs.map +1 -1
  45. package/dist/react/alert.js.map +1 -1
  46. package/dist/react/alert.mjs.map +1 -1
  47. package/dist/react/aspect-ratio.d.mts +1 -1
  48. package/dist/react/aspect-ratio.d.ts +1 -1
  49. package/dist/react/aspect-ratio.js.map +1 -1
  50. package/dist/react/aspect-ratio.mjs.map +1 -1
  51. package/dist/react/avatar.js.map +1 -1
  52. package/dist/react/avatar.mjs.map +1 -1
  53. package/dist/react/badge.js.map +1 -1
  54. package/dist/react/badge.mjs.map +1 -1
  55. package/dist/react/blockquote.js.map +1 -1
  56. package/dist/react/blockquote.mjs.map +1 -1
  57. package/dist/react/box.js.map +1 -1
  58. package/dist/react/box.mjs.map +1 -1
  59. package/dist/react/breadcrumb.js.map +1 -1
  60. package/dist/react/breadcrumb.mjs.map +1 -1
  61. package/dist/react/button.js +1 -1
  62. package/dist/react/button.mjs +1 -1
  63. package/dist/react/calendar.js +1 -1
  64. package/dist/react/calendar.js.map +1 -1
  65. package/dist/react/calendar.mjs +1 -1
  66. package/dist/react/calendar.mjs.map +1 -1
  67. package/dist/react/card.js.map +1 -1
  68. package/dist/react/card.mjs.map +1 -1
  69. package/dist/react/carousel.js +1 -1
  70. package/dist/react/carousel.js.map +1 -1
  71. package/dist/react/carousel.mjs +1 -1
  72. package/dist/react/carousel.mjs.map +1 -1
  73. package/dist/react/checkbox-cards.js +1 -1
  74. package/dist/react/checkbox-cards.js.map +1 -1
  75. package/dist/react/checkbox-cards.mjs +1 -1
  76. package/dist/react/checkbox-cards.mjs.map +1 -1
  77. package/dist/react/checkbox-group.js +1 -1
  78. package/dist/react/checkbox-group.js.map +1 -1
  79. package/dist/react/checkbox-group.mjs +1 -1
  80. package/dist/react/checkbox-group.mjs.map +1 -1
  81. package/dist/react/checkbox-group.primitive.js +1 -1
  82. package/dist/react/checkbox-group.primitive.mjs +1 -1
  83. package/dist/react/checkbox.js.map +1 -1
  84. package/dist/react/checkbox.mjs.map +1 -1
  85. package/dist/react/code.js.map +1 -1
  86. package/dist/react/code.mjs.map +1 -1
  87. package/dist/react/collapsible.js.map +1 -1
  88. package/dist/react/collapsible.mjs.map +1 -1
  89. package/dist/react/command.d.mts +8 -8
  90. package/dist/react/command.d.ts +8 -8
  91. package/dist/react/command.js +1 -1
  92. package/dist/react/command.js.map +1 -1
  93. package/dist/react/command.mjs +1 -1
  94. package/dist/react/command.mjs.map +1 -1
  95. package/dist/react/container.js.map +1 -1
  96. package/dist/react/container.mjs.map +1 -1
  97. package/dist/react/context-menu.js.map +1 -1
  98. package/dist/react/context-menu.mjs.map +1 -1
  99. package/dist/react/data-table.d.mts +1 -1
  100. package/dist/react/data-table.d.ts +1 -1
  101. package/dist/react/data-table.js +1 -1
  102. package/dist/react/data-table.js.map +1 -1
  103. package/dist/react/data-table.mjs +1 -1
  104. package/dist/react/data-table.mjs.map +1 -1
  105. package/dist/react/dialog.js +1 -1
  106. package/dist/react/dialog.mjs +1 -1
  107. package/dist/react/drawer.js.map +1 -1
  108. package/dist/react/drawer.mjs.map +1 -1
  109. package/dist/react/dropdown-menu.js +1 -1
  110. package/dist/react/dropdown-menu.mjs +1 -1
  111. package/dist/react/em.js.map +1 -1
  112. package/dist/react/em.mjs.map +1 -1
  113. package/dist/react/form.js +1 -1
  114. package/dist/react/form.js.map +1 -1
  115. package/dist/react/form.mjs +1 -1
  116. package/dist/react/form.mjs.map +1 -1
  117. package/dist/react/heading.js.map +1 -1
  118. package/dist/react/heading.mjs.map +1 -1
  119. package/dist/react/hover-card.js.map +1 -1
  120. package/dist/react/hover-card.mjs.map +1 -1
  121. package/dist/react/input-otp.js.map +1 -1
  122. package/dist/react/input-otp.mjs.map +1 -1
  123. package/dist/react/input.js.map +1 -1
  124. package/dist/react/input.mjs.map +1 -1
  125. package/dist/react/kbd.js.map +1 -1
  126. package/dist/react/kbd.mjs.map +1 -1
  127. package/dist/react/label.js +1 -1
  128. package/dist/react/label.mjs +1 -1
  129. package/dist/react/menubar.js.map +1 -1
  130. package/dist/react/menubar.mjs.map +1 -1
  131. package/dist/react/navigation-menu.js.map +1 -1
  132. package/dist/react/navigation-menu.mjs.map +1 -1
  133. package/dist/react/pagination.js +1 -1
  134. package/dist/react/pagination.js.map +1 -1
  135. package/dist/react/pagination.mjs +1 -1
  136. package/dist/react/pagination.mjs.map +1 -1
  137. package/dist/react/popover.js.map +1 -1
  138. package/dist/react/popover.mjs.map +1 -1
  139. package/dist/react/pre.js.map +1 -1
  140. package/dist/react/pre.mjs.map +1 -1
  141. package/dist/react/progress.js.map +1 -1
  142. package/dist/react/progress.mjs.map +1 -1
  143. package/dist/react/quote.js.map +1 -1
  144. package/dist/react/quote.mjs.map +1 -1
  145. package/dist/react/radio-cards.js.map +1 -1
  146. package/dist/react/radio-cards.mjs.map +1 -1
  147. package/dist/react/radio-group.js.map +1 -1
  148. package/dist/react/radio-group.mjs.map +1 -1
  149. package/dist/react/radio.js.map +1 -1
  150. package/dist/react/radio.mjs.map +1 -1
  151. package/dist/react/resizable.js.map +1 -1
  152. package/dist/react/resizable.mjs.map +1 -1
  153. package/dist/react/scroll-area.js.map +1 -1
  154. package/dist/react/scroll-area.mjs.map +1 -1
  155. package/dist/react/section.js.map +1 -1
  156. package/dist/react/section.mjs.map +1 -1
  157. package/dist/react/select.js +1 -1
  158. package/dist/react/select.mjs +1 -1
  159. package/dist/react/separator.js.map +1 -1
  160. package/dist/react/separator.mjs.map +1 -1
  161. package/dist/react/sheet.js +1 -1
  162. package/dist/react/sheet.js.map +1 -1
  163. package/dist/react/sheet.mjs +1 -1
  164. package/dist/react/sheet.mjs.map +1 -1
  165. package/dist/react/skeleton.js.map +1 -1
  166. package/dist/react/skeleton.mjs.map +1 -1
  167. package/dist/react/slider.js.map +1 -1
  168. package/dist/react/slider.mjs.map +1 -1
  169. package/dist/react/sonner.js.map +1 -1
  170. package/dist/react/sonner.mjs.map +1 -1
  171. package/dist/react/spinner.js +1 -1
  172. package/dist/react/spinner.mjs +1 -1
  173. package/dist/react/strong.js.map +1 -1
  174. package/dist/react/strong.mjs.map +1 -1
  175. package/dist/react/switch.js.map +1 -1
  176. package/dist/react/switch.mjs.map +1 -1
  177. package/dist/react/table.js.map +1 -1
  178. package/dist/react/table.mjs.map +1 -1
  179. package/dist/react/tabs.js.map +1 -1
  180. package/dist/react/tabs.mjs.map +1 -1
  181. package/dist/react/text.js.map +1 -1
  182. package/dist/react/text.mjs.map +1 -1
  183. package/dist/react/textarea.js.map +1 -1
  184. package/dist/react/textarea.mjs.map +1 -1
  185. package/dist/react/toggle-group.js +1 -1
  186. package/dist/react/toggle-group.js.map +1 -1
  187. package/dist/react/toggle-group.mjs +1 -1
  188. package/dist/react/toggle-group.mjs.map +1 -1
  189. package/dist/react/toggle.js +1 -1
  190. package/dist/react/toggle.mjs +1 -1
  191. package/dist/react/tooltip.js.map +1 -1
  192. package/dist/react/tooltip.mjs.map +1 -1
  193. package/dist/styles.css.map +1 -1
  194. package/dist/tailwind.config.js +1 -1
  195. package/dist/tailwind.config.js.map +1 -1
  196. package/dist/tailwind.config.mjs +1 -1
  197. package/dist/tailwind.config.mjs.map +1 -1
  198. package/package.json +6 -6
  199. package/plugin/animate.plugin.ts +2 -5
  200. package/src/react/accordion.tsx +36 -60
  201. package/src/react/alert-dialog.tsx +57 -125
  202. package/src/react/alert.tsx +16 -42
  203. package/src/react/aspect-ratio.tsx +2 -4
  204. package/src/react/avatar.tsx +15 -43
  205. package/src/react/badge.tsx +3 -8
  206. package/src/react/blockquote.tsx +5 -8
  207. package/src/react/box.tsx +4 -6
  208. package/src/react/breadcrumb.tsx +17 -50
  209. package/src/react/button.tsx +5 -20
  210. package/src/react/calendar.tsx +5 -22
  211. package/src/react/card.tsx +22 -56
  212. package/src/react/carousel.tsx +20 -76
  213. package/src/react/checkbox-cards.tsx +28 -55
  214. package/src/react/checkbox-group.primitive.tsx +24 -78
  215. package/src/react/checkbox-group.tsx +26 -49
  216. package/src/react/checkbox.tsx +15 -19
  217. package/src/react/code.tsx +4 -6
  218. package/src/react/collapsible.tsx +19 -29
  219. package/src/react/command.tsx +69 -134
  220. package/src/react/container.tsx +5 -9
  221. package/src/react/context-menu.tsx +146 -224
  222. package/src/react/data-table.tsx +16 -44
  223. package/src/react/dialog.tsx +45 -90
  224. package/src/react/drawer.tsx +44 -91
  225. package/src/react/dropdown-menu.tsx +126 -194
  226. package/src/react/em.tsx +4 -6
  227. package/src/react/form.tsx +49 -84
  228. package/src/react/heading.tsx +4 -6
  229. package/src/react/hover-card.tsx +22 -38
  230. package/src/react/input-otp.tsx +26 -37
  231. package/src/react/input.tsx +6 -16
  232. package/src/react/kbd.tsx +14 -16
  233. package/src/react/label.tsx +11 -12
  234. package/src/react/menubar.tsx +129 -208
  235. package/src/react/navigation-menu.tsx +105 -147
  236. package/src/react/pagination.tsx +18 -50
  237. package/src/react/popover.tsx +25 -40
  238. package/src/react/pre.tsx +4 -6
  239. package/src/react/progress.tsx +15 -22
  240. package/src/react/quote.tsx +4 -6
  241. package/src/react/radio-cards.tsx +7 -27
  242. package/src/react/radio-group.tsx +7 -27
  243. package/src/react/radio.tsx +14 -18
  244. package/src/react/resizable.tsx +2 -7
  245. package/src/react/scroll-area.tsx +30 -52
  246. package/src/react/section.tsx +4 -6
  247. package/src/react/select.tsx +108 -161
  248. package/src/react/separator.tsx +3 -12
  249. package/src/react/sheet.tsx +21 -71
  250. package/src/react/skeleton.tsx +1 -6
  251. package/src/react/slider.tsx +20 -27
  252. package/src/react/sonner.tsx +2 -4
  253. package/src/react/spinner.tsx +2 -7
  254. package/src/react/strong.tsx +4 -6
  255. package/src/react/switch.tsx +12 -14
  256. package/src/react/table.tsx +37 -82
  257. package/src/react/tabs.tsx +34 -44
  258. package/src/react/text.tsx +5 -8
  259. package/src/react/textarea.tsx +12 -14
  260. package/src/react/toggle-group.tsx +16 -57
  261. package/src/react/toggle.tsx +8 -15
  262. package/src/react/tooltip.tsx +24 -39
  263. package/tailwind.config.ts +2 -2
  264. package/dist/chunk-47CSACCM.mjs.map +0 -1
  265. package/dist/chunk-6FL3EBDQ.mjs.map +0 -1
  266. package/dist/chunk-CERSQE5J.js.map +0 -1
  267. package/dist/chunk-GDMHMSJ2.mjs.map +0 -1
  268. package/dist/chunk-I6QCJDIF.mjs.map +0 -1
  269. package/dist/chunk-JOBEKA4M.mjs.map +0 -1
  270. package/dist/chunk-LG7ACTRE.js.map +0 -1
  271. package/dist/chunk-MU2MZ434.mjs.map +0 -1
  272. package/dist/chunk-OP6Q7VT5.js.map +0 -1
  273. package/dist/chunk-P5AV3QU7.mjs.map +0 -1
  274. package/dist/chunk-PWF46YXQ.mjs.map +0 -1
  275. package/dist/chunk-SCPFGC2X.js.map +0 -1
  276. package/dist/chunk-SDGUDONZ.js.map +0 -1
  277. package/dist/chunk-UYRRHPPH.js.map +0 -1
  278. package/dist/chunk-VXPAGNPJ.js.map +0 -1
  279. package/dist/chunk-X3LRJQM3.js.map +0 -1
  280. package/dist/chunk-XHNT6PVI.mjs.map +0 -1
  281. package/dist/chunk-ZTEJNUH6.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/input-otp.tsx"],"names":["React","DotFilledIcon","OTPInput","OTPInputContext","REGEXP_ONLY_CHARS","REGEXP_ONLY_DIGITS","REGEXP_ONLY_DIGITS_AND_CHARS","jsx","jsxs","InputOTP","className","containerClassName","props","ref","cn","InputOTPGroup","InputOTPSlot","index","slot","InputOTPSeparator"],"mappings":"sDAEA,UAAYA,MAAW,QACvB,OAAS,iBAAAC,MAAqB,wBAC9B,OACE,YAAAC,EACA,mBAAAC,EACA,qBAAAC,EACA,sBAAAC,EACA,gCAAAC,MACK,YAYH,cAAAC,EA8CE,QAAAC,MA9CF,oBAFJ,IAAMC,EAAiB,aACrB,CAAC,CAAE,UAAAC,EAAW,mBAAAC,EAAoB,GAAGC,CAAM,EAAGC,IAC5CN,EAACL,EAAA,CACC,IAAKW,EACL,mBAAoBC,EAClB,qDACAH,CACF,EACA,UAAWG,EAAG,8BAA+BJ,CAAS,EACrD,GAAGE,EACN,CAEJ,EAEAH,EAAS,YAAc,WASvB,IAAMM,EAAsB,aAG1B,CAAC,CAAE,UAAAL,EAAW,GAAGE,CAAM,EAAGC,IAC1BN,EAAC,OAAI,IAAKM,EAAK,UAAWC,EAAG,oBAAqBJ,CAAS,EAAI,GAAGE,EAAO,CAC1E,EAEDG,EAAc,YAAc,gBAY5B,IAAMC,EAAqB,aACzB,CAAC,CAAE,MAAAC,EAAO,UAAAP,EAAW,GAAGE,CAAM,EAAGC,IAAQ,CAEvC,IAAMK,EADwB,aAAWf,CAAe,EAC3B,MAAMc,CAAK,EAExC,OACET,EAAC,OACC,IAAKK,EACL,UAAWC,EACT,8JACAI,GAAM,UAAY,yBAClBR,CACF,EACC,GAAGE,EAEH,UAAAM,GAAM,KACNA,GAAM,aACLX,EAAC,OAAI,UAAU,wEACb,SAAAA,EAAC,OAAI,UAAU,mEAAmE,EACpF,EACE,MACN,CAEJ,CACF,EAEAS,EAAa,YAAc,eAS3B,IAAMG,EAA0B,aAG9B,CAAC,CAAE,GAAGP,CAAM,EAAGC,IACfN,EAAC,OAAI,IAAKM,EAAK,KAAK,YAAa,GAAGD,EAClC,SAAAL,EAACN,EAAA,EAAc,EACjB,CACD,EAEDkB,EAAkB,YAAc","sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { DotFilledIcon } from '@radix-ui/react-icons';\nimport {\n OTPInput,\n OTPInputContext,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n} from 'input-otp';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOtp\n * -------------------------------------------------------------------------- */\n\ntype InputOTPElement = React.ElementRef<typeof OTPInput>;\ntype InputOTPProps = React.ComponentPropsWithoutRef<typeof OTPInput>;\n\nconst InputOTP = React.forwardRef<InputOTPElement, InputOTPProps>(\n ({ className, containerClassName, ...props }, ref) => (\n <OTPInput\n ref={ref}\n containerClassName={cn(\n 'flex items-center gap-2 has-[:disabled]:opacity-50',\n containerClassName,\n )}\n className={cn('disabled:cursor-not-allowed', className)}\n {...props}\n />\n ),\n);\n\nInputOTP.displayName = 'InputOTP';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPGroup\n * -------------------------------------------------------------------------- */\n\ntype InputOTPGroupElement = HTMLDivElement;\ntype InputOTPGroupProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPGroup = React.forwardRef<\n InputOTPGroupElement,\n InputOTPGroupProps\n>(({ className, ...props }, ref) => (\n <div ref={ref} className={cn('flex items-center', className)} {...props} />\n));\n\nInputOTPGroup.displayName = 'InputOTPGroup';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSlot\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSlotElement = HTMLDivElement;\n\ninterface InputOTPSlotProps extends React.HTMLAttributes<HTMLDivElement> {\n index: number;\n}\n\nconst InputOTPSlot = React.forwardRef<InputOTPSlotElement, InputOTPSlotProps>(\n ({ index, className, ...props }, ref) => {\n const inputOTPContext = React.useContext(OTPInputContext);\n const slot = inputOTPContext.slots[index];\n\n return (\n <div\n ref={ref}\n className={cn(\n 'border-input relative flex size-10 items-center justify-center border-y border-r text-sm transition-all first:rounded-l-md first:border-l last:rounded-r-md',\n slot?.isActive && 'z-10 outline outline-2',\n className,\n )}\n {...props}\n >\n {slot?.char}\n {slot?.hasFakeCaret ? (\n <div className=\"pointer-events-none absolute inset-0 flex items-center justify-center\">\n <div className=\"animate-caret-blink bg-foreground animate-duration-1000 h-4 w-px\" />\n </div>\n ) : null}\n </div>\n );\n },\n);\n\nInputOTPSlot.displayName = 'InputOTPSlot';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSeparator\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSeparatorElement = HTMLDivElement;\ntype InputOTPSeparatorProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPSeparator = React.forwardRef<\n InputOTPSeparatorElement,\n InputOTPSeparatorProps\n>(({ ...props }, ref) => (\n <div ref={ref} role=\"separator\" {...props}>\n <DotFilledIcon />\n </div>\n));\n\nInputOTPSeparator.displayName = 'InputOTPSeparator';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n InputOTP,\n InputOTPGroup,\n InputOTPSlot,\n InputOTPSeparator,\n type InputOTPProps,\n type InputOTPGroupProps,\n type InputOTPSlotProps,\n type InputOTPSeparatorProps,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n};\n"]}
1
+ {"version":3,"sources":["../../src/react/input-otp.tsx"],"names":["React","DotFilledIcon","OTPInput","OTPInputContext","REGEXP_ONLY_CHARS","REGEXP_ONLY_DIGITS","REGEXP_ONLY_DIGITS_AND_CHARS","jsx","jsxs","InputOTP","className","containerClassName","props","ref","cn","InputOTPGroup","InputOTPSlot","index","slot","InputOTPSeparator"],"mappings":"sDAEA,UAAYA,MAAW,QACvB,OAAS,iBAAAC,MAAqB,wBAC9B,OACE,YAAAC,EACA,mBAAAC,EACA,qBAAAC,EACA,sBAAAC,EACA,gCAAAC,MACK,YAYH,cAAAC,EAuCA,QAAAC,MAvCA,oBAFJ,IAAMC,EAAiB,aACrB,CAAC,CAAE,UAAAC,EAAW,mBAAAC,EAAoB,GAAGC,CAAM,EAAGC,IAC5CN,EAACL,EAAA,CACC,IAAKW,EACL,mBAAoBC,EAAG,qDAAsDH,CAAkB,EAC/F,UAAWG,EAAG,8BAA+BJ,CAAS,EACrD,GAAGE,EACN,CAEJ,EAEAH,EAAS,YAAc,WASvB,IAAMM,EAAsB,aAAqD,CAAC,CAAE,UAAAL,EAAW,GAAGE,CAAM,EAAGC,IACzGN,EAAC,OAAI,IAAKM,EAAK,UAAWC,EAAG,oBAAqBJ,CAAS,EAAI,GAAGE,EAAO,CAC1E,EAEDG,EAAc,YAAc,gBAY5B,IAAMC,EAAqB,aAAmD,CAAC,CAAE,MAAAC,EAAO,UAAAP,EAAW,GAAGE,CAAM,EAAGC,IAAQ,CAErH,IAAMK,EADwB,aAAWf,CAAe,EAC3B,MAAMc,CAAK,EAExC,OACET,EAAC,OACC,IAAKK,EACL,UAAWC,EACT,8JACAI,GAAM,UAAY,yBAClBR,CACF,EACC,GAAGE,EAEH,UAAAM,GAAM,KACNA,GAAM,aACLX,EAAC,OAAI,UAAU,wEACb,SAAAA,EAAC,OAAI,UAAU,mEAAmE,EACpF,EACE,MACN,CAEJ,CAAC,EAEDS,EAAa,YAAc,eAS3B,IAAMG,EAA0B,aAA6D,CAAC,CAAE,GAAGP,CAAM,EAAGC,IAC1GN,EAAC,OAAI,IAAKM,EAAK,KAAK,YAAa,GAAGD,EAClC,SAAAL,EAACN,EAAA,EAAc,EACjB,CACD,EAEDkB,EAAkB,YAAc","sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { DotFilledIcon } from '@radix-ui/react-icons';\nimport {\n OTPInput,\n OTPInputContext,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n} from 'input-otp';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOtp\n * -------------------------------------------------------------------------- */\n\ntype InputOTPElement = React.ElementRef<typeof OTPInput>;\ntype InputOTPProps = React.ComponentPropsWithoutRef<typeof OTPInput>;\n\nconst InputOTP = React.forwardRef<InputOTPElement, InputOTPProps>(\n ({ className, containerClassName, ...props }, ref) => (\n <OTPInput\n ref={ref}\n containerClassName={cn('flex items-center gap-2 has-[:disabled]:opacity-50', containerClassName)}\n className={cn('disabled:cursor-not-allowed', className)}\n {...props}\n />\n ),\n);\n\nInputOTP.displayName = 'InputOTP';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPGroup\n * -------------------------------------------------------------------------- */\n\ntype InputOTPGroupElement = HTMLDivElement;\ntype InputOTPGroupProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPGroup = React.forwardRef<InputOTPGroupElement, InputOTPGroupProps>(({ className, ...props }, ref) => (\n <div ref={ref} className={cn('flex items-center', className)} {...props} />\n));\n\nInputOTPGroup.displayName = 'InputOTPGroup';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSlot\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSlotElement = HTMLDivElement;\n\ninterface InputOTPSlotProps extends React.HTMLAttributes<HTMLDivElement> {\n index: number;\n}\n\nconst InputOTPSlot = React.forwardRef<InputOTPSlotElement, InputOTPSlotProps>(({ index, className, ...props }, ref) => {\n const inputOTPContext = React.useContext(OTPInputContext);\n const slot = inputOTPContext.slots[index];\n\n return (\n <div\n ref={ref}\n className={cn(\n 'border-input relative flex size-10 items-center justify-center border-y border-r text-sm transition-all first:rounded-l-md first:border-l last:rounded-r-md',\n slot?.isActive && 'z-10 outline outline-2',\n className,\n )}\n {...props}\n >\n {slot?.char}\n {slot?.hasFakeCaret ? (\n <div className=\"pointer-events-none absolute inset-0 flex items-center justify-center\">\n <div className=\"animate-caret-blink bg-foreground animate-duration-1000 h-4 w-px\" />\n </div>\n ) : null}\n </div>\n );\n});\n\nInputOTPSlot.displayName = 'InputOTPSlot';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSeparator\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSeparatorElement = HTMLDivElement;\ntype InputOTPSeparatorProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPSeparator = React.forwardRef<InputOTPSeparatorElement, InputOTPSeparatorProps>(({ ...props }, ref) => (\n <div ref={ref} role=\"separator\" {...props}>\n <DotFilledIcon />\n </div>\n));\n\nInputOTPSeparator.displayName = 'InputOTPSeparator';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n InputOTP,\n InputOTPGroup,\n InputOTPSlot,\n InputOTPSeparator,\n type InputOTPProps,\n type InputOTPGroupProps,\n type InputOTPSlotProps,\n type InputOTPSeparatorProps,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/input-otp.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { DotFilledIcon } from '@radix-ui/react-icons';\nimport {\n OTPInput,\n OTPInputContext,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n} from 'input-otp';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOtp\n * -------------------------------------------------------------------------- */\n\ntype InputOTPElement = React.ElementRef<typeof OTPInput>;\ntype InputOTPProps = React.ComponentPropsWithoutRef<typeof OTPInput>;\n\nconst InputOTP = React.forwardRef<InputOTPElement, InputOTPProps>(\n ({ className, containerClassName, ...props }, ref) => (\n <OTPInput\n ref={ref}\n containerClassName={cn(\n 'flex items-center gap-2 has-[:disabled]:opacity-50',\n containerClassName,\n )}\n className={cn('disabled:cursor-not-allowed', className)}\n {...props}\n />\n ),\n);\n\nInputOTP.displayName = 'InputOTP';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPGroup\n * -------------------------------------------------------------------------- */\n\ntype InputOTPGroupElement = HTMLDivElement;\ntype InputOTPGroupProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPGroup = React.forwardRef<\n InputOTPGroupElement,\n InputOTPGroupProps\n>(({ className, ...props }, ref) => (\n <div ref={ref} className={cn('flex items-center', className)} {...props} />\n));\n\nInputOTPGroup.displayName = 'InputOTPGroup';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSlot\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSlotElement = HTMLDivElement;\n\ninterface InputOTPSlotProps extends React.HTMLAttributes<HTMLDivElement> {\n index: number;\n}\n\nconst InputOTPSlot = React.forwardRef<InputOTPSlotElement, InputOTPSlotProps>(\n ({ index, className, ...props }, ref) => {\n const inputOTPContext = React.useContext(OTPInputContext);\n const slot = inputOTPContext.slots[index];\n\n return (\n <div\n ref={ref}\n className={cn(\n 'border-input relative flex size-10 items-center justify-center border-y border-r text-sm transition-all first:rounded-l-md first:border-l last:rounded-r-md',\n slot?.isActive && 'z-10 outline outline-2',\n className,\n )}\n {...props}\n >\n {slot?.char}\n {slot?.hasFakeCaret ? (\n <div className=\"pointer-events-none absolute inset-0 flex items-center justify-center\">\n <div className=\"animate-caret-blink bg-foreground animate-duration-1000 h-4 w-px\" />\n </div>\n ) : null}\n </div>\n );\n },\n);\n\nInputOTPSlot.displayName = 'InputOTPSlot';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSeparator\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSeparatorElement = HTMLDivElement;\ntype InputOTPSeparatorProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPSeparator = React.forwardRef<\n InputOTPSeparatorElement,\n InputOTPSeparatorProps\n>(({ ...props }, ref) => (\n <div ref={ref} role=\"separator\" {...props}>\n <DotFilledIcon />\n </div>\n));\n\nInputOTPSeparator.displayName = 'InputOTPSeparator';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n InputOTP,\n InputOTPGroup,\n InputOTPSlot,\n InputOTPSeparator,\n type InputOTPProps,\n type InputOTPGroupProps,\n type InputOTPSlotProps,\n type InputOTPSeparatorProps,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n};\n"],"mappings":"uDAEA,UAAYA,MAAW,QACvB,OAAS,iBAAAC,MAAqB,wBAC9B,OACE,YAAAC,EACA,mBAAAC,EACA,qBAAAC,EACA,sBAAAC,EACA,gCAAAC,MACK,YAYH,cAAAC,EA8CE,QAAAC,MA9CF,oBAFJ,IAAMC,EAAiB,aACrB,CAAC,CAAE,UAAAC,EAAW,mBAAAC,EAAoB,GAAGC,CAAM,EAAGC,IAC5CN,EAACO,EAAA,CACC,IAAKD,EACL,mBAAoBE,EAClB,qDACAJ,CACF,EACA,UAAWI,EAAG,8BAA+BL,CAAS,EACrD,GAAGE,EACN,CAEJ,EAEAH,EAAS,YAAc,WASvB,IAAMO,EAAsB,aAG1B,CAAC,CAAE,UAAAN,EAAW,GAAGE,CAAM,EAAGC,IAC1BN,EAAC,OAAI,IAAKM,EAAK,UAAWE,EAAG,oBAAqBL,CAAS,EAAI,GAAGE,EAAO,CAC1E,EAEDI,EAAc,YAAc,gBAY5B,IAAMC,EAAqB,aACzB,CAAC,CAAE,MAAAC,EAAO,UAAAR,EAAW,GAAGE,CAAM,EAAGC,IAAQ,CAEvC,IAAMM,EADwB,aAAWC,CAAe,EAC3B,MAAMF,CAAK,EAExC,OACEV,EAAC,OACC,IAAKK,EACL,UAAWE,EACT,8JACAI,GAAM,UAAY,yBAClBT,CACF,EACC,GAAGE,EAEH,UAAAO,GAAM,KACNA,GAAM,aACLZ,EAAC,OAAI,UAAU,wEACb,SAAAA,EAAC,OAAI,UAAU,mEAAmE,EACpF,EACE,MACN,CAEJ,CACF,EAEAU,EAAa,YAAc,eAS3B,IAAMI,EAA0B,aAG9B,CAAC,CAAE,GAAGT,CAAM,EAAGC,IACfN,EAAC,OAAI,IAAKM,EAAK,KAAK,YAAa,GAAGD,EAClC,SAAAL,EAACe,EAAA,EAAc,EACjB,CACD,EAEDD,EAAkB,YAAc","names":["React","DotFilledIcon","OTPInput","OTPInputContext","REGEXP_ONLY_CHARS","REGEXP_ONLY_DIGITS","REGEXP_ONLY_DIGITS_AND_CHARS","jsx","jsxs","InputOTP","className","containerClassName","props","ref","OTPInput","cn","InputOTPGroup","InputOTPSlot","index","slot","OTPInputContext","InputOTPSeparator","DotFilledIcon"]}
1
+ {"version":3,"sources":["../../src/react/input-otp.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { DotFilledIcon } from '@radix-ui/react-icons';\nimport {\n OTPInput,\n OTPInputContext,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n} from 'input-otp';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOtp\n * -------------------------------------------------------------------------- */\n\ntype InputOTPElement = React.ElementRef<typeof OTPInput>;\ntype InputOTPProps = React.ComponentPropsWithoutRef<typeof OTPInput>;\n\nconst InputOTP = React.forwardRef<InputOTPElement, InputOTPProps>(\n ({ className, containerClassName, ...props }, ref) => (\n <OTPInput\n ref={ref}\n containerClassName={cn('flex items-center gap-2 has-[:disabled]:opacity-50', containerClassName)}\n className={cn('disabled:cursor-not-allowed', className)}\n {...props}\n />\n ),\n);\n\nInputOTP.displayName = 'InputOTP';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPGroup\n * -------------------------------------------------------------------------- */\n\ntype InputOTPGroupElement = HTMLDivElement;\ntype InputOTPGroupProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPGroup = React.forwardRef<InputOTPGroupElement, InputOTPGroupProps>(({ className, ...props }, ref) => (\n <div ref={ref} className={cn('flex items-center', className)} {...props} />\n));\n\nInputOTPGroup.displayName = 'InputOTPGroup';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSlot\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSlotElement = HTMLDivElement;\n\ninterface InputOTPSlotProps extends React.HTMLAttributes<HTMLDivElement> {\n index: number;\n}\n\nconst InputOTPSlot = React.forwardRef<InputOTPSlotElement, InputOTPSlotProps>(({ index, className, ...props }, ref) => {\n const inputOTPContext = React.useContext(OTPInputContext);\n const slot = inputOTPContext.slots[index];\n\n return (\n <div\n ref={ref}\n className={cn(\n 'border-input relative flex size-10 items-center justify-center border-y border-r text-sm transition-all first:rounded-l-md first:border-l last:rounded-r-md',\n slot?.isActive && 'z-10 outline outline-2',\n className,\n )}\n {...props}\n >\n {slot?.char}\n {slot?.hasFakeCaret ? (\n <div className=\"pointer-events-none absolute inset-0 flex items-center justify-center\">\n <div className=\"animate-caret-blink bg-foreground animate-duration-1000 h-4 w-px\" />\n </div>\n ) : null}\n </div>\n );\n});\n\nInputOTPSlot.displayName = 'InputOTPSlot';\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSeparator\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSeparatorElement = HTMLDivElement;\ntype InputOTPSeparatorProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPSeparator = React.forwardRef<InputOTPSeparatorElement, InputOTPSeparatorProps>(({ ...props }, ref) => (\n <div ref={ref} role=\"separator\" {...props}>\n <DotFilledIcon />\n </div>\n));\n\nInputOTPSeparator.displayName = 'InputOTPSeparator';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n InputOTP,\n InputOTPGroup,\n InputOTPSlot,\n InputOTPSeparator,\n type InputOTPProps,\n type InputOTPGroupProps,\n type InputOTPSlotProps,\n type InputOTPSeparatorProps,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n};\n"],"mappings":"uDAEA,UAAYA,MAAW,QACvB,OAAS,iBAAAC,MAAqB,wBAC9B,OACE,YAAAC,EACA,mBAAAC,EACA,qBAAAC,EACA,sBAAAC,EACA,gCAAAC,MACK,YAYH,cAAAC,EAuCA,QAAAC,MAvCA,oBAFJ,IAAMC,EAAiB,aACrB,CAAC,CAAE,UAAAC,EAAW,mBAAAC,EAAoB,GAAGC,CAAM,EAAGC,IAC5CN,EAACO,EAAA,CACC,IAAKD,EACL,mBAAoBE,EAAG,qDAAsDJ,CAAkB,EAC/F,UAAWI,EAAG,8BAA+BL,CAAS,EACrD,GAAGE,EACN,CAEJ,EAEAH,EAAS,YAAc,WASvB,IAAMO,EAAsB,aAAqD,CAAC,CAAE,UAAAN,EAAW,GAAGE,CAAM,EAAGC,IACzGN,EAAC,OAAI,IAAKM,EAAK,UAAWE,EAAG,oBAAqBL,CAAS,EAAI,GAAGE,EAAO,CAC1E,EAEDI,EAAc,YAAc,gBAY5B,IAAMC,EAAqB,aAAmD,CAAC,CAAE,MAAAC,EAAO,UAAAR,EAAW,GAAGE,CAAM,EAAGC,IAAQ,CAErH,IAAMM,EADwB,aAAWC,CAAe,EAC3B,MAAMF,CAAK,EAExC,OACEV,EAAC,OACC,IAAKK,EACL,UAAWE,EACT,8JACAI,GAAM,UAAY,yBAClBT,CACF,EACC,GAAGE,EAEH,UAAAO,GAAM,KACNA,GAAM,aACLZ,EAAC,OAAI,UAAU,wEACb,SAAAA,EAAC,OAAI,UAAU,mEAAmE,EACpF,EACE,MACN,CAEJ,CAAC,EAEDU,EAAa,YAAc,eAS3B,IAAMI,EAA0B,aAA6D,CAAC,CAAE,GAAGT,CAAM,EAAGC,IAC1GN,EAAC,OAAI,IAAKM,EAAK,KAAK,YAAa,GAAGD,EAClC,SAAAL,EAACe,EAAA,EAAc,EACjB,CACD,EAEDD,EAAkB,YAAc","names":["React","DotFilledIcon","OTPInput","OTPInputContext","REGEXP_ONLY_CHARS","REGEXP_ONLY_DIGITS","REGEXP_ONLY_DIGITS_AND_CHARS","jsx","jsxs","InputOTP","className","containerClassName","props","ref","OTPInput","cn","InputOTPGroup","InputOTPSlot","index","slot","OTPInputContext","InputOTPSeparator","DotFilledIcon"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/input.tsx"],"names":["React","jsx","inputVariants","cva","Input","className","inputSize","props","ref"],"mappings":"yCAAA,UAAYA,MAAW,QAoCjB,cAAAC,MAAA,oBA5BN,IAAMC,EAAgBC,EAAI,CACxB,KAAM,kUACN,SAAU,CACR,UAAW,CACT,QAAS,OACT,GAAI,MACJ,GAAI,MACJ,GAAI,MACN,CACF,EACA,gBAAiB,CACf,UAAW,SACb,CACF,CAAC,EAYKC,EAAc,aAClB,CAAC,CAAE,UAAAC,EAAW,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAEjCP,EAAC,SACC,KAAK,OACL,UAAWC,EAAc,CAAE,UAAAG,EAAW,UAAAC,CAAU,CAAC,EACjD,IAAKE,EACJ,GAAGD,EACN,CAGN,EAEAH,EAAM,YAAc","sourcesContent":["import * as React from 'react';\nimport { type VariantProps } from 'cva';\nimport { cva } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Variant: Input\n * -------------------------------------------------------------------------- */\n\nconst inputVariants = cva({\n base: 'border-input placeholder:text-muted-foreground flex w-full rounded-md border bg-transparent px-3 py-2 text-sm shadow-sm transition file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 disabled:cursor-not-allowed disabled:opacity-50',\n variants: {\n inputSize: {\n default: 'h-10',\n xs: 'h-8',\n sm: 'h-9',\n lg: 'h-11',\n },\n },\n defaultVariants: {\n inputSize: 'default',\n },\n});\n\ntype InputVariantsProps = VariantProps<typeof inputVariants>;\n\n/* -----------------------------------------------------------------------------\n * Component: Input\n * -------------------------------------------------------------------------- */\n\ntype InputElement = HTMLInputElement;\ntype InputProps = React.InputHTMLAttributes<HTMLInputElement> &\n InputVariantsProps;\n\nconst Input = React.forwardRef<InputElement, InputProps>(\n ({ className, inputSize, ...props }, ref) => {\n return (\n <input\n type=\"text\"\n className={inputVariants({ className, inputSize })}\n ref={ref}\n {...props}\n />\n );\n },\n);\n\nInput.displayName = 'Input';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Input, type InputProps };\n"]}
1
+ {"version":3,"sources":["../../src/react/input.tsx"],"names":["React","jsx","inputVariants","cva","Input","className","inputSize","props","ref"],"mappings":"yCAAA,UAAYA,MAAW,QAiCd,cAAAC,MAAA,oBAzBT,IAAMC,EAAgBC,EAAI,CACxB,KAAM,kUACN,SAAU,CACR,UAAW,CACT,QAAS,OACT,GAAI,MACJ,GAAI,MACJ,GAAI,MACN,CACF,EACA,gBAAiB,CACf,UAAW,SACb,CACF,CAAC,EAWKC,EAAc,aAAqC,CAAC,CAAE,UAAAC,EAAW,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IACrFP,EAAC,SAAM,KAAK,OAAO,UAAWC,EAAc,CAAE,UAAAG,EAAW,UAAAC,CAAU,CAAC,EAAG,IAAKE,EAAM,GAAGD,EAAO,CACpG,EAEDH,EAAM,YAAc","sourcesContent":["import * as React from 'react';\nimport { cva } from '../lib/utils';\nimport type { VariantProps } from 'cva';\n\n/* -----------------------------------------------------------------------------\n * Variant: Input\n * -------------------------------------------------------------------------- */\n\nconst inputVariants = cva({\n base: 'border-input placeholder:text-muted-foreground flex w-full rounded-md border bg-transparent px-3 py-2 text-sm shadow-sm transition file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 disabled:cursor-not-allowed disabled:opacity-50',\n variants: {\n inputSize: {\n default: 'h-10',\n xs: 'h-8',\n sm: 'h-9',\n lg: 'h-11',\n },\n },\n defaultVariants: {\n inputSize: 'default',\n },\n});\n\ntype InputVariantsProps = VariantProps<typeof inputVariants>;\n\n/* -----------------------------------------------------------------------------\n * Component: Input\n * -------------------------------------------------------------------------- */\n\ntype InputElement = HTMLInputElement;\ntype InputProps = React.InputHTMLAttributes<HTMLInputElement> & InputVariantsProps;\n\nconst Input = React.forwardRef<InputElement, InputProps>(({ className, inputSize, ...props }, ref) => {\n return <input type=\"text\" className={inputVariants({ className, inputSize })} ref={ref} {...props} />;\n});\n\nInput.displayName = 'Input';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Input, type InputProps };\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/input.tsx"],"sourcesContent":["import * as React from 'react';\nimport { type VariantProps } from 'cva';\nimport { cva } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Variant: Input\n * -------------------------------------------------------------------------- */\n\nconst inputVariants = cva({\n base: 'border-input placeholder:text-muted-foreground flex w-full rounded-md border bg-transparent px-3 py-2 text-sm shadow-sm transition file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 disabled:cursor-not-allowed disabled:opacity-50',\n variants: {\n inputSize: {\n default: 'h-10',\n xs: 'h-8',\n sm: 'h-9',\n lg: 'h-11',\n },\n },\n defaultVariants: {\n inputSize: 'default',\n },\n});\n\ntype InputVariantsProps = VariantProps<typeof inputVariants>;\n\n/* -----------------------------------------------------------------------------\n * Component: Input\n * -------------------------------------------------------------------------- */\n\ntype InputElement = HTMLInputElement;\ntype InputProps = React.InputHTMLAttributes<HTMLInputElement> &\n InputVariantsProps;\n\nconst Input = React.forwardRef<InputElement, InputProps>(\n ({ className, inputSize, ...props }, ref) => {\n return (\n <input\n type=\"text\"\n className={inputVariants({ className, inputSize })}\n ref={ref}\n {...props}\n />\n );\n },\n);\n\nInput.displayName = 'Input';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Input, type InputProps };\n"],"mappings":"0CAAA,UAAYA,MAAW,QAoCjB,cAAAC,MAAA,oBA5BN,IAAMC,EAAgBC,EAAI,CACxB,KAAM,kUACN,SAAU,CACR,UAAW,CACT,QAAS,OACT,GAAI,MACJ,GAAI,MACJ,GAAI,MACN,CACF,EACA,gBAAiB,CACf,UAAW,SACb,CACF,CAAC,EAYKC,EAAc,aAClB,CAAC,CAAE,UAAAC,EAAW,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAEjCP,EAAC,SACC,KAAK,OACL,UAAWC,EAAc,CAAE,UAAAG,EAAW,UAAAC,CAAU,CAAC,EACjD,IAAKE,EACJ,GAAGD,EACN,CAGN,EAEAH,EAAM,YAAc","names":["React","jsx","inputVariants","cva","Input","className","inputSize","props","ref"]}
1
+ {"version":3,"sources":["../../src/react/input.tsx"],"sourcesContent":["import * as React from 'react';\nimport { cva } from '../lib/utils';\nimport type { VariantProps } from 'cva';\n\n/* -----------------------------------------------------------------------------\n * Variant: Input\n * -------------------------------------------------------------------------- */\n\nconst inputVariants = cva({\n base: 'border-input placeholder:text-muted-foreground flex w-full rounded-md border bg-transparent px-3 py-2 text-sm shadow-sm transition file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 disabled:cursor-not-allowed disabled:opacity-50',\n variants: {\n inputSize: {\n default: 'h-10',\n xs: 'h-8',\n sm: 'h-9',\n lg: 'h-11',\n },\n },\n defaultVariants: {\n inputSize: 'default',\n },\n});\n\ntype InputVariantsProps = VariantProps<typeof inputVariants>;\n\n/* -----------------------------------------------------------------------------\n * Component: Input\n * -------------------------------------------------------------------------- */\n\ntype InputElement = HTMLInputElement;\ntype InputProps = React.InputHTMLAttributes<HTMLInputElement> & InputVariantsProps;\n\nconst Input = React.forwardRef<InputElement, InputProps>(({ className, inputSize, ...props }, ref) => {\n return <input type=\"text\" className={inputVariants({ className, inputSize })} ref={ref} {...props} />;\n});\n\nInput.displayName = 'Input';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Input, type InputProps };\n"],"mappings":"0CAAA,UAAYA,MAAW,QAiCd,cAAAC,MAAA,oBAzBT,IAAMC,EAAgBC,EAAI,CACxB,KAAM,kUACN,SAAU,CACR,UAAW,CACT,QAAS,OACT,GAAI,MACJ,GAAI,MACJ,GAAI,MACN,CACF,EACA,gBAAiB,CACf,UAAW,SACb,CACF,CAAC,EAWKC,EAAc,aAAqC,CAAC,CAAE,UAAAC,EAAW,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IACrFP,EAAC,SAAM,KAAK,OAAO,UAAWC,EAAc,CAAE,UAAAG,EAAW,UAAAC,CAAU,CAAC,EAAG,IAAKE,EAAM,GAAGD,EAAO,CACpG,EAEDH,EAAM,YAAc","names":["React","jsx","inputVariants","cva","Input","className","inputSize","props","ref"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/kbd.tsx"],"names":["React","Slot","jsx","Kbd","asChild","className","props","ref","cn"],"mappings":"yCAAA,UAAYA,MAAW,QACvB,OAAS,QAAAC,MAAY,uBAkBf,cAAAC,MAAA,oBALN,IAAMC,EAAY,aAChB,CAAC,CAAE,QAAAC,EAAS,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAI/BL,EAHgBE,EAAUH,EAAO,MAGhC,CACC,IAAKM,EACL,UAAWC,EACT,oIACAH,CACF,EACC,GAAGC,EACN,CAGN,EAEAH,EAAI,YAAc","sourcesContent":["import * as React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: Kbd\n * -------------------------------------------------------------------------- */\n\ntype KbdElement = HTMLElement;\n\ninterface KbdProps extends React.HTMLAttributes<HTMLElement> {\n asChild?: boolean;\n}\n\nconst Kbd = React.forwardRef<KbdElement, KbdProps>(\n ({ asChild, className, ...props }, ref) => {\n const Component = asChild ? Slot : 'kbd';\n\n return (\n <Component\n ref={ref}\n className={cn(\n 'bg-muted text-muted-foreground inline-flex h-5 select-none items-center gap-1 rounded border px-1.5 font-mono text-xs font-medium',\n className,\n )}\n {...props}\n />\n );\n },\n);\n\nKbd.displayName = 'Kbd';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Kbd, type KbdProps };\n"]}
1
+ {"version":3,"sources":["../../src/react/kbd.tsx"],"names":["React","Slot","jsx","Kbd","asChild","className","props","ref","cn"],"mappings":"yCAAA,UAAYA,MAAW,QACvB,OAAS,QAAAC,MAAY,uBAiBjB,cAAAC,MAAA,oBAJJ,IAAMC,EAAY,aAAiC,CAAC,CAAE,QAAAC,EAAS,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAIlFL,EAHgBE,EAAUH,EAAO,MAGhC,CACC,IAAKM,EACL,UAAWC,EACT,oIACAH,CACF,EACC,GAAGC,EACN,CAEH,EAEDH,EAAI,YAAc","sourcesContent":["import * as React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: Kbd\n * -------------------------------------------------------------------------- */\n\ntype KbdElement = HTMLElement;\n\ninterface KbdProps extends React.HTMLAttributes<HTMLElement> {\n asChild?: boolean;\n}\n\nconst Kbd = React.forwardRef<KbdElement, KbdProps>(({ asChild, className, ...props }, ref) => {\n const Component = asChild ? Slot : 'kbd';\n\n return (\n <Component\n ref={ref}\n className={cn(\n 'bg-muted text-muted-foreground inline-flex h-5 select-none items-center gap-1 rounded border px-1.5 font-mono text-xs font-medium',\n className,\n )}\n {...props}\n />\n );\n});\n\nKbd.displayName = 'Kbd';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Kbd, type KbdProps };\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/kbd.tsx"],"sourcesContent":["import * as React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: Kbd\n * -------------------------------------------------------------------------- */\n\ntype KbdElement = HTMLElement;\n\ninterface KbdProps extends React.HTMLAttributes<HTMLElement> {\n asChild?: boolean;\n}\n\nconst Kbd = React.forwardRef<KbdElement, KbdProps>(\n ({ asChild, className, ...props }, ref) => {\n const Component = asChild ? Slot : 'kbd';\n\n return (\n <Component\n ref={ref}\n className={cn(\n 'bg-muted text-muted-foreground inline-flex h-5 select-none items-center gap-1 rounded border px-1.5 font-mono text-xs font-medium',\n className,\n )}\n {...props}\n />\n );\n },\n);\n\nKbd.displayName = 'Kbd';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Kbd, type KbdProps };\n"],"mappings":"0CAAA,UAAYA,MAAW,QACvB,OAAS,QAAAC,MAAY,uBAkBf,cAAAC,MAAA,oBALN,IAAMC,EAAY,aAChB,CAAC,CAAE,QAAAC,EAAS,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAI/BL,EAHgBE,EAAUI,EAAO,MAGhC,CACC,IAAKD,EACL,UAAWE,EACT,oIACAJ,CACF,EACC,GAAGC,EACN,CAGN,EAEAH,EAAI,YAAc","names":["React","Slot","jsx","Kbd","asChild","className","props","ref","Slot","cn"]}
1
+ {"version":3,"sources":["../../src/react/kbd.tsx"],"sourcesContent":["import * as React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: Kbd\n * -------------------------------------------------------------------------- */\n\ntype KbdElement = HTMLElement;\n\ninterface KbdProps extends React.HTMLAttributes<HTMLElement> {\n asChild?: boolean;\n}\n\nconst Kbd = React.forwardRef<KbdElement, KbdProps>(({ asChild, className, ...props }, ref) => {\n const Component = asChild ? Slot : 'kbd';\n\n return (\n <Component\n ref={ref}\n className={cn(\n 'bg-muted text-muted-foreground inline-flex h-5 select-none items-center gap-1 rounded border px-1.5 font-mono text-xs font-medium',\n className,\n )}\n {...props}\n />\n );\n});\n\nKbd.displayName = 'Kbd';\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Kbd, type KbdProps };\n"],"mappings":"0CAAA,UAAYA,MAAW,QACvB,OAAS,QAAAC,MAAY,uBAiBjB,cAAAC,MAAA,oBAJJ,IAAMC,EAAY,aAAiC,CAAC,CAAE,QAAAC,EAAS,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAIlFL,EAHgBE,EAAUI,EAAO,MAGhC,CACC,IAAKD,EACL,UAAWE,EACT,oIACAJ,CACF,EACC,GAAGC,EACN,CAEH,EAEDH,EAAI,YAAc","names":["React","Slot","jsx","Kbd","asChild","className","props","ref","Slot","cn"]}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";var _chunkLG7ACTREjs = require('../chunk-LG7ACTRE.js');require('../chunk-HQ4AUOQM.js');exports.Label = _chunkLG7ACTREjs.a;
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";var _chunkPRCS3RWNjs = require('../chunk-PRCS3RWN.js');require('../chunk-HQ4AUOQM.js');exports.Label = _chunkPRCS3RWNjs.a;
2
2
  //# sourceMappingURL=label.js.map
@@ -1,2 +1,2 @@
1
- "use client";import{a}from"../chunk-6FL3EBDQ.mjs";import"../chunk-LEUB3C3L.mjs";export{a as Label};
1
+ "use client";import{a}from"../chunk-HMD2ZU33.mjs";import"../chunk-LEUB3C3L.mjs";export{a as Label};
2
2
  //# sourceMappingURL=label.mjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/menubar.tsx"],"names":["React","CheckIcon","ChevronRightIcon","DotFilledIcon","MenubarPrimitive","jsx","jsxs","MenubarMenu","MenubarGroup","MenubarSub","MenubarRadioGroup","Menubar","className","props","ref","cn","MenubarTrigger","MenubarSubTrigger","children","inset","MenubarSubContent","MenubarContent","align","alignOffset","sideOffset","MenubarItem","MenubarCheckboxItem","checked","MenubarRadioItem","MenubarLabel","MenubarSeparator","MenubarShortcut"],"mappings":"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","sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport {\n CheckIcon,\n ChevronRightIcon,\n DotFilledIcon,\n} from '@radix-ui/react-icons';\nimport * as MenubarPrimitive from '@radix-ui/react-menubar';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarMenu\n * -------------------------------------------------------------------------- */\n\ntype MenubarMenuProps = React.ComponentProps<typeof MenubarPrimitive.Menu>;\nconst MenubarMenu = MenubarPrimitive.Menu;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarGroup\n * -------------------------------------------------------------------------- */\n\ntype MenubarGroupProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Group\n>;\nconst MenubarGroup = MenubarPrimitive.Group;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSub\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Sub\n>;\nconst MenubarSub = MenubarPrimitive.Sub;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarRadioGroup\n * -------------------------------------------------------------------------- */\n\ntype MenubarRadioGroupProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.RadioGroup\n>;\nconst MenubarRadioGroup = MenubarPrimitive.RadioGroup;\n\n/* -----------------------------------------------------------------------------\n * Component: Menubar\n * -------------------------------------------------------------------------- */\n\ntype MenubarElement = React.ElementRef<typeof MenubarPrimitive.Root>;\ntype MenubarProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Root\n>;\n\nconst Menubar = React.forwardRef<MenubarElement, MenubarProps>(\n ({ className, ...props }, ref) => (\n <MenubarPrimitive.Root\n ref={ref}\n className={cn(\n 'bg-background flex h-10 items-center space-x-1 rounded-md border p-1 shadow-sm',\n className,\n )}\n {...props}\n />\n ),\n);\n\nMenubar.displayName = MenubarPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarTrigger\n * -------------------------------------------------------------------------- */\n\ntype MenubarTriggerElement = React.ElementRef<typeof MenubarPrimitive.Trigger>;\ntype MenubarTriggerProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Trigger\n>;\n\nconst MenubarTrigger = React.forwardRef<\n MenubarTriggerElement,\n MenubarTriggerProps\n>(({ className, ...props }, ref) => (\n <MenubarPrimitive.Trigger\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-pointer select-none items-center rounded-sm px-3 py-1 text-sm font-medium focus:outline-none',\n className,\n )}\n {...props}\n />\n));\n\nMenubarTrigger.displayName = MenubarPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSubTrigger\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubTriggerElement = React.ElementRef<\n typeof MenubarPrimitive.SubTrigger\n>;\n\ninterface MenubarSubTriggerProps\n extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.SubTrigger> {\n inset?: boolean;\n}\n\nconst MenubarSubTrigger = React.forwardRef<\n MenubarSubTriggerElement,\n MenubarSubTriggerProps\n>(({ children, className, inset, ...props }, ref) => (\n <MenubarPrimitive.SubTrigger\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none',\n inset && 'pl-8',\n className,\n )}\n {...props}\n >\n {children}\n <ChevronRightIcon className=\"ml-auto size-4\" />\n </MenubarPrimitive.SubTrigger>\n));\n\nMenubarSubTrigger.displayName = MenubarPrimitive.SubTrigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSubContent\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubContentElement = React.ElementRef<\n typeof MenubarPrimitive.SubContent\n>;\ntype MenubarSubContentProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.SubContent\n>;\n\nconst MenubarSubContent = React.forwardRef<\n MenubarSubContentElement,\n MenubarSubContentProps\n>(({ className, ...props }, ref) => (\n <MenubarPrimitive.Portal>\n <MenubarPrimitive.SubContent\n ref={ref}\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-95 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 data-[state=closed]:data-[side=top]:slide-out-to-bottom-2 data-[state=closed]:data-[side=left]:slide-out-to-right-2 data-[state=closed]:data-[side=bottom]:slide-out-to-top-2 data-[state=closed]:data-[side=right]:slide-out-to-left-2 z-50 min-w-32 rounded-md border p-1 shadow-md',\n className,\n )}\n {...props}\n />\n </MenubarPrimitive.Portal>\n));\n\nMenubarSubContent.displayName = MenubarPrimitive.SubContent.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarContent\n * -------------------------------------------------------------------------- */\n\ntype MenubarContentElement = React.ElementRef<typeof MenubarPrimitive.Content>;\ntype MenubarContentProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Content\n>;\n\nconst MenubarContent = React.forwardRef<\n MenubarContentElement,\n MenubarContentProps\n>(\n (\n { className, align = 'start', alignOffset = -4, sideOffset = 8, ...props },\n ref,\n ) => (\n <MenubarPrimitive.Portal>\n <MenubarPrimitive.Content\n ref={ref}\n align={align}\n alignOffset={alignOffset}\n sideOffset={sideOffset}\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-95 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 z-50 min-w-32 rounded-md border p-1 shadow-md',\n className,\n )}\n {...props}\n />\n </MenubarPrimitive.Portal>\n ),\n);\n\nMenubarContent.displayName = MenubarPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarItemElement = React.ElementRef<typeof MenubarPrimitive.Item>;\n\ninterface MenubarItemProps\n extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Item> {\n inset?: boolean;\n}\n\nconst MenubarItem = React.forwardRef<MenubarItemElement, MenubarItemProps>(\n ({ className, inset, ...props }, ref) => (\n <MenubarPrimitive.Item\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n inset && 'pl-8',\n className,\n )}\n {...props}\n />\n ),\n);\n\nMenubarItem.displayName = MenubarPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarCheckboxItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarCheckboxItemElement = React.ElementRef<\n typeof MenubarPrimitive.CheckboxItem\n>;\ntype MenubarCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.CheckboxItem\n>;\n\nconst MenubarCheckboxItem = React.forwardRef<\n MenubarCheckboxItemElement,\n MenubarCheckboxItemProps\n>(({ children, className, checked, ...props }, ref) => (\n <MenubarPrimitive.CheckboxItem\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n className,\n )}\n checked={checked}\n {...props}\n >\n <span className=\"absolute left-2 flex size-3.5 items-center justify-center\">\n <MenubarPrimitive.ItemIndicator>\n <CheckIcon className=\"size-4\" />\n </MenubarPrimitive.ItemIndicator>\n </span>\n {children}\n </MenubarPrimitive.CheckboxItem>\n));\n\nMenubarCheckboxItem.displayName = MenubarPrimitive.CheckboxItem.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarRadioItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarRadioItemElement = React.ElementRef<\n typeof MenubarPrimitive.RadioItem\n>;\ntype MenubarRadioItemProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.RadioItem\n>;\n\nconst MenubarRadioItem = React.forwardRef<\n MenubarRadioItemElement,\n MenubarRadioItemProps\n>(({ children, className, ...props }, ref) => (\n <MenubarPrimitive.RadioItem\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n className,\n )}\n {...props}\n >\n <span className=\"absolute left-2 flex size-3.5 items-center justify-center\">\n <MenubarPrimitive.ItemIndicator>\n <DotFilledIcon className=\"size-4 fill-current\" />\n </MenubarPrimitive.ItemIndicator>\n </span>\n {children}\n </MenubarPrimitive.RadioItem>\n));\n\nMenubarRadioItem.displayName = MenubarPrimitive.RadioItem.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarLabel\n * -------------------------------------------------------------------------- */\n\ntype MenubarLabelElement = React.ElementRef<typeof MenubarPrimitive.Label>;\n\ninterface MenubarLabelProps\n extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Label> {\n inset?: boolean;\n}\n\nconst MenubarLabel = React.forwardRef<MenubarLabelElement, MenubarLabelProps>(\n ({ className, inset, ...props }, ref) => (\n <MenubarPrimitive.Label\n ref={ref}\n className={cn(\n 'px-2 py-1.5 text-sm font-semibold',\n inset && 'pl-8',\n className,\n )}\n {...props}\n />\n ),\n);\n\nMenubarLabel.displayName = MenubarPrimitive.Label.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSeparator\n * -------------------------------------------------------------------------- */\n\ntype MenubarSeparatorElement = React.ElementRef<\n typeof MenubarPrimitive.Separator\n>;\ntype MenubarSeparatorProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Separator\n>;\n\nconst MenubarSeparator = React.forwardRef<\n MenubarSeparatorElement,\n MenubarSeparatorProps\n>(({ className, ...props }, ref) => (\n <MenubarPrimitive.Separator\n ref={ref}\n className={cn('bg-muted -mx-1 my-1 h-px', className)}\n {...props}\n />\n));\n\nMenubarSeparator.displayName = MenubarPrimitive.Separator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarShortcut\n * -------------------------------------------------------------------------- */\n\ntype MenubarShortcutProps = React.HTMLAttributes<HTMLSpanElement>;\n\nfunction MenubarShortcut({\n className,\n ...props\n}: MenubarShortcutProps): React.JSX.Element {\n return (\n <span\n className={cn(\n 'text-muted-foreground ml-auto text-xs tracking-widest',\n className,\n )}\n {...props}\n />\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Menubar,\n MenubarMenu,\n MenubarTrigger,\n MenubarContent,\n MenubarItem,\n MenubarSeparator,\n MenubarLabel,\n MenubarCheckboxItem,\n MenubarRadioGroup,\n MenubarRadioItem,\n MenubarSubContent,\n MenubarSubTrigger,\n MenubarGroup,\n MenubarSub,\n MenubarShortcut,\n type MenubarProps,\n type MenubarMenuProps,\n type MenubarTriggerProps,\n type MenubarContentProps,\n type MenubarItemProps,\n type MenubarSeparatorProps,\n type MenubarLabelProps,\n type MenubarCheckboxItemProps,\n type MenubarRadioGroupProps,\n type MenubarRadioItemProps,\n type MenubarSubContentProps,\n type MenubarSubTriggerProps,\n type MenubarGroupProps,\n type MenubarSubProps,\n type MenubarShortcutProps,\n};\n"]}
1
+ {"version":3,"sources":["../../src/react/menubar.tsx"],"names":["React","CheckIcon","ChevronRightIcon","DotFilledIcon","MenubarPrimitive","jsx","jsxs","MenubarMenu","MenubarGroup","MenubarSub","MenubarRadioGroup","Menubar","className","props","ref","cn","MenubarTrigger","MenubarSubTrigger","children","inset","MenubarSubContent","MenubarContent","align","alignOffset","sideOffset","MenubarItem","MenubarCheckboxItem","checked","MenubarRadioItem","MenubarLabel","MenubarSeparator","MenubarShortcut"],"mappings":"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","sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { CheckIcon, ChevronRightIcon, DotFilledIcon } from '@radix-ui/react-icons';\nimport * as MenubarPrimitive from '@radix-ui/react-menubar';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarMenu\n * -------------------------------------------------------------------------- */\n\ntype MenubarMenuProps = React.ComponentProps<typeof MenubarPrimitive.Menu>;\nconst MenubarMenu = MenubarPrimitive.Menu;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarGroup\n * -------------------------------------------------------------------------- */\n\ntype MenubarGroupProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Group>;\nconst MenubarGroup = MenubarPrimitive.Group;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSub\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Sub>;\nconst MenubarSub = MenubarPrimitive.Sub;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarRadioGroup\n * -------------------------------------------------------------------------- */\n\ntype MenubarRadioGroupProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.RadioGroup>;\nconst MenubarRadioGroup = MenubarPrimitive.RadioGroup;\n\n/* -----------------------------------------------------------------------------\n * Component: Menubar\n * -------------------------------------------------------------------------- */\n\ntype MenubarElement = React.ElementRef<typeof MenubarPrimitive.Root>;\ntype MenubarProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Root>;\n\nconst Menubar = React.forwardRef<MenubarElement, MenubarProps>(({ className, ...props }, ref) => (\n <MenubarPrimitive.Root\n ref={ref}\n className={cn('bg-background flex h-10 items-center space-x-1 rounded-md border p-1 shadow-sm', className)}\n {...props}\n />\n));\n\nMenubar.displayName = MenubarPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarTrigger\n * -------------------------------------------------------------------------- */\n\ntype MenubarTriggerElement = React.ElementRef<typeof MenubarPrimitive.Trigger>;\ntype MenubarTriggerProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Trigger>;\n\nconst MenubarTrigger = React.forwardRef<MenubarTriggerElement, MenubarTriggerProps>(({ className, ...props }, ref) => (\n <MenubarPrimitive.Trigger\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-pointer select-none items-center rounded-sm px-3 py-1 text-sm font-medium focus:outline-none',\n className,\n )}\n {...props}\n />\n));\n\nMenubarTrigger.displayName = MenubarPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSubTrigger\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubTriggerElement = React.ElementRef<typeof MenubarPrimitive.SubTrigger>;\n\ninterface MenubarSubTriggerProps extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.SubTrigger> {\n inset?: boolean;\n}\n\nconst MenubarSubTrigger = React.forwardRef<MenubarSubTriggerElement, MenubarSubTriggerProps>(\n ({ children, className, inset, ...props }, ref) => (\n <MenubarPrimitive.SubTrigger\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none',\n inset && 'pl-8',\n className,\n )}\n {...props}\n >\n {children}\n <ChevronRightIcon className=\"ml-auto size-4\" />\n </MenubarPrimitive.SubTrigger>\n ),\n);\n\nMenubarSubTrigger.displayName = MenubarPrimitive.SubTrigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSubContent\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubContentElement = React.ElementRef<typeof MenubarPrimitive.SubContent>;\ntype MenubarSubContentProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.SubContent>;\n\nconst MenubarSubContent = React.forwardRef<MenubarSubContentElement, MenubarSubContentProps>(\n ({ className, ...props }, ref) => (\n <MenubarPrimitive.Portal>\n <MenubarPrimitive.SubContent\n ref={ref}\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-95 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 data-[state=closed]:data-[side=top]:slide-out-to-bottom-2 data-[state=closed]:data-[side=left]:slide-out-to-right-2 data-[state=closed]:data-[side=bottom]:slide-out-to-top-2 data-[state=closed]:data-[side=right]:slide-out-to-left-2 z-50 min-w-32 rounded-md border p-1 shadow-md',\n className,\n )}\n {...props}\n />\n </MenubarPrimitive.Portal>\n ),\n);\n\nMenubarSubContent.displayName = MenubarPrimitive.SubContent.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarContent\n * -------------------------------------------------------------------------- */\n\ntype MenubarContentElement = React.ElementRef<typeof MenubarPrimitive.Content>;\ntype MenubarContentProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Content>;\n\nconst MenubarContent = React.forwardRef<MenubarContentElement, MenubarContentProps>(\n ({ className, align = 'start', alignOffset = -4, sideOffset = 8, ...props }, ref) => (\n <MenubarPrimitive.Portal>\n <MenubarPrimitive.Content\n ref={ref}\n align={align}\n alignOffset={alignOffset}\n sideOffset={sideOffset}\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-95 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 z-50 min-w-32 rounded-md border p-1 shadow-md',\n className,\n )}\n {...props}\n />\n </MenubarPrimitive.Portal>\n ),\n);\n\nMenubarContent.displayName = MenubarPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarItemElement = React.ElementRef<typeof MenubarPrimitive.Item>;\n\ninterface MenubarItemProps extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Item> {\n inset?: boolean;\n}\n\nconst MenubarItem = React.forwardRef<MenubarItemElement, MenubarItemProps>(({ className, inset, ...props }, ref) => (\n <MenubarPrimitive.Item\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n inset && 'pl-8',\n className,\n )}\n {...props}\n />\n));\n\nMenubarItem.displayName = MenubarPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarCheckboxItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarCheckboxItemElement = React.ElementRef<typeof MenubarPrimitive.CheckboxItem>;\ntype MenubarCheckboxItemProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.CheckboxItem>;\n\nconst MenubarCheckboxItem = React.forwardRef<MenubarCheckboxItemElement, MenubarCheckboxItemProps>(\n ({ children, className, checked, ...props }, ref) => (\n <MenubarPrimitive.CheckboxItem\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n className,\n )}\n checked={checked}\n {...props}\n >\n <span className=\"absolute left-2 flex size-3.5 items-center justify-center\">\n <MenubarPrimitive.ItemIndicator>\n <CheckIcon className=\"size-4\" />\n </MenubarPrimitive.ItemIndicator>\n </span>\n {children}\n </MenubarPrimitive.CheckboxItem>\n ),\n);\n\nMenubarCheckboxItem.displayName = MenubarPrimitive.CheckboxItem.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarRadioItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarRadioItemElement = React.ElementRef<typeof MenubarPrimitive.RadioItem>;\ntype MenubarRadioItemProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.RadioItem>;\n\nconst MenubarRadioItem = React.forwardRef<MenubarRadioItemElement, MenubarRadioItemProps>(\n ({ children, className, ...props }, ref) => (\n <MenubarPrimitive.RadioItem\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n className,\n )}\n {...props}\n >\n <span className=\"absolute left-2 flex size-3.5 items-center justify-center\">\n <MenubarPrimitive.ItemIndicator>\n <DotFilledIcon className=\"size-4 fill-current\" />\n </MenubarPrimitive.ItemIndicator>\n </span>\n {children}\n </MenubarPrimitive.RadioItem>\n ),\n);\n\nMenubarRadioItem.displayName = MenubarPrimitive.RadioItem.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarLabel\n * -------------------------------------------------------------------------- */\n\ntype MenubarLabelElement = React.ElementRef<typeof MenubarPrimitive.Label>;\n\ninterface MenubarLabelProps extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Label> {\n inset?: boolean;\n}\n\nconst MenubarLabel = React.forwardRef<MenubarLabelElement, MenubarLabelProps>(({ className, inset, ...props }, ref) => (\n <MenubarPrimitive.Label\n ref={ref}\n className={cn('px-2 py-1.5 text-sm font-semibold', inset && 'pl-8', className)}\n {...props}\n />\n));\n\nMenubarLabel.displayName = MenubarPrimitive.Label.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSeparator\n * -------------------------------------------------------------------------- */\n\ntype MenubarSeparatorElement = React.ElementRef<typeof MenubarPrimitive.Separator>;\ntype MenubarSeparatorProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Separator>;\n\nconst MenubarSeparator = React.forwardRef<MenubarSeparatorElement, MenubarSeparatorProps>(\n ({ className, ...props }, ref) => (\n <MenubarPrimitive.Separator ref={ref} className={cn('bg-muted -mx-1 my-1 h-px', className)} {...props} />\n ),\n);\n\nMenubarSeparator.displayName = MenubarPrimitive.Separator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarShortcut\n * -------------------------------------------------------------------------- */\n\ntype MenubarShortcutProps = React.HTMLAttributes<HTMLSpanElement>;\n\nfunction MenubarShortcut({ className, ...props }: MenubarShortcutProps): React.JSX.Element {\n return <span className={cn('text-muted-foreground ml-auto text-xs tracking-widest', className)} {...props} />;\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Menubar,\n MenubarMenu,\n MenubarTrigger,\n MenubarContent,\n MenubarItem,\n MenubarSeparator,\n MenubarLabel,\n MenubarCheckboxItem,\n MenubarRadioGroup,\n MenubarRadioItem,\n MenubarSubContent,\n MenubarSubTrigger,\n MenubarGroup,\n MenubarSub,\n MenubarShortcut,\n type MenubarProps,\n type MenubarMenuProps,\n type MenubarTriggerProps,\n type MenubarContentProps,\n type MenubarItemProps,\n type MenubarSeparatorProps,\n type MenubarLabelProps,\n type MenubarCheckboxItemProps,\n type MenubarRadioGroupProps,\n type MenubarRadioItemProps,\n type MenubarSubContentProps,\n type MenubarSubTriggerProps,\n type MenubarGroupProps,\n type MenubarSubProps,\n type MenubarShortcutProps,\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/menubar.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport {\n CheckIcon,\n ChevronRightIcon,\n DotFilledIcon,\n} from '@radix-ui/react-icons';\nimport * as MenubarPrimitive from '@radix-ui/react-menubar';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarMenu\n * -------------------------------------------------------------------------- */\n\ntype MenubarMenuProps = React.ComponentProps<typeof MenubarPrimitive.Menu>;\nconst MenubarMenu = MenubarPrimitive.Menu;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarGroup\n * -------------------------------------------------------------------------- */\n\ntype MenubarGroupProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Group\n>;\nconst MenubarGroup = MenubarPrimitive.Group;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSub\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Sub\n>;\nconst MenubarSub = MenubarPrimitive.Sub;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarRadioGroup\n * -------------------------------------------------------------------------- */\n\ntype MenubarRadioGroupProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.RadioGroup\n>;\nconst MenubarRadioGroup = MenubarPrimitive.RadioGroup;\n\n/* -----------------------------------------------------------------------------\n * Component: Menubar\n * -------------------------------------------------------------------------- */\n\ntype MenubarElement = React.ElementRef<typeof MenubarPrimitive.Root>;\ntype MenubarProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Root\n>;\n\nconst Menubar = React.forwardRef<MenubarElement, MenubarProps>(\n ({ className, ...props }, ref) => (\n <MenubarPrimitive.Root\n ref={ref}\n className={cn(\n 'bg-background flex h-10 items-center space-x-1 rounded-md border p-1 shadow-sm',\n className,\n )}\n {...props}\n />\n ),\n);\n\nMenubar.displayName = MenubarPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarTrigger\n * -------------------------------------------------------------------------- */\n\ntype MenubarTriggerElement = React.ElementRef<typeof MenubarPrimitive.Trigger>;\ntype MenubarTriggerProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Trigger\n>;\n\nconst MenubarTrigger = React.forwardRef<\n MenubarTriggerElement,\n MenubarTriggerProps\n>(({ className, ...props }, ref) => (\n <MenubarPrimitive.Trigger\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-pointer select-none items-center rounded-sm px-3 py-1 text-sm font-medium focus:outline-none',\n className,\n )}\n {...props}\n />\n));\n\nMenubarTrigger.displayName = MenubarPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSubTrigger\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubTriggerElement = React.ElementRef<\n typeof MenubarPrimitive.SubTrigger\n>;\n\ninterface MenubarSubTriggerProps\n extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.SubTrigger> {\n inset?: boolean;\n}\n\nconst MenubarSubTrigger = React.forwardRef<\n MenubarSubTriggerElement,\n MenubarSubTriggerProps\n>(({ children, className, inset, ...props }, ref) => (\n <MenubarPrimitive.SubTrigger\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none',\n inset && 'pl-8',\n className,\n )}\n {...props}\n >\n {children}\n <ChevronRightIcon className=\"ml-auto size-4\" />\n </MenubarPrimitive.SubTrigger>\n));\n\nMenubarSubTrigger.displayName = MenubarPrimitive.SubTrigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSubContent\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubContentElement = React.ElementRef<\n typeof MenubarPrimitive.SubContent\n>;\ntype MenubarSubContentProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.SubContent\n>;\n\nconst MenubarSubContent = React.forwardRef<\n MenubarSubContentElement,\n MenubarSubContentProps\n>(({ className, ...props }, ref) => (\n <MenubarPrimitive.Portal>\n <MenubarPrimitive.SubContent\n ref={ref}\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-95 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 data-[state=closed]:data-[side=top]:slide-out-to-bottom-2 data-[state=closed]:data-[side=left]:slide-out-to-right-2 data-[state=closed]:data-[side=bottom]:slide-out-to-top-2 data-[state=closed]:data-[side=right]:slide-out-to-left-2 z-50 min-w-32 rounded-md border p-1 shadow-md',\n className,\n )}\n {...props}\n />\n </MenubarPrimitive.Portal>\n));\n\nMenubarSubContent.displayName = MenubarPrimitive.SubContent.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarContent\n * -------------------------------------------------------------------------- */\n\ntype MenubarContentElement = React.ElementRef<typeof MenubarPrimitive.Content>;\ntype MenubarContentProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Content\n>;\n\nconst MenubarContent = React.forwardRef<\n MenubarContentElement,\n MenubarContentProps\n>(\n (\n { className, align = 'start', alignOffset = -4, sideOffset = 8, ...props },\n ref,\n ) => (\n <MenubarPrimitive.Portal>\n <MenubarPrimitive.Content\n ref={ref}\n align={align}\n alignOffset={alignOffset}\n sideOffset={sideOffset}\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-95 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 z-50 min-w-32 rounded-md border p-1 shadow-md',\n className,\n )}\n {...props}\n />\n </MenubarPrimitive.Portal>\n ),\n);\n\nMenubarContent.displayName = MenubarPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarItemElement = React.ElementRef<typeof MenubarPrimitive.Item>;\n\ninterface MenubarItemProps\n extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Item> {\n inset?: boolean;\n}\n\nconst MenubarItem = React.forwardRef<MenubarItemElement, MenubarItemProps>(\n ({ className, inset, ...props }, ref) => (\n <MenubarPrimitive.Item\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n inset && 'pl-8',\n className,\n )}\n {...props}\n />\n ),\n);\n\nMenubarItem.displayName = MenubarPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarCheckboxItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarCheckboxItemElement = React.ElementRef<\n typeof MenubarPrimitive.CheckboxItem\n>;\ntype MenubarCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.CheckboxItem\n>;\n\nconst MenubarCheckboxItem = React.forwardRef<\n MenubarCheckboxItemElement,\n MenubarCheckboxItemProps\n>(({ children, className, checked, ...props }, ref) => (\n <MenubarPrimitive.CheckboxItem\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n className,\n )}\n checked={checked}\n {...props}\n >\n <span className=\"absolute left-2 flex size-3.5 items-center justify-center\">\n <MenubarPrimitive.ItemIndicator>\n <CheckIcon className=\"size-4\" />\n </MenubarPrimitive.ItemIndicator>\n </span>\n {children}\n </MenubarPrimitive.CheckboxItem>\n));\n\nMenubarCheckboxItem.displayName = MenubarPrimitive.CheckboxItem.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarRadioItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarRadioItemElement = React.ElementRef<\n typeof MenubarPrimitive.RadioItem\n>;\ntype MenubarRadioItemProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.RadioItem\n>;\n\nconst MenubarRadioItem = React.forwardRef<\n MenubarRadioItemElement,\n MenubarRadioItemProps\n>(({ children, className, ...props }, ref) => (\n <MenubarPrimitive.RadioItem\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n className,\n )}\n {...props}\n >\n <span className=\"absolute left-2 flex size-3.5 items-center justify-center\">\n <MenubarPrimitive.ItemIndicator>\n <DotFilledIcon className=\"size-4 fill-current\" />\n </MenubarPrimitive.ItemIndicator>\n </span>\n {children}\n </MenubarPrimitive.RadioItem>\n));\n\nMenubarRadioItem.displayName = MenubarPrimitive.RadioItem.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarLabel\n * -------------------------------------------------------------------------- */\n\ntype MenubarLabelElement = React.ElementRef<typeof MenubarPrimitive.Label>;\n\ninterface MenubarLabelProps\n extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Label> {\n inset?: boolean;\n}\n\nconst MenubarLabel = React.forwardRef<MenubarLabelElement, MenubarLabelProps>(\n ({ className, inset, ...props }, ref) => (\n <MenubarPrimitive.Label\n ref={ref}\n className={cn(\n 'px-2 py-1.5 text-sm font-semibold',\n inset && 'pl-8',\n className,\n )}\n {...props}\n />\n ),\n);\n\nMenubarLabel.displayName = MenubarPrimitive.Label.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSeparator\n * -------------------------------------------------------------------------- */\n\ntype MenubarSeparatorElement = React.ElementRef<\n typeof MenubarPrimitive.Separator\n>;\ntype MenubarSeparatorProps = React.ComponentPropsWithoutRef<\n typeof MenubarPrimitive.Separator\n>;\n\nconst MenubarSeparator = React.forwardRef<\n MenubarSeparatorElement,\n MenubarSeparatorProps\n>(({ className, ...props }, ref) => (\n <MenubarPrimitive.Separator\n ref={ref}\n className={cn('bg-muted -mx-1 my-1 h-px', className)}\n {...props}\n />\n));\n\nMenubarSeparator.displayName = MenubarPrimitive.Separator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarShortcut\n * -------------------------------------------------------------------------- */\n\ntype MenubarShortcutProps = React.HTMLAttributes<HTMLSpanElement>;\n\nfunction MenubarShortcut({\n className,\n ...props\n}: MenubarShortcutProps): React.JSX.Element {\n return (\n <span\n className={cn(\n 'text-muted-foreground ml-auto text-xs tracking-widest',\n className,\n )}\n {...props}\n />\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Menubar,\n MenubarMenu,\n MenubarTrigger,\n MenubarContent,\n MenubarItem,\n MenubarSeparator,\n MenubarLabel,\n MenubarCheckboxItem,\n MenubarRadioGroup,\n MenubarRadioItem,\n MenubarSubContent,\n MenubarSubTrigger,\n MenubarGroup,\n MenubarSub,\n MenubarShortcut,\n type MenubarProps,\n type MenubarMenuProps,\n type MenubarTriggerProps,\n type MenubarContentProps,\n type MenubarItemProps,\n type MenubarSeparatorProps,\n type MenubarLabelProps,\n type MenubarCheckboxItemProps,\n type MenubarRadioGroupProps,\n type MenubarRadioItemProps,\n type MenubarSubContentProps,\n type MenubarSubTriggerProps,\n type MenubarGroupProps,\n type MenubarSubProps,\n type MenubarShortcutProps,\n};\n"],"mappings":"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","names":["React","CheckIcon","ChevronRightIcon","DotFilledIcon","MenubarPrimitive","jsx","jsxs","MenubarMenu","MenubarGroup","MenubarSub","MenubarRadioGroup","Menubar","className","props","ref","cn","MenubarTrigger","MenubarSubTrigger","children","inset","ChevronRightIcon","MenubarSubContent","MenubarContent","align","alignOffset","sideOffset","MenubarItem","MenubarCheckboxItem","checked","CheckIcon","MenubarRadioItem","DotFilledIcon","MenubarLabel","MenubarSeparator","MenubarShortcut"]}
1
+ {"version":3,"sources":["../../src/react/menubar.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { CheckIcon, ChevronRightIcon, DotFilledIcon } from '@radix-ui/react-icons';\nimport * as MenubarPrimitive from '@radix-ui/react-menubar';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarMenu\n * -------------------------------------------------------------------------- */\n\ntype MenubarMenuProps = React.ComponentProps<typeof MenubarPrimitive.Menu>;\nconst MenubarMenu = MenubarPrimitive.Menu;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarGroup\n * -------------------------------------------------------------------------- */\n\ntype MenubarGroupProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Group>;\nconst MenubarGroup = MenubarPrimitive.Group;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSub\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Sub>;\nconst MenubarSub = MenubarPrimitive.Sub;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarRadioGroup\n * -------------------------------------------------------------------------- */\n\ntype MenubarRadioGroupProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.RadioGroup>;\nconst MenubarRadioGroup = MenubarPrimitive.RadioGroup;\n\n/* -----------------------------------------------------------------------------\n * Component: Menubar\n * -------------------------------------------------------------------------- */\n\ntype MenubarElement = React.ElementRef<typeof MenubarPrimitive.Root>;\ntype MenubarProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Root>;\n\nconst Menubar = React.forwardRef<MenubarElement, MenubarProps>(({ className, ...props }, ref) => (\n <MenubarPrimitive.Root\n ref={ref}\n className={cn('bg-background flex h-10 items-center space-x-1 rounded-md border p-1 shadow-sm', className)}\n {...props}\n />\n));\n\nMenubar.displayName = MenubarPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarTrigger\n * -------------------------------------------------------------------------- */\n\ntype MenubarTriggerElement = React.ElementRef<typeof MenubarPrimitive.Trigger>;\ntype MenubarTriggerProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Trigger>;\n\nconst MenubarTrigger = React.forwardRef<MenubarTriggerElement, MenubarTriggerProps>(({ className, ...props }, ref) => (\n <MenubarPrimitive.Trigger\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-pointer select-none items-center rounded-sm px-3 py-1 text-sm font-medium focus:outline-none',\n className,\n )}\n {...props}\n />\n));\n\nMenubarTrigger.displayName = MenubarPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSubTrigger\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubTriggerElement = React.ElementRef<typeof MenubarPrimitive.SubTrigger>;\n\ninterface MenubarSubTriggerProps extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.SubTrigger> {\n inset?: boolean;\n}\n\nconst MenubarSubTrigger = React.forwardRef<MenubarSubTriggerElement, MenubarSubTriggerProps>(\n ({ children, className, inset, ...props }, ref) => (\n <MenubarPrimitive.SubTrigger\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none',\n inset && 'pl-8',\n className,\n )}\n {...props}\n >\n {children}\n <ChevronRightIcon className=\"ml-auto size-4\" />\n </MenubarPrimitive.SubTrigger>\n ),\n);\n\nMenubarSubTrigger.displayName = MenubarPrimitive.SubTrigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSubContent\n * -------------------------------------------------------------------------- */\n\ntype MenubarSubContentElement = React.ElementRef<typeof MenubarPrimitive.SubContent>;\ntype MenubarSubContentProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.SubContent>;\n\nconst MenubarSubContent = React.forwardRef<MenubarSubContentElement, MenubarSubContentProps>(\n ({ className, ...props }, ref) => (\n <MenubarPrimitive.Portal>\n <MenubarPrimitive.SubContent\n ref={ref}\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-95 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 data-[state=closed]:data-[side=top]:slide-out-to-bottom-2 data-[state=closed]:data-[side=left]:slide-out-to-right-2 data-[state=closed]:data-[side=bottom]:slide-out-to-top-2 data-[state=closed]:data-[side=right]:slide-out-to-left-2 z-50 min-w-32 rounded-md border p-1 shadow-md',\n className,\n )}\n {...props}\n />\n </MenubarPrimitive.Portal>\n ),\n);\n\nMenubarSubContent.displayName = MenubarPrimitive.SubContent.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarContent\n * -------------------------------------------------------------------------- */\n\ntype MenubarContentElement = React.ElementRef<typeof MenubarPrimitive.Content>;\ntype MenubarContentProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Content>;\n\nconst MenubarContent = React.forwardRef<MenubarContentElement, MenubarContentProps>(\n ({ className, align = 'start', alignOffset = -4, sideOffset = 8, ...props }, ref) => (\n <MenubarPrimitive.Portal>\n <MenubarPrimitive.Content\n ref={ref}\n align={align}\n alignOffset={alignOffset}\n sideOffset={sideOffset}\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-95 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 z-50 min-w-32 rounded-md border p-1 shadow-md',\n className,\n )}\n {...props}\n />\n </MenubarPrimitive.Portal>\n ),\n);\n\nMenubarContent.displayName = MenubarPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarItemElement = React.ElementRef<typeof MenubarPrimitive.Item>;\n\ninterface MenubarItemProps extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Item> {\n inset?: boolean;\n}\n\nconst MenubarItem = React.forwardRef<MenubarItemElement, MenubarItemProps>(({ className, inset, ...props }, ref) => (\n <MenubarPrimitive.Item\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n inset && 'pl-8',\n className,\n )}\n {...props}\n />\n));\n\nMenubarItem.displayName = MenubarPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarCheckboxItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarCheckboxItemElement = React.ElementRef<typeof MenubarPrimitive.CheckboxItem>;\ntype MenubarCheckboxItemProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.CheckboxItem>;\n\nconst MenubarCheckboxItem = React.forwardRef<MenubarCheckboxItemElement, MenubarCheckboxItemProps>(\n ({ children, className, checked, ...props }, ref) => (\n <MenubarPrimitive.CheckboxItem\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n className,\n )}\n checked={checked}\n {...props}\n >\n <span className=\"absolute left-2 flex size-3.5 items-center justify-center\">\n <MenubarPrimitive.ItemIndicator>\n <CheckIcon className=\"size-4\" />\n </MenubarPrimitive.ItemIndicator>\n </span>\n {children}\n </MenubarPrimitive.CheckboxItem>\n ),\n);\n\nMenubarCheckboxItem.displayName = MenubarPrimitive.CheckboxItem.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarRadioItem\n * -------------------------------------------------------------------------- */\n\ntype MenubarRadioItemElement = React.ElementRef<typeof MenubarPrimitive.RadioItem>;\ntype MenubarRadioItemProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.RadioItem>;\n\nconst MenubarRadioItem = React.forwardRef<MenubarRadioItemElement, MenubarRadioItemProps>(\n ({ children, className, ...props }, ref) => (\n <MenubarPrimitive.RadioItem\n ref={ref}\n className={cn(\n 'focus:bg-accent focus:text-accent-foreground relative flex cursor-pointer select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50',\n className,\n )}\n {...props}\n >\n <span className=\"absolute left-2 flex size-3.5 items-center justify-center\">\n <MenubarPrimitive.ItemIndicator>\n <DotFilledIcon className=\"size-4 fill-current\" />\n </MenubarPrimitive.ItemIndicator>\n </span>\n {children}\n </MenubarPrimitive.RadioItem>\n ),\n);\n\nMenubarRadioItem.displayName = MenubarPrimitive.RadioItem.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarLabel\n * -------------------------------------------------------------------------- */\n\ntype MenubarLabelElement = React.ElementRef<typeof MenubarPrimitive.Label>;\n\ninterface MenubarLabelProps extends React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Label> {\n inset?: boolean;\n}\n\nconst MenubarLabel = React.forwardRef<MenubarLabelElement, MenubarLabelProps>(({ className, inset, ...props }, ref) => (\n <MenubarPrimitive.Label\n ref={ref}\n className={cn('px-2 py-1.5 text-sm font-semibold', inset && 'pl-8', className)}\n {...props}\n />\n));\n\nMenubarLabel.displayName = MenubarPrimitive.Label.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarSeparator\n * -------------------------------------------------------------------------- */\n\ntype MenubarSeparatorElement = React.ElementRef<typeof MenubarPrimitive.Separator>;\ntype MenubarSeparatorProps = React.ComponentPropsWithoutRef<typeof MenubarPrimitive.Separator>;\n\nconst MenubarSeparator = React.forwardRef<MenubarSeparatorElement, MenubarSeparatorProps>(\n ({ className, ...props }, ref) => (\n <MenubarPrimitive.Separator ref={ref} className={cn('bg-muted -mx-1 my-1 h-px', className)} {...props} />\n ),\n);\n\nMenubarSeparator.displayName = MenubarPrimitive.Separator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: MenubarShortcut\n * -------------------------------------------------------------------------- */\n\ntype MenubarShortcutProps = React.HTMLAttributes<HTMLSpanElement>;\n\nfunction MenubarShortcut({ className, ...props }: MenubarShortcutProps): React.JSX.Element {\n return <span className={cn('text-muted-foreground ml-auto text-xs tracking-widest', className)} {...props} />;\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Menubar,\n MenubarMenu,\n MenubarTrigger,\n MenubarContent,\n MenubarItem,\n MenubarSeparator,\n MenubarLabel,\n MenubarCheckboxItem,\n MenubarRadioGroup,\n MenubarRadioItem,\n MenubarSubContent,\n MenubarSubTrigger,\n MenubarGroup,\n MenubarSub,\n MenubarShortcut,\n type MenubarProps,\n type MenubarMenuProps,\n type MenubarTriggerProps,\n type MenubarContentProps,\n type MenubarItemProps,\n type MenubarSeparatorProps,\n type MenubarLabelProps,\n type MenubarCheckboxItemProps,\n type MenubarRadioGroupProps,\n type MenubarRadioItemProps,\n type MenubarSubContentProps,\n type MenubarSubTriggerProps,\n type MenubarGroupProps,\n type MenubarSubProps,\n type MenubarShortcutProps,\n};\n"],"mappings":"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","names":["React","CheckIcon","ChevronRightIcon","DotFilledIcon","MenubarPrimitive","jsx","jsxs","MenubarMenu","MenubarGroup","MenubarSub","MenubarRadioGroup","Menubar","className","props","ref","cn","MenubarTrigger","MenubarSubTrigger","children","inset","ChevronRightIcon","MenubarSubContent","MenubarContent","align","alignOffset","sideOffset","MenubarItem","MenubarCheckboxItem","checked","CheckIcon","MenubarRadioItem","DotFilledIcon","MenubarLabel","MenubarSeparator","MenubarShortcut"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/navigation-menu.tsx"],"names":["React","ChevronDownIcon","NavigationMenuPrimitive","jsx","jsxs","navigationMenuTriggerVariants","cva","NavigationMenu","children","className","props","ref","cn","NavigationMenuViewport","NavigationMenuList","NavigationMenuIndicator","NavigationMenuItem","NavigationMenuTrigger","NavigationMenuContent","NavigationMenuLink"],"mappings":"6DAEA,UAAYA,MAAW,QACvB,OAAS,mBAAAC,MAAuB,wBAChC,UAAYC,MAA6B,kCA0BvC,OASE,OAAAC,EATF,QAAAC,MAAA,oBAnBF,IAAMC,EAAgCC,EAAI,CACxC,KAAM,8YACR,CAAC,EAaKC,EAAuB,aAG3B,CAAC,CAAE,SAAAC,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IACpCP,EAAyB,OAAxB,CACC,IAAKO,EACL,UAAWC,EACT,kEACAH,CACF,EACC,GAAGC,EAEH,UAAAF,EACDL,EAACU,EAAA,EAAuB,GAC1B,CACD,EAEDN,EAAe,YAAsC,OAAK,YAa1D,IAAMO,EAA2B,aAG/B,CAAC,CAAE,SAAAN,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IACpCP,EAAyB,OAAxB,CACC,IAAKO,EACL,UAAWC,EACT,oEACAH,CACF,EACC,GAAGC,EAEH,UAAAF,EACDL,EAACY,EAAA,EAAwB,GAC3B,CACD,EAEDD,EAAmB,YAAsC,OAAK,YAU9D,IAAME,EAA6C,OAa7CC,EAA8B,aAGlC,CAAC,CAAE,SAAAT,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IACpCP,EAAyB,UAAxB,CACC,IAAKO,EACL,UAAWN,EAA8B,CACvC,UAAW,CAAC,QAASI,CAAS,CAChC,CAAC,EACA,GAAGC,EAEH,UAAAF,EACDL,EAACF,EAAA,CACC,UAAU,4EACV,cAAY,OACd,GACF,CACD,EAEDgB,EAAsB,YAAsC,UAAQ,YAapE,IAAMC,EAA8B,aAGlC,CAAC,CAAE,UAAAT,EAAW,GAAGC,CAAM,EAAGC,IAC1BR,EAAyB,UAAxB,CACC,IAAKQ,EACL,UAAWC,EACT,wVACAH,CACF,EACC,GAAGC,EACN,CACD,EAEDQ,EAAsB,YAAsC,UAAQ,YAUpE,IAAMC,EAA6C,OAa7CN,EAA+B,aAGnC,CAAC,CAAE,UAAAJ,EAAW,GAAGC,CAAM,EAAGC,IAC1BR,EAAC,OAAI,UAAU,oEACb,SAAAA,EAAyB,WAAxB,CACC,UAAWS,EACT,iaACAH,CACF,EACA,IAAKE,EACJ,GAAGD,EACN,EACF,CACD,EAEDG,EAAuB,YACG,WAAS,YAanC,IAAME,EAAgC,aAGpC,CAAC,CAAE,UAAAN,EAAW,GAAGC,CAAM,EAAGC,IAC1BR,EAAyB,YAAxB,CACC,IAAKQ,EACL,UAAWC,EACT,4JACAH,CACF,EACC,GAAGC,EAEJ,SAAAP,EAAC,OAAI,UAAU,8DAA8D,EAC/E,CACD,EAEDY,EAAwB,YACE,YAAU","sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { ChevronDownIcon } from '@radix-ui/react-icons';\nimport * as NavigationMenuPrimitive from '@radix-ui/react-navigation-menu';\nimport { cn, cva } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Variant: NavigationMenu\n * -------------------------------------------------------------------------- */\n\nconst navigationMenuTriggerVariants = cva({\n base: 'bg-background hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent/50 data-[active]:bg-accent/50 group inline-flex h-10 w-max items-center justify-center rounded-md px-3 py-2 text-sm font-medium transition focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 disabled:pointer-events-none disabled:opacity-50',\n});\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenu\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuElement = React.ElementRef<\n typeof NavigationMenuPrimitive.Root\n>;\ntype NavigationMenuProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Root\n>;\n\nconst NavigationMenu = React.forwardRef<\n NavigationMenuElement,\n NavigationMenuProps\n>(({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.Root\n ref={ref}\n className={cn(\n 'relative z-10 flex max-w-max flex-1 items-center justify-center',\n className,\n )}\n {...props}\n >\n {children}\n <NavigationMenuViewport />\n </NavigationMenuPrimitive.Root>\n));\n\nNavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuList\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuListElement = React.ElementRef<\n typeof NavigationMenuPrimitive.List\n>;\ntype NavigationMenuListProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.List\n>;\n\nconst NavigationMenuList = React.forwardRef<\n NavigationMenuListElement,\n NavigationMenuListProps\n>(({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.List\n ref={ref}\n className={cn(\n 'group flex flex-1 list-none items-center justify-center space-x-1',\n className,\n )}\n {...props}\n >\n {children}\n <NavigationMenuIndicator />\n </NavigationMenuPrimitive.List>\n));\n\nNavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuItem\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuItemProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Item\n>;\n\nconst NavigationMenuItem = NavigationMenuPrimitive.Item;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuTriggerElement = React.ElementRef<\n typeof NavigationMenuPrimitive.Trigger\n>;\ntype NavigationMenuTriggerProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Trigger\n>;\n\nconst NavigationMenuTrigger = React.forwardRef<\n NavigationMenuTriggerElement,\n NavigationMenuTriggerProps\n>(({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.Trigger\n ref={ref}\n className={navigationMenuTriggerVariants({\n className: ['group', className],\n })}\n {...props}\n >\n {children}\n <ChevronDownIcon\n className=\"relative top-px ml-1 size-3 transition group-data-[state=open]:rotate-180\"\n aria-hidden=\"true\"\n />\n </NavigationMenuPrimitive.Trigger>\n));\n\nNavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuContentElement = React.ElementRef<\n typeof NavigationMenuPrimitive.Content\n>;\ntype NavigationMenuContentProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Content\n>;\n\nconst NavigationMenuContent = React.forwardRef<\n NavigationMenuContentElement,\n NavigationMenuContentProps\n>(({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Content\n ref={ref}\n className={cn(\n 'data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 left-0 top-0 w-full md:absolute md:w-auto',\n className,\n )}\n {...props}\n />\n));\n\nNavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuLink\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuLinkProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Link\n>;\n\nconst NavigationMenuLink = NavigationMenuPrimitive.Link;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuViewport\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuViewportElement = React.ElementRef<\n typeof NavigationMenuPrimitive.Viewport\n>;\ntype NavigationMenuViewportProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Viewport\n>;\n\nconst NavigationMenuViewport = React.forwardRef<\n NavigationMenuViewportElement,\n NavigationMenuViewportProps\n>(({ className, ...props }, ref) => (\n <div className=\"perspective-[125rem] absolute left-0 top-full flex justify-center\">\n <NavigationMenuPrimitive.Viewport\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border transition-[width,height] sm:w-[var(--radix-navigation-menu-viewport-width)]',\n className,\n )}\n ref={ref}\n {...props}\n />\n </div>\n));\n\nNavigationMenuViewport.displayName =\n NavigationMenuPrimitive.Viewport.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuIndicator\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuIndicatorElement = React.ElementRef<\n typeof NavigationMenuPrimitive.Indicator\n>;\ntype NavigationMenuIndicatorProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Indicator\n>;\n\nconst NavigationMenuIndicator = React.forwardRef<\n NavigationMenuIndicatorElement,\n NavigationMenuIndicatorProps\n>(({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Indicator\n ref={ref}\n className={cn(\n 'data-[state=visible]:animate-fade-in data-[state=hidden]:animate-fade-out top-full z-10 flex h-1.5 items-center justify-center overflow-hidden transition',\n className,\n )}\n {...props}\n >\n <div className=\"bg-border relative top-[60%] size-2 rotate-45 rounded-tl-sm\" />\n </NavigationMenuPrimitive.Indicator>\n));\n\nNavigationMenuIndicator.displayName =\n NavigationMenuPrimitive.Indicator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n navigationMenuTriggerVariants,\n NavigationMenu,\n NavigationMenuList,\n NavigationMenuItem,\n NavigationMenuContent,\n NavigationMenuTrigger,\n NavigationMenuLink,\n type NavigationMenuProps,\n type NavigationMenuListProps,\n type NavigationMenuItemProps,\n type NavigationMenuContentProps,\n type NavigationMenuTriggerProps,\n type NavigationMenuLinkProps,\n};\n"]}
1
+ {"version":3,"sources":["../../src/react/navigation-menu.tsx"],"names":["React","ChevronDownIcon","NavigationMenuPrimitive","jsx","jsxs","navigationMenuTriggerVariants","cva","NavigationMenu","children","className","props","ref","cn","NavigationMenuViewport","NavigationMenuList","NavigationMenuIndicator","NavigationMenuItem","NavigationMenuTrigger","NavigationMenuContent","NavigationMenuLink"],"mappings":"6DAEA,UAAYA,MAAW,QACvB,OAAS,mBAAAC,MAAuB,wBAChC,UAAYC,MAA6B,kCAoBrC,OAME,OAAAC,EANF,QAAAC,MAAA,oBAbJ,IAAMC,EAAgCC,EAAI,CACxC,KAAM,8YACR,CAAC,EASKC,EAAuB,aAC3B,CAAC,CAAE,SAAAC,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAClCP,EAAyB,OAAxB,CACC,IAAKO,EACL,UAAWC,EAAG,kEAAmEH,CAAS,EACzF,GAAGC,EAEH,UAAAF,EACDL,EAACU,EAAA,EAAuB,GAC1B,CAEJ,EAEAN,EAAe,YAAsC,OAAK,YAS1D,IAAMO,EAA2B,aAC/B,CAAC,CAAE,SAAAN,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAClCP,EAAyB,OAAxB,CACC,IAAKO,EACL,UAAWC,EAAG,oEAAqEH,CAAS,EAC3F,GAAGC,EAEH,UAAAF,EACDL,EAACY,EAAA,EAAwB,GAC3B,CAEJ,EAEAD,EAAmB,YAAsC,OAAK,YAQ9D,IAAME,EAA6C,OAS7CC,EAA8B,aAClC,CAAC,CAAE,SAAAT,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAClCP,EAAyB,UAAxB,CACC,IAAKO,EACL,UAAWN,EAA8B,CACvC,UAAW,CAAC,QAASI,CAAS,CAChC,CAAC,EACA,GAAGC,EAEH,UAAAF,EACDL,EAACF,EAAA,CACC,UAAU,4EACV,cAAY,OACd,GACF,CAEJ,EAEAgB,EAAsB,YAAsC,UAAQ,YASpE,IAAMC,EAA8B,aAClC,CAAC,CAAE,UAAAT,EAAW,GAAGC,CAAM,EAAGC,IACxBR,EAAyB,UAAxB,CACC,IAAKQ,EACL,UAAWC,EACT,wVACAH,CACF,EACC,GAAGC,EACN,CAEJ,EAEAQ,EAAsB,YAAsC,UAAQ,YAQpE,IAAMC,EAA6C,OAS7CN,EAA+B,aACnC,CAAC,CAAE,UAAAJ,EAAW,GAAGC,CAAM,EAAGC,IACxBR,EAAC,OAAI,UAAU,oEACb,SAAAA,EAAyB,WAAxB,CACC,UAAWS,EACT,iaACAH,CACF,EACA,IAAKE,EACJ,GAAGD,EACN,EACF,CAEJ,EAEAG,EAAuB,YAAsC,WAAS,YAStE,IAAME,EAAgC,aACpC,CAAC,CAAE,UAAAN,EAAW,GAAGC,CAAM,EAAGC,IACxBR,EAAyB,YAAxB,CACC,IAAKQ,EACL,UAAWC,EACT,4JACAH,CACF,EACC,GAAGC,EAEJ,SAAAP,EAAC,OAAI,UAAU,8DAA8D,EAC/E,CAEJ,EAEAY,EAAwB,YAAsC,YAAU","sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { ChevronDownIcon } from '@radix-ui/react-icons';\nimport * as NavigationMenuPrimitive from '@radix-ui/react-navigation-menu';\nimport { cn, cva } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Variant: NavigationMenu\n * -------------------------------------------------------------------------- */\n\nconst navigationMenuTriggerVariants = cva({\n base: 'bg-background hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent/50 data-[active]:bg-accent/50 group inline-flex h-10 w-max items-center justify-center rounded-md px-3 py-2 text-sm font-medium transition focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 disabled:pointer-events-none disabled:opacity-50',\n});\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenu\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuElement = React.ElementRef<typeof NavigationMenuPrimitive.Root>;\ntype NavigationMenuProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Root>;\n\nconst NavigationMenu = React.forwardRef<NavigationMenuElement, NavigationMenuProps>(\n ({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.Root\n ref={ref}\n className={cn('relative z-10 flex max-w-max flex-1 items-center justify-center', className)}\n {...props}\n >\n {children}\n <NavigationMenuViewport />\n </NavigationMenuPrimitive.Root>\n ),\n);\n\nNavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuList\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuListElement = React.ElementRef<typeof NavigationMenuPrimitive.List>;\ntype NavigationMenuListProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.List>;\n\nconst NavigationMenuList = React.forwardRef<NavigationMenuListElement, NavigationMenuListProps>(\n ({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.List\n ref={ref}\n className={cn('group flex flex-1 list-none items-center justify-center space-x-1', className)}\n {...props}\n >\n {children}\n <NavigationMenuIndicator />\n </NavigationMenuPrimitive.List>\n ),\n);\n\nNavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuItem\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuItemProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Item>;\n\nconst NavigationMenuItem = NavigationMenuPrimitive.Item;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuTriggerElement = React.ElementRef<typeof NavigationMenuPrimitive.Trigger>;\ntype NavigationMenuTriggerProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Trigger>;\n\nconst NavigationMenuTrigger = React.forwardRef<NavigationMenuTriggerElement, NavigationMenuTriggerProps>(\n ({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.Trigger\n ref={ref}\n className={navigationMenuTriggerVariants({\n className: ['group', className],\n })}\n {...props}\n >\n {children}\n <ChevronDownIcon\n className=\"relative top-px ml-1 size-3 transition group-data-[state=open]:rotate-180\"\n aria-hidden=\"true\"\n />\n </NavigationMenuPrimitive.Trigger>\n ),\n);\n\nNavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuContentElement = React.ElementRef<typeof NavigationMenuPrimitive.Content>;\ntype NavigationMenuContentProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Content>;\n\nconst NavigationMenuContent = React.forwardRef<NavigationMenuContentElement, NavigationMenuContentProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Content\n ref={ref}\n className={cn(\n 'data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 left-0 top-0 w-full md:absolute md:w-auto',\n className,\n )}\n {...props}\n />\n ),\n);\n\nNavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuLink\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuLinkProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Link>;\n\nconst NavigationMenuLink = NavigationMenuPrimitive.Link;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuViewport\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuViewportElement = React.ElementRef<typeof NavigationMenuPrimitive.Viewport>;\ntype NavigationMenuViewportProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Viewport>;\n\nconst NavigationMenuViewport = React.forwardRef<NavigationMenuViewportElement, NavigationMenuViewportProps>(\n ({ className, ...props }, ref) => (\n <div className=\"perspective-[125rem] absolute left-0 top-full flex justify-center\">\n <NavigationMenuPrimitive.Viewport\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border transition-[width,height] sm:w-[var(--radix-navigation-menu-viewport-width)]',\n className,\n )}\n ref={ref}\n {...props}\n />\n </div>\n ),\n);\n\nNavigationMenuViewport.displayName = NavigationMenuPrimitive.Viewport.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuIndicator\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuIndicatorElement = React.ElementRef<typeof NavigationMenuPrimitive.Indicator>;\ntype NavigationMenuIndicatorProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Indicator>;\n\nconst NavigationMenuIndicator = React.forwardRef<NavigationMenuIndicatorElement, NavigationMenuIndicatorProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Indicator\n ref={ref}\n className={cn(\n 'data-[state=visible]:animate-fade-in data-[state=hidden]:animate-fade-out top-full z-10 flex h-1.5 items-center justify-center overflow-hidden transition',\n className,\n )}\n {...props}\n >\n <div className=\"bg-border relative top-[60%] size-2 rotate-45 rounded-tl-sm\" />\n </NavigationMenuPrimitive.Indicator>\n ),\n);\n\nNavigationMenuIndicator.displayName = NavigationMenuPrimitive.Indicator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n navigationMenuTriggerVariants,\n NavigationMenu,\n NavigationMenuList,\n NavigationMenuItem,\n NavigationMenuContent,\n NavigationMenuTrigger,\n NavigationMenuLink,\n type NavigationMenuProps,\n type NavigationMenuListProps,\n type NavigationMenuItemProps,\n type NavigationMenuContentProps,\n type NavigationMenuTriggerProps,\n type NavigationMenuLinkProps,\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/navigation-menu.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { ChevronDownIcon } from '@radix-ui/react-icons';\nimport * as NavigationMenuPrimitive from '@radix-ui/react-navigation-menu';\nimport { cn, cva } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Variant: NavigationMenu\n * -------------------------------------------------------------------------- */\n\nconst navigationMenuTriggerVariants = cva({\n base: 'bg-background hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent/50 data-[active]:bg-accent/50 group inline-flex h-10 w-max items-center justify-center rounded-md px-3 py-2 text-sm font-medium transition focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 disabled:pointer-events-none disabled:opacity-50',\n});\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenu\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuElement = React.ElementRef<\n typeof NavigationMenuPrimitive.Root\n>;\ntype NavigationMenuProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Root\n>;\n\nconst NavigationMenu = React.forwardRef<\n NavigationMenuElement,\n NavigationMenuProps\n>(({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.Root\n ref={ref}\n className={cn(\n 'relative z-10 flex max-w-max flex-1 items-center justify-center',\n className,\n )}\n {...props}\n >\n {children}\n <NavigationMenuViewport />\n </NavigationMenuPrimitive.Root>\n));\n\nNavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuList\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuListElement = React.ElementRef<\n typeof NavigationMenuPrimitive.List\n>;\ntype NavigationMenuListProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.List\n>;\n\nconst NavigationMenuList = React.forwardRef<\n NavigationMenuListElement,\n NavigationMenuListProps\n>(({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.List\n ref={ref}\n className={cn(\n 'group flex flex-1 list-none items-center justify-center space-x-1',\n className,\n )}\n {...props}\n >\n {children}\n <NavigationMenuIndicator />\n </NavigationMenuPrimitive.List>\n));\n\nNavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuItem\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuItemProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Item\n>;\n\nconst NavigationMenuItem = NavigationMenuPrimitive.Item;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuTriggerElement = React.ElementRef<\n typeof NavigationMenuPrimitive.Trigger\n>;\ntype NavigationMenuTriggerProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Trigger\n>;\n\nconst NavigationMenuTrigger = React.forwardRef<\n NavigationMenuTriggerElement,\n NavigationMenuTriggerProps\n>(({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.Trigger\n ref={ref}\n className={navigationMenuTriggerVariants({\n className: ['group', className],\n })}\n {...props}\n >\n {children}\n <ChevronDownIcon\n className=\"relative top-px ml-1 size-3 transition group-data-[state=open]:rotate-180\"\n aria-hidden=\"true\"\n />\n </NavigationMenuPrimitive.Trigger>\n));\n\nNavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuContentElement = React.ElementRef<\n typeof NavigationMenuPrimitive.Content\n>;\ntype NavigationMenuContentProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Content\n>;\n\nconst NavigationMenuContent = React.forwardRef<\n NavigationMenuContentElement,\n NavigationMenuContentProps\n>(({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Content\n ref={ref}\n className={cn(\n 'data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 left-0 top-0 w-full md:absolute md:w-auto',\n className,\n )}\n {...props}\n />\n));\n\nNavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuLink\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuLinkProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Link\n>;\n\nconst NavigationMenuLink = NavigationMenuPrimitive.Link;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuViewport\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuViewportElement = React.ElementRef<\n typeof NavigationMenuPrimitive.Viewport\n>;\ntype NavigationMenuViewportProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Viewport\n>;\n\nconst NavigationMenuViewport = React.forwardRef<\n NavigationMenuViewportElement,\n NavigationMenuViewportProps\n>(({ className, ...props }, ref) => (\n <div className=\"perspective-[125rem] absolute left-0 top-full flex justify-center\">\n <NavigationMenuPrimitive.Viewport\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border transition-[width,height] sm:w-[var(--radix-navigation-menu-viewport-width)]',\n className,\n )}\n ref={ref}\n {...props}\n />\n </div>\n));\n\nNavigationMenuViewport.displayName =\n NavigationMenuPrimitive.Viewport.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuIndicator\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuIndicatorElement = React.ElementRef<\n typeof NavigationMenuPrimitive.Indicator\n>;\ntype NavigationMenuIndicatorProps = React.ComponentPropsWithoutRef<\n typeof NavigationMenuPrimitive.Indicator\n>;\n\nconst NavigationMenuIndicator = React.forwardRef<\n NavigationMenuIndicatorElement,\n NavigationMenuIndicatorProps\n>(({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Indicator\n ref={ref}\n className={cn(\n 'data-[state=visible]:animate-fade-in data-[state=hidden]:animate-fade-out top-full z-10 flex h-1.5 items-center justify-center overflow-hidden transition',\n className,\n )}\n {...props}\n >\n <div className=\"bg-border relative top-[60%] size-2 rotate-45 rounded-tl-sm\" />\n </NavigationMenuPrimitive.Indicator>\n));\n\nNavigationMenuIndicator.displayName =\n NavigationMenuPrimitive.Indicator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n navigationMenuTriggerVariants,\n NavigationMenu,\n NavigationMenuList,\n NavigationMenuItem,\n NavigationMenuContent,\n NavigationMenuTrigger,\n NavigationMenuLink,\n type NavigationMenuProps,\n type NavigationMenuListProps,\n type NavigationMenuItemProps,\n type NavigationMenuContentProps,\n type NavigationMenuTriggerProps,\n type NavigationMenuLinkProps,\n};\n"],"mappings":"8DAEA,UAAYA,MAAW,QACvB,OAAS,mBAAAC,MAAuB,wBAChC,UAAYC,MAA6B,kCA0BvC,OASE,OAAAC,EATF,QAAAC,MAAA,oBAnBF,IAAMC,EAAgCC,EAAI,CACxC,KAAM,8YACR,CAAC,EAaKC,EAAuB,aAG3B,CAAC,CAAE,SAAAC,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IACpCP,EAAyB,OAAxB,CACC,IAAKO,EACL,UAAWC,EACT,kEACAH,CACF,EACC,GAAGC,EAEH,UAAAF,EACDL,EAACU,EAAA,EAAuB,GAC1B,CACD,EAEDN,EAAe,YAAsC,OAAK,YAa1D,IAAMO,EAA2B,aAG/B,CAAC,CAAE,SAAAN,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IACpCP,EAAyB,OAAxB,CACC,IAAKO,EACL,UAAWC,EACT,oEACAH,CACF,EACC,GAAGC,EAEH,UAAAF,EACDL,EAACY,EAAA,EAAwB,GAC3B,CACD,EAEDD,EAAmB,YAAsC,OAAK,YAU9D,IAAME,EAA6C,OAa7CC,EAA8B,aAGlC,CAAC,CAAE,SAAAT,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IACpCP,EAAyB,UAAxB,CACC,IAAKO,EACL,UAAWN,EAA8B,CACvC,UAAW,CAAC,QAASI,CAAS,CAChC,CAAC,EACA,GAAGC,EAEH,UAAAF,EACDL,EAACe,EAAA,CACC,UAAU,4EACV,cAAY,OACd,GACF,CACD,EAEDD,EAAsB,YAAsC,UAAQ,YAapE,IAAME,EAA8B,aAGlC,CAAC,CAAE,UAAAV,EAAW,GAAGC,CAAM,EAAGC,IAC1BR,EAAyB,UAAxB,CACC,IAAKQ,EACL,UAAWC,EACT,wVACAH,CACF,EACC,GAAGC,EACN,CACD,EAEDS,EAAsB,YAAsC,UAAQ,YAUpE,IAAMC,EAA6C,OAa7CP,EAA+B,aAGnC,CAAC,CAAE,UAAAJ,EAAW,GAAGC,CAAM,EAAGC,IAC1BR,EAAC,OAAI,UAAU,oEACb,SAAAA,EAAyB,WAAxB,CACC,UAAWS,EACT,iaACAH,CACF,EACA,IAAKE,EACJ,GAAGD,EACN,EACF,CACD,EAEDG,EAAuB,YACG,WAAS,YAanC,IAAME,EAAgC,aAGpC,CAAC,CAAE,UAAAN,EAAW,GAAGC,CAAM,EAAGC,IAC1BR,EAAyB,YAAxB,CACC,IAAKQ,EACL,UAAWC,EACT,4JACAH,CACF,EACC,GAAGC,EAEJ,SAAAP,EAAC,OAAI,UAAU,8DAA8D,EAC/E,CACD,EAEDY,EAAwB,YACE,YAAU","names":["React","ChevronDownIcon","NavigationMenuPrimitive","jsx","jsxs","navigationMenuTriggerVariants","cva","NavigationMenu","children","className","props","ref","cn","NavigationMenuViewport","NavigationMenuList","NavigationMenuIndicator","NavigationMenuItem","NavigationMenuTrigger","ChevronDownIcon","NavigationMenuContent","NavigationMenuLink"]}
1
+ {"version":3,"sources":["../../src/react/navigation-menu.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { ChevronDownIcon } from '@radix-ui/react-icons';\nimport * as NavigationMenuPrimitive from '@radix-ui/react-navigation-menu';\nimport { cn, cva } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Variant: NavigationMenu\n * -------------------------------------------------------------------------- */\n\nconst navigationMenuTriggerVariants = cva({\n base: 'bg-background hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent/50 data-[active]:bg-accent/50 group inline-flex h-10 w-max items-center justify-center rounded-md px-3 py-2 text-sm font-medium transition focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 disabled:pointer-events-none disabled:opacity-50',\n});\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenu\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuElement = React.ElementRef<typeof NavigationMenuPrimitive.Root>;\ntype NavigationMenuProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Root>;\n\nconst NavigationMenu = React.forwardRef<NavigationMenuElement, NavigationMenuProps>(\n ({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.Root\n ref={ref}\n className={cn('relative z-10 flex max-w-max flex-1 items-center justify-center', className)}\n {...props}\n >\n {children}\n <NavigationMenuViewport />\n </NavigationMenuPrimitive.Root>\n ),\n);\n\nNavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuList\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuListElement = React.ElementRef<typeof NavigationMenuPrimitive.List>;\ntype NavigationMenuListProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.List>;\n\nconst NavigationMenuList = React.forwardRef<NavigationMenuListElement, NavigationMenuListProps>(\n ({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.List\n ref={ref}\n className={cn('group flex flex-1 list-none items-center justify-center space-x-1', className)}\n {...props}\n >\n {children}\n <NavigationMenuIndicator />\n </NavigationMenuPrimitive.List>\n ),\n);\n\nNavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuItem\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuItemProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Item>;\n\nconst NavigationMenuItem = NavigationMenuPrimitive.Item;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuTriggerElement = React.ElementRef<typeof NavigationMenuPrimitive.Trigger>;\ntype NavigationMenuTriggerProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Trigger>;\n\nconst NavigationMenuTrigger = React.forwardRef<NavigationMenuTriggerElement, NavigationMenuTriggerProps>(\n ({ children, className, ...props }, ref) => (\n <NavigationMenuPrimitive.Trigger\n ref={ref}\n className={navigationMenuTriggerVariants({\n className: ['group', className],\n })}\n {...props}\n >\n {children}\n <ChevronDownIcon\n className=\"relative top-px ml-1 size-3 transition group-data-[state=open]:rotate-180\"\n aria-hidden=\"true\"\n />\n </NavigationMenuPrimitive.Trigger>\n ),\n);\n\nNavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuContentElement = React.ElementRef<typeof NavigationMenuPrimitive.Content>;\ntype NavigationMenuContentProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Content>;\n\nconst NavigationMenuContent = React.forwardRef<NavigationMenuContentElement, NavigationMenuContentProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Content\n ref={ref}\n className={cn(\n 'data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 left-0 top-0 w-full md:absolute md:w-auto',\n className,\n )}\n {...props}\n />\n ),\n);\n\nNavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuLink\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuLinkProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Link>;\n\nconst NavigationMenuLink = NavigationMenuPrimitive.Link;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuViewport\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuViewportElement = React.ElementRef<typeof NavigationMenuPrimitive.Viewport>;\ntype NavigationMenuViewportProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Viewport>;\n\nconst NavigationMenuViewport = React.forwardRef<NavigationMenuViewportElement, NavigationMenuViewportProps>(\n ({ className, ...props }, ref) => (\n <div className=\"perspective-[125rem] absolute left-0 top-full flex justify-center\">\n <NavigationMenuPrimitive.Viewport\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border transition-[width,height] sm:w-[var(--radix-navigation-menu-viewport-width)]',\n className,\n )}\n ref={ref}\n {...props}\n />\n </div>\n ),\n);\n\nNavigationMenuViewport.displayName = NavigationMenuPrimitive.Viewport.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuIndicator\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuIndicatorElement = React.ElementRef<typeof NavigationMenuPrimitive.Indicator>;\ntype NavigationMenuIndicatorProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Indicator>;\n\nconst NavigationMenuIndicator = React.forwardRef<NavigationMenuIndicatorElement, NavigationMenuIndicatorProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Indicator\n ref={ref}\n className={cn(\n 'data-[state=visible]:animate-fade-in data-[state=hidden]:animate-fade-out top-full z-10 flex h-1.5 items-center justify-center overflow-hidden transition',\n className,\n )}\n {...props}\n >\n <div className=\"bg-border relative top-[60%] size-2 rotate-45 rounded-tl-sm\" />\n </NavigationMenuPrimitive.Indicator>\n ),\n);\n\nNavigationMenuIndicator.displayName = NavigationMenuPrimitive.Indicator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n navigationMenuTriggerVariants,\n NavigationMenu,\n NavigationMenuList,\n NavigationMenuItem,\n NavigationMenuContent,\n NavigationMenuTrigger,\n NavigationMenuLink,\n type NavigationMenuProps,\n type NavigationMenuListProps,\n type NavigationMenuItemProps,\n type NavigationMenuContentProps,\n type NavigationMenuTriggerProps,\n type NavigationMenuLinkProps,\n};\n"],"mappings":"8DAEA,UAAYA,MAAW,QACvB,OAAS,mBAAAC,MAAuB,wBAChC,UAAYC,MAA6B,kCAoBrC,OAME,OAAAC,EANF,QAAAC,MAAA,oBAbJ,IAAMC,EAAgCC,EAAI,CACxC,KAAM,8YACR,CAAC,EASKC,EAAuB,aAC3B,CAAC,CAAE,SAAAC,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAClCP,EAAyB,OAAxB,CACC,IAAKO,EACL,UAAWC,EAAG,kEAAmEH,CAAS,EACzF,GAAGC,EAEH,UAAAF,EACDL,EAACU,EAAA,EAAuB,GAC1B,CAEJ,EAEAN,EAAe,YAAsC,OAAK,YAS1D,IAAMO,EAA2B,aAC/B,CAAC,CAAE,SAAAN,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAClCP,EAAyB,OAAxB,CACC,IAAKO,EACL,UAAWC,EAAG,oEAAqEH,CAAS,EAC3F,GAAGC,EAEH,UAAAF,EACDL,EAACY,EAAA,EAAwB,GAC3B,CAEJ,EAEAD,EAAmB,YAAsC,OAAK,YAQ9D,IAAME,EAA6C,OAS7CC,EAA8B,aAClC,CAAC,CAAE,SAAAT,EAAU,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAClCP,EAAyB,UAAxB,CACC,IAAKO,EACL,UAAWN,EAA8B,CACvC,UAAW,CAAC,QAASI,CAAS,CAChC,CAAC,EACA,GAAGC,EAEH,UAAAF,EACDL,EAACe,EAAA,CACC,UAAU,4EACV,cAAY,OACd,GACF,CAEJ,EAEAD,EAAsB,YAAsC,UAAQ,YASpE,IAAME,EAA8B,aAClC,CAAC,CAAE,UAAAV,EAAW,GAAGC,CAAM,EAAGC,IACxBR,EAAyB,UAAxB,CACC,IAAKQ,EACL,UAAWC,EACT,wVACAH,CACF,EACC,GAAGC,EACN,CAEJ,EAEAS,EAAsB,YAAsC,UAAQ,YAQpE,IAAMC,EAA6C,OAS7CP,EAA+B,aACnC,CAAC,CAAE,UAAAJ,EAAW,GAAGC,CAAM,EAAGC,IACxBR,EAAC,OAAI,UAAU,oEACb,SAAAA,EAAyB,WAAxB,CACC,UAAWS,EACT,iaACAH,CACF,EACA,IAAKE,EACJ,GAAGD,EACN,EACF,CAEJ,EAEAG,EAAuB,YAAsC,WAAS,YAStE,IAAME,EAAgC,aACpC,CAAC,CAAE,UAAAN,EAAW,GAAGC,CAAM,EAAGC,IACxBR,EAAyB,YAAxB,CACC,IAAKQ,EACL,UAAWC,EACT,4JACAH,CACF,EACC,GAAGC,EAEJ,SAAAP,EAAC,OAAI,UAAU,8DAA8D,EAC/E,CAEJ,EAEAY,EAAwB,YAAsC,YAAU","names":["React","ChevronDownIcon","NavigationMenuPrimitive","jsx","jsxs","navigationMenuTriggerVariants","cva","NavigationMenu","children","className","props","ref","cn","NavigationMenuViewport","NavigationMenuList","NavigationMenuIndicator","NavigationMenuItem","NavigationMenuTrigger","ChevronDownIcon","NavigationMenuContent","NavigationMenuLink"]}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } }var _chunkX3LRJQM3js = require('../chunk-X3LRJQM3.js');require('../chunk-ZTEJNUH6.js');var _chunkHQ4AUOQMjs = require('../chunk-HQ4AUOQM.js');var _react = require('react'); var o = _interopRequireWildcard(_react);var _reacticons = require('@radix-ui/react-icons');var _jsxruntime = require('react/jsx-runtime');function N({className:n,...t}){return _jsxruntime.jsx.call(void 0, "nav",{role:"navigation","aria-label":"pagination",className:_chunkHQ4AUOQMjs.b.call(void 0, "mx-auto flex w-full justify-center",n),...t})}var u=o.forwardRef(({className:n,...t},i)=>_jsxruntime.jsx.call(void 0, "ul",{ref:i,className:_chunkHQ4AUOQMjs.b.call(void 0, "flex flex-row items-center gap-1",n),...t}));u.displayName="PaginationContent";var f=o.forwardRef((n,t)=>_jsxruntime.jsx.call(void 0, "li",{ref:t,...n}));f.displayName="PaginationItem";function p({className:n,isActive:t,size:i="icon",children:P,...l}){return _jsxruntime.jsx.call(void 0, "a",{"aria-current":t?"page":void 0,className:_chunkX3LRJQM3js.a.call(void 0, {variant:t?"outline":"ghost",size:i,className:n}),...l,children:P})}function R({className:n,...t}){return _jsxruntime.jsxs.call(void 0, p,{"aria-label":"Go to previous page",size:"default",className:_chunkHQ4AUOQMjs.b.call(void 0, "gap-1 pl-2.5",n),...t,children:[_jsxruntime.jsx.call(void 0, _reacticons.ChevronLeftIcon,{className:"size-4"}),_jsxruntime.jsx.call(void 0, "span",{children:"Previous"})]})}function H({className:n,...t}){return _jsxruntime.jsxs.call(void 0, p,{"aria-label":"Go to next page",size:"default",className:_chunkHQ4AUOQMjs.b.call(void 0, "gap-1 pr-2.5",n),...t,children:[_jsxruntime.jsx.call(void 0, "span",{children:"Next"}),_jsxruntime.jsx.call(void 0, _reacticons.ChevronRightIcon,{className:"size-4"})]})}function M({className:n,...t}){return _jsxruntime.jsxs.call(void 0, "span",{"aria-hidden":!0,className:_chunkHQ4AUOQMjs.b.call(void 0, "flex size-10 items-center justify-center",n),...t,children:[_jsxruntime.jsx.call(void 0, _reacticons.DotsHorizontalIcon,{className:"size-4"}),_jsxruntime.jsx.call(void 0, "span",{className:"sr-only",children:"More pages"})]})}exports.Pagination = N; exports.PaginationContent = u; exports.PaginationEllipsis = M; exports.PaginationItem = f; exports.PaginationLink = p; exports.PaginationNext = H; exports.PaginationPrevious = R;
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } }var _chunkVZVI3OHHjs = require('../chunk-VZVI3OHH.js');require('../chunk-46W6RAYD.js');var _chunkHQ4AUOQMjs = require('../chunk-HQ4AUOQM.js');var _react = require('react'); var o = _interopRequireWildcard(_react);var _reacticons = require('@radix-ui/react-icons');var _jsxruntime = require('react/jsx-runtime');function N({className:n,...t}){return _jsxruntime.jsx.call(void 0, "nav",{role:"navigation","aria-label":"pagination",className:_chunkHQ4AUOQMjs.b.call(void 0, "mx-auto flex w-full justify-center",n),...t})}var u=o.forwardRef(({className:n,...t},i)=>_jsxruntime.jsx.call(void 0, "ul",{ref:i,className:_chunkHQ4AUOQMjs.b.call(void 0, "flex flex-row items-center gap-1",n),...t}));u.displayName="PaginationContent";var f=o.forwardRef((n,t)=>_jsxruntime.jsx.call(void 0, "li",{ref:t,...n}));f.displayName="PaginationItem";function p({className:n,isActive:t,size:i="icon",children:P,...l}){return _jsxruntime.jsx.call(void 0, "a",{"aria-current":t?"page":void 0,className:_chunkVZVI3OHHjs.a.call(void 0, {variant:t?"outline":"ghost",size:i,className:n}),...l,children:P})}function R({className:n,...t}){return _jsxruntime.jsxs.call(void 0, p,{"aria-label":"Go to previous page",size:"default",className:_chunkHQ4AUOQMjs.b.call(void 0, "gap-1 pl-2.5",n),...t,children:[_jsxruntime.jsx.call(void 0, _reacticons.ChevronLeftIcon,{className:"size-4"}),_jsxruntime.jsx.call(void 0, "span",{children:"Previous"})]})}function H({className:n,...t}){return _jsxruntime.jsxs.call(void 0, p,{"aria-label":"Go to next page",size:"default",className:_chunkHQ4AUOQMjs.b.call(void 0, "gap-1 pr-2.5",n),...t,children:[_jsxruntime.jsx.call(void 0, "span",{children:"Next"}),_jsxruntime.jsx.call(void 0, _reacticons.ChevronRightIcon,{className:"size-4"})]})}function M({className:n,...t}){return _jsxruntime.jsxs.call(void 0, "span",{"aria-hidden":!0,className:_chunkHQ4AUOQMjs.b.call(void 0, "flex size-10 items-center justify-center",n),...t,children:[_jsxruntime.jsx.call(void 0, _reacticons.DotsHorizontalIcon,{className:"size-4"}),_jsxruntime.jsx.call(void 0, "span",{className:"sr-only",children:"More pages"})]})}exports.Pagination = N; exports.PaginationContent = u; exports.PaginationEllipsis = M; exports.PaginationItem = f; exports.PaginationLink = p; exports.PaginationNext = H; exports.PaginationPrevious = R;
2
2
  //# sourceMappingURL=pagination.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/pagination.tsx"],"names":["React","ChevronLeftIcon","ChevronRightIcon","DotsHorizontalIcon","jsx","jsxs","Pagination","className","props","cn","PaginationContent","ref","PaginationItem","PaginationLink","isActive","size","children","buttonVariants","PaginationPrevious","PaginationNext","PaginationEllipsis"],"mappings":"+GAAA,UAAYA,MAAW,QACvB,OACE,mBAAAC,EACA,oBAAAC,EACA,sBAAAC,MACK,wBAeH,cAAAC,EAsFA,QAAAC,MAtFA,oBALJ,SAASC,EAAW,CAClB,UAAAC,EACA,GAAGC,CACL,EAAuC,CACrC,OACEJ,EAAC,OACC,KAAK,aACL,aAAW,aACX,UAAWK,EAAG,qCAAsCF,CAAS,EAC5D,GAAGC,EACN,CAEJ,CASA,IAAME,EAA0B,aAG9B,CAAC,CAAE,UAAAH,EAAW,GAAGC,CAAM,EAAGG,IAC1BP,EAAC,MACC,IAAKO,EACL,UAAWF,EAAG,mCAAoCF,CAAS,EAC1D,GAAGC,EACN,CACD,EAEDE,EAAkB,YAAc,oBAShC,IAAME,EAAuB,aAG3B,CAACJ,EAAOG,IAAQP,EAAC,MAAG,IAAKO,EAAM,GAAGH,EAAO,CAAE,EAE7CI,EAAe,YAAc,iBAY7B,SAASC,EAAe,CACtB,UAAAN,EACA,SAAAO,EACA,KAAAC,EAAO,OACP,SAAAC,EACA,GAAGR,CACL,EAA2C,CACzC,OACEJ,EAAC,KACC,eAAcU,EAAW,OAAS,OAClC,UAAWG,EAAe,CACxB,QAASH,EAAW,UAAY,QAChC,KAAAC,EACA,UAAAR,CACF,CAAC,EACA,GAAGC,EAEH,SAAAQ,EACH,CAEJ,CAQA,SAASE,EAAmB,CAC1B,UAAAX,EACA,GAAGC,CACL,EAA+C,CAC7C,OACEH,EAACQ,EAAA,CACC,aAAW,sBACX,KAAK,UACL,UAAWJ,EAAG,eAAgBF,CAAS,EACtC,GAAGC,EAEJ,UAAAJ,EAACH,EAAA,CAAgB,UAAU,SAAS,EACpCG,EAAC,QAAK,oBAAQ,GAChB,CAEJ,CAQA,SAASe,EAAe,CACtB,UAAAZ,EACA,GAAGC,CACL,EAA2C,CACzC,OACEH,EAACQ,EAAA,CACC,aAAW,kBACX,KAAK,UACL,UAAWJ,EAAG,eAAgBF,CAAS,EACtC,GAAGC,EAEJ,UAAAJ,EAAC,QAAK,gBAAI,EACVA,EAACF,EAAA,CAAiB,UAAU,SAAS,GACvC,CAEJ,CAQA,SAASkB,EAAmB,CAC1B,UAAAb,EACA,GAAGC,CACL,EAA+C,CAC7C,OACEH,EAAC,QACC,cAAW,GACX,UAAWI,EAAG,2CAA4CF,CAAS,EAClE,GAAGC,EAEJ,UAAAJ,EAACD,EAAA,CAAmB,UAAU,SAAS,EACvCC,EAAC,QAAK,UAAU,UAAU,sBAAU,GACtC,CAEJ","sourcesContent":["import * as React from 'react';\nimport {\n ChevronLeftIcon,\n ChevronRightIcon,\n DotsHorizontalIcon,\n} from '@radix-ui/react-icons';\nimport { cn } from '../lib/utils';\nimport { type ButtonProps, buttonVariants } from './button';\n\n/* -----------------------------------------------------------------------------\n * Component: Pagination\n * -------------------------------------------------------------------------- */\n\ntype PaginationProps = React.HTMLAttributes<HTMLElement>;\n\nfunction Pagination({\n className,\n ...props\n}: PaginationProps): React.JSX.Element {\n return (\n <nav\n role=\"navigation\"\n aria-label=\"pagination\"\n className={cn('mx-auto flex w-full justify-center', className)}\n {...props}\n />\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationContent\n * -------------------------------------------------------------------------- */\n\ntype PaginationContentElement = HTMLUListElement;\ntype PaginationContentProps = React.HTMLAttributes<HTMLUListElement>;\n\nconst PaginationContent = React.forwardRef<\n PaginationContentElement,\n PaginationContentProps\n>(({ className, ...props }, ref) => (\n <ul\n ref={ref}\n className={cn('flex flex-row items-center gap-1', className)}\n {...props}\n />\n));\n\nPaginationContent.displayName = 'PaginationContent';\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationItem\n * -------------------------------------------------------------------------- */\n\ntype PaginationItemElement = HTMLLIElement;\ntype PaginationItemProps = React.LiHTMLAttributes<HTMLLIElement>;\n\nconst PaginationItem = React.forwardRef<\n PaginationItemElement,\n PaginationItemProps\n>((props, ref) => <li ref={ref} {...props} />);\n\nPaginationItem.displayName = 'PaginationItem';\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationLink\n * -------------------------------------------------------------------------- */\n\ninterface PaginationLinkProps\n extends React.AnchorHTMLAttributes<HTMLAnchorElement>,\n Pick<ButtonProps, 'size'> {\n isActive?: boolean;\n}\n\nfunction PaginationLink({\n className,\n isActive,\n size = 'icon',\n children,\n ...props\n}: PaginationLinkProps): React.JSX.Element {\n return (\n <a\n aria-current={isActive ? 'page' : undefined}\n className={buttonVariants({\n variant: isActive ? 'outline' : 'ghost',\n size,\n className,\n })}\n {...props}\n >\n {children}\n </a>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationPrevious\n * -------------------------------------------------------------------------- */\n\ntype PaginationPreviousProps = PaginationLinkProps;\n\nfunction PaginationPrevious({\n className,\n ...props\n}: PaginationPreviousProps): React.JSX.Element {\n return (\n <PaginationLink\n aria-label=\"Go to previous page\"\n size=\"default\"\n className={cn('gap-1 pl-2.5', className)}\n {...props}\n >\n <ChevronLeftIcon className=\"size-4\" />\n <span>Previous</span>\n </PaginationLink>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationNext\n * -------------------------------------------------------------------------- */\n\ntype PaginationNextProps = PaginationLinkProps;\n\nfunction PaginationNext({\n className,\n ...props\n}: PaginationNextProps): React.JSX.Element {\n return (\n <PaginationLink\n aria-label=\"Go to next page\"\n size=\"default\"\n className={cn('gap-1 pr-2.5', className)}\n {...props}\n >\n <span>Next</span>\n <ChevronRightIcon className=\"size-4\" />\n </PaginationLink>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationEllipsis\n * -------------------------------------------------------------------------- */\n\ntype PaginationEllipsisProps = React.HTMLAttributes<HTMLSpanElement>;\n\nfunction PaginationEllipsis({\n className,\n ...props\n}: PaginationEllipsisProps): React.JSX.Element {\n return (\n <span\n aria-hidden\n className={cn('flex size-10 items-center justify-center', className)}\n {...props}\n >\n <DotsHorizontalIcon className=\"size-4\" />\n <span className=\"sr-only\">More pages</span>\n </span>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Pagination,\n PaginationContent,\n PaginationLink,\n PaginationItem,\n PaginationPrevious,\n PaginationNext,\n PaginationEllipsis,\n type PaginationProps,\n type PaginationContentProps,\n type PaginationLinkProps,\n type PaginationItemProps,\n type PaginationPreviousProps,\n type PaginationNextProps,\n type PaginationEllipsisProps,\n};\n"]}
1
+ {"version":3,"sources":["../../src/react/pagination.tsx"],"names":["React","ChevronLeftIcon","ChevronRightIcon","DotsHorizontalIcon","jsx","jsxs","Pagination","className","props","cn","PaginationContent","ref","PaginationItem","PaginationLink","isActive","size","children","buttonVariants","PaginationPrevious","PaginationNext","PaginationEllipsis"],"mappings":"+GAAA,UAAYA,MAAW,QACvB,OAAS,mBAAAC,EAAiB,oBAAAC,EAAkB,sBAAAC,MAA0B,wBAalE,cAAAC,EA2EA,QAAAC,MA3EA,oBAFJ,SAASC,EAAW,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAuC,CAC/E,OACEJ,EAAC,OACC,KAAK,aACL,aAAW,aACX,UAAWK,EAAG,qCAAsCF,CAAS,EAC5D,GAAGC,EACN,CAEJ,CASA,IAAME,EAA0B,aAC9B,CAAC,CAAE,UAAAH,EAAW,GAAGC,CAAM,EAAGG,IACxBP,EAAC,MAAG,IAAKO,EAAK,UAAWF,EAAG,mCAAoCF,CAAS,EAAI,GAAGC,EAAO,CAE3F,EAEAE,EAAkB,YAAc,oBAShC,IAAME,EAAuB,aAAuD,CAACJ,EAAOG,IAC1FP,EAAC,MAAG,IAAKO,EAAM,GAAGH,EAAO,CAC1B,EAEDI,EAAe,YAAc,iBAU7B,SAASC,EAAe,CACtB,UAAAN,EACA,SAAAO,EACA,KAAAC,EAAO,OACP,SAAAC,EACA,GAAGR,CACL,EAA2C,CACzC,OACEJ,EAAC,KACC,eAAcU,EAAW,OAAS,OAClC,UAAWG,EAAe,CACxB,QAASH,EAAW,UAAY,QAChC,KAAAC,EACA,UAAAR,CACF,CAAC,EACA,GAAGC,EAEH,SAAAQ,EACH,CAEJ,CAQA,SAASE,EAAmB,CAAE,UAAAX,EAAW,GAAGC,CAAM,EAA+C,CAC/F,OACEH,EAACQ,EAAA,CACC,aAAW,sBACX,KAAK,UACL,UAAWJ,EAAG,eAAgBF,CAAS,EACtC,GAAGC,EAEJ,UAAAJ,EAACH,EAAA,CAAgB,UAAU,SAAS,EACpCG,EAAC,QAAK,oBAAQ,GAChB,CAEJ,CAQA,SAASe,EAAe,CAAE,UAAAZ,EAAW,GAAGC,CAAM,EAA2C,CACvF,OACEH,EAACQ,EAAA,CAAe,aAAW,kBAAkB,KAAK,UAAU,UAAWJ,EAAG,eAAgBF,CAAS,EAAI,GAAGC,EACxG,UAAAJ,EAAC,QAAK,gBAAI,EACVA,EAACF,EAAA,CAAiB,UAAU,SAAS,GACvC,CAEJ,CAQA,SAASkB,EAAmB,CAAE,UAAAb,EAAW,GAAGC,CAAM,EAA+C,CAC/F,OACEH,EAAC,QAAK,cAAW,GAAC,UAAWI,EAAG,2CAA4CF,CAAS,EAAI,GAAGC,EAC1F,UAAAJ,EAACD,EAAA,CAAmB,UAAU,SAAS,EACvCC,EAAC,QAAK,UAAU,UAAU,sBAAU,GACtC,CAEJ","sourcesContent":["import * as React from 'react';\nimport { ChevronLeftIcon, ChevronRightIcon, DotsHorizontalIcon } from '@radix-ui/react-icons';\nimport { cn } from '../lib/utils';\nimport { buttonVariants } from './button';\nimport type { ButtonProps } from './button';\n\n/* -----------------------------------------------------------------------------\n * Component: Pagination\n * -------------------------------------------------------------------------- */\n\ntype PaginationProps = React.HTMLAttributes<HTMLElement>;\n\nfunction Pagination({ className, ...props }: PaginationProps): React.JSX.Element {\n return (\n <nav\n role=\"navigation\"\n aria-label=\"pagination\"\n className={cn('mx-auto flex w-full justify-center', className)}\n {...props}\n />\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationContent\n * -------------------------------------------------------------------------- */\n\ntype PaginationContentElement = HTMLUListElement;\ntype PaginationContentProps = React.HTMLAttributes<HTMLUListElement>;\n\nconst PaginationContent = React.forwardRef<PaginationContentElement, PaginationContentProps>(\n ({ className, ...props }, ref) => (\n <ul ref={ref} className={cn('flex flex-row items-center gap-1', className)} {...props} />\n ),\n);\n\nPaginationContent.displayName = 'PaginationContent';\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationItem\n * -------------------------------------------------------------------------- */\n\ntype PaginationItemElement = HTMLLIElement;\ntype PaginationItemProps = React.LiHTMLAttributes<HTMLLIElement>;\n\nconst PaginationItem = React.forwardRef<PaginationItemElement, PaginationItemProps>((props, ref) => (\n <li ref={ref} {...props} />\n));\n\nPaginationItem.displayName = 'PaginationItem';\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationLink\n * -------------------------------------------------------------------------- */\n\ninterface PaginationLinkProps extends React.AnchorHTMLAttributes<HTMLAnchorElement>, Pick<ButtonProps, 'size'> {\n isActive?: boolean;\n}\n\nfunction PaginationLink({\n className,\n isActive,\n size = 'icon',\n children,\n ...props\n}: PaginationLinkProps): React.JSX.Element {\n return (\n <a\n aria-current={isActive ? 'page' : undefined}\n className={buttonVariants({\n variant: isActive ? 'outline' : 'ghost',\n size,\n className,\n })}\n {...props}\n >\n {children}\n </a>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationPrevious\n * -------------------------------------------------------------------------- */\n\ntype PaginationPreviousProps = PaginationLinkProps;\n\nfunction PaginationPrevious({ className, ...props }: PaginationPreviousProps): React.JSX.Element {\n return (\n <PaginationLink\n aria-label=\"Go to previous page\"\n size=\"default\"\n className={cn('gap-1 pl-2.5', className)}\n {...props}\n >\n <ChevronLeftIcon className=\"size-4\" />\n <span>Previous</span>\n </PaginationLink>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationNext\n * -------------------------------------------------------------------------- */\n\ntype PaginationNextProps = PaginationLinkProps;\n\nfunction PaginationNext({ className, ...props }: PaginationNextProps): React.JSX.Element {\n return (\n <PaginationLink aria-label=\"Go to next page\" size=\"default\" className={cn('gap-1 pr-2.5', className)} {...props}>\n <span>Next</span>\n <ChevronRightIcon className=\"size-4\" />\n </PaginationLink>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationEllipsis\n * -------------------------------------------------------------------------- */\n\ntype PaginationEllipsisProps = React.HTMLAttributes<HTMLSpanElement>;\n\nfunction PaginationEllipsis({ className, ...props }: PaginationEllipsisProps): React.JSX.Element {\n return (\n <span aria-hidden className={cn('flex size-10 items-center justify-center', className)} {...props}>\n <DotsHorizontalIcon className=\"size-4\" />\n <span className=\"sr-only\">More pages</span>\n </span>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Pagination,\n PaginationContent,\n PaginationLink,\n PaginationItem,\n PaginationPrevious,\n PaginationNext,\n PaginationEllipsis,\n type PaginationProps,\n type PaginationContentProps,\n type PaginationLinkProps,\n type PaginationItemProps,\n type PaginationPreviousProps,\n type PaginationNextProps,\n type PaginationEllipsisProps,\n};\n"]}
@@ -1,2 +1,2 @@
1
- import{a as r}from"../chunk-47CSACCM.mjs";import"../chunk-P5AV3QU7.mjs";import{b as e}from"../chunk-LEUB3C3L.mjs";import*as o from"react";import{ChevronLeftIcon as g,ChevronRightIcon as m,DotsHorizontalIcon as c}from"@radix-ui/react-icons";import{jsx as a,jsxs as s}from"react/jsx-runtime";function N({className:n,...t}){return a("nav",{role:"navigation","aria-label":"pagination",className:e("mx-auto flex w-full justify-center",n),...t})}var u=o.forwardRef(({className:n,...t},i)=>a("ul",{ref:i,className:e("flex flex-row items-center gap-1",n),...t}));u.displayName="PaginationContent";var f=o.forwardRef((n,t)=>a("li",{ref:t,...n}));f.displayName="PaginationItem";function p({className:n,isActive:t,size:i="icon",children:P,...l}){return a("a",{"aria-current":t?"page":void 0,className:r({variant:t?"outline":"ghost",size:i,className:n}),...l,children:P})}function R({className:n,...t}){return s(p,{"aria-label":"Go to previous page",size:"default",className:e("gap-1 pl-2.5",n),...t,children:[a(g,{className:"size-4"}),a("span",{children:"Previous"})]})}function H({className:n,...t}){return s(p,{"aria-label":"Go to next page",size:"default",className:e("gap-1 pr-2.5",n),...t,children:[a("span",{children:"Next"}),a(m,{className:"size-4"})]})}function M({className:n,...t}){return s("span",{"aria-hidden":!0,className:e("flex size-10 items-center justify-center",n),...t,children:[a(c,{className:"size-4"}),a("span",{className:"sr-only",children:"More pages"})]})}export{N as Pagination,u as PaginationContent,M as PaginationEllipsis,f as PaginationItem,p as PaginationLink,H as PaginationNext,R as PaginationPrevious};
1
+ import{a as r}from"../chunk-7ABWX5CF.mjs";import"../chunk-BNKSZEF2.mjs";import{b as e}from"../chunk-LEUB3C3L.mjs";import*as o from"react";import{ChevronLeftIcon as g,ChevronRightIcon as m,DotsHorizontalIcon as c}from"@radix-ui/react-icons";import{jsx as a,jsxs as s}from"react/jsx-runtime";function N({className:n,...t}){return a("nav",{role:"navigation","aria-label":"pagination",className:e("mx-auto flex w-full justify-center",n),...t})}var u=o.forwardRef(({className:n,...t},i)=>a("ul",{ref:i,className:e("flex flex-row items-center gap-1",n),...t}));u.displayName="PaginationContent";var f=o.forwardRef((n,t)=>a("li",{ref:t,...n}));f.displayName="PaginationItem";function p({className:n,isActive:t,size:i="icon",children:P,...l}){return a("a",{"aria-current":t?"page":void 0,className:r({variant:t?"outline":"ghost",size:i,className:n}),...l,children:P})}function R({className:n,...t}){return s(p,{"aria-label":"Go to previous page",size:"default",className:e("gap-1 pl-2.5",n),...t,children:[a(g,{className:"size-4"}),a("span",{children:"Previous"})]})}function H({className:n,...t}){return s(p,{"aria-label":"Go to next page",size:"default",className:e("gap-1 pr-2.5",n),...t,children:[a("span",{children:"Next"}),a(m,{className:"size-4"})]})}function M({className:n,...t}){return s("span",{"aria-hidden":!0,className:e("flex size-10 items-center justify-center",n),...t,children:[a(c,{className:"size-4"}),a("span",{className:"sr-only",children:"More pages"})]})}export{N as Pagination,u as PaginationContent,M as PaginationEllipsis,f as PaginationItem,p as PaginationLink,H as PaginationNext,R as PaginationPrevious};
2
2
  //# sourceMappingURL=pagination.mjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/pagination.tsx"],"sourcesContent":["import * as React from 'react';\nimport {\n ChevronLeftIcon,\n ChevronRightIcon,\n DotsHorizontalIcon,\n} from '@radix-ui/react-icons';\nimport { cn } from '../lib/utils';\nimport { type ButtonProps, buttonVariants } from './button';\n\n/* -----------------------------------------------------------------------------\n * Component: Pagination\n * -------------------------------------------------------------------------- */\n\ntype PaginationProps = React.HTMLAttributes<HTMLElement>;\n\nfunction Pagination({\n className,\n ...props\n}: PaginationProps): React.JSX.Element {\n return (\n <nav\n role=\"navigation\"\n aria-label=\"pagination\"\n className={cn('mx-auto flex w-full justify-center', className)}\n {...props}\n />\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationContent\n * -------------------------------------------------------------------------- */\n\ntype PaginationContentElement = HTMLUListElement;\ntype PaginationContentProps = React.HTMLAttributes<HTMLUListElement>;\n\nconst PaginationContent = React.forwardRef<\n PaginationContentElement,\n PaginationContentProps\n>(({ className, ...props }, ref) => (\n <ul\n ref={ref}\n className={cn('flex flex-row items-center gap-1', className)}\n {...props}\n />\n));\n\nPaginationContent.displayName = 'PaginationContent';\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationItem\n * -------------------------------------------------------------------------- */\n\ntype PaginationItemElement = HTMLLIElement;\ntype PaginationItemProps = React.LiHTMLAttributes<HTMLLIElement>;\n\nconst PaginationItem = React.forwardRef<\n PaginationItemElement,\n PaginationItemProps\n>((props, ref) => <li ref={ref} {...props} />);\n\nPaginationItem.displayName = 'PaginationItem';\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationLink\n * -------------------------------------------------------------------------- */\n\ninterface PaginationLinkProps\n extends React.AnchorHTMLAttributes<HTMLAnchorElement>,\n Pick<ButtonProps, 'size'> {\n isActive?: boolean;\n}\n\nfunction PaginationLink({\n className,\n isActive,\n size = 'icon',\n children,\n ...props\n}: PaginationLinkProps): React.JSX.Element {\n return (\n <a\n aria-current={isActive ? 'page' : undefined}\n className={buttonVariants({\n variant: isActive ? 'outline' : 'ghost',\n size,\n className,\n })}\n {...props}\n >\n {children}\n </a>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationPrevious\n * -------------------------------------------------------------------------- */\n\ntype PaginationPreviousProps = PaginationLinkProps;\n\nfunction PaginationPrevious({\n className,\n ...props\n}: PaginationPreviousProps): React.JSX.Element {\n return (\n <PaginationLink\n aria-label=\"Go to previous page\"\n size=\"default\"\n className={cn('gap-1 pl-2.5', className)}\n {...props}\n >\n <ChevronLeftIcon className=\"size-4\" />\n <span>Previous</span>\n </PaginationLink>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationNext\n * -------------------------------------------------------------------------- */\n\ntype PaginationNextProps = PaginationLinkProps;\n\nfunction PaginationNext({\n className,\n ...props\n}: PaginationNextProps): React.JSX.Element {\n return (\n <PaginationLink\n aria-label=\"Go to next page\"\n size=\"default\"\n className={cn('gap-1 pr-2.5', className)}\n {...props}\n >\n <span>Next</span>\n <ChevronRightIcon className=\"size-4\" />\n </PaginationLink>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationEllipsis\n * -------------------------------------------------------------------------- */\n\ntype PaginationEllipsisProps = React.HTMLAttributes<HTMLSpanElement>;\n\nfunction PaginationEllipsis({\n className,\n ...props\n}: PaginationEllipsisProps): React.JSX.Element {\n return (\n <span\n aria-hidden\n className={cn('flex size-10 items-center justify-center', className)}\n {...props}\n >\n <DotsHorizontalIcon className=\"size-4\" />\n <span className=\"sr-only\">More pages</span>\n </span>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Pagination,\n PaginationContent,\n PaginationLink,\n PaginationItem,\n PaginationPrevious,\n PaginationNext,\n PaginationEllipsis,\n type PaginationProps,\n type PaginationContentProps,\n type PaginationLinkProps,\n type PaginationItemProps,\n type PaginationPreviousProps,\n type PaginationNextProps,\n type PaginationEllipsisProps,\n};\n"],"mappings":"kHAAA,UAAYA,MAAW,QACvB,OACE,mBAAAC,EACA,oBAAAC,EACA,sBAAAC,MACK,wBAeH,cAAAC,EAsFA,QAAAC,MAtFA,oBALJ,SAASC,EAAW,CAClB,UAAAC,EACA,GAAGC,CACL,EAAuC,CACrC,OACEJ,EAAC,OACC,KAAK,aACL,aAAW,aACX,UAAWK,EAAG,qCAAsCF,CAAS,EAC5D,GAAGC,EACN,CAEJ,CASA,IAAME,EAA0B,aAG9B,CAAC,CAAE,UAAAH,EAAW,GAAGC,CAAM,EAAGG,IAC1BP,EAAC,MACC,IAAKO,EACL,UAAWF,EAAG,mCAAoCF,CAAS,EAC1D,GAAGC,EACN,CACD,EAEDE,EAAkB,YAAc,oBAShC,IAAME,EAAuB,aAG3B,CAACJ,EAAOG,IAAQP,EAAC,MAAG,IAAKO,EAAM,GAAGH,EAAO,CAAE,EAE7CI,EAAe,YAAc,iBAY7B,SAASC,EAAe,CACtB,UAAAN,EACA,SAAAO,EACA,KAAAC,EAAO,OACP,SAAAC,EACA,GAAGR,CACL,EAA2C,CACzC,OACEJ,EAAC,KACC,eAAcU,EAAW,OAAS,OAClC,UAAWG,EAAe,CACxB,QAASH,EAAW,UAAY,QAChC,KAAAC,EACA,UAAAR,CACF,CAAC,EACA,GAAGC,EAEH,SAAAQ,EACH,CAEJ,CAQA,SAASE,EAAmB,CAC1B,UAAAX,EACA,GAAGC,CACL,EAA+C,CAC7C,OACEH,EAACQ,EAAA,CACC,aAAW,sBACX,KAAK,UACL,UAAWJ,EAAG,eAAgBF,CAAS,EACtC,GAAGC,EAEJ,UAAAJ,EAACe,EAAA,CAAgB,UAAU,SAAS,EACpCf,EAAC,QAAK,oBAAQ,GAChB,CAEJ,CAQA,SAASgB,EAAe,CACtB,UAAAb,EACA,GAAGC,CACL,EAA2C,CACzC,OACEH,EAACQ,EAAA,CACC,aAAW,kBACX,KAAK,UACL,UAAWJ,EAAG,eAAgBF,CAAS,EACtC,GAAGC,EAEJ,UAAAJ,EAAC,QAAK,gBAAI,EACVA,EAACiB,EAAA,CAAiB,UAAU,SAAS,GACvC,CAEJ,CAQA,SAASC,EAAmB,CAC1B,UAAAf,EACA,GAAGC,CACL,EAA+C,CAC7C,OACEH,EAAC,QACC,cAAW,GACX,UAAWI,EAAG,2CAA4CF,CAAS,EAClE,GAAGC,EAEJ,UAAAJ,EAACmB,EAAA,CAAmB,UAAU,SAAS,EACvCnB,EAAC,QAAK,UAAU,UAAU,sBAAU,GACtC,CAEJ","names":["React","ChevronLeftIcon","ChevronRightIcon","DotsHorizontalIcon","jsx","jsxs","Pagination","className","props","cn","PaginationContent","ref","PaginationItem","PaginationLink","isActive","size","children","buttonVariants","PaginationPrevious","ChevronLeftIcon","PaginationNext","ChevronRightIcon","PaginationEllipsis","DotsHorizontalIcon"]}
1
+ {"version":3,"sources":["../../src/react/pagination.tsx"],"sourcesContent":["import * as React from 'react';\nimport { ChevronLeftIcon, ChevronRightIcon, DotsHorizontalIcon } from '@radix-ui/react-icons';\nimport { cn } from '../lib/utils';\nimport { buttonVariants } from './button';\nimport type { ButtonProps } from './button';\n\n/* -----------------------------------------------------------------------------\n * Component: Pagination\n * -------------------------------------------------------------------------- */\n\ntype PaginationProps = React.HTMLAttributes<HTMLElement>;\n\nfunction Pagination({ className, ...props }: PaginationProps): React.JSX.Element {\n return (\n <nav\n role=\"navigation\"\n aria-label=\"pagination\"\n className={cn('mx-auto flex w-full justify-center', className)}\n {...props}\n />\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationContent\n * -------------------------------------------------------------------------- */\n\ntype PaginationContentElement = HTMLUListElement;\ntype PaginationContentProps = React.HTMLAttributes<HTMLUListElement>;\n\nconst PaginationContent = React.forwardRef<PaginationContentElement, PaginationContentProps>(\n ({ className, ...props }, ref) => (\n <ul ref={ref} className={cn('flex flex-row items-center gap-1', className)} {...props} />\n ),\n);\n\nPaginationContent.displayName = 'PaginationContent';\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationItem\n * -------------------------------------------------------------------------- */\n\ntype PaginationItemElement = HTMLLIElement;\ntype PaginationItemProps = React.LiHTMLAttributes<HTMLLIElement>;\n\nconst PaginationItem = React.forwardRef<PaginationItemElement, PaginationItemProps>((props, ref) => (\n <li ref={ref} {...props} />\n));\n\nPaginationItem.displayName = 'PaginationItem';\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationLink\n * -------------------------------------------------------------------------- */\n\ninterface PaginationLinkProps extends React.AnchorHTMLAttributes<HTMLAnchorElement>, Pick<ButtonProps, 'size'> {\n isActive?: boolean;\n}\n\nfunction PaginationLink({\n className,\n isActive,\n size = 'icon',\n children,\n ...props\n}: PaginationLinkProps): React.JSX.Element {\n return (\n <a\n aria-current={isActive ? 'page' : undefined}\n className={buttonVariants({\n variant: isActive ? 'outline' : 'ghost',\n size,\n className,\n })}\n {...props}\n >\n {children}\n </a>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationPrevious\n * -------------------------------------------------------------------------- */\n\ntype PaginationPreviousProps = PaginationLinkProps;\n\nfunction PaginationPrevious({ className, ...props }: PaginationPreviousProps): React.JSX.Element {\n return (\n <PaginationLink\n aria-label=\"Go to previous page\"\n size=\"default\"\n className={cn('gap-1 pl-2.5', className)}\n {...props}\n >\n <ChevronLeftIcon className=\"size-4\" />\n <span>Previous</span>\n </PaginationLink>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationNext\n * -------------------------------------------------------------------------- */\n\ntype PaginationNextProps = PaginationLinkProps;\n\nfunction PaginationNext({ className, ...props }: PaginationNextProps): React.JSX.Element {\n return (\n <PaginationLink aria-label=\"Go to next page\" size=\"default\" className={cn('gap-1 pr-2.5', className)} {...props}>\n <span>Next</span>\n <ChevronRightIcon className=\"size-4\" />\n </PaginationLink>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationEllipsis\n * -------------------------------------------------------------------------- */\n\ntype PaginationEllipsisProps = React.HTMLAttributes<HTMLSpanElement>;\n\nfunction PaginationEllipsis({ className, ...props }: PaginationEllipsisProps): React.JSX.Element {\n return (\n <span aria-hidden className={cn('flex size-10 items-center justify-center', className)} {...props}>\n <DotsHorizontalIcon className=\"size-4\" />\n <span className=\"sr-only\">More pages</span>\n </span>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Pagination,\n PaginationContent,\n PaginationLink,\n PaginationItem,\n PaginationPrevious,\n PaginationNext,\n PaginationEllipsis,\n type PaginationProps,\n type PaginationContentProps,\n type PaginationLinkProps,\n type PaginationItemProps,\n type PaginationPreviousProps,\n type PaginationNextProps,\n type PaginationEllipsisProps,\n};\n"],"mappings":"kHAAA,UAAYA,MAAW,QACvB,OAAS,mBAAAC,EAAiB,oBAAAC,EAAkB,sBAAAC,MAA0B,wBAalE,cAAAC,EA2EA,QAAAC,MA3EA,oBAFJ,SAASC,EAAW,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAuC,CAC/E,OACEJ,EAAC,OACC,KAAK,aACL,aAAW,aACX,UAAWK,EAAG,qCAAsCF,CAAS,EAC5D,GAAGC,EACN,CAEJ,CASA,IAAME,EAA0B,aAC9B,CAAC,CAAE,UAAAH,EAAW,GAAGC,CAAM,EAAGG,IACxBP,EAAC,MAAG,IAAKO,EAAK,UAAWF,EAAG,mCAAoCF,CAAS,EAAI,GAAGC,EAAO,CAE3F,EAEAE,EAAkB,YAAc,oBAShC,IAAME,EAAuB,aAAuD,CAACJ,EAAOG,IAC1FP,EAAC,MAAG,IAAKO,EAAM,GAAGH,EAAO,CAC1B,EAEDI,EAAe,YAAc,iBAU7B,SAASC,EAAe,CACtB,UAAAN,EACA,SAAAO,EACA,KAAAC,EAAO,OACP,SAAAC,EACA,GAAGR,CACL,EAA2C,CACzC,OACEJ,EAAC,KACC,eAAcU,EAAW,OAAS,OAClC,UAAWG,EAAe,CACxB,QAASH,EAAW,UAAY,QAChC,KAAAC,EACA,UAAAR,CACF,CAAC,EACA,GAAGC,EAEH,SAAAQ,EACH,CAEJ,CAQA,SAASE,EAAmB,CAAE,UAAAX,EAAW,GAAGC,CAAM,EAA+C,CAC/F,OACEH,EAACQ,EAAA,CACC,aAAW,sBACX,KAAK,UACL,UAAWJ,EAAG,eAAgBF,CAAS,EACtC,GAAGC,EAEJ,UAAAJ,EAACe,EAAA,CAAgB,UAAU,SAAS,EACpCf,EAAC,QAAK,oBAAQ,GAChB,CAEJ,CAQA,SAASgB,EAAe,CAAE,UAAAb,EAAW,GAAGC,CAAM,EAA2C,CACvF,OACEH,EAACQ,EAAA,CAAe,aAAW,kBAAkB,KAAK,UAAU,UAAWJ,EAAG,eAAgBF,CAAS,EAAI,GAAGC,EACxG,UAAAJ,EAAC,QAAK,gBAAI,EACVA,EAACiB,EAAA,CAAiB,UAAU,SAAS,GACvC,CAEJ,CAQA,SAASC,EAAmB,CAAE,UAAAf,EAAW,GAAGC,CAAM,EAA+C,CAC/F,OACEH,EAAC,QAAK,cAAW,GAAC,UAAWI,EAAG,2CAA4CF,CAAS,EAAI,GAAGC,EAC1F,UAAAJ,EAACmB,EAAA,CAAmB,UAAU,SAAS,EACvCnB,EAAC,QAAK,UAAU,UAAU,sBAAU,GACtC,CAEJ","names":["React","ChevronLeftIcon","ChevronRightIcon","DotsHorizontalIcon","jsx","jsxs","Pagination","className","props","cn","PaginationContent","ref","PaginationItem","PaginationLink","isActive","size","children","buttonVariants","PaginationPrevious","ChevronLeftIcon","PaginationNext","ChevronRightIcon","PaginationEllipsis","DotsHorizontalIcon"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/react/popover.tsx"],"names":["React","PopoverPrimitive","jsx","Popover","PopoverTrigger","PopoverAnchor","PopoverContent","className","align","sideOffset","props","ref","cn","PopoverArrow"],"mappings":"sDAEA,UAAYA,MAAW,QACvB,UAAYC,MAAsB,0BA0C9B,cAAAC,MAAA,oBAlCJ,IAAMC,EAA2B,OAS3BC,EAAkC,UASlCC,EAAiC,SAWjCC,EAAuB,aAG3B,CAAC,CAAE,UAAAC,EAAW,MAAAC,EAAQ,SAAU,WAAAC,EAAa,EAAG,GAAGC,CAAM,EAAGC,IAC5DT,EAAkB,SAAjB,CACC,SAAAA,EAAkB,UAAjB,CACC,IAAKS,EACL,MAAOH,EACP,WAAYC,EACZ,UAAWG,EACT,gtBACAL,CACF,EACC,GAAGG,EACN,EACF,CACD,EAEDJ,EAAe,YAA+B,UAAQ,YAWtD,IAAMO,EAAqB,aACzB,CAAC,CAAE,UAAAN,EAAW,GAAGG,CAAM,EAAGC,IACxBT,EAAkB,QAAjB,CACC,IAAKS,EACL,UAAWC,EAAG,eAAgBL,CAAS,EACtC,GAAGG,EACN,CAEJ,EAEAG,EAAa,YAA+B,QAAM","sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: Popover\n * -------------------------------------------------------------------------- */\n\ntype PopoverProps = React.ComponentProps<typeof PopoverPrimitive.Root>;\nconst Popover = PopoverPrimitive.Root;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverTrigger\n * -------------------------------------------------------------------------- */\n\ntype PopoverTriggerProps = React.ComponentPropsWithoutRef<\n typeof PopoverPrimitive.Trigger\n>;\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverAnchor\n * -------------------------------------------------------------------------- */\n\ntype PopoverAnchorProps = React.ComponentPropsWithoutRef<\n typeof PopoverPrimitive.Anchor\n>;\nconst PopoverAnchor = PopoverPrimitive.Anchor;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverContent\n * -------------------------------------------------------------------------- */\n\ntype PopoverContentElement = React.ElementRef<typeof PopoverPrimitive.Content>;\ntype PopoverContentProps = React.ComponentPropsWithoutRef<\n typeof PopoverPrimitive.Content\n>;\n\nconst PopoverContent = React.forwardRef<\n PopoverContentElement,\n PopoverContentProps\n>(({ className, align = 'center', sideOffset = 6, ...props }, ref) => (\n <PopoverPrimitive.Portal>\n <PopoverPrimitive.Content\n ref={ref}\n align={align}\n sideOffset={sideOffset}\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-95 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 data-[state=closed]:data-[side=top]:slide-out-to-bottom-2 data-[state=closed]:data-[side=left]:slide-out-to-right-2 data-[state=closed]:data-[side=bottom]:slide-out-to-top-2 data-[state=closed]:data-[side=right]:slide-out-to-left-2 z-50 min-w-32 rounded-md border p-4 shadow-md',\n className,\n )}\n {...props}\n />\n </PopoverPrimitive.Portal>\n));\n\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverArrow\n * -------------------------------------------------------------------------- */\n\ntype PopoverArrowElement = React.ElementRef<typeof PopoverPrimitive.Arrow>;\ntype PopoverArrowProps = React.ComponentPropsWithoutRef<\n typeof PopoverPrimitive.Arrow\n>;\n\nconst PopoverArrow = React.forwardRef<PopoverArrowElement, PopoverArrowProps>(\n ({ className, ...props }, ref) => (\n <PopoverPrimitive.Arrow\n ref={ref}\n className={cn('fill-popover', className)}\n {...props}\n />\n ),\n);\n\nPopoverArrow.displayName = PopoverPrimitive.Arrow.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Popover,\n PopoverTrigger,\n PopoverContent,\n PopoverAnchor,\n PopoverArrow,\n type PopoverProps,\n type PopoverTriggerProps,\n type PopoverContentProps,\n type PopoverAnchorProps,\n type PopoverArrowProps,\n};\n"]}
1
+ {"version":3,"sources":["../../src/react/popover.tsx"],"names":["React","PopoverPrimitive","jsx","Popover","PopoverTrigger","PopoverAnchor","PopoverContent","className","align","sideOffset","props","ref","cn","PopoverArrow"],"mappings":"sDAEA,UAAYA,MAAW,QACvB,UAAYC,MAAsB,0BAkC5B,cAAAC,MAAA,oBA1BN,IAAMC,EAA2B,OAO3BC,EAAkC,UAOlCC,EAAiC,SASjCC,EAAuB,aAC3B,CAAC,CAAE,UAAAC,EAAW,MAAAC,EAAQ,SAAU,WAAAC,EAAa,EAAG,GAAGC,CAAM,EAAGC,IAC1DT,EAAkB,SAAjB,CACC,SAAAA,EAAkB,UAAjB,CACC,IAAKS,EACL,MAAOH,EACP,WAAYC,EACZ,UAAWG,EACT,gtBACAL,CACF,EACC,GAAGG,EACN,EACF,CAEJ,EAEAJ,EAAe,YAA+B,UAAQ,YAStD,IAAMO,EAAqB,aAAmD,CAAC,CAAE,UAAAN,EAAW,GAAGG,CAAM,EAAGC,IACtGT,EAAkB,QAAjB,CAAuB,IAAKS,EAAK,UAAWC,EAAG,eAAgBL,CAAS,EAAI,GAAGG,EAAO,CACxF,EAEDG,EAAa,YAA+B,QAAM","sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\nimport { cn } from '../lib/utils';\n\n/* -----------------------------------------------------------------------------\n * Component: Popover\n * -------------------------------------------------------------------------- */\n\ntype PopoverProps = React.ComponentProps<typeof PopoverPrimitive.Root>;\nconst Popover = PopoverPrimitive.Root;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverTrigger\n * -------------------------------------------------------------------------- */\n\ntype PopoverTriggerProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Trigger>;\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverAnchor\n * -------------------------------------------------------------------------- */\n\ntype PopoverAnchorProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Anchor>;\nconst PopoverAnchor = PopoverPrimitive.Anchor;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverContent\n * -------------------------------------------------------------------------- */\n\ntype PopoverContentElement = React.ElementRef<typeof PopoverPrimitive.Content>;\ntype PopoverContentProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Content>;\n\nconst PopoverContent = React.forwardRef<PopoverContentElement, PopoverContentProps>(\n ({ className, align = 'center', sideOffset = 6, ...props }, ref) => (\n <PopoverPrimitive.Portal>\n <PopoverPrimitive.Content\n ref={ref}\n align={align}\n sideOffset={sideOffset}\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-95 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 data-[state=closed]:data-[side=top]:slide-out-to-bottom-2 data-[state=closed]:data-[side=left]:slide-out-to-right-2 data-[state=closed]:data-[side=bottom]:slide-out-to-top-2 data-[state=closed]:data-[side=right]:slide-out-to-left-2 z-50 min-w-32 rounded-md border p-4 shadow-md',\n className,\n )}\n {...props}\n />\n </PopoverPrimitive.Portal>\n ),\n);\n\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverArrow\n * -------------------------------------------------------------------------- */\n\ntype PopoverArrowElement = React.ElementRef<typeof PopoverPrimitive.Arrow>;\ntype PopoverArrowProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Arrow>;\n\nconst PopoverArrow = React.forwardRef<PopoverArrowElement, PopoverArrowProps>(({ className, ...props }, ref) => (\n <PopoverPrimitive.Arrow ref={ref} className={cn('fill-popover', className)} {...props} />\n));\n\nPopoverArrow.displayName = PopoverPrimitive.Arrow.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Popover,\n PopoverTrigger,\n PopoverContent,\n PopoverAnchor,\n PopoverArrow,\n type PopoverProps,\n type PopoverTriggerProps,\n type PopoverContentProps,\n type PopoverAnchorProps,\n type PopoverArrowProps,\n};\n"]}