Last active
March 31, 2017 09:58
-
-
Save Getaji/f4459060f90319f87773712bb4512668 to your computer and use it in GitHub Desktop.
TweetDeckのリプライ表示を従来の形式に戻すJavaScript
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * | Replying to @Getaji | |
| * | Hogehuga | |
| * こんなやつを | |
| * | @Getaji Hogehuga | |
| * こうするスクリプト。クリック時の挙動はそのまま。 | |
| * | |
| * # 更新履歴 | |
| * ## 2017/03/31 18:49 | |
| * [fix]ツイートテキストの最初にリンクが入っている場合はスキップするように | |
| */ | |
| $('.other-replies').each(function() { | |
| const rep = $(this); | |
| const a = rep.children(); | |
| const tweet = $('.js-tweet-text', rep.closest('.js-tweet')); | |
| if (tweet.children().eq(0).hasClass('link-complex')) return; | |
| a.html(a.html().trim() + ' '); | |
| tweet.prepend(a); | |
| rep.remove(); | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment