apache / apache/echarts

[Feature] Bar Chart Sizing & positioning Options

Open
#21,234 1 comment 0 reactions 0 assignees View on GitHub
en new-feature pending
Dominant language
TypeScript
Stars
67.3k
Forks
19.8k
Avg merge
11d 14h
Merged PRs (30d)
8

Description

### What problem does this feature solve?
`

series: [
{
type: 'pie',
radius: '61%',
center: ['30%', '60%'],
selectedMode: 'single',
.
.
.
}
]
`

The pie chart can be adjusted in size by using the radius value in the series, and the position can be adjusted by using the center value, right?

`

series: [
{
name: 'bar',
type: 'bar',
stack: 'one',
emphasis: emphasisStyle,
data: data1
},
{
name: 'bar2',
type: 'bar',
stack: 'one',
emphasis: emphasisStyle,
data: data2
},
{
name: 'bar3',
type: 'bar',
stack: 'two',
emphasis: emphasisStyle,
data: data3
},
{
name: 'bar4',
type: 'bar',
stack: 'two',
emphasis: emphasisStyle,
data: data4
}
]
`

By the way, I wonder if there is no separate option to set the size or position in the bar graph.

### What does the proposed API look like?

series: [
{
type: 'pie',
radius: '61%',
center: ['30%', '60%'],
selectedMode: 'single',
.
.
.
}
]

series: [
{
name: 'bar',
type: 'bar',
stack: 'one',
emphasis: emphasisStyle,
data: data1
},
{
name: 'bar2',
type: 'bar',
stack: 'one',
emphasis: emphasisStyle,
data: data2
},
{
name: 'bar3',
type: 'bar',
stack: 'two',
emphasis: emphasisStyle,
data: data3
},
{
name: 'bar4',
type: 'bar',
stack: 'two',
emphasis: emphasisStyle,
data: data4
}
]

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.