Attach (recommended) or Link to PDF file here: 

Configuration:
- Web browser and its version: Firefox 112.0.2
- Operating system and its version: MacOS Monterey 12.0.1
- PDF.js version: 3.5.35
- Is a browser extension: no

Steps to reproduce the problem:
1. Open attached pdf
2. Type some text into the field, click outside of the field to unfocus 
3. Remove all text from the field and click outside of the field to unfocus 

What is the expected behavior? (add screenshot)
The field should be empty.
<img width="1106" alt="Screenshot 2023-05-10 at 21 51 06" src="https://github.com/mozilla/pdf.js/assets/47328547/6889d38d-87f8-44b3-8325-684f64eac88b">

What went wrong? (add screenshot)
Field is not being cleared - it's not possible to make the field empty.
I found out that if you add any and I mean just any javascript - e.g. just a simple console print statement this problem occurs. However if I remove all javascript, the text field is cleared properly
<img width="832" alt="Screenshot 2023-05-10 at 21 52 33" src="https://github.com/mozilla/pdf.js/assets/47328547/7940c128-ae7a-4879-8d8f-57b08363def4">
[empty-text-field.pdf](https://github.com/mozilla/pdf.js/files/11445510/empty-text-field.pdf)


Link to a viewer (if hosted on a site other than mozilla.github.io/pdf.js or as Firefox/Chrome extension):

[
          ["focus", "Focus"],
          ["blur", "Blur"],
          ["mousedown", "Mouse Down"],
          ["mouseenter", "Mouse Enter"],
          ["mouseleave", "Mouse Exit"],
          ["mouseup", "Mouse Up"],
          ["input", "Action"],
          ["input", "Validate"],
        ],
        event => event.target.value
      );
    } else {
      selectElement.addEventListener("input", function (event) {
        storage.setValue(id, { value: getValue( true) });
      });
    }
    if (this.data.combo) {
      this._setTextStyle(selectElement);
    } else {
      
      
    }
    this._setBackgroundColor(selectElement);
    this._setDefaultPropertiesFromJS(selectElement);
    this.container.append(selectElement);
    return this.container;
  }
}
class PopupAnnotationElement extends AnnotationElement {