This release contains improvements for annotation rendering, annotation editing, font conversion, image conversion, merging files, SMask rendering and the viewer.
Changes since v6.0.227
- Bump the stable version in
pdfjs.configby @timvandermeij in #21360 - Disable WebGPU for Firefox tests by @timvandermeij in #21364
- Skip the format 4 cmap sub-table when it doesn't fit its 16-bits fields by @calixteman in #21365
- Use the
MathClamphelper function in thesrc/display/canvas.jsfile by @Snuffleupagus in #21367 - Update the
StringStreamconstructor to accept an optional dictionary argument by @Snuffleupagus in #21366 - Mark a couple of viewer, and editor, EventBus listeners as "internal" by @Snuffleupagus in #21368
- Improve the
BaseStream.prototype.cloneimplementations by @Snuffleupagus in #21371 - Add an integration-test for clicking on internal links in presentation mode by @Snuffleupagus in #21373
- Fix intermittent failure in the "must check that a freetext is still here after having updated it and scroll the doc" freetext editor integration test by @timvandermeij in #21361
- Restore editor layer state for unchanged pages after page mutations by @calixteman in #21347
- Render gray transparency groups in grayscale by @calixteman in #21372
- Fix broken
enableSelectionRendering: falseby @wooorm in #21378 - Implement proper serialization of
OptionalContentConfigby @Snuffleupagus in #21349 - [api-minor] Add support for
/AuthEvent, on-demand decryption by @wooorm in #21351 - Run browser tests to collect code coverage data by @Snuffleupagus in #21359
- Bump github/codeql-action from 4.35.5 to 4.36.0 by @dependabot[bot] in #21382
- Remove the
#externalHidefield from theAnnotationLayerBuilderclass by @Snuffleupagus in #21380 - Extend the
AppOptionsunit-tests to also cover theEVENT_DISPATCHoption-kind by @Snuffleupagus in #21385 - Shorten the
getBytesmethod in theStream/ChunkedStreamclasses by @Snuffleupagus in #21384 - Add knockout_inner_backdrop ref test by @calixteman in #21383
- Deduplicate shared font/image streams when merging PDFs by @calixteman in #21379
- Bug 2035251 - Use toolkit's pdf icon as favicon by @sfoster in #21358
- Match editor keyboard shortcuts by event.code as a fallback by @calixteman in #21350
- Update the README in order to add some info about code coverage by @calixteman in #21389
- fix typo in bit flag value for suppressCropClip by @KonstantinRight in #21386
- Reject the stream-capability when aborting the
ChunkedStreamManagerby @Snuffleupagus in #21387 - Strip the JBIG2 file header from JBIG2Decode streams by @calixteman in #21388
- Add one more unit-test case for invalid email domains in the
Autolinkerclass by @Snuffleupagus in #21392 - Add a unit-test for passing a filesystem URL-string (in Node.js) to
getDocumentby @Snuffleupagus in #21391 - Add a unit-test for passing a binary string to
getDocumentby @Snuffleupagus in #21390 - Add basic integration-tests for the
PDFCursorToolsfunctionality by @Snuffleupagus in #21393 - Shorten the
DrawLayerBuilder.prototype.cancelmethod a tiny bit by @Snuffleupagus in #21395 - Prevent intermittent issues when invoking the
PDFPageView.prototype.#injectLinkAnnotationsmethod by @Snuffleupagus in #21396 - Upgrade
codecov/codecov-actionto version 7.0.0 by @timvandermeij in #21398 - Run various test-suite when the
external/folder is modified by @Snuffleupagus in #21400 - Update dependencies to the most recent versions by @timvandermeij in #21402
- Update quickjs to rev 3d5e064e9dd67c70f7962836505a7fa067bf0a4e by @calixteman in #21399
- fixed typo in README.md by @matasaru in #21404
- Fix transparent color of
::selectionin Firefox by @wooorm in #21408 - Remove the
Map.prototype.getOrInsertComputedpolyfill from the scripting implementation (PR 21399 follow-up) by @Snuffleupagus in #21405 - Bump actions/checkout from 6.0.2 to 6.0.3 by @dependabot[bot] in #21420
- Bump github/codeql-action from 4.36.0 to 4.36.1 by @dependabot[bot] in #21421
- Handle TR2 with /Default entry by @calixteman in #21414
- [api-minor] Convert
getAttachmentsto return data in aMapby @Snuffleupagus in #21418 - Add a
PDFViewerhelper method for setting#printingAllowedand dispatching the event by @Snuffleupagus in #21409 - Fix form fields with their own canvas updated on non-rendered pages by @calixteman in #21407
- [CRX] List all viewer-accessible schemes in the connect-src CSP by @calixteman in #21419
- Improve rendering of comb text fields by @calixteman in #21413
- Drop 'unsafe-inline' from the CSP style-src directives by @calixteman in #21416
- Use the
convertBlackAndWhiteToRGBAhelper with grayscale images inputBinaryImageDataby @Snuffleupagus in #21427 - Fix the unit-tests for on-demand password handling of encrypted attachments (issue 21425) by @Snuffleupagus in #21429
- l10n: Update locale files by @sync-l10n-for-pdf-js[bot] in #21433
- Handle corrupt PDFs that lack /Kids array and just inline the /Page dictionary (issue 21436) by @Snuffleupagus in #21437
- Use the checkboxes and radio button appearances as defined in the pdf to render them in the annotation layer (bug 1802506) by @calixteman in #18907
- [api-minor] Remove the unused
convertToViewportRectanglemethod in thePageViewportclass by @Snuffleupagus in #21426 - Use the
isDicthelper function in a few more places by @Snuffleupagus in #21431 - Use
Map.prototype.getOrInsertComputed()more in the code-base by @Snuffleupagus in #21439 - Re-factor the
isSourcePDFhandling in theJpegImageclass by @Snuffleupagus in #21441 - Reduce duplication when invoking
finishWorkerTaskby @Snuffleupagus in #21443 - Update dependencies to the most recent versions by @timvandermeij in #21446
- Add an integration-test for merging a corrupt PDF by @Snuffleupagus in #21452
- Add an integration-test for merging a password-protected PDF by @Snuffleupagus in #21444
- Use the
convertRGBToRGBAhelper with RGB images inputBinaryImageDataby @Snuffleupagus in #21440 - Fix intermittent failure in the
must check that the comment sidebar is resizablecomment integration test by @timvandermeij in #21448 - Don't download Puppeteer browsers on
npm installby @timvandermeij in #21453 - Upgrade
eslint-plugin-unicornto version 66.0.0 by @timvandermeij in #21454 - Resolve checkbox/radio export values from the 'Opt' entry by @calixteman in #21428
- Remove the unused
HighlightOutline.prototype.classNamesForOutlininggetter by @Snuffleupagus in #21456 - Remove unneeded check in the "GetAnnotationsByType" worker-thread handler by @Snuffleupagus in #21457
- Draw non-isolated blend-mode groups against their backdrop (bug 1873345) by @calixteman in #21455
- Bump github/codeql-action from 4.36.1 to 4.36.2 by @dependabot[bot] in #21461
- Use ternary expressions to shorten code in
src/core/editor/pdf_editor.jsby @Snuffleupagus in #21459 - Bump markdown-it from 14.1.1 to 14.2.0 by @dependabot[bot] in #21464
- Adjust the 'BaseException' unit-test for the 'Error.stack' changes in Firefox by @calixteman in #21463
- Don't clamp BlueScale up when a font genuinely has small zones by @calixteman in #21462
- Check every LinkAnnotation when testing if inferred links overlap (issue 21458) by @Snuffleupagus in #21460
- Add a 'supportsDownloading' browser option to gate saving/downloading by @calixteman in #21310
- Re-derive annotation attachment content from the xref after cleanup by @calixteman in #21465
- Remove unused branches in the
src/display/canvas.jsfile by @Snuffleupagus in #21467 - Avoid too long BlueScale value when rewriting a CFF font by @calixteman in #21469
- l10n: Update locale files by @sync-l10n-for-pdf-js[bot] in #21471
- Add a unit-test for relative URI actions specified as /Name instances by @Snuffleupagus in #21476
- Remove unnecessary explicit return statements in
CanvasGraphics.prototype.showTextby @Snuffleupagus in #21473 - Bump undici from 7.24.3 to 7.28.0 by @dependabot[bot] in #21472
- Stop event propagation, for the
Enterkey, in the passwordPrompt input by @Snuffleupagus in #21482 - Remove the unused
AnnotationEditorUIManager.prototype.isSelectedmethod by @Snuffleupagus in #21470 - Use the
isDicthelper in theCatalog.prototype.metadatagetter by @Snuffleupagus in #21481 - Don't swallow
MissingDataExceptions in theAnnotation.prototype.#setOptionalContentmethod (PR 21313 follow-up) by @Snuffleupagus in #21479 - A couple of small tweaks of the
StructElementNode.prototype.mathMLgetter by @Snuffleupagus in #21480 - Vertically center the glyphs in comb text fields by @calixteman in #21478
- Reset alpha before drawing a colored glyph in type 3 font by @calixteman in #21483
- Use AES256 for V=5 documents with a mislabeled AESV2 crypt filter (bug 2046659) by @calixteman in #21485
- Add support for RichMedia annotations by @calixteman in #21474
- Remove the
AnnotationEditorUIManagerandIdManagertest-onlyresetmethods (PR 19809 follow-up) by @Snuffleupagus in #21489 - Sort the mappings last in the
readCmapTablefunction (PR 19321 follow-up) by @Snuffleupagus in #21491 - Improve the
sinkhandling ingetTextContentfor Highlight annotations (PR 20019 follow-up) by @Snuffleupagus in #21486 - Add support for Screen annotations playing embedded media by @calixteman in #21490
- Update dependencies to the most recent versions by @timvandermeij in #21492
- Include the
cataloginstance in theannotationGlobalsdata by @Snuffleupagus in #21488 - Bump library version to
6.1by @Snuffleupagus in #21499 - Tweak some
String.prototype.substring()usage by @Snuffleupagus in #21497 - Change
issue17906to test "forms" rendering by @Snuffleupagus in #21502 - Move SVG text selection styles to pdf_viewer.css (bug 2049302) by @nicolo-ribaudo in #21504
- Render non-empty glyph 0 for char code 0 by @calixteman in #21487
- Disable selection rendering when backdrop-filter is unsupported (bug 2050191) by @calixteman in #21500
- Inline the
initmethod in theStructTreeRootconstructor by @Snuffleupagus in #21505 - Use more optional chaining in the
src/andweb/folders by @Snuffleupagus in #21508