User:Ursuul/global.js

///////////////////////////////////////////////////////////////////////// /***********************************************************************/ /****************************** Functions ******************************/ /***********************************************************************/ ///////////////////////////////////////////////////////////////////////// /* * @name:  Upload File Button * @author: Nanaki * @source: http://c.wikia.com/w/User:Nanaki/global.js */ $(function {   var newpage = $('.wds-community-header__wiki-buttons a[data-tracking="add-new-page"]');    newpage.clone.attr({href: '/wiki/Special:Upload', title: 'Upload File', 'data-tracking': 'upload'}).insertAfter(newpage)        .find('svg').attr('id', '').html('<path d="M 8.984375 0.98632812 A 1.0001 1.0001 0 0 0 8.203125 1.3828125 L 4.2929688 5.2929688 A 1.0001 1.0001 0 1 0 5.7070312 6.7070312 L 8 4.4140625 L 8 12 A 1.0001 1.0001 0 1 0 10 12 L 10 4.4140625 L 12.292969 6.7070312 A 1.0001 1.0001 0 1 0 13.707031 5.2929688 L 9.7910156 1.3769531 A 1.0001 1.0001 0 0 0 8.984375 0.98632812 z M 2.984375 10.986328 A 1.0001 1.0001 0 0 0 2 12 L 2 16 A 1.0001 1.0001 0 0 0 3 17 L 15 17 A 1.0001 1.0001 0 0 0 16 16 L 16 12 A 1.0001 1.0001 0 1 0 14 12 L 14 15 L 4 15 L 4 12 A 1.0001 1.0001 0 0 0 2.984375 10.986328 z "> '); });//End UFB*/

/* * @name:  Kill Infobox Builder * @author: Eizen * @source: http://c.wikia.com/w/User:Eizen/global.js */ if (mw.config.get("wgCanonicalSpecialPageName") === "InfoboxBuilder") { var $pageName = "Template:" + mw.config.get("wgPageName").split("/")[1] + "?action=edit&useeditor=source"; window.location.href = mw.config.get("wgArticlePath").replace("$1", $pageName); }//End KIB*/

///////////////////////////////////////////////////////////////////////// /***********************************************************************/ /************************ Import Configurations ************************/ /***********************************************************************/ ///////////////////////////////////////////////////////////////////////// /* SeeMoreActivity */ window.SeeMoreActivityButtonRC = true;//End SMA*/

/* Back to Top Button */ window.BackToTopStart = 400; window.BackToTopSpeed = 1500;//End BtTB*/

/* Talk Notifications * window.talkWikis = ['diepio', 'zh.diepio', 'rings-of-the-master', 'chilly-and-the-gangs-random-stuff'];//End TN*/

/* Skin Switch */ window.oasisText = "Switch to Oasis"; window.mobileText = "Switch to Mercury"; window.monoBookText = "Switch to Monobook";//End SS*/

/* RevealAnonIP */ window.RevealAnonIP = { permissions : ['user'] };//End RAIP*/

/* WAM Rail */ window.railWAM = { load: true };//End WR*/

/* Mass Effect Configs */ batchDeleteDelay = 10;//revert to 250 massCategorizationDelay = 500; massProtectDelay = 10;//revert to 250 massRedirectDelay = 500; massRenameDelay = 500; massRenameSummary = 'Automatic Process'; nullEditDelay = 10;//revert to 250 WHAMDelay = 500; //End MEC*/

