-
State changed as build OD-7986 (16.4.0) is successful
-
OneDev
changed state to 'Closed' 3 weeks ago
Previous Value Current Value Open
Closed
| Type |
Improvement
|
| Priority |
Normal
|
| Assignee | |
| Labels |
No labels
|
Issue Votes (0)
Description
When printing a Markdown page while the application is in dark mode, a dark vertical strip appears on the right-hand side of the printed page. This strip does not appear when printing in light mode, where all content renders correctly.
Expected Behavior
Actual Behavior
Steps to Reproduce
Environment
Possible Cause (from analysis)
The dark vertical strip is likely caused by CSS background colors from the dark theme being carried into the print output, specifically on an element that extends beyond the main content area.
Common scenarios:
Dark mode sets a dark background on a high-level container (e.g.,
body,#root, or amainwrapper) using a rule like:When printing, the browser may include this background color if
print-color-adjust: exactis set, or if the print stylesheet does not explicitly override it.The dark vertical strip on the right often appears when a container has:
min-height: 100vh(or similar) so it covers the full page height.width: 100vwor a negative margin/overflow that makes the background extend slightly beyond the printable content area.::before/::afterpseudo-element that carries the dark background and ends up on the printed page.Suggested Fix
whiteortransparent.@media printrules to reset background colors on high-level containers.Additional information
This occurs not only in markdown files but also when we want to print an issue as well, and I should guess perhaps also pull requests and other pages.
Impact
The dark strip results in excess consumption of printer toner, which is not good for the budget and also not good for the environment.
Screenshot