@slotted/react 0.1.0-beta.10 → 0.1.0-beta.12

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 (329) hide show
  1. package/dist/action-bar-z2DPc1Wy.js +285 -0
  2. package/dist/action-bar.js +1 -1
  3. package/dist/action-sheet-BnedGewu.js +360 -0
  4. package/dist/action-sheet.js +1 -1
  5. package/dist/{alert-BTcqbG8w.js → alert-BTAXJ69M.js} +5 -5
  6. package/dist/alert.js +1 -1
  7. package/dist/{app-shell-BlkqQrOx.js → app-shell-Cb_kDBeV.js} +232 -173
  8. package/dist/app-shell.js +1 -1
  9. package/dist/{attachment-zlOPJvIm.js → attachment-D1O4qS8H.js} +28 -28
  10. package/dist/attachment.js +1 -1
  11. package/dist/{breadcrumb-DCGynpkb.js → breadcrumb-CnFjxxI2.js} +10 -10
  12. package/dist/breadcrumb.js +1 -1
  13. package/dist/{button-BCVjdzkn.js → button-D31perSu.js} +2 -2
  14. package/dist/button.js +2 -2
  15. package/dist/{calendar-qGUJ-kAy.js → calendar-DZyC1gAT.js} +8 -8
  16. package/dist/calendar.js +1 -1
  17. package/dist/{carousel-CjRTu8m7.js → carousel-Dso3gcYd.js} +14 -14
  18. package/dist/carousel.js +1 -1
  19. package/dist/cascader-BbajBwsX.js +1157 -0
  20. package/dist/cascader.js +1 -1
  21. package/dist/{chart-CPFq3jIE.js → chart-Bb6ctahn.js} +9 -9
  22. package/dist/chart.js +1 -1
  23. package/dist/{checkbox-CMY2KIih.js → checkbox-C_8GVtjD.js} +3 -3
  24. package/dist/{checkbox-group-DzMtLF7f.js → checkbox-group-DXCcusol.js} +2 -2
  25. package/dist/checkbox-group.js +1 -1
  26. package/dist/checkbox.js +1 -1
  27. package/dist/{code-block-Bh_2Eg3M.js → code-block-C4mtsROE.js} +8 -8
  28. package/dist/code-block.js +1 -1
  29. package/dist/{color-picker-DlepH5co.js → color-picker-JZPnPb7s.js} +49 -49
  30. package/dist/color-picker.js +1 -1
  31. package/dist/{column-manager-CV9tCnKa.js → column-manager-BDUj-WIs.js} +31 -31
  32. package/dist/column-manager.js +1 -1
  33. package/dist/combobox-Dn69QwGX.js +904 -0
  34. package/dist/combobox.js +1 -1
  35. package/dist/command-palette-Dh1HKz_F.js +744 -0
  36. package/dist/command-palette.js +1 -1
  37. package/dist/{context-menu-Dbc0KkFp.js → context-menu-uJjEmAN3.js} +1 -1
  38. package/dist/context-menu.js +1 -1
  39. package/dist/{currency-field--wIfgVAx.js → currency-field-lHcrNJ7X.js} +13 -13
  40. package/dist/currency-field.js +1 -1
  41. package/dist/{dashboard-grid-D_LbWfdZ.js → dashboard-grid-z-SOm9H0.js} +65 -65
  42. package/dist/dashboard-grid.js +1 -1
  43. package/dist/{data-grid-XH5fGoGj.js → data-grid-Kj1b9RD-.js} +1316 -1272
  44. package/dist/data-grid.js +1 -1
  45. package/dist/data-list-BgdkA3bD.js +587 -0
  46. package/dist/data-list.js +1 -1
  47. package/dist/{date-field-BrNyJBiJ.js → date-field-B2lQzE3p.js} +5 -5
  48. package/dist/date-field.js +1 -1
  49. package/dist/{date-picker-Nl55so0C.js → date-picker-DpTRb-Y1.js} +16 -16
  50. package/dist/date-picker.js +1 -1
  51. package/dist/{date-range-picker-DLkvfUJD.js → date-range-picker-CBUPJep5.js} +17 -17
  52. package/dist/date-range-picker.js +1 -1
  53. package/dist/{datetime-field-CZRhRDPb.js → datetime-field-BZ44uJ_B.js} +7 -7
  54. package/dist/datetime-field.js +1 -1
  55. package/dist/{datetime-picker-_GHra2WL.js → datetime-picker-BK_bV3Yr.js} +21 -21
  56. package/dist/datetime-picker.js +1 -1
  57. package/dist/{datetime-range-picker-Dy1A0Wqy.js → datetime-range-picker-ChdbRgzQ.js} +21 -21
  58. package/dist/datetime-range-picker.js +1 -1
  59. package/dist/{description-list-Cc4JYZ-3.js → description-list-CYlfHDwx.js} +11 -11
  60. package/dist/description-list.js +1 -1
  61. package/dist/{detail-panel-BI_wHSoz.js → detail-panel-DimjnPI8.js} +91 -91
  62. package/dist/detail-panel.js +1 -1
  63. package/dist/{dialog-B6MP7GYI.js → dialog-BB5MdJex.js} +108 -108
  64. package/dist/dialog.js +1 -1
  65. package/dist/docs/action-bar.json +4 -4
  66. package/dist/docs/action-bar.md +3 -3
  67. package/dist/docs/calendar.md +2 -2
  68. package/dist/docs/command-palette.json +1 -0
  69. package/dist/docs/command-palette.md +1 -1
  70. package/dist/docs/data-grid.examples.md +8 -2
  71. package/dist/docs/data-grid.json +12 -2
  72. package/dist/docs/data-grid.md +3 -1
  73. package/dist/docs/detail-panel.json +4 -2
  74. package/dist/docs/detail-panel.md +15 -5
  75. package/dist/docs/dialog.json +1 -0
  76. package/dist/docs/dialog.md +1 -1
  77. package/dist/docs/drawer.json +6 -4
  78. package/dist/docs/drawer.md +3 -3
  79. package/dist/docs/event-calendar.md +2 -2
  80. package/dist/docs/guidelines/index.md +4 -3
  81. package/dist/docs/guidelines/layout-alignment.md +17 -7
  82. package/dist/docs/guidelines/list-pages.md +3 -3
  83. package/dist/docs/page-header.json +18 -2
  84. package/dist/docs/page-header.md +5 -3
  85. package/dist/docs/page.json +1 -0
  86. package/dist/docs/page.md +1 -1
  87. package/dist/docs/rating.md +1 -1
  88. package/dist/docs/section.json +1 -1
  89. package/dist/docs/section.md +1 -1
  90. package/dist/docs/skills/compose-screen/SKILL.md +12 -4
  91. package/dist/docs/skills/review-screen/SKILL.md +20 -18
  92. package/dist/docs/skills/theme-app/SKILL.md +12 -1
  93. package/dist/docs/toast.json +1 -0
  94. package/dist/docs/toast.md +1 -1
  95. package/dist/docs/tokens.md +1 -1
  96. package/dist/docs/toolbar.json +1 -1
  97. package/dist/docs/toolbar.md +1 -1
  98. package/dist/docs/typography.md +1 -1
  99. package/dist/{drawer-CkpFlKYa.js → drawer-fyPyxnYQ.js} +216 -206
  100. package/dist/drawer.js +1 -1
  101. package/dist/entity-picker-ClyhBTyK.js +1283 -0
  102. package/dist/entity-picker.js +1 -1
  103. package/dist/{event-calendar-BDjI5T44.js → event-calendar-COgC24UG.js} +23 -23
  104. package/dist/event-calendar.js +1 -1
  105. package/dist/{field-group-CCM2vPKL.js → field-group-Bj-EbPIU.js} +2 -2
  106. package/dist/field-group.js +1 -1
  107. package/dist/{field-CzSGs7wo.js → field-tnEZiRLg.js} +19 -19
  108. package/dist/field.js +1 -1
  109. package/dist/filter-bar-BRuCz79-.js +1342 -0
  110. package/dist/filter-bar.js +1 -1
  111. package/dist/{form-CDq04WDY.js → form-DEcJ7tHf.js} +1 -1
  112. package/dist/form.js +1 -1
  113. package/dist/{fullscreen-6GW4naDP.js → fullscreen-BwweNj3-.js} +13 -13
  114. package/dist/fullscreen.js +1 -1
  115. package/dist/{hover-card-aadyPXzF.js → hover-card-BWcU37Yp.js} +1 -1
  116. package/dist/hover-card.js +1 -1
  117. package/dist/{i18n-DpW8lqJ1.js → i18n-D7xXDd8-.js} +11 -4
  118. package/dist/i18n.js +1 -1
  119. package/dist/{icon-button-CRB218_z.js → icon-button-DbSZKGT4.js} +73 -71
  120. package/dist/{import-export-center-DUrNwRKP.js → import-export-center-CYf0Qxl_.js} +291 -289
  121. package/dist/import-export-center.js +1 -1
  122. package/dist/index.js +100 -100
  123. package/dist/{kbd-Z4YmSPRy.js → kbd-dNz8QHfL.js} +1 -1
  124. package/dist/kbd.js +1 -1
  125. package/dist/{link-BsSlZ1ts.js → link-DLPyg54C.js} +5 -5
  126. package/dist/link.js +1 -1
  127. package/dist/{listbox-VFcfZT70.js → listbox-BSqx_ARf.js} +1 -1
  128. package/dist/listbox.js +1 -1
  129. package/dist/{loading-overlay-BZPBDK4w.js → loading-overlay-BLIrcaoj.js} +9 -9
  130. package/dist/loading-overlay.js +1 -1
  131. package/dist/{markdown-BmCU_sOv.js → markdown-DccRb1xf.js} +17 -17
  132. package/dist/markdown.js +1 -1
  133. package/dist/{menu-parts-DS9JEUCt.js → menu-parts-CNNHRduK.js} +42 -42
  134. package/dist/menu.js +1 -1
  135. package/dist/{menubar-BV43BKep.js → menubar-Bdr6zigi.js} +1 -1
  136. package/dist/menubar.js +1 -1
  137. package/dist/message-BkTiWsUp.js +436 -0
  138. package/dist/message-scroller-akQEtQLn.js +218 -0
  139. package/dist/message-scroller.js +1 -1
  140. package/dist/message.js +1 -1
  141. package/dist/{multi-select-YaxhhH9y.js → multi-select-BvlJIEtz.js} +445 -443
  142. package/dist/multi-select.js +1 -1
  143. package/dist/{navigation-menu-parts-B64gKl8B.js → navigation-menu-parts-CEW4fgCo.js} +12 -12
  144. package/dist/navigation-menu.js +1 -1
  145. package/dist/{notification-center-Ci-OLWTO.js → notification-center-BQO0Ey3h.js} +40 -40
  146. package/dist/notification-center.js +1 -1
  147. package/dist/{number-field-BYQmPyM-.js → number-field-D1MqT8_A.js} +13 -13
  148. package/dist/number-field.js +1 -1
  149. package/dist/{otp-input-BKO0WPZc.js → otp-input-Cub9H9Di.js} +1 -1
  150. package/dist/otp-input.js +1 -1
  151. package/dist/{page-CfjGviUA.js → page-CwYmBoZQ.js} +1 -1
  152. package/dist/{page-header-w_PFLnLG.js → page-header-CMxCQqu_.js} +117 -114
  153. package/dist/page-header.js +1 -1
  154. package/dist/page.js +1 -1
  155. package/dist/{pagination-Cm9665gb.js → pagination-IEuos7H1.js} +12 -12
  156. package/dist/pagination.js +1 -1
  157. package/dist/{popover-D1krYeP-.js → popover-C7NpEzq6.js} +22 -22
  158. package/dist/popover.js +1 -1
  159. package/dist/prompt-composer-Cu8bj1Vb.js +276 -0
  160. package/dist/prompt-composer.js +1 -1
  161. package/dist/{prose-Bl5OjXTb.js → prose-CQN4Bqqh.js} +1 -1
  162. package/dist/prose.js +1 -1
  163. package/dist/{radio-group-D9VTBLUB.js → radio-group-BHlDgCLk.js} +2 -2
  164. package/dist/radio-group.js +1 -1
  165. package/dist/{rating-BRqsV5OF.js → rating-Cr0lXaAV.js} +15 -15
  166. package/dist/rating.js +1 -1
  167. package/dist/{saved-views-C_76obIv.js → saved-views-CyLSn8a2.js} +151 -151
  168. package/dist/saved-views.js +1 -1
  169. package/dist/{scroll-area-vrm2bbtZ.js → scroll-area-Fr0PmnRS.js} +1 -1
  170. package/dist/scroll-area.js +1 -1
  171. package/dist/{segmented-control-5DTOKO3g.js → segmented-control-uPnQYklX.js} +2 -2
  172. package/dist/segmented-control.js +1 -1
  173. package/dist/select-C0JYHwBy.js +1020 -0
  174. package/dist/select.js +1 -1
  175. package/dist/{side-navigation-MNMSkj9b.js → side-navigation-D8lRpHwj.js} +64 -64
  176. package/dist/side-navigation.js +1 -1
  177. package/dist/{skeleton-DyOwgYmF.js → skeleton-DeEOmm1y.js} +1 -1
  178. package/dist/skeleton.js +1 -1
  179. package/dist/{slider-OMe1DAC-.js → slider-BSI1xvjw.js} +2 -2
  180. package/dist/slider.js +1 -1
  181. package/dist/{sparkline-ChkaLVdY.js → sparkline-CYU4_lCD.js} +1 -1
  182. package/dist/sparkline.js +1 -1
  183. package/dist/spinner-ring-DyfaYloA.js +19 -0
  184. package/dist/{split-button-DbmRwfMC.js → split-button-CkbylOMN.js} +2 -2
  185. package/dist/split-button.js +1 -1
  186. package/dist/{stat-card-BSnsTmsq.js → stat-card-CAh4SdeY.js} +16 -16
  187. package/dist/stat-card.js +1 -1
  188. package/dist/{status-indicator-CyKhBdvN.js → status-indicator-BVMnpcm8.js} +4 -4
  189. package/dist/status-indicator.js +1 -1
  190. package/dist/{stepper-Cw1Auv3n.js → stepper-BLfvMz04.js} +16 -16
  191. package/dist/stepper.js +1 -1
  192. package/dist/styles/action-bar.css +1 -1
  193. package/dist/styles/action-sheet.css +2 -2
  194. package/dist/styles/button.css +2 -2
  195. package/dist/styles/cascader.css +2 -2
  196. package/dist/styles/chart.css +1 -1
  197. package/dist/styles/column-manager.css +3 -3
  198. package/dist/styles/command-palette.css +3 -3
  199. package/dist/styles/dashboard-grid.css +2 -2
  200. package/dist/styles/data-grid.css +3 -3
  201. package/dist/styles/data-list.css +2 -2
  202. package/dist/styles/detail-panel.css +4 -4
  203. package/dist/styles/dialog.css +1 -1
  204. package/dist/styles/drawer.css +1 -1
  205. package/dist/styles/entity-picker.css +1 -1
  206. package/dist/styles/event-calendar.css +1 -1
  207. package/dist/styles/filter-bar.css +3 -3
  208. package/dist/styles/import-export-center.css +4 -4
  209. package/dist/styles/index.css +12 -12
  210. package/dist/styles/markdown.css +2 -2
  211. package/dist/styles/multi-select.css +1 -1
  212. package/dist/styles/notification-center.css +3 -3
  213. package/dist/styles/page-header.css +2 -2
  214. package/dist/styles/page.css +1 -1
  215. package/dist/styles/prompt-composer.css +1 -1
  216. package/dist/styles/saved-views.css +2 -2
  217. package/dist/styles/split-button.css +2 -2
  218. package/dist/styles/table.css +2 -2
  219. package/dist/styles/tabs.css +1 -1
  220. package/dist/styles/timeline.css +1 -1
  221. package/dist/styles/toast.css +1 -1
  222. package/dist/styles/tour.css +2 -2
  223. package/dist/styles/transfer.css +2 -2
  224. package/dist/styles/upload.css +1 -1
  225. package/dist/styles/wizard.css +2 -2
  226. package/dist/styles.css +1 -1
  227. package/dist/{switch-CQ1rpuKa.js → switch-BHyKHqeI.js} +5 -5
  228. package/dist/switch.js +1 -1
  229. package/dist/{table-DpGTPtnb.js → table-C8zOHDcY.js} +30 -30
  230. package/dist/{table-of-contents-BFVERMZy.js → table-of-contents-BAIuPCdy.js} +8 -8
  231. package/dist/table-of-contents.js +1 -1
  232. package/dist/table.js +1 -1
  233. package/dist/{tag-aX7uyAN0.js → tag-XYGEPUHR.js} +14 -14
  234. package/dist/tag.js +1 -1
  235. package/dist/{tags-input-BgpS22sf.js → tags-input-ClYSd-No.js} +40 -40
  236. package/dist/tags-input.js +1 -1
  237. package/dist/text-field-Cguj75tn.js +205 -0
  238. package/dist/text-field.js +1 -1
  239. package/dist/{textarea-DNCjsQYd.js → textarea-BKsh_jAo.js} +1 -1
  240. package/dist/textarea.js +1 -1
  241. package/dist/{time-field-Cm6iBjwH.js → time-field-BIE4WMpS.js} +7 -7
  242. package/dist/time-field.js +1 -1
  243. package/dist/{time-picker-Ce18FSO2.js → time-picker-CNfafRDF.js} +18 -18
  244. package/dist/time-picker.js +1 -1
  245. package/dist/{time-range-picker-kDnw4PQ3.js → time-range-picker-D7gM_Wno.js} +20 -20
  246. package/dist/time-range-picker.js +1 -1
  247. package/dist/timeline-BLadNUkS.js +449 -0
  248. package/dist/timeline.js +1 -1
  249. package/dist/{toast-58ex8PDK.js → toast-CjbiXiza.js} +16 -16
  250. package/dist/toast.js +1 -1
  251. package/dist/{toggle-group-YxVJlCnI.js → toggle-group-BZmghKac.js} +1 -1
  252. package/dist/toggle-group.js +1 -1
  253. package/dist/toolbar-BI4ZepBs.js +243 -0
  254. package/dist/toolbar.js +1 -1
  255. package/dist/{top-navigation-DorkYBnR.js → top-navigation-BTZpx5VA.js} +13 -13
  256. package/dist/top-navigation.js +1 -1
  257. package/dist/{tour-CwK_m_Jp.js → tour-_CQ1kYov.js} +23 -23
  258. package/dist/tour.js +1 -1
  259. package/dist/{transfer-DxGDWIEt.js → transfer-BVhBdIGp.js} +59 -59
  260. package/dist/transfer.js +1 -1
  261. package/dist/tree-DfI9UWLA.js +794 -0
  262. package/dist/tree.js +1 -1
  263. package/dist/types/action-bar/action-bar-overflow.d.ts.map +1 -1
  264. package/dist/types/action-bar/action-bar.types.d.ts +2 -2
  265. package/dist/types/action-sheet/action-sheet-parts.d.ts.map +1 -1
  266. package/dist/types/app-shell/app-shell-parts.d.ts.map +1 -1
  267. package/dist/types/app-shell/app-shell.d.ts.map +1 -1
  268. package/dist/types/app-shell/app-shell.types.d.ts +21 -14
  269. package/dist/types/app-shell/app-shell.types.d.ts.map +1 -1
  270. package/dist/types/app-shell/index.d.ts +1 -1
  271. package/dist/types/app-shell/index.d.ts.map +1 -1
  272. package/dist/types/button/button-indicator.d.ts.map +1 -1
  273. package/dist/types/button/spinner-ring.d.ts +8 -0
  274. package/dist/types/button/spinner-ring.d.ts.map +1 -0
  275. package/dist/types/cascader/cascader-surface.d.ts.map +1 -1
  276. package/dist/types/cascader/cascader.d.ts.map +1 -1
  277. package/dist/types/combobox/combobox-parts.d.ts.map +1 -1
  278. package/dist/types/command-palette/command-palette.d.ts.map +1 -1
  279. package/dist/types/data-grid/data-grid-body.d.ts +7 -2
  280. package/dist/types/data-grid/data-grid-body.d.ts.map +1 -1
  281. package/dist/types/data-grid/data-grid-header.d.ts.map +1 -1
  282. package/dist/types/data-grid/data-grid.d.ts +1 -1
  283. package/dist/types/data-grid/data-grid.d.ts.map +1 -1
  284. package/dist/types/detail-panel/detail-panel-parts.d.ts +2 -1
  285. package/dist/types/detail-panel/detail-panel-parts.d.ts.map +1 -1
  286. package/dist/types/drawer/drawer-parts.d.ts.map +1 -1
  287. package/dist/types/entity-picker/entity-picker-control.d.ts.map +1 -1
  288. package/dist/types/filter-bar/filter-bar.d.ts.map +1 -1
  289. package/dist/types/i18n/slotted-provider.d.ts +6 -0
  290. package/dist/types/i18n/slotted-provider.d.ts.map +1 -1
  291. package/dist/types/import-export-center/import-export-center.d.ts.map +1 -1
  292. package/dist/types/message/message-parts.d.ts.map +1 -1
  293. package/dist/types/message-scroller/message-scroller.d.ts.map +1 -1
  294. package/dist/types/multi-select/multi-select-parts.d.ts.map +1 -1
  295. package/dist/types/page-header/page-header-defaults.d.ts +1 -1
  296. package/dist/types/page-header/page-header-defaults.d.ts.map +1 -1
  297. package/dist/types/page-header/page-header.d.ts +1 -1
  298. package/dist/types/page-header/page-header.d.ts.map +1 -1
  299. package/dist/types/page-header/page-header.types.d.ts +9 -0
  300. package/dist/types/page-header/page-header.types.d.ts.map +1 -1
  301. package/dist/types/prompt-composer/prompt-composer.d.ts.map +1 -1
  302. package/dist/types/select/select-parts.d.ts.map +1 -1
  303. package/dist/types/text-field/text-field.d.ts.map +1 -1
  304. package/dist/types/timeline/timeline-parts.d.ts.map +1 -1
  305. package/dist/types/timeline/timeline.d.ts.map +1 -1
  306. package/dist/types/toolbar/toolbar-overflow.d.ts.map +1 -1
  307. package/dist/types/toolbar/toolbar.types.d.ts +2 -2
  308. package/dist/types/tree/tree-parts.d.ts.map +1 -1
  309. package/dist/{upload-CEDsfMWz.js → upload-N2-nyO8x.js} +65 -65
  310. package/dist/upload.js +1 -1
  311. package/dist/{wizard-B3p7zCSj.js → wizard-CK1x2fs3.js} +16 -16
  312. package/dist/wizard.js +1 -1
  313. package/package.json +6 -6
  314. package/dist/action-bar-CJgBierN.js +0 -283
  315. package/dist/action-sheet-tRrjm7WQ.js +0 -358
  316. package/dist/cascader-DqlC1z5b.js +0 -1154
  317. package/dist/combobox-YWFkxaQ3.js +0 -902
  318. package/dist/command-palette-DXNq-zKN.js +0 -741
  319. package/dist/data-list-DZCN_uW1.js +0 -587
  320. package/dist/entity-picker-CFwLGQeU.js +0 -1281
  321. package/dist/filter-bar-G50WdRac.js +0 -1340
  322. package/dist/message-Dtck9RJy.js +0 -434
  323. package/dist/message-scroller-niUJ8RoL.js +0 -216
  324. package/dist/prompt-composer-sh_TXKYZ.js +0 -273
  325. package/dist/select-BFx5EgAa.js +0 -1018
  326. package/dist/text-field-DL_uhNXV.js +0 -203
  327. package/dist/timeline-pEL30Jp8.js +0 -446
  328. package/dist/toolbar-BtIyVbs4.js +0 -241
  329. package/dist/tree-DbLRyItM.js +0 -792
@@ -1,27 +1,27 @@
1
- import { n as e, t } from "./icon-DjqSEQ-o.js";
2
- import { _ as n, c as r, g as i, n as a, t as o } from "./menu-parts-DS9JEUCt.js";
3
- import { n as s, r as c } from "./i18n-DpW8lqJ1.js";
4
- import { n as l } from "./icon-button-CRB218_z.js";
1
+ import { n as e, r as t } from "./i18n-D7xXDd8-.js";
2
+ import { n, t as r } from "./icon-DjqSEQ-o.js";
3
+ import { _ as i, c as a, g as o, n as s, t as c } from "./menu-parts-CNNHRduK.js";
4
+ import { n as l } from "./icon-button-DbSZKGT4.js";
5
5
  import { a as u, i as d, n as f, r as p } from "./tooltip-DrFiRlH8.js";
6
- import { t as m } from "./checkbox-CMY2KIih.js";
7
- import { i as h } from "./skeleton-DyOwgYmF.js";
8
- import { t as g } from "./text-field-DL_uhNXV.js";
9
- import { a as _, d as ee, f as te, l as ne, r as re, t as ie } from "./popover-D1krYeP-.js";
6
+ import { t as m } from "./checkbox-C_8GVtjD.js";
7
+ import { i as h } from "./skeleton-DeEOmm1y.js";
8
+ import { t as g } from "./text-field-Cguj75tn.js";
9
+ import { a as _, d as ee, f as te, l as ne, r as re, t as ie } from "./popover-C7NpEzq6.js";
10
10
  import { t as v } from "./visually-hidden-BUSrFZ1_.js";
11
11
  import { i as ae, n as oe, o as se, r as ce, t as le } from "./result-state-BMYhelu1.js";
12
- import { t as ue } from "./date-picker-Nl55so0C.js";
13
- import { t as de } from "./date-field-BrNyJBiJ.js";
14
- import { t as fe } from "./date-range-picker-DLkvfUJD.js";
15
- import { t as pe } from "./datetime-picker-_GHra2WL.js";
16
- import { t as me } from "./datetime-field-CZRhRDPb.js";
17
- import { t as he } from "./datetime-range-picker-Dy1A0Wqy.js";
18
- import { a as ge, i as _e, n as ve, s as ye } from "./multi-select-YaxhhH9y.js";
19
- import { t as be } from "./number-field-BYQmPyM-.js";
20
- import { a as xe, t as Se } from "./segmented-control-5DTOKO3g.js";
21
- import { c as Ce, i as we, n as Te, o as Ee, s as De } from "./select-BFx5EgAa.js";
22
- import { t as Oe } from "./time-picker-Ce18FSO2.js";
23
- import { t as ke } from "./time-field-Cm6iBjwH.js";
24
- import { t as Ae } from "./time-range-picker-kDnw4PQ3.js";
12
+ import { t as ue } from "./date-picker-DpTRb-Y1.js";
13
+ import { t as de } from "./date-field-B2lQzE3p.js";
14
+ import { t as fe } from "./date-range-picker-CBUPJep5.js";
15
+ import { t as pe } from "./datetime-picker-BK_bV3Yr.js";
16
+ import { t as me } from "./datetime-field-BZ44uJ_B.js";
17
+ import { t as he } from "./datetime-range-picker-ChdbRgzQ.js";
18
+ import { a as ge, i as _e, n as ve, s as ye } from "./multi-select-BvlJIEtz.js";
19
+ import { t as be } from "./number-field-D1MqT8_A.js";
20
+ import { a as xe, t as Se } from "./segmented-control-uPnQYklX.js";
21
+ import { c as Ce, i as we, n as Te, o as Ee, s as De } from "./select-C0JYHwBy.js";
22
+ import { t as Oe } from "./time-picker-CNfafRDF.js";
23
+ import { t as ke } from "./time-field-BIE4WMpS.js";
24
+ import { t as Ae } from "./time-range-picker-D7gM_Wno.js";
25
25
  import { selectorKeyProps as je, withSelectorKey as Me } from "@slotted/core/selector-key";
26
26
  import { createControllable as Ne } from "@slotted/core/state";
27
27
  import { createContext as Pe, createElement as Fe, memo as Ie, useCallback as y, useContext as Le, useEffect as b, useId as Re, useImperativeHandle as ze, useLayoutEffect as Be, useMemo as x, useRef as S, useState as C, useSyncExternalStore as Ve } from "react";
