From 103fda1d9195c31b1b1bd4261aa01ba8a05ae7d7 Mon Sep 17 00:00:00 2001 From: Jonas Jenwald Date: Mon, 13 Mar 2023 16:56:36 +0100 Subject: [PATCH] Update the `canvasContext` parameter, in RenderParameters (issue 16133) Hopefully this works correctly (since I don't know anything about TypeScript), given that `CanvasRenderingContext2D` is a standard name; please see https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D --- src/display/api.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/display/api.js b/src/display/api.js index 20c78009e..f5b0a9f75 100644 --- a/src/display/api.js +++ b/src/display/api.js @@ -1169,7 +1169,8 @@ class PDFDocumentProxy { * Page render parameters. * * @typedef {Object} RenderParameters - * @property {Object} canvasContext - A 2D context of a DOM Canvas object. + * @property {CanvasRenderingContext2D} canvasContext - A 2D context of a DOM + * Canvas object. * @property {PageViewport} viewport - Rendering viewport obtained by calling * the `PDFPageProxy.getViewport` method. * @property {string} [intent] - Rendering intent, can be 'display', 'print',