File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -218,9 +218,10 @@ class Grid implements CoordinateSystemMaster {
218218 gridRect . width -= lastLabelRect . width / 2 - Number ( boxLayoutParams . right ) + margin ;
219219 }
220220 //Long first label still exceeds the left boundary even when yAxis on the left
221- if ( firstLabelRect . width / 2 >= Number ( boxLayoutParams . left ) + labelUnionRect . width ) {
222- gridRect . width -= firstLabelRect . width / 2 - Number ( boxLayoutParams . left ) - labelUnionRect . width + margin ;
223- gridRect . x += firstLabelRect . width / 2 - Number ( boxLayoutParams . left ) - labelUnionRect . width + margin ;
221+ let leftMargin = Number ( boxLayoutParams . left ) ;
222+ if ( firstLabelRect . width / 2 >= leftMargin + labelUnionRect . width ) {
223+ gridRect . width -= firstLabelRect . width / 2 - leftMargin - labelUnionRect . width + margin ;
224+ gridRect . x += firstLabelRect . width / 2 - leftMargin - labelUnionRect . width + margin ;
224225 }
225226 }
226227 adjustAxes ( ) ;
You can’t perform that action at this time.
0 commit comments