Refined-github: Add button and make it easier to discover the hiding of inline comments

Created on 12 May 2016  路  12Comments  路  Source: sindresorhus/refined-github

Sometimes it's nice when code reviewing to hide comments to get a view of just the code. There is already a checkbox to "Show Notes" but it is only per file. I would like to have a keyboard shortcut and/or global checkbox to hide/show ALL comments.

enhancement help wanted

Most helpful comment

Damn (or hurray depending on how you look at it). There's already a shortcut to do this. Pressing i on the Files page toggles all inline Notes. I guess we can close this issue. I should have dug deeper into the "Show All" link for keyboard shortcuts in github.
image

All 12 comments

I like this idea a lot - I found myself doing this manually with devtools in BitBucket the other day 馃槅

@sindresorhus @paulmolluzzo @hkdobrev what do y'all think?

Sounds good to me as long as they're visible by default. If comments are missing by default it'll be confusing to those who don't know about the feature. :+1:

I agree the comments should remain visible by default so we're not breaking the user's expectation for that page.
I might take a shot at implementing this. Any thoughts on the key combo to toggle them on off?
My initial thought CMD+SHIFT+C already opens the chrome dev tools to inspect an element.
Perhaps something with N for Notes .. CMD+OPTION+N (Mac) - CTRL+ALT+N (Win) ?

I would be happy with just a button, but if you think a keyboard shortcut is needed I'll go with something that's consistent with GitHub default shortcuts as we've added new ones which are consistent with them.

Damn (or hurray depending on how you look at it). There's already a shortcut to do this. Pressing i on the Files page toggles all inline Notes. I guess we can close this issue. I should have dug deeper into the "Show All" link for keyboard shortcuts in github.
image

Haha, nice! Now when I see it again I think I've seen it before it in the full list of shortcuts, but always forget about it. We could indeed close this. Do you think there's something we could do to emphasize the ability to show/hide all inline notes?

I suppose a button or toggle somewhere in the UI would help discoverability. Perhaps adding it to the diff options dropdown as "Hide inline notes [i]" ? (The [i] represents a little keyboard shortcut indicator)
image

Just in case anyone wants to pick this up, here's a testing page with multiple files+comments:

https://github.com/sindresorhus/refined-github/pull/506/commits/840cca95b3a790f939f4eea76c68586dda539407~~

@bfred-it I don't see any GitHub comments on this page. This is about inline GitHub comments, not comments in the code.

There are, it's just that GitHub decided to change my URL to point to the commit directly :(

Here's the correct link

screen shot 2017-07-26 at 14 59 11

Given that a shortcut already exists, this seems to go against other features of Refined GitHub, where we hide buttons because shortcuts exist. Reopen if you disagree

Anyone still interested in this feature can follow up on #2398 and leave a comment

Was this page helpful?
0 / 5 - 0 ratings

Related issues

olso picture olso  路  3Comments

MilesBHuff picture MilesBHuff  路  3Comments

sindresorhus picture sindresorhus  路  3Comments

shivapoudel picture shivapoudel  路  3Comments

hkdobrev picture hkdobrev  路  3Comments