Closed Bug 1660650 Opened 6 years ago Closed 4 years ago

The new UI of pdf viewer is not compatible with dark themes

Categories

(Firefox :: PDF Viewer, enhancement)

Firefox 81
enhancement

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: slanterns.w, Unassigned)

References

Details

(Whiteboard: [pdfjs-ux])

Attachments

(1 file)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:81.0) Gecko/20100101 Firefox/81.0

Steps to reproduce:

Open pdf with firefox.

Actual results:

The new UI of pdf viewer does not compatible with dark themes

Expected results:

There is a dark UI of pdf viewer which fits the dark themes of firefox like just like before.

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → PDF Viewer

Yes, it would be great if the viewer has a dark mode

Depends on: 1681399

In my case, the PDF viewer shows up dark in Firefox 84 on Windows, but on Fedora 32 the viewer shows up white in both Firefox 84 release and the latest nightly builds.

I found now we can set pdfjs.viewerCssTheme to 2 to force pdf.js to use dark mode (and 1 for light mode, 0 for auto-detect). But it seems the auto-detect mode still cannot adjust the pdf.js theme according to the browser theme.

I would like dark mode in the PDF reader!

Reading black text on white background at night is dreadful!

This is working for me, can anyone still reproduce?

Summary: The new UI of pdf viewer does not compatible with dark themes → The new UI of pdf viewer is not compatible with dark themes
Whiteboard: [pdfjs-ux]
Flags: needinfo?(vachan2014carmel)
Flags: needinfo?(slanterns.w)
Flags: needinfo?(eldmannen+mozilla)
Flags: needinfo?(eddiecarswell13)

(In reply to Marco Castelluccio [:marco] from comment #6)

This is working for me, can anyone still reproduce?

No, I think there is a dark theme and pdfjs.viewerCssTheme works fine for most situations now.

Flags: needinfo?(slanterns.w)
Status: UNCONFIRMED → RESOLVED
Closed: 4 years ago
Resolution: --- → WORKSFORME

The UI now for me is dark as expected!

Maybe it would be nice to be able to read a PDF and have it displayed with black text on white background though.

Flags: needinfo?(eldmannen+mozilla)

While it would be nice for the autodetect feature to work, I pretty much only use dark mode anyway. The about:config preference was a suitable fix for me. Perhaps there could be a toggle added to the pdf.js menu to handle this pref for the less technical users.

Flags: needinfo?(eddiecarswell13)
Flags: needinfo?(vachan2014carmel)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: