@vlrc-fe/components 1.0.6 → 1.0.8

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 (452) hide show
  1. package/dist/Form/FormFileUpload/index.d.ts +1 -1
  2. package/dist/Form/FormFileUpload/index.d.ts.map +1 -1
  3. package/dist/Form/index.d.ts +1 -1
  4. package/dist/Form/index.d.ts.map +1 -1
  5. package/dist/MultiSelect/type.d.ts +2 -2
  6. package/dist/index.cjs +1 -1
  7. package/dist/index.js +64 -40
  8. package/dist/index10.cjs +1 -1
  9. package/dist/index10.js +46 -80
  10. package/dist/index100.cjs +1 -1
  11. package/dist/index100.js +22 -60
  12. package/dist/index101.cjs +1 -1
  13. package/dist/index101.js +1147 -43
  14. package/dist/index102.cjs +1 -1
  15. package/dist/index102.js +30 -64
  16. package/dist/index103.cjs +1 -1
  17. package/dist/index103.js +31 -147
  18. package/dist/index104.cjs +1 -1
  19. package/dist/index104.js +93 -19
  20. package/dist/index105.cjs +1 -1
  21. package/dist/index105.js +80 -25
  22. package/dist/index106.cjs +1 -1
  23. package/dist/index106.js +9 -50
  24. package/dist/index107.cjs +1 -1
  25. package/dist/index107.js +30 -156
  26. package/dist/index108.cjs +1 -1
  27. package/dist/index108.js +350 -14
  28. package/dist/index109.cjs +1 -1
  29. package/dist/index109.js +11 -0
  30. package/dist/index11.cjs +1 -1
  31. package/dist/index11.js +55 -60
  32. package/dist/index110.cjs +1 -0
  33. package/dist/index110.js +430 -0
  34. package/dist/index111.cjs +1 -0
  35. package/dist/index111.js +36 -0
  36. package/dist/index112.cjs +1 -0
  37. package/dist/index112.js +28 -0
  38. package/dist/index113.cjs +1 -0
  39. package/dist/index113.js +14 -0
  40. package/dist/index114.cjs +1 -0
  41. package/dist/index114.js +156 -0
  42. package/dist/index115.cjs +1 -0
  43. package/dist/index115.js +19 -0
  44. package/dist/index116.cjs +1 -0
  45. package/dist/index116.js +67 -0
  46. package/dist/index117.cjs +1 -0
  47. package/dist/index117.js +118 -0
  48. package/dist/index118.cjs +1 -0
  49. package/dist/index118.js +36 -0
  50. package/dist/index119.cjs +1 -0
  51. package/dist/index119.js +13 -0
  52. package/dist/index12.cjs +1 -1
  53. package/dist/index12.js +44 -121
  54. package/dist/index120.cjs +1 -0
  55. package/dist/index120.js +31 -0
  56. package/dist/index121.cjs +1 -0
  57. package/dist/index121.js +37 -0
  58. package/dist/index122.cjs +1 -0
  59. package/dist/index122.js +123 -0
  60. package/dist/index123.cjs +1 -0
  61. package/dist/index123.js +44 -0
  62. package/dist/index124.cjs +1 -0
  63. package/dist/index124.js +43 -0
  64. package/dist/index125.cjs +1 -0
  65. package/dist/index125.js +14 -0
  66. package/dist/index126.cjs +1 -0
  67. package/dist/index126.js +64 -0
  68. package/dist/index127.cjs +1 -0
  69. package/dist/index127.js +23 -0
  70. package/dist/index128.cjs +1 -0
  71. package/dist/index128.js +34 -0
  72. package/dist/index129.cjs +1 -0
  73. package/dist/index129.js +27 -0
  74. package/dist/index13.cjs +1 -1
  75. package/dist/index13.js +30 -12
  76. package/dist/index130.cjs +1 -0
  77. package/dist/index130.js +26 -0
  78. package/dist/index131.cjs +1 -0
  79. package/dist/index131.js +157 -0
  80. package/dist/index132.cjs +1 -0
  81. package/dist/index132.js +34 -0
  82. package/dist/index133.cjs +1 -0
  83. package/dist/index133.js +46 -0
  84. package/dist/index134.cjs +1 -0
  85. package/dist/index134.js +142 -0
  86. package/dist/index135.cjs +1 -0
  87. package/dist/index135.js +125 -0
  88. package/dist/index136.cjs +1 -0
  89. package/dist/index136.js +26 -0
  90. package/dist/index137.cjs +1 -0
  91. package/dist/index137.js +88 -0
  92. package/dist/index138.cjs +1 -0
  93. package/dist/index138.js +221 -0
  94. package/dist/index139.cjs +1 -0
  95. package/dist/index139.js +166 -0
  96. package/dist/index14.cjs +1 -1
  97. package/dist/index14.js +8 -12
  98. package/dist/index140.cjs +1 -0
  99. package/dist/index140.js +126 -0
  100. package/dist/index141.cjs +1 -0
  101. package/dist/index141.js +15 -0
  102. package/dist/index142.cjs +1 -0
  103. package/dist/index142.js +9 -0
  104. package/dist/index143.cjs +1 -0
  105. package/dist/index143.js +17 -0
  106. package/dist/index144.cjs +1 -0
  107. package/dist/index144.js +22 -0
  108. package/dist/index145.cjs +1 -0
  109. package/dist/index145.js +18 -0
  110. package/dist/index146.cjs +1 -0
  111. package/dist/index146.js +6 -0
  112. package/dist/index147.cjs +1 -0
  113. package/dist/index147.js +7 -0
  114. package/dist/index148.cjs +1 -0
  115. package/dist/index148.js +8 -0
  116. package/dist/index149.cjs +1 -0
  117. package/dist/index149.js +7 -0
  118. package/dist/index15.cjs +1 -1
  119. package/dist/index15.js +12 -112
  120. package/dist/index150.cjs +1 -0
  121. package/dist/index150.js +7 -0
  122. package/dist/index151.cjs +1 -0
  123. package/dist/index151.js +9 -0
  124. package/dist/index152.cjs +1 -0
  125. package/dist/index152.js +69 -0
  126. package/dist/index153.cjs +1 -0
  127. package/dist/index153.js +11 -0
  128. package/dist/index154.cjs +1 -0
  129. package/dist/index154.js +202 -0
  130. package/dist/index155.cjs +1 -0
  131. package/dist/index155.js +124 -0
  132. package/dist/index156.cjs +1 -0
  133. package/dist/index156.js +32 -0
  134. package/dist/index157.cjs +1 -0
  135. package/dist/index157.js +20 -0
  136. package/dist/index158.cjs +1 -0
  137. package/dist/index158.js +69 -0
  138. package/dist/index159.cjs +1 -0
  139. package/dist/index159.js +32 -0
  140. package/dist/index16.cjs +1 -1
  141. package/dist/index16.js +4 -726
  142. package/dist/index160.cjs +1 -0
  143. package/dist/index160.js +11 -0
  144. package/dist/index161.cjs +1 -0
  145. package/dist/index161.js +280 -0
  146. package/dist/index162.cjs +1 -0
  147. package/dist/index162.js +157 -0
  148. package/dist/index163.cjs +1 -0
  149. package/dist/index163.js +20 -0
  150. package/dist/index164.cjs +1 -0
  151. package/dist/index164.js +10 -0
  152. package/dist/index165.cjs +1 -0
  153. package/dist/index165.js +14 -0
  154. package/dist/index166.cjs +1 -0
  155. package/dist/index166.js +8 -0
  156. package/dist/index167.cjs +1 -0
  157. package/dist/index167.js +8 -0
  158. package/dist/index168.cjs +1 -0
  159. package/dist/index168.js +11 -0
  160. package/dist/index169.cjs +1 -0
  161. package/dist/index169.js +10 -0
  162. package/dist/index17.cjs +1 -1
  163. package/dist/index17.js +79 -339
  164. package/dist/index170.cjs +1 -0
  165. package/dist/index170.js +6 -0
  166. package/dist/index171.cjs +1 -0
  167. package/dist/index171.js +8 -0
  168. package/dist/index172.cjs +1 -0
  169. package/dist/index172.js +8 -0
  170. package/dist/index173.cjs +1 -0
  171. package/dist/index173.js +10 -0
  172. package/dist/index174.cjs +1 -0
  173. package/dist/index174.js +11 -0
  174. package/dist/index175.cjs +1 -0
  175. package/dist/index175.js +15 -0
  176. package/dist/index176.cjs +1 -0
  177. package/dist/index176.js +11 -0
  178. package/dist/index177.cjs +1 -0
  179. package/dist/index177.js +11 -0
  180. package/dist/index178.cjs +1 -0
  181. package/dist/index178.js +6 -0
  182. package/dist/index179.cjs +1 -0
  183. package/dist/index179.js +43 -0
  184. package/dist/index18.cjs +1 -1
  185. package/dist/index18.js +19 -66
  186. package/dist/index180.cjs +1 -0
  187. package/dist/index180.js +382 -0
  188. package/dist/index181.cjs +1 -0
  189. package/dist/index181.js +40 -0
  190. package/dist/index182.cjs +1 -0
  191. package/dist/index182.js +23 -0
  192. package/dist/index183.cjs +1 -0
  193. package/dist/index183.js +59 -0
  194. package/dist/index184.cjs +1 -0
  195. package/dist/index184.js +55 -0
  196. package/dist/index185.cjs +1 -0
  197. package/dist/index185.js +54 -0
  198. package/dist/index186.cjs +1 -0
  199. package/dist/index186.js +57 -0
  200. package/dist/index187.cjs +1 -0
  201. package/dist/index187.js +57 -0
  202. package/dist/index188.cjs +1 -0
  203. package/dist/index188.js +88 -0
  204. package/dist/index189.cjs +1 -0
  205. package/dist/index189.js +66 -0
  206. package/dist/index19.cjs +1 -1
  207. package/dist/index19.js +18 -8
  208. package/dist/index190.cjs +1 -0
  209. package/dist/index190.js +594 -0
  210. package/dist/index191.cjs +9 -0
  211. package/dist/index191.js +30 -0
  212. package/dist/index192.cjs +1 -0
  213. package/dist/index192.js +50 -0
  214. package/dist/index193.cjs +1 -0
  215. package/dist/index193.js +65 -0
  216. package/dist/index194.cjs +1 -0
  217. package/dist/index194.js +48 -0
  218. package/dist/index195.cjs +1 -0
  219. package/dist/index195.js +67 -0
  220. package/dist/index196.cjs +1 -0
  221. package/dist/index196.js +151 -0
  222. package/dist/index197.cjs +1 -0
  223. package/dist/index197.js +23 -0
  224. package/dist/index198.cjs +1 -0
  225. package/dist/index198.js +27 -0
  226. package/dist/index199.cjs +1 -0
  227. package/dist/index199.js +53 -0
  228. package/dist/index20.cjs +1 -1
  229. package/dist/index20.js +51 -98
  230. package/dist/index200.cjs +1 -0
  231. package/dist/index200.js +161 -0
  232. package/dist/index201.cjs +1 -0
  233. package/dist/index201.js +16 -0
  234. package/dist/index202.cjs +1 -0
  235. package/dist/index21.cjs +1 -1
  236. package/dist/index21.js +81 -28
  237. package/dist/index22.cjs +1 -1
  238. package/dist/index22.js +64 -14
  239. package/dist/index23.cjs +1 -1
  240. package/dist/index23.js +25 -22
  241. package/dist/index24.cjs +1 -1
  242. package/dist/index24.js +1014 -33
  243. package/dist/index25.cjs +1 -1
  244. package/dist/index25.js +22 -96
  245. package/dist/index26.cjs +1 -1
  246. package/dist/index26.js +108 -25
  247. package/dist/index27.cjs +1 -1
  248. package/dist/index27.js +15 -9
  249. package/dist/index28.cjs +1 -1
  250. package/dist/index28.js +20 -66
  251. package/dist/index29.cjs +1 -1
  252. package/dist/index29.js +81 -11
  253. package/dist/index30.cjs +1 -1
  254. package/dist/index30.js +91 -29
  255. package/dist/index31.cjs +1 -1
  256. package/dist/index31.js +14 -41
  257. package/dist/index32.cjs +1 -1
  258. package/dist/index32.js +93 -12
  259. package/dist/index33.cjs +1 -1
  260. package/dist/index33.js +22 -62
  261. package/dist/index34.cjs +1 -1
  262. package/dist/index34.js +84 -22
  263. package/dist/index35.cjs +1 -1
  264. package/dist/index35.js +85 -33
  265. package/dist/index36.cjs +1 -1
  266. package/dist/index36.js +407 -25
  267. package/dist/index37.cjs +1 -1
  268. package/dist/index37.js +170 -25
  269. package/dist/index38.cjs +1 -1
  270. package/dist/index38.js +28 -154
  271. package/dist/index39.cjs +1 -1
  272. package/dist/index39.js +158 -33
  273. package/dist/index40.cjs +1 -1
  274. package/dist/index40.js +104 -45
  275. package/dist/index41.cjs +1 -1
  276. package/dist/index41.js +337 -140
  277. package/dist/index42.cjs +1 -1
  278. package/dist/index42.js +96 -124
  279. package/dist/index43.cjs +1 -1
  280. package/dist/index43.js +319 -23
  281. package/dist/index44.cjs +1 -1
  282. package/dist/index44.js +205 -81
  283. package/dist/index45.cjs +1 -1
  284. package/dist/index45.js +33 -220
  285. package/dist/index46.cjs +1 -1
  286. package/dist/index46.js +161 -163
  287. package/dist/index47.cjs +1 -1
  288. package/dist/index47.js +20 -125
  289. package/dist/index48.cjs +1 -1
  290. package/dist/index48.js +24 -14
  291. package/dist/index49.cjs +1 -1
  292. package/dist/index49.js +167 -7
  293. package/dist/index5.js +26 -14
  294. package/dist/index50.cjs +1 -1
  295. package/dist/index50.js +44 -15
  296. package/dist/index51.cjs +1 -1
  297. package/dist/index51.js +15 -18
  298. package/dist/index52.cjs +1 -1
  299. package/dist/index52.js +3 -17
  300. package/dist/index53.cjs +1 -1
  301. package/dist/index53.js +5 -5
  302. package/dist/index54.cjs +1 -1
  303. package/dist/index54.js +19 -4
  304. package/dist/index55.cjs +1 -1
  305. package/dist/index55.js +24 -6
  306. package/dist/index56.cjs +1 -1
  307. package/dist/index56.js +66 -4
  308. package/dist/index57.cjs +1 -1
  309. package/dist/index57.js +14 -5
  310. package/dist/index58.cjs +1 -1
  311. package/dist/index58.js +4 -8
  312. package/dist/index59.cjs +1 -1
  313. package/dist/index59.js +50 -67
  314. package/dist/index6.cjs +1 -1
  315. package/dist/index6.js +85 -46
  316. package/dist/index60.cjs +1 -1
  317. package/dist/index60.js +6 -10
  318. package/dist/index61.cjs +1 -1
  319. package/dist/index61.js +25 -199
  320. package/dist/index62.cjs +1 -1
  321. package/dist/index62.js +13 -122
  322. package/dist/index63.cjs +1 -1
  323. package/dist/index63.js +9 -30
  324. package/dist/index64.cjs +1 -1
  325. package/dist/index64.js +3 -20
  326. package/dist/index65.cjs +1 -1
  327. package/dist/index65.js +24 -66
  328. package/dist/index66.cjs +1 -1
  329. package/dist/index66.js +68 -30
  330. package/dist/index67.cjs +38 -1
  331. package/dist/index67.js +3 -11
  332. package/dist/index68.cjs +1 -1
  333. package/dist/index68.js +12 -279
  334. package/dist/index69.cjs +1 -1
  335. package/dist/index69.js +50 -155
  336. package/dist/index7.cjs +1 -1
  337. package/dist/index7.js +29 -85
  338. package/dist/index70.cjs +1 -1
  339. package/dist/index70.js +115 -19
  340. package/dist/index71.cjs +4 -1
  341. package/dist/index71.js +6 -9
  342. package/dist/index72.cjs +1 -1
  343. package/dist/index72.js +12 -12
  344. package/dist/index73.cjs +1 -1
  345. package/dist/index73.js +539 -6
  346. package/dist/index74.cjs +1 -1
  347. package/dist/index74.js +197 -6
  348. package/dist/index75.cjs +1 -1
  349. package/dist/index75.js +120 -9
  350. package/dist/index76.cjs +1 -1
  351. package/dist/index76.js +912 -8
  352. package/dist/index77.cjs +3 -1
  353. package/dist/index77.js +76 -4
  354. package/dist/index78.cjs +1 -1
  355. package/dist/index78.js +120 -6
  356. package/dist/index79.cjs +1 -1
  357. package/dist/index79.js +12 -6
  358. package/dist/index8.cjs +1 -1
  359. package/dist/index8.js +35 -62
  360. package/dist/index80.cjs +1 -1
  361. package/dist/index80.js +14 -8
  362. package/dist/index81.cjs +1 -1
  363. package/dist/index81.js +113 -9
  364. package/dist/index82.cjs +1 -1
  365. package/dist/index82.js +725 -13
  366. package/dist/index83.cjs +1 -1
  367. package/dist/index83.js +346 -9
  368. package/dist/index84.cjs +1 -1
  369. package/dist/index84.js +74 -9
  370. package/dist/index85.cjs +1 -1
  371. package/dist/index85.js +148 -4
  372. package/dist/index86.cjs +1 -1
  373. package/dist/index86.js +31 -42
  374. package/dist/index87.cjs +1 -1
  375. package/dist/index87.js +12 -380
  376. package/dist/index88.cjs +1 -1
  377. package/dist/index88.js +345 -37
  378. package/dist/index89.cjs +20 -1
  379. package/dist/index89.js +40 -18
  380. package/dist/index9.cjs +1 -1
  381. package/dist/index9.js +85 -17
  382. package/dist/index90.cjs +1 -1
  383. package/dist/index90.js +113 -56
  384. package/dist/index91.cjs +1 -1
  385. package/dist/index91.js +272 -51
  386. package/dist/index92.cjs +1 -1
  387. package/dist/index92.js +129 -50
  388. package/dist/index93.cjs +1 -1
  389. package/dist/index93.js +13 -54
  390. package/dist/index94.cjs +1 -1
  391. package/dist/index94.js +28 -55
  392. package/dist/index95.cjs +1 -1
  393. package/dist/index95.js +525 -80
  394. package/dist/index96.cjs +1 -1
  395. package/dist/index96.js +75 -61
  396. package/dist/index97.cjs +1 -1
  397. package/dist/index97.js +67 -583
  398. package/dist/index98.cjs +1 -9
  399. package/dist/index98.js +32 -27
  400. package/dist/index99.cjs +1 -1
  401. package/dist/index99.js +17 -49
  402. package/dist/ui/alert-dialog.d.ts +15 -0
  403. package/dist/ui/alert-dialog.d.ts.map +1 -0
  404. package/dist/ui/alert.d.ts +10 -0
  405. package/dist/ui/alert.d.ts.map +1 -0
  406. package/dist/ui/aspect-ratio.d.ts +4 -0
  407. package/dist/ui/aspect-ratio.d.ts.map +1 -0
  408. package/dist/ui/avatar.d.ts +7 -0
  409. package/dist/ui/avatar.d.ts.map +1 -0
  410. package/dist/ui/badge.d.ts +1 -1
  411. package/dist/ui/breadcrumb.d.ts +12 -0
  412. package/dist/ui/breadcrumb.d.ts.map +1 -0
  413. package/dist/ui/button.d.ts +1 -1
  414. package/dist/ui/carousel.d.ts +20 -0
  415. package/dist/ui/carousel.d.ts.map +1 -0
  416. package/dist/ui/collapsible.d.ts +6 -0
  417. package/dist/ui/collapsible.d.ts.map +1 -0
  418. package/dist/ui/context-menu.d.ts +26 -0
  419. package/dist/ui/context-menu.d.ts.map +1 -0
  420. package/dist/ui/drawer.d.ts +14 -0
  421. package/dist/ui/drawer.d.ts.map +1 -0
  422. package/dist/ui/hover-card.d.ts +7 -0
  423. package/dist/ui/hover-card.d.ts.map +1 -0
  424. package/dist/ui/index.d.ts +23 -0
  425. package/dist/ui/index.d.ts.map +1 -1
  426. package/dist/ui/input-otp.d.ts +12 -0
  427. package/dist/ui/input-otp.d.ts.map +1 -0
  428. package/dist/ui/menubar.d.ts +27 -0
  429. package/dist/ui/menubar.d.ts.map +1 -0
  430. package/dist/ui/navigation-menu.d.ts +15 -0
  431. package/dist/ui/navigation-menu.d.ts.map +1 -0
  432. package/dist/ui/pagination.d.ts +14 -0
  433. package/dist/ui/pagination.d.ts.map +1 -0
  434. package/dist/ui/resizable.d.ts +9 -0
  435. package/dist/ui/resizable.d.ts.map +1 -0
  436. package/dist/ui/sheet.d.ts +14 -0
  437. package/dist/ui/sheet.d.ts.map +1 -0
  438. package/dist/ui/sidebar.d.ts +70 -0
  439. package/dist/ui/sidebar.d.ts.map +1 -0
  440. package/dist/ui/skeleton.d.ts +3 -0
  441. package/dist/ui/skeleton.d.ts.map +1 -0
  442. package/dist/ui/slider.d.ts +5 -0
  443. package/dist/ui/slider.d.ts.map +1 -0
  444. package/dist/ui/switch.d.ts +5 -0
  445. package/dist/ui/switch.d.ts.map +1 -0
  446. package/dist/ui/tabs.d.ts +8 -0
  447. package/dist/ui/tabs.d.ts.map +1 -0
  448. package/dist/ui/toggle-group.d.ts +8 -0
  449. package/dist/ui/toggle-group.d.ts.map +1 -0
  450. package/dist/ui/toggle.d.ts +10 -0
  451. package/dist/ui/toggle.d.ts.map +1 -0
  452. package/package.json +23 -5
