@mui/x-data-grid 8.9.1 → 8.10.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 (156) hide show
  1. package/CHANGELOG.md +217 -8
  2. package/DataGrid/DataGrid.js +5 -0
  3. package/DataGrid/useDataGridComponent.js +2 -0
  4. package/colDef/gridCheckboxSelectionColDef.js +1 -0
  5. package/components/GridDetailPanels.d.ts +2 -2
  6. package/components/GridFooter.js +1 -1
  7. package/components/GridPagination.js +4 -3
  8. package/components/GridPinnedRows.d.ts +2 -2
  9. package/components/GridRow.js +8 -1
  10. package/components/cell/GridCell.js +7 -5
  11. package/components/cell/GridEditSingleSelectCell.js +1 -1
  12. package/components/columnsManagement/GridColumnsManagement.d.ts +6 -0
  13. package/components/columnsManagement/GridColumnsManagement.js +17 -5
  14. package/components/containers/GridRootStyles.d.ts +1 -1
  15. package/components/toolbarV8/Toolbar.d.ts +1 -1
  16. package/components/virtualization/GridVirtualScroller.js +5 -5
  17. package/constants/dataGridPropsDefaultValues.js +1 -0
  18. package/esm/DataGrid/DataGrid.js +5 -0
  19. package/esm/DataGrid/useDataGridComponent.js +2 -0
  20. package/esm/colDef/gridCheckboxSelectionColDef.js +1 -0
  21. package/esm/components/GridDetailPanels.d.ts +2 -2
  22. package/esm/components/GridFooter.js +1 -1
  23. package/esm/components/GridPagination.js +3 -2
  24. package/esm/components/GridPinnedRows.d.ts +2 -2
  25. package/esm/components/GridRow.js +8 -1
  26. package/esm/components/cell/GridCell.js +7 -5
  27. package/esm/components/cell/GridEditSingleSelectCell.js +1 -1
  28. package/esm/components/columnsManagement/GridColumnsManagement.d.ts +6 -0
  29. package/esm/components/columnsManagement/GridColumnsManagement.js +17 -5
  30. package/esm/components/containers/GridRootStyles.d.ts +1 -1
  31. package/esm/components/toolbarV8/Toolbar.d.ts +1 -1
  32. package/esm/components/virtualization/GridVirtualScroller.js +5 -5
  33. package/esm/constants/dataGridPropsDefaultValues.js +1 -0
  34. package/esm/hooks/core/useGridVirtualizer.d.ts +9 -0
  35. package/esm/hooks/core/useGridVirtualizer.js +223 -0
  36. package/esm/hooks/features/columnHeaders/useGridColumnHeaders.d.ts +1 -1
  37. package/esm/hooks/features/columnHeaders/useGridColumnHeaders.js +3 -2
  38. package/esm/hooks/features/columns/useGridColumnSpanning.js +5 -90
  39. package/esm/hooks/features/dataSource/models.d.ts +11 -2
  40. package/esm/hooks/features/dataSource/useGridDataSourceBase.d.ts +1 -1
  41. package/esm/hooks/features/dataSource/useGridDataSourceBase.js +9 -2
  42. package/esm/hooks/features/dimensions/useGridDimensions.js +18 -188
  43. package/esm/hooks/features/editing/useGridRowEditing.js +4 -1
  44. package/esm/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +1 -1
  45. package/esm/hooks/features/keyboardNavigation/utils.d.ts +3 -3
  46. package/esm/hooks/features/keyboardNavigation/utils.js +5 -5
  47. package/esm/hooks/features/pivoting/gridPivotingInterfaces.d.ts +0 -1
  48. package/esm/hooks/features/pivoting/gridPivotingSelectors.d.ts +1 -4
  49. package/esm/hooks/features/pivoting/gridPivotingSelectors.js +1 -2
  50. package/esm/hooks/features/rowReorder/gridRowReorderInterfaces.d.ts +9 -0
  51. package/esm/hooks/features/rowReorder/gridRowReorderInterfaces.js +1 -0
  52. package/esm/hooks/features/rowReorder/gridRowReorderSelector.d.ts +5 -0
  53. package/esm/hooks/features/rowReorder/gridRowReorderSelector.js +3 -0
  54. package/esm/hooks/features/rowSelection/useGridRowSelection.js +2 -2
  55. package/esm/hooks/features/rowSelection/utils.js +5 -0
  56. package/esm/hooks/features/rows/gridRowsMetaInterfaces.d.ts +2 -8
  57. package/esm/hooks/features/rows/gridRowsMetaState.d.ts +2 -18
  58. package/esm/hooks/features/rows/useGridRowAriaAttributes.js +3 -1
  59. package/esm/hooks/features/rows/useGridRowSpanning.d.ts +2 -12
  60. package/esm/hooks/features/rows/useGridRowSpanning.js +54 -85
  61. package/esm/hooks/features/rows/useGridRowsMeta.d.ts +1 -1
  62. package/esm/hooks/features/rows/useGridRowsMeta.js +17 -187
  63. package/esm/hooks/features/virtualization/gridVirtualizationSelectors.d.ts +1 -1
  64. package/esm/hooks/features/virtualization/index.d.ts +1 -0
  65. package/esm/hooks/features/virtualization/index.js +1 -0
  66. package/esm/hooks/features/virtualization/useGridVirtualization.d.ts +5 -16
  67. package/esm/hooks/features/virtualization/useGridVirtualization.js +41 -22
  68. package/esm/hooks/utils/index.d.ts +1 -1
  69. package/esm/hooks/utils/index.js +1 -1
  70. package/esm/hooks/utils/useFirstRender.d.ts +1 -1
  71. package/esm/hooks/utils/useFirstRender.js +1 -8
  72. package/esm/index.js +1 -1
  73. package/esm/internals/index.d.ts +3 -1
  74. package/esm/internals/index.js +2 -1
  75. package/esm/internals/utils/getPinnedCellOffset.js +5 -0
  76. package/esm/locales/frFR.js +18 -21
  77. package/esm/locales/heIL.js +12 -12
  78. package/esm/locales/nnNO.js +96 -107
  79. package/esm/locales/plPL.js +22 -24
  80. package/esm/material/index.js +2 -2
  81. package/esm/models/api/gridApiCommon.d.ts +4 -1
  82. package/esm/models/api/gridColumnSpanning.d.ts +5 -11
  83. package/esm/models/gridStateCommunity.d.ts +2 -0
  84. package/esm/models/props/DataGridProps.d.ts +5 -0
  85. package/esm/utils/roundToDecimalPlaces.d.ts +1 -1
  86. package/esm/utils/roundToDecimalPlaces.js +1 -3
  87. package/hooks/core/useGridVirtualizer.d.ts +9 -0
  88. package/hooks/core/useGridVirtualizer.js +231 -0
  89. package/hooks/features/columnHeaders/useGridColumnHeaders.d.ts +1 -1
  90. package/hooks/features/columnHeaders/useGridColumnHeaders.js +4 -3
  91. package/hooks/features/columns/useGridColumnSpanning.js +5 -91
  92. package/hooks/features/dataSource/models.d.ts +11 -2
  93. package/hooks/features/dataSource/useGridDataSourceBase.d.ts +1 -1
  94. package/hooks/features/dataSource/useGridDataSourceBase.js +10 -3
  95. package/hooks/features/dimensions/useGridDimensions.js +18 -188
  96. package/hooks/features/editing/useGridRowEditing.js +4 -1
  97. package/hooks/features/keyboardNavigation/useGridKeyboardNavigation.js +1 -1
  98. package/hooks/features/keyboardNavigation/utils.d.ts +3 -3
  99. package/hooks/features/keyboardNavigation/utils.js +5 -5
  100. package/hooks/features/pivoting/gridPivotingInterfaces.d.ts +0 -1
  101. package/hooks/features/pivoting/gridPivotingSelectors.d.ts +1 -4
  102. package/hooks/features/pivoting/gridPivotingSelectors.js +2 -3
  103. package/hooks/features/rowReorder/gridRowReorderInterfaces.d.ts +9 -0
  104. package/hooks/features/rowReorder/gridRowReorderInterfaces.js +5 -0
  105. package/hooks/features/rowReorder/gridRowReorderSelector.d.ts +5 -0
  106. package/hooks/features/rowReorder/gridRowReorderSelector.js +9 -0
  107. package/hooks/features/rowSelection/useGridRowSelection.js +2 -2
  108. package/hooks/features/rowSelection/utils.js +5 -0
  109. package/hooks/features/rows/gridRowsMetaInterfaces.d.ts +2 -8
  110. package/hooks/features/rows/gridRowsMetaState.d.ts +2 -18
  111. package/hooks/features/rows/useGridRowAriaAttributes.js +3 -1
  112. package/hooks/features/rows/useGridRowSpanning.d.ts +2 -12
  113. package/hooks/features/rows/useGridRowSpanning.js +54 -85
  114. package/hooks/features/rows/useGridRowsMeta.d.ts +1 -1
  115. package/hooks/features/rows/useGridRowsMeta.js +15 -186
  116. package/hooks/features/virtualization/gridVirtualizationSelectors.d.ts +1 -1
  117. package/hooks/features/virtualization/index.d.ts +1 -0
  118. package/hooks/features/virtualization/index.js +12 -0
  119. package/hooks/features/virtualization/useGridVirtualization.d.ts +5 -16
  120. package/hooks/features/virtualization/useGridVirtualization.js +42 -24
  121. package/hooks/utils/index.d.ts +1 -1
  122. package/hooks/utils/index.js +12 -12
  123. package/hooks/utils/useFirstRender.d.ts +1 -1
  124. package/hooks/utils/useFirstRender.js +11 -11
  125. package/index.js +1 -1
  126. package/internals/index.d.ts +3 -1
  127. package/internals/index.js +12 -11
  128. package/internals/utils/getPinnedCellOffset.js +5 -0
  129. package/locales/frFR.js +18 -21
  130. package/locales/heIL.js +12 -12
  131. package/locales/nnNO.js +96 -107
  132. package/locales/plPL.js +22 -24
  133. package/material/index.js +2 -2
  134. package/models/api/gridApiCommon.d.ts +4 -1
  135. package/models/api/gridColumnSpanning.d.ts +5 -11
  136. package/models/gridStateCommunity.d.ts +2 -0
  137. package/models/props/DataGridProps.d.ts +5 -0
  138. package/package.json +5 -6
  139. package/utils/roundToDecimalPlaces.d.ts +1 -1
  140. package/utils/roundToDecimalPlaces.js +7 -4
  141. package/esm/hooks/features/rows/gridRowSpanningSelectors.d.ts +0 -10
  142. package/esm/hooks/features/rows/gridRowSpanningSelectors.js +0 -5
  143. package/esm/hooks/features/virtualization/useGridVirtualScroller.d.ts +0 -56
  144. package/esm/hooks/features/virtualization/useGridVirtualScroller.js +0 -843
  145. package/esm/hooks/utils/useRunOnce.d.ts +0 -5
  146. package/esm/hooks/utils/useRunOnce.js +0 -18
  147. package/esm/utils/platform.d.ts +0 -1
  148. package/esm/utils/platform.js +0 -2
  149. package/hooks/features/rows/gridRowSpanningSelectors.d.ts +0 -10
  150. package/hooks/features/rows/gridRowSpanningSelectors.js +0 -11
  151. package/hooks/features/virtualization/useGridVirtualScroller.d.ts +0 -56
  152. package/hooks/features/virtualization/useGridVirtualScroller.js +0 -854
  153. package/hooks/utils/useRunOnce.d.ts +0 -5
  154. package/hooks/utils/useRunOnce.js +0 -27
  155. package/utils/platform.d.ts +0 -1
  156. package/utils/platform.js +0 -8
