ng2-pdfjs-viewer 25.0.10 → 25.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/ng2-pdfjs-viewer.mjs +8 -0
- package/fesm2022/ng2-pdfjs-viewer.mjs.map +1 -1
- package/package.json +1 -1
- package/pdfjs/build/pdf.mjs +22 -22873
- package/pdfjs/build/pdf.sandbox.mjs +22 -218
- package/pdfjs/build/pdf.worker.mjs +22 -58008
- package/pdfjs/build/pdf.mjs.map +0 -1
- package/pdfjs/build/pdf.sandbox.mjs.map +0 -1
- package/pdfjs/build/pdf.worker.mjs.map +0 -1
|
@@ -861,6 +861,10 @@ class PdfJsViewerComponent {
|
|
|
861
861
|
if (changes['pdfSrc'] && !changes['pdfSrc'].firstChange) {
|
|
862
862
|
// pdfSrc changed after initialization - reload the PDF
|
|
863
863
|
if (!this.externalWindow) {
|
|
864
|
+
// Show spinner immediately when PDF source changes (Issue #275)
|
|
865
|
+
this.isLoading = true;
|
|
866
|
+
this.hasError = false;
|
|
867
|
+
this.currentErrorMessage = "";
|
|
864
868
|
// Reset configuration queuing since iframe will reload fresh
|
|
865
869
|
this.initialConfigQueued = false;
|
|
866
870
|
this.isPostMessageReady = false;
|
|
@@ -1605,6 +1609,10 @@ class PdfJsViewerComponent {
|
|
|
1605
1609
|
loadPdf() {
|
|
1606
1610
|
if (!this.validatePdfSource())
|
|
1607
1611
|
return;
|
|
1612
|
+
// Show spinner immediately when PDF loading starts (Issue #275)
|
|
1613
|
+
this.isLoading = true;
|
|
1614
|
+
this.hasError = false;
|
|
1615
|
+
this.currentErrorMessage = "";
|
|
1608
1616
|
this.setupExternalWindow();
|
|
1609
1617
|
const fileUrl = this.createFileUrl();
|
|
1610
1618
|
const viewerUrl = this.buildViewerUrl(fileUrl);
|