web/admin: add fallback font for doughnut charts

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer 2021-10-14 12:50:52 +02:00
parent f341479732
commit 9a42c5815d

View file

@ -99,7 +99,7 @@ export abstract class AKChart<T> extends LitElement {
const height = chart.height || 0;
const fontSize = (height / 114).toFixed(2);
chart.ctx.font = `${fontSize}em Overpass`;
chart.ctx.font = `${fontSize}em Overpass, Arial, sans-serif`;
chart.ctx.textBaseline = "middle";
chart.ctx.fillStyle = this.fontColour;