Skip to content

[pull] master from mozilla:master#99

Merged
vlakken merged 4004 commits intoshowpad:masterfrom
mozilla:master
Mar 23, 2026
Merged

[pull] master from mozilla:master#99
vlakken merged 4004 commits intoshowpad:masterfrom
mozilla:master

Conversation

@pull
Copy link
Copy Markdown

@pull pull bot commented Nov 2, 2023

See Commits and Changes for more details.


Created by pull[bot]

Can you help keep this open source service alive? 💖 Please sponsor : )

@pull pull bot added the ⤵️ pull label Nov 2, 2023
timvandermeij and others added 29 commits March 5, 2026 20:29
Fix few colors in the Manage menu in HCM (bug 2020774)
Add some aria-labels to the paste button in order to know where the buttons are (bug 2020758)
…ons/upload-artifact-7

Bump actions/upload-artifact from 6 to 7
Remove the sidebar resize observer when killing the UI
…tring

Use `BaseStream.prototype.getString` in the `readPostScriptTable` function
…-Stream

Let `BinaryCMapStream` extend the `Stream` class
Fix the position of the thumbnails on the last line (bug 2016437)
Fix the event name in some integration tests (follow-up of #20788)
Add fetch** functions in the XRefWrapper
Once a page has been deleted or pasted, make sure the focus stays in the sidebar (bug 2020731)
Remove gulp-sourcemaps dependency which is unmaintained
This is not only shorter, but (in my opinion) it also simplifies the code.

*Note:* In order to keep the *five* different `BasePDFStreamReader` implementations consistent, we purposely don't re-factor the `PDFWorkerStreamReader` class to support `for await...of` iteration.
This follows the same pattern as the existing handling for the `JpxImage` instance.
Let `src/core/jbig2_ccittFax_wasm.js` import the existing exception, rather than duplicate its code.
The task update_locales is using the GITHUB_TOKEN to push the changes to
the update-locales branch, but this token doesn't trigger other workflows (see [1]),
so we need to explicitly dispatch the required ones.

[1] https://github.com/orgs/community/discussions/26970#discussioncomment-3254152
Shorten the `createActionsMap` helper in the `src/scripting_api/common.js` file
Avoid to have stuck actions when running update_locales task
Convert the data reading in `getPdfManager` to be asynchronous
This adds a *very basic* non-MOZCENTRAL polyfill for now, which we should be able to remove once the next QuickJS version is released; note the pending changelog at https://github.com/bellard/quickjs/blob/f1139494d18a2053630c5ed3384a42bb70db3c53/Changelog#L8
This adds a basic non-MOZCENTRAL polyfill for now, which we should be able to remove once the next QuickJS version is released; note the pending changelog at https://github.com/bellard/quickjs/blob/f1139494d18a2053630c5ed3384a42bb70db3c53/Changelog#L7
Use `Math.sumPrecise` and `Map.prototype.getOrInsertComputed` in the scripting implementation
calixteman and others added 29 commits March 21, 2026 13:45
[Debugger] Allow debugging page-rendering from the /Ref, in addition to the page number
…rtSignal

Ensure that `TextLayerBuilder` works correctly without the `abortSignal` parameter (PR 20928 follow-up)
Fix charSpacing in vertical mode
The WebGPU feature hasn't been released yet but it's interesting to see how
we can use it in order to speed up the rendering of some objects.
This patch allows to render mesh patterns using WebGPU.

I didn't see any significant performance improvement on my machine (mac M2)
but it may be different on other platforms.
Implement Gouraud-based shading using WebGPU.
…ead create the `filename`

The `BaseCMapReaderFactory`, `BaseStandardFontDataFactory`, and `BaseWasmFactory` classes are all very similar, and the only difference is really in their respective `fetch` methods.
By have the worker-thread "compute" the complete `filename` it's possible to simplify the `BaseCMapReaderFactory.prototype.fetch` method, which will allow future improvements to all of these classes.

A couple of things to note:
 - This code is unused, and it's not even bundled, in the Firefox PDF Viewer.
 - In browsers it's unused by default, and worker-thread fetching will always be used when possible since that's more efficient.

*Please note:* For users that provide a custom `CMapReaderFactory` instance when calling `getDocument` this could be a breaking change, however it's unlikely that any such users exist.
(The *internal* format of this data was changed previously in PR 18951, and there hasn't been a single question/complaint about it in well over a year.)
Trying to resolve the same `objId` more than once would be a bug elsewhere in the code-base, since that should never happen, hence update the `resolve` method to prevent that.
With the introduction of `Map.prototype.getOrInsertComputed()` usage this method is no longer necessary, and the code can just be inlined instead.
Make persist-credentials: true in the update_locale action
…lename

[api-minor] Simplify `BaseCMapReaderFactory` by having the worker-thread create the `filename`
Avoid resolving an `objId` more than once in the `PDFObjects` class
Fix the group bbox when the numbers are too big
Add an integration test for the simple viewer
Don't add an EOL after a superscript
This reverts commit d618a2b.
Unfortunately it did not fix the hanging actions for the locale update
job; fixing the issue is tracked in #20813.
Revert "Avoid to have stuck actions when running update_locales task"
…`, and `WasmFactory` API options with a single factory/option

Currently we have no less than three different, but very similar, factories for reading built-in CMap files, standard font files, and wasm files on the main-thread.[1]
These factories were added at different points in time, since I cannot imagine that we'd add essentially three copies of the same code otherwise.

Nowadays these factories are often not even used[2], since worker-thread fetching is used whenever possible to improve performance. In particular, they will *only* be used when either:
 - The PDF.js library runs in Node.js environments.
 - The user manually sets `useWorkerFetch = false` when calling `getDocument`.
 - The user provides custom `CMapReaderFactory`, `StandardFontDataFactory`, and/or `WasmFactory` instances when calling `getDocument`.

By replacing these factories with *a single* new `BinaryDataFactory` factory/option the number of `getDocument` options are thus reduced, which cannot hurt.
This also reduces the total bundle-size of the Firefox PDF Viewer a little bit, and it slightly reduces the number of import maps that need to be maintained.

*Please note:* For users that provide custom `CMapReaderFactory`, `StandardFontDataFactory`, and `WasmFactory` instances when calling `getDocument` this will be a breaking change, however it's unlikely that (many) such users exist.
(The *internal* format data-format of `CMapReaderFactory` was changed in PR 18951, and there hasn't been a single question/complaint about it in well over a year.)

---

[1] Any new functionality could easily lead to more such factories being added in the future, which wouldn't be great.

[2] Note that the Firefox PDF Viewer no longer use these factories, since it "forcibly" sets `useWorkerFetch = true` during building.
Interpret empty annotation border as [0, 0, 0]
[api-minor] Replace the `CMapReaderFactory`, `StandardFontDataFactory`, and `WasmFactory` API options with a single factory/option
Correctly scroll the search result in the viewport with rotated pdfs (bug 2021392)
@vlakken vlakken merged commit 07d80ac into showpad:master Mar 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants