@mui/x-data-grid 5.13.0 → 5.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 (355) hide show
  1. package/CHANGELOG.md +156 -6
  2. package/DataGrid/DataGrid.js +6 -0
  3. package/DataGrid/useDataGridComponent.js +1 -1
  4. package/DataGrid/useDataGridProps.js +1 -0
  5. package/colDef/gridActionsColDef.js +2 -0
  6. package/colDef/gridBooleanColDef.js +3 -1
  7. package/colDef/gridCheckboxSelectionColDef.js +2 -0
  8. package/colDef/gridDateOperators.d.ts +1 -1
  9. package/colDef/gridDateOperators.js +4 -2
  10. package/colDef/gridNumericOperators.js +4 -2
  11. package/colDef/gridStringColDef.d.ts +3 -0
  12. package/colDef/gridStringColDef.js +6 -0
  13. package/colDef/gridStringOperators.js +4 -2
  14. package/components/GridRow.js +5 -1
  15. package/components/base/GridOverlays.js +4 -1
  16. package/components/cell/GridBooleanCell.d.ts +5 -2
  17. package/components/cell/GridBooleanCell.js +93 -2
  18. package/components/cell/GridEditDateCell.js +5 -1
  19. package/components/cell/index.d.ts +1 -0
  20. package/components/cell/index.js +1 -0
  21. package/components/columnSelection/GridCellCheckboxRenderer.js +12 -1
  22. package/components/containers/GridRoot.js +4 -2
  23. package/components/containers/GridRootStyles.js +10 -0
  24. package/components/toolbar/GridToolbarExport.js +20 -10
  25. package/constants/gridClasses.d.ts +41 -1
  26. package/constants/gridClasses.js +1 -1
  27. package/constants/localeTextConstants.js +9 -2
  28. package/hooks/core/pipeProcessing/gridPipeProcessingApi.d.ts +2 -1
  29. package/hooks/features/columns/useGridColumnSpanning.js +9 -7
  30. package/hooks/features/columns/useGridColumns.d.ts +1 -1
  31. package/hooks/features/columns/useGridColumns.js +13 -6
  32. package/hooks/features/dimensions/useGridDimensions.js +6 -1
  33. package/hooks/features/editRows/useGridCellEditing.new.d.ts +1 -1
  34. package/hooks/features/editRows/useGridCellEditing.new.js +7 -4
  35. package/hooks/features/editRows/useGridEditing.new.d.ts +1 -1
  36. package/hooks/features/editRows/useGridEditing.new.js +4 -0
  37. package/hooks/features/editRows/useGridEditing.old.js +1 -1
  38. package/hooks/features/editRows/useGridRowEditing.new.d.ts +1 -1
  39. package/hooks/features/editRows/useGridRowEditing.new.js +3 -3
  40. package/hooks/features/export/utils.d.ts +1 -1
  41. package/hooks/features/export/utils.js +16 -2
  42. package/hooks/features/filter/gridFilterUtils.js +6 -0
  43. package/hooks/features/filter/useGridFilter.d.ts +1 -1
  44. package/hooks/features/filter/useGridFilter.js +30 -5
  45. package/hooks/features/keyboardNavigation/useGridKeyboardNavigation.d.ts +1 -1
  46. package/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +42 -34
  47. package/hooks/features/pagination/useGridPage.js +4 -3
  48. package/hooks/features/pagination/useGridPageSize.js +7 -4
  49. package/hooks/features/preferencesPanel/useGridPreferencesPanel.d.ts +1 -1
  50. package/hooks/features/preferencesPanel/useGridPreferencesPanel.js +12 -4
  51. package/hooks/features/rows/gridRowsSelector.d.ts +14 -0
  52. package/hooks/features/rows/gridRowsSelector.js +20 -1
  53. package/hooks/features/rows/gridRowsState.d.ts +8 -1
  54. package/hooks/features/rows/gridRowsUtils.d.ts +5 -1
  55. package/hooks/features/rows/gridRowsUtils.js +21 -3
  56. package/hooks/features/rows/index.d.ts +1 -1
  57. package/hooks/features/rows/index.js +1 -1
  58. package/hooks/features/rows/useGridRowsMeta.js +19 -4
  59. package/hooks/features/rows/useGridRowsPreProcessors.js +2 -1
  60. package/hooks/features/scroll/useGridScroll.js +7 -2
  61. package/hooks/features/selection/useGridSelection.js +28 -10
  62. package/hooks/features/sorting/gridSortingUtils.d.ts +1 -0
  63. package/hooks/features/sorting/gridSortingUtils.js +10 -11
  64. package/hooks/features/sorting/useGridSorting.d.ts +1 -1
  65. package/hooks/features/sorting/useGridSorting.js +42 -6
  66. package/hooks/features/statePersistence/gridStatePersistenceInterface.d.ts +12 -1
  67. package/hooks/features/statePersistence/index.d.ts +1 -1
  68. package/hooks/features/statePersistence/useGridStatePersistence.js +2 -2
  69. package/hooks/features/virtualization/useGridVirtualScroller.d.ts +3 -1
  70. package/hooks/features/virtualization/useGridVirtualScroller.js +46 -21
  71. package/hooks/utils/useGridApiEventHandler.d.ts +2 -2
  72. package/hooks/utils/useGridNativeEventListener.d.ts +1 -1
  73. package/hooks/utils/useGridNativeEventListener.js +1 -1
  74. package/index.js +1 -1
  75. package/internals/index.d.ts +6 -3
  76. package/internals/index.js +5 -2
  77. package/legacy/DataGrid/DataGrid.js +6 -0
  78. package/legacy/DataGrid/useDataGridComponent.js +1 -1
  79. package/legacy/DataGrid/useDataGridProps.js +1 -0
  80. package/legacy/colDef/gridActionsColDef.js +2 -0
  81. package/legacy/colDef/gridBooleanColDef.js +3 -1
  82. package/legacy/colDef/gridCheckboxSelectionColDef.js +2 -0
  83. package/legacy/colDef/gridDateOperators.js +4 -2
  84. package/legacy/colDef/gridNumericOperators.js +4 -2
  85. package/legacy/colDef/gridStringColDef.js +6 -0
  86. package/legacy/colDef/gridStringOperators.js +4 -2
  87. package/legacy/components/GridRow.js +5 -1
  88. package/legacy/components/base/GridOverlays.js +4 -1
  89. package/legacy/components/cell/GridBooleanCell.js +93 -2
  90. package/legacy/components/cell/GridEditDateCell.js +5 -1
  91. package/legacy/components/cell/index.js +1 -0
  92. package/legacy/components/columnSelection/GridCellCheckboxRenderer.js +11 -1
  93. package/legacy/components/containers/GridRoot.js +4 -2
  94. package/legacy/components/containers/GridRootStyles.js +3 -3
  95. package/legacy/components/toolbar/GridToolbarExport.js +20 -10
  96. package/legacy/constants/gridClasses.js +1 -1
  97. package/legacy/constants/localeTextConstants.js +9 -2
  98. package/legacy/hooks/features/columns/useGridColumnSpanning.js +9 -7
  99. package/legacy/hooks/features/columns/useGridColumns.js +13 -8
  100. package/legacy/hooks/features/dimensions/useGridDimensions.js +6 -1
  101. package/legacy/hooks/features/editRows/useGridCellEditing.new.js +7 -4
  102. package/legacy/hooks/features/editRows/useGridEditing.new.js +4 -0
  103. package/legacy/hooks/features/editRows/useGridEditing.old.js +1 -1
  104. package/legacy/hooks/features/editRows/useGridRowEditing.new.js +3 -3
  105. package/legacy/hooks/features/export/utils.js +21 -2
  106. package/legacy/hooks/features/filter/gridFilterUtils.js +6 -0
  107. package/legacy/hooks/features/filter/useGridFilter.js +30 -5
  108. package/legacy/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +47 -34
  109. package/legacy/hooks/features/pagination/useGridPage.js +4 -3
  110. package/legacy/hooks/features/pagination/useGridPageSize.js +7 -4
  111. package/legacy/hooks/features/preferencesPanel/useGridPreferencesPanel.js +12 -4
  112. package/legacy/hooks/features/rows/gridRowsSelector.js +23 -0
  113. package/legacy/hooks/features/rows/gridRowsUtils.js +21 -3
  114. package/legacy/hooks/features/rows/index.js +1 -1
  115. package/legacy/hooks/features/rows/useGridRowsMeta.js +19 -4
  116. package/legacy/hooks/features/rows/useGridRowsPreProcessors.js +2 -1
  117. package/legacy/hooks/features/scroll/useGridScroll.js +7 -2
  118. package/legacy/hooks/features/selection/useGridSelection.js +30 -12
  119. package/legacy/hooks/features/sorting/gridSortingUtils.js +11 -12
  120. package/legacy/hooks/features/sorting/useGridSorting.js +42 -6
  121. package/legacy/hooks/features/statePersistence/useGridStatePersistence.js +2 -1
  122. package/legacy/hooks/features/virtualization/useGridVirtualScroller.js +51 -25
  123. package/legacy/hooks/utils/useGridNativeEventListener.js +1 -1
  124. package/legacy/index.js +1 -1
  125. package/legacy/internals/index.js +5 -2
  126. package/legacy/locales/arSD.js +8 -1
  127. package/legacy/locales/bgBG.js +8 -1
  128. package/legacy/locales/csCZ.js +8 -1
  129. package/legacy/locales/daDK.js +8 -1
  130. package/legacy/locales/deDE.js +12 -5
  131. package/legacy/locales/elGR.js +8 -1
  132. package/legacy/locales/esES.js +8 -1
  133. package/legacy/locales/faIR.js +8 -1
  134. package/legacy/locales/fiFI.js +8 -1
  135. package/legacy/locales/frFR.js +18 -11
  136. package/legacy/locales/heIL.js +9 -2
  137. package/legacy/locales/huHU.js +8 -1
  138. package/legacy/locales/index.js +2 -1
  139. package/legacy/locales/itIT.js +8 -1
  140. package/legacy/locales/jaJP.js +11 -4
  141. package/legacy/locales/koKR.js +8 -1
  142. package/legacy/locales/nbNO.js +9 -2
  143. package/legacy/locales/nlNL.js +21 -14
  144. package/legacy/locales/plPL.js +8 -1
  145. package/legacy/locales/ptBR.js +17 -10
  146. package/legacy/locales/roRO.js +12 -5
  147. package/legacy/locales/ruRU.js +8 -1
  148. package/legacy/locales/skSK.js +9 -2
  149. package/legacy/locales/svSE.js +9 -2
  150. package/legacy/locales/trTR.js +8 -1
  151. package/legacy/locales/ukUA.js +8 -1
  152. package/legacy/locales/viVN.js +8 -1
  153. package/legacy/locales/zhCN.js +38 -27
  154. package/legacy/locales/zhTW.js +135 -0
  155. package/legacy/models/events/gridEvents.js +1 -0
  156. package/locales/arSD.js +8 -1
  157. package/locales/bgBG.js +8 -1
  158. package/locales/csCZ.js +8 -1
  159. package/locales/daDK.js +8 -1
  160. package/locales/deDE.js +12 -5
  161. package/locales/elGR.js +8 -1
  162. package/locales/esES.js +8 -1
  163. package/locales/faIR.js +8 -1
  164. package/locales/fiFI.js +8 -1
  165. package/locales/frFR.js +18 -11
  166. package/locales/heIL.js +9 -2
  167. package/locales/huHU.js +8 -1
  168. package/locales/index.d.ts +1 -0
  169. package/locales/index.js +2 -1
  170. package/locales/itIT.js +8 -1
  171. package/locales/jaJP.js +11 -4
  172. package/locales/koKR.js +8 -1
  173. package/locales/nbNO.js +9 -2
  174. package/locales/nlNL.js +21 -14
  175. package/locales/plPL.js +8 -1
  176. package/locales/ptBR.js +17 -10
  177. package/locales/roRO.js +12 -5
  178. package/locales/ruRU.js +8 -1
  179. package/locales/skSK.js +9 -2
  180. package/locales/svSE.js +9 -2
  181. package/locales/trTR.js +8 -1
  182. package/locales/ukUA.js +8 -1
  183. package/locales/viVN.js +8 -1
  184. package/locales/zhCN.js +34 -27
  185. package/locales/zhTW.d.ts +2 -0
  186. package/locales/zhTW.js +123 -0
  187. package/models/api/gridColumnSpanning.d.ts +2 -0
  188. package/models/api/gridLocaleTextApi.d.ts +8 -2
  189. package/models/api/gridSelectionApi.d.ts +6 -0
  190. package/models/events/gridEvents.d.ts +1 -0
  191. package/models/events/gridEvents.js +1 -0
  192. package/models/gridFilterOperator.d.ts +6 -0
  193. package/models/gridRows.d.ts +15 -1
  194. package/models/params/gridCellParams.d.ts +4 -4
  195. package/models/props/DataGridProps.d.ts +5 -0
  196. package/modern/DataGrid/DataGrid.js +6 -0
  197. package/modern/DataGrid/useDataGridComponent.js +1 -1
  198. package/modern/DataGrid/useDataGridProps.js +1 -0
  199. package/modern/colDef/gridActionsColDef.js +2 -0
  200. package/modern/colDef/gridBooleanColDef.js +3 -1
  201. package/modern/colDef/gridCheckboxSelectionColDef.js +2 -0
  202. package/modern/colDef/gridDateOperators.js +4 -2
  203. package/modern/colDef/gridNumericOperators.js +4 -2
  204. package/modern/colDef/gridStringColDef.js +6 -0
  205. package/modern/colDef/gridStringOperators.js +4 -2
  206. package/modern/components/GridRow.js +5 -1
  207. package/modern/components/base/GridOverlays.js +4 -1
  208. package/modern/components/cell/GridBooleanCell.js +93 -2
  209. package/modern/components/cell/GridEditDateCell.js +5 -1
  210. package/modern/components/cell/index.js +1 -0
  211. package/modern/components/columnSelection/GridCellCheckboxRenderer.js +12 -1
  212. package/modern/components/containers/GridRoot.js +4 -2
  213. package/modern/components/containers/GridRootStyles.js +10 -0
  214. package/modern/components/toolbar/GridToolbarExport.js +20 -10
  215. package/modern/constants/gridClasses.js +1 -1
  216. package/modern/constants/localeTextConstants.js +9 -2
  217. package/modern/hooks/features/columns/useGridColumnSpanning.js +9 -7
  218. package/modern/hooks/features/columns/useGridColumns.js +10 -5
  219. package/modern/hooks/features/dimensions/useGridDimensions.js +6 -1
  220. package/modern/hooks/features/editRows/useGridCellEditing.new.js +5 -4
  221. package/modern/hooks/features/editRows/useGridEditing.new.js +4 -0
  222. package/modern/hooks/features/editRows/useGridEditing.old.js +1 -1
  223. package/modern/hooks/features/editRows/useGridRowEditing.new.js +3 -3
  224. package/modern/hooks/features/export/utils.js +10 -2
  225. package/modern/hooks/features/filter/gridFilterUtils.js +6 -0
  226. package/modern/hooks/features/filter/useGridFilter.js +25 -4
  227. package/modern/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +42 -30
  228. package/modern/hooks/features/pagination/useGridPage.js +4 -3
  229. package/modern/hooks/features/pagination/useGridPageSize.js +7 -4
  230. package/modern/hooks/features/preferencesPanel/useGridPreferencesPanel.js +8 -4
  231. package/modern/hooks/features/rows/gridRowsSelector.js +18 -1
  232. package/modern/hooks/features/rows/gridRowsUtils.js +19 -3
  233. package/modern/hooks/features/rows/index.js +1 -1
  234. package/modern/hooks/features/rows/useGridRowsMeta.js +17 -4
  235. package/modern/hooks/features/rows/useGridRowsPreProcessors.js +2 -1
  236. package/modern/hooks/features/scroll/useGridScroll.js +5 -2
  237. package/modern/hooks/features/selection/useGridSelection.js +28 -10
  238. package/modern/hooks/features/sorting/gridSortingUtils.js +10 -11
  239. package/modern/hooks/features/sorting/useGridSorting.js +38 -6
  240. package/modern/hooks/features/statePersistence/useGridStatePersistence.js +2 -2
  241. package/modern/hooks/features/virtualization/useGridVirtualScroller.js +41 -20
  242. package/modern/hooks/utils/useGridNativeEventListener.js +1 -1
  243. package/modern/index.js +1 -1
  244. package/modern/internals/index.js +5 -2
  245. package/modern/locales/arSD.js +8 -1
  246. package/modern/locales/bgBG.js +8 -1
  247. package/modern/locales/csCZ.js +8 -1
  248. package/modern/locales/daDK.js +8 -1
  249. package/modern/locales/deDE.js +12 -5
  250. package/modern/locales/elGR.js +8 -1
  251. package/modern/locales/esES.js +8 -1
  252. package/modern/locales/faIR.js +8 -1
  253. package/modern/locales/fiFI.js +8 -1
  254. package/modern/locales/frFR.js +18 -11
  255. package/modern/locales/heIL.js +9 -2
  256. package/modern/locales/huHU.js +8 -1
  257. package/modern/locales/index.js +2 -1
  258. package/modern/locales/itIT.js +8 -1
  259. package/modern/locales/jaJP.js +11 -4
  260. package/modern/locales/koKR.js +8 -1
  261. package/modern/locales/nbNO.js +9 -2
  262. package/modern/locales/nlNL.js +21 -14
  263. package/modern/locales/plPL.js +8 -1
  264. package/modern/locales/ptBR.js +17 -10
  265. package/modern/locales/roRO.js +12 -5
  266. package/modern/locales/ruRU.js +8 -1
  267. package/modern/locales/skSK.js +9 -2
  268. package/modern/locales/svSE.js +9 -2
  269. package/modern/locales/trTR.js +8 -1
  270. package/modern/locales/ukUA.js +8 -1
  271. package/modern/locales/viVN.js +8 -1
  272. package/modern/locales/zhCN.js +34 -27
  273. package/modern/locales/zhTW.js +123 -0
  274. package/modern/models/events/gridEvents.js +1 -0
  275. package/node/DataGrid/DataGrid.js +6 -0
  276. package/node/DataGrid/useDataGridComponent.js +1 -1
  277. package/node/DataGrid/useDataGridProps.js +1 -0
  278. package/node/colDef/gridActionsColDef.js +2 -0
  279. package/node/colDef/gridBooleanColDef.js +3 -1
  280. package/node/colDef/gridCheckboxSelectionColDef.js +2 -0
  281. package/node/colDef/gridDateOperators.js +4 -2
  282. package/node/colDef/gridNumericOperators.js +4 -2
  283. package/node/colDef/gridStringColDef.js +5 -0
  284. package/node/colDef/gridStringOperators.js +4 -2
  285. package/node/components/GridRow.js +5 -1
  286. package/node/components/base/GridOverlays.js +4 -1
  287. package/node/components/cell/GridBooleanCell.js +93 -2
  288. package/node/components/cell/GridEditDateCell.js +7 -1
  289. package/node/components/cell/index.js +13 -0
  290. package/node/components/columnSelection/GridCellCheckboxRenderer.js +12 -1
  291. package/node/components/containers/GridRoot.js +3 -1
  292. package/node/components/containers/GridRootStyles.js +10 -0
  293. package/node/components/toolbar/GridToolbarExport.js +16 -10
  294. package/node/constants/gridClasses.js +1 -1
  295. package/node/constants/localeTextConstants.js +9 -2
  296. package/node/hooks/features/columns/useGridColumnSpanning.js +9 -7
  297. package/node/hooks/features/columns/useGridColumns.js +13 -6
  298. package/node/hooks/features/dimensions/useGridDimensions.js +7 -1
  299. package/node/hooks/features/editRows/useGridCellEditing.new.js +7 -4
  300. package/node/hooks/features/editRows/useGridEditing.new.js +4 -0
  301. package/node/hooks/features/editRows/useGridEditing.old.js +1 -1
  302. package/node/hooks/features/editRows/useGridRowEditing.new.js +3 -3
  303. package/node/hooks/features/export/utils.js +17 -2
  304. package/node/hooks/features/filter/gridFilterUtils.js +7 -0
  305. package/node/hooks/features/filter/useGridFilter.js +30 -5
  306. package/node/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +43 -34
  307. package/node/hooks/features/pagination/useGridPage.js +4 -3
  308. package/node/hooks/features/pagination/useGridPageSize.js +8 -4
  309. package/node/hooks/features/preferencesPanel/useGridPreferencesPanel.js +12 -4
  310. package/node/hooks/features/rows/gridRowsSelector.js +24 -2
  311. package/node/hooks/features/rows/gridRowsUtils.js +23 -2
  312. package/node/hooks/features/rows/index.js +70 -12
  313. package/node/hooks/features/rows/useGridRowsMeta.js +20 -4
  314. package/node/hooks/features/rows/useGridRowsPreProcessors.js +2 -1
  315. package/node/hooks/features/scroll/useGridScroll.js +7 -1
  316. package/node/hooks/features/selection/useGridSelection.js +28 -10
  317. package/node/hooks/features/sorting/gridSortingUtils.js +10 -11
  318. package/node/hooks/features/sorting/useGridSorting.js +42 -6
  319. package/node/hooks/features/statePersistence/useGridStatePersistence.js +2 -2
  320. package/node/hooks/features/virtualization/useGridVirtualScroller.js +46 -21
  321. package/node/hooks/utils/useGridNativeEventListener.js +1 -1
  322. package/node/index.js +1 -1
  323. package/node/internals/index.js +46 -0
  324. package/node/locales/arSD.js +8 -1
  325. package/node/locales/bgBG.js +8 -1
  326. package/node/locales/csCZ.js +8 -1
  327. package/node/locales/daDK.js +8 -1
  328. package/node/locales/deDE.js +12 -5
  329. package/node/locales/elGR.js +8 -1
  330. package/node/locales/esES.js +8 -1
  331. package/node/locales/faIR.js +8 -1
  332. package/node/locales/fiFI.js +8 -1
  333. package/node/locales/frFR.js +18 -11
  334. package/node/locales/heIL.js +9 -2
  335. package/node/locales/huHU.js +8 -1
  336. package/node/locales/index.js +13 -0
  337. package/node/locales/itIT.js +8 -1
  338. package/node/locales/jaJP.js +11 -4
  339. package/node/locales/koKR.js +8 -1
  340. package/node/locales/nbNO.js +9 -2
  341. package/node/locales/nlNL.js +21 -14
  342. package/node/locales/plPL.js +8 -1
  343. package/node/locales/ptBR.js +17 -10
  344. package/node/locales/roRO.js +12 -5
  345. package/node/locales/ruRU.js +8 -1
  346. package/node/locales/skSK.js +9 -2
  347. package/node/locales/svSE.js +9 -2
  348. package/node/locales/trTR.js +8 -1
  349. package/node/locales/ukUA.js +8 -1
  350. package/node/locales/viVN.js +8 -1
  351. package/node/locales/zhCN.js +34 -27
  352. package/node/locales/zhTW.js +133 -0
  353. package/node/models/events/gridEvents.js +1 -0
  354. package/package.json +2 -2
  355. package/utils/getGridLocalization.d.ts +1 -1
