Twitterのwebでin reply toのテキストを表示させるGreasemonkeyその2
Twitterのwebでin reply toのテキストを表示させるGreasemonkey - えびし日記
のグリモンを改良しました。
↑これに対応するためです…!!!
// ==UserScript== // @name show "in reply to" in twitter // @namespace eibiisii // @description Twitterのin reply toの発言を表示します。 // @include http://twitter.com/* // @include https://twitter.com/* // @exclude http://twitter.com/invitations/* // @exclude http://twitter.com/settings/* // @exclude http://twitter.com/goodies/* // @exclude https://twitter.com/invitations/* // @exclude https://twitter.com/settings/* // @exclude https://twitter.com/goodies/* // @require http://jqueryjs.googlecode.com/files/jquery-1.3.2.min.js // ==/UserScript== (function(){ $('.meta a:last-child').each(function(){ //↑変更点 if($(this).hasClass('geocoded_google_link')){//変更点 }else if($(this).is('[rel]')){//変更点 }else{ var hreftext = $(this).attr('href'); var replytext = 'hoge'; $.get(hreftext, function(data){ replytext=data.match('<span class="entry-content">.+?</span>')[0]; replytext = replytext.replace('span','div'); replytext = replytext.replace('class="entry-content"','class="my_class"'); console.log('replytext='+replytext); }); $(this).after('<span class="my_point">★in reply toを見る</span>'); $('.my_point').hover( function(){ $(this).css('cursor','pointer'); }, function(){ $(this).css(''); } ); $(this).next().toggle( function(){ $(this).after(replytext); console.log(replytext); $('.my_class').css({backgroundColor:"#f7f7f7", fontWeight:"bolder", color:"#999999", fontSize:"12px"}); }, function(){ $(this).next().slideUp(); } ); } }); })();