chore(package): update package version

This commit is contained in:
yilin.qyl 2019-03-22 10:55:32 +08:00
parent 4853e2d638
commit 1fa3892db8
4 changed files with 6 additions and 3 deletions

View File

@ -1,6 +1,6 @@
{
"name": "@antv/g6",
"version": "3.0.0-rc.4",
"version": "3.0.0",
"description": "graph visualization frame work",
"main": "build/g6.js",
"homepage": "https://github.com/antvis/g6",

View File

@ -3,7 +3,7 @@
*/
module.exports = {
version: '3.0.0-rc.4',
version: '3.0.0',
rootContainerClassName: 'root-container',
nodeContainerClassName: 'node-container',
edgeContainerClassName: 'edge-container',

View File

@ -309,5 +309,8 @@ Shape.registerEdge('cubic-horizontal', {
Shape.registerEdge('loop', {
getPathPoints(cfg) {
return Util.getLoopCfgs(cfg);
},
getControlPoints(cfg) {
return cfg.controlPoints;
}
}, 'cubic');

View File

@ -51,7 +51,7 @@ const GraphicUtil = {
.getMatrix();
const bbox = item.getKeyShape()
.getBBox();
const loopCfg = cfg.loopCfg;
const loopCfg = cfg.loopCfg || {};
// 距离keyShape边的最高距离
const dist = loopCfg.dist || Math.max(bbox.width, bbox.height) * 2;
// 自环边与keyShape的相对位置关系