User:Mendes2/global.js

window.pageCreatorAvatar = true; window.pageCreatorTimestamp = true; window.pageCreatorUTC = true; window.ajaxSpecialPages = ["Recentchanges", "WikiActivity", "Log"]; window.ajaxRefresh = 25000;

importArticles({   type: 'script',    articles: [        'u:dev:AjaxRC/code.js',        'u:dev:UserAccountAge/code2.js',        'u:dev:LastEdited/code.js',        'u:dev:PageCreator/code2.js',        'u:dev:View Source/code.js',        'u:dev:UserActivityTab/code.js',        'u:dev:MediaWiki:GlobalEditcount/code.js',        'u:dev:PortableCSSPad/code.js'    ] });

/****JS and CSS pages on toolbar****/ var Links = { "/Special:MyPage/common.js": "Personal JS", "/Special:MyPage/chat.js": "Personal Chat JS", "//community.wikia.com/wiki/Special:MyPage/global.js": "Global JS", "//community.wikia.com/wiki/Special:MyPage/global.css": "Global CSS", "/MediaWiki:Common.js": "Wiki JS", "/MediaWiki:Common.css": "Wiki CSS", "/MediaWiki:Chat.js": "Chat JS" };

$.each(Links, function (url, title) {	$("#my-tools-menu").append('' + title + ''); });

/****WhatLinksHere in editor****/ /*******Visual Editor********/ mw.hook('ve.activationComplete').add(function {   $(".ve-init-mw-viewPageTarget-toolbar-actions").append(' WhatLinksHere '); });

/*******Classic Editor*******/ $("#EditPageToolbar").append('WhatLinksHere ');

/****Showing amount of redlinks****/ if(wgNamespaceNumber!=-1) { var p = document.getElementsByClassName('new').length; if(p > 0) { if(document.getElementsByClassName('new')[0].id == 'ca-talk'){ p--; }       if(p > 0) { $(".toolbar .tools").prepend('' + p + ''); }   } }

/****Link to infobox image, mercury, main page****/ var file = $('.pi-image-thumbnail').attr('data-image-key'); if(file) { $(".page-header__contribution-buttons .wds-list.wds-is-linked").append('Infobox image'); } $(".page-header__contribution-buttons .wds-list.wds-is-linked").append('Mobile</a></li>');