PDF.js version: 3.5.141

These two properties should be marked as not mandatory as they are initialized if not present
if (this._scrollMode === ScrollMode.PAGE) {
          
          this.#ensurePageViewVisible();
        } else if (this._spreadMode !== SpreadMode.NONE) {
          this._updateSpreadMode();
        }
        
        
        
        this.#onePageRenderedOrForceFetch().then(async () => {
          this.findController?.setDocument(pdfDocument); 
          this._scriptingManager?.setDocument(pdfDocument); 
          if (this.#hiddenCopyElement) {
            this.#copyCallbackBound = this.#copyCallback.bind(
              this,
              textLayerMode
            );
            document.addEventListener("copy", this.#copyCallbackBound);
          }
          if (this.#annotationEditorUIManager) {
            
            this.eventBus.dispatch("annotationeditormodechanged", {
              source: this,
              mode: this.#annotationEditorMode,
            });
          }
          
          
          if (
            pdfDocument.loadingParams.disableAutoFetch ||