User:DestroyerTau/global.js

importArticles({   type: 'script',    articles: [    	'u:dev:MediaWiki:MultiUpload.js',    	'u:dev:MediaWiki:MassProtect/code.js',        'u:dev:MediaWiki:AjaxBatchDelete.js',    ] }); /* * Script: MorePageActions * * Author: WooperIsBest * Co-Author: Caburum * A simple script that adds extra page actions to the page contributions dropdown menu */

'use strict';
 * (function ($, mw) {

if (window.MorePageActionsLoaded) return; window.MorePageActionsLoaded = true;

const ddm = $('#p-cactions > ul'), // Gets dropdown menu currentPage = encodeURIComponent(mw.config.get('wgPageName')), path = mw.config.get('wgArticlePath');

function link(id, page, msg) { $( '' + mw.msg(msg) + '' ).appendTo(ddm); }

mw.loader.using(['mediawiki.api']).then(function {		return new mw.Api.loadMessagesIfMissing([ 'whatlinkshere', 'log', 'currentrev', 'movesubpage' ]);	}).then(function {		link('whatlinkshere ca-linkshere', 'Special:WhatLinksHere/' + currentPage, 'whatlinkshere');		link('logs', 'Special:Log?page=' + currentPage, 'log');		link('latestrevision ca-latestdiff', currentPage + '?diff=latest', 'currentrev');		link('subpages', 'Special:PrefixIndex/' + currentPage + '/', 'movesubpage');	});

}(window.jQuery, window.mediaWiki));