@mui/x-data-grid 8.11.3 → 8.12.1

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 (154) hide show
  1. package/CHANGELOG.md +175 -6
  2. package/DataGrid/DataGrid.js +3 -1
  3. package/DataGrid/useDataGridComponent.js +2 -2
  4. package/colDef/gridActionsColDef.js +1 -0
  5. package/colDef/gridBooleanColDef.js +1 -0
  6. package/colDef/gridCheckboxSelectionColDef.js +1 -0
  7. package/colDef/gridStringColDef.js +1 -0
  8. package/components/cell/GridCell.js +7 -5
  9. package/constants/localeTextConstants.js +29 -0
  10. package/esm/DataGrid/DataGrid.js +3 -1
  11. package/esm/DataGrid/useDataGridComponent.js +2 -2
  12. package/esm/colDef/gridActionsColDef.js +1 -0
  13. package/esm/colDef/gridBooleanColDef.js +1 -0
  14. package/esm/colDef/gridCheckboxSelectionColDef.js +1 -0
  15. package/esm/colDef/gridStringColDef.js +1 -0
  16. package/esm/components/cell/GridCell.js +7 -5
  17. package/esm/constants/localeTextConstants.js +29 -0
  18. package/esm/hooks/features/columnResize/useGridColumnResize.js +2 -2
  19. package/esm/hooks/features/columns/useGridColumns.js +21 -4
  20. package/esm/hooks/features/filter/gridFilterSelector.d.ts +12 -4
  21. package/esm/hooks/features/filter/gridFilterSelector.js +21 -4
  22. package/esm/hooks/features/filter/gridFilterState.d.ts +3 -1
  23. package/esm/hooks/features/filter/gridFilterUtils.d.ts +3 -3
  24. package/esm/hooks/features/filter/gridFilterUtils.js +23 -13
  25. package/esm/hooks/features/filter/useGridFilter.d.ts +2 -1
  26. package/esm/hooks/features/filter/useGridFilter.js +7 -5
  27. package/esm/hooks/features/rows/gridRowsSelector.d.ts +3 -0
  28. package/esm/hooks/features/rows/gridRowsSelector.js +4 -0
  29. package/esm/hooks/features/rows/useGridParamsApi.js +16 -7
  30. package/esm/hooks/features/sorting/gridSortingUtils.d.ts +3 -1
  31. package/esm/hooks/features/sorting/gridSortingUtils.js +10 -4
  32. package/esm/hooks/features/sorting/useGridSorting.d.ts +2 -1
  33. package/esm/hooks/features/sorting/useGridSorting.js +4 -3
  34. package/esm/index.js +1 -1
  35. package/esm/internals/index.d.ts +1 -1
  36. package/esm/internals/index.js +1 -1
  37. package/esm/locales/arSD.js +31 -0
  38. package/esm/locales/beBY.js +31 -0
  39. package/esm/locales/bgBG.js +31 -0
  40. package/esm/locales/bnBD.js +31 -0
  41. package/esm/locales/csCZ.js +31 -0
  42. package/esm/locales/daDK.js +31 -0
  43. package/esm/locales/deDE.js +32 -0
  44. package/esm/locales/elGR.js +31 -0
  45. package/esm/locales/esES.js +31 -0
  46. package/esm/locales/faIR.js +31 -0
  47. package/esm/locales/fiFI.js +31 -0
  48. package/esm/locales/frFR.js +32 -2
  49. package/esm/locales/heIL.js +31 -0
  50. package/esm/locales/hrHR.js +31 -0
  51. package/esm/locales/huHU.js +31 -0
  52. package/esm/locales/hyAM.js +31 -0
  53. package/esm/locales/idID.d.ts +1 -1
  54. package/esm/locales/idID.js +32 -0
  55. package/esm/locales/isIS.js +31 -0
  56. package/esm/locales/itIT.js +31 -0
  57. package/esm/locales/jaJP.js +31 -0
  58. package/esm/locales/koKR.js +31 -0
  59. package/esm/locales/nbNO.js +31 -0
  60. package/esm/locales/nlNL.js +31 -0
  61. package/esm/locales/nnNO.js +32 -0
  62. package/esm/locales/plPL.js +31 -0
  63. package/esm/locales/ptBR.js +31 -0
  64. package/esm/locales/ptPT.js +31 -0
  65. package/esm/locales/roRO.js +31 -0
  66. package/esm/locales/ruRU.js +31 -0
  67. package/esm/locales/skSK.js +31 -0
  68. package/esm/locales/svSE.js +31 -0
  69. package/esm/locales/trTR.js +31 -0
  70. package/esm/locales/ukUA.js +31 -0
  71. package/esm/locales/urPK.js +31 -0
  72. package/esm/locales/viVN.js +31 -0
  73. package/esm/locales/zhCN.js +31 -0
  74. package/esm/locales/zhHK.js +31 -0
  75. package/esm/locales/zhTW.js +31 -0
  76. package/esm/material/augmentation.d.ts +8 -0
  77. package/esm/material/index.js +122 -24
  78. package/esm/models/api/gridLocaleTextApi.d.ts +27 -0
  79. package/esm/models/api/gridParamsApi.d.ts +5 -1
  80. package/esm/models/configuration/gridAggregationConfiguration.d.ts +25 -0
  81. package/esm/models/configuration/gridAggregationConfiguration.js +1 -0
  82. package/esm/models/configuration/gridConfiguration.d.ts +6 -9
  83. package/esm/models/gridBaseSlots.d.ts +15 -0
  84. package/esm/models/gridSlotsComponent.d.ts +10 -0
  85. package/esm/models/gridSlotsComponentsProps.d.ts +5 -1
  86. package/hooks/features/columnResize/useGridColumnResize.js +2 -2
  87. package/hooks/features/columns/useGridColumns.js +23 -6
  88. package/hooks/features/filter/gridFilterSelector.d.ts +12 -4
  89. package/hooks/features/filter/gridFilterSelector.js +22 -5
  90. package/hooks/features/filter/gridFilterState.d.ts +3 -1
  91. package/hooks/features/filter/gridFilterUtils.d.ts +3 -3
  92. package/hooks/features/filter/gridFilterUtils.js +23 -13
  93. package/hooks/features/filter/useGridFilter.d.ts +2 -1
  94. package/hooks/features/filter/useGridFilter.js +7 -5
  95. package/hooks/features/rows/gridRowsSelector.d.ts +3 -0
  96. package/hooks/features/rows/gridRowsSelector.js +4 -0
  97. package/hooks/features/rows/useGridParamsApi.js +16 -7
  98. package/hooks/features/sorting/gridSortingUtils.d.ts +3 -1
  99. package/hooks/features/sorting/gridSortingUtils.js +10 -4
  100. package/hooks/features/sorting/useGridSorting.d.ts +2 -1
  101. package/hooks/features/sorting/useGridSorting.js +4 -3
  102. package/index.js +1 -1
  103. package/internals/index.d.ts +1 -1
  104. package/internals/index.js +7 -0
  105. package/locales/arSD.js +31 -0
  106. package/locales/beBY.js +31 -0
  107. package/locales/bgBG.js +31 -0
  108. package/locales/bnBD.js +31 -0
  109. package/locales/csCZ.js +31 -0
  110. package/locales/daDK.js +31 -0
  111. package/locales/deDE.js +32 -0
  112. package/locales/elGR.js +31 -0
  113. package/locales/esES.js +31 -0
  114. package/locales/faIR.js +31 -0
  115. package/locales/fiFI.js +31 -0
  116. package/locales/frFR.js +32 -2
  117. package/locales/heIL.js +31 -0
  118. package/locales/hrHR.js +31 -0
  119. package/locales/huHU.js +31 -0
  120. package/locales/hyAM.js +31 -0
  121. package/locales/idID.d.ts +1 -1
  122. package/locales/idID.js +32 -0
  123. package/locales/isIS.js +31 -0
  124. package/locales/itIT.js +31 -0
  125. package/locales/jaJP.js +31 -0
  126. package/locales/koKR.js +31 -0
  127. package/locales/nbNO.js +31 -0
  128. package/locales/nlNL.js +31 -0
  129. package/locales/nnNO.js +32 -0
  130. package/locales/plPL.js +31 -0
  131. package/locales/ptBR.js +31 -0
  132. package/locales/ptPT.js +31 -0
  133. package/locales/roRO.js +31 -0
  134. package/locales/ruRU.js +31 -0
  135. package/locales/skSK.js +31 -0
  136. package/locales/svSE.js +31 -0
  137. package/locales/trTR.js +31 -0
  138. package/locales/ukUA.js +31 -0
  139. package/locales/urPK.js +31 -0
  140. package/locales/viVN.js +31 -0
  141. package/locales/zhCN.js +31 -0
  142. package/locales/zhHK.js +31 -0
  143. package/locales/zhTW.js +31 -0
  144. package/material/augmentation.d.ts +8 -0
  145. package/material/index.js +122 -24
  146. package/models/api/gridLocaleTextApi.d.ts +27 -0
  147. package/models/api/gridParamsApi.d.ts +5 -1
  148. package/models/configuration/gridAggregationConfiguration.d.ts +25 -0
  149. package/models/configuration/gridAggregationConfiguration.js +5 -0
  150. package/models/configuration/gridConfiguration.d.ts +6 -9
  151. package/models/gridBaseSlots.d.ts +15 -0
  152. package/models/gridSlotsComponent.d.ts +10 -0
  153. package/models/gridSlotsComponentsProps.d.ts +5 -1
  154. package/package.json +3 -3
