orgchart 5.0.0 → 6.0.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/.github/workflows/publish.yml +32 -0
- package/README.md +172 -93
- package/README.zh-cn.md +163 -74
- package/README.zh-tw.md +163 -74
- package/bower.json +6 -9
- package/demo/10000-nodes.html +139 -0
- package/demo/ajax-datasource.html +46 -45
- package/demo/bottom2top.html +12 -9
- package/demo/center-on-selected-node.html +21 -17
- package/demo/color-coded.html +12 -9
- package/demo/css/style.css +28 -0
- package/demo/custom-icons.html +12 -9
- package/demo/custom-template.html +12 -9
- package/demo/data-prop-compact.html +11 -8
- package/demo/data-prop-hybrid.html +79 -50
- package/demo/default-collapsed.html +12 -9
- package/demo/drag-drop-hybrid-chart.html +17 -14
- package/demo/drag-drop.html +21 -16
- package/demo/edit-chart.html +148 -94
- package/demo/edit-hybrid-chart.html +178 -135
- package/demo/expand-to-given-depth.html +30 -22
- package/demo/export-chart-pdf.html +12 -9
- package/demo/export-chart-with-pictures.html +19 -12
- package/demo/export-chart.html +12 -9
- package/demo/family-tree.html +14 -11
- package/demo/familytree-custom-properties.html +108 -0
- package/demo/filter-node.html +104 -57
- package/demo/get-hierarchy.html +17 -12
- package/demo/get-related-nodes.html +27 -17
- package/demo/index.html +5 -2
- package/demo/integrate-map.html +32 -27
- package/demo/left2right.html +12 -9
- package/demo/level-offset.html +16 -15
- package/demo/link-node.html +12 -9
- package/demo/local-datasource.html +11 -8
- package/demo/minimap.html +224 -0
- package/demo/nodes-of-different-widths.html +11 -8
- package/demo/ondemand-loading-data.html +88 -91
- package/demo/option-createNode.html +28 -17
- package/demo/pan-zoom.html +20 -11
- package/demo/reload-data.html +17 -14
- package/demo/report-path.html +59 -29
- package/demo/responsive-design.html +14 -11
- package/demo/right2left.html +12 -9
- package/demo/toggle-sibs-resp.html +12 -9
- package/demo/ul-datasource.html +11 -8
- package/demo/vertical-level.html +12 -9
- package/dist/css/{jquery.orgchart.css → orgchart.css} +143 -80
- package/dist/css/orgchart.min.css +1 -0
- package/dist/js/orgchart.js +4101 -0
- package/dist/js/orgchart.min.js +2 -0
- package/dist/js/orgchart.min.js.map +1 -0
- package/gulpfile.js +37 -26
- package/package.json +32 -32
- package/src/css/{jquery.orgchart.css → orgchart.css} +143 -80
- package/src/js/orgchart.js +4101 -0
- package/test/cypress/e2e/demo-interactions.cy.js +91 -0
- package/test/cypress/e2e/demo-rendering.cy.js +100 -0
- package/test/cypress/e2e/drag-drop-hybrid-chart.cy.js +22 -0
- package/test/cypress/e2e/edit-chart.cy.js +20 -0
- package/test/cypress/e2e/level-offset.cy.js +21 -0
- package/test/cypress/e2e/minimap.cy.js +66 -0
- package/test/cypress/e2e/pan-zoom.cy.js +165 -0
- package/test/cypress/e2e/report-path.cy.js +20 -0
- package/test/cypress/e2e/vertical-vevel.cy.js +5 -3
- package/test/e2e/local-datasource/test.js +1 -1
- package/test/integration/init-tests.js +168 -62
- package/test/integration/tests.js +1034 -56
- package/test/unit/lifecycle-builders-export.tests.js +1426 -0
- package/test/unit/minimap.tests.js +210 -0
- package/test/unit/tests.js +2372 -252
- package/dist/css/jquery.orgchart.min.css +0 -1
- package/dist/js/jquery.orgchart.js +0 -1741
- package/dist/js/jquery.orgchart.min.js +0 -5
- package/dist/js/jquery.orgchart.min.js.map +0 -1
- package/src/js/jquery.orgchart.js +0 -1741
package/gulpfile.js
CHANGED
|
@@ -1,17 +1,32 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
1
|
+
const gulp = require('gulp');
|
|
2
|
+
const { spawn } = require('node:child_process');
|
|
3
|
+
const browserSync = require('browser-sync').create();
|
|
4
|
+
const uglify = require('gulp-uglify');
|
|
5
|
+
const rename = require("gulp-rename");
|
|
6
|
+
const eslint = require('gulp-eslint');
|
|
7
|
+
const merge = require('ordered-read-streams');
|
|
8
|
+
const csslint = require('gulp-csslint');
|
|
9
|
+
const cleanCSS = require('gulp-clean-css');
|
|
10
|
+
const sourcemaps = require('gulp-sourcemaps');
|
|
11
|
+
const cypress = require('cypress');
|
|
12
|
+
const jest = require('gulp-jest').default;
|
|
13
|
+
const deletePaths = (patterns) => import('del').then(({ deleteAsync }) => deleteAsync(patterns));
|
|
14
|
+
const runMocha = (files) => new Promise(function (resolve, reject) {
|
|
15
|
+
const mochaProcess = spawn(process.execPath, [
|
|
16
|
+
require.resolve('mocha/bin/mocha.js'),
|
|
17
|
+
'--reporter', 'spec'
|
|
18
|
+
].concat(files), { stdio: 'inherit' });
|
|
19
|
+
|
|
20
|
+
mochaProcess.once('error', reject);
|
|
21
|
+
mochaProcess.once('exit', function (exitCode) {
|
|
22
|
+
if (exitCode === 0) {
|
|
23
|
+
resolve();
|
|
24
|
+
} else {
|
|
25
|
+
reject(new Error('Tests failed with exit code ' + exitCode));
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
});
|
|
29
|
+
const paths = {
|
|
15
30
|
src: 'src',
|
|
16
31
|
srcFiles: 'src/**/*',
|
|
17
32
|
srcHTML: 'src/**/*.html',
|
|
@@ -33,27 +48,23 @@ var paths = {
|
|
|
33
48
|
};
|
|
34
49
|
|
|
35
50
|
gulp.task('unit-tests', function () {
|
|
36
|
-
return
|
|
37
|
-
.pipe(mocha({reporter: 'spec'}));
|
|
51
|
+
return runMocha(['test/unit/*.js']);
|
|
38
52
|
});
|
|
39
53
|
|
|
40
54
|
gulp.task('integration-tests', gulp.series('unit-tests', function () {
|
|
41
|
-
return
|
|
42
|
-
.pipe(mocha({reporter: 'spec'}));
|
|
55
|
+
return runMocha(['test/integration/*.js']);
|
|
43
56
|
}));
|
|
44
57
|
|
|
45
58
|
gulp.task('addAssets', gulp.series('integration-tests', function () {
|
|
46
|
-
|
|
59
|
+
const jsFiles = gulp.src([
|
|
47
60
|
paths.srcJS,
|
|
48
|
-
'node_modules/jquery/dist/jquery.min.js',
|
|
49
|
-
'node_modules/jquery-mockjax/dist/jquery.mockjax.min.js',
|
|
50
61
|
'node_modules/html2canvas/dist/html2canvas.min.js',
|
|
51
62
|
'node_modules/jspdf/dist/jspdf.umd.min.js',
|
|
52
63
|
'node_modules/json-digger/dist/json-digger.js'
|
|
53
64
|
])
|
|
54
65
|
.pipe(gulp.dest(paths.demoJSFolder));
|
|
55
66
|
|
|
56
|
-
|
|
67
|
+
const cssFiles = gulp.src(paths.srcCSS)
|
|
57
68
|
.pipe(gulp.dest(paths.demoCSSFolder));
|
|
58
69
|
|
|
59
70
|
return merge(jsFiles, cssFiles);
|
|
@@ -74,7 +85,7 @@ gulp.task('e2e-tests', gulp.series('addAssets', function () {
|
|
|
74
85
|
gulp.task('test', gulp.series('e2e-tests'));
|
|
75
86
|
|
|
76
87
|
gulp.task('cleanupJS', function() {
|
|
77
|
-
return
|
|
88
|
+
return deletePaths([paths.distJSFolder + '/**']);
|
|
78
89
|
});
|
|
79
90
|
|
|
80
91
|
gulp.task('eslint', function () {
|
|
@@ -88,13 +99,13 @@ gulp.task('js', gulp.series('cleanupJS', 'eslint', 'test', function () {
|
|
|
88
99
|
.pipe(gulp.dest(paths.distJSFolder))
|
|
89
100
|
.pipe(sourcemaps.init())
|
|
90
101
|
.pipe(uglify())
|
|
91
|
-
.pipe(rename('
|
|
102
|
+
.pipe(rename('orgchart.min.js'))
|
|
92
103
|
.pipe(sourcemaps.write('./'))
|
|
93
104
|
.pipe(gulp.dest(paths.distJSFolder));
|
|
94
105
|
}));
|
|
95
106
|
|
|
96
107
|
gulp.task('cleanupCSS', function() {
|
|
97
|
-
return
|
|
108
|
+
return deletePaths([paths.distCSSFolder + '/**']);
|
|
98
109
|
});
|
|
99
110
|
|
|
100
111
|
gulp.task('csslint', function() {
|
|
@@ -113,7 +124,7 @@ gulp.task('css', gulp.series('cleanupCSS', 'csslint', function () {
|
|
|
113
124
|
return gulp.src(paths.srcCSS)
|
|
114
125
|
.pipe(gulp.dest(paths.distCSSFolder))
|
|
115
126
|
.pipe(cleanCSS())
|
|
116
|
-
.pipe(rename('
|
|
127
|
+
.pipe(rename('orgchart.min.css'))
|
|
117
128
|
.pipe(gulp.dest(paths.distCSSFolder));
|
|
118
129
|
}));
|
|
119
130
|
|
package/package.json
CHANGED
|
@@ -1,14 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "orgchart",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "Simple and direct organization chart(tree-like hierarchy)
|
|
5
|
-
"main": "./dist/js/
|
|
3
|
+
"version": "6.0.0",
|
|
4
|
+
"description": "Simple and direct organization chart(tree-like hierarchy) library based on pure DOM.",
|
|
5
|
+
"main": "./dist/js/orgchart.min.js",
|
|
6
6
|
"style": [
|
|
7
|
-
"./dist/css/
|
|
7
|
+
"./dist/css/orgchart.min.css"
|
|
8
8
|
],
|
|
9
9
|
"scripts": {
|
|
10
10
|
"test": "gulp test",
|
|
11
11
|
"unit-tests": "gulp unit-tests",
|
|
12
|
+
"integration-tests": "gulp integration-tests",
|
|
13
|
+
"e2e-tests": "gulp e2e-tests",
|
|
14
|
+
"addAssets": "gulp addAssets",
|
|
12
15
|
"build": "gulp build",
|
|
13
16
|
"start": "gulp serve",
|
|
14
17
|
"cypress:open": "cypress open"
|
|
@@ -18,11 +21,10 @@
|
|
|
18
21
|
},
|
|
19
22
|
"repository": {
|
|
20
23
|
"type": "git",
|
|
21
|
-
"url": "https://github.com/dabeng/OrgChart.git"
|
|
24
|
+
"url": "git+https://github.com/dabeng/OrgChart.git"
|
|
22
25
|
},
|
|
23
26
|
"keywords": [
|
|
24
|
-
"
|
|
25
|
-
"plugin",
|
|
27
|
+
"dom",
|
|
26
28
|
"organization",
|
|
27
29
|
"chart",
|
|
28
30
|
"orgchart",
|
|
@@ -38,36 +40,34 @@
|
|
|
38
40
|
"homepage": "https://github.com/dabeng/OrgChart#readme",
|
|
39
41
|
"dependencies": {
|
|
40
42
|
"html2canvas": "^1.4.1",
|
|
41
|
-
"jquery": "^3.6.2",
|
|
42
|
-
"jquery-mockjax": "^2.6.0",
|
|
43
43
|
"json-digger": "^2.0.2",
|
|
44
|
-
"jspdf": "^2.
|
|
44
|
+
"jspdf": "^4.2.1"
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
|
-
"browser-sync": "^3.0.
|
|
48
|
-
"chai": "^
|
|
49
|
-
"cypress": "^
|
|
50
|
-
"del": "^
|
|
51
|
-
"gulp": "^5.0.
|
|
52
|
-
"gulp-clean-css": "^3.
|
|
47
|
+
"browser-sync": "^3.0.4",
|
|
48
|
+
"chai": "^6.2.2",
|
|
49
|
+
"cypress": "^15.20.0",
|
|
50
|
+
"del": "^8.0.1",
|
|
51
|
+
"gulp": "^5.0.1",
|
|
52
|
+
"gulp-clean-css": "^4.3.0",
|
|
53
53
|
"gulp-csslint": "^1.0.1",
|
|
54
|
-
"gulp-eslint": "^
|
|
55
|
-
"gulp-inject": "^
|
|
56
|
-
"gulp-jest": "^4.0.
|
|
57
|
-
"gulp-mocha": "^
|
|
58
|
-
"gulp-rename": "^1.
|
|
59
|
-
"gulp-sourcemaps": "^
|
|
54
|
+
"gulp-eslint": "^6.0.0",
|
|
55
|
+
"gulp-inject": "^5.0.5",
|
|
56
|
+
"gulp-jest": "^4.0.4",
|
|
57
|
+
"gulp-mocha": "^10.0.1",
|
|
58
|
+
"gulp-rename": "^2.1.0",
|
|
59
|
+
"gulp-sourcemaps": "^3.0.0",
|
|
60
60
|
"gulp-uglify": "^3.0.2",
|
|
61
|
-
"jest": "^
|
|
62
|
-
"jest-cli": "^
|
|
63
|
-
"jest-image-snapshot": "^6.
|
|
64
|
-
"jest-puppeteer": "^
|
|
65
|
-
"jsdom": "^
|
|
61
|
+
"jest": "^30.4.2",
|
|
62
|
+
"jest-cli": "^30.4.2",
|
|
63
|
+
"jest-image-snapshot": "^6.5.2",
|
|
64
|
+
"jest-puppeteer": "^11.0.0",
|
|
65
|
+
"jsdom": "^30.0.1",
|
|
66
66
|
"jsdom-global": "^3.0.2",
|
|
67
|
-
"
|
|
68
|
-
"
|
|
69
|
-
"puppeteer": "^
|
|
70
|
-
"sinon": "^
|
|
71
|
-
"sinon-chai": "^
|
|
67
|
+
"mocha": "^11.8.0",
|
|
68
|
+
"ordered-read-streams": "^2.0.0",
|
|
69
|
+
"puppeteer": "^25.5.0",
|
|
70
|
+
"sinon": "^22.1.0",
|
|
71
|
+
"sinon-chai": "^4.0.1"
|
|
72
72
|
}
|
|
73
73
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
*
|
|
2
|
+
* JavaScript OrgChart Component
|
|
3
3
|
* https://github.com/dabeng/OrgChart
|
|
4
4
|
*
|
|
5
5
|
* Copyright 2016, dabeng
|
|
@@ -51,7 +51,9 @@
|
|
|
51
51
|
}
|
|
52
52
|
|
|
53
53
|
.orgchart ~ .mask {
|
|
54
|
-
position:
|
|
54
|
+
position: sticky;
|
|
55
|
+
width: 100%;
|
|
56
|
+
height: 100%;
|
|
55
57
|
top: 0;
|
|
56
58
|
right: 0;
|
|
57
59
|
bottom: 0;
|
|
@@ -86,19 +88,89 @@
|
|
|
86
88
|
justify-content: center;
|
|
87
89
|
}
|
|
88
90
|
|
|
91
|
+
.orgchart-minimap {
|
|
92
|
+
position: absolute;
|
|
93
|
+
right: 12px;
|
|
94
|
+
bottom: 12px;
|
|
95
|
+
z-index: 25;
|
|
96
|
+
width: 180px;
|
|
97
|
+
height: 120px;
|
|
98
|
+
padding: 8px;
|
|
99
|
+
border: 1px solid rgba(68, 68, 68, 0.18);
|
|
100
|
+
border-radius: 8px;
|
|
101
|
+
background-color: rgba(255, 255, 255, 0.96);
|
|
102
|
+
box-shadow: 0 10px 28px rgba(0, 0, 0, 0.12);
|
|
103
|
+
box-sizing: border-box;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
.orgchart-minimap-stage {
|
|
107
|
+
position: relative;
|
|
108
|
+
width: 100%;
|
|
109
|
+
height: 100%;
|
|
110
|
+
overflow: hidden;
|
|
111
|
+
border-radius: 5px;
|
|
112
|
+
background-image: linear-gradient(rgba(68, 68, 68, 0.05) 1px, transparent 1px), linear-gradient(90deg, rgba(68, 68, 68, 0.05) 1px, transparent 1px);
|
|
113
|
+
background-size: 10px 10px;
|
|
114
|
+
background-color: #f9fbfc;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.orgchart-minimap-content {
|
|
118
|
+
position: absolute;
|
|
119
|
+
top: 0;
|
|
120
|
+
left: 0;
|
|
121
|
+
pointer-events: none;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
.orgchart-minimap-node {
|
|
125
|
+
position: absolute;
|
|
126
|
+
min-width: 6px;
|
|
127
|
+
height: 18px;
|
|
128
|
+
border-radius: 0;
|
|
129
|
+
opacity: 1;
|
|
130
|
+
box-shadow: none;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.orgchart-minimap .orgchart,
|
|
134
|
+
.orgchart-minimap .orgchart ul,
|
|
135
|
+
.orgchart-minimap .orgchart li,
|
|
136
|
+
.orgchart-minimap .orgchart .node,
|
|
137
|
+
.orgchart-minimap .orgchart .edge,
|
|
138
|
+
.orgchart-minimap .orgchart .verticalNodes,
|
|
139
|
+
.orgchart-minimap .orgchart .verticalNode,
|
|
140
|
+
.orgchart-minimap .orgchart .nodes,
|
|
141
|
+
.orgchart-minimap-node {
|
|
142
|
+
pointer-events: none;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
.orgchart-minimap-viewport {
|
|
146
|
+
position: absolute;
|
|
147
|
+
top: 0;
|
|
148
|
+
left: 0;
|
|
149
|
+
min-width: 12px;
|
|
150
|
+
min-height: 12px;
|
|
151
|
+
border: 2px solid rgba(28, 111, 197, 0.9);
|
|
152
|
+
border-radius: 4px;
|
|
153
|
+
background-color: rgba(28, 111, 197, 0.12);
|
|
154
|
+
box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.9), 0 0 0 999px rgba(255, 255, 255, 0.12);
|
|
155
|
+
box-sizing: border-box;
|
|
156
|
+
cursor: move;
|
|
157
|
+
}
|
|
158
|
+
|
|
89
159
|
.orgchart .hierarchy {
|
|
90
160
|
position: relative;
|
|
91
161
|
}
|
|
92
162
|
|
|
93
163
|
/* styles of link lines */
|
|
94
164
|
.orgchart .hierarchy::before {
|
|
165
|
+
box-sizing: border-box;
|
|
95
166
|
content: "";
|
|
96
167
|
position: absolute;
|
|
97
168
|
top: -11px; /* -(background square size + half width of line) */
|
|
98
169
|
left: 0;
|
|
99
170
|
width: 100%;
|
|
100
|
-
border-
|
|
101
|
-
|
|
171
|
+
border-color: rgba(217, 83, 79, 0.8);
|
|
172
|
+
border-style: solid;
|
|
173
|
+
border-width: 2px 0 0 0;
|
|
102
174
|
}
|
|
103
175
|
|
|
104
176
|
/* 本姓人与上一层父母的连线,借助伪元素::before实现 */
|
|
@@ -111,7 +183,7 @@
|
|
|
111
183
|
/* 处理同一层中特殊的末节点 */
|
|
112
184
|
.orgchart .couple:last-child:not(:only-child)::before {
|
|
113
185
|
width: calc(50% + 71px);
|
|
114
|
-
left:
|
|
186
|
+
left: 0;
|
|
115
187
|
}
|
|
116
188
|
|
|
117
189
|
.orgchart .hierarchy.couple:only-child::before {
|
|
@@ -212,24 +284,24 @@
|
|
|
212
284
|
background-color: rgba(238, 217, 54, 0.5);
|
|
213
285
|
}
|
|
214
286
|
/* excluding root node */
|
|
215
|
-
.orgchart > ul > li > ul li > .node
|
|
287
|
+
.orgchart > ul > li > ul li > .node::before {
|
|
216
288
|
content: "";
|
|
217
289
|
position: absolute;
|
|
218
|
-
top: var(--top, -12px); /* -(fallback value = background square size + border width of node) */
|
|
219
290
|
left: calc(50% - 1px);
|
|
220
291
|
width: 2px;
|
|
221
|
-
height: var(--height, 10px); /* fallback value = background square size */
|
|
222
292
|
background-color: rgba(217, 83, 79, 0.8);
|
|
293
|
+
top: var(--top, -12px); /* -(fallback value = background square size + border width of node) */
|
|
294
|
+
height: var(--height, 10px); /* fallback value = background square size */
|
|
223
295
|
}
|
|
224
296
|
|
|
225
297
|
.orgchart > ul > li > ul li > .node.outsider::before {
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
298
|
+
background-color: unset;
|
|
299
|
+
background-image: repeating-linear-gradient(
|
|
300
|
+
to bottom,
|
|
301
|
+
rgba(217, 83, 79, 0.8) 0 2px,
|
|
302
|
+
transparent 2px 4px
|
|
303
|
+
);
|
|
304
|
+
background-repeat: repeat-y;
|
|
233
305
|
}
|
|
234
306
|
|
|
235
307
|
.orgchart > ul > li > ul .isSiblingsCollapsed > .node::before {
|
|
@@ -471,19 +543,56 @@
|
|
|
471
543
|
bottom: -2px;
|
|
472
544
|
width: 16px;
|
|
473
545
|
height: 16px;
|
|
546
|
+
visibility: hidden;
|
|
547
|
+
background-color: rgba(68, 157, 68, 0.6);
|
|
548
|
+
}
|
|
549
|
+
|
|
550
|
+
.orgchart .node:hover .toggleBtn {
|
|
551
|
+
visibility: visible;
|
|
474
552
|
}
|
|
475
553
|
|
|
476
554
|
.orgchart .node .toggleBtn::before {
|
|
477
|
-
|
|
555
|
+
content: "";
|
|
478
556
|
position: absolute;
|
|
479
|
-
left:
|
|
480
|
-
|
|
557
|
+
left: 3px;
|
|
558
|
+
top: 7px;
|
|
559
|
+
box-sizing: border-box;
|
|
560
|
+
width: 10px;
|
|
561
|
+
height: 2px;
|
|
562
|
+
border-radius: 1px;
|
|
563
|
+
background-color: #fff;
|
|
564
|
+
display: none;
|
|
481
565
|
}
|
|
482
566
|
|
|
483
|
-
.orgchart .node .toggleBtn:hover
|
|
567
|
+
.orgchart .node .toggleBtn:hover {
|
|
484
568
|
background-color: #449d44;
|
|
485
569
|
}
|
|
486
570
|
|
|
571
|
+
.orgchart .node .toggleBtn::after {
|
|
572
|
+
content: "";
|
|
573
|
+
position: absolute;
|
|
574
|
+
left: 7px;
|
|
575
|
+
top: 3px;
|
|
576
|
+
width: 2px;
|
|
577
|
+
height: 10px;
|
|
578
|
+
border-radius: 1px;
|
|
579
|
+
background-color: #fff;
|
|
580
|
+
display: none;
|
|
581
|
+
}
|
|
582
|
+
|
|
583
|
+
.orgchart .node .toggleBtn.oci-plus-square::before,
|
|
584
|
+
.orgchart .node .toggleBtn.oci-plus-square::after {
|
|
585
|
+
display: block;
|
|
586
|
+
}
|
|
587
|
+
|
|
588
|
+
.orgchart .node .toggleBtn.oci-minus-square::before {
|
|
589
|
+
display: block;
|
|
590
|
+
}
|
|
591
|
+
|
|
592
|
+
.orgchart .node .toggleBtn.oci-minus-square::after {
|
|
593
|
+
display: none;
|
|
594
|
+
}
|
|
595
|
+
|
|
487
596
|
.oc-export-btn {
|
|
488
597
|
margin-left: 0.5rem;
|
|
489
598
|
padding: 0.5rem 1rem;
|
|
@@ -560,24 +669,21 @@
|
|
|
560
669
|
content: '';
|
|
561
670
|
position: absolute;
|
|
562
671
|
left: -6px; /* -(background square size + half width of line */
|
|
672
|
+
width: 11px; /* background square size + half width of line */
|
|
563
673
|
border-color: rgba(217, 83, 79, 0.8);
|
|
564
674
|
border-style: solid;
|
|
565
|
-
border-width: 0 0 2px 2px;
|
|
566
|
-
}
|
|
567
|
-
|
|
568
|
-
.orgchart .nodes.vertical .hierarchy:only-child::before {
|
|
569
|
-
width: 11px;
|
|
570
675
|
}
|
|
571
676
|
|
|
572
677
|
.orgchart .nodes.vertical .hierarchy::before {
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
width:
|
|
678
|
+
height: 26px;
|
|
679
|
+
top: 0;
|
|
680
|
+
border-width: 0 0 2px 2px;
|
|
576
681
|
}
|
|
577
682
|
|
|
578
683
|
.orgchart .nodes.vertical .hierarchy::after {
|
|
684
|
+
height: calc(100% - 24px); /* node top half's height(25px) + half width of line */
|
|
579
685
|
bottom: 0;
|
|
580
|
-
|
|
686
|
+
border-width: 0 0 0 2px;
|
|
581
687
|
}
|
|
582
688
|
|
|
583
689
|
.orgchart .nodes.vertical .hierarchy:last-child::after {
|
|
@@ -585,7 +691,6 @@
|
|
|
585
691
|
}
|
|
586
692
|
|
|
587
693
|
.orgchart .nodes.vertical > .hierarchy:first-child::before {
|
|
588
|
-
box-sizing: border-box;
|
|
589
694
|
top: -11px; /* -(background square size + half width of line) */
|
|
590
695
|
height: 35px; /* node top half's height + node padding + node border width + background square size */
|
|
591
696
|
width: calc(50% + 2px);
|
|
@@ -593,19 +698,16 @@
|
|
|
593
698
|
}
|
|
594
699
|
|
|
595
700
|
.orgchart .nodes.vertical > .hierarchy:first-child::after {
|
|
596
|
-
box-sizing: border-box;
|
|
597
701
|
top: 24px; /* node bottom half's height(25px) - half border width of line */
|
|
598
|
-
width: 11px; /* backgroud square size + half border width of line */
|
|
599
702
|
border-width: 2px 0 0 2px;
|
|
600
703
|
}
|
|
601
704
|
|
|
602
|
-
.orgchart .nodes.vertical > .hierarchy:
|
|
705
|
+
.orgchart .nodes.vertical > .hierarchy:only-child::after {
|
|
603
706
|
border-width: 2px 0 0 0;
|
|
604
707
|
}
|
|
605
708
|
|
|
606
709
|
/* styles for compact nodes */
|
|
607
710
|
.orgchart .node.compact {
|
|
608
|
-
position: static;
|
|
609
711
|
display: grid;
|
|
610
712
|
width: 140px;
|
|
611
713
|
height: 50px;
|
|
@@ -613,7 +715,6 @@
|
|
|
613
715
|
}
|
|
614
716
|
|
|
615
717
|
.orgchart .node.compact.looseMode {
|
|
616
|
-
display: grid;
|
|
617
718
|
width: unset;
|
|
618
719
|
height: unset;
|
|
619
720
|
}
|
|
@@ -656,14 +757,14 @@
|
|
|
656
757
|
background-color: #eee;
|
|
657
758
|
}
|
|
658
759
|
|
|
659
|
-
.orgchart .node.compact::before {
|
|
760
|
+
/* .orgchart .node.compact::before {
|
|
660
761
|
top: var(--top-cross-point, -10px);
|
|
661
|
-
}
|
|
762
|
+
} */
|
|
662
763
|
|
|
663
764
|
.orgchart .node.compact > .content {
|
|
664
765
|
position: absolute;
|
|
665
|
-
top:
|
|
666
|
-
left:
|
|
766
|
+
top: 23px;
|
|
767
|
+
left: 3px;
|
|
667
768
|
}
|
|
668
769
|
|
|
669
770
|
.orgchart .node.compact.looseMode > .title {
|
|
@@ -672,8 +773,8 @@
|
|
|
672
773
|
}
|
|
673
774
|
|
|
674
775
|
.orgchart .node.compact.looseMode > .content {
|
|
675
|
-
top:
|
|
676
|
-
left:
|
|
776
|
+
top: 28px;
|
|
777
|
+
left: 8px;
|
|
677
778
|
}
|
|
678
779
|
|
|
679
780
|
.orgchart .node.compact > .node.compact.looseMode > .title {
|
|
@@ -706,33 +807,11 @@
|
|
|
706
807
|
|
|
707
808
|
.orgchart .node.compact > .backToCompactSymbol {
|
|
708
809
|
position: absolute;
|
|
709
|
-
top: 5px;
|
|
710
|
-
left: 5px;
|
|
711
|
-
}
|
|
712
|
-
|
|
713
|
-
.orgchart .node.compact.looseMode > .backToCompactSymbol {
|
|
714
|
-
top: 10px;
|
|
715
|
-
left: 10px;
|
|
716
|
-
}
|
|
717
|
-
|
|
718
|
-
.orgchart .node.compact > .node.compact.looseMode > .backToCompactSymbol {
|
|
719
810
|
top: 8px;
|
|
720
811
|
left: 8px;
|
|
721
812
|
}
|
|
722
813
|
|
|
723
|
-
.orgchart .node.compact > .node.compact > .backToCompactSymbol {
|
|
724
|
-
position: absolute;
|
|
725
|
-
top: 3px;
|
|
726
|
-
left: 3px;
|
|
727
|
-
}
|
|
728
|
-
|
|
729
814
|
.orgchart .node.compact > .backToLooseSymbol {
|
|
730
|
-
position: absolute;
|
|
731
|
-
top: 25px;
|
|
732
|
-
right: 5px;
|
|
733
|
-
}
|
|
734
|
-
|
|
735
|
-
.orgchart .node.compact > .node.compact > .backToLooseSymbol {
|
|
736
815
|
position: absolute;
|
|
737
816
|
top: 23px;
|
|
738
817
|
right: 3px;
|
|
@@ -859,27 +938,11 @@
|
|
|
859
938
|
}
|
|
860
939
|
|
|
861
940
|
.oci-plus-square::before {
|
|
862
|
-
content: "
|
|
863
|
-
display: inline-block;
|
|
864
|
-
width: 16px;
|
|
865
|
-
height: 16px;
|
|
866
|
-
text-align: center;
|
|
867
|
-
line-height: 16px;
|
|
868
|
-
background-color: #000;
|
|
869
|
-
color: #fff;
|
|
870
|
-
font-weight: bold;
|
|
941
|
+
content: "";
|
|
871
942
|
}
|
|
872
943
|
|
|
873
944
|
.oci-minus-square::before {
|
|
874
|
-
content: "
|
|
875
|
-
display: inline-block;
|
|
876
|
-
width: 16px;
|
|
877
|
-
height: 16px;
|
|
878
|
-
text-align: center;
|
|
879
|
-
line-height: 16px;
|
|
880
|
-
background-color: #000;
|
|
881
|
-
color: #fff;
|
|
882
|
-
font-weight: bold;
|
|
945
|
+
content: "";
|
|
883
946
|
}
|
|
884
947
|
|
|
885
948
|
.oci-arrow-square-up::before {
|