@codefast/ui 0.0.8 → 0.0.10

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 (459) hide show
  1. package/dist/accordion.d.mts +8 -4
  2. package/dist/accordion.d.ts +8 -4
  3. package/dist/accordion.js +42 -32
  4. package/dist/accordion.js.map +1 -1
  5. package/dist/accordion.mjs +42 -32
  6. package/dist/accordion.mjs.map +1 -1
  7. package/dist/alert-dialog.d.mts +17 -8
  8. package/dist/alert-dialog.d.ts +17 -8
  9. package/dist/alert-dialog.js +47 -75
  10. package/dist/alert-dialog.js.map +1 -1
  11. package/dist/alert-dialog.mjs +47 -75
  12. package/dist/alert-dialog.mjs.map +1 -1
  13. package/dist/alert.d.mts +10 -5
  14. package/dist/alert.d.ts +10 -5
  15. package/dist/alert.js +5 -26
  16. package/dist/alert.js.map +1 -1
  17. package/dist/alert.mjs +5 -26
  18. package/dist/alert.mjs.map +1 -1
  19. package/dist/aspect-ratio.d.mts +2 -1
  20. package/dist/aspect-ratio.d.ts +2 -1
  21. package/dist/aspect-ratio.js.map +1 -1
  22. package/dist/aspect-ratio.mjs.map +1 -1
  23. package/dist/avatar.d.mts +7 -4
  24. package/dist/avatar.d.ts +7 -4
  25. package/dist/avatar.js +3 -16
  26. package/dist/avatar.js.map +1 -1
  27. package/dist/avatar.mjs +3 -16
  28. package/dist/avatar.mjs.map +1 -1
  29. package/dist/badge.d.mts +5 -2
  30. package/dist/badge.d.ts +5 -2
  31. package/dist/badge.js +1 -5
  32. package/dist/badge.js.map +1 -1
  33. package/dist/badge.mjs +1 -5
  34. package/dist/badge.mjs.map +1 -1
  35. package/dist/blockquote.d.mts +5 -4
  36. package/dist/blockquote.d.ts +5 -4
  37. package/dist/blockquote.js.map +1 -1
  38. package/dist/blockquote.mjs.map +1 -1
  39. package/dist/box.d.mts +1 -1
  40. package/dist/box.d.ts +1 -1
  41. package/dist/box.js +4 -6
  42. package/dist/box.js.map +1 -1
  43. package/dist/box.mjs +4 -6
  44. package/dist/box.mjs.map +1 -1
  45. package/dist/breadcrumb.d.mts +18 -11
  46. package/dist/breadcrumb.d.ts +18 -11
  47. package/dist/breadcrumb.js +12 -39
  48. package/dist/breadcrumb.js.map +1 -1
  49. package/dist/breadcrumb.mjs +12 -39
  50. package/dist/breadcrumb.mjs.map +1 -1
  51. package/dist/button.d.mts +4 -2
  52. package/dist/button.d.ts +4 -2
  53. package/dist/button.js +3 -2
  54. package/dist/button.mjs +2 -1
  55. package/dist/calendar.d.mts +3 -2
  56. package/dist/calendar.d.ts +3 -2
  57. package/dist/calendar.js +7 -19
  58. package/dist/calendar.js.map +1 -1
  59. package/dist/calendar.mjs +6 -18
  60. package/dist/calendar.mjs.map +1 -1
  61. package/dist/card.d.mts +13 -7
  62. package/dist/card.d.ts +13 -7
  63. package/dist/card.js +7 -44
  64. package/dist/card.js.map +1 -1
  65. package/dist/card.mjs +7 -44
  66. package/dist/card.mjs.map +1 -1
  67. package/dist/carousel.d.mts +13 -8
  68. package/dist/carousel.d.ts +13 -8
  69. package/dist/carousel.js +104 -104
  70. package/dist/carousel.js.map +1 -1
  71. package/dist/carousel.mjs +104 -104
  72. package/dist/carousel.mjs.map +1 -1
  73. package/dist/checkbox-cards.d.mts +15 -0
  74. package/dist/checkbox-cards.d.ts +15 -0
  75. package/dist/checkbox-cards.js +56 -0
  76. package/dist/checkbox-cards.js.map +1 -0
  77. package/dist/checkbox-cards.mjs +56 -0
  78. package/dist/checkbox-cards.mjs.map +1 -0
  79. package/dist/checkbox-group.d.mts +13 -0
  80. package/dist/checkbox-group.d.ts +13 -0
  81. package/dist/checkbox-group.js +44 -0
  82. package/dist/checkbox-group.js.map +1 -0
  83. package/dist/checkbox-group.mjs +44 -0
  84. package/dist/checkbox-group.mjs.map +1 -0
  85. package/dist/checkbox-group.primitive.d.mts +38 -0
  86. package/dist/checkbox-group.primitive.d.ts +38 -0
  87. package/dist/checkbox-group.primitive.js +19 -0
  88. package/dist/checkbox-group.primitive.js.map +1 -0
  89. package/dist/checkbox-group.primitive.mjs +19 -0
  90. package/dist/checkbox-group.primitive.mjs.map +1 -0
  91. package/dist/checkbox.d.mts +3 -2
  92. package/dist/checkbox.d.ts +3 -2
  93. package/dist/checkbox.js +5 -1
  94. package/dist/checkbox.js.map +1 -1
  95. package/dist/checkbox.mjs +5 -1
  96. package/dist/checkbox.mjs.map +1 -1
  97. package/dist/chunk-3ZZ3SRTJ.js +148 -0
  98. package/dist/chunk-3ZZ3SRTJ.js.map +1 -0
  99. package/dist/chunk-5UHPKXF4.mjs +60 -0
  100. package/dist/chunk-5UHPKXF4.mjs.map +1 -0
  101. package/dist/chunk-EWS3N4OZ.mjs +148 -0
  102. package/dist/chunk-EWS3N4OZ.mjs.map +1 -0
  103. package/dist/{chunk-PTD4AMHI.mjs → chunk-FGI3JA75.mjs} +1 -1
  104. package/dist/chunk-FGI3JA75.mjs.map +1 -0
  105. package/dist/{chunk-RTKEO347.js → chunk-IVYGBU4G.js} +1 -1
  106. package/dist/chunk-IVYGBU4G.js.map +1 -0
  107. package/dist/chunk-IXEJO7ZP.js +86 -0
  108. package/dist/chunk-IXEJO7ZP.js.map +1 -0
  109. package/dist/chunk-J6COVJTP.js +60 -0
  110. package/dist/chunk-J6COVJTP.js.map +1 -0
  111. package/dist/chunk-JULVZPCS.mjs +120 -0
  112. package/dist/chunk-JULVZPCS.mjs.map +1 -0
  113. package/dist/chunk-LNSEYAPJ.js +121 -0
  114. package/dist/chunk-LNSEYAPJ.js.map +1 -0
  115. package/dist/chunk-MOJNV3XZ.js +120 -0
  116. package/dist/chunk-MOJNV3XZ.js.map +1 -0
  117. package/dist/{chunk-U2WDUCW3.js → chunk-NEP3JDVQ.js} +31 -6
  118. package/dist/chunk-NEP3JDVQ.js.map +1 -0
  119. package/dist/chunk-OK63Q6EJ.mjs +121 -0
  120. package/dist/chunk-OK63Q6EJ.mjs.map +1 -0
  121. package/dist/{chunk-5GHZ6EXI.js → chunk-ORAVN37L.js} +6 -10
  122. package/dist/chunk-ORAVN37L.js.map +1 -0
  123. package/dist/{chunk-T52N6ZBP.mjs → chunk-XCBBSHAK.mjs} +6 -10
  124. package/dist/chunk-XCBBSHAK.mjs.map +1 -0
  125. package/dist/chunk-XCKLBP2V.mjs +86 -0
  126. package/dist/chunk-XCKLBP2V.mjs.map +1 -0
  127. package/dist/chunk-XHZUPL2U.mjs +81 -0
  128. package/dist/chunk-XHZUPL2U.mjs.map +1 -0
  129. package/dist/code.d.mts +5 -4
  130. package/dist/code.d.ts +5 -4
  131. package/dist/code.js.map +1 -1
  132. package/dist/code.mjs.map +1 -1
  133. package/dist/collapsible.d.mts +4 -1
  134. package/dist/collapsible.d.ts +4 -1
  135. package/dist/collapsible.js.map +1 -1
  136. package/dist/collapsible.mjs.map +1 -1
  137. package/dist/command.d.mts +24 -12
  138. package/dist/command.d.ts +24 -12
  139. package/dist/command.js +9 -40
  140. package/dist/command.js.map +1 -1
  141. package/dist/command.mjs +9 -40
  142. package/dist/command.mjs.map +1 -1
  143. package/dist/container.d.mts +5 -4
  144. package/dist/container.d.ts +5 -4
  145. package/dist/container.js.map +1 -1
  146. package/dist/container.mjs.map +1 -1
  147. package/dist/context-menu.d.mts +31 -16
  148. package/dist/context-menu.d.ts +31 -16
  149. package/dist/context-menu.js +108 -124
  150. package/dist/context-menu.js.map +1 -1
  151. package/dist/context-menu.mjs +109 -125
  152. package/dist/context-menu.mjs.map +1 -1
  153. package/dist/data-table.d.mts +10 -7
  154. package/dist/data-table.d.ts +10 -7
  155. package/dist/data-table.js +131 -149
  156. package/dist/data-table.js.map +1 -1
  157. package/dist/data-table.mjs +120 -138
  158. package/dist/data-table.mjs.map +1 -1
  159. package/dist/dialog.d.mts +14 -6
  160. package/dist/dialog.d.ts +14 -6
  161. package/dist/dialog.js +2 -2
  162. package/dist/dialog.mjs +1 -1
  163. package/dist/drawer.d.mts +12 -4
  164. package/dist/drawer.d.ts +12 -4
  165. package/dist/drawer.js +30 -63
  166. package/dist/drawer.js.map +1 -1
  167. package/dist/drawer.mjs +30 -63
  168. package/dist/drawer.mjs.map +1 -1
  169. package/dist/dropdown-menu.d.mts +29 -15
  170. package/dist/dropdown-menu.d.ts +29 -15
  171. package/dist/dropdown-menu.js +2 -2
  172. package/dist/dropdown-menu.mjs +1 -1
  173. package/dist/em.d.mts +5 -4
  174. package/dist/em.d.ts +5 -4
  175. package/dist/em.js.map +1 -1
  176. package/dist/em.mjs.map +1 -1
  177. package/dist/form.d.mts +14 -6
  178. package/dist/form.d.ts +14 -6
  179. package/dist/form.js +13 -40
  180. package/dist/form.js.map +1 -1
  181. package/dist/form.mjs +13 -40
  182. package/dist/form.mjs.map +1 -1
  183. package/dist/heading.d.mts +6 -5
  184. package/dist/heading.d.ts +6 -5
  185. package/dist/heading.js.map +1 -1
  186. package/dist/heading.mjs.map +1 -1
  187. package/dist/hover-card.d.mts +5 -2
  188. package/dist/hover-card.d.ts +5 -2
  189. package/dist/hover-card.js +15 -13
  190. package/dist/hover-card.js.map +1 -1
  191. package/dist/hover-card.mjs +15 -13
  192. package/dist/hover-card.mjs.map +1 -1
  193. package/dist/input-otp.d.mts +12 -32
  194. package/dist/input-otp.d.ts +12 -32
  195. package/dist/input-otp.js +16 -13
  196. package/dist/input-otp.js.map +1 -1
  197. package/dist/input-otp.mjs +15 -12
  198. package/dist/input-otp.mjs.map +1 -1
  199. package/dist/input.d.mts +6 -3
  200. package/dist/input.d.ts +6 -3
  201. package/dist/input.js +8 -10
  202. package/dist/input.js.map +1 -1
  203. package/dist/input.mjs +8 -10
  204. package/dist/input.mjs.map +1 -1
  205. package/dist/kbd.d.mts +5 -4
  206. package/dist/kbd.d.ts +5 -4
  207. package/dist/kbd.js.map +1 -1
  208. package/dist/kbd.mjs.map +1 -1
  209. package/dist/label.d.mts +3 -2
  210. package/dist/label.d.ts +3 -2
  211. package/dist/label.js +2 -2
  212. package/dist/label.mjs +1 -1
  213. package/dist/menubar.d.mts +32 -17
  214. package/dist/menubar.d.ts +32 -17
  215. package/dist/menubar.js +73 -93
  216. package/dist/menubar.js.map +1 -1
  217. package/dist/menubar.mjs +74 -94
  218. package/dist/menubar.mjs.map +1 -1
  219. package/dist/navigation-menu.d.mts +16 -8
  220. package/dist/navigation-menu.d.ts +16 -8
  221. package/dist/navigation-menu.js +89 -93
  222. package/dist/navigation-menu.js.map +1 -1
  223. package/dist/navigation-menu.mjs +89 -93
  224. package/dist/navigation-menu.mjs.map +1 -1
  225. package/dist/pagination.d.mts +13 -7
  226. package/dist/pagination.d.ts +13 -7
  227. package/dist/pagination.js +18 -55
  228. package/dist/pagination.js.map +1 -1
  229. package/dist/pagination.mjs +18 -55
  230. package/dist/pagination.mjs.map +1 -1
  231. package/dist/popover.d.mts +8 -3
  232. package/dist/popover.d.ts +8 -3
  233. package/dist/popover.js +16 -21
  234. package/dist/popover.js.map +1 -1
  235. package/dist/popover.mjs +16 -21
  236. package/dist/popover.mjs.map +1 -1
  237. package/dist/pre.d.mts +5 -4
  238. package/dist/pre.d.ts +5 -4
  239. package/dist/pre.js.map +1 -1
  240. package/dist/pre.mjs.map +1 -1
  241. package/dist/progress.d.mts +3 -2
  242. package/dist/progress.d.ts +3 -2
  243. package/dist/progress.js +2 -5
  244. package/dist/progress.js.map +1 -1
  245. package/dist/progress.mjs +2 -5
  246. package/dist/progress.mjs.map +1 -1
  247. package/dist/quote.d.mts +5 -4
  248. package/dist/quote.d.ts +5 -4
  249. package/dist/quote.js.map +1 -1
  250. package/dist/quote.mjs.map +1 -1
  251. package/dist/radio-cards.d.mts +9 -0
  252. package/dist/radio-cards.d.ts +9 -0
  253. package/dist/radio-cards.js +36 -0
  254. package/dist/radio-cards.js.map +1 -0
  255. package/dist/radio-cards.mjs +36 -0
  256. package/dist/radio-cards.mjs.map +1 -0
  257. package/dist/radio-group.d.mts +5 -3
  258. package/dist/radio-group.d.ts +5 -3
  259. package/dist/radio-group.js +3 -9
  260. package/dist/radio-group.js.map +1 -1
  261. package/dist/radio-group.mjs +3 -9
  262. package/dist/radio-group.mjs.map +1 -1
  263. package/dist/radio.d.mts +8 -0
  264. package/dist/radio.d.ts +8 -0
  265. package/dist/radio.js +35 -0
  266. package/dist/radio.js.map +1 -0
  267. package/dist/radio.mjs +35 -0
  268. package/dist/radio.mjs.map +1 -0
  269. package/dist/resizable.d.mts +6 -6
  270. package/dist/resizable.d.ts +6 -6
  271. package/dist/resizable.js +4 -6
  272. package/dist/resizable.js.map +1 -1
  273. package/dist/resizable.mjs +4 -6
  274. package/dist/resizable.mjs.map +1 -1
  275. package/dist/scroll-area.d.mts +5 -3
  276. package/dist/scroll-area.d.ts +5 -3
  277. package/dist/scroll-area.js +25 -31
  278. package/dist/scroll-area.js.map +1 -1
  279. package/dist/scroll-area.mjs +25 -31
  280. package/dist/scroll-area.mjs.map +1 -1
  281. package/dist/section.d.mts +5 -4
  282. package/dist/section.d.ts +5 -4
  283. package/dist/section.js.map +1 -1
  284. package/dist/section.mjs.map +1 -1
  285. package/dist/select.d.mts +18 -8
  286. package/dist/select.d.ts +18 -8
  287. package/dist/select.js +2 -2
  288. package/dist/select.mjs +1 -1
  289. package/dist/separator.d.mts +3 -2
  290. package/dist/separator.d.ts +3 -2
  291. package/dist/separator.js +1 -5
  292. package/dist/separator.js.map +1 -1
  293. package/dist/separator.mjs +1 -5
  294. package/dist/separator.mjs.map +1 -1
  295. package/dist/sheet.d.mts +20 -10
  296. package/dist/sheet.d.ts +20 -10
  297. package/dist/sheet.js +35 -76
  298. package/dist/sheet.js.map +1 -1
  299. package/dist/sheet.mjs +35 -76
  300. package/dist/sheet.mjs.map +1 -1
  301. package/dist/skeleton.d.mts +3 -2
  302. package/dist/skeleton.d.ts +3 -2
  303. package/dist/skeleton.js +2 -11
  304. package/dist/skeleton.js.map +1 -1
  305. package/dist/skeleton.mjs +2 -11
  306. package/dist/skeleton.mjs.map +1 -1
  307. package/dist/slider.d.mts +3 -2
  308. package/dist/slider.d.ts +3 -2
  309. package/dist/slider.js +10 -5
  310. package/dist/slider.js.map +1 -1
  311. package/dist/slider.mjs +10 -5
  312. package/dist/slider.mjs.map +1 -1
  313. package/dist/sonner.d.mts +1 -1
  314. package/dist/sonner.d.ts +1 -1
  315. package/dist/sonner.js +1 -6
  316. package/dist/sonner.js.map +1 -1
  317. package/dist/sonner.mjs +1 -6
  318. package/dist/sonner.mjs.map +1 -1
  319. package/dist/spinner.d.mts +8 -0
  320. package/dist/spinner.d.ts +8 -0
  321. package/dist/spinner.js +8 -0
  322. package/dist/spinner.js.map +1 -0
  323. package/dist/spinner.mjs +8 -0
  324. package/dist/spinner.mjs.map +1 -0
  325. package/dist/strong.d.mts +5 -4
  326. package/dist/strong.d.ts +5 -4
  327. package/dist/strong.js.map +1 -1
  328. package/dist/strong.mjs.map +1 -1
  329. package/dist/styles.css +1 -1
  330. package/dist/styles.css.map +1 -1
  331. package/dist/switch.d.mts +3 -2
  332. package/dist/switch.d.ts +3 -2
  333. package/dist/switch.js +2 -1
  334. package/dist/switch.js.map +1 -1
  335. package/dist/switch.mjs +2 -1
  336. package/dist/switch.mjs.map +1 -1
  337. package/dist/table.d.mts +17 -9
  338. package/dist/table.d.ts +17 -9
  339. package/dist/table.js +6 -47
  340. package/dist/table.js.map +1 -1
  341. package/dist/table.mjs +6 -47
  342. package/dist/table.mjs.map +1 -1
  343. package/dist/tabs.d.mts +8 -4
  344. package/dist/tabs.d.ts +8 -4
  345. package/dist/tabs.js +4 -2
  346. package/dist/tabs.js.map +1 -1
  347. package/dist/tabs.mjs +4 -2
  348. package/dist/tabs.mjs.map +1 -1
  349. package/dist/text.d.mts +1 -1
  350. package/dist/text.d.ts +1 -1
  351. package/dist/text.js +4 -6
  352. package/dist/text.js.map +1 -1
  353. package/dist/text.mjs +4 -6
  354. package/dist/text.mjs.map +1 -1
  355. package/dist/textarea.d.mts +3 -2
  356. package/dist/textarea.d.ts +3 -2
  357. package/dist/textarea.js +2 -1
  358. package/dist/textarea.js.map +1 -1
  359. package/dist/textarea.mjs +2 -1
  360. package/dist/textarea.mjs.map +1 -1
  361. package/dist/toggle-group.d.mts +5 -3
  362. package/dist/toggle-group.d.ts +5 -3
  363. package/dist/toggle-group.js +41 -34
  364. package/dist/toggle-group.js.map +1 -1
  365. package/dist/toggle-group.mjs +40 -33
  366. package/dist/toggle-group.mjs.map +1 -1
  367. package/dist/toggle.d.mts +3 -2
  368. package/dist/toggle.d.ts +3 -2
  369. package/dist/toggle.js +2 -2
  370. package/dist/toggle.mjs +1 -1
  371. package/dist/tooltip.d.mts +8 -3
  372. package/dist/tooltip.d.ts +8 -3
  373. package/dist/tooltip.js +15 -20
  374. package/dist/tooltip.js.map +1 -1
  375. package/dist/tooltip.mjs +15 -20
  376. package/dist/tooltip.mjs.map +1 -1
  377. package/package.json +40 -9
  378. package/src/accordion.tsx +63 -40
  379. package/src/alert-dialog.tsx +84 -84
  380. package/src/alert.tsx +25 -32
  381. package/src/aspect-ratio.tsx +3 -1
  382. package/src/avatar.tsx +19 -26
  383. package/src/badge.tsx +8 -9
  384. package/src/blockquote.tsx +9 -7
  385. package/src/box.tsx +8 -7
  386. package/src/breadcrumb.tsx +55 -54
  387. package/src/button.tsx +44 -15
  388. package/src/calendar.tsx +8 -23
  389. package/src/card.tsx +44 -53
  390. package/src/carousel.tsx +152 -134
  391. package/src/checkbox-cards.tsx +68 -0
  392. package/src/checkbox-group.primitive.tsx +199 -0
  393. package/src/checkbox-group.tsx +57 -0
  394. package/src/checkbox.tsx +11 -6
  395. package/src/code.tsx +9 -5
  396. package/src/collapsible.tsx +12 -1
  397. package/src/command.tsx +65 -65
  398. package/src/container.tsx +9 -7
  399. package/src/context-menu.tsx +184 -160
  400. package/src/data-table.tsx +43 -48
  401. package/src/dialog.tsx +68 -71
  402. package/src/drawer.tsx +59 -67
  403. package/src/dropdown-menu.tsx +164 -139
  404. package/src/em.tsx +9 -5
  405. package/src/form.tsx +61 -69
  406. package/src/heading.tsx +10 -8
  407. package/src/hover-card.tsx +30 -18
  408. package/src/input-otp.tsx +40 -26
  409. package/src/input.tsx +16 -15
  410. package/src/kbd.tsx +9 -5
  411. package/src/label.tsx +6 -5
  412. package/src/menubar.tsx +154 -139
  413. package/src/navigation-menu.tsx +118 -102
  414. package/src/pagination.tsx +39 -49
  415. package/src/popover.tsx +41 -27
  416. package/src/pre.tsx +9 -5
  417. package/src/progress.tsx +8 -10
  418. package/src/quote.tsx +9 -5
  419. package/src/radio-cards.tsx +50 -0
  420. package/src/radio-group.tsx +14 -17
  421. package/src/radio.tsx +44 -0
  422. package/src/resizable.tsx +7 -8
  423. package/src/scroll-area.tsx +33 -37
  424. package/src/section.tsx +9 -7
  425. package/src/select.tsx +116 -105
  426. package/src/separator.tsx +8 -14
  427. package/src/sheet.tsx +62 -70
  428. package/src/skeleton.tsx +5 -11
  429. package/src/slider.tsx +13 -10
  430. package/src/sonner.tsx +4 -8
  431. package/src/spinner.tsx +75 -0
  432. package/src/strong.tsx +9 -5
  433. package/src/switch.tsx +8 -6
  434. package/src/table.tsx +54 -64
  435. package/src/tabs.tsx +30 -15
  436. package/src/text.tsx +9 -9
  437. package/src/textarea.tsx +8 -6
  438. package/src/toggle-group.tsx +59 -48
  439. package/src/toggle.tsx +12 -13
  440. package/src/tooltip.tsx +33 -25
  441. package/dist/chunk-2D7SRYKN.js +0 -135
  442. package/dist/chunk-2D7SRYKN.js.map +0 -1
  443. package/dist/chunk-5GHZ6EXI.js.map +0 -1
  444. package/dist/chunk-EDVCMWDT.mjs +0 -158
  445. package/dist/chunk-EDVCMWDT.mjs.map +0 -1
  446. package/dist/chunk-EIHWTXQ4.mjs +0 -112
  447. package/dist/chunk-EIHWTXQ4.mjs.map +0 -1
  448. package/dist/chunk-ESWGFN3R.mjs +0 -135
  449. package/dist/chunk-ESWGFN3R.mjs.map +0 -1
  450. package/dist/chunk-KW5FJ62U.mjs +0 -56
  451. package/dist/chunk-KW5FJ62U.mjs.map +0 -1
  452. package/dist/chunk-LDYBRDAY.js +0 -112
  453. package/dist/chunk-LDYBRDAY.js.map +0 -1
  454. package/dist/chunk-OCLLX7EY.js +0 -158
  455. package/dist/chunk-OCLLX7EY.js.map +0 -1
  456. package/dist/chunk-PTD4AMHI.mjs.map +0 -1
  457. package/dist/chunk-RTKEO347.js.map +0 -1
  458. package/dist/chunk-T52N6ZBP.mjs.map +0 -1
  459. package/dist/chunk-U2WDUCW3.js.map +0 -1