/* Reorder SUG */ function ShowUserGroups_sorter(a, b) { var PredeterminedOrder = { 'staff':                      -100, 'util':                        -99, 'restricted-login':            -98, 'restricted-login-auto':       -97, 'restricted-login-exempt':     -96, 'devboxpanel':                 -95, 'translator':                  -94, 'content-reviewer':            -93, 'lookupuser':                  -92, 'lookupcontribs':              -91, 'helper':                      -80, 'vstf':                        -70, 'global-discussions-moderator': -60, 'voldev':                      -50, 'vanguard':                    -40, 'council':                     -30, 'authenticated':               -20, 'fandom-editor':               -10, 'bot-global':                    0, 'bot':                          10, 'codeadmin':                    20, 'checkuser':                    30, 'bureaucrat':                   40, 'sysop':                        50, 'content-moderator':            60, 'threadmoderator':              70, 'chatmoderator':                80, 'rollback':                     90, 'poweruser':                   110, 'autoconfirmed':               120 };   var sortA = typeof PredeterminedOrder[a] === "number" ? PredeterminedOrder[a] : 100;   var sortB = typeof PredeterminedOrder[b] === "number" ? PredeterminedOrder[b] : 100;   return sortA - sortB; }//End RSUG*/

///////////////////////////////////////////////////////////////////////// /***********************************************************************/ /******************************* Imports *******************************/ /***********************************************************************/ ///////////////////////////////////////////////////////////////////////// /* Universal Imports */ importArticles({   type: 'script',    articles: [        'u:dev:AdminDashboard JS-Button/code.js',        'u:dev:AjaxBatchDelete/code.js',        'u:dev:AjaxRedirect/code.js',        'u:dev:AjaxUndo/code.js',        'u:dev:AllPagesHideRedirect/code.js',        'u:dev:AnchoredRollback/code.js',        'u:dev:AntiSoundcloud/code.js',        'u:dev:AutoEditPages/code.js',        'u:dev:BlankBlogBugfix/code.js',        'u:dev:BlogLink/code.js',        'u:dev:CleanWantedFiles/code.js',        'u:dev:DiscussionsFeed.js',        'u:dev:EditConflictAlert/code.js',        'u:dev:FindAndReplace/code.js',        'u:dev:Linksweeper/code.js',        'u:dev:MarkBlocked.js',        'u:dev:MassCategorization/code.js',        'u:dev:MassNullEdit/code.js',        'u:dev:MassProtect/code.js',        'u:dev:MassRedirect/code.1.js',        'u:dev:MassRename/code.js',        'u:dev:MassRenameRevert/code.js', 'u:dev:MassUserRights/code.js', 'u:dev:MultipleFileDelete/code.js', 'u:dev:NullEditButton/code.js', 'u:dev:PortableCSSPad/code.js', //'u:dev:PurgeButton/code.js', //'u:dev:RTCL.js', 'u:dev:RedirectManagement/code.js', 'u:dev:ReferencePopups/code.js', 'u:dev:Rollback/code.js', 'u:dev:SearchSuggest/code.js', 'u:dev:SeeMoreActivityButton/code.js', 'u:dev:ShowUserGroups.js', 'u:dev:SkinSwitchButton/code.js', 'u:dev:Thread Inspection/code.js', 'u:dev:UnhideUserMasthead/code.js', 'u:dev:UserActivityTab/code.js', 'u:dev:UserCheck/code.js', 'u:dev:UserRightsRecord/code.js', //'u:dev:UserTalkNotifications/code.js', 'u:dev:WHAM/code.2.js', 'u:dev:WallGreetingButton/code.js', 'u:dev:Wikimarks/code.js', 'u:dev:WorkingMoreUsersCount.js', 'u:diepio:Miscellaneous/code.js', 'u:eizen:User:Eizen/AnonLookup.javascript', 'u:kocka:VSTFReport/code.js', 'u:tes:Common.js/DiscussionsLinks.js', 'u:ursuul:User:Ursuul/AutoEditDropdown.javascript', 'u:ursuul:User:Ursuul/MastheadGender.javascript', 'u:ursuul:Vanguard.js' ] });//End UI*/

/* Community Council specific imports */ $(function {    var config = mw.config.get([ "wgCityId", "wgServer" ]);   if ( config.wgCityId === "193260" && config.wgServer === "http://communitycouncil.wikia.com" ) {       importArticles( {// Stylesheets type: "style", articles: [ "u:c:User:Ursuul/common.css", "u:c:User:Ursuul/wikia.css" ]           },            {// Scripts type: "script", articles: [ "u:dev:BackToTopButton/code.js" ]           }        );    } });//End CCSI*/