@acronis-platform/ui-react 4.0.0 → 4.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (620) hide show
  1. package/dist/_virtual/_rolldown/runtime.js +11 -0
  2. package/dist/components/ui/accordion/accordion.js +40 -53
  3. package/dist/components/ui/accordion/accordion.js.map +1 -1
  4. package/dist/components/ui/accordion-container/accordion-container.js +93 -141
  5. package/dist/components/ui/accordion-container/accordion-container.js.map +1 -1
  6. package/dist/components/ui/alert/alert.js +95 -156
  7. package/dist/components/ui/alert/alert.js.map +1 -1
  8. package/dist/components/ui/app-shell-chat/app-shell-chat.js +233 -332
  9. package/dist/components/ui/app-shell-chat/app-shell-chat.js.map +1 -1
  10. package/dist/components/ui/area-chart/area-chart.js +155 -240
  11. package/dist/components/ui/area-chart/area-chart.js.map +1 -1
  12. package/dist/components/ui/avatar/avatar.js +47 -84
  13. package/dist/components/ui/avatar/avatar.js.map +1 -1
  14. package/dist/components/ui/bar-chart/bar-chart.js +405 -615
  15. package/dist/components/ui/bar-chart/bar-chart.js.map +1 -1
  16. package/dist/components/ui/breadcrumb/breadcrumb.js +68 -116
  17. package/dist/components/ui/breadcrumb/breadcrumb.js.map +1 -1
  18. package/dist/components/ui/button/button.js +31 -40
  19. package/dist/components/ui/button/button.js.map +1 -1
  20. package/dist/components/ui/button-group/button-group.js +33 -55
  21. package/dist/components/ui/button-group/button-group.js.map +1 -1
  22. package/dist/components/ui/button-icon/button-icon.js +26 -35
  23. package/dist/components/ui/button-icon/button-icon.js.map +1 -1
  24. package/dist/components/ui/button-icon-input/button-icon-input.js +28 -35
  25. package/dist/components/ui/button-icon-input/button-icon-input.js.map +1 -1
  26. package/dist/components/ui/button-icon-menu/button-icon-menu.js +22 -26
  27. package/dist/components/ui/button-icon-menu/button-icon-menu.js.map +1 -1
  28. package/dist/components/ui/button-menu/button-menu.js +36 -52
  29. package/dist/components/ui/button-menu/button-menu.js.map +1 -1
  30. package/dist/components/ui/calendar/calendar.js +103 -202
  31. package/dist/components/ui/calendar/calendar.js.map +1 -1
  32. package/dist/components/ui/calendar-panel/calendar-panel-utils.js +46 -57
  33. package/dist/components/ui/calendar-panel/calendar-panel-utils.js.map +1 -1
  34. package/dist/components/ui/calendar-panel/calendar-panel.js +136 -257
  35. package/dist/components/ui/calendar-panel/calendar-panel.js.map +1 -1
  36. package/dist/components/ui/card/card.js +104 -168
  37. package/dist/components/ui/card/card.js.map +1 -1
  38. package/dist/components/ui/card-filter/card-filter.js +49 -76
  39. package/dist/components/ui/card-filter/card-filter.js.map +1 -1
  40. package/dist/components/ui/card-section/card-section.js +81 -111
  41. package/dist/components/ui/card-section/card-section.js.map +1 -1
  42. package/dist/components/ui/carousel-dialog/carousel-dialog.js +49 -87
  43. package/dist/components/ui/carousel-dialog/carousel-dialog.js.map +1 -1
  44. package/dist/components/ui/category-bar/category-bar.js +123 -162
  45. package/dist/components/ui/category-bar/category-bar.js.map +1 -1
  46. package/dist/components/ui/chart/chart-format.js +117 -153
  47. package/dist/components/ui/chart/chart-format.js.map +1 -1
  48. package/dist/components/ui/chart/chart-palette.js +63 -107
  49. package/dist/components/ui/chart/chart-palette.js.map +1 -1
  50. package/dist/components/ui/chart/chart.js +177 -305
  51. package/dist/components/ui/chart/chart.js.map +1 -1
  52. package/dist/components/ui/chart-state/chart-state-illustrations.js +400 -298
  53. package/dist/components/ui/chart-state/chart-state-illustrations.js.map +1 -1
  54. package/dist/components/ui/chart-state/chart-state.js +40 -56
  55. package/dist/components/ui/chart-state/chart-state.js.map +1 -1
  56. package/dist/components/ui/chart-widget/chart-widget.js +40 -87
  57. package/dist/components/ui/chart-widget/chart-widget.js.map +1 -1
  58. package/dist/components/ui/checkbox/checkbox.js +56 -69
  59. package/dist/components/ui/checkbox/checkbox.js.map +1 -1
  60. package/dist/components/ui/chip/chip.js +51 -70
  61. package/dist/components/ui/chip/chip.js.map +1 -1
  62. package/dist/components/ui/combobox/combobox.js +88 -151
  63. package/dist/components/ui/combobox/combobox.js.map +1 -1
  64. package/dist/components/ui/composed-chart/composed-chart.js +297 -434
  65. package/dist/components/ui/composed-chart/composed-chart.js.map +1 -1
  66. package/dist/components/ui/confidence-cone/confidence-cone.js +214 -332
  67. package/dist/components/ui/confidence-cone/confidence-cone.js.map +1 -1
  68. package/dist/components/ui/data-table/data-table-bulk-actions-bar.js +32 -37
  69. package/dist/components/ui/data-table/data-table-bulk-actions-bar.js.map +1 -1
  70. package/dist/components/ui/data-table/data-table-column-header.js +23 -38
  71. package/dist/components/ui/data-table/data-table-column-header.js.map +1 -1
  72. package/dist/components/ui/data-table/data-table-expand-trigger.js +23 -46
  73. package/dist/components/ui/data-table/data-table-expand-trigger.js.map +1 -1
  74. package/dist/components/ui/data-table/data-table-pagination.js +84 -89
  75. package/dist/components/ui/data-table/data-table-pagination.js.map +1 -1
  76. package/dist/components/ui/data-table/data-table-selection.js +7 -6
  77. package/dist/components/ui/data-table/data-table-selection.js.map +1 -1
  78. package/dist/components/ui/data-table/data-table-toolbar.js +51 -76
  79. package/dist/components/ui/data-table/data-table-toolbar.js.map +1 -1
  80. package/dist/components/ui/data-table/data-table-view-options.js +21 -28
  81. package/dist/components/ui/data-table/data-table-view-options.js.map +1 -1
  82. package/dist/components/ui/data-table/data-table.js +304 -438
  83. package/dist/components/ui/data-table/data-table.js.map +1 -1
  84. package/dist/components/ui/date-range-picker/date-range-picker-utils.js +16 -14
  85. package/dist/components/ui/date-range-picker/date-range-picker-utils.js.map +1 -1
  86. package/dist/components/ui/date-range-picker/date-range-picker.js +77 -111
  87. package/dist/components/ui/date-range-picker/date-range-picker.js.map +1 -1
  88. package/dist/components/ui/description-list/description-list.js +44 -54
  89. package/dist/components/ui/description-list/description-list.js.map +1 -1
  90. package/dist/components/ui/dialog/dialog.js +229 -310
  91. package/dist/components/ui/dialog/dialog.js.map +1 -1
  92. package/dist/components/ui/dialog-footer-carousel/dialog-footer-carousel.js +33 -57
  93. package/dist/components/ui/dialog-footer-carousel/dialog-footer-carousel.js.map +1 -1
  94. package/dist/components/ui/dialog-footer-default/dialog-footer-default.js +21 -26
  95. package/dist/components/ui/dialog-footer-default/dialog-footer-default.js.map +1 -1
  96. package/dist/components/ui/dialog-welcome/dialog-welcome.js +221 -267
  97. package/dist/components/ui/dialog-welcome/dialog-welcome.js.map +1 -1
  98. package/dist/components/ui/dropdown-menu/dropdown-menu.js +101 -168
  99. package/dist/components/ui/dropdown-menu/dropdown-menu.js.map +1 -1
  100. package/dist/components/ui/empty/empty.js +49 -77
  101. package/dist/components/ui/empty/empty.js.map +1 -1
  102. package/dist/components/ui/empty-overlay/empty-overlay.js +43 -49
  103. package/dist/components/ui/empty-overlay/empty-overlay.js.map +1 -1
  104. package/dist/components/ui/field/field.js +95 -178
  105. package/dist/components/ui/field/field.js.map +1 -1
  106. package/dist/components/ui/filter-cards/filter-cards.js +16 -25
  107. package/dist/components/ui/filter-cards/filter-cards.js.map +1 -1
  108. package/dist/components/ui/filter-chips/filter-chips.js +36 -44
  109. package/dist/components/ui/filter-chips/filter-chips.js.map +1 -1
  110. package/dist/components/ui/filter-search/filter-search.js +139 -209
  111. package/dist/components/ui/filter-search/filter-search.js.map +1 -1
  112. package/dist/components/ui/fitted-actions/fitted-actions.js +87 -137
  113. package/dist/components/ui/fitted-actions/fitted-actions.js.map +1 -1
  114. package/dist/components/ui/form/form.js +14 -15
  115. package/dist/components/ui/form/form.js.map +1 -1
  116. package/dist/components/ui/funnel-chart/funnel-chart.js +190 -274
  117. package/dist/components/ui/funnel-chart/funnel-chart.js.map +1 -1
  118. package/dist/components/ui/grid/grid.js +61 -68
  119. package/dist/components/ui/grid/grid.js.map +1 -1
  120. package/dist/components/ui/histogram/histogram.js +107 -141
  121. package/dist/components/ui/histogram/histogram.js.map +1 -1
  122. package/dist/components/ui/input/input.js +14 -21
  123. package/dist/components/ui/input/input.js.map +1 -1
  124. package/dist/components/ui/input-date-picker/input-date-picker.js +70 -114
  125. package/dist/components/ui/input-date-picker/input-date-picker.js.map +1 -1
  126. package/dist/components/ui/input-num-picker/input-num-picker.js +48 -0
  127. package/dist/components/ui/input-num-picker/input-num-picker.js.map +1 -0
  128. package/dist/components/ui/input-otp/input-otp.js +75 -104
  129. package/dist/components/ui/input-otp/input-otp.js.map +1 -1
  130. package/dist/components/ui/input-password/input-password.js +71 -126
  131. package/dist/components/ui/input-password/input-password.js.map +1 -1
  132. package/dist/components/ui/input-search/input-search.js +32 -56
  133. package/dist/components/ui/input-search/input-search.js.map +1 -1
  134. package/dist/components/ui/input-select/input-select.js +225 -335
  135. package/dist/components/ui/input-select/input-select.js.map +1 -1
  136. package/dist/components/ui/input-text/input-text.js +54 -98
  137. package/dist/components/ui/input-text/input-text.js.map +1 -1
  138. package/dist/components/ui/input-text-area/input-text-area.js +41 -86
  139. package/dist/components/ui/input-text-area/input-text-area.js.map +1 -1
  140. package/dist/components/ui/label/label.js +6 -5
  141. package/dist/components/ui/label/label.js.map +1 -1
  142. package/dist/components/ui/line-chart/line-chart.js +175 -277
  143. package/dist/components/ui/line-chart/line-chart.js.map +1 -1
  144. package/dist/components/ui/link/link.js +34 -54
  145. package/dist/components/ui/link/link.js.map +1 -1
  146. package/dist/components/ui/loading/loading.js +51 -78
  147. package/dist/components/ui/loading/loading.js.map +1 -1
  148. package/dist/components/ui/meter/meter.js +79 -93
  149. package/dist/components/ui/meter/meter.js.map +1 -1
  150. package/dist/components/ui/metric/metric.js +83 -89
  151. package/dist/components/ui/metric/metric.js.map +1 -1
  152. package/dist/components/ui/number-field/number-field.js +36 -60
  153. package/dist/components/ui/number-field/number-field.js.map +1 -1
  154. package/dist/components/ui/page-content/page-content.js +15 -19
  155. package/dist/components/ui/page-content/page-content.js.map +1 -1
  156. package/dist/components/ui/page-header/page-header.js +120 -181
  157. package/dist/components/ui/page-header/page-header.js.map +1 -1
  158. package/dist/components/ui/pagination/pagination.js +58 -86
  159. package/dist/components/ui/pagination/pagination.js.map +1 -1
  160. package/dist/components/ui/pie-chart/pie-chart.js +189 -268
  161. package/dist/components/ui/pie-chart/pie-chart.js.map +1 -1
  162. package/dist/components/ui/popover/popover.js +51 -96
  163. package/dist/components/ui/popover/popover.js.map +1 -1
  164. package/dist/components/ui/progress/progress.js +23 -29
  165. package/dist/components/ui/progress/progress.js.map +1 -1
  166. package/dist/components/ui/progress-circle/progress-circle.js +97 -113
  167. package/dist/components/ui/progress-circle/progress-circle.js.map +1 -1
  168. package/dist/components/ui/radar-chart/radar-chart.js +127 -225
  169. package/dist/components/ui/radar-chart/radar-chart.js.map +1 -1
  170. package/dist/components/ui/radial-bar-chart/radial-bar-chart.js +267 -399
  171. package/dist/components/ui/radial-bar-chart/radial-bar-chart.js.map +1 -1
  172. package/dist/components/ui/radio/radio.js +22 -43
  173. package/dist/components/ui/radio/radio.js.map +1 -1
  174. package/dist/components/ui/resizable/resizable.js +20 -64
  175. package/dist/components/ui/resizable/resizable.js.map +1 -1
  176. package/dist/components/ui/sankey-chart/sankey-chart.js +155 -217
  177. package/dist/components/ui/sankey-chart/sankey-chart.js.map +1 -1
  178. package/dist/components/ui/scatter-chart/scatter-chart.js +95 -140
  179. package/dist/components/ui/scatter-chart/scatter-chart.js.map +1 -1
  180. package/dist/components/ui/scroll-area/scroll-area.js +43 -77
  181. package/dist/components/ui/scroll-area/scroll-area.js.map +1 -1
  182. package/dist/components/ui/search/search.js +58 -92
  183. package/dist/components/ui/search/search.js.map +1 -1
  184. package/dist/components/ui/section/section.js +125 -163
  185. package/dist/components/ui/section/section.js.map +1 -1
  186. package/dist/components/ui/separator/separator.js +16 -22
  187. package/dist/components/ui/separator/separator.js.map +1 -1
  188. package/dist/components/ui/sheet/sheet-details.js +55 -78
  189. package/dist/components/ui/sheet/sheet-details.js.map +1 -1
  190. package/dist/components/ui/sheet/sheet.js +80 -136
  191. package/dist/components/ui/sheet/sheet.js.map +1 -1
  192. package/dist/components/ui/sidebar-primary/sidebar-primary.js +220 -364
  193. package/dist/components/ui/sidebar-primary/sidebar-primary.js.map +1 -1
  194. package/dist/components/ui/sidebar-secondary/sidebar-secondary.js +459 -641
  195. package/dist/components/ui/sidebar-secondary/sidebar-secondary.js.map +1 -1
  196. package/dist/components/ui/skeleton/skeleton.js +14 -21
  197. package/dist/components/ui/skeleton/skeleton.js.map +1 -1
  198. package/dist/components/ui/slider/slider.js +28 -42
  199. package/dist/components/ui/slider/slider.js.map +1 -1
  200. package/dist/components/ui/spinner/spinner.js +28 -37
  201. package/dist/components/ui/spinner/spinner.js.map +1 -1
  202. package/dist/components/ui/stack/stack.js +59 -61
  203. package/dist/components/ui/stack/stack.js.map +1 -1
  204. package/dist/components/ui/stepper/stepper.js +52 -70
  205. package/dist/components/ui/stepper/stepper.js.map +1 -1
  206. package/dist/components/ui/stepper-item/stepper-item.js +85 -116
  207. package/dist/components/ui/stepper-item/stepper-item.js.map +1 -1
  208. package/dist/components/ui/switch/switch.js +26 -40
  209. package/dist/components/ui/switch/switch.js.map +1 -1
  210. package/dist/components/ui/table/table-pagination.js +91 -106
  211. package/dist/components/ui/table/table-pagination.js.map +1 -1
  212. package/dist/components/ui/table/table-view-options.js +37 -53
  213. package/dist/components/ui/table/table-view-options.js.map +1 -1
  214. package/dist/components/ui/table/table.js +90 -177
  215. package/dist/components/ui/table/table.js.map +1 -1
  216. package/dist/components/ui/tabs/tabs.js +26 -43
  217. package/dist/components/ui/tabs/tabs.js.map +1 -1
  218. package/dist/components/ui/tag/tag.js +42 -47
  219. package/dist/components/ui/tag/tag.js.map +1 -1
  220. package/dist/components/ui/timeline/timeline.js +161 -239
  221. package/dist/components/ui/timeline/timeline.js.map +1 -1
  222. package/dist/components/ui/timer/timer.js +24 -47
  223. package/dist/components/ui/timer/timer.js.map +1 -1
  224. package/dist/components/ui/toast/toast.js +134 -189
  225. package/dist/components/ui/toast/toast.js.map +1 -1
  226. package/dist/components/ui/toggle-group/toggle-group.js +28 -46
  227. package/dist/components/ui/toggle-group/toggle-group.js.map +1 -1
  228. package/dist/components/ui/toolbar/toolbar.js +128 -201
  229. package/dist/components/ui/toolbar/toolbar.js.map +1 -1
  230. package/dist/components/ui/tooltip/tooltip.js +35 -57
  231. package/dist/components/ui/tooltip/tooltip.js.map +1 -1
  232. package/dist/components/ui/treemap/treemap.js +135 -213
  233. package/dist/components/ui/treemap/treemap.js.map +1 -1
  234. package/dist/components/ui/trend-indicator/trend-indicator.js +48 -62
  235. package/dist/components/ui/trend-indicator/trend-indicator.js.map +1 -1
  236. package/dist/components/ui/truncate-text/middle-truncate.js +19 -19
  237. package/dist/components/ui/truncate-text/middle-truncate.js.map +1 -1
  238. package/dist/components/ui/truncate-text/text-width.js +11 -10
  239. package/dist/components/ui/truncate-text/text-width.js.map +1 -1
  240. package/dist/components/ui/truncate-text/truncate-text.js +92 -152
  241. package/dist/components/ui/truncate-text/truncate-text.js.map +1 -1
  242. package/dist/components/ui/widget-placeholder/widget-placeholder.js +63 -106
  243. package/dist/components/ui/widget-placeholder/widget-placeholder.js.map +1 -1
  244. package/dist/components/ui/wizard/wizard.js +36 -59
  245. package/dist/components/ui/wizard/wizard.js.map +1 -1
  246. package/dist/hooks/use-intersection-observer.js +27 -25
  247. package/dist/hooks/use-intersection-observer.js.map +1 -1
  248. package/dist/hooks/use-sort-state.js +43 -33
  249. package/dist/hooks/use-sort-state.js.map +1 -1
  250. package/dist/hooks/use-table-url-state.js +100 -109
  251. package/dist/hooks/use-table-url-state.js.map +1 -1
  252. package/dist/hooks/use-wizard.js +57 -71
  253. package/dist/hooks/use-wizard.js.map +1 -1
  254. package/dist/index.js +125 -550
  255. package/dist/lib/breakpoints.js +8 -13
  256. package/dist/lib/breakpoints.js.map +1 -1
  257. package/dist/lib/deep-equal.js +14 -22
  258. package/dist/lib/deep-equal.js.map +1 -1
  259. package/dist/lib/portal-container.js +16 -12
  260. package/dist/lib/portal-container.js.map +1 -1
  261. package/dist/lib/use-doc-dir.js +11 -10
  262. package/dist/lib/use-doc-dir.js.map +1 -1
  263. package/dist/lib/utils.js +8 -7
  264. package/dist/lib/utils.js.map +1 -1
  265. package/dist/llms/input-num-picker.md +180 -0
  266. package/dist/llms.txt +2 -1
  267. package/dist/node_modules/.pnpm/@date-fns_tz@1.5.0/node_modules/@date-fns/tz/date/index.js +58 -61
  268. package/dist/node_modules/.pnpm/@date-fns_tz@1.5.0/node_modules/@date-fns/tz/date/index.js.map +1 -1
  269. package/dist/node_modules/.pnpm/@date-fns_tz@1.5.0/node_modules/@date-fns/tz/date/mini.js +71 -85
  270. package/dist/node_modules/.pnpm/@date-fns_tz@1.5.0/node_modules/@date-fns/tz/date/mini.js.map +1 -1
  271. package/dist/node_modules/.pnpm/@date-fns_tz@1.5.0/node_modules/@date-fns/tz/index.js +6 -0
  272. package/dist/node_modules/.pnpm/@date-fns_tz@1.5.0/node_modules/@date-fns/tz/tz/index.js +1 -0
  273. package/dist/node_modules/.pnpm/@date-fns_tz@1.5.0/node_modules/@date-fns/tz/tzName/index.js +11 -11
  274. package/dist/node_modules/.pnpm/@date-fns_tz@1.5.0/node_modules/@date-fns/tz/tzName/index.js.map +1 -1
  275. package/dist/node_modules/.pnpm/@date-fns_tz@1.5.0/node_modules/@date-fns/tz/tzOffset/index.js +22 -21
  276. package/dist/node_modules/.pnpm/@date-fns_tz@1.5.0/node_modules/@date-fns/tz/tzOffset/index.js.map +1 -1
  277. package/dist/node_modules/.pnpm/@tanstack_react-table@8.21.3_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/@tanstack/react-table/build/lib/index.js +36 -99
  278. package/dist/node_modules/.pnpm/@tanstack_react-table@8.21.3_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/@tanstack/react-table/build/lib/index.js.map +1 -1
  279. package/dist/node_modules/.pnpm/@tanstack_table-core@8.21.3/node_modules/@tanstack/table-core/build/lib/index.js +1478 -1852
  280. package/dist/node_modules/.pnpm/@tanstack_table-core@8.21.3/node_modules/@tanstack/table-core/build/lib/index.js.map +1 -1
  281. package/dist/node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.js +34 -35
  282. package/dist/node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.js.map +1 -1
  283. package/dist/node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.js +18 -15
  284. package/dist/node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.js.map +1 -1
  285. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/addLeadingZeros.js +7 -7
  286. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/addLeadingZeros.js.map +1 -1
  287. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/defaultOptions.js +8 -7
  288. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/defaultOptions.js.map +1 -1
  289. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/format/formatters.js +387 -580
  290. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/format/formatters.js.map +1 -1
  291. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/format/lightFormatters.js +44 -59
  292. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/format/lightFormatters.js.map +1 -1
  293. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/format/longFormatters.js +39 -52
  294. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/format/longFormatters.js.map +1 -1
  295. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/getTimezoneOffsetInMilliseconds.js +9 -18
  296. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/getTimezoneOffsetInMilliseconds.js.map +1 -1
  297. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/normalizeDates.js +9 -11
  298. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/normalizeDates.js.map +1 -1
  299. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/normalizeInterval.js +12 -8
  300. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/normalizeInterval.js.map +1 -1
  301. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/protectedTokens.js +21 -17
  302. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/_lib/protectedTokens.js.map +1 -1
  303. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/addDays.js +10 -9
  304. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/addDays.js.map +1 -1
  305. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/addMonths.js +13 -19
  306. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/addMonths.js.map +1 -1
  307. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/addWeeks.js +8 -7
  308. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/addWeeks.js.map +1 -1
  309. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/addYears.js +8 -7
  310. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/addYears.js.map +1 -1
  311. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/constants.js +12 -7
  312. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/constants.js.map +1 -1
  313. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/constructFrom.js +8 -7
  314. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/constructFrom.js.map +1 -1
  315. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/differenceInCalendarDays.js +12 -15
  316. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/differenceInCalendarDays.js.map +1 -1
  317. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/differenceInCalendarMonths.js +9 -12
  318. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/differenceInCalendarMonths.js.map +1 -1
  319. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/eachMonthOfInterval.js +16 -16
  320. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/eachMonthOfInterval.js.map +1 -1
  321. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/eachYearOfInterval.js +16 -16
  322. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/eachYearOfInterval.js.map +1 -1
  323. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/endOfISOWeek.js +11 -7
  324. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/endOfISOWeek.js.map +1 -1
  325. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/endOfMonth.js +9 -8
  326. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/endOfMonth.js.map +1 -1
  327. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/endOfWeek.js +10 -10
  328. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/endOfWeek.js.map +1 -1
  329. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/endOfYear.js +9 -8
  330. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/endOfYear.js.map +1 -1
  331. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/format.js +59 -57
  332. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/format.js.map +1 -1
  333. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getDayOfYear.js +11 -10
  334. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getDayOfYear.js.map +1 -1
  335. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getDaysInMonth.js +10 -9
  336. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getDaysInMonth.js.map +1 -1
  337. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getISOWeek.js +12 -11
  338. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getISOWeek.js.map +1 -1
  339. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getISOWeekYear.js +15 -14
  340. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getISOWeekYear.js.map +1 -1
  341. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getMonth.js +8 -7
  342. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getMonth.js.map +1 -1
  343. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getWeek.js +12 -11
  344. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getWeek.js.map +1 -1
  345. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getWeekYear.js +16 -16
  346. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getWeekYear.js.map +1 -1
  347. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getYear.js +8 -7
  348. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/getYear.js.map +1 -1
  349. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isAfter.js +8 -7
  350. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isAfter.js.map +1 -1
  351. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isBefore.js +8 -7
  352. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isBefore.js.map +1 -1
  353. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isDate.js +7 -6
  354. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isDate.js.map +1 -1
  355. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isSameDay.js +10 -13
  356. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isSameDay.js.map +1 -1
  357. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isSameMonth.js +9 -12
  358. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isSameMonth.js.map +1 -1
  359. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isSameYear.js +9 -12
  360. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isSameYear.js.map +1 -1
  361. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isValid.js +9 -8
  362. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/isValid.js.map +1 -1
  363. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/_lib/buildFormatLongFn.js +10 -9
  364. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/_lib/buildFormatLongFn.js.map +1 -1
  365. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/_lib/buildLocalizeFn.js +18 -18
  366. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/_lib/buildLocalizeFn.js.map +1 -1
  367. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/_lib/buildMatchFn.js +21 -29
  368. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/_lib/buildMatchFn.js.map +1 -1
  369. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/_lib/buildMatchPatternFn.js +19 -15
  370. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/_lib/buildMatchPatternFn.js.map +1 -1
  371. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US/_lib/formatDistance.js +70 -70
  372. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US/_lib/formatDistance.js.map +1 -1
  373. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US/_lib/formatLong.js +33 -33
  374. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US/_lib/formatLong.js.map +1 -1
  375. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US/_lib/formatRelative.js +13 -12
  376. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US/_lib/formatRelative.js.map +1 -1
  377. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US/_lib/localize.js +202 -154
  378. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US/_lib/localize.js.map +1 -1
  379. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US/_lib/match.js +125 -110
  380. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US/_lib/match.js.map +1 -1
  381. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US.js +20 -19
  382. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/locale/en-US.js.map +1 -1
  383. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/max.js +14 -13
  384. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/max.js.map +1 -1
  385. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/min.js +14 -13
  386. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/min.js.map +1 -1
  387. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/setMonth.js +13 -12
  388. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/setMonth.js.map +1 -1
  389. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/setYear.js +10 -9
  390. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/setYear.js.map +1 -1
  391. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfDay.js +9 -8
  392. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfDay.js.map +1 -1
  393. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfISOWeek.js +11 -7
  394. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfISOWeek.js.map +1 -1
  395. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfISOWeekYear.js +11 -10
  396. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfISOWeekYear.js.map +1 -1
  397. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfMonth.js +9 -8
  398. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfMonth.js.map +1 -1
  399. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfWeek.js +10 -10
  400. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfWeek.js.map +1 -1
  401. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfWeekYear.js +12 -12
  402. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfWeekYear.js.map +1 -1
  403. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfYear.js +9 -8
  404. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/startOfYear.js.map +1 -1
  405. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/toDate.js +8 -7
  406. package/dist/node_modules/.pnpm/date-fns@4.3.0/node_modules/date-fns/toDate.js.map +1 -1
  407. package/dist/node_modules/.pnpm/embla-carousel-react@8.6.0_react@19.2.6/node_modules/embla-carousel-react/esm/embla-carousel-react.esm.js +25 -24
  408. package/dist/node_modules/.pnpm/embla-carousel-react@8.6.0_react@19.2.6/node_modules/embla-carousel-react/esm/embla-carousel-react.esm.js.map +1 -1
  409. package/dist/node_modules/.pnpm/embla-carousel-reactive-utils@8.6.0_embla-carousel@8.6.0/node_modules/embla-carousel-reactive-utils/esm/embla-carousel-reactive-utils.esm.js +26 -30
  410. package/dist/node_modules/.pnpm/embla-carousel-reactive-utils@8.6.0_embla-carousel@8.6.0/node_modules/embla-carousel-reactive-utils/esm/embla-carousel-reactive-utils.esm.js.map +1 -1
  411. package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/embla-carousel.esm.js +1016 -1202
  412. package/dist/node_modules/.pnpm/embla-carousel@8.6.0/node_modules/embla-carousel/esm/embla-carousel.esm.js.map +1 -1
  413. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/DayPicker.js +398 -246
  414. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/DayPicker.js.map +1 -1
  415. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/UI.js +16 -18
  416. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/UI.js.map +1 -1
  417. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/classes/CalendarDay.js +13 -19
  418. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/classes/CalendarDay.js.map +1 -1
  419. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/classes/CalendarMonth.js +9 -8
  420. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/classes/CalendarMonth.js.map +1 -1
  421. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/classes/CalendarWeek.js +9 -8
  422. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/classes/CalendarWeek.js.map +1 -1
  423. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/classes/DateLib.js +107 -257
  424. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/classes/DateLib.js.map +1 -1
  425. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/CaptionLabel.js +8 -7
  426. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/CaptionLabel.js.map +1 -1
  427. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Chevron.js +14 -14
  428. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Chevron.js.map +1 -1
  429. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Day.js +9 -8
  430. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Day.js.map +1 -1
  431. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/DayButton.js +13 -10
  432. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/DayButton.js.map +1 -1
  433. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Dropdown.js +30 -19
  434. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Dropdown.js.map +1 -1
  435. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/DropdownNav.js +8 -7
  436. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/DropdownNav.js.map +1 -1
  437. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Footer.js +8 -7
  438. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Footer.js.map +1 -1
  439. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Month.js +9 -8
  440. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Month.js.map +1 -1
  441. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/MonthCaption.js +9 -8
  442. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/MonthCaption.js.map +1 -1
  443. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/MonthGrid.js +7 -6
  444. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/MonthGrid.js.map +1 -1
  445. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Months.js +7 -6
  446. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Months.js.map +1 -1
  447. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/MonthsDropdown.js +10 -9
  448. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/MonthsDropdown.js.map +1 -1
  449. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Nav.js +41 -27
  450. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Nav.js.map +1 -1
  451. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/NextMonthButton.js +7 -6
  452. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/NextMonthButton.js.map +1 -1
  453. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Option.js +7 -6
  454. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Option.js.map +1 -1
  455. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/PreviousMonthButton.js +7 -6
  456. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/PreviousMonthButton.js.map +1 -1
  457. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Root.js +12 -8
  458. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Root.js.map +1 -1
  459. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Select.js +8 -7
  460. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Select.js.map +1 -1
  461. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Week.js +9 -8
  462. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Week.js.map +1 -1
  463. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/WeekNumber.js +9 -8
  464. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/WeekNumber.js.map +1 -1
  465. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/WeekNumberHeader.js +8 -7
  466. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/WeekNumberHeader.js.map +1 -1
  467. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Weekday.js +8 -7
  468. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Weekday.js.map +1 -1
  469. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Weekdays.js +7 -10
  470. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Weekdays.js.map +1 -1
  471. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Weeks.js +8 -7
  472. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/Weeks.js.map +1 -1
  473. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/YearsDropdown.js +10 -9
  474. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/YearsDropdown.js.map +1 -1
  475. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/custom-components.js +57 -52
  476. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/components/custom-components.js.map +1 -1
  477. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatCaption.js +8 -7
  478. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatCaption.js.map +1 -1
  479. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatDay.js +8 -7
  480. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatDay.js.map +1 -1
  481. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatMonthDropdown.js +8 -7
  482. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatMonthDropdown.js.map +1 -1
  483. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatWeekNumber.js +8 -7
  484. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatWeekNumber.js.map +1 -1
  485. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatWeekNumberHeader.js +6 -5
  486. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatWeekNumberHeader.js.map +1 -1
  487. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatWeekdayName.js +8 -7
  488. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatWeekdayName.js.map +1 -1
  489. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatYearDropdown.js +8 -7
  490. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/formatYearDropdown.js.map +1 -1
  491. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/index.js +22 -17
  492. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/formatters/index.js.map +1 -1
  493. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/calculateFocusTarget.js +18 -17
  494. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/calculateFocusTarget.js.map +1 -1
  495. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/createGetModifiers.js +36 -41
  496. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/createGetModifiers.js.map +1 -1
  497. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/endOfBroadcastWeek.js +10 -9
  498. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/endOfBroadcastWeek.js.map +1 -1
  499. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getBroadcastWeeksInMonth.js +7 -7
  500. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getBroadcastWeeksInMonth.js.map +1 -1
  501. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getClassNamesForModifiers.js +8 -7
  502. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getClassNamesForModifiers.js.map +1 -1
  503. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getComponents.js +11 -10
  504. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getComponents.js.map +1 -1
  505. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getDataAttributes.js +17 -16
  506. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getDataAttributes.js.map +1 -1
  507. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getDates.js +20 -19
  508. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getDates.js.map +1 -1
  509. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getDays.js +11 -10
  510. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getDays.js.map +1 -1
  511. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getDefaultClassNames.js +12 -15
  512. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getDefaultClassNames.js.map +1 -1
  513. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getDisplayMonths.js +13 -13
  514. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getDisplayMonths.js.map +1 -1
  515. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getFocusableDate.js +15 -15
  516. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getFocusableDate.js.map +1 -1
  517. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getFormatters.js +11 -10
  518. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getFormatters.js.map +1 -1
  519. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getInitialMonth.js +8 -13
  520. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getInitialMonth.js.map +1 -1
  521. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getLabels.js +35 -35
  522. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getLabels.js.map +1 -1
  523. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getMonthOptions.js +18 -13
  524. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getMonthOptions.js.map +1 -1
  525. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getMonths.js +25 -24
  526. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getMonths.js.map +1 -1
  527. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getNavMonth.js +8 -11
  528. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getNavMonth.js.map +1 -1
  529. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getNextFocus.js +12 -12
  530. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getNextFocus.js.map +1 -1
  531. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getNextMonth.js +9 -12
  532. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getNextMonth.js.map +1 -1
  533. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getPreviousMonth.js +9 -12
  534. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getPreviousMonth.js.map +1 -1
  535. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getStyleForModifiers.js +14 -13
  536. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getStyleForModifiers.js.map +1 -1
  537. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getWeekdays.js +12 -11
  538. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getWeekdays.js.map +1 -1
  539. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getWeeks.js +7 -7
  540. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getWeeks.js.map +1 -1
  541. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getYearOptions.js +19 -16
  542. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/getYearOptions.js.map +1 -1
  543. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/startOfBroadcastWeek.js +8 -7
  544. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/startOfBroadcastWeek.js.map +1 -1
  545. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/useControlledValue.js +9 -8
  546. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/helpers/useControlledValue.js.map +1 -1
  547. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/index.js +30 -25
  548. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/index.js.map +1 -1
  549. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelDayButton.js +9 -8
  550. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelDayButton.js.map +1 -1
  551. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelGrid.js +7 -6
  552. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelGrid.js.map +1 -1
  553. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelGridcell.js +9 -8
  554. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelGridcell.js.map +1 -1
  555. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelMonthDropdown.js +7 -6
  556. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelMonthDropdown.js.map +1 -1
  557. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelNav.js +6 -5
  558. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelNav.js.map +1 -1
  559. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelNext.js +6 -7
  560. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelNext.js.map +1 -1
  561. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelPrevious.js +7 -6
  562. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelPrevious.js.map +1 -1
  563. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelWeekNumber.js +7 -6
  564. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelWeekNumber.js.map +1 -1
  565. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelWeekNumberHeader.js +7 -6
  566. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelWeekNumberHeader.js.map +1 -1
  567. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelWeekday.js +8 -7
  568. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelWeekday.js.map +1 -1
  569. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelYearDropdown.js +7 -6
  570. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/labels/labelYearDropdown.js.map +1 -1
  571. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/locale/en-US.js +50 -37
  572. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/locale/en-US.js.map +1 -1
  573. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/noonDateLib.js +101 -106
  574. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/noonDateLib.js.map +1 -1
  575. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/selection/useMulti.js +20 -21
  576. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/selection/useMulti.js.map +1 -1
  577. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/selection/useRange.js +29 -23
  578. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/selection/useRange.js.map +1 -1
  579. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/selection/useSingle.js +16 -15
  580. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/selection/useSingle.js.map +1 -1
  581. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/useAnimation.js +50 -56
  582. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/useAnimation.js.map +1 -1
  583. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/useCalendar.js +71 -76
  584. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/useCalendar.js.map +1 -1
  585. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/useDayPicker.js +11 -12
  586. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/useDayPicker.js.map +1 -1
  587. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/useFocus.js +23 -23
  588. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/useFocus.js.map +1 -1
  589. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/useSelection.js +16 -19
  590. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/useSelection.js.map +1 -1
  591. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/addToRange.js +60 -32
  592. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/addToRange.js.map +1 -1
  593. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/convertMatchersToTimeZone.js +24 -24
  594. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/convertMatchersToTimeZone.js.map +1 -1
  595. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/dateMatchModifiers.js +22 -26
  596. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/dateMatchModifiers.js.map +1 -1
  597. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/rangeContainsDayOfWeek.js +13 -15
  598. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/rangeContainsDayOfWeek.js.map +1 -1
  599. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/rangeContainsModifiers.js +29 -28
  600. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/rangeContainsModifiers.js.map +1 -1
  601. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/rangeIncludesDate.js +9 -9
  602. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/rangeIncludesDate.js.map +1 -1
  603. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/rangeOverlaps.js +9 -8
  604. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/rangeOverlaps.js.map +1 -1
  605. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/toTimeZone.js +9 -8
  606. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/toTimeZone.js.map +1 -1
  607. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/typeguards.js +15 -19
  608. package/dist/node_modules/.pnpm/react-day-picker@10.0.1_@types_react@19.2.15_react@19.2.6/node_modules/react-day-picker/dist/esm/utils/typeguards.js.map +1 -1
  609. package/dist/node_modules/.pnpm/react-resizable-panels@4.11.2_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/react-resizable-panels/dist/react-resizable-panels.js +1511 -2084
  610. package/dist/node_modules/.pnpm/react-resizable-panels@4.11.2_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/react-resizable-panels/dist/react-resizable-panels.js.map +1 -1
  611. package/dist/node_modules/.pnpm/tailwind-merge@3.6.0/node_modules/tailwind-merge/dist/bundle-mjs.js +1716 -2996
  612. package/dist/node_modules/.pnpm/tailwind-merge@3.6.0/node_modules/tailwind-merge/dist/bundle-mjs.js.map +1 -1
  613. package/dist/react.js +125 -550
  614. package/dist/src/components/ui/input-num-picker/index.d.ts +1 -0
  615. package/dist/src/components/ui/input-num-picker/input-num-picker.d.ts +14 -0
  616. package/dist/src/index.d.ts +1 -0
  617. package/dist/ui-react.css +2 -1
  618. package/package.json +7 -7
  619. package/dist/index.js.map +0 -1
  620. package/dist/react.js.map +0 -1
