Alexenon opened a new issue, #18857:
URL: https://github.com/apache/echarts/issues/18857
### What problem does this feature solve?
Does somebody know what is the default tooltip.formatter value for pie
charts ? <br>
Currently I am using version `5.4.2`, and for previous versions it was like
this `{a} <br/>{b}: {c} ({d}%)`, but now you can see that there is an icon near
category name, and I want to catch it.
I want to get something similar to this formatter: `{b.icon} {b}: {c} ({d}%)`
More information you can get
[here](https://stackoverflow.com/questions/76624531/echarts-default-value-tooltip-formatter-for-pie-chart)
### What does the proposed API look like?
```
option = {
title: {
text: 'Referer of a Website',
subtext: 'Fake Data',
left: 'center'
},
tooltip: {
trigger: 'item',
formatter: '{b.color} {b}: <b>{c}</b> ({d}%)'
},
legend: {
orient: 'vertical',
left: 'left'
},
series: [
{
name: 'Access From',
type: 'pie',
radius: '50%',
data: [
{ value: 1048, name: 'Search Engine' },
{ value: 735, name: 'Direct' },
{ value: 580, name: 'Email' },
{ value: 484, name: 'Union Ads' },
{ value: 300, name: 'Video Ads' }
],
emphasis: {
itemStyle: {
shadowBlur: 10,
shadowOffsetX: 0,
shadowColor: 'rgba(0, 0, 0, 0.5)'
}
}
}
]
};
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]