@mui/x-data-grid 7.23.6 → 7.24.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.
- package/CHANGELOG.md +150 -0
- package/DataGrid/DataGrid.js +4 -5
- package/DataGrid/useDataGridComponent.d.ts +2 -1
- package/DataGrid/useDataGridComponent.js +1 -1
- package/components/GridHeaders.js +2 -2
- package/components/GridRow.d.ts +5 -9
- package/components/GridRow.js +28 -105
- package/components/GridSkeletonLoadingOverlay.js +18 -18
- package/components/cell/GridCell.d.ts +9 -16
- package/components/cell/GridCell.js +17 -35
- package/components/columnHeaders/GridColumnGroupHeader.d.ts +5 -5
- package/components/columnHeaders/GridColumnGroupHeader.js +7 -10
- package/components/columnHeaders/GridColumnHeaderFilterIconButton.d.ts +3 -3
- package/components/columnHeaders/GridColumnHeaderFilterIconButton.js +21 -7
- package/components/columnHeaders/GridColumnHeaderItem.d.ts +5 -5
- package/components/columnHeaders/GridColumnHeaderItem.js +13 -12
- package/components/columnSelection/GridCellCheckboxRenderer.js +2 -2
- package/components/containers/GridRoot.d.ts +2 -2
- package/components/containers/GridRoot.js +14 -6
- package/components/containers/GridRootStyles.js +1 -0
- package/components/panel/GridPanel.js +2 -1
- package/components/panel/filterPanel/GridFilterInputValueProps.d.ts +2 -1
- package/components/toolbar/GridToolbarColumnsButton.js +6 -1
- package/components/toolbar/GridToolbarFilterButton.js +6 -1
- package/components/virtualization/GridVirtualScrollbar.js +11 -12
- package/components/virtualization/GridVirtualScroller.js +4 -4
- package/context/GridContextProvider.d.ts +2 -1
- package/hooks/core/pipeProcessing/useGridPipeProcessing.d.ts +2 -2
- package/hooks/core/pipeProcessing/useGridRegisterPipeApplier.d.ts +2 -2
- package/hooks/core/pipeProcessing/useGridRegisterPipeProcessor.d.ts +2 -2
- package/hooks/core/strategyProcessing/useGridRegisterStrategyProcessor.d.ts +2 -2
- package/hooks/core/strategyProcessing/useGridStrategyProcessing.d.ts +2 -2
- package/hooks/core/useGridApiInitialization.d.ts +2 -2
- package/hooks/core/useGridInitialization.d.ts +2 -2
- package/hooks/core/useGridIsRtl.d.ts +2 -2
- package/hooks/core/useGridLocaleText.d.ts +2 -2
- package/hooks/core/useGridLoggerFactory.d.ts +2 -2
- package/hooks/core/useGridRefs.d.ts +2 -2
- package/hooks/core/useGridStateInitialization.d.ts +2 -2
- package/hooks/features/clipboard/useGridClipboard.d.ts +2 -2
- package/hooks/features/columnGrouping/useGridColumnGrouping.d.ts +2 -2
- package/hooks/features/columnHeaders/useGridColumnHeaders.d.ts +5 -7
- package/hooks/features/columnHeaders/useGridColumnHeaders.js +34 -76
- package/hooks/features/columnMenu/useGridColumnMenu.d.ts +2 -2
- package/hooks/features/columnMenu/useGridColumnMenu.js +0 -2
- package/hooks/features/columnResize/useGridColumnResize.d.ts +2 -2
- package/hooks/features/columnResize/useGridColumnResize.js +4 -2
- package/hooks/features/columns/gridColumnsUtils.d.ts +4 -4
- package/hooks/features/columns/useGridColumnSpanning.d.ts +2 -2
- package/hooks/features/columns/useGridColumns.d.ts +2 -2
- package/hooks/features/density/useGridDensity.d.ts +2 -2
- package/hooks/features/dimensions/useGridDimensions.d.ts +2 -2
- package/hooks/features/dimensions/useGridDimensions.js +1 -3
- package/hooks/features/editing/useGridCellEditing.d.ts +2 -2
- package/hooks/features/editing/useGridEditing.d.ts +2 -2
- package/hooks/features/editing/useGridRowEditing.d.ts +2 -2
- package/hooks/features/events/useGridEvents.d.ts +2 -2
- package/hooks/features/export/serializers/csvSerializer.d.ts +2 -1
- package/hooks/features/export/useGridCsvExport.d.ts +2 -2
- package/hooks/features/export/useGridPrintExport.d.ts +2 -2
- package/hooks/features/export/utils.d.ts +2 -2
- package/hooks/features/filter/gridFilterSelector.js +6 -1
- package/hooks/features/filter/gridFilterUtils.d.ts +7 -7
- package/hooks/features/filter/gridFilterUtils.js +3 -3
- package/hooks/features/filter/useGridFilter.d.ts +2 -2
- package/hooks/features/focus/useGridFocus.d.ts +2 -2
- package/hooks/features/headerFiltering/useGridHeaderFiltering.d.ts +2 -2
- package/hooks/features/keyboardNavigation/useGridKeyboardNavigation.d.ts +2 -2
- package/hooks/features/keyboardNavigation/utils.d.ts +3 -3
- package/hooks/features/listView/useGridListView.d.ts +2 -2
- package/hooks/features/pagination/gridPaginationInterfaces.d.ts +3 -0
- package/hooks/features/pagination/gridPaginationSelector.d.ts +20 -1
- package/hooks/features/pagination/gridPaginationSelector.js +39 -1
- package/hooks/features/pagination/useGridPagination.d.ts +3 -3
- package/hooks/features/pagination/useGridPagination.js +5 -3
- package/hooks/features/pagination/useGridPaginationMeta.d.ts +2 -2
- package/hooks/features/pagination/useGridPaginationModel.d.ts +2 -2
- package/hooks/features/pagination/useGridPaginationModel.js +23 -1
- package/hooks/features/pagination/useGridRowCount.d.ts +2 -2
- package/hooks/features/preferencesPanel/gridPreferencePanelSelector.d.ts +1 -0
- package/hooks/features/preferencesPanel/gridPreferencePanelSelector.js +8 -1
- package/hooks/features/preferencesPanel/index.d.ts +1 -1
- package/hooks/features/preferencesPanel/index.js +1 -1
- package/hooks/features/preferencesPanel/useGridPreferencesPanel.d.ts +2 -2
- package/hooks/features/preferencesPanel/useGridPreferencesPanel.js +14 -38
- package/hooks/features/rowSelection/useGridRowSelection.d.ts +2 -2
- package/hooks/features/rowSelection/useGridRowSelectionPreProcessors.d.ts +2 -2
- package/hooks/features/rowSelection/utils.d.ts +3 -2
- package/hooks/features/rows/gridRowSpanningUtils.d.ts +2 -2
- package/hooks/features/rows/gridRowsSelector.js +1 -1
- package/hooks/features/rows/gridRowsUtils.d.ts +4 -4
- package/hooks/features/rows/useGridParamsApi.d.ts +2 -2
- package/hooks/features/rows/useGridRowSpanning.d.ts +2 -2
- package/hooks/features/rows/useGridRows.d.ts +2 -2
- package/hooks/features/rows/useGridRows.js +2 -2
- package/hooks/features/rows/useGridRowsMeta.d.ts +2 -2
- package/hooks/features/rows/useGridRowsPreProcessors.d.ts +2 -2
- package/hooks/features/scroll/useGridScroll.d.ts +2 -2
- package/hooks/features/sorting/gridSortingUtils.d.ts +3 -3
- package/hooks/features/sorting/gridSortingUtils.js +2 -2
- package/hooks/features/sorting/useGridSorting.d.ts +2 -2
- package/hooks/features/statePersistence/useGridStatePersistence.d.ts +2 -2
- package/hooks/features/virtualization/gridFocusedVirtualCellSelector.d.ts +6 -0
- package/hooks/features/virtualization/gridFocusedVirtualCellSelector.js +42 -0
- package/hooks/features/virtualization/useGridVirtualScroller.d.ts +2 -1
- package/hooks/features/virtualization/useGridVirtualScroller.js +92 -50
- package/hooks/features/virtualization/useGridVirtualization.d.ts +2 -2
- package/hooks/utils/useGridApiContext.d.ts +2 -2
- package/hooks/utils/useGridApiEventHandler.d.ts +4 -4
- package/hooks/utils/useGridApiMethod.d.ts +2 -2
- package/hooks/utils/useGridApiRef.d.ts +2 -2
- package/hooks/utils/useGridApiRef.js +3 -1
- package/hooks/utils/useGridInitializeState.d.ts +3 -3
- package/hooks/utils/useGridLogger.d.ts +2 -2
- package/hooks/utils/useGridNativeEventListener.d.ts +2 -1
- package/hooks/utils/useGridPrivateApiContext.d.ts +2 -1
- package/hooks/utils/useGridSelector.d.ts +3 -3
- package/hooks/utils/useGridVisibleRows.d.ts +8 -6
- package/hooks/utils/useGridVisibleRows.js +5 -28
- package/index.js +1 -1
- package/internals/constants.d.ts +6 -0
- package/internals/constants.js +8 -1
- package/internals/index.d.ts +1 -0
- package/internals/index.js +1 -0
- package/internals/utils/attachPinnedStyle.d.ts +2 -0
- package/internals/utils/attachPinnedStyle.js +9 -0
- package/internals/utils/getPinnedCellOffset.d.ts +3 -3
- package/internals/utils/getPinnedCellOffset.js +6 -7
- package/internals/utils/index.d.ts +1 -0
- package/internals/utils/index.js +2 -1
- package/locales/faIR.js +5 -6
- package/locales/urPK.js +9 -10
- package/models/colDef/gridColDef.d.ts +9 -8
- package/models/events/gridEventLookup.d.ts +6 -1
- package/models/gridExport.d.ts +2 -2
- package/models/gridFilterOperator.d.ts +2 -1
- package/models/gridStateCommunity.d.ts +4 -0
- package/models/props/DataGridProps.d.ts +2 -1
- package/modern/DataGrid/DataGrid.js +4 -5
- package/modern/DataGrid/useDataGridComponent.js +1 -1
- package/modern/components/GridHeaders.js +2 -2
- package/modern/components/GridRow.js +28 -105
- package/modern/components/GridSkeletonLoadingOverlay.js +18 -18
- package/modern/components/cell/GridCell.js +17 -35
- package/modern/components/columnHeaders/GridColumnGroupHeader.js +7 -10
- package/modern/components/columnHeaders/GridColumnHeaderFilterIconButton.js +21 -7
- package/modern/components/columnHeaders/GridColumnHeaderItem.js +13 -12
- package/modern/components/columnSelection/GridCellCheckboxRenderer.js +2 -2
- package/modern/components/containers/GridRoot.js +14 -6
- package/modern/components/containers/GridRootStyles.js +1 -0
- package/modern/components/panel/GridPanel.js +2 -1
- package/modern/components/toolbar/GridToolbarColumnsButton.js +6 -1
- package/modern/components/toolbar/GridToolbarFilterButton.js +6 -1
- package/modern/components/virtualization/GridVirtualScrollbar.js +11 -12
- package/modern/components/virtualization/GridVirtualScroller.js +4 -4
- package/modern/hooks/features/columnHeaders/useGridColumnHeaders.js +34 -76
- package/modern/hooks/features/columnMenu/useGridColumnMenu.js +0 -2
- package/modern/hooks/features/columnResize/useGridColumnResize.js +4 -2
- package/modern/hooks/features/dimensions/useGridDimensions.js +1 -3
- package/modern/hooks/features/filter/gridFilterSelector.js +6 -1
- package/modern/hooks/features/filter/gridFilterUtils.js +3 -3
- package/modern/hooks/features/pagination/gridPaginationSelector.js +39 -1
- package/modern/hooks/features/pagination/useGridPagination.js +5 -3
- package/modern/hooks/features/pagination/useGridPaginationModel.js +23 -1
- package/modern/hooks/features/preferencesPanel/gridPreferencePanelSelector.js +8 -1
- package/modern/hooks/features/preferencesPanel/index.js +1 -1
- package/modern/hooks/features/preferencesPanel/useGridPreferencesPanel.js +14 -38
- package/modern/hooks/features/rows/gridRowsSelector.js +1 -1
- package/modern/hooks/features/rows/useGridRows.js +2 -2
- package/modern/hooks/features/sorting/gridSortingUtils.js +2 -2
- package/modern/hooks/features/virtualization/gridFocusedVirtualCellSelector.js +42 -0
- package/modern/hooks/features/virtualization/useGridVirtualScroller.js +92 -50
- package/modern/hooks/utils/useGridApiRef.js +3 -1
- package/modern/hooks/utils/useGridVisibleRows.js +5 -28
- package/modern/index.js +1 -1
- package/modern/internals/constants.js +8 -1
- package/modern/internals/index.js +1 -0
- package/modern/internals/utils/attachPinnedStyle.js +9 -0
- package/modern/internals/utils/getPinnedCellOffset.js +6 -7
- package/modern/internals/utils/index.js +2 -1
- package/modern/locales/faIR.js +5 -6
- package/modern/locales/urPK.js +9 -10
- package/modern/utils/cellBorderUtils.js +5 -5
- package/modern/utils/domUtils.js +7 -2
- package/modern/utils/isJSDOM.js +1 -0
- package/modern/utils/rtlFlipSide.js +22 -0
- package/node/DataGrid/DataGrid.js +2 -3
- package/node/DataGrid/useDataGridComponent.js +1 -1
- package/node/components/GridHeaders.js +2 -2
- package/node/components/GridRow.js +27 -104
- package/node/components/GridSkeletonLoadingOverlay.js +17 -17
- package/node/components/cell/GridCell.js +18 -36
- package/node/components/columnHeaders/GridColumnGroupHeader.js +7 -10
- package/node/components/columnHeaders/GridColumnHeaderFilterIconButton.js +20 -6
- package/node/components/columnHeaders/GridColumnHeaderItem.js +13 -12
- package/node/components/columnSelection/GridCellCheckboxRenderer.js +1 -1
- package/node/components/containers/GridRoot.js +14 -6
- package/node/components/containers/GridRootStyles.js +1 -0
- package/node/components/panel/GridPanel.js +2 -1
- package/node/components/toolbar/GridToolbarColumnsButton.js +6 -1
- package/node/components/toolbar/GridToolbarFilterButton.js +6 -1
- package/node/components/virtualization/GridVirtualScrollbar.js +11 -12
- package/node/components/virtualization/GridVirtualScroller.js +4 -4
- package/node/hooks/features/columnHeaders/useGridColumnHeaders.js +32 -74
- package/node/hooks/features/columnMenu/useGridColumnMenu.js +0 -2
- package/node/hooks/features/columnResize/useGridColumnResize.js +4 -2
- package/node/hooks/features/dimensions/useGridDimensions.js +3 -5
- package/node/hooks/features/filter/gridFilterSelector.js +6 -1
- package/node/hooks/features/filter/gridFilterUtils.js +3 -3
- package/node/hooks/features/pagination/gridPaginationSelector.js +41 -3
- package/node/hooks/features/pagination/useGridPagination.js +5 -3
- package/node/hooks/features/pagination/useGridPaginationModel.js +23 -1
- package/node/hooks/features/preferencesPanel/gridPreferencePanelSelector.js +9 -2
- package/node/hooks/features/preferencesPanel/index.js +11 -10
- package/node/hooks/features/preferencesPanel/useGridPreferencesPanel.js +14 -38
- package/node/hooks/features/rows/gridRowsSelector.js +1 -1
- package/node/hooks/features/rows/useGridRows.js +1 -1
- package/node/hooks/features/sorting/gridSortingUtils.js +2 -2
- package/node/hooks/features/virtualization/gridFocusedVirtualCellSelector.js +49 -0
- package/node/hooks/features/virtualization/useGridVirtualScroller.js +94 -52
- package/node/hooks/utils/useGridApiRef.js +3 -1
- package/node/hooks/utils/useGridVisibleRows.js +3 -28
- package/node/index.js +1 -1
- package/node/internals/constants.js +9 -2
- package/node/internals/index.js +12 -0
- package/node/internals/utils/attachPinnedStyle.js +15 -0
- package/node/internals/utils/getPinnedCellOffset.js +6 -7
- package/node/internals/utils/index.js +11 -0
- package/node/locales/faIR.js +5 -6
- package/node/locales/urPK.js +9 -10
- package/node/utils/cellBorderUtils.js +5 -5
- package/node/utils/domUtils.js +7 -2
- package/node/utils/isJSDOM.js +7 -0
- package/node/utils/rtlFlipSide.js +29 -0
- package/package.json +2 -2
- package/utils/cellBorderUtils.d.ts +3 -3
- package/utils/cellBorderUtils.js +5 -5
- package/utils/createSelector.d.ts +3 -3
- package/utils/domUtils.js +7 -2
- package/utils/getPublicApiRef.d.ts +2 -1
- package/utils/isJSDOM.d.ts +1 -0
- package/utils/isJSDOM.js +1 -0
- package/utils/rtlFlipSide.d.ts +2 -0
- package/utils/rtlFlipSide.js +22 -0
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
import { RefObject } from '@mui/x-internals/types';
|
|
2
3
|
import { GridPrivateApiCommon } from '../../models/api/gridApiCommon';
|
|
3
4
|
import { GridPrivateApiCommunity } from '../../models/api/gridApiCommunity';
|
|
4
5
|
export declare const GridPrivateApiContext: React.Context<unknown>;
|
|
5
|
-
export declare function useGridPrivateApiContext<PrivateApi extends GridPrivateApiCommon = GridPrivateApiCommunity>():
|
|
6
|
+
export declare function useGridPrivateApiContext<PrivateApi extends GridPrivateApiCommon = GridPrivateApiCommunity>(): RefObject<PrivateApi>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { RefObject } from '@mui/x-internals/types';
|
|
2
2
|
import { fastObjectShallowCompare } from '@mui/x-internals/fastObjectShallowCompare';
|
|
3
3
|
import type { GridApiCommon } from '../../models/api/gridApiCommon';
|
|
4
4
|
import type { OutputSelector, OutputSelectorV8 } from '../../utils/createSelector';
|
|
5
5
|
type Selector<Api extends GridApiCommon, Args, T> = ((state: Api['state']) => T) | OutputSelectorV8<Api['state'], Args, T>;
|
|
6
6
|
export declare const objectShallowCompare: typeof fastObjectShallowCompare;
|
|
7
7
|
export declare const argsEqual: (prev: any, curr: any) => boolean;
|
|
8
|
-
export declare const useGridSelector: <Api extends GridApiCommon, T>(apiRef:
|
|
9
|
-
export declare const useGridSelectorV8: <Api extends GridApiCommon, Args, T>(apiRef:
|
|
8
|
+
export declare const useGridSelector: <Api extends GridApiCommon, T>(apiRef: RefObject<Api>, selector: ((state: Api["state"]) => T) | OutputSelector<Api["state"], T>, equals?: (a: T, b: T) => boolean) => T;
|
|
9
|
+
export declare const useGridSelectorV8: <Api extends GridApiCommon, Args, T>(apiRef: RefObject<Api>, selector: Selector<Api, Args, T>, args?: Args, equals?: <U = T>(a: U, b: U) => boolean) => T;
|
|
10
10
|
export {};
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { RefObject } from '@mui/x-internals/types';
|
|
2
2
|
import { DataGridProcessedProps } from '../../models/props/DataGridProps';
|
|
3
|
-
import type { GridApiCommon
|
|
4
|
-
export declare const getVisibleRows: <Api extends GridApiCommon>(apiRef:
|
|
5
|
-
rows: GridRowEntry<import("../..").GridValidRowModel>[];
|
|
3
|
+
import type { GridApiCommon } from '../../models';
|
|
4
|
+
export declare const getVisibleRows: <Api extends GridApiCommon>(apiRef: RefObject<Api>, props?: Pick<DataGridProcessedProps, "pagination" | "paginationMode">) => {
|
|
5
|
+
rows: import("../..").GridRowEntry<import("../..").GridValidRowModel>[];
|
|
6
6
|
range: {
|
|
7
7
|
firstRowIndex: number;
|
|
8
8
|
lastRowIndex: number;
|
|
9
9
|
} | null;
|
|
10
|
+
rowToIndexMap: Map<import("../..").GridValidRowModel, number>;
|
|
10
11
|
};
|
|
11
12
|
/**
|
|
12
13
|
* Computes the list of rows that are reachable by scroll.
|
|
@@ -15,10 +16,11 @@ export declare const getVisibleRows: <Api extends GridApiCommon>(apiRef: React.R
|
|
|
15
16
|
* - If the row tree has several layers, it contains up to `state.pageSize` top level rows and all their descendants.
|
|
16
17
|
* - If the row tree is flat, it only contains up to `state.pageSize` rows.
|
|
17
18
|
*/
|
|
18
|
-
export declare const useGridVisibleRows: <Api extends GridApiCommon>(apiRef:
|
|
19
|
-
rows: GridRowEntry<import("../..").GridValidRowModel>[];
|
|
19
|
+
export declare const useGridVisibleRows: <Api extends GridApiCommon>(apiRef: RefObject<Api>, props?: Pick<DataGridProcessedProps, "pagination" | "paginationMode">) => {
|
|
20
|
+
rows: import("../..").GridRowEntry<import("../..").GridValidRowModel>[];
|
|
20
21
|
range: {
|
|
21
22
|
firstRowIndex: number;
|
|
22
23
|
lastRowIndex: number;
|
|
23
24
|
} | null;
|
|
25
|
+
rowToIndexMap: Map<import("../..").GridValidRowModel, number>;
|
|
24
26
|
};
|
|
@@ -1,27 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import { gridExpandedSortedRowEntriesSelector } from "../features/filter/gridFilterSelector.js";
|
|
1
|
+
import { gridVisibleRowsSelector } from "../features/pagination/gridPaginationSelector.js";
|
|
2
|
+
import { useGridSelector } from "./index.js";
|
|
4
3
|
export const getVisibleRows = (apiRef, props) => {
|
|
5
|
-
|
|
6
|
-
let range;
|
|
7
|
-
if (props.pagination && props.paginationMode === 'client') {
|
|
8
|
-
range = gridPaginationRowRangeSelector(apiRef);
|
|
9
|
-
rows = gridPaginatedVisibleSortedGridRowEntriesSelector(apiRef);
|
|
10
|
-
} else {
|
|
11
|
-
rows = gridExpandedSortedRowEntriesSelector(apiRef);
|
|
12
|
-
if (rows.length === 0) {
|
|
13
|
-
range = null;
|
|
14
|
-
} else {
|
|
15
|
-
range = {
|
|
16
|
-
firstRowIndex: 0,
|
|
17
|
-
lastRowIndex: rows.length - 1
|
|
18
|
-
};
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
return {
|
|
22
|
-
rows,
|
|
23
|
-
range
|
|
24
|
-
};
|
|
4
|
+
return gridVisibleRowsSelector(apiRef);
|
|
25
5
|
};
|
|
26
6
|
|
|
27
7
|
/**
|
|
@@ -31,10 +11,7 @@ export const getVisibleRows = (apiRef, props) => {
|
|
|
31
11
|
* - If the row tree has several layers, it contains up to `state.pageSize` top level rows and all their descendants.
|
|
32
12
|
* - If the row tree is flat, it only contains up to `state.pageSize` rows.
|
|
33
13
|
*/
|
|
14
|
+
|
|
34
15
|
export const useGridVisibleRows = (apiRef, props) => {
|
|
35
|
-
|
|
36
|
-
return React.useMemo(() => ({
|
|
37
|
-
rows: response.rows,
|
|
38
|
-
range: response.range
|
|
39
|
-
}), [response.rows, response.range]);
|
|
16
|
+
return useGridSelector(apiRef, gridVisibleRowsSelector);
|
|
40
17
|
};
|
package/index.js
CHANGED
package/internals/constants.d.ts
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
1
|
export declare const GRID_TREE_DATA_GROUPING_FIELD = "__tree_data_group__";
|
|
2
2
|
export declare const GRID_ROW_GROUPING_SINGLE_GROUPING_FIELD = "__row_group_by_columns_group__";
|
|
3
3
|
export declare const GRID_DETAIL_PANEL_TOGGLE_FIELD = "__detail_panel_toggle__";
|
|
4
|
+
export declare enum PinnedColumnPosition {
|
|
5
|
+
NONE = 0,
|
|
6
|
+
LEFT = 1,
|
|
7
|
+
RIGHT = 2,
|
|
8
|
+
VIRTUAL = 3
|
|
9
|
+
}
|
package/internals/constants.js
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
1
|
export const GRID_TREE_DATA_GROUPING_FIELD = '__tree_data_group__';
|
|
2
2
|
export const GRID_ROW_GROUPING_SINGLE_GROUPING_FIELD = '__row_group_by_columns_group__';
|
|
3
|
-
export const GRID_DETAIL_PANEL_TOGGLE_FIELD = '__detail_panel_toggle__';
|
|
3
|
+
export const GRID_DETAIL_PANEL_TOGGLE_FIELD = '__detail_panel_toggle__';
|
|
4
|
+
export let PinnedColumnPosition = /*#__PURE__*/function (PinnedColumnPosition) {
|
|
5
|
+
PinnedColumnPosition[PinnedColumnPosition["NONE"] = 0] = "NONE";
|
|
6
|
+
PinnedColumnPosition[PinnedColumnPosition["LEFT"] = 1] = "LEFT";
|
|
7
|
+
PinnedColumnPosition[PinnedColumnPosition["RIGHT"] = 2] = "RIGHT";
|
|
8
|
+
PinnedColumnPosition[PinnedColumnPosition["VIRTUAL"] = 3] = "VIRTUAL";
|
|
9
|
+
return PinnedColumnPosition;
|
|
10
|
+
}({});
|
package/internals/index.d.ts
CHANGED
|
@@ -76,6 +76,7 @@ export type * from '../models/props/DataGridProps';
|
|
|
76
76
|
export type * from '../models/gridDataSource';
|
|
77
77
|
export { getColumnsToExport, defaultGetRowsToExport } from '../hooks/features/export/utils';
|
|
78
78
|
export * from '../utils/createControllablePromise';
|
|
79
|
+
export * from '../utils/rtlFlipSide';
|
|
79
80
|
export { createSelector, createSelectorV8, createSelectorMemoized, createSelectorMemoizedV8, } from '../utils/createSelector';
|
|
80
81
|
export { useGridSelectorV8 } from '../hooks/utils/useGridSelector';
|
|
81
82
|
export { gridRowGroupsToFetchSelector } from '../hooks/features/rows/gridRowsSelector';
|
package/internals/index.js
CHANGED
|
@@ -61,6 +61,7 @@ export { useGridVisibleRows, getVisibleRows } from "../hooks/utils/useGridVisibl
|
|
|
61
61
|
export { useGridInitializeState } from "../hooks/utils/useGridInitializeState.js";
|
|
62
62
|
export { getColumnsToExport, defaultGetRowsToExport } from "../hooks/features/export/utils.js";
|
|
63
63
|
export * from "../utils/createControllablePromise.js";
|
|
64
|
+
export * from "../utils/rtlFlipSide.js";
|
|
64
65
|
export { createSelector, createSelectorV8, createSelectorMemoized, createSelectorMemoizedV8 } from "../utils/createSelector.js";
|
|
65
66
|
export { useGridSelectorV8 } from "../hooks/utils/useGridSelector.js";
|
|
66
67
|
export { gridRowGroupsToFetchSelector } from "../hooks/features/rows/gridRowsSelector.js";
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { rtlFlipSide } from "../../utils/rtlFlipSide.js";
|
|
2
|
+
export function attachPinnedStyle(style, isRtl, pinnedPosition, pinnedOffset) {
|
|
3
|
+
const side = rtlFlipSide(pinnedPosition, isRtl);
|
|
4
|
+
if (!side || pinnedOffset === undefined) {
|
|
5
|
+
return style;
|
|
6
|
+
}
|
|
7
|
+
style[side] = pinnedOffset;
|
|
8
|
+
return style;
|
|
9
|
+
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
export declare const getPinnedCellOffset: (pinnedPosition:
|
|
1
|
+
import { PinnedColumnPosition } from '../constants';
|
|
2
|
+
import { gridColumnPositionsSelector } from '../../hooks/features/columns';
|
|
3
|
+
export declare const getPinnedCellOffset: (pinnedPosition: PinnedColumnPosition | undefined, computedWidth: number, columnIndex: number, columnPositions: ReturnType<typeof gridColumnPositionsSelector>, columnsTotalWidth: number, scrollbarWidth: number) => number | undefined;
|
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export const getPinnedCellOffset = (pinnedPosition, computedWidth, columnIndex, columnPositions,
|
|
3
|
-
const scrollbarWidth = dimensions.hasScrollY ? dimensions.scrollbarSize : 0;
|
|
1
|
+
import { PinnedColumnPosition } from "../constants.js";
|
|
2
|
+
export const getPinnedCellOffset = (pinnedPosition, computedWidth, columnIndex, columnPositions, columnsTotalWidth, scrollbarWidth) => {
|
|
4
3
|
let pinnedOffset;
|
|
5
4
|
switch (pinnedPosition) {
|
|
6
|
-
case
|
|
5
|
+
case PinnedColumnPosition.LEFT:
|
|
7
6
|
pinnedOffset = columnPositions[columnIndex];
|
|
8
7
|
break;
|
|
9
|
-
case
|
|
10
|
-
pinnedOffset =
|
|
8
|
+
case PinnedColumnPosition.RIGHT:
|
|
9
|
+
pinnedOffset = columnsTotalWidth - columnPositions[columnIndex] - computedWidth + scrollbarWidth;
|
|
11
10
|
break;
|
|
12
11
|
default:
|
|
13
|
-
pinnedOffset =
|
|
12
|
+
pinnedOffset = undefined;
|
|
14
13
|
break;
|
|
15
14
|
}
|
|
16
15
|
return pinnedOffset;
|
package/internals/utils/index.js
CHANGED
package/locales/faIR.js
CHANGED
|
@@ -34,8 +34,7 @@ const faIRGrid = {
|
|
|
34
34
|
columnsManagementNoColumns: 'بدون سطر',
|
|
35
35
|
columnsManagementShowHideAllText: 'نمایش/مخفی کردن همه',
|
|
36
36
|
columnsManagementReset: 'بازنشانی',
|
|
37
|
-
|
|
38
|
-
|
|
37
|
+
columnsManagementDeleteIconLabel: 'پاک کردن',
|
|
39
38
|
// Filter panel text
|
|
40
39
|
filterPanelAddFilter: 'افزودن فیلتر',
|
|
41
40
|
filterPanelRemoveAll: 'حذف همه',
|
|
@@ -49,9 +48,9 @@ const faIRGrid = {
|
|
|
49
48
|
filterPanelInputPlaceholder: 'فیلتر مقدار',
|
|
50
49
|
// Filter operators text
|
|
51
50
|
filterOperatorContains: 'شامل',
|
|
52
|
-
|
|
51
|
+
filterOperatorDoesNotContain: 'شامل نمیشود',
|
|
53
52
|
filterOperatorEquals: 'مساوی',
|
|
54
|
-
|
|
53
|
+
filterOperatorDoesNotEqual: 'برابر نیست',
|
|
55
54
|
filterOperatorStartsWith: 'شروع با',
|
|
56
55
|
filterOperatorEndsWith: 'پایان با',
|
|
57
56
|
filterOperatorIs: 'هست',
|
|
@@ -71,9 +70,9 @@ const faIRGrid = {
|
|
|
71
70
|
'filterOperator<=': '<=',
|
|
72
71
|
// Header filter operators text
|
|
73
72
|
headerFilterOperatorContains: 'شامل',
|
|
74
|
-
|
|
73
|
+
headerFilterOperatorDoesNotContain: 'شامل نمیشود',
|
|
75
74
|
headerFilterOperatorEquals: 'مساوی',
|
|
76
|
-
|
|
75
|
+
headerFilterOperatorDoesNotEqual: 'برابر نیست',
|
|
77
76
|
headerFilterOperatorStartsWith: 'شروع با',
|
|
78
77
|
headerFilterOperatorEndsWith: 'پایان با',
|
|
79
78
|
headerFilterOperatorIs: 'هست',
|
package/locales/urPK.js
CHANGED
|
@@ -30,12 +30,11 @@ const urPKGrid = {
|
|
|
30
30
|
toolbarExportPrint: 'پرنٹ کریں',
|
|
31
31
|
toolbarExportExcel: 'ایکسل کے طور پر ڈاوٴنلوڈ کریں',
|
|
32
32
|
// Columns management text
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
33
|
+
columnsManagementSearchTitle: 'تلاش',
|
|
34
|
+
columnsManagementNoColumns: 'کوئی کالم نہیں',
|
|
35
|
+
columnsManagementShowHideAllText: 'تمام دکھائیں/چھپائیں',
|
|
36
|
+
columnsManagementReset: 'ریسیٹ',
|
|
37
|
+
columnsManagementDeleteIconLabel: 'کلئیر',
|
|
39
38
|
// Filter panel text
|
|
40
39
|
filterPanelAddFilter: 'نیا فلٹر',
|
|
41
40
|
filterPanelRemoveAll: 'سارے ختم کریں',
|
|
@@ -49,9 +48,9 @@ const urPKGrid = {
|
|
|
49
48
|
filterPanelInputPlaceholder: 'ویلیو کو فلٹر کریں',
|
|
50
49
|
// Filter operators text
|
|
51
50
|
filterOperatorContains: 'شامل ہے',
|
|
52
|
-
|
|
51
|
+
filterOperatorDoesNotContain: 'موجود نہیں ہے',
|
|
53
52
|
filterOperatorEquals: 'برابر ہے',
|
|
54
|
-
|
|
53
|
+
filterOperatorDoesNotEqual: 'برابر نہیں ہے',
|
|
55
54
|
filterOperatorStartsWith: 'شروع ہوتا ہے',
|
|
56
55
|
filterOperatorEndsWith: 'ختم ہوتا ہے',
|
|
57
56
|
filterOperatorIs: 'ہے',
|
|
@@ -71,9 +70,9 @@ const urPKGrid = {
|
|
|
71
70
|
'filterOperator<=': '<=',
|
|
72
71
|
// Header filter operators text
|
|
73
72
|
headerFilterOperatorContains: 'شامل ہے',
|
|
74
|
-
|
|
73
|
+
headerFilterOperatorDoesNotContain: 'موجود نہیں ہے',
|
|
75
74
|
headerFilterOperatorEquals: 'برابر ہے',
|
|
76
|
-
|
|
75
|
+
headerFilterOperatorDoesNotEqual: 'برابر نہیں ہے',
|
|
77
76
|
headerFilterOperatorStartsWith: 'شروع ہوتا ہے',
|
|
78
77
|
headerFilterOperatorEndsWith: 'ختم ہوتا ہے',
|
|
79
78
|
headerFilterOperatorIs: 'ہے',
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
import { RefObject } from '@mui/x-internals/types';
|
|
2
3
|
import { GridCellClassNamePropType } from '../gridCellClass';
|
|
3
4
|
import { GridColumnHeaderClassNamePropType } from '../gridColumnHeaderClass';
|
|
4
5
|
import type { GridFilterOperator } from '../gridFilterOperator';
|
|
@@ -24,13 +25,13 @@ export type ValueOptions = string | number | {
|
|
|
24
25
|
* Value that can be used as a key for grouping rows
|
|
25
26
|
*/
|
|
26
27
|
export type GridKeyValue = string | number | boolean;
|
|
27
|
-
export type GridApplyQuickFilter<R extends GridValidRowModel = GridValidRowModel, V = any> = (value: V, row: R, column: GridColDef, apiRef:
|
|
28
|
-
export type GetApplyQuickFilterFn<R extends GridValidRowModel = GridValidRowModel, V = any> = (value: any, colDef: GridStateColDef<R, V>, apiRef:
|
|
29
|
-
export type GridValueGetter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V, TValue = never> = (value: TValue, row: R, column: GridColDef<R, V, F>, apiRef:
|
|
30
|
-
export type GridValueFormatter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V, TValue = never> = (value: TValue, row: R, column: GridColDef<R, V, F>, apiRef:
|
|
31
|
-
export type GridValueSetter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: V, row: R, column: GridColDef<R, V, F>, apiRef:
|
|
32
|
-
export type GridValueParser<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: F | undefined, row: R | undefined, column: GridColDef<R, V, F>, apiRef:
|
|
33
|
-
export type GridColSpanFn<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: V, row: R, column: GridColDef<R, V, F>, apiRef:
|
|
28
|
+
export type GridApplyQuickFilter<R extends GridValidRowModel = GridValidRowModel, V = any> = (value: V, row: R, column: GridColDef, apiRef: RefObject<GridApiCommunity>) => boolean;
|
|
29
|
+
export type GetApplyQuickFilterFn<R extends GridValidRowModel = GridValidRowModel, V = any> = (value: any, colDef: GridStateColDef<R, V>, apiRef: RefObject<GridApiCommunity>) => null | GridApplyQuickFilter<R, V>;
|
|
30
|
+
export type GridValueGetter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V, TValue = never> = (value: TValue, row: R, column: GridColDef<R, V, F>, apiRef: RefObject<GridApiCommunity>) => V;
|
|
31
|
+
export type GridValueFormatter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V, TValue = never> = (value: TValue, row: R, column: GridColDef<R, V, F>, apiRef: RefObject<GridApiCommunity>) => F;
|
|
32
|
+
export type GridValueSetter<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: V, row: R, column: GridColDef<R, V, F>, apiRef: RefObject<GridApiCommunity>) => R;
|
|
33
|
+
export type GridValueParser<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: F | undefined, row: R | undefined, column: GridColDef<R, V, F>, apiRef: RefObject<GridApiCommunity>) => V;
|
|
34
|
+
export type GridColSpanFn<R extends GridValidRowModel = GridValidRowModel, V = any, F = V> = (value: V, row: R, column: GridColDef<R, V, F>, apiRef: RefObject<GridApiCommunity>) => number | undefined;
|
|
34
35
|
/**
|
|
35
36
|
* Column Definition base interface.
|
|
36
37
|
*/
|
|
@@ -217,7 +218,7 @@ export interface GridBaseColDef<R extends GridValidRowModel = GridValidRowModel,
|
|
|
217
218
|
* This function can return `null` to skip filtering for this value and column.
|
|
218
219
|
* @param {any} value The value with which we want to filter the column.
|
|
219
220
|
* @param {GridStateColDef} colDef The column from which we want to filter the rows.
|
|
220
|
-
* @param {
|
|
221
|
+
* @param {RefObject<GridApiCommunity>} apiRef Deprecated: The API of the grid.
|
|
221
222
|
* @returns {null | GridApplyQuickFilter} The function to call to check if a row pass this filter value or not.
|
|
222
223
|
*/
|
|
223
224
|
getApplyQuickFilterFn?: GetApplyQuickFilterFn<R, V>;
|
|
@@ -583,7 +583,12 @@ export interface GridEventLookup extends GridRowEventLookup, GridColumnHeaderEve
|
|
|
583
583
|
* Fired when the content size used by the `GridVirtualScroller` changes.
|
|
584
584
|
* @ignore - do not document.
|
|
585
585
|
*/
|
|
586
|
-
virtualScrollerContentSizeChange: {
|
|
586
|
+
virtualScrollerContentSizeChange: {
|
|
587
|
+
params: {
|
|
588
|
+
columnsTotalWidth: number;
|
|
589
|
+
contentHeight: number;
|
|
590
|
+
};
|
|
591
|
+
};
|
|
587
592
|
/**
|
|
588
593
|
* Fired when the content is scrolled by the mouse wheel.
|
|
589
594
|
* It's attached to the "mousewheel" event.
|
package/models/gridExport.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { RefObject } from '@mui/x-internals/types';
|
|
2
2
|
import { GridRowId } from './gridRows';
|
|
3
3
|
import type { GridApiCommon } from './api';
|
|
4
4
|
import type { GridApiCommunity } from './api/gridApiCommunity';
|
|
@@ -49,7 +49,7 @@ export interface GridGetRowsToExportParams<Api extends GridApiCommon = GridApiCo
|
|
|
49
49
|
/**
|
|
50
50
|
* The API of the grid.
|
|
51
51
|
*/
|
|
52
|
-
apiRef:
|
|
52
|
+
apiRef: RefObject<Api>;
|
|
53
53
|
}
|
|
54
54
|
export interface GridCsvGetRowsToExportParams<Api extends GridApiCommon = GridApiCommunity> extends GridGetRowsToExportParams<Api> {
|
|
55
55
|
}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
import { RefObject } from '@mui/x-internals/types';
|
|
2
3
|
import { GridFilterItem } from './gridFilterItem';
|
|
3
4
|
import type { GridColDef } from './colDef/gridColDef';
|
|
4
5
|
import type { GridValidRowModel } from './gridRows';
|
|
5
6
|
import type { GridApiCommunity } from './api/gridApiCommunity';
|
|
6
|
-
type ApplyFilterFn<R extends GridValidRowModel = any, V = any, F = V> = (value: V, row: R, column: GridColDef<R, V, F>, apiRef:
|
|
7
|
+
type ApplyFilterFn<R extends GridValidRowModel = any, V = any, F = V> = (value: V, row: R, column: GridColDef<R, V, F>, apiRef: RefObject<GridApiCommunity>) => boolean;
|
|
7
8
|
export type GetApplyFilterFn<R extends GridValidRowModel = any, V = any, F = V> = (filterItem: GridFilterItem, column: GridColDef<R, V, F>) => null | ApplyFilterFn<R, V, F>;
|
|
8
9
|
/**
|
|
9
10
|
* Filter operator definition interface.
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
import { RefObject } from '@mui/x-internals/types';
|
|
2
3
|
import { SxProps } from '@mui/system';
|
|
3
4
|
import { Theme } from '@mui/material/styles';
|
|
4
5
|
import { CommonProps } from '@mui/material/OverridableComponent';
|
|
@@ -386,7 +387,7 @@ export interface DataGridPropsWithoutDefaultValue<R extends GridValidRowModel =
|
|
|
386
387
|
/**
|
|
387
388
|
* The ref object that allows Data Grid manipulation. Can be instantiated with `useGridApiRef()`.
|
|
388
389
|
*/
|
|
389
|
-
apiRef?:
|
|
390
|
+
apiRef?: RefObject<GridApiCommunity>;
|
|
390
391
|
/**
|
|
391
392
|
* Forwarded props for the Data Grid root element.
|
|
392
393
|
* @ignore - do not document.
|
|
@@ -4,14 +4,14 @@ import _extends from "@babel/runtime/helpers/esm/extends";
|
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import PropTypes from 'prop-types';
|
|
6
6
|
import { forwardRef } from '@mui/x-internals/forwardRef';
|
|
7
|
-
import {
|
|
7
|
+
import { GridRoot } from "../components/index.js";
|
|
8
8
|
import { useGridAriaAttributes } from "../hooks/utils/useGridAriaAttributes.js";
|
|
9
9
|
import { useGridRowAriaAttributes } from "../hooks/features/rows/useGridRowAriaAttributes.js";
|
|
10
10
|
import { GridContextProvider } from "../context/GridContextProvider.js";
|
|
11
11
|
import { useDataGridComponent } from "./useDataGridComponent.js";
|
|
12
12
|
import { useDataGridProps } from "./useDataGridProps.js";
|
|
13
13
|
import { propValidatorsDataGrid, validateProps } from "../internals/utils/propValidation.js";
|
|
14
|
-
import { jsx as _jsx
|
|
14
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
15
15
|
const configuration = {
|
|
16
16
|
hooks: {
|
|
17
17
|
useGridAriaAttributes,
|
|
@@ -34,13 +34,12 @@ const DataGridRaw = forwardRef(function DataGrid(inProps, ref) {
|
|
|
34
34
|
privateApiRef: privateApiRef,
|
|
35
35
|
configuration: configuration,
|
|
36
36
|
props: props,
|
|
37
|
-
children: /*#__PURE__*/
|
|
37
|
+
children: /*#__PURE__*/_jsx(GridRoot, _extends({
|
|
38
38
|
className: props.className,
|
|
39
39
|
style: props.style,
|
|
40
40
|
sx: props.sx
|
|
41
41
|
}, props.forwardedProps, props.slotProps?.root, {
|
|
42
|
-
ref: ref
|
|
43
|
-
children: [/*#__PURE__*/_jsx(GridHeader, {}), /*#__PURE__*/_jsx(GridBody, {}), /*#__PURE__*/_jsx(GridFooterPlaceholder, {})]
|
|
42
|
+
ref: ref
|
|
44
43
|
}))
|
|
45
44
|
});
|
|
46
45
|
});
|
|
@@ -44,6 +44,7 @@ export const useDataGridComponent = (inputApiRef, props) => {
|
|
|
44
44
|
useGridInitializeState(dimensionsStateInitializer, apiRef, props);
|
|
45
45
|
useGridInitializeState(rowSelectionStateInitializer, apiRef, props);
|
|
46
46
|
useGridInitializeState(columnsStateInitializer, apiRef, props);
|
|
47
|
+
useGridInitializeState(paginationStateInitializer, apiRef, props);
|
|
47
48
|
useGridInitializeState(rowsStateInitializer, apiRef, props);
|
|
48
49
|
useGridInitializeState(editingStateInitializer, apiRef, props);
|
|
49
50
|
useGridInitializeState(focusStateInitializer, apiRef, props);
|
|
@@ -53,7 +54,6 @@ export const useDataGridComponent = (inputApiRef, props) => {
|
|
|
53
54
|
useGridInitializeState(rowSpanningStateInitializer, apiRef, props);
|
|
54
55
|
useGridInitializeState(densityStateInitializer, apiRef, props);
|
|
55
56
|
useGridInitializeState(columnResizeStateInitializer, apiRef, props);
|
|
56
|
-
useGridInitializeState(paginationStateInitializer, apiRef, props);
|
|
57
57
|
useGridInitializeState(rowsMetaStateInitializer, apiRef, props);
|
|
58
58
|
useGridInitializeState(columnMenuStateInitializer, apiRef, props);
|
|
59
59
|
useGridInitializeState(columnGroupsStateInitializer, apiRef, props);
|
|
@@ -18,7 +18,7 @@ function GridHeaders() {
|
|
|
18
18
|
const filterColumnLookup = useGridSelector(apiRef, gridFilterActiveItemsLookupSelector);
|
|
19
19
|
const sortColumnLookup = useGridSelector(apiRef, gridSortColumnLookupSelector);
|
|
20
20
|
const columnHeaderTabIndexState = useGridSelector(apiRef, gridTabIndexColumnHeaderSelector);
|
|
21
|
-
const
|
|
21
|
+
const hasNoCellTabIndexState = useGridSelector(apiRef, () => gridTabIndexCellSelector(apiRef) === null);
|
|
22
22
|
const columnGroupHeaderTabIndexState = useGridSelector(apiRef, gridTabIndexColumnGroupHeaderSelector);
|
|
23
23
|
const columnHeaderFocus = useGridSelector(apiRef, gridFocusColumnHeaderSelector);
|
|
24
24
|
const columnGroupHeaderFocus = useGridSelector(apiRef, gridFocusColumnGroupHeaderSelector);
|
|
@@ -26,7 +26,7 @@ function GridHeaders() {
|
|
|
26
26
|
const columnMenuState = useGridSelector(apiRef, gridColumnMenuSelector);
|
|
27
27
|
const columnVisibility = useGridSelector(apiRef, gridColumnVisibilityModelSelector);
|
|
28
28
|
const columnGroupsHeaderStructure = useGridSelector(apiRef, gridColumnGroupsHeaderStructureSelector);
|
|
29
|
-
const hasOtherElementInTabSequence = !(columnGroupHeaderTabIndexState === null && columnHeaderTabIndexState === null &&
|
|
29
|
+
const hasOtherElementInTabSequence = !(columnGroupHeaderTabIndexState === null && columnHeaderTabIndexState === null && hasNoCellTabIndexState);
|
|
30
30
|
const columnsContainerRef = apiRef.current.columnHeadersContainerRef;
|
|
31
31
|
return /*#__PURE__*/_jsx(rootProps.slots.columnHeaders, _extends({
|
|
32
32
|
ref: columnsContainerRef,
|