Heartbeat close button invisible on dark theme
Categories
(Firefox :: Normandy Client, enhancement, P3)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox67 | --- | fixed |
People
(Reporter: mozilla.org, Assigned: glasserc)
Details
Attachments
(5 files)
Comment 1•8 years ago
|
||
Comment 2•8 years ago
|
||
Comment 3•8 years ago
|
||
Comment 4•8 years ago
|
||
Comment 5•8 years ago
|
||
Comment 7•8 years ago
|
||
Comment 10•8 years ago
|
||
Updated•8 years ago
|
| Assignee | ||
Comment 11•7 years ago
|
||
Comment 12•7 years ago
|
||
| Assignee | ||
Comment 13•7 years ago
|
||
Comment 14•7 years ago
|
||
Hi Ethan,
Apologies for the delay in answering, got the notification on the phone when I was away from the computer and then forgot about it completely ^^U.
I tried on the browser console but still could not make it work. While the first two instructions appeared to do their thing without complaints, the third caused an error:
13:47:55.261 ChromeUtils.import("resource://gre/modules/Services.jsm");
13:47:55.268
NonSyntacticVariablesObject { EXPORTED_SYMBOLS: (1) […], Services: {…}, initTable: undefined, AppConstants: {…}, XPCOMUtils: {…}, … }
13:48:02.735 ChromeUtils.import("resource://normandy/lib/Heartbeat.jsm");
13:48:02.744
NonSyntacticVariablesObject { EXPORTED_SYMBOLS: (1) […], Heartbeat: (), AppConstants: {…}, Preferences: (), Services: {…}, TelemetryController: {…}, setTimeout: (), setTimeoutWithTarget: (), clearTimeout: (), setInterval: (), … }
13:48:13.179 new Heartbeat(Services.wm.getMostRecentWindow("navigator:browser"), {flowId: "test", message: "message", learnMoreMessage: "Learn More", learnMoreUrl: "https://mozilla.org"});
13:48:13.196 TypeError: options is undefined[Learn More] debugger eval code:81:9
This is on Firefox 65.0 on Mint 19 - maybe this version needs slightly different commands?
| Assignee | ||
Comment 15•7 years ago
|
||
Hi Fede, can you try the code that :mythmon posted in comment 4 instead? I think 65 is too early for the bug I posted.
Comment 16•7 years ago
|
||
Alright, that worked. I tested four situations:
- Light desktop theme, light Firefox theme
- Light desktop theme, dark Firefox theme
- Dark desktop theme, light Firefox theme
- Dark desktop theme, dark Firefox theme
To summarize, the issue depends on the desktop theme, and not the Firefox theme. With a dark desktop theme (possibly any desktop theme that provides a close button that is light colored?) the close button is indistinguishable from the background, while with a light desktop theme (one that provides a dark close button?) the close button is perfectly visible. To reiterate, the button is always there, it's just practically impossible to spot if using a dark desktop theme.
| Assignee | ||
Comment 17•7 years ago
|
||
OK, that's super interesting. Thank you very much for reporting it.
:Gijs suggested that the notification bar already has support for most of the desktop theme things. The reason that this one doesn't is because we expressly override background color (https://searchfox.org/mozilla-central/source/toolkit/components/normandy/skin/shared/Heartbeat.css#7) and text color (https://searchfox.org/mozilla-central/source/toolkit/components/normandy/skin/shared/Heartbeat.css#52) but not close button color. It sounded like Gijs would prefer that rather than trying to slap more CSS on top of this, we should remove these customizations and rely on the normal notification bar code. What do you think about that, :mythmon?
Comment 18•7 years ago
|
||
I'm generally in favor of making Heartbeat less weird. My only concern is how the heart icon would look like on a dark background. Lets give it a shot and see how it looks?
| Assignee | ||
Comment 19•7 years ago
|
||
| Assignee | ||
Comment 20•7 years ago
|
||
This is what it looks like on Nightly when I take out the hard-coded white colors. I think it looks better with a dark theme than the previous, but I'm willing to be contradicted.
| Assignee | ||
Comment 21•7 years ago
|
||
There are three other hard-coded colors here which are the ones used in .text-link (which I think is just the "Learn More" link). I considered taking these colors out too but I guess they have been chosen to match the colors of the stars. I feel like we might have a similar problem to this one day if we get a user who is using B00merang Glass but I don't see a way around it as long as we render stars using SVGs (which, presumably, have hard-coded colors).
I'll send a patch; :mythmon, who should I ask about the visual aesthetics?
| Assignee | ||
Comment 22•7 years ago
|
||
For completeness, here is also what the heartbeat looks like with a "light" theme once I remove the background colors from the heartbeat CSS.
| Assignee | ||
Comment 23•7 years ago
|
||
These hard-coded colors actually remove our ability to respond to
the user's theme. Get rid of them.
Comment 24•7 years ago
|
||
I'm happy with removing the hard coded links, and allowing heartbeat to match the rest of the UI. I think the closest thing we have to an authority about the aesthetics is the people using it.
Tyler, do you have any opinions about the screenshots that Ethan posted?
| Assignee | ||
Updated•7 years ago
|
| Assignee | ||
Comment 25•7 years ago
|
||
For completeness, this is the version once I have taken the custom link color out.
Comment 27•7 years ago
|
||
Comment 28•7 years ago
|
||
| bugherder | ||
Description
•