ui-chart icon indicating copy to clipboard operation
ui-chart copied to clipboard

Y-axis is not adjusting to barheight in barchart on IOS

Open sockRa opened this issue 2 years ago • 2 comments

Summary The bars are going outside the barchart on IOS. The code runs fine on android, and the strange thing is that it does not help when I revert the ui-chart version to a version I know has worked, because it is live right now.

I suspect it has something to do with the IOS version (17), just because reverting the package version is not helping.

image

Expected Behavior I expect it to behave equally on both android and IOS. image

Possible Solution

Device (please complete the following information):

  • Device: iPhone 15 pro (simulator 17.0), Iphone 14 pro (17.1.2)
  • Library Version ui-chart 1.2.32, core 8.6.0

Additional Context

sockRa avatar Dec 13 '23 06:12 sockRa

Found a workaround.

This is a snippet of the current code:

<GridLayout padding="0,0,5,0" [height]="chartHeight" rows="*, auto">
 <BarChart *ngIf="chartSeriesData" class="m-x-8" row="0" (loaded)="onChartLoaded($event)"></BarChart>
 ...
 </GridLayout>

If I add a small margin to the GridLayout, then it looks like it should.

<GridLayout padding="0,0,5,0" [height]="chartHeight" rows="*, auto" class="m-y-8">

sockRa avatar Dec 13 '23 07:12 sockRa

@sockRa does it work fine on iOS < 17 ? It would be nice if you could create a reproducible example so that i can look at it and find the true issue either in the plugin or in N.

farfromrefug avatar Dec 13 '23 08:12 farfromrefug