@mui/x-data-grid-premium 5.11.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 (199) hide show
  1. package/CHANGELOG.md +4052 -0
  2. package/DataGridPremium/DataGridPremium.d.ts +9 -0
  3. package/DataGridPremium/DataGridPremium.js +986 -0
  4. package/DataGridPremium/index.d.ts +2 -0
  5. package/DataGridPremium/index.js +2 -0
  6. package/DataGridPremium/package.json +6 -0
  7. package/DataGridPremium/useDataGridPremiumComponent.d.ts +4 -0
  8. package/DataGridPremium/useDataGridPremiumComponent.js +78 -0
  9. package/DataGridPremium/useDataGridPremiumProps.d.ts +6 -0
  10. package/DataGridPremium/useDataGridPremiumProps.js +37 -0
  11. package/LICENSE +12 -0
  12. package/README.md +31 -0
  13. package/components/GridExcelExportMenuItem.d.ts +9 -0
  14. package/components/GridExcelExportMenuItem.js +32 -0
  15. package/components/GridGroupingColumnLeafCell.d.ts +4 -0
  16. package/components/GridGroupingColumnLeafCell.js +22 -0
  17. package/components/GridGroupingCriteriaCell.d.ts +7 -0
  18. package/components/GridGroupingCriteriaCell.js +78 -0
  19. package/components/GridRowGroupableColumnMenuItems.d.ts +11 -0
  20. package/components/GridRowGroupableColumnMenuItems.js +63 -0
  21. package/components/GridRowGroupingColumnMenuItems.d.ts +11 -0
  22. package/components/GridRowGroupingColumnMenuItems.js +58 -0
  23. package/components/index.d.ts +1 -0
  24. package/components/index.js +1 -0
  25. package/components/package.json +6 -0
  26. package/hooks/features/export/gridExcelExportInterface.d.ts +58 -0
  27. package/hooks/features/export/gridExcelExportInterface.js +1 -0
  28. package/hooks/features/export/index.d.ts +1 -0
  29. package/hooks/features/export/index.js +1 -0
  30. package/hooks/features/export/serializer/excelSerializer.d.ts +14 -0
  31. package/hooks/features/export/serializer/excelSerializer.js +218 -0
  32. package/hooks/features/export/useGridExcelExport.d.ts +10 -0
  33. package/hooks/features/export/useGridExcelExport.js +77 -0
  34. package/hooks/features/index.d.ts +2 -0
  35. package/hooks/features/index.js +3 -0
  36. package/hooks/features/rowGrouping/createGroupingColDef.d.ts +42 -0
  37. package/hooks/features/rowGrouping/createGroupingColDef.js +318 -0
  38. package/hooks/features/rowGrouping/gridRowGroupingInterfaces.d.ts +37 -0
  39. package/hooks/features/rowGrouping/gridRowGroupingInterfaces.js +1 -0
  40. package/hooks/features/rowGrouping/gridRowGroupingSelector.d.ts +4 -0
  41. package/hooks/features/rowGrouping/gridRowGroupingSelector.js +5 -0
  42. package/hooks/features/rowGrouping/gridRowGroupingUtils.d.ts +27 -0
  43. package/hooks/features/rowGrouping/gridRowGroupingUtils.js +139 -0
  44. package/hooks/features/rowGrouping/index.d.ts +3 -0
  45. package/hooks/features/rowGrouping/index.js +3 -0
  46. package/hooks/features/rowGrouping/useGridRowGrouping.d.ts +11 -0
  47. package/hooks/features/rowGrouping/useGridRowGrouping.js +200 -0
  48. package/hooks/features/rowGrouping/useGridRowGroupingPreProcessors.d.ts +4 -0
  49. package/hooks/features/rowGrouping/useGridRowGroupingPreProcessors.js +201 -0
  50. package/hooks/index.d.ts +2 -0
  51. package/hooks/index.js +3 -0
  52. package/hooks/package.json +6 -0
  53. package/hooks/utils/index.d.ts +1 -0
  54. package/hooks/utils/index.js +1 -0
  55. package/hooks/utils/useGridApiContext.d.ts +4 -0
  56. package/hooks/utils/useGridApiContext.js +2 -0
  57. package/hooks/utils/useGridApiRef.d.ts +4 -0
  58. package/hooks/utils/useGridApiRef.js +2 -0
  59. package/hooks/utils/useGridRootProps.d.ts +2 -0
  60. package/hooks/utils/useGridRootProps.js +2 -0
  61. package/hooks/utils/useKeepGroupedColumnsHidden.d.ts +12 -0
  62. package/hooks/utils/useKeepGroupedColumnsHidden.js +50 -0
  63. package/index.d.ts +22 -0
  64. package/index.js +25 -0
  65. package/legacy/DataGridPremium/DataGridPremium.js +986 -0
  66. package/legacy/DataGridPremium/index.js +2 -0
  67. package/legacy/DataGridPremium/useDataGridPremiumComponent.js +78 -0
  68. package/legacy/DataGridPremium/useDataGridPremiumProps.js +46 -0
  69. package/legacy/components/GridExcelExportMenuItem.js +30 -0
  70. package/legacy/components/GridGroupingColumnLeafCell.js +20 -0
  71. package/legacy/components/GridGroupingCriteriaCell.js +74 -0
  72. package/legacy/components/GridRowGroupableColumnMenuItems.js +61 -0
  73. package/legacy/components/GridRowGroupingColumnMenuItems.js +56 -0
  74. package/legacy/components/index.js +1 -0
  75. package/legacy/hooks/features/export/gridExcelExportInterface.js +1 -0
  76. package/legacy/hooks/features/export/index.js +1 -0
  77. package/legacy/hooks/features/export/serializer/excelSerializer.js +260 -0
  78. package/legacy/hooks/features/export/useGridExcelExport.js +111 -0
  79. package/legacy/hooks/features/index.js +3 -0
  80. package/legacy/hooks/features/rowGrouping/createGroupingColDef.js +319 -0
  81. package/legacy/hooks/features/rowGrouping/gridRowGroupingInterfaces.js +1 -0
  82. package/legacy/hooks/features/rowGrouping/gridRowGroupingSelector.js +13 -0
  83. package/legacy/hooks/features/rowGrouping/gridRowGroupingUtils.js +147 -0
  84. package/legacy/hooks/features/rowGrouping/index.js +3 -0
  85. package/legacy/hooks/features/rowGrouping/useGridRowGrouping.js +206 -0
  86. package/legacy/hooks/features/rowGrouping/useGridRowGroupingPreProcessors.js +215 -0
  87. package/legacy/hooks/index.js +3 -0
  88. package/legacy/hooks/utils/index.js +1 -0
  89. package/legacy/hooks/utils/useGridApiContext.js +2 -0
  90. package/legacy/hooks/utils/useGridApiRef.js +2 -0
  91. package/legacy/hooks/utils/useGridRootProps.js +2 -0
  92. package/legacy/hooks/utils/useKeepGroupedColumnsHidden.js +50 -0
  93. package/legacy/index.js +25 -0
  94. package/legacy/models/dataGridPremiumProps.js +1 -0
  95. package/legacy/models/gridApiPremium.js +1 -0
  96. package/legacy/models/gridGroupingValueGetterParams.js +1 -0
  97. package/legacy/models/gridStatePremium.js +1 -0
  98. package/legacy/models/index.js +1 -0
  99. package/legacy/typeOverloads/index.js +1 -0
  100. package/legacy/typeOverloads/modules.js +33 -0
  101. package/legacy/typeOverloads/reexports.js +6 -0
  102. package/legacy/utils/releaseInfo.js +15 -0
  103. package/models/dataGridPremiumProps.d.ts +64 -0
  104. package/models/dataGridPremiumProps.js +1 -0
  105. package/models/gridApiPremium.d.ts +13 -0
  106. package/models/gridApiPremium.js +1 -0
  107. package/models/gridGroupingValueGetterParams.d.ts +31 -0
  108. package/models/gridGroupingValueGetterParams.js +1 -0
  109. package/models/gridStatePremium.d.ts +14 -0
  110. package/models/gridStatePremium.js +1 -0
  111. package/models/index.d.ts +1 -0
  112. package/models/index.js +1 -0
  113. package/models/package.json +6 -0
  114. package/modern/DataGridPremium/DataGridPremium.js +986 -0
  115. package/modern/DataGridPremium/index.js +2 -0
  116. package/modern/DataGridPremium/useDataGridPremiumComponent.js +76 -0
  117. package/modern/DataGridPremium/useDataGridPremiumProps.js +37 -0
  118. package/modern/components/GridExcelExportMenuItem.js +32 -0
  119. package/modern/components/GridGroupingColumnLeafCell.js +20 -0
  120. package/modern/components/GridGroupingCriteriaCell.js +76 -0
  121. package/modern/components/GridRowGroupableColumnMenuItems.js +61 -0
  122. package/modern/components/GridRowGroupingColumnMenuItems.js +56 -0
  123. package/modern/components/index.js +1 -0
  124. package/modern/hooks/features/export/gridExcelExportInterface.js +1 -0
  125. package/modern/hooks/features/export/index.js +1 -0
  126. package/modern/hooks/features/export/serializer/excelSerializer.js +216 -0
  127. package/modern/hooks/features/export/useGridExcelExport.js +73 -0
  128. package/modern/hooks/features/index.js +3 -0
  129. package/modern/hooks/features/rowGrouping/createGroupingColDef.js +302 -0
  130. package/modern/hooks/features/rowGrouping/gridRowGroupingInterfaces.js +1 -0
  131. package/modern/hooks/features/rowGrouping/gridRowGroupingSelector.js +5 -0
  132. package/modern/hooks/features/rowGrouping/gridRowGroupingUtils.js +137 -0
  133. package/modern/hooks/features/rowGrouping/index.js +3 -0
  134. package/modern/hooks/features/rowGrouping/useGridRowGrouping.js +192 -0
  135. package/modern/hooks/features/rowGrouping/useGridRowGroupingPreProcessors.js +201 -0
  136. package/modern/hooks/index.js +3 -0
  137. package/modern/hooks/utils/index.js +1 -0
  138. package/modern/hooks/utils/useGridApiContext.js +2 -0
  139. package/modern/hooks/utils/useGridApiRef.js +2 -0
  140. package/modern/hooks/utils/useGridRootProps.js +2 -0
  141. package/modern/hooks/utils/useKeepGroupedColumnsHidden.js +46 -0
  142. package/modern/index.js +25 -0
  143. package/modern/models/dataGridPremiumProps.js +1 -0
  144. package/modern/models/gridApiPremium.js +1 -0
  145. package/modern/models/gridGroupingValueGetterParams.js +1 -0
  146. package/modern/models/gridStatePremium.js +1 -0
  147. package/modern/models/index.js +1 -0
  148. package/modern/typeOverloads/index.js +1 -0
  149. package/modern/typeOverloads/modules.js +33 -0
  150. package/modern/typeOverloads/reexports.js +6 -0
  151. package/modern/utils/releaseInfo.js +15 -0
  152. package/node/DataGridPremium/DataGridPremium.js +1009 -0
  153. package/node/DataGridPremium/index.js +30 -0
  154. package/node/DataGridPremium/useDataGridPremiumComponent.js +91 -0
  155. package/node/DataGridPremium/useDataGridPremiumProps.js +57 -0
  156. package/node/components/GridExcelExportMenuItem.js +49 -0
  157. package/node/components/GridGroupingColumnLeafCell.js +38 -0
  158. package/node/components/GridGroupingCriteriaCell.js +99 -0
  159. package/node/components/GridRowGroupableColumnMenuItems.js +82 -0
  160. package/node/components/GridRowGroupingColumnMenuItems.js +78 -0
  161. package/node/components/index.js +18 -0
  162. package/node/hooks/features/export/gridExcelExportInterface.js +5 -0
  163. package/node/hooks/features/export/index.js +18 -0
  164. package/node/hooks/features/export/serializer/excelSerializer.js +233 -0
  165. package/node/hooks/features/export/useGridExcelExport.js +95 -0
  166. package/node/hooks/features/index.js +31 -0
  167. package/node/hooks/features/rowGrouping/createGroupingColDef.js +341 -0
  168. package/node/hooks/features/rowGrouping/gridRowGroupingInterfaces.js +5 -0
  169. package/node/hooks/features/rowGrouping/gridRowGroupingSelector.js +18 -0
  170. package/node/hooks/features/rowGrouping/gridRowGroupingUtils.js +172 -0
  171. package/node/hooks/features/rowGrouping/index.js +51 -0
  172. package/node/hooks/features/rowGrouping/useGridRowGrouping.js +228 -0
  173. package/node/hooks/features/rowGrouping/useGridRowGroupingPreProcessors.js +223 -0
  174. package/node/hooks/index.js +31 -0
  175. package/node/hooks/utils/index.js +18 -0
  176. package/node/hooks/utils/useGridApiContext.js +11 -0
  177. package/node/hooks/utils/useGridApiRef.js +11 -0
  178. package/node/hooks/utils/useGridRootProps.js +11 -0
  179. package/node/hooks/utils/useKeepGroupedColumnsHidden.js +66 -0
  180. package/node/index.js +272 -0
  181. package/node/models/dataGridPremiumProps.js +5 -0
  182. package/node/models/gridApiPremium.js +5 -0
  183. package/node/models/gridGroupingValueGetterParams.js +5 -0
  184. package/node/models/gridStatePremium.js +5 -0
  185. package/node/models/index.js +18 -0
  186. package/node/typeOverloads/index.js +3 -0
  187. package/node/typeOverloads/modules.js +34 -0
  188. package/node/typeOverloads/reexports.js +29 -0
  189. package/node/utils/releaseInfo.js +25 -0
  190. package/package.json +63 -0
  191. package/typeOverloads/index.d.ts +1 -0
  192. package/typeOverloads/index.js +1 -0
  193. package/typeOverloads/modules.d.ts +0 -0
  194. package/typeOverloads/modules.js +33 -0
  195. package/typeOverloads/package.json +6 -0
  196. package/typeOverloads/reexports.d.ts +22 -0
  197. package/typeOverloads/reexports.js +6 -0
  198. package/utils/releaseInfo.d.ts +1 -0
  199. package/utils/releaseInfo.js +15 -0
