jsplumbConfig.js
1.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
import {tbType} from './tbType.js'
const jsPlumbSetting = {
grid: [10, 10],
Container: 'flow',
// 连线的样式四种类型:Bezier/Straight/Flowchart/StateMachine
connector: ['StateMachine'],
// 连线的端点
Endpoint: [
'Rectangle',
{
width: 120,
height: 20,
cssClass: 'endpoint-rect'
}
],
// 端点的样式
EndpointStyle: {
fill: '#c4c4c4',
outlineWidth: 1
},
// connectorStyle: {
// stroke:tbType["Union"].color,
// strokeWidth: 2
// },
// connectorHoverStyle: {
// stroke: tbType["RS"].color,
// strokeWidth: 3
// },
// 绘制线
PaintStyle: {
stroke: tbType['Union'].color,
strokeWidth: 3
},
HoverPaintStyle: {
stroke: tbType['RS'].color,
strokeWidth: 4
},
maxConnections: 1, // 设置连接点最多可以连接几条线 -1不限
// 绘制箭头
Overlays: [
[
'Arrow',
{
width: 8,
length: 10,
location: 1
}
]
],
LogEnabled: false //是否打开jsPlumb的内部日志记录
}
export default jsPlumbSetting