Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make downloadManager optional in JSDoc types #17029

Closed
wojtekmaj opened this issue Sep 25, 2023 · 0 comments · Fixed by #17038 or #17608
Closed

Make downloadManager optional in JSDoc types #17029

wojtekmaj opened this issue Sep 25, 2023 · 0 comments · Fixed by #17038 or #17608

Comments

@wojtekmaj
Copy link
Contributor

Reading from the source code:

this.downloadManager?.openOrDownloadData(

it appears to me it was not an intention to mark downloadManager as a required parameter in AnnotationLayerParameters:

* @property {IDownloadManager} downloadManager

and AnnotationLayerBuilderOptions:

* @property {IDownloadManager} downloadManager

and it should be optional, similarly to accessibilityManager for example:

* @property {TextAccessibilityManager} [accessibilityManager]

Configuration:

  • PDF.js version: 2.11.174
  • Is a browser extension: no

What is the expected behavior? (add screenshot)

downloadManager to be optional

What went wrong? (add screenshot)

downloadManager marked as required

Link to a viewer (if hosted on a site other than mozilla.github.io/pdf.js or as Firefox/Chrome extension):

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant