[v9.2.x] Heatmap: Fix blurry text & rendering (#59261)

Heatmap: Fix blurry text & rendering (#59260)

(cherry picked from commit 6f00bc5674)

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
This commit is contained in:
Grot (@grafanabot)
2022-11-23 23:12:12 -05:00
committed by GitHub
co-authored by Leon Sorokin
parent 09308c77d8
commit 6fbdc2ed89
@@ -65,8 +65,8 @@ export class UPlotChart extends Component<PlotProps, UPlotChartState> {
});
const config: Options = {
width: this.props.width,
height: this.props.height,
width: Math.floor(this.props.width),
height: Math.floor(this.props.height),
...this.props.config.getConfig(),
};
@@ -93,8 +93,8 @@ export class UPlotChart extends Component<PlotProps, UPlotChartState> {
if (!sameDims(prevProps, this.props)) {
plot?.setSize({
width: this.props.width,
height: this.props.height,
width: Math.floor(this.props.width),
height: Math.floor(this.props.height),
});
} else if (!sameConfig(prevProps, this.props)) {
this.reinitPlot();