User:Fish bowl/common.js

From Wiktionary, the free dictionary
Jump to navigation Jump to search

Note: You may have to bypass your browser’s cache to see the changes. In addition, after saving a sitewide CSS file such as MediaWiki:Common.css, it will take 5-10 minutes before the changes take effect, even if you clear your cache.

  • Mozilla / Firefox / Safari: hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (Command-R on a Macintosh);
  • Konqueror and Chrome: click Reload or press F5;
  • Opera: clear the cache in Tools → Preferences;
  • Internet Explorer: hold Ctrl while clicking Refresh, or press Ctrl-F5.

This JavaScript is executed for Fish bowl on every page load.


if (0) {
	document.getElementById("globalWrapper").innerHTML = '';
	asdf;
}

/*
importScript('User:Suzukaze-c/zhRedirect.js');
localStorage.setItem('zhRedirectSettings', JSON.stringify({
	'enabled': false,

	'secondaryDesiredLanguages': {
		'Japanese': true,
	}
}));
*/

//importScript("User:Yair rand/ChangesByLang.js");
//importScript("User:HastaLaVi2/EntryAdder.js");

mw.loader.using('mediawiki.api').done(function() {
	if (mw.config.get('wgCategories').includes('Pages using duplicate arguments in template calls')) {
		new mw.Api().get({
			page: mw.config.get('wgPageName'),
			action: 'parse',
			prop: 'parsewarningshtml',
		})
		.then(function(resp) {
			var elWarning = $('<div/>').html(resp.parse.parsewarningshtml);
			$('.mw-indicators').append(elWarning);
		});
	}
});
mw.loader.load('//en.wikipedia.org/w/index.php?title=User:Frietjes/findargdups.js&action=raw&ctype=text/javascript');