-
Notifications
You must be signed in to change notification settings - Fork 14.4k
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
[vis] fix axis labels display #2066
Conversation
5ede928
to
818f0db
Compare
Would rotating 45 degrees make it more readable? |
rotating 45 degrees makes the chart a bit smaller since we have to increase the right margin to accommodate the last label. when i look at these side by side, i think 90 degree labels work much better. @elibrumbaugh do you have any thoughts on this? @mistercrunch @vera-liu which do you think works better? vs. |
Thanks for sharing this with me @ascott! From a legibility perspective, I think 45° works better than 90° here. However, the shrinking of the graph is an issue. If I had to trade off I would keep the labels 45° and allow the graph to be pushed in. One way I've seen this solved (sort of) in the past is to truncate long labels from the middle or end that are rotated 45°. For example: 1985-01-01 00:00:00 is 1985...00:00. On hover the entire label could be shown. This could also be a toggle to turn them on and off. |
sync'd with @elibrumbaugh on 60 vs 45. we will stick with 45 since it's more standard within our app and others. |
* re-render chart after adjusting for long axis labels * measure all of the labels and take the max height * add missing isTimeSeries var * fix linting * use jQuery to get text ticks * rotate 45 rather than 90
fixes: #1971
before
after
before
after
plz review @airbnb/superset-reviewers