You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Bug] When pie.minAngle is within the normal range but the set value is relatively large, the size of the sector angle does not match the actual value corresponding to each sector, and there is a problem with the sector enlargement effect when hovering over the sector
#20621
Open
likexin-kk opened this issue
Dec 26, 2024
· 2 comments
The values corresponding to each sector should not be similar.
Check the angles of all sector and the corresponding values of each sector area.
Hover all sector and observe the angle change after hovering
Current Behavior
The correspondence between the size of the angle of the sector and the corresponding classification value of the sector is confusing.
When hovering over the ‘Search Engine’ , the angle of the sector increases.
Expected Behavior
The size of the sector angle corresponds to the size of the value.
When hovering over any sector, only the sector will be magnified without changing the angle of the sector area.
If this is not a bug, unless the user is particularly familiar with the pie.minAngle function, it will be difficult to visually see the proportion of each category, which will affect the user experience
Environment
- OS:
- Browser:
- Framework:
Any additional comments?
No response
The text was updated successfully, but these errors were encountered:
Hello. I happened to see your issue and looked at the link you gave.
For your example, I think there are some configuration items that are not very reasonable (there is also a certain possibility that echarts was not designed with 0 in mind).
First, we need to argue that it makes sense to set a minimum angle when the data in the pie chart has a value of 0.From my point of view, if there is an item in the pie chart with a data value of 0, then the minimum angle of the design is redundant, because there is really no need for the value of 0 to be displayed in the pie chart. Of course, this includes what I said about echart, which was not designed with the special value of 0 in mind.
Secondly, for pie charts, the maximum angle is 360 degrees, and if the angle of the minimum value is set to a static value and this static value is too large, there will be problems. For example, if there are five items in a pie chart, it is mathematically wrong to set the minimum item to an angle of 100, because the minimum angle is 100. Then 100*5>360. Therefore, this minimum angle is best calculated dynamically, and if there is a value of 0 in the data, the minimum angle should be avoided.
of course, the echarts official can further modify the rationality of this configuration item, so that you don't have to think about this problem when you use it.
Version
5.5.1
Link to Minimal Reproduction
https://echarts.apache.org/examples/zh/editor.html?code=PYBwLglsB2AEC8sDeAoWtJgDYFMBcya6GOAHmAQOQBKOAZjgE5OzB2wCGsA6jgEYBnCGByUANEXQCArnxHkqAMQ4BrHLAAiHMB3GTYuOhViUAxjmgjGlIgF8J6MMGBZIIAqmIZGEAOa-mKmEcAFsbdHsiXADoABMPfWAfC2NKADcmSFMOLD0vQ1SC8NhIqSYIHAECAG19Ty9YaA4Q_BMAQVNzAQFYRUZgMIcGsABPEFbKEAq8hsYOWIhpKpMAVgAGAFIZr1jtDhr9LyRYNJzpVoA2MUbmiYBlHA5GUwALWABRaF8IaFESoYayBOZ1aK2uTRaVA0EGYpjAlH-h2Ix1OWHOBAAjGtwbcqO8QhwILlEYD0CiQZiwTdISYAKrQKBwNqxAQI0qk8lo1rY6kTABqEFiOGAsGZrJKSIAugDiKEQC8OEJlvVAcEQndRrgEqTiAIFbFgAB3ABCaMYmOxSK8evmRoA8nQ6AIcGAABoES06qT6o0AYRcSSojF8fA4AAoeZHrmsAHQrACUxUBtiR7K8IR-bS-WtgWLW-hT6ElKFsAG4gA
Steps to Reproduce
Current Behavior
Expected Behavior
If this is not a bug, unless the user is particularly familiar with the pie.minAngle function, it will be difficult to visually see the proportion of each category, which will affect the user experience
Environment
Any additional comments?
No response
The text was updated successfully, but these errors were encountered: