@mdtl/uikit 0.0.71 → 0.0.73
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/dist/components/Table/BasicTable.d.ts +0 -9
- package/dist/components/Table/Cell/Cell.d.ts +1 -2
- package/dist/components/Table/Cell/CellColumnContent.d.ts +1 -2
- package/dist/components/Table/Cell/ItemActions.d.ts +1 -2
- package/dist/components/Table/Cell/RowCell.d.ts +1 -2
- package/dist/components/Table/Cell/TileCell.d.ts +1 -2
- package/dist/components/Table/Row/DraggableRow.d.ts +1 -2
- package/dist/components/Table/Row/Row.d.ts +1 -2
- package/dist/components/Table/Row/TableRowWrapper.d.ts +1 -2
- package/dist/components/Table/TableHeader.d.ts +1 -2
- package/dist/components/Table/TableHeaderCell.d.ts +1 -2
- package/dist/components/Table/interfaces/interfaces.d.ts +72 -56
- package/dist/components/Table/utils/util.d.ts +2 -1
- package/dist/themes/aps/augmentation.d.ts +31 -0
- package/dist/themes/aps/controls/configs/toggleButton.d.ts +40 -20
- package/dist/themes/aps/controls/configs/toggleButtonGroup.d.ts +17 -1
- package/dist/uikit.js +4973 -4870
- package/package.json +1 -1
|
@@ -18,15 +18,6 @@ declare module '@tanstack/table-core' {
|
|
|
18
18
|
folder?: any;
|
|
19
19
|
}
|
|
20
20
|
}
|
|
21
|
-
export interface AdditionalRowFields {
|
|
22
|
-
hasChildren?: boolean;
|
|
23
|
-
parentId?: string;
|
|
24
|
-
level?: number;
|
|
25
|
-
subRows?: any;
|
|
26
|
-
isDragDisabled?: boolean;
|
|
27
|
-
nodeType?: number;
|
|
28
|
-
field?: string;
|
|
29
|
-
}
|
|
30
21
|
/**
|
|
31
22
|
* Содержимое таблицы
|
|
32
23
|
* @param props
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
-
import { ICellProps } from '../interfaces/interfaces';
|
|
3
|
-
import { AdditionalRowFields } from '../BasicTable';
|
|
2
|
+
import { AdditionalRowFields, ICellProps } from '../interfaces/interfaces';
|
|
4
3
|
/**
|
|
5
4
|
* Перетаскиваемая строка
|
|
6
5
|
* @param props
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
-
import { ICellColumnProps, THeadCellType } from '../interfaces/interfaces';
|
|
3
|
-
import { AdditionalRowFields } from '../BasicTable';
|
|
2
|
+
import { AdditionalRowFields, ICellColumnProps, THeadCellType } from '../interfaces/interfaces';
|
|
4
3
|
declare module '@mui/material/OutlinedInput' {
|
|
5
4
|
interface OutlinedInputProps {
|
|
6
5
|
type?: THeadCellType;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
import { IItemActionsProps } from '../interfaces/interfaces';
|
|
3
|
-
import { AdditionalRowFields } from '../BasicTable';
|
|
2
|
+
import { AdditionalRowFields, IItemActionsProps } from '../interfaces/interfaces';
|
|
4
3
|
/**
|
|
5
4
|
* Действия над записью
|
|
6
5
|
* @param props
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
-
import { IRowCellProps } from '../interfaces/interfaces';
|
|
3
|
-
import { AdditionalRowFields } from '../BasicTable';
|
|
2
|
+
import { AdditionalRowFields, IRowCellProps } from '../interfaces/interfaces';
|
|
4
3
|
/**
|
|
5
4
|
* Ячейки таблицы, образующие строку
|
|
6
5
|
* @param props
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
import { ITillCellProps } from '../interfaces/interfaces';
|
|
3
|
-
import { AdditionalRowFields } from '../BasicTable';
|
|
2
|
+
import { AdditionalRowFields, ITillCellProps } from '../interfaces/interfaces';
|
|
4
3
|
/**
|
|
5
4
|
* Плоская ячейка-плитка
|
|
6
5
|
* @param props
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
-
import { ITableRowProps } from '../interfaces/interfaces';
|
|
3
|
-
import { AdditionalRowFields } from '../BasicTable';
|
|
2
|
+
import { AdditionalRowFields, ITableRowProps } from '../interfaces/interfaces';
|
|
4
3
|
/**
|
|
5
4
|
* Перетаскиваемая строка
|
|
6
5
|
* @param props
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
-
import { ITableRowProps } from '../interfaces/interfaces';
|
|
3
|
-
import { AdditionalRowFields } from '../BasicTable';
|
|
2
|
+
import { AdditionalRowFields, ITableRowProps } from '../interfaces/interfaces';
|
|
4
3
|
export declare const Row: TableRowComponent;
|
|
5
4
|
type TableRowComponent = <TData extends AdditionalRowFields>(props: ITableRowProps<TData>) => JSX.Element;
|
|
6
5
|
export {};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
-
import { ITableRowWrapperProps } from '../interfaces/interfaces';
|
|
3
|
-
import { AdditionalRowFields } from '../BasicTable';
|
|
2
|
+
import { AdditionalRowFields, ITableRowWrapperProps } from '../interfaces/interfaces';
|
|
4
3
|
/**
|
|
5
4
|
* Обертка для строки, которая определяет будет строка draggable или обычной
|
|
6
5
|
* @param props
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
import { ITableHeaderProps } from './interfaces/interfaces';
|
|
3
|
-
import { AdditionalRowFields } from './BasicTable';
|
|
2
|
+
import { AdditionalRowFields, ITableHeaderProps } from './interfaces/interfaces';
|
|
4
3
|
/**
|
|
5
4
|
* Шапка таблицы
|
|
6
5
|
* @param props
|
|
@@ -1,4 +1,3 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
import { ITableHeaderCell } from './interfaces/interfaces';
|
|
3
|
-
import { AdditionalRowFields } from './BasicTable';
|
|
2
|
+
import { AdditionalRowFields, ITableHeaderCell } from './interfaces/interfaces';
|
|
4
3
|
export declare const TableHeaderCell: <TData extends AdditionalRowFields>(props: ITableHeaderCell<TData>) => React.JSX.Element;
|
|
@@ -42,7 +42,8 @@ export interface IHeadCell<TData> {
|
|
|
42
42
|
backgroundColorCallback?: (row: TData) => string | undefined;
|
|
43
43
|
/** используется в базовых колонках таблиц с шаблонами, чтобы поместить их в конец таблицы */
|
|
44
44
|
isLast?: boolean;
|
|
45
|
-
|
|
45
|
+
/** включение сортировки для колонки */
|
|
46
|
+
enableSorting?: boolean;
|
|
46
47
|
}
|
|
47
48
|
export interface IOperation {
|
|
48
49
|
id: string;
|
|
@@ -137,6 +138,8 @@ export interface ITableProps<TData> {
|
|
|
137
138
|
selectedKeysChangedCallback?: (selectedKeys: string[], selectedItems?: TData[]) => void;
|
|
138
139
|
/** выбранные строки */
|
|
139
140
|
selectedItems?: TData[];
|
|
141
|
+
/** идентификаторы строк с задизейбленными чекбоксами */
|
|
142
|
+
disabledKeys?: string[];
|
|
140
143
|
/** выбранная строка */
|
|
141
144
|
selectedRow?: (row: TData) => boolean;
|
|
142
145
|
/** показывает тултип для строки с выводом всех ее ячеек в транспонированном виде */
|
|
@@ -293,6 +296,63 @@ export interface ITableBodyProps<TData> {
|
|
|
293
296
|
highlightDragOverRow?: boolean;
|
|
294
297
|
columnOrder: string[];
|
|
295
298
|
onCellClick?: (info: ICellClickInfo) => void;
|
|
299
|
+
disabledKeys?: string[];
|
|
300
|
+
}
|
|
301
|
+
export interface ITableRowWrapperProps<TData> {
|
|
302
|
+
rowDraggable: boolean;
|
|
303
|
+
columnDraggable?: boolean;
|
|
304
|
+
itemKey: string;
|
|
305
|
+
row: Row<TData>;
|
|
306
|
+
rowIndex: number;
|
|
307
|
+
viewMode: ViewMode;
|
|
308
|
+
isEditedRow: boolean;
|
|
309
|
+
onStartRowEdit: (item: TData | null) => void;
|
|
310
|
+
onAcceptRowEdit: (event: React.MouseEvent<unknown>, item: TData) => void;
|
|
311
|
+
selected: boolean;
|
|
312
|
+
tableViewMode: TableViewMode;
|
|
313
|
+
adaptive: boolean;
|
|
314
|
+
inSearch: boolean;
|
|
315
|
+
inSelect: boolean;
|
|
316
|
+
selectedRow: (row: TData) => boolean;
|
|
317
|
+
resultColumns: IHeadCell<TData>[];
|
|
318
|
+
root: string;
|
|
319
|
+
editable: boolean;
|
|
320
|
+
level: number;
|
|
321
|
+
onClick: (TData: any) => void;
|
|
322
|
+
handleSelect: (item: any) => void;
|
|
323
|
+
rowBackgroundCallback: (row: TData) => string;
|
|
324
|
+
multiselectVisibility: MultiSelectType;
|
|
325
|
+
itemActions: IItemAction<TData>[];
|
|
326
|
+
keyProperty: string;
|
|
327
|
+
expanded: ExpandedState;
|
|
328
|
+
expandable: boolean;
|
|
329
|
+
handleExpand: (item: any, expandedState: any) => void;
|
|
330
|
+
itemActionsVisibilityCallback: (TData: any) => boolean;
|
|
331
|
+
onItemActionClick: (actionId: string, item: TData, data?: TData[]) => void;
|
|
332
|
+
isNodeDeterminate: boolean;
|
|
333
|
+
virtualization?: boolean;
|
|
334
|
+
virtualColumns?: VirtualItem[];
|
|
335
|
+
virtualIndexes: number[];
|
|
336
|
+
columnVirtualizerTotalSize?: number;
|
|
337
|
+
leftPinnedColumns: Column<TData, unknown>[];
|
|
338
|
+
rightPinnedColumns: Column<TData, unknown>[];
|
|
339
|
+
isClickHighlighted?: boolean;
|
|
340
|
+
overflowShadow: boolean;
|
|
341
|
+
virtualPaddingLeft?: number;
|
|
342
|
+
virtualPaddingRight?: number;
|
|
343
|
+
resetNewRow: () => void;
|
|
344
|
+
isNewRowCreated: boolean;
|
|
345
|
+
setIsNewRowCreated: React.Dispatch<React.SetStateAction<boolean>>;
|
|
346
|
+
showTransposedTooltip?: boolean;
|
|
347
|
+
itemActionsDisabledTooltip?: (row: TData) => string;
|
|
348
|
+
enableRowDragCallback?: (row: TData) => boolean;
|
|
349
|
+
enableDrop: boolean;
|
|
350
|
+
onItemClick?: (row: TData) => void;
|
|
351
|
+
highlightDragOverRow?: boolean;
|
|
352
|
+
name: string;
|
|
353
|
+
columnOrder: string[];
|
|
354
|
+
onCellClick?: (info: ICellClickInfo) => void;
|
|
355
|
+
disabledKeys?: string[];
|
|
296
356
|
}
|
|
297
357
|
export interface ITableRowProps<TData> {
|
|
298
358
|
name: string;
|
|
@@ -349,6 +409,7 @@ export interface ITableRowProps<TData> {
|
|
|
349
409
|
onItemClick?: (row: TData) => void;
|
|
350
410
|
columnOrder: string[];
|
|
351
411
|
onCellClick?: (info: ICellClickInfo) => void;
|
|
412
|
+
disabledKeys?: string[];
|
|
352
413
|
}
|
|
353
414
|
export interface IRowCellProps<TData> {
|
|
354
415
|
cells: Cell<TData, unknown>[];
|
|
@@ -389,61 +450,7 @@ export interface IRowCellProps<TData> {
|
|
|
389
450
|
isDragOver: boolean;
|
|
390
451
|
onCellClick?: (info: ICellClickInfo) => void;
|
|
391
452
|
isExpanded?: boolean;
|
|
392
|
-
|
|
393
|
-
export interface ITableRowWrapperProps<TData> {
|
|
394
|
-
rowDraggable: boolean;
|
|
395
|
-
columnDraggable?: boolean;
|
|
396
|
-
itemKey: string;
|
|
397
|
-
row: Row<TData>;
|
|
398
|
-
rowIndex: number;
|
|
399
|
-
viewMode: ViewMode;
|
|
400
|
-
isEditedRow: boolean;
|
|
401
|
-
onStartRowEdit: (item: TData | null) => void;
|
|
402
|
-
onAcceptRowEdit: (event: React.MouseEvent<unknown>, item: TData) => void;
|
|
403
|
-
selected: boolean;
|
|
404
|
-
tableViewMode: TableViewMode;
|
|
405
|
-
adaptive: boolean;
|
|
406
|
-
inSearch: boolean;
|
|
407
|
-
inSelect: boolean;
|
|
408
|
-
selectedRow: (row: TData) => boolean;
|
|
409
|
-
resultColumns: IHeadCell<TData>[];
|
|
410
|
-
root: string;
|
|
411
|
-
editable: boolean;
|
|
412
|
-
level: number;
|
|
413
|
-
onClick: (TData: any) => void;
|
|
414
|
-
handleSelect: (item: any) => void;
|
|
415
|
-
rowBackgroundCallback: (row: TData) => string;
|
|
416
|
-
multiselectVisibility: MultiSelectType;
|
|
417
|
-
itemActions: IItemAction<TData>[];
|
|
418
|
-
keyProperty: string;
|
|
419
|
-
expanded: ExpandedState;
|
|
420
|
-
expandable: boolean;
|
|
421
|
-
handleExpand: (item: any, expandedState: any) => void;
|
|
422
|
-
itemActionsVisibilityCallback: (TData: any) => boolean;
|
|
423
|
-
onItemActionClick: (actionId: string, item: TData, data?: TData[]) => void;
|
|
424
|
-
isNodeDeterminate: boolean;
|
|
425
|
-
virtualization?: boolean;
|
|
426
|
-
virtualColumns?: VirtualItem[];
|
|
427
|
-
virtualIndexes: number[];
|
|
428
|
-
columnVirtualizerTotalSize?: number;
|
|
429
|
-
leftPinnedColumns: Column<TData, unknown>[];
|
|
430
|
-
rightPinnedColumns: Column<TData, unknown>[];
|
|
431
|
-
isClickHighlighted?: boolean;
|
|
432
|
-
overflowShadow: boolean;
|
|
433
|
-
virtualPaddingLeft?: number;
|
|
434
|
-
virtualPaddingRight?: number;
|
|
435
|
-
resetNewRow: () => void;
|
|
436
|
-
isNewRowCreated: boolean;
|
|
437
|
-
setIsNewRowCreated: React.Dispatch<React.SetStateAction<boolean>>;
|
|
438
|
-
showTransposedTooltip?: boolean;
|
|
439
|
-
itemActionsDisabledTooltip?: (row: TData) => string;
|
|
440
|
-
enableRowDragCallback?: (row: TData) => boolean;
|
|
441
|
-
enableDrop: boolean;
|
|
442
|
-
onItemClick?: (row: TData) => void;
|
|
443
|
-
highlightDragOverRow?: boolean;
|
|
444
|
-
name: string;
|
|
445
|
-
columnOrder: string[];
|
|
446
|
-
onCellClick?: (info: ICellClickInfo) => void;
|
|
453
|
+
disabledKeys?: string[];
|
|
447
454
|
}
|
|
448
455
|
export interface IItemActionsProps<TData> {
|
|
449
456
|
actionsVisible: boolean;
|
|
@@ -626,4 +633,13 @@ export declare enum ConstantType {
|
|
|
626
633
|
DateTime = 6,
|
|
627
634
|
NotNullNumber = 7
|
|
628
635
|
}
|
|
636
|
+
export interface AdditionalRowFields {
|
|
637
|
+
hasChildren?: boolean;
|
|
638
|
+
parentId?: string;
|
|
639
|
+
level?: number;
|
|
640
|
+
subRows?: any;
|
|
641
|
+
isDragDisabled?: boolean;
|
|
642
|
+
nodeType?: number;
|
|
643
|
+
field?: string;
|
|
644
|
+
}
|
|
629
645
|
export {};
|
|
@@ -58,7 +58,7 @@ export declare const getTableColumns: <TData>(columns: IHeadCell<TData>[], adapt
|
|
|
58
58
|
tooltipTemplate?: (row: IHashMap) => React.JSX.Element | string;
|
|
59
59
|
backgroundColorCallback?: (row: TData) => string | undefined;
|
|
60
60
|
isLast?: boolean;
|
|
61
|
-
|
|
61
|
+
enableSorting?: boolean;
|
|
62
62
|
}[];
|
|
63
63
|
export declare const getCommonPinningStyles: (column: any, isHeader?: boolean, hasShadow?: boolean) => CSSProperties;
|
|
64
64
|
export declare const dragOverlayStyle: {
|
|
@@ -77,3 +77,4 @@ export declare const dragOverlayStyle: {
|
|
|
77
77
|
* @param id
|
|
78
78
|
*/
|
|
79
79
|
export declare function getTableItemById(data: IHashMap[], id: string): IHashMap;
|
|
80
|
+
export declare const isArraysEqual: (arr1?: string[], arr2?: string[]) => boolean;
|
|
@@ -51,6 +51,7 @@ declare module '@mui/material/styles' {
|
|
|
51
51
|
interface TypeBackground {
|
|
52
52
|
defaultHover: CSSProperties;
|
|
53
53
|
secondary: CSSProperties;
|
|
54
|
+
disabled: CSSProperties;
|
|
54
55
|
}
|
|
55
56
|
|
|
56
57
|
interface TypeAction {
|
|
@@ -151,3 +152,33 @@ declare module '@mui/material/Checkbox' {
|
|
|
151
152
|
|
|
152
153
|
interface CheckboxProps extends CustomCheckProps {}
|
|
153
154
|
}
|
|
155
|
+
|
|
156
|
+
declare module '@mui/material/ToggleButtonGroup' {
|
|
157
|
+
interface ToggleButtonGroupPropsSizeOverrides {
|
|
158
|
+
s: true;
|
|
159
|
+
m: true;
|
|
160
|
+
large: false;
|
|
161
|
+
medium: false;
|
|
162
|
+
small: false;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
interface ToggleButtonGroupPropsColorOverrides {
|
|
166
|
+
primary: true;
|
|
167
|
+
secondary: true;
|
|
168
|
+
standard: false;
|
|
169
|
+
error: false;
|
|
170
|
+
info: false;
|
|
171
|
+
success: false;
|
|
172
|
+
warning: false;
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
declare module '@mui/material/ToggleButton' {
|
|
177
|
+
interface ToggleButtonPropsSizeOverrides {
|
|
178
|
+
s: true;
|
|
179
|
+
m: true;
|
|
180
|
+
large: false;
|
|
181
|
+
medium: false;
|
|
182
|
+
small: false;
|
|
183
|
+
}
|
|
184
|
+
}
|
|
@@ -1,35 +1,55 @@
|
|
|
1
|
-
export declare const
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
export declare const toggleButtonConfig: {
|
|
2
|
+
variants: {
|
|
3
|
+
props: {
|
|
4
|
+
size: string;
|
|
5
|
+
};
|
|
6
|
+
style: {
|
|
7
7
|
height: string;
|
|
8
|
+
borderRadius: string;
|
|
9
|
+
'&.MuiToggleButtonGroup-firstButton, &.MuiToggleButtonGroup-middleButton, &.MuiToggleButtonGroup-lastButton': {
|
|
10
|
+
borderTopRightRadius: string;
|
|
11
|
+
borderBottomRightRadius: string;
|
|
12
|
+
borderTopLeftRadius: string;
|
|
13
|
+
borderBottomLeftRadius: string;
|
|
14
|
+
marginLeft: number;
|
|
15
|
+
marginRight: number;
|
|
16
|
+
};
|
|
17
|
+
fontSize: number;
|
|
8
18
|
padding: string;
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
19
|
+
border: string;
|
|
20
|
+
textTransform: "none";
|
|
21
|
+
display: string;
|
|
22
|
+
alignItems: string;
|
|
23
|
+
justifyContent: string;
|
|
24
|
+
minWidth: string;
|
|
25
|
+
background: string;
|
|
26
|
+
'&:hover': {
|
|
27
|
+
background: string;
|
|
14
28
|
};
|
|
15
29
|
'&.Mui-selected': {
|
|
16
30
|
background: string;
|
|
17
|
-
borderColor: string;
|
|
18
31
|
color: string;
|
|
19
32
|
'&:hover': {
|
|
20
33
|
background: string;
|
|
21
34
|
};
|
|
22
35
|
};
|
|
23
|
-
'&.
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
};
|
|
30
|
-
};
|
|
36
|
+
'&.Mui-disabled': {
|
|
37
|
+
color: string;
|
|
38
|
+
opacity: string;
|
|
39
|
+
border: string;
|
|
40
|
+
};
|
|
41
|
+
'&.Mui-selected.Mui-disabled': {
|
|
31
42
|
color: string;
|
|
32
43
|
};
|
|
44
|
+
'& .MuiSvgIcon-root': {
|
|
45
|
+
fontSize: string;
|
|
46
|
+
};
|
|
33
47
|
};
|
|
48
|
+
}[];
|
|
49
|
+
defaultProps: {
|
|
50
|
+
size: string;
|
|
51
|
+
disableRipple: boolean;
|
|
52
|
+
disableFocusRipple: boolean;
|
|
53
|
+
disableTouchRipple: boolean;
|
|
34
54
|
};
|
|
35
55
|
};
|
|
@@ -1,7 +1,23 @@
|
|
|
1
|
-
export declare const
|
|
1
|
+
export declare const toggleButtonGroupConfig: {
|
|
2
2
|
styleOverrides: {
|
|
3
3
|
root: {
|
|
4
4
|
gap: string;
|
|
5
|
+
display: string;
|
|
5
6
|
};
|
|
6
7
|
};
|
|
8
|
+
variants: {
|
|
9
|
+
props: {
|
|
10
|
+
color: string;
|
|
11
|
+
size: string;
|
|
12
|
+
};
|
|
13
|
+
style: {
|
|
14
|
+
borderRadius: string;
|
|
15
|
+
backgroundColor: string;
|
|
16
|
+
padding: string;
|
|
17
|
+
};
|
|
18
|
+
}[];
|
|
19
|
+
defaultProps: {
|
|
20
|
+
color: string;
|
|
21
|
+
size: string;
|
|
22
|
+
};
|
|
7
23
|
};
|