CSS colour fix needed for private messages

This is an archive of a topic from NESdev BBS, taken in mid-October 2019 before a server upgrade.
View original topic
CSS colour fix needed for private messages
by on (#98385)
When reviewing a private message you sent, one of the CSS background colours appears to be bright blue. Attached is a screenshot showing what I'm talking about (surrounded by a red box to denote what I'm referring to).

The HTML generated for the problematic section is:

Code:
         <td width="100%" style="background-color:lightblue">
            <div class="gensmall" style="float: left;"><b>Message subject:</b>&nbsp;NSFPlay 2.2 beta</div><div class="gensmall" style="float: right;"><b>Folder:</b>&nbsp;<a href="./ucp.php?i=pm&amp;folder=0">Inbox</a></div>
         </td>


You can see the style="background-color:lightblue" attribute being set explicitly. Not sure where this correlates in the underlying phpBB themes / etc., but it should probably be changed to what the previous message background looks like. The HTML for THAT is:

Code:
         <td width="100%">
            <div class="gensmall" style="float: left;"><b>Message subject:</b>&nbsp;Re: NSFPlay 2.2 beta</div><div class="gensmall" style="float: right;"><b>Folder:</b>&nbsp;<a href="./ucp.php?i=pm&amp;folder=-1">Sent messages</a></div>
         </td>


Note the lack of style attribute.
Re: CSS colour fix needed for private messages
by on (#98387)
Figured this one out, but needed SSH access so I could do a "grep -r lightblue" through the templates. :-) The styles/subsilver2/template/ucp_pm_history.html file seems to have the code in it.

Code:
<td width="100%"<!-- IF history_row.S_CURRENT_MSG --> style="background-color:lightblue"<!-- ENDIF -->>


How nice that they just "assume" lightblue. All this themeing and CSS support yet no use of classes there... Silly silly silly.

Anyway, I've changed it to background-color:#3355aa; which is the same thing we use for the "tt" block here in posts. It looks good to me; screenshot attached.

I can make it a little darker if some people find the grey-on-blue text too hard to read -- let me know!

EDIT: Actually, to make it more consistent with the UI, I think it should use the same colour as the "Attachments:" bar background colour here in posts. That seems to be readable. But I'd like feedback from folks first.