Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

First characters are not displayed when focus is lost from an overpopulated field #12359

Closed
bogdanmaris opened this issue Sep 10, 2020 · 2 comments

Comments

@bogdanmaris
Copy link

bogdanmaris commented Sep 10, 2020

Affected versions

  • Latest Nightly 82.0a1
  • Firefox 81.0b8

Affected platforms

  • Ubuntu 18.04 64bit
  • MacOS 10.15
  • Windows 10 64bit

Steps to reproduce

  1. Open the following http://foersom.com/net/HowTo/data/OoPdfFormExample.pdf
  2. Click inside the Given Name field and overpopulate the field so the first characters are hidden
  3. Click outside of the field

Expected result

  • First characters are displayed at the beginning of the field when the focus is off that field.

Actual result

  • Characters entered at the start of the field are hidden from view, although printing or saving the pdf will display the first characters as expected.

Regression range

  • Not a regression since this did not work on a build where this feature was enabled in Nightly.

Additional Notes

  • Other form editors don't suffer from this issue (Acrobat, Foxit, Chrome).
  • Gif showing the issue:

Focus jump

Suggested severity

  • I my opinion this should have the S4 severity, it is an inconvenience when editing the pdf, but it's not visible after printing, saving the pdf.
@timvandermeij
Copy link
Contributor

Fixed by the PR above.

@CetinSert
Copy link
Contributor

This has caused a regression for Safari currently being tracked here: #13224 (comment)

CetinSert added a commit to pdf-ist-internal/pdf.js that referenced this issue Apr 13, 2021
setSelectionRange(0, 0); // required only by Firefox, causes issues in Safari (see mozilla#12592 and mozilla#13191).
scrollLeft = 0; // is a fix that breaks the focus trap in Safari while keeping Firefox behavior same for mozilla#12359
CetinSert added a commit to pdf-ist-internal/pdf.js that referenced this issue Apr 13, 2021
`setSelectionRange(0, 0)` added in mozilla@44b24fc for mozilla#12359, required only by Firefox ([bug](https://bugzilla.mozilla.org/show_bug.cgi?id=860329)), causes issues mozilla#13191, mozilla#12592 in Safari.
`scrollLeft = 0` is a fix that breaks the focus trap in Safari while **keeping Firefox behavior same for mozilla#12359**.
CetinSert added a commit to pdf-ist-internal/pdf.js that referenced this issue Apr 13, 2021
`setSelectionRange(0, 0)` added in mozilla@44b24fc for mozilla#12359, required only by Firefox ([bug](https://bugzilla.mozilla.org/show_bug.cgi?id=860329)), causes issues mozilla#13191, mozilla#12592 in Safari.
`scrollLeft = 0` is a fix that breaks the focus trap in Safari while **keeping Firefox behavior same for mozilla#12359**.
calixteman pushed a commit that referenced this issue Apr 13, 2021
`setSelectionRange(0, 0)` added in 44b24fc for #12359, required only by Firefox ([bug](https://bugzilla.mozilla.org/show_bug.cgi?id=860329)), causes issues #13191, #12592 in Safari.
`scrollLeft = 0` is a fix that breaks the focus trap in Safari while **keeping Firefox behavior same for #12359**.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants