g6-editor icon indicating copy to clipboard operation
g6-editor copied to clipboard

如何禁止已经连接节点的线段不被拖动?

Open PatrickChou opened this issue 6 years ago • 0 comments

目前没有找到方法,本人的解决办法是: graph.on('dragstart', (ev)=>{ if(ev.shape && ev.shape.eventPreFix == 'edgeControlPoint') { // 下段代码为报错代码,人为让该方法报错,可以阻止线段移动 xDom = domX, yDom = domY; } });

PatrickChou avatar Sep 20 '18 06:09 PatrickChou