0.0.36-beta22 • Published 4 months ago
@whalecloud/fishtopo-flow v0.0.36-beta22
@whalecloud/fishtopo-flow
fishTopoFlow 库,支持 react
Install
npm i @whalecloud/fishtopo-flow
Usage
import { FishTopoFlow } from '@whalecloud/fishtopo-flow';
import { Image, Rect } from '@whalecloud/fishtopo-flow/lib/node';
import { Curve } from '@whalecloud/fishtopo-flow/lib/link';
this.fishtopo = new FishTopoFlow(document.getElementById("flowIns"), {
deleteShow: true,
linkShow: true,
linkModify: true,
roam: false
});
const imageNode = new Image({
style: {
image: "https://fish.iwhalecloud.com/fish-topo-develop/examples/flow/img/network/4_cloud.svg",
width:120,
height:70,
text:"server",
textPosition:"bottom"
},
position:[10,10]
});
const rect = new Rect({
shape: { width: 100, height: 60 },
position: [300, 300],
tooltip: "矩形",
hoverStyle: { fill: "#FF0000" }
});
const newCurveLink = (startNode, endNode, text, direction, dashedPattern) => {
return new Curve(startNode, endNode, {
style: {
lineDash: [dashedPattern]
},
text: {
text: text
},
pos: direction
})
}
const link = newCurveLink(rect, imageNode, '曲线', "bottom, left", 2);
this.fishtopo.add(imageNode);
this.fishtopo.add(rect);
this.fishtopo.add(link);
0.0.36-beta22
4 months ago
0.0.36-beta21
5 months ago
0.0.36-beta20
1 year ago
0.0.36-beta17
2 years ago
0.0.36-beta18
2 years ago
0.0.36-beta19
1 year ago
0.0.36-beta13
2 years ago
0.0.36-beta14
2 years ago
0.0.36-beta15
2 years ago
0.0.36-beta16
2 years ago
0.0.36-beta12
2 years ago
0.0.36-beta11
3 years ago
0.0.36-beta8
3 years ago
0.0.36-beta9
3 years ago
0.0.36-beta10
3 years ago
0.0.36-beta6
3 years ago
0.0.36-beta7
3 years ago
0.0.36-beta5
3 years ago
0.0.36-beta4
3 years ago
0.0.35-beta4
3 years ago
0.0.32-beta4
3 years ago
0.0.34-beta4
3 years ago
0.0.33-beta4
3 years ago
0.0.32-beta3
3 years ago
0.0.32-beta2
4 years ago
0.0.32-beta1
4 years ago
0.0.32
4 years ago
0.0.30
4 years ago
0.0.31
4 years ago
0.0.29
4 years ago
0.0.28
4 years ago
0.0.27
4 years ago
0.0.26
4 years ago
0.0.25
4 years ago
0.0.24
4 years ago
0.0.23
4 years ago
0.0.20
4 years ago
0.0.21
4 years ago
0.0.22
4 years ago
0.0.19
4 years ago
0.0.18
4 years ago
0.0.17
4 years ago
0.0.16
4 years ago
0.0.15
4 years ago
0.0.13
4 years ago
0.0.14
4 years ago
0.0.12
4 years ago
0.0.11
4 years ago
0.0.10
4 years ago
0.0.9
4 years ago
0.0.8
4 years ago
0.0.7
4 years ago
0.0.6
4 years ago
0.0.5
4 years ago
0.0.4
4 years ago
0.0.3
4 years ago
0.0.2
4 years ago
0.0.1
4 years ago