@@ -0,0 +1,986 @@
1
+ import * as React from 'react';
2
+ import PropTypes from 'prop-types';
3
+ import { useLicenseVerifier, Watermark } from '@mui/x-license-pro';
4
+ import { chainPropTypes } from '@mui/utils';
5
+ import { GridBody, GridErrorHandler, GridFooterPlaceholder, GridHeaderPlaceholder, GridRoot, GridContextProvider } from '@mui/x-data-grid-pro';
6
+ import { DataGridProVirtualScroller, DataGridProColumnHeaders } from '@mui/x-data-grid-pro/internals';
7
+ import { useDataGridPremiumComponent } from './useDataGridPremiumComponent';
8
+ import { useDataGridPremiumProps } from './useDataGridPremiumProps';
9
+ import { getReleaseInfo } from '../utils/releaseInfo';
10
+ import { jsx as _jsx } from "react/jsx-runtime";
11
+ import { jsxs as _jsxs } from "react/jsx-runtime";
12
+ const releaseInfo = getReleaseInfo();
13
+ const DataGridPremiumRaw = /*#__PURE__*/React.forwardRef(function DataGridPremium(inProps, ref) {
14
+ const props = useDataGridPremiumProps(inProps);
15
+ const apiRef = useDataGridPremiumComponent(props.apiRef, props);
16
+ useLicenseVerifier('x-data-grid-premium', releaseInfo);
17
+ return /*#__PURE__*/_jsx(GridContextProvider, {
18
+ apiRef: apiRef,
19
+ props: props,
20
+ children: /*#__PURE__*/_jsx(GridRoot, {
21
+ className: props.className,
22
+ style: props.style,
23
+ sx: props.sx,
24
+ ref: ref,
25
+ children: /*#__PURE__*/_jsxs(GridErrorHandler, {
26
+ children: [/*#__PURE__*/_jsx(GridHeaderPlaceholder, {}), /*#__PURE__*/_jsx(GridBody, {
27
+ ColumnHeadersComponent: DataGridProColumnHeaders,
28
+ VirtualScrollerComponent: DataGridProVirtualScroller,
29
+ children: /*#__PURE__*/_jsx(Watermark, {
30
+ packageName: "x-data-grid-premium",
31
+ releaseInfo: releaseInfo
32
+ })
33
+ }), /*#__PURE__*/_jsx(GridFooterPlaceholder, {})]
34
+ })
35
+ })
36
+ });
37
+ });
38
+ export const DataGridPremium = /*#__PURE__*/React.memo(DataGridPremiumRaw);
39
+ process.env.NODE_ENV !== "production" ? DataGridPremiumRaw.propTypes = {
40
+ // ----------------------------- Warning --------------------------------
41
+ // | These PropTypes are generated from the TypeScript type definitions |
42
+ // | To update them edit the TypeScript types and run "yarn proptypes" |
43
+ // ----------------------------------------------------------------------
44
+
45
+ /**
46
+ * The ref object that allows grid manipulation. Can be instantiated with [[useGridApiRef()]].
47
+ */
48
+ apiRef: PropTypes.shape({
49
+ current: PropTypes.object.isRequired
50
+ }),
51
+
52
+ /**
53
+ * The label of the grid.
54
+ */
55
+ 'aria-label': PropTypes.string,
56
+
57
+ /**
58
+ * The id of the element containing a label for the grid.
59
+ */
60
+ 'aria-labelledby': PropTypes.string,
61
+
62
+ /**
63
+ * If `true`, the grid height is dynamic and follow the number of rows in the grid.
64
+ * @default false
65
+ */
66
+ autoHeight: PropTypes.bool,
67
+
68
+ /**
69
+ * If `true`, the pageSize is calculated according to the container size and the max number of rows to avoid rendering a vertical scroll bar.
70
+ * @default false
71
+ */
72
+ autoPageSize: PropTypes.bool,
73
+
74
+ /**
75
+ * Controls the modes of the cells.
76
+ */
77
+ cellModesModel: PropTypes.object,
78
+
79
+ /**
80
+ * If `true`, the grid get a first column with a checkbox that allows to select rows.
81
+ * @default false
82
+ */
83
+ checkboxSelection: PropTypes.bool,
84
+
85
+ /**
86
+ * If `true`, the "Select All" header checkbox selects only the rows on the current page. To be used in combination with `checkboxSelection`.
87
+ * It only works if the pagination is enabled.
88
+ * @default false
89
+ */
90
+ checkboxSelectionVisibleOnly: chainPropTypes(PropTypes.bool, props => {
91
+ if (!props.pagination && props.checkboxSelectionVisibleOnly) {
92
+ return new Error('MUI: The `checkboxSelectionVisibleOnly` prop has no effect when the pagination is not enabled.');
93
+ }
94
+
95
+ return null;
96
+ }),
97
+
98
+ /**
99
+ * Override or extend the styles applied to the component.
100
+ */
101
+ classes: PropTypes.object,
102
+
103
+ /**
104
+ * Number of extra columns to be rendered before/after the visible slice.
105
+ * @default 3
106
+ */
107
+ columnBuffer: PropTypes.number,
108
+
109
+ /**
110
+ * Set of columns of type [[GridColumns]].
111
+ */
112
+ columns: PropTypes.arrayOf(PropTypes.object).isRequired,
113
+
114
+ /**
115
+ * Number of rows from the `columnBuffer` that can be visible before a new slice is rendered.
116
+ * @default 3
117
+ */
118
+ columnThreshold: PropTypes.number,
119
+
120
+ /**
121
+ * Extend native column types with your new column types.
122
+ */
123
+ columnTypes: PropTypes.object,
124
+
125
+ /**
126
+ * Set the column visibility model of the grid.
127
+ * If defined, the grid will ignore the `hide` property in [[GridColDef]].
128
+ */
129
+ columnVisibilityModel: PropTypes.object,
130
+
131
+ /**
132
+ * Overrideable components.
133
+ */
134
+ components: PropTypes.object,
135
+
136
+ /**
137
+ * Overrideable components props dynamically passed to the component at rendering.
138
+ */
139
+ componentsProps: PropTypes.object,
140
+
141
+ /**
142
+ * If above 0, the row children will be expanded up to this depth.
143
+ * If equal to -1, all the row children will be expanded.
144
+ * @default 0
145
+ */
146
+ defaultGroupingExpansionDepth: PropTypes.number,
147
+
148
+ /**
149
+ * Set the density of the grid.
150
+ * @default "standard"
151
+ */
152
+ density: PropTypes.oneOf(['comfortable', 'compact', 'standard']),
153
+
154
+ /**
155
+ * The row ids to show the detail panel.
156
+ */
157
+ detailPanelExpandedRowIds: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string]).isRequired),
158
+
159
+ /**
160
+ * If `true`, the filtering will only be applied to the top level rows when grouping rows with the `treeData` prop.
161
+ * @default false
162
+ */
163
+ disableChildrenFiltering: PropTypes.bool,
164
+
165
+ /**
166
+ * If `true`, the sorting will only be applied to the top level rows when grouping rows with the `treeData` prop.
167
+ * @default false
168
+ */
169
+ disableChildrenSorting: PropTypes.bool,
170
+
171
+ /**
172
+ * If `true`, column filters are disabled.
173
+ * @default false
174
+ */
175
+ disableColumnFilter: PropTypes.bool,
176
+
177
+ /**
178
+ * If `true`, the column menu is disabled.
179
+ * @default false
180
+ */
181
+ disableColumnMenu: PropTypes.bool,
182
+
183
+ /**
184
+ * If `true`, the column pinning is disabled.
185
+ * @default false
186
+ */
187
+ disableColumnPinning: PropTypes.bool,
188
+
189
+ /**
190
+ * If `true`, reordering columns is disabled.
191
+ * @default false
192
+ */
193
+ disableColumnReorder: PropTypes.bool,
194
+
195
+ /**
196
+ * If `true`, resizing columns is disabled.
197
+ * @default false
198
+ */
199
+ disableColumnResize: PropTypes.bool,
200
+
201
+ /**
202
+ * If `true`, hiding/showing columns is disabled.
203
+ * @default false
204
+ */
205
+ disableColumnSelector: PropTypes.bool,
206
+
207
+ /**
208
+ * If `true`, the density selector is disabled.
209
+ * @default false
210
+ */
211
+ disableDensitySelector: PropTypes.bool,
212
+
213
+ /**
214
+ * If `true`, rows will not be extended to fill the full width of the grid container.
215
+ * @default false
216
+ */
217
+ disableExtendRowFullWidth: PropTypes.bool,
218
+
219
+ /**
220
+ * If `true`, filtering with multiple columns is disabled.
221
+ * @default false
222
+ */
223
+ disableMultipleColumnsFiltering: PropTypes.bool,
224
+
225
+ /**
226
+ * If `true`, sorting with multiple columns is disabled.
227
+ * @default false
228
+ */
229
+ disableMultipleColumnsSorting: PropTypes.bool,
230
+
231
+ /**
232
+ * If `true`, multiple selection using the Ctrl or CMD key is disabled.
233
+ * @default false
234
+ */
235
+ disableMultipleSelection: PropTypes.bool,
236
+
237
+ /**
238
+ * If `true`, the row grouping is disabled.
239
+ * @default false
240
+ */
241
+ disableRowGrouping: PropTypes.bool,
242
+
243
+ /**
244
+ * If `true`, the selection on click on a row or cell is disabled.
245
+ * @default false
246
+ */
247
+ disableSelectionOnClick: PropTypes.bool,
248
+
249
+ /**
250
+ * If `true`, the virtualization is disabled.
251
+ * @default false
252
+ */
253
+ disableVirtualization: PropTypes.bool,
254
+
255
+ /**
256
+ * Controls whether to use the cell or row editing.
257
+ * @default "cell"
258
+ */
259
+ editMode: PropTypes.oneOf(['cell', 'row']),
260
+
261
+ /**
262
+ * Set the edit rows model of the grid.
263
+ */
264
+ editRowsModel: PropTypes.object,
265
+
266
+ /**
267
+ * An error that will turn the grid into its error state and display the error component.
268
+ */
269
+ error: PropTypes.any,
270
+
271
+ /**
272
+ * Features under development.
273
+ * For each feature, if the flag is not explicitly set to `true`, the feature will be fully disabled and any property / method call will not have any effect.
274
+ */
275
+ experimentalFeatures: PropTypes.shape({
276
+ newEditingApi: PropTypes.bool,
277
+ preventCommitWhileValidating: PropTypes.bool,
278
+ rowGrouping: PropTypes.bool,
279
+ warnIfFocusStateIsNotSynced: PropTypes.bool
280
+ }),
281
+
282
+ /**
283
+ * Filtering can be processed on the server or client-side.
284
+ * Set it to 'server' if you would like to handle filtering on the server-side.
285
+ * @default "client"
286
+ */
287
+ filterMode: chainPropTypes(PropTypes.oneOf(['client', 'server']), props => {
288
+ if (props.treeData && props.filterMode === 'server') {
289
+ return new Error('MUI: The `filterMode="server"` prop is not available when the `treeData` is enabled.');
290
+ }
291
+
292
+ return null;
293
+ }),
294
+
295
+ /**
296
+ * Set the filter model of the grid.
297
+ */
298
+ filterModel: PropTypes.shape({
299
+ items: PropTypes.arrayOf(PropTypes.shape({
300
+ columnField: PropTypes.string.isRequired,
301
+ id: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),
302
+ operatorValue: PropTypes.string,
303
+ value: PropTypes.any
304
+ })).isRequired,
305
+ linkOperator: PropTypes.oneOf(['and', 'or']),
306
+ quickFilterLogicOperator: PropTypes.oneOf(['and', 'or']),
307
+ quickFilterValues: PropTypes.array
308
+ }),
309
+
310
+ /**
311
+ * Function that applies CSS classes dynamically on cells.
312
+ * @param {GridCellParams} params With all properties from [[GridCellParams]].
313
+ * @returns {string} The CSS class to apply to the cell.
314
+ */
315
+ getCellClassName: PropTypes.func,
316
+
317
+ /**
318
+ * Function that returns the element to render in row detail.
319
+ * @param {GridRowParams} params With all properties from [[GridRowParams]].
320
+ * @returns {JSX.Element} The row detail element.
321
+ */
322
+ getDetailPanelContent: PropTypes.func,
323
+
324
+ /**
325
+ * Function that returns the height of the row detail panel.
326
+ * @param {GridRowParams} params With all properties from [[GridRowParams]].
327
+ * @returns {number} The height in pixels.
328
+ * @default "() => 500"
329
+ */
330
+ getDetailPanelHeight: PropTypes.func,
331
+
332
+ /**
333
+ * Function that applies CSS classes dynamically on rows.
334
+ * @param {GridRowClassNameParams} params With all properties from [[GridRowClassNameParams]].
335
+ * @returns {string} The CSS class to apply to the row.
336
+ */
337
+ getRowClassName: PropTypes.func,
338
+
339
+ /**
340
+ * Function that sets the row height per row.
341
+ * @param {GridRowHeightParams} params With all properties from [[GridRowHeightParams]].
342
+ * @returns {GridRowHeightReturnValue} The row height value. If `null` or `undefined` then the default row height is applied.
343
+ */
344
+ getRowHeight: PropTypes.func,
345
+
346
+ /**
347
+ * Return the id of a given [[GridRowModel]].
348
+ */
349
+ getRowId: PropTypes.func,
350
+
351
+ /**
352
+ * Function that allows to specify the spacing between rows.
353
+ * @param {GridRowSpacingParams} params With all properties from [[GridRowSpacingParams]].
354
+ * @returns {GridRowSpacing} The row spacing values.
355
+ */
356
+ getRowSpacing: PropTypes.func,
357
+
358
+ /**
359
+ * Determines the path of a row in the tree data.
360
+ * For instance, a row with the path ["A", "B"] is the child of the row with the path ["A"].
361
+ * Note that all paths must contain at least one element.
362
+ * @template R
363
+ * @param {R} row The row from which we want the path.
364
+ * @returns {string[]} The path to the row.
365
+ */
366
+ getTreeDataPath: PropTypes.func,
367
+
368
+ /**
369
+ * The grouping column used by the tree data.
370
+ */
371
+ groupingColDef: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),
372
+
373
+ /**
374
+ * Set the height in pixel of the column headers in the grid.
375
+ * @default 56
376
+ */
377
+ headerHeight: PropTypes.number,
378
+
379
+ /**
380
+ * If `true`, the footer component is hidden.
381
+ * @default false
382
+ */
383
+ hideFooter: PropTypes.bool,
384
+
385
+ /**
386
+ * If `true`, the pagination component in the footer is hidden.
387
+ * @default false
388
+ */
389
+ hideFooterPagination: PropTypes.bool,
390
+
391
+ /**
392
+ * If `true`, the row count in the footer is hidden.
393
+ * It has no effect if the pagination is enabled.
394
+ * @default false
395
+ */
396
+ hideFooterRowCount: chainPropTypes(PropTypes.bool, props => {
397
+ if (props.pagination && props.hideFooterRowCount) {
398
+ return new Error('MUI: The `hideFooterRowCount` prop has no effect when the pagination is enabled.');
399
+ }
400
+
401
+ return null;
402
+ }),
403
+
404
+ /**
405
+ * If `true`, the selected row count in the footer is hidden.
406
+ * @default false
407
+ */
408
+ hideFooterSelectedRowCount: PropTypes.bool,
409
+
410
+ /**
411
+ * The initial state of the DataGridPremium.
412
+ * The data in it will be set in the state on initialization but will not be controlled.
413
+ * If one of the data in `initialState` is also being controlled, then the control state wins.
414
+ */
415
+ initialState: PropTypes.object,
416
+
417
+ /**
418
+ * Callback fired when a cell is rendered, returns true if the cell is editable.
419
+ * @param {GridCellParams} params With all properties from [[GridCellParams]].
420
+ * @returns {boolean} A boolean indicating if the cell is editable.
421
+ */
422
+ isCellEditable: PropTypes.func,
423
+
424
+ /**
425
+ * Determines if a group should be expanded after its creation.
426
+ * This prop takes priority over the `defaultGroupingExpansionDepth` prop.
427
+ * @param {GridRowTreeNodeConfig} node The node of the group to test.
428
+ * @returns {boolean} A boolean indicating if the group is expanded.
429
+ */
430
+ isGroupExpandedByDefault: PropTypes.func,
431
+
432
+ /**
433
+ * Determines if a row can be selected.
434
+ * @param {GridRowParams} params With all properties from [[GridRowParams]].
435
+ * @returns {boolean} A boolean indicating if the cell is selectable.
436
+ */
437
+ isRowSelectable: PropTypes.func,
438
+
439
+ /**
440
+ * If `true`, the selection model will retain selected rows that do not exist.
441
+ * Useful when using server side pagination and row selections need to be retained
442
+ * when changing pages.
443
+ * @default false
444
+ */
445
+ keepNonExistentRowsSelected: PropTypes.bool,
446
+
447
+ /**
448
+ * If `true`, a loading overlay is displayed.
449
+ */
450
+ loading: PropTypes.bool,
451
+
452
+ /**
453
+ * Set the locale text of the grid.
454
+ * You can find all the translation keys supported in [the source](https://github.com/mui/mui-x/blob/HEAD/packages/grid/x-data-grid/src/constants/localeTextConstants.ts) in the GitHub repository.
455
+ */
456
+ localeText: PropTypes.object,
457
+
458
+ /**
459
+ * Pass a custom logger in the components that implements the [[Logger]] interface.
460
+ * @default console
461
+ */
462
+ logger: PropTypes.shape({
463
+ debug: PropTypes.func.isRequired,
464
+ error: PropTypes.func.isRequired,
465
+ info: PropTypes.func.isRequired,
466
+ warn: PropTypes.func.isRequired
467
+ }),
468
+
469
+ /**
470
+ * Allows to pass the logging level or false to turn off logging.
471
+ * @default "debug"
472
+ */
473
+ logLevel: PropTypes.oneOf(['debug', 'error', 'info', 'warn', false]),
474
+
475
+ /**
476
+ * Nonce of the inline styles for [Content Security Policy](https://www.w3.org/TR/2016/REC-CSP2-20161215/#script-src-the-nonce-attribute).
477
+ */
478
+ nonce: PropTypes.string,
479
+
480
+ /**
481
+ * Callback fired when any cell is clicked.
482
+ * @param {GridCellParams} params With all properties from [[GridCellParams]].
483
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
484
+ * @param {GridCallbackDetails} details Additional details for this callback.
485
+ */
486
+ onCellClick: PropTypes.func,
487
+
488
+ /**
489
+ * Callback fired when a double click event comes from a cell element.
490
+ * @param {GridCellParams} params With all properties from [[GridCellParams]].
491
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
492
+ * @param {GridCallbackDetails} details Additional details for this callback.
493
+ */
494
+ onCellDoubleClick: PropTypes.func,
495
+
496
+ /**
497
+ * Callback fired when the cell changes are committed.
498
+ * @param {GridCellEditCommitParams} params With all properties from [[GridCellEditCommitParams]].
499
+ * @param {MuiEvent<MuiBaseEvent>} event The event that caused this prop to be called.
500
+ * @param {GridCallbackDetails} details Additional details for this callback.
501
+ */
502
+ onCellEditCommit: PropTypes.func,
503
+
504
+ /**
505
+ * Callback fired when the cell turns to edit mode.
506
+ * @param {GridCellParams} params With all properties from [[GridCellParams]].
507
+ * @param {MuiEvent<React.KeyboardEvent | React.MouseEvent>} event The event that caused this prop to be called.
508
+ */
509
+ onCellEditStart: PropTypes.func,
510
+
511
+ /**
512
+ * Callback fired when the cell turns to view mode.
513
+ * @param {GridCellParams} params With all properties from [[GridCellParams]].
514
+ * @param {MuiEvent<MuiBaseEvent>} event The event that caused this prop to be called.
515
+ */
516
+ onCellEditStop: PropTypes.func,
517
+
518
+ /**
519
+ * Callback fired when a cell loses focus.
520
+ * @param {GridCellParams} params With all properties from [[GridCellParams]].
521
+ * @param {MuiEvent<MuiBaseEvent>} event The event object.
522
+ * @param {GridCallbackDetails} details Additional details for this callback.
523
+ */
524
+ onCellFocusOut: PropTypes.func,
525
+
526
+ /**
527
+ * Callback fired when a keydown event comes from a cell element.
528
+ * @param {GridCellParams} params With all properties from [[GridCellParams]].
529
+ * @param {MuiEvent<React.KeyboardEvent>} event The event object.
530
+ * @param {GridCallbackDetails} details Additional details for this callback.
531
+ */
532
+ onCellKeyDown: PropTypes.func,
533
+
534
+ /**
535
+ * Callback fired when the `cellModesModel` prop changes.
536
+ * @param {GridCellModesModel} cellModesModel Object containig which cells are in "edit" mode.
537
+ * @param {GridCallbackDetails} details Additional details for this callback.
538
+ */
539
+ onCellModesModelChange: PropTypes.func,
540
+
541
+ /**
542
+ * Callback fired when a click event comes from a column header element.
543
+ * @param {GridColumnHeaderParams} params With all properties from [[GridColumnHeaderParams]].
544
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
545
+ * @param {GridCallbackDetails} details Additional details for this callback.
546
+ */
547
+ onColumnHeaderClick: PropTypes.func,
548
+
549
+ /**
550
+ * Callback fired when a double click event comes from a column header element.
551
+ * @param {GridColumnHeaderParams} params With all properties from [[GridColumnHeaderParams]].
552
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
553
+ * @param {GridCallbackDetails} details Additional details for this callback.
554
+ */
555
+ onColumnHeaderDoubleClick: PropTypes.func,
556
+
557
+ /**
558
+ * Callback fired when a mouse enter event comes from a column header element.
559
+ * @param {GridColumnHeaderParams} params With all properties from [[GridColumnHeaderParams]].
560
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
561
+ * @param {GridCallbackDetails} details Additional details for this callback.
562
+ */
563
+ onColumnHeaderEnter: PropTypes.func,
564
+
565
+ /**
566
+ * Callback fired when a mouse leave event comes from a column header element.
567
+ * @param {GridColumnHeaderParams} params With all properties from [[GridColumnHeaderParams]].
568
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
569
+ * @param {GridCallbackDetails} details Additional details for this callback.
570
+ */
571
+ onColumnHeaderLeave: PropTypes.func,
572
+
573
+ /**
574
+ * Callback fired when a mouseout event comes from a column header element.
575
+ * @param {GridColumnHeaderParams} params With all properties from [[GridColumnHeaderParams]].
576
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
577
+ * @param {GridCallbackDetails} details Additional details for this callback.
578
+ */
579
+ onColumnHeaderOut: PropTypes.func,
580
+
581
+ /**
582
+ * Callback fired when a mouseover event comes from a column header element.
583
+ * @param {GridColumnHeaderParams} params With all properties from [[GridColumnHeaderParams]].
584
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
585
+ * @param {GridCallbackDetails} details Additional details for this callback.
586
+ */
587
+ onColumnHeaderOver: PropTypes.func,
588
+
589
+ /**
590
+ * Callback fired when a column is reordered.
591
+ * @param {GridColumnOrderChangeParams} params With all properties from [[GridColumnOrderChangeParams]].
592
+ * @param {MuiEvent<{}>} event The event object.
593
+ * @param {GridCallbackDetails} details Additional details for this callback.
594
+ */
595
+ onColumnOrderChange: PropTypes.func,
596
+
597
+ /**
598
+ * Callback fired while a column is being resized.
599
+ * @param {GridColumnResizeParams} params With all properties from [[GridColumnResizeParams]].
600
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
601
+ * @param {GridCallbackDetails} details Additional details for this callback.
602
+ */
603
+ onColumnResize: PropTypes.func,
604
+
605
+ /**
606
+ * Callback fired when a column visibility changes.
607
+ * Only works when no `columnVisibilityModel` is provided and if we change the visibility of a single column at a time.
608
+ * @param {GridColumnVisibilityChangeParams} params With all properties from [[GridColumnVisibilityChangeParams]].
609
+ * @param {MuiEvent<{}>} event The event object.
610
+ * @param {GridCallbackDetails} details Additional details for this callback.
611
+ * @deprecated Use `onColumnVisibilityModelChange` instead.
612
+ */
613
+ onColumnVisibilityChange: PropTypes.func,
614
+
615
+ /**
616
+ * Callback fired when the column visibility model changes.
617
+ * @param {GridColumnVisibilityModel} model The new model.
618
+ * @param {GridCallbackDetails} details Additional details for this callback.
619
+ */
620
+ onColumnVisibilityModelChange: PropTypes.func,
621
+
622
+ /**
623
+ * Callback fired when the width of a column is changed.
624
+ * @param {GridColumnResizeParams} params With all properties from [[GridColumnResizeParams]].
625
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
626
+ * @param {GridCallbackDetails} details Additional details for this callback.
627
+ */
628
+ onColumnWidthChange: PropTypes.func,
629
+
630
+ /**
631
+ * Callback fired when the detail panel of a row is opened or closed.
632
+ * @param {GridRowId[]} ids The ids of the rows which have the detail panel open.
633
+ * @param {GridCallbackDetails} details Additional details for this callback.
634
+ */
635
+ onDetailPanelExpandedRowIdsChange: PropTypes.func,
636
+
637
+ /**
638
+ * Callback fired when the edit cell value changes.
639
+ * @param {GridEditCellPropsParams} params With all properties from [[GridEditCellPropsParams]].
640
+ * @param {MuiEvent<React.SyntheticEvent>} event The event that caused this prop to be called.
641
+ * @param {GridCallbackDetails} details Additional details for this callback.
642
+ * @deprecated use `preProcessEditCellProps` from the [`GridColDef`](/x/api/data-grid/grid-col-def/)
643
+ */
644
+ onEditCellPropsChange: PropTypes.func,
645
+
646
+ /**
647
+ * Callback fired when the `editRowsModel` changes.
648
+ * @param {GridEditRowsModel} editRowsModel With all properties from [[GridEditRowsModel]].
649
+ * @param {GridCallbackDetails} details Additional details for this callback.
650
+ */
651
+ onEditRowsModelChange: PropTypes.func,
652
+
653
+ /**
654
+ * Callback fired when an exception is thrown in the grid.
655
+ * @param {any} args The arguments passed to the `showError` call.
656
+ * @param {MuiEvent<{}>} event The event object.
657
+ * @param {GridCallbackDetails} details Additional details for this callback.
658
+ */
659
+ onError: PropTypes.func,
660
+
661
+ /**
662
+ * Callback fired when the Filter model changes before the filters are applied.
663
+ * @param {GridFilterModel} model With all properties from [[GridFilterModel]].
664
+ * @param {GridCallbackDetails} details Additional details for this callback.
665
+ */
666
+ onFilterModelChange: PropTypes.func,
667
+
668
+ /**
669
+ * Callback fired when the current page has changed.
670
+ * @param {number} page Index of the page displayed on the Grid.
671
+ * @param {GridCallbackDetails} details Additional details for this callback.
672
+ */
673
+ onPageChange: PropTypes.func,
674
+
675
+ /**
676
+ * Callback fired when the page size has changed.
677
+ * @param {number} pageSize Size of the page displayed on the Grid.
678
+ * @param {GridCallbackDetails} details Additional details for this callback.
679
+ */
680
+ onPageSizeChange: PropTypes.func,
681
+
682
+ /**
683
+ * Callback fired when the pinned columns have changed.
684
+ * @param {GridPinnedColumns} pinnedColumns The changed pinned columns.
685
+ * @param {GridCallbackDetails} details Additional details for this callback.
686
+ */
687
+ onPinnedColumnsChange: PropTypes.func,
688
+
689
+ /**
690
+ * Callback fired when the preferences panel is closed.
691
+ * @param {GridPreferencePanelParams} params With all properties from [[GridPreferencePanelParams]].
692
+ * @param {MuiEvent<{}>} event The event object.
693
+ * @param {GridCallbackDetails} details Additional details for this callback.
694
+ */
695
+ onPreferencePanelClose: PropTypes.func,
696
+
697
+ /**
698
+ * Callback fired when the preferences panel is opened.
699
+ * @param {GridPreferencePanelParams} params With all properties from [[GridPreferencePanelParams]].
700
+ * @param {MuiEvent<{}>} event The event object.
701
+ * @param {GridCallbackDetails} details Additional details for this callback.
702
+ */
703
+ onPreferencePanelOpen: PropTypes.func,
704
+
705
+ /**
706
+ * Callback called when `processRowUpdate` throws an error or rejects.
707
+ * @param {any} error The error thrown.
708
+ */
709
+ onProcessRowUpdateError: PropTypes.func,
710
+
711
+ /**
712
+ * Callback fired when the grid is resized.
713
+ * @param {ElementSize} containerSize With all properties from [[ElementSize]].
714
+ * @param {MuiEvent<{}>} event The event object.
715
+ * @param {GridCallbackDetails} details Additional details for this callback.
716
+ */
717
+ onResize: PropTypes.func,
718
+
719
+ /**
720
+ * Callback fired when a row is clicked.
721
+ * Not called if the target clicked is an interactive element added by the built-in columns.
722
+ * @param {GridRowParams} params With all properties from [[GridRowParams]].
723
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
724
+ * @param {GridCallbackDetails} details Additional details for this callback.
725
+ */
726
+ onRowClick: PropTypes.func,
727
+
728
+ /**
729
+ * Callback fired when a double click event comes from a row container element.
730
+ * @param {GridRowParams} params With all properties from [[RowParams]].
731
+ * @param {MuiEvent<React.MouseEvent>} event The event object.
732
+ * @param {GridCallbackDetails} details Additional details for this callback.
733
+ */
734
+ onRowDoubleClick: PropTypes.func,
735
+
736
+ /**
737
+ * Callback fired when the row changes are committed.
738
+ * @param {GridRowId} id The row id.
739
+ * @param {MuiEvent<MuiBaseEvent>} event The event that caused this prop to be called.
740
+ */
741
+ onRowEditCommit: PropTypes.func,
742
+
743
+ /**
744
+ * Callback fired when the row turns to edit mode.
745
+ * @param {GridRowParams} params With all properties from [[GridRowParams]].
746
+ * @param {MuiEvent<React.KeyboardEvent | React.MouseEvent>} event The event that caused this prop to be called.
747
+ */
748
+ onRowEditStart: PropTypes.func,
749
+
750
+ /**
751
+ * Callback fired when the row turns to view mode.
752
+ * @param {GridRowParams} params With all properties from [[GridRowParams]].
753
+ * @param {MuiEvent<MuiBaseEvent>} event The event that caused this prop to be called.
754
+ */
755
+ onRowEditStop: PropTypes.func,
756
+
757
+ /**
758
+ * Callback fired when the row grouping model changes.
759
+ * @param {GridRowGroupingModel} model Columns used as grouping criteria.
760
+ * @param {GridCallbackDetails} details Additional details for this callback.
761
+ */
762
+ onRowGroupingModelChange: PropTypes.func,
763
+
764
+ /**
765
+ * Callback fired when the `rowModesModel` prop changes.
766
+ * @param {GridRowModesModel} rowModesModel Object containig which rows are in "edit" mode.
767
+ * @param {GridCallbackDetails} details Additional details for this callback.
768
+ */
769
+ onRowModesModelChange: PropTypes.func,
770
+
771
+ /**
772
+ * Callback fired when a row is being reordered.
773
+ * @param {GridRowOrderChangeParams} params With all properties from [[GridRowOrderChangeParams]].
774
+ * @param {MuiEvent<{}>} event The event object.
775
+ * @param {GridCallbackDetails} details Additional details for this callback.
776
+ */
777
+ onRowOrderChange: PropTypes.func,
778
+
779
+ /**
780
+ * Callback fired when scrolling to the bottom of the grid viewport.
781
+ * @param {GridRowScrollEndParams} params With all properties from [[GridRowScrollEndParams]].
782
+ * @param {MuiEvent<{}>} event The event object.
783
+ * @param {GridCallbackDetails} details Additional details for this callback.
784
+ */
785
+ onRowsScrollEnd: PropTypes.func,
786
+
787
+ /**
788
+ * Callback fired when the selection state of one or multiple rows changes.
789
+ * @param {GridSelectionModel} selectionModel With all the row ids [[GridSelectionModel]].
790
+ * @param {GridCallbackDetails} details Additional details for this callback.
791
+ */
792
+ onSelectionModelChange: PropTypes.func,
793
+
794
+ /**
795
+ * Callback fired when the sort model changes before a column is sorted.
796
+ * @param {GridSortModel} model With all properties from [[GridSortModel]].
797
+ * @param {GridCallbackDetails} details Additional details for this callback.
798
+ */
799
+ onSortModelChange: PropTypes.func,
800
+
801
+ /**
802
+ * Callback fired when the state of the grid is updated.
803
+ * @param {GridState} state The new state.
804
+ * @param {MuiEvent<{}>} event The event object.
805
+ * @param {GridCallbackDetails} details Additional details for this callback.
806
+ * @internal
807
+ */
808
+ onStateChange: PropTypes.func,
809
+
810
+ /**
811
+ * The zero-based index of the current page.
812
+ * @default 0
813
+ */
814
+ page: PropTypes.number,
815
+
816
+ /**
817
+ * Set the number of rows in one page.
818
+ * If some of the rows have children (for instance in the tree data), this number represents the amount of top level rows wanted on each page.
819
+ * @default 100
820
+ */
821
+ pageSize: PropTypes.number,
822
+
823
+ /**
824
+ * If `true`, pagination is enabled.
825
+ * @default false
826
+ */
827
+ pagination: PropTypes.bool,
828
+
829
+ /**
830
+ * Pagination can be processed on the server or client-side.
831
+ * Set it to 'client' if you would like to handle the pagination on the client-side.
832
+ * Set it to 'server' if you would like to handle the pagination on the server-side.
833
+ * @default "client"
834
+ */
835
+ paginationMode: PropTypes.oneOf(['client', 'server']),
836
+
837
+ /**
838
+ * The column fields to display pinned to left or right.
839
+ */
840
+ pinnedColumns: PropTypes.shape({
841
+ left: PropTypes.arrayOf(PropTypes.string),
842
+ right: PropTypes.arrayOf(PropTypes.string)
843
+ }),
844
+
845
+ /**
846
+ * Callback called before updating a row with new values in the row and cell editing.
847
+ * Only applied if `props.experimentalFeatures.newEditingApi: true`.
848
+ * @template R
849
+ * @param {R} newRow Row object with the new values.
850
+ * @param {R} oldRow Row object with the old values.
851
+ * @returns {Promise<R> | R} The final values to update the row.
852
+ */
853
+ processRowUpdate: PropTypes.func,
854
+
855
+ /**
856
+ * Number of extra rows to be rendered before/after the visible slice.
857
+ * @default 3
858
+ */
859
+ rowBuffer: PropTypes.number,
860
+
861
+ /**
862
+ * Set the total number of rows, if it is different from the length of the value `rows` prop.
863
+ * If some rows have children (for instance in the tree data), this number represents the amount of top level rows.
864
+ */
865
+ rowCount: PropTypes.number,
866
+
867
+ /**
868
+ * If `single`, all column we are grouping by will be represented in the same grouping the same column.
869
+ * If `multiple`, each column we are grouping by will be represented in its own column.
870
+ * @default 'single'
871
+ */
872
+ rowGroupingColumnMode: PropTypes.oneOf(['multiple', 'single']),
873
+
874
+ /**
875
+ * Set the row grouping model of the grid.
876
+ */
877
+ rowGroupingModel: PropTypes.arrayOf(PropTypes.string),
878
+
879
+ /**
880
+ * Set the height in pixel of a row in the grid.
881
+ * @default 52
882
+ */
883
+ rowHeight: PropTypes.number,
884
+
885
+ /**
886
+ * Controls the modes of the rows.
887
+ */
888
+ rowModesModel: PropTypes.object,
889
+
890
+ /**
891
+ * If `true`, the reordering of rows is enabled.
892
+ * @default false
893
+ */
894
+ rowReordering: PropTypes.bool,
895
+
896
+ /**
897
+ * Set of rows of type [[GridRowsProp]].
898
+ */
899
+ rows: PropTypes.array.isRequired,
900
+
901
+ /**
902
+ * Sets the type of space between rows added by `getRowSpacing`.
903
+ * @default "margin"
904
+ */
905
+ rowSpacingType: PropTypes.oneOf(['border', 'margin']),
906
+
907
+ /**
908
+ * Select the pageSize dynamically using the component UI.
909
+ * @default [25, 50, 100]
910
+ */
911
+ rowsPerPageOptions: PropTypes.arrayOf(PropTypes.number),
912
+
913
+ /**
914
+ * Number of rows from the `rowBuffer` that can be visible before a new slice is rendered.
915
+ * @default 3
916
+ */
917
+ rowThreshold: PropTypes.number,
918
+
919
+ /**
920
+ * Override the height/width of the grid inner scrollbar.
921
+ */
922
+ scrollbarSize: PropTypes.number,
923
+
924
+ /**
925
+ * Set the area in `px` at the bottom of the grid viewport where onRowsScrollEnd is called.
926
+ * @default 80
927
+ */
928
+ scrollEndThreshold: PropTypes.number,
929
+
930
+ /**
931
+ * Set the selection model of the grid.
932
+ */
933
+ selectionModel: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string]).isRequired), PropTypes.number, PropTypes.string]),
934
+
935
+ /**
936
+ * If `true`, the right border of the cells are displayed.
937
+ * @default false
938
+ */
939
+ showCellRightBorder: PropTypes.bool,
940
+
941
+ /**
942
+ * If `true`, the right border of the column headers are displayed.
943
+ * @default false
944
+ */
945
+ showColumnRightBorder: PropTypes.bool,
946
+
947
+ /**
948
+ * Sorting can be processed on the server or client-side.
949
+ * Set it to 'client' if you would like to handle sorting on the client-side.
950
+ * Set it to 'server' if you would like to handle sorting on the server-side.
951
+ * @default "client"
952
+ */
953
+ sortingMode: PropTypes.oneOf(['client', 'server']),
954
+
955
+ /**
956
+ * The order of the sorting sequence.
957
+ * @default ['asc', 'desc', null]
958
+ */
959
+ sortingOrder: PropTypes.arrayOf(PropTypes.oneOf(['asc', 'desc'])),
960
+
961
+ /**
962
+ * Set the sort model of the grid.
963
+ */
964
+ sortModel: PropTypes.arrayOf(PropTypes.shape({
965
+ field: PropTypes.string.isRequired,
966
+ sort: PropTypes.oneOf(['asc', 'desc'])
967
+ })),
968
+
969
+ /**
970
+ * The system prop that allows defining system overrides as well as additional CSS styles.
971
+ */
972
+ sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
973
+
974
+ /**
975
+ * If positive, the Grid will throttle updates coming from `apiRef.current.updateRows` and `apiRef.current.setRows`.
976
+ * It can be useful if you have a high update rate but do not want to do heavy work like filtering / sorting or rendering on each individual update.
977
+ * @default 0
978
+ */
979
+ throttleRowsMs: PropTypes.number,
980
+
981
+ /**
982
+ * If `true`, the rows will be gathered in a tree structure according to the `getTreeDataPath` prop.
983
+ * @default false
984
+ */
985
+ treeData: PropTypes.bool
986
+ } : void 0;