apache / apache/echarts

[Bug] sankey chart labels overlap when values are 0

Open
#16,182 0 comments 3 reactions 0 assignees View on GitHub
bug en topic: sankey
Dominant language
TypeScript
Stars
67.3k
Forks
19.8k
Avg merge
11d 14h
Merged PRs (30d)
8

Description

### Version

5.2.2

### Link to minimal reproduction

_No response_

### Steps To Reproduce

go to https://echarts.apache.org/examples/en/editor.html?c=sankey-simple
change all values in links to `0`
example options:
```
option = {
series: {
type: 'sankey',
layout: 'none',
emphasis: {
focus: 'adjacency'
},
data: [
{
name: 'd'
},
{
name: 'b'
},
],
links: [
{
source: 'd',
target: 'b',
value: 0
},
]
}
};
```

### Current Behavior

when the values are zero, text labels overlap.

### Expected Behavior

need to add some spacing between the labels.

### Environment

```markdown
- OS:macOS 10.15.7
- Browser: safari 14.1.2, Chrome 96.0.4664.55
- Framework: -
```

### Any additional comments?

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.