antvis/G2

5.1.15: tooltiip .g2-tooltip defaulting to Roboto-Regular #6161

sspilleman posted onGitHub

How to reproduce: Take a simple barchart with a tooltip: .g2-tooltip class is 'font-family': 'Roboto-Regular' Which is not installed in my project so it looks inconsistent with e.g. legend and other fonts selected by default for the chart

Expected 'font-family': inherit OR whatever font is selected by default for other chart elements like legend

Workaround:

chart.interaction('tooltip', {
    css: {
        '.g2-tooltip': {
            'font-family': `inherit` <------------
        }
    }
});

Software macOS, Chrome


please comment and close if you don't think this is an issue....

posted by sspilleman about 1 year ago

the font of tooltip and legend should be the same value.

posted by hustcc about 1 year ago

the font of tooltip and legend should be the same value.

Then its a bug ;-)

posted by sspilleman about 1 year ago

Fund this Issue

$0.00
Funded

Pull requests