@@ -1,22 +1,16 @@
1
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; } }
2
2
 
3
- var _chunkU2WDUCW3js = require('./chunk-U2WDUCW3.js');
3
+ var _chunkNEP3JDVQjs = require('./chunk-NEP3JDVQ.js');
4
+ require('./chunk-J6COVJTP.js');
4
5
 
5
6
 
6
7
  var _chunkG3NP7M2Njs = require('./chunk-G3NP7M2N.js');
7
8
 
8
9
  // src/pagination.tsx
9
10
  var _react = require('react'); var React = _interopRequireWildcard(_react);
10
-
11
-
12
-
13
-
14
11
  var _reacticons = require('@radix-ui/react-icons');
15
12
  var _jsxruntime = require('react/jsx-runtime');
16
- function Pagination({
17
- className,
18
- ...props
19
- }) {
13
+ function Pagination({ className, ...props }) {
20
14
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
21
15
  "nav",
22
16
  {
@@ -27,14 +21,9 @@ function Pagination({
27
21
  }
28
22
  );
29
23
  }
30
- var PaginationContent = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
31
- "ul",
32
- {
33
- ref,
34
- className: _chunkG3NP7M2Njs.cn.call(void 0, "flex flex-row items-center gap-1", className),
35
- ...props
36
- }
37
- ));
24
+ var PaginationContent = React.forwardRef(
25
+ ({ className, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "ul", { ref, className: _chunkG3NP7M2Njs.cn.call(void 0, "flex flex-row items-center gap-1", className), ...props })
26
+ );
38
27
  PaginationContent.displayName = "PaginationContent";
39
28
  var PaginationItem = React.forwardRef((props, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "li", { ref, ...props }));
40
29
  PaginationItem.displayName = "PaginationItem";
@@ -49,7 +38,7 @@ function PaginationLink({
49
38
  "a",
50
39
  {
51
40
  "aria-current": isActive ? "page" : void 0,
52
- className: _chunkU2WDUCW3js.buttonVariants.call(void 0, {
41
+ className: _chunkNEP3JDVQjs.buttonVariants.call(void 0, {
53
42
  variant: isActive ? "outline" : "ghost",
54
43
  size,
55
44
  className
@@ -59,10 +48,7 @@ function PaginationLink({
59
48
  }
60
49
  );
61
50
  }
62
- function PaginationPrevious({
63
- className,
64
- ...props
65
- }) {
51
+ function PaginationPrevious({ className, ...props }) {
66
52
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
67
53
  PaginationLink,
68
54
  {
@@ -77,40 +63,17 @@ function PaginationPrevious({
77
63
  }
78
64
  );
79
65
  }
80
- function PaginationNext({
81
- className,
82
- ...props
83
- }) {
84
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
85
- PaginationLink,
86
- {
87
- "aria-label": "Go to next page",
88
- size: "default",
89
- className: _chunkG3NP7M2Njs.cn.call(void 0, "gap-1 pr-2.5", className),
90
- ...props,
91
- children: [
92
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Next" }),
93
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reacticons.ChevronRightIcon, { className: "size-4" })
94
- ]
95
- }
96
- );
66
+ function PaginationNext({ className, ...props }) {
67
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, PaginationLink, { "aria-label": "Go to next page", size: "default", className: _chunkG3NP7M2Njs.cn.call(void 0, "gap-1 pr-2.5", className), ...props, children: [
68
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Next" }),
69
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reacticons.ChevronRightIcon, { className: "size-4" })
70
+ ] });
97
71
  }
98
- function PaginationEllipsis({
99
- className,
100
- ...props
101
- }) {
102
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
103
- "span",
104
- {
105
- "aria-hidden": true,
106
- className: _chunkG3NP7M2Njs.cn.call(void 0, "flex size-10 items-center justify-center", className),
107
- ...props,
108
- children: [
109
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reacticons.DotsHorizontalIcon, { className: "size-4" }),
110
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "sr-only", children: "More pages" })
111
- ]
112
- }
113
- );
72
+ function PaginationEllipsis({ className, ...props }) {
73
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { "aria-hidden": true, className: _chunkG3NP7M2Njs.cn.call(void 0, "flex size-10 items-center justify-center", className), ...props, children: [
74
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reacticons.DotsHorizontalIcon, { className: "size-4" }),
75
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "sr-only", children: "More pages" })
76
+ ] });
114
77
  }