@@ -107,16 +107,33 @@ export const gridExpandedSortedRowTreeLevelPositionLookupSelector = createSelect
107
107
  });
108
108
 
109
109
  /**
110
- * Get the id and the model of the top level rows accessible after the filtering process.
110
+ * Get the id and the model of the rows per depth level, accessible after the filtering process.
111
+ * Returns an array of arrays, where each array index contains the rows for the depth level equal to the index.
111
112
  * @category Filtering
112
113
  */
113
- export const gridFilteredSortedTopLevelRowEntriesSelector = createSelectorMemoized(gridExpandedSortedRowEntriesSelector, gridRowTreeSelector, gridRowMaximumTreeDepthSelector, (visibleSortedRows, rowTree, rowTreeDepth) => {
114
+ export const gridFilteredSortedDepthRowEntriesSelector = createSelectorMemoized(gridFilteredSortedRowEntriesSelector, gridRowTreeSelector, gridRowMaximumTreeDepthSelector, (sortedRows, rowTree, rowTreeDepth) => {
114
115
  if (rowTreeDepth < 2) {
115
- return visibleSortedRows;
116
+ return [sortedRows];
116
117
  }
117
- return visibleSortedRows.filter(row => rowTree[row.id]?.depth === 0);
118
+ return sortedRows.reduce((acc, row) => {
119
+ const depth = rowTree[row.id]?.depth;
120
+ if (depth === undefined) {
121
+ return acc;
122
+ }
123
+ if (!acc[depth]) {
124
+ acc[depth] = [];
125
+ }
126
+ acc[depth].push(row);
127
+ return acc;
128
+ }, [[]]);
118
129
  });
119
130
 
131
+ /**
132
+ * Get the id and the model of the top level rows accessible after the filtering process.
133
+ * @category Filtering
134
+ */
135
+ export const gridFilteredSortedTopLevelRowEntriesSelector = createSelector(gridFilteredSortedDepthRowEntriesSelector, filteredSortedDepthRows => filteredSortedDepthRows[0] ?? []);
136
+
120
137
  /**
121
138
  * Get the amount of rows accessible after the filtering process.
122
139
  * @category Filtering
@@ -1,6 +1,7 @@
1
1
  import { GridFilterItem } from "../../../models/gridFilterItem.js";
2
2
  import { GridFilterModel } from "../../../models/gridFilterModel.js";
3
- import { GridRowId, GridValidRowModel } from "../../../models/gridRows.js";
3
+ import { GridRowId, GridRowModel, GridValidRowModel } from "../../../models/gridRows.js";
4
+ import { GridColDef } from "../../../models/colDef/index.js";
4
5
  export type GridFilterItemResult = {
5
6
  [key: Required<GridFilterItem>['id']]: boolean;
6
7
  };
@@ -52,6 +53,7 @@ export type GridAggregatedFilterItemApplier = (row: GridValidRowModel, shouldApp
52
53
  export interface GridFilteringMethodParams {
53
54
  isRowMatchingFilters: GridAggregatedFilterItemApplier | null;
54
55
  filterModel: GridFilterModel;
56
+ filterValueGetter: (row: GridRowModel, column: GridColDef) => any;
55
57
  }
56
58
  export type GridFilteringMethodValue = Omit<GridFilterState, 'filterModel'>;
57
59
  /**
@@ -1,5 +1,5 @@
1
1
  import { RefObject } from '@mui/x-internals/types';
2
- import { GridFilterItem, GridFilterModel } from "../../../models/index.js";
2
+ import { GridColDef, GridFilterItem, GridFilterModel, GridRowModel } from "../../../models/index.js";
3
3
  import type { GridPrivateApiCommunity } from "../../../models/api/gridApiCommunity.js";
4
4
  import { GridStateCommunity } from "../../../models/gridStateCommunity.js";
5
5
  import { GridAggregatedFilterItemApplier, GridFilterItemResult, GridQuickFilterValueResult } from "./gridFilterState.js";
@@ -15,9 +15,9 @@ export declare const sanitizeFilterModel: (model: GridFilterModel, disableMultip
15
15
  export declare const mergeStateWithFilterModel: (filterModel: GridFilterModel, disableMultipleColumnsFiltering: boolean, apiRef: RefObject<GridPrivateApiCommunity>) => (filteringState: GridStateCommunity["filter"]) => GridStateCommunity["filter"];
16
16
  export declare const removeDiacritics: (value: unknown) => unknown;
17
17
  export declare const shouldQuickFilterExcludeHiddenColumns: (filterModel: GridFilterModel) => boolean;
18
- export declare const buildAggregatedFilterApplier: (filterModel: GridFilterModel, apiRef: RefObject<GridPrivateApiCommunity>, disableEval: boolean) => GridAggregatedFilterItemApplier;
18
+ export declare const buildAggregatedFilterApplier: (filterModel: GridFilterModel, filterValueGetter: (row: GridRowModel, column: GridColDef) => any, apiRef: RefObject<GridPrivateApiCommunity>, disableEval: boolean) => GridAggregatedFilterItemApplier;
19
19
  type FilterCache = {
20
20
  cleanedFilterItems?: GridFilterItem[];
21
21
  };
22
- export declare const passFilterLogic: (allFilterItemResults: (null | GridFilterItemResult)[], allQuickFilterResults: (null | GridQuickFilterValueResult)[], filterModel: GridFilterModel, apiRef: RefObject<GridPrivateApiCommunity>, cache: FilterCache) => boolean;
22
+ export declare const passFilterLogic: (allFilterItemResults: (null | GridFilterItemResult)[], allQuickFilterResults: (null | GridQuickFilterValueResult)[], filterModel: GridFilterModel, filterValueGetter: (row: GridRowModel, column: GridColDef) => any, apiRef: RefObject<GridPrivateApiCommunity>, cache: FilterCache) => boolean;
23
23
  export {};
@@ -81,7 +81,7 @@ export const removeDiacritics = value => {
81
81
  }
82
82
  return value;
83
83
  };
84
- const getFilterCallbackFromItem = (filterItem, apiRef) => {
84
+ const getFilterCallbackFromItem = (filterItem, filterValueGetter, apiRef) => {
85
85
  if (!filterItem.field || !filterItem.operator) {
86
86
  return null;
87
87
  }
@@ -121,7 +121,7 @@ const getFilterCallbackFromItem = (filterItem, apiRef) => {
121
121
  return {
122
122
  item: newFilterItem,
123
123
  fn: row => {
124
- let value = apiRef.current.getRowValue(row, column);
124
+ let value = filterValueGetter(row, column);
125
125
  if (ignoreDiacritics) {
126
126
  value = removeDiacritics(value);
127
127
  }
@@ -132,16 +132,21 @@ const getFilterCallbackFromItem = (filterItem, apiRef) => {
132
132
  let filterItemsApplierId = 1;
133
133
 
134
134
  /**
135
+ * @name filterValueGetter
136
+ * @param {GridRowModel} row The row to get the value from.
137
+ * @param {GridColDef} column The column that the filter is applied on.
138
+ *
135
139
  * Generates a method to easily check if a row is matching the current filter model.
136
140
  * @param {GridFilterModel} filterModel The model with which we want to filter the rows.
141
+ * @param {FilterValueGetterFn} filterValueGetter The function to get the value to filter by.
137
142
  * @param {RefObject<GridPrivateApiCommunity>} apiRef The API of the grid.
138
143
  * @returns {GridAggregatedFilterItemApplier | null} A method that checks if a row is matching the current filter model. If `null`, we consider that all the rows are matching the filters.
139
144
  */
140
- const buildAggregatedFilterItemsApplier = (filterModel, apiRef, disableEval) => {
145
+ const buildAggregatedFilterItemsApplier = (filterModel, filterValueGetter, apiRef, disableEval) => {
141
146
  const {
142
147
  items
143
148
  } = filterModel;
144
- const appliers = items.map(item => getFilterCallbackFromItem(item, apiRef)).filter(callback => !!callback);
149
+ const appliers = items.map(item => getFilterCallbackFromItem(item, filterValueGetter, apiRef)).filter(callback => !!callback);
145
150
  if (appliers.length === 0) {
146
151
  return null;
147
152
  }
@@ -181,12 +186,17 @@ export const shouldQuickFilterExcludeHiddenColumns = filterModel => {
181
186
  };
182
187
 
183
188
  /**
189
+ * @name filterValueGetter
190
+ * @param {GridRowModel} row The row to get the value from.
191
+ * @param {GridColDef} column The column that the filter is applied on.
192
+ *
184
193
  * Generates a method to easily check if a row is matching the current quick filter.
185
194
  * @param {any[]} filterModel The model with which we want to filter the rows.
195
+ * @param {FilterValueGetterFn} filterValueGetter The function to get the value to filter by.
186
196
  * @param {RefObject<GridPrivateApiCommunity>} apiRef The API of the grid.
187
197
  * @returns {GridAggregatedFilterItemApplier | null} A method that checks if a row is matching the current filter model. If `null`, we consider that all the rows are matching the filters.
188
198
  */
189
- const buildAggregatedQuickFilterApplier = (filterModel, apiRef) => {
199
+ const buildAggregatedQuickFilterApplier = (filterModel, filterValueGetter, apiRef) => {
190
200
  const quickFilterValues = filterModel.quickFilterValues?.filter(Boolean) ?? [];
191
201
  if (quickFilterValues.length === 0) {
192
202
  return null;
@@ -239,7 +249,7 @@ const buildAggregatedQuickFilterApplier = (filterModel, apiRef) => {
239
249
  continue;
240
250
  }
241
251
  const applier = appliers[v];
242
- let value = apiRef.current.getRowValue(row, column);
252
+ let value = filterValueGetter(row, column);
243
253
  if (applier.fn === null) {
244
254
  continue;
245
255
  }
@@ -257,23 +267,23 @@ const buildAggregatedQuickFilterApplier = (filterModel, apiRef) => {
257
267
  return result;
258
268
  };
259
269
  };
260
- export const buildAggregatedFilterApplier = (filterModel, apiRef, disableEval) => {
261
- const isRowMatchingFilterItems = buildAggregatedFilterItemsApplier(filterModel, apiRef, disableEval);
262
- const isRowMatchingQuickFilter = buildAggregatedQuickFilterApplier(filterModel, apiRef);
270
+ export const buildAggregatedFilterApplier = (filterModel, filterValueGetter, apiRef, disableEval) => {
271
+ const isRowMatchingFilterItems = buildAggregatedFilterItemsApplier(filterModel, filterValueGetter, apiRef, disableEval);
272
+ const isRowMatchingQuickFilter = buildAggregatedQuickFilterApplier(filterModel, filterValueGetter, apiRef);
263
273
  return function isRowMatchingFilters(row, shouldApplyFilter, result) {
264
274
  result.passingFilterItems = isRowMatchingFilterItems?.(row, shouldApplyFilter) ?? null;
265
275
  result.passingQuickFilterValues = isRowMatchingQuickFilter?.(row, shouldApplyFilter) ?? null;
266
276
  };
267
277
  };
268
278
  const isNotNull = result => result != null;
269
- const filterModelItems = (cache, apiRef, items) => {
279
+ const filterModelItems = (cache, filterValueGetter, apiRef, items) => {
270
280
  if (!cache.cleanedFilterItems) {
271
- cache.cleanedFilterItems = items.filter(item => getFilterCallbackFromItem(item, apiRef) !== null);
281
+ cache.cleanedFilterItems = items.filter(item => getFilterCallbackFromItem(item, filterValueGetter, apiRef) !== null);
272
282
  }
273
283
  return cache.cleanedFilterItems;
274
284
  };
275
- export const passFilterLogic = (allFilterItemResults, allQuickFilterResults, filterModel, apiRef, cache) => {
276
- const cleanedFilterItems = filterModelItems(cache, apiRef, filterModel.items);
285
+ export const passFilterLogic = (allFilterItemResults, allQuickFilterResults, filterModel, filterValueGetter, apiRef, cache) => {
286
+ const cleanedFilterItems = filterModelItems(cache, filterValueGetter, apiRef, filterModel.items);
277
287
  const cleanedFilterItemResults = allFilterItemResults.filter(isNotNull);
278
288
  const cleanedQuickFilterResults = allQuickFilterResults.filter(isNotNull);
279
289
 
@@ -2,10 +2,11 @@ import { RefObject } from '@mui/x-internals/types';
2
2
  import { DataGridProcessedProps } from "../../../models/props/DataGridProps.js";
3
3
  import { GridPrivateApiCommunity } from "../../../models/api/gridApiCommunity.js";
4
4
  import { GridStateInitializer } from "../../utils/useGridInitializeState.js";
5
+ import type { GridConfiguration } from "../../../models/configuration/gridConfiguration.js";
5
6
  export declare const filterStateInitializer: GridStateInitializer<Pick<DataGridProcessedProps, 'filterModel' | 'initialState' | 'disableMultipleColumnsFiltering'>>;
6
7
  /**
7
8
  * @requires useGridColumns (method, event)
8
9
  * @requires useGridParamsApi (method)
9
10
  * @requires useGridRows (event)
10
11
  */
11
- export declare const useGridFilter: (apiRef: RefObject<GridPrivateApiCommunity>, props: Pick<DataGridProcessedProps, "rows" | "initialState" | "filterModel" | "getRowId" | "onFilterModelChange" | "filterMode" | "disableMultipleColumnsFiltering" | "slots" | "slotProps" | "disableColumnFilter" | "disableEval" | "ignoreDiacritics">) => void;
12
+ export declare const useGridFilter: (apiRef: RefObject<GridPrivateApiCommunity>, props: Pick<DataGridProcessedProps, "rows" | "initialState" | "filterModel" | "getRowId" | "onFilterModelChange" | "filterMode" | "disableMultipleColumnsFiltering" | "slots" | "slotProps" | "disableColumnFilter" | "disableEval" | "ignoreDiacritics">, configuration: GridConfiguration) => void;
@@ -45,7 +45,7 @@ function createMemoizedValues() {
45
45
  * @requires useGridParamsApi (method)
46
46
  * @requires useGridRows (event)
47
47
  */
48
- export const useGridFilter = (apiRef, props) => {
48
+ export const useGridFilter = (apiRef, props, configuration) => {
49
49
  const logger = useGridLogger(apiRef, 'useGridFilter');
50
50
  apiRef.current.registerControlState({
51
51
  stateId: 'filter',
@@ -195,15 +195,17 @@ export const useGridFilter = (apiRef, props) => {
195
195
  }, [apiRef, logger, props.disableMultipleColumnsFiltering]);
196
196
  const getFilterState = React.useCallback(inputFilterModel => {
197
197
  const filterModel = sanitizeFilterModel(inputFilterModel, props.disableMultipleColumnsFiltering, apiRef);
198
- const isRowMatchingFilters = props.filterMode === 'client' ? buildAggregatedFilterApplier(filterModel, apiRef, props.disableEval) : null;
198
+ const filterValueGetter = configuration.hooks.useFilterValueGetter(apiRef, props);
199
+ const isRowMatchingFilters = props.filterMode === 'client' ? buildAggregatedFilterApplier(filterModel, filterValueGetter, apiRef, props.disableEval) : null;
199
200
  const filterResult = apiRef.current.applyStrategyProcessor('filtering', {
200
201
  isRowMatchingFilters,
201
- filterModel: filterModel ?? getDefaultGridFilterModel()
202
+ filterModel: filterModel ?? getDefaultGridFilterModel(),
203
+ filterValueGetter
202
204
  });
203
205
  return _extends({}, filterResult, {
204
206
  filterModel
205
207
  });
206
- }, [props.disableMultipleColumnsFiltering, props.filterMode, props.disableEval, apiRef]);
208
+ }, [apiRef, configuration.hooks, props]);
207
209
  const filterApi = {
208
210
  setFilterLogicOperator,
209
211
  unstable_applyFilters: updateFilteredRows,
@@ -287,7 +289,7 @@ export const useGridFilter = (apiRef, props) => {
287
289
  const row = rows[i];
288
290
  const id = getRowId ? getRowId(row) : row.id;
289
291
  isRowMatchingFilters(row, undefined, result);
290
- const isRowPassing = passFilterLogic([result.passingFilterItems], [result.passingQuickFilterValues], params.filterModel, apiRef, filterCache);
292
+ const isRowPassing = passFilterLogic([result.passingFilterItems], [result.passingQuickFilterValues], params.filterModel, params.filterValueGetter, apiRef, filterCache);
291
293
  if (!isRowPassing) {
292
294
  filteredRowsLookup[id] = isRowPassing;
293
295
  }
@@ -40,6 +40,9 @@ export declare const gridRowTreeDepthsSelector: (args_0: import("react").RefObje
40
40
  export declare const gridRowMaximumTreeDepthSelector: (args_0: import("react").RefObject<{
41
41
  state: GridStateCommunity;
42
42
  } | null>) => number;
43
+ /**
44
+ * @category Rows
45
+ */
43
46
  export declare const gridDataRowIdsSelector: (args_0: import("react").RefObject<{
44
47
  state: GridStateCommunity;
45
48
  } | null>) => GridRowId[];
@@ -27,6 +27,10 @@ export const gridRowMaximumTreeDepthSelector = createSelectorMemoized(gridRowsSt
27
27
  }
28
28
  return (entries.filter(([, nodeCount]) => nodeCount > 0).map(([depth]) => Number(depth)).sort((a, b) => b - a)[0] ?? 0) + 1;
29
29
  });
30
+
31
+ /**
32
+ * @category Rows
33
+ */
30
34
  export const gridDataRowIdsSelector = createSelector(gridRowsStateSelector, rows => rows.dataRowIds);
31
35
  export const gridDataRowsSelector = createSelectorMemoized(gridDataRowIdsSelector, gridRowsLookupSelector, (dataRowIds, rowsLookup) => dataRowIds.reduce((acc, id) => {
32
36
  if (!rowsLookup[id]) {
@@ -37,10 +37,22 @@ export function useGridParamsApi(apiRef, props) {
37
37
  colDef,
38
38
  hasFocus,
39
39
  rowNode,
40
- tabIndex
40
+ tabIndex,
41
+ value: forcedValue,
42
+ formattedValue: forcedFormattedValue
41
43
  }) => {
42
- const rawValue = row[field];
43
- const value = colDef?.valueGetter ? colDef.valueGetter(rawValue, row, colDef, apiRef) : rawValue;
44
+ let value = row[field];
45
+ if (forcedValue !== undefined) {
46
+ value = forcedValue;
47
+ } else if (colDef?.valueGetter) {
48
+ value = colDef.valueGetter(value, row, colDef, apiRef);
49
+ }
50
+ let formattedValue = value;
51
+ if (forcedFormattedValue !== undefined) {
52
+ formattedValue = forcedFormattedValue;
53
+ } else if (colDef?.valueFormatter) {
54
+ formattedValue = colDef.valueFormatter(value, row, colDef, apiRef);
55
+ }
44
56
  const params = {
45
57
  id,
46
58
  field,
@@ -51,13 +63,10 @@ export function useGridParamsApi(apiRef, props) {
51
63
  hasFocus,
52
64
  tabIndex,
53
65
  value,
54
- formattedValue: value,
66
+ formattedValue,
55
67
  isEditable: false,
56
68
  api: apiRef.current
57
69
  };
58
- if (colDef && colDef.valueFormatter) {
59
- params.formattedValue = colDef.valueFormatter(value, row, colDef, apiRef);
60
- }
61
70
  params.isEditable = colDef && apiRef.current.isCellEditable(params);
62
71
  return params;
63
72
  }, [apiRef]);
@@ -1,5 +1,6 @@
1
1
  import { RefObject } from '@mui/x-internals/types';
2
2
  import { GridSortingModelApplier } from "./gridSortingState.js";
3
+ import type { GridRowId } from "../../../models/index.js";
3
4
  import { GridApiCommunity } from "../../../models/api/gridApiCommunity.js";
4
5
  import { GridStateCommunity } from "../../../models/gridStateCommunity.js";
5
6
  import { GridComparatorFn, GridSortDirection, GridSortModel } from "../../../models/gridSortModel.js";
@@ -8,10 +9,11 @@ export declare const mergeStateWithSortModel: (sortModel: GridSortModel, disable
8
9
  /**
9
10
  * Generates a method to easily sort a list of rows according to the current sort model.
10
11
  * @param {GridSortModel} sortModel The model with which we want to sort the rows.
12
+ * @param {Function} sortValueGetter A function to get the value to sort by.
11
13
  * @param {RefObject<GridApiCommunity>} apiRef The API of the grid.
12
14
  * @returns {GridSortingModelApplier | null} A method that generates a list of sorted row ids from a list of rows according to the current sort model. If `null`, we consider that the rows should remain in the order there were provided.
13
15
  */
14
- export declare const buildAggregatedSortingApplier: (sortModel: GridSortModel, apiRef: RefObject<GridApiCommunity>) => GridSortingModelApplier | null;
16
+ export declare const buildAggregatedSortingApplier: (sortModel: GridSortModel, sortValueGetter: (id: GridRowId, field: string) => any, apiRef: RefObject<GridApiCommunity>) => GridSortingModelApplier | null;
15
17
  export declare const getNextGridSortDirection: (sortingOrder: readonly GridSortDirection[], current?: GridSortDirection) => GridSortDirection;
16
18
  export declare const gridStringOrNumberComparator: GridComparatorFn;
17
19
  export declare const gridNumberComparator: GridComparatorFn;
@@ -18,12 +18,17 @@ export const mergeStateWithSortModel = (sortModel, disableMultipleColumnsSorting
18
18
  const isDesc = direction => direction === 'desc';
19
19
 
20
20
  /**
21
+ * @name sortValueGetter
22
+ * @param {GridRowId} id The id of the row.
23
+ * @param {string} field The field to sort by.
24
+ *
21
25
  * Transform an item of the sorting model into a method comparing two rows.
22
26
  * @param {GridSortItem} sortItem The sort item we want to apply.
27
+ * @param {Function} sortValueGetter A function to get the value to sort by.
23
28
  * @param {RefObject<GridApiCommunity>} apiRef The API of the grid.
24
29
  * @returns {GridParsedSortItem | null} The parsed sort item. Returns `null` is the sort item is not valid.
25
30
  */
26
- const parseSortItem = (sortItem, apiRef) => {
31
+ const parseSortItem = (sortItem, sortValueGetter, apiRef) => {
27
32
  const column = apiRef.current.getColumn(sortItem.field);
28
33
  if (!column || sortItem.sort === null) {
29
34
  return null;
@@ -41,7 +46,7 @@ const parseSortItem = (sortItem, apiRef) => {
41
46
  id,
42
47
  field: column.field,
43
48
  rowNode: gridRowNodeSelector(apiRef, id),
44
- value: apiRef.current.getCellValue(id, column.field),
49
+ value: sortValueGetter(id, column.field),
45
50
  api: apiRef.current
46
51
  });
47
52
  return {
@@ -73,11 +78,12 @@ const compareRows = (parsedSortItems, row1, row2) => {
73
78
  /**
74
79
  * Generates a method to easily sort a list of rows according to the current sort model.
75
80
  * @param {GridSortModel} sortModel The model with which we want to sort the rows.
81
+ * @param {Function} sortValueGetter A function to get the value to sort by.
76
82
  * @param {RefObject<GridApiCommunity>} apiRef The API of the grid.
77
83
  * @returns {GridSortingModelApplier | null} A method that generates a list of sorted row ids from a list of rows according to the current sort model. If `null`, we consider that the rows should remain in the order there were provided.
78
84
  */
79
- export const buildAggregatedSortingApplier = (sortModel, apiRef) => {
80
- const comparatorList = sortModel.map(item => parseSortItem(item, apiRef)).filter(comparator => !!comparator);
85
+ export const buildAggregatedSortingApplier = (sortModel, sortValueGetter, apiRef) => {
86
+ const comparatorList = sortModel.map(item => parseSortItem(item, sortValueGetter, apiRef)).filter(comparator => !!comparator);
81
87
  if (comparatorList.length === 0) {
82
88
  return null;
83
89
  }
@@ -2,9 +2,10 @@ import { RefObject } from '@mui/x-internals/types';
2
2
  import { DataGridProcessedProps } from "../../../models/props/DataGridProps.js";
3
3
  import { GridPrivateApiCommunity } from "../../../models/api/gridApiCommunity.js";
4
4
  import { GridStateInitializer } from "../../utils/useGridInitializeState.js";
5
+ import type { GridConfiguration } from "../../../models/configuration/gridConfiguration.js";
5
6
  export declare const sortingStateInitializer: GridStateInitializer<Pick<DataGridProcessedProps, 'sortModel' | 'initialState' | 'disableMultipleColumnsSorting'>>;
6
7
  /**
7
8
  * @requires useGridRows (event)
8
9
  * @requires useGridColumns (event)
9
10
  */
10
- export declare const useGridSorting: (apiRef: RefObject<GridPrivateApiCommunity>, props: Pick<DataGridProcessedProps, "initialState" | "sortModel" | "onSortModelChange" | "sortingOrder" | "sortingMode" | "disableColumnSorting" | "disableMultipleColumnsSorting" | "multipleColumnsSortingMode">) => void;
11
+ export declare const useGridSorting: (apiRef: RefObject<GridPrivateApiCommunity>, props: Pick<DataGridProcessedProps, "initialState" | "sortModel" | "onSortModelChange" | "sortingOrder" | "sortingMode" | "disableColumnSorting" | "disableMultipleColumnsSorting" | "multipleColumnsSortingMode">, configuration: GridConfiguration) => void;
@@ -26,7 +26,7 @@ export const sortingStateInitializer = (state, props) => {
26
26
  * @requires useGridRows (event)
27
27
  * @requires useGridColumns (event)
28
28
  */
29
- export const useGridSorting = (apiRef, props) => {
29
+ export const useGridSorting = (apiRef, props, configuration) => {
30
30
  const logger = useGridLogger(apiRef, 'useGridSorting');
31
31
  apiRef.current.registerControlState({
32
32
  stateId: 'sortModel',
@@ -79,6 +79,7 @@ export const useGridSorting = (apiRef, props) => {
79
79
  * API METHODS
80
80
  */
81
81
  const applySorting = React.useCallback(() => {
82
+ const sortValueGetter = configuration.hooks.useSortValueGetter(apiRef);
82
83
  apiRef.current.setState(state => {
83
84
  if (props.sortingMode === 'server') {
84
85
  logger.debug('Skipping sorting rows as sortingMode = server');
@@ -89,7 +90,7 @@ export const useGridSorting = (apiRef, props) => {
89
90
  });
90
91
  }
91
92
  const sortModel = gridSortModelSelector(apiRef);
92
- const sortRowList = buildAggregatedSortingApplier(sortModel, apiRef);
93
+ const sortRowList = buildAggregatedSortingApplier(sortModel, sortValueGetter, apiRef);
93
94
  const sortedRows = apiRef.current.applyStrategyProcessor('sorting', {
94
95
  sortRowList
95
96
  });
@@ -100,7 +101,7 @@ export const useGridSorting = (apiRef, props) => {
100
101
  });
101
102
  });
102
103
  apiRef.current.publishEvent('sortedRowsSet');
103
- }, [apiRef, logger, props.sortingMode]);
104
+ }, [apiRef, logger, configuration, props.sortingMode]);
104
105
  const setSortModel = React.useCallback(model => {
105
106
  const currentModel = gridSortModelSelector(apiRef);
106
107
  if (currentModel !== model) {
package/esm/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid v8.11.3
2
+ * @mui/x-data-grid v8.12.1
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -41,7 +41,7 @@ export { useGridPrintExport } from "../hooks/features/export/useGridPrintExport.
41
41
  export { useGridFilter, filterStateInitializer } from "../hooks/features/filter/useGridFilter.js";
42
42
  export { defaultGridFilterLookup } from "../hooks/features/filter/gridFilterState.js";
43
43
  export { passFilterLogic } from "../hooks/features/filter/gridFilterUtils.js";
44
- export { gridFilteredChildrenCountLookupSelector, gridExpandedSortedRowTreeLevelPositionLookupSelector, gridExpandedSortedRowIndexLookupSelector } from "../hooks/features/filter/gridFilterSelector.js";
44
+ export { gridFilteredChildrenCountLookupSelector, gridExpandedSortedRowTreeLevelPositionLookupSelector, gridExpandedSortedRowIndexLookupSelector, gridFilteredSortedDepthRowEntriesSelector } from "../hooks/features/filter/gridFilterSelector.js";
45
45
  export { isSingleSelectColDef } from "../components/panel/filterPanel/filterPanelUtils.js";
46
46
  export type { GridAggregatedFilterItemApplier, GridAggregatedFilterItemApplierResult } from "../hooks/features/filter/gridFilterState.js";
47
47
  export { useGridFocus, focusStateInitializer } from "../hooks/features/focus/useGridFocus.js";
@@ -31,7 +31,7 @@ export { useGridPrintExport } from "../hooks/features/export/useGridPrintExport.
31
31
  export { useGridFilter, filterStateInitializer } from "../hooks/features/filter/useGridFilter.js";
32
32
  export { defaultGridFilterLookup } from "../hooks/features/filter/gridFilterState.js";
33
33
  export { passFilterLogic } from "../hooks/features/filter/gridFilterUtils.js";
34
- export { gridFilteredChildrenCountLookupSelector, gridExpandedSortedRowTreeLevelPositionLookupSelector, gridExpandedSortedRowIndexLookupSelector } from "../hooks/features/filter/gridFilterSelector.js";
34
+ export { gridFilteredChildrenCountLookupSelector, gridExpandedSortedRowTreeLevelPositionLookupSelector, gridExpandedSortedRowIndexLookupSelector, gridFilteredSortedDepthRowEntriesSelector } from "../hooks/features/filter/gridFilterSelector.js";
35
35
  export { isSingleSelectColDef } from "../components/panel/filterPanel/filterPanelUtils.js";
36
36
  export { useGridFocus, focusStateInitializer } from "../hooks/features/focus/useGridFocus.js";
37
37
  export { useGridKeyboardNavigation } from "../hooks/features/keyboardNavigation/useGridKeyboardNavigation.js";
@@ -35,6 +35,9 @@ const arSDGrid = {
35
35
  // Toolbar pivot button
36
36
  // toolbarPivot: 'Pivot',
37
37
 
38
+ // Toolbar charts button
39
+ // toolbarCharts: 'Charts',
40
+
38
41
  // Toolbar AI Assistant button
39
42
  // toolbarAssistant: 'AI Assistant',
40
43
 
@@ -116,6 +119,7 @@ const arSDGrid = {
116
119
  columnMenuSortAsc: 'الفرز تصاعدياً',
117
120
  columnMenuSortDesc: 'الفرز تنازلياً',
118
121
  // columnMenuManagePivot: 'Manage pivot',
122
+ // columnMenuManageCharts: 'Manage charts',
119
123
 
120
124
  // Column header text
121
125
  columnHeaderFiltersTooltipActive: count => count !== 1 ? `${count} من المرشِحات النشطة` : `مرشِح نشط`,
@@ -185,6 +189,7 @@ const arSDGrid = {
185
189
  rowReorderingHeaderName: 'أعادة ترتيب الصفوف',
186
190
  // Aggregation
187
191
  aggregationMenuItemHeader: 'الدلالات الحسابية',
192
+ // aggregationFunctionLabelNone: 'none',
188
193
  aggregationFunctionLabelSum: 'مجموع',
189
194
  aggregationFunctionLabelAvg: 'معدل',
190
195
  aggregationFunctionLabelMin: 'الحد الادنى',
@@ -220,6 +225,32 @@ const arSDGrid = {
220
225
  // pivotYearColumnHeaderName: '(Year)',
221
226
  // pivotQuarterColumnHeaderName: '(Quarter)',
222
227
 
228
+ // Charts configuration panel
229
+ // chartsNoCharts: 'There are no charts available',
230
+ // chartsChartNotSelected: 'Select a chart type to configure its options',
231
+ // chartsTabChart: 'Chart',
232
+ // chartsTabFields: 'Fields',
233
+ // chartsTabCustomize: 'Customize',
234
+ // chartsCloseButton: 'Close charts configuration',
235
+ // chartsSyncButtonLabel: 'Sync chart',
236
+ // chartsSearchPlaceholder: 'Search fields',
237
+ // chartsSearchLabel: 'Search fields',
238
+ // chartsSearchClear: 'Clear search',
239
+ // chartsNoFields: 'No fields',
240
+ // chartsFieldBlocked: 'This field cannot be added to any section',
241
+ // chartsCategories: 'Categories',
242
+ // chartsSeries: 'Series',
243
+ // chartsMenuAddToDimensions: (dimensionLabel: string) => `Add to ${dimensionLabel}`,
244
+ // chartsMenuAddToValues: (valuesLabel: string) => `Add to ${valuesLabel}`,
245
+ // chartsMenuMoveUp: 'Move up',
246
+ // chartsMenuMoveDown: 'Move down',
247
+ // chartsMenuMoveToTop: 'Move to top',
248
+ // chartsMenuMoveToBottom: 'Move to bottom',
249
+ // chartsMenuOptions: 'Field options',
250
+ // chartsMenuRemove: 'Remove',
251
+ // chartsDragToDimensions: (dimensionLabel: string) => `Drag here to use column as ${dimensionLabel}`,
252
+ // chartsDragToValues: (valuesLabel: string) => `Drag here to use column as ${valuesLabel}`,
253
+
223
254
  // AI Assistant panel
224
255
  // aiAssistantPanelTitle: 'AI Assistant',
225
256
  // aiAssistantPanelClose: 'Close AI Assistant',
@@ -49,6 +49,9 @@ const beBYGrid = {
49
49
  // Toolbar pivot button
50
50
  // toolbarPivot: 'Pivot',
51
51
 
52
+ // Toolbar charts button
53
+ // toolbarCharts: 'Charts',
54
+
52
55
  // Toolbar AI Assistant button
53
56
  // toolbarAssistant: 'AI Assistant',
54
57
 
@@ -132,6 +135,7 @@ const beBYGrid = {
132
135
  columnMenuSortAsc: 'Сартыраваць па нарастанню',
133
136
  columnMenuSortDesc: 'Сартыраваць па спаданню',
134
137
  // columnMenuManagePivot: 'Manage pivot',
138
+ // columnMenuManageCharts: 'Manage charts',
135
139
 
136
140
  // Column header text
137
141
  columnHeaderFiltersTooltipActive: count => getPluralForm(count, {
@@ -209,6 +213,7 @@ const beBYGrid = {
209
213
  rowReorderingHeaderName: 'Змяненне чарговасці радкоў',
210
214
  // Aggregation
211
215
  aggregationMenuItemHeader: "Аб'яднанне дадзеных",
216
+ // aggregationFunctionLabelNone: 'none',
212
217
  aggregationFunctionLabelSum: 'сума',
213
218
  aggregationFunctionLabelAvg: 'сярэдняе',
214
219
  aggregationFunctionLabelMin: 'мінімум',
@@ -244,6 +249,32 @@ const beBYGrid = {
244
249
  // pivotYearColumnHeaderName: '(Year)',
245
250
  // pivotQuarterColumnHeaderName: '(Quarter)',
246
251
 
252
+ // Charts configuration panel
253
+ // chartsNoCharts: 'There are no charts available',
254
+ // chartsChartNotSelected: 'Select a chart type to configure its options',
255
+ // chartsTabChart: 'Chart',
256
+ // chartsTabFields: 'Fields',
257
+ // chartsTabCustomize: 'Customize',
258
+ // chartsCloseButton: 'Close charts configuration',
259
+ // chartsSyncButtonLabel: 'Sync chart',
260
+ // chartsSearchPlaceholder: 'Search fields',
261
+ // chartsSearchLabel: 'Search fields',
262
+ // chartsSearchClear: 'Clear search',
263
+ // chartsNoFields: 'No fields',
264
+ // chartsFieldBlocked: 'This field cannot be added to any section',
265
+ // chartsCategories: 'Categories',
266
+ // chartsSeries: 'Series',
267
+ // chartsMenuAddToDimensions: (dimensionLabel: string) => `Add to ${dimensionLabel}`,
268
+ // chartsMenuAddToValues: (valuesLabel: string) => `Add to ${valuesLabel}`,
269
+ // chartsMenuMoveUp: 'Move up',
270
+ // chartsMenuMoveDown: 'Move down',
271
+ // chartsMenuMoveToTop: 'Move to top',
272
+ // chartsMenuMoveToBottom: 'Move to bottom',
273
+ // chartsMenuOptions: 'Field options',
274
+ // chartsMenuRemove: 'Remove',
275
+ // chartsDragToDimensions: (dimensionLabel: string) => `Drag here to use column as ${dimensionLabel}`,
276
+ // chartsDragToValues: (valuesLabel: string) => `Drag here to use column as ${valuesLabel}`,
277
+
247
278
  // AI Assistant panel
248
279
  // aiAssistantPanelTitle: 'AI Assistant',
249
280
  // aiAssistantPanelClose: 'Close AI Assistant',
@@ -35,6 +35,9 @@ const bgBGGrid = {
35
35
  // Toolbar pivot button
36
36
  // toolbarPivot: 'Pivot',
37
37
 
38
+ // Toolbar charts button
39
+ // toolbarCharts: 'Charts',
40
+
38
41
  // Toolbar AI Assistant button
39
42
  // toolbarAssistant: 'AI Assistant',
40
43
 
@@ -117,6 +120,7 @@ const bgBGGrid = {
117
120
  columnMenuSortAsc: 'Сортирай по възходящ ред',
118
121
  columnMenuSortDesc: 'Сортирай по низходящ ред',
119
122
  // columnMenuManagePivot: 'Manage pivot',
123
+ // columnMenuManageCharts: 'Manage charts',
120
124
 
121
125
  // Column header text
122
126
  columnHeaderFiltersTooltipActive: count => `${count} активни филтри`,
@@ -186,6 +190,7 @@ const bgBGGrid = {
186
190
  rowReorderingHeaderName: 'Подредба на редове',
187
191
  // Aggregation
188
192
  aggregationMenuItemHeader: 'Агрегиране',
193
+ // aggregationFunctionLabelNone: 'none',
189
194
  aggregationFunctionLabelSum: 'сума',
190
195
  aggregationFunctionLabelAvg: 'срст',
191
196
  aggregationFunctionLabelMin: 'мин',
@@ -221,6 +226,32 @@ const bgBGGrid = {
221
226
  // pivotYearColumnHeaderName: '(Year)',
222
227
  // pivotQuarterColumnHeaderName: '(Quarter)',
223
228
 
229
+ // Charts configuration panel
230
+ // chartsNoCharts: 'There are no charts available',
231
+ // chartsChartNotSelected: 'Select a chart type to configure its options',
232
+ // chartsTabChart: 'Chart',
233
+ // chartsTabFields: 'Fields',
234
+ // chartsTabCustomize: 'Customize',
235
+ // chartsCloseButton: 'Close charts configuration',
236
+ // chartsSyncButtonLabel: 'Sync chart',
237
+ // chartsSearchPlaceholder: 'Search fields',
238
+ // chartsSearchLabel: 'Search fields',
239
+ // chartsSearchClear: 'Clear search',
240
+ // chartsNoFields: 'No fields',
241
+ // chartsFieldBlocked: 'This field cannot be added to any section',
242
+ // chartsCategories: 'Categories',
243
+ // chartsSeries: 'Series',
244
+ // chartsMenuAddToDimensions: (dimensionLabel: string) => `Add to ${dimensionLabel}`,
245
+ // chartsMenuAddToValues: (valuesLabel: string) => `Add to ${valuesLabel}`,
246
+ // chartsMenuMoveUp: 'Move up',
247
+ // chartsMenuMoveDown: 'Move down',
248
+ // chartsMenuMoveToTop: 'Move to top',
249
+ // chartsMenuMoveToBottom: 'Move to bottom',
250
+ // chartsMenuOptions: 'Field options',
251
+ // chartsMenuRemove: 'Remove',
252
+ // chartsDragToDimensions: (dimensionLabel: string) => `Drag here to use column as ${dimensionLabel}`,
253
+ // chartsDragToValues: (valuesLabel: string) => `Drag here to use column as ${valuesLabel}`,
254
+
224
255
  // AI Assistant panel
225
256
  // aiAssistantPanelTitle: 'AI Assistant',
226
257
  // aiAssistantPanelClose: 'Close AI Assistant',