@@ -1,115 +1,106 @@
1
- import * as u from "react";
2
- const y = {
3
- page: "tbl_page",
4
- size: "tbl_size",
5
- sort: "tbl_sort",
6
- filter: "tbl_filter"
1
+ import * as e from "react";
2
+ //#region src/hooks/use-table-url-state.ts
3
+ var t = {
4
+ page: "tbl_page",
5
+ size: "tbl_size",
6
+ sort: "tbl_sort",
7
+ filter: "tbl_filter"
7
8
  };
8
- function b(e, r) {
9
- return typeof e == "function" ? e(r) : e;
9
+ function n(e, t) {
10
+ return typeof e == "function" ? e(t) : e;
10
11
  }
11
- function z(e, {
12
- defaultPageSize: r = 10,
13
- paramKeys: i
14
- } = {}) {
15
- const a = i ?? y, o = new URLSearchParams(e), t = Number(o.get(a.page)), s = Number.isFinite(t) && t >= 1 ? Math.floor(t) - 1 : 0, c = Number(o.get(a.size)), S = Number.isFinite(c) && c >= 1 ? Math.floor(c) : r, g = o.get(a.sort), m = /* @__PURE__ */ new Map();
16
- if (g)
17
- for (const l of g.split(",")) {
18
- const f = l.indexOf(":");
19
- if (f === -1) continue;
20
- const p = l.slice(0, f), h = l.slice(f + 1);
21
- !p || h !== "asc" && h !== "desc" || m.set(p, { id: p, desc: h === "desc" });
22
- }
23
- const n = Array.from(m.values()), d = o.get(a.filter), w = d ? d.split(",").map((l) => {
24
- const f = l.indexOf(":");
25
- if (f === -1) return null;
26
- const p = l.slice(0, f);
27
- if (!p) return null;
28
- try {
29
- return { id: p, value: decodeURIComponent(l.slice(f + 1)) };
30
- } catch {
31
- return null;
32
- }
33
- }).filter((l) => l !== null) : [];
34
- return { pagination: { pageIndex: s, pageSize: S }, sorting: n, columnFilters: w };
12
+ function r(e, { defaultPageSize: n = 10, paramKeys: r } = {}) {
13
+ let i = r ?? t, a = new URLSearchParams(e), o = Number(a.get(i.page)), s = Number.isFinite(o) && o >= 1 ? Math.floor(o) - 1 : 0, c = Number(a.get(i.size)), l = Number.isFinite(c) && c >= 1 ? Math.floor(c) : n, u = a.get(i.sort), d = /* @__PURE__ */ new Map();
14
+ if (u) for (let e of u.split(",")) {
15
+ let t = e.indexOf(":");
16
+ if (t === -1) continue;
17
+ let n = e.slice(0, t), r = e.slice(t + 1);
18
+ !n || r !== "asc" && r !== "desc" || d.set(n, {
19
+ id: n,
20
+ desc: r === "desc"
21
+ });
22
+ }
23
+ let f = Array.from(d.values()), p = a.get(i.filter), m = p ? p.split(",").map((e) => {
24
+ let t = e.indexOf(":");
25
+ if (t === -1) return null;
26
+ let n = e.slice(0, t);
27
+ if (!n) return null;
28
+ try {
29
+ return {
30
+ id: n,
31
+ value: decodeURIComponent(e.slice(t + 1))
32
+ };
33
+ } catch {
34
+ return null;
35
+ }
36
+ }).filter((e) => e !== null) : [];
37
+ return {
38
+ pagination: {
39
+ pageIndex: s,
40
+ pageSize: l
41
+ },
42
+ sorting: f,
43
+ columnFilters: m
44
+ };
35
45
  }
36
- function P(e, r, {
37
- defaultPageSize: i = 10,
38
- paramKeys: a
39
- } = {}) {
40
- const o = a ?? y, t = new URLSearchParams(r);
41
- for (const s of Object.values(o)) t.delete(s);
42
- return e.pagination.pageIndex > 0 && t.set(o.page, String(e.pagination.pageIndex + 1)), e.pagination.pageSize !== i && t.set(o.size, String(e.pagination.pageSize)), e.sorting.length > 0 && t.set(
43
- o.sort,
44
- e.sorting.map((s) => `${s.id}:${s.desc ? "desc" : "asc"}`).join(",")
45
- ), e.columnFilters.length > 0 && t.set(
46
- o.filter,
47
- e.columnFilters.map((s) => `${s.id}:${encodeURIComponent(s.value)}`).join(",")
48
- ), t.toString();
46
+ function i(e, n, { defaultPageSize: r = 10, paramKeys: i } = {}) {
47
+ let a = i ?? t, o = new URLSearchParams(n);
48
+ for (let e of Object.values(a)) o.delete(e);
49
+ return e.pagination.pageIndex > 0 && o.set(a.page, String(e.pagination.pageIndex + 1)), e.pagination.pageSize !== r && o.set(a.size, String(e.pagination.pageSize)), e.sorting.length > 0 && o.set(a.sort, e.sorting.map((e) => `${e.id}:${e.desc ? "desc" : "asc"}`).join(",")), e.columnFilters.length > 0 && o.set(a.filter, e.columnFilters.map((e) => `${e.id}:${encodeURIComponent(e.value)}`).join(",")), o.toString();
49
50
  }
50
- function R(e, r) {
51
- const i = typeof window < "u" ? window.location.search : "";
52
- return z(i, { defaultPageSize: e, paramKeys: r });
51
+ function a(e, t) {
52
+ return r(typeof window < "u" ? window.location.search : "", {
53
+ defaultPageSize: e,
54
+ paramKeys: t
55
+ });
53
56
  }
54
- function U(e = {}) {
55
- const { defaultPageSize: r = 10 } = e, i = u.useMemo(
56
- () => ({ ...y, ...e.paramKeys }),
57
- [e.paramKeys]
58
- ), [a, o] = u.useState(
59
- () => R(r, i)
60
- ), t = u.useRef(a);
61
- t.current = a;
62
- const s = u.useRef(!1);
63
- u.useEffect(() => {
64
- if (typeof window > "u") return;
65
- const n = () => {
66
- o(R(r, i));
67
- };
68
- return window.addEventListener("popstate", n), () => window.removeEventListener("popstate", n);
69
- }, [r, i]);
70
- const c = u.useCallback(
71
- (n) => {
72
- if (t.current = n, o(n), typeof window > "u") return;
73
- const d = P(n, window.location.search, {
74
- defaultPageSize: r,
75
- paramKeys: i
76
- }), w = `${window.location.pathname}${d ? `?${d}` : ""}${window.location.hash}`;
77
- s.current ? window.history.replaceState(null, "", w) : (window.history.pushState(null, "", w), s.current = !0, queueMicrotask(() => {
78
- s.current = !1;
79
- }));
80
- },
81
- [r, i]
82
- ), S = u.useCallback(
83
- (n) => {
84
- c({
85
- ...t.current,
86
- pagination: b(n, t.current.pagination)
87
- });
88
- },
89
- [c]
90
- ), g = u.useCallback(
91
- (n) => {
92
- c({
93
- ...t.current,
94
- sorting: b(n, t.current.sorting)
95
- });
96
- },
97
- [c]
98
- ), m = u.useCallback(
99
- (n) => {
100
- c({
101
- ...t.current,
102
- columnFilters: b(n, t.current.columnFilters)
103
- });
104
- },
105
- [c]
106
- );
107
- return { state: a, setPagination: S, setSorting: g, setColumnFilters: m };
57
+ function o(r = {}) {
58
+ let { defaultPageSize: o = 10 } = r, s = e.useMemo(() => ({
59
+ ...t,
60
+ ...r.paramKeys
61
+ }), [r.paramKeys]), [c, l] = e.useState(() => a(o, s)), u = e.useRef(c);
62
+ u.current = c;
63
+ let d = e.useRef(!1);
64
+ e.useEffect(() => {
65
+ if (typeof window > "u") return;
66
+ let e = () => {
67
+ l(a(o, s));
68
+ };
69
+ return window.addEventListener("popstate", e), () => window.removeEventListener("popstate", e);
70
+ }, [o, s]);
71
+ let f = e.useCallback((e) => {
72
+ if (u.current = e, l(e), typeof window > "u") return;
73
+ let t = i(e, window.location.search, {
74
+ defaultPageSize: o,
75
+ paramKeys: s
76
+ }), n = `${window.location.pathname}${t ? `?${t}` : ""}${window.location.hash}`;
77
+ d.current ? window.history.replaceState(null, "", n) : (window.history.pushState(null, "", n), d.current = !0, queueMicrotask(() => {
78
+ d.current = !1;
79
+ }));
80
+ }, [o, s]);
81
+ return {
82
+ state: c,
83
+ setPagination: e.useCallback((e) => {
84
+ f({
85
+ ...u.current,
86
+ pagination: n(e, u.current.pagination)
87
+ });
88
+ }, [f]),
89
+ setSorting: e.useCallback((e) => {
90
+ f({
91
+ ...u.current,
92
+ sorting: n(e, u.current.sorting)
93
+ });
94
+ }, [f]),
95
+ setColumnFilters: e.useCallback((e) => {
96
+ f({
97
+ ...u.current,
98
+ columnFilters: n(e, u.current.columnFilters)
99
+ });
100
+ }, [f])
101
+ };
108
102
  }
109
- export {
110
- y as DEFAULT_TABLE_URL_PARAM_KEYS,
111
- z as parseTableUrlState,
112
- P as serializeTableUrlState,
113
- U as useTableUrlState
114
- };
115
- //# sourceMappingURL=use-table-url-state.js.map
103
+ //#endregion
104
+ export { t as DEFAULT_TABLE_URL_PARAM_KEYS, r as parseTableUrlState, i as serializeTableUrlState, o as useTableUrlState };
105
+
106
+ //# sourceMappingURL=use-table-url-state.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"use-table-url-state.js","sources":["../../src/hooks/use-table-url-state.ts"],"sourcesContent":["import * as React from 'react';\n\nexport interface TablePaginationState {\n /** Zero-based page index. */\n pageIndex: number;\n /** Rows per page. */\n pageSize: number;\n}\n\nexport interface TableSortingState {\n /** Column id. */\n id: string;\n /** `true` for descending. */\n desc: boolean;\n}\n\nexport interface TableColumnFilterState {\n /** Column id. */\n id: string;\n /** Filter value (string-encoded in the URL). */\n value: string;\n}\n\n/**\n * Controlled table state. The three fields mirror TanStack's `PaginationState`,\n * `SortingState`, and `ColumnFiltersState` shapes (filter value narrowed to\n * `string`) so they can wire straight into `onPaginationChange` /\n * `onSortingChange` / `onColumnFiltersChange`.\n */\nexport interface TableUrlState {\n pagination: TablePaginationState;\n sorting: TableSortingState[];\n columnFilters: TableColumnFilterState[];\n}\n\n/** Query-string keys. Namespaced (`tbl_*`) to avoid collisions with Storybook's\n * own `path`/`args`/`globals` params on a shared preview-iframe URL. */\nexport interface TableUrlParamKeys {\n page: string;\n size: string;\n sort: string;\n filter: string;\n}\n\nexport const DEFAULT_TABLE_URL_PARAM_KEYS: TableUrlParamKeys = {\n page: 'tbl_page',\n size: 'tbl_size',\n sort: 'tbl_sort',\n filter: 'tbl_filter',\n};\n\nexport interface UseTableUrlStateOptions {\n /** Default page size; omitted from the URL when the size matches it. */\n defaultPageSize?: number;\n /** Override the namespaced query-string keys. */\n paramKeys?: Partial<TableUrlParamKeys>;\n}\n\nexport type TableUrlUpdater<T> = T | ((old: T) => T);\n\nexport interface UseTableUrlStateResult {\n state: TableUrlState;\n /** Accepts a value or updater — shaped for TanStack's `onPaginationChange`. */\n setPagination: (updater: TableUrlUpdater<TablePaginationState>) => void;\n /** Accepts a value or updater — shaped for TanStack's `onSortingChange`. */\n setSorting: (updater: TableUrlUpdater<TableSortingState[]>) => void;\n /** Accepts a value or updater — shaped for TanStack's `onColumnFiltersChange`. */\n setColumnFilters: (\n updater: TableUrlUpdater<TableColumnFilterState[]>\n ) => void;\n}\n\nfunction applyUpdater<T>(updater: TableUrlUpdater<T>, old: T): T {\n return typeof updater === 'function'\n ? (updater as (old: T) => T)(old)\n : updater;\n}\n\n/**\n * Parses table state out of a query string. Pure — safe to reuse for seeding a\n * story or an SSR default. `search` may include or omit the leading `?`.\n *\n * Encoding: `tbl_page` is 1-based; `tbl_sort` is `id:asc|desc` pairs joined by\n * `,`; `tbl_filter` is `id:<encoded-value>` pairs joined by `,` (the value is\n * `encodeURIComponent`-escaped so it may contain `:`/`,`). Column ids must not\n * contain `:` or `,`.\n */\nexport function parseTableUrlState(\n search: string,\n {\n defaultPageSize = 10,\n paramKeys,\n }: { defaultPageSize?: number; paramKeys?: TableUrlParamKeys } = {}\n): TableUrlState {\n const keys = paramKeys ?? DEFAULT_TABLE_URL_PARAM_KEYS;\n const params = new URLSearchParams(search);\n\n const rawPage = Number(params.get(keys.page));\n const pageIndex =\n Number.isFinite(rawPage) && rawPage >= 1 ? Math.floor(rawPage) - 1 : 0;\n\n const rawSize = Number(params.get(keys.size));\n const pageSize =\n Number.isFinite(rawSize) && rawSize >= 1 ? Math.floor(rawSize) : defaultPageSize;\n\n const sortParam = params.get(keys.sort);\n const sortingById = new Map<string, TableSortingState>();\n if (sortParam) {\n for (const pair of sortParam.split(',')) {\n const separator = pair.indexOf(':');\n if (separator === -1) continue;\n const id = pair.slice(0, separator);\n const dir = pair.slice(separator + 1);\n if (!id || (dir !== 'asc' && dir !== 'desc')) continue;\n // Last occurrence wins on a duplicate id — matches URLSearchParams'\n // own semantics for a repeated key.\n sortingById.set(id, { id, desc: dir === 'desc' });\n }\n }\n const sorting: TableSortingState[] = Array.from(sortingById.values());\n\n const filterParam = params.get(keys.filter);\n const columnFilters: TableColumnFilterState[] = filterParam\n ? filterParam\n .split(',')\n .map((pair) => {\n const separator = pair.indexOf(':');\n if (separator === -1) return null;\n const id = pair.slice(0, separator);\n if (!id) return null;\n try {\n return { id, value: decodeURIComponent(pair.slice(separator + 1)) };\n } catch {\n return null;\n }\n })\n .filter((entry): entry is TableColumnFilterState => entry !== null)\n : [];\n\n return { pagination: { pageIndex, pageSize }, sorting, columnFilters };\n}\n\n/**\n * Serializes table state onto a query string, preserving any foreign params\n * already present in `search` (e.g. Storybook's `path`/`args`/`globals`).\n * Returns the query string without a leading `?` (empty string when no params).\n */\nexport function serializeTableUrlState(\n state: TableUrlState,\n search: string,\n {\n defaultPageSize = 10,\n paramKeys,\n }: { defaultPageSize?: number; paramKeys?: TableUrlParamKeys } = {}\n): string {\n const keys = paramKeys ?? DEFAULT_TABLE_URL_PARAM_KEYS;\n const params = new URLSearchParams(search);\n\n // Clear our namespaced keys before rewriting so a cleared field drops out.\n for (const key of Object.values(keys)) params.delete(key);\n\n if (state.pagination.pageIndex > 0) {\n params.set(keys.page, String(state.pagination.pageIndex + 1));\n }\n if (state.pagination.pageSize !== defaultPageSize) {\n params.set(keys.size, String(state.pagination.pageSize));\n }\n if (state.sorting.length > 0) {\n params.set(\n keys.sort,\n state.sorting\n .map((entry) => `${entry.id}:${entry.desc ? 'desc' : 'asc'}`)\n .join(',')\n );\n }\n if (state.columnFilters.length > 0) {\n params.set(\n keys.filter,\n state.columnFilters\n .map((entry) => `${entry.id}:${encodeURIComponent(entry.value)}`)\n .join(',')\n );\n }\n\n return params.toString();\n}\n\nfunction readCurrentState(\n defaultPageSize: number,\n paramKeys: TableUrlParamKeys\n): TableUrlState {\n const search = typeof window !== 'undefined' ? window.location.search : '';\n return parseTableUrlState(search, { defaultPageSize, paramKeys });\n}\n\n/**\n * Router-agnostic hook that syncs controlled table state (pagination / sorting\n * / column filters) to and from the URL query string via `history.pushState` +\n * `popstate`. Depends only on `window.location` / `window.history`, so it works\n * with any router (or none). Query keys are namespaced (`tbl_*`) so they never\n * collide with other params on the same URL. Reads initial state from the URL,\n * so a bookmarked link restores the table's view.\n */\nexport function useTableUrlState(\n options: UseTableUrlStateOptions = {}\n): UseTableUrlStateResult {\n const { defaultPageSize = 10 } = options;\n const paramKeys = React.useMemo<TableUrlParamKeys>(\n () => ({ ...DEFAULT_TABLE_URL_PARAM_KEYS, ...options.paramKeys }),\n [options.paramKeys]\n );\n\n const [state, setState] = React.useState<TableUrlState>(() =>\n readCurrentState(defaultPageSize, paramKeys)\n );\n\n // Keep a ref of the latest state so `popstate` and the setters can compute\n // the next URL/state without re-subscribing on every change.\n const stateRef = React.useRef(state);\n stateRef.current = state;\n\n // Coalesce multiple setters called synchronously in the same handler (e.g. a\n // filter change that also resets the page) into a single history entry: the\n // first commit in a tick pushes, later ones in the same tick replace. The\n // flag clears on a microtask so the next distinct user action pushes again.\n const hasPushedThisTickRef = React.useRef(false);\n\n React.useEffect(() => {\n if (typeof window === 'undefined') return;\n const onPopState = () => {\n setState(readCurrentState(defaultPageSize, paramKeys));\n };\n window.addEventListener('popstate', onPopState);\n return () => window.removeEventListener('popstate', onPopState);\n }, [defaultPageSize, paramKeys]);\n\n const commit = React.useCallback(\n (next: TableUrlState) => {\n // Refresh the ref here, not just in the render body — two setters\n // called synchronously in the same handler (before React re-renders)\n // must see each other's updates, not the pre-batch snapshot.\n stateRef.current = next;\n setState(next);\n if (typeof window === 'undefined') return;\n const query = serializeTableUrlState(next, window.location.search, {\n defaultPageSize,\n paramKeys,\n });\n const url = `${window.location.pathname}${query ? `?${query}` : ''}${window.location.hash}`;\n if (hasPushedThisTickRef.current) {\n window.history.replaceState(null, '', url);\n } else {\n window.history.pushState(null, '', url);\n hasPushedThisTickRef.current = true;\n queueMicrotask(() => {\n hasPushedThisTickRef.current = false;\n });\n }\n },\n [defaultPageSize, paramKeys]\n );\n\n const setPagination = React.useCallback(\n (updater: TableUrlUpdater<TablePaginationState>) => {\n commit({\n ...stateRef.current,\n pagination: applyUpdater(updater, stateRef.current.pagination),\n });\n },\n [commit]\n );\n\n const setSorting = React.useCallback(\n (updater: TableUrlUpdater<TableSortingState[]>) => {\n commit({\n ...stateRef.current,\n sorting: applyUpdater(updater, stateRef.current.sorting),\n });\n },\n [commit]\n );\n\n const setColumnFilters = React.useCallback(\n (updater: TableUrlUpdater<TableColumnFilterState[]>) => {\n commit({\n ...stateRef.current,\n columnFilters: applyUpdater(updater, stateRef.current.columnFilters),\n });\n },\n [commit]\n );\n\n return { state, setPagination, setSorting, setColumnFilters };\n}\n"],"names":["DEFAULT_TABLE_URL_PARAM_KEYS","applyUpdater","updater","old","parseTableUrlState","search","defaultPageSize","paramKeys","keys","params","rawPage","pageIndex","rawSize","pageSize","sortParam","sortingById","pair","separator","id","dir","sorting","filterParam","columnFilters","entry","serializeTableUrlState","state","key","readCurrentState","useTableUrlState","options","React","setState","stateRef","hasPushedThisTickRef","onPopState","commit","next","query","url","setPagination","setSorting","setColumnFilters"],"mappings":";AA4CO,MAAMA,IAAkD;AAAA,EAC7D,MAAM;AAAA,EACN,MAAM;AAAA,EACN,MAAM;AAAA,EACN,QAAQ;AACV;AAuBA,SAASC,EAAgBC,GAA6BC,GAAW;AAC/D,SAAO,OAAOD,KAAY,aACrBA,EAA0BC,CAAG,IAC9BD;AACN;AAWO,SAASE,EACdC,GACA;AAAA,EACE,iBAAAC,IAAkB;AAAA,EAClB,WAAAC;AACF,IAAiE,IAClD;AACf,QAAMC,IAAOD,KAAaP,GACpBS,IAAS,IAAI,gBAAgBJ,CAAM,GAEnCK,IAAU,OAAOD,EAAO,IAAID,EAAK,IAAI,CAAC,GACtCG,IACJ,OAAO,SAASD,CAAO,KAAKA,KAAW,IAAI,KAAK,MAAMA,CAAO,IAAI,IAAI,GAEjEE,IAAU,OAAOH,EAAO,IAAID,EAAK,IAAI,CAAC,GACtCK,IACJ,OAAO,SAASD,CAAO,KAAKA,KAAW,IAAI,KAAK,MAAMA,CAAO,IAAIN,GAE7DQ,IAAYL,EAAO,IAAID,EAAK,IAAI,GAChCO,wBAAkB,IAAA;AACxB,MAAID;AACF,eAAWE,KAAQF,EAAU,MAAM,GAAG,GAAG;AACvC,YAAMG,IAAYD,EAAK,QAAQ,GAAG;AAClC,UAAIC,MAAc,GAAI;AACtB,YAAMC,IAAKF,EAAK,MAAM,GAAGC,CAAS,GAC5BE,IAAMH,EAAK,MAAMC,IAAY,CAAC;AACpC,MAAI,CAACC,KAAOC,MAAQ,SAASA,MAAQ,UAGrCJ,EAAY,IAAIG,GAAI,EAAE,IAAAA,GAAI,MAAMC,MAAQ,QAAQ;AAAA,IAClD;AAEF,QAAMC,IAA+B,MAAM,KAAKL,EAAY,QAAQ,GAE9DM,IAAcZ,EAAO,IAAID,EAAK,MAAM,GACpCc,IAA0CD,IAC5CA,EACG,MAAM,GAAG,EACT,IAAI,CAACL,MAAS;AACb,UAAMC,IAAYD,EAAK,QAAQ,GAAG;AAClC,QAAIC,MAAc,GAAI,QAAO;AAC7B,UAAMC,IAAKF,EAAK,MAAM,GAAGC,CAAS;AAClC,QAAI,CAACC,EAAI,QAAO;AAChB,QAAI;AACF,aAAO,EAAE,IAAAA,GAAI,OAAO,mBAAmBF,EAAK,MAAMC,IAAY,CAAC,CAAC,EAAA;AAAA,IAClE,QAAQ;AACN,aAAO;AAAA,IACT;AAAA,EACF,CAAC,EACA,OAAO,CAACM,MAA2CA,MAAU,IAAI,IACpE,CAAA;AAEJ,SAAO,EAAE,YAAY,EAAE,WAAAZ,GAAW,UAAAE,EAAA,GAAY,SAAAO,GAAS,eAAAE,EAAA;AACzD;AAOO,SAASE,EACdC,GACApB,GACA;AAAA,EACE,iBAAAC,IAAkB;AAAA,EAClB,WAAAC;AACF,IAAiE,IACzD;AACR,QAAMC,IAAOD,KAAaP,GACpBS,IAAS,IAAI,gBAAgBJ,CAAM;AAGzC,aAAWqB,KAAO,OAAO,OAAOlB,CAAI,EAAG,CAAAC,EAAO,OAAOiB,CAAG;AAExD,SAAID,EAAM,WAAW,YAAY,KAC/BhB,EAAO,IAAID,EAAK,MAAM,OAAOiB,EAAM,WAAW,YAAY,CAAC,CAAC,GAE1DA,EAAM,WAAW,aAAanB,KAChCG,EAAO,IAAID,EAAK,MAAM,OAAOiB,EAAM,WAAW,QAAQ,CAAC,GAErDA,EAAM,QAAQ,SAAS,KACzBhB,EAAO;AAAA,IACLD,EAAK;AAAA,IACLiB,EAAM,QACH,IAAI,CAACF,MAAU,GAAGA,EAAM,EAAE,IAAIA,EAAM,OAAO,SAAS,KAAK,EAAE,EAC3D,KAAK,GAAG;AAAA,EAAA,GAGXE,EAAM,cAAc,SAAS,KAC/BhB,EAAO;AAAA,IACLD,EAAK;AAAA,IACLiB,EAAM,cACH,IAAI,CAACF,MAAU,GAAGA,EAAM,EAAE,IAAI,mBAAmBA,EAAM,KAAK,CAAC,EAAE,EAC/D,KAAK,GAAG;AAAA,EAAA,GAIRd,EAAO,SAAA;AAChB;AAEA,SAASkB,EACPrB,GACAC,GACe;AACf,QAAMF,IAAS,OAAO,SAAW,MAAc,OAAO,SAAS,SAAS;AACxE,SAAOD,EAAmBC,GAAQ,EAAE,iBAAAC,GAAiB,WAAAC,GAAW;AAClE;AAUO,SAASqB,EACdC,IAAmC,IACX;AACxB,QAAM,EAAE,iBAAAvB,IAAkB,GAAA,IAAOuB,GAC3BtB,IAAYuB,EAAM;AAAA,IACtB,OAAO,EAAE,GAAG9B,GAA8B,GAAG6B,EAAQ,UAAA;AAAA,IACrD,CAACA,EAAQ,SAAS;AAAA,EAAA,GAGd,CAACJ,GAAOM,CAAQ,IAAID,EAAM;AAAA,IAAwB,MACtDH,EAAiBrB,GAAiBC,CAAS;AAAA,EAAA,GAKvCyB,IAAWF,EAAM,OAAOL,CAAK;AACnC,EAAAO,EAAS,UAAUP;AAMnB,QAAMQ,IAAuBH,EAAM,OAAO,EAAK;AAE/C,EAAAA,EAAM,UAAU,MAAM;AACpB,QAAI,OAAO,SAAW,IAAa;AACnC,UAAMI,IAAa,MAAM;AACvB,MAAAH,EAASJ,EAAiBrB,GAAiBC,CAAS,CAAC;AAAA,IACvD;AACA,kBAAO,iBAAiB,YAAY2B,CAAU,GACvC,MAAM,OAAO,oBAAoB,YAAYA,CAAU;AAAA,EAChE,GAAG,CAAC5B,GAAiBC,CAAS,CAAC;AAE/B,QAAM4B,IAASL,EAAM;AAAA,IACnB,CAACM,MAAwB;AAMvB,UAFAJ,EAAS,UAAUI,GACnBL,EAASK,CAAI,GACT,OAAO,SAAW,IAAa;AACnC,YAAMC,IAAQb,EAAuBY,GAAM,OAAO,SAAS,QAAQ;AAAA,QACjE,iBAAA9B;AAAA,QACA,WAAAC;AAAA,MAAA,CACD,GACK+B,IAAM,GAAG,OAAO,SAAS,QAAQ,GAAGD,IAAQ,IAAIA,CAAK,KAAK,EAAE,GAAG,OAAO,SAAS,IAAI;AACzF,MAAIJ,EAAqB,UACvB,OAAO,QAAQ,aAAa,MAAM,IAAIK,CAAG,KAEzC,OAAO,QAAQ,UAAU,MAAM,IAAIA,CAAG,GACtCL,EAAqB,UAAU,IAC/B,eAAe,MAAM;AACnB,QAAAA,EAAqB,UAAU;AAAA,MACjC,CAAC;AAAA,IAEL;AAAA,IACA,CAAC3B,GAAiBC,CAAS;AAAA,EAAA,GAGvBgC,IAAgBT,EAAM;AAAA,IAC1B,CAAC5B,MAAmD;AAClD,MAAAiC,EAAO;AAAA,QACL,GAAGH,EAAS;AAAA,QACZ,YAAY/B,EAAaC,GAAS8B,EAAS,QAAQ,UAAU;AAAA,MAAA,CAC9D;AAAA,IACH;AAAA,IACA,CAACG,CAAM;AAAA,EAAA,GAGHK,IAAaV,EAAM;AAAA,IACvB,CAAC5B,MAAkD;AACjD,MAAAiC,EAAO;AAAA,QACL,GAAGH,EAAS;AAAA,QACZ,SAAS/B,EAAaC,GAAS8B,EAAS,QAAQ,OAAO;AAAA,MAAA,CACxD;AAAA,IACH;AAAA,IACA,CAACG,CAAM;AAAA,EAAA,GAGHM,IAAmBX,EAAM;AAAA,IAC7B,CAAC5B,MAAuD;AACtD,MAAAiC,EAAO;AAAA,QACL,GAAGH,EAAS;AAAA,QACZ,eAAe/B,EAAaC,GAAS8B,EAAS,QAAQ,aAAa;AAAA,MAAA,CACpE;AAAA,IACH;AAAA,IACA,CAACG,CAAM;AAAA,EAAA;AAGT,SAAO,EAAE,OAAAV,GAAO,eAAAc,GAAe,YAAAC,GAAY,kBAAAC,EAAA;AAC7C;"}
1
+ {"version":3,"file":"use-table-url-state.js","names":[],"sources":["../../src/hooks/use-table-url-state.ts"],"sourcesContent":["import * as React from 'react';\n\nexport interface TablePaginationState {\n /** Zero-based page index. */\n pageIndex: number;\n /** Rows per page. */\n pageSize: number;\n}\n\nexport interface TableSortingState {\n /** Column id. */\n id: string;\n /** `true` for descending. */\n desc: boolean;\n}\n\nexport interface TableColumnFilterState {\n /** Column id. */\n id: string;\n /** Filter value (string-encoded in the URL). */\n value: string;\n}\n\n/**\n * Controlled table state. The three fields mirror TanStack's `PaginationState`,\n * `SortingState`, and `ColumnFiltersState` shapes (filter value narrowed to\n * `string`) so they can wire straight into `onPaginationChange` /\n * `onSortingChange` / `onColumnFiltersChange`.\n */\nexport interface TableUrlState {\n pagination: TablePaginationState;\n sorting: TableSortingState[];\n columnFilters: TableColumnFilterState[];\n}\n\n/** Query-string keys. Namespaced (`tbl_*`) to avoid collisions with Storybook's\n * own `path`/`args`/`globals` params on a shared preview-iframe URL. */\nexport interface TableUrlParamKeys {\n page: string;\n size: string;\n sort: string;\n filter: string;\n}\n\nexport const DEFAULT_TABLE_URL_PARAM_KEYS: TableUrlParamKeys = {\n page: 'tbl_page',\n size: 'tbl_size',\n sort: 'tbl_sort',\n filter: 'tbl_filter',\n};\n\nexport interface UseTableUrlStateOptions {\n /** Default page size; omitted from the URL when the size matches it. */\n defaultPageSize?: number;\n /** Override the namespaced query-string keys. */\n paramKeys?: Partial<TableUrlParamKeys>;\n}\n\nexport type TableUrlUpdater<T> = T | ((old: T) => T);\n\nexport interface UseTableUrlStateResult {\n state: TableUrlState;\n /** Accepts a value or updater — shaped for TanStack's `onPaginationChange`. */\n setPagination: (updater: TableUrlUpdater<TablePaginationState>) => void;\n /** Accepts a value or updater — shaped for TanStack's `onSortingChange`. */\n setSorting: (updater: TableUrlUpdater<TableSortingState[]>) => void;\n /** Accepts a value or updater — shaped for TanStack's `onColumnFiltersChange`. */\n setColumnFilters: (\n updater: TableUrlUpdater<TableColumnFilterState[]>\n ) => void;\n}\n\nfunction applyUpdater<T>(updater: TableUrlUpdater<T>, old: T): T {\n return typeof updater === 'function'\n ? (updater as (old: T) => T)(old)\n : updater;\n}\n\n/**\n * Parses table state out of a query string. Pure — safe to reuse for seeding a\n * story or an SSR default. `search` may include or omit the leading `?`.\n *\n * Encoding: `tbl_page` is 1-based; `tbl_sort` is `id:asc|desc` pairs joined by\n * `,`; `tbl_filter` is `id:<encoded-value>` pairs joined by `,` (the value is\n * `encodeURIComponent`-escaped so it may contain `:`/`,`). Column ids must not\n * contain `:` or `,`.\n */\nexport function parseTableUrlState(\n search: string,\n {\n defaultPageSize = 10,\n paramKeys,\n }: { defaultPageSize?: number; paramKeys?: TableUrlParamKeys } = {}\n): TableUrlState {\n const keys = paramKeys ?? DEFAULT_TABLE_URL_PARAM_KEYS;\n const params = new URLSearchParams(search);\n\n const rawPage = Number(params.get(keys.page));\n const pageIndex =\n Number.isFinite(rawPage) && rawPage >= 1 ? Math.floor(rawPage) - 1 : 0;\n\n const rawSize = Number(params.get(keys.size));\n const pageSize =\n Number.isFinite(rawSize) && rawSize >= 1 ? Math.floor(rawSize) : defaultPageSize;\n\n const sortParam = params.get(keys.sort);\n const sortingById = new Map<string, TableSortingState>();\n if (sortParam) {\n for (const pair of sortParam.split(',')) {\n const separator = pair.indexOf(':');\n if (separator === -1) continue;\n const id = pair.slice(0, separator);\n const dir = pair.slice(separator + 1);\n if (!id || (dir !== 'asc' && dir !== 'desc')) continue;\n // Last occurrence wins on a duplicate id — matches URLSearchParams'\n // own semantics for a repeated key.\n sortingById.set(id, { id, desc: dir === 'desc' });\n }\n }\n const sorting: TableSortingState[] = Array.from(sortingById.values());\n\n const filterParam = params.get(keys.filter);\n const columnFilters: TableColumnFilterState[] = filterParam\n ? filterParam\n .split(',')\n .map((pair) => {\n const separator = pair.indexOf(':');\n if (separator === -1) return null;\n const id = pair.slice(0, separator);\n if (!id) return null;\n try {\n return { id, value: decodeURIComponent(pair.slice(separator + 1)) };\n } catch {\n return null;\n }\n })\n .filter((entry): entry is TableColumnFilterState => entry !== null)\n : [];\n\n return { pagination: { pageIndex, pageSize }, sorting, columnFilters };\n}\n\n/**\n * Serializes table state onto a query string, preserving any foreign params\n * already present in `search` (e.g. Storybook's `path`/`args`/`globals`).\n * Returns the query string without a leading `?` (empty string when no params).\n */\nexport function serializeTableUrlState(\n state: TableUrlState,\n search: string,\n {\n defaultPageSize = 10,\n paramKeys,\n }: { defaultPageSize?: number; paramKeys?: TableUrlParamKeys } = {}\n): string {\n const keys = paramKeys ?? DEFAULT_TABLE_URL_PARAM_KEYS;\n const params = new URLSearchParams(search);\n\n // Clear our namespaced keys before rewriting so a cleared field drops out.\n for (const key of Object.values(keys)) params.delete(key);\n\n if (state.pagination.pageIndex > 0) {\n params.set(keys.page, String(state.pagination.pageIndex + 1));\n }\n if (state.pagination.pageSize !== defaultPageSize) {\n params.set(keys.size, String(state.pagination.pageSize));\n }\n if (state.sorting.length > 0) {\n params.set(\n keys.sort,\n state.sorting\n .map((entry) => `${entry.id}:${entry.desc ? 'desc' : 'asc'}`)\n .join(',')\n );\n }\n if (state.columnFilters.length > 0) {\n params.set(\n keys.filter,\n state.columnFilters\n .map((entry) => `${entry.id}:${encodeURIComponent(entry.value)}`)\n .join(',')\n );\n }\n\n return params.toString();\n}\n\nfunction readCurrentState(\n defaultPageSize: number,\n paramKeys: TableUrlParamKeys\n): TableUrlState {\n const search = typeof window !== 'undefined' ? window.location.search : '';\n return parseTableUrlState(search, { defaultPageSize, paramKeys });\n}\n\n/**\n * Router-agnostic hook that syncs controlled table state (pagination / sorting\n * / column filters) to and from the URL query string via `history.pushState` +\n * `popstate`. Depends only on `window.location` / `window.history`, so it works\n * with any router (or none). Query keys are namespaced (`tbl_*`) so they never\n * collide with other params on the same URL. Reads initial state from the URL,\n * so a bookmarked link restores the table's view.\n */\nexport function useTableUrlState(\n options: UseTableUrlStateOptions = {}\n): UseTableUrlStateResult {\n const { defaultPageSize = 10 } = options;\n const paramKeys = React.useMemo<TableUrlParamKeys>(\n () => ({ ...DEFAULT_TABLE_URL_PARAM_KEYS, ...options.paramKeys }),\n [options.paramKeys]\n );\n\n const [state, setState] = React.useState<TableUrlState>(() =>\n readCurrentState(defaultPageSize, paramKeys)\n );\n\n // Keep a ref of the latest state so `popstate` and the setters can compute\n // the next URL/state without re-subscribing on every change.\n const stateRef = React.useRef(state);\n stateRef.current = state;\n\n // Coalesce multiple setters called synchronously in the same handler (e.g. a\n // filter change that also resets the page) into a single history entry: the\n // first commit in a tick pushes, later ones in the same tick replace. The\n // flag clears on a microtask so the next distinct user action pushes again.\n const hasPushedThisTickRef = React.useRef(false);\n\n React.useEffect(() => {\n if (typeof window === 'undefined') return;\n const onPopState = () => {\n setState(readCurrentState(defaultPageSize, paramKeys));\n };\n window.addEventListener('popstate', onPopState);\n return () => window.removeEventListener('popstate', onPopState);\n }, [defaultPageSize, paramKeys]);\n\n const commit = React.useCallback(\n (next: TableUrlState) => {\n // Refresh the ref here, not just in the render body — two setters\n // called synchronously in the same handler (before React re-renders)\n // must see each other's updates, not the pre-batch snapshot.\n stateRef.current = next;\n setState(next);\n if (typeof window === 'undefined') return;\n const query = serializeTableUrlState(next, window.location.search, {\n defaultPageSize,\n paramKeys,\n });\n const url = `${window.location.pathname}${query ? `?${query}` : ''}${window.location.hash}`;\n if (hasPushedThisTickRef.current) {\n window.history.replaceState(null, '', url);\n } else {\n window.history.pushState(null, '', url);\n hasPushedThisTickRef.current = true;\n queueMicrotask(() => {\n hasPushedThisTickRef.current = false;\n });\n }\n },\n [defaultPageSize, paramKeys]\n );\n\n const setPagination = React.useCallback(\n (updater: TableUrlUpdater<TablePaginationState>) => {\n commit({\n ...stateRef.current,\n pagination: applyUpdater(updater, stateRef.current.pagination),\n });\n },\n [commit]\n );\n\n const setSorting = React.useCallback(\n (updater: TableUrlUpdater<TableSortingState[]>) => {\n commit({\n ...stateRef.current,\n sorting: applyUpdater(updater, stateRef.current.sorting),\n });\n },\n [commit]\n );\n\n const setColumnFilters = React.useCallback(\n (updater: TableUrlUpdater<TableColumnFilterState[]>) => {\n commit({\n ...stateRef.current,\n columnFilters: applyUpdater(updater, stateRef.current.columnFilters),\n });\n },\n [commit]\n );\n\n return { state, setPagination, setSorting, setColumnFilters };\n}\n"],"mappings":"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"}
@@ -1,75 +1,61 @@
1
- import * as l from "react";
2
- const f = {
3
- completed: { avatarColor: "green", avatarClassName: "[box-shadow:none]" },
4
- current: {
5
- avatarColor: "blue",
6
- avatarClassName: "[box-shadow:none] text-[var(--ui-stepper-item-current-label-color)]"
7
- },
8
- future: {
9
- avatarColor: "gray",
10
- avatarClassName: "[box-shadow:none] text-[var(--ui-stepper-item-future-label-color)]"
11
- }
1
+ import * as e from "react";
2
+ //#region src/hooks/use-wizard.ts
3
+ var t = {
4
+ completed: {
5
+ avatarColor: "green",
6
+ avatarClassName: "[box-shadow:none]"
7
+ },
8
+ current: {
9
+ avatarColor: "blue",
10
+ avatarClassName: "[box-shadow:none] text-[var(--ui-stepper-item-current-label-color)]"
11
+ },
12
+ future: {
13
+ avatarColor: "gray",
14
+ avatarClassName: "[box-shadow:none] text-[var(--ui-stepper-item-future-label-color)]"
15
+ }
12
16
  };
13
- function u(e, n) {
14
- return Math.min(Math.max(e, 0), n - 1);
17
+ function n(e, t) {
18
+ return Math.min(Math.max(e, 0), t - 1);
15
19
  }
16
- function d(e, n) {
17
- if (typeof n == "number")
18
- return Number.isNaN(n) ? null : u(Math.trunc(n), e.length);
19
- const t = e.findIndex((c) => c.id === n);
20
- return t === -1 ? null : t;
20
+ function r(e, t) {
21
+ if (typeof t == "number") return Number.isNaN(t) ? null : n(Math.trunc(t), e.length);
22
+ let r = e.findIndex((e) => e.id === t);
23
+ return r === -1 ? null : r;
21
24
  }
22
- function S({
23
- steps: e,
24
- initialStep: n = 0
25
- }) {
26
- var i;
27
- if (e.length === 0)
28
- throw new Error("useWizard: `steps` must not be empty.");
29
- const t = e.length, [c, s] = l.useState(
30
- () => d(e, n) ?? 0
31
- ), r = u(c, t), b = l.useCallback(() => {
32
- s(
33
- (a) => u(u(a, t) + 1, t)
34
- );
35
- }, [t]), p = l.useCallback(() => {
36
- s(
37
- (a) => u(u(a, t) - 1, t)
38
- );
39
- }, [t]), x = l.useCallback(
40
- (a) => {
41
- const o = d(e, a);
42
- o !== null && s(o);
43
- },
44
- [e]
45
- );
46
- return {
47
- steps: l.useMemo(
48
- () => e.map((a, o) => {
49
- const m = o < r ? "completed" : o === r ? "current" : "future";
50
- return {
51
- ...a,
52
- index: o,
53
- stepNumber: o + 1,
54
- variant: m,
55
- ...f[m]
56
- };
57
- }),
58
- [e, r]
59
- ),
60
- currentIndex: r,
61
- currentStepNumber: r + 1,
62
- stepCount: t,
63
- currentStepLabel: e[r].label,
64
- nextStepLabel: (i = e[r + 1]) == null ? void 0 : i.label,
65
- isFirstStep: r === 0,
66
- isLastStep: r === t - 1,
67
- goToNextStep: b,
68
- goToPreviousStep: p,
69
- goToStep: x
70
- };
25
+ function i({ steps: i, initialStep: a = 0 }) {
26
+ if (i.length === 0) throw Error("useWizard: `steps` must not be empty.");
27
+ let o = i.length, [s, c] = e.useState(() => r(i, a) ?? 0), l = n(s, o), u = e.useCallback(() => {
28
+ c((e) => n(n(e, o) + 1, o));
29
+ }, [o]), d = e.useCallback(() => {
30
+ c((e) => n(n(e, o) - 1, o));
31
+ }, [o]), f = e.useCallback((e) => {
32
+ let t = r(i, e);
33
+ t !== null && c(t);
34
+ }, [i]);
35
+ return {
36
+ steps: e.useMemo(() => i.map((e, n) => {
37
+ let r = n < l ? "completed" : n === l ? "current" : "future";
38
+ return {
39
+ ...e,
40
+ index: n,
41
+ stepNumber: n + 1,
42
+ variant: r,
43
+ ...t[r]
44
+ };
45
+ }), [i, l]),
46
+ currentIndex: l,
47
+ currentStepNumber: l + 1,
48
+ stepCount: o,
49
+ currentStepLabel: i[l].label,
50
+ nextStepLabel: i[l + 1]?.label,
51
+ isFirstStep: l === 0,
52
+ isLastStep: l === o - 1,
53
+ goToNextStep: u,
54
+ goToPreviousStep: d,
55
+ goToStep: f
56
+ };
71
57
  }
72
- export {
73
- S as useWizard
74
- };
75
- //# sourceMappingURL=use-wizard.js.map
58
+ //#endregion
59
+ export { i as useWizard };
60
+
61
+ //# sourceMappingURL=use-wizard.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"use-wizard.js","sources":["../../src/hooks/use-wizard.ts"],"sourcesContent":["import * as React from 'react';\n\nexport interface WizardStep {\n /** Stable identifier; `goToStep` and `initialStep` accept it as a string. */\n id: string;\n /** Step label, rendered by `StepperItem` and the `Stepper` summary. */\n label: string;\n}\n\nexport type WizardStepAvatarColor = 'blue' | 'green' | 'gray';\n\nexport type WizardStepVariant = 'completed' | 'current' | 'future';\n\n/**\n * A step enriched with everything a `StepperItem` needs. Intersects `TStep`, so\n * any extra fields the consumer put on their own step objects survive.\n */\nexport type WizardStepState<TStep extends WizardStep = WizardStep> = TStep & {\n /** Zero-based position in `steps`. */\n index: number;\n /** One-based position, for the avatar's displayed number. */\n stepNumber: number;\n /** `StepperItem`'s `variant`, derived from the position vs. `currentIndex`. */\n variant: WizardStepVariant;\n /** `Avatar`'s `color` for this step's variant. */\n avatarColor: WizardStepAvatarColor;\n /** Classes to merge onto this step's `Avatar`. */\n avatarClassName: string;\n};\n\nexport interface UseWizardOptions<TStep extends WizardStep = WizardStep> {\n /** The flow's steps, in order. Must not be empty. */\n steps: TStep[];\n /**\n * Where the flow starts — a zero-based index or a step `id`. A numeric\n * index is truncated toward zero and clamped into range; `NaN` and an id\n * that matches no step fall back to the first step. A seed, not a\n * controlled input: later changes are ignored.\n */\n initialStep?: number | string;\n}\n\nexport interface UseWizardResult<TStep extends WizardStep = WizardStep> {\n /** `steps` with per-step `variant`/avatar presentation derived. */\n steps: WizardStepState<TStep>[];\n /**\n * Zero-based index of the active step. Always a valid index into `steps`:\n * if `steps` shrinks so that the stored index is past the end, the\n * effective index clamps to `steps.length - 1`.\n */\n currentIndex: number;\n /** One-based number of the active step, for `Stepper`'s `currentStep`. */\n currentStepNumber: number;\n /** Total number of steps, for `Stepper`'s `totalSteps`. */\n stepCount: number;\n /** The active step's label, for `Stepper`'s `current`. */\n currentStepLabel: string;\n /** The following step's label, or `undefined` on the last step. */\n nextStepLabel: string | undefined;\n isFirstStep: boolean;\n isLastStep: boolean;\n /** Advance one step; no-op on the last step (never wraps). */\n goToNextStep: () => void;\n /** Go back one step; no-op on the first step (never wraps). */\n goToPreviousStep: () => void;\n /**\n * Jump to a zero-based index or a step `id`. A numeric index is truncated\n * toward zero (`1.5` → `1`) and clamped into range; `NaN` is a no-op. An\n * id that matches no step is a no-op; on duplicate ids the first wins.\n */\n goToStep: (target: number | string) => void;\n}\n\nconst AVATAR_BY_VARIANT: Record<\n WizardStepVariant,\n { avatarColor: WizardStepAvatarColor; avatarClassName: string }\n> = {\n completed: { avatarColor: 'green', avatarClassName: '[box-shadow:none]' },\n current: {\n avatarColor: 'blue',\n avatarClassName:\n '[box-shadow:none] text-[var(--ui-stepper-item-current-label-color)]',\n },\n future: {\n avatarColor: 'gray',\n avatarClassName:\n '[box-shadow:none] text-[var(--ui-stepper-item-future-label-color)]',\n },\n};\n\nfunction clampIndex(index: number, stepCount: number): number {\n return Math.min(Math.max(index, 0), stepCount - 1);\n}\n\n// Numbers are truncated toward zero and clamped into range; `NaN` and ids that\n// match nothing resolve to `null`, which callers treat as a no-op.\nfunction resolveStepIndex(\n steps: readonly WizardStep[],\n target: number | string\n): number | null {\n if (typeof target === 'number') {\n if (Number.isNaN(target)) return null;\n return clampIndex(Math.trunc(target), steps.length);\n }\n const index = steps.findIndex((step) => step.id === target);\n return index === -1 ? null : index;\n}\n\n/**\n * Headless step state for a `Wizard`'s `Stepper` (the `Wizard` components\n * themselves stay presentational and own no state). Returns the `Stepper`\n * summary props plus a per-step `variant` + avatar presentation, and the\n * navigation callbacks a consumer wires to its Back/Next buttons.\n *\n * Opt-in: a consumer that already owns its step state can keep driving\n * `Stepper`/`StepperItem` by hand.\n *\n * `steps` may be a live, per-render value. The active index is stored as\n * state but re-clamped against the *current* `steps.length` on every read,\n * so a `steps` array that shrinks past the active index resolves to the last\n * remaining step instead of reading past the end.\n */\nexport function useWizard<TStep extends WizardStep = WizardStep>({\n steps,\n initialStep = 0,\n}: UseWizardOptions<TStep>): UseWizardResult<TStep> {\n if (steps.length === 0) {\n throw new Error('useWizard: `steps` must not be empty.');\n }\n\n const stepCount = steps.length;\n\n const [storedIndex, setCurrentIndex] = React.useState(\n () => resolveStepIndex(steps, initialStep) ?? 0\n );\n\n // `storedIndex` can outlive the step it pointed at, so every read goes\n // through the clamp rather than trusting the stored value.\n const currentIndex = clampIndex(storedIndex, stepCount);\n\n // Both step relative to the *clamped* current index, so a `steps` array that\n // shrank does not leave the stored value skipping steps on the way back.\n const goToNextStep = React.useCallback(() => {\n setCurrentIndex((current) =>\n clampIndex(clampIndex(current, stepCount) + 1, stepCount)\n );\n }, [stepCount]);\n\n const goToPreviousStep = React.useCallback(() => {\n setCurrentIndex((current) =>\n clampIndex(clampIndex(current, stepCount) - 1, stepCount)\n );\n }, [stepCount]);\n\n const goToStep = React.useCallback(\n (target: number | string) => {\n const index = resolveStepIndex(steps, target);\n if (index === null) return;\n setCurrentIndex(index);\n },\n [steps]\n );\n\n const derivedSteps = React.useMemo(\n () =>\n steps.map((step, index) => {\n const variant: WizardStepVariant =\n index < currentIndex\n ? 'completed'\n : index === currentIndex\n ? 'current'\n : 'future';\n return {\n ...step,\n index,\n stepNumber: index + 1,\n variant,\n ...AVATAR_BY_VARIANT[variant],\n };\n }),\n [steps, currentIndex]\n );\n\n return {\n steps: derivedSteps,\n currentIndex,\n currentStepNumber: currentIndex + 1,\n stepCount,\n currentStepLabel: steps[currentIndex].label,\n nextStepLabel: steps[currentIndex + 1]?.label,\n isFirstStep: currentIndex === 0,\n isLastStep: currentIndex === stepCount - 1,\n goToNextStep,\n goToPreviousStep,\n goToStep,\n };\n}\n"],"names":["AVATAR_BY_VARIANT","clampIndex","index","stepCount","resolveStepIndex","steps","target","step","useWizard","initialStep","storedIndex","setCurrentIndex","React","currentIndex","goToNextStep","current","goToPreviousStep","goToStep","variant","_a"],"mappings":";AAyEA,MAAMA,IAGF;AAAA,EACF,WAAW,EAAE,aAAa,SAAS,iBAAiB,oBAAA;AAAA,EACpD,SAAS;AAAA,IACP,aAAa;AAAA,IACb,iBACE;AAAA,EAAA;AAAA,EAEJ,QAAQ;AAAA,IACN,aAAa;AAAA,IACb,iBACE;AAAA,EAAA;AAEN;AAEA,SAASC,EAAWC,GAAeC,GAA2B;AAC5D,SAAO,KAAK,IAAI,KAAK,IAAID,GAAO,CAAC,GAAGC,IAAY,CAAC;AACnD;AAIA,SAASC,EACPC,GACAC,GACe;AACf,MAAI,OAAOA,KAAW;AACpB,WAAI,OAAO,MAAMA,CAAM,IAAU,OAC1BL,EAAW,KAAK,MAAMK,CAAM,GAAGD,EAAM,MAAM;AAEpD,QAAMH,IAAQG,EAAM,UAAU,CAACE,MAASA,EAAK,OAAOD,CAAM;AAC1D,SAAOJ,MAAU,KAAK,OAAOA;AAC/B;AAgBO,SAASM,EAAiD;AAAA,EAC/D,OAAAH;AAAA,EACA,aAAAI,IAAc;AAChB,GAAoD;;AAClD,MAAIJ,EAAM,WAAW;AACnB,UAAM,IAAI,MAAM,uCAAuC;AAGzD,QAAMF,IAAYE,EAAM,QAElB,CAACK,GAAaC,CAAe,IAAIC,EAAM;AAAA,IAC3C,MAAMR,EAAiBC,GAAOI,CAAW,KAAK;AAAA,EAAA,GAK1CI,IAAeZ,EAAWS,GAAaP,CAAS,GAIhDW,IAAeF,EAAM,YAAY,MAAM;AAC3C,IAAAD;AAAA,MAAgB,CAACI,MACfd,EAAWA,EAAWc,GAASZ,CAAS,IAAI,GAAGA,CAAS;AAAA,IAAA;AAAA,EAE5D,GAAG,CAACA,CAAS,CAAC,GAERa,IAAmBJ,EAAM,YAAY,MAAM;AAC/C,IAAAD;AAAA,MAAgB,CAACI,MACfd,EAAWA,EAAWc,GAASZ,CAAS,IAAI,GAAGA,CAAS;AAAA,IAAA;AAAA,EAE5D,GAAG,CAACA,CAAS,CAAC,GAERc,IAAWL,EAAM;AAAA,IACrB,CAACN,MAA4B;AAC3B,YAAMJ,IAAQE,EAAiBC,GAAOC,CAAM;AAC5C,MAAIJ,MAAU,QACdS,EAAgBT,CAAK;AAAA,IACvB;AAAA,IACA,CAACG,CAAK;AAAA,EAAA;AAuBR,SAAO;AAAA,IACL,OArBmBO,EAAM;AAAA,MACzB,MACEP,EAAM,IAAI,CAACE,GAAML,MAAU;AACzB,cAAMgB,IACJhB,IAAQW,IACJ,cACAX,MAAUW,IACR,YACA;AACR,eAAO;AAAA,UACL,GAAGN;AAAA,UACH,OAAAL;AAAA,UACA,YAAYA,IAAQ;AAAA,UACpB,SAAAgB;AAAA,UACA,GAAGlB,EAAkBkB,CAAO;AAAA,QAAA;AAAA,MAEhC,CAAC;AAAA,MACH,CAACb,GAAOQ,CAAY;AAAA,IAAA;AAAA,IAKpB,cAAAA;AAAA,IACA,mBAAmBA,IAAe;AAAA,IAClC,WAAAV;AAAA,IACA,kBAAkBE,EAAMQ,CAAY,EAAE;AAAA,IACtC,gBAAeM,IAAAd,EAAMQ,IAAe,CAAC,MAAtB,gBAAAM,EAAyB;AAAA,IACxC,aAAaN,MAAiB;AAAA,IAC9B,YAAYA,MAAiBV,IAAY;AAAA,IACzC,cAAAW;AAAA,IACA,kBAAAE;AAAA,IACA,UAAAC;AAAA,EAAA;AAEJ;"}
1
+ {"version":3,"file":"use-wizard.js","names":[],"sources":["../../src/hooks/use-wizard.ts"],"sourcesContent":["import * as React from 'react';\n\nexport interface WizardStep {\n /** Stable identifier; `goToStep` and `initialStep` accept it as a string. */\n id: string;\n /** Step label, rendered by `StepperItem` and the `Stepper` summary. */\n label: string;\n}\n\nexport type WizardStepAvatarColor = 'blue' | 'green' | 'gray';\n\nexport type WizardStepVariant = 'completed' | 'current' | 'future';\n\n/**\n * A step enriched with everything a `StepperItem` needs. Intersects `TStep`, so\n * any extra fields the consumer put on their own step objects survive.\n */\nexport type WizardStepState<TStep extends WizardStep = WizardStep> = TStep & {\n /** Zero-based position in `steps`. */\n index: number;\n /** One-based position, for the avatar's displayed number. */\n stepNumber: number;\n /** `StepperItem`'s `variant`, derived from the position vs. `currentIndex`. */\n variant: WizardStepVariant;\n /** `Avatar`'s `color` for this step's variant. */\n avatarColor: WizardStepAvatarColor;\n /** Classes to merge onto this step's `Avatar`. */\n avatarClassName: string;\n};\n\nexport interface UseWizardOptions<TStep extends WizardStep = WizardStep> {\n /** The flow's steps, in order. Must not be empty. */\n steps: TStep[];\n /**\n * Where the flow starts — a zero-based index or a step `id`. A numeric\n * index is truncated toward zero and clamped into range; `NaN` and an id\n * that matches no step fall back to the first step. A seed, not a\n * controlled input: later changes are ignored.\n */\n initialStep?: number | string;\n}\n\nexport interface UseWizardResult<TStep extends WizardStep = WizardStep> {\n /** `steps` with per-step `variant`/avatar presentation derived. */\n steps: WizardStepState<TStep>[];\n /**\n * Zero-based index of the active step. Always a valid index into `steps`:\n * if `steps` shrinks so that the stored index is past the end, the\n * effective index clamps to `steps.length - 1`.\n */\n currentIndex: number;\n /** One-based number of the active step, for `Stepper`'s `currentStep`. */\n currentStepNumber: number;\n /** Total number of steps, for `Stepper`'s `totalSteps`. */\n stepCount: number;\n /** The active step's label, for `Stepper`'s `current`. */\n currentStepLabel: string;\n /** The following step's label, or `undefined` on the last step. */\n nextStepLabel: string | undefined;\n isFirstStep: boolean;\n isLastStep: boolean;\n /** Advance one step; no-op on the last step (never wraps). */\n goToNextStep: () => void;\n /** Go back one step; no-op on the first step (never wraps). */\n goToPreviousStep: () => void;\n /**\n * Jump to a zero-based index or a step `id`. A numeric index is truncated\n * toward zero (`1.5` → `1`) and clamped into range; `NaN` is a no-op. An\n * id that matches no step is a no-op; on duplicate ids the first wins.\n */\n goToStep: (target: number | string) => void;\n}\n\nconst AVATAR_BY_VARIANT: Record<\n WizardStepVariant,\n { avatarColor: WizardStepAvatarColor; avatarClassName: string }\n> = {\n completed: { avatarColor: 'green', avatarClassName: '[box-shadow:none]' },\n current: {\n avatarColor: 'blue',\n avatarClassName:\n '[box-shadow:none] text-[var(--ui-stepper-item-current-label-color)]',\n },\n future: {\n avatarColor: 'gray',\n avatarClassName:\n '[box-shadow:none] text-[var(--ui-stepper-item-future-label-color)]',\n },\n};\n\nfunction clampIndex(index: number, stepCount: number): number {\n return Math.min(Math.max(index, 0), stepCount - 1);\n}\n\n// Numbers are truncated toward zero and clamped into range; `NaN` and ids that\n// match nothing resolve to `null`, which callers treat as a no-op.\nfunction resolveStepIndex(\n steps: readonly WizardStep[],\n target: number | string\n): number | null {\n if (typeof target === 'number') {\n if (Number.isNaN(target)) return null;\n return clampIndex(Math.trunc(target), steps.length);\n }\n const index = steps.findIndex((step) => step.id === target);\n return index === -1 ? null : index;\n}\n\n/**\n * Headless step state for a `Wizard`'s `Stepper` (the `Wizard` components\n * themselves stay presentational and own no state). Returns the `Stepper`\n * summary props plus a per-step `variant` + avatar presentation, and the\n * navigation callbacks a consumer wires to its Back/Next buttons.\n *\n * Opt-in: a consumer that already owns its step state can keep driving\n * `Stepper`/`StepperItem` by hand.\n *\n * `steps` may be a live, per-render value. The active index is stored as\n * state but re-clamped against the *current* `steps.length` on every read,\n * so a `steps` array that shrinks past the active index resolves to the last\n * remaining step instead of reading past the end.\n */\nexport function useWizard<TStep extends WizardStep = WizardStep>({\n steps,\n initialStep = 0,\n}: UseWizardOptions<TStep>): UseWizardResult<TStep> {\n if (steps.length === 0) {\n throw new Error('useWizard: `steps` must not be empty.');\n }\n\n const stepCount = steps.length;\n\n const [storedIndex, setCurrentIndex] = React.useState(\n () => resolveStepIndex(steps, initialStep) ?? 0\n );\n\n // `storedIndex` can outlive the step it pointed at, so every read goes\n // through the clamp rather than trusting the stored value.\n const currentIndex = clampIndex(storedIndex, stepCount);\n\n // Both step relative to the *clamped* current index, so a `steps` array that\n // shrank does not leave the stored value skipping steps on the way back.\n const goToNextStep = React.useCallback(() => {\n setCurrentIndex((current) =>\n clampIndex(clampIndex(current, stepCount) + 1, stepCount)\n );\n }, [stepCount]);\n\n const goToPreviousStep = React.useCallback(() => {\n setCurrentIndex((current) =>\n clampIndex(clampIndex(current, stepCount) - 1, stepCount)\n );\n }, [stepCount]);\n\n const goToStep = React.useCallback(\n (target: number | string) => {\n const index = resolveStepIndex(steps, target);\n if (index === null) return;\n setCurrentIndex(index);\n },\n [steps]\n );\n\n const derivedSteps = React.useMemo(\n () =>\n steps.map((step, index) => {\n const variant: WizardStepVariant =\n index < currentIndex\n ? 'completed'\n : index === currentIndex\n ? 'current'\n : 'future';\n return {\n ...step,\n index,\n stepNumber: index + 1,\n variant,\n ...AVATAR_BY_VARIANT[variant],\n };\n }),\n [steps, currentIndex]\n );\n\n return {\n steps: derivedSteps,\n currentIndex,\n currentStepNumber: currentIndex + 1,\n stepCount,\n currentStepLabel: steps[currentIndex].label,\n nextStepLabel: steps[currentIndex + 1]?.label,\n isFirstStep: currentIndex === 0,\n isLastStep: currentIndex === stepCount - 1,\n goToNextStep,\n goToPreviousStep,\n goToStep,\n };\n}\n"],"mappings":";;AAyEA,IAAM,IAGF;CACF,WAAW;EAAE,aAAa;EAAS,iBAAiB;CAAoB;CACxE,SAAS;EACP,aAAa;EACb,iBACE;CACJ;CACA,QAAQ;EACN,aAAa;EACb,iBACE;CACJ;AACF;AAEA,SAAS,EAAW,GAAe,GAA2B;CAC5D,OAAO,KAAK,IAAI,KAAK,IAAI,GAAO,CAAC,GAAG,IAAY,CAAC;AACnD;AAIA,SAAS,EACP,GACA,GACe;CACf,IAAI,OAAO,KAAW,UAEpB,OADI,OAAO,MAAM,CAAM,IAAU,OAC1B,EAAW,KAAK,MAAM,CAAM,GAAG,EAAM,MAAM;CAEpD,IAAM,IAAQ,EAAM,WAAW,MAAS,EAAK,OAAO,CAAM;CAC1D,OAAO,MAAU,KAAK,OAAO;AAC/B;AAgBA,SAAgB,EAAiD,EAC/D,UACA,iBAAc,KACoC;CAClD,IAAI,EAAM,WAAW,GACnB,MAAU,MAAM,uCAAuC;CAGzD,IAAM,IAAY,EAAM,QAElB,CAAC,GAAa,KAAmB,EAAM,eACrC,EAAiB,GAAO,CAAW,KAAK,CAChD,GAIM,IAAe,EAAW,GAAa,CAAS,GAIhD,IAAe,EAAM,kBAAkB;EAC3C,GAAiB,MACf,EAAW,EAAW,GAAS,CAAS,IAAI,GAAG,CAAS,CAC1D;CACF,GAAG,CAAC,CAAS,CAAC,GAER,IAAmB,EAAM,kBAAkB;EAC/C,GAAiB,MACf,EAAW,EAAW,GAAS,CAAS,IAAI,GAAG,CAAS,CAC1D;CACF,GAAG,CAAC,CAAS,CAAC,GAER,IAAW,EAAM,aACpB,MAA4B;EAC3B,IAAM,IAAQ,EAAiB,GAAO,CAAM;EACxC,MAAU,QACd,EAAgB,CAAK;CACvB,GACA,CAAC,CAAK,CACR;CAsBA,OAAO;EACL,OArBmB,EAAM,cAEvB,EAAM,KAAK,GAAM,MAAU;GACzB,IAAM,IACJ,IAAQ,IACJ,cACA,MAAU,IACR,YACA;GACR,OAAO;IACL,GAAG;IACH;IACA,YAAY,IAAQ;IACpB;IACA,GAAG,EAAkB;GACvB;EACF,CAAC,GACH,CAAC,GAAO,CAAY,CAIb;EACP;EACA,mBAAmB,IAAe;EAClC;EACA,kBAAkB,EAAM,EAAa,CAAC;EACtC,eAAe,EAAM,IAAe,EAAE,EAAE;EACxC,aAAa,MAAiB;EAC9B,YAAY,MAAiB,IAAY;EACzC;EACA;EACA;CACF;AACF"}