User:JJMC89/common.js

/*** Import Local Scripts ***/ importScript('MediaWiki:Gadget-protectionNotices.js'); importScript('MediaWiki:Gadget-SysopTools.js'); importScript('MediaWiki:Gadget-codeBacklinks.js'); importScript('User:JJMC89/ajaxRollback.js'); //importScript('MediaWiki:Gadget-listStyles.js'); //Doesn't seem to work. /*** /Import Local Scripts ***/

/** * Make [rollback] and "blocklink" disappear on Watchlist, RecentChanges, and Contributions. * From User:Technical 13 */ if (wgPageName == "Special:Watchlist" || wgPageName == "Special:RecentChanges" || wgCanonicalSpecialPageName == "Contributions") { $('span.mw-rollback-link').remove; $('span.mw-usertoollinks').each(function {		$(this).children('a:last').replaceWith("-");		$(this).html($(this).html.replace(" | -", ""));	}); }

/** * AjaxPatrolLinks * Author: Krinkle * File:Krinkle_AjaxPatrolLinks.js * http://meta.wikimedia.org/wiki/User:Krinkle/Scripts/AjaxPatrolLinks * http://meta.wikimedia.org/wiki/User:Krinkle/Scripts/AjaxPatrolLinks.js * Note: MediaWiki 1.21 includes this functionality. */ mw.loader.load('//meta.wikimedia.org/w/index.php?title=User:Krinkle/Scripts/AjaxPatrolLinks.js&action=raw&ctype=text/javascript');

/* * Add custom delete reasons * Author: Krinkle * File:Krinkle_addDeleteReasons.js * http://meta.wikimedia.org/wiki/User:Krinkle/Scripts/addDeleteReasons * http://meta.wikimedia.org/wiki/User:Krinkle/Scripts/addDeleteReasons.js */ $.getScript( 'http://meta.wikimedia.org/w/index.php?title=User:Krinkle/Scripts/addDeleteReasons.js&action=raw&ctype=text/javascript', function{ krAddDeleteReasons.File( 'Image of an item that never existed' );  krAddDeleteReasons.File( 'Invalid file extension per Naming policy' );

});

/* * Real-Time Recent Changes (RTRC) * Author: Krinkle * File:Krinkle_RTRC.js * http://meta.wikimedia.org/wiki/User:Krinkle/Tools/Real-Time_Recent_Changes * http://meta.wikimedia.org/wiki/User:Krinkle/RTRC.js */ // Disabled for testing. // mw.loader.load('//meta.wikimedia.org/w/index.php?title=User:Krinkle/RTRC.js&action=raw&ctype=text/javascript');

/** * What Leaves Here * Author: Krinkle * File:Krinkle_WhatLeavesHere.js * http://meta.wikimedia.org/wiki/User:Krinkle/Tools/WhatLeavesHere * http://meta.wikimedia.org/wiki/User:Krinkle/Tools/WhatLeavesHere.js */ // Disabled for testing. // mw.loader.load('//meta.wikimedia.org/w/index.php?title=User:Krinkle/Tools/WhatLeavesHere.js&action=raw&ctype=text/javascript');

/** * Extra buttons in toolbar * Author: Krinkle * File:Krinkle_InsertWikiEditorButton.js * http://meta.wikimedia.org/wiki/User:Krinkle/Scripts/insertVectorButtons * http://meta.wikimedia.org/wiki/User:Krinkle/insertVectorButtons.js */ // Disabled until needed. /*jQuery.getScript('//meta.wikimedia.org/w/index.php?title=User:Krinkle/Scripts/InsertWikiEditorButton.js&action=raw&ctype=text/javascript', function {	// Happy face	krInsertWikiEditorButton({ id: "mw-customeditbutton-myspecialbutton", icon: "//upload.wikimedia.org/wikipedia/commons/thumb/a/a4/Gnome-face-smile.svg/22px-Gnome-face-smile.svg.png", label: 'Insert happy face', insertBefore: '', sampleText: 'Happy face' });	// Monkey	krInsertWikiEditorButton({ id: 'mw-customeditbutton-anotherspecialbutton', icon: '//upload.wikimedia.org/wikipedia/commons/thumb/1/1b/Gnome-face-monkey.svg/22px-Gnome-face-monkey.svg.png', label: 'Insert monkey', insertBefore: '', sampleText: 'Happy face' }); });*/