Closed schnerd closed 2 years ago
Fixes this rounding issue:
So that ticks are calculated without rounding errors.
You can run getChartIntervals(0.8) to replicate this behavior:
getChartIntervals(0.8) === [ 0, 0.2, 0.4, 0.6000000000000001, 0.8 ]
I'm on version 1.6.1. Couldn't test 1.6.2 because it caused a separate bug for me and also the css file isn't present in dist/: https://unpkg.com/browse/frappe-charts@1.6.2/dist/
See above
Create a chart where the maximum value is 0.8.
I tried to write some test cases for this but the project doesn't have a test command (even thought it has some test files)
test
@scmmishra Can you do a build+release with this change?
Explanation About What Code Achieves:
Fixes this rounding issue:![image](https://user-images.githubusercontent.com/875591/127074361-31ba17c7-409e-45f2-926b-8cab8903d4d3.png)
So that ticks are calculated without rounding errors.
You can run getChartIntervals(0.8) to replicate this behavior:
I'm on version 1.6.1. Couldn't test 1.6.2 because it caused a separate bug for me and also the css file isn't present in dist/: https://unpkg.com/browse/frappe-charts@1.6.2/dist/
Screenshots/GIFs:
See above
Steps To Test:
Create a chart where the maximum value is 0.8.
I tried to write some test cases for this but the project doesn't have a
test
command (even thought it has some test files)