@@ -5,16 +5,12 @@ import { forwardRef } from '@mui/x-internals/forwardRef';
5
5
import { GridRoot } from '../components' ;
6
6
import { useGridAriaAttributes } from '../hooks/utils/useGridAriaAttributes' ;
7
7
import { useGridRowAriaAttributes } from '../hooks/features/rows/useGridRowAriaAttributes' ;
8
- import { DataGridProcessedProps , DataGridProps } from '../models/props/DataGridProps' ;
8
+ import { DataGridProps } from '../models/props/DataGridProps' ;
9
9
import { GridContextProvider } from '../context/GridContextProvider' ;
10
10
import { useDataGridComponent } from './useDataGridComponent' ;
11
11
import { useDataGridProps } from './useDataGridProps' ;
12
12
import { GridValidRowModel } from '../models/gridRows' ;
13
- import {
14
- PropValidator ,
15
- propValidatorsDataGrid ,
16
- validateProps ,
17
- } from '../internals/utils/propValidation' ;
13
+ import { propValidatorsDataGrid , validateProps } from '../internals/utils/propValidation' ;
18
14
19
15
export type { GridSlotsComponent as GridSlots } from '../models' ;
20
16
@@ -24,24 +20,6 @@ const configuration = {
24
20
useGridRowAriaAttributes,
25
21
} ,
26
22
} ;
27
- let propValidators : PropValidator < DataGridProcessedProps > [ ] ;
28
-
29
- if ( process . env . NODE_ENV !== 'production' ) {
30
- propValidators = [
31
- ...propValidatorsDataGrid ,
32
- // Only validate in MIT version
33
- ( props ) =>
34
- ( props . columns &&
35
- props . columns . some ( ( column ) => column . resizable ) &&
36
- [
37
- `MUI X: \`column.resizable = true\` is not a valid prop.` ,
38
- 'Column resizing is not available in the MIT version.' ,
39
- '' ,
40
- 'You need to upgrade to DataGridPro or DataGridPremium component to unlock this feature.' ,
41
- ] . join ( '\n' ) ) ||
42
- undefined ,
43
- ] ;
44
- }
45
23
46
24
const DataGridRaw = forwardRef ( function DataGrid < R extends GridValidRowModel > (
47
25
inProps : DataGridProps < R > ,
@@ -51,7 +29,7 @@ const DataGridRaw = forwardRef(function DataGrid<R extends GridValidRowModel>(
51
29
const privateApiRef = useDataGridComponent ( props . apiRef , props ) ;
52
30
53
31
if ( process . env . NODE_ENV !== 'production' ) {
54
- validateProps ( props , propValidators ) ;
32
+ validateProps ( props , propValidatorsDataGrid ) ;
55
33
}
56
34
return (
57
35
< GridContextProvider privateApiRef = { privateApiRef } configuration = { configuration } props = { props } >
0 commit comments