swimlane / ngx-charts

:bar_chart: Declarative Charting Framework for Angular
https://swimlane.github.io/ngx-charts/
MIT License
4.29k stars 1.15k forks source link

Cannot wrap/force xAxis/yAxis tick labels to display on next line. #1125

Open Vikki123 opened 5 years ago

Vikki123 commented 5 years ago

I'm submitting a ... (check one with "x")

Current behavior

As of today , when the xAxis trim is false and xAxis labels are more than a specified width, xAxis labels are roated and are shown at an angle(60 deg or so). But i could not find a way to display the full label without rotating the labels.

image

Expected behavior

Should be able to display label without rotated labels and with text wrap as shown. image

Reproduction of the problem

Any charts in the demo site , change the label with a lengthy label.

What is the motivation / use case for changing the behavior? I have a UX requirement where i cannot show the ellipsis on the chart xAxis label. Since the size of my container is very small , if the labels are rotated, the chart will not have sufficient space to display the data as shown.

WIth ticks trimmed

image

With rotated labels image

Please tell us about your environment:

Vikki123 commented 5 years ago

@marjan-georgiev any fix/update for this ?

kevinfrnando commented 5 years ago

can you resolve it?

niralmunjariya commented 5 years ago

I need the same functionality. Any updates or any way to achieve that? Thank you!