User:Ursuul/global.js

///////////////////////////////////////////////////////////////////////// /****************************** Functions ******************************/ ///////////////////////////////////////////////////////////////////////// /* * @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*/

/* FindAndReplace */ var cvCaseSensitive = 'checked';//End FAR*/

/* Mass Effect Configs */ batchDeleteDelay = 10;//revert to 250 massCategorizationDelay = 250; massProtectDelay = 10;//revert to 250 massRedirectDelay = 500; massRenameDelay = 500; massRenameSummary = 'Automatic Process'; nullEditDelay = 10;//revert to 250 WHAMDelay = 250; //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.2.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:CodeQuickLinks/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:MassEdit/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:QuickLogs/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:ToggleSideBar/code.js', 'u:dev:UnhideUserMasthead/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.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' ] });//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*/