1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-19 22:58:07 +02:00

Merge pull request #18587 from Snuffleupagus/PDFViewer-check-AbortSignal-any

Check that `AbortSignal.any()` is supported in `PDFViewer` too (PR 18586 follow-up)
This commit is contained in:
Tim van der Meij 2024-08-09 17:35:25 +02:00 committed by GitHub
commit daabc7abea
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -880,7 +880,11 @@ class PDFViewer {
viewer.before(element);
}
if (annotationEditorMode !== AnnotationEditorType.DISABLE) {
if (
((typeof PDFJSDev !== "undefined" && PDFJSDev.test("MOZCENTRAL")) ||
typeof AbortSignal.any === "function") &&
annotationEditorMode !== AnnotationEditorType.DISABLE
) {
const mode = annotationEditorMode;
if (pdfDocument.isPureXfa) {