-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Fix hide-useless-comments selectors
#4013
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Co-Authored-By: Fregante <opensource@bfred.it>
|
As long as it was tested on the licecap thread for the similar comment it’s good to be merged |
|
@cheap-glitch can you look this over? Why do we use different selectors for hide and unhide? |
|
|
||
| // Expand all "similar comments" boxes | ||
| for (const similarCommentsExpandButton of select.all('.js-discussion .Details-content--closed > span:only-child')) { | ||
| for (const similarCommentsExpandButton of select.all('.pagination-loader-container .Details-content--closed > span:only-child')) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yakov116 we can indeed simplify this selector to '.js-discussion .Details-element:not([data-body-version]) > summary' (tested in both cases)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thought so but it was waay past my bed time and I wanted to release it. (We don't want broken features)
I put it on my list for my next lint
|
This broke #3992 In the linked Licecap thread you can clearly see that the similar comment is hidden, but not expanded later: |
|
Also it might be a good time to also fix that little corner. The rule should be be: .rgh our class .timeline-comment--caret:before {
border-right-color: var(--github-red);
} |
Weird, it's working for me (Firefox + |

LINKED ISSUES:
Hide and auto-expand Similar comments in
hide-useless-comments#3992TEST URLS:
LICEcap 1.3.0 does not compatible with macOS Big Sur. justinfrankel/licecap#97
SCREENSHOT:


Before
after