Forum Bugs

Unable to set different background-color on specific elements

zackingit
Having quite a few issues getting backgrounds to render in PDF form despite HTML version working perfectly.

While I'm able to set a background-color on the entire @page, any time I try to change either the `color` of an element or the `background-color` of an element, it continues to default to black and transparent respectively. Even when I add a super-specific selector like an `id` attribute, this issue persists.

HTML version is working just fine (so I know it's not a basic CSS issue), but something in the PDF conversion process causes the background color to be lost.

I want to emphasize that this isn't a one-off issue -- I've been able to create a literal quilt of background colors in HTML, but the PDF generates only background-colors in the page margin repeated areas (i.e., @top-left-corner)
mikeday
Perhaps you have a print style sheet being applied somewhere that has "color: black !important"?
zackingit
Yep -- that was pretty much exactly it -- I have to apply !important to get it to apply because my CTO apparently loved !important 4 years ago. You da real MVP Mike Day!

Edited by zackingit