Closed Bug 1047132 Opened 10 years ago Closed 4 years ago

DevTools: Panel button should show on hover a pointer cursor

Categories

(DevTools :: Framework, defect, P3)

34 Branch
defect

Tracking

(firefox75 verified)

VERIFIED FIXED
Firefox 75
Tracking Status
firefox75 --- verified

People

(Reporter: sys.sgx, Assigned: aarushivij, Mentored)

Details

(Keywords: good-first-bug)

Attachments

(8 files, 1 obsolete file)

User Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:34.0) Gecko/20100101 Firefox/34.0 (Beta/Release)
Build ID: 20140731030206

Steps to reproduce:

Click on the DevTools network panel, reload the page and click on the "Toggle performance analysis" link. You will get the graphics shown in the attached image.

The mouse cursor should be a "pointer" one when hovering the "Back" button link, since its linking to another "page". Currently, hovering the mouse it has an arrow cursor over the button.
Component: Untriaged → Developer Tools: Netmonitor
OS: Windows 7 → All
Hardware: x86 → All
Summary: DevTools: Network Panel button should have a pointer cursor → DevTools: Network Panel button should show on hover a pointer cursor
Attached image Button.png
(In reply to sys.sgx from comment #0)
> The mouse cursor should be a "pointer" one when hovering the "Back" button
> link, since its linking to another "page". 
It's probably following the same behavior as the other devtools (click on the titles: inspector, console etc)
The Inspector button resides in the "button area" of the devtools. Here, there is a button that is inside the information area of the network panel, so it's not distinguishable that this is something that can be clicked.
I could see arguing either way, but I agree it should probably turn into an arrow cursor since it's navigational. There is probably a dev tools UX designer with a strong opinion for this one!
Status: UNCONFIRMED → NEW
Ever confirmed: true
Every clickable button should have the pointer cursor. I'd happy to mentor anyone who want help.

The button we want to have the pointer cursor in netmonitor are:

1. Back button on "Toggle performance analysis" link
Defined in components/statistics_panel http://searchfox.org/mozilla-central/source/devtools/client/netmonitor/components/statistics-panel.js#252

2. The `Edit and Resend` and `Raw headers` button on headers sidebar panel
http://searchfox.org/mozilla-central/source/devtools/client/netmonitor/shared/components/headers-panel.js#201

3. The `Reload` and `statistics` icon in request-list-empty view
http://searchfox.org/mozilla-central/source/devtools/client/netmonitor/components/request-list-empty.js#40

What we need to do is find related element's classes, add correct style `cursor: pointer;` in netmonitor.css and make sure it does not affect other place.
Mentor: gasolin
Keywords: good-first-bug
Hey! I would like to work on this. I already have built Firefox and will look now for the CSS file you mentioned, Fred.
Flags: qe-verify?
Whiteboard: [netmonitor] [triage]
So, I have made the changes, but when I tried to actually push them I got an error saying that someone needs to assign this bug to me.
Sorry, this is my first time sending a patch here, haha. So, can someone assign this to me?
Thanks!
Flags: needinfo?(gasolin)
Assignee: nobody → beatriz.rizental
Flags: needinfo?(gasolin)
Whiteboard: [netmonitor] [triage] → [netmonitor-reserve]
Status: NEW → ASSIGNED
(Thanks Marco to help assign the bug)

Beatriz, thanks for the quick patch! 

With this patch every thing works well, and I think it could be put into common.css so every devtool panels button shows a pointer cursor when hovered.

ntim, How do you think? Do we want this normal button hover affect for all devtools panels?
Flags: needinfo?(ntim.bugs)
Flags: qe-verify? → qe-verify+
QA Contact: ciprian.georgiu
(In reply to Fred Lin [:gasolin] from comment #9)
> (Thanks Marco to help assign the bug)
> 
> Beatriz, thanks for the quick patch! 
> 
> With this patch every thing works well, and I think it could be put into
> common.css so every devtool panels button shows a pointer cursor when
> hovered.
> 
> ntim, How do you think? Do we want this normal button hover affect for all
> devtools panels?

It's worth pointing out that the rest of the browser UI doesn't have a pointer cursor when hovering over buttons. So I'd let UX decide.

I personally don't have a strong opinion, but whatever we go with, it should be affect the whole toolbox, not just the netmonitor.

[0]: https://dxr.mozilla.org/mozilla-central/source/devtools/client/themes/common.css#245
Flags: needinfo?(ntim.bugs)
Hello guys,

So, I was having a look here at the panel and I agree that we should standardize the feedback for hovered button throughout all devtools, but maybe the cursor pointer thing is not the way to go.

I think that the problem that triggered this bug was that some of the buttons on the netmonitor don't give proper feedback when hovered over. This problem has not appeared on other areas of the devtools because other buttons give better feedback, most of them change color intensity and background color when hovered over.

I think the best thing to do would be to create a standart interaction for all buttons on the devtools, changing color more noticeably when hovered over, etc. And maybe not putting "cursor: pointer" on all of them, because I think that would be too much.

I will give this a try and send a patch, ok?
Thanks ntim's feedback, I changed title and category to reflect this issues should be resolved through whole panels, not netmonitor specific.

I think it make sense to make `button` behave like normal button when we advocate our devtool as devtools.html.


Beatriz, good suggestion! Thank you for volunteer to take a more longer time investigation.

It will help if you can post which parts you want to change, before send a patch. 
With this way people look at this issue can express their opinions and avoid some repeat works.
Component: Developer Tools: Netmonitor → Developer Tools: Framework
Flags: needinfo?(beatriz.rizental)
Summary: DevTools: Network Panel button should show on hover a pointer cursor → DevTools: Panel button should show on hover a pointer cursor
No longer blocks: netmonitor-html
Whiteboard: [netmonitor-reserve]
Ok Fred. 

So I was having a look now at the whole DevTools, searching for design inconsistencies and minor problems and I found some of them which I'll list here.

1. For Stand Alone buttons (like the one for Inspector>Animations>Pick an element form the page, or in Performance>Start Recording Performance, or even the Network>Reload buttons) the hover feedback is not really clear. So I think that for them, we should have a more drastic change of color and background. Also, they look different every time, so I guess we should standardize that. For these kinds of buttons I think the "cursor: pointer" would be useful.

2. In the Debugger tab, both "Collapse Panel" buttons are different than they are in other tabs. The "Pause" and "Step" buttons also are not like any other button on the DevTools. Still on the Debugger tab, everything now has "cursor: pointer", that should be removed once the right interaction for hovering is in place.

Now, these are the button questions that I found. The other ones are about design inconsistencies overall in the DevTools and I don't know if I should open a new bug for them here in Bugzilla or if we could just change this bug's name to something like "DevTools: straightening out design inconsistencies etc". I'll list them here anyways.

1. The Performance and Memory tabs are mostly the same when nothing is happening, but the alignment of the center button is different. Also the "Clear" button should be inactive on the Performance tab when there is nothing there to be cleared, just like on the Memory tab. Finally, we could put a "There are no snapshots yet." message on the Memory tab, just like there is in the Performance.

2. The debugger left-side panel should have the same styles as the Performance and Memory ones, since they are similar and have mostly the same parts.

I guess that's it for now, let me know what you think :)

(I'm sorry for not adding any screenshots here, I tried to, but could not figure out how. I'll look into it later, haha. Still learning how to use Bugzilla...)
Flags: needinfo?(beatriz.rizental)
Beatriz, Thanks for the detailed report! I saw several valuable investigation here.

There are some actions you can do:

* You could file bugs in related bugzilla components, to make sure they will be tracked (while file the bug, you can put this bug in `see also` field for track)
* The debugger UI consistency is only happened in nightly because its a newly written, different debugger. (https://github.com/devtools-html/debugger.html) We'll ship it to before we get similar UI, so you don't have to file related bugs(and they might already there...)


Since this issue need more time for UX commitment and discussion, I suggest you to pick another one bug and come back later to track the status. 

Great Job!
Will do, Fred!

Thanks for the feedback.
Product: Firefox → DevTools

This bug has not been updated in the last 6 months. Resetting the assignee field.
Please, feel free to pick it up again and add a comment outlining your plans for it if you do still intend to work on it.
This is just trying to clean our backlog of bugs and make bugs available for people.

Assignee: beatriz.rizental → nobody
Status: ASSIGNED → NEW

(In reply to Patrick Brosset <:pbro> from comment #16)

Hello Patrick,

I may be interested in pick up this bug. Could you help me to see what is left to do to finish this bug? Thank you

Are you still interested in this ?

Flags: needinfo?(helenaenred)

Hello,

Is this bug still available? I would like to work on it.

Mentor: gasolin
Flags: needinfo?(helenaenred)

Victoria, this bug is about (In reply to u566121 from comment #13)

  1. For Stand Alone buttons (like the one for Inspector>Animations>Pick an
    element form the page, or in Performance>Start Recording Performance, or
    even the Network>Reload buttons) the hover feedback is not really clear. So
    I think that for them, we should have a more drastic change of color and
    background. Also, they look different every time, so I guess we should
    standardize that. For these kinds of buttons I think the "cursor: pointer"
    would be useful.

  2. In the Debugger tab, both "Collapse Panel" buttons are different than
    they are in other tabs. The "Pause" and "Step" buttons also are not like any
    other button on the DevTools. Still on the Debugger tab, everything now has
    "cursor: pointer", that should be removed once the right interaction for
    hovering is in place.

Now, these are the button questions that I found. The other ones are about
design inconsistencies overall in the DevTools and I don't know if I should
open a new bug for them here in Bugzilla or if we could just change this
bug's name to something like "DevTools: straightening out design
inconsistencies etc". I'll list them here anyways.

  1. The Performance and Memory tabs are mostly the same when nothing is
    happening, but the alignment of the center button is different. Also the
    "Clear" button should be inactive on the Performance tab when there is
    nothing there to be cleared, just like on the Memory tab. Finally, we could
    put a "There are no snapshots yet." message on the Memory tab, just like
    there is in the Performance.

  2. The debugger left-side panel should have the same styles as the
    Performance and Memory ones, since they are similar and have mostly the same
    parts.

I guess that's it for now, let me know what you think :)

(I'm sorry for not adding any screenshots here, I tried to, but could not
figure out how. I'll look into it later, haha. Still learning how to use
Bugzilla...)

Thanks for the summary!

Most of the things in this summary has been fixed over time, except of the hover button s in the Performance panel I think. But, this panel is subject for significant refactoring so, I think we can solve that hovering elsewhere.

Honza

Attached image image.png

Victoria, this bug is about cursor for the back button in the Network panel (performance analysis view). See the attached screenshot. It's currently 'pointer' and the suggestion is to use 'hand'.

It looks like we are using pointer for buttons across the DevTools UI so, I tend to say we should keep it but, wanted to check with you first.

Honza

Flags: needinfo?(victoria)

Yes, the more pressing issue is that the button itself doesn't look like any other buttons.

A quick fix for this could be changing the shape of the button to a photon style button. This indeed should keep the pointer cursor.

Mockup: https://www.figma.com/file/Ni3AVbCkUFl1WEyElPg2Xh/network-performance-analysis?node-id=0%3A1

Flags: needinfo?(victoria)

Hello, Can I work on this bug.
So, do we need to change the pointer to hand or as mentioned in comment 22 change the back button UI itself
Aarushi

(In reply to Victoria Wang [:victoria] from comment #22)

Yes, the more pressing issue is that the button itself doesn't look like any other buttons.

A quick fix for this could be changing the shape of the button to a photon style button. This indeed should keep the pointer cursor.

Mockup: https://www.figma.com/file/Ni3AVbCkUFl1WEyElPg2Xh/network-performance-analysis?node-id=0%3A1

Thanks Victoria for the mockup!

(In reply to aarushivij from comment #23)

Hello, Can I work on this bug.

Assigned to you, thanks for the help.

So, do we need to change the pointer to hand or as mentioned in comment 22 change the back button UI itself

The cursor should stay the same. We only want to change the back button itself, see Victoria's mockup

Honza

Assignee: nobody → aarushivij
Status: NEW → ASSIGNED

Ok, Thanks for assigning :)
Shall get back to you soon
Aarushi

Attached image demo.png

Hello,
I have made the changes in the element.
Is it looking correct?
Also what color should the button be?
Thanks
Aarushi

Hey @Honza , please review the last comment so that I can make the changes in the file and make a patch.
Thanks :)

Attached image image.png

Hi Aarushi, you can match the button color of the Edit & Resend button in the Network sidebar. There are different colors for dark and light theme. Thanks!

Hey :victoria
I was working on the issue.
I know what rules to apply, but couldn't find the appropriate file.
I tried with using back-button class and adding the style into it in https://searchfox.org/mozilla-central/source/devtools/client/netmonitor/src/assets/styles/netmonitor.css
But the rules did not apply on the back button.
Unlike the Edit and Resend button whose style is specifically mentioned in https://searchfox.org/mozilla-central/source/devtools/client/netmonitor/src/assets/styles/NetworkDetailsPanel.css

Also about the background color of the button.
Should I use .light-theme .back-button{} style class for it.
Since the similar method is used in edit and resend button styling
So can you please guide me through.
I have attached the screenshot showing the styles to be added in .back-button.devtools-button{}
Thank you.
Aarushi

(In reply to aarushivij from comment #29)

I know what rules to apply, but couldn't find the appropriate file.

The new CSS rules should go to StatisticsPanel.css file
https://searchfox.org/mozilla-central/source/devtools/client/netmonitor/src/assets/styles/StatisticsPanel.css

Also about the background color of the button.
Should I use .light-theme .back-button{} style class for it.
Since the similar method is used in edit and resend button styling

Yes

.edit-and-resend-button button styles are here
https://searchfox.org/mozilla-central/search?q=.edit-and-resend-button+&path=

And there are separate CSS rules for light and dark themes. We need something similar for the back button.
Something like as follows:

.theme-dark  .statistics-panel .devtools-toolbarbutton.back-button {
   // CSS props for dark theme
}

.theme-light  .statistics-panel .devtools-toolbarbutton.back-button {
   // CSS props for light theme
}

I have attached the screenshot showing the styles to be added in .back-button.devtools-button{}

Please attach your current patch so, I can try it on my machine.
You might want to read the docs here:
https://firefox-source-docs.mozilla.org/devtools/contributing/making-prs.html

Honza

(In reply to Jan Honza Odvarko [:Honza] (always need-info? me) from comment #30)

.theme-dark  .statistics-panel .devtools-toolbarbutton.back-button {
   // CSS props for dark theme
}

.theme-light  .statistics-panel .devtools-toolbarbutton.back-button {
   // CSS props for light theme
}

.devtools-button is what you want, since .devtools-toolbarbutton is for XUL panels.

Also, you probably wouldn't need separate rules for theme-dark/theme-light, given that .devtools-button class + the data-standalone attribute would give you all the correct colors.

So if you need to add CSS rules (though you really don't need to, except maybe for margin), this is what you probably want:

.statistics-panel .back-button {

}

Thanks for simplification Tim!

Honza

Thanks @Honza and @Tim
Shall make the changes and share the patch soon.

Hello
I have made the changes.
The specification for background color for dark-theme wasn't needed. But since in light theme originally the back button had that greyish color on hover only , so I specified it's background color.
Thanks for all the help :)
Shall make the changes if any after review
Aarushi

Great thanks, commented in Phab.
Honza

Hey @Honza
Sorry, I submitted a new patch, though I used the amend command to make the changes in my commit. As mentioned in https://docs.firefox-dev.tools/contributing/making-prs.html
What was I doing wrong?
Thanks for the help
Aarushi

(In reply to aarushivij from comment #38)

Hey @Honza
Sorry, I submitted a new patch, though I used the amend command to make the changes in my commit. As mentioned in https://docs.firefox-dev.tools/contributing/making-prs.html
What was I doing wrong?

Do not specify new -m commit message
(the doc needs to be fixed, see also bug 1613578)

Honza

Oh okay.
But now if I will amend, it will amend the new patch.
Is the latest patch acceptable.
Made the spacing changes in it.

Pushed by jodvarko@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/9a504e897ba1
DevTools: Panel button should show on hover a pointer cursor. r=Honza
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 75

Hi Jan, After going through all the comments I'm a bit confused about what finally changed with this issue, is it just the Back button from the Network > Performance Analysis ?

if so, I noticed in the old builds that the button itself used to highlight a bit (change to a darker grey) when hovered over and now it does not highlight at all, I do see the Arrow cursor and the tooltip for the button. (This applies to the Dark Theme as well)

Can you please clear things up a bit so we can update the flags accordingly ?

Flags: needinfo?(odvarko)
Attached image image.png

(In reply to Rares Doghi from comment #43)

Hi Jan, After going through all the comments I'm a bit confused about what finally changed with this issue, is it just the Back button from the Network > Performance Analysis ?

Yes, correct.

The button should follow the same UX as the one we have in the Headers side panel Edit And Resend screenshot attached.
(no hover effect)

Honza

Flags: needinfo?(odvarko)

Great, Based on Comment 44 we can confirm this issue Verified as Fixed in our latest Nightly build on Windows 10, Mac 10.14 and Ubuntu 18.04.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: