use devicePixelRatio in additional scales logic

This commit is contained in:
vcoppe
2024-07-18 15:26:31 +02:00
parent f20116b080
commit 923e47cc45

View File

@@ -62,7 +62,7 @@
let canvas: HTMLCanvasElement;
let showAdditionalScales = true;
let updateShowAdditionalScales = () => {
showAdditionalScales = canvas.width >= 600;
showAdditionalScales = canvas.width / window.devicePixelRatio >= 600;
};
let overlay: HTMLCanvasElement;
let chart: Chart;