/* jshint multistr:true */
var ns = mw.config.get('wgNamespaceNumber'),
ul = mw.config.get('wgUserLanguage'),
pn = mw.config.get('wgPageName'),
un = mw.config.get('wgUserName'),
ti = mw.config.get('wgTitle'),
dt = new Date();
oi = ' oloc '; // or ' imag ''
fd = dt.getFullYear()+'-'+String(dt.getMonth()+1).padStart(2,'0')+'-'+String(dt.getDate()).padStart(2,'0'); // formatted date
$.when(mw.loader.using('mediawiki.util'), $.ready).done(function ()
{ "use strict";
if (ns === 6) // Files only
{ importScript('MediaWiki:Gadget-InformationToCOA.js'); // convert to COAInformation
if (/.svg/i.test(ti.slice(-4))) // SVG
{ // SVG edit
importScript('User:Rillke/SVGedit.js');
// W3C-Validator for SVG (with ss)
mw.util.addPortletLink('p-cactions', 'http://validator.w3.org/check?uri=' + 'https://commons.wikimedia.org' + mw.util.getUrl('Special:Filepath/' + ti) + '&ss=1#source', 'Valid SVG?', 't-validSVG', 'W3C-Validator', null);
// W3C-Validator check-link for every SVG (by [[User: Perhelion]]); + detailed byte-size
importScript('User:Sarang/simpleSVGcheck/sandbox.js'); // sandbox 🔴🔴🔴
// // importScript('User:Sarang/simpleSVGcheck.js');
mw.loader.load('//commons.wikimedia.org/w/index.php?title=User:Sarang/simpleSVGcheck/sandbox.js&action=raw&ctype=text/javascript'); // sandbox 🔴🔴🔴
importScript('User:Surjection/findUser.js'); // sandbox
}
// else // ^ SVG
window.GlobalReplaceDefaultReason = "now⛶svg";
// [[Commons:GlobalReplace]]
// JustReplace [[User:Sreejithk2000/JustReplace.js]]
importScript('User:Perhelion/JustReplace+.js');
// File desc. cleanup
importScript('User:Sarang/cleanup/sandbox.js'); // sandbox 🔴🔴🔴
importScript('User:Perhelion/massrename.js');
}
mw.loader.load( '//en.wikipedia.org/w/index.php?title=User:Ahecht/Scripts/refresh.js&action=raw&ctype=text/javascript' ); // Linkback: [[User:Ahecht/Scripts/refresh.js]]
// if(mw.config.get('wgNamespaceNumber')===6&&/SVG/i.test(mw.config.get('wgTitle').slice(-3)))
// importScript('User:Perhelion/simpleSVGcheck.js');
// Insert a personalized text-template into the Special:Upload edit box.
// input form, prefilled for uploading own work on current date, {{PD-self}}
if (pn === 'Special:Upload' && /&uselang=([^&]*)ownwork/.test(location.search))
{ setTimeout(function ()
{ $('#wpUploadDescription').val
( '== {{int:filedesc}} ==\n\{{Inform\n' +
'| desc = \n' + // {{F|F}}
// '| dese = \n' + // {{en|…}}
'| date = ' + fd + '\n' + // yyyy-mm-dd
'| sour = \n' + // {{own based|…}}
'| auth = ' + un + '\n' + // mw.config.get('wgUserName')
'|'+oi+'= \n}}\n' // geoloc, or igen parms
// vers; fiel; perm;
);
}, 100);
} else
{ // If not on Special:Upload change the Upload-link.
$('#n-uploadbtn').find('a').attr('href', '//commons.wikimedia.org/w/index.php?title=Special:Upload&uselang=' +
((ul === 'en') ? '' : ul) + 'ownwork&uploadformstyle=basic');
}
}); // end mw.util
//<nowiki>
//vFCvFCCfg/////////////////////////////////////
/////// VISUAL FILE CHANGE CONFIGURATION ///////
///// DO NOT MODIFY BY HAND - FINGERS AWAY! ////
////////////////////////////////////////////////
window.vFCSettings = {"userNote":"Yours sincerely,","firstTest":0,"testEdits":0,"defaultAction":"c_replace","watchlistUserTalk":"preferences","watchlistFiles":"preferences","watchlistReplace":"nochange","watchlistOTRS":"nochange","loadBatchSize":512,"maxSimultaneousReq":5,"summaryChacheLen":5,"loadThumbs":true,"loadWikitext":true};
//////////////////////////////////vFCvFCCfgEnd//
//</nowiki>