lizaui 3.0.11

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 (348) hide show
  1. package/README.md +54 -0
  2. package/dist/button/index.cjs.js +2 -0
  3. package/dist/button/index.cjs.js.map +1 -0
  4. package/dist/button/index.es.js +5 -0
  5. package/dist/button/index.es.js.map +1 -0
  6. package/dist/button.d.ts +2 -0
  7. package/dist/calendar/index.cjs.js +425 -0
  8. package/dist/calendar/index.cjs.js.map +1 -0
  9. package/dist/calendar/index.es.js +6105 -0
  10. package/dist/calendar/index.es.js.map +1 -0
  11. package/dist/calendar.d.ts +2 -0
  12. package/dist/checkbox/index.cjs.js +2 -0
  13. package/dist/checkbox/index.cjs.js.map +1 -0
  14. package/dist/checkbox/index.es.js +6 -0
  15. package/dist/checkbox/index.es.js.map +1 -0
  16. package/dist/checkbox.d.ts +2 -0
  17. package/dist/chip/index.cjs.js +2 -0
  18. package/dist/chip/index.cjs.js.map +1 -0
  19. package/dist/chip/index.es.js +533 -0
  20. package/dist/chip/index.es.js.map +1 -0
  21. package/dist/chip.d.ts +2 -0
  22. package/dist/chunks/bundle-mjs-JiDEie86.js +2728 -0
  23. package/dist/chunks/bundle-mjs-JiDEie86.js.map +1 -0
  24. package/dist/chunks/bundle-mjs-W341Qwux.js +2 -0
  25. package/dist/chunks/bundle-mjs-W341Qwux.js.map +1 -0
  26. package/dist/chunks/button-CPpIQ7Z7.js +3971 -0
  27. package/dist/chunks/button-CPpIQ7Z7.js.map +1 -0
  28. package/dist/chunks/button-Dr5w6yIW.js +10 -0
  29. package/dist/chunks/button-Dr5w6yIW.js.map +1 -0
  30. package/dist/chunks/checkbox-C71XoTt2.js +2 -0
  31. package/dist/chunks/checkbox-C71XoTt2.js.map +1 -0
  32. package/dist/chunks/checkbox-DN309yjg.js +312 -0
  33. package/dist/chunks/checkbox-DN309yjg.js.map +1 -0
  34. package/dist/chunks/classes-7MXTIFwM.js +52 -0
  35. package/dist/chunks/classes-7MXTIFwM.js.map +1 -0
  36. package/dist/chunks/classes-P14wj2Ze.js +2 -0
  37. package/dist/chunks/classes-P14wj2Ze.js.map +1 -0
  38. package/dist/chunks/clsx-C11secjj.js +2 -0
  39. package/dist/chunks/clsx-C11secjj.js.map +1 -0
  40. package/dist/chunks/clsx-OuTLNxxd.js +17 -0
  41. package/dist/chunks/clsx-OuTLNxxd.js.map +1 -0
  42. package/dist/chunks/floating-ui.dom-9ZI0iiqa.js +2 -0
  43. package/dist/chunks/floating-ui.dom-9ZI0iiqa.js.map +1 -0
  44. package/dist/chunks/floating-ui.dom-PqoU7a4n.js +1134 -0
  45. package/dist/chunks/floating-ui.dom-PqoU7a4n.js.map +1 -0
  46. package/dist/chunks/floating-ui.react-dom-BQpCDpNU.js +2 -0
  47. package/dist/chunks/floating-ui.react-dom-BQpCDpNU.js.map +1 -0
  48. package/dist/chunks/floating-ui.react-dom-CihJ_dlB.js +204 -0
  49. package/dist/chunks/floating-ui.react-dom-CihJ_dlB.js.map +1 -0
  50. package/dist/chunks/iconBase-C4boY5mo.js +2 -0
  51. package/dist/chunks/iconBase-C4boY5mo.js.map +1 -0
  52. package/dist/chunks/iconBase-DSKTHwal.js +113 -0
  53. package/dist/chunks/iconBase-DSKTHwal.js.map +1 -0
  54. package/dist/chunks/index-CBDkd84T.js +2 -0
  55. package/dist/chunks/index-CBDkd84T.js.map +1 -0
  56. package/dist/chunks/index-C_b6-TON.js +78 -0
  57. package/dist/chunks/index-C_b6-TON.js.map +1 -0
  58. package/dist/chunks/jsx-runtime-BYq8_R6m.js +247 -0
  59. package/dist/chunks/jsx-runtime-BYq8_R6m.js.map +1 -0
  60. package/dist/chunks/jsx-runtime-DFswc9zO.js +2 -0
  61. package/dist/chunks/jsx-runtime-DFswc9zO.js.map +1 -0
  62. package/dist/chunks/pattern-CdQavADx.js +5 -0
  63. package/dist/chunks/pattern-CdQavADx.js.map +1 -0
  64. package/dist/chunks/pattern-F8jUniwt.js +2 -0
  65. package/dist/chunks/pattern-F8jUniwt.js.map +1 -0
  66. package/dist/chunks/refs-DLih6QCP.js +2 -0
  67. package/dist/chunks/refs-DLih6QCP.js.map +1 -0
  68. package/dist/chunks/refs-DcCOPvdv.js +35 -0
  69. package/dist/chunks/refs-DcCOPvdv.js.map +1 -0
  70. package/dist/chunks/select-BoiIj-gw.js +7 -0
  71. package/dist/chunks/select-BoiIj-gw.js.map +1 -0
  72. package/dist/chunks/select-Cy78fn6H.js +4267 -0
  73. package/dist/chunks/select-Cy78fn6H.js.map +1 -0
  74. package/dist/chunks/tooltip-BQVohLC7.js +2 -0
  75. package/dist/chunks/tooltip-BQVohLC7.js.map +1 -0
  76. package/dist/chunks/tooltip-CIcTjpF8.js +959 -0
  77. package/dist/chunks/tooltip-CIcTjpF8.js.map +1 -0
  78. package/dist/chunks/tv-ButAo3dF.js +2669 -0
  79. package/dist/chunks/tv-ButAo3dF.js.map +1 -0
  80. package/dist/chunks/tv-C5lw0tnu.js +2 -0
  81. package/dist/chunks/tv-C5lw0tnu.js.map +1 -0
  82. package/dist/chunks/utils-Blo0iNdk.js +15 -0
  83. package/dist/chunks/utils-Blo0iNdk.js.map +1 -0
  84. package/dist/chunks/utils-DuSyQWep.js +2 -0
  85. package/dist/chunks/utils-DuSyQWep.js.map +1 -0
  86. package/dist/chunks/v4-CRLUkzQ6.js +31 -0
  87. package/dist/chunks/v4-CRLUkzQ6.js.map +1 -0
  88. package/dist/chunks/v4-CqU37_Sa.js +2 -0
  89. package/dist/chunks/v4-CqU37_Sa.js.map +1 -0
  90. package/dist/chunks/variants-BUTPDD09.js +2 -0
  91. package/dist/chunks/variants-BUTPDD09.js.map +1 -0
  92. package/dist/chunks/variants-DhZQjbsQ.js +62 -0
  93. package/dist/chunks/variants-DhZQjbsQ.js.map +1 -0
  94. package/dist/components/button/button.d.ts +6 -0
  95. package/dist/components/button/button.d.ts.map +1 -0
  96. package/dist/components/button/index.d.ts +4 -0
  97. package/dist/components/button/index.d.ts.map +1 -0
  98. package/dist/components/button/spinner.d.ts +3 -0
  99. package/dist/components/button/spinner.d.ts.map +1 -0
  100. package/dist/components/button/use-button.d.ts +328 -0
  101. package/dist/components/button/use-button.d.ts.map +1 -0
  102. package/dist/components/calendar/date-picker/date-picker.d.ts +3 -0
  103. package/dist/components/calendar/date-picker/date-picker.d.ts.map +1 -0
  104. package/dist/components/calendar/date-picker/date-picker.style.d.ts +9 -0
  105. package/dist/components/calendar/date-picker/date-picker.style.d.ts.map +1 -0
  106. package/dist/components/calendar/date-picker/interface/date-picker.interface.d.ts +38 -0
  107. package/dist/components/calendar/date-picker/interface/date-picker.interface.d.ts.map +1 -0
  108. package/dist/components/calendar/icon/icon-calendar.d.ts +11 -0
  109. package/dist/components/calendar/icon/icon-calendar.d.ts.map +1 -0
  110. package/dist/components/calendar/index.d.ts +2 -0
  111. package/dist/components/calendar/index.d.ts.map +1 -0
  112. package/dist/components/calendar/interface/calendar-shared.interface.d.ts +4 -0
  113. package/dist/components/calendar/interface/calendar-shared.interface.d.ts.map +1 -0
  114. package/dist/components/checkbox/checkbox-icon.d.ts +9 -0
  115. package/dist/components/checkbox/checkbox-icon.d.ts.map +1 -0
  116. package/dist/components/checkbox/checkbox.d.ts +7 -0
  117. package/dist/components/checkbox/checkbox.d.ts.map +1 -0
  118. package/dist/components/checkbox/index.d.ts +5 -0
  119. package/dist/components/checkbox/index.d.ts.map +1 -0
  120. package/dist/components/checkbox/use-checkbox.d.ts +57 -0
  121. package/dist/components/checkbox/use-checkbox.d.ts.map +1 -0
  122. package/dist/components/chip/chip.d.ts +6 -0
  123. package/dist/components/chip/chip.d.ts.map +1 -0
  124. package/dist/components/chip/index.d.ts +4 -0
  125. package/dist/components/chip/index.d.ts.map +1 -0
  126. package/dist/components/chip/use-chip.d.ts +441 -0
  127. package/dist/components/chip/use-chip.d.ts.map +1 -0
  128. package/dist/components/divider/divider.d.ts +6 -0
  129. package/dist/components/divider/divider.d.ts.map +1 -0
  130. package/dist/components/divider/index.d.ts +4 -0
  131. package/dist/components/divider/index.d.ts.map +1 -0
  132. package/dist/components/divider/use-divider.d.ts +19 -0
  133. package/dist/components/divider/use-divider.d.ts.map +1 -0
  134. package/dist/components/divider/use-separator.d.ts +22 -0
  135. package/dist/components/divider/use-separator.d.ts.map +1 -0
  136. package/dist/components/icons/close-filled.d.ts +3 -0
  137. package/dist/components/icons/close-filled.d.ts.map +1 -0
  138. package/dist/components/index.d.ts +5 -0
  139. package/dist/components/index.d.ts.map +1 -0
  140. package/dist/components/pagination/function/index.d.ts +7 -0
  141. package/dist/components/pagination/function/index.d.ts.map +1 -0
  142. package/dist/components/pagination/hook/use-pagination.d.ts +3 -0
  143. package/dist/components/pagination/hook/use-pagination.d.ts.map +1 -0
  144. package/dist/components/pagination/index.d.ts +4 -0
  145. package/dist/components/pagination/index.d.ts.map +1 -0
  146. package/dist/components/pagination/interface/pagination-share.interface.d.ts +10 -0
  147. package/dist/components/pagination/interface/pagination-share.interface.d.ts.map +1 -0
  148. package/dist/components/pagination/interface/pagination.interface.d.ts +26 -0
  149. package/dist/components/pagination/interface/pagination.interface.d.ts.map +1 -0
  150. package/dist/components/pagination/pagination-item.d.ts +3 -0
  151. package/dist/components/pagination/pagination-item.d.ts.map +1 -0
  152. package/dist/components/pagination/pagination.d.ts +3 -0
  153. package/dist/components/pagination/pagination.d.ts.map +1 -0
  154. package/dist/components/ripple/ripple.d.ts +20 -0
  155. package/dist/components/ripple/ripple.d.ts.map +1 -0
  156. package/dist/components/ripple/use-ripple.d.ts +10 -0
  157. package/dist/components/ripple/use-ripple.d.ts.map +1 -0
  158. package/dist/components/select/autocomplete/autocomplete.d.ts +3 -0
  159. package/dist/components/select/autocomplete/autocomplete.d.ts.map +1 -0
  160. package/dist/components/select/index.d.ts +3 -0
  161. package/dist/components/select/index.d.ts.map +1 -0
  162. package/dist/components/select/select.d.ts +3 -0
  163. package/dist/components/select/select.d.ts.map +1 -0
  164. package/dist/components/select/style/select-theme.style.d.ts +4 -0
  165. package/dist/components/select/style/select-theme.style.d.ts.map +1 -0
  166. package/dist/components/select/sub-component/clear-indicator.d.ts +3 -0
  167. package/dist/components/select/sub-component/clear-indicator.d.ts.map +1 -0
  168. package/dist/components/select/sub-component/control-start.d.ts +3 -0
  169. package/dist/components/select/sub-component/control-start.d.ts.map +1 -0
  170. package/dist/components/select/sub-component/dropdown-indicator.d.ts +3 -0
  171. package/dist/components/select/sub-component/dropdown-indicator.d.ts.map +1 -0
  172. package/dist/components/select/sub-component/index.d.ts +9 -0
  173. package/dist/components/select/sub-component/index.d.ts.map +1 -0
  174. package/dist/components/select/sub-component/input-select.d.ts +3 -0
  175. package/dist/components/select/sub-component/input-select.d.ts.map +1 -0
  176. package/dist/components/select/sub-component/loading-indicator.d.ts +3 -0
  177. package/dist/components/select/sub-component/loading-indicator.d.ts.map +1 -0
  178. package/dist/components/select/sub-component/loading-message.d.ts +3 -0
  179. package/dist/components/select/sub-component/loading-message.d.ts.map +1 -0
  180. package/dist/components/select/sub-component/no-option-message.d.ts +3 -0
  181. package/dist/components/select/sub-component/no-option-message.d.ts.map +1 -0
  182. package/dist/components/select/sub-component/option-item.d.ts +3 -0
  183. package/dist/components/select/sub-component/option-item.d.ts.map +1 -0
  184. package/dist/components/select/sub-component/single-value.d.ts +3 -0
  185. package/dist/components/select/sub-component/single-value.d.ts.map +1 -0
  186. package/dist/components/table/body/table-body-column.d.ts +4 -0
  187. package/dist/components/table/body/table-body-column.d.ts.map +1 -0
  188. package/dist/components/table/body/table-body-row.d.ts +3 -0
  189. package/dist/components/table/body/table-body-row.d.ts.map +1 -0
  190. package/dist/components/table/body/table-body.d.ts +4 -0
  191. package/dist/components/table/body/table-body.d.ts.map +1 -0
  192. package/dist/components/table/context/table.context.d.ts +3 -0
  193. package/dist/components/table/context/table.context.d.ts.map +1 -0
  194. package/dist/components/table/header/table-header-column.d.ts +4 -0
  195. package/dist/components/table/header/table-header-column.d.ts.map +1 -0
  196. package/dist/components/table/header/table-header-row.d.ts +4 -0
  197. package/dist/components/table/header/table-header-row.d.ts.map +1 -0
  198. package/dist/components/table/header/table-header.d.ts +4 -0
  199. package/dist/components/table/header/table-header.d.ts.map +1 -0
  200. package/dist/components/table/hook/use-table-context.d.ts +2 -0
  201. package/dist/components/table/hook/use-table-context.d.ts.map +1 -0
  202. package/dist/components/table/hook/use-table.d.ts +10 -0
  203. package/dist/components/table/hook/use-table.d.ts.map +1 -0
  204. package/dist/components/table/index.d.ts +4 -0
  205. package/dist/components/table/index.d.ts.map +1 -0
  206. package/dist/components/table/interface/table-share.interface.d.ts +9 -0
  207. package/dist/components/table/interface/table-share.interface.d.ts.map +1 -0
  208. package/dist/components/table/interface/table.interface.d.ts +115 -0
  209. package/dist/components/table/interface/table.interface.d.ts.map +1 -0
  210. package/dist/components/table/search/table-search-column.d.ts +4 -0
  211. package/dist/components/table/search/table-search-column.d.ts.map +1 -0
  212. package/dist/components/table/search/table-search-row.d.ts +4 -0
  213. package/dist/components/table/search/table-search-row.d.ts.map +1 -0
  214. package/dist/components/table/table.d.ts +4 -0
  215. package/dist/components/table/table.d.ts.map +1 -0
  216. package/dist/components/tooltip/index.d.ts +2 -0
  217. package/dist/components/tooltip/index.d.ts.map +1 -0
  218. package/dist/components/tooltip/tooltip.d.ts +11 -0
  219. package/dist/components/tooltip/tooltip.d.ts.map +1 -0
  220. package/dist/components/ui/accordion.d.ts +8 -0
  221. package/dist/components/ui/accordion.d.ts.map +1 -0
  222. package/dist/components/ui/alert-dialog.d.ts +15 -0
  223. package/dist/components/ui/alert-dialog.d.ts.map +1 -0
  224. package/dist/components/ui/avatar.d.ts +13 -0
  225. package/dist/components/ui/avatar.d.ts.map +1 -0
  226. package/dist/components/ui/badge.d.ts +218 -0
  227. package/dist/components/ui/badge.d.ts.map +1 -0
  228. package/dist/components/ui/card.d.ts +10 -0
  229. package/dist/components/ui/card.d.ts.map +1 -0
  230. package/dist/components/ui/command.d.ts +19 -0
  231. package/dist/components/ui/command.d.ts.map +1 -0
  232. package/dist/components/ui/confirmation.d.ts +17 -0
  233. package/dist/components/ui/confirmation.d.ts.map +1 -0
  234. package/dist/components/ui/dialog.d.ts +16 -0
  235. package/dist/components/ui/dialog.d.ts.map +1 -0
  236. package/dist/components/ui/dropdown-menu.d.ts +26 -0
  237. package/dist/components/ui/dropdown-menu.d.ts.map +1 -0
  238. package/dist/components/ui/index.d.ts +21 -0
  239. package/dist/components/ui/index.d.ts.map +1 -0
  240. package/dist/components/ui/input-otp.d.ts +12 -0
  241. package/dist/components/ui/input-otp.d.ts.map +1 -0
  242. package/dist/components/ui/input.d.ts +42 -0
  243. package/dist/components/ui/input.d.ts.map +1 -0
  244. package/dist/components/ui/label-error.d.ts +16 -0
  245. package/dist/components/ui/label-error.d.ts.map +1 -0
  246. package/dist/components/ui/label.d.ts +5 -0
  247. package/dist/components/ui/label.d.ts.map +1 -0
  248. package/dist/components/ui/menubar.d.ts +27 -0
  249. package/dist/components/ui/menubar.d.ts.map +1 -0
  250. package/dist/components/ui/modal.d.ts +16 -0
  251. package/dist/components/ui/modal.d.ts.map +1 -0
  252. package/dist/components/ui/navigation-menu.d.ts +15 -0
  253. package/dist/components/ui/navigation-menu.d.ts.map +1 -0
  254. package/dist/components/ui/popover.d.ts +8 -0
  255. package/dist/components/ui/popover.d.ts.map +1 -0
  256. package/dist/components/ui/resizable.d.ts +9 -0
  257. package/dist/components/ui/resizable.d.ts.map +1 -0
  258. package/dist/components/ui/skeleton.d.ts +3 -0
  259. package/dist/components/ui/skeleton.d.ts.map +1 -0
  260. package/dist/components/ui/switch.d.ts +13 -0
  261. package/dist/components/ui/switch.d.ts.map +1 -0
  262. package/dist/components/ui/tabs.d.ts +8 -0
  263. package/dist/components/ui/tabs.d.ts.map +1 -0
  264. package/dist/divider/index.cjs.js +2 -0
  265. package/dist/divider/index.cjs.js.map +1 -0
  266. package/dist/divider/index.es.js +67 -0
  267. package/dist/divider/index.es.js.map +1 -0
  268. package/dist/divider.d.ts +2 -0
  269. package/dist/functions/assertion.d.ts +14 -0
  270. package/dist/functions/assertion.d.ts.map +1 -0
  271. package/dist/functions/index.d.ts +5 -0
  272. package/dist/functions/index.d.ts.map +1 -0
  273. package/dist/functions/numbers.d.ts +20 -0
  274. package/dist/functions/numbers.d.ts.map +1 -0
  275. package/dist/functions/pattern.d.ts +3 -0
  276. package/dist/functions/pattern.d.ts.map +1 -0
  277. package/dist/functions/refs.d.ts +20 -0
  278. package/dist/functions/refs.d.ts.map +1 -0
  279. package/dist/hooks/use-confirmation.d.ts +21 -0
  280. package/dist/hooks/use-confirmation.d.ts.map +1 -0
  281. package/dist/hooks/use-modal.d.ts +15 -0
  282. package/dist/hooks/use-modal.d.ts.map +1 -0
  283. package/dist/index.cjs.js +2 -0
  284. package/dist/index.cjs.js.map +1 -0
  285. package/dist/index.d.ts +2 -0
  286. package/dist/index.es.js +386 -0
  287. package/dist/index.es.js.map +1 -0
  288. package/dist/lib/tv.d.ts +21 -0
  289. package/dist/lib/tv.d.ts.map +1 -0
  290. package/dist/lib/utils.d.ts +3 -0
  291. package/dist/lib/utils.d.ts.map +1 -0
  292. package/dist/lizaui.css +1 -0
  293. package/dist/pagination/index.cjs.js +2 -0
  294. package/dist/pagination/index.cjs.js.map +1 -0
  295. package/dist/pagination/index.es.js +170 -0
  296. package/dist/pagination/index.es.js.map +1 -0
  297. package/dist/pagination.d.ts +2 -0
  298. package/dist/select/index.cjs.js +2 -0
  299. package/dist/select/index.cjs.js.map +1 -0
  300. package/dist/select/index.es.js +226 -0
  301. package/dist/select/index.es.js.map +1 -0
  302. package/dist/select.d.ts +2 -0
  303. package/dist/table/index.cjs.js +2 -0
  304. package/dist/table/index.cjs.js.map +1 -0
  305. package/dist/table/index.es.js +233 -0
  306. package/dist/table/index.es.js.map +1 -0
  307. package/dist/table.d.ts +2 -0
  308. package/dist/theme/classes.d.ts +34 -0
  309. package/dist/theme/classes.d.ts.map +1 -0
  310. package/dist/theme/color/button.d.ts +162 -0
  311. package/dist/theme/color/button.d.ts.map +1 -0
  312. package/dist/theme/color/checkbox.d.ts +289 -0
  313. package/dist/theme/color/checkbox.d.ts.map +1 -0
  314. package/dist/theme/color/chip.d.ts +321 -0
  315. package/dist/theme/color/chip.d.ts.map +1 -0
  316. package/dist/theme/color/divider.d.ts +29 -0
  317. package/dist/theme/color/divider.d.ts.map +1 -0
  318. package/dist/theme/index.d.ts +3 -0
  319. package/dist/theme/index.d.ts.map +1 -0
  320. package/dist/theme/variants.d.ts +66 -0
  321. package/dist/theme/variants.d.ts.map +1 -0
  322. package/dist/tooltip/index.cjs.js +2 -0
  323. package/dist/tooltip/index.cjs.js.map +1 -0
  324. package/dist/tooltip/index.es.js +5 -0
  325. package/dist/tooltip/index.es.js.map +1 -0
  326. package/dist/tooltip.d.ts +2 -0
  327. package/dist/types/checkbox.type.d.ts +89 -0
  328. package/dist/types/checkbox.type.d.ts.map +1 -0
  329. package/dist/types/global.d.ts +5 -0
  330. package/dist/types/global.d.ts.map +1 -0
  331. package/dist/types/icon.type.d.ts +3 -0
  332. package/dist/types/icon.type.d.ts.map +1 -0
  333. package/dist/types/index.d.ts +8 -0
  334. package/dist/types/index.d.ts.map +1 -0
  335. package/dist/types/select/select-main.type.d.ts +139 -0
  336. package/dist/types/select/select-main.type.d.ts.map +1 -0
  337. package/dist/types/select/select.type.d.ts +8 -0
  338. package/dist/types/select/select.type.d.ts.map +1 -0
  339. package/dist/types/switch.type.d.ts +78 -0
  340. package/dist/types/switch.type.d.ts.map +1 -0
  341. package/dist/types/theme.d.ts +8 -0
  342. package/dist/types/theme.d.ts.map +1 -0
  343. package/dist/ui/index.cjs.js +71 -0
  344. package/dist/ui/index.cjs.js.map +1 -0
  345. package/dist/ui/index.es.js +8189 -0
  346. package/dist/ui/index.es.js.map +1 -0
  347. package/dist/ui.d.ts +2 -0
  348. package/package.json +135 -0
