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

Alt-text button doesn't handle long locale strings "nicely" #17299

Closed
Snuffleupagus opened this issue Nov 20, 2023 · 0 comments · Fixed by #17300
Closed

Alt-text button doesn't handle long locale strings "nicely" #17299

Snuffleupagus opened this issue Nov 20, 2023 · 0 comments · Fixed by #17300
Assignees

Comments

@Snuffleupagus
Copy link
Collaborator

Snuffleupagus commented Nov 20, 2023

Attach (recommended) or Link to PDF file here: N/A

Configuration:

  • Web browser and its version: N/A
  • Operating system and its version: N/A
  • PDF.js version: 4.0.242 [3459615]
  • Is a browser extension: N/A

Steps to reproduce the problem:

  1. Open the demo viewer, using a locale with longer strings than English, https://mozilla.github.io/pdf.js/web/viewer.html#locale=sv-SE
  2. Add a StampAnnotation, e.g. firefox_logo.svg from the test-suite.
  3. Rotate the document once. Edit: It also reproduces without rotating, simply by making the Annotation small enough.

What is the expected behavior? (add screenshot)
That the alt-text button has vertical padding, even when the alt-text string is longer than the default.

What went wrong? (add screenshot)
No vertical padding, with the localized alt-text reaching the borders of the button, when the alt-text string is split into multiple lines; see screen-shot below.
Edit: If the localized string is sufficiently long, I suppose that the text may even end up "outside" of the button.

padding

Link to a viewer (if hosted on a site other than mozilla.github.io/pdf.js or as Firefox/Chrome extension): N/A

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants