Closed Bug 1808858 Opened 2 years ago Closed 2 years ago

Update PDF.js to new version 8a0ca04399cd1b4b4d1bb960685550e3f6ea4e03 from 2023-01-05 12:43:53

Categories

(Firefox :: PDF Viewer, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
110 Branch
Tracking Status
firefox110 --- fixed

People

(Reporter: update-bot, Assigned: update-bot)

References

(Blocks 1 open bug)

Details

(Whiteboard: [3pl-filed][task_id: NGkcsnRXRrKkf8zCoYO5HA])

Attachments

(1 file)

This update covers 14 commits:


409c8b344f6a0a76d5a72737be5ac249446c689b by Calixte Denizet

https://github.com/mozilla/pdf.js/commit/409c8b344f6a0a76d5a72737be5ac249446c689b
Authored: 2023-01-05 11:28:04 +0100
Committed: 2023-01-05 13:02:29 +0100

[GV] Remove print stuff because window.print isn't implemented (bug 1808668)

Files Modified:

  • web/app.js
  • web/viewer-geckoview.css
  • web/viewer-geckoview.html
  • web/viewer-geckoview.js

dea2471e961061fcc9bf8362d14dd3a57f8c2a84 by Calixte Denizet

https://github.com/mozilla/pdf.js/commit/dea2471e961061fcc9bf8362d14dd3a57f8c2a84
Authored: 2023-01-04 19:49:31 +0100
Committed: 2023-01-04 21:26:36 +0100

[JS] UserActivation must be enabled before running document actions

else auto-print is broken (it's a regression from patch #15822).

Files Added:

  • test/pdfs/autoprint.pdf

Files Modified:

  • src/scripting_api/event.js
  • test/integration/scripting_spec.js
  • test/pdfs/.gitignore

66a3aa28fd49ae09ce77b3522c2e41f977186c68 by Jonas Jenwald

https://github.com/mozilla/pdf.js/commit/66a3aa28fd49ae09ce77b3522c2e41f977186c68
Authored: 2023-01-04 17:32:18 +0100
Committed: 2023-01-04 18:19:39 +0100

Reduce duplication in the accumulateWheelTicks/accumulateTouchTicks methods (PR 15886 follow-up)

It just occurred to me that we can reduce some duplication by having the, virtually identical, accumulateWheelTicks/accumulateTouchTicks methods use a common helper instead that takes advantage of bracket notation.

Files Modified:

  • web/app.js

d6b7a1f034c1c6cb2458135a088633ae87310e1f by Calixte Denizet

https://github.com/mozilla/pdf.js/commit/d6b7a1f034c1c6cb2458135a088633ae87310e1f
Authored: 2023-01-02 18:23:44 +0100
Committed: 2023-01-04 16:00:46 +0100

[api-minor] Add the pinch-to-zoom feature (bug 1677933)

Files Modified:

  • web/app.js
  • web/firefoxcom.js
  • web/pdf_viewer.js

6bdbb5c5ca928ecd38a72dc4c72c0879cea49a3b by Jonas Jenwald

https://github.com/mozilla/pdf.js/commit/6bdbb5c5ca928ecd38a72dc4c72c0879cea49a3b
Authored: 2023-01-02 16:21:48 +0100
Committed: 2023-01-02 16:21:48 +0100

Update the type/subtype at the end of font parsing

This fixes a warning reported by CodeQL, and should also make general sense given that we parse the font-data to determine the actual type/subtype rather than trusting the PDF document.

Files Modified:

  • src/core/fonts.js

9089e75cce1ed4c3cc6e9d661096e4ee52141ba8 by Jonas Jenwald

https://github.com/mozilla/pdf.js/commit/9089e75cce1ed4c3cc6e9d661096e4ee52141ba8
Authored: 2023-01-02 14:10:36 +0100
Committed: 2023-01-02 14:52:00 +0100

Validate the options before adding the ResizeObserver in the PDFViewer constructor (PR 15830 follow-up)

In the GENERIC viewer, it doesn't make sense to register the ResizeObserver if the container/viewer options are not valid.

Files Modified:

  • web/pdf_viewer.js

0860a5b16858775774019487ca29f42cac7f5f92 by Jonas Jenwald

https://github.com/mozilla/pdf.js/commit/0860a5b16858775774019487ca29f42cac7f5f92
Authored: 2023-01-02 14:05:33 +0100
Committed: 2023-01-02 14:05:33 +0100

Ensure that a document is loaded in PDFViewer.{increaseScale, decreaseScale} (PR 14053 follow-up)

This was always "wrong", since these methods (just like all the zoom-related ones) don't make sense unless there's an active document.

Files Modified:

  • web/pdf_viewer.js

9f50b0af372bf41d70f1a6b5ce3c9b09d4facc79 by Jonas Jenwald

https://github.com/mozilla/pdf.js/commit/9f50b0af372bf41d70f1a6b5ce3c9b09d4facc79
Authored: 2023-01-02 14:00:16 +0100
Committed: 2023-01-02 14:00:16 +0100

Enable the defaultZoomDelay option/preference unconditionally (PR 15812 follow-up)

This option/preference was disabled in GENERIC builds, see PR 15812, to avoid landing it just before a new release. Hence it should be fine to enable this now.

Files Modified:

  • web/app_options.js

69c88477a9937212a43c7db754c4aa566d5d10f3 by Calixte Denizet

https://github.com/mozilla/pdf.js/commit/69c88477a9937212a43c7db754c4aa566d5d10f3
Authored: 2023-01-02 11:38:24 +0100
Committed: 2023-01-02 12:27:07 +0100

Avoid an infinite loop when searching for a single diacritic

Files Modified:

  • test/unit/pdf_find_controller_spec.js
  • web/pdf_find_controller.js

1a69d537c16124104948b950a07bad1f0e021609 by Jonas Jenwald

https://github.com/mozilla/pdf.js/commit/1a69d537c16124104948b950a07bad1f0e021609
Authored: 2023-01-01 16:57:57 +0100
Committed: 2023-01-01 17:53:12 +0100

[api-minor] Limit the PDFDocumentLoadingTask.onUnsupportedFeature functionality to GENERIC builds (PR 15758 follow-up)

This was deprecated in PR 15758 but it's unfortunately quite difficult to tell if third-party users are depending on this, e.g. to implement custom error reporting, and if so to what extent.
However, thanks to the pre-processor we can limit most of this code to GENERIC builds which still seem like a worthwhile change.

These changes reduce the bundle size of the Firefox PDF Viewer by 3.8 kB in total.

Files Modified:

  • src/core/document.js
  • src/core/evaluator.js
  • src/core/pattern.js
  • src/display/api.js
  • src/display/font_loader.js
  • src/shared/util.js

0c1fb4e740ba605138d743c9e437184b62edf727 by Jonas Jenwald

https://github.com/mozilla/pdf.js/commit/0c1fb4e740ba605138d743c9e437184b62edf727
Authored: 2023-01-01 16:33:55 +0100
Committed: 2023-01-01 17:06:47 +0100

[api-minor] Remove the PDFDocumentProxy.stats getter (PR 15758 follow-up)

This was deprecated in PR 15758 and given that it's quite unlikely that any third-party users are relying on this functionality, since it was only ever added to support telemetry reporting in the Firefox PDF Viewer, it should hopefully be fine to remove this fairly quickly.

These changes reduce the bundle size of the Firefox PDF Viewer by 4.5 kB in total.

Files Modified:

  • src/core/core_utils.js
  • src/core/evaluator.js
  • src/core/fonts.js
  • src/core/fonts_utils.js
  • src/core/parser.js
  • src/core/xref.js
  • src/display/api.js
  • src/shared/util.js
  • test/unit/api_spec.js
  • test/unit/test_utils.js

195846a716583a5551a634a1d2f9044efa4271d1 by Tim van der Meij

https://github.com/mozilla/pdf.js/commit/195846a716583a5551a634a1d2f9044efa4271d1
Authored: 2023-01-01 14:35:58 +0100
Committed: 2023-01-01 14:35:58 +0100

Bump versions in pdfjs.config

Files Modified:

  • pdfjs.config

c2d17cac34ad39b17dd80f9138709d2cde3a4128 by Jonas Jenwald

https://github.com/mozilla/pdf.js/commit/c2d17cac34ad39b17dd80f9138709d2cde3a4128
Authored: 2022-12-28 12:14:22 +0100
Committed: 2022-12-28 12:14:22 +0100

[GeckoView] Remove the progressBar CSS variables, since they're unused

Given that there's no loadingBar element present in the GeckoView-viewer, we shouldn't need CSS variables for it.

Files Modified:

  • web/viewer-geckoview.css

49c09eda9bc9c5111abfa067aa1acb66a472f6d4 by Jonas Jenwald

https://github.com/mozilla/pdf.js/commit/49c09eda9bc9c5111abfa067aa1acb66a472f6d4
Authored: 2022-12-28 12:03:46 +0100
Committed: 2022-12-28 12:07:39 +0100

Decouple the loadingBar background-color from the rest of the viewer

With upcoming background changes elsewhere in the viewer, this should be helpful in separating the styling of the loadingBar. These changes also means that both the "regular" and the "indeterminate" loadingBar now uses the same background-color value.

Also, shortens the related CSS variables a little bit since that can't hurt.

Files Modified:

  • web/viewer.css

Assignee: nobody → update-bot
Status: NEW → ASSIGNED
Pushed by cdenizet@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/5ce095aa44f1 Update PDF.js to 8a0ca04399cd1b4b4d1bb960685550e3f6ea4e03 r=calixte
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 110 Branch

The try push is done, we found jobs with unclassified failures.

Needs Investigation (From Push Health):

No tests were found for flavor 'plain' and the following manifest filters:

skip_if, run_if, fail_if, subsuite(name=None), tags(['condprof']), pathprefix(['toolkit/components/pdfjs/test'])

Make sure the test paths (if any) are spelt correctly and the corresponding
--flavor and --subsuite are being used. See mach mochitest --help for a
list of valid flavors.
- 2 of 2 failed on different tasks
- test-linux1804-64-qr/opt-mochitest-plain-condprof-1 (c3ev5COvR4Sff53XMNdvGg)
- test-windows10-64-2004-qr/opt-mochitest-plain-condprof-1 (SUxLZJSXReC-C2FyOnFMmw)

Needs Investigation (Other Failed Jobs):
test-linux1804-64-qr/debug-mochitest-devtools-chrome-swr-1
- 4 of 4 failed on the same (retriggered) task (ImaD-xyqRZ2oQZdFltI_VA, HyQbFQv2Th2LhSz1Xy_sOA, aGTkKAqESs2DGPTfgsLe1g, bWpTDuhjT3qb2nYWjnTZIQ)
test-macosx1015-64-qr/debug-mochitest-devtools-chrome-1
- 4 of 4 failed on the same (retriggered) task (KGkTFXXsSUGFFi0Qy89M4g, KUgmJMKgT56TK969Kl2aDQ, VdEUMMmsTQWKU1qZu-cR7w, bWs3bmrPToqZw_RxUDy7DA)
test-linux1804-64-qr/debug-mochitest-devtools-chrome-spi-nw-1
- 4 of 4 failed on the same (retriggered) task (LK2nsQx4SL6wnSxYyZvdNQ, UMYh-9mHRvGXomMTfxzMxg, HVLnBnVhRFiVKSjCNE5SMA, XD4jSg1sRP6m3fmlpaFc5Q)
test-windows10-64-2004-qr/debug-mochitest-devtools-chrome-spi-nw-1
- 4 of 4 failed on the same (retriggered) task (MEQ4CaR6SsqqjtZlCIlW8w, PxpG_hrATNK0bki8VtbhPQ, Ia1hO-EoR5Ox4kjG2hnY8g, EFnvhwcTSSCNH8tDyOTw1A)
test-linux1804-64-qr/debug-mochitest-devtools-chrome-1
- 4 of 4 failed on the same (retriggered) task (RARNxK0YSzioRxVeW42vwQ, UtLZjKDgTH2-m_6Y8iJpeA, CMDsfX9RQ7KnfZGOI8xKOA, Jj8gyHAXQbSjGq9lXpR-_A)
test-windows10-64-2004-qr/debug-mochitest-devtools-chrome-1
- 4 of 4 failed on the same (retriggered) task (VOhi9qahRN2mYKPsmecLGw, XKKUrn0qRVCzhrwhBdM1Bw, Wmsx0TZhQRO-9LIyCBfh9w, f0T3-cJHQG6d6s2WzPc63Q)
test-macosx1015-64-qr/debug-mochitest-devtools-chrome-spi-nw-1
- 4 of 4 failed on the same (retriggered) task (BN5VABqnRNWTB4yg3BBgDA, b78wcjUkR4GYvWrvaCFQ9Q, BgNrBkGcRdW_VERPxPLmxw, Jim2xdoHQ5eq8SI9XRmr_w)

These failures could mean that the library update changed something and caused
tests to fail. You'll need to review them yourself and decide where to go from here.

In either event, I have done all I can and you will need to take it from here. If you
don't want to land my patch, you can replicate it locally for editing with
./mach vendor toolkit/components/pdfjs/moz.yaml

When reviewing, please note that this is external code, which needs a full and
careful inspection - not a rubberstamp.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: