Skip to content

Conversation

@kairosci
Copy link

Fixes #18190.

This PR addresses a regression where text underneath highlight, underline, squiggly, and strikeout annotations could not be selected.
The cause was pointer-events: auto on the annotation container elements, which blocked mouse events from reaching the text layer.

Changes:

  • Added pointer-events: none to .highlightAnnotation, .underlineAnnotation, .squigglyAnnotation, and .strikeoutAnnotation in web/annotation_layer_builder.css.
  • Added an integration test test/integration/highlight_selection_spec.mjs to verify that the pointer-events property is correctly set to 'none'.

Verification:

  • Verified manually that text selection works.
  • Lint check passed.

@kairosci kairosci requested a review from a team as a code owner January 10, 2026 14:57
@kairosci kairosci marked this pull request as draft January 10, 2026 15:00
…zilla#18190)

Add pointer-events: none to markup annotation containers to prevent blocking text selection.

Add integration test.
@kairosci kairosci changed the title fix(display): allow text selection under markup annotations (issue #18190) fix(display): allow text selection under markup annotations Jan 10, 2026
@kairosci kairosci marked this pull request as ready for review January 10, 2026 15:14
@bcolsson
Copy link

Not sure if you intended to flag l10n for review or something else. It doesn't look like localization is affected.

@kairosci
Copy link
Author

kairosci commented Jan 21, 2026

@bcolsson I do not understand what you are referring to, in any case the change does not affect nor refers to internationalization.

@flodolo
Copy link
Contributor

flodolo commented Jan 21, 2026

@bcolsson I do not understand what you are referring to, in any case the change does not affect nor refers to internationalization.

You triggered a review from @mozilla/pdfjs-l10n (likely you pushed changes to a .ftl file at some point).

@kairosci kairosci marked this pull request as draft January 21, 2026 08:12
@kairosci
Copy link
Author

You triggered a review from @mozilla/pdfjs-l10n (likely you pushed changes to a .ftl file at some point).

Could you link it to me? Thanks!

@flodolo
Copy link
Contributor

flodolo commented Jan 21, 2026

You triggered a review from @mozilla/pdfjs-l10n (likely you pushed changes to a .ftl file at some point).

Could you link it to me? Thanks!

Not sure what you're asking to link to.

There are rules triggering automated review requests, depending on which files you touch
https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners

Touching .ftl files will trigger a review from Bryan's (and my) group.

@kairosci kairosci marked this pull request as ready for review January 25, 2026 22:22
@kairosci
Copy link
Author

kairosci commented Jan 25, 2026

It seems strange to me, since I haven't modified any ftl files. Should I close the PR, or is there an alternative way to have it reviewed by the appropriate group?

@kairosci kairosci marked this pull request as draft January 25, 2026 22:57
@kairosci kairosci marked this pull request as ready for review January 25, 2026 23:10
@kairosci
Copy link
Author

test

I share a screenshot of the result, which allows you to select and click on the selected part, or at least when I double-click on the selection, I see the section.

@kairosci
Copy link
Author

@timvandermeij If you can, please let me know how to proceed, thank you!

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.

Unable to select highlighted text.

4 participants