@redsift/table 11.3.1-alpha.1 → 11.3.1-muiv5
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/index.d.ts +32 -26
- package/index.js +400 -289
- package/index.js.map +1 -1
- package/package.json +4 -4
package/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _mui_x_data_grid_pro from '@mui/x-data-grid-pro';
|
|
2
|
-
import { GridColumnTypesRecord, GridFilterItem, GridCellParams, GridFilterOperator, GridFilterInputValue, GridFilterInputMultipleValue, DataGridProProps, GridFilterModel,
|
|
3
|
-
export { GridAlignment, GridColDef, GridFilterItem, GridFilterModel, getGridBooleanOperators, getGridDateOperators, getGridSingleSelectOperators } from '@mui/x-data-grid-pro';
|
|
2
|
+
import { GridNativeColTypes, GridColumnTypesRecord, GridFilterItem, GridCellParams, GridFilterOperator, GridFilterInputValue, GridFilterInputMultipleValue, DataGridProProps, GridFilterModel, GridSortModel, GridSortItem, GridColumnVisibilityModel, GridPinnedColumns, GridSlotsComponent, GridSelectionModel, GridRowParams, GridToolbarExportProps, GridToolbarFilterButtonProps, GridToolbarColumnsButton, GridToolbarDensitySelector } from '@mui/x-data-grid-pro';
|
|
3
|
+
export { GridAlignment, GridColDef, GridColumns, GridFilterItem, GridFilterModel, GridSelectionModel, getGridBooleanOperators, getGridDateOperators, getGridSingleSelectOperators } from '@mui/x-data-grid-pro';
|
|
4
4
|
import { GridInitialStatePro } from '@mui/x-data-grid-pro/models/gridStatePro';
|
|
5
5
|
import React, { ReactNode, ComponentProps, MutableRefObject, RefObject } from 'react';
|
|
6
6
|
import { TablePaginationProps } from '@mui/material';
|
|
@@ -10,19 +10,19 @@ import { GridApiPro } from '@mui/x-data-grid-pro/models/gridApiPro';
|
|
|
10
10
|
declare const DETAIL_PANEL_TOGGLE_COL_DEF: _mui_x_data_grid_pro.GridColDef<any, any, any>;
|
|
11
11
|
|
|
12
12
|
declare const getRsStringColumnType: () => {
|
|
13
|
-
|
|
13
|
+
extendType: GridNativeColTypes;
|
|
14
14
|
filterOperators: _mui_x_data_grid_pro.GridFilterOperator<any, string | number | null, any>[];
|
|
15
15
|
};
|
|
16
16
|
declare const getRsNumberColumnType: () => {
|
|
17
|
-
|
|
17
|
+
extendType: GridNativeColTypes;
|
|
18
18
|
filterOperators: _mui_x_data_grid_pro.GridFilterOperator<any, string | number | null, any>[];
|
|
19
19
|
};
|
|
20
|
-
declare const customColumnTypes:
|
|
20
|
+
declare const customColumnTypes: GridColumnTypesRecord;
|
|
21
21
|
|
|
22
22
|
declare const IS_BETWEEN: {
|
|
23
23
|
label: string;
|
|
24
24
|
value: string;
|
|
25
|
-
getApplyFilterFn: (filterItem: GridFilterItem) => ((params: GridCellParams
|
|
25
|
+
getApplyFilterFn: (filterItem: GridFilterItem) => ((params: GridCellParams) => boolean) | null;
|
|
26
26
|
InputComponent: (props: any) => JSX.Element;
|
|
27
27
|
};
|
|
28
28
|
|
|
@@ -91,8 +91,8 @@ declare const operatorList: {
|
|
|
91
91
|
string: _mui_x_data_grid_pro.GridFilterOperator<any, string | number | null, any>[];
|
|
92
92
|
number: _mui_x_data_grid_pro.GridFilterOperator<any, string | number | null, any>[];
|
|
93
93
|
boolean: _mui_x_data_grid_pro.GridFilterOperator<any, boolean | null, any>[];
|
|
94
|
-
date: _mui_x_data_grid_pro.GridFilterOperator<any, Date, any>[];
|
|
95
|
-
dateTime: _mui_x_data_grid_pro.GridFilterOperator<any, Date, any>[];
|
|
94
|
+
date: _mui_x_data_grid_pro.GridFilterOperator<any, string | Date, any>[];
|
|
95
|
+
dateTime: _mui_x_data_grid_pro.GridFilterOperator<any, string | Date, any>[];
|
|
96
96
|
singleSelect: _mui_x_data_grid_pro.GridFilterOperator<any, any, any>[];
|
|
97
97
|
rsString: _mui_x_data_grid_pro.GridFilterOperator<any, string | number | null, any>[];
|
|
98
98
|
rsNumber: _mui_x_data_grid_pro.GridFilterOperator<any, string | number | null, any>[];
|
|
@@ -166,7 +166,9 @@ declare const StatefulDataGrid: Comp<StatefulDataGridProps, HTMLDivElement>;
|
|
|
166
166
|
interface ExtendedGridFilterModel extends GridFilterModel {
|
|
167
167
|
quickFilterValues?: string[];
|
|
168
168
|
}
|
|
169
|
-
interface ExtendedGridPaginationModel
|
|
169
|
+
interface ExtendedGridPaginationModel {
|
|
170
|
+
page: number;
|
|
171
|
+
pageSize: number;
|
|
170
172
|
direction?: 'next' | 'back';
|
|
171
173
|
}
|
|
172
174
|
|
|
@@ -176,8 +178,6 @@ declare const encodeValue: (value: string | undefined) => string;
|
|
|
176
178
|
declare const urlSearchParamsToString: (searchParams: URLSearchParams) => string;
|
|
177
179
|
declare const numberOperatorEncoder: Record<string, string>;
|
|
178
180
|
declare const numberOperatorDecoder: Record<string, string>;
|
|
179
|
-
declare const isOperatorValueValid: (field: string, operator: OperatorValue, columns: DataGridProps['columns']) => boolean;
|
|
180
|
-
declare const isValueValid: (value: OperatorValue, field: string, columns: DataGridProps['columns'], operator: OperatorValue) => boolean;
|
|
181
181
|
/** FILTERS */
|
|
182
182
|
declare const getFilterModelFromString: (searchString: string, columns: DataGridProps['columns']) => ExtendedGridFilterModel | 'invalid';
|
|
183
183
|
declare const getSearchParamsFromFilterModel: (filterModel: ExtendedGridFilterModel) => URLSearchParams;
|
|
@@ -188,8 +188,8 @@ declare const getSearchParamsFromSorting: (sorting: GridSortItem[]) => URLSearch
|
|
|
188
188
|
declare const getPaginationFromString: (searchString: string) => ExtendedGridPaginationModel | 'invalid';
|
|
189
189
|
declare const getSearchParamsFromPagination: (pagination: ExtendedGridPaginationModel) => URLSearchParams;
|
|
190
190
|
/** COLUMN VISIBILITY */
|
|
191
|
-
declare const getColumnVisibilityFromString: (searchString: string, columns: DataGridProps['columns']) => GridColumnVisibilityModel | 'invalid';
|
|
192
191
|
declare const getSearchParamsFromColumnVisibility: (columnVisibility: GridColumnVisibilityModel, columns: DataGridProps['columns']) => URLSearchParams;
|
|
192
|
+
declare const getColumnVisibilityFromString: (notParsed: string, tableColumns: DataGridProps['columns']) => GridColumnVisibilityModel | 'invalid';
|
|
193
193
|
declare const getPinnedColumnsFromString: (notParsed: string, tableColumns: DataGridProps['columns']) => PinnedColumns | 'invalid';
|
|
194
194
|
declare const getSearchParamsFromPinnedColumns: (pinnedColumns: GridPinnedColumns) => URLSearchParams;
|
|
195
195
|
declare const getSearchParamsFromTab: (search: string) => URLSearchParams;
|
|
@@ -251,12 +251,12 @@ declare const BasePopper: React.JSXElementConstructor<any>;
|
|
|
251
251
|
declare const BaseTextField: React.JSXElementConstructor<any>;
|
|
252
252
|
|
|
253
253
|
interface CompletionResponseItem {
|
|
254
|
-
|
|
255
|
-
|
|
254
|
+
columnField: string;
|
|
255
|
+
operatorValue: string;
|
|
256
256
|
value?: string;
|
|
257
257
|
}
|
|
258
258
|
type CompletionResponse = {
|
|
259
|
-
|
|
259
|
+
linkOperator: 'and' | 'or';
|
|
260
260
|
items: CompletionResponseItem[];
|
|
261
261
|
};
|
|
262
262
|
interface LocaleText {
|
|
@@ -302,9 +302,11 @@ type ControlledPaginationProps = {
|
|
|
302
302
|
displayPagination?: boolean;
|
|
303
303
|
selectionStatus: SelectionStatus;
|
|
304
304
|
apiRef: MutableRefObject<GridApiPro>;
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
305
|
+
page: number;
|
|
306
|
+
onPageChange: (page: number) => void;
|
|
307
|
+
pageSize: number;
|
|
308
|
+
onPageSizeChange: (pageSize: number) => void;
|
|
309
|
+
rowsPerPageOptions?: number[];
|
|
308
310
|
isRowSelectable?: DataGridProps['isRowSelectable'];
|
|
309
311
|
paginationProps?: DataGridProps['paginationProps'];
|
|
310
312
|
};
|
|
@@ -315,14 +317,16 @@ type ServerSideControlledPaginationProps = {
|
|
|
315
317
|
displayRowsPerPage?: boolean;
|
|
316
318
|
displayPagination?: boolean;
|
|
317
319
|
selectionStatus: SelectionStatus;
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
320
|
+
page: number;
|
|
321
|
+
onPageChange: (page: number) => void;
|
|
322
|
+
pageSize: number;
|
|
323
|
+
onPageSizeChange: (pageSize: number) => void;
|
|
324
|
+
rowsPerPageOptions?: number[];
|
|
321
325
|
paginationProps?: DataGridProps['paginationProps'];
|
|
322
326
|
rowCount: number;
|
|
323
327
|
loading?: boolean;
|
|
324
328
|
};
|
|
325
|
-
declare const onServerSideSelectionStatusChange: (newSelectionModel:
|
|
329
|
+
declare const onServerSideSelectionStatusChange: (newSelectionModel: GridSelectionModel, apiRef: React.MutableRefObject<GridApiPro>, selectionStatus: React.MutableRefObject<SelectionStatus>, isRowSelectable: ((params: GridRowParams<any>) => boolean) | undefined, page: number, pageSize: number) => void;
|
|
326
330
|
declare const ServerSideControlledPagination: React.FC<ServerSideControlledPaginationProps>;
|
|
327
331
|
|
|
328
332
|
interface TextCellProps extends ComponentProps<'div'> {
|
|
@@ -412,13 +416,15 @@ type ToolbarWrapperProps = {
|
|
|
412
416
|
selectionStatus: React.MutableRefObject<SelectionStatus>;
|
|
413
417
|
apiRef: DataGridProps['apiRef'];
|
|
414
418
|
isRowSelectable: DataGridProps['isRowSelectable'];
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
419
|
+
page: DataGridProps['page'];
|
|
420
|
+
onPageChange: DataGridProps['onPageChange'];
|
|
421
|
+
pageSize: DataGridProps['pageSize'];
|
|
422
|
+
onPageSizeChange: DataGridProps['onPageSizeChange'];
|
|
423
|
+
rowsPerPageOptions: DataGridProps['rowsPerPageOptions'];
|
|
418
424
|
paginationProps: DataGridProps['paginationProps'];
|
|
419
425
|
paginationMode?: DataGridProps['paginationMode'];
|
|
420
426
|
rowCount?: DataGridProps['rowCount'];
|
|
421
427
|
};
|
|
422
428
|
declare const ToolbarWrapper: React.FC<ToolbarWrapperProps>;
|
|
423
429
|
|
|
424
|
-
export { BaseButton, BaseCheckbox, BaseIcon, BasePopper, BaseTextField, CATEGORIES, CONTAINS_ANY_OF, CONTAINS_ANY_OF_I, Category, CompletionResponse, ControlledPagination, ControlledPaginationProps, DEFAULT_OPERATORS, DETAIL_PANEL_TOGGLE_COL_DEF, DIMENSION_MODEL_KEY, DOES_NOT_CONTAIN, DOES_NOT_EQUAL, DataGrid, DataGridModel, DataGridProps, ENDS_WITH_ANY_OF, FILTER_MODEL_KEY, FILTER_SEARCH_KEY, FilterConfig, GridToolbarFilterSemanticField, GridToolbarFilterSemanticFieldProps, IS_ANY_OF, IS_BETWEEN, IS_NOT_ANY_OF, PAGINATION_MODEL_KEY, PINNED_COLUMNS, PinnedColumns, SORT_MODEL_KEY, STARTS_WITH_ANY_OF, SelectionStatus, ServerSideControlledPagination, ServerSideControlledPaginationProps, StatefulDataGrid, StatefulDataGridProps, StyledDataGridProps, TextCell, Toolbar, ToolbarWrapper, ToolbarWrapperProps, VISIBILITY_MODEL_KEY, areFilterModelsEquivalent, buildStorageKey, clearPreviousVersionStorage, customColumnTypes, decodeValue, encodeValue, getColumnVisibilityFromString, getCompletion, getFilterModelFromString, getFinalSearch, getGridNumericOperators, getGridStringArrayOperators, getGridStringOperators, getModelsParsedOrUpdateLocalStorage, getPaginationFromString, getPinnedColumnsFromString, getRsNumberColumnType, getRsStringColumnType, getSearchParamsFromColumnVisibility, getSearchParamsFromFilterModel, getSearchParamsFromPagination, getSearchParamsFromPinnedColumns, getSearchParamsFromSorting, getSearchParamsFromTab, getSortingFromString,
|
|
430
|
+
export { BaseButton, BaseCheckbox, BaseIcon, BasePopper, BaseTextField, CATEGORIES, CONTAINS_ANY_OF, CONTAINS_ANY_OF_I, Category, CompletionResponse, ControlledPagination, ControlledPaginationProps, DEFAULT_OPERATORS, DETAIL_PANEL_TOGGLE_COL_DEF, DIMENSION_MODEL_KEY, DOES_NOT_CONTAIN, DOES_NOT_EQUAL, DataGrid, DataGridModel, DataGridProps, ENDS_WITH_ANY_OF, FILTER_MODEL_KEY, FILTER_SEARCH_KEY, FilterConfig, GridToolbarFilterSemanticField, GridToolbarFilterSemanticFieldProps, IS_ANY_OF, IS_BETWEEN, IS_NOT_ANY_OF, PAGINATION_MODEL_KEY, PINNED_COLUMNS, PinnedColumns, SORT_MODEL_KEY, STARTS_WITH_ANY_OF, SelectionStatus, ServerSideControlledPagination, ServerSideControlledPaginationProps, StatefulDataGrid, StatefulDataGridProps, StyledDataGridProps, TextCell, Toolbar, ToolbarWrapper, ToolbarWrapperProps, VISIBILITY_MODEL_KEY, areFilterModelsEquivalent, buildStorageKey, clearPreviousVersionStorage, customColumnTypes, decodeValue, encodeValue, getColumnVisibilityFromString, getCompletion, getFilterModelFromString, getFinalSearch, getGridNumericOperators, getGridStringArrayOperators, getGridStringOperators, getModelsParsedOrUpdateLocalStorage, getPaginationFromString, getPinnedColumnsFromString, getRsNumberColumnType, getRsStringColumnType, getSearchParamsFromColumnVisibility, getSearchParamsFromFilterModel, getSearchParamsFromPagination, getSearchParamsFromPinnedColumns, getSearchParamsFromSorting, getSearchParamsFromTab, getSortingFromString, muiIconToDSIcon, numberOperatorDecoder, numberOperatorEncoder, onServerSideSelectionStatusChange, operatorList, updateUrl, urlSearchParamsToString };
|