package/locales/nnNO.js CHANGED
@@ -9,10 +9,9 @@ const nnNOGrid = {
9
9
  // Root
10
10
  noRowsLabel: 'Ingen rader',
11
11
  noResultsOverlayLabel: 'Fann ingen resultat.',
12
- // noColumnsOverlayLabel: 'No columns',
13
- // noColumnsOverlayManageColumns: 'Manage columns',
14
- // emptyPivotOverlayLabel: 'Add fields to rows, columns, and values to create a pivot table',
15
-
12
+ noColumnsOverlayLabel: 'Ingen kolonner',
13
+ noColumnsOverlayManageColumns: 'Vel kolonner',
14
+ emptyPivotOverlayLabel: 'Legg til felt i rader, kolonner og verdiar for å opprette ein pivot-tabell',
16
15
  // Density selector toolbar button text
17
16
  toolbarDensity: 'Tettheit',
18
17
  toolbarDensityLabel: 'Tettheit',
@@ -39,18 +38,15 @@ const nnNOGrid = {
39
38
  toolbarExportPrint: 'Skriv ut',
40
39
  toolbarExportExcel: 'Last ned som Excel',
41
40
  // Toolbar pivot button
42
- // toolbarPivot: 'Pivot',
43
-
41
+ toolbarPivot: 'Pivot',
44
42
  // Toolbar AI Assistant button
45
- // toolbarAssistant: 'AI Assistant',
46
-
43
+ toolbarAssistant: 'AI Assistent',
47
44
  // Columns management text
48
45
  columnsManagementSearchTitle: 'Søk',
49
46
  columnsManagementNoColumns: 'Ingen kolonner',
50
47
  columnsManagementShowHideAllText: 'Vis/skjul alle',
51
48
  columnsManagementReset: 'Nullstill',
52
- // columnsManagementDeleteIconLabel: 'Clear',
53
-
49
+ columnsManagementDeleteIconLabel: 'Tøm',
54
50
  // Filter panel text
55
51
  filterPanelAddFilter: 'Legg til filter',
56
52
  filterPanelRemoveAll: 'Fjern alle',
@@ -64,9 +60,9 @@ const nnNOGrid = {
64
60
  filterPanelInputPlaceholder: 'Filter verdi',
65
61
  // Filter operators text
66
62
  filterOperatorContains: 'inneheld',
67
- // filterOperatorDoesNotContain: 'does not contain',
63
+ filterOperatorDoesNotContain: 'inneheld ikkje',
68
64
  filterOperatorEquals: 'er lik',
69
- // filterOperatorDoesNotEqual: 'does not equal',
65
+ filterOperatorDoesNotEqual: 'er ikkje lik',
70
66
  filterOperatorStartsWith: 'startar med',
71
67
  filterOperatorEndsWith: 'sluttar med',
72
68
  filterOperatorIs: 'er',
@@ -86,9 +82,9 @@ const nnNOGrid = {
86
82
  'filterOperator<=': '<=',
87
83
  // Header filter operators text
88
84
  headerFilterOperatorContains: 'Inneheld',
89
- // headerFilterOperatorDoesNotContain: 'Does not contain',
85
+ headerFilterOperatorDoesNotContain: 'Inneheld ikkje',
90
86
  headerFilterOperatorEquals: 'Lik',
91
- // headerFilterOperatorDoesNotEqual: 'Does not equal',
87
+ headerFilterOperatorDoesNotEqual: 'Er ikkje lik',
92
88
  headerFilterOperatorStartsWith: 'Startar på',
93
89
  headerFilterOperatorEndsWith: 'Sluttar på',
94
90
  headerFilterOperatorIs: 'Er',
@@ -106,15 +102,14 @@ const nnNOGrid = {
106
102
  'headerFilterOperator>=': 'Større enn eller lik',
107
103
  'headerFilterOperator<': 'Mindre enn',
108
104
  'headerFilterOperator<=': 'Mindre enn eller lik',
109
- // headerFilterClear: 'Clear filter',
110
-
105
+ headerFilterClear: 'Tøm filter',
111
106
  // Filter values text
112
107
  filterValueAny: 'nokon',
113
108
  filterValueTrue: 'sant',
114
109
  filterValueFalse: 'usant',
115
110
  // Column menu text
116
111
  columnMenuLabel: 'Meny',
117
- // columnMenuAriaLabel: (columnName: string) => `${columnName} column menu`,
112
+ columnMenuAriaLabel: columnName => `${columnName} kolonne meny`,
118
113
  columnMenuShowColumns: 'Vis kolonner',
119
114
  columnMenuManageColumns: 'Administrer kolonner',
120
115
  columnMenuFilter: 'Filter',
@@ -122,8 +117,7 @@ const nnNOGrid = {
122
117
  columnMenuUnsort: 'Usorter',
123
118
  columnMenuSortAsc: 'Sorter AUKANDE',
124
119
  columnMenuSortDesc: 'Sorter SYNKANDE',
125
- // columnMenuManagePivot: 'Manage pivot',
126
-
120
+ columnMenuManagePivot: 'Behandle pivot',
127
121
  // Column header text
128
122
  columnHeaderFiltersTooltipActive: count => count !== 1 ? `${count} aktive filter` : `${count} aktivt filter`,
129
123
  columnHeaderFiltersLabel: 'Vis filter',
@@ -158,23 +152,23 @@ const nnNOGrid = {
158
152
  groupColumn: name => `Grupper på ${name}`,
159
153
  unGroupColumn: name => `Slutt å grupper på ${name}`,
160
154
  // Master/detail
161
- detailPanelToggle: 'Utvid/kollaps detalj panel',
162
- expandDetailPanel: 'Utvid',
163
- collapseDetailPanel: 'Kolaps',
155
+ detailPanelToggle: 'Vis/gøym detaljpanel',
156
+ expandDetailPanel: 'Vis',
157
+ collapseDetailPanel: 'Gøym',
164
158
  // Pagination
165
159
  paginationRowsPerPage: 'Rader per side:',
166
- // paginationDisplayedRows: ({
167
- // from,
168
- // to,
169
- // count,
170
- // estimated
171
- // }) => {
172
- // if (!estimated) {
173
- // return `${from}–${to} of ${count !== -1 ? count : `more than ${to}`}`;
174
- // }
175
- // const estimatedLabel = estimated && estimated > to ? `around ${estimated}` : `more than ${to}`;
176
- // return `${from}–${to} of ${count !== -1 ? count : estimatedLabel}`;
177
- // },
160
+ paginationDisplayedRows: ({
161
+ from,
162
+ to,
163
+ count,
164
+ estimated
165
+ }) => {
166
+ if (!estimated) {
167
+ return `${from}–${to} av ${count !== -1 ? count : `flere enn ${to}`}`;
168
+ }
169
+ const estimatedLabel = estimated && estimated > to ? `omtrent ${estimated}` : `flere enn ${to}`;
170
+ return `${from}–${to} av ${count !== -1 ? count : estimatedLabel}`;
171
+ },
178
172
  paginationItemAriaLabel: type => {
179
173
  if (type === 'first') {
180
174
  return 'Gå til første side';
@@ -196,83 +190,78 @@ const nnNOGrid = {
196
190
  aggregationFunctionLabelAvg: 'snitt',
197
191
  aggregationFunctionLabelMin: 'min',
198
192
  aggregationFunctionLabelMax: 'maks',
199
- aggregationFunctionLabelSize: 'størrelse'
200
-
193
+ aggregationFunctionLabelSize: 'størrelse',
201
194
  // Pivot panel
202
- // pivotToggleLabel: 'Pivot',
203
- // pivotRows: 'Rows',
204
- // pivotColumns: 'Columns',
205
- // pivotValues: 'Values',
206
- // pivotCloseButton: 'Close pivot settings',
207
- // pivotSearchButton: 'Search fields',
208
- // pivotSearchControlPlaceholder: 'Search fields',
209
- // pivotSearchControlLabel: 'Search fields',
210
- // pivotSearchControlClear: 'Clear search',
211
- // pivotNoFields: 'No fields',
212
- // pivotMenuMoveUp: 'Move up',
213
- // pivotMenuMoveDown: 'Move down',
214
- // pivotMenuMoveToTop: 'Move to top',
215
- // pivotMenuMoveToBottom: 'Move to bottom',
216
- // pivotMenuRows: 'Rows',
217
- // pivotMenuColumns: 'Columns',
218
- // pivotMenuValues: 'Values',
219
- // pivotMenuOptions: 'Field options',
220
- // pivotMenuAddToRows: 'Add to Rows',
221
- // pivotMenuAddToColumns: 'Add to Columns',
222
- // pivotMenuAddToValues: 'Add to Values',
223
- // pivotMenuRemove: 'Remove',
224
- // pivotDragToRows: 'Drag here to create rows',
225
- // pivotDragToColumns: 'Drag here to create columns',
226
- // pivotDragToValues: 'Drag here to create values',
227
- // pivotYearColumnHeaderName: '(Year)',
228
- // pivotQuarterColumnHeaderName: '(Quarter)',
229
-
195
+ pivotToggleLabel: 'Pivot',
196
+ pivotRows: 'Rader',
197
+ pivotColumns: 'Kolonner',
198
+ pivotValues: 'Verdiar',
199
+ pivotCloseButton: 'Lukk pivotinnstillingar',
200
+ pivotSearchButton: 'Søk felt',
201
+ pivotSearchControlPlaceholder: 'Søk felt',
202
+ pivotSearchControlLabel: 'Søk felt',
203
+ pivotSearchControlClear: 'Tøm søk',
204
+ pivotNoFields: 'Ingen felt',
205
+ pivotMenuMoveUp: 'Flytt opp',
206
+ pivotMenuMoveDown: 'Flytt ned',
207
+ pivotMenuMoveToTop: 'Flytt til toppen',
208
+ pivotMenuMoveToBottom: 'Flytt til botnen',
209
+ pivotMenuRows: 'Rader',
210
+ pivotMenuColumns: 'Kolonner',
211
+ pivotMenuValues: 'Verdiar',
212
+ pivotMenuOptions: 'Feltalternativ',
213
+ pivotMenuAddToRows: 'Legg til i Rader',
214
+ pivotMenuAddToColumns: 'Legg til i Kolonner',
215
+ pivotMenuAddToValues: 'Legg til i Verdiar',
216
+ pivotMenuRemove: 'Fjern',
217
+ pivotDragToRows: 'Dra hit for å opprette rader',
218
+ pivotDragToColumns: 'Dra hit for å opprette kolonner',
219
+ pivotDragToValues: 'Dra hit for å opprette verdiar',
220
+ pivotYearColumnHeaderName: '(År)',
221
+ pivotQuarterColumnHeaderName: '(Kvartal)',
230
222
  // AI Assistant panel
231
- // aiAssistantPanelTitle: 'AI Assistant',
232
- // aiAssistantPanelClose: 'Close AI Assistant',
233
- // aiAssistantPanelNewConversation: 'New conversation',
234
- // aiAssistantPanelConversationHistory: 'Conversation history',
235
- // aiAssistantPanelEmptyConversation: 'No prompt history',
236
- // aiAssistantSuggestions: 'Suggestions',
237
-
223
+ aiAssistantPanelTitle: 'AI Assistent',
224
+ aiAssistantPanelClose: 'Lukk AI Assistent',
225
+ aiAssistantPanelNewConversation: 'Ny samtale',
226
+ aiAssistantPanelConversationHistory: 'Samtalehistorikk',
227
+ aiAssistantPanelEmptyConversation: 'Ingen prompt-historikk',
228
+ aiAssistantSuggestions: 'Forslag',
238
229
  // Prompt field
239
- // promptFieldLabel: 'Prompt',
240
- // promptFieldPlaceholder: 'Type a prompt…',
241
- // promptFieldPlaceholderWithRecording: 'Type or record a prompt…',
242
- // promptFieldPlaceholderListening: 'Listening for prompt…',
243
- // promptFieldSpeechRecognitionNotSupported: 'Speech recognition is not supported in this browser',
244
- // promptFieldSend: 'Send',
245
- // promptFieldRecord: 'Record',
246
- // promptFieldStopRecording: 'Stop recording',
247
-
230
+ promptFieldLabel: 'Prompt',
231
+ promptFieldPlaceholder: 'Skriv ein prompt…',
232
+ promptFieldPlaceholderWithRecording: 'Skriv eller spel inn ein prompt…',
233
+ promptFieldPlaceholderListening: 'Lyttar etter prompt…',
234
+ promptFieldSpeechRecognitionNotSupported: 'Talegjenkjenning er ikkje støtta i denne nettlesaren',
235
+ promptFieldSend: 'Send',
236
+ promptFieldRecord: 'Spel inn',
237
+ promptFieldStopRecording: 'Stopp opptak',
248
238
  // Prompt
249
- // promptRerun: 'Run again',
250
- // promptProcessing: 'Processing…',
251
- // promptAppliedChanges: 'Applied changes',
252
-
239
+ promptRerun: 'Kjør på nytt',
240
+ promptProcessing: 'Behandlar…',
241
+ promptAppliedChanges: 'Brukte endringar',
253
242
  // Prompt changes
254
- // promptChangeGroupDescription: (column: string) => `Group by ${column}`,
255
- // promptChangeAggregationLabel: (column: string, aggregation: string) => `${column} (${aggregation})`,
256
- // promptChangeAggregationDescription: (column: string, aggregation: string) => `Aggregate ${column} (${aggregation})`,
257
- // promptChangeFilterLabel: (column: string, operator: string, value: string) => {
258
- // if (operator === 'is any of') {
259
- // return `${column} is any of: ${value}`;
260
- // }
261
- // return `${column} ${operator} ${value}`;
262
- // },
263
- // promptChangeFilterDescription: (column: string, operator: string, value: string) => {
264
- // if (operator === 'is any of') {
265
- // return `Filter where ${column} is any of: ${value}`;
266
- // }
267
- // return `Filter where ${column} ${operator} ${value}`;
268
- // },
269
- // promptChangeSortDescription: (column: string, direction: string) => `Sort by ${column} (${direction})`,
270
- // promptChangePivotEnableLabel: 'Pivot',
271
- // promptChangePivotEnableDescription: 'Enable pivot',
272
- // promptChangePivotColumnsLabel: (count: number) => `Columns (${count})`,
273
- // promptChangePivotColumnsDescription: (column: string, direction: string) => `${column}${direction ? ` (${direction})` : ''}`,
274
- // promptChangePivotRowsLabel: (count: number) => `Rows (${count})`,
275
- // promptChangePivotValuesLabel: (count: number) => `Values (${count})`,
276
- // promptChangePivotValuesDescription: (column: string, aggregation: string) => `${column} (${aggregation})`,
243
+ promptChangeGroupDescription: column => `Grupper etter ${column}`,
244
+ promptChangeAggregationLabel: (column, aggregation) => `${column} (${aggregation})`,
245
+ promptChangeAggregationDescription: (column, aggregation) => `Aggreger ${column} (${aggregation})`,
246
+ promptChangeFilterLabel: (column, operator, value) => {
247
+ if (operator === 'is any of') {
248
+ return `${column} er ein av: ${value}`;
249
+ }
250
+ return `${column} ${operator} ${value}`;
251
+ },
252
+ promptChangeFilterDescription: (column, operator, value) => {
253
+ if (operator === 'is any of') {
254
+ return `Filter der ${column} er ein av: ${value}`;
255
+ }
256
+ return `Filter der ${column} ${operator} ${value}`;
257
+ },
258
+ promptChangeSortDescription: (column, direction) => `Sorter etter ${column} (${direction})`,
259
+ promptChangePivotEnableLabel: 'Pivot',
260
+ promptChangePivotEnableDescription: 'Aktiver pivot',
261
+ promptChangePivotColumnsLabel: count => `Kolonner (${count})`,
262
+ promptChangePivotColumnsDescription: (column, direction) => `${column}${direction ? ` (${direction})` : ''}`,
263
+ promptChangePivotRowsLabel: count => `Rader (${count})`,
264
+ promptChangePivotValuesLabel: count => `Verdiar (${count})`,
265
+ promptChangePivotValuesDescription: (column, aggregation) => `${column} (${aggregation})`
277
266
  };
278
267
  const nnNO = exports.nnNO = (0, _getGridLocalization.getGridLocalization)(nnNOGrid);
package/locales/plPL.js CHANGED
@@ -9,8 +9,8 @@ const plPLGrid = {
9
9
  // Root
10
10
  noRowsLabel: 'Brak danych',
11
11
  noResultsOverlayLabel: 'Nie znaleziono wyników.',
12
- // noColumnsOverlayLabel: 'No columns',
13
- // noColumnsOverlayManageColumns: 'Manage columns',
12
+ noColumnsOverlayLabel: 'Brak kolumn',
13
+ noColumnsOverlayManageColumns: 'Zarządzaj kolumnami',
14
14
  // emptyPivotOverlayLabel: 'Add fields to rows, columns, and values to create a pivot table',
15
15
 
16
16
  // Density selector toolbar button text
@@ -42,8 +42,7 @@ const plPLGrid = {
42
42
  // toolbarPivot: 'Pivot',
43
43
 
44
44
  // Toolbar AI Assistant button
45
- // toolbarAssistant: 'AI Assistant',
46
-
45
+ toolbarAssistant: 'Asystent AI',
47
46
  // Columns management text
48
47
  columnsManagementSearchTitle: 'Szukaj',
49
48
  columnsManagementNoColumns: 'Brak kolumn',
@@ -161,18 +160,18 @@ const plPLGrid = {
161
160
  collapseDetailPanel: 'Zwiń',
162
161
  // Pagination
163
162
  paginationRowsPerPage: 'Wierszy na stronę:',
164
- // paginationDisplayedRows: ({
165
- // from,
166
- // to,
167
- // count,
168
- // estimated
169
- // }) => {
170
- // if (!estimated) {
171
- // return `${from}–${to} of ${count !== -1 ? count : `more than ${to}`}`;
172
- // }
173
- // const estimatedLabel = estimated && estimated > to ? `around ${estimated}` : `more than ${to}`;
174
- // return `${from}–${to} of ${count !== -1 ? count : estimatedLabel}`;
175
- // },
163
+ paginationDisplayedRows: ({
164
+ from,
165
+ to,
166
+ count,
167
+ estimated
168
+ }) => {
169
+ if (!estimated) {
170
+ return `${from}–${to} z ${count !== -1 ? count : `więcej niż ${to}`}`;
171
+ }
172
+ const estimatedLabel = estimated && estimated > to ? `około ${estimated}` : `więcej niż ${to}`;
173
+ return `${from}–${to} z ${count !== -1 ? count : estimatedLabel}`;
174
+ },
176
175
  paginationItemAriaLabel: type => {
177
176
  if (type === 'first') {
178
177
  return 'Przejdź do pierwszej strony';
@@ -225,19 +224,18 @@ const plPLGrid = {
225
224
  // pivotQuarterColumnHeaderName: '(Quarter)',
226
225
 
227
226
  // AI Assistant panel
228
- // aiAssistantPanelTitle: 'AI Assistant',
229
- // aiAssistantPanelClose: 'Close AI Assistant',
230
- // aiAssistantPanelNewConversation: 'New conversation',
231
- // aiAssistantPanelConversationHistory: 'Conversation history',
232
- // aiAssistantPanelEmptyConversation: 'No prompt history',
233
- // aiAssistantSuggestions: 'Suggestions',
234
-
227
+ aiAssistantPanelTitle: 'Asystent AI',
228
+ aiAssistantPanelClose: 'Zamknij asystenta AI',
229
+ aiAssistantPanelNewConversation: 'Nowa konwersacja',
230
+ aiAssistantPanelConversationHistory: 'Historia konwersacji',
231
+ aiAssistantPanelEmptyConversation: 'Brak historii poleceń',
232
+ aiAssistantSuggestions: 'Sugestie',
235
233
  // Prompt field
236
234
  promptFieldLabel: 'Wprowadź polecenie',
237
235
  promptFieldPlaceholder: 'Wpisz polecenie…',
238
236
  promptFieldPlaceholderWithRecording: 'Wpisz lub nagraj polecenie…',
239
237
  promptFieldPlaceholderListening: 'Nasłuchiwanie polecenia…',
240
- // promptFieldSpeechRecognitionNotSupported: 'Speech recognition is not supported in this browser',
238
+ promptFieldSpeechRecognitionNotSupported: 'Rozpoznawanie głosu nie jest obsługiwane przez Twoją przeglądarkę.',
241
239
  promptFieldSend: 'Wyślij',
242
240
  promptFieldRecord: 'Nagrywaj',
243
241
  promptFieldStopRecording: 'Zatrzymaj nagrywanie'
package/material/index.js CHANGED
@@ -172,9 +172,9 @@ const BaseSelect = (0, _forwardRef.forwardRef)(function BaseSelect(props, ref) {
172
172
  labelId: labelId,
173
173
  label: label,
174
174
  displayEmpty: true,
175
- onChange: onChange
175
+ onChange: onChange,
176
+ variant: "outlined"
176
177
  }, rest, {
177
- variant: "outlined",
178
178
  notched: true,
179
179
  inputProps: slotProps?.htmlInput,
180
180
  onOpen: onOpen,
@@ -1,3 +1,4 @@
1
+ import type { Virtualizer } from '@mui/x-virtualizer';
1
2
  import type { GridColumnApi } from "./gridColumnApi.js";
2
3
  import type { GridColumnMenuApi } from "./gridColumnMenuApi.js";
3
4
  import type { GridCoreApi, GridCorePrivateApi } from "./gridCoreApi.js";
@@ -31,5 +32,7 @@ import type { DataGridProcessedProps } from "../props/DataGridProps.js";
31
32
  import type { GridColumnResizeApi } from "../../hooks/features/columnResize/index.js";
32
33
  import type { GridPivotingPrivateApiCommunity } from "../../hooks/features/pivoting/gridPivotingInterfaces.js";
33
34
  export interface GridApiCommon<GridState extends GridStateCommunity = any, GridInitialState extends GridInitialStateCommunity = any> extends GridCoreApi, GridPipeProcessingApi, GridDensityApi, GridDimensionsApi, GridRowApi, GridRowsMetaApi, GridEditingApi, GridParamsApi, GridColumnApi, GridRowSelectionApi, GridSortApi, GridPaginationApi, GridCsvExportApi, GridFocusApi, GridFilterApi, GridColumnMenuApi, GridPreferencesPanelApi, GridPrintExportApi, GridVirtualizationApi, GridLocaleTextApi, GridScrollApi, GridColumnSpanningApi, GridStateApi<GridState>, GridStatePersistenceApi<GridInitialState>, GridColumnGroupingApi, GridHeaderFilteringApi, GridColumnResizeApi {}
34
- export interface GridPrivateOnlyApiCommon<Api extends GridApiCommon, PrivateApi extends GridPrivateApiCommon, Props extends DataGridProcessedProps> extends GridCorePrivateApi<Api, PrivateApi, Props>, GridStatePrivateApi<PrivateApi['state']>, GridPipeProcessingPrivateApi, GridStrategyProcessingApi, GridColumnSpanningPrivateApi, GridRowsMetaPrivateApi, GridDimensionsPrivateApi, GridEditingPrivateApi, GridLoggerApi, GridFocusPrivateApi, GridHeaderFilteringPrivateApi, GridVirtualizationPrivateApi, GridRowProPrivateApi, GridParamsPrivateApi, GridPivotingPrivateApiCommunity {}
35
+ export interface GridPrivateOnlyApiCommon<Api extends GridApiCommon, PrivateApi extends GridPrivateApiCommon, Props extends DataGridProcessedProps> extends GridCorePrivateApi<Api, PrivateApi, Props>, GridStatePrivateApi<PrivateApi['state']>, GridPipeProcessingPrivateApi, GridStrategyProcessingApi, GridColumnSpanningPrivateApi, GridRowsMetaPrivateApi, GridDimensionsPrivateApi, GridEditingPrivateApi, GridLoggerApi, GridFocusPrivateApi, GridHeaderFilteringPrivateApi, GridVirtualizationPrivateApi, GridRowProPrivateApi, GridParamsPrivateApi, GridPivotingPrivateApiCommunity {
36
+ virtualizer: Virtualizer;
37
+ }
35
38
  export interface GridPrivateApiCommon extends GridApiCommon, GridPrivateOnlyApiCommon<GridApiCommon, GridPrivateApiCommon, DataGridProcessedProps> {}
@@ -19,16 +19,10 @@ export interface GridColumnSpanningPrivateApi {
19
19
  resetColSpan: () => void;
20
20
  /**
21
21
  * Calculate column spanning for each cell in the row
22
- * @param {Object} options The options to apply on the calculation.
23
- * @param {GridRowId} options.rowId The row id
24
- * @param {number} options.minFirstColumn First visible column index
25
- * @param {number} options.maxLastColumn Last visible column index
26
- * @param {GridStateColDef[]} options.columns List of columns to calculate colSpan for
22
+ * @param {GridRowId} rowId The row id
23
+ * @param {number} minFirstColumn First visible column index
24
+ * @param {number} maxLastColumn Last visible column index
25
+ * @param {GridStateColDef[]} columns List of columns to calculate colSpan for
27
26
  */
28
- calculateColSpan: (options: {
29
- rowId: GridRowId;
30
- minFirstColumn: number;
31
- maxLastColumn: number;
32
- columns: GridStateColDef[];
33
- }) => void;
27
+ calculateColSpan: (rowId: GridRowId, minFirstColumn: number, maxLastColumn: number, columns: GridStateColDef[]) => void;
34
28
  }
@@ -8,6 +8,7 @@ import type { GridVisibleRowsLookupState } from "../hooks/features/filter/gridFi
8
8
  import type { GridColumnResizeState } from "../hooks/features/columnResize/index.js";
9
9
  import type { GridRowSpanningState } from "../hooks/features/rows/useGridRowSpanning.js";
10
10
  import type { GridListViewState } from "../hooks/features/listView/useGridListView.js";
11
+ import type { GridRowReorderState } from "../hooks/features/rowReorder/gridRowReorderInterfaces.js";
11
12
  /**
12
13
  * Some props are passed on the state to enable grid selectors to select
13
14
  * and react to them.
@@ -41,6 +42,7 @@ export interface GridStateCommunity {
41
42
  columnResize: GridColumnResizeState;
42
43
  rowSpanning: GridRowSpanningState;
43
44
  listViewColumn: GridListViewState;
45
+ rowReorder: GridRowReorderState;
44
46
  }
45
47
  /**
46
48
  * The initial state of Data Grid.
@@ -196,6 +196,11 @@ export interface DataGridPropsWithDefaultValues<R extends GridValidRowModel = an
196
196
  * @default 150
197
197
  */
198
198
  filterDebounceMs: number;
199
+ /**
200
+ * The milliseconds delay to wait after a keystroke before triggering filtering in the columns menu.
201
+ * @default 150
202
+ */
203
+ columnFilterDebounceMs: number;
199
204
  /**
200
205
  * Sets the height in pixel of the column headers in the Data Grid.
201
206
  * @default 56
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mui/x-data-grid",
3
- "version": "8.9.1",
3
+ "version": "8.10.0",
4
4
  "author": "MUI Team",
5
5
  "description": "The Community plan edition of the MUI X Data Grid components.",
6
6
  "main": "./index.js",
@@ -17,8 +17,7 @@
17
17
  "url": "https://opencollective.com/mui-org"
18
18
  },
19
19
  "publishConfig": {
20
- "access": "public",
21
- "directory": "build"
20
+ "access": "public"
22
21
  },
23
22
  "keywords": [
24
23
  "react",
@@ -39,12 +38,13 @@
39
38
  "directory": "packages/x-data-grid"
40
39
  },
41
40
  "dependencies": {
42
- "@babel/runtime": "^7.27.6",
41
+ "@babel/runtime": "^7.28.2",
43
42
  "@mui/utils": "^7.2.0",
44
43
  "clsx": "^2.1.1",
45
44
  "prop-types": "^15.8.1",
46
45
  "use-sync-external-store": "^1.5.0",
47
- "@mui/x-internals": "8.8.0"
46
+ "@mui/x-internals": "8.10.0",
47
+ "@mui/x-virtualizer": "0.1.1"
48
48
  },
49
49
  "peerDependencies": {
50
50
  "@emotion/react": "^11.9.0",
@@ -66,7 +66,6 @@
66
66
  "node": ">=14.0.0"
67
67
  },
68
68
  "private": false,
69
- "module": "./esm/index.js",
70
69
  "exports": {
71
70
  "./package.json": "./package.json",
72
71
  ".": {
@@ -1 +1 @@
1
- export declare function roundToDecimalPlaces(value: number, decimals: number): number;
1
+ export { roundToDecimalPlaces } from '@mui/x-internals/math';
@@ -3,7 +3,10 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.roundToDecimalPlaces = roundToDecimalPlaces;
7
- function roundToDecimalPlaces(value, decimals) {
8
- return Math.round(value * 10 ** decimals) / 10 ** decimals;
9
- }
6
+ Object.defineProperty(exports, "roundToDecimalPlaces", {
7
+ enumerable: true,
8
+ get: function () {
9
+ return _math.roundToDecimalPlaces;
10
+ }
11
+ });
12
+ var _math = require("@mui/x-internals/math");
@@ -1,10 +0,0 @@
1
- import { GridStateCommunity } from "../../../models/gridStateCommunity.js";
2
- export declare const gridRowSpanningHiddenCellsSelector: (args_0: import("react").RefObject<{
3
- state: GridStateCommunity;
4
- } | null>) => Record<import("@mui/x-data-grid").GridRowId, Record<string, boolean>>;
5
- export declare const gridRowSpanningSpannedCellsSelector: (args_0: import("react").RefObject<{
6
- state: GridStateCommunity;
7
- } | null>) => Record<import("@mui/x-data-grid").GridRowId, Record<string, number>>;
8
- export declare const gridRowSpanningHiddenCellsOriginMapSelector: (args_0: import("react").RefObject<{
9
- state: GridStateCommunity;
10
- } | null>) => Record<number, Record<string, number>>;
@@ -1,5 +0,0 @@
1
- import { createSelector, createRootSelector } from "../../../utils/createSelector.js";
2
- const gridRowSpanningStateSelector = createRootSelector(state => state.rowSpanning);
3
- export const gridRowSpanningHiddenCellsSelector = createSelector(gridRowSpanningStateSelector, rowSpanning => rowSpanning.hiddenCells);
4
- export const gridRowSpanningSpannedCellsSelector = createSelector(gridRowSpanningStateSelector, rowSpanning => rowSpanning.spannedCells);
5
- export const gridRowSpanningHiddenCellsOriginMapSelector = createSelector(gridRowSpanningStateSelector, rowSpanning => rowSpanning.hiddenCellOriginMap);
@@ -1,56 +0,0 @@
1
- import * as React from 'react';
2
- import { GridPinnedRowsPosition } from "../rows/gridRowsInterfaces.js";
3
- import { type GridRenderContext, type GridColumnsRenderContext, type GridRowEntry, type GridRowId } from "../../../models/index.js";
4
- export type VirtualScroller = ReturnType<typeof useGridVirtualScroller>;
5
- export declare const EMPTY_DETAIL_PANELS: Readonly<Map<GridRowId, React.ReactNode>>;
6
- export declare const useGridVirtualScroller: () => {
7
- renderContext: GridRenderContext;
8
- setPanels: React.Dispatch<React.SetStateAction<Readonly<Map<GridRowId, React.ReactNode>>>>;
9
- getRows: (params?: {
10
- rows?: GridRowEntry[];
11
- position?: GridPinnedRowsPosition;
12
- renderContext?: GridRenderContext;
13
- }) => React.ReactNode[];
14
- getContainerProps: () => {
15
- ref: (node: HTMLDivElement | null) => (() => void) | undefined;
16
- };
17
- getScrollerProps: () => {
18
- ref: React.RefObject<HTMLDivElement | null>;
19
- onScroll: () => void;
20
- onWheel: (event: React.WheelEvent) => void;
21
- onTouchMove: (event: React.TouchEvent) => void;
22
- style: React.CSSProperties;
23
- role: string;
24
- tabIndex: number | undefined;
25
- };
26
- getContentProps: () => {
27
- style: React.CSSProperties;
28
- role: string;
29
- ref: (node: HTMLDivElement | null) => void;
30
- };
31
- getRenderZoneProps: () => {
32
- role: string;
33
- };
34
- getScrollbarVerticalProps: () => {
35
- ref: React.RefObject<HTMLDivElement | null>;
36
- scrollPosition: React.RefObject<{
37
- top: number;
38
- left: number;
39
- }>;
40
- };
41
- getScrollbarHorizontalProps: () => {
42
- ref: React.RefObject<HTMLDivElement | null>;
43
- scrollPosition: React.RefObject<{
44
- top: number;
45
- left: number;
46
- }>;
47
- };
48
- getScrollAreaProps: () => {
49
- scrollPosition: React.RefObject<{
50
- top: number;
51
- left: number;
52
- }>;
53
- };
54
- };
55
- export declare function areRenderContextsEqual(context1: GridRenderContext, context2: GridRenderContext): boolean;
56
- export declare function computeOffsetLeft(columnPositions: number[], renderContext: GridColumnsRenderContext, pinnedLeftLength: number): number;