]> git.ipfire.org Git - thirdparty/Chart.js.git/commitdiff
Fix reading wrong property from font object for font string (#8315)
authorLeeLenaleee <39033624+LeeLenaleee@users.noreply.github.com>
Sat, 16 Jan 2021 19:13:13 +0000 (20:13 +0100)
committerGitHub <noreply@github.com>
Sat, 16 Jan 2021 19:13:13 +0000 (21:13 +0200)
src/helpers/helpers.canvas.js

index 0d590444e025adf038afa9122813560050b63d9a..064c5e9c4afaaa9357dbb315a83a53eb80ab3ef1 100644 (file)
@@ -312,7 +312,7 @@ export function renderText(ctx, text, x, y, font, opts = {}) {
                ctx.rotate(opts.rotation);
        }
 
-       ctx.font = font.fontString;
+       ctx.font = font.string;
 
        if (opts.color) {
                ctx.fillStyle = opts.color;