pdfjs-reader-core 0.2.7 → 0.2.8

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/dist/index.cjs CHANGED
@@ -10018,12 +10018,13 @@ var init_PDFViewerClient = __esm({
10018
10018
  currentDoc.destroy();
10019
10019
  viewerStore.getState().setDocument(null);
10020
10020
  }
10021
+ viewerStore.getState().setLoading(true, { phase: "initializing" });
10022
+ viewerStore.getState().setError(null);
10023
+ setLoadState("loading");
10021
10024
  const loadDoc = async () => {
10022
10025
  if (!mountedRef.current) return;
10023
10026
  try {
10024
- viewerStore.getState().setLoading(true, { phase: "fetching" });
10025
- viewerStore.getState().setError(null);
10026
- setLoadState("loading");
10027
+ viewerStore.getState().setLoadingProgress({ phase: "fetching" });
10027
10028
  const { document: document2, numPages } = await loadDocument({
10028
10029
  src,
10029
10030
  workerSrc,