User:OttoLannister550/global.js

importArticles({   type: 'script',    articles: [        'u:dev:MediaWiki:MassEdit/code.js',        'u:dev:MediaWiki:MassCategorization/code.js',        'u:dev:MediaWiki:FindAndReplace/code.js',        'u:dev:MediaWiki:AjaxRename/code.js',        'u:dev:MediaWiki:AjaxEdit.js',        'u:dev:MediaWiki:AjaxRedirect/code.js',        'u:dev:MediaWiki:MassNullEdit/code.js',        'u:dev:MediaWiki:AjaxDelete/code.js',        'u:dev:MediaWiki:AjaxBatchDelete.js',        'u:dev:MediaWiki:AjaxBatchUndelete.js',        'u:dev:MediaWiki:AjaxEditPreview.js',        'u:dev:MediaWiki:WhatLinksHere/code.js',        'u:dev:MediaWiki:TopArticles/code.js',        'u:dev:MediaWiki:MassRename/code.js',        'u:dev:MediaWiki:DisplayTimer/code.js',        'u:dev:MediaWiki:NullEditButton/code.js',        'u:dev:MediaWiki:DisableCode/code.js',        'u:dev:MediaWiki:PageCreator/code2.js',        'u:dev:MediaWiki:ThemeToggler.js', 'u:dev:MediaWiki:DateInserter/code.js', 'u:dev:MediaWiki:QuickPurge.js', 'u:dev:MediaWiki:SkinSwitchFD.js', 'u:dev:MediaWiki:MultiUpload.js', 'u:dev:MediaWiki:ImageMapEdit.js', 'u:dev:MediaWiki:ImageMapEditZoom.js', 'u:dev:MediaWiki:MobilePreview.js', ] });

/* Adding Personal CSS, Personal JS, Wiki CSS, and Wiki JS to the Wiki Tools' Dropdown */ $(function {	var i; //Creating Personal CSS' Sub Menus	var personalCSS_submenu_a, personalCSS_submenu_li;	var personalCSSName = ['Common', 'Fandomdesktop', 'FandomMobile', 'Oasis'];	var personalCSSName_lc = ['common', 'fandomdesktop', 'fandommobile', 'oasis'];	var personalCSS_submenuContainer_ul = document.createElement('ul');    personalCSS_submenuContainer_ul.className = 'wds-list wds-is-linked';	    for (i = 0; i < personalCSSName.length; i++) {		    personalCSS_submenu_a = document.createElement('a');    	    personalCSS_submenu_a.href = '/wiki/Special:MyPage/' + personalCSSName_lc[i] + '.css';    	    personalCSS_submenu_a.id = 'Personal_' + personalCSSName[i] + '_CSS';    	    personalCSS_submenu_a.innerHTML = personalCSSName[i] + ' CSS';    	    personalCSS_submenu_li = document.createElement('li');         	personalCSS_submenu_li.appendChild(personalCSS_submenu_a);    	    personalCSS_submenuContainer_ul.appendChild(personalCSS_submenu_li); }   var personalCSS_submenuContainer_div = document.createElement('div'); personalCSS_submenuContainer_div.className = 'wds-is-not-scrollable wds-dropdown-level-2__content'; personalCSS_submenuContainer_div.appendChild(personalCSS_submenuContainer_ul); //Creating Personal CSS Menu var personalCSS_menu_a = document.createElement('a'); personalCSS_menu_a.href = '#'; personalCSS_menu_a.id = 'Personal_CSS'; personalCSS_menu_a.innerHTML = 'Personal CSS'; var personalCSS_menu_li = document.createElement('li'); personalCSS_menu_li.className = 'wds-dropdown-level-2 is-calculated css-js_pages_li'; personalCSS_menu_li.appendChild(personalCSS_menu_a); personalCSS_menu_li.appendChild(personalCSS_submenuContainer_div); //Creating Personal JS' Sub Menus var personalJS_submenu_a, personalJS_submenu_li; var personalJSName = ['Common', 'Fandomdesktop', 'FandomMobile', 'Oasis']; var personalJSName_lc = ['common', 'fandomdesktop', 'fandommobile', 'oasis']; var personalJS_submenuContainer_ul = document.createElement('ul'); personalJS_submenuContainer_ul.className = 'wds-list wds-is-linked'; for (i = 0; i < personalJSName.length; i++) { personalJS_submenu_a = document.createElement('a'); personalJS_submenu_a.href = '/wiki/Special:MyPage/' + personalJSName_lc[i] + '.js'; personalJS_submenu_a.id = 'Personal_' + personalJSName[i] + '_JS'; personalJS_submenu_a.innerHTML = personalJSName[i] + ' JS'; personalJS_submenu_li = document.createElement('li'); personalJS_submenu_li.appendChild(personalJS_submenu_a); personalJS_submenuContainer_ul.appendChild(personalJS_submenu_li); }   var personalJS_submenuContainer_div = document.createElement('div'); personalJS_submenuContainer_div.className = 'wds-is-not-scrollable wds-dropdown-level-2__content'; personalJS_submenuContainer_div.appendChild(personalJS_submenuContainer_ul); //Creating Personal JS Menu var personalJS_menu_a = document.createElement('a'); personalJS_menu_a.href = '#'; personalJS_menu_a.id = 'Personal_JS'; personalJS_menu_a.innerHTML = 'Personal JS'; var personalJS_menu_li = document.createElement('li'); personalJS_menu_li.className = 'wds-dropdown-level-2 is-calculated css-js_pages_li'; personalJS_menu_li.appendChild(personalJS_menu_a); personalJS_menu_li.appendChild(personalJS_submenuContainer_div); //Creating Wiki CSS' Sub Menus var wikiCSS_submenu_a, wikiCSS_submenu_li; var wikiCSSName = ['Common', 'Fandomdesktop', 'Wikia', 'Print', 'Group-autoconfirmed', 'Group-sysop', 'Group-bot']; var wikiCSS_submenuContainer_ul = document.createElement('ul'); wikiCSS_submenuContainer_ul.className = 'wds-list wds-is-linked'; for (i = 0; i < wikiCSSName.length; i++) { wikiCSS_submenu_a = document.createElement('a'); wikiCSS_submenu_a.href = '/wiki/MediaWiki:' + wikiCSSName[i] + '.css'; wikiCSS_submenu_a.id = 'Wiki_' + wikiCSSName[i] + '_CSS'; wikiCSS_submenu_a.innerHTML = wikiCSSName[i] + ' CSS'; wikiCSS_submenu_li = document.createElement('li'); wikiCSS_submenu_li.appendChild(wikiCSS_submenu_a); wikiCSS_submenuContainer_ul.appendChild(wikiCSS_submenu_li); }   var wikiCSS_submenuContainer_div = document.createElement('div'); wikiCSS_submenuContainer_div.className = 'wds-is-not-scrollable wds-dropdown-level-2__content'; wikiCSS_submenuContainer_div.appendChild(wikiCSS_submenuContainer_ul); //Creating Wiki CSS Menu var wikiCSS_menu_a = document.createElement('a'); wikiCSS_menu_a.href = '#'; wikiCSS_menu_a.id = 'Wiki_CSS'; wikiCSS_menu_a.innerHTML = 'Wiki CSS'; var wikiCSS_menu_li = document.createElement('li'); wikiCSS_menu_li.className = 'wds-dropdown-level-2 is-calculated css-js_pages_li'; wikiCSS_menu_li.appendChild(wikiCSS_menu_a); wikiCSS_menu_li.appendChild(wikiCSS_submenuContainer_div); //Creating Wiki JS' Sub Menus var wikiJS_submenu_a, wikiJS_submenu_li; var wikiJSName = ['Common', 'Fandomdesktop', 'Wikia', 'Group-autoconfirmed', 'Group-sysop', 'Group-bot']; var wikiJS_submenuContainer_ul = document.createElement('ul'); wikiJS_submenuContainer_ul.className = 'wds-list wds-is-linked'; for (i = 0; i < wikiJSName.length; i++) { wikiJS_submenu_a = document.createElement('a'); wikiJS_submenu_a.href = '/wiki/MediaWiki:' + wikiJSName[i] + '.js'; wikiJS_submenu_a.id = 'Wiki_' + wikiJSName[i] + '_JS'; wikiJS_submenu_a.innerHTML = wikiJSName[i] + ' JS'; wikiJS_submenu_li = document.createElement('li'); wikiJS_submenu_li.appendChild(wikiJS_submenu_a); wikiJS_submenuContainer_ul.appendChild(wikiJS_submenu_li); }   var wikiJS_submenuContainer_div = document.createElement('div'); wikiJS_submenuContainer_div.className = 'wds-is-not-scrollable wds-dropdown-level-2__content'; wikiJS_submenuContainer_div.appendChild(wikiJS_submenuContainer_ul); //Creating Wiki JS Menu var wikiJS_menu_a = document.createElement('a'); wikiJS_menu_a.href = '#'; wikiJS_menu_a.id = 'Wiki_JS'; wikiJS_menu_a.innerHTML = 'Wiki JS'; var wikiJS_menu_li = document.createElement('li'); wikiJS_menu_li.className = 'wds-dropdown-level-2 is-calculated css-js_pages_li'; wikiJS_menu_li.appendChild(wikiJS_menu_a); wikiJS_menu_li.appendChild(wikiJS_submenuContainer_div); //Adding the New Menus to the List var wikiToolsDropdown = document.querySelectorAll('.wiki-tools .wds-dropdown__content>ul.wds-list'); for (i = 0; i < wikiToolsDropdown.length; i++) { wikiToolsDropdown[i].appendChild(personalCSS_menu_li); wikiToolsDropdown[i].appendChild(personalJS_menu_li); wikiToolsDropdown[i].appendChild(wikiCSS_menu_li); wikiToolsDropdown[i].appendChild(wikiJS_menu_li); } //Styling the Menus var cssjsPageMenus_li = document.getElementsByClassName('css-js_pages_li'); var cssjsPageMenus_a = document.querySelectorAll('.wds-dropdown__content .css-js_pages_li>a'); var cssjsPageSubMenus_div = document.querySelectorAll('.css-js_pages_li>div.wds-dropdown-level-2__content'); for (i = 0; i < cssjsPageMenus_li.length; i++) { cssjsPageMenus_li[i].style.marginRight = '9px'; cssjsPageMenus_li[i].style.marginLeft = '0'; cssjsPageMenus_a[i].style.paddingLeft = '19px'; cssjsPageSubMenus_div[i].style.left = 'inherit'; cssjsPageSubMenus_div[i].style.right = '100%'; } });