package/CHANGELOG.md CHANGED
@@ -3,6 +3,156 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## 5.15.0
7
+
8
+ _Jul 29, 2022_
9
+
10
+ We'd like to offer a big thanks to the 6 contributors who made this release possible. Here are some highlights ✨:
11
+
12
+ - 🎁 Introduce aggregation (#5592) @flaviendelangle
13
+
14
+ Premium users can now aggregate data in the grid.
15
+ Extract information like sum, average, count, and others with a couple of clicks.
16
+
17
+ https://user-images.githubusercontent.com/45398769/181581503-77cc412e-9d9e-4de1-8bc3-c3bccc54cdaa.mp4
18
+
19
+ To enable this feature, add `experimentalFeatures={{ aggregation: true }}`.
20
+ Aggregation functions are customizable and they combine well with row grouping.
21
+ See the [documentation](https://mui.com/x/react-data-grid/aggregation/) to explore everything it has to offer.
22
+
23
+ - 🚀 Introduce row pinning (#4863) @cherniavskii
24
+
25
+ Pro users can now pin rows on top or bottom of the grid.
26
+
27
+ https://user-images.githubusercontent.com/45398769/181581493-56c733a3-6dd5-4546-bf8d-3f2dff72b14a.mp4
28
+
29
+ To do so, enable the feature with `experimentalFeatures={{ rowPinning: true }}` and provide the pinned rows data to the `pinnedRows` prop.
30
+ For more details, see the [documentation](https://mui.com/x/react-data-grid/row-pinning/).
31
+
32
+ - 🌍 Add simplified Chinese (zh-CN) locale to pickers (#5584) @gamecss
33
+ - 📚 Documentation improvements
34
+
35
+ ### `@mui/x-data-grid@v5.15.0` / `@mui/x-data-grid-pro@v5.15.0` / `@mui/x-data-grid-premium@v5.15.0`
36
+
37
+ #### Changes
38
+
39
+ - [DataGrid] Add prop to keep modifications while processing props (#5309) @m4theushw
40
+ - [DataGrid] Fix container width change on React 18 (#5566) @m4theushw
41
+ - [DataGrid] Fix ellipsis style convention (#5587) @oliviertassinari
42
+ - [DataGridPro] Implement row pinning (#4863) @cherniavskii
43
+ - [DataGridPremium] Make aggregation public (#5592) @cherniavskii
44
+ - [l10n] Improve simplified Chinese (zh-CN) locale (#5584) @gamecss
45
+
46
+ ### `@mui/x-date-pickers@v5.0.0-beta.3` / `@mui/x-date-picker-pro@5.0.0-beta.3`
47
+
48
+ #### Changes
49
+
50
+ - [l10n] Add simplified Chinese (zh-CN) locale (#5584) @gamecss
51
+
52
+ ### Docs
53
+
54
+ - [docs] Split docs page about rows (#5195) @flaviendelangle
55
+ - [docs] Add warning clarifications (#5399) @alexfauquette
56
+ - [docs] Correct slot CSS classes for Pro and Premium components (#5452) @alexfauquette
57
+ - [docs] Fix internal link to `valueParser` (#5450) @alexfauquette
58
+
59
+ ### Core
60
+
61
+ - [core] Upgrade monorepo (#5560) @m4theushw
62
+
63
+ ## 5.14.0
64
+
65
+ _Jul 21, 2022_
66
+
67
+ We'd like to offer a big thanks to the 10 contributors who made this release possible. Here are some highlights ✨:
68
+
69
+ - 🧪 Export `GridBooleanCell` component from data grid (#5537) @cliedeman
70
+ - ⚙️ Improve accessibility of the Export menu (#5486) @nogalpaulina
71
+ - 🌍 Improvements to different locales
72
+ - 📚 Documentation improvements
73
+ - 🐞 Bugfixes
74
+
75
+ ### `@mui/x-data-grid@5.14.0` / `@mui/x-data-grid-pro@5.14.0` / `@mui/x-data-grid-premium@5.14.0`
76
+
77
+ #### Changes
78
+
79
+ - [DataGrid] Add generics to `GridPreProcessEditCellProps` (#5510) @YunosukeY
80
+ - [DataGrid] Avoid inconsistent state export (#5390) @flaviendelangle
81
+ - [DataGrid] Export `GridBooleanCell` component (#5537) @cliedeman
82
+ - [DataGrid] Fix `date`/`dateTime` edit input font size to match view mode (#5304) @cherniavskii
83
+ - [DataGrid] Fix loading overlay position (#5558) @DanailH
84
+ - [DataGrid] Improve accessibility of the Export menu in the toolbar (#5486) @nogalpaulina
85
+ - [DataGridPremium] Implement Aggregation - not publicly released (#4208) @flaviendelangle
86
+ - [DataGridPremium] Fix crash when exporting all columns to Excel (#5425) @cherniavskii
87
+ - [l10n] Add Traditional Chinese (zh-TW) locale (#5498) @happyincent
88
+
89
+ ### `@mui/x-date-pickers@v5.0.0-beta.2` / `@mui/x-date-picker-pro@5.0.0-beta.2`
90
+
91
+ #### Changes
92
+
93
+ - [l10n] Add Norwegian (nb-NO) locale (#5475) @elkebab
94
+
95
+ ### Docs
96
+
97
+ - [docs] New page presenting the `apiRef` (#5273) @flaviendelangle
98
+ - [docs] Remove blank line @oliviertassinari
99
+
100
+ ### Core
101
+
102
+ - [core] Add missing comments on zh-TW translation (#5559) @flaviendelangle
103
+ - [core] Polish on the bug issue template (#5525) @oliviertassinari
104
+ - [test] Add more tests related to `isPrintableKey` (#5458) @mnajdova
105
+
106
+ ## 5.13.1
107
+
108
+ _Jul 15, 2022_
109
+
110
+ We'd like to offer a big thanks to the 13 contributors who made this release possible. Here are some highlights ✨:
111
+
112
+ - ✏️ Enter edit mode when pasting in a cell with Ctrl+V (Cmd+V on macOS) (#5405) @alexfauquette
113
+ - 🌍 Many improvements to the locales
114
+ - 📚 Documentation improvements
115
+ - 🐞 Bugfixes
116
+
117
+ ### `@mui/x-data-grid@v5.13.1` / `@mui/x-data-grid-pro@v5.13.1` / `@mui/x-data-grid-premium@v5.13.1`
118
+
119
+ #### Changes
120
+
121
+ - [DataGrid] Fix blank space when using dynamic row height with pagination (#5315) @m4theushw
122
+ - [DataGrid] Start editing with uppercase letter and Ctrl+V (#5405) @alexfauquette
123
+ - [DataGrid] Fix some filters being removed from filter model on filter panel open (#5403) @cherniavskii
124
+ - [DataGridPro] Improve pinned column headers accessibility (#5370) @cherniavskii
125
+ - [l10n] Improve Dutch (nl-NL) locale (#5464) @developenguin
126
+ - [l10n] Improve French (fr-FR) locale (#3211) (#5420) @Zenoo
127
+ - [l10n] Improve German (de-DE) locale (#5448) @sebastianfrey
128
+ - [l10n] Improve Brazilian Portuguese (pt-BR) locale (#5394) @andrepxa
129
+ - [l10n] Improve Romanian (ro-RO) locale (#5449) @rolule
130
+
131
+ ### `@mui/x-date-pickers@v5.0.0-beta.1` / `@mui/x-date-picker-pro@5.0.0-beta.1`
132
+
133
+ #### Changes
134
+
135
+ - [pickers] Add Italian (it-IT) locale (#5467) @felixh10r
136
+ - [pickers] Add Spanish (es-ES) locale (#5468) @felixh10r
137
+ - [pickers] Improve French (fr-FR) locale (#5446) @Zenoo
138
+ - [pickers] Improve German (de-DE) locale (#5447) @sebastianfrey
139
+
140
+ ### Docs
141
+
142
+ - [docs] Fix typo in the sorting page (#5431) @JosephMarinier
143
+ - [docs] Fix description for "Striped rows" example (#5432) @lindapaiste
144
+ - [docs] Make a clear difference between the license and license key (#5316) @oliviertassinari
145
+ - [docs] Update pickers README files (#5456) @cherniavskii
146
+ - [docs] Clarify the scope of support for MUI X (#5423) @joserodolfofreitas
147
+
148
+ ### Core
149
+
150
+ - [core] Add technical support link to \_redirects (#5428) @joserodolfofreitas
151
+ - [core] Improve GitHub bug reproduction template (#5067) @joserodolfofreitas
152
+ - [core] Include playground pages in tsconfig (#5367) @cherniavskii
153
+ - [core] Sort keys like in material-ui @oliviertassinari
154
+ - [test] Wait for flags to load on regression tests (#5473) @m4theushw
155
+
6
156
  ## 5.13.0
7
157
 
8
158
  _Jul 7, 2022_
@@ -213,7 +363,7 @@ _May 31, 2022_
213
363
 
214
364
  We'd like to offer a big thanks to the 15 contributors who made this release possible. Here are some highlights ✨:
215
365
 
216
- - 🎁 Introduce support for [dynamic row height](https://mui.com/x/react-data-grid/rows/#dynamic-row-height) (#4859) @m4theushw
366
+ - 🎁 Introduce support for [dynamic row height](https://mui.com/x/react-data-grid/row-height/#dynamic-row-height) (#4859) @m4theushw
217
367
 
218
368
  <img src="https://user-images.githubusercontent.com/42154031/171183167-718d7bcd-ec0f-459e-97fe-0f650abb4a99.gif" width="800">
219
369
 
@@ -530,7 +680,7 @@ _Apr 25, 2022_
530
680
 
531
681
  We'd like to offer a big thanks to the 6 contributors who made this release possible. Here are some highlights ✨:
532
682
 
533
- - 🎁 Introduce [Row reorder](https://mui.com/x/react-data-grid/rows/#row-reorder) (#4034) @DanailH
683
+ - 🎁 Introduce [Row reorder](https://mui.com/x/react-data-grid/row-ordering/) (#4034) @DanailH
534
684
 
535
685
  <img src="https://user-images.githubusercontent.com/5858539/165091263-23472fbb-a989-44b8-849a-d2185adfe13b.gif" width="800">
536
686
 
@@ -794,7 +944,7 @@ We'd like to offer a big thanks to the 8 contributors who made this release poss
794
944
  <DataGrid getRowSpacing={() => ({ top: 10, bottom: 10 })} />
795
945
  ```
796
946
 
797
- Check the [documentation](https://mui.com/x/react-data-grid/rows/#row-spacing) for more information.
947
+ Check the [documentation](https://mui.com/x/react-data-grid/row-height/#row-spacing) for more information.
798
948
 
799
949
  ### `@mui/x-data-grid@v5.6.1` / `@mui/x-data-grid-pro@v5.6.1`
800
950
 
@@ -1048,7 +1198,7 @@ _Jan 28, 2022_
1048
1198
 
1049
1199
  A big thanks to the 9 contributors who made this release possible. Here are some highlights ✨:
1050
1200
 
1051
- - 🚣 Introduce [variable row height](https://mui.com/x/react-data-grid/rows/#variable-row-height) (#438) @DanailH
1201
+ - 🚣 Introduce [variable row height](https://mui.com/x/react-data-grid/row-height/#variable-row-height) (#438) @DanailH
1052
1202
 
1053
1203
  Allows for setting a row-specific height.
1054
1204
  By default, all rows have the same height, but now you can set the height on a per-row basis.
@@ -1416,7 +1566,7 @@ A big thanks to the 5 contributors who made this release possible. Here are some
1416
1566
  - [core] Fix `yarn prettier` script (#3292) @oliviertassinari
1417
1567
  - [core] Improve tests for Tree Data (#3366) @flaviendelangle
1418
1568
  - [core] Never import directly from the `__modules__` folder in the `x-data-grid-generator` package (#3379) @flaviendelangle
1419
- - [core] Transition to a new StackOverflow tag (#3308) @oliviertassinari
1569
+ - [core] Transition to a new Stack Overflow tag (#3308) @oliviertassinari
1420
1570
  - [core] Update monorepo (#3370) @flaviendelangle
1421
1571
  - [core] Use pre-processors for sorting and filtering (#3318) @flaviendelangle
1422
1572
  - [test] Replace `useFakeTimers` (#3323) @m4theushw
@@ -3700,7 +3850,7 @@ Big thanks to the 7 contributors who made this release possible. Here are some h
3700
3850
  - 🎁 Add `onRowsScrollEnd` to support infinite loading (#1199) @DanailH
3701
3851
  This is an XGrid feature. Provides the ability to tap into the `onRowsScrollEnd` which is called when the scroll reaches the bottom of the grid viewport allowing developers to load additional data. It can be used with a combination of `scrollBottomThreshold` to control the area in which the `onRowsScrollEnd` is called.
3702
3852
 
3703
- See the documentation for [more details](https://mui.com/x/react-data-grid/rows/#infinite-loading).
3853
+ See the documentation for [more details](https://mui.com/x/react-data-grid/row-updates/#infinite-loading).
3704
3854
 
3705
3855
  - 🕹 Provide the ability to sort by multiple columns using Shift+click (#1203) @dtassone
3706
3856
  - 🇵🇱 Added pl-PL locale (#1117) @LarsKumbier
@@ -155,6 +155,12 @@ DataGridRaw.propTypes = {
155
155
  */
156
156
  disableExtendRowFullWidth: PropTypes.bool,
157
157
 
158
+ /**
159
+ * If `true`, modification to a cell will not be discarded if the mode is changed from "edit" to "view" while processing props.
160
+ * @default false
161
+ */
162
+ disableIgnoreModificationsIfProcessingProps: PropTypes.bool,
163
+
158
164
  /**
159
165
  * If `true`, the selection on click on a row or cell is disabled.
160
166
  * @default false
@@ -60,7 +60,7 @@ export const useDataGridComponent = props => {
60
60
  const useGridEditing = (_props$experimentalFe2 = props.experimentalFeatures) != null && _props$experimentalFe2.newEditingApi ? useGridEditing_new : useGridEditing_old;
61
61
  useGridEditing(apiRef, props);
62
62
  useGridFocus(apiRef, props);
63
- useGridPreferencesPanel(apiRef);
63
+ useGridPreferencesPanel(apiRef, props);
64
64
  useGridFilter(apiRef, props);
65
65
  useGridSorting(apiRef, props);
66
66
  useGridDensity(apiRef, props);
@@ -41,6 +41,7 @@ export const DATA_GRID_PROPS_DEFAULT_VALUES = {
41
41
  disableMultipleColumnsSorting: false,
42
42
  disableSelectionOnClick: false,
43
43
  disableVirtualization: false,
44
+ disableIgnoreModificationsIfProcessingProps: false,
44
45
  editMode: GridEditModes.Cell,
45
46
  filterMode: GridFeatureModeConstant.client,
46
47
  headerHeight: 56,
@@ -5,6 +5,8 @@ export const GRID_ACTIONS_COLUMN_TYPE = 'actions';
5
5
  export const GRID_ACTIONS_COL_DEF = _extends({}, GRID_STRING_COL_DEF, {
6
6
  sortable: false,
7
7
  filterable: false,
8
+ // @ts-ignore
9
+ aggregable: false,
8
10
  width: 100,
9
11
  align: 'center',
10
12
  headerAlign: 'center',
@@ -21,5 +21,7 @@ export const GRID_BOOLEAN_COL_DEF = _extends({}, GRID_STRING_COL_DEF, {
21
21
  sortComparator: gridNumberComparator,
22
22
  valueFormatter: gridBooleanFormatter,
23
23
  filterOperators: getGridBooleanOperators(),
24
- getApplyQuickFilterFn: undefined
24
+ getApplyQuickFilterFn: undefined,
25
+ // @ts-ignore
26
+ aggregable: false
25
27
  });
@@ -13,6 +13,8 @@ export const GRID_CHECKBOX_SELECTION_COL_DEF = _extends({}, GRID_BOOLEAN_COL_DEF
13
13
  resizable: false,
14
14
  sortable: false,
15
15
  filterable: false,
16
+ // @ts-ignore
17
+ aggregable: false,
16
18
  disableColumnMenu: true,
17
19
  disableReorder: true,
18
20
  disableExport: true,
@@ -1,2 +1,2 @@
1
1
  import { GridFilterOperator } from '../models/gridFilterOperator';
2
- export declare const getGridDateOperators: (showTime?: boolean | undefined) => GridFilterOperator<any, string | Date, any>[];
2
+ export declare const getGridDateOperators: (showTime?: boolean) => GridFilterOperator<any, string | Date, any>[];
@@ -91,7 +91,8 @@ export const getGridDateOperators = showTime => [{
91
91
  }) => {
92
92
  return value == null;
93
93
  };
94
- }
94
+ },
95
+ requiresFilterValue: false
95
96
  }, {
96
97
  value: 'isNotEmpty',
97
98
  getApplyFilterFn: () => {
@@ -100,5 +101,6 @@ export const getGridDateOperators = showTime => [{
100
101
  }) => {
101
102
  return value != null;
102
103
  };
103
- }
104
+ },
105
+ requiresFilterValue: false
104
106
  }];
@@ -153,7 +153,8 @@ export const getGridNumericOperators = () => [{
153
153
  }) => {
154
154
  return value == null;
155
155
  };
156
- }
156
+ },
157
+ requiresFilterValue: false
157
158
  }, {
158
159
  value: 'isNotEmpty',
159
160
  getApplyFilterFn: () => {
@@ -162,7 +163,8 @@ export const getGridNumericOperators = () => [{
162
163
  }) => {
163
164
  return value != null;
164
165
  };
165
- }
166
+ },
167
+ requiresFilterValue: false
166
168
  }, {
167
169
  value: 'isAnyOf',
168
170
  getApplyFilterFn: filterItem => {
@@ -1,2 +1,5 @@
1
1
  import { GridColTypeDef } from '../models/colDef/gridColDef';
2
+ /**
3
+ * TODO: Move pro and premium properties outside of this Community file
4
+ */
2
5
  export declare const GRID_STRING_COL_DEF: GridColTypeDef<any, any>;
@@ -1,6 +1,10 @@
1
1
  import { renderEditInputCell } from '../components/cell/GridEditInputCell';
2
2
  import { gridStringOrNumberComparator } from '../hooks/features/sorting/gridSortingUtils';
3
3
  import { getGridStringOperators, getGridStringQuickFilterFn } from './gridStringOperators';
4
+ /**
5
+ * TODO: Move pro and premium properties outside of this Community file
6
+ */
7
+
4
8
  export const GRID_STRING_COL_DEF = {
5
9
  width: 100,
6
10
  minWidth: 50,
@@ -12,6 +16,8 @@ export const GRID_STRING_COL_DEF = {
12
16
  filterable: true,
13
17
  groupable: true,
14
18
  pinnable: true,
19
+ // @ts-ignore
20
+ aggregable: true,
15
21
  editable: false,
16
22
  sortComparator: gridStringOrNumberComparator,
17
23
  type: 'string',
@@ -88,7 +88,8 @@ export const getGridStringOperators = (disableTrim = false) => [{
88
88
  }) => {
89
89
  return value === '' || value == null;
90
90
  };
91
- }
91
+ },
92
+ requiresFilterValue: false
92
93
  }, {
93
94
  value: 'isNotEmpty',
94
95
  getApplyFilterFn: () => {
@@ -97,7 +98,8 @@ export const getGridStringOperators = (disableTrim = false) => [{
97
98
  }) => {
98
99
  return value !== '' && value != null;
99
100
  };
100
- }
101
+ },
102
+ requiresFilterValue: false
101
103
  }, {
102
104
  value: 'isAnyOf',
103
105
  getApplyFilterFn: filterItem => {
@@ -120,7 +120,11 @@ function GridRow(props) {
120
120
  // doesn't care about pagination and considers the rows from the current page only, so the
121
121
  // first row always has index=0. We need to subtract the index of the first row to make it
122
122
  // compatible with the index used by the virtualization.
123
- apiRef.current.unstable_setLastMeasuredRowIndex(index - currentPage.range.firstRowIndex);
123
+ const rowIndex = apiRef.current.getRowIndexRelativeToVisibleRows(rowId); // pinned rows are not part of the visible rows
124
+
125
+ if (rowIndex != null) {
126
+ apiRef.current.unstable_setLastMeasuredRowIndex(rowIndex);
127
+ }
124
128
  }
125
129
 
126
130
  const rootElement = ref.current;
@@ -44,7 +44,10 @@ function GridOverlayWrapper(props) {
44
44
  width: (_viewportInnerSize$wi = viewportInnerSize == null ? void 0 : viewportInnerSize.width) != null ? _viewportInnerSize$wi : 0,
45
45
  position: 'absolute',
46
46
  top: headerHeight,
47
- bottom: height === 'auto' ? 0 : undefined
47
+ bottom: height === 'auto' ? 0 : undefined,
48
+ zIndex: 4,
49
+ // should be above pinned columns, pinned rows and detail panel
50
+ pointerEvents: 'none'
48
51
  }
49
52
  }, props));
50
53
  }
@@ -4,6 +4,9 @@ import { GridRenderCellParams } from '../../models/params/gridCellParams';
4
4
  import { GridColDef } from '../../models/colDef/gridColDef';
5
5
  interface GridBooleanCellProps extends GridRenderCellParams, Omit<SvgIconProps, 'tabIndex' | 'id'> {
6
6
  }
7
- export declare const GridBooleanCell: React.MemoExoticComponent<(props: GridBooleanCellProps) => JSX.Element>;
7
+ declare const GridBooleanCell: React.MemoExoticComponent<{
8
+ (props: GridBooleanCellProps): JSX.Element;
9
+ propTypes: any;
10
+ }>;
11
+ export { GridBooleanCell };
8
12
  export declare const renderBooleanCell: GridColDef['renderCell'];
9
- export {};
@@ -2,6 +2,7 @@ import _extends from "@babel/runtime/helpers/esm/extends";
2
2
  import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
3
3
  const _excluded = ["id", "value", "formattedValue", "api", "field", "row", "rowNode", "colDef", "cellMode", "isEditable", "hasFocus", "tabIndex", "getValue"];
4
4
  import * as React from 'react';
5
+ import PropTypes from 'prop-types';
5
6
  import { unstable_composeClasses as composeClasses } from '@mui/material';
6
7
  import { getDataGridUtilityClass } from '../../constants/gridClasses';
7
8
  import { useGridRootProps } from '../../hooks/utils/useGridRootProps';
@@ -18,7 +19,7 @@ const useUtilityClasses = ownerState => {
18
19
  return composeClasses(slots, getDataGridUtilityClass, classes);
19
20
  };
20
21
 
21
- export const GridBooleanCell = /*#__PURE__*/React.memo(props => {
22
+ const GridBooleanCellRaw = props => {
22
23
  const {
23
24
  value
24
25
  } = props,
@@ -37,7 +38,97 @@ export const GridBooleanCell = /*#__PURE__*/React.memo(props => {
37
38
  titleAccess: apiRef.current.getLocaleText(value ? 'booleanCellTrueLabel' : 'booleanCellFalseLabel'),
38
39
  "data-value": Boolean(value)
39
40
  }, other));
40
- });
41
+ };
42
+
43
+ process.env.NODE_ENV !== "production" ? GridBooleanCellRaw.propTypes = {
44
+ // ----------------------------- Warning --------------------------------
45
+ // | These PropTypes are generated from the TypeScript type definitions |
46
+ // | To update them edit the TypeScript types and run "yarn proptypes" |
47
+ // ----------------------------------------------------------------------
48
+
49
+ /**
50
+ * GridApi that let you manipulate the grid.
51
+ * @deprecated Use the `apiRef` returned by `useGridApiContext` or `useGridApiRef` (only available in `@mui/x-data-grid-pro`)
52
+ */
53
+ api: PropTypes.any.isRequired,
54
+
55
+ /**
56
+ * The mode of the cell.
57
+ */
58
+ cellMode: PropTypes.oneOf(['edit', 'view']).isRequired,
59
+
60
+ /**
61
+ * The column of the row that the current cell belongs to.
62
+ */
63
+ colDef: PropTypes.object.isRequired,
64
+
65
+ /**
66
+ * The column field of the cell that triggered the event.
67
+ */
68
+ field: PropTypes.string.isRequired,
69
+
70
+ /**
71
+ * A ref allowing to set imperative focus.
72
+ * It can be passed to the element that should receive focus.
73
+ * @ignore - do not document.
74
+ */
75
+ focusElementRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({
76
+ current: PropTypes.shape({
77
+ focus: PropTypes.func.isRequired
78
+ })
79
+ })]),
80
+
81
+ /**
82
+ * The cell value formatted with the column valueFormatter.
83
+ */
84
+ formattedValue: PropTypes.any,
85
+
86
+ /**
87
+ * Get the cell value of a row and field.
88
+ * @param {GridRowId} id The row id.
89
+ * @param {string} field The field.
90
+ * @returns {any} The cell value.
91
+ * @deprecated Use `params.row` to directly access the fields you want instead.
92
+ */
93
+ getValue: PropTypes.func.isRequired,
94
+
95
+ /**
96
+ * If true, the cell is the active element.
97
+ */
98
+ hasFocus: PropTypes.bool.isRequired,
99
+
100
+ /**
101
+ * The grid row id.
102
+ */
103
+ id: PropTypes.oneOfType([PropTypes.number, PropTypes.string]).isRequired,
104
+
105
+ /**
106
+ * If true, the cell is editable.
107
+ */
108
+ isEditable: PropTypes.bool,
109
+
110
+ /**
111
+ * The row model of the row that the current cell belongs to.
112
+ */
113
+ row: PropTypes.object.isRequired,
114
+
115
+ /**
116
+ * The node of the row that the current cell belongs to.
117
+ */
118
+ rowNode: PropTypes.object.isRequired,
119
+
120
+ /**
121
+ * the tabIndex value.
122
+ */
123
+ tabIndex: PropTypes.oneOf([-1, 0]).isRequired,
124
+
125
+ /**
126
+ * The cell value, but if the column has valueGetter, use getValue.
127
+ */
128
+ value: PropTypes.any
129
+ } : void 0;
130
+ const GridBooleanCell = /*#__PURE__*/React.memo(GridBooleanCellRaw);
131
+ export { GridBooleanCell };
41
132
  export const renderBooleanCell = params => {
42
133
  if (params.rowNode.isAutoGenerated) {
43
134
  return '';
@@ -6,10 +6,14 @@ import PropTypes from 'prop-types';
6
6
  import { unstable_composeClasses as composeClasses } from '@mui/material';
7
7
  import { unstable_useEnhancedEffect as useEnhancedEffect } from '@mui/material/utils';
8
8
  import InputBase from '@mui/material/InputBase';
9
+ import { styled } from '@mui/material/styles';
9
10
  import { getDataGridUtilityClass } from '../../constants/gridClasses';
10
11
  import { useGridRootProps } from '../../hooks/utils/useGridRootProps';
11
12
  import { useGridApiContext } from '../../hooks/utils/useGridApiContext';
12
13
  import { jsx as _jsx } from "react/jsx-runtime";
14
+ const StyledInputBase = styled(InputBase)({
15
+ fontSize: 'inherit'
16
+ });
13
17
 
14
18
  const useUtilityClasses = ownerState => {
15
19
  const {
@@ -116,7 +120,7 @@ function GridEditDateCell(props) {
116
120
  inputRef.current.focus();
117
121
  }
118
122
  }, [hasFocus]);
119
- return /*#__PURE__*/_jsx(InputBase, _extends({
123
+ return /*#__PURE__*/_jsx(StyledInputBase, _extends({
120
124
  inputRef: inputRef,
121
125
  fullWidth: true,
122
126
  className: classes.root,
@@ -1,4 +1,5 @@
1
1
  export * from './GridCell';
2
+ export * from './GridBooleanCell';
2
3
  export * from './GridEditBooleanCell';
3
4
  export * from './GridEditDateCell';
4
5
  export * from './GridEditInputCell';
@@ -1,4 +1,5 @@
1
1
  export * from './GridCell';
2
+ export * from './GridBooleanCell';
2
3
  export * from './GridEditBooleanCell';
3
4
  export * from './GridEditDateCell';
4
5
  export * from './GridEditInputCell';
@@ -28,6 +28,7 @@ const GridCellCheckboxForwardRef = /*#__PURE__*/React.forwardRef(function GridCe
28
28
  field,
29
29
  id,
30
30
  value: isChecked,
31
+ rowNode,
31
32
  hasFocus,
32
33
  tabIndex
33
34
  } = props,
@@ -77,8 +78,18 @@ const GridCellCheckboxForwardRef = /*#__PURE__*/React.forwardRef(function GridCe
77
78
  apiRef.current.publishEvent('cellNavigationKeyDown', props, event);
78
79
  }
79
80
  }, [apiRef, props]);
80
- const isSelectable = !rootProps.isRowSelectable || rootProps.isRowSelectable(apiRef.current.getRowParams(id));
81
+
82
+ if (rowNode.position === 'footer') {
83
+ return null;
84
+ }
85
+
86
+ const isSelectable = apiRef.current.isRowSelectable(id);
81
87
  const label = apiRef.current.getLocaleText(isChecked ? 'checkboxSelectionUnselectRow' : 'checkboxSelectionSelectRow');
88
+
89
+ if (rowNode.isPinned) {
90
+ return null;
91
+ }
92
+
82
93
  return /*#__PURE__*/_jsx(rootProps.components.BaseCheckbox, _extends({
83
94
  ref: handleRef,
84
95
  tabIndex: tabIndex,
@@ -12,7 +12,7 @@ import { useGridSelector } from '../../hooks/utils/useGridSelector';
12
12
  import { useGridApiContext } from '../../hooks/utils/useGridApiContext';
13
13
  import { useGridRootProps } from '../../hooks/utils/useGridRootProps';
14
14
  import { getDataGridUtilityClass } from '../../constants/gridClasses';
15
- import { gridRowCountSelector } from '../../hooks/features/rows/gridRowsSelector';
15
+ import { gridPinnedRowsCountSelector, gridRowCountSelector } from '../../hooks/features/rows/gridRowsSelector';
16
16
  import { gridDensityValueSelector } from '../../hooks/features/density/densitySelector';
17
17
  import { jsx as _jsx } from "react/jsx-runtime";
18
18
 
@@ -43,6 +43,7 @@ const GridRoot = /*#__PURE__*/React.forwardRef(function GridRoot(props, ref) {
43
43
  const densityValue = useGridSelector(apiRef, gridDensityValueSelector);
44
44
  const rootContainerRef = React.useRef(null);
45
45
  const handleRef = useForkRef(rootContainerRef, ref);
46
+ const pinnedRowsCount = useGridSelector(apiRef, gridPinnedRowsCountSelector);
46
47
  const ownerState = {
47
48
  density: densityValue,
48
49
  classes: rootProps.classes,
@@ -70,7 +71,8 @@ const GridRoot = /*#__PURE__*/React.forwardRef(function GridRoot(props, ref) {
70
71
  className: clsx(className, classes.root),
71
72
  role: "grid",
72
73
  "aria-colcount": visibleColumns.length,
73
- "aria-rowcount": totalRowCount,
74
+ "aria-rowcount": totalRowCount + pinnedRowsCount + 1 // +1 for the header row
75
+ ,
74
76
  "aria-multiselectable": !rootProps.disableMultipleSelection,
75
77
  "aria-label": rootProps['aria-label'],
76
78
  "aria-labelledby": rootProps['aria-labelledby']
@@ -6,6 +6,16 @@ export const GridRootStyles = styled('div', {
6
6
  slot: 'Root',
7
7
  overridesResolver: (props, styles) => [{
8
8
  [`&.${gridClasses.autoHeight}`]: styles.autoHeight
9
+ }, {
10
+ [`&.${gridClasses.aggregationColumnHeader}`]: styles.aggregationColumnHeader
11
+ }, {
12
+ [`&.${gridClasses['aggregationColumnHeader--alignLeft']}`]: styles['aggregationColumnHeader--alignLeft']
13
+ }, {
14
+ [`&.${gridClasses['aggregationColumnHeader--alignCenter']}`]: styles['aggregationColumnHeader--alignCenter']
15
+ }, {
16
+ [`&.${gridClasses['aggregationColumnHeader--alignRight']}`]: styles['aggregationColumnHeader--alignRight']
17
+ }, {
18
+ [`&.${gridClasses.aggregationColumnHeaderLabel}`]: styles.aggregationColumnHeaderLabel
9
19
  }, {
10
20
  [`& .${gridClasses.editBooleanCell}`]: styles.editBooleanCell
11
21
  }, {