google / google-visualization-issues

288 stars 35 forks source link

Setting (unexpected to lib) fontName in ChartRangeFilter's ui breaks initial state computations #2990

Open jwaga opened 1 year ago

jwaga commented 1 year ago

Well, I couldn't believe it either.

Below is a screenshod of a modified jsfiddle originally sourced from https://developers.google.com/chart/interactive/docs/gallery/controls#full-web-page.

It's modified where indicated:

image

If setting 'Arial' as a fontName, the state range of the control is computed and console.logged. If a 'Roboto' font is used, the state range is unspecified.

I was trying to find a list of "allowed" fonts but failed. That's anyway a side story. Whatever the fontName value is, is should not break state range computations.

dlaliberte commented 1 year ago

Axis tick generation can fail to find any alternative that fits the available space without conflict, in which case it will not show any tick labels rather than showing the "best" of the failed attempts. That is probably the cause of the problem here.