User:Devilify65536/global.js

(function($, mw){	"use strict";	var config = mw.config.get([ 'wgUserLanguage', 'wgPageName', 'wgAction' ]);	window.RevisionEditLinks = window.RevisionEditLinks || {};	function putEditLinks{		new mw.Api.get({ "action": "query", "format": "json", "meta": "allmessages", "ammessages": "editold|pipe-separator", "amlang": config.wgUserLanguage }).then (function(data){ var editlabel = RevisionEditLinks.editlabel = RevisionEditLinks.editlabel==null?data.query.allmessages[0]["*"]:RevisionEditLinks.editlabel, separator = data.query.allmessages[1]["*"]; $(".mw-contributions-list > li").queue(function{				var pgname = $(this).find('.mw-contributions-title').length?$(this).find('.mw-contributions-title').text:config.wgPageName,				revid = $(this).attr('data-mw-revid');				if ($(this).find('.mw-changeslist-links:not(.mw-usertoollinks, .mw-history-histlinks)').length)$(this).find('.mw-changeslist-links:not(.mw-usertoollinks, .mw-history-histlinks)').append(' ' + (config.wgAction == "history"?' ':) + '' + editlabel + '' + (config.wgAction = "history"?' ':'') + ' ');				else $(this).find($(this).find('.mw-tag-markers').length?'.mw-tag-markers':'.comment').before(' ' + editlabel + '  '); });			$("table.mw-changeslist-line").queue(function{ var pgname = $(this).find('.mw-changeslist-title').text, revid = $(this).attr('data-mw-revid'); if (revid == null) { $(this).find("tr.mw-changeslist-line").queue(function{						var revid = $(this).attr('data-mw-revid');						$(this).find(".mw-changeslist-diff").after(separator + ' ' + editlabel + ' ')					}) } else { $(this).find('.mw-changeslist-links:not(.mw-usertoollinks, .mw-history-histlinks)').append(' ' + editlabel + ' '); }			});		});	}	mw.loader.using([       'mediawiki.api',        'mediawiki.user',    ], putEditLinks); })(jQuery, mediaWiki);