User:MACH-59330/global.js

// global imports importArticles({   type: 'script',    articles: [        // 'u:de.trollocool:VanguardTools.js',        // 'u:dev:PortableCSSPad/code.js',        //  using these in Tampermonkey for quick toggling        'u:dev:DiscussionsFeed.js',        'u:dev:SkinSwitchButton/code.js',        'u:dev:Colors/code.js' //Monobook dark wiki class    ] });

// global header recolor $(function {   if ($('.wds-global-navigation').length) {        $('.wds-global-navigation').css('background-color', wgSassParams['color-buttons']);    }    if ($('.pph-wiki-header').length) {        $('.pph-wiki-header').css('box-shadow', 'inset 15px 15px 20px 0' + wgSassParams['color-buttons']);    } });

// global footer recolor $(function {   if ($('.wds-global-footer').length) {        $('.wds-global-footer').css('background-color', wgSassParams['color-buttons']);    } });

// source editor recolor $(function {   if ($('.skin-oasis.editor').length) {        $('.wds-global-navigation,.EditPageHeader').css('background-color', wgSassParams['color-buttons']);        $('.WikiaPage').css('border-color', wgSassParams['color-buttons']);        $('.EditPage .module > h3').css('background', wgSassParams['color-buttons']);    } });

// dark theme deluminator $(function {   if ($('#deluminate_fullscreen_workaround').length) {        $('.skin-oasis.oasis-dark-theme').prevAll("#deluminate_fullscreen_workaround").addClass("inverted");        $('.skin-monobook.page-dark').prevAll("#deluminate_fullscreen_workaround").addClass("inverted");    } });

// global chat-specific JS, by KockaAdmiralac if (mw.config.get('wgCityId') !== '177') { $('a[href="/wiki/Special:Chat"], .chat-join button').click(function(e) {   e.preventDefault;        var cw = window.open('/wiki/Special:Chat?useskin=oasis');        cw.onload = function {            cw.importScriptPage('Special:MyPage/chat.js', 'c');       }    }); }