Try to expose more API-functionality in the TypeScript definitions
While these types apparently makes sense in TypeScript environments, we really don't want to extend the *public* API by simply exporting the relevant classes directly in `src/pdf.js` (since they should never be called/initialized manually). Please see e.g. issue 12384 where this was first requested, and note that a possible work-around was also provided there. This patch simply implements that work-around[1], which will hopefully be helpful to TypeScript users. --- [1] Based on the discussion in PR 13957, the two previous patches appear to be necessary for this to actually work.
This commit is contained in:
parent
d854352cd5
commit
95057a4e56
@ -14,6 +14,12 @@
|
||||
*/
|
||||
/* eslint-disable sort-exports/sort-exports */
|
||||
|
||||
// eslint-disable-next-line max-len
|
||||
/** @typedef {import("./display/api").PDFDocumentLoadingTask} PDFDocumentLoadingTask */
|
||||
/** @typedef {import("./display/api").PDFDocumentProxy} PDFDocumentProxy */
|
||||
/** @typedef {import("./display/api").PDFPageProxy} PDFPageProxy */
|
||||
/** @typedef {import("./display/api").RenderTask} RenderTask */
|
||||
|
||||
import {
|
||||
addLinkAttributes,
|
||||
getFilenameFromUrl,
|
||||
|
Loading…
x
Reference in New Issue
Block a user