Comments (7)
原因getAnchorPoints已经被我写死在代码里只能返回固定的数组了,你可以把getAnchorPoints方法去掉,然后他就会触发这段G6的代码了
getAnchorPoints(cfg: ModelConfig): number[][] | undefined {
const { anchorPoints: defaultAnchorPoints } = this.options as ModelConfig;
const anchorPoints = cfg.anchorPoints || defaultAnchorPoints;
return anchorPoints;
}
from wfd-vue.
原因getAnchorPoints已经被我写死在代码里只能返回固定的数组了,你可以把getAnchorPoints方法去掉,然后他就会触发这段G6的代码了
getAnchorPoints(cfg: ModelConfig): number[][] | undefined {
const { anchorPoints: defaultAnchorPoints } = this.options as ModelConfig;
const anchorPoints = cfg.anchorPoints || defaultAnchorPoints;
return anchorPoints;
}
好的,我试试去,谢谢啦
from wfd-vue.
已经实现这个功能,修改绘制锚点的方法,然后确保在选择了锚点数后,能获取到数据中的anchorPoints即可。
from wfd-vue.
nice
from wfd-vue.
from wfd-vue.
behavior下面有个dragPanelItemAddNode.ts,这是拖动节点进来的实现,115行是增加节点到画布的代码,你打印一下试试
from wfd-vue.
问题解决了,是在addItemPanel.js中,修改文件的时候,class类写的有问题,造成没有获取到children。
from wfd-vue.
Related Issues (20)
- 请问怎么设置线条的连线方式,让节点直接直线连接,不出现拐点
- 远程请求来的数据不能拖动到右边画布(刷新页面之后不可以,代码热更新是可以的) HOT 5
- 在线demo进去是空的 HOT 7
- Pickup a license, please
- 查看流程图显示不全,自适应按钮失效
- 节点文字溢出,怎么显示更多文字,或者自动换行
- 拖动画布,添加节点到画布左侧失败 HOT 2
- 更新g6版本后(4.26),不能连线了 HOT 10
- 节点及连线设置样式 标记历史节点怎么设置啊?
- 编辑状态下,groups节点分组里的节点不能和group之外的节点关联,怎么触发点击group区域的点击事件呀?
- 大佬,想请教您写的源码问题,我看代码里的插件比如AddItemPanel,都不是g6里提供的,请问您是自己写的吗? HOT 4
- 为什么我拉下来运行后连线不是特别灵敏? HOT 3
- 启动报错: Cannot read properties of undefined (reading 'shape') HOT 1
- xml文件无法下载 HOT 2
- 支持vue3吗?
- > @gzhanghui老哥,请教下,更新至4.1以上版本以后 HOT 6
- @gzhanghui 老哥,请教下,更新至4.1以上版本以后
- 大佬能开发vue3版本的不
- 大佬能开发vue3版本的不
- 再不更新vue3,就要被淘汰了哦,加油,大佬。期待
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wfd-vue.