@balkangraph/orgchart.js 8.14.78 → 8.14.80
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/orgchart.d.ts +103 -3
- package/orgchart.js +1 -1
- package/package.json +1 -1
package/orgchart.d.ts
CHANGED
|
@@ -1,31 +1,127 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
3
|
declare class OrgChart {
|
|
4
|
-
|
|
4
|
+
/**
|
|
5
|
+
* SVG icons
|
|
6
|
+
* @param w - width
|
|
7
|
+
* @param h - height
|
|
8
|
+
* @param c - color
|
|
9
|
+
* @param x - X position
|
|
10
|
+
* @param y - Y position
|
|
11
|
+
* @returns string with the SVG definition
|
|
12
|
+
*/
|
|
5
13
|
static icon: {
|
|
14
|
+
/**
|
|
15
|
+
* ```typescript
|
|
16
|
+
* let pngIcon = OrgChart.icon.png(24, 24, "#7A7A7A");
|
|
17
|
+
* ```
|
|
18
|
+
*/
|
|
6
19
|
png: (w: string| number, h: string | number, c: string) => string,
|
|
7
|
-
|
|
20
|
+
/**
|
|
21
|
+
* ```typescript
|
|
22
|
+
* let pdfIcon = OrgChart.icon.pdf(24, 24, "#7A7A7A");
|
|
23
|
+
* ```
|
|
24
|
+
*/
|
|
25
|
+
pdf: (w: string | number, h: string | number, c: string) => string,
|
|
26
|
+
/**
|
|
27
|
+
* ```typescript
|
|
28
|
+
* let svgIcon = OrgChart.icon.svg(24, 24, "#7A7A7A");
|
|
29
|
+
* ```
|
|
30
|
+
*/
|
|
8
31
|
svg: (w: string| number, h: string| number, c: string | number) => string,
|
|
32
|
+
/**
|
|
33
|
+
* ```typescript
|
|
34
|
+
* let csvIcon = OrgChart.icon.csv(24, 24, "#7A7A7A");
|
|
35
|
+
* ```
|
|
36
|
+
*/
|
|
9
37
|
csv: (w: string| number, h: string| number, c: string| number) => string,
|
|
38
|
+
/**
|
|
39
|
+
* ```typescript
|
|
40
|
+
* let excelIcon = OrgChart.icon.excel(24, 24, "#7A7A7A");
|
|
41
|
+
* ```
|
|
42
|
+
*/
|
|
10
43
|
excel: (w: string| number, h: string| number, c: string| number) => string,
|
|
44
|
+
/**
|
|
45
|
+
* ```typescript
|
|
46
|
+
* let editIcon = OrgChart.icon.edit(24, 24, "#7A7A7A");
|
|
47
|
+
* ```
|
|
48
|
+
*/
|
|
11
49
|
edit: (w: string| number, h: string| number, c: string| number) => string,
|
|
50
|
+
/**
|
|
51
|
+
* ```typescript
|
|
52
|
+
* let detailsIcon = OrgChart.icon.details(24, 24, "#7A7A7A");
|
|
53
|
+
* ```
|
|
54
|
+
*/
|
|
12
55
|
details: (w: string| number, h: string| number, c: string| number) => string,
|
|
56
|
+
/**
|
|
57
|
+
* ```typescript
|
|
58
|
+
* let removeIcon = OrgChart.icon.remove(24, 24, "#7A7A7A");
|
|
59
|
+
* ```
|
|
60
|
+
*/
|
|
13
61
|
remove: (w: string| number, h: string| number, c: string| number) => string,
|
|
62
|
+
/**
|
|
63
|
+
* ```typescript
|
|
64
|
+
* let addIcon = OrgChart.icon.add(24, 24, "#7A7A7A");
|
|
65
|
+
* ```
|
|
66
|
+
*/
|
|
14
67
|
add: (w: string| number, h: string| number, c: string| number) => string,
|
|
68
|
+
/**
|
|
69
|
+
* ```typescript
|
|
70
|
+
* let xmlIcon = OrgChart.icon.xml(24, 24, "#7A7A7A");
|
|
71
|
+
* ```
|
|
72
|
+
*/
|
|
15
73
|
xml: (w: string| number, h: string| number, c: string| number) => string,
|
|
74
|
+
/**
|
|
75
|
+
* ```typescript
|
|
76
|
+
* let linkIcon = OrgChart.icon.link(24, 24, "#7A7A7A");
|
|
77
|
+
* ```
|
|
78
|
+
*/
|
|
16
79
|
link: (w: string| number, h: string| number, c: string| number) => string,
|
|
80
|
+
/**
|
|
81
|
+
* ```typescript
|
|
82
|
+
* let happyIcon = OrgChart.icon.happy(24, 24, "#7A7A7A");
|
|
83
|
+
* ```
|
|
84
|
+
*/
|
|
17
85
|
happy: (w: string| number, h: string| number, c: string| number) => string,
|
|
86
|
+
/**
|
|
87
|
+
* ```typescript
|
|
88
|
+
* let sadIcon = OrgChart.icon.sad(24, 24, "#7A7A7A");
|
|
89
|
+
* ```
|
|
90
|
+
*/
|
|
18
91
|
sad: (w: string| number, h: string| number, c: string| number) => string,
|
|
92
|
+
/**
|
|
93
|
+
* ```typescript
|
|
94
|
+
* let shareIcon = OrgChart.icon.share(24, 24, "#7A7A7A");
|
|
95
|
+
* ```
|
|
96
|
+
*/
|
|
19
97
|
share: (w: string| number, h: string| number, c: string| number, x?: string| number, y?: string| number) => string,
|
|
98
|
+
/**
|
|
99
|
+
* ```typescript
|
|
100
|
+
* let userIcon = OrgChart.icon.user(24, 24, "#7A7A7A");
|
|
101
|
+
* ```
|
|
102
|
+
*/
|
|
20
103
|
user: (w: string| number, h: string| number, c: string| number, x?: string| number, y?: string| number) => string,
|
|
104
|
+
/**
|
|
105
|
+
* ```typescript
|
|
106
|
+
* let undoIcon = OrgChart.icon.undo(24, 24, "#7A7A7A");
|
|
107
|
+
* ```
|
|
108
|
+
*/
|
|
21
109
|
undo: (w: string| number, h: string| number, c: string| number, x?: string| number, y?: string| number) => string,
|
|
110
|
+
/**
|
|
111
|
+
* ```typescript
|
|
112
|
+
* let redoIcon = OrgChart.icon.redo(24, 24, "#7A7A7A");
|
|
113
|
+
* ```
|
|
114
|
+
*/
|
|
22
115
|
redo: (w: string| number, h: string| number, c: string| number, x?: string| number, y?: string| number) => string
|
|
23
116
|
}
|
|
24
117
|
|
|
25
118
|
|
|
26
119
|
|
|
27
120
|
/**
|
|
28
|
-
* Can update link
|
|
121
|
+
* Can update link (Does the node is dropping under itself)
|
|
122
|
+
* ```typescript
|
|
123
|
+
* let canDropTheNode = chart.canUpdateLink(draggedNodeId, droppedNodeId));
|
|
124
|
+
* ```
|
|
29
125
|
* @param id child id
|
|
30
126
|
* @param pid parent id
|
|
31
127
|
*/
|
|
@@ -33,6 +129,10 @@ declare class OrgChart {
|
|
|
33
129
|
|
|
34
130
|
/**
|
|
35
131
|
* Removes specified node from nodes collection, redraws the chart and fires remove event.
|
|
132
|
+
* ```typescript
|
|
133
|
+
* var chart = new OrgChart('#tree', {});
|
|
134
|
+
* chart.removeNode(2);
|
|
135
|
+
* ```
|
|
36
136
|
* @param id identification number of the node
|
|
37
137
|
* @param callback called at the end of animation
|
|
38
138
|
* @param fireEvent indicates if the remove event will be called or not
|