@vlrc-fe/components 2.7.0 → 2.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (476) hide show
  1. package/CHANGELOG.md +25 -0
  2. package/dist/ConfirmModal.d.ts +2 -3
  3. package/dist/ConfirmModal.d.ts.map +1 -1
  4. package/dist/DataTable/components/DataTableFacetedFilter.d.ts.map +1 -1
  5. package/dist/DataTable/components/DataTablePagination.d.ts.map +1 -1
  6. package/dist/Dropdown/Dropdown.d.ts.map +1 -1
  7. package/dist/Dropdown/types.d.ts +1 -1
  8. package/dist/Dropdown/types.d.ts.map +1 -1
  9. package/dist/Form/FormDatePicker/FormDatePicker.d.ts.map +1 -1
  10. package/dist/Form/FormDatePicker/MonthPickerPanel.d.ts +2 -1
  11. package/dist/Form/FormDatePicker/MonthPickerPanel.d.ts.map +1 -1
  12. package/dist/Form/FormDatePicker/RangeDatePicker.d.ts +7 -1
  13. package/dist/Form/FormDatePicker/RangeDatePicker.d.ts.map +1 -1
  14. package/dist/Form/FormDatePicker/SingleDatePicker.d.ts +5 -1
  15. package/dist/Form/FormDatePicker/SingleDatePicker.d.ts.map +1 -1
  16. package/dist/Form/FormDatePicker/TimeInput.d.ts.map +1 -1
  17. package/dist/Form/FormDatePicker/TimePicker.d.ts.map +1 -1
  18. package/dist/Form/FormDatePicker/types.d.ts +5 -0
  19. package/dist/Form/FormDatePicker/types.d.ts.map +1 -1
  20. package/dist/Form/FormFileUpload/index.d.ts.map +1 -1
  21. package/dist/Form/FormNumberInput/useFormNumberInput.d.ts +2 -2
  22. package/dist/Form/FormNumberInput/useFormNumberInput.d.ts.map +1 -1
  23. package/dist/Form/FormSelect/FormSelect.d.ts.map +1 -1
  24. package/dist/Form/FormSelect/types.d.ts +1 -1
  25. package/dist/Form/FormSelect/types.d.ts.map +1 -1
  26. package/dist/Form/FormSelect/useFormSelect.d.ts +1 -1
  27. package/dist/Form/FormSelect/useFormSelect.d.ts.map +1 -1
  28. package/dist/MultiSelect/MultiSelect.d.ts +3 -31
  29. package/dist/MultiSelect/MultiSelect.d.ts.map +1 -1
  30. package/dist/MultiSelect/renderers.d.ts.map +1 -1
  31. package/dist/MultiSelect/type.d.ts +1 -0
  32. package/dist/MultiSelect/type.d.ts.map +1 -1
  33. package/dist/MultiSelect/useMultiSelect.d.ts.map +1 -1
  34. package/dist/Select/BaseSelect.d.ts.map +1 -1
  35. package/dist/Select/MultiSelectTags.d.ts.map +1 -1
  36. package/dist/Select/type.d.ts +1 -1
  37. package/dist/Select/type.d.ts.map +1 -1
  38. package/dist/Typography/Code.d.ts.map +1 -1
  39. package/dist/Typography/Link.d.ts.map +1 -1
  40. package/dist/Typography/Paragraph.d.ts.map +1 -1
  41. package/dist/Typography/Text.d.ts.map +1 -1
  42. package/dist/Typography/Title.d.ts.map +1 -1
  43. package/dist/Typography/types.d.ts +37 -1
  44. package/dist/Typography/types.d.ts.map +1 -1
  45. package/dist/Typography/utils.d.ts +3 -2
  46. package/dist/Typography/utils.d.ts.map +1 -1
  47. package/dist/assets/stylex.css +36 -24
  48. package/dist/index.cjs +1 -1
  49. package/dist/index.js +108 -108
  50. package/dist/index10.cjs +1 -1
  51. package/dist/index10.js +18 -55
  52. package/dist/index101.cjs +1 -1
  53. package/dist/index101.js +89 -89
  54. package/dist/index102.cjs +1 -1
  55. package/dist/index102.js +29 -29
  56. package/dist/index103.cjs +1 -1
  57. package/dist/index103.js +128 -124
  58. package/dist/index104.cjs +1 -1
  59. package/dist/index104.js +16 -16
  60. package/dist/index106.cjs +1 -1
  61. package/dist/index106.js +2 -2
  62. package/dist/index107.cjs +1 -1
  63. package/dist/index107.js +114 -117
  64. package/dist/index108.cjs +1 -1
  65. package/dist/index108.js +95 -92
  66. package/dist/index109.cjs +1 -1
  67. package/dist/index109.js +41 -41
  68. package/dist/index11.cjs +1 -1
  69. package/dist/index11.js +36 -164
  70. package/dist/index110.cjs +1 -1
  71. package/dist/index110.js +1 -1
  72. package/dist/index111.cjs +1 -1
  73. package/dist/index111.js +1 -1
  74. package/dist/index112.cjs +1 -1
  75. package/dist/index112.js +128 -120
  76. package/dist/index114.cjs +1 -1
  77. package/dist/index114.js +151 -151
  78. package/dist/index116.cjs +1 -1
  79. package/dist/index116.js +96 -91
  80. package/dist/index117.cjs +1 -1
  81. package/dist/index117.js +18 -18
  82. package/dist/index118.cjs +1 -1
  83. package/dist/index118.js +2 -2
  84. package/dist/index119.cjs +1 -1
  85. package/dist/index119.js +15 -15
  86. package/dist/index12.cjs +1 -1
  87. package/dist/index12.js +147 -103
  88. package/dist/index120.cjs +1 -1
  89. package/dist/index120.js +10 -10
  90. package/dist/index121.cjs +1 -1
  91. package/dist/index121.js +31 -31
  92. package/dist/index122.cjs +1 -1
  93. package/dist/index122.js +3 -3
  94. package/dist/index123.cjs +1 -1
  95. package/dist/index123.js +2 -2
  96. package/dist/index124.cjs +1 -1
  97. package/dist/index124.js +53 -49
  98. package/dist/index126.cjs +1 -1
  99. package/dist/index126.js +35 -38
  100. package/dist/index127.cjs +1 -1
  101. package/dist/index127.js +114 -107
  102. package/dist/index128.cjs +1 -1
  103. package/dist/index128.js +8 -8
  104. package/dist/index129.cjs +1 -1
  105. package/dist/index129.js +53 -53
  106. package/dist/index13.cjs +1 -1
  107. package/dist/index13.js +130 -102
  108. package/dist/index130.cjs +1 -1
  109. package/dist/index130.js +134 -130
  110. package/dist/index132.cjs +1 -1
  111. package/dist/index132.js +7 -7
  112. package/dist/index133.cjs +1 -1
  113. package/dist/index133.js +95 -95
  114. package/dist/index134.cjs +1 -1
  115. package/dist/index134.js +2 -2
  116. package/dist/index135.cjs +1 -1
  117. package/dist/index135.js +113 -99
  118. package/dist/index136.cjs +1 -1
  119. package/dist/index136.js +8 -8
  120. package/dist/index137.cjs +1 -1
  121. package/dist/index137.js +16 -16
  122. package/dist/index138.cjs +1 -1
  123. package/dist/index138.js +20 -20
  124. package/dist/index14.cjs +1 -1
  125. package/dist/index14.js +154 -80
  126. package/dist/index140.cjs +1 -1
  127. package/dist/index140.js +2 -2
  128. package/dist/index141.cjs +1 -1
  129. package/dist/index141.js +24 -24
  130. package/dist/index142.cjs +1 -1
  131. package/dist/index142.js +2 -2
  132. package/dist/index143.cjs +1 -1
  133. package/dist/index143.js +15 -15
  134. package/dist/index144.cjs +1 -1
  135. package/dist/index144.js +3 -3
  136. package/dist/index145.cjs +1 -1
  137. package/dist/index145.js +2 -2
  138. package/dist/index146.cjs +1 -1
  139. package/dist/index146.js +1 -1
  140. package/dist/index147.cjs +1 -1
  141. package/dist/index147.js +88 -88
  142. package/dist/index149.cjs +1 -1
  143. package/dist/index149.js +64 -64
  144. package/dist/index15.cjs +1 -1
  145. package/dist/index15.js +116 -63
  146. package/dist/index150.cjs +1 -1
  147. package/dist/index150.js +9 -9
  148. package/dist/index152.cjs +1 -1
  149. package/dist/index152.js +1 -1
  150. package/dist/index153.cjs +1 -1
  151. package/dist/index153.js +41 -41
  152. package/dist/index154.cjs +1 -1
  153. package/dist/index154.js +73 -73
  154. package/dist/index155.cjs +1 -1
  155. package/dist/index155.js +34 -34
  156. package/dist/index156.cjs +1 -1
  157. package/dist/index156.js +8 -8
  158. package/dist/index157.cjs +1 -1
  159. package/dist/index157.js +1 -1
  160. package/dist/index158.cjs +1 -1
  161. package/dist/index158.js +30 -30
  162. package/dist/index159.cjs +1 -1
  163. package/dist/index159.js +21 -21
  164. package/dist/index16.cjs +1 -1
  165. package/dist/index16.js +60 -91
  166. package/dist/index160.cjs +1 -1
  167. package/dist/index160.js +59 -59
  168. package/dist/index161.cjs +1 -1
  169. package/dist/index161.js +2 -2
  170. package/dist/index162.cjs +1 -1
  171. package/dist/index162.js +50 -50
  172. package/dist/index163.cjs +1 -1
  173. package/dist/index163.js +11 -11
  174. package/dist/index164.cjs +1 -1
  175. package/dist/index164.js +1 -1
  176. package/dist/index165.cjs +1 -1
  177. package/dist/index165.js +33 -33
  178. package/dist/index166.cjs +1 -1
  179. package/dist/index166.js +11 -11
  180. package/dist/index167.cjs +1 -1
  181. package/dist/index167.js +2 -2
  182. package/dist/index168.cjs +1 -1
  183. package/dist/index168.js +7 -7
  184. package/dist/index169.cjs +1 -1
  185. package/dist/index169.js +74 -65
  186. package/dist/index17.cjs +1 -1
  187. package/dist/index17.js +122 -15
  188. package/dist/index170.cjs +1 -1
  189. package/dist/index170.js +9 -9
  190. package/dist/index171.cjs +1 -1
  191. package/dist/index171.js +7 -7
  192. package/dist/index172.cjs +1 -1
  193. package/dist/index172.js +12 -12
  194. package/dist/index174.cjs +1 -1
  195. package/dist/index174.js +15 -15
  196. package/dist/index175.cjs +1 -1
  197. package/dist/index175.js +13 -13
  198. package/dist/index176.cjs +1 -1
  199. package/dist/index176.js +2 -2
  200. package/dist/index177.cjs +1 -1
  201. package/dist/index177.js +140 -115
  202. package/dist/index178.cjs +1 -1
  203. package/dist/index178.js +4 -4
  204. package/dist/index179.cjs +1 -1
  205. package/dist/index179.js +47 -47
  206. package/dist/index18.cjs +1 -1
  207. package/dist/index18.js +15 -268
  208. package/dist/index181.cjs +1 -1
  209. package/dist/index181.js +36 -25
  210. package/dist/index183.cjs +1 -1
  211. package/dist/index183.js +4 -4
  212. package/dist/index185.cjs +1 -1
  213. package/dist/index185.js +5 -8
  214. package/dist/index186.cjs +1 -1
  215. package/dist/index186.js +5 -15
  216. package/dist/index187.cjs +1 -1
  217. package/dist/index187.js +5 -20
  218. package/dist/index188.cjs +1 -1
  219. package/dist/index188.js +5 -16
  220. package/dist/index189.cjs +1 -1
  221. package/dist/index189.js +8 -5
  222. package/dist/index19.cjs +1 -1
  223. package/dist/index19.js +11 -281
  224. package/dist/index190.cjs +1 -1
  225. package/dist/index190.js +7 -4
  226. package/dist/index191.cjs +1 -1
  227. package/dist/index191.js +12 -6
  228. package/dist/index192.cjs +1 -1
  229. package/dist/index192.js +6 -5
  230. package/dist/index193.cjs +1 -1
  231. package/dist/index193.js +6 -5
  232. package/dist/index194.cjs +1 -1
  233. package/dist/index194.js +6 -7
  234. package/dist/index195.cjs +1 -1
  235. package/dist/index195.js +10 -68
  236. package/dist/index196.cjs +1 -1
  237. package/dist/index196.js +9 -10
  238. package/dist/index197.cjs +1 -1
  239. package/dist/index197.js +5 -201
  240. package/dist/index198.cjs +1 -1
  241. package/dist/index198.js +7 -123
  242. package/dist/index199.cjs +1 -1
  243. package/dist/index199.js +7 -31
  244. package/dist/index20.cjs +1 -1
  245. package/dist/index20.js +26 -11
  246. package/dist/index200.cjs +1 -1
  247. package/dist/index200.js +66 -17
  248. package/dist/index201.cjs +1 -1
  249. package/dist/index201.js +8 -68
  250. package/dist/index202.cjs +1 -1
  251. package/dist/index202.js +13 -13
  252. package/dist/index203.cjs +1 -1
  253. package/dist/index203.js +6 -6
  254. package/dist/index204.cjs +1 -1
  255. package/dist/index204.js +15 -278
  256. package/dist/index205.cjs +1 -1
  257. package/dist/index205.js +171 -126
  258. package/dist/index206.cjs +1 -1
  259. package/dist/index206.js +21 -19
  260. package/dist/index207.cjs +1 -1
  261. package/dist/index207.js +16 -8
  262. package/dist/index208.cjs +1 -1
  263. package/dist/index208.js +123 -13
  264. package/dist/index209.cjs +1 -1
  265. package/dist/index209.js +19 -7
  266. package/dist/index21.cjs +1 -1
  267. package/dist/index21.js +29 -26
  268. package/dist/index210.cjs +1 -1
  269. package/dist/index210.js +8 -6
  270. package/dist/index211.cjs +1 -1
  271. package/dist/index211.js +9 -9
  272. package/dist/index212.cjs +1 -1
  273. package/dist/index212.js +13 -8
  274. package/dist/index213.cjs +1 -1
  275. package/dist/index213.js +9 -4
  276. package/dist/index214.cjs +1 -1
  277. package/dist/index214.js +9 -6
  278. package/dist/index215.cjs +1 -1
  279. package/dist/index215.js +4 -6
  280. package/dist/index216.cjs +1 -1
  281. package/dist/index216.js +42 -9
  282. package/dist/index217.cjs +1 -1
  283. package/dist/index217.js +386 -8
  284. package/dist/index218.cjs +1 -1
  285. package/dist/index218.js +37 -14
  286. package/dist/index219.cjs +1 -1
  287. package/dist/index219.js +22 -10
  288. package/dist/index22.cjs +1 -1
  289. package/dist/index22.js +367 -59
  290. package/dist/index220.cjs +1 -1
  291. package/dist/index220.js +57 -9
  292. package/dist/index221.cjs +1 -1
  293. package/dist/index221.js +39 -4
  294. package/dist/index222.cjs +1 -1
  295. package/dist/index222.js +116 -35
  296. package/dist/index223.cjs +1 -1
  297. package/dist/index223.js +85 -387
  298. package/dist/index224.cjs +1 -1
  299. package/dist/index224.js +87 -35
  300. package/dist/index225.cjs +1 -1
  301. package/dist/index225.js +116 -18
  302. package/dist/index226.cjs +1 -1
  303. package/dist/index226.js +97 -55
  304. package/dist/index227.cjs +1 -1
  305. package/dist/index227.js +154 -37
  306. package/dist/index228.cjs +1 -1
  307. package/dist/index228.js +76 -121
  308. package/dist/index229.cjs +9 -1
  309. package/dist/index229.js +588 -77
  310. package/dist/index23.cjs +1 -1
  311. package/dist/index23.js +212 -29
  312. package/dist/index230.cjs +1 -1
  313. package/dist/index230.js +64 -68
  314. package/dist/index231.cjs +1 -1
  315. package/dist/index231.js +42 -115
  316. package/dist/index232.cjs +1 -1
  317. package/dist/index232.js +65 -98
  318. package/dist/index233.cjs +1 -1
  319. package/dist/index233.js +48 -149
  320. package/dist/index234.cjs +1 -1
  321. package/dist/index234.js +98 -68
  322. package/dist/index235.cjs +1 -9
  323. package/dist/index235.js +214 -580
  324. package/dist/index236.cjs +1 -1
  325. package/dist/index236.js +29 -66
  326. package/dist/index237.cjs +1 -1
  327. package/dist/index237.js +23 -40
  328. package/dist/index238.cjs +1 -1
  329. package/dist/index238.js +55 -59
  330. package/dist/index239.cjs +1 -1
  331. package/dist/index239.js +419 -46
  332. package/dist/index24.cjs +1 -1
  333. package/dist/index24.js +200 -312
  334. package/dist/index240.cjs +1 -1
  335. package/dist/index240.js +30 -97
  336. package/dist/index241.cjs +1 -1
  337. package/dist/index241.js +205 -196
  338. package/dist/index25.cjs +1 -1
  339. package/dist/index25.js +228 -124
  340. package/dist/index26.cjs +1 -1
  341. package/dist/index26.js +161 -86
  342. package/dist/index27.cjs +1 -1
  343. package/dist/index27.js +89 -143
  344. package/dist/index28.cjs +1 -1
  345. package/dist/index28.js +140 -76
  346. package/dist/index29.cjs +1 -1
  347. package/dist/index29.js +92 -84
  348. package/dist/index30.cjs +1 -1
  349. package/dist/index30.js +84 -26
  350. package/dist/index31.cjs +1 -1
  351. package/dist/index31.js +26 -35
  352. package/dist/index32.cjs +1 -1
  353. package/dist/index32.js +39 -86
  354. package/dist/index33.cjs +1 -1
  355. package/dist/index33.js +84 -231
  356. package/dist/index34.cjs +1 -1
  357. package/dist/index34.js +234 -44
  358. package/dist/index35.cjs +1 -1
  359. package/dist/index35.js +39 -26
  360. package/dist/index36.cjs +1 -1
  361. package/dist/index36.js +30 -14
  362. package/dist/index37.cjs +1 -1
  363. package/dist/index37.js +14 -13
  364. package/dist/index38.cjs +1 -1
  365. package/dist/index38.js +13 -3
  366. package/dist/index39.cjs +1 -1
  367. package/dist/index39.js +4 -87
  368. package/dist/index40.cjs +1 -1
  369. package/dist/index40.js +83 -174
  370. package/dist/index41.cjs +1 -1
  371. package/dist/index41.js +66 -142
  372. package/dist/index42.cjs +1 -1
  373. package/dist/index42.js +217 -62
  374. package/dist/index43.cjs +1 -1
  375. package/dist/index43.js +135 -47
  376. package/dist/index44.cjs +1 -1
  377. package/dist/index44.js +47 -260
  378. package/dist/index45.cjs +1 -1
  379. package/dist/index45.js +273 -8
  380. package/dist/index46.cjs +1 -1
  381. package/dist/index46.js +7 -4
  382. package/dist/index47.cjs +1 -1
  383. package/dist/index47.js +4 -503
  384. package/dist/index48.cjs +1 -1
  385. package/dist/index48.js +472 -177
  386. package/dist/index49.cjs +1 -1
  387. package/dist/index49.js +205 -23
  388. package/dist/index50.cjs +1 -1
  389. package/dist/index50.js +21 -1008
  390. package/dist/index51.cjs +1 -1
  391. package/dist/index51.js +1014 -21
  392. package/dist/index52.cjs +1 -1
  393. package/dist/index52.js +22 -207
  394. package/dist/index53.cjs +1 -1
  395. package/dist/index53.js +181 -130
  396. package/dist/index54.cjs +1 -1
  397. package/dist/index54.js +132 -99
  398. package/dist/index55.cjs +1 -1
  399. package/dist/index55.js +123 -19
  400. package/dist/index56.cjs +1 -1
  401. package/dist/index56.js +17 -79
  402. package/dist/index57.cjs +1 -1
  403. package/dist/index57.js +75 -90
  404. package/dist/index58.cjs +1 -1
  405. package/dist/index58.js +91 -9
  406. package/dist/index59.cjs +1 -1
  407. package/dist/index59.js +12 -91
  408. package/dist/index6.cjs +1 -1
  409. package/dist/index6.js +62 -5
  410. package/dist/index60.cjs +1 -1
  411. package/dist/index60.js +92 -31
  412. package/dist/index61.cjs +1 -1
  413. package/dist/index61.js +29 -208
  414. package/dist/index62.cjs +1 -1
  415. package/dist/index62.js +123 -99
  416. package/dist/index63.cjs +1 -1
  417. package/dist/index63.js +17 -17
  418. package/dist/index64.cjs +1 -1
  419. package/dist/index64.js +28 -28
  420. package/dist/index65.cjs +1 -1
  421. package/dist/index65.js +30 -30
  422. package/dist/index67.cjs +1 -1
  423. package/dist/index67.js +11 -11
  424. package/dist/index7.cjs +1 -1
  425. package/dist/index7.js +22 -28
  426. package/dist/index73.cjs +1 -1
  427. package/dist/index73.js +1 -1
  428. package/dist/index74.cjs +1 -1
  429. package/dist/index74.js +20 -20
  430. package/dist/index75.cjs +1 -1
  431. package/dist/index75.js +7 -7
  432. package/dist/index77.cjs +1 -1
  433. package/dist/index77.js +28 -28
  434. package/dist/index8.cjs +1 -1
  435. package/dist/index8.js +28 -61
  436. package/dist/index9.cjs +1 -1
  437. package/dist/index9.js +60 -15
  438. package/dist/ui/accordion.d.ts.map +1 -1
  439. package/dist/ui/avatar.d.ts.map +1 -1
  440. package/dist/ui/breadcrumb.d.ts.map +1 -1
  441. package/dist/ui/button.d.ts.map +1 -1
  442. package/dist/ui/calendar.d.ts +1 -1
  443. package/dist/ui/calendar.d.ts.map +1 -1
  444. package/dist/ui/command.d.ts +1 -1
  445. package/dist/ui/command.d.ts.map +1 -1
  446. package/dist/ui/context-menu.d.ts.map +1 -1
  447. package/dist/ui/dropdown-menu.d.ts.map +1 -1
  448. package/dist/ui/editable.d.ts.map +1 -1
  449. package/dist/ui/field.d.ts.map +1 -1
  450. package/dist/ui/form.d.ts.map +1 -1
  451. package/dist/ui/input-group.d.ts.map +1 -1
  452. package/dist/ui/input-otp.d.ts +1 -1
  453. package/dist/ui/input-otp.d.ts.map +1 -1
  454. package/dist/ui/item.d.ts.map +1 -1
  455. package/dist/ui/menubar.d.ts.map +1 -1
  456. package/dist/ui/pagination.d.ts +3 -1
  457. package/dist/ui/pagination.d.ts.map +1 -1
  458. package/dist/ui/toggle-group.d.ts +1 -1
  459. package/dist/ui/toggle-group.d.ts.map +1 -1
  460. package/dist/ui/toggle.d.ts +1 -1
  461. package/dist/ui/toggle.d.ts.map +1 -1
  462. package/dist/ui/useBreakpoint.d.ts +0 -4
  463. package/dist/ui/useBreakpoint.d.ts.map +1 -1
  464. package/package.json +1 -1
  465. package/dist/index242.cjs +0 -1
  466. package/dist/index242.js +0 -25
  467. package/dist/index243.cjs +0 -1
  468. package/dist/index243.js +0 -26
  469. package/dist/index244.cjs +0 -1
  470. package/dist/index244.js +0 -63
  471. package/dist/index245.cjs +0 -1
  472. package/dist/index245.js +0 -422
  473. package/dist/index246.cjs +0 -1
  474. package/dist/index246.js +0 -25
  475. package/dist/index247.cjs +0 -1
  476. package/dist/index247.js +0 -209
