Feat:新增节点标签的点击事件
This commit is contained in:
parent
b69a0b620d
commit
e939b6132f
@ -288,6 +288,9 @@ function createTagNode() {
|
|||||||
let nodes = []
|
let nodes = []
|
||||||
tagData.slice(0, this.mindMap.opt.maxTag).forEach((item, index) => {
|
tagData.slice(0, this.mindMap.opt.maxTag).forEach((item, index) => {
|
||||||
let tag = new G()
|
let tag = new G()
|
||||||
|
tag.on('click', () => {
|
||||||
|
this.mindMap.emit('node_tag_click', this, item)
|
||||||
|
})
|
||||||
// 标签文本
|
// 标签文本
|
||||||
let text = new Text().text(item).x(8).cy(8)
|
let text = new Text().text(item).x(8).cy(8)
|
||||||
this.style.tagText(text, index)
|
this.style.tagText(text, index)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user