User:Omegatron/monobook.js/addsincetab.js: Difference between revisions

Content deleted Content added
Remove all comments for now
m Maintenance: Replacing addOnloadHook with native jQuery (mw:ResourceLoader/Migration_guide_(users)#addOnloadHook - phab:T130879)
 
(One intermediate revision by one other user not shown)
Line 1:
 
function addSinceTab() {
if (window.___location.href.indexOf("&action=history&gotosince=true")!=-1) {
Line 6 ⟶ 5:
else if (!/wiki\/Special:|w\/index.php?title=Special:/.test(window.___location.href)) {
var thetitle=document.title.slice(0, String(document.title).indexOf(" - "));
var l=addLinkaddPortletLink('p-cactions', "/w/index.php?title="+thetitle+"&action=history&gotosince=true", 'since', 'ca-since', 'View diff from last edit by me', '', 'ca-history');
l.lastChild.title="Changes since I last edited";
}
Line 32 ⟶ 31:
}
 
addOnloadHook$(addSinceTab);