Provide a way to specify default theme for printing
@siriwatknp is already working on this.
Since Feb 27, 2023.
- Dominant language
- JavaScript
- Stars
- 99.1k
- Forks
- 32.5k
- Avg merge
- 2d 17h
- Merged PRs (30d)
- 106
Description
Duplicates
- I have searched the existing issues
Latest version
- I have tested the latest version
Summary 💡
In my app, I have support for light and dark themes.
When I initiate printing with window.print() I want the default light theme to be used regardless if the current displed theme is dark or light.
I tried to work around this by using useMediaQuery('print') and setting the theme to light but it does not work with window.print() only on Ctrl+P.
I also tried experimental CssVariables color schemas and if you would add the ability to specify media property for injected global stylesheets that may solve the issue.
Examples 🌈
No response
Motivation 🔦
It does not make sense to print pages on a dark theme because you will use a lot of ink for printing.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.