@mui/x-data-grid-pro 8.26.0 → 8.27.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 +153 -0
- package/DataGridPro/DataGridPro.d.ts +2 -2
- package/DataGridPro/DataGridPro.js +1 -1
- package/DataGridPro/useDataGridProComponent.d.ts +4 -4
- package/DataGridPro/useDataGridProProps.d.ts +2 -2
- package/components/GridColumnHeaders.d.ts +1 -1
- package/components/GridColumnMenuPinningItem.d.ts +1 -1
- package/components/GridDataSourceTreeDataGroupingCell.d.ts +1 -1
- package/components/GridDetailPanel.d.ts +1 -1
- package/components/GridDetailPanelToggleCell.d.ts +1 -1
- package/components/GridDetailPanels.d.ts +1 -1
- package/components/GridPinnedRows.d.ts +1 -1
- package/components/GridProColumnMenu.d.ts +2 -2
- package/components/GridProColumnMenu.js +3 -1
- package/components/GridRowReorderCell.d.ts +1 -1
- package/components/GridRowReorderCell.js +2 -2
- package/components/GridTreeDataGroupingCell.d.ts +1 -1
- package/components/headerFiltering/GridHeaderFilterCell.d.ts +2 -2
- package/components/headerFiltering/GridHeaderFilterCell.js +2 -1
- package/components/headerFiltering/GridHeaderFilterClearButton.d.ts +1 -1
- package/components/headerFiltering/GridHeaderFilterMenu.d.ts +1 -1
- package/components/headerFiltering/GridHeaderFilterMenuContainer.d.ts +1 -1
- package/esm/DataGridPro/DataGridPro.d.ts +2 -2
- package/esm/DataGridPro/DataGridPro.js +1 -1
- package/esm/DataGridPro/useDataGridProComponent.d.ts +4 -4
- package/esm/DataGridPro/useDataGridProProps.d.ts +2 -2
- package/esm/components/GridColumnHeaders.d.ts +1 -1
- package/esm/components/GridColumnMenuPinningItem.d.ts +1 -1
- package/esm/components/GridDataSourceTreeDataGroupingCell.d.ts +1 -1
- package/esm/components/GridDetailPanel.d.ts +1 -1
- package/esm/components/GridDetailPanelToggleCell.d.ts +1 -1
- package/esm/components/GridDetailPanels.d.ts +1 -1
- package/esm/components/GridPinnedRows.d.ts +1 -1
- package/esm/components/GridProColumnMenu.d.ts +2 -2
- package/esm/components/GridProColumnMenu.js +3 -1
- package/esm/components/GridRowReorderCell.d.ts +1 -1
- package/esm/components/GridRowReorderCell.js +1 -1
- package/esm/components/GridTreeDataGroupingCell.d.ts +1 -1
- package/esm/components/headerFiltering/GridHeaderFilterCell.d.ts +2 -2
- package/esm/components/headerFiltering/GridHeaderFilterCell.js +2 -1
- package/esm/components/headerFiltering/GridHeaderFilterClearButton.d.ts +1 -1
- package/esm/components/headerFiltering/GridHeaderFilterMenu.d.ts +1 -1
- package/esm/components/headerFiltering/GridHeaderFilterMenuContainer.d.ts +1 -1
- package/esm/hooks/features/columnHeaders/useGridColumnHeaders.d.ts +1 -1
- package/esm/hooks/features/columnPinning/gridColumnPinningInterface.d.ts +2 -2
- package/esm/hooks/features/columnPinning/useGridColumnPinning.d.ts +4 -4
- package/esm/hooks/features/columnPinning/useGridColumnPinning.js +4 -0
- package/esm/hooks/features/columnPinning/useGridColumnPinningPreProcessors.d.ts +3 -3
- package/esm/hooks/features/columnReorder/columnReorderSelector.d.ts +1 -1
- package/esm/hooks/features/columnReorder/useGridColumnReorder.d.ts +4 -4
- package/esm/hooks/features/dataSource/gridDataSourceSelector.d.ts +1 -1
- package/esm/hooks/features/dataSource/useGridDataSourceBasePro.d.ts +6 -6
- package/esm/hooks/features/dataSource/useGridDataSourcePro.d.ts +4 -4
- package/esm/hooks/features/dataSource/utils.d.ts +3 -3
- package/esm/hooks/features/detailPanel/gridDetailPanelInterface.d.ts +2 -2
- package/esm/hooks/features/detailPanel/gridDetailPanelSelector.d.ts +1 -1
- package/esm/hooks/features/detailPanel/gridDetailPanelToggleColDef.d.ts +1 -1
- package/esm/hooks/features/detailPanel/useGridDetailPanel.d.ts +4 -4
- package/esm/hooks/features/detailPanel/useGridDetailPanelPreProcessors.d.ts +3 -3
- package/esm/hooks/features/infiniteLoader/useGridInfiniteLoader.d.ts +3 -3
- package/esm/hooks/features/lazyLoader/useGridLazyLoader.d.ts +3 -3
- package/esm/hooks/features/lazyLoader/useGridLazyLoaderPreProcessors.d.ts +3 -3
- package/esm/hooks/features/lazyLoader/utils.d.ts +23 -8
- package/esm/hooks/features/lazyLoader/utils.js +23 -0
- package/esm/hooks/features/rowPinning/gridRowPinningInterface.d.ts +1 -1
- package/esm/hooks/features/rowPinning/useGridRowPinning.d.ts +4 -4
- package/esm/hooks/features/rowPinning/useGridRowPinningPreProcessors.d.ts +4 -4
- package/esm/hooks/features/rowReorder/gridRowReorderColDef.d.ts +1 -1
- package/esm/hooks/features/rowReorder/models.d.ts +1 -1
- package/esm/hooks/features/rowReorder/reorderValidator.d.ts +1 -1
- package/esm/hooks/features/rowReorder/useGridRowReorder.d.ts +3 -3
- package/esm/hooks/features/rowReorder/useGridRowReorderPreProcessors.d.ts +3 -3
- package/esm/hooks/features/rowReorder/utils.d.ts +2 -2
- package/esm/hooks/features/rows/useGridRowAriaAttributes.d.ts +1 -1
- package/esm/hooks/features/serverSideLazyLoader/useGridDataSourceLazyLoader.d.ts +3 -3
- package/esm/hooks/features/serverSideLazyLoader/useGridDataSourceLazyLoader.js +23 -28
- package/esm/hooks/features/serverSideLazyLoader/useGridInfiniteLoadingIntersection.d.ts +3 -3
- package/esm/hooks/features/serverSideLazyLoader/useGridInfiniteLoadingIntersection.js +1 -1
- package/esm/hooks/features/serverSideTreeData/useGridDataSourceTreeDataPreProcessors.d.ts +3 -3
- package/esm/hooks/features/serverSideTreeData/utils.d.ts +5 -2
- package/esm/hooks/features/serverSideTreeData/utils.js +14 -2
- package/esm/hooks/features/treeData/gridTreeDataGroupColDef.d.ts +1 -1
- package/esm/hooks/features/treeData/gridTreeDataUtils.d.ts +3 -3
- package/esm/hooks/features/treeData/treeDataReorderExecutor.d.ts +1 -1
- package/esm/hooks/features/treeData/useGridTreeData.d.ts +1 -1
- package/esm/hooks/features/treeData/useGridTreeDataPreProcessors.d.ts +3 -3
- package/esm/hooks/utils/useGridApiContext.d.ts +3 -3
- package/esm/hooks/utils/useGridApiRef.d.ts +2 -2
- package/esm/hooks/utils/useGridAriaAttributes.d.ts +1 -1
- package/esm/hooks/utils/useGridPrivateApiContext.d.ts +1 -1
- package/esm/index.js +1 -1
- package/esm/internals/propValidation.d.ts +2 -2
- package/esm/models/dataGridProProps.d.ts +4 -4
- package/esm/models/gridApiPro.d.ts +3 -3
- package/esm/models/gridFetchRowsParams.d.ts +1 -1
- package/esm/models/gridGroupingColDefOverride.d.ts +1 -1
- package/esm/models/gridProIconSlotsComponent.d.ts +2 -2
- package/esm/models/gridProSlotProps.d.ts +1 -1
- package/esm/models/gridProSlotsComponent.d.ts +2 -2
- package/esm/models/gridRowOrderChangeParams.d.ts +1 -1
- package/esm/models/gridRowScrollEndParams.d.ts +1 -1
- package/esm/models/gridStatePro.d.ts +1 -1
- package/esm/themeAugmentation/overrides.d.ts +1 -1
- package/esm/themeAugmentation/props.d.ts +2 -2
- package/esm/typeOverloads/modules.d.ts +2 -2
- package/esm/utils/tree/createRowTree.d.ts +4 -4
- package/esm/utils/tree/insertDataRowInTree.d.ts +4 -4
- package/esm/utils/tree/models.d.ts +1 -1
- package/esm/utils/tree/removeDataRowFromTree.d.ts +2 -2
- package/esm/utils/tree/sortRowTree.d.ts +2 -2
- package/esm/utils/tree/updateRowTree.d.ts +3 -3
- package/esm/utils/tree/utils.d.ts +4 -4
- package/hooks/features/columnHeaders/useGridColumnHeaders.d.ts +1 -1
- package/hooks/features/columnPinning/gridColumnPinningInterface.d.ts +2 -2
- package/hooks/features/columnPinning/useGridColumnPinning.d.ts +4 -4
- package/hooks/features/columnPinning/useGridColumnPinning.js +4 -0
- package/hooks/features/columnPinning/useGridColumnPinningPreProcessors.d.ts +3 -3
- package/hooks/features/columnReorder/columnReorderSelector.d.ts +1 -1
- package/hooks/features/columnReorder/useGridColumnReorder.d.ts +4 -4
- package/hooks/features/dataSource/gridDataSourceSelector.d.ts +1 -1
- package/hooks/features/dataSource/useGridDataSourceBasePro.d.ts +6 -6
- package/hooks/features/dataSource/useGridDataSourcePro.d.ts +4 -4
- package/hooks/features/dataSource/utils.d.ts +3 -3
- package/hooks/features/detailPanel/gridDetailPanelInterface.d.ts +2 -2
- package/hooks/features/detailPanel/gridDetailPanelSelector.d.ts +1 -1
- package/hooks/features/detailPanel/gridDetailPanelToggleColDef.d.ts +1 -1
- package/hooks/features/detailPanel/useGridDetailPanel.d.ts +4 -4
- package/hooks/features/detailPanel/useGridDetailPanelPreProcessors.d.ts +3 -3
- package/hooks/features/infiniteLoader/useGridInfiniteLoader.d.ts +3 -3
- package/hooks/features/lazyLoader/useGridLazyLoader.d.ts +3 -3
- package/hooks/features/lazyLoader/useGridLazyLoaderPreProcessors.d.ts +3 -3
- package/hooks/features/lazyLoader/utils.d.ts +23 -8
- package/hooks/features/lazyLoader/utils.js +26 -1
- package/hooks/features/rowPinning/gridRowPinningInterface.d.ts +1 -1
- package/hooks/features/rowPinning/useGridRowPinning.d.ts +4 -4
- package/hooks/features/rowPinning/useGridRowPinningPreProcessors.d.ts +4 -4
- package/hooks/features/rowReorder/gridRowReorderColDef.d.ts +1 -1
- package/hooks/features/rowReorder/models.d.ts +1 -1
- package/hooks/features/rowReorder/reorderValidator.d.ts +1 -1
- package/hooks/features/rowReorder/useGridRowReorder.d.ts +3 -3
- package/hooks/features/rowReorder/useGridRowReorderPreProcessors.d.ts +3 -3
- package/hooks/features/rowReorder/utils.d.ts +2 -2
- package/hooks/features/rows/useGridRowAriaAttributes.d.ts +1 -1
- package/hooks/features/serverSideLazyLoader/useGridDataSourceLazyLoader.d.ts +3 -3
- package/hooks/features/serverSideLazyLoader/useGridDataSourceLazyLoader.js +23 -28
- package/hooks/features/serverSideLazyLoader/useGridInfiniteLoadingIntersection.d.ts +3 -3
- package/hooks/features/serverSideLazyLoader/useGridInfiniteLoadingIntersection.js +2 -2
- package/hooks/features/serverSideTreeData/useGridDataSourceTreeDataPreProcessors.d.ts +3 -3
- package/hooks/features/serverSideTreeData/utils.d.ts +5 -2
- package/hooks/features/serverSideTreeData/utils.js +14 -2
- package/hooks/features/treeData/gridTreeDataGroupColDef.d.ts +1 -1
- package/hooks/features/treeData/gridTreeDataUtils.d.ts +3 -3
- package/hooks/features/treeData/treeDataReorderExecutor.d.ts +1 -1
- package/hooks/features/treeData/useGridTreeData.d.ts +1 -1
- package/hooks/features/treeData/useGridTreeDataPreProcessors.d.ts +3 -3
- package/hooks/utils/useGridApiContext.d.ts +3 -3
- package/hooks/utils/useGridApiRef.d.ts +2 -2
- package/hooks/utils/useGridAriaAttributes.d.ts +1 -1
- package/hooks/utils/useGridPrivateApiContext.d.ts +1 -1
- package/index.js +1 -1
- package/internals/propValidation.d.ts +2 -2
- package/models/dataGridProProps.d.ts +4 -4
- package/models/gridApiPro.d.ts +3 -3
- package/models/gridFetchRowsParams.d.ts +1 -1
- package/models/gridGroupingColDefOverride.d.ts +1 -1
- package/models/gridProIconSlotsComponent.d.ts +2 -2
- package/models/gridProSlotProps.d.ts +1 -1
- package/models/gridProSlotsComponent.d.ts +2 -2
- package/models/gridRowOrderChangeParams.d.ts +1 -1
- package/models/gridRowScrollEndParams.d.ts +1 -1
- package/models/gridStatePro.d.ts +1 -1
- package/package.json +4 -4
- package/themeAugmentation/overrides.d.ts +1 -1
- package/themeAugmentation/props.d.ts +2 -2
- package/typeOverloads/modules.d.ts +2 -2
- package/utils/tree/createRowTree.d.ts +4 -4
- package/utils/tree/insertDataRowInTree.d.ts +4 -4
- package/utils/tree/models.d.ts +1 -1
- package/utils/tree/removeDataRowFromTree.d.ts +2 -2
- package/utils/tree/sortRowTree.d.ts +2 -2
- package/utils/tree/updateRowTree.d.ts +3 -3
- package/utils/tree/utils.d.ts +4 -4
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridRowId } from '@mui/x-data-grid';
|
|
3
|
-
import { CacheChunkManager, DataSourceRowsUpdateStrategy, GridDataSourceBaseOptions, GridStrategyProcessor } from '@mui/x-data-grid/internals';
|
|
4
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
5
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
6
|
-
import { GridDataSourceApiPro, GridDataSourcePrivateApiPro } from "./models.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import { type GridRowId } from '@mui/x-data-grid';
|
|
3
|
+
import { CacheChunkManager, DataSourceRowsUpdateStrategy, type GridDataSourceBaseOptions, type GridStrategyProcessor } from '@mui/x-data-grid/internals';
|
|
4
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
5
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
6
|
+
import type { GridDataSourceApiPro, GridDataSourcePrivateApiPro } from "./models.js";
|
|
7
7
|
export declare const INITIAL_STATE: {
|
|
8
8
|
loading: {};
|
|
9
9
|
errors: {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridStateInitializer } from '@mui/x-data-grid/internals';
|
|
3
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import { type GridStateInitializer } from '@mui/x-data-grid/internals';
|
|
3
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
5
5
|
export declare const dataSourceStateInitializer: GridStateInitializer;
|
|
6
6
|
export declare const useGridDataSourcePro: (apiRef: RefObject<GridPrivateApiPro>, props: DataGridProProcessedProps) => void;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridKeyValue, GridRowId, GridRowTreeConfig } from '@mui/x-data-grid';
|
|
3
|
-
import { GridPrivateApiPro } from "../../../models/index.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import { type GridKeyValue, type GridRowId, type GridRowTreeConfig } from '@mui/x-data-grid';
|
|
3
|
+
import type { GridPrivateApiPro } from "../../../models/index.js";
|
|
4
4
|
export declare enum RequestStatus {
|
|
5
5
|
QUEUED = 0,
|
|
6
6
|
PENDING = 1,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GridStatePro } from "../../../models/gridStatePro.js";
|
|
1
|
+
import type { GridStatePro } from "../../../models/gridStatePro.js";
|
|
2
2
|
export declare const gridDetailPanelStateSelector: import("@mui/x-data-grid").OutputSelector<GridStatePro, unknown, import("./gridDetailPanelInterface.js").GridDetailPanelState>;
|
|
3
3
|
export declare const gridDetailPanelExpandedRowIdsSelector: (args_0: import("react").RefObject<{
|
|
4
4
|
state: GridStatePro;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GridColDef } from '@mui/x-data-grid';
|
|
1
|
+
import { type GridColDef } from '@mui/x-data-grid';
|
|
2
2
|
import { GRID_DETAIL_PANEL_TOGGLE_FIELD } from '@mui/x-data-grid/internals';
|
|
3
3
|
export { GRID_DETAIL_PANEL_TOGGLE_FIELD };
|
|
4
4
|
export declare const GRID_DETAIL_PANEL_TOGGLE_COL_DEF: GridColDef;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridStateInitializer } from '@mui/x-data-grid/internals';
|
|
3
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import { type GridStateInitializer } from '@mui/x-data-grid/internals';
|
|
3
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
5
5
|
export declare const detailPanelStateInitializer: GridStateInitializer<Pick<DataGridProProcessedProps, 'initialState' | 'detailPanelExpandedRowIds'>>;
|
|
6
6
|
export declare const useGridDetailPanel: (apiRef: RefObject<GridPrivateApiPro>, props: Pick<DataGridProProcessedProps, "getDetailPanelContent" | "getDetailPanelHeight" | "detailPanelExpandedRowIds" | "onDetailPanelExpandedRowIdsChange">) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
3
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
3
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
4
|
export declare const useGridDetailPanelPreProcessors: (privateApiRef: RefObject<GridPrivateApiPro>, props: DataGridProProcessedProps) => void;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
3
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
3
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
4
4
|
/**
|
|
5
5
|
* @requires useGridColumns (state)
|
|
6
6
|
* @requires useGridDimensions (method) - can be after
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
3
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
3
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
4
4
|
/**
|
|
5
5
|
* @requires useGridRows (state)
|
|
6
6
|
* @requires useGridPagination (state)
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
3
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
3
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
4
4
|
export declare const GRID_SKELETON_ROW_ROOT_ID = "auto-generated-skeleton-row-root";
|
|
5
5
|
export declare const useGridLazyLoaderPreProcessors: (privateApiRef: RefObject<GridPrivateApiPro>, props: Pick<DataGridProProcessedProps, "rowCount" | "rowsLoadingMode">) => void;
|
|
@@ -1,6 +1,23 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridRowEntry } from '@mui/x-data-grid';
|
|
3
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import { type GridRowEntry } from '@mui/x-data-grid';
|
|
3
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
|
+
interface GridRowRenderContext {
|
|
5
|
+
firstRowIndex: number;
|
|
6
|
+
lastRowIndex: number;
|
|
7
|
+
}
|
|
8
|
+
interface AdjustRowParamsOptions {
|
|
9
|
+
pageSize: number;
|
|
10
|
+
rowCount: number | undefined;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Adjusts the row fetch parameters to align with page boundaries.
|
|
14
|
+
* - Start index is decreased to the start of the page
|
|
15
|
+
* - End index is increased to the end of the page (capped by rowCount - 1 if defined)
|
|
16
|
+
*/
|
|
17
|
+
export declare const adjustRowParams: <T extends {
|
|
18
|
+
start: number | string;
|
|
19
|
+
end: number;
|
|
20
|
+
}>(params: T, options: AdjustRowParamsOptions) => T;
|
|
4
21
|
export declare const findSkeletonRowsSection: ({
|
|
5
22
|
apiRef,
|
|
6
23
|
visibleRows,
|
|
@@ -8,11 +25,9 @@ export declare const findSkeletonRowsSection: ({
|
|
|
8
25
|
}: {
|
|
9
26
|
apiRef: RefObject<GridPrivateApiPro>;
|
|
10
27
|
visibleRows: GridRowEntry[];
|
|
11
|
-
range:
|
|
12
|
-
firstRowIndex: number;
|
|
13
|
-
lastRowIndex: number;
|
|
14
|
-
};
|
|
28
|
+
range: GridRowRenderContext;
|
|
15
29
|
}) => {
|
|
16
30
|
firstRowIndex: number;
|
|
17
31
|
lastRowIndex: number;
|
|
18
|
-
} | undefined;
|
|
32
|
+
} | undefined;
|
|
33
|
+
export {};
|
|
@@ -1,4 +1,27 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
1
2
|
import { gridRowNodeSelector } from '@mui/x-data-grid';
|
|
3
|
+
/**
|
|
4
|
+
* Adjusts the row fetch parameters to align with page boundaries.
|
|
5
|
+
* - Start index is decreased to the start of the page
|
|
6
|
+
* - End index is increased to the end of the page (capped by rowCount - 1 if defined)
|
|
7
|
+
*/
|
|
8
|
+
export const adjustRowParams = (params, options) => {
|
|
9
|
+
if (typeof params.start !== 'number') {
|
|
10
|
+
return params;
|
|
11
|
+
}
|
|
12
|
+
const {
|
|
13
|
+
pageSize,
|
|
14
|
+
rowCount
|
|
15
|
+
} = options;
|
|
16
|
+
const adjustedStart = params.start - params.start % pageSize;
|
|
17
|
+
const pageAlignedEnd = params.end + pageSize - params.end % pageSize - 1;
|
|
18
|
+
// rowCount of -1 means "unknown/infinite", treat same as undefined (no capping)
|
|
19
|
+
const maxEnd = rowCount !== undefined && rowCount !== -1 ? Math.max(0, rowCount - 1) : Infinity;
|
|
20
|
+
return _extends({}, params, {
|
|
21
|
+
start: adjustedStart,
|
|
22
|
+
end: Math.min(maxEnd, pageAlignedEnd)
|
|
23
|
+
});
|
|
24
|
+
};
|
|
2
25
|
export const findSkeletonRowsSection = ({
|
|
3
26
|
apiRef,
|
|
4
27
|
visibleRows,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GridRowId, GridRowIdToModelLookup, GridRowsProp, GridValidRowModel } from '@mui/x-data-grid';
|
|
1
|
+
import type { GridRowId, GridRowIdToModelLookup, GridRowsProp, GridValidRowModel } from '@mui/x-data-grid';
|
|
2
2
|
export interface GridPinnedRowsProp<R extends GridValidRowModel = GridValidRowModel> {
|
|
3
3
|
top?: GridRowsProp<R>;
|
|
4
4
|
bottom?: GridRowsProp<R>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridStateInitializer } from '@mui/x-data-grid/internals';
|
|
3
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import { type GridStateInitializer } from '@mui/x-data-grid/internals';
|
|
3
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
5
5
|
export declare const rowPinningStateInitializer: GridStateInitializer<Pick<DataGridProProcessedProps, 'pinnedRows' | 'getRowId'>>;
|
|
6
6
|
export declare const useGridRowPinning: (apiRef: RefObject<GridPrivateApiPro>, props: Pick<DataGridProProcessedProps, "pinnedRows" | "getRowId">) => void;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridHydrateRowsValue } from '@mui/x-data-grid/internals';
|
|
3
|
-
import { GridRowId, GridRowModel } from '@mui/x-data-grid';
|
|
4
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import { type GridHydrateRowsValue } from '@mui/x-data-grid/internals';
|
|
3
|
+
import { type GridRowId, type GridRowModel } from '@mui/x-data-grid';
|
|
4
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
5
5
|
import type { GridPinnedRowsProp } from "./gridRowPinningInterface.js";
|
|
6
6
|
type GridPinnedRowPosition = keyof GridPinnedRowsProp;
|
|
7
7
|
export declare function addPinnedRow({
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { GridColDef } from '@mui/x-data-grid';
|
|
1
|
+
import { type GridColDef } from '@mui/x-data-grid';
|
|
2
2
|
export declare const GRID_REORDER_COL_DEF: GridColDef;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GridTreeNode, GridValidRowModel } from '@mui/x-data-grid';
|
|
1
|
+
import type { GridTreeNode, GridValidRowModel } from '@mui/x-data-grid';
|
|
2
2
|
import type { RefObject } from '@mui/x-internals/types';
|
|
3
3
|
import type { RowReorderDropPosition, RowReorderDragDirection } from '@mui/x-data-grid/internals';
|
|
4
4
|
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
2
|
import { type GridStateInitializer } from '@mui/x-data-grid/internals';
|
|
3
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
3
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
5
5
|
export declare const rowReorderStateInitializer: GridStateInitializer;
|
|
6
6
|
/**
|
|
7
7
|
* Hook for row reordering (Pro package)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
3
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
3
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
4
|
export declare const useGridRowReorderPreProcessors: (privateApiRef: RefObject<GridPrivateApiPro>, props: DataGridProProcessedProps) => void;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
2
|
import { type GridRowId, type GridTreeNode, type GridGroupNode, type GridRowTreeConfig, type GridKeyValue, type GridValidRowModel } from '@mui/x-data-grid';
|
|
3
|
-
import {
|
|
3
|
+
import type { ReorderOperationType } from "./types.js";
|
|
4
4
|
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
5
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
5
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
6
6
|
export { getNodePathInTree } from "../../../utils/tree/utils.js";
|
|
7
7
|
/**
|
|
8
8
|
* Finds the closest cell element from the given event target.
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { GridTreeNode } from '@mui/x-data-grid';
|
|
2
|
+
import { type GridTreeNode } from '@mui/x-data-grid';
|
|
3
3
|
export declare const useGridRowAriaAttributesPro: (addTreeDataAttributes?: boolean) => (rowNode: GridTreeNode, index: number) => React.HTMLAttributes<HTMLElement>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
3
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
3
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
4
4
|
/**
|
|
5
5
|
* @requires useGridRows (state)
|
|
6
6
|
* @requires useGridPagination (state)
|
|
@@ -7,7 +7,7 @@ import useEventCallback from '@mui/utils/useEventCallback';
|
|
|
7
7
|
import debounce from '@mui/utils/debounce';
|
|
8
8
|
import { useGridEvent, gridSortModelSelector, gridFilterModelSelector, GRID_ROOT_GROUP_ID, gridPaginationModelSelector, gridFilteredSortedRowIdsSelector, gridRowIdSelector } from '@mui/x-data-grid';
|
|
9
9
|
import { getVisibleRows, gridRenderContextSelector, GridStrategyGroup, useGridRegisterStrategyProcessor, runIf, DataSourceRowsUpdateStrategy } from '@mui/x-data-grid/internals';
|
|
10
|
-
import { findSkeletonRowsSection } from "../lazyLoader/utils.js";
|
|
10
|
+
import { findSkeletonRowsSection, adjustRowParams } from "../lazyLoader/utils.js";
|
|
11
11
|
import { GRID_SKELETON_ROW_ROOT_ID } from "../lazyLoader/useGridLazyLoaderPreProcessors.js";
|
|
12
12
|
var LoadingTrigger = /*#__PURE__*/function (LoadingTrigger) {
|
|
13
13
|
LoadingTrigger[LoadingTrigger["VIEWPORT"] = 0] = "VIEWPORT";
|
|
@@ -39,19 +39,6 @@ export const useGridDataSourceLazyLoader = (privateApiRef, props) => {
|
|
|
39
39
|
privateApiRef.current.dataSource.fetchRows(GRID_ROOT_GROUP_ID, params);
|
|
40
40
|
}, [privateApiRef]);
|
|
41
41
|
const debouncedFetchRows = React.useMemo(() => debounce(fetchRows, 0), [fetchRows]);
|
|
42
|
-
|
|
43
|
-
// Adjust the render context range to fit the pagination model's page size
|
|
44
|
-
// First row index should be decreased to the start of the page, end row index should be increased to the end of the page
|
|
45
|
-
const adjustRowParams = React.useCallback(params => {
|
|
46
|
-
if (typeof params.start !== 'number') {
|
|
47
|
-
return params;
|
|
48
|
-
}
|
|
49
|
-
const paginationModel = gridPaginationModelSelector(privateApiRef);
|
|
50
|
-
return _extends({}, params, {
|
|
51
|
-
start: params.start - params.start % paginationModel.pageSize,
|
|
52
|
-
end: params.end + paginationModel.pageSize - params.end % paginationModel.pageSize - 1
|
|
53
|
-
});
|
|
54
|
-
}, [privateApiRef]);
|
|
55
42
|
const resetGrid = React.useCallback(() => {
|
|
56
43
|
privateApiRef.current.setLoading(true);
|
|
57
44
|
privateApiRef.current.dataSource.cache.clear();
|
|
@@ -102,9 +89,13 @@ export const useGridDataSourceLazyLoader = (privateApiRef, props) => {
|
|
|
102
89
|
if (rootChildrenCount === 0) {
|
|
103
90
|
return;
|
|
104
91
|
}
|
|
92
|
+
const paginationModel = gridPaginationModelSelector(privateApiRef);
|
|
105
93
|
const pageToSkip = adjustRowParams({
|
|
106
94
|
start: renderedRowsIntervalCache.current.firstRowToRender,
|
|
107
95
|
end: renderedRowsIntervalCache.current.lastRowToRender
|
|
96
|
+
}, {
|
|
97
|
+
pageSize: paginationModel.pageSize,
|
|
98
|
+
rowCount: pageRowCount
|
|
108
99
|
});
|
|
109
100
|
let hasChanged = false;
|
|
110
101
|
const isInitialPage = renderedRowsIntervalCache.current.firstRowToRender === 0 && renderedRowsIntervalCache.current.lastRowToRender === 0;
|
|
@@ -157,7 +148,7 @@ export const useGridDataSourceLazyLoader = (privateApiRef, props) => {
|
|
|
157
148
|
tree
|
|
158
149
|
})
|
|
159
150
|
}), 'addSkeletonRows');
|
|
160
|
-
}, [privateApiRef
|
|
151
|
+
}, [privateApiRef]);
|
|
161
152
|
const updateLoadingTrigger = React.useCallback(rowCount => {
|
|
162
153
|
const newLoadingTrigger = rowCount === -1 ? LoadingTrigger.SCROLL_END : LoadingTrigger.VIEWPORT;
|
|
163
154
|
if (loadingTrigger.current !== null) {
|
|
@@ -268,43 +259,47 @@ export const useGridDataSourceLazyLoader = (privateApiRef, props) => {
|
|
|
268
259
|
filterModel
|
|
269
260
|
};
|
|
270
261
|
privateApiRef.current.setLoading(true);
|
|
271
|
-
fetchRows(adjustRowParams(getRowsParams
|
|
262
|
+
fetchRows(adjustRowParams(getRowsParams, {
|
|
263
|
+
pageSize: paginationModel.pageSize,
|
|
264
|
+
rowCount: privateApiRef.current.state.pagination.rowCount
|
|
265
|
+
}));
|
|
272
266
|
});
|
|
273
|
-
const handleRenderedRowsIntervalChange = React.useCallback(
|
|
267
|
+
const handleRenderedRowsIntervalChange = React.useCallback(renderContext => {
|
|
274
268
|
if (rowsStale.current) {
|
|
275
269
|
return;
|
|
276
270
|
}
|
|
277
271
|
const sortModel = gridSortModelSelector(privateApiRef);
|
|
278
272
|
const filterModel = gridFilterModelSelector(privateApiRef);
|
|
279
273
|
const getRowsParams = {
|
|
280
|
-
start:
|
|
281
|
-
end:
|
|
274
|
+
start: renderContext.firstRowIndex,
|
|
275
|
+
end: renderContext.lastRowIndex - 1,
|
|
282
276
|
sortModel,
|
|
283
277
|
filterModel
|
|
284
278
|
};
|
|
285
|
-
if (renderedRowsIntervalCache.current.firstRowToRender ===
|
|
279
|
+
if (renderedRowsIntervalCache.current.firstRowToRender === renderContext.firstRowIndex && renderedRowsIntervalCache.current.lastRowToRender === renderContext.lastRowIndex) {
|
|
286
280
|
return;
|
|
287
281
|
}
|
|
288
282
|
renderedRowsIntervalCache.current = {
|
|
289
|
-
firstRowToRender:
|
|
290
|
-
lastRowToRender:
|
|
283
|
+
firstRowToRender: renderContext.firstRowIndex,
|
|
284
|
+
lastRowToRender: renderContext.lastRowIndex
|
|
291
285
|
};
|
|
292
286
|
const currentVisibleRows = getVisibleRows(privateApiRef);
|
|
293
287
|
const skeletonRowsSection = findSkeletonRowsSection({
|
|
294
288
|
apiRef: privateApiRef,
|
|
295
289
|
visibleRows: currentVisibleRows.rows,
|
|
296
|
-
range:
|
|
297
|
-
firstRowIndex: params.firstRowIndex,
|
|
298
|
-
lastRowIndex: params.lastRowIndex - 1
|
|
299
|
-
}
|
|
290
|
+
range: renderContext
|
|
300
291
|
});
|
|
301
292
|
if (!skeletonRowsSection) {
|
|
302
293
|
return;
|
|
303
294
|
}
|
|
304
295
|
getRowsParams.start = skeletonRowsSection.firstRowIndex;
|
|
305
296
|
getRowsParams.end = skeletonRowsSection.lastRowIndex;
|
|
306
|
-
|
|
307
|
-
|
|
297
|
+
const paginationModel = gridPaginationModelSelector(privateApiRef);
|
|
298
|
+
fetchRows(adjustRowParams(getRowsParams, {
|
|
299
|
+
pageSize: paginationModel.pageSize,
|
|
300
|
+
rowCount: privateApiRef.current.state.pagination.rowCount
|
|
301
|
+
}));
|
|
302
|
+
}, [privateApiRef, fetchRows]);
|
|
308
303
|
const throttledHandleRenderedRowsIntervalChange = React.useMemo(() => throttle(handleRenderedRowsIntervalChange, props.lazyLoadingRequestThrottleMs), [props.lazyLoadingRequestThrottleMs, handleRenderedRowsIntervalChange]);
|
|
309
304
|
React.useEffect(() => {
|
|
310
305
|
return () => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
3
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
3
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
4
4
|
/**
|
|
5
5
|
* @requires useGridDimensions (method) - can be after
|
|
6
6
|
*/
|
|
@@ -4,7 +4,7 @@ import * as React from 'react';
|
|
|
4
4
|
import { useGridSelector, useGridApiMethod, gridDimensionsSelector } from '@mui/x-data-grid';
|
|
5
5
|
import { useTimeout, gridHorizontalScrollbarHeightSelector } from '@mui/x-data-grid/internals';
|
|
6
6
|
import useEventCallback from '@mui/utils/useEventCallback';
|
|
7
|
-
import { styled } from '@mui/
|
|
7
|
+
import { styled } from '@mui/material/styles';
|
|
8
8
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
9
9
|
const InfiniteLoadingTriggerElement = styled('div', {
|
|
10
10
|
slot: 'internal',
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
3
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
3
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
4
|
export declare const useGridDataSourceTreeDataPreProcessors: (privateApiRef: RefObject<GridPrivateApiPro>, props: Pick<DataGridProProcessedProps, "treeData" | "groupingColDef" | "disableChildrenSorting" | "disableChildrenFiltering" | "defaultGroupingExpansionDepth" | "isGroupExpandedByDefault" | "dataSource">) => void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { GridRowId, GridRowTreeConfig } from '@mui/x-data-grid';
|
|
2
|
-
import { GridRowTreeCreationParams } from '@mui/x-data-grid/internals';
|
|
1
|
+
import { type GridRowId, type GridRowTreeConfig } from '@mui/x-data-grid';
|
|
2
|
+
import { type GridRowTreeCreationParams } from '@mui/x-data-grid/internals';
|
|
3
3
|
export declare function skipFiltering(rowTree: GridRowTreeConfig): {
|
|
4
4
|
filteredRowsLookup: {};
|
|
5
5
|
filteredChildrenCountLookup: Record<GridRowId, number>;
|
|
@@ -9,5 +9,8 @@ export declare function skipSorting(rowTree: GridRowTreeConfig): GridRowId[];
|
|
|
9
9
|
/**
|
|
10
10
|
* Retrieves the parent path for a row from the previous tree state.
|
|
11
11
|
* Used during full tree updates to maintain correct hierarchy.
|
|
12
|
+
*
|
|
13
|
+
* Uses the parent node's `path` property, which stores the group keys
|
|
14
|
+
* representing the full path to the parent (i.e. the keys used to fetch the current node).
|
|
12
15
|
*/
|
|
13
16
|
export declare function getParentPath(rowId: GridRowId, treeCreationParams: GridRowTreeCreationParams): string[];
|
|
@@ -20,10 +20,22 @@ export function skipSorting(rowTree) {
|
|
|
20
20
|
/**
|
|
21
21
|
* Retrieves the parent path for a row from the previous tree state.
|
|
22
22
|
* Used during full tree updates to maintain correct hierarchy.
|
|
23
|
+
*
|
|
24
|
+
* Uses the parent node's `path` property, which stores the group keys
|
|
25
|
+
* representing the full path to the parent (i.e. the keys used to fetch the current node).
|
|
23
26
|
*/
|
|
24
27
|
export function getParentPath(rowId, treeCreationParams) {
|
|
25
|
-
if (treeCreationParams.updates.type !== 'full' || !treeCreationParams.previousTree?.[rowId] || treeCreationParams.previousTree[rowId].depth < 1
|
|
28
|
+
if (treeCreationParams.updates.type !== 'full' || !treeCreationParams.previousTree?.[rowId] || treeCreationParams.previousTree[rowId].depth < 1) {
|
|
26
29
|
return [];
|
|
27
30
|
}
|
|
28
|
-
|
|
31
|
+
const node = treeCreationParams.previousTree[rowId];
|
|
32
|
+
const parentId = node.parent;
|
|
33
|
+
if (parentId == null) {
|
|
34
|
+
return [];
|
|
35
|
+
}
|
|
36
|
+
const parentNode = treeCreationParams.previousTree[parentId];
|
|
37
|
+
if (parentNode && 'path' in parentNode) {
|
|
38
|
+
return parentNode.path || [];
|
|
39
|
+
}
|
|
40
|
+
return [];
|
|
29
41
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridRowTreeConfig, GridFilterState, GridFilterModel, GridRowModel, GridColDef } from '@mui/x-data-grid';
|
|
3
|
-
import { GridAggregatedFilterItemApplier } from '@mui/x-data-grid/internals';
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import type { GridRowTreeConfig, GridFilterState, GridFilterModel, GridRowModel, GridColDef } from '@mui/x-data-grid';
|
|
3
|
+
import { type GridAggregatedFilterItemApplier } from '@mui/x-data-grid/internals';
|
|
4
4
|
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
5
5
|
interface FilterRowTreeFromTreeDataParams {
|
|
6
6
|
rowTree: GridRowTreeConfig;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { BaseReorderOperation, RowReorderExecutor } from "../rowReorder/reorderExecutor.js";
|
|
2
|
-
import {
|
|
2
|
+
import type { ReorderOperation, ReorderExecutionContext } from "../rowReorder/types.js";
|
|
3
3
|
/**
|
|
4
4
|
* Handles reordering of items within the same parent group.
|
|
5
5
|
*/
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
2
|
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
3
3
|
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
4
4
|
export declare const useGridTreeData: (apiRef: RefObject<GridPrivateApiPro>, props: Pick<DataGridProProcessedProps, "treeData" | "dataSource" | "isValidRowReorder">) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
3
|
-
import { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import type { DataGridProProcessedProps } from "../../../models/dataGridProProps.js";
|
|
3
|
+
import type { GridPrivateApiPro } from "../../../models/gridApiPro.js";
|
|
4
4
|
export declare const useGridTreeDataPreProcessors: (privateApiRef: RefObject<GridPrivateApiPro>, props: Pick<DataGridProProcessedProps, "treeData" | "groupingColDef" | "getTreeDataPath" | "disableChildrenSorting" | "disableChildrenFiltering" | "defaultGroupingExpansionDepth" | "isGroupExpandedByDefault" | "dataSource">) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridApiCommon } from '@mui/x-data-grid';
|
|
3
|
-
import { GridApiPro } from "../../models/gridApiPro.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import { type GridApiCommon } from '@mui/x-data-grid';
|
|
3
|
+
import type { GridApiPro } from "../../models/gridApiPro.js";
|
|
4
4
|
export declare const useGridApiContext: <Api extends GridApiCommon = GridApiPro>() => RefObject<Api>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import { GridApiPro } from "../../models/gridApiPro.js";
|
|
1
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
+
import type { GridApiPro } from "../../models/gridApiPro.js";
|
|
3
3
|
export declare const useGridApiRef: () => RefObject<GridApiPro | null>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
1
|
+
import type * as React from 'react';
|
|
2
2
|
export declare const useGridAriaAttributesPro: () => React.HTMLAttributes<HTMLElement>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { GridPrivateApiPro } from "../../models/gridApiPro.js";
|
|
1
|
+
import type { GridPrivateApiPro } from "../../models/gridApiPro.js";
|
|
2
2
|
export declare const useGridPrivateApiContext: () => import("react").RefObject<GridPrivateApiPro>;
|
package/esm/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { PropValidator } from '@mui/x-data-grid/internals';
|
|
2
|
-
import { DataGridProProcessedProps } from "../models/dataGridProProps.js";
|
|
1
|
+
import { type PropValidator } from '@mui/x-data-grid/internals';
|
|
2
|
+
import type { DataGridProProcessedProps } from "../models/dataGridProProps.js";
|
|
3
3
|
export declare const propValidatorsDataGridPro: PropValidator<DataGridProProcessedProps>[];
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { RefObject } from '@mui/x-internals/types';
|
|
3
|
-
import { GridEventListener, GridCallbackDetails, GridRowParams, GridRowId, GridValidRowModel, GridGroupNode, GridFeatureMode, GridListViewColDef, GridGetRowsError, GridUpdateRowError } from '@mui/x-data-grid';
|
|
1
|
+
import type * as React from 'react';
|
|
2
|
+
import type { RefObject } from '@mui/x-internals/types';
|
|
3
|
+
import type { GridEventListener, GridCallbackDetails, GridRowParams, GridRowId, GridValidRowModel, GridGroupNode, GridFeatureMode, GridListViewColDef, GridGetRowsError, GridUpdateRowError } from '@mui/x-data-grid';
|
|
4
4
|
import type { GridExperimentalFeatures, DataGridPropsWithoutDefaultValue, DataGridPropsWithDefaultValues, DataGridPropsWithComplexDefaultValueAfterProcessing, DataGridPropsWithComplexDefaultValueBeforeProcessing, GridPinnedColumnFields, DataGridProSharedPropsWithDefaultValue, DataGridProSharedPropsWithoutDefaultValue } from '@mui/x-data-grid/internals';
|
|
5
5
|
import type { GridPinnedRowsProp } from "../hooks/features/rowPinning/index.js";
|
|
6
6
|
import type { GridApiPro } from "./gridApiPro.js";
|
|
7
|
-
import { GridGroupingColDefOverride, GridGroupingColDefOverrideParams } from "./gridGroupingColDefOverride.js";
|
|
7
|
+
import type { GridGroupingColDefOverride, GridGroupingColDefOverrideParams } from "./gridGroupingColDefOverride.js";
|
|
8
8
|
import type { GridInitialStatePro } from "./gridStatePro.js";
|
|
9
9
|
import type { GridProSlotsComponent } from "./gridProSlotsComponent.js";
|
|
10
10
|
import type { GridProSlotProps } from "./gridProSlotProps.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { GridApiCommon, GridColumnReorderApi, GridRowMultiSelectionApi, GridRowProApi } from '@mui/x-data-grid';
|
|
2
|
-
import { GridPrivateOnlyApiCommon, GridInfiniteLoaderPrivateApi } from '@mui/x-data-grid/internals';
|
|
3
|
-
import { GridInitialStatePro, GridStatePro } from "./gridStatePro.js";
|
|
1
|
+
import type { GridApiCommon, GridColumnReorderApi, GridRowMultiSelectionApi, GridRowProApi } from '@mui/x-data-grid';
|
|
2
|
+
import type { GridPrivateOnlyApiCommon, GridInfiniteLoaderPrivateApi } from '@mui/x-data-grid/internals';
|
|
3
|
+
import type { GridInitialStatePro, GridStatePro } from "./gridStatePro.js";
|
|
4
4
|
import type { GridColumnPinningApi, GridDetailPanelApi, GridRowPinningApi, GridDetailPanelPrivateApi } from "../hooks/index.js";
|
|
5
5
|
import type { GridRowReorderPrivateApi } from "./gridRowReorderApi.js";
|
|
6
6
|
import type { GridDataSourceApiPro, GridDataSourcePrivateApiPro } from "../hooks/features/dataSource/models.js";
|