package/dist/index54.js CHANGED
@@ -1,124 +1,157 @@
1
- import { Text as e } from "./index13.js";
2
- import * as t from "react";
3
- import * as n from "@stylexjs/stylex";
4
- import { jsx as r, jsxs as i } from "react/jsx-runtime";
5
- // src/ui/circular-progress.tsx
1
+ import * as e from "@stylexjs/stylex";
2
+ import { CheckIcon as t } from "lucide-react";
3
+ import { jsx as n } from "react/jsx-runtime";
4
+ import * as r from "react";
5
+ import * as i from "@radix-ui/react-checkbox";
6
+ // src/ui/checkbox.tsx
6
7
  var a = {
7
8
  root: {
8
- kVAEAm: "x1n2onr6",
9
+ kmuXW: "x2lah0s",
10
+ kMzoRj: "xmkeg23",
11
+ ksu8eU: "x1y0btm7",
12
+ kVAM5u: "xsyin8q",
13
+ kWkggS: "x1mlyrtw",
14
+ kGVxlE: "x1dsmnui",
15
+ k1ekBW: "x18k87a7",
16
+ kIyJzY: "xx6bhzk",
17
+ kI3sdo: "x1a2a7pz",
9
18
  k1xSpc: "x3nfvp2",
10
19
  kGNEyG: "x6s0dn4",
11
20
  kjj79g: "xl56j7k",
12
- kXLuUW: "xxymvpz",
21
+ kkrTdU: "x1ypdohk",
22
+ kmVPX3: "x1717udv",
23
+ kB7OPa: "x9f619",
24
+ kOJeXU: "x156qtes",
25
+ kEtg5x: "x1ippke1",
26
+ kYPGJ8: "x1s07b3s",
27
+ kWCcOm: "xijokvz",
13
28
  $$css: !0
14
29
  },
15
- indicator: {
16
- kU5bRw: "x1owpc8m",
17
- k1ekBW: "xxnu56j",
18
- kIyJzY: "x1d8287x",
19
- kAMwcw: "xz4gly6",
30
+ rootChecked: {
31
+ kWkggS: "x1j7ufkg",
32
+ kVAM5u: "x1khvrlk",
33
+ kMwMTN: "xstwp1q",
20
34
  $$css: !0
21
35
  },
22
- colorDefault: {
23
- kjVXCG: "xodl5ec",
36
+ sizeXxs: {
37
+ kzqmXN: "x1jw3ynk",
38
+ kZKoxP: "xvle69y",
39
+ kaIpWk: "x10a6c4v",
24
40
  $$css: !0
25
41
  },
26
- colorSecondary: {
27
- kjVXCG: "x1vgo946",
42
+ sizeXs: {
43
+ kzqmXN: "x1xvt488",
44
+ kZKoxP: "xf08kfj",
45
+ kaIpWk: "x10a6c4v",
28
46
  $$css: !0
29
47
  },
30
- colorDestructive: {
31
- kjVXCG: "x1whg6ty",
48
+ sizeSm: {
49
+ kzqmXN: "xcdlrvm",
50
+ kZKoxP: "x1l36t39",
51
+ kaIpWk: "x16eypsj",
32
52
  $$css: !0
33
53
  },
34
- colorWarning: {
35
- kjVXCG: "x163v6lp",
54
+ sizeMd: {
55
+ kzqmXN: "xsk17dz",
56
+ kZKoxP: "xaylbqo",
57
+ kaIpWk: "x16eypsj",
36
58
  $$css: !0
37
59
  },
38
- colorSuccess: {
39
- kjVXCG: "x1uof0aa",
60
+ sizeLg: {
61
+ kzqmXN: "xwqq7k2",
62
+ kZKoxP: "xmll18r",
63
+ kaIpWk: "xddr76m",
40
64
  $$css: !0
41
- }
42
- }, o = {
43
- xs: {
44
- size: 24,
45
- strokeWidth: 2.5,
46
- textSize: "xs"
47
65
  },
48
- sm: {
49
- size: 36,
50
- strokeWidth: 3,
51
- textSize: "xs"
66
+ sizeXl: {
67
+ kzqmXN: "xp8d6y2",
68
+ kZKoxP: "xam5rvr",
69
+ kaIpWk: "x6i6fhv",
70
+ $$css: !0
52
71
  },
53
- md: {
54
- size: 48,
55
- strokeWidth: 4,
56
- textSize: "sm"
72
+ sizeXxl: {
73
+ kzqmXN: "xh29eag",
74
+ kZKoxP: "xb8l8e1",
75
+ kaIpWk: "xjzjd16",
76
+ $$css: !0
57
77
  },
58
- lg: {
59
- size: 64,
60
- strokeWidth: 5,
61
- textSize: "md"
78
+ iconXxs: {
79
+ kzqmXN: "x7gqxlp",
80
+ kZKoxP: "xpurx6q",
81
+ $$css: !0
82
+ },
83
+ iconXs: {
84
+ kzqmXN: "x1tmz82h",
85
+ kZKoxP: "x1nnp5p7",
86
+ $$css: !0
87
+ },
88
+ iconSm: {
89
+ kzqmXN: "x10rziqa",
90
+ kZKoxP: "x75iezw",
91
+ $$css: !0
62
92
  },
63
- xl: {
64
- size: 96,
65
- strokeWidth: 6,
66
- textSize: "lg"
93
+ iconMd: {
94
+ kzqmXN: "x15xktyq",
95
+ kZKoxP: "x25yk9b",
96
+ $$css: !0
97
+ },
98
+ iconLg: {
99
+ kzqmXN: "x51uzbs",
100
+ kZKoxP: "x1fz7b6p",
101
+ $$css: !0
102
+ },
103
+ iconXl: {
104
+ kzqmXN: "xwqq7k2",
105
+ kZKoxP: "xmll18r",
106
+ $$css: !0
107
+ },
108
+ iconXxl: {
109
+ kzqmXN: "xp8d6y2",
110
+ kZKoxP: "xam5rvr",
111
+ $$css: !0
67
112
  }
68
- }, s = t.forwardRef(({ value: t, min: s = 0, max: c = 100, size: l = "md", strokeWidth: u, variant: d = "primary", indeterminate: f, showValue: p = !1, formatValue: m, children: h, sx: g, className: _, style: v, "aria-label": y = "Circular progress", ...b }, x) => {
69
- let S = f || t === void 0 || Number.isNaN(t), C = typeof l == "string" ? o[l] : void 0, w = typeof l == "number" ? l : C?.size ?? 48, T = u ?? C?.strokeWidth ?? 4, E = Math.max(0, (w - T) / 2), D = 2 * Math.PI * E, O = Math.min(Math.max(t ?? 0, s), c), k = Math.round((O - s) / (c - s || 1) * 100), A = S ? D * .75 : D - D * k / 100, j = d === "secondary" ? a.colorSecondary : d === "destructive" ? a.colorDestructive : d === "warning" ? a.colorWarning : d === "success" ? a.colorSuccess : a.colorDefault, M = n.props(a.root, g), N = m ? m(O) : `${k}%`;
70
- return /* @__PURE__ */ i("div", {
71
- ref: x,
72
- role: "progressbar",
73
- "aria-valuenow": S ? void 0 : O,
74
- "aria-valuemin": s,
75
- "aria-valuemax": c,
76
- "aria-label": y,
77
- "data-slot": "circular-progress",
78
- "data-state": S ? "indeterminate" : "determinate",
79
- ...M,
80
- className: _ ? `${M.className || ""} ${_}`.trim() : M.className,
81
- style: {
82
- width: w,
83
- height: w,
84
- ...v
85
- },
86
- ...b,
87
- children: [/* @__PURE__ */ i("svg", {
88
- viewBox: `0 0 ${w} ${w}`,
89
- width: w,
90
- height: w,
91
- ...{
92
- 0: { className: "x1lliihq x9tu13d" },
93
- 1: { className: "x1lliihq x9tu13d x1ka1v4i x1sbju2s x1esw782 xa4qsjk" }
94
- }[!!S | 0],
95
- children: [/* @__PURE__ */ r("circle", {
96
- cx: w / 2,
97
- cy: w / 2,
98
- r: E,
99
- fill: "none",
100
- strokeWidth: T,
101
- className: "xdeg11c"
102
- }), /* @__PURE__ */ r("circle", {
103
- cx: w / 2,
104
- cy: w / 2,
105
- r: E,
106
- fill: "none",
107
- strokeWidth: T,
108
- strokeDasharray: D,
109
- strokeDashoffset: A,
110
- ...n.props(a.indicator, j)
111
- })]
112
- }), (p || h) && /* @__PURE__ */ r("div", {
113
- className: "x10l6tqk xwa60dl x1nrll8i x11lhmoz x78zum5 x6s0dn4 xl56j7k x47corl",
114
- children: h || /* @__PURE__ */ r(e, {
115
- weight: "medium",
116
- size: C?.textSize ?? "sm",
117
- "data-slot": "circular-progress-value",
118
- children: N
113
+ }, o = {
114
+ xxs: a.sizeXxs,
115
+ xs: a.sizeXs,
116
+ sm: a.sizeSm,
117
+ md: a.sizeMd,
118
+ lg: a.sizeLg,
119
+ xl: a.sizeXl,
120
+ xxl: a.sizeXxl
121
+ }, s = {
122
+ xxs: a.iconXxs,
123
+ xs: a.iconXs,
124
+ sm: a.iconSm,
125
+ md: a.iconMd,
126
+ lg: a.iconLg,
127
+ xl: a.iconXl,
128
+ xxl: a.iconXxl
129
+ };
130
+ function c({ className: c, size: l = "md", checked: u, defaultChecked: d = !1, onCheckedChange: f, disabled: p, sx: m, ...h }) {
131
+ let g = u !== void 0, [_, v] = r.useState(d), y = g ? !!u : _;
132
+ r.useEffect(() => {
133
+ !g && d !== void 0 && v(d);
134
+ }, [d, g]);
135
+ let b = (e) => {
136
+ g || v(e === !0), f?.(e);
137
+ }, x = o[l] ?? a.sizeMd, S = s[l] ?? a.iconMd, C = e.props(a.root, x, y && a.rootChecked, m);
138
+ return /* @__PURE__ */ n(i.Root, {
139
+ "data-slot": "checkbox",
140
+ "data-size": l,
141
+ checked: y,
142
+ onCheckedChange: b,
143
+ disabled: p,
144
+ ...C,
145
+ className: c ? `${C.className || ""} ${c}`.trim() : C.className,
146
+ ...h,
147
+ children: /* @__PURE__ */ n(i.Indicator, {
148
+ "data-slot": "checkbox-indicator",
149
+ className: "x78zum5 x6s0dn4 xl56j7k xstwp1q xh8yej3 x5yr21d x47corl",
150
+ children: /* @__PURE__ */ n(t, {
151
+ ...e.props(S),
152
+ strokeWidth: 3
119
153
  })
120
- })]
154
+ })
121
155
  });
122
- });
123
- s.displayName = "CircularProgress";
124
- export { s as CircularProgress };
156
+ }
157
+ export { c as Checkbox };
package/dist/index55.cjs CHANGED
@@ -1 +1 @@
1
- const e=require("./index2.cjs"),t=require("./index38.cjs");let n=require("react"),r=e.__toESM(n,1);n=e.__toESM(n);var i=Object.defineProperty,a=(e,t)=>i(e,`name`,{value:t,configurable:!0}),o=r.useEffectEvent,s=r.useInsertionEffect;function c(e){if(typeof o==`function`)return o(e);let n=r.useRef(()=>{throw Error(`Cannot call an event handler while rendering.`)});return typeof s==`function`?s(()=>{n.current=e}):t.useLayoutEffect(()=>{n.current=e}),r.useMemo(()=>((...e)=>n.current?.(...e)),[])}a(c,`useEffectEvent`),exports.useEffectEvent=c;
1
+ const e=require("./index2.cjs"),t=require("./index14.cjs");let n=require("@stylexjs/stylex");n=e.__toESM(n,1);let r=require("react/jsx-runtime"),i=require("react"),a=e.__toESM(i,1);i=e.__toESM(i);var o={root:{kVAEAm:`x1n2onr6`,k1xSpc:`x3nfvp2`,kGNEyG:`x6s0dn4`,kjj79g:`xl56j7k`,kXLuUW:`xxymvpz`,$$css:!0},indicator:{kU5bRw:`x1owpc8m`,k1ekBW:`xxnu56j`,kIyJzY:`x1d8287x`,kAMwcw:`xz4gly6`,$$css:!0},colorDefault:{kjVXCG:`xodl5ec`,$$css:!0},colorSecondary:{kjVXCG:`x1vgo946`,$$css:!0},colorDestructive:{kjVXCG:`x1whg6ty`,$$css:!0},colorWarning:{kjVXCG:`x163v6lp`,$$css:!0},colorSuccess:{kjVXCG:`x1uof0aa`,$$css:!0}},s={xs:{size:24,strokeWidth:2.5,textSize:`xs`},sm:{size:36,strokeWidth:3,textSize:`xs`},md:{size:48,strokeWidth:4,textSize:`sm`},lg:{size:64,strokeWidth:5,textSize:`md`},xl:{size:96,strokeWidth:6,textSize:`lg`}},c=a.forwardRef(({value:e,min:i=0,max:a=100,size:c=`md`,strokeWidth:l,variant:u=`primary`,indeterminate:d,showValue:f=!1,formatValue:p,children:m,sx:h,className:g,style:_,"aria-label":v=`Circular progress`,...y},b)=>{let x=d||e===void 0||Number.isNaN(e),S=typeof c==`string`?s[c]:void 0,C=typeof c==`number`?c:S?.size??48,w=l??S?.strokeWidth??4,T=Math.max(0,(C-w)/2),E=2*Math.PI*T,D=Math.min(Math.max(e??0,i),a),O=Math.round((D-i)/(a-i||1)*100),k=x?E*.75:E-E*O/100,A=u===`secondary`?o.colorSecondary:u===`destructive`?o.colorDestructive:u===`warning`?o.colorWarning:u===`success`?o.colorSuccess:o.colorDefault,j=n.props(o.root,h),M=p?p(D):`${O}%`;return(0,r.jsxs)(`div`,{ref:b,role:`progressbar`,"aria-valuenow":x?void 0:D,"aria-valuemin":i,"aria-valuemax":a,"aria-label":v,"data-slot":`circular-progress`,"data-state":x?`indeterminate`:`determinate`,...j,className:g?`${j.className||``} ${g}`.trim():j.className,style:{width:C,height:C,..._},...y,children:[(0,r.jsxs)(`svg`,{viewBox:`0 0 ${C} ${C}`,width:C,height:C,...{0:{className:`x1lliihq x9tu13d`},1:{className:`x1lliihq x9tu13d x1ka1v4i x1sbju2s x1esw782 xa4qsjk`}}[!!x|0],children:[(0,r.jsx)(`circle`,{cx:C/2,cy:C/2,r:T,fill:`none`,strokeWidth:w,className:`xdeg11c`}),(0,r.jsx)(`circle`,{cx:C/2,cy:C/2,r:T,fill:`none`,strokeWidth:w,strokeDasharray:E,strokeDashoffset:k,...n.props(o.indicator,A)})]}),(f||m)&&(0,r.jsx)(`div`,{className:`x10l6tqk xwa60dl x1nrll8i x11lhmoz x78zum5 x6s0dn4 xl56j7k x47corl`,children:m||(0,r.jsx)(t.Text,{weight:`medium`,size:S?.textSize??`sm`,"data-slot":`circular-progress-value`,children:M})})]})});c.displayName=`CircularProgress`,exports.CircularProgress=c;
package/dist/index55.js CHANGED
@@ -1,20 +1,124 @@
1
- import { useLayoutEffect as e } from "./index38.js";
2
- import * as t from "react";
3
- // ../../node_modules/.pnpm/@radix-ui+react-use-effect-event@0.0.5_@types+react@19.3.0_react@19.3.1/node_modules/@radix-ui/react-use-effect-event/dist/index.mjs
4
- var n = Object.defineProperty, r = (e, t) => n(e, "name", {
5
- value: t,
6
- configurable: !0
7
- }), i = t.useEffectEvent, a = t.useInsertionEffect;
8
- function o(n) {
9
- if (typeof i == "function") return i(n);
10
- let r = t.useRef(() => {
11
- throw Error("Cannot call an event handler while rendering.");
1
+ import { Text as e } from "./index14.js";
2
+ import * as t from "@stylexjs/stylex";
3
+ import { jsx as n, jsxs as r } from "react/jsx-runtime";
4
+ import * as i from "react";
5
+ // src/ui/circular-progress.tsx
6
+ var a = {
7
+ root: {
8
+ kVAEAm: "x1n2onr6",
9
+ k1xSpc: "x3nfvp2",
10
+ kGNEyG: "x6s0dn4",
11
+ kjj79g: "xl56j7k",
12
+ kXLuUW: "xxymvpz",
13
+ $$css: !0
14
+ },
15
+ indicator: {
16
+ kU5bRw: "x1owpc8m",
17
+ k1ekBW: "xxnu56j",
18
+ kIyJzY: "x1d8287x",
19
+ kAMwcw: "xz4gly6",
20
+ $$css: !0
21
+ },
22
+ colorDefault: {
23
+ kjVXCG: "xodl5ec",
24
+ $$css: !0
25
+ },
26
+ colorSecondary: {
27
+ kjVXCG: "x1vgo946",
28
+ $$css: !0
29
+ },
30
+ colorDestructive: {
31
+ kjVXCG: "x1whg6ty",
32
+ $$css: !0
33
+ },
34
+ colorWarning: {
35
+ kjVXCG: "x163v6lp",
36
+ $$css: !0
37
+ },
38
+ colorSuccess: {
39
+ kjVXCG: "x1uof0aa",
40
+ $$css: !0
41
+ }
42
+ }, o = {
43
+ xs: {
44
+ size: 24,
45
+ strokeWidth: 2.5,
46
+ textSize: "xs"
47
+ },
48
+ sm: {
49
+ size: 36,
50
+ strokeWidth: 3,
51
+ textSize: "xs"
52
+ },
53
+ md: {
54
+ size: 48,
55
+ strokeWidth: 4,
56
+ textSize: "sm"
57
+ },
58
+ lg: {
59
+ size: 64,
60
+ strokeWidth: 5,
61
+ textSize: "md"
62
+ },
63
+ xl: {
64
+ size: 96,
65
+ strokeWidth: 6,
66
+ textSize: "lg"
67
+ }
68
+ }, s = i.forwardRef(({ value: i, min: s = 0, max: c = 100, size: l = "md", strokeWidth: u, variant: d = "primary", indeterminate: f, showValue: p = !1, formatValue: m, children: h, sx: g, className: _, style: v, "aria-label": y = "Circular progress", ...b }, x) => {
69
+ let S = f || i === void 0 || Number.isNaN(i), C = typeof l == "string" ? o[l] : void 0, w = typeof l == "number" ? l : C?.size ?? 48, T = u ?? C?.strokeWidth ?? 4, E = Math.max(0, (w - T) / 2), D = 2 * Math.PI * E, O = Math.min(Math.max(i ?? 0, s), c), k = Math.round((O - s) / (c - s || 1) * 100), A = S ? D * .75 : D - D * k / 100, j = d === "secondary" ? a.colorSecondary : d === "destructive" ? a.colorDestructive : d === "warning" ? a.colorWarning : d === "success" ? a.colorSuccess : a.colorDefault, M = t.props(a.root, g), N = m ? m(O) : `${k}%`;
70
+ return /* @__PURE__ */ r("div", {
71
+ ref: x,
72
+ role: "progressbar",
73
+ "aria-valuenow": S ? void 0 : O,
74
+ "aria-valuemin": s,
75
+ "aria-valuemax": c,
76
+ "aria-label": y,
77
+ "data-slot": "circular-progress",
78
+ "data-state": S ? "indeterminate" : "determinate",
79
+ ...M,
80
+ className: _ ? `${M.className || ""} ${_}`.trim() : M.className,
81
+ style: {
82
+ width: w,
83
+ height: w,
84
+ ...v
85
+ },
86
+ ...b,
87
+ children: [/* @__PURE__ */ r("svg", {
88
+ viewBox: `0 0 ${w} ${w}`,
89
+ width: w,
90
+ height: w,
91
+ ...{
92
+ 0: { className: "x1lliihq x9tu13d" },
93
+ 1: { className: "x1lliihq x9tu13d x1ka1v4i x1sbju2s x1esw782 xa4qsjk" }
94
+ }[!!S | 0],
95
+ children: [/* @__PURE__ */ n("circle", {
96
+ cx: w / 2,
97
+ cy: w / 2,
98
+ r: E,
99
+ fill: "none",
100
+ strokeWidth: T,
101
+ className: "xdeg11c"
102
+ }), /* @__PURE__ */ n("circle", {
103
+ cx: w / 2,
104
+ cy: w / 2,
105
+ r: E,
106
+ fill: "none",
107
+ strokeWidth: T,
108
+ strokeDasharray: D,
109
+ strokeDashoffset: A,
110
+ ...t.props(a.indicator, j)
111
+ })]
112
+ }), (p || h) && /* @__PURE__ */ n("div", {
113
+ className: "x10l6tqk xwa60dl x1nrll8i x11lhmoz x78zum5 x6s0dn4 xl56j7k x47corl",
114
+ children: h || /* @__PURE__ */ n(e, {
115
+ weight: "medium",
116
+ size: C?.textSize ?? "sm",
117
+ "data-slot": "circular-progress-value",
118
+ children: N
119
+ })
120
+ })]
12
121
  });
13
- return typeof a == "function" ? a(() => {
14
- r.current = n;
15
- }) : e(() => {
16
- r.current = n;
17
- }), t.useMemo(() => ((...e) => r.current?.(...e)), []);
18
- }
19
- r(o, "useEffectEvent");
20
- export { o as useEffectEvent };
122
+ });
123
+ s.displayName = "CircularProgress";
124
+ export { s as CircularProgress };
package/dist/index56.cjs CHANGED
@@ -1 +1 @@
1
- const e=require("./index2.cjs"),t=require("./index38.cjs"),n=require("./index55.cjs");let r=require("react"),i=e.__toESM(r,1);r=e.__toESM(r);var a=Object.defineProperty,o=(e,t)=>a(e,`name`,{value:t,configurable:!0}),s=i.useInsertionEffect||t.useLayoutEffect;function c({prop:e,defaultProp:t,onChange:n=o(()=>{},`onChange`),caller:r}){let[a,s,c]=l({defaultProp:t,onChange:n}),d=e!==void 0;return[d?e:a,i.useCallback(t=>{if(d){let n=u(t)?t(e):t;n!==e&&c.current?.(n)}else s(t)},[d,e,s,c])]}o(c,`useControllableState`);function l({defaultProp:e,onChange:t}){let[n,r]=i.useState(e),a=i.useRef(n),o=i.useRef(t);return s(()=>{o.current=t},[t]),i.useEffect(()=>{a.current!==n&&(o.current?.(n),a.current=n)},[n,a]),[n,r,o]}o(l,`useUncontrolledState`);function u(e){return typeof e==`function`}o(u,`isFunction`);var d=Symbol(`RADIX:SYNC_STATE`);function f(e,t,r,a){let{prop:o,defaultProp:s,onChange:c,caller:l}=t,u=o!==void 0,f=n.useEffectEvent(c),p=[{...r,state:s}];a&&p.push(a);let[m,h]=i.useReducer((t,n)=>{if(n.type===d)return{...t,state:n.state};let r=e(t,n);return u&&!Object.is(r.state,t.state)&&f(r.state),r},...p),g=m.state,_=i.useRef(g);i.useEffect(()=>{_.current!==g&&(_.current=g,u||f(g))},[g,_,u]);let v=i.useMemo(()=>o===void 0?m:{...m,state:o},[m,o]);return i.useEffect(()=>{u&&!Object.is(o,m.state)&&h({type:d,state:o})},[o,m.state,u]),[v,h]}o(f,`useControllableStateReducer`),exports.useControllableState=c,exports.useControllableStateReducer=f;
1
+ const e=require("./index2.cjs"),t=require("./index39.cjs");let n=require("react"),r=e.__toESM(n,1);n=e.__toESM(n);var i=Object.defineProperty,a=(e,t)=>i(e,`name`,{value:t,configurable:!0}),o=r.useEffectEvent,s=r.useInsertionEffect;function c(e){if(typeof o==`function`)return o(e);let n=r.useRef(()=>{throw Error(`Cannot call an event handler while rendering.`)});return typeof s==`function`?s(()=>{n.current=e}):t.useLayoutEffect(()=>{n.current=e}),r.useMemo(()=>((...e)=>n.current?.(...e)),[])}a(c,`useEffectEvent`),exports.useEffectEvent=c;
package/dist/index56.js CHANGED
@@ -1,82 +1,20 @@
1
- import { useLayoutEffect as e } from "./index38.js";
2
- import { useEffectEvent as t } from "./index55.js";
3
- import * as n from "react";
4
- // ../../node_modules/.pnpm/@radix-ui+react-use-controllable-state@1.2.6_@types+react@19.3.0_react@19.3.1/node_modules/@radix-ui/react-use-controllable-state/dist/index.mjs
5
- var r = Object.defineProperty, i = (e, t) => r(e, "name", {
1
+ import { useLayoutEffect as e } from "./index39.js";
2
+ import * as t from "react";
3
+ // ../../node_modules/.pnpm/@radix-ui+react-use-effect-event@0.0.5_@types+react@19.3.0_react@19.3.1/node_modules/@radix-ui/react-use-effect-event/dist/index.mjs
4
+ var n = Object.defineProperty, r = (e, t) => n(e, "name", {
6
5
  value: t,
7
6
  configurable: !0
8
- }), a = n.useInsertionEffect || e;
9
- function o({ prop: e, defaultProp: t, onChange: r = /* @__PURE__ */ i(() => {}, "onChange"), caller: a }) {
10
- let [o, l, u] = s({
11
- defaultProp: t,
12
- onChange: r
13
- }), d = e !== void 0;
14
- return [d ? e : o, n.useCallback((t) => {
15
- if (d) {
16
- let n = c(t) ? t(e) : t;
17
- n !== e && u.current?.(n);
18
- } else l(t);
19
- }, [
20
- d,
21
- e,
22
- l,
23
- u
24
- ])];
7
+ }), i = t.useEffectEvent, a = t.useInsertionEffect;
8
+ function o(n) {
9
+ if (typeof i == "function") return i(n);
10
+ let r = t.useRef(() => {
11
+ throw Error("Cannot call an event handler while rendering.");
12
+ });
13
+ return typeof a == "function" ? a(() => {
14
+ r.current = n;
15
+ }) : e(() => {
16
+ r.current = n;
17
+ }), t.useMemo(() => ((...e) => r.current?.(...e)), []);
25
18
  }
26
- i(o, "useControllableState");
27
- function s({ defaultProp: e, onChange: t }) {
28
- let [r, i] = n.useState(e), o = n.useRef(r), s = n.useRef(t);
29
- return a(() => {
30
- s.current = t;
31
- }, [t]), n.useEffect(() => {
32
- o.current !== r && (s.current?.(r), o.current = r);
33
- }, [r, o]), [
34
- r,
35
- i,
36
- s
37
- ];
38
- }
39
- i(s, "useUncontrolledState");
40
- function c(e) {
41
- return typeof e == "function";
42
- }
43
- i(c, "isFunction");
44
- var l = Symbol("RADIX:SYNC_STATE");
45
- function u(e, r, i, a) {
46
- let { prop: o, defaultProp: s, onChange: c, caller: u } = r, d = o !== void 0, f = t(c), p = [{
47
- ...i,
48
- state: s
49
- }];
50
- a && p.push(a);
51
- let [m, h] = n.useReducer((t, n) => {
52
- if (n.type === l) return {
53
- ...t,
54
- state: n.state
55
- };
56
- let r = e(t, n);
57
- return d && !Object.is(r.state, t.state) && f(r.state), r;
58
- }, ...p), g = m.state, _ = n.useRef(g);
59
- n.useEffect(() => {
60
- _.current !== g && (_.current = g, d || f(g));
61
- }, [
62
- g,
63
- _,
64
- d
65
- ]);
66
- let v = n.useMemo(() => o === void 0 ? m : {
67
- ...m,
68
- state: o
69
- }, [m, o]);
70
- return n.useEffect(() => {
71
- d && !Object.is(o, m.state) && h({
72
- type: l,
73
- state: o
74
- });
75
- }, [
76
- o,
77
- m.state,
78
- d
79
- ]), [v, h];
80
- }
81
- i(u, "useControllableStateReducer");
82
- export { o as useControllableState, u as useControllableStateReducer };
19
+ r(o, "useEffectEvent");
20
+ export { o as useEffectEvent };
package/dist/index57.cjs CHANGED
@@ -1 +1 @@
1
- "use client";const e=require("./index2.cjs"),t=require("./index38.cjs");let n=require("react"),r=e.__toESM(n,1);n=e.__toESM(n);var i=Object.defineProperty,a=(e,t)=>i(e,`name`,{value:t,configurable:!0});function o(e,t){return r.useReducer((e,n)=>t[e][n]??e,e)}a(o,`useStateMachine`);var s=a(e=>{let{present:t,children:n}=e,i=c(t),a=typeof n==`function`?n({present:i.isPresent}):r.Children.only(n),o=u(i.ref,f(a));return typeof n==`function`||i.isPresent?r.cloneElement(a,{ref:o}):null},`Presence`);function c(e){let[n,i]=r.useState(),s=r.useRef(null),c=r.useRef(e),l=r.useRef(`none`),u=r.useRef(void 0),[f,p]=o(e?`mounted`:`unmounted`,{mounted:{UNMOUNT:`unmounted`,ANIMATION_OUT:`unmountSuspended`},unmountSuspended:{MOUNT:`mounted`,ANIMATION_END:`unmounted`},unmounted:{MOUNT:`mounted`}});return r.useEffect(()=>{f===`mounted`?(l.current=u.current??d(s.current),u.current=void 0):l.current=`none`},[f]),t.useLayoutEffect(()=>{let t=s.current,n=c.current;if(n!==e){let r=l.current,i=d(t);e?(u.current=i,p(`MOUNT`)):i===`none`||t?.display===`none`?p(`UNMOUNT`):p(n&&r!==i?`ANIMATION_OUT`:`UNMOUNT`),c.current=e}},[e,p]),t.useLayoutEffect(()=>{if(n){let e,t=n.ownerDocument.defaultView??window,r=a(r=>{let i=d(s.current).includes(CSS.escape(r.animationName));if(r.target===n&&i&&(p(`ANIMATION_END`),!c.current)){let r=n.style.animationFillMode;n.style.animationFillMode=`forwards`,e=t.setTimeout(()=>{n.style.animationFillMode===`forwards`&&(n.style.animationFillMode=r)})}},`handleAnimationEnd`),i=a(e=>{e.target===n&&(l.current=d(s.current))},`handleAnimationStart`);return n.addEventListener(`animationstart`,i),n.addEventListener(`animationcancel`,r),n.addEventListener(`animationend`,r),()=>{t.clearTimeout(e),n.removeEventListener(`animationstart`,i),n.removeEventListener(`animationcancel`,r),n.removeEventListener(`animationend`,r)}}p(`ANIMATION_END`)},[n,p]),{isPresent:[`mounted`,`unmountSuspended`].includes(f),ref:r.useCallback(e=>{if(e){let t=getComputedStyle(e);s.current=t,u.current=d(t)}else s.current=null;i(e)},[])}}a(c,`usePresence`);function l(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}a(l,`setRef`);function u(...e){let t=r.useRef(e);return t.current=e,r.useCallback(e=>{let n=t.current,r=!1,i=n.map(t=>{let n=l(t,e);return!r&&typeof n==`function`&&(r=!0),n});if(r)return()=>{for(let e=0;e<i.length;e++){let t=i[e];typeof t==`function`?t():l(n[e],null)}}},[])}a(u,`useStableComposedRefs`);function d(e){return e?.animationName||`none`}a(d,`getAnimationName`);function f(e){let t=Object.getOwnPropertyDescriptor(e.props,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}a(f,`getElementRef`),exports.Presence=s;
1
+ const e=require("./index2.cjs"),t=require("./index39.cjs"),n=require("./index56.cjs");let r=require("react"),i=e.__toESM(r,1);r=e.__toESM(r);var a=Object.defineProperty,o=(e,t)=>a(e,`name`,{value:t,configurable:!0}),s=i.useInsertionEffect||t.useLayoutEffect;function c({prop:e,defaultProp:t,onChange:n=o(()=>{},`onChange`),caller:r}){let[a,s,c]=l({defaultProp:t,onChange:n}),d=e!==void 0;return[d?e:a,i.useCallback(t=>{if(d){let n=u(t)?t(e):t;n!==e&&c.current?.(n)}else s(t)},[d,e,s,c])]}o(c,`useControllableState`);function l({defaultProp:e,onChange:t}){let[n,r]=i.useState(e),a=i.useRef(n),o=i.useRef(t);return s(()=>{o.current=t},[t]),i.useEffect(()=>{a.current!==n&&(o.current?.(n),a.current=n)},[n,a]),[n,r,o]}o(l,`useUncontrolledState`);function u(e){return typeof e==`function`}o(u,`isFunction`);var d=Symbol(`RADIX:SYNC_STATE`);function f(e,t,r,a){let{prop:o,defaultProp:s,onChange:c,caller:l}=t,u=o!==void 0,f=n.useEffectEvent(c),p=[{...r,state:s}];a&&p.push(a);let[m,h]=i.useReducer((t,n)=>{if(n.type===d)return{...t,state:n.state};let r=e(t,n);return u&&!Object.is(r.state,t.state)&&f(r.state),r},...p),g=m.state,_=i.useRef(g);i.useEffect(()=>{_.current!==g&&(_.current=g,u||f(g))},[g,_,u]);let v=i.useMemo(()=>o===void 0?m:{...m,state:o},[m,o]);return i.useEffect(()=>{u&&!Object.is(o,m.state)&&h({type:d,state:o})},[o,m.state,u]),[v,h]}o(f,`useControllableStateReducer`),exports.useControllableState=c,exports.useControllableStateReducer=f;