@@ -0,0 +1,31 @@
1
+ "use client";
2
+ import { composeEventHandlers as e } from "./index8.js";
3
+ import { Primitive as t } from "./index12.js";
4
+ import { useControllableState as n } from "./index29.js";
5
+ import * as r from "react";
6
+ import { jsx as i } from "react/jsx-runtime";
7
+ //#region ../../node_modules/.pnpm/@radix-ui+react-toggle@1.1.18_@types+react-dom@19.2.3_@types+react@19.2.17__@types+reac_bfc68b0fc9dd6fbca9be8cf294d00420/node_modules/@radix-ui/react-toggle/dist/index.mjs
8
+ var a = Object.defineProperty, o = (e, t) => a(e, "name", {
9
+ value: t,
10
+ configurable: !0
11
+ }), s = "Toggle", c = /* @__PURE__ */ r.forwardRef(/* @__PURE__ */ o(function(r, a) {
12
+ let { pressed: o, defaultPressed: c, onPressedChange: l, ...u } = r, [d, f] = n({
13
+ prop: o,
14
+ onChange: l,
15
+ defaultProp: c ?? !1,
16
+ caller: s
17
+ });
18
+ return /* @__PURE__ */ i(t.button, {
19
+ type: "button",
20
+ "aria-pressed": d,
21
+ "data-state": d ? "on" : "off",
22
+ "data-disabled": r.disabled ? "" : void 0,
23
+ ...u,
24
+ ref: a,
25
+ onClick: e(r.onClick, () => {
26
+ r.disabled || f(!d);
27
+ })
28
+ });
29
+ }, "Toggle")), l = c;
30
+ //#endregion
31
+ export { l as Root, c as Toggle };
@@ -0,0 +1 @@
1
+ "use client";const e=require("./index2.cjs"),t=require("./index9.cjs"),n=require("./index13.cjs"),r=require("./index30.cjs");let i=require("react");i=e.__toESM(i,1);let a=require("react/jsx-runtime");var o=Object.defineProperty,s=(e,t)=>o(e,`name`,{value:t,configurable:!0}),c=`Toggle`,l=i.forwardRef(s(function(e,i){let{pressed:o,defaultPressed:s,onPressedChange:l,...u}=e,[d,f]=r.useControllableState({prop:o,onChange:l,defaultProp:s??!1,caller:c});return(0,a.jsx)(n.Primitive.button,{type:`button`,"aria-pressed":d,"data-state":d?`on`:`off`,"data-disabled":e.disabled?``:void 0,...u,ref:i,onClick:t.composeEventHandlers(e.onClick,()=>{e.disabled||f(!d)})})},`Toggle`)),u=l;exports.Root=u,exports.Toggle=l;
@@ -0,0 +1,37 @@
1
+ "use client";
2
+ import { cn as e } from "./index3.js";
3
+ import { Root as t } from "./index120.js";
4
+ import "react";
5
+ import { jsx as n } from "react/jsx-runtime";
6
+ import { cva as r } from "class-variance-authority";
7
+ //#region src/ui/toggle.tsx
8
+ var i = r("inline-flex items-center justify-center gap-2 rounded-md text-sm font-medium hover:bg-muted hover:text-muted-foreground disabled:pointer-events-none disabled:opacity-50 data-[state=on]:bg-accent data-[state=on]:text-accent-foreground [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 [&_svg]:shrink-0 focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none transition-[color,box-shadow] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive whitespace-nowrap", {
9
+ variants: {
10
+ variant: {
11
+ default: "bg-transparent",
12
+ outline: "border border-input bg-transparent shadow-xs hover:bg-accent hover:text-accent-foreground"
13
+ },
14
+ size: {
15
+ default: "h-9 px-2 min-w-9",
16
+ sm: "h-8 px-1.5 min-w-8",
17
+ lg: "h-10 px-2.5 min-w-10"
18
+ }
19
+ },
20
+ defaultVariants: {
21
+ variant: "default",
22
+ size: "default"
23
+ }
24
+ });
25
+ function a({ className: r, variant: a, size: o, ...s }) {
26
+ return /* @__PURE__ */ n(t, {
27
+ "data-slot": "toggle",
28
+ className: e(i({
29
+ variant: a,
30
+ size: o,
31
+ className: r
32
+ })),
33
+ ...s
34
+ });
35
+ }
36
+ //#endregion
37
+ export { a as Toggle, i as toggleVariants };
@@ -0,0 +1 @@
1
+ "use client";const e=require("./index2.cjs"),t=require("./index4.cjs"),n=require("./index121.cjs");let r=require("react");r=e.__toESM(r,1);let i=require("react/jsx-runtime");var a=(0,require("class-variance-authority").cva)(`inline-flex items-center justify-center gap-2 rounded-md text-sm font-medium hover:bg-muted hover:text-muted-foreground disabled:pointer-events-none disabled:opacity-50 data-[state=on]:bg-accent data-[state=on]:text-accent-foreground [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 [&_svg]:shrink-0 focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none transition-[color,box-shadow] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive whitespace-nowrap`,{variants:{variant:{default:`bg-transparent`,outline:`border border-input bg-transparent shadow-xs hover:bg-accent hover:text-accent-foreground`},size:{default:`h-9 px-2 min-w-9`,sm:`h-8 px-1.5 min-w-8`,lg:`h-10 px-2.5 min-w-10`}},defaultVariants:{variant:`default`,size:`default`}});function o({className:e,variant:r,size:o,...s}){return(0,i.jsx)(n.Root,{"data-slot":`toggle`,className:t.cn(a({variant:r,size:o,className:e})),...s})}exports.Toggle=o,exports.toggleVariants=a;
@@ -0,0 +1,123 @@
1
+ "use client";
2
+ import { createContextScope as e } from "./index6.js";
3
+ import { Primitive as t } from "./index12.js";
4
+ import { useControllableState as n } from "./index29.js";
5
+ import { Item as r, Root as i, createRovingFocusGroupScope as a } from "./index49.js";
6
+ import { Toggle as o } from "./index120.js";
7
+ import * as s from "react";
8
+ import { jsx as c } from "react/jsx-runtime";
9
+ import { useDirection as l } from "@radix-ui/react-direction";
10
+ //#region ../../node_modules/.pnpm/@radix-ui+react-toggle-group@1.1.19_@types+react-dom@19.2.3_@types+react@19.2.17__@type_8d974b08799a7a6c081744aa632f25fd/node_modules/@radix-ui/react-toggle-group/dist/index.mjs
11
+ var u = Object.defineProperty, d = (e, t) => u(e, "name", {
12
+ value: t,
13
+ configurable: !0
14
+ }), f = "ToggleGroup", [p, m] = e(f, [a]), h = a(), g = /* @__PURE__ */ s.forwardRef(/* @__PURE__ */ d(function(e, t) {
15
+ let { type: n, ...r } = e;
16
+ if (n === "single") return /* @__PURE__ */ c(y, {
17
+ role: "radiogroup",
18
+ ...r,
19
+ ref: t
20
+ });
21
+ if (n === "multiple") return /* @__PURE__ */ c(b, {
22
+ role: "toolbar",
23
+ ...r,
24
+ ref: t
25
+ });
26
+ throw Error(`Missing prop \`type\` expected on \`${f}\``);
27
+ }, "ToggleGroup")), [_, v] = p(f), y = /* @__PURE__ */ s.forwardRef(/* @__PURE__ */ d(function(e, t) {
28
+ let { value: r, defaultValue: i, onValueChange: a = /* @__PURE__ */ d(() => {}, "onValueChange"), ...o } = e, [l, u] = n({
29
+ prop: r,
30
+ defaultProp: i ?? "",
31
+ onChange: a,
32
+ caller: f
33
+ });
34
+ return /* @__PURE__ */ c(_, {
35
+ scope: e.__scopeToggleGroup,
36
+ type: "single",
37
+ value: s.useMemo(() => l ? [l] : [], [l]),
38
+ onItemActivate: u,
39
+ onItemDeactivate: s.useCallback(() => u(""), [u]),
40
+ children: /* @__PURE__ */ c(C, {
41
+ ...o,
42
+ ref: t
43
+ })
44
+ });
45
+ }, "ToggleGroupImplSingle")), b = /* @__PURE__ */ s.forwardRef(/* @__PURE__ */ d(function(e, t) {
46
+ let { value: r, defaultValue: i, onValueChange: a = /* @__PURE__ */ d(() => {}, "onValueChange"), ...o } = e, [l, u] = n({
47
+ prop: r,
48
+ defaultProp: i ?? [],
49
+ onChange: a,
50
+ caller: f
51
+ }), p = s.useCallback((e) => u((t = []) => [...t, e]), [u]), m = s.useCallback((e) => u((t = []) => t.filter((t) => t !== e)), [u]);
52
+ return /* @__PURE__ */ c(_, {
53
+ scope: e.__scopeToggleGroup,
54
+ type: "multiple",
55
+ value: l,
56
+ onItemActivate: p,
57
+ onItemDeactivate: m,
58
+ children: /* @__PURE__ */ c(C, {
59
+ ...o,
60
+ ref: t
61
+ })
62
+ });
63
+ }, "ToggleGroupImplMultiple")), [x, S] = p(f), C = /* @__PURE__ */ s.forwardRef(/* @__PURE__ */ d(function(e, n) {
64
+ let { __scopeToggleGroup: r, disabled: a = !1, rovingFocus: o = !0, orientation: s, dir: u, loop: d = !0, ...f } = e, p = h(r), m = l(u), g = {
65
+ dir: m,
66
+ ...f
67
+ };
68
+ return /* @__PURE__ */ c(x, {
69
+ scope: r,
70
+ rovingFocus: o,
71
+ disabled: a,
72
+ children: o ? /* @__PURE__ */ c(i, {
73
+ asChild: !0,
74
+ ...p,
75
+ orientation: s,
76
+ dir: m,
77
+ loop: d,
78
+ children: /* @__PURE__ */ c(t.div, {
79
+ ...g,
80
+ ref: n
81
+ })
82
+ }) : /* @__PURE__ */ c(t.div, {
83
+ ...g,
84
+ ref: n
85
+ })
86
+ });
87
+ }, "ToggleGroupImpl")), w = "ToggleGroupItem", T = /* @__PURE__ */ s.forwardRef(/* @__PURE__ */ d(function(e, t) {
88
+ let n = v(w, e.__scopeToggleGroup), i = S(w, e.__scopeToggleGroup), a = h(e.__scopeToggleGroup), o = n.value.includes(e.value), l = i.disabled || e.disabled, u = {
89
+ ...e,
90
+ pressed: o,
91
+ disabled: l
92
+ }, d = s.useRef(null);
93
+ return i.rovingFocus ? /* @__PURE__ */ c(r, {
94
+ asChild: !0,
95
+ ...a,
96
+ focusable: !l,
97
+ active: o,
98
+ ref: d,
99
+ children: /* @__PURE__ */ c(E, {
100
+ ...u,
101
+ ref: t
102
+ })
103
+ }) : /* @__PURE__ */ c(E, {
104
+ ...u,
105
+ ref: t
106
+ });
107
+ }, "ToggleGroupItem")), E = /* @__PURE__ */ s.forwardRef(/* @__PURE__ */ d(function(e, t) {
108
+ let { __scopeToggleGroup: n, value: r, ...i } = e, a = v(w, n), s = {
109
+ role: "radio",
110
+ "aria-checked": e.pressed,
111
+ "aria-pressed": void 0
112
+ };
113
+ return /* @__PURE__ */ c(o, {
114
+ ...a.type === "single" ? s : void 0,
115
+ ...i,
116
+ ref: t,
117
+ onPressedChange: (e) => {
118
+ e ? a.onItemActivate(r) : a.onItemDeactivate(r);
119
+ }
120
+ });
121
+ }, "ToggleGroupItemImpl"));
122
+ //#endregion
123
+ export { g as ToggleGroup, T as ToggleGroupItem };
@@ -0,0 +1 @@
1
+ "use client";const e=require("./index2.cjs"),t=require("./index7.cjs"),n=require("./index13.cjs"),r=require("./index30.cjs"),i=require("./index50.cjs"),a=require("./index121.cjs");let o=require("react");o=e.__toESM(o,1);let s=require("react/jsx-runtime"),c=require("@radix-ui/react-direction");var l=Object.defineProperty,u=(e,t)=>l(e,`name`,{value:t,configurable:!0}),d=`ToggleGroup`,[f,p]=t.createContextScope(d,[i.createRovingFocusGroupScope]),m=i.createRovingFocusGroupScope(),h=o.forwardRef(u(function(e,t){let{type:n,...r}=e;if(n===`single`)return(0,s.jsx)(v,{role:`radiogroup`,...r,ref:t});if(n===`multiple`)return(0,s.jsx)(y,{role:`toolbar`,...r,ref:t});throw Error(`Missing prop \`type\` expected on \`${d}\``)},`ToggleGroup`)),[g,_]=f(d),v=o.forwardRef(u(function(e,t){let{value:n,defaultValue:i,onValueChange:a=u(()=>{},`onValueChange`),...c}=e,[l,f]=r.useControllableState({prop:n,defaultProp:i??``,onChange:a,caller:d});return(0,s.jsx)(g,{scope:e.__scopeToggleGroup,type:`single`,value:o.useMemo(()=>l?[l]:[],[l]),onItemActivate:f,onItemDeactivate:o.useCallback(()=>f(``),[f]),children:(0,s.jsx)(S,{...c,ref:t})})},`ToggleGroupImplSingle`)),y=o.forwardRef(u(function(e,t){let{value:n,defaultValue:i,onValueChange:a=u(()=>{},`onValueChange`),...c}=e,[l,f]=r.useControllableState({prop:n,defaultProp:i??[],onChange:a,caller:d}),p=o.useCallback(e=>f((t=[])=>[...t,e]),[f]),m=o.useCallback(e=>f((t=[])=>t.filter(t=>t!==e)),[f]);return(0,s.jsx)(g,{scope:e.__scopeToggleGroup,type:`multiple`,value:l,onItemActivate:p,onItemDeactivate:m,children:(0,s.jsx)(S,{...c,ref:t})})},`ToggleGroupImplMultiple`)),[b,x]=f(d),S=o.forwardRef(u(function(e,t){let{__scopeToggleGroup:r,disabled:a=!1,rovingFocus:o=!0,orientation:l,dir:u,loop:d=!0,...f}=e,p=m(r),h=(0,c.useDirection)(u),g={dir:h,...f};return(0,s.jsx)(b,{scope:r,rovingFocus:o,disabled:a,children:o?(0,s.jsx)(i.Root,{asChild:!0,...p,orientation:l,dir:h,loop:d,children:(0,s.jsx)(n.Primitive.div,{...g,ref:t})}):(0,s.jsx)(n.Primitive.div,{...g,ref:t})})},`ToggleGroupImpl`)),C=`ToggleGroupItem`,w=o.forwardRef(u(function(e,t){let n=_(C,e.__scopeToggleGroup),r=x(C,e.__scopeToggleGroup),a=m(e.__scopeToggleGroup),c=n.value.includes(e.value),l=r.disabled||e.disabled,u={...e,pressed:c,disabled:l},d=o.useRef(null);return r.rovingFocus?(0,s.jsx)(i.Item,{asChild:!0,...a,focusable:!l,active:c,ref:d,children:(0,s.jsx)(T,{...u,ref:t})}):(0,s.jsx)(T,{...u,ref:t})},`ToggleGroupItem`)),T=o.forwardRef(u(function(e,t){let{__scopeToggleGroup:n,value:r,...i}=e,o=_(C,n),c={role:`radio`,"aria-checked":e.pressed,"aria-pressed":void 0};return(0,s.jsx)(a.Toggle,{...o.type===`single`?c:void 0,...i,ref:t,onPressedChange:e=>{e?o.onItemActivate(r):o.onItemDeactivate(r)}})},`ToggleGroupItemImpl`));exports.ToggleGroup=h,exports.ToggleGroupItem=w;
@@ -0,0 +1,44 @@
1
+ "use client";
2
+ import { cn as e } from "./index3.js";
3
+ import { toggleVariants as t } from "./index121.js";
4
+ import { ToggleGroup as n, ToggleGroupItem as r } from "./index122.js";
5
+ import * as i from "react";
6
+ import { jsx as a } from "react/jsx-runtime";
7
+ import "class-variance-authority";
8
+ //#region src/ui/toggle-group.tsx
9
+ var o = i.createContext({
10
+ size: "default",
11
+ variant: "default"
12
+ });
13
+ function s({ className: t, variant: r, size: i, children: s, ...c }) {
14
+ return /* @__PURE__ */ a(n, {
15
+ "data-slot": "toggle-group",
16
+ "data-variant": r,
17
+ "data-size": i,
18
+ className: e("group/toggle-group flex w-fit items-center rounded-md data-[variant=outline]:shadow-xs", t),
19
+ ...c,
20
+ children: /* @__PURE__ */ a(o.Provider, {
21
+ value: {
22
+ variant: r,
23
+ size: i
24
+ },
25
+ children: s
26
+ })
27
+ });
28
+ }
29
+ function c({ className: n, children: s, variant: c, size: l, ...u }) {
30
+ let d = i.useContext(o);
31
+ return /* @__PURE__ */ a(r, {
32
+ "data-slot": "toggle-group-item",
33
+ "data-variant": d.variant || c,
34
+ "data-size": d.size || l,
35
+ className: e(t({
36
+ variant: d.variant || c,
37
+ size: d.size || l
38
+ }), "min-w-0 flex-1 shrink-0 rounded-none shadow-none first:rounded-l-md last:rounded-r-md focus:z-10 focus-visible:z-10 data-[variant=outline]:border-l-0 data-[variant=outline]:first:border-l", n),
39
+ ...u,
40
+ children: s
41
+ });
42
+ }
43
+ //#endregion
44
+ export { s as ToggleGroup, c as ToggleGroupItem };
@@ -0,0 +1 @@
1
+ "use client";const e=require("./index2.cjs"),t=require("./index4.cjs"),n=require("./index122.cjs"),r=require("./index123.cjs");let i=require("react");i=e.__toESM(i,1);let a=require("react/jsx-runtime");require("class-variance-authority");var o=i.createContext({size:`default`,variant:`default`});function s({className:e,variant:n,size:i,children:s,...c}){return(0,a.jsx)(r.ToggleGroup,{"data-slot":`toggle-group`,"data-variant":n,"data-size":i,className:t.cn(`group/toggle-group flex w-fit items-center rounded-md data-[variant=outline]:shadow-xs`,e),...c,children:(0,a.jsx)(o.Provider,{value:{variant:n,size:i},children:s})})}function c({className:e,children:s,variant:c,size:l,...u}){let d=i.useContext(o);return(0,a.jsx)(r.ToggleGroupItem,{"data-slot":`toggle-group-item`,"data-variant":d.variant||c,"data-size":d.size||l,className:t.cn(n.toggleVariants({variant:d.variant||c,size:d.size||l}),`min-w-0 flex-1 shrink-0 rounded-none shadow-none first:rounded-l-md last:rounded-r-md focus:z-10 focus-visible:z-10 data-[variant=outline]:border-l-0 data-[variant=outline]:first:border-l`,e),...u,children:s})}exports.ToggleGroup=s,exports.ToggleGroupItem=c;
@@ -0,0 +1,43 @@
1
+ import { cn as e } from "./index3.js";
2
+ import { Button as t } from "./index10.js";
3
+ import { Dialog as n, DialogContent as r, DialogDescription as i, DialogFooter as a, DialogHeader as o, DialogTitle as s } from "./index34.js";
4
+ import { jsx as c, jsxs as l } from "react/jsx-runtime";
5
+ //#region src/Modal.tsx
6
+ function u({ open: u = !0, title: d, description: f, children: p, footer: m, width: h = 900, confirmText: g = "Xác nhận", cancelText: _ = "Hủy", isLoading: v = !1, onCancel: y, onConfirm: b }) {
7
+ return /* @__PURE__ */ c(n, {
8
+ open: u,
9
+ onOpenChange: (e) => !e && y(),
10
+ children: /* @__PURE__ */ l(r, {
11
+ className: e("flex max-h-[calc(100vh-150px)] flex-col gap-0 p-0 sm:max-w-175"),
12
+ style: { maxWidth: h },
13
+ children: [
14
+ /* @__PURE__ */ l(o, {
15
+ className: "px-6 py-4 border-b",
16
+ children: [/* @__PURE__ */ c(s, { children: d }), f ? /* @__PURE__ */ c(i, { children: f }) : null]
17
+ }),
18
+ /* @__PURE__ */ c("div", {
19
+ className: "flex-1 overflow-y-auto px-6 py-4",
20
+ children: p
21
+ }),
22
+ (m || b) && /* @__PURE__ */ c(a, {
23
+ className: "px-6 py-4 border-t",
24
+ children: m || /* @__PURE__ */ l("div", {
25
+ className: "flex w-full justify-end gap-2",
26
+ children: [/* @__PURE__ */ c(t, {
27
+ variant: "outline",
28
+ onClick: y,
29
+ disabled: v,
30
+ children: _
31
+ }), b ? /* @__PURE__ */ c(t, {
32
+ onClick: b,
33
+ disabled: v,
34
+ children: g
35
+ }) : null]
36
+ })
37
+ })
38
+ ]
39
+ })
40
+ });
41
+ }
42
+ //#endregion
43
+ export { u as Modal };
@@ -0,0 +1 @@
1
+ const e=require("./index4.cjs"),t=require("./index11.cjs"),n=require("./index35.cjs");let r=require("react/jsx-runtime");function i({open:i=!0,title:a,description:o,children:s,footer:c,width:l=900,confirmText:u=`Xác nhận`,cancelText:d=`Hủy`,isLoading:f=!1,onCancel:p,onConfirm:m}){return(0,r.jsx)(n.Dialog,{open:i,onOpenChange:e=>!e&&p(),children:(0,r.jsxs)(n.DialogContent,{className:e.cn(`flex max-h-[calc(100vh-150px)] flex-col gap-0 p-0 sm:max-w-175`),style:{maxWidth:l},children:[(0,r.jsxs)(n.DialogHeader,{className:`px-6 py-4 border-b`,children:[(0,r.jsx)(n.DialogTitle,{children:a}),o?(0,r.jsx)(n.DialogDescription,{children:o}):null]}),(0,r.jsx)(`div`,{className:`flex-1 overflow-y-auto px-6 py-4`,children:s}),(c||m)&&(0,r.jsx)(n.DialogFooter,{className:`px-6 py-4 border-t`,children:c||(0,r.jsxs)(`div`,{className:`flex w-full justify-end gap-2`,children:[(0,r.jsx)(t.Button,{variant:`outline`,onClick:p,disabled:f,children:d}),m?(0,r.jsx)(t.Button,{onClick:m,disabled:f,children:u}):null]})})]})})}exports.Modal=i;
@@ -0,0 +1,14 @@
1
+ import { Suspense as e, lazy as t } from "react";
2
+ import { jsx as n } from "react/jsx-runtime";
3
+ //#region src/lazyLoad.tsx
4
+ function r(r, i = /* @__PURE__ */ n("div", { children: "Loading..." })) {
5
+ let a = t(r);
6
+ return function(t) {
7
+ return /* @__PURE__ */ n(e, {
8
+ fallback: i,
9
+ children: /* @__PURE__ */ n(a, { ...t })
10
+ });
11
+ };
12
+ }
13
+ //#endregion
14
+ export { r as lazyLoad };
@@ -0,0 +1 @@
1
+ let e=require("react"),t=require("react/jsx-runtime");function n(n,r=(0,t.jsx)(`div`,{children:`Loading...`})){let i=(0,e.lazy)(n);return function(n){return(0,t.jsx)(e.Suspense,{fallback:r,children:(0,t.jsx)(i,{...n})})}}exports.lazyLoad=n;
@@ -0,0 +1,64 @@
1
+ import { Button as e } from "./index10.js";
2
+ import { DropdownMenu as t, DropdownMenuContent as n, DropdownMenuItem as r, DropdownMenuTrigger as i } from "./index78.js";
3
+ import { jsx as a, jsxs as o } from "react/jsx-runtime";
4
+ import { map as s } from "lodash-es";
5
+ //#region src/DataTable/components/DataTablePagination.tsx
6
+ var c = ({ table: c, tableState: l, pageSizeOptions: u, apiConfig: d }) => {
7
+ let f = l.pagination.pageIndex, p = l.pagination.pageSize, m = d.mode === "server" ? d.totalRows : c.getFilteredRowModel().rows.length, h = p > 0 ? Math.ceil(m / p) : 0;
8
+ return /* @__PURE__ */ o("div", {
9
+ className: "flex items-center justify-between gap-4 py-4",
10
+ children: [/* @__PURE__ */ o("div", {
11
+ className: "text-muted-foreground flex-1 text-sm",
12
+ children: [
13
+ c.getFilteredSelectedRowModel().rows.length,
14
+ " of ",
15
+ m,
16
+ " row(s) selected."
17
+ ]
18
+ }), /* @__PURE__ */ o("div", {
19
+ className: "flex items-center gap-2",
20
+ children: [
21
+ /* @__PURE__ */ o(t, { children: [/* @__PURE__ */ a(i, {
22
+ asChild: !0,
23
+ children: /* @__PURE__ */ o(e, {
24
+ variant: "outline",
25
+ size: "sm",
26
+ children: ["Rows: ", p]
27
+ })
28
+ }), /* @__PURE__ */ a(n, {
29
+ align: "end",
30
+ children: s(u, (e) => /* @__PURE__ */ a(r, {
31
+ onClick: () => c.setPageSize(e),
32
+ disabled: e === p,
33
+ children: e
34
+ }, String(e)))
35
+ })] }),
36
+ /* @__PURE__ */ a(e, {
37
+ variant: "outline",
38
+ size: "sm",
39
+ onClick: () => c.previousPage(),
40
+ disabled: !c.getCanPreviousPage(),
41
+ children: "Previous"
42
+ }),
43
+ /* @__PURE__ */ a(e, {
44
+ variant: "outline",
45
+ size: "sm",
46
+ onClick: () => c.nextPage(),
47
+ disabled: !c.getCanNextPage(),
48
+ children: "Next"
49
+ }),
50
+ /* @__PURE__ */ o("div", {
51
+ className: "text-muted-foreground px-2 text-sm",
52
+ children: [
53
+ "Page ",
54
+ f + 1,
55
+ " / ",
56
+ h === 0 ? 1 : h
57
+ ]
58
+ })
59
+ ]
60
+ })]
61
+ });
62
+ };
63
+ //#endregion
64
+ export { c as DataTablePagination };
@@ -0,0 +1 @@
1
+ const e=require("./index11.cjs"),t=require("./index79.cjs");let n=require("react/jsx-runtime"),r=require("lodash-es");var i=({table:i,tableState:a,pageSizeOptions:o,apiConfig:s})=>{let c=a.pagination.pageIndex,l=a.pagination.pageSize,u=s.mode===`server`?s.totalRows:i.getFilteredRowModel().rows.length,d=l>0?Math.ceil(u/l):0;return(0,n.jsxs)(`div`,{className:`flex items-center justify-between gap-4 py-4`,children:[(0,n.jsxs)(`div`,{className:`text-muted-foreground flex-1 text-sm`,children:[i.getFilteredSelectedRowModel().rows.length,` of `,u,` row(s) selected.`]}),(0,n.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,n.jsxs)(t.DropdownMenu,{children:[(0,n.jsx)(t.DropdownMenuTrigger,{asChild:!0,children:(0,n.jsxs)(e.Button,{variant:`outline`,size:`sm`,children:[`Rows: `,l]})}),(0,n.jsx)(t.DropdownMenuContent,{align:`end`,children:(0,r.map)(o,e=>(0,n.jsx)(t.DropdownMenuItem,{onClick:()=>i.setPageSize(e),disabled:e===l,children:e},String(e)))})]}),(0,n.jsx)(e.Button,{variant:`outline`,size:`sm`,onClick:()=>i.previousPage(),disabled:!i.getCanPreviousPage(),children:`Previous`}),(0,n.jsx)(e.Button,{variant:`outline`,size:`sm`,onClick:()=>i.nextPage(),disabled:!i.getCanNextPage(),children:`Next`}),(0,n.jsxs)(`div`,{className:`text-muted-foreground px-2 text-sm`,children:[`Page `,c+1,` / `,d===0?1:d]})]})]})};exports.DataTablePagination=i;
@@ -0,0 +1,23 @@
1
+ import { Table as e, TableBody as t, TableCell as n, TableHead as r, TableHeader as i, TableRow as a } from "./index116.js";
2
+ import { Fragment as o } from "react";
3
+ import { jsx as s, jsxs as c } from "react/jsx-runtime";
4
+ import { isEmpty as l, map as u } from "lodash-es";
5
+ import { flexRender as d } from "@tanstack/react-table";
6
+ //#region src/DataTable/components/DataTableTable.tsx
7
+ var f = ({ table: f, columnVisibility: p, expandedState: m, expandConfig: h, empty: g, columnsCount: _ }) => {
8
+ let v = f.getRowModel().rows;
9
+ return /* @__PURE__ */ c(e, { children: [/* @__PURE__ */ s(i, { children: u(f.getHeaderGroups(), (e) => /* @__PURE__ */ s(a, { children: u(e.headers, (e) => e.isPlaceholder || p[e.column.id] === !1 || e.column.columnDef.header === void 0 ? null : /* @__PURE__ */ s(r, { children: d(e.column.columnDef.header, e.getContext()) }, e.id)) }, e.id)) }), /* @__PURE__ */ s(t, { children: l(v) ? /* @__PURE__ */ s(a, { children: /* @__PURE__ */ s(n, {
10
+ colSpan: _,
11
+ className: "h-24 text-center",
12
+ children: g.render()
13
+ }) }) : u(v, (e) => /* @__PURE__ */ c(o, { children: [/* @__PURE__ */ s(a, {
14
+ "data-state": e.getIsSelected() ? "selected" : void 0,
15
+ children: u(e.getVisibleCells(), (e) => /* @__PURE__ */ s(n, { children: d(e.column.columnDef.cell, e.getContext()) }, e.id))
16
+ }), h.enabled && e.getIsExpanded() ? /* @__PURE__ */ s(a, { children: /* @__PURE__ */ s(n, {
17
+ colSpan: _,
18
+ className: "p-0",
19
+ children: h.renderSubComponent(e)
20
+ }) }) : null] }, e.id)) })] });
21
+ };
22
+ //#endregion
23
+ export { f as DataTableTable };
@@ -0,0 +1 @@
1
+ const e=require("./index117.cjs");let t=require("react"),n=require("react/jsx-runtime"),r=require("lodash-es"),i=require("@tanstack/react-table");var a=({table:a,columnVisibility:o,expandedState:s,expandConfig:c,empty:l,columnsCount:u})=>{let d=a.getRowModel().rows;return(0,n.jsxs)(e.Table,{children:[(0,n.jsx)(e.TableHeader,{children:(0,r.map)(a.getHeaderGroups(),t=>(0,n.jsx)(e.TableRow,{children:(0,r.map)(t.headers,t=>t.isPlaceholder||o[t.column.id]===!1||t.column.columnDef.header===void 0?null:(0,n.jsx)(e.TableHead,{children:(0,i.flexRender)(t.column.columnDef.header,t.getContext())},t.id))},t.id))}),(0,n.jsx)(e.TableBody,{children:(0,r.isEmpty)(d)?(0,n.jsx)(e.TableRow,{children:(0,n.jsx)(e.TableCell,{colSpan:u,className:`h-24 text-center`,children:l.render()})}):(0,r.map)(d,a=>(0,n.jsxs)(t.Fragment,{children:[(0,n.jsx)(e.TableRow,{"data-state":a.getIsSelected()?`selected`:void 0,children:(0,r.map)(a.getVisibleCells(),t=>(0,n.jsx)(e.TableCell,{children:(0,i.flexRender)(t.column.columnDef.cell,t.getContext())},t.id))}),c.enabled&&a.getIsExpanded()?(0,n.jsx)(e.TableRow,{children:(0,n.jsx)(e.TableCell,{colSpan:u,className:`p-0`,children:c.renderSubComponent(a)})}):null]},a.id))})]})};exports.DataTableTable=a;
@@ -0,0 +1,34 @@
1
+ import { Input as e } from "./index87.js";
2
+ import { useEffect as t, useRef as n } from "react";
3
+ import { jsx as r, jsxs as i } from "react/jsx-runtime";
4
+ import { debounce as a, isEmpty as o } from "lodash-es";
5
+ //#region src/DataTable/components/DataTableToolbar.tsx
6
+ var s = ({ table: s, placeholder: c, debounceMs: l, right: u }) => {
7
+ let d = s.getState().globalFilter, f = typeof d == "string" ? d : "", p = n(a((e) => {
8
+ s.setGlobalFilter(e);
9
+ }, l));
10
+ return t(() => (p.current = a((e) => {
11
+ s.setGlobalFilter(e);
12
+ }, l), () => {
13
+ p.current.cancel();
14
+ }), [s, l]), t(() => () => {
15
+ p.current.cancel();
16
+ }, []), /* @__PURE__ */ i("div", {
17
+ className: "flex items-center gap-2 py-4",
18
+ children: [/* @__PURE__ */ r(e, {
19
+ placeholder: c,
20
+ defaultValue: f,
21
+ onChange: (e) => {
22
+ let t = e.target.value;
23
+ if (o(t)) {
24
+ p.current("");
25
+ return;
26
+ }
27
+ p.current(t);
28
+ },
29
+ className: "max-w-sm"
30
+ }), u]
31
+ });
32
+ };
33
+ //#endregion
34
+ export { s as DataTableToolbar };
@@ -0,0 +1 @@
1
+ const e=require("./index88.cjs");let t=require("react"),n=require("react/jsx-runtime"),r=require("lodash-es");var i=({table:i,placeholder:a,debounceMs:o,right:s})=>{let c=i.getState().globalFilter,l=typeof c==`string`?c:``,u=(0,t.useRef)((0,r.debounce)(e=>{i.setGlobalFilter(e)},o));return(0,t.useEffect)(()=>(u.current=(0,r.debounce)(e=>{i.setGlobalFilter(e)},o),()=>{u.current.cancel()}),[i,o]),(0,t.useEffect)(()=>()=>{u.current.cancel()},[]),(0,n.jsxs)(`div`,{className:`flex items-center gap-2 py-4`,children:[(0,n.jsx)(e.Input,{placeholder:a,defaultValue:l,onChange:e=>{let t=e.target.value;if((0,r.isEmpty)(t)){u.current(``);return}u.current(t)},className:`max-w-sm`}),s]})};exports.DataTableToolbar=i;
@@ -0,0 +1,27 @@
1
+ import { Button as e } from "./index10.js";
2
+ import { DropdownMenu as t, DropdownMenuCheckboxItem as n, DropdownMenuContent as r, DropdownMenuTrigger as i } from "./index78.js";
3
+ import { ChevronDown as a } from "lucide-react";
4
+ import { jsx as o, jsxs as s } from "react/jsx-runtime";
5
+ import { map as c } from "lodash-es";
6
+ //#region src/DataTable/components/DataTableViewOptions.tsx
7
+ var l = ({ table: l, columnVisibility: u }) => {
8
+ let d = l.getAllColumns().filter((e) => e.getCanHide());
9
+ return /* @__PURE__ */ s(t, { children: [/* @__PURE__ */ o(i, {
10
+ asChild: !0,
11
+ children: /* @__PURE__ */ s(e, {
12
+ variant: "outline",
13
+ className: "ml-auto",
14
+ children: ["Columns ", /* @__PURE__ */ o(a, {})]
15
+ })
16
+ }), /* @__PURE__ */ o(r, {
17
+ align: "end",
18
+ children: c(d, (e) => /* @__PURE__ */ o(n, {
19
+ className: "capitalize",
20
+ checked: u[e.id] !== !1,
21
+ onCheckedChange: () => e.toggleVisibility(u[e.id] === !1),
22
+ children: e.id
23
+ }, e.id))
24
+ })] });
25
+ };
26
+ //#endregion
27
+ export { l as DataTableViewOptions };
package/dist/index13.cjs CHANGED
@@ -1 +1 @@
1
- const e=require("./index2.cjs"),t=require("./index4.cjs");let n=require("lucide-react"),r=require("react");r=e.__toESM(r,1);let i=require("react/jsx-runtime"),a=require("@radix-ui/react-dropdown-menu");a=e.__toESM(a,1);function o({...e}){return(0,i.jsx)(a.Root,{"data-slot":`dropdown-menu`,...e})}function s({...e}){return(0,i.jsx)(a.Portal,{"data-slot":`dropdown-menu-portal`,...e})}function c({...e}){return(0,i.jsx)(a.Trigger,{"data-slot":`dropdown-menu-trigger`,...e})}function l({className:e,sideOffset:n=4,...r}){return(0,i.jsx)(a.Portal,{children:(0,i.jsx)(a.Content,{"data-slot":`dropdown-menu-content`,sideOffset:n,className:t.cn(`bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 max-h-(--radix-dropdown-menu-content-available-height) min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md`,e),...r})})}function u({...e}){return(0,i.jsx)(a.Group,{"data-slot":`dropdown-menu-group`,...e})}function d({className:e,inset:n,variant:r=`default`,...o}){return(0,i.jsx)(a.Item,{"data-slot":`dropdown-menu-item`,"data-inset":n,"data-variant":r,className:t.cn(`focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,e),...o})}function f({className:e,children:r,checked:o,...s}){return(0,i.jsxs)(a.CheckboxItem,{"data-slot":`dropdown-menu-checkbox-item`,className:t.cn(`focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,e),checked:o,...s,children:[(0,i.jsx)(`span`,{className:`pointer-events-none absolute left-2 flex size-3.5 items-center justify-center`,children:(0,i.jsx)(a.ItemIndicator,{children:(0,i.jsx)(n.CheckIcon,{className:`size-4`})})}),r]})}function p({...e}){return(0,i.jsx)(a.RadioGroup,{"data-slot":`dropdown-menu-radio-group`,...e})}function m({className:e,children:r,...o}){return(0,i.jsxs)(a.RadioItem,{"data-slot":`dropdown-menu-radio-item`,className:t.cn(`focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,e),...o,children:[(0,i.jsx)(`span`,{className:`pointer-events-none absolute left-2 flex size-3.5 items-center justify-center`,children:(0,i.jsx)(a.ItemIndicator,{children:(0,i.jsx)(n.CircleIcon,{className:`size-2 fill-current`})})}),r]})}function h({className:e,inset:n,...r}){return(0,i.jsx)(a.Label,{"data-slot":`dropdown-menu-label`,"data-inset":n,className:t.cn(`px-2 py-1.5 text-sm font-medium data-[inset]:pl-8`,e),...r})}function g({className:e,...n}){return(0,i.jsx)(a.Separator,{"data-slot":`dropdown-menu-separator`,className:t.cn(`bg-border -mx-1 my-1 h-px`,e),...n})}function _({className:e,...n}){return(0,i.jsx)(`span`,{"data-slot":`dropdown-menu-shortcut`,className:t.cn(`text-muted-foreground ml-auto text-xs tracking-widest`,e),...n})}function v({...e}){return(0,i.jsx)(a.Sub,{"data-slot":`dropdown-menu-sub`,...e})}function y({className:e,inset:r,children:o,...s}){return(0,i.jsxs)(a.SubTrigger,{"data-slot":`dropdown-menu-sub-trigger`,"data-inset":r,className:t.cn(`focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,e),...s,children:[o,(0,i.jsx)(n.ChevronRightIcon,{className:`ml-auto size-4`})]})}function b({className:e,...n}){return(0,i.jsx)(a.SubContent,{"data-slot":`dropdown-menu-sub-content`,className:t.cn(`bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg`,e),...n})}exports.DropdownMenu=o,exports.DropdownMenuCheckboxItem=f,exports.DropdownMenuContent=l,exports.DropdownMenuGroup=u,exports.DropdownMenuItem=d,exports.DropdownMenuLabel=h,exports.DropdownMenuPortal=s,exports.DropdownMenuRadioGroup=p,exports.DropdownMenuRadioItem=m,exports.DropdownMenuSeparator=g,exports.DropdownMenuShortcut=_,exports.DropdownMenuSub=v,exports.DropdownMenuSubContent=b,exports.DropdownMenuSubTrigger=y,exports.DropdownMenuTrigger=c;
1
+ const e=require("./index2.cjs");let t=require("react");t=e.__toESM(t,1);let n=require("react/jsx-runtime"),r=require("@radix-ui/react-slot"),i=require("react-dom");i=e.__toESM(i,1);var a=Object.defineProperty,o=(e,t)=>a(e,`name`,{value:t,configurable:!0}),s=[`a`,`button`,`div`,`form`,`h2`,`h3`,`img`,`input`,`label`,`li`,`nav`,`ol`,`p`,`select`,`span`,`svg`,`ul`].reduce((e,i)=>{let a=(0,r.createSlot)(`Primitive.${i}`),o=t.forwardRef((e,t)=>{let{asChild:r,...o}=e,s=r?a:i;return typeof window<`u`&&(window[Symbol.for(`radix-ui`)]=!0),(0,n.jsx)(s,{...o,ref:t})});return o.displayName=`Primitive.${i}`,{...e,[i]:o}},{});function c(e,t){e&&i.flushSync(()=>e.dispatchEvent(t))}o(c,`dispatchDiscreteCustomEvent`),exports.Primitive=s,exports.dispatchDiscreteCustomEvent=c;
package/dist/index13.js CHANGED
@@ -1,14 +1,32 @@
1
- import { cn as e } from "./index3.js";
2
- import "react";
3
- import { jsx as t } from "react/jsx-runtime";
4
- import * as n from "@radix-ui/react-label";
5
- //#region src/ui/label.tsx
6
- function r({ className: r, ...i }) {
7
- return /* @__PURE__ */ t(n.Root, {
8
- "data-slot": "label",
9
- className: e("flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50", r),
10
- ...i
1
+ import { Primitive as e } from "./index12.js";
2
+ import * as t from "react";
3
+ import { jsx as n } from "react/jsx-runtime";
4
+ //#region ../../node_modules/.pnpm/@radix-ui+react-aspect-ratio@1.1.15_@types+react-dom@19.2.3_@types+react@19.2.17__@type_10aa7c245e36f921a290d66c57b9e119/node_modules/@radix-ui/react-aspect-ratio/dist/index.mjs
5
+ var r = Object.defineProperty, i = /* @__PURE__ */ t.forwardRef(/* @__PURE__ */ ((e, t) => r(e, "name", {
6
+ value: t,
7
+ configurable: !0
8
+ }))(function(t, r) {
9
+ let { ratio: i = 1 / 1, style: a, ...o } = t;
10
+ return /* @__PURE__ */ n("div", {
11
+ style: {
12
+ position: "relative",
13
+ width: "100%",
14
+ paddingBottom: `${100 / i}%`
15
+ },
16
+ "data-radix-aspect-ratio-wrapper": "",
17
+ children: /* @__PURE__ */ n(e.div, {
18
+ ...o,
19
+ ref: r,
20
+ style: {
21
+ ...a,
22
+ position: "absolute",
23
+ top: 0,
24
+ right: 0,
25
+ bottom: 0,
26
+ left: 0
27
+ }
28
+ })
11
29
  });
12
- }
30
+ }, "AspectRatio"));
13
31
  //#endregion
14
- export { r as Label };
32
+ export { i as Root };
@@ -0,0 +1 @@
1
+ const e=require("./index11.cjs"),t=require("./index79.cjs");let n=require("lucide-react"),r=require("react/jsx-runtime"),i=require("lodash-es");var a=({table:a,columnVisibility:o})=>{let s=a.getAllColumns().filter(e=>e.getCanHide());return(0,r.jsxs)(t.DropdownMenu,{children:[(0,r.jsx)(t.DropdownMenuTrigger,{asChild:!0,children:(0,r.jsxs)(e.Button,{variant:`outline`,className:`ml-auto`,children:[`Columns `,(0,r.jsx)(n.ChevronDown,{})]})}),(0,r.jsx)(t.DropdownMenuContent,{align:`end`,children:(0,i.map)(s,e=>(0,r.jsx)(t.DropdownMenuCheckboxItem,{className:`capitalize`,checked:o[e.id]!==!1,onCheckedChange:()=>e.toggleVisibility(o[e.id]===!1),children:e.id},e.id))})]})};exports.DataTableViewOptions=a;
@@ -0,0 +1,26 @@
1
+ import { jsx as e } from "react/jsx-runtime";
2
+ import { noop as t } from "lodash-es";
3
+ //#region src/DataTable/render/defaults.tsx
4
+ var n = {
5
+ placeholder: "Search...",
6
+ debounceMs: 300
7
+ }, r = { pageSizeOptions: [
8
+ 10,
9
+ 20,
10
+ 50,
11
+ 100
12
+ ] }, i = { render: () => /* @__PURE__ */ e("div", {
13
+ className: "text-muted-foreground py-8 text-center text-sm",
14
+ children: "No results."
15
+ }) }, a = {
16
+ mode: "client",
17
+ isFetching: !1,
18
+ totalRows: 0,
19
+ onQueryChange: t
20
+ }, o = {
21
+ enabled: !1,
22
+ thresholdPx: 200,
23
+ onEndReached: t
24
+ }, s = () => ({ getRowActions: () => [] });
25
+ //#endregion
26
+ export { a as DEFAULT_API, i as DEFAULT_EMPTY, o as DEFAULT_INFINITE_SCROLL, r as DEFAULT_PAGINATION, n as DEFAULT_SEARCH, s as createDefaultActions };
@@ -0,0 +1 @@
1
+ let e=require("react/jsx-runtime"),t=require("lodash-es");var n={placeholder:`Search...`,debounceMs:300},r={pageSizeOptions:[10,20,50,100]},i={render:()=>(0,e.jsx)(`div`,{className:`text-muted-foreground py-8 text-center text-sm`,children:`No results.`})},a={mode:`client`,isFetching:!1,totalRows:0,onQueryChange:t.noop},o={enabled:!1,thresholdPx:200,onEndReached:t.noop},s=()=>({getRowActions:()=>[]});exports.DEFAULT_API=a,exports.DEFAULT_EMPTY=i,exports.DEFAULT_INFINITE_SCROLL=o,exports.DEFAULT_PAGINATION=r,exports.DEFAULT_SEARCH=n,exports.createDefaultActions=s;