@mui/x-data-grid-premium 9.6.0 → 9.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +241 -2
- package/DataGridPremium/DataGridPremium.d.mts +1 -1
- package/DataGridPremium/DataGridPremium.d.ts +1 -1
- package/DataGridPremium/DataGridPremium.js +2 -2
- package/DataGridPremium/DataGridPremium.mjs +2 -2
- package/DataGridPremium/useDataGridPremiumComponent.d.mts +1 -1
- package/DataGridPremium/useDataGridPremiumComponent.d.ts +1 -1
- package/components/GridAggregationHeader.d.mts +2 -2
- package/components/GridAggregationHeader.d.ts +2 -2
- package/components/GridDataSourceGroupingCriteriaCell.d.mts +1 -1
- package/components/GridDataSourceGroupingCriteriaCell.d.ts +1 -1
- package/components/GridEmptyPivotOverlay.d.mts +1 -1
- package/components/GridEmptyPivotOverlay.d.ts +1 -1
- package/components/GridGroupingCriteriaCell.d.mts +1 -1
- package/components/GridGroupingCriteriaCell.d.ts +1 -1
- package/components/GridPremiumColumnMenu.d.mts +1 -1
- package/components/GridPremiumColumnMenu.d.ts +1 -1
- package/components/GridPremiumToolbar.d.mts +1 -1
- package/components/GridPremiumToolbar.d.ts +1 -1
- package/components/aiAssistantPanel/AiAssistantPanelTrigger.d.mts +2 -2
- package/components/aiAssistantPanel/AiAssistantPanelTrigger.d.ts +2 -2
- package/components/aiAssistantPanel/AiAssistantPanelTrigger.js +2 -2
- package/components/aiAssistantPanel/AiAssistantPanelTrigger.mjs +2 -2
- package/components/chartsPanel/ChartsPanelTrigger.d.mts +1 -1
- package/components/chartsPanel/ChartsPanelTrigger.d.ts +1 -1
- package/components/chartsPanel/data/GridChartsPanelDataSearch.d.mts +1 -1
- package/components/chartsPanel/data/GridChartsPanelDataSearch.d.ts +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuAggregationItem.d.mts +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuAggregationItem.d.ts +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuChartsItem.d.mts +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuChartsItem.d.ts +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuPivotItem.d.mts +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuPivotItem.d.ts +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuRowGroupItem.d.mts +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuRowGroupItem.d.ts +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuRowUngroupItem.d.mts +1 -1
- package/components/columnMenu/menuItems/GridColumnMenuRowUngroupItem.d.ts +1 -1
- package/components/pivotPanel/GridPivotPanelSearch.d.mts +1 -1
- package/components/pivotPanel/GridPivotPanelSearch.d.ts +1 -1
- package/components/pivotPanel/PivotPanelTrigger.d.mts +2 -2
- package/components/pivotPanel/PivotPanelTrigger.d.ts +2 -2
- package/components/promptField/GridPromptField.d.mts +1 -1
- package/components/promptField/GridPromptField.d.ts +1 -1
- package/components/promptField/PromptField.d.mts +1 -1
- package/components/promptField/PromptField.d.ts +1 -1
- package/components/promptField/PromptFieldControl.d.mts +1 -1
- package/components/promptField/PromptFieldControl.d.ts +1 -1
- package/components/promptField/PromptFieldRecord.d.mts +1 -1
- package/components/promptField/PromptFieldRecord.d.ts +1 -1
- package/components/promptField/PromptFieldSend.d.mts +1 -1
- package/components/promptField/PromptFieldSend.d.ts +1 -1
- package/hooks/features/aggregation/createAggregationLookup.js +2 -0
- package/hooks/features/aggregation/createAggregationLookup.mjs +2 -0
- package/hooks/features/aggregation/gridAggregationSelectors.d.mts +3 -3
- package/hooks/features/aggregation/gridAggregationSelectors.d.ts +3 -3
- package/hooks/features/aggregation/gridAggregationSelectors.js +1 -1
- package/hooks/features/aggregation/gridAggregationSelectors.mjs +1 -1
- package/hooks/features/aggregation/gridAggregationUtils.d.mts +2 -2
- package/hooks/features/aggregation/gridAggregationUtils.d.ts +2 -2
- package/hooks/features/aggregation/useGridAggregation.d.mts +1 -1
- package/hooks/features/aggregation/useGridAggregation.d.ts +1 -1
- package/hooks/features/aggregation/wrapColumnWithAggregation.d.mts +2 -2
- package/hooks/features/aggregation/wrapColumnWithAggregation.d.ts +2 -2
- package/hooks/features/aiAssistant/useGridAiAssistant.d.mts +1 -1
- package/hooks/features/aiAssistant/useGridAiAssistant.d.ts +1 -1
- package/hooks/features/cellSelection/useGridCellSelection.d.mts +1 -1
- package/hooks/features/cellSelection/useGridCellSelection.d.ts +1 -1
- package/hooks/features/cellSelection/useGridCellSelection.js +2 -2
- package/hooks/features/cellSelection/useGridCellSelection.mjs +2 -2
- package/hooks/features/chartsIntegration/useGridChartsIntegration.d.mts +1 -1
- package/hooks/features/chartsIntegration/useGridChartsIntegration.d.ts +1 -1
- package/hooks/features/clipboard/useGridClipboardImport.d.mts +1 -1
- package/hooks/features/clipboard/useGridClipboardImport.d.ts +1 -1
- package/hooks/features/dataSource/utils.d.mts +1 -1
- package/hooks/features/dataSource/utils.d.ts +1 -1
- package/hooks/features/editing/useGridCellEditable.d.mts +1 -1
- package/hooks/features/editing/useGridCellEditable.d.ts +1 -1
- package/hooks/features/export/serializer/excelSerializer.d.mts +3 -3
- package/hooks/features/export/serializer/excelSerializer.d.ts +3 -3
- package/hooks/features/export/serializer/excelSerializer.js +2 -2
- package/hooks/features/export/serializer/excelSerializer.mjs +2 -2
- package/hooks/features/history/useGridHistory.d.mts +1 -1
- package/hooks/features/history/useGridHistory.d.ts +1 -1
- package/hooks/features/pivoting/useGridPivoting.d.mts +2 -2
- package/hooks/features/pivoting/useGridPivoting.d.ts +2 -2
- package/hooks/features/pivoting/utils.d.mts +1 -1
- package/hooks/features/pivoting/utils.d.ts +1 -1
- package/hooks/features/rowGrouping/createGroupingColDef.d.mts +3 -2
- package/hooks/features/rowGrouping/createGroupingColDef.d.ts +3 -2
- package/hooks/features/rowGrouping/gridRowGroupingUtils.d.mts +2 -1
- package/hooks/features/rowGrouping/gridRowGroupingUtils.d.ts +2 -1
- package/hooks/features/rowGrouping/useGridRowGrouping.d.mts +1 -1
- package/hooks/features/rowGrouping/useGridRowGrouping.d.ts +1 -1
- package/hooks/features/rowReorder/operations.d.mts +2 -1
- package/hooks/features/rowReorder/operations.d.ts +2 -1
- package/hooks/features/rows/useGridParamsOverridableMethods.js +2 -2
- package/hooks/features/rows/useGridParamsOverridableMethods.mjs +2 -2
- package/hooks/features/sidebar/useGridSidebar.d.mts +1 -1
- package/hooks/features/sidebar/useGridSidebar.d.ts +1 -1
- package/hooks/utils/useGridApiContext.d.mts +1 -1
- package/hooks/utils/useGridApiContext.d.ts +1 -1
- package/hooks/utils/useKeepGroupedColumnsHidden.d.mts +1 -1
- package/hooks/utils/useKeepGroupedColumnsHidden.d.ts +1 -1
- package/hooks/utils/useKeepGroupedColumnsHidden.js +1 -1
- package/hooks/utils/useKeepGroupedColumnsHidden.mjs +1 -1
- package/index.js +1 -1
- package/index.mjs +1 -1
- package/package.json +7 -6
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import type { GridSlotProps, RenderProp } from '@mui/x-data-grid-pro';
|
|
3
|
-
import {
|
|
3
|
+
import type { PromptFieldState } from "./PromptFieldContext.js";
|
|
4
4
|
export type PromptFieldControlProps = Omit<GridSlotProps['baseTextField'], 'className'> & {
|
|
5
5
|
/**
|
|
6
6
|
* A function to customize rendering of the component.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import type { GridSlotProps, RenderProp } from '@mui/x-data-grid-pro';
|
|
3
|
-
import {
|
|
3
|
+
import type { PromptFieldState } from "./PromptFieldContext.mjs";
|
|
4
4
|
export type PromptFieldRecordProps = Omit<GridSlotProps['baseIconButton'], 'className'> & {
|
|
5
5
|
/**
|
|
6
6
|
* A function to customize rendering of the component.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import type { GridSlotProps, RenderProp } from '@mui/x-data-grid-pro';
|
|
3
|
-
import {
|
|
3
|
+
import type { PromptFieldState } from "./PromptFieldContext.js";
|
|
4
4
|
export type PromptFieldRecordProps = Omit<GridSlotProps['baseIconButton'], 'className'> & {
|
|
5
5
|
/**
|
|
6
6
|
* A function to customize rendering of the component.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import type { GridSlotProps, RenderProp } from '@mui/x-data-grid-pro';
|
|
3
|
-
import {
|
|
3
|
+
import type { PromptFieldState } from "./PromptFieldContext.mjs";
|
|
4
4
|
export type PromptFieldSendProps = Omit<GridSlotProps['baseIconButton'], 'className'> & {
|
|
5
5
|
/**
|
|
6
6
|
* A function to customize rendering of the component.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import type { GridSlotProps, RenderProp } from '@mui/x-data-grid-pro';
|
|
3
|
-
import {
|
|
3
|
+
import type { PromptFieldState } from "./PromptFieldContext.js";
|
|
4
4
|
export type PromptFieldSendProps = Omit<GridSlotProps['baseIconButton'], 'className'> & {
|
|
5
5
|
/**
|
|
6
6
|
* A function to customize rendering of the component.
|
|
@@ -139,6 +139,8 @@ const createAggregationLookup = ({
|
|
|
139
139
|
for (let i = 0; i < aggregatedFields.length; i += 1) {
|
|
140
140
|
const field = aggregatedFields[i];
|
|
141
141
|
const column = columnsLookup[field];
|
|
142
|
+
// `column` can be `undefined` if the field has no matching column; `getRowValue`
|
|
143
|
+
// tolerates that and returns `undefined`, which is filtered out when aggregating.
|
|
142
144
|
const valueGetter = row => apiRef.current.getRowValue(row, column);
|
|
143
145
|
valueGetters[field] = valueGetter;
|
|
144
146
|
}
|
|
@@ -132,6 +132,8 @@ export const createAggregationLookup = ({
|
|
|
132
132
|
for (let i = 0; i < aggregatedFields.length; i += 1) {
|
|
133
133
|
const field = aggregatedFields[i];
|
|
134
134
|
const column = columnsLookup[field];
|
|
135
|
+
// `column` can be `undefined` if the field has no matching column; `getRowValue`
|
|
136
|
+
// tolerates that and returns `undefined`, which is filtered out when aggregating.
|
|
135
137
|
const valueGetter = row => apiRef.current.getRowValue(row, column);
|
|
136
138
|
valueGetters[field] = valueGetter;
|
|
137
139
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import type { GridAggregationPosition } from '@mui/x-data-grid-pro/internals';
|
|
2
|
+
import type { GridRowId } from '@mui/x-data-grid-pro';
|
|
3
3
|
import type { GridStatePremium } from "../../../models/gridStatePremium.mjs";
|
|
4
4
|
export declare const gridAggregationStateSelector: import("@mui/x-data-grid").OutputSelector<GridStatePremium, unknown, import("./gridAggregationInterfaces.mjs").GridAggregationState>;
|
|
5
5
|
/**
|
|
@@ -21,7 +21,7 @@ export declare const gridCellAggregationResultSelector: (args_0: import("react")
|
|
|
21
21
|
state: GridStatePremium;
|
|
22
22
|
} | null>, args_1: {
|
|
23
23
|
id: GridRowId;
|
|
24
|
-
field: string;
|
|
24
|
+
field: string | undefined;
|
|
25
25
|
}) => {
|
|
26
26
|
position: GridAggregationPosition;
|
|
27
27
|
value: any;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import type { GridAggregationPosition } from '@mui/x-data-grid-pro/internals';
|
|
2
|
+
import type { GridRowId } from '@mui/x-data-grid-pro';
|
|
3
3
|
import type { GridStatePremium } from "../../../models/gridStatePremium.js";
|
|
4
4
|
export declare const gridAggregationStateSelector: import("@mui/x-data-grid").OutputSelector<GridStatePremium, unknown, import("./gridAggregationInterfaces.js").GridAggregationState>;
|
|
5
5
|
/**
|
|
@@ -21,7 +21,7 @@ export declare const gridCellAggregationResultSelector: (args_0: import("react")
|
|
|
21
21
|
state: GridStatePremium;
|
|
22
22
|
} | null>, args_1: {
|
|
23
23
|
id: GridRowId;
|
|
24
|
-
field: string;
|
|
24
|
+
field: string | undefined;
|
|
25
25
|
}) => {
|
|
26
26
|
position: GridAggregationPosition;
|
|
27
27
|
value: any;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import type { GridColDef, GridRowId, GridGroupNode } from '@mui/x-data-grid-pro';
|
|
3
|
+
import type { GridColumnRawLookup, GridHydrateRowsValue } from '@mui/x-data-grid-pro/internals';
|
|
4
4
|
import type { GridAggregationFunction, GridAggregationFunctionDataSource, GridAggregationModel, GridAggregationRule, GridAggregationRules } from "./gridAggregationInterfaces.mjs";
|
|
5
5
|
import type { GridStatePremium } from "../../../models/gridStatePremium.mjs";
|
|
6
6
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import type { GridColDef, GridRowId, GridGroupNode } from '@mui/x-data-grid-pro';
|
|
3
|
+
import type { GridColumnRawLookup, GridHydrateRowsValue } from '@mui/x-data-grid-pro/internals';
|
|
4
4
|
import type { GridAggregationFunction, GridAggregationFunctionDataSource, GridAggregationModel, GridAggregationRule, GridAggregationRules } from "./gridAggregationInterfaces.js";
|
|
5
5
|
import type { GridStatePremium } from "../../../models/gridStatePremium.js";
|
|
6
6
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
4
4
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
5
5
|
export declare const aggregationStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'aggregationModel' | 'initialState'>, GridPrivateApiPremium>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
4
4
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
5
5
|
export declare const aggregationStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'aggregationModel' | 'initialState'>, GridPrivateApiPremium>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import type { GridColDef } from '@mui/x-data-grid-pro';
|
|
3
|
+
import type { GridBaseColDef } from '@mui/x-data-grid-pro/internals';
|
|
4
4
|
import type { GridApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
5
5
|
import type { GridAggregationRule } from "./gridAggregationInterfaces.mjs";
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import type { GridColDef } from '@mui/x-data-grid-pro';
|
|
3
|
+
import type { GridBaseColDef } from '@mui/x-data-grid-pro/internals';
|
|
4
4
|
import type { GridApiPremium } from "../../../models/gridApiPremium.js";
|
|
5
5
|
import type { GridAggregationRule } from "./gridAggregationInterfaces.js";
|
|
6
6
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
5
5
|
export declare const aiAssistantStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'initialState' | 'aiAssistantConversations' | 'aiAssistant'>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
5
5
|
export declare const aiAssistantStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'initialState' | 'aiAssistantConversations' | 'aiAssistant'>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
4
4
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
5
5
|
export declare const cellSelectionStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'cellSelectionModel' | 'initialState'>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
4
4
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
5
5
|
export declare const cellSelectionStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'cellSelectionModel' | 'initialState'>>;
|
|
@@ -9,6 +9,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
9
9
|
exports.useGridCellSelection = exports.cellSelectionStateInitializer = void 0;
|
|
10
10
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
11
11
|
var React = _interopRequireWildcard(require("react"));
|
|
12
|
+
var _platform = require("@base-ui/utils/platform");
|
|
12
13
|
var _ownerDocument = _interopRequireDefault(require("@mui/utils/ownerDocument"));
|
|
13
14
|
var _useEventCallback = _interopRequireDefault(require("@mui/utils/useEventCallback"));
|
|
14
15
|
var _internals = require("@mui/x-data-grid-pro/internals");
|
|
@@ -187,8 +188,7 @@ const useGridCellSelection = (apiRef, props) => {
|
|
|
187
188
|
const handleCellMouseDown = React.useCallback((params, event) => {
|
|
188
189
|
// Skip if the click comes from the right-button or, only on macOS, Ctrl is pressed
|
|
189
190
|
// Fix for https://github.com/mui/mui-x/pull/6567#issuecomment-1329155578
|
|
190
|
-
|
|
191
|
-
if (event.button !== 0 || event.ctrlKey && isMacOs) {
|
|
191
|
+
if (event.button !== 0 || event.ctrlKey && _platform.platform.os.mac) {
|
|
192
192
|
return;
|
|
193
193
|
}
|
|
194
194
|
if (params.field === _xDataGridPro.GRID_REORDER_COL_DEF.field) {
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
4
4
|
import * as React from 'react';
|
|
5
|
+
import { platform } from '@base-ui/utils/platform';
|
|
5
6
|
import ownerDocument from '@mui/utils/ownerDocument';
|
|
6
7
|
import useEventCallback from '@mui/utils/useEventCallback';
|
|
7
8
|
import { getGridCellElement, getTotalHeaderHeight, getVisibleRows, isFillDownShortcut, isFillRightShortcut, isNavigationKey, serializeCellValue, useGridRegisterPipeProcessor } from '@mui/x-data-grid-pro/internals';
|
|
@@ -179,8 +180,7 @@ export const useGridCellSelection = (apiRef, props) => {
|
|
|
179
180
|
const handleCellMouseDown = React.useCallback((params, event) => {
|
|
180
181
|
// Skip if the click comes from the right-button or, only on macOS, Ctrl is pressed
|
|
181
182
|
// Fix for https://github.com/mui/mui-x/pull/6567#issuecomment-1329155578
|
|
182
|
-
|
|
183
|
-
if (event.button !== 0 || event.ctrlKey && isMacOs) {
|
|
183
|
+
if (event.button !== 0 || event.ctrlKey && platform.os.mac) {
|
|
184
184
|
return;
|
|
185
185
|
}
|
|
186
186
|
if (params.field === GRID_REORDER_COL_DEF.field) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
4
4
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
5
5
|
import type { ChartState } from "../../../models/gridChartsIntegration.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
4
4
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
5
5
|
import type { ChartState } from "../../../models/gridChartsIntegration.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridColDef, GridRowId, GridValidRowModel, GridRowModel } from '@mui/x-data-grid';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
5
5
|
export declare class CellValueUpdater {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridColDef, GridRowId, GridValidRowModel, GridRowModel } from '@mui/x-data-grid';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
5
5
|
export declare class CellValueUpdater {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridColDef, GridRowId, GridRowTreeConfig } from '@mui/x-data-grid-pro';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
4
4
|
import type { GridPivotingDynamicPropsOverrides, PivotingColDefCallback, GridPivotModel } from "../pivoting/gridPivotingInterfaces.mjs";
|
|
5
5
|
import type { GridGetRowsResponsePivotColumn } from "./models.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridColDef, GridRowId, GridRowTreeConfig } from '@mui/x-data-grid-pro';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
4
4
|
import type { GridPivotingDynamicPropsOverrides, PivotingColDefCallback, GridPivotModel } from "../pivoting/gridPivotingInterfaces.js";
|
|
5
5
|
import type { GridGetRowsResponsePivotColumn } from "./models.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { CellEditableConditionFn } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
5
5
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { CellEditableConditionFn } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
5
5
|
/**
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import type * as Excel from '@mui/x-internal-exceljs-fork';
|
|
2
2
|
import type { RefObject } from '@mui/x-internals/types';
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
3
|
+
import type { GridRowId, GridColDef } from '@mui/x-data-grid-pro';
|
|
4
|
+
import type { GridStateColDef } from '@mui/x-data-grid/internals';
|
|
5
5
|
import type { ColumnsStylesInterface, GridExcelExportOptions } from "../gridExcelExportInterface.mjs";
|
|
6
6
|
import type { GridPrivateApiPremium } from "../../../../models/gridApiPremium.mjs";
|
|
7
|
-
import {
|
|
7
|
+
import type { SerializedColumns, SerializedRow, ValueOptionsData } from "./utils.mjs";
|
|
8
8
|
export type { ExcelExportInitEvent } from "./utils.mjs";
|
|
9
9
|
/**
|
|
10
10
|
* FIXME: This function mutates the colspan info, but colspan info assumes that the columns
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import type * as Excel from '@mui/x-internal-exceljs-fork';
|
|
2
2
|
import type { RefObject } from '@mui/x-internals/types';
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
3
|
+
import type { GridRowId, GridColDef } from '@mui/x-data-grid-pro';
|
|
4
|
+
import type { GridStateColDef } from '@mui/x-data-grid/internals';
|
|
5
5
|
import type { ColumnsStylesInterface, GridExcelExportOptions } from "../gridExcelExportInterface.js";
|
|
6
6
|
import type { GridPrivateApiPremium } from "../../../../models/gridApiPremium.js";
|
|
7
|
-
import {
|
|
7
|
+
import type { SerializedColumns, SerializedRow, ValueOptionsData } from "./utils.js";
|
|
8
8
|
export type { ExcelExportInitEvent } from "./utils.js";
|
|
9
9
|
/**
|
|
10
10
|
* FIXME: This function mutates the colspan info, but colspan info assumes that the columns
|
|
@@ -116,9 +116,9 @@ const serializeRowUnsafe = (id, columns, apiRef, defaultValueOptionsFormulae, op
|
|
|
116
116
|
}
|
|
117
117
|
}
|
|
118
118
|
if ((0, _internals.isObject)(formattedValue)) {
|
|
119
|
-
|
|
119
|
+
cellValue = formattedValue?.label;
|
|
120
120
|
} else {
|
|
121
|
-
|
|
121
|
+
cellValue = formattedValue;
|
|
122
122
|
}
|
|
123
123
|
break;
|
|
124
124
|
}
|
|
@@ -105,9 +105,9 @@ export const serializeRowUnsafe = (id, columns, apiRef, defaultValueOptionsFormu
|
|
|
105
105
|
}
|
|
106
106
|
}
|
|
107
107
|
if (isObject(formattedValue)) {
|
|
108
|
-
|
|
108
|
+
cellValue = formattedValue?.label;
|
|
109
109
|
} else {
|
|
110
|
-
|
|
110
|
+
cellValue = formattedValue;
|
|
111
111
|
}
|
|
112
112
|
break;
|
|
113
113
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
5
5
|
export declare const historyStateInitializer: GridStateInitializer;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
5
5
|
export declare const historyStateInitializer: GridStateInitializer;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { GridColDef, GridRowModel } from '@mui/x-data-grid-pro';
|
|
2
2
|
import type { RefObject } from '@mui/x-internals/types';
|
|
3
|
-
import {
|
|
3
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
5
5
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
6
6
|
export declare const pivotingStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'pivotActive' | 'pivotModel' | 'pivotPanelOpen' | 'initialState' | 'disablePivoting' | 'getPivotDerivedColumns' | 'columns'>, GridPrivateApiPremium>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { GridColDef, GridRowModel } from '@mui/x-data-grid-pro';
|
|
2
2
|
import type { RefObject } from '@mui/x-internals/types';
|
|
3
|
-
import {
|
|
3
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
5
5
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
6
6
|
export declare const pivotingStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'pivotActive' | 'pivotModel' | 'pivotPanelOpen' | 'initialState' | 'disablePivoting' | 'getPivotDerivedColumns' | 'columns'>, GridPrivateApiPremium>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { GridColDef, GridRowModel, GridLocaleTextApi } from '@mui/x-data-grid-pro';
|
|
2
2
|
import type { RefObject } from '@mui/x-internals/types';
|
|
3
3
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
4
4
|
import type { GridApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { GridColDef, GridRowModel, GridLocaleTextApi } from '@mui/x-data-grid-pro';
|
|
2
2
|
import type { RefObject } from '@mui/x-internals/types';
|
|
3
3
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
4
4
|
import type { GridApiPremium } from "../../../models/gridApiPremium.js";
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import type { GridColDef, GridGroupingColDefOverride } from '@mui/x-data-grid-pro';
|
|
3
|
+
import { RowGroupingStrategy } from '@mui/x-data-grid-pro/internals';
|
|
4
|
+
import type { GridColumnRawLookup } from '@mui/x-data-grid-pro/internals';
|
|
4
5
|
import type { GridApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
5
6
|
import type { GridRowGroupingModel } from "./gridRowGroupingInterfaces.mjs";
|
|
6
7
|
interface CreateGroupingColDefMonoCriteriaParams {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import type { GridColDef, GridGroupingColDefOverride } from '@mui/x-data-grid-pro';
|
|
3
|
+
import { RowGroupingStrategy } from '@mui/x-data-grid-pro/internals';
|
|
4
|
+
import type { GridColumnRawLookup } from '@mui/x-data-grid-pro/internals';
|
|
4
5
|
import type { GridApiPremium } from "../../../models/gridApiPremium.js";
|
|
5
6
|
import type { GridRowGroupingModel } from "./gridRowGroupingInterfaces.js";
|
|
6
7
|
interface CreateGroupingColDefMonoCriteriaParams {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
2
|
import type { GridRowTreeConfig, GridFilterState, GridFilterModel, GridRowModel, GridColDef, GridKeyValue, GridDataSource } from '@mui/x-data-grid-pro';
|
|
3
|
-
import {
|
|
3
|
+
import { GRID_ROW_GROUPING_SINGLE_GROUPING_FIELD, getRowGroupingCriteriaFromGroupingField, isGroupingColumn, RowGroupingStrategy } from '@mui/x-data-grid-pro/internals';
|
|
4
|
+
import type { GridAggregatedFilterItemApplier, GridColumnRawLookup } from '@mui/x-data-grid-pro/internals';
|
|
4
5
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
5
6
|
import type { GridGroupingRule, GridGroupingRules, GridRowGroupingModel } from "./gridRowGroupingInterfaces.mjs";
|
|
6
7
|
import type { GridStatePremium } from "../../../models/gridStatePremium.mjs";
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
2
|
import type { GridRowTreeConfig, GridFilterState, GridFilterModel, GridRowModel, GridColDef, GridKeyValue, GridDataSource } from '@mui/x-data-grid-pro';
|
|
3
|
-
import {
|
|
3
|
+
import { GRID_ROW_GROUPING_SINGLE_GROUPING_FIELD, getRowGroupingCriteriaFromGroupingField, isGroupingColumn, RowGroupingStrategy } from '@mui/x-data-grid-pro/internals';
|
|
4
|
+
import type { GridAggregatedFilterItemApplier, GridColumnRawLookup } from '@mui/x-data-grid-pro/internals';
|
|
4
5
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
5
6
|
import type { GridGroupingRule, GridGroupingRules, GridRowGroupingModel } from "./gridRowGroupingInterfaces.js";
|
|
6
7
|
import type { GridStatePremium } from "../../../models/gridStatePremium.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
5
5
|
export declare const rowGroupingStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'rowGroupingModel' | 'initialState'>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
4
4
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
5
5
|
export declare const rowGroupingStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'rowGroupingModel' | 'initialState'>>;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { BaseReorderOperation
|
|
1
|
+
import { BaseReorderOperation } from '@mui/x-data-grid-pro/internals';
|
|
2
|
+
import type { ReorderOperation, ReorderExecutionContext } from '@mui/x-data-grid-pro/internals';
|
|
2
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
3
4
|
type ReorderExecutionContextType = ReorderExecutionContext<GridPrivateApiPremium>;
|
|
4
5
|
/**
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { BaseReorderOperation
|
|
1
|
+
import { BaseReorderOperation } from '@mui/x-data-grid-pro/internals';
|
|
2
|
+
import type { ReorderOperation, ReorderExecutionContext } from '@mui/x-data-grid-pro/internals';
|
|
2
3
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
3
4
|
type ReorderExecutionContextType = ReorderExecutionContext<GridPrivateApiPremium>;
|
|
4
5
|
/**
|
|
@@ -17,12 +17,12 @@ const useGridParamsOverridableMethods = apiRef => {
|
|
|
17
17
|
})?.value ?? communityMethods.getCellValue(id, field), [apiRef, communityMethods]);
|
|
18
18
|
const getRowValue = React.useCallback((row, colDef) => (0, _gridAggregationSelectors.gridCellAggregationResultSelector)(apiRef, {
|
|
19
19
|
id: (0, _xDataGridPro.gridRowIdSelector)(apiRef, row),
|
|
20
|
-
field: colDef
|
|
20
|
+
field: colDef?.field
|
|
21
21
|
})?.value ?? communityMethods.getRowValue(row, colDef), [apiRef, communityMethods]);
|
|
22
22
|
const getRowFormattedValue = React.useCallback((row, colDef) => {
|
|
23
23
|
const aggregationFormattedValue = (0, _gridAggregationSelectors.gridCellAggregationResultSelector)(apiRef, {
|
|
24
24
|
id: (0, _xDataGridPro.gridRowIdSelector)(apiRef, row),
|
|
25
|
-
field: colDef
|
|
25
|
+
field: colDef?.field
|
|
26
26
|
})?.formattedValue;
|
|
27
27
|
if (aggregationFormattedValue !== undefined) {
|
|
28
28
|
return aggregationFormattedValue;
|
|
@@ -10,12 +10,12 @@ export const useGridParamsOverridableMethods = apiRef => {
|
|
|
10
10
|
})?.value ?? communityMethods.getCellValue(id, field), [apiRef, communityMethods]);
|
|
11
11
|
const getRowValue = React.useCallback((row, colDef) => gridCellAggregationResultSelector(apiRef, {
|
|
12
12
|
id: gridRowIdSelector(apiRef, row),
|
|
13
|
-
field: colDef
|
|
13
|
+
field: colDef?.field
|
|
14
14
|
})?.value ?? communityMethods.getRowValue(row, colDef), [apiRef, communityMethods]);
|
|
15
15
|
const getRowFormattedValue = React.useCallback((row, colDef) => {
|
|
16
16
|
const aggregationFormattedValue = gridCellAggregationResultSelector(apiRef, {
|
|
17
17
|
id: gridRowIdSelector(apiRef, row),
|
|
18
|
-
field: colDef
|
|
18
|
+
field: colDef?.field
|
|
19
19
|
})?.formattedValue;
|
|
20
20
|
if (aggregationFormattedValue !== undefined) {
|
|
21
21
|
return aggregationFormattedValue;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.mjs";
|
|
4
4
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.mjs";
|
|
5
5
|
export declare const sidebarStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'initialState'>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridStateInitializer } from '@mui/x-data-grid-pro/internals';
|
|
3
3
|
import type { DataGridPremiumProcessedProps } from "../../../models/dataGridPremiumProps.js";
|
|
4
4
|
import type { GridPrivateApiPremium } from "../../../models/gridApiPremium.js";
|
|
5
5
|
export declare const sidebarStateInitializer: GridStateInitializer<Pick<DataGridPremiumProcessedProps, 'initialState'>>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridApiCommon } from '@mui/x-data-grid';
|
|
3
3
|
import type { GridApiPremium } from "../../models/gridApiPremium.mjs";
|
|
4
4
|
export declare const useGridApiContext: <Api extends GridApiCommon = GridApiPremium>() => RefObject<Api>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridApiCommon } from '@mui/x-data-grid';
|
|
3
3
|
import type { GridApiPremium } from "../../models/gridApiPremium.js";
|
|
4
4
|
export declare const useGridApiContext: <Api extends GridApiCommon = GridApiPremium>() => RefObject<Api>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridApi } from '@mui/x-data-grid-pro';
|
|
3
3
|
import type { GridInitialStatePremium } from "../../models/gridStatePremium.mjs";
|
|
4
4
|
import type { DataGridPremiumProps } from "../../models/dataGridPremiumProps.mjs";
|
|
5
5
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RefObject } from '@mui/x-internals/types';
|
|
2
|
-
import {
|
|
2
|
+
import type { GridApi } from '@mui/x-data-grid-pro';
|
|
3
3
|
import type { GridInitialStatePremium } from "../../models/gridStatePremium.js";
|
|
4
4
|
import type { DataGridPremiumProps } from "../../models/dataGridPremiumProps.js";
|
|
5
5
|
/**
|