User:Fisssion/global.js

importArticles({   type: 'script',    articles: [        'u:dev:MediaWiki:QuickDiff/code.js',        'u:dev:MediaWiki:RevisionDelete.js',        'u:dev:MediaWiki:MultiUpload.js',        'u:dev:MediaWiki:View_Source/code.js',        'u:dev:MediaWiki:LastEdited/code.js',        'u:dev:MediaWiki:AjaxRedirect/code.js',        'u:dev:MediaWiki:Discussions Delete All/code.js',        'u:dev:MediaWiki:MassEdit/code.js',        'u:dev:MediaWiki:MassNullEdit/code.js',    ] }); (function {	"use strict";	if (mw.config.get('wgIsArticle')) {		$("#firstHeading").append($(" ").addClass("sourceCopy").html("📋"));		$(".sourceCopy").click(function { var pageTitle = location.pathname.split("/wiki/").pop; $.getJSON(mw.util.wikiScript('api'), {format: 'json', action: 'query', prop: 'revisions', rvprop: 'content', rvlimit: 1, titles: pageTitle}) .then(function(content) {				var pageName, pageSource;				for ( pageName in content.query.pages ) {					pageSource = content.query.pages[pageName].revisions[0]['*'];				}				$("body").append($(" ").attr("id", "copyArea").html(pageSource));				var copyArea = document.getElementById("copyArea");				copyArea.select;				copyArea.setSelectionRange(0, 99999);				document.execCommand("copy");				copyArea.remove;				mw.notify("Successfully copied!");			}) .catch(function {				mw.notify("API request failed.");			}); });	} }); //