115
78
 
116
79
 
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/pagination.tsx"],"names":[],"mappings":";;;;;;;;AAAA,YAAY,WAAW;AACvB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAaH,cA4EA,YA5EA;AALJ,SAAS,WAAW;AAAA,EAClB;AAAA,EACA,GAAG;AACL,GAAmD;AACjD,SACE;AAAA,IAAC;AAAA;AAAA,MACC,MAAK;AAAA,MACL,cAAW;AAAA,MACX,WAAW,GAAG,sCAAsC,SAAS;AAAA,MAC5D,GAAG;AAAA;AAAA,EACN;AAEJ;AAMA,IAAM,oBAA0B,iBAG9B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC;AAAA;AAAA,IACC;AAAA,IACA,WAAW,GAAG,oCAAoC,SAAS;AAAA,IAC1D,GAAG;AAAA;AACN,CACD;AACD,kBAAkB,cAAc;AAMhC,IAAM,iBAAuB,iBAG3B,CAAC,OAAO,QAAQ,oBAAC,QAAG,KAAW,GAAG,OAAO,CAAE;AAC7C,eAAe,cAAc;AAY7B,SAAS,eAAe;AAAA,EACtB;AAAA,EACA;AAAA,EACA,OAAO;AAAA,EACP;AAAA,EACA,GAAG;AACL,GAA2C;AACzC,SACE;AAAA,IAAC;AAAA;AAAA,MACC,gBAAc,WAAW,SAAS;AAAA,MAClC,WAAW,eAAe;AAAA,QACxB,SAAS,WAAW,YAAY;AAAA,QAChC;AAAA,QACA;AAAA,MACF,CAAC;AAAA,MACA,GAAG;AAAA,MAEH;AAAA;AAAA,EACH;AAEJ;AAMA,SAAS,mBAAmB;AAAA,EAC1B;AAAA,EACA,GAAG;AACL,GAA2C;AACzC,SACE;AAAA,IAAC;AAAA;AAAA,MACC,cAAW;AAAA,MACX,MAAK;AAAA,MACL,WAAW,GAAG,gBAAgB,SAAS;AAAA,MACtC,GAAG;AAAA,MAEJ;AAAA,4BAAC,mBAAgB,WAAU,UAAS;AAAA,QACpC,oBAAC,UAAK,sBAAQ;AAAA;AAAA;AAAA,EAChB;AAEJ;AAMA,SAAS,eAAe;AAAA,EACtB;AAAA,EACA,GAAG;AACL,GAA2C;AACzC,SACE;AAAA,IAAC;AAAA;AAAA,MACC,cAAW;AAAA,MACX,MAAK;AAAA,MACL,WAAW,GAAG,gBAAgB,SAAS;AAAA,MACtC,GAAG;AAAA,MAEJ;AAAA,4BAAC,UAAK,kBAAI;AAAA,QACV,oBAAC,oBAAiB,WAAU,UAAS;AAAA;AAAA;AAAA,EACvC;AAEJ;AAMA,SAAS,mBAAmB;AAAA,EAC1B;AAAA,EACA,GAAG;AACL,GAA6D;AAC3D,SACE;AAAA,IAAC;AAAA;AAAA,MACC,eAAW;AAAA,MACX,WAAW,GAAG,4CAA4C,SAAS;AAAA,MAClE,GAAG;AAAA,MAEJ;AAAA,4BAAC,sBAAmB,WAAU,UAAS;AAAA,QACvC,oBAAC,UAAK,WAAU,WAAU,wBAAU;AAAA;AAAA;AAAA,EACtC;AAEJ","sourcesContent":["import * as React from \"react\";\nimport {\n ChevronLeftIcon,\n ChevronRightIcon,\n DotsHorizontalIcon,\n} from \"@radix-ui/react-icons\";\nimport { cn } from \"./utils\";\nimport { type ButtonProps, buttonVariants } from \"./button\";\n\n/* -----------------------------------------------------------------------------\n * Component: Pagination\n * -------------------------------------------------------------------------- */\n\nfunction Pagination({\n className,\n ...props\n}: React.ComponentProps<\"nav\">): 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\nconst PaginationContent = React.forwardRef<\n HTMLUListElement,\n React.HTMLAttributes<HTMLUListElement>\n>(({ className, ...props }, ref) => (\n <ul\n ref={ref}\n className={cn(\"flex flex-row items-center gap-1\", className)}\n {...props}\n />\n));\nPaginationContent.displayName = \"PaginationContent\";\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationItem\n * -------------------------------------------------------------------------- */\n\nconst PaginationItem = React.forwardRef<\n HTMLLIElement,\n React.LiHTMLAttributes<HTMLLIElement>\n>((props, ref) => <li ref={ref} {...props} />);\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\nfunction PaginationPrevious({\n className,\n ...props\n}: PaginationLinkProps): 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\nfunction PaginationNext({\n className,\n ...props\n}: PaginationLinkProps): 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\nfunction PaginationEllipsis({\n className,\n ...props\n}: React.HTMLAttributes<HTMLSpanElement>): 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};\n"]}
1
+ {"version":3,"sources":["../src/pagination.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,YAAY,WAAW;AACvB,SAAS,iBAAiB,kBAAkB,0BAA0B;AAYlE,cA2EA,YA3EA;AAFJ,SAAS,WAAW,EAAE,WAAW,GAAG,MAAM,GAAuC;AAC/E,SACE;AAAA,IAAC;AAAA;AAAA,MACC,MAAK;AAAA,MACL,cAAW;AAAA,MACX,WAAW,GAAG,sCAAsC,SAAS;AAAA,MAC5D,GAAG;AAAA;AAAA,EACN;AAEJ;AASA,IAAM,oBAA0B;AAAA,EAC9B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,QAAG,KAAU,WAAW,GAAG,oCAAoC,SAAS,GAAI,GAAG,OAAO;AAE3F;AAEA,kBAAkB,cAAc;AAShC,IAAM,iBAAuB,iBAAuD,CAAC,OAAO,QAC1F,oBAAC,QAAG,KAAW,GAAG,OAAO,CAC1B;AAED,eAAe,cAAc;AAU7B,SAAS,eAAe;AAAA,EACtB;AAAA,EACA;AAAA,EACA,OAAO;AAAA,EACP;AAAA,EACA,GAAG;AACL,GAA2C;AACzC,SACE;AAAA,IAAC;AAAA;AAAA,MACC,gBAAc,WAAW,SAAS;AAAA,MAClC,WAAW,eAAe;AAAA,QACxB,SAAS,WAAW,YAAY;AAAA,QAChC;AAAA,QACA;AAAA,MACF,CAAC;AAAA,MACA,GAAG;AAAA,MAEH;AAAA;AAAA,EACH;AAEJ;AAQA,SAAS,mBAAmB,EAAE,WAAW,GAAG,MAAM,GAA+C;AAC/F,SACE;AAAA,IAAC;AAAA;AAAA,MACC,cAAW;AAAA,MACX,MAAK;AAAA,MACL,WAAW,GAAG,gBAAgB,SAAS;AAAA,MACtC,GAAG;AAAA,MAEJ;AAAA,4BAAC,mBAAgB,WAAU,UAAS;AAAA,QACpC,oBAAC,UAAK,sBAAQ;AAAA;AAAA;AAAA,EAChB;AAEJ;AAQA,SAAS,eAAe,EAAE,WAAW,GAAG,MAAM,GAA2C;AACvF,SACE,qBAAC,kBAAe,cAAW,mBAAkB,MAAK,WAAU,WAAW,GAAG,gBAAgB,SAAS,GAAI,GAAG,OACxG;AAAA,wBAAC,UAAK,kBAAI;AAAA,IACV,oBAAC,oBAAiB,WAAU,UAAS;AAAA,KACvC;AAEJ;AAQA,SAAS,mBAAmB,EAAE,WAAW,GAAG,MAAM,GAA+C;AAC/F,SACE,qBAAC,UAAK,eAAW,MAAC,WAAW,GAAG,4CAA4C,SAAS,GAAI,GAAG,OAC1F;AAAA,wBAAC,sBAAmB,WAAU,UAAS;AAAA,IACvC,oBAAC,UAAK,WAAU,WAAU,wBAAU;AAAA,KACtC;AAEJ","sourcesContent":["import * as React from \"react\";\nimport { ChevronLeftIcon, ChevronRightIcon, DotsHorizontalIcon } from \"@radix-ui/react-icons\";\nimport { cn } from \"./utils\";\nimport { type ButtonProps, buttonVariants } 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,22 +1,16 @@
1
1
  import {
2
2
  buttonVariants
3
- } from "./chunk-KW5FJ62U.mjs";
3
+ } from "./chunk-XHZUPL2U.mjs";
4
+ import "./chunk-5UHPKXF4.mjs";
4
5
  import {
5
6
  cn
6
7
  } from "./chunk-UG3URV2Z.mjs";
7
8
 
8
9
  // src/pagination.tsx
9
10
  import * as React from "react";
10
- import {
11
- ChevronLeftIcon,
12
- ChevronRightIcon,
13
- DotsHorizontalIcon
14
- } from "@radix-ui/react-icons";
11
+ import { ChevronLeftIcon, ChevronRightIcon, DotsHorizontalIcon } from "@radix-ui/react-icons";
15
12
  import { jsx, jsxs } from "react/jsx-runtime";
16
- function Pagination({
17
- className,
18
- ...props
19
- }) {
13
+ function Pagination({ className, ...props }) {
20
14
  return /* @__PURE__ */ jsx(
21
15
  "nav",
22
16
  {
@@ -27,14 +21,9 @@ function Pagination({
27
21
  }
28
22
  );
29
23
  }
30
- var PaginationContent = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
31
- "ul",
32
- {
33
- ref,
34
- className: cn("flex flex-row items-center gap-1", className),
35
- ...props
36
- }
37
- ));
24
+ var PaginationContent = React.forwardRef(
25
+ ({ className, ...props }, ref) => /* @__PURE__ */ jsx("ul", { ref, className: cn("flex flex-row items-center gap-1", className), ...props })
26
+ );
38
27
  PaginationContent.displayName = "PaginationContent";
39
28
  var PaginationItem = React.forwardRef((props, ref) => /* @__PURE__ */ jsx("li", { ref, ...props }));
40
29
  PaginationItem.displayName = "PaginationItem";
@@ -59,10 +48,7 @@ function PaginationLink({
59
48
  }
60
49
  );
61
50
  }
62
- function PaginationPrevious({
63
- className,
64
- ...props
65
- }) {
51
+ function PaginationPrevious({ className, ...props }) {
66
52
  return /* @__PURE__ */ jsxs(
67
53
  PaginationLink,
68
54
  {
@@ -77,40 +63,17 @@ function PaginationPrevious({
77
63
  }
78
64
  );
79
65
  }
80
- function PaginationNext({
81
- className,
82
- ...props
83
- }) {
84
- return /* @__PURE__ */ jsxs(
85
- PaginationLink,
86
- {
87
- "aria-label": "Go to next page",
88
- size: "default",
89
- className: cn("gap-1 pr-2.5", className),
90
- ...props,
91
- children: [
92
- /* @__PURE__ */ jsx("span", { children: "Next" }),
93
- /* @__PURE__ */ jsx(ChevronRightIcon, { className: "size-4" })
94
- ]
95
- }
96
- );
66
+ function PaginationNext({ className, ...props }) {
67
+ return /* @__PURE__ */ jsxs(PaginationLink, { "aria-label": "Go to next page", size: "default", className: cn("gap-1 pr-2.5", className), ...props, children: [
68
+ /* @__PURE__ */ jsx("span", { children: "Next" }),
69
+ /* @__PURE__ */ jsx(ChevronRightIcon, { className: "size-4" })
70
+ ] });
97
71
  }
98
- function PaginationEllipsis({
99
- className,
100
- ...props
101
- }) {
102
- return /* @__PURE__ */ jsxs(
103
- "span",
104
- {
105
- "aria-hidden": true,
106
- className: cn("flex size-10 items-center justify-center", className),
107
- ...props,
108
- children: [
109
- /* @__PURE__ */ jsx(DotsHorizontalIcon, { className: "size-4" }),
110
- /* @__PURE__ */ jsx("span", { className: "sr-only", children: "More pages" })
111
- ]
112
- }
113
- );
72
+ function PaginationEllipsis({ className, ...props }) {
73
+ return /* @__PURE__ */ jsxs("span", { "aria-hidden": true, className: cn("flex size-10 items-center justify-center", className), ...props, children: [
74
+ /* @__PURE__ */ jsx(DotsHorizontalIcon, { className: "size-4" }),
75
+ /* @__PURE__ */ jsx("span", { className: "sr-only", children: "More pages" })
76
+ ] });
114
77
  }
115
78
  export {
116
79
  Pagination,
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/pagination.tsx"],"sourcesContent":["import * as React from \"react\";\nimport {\n ChevronLeftIcon,\n ChevronRightIcon,\n DotsHorizontalIcon,\n} from \"@radix-ui/react-icons\";\nimport { cn } from \"./utils\";\nimport { type ButtonProps, buttonVariants } from \"./button\";\n\n/* -----------------------------------------------------------------------------\n * Component: Pagination\n * -------------------------------------------------------------------------- */\n\nfunction Pagination({\n className,\n ...props\n}: React.ComponentProps<\"nav\">): 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\nconst PaginationContent = React.forwardRef<\n HTMLUListElement,\n React.HTMLAttributes<HTMLUListElement>\n>(({ className, ...props }, ref) => (\n <ul\n ref={ref}\n className={cn(\"flex flex-row items-center gap-1\", className)}\n {...props}\n />\n));\nPaginationContent.displayName = \"PaginationContent\";\n\n/* -----------------------------------------------------------------------------\n * Component: PaginationItem\n * -------------------------------------------------------------------------- */\n\nconst PaginationItem = React.forwardRef<\n HTMLLIElement,\n React.LiHTMLAttributes<HTMLLIElement>\n>((props, ref) => <li ref={ref} {...props} />);\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\nfunction PaginationPrevious({\n className,\n ...props\n}: PaginationLinkProps): 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\nfunction PaginationNext({\n className,\n ...props\n}: PaginationLinkProps): 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\nfunction PaginationEllipsis({\n className,\n ...props\n}: React.HTMLAttributes<HTMLSpanElement>): 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};\n"],"mappings":";;;;;;;;AAAA,YAAY,WAAW;AACvB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAaH,cA4EA,YA5EA;AALJ,SAAS,WAAW;AAAA,EAClB;AAAA,EACA,GAAG;AACL,GAAmD;AACjD,SACE;AAAA,IAAC;AAAA;AAAA,MACC,MAAK;AAAA,MACL,cAAW;AAAA,MACX,WAAW,GAAG,sCAAsC,SAAS;AAAA,MAC5D,GAAG;AAAA;AAAA,EACN;AAEJ;AAMA,IAAM,oBAA0B,iBAG9B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC;AAAA;AAAA,IACC;AAAA,IACA,WAAW,GAAG,oCAAoC,SAAS;AAAA,IAC1D,GAAG;AAAA;AACN,CACD;AACD,kBAAkB,cAAc;AAMhC,IAAM,iBAAuB,iBAG3B,CAAC,OAAO,QAAQ,oBAAC,QAAG,KAAW,GAAG,OAAO,CAAE;AAC7C,eAAe,cAAc;AAY7B,SAAS,eAAe;AAAA,EACtB;AAAA,EACA;AAAA,EACA,OAAO;AAAA,EACP;AAAA,EACA,GAAG;AACL,GAA2C;AACzC,SACE;AAAA,IAAC;AAAA;AAAA,MACC,gBAAc,WAAW,SAAS;AAAA,MAClC,WAAW,eAAe;AAAA,QACxB,SAAS,WAAW,YAAY;AAAA,QAChC;AAAA,QACA;AAAA,MACF,CAAC;AAAA,MACA,GAAG;AAAA,MAEH;AAAA;AAAA,EACH;AAEJ;AAMA,SAAS,mBAAmB;AAAA,EAC1B;AAAA,EACA,GAAG;AACL,GAA2C;AACzC,SACE;AAAA,IAAC;AAAA;AAAA,MACC,cAAW;AAAA,MACX,MAAK;AAAA,MACL,WAAW,GAAG,gBAAgB,SAAS;AAAA,MACtC,GAAG;AAAA,MAEJ;AAAA,4BAAC,mBAAgB,WAAU,UAAS;AAAA,QACpC,oBAAC,UAAK,sBAAQ;AAAA;AAAA;AAAA,EAChB;AAEJ;AAMA,SAAS,eAAe;AAAA,EACtB;AAAA,EACA,GAAG;AACL,GAA2C;AACzC,SACE;AAAA,IAAC;AAAA;AAAA,MACC,cAAW;AAAA,MACX,MAAK;AAAA,MACL,WAAW,GAAG,gBAAgB,SAAS;AAAA,MACtC,GAAG;AAAA,MAEJ;AAAA,4BAAC,UAAK,kBAAI;AAAA,QACV,oBAAC,oBAAiB,WAAU,UAAS;AAAA;AAAA;AAAA,EACvC;AAEJ;AAMA,SAAS,mBAAmB;AAAA,EAC1B;AAAA,EACA,GAAG;AACL,GAA6D;AAC3D,SACE;AAAA,IAAC;AAAA;AAAA,MACC,eAAW;AAAA,MACX,WAAW,GAAG,4CAA4C,SAAS;AAAA,MAClE,GAAG;AAAA,MAEJ;AAAA,4BAAC,sBAAmB,WAAU,UAAS;AAAA,QACvC,oBAAC,UAAK,WAAU,WAAU,wBAAU;AAAA;AAAA;AAAA,EACtC;AAEJ;","names":[]}
1
+ {"version":3,"sources":["../src/pagination.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { ChevronLeftIcon, ChevronRightIcon, DotsHorizontalIcon } from \"@radix-ui/react-icons\";\nimport { cn } from \"./utils\";\nimport { type ButtonProps, buttonVariants } 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":";;;;;;;;;AAAA,YAAY,WAAW;AACvB,SAAS,iBAAiB,kBAAkB,0BAA0B;AAYlE,cA2EA,YA3EA;AAFJ,SAAS,WAAW,EAAE,WAAW,GAAG,MAAM,GAAuC;AAC/E,SACE;AAAA,IAAC;AAAA;AAAA,MACC,MAAK;AAAA,MACL,cAAW;AAAA,MACX,WAAW,GAAG,sCAAsC,SAAS;AAAA,MAC5D,GAAG;AAAA;AAAA,EACN;AAEJ;AASA,IAAM,oBAA0B;AAAA,EAC9B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,QAAG,KAAU,WAAW,GAAG,oCAAoC,SAAS,GAAI,GAAG,OAAO;AAE3F;AAEA,kBAAkB,cAAc;AAShC,IAAM,iBAAuB,iBAAuD,CAAC,OAAO,QAC1F,oBAAC,QAAG,KAAW,GAAG,OAAO,CAC1B;AAED,eAAe,cAAc;AAU7B,SAAS,eAAe;AAAA,EACtB;AAAA,EACA;AAAA,EACA,OAAO;AAAA,EACP;AAAA,EACA,GAAG;AACL,GAA2C;AACzC,SACE;AAAA,IAAC;AAAA;AAAA,MACC,gBAAc,WAAW,SAAS;AAAA,MAClC,WAAW,eAAe;AAAA,QACxB,SAAS,WAAW,YAAY;AAAA,QAChC;AAAA,QACA;AAAA,MACF,CAAC;AAAA,MACA,GAAG;AAAA,MAEH;AAAA;AAAA,EACH;AAEJ;AAQA,SAAS,mBAAmB,EAAE,WAAW,GAAG,MAAM,GAA+C;AAC/F,SACE;AAAA,IAAC;AAAA;AAAA,MACC,cAAW;AAAA,MACX,MAAK;AAAA,MACL,WAAW,GAAG,gBAAgB,SAAS;AAAA,MACtC,GAAG;AAAA,MAEJ;AAAA,4BAAC,mBAAgB,WAAU,UAAS;AAAA,QACpC,oBAAC,UAAK,sBAAQ;AAAA;AAAA;AAAA,EAChB;AAEJ;AAQA,SAAS,eAAe,EAAE,WAAW,GAAG,MAAM,GAA2C;AACvF,SACE,qBAAC,kBAAe,cAAW,mBAAkB,MAAK,WAAU,WAAW,GAAG,gBAAgB,SAAS,GAAI,GAAG,OACxG;AAAA,wBAAC,UAAK,kBAAI;AAAA,IACV,oBAAC,oBAAiB,WAAU,UAAS;AAAA,KACvC;AAEJ;AAQA,SAAS,mBAAmB,EAAE,WAAW,GAAG,MAAM,GAA+C;AAC/F,SACE,qBAAC,UAAK,eAAW,MAAC,WAAW,GAAG,4CAA4C,SAAS,GAAI,GAAG,OAC1F;AAAA,wBAAC,sBAAmB,WAAU,UAAS;AAAA,IACvC,oBAAC,UAAK,WAAU,WAAU,wBAAU;AAAA,KACtC;AAEJ;","names":[]}
@@ -1,10 +1,15 @@
1
1
  import * as React from 'react';
2
2
  import * as PopoverPrimitive from '@radix-ui/react-popover';
3
3
 
4
+ type PopoverProps = React.ComponentProps<typeof PopoverPrimitive.Root>;
4
5
  declare const Popover: React.FC<PopoverPrimitive.PopoverProps>;
6
+ type PopoverTriggerProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Trigger>;
5
7
  declare const PopoverTrigger: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverTriggerProps & React.RefAttributes<HTMLButtonElement>>;
8
+ type PopoverAnchorProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Anchor>;
6
9
  declare const PopoverAnchor: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverAnchorProps & React.RefAttributes<HTMLDivElement>>;
7
- declare const PopoverContent: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverContentProps & React.RefAttributes<HTMLDivElement>>;
8
- declare const PopoverArrow: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverArrowProps & React.RefAttributes<SVGSVGElement>>;
10
+ type PopoverContentProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Content>;
11
+ declare const PopoverContent: React.ForwardRefExoticComponent<Omit<PopoverPrimitive.PopoverContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
12
+ type PopoverArrowProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Arrow>;
13
+ declare const PopoverArrow: React.ForwardRefExoticComponent<Omit<PopoverPrimitive.PopoverArrowProps & React.RefAttributes<SVGSVGElement>, "ref"> & React.RefAttributes<SVGSVGElement>>;
9
14
 
10
- export { Popover, PopoverAnchor, PopoverArrow, PopoverContent, PopoverTrigger };
15
+ export { Popover, PopoverAnchor, type PopoverAnchorProps, PopoverArrow, type PopoverArrowProps, PopoverContent, type PopoverContentProps, type PopoverProps, PopoverTrigger, type PopoverTriggerProps };
package/dist/popover.d.ts CHANGED
@@ -1,10 +1,15 @@
1
1
  import * as React from 'react';
2
2
  import * as PopoverPrimitive from '@radix-ui/react-popover';
3
3
 
4
+ type PopoverProps = React.ComponentProps<typeof PopoverPrimitive.Root>;
4
5
  declare const Popover: React.FC<PopoverPrimitive.PopoverProps>;
6
+ type PopoverTriggerProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Trigger>;
5
7
  declare const PopoverTrigger: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverTriggerProps & React.RefAttributes<HTMLButtonElement>>;
8
+ type PopoverAnchorProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Anchor>;
6
9
  declare const PopoverAnchor: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverAnchorProps & React.RefAttributes<HTMLDivElement>>;
7
- declare const PopoverContent: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverContentProps & React.RefAttributes<HTMLDivElement>>;
8
- declare const PopoverArrow: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverArrowProps & React.RefAttributes<SVGSVGElement>>;
10
+ type PopoverContentProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Content>;
11
+ declare const PopoverContent: React.ForwardRefExoticComponent<Omit<PopoverPrimitive.PopoverContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
12
+ type PopoverArrowProps = React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Arrow>;
13
+ declare const PopoverArrow: React.ForwardRefExoticComponent<Omit<PopoverPrimitive.PopoverArrowProps & React.RefAttributes<SVGSVGElement>, "ref"> & React.RefAttributes<SVGSVGElement>>;
9
14
 
10
- export { Popover, PopoverAnchor, PopoverArrow, PopoverContent, PopoverTrigger };
15
+ export { Popover, PopoverAnchor, type PopoverAnchorProps, PopoverArrow, type PopoverArrowProps, PopoverContent, type PopoverContentProps, type PopoverProps, PopoverTrigger, type PopoverTriggerProps };
package/dist/popover.js CHANGED
@@ -10,28 +10,23 @@ var _jsxruntime = require('react/jsx-runtime');
10
10
  var Popover = PopoverPrimitive.Root;
11
11
  var PopoverTrigger = PopoverPrimitive.Trigger;
12
12
  var PopoverAnchor = PopoverPrimitive.Anchor;
13
- var PopoverContent = React.forwardRef(({ className, align = "center", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PopoverPrimitive.Portal, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
14
- PopoverPrimitive.Content,
15
- {
16
- ref,
17
- align,
18
- sideOffset,
19
- className: _chunkG3NP7M2Njs.cn.call(void 0,
20
- "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in-0 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-0 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-[8rem] rounded-md border p-4 shadow-md focus:outline-none",
21
- className
22
- ),
23
- ...props
24
- }
25
- ) }));
13
+ var PopoverContent = React.forwardRef(
14
+ ({ className, align = "center", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PopoverPrimitive.Portal, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
15
+ PopoverPrimitive.Content,
16
+ {
17
+ ref,
18
+ align,
19
+ sideOffset,
20
+ className: _chunkG3NP7M2Njs.cn.call(void 0,
21
+ "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in-0 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-0 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-[8rem] rounded-md border p-4 shadow-md focus:outline-none",
22
+ className
23
+ ),
24
+ ...props
25
+ }
26
+ ) })
27
+ );
26
28
  PopoverContent.displayName = PopoverPrimitive.Content.displayName;
27
- var PopoverArrow = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
28
- PopoverPrimitive.Arrow,
29
- {
30
- ref,
31
- className: _chunkG3NP7M2Njs.cn.call(void 0, "fill-popover", className),
32
- ...props
33
- }
34
- ));
29
+ var PopoverArrow = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PopoverPrimitive.Arrow, { ref, className: _chunkG3NP7M2Njs.cn.call(void 0, "fill-popover", className), ...props }));
35
30
  PopoverArrow.displayName = PopoverPrimitive.Arrow.displayName;
36
31
 
37
32
 
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/popover.tsx"],"names":[],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,YAAY,sBAAsB;AA8B9B;AAvBJ,IAAM,UAA2B;AAMjC,IAAM,iBAAkC;AAMxC,IAAM,gBAAiC;AAMvC,IAAM,iBAAuB,iBAG3B,CAAC,EAAE,WAAW,QAAQ,UAAU,aAAa,GAAG,GAAG,MAAM,GAAG,QAC5D,oBAAkB,yBAAjB,EACC;AAAA,EAAkB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA;AAAA,IACA;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,GACF,CACD;AACD,eAAe,cAA+B,yBAAQ;AAMtD,IAAM,eAAqB,iBAGzB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAkB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW,GAAG,gBAAgB,SAAS;AAAA,IACtC,GAAG;AAAA;AACN,CACD;AACD,aAAa,cAA+B,uBAAM","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport * as PopoverPrimitive from \"@radix-ui/react-popover\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: Popover\n * -------------------------------------------------------------------------- */\n\nconst Popover = PopoverPrimitive.Root;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverTrigger\n * -------------------------------------------------------------------------- */\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverAnchor\n * -------------------------------------------------------------------------- */\n\nconst PopoverAnchor = PopoverPrimitive.Anchor;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverContent\n * -------------------------------------------------------------------------- */\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Content>,\n PopoverPrimitive.PopoverContentProps\n>(({ className, align = \"center\", sideOffset = 4, ...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-0 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-0 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-[8rem] rounded-md border p-4 shadow-md focus:outline-none\",\n className,\n )}\n {...props}\n />\n </PopoverPrimitive.Portal>\n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverArrow\n * -------------------------------------------------------------------------- */\n\nconst PopoverArrow = React.forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Arrow>,\n PopoverPrimitive.PopoverArrowProps\n>(({ className, ...props }, ref) => (\n <PopoverPrimitive.Arrow\n ref={ref}\n className={cn(\"fill-popover\", className)}\n {...props}\n />\n));\nPopoverArrow.displayName = PopoverPrimitive.Arrow.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Popover, PopoverTrigger, PopoverContent, PopoverAnchor, PopoverArrow };\n"]}
1
+ {"version":3,"sources":["../src/popover.tsx"],"names":[],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,YAAY,sBAAsB;AAkC5B;AA1BN,IAAM,UAA2B;AAOjC,IAAM,iBAAkC;AAOxC,IAAM,gBAAiC;AASvC,IAAM,iBAAuB;AAAA,EAC3B,CAAC,EAAE,WAAW,QAAQ,UAAU,aAAa,GAAG,GAAG,MAAM,GAAG,QAC1D,oBAAkB,yBAAjB,EACC;AAAA,IAAkB;AAAA,IAAjB;AAAA,MACC;AAAA,MACA;AAAA,MACA;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN,GACF;AAEJ;AAEA,eAAe,cAA+B,yBAAQ;AAStD,IAAM,eAAqB,iBAAmD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACtG,oBAAkB,wBAAjB,EAAuB,KAAU,WAAW,GAAG,gBAAgB,SAAS,GAAI,GAAG,OAAO,CACxF;AAED,aAAa,cAA+B,uBAAM","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport * as PopoverPrimitive from \"@radix-ui/react-popover\";\nimport { cn } from \"./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 = 4, ...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-0 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-0 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-[8rem] rounded-md border p-4 shadow-md focus:outline-none\",\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"]}
package/dist/popover.mjs CHANGED
@@ -10,28 +10,23 @@ import { jsx } from "react/jsx-runtime";
10
10
  var Popover = PopoverPrimitive.Root;