@@ -34,15 +34,15 @@ import { isPlainDate as Je, isPlainDateTime as Ye, isPlainTime as Xe, parseISODa
34
34
  import { createRowMetrics as rt, nextSelection as it, virtualWindow as at } from "@slotted/core/collection";
35
35
  import { writeToClipboard as ot } from "@slotted/core/clipboard";
36
36
  import { createDragController as st } from "@slotted/core/drag";
37
- import { FILTER_ROW as ct, GROUP_ROW_PREFIX as lt, HEADER_ROW as ut, POPIN_COLUMN_ID as dt, RESIZE_STEP as ft, SUMMARY_ROW as pt, applyQuery as mt, cellText as ht, cellValue as gt, columnRange as _t, columnTemplate as vt, columnsOutOfSpace as yt, emptyGridView as bt, emptyQuery as xt, groupInOrder as St, isGroupCursorRow as Ct, moveCursor as wt, normalizeColumnState as Tt, parseGridView as Et, rangeBounds as Dt, rangeCells as Ot, rangeEdges as kt, rangeToText as At, resolveColumnOverflow as jt, resolveColumns as Mt, rowRange as Nt, sameCell as E, serializeGridView as Pt, serializeQuery as Ft, settleCursor as It, toCsv as Lt, wholeRange as Rt, withColumnFilter as zt, withColumnHidden as Bt, withColumnMoved as Vt, withColumnPinned as Ht, withColumnWidth as Ut, withSort as Wt, withSortPress as Gt, withoutFilters as Kt, zoneOf as qt } from "@slotted/core/grid";
38
- import { createFilterGroupPredicate as Jt, defaultOperator as Yt, describeFilter as Xt, emptyFilter as Zt, isConditionActive as Qt, isFilterActive as $t, normalizeFilter as en, operandCount as tn, operatorsFor as nn, ruleFor as rn, serializeFilter as an, withCondition as on, withJoin as sn, withoutRuleFor as cn } from "@slotted/core/filter";
37
+ import { FILTER_ROW as ct, GROUP_ROW_PREFIX as lt, HEADER_ROW as ut, POPIN_COLUMN_ID as dt, RESIZE_STEP as ft, SUMMARY_ROW as pt, applyQuery as mt, cellText as ht, cellValue as gt, clampWidth as _t, columnRange as vt, columnTemplate as yt, columnsOutOfSpace as bt, emptyGridView as xt, emptyQuery as St, groupInOrder as Ct, isGroupCursorRow as wt, moveCursor as Tt, normalizeColumnState as Et, parseGridView as Dt, rangeBounds as Ot, rangeCells as kt, rangeEdges as At, rangeToText as jt, resolveColumnOverflow as Mt, resolveColumns as Nt, rowRange as Pt, sameCell as E, serializeGridView as Ft, serializeQuery as It, settleCursor as Lt, toCsv as Rt, wholeRange as zt, withColumnFilter as Bt, withColumnHidden as Vt, withColumnMoved as Ht, withColumnPinned as Ut, withColumnWidth as Wt, withSort as Gt, withSortPress as Kt, withoutFilters as qt, zoneOf as Jt } from "@slotted/core/grid";
38
+ import { createFilterGroupPredicate as Yt, defaultOperator as Xt, describeFilter as Zt, emptyFilter as Qt, isConditionActive as $t, isFilterActive as en, normalizeFilter as tn, operandCount as nn, operatorsFor as rn, ruleFor as an, serializeFilter as on, withCondition as sn, withJoin as cn, withoutRuleFor as ln } from "@slotted/core/filter";
39
39
  //#region src/data-grid/data-grid-constants.ts
40
- var ln = "__selection", un = "__expander", dn = "__drag", fn = "a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex=\"-1\"]), [contenteditable=\"true\"]";
41
- function pn(e, t) {
40
+ var un = "__selection", dn = "__expander", fn = "__drag", pn = "a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex=\"-1\"]), [contenteditable=\"true\"]";
41
+ function mn(e, t) {
42
42
  let n = { "--slotted-data-grid-column": String(t) };
43
43
  return e.pinned && (n["--slotted-data-grid-pin-offset"] = `${e.pinOffset}px`), n;
44
44
  }
45
- function mn(e) {
45
+ function hn(e) {
46
46
  return {
47
47
  ...e.align ? { "data-align": e.align } : {},
48
48
  ...e.numeric ? { "data-numeric": "" } : {},
@@ -51,19 +51,19 @@ function mn(e) {
51
51
  "data-column": e.id
52
52
  };
53
53
  }
54
- function hn(e) {
54
+ function gn(e) {
55
55
  let t = e.currentTarget, n = e.target;
56
56
  if (!n || !t.contains(n)) return !0;
57
- let r = n.closest(fn);
57
+ let r = n.closest(pn);
58
58
  return r !== null && r !== t && t.contains(r);
59
59
  }
60
- var gn = 1200, _n = Pe(void 0);
60
+ var _n = 1200, vn = Pe(void 0);
61
61
  function D() {
62
- let e = Le(_n);
62
+ let e = Le(vn);
63
63
  if (e === void 0) throw Error("Every DataGrid part must be rendered inside DataGrid.");
64
64
  return e;
65
65
  }
66
- var vn = /* @__PURE__ */ new Set([
66
+ var yn = /* @__PURE__ */ new Set([
67
67
  "changedOf",
68
68
  "current",
69
69
  "detailId",
@@ -77,8 +77,8 @@ var vn = /* @__PURE__ */ new Set([
77
77
  "rangeBounds",
78
78
  "rangeInfo",
79
79
  "rowLabelOf"
80
- ]), yn = /* @__PURE__ */ new Set(/* @__PURE__ */ "activate.allState.announce.anchorToButton.attachDraggable.attachRowDraggable.autofit.beginRange.cancelEdit.commitEdit.extendRange.focused.hide.moveColumn.onCellBlur.onCellClick.onCellDoubleClick.onCellFocus.onCellKeyDown.onCellPointerDown.onCellPointerEnter.onHeaderContextMenu.onManageColumns.pin.pressSort.rangeDragging.rangeSummary.resizeBy.resizeTo.selectableCount.selectedCount.setCurrent.setDraft.setFilter.setFilterOpen.setMenuOpen.setResizing.setSort.startEdit.tabStop.toggleAll.toggleBranch.toggleExpanded.toggleGroup.toggleSelected".split("."));
81
- function bn(e) {
80
+ ]), bn = /* @__PURE__ */ new Set(/* @__PURE__ */ "activate.allState.announce.anchorToButton.attachDraggable.attachRowDraggable.autofit.beginRange.cancelEdit.commitEdit.extendRange.focused.hide.moveColumn.onCellBlur.onCellClick.onCellDoubleClick.onCellFocus.onCellKeyDown.onCellPointerDown.onCellPointerEnter.onHeaderContextMenu.onManageColumns.pin.pressSort.rangeDragging.rangeSummary.resizeBy.resizeTo.selectableCount.selectedCount.setCurrent.setDraft.setFilter.setFilterOpen.setMenuOpen.setResizing.setSort.startEdit.tabStop.toggleAll.toggleBranch.toggleExpanded.toggleGroup.toggleSelected".split("."));
81
+ function xn(e) {
82
82
  let t = e, n = 0, r = /* @__PURE__ */ new Set();
83
83
  return {
84
84
  grid: new Proxy({}, {
@@ -89,7 +89,7 @@ function bn(e) {
89
89
  set: (e) => {
90
90
  if (e === t) return;
91
91
  let r = t, i = e;
92
- for (let e of Object.keys(i)) if (!(vn.has(e) || yn.has(e)) && r[e] !== i[e]) {
92
+ for (let e of Object.keys(i)) if (!(yn.has(e) || bn.has(e)) && r[e] !== i[e]) {
93
93
  n += 1;
94
94
  break;
95
95
  }
@@ -116,7 +116,7 @@ function bn(e) {
116
116
  +!!t.hasPopinCell(e),
117
117
  +(t.draggingRow === e),
118
118
  r !== null && r.row === e ? r.column : "",
119
- i !== null && i.cell.row === e ? O(i) : "",
119
+ i !== null && i.cell.row === e ? wn(i) : "",
120
120
  t.detailId(e),
121
121
  t.rowLabelOf(e),
122
122
  a
@@ -124,48 +124,57 @@ function bn(e) {
124
124
  }
125
125
  };
126
126
  }
127
- var xn = /* @__PURE__ */ new WeakMap(), Sn = 0;
128
- function O(e) {
129
- let t = xn.get(e);
130
- return t === void 0 && (Sn += 1, t = Sn, xn.set(e, t)), t;
131
- }
132
- var Cn = Pe(void 0);
127
+ var Sn = /* @__PURE__ */ new WeakMap(), Cn = 0;
133
128
  function wn(e) {
134
- let t = Le(Cn);
129
+ let t = Sn.get(e);
130
+ return t === void 0 && (Cn += 1, t = Cn, Sn.set(e, t)), t;
131
+ }
132
+ var Tn = Pe(void 0);
133
+ function En(e) {
134
+ let t = Le(Tn);
135
135
  if (t === void 0) throw Error("Every DataGrid part must be rendered inside DataGrid.");
136
136
  let n = () => t.signature(e);
137
137
  return Ve(t.subscribe, n, n), t;
138
138
  }
139
139
  //#endregion
140
140
  //#region src/data-grid/data-grid-body.tsx
141
- function Tn({ allNodes: e, bodyStyle: t, firstIndex: n, headerRowCount: r, measureRow: i, nodes: a, heldRows: o }) {
142
- let s = o.map((t) => e.find((e) => e.key === t)).filter((e) => e !== void 0 && !a.includes(e));
143
- return /* @__PURE__ */ w("div", {
141
+ function Dn({ allNodes: e, bodyStyle: t, firstIndex: n, headerRowCount: r, measureRow: i, nodes: a, heldRows: o, loadMore: s }) {
142
+ let c = o.map((t) => e.find((e) => e.key === t)).filter((e) => e !== void 0 && !a.includes(e));
143
+ return /* @__PURE__ */ T("div", {
144
144
  "data-part": "body",
145
145
  "data-part-body": "",
146
146
  role: "rowgroup",
147
147
  style: t,
148
- children: [...a, ...s].map((e, t) => {
148
+ children: [[...a, ...c].map((e, t) => {
149
149
  let a = n + t, o = r + 1 + (e.kind === "row" ? e.index : a);
150
- return e.kind === "group" ? /* @__PURE__ */ w(j, {
150
+ return e.kind === "group" ? /* @__PURE__ */ w(Fn, {
151
151
  node: e,
152
152
  rowIndex: o
153
- }, `group:${e.key}`) : /* @__PURE__ */ w(kn, {
153
+ }, `group:${e.key}`) : /* @__PURE__ */ w(jn, {
154
154
  index: a,
155
155
  measure: i,
156
156
  node: e,
157
157
  rowIndex: o
158
158
  }, e.key);
159
- })
159
+ }), s ? /* @__PURE__ */ w("div", {
160
+ "aria-hidden": "true",
161
+ ref: s.ref,
162
+ style: {
163
+ bottom: 0,
164
+ inlineSize: 1,
165
+ position: "absolute",
166
+ top: s.top
167
+ }
168
+ }) : null]
160
169
  });
161
170
  }
162
- function En({ edge: e, firstRowIndex: t, nodes: n }) {
171
+ function On({ edge: e, firstRowIndex: t, nodes: n }) {
163
172
  return /* @__PURE__ */ w("div", {
164
173
  "data-edge": e,
165
174
  "data-part": "pinned-rows",
166
175
  "data-part-pinned-rows": "",
167
176
  role: "rowgroup",
168
- children: n.map((e, n) => /* @__PURE__ */ w(kn, {
177
+ children: n.map((e, n) => /* @__PURE__ */ w(jn, {
169
178
  index: -1,
170
179
  measure: void 0,
171
180
  node: e,
@@ -173,15 +182,15 @@ function En({ edge: e, firstRowIndex: t, nodes: n }) {
173
182
  }, e.key))
174
183
  });
175
184
  }
176
- function Dn({ children: e }) {
185
+ function kn({ children: e }) {
177
186
  return /* @__PURE__ */ w("div", {
178
187
  "data-part": "empty",
179
188
  "data-part-empty": "",
180
189
  children: e
181
190
  });
182
191
  }
183
- function On({ index: e, measure: t, node: n, rowIndex: r }) {
184
- let i = n.key, a = wn(i), o = a.latest(), s = o.isSelected(i), c = o.isDisabled(i), l = o.current !== null && o.current.row === i, u = o.isExpanded(i) && (o.treeColumn === null || n.childCount === 0), d = o.isLoadingChildren(i), f = o.edit !== null && o.edit.cell.row === i, p = y((n) => {
192
+ function An({ index: e, measure: t, node: n, rowIndex: r }) {
193
+ let i = n.key, a = En(i), o = a.latest(), s = o.isSelected(i), c = o.isDisabled(i), l = o.current !== null && o.current.row === i, u = o.isExpanded(i) && (o.treeColumn === null || n.childCount === 0), d = o.isLoadingChildren(i), f = o.edit !== null && o.edit.cell.row === i, p = y((n) => {
185
194
  t?.(e, n), a.grid.attachRowDraggable(n, i);
186
195
  }, [
187
196
  t,
@@ -207,14 +216,14 @@ function On({ index: e, measure: t, node: n, rowIndex: r }) {
207
216
  ...c ? { "data-disabled": "" } : {},
208
217
  ...f ? { "data-editing": "" } : {},
209
218
  children: [
210
- o.columnIds.includes("__selection") ? /* @__PURE__ */ w(An, { rowKey: i }) : null,
211
- o.columnIds.includes("__drag") ? /* @__PURE__ */ w(k, { node: n }) : null,
212
- o.columnIds.includes("__expander") ? /* @__PURE__ */ w(jn, { node: n }) : null,
213
- o.mountedColumns.map((e) => /* @__PURE__ */ w(A, {
219
+ o.columnIds.includes("__selection") ? /* @__PURE__ */ w(O, { rowKey: i }) : null,
220
+ o.columnIds.includes("__drag") ? /* @__PURE__ */ w(Mn, { node: n }) : null,
221
+ o.columnIds.includes("__expander") ? /* @__PURE__ */ w(k, { node: n }) : null,
222
+ o.mountedColumns.map((e) => /* @__PURE__ */ w(Nn, {
214
223
  column: e,
215
224
  node: n
216
225
  }, e.id)),
217
- o.popinColumns.length > 0 ? /* @__PURE__ */ w(Mn, { node: n }) : null
226
+ o.popinColumns.length > 0 ? /* @__PURE__ */ w(Pn, { node: n }) : null
218
227
  ]
219
228
  }), u && o.renderDetail ? /* @__PURE__ */ w("div", {
220
229
  "aria-rowindex": r + 1,
@@ -233,15 +242,15 @@ function On({ index: e, measure: t, node: n, rowIndex: r }) {
233
242
  })
234
243
  }) : null] });
235
244
  }
236
- var kn = Ie(On);
237
- function An({ rowKey: e }) {
245
+ var jn = Ie(An);
246
+ function O({ rowKey: e }) {
238
247
  let t = D(), n = {
239
248
  row: e,
240
- column: ln
249
+ column: un
241
250
  }, r = t.current !== null && t.current.row === e && t.current.column === "__selection", i = t.isDisabled(e);
242
251
  return /* @__PURE__ */ w("div", {
243
252
  "aria-colindex": 1,
244
- "data-column": ln,
253
+ "data-column": un,
245
254
  "data-part": "selection",
246
255
  "data-part-selection": "",
247
256
  role: "gridcell",
@@ -271,14 +280,14 @@ function An({ rowKey: e }) {
271
280
  })
272
281
  });
273
282
  }
274
- function k({ node: n }) {
275
- let r = D(), i = {
276
- row: n.key,
277
- column: dn
278
- }, a = r.columnIds.indexOf(dn) + 1, o = r.current !== null && r.current.row === n.key && r.current.column === "__drag";
283
+ function Mn({ node: e }) {
284
+ let t = D(), i = {
285
+ row: e.key,
286
+ column: fn
287
+ }, a = t.columnIds.indexOf(fn) + 1, o = t.current !== null && t.current.row === e.key && t.current.column === "__drag";
279
288
  return /* @__PURE__ */ w("div", {
280
289
  "aria-colindex": a,
281
- "data-column": dn,
290
+ "data-column": fn,
282
291
  "data-kind": "drag",
283
292
  "data-part": "cell",
284
293
  "data-part-cell": "",
@@ -286,31 +295,31 @@ function k({ node: n }) {
286
295
  style: { "--slotted-data-grid-column": String(a) },
287
296
  tabIndex: o ? 0 : -1,
288
297
  onFocus: (e) => {
289
- e.target === e.currentTarget && r.onCellFocus(i);
298
+ e.target === e.currentTarget && t.onCellFocus(i);
290
299
  },
291
- onKeyDown: (e) => r.onCellKeyDown(e, i),
292
- onPointerDown: (e) => r.onCellPointerDown(e, i),
300
+ onKeyDown: (e) => t.onCellKeyDown(e, i),
301
+ onPointerDown: (e) => t.onCellPointerDown(e, i),
293
302
  ...o ? { "data-current": "" } : {},
294
303
  children: /* @__PURE__ */ w("button", {
295
- "aria-disabled": !r.rowsReorderable || void 0,
296
- "aria-label": r.t("reorderRow", { row: r.rowLabelOf(n.key) }),
304
+ "aria-disabled": !t.rowsReorderable || void 0,
305
+ "aria-label": t.t("reorderRow", { row: t.rowLabelOf(e.key) }),
297
306
  "data-part": "row-handle",
298
307
  "data-part-row-handle": "",
299
- ...r.rowsReorderable ? {} : { "data-disabled": "" },
308
+ ...t.rowsReorderable ? {} : { "data-disabled": "" },
300
309
  tabIndex: o ? 0 : -1,
301
310
  type: "button",
302
- children: /* @__PURE__ */ w(t, { children: /* @__PURE__ */ w(e, { name: "grip-vertical" }) })
311
+ children: /* @__PURE__ */ w(r, { children: /* @__PURE__ */ w(n, { name: "grip-vertical" }) })
303
312
  })
304
313
  });
305
314
  }
306
- function jn({ node: n }) {
307
- let r = D(), i = {
308
- row: n.key,
309
- column: un
310
- }, a = r.columnIds.indexOf(un) + 1, o = r.current !== null && r.current.row === n.key && r.current.column === "__expander", s = r.isExpandable(n.row), c = r.isExpanded(n.key);
315
+ function k({ node: e }) {
316
+ let t = D(), i = {
317
+ row: e.key,
318
+ column: dn
319
+ }, a = t.columnIds.indexOf(dn) + 1, o = t.current !== null && t.current.row === e.key && t.current.column === "__expander", s = t.isExpandable(e.row), c = t.isExpanded(e.key);
311
320
  return /* @__PURE__ */ w("div", {
312
321
  "aria-colindex": a,
313
- "data-column": un,
322
+ "data-column": dn,
314
323
  "data-kind": "expander",
315
324
  "data-part": "cell",
316
325
  "data-part-cell": "",
@@ -318,43 +327,43 @@ function jn({ node: n }) {
318
327
  style: { "--slotted-data-grid-column": String(a) },
319
328
  tabIndex: o ? 0 : -1,
320
329
  onFocus: (e) => {
321
- e.target === e.currentTarget && r.onCellFocus(i);
330
+ e.target === e.currentTarget && t.onCellFocus(i);
322
331
  },
323
- onKeyDown: (e) => r.onCellKeyDown(e, i),
324
- onPointerDown: (e) => r.onCellPointerDown(e, i),
332
+ onKeyDown: (e) => t.onCellKeyDown(e, i),
333
+ onPointerDown: (e) => t.onCellPointerDown(e, i),
325
334
  ...o ? { "data-current": "" } : {},
326
335
  children: s ? /* @__PURE__ */ w("button", {
327
- "aria-controls": c ? r.detailId(n.key) : void 0,
336
+ "aria-controls": c ? t.detailId(e.key) : void 0,
328
337
  "aria-expanded": c,
329
- "aria-label": r.t(c ? "collapse" : "expand"),
338
+ "aria-label": t.t(c ? "collapse" : "expand"),
330
339
  "data-part": "expander",
331
340
  "data-part-expander": "",
332
- onClick: (e) => r.toggleExpanded(n.key, e),
341
+ onClick: (n) => t.toggleExpanded(e.key, n),
333
342
  tabIndex: o ? 0 : -1,
334
343
  type: "button",
335
- children: /* @__PURE__ */ w(t, { children: /* @__PURE__ */ w(e, { name: "chevron-right" }) })
344
+ children: /* @__PURE__ */ w(r, { children: /* @__PURE__ */ w(n, { name: "chevron-right" }) })
336
345
  }) : null
337
346
  });
338
347
  }
339
- function A({ column: n, node: r }) {
340
- let i = D(), a = r.key, o = {
348
+ function Nn({ column: e, node: t }) {
349
+ let i = D(), a = t.key, o = {
341
350
  row: a,
342
- column: n.id
343
- }, s = i.columnIds.indexOf(n.id) + 1, c = i.current !== null && i.current.row === a && i.current.column === n.id, l = i.isSelected(a), u = i.edit, d = u !== null && u.cell.row === a && u.columns.includes(n.id), f = i.valueOf(n.column, r.row), p = i.textOf(n.column, r.row), m = i.isEditable(n.column, r.row), h = i.rangeInfo(o), g = d ? u.messages[n.id] ?? null : null, _ = d && u.status === "invalid" && g !== null, ee = d && u.status === "pending", te = n.column.rowHeader ? "row-header" : "cell", ne = i.changedOf(o), re = i.treeColumn === n.id, ie = re && (r.childCount > 0 || r.open || i.isLoadingChildren(a) || i.hasChildren(r.row));
351
+ column: e.id
352
+ }, s = i.columnIds.indexOf(e.id) + 1, c = i.current !== null && i.current.row === a && i.current.column === e.id, l = i.isSelected(a), u = i.edit, d = u !== null && u.cell.row === a && u.columns.includes(e.id), f = i.valueOf(e.column, t.row), p = i.textOf(e.column, t.row), m = i.isEditable(e.column, t.row), h = i.rangeInfo(o), g = d ? u.messages[e.id] ?? null : null, _ = d && u.status === "invalid" && g !== null, ee = d && u.status === "pending", te = e.column.rowHeader ? "row-header" : "cell", ne = i.changedOf(o), re = i.treeColumn === e.id, ie = re && (t.childCount > 0 || t.open || i.isLoadingChildren(a) || i.hasChildren(t.row));
344
353
  return /* @__PURE__ */ T("div", {
345
- ...mn(n),
354
+ ...hn(e),
346
355
  "aria-colindex": s,
347
- "aria-readonly": i.anyEditable && !m && n.kind !== "actions" ? !0 : void 0,
356
+ "aria-readonly": i.anyEditable && !m && e.kind !== "actions" ? !0 : void 0,
348
357
  "aria-selected": i.selectionMode === "range" && h.inside ? !0 : void 0,
349
358
  "aria-invalid": _ ? !0 : void 0,
350
359
  "data-part": te,
351
360
  ...je("part", te),
352
- "data-text": n.text,
361
+ "data-text": e.text,
353
362
  role: te === "row-header" ? "rowheader" : "gridcell",
354
363
  style: re ? {
355
- ...pn(n, s),
356
- "--slotted-data-grid-level": String(r.level)
357
- } : pn(n, s),
364
+ ...mn(e, s),
365
+ "--slotted-data-grid-level": String(t.level)
366
+ } : mn(e, s),
358
367
  tabIndex: c ? 0 : -1,
359
368
  title: _ && g ? g : void 0,
360
369
  onClick: (e) => i.onCellClick(e, o),
@@ -372,11 +381,11 @@ function A({ column: n, node: r }) {
372
381
  ..._ ? { "data-invalid": "" } : {},
373
382
  ...ee ? { "data-loading": "" } : {},
374
383
  ...ne ? { "data-changed": ne } : {},
375
- ...i.anyEditable && !m && n.kind !== "actions" ? { "data-readonly": "" } : {},
384
+ ...i.anyEditable && !m && e.kind !== "actions" ? { "data-readonly": "" } : {},
376
385
  ...re ? { "data-tree": ie ? "branch" : "leaf" } : {},
377
386
  children: [re ? ie ? /* @__PURE__ */ w("button", {
378
- "aria-expanded": r.open,
379
- "aria-label": i.t(r.open ? "collapse" : "expand"),
387
+ "aria-expanded": t.open,
388
+ "aria-label": i.t(t.open ? "collapse" : "expand"),
380
389
  "data-part": "tree-toggle",
381
390
  "data-part-tree-toggle": "",
382
391
  onClick: (e) => {
@@ -386,7 +395,7 @@ function A({ column: n, node: r }) {
386
395
  tabIndex: -1,
387
396
  type: "button",
388
397
  ...i.isLoadingChildren(a) ? { "data-loading": "" } : {},
389
- children: /* @__PURE__ */ w(t, { children: /* @__PURE__ */ w(e, { name: i.isLoadingChildren(a) ? "loader-circle" : "chevron-right" }) })
398
+ children: /* @__PURE__ */ w(r, { children: /* @__PURE__ */ w(n, { name: i.isLoadingChildren(a) ? "loader-circle" : "chevron-right" }) })
390
399
  }) : /* @__PURE__ */ w("span", {
391
400
  "aria-hidden": !0,
392
401
  "data-part": "tree-toggle",
@@ -396,24 +405,24 @@ function A({ column: n, node: r }) {
396
405
  "data-part": "editor",
397
406
  "data-part-editor": "",
398
407
  children: i.renderEditorContent({
399
- row: r.row,
408
+ row: t.row,
400
409
  rowKey: a,
401
- column: n.column,
410
+ column: e.column,
402
411
  value: f,
403
412
  text: p,
404
413
  current: c,
405
414
  selected: l,
406
- draft: u.drafts[n.id],
407
- setDraft: (e) => i.setDraft(n.id, e),
415
+ draft: u.drafts[e.id],
416
+ setDraft: (t) => i.setDraft(e.id, t),
408
417
  commit: () => i.commitEdit("programmatic"),
409
418
  cancel: () => i.cancelEdit(),
410
419
  invalid: _,
411
420
  message: g
412
421
  })
413
422
  }) : i.renderCellContent({
414
- row: r.row,
423
+ row: t.row,
415
424
  rowKey: a,
416
- column: n.column,
425
+ column: e.column,
417
426
  value: f,
418
427
  text: p,
419
428
  current: c,
@@ -421,7 +430,7 @@ function A({ column: n, node: r }) {
421
430
  })]
422
431
  });
423
432
  }
424
- function Mn({ node: e }) {
433
+ function Pn({ node: e }) {
425
434
  let t = D(), n = e.key, r = {
426
435
  row: n,
427
436
  column: dt
@@ -467,20 +476,20 @@ function Mn({ node: e }) {
467
476
  }, r.id))
468
477
  });
469
478
  }
470
- function j({ node: n, rowIndex: r }) {
471
- let i = D(), a = `${lt}${n.key}`, o = i.columns.find((e) => e.id === n.column), s = i.resolved.filter((e) => e.column.aggregate !== void 0), c = s.length > 0 ? Math.min(...s.map((e) => i.columnIds.indexOf(e.id) + 1)) : i.columnIds.length + 1, l = (e) => ({
479
+ function Fn({ node: e, rowIndex: t }) {
480
+ let i = D(), a = `${lt}${e.key}`, o = i.columns.find((t) => t.id === e.column), s = i.resolved.filter((e) => e.column.aggregate !== void 0), c = s.length > 0 ? Math.min(...s.map((e) => i.columnIds.indexOf(e.id) + 1)) : i.columnIds.length + 1, l = (e) => ({
472
481
  row: a,
473
482
  column: e
474
- }), u = i.columnIds[0], d = i.current !== null && i.current.row === a, f = i.t("groupCount", { count: n.count });
483
+ }), u = i.columnIds[0], d = i.current !== null && i.current.row === a, f = i.t("groupCount", { count: e.count });
475
484
  return /* @__PURE__ */ T("div", {
476
- "aria-expanded": n.expanded,
477
- "aria-level": n.level,
478
- "aria-rowindex": r,
485
+ "aria-expanded": e.expanded,
486
+ "aria-level": e.level,
487
+ "aria-rowindex": t,
479
488
  "data-part": "group-row",
480
489
  "data-part-group-row": "",
481
490
  "data-row": a,
482
491
  role: "row",
483
- style: { "--slotted-data-grid-level": String(n.level) },
492
+ style: { "--slotted-data-grid-level": String(e.level) },
484
493
  ...d ? { "data-current": "" } : {},
485
494
  children: [/* @__PURE__ */ T("div", {
486
495
  "aria-colindex": 1,
@@ -497,38 +506,38 @@ function j({ node: n, rowIndex: r }) {
497
506
  onPointerDown: (e) => i.onCellPointerDown(e, l(u)),
498
507
  ...d && i.current?.column === u ? { "data-current": "" } : {},
499
508
  children: [/* @__PURE__ */ w("button", {
500
- "aria-expanded": n.expanded,
501
- "aria-label": i.t(n.expanded ? "collapseGroup" : "expandGroup", { group: n.text }),
509
+ "aria-expanded": e.expanded,
510
+ "aria-label": i.t(e.expanded ? "collapseGroup" : "expandGroup", { group: e.text }),
502
511
  "data-part": "group-toggle",
503
512
  "data-part-group-toggle": "",
504
- onClick: (e) => {
505
- e.stopPropagation(), i.toggleGroup(n.key, e);
513
+ onClick: (t) => {
514
+ t.stopPropagation(), i.toggleGroup(e.key, t);
506
515
  },
507
516
  tabIndex: -1,
508
517
  type: "button",
509
- children: /* @__PURE__ */ w(t, { children: /* @__PURE__ */ w(e, { name: "chevron-right" }) })
518
+ children: /* @__PURE__ */ w(r, { children: /* @__PURE__ */ w(n, { name: "chevron-right" }) })
510
519
  }), i.renderGroup && o ? i.renderGroup({
511
- node: n,
520
+ node: e,
512
521
  column: o,
513
- toggle: () => i.toggleGroup(n.key)
514
- }) : /* @__PURE__ */ T(He, { children: [/* @__PURE__ */ w("span", { children: n.text }), /* @__PURE__ */ w("span", {
522
+ toggle: () => i.toggleGroup(e.key)
523
+ }) : /* @__PURE__ */ T(He, { children: [/* @__PURE__ */ w("span", { children: e.text }), /* @__PURE__ */ w("span", {
515
524
  "data-count": "",
516
525
  children: f
517
526
  })] })]
518
- }), s.map((e) => {
519
- let t = i.columnIds.indexOf(e.id) + 1, r = n.aggregates[e.id], a = r == null ? "" : ht({
520
- ...e.column,
527
+ }), s.map((t) => {
528
+ let n = i.columnIds.indexOf(t.id) + 1, r = e.aggregates[t.id], a = r == null ? "" : ht({
529
+ ...t.column,
521
530
  accessor: () => r
522
- }, n.rows[0], {
531
+ }, e.rows[0], {
523
532
  locale: i.locale,
524
533
  booleans: i.booleans
525
- }), o = l(e.id), s = d && i.current?.column === e.id;
534
+ }), o = l(t.id), s = d && i.current?.column === t.id;
526
535
  return /* @__PURE__ */ Fe("div", {
527
- ...mn(e),
528
- "aria-colindex": t,
529
- key: e.id,
536
+ ...hn(t),
537
+ "aria-colindex": n,
538
+ key: t.id,
530
539
  role: "gridcell",
531
- style: pn(e, t),
540
+ style: mn(t, n),
532
541
  tabIndex: s ? 0 : -1,
533
542
  onFocus: (e) => {
534
543
  e.target === e.currentTarget && i.onCellFocus(o);
@@ -543,7 +552,7 @@ function j({ node: n, rowIndex: r }) {
543
552
  })]
544
553
  });
545
554
  }
546
- function Nn({ rows: e, rowSize: t }) {
555
+ function In({ rows: e, rowSize: t }) {
547
556
  let n = D(), r = n.columnIds.length - n.resolved.length;
548
557
  return /* @__PURE__ */ w("div", {
549
558
  "aria-hidden": !0,
@@ -572,7 +581,7 @@ function Nn({ rows: e, rowSize: t }) {
572
581
  }, t))
573
582
  });
574
583
  }
575
- function Pn({ aggregates: e, rowIndex: t }) {
584
+ function Ln({ aggregates: e, rowIndex: t }) {
576
585
  let n = D(), r = n.current !== null && n.current.row === pt, i = n.columnIds.length - n.resolved.length, a = (t) => {
577
586
  let r = e[t.id];
578
587
  return r == null ? "" : ht({
@@ -610,13 +619,13 @@ function Pn({ aggregates: e, rowIndex: t }) {
610
619
  column: e.id
611
620
  }, o = r && n.current?.column === e.id, s = a(e);
612
621
  return /* @__PURE__ */ Fe("div", {
613
- ...mn(e),
622
+ ...hn(e),
614
623
  "aria-colindex": t,
615
624
  "data-part": "summary-cell",
616
625
  "data-part-summary-cell": "",
617
626
  key: e.id,
618
627
  role: "gridcell",
619
- style: pn(e, t),
628
+ style: mn(e, t),
620
629
  tabIndex: o ? 0 : -1,
621
630
  onFocus: (e) => {
622
631
  e.target === e.currentTarget && n.onCellFocus(i);
@@ -661,29 +670,29 @@ function Pn({ aggregates: e, rowIndex: t }) {
661
670
  }
662
671
  //#endregion
663
672
  //#region src/data-grid/data-grid-defaults.tsx
664
- var Fn = Pe({});
665
- function In({ children: e, ...t }) {
666
- let n = { ...Le(Fn) };
673
+ var Rn = Pe({});
674
+ function zn({ children: e, ...t }) {
675
+ let n = { ...Le(Rn) };
667
676
  for (let [e, r] of Object.entries(t)) r !== void 0 && (n[e] = r);
668
677
  let r = x(() => n, [JSON.stringify(n)]);
669
- return /* @__PURE__ */ w(Fn.Provider, {
678
+ return /* @__PURE__ */ w(Rn.Provider, {
670
679
  value: r,
671
680
  children: e
672
681
  });
673
682
  }
674
- function Ln() {
675
- return Le(Fn);
683
+ function Bn() {
684
+ return Le(Rn);
676
685
  }
677
686
  //#endregion
678
687
  //#region src/data-grid/use-data-source.ts
679
- var Rn = 20, zn = [];
680
- function Bn(e, t) {
688
+ var Vn = 20, Hn = [];
689
+ function Un(e, t) {
681
690
  let [n, r] = C({
682
691
  key: null,
683
692
  result: null,
684
693
  loading: e !== void 0,
685
694
  error: null
686
- }), i = S(/* @__PURE__ */ new Map()), a = S(null), [o, s] = C(0), c = e ? Ft(t) : null;
695
+ }), i = S(/* @__PURE__ */ new Map()), a = S(null), [o, s] = C(0), c = e ? It(t) : null;
687
696
  b(() => {
688
697
  if (!e || c === null) return;
689
698
  let n = i.current.get(c);
@@ -704,7 +713,7 @@ function Bn(e, t) {
704
713
  error: null
705
714
  })), e.getRows(t, { signal: o.signal }).then((t) => {
706
715
  if (o.signal.aborted) return;
707
- let n = e.cacheSize ?? Rn;
716
+ let n = e.cacheSize ?? Vn;
708
717
  if (n > 0) for (i.current.set(c, t); i.current.size > n;) {
709
718
  let e = i.current.keys().next().value;
710
719
  if (e === void 0) break;
@@ -734,7 +743,7 @@ function Bn(e, t) {
734
743
  i.current.clear(), s((e) => e + 1);
735
744
  }, []);
736
745
  return {
737
- rows: n.result?.rows ?? zn,
746
+ rows: n.result?.rows ?? Hn,
738
747
  total: n.result?.total,
739
748
  hasMore: n.result?.hasMore,
740
749
  loading: n.loading,
@@ -745,26 +754,26 @@ function Bn(e, t) {
745
754
  }
746
755
  //#endregion
747
756
  //#region src/data-grid/data-grid-editors.tsx
748
- function Vn(e) {
757
+ function Wn(e) {
749
758
  return /* @__PURE__ */ w("span", {
750
759
  title: e.text,
751
760
  children: e.text
752
761
  });
753
762
  }
754
- function Hn(e) {
763
+ function Gn(e) {
755
764
  if (!e) return null;
756
765
  let t = String(e);
757
766
  return $e(/^\d{2}$/.test(t) ? `${t}:00` : t);
758
767
  }
759
- function Un(e) {
768
+ function Kn(e) {
760
769
  if (!e) return null;
761
770
  let t = String(e);
762
771
  return /^\d{4}-\d{2}-\d{2}$/.test(t) ? Qe(`${t}T00:00`) : /^\d{4}-\d{2}-\d{2}T\d{2}$/.test(t) ? Qe(`${t}:00`) : Qe(t);
763
772
  }
764
- function M(e) {
773
+ function qn(e) {
765
774
  return e ? Ze(String(e)) : null;
766
775
  }
767
- function Wn(e, t, n) {
776
+ function Jn(e, t, n) {
768
777
  let { column: r, draft: i, setDraft: a, invalid: o, message: s } = e, c = r.kind ?? "text", l = r.label, u = {
769
778
  "aria-label": l,
770
779
  autoFocus: !0,
@@ -792,19 +801,19 @@ function Wn(e, t, n) {
792
801
  case "date": return /* @__PURE__ */ w(de, {
793
802
  ...u,
794
803
  onValueChange: (e) => a(Je(e) ? et(e) : null),
795
- value: M(i),
804
+ value: qn(i),
796
805
  ...n === void 0 ? {} : { locale: n }
797
806
  });
798
807
  case "time": return /* @__PURE__ */ w(ke, {
799
808
  ...u,
800
809
  onValueChange: (e) => a(Xe(e) ? nt(e, "minute") : null),
801
- value: Hn(i),
810
+ value: Gn(i),
802
811
  ...n === void 0 ? {} : { locale: n }
803
812
  });
804
813
  case "datetime": return /* @__PURE__ */ w(me, {
805
814
  ...u,
806
815
  onValueChange: (e) => a(Ye(e) ? tt(e) : null),
807
- value: Un(i),
816
+ value: Kn(i),
808
817
  ...n === void 0 ? {} : { locale: n }
809
818
  });
810
819
  case "set": {
@@ -839,7 +848,7 @@ function Wn(e, t, n) {
839
848
  }
840
849
  //#endregion
841
850
  //#region src/data-grid/data-grid-filter.tsx
842
- var Gn = [
851
+ var Yn = [
843
852
  "text",
844
853
  "number",
845
854
  "date",
@@ -848,21 +857,21 @@ var Gn = [
848
857
  "boolean",
849
858
  "set"
850
859
  ];
851
- function Kn(e) {
852
- return Gn.includes(e.kind) ? e.kind : null;
860
+ function A(e) {
861
+ return Yn.includes(e.kind) ? e.kind : null;
853
862
  }
854
- function qn(e, t) {
855
- return an(e) === an(t);
863
+ function j(e, t) {
864
+ return on(e) === on(t);
856
865
  }
857
- var Jn = [
866
+ var Xn = [
858
867
  "date",
859
868
  "time",
860
869
  "datetime"
861
870
  ];
862
- function Yn(e, t) {
863
- return tn(t) === 2 && Jn.includes(e);
871
+ function Zn(e, t) {
872
+ return nn(t) === 2 && Xn.includes(e);
864
873
  }
865
- function Xn({ kind: e, start: t, end: n, onChange: r, t: i, locale: a, variant: o, autoFocus: s }) {
874
+ function Qn({ kind: e, start: t, end: n, onChange: r, t: i, locale: a, variant: o, autoFocus: s }) {
866
875
  let c = {
867
876
  size: "sm",
868
877
  variant: o,
@@ -877,16 +886,16 @@ function Xn({ kind: e, start: t, end: n, onChange: r, t: i, locale: a, variant:
877
886
  ...l,
878
887
  onValueChange: (e) => r(Xe(e?.start) ? nt(e.start, "minute") : null, Xe(e?.end) ? nt(e.end, "minute") : null),
879
888
  value: {
880
- start: Hn(t),
881
- end: Hn(n)
889
+ start: Gn(t),
890
+ end: Gn(n)
882
891
  }
883
892
  }) : e === "datetime" ? /* @__PURE__ */ w(he, {
884
893
  ...c,
885
894
  ...l,
886
895
  onValueChange: (e) => r(Ye(e?.start) ? tt(e.start) : null, Ye(e?.end) ? tt(e.end) : null),
887
896
  value: {
888
- start: Un(t),
889
- end: Un(n)
897
+ start: Kn(t),
898
+ end: Kn(n)
890
899
  }
891
900
  }) : /* @__PURE__ */ w(fe, {
892
901
  ...c,
@@ -896,12 +905,12 @@ function Xn({ kind: e, start: t, end: n, onChange: r, t: i, locale: a, variant:
896
905
  },
897
906
  onValueChange: (e) => r(Je(e?.start) ? et(e.start) : null, Je(e?.end) ? et(e.end) : null),
898
907
  value: {
899
- start: M(t),
900
- end: M(n)
908
+ start: qn(t),
909
+ end: qn(n)
901
910
  }
902
911
  });
903
912
  }
904
- function Zn({ autoFocus: e, column: t, counts: n, kind: r, label: i, t: a, locale: o, onChange: s, onKeyDown: c, placeholder: l, value: u, variant: d }) {
913
+ function $n({ autoFocus: e, column: t, counts: n, kind: r, label: i, t: a, locale: o, onChange: s, onKeyDown: c, placeholder: l, value: u, variant: d }) {
905
914
  let f = {
906
915
  "aria-label": i,
907
916
  size: "sm",
@@ -921,17 +930,17 @@ function Zn({ autoFocus: e, column: t, counts: n, kind: r, label: i, t: a, local
921
930
  case "date": return /* @__PURE__ */ w(ue, {
922
931
  ...f,
923
932
  onValueChange: (e) => s(Je(e) ? et(e) : null),
924
- value: M(u)
933
+ value: qn(u)
925
934
  });
926
935
  case "time": return /* @__PURE__ */ w(Oe, {
927
936
  ...f,
928
937
  onValueChange: (e) => s(Xe(e) ? nt(e, "minute") : null),
929
- value: Hn(u)
938
+ value: Gn(u)
930
939
  });
931
940
  case "datetime": return /* @__PURE__ */ w(pe, {
932
941
  ...f,
933
942
  onValueChange: (e) => s(Ye(e) ? tt(e) : null),
934
- value: Un(u)
943
+ value: Kn(u)
935
944
  });
936
945
  case "boolean": return /* @__PURE__ */ T(Ce, {
937
946
  fullWidth: !0,
@@ -999,10 +1008,10 @@ function Zn({ autoFocus: e, column: t, counts: n, kind: r, label: i, t: a, local
999
1008
  });
1000
1009
  }
1001
1010
  }
1002
- function Qn({ column: e, children: t }) {
1003
- let n = D(), r = Kn(e), i = n.filterOpen === e.id && r !== null, a = n.filterOf(e.id), o = n.t, s = S(null), c = y((e) => {
1011
+ function er({ column: e, children: t }) {
1012
+ let n = D(), r = A(e), i = n.filterOpen === e.id && r !== null, a = n.filterOf(e.id), o = n.t, s = S(null), c = y((e) => {
1004
1013
  s.current = e;
1005
- }, []), u = y(() => r ? Zt(r) : null, [r]), [d, f] = C(a ?? u()), p = S(!1);
1014
+ }, []), u = y(() => r ? Qt(r) : null, [r]), [d, f] = C(a ?? u()), p = S(!1);
1006
1015
  if (b(() => {
1007
1016
  i && !p.current && f(a ?? u()), p.current = i;
1008
1017
  }, [
@@ -1013,27 +1022,27 @@ function Qn({ column: e, children: t }) {
1013
1022
  let m = r, h = e.column.label, g = {
1014
1023
  join: (e) => o(`filterJoins.${e}`),
1015
1024
  operator: (e) => o(`filterOperators.${e}`)
1016
- }, ee = nn(r), re = r === "set" ? 1 : 2, v = d ?? u(), ae = (e) => v.conditions[e] ?? { operator: Yt(r) }, oe = re === 2 && Qt(r, ae(0));
1025
+ }, ee = rn(r), re = r === "set" ? 1 : 2, v = d ?? u(), ae = (e) => v.conditions[e] ?? { operator: Xt(r) }, oe = re === 2 && $t(r, ae(0));
1017
1026
  function se() {
1018
1027
  n.setFilterOpen(null);
1019
1028
  }
1020
1029
  function ce(t, r) {
1021
- let i = en(v);
1022
- qn(i, a) || n.setFilter(e.id, i, r, t), n.announce(i ? o("filterApplied", {
1030
+ let i = tn(v);
1031
+ j(i, a) || n.setFilter(e.id, i, r, t), n.announce(i ? o("filterApplied", {
1023
1032
  column: h,
1024
- filter: Xt(i, g)
1033
+ filter: Zt(i, g)
1025
1034
  }) : o("filterCleared", { column: h })), se();
1026
1035
  }
1027
1036
  function le(t) {
1028
1037
  f(u()), a && n.setFilter(e.id, null, "clear", t), n.announce(o("filterCleared", { column: h })), se();
1029
1038
  }
1030
1039
  function ue(e, t) {
1031
- let n = ae(e), r = tn(n.operator), i = tn(t), a = {
1040
+ let n = ae(e), r = nn(n.operator), i = nn(t), a = {
1032
1041
  operator: t,
1033
1042
  ...i >= 1 && r >= 1 ? { value: n.value } : {},
1034
1043
  ...i === 2 && r === 2 ? { end: n.end } : {}
1035
1044
  };
1036
- f(on(v, e, a));
1045
+ f(sn(v, e, a));
1037
1046
  }
1038
1047
  function de(e, t, n) {
1039
1048
  let r = ae(e), i = t === 0 ? {
@@ -1043,13 +1052,13 @@ function Qn({ column: e, children: t }) {
1043
1052
  ...r,
1044
1053
  end: n
1045
1054
  };
1046
- f(on(v, e, i));
1055
+ f(sn(v, e, i));
1047
1056
  }
1048
1057
  let fe = (e) => {
1049
1058
  e.key === "Enter" && !e.defaultPrevented && (e.preventDefault(), ce(e, "keyboard"));
1050
1059
  };
1051
1060
  function pe(t) {
1052
- let r = ae(t), i = tn(r.operator), a = n.renderFilterOperand;
1061
+ let r = ae(t), i = nn(r.operator), a = n.renderFilterOperand;
1053
1062
  return /* @__PURE__ */ T("div", {
1054
1063
  "data-operands": i,
1055
1064
  "data-part": "filter-condition",
@@ -1060,7 +1069,7 @@ function Qn({ column: e, children: t }) {
1060
1069
  "data-part-filter-join": "",
1061
1070
  children: /* @__PURE__ */ T(Se, {
1062
1071
  "aria-label": o("filterJoin"),
1063
- onValueChange: (e) => f(sn(v, e)),
1072
+ onValueChange: (e) => f(cn(v, e)),
1064
1073
  size: "sm",
1065
1074
  value: v.join,
1066
1075
  children: [/* @__PURE__ */ w(xe, {
@@ -1099,13 +1108,13 @@ function Qn({ column: e, children: t }) {
1099
1108
  "data-kind": m,
1100
1109
  "data-part": "filter-operand",
1101
1110
  "data-part-filter-operand": "",
1102
- ...i === 2 && !Yn(m, r.operator) ? { "data-range": "" } : {},
1103
- children: i === 0 ? null : !a && Yn(m, r.operator) ? /* @__PURE__ */ w(Xn, {
1111
+ ...i === 2 && !Zn(m, r.operator) ? { "data-range": "" } : {},
1112
+ children: i === 0 ? null : !a && Zn(m, r.operator) ? /* @__PURE__ */ w(Qn, {
1104
1113
  end: r.end ?? null,
1105
1114
  kind: m,
1106
1115
  t: o,
1107
1116
  locale: n.locale,
1108
- onChange: (e, n) => f(on(v, t, {
1117
+ onChange: (e, n) => f(sn(v, t, {
1109
1118
  ...r,
1110
1119
  value: e,
1111
1120
  end: n
@@ -1121,7 +1130,7 @@ function Qn({ column: e, children: t }) {
1121
1130
  setValue: (e) => de(t, s, e),
1122
1131
  apply: () => ce(null, "keyboard"),
1123
1132
  label: c
1124
- }) }, s) : /* @__PURE__ */ w(Zn, {
1133
+ }) }, s) : /* @__PURE__ */ w($n, {
1125
1134
  column: e,
1126
1135
  counts: m === "set" ? n.countsFor(e.id) : void 0,
1127
1136
  kind: m,
@@ -1165,7 +1174,7 @@ function Qn({ column: e, children: t }) {
1165
1174
  "data-part": "filter-actions",
1166
1175
  "data-part-filter-actions": "",
1167
1176
  children: [/* @__PURE__ */ w(l, {
1168
- disabled: !$t(v) && a === null,
1177
+ disabled: !en(v) && a === null,
1169
1178
  onClick: (e) => le(e),
1170
1179
  size: "sm",
1171
1180
  tone: "secondary",
@@ -1182,14 +1191,14 @@ function Qn({ column: e, children: t }) {
1182
1191
  }) }) : null]
1183
1192
  });
1184
1193
  }
1185
- function $n({ column: e }) {
1186
- let t = D(), i = Kn(e), s = t.columnIds.indexOf(e.id) + 1, c = {
1194
+ function tr({ column: e }) {
1195
+ let t = D(), n = A(e), r = t.columnIds.indexOf(e.id) + 1, o = {
1187
1196
  row: ct,
1188
1197
  column: e.id
1189
- }, l = t.current !== null && t.current.row === ct && t.current.column === e.id, u = t.filterOf(e.id), d = t.t, f = u?.conditions[0] ?? null, [p, m] = C(f?.operator ?? (i ? Yt(i) : "contains")), [h, g] = C({
1198
+ }, l = t.current !== null && t.current.row === ct && t.current.column === e.id, u = t.filterOf(e.id), d = t.t, f = u?.conditions[0] ?? null, [p, m] = C(f?.operator ?? (n ? Xt(n) : "contains")), [h, g] = C({
1190
1199
  value: f?.value ?? null,
1191
1200
  end: f?.end ?? null
1192
- }), _ = S(void 0), ee = an(u), te = S(ee);
1201
+ }), _ = S(void 0), ee = on(u), te = S(ee);
1193
1202
  if (b(() => {
1194
1203
  if (te.current === ee) return;
1195
1204
  te.current = ee;
@@ -1201,24 +1210,24 @@ function $n({ column: e }) {
1201
1210
  value: null,
1202
1211
  end: null
1203
1212
  });
1204
- }, [ee, u]), b(() => () => clearTimeout(_.current), []), !i || !e.filterable) return /* @__PURE__ */ w("div", {
1205
- ...mn(e),
1206
- "aria-colindex": s,
1213
+ }, [ee, u]), b(() => () => clearTimeout(_.current), []), !n || !e.filterable) return /* @__PURE__ */ w("div", {
1214
+ ...hn(e),
1215
+ "aria-colindex": r,
1207
1216
  "data-part": "filter-cell",
1208
1217
  "data-part-filter-cell": "",
1209
1218
  role: "gridcell",
1210
- style: pn(e, s),
1219
+ style: mn(e, r),
1211
1220
  tabIndex: l ? 0 : -1,
1212
1221
  onFocus: (e) => {
1213
- e.target === e.currentTarget && t.onCellFocus(c);
1222
+ e.target === e.currentTarget && t.onCellFocus(o);
1214
1223
  },
1215
- onKeyDown: (e) => t.onCellKeyDown(e, c),
1216
- onPointerDown: (e) => t.onCellPointerDown(e, c),
1224
+ onKeyDown: (e) => t.onCellKeyDown(e, o),
1225
+ onPointerDown: (e) => t.onCellPointerDown(e, o),
1217
1226
  ...l ? { "data-current": "" } : {}
1218
1227
  });
1219
- let ne = i, re = nn(i), ie = tn(p);
1228
+ let ne = n, re = rn(n), ie = nn(p);
1220
1229
  function v(n, r) {
1221
- let i = en({
1230
+ let i = tn({
1222
1231
  kind: ne,
1223
1232
  join: "and",
1224
1233
  conditions: [{
@@ -1227,19 +1236,19 @@ function $n({ column: e }) {
1227
1236
  end: n.end
1228
1237
  }]
1229
1238
  });
1230
- qn(i, u) || t.setFilter(e.id, i, r, void 0);
1239
+ j(i, u) || t.setFilter(e.id, i, r, void 0);
1231
1240
  }
1232
- function ae(e, n) {
1241
+ function ae(e, r) {
1233
1242
  g(e), clearTimeout(_.current);
1234
- let r = () => v({
1243
+ let i = () => v({
1235
1244
  operator: p,
1236
1245
  ...e
1237
1246
  }, "keyboard");
1238
- n || i !== "text" && i !== "number" ? r() : _.current = setTimeout(r, t.filterDebounce);
1247
+ r || n !== "text" && n !== "number" ? i() : _.current = setTimeout(i, t.filterDebounce);
1239
1248
  }
1240
1249
  function oe(e) {
1241
1250
  m(e);
1242
- let t = tn(e), n = {
1251
+ let t = nn(e), n = {
1243
1252
  value: t >= 1 ? h.value : null,
1244
1253
  end: t === 2 ? h.end : null
1245
1254
  };
@@ -1255,45 +1264,45 @@ function $n({ column: e }) {
1255
1264
  }, "keyboard"));
1256
1265
  }, ce = d(`filterSymbols.${p}`), le = t.renderFilterOperand;
1257
1266
  return /* @__PURE__ */ w("div", {
1258
- ...mn(e),
1259
- "aria-colindex": s,
1267
+ ...hn(e),
1268
+ "aria-colindex": r,
1260
1269
  "data-part": "filter-cell",
1261
1270
  "data-part-filter-cell": "",
1262
1271
  role: "gridcell",
1263
- style: pn(e, s),
1272
+ style: mn(e, r),
1264
1273
  tabIndex: l ? 0 : -1,
1265
1274
  onFocus: (e) => {
1266
- e.target === e.currentTarget && t.onCellFocus(c);
1275
+ e.target === e.currentTarget && t.onCellFocus(o);
1267
1276
  },
1268
- onKeyDown: (e) => t.onCellKeyDown(e, c),
1269
- onPointerDown: (e) => t.onCellPointerDown(e, c),
1277
+ onKeyDown: (e) => t.onCellKeyDown(e, o),
1278
+ onPointerDown: (e) => t.onCellPointerDown(e, o),
1270
1279
  ...u ? { "data-filtered": "" } : {},
1271
1280
  ...l ? { "data-current": "" } : {},
1272
1281
  children: /* @__PURE__ */ T("div", {
1273
- "data-kind": i,
1282
+ "data-kind": n,
1274
1283
  "data-part": "filter-operand",
1275
1284
  "data-part-filter-operand": "",
1276
- ...ie === 2 && !Yn(i, p) ? { "data-range": "" } : {},
1285
+ ...ie === 2 && !Zn(n, p) ? { "data-range": "" } : {},
1277
1286
  children: [/* @__PURE__ */ w("div", {
1278
1287
  "data-part": "filter-operator",
1279
1288
  "data-part-filter-operator": "",
1280
- children: /* @__PURE__ */ T(n, {
1289
+ children: /* @__PURE__ */ T(i, {
1281
1290
  size: "sm",
1282
- children: [/* @__PURE__ */ w(a, { render: (e) => /* @__PURE__ */ w("button", {
1291
+ children: [/* @__PURE__ */ w(s, { render: (e) => /* @__PURE__ */ w("button", {
1283
1292
  ...e,
1284
1293
  "aria-label": d("filterOperatorChosen", { operator: d(`filterOperators.${p}`) }),
1285
1294
  title: d(`filterOperators.${p}`),
1286
1295
  tabIndex: -1,
1287
1296
  type: "button",
1288
1297
  children: ce
1289
- }) }), /* @__PURE__ */ w(o, { children: re.map((e) => /* @__PURE__ */ w(r, {
1298
+ }) }), /* @__PURE__ */ w(c, { children: re.map((e) => /* @__PURE__ */ w(a, {
1290
1299
  onSelect: () => oe(e),
1291
1300
  children: d(`filterOperators.${e}`)
1292
1301
  }, e)) })]
1293
1302
  })
1294
- }), ie === 0 ? null : !le && Yn(i, p) ? /* @__PURE__ */ w(Xn, {
1303
+ }), ie === 0 ? null : !le && Zn(n, p) ? /* @__PURE__ */ w(Qn, {
1295
1304
  end: h.end,
1296
- kind: i,
1305
+ kind: n,
1297
1306
  t: d,
1298
1307
  locale: t.locale,
1299
1308
  onChange: (e, t) => ae({
@@ -1302,11 +1311,11 @@ function $n({ column: e }) {
1302
1311
  }, !0),
1303
1312
  start: h.value,
1304
1313
  variant: "plain"
1305
- }) : [0, 1].slice(0, ie).map((n) => {
1306
- let r = ie === 2 ? d("filterRange", {
1307
- bound: n === 0 ? "from" : "to",
1314
+ }) : [0, 1].slice(0, ie).map((r) => {
1315
+ let i = ie === 2 ? d("filterRange", {
1316
+ bound: r === 0 ? "from" : "to",
1308
1317
  column: e.column.label
1309
- }) : d("filterColumn", { column: e.column.label }), a = n === 0 ? h.value : h.end, o = (e, t = !1) => ae(n === 0 ? {
1318
+ }) : d("filterColumn", { column: e.column.label }), a = r === 0 ? h.value : h.end, o = (e, t = !1) => ae(r === 0 ? {
1310
1319
  ...h,
1311
1320
  value: e
1312
1321
  } : {
@@ -1322,29 +1331,29 @@ function $n({ column: e }) {
1322
1331
  operator: p,
1323
1332
  ...h
1324
1333
  }, "keyboard"),
1325
- label: r
1326
- }) }, n) : /* @__PURE__ */ w(Zn, {
1334
+ label: i
1335
+ }) }, r) : /* @__PURE__ */ w($n, {
1327
1336
  column: e,
1328
- counts: i === "set" ? t.countsFor(e.id) : void 0,
1329
- kind: i,
1330
- label: r,
1337
+ counts: n === "set" ? t.countsFor(e.id) : void 0,
1338
+ kind: n,
1339
+ label: i,
1331
1340
  t: d,
1332
1341
  locale: t.locale,
1333
- onChange: (e) => o(e, i !== "text" && i !== "number"),
1342
+ onChange: (e) => o(e, n !== "text" && n !== "number"),
1334
1343
  onKeyDown: se,
1335
1344
  operator: p,
1336
- placeholder: d(ie === 2 ? n === 0 ? "filterFrom" : "filterTo" : "filter"),
1345
+ placeholder: d(ie === 2 ? r === 0 ? "filterFrom" : "filterTo" : "filter"),
1337
1346
  value: a,
1338
1347
  variant: "plain"
1339
- }, n);
1348
+ }, r);
1340
1349
  })]
1341
1350
  })
1342
1351
  });
1343
1352
  }
1344
1353
  //#endregion
1345
1354
  //#region src/data-grid/data-grid-header.tsx
1346
- var er = 4;
1347
- function tr({ columnGroups: e, headerRowCount: t }) {
1355
+ var M = 4;
1356
+ function nr({ columnGroups: e, headerRowCount: t }) {
1348
1357
  let n = D(), r = n.columnIds.length - n.resolved.length, i = e !== void 0 && e.length > 0;
1349
1358
  return /* @__PURE__ */ T("div", {
1350
1359
  "data-part": "head",
@@ -1356,7 +1365,7 @@ function tr({ columnGroups: e, headerRowCount: t }) {
1356
1365
  "data-part": "header-row",
1357
1366
  "data-part-header-row": "",
1358
1367
  role: "row",
1359
- children: N(n.mountedColumns, e, r)
1368
+ children: rr(n.mountedColumns, e, r)
1360
1369
  }) : null,
1361
1370
  /* @__PURE__ */ T("div", {
1362
1371
  "aria-rowindex": i ? 2 : 1,
@@ -1365,28 +1374,28 @@ function tr({ columnGroups: e, headerRowCount: t }) {
1365
1374
  "data-row": ut,
1366
1375
  role: "row",
1367
1376
  children: [
1368
- n.columnIds.includes("__selection") ? /* @__PURE__ */ w(nr, {}) : null,
1377
+ n.columnIds.includes("__selection") ? /* @__PURE__ */ w(ir, {}) : null,
1369
1378
  n.columnIds.includes("__drag") ? /* @__PURE__ */ w("div", {
1370
- "aria-colindex": n.columnIds.indexOf(dn) + 1,
1371
- "data-column": dn,
1379
+ "aria-colindex": n.columnIds.indexOf(fn) + 1,
1380
+ "data-column": fn,
1372
1381
  "data-part": "column-header",
1373
1382
  "data-part-column-header": "",
1374
1383
  role: "columnheader",
1375
- style: { "--slotted-data-grid-column": String(n.columnIds.indexOf(dn) + 1) },
1384
+ style: { "--slotted-data-grid-column": String(n.columnIds.indexOf(fn) + 1) },
1376
1385
  tabIndex: -1,
1377
1386
  children: /* @__PURE__ */ w("span", {})
1378
1387
  }) : null,
1379
1388
  n.columnIds.includes("__expander") ? /* @__PURE__ */ w("div", {
1380
- "aria-colindex": n.columnIds.indexOf(un) + 1,
1381
- "data-column": un,
1389
+ "aria-colindex": n.columnIds.indexOf(dn) + 1,
1390
+ "data-column": dn,
1382
1391
  "data-part": "column-header",
1383
1392
  "data-part-column-header": "",
1384
1393
  role: "columnheader",
1385
- style: { "--slotted-data-grid-column": String(n.columnIds.indexOf(un) + 1) },
1394
+ style: { "--slotted-data-grid-column": String(n.columnIds.indexOf(dn) + 1) },
1386
1395
  tabIndex: -1,
1387
1396
  children: /* @__PURE__ */ w("span", {})
1388
1397
  }) : null,
1389
- n.mountedColumns.map((e) => /* @__PURE__ */ w(P, { column: e }, e.id)),
1398
+ n.mountedColumns.map((e) => /* @__PURE__ */ w(ar, { column: e }, e.id)),
1390
1399
  n.popinColumns.length > 0 ? /* @__PURE__ */ w("div", {
1391
1400
  "aria-colindex": n.popinIndex,
1392
1401
  "data-column": dt,
@@ -1406,35 +1415,35 @@ function tr({ columnGroups: e, headerRowCount: t }) {
1406
1415
  children: [
1407
1416
  n.columnIds.includes("__selection") ? /* @__PURE__ */ w("div", {
1408
1417
  "aria-colindex": 1,
1409
- "data-column": ln,
1418
+ "data-column": un,
1410
1419
  "data-part": "filter-cell",
1411
1420
  "data-part-filter-cell": "",
1412
1421
  role: "gridcell",
1413
1422
  tabIndex: -1
1414
1423
  }) : null,
1415
1424
  n.columnIds.includes("__drag") ? /* @__PURE__ */ w("div", {
1416
- "aria-colindex": n.columnIds.indexOf(dn) + 1,
1417
- "data-column": dn,
1425
+ "aria-colindex": n.columnIds.indexOf(fn) + 1,
1426
+ "data-column": fn,
1418
1427
  "data-part": "filter-cell",
1419
1428
  "data-part-filter-cell": "",
1420
1429
  role: "gridcell",
1421
1430
  tabIndex: -1
1422
1431
  }) : null,
1423
1432
  n.columnIds.includes("__expander") ? /* @__PURE__ */ w("div", {
1424
- "aria-colindex": n.columnIds.indexOf(un) + 1,
1425
- "data-column": un,
1433
+ "aria-colindex": n.columnIds.indexOf(dn) + 1,
1434
+ "data-column": dn,
1426
1435
  "data-part": "filter-cell",
1427
1436
  "data-part-filter-cell": "",
1428
1437
  role: "gridcell",
1429
1438
  tabIndex: -1
1430
1439
  }) : null,
1431
- n.mountedColumns.map((e) => /* @__PURE__ */ w($n, { column: e }, e.id))
1440
+ n.mountedColumns.map((e) => /* @__PURE__ */ w(tr, { column: e }, e.id))
1432
1441
  ]
1433
1442
  }) : null
1434
1443
  ]
1435
1444
  });
1436
1445
  }
1437
- function N(e, t, n) {
1446
+ function rr(e, t, n) {
1438
1447
  let r = [], i = 0;
1439
1448
  for (; i < e.length;) {
1440
1449
  let a = e[i], o = t.find((e) => e.columns.includes(a.id)), s = 1;
@@ -1454,14 +1463,14 @@ function N(e, t, n) {
1454
1463
  }
1455
1464
  return r;
1456
1465
  }
1457
- function nr() {
1466
+ function ir() {
1458
1467
  let e = D(), t = {
1459
1468
  row: ut,
1460
- column: ln
1469
+ column: un
1461
1470
  }, n = e.current !== null && e.current.row === ut && e.current.column === "__selection", r = e.t(e.total !== null && e.total > e.selectableCount ? "selectAllPage" : "selectAllFiltered", { count: e.selectableCount });
1462
1471
  return /* @__PURE__ */ w("div", {
1463
1472
  "aria-colindex": 1,
1464
- "data-column": ln,
1473
+ "data-column": un,
1465
1474
  "data-part": "selection",
1466
1475
  "data-part-selection": "",
1467
1476
  role: "gridcell",
@@ -1480,51 +1489,51 @@ function nr() {
1480
1489
  }) : null
1481
1490
  });
1482
1491
  }
1483
- function P({ column: n }) {
1484
- let r = D(), i = {
1492
+ function ar({ column: e }) {
1493
+ let t = D(), i = {
1485
1494
  row: ut,
1486
- column: n.id
1487
- }, a = r.columnIds.indexOf(n.id) + 1, o = r.current !== null && r.current.row === ut && r.current.column === n.id, s = r.sortOf(n.id), c = r.filterOf(n.id) !== null, l = r.query.sort.length > 1, u = r.menuOpen === n.id, d = r.attachDraggable, f = S(() => void 0), p = S(null), m = y((e) => {
1495
+ column: e.id
1496
+ }, a = t.columnIds.indexOf(e.id) + 1, o = t.current !== null && t.current.row === ut && t.current.column === e.id, s = t.sortOf(e.id), c = t.filterOf(e.id) !== null, l = t.query.sort.length > 1, u = t.menuOpen === e.id, d = t.attachDraggable, f = S(() => void 0), p = S(null), m = y((e) => {
1488
1497
  p.current = e, f.current(e);
1489
1498
  }, []);
1490
- b(() => (d(p.current, n.id), () => d(null, n.id)), [d, n.id]);
1491
- let h = n.column.description, g = `${r.id}-description-${n.id}`, _ = n.column.help, ee = r.renderHeaderContent ? r.renderHeaderContent({
1492
- column: n.column,
1493
- resolved: n,
1499
+ b(() => (d(p.current, e.id), () => d(null, e.id)), [d, e.id]);
1500
+ let h = e.column.description, g = `${t.id}-description-${e.id}`, _ = e.column.help, ee = t.renderHeaderContent ? t.renderHeaderContent({
1501
+ column: e.column,
1502
+ resolved: e,
1494
1503
  sorted: s?.direction ?? null,
1495
1504
  sortIndex: s?.index ?? null,
1496
1505
  filtered: c
1497
- }) : n.column.label;
1498
- return /* @__PURE__ */ w(Qn, {
1499
- column: n,
1506
+ }) : e.column.label;
1507
+ return /* @__PURE__ */ w(er, {
1508
+ column: e,
1500
1509
  children: (d) => (f.current = d, /* @__PURE__ */ T("div", {
1501
- ...mn(n),
1510
+ ...hn(e),
1502
1511
  "aria-colindex": a,
1503
1512
  "aria-describedby": h ? g : void 0,
1504
1513
  "aria-sort": s && s.index === 1 ? s.direction : void 0,
1505
1514
  "data-part": "column-header",
1506
1515
  "data-part-column-header": "",
1507
1516
  role: "columnheader",
1508
- style: pn(n, a),
1509
- tabIndex: o || E(i, r.tabStop) ? 0 : -1,
1510
- onClick: (e) => r.onCellClick(e, i),
1511
- onContextMenu: (e) => r.onHeaderContextMenu(e, n.id),
1517
+ style: mn(e, a),
1518
+ tabIndex: o || E(i, t.tabStop) ? 0 : -1,
1519
+ onClick: (e) => t.onCellClick(e, i),
1520
+ onContextMenu: (n) => t.onHeaderContextMenu(n, e.id),
1512
1521
  onFocus: (e) => {
1513
- e.target === e.currentTarget && r.onCellFocus(i);
1522
+ e.target === e.currentTarget && t.onCellFocus(i);
1514
1523
  },
1515
- onKeyDown: (e) => r.onCellKeyDown(e, i),
1516
- onPointerDown: (e) => r.onCellPointerDown(e, i),
1524
+ onKeyDown: (e) => t.onCellKeyDown(e, i),
1525
+ onPointerDown: (e) => t.onCellPointerDown(e, i),
1517
1526
  ref: m,
1518
- ...n.sortable ? { "data-sortable": "" } : {},
1527
+ ...e.sortable ? { "data-sortable": "" } : {},
1519
1528
  ...s ? { "data-sorted": s.direction } : {},
1520
1529
  ...c ? { "data-filtered": "" } : {},
1521
1530
  ...o ? { "data-current": "" } : {},
1522
- ...r.dragging === n.id ? { "data-dragging": "" } : {},
1523
- ...r.dropTarget === n.id ? { "data-drop-target": "" } : {},
1524
- ...r.resizing === n.id ? { "data-resizing": "" } : {},
1531
+ ...t.dragging === e.id ? { "data-dragging": "" } : {},
1532
+ ...t.dropTarget === e.id ? { "data-drop-target": "" } : {},
1533
+ ...t.resizing === e.id ? { "data-resizing": "" } : {},
1525
1534
  children: [
1526
- /* @__PURE__ */ w(rr, {
1527
- label: n.column.label,
1535
+ /* @__PURE__ */ w(or, {
1536
+ label: e.column.label,
1528
1537
  children: ee
1529
1538
  }),
1530
1539
  s ? /* @__PURE__ */ w("span", {
@@ -1532,7 +1541,7 @@ function P({ column: n }) {
1532
1541
  "data-part": "sort",
1533
1542
  "data-part-sort": "",
1534
1543
  ...l ? { "data-index": String(s.index) } : {},
1535
- children: /* @__PURE__ */ w(t, { children: /* @__PURE__ */ w(e, { name: "chevron-down" }) })
1544
+ children: /* @__PURE__ */ w(r, { children: /* @__PURE__ */ w(n, { name: "chevron-down" }) })
1536
1545
  }) : null,
1537
1546
  h ? /* @__PURE__ */ w("span", {
1538
1547
  "aria-hidden": "true",
@@ -1545,28 +1554,28 @@ function P({ column: n }) {
1545
1554
  "data-part": "column-actions",
1546
1555
  "data-part-column-actions": "",
1547
1556
  children: [
1548
- h || _ !== void 0 ? /* @__PURE__ */ w(ir, {
1549
- column: n,
1557
+ h || _ !== void 0 ? /* @__PURE__ */ w(sr, {
1558
+ column: e,
1550
1559
  description: h,
1551
1560
  help: _
1552
1561
  }) : null,
1553
- n.filterable ? /* @__PURE__ */ w(ar, {
1554
- column: n,
1562
+ e.filterable ? /* @__PURE__ */ w(cr, {
1563
+ column: e,
1555
1564
  filtered: c
1556
1565
  }) : null,
1557
- /* @__PURE__ */ w(or, {
1558
- column: n,
1566
+ /* @__PURE__ */ w(lr, {
1567
+ column: e,
1559
1568
  descriptionId: h ? g : void 0,
1560
1569
  open: u
1561
1570
  })
1562
1571
  ]
1563
1572
  }),
1564
- n.resizable ? /* @__PURE__ */ w(sr, { column: n }) : null
1573
+ e.resizable ? /* @__PURE__ */ w(ur, { column: e }) : null
1565
1574
  ]
1566
1575
  }))
1567
1576
  });
1568
1577
  }
1569
- function rr({ children: e, label: t }) {
1578
+ function or({ children: e, label: t }) {
1570
1579
  return /* @__PURE__ */ T(u, {
1571
1580
  describes: "none",
1572
1581
  openOn: "hover",
@@ -1578,127 +1587,127 @@ function rr({ children: e, label: t }) {
1578
1587
  }), /* @__PURE__ */ w(p, { children: /* @__PURE__ */ w(f, { children: t }) })]
1579
1588
  });
1580
1589
  }
1581
- function ir({ column: n, description: r, help: i }) {
1582
- let a = D().t("columnHelp", { column: n.column.label });
1590
+ function sr({ column: e, description: t, help: i }) {
1591
+ let a = D().t("columnHelp", { column: e.column.label });
1583
1592
  return /* @__PURE__ */ T(te, {
1584
1593
  align: "start",
1585
1594
  side: "bottom",
1586
1595
  size: "sm",
1587
- children: [/* @__PURE__ */ w(ee, { render: (n) => /* @__PURE__ */ w("button", {
1588
- ...Me(n, "part", "column-help"),
1596
+ children: [/* @__PURE__ */ w(ee, { render: (e) => /* @__PURE__ */ w("button", {
1597
+ ...Me(e, "part", "column-help"),
1589
1598
  "aria-label": a,
1590
- onClick: (e) => {
1591
- e.stopPropagation(), n.onClick?.(e);
1599
+ onClick: (t) => {
1600
+ t.stopPropagation(), e.onClick?.(t);
1592
1601
  },
1593
1602
  onPointerDown: (e) => e.stopPropagation(),
1594
1603
  tabIndex: -1,
1595
1604
  type: "button",
1596
- children: /* @__PURE__ */ w(t, { children: /* @__PURE__ */ w(e, { name: "circle-question" }) })
1605
+ children: /* @__PURE__ */ w(r, { children: /* @__PURE__ */ w(n, { name: "circle-question" }) })
1597
1606
  }) }), /* @__PURE__ */ w(ne, { children: /* @__PURE__ */ w(_, {
1598
1607
  "aria-label": a,
1599
- children: /* @__PURE__ */ T(re, { children: [r ? /* @__PURE__ */ w("div", { children: r }) : null, i] })
1608
+ children: /* @__PURE__ */ T(re, { children: [t ? /* @__PURE__ */ w("div", { children: t }) : null, i] })
1600
1609
  }) })]
1601
1610
  });
1602
1611
  }
1603
- function ar({ column: n, filtered: r }) {
1604
- let i = D(), a = i.filterOpen === n.id;
1605
- return !r && !a ? null : /* @__PURE__ */ w("button", {
1612
+ function cr({ column: e, filtered: t }) {
1613
+ let i = D(), a = i.filterOpen === e.id;
1614
+ return !t && !a ? null : /* @__PURE__ */ w("button", {
1606
1615
  "aria-expanded": a,
1607
1616
  "aria-haspopup": "dialog",
1608
- "aria-label": i.t("filterColumn", { column: n.column.label }),
1617
+ "aria-label": i.t("filterColumn", { column: e.column.label }),
1609
1618
  "data-part": "filter",
1610
1619
  "data-part-filter": "",
1611
- onClick: (e) => {
1612
- e.stopPropagation(), i.setFilterOpen(a ? null : n.id);
1620
+ onClick: (t) => {
1621
+ t.stopPropagation(), i.setFilterOpen(a ? null : e.id);
1613
1622
  },
1614
1623
  onPointerDown: (e) => e.stopPropagation(),
1615
1624
  tabIndex: -1,
1616
1625
  type: "button",
1617
- ...r ? { "data-filtered": "" } : {},
1626
+ ...t ? { "data-filtered": "" } : {},
1618
1627
  ...a ? { "data-open": "" } : {},
1619
- children: /* @__PURE__ */ w(t, { children: /* @__PURE__ */ w(e, { name: "funnel" }) })
1628
+ children: /* @__PURE__ */ w(r, { children: /* @__PURE__ */ w(n, { name: "funnel" }) })
1620
1629
  });
1621
1630
  }
1622
- function or({ column: s, descriptionId: c, open: l }) {
1623
- let u = D(), d = u.t, f = u.sortOf(s.id), p = s.column.label, m = u.menuAnchor !== null && u.menuAnchor.column === s.id;
1624
- return /* @__PURE__ */ T(n, {
1631
+ function lr({ column: e, descriptionId: t, open: l }) {
1632
+ let u = D(), d = u.t, f = u.sortOf(e.id), p = e.column.label, m = u.menuAnchor !== null && u.menuAnchor.column === e.id;
1633
+ return /* @__PURE__ */ T(i, {
1625
1634
  anchor: m ? u.menuAnchor.anchor : null,
1626
1635
  finalFocus: m ? u.menuAnchor.returnTo : void 0,
1627
- onOpenChange: (e) => u.setMenuOpen(e ? s.id : null),
1636
+ onOpenChange: (t) => u.setMenuOpen(t ? e.id : null),
1628
1637
  open: l,
1629
- sideOffset: er,
1638
+ sideOffset: M,
1630
1639
  size: "sm",
1631
- children: [/* @__PURE__ */ w(a, { render: (n) => /* @__PURE__ */ w("button", {
1632
- ...Me(n, "part", "column-menu"),
1640
+ children: [/* @__PURE__ */ w(s, { render: (e) => /* @__PURE__ */ w("button", {
1641
+ ...Me(e, "part", "column-menu"),
1633
1642
  "aria-label": d("columnMenu", { column: p }),
1634
- onPointerDown: (e) => {
1635
- e.stopPropagation(), n.onPointerDown?.(e);
1643
+ onPointerDown: (t) => {
1644
+ t.stopPropagation(), e.onPointerDown?.(t);
1636
1645
  },
1637
- onClick: (e) => {
1638
- e.stopPropagation(), u.anchorToButton(), n.onClick?.(e);
1646
+ onClick: (t) => {
1647
+ t.stopPropagation(), u.anchorToButton(), e.onClick?.(t);
1639
1648
  },
1640
1649
  tabIndex: -1,
1641
1650
  type: "button",
1642
1651
  ...l ? { "data-open": "" } : {},
1643
- children: /* @__PURE__ */ w(t, { children: /* @__PURE__ */ w(e, { name: "ellipsis" }) })
1644
- }) }), /* @__PURE__ */ T(o, {
1645
- "aria-describedby": c,
1652
+ children: /* @__PURE__ */ w(r, { children: /* @__PURE__ */ w(n, { name: "ellipsis" }) })
1653
+ }) }), /* @__PURE__ */ T(c, {
1654
+ "aria-describedby": t,
1646
1655
  children: [
1647
- s.column.description ? /* @__PURE__ */ w("div", {
1656
+ e.column.description ? /* @__PURE__ */ w("div", {
1648
1657
  "aria-hidden": !0,
1649
1658
  "data-part": "column-menu-description",
1650
1659
  "data-part-column-menu-description": "",
1651
- children: s.column.description
1660
+ children: e.column.description
1652
1661
  }) : null,
1653
- s.sortable ? /* @__PURE__ */ T(He, { children: [
1654
- /* @__PURE__ */ w(r, {
1662
+ e.sortable ? /* @__PURE__ */ T(He, { children: [
1663
+ /* @__PURE__ */ w(a, {
1655
1664
  disabled: f?.direction === "ascending" && f.index === 1 && u.query.sort.length === 1,
1656
- onSelect: (e) => u.setSort(s.id, "ascending", e),
1665
+ onSelect: (t) => u.setSort(e.id, "ascending", t),
1657
1666
  children: d("sortAscendingAction")
1658
1667
  }),
1659
- /* @__PURE__ */ w(r, {
1668
+ /* @__PURE__ */ w(a, {
1660
1669
  disabled: f?.direction === "descending" && f.index === 1 && u.query.sort.length === 1,
1661
- onSelect: (e) => u.setSort(s.id, "descending", e),
1670
+ onSelect: (t) => u.setSort(e.id, "descending", t),
1662
1671
  children: d("sortDescendingAction")
1663
1672
  }),
1664
- /* @__PURE__ */ w(r, {
1673
+ /* @__PURE__ */ w(a, {
1665
1674
  disabled: f === null,
1666
- onSelect: (e) => u.setSort(s.id, null, e),
1675
+ onSelect: (t) => u.setSort(e.id, null, t),
1667
1676
  children: d("sortClearAction")
1668
1677
  }),
1669
- /* @__PURE__ */ w(i, {})
1678
+ /* @__PURE__ */ w(o, {})
1670
1679
  ] }) : null,
1671
- s.filterable ? /* @__PURE__ */ w(r, {
1672
- onSelect: () => u.setFilterOpen(s.id),
1680
+ e.filterable ? /* @__PURE__ */ w(a, {
1681
+ onSelect: () => u.setFilterOpen(e.id),
1673
1682
  children: d("filterMenu")
1674
1683
  }) : null,
1675
- /* @__PURE__ */ w(r, {
1676
- disabled: s.pinned === "start",
1677
- onSelect: (e) => u.pin(s.id, "start", e),
1684
+ /* @__PURE__ */ w(a, {
1685
+ disabled: e.pinned === "start",
1686
+ onSelect: (t) => u.pin(e.id, "start", t),
1678
1687
  children: d("pinStart")
1679
1688
  }),
1680
- /* @__PURE__ */ w(r, {
1681
- disabled: s.pinned === "end",
1682
- onSelect: (e) => u.pin(s.id, "end", e),
1689
+ /* @__PURE__ */ w(a, {
1690
+ disabled: e.pinned === "end",
1691
+ onSelect: (t) => u.pin(e.id, "end", t),
1683
1692
  children: d("pinEnd")
1684
1693
  }),
1685
- s.pinned ? /* @__PURE__ */ w(r, {
1686
- onSelect: (e) => u.pin(s.id, null, e),
1694
+ e.pinned ? /* @__PURE__ */ w(a, {
1695
+ onSelect: (t) => u.pin(e.id, null, t),
1687
1696
  children: d("unpin")
1688
1697
  }) : null,
1689
- /* @__PURE__ */ w(i, {}),
1690
- s.resizable ? /* @__PURE__ */ T(He, { children: [/* @__PURE__ */ w(r, {
1691
- onSelect: (e) => u.autofit(s.id, e.reason, e),
1698
+ /* @__PURE__ */ w(o, {}),
1699
+ e.resizable ? /* @__PURE__ */ T(He, { children: [/* @__PURE__ */ w(a, {
1700
+ onSelect: (t) => u.autofit(e.id, t.reason, t),
1692
1701
  children: d("autofit")
1693
- }), /* @__PURE__ */ w(r, {
1702
+ }), /* @__PURE__ */ w(a, {
1694
1703
  onSelect: (e) => u.autofit(null, e.reason, e),
1695
1704
  children: d("autofitAll")
1696
1705
  })] }) : null,
1697
- s.hideable ? /* @__PURE__ */ w(r, {
1698
- onSelect: (e) => u.hide(s.id, e, e.reason),
1706
+ e.hideable ? /* @__PURE__ */ w(a, {
1707
+ onSelect: (t) => u.hide(e.id, t, t.reason),
1699
1708
  children: d("hide")
1700
1709
  }) : null,
1701
- u.onManageColumns ? /* @__PURE__ */ w(r, {
1710
+ u.onManageColumns ? /* @__PURE__ */ w(a, {
1702
1711
  onSelect: () => u.onManageColumns?.(),
1703
1712
  children: d("manageColumns")
1704
1713
  }) : null
@@ -1706,35 +1715,41 @@ function or({ column: s, descriptionId: c, open: l }) {
1706
1715
  })]
1707
1716
  });
1708
1717
  }
1709
- function sr({ column: e }) {
1718
+ function ur({ column: e }) {
1710
1719
  let t = D(), [n, r] = C(null), i = S(n);
1711
- i.current = n, b(() => {
1720
+ i.current = n;
1721
+ let a = S(null), o = S(null);
1722
+ b(() => {
1712
1723
  if (!n) return;
1713
- let i = (i) => {
1714
- i.key === "Escape" && (i.preventDefault(), i.stopPropagation(), t.resizeTo(e.id, n.startWidth, "pointer"), r(null), t.setResizing(null));
1724
+ let e = (e) => {
1725
+ e.key === "Escape" && (e.preventDefault(), e.stopPropagation(), o.current = null, r(null), t.setResizing(null));
1715
1726
  };
1716
- return document.addEventListener("keydown", i, !0), () => document.removeEventListener("keydown", i, !0);
1727
+ return document.addEventListener("keydown", e, !0), () => document.removeEventListener("keydown", e, !0);
1717
1728
  }, [
1718
1729
  n,
1719
1730
  t,
1720
1731
  e.id
1721
1732
  ]);
1722
- let a = (n) => {
1733
+ let s = (n) => {
1723
1734
  if (n.button !== 0) return;
1724
1735
  n.preventDefault(), n.stopPropagation(), n.currentTarget.setPointerCapture(n.pointerId);
1725
- let i = getComputedStyle(n.currentTarget).direction === "rtl", a = n.currentTarget.closest("[data-part=\"column-header\"]");
1726
- r({
1736
+ let i = getComputedStyle(n.currentTarget).direction === "rtl", a = n.currentTarget.closest("[data-part=\"column-header\"]"), s = n.currentTarget.closest("[data-part=\"scroll\"]");
1737
+ o.current = null, r({
1727
1738
  startX: n.clientX,
1728
1739
  startWidth: a ? Math.round(a.getBoundingClientRect().width) : e.width,
1729
- rtl: i
1740
+ rtl: i,
1741
+ span: s?.clientHeight ?? 0
1730
1742
  }), t.setResizing(e.id);
1731
- }, o = (n) => {
1732
- let r = i.current;
1733
- if (!r) return;
1734
- let a = (n.clientX - r.startX) * (r.rtl ? -1 : 1);
1735
- t.resizeTo(e.id, r.startWidth + a, "pointer", n);
1736
- }, s = (e) => {
1737
- i.current && (e.currentTarget.releasePointerCapture(e.pointerId), r(null), t.setResizing(null));
1743
+ }, c = (t) => {
1744
+ let n = i.current;
1745
+ if (!n) return;
1746
+ let r = (t.clientX - n.startX) * (n.rtl ? -1 : 1), s = _t(e.column, n.startWidth + r);
1747
+ o.current = s, a.current?.style.setProperty("translate", `${String((s - n.startWidth) * (n.rtl ? -1 : 1))}px 0`);
1748
+ }, l = (n) => {
1749
+ if (!i.current) return;
1750
+ n.currentTarget.releasePointerCapture(n.pointerId);
1751
+ let a = o.current;
1752
+ o.current = null, r(null), t.setResizing(null), a !== null && n.type === "pointerup" && t.resizeTo(e.id, a, "pointer", n);
1738
1753
  };
1739
1754
  return /* @__PURE__ */ w("div", {
1740
1755
  "aria-hidden": !0,
@@ -1744,17 +1759,24 @@ function sr({ column: e }) {
1744
1759
  onDoubleClick: (n) => {
1745
1760
  n.stopPropagation(), t.autofit(n.shiftKey ? null : e.id, "pointer", n);
1746
1761
  },
1747
- onPointerCancel: s,
1748
- onPointerDown: a,
1749
- onPointerMove: o,
1750
- onPointerUp: s,
1762
+ onPointerCancel: l,
1763
+ onPointerDown: s,
1764
+ onPointerMove: c,
1765
+ onPointerUp: l,
1751
1766
  title: t.t("resize"),
1752
- ...n ? { "data-resizing": "" } : {}
1767
+ ...n ? { "data-resizing": "" } : {},
1768
+ children: n ? /* @__PURE__ */ w("div", {
1769
+ "aria-hidden": !0,
1770
+ "data-part": "resize-guide",
1771
+ "data-part-resize-guide": "",
1772
+ ref: a,
1773
+ style: { blockSize: n.span }
1774
+ }) : null
1753
1775
  });
1754
1776
  }
1755
1777
  //#endregion
1756
1778
  //#region src/data-grid/use-model.ts
1757
- function cr(e, t, n, r = Object.is) {
1779
+ function dr(e, t, n, r = Object.is) {
1758
1780
  let [i, a] = C(t), o = e === void 0 ? i : e, s = S({
1759
1781
  controlled: e,
1760
1782
  value: o,
@@ -1778,31 +1800,37 @@ function cr(e, t, n, r = Object.is) {
1778
1800
  }
1779
1801
  //#endregion
1780
1802
  //#region src/data-grid/data-grid.tsx
1781
- var lr = 34, ur = 100, dr = 20, fr = 600, pr = 400, mr = {
1803
+ var fr = 34, pr = 100, mr = 20, hr = 600, gr = 400, _r = {
1782
1804
  popin: [],
1783
1805
  hidden: []
1784
- }, hr = "input, textarea, select, [contenteditable]:not([contenteditable=\"false\"])", gr = 300, _r = 500;
1785
- function vr(e, t) {
1806
+ }, vr = "input, textarea, select, [contenteditable]:not([contenteditable=\"false\"])", yr = 300, br = 500;
1807
+ function xr(e) {
1808
+ let t = S(e);
1809
+ t.current = e;
1810
+ let n = e !== void 0;
1811
+ return x(() => n ? (...e) => t.current(...e) : void 0, [n]);
1812
+ }
1813
+ function Sr(e, t) {
1786
1814
  let n = new DOMRect(e, t, 0, 0);
1787
1815
  return { getBoundingClientRect: () => n };
1788
1816
  }
1789
- function yr(e, t) {
1817
+ function Cr(e, t) {
1790
1818
  return JSON.stringify(e) === JSON.stringify(t);
1791
1819
  }
1792
- function br(e, t) {
1820
+ function wr(e, t) {
1793
1821
  return JSON.stringify(e) === JSON.stringify(t);
1794
1822
  }
1795
- function xr(e, t) {
1823
+ function Tr(e, t) {
1796
1824
  return e === "all" || t === "all" ? e === t : e.length === t.length && e.every((e, n) => e === t[n]);
1797
1825
  }
1798
- function Sr(e, t) {
1826
+ function Er(e, t) {
1799
1827
  return !e || !t ? e === t : E(e.anchor, t.anchor) && E(e.focus, t.focus);
1800
1828
  }
1801
- function Cr(e, t) {
1802
- return Array.isArray(e) && Array.isArray(t) ? xr(e, t) : e === t;
1829
+ function Dr(e, t) {
1830
+ return Array.isArray(e) && Array.isArray(t) ? Tr(e, t) : e === t;
1803
1831
  }
1804
- var wr = [];
1805
- function Tr(e) {
1832
+ var Or = [];
1833
+ function kr(e) {
1806
1834
  let t = getComputedStyle(e), n = e.offsetWidth - e.clientWidth + parseFloat(t.paddingInlineStart) + parseFloat(t.paddingInlineEnd), r = parseFloat(t.columnGap) || 0, i = 0, a = 0;
1807
1835
  for (let t of e.children) if (t instanceof HTMLElement && getComputedStyle(t).display !== "none" && t.dataset.part !== "column-description") {
1808
1836
  if (a += 1, a === 1 && t.dataset.ui === void 0) {
@@ -1812,69 +1840,87 @@ function Tr(e) {
1812
1840
  }
1813
1841
  return i + Math.max(0, a - 1) * r + n;
1814
1842
  }
1815
- function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow: r, dataSource: i, columnState: a, columns: o, current: u, density: d, defaultColumnState: f, defaultCurrent: p, defaultExpanded: m, defaultExpandedGroups: h, defaultQuery: g, defaultRange: _, defaultValue: ee, disabledKeys: te, editMode: ne, editorRenderers: re, error: ie, expandable: v, expanded: ue, expandedGroups: de, filterDebounce: fe, filterRow: pe, footer: me, handle: he, hasMore: ge, height: _e, highlightChanges: ve, labelledBy: ye, loadMoreThreshold: be, loadMoreTrigger: xe, loadMoreFailed: Se, loading: Ce, locale: we, messages: Te, mode: Ee, onActivate: De, onColumnStateChange: Oe, onCurrentChange: ke, onEditCancel: Ae, onEditCommit: je, onEditStart: Me, onExpandedChange: Ne, onExpandedGroupsChange: Pe, onLoadChildren: Fe, onRowsReorder: Ie, onKeyDown: Le, onLoadMore: Ve, onManageColumns: He, onOutOfSpaceChange: Je, onQueryChange: Ye, onRangeChange: Xe, onRetry: Ze, onValueChange: Qe, overscan: $e, pinnedRows: et, pageSizes: tt, query: nt, range: bt, ref: Et, renderCell: Pt, renderDetail: Ft, renderEditor: Yt, renderEmpty: Xt, renderFilterOperand: Zt, renderGroup: Qt, renderHeader: $t, rowHeight: en, rowKey: tn, rowsReorderable: nn, rows: an, selectionMode: on, showRange: sn, skeletonRows: pn, stickyHeader: mn, stickyTo: D, striped: vn, style: yn, timeZone: xn, totalCount: Sn, tree: O, value: wn, variant: On, virtualize: kn, ...An }) {
1816
- let k = Ln(), jn = Re(), A = S(null), Mn = S(null), j = c(We, Te), Fn = c(Ge), In = s(), Rn = On ?? k.variant ?? "ruled", zn = vn ?? k.striped ?? !1, Hn = mn ?? k.stickyHeader ?? !0, Un = D ?? k.stickyTo ?? "scroll", M = on ?? k.selectionMode ?? "none", Gn = ne ?? k.editMode ?? "cell", Kn = pe ?? k.filterRow ?? !1, qn = kn ?? k.virtualize ?? "auto", Jn = en ?? k.rowHeight, Yn = r ?? k.columnOverflow ?? "auto", Xn = $e ?? k.overscan ?? 6, Zn = fe ?? k.filterDebounce ?? 300, Qn = be ?? k.loadMoreThreshold ?? 20, $n = xe ?? k.loadMoreTrigger ?? "scroll", er = pn ?? k.skeletonRows ?? 8, N = we ?? In, nr = e ?? !1, P = y((e) => typeof tn == "function" ? tn(e) : String(e[tn]), [tn]), rr = j("filterYes"), ir = j("filterNo"), ar = x(() => ({
1843
+ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow: a, dataSource: o, columnState: s, columns: c, current: u, density: d, defaultColumnState: f, defaultCurrent: p, defaultExpanded: m, defaultExpandedGroups: h, defaultQuery: g, defaultRange: _, defaultValue: ee, disabledKeys: te, editMode: ne, editorRenderers: re, error: ie, expandable: v, expanded: ue, expandedGroups: de, filterDebounce: fe, filterRow: pe, footer: me, handle: he, hasMore: ge, height: _e, highlightChanges: ve, labelledBy: ye, loadMoreThreshold: be, loadMoreTrigger: xe, loadMoreFailed: Se, loading: Ce, locale: we, messages: Te, mode: Ee, onActivate: De, onColumnStateChange: Oe, onCurrentChange: ke, onEditCancel: Ae, onEditCommit: je, onEditStart: Me, onExpandedChange: Ne, onExpandedGroupsChange: Pe, onLoadChildren: Fe, onRowsReorder: Ie, onKeyDown: Le, onLoadMore: Ve, onManageColumns: He, onOutOfSpaceChange: Je, onQueryChange: Ye, onRangeChange: Xe, onRetry: Ze, onValueChange: Qe, overscan: $e, pinnedRows: et, pageSizes: tt, query: nt, range: _t, ref: xt, renderCell: Dt, renderDetail: Ft, renderEditor: It, renderEmpty: Xt, renderFilterOperand: Zt, renderGroup: Qt, renderHeader: $t, rowHeight: en, rowKey: tn, rowsReorderable: nn, rows: rn, selectionMode: on, showRange: sn, skeletonRows: cn, stickyHeader: mn, stickyTo: hn, striped: D, style: yn, timeZone: bn, totalCount: Sn, tree: Cn, value: wn, variant: En, virtualize: An, ...jn }) {
1844
+ let O = Bn(), Mn = Re(), k = S(null), Nn = S(null), Pn = S({
1845
+ cellRenderers: r,
1846
+ editorRenderers: re,
1847
+ tree: Cn
1848
+ });
1849
+ Pn.current = {
1850
+ cellRenderers: r,
1851
+ editorRenderers: re,
1852
+ tree: Cn
1853
+ };
1854
+ let Fn = xr(Dt), Rn = xr(Ft), zn = xr(It), Vn = xr(Qt), Hn = xr($t), Gn = r ? Object.keys(r).join() : null, Kn = re ? Object.keys(re).join() : null, qn = Cn?.column, Yn = Cn?.hasChildren !== void 0, A = x(() => Cn === void 0 ? void 0 : {
1855
+ column: qn,
1856
+ parentKey: (e) => Pn.current.tree.parentKey(e),
1857
+ hasChildren: Yn ? (e) => Pn.current.tree.hasChildren?.(e) === !0 : void 0
1858
+ }, [
1859
+ Cn === void 0,
1860
+ qn,
1861
+ Yn
1862
+ ]), j = t(We, Te), Xn = t(Ge), Zn = e(), Qn = En ?? O.variant ?? "ruled", $n = D ?? O.striped ?? !1, er = mn ?? O.stickyHeader ?? !0, tr = hn ?? O.stickyTo ?? "scroll", M = on ?? O.selectionMode ?? "none", rr = ne ?? O.editMode ?? "cell", ir = pe ?? O.filterRow ?? !1, ar = An ?? O.virtualize ?? "auto", or = en ?? O.rowHeight, sr = a ?? O.columnOverflow ?? "auto", cr = $e ?? O.overscan ?? 6, lr = fe ?? O.filterDebounce ?? 300, ur = be ?? O.loadMoreThreshold ?? 20, Ar = xe ?? O.loadMoreTrigger ?? "scroll", Nr = cn ?? O.skeletonRows ?? 8, N = we ?? Zn, Pr = n ?? !1, P = y((e) => typeof tn == "function" ? tn(e) : String(e[tn]), [tn]), Fr = j("filterYes"), Ir = j("filterNo"), Lr = x(() => ({
1817
1863
  locale: N,
1818
- timeZone: xn,
1864
+ timeZone: bn,
1819
1865
  booleans: {
1820
- true: rr,
1821
- false: ir
1866
+ true: Fr,
1867
+ false: Ir
1822
1868
  }
1823
1869
  }), [
1824
1870
  N,
1825
- xn,
1826
- rr,
1827
- ir
1828
- ]), or = y((e, t) => ht(e, t, ar), [ar]), sr = x(() => new Set(te ?? []), [te]), Er = y((e) => sr.has(e), [sr]), F = y((e, t) => {
1829
- if (sr.has(P(t))) return !1;
1871
+ bn,
1872
+ Fr,
1873
+ Ir
1874
+ ]), Rr = y((e, t) => ht(e, t, Lr), [Lr]), zr = x(() => new Set(te ?? []), [te]), Br = y((e) => zr.has(e), [zr]), F = y((e, t) => {
1875
+ if (zr.has(P(t))) return !1;
1830
1876
  let n = e.editable;
1831
1877
  return typeof n == "function" ? n(t) : n === !0;
1832
- }, [sr, P]), kr = x(() => o.some((e) => e.editable), [o]), Ar = y((e) => Ft ? v === void 0 ? !0 : typeof v == "function" ? v(e) : v : !1, [v, Ft]), [I, jr] = cr(nt, g ?? xt(), Ye, yr), Mr = Bn(i, I), L = i ? Mr.rows : an ?? wr, Nr = i ? Mr.total : Sn, Pr = i ? Mr.hasMore : ge, Fr = i ? Mr.loading : Ce, Ir = Fr !== void 0 && Fr !== !1, Lr = i ? Mr.error : ie, Rr = i ? Mr.retry : Ze, zr = Ee ?? (i || Nr !== void 0 || Pr !== void 0 ? "server" : "client"), Br = x(() => Tt(a ?? f, o), [a, o]), [Vr, Hr] = cr(a === void 0 ? void 0 : Br, Br, Oe, br), R = x(() => Tt(Vr, o), [Vr, o]), [Ur, Wr] = cr(wn, ee ?? (M === "multiple" ? [] : null), Qe, Cr), [Gr, Kr] = cr(bt, _ ?? null, Xe, Sr), [z, qr] = cr(u, p ?? null, ke, E), [Jr, Yr] = cr(ue, m ?? [], Ne, xr), [Xr, Zr] = cr(de, h ?? "all", Pe, xr), Qr = M === "single" || M === "multiple", $r = nn === !0, ei = Ft !== void 0, ti = x(() => {
1878
+ }, [zr, P]), Vr = x(() => c.some((e) => e.editable), [c]), Hr = y((e) => Rn ? v === void 0 ? !0 : typeof v == "function" ? v(e) : v : !1, [v, Rn]), [I, Ur] = dr(nt, g ?? St(), Ye, Cr), Wr = Un(o, I), L = o ? Wr.rows : rn ?? Or, Gr = o ? Wr.total : Sn, Kr = o ? Wr.hasMore : ge, qr = o ? Wr.loading : Ce, Jr = qr !== void 0 && qr !== !1, Yr = o ? Wr.error : ie, Xr = o ? Wr.retry : Ze, Zr = Ee ?? (o || Gr !== void 0 || Kr !== void 0 ? "server" : "client"), Qr = x(() => Et(s ?? f, c), [s, c]), [$r, ei] = dr(s === void 0 ? void 0 : Qr, Qr, Oe, wr), R = x(() => Et($r, c), [$r, c]), [ti, ni] = dr(wn, ee ?? (M === "multiple" ? [] : null), Qe, Dr), [ri, ii] = dr(_t, _ ?? null, Xe, Er), [z, ai] = dr(u, p ?? null, ke, E), [oi, si] = dr(ue, m ?? [], Ne, Tr), [ci, li] = dr(de, h ?? "all", Pe, Tr), ui = M === "single" || M === "multiple", di = nn === !0, fi = Rn !== void 0, pi = x(() => {
1833
1879
  let e = [];
1834
- return Qr && e.push(48), $r && e.push(40), ei && e.push(40), e;
1880
+ return ui && e.push(48), di && e.push(40), fi && e.push(40), e;
1835
1881
  }, [
1836
- Qr,
1837
- $r,
1838
- ei
1839
- ]), ni = ti.reduce((e, t) => e + t, 0), ri = x(() => Mt(o, R, { leading: ni }), [
1840
- o,
1882
+ ui,
1883
+ di,
1884
+ fi
1885
+ ]), mi = pi.reduce((e, t) => e + t, 0), hi = x(() => Nt(c, R, { leading: mi }), [
1886
+ c,
1841
1887
  R,
1842
- ni
1843
- ]), [ii, ai] = C(0), [oi, si] = C(!1);
1888
+ mi
1889
+ ]), [gi, _i] = C(0), [vi, yi] = C(!1);
1844
1890
  b(() => {
1845
1891
  if (typeof window > "u" || typeof window.matchMedia != "function") return;
1846
- let e = window.matchMedia("(pointer: coarse)"), t = () => si(e.matches);
1892
+ let e = window.matchMedia("(pointer: coarse)"), t = () => yi(e.matches);
1847
1893
  return t(), e.addEventListener("change", t), () => e.removeEventListener("change", t);
1848
1894
  }, []);
1849
- let ci = ii <= 0 || jt(Yn, ii, oi) === "scroll" ? mr : yt(ri, ii, { leading: ni }), li = `${ci.popin.join("\0")}\u0001${ci.hidden.join("\0")}`, B = x(() => ci, [li]), V = x(() => B.popin.length === 0 && B.hidden.length === 0 ? ri : Mt(o, {
1895
+ let bi = gi <= 0 || Mt(sr, gi, vi) === "scroll" ? _r : bt(hi, gi, { leading: mi }), xi = `${bi.popin.join("\0")}\u0001${bi.hidden.join("\0")}`, B = x(() => bi, [xi]), V = x(() => B.popin.length === 0 && B.hidden.length === 0 ? hi : Nt(c, {
1850
1896
  ...R,
1851
1897
  hidden: [
1852
1898
  ...R.hidden,
1853
1899
  ...B.popin,
1854
1900
  ...B.hidden
1855
1901
  ]
1856
- }, { leading: ni }), [
1857
- ri,
1902
+ }, { leading: mi }), [
1903
+ hi,
1858
1904
  B,
1859
- o,
1905
+ c,
1860
1906
  R,
1861
- ni
1862
- ]), ui = x(() => B.popin.length === 0 ? [] : ri.filter((e) => B.popin.includes(e.id)), [ri, B]), di = ui.length > 0, fi = S(mr);
1907
+ mi
1908
+ ]), Si = x(() => B.popin.length === 0 ? [] : hi.filter((e) => B.popin.includes(e.id)), [hi, B]), Ci = Si.length > 0, wi = S(_r);
1863
1909
  b(() => {
1864
- let e = fi.current;
1865
- xr(B.popin, e.popin) && xr(B.hidden, e.hidden) || (fi.current = B, Je?.(B));
1910
+ let e = wi.current;
1911
+ Tr(B.popin, e.popin) && Tr(B.hidden, e.hidden) || (wi.current = B, Je?.(B));
1866
1912
  }, [B, Je]);
1867
1913
  let H = x(() => new Map(V.map((e) => [e.id, e])), [V]), U = x(() => [
1868
- ...Qr ? [ln] : [],
1869
- ...$r ? [dn] : [],
1870
- ...ei ? [un] : [],
1914
+ ...ui ? [un] : [],
1915
+ ...di ? [fn] : [],
1916
+ ...fi ? [dn] : [],
1871
1917
  ...V.map((e) => e.id)
1872
1918
  ], [
1873
- Qr,
1874
- $r,
1875
- ei,
1919
+ ui,
1920
+ di,
1921
+ fi,
1876
1922
  V
1877
- ]), pi = U.length + +!!di, mi = U.length + 1, hi = x(() => di ? [...U, dt] : U, [di, U]), gi = x(() => vt(V, ti), [V, ti]), W = x(() => {
1923
+ ]), Ti = U.length + +!!Ci, Ei = U.length + 1, Di = x(() => Ci ? [...U, dt] : U, [Ci, U]), Oi = x(() => yt(V, pi), [V, pi]), W = x(() => {
1878
1924
  let e = et?.top ?? [], t = et?.bottom ?? [];
1879
1925
  if (e.length === 0 && t.length === 0) return {
1880
1926
  top: [],
@@ -1906,80 +1952,80 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
1906
1952
  et,
1907
1953
  L,
1908
1954
  P
1909
- ]), _i = x(() => W.keys ? L.filter((e) => !W.keys.has(P(e))) : L, [
1955
+ ]), ki = x(() => W.keys ? L.filter((e) => !W.keys.has(P(e))) : L, [
1910
1956
  L,
1911
1957
  W.keys,
1912
1958
  P
1913
- ]), vi = x(() => {
1914
- let e = _i;
1915
- if (zr === "server") return {
1916
- nodes: St(e, o, I.group, {
1959
+ ]), Ai = x(() => {
1960
+ let e = ki;
1961
+ if (Zr === "server") return {
1962
+ nodes: Ct(e, c, I.group, {
1917
1963
  rowKey: P,
1918
- expandedGroups: Xr,
1964
+ expandedGroups: ci,
1919
1965
  offset: I.page && "index" in I.page ? I.page.index * I.page.size : 0,
1920
1966
  locale: N,
1921
- timeZone: xn,
1922
- booleans: ar.booleans
1967
+ timeZone: bn,
1968
+ booleans: Lr.booleans
1923
1969
  }),
1924
1970
  rows: e,
1925
- total: Nr ?? null,
1926
- hasMore: Pr ?? !1,
1971
+ total: Gr ?? null,
1972
+ hasMore: Kr ?? !1,
1927
1973
  aggregates: {}
1928
1974
  };
1929
- let t = mt(e, o, I, {
1975
+ let t = mt(e, c, I, {
1930
1976
  rowKey: P,
1931
- expandedGroups: Xr,
1932
- tree: O,
1933
- expanded: O ? Jr : void 0,
1977
+ expandedGroups: ci,
1978
+ tree: A,
1979
+ expanded: A ? oi : void 0,
1934
1980
  locale: N,
1935
- timeZone: xn,
1936
- booleans: ar.booleans
1981
+ timeZone: bn,
1982
+ booleans: Lr.booleans
1937
1983
  });
1938
1984
  return {
1939
1985
  ...t,
1940
1986
  total: t.total
1941
1987
  };
1942
1988
  }, [
1943
- zr,
1944
- _i,
1945
- o,
1989
+ Zr,
1990
+ ki,
1991
+ c,
1946
1992
  I,
1947
1993
  P,
1948
- Xr,
1949
- O,
1950
- Jr,
1994
+ ci,
1995
+ A,
1996
+ oi,
1951
1997
  N,
1952
- xn,
1953
- ar.booleans,
1954
- Nr,
1955
- Pr
1956
- ]), G = vi.nodes, yi = vi.total, bi = x(() => ui.filter((e) => e.column.aggregate !== void 0), [ui]), xi = (V.some((e) => e.column.aggregate !== void 0) || bi.length > 0) && zr === "client", Si = y((e) => di ? e === pt ? bi.length > 0 : Or(e) : !1, [di, bi]), Ci = y((e) => e.column !== dt || Si(e.row) ? e : {
1998
+ bn,
1999
+ Lr.booleans,
2000
+ Gr,
2001
+ Kr
2002
+ ]), G = Ai.nodes, ji = Ai.total, Mi = x(() => Si.filter((e) => e.column.aggregate !== void 0), [Si]), Ni = (V.some((e) => e.column.aggregate !== void 0) || Mi.length > 0) && Zr === "client", Pi = y((e) => Ci ? e === pt ? Mi.length > 0 : Mr(e) : !1, [Ci, Mi]), Fi = y((e) => e.column !== dt || Pi(e.row) ? e : {
1957
2003
  row: e.row,
1958
2004
  column: U[U.length - 1]
1959
- }, [Si, U]), wi = 1 + (n && n.length > 0 ? 1 : 0) + +!!Kn, Ti = x(() => {
2005
+ }, [Pi, U]), Ii = 1 + (i && i.length > 0 ? 1 : 0) + +!!ir, Li = x(() => {
1960
2006
  let e = [ut];
1961
- Kn && e.push(ct);
2007
+ ir && e.push(ct);
1962
2008
  for (let t of W.top) e.push(t.key);
1963
2009
  for (let t of G) e.push(t.kind === "group" ? `${lt}${t.key}` : t.key);
1964
2010
  for (let t of W.bottom) e.push(t.key);
1965
- return xi && e.push(pt), e;
2011
+ return Ni && e.push(pt), e;
1966
2012
  }, [
1967
2013
  G,
1968
2014
  W,
1969
- Kn,
1970
- xi
1971
- ]), Ei = 1 + +!!Kn, Di = Ei + W.top.length + G.length + W.bottom.length, [Oi, ki] = C(0), [Ai, ji] = C(0), [K, Mi] = C({
2015
+ ir,
2016
+ Ni
2017
+ ]), Ri = 1 + +!!ir, zi = Ri + W.top.length + G.length + W.bottom.length, [Bi, Vi] = C(0), [Hi, Ui] = C(0), [K, Wi] = C({
1972
2018
  width: 0,
1973
2019
  height: 0
1974
- }), [Ni, Pi] = C(null), [Fi, Ii] = C(/* @__PURE__ */ new Map()), Li = Jn === "auto" || di, q = typeof Jn == "number" ? Jn : Ni ?? lr, Ri = qn === !0 || qn === "auto" && G.length > ur, zi = x(() => {
1975
- if (Li) return rt(G.map((e, t) => Fi.get(t) ?? q));
2020
+ }), [Gi, Ki] = C(null), [qi, Ji] = C(/* @__PURE__ */ new Map()), Yi = or === "auto" || Ci, q = typeof or == "number" ? or : Gi ?? fr, Xi = ar === !0 || ar === "auto" && G.length > pr, Zi = x(() => {
2021
+ if (Yi) return rt(G.map((e, t) => qi.get(t) ?? q));
1976
2022
  }, [
1977
- Li,
2023
+ Yi,
1978
2024
  G,
1979
- Fi,
2025
+ qi,
1980
2026
  q
1981
- ]), Bi = x(() => {
1982
- if (!Ri) return {
2027
+ ]), Qi = x(() => {
2028
+ if (!Xi) return {
1983
2029
  startIndex: 0,
1984
2030
  endIndex: G.length,
1985
2031
  startOffset: 0,
@@ -1988,10 +2034,10 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
1988
2034
  let e = at({
1989
2035
  itemCount: G.length,
1990
2036
  itemSize: q,
1991
- metrics: zi,
1992
- overscan: Xn,
1993
- scrollOffset: Math.max(0, Oi),
1994
- viewportSize: K.height || fr
2037
+ metrics: Zi,
2038
+ overscan: cr,
2039
+ scrollOffset: Math.max(0, Bi),
2040
+ viewportSize: K.height || hr
1995
2041
  });
1996
2042
  return {
1997
2043
  startIndex: e.startIndex,
@@ -2000,224 +2046,224 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2000
2046
  totalSize: e.totalSize
2001
2047
  };
2002
2048
  }, [
2003
- Ri,
2049
+ Xi,
2004
2050
  K.height,
2005
2051
  G.length,
2006
2052
  q,
2007
- zi,
2008
- Xn,
2009
- Oi
2010
- ]), Vi = x(() => Ri ? G.slice(Bi.startIndex, Bi.endIndex) : G, [
2011
- Ri,
2053
+ Zi,
2054
+ cr,
2055
+ Bi
2056
+ ]), $i = x(() => Xi ? G.slice(Qi.startIndex, Qi.endIndex) : G, [
2057
+ Xi,
2012
2058
  G,
2013
- Bi.startIndex,
2014
- Bi.endIndex
2015
- ]), [Hi, Ui] = C([]), Wi = x(() => V.filter((e) => e.pinned === null), [V]), Gi = qn === !0 || qn === "auto" && Wi.length > dr, Ki = x(() => {
2016
- if (!Gi || K.width === 0) return V;
2017
- let e = ti.reduce((e, t) => e + t, 0), t = V.filter((e) => e.pinned === "start").reduce((e, t) => e + t.width, 0), n = V.filter((e) => e.pinned === "end").reduce((e, t) => e + t.width, 0), r = Ai - pr, i = Ai + K.width - n + pr, a = e + t, o = /* @__PURE__ */ new Set();
2018
- for (let e of Wi) {
2059
+ Qi.startIndex,
2060
+ Qi.endIndex
2061
+ ]), [ea, ta] = C([]), na = x(() => V.filter((e) => e.pinned === null), [V]), ra = ar === !0 || ar === "auto" && na.length > mr, ia = x(() => {
2062
+ if (!ra || K.width === 0) return V;
2063
+ let e = pi.reduce((e, t) => e + t, 0), t = V.filter((e) => e.pinned === "start").reduce((e, t) => e + t.width, 0), n = V.filter((e) => e.pinned === "end").reduce((e, t) => e + t.width, 0), r = Hi - gr, i = Hi + K.width - n + gr, a = e + t, o = /* @__PURE__ */ new Set();
2064
+ for (let e of na) {
2019
2065
  let t = a + e.width;
2020
2066
  t >= r && a <= i && o.add(e.id), a = t;
2021
2067
  }
2022
2068
  return V.filter((e) => e.pinned !== null || o.has(e.id) || z !== null && z.column === e.id);
2023
2069
  }, [
2024
- Gi,
2070
+ ra,
2025
2071
  K.width,
2026
2072
  V,
2027
- ti,
2028
- Ai,
2029
- Wi,
2073
+ pi,
2074
+ Hi,
2075
+ na,
2030
2076
  z
2031
2077
  ]), J = x(() => {
2032
- let e = zr === "client" ? vi.rows : _i;
2078
+ let e = Zr === "client" ? Ai.rows : ki;
2033
2079
  return [
2034
2080
  ...W.top.map((e) => e.key),
2035
2081
  ...e.map(P),
2036
2082
  ...W.bottom.map((e) => e.key)
2037
- ].filter((e) => !sr.has(e));
2083
+ ].filter((e) => !zr.has(e));
2038
2084
  }, [
2039
- zr,
2040
- vi.rows,
2041
- _i,
2085
+ Zr,
2086
+ Ai.rows,
2087
+ ki,
2042
2088
  W,
2043
2089
  P,
2044
- sr
2045
- ]), qi = x(() => Array.isArray(Ur) ? Ur : Ur == null ? [] : [Ur], [Ur]), Ji = x(() => new Set(qi), [qi]), Yi = S(void 0), Xi = y((e) => Ji.has(e), [Ji]), Zi = x(() => new Set(J), [J]), Qi = x(() => qi.filter((e) => Zi.has(e)).length, [qi, Zi]), $i = Qi === 0 ? "none" : Qi >= J.length ? "all" : "some", ea = y((e, t, n) => {
2090
+ zr
2091
+ ]), aa = x(() => Array.isArray(ti) ? ti : ti == null ? [] : [ti], [ti]), oa = x(() => new Set(aa), [aa]), sa = S(void 0), ca = y((e) => oa.has(e), [oa]), la = x(() => new Set(J), [J]), ua = x(() => aa.filter((e) => la.has(e)).length, [aa, la]), da = ua === 0 ? "none" : ua >= J.length ? "all" : "some", fa = y((e, t, n) => {
2046
2092
  let r = M === "multiple" ? e : e[0] ?? null;
2047
- Wr(r, t, n);
2048
- }, [M, Wr]), ta = y((e, t) => {
2049
- if (M === "none" || M === "range" || sr.has(e)) return;
2093
+ ni(r, t, n);
2094
+ }, [M, ni]), pa = y((e, t) => {
2095
+ if (M === "none" || M === "range" || zr.has(e)) return;
2050
2096
  let n = it({
2051
2097
  action: t.range ? "range" : "toggle",
2052
2098
  mode: M,
2053
- selected: qi,
2099
+ selected: aa,
2054
2100
  keys: J,
2055
2101
  key: e,
2056
- anchor: Yi.current,
2057
- disabled: (e) => sr.has(e)
2102
+ anchor: sa.current,
2103
+ disabled: (e) => zr.has(e)
2058
2104
  });
2059
- t.range || (Yi.current = e), n.changed && ea(n.selected, t.reason ?? "pointer", t.source);
2105
+ t.range || (sa.current = e), n.changed && fa(n.selected, t.reason ?? "pointer", t.source);
2060
2106
  }, [
2061
2107
  M,
2062
- sr,
2063
- qi,
2108
+ zr,
2109
+ aa,
2064
2110
  J,
2065
- ea
2066
- ]), na = y((e) => {
2111
+ fa
2112
+ ]), ma = y((e) => {
2067
2113
  if (M !== "multiple") return;
2068
2114
  let t = it({
2069
2115
  action: "all",
2070
2116
  mode: "multiple",
2071
- selected: qi,
2117
+ selected: aa,
2072
2118
  keys: J
2073
2119
  });
2074
- t.changed && ea(t.selected, "select", e);
2120
+ t.changed && fa(t.selected, "select", e);
2075
2121
  }, [
2076
2122
  M,
2077
- qi,
2123
+ aa,
2078
2124
  J,
2079
- ea
2080
- ]), ra = Math.max(1, Math.floor((K.height || 400) / q) - 1), Y = x(() => ({
2081
- rows: Ti,
2082
- columns: hi,
2083
- pageSize: ra,
2084
- bodyStart: Ei,
2085
- bodyEnd: Di
2125
+ fa
2126
+ ]), ha = Math.max(1, Math.floor((K.height || 400) / q) - 1), Y = x(() => ({
2127
+ rows: Li,
2128
+ columns: Di,
2129
+ pageSize: ha,
2130
+ bodyStart: Ri,
2131
+ bodyEnd: zi
2086
2132
  }), [
2087
- Ti,
2088
- hi,
2089
- ra,
2090
- Ei,
2091
- Di
2092
- ]), X = x(() => M === "range" ? Dt(Y, Gr) : null, [
2133
+ Li,
2134
+ Di,
2135
+ ha,
2136
+ Ri,
2137
+ zi
2138
+ ]), X = x(() => M === "range" ? Ot(Y, ri) : null, [
2093
2139
  M,
2094
2140
  Y,
2095
- Gr
2096
- ]), ia = y((e) => kt(Y, X, e), [Y, X]), [aa, oa] = C(!1), sa = S(null), ca = y((e, t, n) => {
2097
- if (M !== "range" || !Or(e.row)) return;
2098
- let r = t && Gr ? Gr.anchor : e;
2099
- sa.current = r, Kr({
2141
+ ri
2142
+ ]), ga = y((e) => At(Y, X, e), [Y, X]), [_a, va] = C(!1), ya = S(null), ba = y((e, t, n) => {
2143
+ if (M !== "range" || !Mr(e.row)) return;
2144
+ let r = t && ri ? ri.anchor : e;
2145
+ ya.current = r, ii({
2100
2146
  anchor: r,
2101
2147
  focus: e
2102
2148
  }, "pointer", n);
2103
2149
  }, [
2104
2150
  M,
2105
- Gr,
2106
- Kr
2107
- ]), la = y((e, t) => {
2108
- if (M !== "range" || !Or(e.row)) return;
2109
- let n = sa.current ?? Gr?.anchor ?? e;
2110
- Kr({
2151
+ ri,
2152
+ ii
2153
+ ]), xa = y((e, t) => {
2154
+ if (M !== "range" || !Mr(e.row)) return;
2155
+ let n = ya.current ?? ri?.anchor ?? e;
2156
+ ii({
2111
2157
  anchor: n,
2112
2158
  focus: e
2113
2159
  }, "pointer", t);
2114
2160
  }, [
2115
2161
  M,
2116
- Gr,
2117
- Kr
2162
+ ri,
2163
+ ii
2118
2164
  ]), Z = y((e) => {
2119
- qe(A.current?.ownerDocument).announce(e);
2120
- }, []), [ua, da] = C(!1), fa = S(null), pa = y((e) => {
2121
- let t = A.current?.querySelector(`[data-row="${CSS.escape(e.row)}"] [data-column="${CSS.escape(e.column)}"]`);
2165
+ qe(k.current?.ownerDocument).announce(e);
2166
+ }, []), [Sa, Ca] = C(!1), wa = S(null), Ta = y((e) => {
2167
+ let t = k.current?.querySelector(`[data-row="${CSS.escape(e.row)}"] [data-column="${CSS.escape(e.column)}"]`);
2122
2168
  if (!t) return !1;
2123
2169
  let n = t.matches("[data-part=\"column-header\"], [data-part=\"filter-cell\"]") || t.querySelector("[data-part=\"group-toggle\"]") !== null, r = t.querySelector("[data-part=\"editor\"]");
2124
2170
  if (r) return (r.querySelector("input:not([type=\"checkbox\"]):not([type=\"radio\"]):not([disabled]), textarea:not([disabled]), [role=\"combobox\"]:not([disabled]), [role=\"spinbutton\"]:not([disabled]), [role=\"checkbox\"], [role=\"switch\"]") ?? r.querySelector("a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex=\"-1\"]), [contenteditable=\"true\"]") ?? t).focus({ preventScroll: !1 }), !0;
2125
- let i = n ? [] : [...t.querySelectorAll(fn)];
2171
+ let i = n ? [] : [...t.querySelectorAll(pn)];
2126
2172
  return ((i.length === 1 && i[0].matches("a[href], button, input[type=\"checkbox\"], input[type=\"radio\"], [role=\"switch\"], [role=\"button\"], [role=\"checkbox\"]") ? i[0] : null) ?? t).focus({ preventScroll: !1 }), !0;
2127
- }, []), ma = y((e, t, n) => {
2128
- if (E(e, z) || qr(e, t, n), fa.current = e, Or(e.row) && !Ti.includes(e.row)) return;
2129
- let r = Ti.indexOf(e.row) - Ei;
2130
- if (Ri && r >= 0 && (r < Bi.startIndex || r >= Bi.endIndex)) {
2131
- Ui([e.row]);
2132
- let t = zi ? zi.offsetOf(r) : r * q;
2133
- Mn.current?.scrollTo({ top: t - K.height / 2 + q });
2173
+ }, []), Ea = y((e, t, n) => {
2174
+ if (E(e, z) || ai(e, t, n), wa.current = e, Mr(e.row) && !Li.includes(e.row)) return;
2175
+ let r = Li.indexOf(e.row) - Ri;
2176
+ if (Xi && r >= 0 && (r < Qi.startIndex || r >= Qi.endIndex)) {
2177
+ ta([e.row]);
2178
+ let t = Zi ? Zi.offsetOf(r) : r * q;
2179
+ Nn.current?.scrollTo({ top: t - K.height / 2 + q });
2134
2180
  }
2135
2181
  }, [
2136
2182
  z,
2137
- qr,
2138
- Ti,
2139
- Ei,
2183
+ ai,
2184
+ Li,
2140
2185
  Ri,
2141
- Bi,
2142
- zi,
2186
+ Xi,
2187
+ Qi,
2188
+ Zi,
2143
2189
  q,
2144
2190
  K.height
2145
2191
  ]);
2146
2192
  Be(() => {
2147
- let e = fa.current;
2148
- e && pa(e) && (fa.current = null);
2193
+ let e = wa.current;
2194
+ e && Ta(e) && (wa.current = null);
2149
2195
  });
2150
- let ha = S(0);
2196
+ let Da = S(0);
2151
2197
  b(() => {
2152
- if (z && Ti.includes(z.row) && (ha.current = Ti.indexOf(z.row), hi.includes(z.column)) || !z) return;
2153
- let e = Ti.includes(z.row) && B.popin.includes(z.column) && Si(z.row) ? {
2198
+ if (z && Li.includes(z.row) && (Da.current = Li.indexOf(z.row), Di.includes(z.column)) || !z) return;
2199
+ let e = Li.includes(z.row) && B.popin.includes(z.column) && Pi(z.row) ? {
2154
2200
  row: z.row,
2155
2201
  column: dt
2156
- } : It(Y, z, ha.current);
2157
- e && !E(e, z) ? (qr(e, "programmatic"), ua && (fa.current = e)) : !e && ua && A.current?.querySelector("[data-part=\"empty\"] [tabindex]")?.focus();
2202
+ } : Lt(Y, z, Da.current);
2203
+ e && !E(e, z) ? (ai(e, "programmatic"), Sa && (wa.current = e)) : !e && Sa && k.current?.querySelector("[data-part=\"empty\"] [tabindex]")?.focus();
2158
2204
  }, [
2159
2205
  Y,
2160
- Ti,
2161
- hi,
2206
+ Li,
2207
+ Di,
2162
2208
  B,
2163
- Si,
2209
+ Pi,
2164
2210
  z,
2165
- qr,
2166
- ua
2211
+ ai,
2212
+ Sa
2167
2213
  ]);
2168
- let ga = y((e) => {
2214
+ let Oa = y((e) => {
2169
2215
  let t = I.sort.findIndex((t) => t.column === e);
2170
2216
  return t === -1 ? null : {
2171
2217
  direction: I.sort[t].direction,
2172
2218
  index: t + 1
2173
2219
  };
2174
- }, [I.sort]), _a = y((e) => H.get(e)?.column.label ?? e, [H]), va = y((e) => {
2220
+ }, [I.sort]), ka = y((e) => H.get(e)?.column.label ?? e, [H]), Aa = y((e) => {
2175
2221
  if (e.sort.length === 0) {
2176
2222
  Z(j("sortCleared"));
2177
2223
  return;
2178
2224
  }
2179
- let t = e.sort.map((e) => j(e.direction === "ascending" ? "sortAscending" : "sortDescending", { column: _a(e.column) })).join(", ");
2225
+ let t = e.sort.map((e) => j(e.direction === "ascending" ? "sortAscending" : "sortDescending", { column: ka(e.column) })).join(", ");
2180
2226
  Z(j("sortedBy", { order: t }));
2181
2227
  }, [
2182
2228
  Z,
2183
2229
  j,
2184
- _a
2185
- ]), ya = y((e, t, n, r = "pointer") => {
2230
+ ka
2231
+ ]), ja = y((e, t, n, r = "pointer") => {
2186
2232
  let i = H.get(e);
2187
2233
  if (!i || !i.sortable) return;
2188
- let a = Gt(I, e, t);
2189
- jr(a.query, r, n, { change: a.change }), va(a.query);
2234
+ let a = Kt(I, e, t);
2235
+ Ur(a.query, r, n, { change: a.change }), Aa(a.query);
2190
2236
  }, [
2191
2237
  H,
2192
2238
  I,
2193
- jr,
2194
- va
2195
- ]), ba = y((e, t, n) => {
2196
- let r = Wt(I, e, t);
2197
- jr(r.query, "pointer", n, { change: r.change }), va(r.query);
2239
+ Ur,
2240
+ Aa
2241
+ ]), Ma = y((e, t, n) => {
2242
+ let r = Gt(I, e, t);
2243
+ Ur(r.query, "pointer", n, { change: r.change }), Aa(r.query);
2198
2244
  }, [
2199
2245
  I,
2200
- jr,
2201
- va
2202
- ]), xa = y((e) => rn(I.filter, e) ?? null, [I.filter]), Sa = y((e, t, n, r) => {
2203
- let i = zt(I, e, t);
2204
- jr(i.query, n, r, { change: i.change });
2205
- }, [I, jr]), [Ca, wa] = C(null), [Ta, Ea] = C(null), [Da, Oa] = C(null), ka = S(-Infinity), Aa = y((e, t, n) => {
2206
- Oa({
2246
+ Ur,
2247
+ Aa
2248
+ ]), Na = y((e) => an(I.filter, e) ?? null, [I.filter]), Pa = y((e, t, n, r) => {
2249
+ let i = Bt(I, e, t);
2250
+ Ur(i.query, n, r, { change: i.change });
2251
+ }, [I, Ur]), [Fa, Ia] = C(null), [La, Ra] = C(null), [za, Ba] = C(null), Va = S(-Infinity), Ha = y((e, t, n) => {
2252
+ Ba({
2207
2253
  column: e,
2208
2254
  anchor: t,
2209
2255
  returnTo: n
2210
- }), Ea(e);
2211
- }, []), ja = y(() => Oa(null), []), Ma = y((e, t) => {
2256
+ }), Ra(e);
2257
+ }, []), Ua = y(() => Ba(null), []), Wa = y((e, t) => {
2212
2258
  let n = e.target;
2213
- n instanceof Element && e.currentTarget.contains(n) && (e.shiftKey || n.closest(hr) || (e.preventDefault(), !(Date.now() - ka.current < gr) && Aa(t, vr(e.clientX, e.clientY), e.currentTarget)));
2214
- }, [Aa]), Na = S(/* @__PURE__ */ new Map()), Pa = y((e) => {
2215
- let t = `${e}|${JSON.stringify(I.filter)}|${I.search}|${L.length}`, n = Na.current.get(t);
2259
+ n instanceof Element && e.currentTarget.contains(n) && (e.shiftKey || n.closest(vr) || (e.preventDefault(), !(Date.now() - Va.current < yr) && Ha(t, Sr(e.clientX, e.clientY), e.currentTarget)));
2260
+ }, [Ha]), Ga = S(/* @__PURE__ */ new Map()), Ka = y((e) => {
2261
+ let t = `${e}|${JSON.stringify(I.filter)}|${I.search}|${L.length}`, n = Ga.current.get(t);
2216
2262
  if (n) return n;
2217
- let r = o.find((t) => t.id === e), i = /* @__PURE__ */ new Map();
2263
+ let r = c.find((t) => t.id === e), i = /* @__PURE__ */ new Map();
2218
2264
  if (r) {
2219
- let t = cn(I.filter, e), n = Jt(t.rules.length ? t : null, (e, t) => {
2220
- let n = o.find((e) => e.id === t);
2265
+ let t = ln(I.filter, e), n = Yt(t.rules.length ? t : null, (e, t) => {
2266
+ let n = c.find((e) => e.id === t);
2221
2267
  return n ? gt(n, e) : void 0;
2222
2268
  }, { locale: N });
2223
2269
  for (let e of L) {
@@ -2230,107 +2276,107 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2230
2276
  }
2231
2277
  }
2232
2278
  }
2233
- return Na.current = /* @__PURE__ */ new Map([[t, i]]), i;
2279
+ return Ga.current = /* @__PURE__ */ new Map([[t, i]]), i;
2234
2280
  }, [
2235
- o,
2281
+ c,
2236
2282
  I.filter,
2237
2283
  I.search,
2238
2284
  L,
2239
2285
  N
2240
- ]), Fa = y((e, t, n, r) => {
2241
- Hr(e, n, r, { change: t });
2242
- }, [Hr]), Ia = y((e, t, n) => {
2243
- Fa(Ht(R, e, t), "pinned", "pointer", n);
2244
- }, [R, Fa]), La = y((e, t, n = "programmatic") => {
2245
- let r = o.find((t) => t.id === e);
2246
- r && !R.hidden.includes(e) && (Fa(Bt(R, e, !0), "hidden", n, t), Z(j("columnHidden", { column: r.label })));
2286
+ ]), qa = y((e, t, n, r) => {
2287
+ ei(e, n, r, { change: t });
2288
+ }, [ei]), Ja = y((e, t, n) => {
2289
+ qa(Ut(R, e, t), "pinned", "pointer", n);
2290
+ }, [R, qa]), Ya = y((e, t, n = "programmatic") => {
2291
+ let r = c.find((t) => t.id === e);
2292
+ r && !R.hidden.includes(e) && (qa(Vt(R, e, !0), "hidden", n, t), Z(j("columnHidden", { column: r.label })));
2247
2293
  }, [
2248
- o,
2294
+ c,
2249
2295
  R,
2250
- Fa,
2296
+ qa,
2251
2297
  Z,
2252
2298
  j
2253
- ]), Ra = y((e, t, n, r) => {
2254
- let i = o.find((t) => t.id === e);
2299
+ ]), Xa = y((e, t, n, r) => {
2300
+ let i = c.find((t) => t.id === e);
2255
2301
  if (!i) return;
2256
- let a = Ut(R, i, t);
2257
- Fa(a, "width", n, r), n === "keyboard" && Z(j("resized", {
2302
+ let a = Wt(R, i, t);
2303
+ qa(a, "width", n, r), n === "keyboard" && Z(j("resized", {
2258
2304
  column: i.label,
2259
2305
  width: String(a.widths[e] ?? t)
2260
2306
  }));
2261
2307
  }, [
2262
- o,
2308
+ c,
2263
2309
  R,
2264
- Fa,
2310
+ qa,
2265
2311
  Z,
2266
2312
  j
2267
- ]), za = y((e, t, n) => {
2313
+ ]), Za = y((e, t, n) => {
2268
2314
  let r = H.get(e);
2269
- r && r.resizable && Ra(e, r.width + t, "keyboard", n);
2270
- }, [H, Ra]), Ba = y((e) => {
2271
- let t = A.current;
2315
+ r && r.resizable && Xa(e, r.width + t, "keyboard", n);
2316
+ }, [H, Xa]), Qa = y((e) => {
2317
+ let t = k.current;
2272
2318
  if (!t) return null;
2273
2319
  let n = 0;
2274
- for (let r of t.querySelectorAll(`[data-column="${CSS.escape(e)}"]`)) n = Math.max(n, Tr(r));
2320
+ for (let r of t.querySelectorAll(`[data-column="${CSS.escape(e)}"]`)) n = Math.max(n, kr(r));
2275
2321
  return n > 0 ? Math.ceil(n) : null;
2276
- }, []), Va = y((e, t, n) => {
2322
+ }, []), $a = y((e, t, n) => {
2277
2323
  if (!H.has(e)) return;
2278
- let r = Ba(e);
2279
- r !== null && Ra(e, r, t, n);
2324
+ let r = Qa(e);
2325
+ r !== null && Xa(e, r, t, n);
2280
2326
  }, [
2281
2327
  H,
2282
- Ba,
2283
- Ra
2284
- ]), Ha = y((e, t) => {
2328
+ Qa,
2329
+ Xa
2330
+ ]), eo = y((e, t) => {
2285
2331
  let n = R;
2286
2332
  for (let e of V) {
2287
2333
  if (!e.resizable) continue;
2288
- let t = Ba(e.id);
2289
- t !== null && (n = Ut(n, e.column, t));
2334
+ let t = Qa(e.id);
2335
+ t !== null && (n = Wt(n, e.column, t));
2290
2336
  }
2291
- n !== R && Fa(n, "width", e, t);
2337
+ n !== R && qa(n, "width", e, t);
2292
2338
  }, [
2293
2339
  R,
2294
2340
  V,
2295
- Ba,
2296
- Fa
2297
- ]), Ua = y((e, t, n) => e === null ? Ha(t, n) : Va(e, t, n), [Ha, Va]), Wa = y((e, t, n) => {
2341
+ Qa,
2342
+ qa
2343
+ ]), to = y((e, t, n) => e === null ? eo(t, n) : $a(e, t, n), [eo, $a]), no = y((e, t, n) => {
2298
2344
  let r = H.get(e);
2299
2345
  if (!r || !r.reorderable) return;
2300
- let i = qt(V, e), a = i.indexOf(e) + t;
2301
- a < 0 || a >= i.length || Fa(Vt(R, e, a, i), "order", "keyboard", n);
2346
+ let i = Jt(V, e), a = i.indexOf(e) + t;
2347
+ a < 0 || a >= i.length || qa(Ht(R, e, a, i), "order", "keyboard", n);
2302
2348
  }, [
2303
2349
  H,
2304
2350
  V,
2305
2351
  R,
2306
- Fa
2307
- ]), [Ga, Ka] = C(null), [qa, Ja] = C({
2352
+ qa
2353
+ ]), [ro, io] = C(null), [ao, oo] = C({
2308
2354
  dragging: null,
2309
2355
  target: null,
2310
2356
  offset: null,
2311
2357
  scrollTop: 0
2312
- }), Ya = S(null), Xa = S({
2358
+ }), so = S(null), co = S({
2313
2359
  resolved: V,
2314
2360
  effectiveState: R,
2315
- requestState: Fa,
2316
- gutters: ti,
2317
- labelOf: _a,
2361
+ requestState: qa,
2362
+ gutters: pi,
2363
+ labelOf: ka,
2318
2364
  t: j,
2319
- dragT: Fn
2365
+ dragT: Xn
2320
2366
  });
2321
- Xa.current = {
2367
+ co.current = {
2322
2368
  resolved: V,
2323
2369
  effectiveState: R,
2324
- requestState: Fa,
2325
- gutters: ti,
2326
- labelOf: _a,
2370
+ requestState: qa,
2371
+ gutters: pi,
2372
+ labelOf: ka,
2327
2373
  t: j,
2328
- dragT: Fn
2374
+ dragT: Xn
2329
2375
  };
2330
- let Za = S(/* @__PURE__ */ new Map()), Qa = S(!1), $a = S(/* @__PURE__ */ new Map()), eo = y((e, t) => {
2331
- let n = Ya.current, r = Za.current.get(t);
2332
- if (r && (r(), Za.current.delete(t)), !e || !n) return;
2333
- let i = Xa.current.resolved.find((e) => e.id === t);
2376
+ let lo = S(/* @__PURE__ */ new Map()), uo = S(!1), fo = S(/* @__PURE__ */ new Map()), po = y((e, t) => {
2377
+ let n = so.current, r = lo.current.get(t);
2378
+ if (r && (r(), lo.current.delete(t)), !e || !n) return;
2379
+ let i = co.current.resolved.find((e) => e.id === t);
2334
2380
  if (!i || !i.reorderable) return;
2335
2381
  let a = n.attachDraggable(e, {
2336
2382
  container: "columns",
@@ -2339,38 +2385,38 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2339
2385
  canDrag: (e) => !(e.target instanceof Element && e.target.closest("[data-part=\"resizer\"]")),
2340
2386
  distance: 6
2341
2387
  });
2342
- Za.current.set(t, a);
2343
- }, []), to = y((e, t) => {
2344
- e ? $a.current.set(t, e) : $a.current.delete(t), eo(e, t);
2345
- }, [eo]), no = V.map((e) => e.id).join("\0");
2388
+ lo.current.set(t, a);
2389
+ }, []), mo = y((e, t) => {
2390
+ e ? fo.current.set(t, e) : fo.current.delete(t), po(e, t);
2391
+ }, [po]), ho = V.map((e) => e.id).join("\0");
2346
2392
  b(() => {
2347
- for (let [e, t] of $a.current) eo(t, e);
2348
- }, [no, eo]), b(() => {
2349
- let e = A.current;
2393
+ for (let [e, t] of fo.current) po(t, e);
2394
+ }, [ho, po]), b(() => {
2395
+ let e = k.current;
2350
2396
  if (!e) return;
2351
2397
  let t = st({
2352
2398
  document: e.ownerDocument,
2353
- t: (e, t) => Xa.current.dragT(e, t),
2399
+ t: (e, t) => co.current.dragT(e, t),
2354
2400
  preview: !1,
2355
2401
  autoScroll: { axis: "x" },
2356
2402
  onDrop: ({ items: e, target: t, reason: n, event: r }) => {
2357
2403
  if (t.kind !== "between") return;
2358
- let { resolved: i, effectiveState: a, requestState: o } = Xa.current, s = e[0], c = qt(i, s), l = Dr(i, c, s, t.index);
2359
- l !== null && o(Vt(a, s, l, c), "order", n === "keyboard" ? "keyboard" : "pointer", r);
2404
+ let { resolved: i, effectiveState: a, requestState: o } = co.current, s = e[0], c = Jt(i, s), l = jr(i, c, s, t.index);
2405
+ l !== null && o(Ht(a, s, l, c), "order", n === "keyboard" ? "keyboard" : "pointer", r);
2360
2406
  }
2361
- }), n = () => Xa.current.resolved.map((e) => e.id), r = (t) => e.querySelector(`[data-part="column-header"][data-column="${CSS.escape(t)}"]`);
2407
+ }), n = () => co.current.resolved.map((e) => e.id), r = (t) => e.querySelector(`[data-part="column-header"][data-column="${CSS.escape(t)}"]`);
2362
2408
  t.registerContainer({
2363
2409
  key: "columns",
2364
2410
  items: n,
2365
2411
  orientation: "horizontal",
2366
2412
  element: () => e.querySelector("[data-part=\"head\"] > [data-part=\"header-row\"]:last-of-type"),
2367
2413
  itemElement: r,
2368
- label: () => Xa.current.t("dragColumns"),
2369
- itemLabel: (e) => Xa.current.labelOf(e)
2414
+ label: () => co.current.t("dragColumns"),
2415
+ itemLabel: (e) => co.current.labelOf(e)
2370
2416
  });
2371
2417
  let i = !1, a = t.subscribe((e) => {
2372
2418
  if (e.status !== "dragging") {
2373
- i && (Qa.current = !0), i = !1, Ja({
2419
+ i && (uo.current = !0), i = !1, oo({
2374
2420
  dragging: null,
2375
2421
  target: null,
2376
2422
  offset: null,
@@ -2381,78 +2427,78 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2381
2427
  i = !0;
2382
2428
  let t = e.items[0] ?? null, a = e.target && e.target.kind === "between" ? e.target : null, o = null, s = 0, c = null;
2383
2429
  if (a && t) {
2384
- let e = Xa.current.resolved, i = qt(e, t), l = e.find((e) => e.id === i[0]), u = e.find((e) => e.id === i[i.length - 1]), d = Math.max(l ? l.index - 1 : 0, Math.min(u ? u.index : e.length, a.index)), f = Mn.current, p = n(), m = d >= p.length, h = p[m ? p.length - 1 : d], g = h ? r(h) : null;
2430
+ let e = co.current.resolved, i = Jt(e, t), l = e.find((e) => e.id === i[0]), u = e.find((e) => e.id === i[i.length - 1]), d = Math.max(l ? l.index - 1 : 0, Math.min(u ? u.index : e.length, a.index)), f = Nn.current, p = n(), m = d >= p.length, h = p[m ? p.length - 1 : d], g = h ? r(h) : null;
2385
2431
  if (g && f) {
2386
2432
  let e = g.getBoundingClientRect(), t = f.getBoundingClientRect(), n = getComputedStyle(f).direction === "rtl", r = m === n ? e.left : e.right;
2387
2433
  o = n ? t.right - r - f.scrollLeft : r - t.left + f.scrollLeft, s = f.scrollTop, c = p[d] ?? null;
2388
2434
  }
2389
2435
  }
2390
- Ja({
2436
+ oo({
2391
2437
  dragging: t,
2392
2438
  target: c,
2393
2439
  offset: o,
2394
2440
  scrollTop: s
2395
2441
  });
2396
2442
  });
2397
- Ya.current = t;
2398
- for (let [e, t] of $a.current) eo(t, e);
2399
- let o = Za.current;
2443
+ so.current = t;
2444
+ for (let [e, t] of fo.current) po(t, e);
2445
+ let o = lo.current;
2400
2446
  return () => {
2401
2447
  a();
2402
2448
  for (let e of o.values()) e();
2403
- o.clear(), t.destroy(), Ya.current = null;
2449
+ o.clear(), t.destroy(), so.current = null;
2404
2450
  };
2405
2451
  }, []);
2406
- let ro = x(() => {
2452
+ let go = x(() => {
2407
2453
  let e = /* @__PURE__ */ new Map();
2408
2454
  for (let t of W.top) e.set(t.key, t);
2409
2455
  for (let t of G) t.kind === "row" && e.set(t.key, t);
2410
2456
  for (let t of W.bottom) e.set(t.key, t);
2411
2457
  return e;
2412
- }, [G, W]), io = $r && !O && zr === "client" && I.sort.length === 0 && I.filter === null && I.search.trim() === "" && I.group.length === 0, [ao, oo] = C({
2458
+ }, [G, W]), _o = di && !A && Zr === "client" && I.sort.length === 0 && I.filter === null && I.search.trim() === "" && I.group.length === 0, [vo, yo] = C({
2413
2459
  dragging: null,
2414
2460
  offset: null,
2415
2461
  scrollLeft: 0
2416
- }), so = S(null), co = S(/* @__PURE__ */ new Map()), lo = S(/* @__PURE__ */ new Map()), uo = y((e) => {
2417
- let t = ro.get(e), n = o.find((e) => e.rowHeader);
2418
- return t && n ? ht(n, t.row, ar) : e;
2462
+ }), bo = S(null), xo = S(/* @__PURE__ */ new Map()), So = S(/* @__PURE__ */ new Map()), Co = y((e) => {
2463
+ let t = go.get(e), n = c.find((e) => e.rowHeader);
2464
+ return t && n ? ht(n, t.row, Lr) : e;
2419
2465
  }, [
2420
- ro,
2421
- o,
2422
- ar
2423
- ]), fo = S({
2424
- nodeByKey: ro,
2425
- mountedNodes: Vi,
2426
- rowsReorderableNow: io,
2466
+ go,
2467
+ c,
2468
+ Lr
2469
+ ]), wo = S({
2470
+ nodeByKey: go,
2471
+ mountedNodes: $i,
2472
+ rowsReorderableNow: _o,
2427
2473
  onRowsReorder: Ie,
2428
- labelOf: uo,
2474
+ labelOf: Co,
2429
2475
  t: j,
2430
- dragT: Fn
2476
+ dragT: Xn
2431
2477
  });
2432
- fo.current = {
2433
- nodeByKey: ro,
2434
- mountedNodes: Vi,
2435
- rowsReorderableNow: io,
2478
+ wo.current = {
2479
+ nodeByKey: go,
2480
+ mountedNodes: $i,
2481
+ rowsReorderableNow: _o,
2436
2482
  onRowsReorder: Ie,
2437
- labelOf: uo,
2483
+ labelOf: Co,
2438
2484
  t: j,
2439
- dragT: Fn
2485
+ dragT: Xn
2440
2486
  };
2441
- let po = y((e, t) => {
2442
- let n = so.current;
2443
- if (lo.current.get(t)?.(), lo.current.delete(t), !e || !n) return;
2487
+ let To = y((e, t) => {
2488
+ let n = bo.current;
2489
+ if (So.current.get(t)?.(), So.current.delete(t), !e || !n) return;
2444
2490
  let r = n.attachDraggable(e, {
2445
2491
  container: "rows",
2446
2492
  key: t,
2447
2493
  handle: () => e.querySelector("[data-part=\"row-handle\"]"),
2448
- disabled: () => !fo.current.rowsReorderableNow,
2494
+ disabled: () => !wo.current.rowsReorderableNow,
2449
2495
  distance: 6
2450
2496
  });
2451
- lo.current.set(t, r);
2452
- }, []), mo = y((e, t) => {
2453
- e ? co.current.set(t, e) : co.current.delete(t), po(e, t);
2454
- }, [po]), ho = y((e, t) => {
2455
- let { nodeByKey: n, mountedNodes: r } = fo.current, i = n.get(e);
2497
+ So.current.set(t, r);
2498
+ }, []), Eo = y((e, t) => {
2499
+ e ? xo.current.set(t, e) : xo.current.delete(t), To(e, t);
2500
+ }, [To]), Do = y((e, t) => {
2501
+ let { nodeByKey: n, mountedNodes: r } = wo.current, i = n.get(e);
2456
2502
  if (!i) return null;
2457
2503
  let a = r.filter((e) => e.kind === "row"), o = a[a.length - 1], s = a[t], c = s && s.kind === "row" ? s.index : o && o.kind === "row" ? o.index + 1 : 0, l = i.index < c ? c - 1 : c;
2458
2504
  return l === i.index ? null : {
@@ -2463,42 +2509,42 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2463
2509
  };
2464
2510
  }, []);
2465
2511
  b(() => {
2466
- let e = A.current;
2467
- if (!e || !$r) return;
2512
+ let e = k.current;
2513
+ if (!e || !di) return;
2468
2514
  let t = st({
2469
2515
  document: e.ownerDocument,
2470
- t: (e, t) => fo.current.dragT(e, t),
2516
+ t: (e, t) => wo.current.dragT(e, t),
2471
2517
  preview: !1,
2472
2518
  autoScroll: { axis: "y" },
2473
2519
  onDrop: ({ items: e, target: t, reason: n, event: r }) => {
2474
2520
  if (t.kind !== "between") return;
2475
- let i = ho(e[0], t.index);
2476
- i && fo.current.onRowsReorder?.({
2521
+ let i = Do(e[0], t.index);
2522
+ i && wo.current.onRowsReorder?.({
2477
2523
  ...i,
2478
2524
  reason: n === "keyboard" ? "keyboard" : "pointer",
2479
2525
  event: r
2480
2526
  });
2481
2527
  }
2482
- }), n = () => fo.current.mountedNodes.flatMap((e) => e.kind === "row" ? [e.key] : []), r = (t) => e.querySelector(`[data-part="body"] > [data-part="row"][data-row="${CSS.escape(t)}"]`);
2528
+ }), n = () => wo.current.mountedNodes.flatMap((e) => e.kind === "row" ? [e.key] : []), r = (t) => e.querySelector(`[data-part="body"] > [data-part="row"][data-row="${CSS.escape(t)}"]`);
2483
2529
  t.registerContainer({
2484
2530
  key: "rows",
2485
2531
  items: n,
2486
2532
  orientation: "vertical",
2487
2533
  element: () => e.querySelector("[data-part=\"body\"]"),
2488
2534
  itemElement: r,
2489
- label: () => fo.current.t("dragRows"),
2490
- itemLabel: (e) => fo.current.labelOf(e)
2535
+ label: () => wo.current.t("dragRows"),
2536
+ itemLabel: (e) => wo.current.labelOf(e)
2491
2537
  });
2492
2538
  let i = t.subscribe((e) => {
2493
2539
  if (e.status !== "dragging") {
2494
- oo({
2540
+ yo({
2495
2541
  dragging: null,
2496
2542
  offset: null,
2497
2543
  scrollLeft: 0
2498
2544
  });
2499
2545
  return;
2500
2546
  }
2501
- let t = e.items[0] ?? null, i = e.target && e.target.kind === "between" ? e.target : null, a = null, o = 0, s = Mn.current;
2547
+ let t = e.items[0] ?? null, i = e.target && e.target.kind === "between" ? e.target : null, a = null, o = 0, s = Nn.current;
2502
2548
  if (i && s) {
2503
2549
  let e = n(), t = i.index >= e.length, c = e[t ? e.length - 1 : i.index], l = c ? r(c) : null;
2504
2550
  if (l) {
@@ -2506,165 +2552,165 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2506
2552
  a = (t ? e.bottom : e.top) - n.top + s.scrollTop, o = Math.abs(s.scrollLeft);
2507
2553
  }
2508
2554
  }
2509
- oo({
2555
+ yo({
2510
2556
  dragging: t,
2511
2557
  offset: a,
2512
2558
  scrollLeft: o
2513
2559
  });
2514
2560
  });
2515
- so.current = t;
2516
- for (let [e, t] of co.current) po(t, e);
2517
- let a = lo.current;
2561
+ bo.current = t;
2562
+ for (let [e, t] of xo.current) To(t, e);
2563
+ let a = So.current;
2518
2564
  return () => {
2519
2565
  i();
2520
2566
  for (let e of a.values()) e();
2521
- a.clear(), t.destroy(), so.current = null;
2567
+ a.clear(), t.destroy(), bo.current = null;
2522
2568
  };
2523
2569
  }, [
2524
- $r,
2525
- po,
2526
- ho
2570
+ di,
2571
+ To,
2572
+ Do
2527
2573
  ]);
2528
- let go = y((e, t, n) => {
2529
- if (!fo.current.rowsReorderableNow) return;
2530
- let r = fo.current.mountedNodes.filter((e) => e.kind === "row").findIndex((t) => t.key === e);
2574
+ let Oo = y((e, t, n) => {
2575
+ if (!wo.current.rowsReorderableNow) return;
2576
+ let r = wo.current.mountedNodes.filter((e) => e.kind === "row").findIndex((t) => t.key === e);
2531
2577
  if (r < 0) return;
2532
2578
  let i = t > 0 ? r + 2 : r - 1;
2533
2579
  if (i < 0) return;
2534
- let a = ho(e, i);
2580
+ let a = Do(e, i);
2535
2581
  a && (Ie?.({
2536
2582
  ...a,
2537
2583
  reason: "keyboard",
2538
2584
  event: n
2539
2585
  }), Z(j("rowMoved", {
2540
- row: fo.current.labelOf(e),
2586
+ row: wo.current.labelOf(e),
2541
2587
  position: a.to + 1
2542
2588
  })));
2543
2589
  }, [
2544
- ho,
2590
+ Do,
2545
2591
  Ie,
2546
2592
  Z,
2547
2593
  j
2548
- ]), _o = ve === !0 ? gn : ve || 0, vo = S(/* @__PURE__ */ new Map()), yo = S(0), [bo, xo] = C(0), So = S(null), Co = S(null);
2594
+ ]), ko = ve === !0 ? _n : ve || 0, Ao = S(/* @__PURE__ */ new Map()), jo = S(0), [Mo, No] = C(0), Po = S(null), Fo = S(null);
2549
2595
  b(() => {
2550
- if (_o <= 0) {
2551
- Co.current = null;
2596
+ if (ko <= 0) {
2597
+ Fo.current = null;
2552
2598
  return;
2553
2599
  }
2554
- let e = Co.current, t = /* @__PURE__ */ new Map();
2600
+ let e = Fo.current, t = /* @__PURE__ */ new Map();
2555
2601
  for (let e of L) t.set(P(e), e);
2556
- if (Co.current = {
2602
+ if (Fo.current = {
2557
2603
  rows: L,
2558
2604
  byKey: t
2559
2605
  }, !e || e.rows === L) return;
2560
2606
  let n = Date.now(), r = !1;
2561
2607
  for (let t of [
2562
2608
  ...W.top,
2563
- ...Vi,
2609
+ ...$i,
2564
2610
  ...W.bottom
2565
2611
  ]) {
2566
2612
  if (t.kind !== "row") continue;
2567
2613
  let i = e.byKey.get(t.key);
2568
- if (i !== void 0 && i !== t.row) for (let e of V) Object.is(gt(e.column, i), gt(e.column, t.row)) || (vo.current.set(`${t.key}\u0000${e.id}`, {
2569
- until: n + _o,
2570
- generation: yo.current + 1
2614
+ if (i !== void 0 && i !== t.row) for (let e of V) Object.is(gt(e.column, i), gt(e.column, t.row)) || (Ao.current.set(`${t.key}\u0000${e.id}`, {
2615
+ until: n + ko,
2616
+ generation: jo.current + 1
2571
2617
  }), r = !0);
2572
2618
  }
2573
- if (r && (yo.current += 1, xo((e) => e + 1), So.current === null)) {
2619
+ if (r && (jo.current += 1, No((e) => e + 1), Po.current === null)) {
2574
2620
  let e = () => {
2575
- So.current = null;
2621
+ Po.current = null;
2576
2622
  let t = Date.now(), n = Infinity;
2577
- for (let [e, r] of vo.current) r.until <= t ? vo.current.delete(e) : n = Math.min(n, r.until);
2578
- xo((e) => e + 1), n !== Infinity && (So.current = setTimeout(e, Math.max(16, n - t)));
2623
+ for (let [e, r] of Ao.current) r.until <= t ? Ao.current.delete(e) : n = Math.min(n, r.until);
2624
+ No((e) => e + 1), n !== Infinity && (Po.current = setTimeout(e, Math.max(16, n - t)));
2579
2625
  };
2580
- So.current = setTimeout(e, _o);
2626
+ Po.current = setTimeout(e, ko);
2581
2627
  }
2582
2628
  }, [
2583
2629
  L,
2584
2630
  P,
2585
- Vi,
2631
+ $i,
2586
2632
  W,
2587
2633
  V,
2588
- _o
2634
+ ko
2589
2635
  ]), b(() => () => {
2590
- So.current !== null && clearTimeout(So.current);
2636
+ Po.current !== null && clearTimeout(Po.current);
2591
2637
  }, []);
2592
- let wo = y((e) => {
2593
- let t = vo.current.get(`${e.row}\u0000${e.column}`);
2638
+ let Io = y((e) => {
2639
+ let t = Ao.current.get(`${e.row}\u0000${e.column}`);
2594
2640
  return t ? t.generation % 2 == 0 ? "a" : "b" : null;
2595
- }, [bo]), To = x(() => new Set(Jr), [Jr]), Eo = y((e) => To.has(e), [To]), Do = y((e, t, n = "pointer") => {
2596
- let r = To.has(e) ? Jr.filter((t) => t !== e) : [...Jr, e];
2597
- Yr(r, n, t);
2641
+ }, [Mo]), Lo = x(() => new Set(oi), [oi]), Ro = y((e) => Lo.has(e), [Lo]), zo = y((e, t, n = "pointer") => {
2642
+ let r = Lo.has(e) ? oi.filter((t) => t !== e) : [...oi, e];
2643
+ si(r, n, t);
2598
2644
  }, [
2599
- To,
2600
- Jr,
2601
- Yr
2602
- ]), Oo = x(() => O ? O.column && H.has(O.column) ? O.column : V[0]?.id ?? null : null, [
2603
- O,
2645
+ Lo,
2646
+ oi,
2647
+ si
2648
+ ]), Bo = x(() => A ? A.column && H.has(A.column) ? A.column : V[0]?.id ?? null : null, [
2649
+ A,
2604
2650
  H,
2605
2651
  V
2606
- ]), [ko, Ao] = C(/* @__PURE__ */ new Set()), jo = y((e) => ko.has(e), [ko]), Mo = y((e) => O?.hasChildren?.(e) === !0, [O]);
2652
+ ]), [Vo, Ho] = C(/* @__PURE__ */ new Set()), Uo = y((e) => Vo.has(e), [Vo]), Wo = y((e) => A?.hasChildren?.(e) === !0, [A]);
2607
2653
  b(() => {
2608
- if (ko.size === 0) return;
2609
- let e = new Set(ko);
2610
- for (let t of ko) {
2611
- let n = ro.get(t);
2612
- (!n || !To.has(t) || n.childCount > 0) && e.delete(t);
2654
+ if (Vo.size === 0) return;
2655
+ let e = new Set(Vo);
2656
+ for (let t of Vo) {
2657
+ let n = go.get(t);
2658
+ (!n || !Lo.has(t) || n.childCount > 0) && e.delete(t);
2613
2659
  }
2614
- e.size !== ko.size && Ao(e);
2660
+ e.size !== Vo.size && Ho(e);
2615
2661
  }, [
2616
- ko,
2617
- ro,
2618
- To
2662
+ Vo,
2663
+ go,
2664
+ Lo
2619
2665
  ]);
2620
- let No = y((e, t, n = "pointer") => {
2621
- let r = ro.get(e);
2666
+ let Go = y((e, t, n = "pointer") => {
2667
+ let r = go.get(e);
2622
2668
  if (!r) return;
2623
- let i = !To.has(e);
2624
- Do(e, t, n), i && r.childCount === 0 && O?.hasChildren?.(r.row) && Fe && (Ao((t) => new Set(t).add(e)), Fe({
2669
+ let i = !Lo.has(e);
2670
+ zo(e, t, n), i && r.childCount === 0 && A?.hasChildren?.(r.row) && Fe && (Ho((t) => new Set(t).add(e)), Fe({
2625
2671
  key: e,
2626
2672
  row: r.row
2627
2673
  }));
2628
2674
  }, [
2629
- ro,
2630
- To,
2631
- Do,
2632
- O,
2675
+ go,
2676
+ Lo,
2677
+ zo,
2678
+ A,
2633
2679
  Fe
2634
- ]), Po = x(() => G.filter((e) => e.kind === "group").map((e) => e.key), [G]), Fo = y((e, t, n = "pointer") => {
2635
- let r = Xr === "all" || Xr.includes(e), i;
2636
- i = Xr === "all" ? Po.filter((t) => t !== e && !t.startsWith(`${e}/`)) : r ? Xr.filter((t) => t !== e) : [...Xr, e], Zr(i, n, t);
2680
+ ]), Ko = x(() => G.filter((e) => e.kind === "group").map((e) => e.key), [G]), qo = y((e, t, n = "pointer") => {
2681
+ let r = ci === "all" || ci.includes(e), i;
2682
+ i = ci === "all" ? Ko.filter((t) => t !== e && !t.startsWith(`${e}/`)) : r ? ci.filter((t) => t !== e) : [...ci, e], li(i, n, t);
2637
2683
  }, [
2638
- Xr,
2639
- Po,
2640
- Zr
2641
- ]), [Io, Lo] = C(null), Ro = S(Io);
2642
- Ro.current = Io;
2643
- let Q = y((e) => ro.get(e)?.row, [ro]), zo = y((e, t = null) => {
2644
- let n = Q(e.row), r = o.find((t) => t.id === e.column);
2684
+ ci,
2685
+ Ko,
2686
+ li
2687
+ ]), [Jo, Yo] = C(null), Xo = S(Jo);
2688
+ Xo.current = Jo;
2689
+ let Q = y((e) => go.get(e)?.row, [go]), Zo = y((e, t = null) => {
2690
+ let n = Q(e.row), r = c.find((t) => t.id === e.column);
2645
2691
  if (!n || !r || !F(r, n)) return;
2646
- let i = Gn === "row" ? o.filter((e) => F(e, n)).map((e) => e.id) : [e.column], a = {};
2692
+ let i = rr === "row" ? c.filter((e) => F(e, n)).map((e) => e.id) : [e.column], a = {};
2647
2693
  for (let e of i) {
2648
- let t = o.find((t) => t.id === e);
2694
+ let t = c.find((t) => t.id === e);
2649
2695
  a[e] = gt(t, n);
2650
2696
  }
2651
- let s = { ...a };
2652
- t !== null && (s[e.column] = r.kind === "number" ? Number(t) : t), Lo({
2697
+ let o = { ...a };
2698
+ t !== null && (o[e.column] = r.kind === "number" ? Number(t) : t), Yo({
2653
2699
  cell: e,
2654
2700
  columns: i,
2655
- drafts: s,
2701
+ drafts: o,
2656
2702
  originals: a,
2657
2703
  status: "editing",
2658
2704
  messages: {},
2659
2705
  seed: t
2660
- }), Me?.(e), fa.current = e;
2706
+ }), Me?.(e), wa.current = e;
2661
2707
  }, [
2662
2708
  Q,
2663
- o,
2709
+ c,
2664
2710
  F,
2665
- Gn,
2711
+ rr,
2666
2712
  Me
2667
- ]), Bo = y((e, t) => {
2713
+ ]), Qo = y((e, t) => {
2668
2714
  let n = (n) => n && {
2669
2715
  ...n,
2670
2716
  drafts: {
@@ -2673,19 +2719,19 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2673
2719
  },
2674
2720
  status: "editing"
2675
2721
  };
2676
- Ro.current = n(Ro.current), Lo(n);
2677
- }, []), Vo = y(() => {
2678
- let e = Ro.current;
2679
- e && (Lo(null), Ae?.(e.cell), fa.current = e.cell);
2680
- }, [Ae]), Ho = y((e, t) => {
2722
+ Xo.current = n(Xo.current), Yo(n);
2723
+ }, []), $o = y(() => {
2724
+ let e = Xo.current;
2725
+ e && (Yo(null), Ae?.(e.cell), wa.current = e.cell);
2726
+ }, [Ae]), es = y((e, t) => {
2681
2727
  if (t === "down") {
2682
- let t = wt(Y, e, "down");
2683
- return E(t, e) || !Or(t.row) ? null : t;
2728
+ let t = Tt(Y, e, "down");
2729
+ return E(t, e) || !Mr(t.row) ? null : t;
2684
2730
  }
2685
2731
  let n = Q(e.row);
2686
2732
  if (!n) return null;
2687
2733
  let r = U.filter((e) => {
2688
- let t = o.find((t) => t.id === e);
2734
+ let t = c.find((t) => t.id === e);
2689
2735
  return t !== void 0 && F(t, n);
2690
2736
  }), i = r[r.indexOf(e.column) + (t === "next" ? 1 : -1)];
2691
2737
  return i ? {
@@ -2696,91 +2742,91 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2696
2742
  Y,
2697
2743
  Q,
2698
2744
  U,
2699
- o,
2745
+ c,
2700
2746
  F
2701
2747
  ]), $ = y((e, t = {}) => {
2702
- let n = Ro.current;
2748
+ let n = Xo.current;
2703
2749
  if (!n || n.status === "pending") return;
2704
2750
  let r = Q(n.cell.row);
2705
2751
  if (!r) {
2706
- Lo(null);
2752
+ Yo(null);
2707
2753
  return;
2708
2754
  }
2709
2755
  let i = {};
2710
2756
  for (let e of n.columns) Object.is(n.drafts[e], n.originals[e]) || (i[e] = n.drafts[e]);
2711
2757
  let a = () => {
2712
- let e = t.move ?? "stay", r = e === "stay" ? null : Ho(n.cell, e);
2713
- Lo(null), r ? (ma(r, "keyboard"), Gn === "cell" && e !== "down" && zo(r)) : fa.current = n.cell;
2758
+ let e = t.move ?? "stay", r = e === "stay" ? null : es(n.cell, e);
2759
+ Yo(null), r ? (Ea(r, "keyboard"), rr === "cell" && e !== "down" && Zo(r)) : wa.current = n.cell;
2714
2760
  };
2715
2761
  if (Object.keys(i).length === 0) {
2716
2762
  a();
2717
2763
  return;
2718
2764
  }
2719
- let s = async () => {
2765
+ let o = async () => {
2720
2766
  let e = {};
2721
2767
  for (let t of Object.keys(i)) {
2722
- let n = o.find((e) => e.id === t), a = n.parse ? n.parse(i[t], r) : i[t];
2768
+ let n = c.find((e) => e.id === t), a = n.parse ? n.parse(i[t], r) : i[t];
2723
2769
  i[t] = a;
2724
- let s = n.validate ? await n.validate(a, r) : null;
2725
- s && (e[t] = s);
2770
+ let o = n.validate ? await n.validate(a, r) : null;
2771
+ o && (e[t] = o);
2726
2772
  }
2727
2773
  return e;
2728
2774
  };
2729
2775
  (async () => {
2730
- Lo((e) => e && {
2776
+ Yo((e) => e && {
2731
2777
  ...e,
2732
2778
  status: "pending"
2733
2779
  });
2734
- let t = await s();
2780
+ let t = await o();
2735
2781
  if (Object.keys(t).length > 0) {
2736
- Lo((e) => e && {
2782
+ Yo((e) => e && {
2737
2783
  ...e,
2738
2784
  status: "invalid",
2739
2785
  messages: t
2740
- }), fa.current = n.cell;
2786
+ }), wa.current = n.cell;
2741
2787
  return;
2742
2788
  }
2743
- let o = n.cell.column in i ? n.cell.column : Object.keys(i)[0];
2789
+ let s = n.cell.column in i ? n.cell.column : Object.keys(i)[0];
2744
2790
  try {
2745
2791
  await je?.({
2746
2792
  key: n.cell.row,
2747
- column: o,
2748
- value: i[o],
2749
- previous: n.originals[o],
2793
+ column: s,
2794
+ value: i[s],
2795
+ previous: n.originals[s],
2750
2796
  row: r,
2751
2797
  reason: e,
2752
2798
  changes: i
2753
2799
  }), a();
2754
2800
  } catch (e) {
2755
2801
  let t = e instanceof Error && e.message ? e.message : j("editFailed");
2756
- Lo((e) => e && {
2802
+ Yo((e) => e && {
2757
2803
  ...e,
2758
2804
  status: "invalid",
2759
- messages: { [o]: t }
2760
- }), fa.current = n.cell;
2805
+ messages: { [s]: t }
2806
+ }), wa.current = n.cell;
2761
2807
  }
2762
2808
  })();
2763
2809
  }, [
2764
2810
  Q,
2765
- Ho,
2766
- ma,
2767
- Gn,
2768
- zo,
2769
- o,
2811
+ es,
2812
+ Ea,
2813
+ rr,
2814
+ Zo,
2815
+ c,
2770
2816
  je,
2771
2817
  j
2772
- ]), Uo = j("editConflict");
2818
+ ]), ts = j("editConflict");
2773
2819
  b(() => {
2774
- let e = Ro.current;
2820
+ let e = Xo.current;
2775
2821
  if (!e || e.status === "pending") return;
2776
2822
  let t = Q(e.cell.row);
2777
2823
  if (!t) return;
2778
2824
  let n = {};
2779
2825
  for (let r of e.columns) {
2780
- let i = o.find((e) => e.id === r);
2781
- i && !Object.is(gt(i, t), e.originals[r]) && (n[r] = Uo);
2826
+ let i = c.find((e) => e.id === r);
2827
+ i && !Object.is(gt(i, t), e.originals[r]) && (n[r] = ts);
2782
2828
  }
2783
- Object.keys(n).length > 0 && Lo({
2829
+ Object.keys(n).length > 0 && Yo({
2784
2830
  ...e,
2785
2831
  status: "invalid",
2786
2832
  messages: {
@@ -2791,10 +2837,10 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2791
2837
  }, [
2792
2838
  L,
2793
2839
  Q,
2794
- o,
2795
- Uo
2840
+ c,
2841
+ ts
2796
2842
  ]);
2797
- let Wo = y((e, t, n) => {
2843
+ let ns = y((e, t, n) => {
2798
2844
  De?.({
2799
2845
  key: e,
2800
2846
  reason: t,
@@ -2802,10 +2848,10 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2802
2848
  });
2803
2849
  }, [De]);
2804
2850
  b(() => {
2805
- let e = Mn.current;
2851
+ let e = Nn.current;
2806
2852
  if (!e) return;
2807
2853
  let t = 0, n = () => {
2808
- t = 0, ki(e.scrollTop), ji(Math.abs(e.scrollLeft));
2854
+ t = 0, Vi(e.scrollTop), Ui(Math.abs(e.scrollLeft));
2809
2855
  }, r = () => {
2810
2856
  t === 0 && (t = requestAnimationFrame(n));
2811
2857
  };
@@ -2814,17 +2860,17 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2814
2860
  let t = e.querySelector(":scope > [data-part=\"head\"]"), n = e.querySelector(":scope > [data-part=\"summary\"]");
2815
2861
  e.style.setProperty("--slotted-data-grid-pinned-top-offset", `${t?.offsetHeight ?? 0}px`), e.style.setProperty("--slotted-data-grid-pinned-bottom-offset", `${n?.offsetHeight ?? 0}px`);
2816
2862
  }, a = typeof ResizeObserver > "u" ? null : new ResizeObserver(() => {
2817
- Mi({
2863
+ Wi({
2818
2864
  width: e.clientWidth,
2819
2865
  height: e.clientHeight
2820
- }), ai(e.clientWidth), i();
2866
+ }), _i(e.clientWidth), i();
2821
2867
  });
2822
2868
  a?.observe(e);
2823
2869
  for (let t of e.querySelectorAll(":scope > [data-part=\"head\"], :scope > [data-part=\"summary\"]")) a?.observe(t);
2824
- Mi({
2870
+ Wi({
2825
2871
  width: e.clientWidth,
2826
2872
  height: e.clientHeight
2827
- }), a && ai(e.clientWidth), i();
2873
+ }), a && _i(e.clientWidth), i();
2828
2874
  let o = Ue(e, {
2829
2875
  orientation: () => "horizontal",
2830
2876
  onChange: (t) => {
@@ -2835,64 +2881,58 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2835
2881
  e.removeEventListener("scroll", r), t && cancelAnimationFrame(t), a?.disconnect(), o.destroy();
2836
2882
  };
2837
2883
  }, []);
2838
- let Go = di ? `${li}\u0002${ii}` : li, Ko = y((e, t) => {
2884
+ let rs = Ci ? `${xi}\u0002${gi}` : xi, is = y((e, t) => {
2839
2885
  if (!t) return;
2840
- let n = typeof Jn != "number" && Ni === null;
2841
- if (!n && !Li) return;
2886
+ let n = typeof or != "number" && Gi === null;
2887
+ if (!n && !Yi) return;
2842
2888
  let r = t.getBoundingClientRect().height;
2843
- r !== 0 && (n && Pi(Math.round(r)), Li && Ii((t) => t.get(e) === r ? t : new Map(t).set(e, r)));
2889
+ r !== 0 && (n && Ki(Math.round(r)), Yi && Ji((t) => t.get(e) === r ? t : new Map(t).set(e, r)));
2844
2890
  }, [
2845
- Jn,
2846
- Ni,
2847
- Li,
2848
- Go
2849
- ]);
2850
- b(() => {
2851
- if (!Ve || !Pr || Ir || $n === "button" || Se === !0) return;
2852
- let e = G.length - Bi.endIndex;
2853
- (Ri ? e <= Qn : Oi + K.height >= (Mn.current?.scrollHeight ?? 0) - q * Qn) && Ve();
2891
+ or,
2892
+ Gi,
2893
+ Yi,
2894
+ rs
2895
+ ]), as = Ve !== void 0 && Kr === !0 && !Jr && Ar !== "button" && Se !== !0, os = Math.max(0, G.length - ur), ss = Zi ? Zi.offsetOf(os) : os * q, cs = S(null), ls = S(Ve);
2896
+ ls.current = Ve, b(() => {
2897
+ let e = cs.current;
2898
+ if (!as || e === null || typeof IntersectionObserver > "u") return;
2899
+ let t = new IntersectionObserver((e) => {
2900
+ e.some((e) => e.isIntersecting) && ls.current?.();
2901
+ });
2902
+ return t.observe(e), () => t.disconnect();
2854
2903
  }, [
2855
- Ve,
2856
- Pr,
2857
- Ir,
2858
- $n,
2859
- Se,
2904
+ as,
2860
2905
  G.length,
2861
- Bi.endIndex,
2862
- Ri,
2863
- Qn,
2864
- Oi,
2865
- K.height,
2866
- q
2906
+ ss
2867
2907
  ]);
2868
- let qo = () => A.current ? getComputedStyle(A.current).direction === "rtl" : !1, Jo = y(async (e) => {
2869
- let t = X ? Ot(Y, X) : [[e]], n = At(t, (e) => {
2870
- let t = Q(e.row), n = o.find((t) => t.id === e.column);
2871
- return t && n ? or(n, t) : "";
2908
+ let us = () => k.current ? getComputedStyle(k.current).direction === "rtl" : !1, ds = y(async (e) => {
2909
+ let t = X ? kt(Y, X) : [[e]], n = jt(t, (e) => {
2910
+ let t = Q(e.row), n = c.find((t) => t.id === e.column);
2911
+ return t && n ? Rr(n, t) : "";
2872
2912
  });
2873
- await ot(n, A.current?.ownerDocument) !== "refused" && Z(j("copied", { count: t.reduce((e, t) => e + t.length, 0) }));
2913
+ await ot(n, k.current?.ownerDocument) !== "refused" && Z(j("copied", { count: t.reduce((e, t) => e + t.length, 0) }));
2874
2914
  }, [
2875
2915
  X,
2876
2916
  Y,
2877
2917
  Q,
2878
- o,
2879
- or,
2918
+ c,
2919
+ Rr,
2880
2920
  Z,
2881
2921
  j
2882
- ]), Yo = y((e, t) => {
2922
+ ]), fs = y((e, t) => {
2883
2923
  if (e.defaultPrevented) return;
2884
- let n = Ro.current, r = e.target, i = e.currentTarget, a = r !== i, o = e.key, s = qo();
2924
+ let n = Xo.current, r = e.target, i = e.currentTarget, a = r !== i, o = e.key, s = us();
2885
2925
  if (n && E(n.cell, t)) {
2886
2926
  if (o === "Escape") {
2887
- e.preventDefault(), e.stopPropagation(), Vo();
2927
+ e.preventDefault(), e.stopPropagation(), $o();
2888
2928
  return;
2889
2929
  }
2890
2930
  if (o === "Enter") {
2891
- e.preventDefault(), $("keyboard", { move: Gn === "cell" ? "down" : "stay" });
2931
+ e.preventDefault(), $("keyboard", { move: rr === "cell" ? "down" : "stay" });
2892
2932
  return;
2893
2933
  }
2894
2934
  if (o === "Tab") {
2895
- Ho(t, e.shiftKey ? "previous" : "next") ? (e.preventDefault(), $("keyboard", { move: e.shiftKey ? "previous" : "next" })) : $("keyboard", { move: "stay" });
2935
+ es(t, e.shiftKey ? "previous" : "next") ? (e.preventDefault(), $("keyboard", { move: e.shiftKey ? "previous" : "next" })) : $("keyboard", { move: "stay" });
2896
2936
  return;
2897
2937
  }
2898
2938
  if (o === "F2") {
@@ -2903,7 +2943,7 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2903
2943
  }
2904
2944
  if (n && n.columns.includes(t.column) && n.cell.row === t.row) {
2905
2945
  if (o === "Escape") {
2906
- e.preventDefault(), Vo();
2946
+ e.preventDefault(), $o();
2907
2947
  return;
2908
2948
  }
2909
2949
  if (o === "Enter") {
@@ -2926,7 +2966,7 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2926
2966
  if (a && !r.matches("a[href], button, input[type=\"checkbox\"], input[type=\"radio\"], [role=\"switch\"], [role=\"button\"], [role=\"checkbox\"]")) {
2927
2967
  if (o === "Escape") e.preventDefault(), i.focus();
2928
2968
  else if (o === "Tab") {
2929
- let t = [...i.querySelectorAll(fn)];
2969
+ let t = [...i.querySelectorAll(pn)];
2930
2970
  if (t.length > 1) {
2931
2971
  let n = t[(t.indexOf(r) + (e.shiftKey ? -1 : 1) + t.length) % t.length];
2932
2972
  e.preventDefault(), n?.focus();
@@ -2934,7 +2974,7 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2934
2974
  }
2935
2975
  return;
2936
2976
  }
2937
- let c = t.row === ut, l = H.get(t.column), u = Or(t.row) ? Q(t.row) : void 0, d = {
2977
+ let c = t.row === ut, l = H.get(t.column), u = Mr(t.row) ? Q(t.row) : void 0, d = {
2938
2978
  ArrowUp: "up",
2939
2979
  ArrowDown: "down",
2940
2980
  ArrowLeft: s ? "end" : "start",
@@ -2945,18 +2985,18 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2945
2985
  PageDown: "pageDown"
2946
2986
  };
2947
2987
  if (c && l) {
2948
- if ((o === "ContextMenu" || o === "F10" && e.shiftKey) && !r.closest(hr)) {
2949
- e.preventDefault(), ka.current = Date.now(), Aa(t.column, i, i);
2988
+ if ((o === "ContextMenu" || o === "F10" && e.shiftKey) && !r.closest(vr)) {
2989
+ e.preventDefault(), Va.current = Date.now(), Ha(t.column, i, i);
2950
2990
  return;
2951
2991
  }
2952
2992
  if ((e.ctrlKey || e.metaKey) && e.shiftKey && (o === "ArrowLeft" || o === "ArrowRight")) {
2953
2993
  e.preventDefault();
2954
2994
  let n = o === "ArrowRight" !== s;
2955
- za(t.column, n ? ft : -ft, e);
2995
+ Za(t.column, n ? ft : -ft, e);
2956
2996
  return;
2957
2997
  }
2958
2998
  if ((e.ctrlKey || e.metaKey) && e.shiftKey && o === "Enter") {
2959
- e.preventDefault(), Ua(t.column, "keyboard", e);
2999
+ e.preventDefault(), to(t.column, "keyboard", e);
2960
3000
  return;
2961
3001
  }
2962
3002
  if (o === "F2" && !a) {
@@ -2967,56 +3007,56 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
2967
3007
  if (e.altKey && (o === "ArrowLeft" || o === "ArrowRight")) {
2968
3008
  e.preventDefault();
2969
3009
  let n = o === "ArrowRight" !== s;
2970
- Wa(t.column, n ? 1 : -1, e), fa.current = t;
3010
+ no(t.column, n ? 1 : -1, e), wa.current = t;
2971
3011
  return;
2972
3012
  }
2973
3013
  if ((e.ctrlKey || e.metaKey) && o === "Enter") {
2974
- e.preventDefault(), ja(), Ea(t.column);
3014
+ e.preventDefault(), Ua(), Ra(t.column);
2975
3015
  return;
2976
3016
  }
2977
3017
  if (o === "Enter" || o === " ") {
2978
3018
  if (a) return;
2979
- e.preventDefault(), ya(t.column, e.shiftKey, e, "keyboard");
3019
+ e.preventDefault(), ja(t.column, e.shiftKey, e, "keyboard");
2980
3020
  return;
2981
3021
  }
2982
3022
  }
2983
- if (Ct(t.row) && (o === "ArrowRight" || o === "ArrowLeft") && !e.shiftKey) {
2984
- let n = t.row.slice(lt.length), r = Xr === "all" || Xr.includes(n);
3023
+ if (wt(t.row) && (o === "ArrowRight" || o === "ArrowLeft") && !e.shiftKey) {
3024
+ let n = t.row.slice(lt.length), r = ci === "all" || ci.includes(n);
2985
3025
  if (o === "ArrowRight" !== s !== r) {
2986
- e.preventDefault(), Fo(n, e, "keyboard");
3026
+ e.preventDefault(), qo(n, e, "keyboard");
2987
3027
  return;
2988
3028
  }
2989
3029
  }
2990
3030
  if (u && e.altKey && (o === "ArrowUp" || o === "ArrowDown")) {
2991
- e.preventDefault(), go(t.row, o === "ArrowDown" ? 1 : -1, e), fa.current = t;
3031
+ e.preventDefault(), Oo(t.row, o === "ArrowDown" ? 1 : -1, e), wa.current = t;
2992
3032
  return;
2993
3033
  }
2994
- if (u && Oo !== null && t.column === Oo && (o === "ArrowRight" || o === "ArrowLeft") && !e.shiftKey) {
2995
- let n = ro.get(t.row), r = n !== void 0 && (n.childCount > 0 || O?.hasChildren?.(u) === !0), i = o === "ArrowRight" !== s;
3034
+ if (u && Bo !== null && t.column === Bo && (o === "ArrowRight" || o === "ArrowLeft") && !e.shiftKey) {
3035
+ let n = go.get(t.row), r = n !== void 0 && (n.childCount > 0 || A?.hasChildren?.(u) === !0), i = o === "ArrowRight" !== s;
2996
3036
  if (n && r && i !== n.open) {
2997
- e.preventDefault(), No(t.row, e, "keyboard");
3037
+ e.preventDefault(), Go(t.row, e, "keyboard");
2998
3038
  return;
2999
3039
  }
3000
3040
  if (n && !i && n.parent !== null) {
3001
- e.preventDefault(), ma({
3041
+ e.preventDefault(), Ea({
3002
3042
  row: n.parent,
3003
3043
  column: t.column
3004
3044
  }, "keyboard", e);
3005
3045
  return;
3006
3046
  }
3007
3047
  }
3008
- if (u && t.column === "__expander" && (o === "ArrowRight" || o === "ArrowLeft") && !e.shiftKey && Ar(u)) {
3009
- let n = To.has(t.row);
3048
+ if (u && t.column === "__expander" && (o === "ArrowRight" || o === "ArrowLeft") && !e.shiftKey && Hr(u)) {
3049
+ let n = Lo.has(t.row);
3010
3050
  if (o === "ArrowRight" !== s !== n) {
3011
- e.preventDefault(), Do(t.row, e, "keyboard");
3051
+ e.preventDefault(), zo(t.row, e, "keyboard");
3012
3052
  return;
3013
3053
  }
3014
3054
  }
3015
3055
  if (o === " " && e.shiftKey && u) {
3016
3056
  if (e.preventDefault(), M === "range") {
3017
- let n = Nt(Y, t.row);
3018
- n && Kr(n, "keyboard", e);
3019
- } else ta(t.row, {
3057
+ let n = Pt(Y, t.row);
3058
+ n && ii(n, "keyboard", e);
3059
+ } else pa(t.row, {
3020
3060
  range: !1,
3021
3061
  source: e,
3022
3062
  reason: "keyboard"
@@ -3025,8 +3065,8 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
3025
3065
  }
3026
3066
  if (o === " " && (e.ctrlKey || e.metaKey) && M === "range" && l) {
3027
3067
  e.preventDefault();
3028
- let n = _t(Y, t.column);
3029
- n && Kr(n, "keyboard", e);
3068
+ let n = vt(Y, t.column);
3069
+ n && ii(n, "keyboard", e);
3030
3070
  return;
3031
3071
  }
3032
3072
  if ((o === "a" || o === "A") && (e.ctrlKey || e.metaKey) && !a) {
@@ -3034,198 +3074,198 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
3034
3074
  e.preventDefault(), (it({
3035
3075
  action: "all",
3036
3076
  mode: "multiple",
3037
- selected: qi,
3077
+ selected: aa,
3038
3078
  keys: J
3039
- }).changed || Qi < J.length) && ea(J, "select", e);
3079
+ }).changed || ua < J.length) && fa(J, "select", e);
3040
3080
  return;
3041
3081
  }
3042
3082
  if (M === "range") {
3043
3083
  e.preventDefault();
3044
- let t = Rt(Y);
3045
- t && Kr(t, "keyboard", e);
3084
+ let t = zt(Y);
3085
+ t && ii(t, "keyboard", e);
3046
3086
  return;
3047
3087
  }
3048
3088
  }
3049
3089
  if ((o === "c" || o === "C") && (e.ctrlKey || e.metaKey) && !a) {
3050
3090
  let n = i.ownerDocument.getSelection();
3051
3091
  if (n && n.toString().length > 0) return;
3052
- e.preventDefault(), Jo(t);
3092
+ e.preventDefault(), ds(t);
3053
3093
  return;
3054
3094
  }
3055
- if (o === "Escape" && M === "range" && Gr) {
3056
- e.preventDefault(), Kr(null, "clear", e);
3095
+ if (o === "Escape" && M === "range" && ri) {
3096
+ e.preventDefault(), ii(null, "clear", e);
3057
3097
  return;
3058
3098
  }
3059
3099
  if (u && (l || t.column === dt) && (o === "Enter" || o === "F2")) {
3060
3100
  if (l !== void 0 && F(l.column, u) && !a) {
3061
- e.preventDefault(), zo(t);
3101
+ e.preventDefault(), Zo(t);
3062
3102
  return;
3063
3103
  }
3064
- let n = i.querySelectorAll(fn);
3104
+ let n = i.querySelectorAll(pn);
3065
3105
  if (!a && n.length > 0) {
3066
3106
  e.preventDefault(), n[0].focus();
3067
3107
  return;
3068
3108
  }
3069
- if (o === "Enter" && nr && !a) {
3070
- e.preventDefault(), Wo(t.row, "keyboard", e);
3109
+ if (o === "Enter" && Pr && !a) {
3110
+ e.preventDefault(), ns(t.row, "keyboard", e);
3071
3111
  return;
3072
3112
  }
3073
3113
  }
3074
3114
  if (u && l && !a && o.length === 1 && !e.ctrlKey && !e.metaKey && !e.altKey && (l.kind === "text" || l.kind === "number") && F(l.column, u)) {
3075
3115
  if (l.kind === "number" && !/[0-9.,-]/.test(o)) return;
3076
- e.preventDefault(), zo(t, o);
3116
+ e.preventDefault(), Zo(t, o);
3077
3117
  return;
3078
3118
  }
3079
3119
  let f = d[o];
3080
3120
  if (!f || a && (o === "ArrowLeft" || o === "ArrowRight" || o === "Home" || o === "End") && r.matches("input:not([type=\"checkbox\"]):not([type=\"radio\"]), textarea")) return;
3081
3121
  e.preventDefault();
3082
- let p = Ci(wt(Y, t, f));
3122
+ let p = Fi(Tt(Y, t, f));
3083
3123
  if (e.shiftKey && o.startsWith("Arrow")) {
3084
- if (M === "range" && Or(p.row)) {
3085
- let n = Gr?.anchor ?? t;
3086
- Kr({
3124
+ if (M === "range" && Mr(p.row)) {
3125
+ let n = ri?.anchor ?? t;
3126
+ ii({
3087
3127
  anchor: n,
3088
3128
  focus: p
3089
3129
  }, "keyboard", e);
3090
- } else M === "multiple" && (o === "ArrowUp" || o === "ArrowDown") && Or(p.row) && ta(p.row, {
3130
+ } else M === "multiple" && (o === "ArrowUp" || o === "ArrowDown") && Mr(p.row) && pa(p.row, {
3091
3131
  range: !0,
3092
3132
  source: e,
3093
3133
  reason: "keyboard"
3094
3134
  });
3095
3135
  }
3096
- E(p, t) || ma(p, "keyboard", e);
3136
+ E(p, t) || Ea(p, "keyboard", e);
3097
3137
  }, [
3098
- Vo,
3138
+ $o,
3099
3139
  $,
3100
- Gn,
3101
- Ho,
3140
+ rr,
3141
+ es,
3102
3142
  H,
3103
3143
  Q,
3104
- za,
3105
- Ua,
3106
- Wa,
3107
- ya,
3108
- Xr,
3109
- Fo,
3110
- Ar,
3111
- To,
3112
- Do,
3113
- Oo,
3114
- ro,
3115
- O,
3116
- No,
3144
+ Za,
3145
+ to,
3146
+ no,
3147
+ ja,
3148
+ ci,
3149
+ qo,
3150
+ Hr,
3151
+ Lo,
3152
+ zo,
3153
+ Bo,
3117
3154
  go,
3155
+ A,
3156
+ Go,
3157
+ Oo,
3118
3158
  M,
3119
3159
  Y,
3120
- Kr,
3121
- ta,
3122
- qi,
3160
+ ii,
3161
+ pa,
3162
+ aa,
3123
3163
  J,
3124
- Qi,
3125
- ea,
3126
- Jo,
3127
- Gr,
3164
+ ua,
3165
+ fa,
3166
+ ds,
3167
+ ri,
3128
3168
  F,
3129
- zo,
3130
- nr,
3131
- Wo,
3132
- ma,
3133
- Aa,
3134
- ja,
3135
- Ci
3136
- ]), Xo = S(""), Zo = S(-Infinity), Qo = y((e, t) => {
3137
- if (Xo.current = e.pointerType ?? "", e.button !== 0) return;
3138
- Qa.current = !1;
3139
- let n = Ro.current;
3140
- n && !E(n.cell, t) && !(n.cell.row === t.row && n.columns.includes(t.column)) && $("blur", { move: "stay" }), E(t, z) || qr(t, "pointer", e), M === "range" && Or(t.row) && (hn(e) || (ca(t, e.shiftKey, e), oa(!0)));
3169
+ Zo,
3170
+ Pr,
3171
+ ns,
3172
+ Ea,
3173
+ Ha,
3174
+ Ua,
3175
+ Fi
3176
+ ]), ps = S(""), ms = S(-Infinity), hs = y((e, t) => {
3177
+ if (ps.current = e.pointerType ?? "", e.button !== 0) return;
3178
+ uo.current = !1;
3179
+ let n = Xo.current;
3180
+ n && !E(n.cell, t) && !(n.cell.row === t.row && n.columns.includes(t.column)) && $("blur", { move: "stay" }), E(t, z) || ai(t, "pointer", e), M === "range" && Mr(t.row) && (gn(e) || (ba(t, e.shiftKey, e), va(!0)));
3141
3181
  }, [
3142
3182
  $,
3143
3183
  z,
3144
- qr,
3184
+ ai,
3145
3185
  M,
3146
- ca
3147
- ]), $o = y((e, t) => {
3148
- aa && e.buttons === 1 && la(t, e);
3149
- }, [aa, la]);
3186
+ ba
3187
+ ]), gs = y((e, t) => {
3188
+ _a && e.buttons === 1 && xa(t, e);
3189
+ }, [_a, xa]);
3150
3190
  b(() => {
3151
- if (!aa) return;
3152
- let e = () => oa(!1), t = A.current?.ownerDocument ?? document;
3191
+ if (!_a) return;
3192
+ let e = () => va(!1), t = k.current?.ownerDocument ?? document;
3153
3193
  return t.addEventListener("pointerup", e), t.addEventListener("pointercancel", e), () => {
3154
3194
  t.removeEventListener("pointerup", e), t.removeEventListener("pointercancel", e);
3155
3195
  };
3156
- }, [aa]);
3157
- let es = y((e, t) => {
3158
- let n = Xo.current;
3159
- if (Xo.current = "", Qa.current) {
3160
- Qa.current = !1;
3196
+ }, [_a]);
3197
+ let _s = y((e, t) => {
3198
+ let n = ps.current;
3199
+ if (ps.current = "", uo.current) {
3200
+ uo.current = !1;
3161
3201
  return;
3162
3202
  }
3163
- if (hn(e)) return;
3203
+ if (gn(e)) return;
3164
3204
  if (t.row === ut && H.get(t.column)?.sortable) {
3165
- ya(t.column, e.shiftKey, e, "pointer");
3205
+ ja(t.column, e.shiftKey, e, "pointer");
3166
3206
  return;
3167
3207
  }
3168
- if (Ct(t.row)) {
3169
- Fo(t.row.slice(lt.length), e);
3208
+ if (wt(t.row)) {
3209
+ qo(t.row.slice(lt.length), e);
3170
3210
  return;
3171
3211
  }
3172
- if (!Or(t.row)) return;
3173
- M === "single" && !sr.has(t.row) && ta(t.row, {
3212
+ if (!Mr(t.row)) return;
3213
+ M === "single" && !zr.has(t.row) && pa(t.row, {
3174
3214
  range: !1,
3175
3215
  source: e
3176
3216
  });
3177
- let r = Ro.current, i = r !== null && r.cell.row === t.row && r.columns.includes(t.column);
3178
- nr && (n === "touch" || n === "pen") && !i && (Zo.current = Date.now(), Wo(t.row, "pointer", e));
3217
+ let r = Xo.current, i = r !== null && r.cell.row === t.row && r.columns.includes(t.column);
3218
+ Pr && (n === "touch" || n === "pen") && !i && (ms.current = Date.now(), ns(t.row, "pointer", e));
3179
3219
  }, [
3180
3220
  H,
3181
- ya,
3182
- Fo,
3221
+ ja,
3222
+ qo,
3183
3223
  M,
3184
- sr,
3185
- ta,
3186
- nr,
3187
- Wo
3188
- ]), ts = y((e, t) => {
3189
- if (hn(e) || Date.now() - Zo.current < _r) return;
3190
- let n = Q(t.row), r = o.find((e) => e.id === t.column);
3224
+ zr,
3225
+ pa,
3226
+ Pr,
3227
+ ns
3228
+ ]), vs = y((e, t) => {
3229
+ if (gn(e) || Date.now() - ms.current < br) return;
3230
+ let n = Q(t.row), r = c.find((e) => e.id === t.column);
3191
3231
  if (n) {
3192
- if (r && F(r, n) && !nr) {
3193
- zo(t);
3232
+ if (r && F(r, n) && !Pr) {
3233
+ Zo(t);
3194
3234
  return;
3195
3235
  }
3196
- nr ? Wo(t.row, "pointer", e) : r && F(r, n) && zo(t);
3236
+ Pr ? ns(t.row, "pointer", e) : r && F(r, n) && Zo(t);
3197
3237
  }
3198
3238
  }, [
3199
3239
  Q,
3200
- o,
3240
+ c,
3201
3241
  F,
3202
- nr,
3203
- zo,
3204
- Wo
3205
- ]), ns = y((e) => {
3206
- da(!0), E(e, z) || qr(e, "programmatic");
3207
- }, [z, qr]), rs = y(() => {}, []), is = y((e) => {
3242
+ Pr,
3243
+ Zo,
3244
+ ns
3245
+ ]), ys = y((e) => {
3246
+ Ca(!0), E(e, z) || ai(e, "programmatic");
3247
+ }, [z, ai]), bs = y(() => {}, []), xs = y((e) => {
3208
3248
  let t = e.relatedTarget;
3209
3249
  if (!t || !e.currentTarget.contains(t)) {
3210
- da(!1);
3211
- let e = Ro.current;
3250
+ Ca(!1);
3251
+ let e = Xo.current;
3212
3252
  e && e.status === "editing" && $("blur", { move: "stay" });
3213
3253
  }
3214
- }, [$]), as = y((e) => {
3215
- let n = t?.[e.column.id];
3216
- return n ? n(e) : Pt ? Pt(e) : Vn(e);
3217
- }, [t, Pt]), os = y((e) => {
3218
- let t = re?.[e.column.id];
3219
- return t ? t(e) : Yt ? Yt(e) : Wn(e, j, N);
3254
+ }, [$]), Ss = y((e) => {
3255
+ let t = Pn.current.cellRenderers?.[e.column.id];
3256
+ return t ? t(e) : Fn ? Fn(e) : Wn(e);
3257
+ }, [Gn, Fn]), Cs = y((e) => {
3258
+ let t = Pn.current.editorRenderers?.[e.column.id];
3259
+ return t ? t(e) : zn ? zn(e) : Jn(e, j, N);
3220
3260
  }, [
3221
- re,
3222
- Yt,
3261
+ Kn,
3262
+ zn,
3223
3263
  j,
3224
3264
  N
3225
- ]), ss = y((e, t = "nearest") => {
3226
- let n = G.findIndex((t) => t.key === e), r = Mn.current;
3265
+ ]), ws = y((e, t = "nearest") => {
3266
+ let n = G.findIndex((t) => t.key === e), r = Nn.current;
3227
3267
  if (n === -1 || !r) return;
3228
- let i = zi ? zi.offsetOf(n) : n * q, a = r.querySelector("[data-part=\"head\"]")?.offsetHeight ?? 0, o = i;
3268
+ let i = Zi ? Zi.offsetOf(n) : n * q, a = r.querySelector("[data-part=\"head\"]")?.offsetHeight ?? 0, o = i;
3229
3269
  if (t === "center") o = i - K.height / 2 + q;
3230
3270
  else if (t === "end") o = i - K.height + q + a;
3231
3271
  else if (t === "nearest") {
@@ -3233,365 +3273,365 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
3233
3273
  if (i >= e && i + q <= t) return;
3234
3274
  o = i < e ? i : i - K.height + q + a;
3235
3275
  }
3236
- r.scrollTo({ top: Math.max(0, o) }), Ri && Ui([e]);
3276
+ r.scrollTo({ top: Math.max(0, o) }), Xi && ta([e]);
3237
3277
  }, [
3238
3278
  G,
3239
- zi,
3279
+ Zi,
3240
3280
  q,
3241
3281
  K.height,
3242
- Ri
3243
- ]), cs = y((e) => {
3244
- let t = Mn.current, n = H.get(e);
3282
+ Xi
3283
+ ]), Ts = y((e) => {
3284
+ let t = Nn.current, n = H.get(e);
3245
3285
  if (!t || !n || n.pinned) return;
3246
- let r = ti.reduce((e, t) => e + t, 0);
3286
+ let r = pi.reduce((e, t) => e + t, 0);
3247
3287
  for (let t of V) {
3248
3288
  if (t.id === e) break;
3249
3289
  (t.pinned === null || t.pinned === "start") && (r += t.width);
3250
3290
  }
3251
- let i = V.filter((e) => e.pinned === "start").reduce((e, t) => e + t.width, 0) + ti.reduce((e, t) => e + t, 0), a = V.filter((e) => e.pinned === "end").reduce((e, t) => e + t.width, 0), o = Math.abs(t.scrollLeft);
3291
+ let i = V.filter((e) => e.pinned === "start").reduce((e, t) => e + t.width, 0) + pi.reduce((e, t) => e + t, 0), a = V.filter((e) => e.pinned === "end").reduce((e, t) => e + t.width, 0), o = Math.abs(t.scrollLeft);
3252
3292
  r < o + i ? t.scrollTo({ left: r - i }) : r + n.width > o + K.width - a && t.scrollTo({ left: r + n.width - K.width + a });
3253
3293
  }, [
3254
3294
  H,
3255
- ti,
3295
+ pi,
3256
3296
  V,
3257
3297
  K.width
3258
- ]), ls = y((e = {}) => {
3259
- let { filename: t, rows: n, columns: r, ...i } = e, a = zr === "client" ? vi.rows : L, s = n === "selected" ? a.filter((e) => Ji.has(P(e))) : a, c = r === "all" ? o : V.map((e) => e.column);
3260
- return Lt(s, c, {
3298
+ ]), Es = y((e = {}) => {
3299
+ let { filename: t, rows: n, columns: r, ...i } = e, a = Zr === "client" ? Ai.rows : L, o = n === "selected" ? a.filter((e) => oa.has(P(e))) : a, s = r === "all" ? c : V.map((e) => e.column);
3300
+ return Rt(o, s, {
3261
3301
  locale: N,
3262
- timeZone: xn,
3302
+ timeZone: bn,
3263
3303
  ...i,
3264
- booleans: i.booleans ?? ar.booleans
3304
+ booleans: i.booleans ?? Lr.booleans
3265
3305
  });
3266
3306
  }, [
3267
- zr,
3268
- vi.rows,
3307
+ Zr,
3308
+ Ai.rows,
3269
3309
  L,
3270
- Ji,
3310
+ oa,
3271
3311
  P,
3272
- o,
3312
+ c,
3273
3313
  V,
3274
3314
  N,
3275
- xn,
3276
- ar.booleans
3315
+ bn,
3316
+ Lr.booleans
3277
3317
  ]);
3278
3318
  ze(he, () => ({
3279
- focusCell: (e) => ma(e, "programmatic"),
3280
- scrollToRow: ss,
3281
- scrollToColumn: cs,
3319
+ focusCell: (e) => Ea(e, "programmatic"),
3320
+ scrollToRow: ws,
3321
+ scrollToColumn: Ts,
3282
3322
  scrollToCell: (e) => {
3283
- ss(e.row), cs(e.column);
3323
+ ws(e.row), Ts(e.column);
3284
3324
  },
3285
3325
  startEdit: (e) => {
3286
- ma(e, "programmatic"), zo(e);
3326
+ Ea(e, "programmatic"), Zo(e);
3287
3327
  },
3288
- stopEdit: (e) => e?.commit === !1 ? Vo() : $("programmatic"),
3289
- autofit: (e) => Ua(e ?? null, "programmatic"),
3328
+ stopEdit: (e) => e?.commit === !1 ? $o() : $("programmatic"),
3329
+ autofit: (e) => to(e ?? null, "programmatic"),
3290
3330
  getOutOfSpace: () => B,
3291
- getVisibleRows: () => zr === "client" ? vi.rows : L,
3292
- toCsv: ls,
3293
- reload: Mr.reload,
3331
+ getVisibleRows: () => Zr === "client" ? Ai.rows : L,
3332
+ toCsv: Es,
3333
+ reload: Wr.reload,
3294
3334
  exportCsv: (e = {}) => {
3295
- let t = ls(e), n = A.current?.ownerDocument ?? document, r = URL.createObjectURL(new Blob([t], { type: "text/csv;charset=utf-8" })), i = n.createElement("a");
3335
+ let t = Es(e), n = k.current?.ownerDocument ?? document, r = URL.createObjectURL(new Blob([t], { type: "text/csv;charset=utf-8" })), i = n.createElement("a");
3296
3336
  i.href = r, i.download = e.filename ?? "export.csv", i.click(), URL.revokeObjectURL(r);
3297
3337
  },
3298
- selectAll: () => ea(J, "programmatic", void 0),
3299
- clearSelection: () => ea([], "programmatic", void 0),
3338
+ selectAll: () => fa(J, "programmatic", void 0),
3339
+ clearSelection: () => fa([], "programmatic", void 0),
3300
3340
  get element() {
3301
- return A.current;
3341
+ return k.current;
3302
3342
  }
3303
3343
  }), [
3304
- ma,
3305
- ss,
3306
- cs,
3307
- zo,
3308
- Vo,
3344
+ Ea,
3345
+ ws,
3346
+ Ts,
3347
+ Zo,
3348
+ $o,
3309
3349
  $,
3310
- Ua,
3350
+ to,
3311
3351
  B,
3312
- zr,
3313
- vi.rows,
3352
+ Zr,
3353
+ Ai.rows,
3314
3354
  L,
3315
- ls,
3316
- Mr.reload,
3317
- ea,
3355
+ Es,
3356
+ Wr.reload,
3357
+ fa,
3318
3358
  J
3319
3359
  ]);
3320
- let us = y((e) => {
3321
- A.current = e, typeof Et == "function" ? Et(e) : Et && (Et.current = e);
3322
- }, [Et]), ds = x(() => X ? `${X.rowEnd - X.rowStart + 1} × ${X.columnEnd - X.columnStart + 1}` : null, [X]), fs = S(null), ps = Fr === "initial" || Fr === !0 && fs.current !== "empty";
3323
- !Ir && !Lr && (fs.current = L.length > 0 ? "rows" : "empty");
3324
- let ms = Lr ? "error" : ps && L.length === 0 ? "loading" : G.length > 0 ? "rows" : I.filter || I.search.trim() ? "no-results" : "empty", hs = x(() => {
3360
+ let Ds = y((e) => {
3361
+ k.current = e, typeof xt == "function" ? xt(e) : xt && (xt.current = e);
3362
+ }, [xt]), Os = x(() => X ? `${X.rowEnd - X.rowStart + 1} × ${X.columnEnd - X.columnStart + 1}` : null, [X]), ks = S(null), As = qr === "initial" || qr === !0 && ks.current !== "empty";
3363
+ !Jr && !Yr && (ks.current = L.length > 0 ? "rows" : "empty");
3364
+ let js = Yr ? "error" : As && L.length === 0 ? "loading" : G.length > 0 ? "rows" : I.filter || I.search.trim() ? "no-results" : "empty", Ms = x(() => {
3325
3365
  let e = I.page?.size;
3326
- return K.height === 0 ? er : Math.max(1, Math.min(e ?? Infinity, Math.ceil(K.height / q)));
3366
+ return K.height === 0 ? Nr : Math.max(1, Math.min(e ?? Infinity, Math.ceil(K.height / q)));
3327
3367
  }, [
3328
3368
  I.page?.size,
3329
3369
  K.height,
3330
3370
  q,
3331
- er
3332
- ]), gs = x(() => z ?? {
3371
+ Nr
3372
+ ]), Ns = x(() => z ?? {
3333
3373
  row: ut,
3334
3374
  column: U[0] ?? ""
3335
- }, [z, U]), _s = x(() => ({
3336
- id: jn,
3375
+ }, [z, U]), Ps = x(() => ({
3376
+ id: Mn,
3337
3377
  t: j,
3338
3378
  locale: N,
3339
- booleans: ar.booleans,
3340
- timeZone: xn,
3341
- columns: o,
3379
+ booleans: Lr.booleans,
3380
+ timeZone: bn,
3381
+ columns: c,
3342
3382
  resolved: V,
3343
3383
  resolvedById: H,
3344
3384
  columnIds: U,
3345
- mountedColumns: Ki,
3346
- columnsWindowed: Gi,
3347
- popinColumns: ui,
3348
- popinAggregated: bi,
3349
- popinIndex: mi,
3350
- hasPopinCell: Si,
3385
+ mountedColumns: ia,
3386
+ columnsWindowed: ra,
3387
+ popinColumns: Si,
3388
+ popinAggregated: Mi,
3389
+ popinIndex: Ei,
3390
+ hasPopinCell: Pi,
3351
3391
  query: I,
3352
3392
  nodes: G,
3353
- total: yi,
3393
+ total: ji,
3354
3394
  selectionMode: M,
3355
- editMode: Gn,
3356
- filterRow: Kn,
3357
- activatable: nr,
3395
+ editMode: rr,
3396
+ filterRow: ir,
3397
+ activatable: Pr,
3358
3398
  rowKeyOf: P,
3359
- textOf: or,
3399
+ textOf: Rr,
3360
3400
  valueOf: gt,
3361
3401
  isEditable: F,
3362
- anyEditable: kr,
3363
- isDisabled: Er,
3364
- isExpandable: Ar,
3402
+ anyEditable: Vr,
3403
+ isDisabled: Br,
3404
+ isExpandable: Hr,
3365
3405
  current: z,
3366
- tabStop: gs,
3367
- focused: ua,
3368
- setCurrent: ma,
3369
- isSelected: Xi,
3370
- selectedCount: Qi,
3371
- toggleSelected: ta,
3372
- toggleAll: na,
3373
- allState: $i,
3406
+ tabStop: Ns,
3407
+ focused: Sa,
3408
+ setCurrent: Ea,
3409
+ isSelected: ca,
3410
+ selectedCount: ua,
3411
+ toggleSelected: pa,
3412
+ toggleAll: ma,
3413
+ allState: da,
3374
3414
  selectableCount: J.length,
3375
3415
  rangeBounds: X,
3376
- rangeInfo: ia,
3377
- changedOf: wo,
3378
- beginRange: ca,
3379
- extendRange: la,
3380
- rangeDragging: aa,
3381
- isExpanded: Eo,
3382
- toggleExpanded: Do,
3383
- toggleBranch: No,
3384
- treeColumn: Oo,
3385
- hasChildren: Mo,
3386
- rowsReorderable: io,
3387
- attachRowDraggable: mo,
3388
- rowLabelOf: uo,
3389
- isLoadingChildren: jo,
3390
- toggleGroup: Fo,
3391
- sortOf: ga,
3392
- pressSort: ya,
3393
- setSort: ba,
3394
- filterOf: xa,
3395
- setFilter: Sa,
3396
- filterOpen: Ca,
3397
- setFilterOpen: wa,
3398
- menuOpen: Ta,
3399
- setMenuOpen: Ea,
3400
- menuAnchor: Da,
3401
- anchorToButton: ja,
3402
- onHeaderContextMenu: Ma,
3403
- filterDebounce: Zn,
3404
- countsFor: Pa,
3405
- pin: Ia,
3406
- hide: La,
3407
- resizeBy: za,
3408
- resizeTo: Ra,
3409
- autofit: Ua,
3410
- moveColumn: Wa,
3411
- resizing: Ga,
3412
- setResizing: Ka,
3413
- dragging: qa.dragging,
3414
- dropTarget: qa.target,
3415
- draggingRow: ao.dragging,
3416
- dropOffset: qa.offset,
3417
- attachDraggable: to,
3416
+ rangeInfo: ga,
3417
+ changedOf: Io,
3418
+ beginRange: ba,
3419
+ extendRange: xa,
3420
+ rangeDragging: _a,
3421
+ isExpanded: Ro,
3422
+ toggleExpanded: zo,
3423
+ toggleBranch: Go,
3424
+ treeColumn: Bo,
3425
+ hasChildren: Wo,
3426
+ rowsReorderable: _o,
3427
+ attachRowDraggable: Eo,
3428
+ rowLabelOf: Co,
3429
+ isLoadingChildren: Uo,
3430
+ toggleGroup: qo,
3431
+ sortOf: Oa,
3432
+ pressSort: ja,
3433
+ setSort: Ma,
3434
+ filterOf: Na,
3435
+ setFilter: Pa,
3436
+ filterOpen: Fa,
3437
+ setFilterOpen: Ia,
3438
+ menuOpen: La,
3439
+ setMenuOpen: Ra,
3440
+ menuAnchor: za,
3441
+ anchorToButton: Ua,
3442
+ onHeaderContextMenu: Wa,
3443
+ filterDebounce: lr,
3444
+ countsFor: Ka,
3445
+ pin: Ja,
3446
+ hide: Ya,
3447
+ resizeBy: Za,
3448
+ resizeTo: Xa,
3449
+ autofit: to,
3450
+ moveColumn: no,
3451
+ resizing: ro,
3452
+ setResizing: io,
3453
+ dragging: ao.dragging,
3454
+ dropTarget: ao.target,
3455
+ draggingRow: vo.dragging,
3456
+ dropOffset: ao.offset,
3457
+ attachDraggable: mo,
3418
3458
  onManageColumns: He,
3419
- edit: Io,
3420
- startEdit: zo,
3421
- setDraft: Bo,
3459
+ edit: Jo,
3460
+ startEdit: Zo,
3461
+ setDraft: Qo,
3422
3462
  commitEdit: $,
3423
- cancelEdit: Vo,
3424
- activate: Wo,
3425
- renderCellContent: as,
3426
- renderEditorContent: os,
3427
- renderHeaderContent: $t,
3428
- renderDetail: Ft,
3429
- renderGroup: Qt,
3463
+ cancelEdit: $o,
3464
+ activate: ns,
3465
+ renderCellContent: Ss,
3466
+ renderEditorContent: Cs,
3467
+ renderHeaderContent: Hn,
3468
+ renderDetail: Rn,
3469
+ renderGroup: Vn,
3430
3470
  renderFilterOperand: Zt,
3431
- onCellPointerDown: Qo,
3432
- onCellPointerEnter: $o,
3433
- onCellClick: es,
3434
- onCellDoubleClick: ts,
3435
- onCellKeyDown: Yo,
3436
- onCellFocus: ns,
3437
- onCellBlur: rs,
3471
+ onCellPointerDown: hs,
3472
+ onCellPointerEnter: gs,
3473
+ onCellClick: _s,
3474
+ onCellDoubleClick: vs,
3475
+ onCellKeyDown: fs,
3476
+ onCellFocus: ys,
3477
+ onCellBlur: bs,
3438
3478
  announce: Z,
3439
- detailId: (e) => `${jn}detail-${e}`,
3440
- rangeSummary: ds
3479
+ detailId: (e) => `${Mn}detail-${e}`,
3480
+ rangeSummary: Os
3441
3481
  }), [
3442
- jn,
3482
+ Mn,
3443
3483
  j,
3444
3484
  N,
3445
- ar.booleans,
3446
- xn,
3447
- o,
3485
+ Lr.booleans,
3486
+ bn,
3487
+ c,
3448
3488
  V,
3449
3489
  H,
3450
3490
  U,
3451
- Ki,
3452
- Gi,
3453
- ui,
3454
- bi,
3455
- mi,
3491
+ ia,
3492
+ ra,
3456
3493
  Si,
3494
+ Mi,
3495
+ Ei,
3496
+ Pi,
3457
3497
  I,
3458
3498
  G,
3459
- yi,
3499
+ ji,
3460
3500
  M,
3461
- Gn,
3462
- Kn,
3463
- nr,
3501
+ rr,
3502
+ ir,
3503
+ Pr,
3464
3504
  P,
3465
- or,
3505
+ Rr,
3466
3506
  F,
3467
- kr,
3468
- Er,
3469
- Ar,
3507
+ Vr,
3508
+ Br,
3509
+ Hr,
3470
3510
  z,
3471
- gs,
3511
+ Ns,
3512
+ Sa,
3513
+ Ea,
3514
+ ca,
3472
3515
  ua,
3516
+ pa,
3473
3517
  ma,
3474
- Xi,
3475
- Qi,
3476
- ta,
3477
- na,
3478
- $i,
3518
+ da,
3479
3519
  J.length,
3480
3520
  X,
3481
- ia,
3482
- wo,
3483
- ca,
3484
- la,
3485
- aa,
3486
- Eo,
3487
- Do,
3488
- No,
3489
- Oo,
3490
- Mo,
3491
- io,
3492
- mo,
3493
- uo,
3494
- jo,
3495
- Fo,
3496
3521
  ga,
3497
- ya,
3522
+ Io,
3498
3523
  ba,
3499
3524
  xa,
3500
- Sa,
3501
- Ca,
3502
- Ta,
3503
- Da,
3525
+ _a,
3526
+ Ro,
3527
+ zo,
3528
+ Go,
3529
+ Bo,
3530
+ Wo,
3531
+ _o,
3532
+ Eo,
3533
+ Co,
3534
+ Uo,
3535
+ qo,
3536
+ Oa,
3504
3537
  ja,
3505
3538
  Ma,
3506
- Zn,
3539
+ Na,
3507
3540
  Pa,
3508
- Ia,
3541
+ Fa,
3509
3542
  La,
3510
3543
  za,
3511
- Ra,
3512
3544
  Ua,
3513
3545
  Wa,
3514
- Ga,
3515
- qa,
3516
- ao.dragging,
3546
+ lr,
3547
+ Ka,
3548
+ Ja,
3549
+ Ya,
3550
+ Za,
3551
+ Xa,
3517
3552
  to,
3553
+ no,
3554
+ ro,
3555
+ ao,
3556
+ vo.dragging,
3557
+ mo,
3518
3558
  He,
3519
- Io,
3520
- zo,
3521
- Bo,
3522
- $,
3523
- Vo,
3524
- Wo,
3525
- as,
3526
- os,
3527
- $t,
3528
- Ft,
3529
- Qt,
3530
- Zt,
3559
+ Jo,
3560
+ Zo,
3531
3561
  Qo,
3562
+ $,
3532
3563
  $o,
3533
- es,
3534
- ts,
3535
- Yo,
3536
3564
  ns,
3537
- rs,
3565
+ Ss,
3566
+ Cs,
3567
+ Hn,
3568
+ Rn,
3569
+ Vn,
3570
+ Zt,
3571
+ hs,
3572
+ gs,
3573
+ _s,
3574
+ vs,
3575
+ fs,
3576
+ ys,
3577
+ bs,
3538
3578
  Z,
3539
- ds
3540
- ]), [vs] = C(() => bn(_s));
3541
- vs.set(_s), Be(() => vs.publish(), [_s, vs]);
3542
- let ys = {
3579
+ Os
3580
+ ]), [Fs] = C(() => xn(Ps));
3581
+ Fs.set(Ps), Be(() => Fs.publish(), [Ps, Fs]);
3582
+ let Is = {
3543
3583
  ...yn,
3544
- "--slotted-data-grid-template": gi,
3584
+ "--slotted-data-grid-template": Oi,
3545
3585
  ..._e === void 0 ? {} : { "--slotted-data-grid-block-size": typeof _e == "number" ? `${_e}px` : _e },
3546
- ...typeof Jn == "number" ? { "--slotted-data-grid-row-block-size": `${Jn}px` } : {},
3547
- ..._o > 0 ? { "--slotted-data-grid-changed-duration": `${_o}ms` } : {},
3548
- ...di ? { "--slotted-data-grid-leading": `${ni}px` } : {},
3586
+ ...typeof or == "number" ? { "--slotted-data-grid-row-block-size": `${or}px` } : {},
3587
+ ...ko > 0 ? { "--slotted-data-grid-changed-duration": `${ko}ms` } : {},
3588
+ ...Ci ? { "--slotted-data-grid-leading": `${mi}px` } : {},
3549
3589
  ...K.width > 0 ? { "--slotted-data-grid-viewport": `${K.width}px` } : {}
3550
- }, bs = Ri ? {
3551
- "--slotted-data-grid-window-total": `${Bi.totalSize}px`,
3552
- "--slotted-data-grid-window-start": `${Bi.startOffset}px`
3553
- } : void 0, xs = (() => {
3590
+ }, Ls = Xi ? {
3591
+ "--slotted-data-grid-window-total": `${Qi.totalSize}px`,
3592
+ "--slotted-data-grid-window-start": `${Qi.startOffset}px`
3593
+ } : void 0, Rs = (() => {
3554
3594
  if (sn === !1 || !I.page || G.length === 0) return null;
3555
- let e = ("index" in I.page ? I.page.index * I.page.size : 0) + 1, t = e + (zr === "client" ? G.filter((e) => e.kind === "row").length : L.length) - 1;
3556
- return yi === null || yi < 0 ? j("rangeUnknown", {
3595
+ let e = ("index" in I.page ? I.page.index * I.page.size : 0) + 1, t = e + (Zr === "client" ? G.filter((e) => e.kind === "row").length : L.length) - 1;
3596
+ return ji === null || ji < 0 ? j("rangeUnknown", {
3557
3597
  start: e,
3558
3598
  end: t
3559
3599
  }) : j("range", {
3560
3600
  start: e,
3561
3601
  end: t,
3562
- total: yi
3602
+ total: ji
3563
3603
  });
3564
- })(), Ss = !Pr || !Ve ? null : $n === "scroll" && Se !== !0 ? Ir ? /* @__PURE__ */ w("span", {
3604
+ })(), zs = !Kr || !Ve ? null : Ar === "scroll" && Se !== !0 ? Jr ? /* @__PURE__ */ w("span", {
3565
3605
  "data-loading-more": "",
3566
3606
  role: "status",
3567
3607
  children: j("loadingMore")
3568
3608
  }) : null : /* @__PURE__ */ w("div", { children: /* @__PURE__ */ w(l, {
3569
- disabled: Ir,
3609
+ disabled: Jr,
3570
3610
  onClick: () => Ve(),
3571
3611
  size: "sm",
3572
3612
  tone: "secondary",
3573
3613
  variant: "outline",
3574
3614
  children: j(Se === !0 ? "retry" : "loadMore")
3575
- }) }), Cs = (() => {
3576
- if (ms === "rows" || ms === "loading") return null;
3577
- let e = ms;
3615
+ }) }), Bs = (() => {
3616
+ if (js === "rows" || js === "loading") return null;
3617
+ let e = js;
3578
3618
  if (Xt) return Xt(e);
3579
3619
  let t = j(e === "error" ? "error" : e === "no-results" ? "noResults" : "empty");
3580
3620
  return /* @__PURE__ */ T(le, {
3581
3621
  reach: "section",
3582
3622
  status: e,
3583
3623
  tabIndex: -1,
3584
- children: [/* @__PURE__ */ T(ce, { children: [/* @__PURE__ */ w(se, { children: t }), e === "error" && Lr ? /* @__PURE__ */ w(ae, { children: Lr }) : null] }), e === "no-results" || e === "error" && Rr ? /* @__PURE__ */ w(oe, { children: e === "no-results" ? /* @__PURE__ */ w(l, {
3624
+ children: [/* @__PURE__ */ T(ce, { children: [/* @__PURE__ */ w(se, { children: t }), e === "error" && Yr ? /* @__PURE__ */ w(ae, { children: Yr }) : null] }), e === "no-results" || e === "error" && Xr ? /* @__PURE__ */ w(oe, { children: e === "no-results" ? /* @__PURE__ */ w(l, {
3585
3625
  onClick: (e) => {
3586
- let t = Kt(I);
3587
- jr(t.query, "clear", e, { change: t.change });
3626
+ let t = qt(I);
3627
+ Ur(t.query, "clear", e, { change: t.change });
3588
3628
  },
3589
3629
  size: "sm",
3590
3630
  tone: "secondary",
3591
3631
  variant: "outline",
3592
3632
  children: j("clearFilters")
3593
3633
  }) : /* @__PURE__ */ w(l, {
3594
- onClick: () => Rr?.(),
3634
+ onClick: () => Xr?.(),
3595
3635
  size: "sm",
3596
3636
  tone: "secondary",
3597
3637
  variant: "outline",
@@ -3599,131 +3639,135 @@ function Er({ activatable: e, cellRenderers: t, columnGroups: n, columnOverflow:
3599
3639
  }) }) : null]
3600
3640
  });
3601
3641
  })();
3602
- return /* @__PURE__ */ w(_n.Provider, {
3603
- value: vs.grid,
3604
- children: /* @__PURE__ */ w(Cn.Provider, {
3605
- value: vs,
3642
+ return /* @__PURE__ */ w(vn.Provider, {
3643
+ value: Fs.grid,
3644
+ children: /* @__PURE__ */ w(Tn.Provider, {
3645
+ value: Fs,
3606
3646
  children: /* @__PURE__ */ T("div", {
3607
- ...An,
3608
- "aria-busy": Ir && ms !== "loading" ? !0 : void 0,
3609
- "aria-colcount": pi,
3610
- "aria-label": An["aria-label"] ?? (ye ? void 0 : j("grid")),
3647
+ ...jn,
3648
+ "aria-busy": Jr && js !== "loading" ? !0 : void 0,
3649
+ "aria-colcount": Ti,
3650
+ "aria-label": jn["aria-label"] ?? (ye ? void 0 : j("grid")),
3611
3651
  "aria-labelledby": ye,
3612
3652
  "aria-multiselectable": M === "multiple" || M === "range" || void 0,
3613
- "aria-rowcount": (yi === null ? -1 : yi) + W.top.length + W.bottom.length + wi + +!!xi,
3653
+ "aria-rowcount": (ji === null ? -1 : ji) + W.top.length + W.bottom.length + Ii + +!!Ni,
3614
3654
  "data-part": "root",
3615
3655
  "data-part-root": "",
3616
- "data-popin": di ? B.popin.length : void 0,
3656
+ "data-popin": Ci ? B.popin.length : void 0,
3617
3657
  "data-narrow": K.width > 0 && K.width < Ke ? "" : void 0,
3618
- "data-rows": Li ? "auto" : "fixed",
3658
+ "data-rows": Yi ? "auto" : "fixed",
3619
3659
  "data-slotted-density": d ?? void 0,
3620
3660
  "data-ui": "data-grid",
3621
3661
  "data-ui-data-grid": "",
3622
- "data-variant": Rn,
3623
- onBlur: is,
3662
+ "data-variant": Qn,
3663
+ onBlur: xs,
3624
3664
  onKeyDown: (e) => {
3625
- Le?.(e), !e.defaultPrevented && (Ya.current?.handleKeydown(e.nativeEvent) || so.current?.handleKeydown(e.nativeEvent));
3665
+ Le?.(e), !e.defaultPrevented && (so.current?.handleKeydown(e.nativeEvent) || bo.current?.handleKeydown(e.nativeEvent));
3626
3666
  },
3627
- ref: us,
3628
- role: O ? "treegrid" : "grid",
3629
- style: ys,
3630
- ...zn ? { "data-striped": "" } : {},
3631
- ...Hn ? { "data-sticky-header": "" } : {},
3632
- ...Kn ? { "data-filter-row": "" } : {},
3633
- ...Un === "page" ? { "data-sticky-to": "page" } : {},
3667
+ ref: Ds,
3668
+ role: A ? "treegrid" : "grid",
3669
+ style: Is,
3670
+ ...$n ? { "data-striped": "" } : {},
3671
+ ...er ? { "data-sticky-header": "" } : {},
3672
+ ...ir ? { "data-filter-row": "" } : {},
3673
+ ...tr === "page" ? { "data-sticky-to": "page" } : {},
3634
3674
  ...M === "none" ? {} : { "data-selection": M },
3635
3675
  children: [/* @__PURE__ */ T("div", {
3636
3676
  "data-part": "scroll",
3637
3677
  "data-part-scroll": "",
3638
- ref: Mn,
3678
+ ref: Nn,
3639
3679
  children: [
3640
- /* @__PURE__ */ w(tr, {
3641
- columnGroups: n,
3642
- headerRowCount: wi
3680
+ /* @__PURE__ */ w(nr, {
3681
+ columnGroups: i,
3682
+ headerRowCount: Ii
3643
3683
  }),
3644
- W.top.length > 0 ? /* @__PURE__ */ w(En, {
3684
+ W.top.length > 0 ? /* @__PURE__ */ w(On, {
3645
3685
  edge: "top",
3646
- firstRowIndex: wi + 1,
3686
+ firstRowIndex: Ii + 1,
3647
3687
  nodes: W.top
3648
3688
  }) : null,
3649
- ms === "loading" ? /* @__PURE__ */ w(Nn, {
3689
+ js === "loading" ? /* @__PURE__ */ w(In, {
3650
3690
  rowSize: q,
3651
- rows: hs
3652
- }) : /* @__PURE__ */ w(Tn, {
3653
- bodyStyle: bs,
3654
- firstIndex: Ri ? Bi.startIndex : 0,
3655
- headerRowCount: wi + W.top.length,
3656
- measureRow: Li || Ni === null ? Ko : void 0,
3657
- nodes: Vi,
3658
- heldRows: Hi,
3691
+ rows: Ms
3692
+ }) : /* @__PURE__ */ w(Dn, {
3693
+ bodyStyle: Ls,
3694
+ firstIndex: Xi ? Qi.startIndex : 0,
3695
+ headerRowCount: Ii + W.top.length,
3696
+ measureRow: Yi || Gi === null ? is : void 0,
3697
+ loadMore: as ? {
3698
+ top: ss,
3699
+ ref: cs
3700
+ } : void 0,
3701
+ nodes: $i,
3702
+ heldRows: ea,
3659
3703
  allNodes: G
3660
3704
  }),
3661
- Cs !== null && ms !== "loading" ? /* @__PURE__ */ w(Dn, { children: Cs }) : null,
3662
- W.bottom.length > 0 ? /* @__PURE__ */ w(En, {
3705
+ Bs !== null && js !== "loading" ? /* @__PURE__ */ w(kn, { children: Bs }) : null,
3706
+ W.bottom.length > 0 ? /* @__PURE__ */ w(On, {
3663
3707
  edge: "bottom",
3664
- firstRowIndex: wi + W.top.length + (yi ?? G.length) + 1,
3708
+ firstRowIndex: Ii + W.top.length + (ji ?? G.length) + 1,
3665
3709
  nodes: W.bottom
3666
3710
  }) : null,
3667
- xi && ms === "rows" ? /* @__PURE__ */ w(Pn, {
3668
- aggregates: vi.aggregates,
3669
- rowIndex: wi + W.top.length + (yi ?? G.length) + W.bottom.length + 1
3711
+ Ni && js === "rows" ? /* @__PURE__ */ w(Ln, {
3712
+ aggregates: Ai.aggregates,
3713
+ rowIndex: Ii + W.top.length + (ji ?? G.length) + W.bottom.length + 1
3670
3714
  }) : null,
3671
- qa.offset === null ? null : /* @__PURE__ */ w("div", {
3715
+ ao.offset === null ? null : /* @__PURE__ */ w("div", {
3672
3716
  "aria-hidden": !0,
3673
3717
  "data-part": "drop-indicator",
3674
3718
  "data-part-drop-indicator": "",
3675
3719
  style: {
3676
- "--slotted-data-grid-drop-offset": `${qa.offset}px`,
3677
- "--slotted-data-grid-drop-scroll": `${qa.scrollTop}px`
3720
+ "--slotted-data-grid-drop-offset": `${ao.offset}px`,
3721
+ "--slotted-data-grid-drop-scroll": `${ao.scrollTop}px`
3678
3722
  }
3679
3723
  }),
3680
- ao.offset === null ? null : /* @__PURE__ */ w("div", {
3724
+ vo.offset === null ? null : /* @__PURE__ */ w("div", {
3681
3725
  "aria-hidden": !0,
3682
3726
  "data-axis": "row",
3683
3727
  "data-part": "drop-indicator",
3684
3728
  "data-part-drop-indicator": "",
3685
3729
  style: {
3686
- "--slotted-data-grid-drop-offset": `${ao.offset}px`,
3687
- "--slotted-data-grid-drop-scroll": `${ao.scrollLeft}px`
3730
+ "--slotted-data-grid-drop-offset": `${vo.offset}px`,
3731
+ "--slotted-data-grid-drop-scroll": `${vo.scrollLeft}px`
3688
3732
  }
3689
3733
  })
3690
3734
  ]
3691
- }), me !== void 0 || xs !== null || Ss !== null ? /* @__PURE__ */ T("div", {
3735
+ }), me !== void 0 || Rs !== null || zs !== null ? /* @__PURE__ */ T("div", {
3692
3736
  "data-part": "footer",
3693
3737
  "data-part-footer": "",
3694
3738
  children: [
3695
- xs === null ? null : /* @__PURE__ */ w("span", {
3739
+ Rs === null ? null : /* @__PURE__ */ w("span", {
3696
3740
  "data-range": "",
3697
- children: xs
3741
+ children: Rs
3698
3742
  }),
3699
3743
  me,
3700
- me === void 0 ? Ss : null
3744
+ me === void 0 ? zs : null
3701
3745
  ]
3702
3746
  }) : null]
3703
3747
  })
3704
3748
  })
3705
3749
  });
3706
3750
  }
3707
- function Dr(e, t, n, r) {
3751
+ function jr(e, t, n, r) {
3708
3752
  let i = e.findIndex((e) => e.id === t[0]), a = Math.max(i, Math.min(i + t.length, r)), o = t.indexOf(n), s = a - i, c = s > o ? s - 1 : s;
3709
3753
  return c === o ? null : c;
3710
3754
  }
3711
- function Or(e) {
3712
- return e !== ut && e !== ct && e !== pt && !Ct(e);
3755
+ function Mr(e) {
3756
+ return e !== ut && e !== ct && e !== pt && !wt(e);
3713
3757
  }
3714
3758
  //#endregion
3715
3759
  //#region src/data-grid/use-persisted-grid-view.ts
3716
- function F() {
3760
+ function Nr() {
3717
3761
  try {
3718
3762
  return typeof window > "u" ? null : window.localStorage;
3719
3763
  } catch {
3720
3764
  return null;
3721
3765
  }
3722
3766
  }
3723
- function kr({ key: e, columns: t, storage: n, defaultQuery: r, defaultColumnState: i, defaultDensity: a, ...o }) {
3724
- let s = x(() => n === void 0 ? F() : n, [n]), c = x(() => ({
3725
- columns: Tt(i ?? null, t),
3726
- query: r ?? bt(o.defaultPageSize).query,
3767
+ function N({ key: e, columns: t, storage: n, defaultQuery: r, defaultColumnState: i, defaultDensity: a, ...o }) {
3768
+ let s = x(() => n === void 0 ? Nr() : n, [n]), c = x(() => ({
3769
+ columns: Et(i ?? null, t),
3770
+ query: r ?? xt(o.defaultPageSize).query,
3727
3771
  density: a ?? null
3728
3772
  }), []), [l, u] = C(() => {
3729
3773
  let n;
@@ -3733,7 +3777,7 @@ function kr({ key: e, columns: t, storage: n, defaultQuery: r, defaultColumnStat
3733
3777
  n = null;
3734
3778
  }
3735
3779
  if (n === null || n === "") return c;
3736
- let r = Et(n, t, o);
3780
+ let r = Dt(n, t, o);
3737
3781
  return {
3738
3782
  columns: r.columns,
3739
3783
  query: r.query.page === null ? {
@@ -3762,7 +3806,7 @@ function kr({ key: e, columns: t, storage: n, defaultQuery: r, defaultColumnStat
3762
3806
  f.current = !1;
3763
3807
  let { key: e, columns: t, options: n, store: r } = d.current;
3764
3808
  if (r) try {
3765
- let i = Pt(l, t, n);
3809
+ let i = Ft(l, t, n);
3766
3810
  i === "" ? r.removeItem(e) : r.setItem(e, i);
3767
3811
  } catch {}
3768
3812
  }, [l]);
@@ -3801,4 +3845,4 @@ function kr({ key: e, columns: t, storage: n, defaultQuery: r, defaultColumnStat
3801
3845
  };
3802
3846
  }
3803
3847
  //#endregion
3804
- export { dn as a, Ln as i, Er as n, un as o, In as r, ln as s, kr as t };
3848
+ export { fn as a, Bn as i, Ar as n, dn as o, zn as r, un as s, N as t };