Wrong color when selecting HTTP response payload in the Console
Categories
(DevTools :: Netmonitor, defect, P3)
Tracking
(firefox76 fixed)
Tracking | Status | |
---|---|---|
firefox76 | --- | fixed |
People
(Reporter: Honza, Assigned: marianapicolo, Mentored)
References
(Blocks 1 open bug)
Details
(Keywords: good-first-bug)
Attachments
(3 files)
STR:
- Open DevTools and select the Console panel, make sure the Requests filter is on
- Load https://api.github.com/
- Expand the request in the Console
- Select the Response panel
- Select something in the JSON Preview section
All the selected text should be white (on blue background) but, part of the text is gray, which makes it unreadable.
See the attached screenshot.
Note that it doesn't happen in the Response side panel in the Network panel. Why?
Honza
Reporter | ||
Updated•5 years ago
|
Assignee | ||
Comment 1•5 years ago
|
||
Honza, can I work on this one too?
Assignee | ||
Comment 2•5 years ago
|
||
Honza, I think I found the issue:
The network messages are built here:
https://searchfox.org/mozilla-central/source/devtools/client/webconsole/components/Output/message-types/NetworkEventMessage.js#133-136
The requestUrl
has a CSS class of url
,
https://searchfox.org/mozilla-central/source/devtools/client/themes/webconsole.css#739-742
which has the color of --theme-comment
;
But, according to the variables
file, the colors for selections are:
https://searchfox.org/mozilla-central/source/devtools/client/themes/variables.css#134-139
Assignee | ||
Comment 3•5 years ago
|
||
I think this color property defined on the url
class should be removed:
https://searchfox.org/mozilla-central/source/devtools/client/themes/webconsole.css#740
Assignee | ||
Comment 4•5 years ago
|
||
Assignee | ||
Comment 5•5 years ago
|
||
On the previous comment I posted one property of the JSON selected;
Can I send a patch?
I'm sorry for too many comments: I didn't find how to edit them
Reporter | ||
Comment 6•5 years ago
|
||
Hubert, can you please help Mariana to fix this, thanks!
Honza
Comment 7•5 years ago
•
|
||
Hi Mariana,
(In reply to Mariana Pícolo from comment #3)
I think this color property defined on the
url
class should be removed:
https://searchfox.org/mozilla-central/source/devtools/client/themes/webconsole.css#740
Great analysis! This line is the issue.
Lets probably add something like this instead
.webconsole-app .message.network .selected .url {
color: var(--theme-selection-color)
}
as we only need the change when the url is selected.
Assignee | ||
Comment 8•5 years ago
|
||
Assignee | ||
Comment 9•5 years ago
|
||
Hubert, can you check the patch I sent?
I think it fixes the bug
Updated•5 years ago
|
Comment 11•5 years ago
|
||
Mariana,
Ignore using comment 7. I left comments in the patch!
Thanks
Comment 12•5 years ago
|
||
Comment 13•5 years ago
|
||
bugherder |
Updated•4 years ago
|
Description
•