11
11
  var PopoverTrigger = PopoverPrimitive.Trigger;
12
12
  var PopoverAnchor = PopoverPrimitive.Anchor;
13
- var PopoverContent = React.forwardRef(({ className, align = "center", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsx(PopoverPrimitive.Portal, { children: /* @__PURE__ */ jsx(
14
- PopoverPrimitive.Content,
15
- {
16
- ref,
17
- align,
18
- sideOffset,
19
- className: cn(
20
- "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in-0 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-0 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-[8rem] rounded-md border p-4 shadow-md focus:outline-none",
21
- className
22
- ),
23
- ...props
24
- }
25
- ) }));
13
+ var PopoverContent = React.forwardRef(
14
+ ({ className, align = "center", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsx(PopoverPrimitive.Portal, { children: /* @__PURE__ */ jsx(
15
+ PopoverPrimitive.Content,
16
+ {
17
+ ref,
18
+ align,
19
+ sideOffset,
20
+ className: cn(
21
+ "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in-0 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-0 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-[8rem] rounded-md border p-4 shadow-md focus:outline-none",
22
+ className
23
+ ),
24
+ ...props
25
+ }
26
+ ) })
27
+ );
26
28
  PopoverContent.displayName = PopoverPrimitive.Content.displayName;
27
- var PopoverArrow = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
28
- PopoverPrimitive.Arrow,
29
- {
30
- ref,
31
- className: cn("fill-popover", className),
32
- ...props
33
- }
34
- ));
29
+ var PopoverArrow = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(PopoverPrimitive.Arrow, { ref, className: cn("fill-popover", className), ...props }));
35
30
  PopoverArrow.displayName = PopoverPrimitive.Arrow.displayName;
36
31
  export {
37
32
  Popover,
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/popover.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport * as PopoverPrimitive from \"@radix-ui/react-popover\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: Popover\n * -------------------------------------------------------------------------- */\n\nconst Popover = PopoverPrimitive.Root;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverTrigger\n * -------------------------------------------------------------------------- */\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverAnchor\n * -------------------------------------------------------------------------- */\n\nconst PopoverAnchor = PopoverPrimitive.Anchor;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverContent\n * -------------------------------------------------------------------------- */\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Content>,\n PopoverPrimitive.PopoverContentProps\n>(({ className, align = \"center\", sideOffset = 4, ...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-0 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-0 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-[8rem] rounded-md border p-4 shadow-md focus:outline-none\",\n className,\n )}\n {...props}\n />\n </PopoverPrimitive.Portal>\n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: PopoverArrow\n * -------------------------------------------------------------------------- */\n\nconst PopoverArrow = React.forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Arrow>,\n PopoverPrimitive.PopoverArrowProps\n>(({ className, ...props }, ref) => (\n <PopoverPrimitive.Arrow\n ref={ref}\n className={cn(\"fill-popover\", className)}\n {...props}\n />\n));\nPopoverArrow.displayName = PopoverPrimitive.Arrow.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Popover, PopoverTrigger, PopoverContent, PopoverAnchor, PopoverArrow };\n"],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,YAAY,sBAAsB;AA8B9B;AAvBJ,IAAM,UAA2B;AAMjC,IAAM,iBAAkC;AAMxC,IAAM,gBAAiC;AAMvC,IAAM,iBAAuB,iBAG3B,CAAC,EAAE,WAAW,QAAQ,UAAU,aAAa,GAAG,GAAG,MAAM,GAAG,QAC5D,oBAAkB,yBAAjB,EACC;AAAA,EAAkB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA;AAAA,IACA;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,GACF,CACD;AACD,eAAe,cAA+B,yBAAQ;AAMtD,IAAM,eAAqB,iBAGzB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAkB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW,GAAG,gBAAgB,SAAS;AAAA,IACtC,GAAG;AAAA;AACN,CACD;AACD,aAAa,cAA+B,uBAAM;","names":[]}
1
+ {"version":3,"sources":["../src/popover.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport * as PopoverPrimitive from \"@radix-ui/react-popover\";\nimport { cn } from \"./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 = 4, ...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-0 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-0 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-[8rem] rounded-md border p-4 shadow-md focus:outline-none\",\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"],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,YAAY,sBAAsB;AAkC5B;AA1BN,IAAM,UAA2B;AAOjC,IAAM,iBAAkC;AAOxC,IAAM,gBAAiC;AASvC,IAAM,iBAAuB;AAAA,EAC3B,CAAC,EAAE,WAAW,QAAQ,UAAU,aAAa,GAAG,GAAG,MAAM,GAAG,QAC1D,oBAAkB,yBAAjB,EACC;AAAA,IAAkB;AAAA,IAAjB;AAAA,MACC;AAAA,MACA;AAAA,MACA;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN,GACF;AAEJ;AAEA,eAAe,cAA+B,yBAAQ;AAStD,IAAM,eAAqB,iBAAmD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACtG,oBAAkB,wBAAjB,EAAuB,KAAU,WAAW,GAAG,gBAAgB,SAAS,GAAI,GAAG,OAAO,CACxF;AAED,aAAa,cAA+B,uBAAM;","names":[]}
package/dist/pre.d.mts CHANGED
@@ -1,7 +1,8 @@
1
1
  import * as React from 'react';
2
2
 
3
- declare const Pre: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLPreElement> & {
4
- asChild?: boolean | undefined;
5
- } & React.RefAttributes<HTMLPreElement>>;
3
+ interface PreProps extends React.HTMLAttributes<HTMLPreElement> {
4
+ asChild?: boolean;
5
+ }
6
+ declare const Pre: React.ForwardRefExoticComponent<PreProps & React.RefAttributes<HTMLPreElement>>;
6
7
 
7
- export { Pre };
8
+ export { Pre, type PreProps };
package/dist/pre.d.ts CHANGED
@@ -1,7 +1,8 @@
1
1
  import * as React from 'react';
2
2
 
3
- declare const Pre: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLPreElement> & {
4
- asChild?: boolean | undefined;
5
- } & React.RefAttributes<HTMLPreElement>>;
3
+ interface PreProps extends React.HTMLAttributes<HTMLPreElement> {
4
+ asChild?: boolean;
5
+ }
6
+ declare const Pre: React.ForwardRefExoticComponent<PreProps & React.RefAttributes<HTMLPreElement>>;
6
7
 
7
- export { Pre };
8
+ export { Pre, type PreProps };
package/dist/pre.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/pre.tsx"],"names":[],"mappings":";AAAA,YAAY,WAAW;AACvB,SAAS,YAAY;AAYZ;AANT,IAAM,MAAY,iBAGhB,CAAC,EAAE,SAAS,GAAG,MAAM,GAAG,QAAQ;AAChC,QAAM,OAAO,UAAU,OAAO;AAE9B,SAAO,oBAAC,QAAK,KAAW,GAAG,OAAO;AACpC,CAAC;AACD,IAAI,cAAc","sourcesContent":["import * as React from \"react\";\nimport { Slot } from \"@radix-ui/react-slot\";\n\n/* -----------------------------------------------------------------------------\n * Component: Pre\n * -------------------------------------------------------------------------- */\n\nconst Pre = React.forwardRef<\n HTMLPreElement,\n React.HTMLAttributes<HTMLPreElement> & { asChild?: boolean }\n>(({ asChild, ...props }, ref) => {\n const Comp = asChild ? Slot : \"pre\";\n\n return <Comp ref={ref} {...props} />;\n});\nPre.displayName = \"Pre\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Pre };\n"]}
1
+ {"version":3,"sources":["../src/pre.tsx"],"names":[],"mappings":";AAAA,YAAY,WAAW;AACvB,SAAS,YAAY;AAeZ;AAHT,IAAM,MAAY,iBAAiC,CAAC,EAAE,SAAS,GAAG,MAAM,GAAG,QAAQ;AACjF,QAAM,OAAO,UAAU,OAAO;AAE9B,SAAO,oBAAC,QAAK,KAAW,GAAG,OAAO;AACpC,CAAC;AAED,IAAI,cAAc","sourcesContent":["import * as React from \"react\";\nimport { Slot } from \"@radix-ui/react-slot\";\n\n/* -----------------------------------------------------------------------------\n * Component: Pre\n * -------------------------------------------------------------------------- */\n\ntype PreElement = HTMLPreElement;\n\ninterface PreProps extends React.HTMLAttributes<HTMLPreElement> {\n asChild?: boolean;\n}\n\nconst Pre = React.forwardRef<PreElement, PreProps>(({ asChild, ...props }, ref) => {\n const Comp = asChild ? Slot : \"pre\";\n\n return <Comp ref={ref} {...props} />;\n});\n\nPre.displayName = \"Pre\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Pre, type PreProps };\n"]}
package/dist/pre.mjs.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/pre.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { Slot } from \"@radix-ui/react-slot\";\n\n/* -----------------------------------------------------------------------------\n * Component: Pre\n * -------------------------------------------------------------------------- */\n\nconst Pre = React.forwardRef<\n HTMLPreElement,\n React.HTMLAttributes<HTMLPreElement> & { asChild?: boolean }\n>(({ asChild, ...props }, ref) => {\n const Comp = asChild ? Slot : \"pre\";\n\n return <Comp ref={ref} {...props} />;\n});\nPre.displayName = \"Pre\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Pre };\n"],"mappings":";AAAA,YAAY,WAAW;AACvB,SAAS,YAAY;AAYZ;AANT,IAAM,MAAY,iBAGhB,CAAC,EAAE,SAAS,GAAG,MAAM,GAAG,QAAQ;AAChC,QAAM,OAAO,UAAU,OAAO;AAE9B,SAAO,oBAAC,QAAK,KAAW,GAAG,OAAO;AACpC,CAAC;AACD,IAAI,cAAc;","names":[]}
1
+ {"version":3,"sources":["../src/pre.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { Slot } from \"@radix-ui/react-slot\";\n\n/* -----------------------------------------------------------------------------\n * Component: Pre\n * -------------------------------------------------------------------------- */\n\ntype PreElement = HTMLPreElement;\n\ninterface PreProps extends React.HTMLAttributes<HTMLPreElement> {\n asChild?: boolean;\n}\n\nconst Pre = React.forwardRef<PreElement, PreProps>(({ asChild, ...props }, ref) => {\n const Comp = asChild ? Slot : \"pre\";\n\n return <Comp ref={ref} {...props} />;\n});\n\nPre.displayName = \"Pre\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Pre, type PreProps };\n"],"mappings":";AAAA,YAAY,WAAW;AACvB,SAAS,YAAY;AAeZ;AAHT,IAAM,MAAY,iBAAiC,CAAC,EAAE,SAAS,GAAG,MAAM,GAAG,QAAQ;AACjF,QAAM,OAAO,UAAU,OAAO;AAE9B,SAAO,oBAAC,QAAK,KAAW,GAAG,OAAO;AACpC,CAAC;AAED,IAAI,cAAc;","names":[]}
@@ -1,6 +1,7 @@
1
1
  import * as React from 'react';
