mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-08 01:10:08 +02:00
Update the Annotation --zoom-factor
CSS variable when PDFPageView
is used standalone (PR 13868 follow-up)
Without this patch, when using `PDFPageView` directly[1] this CSS variable won't be updated and consequently things won't work as intended. This is purposely implemented such that when a `PDFPageView`-instance is part of a viewer, we don't repeatedly set the CSS variable for every single page. --- [1] See e.g. the "pageviewer" example in the `examples/components/` folder.
This commit is contained in:
parent
4ad65c8b9c
commit
561faa7c94
3 changed files with 12 additions and 2 deletions
|
@ -60,6 +60,13 @@ class PDFRenderingQueue {
|
|||
return this.highestPriorityPage === view.renderingId;
|
||||
}
|
||||
|
||||
/**
|
||||
* @returns {boolean}
|
||||
*/
|
||||
hasViewer() {
|
||||
return !!this.pdfViewer;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {Object} currentlyVisiblePages
|
||||
*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue