Jump to content

User:4th-otaku/common.js

From Wikipedia, the free encyclopedia
Note: After saving, you have to bypass your browser's cache to see the changes. Google Chrome, Firefox, Microsoft Edge and Safari: Hold down the ⇧ Shift key and click the Reload toolbar button. For details and instructions about other browsers, see Wikipedia:Bypass your cache.
// [[d:User:Yair rand/WikidataInfo.js]]
mw.loader.load("//www.wikidata.org/w/index.php?title=User:Yair rand/WikidataInfo.js&action=raw&ctype=text/javascript");

// [[MediaWiki:Wdsearch.js]]
importScript('MediaWiki:Wdsearch.js');

// [[MediaWiki:Gadget-oldeditor.js]] -- fixed
/*
$(document).ready(function (){
	var state = mw.loader.getState('ext.visualEditor.viewPageTarget.init');
	if (state != 'registered') { // 'registered' actually means 'not loading'
		mw.loader.using('ext.visualEditor.viewPageTarget.init', function () {
			if( $('#ca-ve-edit').length > 0 ) {
				// Kill the tab
				$('#ca-edit a').text('Edit');
				$('#ca-ve-edit').remove();

				// Kill the section edit links
				$('.mw-editsection a').text('edit');
				$('.mw-editsection-divider, .mw-editsection-visualeditor').remove();
			}
		});
	}
});
*/