2
2
  import * as ProgressPrimitive from '@radix-ui/react-progress';
3
3
 
4
- declare const Progress: React.ForwardRefExoticComponent<ProgressPrimitive.ProgressProps & React.RefAttributes<HTMLDivElement>>;
4
+ type ProgressProps = React.ComponentPropsWithoutRef<typeof ProgressPrimitive.Root>;
5
+ declare const Progress: React.ForwardRefExoticComponent<Omit<ProgressPrimitive.ProgressProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
5
6
 
6
- export { Progress };
7
+ export { Progress, type ProgressProps };
@@ -1,6 +1,7 @@
1
1
  import * as React from 'react';
2
2
  import * as ProgressPrimitive from '@radix-ui/react-progress';
3
3
 
4
- declare const Progress: React.ForwardRefExoticComponent<ProgressPrimitive.ProgressProps & React.RefAttributes<HTMLDivElement>>;
4
+ type ProgressProps = React.ComponentPropsWithoutRef<typeof ProgressPrimitive.Root>;
5
+ declare const Progress: React.ForwardRefExoticComponent<Omit<ProgressPrimitive.ProgressProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
5
6
 
6
- export { Progress };
7
+ export { Progress, type ProgressProps };
package/dist/progress.js CHANGED
@@ -11,17 +11,14 @@ var Progress = React.forwardRef(({ className, value, ...props }, ref) => /* @__P
11
11
  ProgressPrimitive.Root,
12
12
  {
13
13
  ref,
14
- className: _chunkG3NP7M2Njs.cn.call(void 0,
15
- "bg-primary/20 relative h-2 w-full overflow-hidden rounded-full",
16
- className
17
- ),
14
+ className: _chunkG3NP7M2Njs.cn.call(void 0, "bg-primary/20 relative h-2 w-full overflow-hidden rounded-full", className),
18
15
  ...props,
19
16
  children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
20
17
  ProgressPrimitive.Indicator,
21
18
  {
22
19
  className: "bg-primary h-full w-full flex-1 transition-all",
23
20
  style: {
24
- transform: `translateX(-${100 - (_nullishCoalesce(value, () => ( 0)))}%)`
21
+ transform: `translateX(-${String(100 - (_nullishCoalesce(value, () => ( 0))))}%)`
25
22
  }
26
23
  }
27
24
  )
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/progress.tsx"],"names":[],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,YAAY,uBAAuB;AAmB/B;AAZJ,IAAM,WAAiB,iBAGrB,CAAC,EAAE,WAAW,OAAO,GAAG,MAAM,GAAG,QACjC;AAAA,EAAmB;AAAA,EAAlB;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA,IAEJ;AAAA,MAAmB;AAAA,MAAlB;AAAA,QACC,WAAU;AAAA,QACV,OAAO;AAAA,UACL,WAAW,eAAe,OAAO,SAAS,EAAE;AAAA,QAC9C;AAAA;AAAA,IACF;AAAA;AACF,CACD;AACD,SAAS,cAAgC,uBAAK","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport * as ProgressPrimitive from \"@radix-ui/react-progress\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: Progress\n * -------------------------------------------------------------------------- */\n\nconst Progress = React.forwardRef<\n React.ElementRef<typeof ProgressPrimitive.Root>,\n ProgressPrimitive.ProgressProps\n>(({ className, value, ...props }, ref) => (\n <ProgressPrimitive.Root\n ref={ref}\n className={cn(\n \"bg-primary/20 relative h-2 w-full overflow-hidden rounded-full\",\n className,\n )}\n {...props}\n >\n <ProgressPrimitive.Indicator\n className=\"bg-primary h-full w-full flex-1 transition-all\"\n style={{\n transform: `translateX(-${100 - (value ?? 0)}%)`,\n }}\n />\n </ProgressPrimitive.Root>\n));\nProgress.displayName = ProgressPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Progress };\n"]}
1
+ {"version":3,"sources":["../src/progress.tsx"],"names":[],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,YAAY,uBAAuB;AAgB/B;AANJ,IAAM,WAAiB,iBAA2C,CAAC,EAAE,WAAW,OAAO,GAAG,MAAM,GAAG,QACjG;AAAA,EAAmB;AAAA,EAAlB;AAAA,IACC;AAAA,IACA,WAAW,GAAG,kEAAkE,SAAS;AAAA,IACxF,GAAG;AAAA,IAEJ;AAAA,MAAmB;AAAA,MAAlB;AAAA,QACC,WAAU;AAAA,QACV,OAAO;AAAA,UACL,WAAW,eAAe,OAAO,OAAO,SAAS,EAAE,CAAC;AAAA,QACtD;AAAA;AAAA,IACF;AAAA;AACF,CACD;AAED,SAAS,cAAgC,uBAAK","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport * as ProgressPrimitive from \"@radix-ui/react-progress\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: Progress\n * -------------------------------------------------------------------------- */\n\ntype ProgressElement = React.ElementRef<typeof ProgressPrimitive.Root>;\ntype ProgressProps = React.ComponentPropsWithoutRef<typeof ProgressPrimitive.Root>;\n\nconst Progress = React.forwardRef<ProgressElement, ProgressProps>(({ className, value, ...props }, ref) => (\n <ProgressPrimitive.Root\n ref={ref}\n className={cn(\"bg-primary/20 relative h-2 w-full overflow-hidden rounded-full\", className)}\n {...props}\n >\n <ProgressPrimitive.Indicator\n className=\"bg-primary h-full w-full flex-1 transition-all\"\n style={{\n transform: `translateX(-${String(100 - (value ?? 0))}%)`,\n }}\n />\n </ProgressPrimitive.Root>\n));\n\nProgress.displayName = ProgressPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Progress, type ProgressProps };\n"]}
package/dist/progress.mjs CHANGED
@@ -11,17 +11,14 @@ var Progress = React.forwardRef(({ className, value, ...props }, ref) => /* @__P
11
11
  ProgressPrimitive.Root,
12
12
  {
13
13
  ref,
14
- className: cn(
15
- "bg-primary/20 relative h-2 w-full overflow-hidden rounded-full",
16
- className
17
- ),
14
+ className: cn("bg-primary/20 relative h-2 w-full overflow-hidden rounded-full", className),
18
15
  ...props,
19
16
  children: /* @__PURE__ */ jsx(
20
17
  ProgressPrimitive.Indicator,
21
18
  {
22
19
  className: "bg-primary h-full w-full flex-1 transition-all",
23
20
  style: {
24
- transform: `translateX(-${100 - (value ?? 0)}%)`
21
+ transform: `translateX(-${String(100 - (value ?? 0))}%)`
25
22
  }
26
23
  }
27
24
  )