@cloudtower/eagle 0.22.40 → 0.23.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/dist/components/TableForm/Columns/AffixColumn.d.ts +1 -1
- package/dist/components/TableForm/Columns/CheckboxColumn.d.ts +6 -3
- package/dist/components/TableForm/Columns/InputColumn.d.ts +3 -3
- package/dist/components/TableForm/Columns/TextColumn.d.ts +1 -1
- package/dist/components/TableForm/Columns/index.d.ts +15 -13
- package/dist/components/TableForm/types.d.ts +27 -12
- package/dist/esm/index.js +189 -112
- package/dist/esm/stats1.html +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/style.css +1145 -1120
- package/dist/umd/index.js +188 -110
- package/dist/umd/stats1.html +1 -1
- package/package.json +5 -5
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { ColumnHeaderCellProps } from "../types";
|
|
3
3
|
export declare const AffixColumnHeaderCell: React.FC<Omit<ColumnHeaderCellProps, "onChange" | "onBlur"> & {
|
|
4
|
-
onChange: (value:
|
|
4
|
+
onChange: (value: any) => void;
|
|
5
5
|
onBlur: () => void;
|
|
6
6
|
}>;
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import { ColumnBodyCellProps } from "../types";
|
|
3
|
-
export declare const
|
|
4
|
-
onChange: (value:
|
|
2
|
+
import { ColumnBodyCellProps, ColumnHeaderCellProps } from "../types";
|
|
3
|
+
export declare const CheckboxColumnHeaderCell: React.FC<Omit<ColumnHeaderCellProps, "onChange" | "onBlur"> & {
|
|
4
|
+
onChange: (value: any, shouldUpdateData?: boolean) => void;
|
|
5
|
+
}>;
|
|
6
|
+
export declare const CheckboxColumnBodyCell: React.FC<Pick<ColumnBodyCellProps, "data" | "column" | "index"> & {
|
|
7
|
+
onChange: (value: any) => void;
|
|
5
8
|
}>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { ColumnBodyCellProps, ColumnHeaderCellProps } from "../types";
|
|
3
3
|
export declare const InputColumnHeaderCell: React.FC<Omit<ColumnHeaderCellProps, "onChange" | "onBlur"> & {
|
|
4
|
-
onChange: (value:
|
|
4
|
+
onChange: (value: any) => void;
|
|
5
5
|
onBlur: () => void;
|
|
6
6
|
}>;
|
|
7
|
-
export declare const InputColumnBodyCell: React.FC<
|
|
8
|
-
onChange: (value:
|
|
7
|
+
export declare const InputColumnBodyCell: React.FC<Pick<ColumnBodyCellProps, "data" | "latestData" | "column" | "index" | "disabled" | "visible"> & {
|
|
8
|
+
onChange: (value: any) => void;
|
|
9
9
|
onBlur: () => void;
|
|
10
10
|
}>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { ColumnBodyCellProps, ColumnHeaderCellProps } from "../types";
|
|
3
3
|
export declare const TextColumnHeaderCell: React.FC<ColumnHeaderCellProps>;
|
|
4
|
-
export declare const TextColumnBodyCell: React.FC<ColumnBodyCellProps
|
|
4
|
+
export declare const TextColumnBodyCell: React.FC<Pick<ColumnBodyCellProps, "data" | "column" | "index">>;
|
|
@@ -2,34 +2,36 @@
|
|
|
2
2
|
export declare const ColumnHeaderImpls: {
|
|
3
3
|
text: import("react").FC<import("../types").ColumnHeaderCellProps>;
|
|
4
4
|
input: import("react").FC<Omit<import("../types").ColumnHeaderCellProps, "onChange" | "onBlur"> & {
|
|
5
|
-
onChange: (value:
|
|
5
|
+
onChange: (value: any) => void;
|
|
6
6
|
onBlur: () => void;
|
|
7
7
|
}>;
|
|
8
8
|
password: import("react").FC<Omit<import("../types").ColumnHeaderCellProps, "onChange" | "onBlur"> & {
|
|
9
|
-
onChange: (value:
|
|
9
|
+
onChange: (value: any) => void;
|
|
10
10
|
onBlur: () => void;
|
|
11
11
|
}>;
|
|
12
12
|
affix: import("react").FC<Omit<import("../types").ColumnHeaderCellProps, "onChange" | "onBlur"> & {
|
|
13
|
-
onChange: (value:
|
|
13
|
+
onChange: (value: any) => void;
|
|
14
14
|
onBlur: () => void;
|
|
15
15
|
}>;
|
|
16
|
-
checkbox: import("react").FC<import("../types").ColumnHeaderCellProps
|
|
16
|
+
checkbox: import("react").FC<Omit<import("../types").ColumnHeaderCellProps, "onChange" | "onBlur"> & {
|
|
17
|
+
onChange: (value: any, shouldUpdateData?: boolean | undefined) => void;
|
|
18
|
+
}>;
|
|
17
19
|
};
|
|
18
20
|
export declare const ColumnBodyImpls: {
|
|
19
|
-
text: import("react").FC<import("../types").ColumnBodyCellProps
|
|
20
|
-
input: import("react").FC<
|
|
21
|
-
onChange: (value:
|
|
21
|
+
text: import("react").FC<Pick<import("../types").ColumnBodyCellProps, "data" | "column" | "index">>;
|
|
22
|
+
input: import("react").FC<Pick<import("../types").ColumnBodyCellProps, "data" | "latestData" | "column" | "disabled" | "index" | "visible"> & {
|
|
23
|
+
onChange: (value: any) => void;
|
|
22
24
|
onBlur: () => void;
|
|
23
25
|
}>;
|
|
24
|
-
password: import("react").FC<
|
|
25
|
-
onChange: (value:
|
|
26
|
+
password: import("react").FC<Pick<import("../types").ColumnBodyCellProps, "data" | "latestData" | "column" | "disabled" | "index" | "visible"> & {
|
|
27
|
+
onChange: (value: any) => void;
|
|
26
28
|
onBlur: () => void;
|
|
27
29
|
}>;
|
|
28
|
-
affix: import("react").FC<
|
|
29
|
-
onChange: (value:
|
|
30
|
+
affix: import("react").FC<Pick<import("../types").ColumnBodyCellProps, "data" | "latestData" | "column" | "disabled" | "index" | "visible"> & {
|
|
31
|
+
onChange: (value: any) => void;
|
|
30
32
|
onBlur: () => void;
|
|
31
33
|
}>;
|
|
32
|
-
checkbox: import("react").FC<
|
|
33
|
-
onChange: (value:
|
|
34
|
+
checkbox: import("react").FC<Pick<import("../types").ColumnBodyCellProps, "data" | "column" | "index"> & {
|
|
35
|
+
onChange: (value: any) => void;
|
|
34
36
|
}>;
|
|
35
37
|
};
|
|
@@ -5,10 +5,15 @@ export type ErrorInfo = Record<string, {
|
|
|
5
5
|
errorMessage: string;
|
|
6
6
|
isError: boolean;
|
|
7
7
|
}>;
|
|
8
|
+
export declare enum ValidateTriggerType {
|
|
9
|
+
Normal = 0,
|
|
10
|
+
Aggressive = 1,
|
|
11
|
+
Lazy = 2
|
|
12
|
+
}
|
|
8
13
|
export type CustomizedColumnRenderProps = {
|
|
9
|
-
value?:
|
|
14
|
+
value?: any;
|
|
10
15
|
rowIndex?: number;
|
|
11
|
-
onChange: (value:
|
|
16
|
+
onChange: (value: any) => void;
|
|
12
17
|
disabled?: boolean;
|
|
13
18
|
onBlur?: () => void;
|
|
14
19
|
placeholder?: string;
|
|
@@ -22,9 +27,9 @@ export type TableFormColumn = {
|
|
|
22
27
|
subTitleColor?: "" | "primary" | "success" | "warning" | "danger";
|
|
23
28
|
bodyIcon?: any;
|
|
24
29
|
bodyErrorIcon?: any;
|
|
25
|
-
width?: number;
|
|
30
|
+
width?: number | string;
|
|
26
31
|
displayText?: string;
|
|
27
|
-
defaultValue?:
|
|
32
|
+
defaultValue?: any;
|
|
28
33
|
hidden?: boolean;
|
|
29
34
|
placeholder?: string;
|
|
30
35
|
autoIncrease?: boolean;
|
|
@@ -35,7 +40,7 @@ export type TableFormColumn = {
|
|
|
35
40
|
renderDescription?: (props: RenderRowDescriptionProps) => React.ReactNode;
|
|
36
41
|
render?: (props: CustomizedColumnRenderProps) => React.ReactNode;
|
|
37
42
|
validator?: (params: {
|
|
38
|
-
value:
|
|
43
|
+
value: any;
|
|
39
44
|
rowIndex?: number;
|
|
40
45
|
rowData?: DataType;
|
|
41
46
|
isHeader?: boolean;
|
|
@@ -47,13 +52,12 @@ export interface ColumnHeaderCellProps {
|
|
|
47
52
|
column: TableFormColumn;
|
|
48
53
|
disabled?: boolean;
|
|
49
54
|
disableBatchFilling?: boolean;
|
|
50
|
-
onChange?: (newData: DataType[], columnKey
|
|
55
|
+
onChange?: (newData: DataType[], columnKey: string, shouldUpdateData: boolean) => void;
|
|
51
56
|
onBlur?: (key: string, error?: string) => void;
|
|
52
57
|
onVisibleChange?: (visible: boolean) => void;
|
|
53
58
|
}
|
|
54
59
|
export type DataType = {
|
|
55
60
|
[columnKey: string]: any;
|
|
56
|
-
deletable?: boolean;
|
|
57
61
|
};
|
|
58
62
|
export interface ColumnBodyCellProps {
|
|
59
63
|
data: DataType[];
|
|
@@ -66,7 +70,10 @@ export interface ColumnBodyCellProps {
|
|
|
66
70
|
customData?: any;
|
|
67
71
|
placeholderValue?: string;
|
|
68
72
|
visible?: boolean;
|
|
69
|
-
|
|
73
|
+
validateTriggerType: ValidateTriggerType;
|
|
74
|
+
isRowError: boolean;
|
|
75
|
+
getRowValidateResult: (rowData: DataType) => string | undefined;
|
|
76
|
+
validateAll: boolean;
|
|
70
77
|
}
|
|
71
78
|
export type AddRowButtonProps = {
|
|
72
79
|
config: RowAddConfigurations;
|
|
@@ -82,35 +89,43 @@ export type RowAddConfigurations = {
|
|
|
82
89
|
className?: string;
|
|
83
90
|
CustomizedButton?: (props: AddRowButtonProps) => React.ReactElement;
|
|
84
91
|
};
|
|
85
|
-
export interface TableFormRowsProps extends Pick<TableFormProps, "columns" | "disabled" | "
|
|
92
|
+
export interface TableFormRowsProps extends Pick<TableFormProps, "columns" | "disabled" | "deleteConfig" | "draggable" | "disableBatchFilling" | "rowSplitType" | "validateTriggerType" | "renderRowDescription" | "rowValidator" | "onBodyBlur"> {
|
|
86
93
|
data: DataType[];
|
|
87
94
|
latestData: DataType[];
|
|
88
95
|
updateData: (data: DataType[]) => void;
|
|
89
96
|
passwordVisible: boolean;
|
|
97
|
+
validateAll: boolean;
|
|
90
98
|
}
|
|
91
99
|
export type RenderRowDescriptionProps = {
|
|
92
100
|
rowIndex: number;
|
|
93
101
|
rowData: DataType;
|
|
94
102
|
latestData?: DataType[];
|
|
95
103
|
};
|
|
104
|
+
export type DeletableConfigurations = {
|
|
105
|
+
deletable: boolean;
|
|
106
|
+
specifyRowDeleteDisabled?: (rowIndex: number, allData: DataType[]) => boolean;
|
|
107
|
+
};
|
|
96
108
|
export type TableFormProps = {
|
|
97
109
|
defaultData?: DataType[];
|
|
98
110
|
columns: TableFormColumn[];
|
|
99
111
|
disabled?: boolean;
|
|
100
112
|
rowAddConfig?: RowAddConfigurations;
|
|
101
|
-
|
|
113
|
+
deleteConfig?: DeletableConfigurations;
|
|
102
114
|
size?: "default" | "large" | "small";
|
|
103
115
|
draggable?: boolean;
|
|
104
116
|
disableBatchFilling?: boolean;
|
|
105
117
|
className?: string;
|
|
106
118
|
rowSplitType?: "border" | "zebraMarking";
|
|
119
|
+
validateTriggerType?: ValidateTriggerType;
|
|
120
|
+
maxHeight?: number | string;
|
|
107
121
|
renderRowDescription?: (props: RenderRowDescriptionProps) => React.ReactNode;
|
|
108
122
|
rowValidator?: (rowIndex: number, rowData: DataType) => string | undefined;
|
|
109
|
-
onHeaderChange?: (data:
|
|
110
|
-
onHeaderBlur?: (data:
|
|
123
|
+
onHeaderChange?: (data: any[], columnKey: string) => void;
|
|
124
|
+
onHeaderBlur?: (data: any[]) => void;
|
|
111
125
|
onBodyChange?: (value: DataType[], rowIndex?: number, columnKey?: string) => void;
|
|
112
126
|
onBodyBlur?: (value: DataType, rowIndex?: number, columnKey?: string) => void;
|
|
113
127
|
};
|
|
114
128
|
export type TableFormHandle = {
|
|
115
129
|
setData: (data: DataType[]) => void;
|
|
130
|
+
validateWholeFields: () => void;
|
|
116
131
|
};
|