File tree Expand file tree Collapse file tree 2 files changed +15
-3
lines changed
Expand file tree Collapse file tree 2 files changed +15
-3
lines changed Original file line number Diff line number Diff line change 1212// @updateURL https://github.com/jerone/UserScripts/raw/master/Github_Reply_Comments/Github_Reply_Comments.user.js
1313// @supportURL https://github.com/jerone/UserScripts/issues
1414// @contributionURL https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=VCYMHWQ7ZMBKW
15- // @version 1.0.5
15+ // @version 1.0.6
1616// @icon https://github.githubassets.com/pinned-octocat.svg
1717// @grant none
1818// @include https://github.com/*
5959 }
6060
6161 var textareas = newComment . querySelectorAll (
62- ":scope > :not(.last-review-thread) .comment-form-textarea :not(.github-writer-ckeditor)" ,
62+ ":scope > :not(.last-review-thread) .js- comment-field :not(.github-writer-ckeditor)" ,
6363 ) ;
6464 return textareas [ textareas . length - 1 ] ;
6565 }
6868 var commentText = "" ;
6969
7070 // Use raw comment when available.
71- var commentForm = comment . querySelector ( ".comment-form-textarea " ) ;
71+ var commentForm = comment . querySelector ( ".js- comment-field " ) ;
7272 if ( commentForm ) {
7373 commentText = commentForm . value ;
7474 }
8888 } ,
8989 ) ;
9090
91+ // Refined GitHub adds a small avatar to username mention. See https://github.com/refined-github/refined-github/blob/main/source/features/small-user-avatars.tsx
92+ Array . prototype . forEach . call (
93+ commentBody . querySelectorAll ( ".rgh-small-user-avatars" ) ,
94+ function ( rgh ) {
95+ rgh . remove ( ) ;
96+ } ,
97+ ) ;
98+
9199 // GitHub add an extra new line, which is converted by Turndown.
92100 Array . prototype . forEach . call (
93101 commentBody . querySelectorAll ( "pre code" ) ,
Original file line number Diff line number Diff line change @@ -20,6 +20,10 @@ reply button on an comment.
2020
2121## Version History
2222
23+ - version ** 1.0.6**
24+
25+ - π Fix broken comment form. Fixes ([ #168 ] ( https://github.com/jerone/UserScripts/issues/168 ) ).
26+
2327- version ** 1.0.5**
2428
2529 - π Enable the Comment button. Fixes ([ #152 ] ( https://github.com/jerone/UserScripts/issues/152 ) ).
You canβt perform that action at this time.
0 commit comments