-
-
Save supermomonga/5277251 to your computer and use it in GitHub Desktop.
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
// ==UserScript== | |
// @name lingr_nicovideo | |
// @namespace raa0121 & supermomonga | |
// @description lingr_nicovideo | |
// @include http://lingr.com/* | |
// @version 1 | |
// ==/UserScript== | |
$(function(){ | |
setInterval(function(){ | |
$('.speaker[href="/bot/nicothumb"]').each(function(){$(this).parent().css('display','none')}); | |
$('.decorated a').each(function(){ | |
if($.isArray(this.href.match(/^http:\/\/(www.|live.)?nico(.ms|video.jp\/watch\/)(sm|nm|lv)?(\d+)\??/))){ | |
embedurl = ( RegExp.$3 == 'lv' ? 'http://live.nicovideo.jp/embed/' : 'http://ext.nicovideo.jp/thumb/' ) + RegExp.$3 + RegExp.$4; | |
$(this).replaceWith('<iframe style="width: 312px;height: 176px; border: 1px solid #333;" frameborder="0" scrolling="no" src="' + embedurl + '"></iframe>'); | |
} | |
}); | |
},1000); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment