User:RianL110/wikia.js

if (mediaWiki.config.get("wgAction") === "view" && (!window.localStorage || !window.localStorage.getItem('#NichibrosNotif1'))) { (function ($, mw, window) {		var wgServer = mw.config.get("wgServer"),			wgUserName = mw.config.get("wgUserName");		if (typeof wgUserName !== "string") {			$(createNotification);		} else {			var url = wgServer + "/api.php?action=query&format=json&list=usercontribs&uclimit=10&ucuser=" + window.encodeURIComponent(wgUserName);

$.get(url, function (data) {				try {					if (1) {						$(createNotification);					}				} catch (e) {}			}); }		function createNotification { // HTML for the notification (no wiki markup allowed here, e.g. link here is not HTML) var notificationHTML = ' Check out the new Main Page poll! Getting started with editing? Please refer to the Manual of Style first! This website is best viewed on desktop. '; // add notication into the page $('#NichibrosNotif1').remove; $('body').append(notificationHTML); // close the notification when clicking the x			$('#NichibrosNotif1 .close-notification').click(function {				$('#NichibrosNotif1').remove;				if (window.localStorage) {					window.localStorage.setItem('#NichibrosNotif1', 'dismissed');				}			}); }	}(jQuery, mediaWiki, window)); }

importArticles({   type: 'script',    articles: [        'u:dev:MediaWiki:ReferencePopups/code.js',    ] });