rishyanthkondra opened a new pull request, #21495:
URL: https://github.com/apache/echarts/pull/21495
## Brief Information
This pull request is in the type of:
- [x] bug fixing
- [ ] new feature
- [ ] others
### What does this PR do?
- Fix the condition for recalculating angles due to minAngle & padAngles
- Condition is always true when angle span < 2*PI
- So when span < 2*PI, i.e. endAngle is not `auto`, its unnecessarily
recompute sector angles
- Fix: change 2*PI --> angleRange
### Fixed issues
N.A
## Details
### Before: What was the problem?
// This example requires ECharts v5.5.0 or later
option = {
tooltip: {
trigger: 'item'
},
legend: {
top: '5%',
left: 'center'
},
series: [
{
name: 'Access From',
type: 'pie',
roseType: 'area',
radius: ['40%', '70%'],
center: ['50%', '70%'],
// adjust the start and end angle
startAngle: 180,
endAngle: 360,
data: [
{ value: 1000, name: 'Search Engine' },
{ value: 500, name: 'Direct' },
{ value: 250, name: 'Email' },
]
}
]
};
<img width="800" alt="pie-half-donut"
src="https://github.com/user-attachments/assets/56684969-0d5a-4fc5-a9a0-335f53c9b8bb"
/>
### After: How does it behave after the fixing?
<img width="800" height="600" alt="image"
src="https://github.com/user-attachments/assets/2d2ee398-a2b2-4ace-8783-e630596fd945"
/>
## Document Info
One of the following should be checked.
- [x] This PR doesn't relate to document changes
- [ ] The document should be updated later
- [ ] The document changes have been made in apache/echarts-doc#xxx
## Misc
### Security Checking
- [ ] This PR uses security-sensitive Web APIs.
<!-- PLEASE CHECK IT AGAINST:
<https://github.com/apache/echarts/wiki/Security-Checklist-for-Code-Contributors>
-->
### ZRender Changes
- [ ] This PR depends on ZRender changes (ecomfe/zrender#xxx).
### Related test cases or examples to use the new APIs
N.A.
### Merging options
- [x] Please squash the commits into a single one when merging.
### Other information
N.A.
--
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]