@@ -18,7 +18,7 @@ import {
18
18
import { from , fromEvent , Subject } from 'rxjs' ;
19
19
import { debounceTime , filter , takeUntil } from 'rxjs/operators' ;
20
20
import * as PDFJS from 'pdfjs-dist' ;
21
- import * as PDFJSViewer from 'pdfjs-dist/web/pdf_viewer' ;
21
+ import * as PDFJSViewer from 'pdfjs-dist/web/pdf_viewer.mjs ' ;
22
22
23
23
import { createEventBus } from '../utils/event-bus-utils' ;
24
24
import { assign , isSSR } from '../utils/helpers' ;
@@ -32,7 +32,7 @@ import type {
32
32
PDFViewerOptions ,
33
33
ZoomScale
34
34
} from './typings' ;
35
- import { PDFSinglePageViewer } from 'pdfjs-dist/web/pdf_viewer' ;
35
+ import { PDFSinglePageViewer } from 'pdfjs-dist/web/pdf_viewer.mjs ' ;
36
36
37
37
if ( ! isSSR ( ) ) {
38
38
assign ( PDFJS , 'verbosity' , PDFJS . VerbosityLevel . INFOS ) ;
@@ -289,9 +289,9 @@ export class PdfViewerComponent
289
289
this . loadPDF ( ) ;
290
290
} else if ( this . _pdf ) {
291
291
if ( 'renderText' in changes ) {
292
- this . pdfViewer . textLayerMode = this . _renderText
293
- ? this . _renderTextMode
294
- : RenderTextMode . DISABLED ;
292
+ // this.pdfViewer.textLayerMode = this._renderText
293
+ // ? this._renderTextMode
294
+ // : RenderTextMode.DISABLED;
295
295
this . resetPdfDocument ( ) ;
296
296
} else if ( 'showAll' in changes ) {
297
297
this . setupViewer ( ) ;
@@ -341,7 +341,7 @@ export class PdfViewerComponent
341
341
stickToPage = ! this . _stickToPage ;
342
342
}
343
343
344
- this . pdfViewer . _setScale ( scale , stickToPage ) ;
344
+ this . pdfViewer . currentScale = scale ;
345
345
}
346
346
} ) ;
347
347
}
0 commit comments