@12-apps/ui 6.13.2 → 6.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (358) hide show
  1. package/components-catalog.md +8 -1
  2. package/dist/_internal/components/data-display/AsyncStateContainer/AsyncStateContainer.js +4 -4
  3. package/dist/_internal/components/data-display/Badge/Badge.js +2 -2
  4. package/dist/_internal/components/data-display/CardKit/use-remove-confirm.js +5 -5
  5. package/dist/_internal/components/data-display/CardKit/use-row-confirm.js +5 -5
  6. package/dist/_internal/components/data-display/Carousel/Carousel.js +3 -3
  7. package/dist/_internal/components/data-display/Chart/Chart.js +4 -4
  8. package/dist/_internal/components/data-display/Chart/SpecChart.js +8 -8
  9. package/dist/_internal/components/data-display/Chart/chart-context.js +2 -2
  10. package/dist/_internal/components/data-display/Chart/chart-renderers.js +3 -3
  11. package/dist/_internal/components/data-display/Chart/chart-spec.js +2 -2
  12. package/dist/_internal/components/data-display/DataGrid/DataGrid.js +3 -3
  13. package/dist/_internal/components/data-display/DataViews/DataViewsGrid.js +44 -42
  14. package/dist/_internal/components/data-display/DataViews/DataViewsTableBase.js +60 -58
  15. package/dist/_internal/components/data-display/DataViews/ManageViewsDialog.js +5 -5
  16. package/dist/_internal/components/data-display/DataViews/base-list-card-geometry.js +4 -4
  17. package/dist/_internal/components/data-display/DataViews/base-list-card-slots.js +3 -3
  18. package/dist/_internal/components/data-display/DataViews/base-list-card.js +7 -7
  19. package/dist/_internal/components/data-display/DataViews/data-views-category-pill.js +13 -13
  20. package/dist/_internal/components/data-display/DataViews/data-views-display-panel.js +1 -1
  21. package/dist/_internal/components/data-display/DataViews/data-views-filter-panel.js +20 -20
  22. package/dist/_internal/components/data-display/DataViews/data-views-grid-bodies.js +7 -7
  23. package/dist/_internal/components/data-display/DataViews/data-views-grid-parts.js +39 -37
  24. package/dist/_internal/components/data-display/DataViews/data-views-header-row.js +12 -0
  25. package/dist/_internal/components/data-display/DataViews/data-views-header-row.js.map +1 -0
  26. package/dist/_internal/components/data-display/DataViews/data-views-inline-bar.js +20 -20
  27. package/dist/_internal/components/data-display/DataViews/data-views-more-fields.js +7 -7
  28. package/dist/_internal/components/data-display/DataViews/data-views-more-filters.js +8 -8
  29. package/dist/_internal/components/data-display/DataViews/data-views-range-pill.js +3 -3
  30. package/dist/_internal/components/data-display/DataViews/data-views-scope-tabs.js +2 -2
  31. package/dist/_internal/components/data-display/DataViews/data-views-selection-extra.js +8 -0
  32. package/dist/_internal/components/data-display/DataViews/data-views-selection-extra.js.map +1 -0
  33. package/dist/_internal/components/data-display/DataViews/data-views-shell-toolbar.js +7 -7
  34. package/dist/_internal/components/data-display/DataViews/data-views-table-parts.js +9 -9
  35. package/dist/_internal/components/data-display/DataViews/data-views-toolbar.js +6 -6
  36. package/dist/_internal/components/data-display/DataViews/list-card-rails.js +2 -2
  37. package/dist/_internal/components/data-display/DataViews/use-data-views-state.js +4 -4
  38. package/dist/_internal/components/data-display/DataViews/use-saved-views-controller.js +2 -2
  39. package/dist/_internal/components/data-display/HoverCard/HoverCard.js +2 -2
  40. package/dist/_internal/components/data-display/LazyImage/LazyImage.js +3 -3
  41. package/dist/_internal/components/data-display/Lightbox/Lightbox.js +6 -6
  42. package/dist/_internal/components/data-display/LoadingState/LoadingState.js +3 -3
  43. package/dist/_internal/components/data-display/MapPreview/MapDecorations.js +2 -2
  44. package/dist/_internal/components/data-display/MapPreview/MapLayers.js +3 -3
  45. package/dist/_internal/components/data-display/MapPreview/MapPreview.hooks.js +2 -2
  46. package/dist/_internal/components/data-display/MapPreview/MapPreview.js +11 -11
  47. package/dist/_internal/components/data-display/MapPreview/MapTiles.js +2 -2
  48. package/dist/_internal/components/data-display/MapPreview/StaticMapView.js +4 -4
  49. package/dist/_internal/components/data-display/MapPreview/useMapPreview.js +3 -3
  50. package/dist/_internal/components/data-display/StatCard/StatCard.js +3 -3
  51. package/dist/_internal/components/data-display/Table/Table.js +2 -2
  52. package/dist/_internal/components/data-display/index.js +52 -52
  53. package/dist/_internal/components/feedback/ConfirmAction/ConfirmAction.js +2 -2
  54. package/dist/_internal/components/feedback/ConfirmAction/ConfirmButton.js +3 -3
  55. package/dist/_internal/components/feedback/ConfirmAction/with-confirmation.js +2 -2
  56. package/dist/_internal/components/feedback/StackedModal/StackedModal.js +6 -6
  57. package/dist/_internal/components/feedback/TutorialOverlay/TutorialOverlay.js +2 -2
  58. package/dist/_internal/components/feedback/index.js +15 -15
  59. package/dist/_internal/components/form/AddressAutocomplete/AddressAutocomplete.hooks.js +4 -4
  60. package/dist/_internal/components/form/AddressAutocomplete/AddressAutocomplete.js +7 -7
  61. package/dist/_internal/components/form/AddressAutocomplete/AddressAutocompleteField.js +2 -2
  62. package/dist/_internal/components/form/Autocomplete/Autocomplete.js +2 -2
  63. package/dist/_internal/components/form/CategorySelect/CategoryPanel.js +4 -4
  64. package/dist/_internal/components/form/CategorySelect/CategoryPanelList.js +3 -3
  65. package/dist/_internal/components/form/CategorySelect/CategoryRows.js +2 -2
  66. package/dist/_internal/components/form/CategorySelect/CategorySelect.js +9 -9
  67. package/dist/_internal/components/form/CodeEditor/CodeEditor.js +3 -3
  68. package/dist/_internal/components/form/DateRangePicker/DateRangePicker.js +3 -3
  69. package/dist/_internal/components/form/HeaderActions/HeaderActions.js +11 -0
  70. package/dist/_internal/components/form/HeaderActions/HeaderActions.js.map +1 -0
  71. package/dist/_internal/components/form/HeaderActions/HeaderActions.types.js +1 -0
  72. package/dist/_internal/components/form/HeaderActions/HeaderActions.types.js.map +1 -0
  73. package/dist/_internal/components/form/Label/Label.js +2 -2
  74. package/dist/_internal/components/form/PhoneInput/PhoneInput.hooks.js +2 -2
  75. package/dist/_internal/components/form/PhoneInput/PhoneInput.js +3 -3
  76. package/dist/_internal/components/form/index.js +38 -38
  77. package/dist/_internal/components/form/total-form/Fields/CategoryField.js +10 -10
  78. package/dist/_internal/components/form/total-form/Fields/index.js +13 -13
  79. package/dist/_internal/components/index.js +143 -141
  80. package/dist/_internal/components/layout/ContentToolbar/ContentToolbar.js +1 -1
  81. package/dist/_internal/components/layout/Dashboard/Dashboard.js +4 -2
  82. package/dist/_internal/components/layout/Dashboard/DashboardParts.js +5 -1
  83. package/dist/_internal/components/layout/ScrollArea/ScrollArea.js +3 -3
  84. package/dist/_internal/components/layout/Skeleton/Skeleton.js +2 -2
  85. package/dist/_internal/components/layout/index.js +22 -20
  86. package/dist/_internal/components/navigation/CommandPalette/CommandPalette.js +2 -2
  87. package/dist/_internal/components/navigation/NavigationMenu/NavigationMegaSection.js +3 -3
  88. package/dist/_internal/components/navigation/NavigationMenu/NavigationMenu.js +5 -5
  89. package/dist/_internal/components/navigation/NavigationMenu/NavigationMenuItem.js +2 -2
  90. package/dist/_internal/components/navigation/NavigationMenu/NavigationStandardBody.js +3 -3
  91. package/dist/_internal/components/navigation/index.js +11 -11
  92. package/dist/_internal/components/typography/index.js +3 -3
  93. package/dist/_internal/components/utility/InstallPrompt/InstallPrompt.js +2 -2
  94. package/dist/_internal/components/utility/index.js +7 -7
  95. package/dist/_internal/en-US.data-display.js +2 -2
  96. package/dist/charts.js +17 -17
  97. package/dist/{chunk-WQSL6MCA.js → chunk-23FCBIUN.js} +4 -4
  98. package/dist/{chunk-6PFBYCBU.js → chunk-24LW52EU.js} +2 -2
  99. package/dist/{chunk-HR7YTBR7.js → chunk-3AOOI2NR.js} +4 -4
  100. package/dist/{chunk-EIGELK2H.js → chunk-3P4THDBM.js} +4 -4
  101. package/dist/{chunk-SJIBPRPB.js → chunk-3T2I6BYA.js} +4 -4
  102. package/dist/{chunk-5ZZPQ3MT.js → chunk-434EDUHY.js} +5 -5
  103. package/dist/{chunk-4ETQRBZC.js → chunk-46UPILLK.js} +4 -4
  104. package/dist/{chunk-CKZFYGBY.js → chunk-47DCYF4G.js} +6 -6
  105. package/dist/{chunk-B2324WXJ.js → chunk-4KNJQFDJ.js} +4 -4
  106. package/dist/{chunk-V44U7H4M.js → chunk-5KZESOK6.js} +8 -8
  107. package/dist/{chunk-JE6RZ5L6.js → chunk-5ZOJLYD2.js} +4 -4
  108. package/dist/{chunk-AVGTTWTE.js → chunk-65DLYC4S.js} +4 -4
  109. package/dist/{chunk-HRJ27X5B.js → chunk-6HNEEJES.js} +7 -7
  110. package/dist/{chunk-4VNUOSTQ.js → chunk-6YFMGNSA.js} +4 -4
  111. package/dist/{chunk-R7MX5KPJ.js → chunk-6YLAVHV4.js} +4 -4
  112. package/dist/{chunk-56SMIHWE.js → chunk-747HBFGH.js} +4 -4
  113. package/dist/{chunk-A43SJQYE.js → chunk-74LYLKO2.js} +4 -2
  114. package/dist/chunk-74LYLKO2.js.map +1 -0
  115. package/dist/{chunk-RXSGHPCR.js → chunk-7FOOLP5H.js} +4 -4
  116. package/dist/{chunk-EICVL6GS.js → chunk-7HPPUO2A.js} +2 -2
  117. package/dist/chunk-A4YWFX5C.js +39 -0
  118. package/dist/chunk-A4YWFX5C.js.map +1 -0
  119. package/dist/{chunk-VJFH2AXT.js → chunk-ARI5ZU75.js} +7 -7
  120. package/dist/{chunk-7QVYJQN4.js → chunk-B5LNUTGZ.js} +2 -2
  121. package/dist/{chunk-75KRWRJA.js → chunk-BQYIJOKS.js} +6 -6
  122. package/dist/{chunk-72NOM3O2.js → chunk-C34GFGA5.js} +2 -2
  123. package/dist/{chunk-4KSOSI3U.js → chunk-CRHQN42I.js} +5 -5
  124. package/dist/{chunk-LQR2IVSL.js → chunk-DWUMMMLR.js} +4 -4
  125. package/dist/{chunk-SHDIZSN5.js → chunk-EGRFMPGD.js} +6 -6
  126. package/dist/{chunk-XFUNJYFT.js → chunk-EPNUVSNK.js} +7 -7
  127. package/dist/{chunk-FLSSV4TH.js → chunk-EWGVRRUF.js} +23 -2
  128. package/dist/chunk-EWGVRRUF.js.map +1 -0
  129. package/dist/{chunk-L6KEVPXN.js → chunk-FH4VARZ7.js} +7 -7
  130. package/dist/{chunk-N6JGYVRY.js → chunk-GDUIT5I6.js} +2 -2
  131. package/dist/{chunk-R6SBP5M5.js → chunk-GOWBYHYW.js} +4 -4
  132. package/dist/{chunk-HDNK7BAX.js → chunk-GT7C6TSM.js} +3 -3
  133. package/dist/{chunk-X5MPHXG5.js → chunk-HEG7JIBM.js} +4 -4
  134. package/dist/{chunk-RDYBS45D.js → chunk-HIZCBYEP.js} +7 -7
  135. package/dist/{chunk-AZUFGKMQ.js → chunk-HJOABXKN.js} +4 -4
  136. package/dist/{chunk-ZOUWHGV3.js → chunk-HOJL2GKW.js} +7 -7
  137. package/dist/{chunk-AZSFIQIA.js → chunk-I2S2GHEG.js} +12 -12
  138. package/dist/{chunk-RRO2EOJB.js → chunk-JB67KPGM.js} +4 -4
  139. package/dist/{chunk-MNJVOU7T.js → chunk-K2T2CQSZ.js} +4 -4
  140. package/dist/chunk-KX75HM5U.js +20 -0
  141. package/dist/chunk-KX75HM5U.js.map +1 -0
  142. package/dist/{chunk-AWTERXCW.js → chunk-LDMXHDZ5.js} +4 -2
  143. package/dist/chunk-LDMXHDZ5.js.map +1 -0
  144. package/dist/{chunk-IIUB4IOH.js → chunk-LKF5KQ2Q.js} +4 -4
  145. package/dist/{chunk-A2WJMZX5.js → chunk-LNQ6QMKG.js} +2 -2
  146. package/dist/{chunk-ECIGNYSI.js → chunk-LR2ECQSZ.js} +2 -2
  147. package/dist/{chunk-SFAP5EH5.js → chunk-LUMF63BM.js} +4 -4
  148. package/dist/{chunk-CZPU5TW3.js → chunk-LYSSO6WC.js} +4 -4
  149. package/dist/{chunk-XSKVBGCZ.js → chunk-MHJ52VJE.js} +5 -5
  150. package/dist/{chunk-WXBBWSNU.js → chunk-MJOXIENM.js} +3 -2
  151. package/dist/chunk-MJOXIENM.js.map +1 -0
  152. package/dist/chunk-N4JEQJBL.js +93 -0
  153. package/dist/chunk-N4JEQJBL.js.map +1 -0
  154. package/dist/{chunk-HNDUCGM3.js → chunk-NI2ISQZI.js} +3 -3
  155. package/dist/chunk-NI2ISQZI.js.map +1 -0
  156. package/dist/{chunk-Q4ITS2EP.js → chunk-NJS4WCHA.js} +21 -45
  157. package/dist/chunk-NJS4WCHA.js.map +1 -0
  158. package/dist/{chunk-RUO4D4N6.js → chunk-NKCKIGRL.js} +6 -6
  159. package/dist/{chunk-IRDGC7FK.js → chunk-NVOQLMYF.js} +4 -4
  160. package/dist/{chunk-AGYGNNOM.js → chunk-PQECNGDE.js} +2 -2
  161. package/dist/{chunk-LPYB4Y7C.js → chunk-PRAGFBHW.js} +4 -4
  162. package/dist/{chunk-7DNQHMDO.js → chunk-PXH24VIP.js} +4 -4
  163. package/dist/{chunk-AP3PVR3T.js → chunk-Q6KXTTC4.js} +2 -2
  164. package/dist/{chunk-CDJPDZCA.js → chunk-QISJKBCM.js} +2 -2
  165. package/dist/{chunk-WBKWIFXA.js → chunk-QYNCPS5W.js} +6 -6
  166. package/dist/{chunk-XEE7PLDR.js → chunk-QZBUGUOY.js} +6 -6
  167. package/dist/{chunk-BLT5ZBVL.js → chunk-RRX6ZTNX.js} +2 -2
  168. package/dist/{chunk-QQE2PVLO.js → chunk-RXYSP56G.js} +6 -6
  169. package/dist/{chunk-BVGR7OYA.js → chunk-SE4Z3P6D.js} +4 -4
  170. package/dist/chunk-SIZOJNB2.js +1 -0
  171. package/dist/chunk-SIZOJNB2.js.map +1 -0
  172. package/dist/{chunk-2WWKBD4D.js → chunk-TSPHRZ4U.js} +5 -1
  173. package/dist/chunk-TSPHRZ4U.js.map +1 -0
  174. package/dist/{chunk-BGYLL467.js → chunk-TXHJX2NG.js} +4 -4
  175. package/dist/{chunk-KEDI6IRA.js → chunk-UN5D73A4.js} +2 -2
  176. package/dist/{chunk-PKJKA4CU.js → chunk-UPR7F3ML.js} +2 -2
  177. package/dist/{chunk-4ZEU22L2.js → chunk-VLNM4BTH.js} +4 -4
  178. package/dist/{chunk-2SWQ6HIK.js → chunk-W3FAKT3D.js} +4 -4
  179. package/dist/{chunk-UHXNEXOC.js → chunk-WWNXJMBX.js} +2 -2
  180. package/dist/{chunk-V5P5Q6HM.js → chunk-X24P3ZYW.js} +10 -10
  181. package/dist/{chunk-PMS3H3OO.js → chunk-XSJWN3WH.js} +10 -10
  182. package/dist/{chunk-OGGHD64H.js → chunk-Y5UCOBQN.js} +4 -4
  183. package/dist/{chunk-O6J4CKS5.js → chunk-YROTCW42.js} +2 -2
  184. package/dist/{chunk-2A3OMYCB.js → chunk-YRUCIKPO.js} +4 -4
  185. package/dist/{chunk-PDGAFQ6Z.js → chunk-YVX7GGS4.js} +3 -3
  186. package/dist/{chunk-G5ZVD5IJ.js → chunk-ZDWU52DJ.js} +2 -2
  187. package/dist/{chunk-2UCJJACD.js → chunk-ZLNKBKUB.js} +11 -11
  188. package/dist/{chunk-RRYQG5Y6.js → chunk-ZPIFVTJA.js} +6 -6
  189. package/dist/chunk-ZPIFVTJA.js.map +1 -0
  190. package/dist/data-display/AsyncStateContainer.js +4 -4
  191. package/dist/data-display/Badge.js +2 -2
  192. package/dist/data-display/CardKit.js +11 -11
  193. package/dist/data-display/Carousel.js +3 -3
  194. package/dist/data-display/Chart.js +17 -17
  195. package/dist/data-display/DataGrid.js +3 -3
  196. package/dist/data-display/DataViews.js +77 -75
  197. package/dist/data-display/HoverCard.js +2 -2
  198. package/dist/data-display/LazyImage.js +3 -3
  199. package/dist/data-display/Lightbox.js +6 -6
  200. package/dist/data-display/LoadingState.js +3 -3
  201. package/dist/data-display/MapPreview.js +11 -11
  202. package/dist/data-display/StatCard.js +3 -3
  203. package/dist/data-display/Table.js +2 -2
  204. package/dist/en-US.js +8 -8
  205. package/dist/feedback/ConfirmAction.js +7 -7
  206. package/dist/feedback/StackedModal.js +6 -6
  207. package/dist/feedback/TutorialOverlay.js +2 -2
  208. package/dist/form/AddressAutocomplete.js +7 -7
  209. package/dist/form/Autocomplete.js +2 -2
  210. package/dist/form/CategorySelect.js +9 -9
  211. package/dist/form/CodeEditor.js +3 -3
  212. package/dist/form/DateRangePicker.js +3 -3
  213. package/dist/form/HeaderActions.js +11 -0
  214. package/dist/form/HeaderActions.js.map +1 -0
  215. package/dist/form/Label.js +2 -2
  216. package/dist/form/PhoneInput.js +3 -3
  217. package/dist/form/total-form.js +16 -16
  218. package/dist/layout/ContentToolbar.js +7 -7
  219. package/dist/layout/Dashboard.js +4 -2
  220. package/dist/layout/ScrollArea.js +3 -3
  221. package/dist/layout/Skeleton.js +2 -2
  222. package/dist/locales.js +11 -11
  223. package/dist/navigation/CommandPalette.js +2 -2
  224. package/dist/navigation/NavigationMenu.js +5 -5
  225. package/dist/pt-BR.js +4 -4
  226. package/dist/types/components/data-display/DataViews/DataViewsGrid.d.ts +12 -0
  227. package/dist/types/components/data-display/DataViews/DataViewsGrid.d.ts.map +1 -1
  228. package/dist/types/components/data-display/DataViews/DataViewsTableBase.d.ts +3 -0
  229. package/dist/types/components/data-display/DataViews/DataViewsTableBase.d.ts.map +1 -1
  230. package/dist/types/components/data-display/DataViews/data-views-grid-parts.d.ts +3 -0
  231. package/dist/types/components/data-display/DataViews/data-views-grid-parts.d.ts.map +1 -1
  232. package/dist/types/components/data-display/DataViews/data-views-header-row.d.ts +18 -0
  233. package/dist/types/components/data-display/DataViews/data-views-header-row.d.ts.map +1 -0
  234. package/dist/types/components/data-display/DataViews/data-views-selection-extra.d.ts +50 -0
  235. package/dist/types/components/data-display/DataViews/data-views-selection-extra.d.ts.map +1 -0
  236. package/dist/types/components/data-display/DataViews/data-views-shell-toolbar.d.ts +3 -1
  237. package/dist/types/components/data-display/DataViews/data-views-shell-toolbar.d.ts.map +1 -1
  238. package/dist/types/components/data-display/DataViews/data-views-toolbar.d.ts +2 -0
  239. package/dist/types/components/data-display/DataViews/data-views-toolbar.d.ts.map +1 -1
  240. package/dist/types/components/data-display/DataViews/index.d.ts +1 -0
  241. package/dist/types/components/data-display/DataViews/index.d.ts.map +1 -1
  242. package/dist/types/components/form/HeaderActions/HeaderActions.d.ts +48 -0
  243. package/dist/types/components/form/HeaderActions/HeaderActions.d.ts.map +1 -0
  244. package/dist/types/components/form/HeaderActions/HeaderActions.types.d.ts +62 -0
  245. package/dist/types/components/form/HeaderActions/HeaderActions.types.d.ts.map +1 -0
  246. package/dist/types/components/form/HeaderActions/index.d.ts +3 -0
  247. package/dist/types/components/form/HeaderActions/index.d.ts.map +1 -0
  248. package/dist/types/components/layout/ContentToolbar/ContentToolbar.d.ts +1 -1
  249. package/dist/types/components/layout/ContentToolbar/ContentToolbar.d.ts.map +1 -1
  250. package/dist/types/components/layout/ContentToolbar/ContentToolbar.types.d.ts +15 -0
  251. package/dist/types/components/layout/ContentToolbar/ContentToolbar.types.d.ts.map +1 -1
  252. package/dist/types/components/layout/Dashboard/Dashboard.d.ts +4 -0
  253. package/dist/types/components/layout/Dashboard/Dashboard.d.ts.map +1 -1
  254. package/dist/types/components/layout/Dashboard/Dashboard.types.d.ts +10 -0
  255. package/dist/types/components/layout/Dashboard/Dashboard.types.d.ts.map +1 -1
  256. package/dist/types/components/layout/Dashboard/DashboardParts.d.ts +22 -1
  257. package/dist/types/components/layout/Dashboard/DashboardParts.d.ts.map +1 -1
  258. package/dist/types/components/layout/Dashboard/index.d.ts +1 -1
  259. package/dist/types/components/layout/Dashboard/index.d.ts.map +1 -1
  260. package/dist/utility/InstallPrompt.js +2 -2
  261. package/package.json +5 -1
  262. package/src/components/data-display/DataViews/DataViewsGrid.tsx +12 -0
  263. package/src/components/data-display/DataViews/DataViewsTableBase.tsx +3 -0
  264. package/src/components/data-display/DataViews/data-views-grid-parts.tsx +5 -50
  265. package/src/components/data-display/DataViews/data-views-header-row.tsx +52 -0
  266. package/src/components/data-display/DataViews/data-views-selection-extra.ts +67 -0
  267. package/src/components/data-display/DataViews/data-views-shell-toolbar.tsx +4 -0
  268. package/src/components/data-display/DataViews/data-views-toolbar.tsx +3 -0
  269. package/src/components/data-display/DataViews/index.ts +1 -0
  270. package/src/components/form/HeaderActions/HeaderActions.md +72 -0
  271. package/src/components/form/HeaderActions/HeaderActions.tsx +134 -0
  272. package/src/components/form/HeaderActions/HeaderActions.types.ts +64 -0
  273. package/src/components/form/HeaderActions/index.ts +2 -0
  274. package/src/components/layout/ContentToolbar/ContentToolbar.md +10 -3
  275. package/src/components/layout/ContentToolbar/ContentToolbar.tsx +5 -0
  276. package/src/components/layout/ContentToolbar/ContentToolbar.types.ts +15 -0
  277. package/src/components/layout/Dashboard/Dashboard.md +9 -2
  278. package/src/components/layout/Dashboard/Dashboard.tsx +2 -0
  279. package/src/components/layout/Dashboard/Dashboard.types.ts +12 -0
  280. package/src/components/layout/Dashboard/DashboardParts.tsx +36 -0
  281. package/src/components/layout/Dashboard/index.ts +1 -0
  282. package/dist/chunk-2WWKBD4D.js.map +0 -1
  283. package/dist/chunk-A43SJQYE.js.map +0 -1
  284. package/dist/chunk-AWTERXCW.js.map +0 -1
  285. package/dist/chunk-FLSSV4TH.js.map +0 -1
  286. package/dist/chunk-HNDUCGM3.js.map +0 -1
  287. package/dist/chunk-Q4ITS2EP.js.map +0 -1
  288. package/dist/chunk-RRYQG5Y6.js.map +0 -1
  289. package/dist/chunk-WXBBWSNU.js.map +0 -1
  290. /package/dist/{chunk-WQSL6MCA.js.map → chunk-23FCBIUN.js.map} +0 -0
  291. /package/dist/{chunk-6PFBYCBU.js.map → chunk-24LW52EU.js.map} +0 -0
  292. /package/dist/{chunk-HR7YTBR7.js.map → chunk-3AOOI2NR.js.map} +0 -0
  293. /package/dist/{chunk-EIGELK2H.js.map → chunk-3P4THDBM.js.map} +0 -0
  294. /package/dist/{chunk-SJIBPRPB.js.map → chunk-3T2I6BYA.js.map} +0 -0
  295. /package/dist/{chunk-5ZZPQ3MT.js.map → chunk-434EDUHY.js.map} +0 -0
  296. /package/dist/{chunk-4ETQRBZC.js.map → chunk-46UPILLK.js.map} +0 -0
  297. /package/dist/{chunk-CKZFYGBY.js.map → chunk-47DCYF4G.js.map} +0 -0
  298. /package/dist/{chunk-B2324WXJ.js.map → chunk-4KNJQFDJ.js.map} +0 -0
  299. /package/dist/{chunk-V44U7H4M.js.map → chunk-5KZESOK6.js.map} +0 -0
  300. /package/dist/{chunk-JE6RZ5L6.js.map → chunk-5ZOJLYD2.js.map} +0 -0
  301. /package/dist/{chunk-AVGTTWTE.js.map → chunk-65DLYC4S.js.map} +0 -0
  302. /package/dist/{chunk-HRJ27X5B.js.map → chunk-6HNEEJES.js.map} +0 -0
  303. /package/dist/{chunk-4VNUOSTQ.js.map → chunk-6YFMGNSA.js.map} +0 -0
  304. /package/dist/{chunk-R7MX5KPJ.js.map → chunk-6YLAVHV4.js.map} +0 -0
  305. /package/dist/{chunk-56SMIHWE.js.map → chunk-747HBFGH.js.map} +0 -0
  306. /package/dist/{chunk-RXSGHPCR.js.map → chunk-7FOOLP5H.js.map} +0 -0
  307. /package/dist/{chunk-EICVL6GS.js.map → chunk-7HPPUO2A.js.map} +0 -0
  308. /package/dist/{chunk-VJFH2AXT.js.map → chunk-ARI5ZU75.js.map} +0 -0
  309. /package/dist/{chunk-7QVYJQN4.js.map → chunk-B5LNUTGZ.js.map} +0 -0
  310. /package/dist/{chunk-75KRWRJA.js.map → chunk-BQYIJOKS.js.map} +0 -0
  311. /package/dist/{chunk-72NOM3O2.js.map → chunk-C34GFGA5.js.map} +0 -0
  312. /package/dist/{chunk-4KSOSI3U.js.map → chunk-CRHQN42I.js.map} +0 -0
  313. /package/dist/{chunk-LQR2IVSL.js.map → chunk-DWUMMMLR.js.map} +0 -0
  314. /package/dist/{chunk-SHDIZSN5.js.map → chunk-EGRFMPGD.js.map} +0 -0
  315. /package/dist/{chunk-XFUNJYFT.js.map → chunk-EPNUVSNK.js.map} +0 -0
  316. /package/dist/{chunk-L6KEVPXN.js.map → chunk-FH4VARZ7.js.map} +0 -0
  317. /package/dist/{chunk-N6JGYVRY.js.map → chunk-GDUIT5I6.js.map} +0 -0
  318. /package/dist/{chunk-R6SBP5M5.js.map → chunk-GOWBYHYW.js.map} +0 -0
  319. /package/dist/{chunk-HDNK7BAX.js.map → chunk-GT7C6TSM.js.map} +0 -0
  320. /package/dist/{chunk-X5MPHXG5.js.map → chunk-HEG7JIBM.js.map} +0 -0
  321. /package/dist/{chunk-RDYBS45D.js.map → chunk-HIZCBYEP.js.map} +0 -0
  322. /package/dist/{chunk-AZUFGKMQ.js.map → chunk-HJOABXKN.js.map} +0 -0
  323. /package/dist/{chunk-ZOUWHGV3.js.map → chunk-HOJL2GKW.js.map} +0 -0
  324. /package/dist/{chunk-AZSFIQIA.js.map → chunk-I2S2GHEG.js.map} +0 -0
  325. /package/dist/{chunk-RRO2EOJB.js.map → chunk-JB67KPGM.js.map} +0 -0
  326. /package/dist/{chunk-MNJVOU7T.js.map → chunk-K2T2CQSZ.js.map} +0 -0
  327. /package/dist/{chunk-IIUB4IOH.js.map → chunk-LKF5KQ2Q.js.map} +0 -0
  328. /package/dist/{chunk-A2WJMZX5.js.map → chunk-LNQ6QMKG.js.map} +0 -0
  329. /package/dist/{chunk-ECIGNYSI.js.map → chunk-LR2ECQSZ.js.map} +0 -0
  330. /package/dist/{chunk-SFAP5EH5.js.map → chunk-LUMF63BM.js.map} +0 -0
  331. /package/dist/{chunk-CZPU5TW3.js.map → chunk-LYSSO6WC.js.map} +0 -0
  332. /package/dist/{chunk-XSKVBGCZ.js.map → chunk-MHJ52VJE.js.map} +0 -0
  333. /package/dist/{chunk-RUO4D4N6.js.map → chunk-NKCKIGRL.js.map} +0 -0
  334. /package/dist/{chunk-IRDGC7FK.js.map → chunk-NVOQLMYF.js.map} +0 -0
  335. /package/dist/{chunk-AGYGNNOM.js.map → chunk-PQECNGDE.js.map} +0 -0
  336. /package/dist/{chunk-LPYB4Y7C.js.map → chunk-PRAGFBHW.js.map} +0 -0
  337. /package/dist/{chunk-7DNQHMDO.js.map → chunk-PXH24VIP.js.map} +0 -0
  338. /package/dist/{chunk-AP3PVR3T.js.map → chunk-Q6KXTTC4.js.map} +0 -0
  339. /package/dist/{chunk-CDJPDZCA.js.map → chunk-QISJKBCM.js.map} +0 -0
  340. /package/dist/{chunk-WBKWIFXA.js.map → chunk-QYNCPS5W.js.map} +0 -0
  341. /package/dist/{chunk-XEE7PLDR.js.map → chunk-QZBUGUOY.js.map} +0 -0
  342. /package/dist/{chunk-BLT5ZBVL.js.map → chunk-RRX6ZTNX.js.map} +0 -0
  343. /package/dist/{chunk-QQE2PVLO.js.map → chunk-RXYSP56G.js.map} +0 -0
  344. /package/dist/{chunk-BVGR7OYA.js.map → chunk-SE4Z3P6D.js.map} +0 -0
  345. /package/dist/{chunk-BGYLL467.js.map → chunk-TXHJX2NG.js.map} +0 -0
  346. /package/dist/{chunk-KEDI6IRA.js.map → chunk-UN5D73A4.js.map} +0 -0
  347. /package/dist/{chunk-PKJKA4CU.js.map → chunk-UPR7F3ML.js.map} +0 -0
  348. /package/dist/{chunk-4ZEU22L2.js.map → chunk-VLNM4BTH.js.map} +0 -0
  349. /package/dist/{chunk-2SWQ6HIK.js.map → chunk-W3FAKT3D.js.map} +0 -0
  350. /package/dist/{chunk-UHXNEXOC.js.map → chunk-WWNXJMBX.js.map} +0 -0
  351. /package/dist/{chunk-V5P5Q6HM.js.map → chunk-X24P3ZYW.js.map} +0 -0
  352. /package/dist/{chunk-PMS3H3OO.js.map → chunk-XSJWN3WH.js.map} +0 -0
  353. /package/dist/{chunk-OGGHD64H.js.map → chunk-Y5UCOBQN.js.map} +0 -0
  354. /package/dist/{chunk-O6J4CKS5.js.map → chunk-YROTCW42.js.map} +0 -0
  355. /package/dist/{chunk-2A3OMYCB.js.map → chunk-YRUCIKPO.js.map} +0 -0
  356. /package/dist/{chunk-PDGAFQ6Z.js.map → chunk-YVX7GGS4.js.map} +0 -0
  357. /package/dist/{chunk-G5ZVD5IJ.js.map → chunk-ZDWU52DJ.js.map} +0 -0
  358. /package/dist/{chunk-2UCJJACD.js.map → chunk-ZLNKBKUB.js.map} +0 -0
@@ -1,27 +1,27 @@
1
+ import {
2
+ CategoryPanel
3
+ } from "./chunk-434EDUHY.js";
1
4
  import {
2
5
  CategoryPanelSurface
3
6
  } from "./chunk-LMXWI3DD.js";
4
7
  import {
5
- CategoryPanel
6
- } from "./chunk-5ZZPQ3MT.js";
8
+ useCategorySelect
9
+ } from "./chunk-2GB5CIN6.js";
10
+ import {
11
+ useCategoryKeyHandler
12
+ } from "./chunk-ISH42UC7.js";
7
13
  import {
8
14
  useCategoryCommit
9
15
  } from "./chunk-ZAB65STX.js";
16
+ import {
17
+ summarizeSelection
18
+ } from "./chunk-LR6MSKTT.js";
10
19
  import {
11
20
  CategoryTrigger
12
21
  } from "./chunk-XQ2BNVXL.js";
13
22
  import {
14
23
  METRICS
15
24
  } from "./chunk-XCT2ZLA6.js";
16
- import {
17
- useCategorySelect
18
- } from "./chunk-2GB5CIN6.js";
19
- import {
20
- useCategoryKeyHandler
21
- } from "./chunk-ISH42UC7.js";
22
- import {
23
- summarizeSelection
24
- } from "./chunk-LR6MSKTT.js";
25
25
  import {
26
26
  FormControl,
27
27
  FormLabel,
@@ -158,4 +158,4 @@ function CategorySelect(props) {
158
158
  export {
159
159
  CategorySelect
160
160
  };
161
- //# sourceMappingURL=chunk-AZSFIQIA.js.map
161
+ //# sourceMappingURL=chunk-I2S2GHEG.js.map
@@ -1,9 +1,9 @@
1
- import {
2
- TILE_SIZE
3
- } from "./chunk-TUBCN4DJ.js";
4
1
  import {
5
2
  tileBackground
6
3
  } from "./chunk-DRADVLHZ.js";
4
+ import {
5
+ TILE_SIZE
6
+ } from "./chunk-TUBCN4DJ.js";
7
7
 
8
8
  // src/components/data-display/MapPreview/MapTiles.tsx
9
9
  import { alpha, useTheme } from "@mui/material/styles/index.js";
@@ -61,4 +61,4 @@ var MapTiles = ({ origin, zoom, mapType, panOffset }) => {
61
61
  export {
62
62
  MapTiles
63
63
  };
64
- //# sourceMappingURL=chunk-RRO2EOJB.js.map
64
+ //# sourceMappingURL=chunk-JB67KPGM.js.map
@@ -1,12 +1,12 @@
1
1
  import {
2
2
  useCardActions
3
3
  } from "./chunk-77GA5YHQ.js";
4
- import {
5
- useConfirmAction
6
- } from "./chunk-EMYESBIT.js";
7
4
  import {
8
5
  ConfirmActionDialog
9
6
  } from "./chunk-QQS3GQYS.js";
7
+ import {
8
+ useConfirmAction
9
+ } from "./chunk-EMYESBIT.js";
10
10
 
11
11
  // src/components/data-display/CardKit/use-remove-confirm.tsx
12
12
  import { jsx } from "react/jsx-runtime";
@@ -50,4 +50,4 @@ function useRemoveConfirm({
50
50
  export {
51
51
  useRemoveConfirm
52
52
  };
53
- //# sourceMappingURL=chunk-MNJVOU7T.js.map
53
+ //# sourceMappingURL=chunk-K2T2CQSZ.js.map
@@ -0,0 +1,20 @@
1
+ // src/components/data-display/DataViews/data-views-selection-extra.ts
2
+ function resolveSelectionExtra({
3
+ c,
4
+ getRowId,
5
+ selectionExtra
6
+ }) {
7
+ if (selectionExtra === void 0 || c.selectedRows.length === 0) return void 0;
8
+ const page = c.matched;
9
+ return selectionExtra({
10
+ selectedRows: c.selectedRows,
11
+ clearSelection: c.clearSelection,
12
+ allOnPageSelected: page.length > 0 && page.every((row) => c.selectedIds.has(getRowId(row))),
13
+ pageRowCount: page.length
14
+ });
15
+ }
16
+
17
+ export {
18
+ resolveSelectionExtra
19
+ };
20
+ //# sourceMappingURL=chunk-KX75HM5U.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/data-display/DataViews/data-views-selection-extra.ts"],"sourcesContent":["/**\n * The selection-WIDENING slot: what a paginated grid needs so an operator can\n * act on \"everything matching the filter\" rather than on the page in front of\n * them.\n *\n * It is a slot of its own rather than a share of the bulk-actions menu because\n * the two answer different questions — `actions` is what HAPPENS to the\n * selection, this is what the selection IS. Folding a widening into the actions\n * menu files \"change what I picked\" under \"do this to what I picked\", where\n * every entry is expected to write something.\n */\nimport type { DataViewsController } from \"./use-data-views-state\";\n\n/**\n * What a widening control gets to decide with.\n *\n * `allOnPageSelected` is the one thing a host cannot compute for itself, and\n * the whole reason this is a context rather than a bare node: the grid owns\n * which rows the page is currently rendering — server mode pages at the\n * backend, so the host's `rows` prop and the page can differ mid-fetch — and\n * \"every row here is ticked\" is the trigger a select-all-matching control\n * hangs on. Deriving it host-side would be a second, slightly different answer\n * to the question the grid already answers to draw its own header checkbox.\n */\nexport interface SelectionExtraContext<T extends Record<string, unknown>> {\n /** The selected rows, off-page ones included. */\n selectedRows: T[];\n /** Drop the whole selection. */\n clearSelection: () => void;\n /** Every row the page is rendering is selected — and the page is not empty. */\n allOnPageSelected: boolean;\n /** How many rows the page is rendering. */\n pageRowCount: number;\n}\n\n/** The host's widening control, called only while something is selected. */\nexport type SelectionExtraRender<T extends Record<string, unknown>> = (\n context: SelectionExtraContext<T>,\n) => React.ReactNode;\n\n/**\n * Resolve the host's control against the page on screen.\n *\n * Measured against `c.matched` — which in server mode IS the page — rather than\n * the `rows` prop, so the answer cannot lag a page change.\n *\n * Returns `undefined` with nothing selected, so the toolbar renders no empty\n * slot: a widening with nothing to widen is not a control.\n */\nexport function resolveSelectionExtra<T extends Record<string, unknown>>({\n c,\n getRowId,\n selectionExtra,\n}: {\n c: DataViewsController<T>;\n getRowId: (row: T) => string | number;\n selectionExtra?: SelectionExtraRender<T>;\n}): React.ReactNode {\n if (selectionExtra === undefined || c.selectedRows.length === 0) return undefined;\n const page = c.matched;\n return selectionExtra({\n selectedRows: c.selectedRows,\n clearSelection: c.clearSelection,\n allOnPageSelected: page.length > 0 && page.every((row) => c.selectedIds.has(getRowId(row))),\n pageRowCount: page.length,\n });\n}\n"],"mappings":";AAiDO,SAAS,sBAAyD;AAAA,EACvE;AAAA,EACA;AAAA,EACA;AACF,GAIoB;AAClB,MAAI,mBAAmB,UAAa,EAAE,aAAa,WAAW,EAAG,QAAO;AACxE,QAAM,OAAO,EAAE;AACf,SAAO,eAAe;AAAA,IACpB,cAAc,EAAE;AAAA,IAChB,gBAAgB,EAAE;AAAA,IAClB,mBAAmB,KAAK,SAAS,KAAK,KAAK,MAAM,CAAC,QAAQ,EAAE,YAAY,IAAI,SAAS,GAAG,CAAC,CAAC;AAAA,IAC1F,cAAc,KAAK;AAAA,EACrB,CAAC;AACH;","names":[]}
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  GridToolbar
3
- } from "./chunk-WXBBWSNU.js";
3
+ } from "./chunk-MJOXIENM.js";
4
4
 
5
5
  // src/components/data-display/DataViews/data-views-shell-toolbar.tsx
6
6
  import { jsx } from "react/jsx-runtime";
@@ -10,6 +10,7 @@ function ShellToolbar({
10
10
  testIdPrefix,
11
11
  rowActions,
12
12
  bulkActions,
13
+ selectionExtra,
13
14
  toolbarRightSlot,
14
15
  showInline,
15
16
  compactControls,
@@ -42,6 +43,7 @@ function ShellToolbar({
42
43
  clearSelection: c.clearSelection,
43
44
  rowActions,
44
45
  bulkActions,
46
+ selectionExtra,
45
47
  sortFields: c.resolvedSortFields,
46
48
  activeSortField: c.activeSortField,
47
49
  activeSortOrder: c.activeSortOrder,
@@ -62,4 +64,4 @@ function ShellToolbar({
62
64
  export {
63
65
  ShellToolbar
64
66
  };
65
- //# sourceMappingURL=chunk-AWTERXCW.js.map
67
+ //# sourceMappingURL=chunk-LDMXHDZ5.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/data-display/DataViews/data-views-shell-toolbar.tsx"],"sourcesContent":["\"use client\";\n\n/**\n * The toolbar band, fed from the controller — ~25 props of pure forwarding and\n * nothing else, which is why it lives in its own file rather than in the shell.\n */\nimport { type ColumnVisibilityOption } from \"../../layout/ContentToolbar\";\n\nimport type { DisplayPanelView } from \"./data-views-display-panel\";\nimport type { DataViewExport } from \"./data-views-export\";\nimport { GridToolbar } from \"./data-views-toolbar\";\nimport type { RowAction } from \"./data-views-types\";\nimport type { DataViewsController } from \"./use-data-views-state\";\n\n/**\n * The toolbar band, fed from the controller. Split out of `GridShell` for that\n * function's size budget — it is ~25 props of pure forwarding and nothing else.\n */\nexport function ShellToolbar<T extends Record<string, unknown>>({\n c,\n rows,\n testIdPrefix,\n rowActions,\n bulkActions,\n selectionExtra,\n toolbarRightSlot,\n showInline,\n compactControls,\n counterHidden,\n sortKinds,\n displayView,\n exportConfig,\n filterControls,\n barRef,\n}: {\n c: DataViewsController<T>;\n rows: T[];\n testIdPrefix: string;\n sortKinds?: Record<string, string>;\n displayView?: DisplayPanelView;\n exportConfig?: DataViewExport;\n rowActions?: RowAction<T>[];\n bulkActions?: (selectedRows: T[], clearSelection: () => void) => React.ReactNode;\n /** Already resolved by the shell, which is the party that knows the page. */\n selectionExtra?: React.ReactNode;\n toolbarRightSlot?: React.ReactNode;\n /** Search + filters, rendered on the toolbar line (see `GridToolbar`). */\n filterControls?: React.ReactNode;\n barRef?: React.Ref<HTMLDivElement>;\n showInline: boolean;\n /** Step 2 of the ladder: Exibir/Exportar as icons only. */\n compactControls?: boolean;\n /** Step 5, last resort: drop the counter so the row still fits one line. */\n counterHidden?: boolean;\n}): React.JSX.Element {\n const columnOptions: ColumnVisibilityOption[] = c.hideableColumns.map((col) => ({\n id: col.id,\n label: col.label,\n visible: c.state.visibleColumns.includes(col.id),\n }));\n return (\n <GridToolbar\n c={c}\n sortKinds={sortKinds}\n displayView={displayView}\n exportConfig={exportConfig}\n filterControls={filterControls}\n barRef={barRef}\n compactControls={compactControls}\n counterHidden={counterHidden}\n testIdPrefix={testIdPrefix}\n selectedRows={c.selectedRows}\n selectAll={c.selectAll}\n clearSelection={c.clearSelection}\n rowActions={rowActions}\n bulkActions={bulkActions}\n selectionExtra={selectionExtra}\n sortFields={c.resolvedSortFields}\n activeSortField={c.activeSortField}\n activeSortOrder={c.activeSortOrder}\n onChangeSort={(field, order) => c.patch({ sortBy: [{ id: field, dir: order }] })}\n matchedCount={c.matched.length}\n totalCount={c.serverMode ? c.serverTotalCount : rows.length}\n toolbarRightSlot={toolbarRightSlot}\n columnOptions={columnOptions}\n onToggleColumn={c.toggleColumn}\n filterOpen={c.filterOpen}\n setFilterOpen={c.setFilterOpen}\n activeFilterCount={c.activeFilterCount}\n showFilterTrigger={!showInline}\n />\n );\n}\n\n/** Wires the controller into the shared toolbar + filter panel + grid/cards body. */\n"],"mappings":";;;;;AA6DI;AA3CG,SAAS,aAAgD;AAAA,EAC9D;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAoBsB;AACpB,QAAM,gBAA0C,EAAE,gBAAgB,IAAI,CAAC,SAAS;AAAA,IAC9E,IAAI,IAAI;AAAA,IACR,OAAO,IAAI;AAAA,IACX,SAAS,EAAE,MAAM,eAAe,SAAS,IAAI,EAAE;AAAA,EACjD,EAAE;AACF,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,cAAc,EAAE;AAAA,MAChB,WAAW,EAAE;AAAA,MACb,gBAAgB,EAAE;AAAA,MAClB;AAAA,MACA;AAAA,MACA;AAAA,MACA,YAAY,EAAE;AAAA,MACd,iBAAiB,EAAE;AAAA,MACnB,iBAAiB,EAAE;AAAA,MACnB,cAAc,CAAC,OAAO,UAAU,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,IAAI,OAAO,KAAK,MAAM,CAAC,EAAE,CAAC;AAAA,MAC/E,cAAc,EAAE,QAAQ;AAAA,MACxB,YAAY,EAAE,aAAa,EAAE,mBAAmB,KAAK;AAAA,MACrD;AAAA,MACA;AAAA,MACA,gBAAgB,EAAE;AAAA,MAClB,YAAY,EAAE;AAAA,MACd,eAAe,EAAE;AAAA,MACjB,mBAAmB,EAAE;AAAA,MACrB,mBAAmB,CAAC;AAAA;AAAA,EACtB;AAEJ;","names":[]}
@@ -1,11 +1,11 @@
1
- import {
2
- EN_US_TABLE_FILTER_COPY
3
- } from "./chunk-GRHECKHU.js";
4
1
  import {
5
2
  EN_US_CATEGORY_SELECT_COPY,
6
3
  EN_US_CONFIRM_ACTION_COPY,
7
4
  EN_US_SAVED_VIEWS_LABELS
8
5
  } from "./chunk-PZS7N74L.js";
6
+ import {
7
+ EN_US_TABLE_FILTER_COPY
8
+ } from "./chunk-GRHECKHU.js";
9
9
 
10
10
  // src/en-US.data-display.ts
11
11
  var EN_US_LIGHTBOX_COPY = {
@@ -234,4 +234,4 @@ export {
234
234
  EN_US_DATA_STATE_COPY,
235
235
  EN_US_DATA_VIEWS_COPY
236
236
  };
237
- //# sourceMappingURL=chunk-IIUB4IOH.js.map
237
+ //# sourceMappingURL=chunk-LKF5KQ2Q.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  usePhoneInput
3
- } from "./chunk-BGYLL467.js";
3
+ } from "./chunk-TXHJX2NG.js";
4
4
  import {
5
5
  countries
6
6
  } from "./chunk-3JDP5OUR.js";
@@ -331,4 +331,4 @@ export {
331
331
  PhoneInput,
332
332
  PhoneInput_default
333
333
  };
334
- //# sourceMappingURL=chunk-A2WJMZX5.js.map
334
+ //# sourceMappingURL=chunk-LNQ6QMKG.js.map
@@ -6,7 +6,7 @@ import {
6
6
  } from "./chunk-4T6W43TO.js";
7
7
  import {
8
8
  CategorySelect
9
- } from "./chunk-AZSFIQIA.js";
9
+ } from "./chunk-I2S2GHEG.js";
10
10
 
11
11
  // src/components/data-display/DataViews/data-views-category-pill.tsx
12
12
  import { jsx } from "react/jsx-runtime";
@@ -79,4 +79,4 @@ export {
79
79
  emitPillDiff,
80
80
  PillControl
81
81
  };
82
- //# sourceMappingURL=chunk-ECIGNYSI.js.map
82
+ //# sourceMappingURL=chunk-LR2ECQSZ.js.map
@@ -1,9 +1,9 @@
1
- import {
2
- TutorialStepBody
3
- } from "./chunk-7WP2HRTW.js";
4
1
  import {
5
2
  useTutorialOverlay
6
3
  } from "./chunk-RSQMPCCR.js";
4
+ import {
5
+ TutorialStepBody
6
+ } from "./chunk-7WP2HRTW.js";
7
7
 
8
8
  // src/components/feedback/TutorialOverlay/TutorialOverlay.tsx
9
9
  import Box from "@mui/material/Box/index.js";
@@ -271,4 +271,4 @@ export {
271
271
  TutorialOverlay,
272
272
  TutorialOverlay_default
273
273
  };
274
- //# sourceMappingURL=chunk-SFAP5EH5.js.map
274
+ //# sourceMappingURL=chunk-LUMF63BM.js.map
@@ -1,10 +1,10 @@
1
+ import {
2
+ DENSITY_ROW_PADDING
3
+ } from "./chunk-ZPIMPOHV.js";
1
4
  import {
2
5
  CellConfigProvider,
3
6
  cellTracks
4
7
  } from "./chunk-6VP2L3DJ.js";
5
- import {
6
- DENSITY_ROW_PADDING
7
- } from "./chunk-ZPIMPOHV.js";
8
8
  import {
9
9
  default as default2
10
10
  } from "./chunk-6DPAWXZ3.js";
@@ -129,4 +129,4 @@ export {
129
129
  cellRailCount,
130
130
  ListCardGroup
131
131
  };
132
- //# sourceMappingURL=chunk-CZPU5TW3.js.map
132
+ //# sourceMappingURL=chunk-LYSSO6WC.js.map
@@ -1,13 +1,13 @@
1
+ import {
2
+ resolveAxisConfig,
3
+ resolveBarGeometry
4
+ } from "./chunk-4V532JF6.js";
1
5
  import {
2
6
  getAxisStyles,
3
7
  getDefaultColors,
4
8
  getSizeStyles,
5
9
  resolveSeries
6
10
  } from "./chunk-AVU6KU27.js";
7
- import {
8
- resolveAxisConfig,
9
- resolveBarGeometry
10
- } from "./chunk-4V532JF6.js";
11
11
 
12
12
  // src/components/data-display/Chart/chart-context.ts
13
13
  function buildChartContext(props, theme) {
@@ -48,4 +48,4 @@ function buildChartContext(props, theme) {
48
48
  export {
49
49
  buildChartContext
50
50
  };
51
- //# sourceMappingURL=chunk-XSKVBGCZ.js.map
51
+ //# sourceMappingURL=chunk-MHJ52VJE.js.map
@@ -15,7 +15,7 @@ import {
15
15
  } from "./chunk-LVCUJ7YU.js";
16
16
  import {
17
17
  ContentToolbar
18
- } from "./chunk-2WWKBD4D.js";
18
+ } from "./chunk-TSPHRZ4U.js";
19
19
  import {
20
20
  default as default2
21
21
  } from "./chunk-6DPAWXZ3.js";
@@ -113,6 +113,7 @@ function GridToolbar(props) {
113
113
  clearSelection: props.clearSelection,
114
114
  selectAllTestId: `${testIdPrefix}-select-all`,
115
115
  clearAllTestId: `${testIdPrefix}-clear-all`,
116
+ selectionExtra: props.selectionExtra,
116
117
  actions: renderBulkActions({
117
118
  rowActions: props.rowActions,
118
119
  bulkActions: props.bulkActions,
@@ -132,4 +133,4 @@ function GridToolbar(props) {
132
133
  export {
133
134
  GridToolbar
134
135
  };
135
- //# sourceMappingURL=chunk-WXBBWSNU.js.map
136
+ //# sourceMappingURL=chunk-MJOXIENM.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/data-display/DataViews/data-views-toolbar.tsx"],"sourcesContent":["\"use client\";\n\nimport Divider from \"@mui/material/Divider/index.js\";\n\nimport {\n ContentToolbar,\n FilterTrigger,\n type ColumnVisibilityOption,\n type SortFieldDefinition,\n} from \"../../layout/ContentToolbar\";\nimport { Box } from \"../../../mui/Box\";\nimport { Text } from \"../../typography/Text\";\n\nimport { useDataViewsCopy } from \"./data-views-copy-context\";\nimport { DataViewsDisplayPanel, type DisplayPanelView } from \"./data-views-display-panel\";\nimport { DataViewsExportMenu, type DataViewExport } from \"./data-views-export\";\nimport { renderBulkActions } from \"./data-views-grid-helpers\";\nimport type { RowAction } from \"./data-views-types\";\nimport type { DataViewsController } from \"./use-data-views-state\";\n\nexport interface GridToolbarProps<T extends Record<string, unknown>> {\n testIdPrefix: string;\n selectedRows: T[];\n selectAll: () => void;\n clearSelection: () => void;\n rowActions?: RowAction<T>[];\n bulkActions?: (selectedRows: T[], clearSelection: () => void) => React.ReactNode;\n /** A control between the count and the actions menu — see `selectionExtra`. */\n selectionExtra?: React.ReactNode;\n sortFields: SortFieldDefinition[];\n activeSortField: string;\n activeSortOrder: \"asc\" | \"desc\";\n onChangeSort: (field: string, order: \"asc\" | \"desc\") => void;\n matchedCount: number;\n totalCount: number;\n toolbarRightSlot?: React.ReactNode;\n columnOptions: ColumnVisibilityOption[];\n onToggleColumn: (id: string, visible: boolean) => void;\n filterOpen: boolean;\n setFilterOpen: (open: boolean) => void;\n activeFilterCount: number;\n /** Hide the \"Filtros\" slide-in trigger (compact layout shows filters inline). */\n showFilterTrigger?: boolean;\n /**\n * Search + filter controls, rendered ON the toolbar line rather than on a row\n * beneath it. Absent ⇒ the toolbar keeps its plain two-cluster shape.\n */\n filterControls?: React.ReactNode;\n /** Measures the toolbar ROW for the filter overflow — see `useFilterOverflow`. */\n barRef?: React.Ref<HTMLDivElement>;\n /** The controller, so \"Exibir\" can drive sort, columns, order and format. */\n c: DataViewsController<T>;\n /** Per-sort-field value kind, so directions read in the column's own terms. */\n sortKinds?: Record<string, string>;\n /** The saved-view chrome bracketing the Exibir panel, when the host has views. */\n displayView?: DisplayPanelView;\n /** Injected export. Absent ⇒ no Exportar control. */\n exportConfig?: DataViewExport;\n /**\n * Step 2 of the degradation ladder: Exibir/Exportar as icons only.\n * MEASURED upstream (see `useFilterOverflow`) rather than switched at a\n * breakpoint, so a two-filter page keeps its labels where a five-filter one\n * has already given them up.\n */\n compactControls?: boolean;\n /**\n * Step 5 of the ladder, and its floor: on a screen too narrow for even the\n * fully-collapsed row, the counter is dropped so the controls still fit one\n * line instead of spilling outside the toolbar.\n */\n counterHidden?: boolean;\n}\n\n/** The right-aligned toolbar controls: Sort By, the counter, zoom/layout/columns, filters. */\nfunction ToolbarRightControls<T extends Record<string, unknown>>(props: GridToolbarProps<T>): React.JSX.Element {\n const { testIdPrefix, matchedCount, totalCount, filterOpen, setFilterOpen } = props;\n return (\n <>\n {/* MEASURED, never breakpointed: `RESERVED.counter` prices it into the\n ladder, so hiding it at `md` was the ladder and a breakpoint\n disagreeing about the same pixels — which broke the row at exactly\n 900px. It is dropped only as the ladder's last rung. */}\n {!props.counterHidden && (\n <>\n <Text variant=\"caption\" as=\"span\">\n <Box\n component=\"span\"\n data-testid={`${testIdPrefix}-counter`}\n sx={{ whiteSpace: \"nowrap\" }}\n >\n {matchedCount} de {totalCount}\n </Box>\n </Text>\n {/* Divides the READING of the list from the controls that change it —\n the counter states what is on screen, everything right of here\n acts on it. */}\n <Divider\n orientation=\"vertical\"\n flexItem\n sx={{ height: 20, alignSelf: \"center\", mx: 0.5 }}\n />\n </>\n )}\n {props.toolbarRightSlot}\n {/* Sort + columns + format, in ONE control — see DataViewsDisplayPanel. */}\n <DataViewsDisplayPanel\n c={props.c}\n testIdPrefix={testIdPrefix}\n sortKinds={props.sortKinds}\n view={props.displayView}\n compact={props.compactControls}\n />\n {props.exportConfig && (\n <DataViewsExportMenu\n config={props.exportConfig}\n query={props.c.currentQuery}\n totalCount={props.totalCount}\n selectedIds={[...props.c.selectedIds]}\n columns={props.columnOptions.filter((col) => col.visible).map((col) => ({ id: col.id, label: col.label }))}\n testIdPrefix={testIdPrefix}\n compact={props.compactControls}\n />\n )}\n {props.showFilterTrigger !== false && (\n <FilterTrigger\n open={filterOpen}\n onOpenChange={setFilterOpen}\n activeCount={props.activeFilterCount}\n data-testid={`${testIdPrefix}-filters-toggle`}\n />\n )}\n </>\n );\n}\n\n/**\n * The bordered toolbar band: selection chrome + Sort By, the result counter, the\n * saved-views slot, and the filter funnel. The negative margin lets the top/bottom\n * separators reach the sidebar's vertical line and the window edge.\n */\nexport function GridToolbar<T extends Record<string, unknown>>(props: GridToolbarProps<T>): React.JSX.Element {\n const copy = useDataViewsCopy();\n const { testIdPrefix, selectedRows } = props;\n return (\n <Box\n ref={props.barRef}\n sx={{\n borderTop: 1,\n borderBottom: 1,\n borderColor: \"divider\",\n py: 1.25,\n mx: { xs: -2, md: -3 },\n px: { xs: 2, md: 3 },\n }}\n >\n <ContentToolbar\n selectAllLabel={copy.selection.selectAll}\n selectAllText={copy.selection.selectAllOnPage}\n clearAllText={copy.filters.clearAll}\n hasSelection={selectedRows.length > 0}\n selectedCount={selectedRows.length}\n selectAll={props.selectAll}\n clearSelection={props.clearSelection}\n selectAllTestId={`${testIdPrefix}-select-all`}\n clearAllTestId={`${testIdPrefix}-clear-all`}\n selectionExtra={props.selectionExtra}\n actions={renderBulkActions({\n rowActions: props.rowActions,\n bulkActions: props.bulkActions,\n selectedRows,\n clearSelection: props.clearSelection,\n testIdPrefix,\n })}\n leadingControls={props.filterControls}\n // Selection takes the whole line: no Select All while browsing, and no\n // search/filters/Exibir/Exportar once a row is ticked.\n exclusiveSelection\n rightControls={<ToolbarRightControls {...props} />}\n />\n </Box>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,OAAO,aAAa;AAiFZ,mBACE,KACE,YAFJ;AATR,SAAS,qBAAwD,OAA+C;AAC9G,QAAM,EAAE,cAAc,cAAc,YAAY,YAAY,cAAc,IAAI;AAC9E,SACE,iCAKG;AAAA,KAAC,MAAM,iBACN,iCACE;AAAA,0BAAC,QAAK,SAAQ,WAAU,IAAG,QACzB;AAAA,QAACA;AAAA,QAAA;AAAA,UACC,WAAU;AAAA,UACV,eAAa,GAAG,YAAY;AAAA,UAC5B,IAAI,EAAE,YAAY,SAAS;AAAA,UAE1B;AAAA;AAAA,YAAa;AAAA,YAAK;AAAA;AAAA;AAAA,MACrB,GACF;AAAA,MAIA;AAAA,QAAC;AAAA;AAAA,UACC,aAAY;AAAA,UACZ,UAAQ;AAAA,UACR,IAAI,EAAE,QAAQ,IAAI,WAAW,UAAU,IAAI,IAAI;AAAA;AAAA,MACjD;AAAA,OACF;AAAA,IAED,MAAM;AAAA,IAEP;AAAA,MAAC;AAAA;AAAA,QACC,GAAG,MAAM;AAAA,QACT;AAAA,QACA,WAAW,MAAM;AAAA,QACjB,MAAM,MAAM;AAAA,QACZ,SAAS,MAAM;AAAA;AAAA,IACjB;AAAA,IACC,MAAM,gBACL;AAAA,MAAC;AAAA;AAAA,QACC,QAAQ,MAAM;AAAA,QACd,OAAO,MAAM,EAAE;AAAA,QACf,YAAY,MAAM;AAAA,QAClB,aAAa,CAAC,GAAG,MAAM,EAAE,WAAW;AAAA,QACpC,SAAS,MAAM,cAAc,OAAO,CAAC,QAAQ,IAAI,OAAO,EAAE,IAAI,CAAC,SAAS,EAAE,IAA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1,93 @@
1
+ import {
2
+ HeaderButton
3
+ } from "./chunk-2CEV746H.js";
4
+
5
+ // src/components/form/HeaderActions/HeaderActions.tsx
6
+ import ExpandMoreIcon from "@mui/icons-material/ExpandMore";
7
+ import MoreHorizIcon from "@mui/icons-material/MoreHoriz";
8
+ import Box from "@mui/material/Box/index.js";
9
+ import ListItemIcon from "@mui/material/ListItemIcon/index.js";
10
+ import ListItemText from "@mui/material/ListItemText/index.js";
11
+ import Menu from "@mui/material/Menu/index.js";
12
+ import MenuItem from "@mui/material/MenuItem/index.js";
13
+ import { useState } from "react";
14
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
15
+ function present(actions) {
16
+ return actions.filter(
17
+ (action) => Boolean(action) && action.visible !== false
18
+ );
19
+ }
20
+ function HeaderActions({
21
+ actions,
22
+ moreLabel,
23
+ collapseBelow = "md",
24
+ testIdPrefix = "header-actions"
25
+ }) {
26
+ const [anchorEl, setAnchorEl] = useState(null);
27
+ const items = present(actions);
28
+ const open = Boolean(anchorEl);
29
+ const [primary, ...overflow] = items;
30
+ if (!primary) return null;
31
+ return /* @__PURE__ */ jsxs(Box, { sx: { display: "inline-flex", alignItems: "center", gap: 1 }, children: [
32
+ /* @__PURE__ */ jsx(
33
+ HeaderButton,
34
+ {
35
+ text: primary.text,
36
+ icon: primary.icon,
37
+ onClick: primary.onClick,
38
+ disabled: primary.disabled,
39
+ variant: primary.variant,
40
+ color: primary.color,
41
+ collapseBelow,
42
+ dataTestId: primary.dataTestId ?? primary.id
43
+ }
44
+ ),
45
+ overflow.length > 0 && /* @__PURE__ */ jsxs(Fragment, { children: [
46
+ /* @__PURE__ */ jsx(
47
+ HeaderButton,
48
+ {
49
+ text: moreLabel,
50
+ icon: /* @__PURE__ */ jsx(MoreHorizIcon, { fontSize: "small" }),
51
+ endIcon: /* @__PURE__ */ jsx(ExpandMoreIcon, { fontSize: "small" }),
52
+ onClick: (event) => setAnchorEl(event.currentTarget),
53
+ collapseBelow,
54
+ "aria-haspopup": "menu",
55
+ "aria-expanded": open,
56
+ dataTestId: `${testIdPrefix}-more-trigger`
57
+ }
58
+ ),
59
+ /* @__PURE__ */ jsx(
60
+ Menu,
61
+ {
62
+ anchorEl,
63
+ open,
64
+ onClose: () => setAnchorEl(null),
65
+ anchorOrigin: { vertical: "bottom", horizontal: "right" },
66
+ transformOrigin: { vertical: "top", horizontal: "right" },
67
+ "data-testid": `${testIdPrefix}-more-menu`,
68
+ children: overflow.map((action) => /* @__PURE__ */ jsxs(
69
+ MenuItem,
70
+ {
71
+ disabled: action.disabled,
72
+ onClick: () => {
73
+ setAnchorEl(null);
74
+ action.onClick?.();
75
+ },
76
+ "data-testid": action.dataTestId ?? action.id,
77
+ children: [
78
+ /* @__PURE__ */ jsx(ListItemIcon, { sx: { minWidth: 32 }, children: action.icon }),
79
+ /* @__PURE__ */ jsx(ListItemText, { children: action.text })
80
+ ]
81
+ },
82
+ action.id
83
+ ))
84
+ }
85
+ )
86
+ ] })
87
+ ] });
88
+ }
89
+
90
+ export {
91
+ HeaderActions
92
+ };
93
+ //# sourceMappingURL=chunk-N4JEQJBL.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/form/HeaderActions/HeaderActions.tsx"],"sourcesContent":["'use client';\n\nimport ExpandMoreIcon from '@mui/icons-material/ExpandMore';\nimport MoreHorizIcon from '@mui/icons-material/MoreHoriz';\nimport Box from '@mui/material/Box/index.js';\nimport ListItemIcon from '@mui/material/ListItemIcon/index.js';\nimport ListItemText from '@mui/material/ListItemText/index.js';\nimport Menu from '@mui/material/Menu/index.js';\nimport MenuItem from '@mui/material/MenuItem/index.js';\nimport React, { useState } from 'react';\n\nimport { HeaderButton } from '../HeaderButton';\nimport type { HeaderActionItem, HeaderActionsProps } from './HeaderActions.types';\n\n/** Drop the gated-away entries, so everything below can count what is left. */\nfunction present(\n actions: HeaderActionsProps['actions'],\n): HeaderActionItem[] {\n return actions.filter(\n (action): action is HeaderActionItem => Boolean(action) && (action as HeaderActionItem).visible !== false,\n );\n}\n\n/**\n * The page header's actions, as ONE control that scales with how many there\n * are: nothing, a button, or a button plus an overflow menu.\n *\n * | actions | renders |\n * |---|---|\n * | 0 | nothing at all — not an empty box, and not a menu with no items |\n * | 1 | that action, as an ordinary `HeaderButton` |\n * | n | the FIRST as a button; the other n−1 inside one dropdown |\n *\n * ## Why the first one stays a button\n *\n * A header whose every action lives behind a menu costs two clicks for the\n * thing the page is FOR — \"Novo produto\" on a catalog, \"Nova categoria\" on the\n * categories list. Folding it in with the exports and the reorder screens\n * would treat a merchant's daily action as equal to the one they use monthly.\n * So the array is in PRIORITY order and index 0 keeps its button; everything\n * after it is secondary by the caller's own declaration.\n *\n * ## Why this takes a list and not children\n *\n * The 0/1/n decision is only decidable over data. A component handed JSX can\n * count `React.Children`, but it cannot tell a gated-away action from an\n * absent one, cannot read a label to put in a menu row, and cannot re-render\n * a `<Button>` as a `<MenuItem>` without reaching into its props. Every\n * caller in the estate had therefore hand-written the row, which is how four\n * equally-weighted buttons ended up wrapping the line on a catalog page.\n *\n * ## One element, so the spacing is the component's and not the mount's\n *\n * It renders an `inline-flex` box rather than a fragment. A fragment inherits\n * whatever gap its parent happens to set, and the two mounts here set\n * different ones — a `Dashboard.Header` spaces its children, a\n * `Dashboard.Action` slot does not, which is why the pair of buttons in that\n * slot sat flush against each other. The gap belongs to the control.\n *\n * ## The ids survive the move\n *\n * An action that overflows keeps its `dataTestId` on its `MenuItem`. It is a\n * different element in a different place, and it must still answer to the same\n * selector: otherwise adding a fifth action to a header silently breaks the\n * suite of the action that got pushed out, which is the last place anyone\n * would look.\n */\nexport function HeaderActions({\n actions,\n moreLabel,\n collapseBelow = 'md',\n testIdPrefix = 'header-actions',\n}: HeaderActionsProps): React.JSX.Element | null {\n const [anchorEl, setAnchorEl] = useState<HTMLElement | null>(null);\n const items = present(actions);\n const open = Boolean(anchorEl);\n\n // Before the early return would be a conditional hook; after it is the only\n // legal place. Nothing below runs for an empty list anyway.\n const [primary, ...overflow] = items;\n if (!primary) return null;\n\n return (\n <Box sx={{ display: 'inline-flex', alignItems: 'center', gap: 1 }}>\n <HeaderButton\n text={primary.text}\n icon={primary.icon}\n onClick={primary.onClick}\n disabled={primary.disabled}\n variant={primary.variant}\n color={primary.color}\n collapseBelow={collapseBelow}\n dataTestId={primary.dataTestId ?? primary.id}\n />\n {overflow.length > 0 && (\n <>\n <HeaderButton\n text={moreLabel}\n icon={<MoreHorizIcon fontSize=\"small\" />}\n endIcon={<ExpandMoreIcon fontSize=\"small\" />}\n onClick={(event) => setAnchorEl(event.currentTarget)}\n collapseBelow={collapseBelow}\n aria-haspopup=\"menu\"\n aria-expanded={open}\n dataTestId={`${testIdPrefix}-more-trigger`}\n />\n <Menu\n anchorEl={anchorEl}\n open={open}\n onClose={() => setAnchorEl(null)}\n anchorOrigin={{ vertical: 'bottom', horizontal: 'right' }}\n transformOrigin={{ vertical: 'top', horizontal: 'right' }}\n data-testid={`${testIdPrefix}-more-menu`}\n >\n {overflow.map((action) => (\n <MenuItem\n key={action.id}\n disabled={action.disabled}\n onClick={() => {\n setAnchorEl(null);\n action.onClick?.();\n }}\n data-testid={action.dataTestId ?? action.id}\n >\n <ListItemIcon sx={{ minWidth: 32 }}>{action.icon}</ListItemIcon>\n <ListItemText>{action.text}</ListItemText>\n </MenuItem>\n ))}\n </Menu>\n </>\n )}\n </Box>\n );\n}\n"],"mappings":";;;;;AAEA,OAAO,oBAAoB;AAC3B,OAAO,mBAAmB;AAC1B,OAAO,SAAS;AAChB,OAAO,kBAAkB;AACzB,OAAO,kBAAkB;AACzB,OAAO,UAAU;AACjB,OAAO,cAAc;AACrB,SAAgB,gBAAgB;AA2E1B,SAWE,UAXF,KA+BQ,YA/BR;AArEN,SAAS,QACP,SACoB;AACpB,SAAO,QAAQ;AAAA,IACb,CAAC,WAAuC,QAAQ,MAAM,KAAM,OAA4B,YAAY;AAAA,EACtG;AACF;AA8CO,SAAS,cAAc;AAAA,EAC5B;AAAA,EACA;AAAA,E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ACnB;AAAA,cACA,eAAa,OAAO,cAAc,OAAO;AAAA,cAEzC;AAAA,oCAAC,gBAAa,IAAI,EAAE,UAAU,GAAG,GAAI,iBAAO,MAAK;AAAA,gBACjD,oBAAC,gBAAc,iBAAO,MAAK;AAAA;AAAA;AAAA,YATtB,OAAO;AAAA,UAUd,CACD;AAAA;AAAA,MACH;AAAA,OACF;AAAA,KAEJ;AAEJ;","names":[]}
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  GridShell
3
- } from "./chunk-Q4ITS2EP.js";
3
+ } from "./chunk-NJS4WCHA.js";
4
4
  import {
5
5
  useDataViewsState
6
- } from "./chunk-2UCJJACD.js";
6
+ } from "./chunk-ZLNKBKUB.js";
7
7
 
8
8
  // src/components/data-display/DataViews/DataViewsGrid.tsx
9
9
  import { useEffect, useRef } from "react";
@@ -27,4 +27,4 @@ function DataViewsGrid(props) {
27
27
  export {
28
28
  DataViewsGrid
29
29
  };
30
- //# sourceMappingURL=chunk-HNDUCGM3.js.map
30
+ //# sourceMappingURL=chunk-NI2ISQZI.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/data-display/DataViews/DataViewsGrid.tsx"],"sourcesContent":["\"use client\";\n\nimport { useEffect, useRef } from \"react\";\n\nimport { type SortFieldDefinition } from \"../../layout/ContentToolbar\";\n\nimport { GridShell } from \"./data-views-grid-parts\";\nimport type { SelectionExtraRender } from \"./data-views-selection-extra\";\nimport type { ListGroupConfig } from \"./list-card-rails\";\nimport type { DisplayPanelView } from \"./data-views-display-panel\";\nimport type { BoardConfig } from \"./DataViewsBoard\";\nimport type { DataViewExport } from \"./data-views-export\";\nimport type { ScopeConfig } from \"./data-views-scopes\";\nimport type { DataViewCardSelection } from \"./data-views-types\";\nimport {\n type DataViewColumn,\n type DataViewsLayout,\n type DataViewServer,\n type DataViewState,\n type DataViewSyncState,\n type FilterFieldConfig,\n type RangeFieldConfig,\n type RowAction,\n} from \"./data-views-types\";\nimport { useDataViewsState } from \"./use-data-views-state\";\n\ninterface DataViewsGridProps<T extends Record<string, unknown>> {\n rows: T[];\n columns: DataViewColumn<T>[];\n fields: FilterFieldConfig<T>[];\n /** Optional numeric min/max range filters (advanced \"filter by amount\"). */\n rangeFields?: RangeFieldConfig<T>[];\n getRowId: (row: T) => string | number;\n /** Row click opens the row; clicks in the actions column are ignored. */\n onRowClick?: (row: T) => void;\n emptyState?: React.ReactNode;\n dataTestId?: string;\n testIdPrefix?: string;\n /** Seed/replace the view state. A NEW reference re-applies (used to apply a saved view). */\n appliedState?: DataViewState;\n /**\n * URL-driven controls (search/pills/ranges/sort) that RE-APPLY on reference\n * change while preserving column visibility — for server-mode lists that keep\n * their filter/sort/page in the address bar (see {@link DataViewSyncState}).\n */\n syncState?: DataViewSyncState;\n /** Notified on every view-state change (so a save-view modal can read it). */\n onStateChange?: (state: DataViewState) => void;\n /**\n * Notified with the currently-visible (search + filter matched) rows whenever\n * they change — so a page-level Export exports what the user sees, not the\n * full dataset.\n */\n onVisibleRowsChange?: (rows: T[]) => void;\n /** Saved-views UI injected into the toolbar (FUT-89). */\n toolbarRightSlot?: React.ReactNode;\n /**\n * The saved-view chrome for the Exibir panel: its VISÃO header (with the\n * views dropdown) and its Redefinir / Salvar visão footer. Supplied by\n * `DataViewsTableBase`; without it the panel is tabs only.\n */\n displayView?: DisplayPanelView;\n /** Big page title in the header row (next to the funnel + gear). */\n title?: string;\n /** Primary page actions rendered at the header's right. */\n headerActions?: React.ReactNode;\n /**\n * Sort options for the toolbar's \"Sort By\" dropdown. Defaults to the sortable\n * columns (asc/desc each) when omitted.\n */\n sortFields?: SortFieldDefinition[];\n /**\n * Per-sort-field VALUE KIND (`\"currency\" | \"number\" | \"date\" | \"text\"`), so the\n * Exibir panel phrases the direction in that column's own terms. \"Crescente\"\n * on a currency column is a puzzle; \"Menor → maior\" is not. Defaults to text.\n */\n sortKinds?: Record<string, string>;\n /**\n * Opt-in \"Exportar\" control. The grid hands the host the current query,\n * UNPAGINATED, and the host re-queries — the grid never fetches, and an\n * export therefore follows the filters rather than the loaded page.\n */\n exportConfig?: DataViewExport;\n /**\n * A single, reusable list of row actions that drives BOTH the per-row \"⋮\"\n * kebab AND the bulk-actions menu (tabwoah model). When provided, the grid\n * appends a kebab actions column automatically (unless the page already\n * defines one) and shows an \"Ações\" bulk menu when rows are selected.\n */\n rowActions?: RowAction<T>[];\n /**\n * Extra leading control rendered in the auto kebab column, before the \"⋮\"\n * (e.g. a favourite star). Only used when `rowActions` is set.\n */\n rowActionsLeading?: (row: T) => React.ReactNode;\n /**\n * Low-level override for the selection bulk control. Prefer `rowActions`.\n * Receives the selected rows + a `clearSelection` callback.\n */\n bulkActions?: (selectedRows: T[], clearSelection: () => void) => React.ReactNode;\n /**\n * A control rendered beside the \"N selected\" count, for changing WHAT is\n * selected rather than what happens to it — a \"select all N matching the\n * filter\" widening, above all.\n *\n * Called only while something is selected, and handed\n * {@link SelectionExtraContext.allOnPageSelected} so the control can follow\n * the convention operators already know: the widening appears once the whole\n * page is ticked, and not before.\n */\n selectionExtra?: SelectionExtraRender<T>;\n /**\n * Render a bespoke per-row menu in the actions column instead of the auto\n * kebab — typically an entity's self-contained 3-dots menu that owns its own\n * popups, so the SAME menu component drives both the table row and the card.\n * `rowActions`/`bulkActions` still drive the multi-row bulk menu.\n */\n renderRowMenu?: (row: T) => React.ReactNode;\n /**\n * Opt-in \"Grade\" (cards) layout. When provided, a Grade/Tabela toggle appears in\n * the toolbar and the cards body renders each visible row via this function\n * (reusing the same search/filter/sort). Omit ⇒ table only (unchanged).\n */\n renderCard?: (row: T, selection: DataViewCardSelection) => React.ReactNode;\n /**\n * Opt-in \"Quadro\" (board) layout: the loaded page laid out as columns of one\n * grouping field. Reuses `renderCard`, so supplying a board WITHOUT one simply\n * offers no board. Best when the groups are states in a state machine — derive\n * these groups and `scopes` from ONE definition so the two cannot drift.\n */\n board?: BoardConfig<T>;\n /**\n * Opt-in \"Lista\" layout (FUT-733): one FULL-WIDTH row per record, rendered by\n * the entity — a marker, a title, a subtitle and a value on the right. Sits\n * between the table (compare columns) and the cards (browse); omit ⇒ not\n * offered, exactly as `renderCard` gates the cards.\n */\n renderListRow?: (row: T, selection: DataViewCardSelection) => React.ReactNode;\n /**\n * The Lista's SHARED COLUMNS — declared once for the list, obeyed by every row.\n *\n * This is what makes a list line up by construction rather than by convention.\n * Omit it and each row still resolves its own tracks from its own config,\n * which agrees with its neighbours right up until one row carries an unusually\n * wide value.\n */\n listGroup?: ListGroupConfig<T>;\n /**\n * The page-level partition rendered as an exclusive tab strip above the\n * toolbar, with server-supplied counts. Requires `server`: a scope is applied\n * at the backend, never in the browser.\n */\n scopes?: ScopeConfig[];\n /** The row field the scopes partition by — used only to reject a pill over the same field. */\n scopeFieldId?: string;\n /** Which layout to show first when the user has expressed no preference (default \"table\"). */\n defaultLayout?: DataViewsLayout;\n /**\n * Ignore the remembered cross-screen layout preference and pin to\n * `defaultLayout`. For tables that exist to SHOW a layout — stories, docs,\n * screenshots — not for real screens.\n */\n ignoreStoredLayout?: boolean;\n /**\n * Opt into the responsive inline filter UX (collapsible filter row on wide\n * screens, modal on narrow). Default `false` keeps the classic slide-in panel.\n */\n inlineFilters?: boolean;\n /** Keep the inline search visible with no filter fields and no active search. */\n alwaysShowSearch?: boolean;\n /** Server-mode wiring; when set the grid is backend-driven (no client filter/sort/paginate). */\n server?: DataViewServer;\n}\n\n/**\n * Surface the visible (filtered) rows so a page-level Export matches the view.\n *\n * Pages pass inline column/field arrays, so `matched` is a fresh reference on\n * every render even when its contents are unchanged. The guard is a signature\n * over the rows' *contents* (not just their ids), so the callback — and the\n * parent `useState` it usually drives — fires only when the visible data\n * actually changes. Ids alone are not enough: a server refresh can change a\n * visible row's values while keeping its id, and the export must reflect them.\n * Content-equal renders keep the same signature, so this never loops.\n */\nfunction useVisibleRowsNotifier<T>(matched: T[], onVisibleRowsChange?: (rows: T[]) => void): void {\n const visibleSignature = JSON.stringify(matched);\n const lastSignature = useRef<string | null>(null);\n useEffect(() => {\n if (lastSignature.current === visibleSignature) return;\n lastSignature.current = visibleSignature;\n onVisibleRowsChange?.(matched);\n }, [visibleSignature, matched, onVisibleRowsChange]);\n}\n\n/**\n * The reusable admin DataViews table (FUT-88): the shared ContentToolbar +\n * TableFilter panel over `@12-apps/ui` DataGrid. State + derived data live in\n * {@link useDataViewsState}; the render lives in `GridShell`. This component just\n * connects the two. Reused across every admin list page.\n */\nexport function DataViewsGrid<T extends Record<string, unknown>>(\n props: DataViewsGridProps<T>,\n): React.JSX.Element {\n // Forwarded as a whole rather than restated name-by-name twice: this component\n // only ADDS the controller, and a 25-name destructure repeated in the JSX is\n // where a newly added prop silently stops being passed on.\n const { rangeFields = [], testIdPrefix = \"table\" } = props;\n const controller = useDataViewsState({ ...props, rangeFields, testIdPrefix });\n useVisibleRowsNotifier(controller.matched, props.onVisibleRowsChange);\n return <GridShell {...props} c={controller} rangeFields={rangeFields} testIdPrefix={testIdPrefix} />;\n}\n"],"mappings":";;;;;;;;AAEA,SAAS,WAAW,cAAc;AAgNzB;AAzBT,SAAS,uBAA0B,SAAc,qBAAiD;AAChG,QAAM,mBAAmB,KAAK,UAAU,OAAO;AAC/C,QAAM,gBAAgB,OAAsB,IAAI;AAChD,YAAU,MAAM;AACd,QAAI,cAAc,YAAY,iBAAkB;AAChD,kBAAc,UAAU;AACxB,0BAAsB,OAAO;AAAA,EAC/B,GAAG,CAAC,kBAAkB,SAAS,mBAAmB,CAAC;AACrD;AAQO,SAAS,cACd,OACmB;AAInB,QAAM,EAAE,cAAc,CAAC,GAAG,eAAe,QAAQ,IAAI;AACrD,QAAM,aAAa,kBAAkB,EAAE,GAAG,OAAO,aAAa,aAAa,CAAC;AAC5E,yBAAuB,WAAW,SAAS,MAAM,mBAAmB;AACpE,SAAO,oBAAC,aAAW,GAAG,OAAO,GAAG,YAAY,aAA0B,cAA4B;AACpG;","names":[]}
@@ -1,16 +1,19 @@
1
- import {
2
- FilterDialog,
3
- GridFilterPanel
4
- } from "./chunk-4VNUOSTQ.js";
5
1
  import {
6
2
  DataViewsEmpty
7
3
  } from "./chunk-S7CAXRRP.js";
8
4
  import {
9
5
  InlineFilterControls
10
- } from "./chunk-RUO4D4N6.js";
6
+ } from "./chunk-NKCKIGRL.js";
7
+ import {
8
+ GridHeaderRow
9
+ } from "./chunk-A4YWFX5C.js";
11
10
  import {
12
11
  GridMain
13
- } from "./chunk-QQE2PVLO.js";
12
+ } from "./chunk-RXYSP56G.js";
13
+ import {
14
+ FilterDialog,
15
+ GridFilterPanel
16
+ } from "./chunk-6YFMGNSA.js";
14
17
  import {
15
18
  DataViewsPagination
16
19
  } from "./chunk-VR5HDUBK.js";
@@ -18,19 +21,22 @@ import {
18
21
  toOverflowFields,
19
22
  useFilterOverflow
20
23
  } from "./chunk-TQ6FPOPD.js";
24
+ import {
25
+ ScopeTabsSlot
26
+ } from "./chunk-Y5UCOBQN.js";
21
27
  import {
22
28
  ShellToolbar
23
- } from "./chunk-AWTERXCW.js";
29
+ } from "./chunk-LDMXHDZ5.js";
24
30
  import {
25
- ScopeTabsSlot
26
- } from "./chunk-OGGHD64H.js";
31
+ resolveSelectionExtra
32
+ } from "./chunk-KX75HM5U.js";
33
+ import {
34
+ togglePillValues
35
+ } from "./chunk-5VZPVDUF.js";
27
36
  import {
28
37
  DataViewsLayoutProvider,
29
38
  useDataViewsLayout
30
39
  } from "./chunk-ZPIMPOHV.js";
31
- import {
32
- togglePillValues
33
- } from "./chunk-5VZPVDUF.js";
34
40
  import {
35
41
  useDataViewsCopy
36
42
  } from "./chunk-KHG57NAE.js";
@@ -39,42 +45,11 @@ import {
39
45
  } from "./chunk-J3JGO6Y6.js";
40
46
  import {
41
47
  default as default2
42
- } from "./chunk-6DPAWXZ3.js";
43
- import {
44
- default as default3
45
48
  } from "./chunk-WEBEOBN5.js";
46
- import {
47
- Text
48
- } from "./chunk-VRHBJXZ7.js";
49
49
 
50
50
  // src/components/data-display/DataViews/data-views-grid-parts.tsx
51
51
  import { useEffect, useState } from "react";
52
52
  import { jsx, jsxs } from "react/jsx-runtime";
53
- function GridHeaderRow({
54
- title,
55
- headerActions,
56
- testIdPrefix
57
- }) {
58
- if (!title && !headerActions) return null;
59
- return /* @__PURE__ */ jsxs(
60
- default2,
61
- {
62
- "data-testid": `${testIdPrefix}-header`,
63
- sx: {
64
- display: "flex",
65
- alignItems: "center",
66
- justifyContent: "space-between",
67
- gap: 2,
68
- flexWrap: "wrap",
69
- pb: 1.5
70
- },
71
- children: [
72
- title ? /* @__PURE__ */ jsx(Text, { variant: "heading", size: "lg", as: "h2", children: title }) : /* @__PURE__ */ jsx(default2, {}),
73
- headerActions && /* @__PURE__ */ jsx(default2, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: headerActions })
74
- ]
75
- }
76
- );
77
- }
78
53
  function LayoutStateSync({
79
54
  c
80
55
  }) {
@@ -152,7 +127,7 @@ function ShellStack({
152
127
  open: c.filterOpen,
153
128
  onOpenChange: c.setFilterOpen,
154
129
  hasActiveFilters: c.activeFilterCount > 0,
155
- children: /* @__PURE__ */ jsxs(default3, { spacing: 0, "data-testid": dataTestId ? `${dataTestId}-container` : void 0, children: [
130
+ children: /* @__PURE__ */ jsxs(default2, { spacing: 0, "data-testid": dataTestId ? `${dataTestId}-container` : void 0, children: [
156
131
  /* @__PURE__ */ jsx(GridHeaderRow, { title: props.title, headerActions: props.headerActions, testIdPrefix }),
157
132
  /* @__PURE__ */ jsx(
158
133
  ShellToolbar,
@@ -175,6 +150,7 @@ function ShellStack({
175
150
  testIdPrefix,
176
151
  rowActions: props.rowActions,
177
152
  bulkActions: props.bulkActions,
153
+ selectionExtra: resolveSelectionExtra(props),
178
154
  toolbarRightSlot: props.toolbarRightSlot,
179
155
  compactControls: showInline && split.compactControls,
180
156
  counterHidden: showInline && split.counterHidden,
@@ -261,4 +237,4 @@ function GridShell(props) {
261
237
  export {
262
238
  GridShell
263
239
  };
264
- //# sourceMappingURL=chunk-Q4ITS2EP.js.map
240
+ //# sourceMappingURL=chunk-NJS4WCHA.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/data-display/DataViews/data-views-grid-parts.tsx"],"sourcesContent":["\"use client\";\n\nimport { useEffect, useState } from \"react\";\n\nimport { TableFilter } from \"../../layout/TableFilter\";\nimport { Stack } from \"../../../mui/Stack\";\n\nimport {\n DataViewsLayoutProvider,\n useDataViewsLayout,\n type DataViewsLayout,\n} from \"./data-views-layout-context\";\nimport { FilterDialog, GridFilterPanel } from \"./data-views-filter-panel\";\nimport { GridMain } from \"./data-views-grid-bodies\";\nimport type { ListGroupConfig } from \"./list-card-rails\";\nimport { InlineFilterControls } from \"./data-views-inline-bar\";\nimport { toOverflowFields, useFilterOverflow, type OverflowSplit } from \"./data-views-overflow\";\nimport { GridHeaderRow } from \"./data-views-header-row\";\nimport { resolveSelectionExtra, type SelectionExtraRender } from \"./data-views-selection-extra\";\nimport { ShellToolbar } from \"./data-views-shell-toolbar\";\nimport type { DisplayPanelView } from \"./data-views-display-panel\";\nimport type { DataViewExport } from \"./data-views-export\";\nimport { useDataViewsCopy } from \"./data-views-copy-context\";\nimport { DataViewsEmpty } from \"./data-views-empty\";\nimport { DataViewsPagination } from \"./data-views-pagination\";\nimport type { BoardConfig } from \"./DataViewsBoard\";\nimport { type ScopeConfig } from \"./data-views-scopes\";\nimport { ScopeTabsSlot } from \"./data-views-scope-tabs\";\nimport { togglePillValues } from \"./data-views-grid-helpers\";\nimport type {\n DataViewCardSelection,\n FilterFieldConfig,\n RangeFieldConfig,\n RangeValue,\n RowAction,\n} from \"./data-views-types\";\nimport type { DataViewsController } from \"./use-data-views-state\";\n\n/* ── Layout ⇄ view-state mirror ──────────────────────────────────────────── */\n\n/**\n * Mirrors the LIVE layout back into the view state, so saving a view captures\n * the layout the user is actually looking at.\n *\n * A component rather than a callback prop because only something INSIDE the\n * provider can read the layout, and only the controller can write the state.\n * The `stored !== layout` guard is what makes it idempotent: `c` is rebuilt on\n * every render, so an unguarded effect here would patch → re-render → patch.\n *\n * It re-fires when `stored` changes too, which is the case that matters after\n * applying a saved view: `appliedState` REPLACES the state, so a view saved\n * before layouts were captured clears `state.layout`, and the mirror puts the\n * current one back rather than leaving the next save with nothing to store.\n */\nfunction LayoutStateSync<T extends Record<string, unknown>>({\n c,\n}: {\n c: DataViewsController<T>;\n}): null {\n const { layout } = useDataViewsLayout();\n const stored = c.state.layout;\n useEffect(() => {\n if (stored !== layout) c.patch({ layout });\n // `c` is intentionally out of the deps — see the guard above.\n }, [layout, stored]);\n return null;\n}\n\n/* ── Shell (composes toolbar + body + panel) ─────────────────────────────── */\n\n/** The shared filter-surface props consumed by the inline bar, panel, and modal. */\ninterface FilterSurfaceProps<T extends Record<string, unknown>> {\n testIdPrefix: string;\n search: string;\n fields: FilterFieldConfig<T>[];\n rangeFields: RangeFieldConfig<T>[];\n pills: Record<string, string[]>;\n ranges: Record<string, RangeValue>;\n onSearchChange: (value: string) => void;\n onTogglePill: (fieldId: string, value: string, checked: boolean) => void;\n onChangeRange: (fieldId: string, range: RangeValue) => void;\n onClearField: (fieldId: string) => void;\n onClearAll: () => void;\n}\n\n/**\n * Derives the responsive filter state (which surface to show at this width) and\n * the filter-mutation handlers from the controller — pulled out of `GridShell`\n * so the component body stays under the size/complexity budget.\n */\n/** Grouped rather than positional: the list had grown past readability. */\ninterface GridShellFiltersArgs<T extends Record<string, unknown>> {\n c: DataViewsController<T>;\n inlineFilters: boolean;\n fields: FilterFieldConfig<T>[];\n rangeFields: RangeFieldConfig<T>[];\n testIdPrefix: string;\n alwaysShowSearch: boolean;\n /** Is \"Exportar\" on the bar? Half the right cluster's cost when it is not. */\n hasExport: boolean;\n}\n\nfunction useGridShellFilters<T extends Record<string, unknown>>({\n c,\n inlineFilters,\n fields,\n rangeFields,\n testIdPrefix,\n alwaysShowSearch,\n hasExport,\n}: GridShellFiltersArgs<T>): {\n showInline: boolean;\n useModal: boolean;\n inlineVisible: boolean;\n filterProps: FilterSurfaceProps<T>;\n split: OverflowSplit<T>;\n onControlOpenChange: (open: boolean) => void;\n} {\n const { state } = c;\n // How many filter controls are open. A COUNT, not a flag: closing one popover\n // by opening another overlaps, and a boolean would unfreeze mid-handover.\n const [openControls, setOpenControls] = useState(0);\n // ONE measurement for the whole shell: the filter row decides which controls\n // it can keep, and the TOOLBAR needs the same answer to drop its labels.\n // Measuring twice would let the two disagree at the crossover width.\n const split = useFilterOverflow(\n toOverflowFields(fields, rangeFields),\n state.pills,\n c.ranges,\n openControls > 0,\n hasExport,\n );\n // THE BAR RENDERS AT EVERY WIDTH. It used to be swapped for a full-screen\n // filter MODAL below `lg`, which was the responsive strategy before the\n // measured ladder existed — and the two now do the same job, badly together:\n // the modal took the bar away at 1199px, and with it the very degradation\n // (labels off, search collapsed, filters into \"Mais\") that exists to make a\n // narrow bar work. So a 900px window got no bar and no ladder, and the\n // operator lost the search entirely rather than gaining a compact one.\n //\n // The ladder is measured, so it already covers every width the modal did.\n const showInline = inlineFilters;\n const useModal = false;\n const inlineVisible =\n showInline &&\n (alwaysShowSearch || fields.length > 0 || rangeFields.length > 0 || state.search !== \"\");\n const filterProps: FilterSurfaceProps<T> = {\n testIdPrefix,\n search: state.search,\n fields,\n rangeFields,\n pills: state.pills,\n ranges: c.ranges,\n onSearchChange: (value) => c.patch({ search: value }),\n // Updater, never the render's `state` — see {@link DataViewStatePatch}.\n onTogglePill: (fieldId, value, checked) =>\n c.patch(({ pills }) => ({ pills: { ...pills, [fieldId]: togglePillValues(pills[fieldId], value, checked) } })),\n onChangeRange: (fieldId, range) => c.patch({ ranges: { ...c.ranges, [fieldId]: range } }),\n onClearField: (fieldId) => c.patch({ pills: { ...state.pills, [fieldId]: [] } }),\n onClearAll: () => c.patch({ search: \"\", pills: {}, ranges: {} }),\n };\n return {\n showInline,\n useModal,\n inlineVisible,\n filterProps,\n split,\n onControlOpenChange: (open) =>\n setOpenControls((count) => Math.max(0, count + (open ? 1 : -1))),\n };\n}\n\ninterface GridShellProps<T extends Record<string, unknown>> {\n c: DataViewsController<T>;\n rows: T[];\n fields: FilterFieldConfig<T>[];\n rangeFields: RangeFieldConfig<T>[];\n getRowId: (row: T) => string | number;\n testIdPrefix: string;\n dataTestId?: string;\n emptyState?: React.ReactNode;\n toolbarRightSlot?: React.ReactNode;\n rowActions?: RowAction<T>[];\n bulkActions?: (selectedRows: T[], clearSelection: () => void) => React.ReactNode;\n /** A widening control beside the selection count — see `resolveSelectionExtra`. */\n selectionExtra?: SelectionExtraRender<T>;\n /** Opt-in \"Grade\" (cards) layout: renders each row as an entity-supplied card.\n * Omit ⇒ table only (no layout toggle). */\n renderCard?: (row: T, selection: DataViewCardSelection) => React.ReactNode;\n /**\n * Opt-in \"Quadro\" (board) layout. Needs `renderCard` too — the board reuses\n * the entity's card, so a board config without one simply offers no board\n * rather than failing: that is a config gap, not a runtime error.\n */\n board?: BoardConfig<T>;\n /** Opt-in \"Lista\" layout: one full-width, entity-rendered row per record. */\n renderListRow?: (row: T, selection: DataViewCardSelection) => React.ReactNode;\n /** The Lista's shared columns, so its rows line up by construction. */\n listGroup?: ListGroupConfig<T>;\n /** The page-level partition rendered as tabs under the toolbar. */\n scopes?: ScopeConfig[];\n /**\n * The row field the scopes partition by. Compared against the board's\n * `groupBy` so the two are not shown as the same partition twice.\n */\n scopeFieldId?: string;\n /** Per-sort-field value kind, so directions read in the column's own terms. */\n sortKinds?: Record<string, string>;\n /** The saved-view chrome bracketing the Exibir panel. */\n displayView?: DisplayPanelView;\n /** Injected export — the host re-queries; the grid never fetches. */\n exportConfig?: DataViewExport;\n /** Page title in the grid's own header row, above the scopes + toolbar. */\n title?: string;\n /** Primary page actions rendered at the header row's right. */\n headerActions?: React.ReactNode;\n /** Which layout to show first when the user has expressed no preference (default \"table\"). */\n defaultLayout?: DataViewsLayout;\n /** Pin to `defaultLayout`, ignoring the remembered preference (stories/docs). */\n ignoreStoredLayout?: boolean;\n /**\n * Opt into the responsive inline filter UX: a collapsible filter row below the\n * toolbar on wide screens and a modal on narrow ones. When false (default),\n * keep the classic slide-in filter panel opened by the \"Filtros\" button.\n */\n inlineFilters?: boolean;\n /**\n * Keep the inline search box on screen even with no filter fields and no\n * active search. Without it a grid whose only filter IS the search (`fields`\n * empty) can never OFFER one: the row renders only once a search exists, so\n * the operator would have to hand-edit the URL to start one. Default false —\n * every grid that ships filter fields already shows the row.\n */\n alwaysShowSearch?: boolean;\n}\n\n/** The scrollable content region: scope tabs, toolbar, filter bar, body, pager. */\nfunction ShellStack<T extends Record<string, unknown>>({\n props,\n filters,\n}: {\n props: GridShellProps<T>;\n filters: ReturnType<typeof useGridShellFilters<T>>;\n}): React.JSX.Element {\n const copy = useDataViewsCopy();\n const { c, testIdPrefix, dataTestId, scopes = [], emptyState, inlineFilters = false } = props;\n const { showInline, useModal, inlineVisible, filterProps, split, onControlOpenChange } = filters;\n // The grid renders the FILTERED empty state itself — it is the only party\n // that knows a filter is applied. See {@link DataViewsEmpty}.\n const body = (\n <DataViewsEmpty\n filtered={c.activeFilterCount > 0 || c.state.search !== \"\"}\n onClearFilters={() => c.patch({ search: \"\", pills: {}, ranges: {} })}\n emptyState={emptyState}\n testIdPrefix={testIdPrefix}\n />\n );\n return (\n <TableFilter\n copy={copy.tableFilter} open={c.filterOpen} onOpenChange={c.setFilterOpen}\n hasActiveFilters={c.activeFilterCount > 0}\n >\n <Stack spacing={0} data-testid={dataTestId ? `${dataTestId}-container` : undefined}>\n <GridHeaderRow title={props.title} headerActions={props.headerActions} testIdPrefix={testIdPrefix} />\n <ShellToolbar\n c={c}\n rows={props.rows}\n sortKinds={props.sortKinds}\n displayView={props.displayView}\n exportConfig={props.exportConfig}\n filterControls={\n inlineVisible ? (\n <InlineFilterControls\n {...filterProps} split={split} activeFilterCount={c.activeFilterCount}\n onControlOpenChange={onControlOpenChange}\n />\n ) : undefined\n }\n barRef={split.barRef}\n testIdPrefix={testIdPrefix}\n rowActions={props.rowActions}\n bulkActions={props.bulkActions}\n selectionExtra={resolveSelectionExtra(props)}\n toolbarRightSlot={props.toolbarRightSlot}\n compactControls={showInline && split.compactControls}\n counterHidden={showInline && split.counterHidden}\n showInline={showInline}\n />\n <ScopeTabsSlot\n scopes={scopes} scopeFieldId={props.scopeFieldId} board={props.board}\n value={c.scope} onChange={c.setScope} counts={c.scopeCounts}\n testIdPrefix={testIdPrefix}\n />\n <TableFilter.Layout>\n <TableFilter.Main>\n <GridMain\n c={c}\n getRowId={props.getRowId}\n renderCard={props.renderCard}\n renderListRow={props.renderListRow}\n listGroup={props.listGroup}\n board={props.board}\n dataTestId={dataTestId}\n testIdPrefix={testIdPrefix}\n emptyState={body}\n />\n <DataViewsPagination c={c} testIdPrefix={testIdPrefix} />\n </TableFilter.Main>\n {inlineFilters ? null : <GridFilterPanel {...filterProps} />}\n </TableFilter.Layout>\n {useModal && <FilterDialog open={c.filterOpen} onClose={() => c.setFilterOpen(false)} {...filterProps} />}\n </Stack>\n </TableFilter>\n );\n}\n\nexport function GridShell<T extends Record<string, unknown>>(props: GridShellProps<T>): React.JSX.Element {\n const {\n c,\n fields,\n rangeFields,\n testIdPrefix,\n renderCard,\n renderListRow,\n board,\n defaultLayout,\n ignoreStoredLayout,\n inlineFilters = false,\n alwaysShowSearch = false,\n } = props;\n const filters = useGridShellFilters({\n c,\n inlineFilters,\n fields,\n rangeFields,\n testIdPrefix,\n alwaysShowSearch,\n hasExport: props.exportConfig !== undefined,\n });\n return (\n <DataViewsLayoutProvider\n canUseCards={Boolean(renderCard)}\n canUseList={Boolean(renderListRow)}\n // The board reuses the entity's card, so it needs BOTH — a `board` with no\n // `renderCard` offers no board rather than throwing.\n canUseBoard={Boolean(board && renderCard)}\n defaultLayout={defaultLayout}\n ignoreStoredLayout={ignoreStoredLayout}\n viewLayout={c.state.layout}\n >\n <LayoutStateSync c={c} />\n <ShellStack props={props} filters={filters} />\n </DataViewsLayoutProvider>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,SAAS,WAAW,gBAAgB;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