Configure chart color

How can i change the color of an chart element like color of bar in bar chart or in pie chart?

4 Likes

You can directly change the colour of chart in source code.

Simply, You have to add these key values in JSON of chart in a particular bar data to change the colour of bar in a bar graph in the following sequence

series → data → itemstyle → color

eg -
itemStyle: {
color: ‘#a90000’
}

and same in pie graph

eg -
{ value: 1001, name: ‘vFlow’,
itemStyle: {
color: ‘#a90000’
}
}

46 Likes

The chart library used by vFlow is Apache echarts. You can configure any property of charts in accordance with library as @Nikhil.Dhanda suggested.

3 Likes

To check the chart examples:

To check the properties that can be used in charts:

18 Likes