pixel-react 1.16.3 → 1.16.4
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/README.md +75 -75
- package/lib/components/Charts/BarChart/BarChart.js +8 -8
- package/lib/components/Charts/DashboardDonutChart/DashboardDonutChart.js +6 -6
- package/lib/components/Charts/IconRadialChart/IconRadialChart.js +4 -4
- package/lib/components/Charts/PieChart/PieChart.js +5 -5
- package/lib/components/Comments/Comments.js +14 -14
- package/lib/components/Comments/childComment/ChildComment.js +14 -14
- package/lib/components/EditTextField/EditTextField.js +2 -2
- package/lib/components/LabelEditTextField/LabelEditTextField.js +4 -4
- package/lib/components/StatusIndicator/StatusIndicator.js +5 -5
- package/lib/components/TreeV3/Components/TableBody.d.ts +3 -0
- package/lib/components/TreeV3/Components/TableBody.js +17 -0
- package/lib/components/TreeV3/Components/TableBody.js.map +1 -0
- package/lib/components/TreeV3/Components/TableCell.d.ts +4 -0
- package/lib/components/TreeV3/Components/TableCell.js +89 -0
- package/lib/components/TreeV3/Components/TableCell.js.map +1 -0
- package/lib/components/TreeV3/Components/TableHead.d.ts +4 -0
- package/lib/components/TreeV3/Components/TableHead.js +53 -0
- package/lib/components/TreeV3/Components/TableHead.js.map +1 -0
- package/lib/components/TreeV3/Components/TableRow.d.ts +4 -0
- package/lib/components/TreeV3/Components/TableRow.js +14 -0
- package/lib/components/TreeV3/Components/TableRow.js.map +1 -0
- package/lib/components/TreeV3/TableTreeFn.d.ts +5 -0
- package/lib/components/TreeV3/TableTreeFn.js +724 -0
- package/lib/components/TreeV3/TableTreeFn.js.map +1 -0
- package/lib/components/TreeV3/Utils/TableCell.d.ts +1 -0
- package/lib/components/TreeV3/Utils/TableCell.js +24 -0
- package/lib/components/TreeV3/Utils/TableCell.js.map +1 -0
- package/lib/components/TreeV3/Utils/addLastChild.d.ts +2 -0
- package/lib/components/TreeV3/Utils/addLastChild.js +24 -0
- package/lib/components/TreeV3/Utils/addLastChild.js.map +1 -0
- package/lib/components/TreeV3/Utils/addNewRow.d.ts +14 -0
- package/lib/components/TreeV3/Utils/addNewRow.js +80 -0
- package/lib/components/TreeV3/Utils/addNewRow.js.map +1 -0
- package/lib/components/TreeV3/Utils/formatDataCell.d.ts +2 -0
- package/lib/components/TreeV3/Utils/formatDataCell.js +15 -0
- package/lib/components/TreeV3/Utils/formatDataCell.js.map +1 -0
- package/lib/components/TreeV3/Utils/getAllChildIds.d.ts +2 -0
- package/lib/components/TreeV3/Utils/getAllChildIds.js +12 -0
- package/lib/components/TreeV3/Utils/getAllChildIds.js.map +1 -0
- package/lib/components/TreeV3/Utils/renderSpaces.d.ts +0 -0
- package/lib/components/TreeV3/Utils/renderSpaces.js +2 -0
- package/lib/components/TreeV3/Utils/renderSpaces.js.map +1 -0
- package/lib/components/TreeV3/Utils/updateParentSibling.d.ts +3 -0
- package/lib/components/TreeV3/Utils/updateParentSibling.js +65 -0
- package/lib/components/TreeV3/Utils/updateParentSibling.js.map +1 -0
- package/lib/components/TreeV3/data.d.ts +247 -0
- package/lib/components/TreeV3/data.js +529 -0
- package/lib/components/TreeV3/data.js.map +1 -0
- package/lib/components/TreeV3/index.d.ts +3 -0
- package/lib/components/TreeV3/index.js +4 -0
- package/lib/components/TreeV3/index.js.map +1 -0
- package/lib/components/TreeV3/types.d.ts +170 -0
- package/lib/components/TreeV3/types.js +2 -0
- package/lib/components/TreeV3/types.js.map +1 -0
- package/lib/index.js +7 -7
- package/lib/index.js.map +1 -1
- package/lib/styles.css +1 -1
- package/lib/styles.css.map +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/package.json +106 -106
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
import { ReactNode, CSSProperties } from 'react';
|
|
2
|
+
import { TreeNodeProps } from '../../ComponentProps/TreeNodeProps';
|
|
3
|
+
interface NewNode {
|
|
4
|
+
sourceId?: string;
|
|
5
|
+
payloadSourceId?: string;
|
|
6
|
+
action?: 'addAbove' | 'addBelow' | 'addInside';
|
|
7
|
+
type?: 'input' | 'inputWithDropdown';
|
|
8
|
+
options?: [];
|
|
9
|
+
selectedOption?: string;
|
|
10
|
+
value?: string;
|
|
11
|
+
error?: string;
|
|
12
|
+
label?: string;
|
|
13
|
+
confirmIconTooltip?: string;
|
|
14
|
+
cancelIconTooltip?: string;
|
|
15
|
+
firstNodeKey?: string;
|
|
16
|
+
}
|
|
17
|
+
declare type JSX = ReactNode | JSX.Element[] | string | null;
|
|
18
|
+
export interface TableCellProps {
|
|
19
|
+
treeRowRef?: React.RefObject<HTMLDivElement | null>;
|
|
20
|
+
col: any;
|
|
21
|
+
colIndex?: number;
|
|
22
|
+
columnMeta?: ColumnMeta;
|
|
23
|
+
node: any;
|
|
24
|
+
selected: string[];
|
|
25
|
+
select: string | null;
|
|
26
|
+
onCheckBoxChange: (e: any, node: string[] | any) => void;
|
|
27
|
+
onToggleExpand: (node: any) => void;
|
|
28
|
+
index?: number;
|
|
29
|
+
onAddConfirm?: (_name: string, _type?: Option) => void;
|
|
30
|
+
onAddCancel?: () => void;
|
|
31
|
+
handleEditFieldError?: (inputText: string) => string;
|
|
32
|
+
isExpanding?: boolean;
|
|
33
|
+
columnTextColor?: string;
|
|
34
|
+
hideOnDisable?: boolean;
|
|
35
|
+
scriptLengthTruncate: number;
|
|
36
|
+
addModuleInputWidth?: number;
|
|
37
|
+
addModuleSelectWidth?: number;
|
|
38
|
+
disableEditLabelConfirmIcon?: boolean;
|
|
39
|
+
isEditable?: boolean;
|
|
40
|
+
setIsEditable?: (id: string | null) => void;
|
|
41
|
+
}
|
|
42
|
+
export type RootNode = {
|
|
43
|
+
node: any;
|
|
44
|
+
select: 'radio' | 'checkbox' | 'none';
|
|
45
|
+
cell?: (row: any) => JSX;
|
|
46
|
+
actions?: (row: any, treeRowRef?: React.RefObject<HTMLDivElement | null>) => JSX;
|
|
47
|
+
};
|
|
48
|
+
export interface TableHeadProps {
|
|
49
|
+
columnsData: any[];
|
|
50
|
+
columnMeta?: ColumnMeta[];
|
|
51
|
+
totalWidth?: string;
|
|
52
|
+
rootNode?: RootNode;
|
|
53
|
+
selected: string[];
|
|
54
|
+
selectedNode?: string;
|
|
55
|
+
tableHeaderBgColor?: string;
|
|
56
|
+
onCheckBoxChange: (e: any, node: string[] | any) => void;
|
|
57
|
+
hideOnDisable?: boolean;
|
|
58
|
+
transparentHeader?: boolean;
|
|
59
|
+
scriptLengthTruncate?: number;
|
|
60
|
+
showHeader?: boolean;
|
|
61
|
+
}
|
|
62
|
+
export interface TableBodyProps {
|
|
63
|
+
flattenedTreeData: any[];
|
|
64
|
+
columnsData: any[];
|
|
65
|
+
columnMeta?: ColumnMeta[];
|
|
66
|
+
totalWidth?: string;
|
|
67
|
+
rowHeight?: number;
|
|
68
|
+
startIndex?: number;
|
|
69
|
+
totalHeight?: number;
|
|
70
|
+
selected: string[];
|
|
71
|
+
select: string | null;
|
|
72
|
+
onRowClick: (e: any, node: any) => void;
|
|
73
|
+
onToggleExpand: (node: TreeNodeProps) => void;
|
|
74
|
+
onCheckBoxChange: (e: any, node: string[] | any) => void;
|
|
75
|
+
newNode?: NewNode;
|
|
76
|
+
onAddConfirm?: (_name: string, _type?: Option) => void;
|
|
77
|
+
onAddCancel?: () => void;
|
|
78
|
+
handleEditFieldError?: (inputText: string) => string;
|
|
79
|
+
expanding?: string | null;
|
|
80
|
+
rootNode?: TreeNodeProps;
|
|
81
|
+
selectedNode?: string;
|
|
82
|
+
hideOnDisable?: boolean;
|
|
83
|
+
scriptLengthTruncate: number;
|
|
84
|
+
addModuleInputWidth?: number;
|
|
85
|
+
addModuleSelectWidth?: number;
|
|
86
|
+
disableEditLabelConfirmIcon?: boolean;
|
|
87
|
+
isEditable?: boolean;
|
|
88
|
+
setIsEditable?: (id: string | null) => void;
|
|
89
|
+
}
|
|
90
|
+
export interface TableRowProps {
|
|
91
|
+
node: any;
|
|
92
|
+
columnsData: any[];
|
|
93
|
+
columnMeta?: ColumnMeta[];
|
|
94
|
+
selected: string[];
|
|
95
|
+
select: string | null;
|
|
96
|
+
onRowClick: (e: any, node: any) => void;
|
|
97
|
+
onToggleExpand: (node: TreeNodeProps) => void;
|
|
98
|
+
onCheckBoxChange: (e: any, node: string[] | any) => void;
|
|
99
|
+
index?: number;
|
|
100
|
+
onAddConfirm?: (_name: string, _type?: Option) => void;
|
|
101
|
+
onAddCancel?: () => void;
|
|
102
|
+
handleEditFieldError?: (inputText: string) => string;
|
|
103
|
+
isExpanding?: boolean;
|
|
104
|
+
selectedNode?: string;
|
|
105
|
+
hideOnDisable?: boolean;
|
|
106
|
+
scriptLengthTruncate: number;
|
|
107
|
+
addModuleInputWidth?: number;
|
|
108
|
+
addModuleSelectWidth?: number;
|
|
109
|
+
disableEditLabelConfirmIcon?: boolean;
|
|
110
|
+
isEditable?: boolean;
|
|
111
|
+
setIsEditable?: (id: string | null) => void;
|
|
112
|
+
style?: CSSProperties;
|
|
113
|
+
}
|
|
114
|
+
export interface Column {
|
|
115
|
+
name: string | JSX;
|
|
116
|
+
accessor: string;
|
|
117
|
+
width: string;
|
|
118
|
+
isClickable?: boolean;
|
|
119
|
+
cell?: (row: any) => JSX;
|
|
120
|
+
actions?: (row: any, treeRowRef?: React.RefObject<HTMLDivElement | null>) => JSX;
|
|
121
|
+
isTree?: boolean;
|
|
122
|
+
defaultValue?: string;
|
|
123
|
+
defaultActions?: () => JSX;
|
|
124
|
+
}
|
|
125
|
+
export interface ColumnMeta {
|
|
126
|
+
width: string;
|
|
127
|
+
sticky: boolean;
|
|
128
|
+
left: string;
|
|
129
|
+
zIndex: number;
|
|
130
|
+
}
|
|
131
|
+
export interface TreeTableProps {
|
|
132
|
+
treeData: any;
|
|
133
|
+
columnsData: Column[];
|
|
134
|
+
selected?: string[];
|
|
135
|
+
select?: 'radio' | 'checkbox' | 'none';
|
|
136
|
+
onChange?: (e: any, node: string[] | any) => void;
|
|
137
|
+
onClick?: (e: React.MouseEvent<HTMLDivElement>, row: TreeNodeProps) => void;
|
|
138
|
+
onExpand?: (node: TreeNodeProps) => void;
|
|
139
|
+
loadMore?: (_direction?: string) => void;
|
|
140
|
+
tableBorder?: string;
|
|
141
|
+
height?: number | string;
|
|
142
|
+
newNode?: NewNode;
|
|
143
|
+
onAddConfirm?: (_name: string, _type?: Option) => void;
|
|
144
|
+
onAddCancel?: () => void;
|
|
145
|
+
loading?: boolean;
|
|
146
|
+
rootNode?: RootNode;
|
|
147
|
+
getContentLength?: number;
|
|
148
|
+
handleEditFieldError?: (inputText: string) => string;
|
|
149
|
+
pagination?: boolean;
|
|
150
|
+
selectedNode?: string;
|
|
151
|
+
tableHeaderBgColor?: string;
|
|
152
|
+
hideOnDisable?: boolean;
|
|
153
|
+
freezeColumns?: number;
|
|
154
|
+
scriptLengthTruncate?: number;
|
|
155
|
+
addModuleInputWidth?: number;
|
|
156
|
+
addModuleSelectWidth?: number;
|
|
157
|
+
onScroll?: () => void;
|
|
158
|
+
onScrollEnd?: () => void;
|
|
159
|
+
disableEditLabelConfirmIcon?: boolean;
|
|
160
|
+
transparentHeader?: boolean;
|
|
161
|
+
navigateTreeNode?: string | null;
|
|
162
|
+
handleRemoveNavigateTreeNode?: () => void;
|
|
163
|
+
scrollThreshold?: number;
|
|
164
|
+
showHeader?: boolean;
|
|
165
|
+
}
|
|
166
|
+
type OptionValue = any;
|
|
167
|
+
export interface Option {
|
|
168
|
+
[key: string]: OptionValue;
|
|
169
|
+
}
|
|
170
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/components/TreeV3/types.ts"],"names":[],"mappings":""}
|