Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better tick placement for scales with binary tick formatting #1395

Closed
3 tasks done
flash1293 opened this issue Sep 21, 2021 · 1 comment · Fixed by #1389
Closed
3 tasks done

Better tick placement for scales with binary tick formatting #1395

flash1293 opened this issue Sep 21, 2021 · 1 comment · Fixed by #1389
Assignees
Labels
enhancement New feature or request Impact:High kibana cross issue Has a Kibana issue counterpart released Issue released publicly

Comments

@flash1293
Copy link

Is your feature request related to a problem? Please describe.

As explained in this issue elastic/kibana#7539 - a bytes formatter is dividing the raw number of a tick by powers of two like 1024 or 1048576 before displaying the value. Elastic charts tries to find "nice" tick placements like 500 or 1000 which lead to odd looking tick labels

Describe the solution you'd like
It should be possible to instruct elastic-charts to try to place ticks at different positions which are a better fit for the formatter (like 1024 or 1048576 instead of 1000 and 1000000)

Describe alternatives you've considered
If the formatter is using the same unit (like KB) for each tick, it would theoretically be possible to divide the actual value in the data array by 1024, then multiplying by 1024 again before formatting the label. Elastic charts would try to find nice tick placements like 1, which will be turned into 1KB by formatting.

Kibana Cross Issues
elastic/kibana#7539

Checklist

Delete any items that are not applicable to this feature request.

  • this request is checked against already exist requests
  • every related Kibana issue is listed under Kibana Cross Issues list
  • kibana cross issue tag is associated to the issue if any kibana cross issue is present
@flash1293 flash1293 added enhancement New feature or request kibana cross issue Has a Kibana issue counterpart labels Sep 21, 2021
@nickofthyme nickofthyme self-assigned this Sep 22, 2021
@nickofthyme
Copy link
Collaborator

🎉 This issue has been resolved in version 38.0.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@nickofthyme nickofthyme added the released Issue released publicly label Oct 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Impact:High kibana cross issue Has a Kibana issue counterpart released Issue released publicly
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants