You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@echarts.apache.org by GitBox <gi...@apache.org> on 2018/12/04 01:21:06 UTC
[GitHub] alex1504 opened a new issue #9520: echarts关系节点图怎么直接显示name字段?
alex1504 opened a new issue #9520: echarts关系节点图怎么直接显示name字段?
URL: https://github.com/apache/incubator-echarts/issues/9520
由于项目需求,需要直接显示echarts关系节点的name字段,而非鼠标移入节点的时候才显示。如图:

是否有支持直接显示节点name属性的配置呢?
目前echarts的配置如下:
```js
option = {
legendHoverLink: false,
tooltip: {
show: true,
formatter: '{b0}'
},
legend: {
data: [
{
name: '文件',
icon: "image://../image/file.png"
}, {
name: '文件块',
icon: "image://../image/chunk.png"
}, {
name: '节点',
icon: "image://../image/node.png"
}
]
},
series: [
{
type: 'graph',
layout: 'force',
animation: false,
edgeSymbol: [
'none', 'arrow'
],
label: {
show: false,
position: 'bottom',
color: "#666"
},
symbolSize: 60,
draggable: true,
data: webkitDep
.nodes
.map(function (node, idx) {
node.id = idx;
return node;
}),
categories: webkitDep.categories,
force: {
initLayout: 'circular',
repulsion: 2000,
edgeLength: 300
},
edges: webkitDep.links
}
]
};
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@echarts.apache.org
For additional commands, e-mail: dev-help@echarts.apache.org