@@ -0,0 +1,386 @@
1
+ import C, { useState as T, useRef as K, useId as q, useCallback as x, useEffect as N, useMemo as z } from "react";
2
+ function oe(e) {
3
+ const [n, i] = T(!1), [r, t] = T(!1), [d, c] = T(null), s = K(() => {
4
+ }), f = K(() => {
5
+ }), g = q(), a = e || `modal-${g}`, p = x((o) => {
6
+ var v;
7
+ o !== void 0 && c(o), i(!0), t(!0), (v = s.current) == null || v.call(s);
8
+ }, []), b = x(() => {
9
+ var o;
10
+ i(!1), t(!1), (o = f.current) == null || o.call(f);
11
+ }, []);
12
+ return {
13
+ modalId: a,
14
+ isOpen: n,
15
+ isVisibleModal: r,
16
+ paramBody: d,
17
+ showModal: p,
18
+ closeModal: b,
19
+ visibleModal: () => t(!0),
20
+ hiddenModal: () => t(!1),
21
+ updateParamBody: (o) => {
22
+ c(o);
23
+ },
24
+ toggleModal: () => {
25
+ i((o) => {
26
+ var m, y;
27
+ const v = !o;
28
+ return v ? (m = s.current) == null || m.call(s) : (y = f.current) == null || y.call(f), v;
29
+ });
30
+ }
31
+ };
32
+ }
33
+ const S = {
34
+ title: "",
35
+ description: "",
36
+ body: null,
37
+ isOpen: !1,
38
+ loading: !1,
39
+ params: null
40
+ }, re = () => {
41
+ const [e, n] = T(S), [i, r] = T({});
42
+ return {
43
+ alert: e,
44
+ showAlert: (a) => {
45
+ n({
46
+ ...S,
47
+ ...a,
48
+ isOpen: !0
49
+ });
50
+ },
51
+ setAlertLoading: () => n((a) => ({ ...a, loading: !0 })),
52
+ hideAlert: () => n(S),
53
+ alerts: i,
54
+ showModalByKey: (a, p) => {
55
+ r((b) => ({
56
+ ...b,
57
+ [a]: {
58
+ ...S,
59
+ ...p,
60
+ isOpen: !0
61
+ }
62
+ }));
63
+ },
64
+ setModalLoadingByKey: (a) => {
65
+ r((p) => ({
66
+ ...p,
67
+ [a]: { ...p[a], loading: !0 }
68
+ }));
69
+ },
70
+ hideModalByKey: (a) => {
71
+ r((p) => ({
72
+ ...p,
73
+ [a]: S
74
+ }));
75
+ }
76
+ };
77
+ }, H = typeof document < "u" ? C.useLayoutEffect : () => {
78
+ };
79
+ function I(e) {
80
+ const n = K(null);
81
+ return H(() => {
82
+ n.current = e;
83
+ }, [
84
+ e
85
+ ]), x((...i) => {
86
+ const r = n.current;
87
+ return r == null ? void 0 : r(...i);
88
+ }, []);
89
+ }
90
+ const V = (e) => {
91
+ var n;
92
+ return (n = e == null ? void 0 : e.ownerDocument) !== null && n !== void 0 ? n : document;
93
+ };
94
+ function k(e) {
95
+ var n;
96
+ return typeof window > "u" || window.navigator == null ? !1 : ((n = window.navigator.userAgentData) === null || n === void 0 ? void 0 : n.brands.some((i) => e.test(i.brand))) || e.test(window.navigator.userAgent);
97
+ }
98
+ function P(e) {
99
+ var n;
100
+ return typeof window < "u" && window.navigator != null ? e.test(((n = window.navigator.userAgentData) === null || n === void 0 ? void 0 : n.platform) || window.navigator.platform) : !1;
101
+ }
102
+ function h(e) {
103
+ if (process.env.NODE_ENV === "test") return e;
104
+ let n = null;
105
+ return () => (n == null && (n = e()), n);
106
+ }
107
+ const F = h(function() {
108
+ return P(/^Mac/i);
109
+ }), j = h(function() {
110
+ return P(/^iPhone/i);
111
+ }), W = h(function() {
112
+ return P(/^iPad/i) || // iPadOS 13 lies and says it's a Mac, but we can distinguish by detecting touch support.
113
+ F() && navigator.maxTouchPoints > 1;
114
+ }), U = h(function() {
115
+ return j() || W();
116
+ });
117
+ h(function() {
118
+ return F() || U();
119
+ });
120
+ h(function() {
121
+ return k(/AppleWebKit/i) && !J();
122
+ });
123
+ const J = h(function() {
124
+ return k(/Chrome/i);
125
+ });
126
+ h(function() {
127
+ return k(/Android/i);
128
+ });
129
+ h(function() {
130
+ return k(/Firefox/i);
131
+ });
132
+ let M = /* @__PURE__ */ new Map(), X = /* @__PURE__ */ new Set();
133
+ function O() {
134
+ if (typeof window > "u") return;
135
+ function e(r) {
136
+ return "propertyName" in r;
137
+ }
138
+ let n = (r) => {
139
+ if (!e(r) || !r.target) return;
140
+ let t = M.get(r.target);
141
+ t || (t = /* @__PURE__ */ new Set(), M.set(r.target, t), r.target.addEventListener("transitioncancel", i, {
142
+ once: !0
143
+ })), t.add(r.propertyName);
144
+ }, i = (r) => {
145
+ if (!e(r) || !r.target) return;
146
+ let t = M.get(r.target);
147
+ if (t && (t.delete(r.propertyName), t.size === 0 && (r.target.removeEventListener("transitioncancel", i), M.delete(r.target)), M.size === 0)) {
148
+ for (let d of X) d();
149
+ X.clear();
150
+ }
151
+ };
152
+ document.body.addEventListener("transitionrun", n), document.body.addEventListener("transitionend", i);
153
+ }
154
+ typeof document < "u" && (document.readyState !== "loading" ? O() : document.addEventListener("DOMContentLoaded", O));
155
+ function Q() {
156
+ for (const [e] of M)
157
+ "isConnected" in e && !e.isConnected && M.delete(e);
158
+ }
159
+ function Z(e) {
160
+ requestAnimationFrame(() => {
161
+ Q(), M.size === 0 ? e() : X.add(e);
162
+ });
163
+ }
164
+ function R() {
165
+ let e = K(/* @__PURE__ */ new Map()), n = x((t, d, c, s) => {
166
+ let f = s != null && s.once ? (...g) => {
167
+ e.current.delete(c), c(...g);
168
+ } : c;
169
+ e.current.set(c, {
170
+ type: d,
171
+ eventTarget: t,
172
+ fn: f,
173
+ options: s
174
+ }), t.addEventListener(d, f, s);
175
+ }, []), i = x((t, d, c, s) => {
176
+ var f;
177
+ let g = ((f = e.current.get(c)) === null || f === void 0 ? void 0 : f.fn) || c;
178
+ t.removeEventListener(d, g, s), e.current.delete(c);
179
+ }, []), r = x(() => {
180
+ e.current.forEach((t, d) => {
181
+ i(t.eventTarget, t.type, d, t.options);
182
+ });
183
+ }, [
184
+ i
185
+ ]);
186
+ return N(() => r, [
187
+ r
188
+ ]), {
189
+ addGlobalListener: n,
190
+ removeGlobalListener: i,
191
+ removeAllGlobalListeners: r
192
+ };
193
+ }
194
+ let L = "default", Y = "", E = /* @__PURE__ */ new WeakMap();
195
+ function _(e) {
196
+ if (U()) {
197
+ if (L === "default") {
198
+ const n = V(e);
199
+ Y = n.documentElement.style.webkitUserSelect, n.documentElement.style.webkitUserSelect = "none";
200
+ }
201
+ L = "disabled";
202
+ } else if (e instanceof HTMLElement || e instanceof SVGElement) {
203
+ let n = "userSelect" in e.style ? "userSelect" : "webkitUserSelect";
204
+ E.set(e, e.style[n]), e.style[n] = "none";
205
+ }
206
+ }
207
+ function ee(e) {
208
+ if (U()) {
209
+ if (L !== "disabled") return;
210
+ L = "restoring", setTimeout(() => {
211
+ Z(() => {
212
+ if (L === "restoring") {
213
+ const n = V(e);
214
+ n.documentElement.style.webkitUserSelect === "none" && (n.documentElement.style.webkitUserSelect = Y || ""), Y = "", L = "default";
215
+ }
216
+ });
217
+ }, 300);
218
+ } else if ((e instanceof HTMLElement || e instanceof SVGElement) && e && E.has(e)) {
219
+ let n = E.get(e), i = "userSelect" in e.style ? "userSelect" : "webkitUserSelect";
220
+ e.style[i] === "none" && (e.style[i] = n), e.getAttribute("style") === "" && e.removeAttribute("style"), E.delete(e);
221
+ }
222
+ }
223
+ function te(e) {
224
+ let { onMoveStart: n, onMove: i, onMoveEnd: r } = e, t = K({
225
+ didMove: !1,
226
+ lastPosition: null,
227
+ id: null
228
+ }), { addGlobalListener: d, removeGlobalListener: c } = R(), s = I((a, p, b, l) => {
229
+ b === 0 && l === 0 || (t.current.didMove || (t.current.didMove = !0, n == null || n({
230
+ type: "movestart",
231
+ pointerType: p,
232
+ shiftKey: a.shiftKey,
233
+ metaKey: a.metaKey,
234
+ ctrlKey: a.ctrlKey,
235
+ altKey: a.altKey
236
+ })), i == null || i({
237
+ type: "move",
238
+ pointerType: p,
239
+ deltaX: b,
240
+ deltaY: l,
241
+ shiftKey: a.shiftKey,
242
+ metaKey: a.metaKey,
243
+ ctrlKey: a.ctrlKey,
244
+ altKey: a.altKey
245
+ }));
246
+ }), f = I((a, p) => {
247
+ ee(), t.current.didMove && (r == null || r({
248
+ type: "moveend",
249
+ pointerType: p,
250
+ shiftKey: a.shiftKey,
251
+ metaKey: a.metaKey,
252
+ ctrlKey: a.ctrlKey,
253
+ altKey: a.altKey
254
+ }));
255
+ });
256
+ return {
257
+ moveProps: z(() => {
258
+ let a = {}, p = () => {
259
+ _(), t.current.didMove = !1;
260
+ };
261
+ if (typeof PointerEvent > "u" && process.env.NODE_ENV === "test") {
262
+ let l = (o) => {
263
+ if (o.button === 0) {
264
+ var v, m, y, A;
265
+ s(o, "mouse", o.pageX - ((y = (v = t.current.lastPosition) === null || v === void 0 ? void 0 : v.pageX) !== null && y !== void 0 ? y : 0), o.pageY - ((A = (m = t.current.lastPosition) === null || m === void 0 ? void 0 : m.pageY) !== null && A !== void 0 ? A : 0)), t.current.lastPosition = {
266
+ pageX: o.pageX,
267
+ pageY: o.pageY
268
+ };
269
+ }
270
+ }, $ = (o) => {
271
+ o.button === 0 && (f(o, "mouse"), c(window, "mousemove", l, !1), c(window, "mouseup", $, !1));
272
+ };
273
+ a.onMouseDown = (o) => {
274
+ o.button === 0 && (p(), o.stopPropagation(), o.preventDefault(), t.current.lastPosition = {
275
+ pageX: o.pageX,
276
+ pageY: o.pageY
277
+ }, d(window, "mousemove", l, !1), d(window, "mouseup", $, !1));
278
+ };
279
+ let u = (o) => {
280
+ let v = [
281
+ ...o.changedTouches
282
+ ].findIndex(({ identifier: D }) => D === t.current.id);
283
+ if (v >= 0) {
284
+ var m, y;
285
+ let { pageX: D, pageY: B } = o.changedTouches[v];
286
+ var A, G;
287
+ s(o, "touch", D - ((A = (m = t.current.lastPosition) === null || m === void 0 ? void 0 : m.pageX) !== null && A !== void 0 ? A : 0), B - ((G = (y = t.current.lastPosition) === null || y === void 0 ? void 0 : y.pageY) !== null && G !== void 0 ? G : 0)), t.current.lastPosition = {
288
+ pageX: D,
289
+ pageY: B
290
+ };
291
+ }
292
+ }, w = (o) => {
293
+ [
294
+ ...o.changedTouches
295
+ ].findIndex(({ identifier: m }) => m === t.current.id) >= 0 && (f(o, "touch"), t.current.id = null, c(window, "touchmove", u), c(window, "touchend", w), c(window, "touchcancel", w));
296
+ };
297
+ a.onTouchStart = (o) => {
298
+ if (o.changedTouches.length === 0 || t.current.id != null) return;
299
+ let { pageX: v, pageY: m, identifier: y } = o.changedTouches[0];
300
+ p(), o.stopPropagation(), o.preventDefault(), t.current.lastPosition = {
301
+ pageX: v,
302
+ pageY: m
303
+ }, t.current.id = y, d(window, "touchmove", u, !1), d(window, "touchend", w, !1), d(window, "touchcancel", w, !1);
304
+ };
305
+ } else {
306
+ let l = (u) => {
307
+ if (u.pointerId === t.current.id) {
308
+ var w, o;
309
+ let y = u.pointerType || "mouse";
310
+ var v, m;
311
+ s(u, y, u.pageX - ((v = (w = t.current.lastPosition) === null || w === void 0 ? void 0 : w.pageX) !== null && v !== void 0 ? v : 0), u.pageY - ((m = (o = t.current.lastPosition) === null || o === void 0 ? void 0 : o.pageY) !== null && m !== void 0 ? m : 0)), t.current.lastPosition = {
312
+ pageX: u.pageX,
313
+ pageY: u.pageY
314
+ };
315
+ }
316
+ }, $ = (u) => {
317
+ if (u.pointerId === t.current.id) {
318
+ let w = u.pointerType || "mouse";
319
+ f(u, w), t.current.id = null, c(window, "pointermove", l, !1), c(window, "pointerup", $, !1), c(window, "pointercancel", $, !1);
320
+ }
321
+ };
322
+ a.onPointerDown = (u) => {
323
+ u.button === 0 && t.current.id == null && (p(), u.stopPropagation(), u.preventDefault(), t.current.lastPosition = {
324
+ pageX: u.pageX,
325
+ pageY: u.pageY
326
+ }, t.current.id = u.pointerId, d(window, "pointermove", l, !1), d(window, "pointerup", $, !1), d(window, "pointercancel", $, !1));
327
+ };
328
+ }
329
+ let b = (l, $, u) => {
330
+ p(), s(l, "keyboard", $, u), f(l, "keyboard");
331
+ };
332
+ return a.onKeyDown = (l) => {
333
+ switch (l.key) {
334
+ case "Left":
335
+ case "ArrowLeft":
336
+ l.preventDefault(), l.stopPropagation(), b(l, -1, 0);
337
+ break;
338
+ case "Right":
339
+ case "ArrowRight":
340
+ l.preventDefault(), l.stopPropagation(), b(l, 1, 0);
341
+ break;
342
+ case "Up":
343
+ case "ArrowUp":
344
+ l.preventDefault(), l.stopPropagation(), b(l, 0, -1);
345
+ break;
346
+ case "Down":
347
+ case "ArrowDown":
348
+ l.preventDefault(), l.stopPropagation(), b(l, 0, 1);
349
+ break;
350
+ }
351
+ }, a;
352
+ }, [
353
+ t,
354
+ d,
355
+ c,
356
+ s,
357
+ f
358
+ ])
359
+ };
360
+ }
361
+ function ae({ targetRef: e, isDisabled: n = !1 }) {
362
+ const i = K({ x: 0, y: 0 }), r = K({ dx: 0, dy: 0 }), t = K(null), d = () => {
363
+ const { dx: a, dy: p } = r.current;
364
+ (a !== 0 || p !== 0) && (i.current.x += a, i.current.y += p, r.current = { dx: 0, dy: 0 }, e != null && e.current && (e.current.style.transform = `translate(calc(-50% + ${i.current.x}px), calc(-50% + ${i.current.y}px))`)), t.current = requestAnimationFrame(d);
365
+ }, c = () => {
366
+ t.current === null && (t.current = requestAnimationFrame(d));
367
+ }, s = () => {
368
+ c();
369
+ }, f = (a) => {
370
+ n || (r.current.dx += a.deltaX, r.current.dy += a.deltaY);
371
+ }, { moveProps: g } = te({ onMoveStart: s, onMove: f });
372
+ return N(() => () => {
373
+ t.current && cancelAnimationFrame(t.current);
374
+ }, []), {
375
+ moveProps: {
376
+ ...g,
377
+ style: { cursor: n ? "default" : "move" }
378
+ }
379
+ };
380
+ }
381
+ export {
382
+ re as useConfirmationAlert,
383
+ ae as useDraggableSmooth,
384
+ oe as useModalHooks
385
+ };
386
+ //# sourceMappingURL=index.es.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.es.js","sources":["../src/hooks/use-modal.ts","../src/hooks/use-confirmation.ts","../node_modules/.pnpm/@react-aria+utils@3.29.1_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/@react-aria/utils/dist/useLayoutEffect.mjs","../node_modules/.pnpm/@react-aria+utils@3.29.1_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/@react-aria/utils/dist/useEffectEvent.mjs","../node_modules/.pnpm/@react-aria+utils@3.29.1_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/@react-aria/utils/dist/domHelpers.mjs","../node_modules/.pnpm/@react-aria+utils@3.29.1_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/@react-aria/utils/dist/platform.mjs","../node_modules/.pnpm/@react-aria+utils@3.29.1_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/@react-aria/utils/dist/runAfterTransition.mjs","../node_modules/.pnpm/@react-aria+utils@3.29.1_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/@react-aria/utils/dist/useGlobalListeners.mjs","../node_modules/.pnpm/@react-aria+interactions@3.25.3_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/@react-aria/interactions/dist/textSelection.mjs","../node_modules/.pnpm/@react-aria+interactions@3.25.3_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/@react-aria/interactions/dist/useMove.mjs","../src/hooks/use-draggable.ts"],"sourcesContent":["import { useCallback, useId, useState, useRef } from \"react\";\n\nexport type SizeModalInterface = \"smaller\" | \"small\" | \"medium\" | \"large\" | \"x-large\" | \"full\";\n\nexport interface UseModalType<T = any> {\n\tmodalId: string;\n\tisOpen: boolean;\n\tisVisibleModal: boolean;\n\tparamBody: T | null;\n\tshowModal: (params?: T, content?: React.ReactNode) => void;\n\tcloseModal: () => void;\n\tvisibleModal: () => void;\n\thiddenModal: () => void;\n\tupdateParamBody: (params: T) => void;\n\ttoggleModal: () => void;\n}\n\nexport function useModalHooks<T = any>(modalIdRef?: string): UseModalType<T> {\n\tconst [isOpen, setIsOpen] = useState(false);\n\tconst [isVisibleModal, setIsVisibleModal] = useState(false);\n\tconst [paramBody, setParamBody] = useState<T | null>(null);\n\n\tconst onOpenRef = useRef(() => {});\n\tconst onCloseRef = useRef(() => {});\n\tconst modalIdGenerated = useId();\n\tconst modalId = modalIdRef || `modal-${modalIdGenerated}`;\n\n\tconst showModal = useCallback((params?: T) => {\n\t\tif (params !== undefined) {\n\t\t\tsetParamBody(params);\n\t\t}\n\t\tsetIsOpen(true);\n\t\tsetIsVisibleModal(true);\n\t\tonOpenRef.current?.();\n\t}, []);\n\n\tconst closeModal = useCallback(() => {\n\t\tsetIsOpen(false);\n\t\tsetIsVisibleModal(false);\n\t\tonCloseRef.current?.();\n\t}, []);\n\n\tconst visibleModal = () => setIsVisibleModal(true);\n\tconst hiddenModal = () => setIsVisibleModal(false);\n\n\tconst updateParamBody = (params: T) => {\n\t\tsetParamBody(params);\n\t};\n\n\tconst toggleModal = () => {\n\t\tsetIsOpen((prev) => {\n\t\t\tconst next = !prev;\n\t\t\tif (next) onOpenRef.current?.();\n\t\t\telse onCloseRef.current?.();\n\t\t\treturn next;\n\t\t});\n\t};\n\n\treturn {\n\t\tmodalId,\n\t\tisOpen,\n\t\tisVisibleModal,\n\t\tparamBody,\n\t\tshowModal,\n\t\tcloseModal,\n\t\tvisibleModal,\n\t\thiddenModal,\n\t\tupdateParamBody,\n\t\ttoggleModal,\n\t};\n}\n","import { useState } from \"react\";\n\nexport interface ConfirmationAlertProps {\n\ttitle?: React.ReactNode;\n\tdescription?: React.ReactNode;\n\tbody?: React.ReactNode;\n\tisOpen: boolean;\n\tloading?: boolean;\n\tparams?: unknown;\n}\n\nconst defaultAlertState: ConfirmationAlertProps = {\n\ttitle: \"\",\n\tdescription: \"\",\n\tbody: null,\n\tisOpen: false,\n\tloading: false,\n\tparams: null,\n};\n\ntype ModalMap = Record<string, ConfirmationAlertProps>;\n\nexport const useConfirmationAlert = () => {\n\tconst [alert, setAlert] = useState<ConfirmationAlertProps>(defaultAlertState);\n\tconst [alerts, setAlerts] = useState<ModalMap>({});\n\n\tconst showAlert = (options: Partial<ConfirmationAlertProps>) => {\n\t\tsetAlert({\n\t\t\t...defaultAlertState,\n\t\t\t...options,\n\t\t\tisOpen: true,\n\t\t});\n\t};\n\n\tconst setAlertLoading = () => setAlert((prev) => ({ ...prev, loading: true }));\n\tconst hideAlert = () => setAlert(defaultAlertState);\n\n\tconst showModalByKey = (key: string, options: Partial<ConfirmationAlertProps>) => {\n\t\tsetAlerts((prev) => ({\n\t\t\t...prev,\n\t\t\t[key]: {\n\t\t\t\t...defaultAlertState,\n\t\t\t\t...options,\n\t\t\t\tisOpen: true,\n\t\t\t},\n\t\t}));\n\t};\n\n\tconst setModalLoadingByKey = (key: string) => {\n\t\tsetAlerts((prev) => ({\n\t\t\t...prev,\n\t\t\t[key]: { ...prev[key], loading: true },\n\t\t}));\n\t};\n\n\tconst hideModalByKey = (key: string) => {\n\t\tsetAlerts((prev) => ({\n\t\t\t...prev,\n\t\t\t[key]: defaultAlertState,\n\t\t}));\n\t};\n\n\treturn {\n\t\talert,\n\t\tshowAlert,\n\t\tsetAlertLoading,\n\t\thideAlert,\n\t\talerts,\n\t\tshowModalByKey,\n\t\tsetModalLoadingByKey,\n\t\thideModalByKey,\n\t};\n};\n","import $HgANd$react from \"react\";\n\n/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */ \nconst $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c = typeof document !== 'undefined' ? (0, $HgANd$react).useLayoutEffect : ()=>{};\n\n\nexport {$f0a04ccd8dbdd83b$export$e5c5a5f917a5871c as useLayoutEffect};\n//# sourceMappingURL=useLayoutEffect.module.js.map\n","import {useLayoutEffect as $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c} from \"./useLayoutEffect.mjs\";\nimport {useRef as $lmaYr$useRef, useCallback as $lmaYr$useCallback} from \"react\";\n\n/*\n * Copyright 2023 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */ \n\nfunction $8ae05eaa5c114e9c$export$7f54fc3180508a52(fn) {\n const ref = (0, $lmaYr$useRef)(null);\n (0, $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c)(()=>{\n ref.current = fn;\n }, [\n fn\n ]);\n // @ts-ignore\n return (0, $lmaYr$useCallback)((...args)=>{\n const f = ref.current;\n return f === null || f === void 0 ? void 0 : f(...args);\n }, []);\n}\n\n\nexport {$8ae05eaa5c114e9c$export$7f54fc3180508a52 as useEffectEvent};\n//# sourceMappingURL=useEffectEvent.module.js.map\n","const $431fbd86ca7dc216$export$b204af158042fbac = (el)=>{\n var _el_ownerDocument;\n return (_el_ownerDocument = el === null || el === void 0 ? void 0 : el.ownerDocument) !== null && _el_ownerDocument !== void 0 ? _el_ownerDocument : document;\n};\nconst $431fbd86ca7dc216$export$f21a1ffae260145a = (el)=>{\n if (el && 'window' in el && el.window === el) return el;\n const doc = $431fbd86ca7dc216$export$b204af158042fbac(el);\n return doc.defaultView || window;\n};\n/**\n * Type guard that checks if a value is a Node. Verifies the presence and type of the nodeType property.\n */ function $431fbd86ca7dc216$var$isNode(value) {\n return value !== null && typeof value === 'object' && 'nodeType' in value && typeof value.nodeType === 'number';\n}\nfunction $431fbd86ca7dc216$export$af51f0f06c0f328a(node) {\n return $431fbd86ca7dc216$var$isNode(node) && node.nodeType === Node.DOCUMENT_FRAGMENT_NODE && 'host' in node;\n}\n\n\nexport {$431fbd86ca7dc216$export$b204af158042fbac as getOwnerDocument, $431fbd86ca7dc216$export$f21a1ffae260145a as getOwnerWindow, $431fbd86ca7dc216$export$af51f0f06c0f328a as isShadowRoot};\n//# sourceMappingURL=domHelpers.module.js.map\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */ function $c87311424ea30a05$var$testUserAgent(re) {\n var _window_navigator_userAgentData;\n if (typeof window === 'undefined' || window.navigator == null) return false;\n return ((_window_navigator_userAgentData = window.navigator['userAgentData']) === null || _window_navigator_userAgentData === void 0 ? void 0 : _window_navigator_userAgentData.brands.some((brand)=>re.test(brand.brand))) || re.test(window.navigator.userAgent);\n}\nfunction $c87311424ea30a05$var$testPlatform(re) {\n var _window_navigator_userAgentData;\n return typeof window !== 'undefined' && window.navigator != null ? re.test(((_window_navigator_userAgentData = window.navigator['userAgentData']) === null || _window_navigator_userAgentData === void 0 ? void 0 : _window_navigator_userAgentData.platform) || window.navigator.platform) : false;\n}\nfunction $c87311424ea30a05$var$cached(fn) {\n if (process.env.NODE_ENV === 'test') return fn;\n let res = null;\n return ()=>{\n if (res == null) res = fn();\n return res;\n };\n}\nconst $c87311424ea30a05$export$9ac100e40613ea10 = $c87311424ea30a05$var$cached(function() {\n return $c87311424ea30a05$var$testPlatform(/^Mac/i);\n});\nconst $c87311424ea30a05$export$186c6964ca17d99 = $c87311424ea30a05$var$cached(function() {\n return $c87311424ea30a05$var$testPlatform(/^iPhone/i);\n});\nconst $c87311424ea30a05$export$7bef049ce92e4224 = $c87311424ea30a05$var$cached(function() {\n return $c87311424ea30a05$var$testPlatform(/^iPad/i) || // iPadOS 13 lies and says it's a Mac, but we can distinguish by detecting touch support.\n $c87311424ea30a05$export$9ac100e40613ea10() && navigator.maxTouchPoints > 1;\n});\nconst $c87311424ea30a05$export$fedb369cb70207f1 = $c87311424ea30a05$var$cached(function() {\n return $c87311424ea30a05$export$186c6964ca17d99() || $c87311424ea30a05$export$7bef049ce92e4224();\n});\nconst $c87311424ea30a05$export$e1865c3bedcd822b = $c87311424ea30a05$var$cached(function() {\n return $c87311424ea30a05$export$9ac100e40613ea10() || $c87311424ea30a05$export$fedb369cb70207f1();\n});\nconst $c87311424ea30a05$export$78551043582a6a98 = $c87311424ea30a05$var$cached(function() {\n return $c87311424ea30a05$var$testUserAgent(/AppleWebKit/i) && !$c87311424ea30a05$export$6446a186d09e379e();\n});\nconst $c87311424ea30a05$export$6446a186d09e379e = $c87311424ea30a05$var$cached(function() {\n return $c87311424ea30a05$var$testUserAgent(/Chrome/i);\n});\nconst $c87311424ea30a05$export$a11b0059900ceec8 = $c87311424ea30a05$var$cached(function() {\n return $c87311424ea30a05$var$testUserAgent(/Android/i);\n});\nconst $c87311424ea30a05$export$b7d78993b74f766d = $c87311424ea30a05$var$cached(function() {\n return $c87311424ea30a05$var$testUserAgent(/Firefox/i);\n});\n\n\nexport {$c87311424ea30a05$export$9ac100e40613ea10 as isMac, $c87311424ea30a05$export$186c6964ca17d99 as isIPhone, $c87311424ea30a05$export$7bef049ce92e4224 as isIPad, $c87311424ea30a05$export$fedb369cb70207f1 as isIOS, $c87311424ea30a05$export$e1865c3bedcd822b as isAppleDevice, $c87311424ea30a05$export$78551043582a6a98 as isWebKit, $c87311424ea30a05$export$6446a186d09e379e as isChrome, $c87311424ea30a05$export$a11b0059900ceec8 as isAndroid, $c87311424ea30a05$export$b7d78993b74f766d as isFirefox};\n//# sourceMappingURL=platform.module.js.map\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */ // We store a global list of elements that are currently transitioning,\n// mapped to a set of CSS properties that are transitioning for that element.\n// This is necessary rather than a simple count of transitions because of browser\n// bugs, e.g. Chrome sometimes fires both transitionend and transitioncancel rather\n// than one or the other. So we need to track what's actually transitioning so that\n// we can ignore these duplicate events.\nlet $bbed8b41f857bcc0$var$transitionsByElement = new Map();\n// A list of callbacks to call once there are no transitioning elements.\nlet $bbed8b41f857bcc0$var$transitionCallbacks = new Set();\nfunction $bbed8b41f857bcc0$var$setupGlobalEvents() {\n if (typeof window === 'undefined') return;\n function isTransitionEvent(event) {\n return 'propertyName' in event;\n }\n let onTransitionStart = (e)=>{\n if (!isTransitionEvent(e) || !e.target) return;\n // Add the transitioning property to the list for this element.\n let transitions = $bbed8b41f857bcc0$var$transitionsByElement.get(e.target);\n if (!transitions) {\n transitions = new Set();\n $bbed8b41f857bcc0$var$transitionsByElement.set(e.target, transitions);\n // The transitioncancel event must be registered on the element itself, rather than as a global\n // event. This enables us to handle when the node is deleted from the document while it is transitioning.\n // In that case, the cancel event would have nowhere to bubble to so we need to handle it directly.\n e.target.addEventListener('transitioncancel', onTransitionEnd, {\n once: true\n });\n }\n transitions.add(e.propertyName);\n };\n let onTransitionEnd = (e)=>{\n if (!isTransitionEvent(e) || !e.target) return;\n // Remove property from list of transitioning properties.\n let properties = $bbed8b41f857bcc0$var$transitionsByElement.get(e.target);\n if (!properties) return;\n properties.delete(e.propertyName);\n // If empty, remove transitioncancel event, and remove the element from the list of transitioning elements.\n if (properties.size === 0) {\n e.target.removeEventListener('transitioncancel', onTransitionEnd);\n $bbed8b41f857bcc0$var$transitionsByElement.delete(e.target);\n }\n // If no transitioning elements, call all of the queued callbacks.\n if ($bbed8b41f857bcc0$var$transitionsByElement.size === 0) {\n for (let cb of $bbed8b41f857bcc0$var$transitionCallbacks)cb();\n $bbed8b41f857bcc0$var$transitionCallbacks.clear();\n }\n };\n document.body.addEventListener('transitionrun', onTransitionStart);\n document.body.addEventListener('transitionend', onTransitionEnd);\n}\nif (typeof document !== 'undefined') {\n if (document.readyState !== 'loading') $bbed8b41f857bcc0$var$setupGlobalEvents();\n else document.addEventListener('DOMContentLoaded', $bbed8b41f857bcc0$var$setupGlobalEvents);\n}\n/**\n * Cleans up any elements that are no longer in the document.\n * This is necessary because we can't rely on transitionend events to fire\n * for elements that are removed from the document while transitioning.\n */ function $bbed8b41f857bcc0$var$cleanupDetachedElements() {\n for (const [eventTarget] of $bbed8b41f857bcc0$var$transitionsByElement)// Similar to `eventTarget instanceof Element && !eventTarget.isConnected`, but avoids\n // the explicit instanceof check, since it may be different in different contexts.\n if ('isConnected' in eventTarget && !eventTarget.isConnected) $bbed8b41f857bcc0$var$transitionsByElement.delete(eventTarget);\n}\nfunction $bbed8b41f857bcc0$export$24490316f764c430(fn) {\n // Wait one frame to see if an animation starts, e.g. a transition on mount.\n requestAnimationFrame(()=>{\n $bbed8b41f857bcc0$var$cleanupDetachedElements();\n // If no transitions are running, call the function immediately.\n // Otherwise, add it to a list of callbacks to run at the end of the animation.\n if ($bbed8b41f857bcc0$var$transitionsByElement.size === 0) fn();\n else $bbed8b41f857bcc0$var$transitionCallbacks.add(fn);\n });\n}\n\n\nexport {$bbed8b41f857bcc0$export$24490316f764c430 as runAfterTransition};\n//# sourceMappingURL=runAfterTransition.module.js.map\n","import {useRef as $lPAwt$useRef, useCallback as $lPAwt$useCallback, useEffect as $lPAwt$useEffect} from \"react\";\n\n/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */ \nfunction $03deb23ff14920c4$export$4eaf04e54aa8eed6() {\n let globalListeners = (0, $lPAwt$useRef)(new Map());\n let addGlobalListener = (0, $lPAwt$useCallback)((eventTarget, type, listener, options)=>{\n // Make sure we remove the listener after it is called with the `once` option.\n let fn = (options === null || options === void 0 ? void 0 : options.once) ? (...args)=>{\n globalListeners.current.delete(listener);\n listener(...args);\n } : listener;\n globalListeners.current.set(listener, {\n type: type,\n eventTarget: eventTarget,\n fn: fn,\n options: options\n });\n eventTarget.addEventListener(type, fn, options);\n }, []);\n let removeGlobalListener = (0, $lPAwt$useCallback)((eventTarget, type, listener, options)=>{\n var _globalListeners_current_get;\n let fn = ((_globalListeners_current_get = globalListeners.current.get(listener)) === null || _globalListeners_current_get === void 0 ? void 0 : _globalListeners_current_get.fn) || listener;\n eventTarget.removeEventListener(type, fn, options);\n globalListeners.current.delete(listener);\n }, []);\n let removeAllGlobalListeners = (0, $lPAwt$useCallback)(()=>{\n globalListeners.current.forEach((value, key)=>{\n removeGlobalListener(value.eventTarget, value.type, key, value.options);\n });\n }, [\n removeGlobalListener\n ]);\n (0, $lPAwt$useEffect)(()=>{\n return removeAllGlobalListeners;\n }, [\n removeAllGlobalListeners\n ]);\n return {\n addGlobalListener: addGlobalListener,\n removeGlobalListener: removeGlobalListener,\n removeAllGlobalListeners: removeAllGlobalListeners\n };\n}\n\n\nexport {$03deb23ff14920c4$export$4eaf04e54aa8eed6 as useGlobalListeners};\n//# sourceMappingURL=useGlobalListeners.module.js.map\n","import {isIOS as $7R18e$isIOS, getOwnerDocument as $7R18e$getOwnerDocument, runAfterTransition as $7R18e$runAfterTransition} from \"@react-aria/utils\";\n\n/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */ \n// Note that state only matters here for iOS. Non-iOS gets user-select: none applied to the target element\n// rather than at the document level so we just need to apply/remove user-select: none for each pressed element individually\nlet $14c0b72509d70225$var$state = 'default';\nlet $14c0b72509d70225$var$savedUserSelect = '';\nlet $14c0b72509d70225$var$modifiedElementMap = new WeakMap();\nfunction $14c0b72509d70225$export$16a4697467175487(target) {\n if ((0, $7R18e$isIOS)()) {\n if ($14c0b72509d70225$var$state === 'default') {\n const documentObject = (0, $7R18e$getOwnerDocument)(target);\n $14c0b72509d70225$var$savedUserSelect = documentObject.documentElement.style.webkitUserSelect;\n documentObject.documentElement.style.webkitUserSelect = 'none';\n }\n $14c0b72509d70225$var$state = 'disabled';\n } else if (target instanceof HTMLElement || target instanceof SVGElement) {\n // If not iOS, store the target's original user-select and change to user-select: none\n // Ignore state since it doesn't apply for non iOS\n let property = 'userSelect' in target.style ? 'userSelect' : 'webkitUserSelect';\n $14c0b72509d70225$var$modifiedElementMap.set(target, target.style[property]);\n target.style[property] = 'none';\n }\n}\nfunction $14c0b72509d70225$export$b0d6fa1ab32e3295(target) {\n if ((0, $7R18e$isIOS)()) {\n // If the state is already default, there's nothing to do.\n // If it is restoring, then there's no need to queue a second restore.\n if ($14c0b72509d70225$var$state !== 'disabled') return;\n $14c0b72509d70225$var$state = 'restoring';\n // There appears to be a delay on iOS where selection still might occur\n // after pointer up, so wait a bit before removing user-select.\n setTimeout(()=>{\n // Wait for any CSS transitions to complete so we don't recompute style\n // for the whole page in the middle of the animation and cause jank.\n (0, $7R18e$runAfterTransition)(()=>{\n // Avoid race conditions\n if ($14c0b72509d70225$var$state === 'restoring') {\n const documentObject = (0, $7R18e$getOwnerDocument)(target);\n if (documentObject.documentElement.style.webkitUserSelect === 'none') documentObject.documentElement.style.webkitUserSelect = $14c0b72509d70225$var$savedUserSelect || '';\n $14c0b72509d70225$var$savedUserSelect = '';\n $14c0b72509d70225$var$state = 'default';\n }\n });\n }, 300);\n } else if (target instanceof HTMLElement || target instanceof SVGElement) // If not iOS, restore the target's original user-select if any\n // Ignore state since it doesn't apply for non iOS\n {\n if (target && $14c0b72509d70225$var$modifiedElementMap.has(target)) {\n let targetOldUserSelect = $14c0b72509d70225$var$modifiedElementMap.get(target);\n let property = 'userSelect' in target.style ? 'userSelect' : 'webkitUserSelect';\n if (target.style[property] === 'none') target.style[property] = targetOldUserSelect;\n if (target.getAttribute('style') === '') target.removeAttribute('style');\n $14c0b72509d70225$var$modifiedElementMap.delete(target);\n }\n }\n}\n\n\nexport {$14c0b72509d70225$export$16a4697467175487 as disableTextSelection, $14c0b72509d70225$export$b0d6fa1ab32e3295 as restoreTextSelection};\n//# sourceMappingURL=textSelection.module.js.map\n","import {disableTextSelection as $14c0b72509d70225$export$16a4697467175487, restoreTextSelection as $14c0b72509d70225$export$b0d6fa1ab32e3295} from \"./textSelection.mjs\";\nimport {useRef as $5GN7j$useRef, useMemo as $5GN7j$useMemo} from \"react\";\nimport {useGlobalListeners as $5GN7j$useGlobalListeners, useEffectEvent as $5GN7j$useEffectEvent} from \"@react-aria/utils\";\n\n/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */ \n\n\nfunction $e8a7022cf87cba2a$export$36da96379f79f245(props) {\n let { onMoveStart: onMoveStart, onMove: onMove, onMoveEnd: onMoveEnd } = props;\n let state = (0, $5GN7j$useRef)({\n didMove: false,\n lastPosition: null,\n id: null\n });\n let { addGlobalListener: addGlobalListener, removeGlobalListener: removeGlobalListener } = (0, $5GN7j$useGlobalListeners)();\n let move = (0, $5GN7j$useEffectEvent)((originalEvent, pointerType, deltaX, deltaY)=>{\n if (deltaX === 0 && deltaY === 0) return;\n if (!state.current.didMove) {\n state.current.didMove = true;\n onMoveStart === null || onMoveStart === void 0 ? void 0 : onMoveStart({\n type: 'movestart',\n pointerType: pointerType,\n shiftKey: originalEvent.shiftKey,\n metaKey: originalEvent.metaKey,\n ctrlKey: originalEvent.ctrlKey,\n altKey: originalEvent.altKey\n });\n }\n onMove === null || onMove === void 0 ? void 0 : onMove({\n type: 'move',\n pointerType: pointerType,\n deltaX: deltaX,\n deltaY: deltaY,\n shiftKey: originalEvent.shiftKey,\n metaKey: originalEvent.metaKey,\n ctrlKey: originalEvent.ctrlKey,\n altKey: originalEvent.altKey\n });\n });\n let end = (0, $5GN7j$useEffectEvent)((originalEvent, pointerType)=>{\n (0, $14c0b72509d70225$export$b0d6fa1ab32e3295)();\n if (state.current.didMove) onMoveEnd === null || onMoveEnd === void 0 ? void 0 : onMoveEnd({\n type: 'moveend',\n pointerType: pointerType,\n shiftKey: originalEvent.shiftKey,\n metaKey: originalEvent.metaKey,\n ctrlKey: originalEvent.ctrlKey,\n altKey: originalEvent.altKey\n });\n });\n let moveProps = (0, $5GN7j$useMemo)(()=>{\n let moveProps = {};\n let start = ()=>{\n (0, $14c0b72509d70225$export$16a4697467175487)();\n state.current.didMove = false;\n };\n if (typeof PointerEvent === 'undefined' && process.env.NODE_ENV === 'test') {\n let onMouseMove = (e)=>{\n if (e.button === 0) {\n var _state_current_lastPosition, _state_current_lastPosition1;\n var _state_current_lastPosition_pageX, _state_current_lastPosition_pageY;\n move(e, 'mouse', e.pageX - ((_state_current_lastPosition_pageX = (_state_current_lastPosition = state.current.lastPosition) === null || _state_current_lastPosition === void 0 ? void 0 : _state_current_lastPosition.pageX) !== null && _state_current_lastPosition_pageX !== void 0 ? _state_current_lastPosition_pageX : 0), e.pageY - ((_state_current_lastPosition_pageY = (_state_current_lastPosition1 = state.current.lastPosition) === null || _state_current_lastPosition1 === void 0 ? void 0 : _state_current_lastPosition1.pageY) !== null && _state_current_lastPosition_pageY !== void 0 ? _state_current_lastPosition_pageY : 0));\n state.current.lastPosition = {\n pageX: e.pageX,\n pageY: e.pageY\n };\n }\n };\n let onMouseUp = (e)=>{\n if (e.button === 0) {\n end(e, 'mouse');\n removeGlobalListener(window, 'mousemove', onMouseMove, false);\n removeGlobalListener(window, 'mouseup', onMouseUp, false);\n }\n };\n moveProps.onMouseDown = (e)=>{\n if (e.button === 0) {\n start();\n e.stopPropagation();\n e.preventDefault();\n state.current.lastPosition = {\n pageX: e.pageX,\n pageY: e.pageY\n };\n addGlobalListener(window, 'mousemove', onMouseMove, false);\n addGlobalListener(window, 'mouseup', onMouseUp, false);\n }\n };\n let onTouchMove = (e)=>{\n let touch = [\n ...e.changedTouches\n ].findIndex(({ identifier: identifier })=>identifier === state.current.id);\n if (touch >= 0) {\n var _state_current_lastPosition, _state_current_lastPosition1;\n let { pageX: pageX, pageY: pageY } = e.changedTouches[touch];\n var _state_current_lastPosition_pageX, _state_current_lastPosition_pageY;\n move(e, 'touch', pageX - ((_state_current_lastPosition_pageX = (_state_current_lastPosition = state.current.lastPosition) === null || _state_current_lastPosition === void 0 ? void 0 : _state_current_lastPosition.pageX) !== null && _state_current_lastPosition_pageX !== void 0 ? _state_current_lastPosition_pageX : 0), pageY - ((_state_current_lastPosition_pageY = (_state_current_lastPosition1 = state.current.lastPosition) === null || _state_current_lastPosition1 === void 0 ? void 0 : _state_current_lastPosition1.pageY) !== null && _state_current_lastPosition_pageY !== void 0 ? _state_current_lastPosition_pageY : 0));\n state.current.lastPosition = {\n pageX: pageX,\n pageY: pageY\n };\n }\n };\n let onTouchEnd = (e)=>{\n let touch = [\n ...e.changedTouches\n ].findIndex(({ identifier: identifier })=>identifier === state.current.id);\n if (touch >= 0) {\n end(e, 'touch');\n state.current.id = null;\n removeGlobalListener(window, 'touchmove', onTouchMove);\n removeGlobalListener(window, 'touchend', onTouchEnd);\n removeGlobalListener(window, 'touchcancel', onTouchEnd);\n }\n };\n moveProps.onTouchStart = (e)=>{\n if (e.changedTouches.length === 0 || state.current.id != null) return;\n let { pageX: pageX, pageY: pageY, identifier: identifier } = e.changedTouches[0];\n start();\n e.stopPropagation();\n e.preventDefault();\n state.current.lastPosition = {\n pageX: pageX,\n pageY: pageY\n };\n state.current.id = identifier;\n addGlobalListener(window, 'touchmove', onTouchMove, false);\n addGlobalListener(window, 'touchend', onTouchEnd, false);\n addGlobalListener(window, 'touchcancel', onTouchEnd, false);\n };\n } else {\n let onPointerMove = (e)=>{\n if (e.pointerId === state.current.id) {\n var _state_current_lastPosition, _state_current_lastPosition1;\n let pointerType = e.pointerType || 'mouse';\n var _state_current_lastPosition_pageX, _state_current_lastPosition_pageY;\n // Problems with PointerEvent#movementX/movementY:\n // 1. it is always 0 on macOS Safari.\n // 2. On Chrome Android, it's scaled by devicePixelRatio, but not on Chrome macOS\n move(e, pointerType, e.pageX - ((_state_current_lastPosition_pageX = (_state_current_lastPosition = state.current.lastPosition) === null || _state_current_lastPosition === void 0 ? void 0 : _state_current_lastPosition.pageX) !== null && _state_current_lastPosition_pageX !== void 0 ? _state_current_lastPosition_pageX : 0), e.pageY - ((_state_current_lastPosition_pageY = (_state_current_lastPosition1 = state.current.lastPosition) === null || _state_current_lastPosition1 === void 0 ? void 0 : _state_current_lastPosition1.pageY) !== null && _state_current_lastPosition_pageY !== void 0 ? _state_current_lastPosition_pageY : 0));\n state.current.lastPosition = {\n pageX: e.pageX,\n pageY: e.pageY\n };\n }\n };\n let onPointerUp = (e)=>{\n if (e.pointerId === state.current.id) {\n let pointerType = e.pointerType || 'mouse';\n end(e, pointerType);\n state.current.id = null;\n removeGlobalListener(window, 'pointermove', onPointerMove, false);\n removeGlobalListener(window, 'pointerup', onPointerUp, false);\n removeGlobalListener(window, 'pointercancel', onPointerUp, false);\n }\n };\n moveProps.onPointerDown = (e)=>{\n if (e.button === 0 && state.current.id == null) {\n start();\n e.stopPropagation();\n e.preventDefault();\n state.current.lastPosition = {\n pageX: e.pageX,\n pageY: e.pageY\n };\n state.current.id = e.pointerId;\n addGlobalListener(window, 'pointermove', onPointerMove, false);\n addGlobalListener(window, 'pointerup', onPointerUp, false);\n addGlobalListener(window, 'pointercancel', onPointerUp, false);\n }\n };\n }\n let triggerKeyboardMove = (e, deltaX, deltaY)=>{\n start();\n move(e, 'keyboard', deltaX, deltaY);\n end(e, 'keyboard');\n };\n moveProps.onKeyDown = (e)=>{\n switch(e.key){\n case 'Left':\n case 'ArrowLeft':\n e.preventDefault();\n e.stopPropagation();\n triggerKeyboardMove(e, -1, 0);\n break;\n case 'Right':\n case 'ArrowRight':\n e.preventDefault();\n e.stopPropagation();\n triggerKeyboardMove(e, 1, 0);\n break;\n case 'Up':\n case 'ArrowUp':\n e.preventDefault();\n e.stopPropagation();\n triggerKeyboardMove(e, 0, -1);\n break;\n case 'Down':\n case 'ArrowDown':\n e.preventDefault();\n e.stopPropagation();\n triggerKeyboardMove(e, 0, 1);\n break;\n }\n };\n return moveProps;\n }, [\n state,\n addGlobalListener,\n removeGlobalListener,\n move,\n end\n ]);\n return {\n moveProps: moveProps\n };\n}\n\n\nexport {$e8a7022cf87cba2a$export$36da96379f79f245 as useMove};\n//# sourceMappingURL=useMove.module.js.map\n","import { useRef, useEffect } from \"react\";\nimport { useMove } from \"@react-aria/interactions\";\n\ninterface UseDraggableSmoothProps {\n\ttargetRef: React.RefObject<HTMLElement>;\n\tisDisabled?: boolean;\n}\n\nexport function useDraggableSmooth({ targetRef, isDisabled = false }: UseDraggableSmoothProps) {\n\tconst position = useRef({ x: 0, y: 0 });\n\tconst pending = useRef({ dx: 0, dy: 0 });\n\tconst frame = useRef<number | null>(null);\n\n\tconst update = () => {\n\t\tconst { dx, dy } = pending.current;\n\t\tif (dx !== 0 || dy !== 0) {\n\t\t\tposition.current.x += dx;\n\t\t\tposition.current.y += dy;\n\t\t\tpending.current = { dx: 0, dy: 0 };\n\n\t\t\tif (targetRef?.current) {\n\t\t\t\ttargetRef.current.style.transform = `translate(calc(-50% + ${position.current.x}px), calc(-50% + ${position.current.y}px))`;\n\t\t\t}\n\t\t}\n\t\tframe.current = requestAnimationFrame(update);\n\t};\n\n\tconst startLoop = () => {\n\t\tif (frame.current === null) {\n\t\t\tframe.current = requestAnimationFrame(update);\n\t\t}\n\t};\n\n\tconst onMoveStart = () => {\n\t\tstartLoop();\n\t};\n\n\tconst onMove = (e: any) => {\n\t\tif (isDisabled) return;\n\t\tpending.current.dx += e.deltaX;\n\t\tpending.current.dy += e.deltaY;\n\t};\n\n\tconst { moveProps } = useMove({ onMoveStart, onMove });\n\n\tuseEffect(() => {\n\t\treturn () => {\n\t\t\tif (frame.current) cancelAnimationFrame(frame.current);\n\t\t};\n\t}, []);\n\n\treturn {\n\t\tmoveProps: {\n\t\t\t...moveProps,\n\t\t\tstyle: { cursor: isDisabled ? \"default\" : \"move\" },\n\t\t},\n\t};\n}\n"],"names":["useModalHooks","modalIdRef","isOpen","setIsOpen","useState","isVisibleModal","setIsVisibleModal","paramBody","setParamBody","onOpenRef","useRef","onCloseRef","modalIdGenerated","useId","modalId","showModal","useCallback","params","_a","closeModal","prev","next","defaultAlertState","useConfirmationAlert","alert","setAlert","alerts","setAlerts","options","key","$f0a04ccd8dbdd83b$export$e5c5a5f917a5871c","$HgANd$react","$8ae05eaa5c114e9c$export$7f54fc3180508a52","fn","ref","$lmaYr$useRef","$lmaYr$useCallback","args","f","$431fbd86ca7dc216$export$b204af158042fbac","el","_el_ownerDocument","$c87311424ea30a05$var$testUserAgent","re","_window_navigator_userAgentData","brand","$c87311424ea30a05$var$testPlatform","$c87311424ea30a05$var$cached","res","$c87311424ea30a05$export$9ac100e40613ea10","$c87311424ea30a05$export$186c6964ca17d99","$c87311424ea30a05$export$7bef049ce92e4224","$c87311424ea30a05$export$fedb369cb70207f1","$c87311424ea30a05$export$6446a186d09e379e","$bbed8b41f857bcc0$var$transitionsByElement","$bbed8b41f857bcc0$var$transitionCallbacks","$bbed8b41f857bcc0$var$setupGlobalEvents","isTransitionEvent","event","onTransitionStart","e","transitions","onTransitionEnd","properties","cb","$bbed8b41f857bcc0$var$cleanupDetachedElements","eventTarget","$bbed8b41f857bcc0$export$24490316f764c430","$03deb23ff14920c4$export$4eaf04e54aa8eed6","globalListeners","$lPAwt$useRef","addGlobalListener","$lPAwt$useCallback","type","listener","removeGlobalListener","_globalListeners_current_get","removeAllGlobalListeners","value","$lPAwt$useEffect","$14c0b72509d70225$var$state","$14c0b72509d70225$var$savedUserSelect","$14c0b72509d70225$var$modifiedElementMap","$14c0b72509d70225$export$16a4697467175487","target","$7R18e$isIOS","documentObject","$7R18e$getOwnerDocument","property","$14c0b72509d70225$export$b0d6fa1ab32e3295","$7R18e$runAfterTransition","targetOldUserSelect","$e8a7022cf87cba2a$export$36da96379f79f245","props","onMoveStart","onMove","onMoveEnd","state","$5GN7j$useRef","$5GN7j$useGlobalListeners","move","$5GN7j$useEffectEvent","originalEvent","pointerType","deltaX","deltaY","end","$5GN7j$useMemo","moveProps","start","onMouseMove","_state_current_lastPosition","_state_current_lastPosition1","_state_current_lastPosition_pageX","_state_current_lastPosition_pageY","onMouseUp","onTouchMove","touch","identifier","pageX","pageY","onTouchEnd","onPointerMove","onPointerUp","triggerKeyboardMove","useDraggableSmooth","targetRef","isDisabled","position","pending","frame","update","dx","dy","startLoop","useMove","useEffect"],"mappings":";AAiBO,SAASA,GAAuBC,GAAsC;AAC5E,QAAM,CAACC,GAAQC,CAAS,IAAIC,EAAS,EAAK,GACpC,CAACC,GAAgBC,CAAiB,IAAIF,EAAS,EAAK,GACpD,CAACG,GAAWC,CAAY,IAAIJ,EAAmB,IAAI,GAEnDK,IAAYC,EAAO,MAAM;AAAA,EAAA,CAAE,GAC3BC,IAAaD,EAAO,MAAM;AAAA,EAAA,CAAE,GAC5BE,IAAmBC,EAAM,GACzBC,IAAUb,KAAc,SAASW,CAAgB,IAEjDG,IAAYC,EAAY,CAACC,MAAe;;AAC7C,IAAIA,MAAW,UACdT,EAAaS,CAAM,GAEpBd,EAAU,EAAI,GACdG,EAAkB,EAAI,IACtBY,IAAAT,EAAU,YAAV,QAAAS,EAAA,KAAA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AQ;AACvB,KAAAG,MAAO,KAAKC,MAAO,OACtBL,EAAS,QAAQ,KAAKI,GACtBJ,EAAS,QAAQ,KAAKK,GACtBJ,EAAQ,UAAU,EAAE,IAAI,GAAG,IAAI,EAAE,GAE7BH,KAAA,QAAAA,EAAW,YACJA,EAAA,QAAQ,MAAM,YAAY,yBAAyBE,EAAS,QAAQ,CAAC,oBAAoBA,EAAS,QAAQ,CAAC,UAGjHE,EAAA,UAAU,sBAAsBC,CAAM;AAAA,EAC7C,GAEMG,IAAY,MAAM;AACnB,IAAAJ,EAAM,YAAY,SACfA,EAAA,UAAU,sBAAsBC,CAAM;AAAA,EAE9C,GAEMrC,IAAc,MAAM;AACf,IAAAwC,EAAA;AAAA,EACX,GAEMvC,IAAS,CAACnC,MAAW;AAC1B,IAAImE,MACIE,EAAA,QAAQ,MAAMrE,EAAE,QAChBqE,EAAA,QAAQ,MAAMrE,EAAE;AAAA,EACzB,GAEM,EAAE,WAAAgD,EAAU,IAAI2B,GAAQ,EAAE,aAAAzC,GAAa,QAAAC,GAAQ;AAErD,SAAAyC,EAAU,MACF,MAAM;AACZ,IAAIN,EAAM,WAA8B,qBAAAA,EAAM,OAAO;AAAA,EACtD,GACE,EAAE,GAEE;AAAA,IACN,WAAW;AAAA,MACV,GAAGtB;AAAA,MACH,OAAO,EAAE,QAAQmB,IAAa,YAAY,OAAO;AAAA,IAAA;AAAA,EAEnD;AACD;","x_google_ignoreList":[2,3,4,5,6,7,8,9]}
@@ -0,0 +1,21 @@
1
+ import { TV } from 'tailwind-variants';
2
+ export declare const COMMON_UNITS: string[];
3
+ export declare const twMergeConfig: {
4
+ theme: {
5
+ opacity: string[];
6
+ spacing: string[];
7
+ borderWidth: string[];
8
+ borderRadius: string[];
9
+ };
10
+ classGroups: {
11
+ shadow: {
12
+ shadow: string[];
13
+ }[];
14
+ "font-size": {
15
+ text: string[];
16
+ }[];
17
+ "bg-image": string[];
18
+ };
19
+ };
20
+ export declare const tv: TV;
21
+ //# sourceMappingURL=tv.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tv.d.ts","sourceRoot":"","sources":["../../src/lib/tv.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgB,KAAK,EAAE,EAAE,MAAM,mBAAmB,CAAC;AAE1D,eAAO,MAAM,YAAY,UAA+B,CAAC;AAEzD,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;CAmBzB,CAAC;AAGF,eAAO,MAAM,EAAE,EAAE,EAed,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { ClassValue } from 'clsx';
2
+ export declare function cn(...inputs: ClassValue[]): string;
3
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/lib/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,UAAU,EAAE,MAAM,MAAM,CAAA;AAG5C,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,UAEzC"}
@@ -0,0 +1 @@
1
+ .react-calendar{width:350px;max-width:100%;background:#fff;border:1px solid #a0a096;font-family:Arial,Helvetica,sans-serif;line-height:1.125em}.react-calendar--doubleView{width:700px}.react-calendar--doubleView .react-calendar__viewContainer{display:flex;margin:-.5em}.react-calendar--doubleView .react-calendar__viewContainer>*{width:50%;margin:.5em}.react-calendar,.react-calendar *,.react-calendar *:before,.react-calendar *:after{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.react-calendar button{margin:0;border:0;outline:none}.react-calendar button:enabled:hover{cursor:pointer}.react-calendar__navigation{display:flex;height:44px;margin-bottom:1em}.react-calendar__navigation button{min-width:44px;background:none}.react-calendar__navigation button:disabled{background-color:#f0f0f0}.react-calendar__navigation button:enabled:hover,.react-calendar__navigation button:enabled:focus{background-color:#e6e6e6}.react-calendar__month-view__weekdays{text-align:center;text-transform:uppercase;font:inherit;font-size:.75em;font-weight:700}.react-calendar__month-view__weekdays__weekday{padding:.5em}.react-calendar__month-view__weekNumbers .react-calendar__tile{display:flex;align-items:center;justify-content:center;font:inherit;font-size:.75em;font-weight:700}.react-calendar__month-view__days__day--weekend{color:#d10000}.react-calendar__month-view__days__day--neighboringMonth,.react-calendar__decade-view__years__year--neighboringDecade,.react-calendar__century-view__decades__decade--neighboringCentury{color:#757575}.react-calendar__year-view .react-calendar__tile,.react-calendar__decade-view .react-calendar__tile,.react-calendar__century-view .react-calendar__tile{padding:2em .5em}.react-calendar__tile{max-width:100%;padding:10px 6.6667px;background:none;text-align:center;font:inherit;font-size:.833em}.react-calendar__tile:disabled{background-color:#f0f0f0;color:#ababab}.react-calendar__month-view__days__day--neighboringMonth:disabled,.react-calendar__decade-view__years__year--neighboringDecade:disabled,.react-calendar__century-view__decades__decade--neighboringCentury:disabled{color:#cdcdcd}.react-calendar__tile:enabled:hover,.react-calendar__tile:enabled:focus{background-color:#e6e6e6}.react-calendar__tile--now{background:#ffff76}.react-calendar__tile--now:enabled:hover,.react-calendar__tile--now:enabled:focus{background:#ffffa9}.react-calendar__tile--hasActive{background:#76baff}.react-calendar__tile--hasActive:enabled:hover,.react-calendar__tile--hasActive:enabled:focus{background:#a9d4ff}.react-calendar__tile--active{background:#006edc;color:#fff}.react-calendar__tile--active:enabled:hover,.react-calendar__tile--active:enabled:focus{background:#1087ff}.react-calendar--selectRange .react-calendar__tile--hover{background-color:#e6e6e6}.react-date-picker{display:inline-flex;position:relative}.react-date-picker,.react-date-picker *,.react-date-picker *:before,.react-date-picker *:after{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.react-date-picker--disabled{background-color:#f0f0f0;color:#6d6d6d}.react-date-picker__wrapper{display:flex;flex-grow:1;flex-shrink:0;border:thin solid gray}.react-date-picker__inputGroup{min-width:calc((4px * 3) + .54em * 8 + .217em * 2);flex-grow:1;padding:0 2px;box-sizing:content-box}.react-date-picker__inputGroup__divider{padding:1px 0;white-space:pre}.react-date-picker__inputGroup__divider,.react-date-picker__inputGroup__leadingZero{display:inline-block;font:inherit}.react-date-picker__inputGroup__input{min-width:.54em;height:100%;position:relative;padding:0 1px;border:0;background:none;color:currentColor;font:inherit;box-sizing:content-box;-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield}.react-date-picker__inputGroup__input::-webkit-outer-spin-button,.react-date-picker__inputGroup__input::-webkit-inner-spin-button{-webkit-appearance:none;-moz-appearance:none;appearance:none;margin:0}.react-date-picker__inputGroup__input:invalid{background:#ff00001a}.react-date-picker__inputGroup__input--hasLeadingZero{margin-left:-.54em;padding-left:calc(1px + .54em)}.react-date-picker__button{border:0;background:transparent;padding:4px 6px}.react-date-picker__button:enabled{cursor:pointer}.react-date-picker__button:enabled:hover .react-date-picker__button__icon,.react-date-picker__button:enabled:focus .react-date-picker__button__icon{stroke:#0078d7}.react-date-picker__button:disabled .react-date-picker__button__icon{stroke:#6d6d6d}.react-date-picker__button svg{display:inherit}.react-date-picker__calendar{width:350px;max-width:100vw;z-index:1}.react-date-picker__calendar--closed{display:none}.react-date-picker__calendar .react-calendar{border-width:thin}.react-daterange-picker{display:inline-flex;position:relative}.react-daterange-picker,.react-daterange-picker *,.react-daterange-picker *:before,.react-daterange-picker *:after{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.react-daterange-picker--disabled{background-color:#f0f0f0;color:#6d6d6d}.react-daterange-picker__wrapper{display:flex;flex-grow:1;flex-shrink:0;align-items:center;border:thin solid gray}.react-daterange-picker__inputGroup{min-width:calc((4px * 3) + .54em * 8 + .217em * 2);height:100%;flex-grow:1;padding:0 2px;box-sizing:content-box}.react-daterange-picker__inputGroup__divider{padding:1px 0;white-space:pre}.react-daterange-picker__inputGroup__divider,.react-daterange-picker__inputGroup__leadingZero{display:inline-block;font:inherit}.react-daterange-picker__inputGroup__input{min-width:.54em;height:100%;position:relative;padding:0 1px;border:0;background:none;color:currentColor;font:inherit;box-sizing:content-box;-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield}.react-daterange-picker__inputGroup__input::-webkit-outer-spin-button,.react-daterange-picker__inputGroup__input::-webkit-inner-spin-button{-webkit-appearance:none;-moz-appearance:none;appearance:none;margin:0}.react-daterange-picker__inputGroup__input:invalid{background:#ff00001a}.react-daterange-picker__inputGroup__input--hasLeadingZero{margin-left:-.54em;padding-left:calc(1px + .54em)}.react-daterange-picker__button{border:0;background:transparent;padding:4px 6px}.react-daterange-picker__button:enabled{cursor:pointer}.react-daterange-picker__button:enabled:hover .react-daterange-picker__button__icon,.react-daterange-picker__button:enabled:focus .react-daterange-picker__button__icon{stroke:#0078d7}.react-daterange-picker__button:disabled .react-daterange-picker__button__icon{stroke:#6d6d6d}.react-daterange-picker__button svg{display:inherit}.react-daterange-picker__calendar{width:350px;max-width:100vw;z-index:1}.react-daterange-picker__calendar--closed{display:none}.react-daterange-picker__calendar .react-calendar{border-width:thin}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("../chunks/jsx-runtime-DFswc9zO.js"),f=require("../chunks/bundle-mjs-W341Qwux.js"),h=require("../chunks/select-BoiIj-gw.js"),j=require("react"),m=require("../chunks/clsx-C11secjj.js"),y=({className:o,color:e="primary",active:t,children:i,text:r,onClick:x})=>{const l=m.clsx({"bg-primary":e==="primary"&&t,"bg-success":e==="success"&&t,"bg-danger":e==="danger"&&t,"bg-warning":e==="warning"&&t,"bg-default":e==="default"&&t}),u=f.twMerge(m.clsx("text-sm",{"group-hover:text-primary-500":e==="primary"&&!t,"group-hover:text-success-500":e==="success"&&!t,"group-hover:text-danger-500":e==="danger"&&!t,"group-hover:text-warning-500":e==="warning"&&!t,"group-hover:text-default-500":e==="default"&&!t,"text-default-foreground":t&&e==="default","text-primary-foreground":t&&e==="primary","text-success-foreground":t&&e==="success","text-danger-foreground":t&&e==="danger","text-warning-foreground":t&&e==="warning"}));return n.jsxRuntimeExports.jsx("div",{className:f.twMerge("w-[33px] h-[32px] flex items-center justify-center group",l,o),onClick:x,children:i||n.jsxRuntimeExports.jsx("p",{className:u,children:r})})},b=({page:o,total:e,siblings:t=1})=>{if(7+t>=e)return Array.from({length:e},(s,a)=>a+1);const r=Math.max(o-t,1),x=Math.min(o+t,e),l=r>2,u=x<e-2;if(!l&&u){const s=3+2*t;return[...Array.from({length:s},(g,d)=>d+1),"...",e]}else if(l&&!u){const s=3+2*t;return[1,"...",...Array.from({length:s},(g,d)=>e-s+d+1)]}else return[1,"...",...Array.from({length:x-r+1},(a,g)=>r+g),"...",e]},E=o=>o.map(e=>({id:e,name:e})),I=({className:o,color:e="primary",total:t,limit:i=20,page:r=1,siblings:x=1,isLimitSelect:l=!0,dataLimit:u=[10,15,20,50,100,200],onChange:s})=>{const a=Math.ceil(t/i),g=b({page:r,siblings:x,total:a}),d=E(u),R=c=>{c!=="..."&&s&&s({limit:i,page:Number(c)})},w=()=>{r!==1&&s&&s({limit:i,page:r-1})},N=()=>{r===a||a===0||s&&s({limit:i,page:r+1})},P=({item:c,action:p})=>{p!=="clear"&&s&&s({page:r,limit:c.id})};return n.jsxRuntimeExports.jsxs("div",{className:f.twMerge("flex justify-between gap-x-2 items-center",o),children:[l?n.jsxRuntimeExports.jsxs("div",{className:"flex items-center gap-x-2.5",children:[n.jsxRuntimeExports.jsx("p",{className:"text-sm text-gray-500",children:"Filas por pagina"}),n.jsxRuntimeExports.jsx(h.Select$1,{data:d,onChange:P,placeholder:"0",isSearchable:!1,value:i,widthMenu:80,isClearable:!1,isPortal:!0,menuPosition:"fixed",classNameContainer:"min-w-20",size:"sm"}),n.jsxRuntimeExports.jsxs("p",{className:"text-sm text-gray-500",children:[n.jsxRuntimeExports.jsx("span",{className:"text-gray-900",children:`${r} - ${i}`})," de ",n.jsxRuntimeExports.jsx("span",{className:"text-gray-900",children:t})]})]}):null,n.jsxRuntimeExports.jsxs("div",{className:"flex items-center border border-gray-300 bg-white rounded-lg cursor-pointer",children:[n.jsxRuntimeExports.jsx(y,{className:m.clsx(r===1&&"cursor-no-drop"),onClick:w,children:n.jsxRuntimeExports.jsx(h.IoIosArrowBack,{className:f.twMerge("fill-gray-500",m.clsx(r===1&&"fill-gray-300"))})}),g.map((c,p)=>n.jsxRuntimeExports.jsx(y,{text:c,active:r===c,color:e,onClick:()=>R(c),className:"border-l"},p)),n.jsxRuntimeExports.jsx(y,{className:m.clsx("border-l",(r===a||a===0)&&"cursor-no-drop"),onClick:N,children:n.jsxRuntimeExports.jsx(h.IoIosArrowBack,{className:f.twMerge("fill-gray-500 transform rotate-180",m.clsx((r===a||a===0)&&"fill-gray-300"))})})]})]})},M=({initialPage:o=1,initialLimit:e=20})=>{const[t,i]=j.useState(o),[r,x]=j.useState(e);return{handleSetPagination:j.useCallback(({page:u,limit:s})=>{u!==t&&i(u),s!==r&&x(s)},[r,t]),page:t,limit:r}};exports.Pagination=I;exports.usePagination=M;
2
+ //# sourceMappingURL=index.cjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs.js","sources":["../../src/components/pagination/pagination-item.tsx","../../src/components/pagination/function/index.ts","../../src/components/pagination/pagination.tsx","../../src/components/pagination/hook/use-pagination.tsx"],"sourcesContent":["import { twMerge } from \"tailwind-merge\";\nimport { type PaginationItemProps } from \"./interface/pagination.interface\";\nimport clsx from \"clsx\";\n\nexport const PaginationItem = ({\n\tclassName,\n\tcolor = \"primary\",\n\tactive,\n\tchildren,\n\ttext,\n\tonClick,\n}: PaginationItemProps) => {\n\tconst bgClass = clsx({\n\t\t\"bg-primary\": color === \"primary\" && active,\n\t\t\"bg-success\": color === \"success\" && active,\n \"bg-danger\": color === \"danger\" && active,\n \"bg-warning\": color === \"warning\" && active,\n \"bg-default\": color === \"default\" && active,\n\t});\n\tconst colorClass = twMerge(\n\t\tclsx(\"text-sm\", {\n\t\t\t\"group-hover:text-primary-500\": color === \"primary\" && !active,\n\t\t\t\"group-hover:text-success-500\": color === \"success\" && !active,\n \"group-hover:text-danger-500\": color === \"danger\" && !active,\n \"group-hover:text-warning-500\": color === \"warning\" && !active,\n \"group-hover:text-default-500\": color === \"default\" && !active,\n\n\t\t\t\"text-default-foreground\": active && color === \"default\",\n\t\t\t\"text-primary-foreground\": active && color === \"primary\",\n \"text-success-foreground\": active && color === \"success\",\n \"text-danger-foreground\": active && color === \"danger\",\n \"text-warning-foreground\": active && color === \"warning\",\n\t\t})\n\t);\n\n\n\treturn (\n\t\t<div\n\t\t\tclassName={twMerge(\n\t\t\t\t\"w-[33px] h-[32px] flex items-center justify-center group\",\n\t\t\t\tbgClass,\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\tonClick={onClick}\n\t\t>\n\t\t\t{children || <p className={colorClass}>{text}</p>}\n\t\t</div>\n\t);\n};\n","import { type PaginationValueProps } from \"../interface/pagination-share.interface\";\n\nexport const FormatPagePagination = ({\n\tpage,\n\ttotal,\n\tsiblings = 1,\n}: PaginationValueProps) => {\n\tconst totalPageNoInArray = 7 + siblings;\n\n\tif (totalPageNoInArray >= total) {\n\t\treturn Array.from({ length: total }, (_, i) => i + 1);\n\t}\n\n\tconst leftSiblingsIndex = Math.max(page - siblings, 1);\n\tconst rightSiblingsIndex = Math.min(page + siblings, total);\n\n\tconst showLeftDots = leftSiblingsIndex > 2;\n\tconst showRightDots = rightSiblingsIndex < total - 2;\n\n\tif (!showLeftDots && showRightDots) {\n\t\tconst leftItemsCount = 3 + 2 * siblings;\n\t\tconst leftRange = Array.from({ length: leftItemsCount }, (_, i) => i + 1);\n\t\treturn [...leftRange, \"...\", total];\n\t} else if (showLeftDots && !showRightDots) {\n\t\tconst rightItemsCount = 3 + 2 * siblings;\n\t\tconst rightRange = Array.from(\n\t\t\t{ length: rightItemsCount },\n\t\t\t(_, i) => total - rightItemsCount + i + 1\n\t\t);\n\t\treturn [1, \"...\", ...rightRange];\n\t} else {\n\t\tconst middleRange = Array.from(\n\t\t\t{ length: rightSiblingsIndex - leftSiblingsIndex + 1 },\n\t\t\t(_, i) => leftSiblingsIndex + i\n\t\t);\n\t\treturn [1, \"...\", ...middleRange, \"...\", total];\n\t}\n};\n\nexport const FormatLimitPagination = (data: number[]) => {\n\treturn data.map((el) => {\n\t\treturn {\n\t\t\tid: el,\n\t\t\tname: el,\n\t\t};\n\t});\n};\n","import { twMerge } from \"tailwind-merge\";\r\nimport { IoIosArrowBack } from \"react-icons/io\";\r\nimport { PaginationItem } from \"./pagination-item\";\r\nimport { type PaginationProps } from \"./interface/pagination.interface\";\r\nimport { FormatLimitPagination, FormatPagePagination } from \"./function\";\r\nimport clsx from \"clsx\";\r\nimport { Select } from \"../select/select\";\r\nimport type { ActionChangeProps } from \"@/types\";\r\n\r\nexport const Pagination = ({\r\n\tclassName,\r\n\tcolor = \"primary\",\r\n\r\n\ttotal,\r\n\tlimit = 20,\r\n\tpage = 1,\r\n\tsiblings = 1,\r\n\tisLimitSelect = true,\r\n\tdataLimit = [10, 15, 20, 50, 100, 200],\r\n\tonChange,\r\n}: PaginationProps) => {\r\n\tconst totalPagination = Math.ceil(total / limit);\r\n\r\n\tconst dataPageFormat = FormatPagePagination({\r\n\t\tlimit,\r\n\t\tpage,\r\n\t\tsiblings,\r\n\t\ttotal: totalPagination,\r\n\t});\r\n\tconst dataLimitFormat = FormatLimitPagination(dataLimit);\r\n\r\n\tconst handleChange = (value: number | string | null) => {\r\n\t\tif (value === \"...\") return;\r\n\t\tif (onChange)\r\n\t\t\tonChange({\r\n\t\t\t\tlimit,\r\n\t\t\t\tpage: Number(value),\r\n\t\t\t});\r\n\t};\r\n\r\n\tconst handlePrev = () => {\r\n\t\tif (page === 1) return;\r\n\r\n\t\tif (onChange)\r\n\t\t\tonChange({\r\n\t\t\t\tlimit,\r\n\t\t\t\tpage: page - 1,\r\n\t\t\t});\r\n\t};\r\n\r\n\tconst handleNext = () => {\r\n\t\tif (page === totalPagination || totalPagination === 0) return;\r\n\r\n\t\tif (onChange)\r\n\t\t\tonChange({\r\n\t\t\t\tlimit,\r\n\t\t\t\tpage: page + 1,\r\n\t\t\t});\r\n\t};\r\n\r\n\tconst handleChangeSelect = ({ item, action }: { item: any; action: ActionChangeProps }) => {\r\n\t\tif (action === \"clear\") return;\r\n\t\tif (onChange)\r\n\t\t\tonChange({\r\n\t\t\t\tpage,\r\n\t\t\t\tlimit: item.id,\r\n\t\t\t});\r\n\t};\r\n\r\n\treturn (\r\n\t\t<div className={twMerge(\"flex justify-between gap-x-2 items-center\", className)}>\r\n\t\t\t{isLimitSelect ? (\r\n\t\t\t\t<div className=\"flex items-center gap-x-2.5\">\r\n\t\t\t\t\t<p className=\"text-sm text-gray-500\">Filas por pagina</p>\r\n\t\t\t\t\t<Select\r\n\t\t\t\t\t\tdata={dataLimitFormat}\r\n\t\t\t\t\t\tonChange={handleChangeSelect}\r\n\t\t\t\t\t\tplaceholder=\"0\"\r\n\t\t\t\t\t\tisSearchable={false}\r\n\t\t\t\t\t\tvalue={limit}\r\n\t\t\t\t\t\twidthMenu={80}\r\n\t\t\t\t\t\tisClearable={false}\r\n\t\t\t\t\t\tisPortal\r\n\t\t\t\t\t\tmenuPosition=\"fixed\"\r\n\t\t\t\t\t\tclassNameContainer=\"min-w-20\"\r\n\t\t\t\t\t\tsize=\"sm\"\r\n\t\t\t\t\t/>\r\n\t\t\t\t\t<p className=\"text-sm text-gray-500\">\r\n\t\t\t\t\t\t<span className=\"text-gray-900\">{`${page} - ${limit}`}</span> de <span className=\"text-gray-900\">{total}</span>\r\n\t\t\t\t\t</p>\r\n\t\t\t\t</div>\r\n\t\t\t) : null}\r\n\r\n\t\t\t<div className=\"flex items-center border border-gray-300 bg-white rounded-lg cursor-pointer\">\r\n\t\t\t\t<PaginationItem className={clsx(page === 1 && \"cursor-no-drop\")} onClick={handlePrev}>\r\n\t\t\t\t\t<IoIosArrowBack className={twMerge(\"fill-gray-500\", clsx(page === 1 && \"fill-gray-300\"))} />\r\n\t\t\t\t</PaginationItem>\r\n\r\n\t\t\t\t{dataPageFormat.map((el, i) => (\r\n\t\t\t\t\t<PaginationItem key={i} text={el} active={page === el} color={color} onClick={() => handleChange(el)} className=\"border-l\" />\r\n\t\t\t\t))}\r\n\r\n\t\t\t\t<PaginationItem\r\n\t\t\t\t\tclassName={clsx(\"border-l\", (page === totalPagination || totalPagination === 0) && \"cursor-no-drop\")}\r\n\t\t\t\t\tonClick={handleNext}\r\n\t\t\t\t>\r\n\t\t\t\t\t<IoIosArrowBack\r\n\t\t\t\t\t\tclassName={twMerge(\r\n\t\t\t\t\t\t\t\"fill-gray-500 transform rotate-180\",\r\n\t\t\t\t\t\t\tclsx((page === totalPagination || totalPagination === 0) && \"fill-gray-300\"),\r\n\t\t\t\t\t\t)}\r\n\t\t\t\t\t/>\r\n\t\t\t\t</PaginationItem>\r\n\t\t\t</div>\r\n\t\t</div>\r\n\t);\r\n};\r\n","import { useCallback, useState } from \"react\";\nimport { type PaginationHookProps, type UsePaginationProps } from \"../interface/pagination.interface\";\nimport { type PaginationSetValueProps } from \"../interface/pagination-share.interface\";\n\nexport const usePagination = ({ initialPage = 1, initialLimit = 20 }: UsePaginationProps): PaginationHookProps => {\n\tconst [pageCurrent, setPageCurrent] = useState<number>(initialPage);\n\tconst [limitCurrent, setLimitCurrent] = useState<number>(initialLimit);\n\n\tconst handleSetPagination = useCallback(\n\t\t({ page, limit }: PaginationSetValueProps) => {\n\t\t\tif (page !== pageCurrent) setPageCurrent(page);\n\t\t\tif (limit !== limitCurrent) setLimitCurrent(limit);\n\t\t},\n\t\t[limitCurrent, pageCurrent],\n\t);\n\n\treturn {\n\t\thandleSetPagination,\n\t\tpage: pageCurrent,\n\t\tlimit: limitCurrent,\n\t};\n};\n"],"names":["PaginationItem","className","color","active","children","text","onClick","bgClass","clsx","colorClass","twMerge","jsx","FormatPagePagination","page","total","siblings","_","i","leftSiblingsIndex","rightSiblingsIndex","showLeftDots","showRightDots","leftItemsCount","rightItemsCount","FormatLimitPagination","data","el","Pagination","limit","isLimitSelect","dataLimit","onChange","totalPagination","dataPageFormat","dataLimitFormat","handleChange","value","handlePrev","handleNext","handleChangeSelect","item","action","jsxs","Select","IoIosArrowBack","usePagination","initialPage","initialLimit","pageCurrent","setPageCurrent","useState","limitCurrent","setLimitCurrent","useCallback"],"mappings":"wRAIaA,EAAiB,CAAC,CAC9B,UAAAC,EACA,MAAAC,EAAQ,UACR,OAAAC,EACA,SAAAC,EACA,KAAAC,EACA,QAAAC,CACD,IAA2B,CAC1B,MAAMC,EAAUC,EAAAA,KAAK,CACpB,aAAcN,IAAU,WAAaC,EACrC,aAAcD,IAAU,WAAaC,EAC/B,YAAaD,IAAU,UAAYC,EACnC,aAAcD,IAAU,WAAaC,EACrC,aAAcD,IAAU,WAAaC,CAAA,CAC3C,EACKM,EAAaC,EAAA,QAClBF,EAAAA,KAAK,UAAW,CACf,+BAAgCN,IAAU,WAAa,CAACC,EACxD,+BAAgCD,IAAU,WAAa,CAACC,EAC/C,8BAA+BD,IAAU,UAAY,CAACC,EACtD,+BAAgCD,IAAU,WAAa,CAACC,EACxD,+BAAgCD,IAAU,WAAa,CAACC,EAEjE,0BAA2BA,GAAUD,IAAU,UAC/C,0BAA2BC,GAAUD,IAAU,UACtC,0BAA2BC,GAAUD,IAAU,UAC/C,yBAA0BC,GAAUD,IAAU,SAC9C,0BAA2BC,GAAUD,IAAU,SACxD,CAAA,CACF,EAIC,OAAAS,EAAA,kBAAA,IAAC,MAAA,CACA,UAAWD,EAAA,QACV,2DACAH,EACAN,CACD,EACA,QAAAK,EAEC,SAAYF,GAAAO,EAAAA,kBAAAA,IAAC,IAAE,CAAA,UAAWF,EAAa,SAAKJ,CAAA,CAAA,CAAA,CAC9C,CAEF,EC9CaO,EAAuB,CAAC,CACpC,KAAAC,EACA,MAAAC,EACA,SAAAC,EAAW,CACZ,IAA4B,CAG3B,GAF2B,EAAIA,GAELD,EAClB,OAAA,MAAM,KAAK,CAAE,OAAQA,GAAS,CAACE,EAAGC,IAAMA,EAAI,CAAC,EAGrD,MAAMC,EAAoB,KAAK,IAAIL,EAAOE,EAAU,CAAC,EAC/CI,EAAqB,KAAK,IAAIN,E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