Closed
Bug 1067999
Opened 10 years ago
Closed 7 years ago
Images in background-image tooltips aren't always easy to see
Categories
(DevTools :: Inspector, defect, P3)
DevTools
Inspector
Tracking
(firefox55 verified)
VERIFIED
FIXED
Firefox 55
Tracking | Status | |
---|---|---|
firefox55 | --- | verified |
People
(Reporter: pbro, Assigned: sy.fen0)
References
Details
(Keywords: good-first-bug, Whiteboard: [good first bug][lang=css])
Attachments
(3 files, 10 obsolete files)
STR: - Open https://www.mozilla.org/en-US/ - Open the inspector - Make sure the light theme is selected (go to the options panel to change it if not) - Using the inspector search field, find node '.btn-prev' and select it - In the Rules panel, hover over the URL in the property 'background-image: url("/media/img/home/control-arrows-lt.png");' ==> the white arrow icon in the tooltip is just invisible in the light theme. We need a better tooltip background to help see it. If you switch to the dark theme (in the options panel), you will see the image fine.
Comment 2•8 years ago
|
||
STR from Comment 0 isn't available anymore, but this screenshot shows the issue for the light theme.
Updated•8 years ago
|
Whiteboard: [good first bug][lang=css]
Comment 3•8 years ago
|
||
Nicolas, I'll take a shot at this one. What is the best way to get started? What is the particular directory in the source that holds the css for the inspector?
Comment 4•8 years ago
|
||
Cannot replicate from comment 0, there isn't a node '.btn-prev' and no 'background-image: url("/media/img/home/control-arrows-lt.png");' Has this been fixed as well?
Reporter | ||
Comment 5•8 years ago
|
||
As commented by Nicolas on IRC just now:
> 4:15 PM <nchevobbe> eights: you should be able to see it if you inspect the "Eurosport" logo in this page "http://www.eurosport.fr/"
> 4:16 PM <nchevobbe> search ".nav__logo"
> 4:17 PM <nchevobbe> eights: it's a data-uri, but we do show a preview for this, and you can see that if you have the light theme, you can't really see the logo
Reporter | ||
Comment 6•8 years ago
|
||
Also, as discussed with Helen on IRC: a checkered background would help. Brad, once you have something that works, it would be great if you could ping :helenvholmes on the bug so she can verify the visual aspect of it. Also because we have a new popup design coming up, so we should make sure this works there too.
Comment 7•8 years ago
|
||
Patrick, Ok great. Thanks for the help, I'll see what I can work up. Nicolas, Thank you for the point in the right direction.
Updated•8 years ago
|
Assignee: nobody → b.aytes
Comment 8•8 years ago
|
||
Screenshot of black logo on checkered background for devtools tooltip
Comment 9•8 years ago
|
||
Screenshot of white logo on checkered background for devtools tooltip
Comment 10•8 years ago
|
||
Screenshot of colored logo on checkered background for devtools tooltip
Updated•8 years ago
|
Attachment #8754464 -
Flags: ui-review?(hholmes)
Updated•8 years ago
|
Attachment #8754465 -
Flags: ui-review?(hholmes)
Updated•8 years ago
|
Attachment #8754467 -
Flags: ui-review?(hholmes)
Comment 11•8 years ago
|
||
Screenshots added for ui-reivew by :helenvholmes showing checkered background on the devtools tooltip(s) have been added.
Comment 12•8 years ago
|
||
Comment on attachment 8754467 [details] coloredLogo.png - colored logo over top of checkered background for devtools tooltip I'm noticing some odd overlap in this screenshot: http://cl.ly/3A11380e2R0z is that because of the background image not lining up perfectly? I also think that the background is a little dark. Could we lighten it up to match the background colors of say Sketch? http://cl.ly/1K1s223Y3a13
Attachment #8754467 -
Flags: ui-review?(hholmes) → feedback+
Comment 13•8 years ago
|
||
Comment on attachment 8754465 [details]
whiteLogo.png - white logo over top of checkered background for devtools tooltip
I'm thinking that we might want to keep the pixel values over top of a white background for readability. Can we have the checkered background not span the entire height of the tooltip, but leave say, 15px of white background at the bottom with the pixel label vertically centered within it?
Attachment #8754465 -
Flags: ui-review?(hholmes) → ui-review+
Updated•8 years ago
|
Attachment #8754464 -
Flags: ui-review?(hholmes)
Updated•8 years ago
|
Attachment #8754465 -
Flags: ui-review+ → feedback+
Comment 14•8 years ago
|
||
Attachment #8754464 -
Attachment is obsolete: true
Attachment #8754465 -
Attachment is obsolete: true
Attachment #8754467 -
Attachment is obsolete: true
Attachment #8754867 -
Flags: ui-review?(hholmes)
Comment 15•8 years ago
|
||
Attached '1067999.patch' User: Brad Aytes Email: b.aytes@gmail.com Bug 1067999 - Fixed "Images in background-image tooltips aren't always easy to see" by creating a new css class and adding a repeating checkered background image for the tooltip widget. Files Modified: ~/devtools/client/shared/widgets/Tooltip.js Line 584: vbox.className = "devtools-tooltip-simple-bg-container"; ~/devtools/client/themes/common.css Line 212-216: /* Tooltip: Background Image */ .devtools-tooltip-simple-bg-container { background-image: url("chrome://devtools/skin/images/repeating-bg.png"); background-repeat: repeat; } ~/devtools/client/jar.mn Line 189: skin/images/repeating-bg.png (themes/images/repeating-bg.png) The 'repeating-bg.png' image has been added to: ~/devtools/client/themes/images/repeating-bg.png
Attachment #8755067 -
Flags: ui-review?(hholmes)
Comment 16•8 years ago
|
||
Comment on attachment 8754867 [details]
tooltipBG-LogoSS.zip - blackLogo.png - Logos over top of checkered background for devtools tooltip
Hey Brad,
Looks like some of the review from my last pass isn't in these images—was that intentional or just a uploading error?
Attachment #8754867 -
Flags: ui-review?(hholmes) → ui-review-
Comment 17•8 years ago
|
||
Comment on attachment 8755067 [details] [diff] [review] 1067999.patch Hey Brad, can you make sure this is rebased with today's fx-team? I'm having issues applying this cleanly.
Attachment #8755067 -
Flags: ui-review?(hholmes)
Comment 18•8 years ago
|
||
Helen, Yes that was an uploading errormy last comment was the updated one & yes as soon as I get back to the house I'll pull down the latest and apply the updates re-create the patch and upload it for you. Let me know if you need anything else in the mean time. Thanks, Brad
Comment 19•8 years ago
|
||
Comment on attachment 8755067 [details] [diff] [review] 1067999.patch Review of attachment 8755067 [details] [diff] [review]: ----------------------------------------------------------------- ::: devtools/client/shared/widgets/Tooltip.js @@ +580,5 @@ > > // Main container > let vbox = this.doc.createElement("vbox"); > vbox.setAttribute("align", "center"); > + vbox.className = "devtools-tooltip-simple-bg-container"; Instead of introducing this new classname, can you use the existing .devtools-tooltip-tiles class instead ? That also means the image you've introduced can be removed. See https://dxr.mozilla.org/mozilla-central/source/devtools/client/themes/common.css#236
Comment 20•8 years ago
|
||
I apologize for the delay on this, I'm working this up now and will submit a new patch once completed. Thanks, Brad
Comment 21•8 years ago
|
||
*** EDITED *** Per 'Tim Nguyen :ntim' instructions. Attached '1067999-06012016.patch' User: Brad Aytes Email: b.aytes@gmail.com *** EDITED *** Bug 1067999 - Fixed "Images in background-image tooltips aren't always easy to see" by creating a new css class and adding a repeating checkered background image for the tooltip widget. Files Modified: ~/devtools/client/shared/widgets/Tooltip.js Line 584: vbox.className = "devtools-tooltip-tiles"; } REMOVED: ~/devtools/client/themes/common.css Line 212-216: /* Tooltip: Background Image */ .devtools-tooltip-simple-bg-container { background-image: url("chrome://devtools/skin/images/repeating-bg.png"); background-repeat: repeat; ~/devtools/client/jar.mn Line 189: skin/images/repeating-bg.png (themes/images/repeating-bg.png) REMOVED: The 'repeating-bg.png' image has been removed to: ~/devtools/client/themes/images/repeating-bg.png
Attachment #8754867 -
Attachment is obsolete: true
Attachment #8755067 -
Attachment is obsolete: true
Attachment #8758997 -
Flags: ui-review?(hholmes)
Attachment #8758997 -
Flags: review?(ntim.bugs)
Comment 22•8 years ago
|
||
Comment on attachment 8758997 [details] [diff] [review] 1067999-06012016.patch Review of attachment 8758997 [details] [diff] [review]: ----------------------------------------------------------------- It seems like this patch applies on top of a previous patch I don't have. Can you post a folded patch ? ::: devtools/client/jar.mn @@ +184,5 @@ > skin/images/command-console.svg (themes/images/command-console.svg) > skin/images/command-eyedropper.svg (themes/images/command-eyedropper.svg) > skin/images/command-rulers.svg (themes/images/command-rulers.svg) > skin/images/command-measure.svg (themes/images/command-measure.svg) > + skin/images/command-noautohide.svg (themes/images/command-noautohide.svg) nit: trailing whitespace ::: devtools/client/shared/widgets/Tooltip.js @@ +575,5 @@ > */ > setImageContent: function(imageUrl, options={}) { > if (!imageUrl) { > return; > } nit: trailing whitespace @@ +579,5 @@ > } > > // Main container > let vbox = this.doc.createElement("vbox"); > + vbox.setAttribute("align", "center"); nit: trailing whitespace
Attachment #8758997 -
Flags: review?(ntim.bugs)
Comment 23•8 years ago
|
||
Sure, how do I create the 'folded patch'? hg qpush --move my-first-patch ? Thanks, Brad
Reporter | ||
Comment 24•8 years ago
|
||
If this bug requires 2 patches to be fixed, then you should post both patches here. Unless it depends on an other bug that will land first? In which case you should mark this bug as depending on that other bug. In any case, if you want to "fold" 2 patches into 1 and you are using MQ (which appears to be the case from comment 23), then you should use the the qfold command: http://hgbook.red-bean.com/read/mercurial-queues-reference.html#id444909
Comment 25•8 years ago
|
||
Patrick, It doesn't require 2 patches, that way my mistake in creating a patch initially (for the first stab at fixing this bug, however there were a few changes that needed to be made after i created the initial patch) and once I reverted back the initial changes and made the 'final' changes, I created another patch and uploaded it here. This is why it is 'seeming' like there are multiple patches. How can I get rid of ALL of the changes and start fresh with the default mozilla-central repo and make the 'correct' changes? Any of that make sense? LOL
Flags: needinfo?(pbrosset)
Reporter | ||
Comment 26•8 years ago
|
||
(In reply to Brad Aytes [:eights] from comment #25) > How can I get rid of ALL of the changes and > start fresh with the default mozilla-central repo and make the 'correct' > changes? Using MQ, make sure you unapply all your patches first: hg qpop -a [1] Then pull the latest changes made to the repository: hg pull -u [2] Then, 2 choices: - either you have one of your patches that is clean and you want to re-apply just this one: hg qpush --move N (where N is the index of the patch in your queue) - or you really want tol start fresh as you said and in which case you can just start working and create a new patch with hg qnew [1] https://www.mercurial-scm.org/wiki/MqExtension#Command_Examples [2] https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Build_Instructions/Simple_Firefox_build#How_to_update
Flags: needinfo?(pbrosset)
Comment 27•8 years ago
|
||
Comment on attachment 8758997 [details] [diff] [review] 1067999-06012016.patch If it's all right, I'm going to clear my review flag until the new patch gets attached :)
Attachment #8758997 -
Flags: ui-review?(hholmes)
Comment 28•8 years ago
|
||
Absolutly, Sorry! I'm a Few Days Behind.
Comment 29•8 years ago
|
||
This should be a clean patch now with no dependencies. Let me know if it is not. Thanks, Brad
Attachment #8758997 -
Attachment is obsolete: true
Attachment #8760558 -
Flags: review?(ntim.bugs)
Comment 30•8 years ago
|
||
Comment on attachment 8760558 [details] [diff] [review] 1067999-reBuilt.patch Review of attachment 8760558 [details] [diff] [review]: ----------------------------------------------------------------- The patch now applies fine, but I can't seem to see the checkered background anywhere when running the build. Maybe the class needs to be applied on a different element ?
Attachment #8760558 -
Flags: review?(ntim.bugs)
Comment 31•8 years ago
|
||
It seems to be applied on the netmonitor image tooltip, which is a good thing, but not in the inspector tooltip. The inspector relies on the HTML tooltip which is here: https://dxr.mozilla.org/mozilla-central/source/devtools/client/shared/widgets/tooltip/ImageTooltipHelper.js#50 So you'll have to add it there as well.
Comment 32•8 years ago
|
||
Also, instead of adding the class on the container, I think it would be better to apply it on the image itself: https://dxr.mozilla.org/mozilla-central/source/devtools/client/shared/widgets/Tooltip.js#563 . This way, the labels still remain visible.
Comment 33•8 years ago
|
||
Note that you can use `hg qref` to fold the changes in your top-most patch without creating a new patch for each change.
Comment 34•8 years ago
|
||
(In reply to Tim Nguyen :ntim from comment #31) > It seems to be applied on the netmonitor image tooltip, which is a good > thing, but not in the inspector tooltip. > > The inspector relies on the HTML tooltip which is here: > https://dxr.mozilla.org/mozilla-central/source/devtools/client/shared/ > widgets/tooltip/ImageTooltipHelper.js#50 > > So you'll have to add it there as well. Sorry about that, I didn't see this bug! I should have warned you about the HTML Tooltip migration. We still have one panel using XUL Tooltips for images: the netmonitor, so if you intend to fix this now you will indeed have to do it both for the XUL Tooltip and for the HTML Tooltip. (FWIW, the netmonitor tooltips will be migrated in Bug 1277264, but since we are focusing on the inspector for now, it might not happen before a while) Sorry again for the double maintenance, ping me if you have any question about the HTMLTooltip implementation.
Comment 35•8 years ago
|
||
I dont seem to have a /devtools/client/shared/widgets/tooltip/ImageTooltipHelper.js in my source. Am I missing something?
Comment 36•8 years ago
|
||
(In reply to Brad Aytes [:eights] from comment #35) > I dont seem to have a > /devtools/client/shared/widgets/tooltip/ImageTooltipHelper.js in my source. > Am I missing something? This is a recent addition, you probably need to pull and update your repository. This file landed just 13 days ago : https://hg.mozilla.org/integration/fx-team/rev/a41f8a55229c
Comment 37•8 years ago
|
||
(In reply to Julian Descottes [:jdescottes] from comment #36) > (In reply to Brad Aytes [:eights] from comment #35) > > I dont seem to have a > > /devtools/client/shared/widgets/tooltip/ImageTooltipHelper.js in my source. > > Am I missing something? > > This is a recent addition, you probably need to pull and update your > repository. This file landed just 13 days ago : > https://hg.mozilla.org/integration/fx-team/rev/a41f8a55229c I went and did a 'hg pull' and then a 'hg update' and it says: eights@dev:~/Code/mozilla/mozilla-central$ hg pull pulling from https://hg.mozilla.org/mozilla-central searching for changes adding changesets adding manifests adding file changes added 896 changesets with 3392 changes to 2135 files (run 'hg update' to get a working copy) eights@dev:~/Code/mozilla/mozilla-central$ hg update 0 files updated, 0 files merged, 0 files removed, 0 files unresolved 1 other heads for branch "default"
Comment 38•8 years ago
|
||
You need to explicitly update to the latest changeset here: "hg update tip" I am not using mq, so I don't know how you can reapply your patch on top of the new tip. According to Patrick in comment 26, looks like you can do something like: > hg qpush --move N (where N is the index of the patch in your queue)
Comment 39•8 years ago
|
||
ok, thanks. I should obviously 'hg update tip' before reapplying the patch on top correct?
Comment 40•8 years ago
|
||
(In reply to Brad Aytes [:eights] from comment #39) > ok, thanks. I should obviously 'hg update tip' before reapplying the patch > on top correct? I never needed to do that with MQ.
Reporter | ||
Comment 41•8 years ago
|
||
[good first bug] whiteboard -> keyword mass change
Keywords: good-first-bug
Comment 42•8 years ago
|
||
Hey Brad, do you need help to finish this bug ? Since you have a patch it would be nice to have it in the tools :)
Flags: needinfo?(b.aytes)
Comment 43•8 years ago
|
||
Just a heads up, the image tooltip has since moved to a HTML tooltip. The file that should be modified here is devtools/client/shared/widgets/tooltip/ImageTooltipHelper.js The markup for the image tooltip is being created in setImageTooltip() [1] (looking at the current implementation, feel free to take the opportunity of moving some of the inline styles to a class :) ) [1] http://searchfox.org/mozilla-central/rev/d96317a351af8aa78ab9847e7feed964bbaac7d7/devtools/client/shared/widgets/tooltip/ImageTooltipHelper.js#82
Assignee | ||
Comment 44•7 years ago
|
||
Hi, I have found this issue on my devtools and fix it. This issue is idle since 2016-10, so I submitted my patch, sorry if I need to talk something (it's my first mozilla patch). Let me know if I need to change or send something.
Attachment #8845915 -
Flags: ui-review?(pbrosset)
Attachment #8845915 -
Flags: ui-review?(jdescottes)
Attachment #8845915 -
Flags: ui-review?(chevobbe.nicolas)
Assignee | ||
Comment 45•7 years ago
|
||
This is a preview from my patch. I have a newbie question, I added an image background for that commit, should I send checkered-background.png file here with the patch?
Assignee | ||
Comment 46•7 years ago
|
||
When put background on wrapper like I did, it show a little of the checkered background even when image isn't transparent. This fix this problem: added checkered background to img.
Attachment #8845915 -
Attachment is obsolete: true
Attachment #8845915 -
Flags: ui-review?(pbrosset)
Attachment #8845915 -
Flags: ui-review?(jdescottes)
Attachment #8845915 -
Flags: ui-review?(chevobbe.nicolas)
Attachment #8845934 -
Flags: ui-review?
Assignee | ||
Comment 47•7 years ago
|
||
Preview from my last patch.
Attachment #8845930 -
Attachment is obsolete: true
Comment 48•7 years ago
|
||
Comment on attachment 8845934 [details] [diff] [review] bug1067999.patch Review of attachment 8845934 [details] [diff] [review]: ----------------------------------------------------------------- Looks great thanks! ::: devtools/client/shared/widgets/tooltip/ImageTooltipHelper.js @@ +86,5 @@ > justify-content: center; > min-height: 1px;"> > + <img style="height: ${imgHeight}px; > + background-image: url('chrome://devtools/skin/images/checkered-bg.png'); > + background-repeat: round repeat; The devtools-tooltip-tiles class does exactly this without the need of the image or the background properties. Can you use it ?
Attachment #8845934 -
Flags: ui-review?
Assignee | ||
Comment 49•7 years ago
|
||
Attachment #8845934 -
Attachment is obsolete: true
Attachment #8846101 -
Flags: ui-review?(ntim.bugs)
Updated•7 years ago
|
Attachment #8846101 -
Flags: ui-review?(ntim.bugs) → review+
Updated•7 years ago
|
Attachment #8760558 -
Attachment is obsolete: true
Flags: needinfo?(b.aytes)
Updated•7 years ago
|
Assignee: b.aytes → sy.fen0
Updated•7 years ago
|
Keywords: checkin-needed
Comment 50•7 years ago
|
||
Pushed by ryanvm@gmail.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/40da036eabf6 Fixed 'Images in background-image tooltips aren't always easy to see' by adding a repeating image for the tooltip widget. r=ntim
Keywords: checkin-needed
Comment 51•7 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/40da036eabf6
Status: NEW → RESOLVED
Closed: 7 years ago
status-firefox55:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 55
Comment 53•7 years ago
|
||
[bugday-20170322] status-ff55: verified and fixed BuildID : 20170321030211
Comment 54•7 years ago
|
||
I have reproduced this bug with Firefox nightly 35.0a1 (build id:20140916030204)on windows 7(64 bit) I have verified this bug as fixed with Firefox nightly 55.0a1(build id:20170502030211) User Agent:Mozilla/5.0 (Windows NT 6.1; WOW64; rv:55.0) Gecko/20100101 Firefox/55.0 [bugday-20170503]
Updated•7 years ago
|
Status: RESOLVED → VERIFIED
Updated•6 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•