User:Anonminati/global.js

window.AutoCreateUserPagesConfig = { content: '', summary: 'Not active here' }; importArticles({   type: 'script',    articles: [        'u:dev:MediaWiki:GlobalEditcount/code.js',        'u:dev:WorkingMoreUsersCount.js',        'u:dev:MediaWiki:RefreshThreads/code.js',        'u:dev:UserAccountAge/code2.js',        'u:dev:AjaxDelete/code.js',        'u:dev:AjaxUndo/code.js',        'u:dev:BlogLink/code.js',        'u:dev:CommentPreview/code.js',        'u:dev:MediaWiki:FindAndReplace/code.js',        'u:dev:MassEdit/code.js',        'u:dev:MobileEditor.js',        'u:dev:ModernLightbox.js',        'u:dev:Nuke/code.js',        'u:dev:UserActivityTab/code.js',        'u:dev:View Source/code.js',        'u:dev:WallGreetingButton/code.js',        'u:dev:NullEditButton/code.js',        'u:dev:PurgeButton/code.js',        'u:dev:SandboxTab/code.js',        'u:dev:SeeMoreActivityButton/code.js',        'u:dev:PortableCSSPad/code.js',        'u:dev:UsernameAvailability/code.js', 'u:dev:RevealAnonIP/code.js', 'u:dev:MediaWiki:MultiUpload/code.js', 'u:dev:MediaWiki:VSTFReport.js', 'u:dev:MediaWiki:MastheadGender/code.js', 'u:anonminati:MediaWiki:UsefulButtonsJS.js', 'u:dev:MediaWiki:HighlightsNotificationBubble/code.js', 'u:dev:MediaWiki:EditBio/code.js', 'u:kocka:User:KockaAdmiralac/AutoCreateUserPages.javascript', 'u:dev:MediaWiki:AjaxRC/code.js', 'u:kocka:ReportFormatter.js' ] }); /* Auto Refresh */ AjaxRCRefreshText = 'Auto-Refresh'; AjaxRCRefreshHoverText = 'Automatically refresh the page'; ajaxPages = ["Special:RecentChanges","Special:WikiActivity"];

/**   *This Script is created by Colouratura * colour.chat *   * Literally exists to hold PM blocking code */ window.colour.chat = { _blockPM: function(user) { return new Promise(function(resolve, reject) {       $.ajax({ url: mw.util.wikiScript('index') + '?action=ajax&rs=ChatAjax&method=blockOrBanChat', type: 'post', dataType: 'json', data: { userToBan: user, dir: 'add', token: mw.user.tokens.get('editToken') }       })          .done(function(res) { if (!res.hasOwnProperty('success')) reject(res); if (res.success === true) resolve(true); else reject(res); })         .fail(function(err, stat) { reject(err, stat); });     });    },    blockPM: function(user) { window.colour.chat._blockPM(user).then(       function {          console.log(user + ' was blocked!');        },        function(err, stat) {          console.error(err, stats);        }      ); } };  /**    * This Script is created by Colouratura * Blocks PMs on user join *   * Please consider, like, leaving me alone */ if (mw.config.get('wgCanonicalSpecialPageName') === 'Chat') { mainRoom.socket.bind('join', function(event) {     var ev = JSON.parse(event.data);      var username = ev.attrs.name;      var whitelist = [        'KockaAdmiralac',        'Sannse',        'Sophiedp',        'Noreplyz',        'Outclaw',        'JustLeafy',        'MythHunter 007',        'TheRogue12',        'The Demon King Finn Balor',        'TheKorraFanatic',        'M67PattonZippo',        'Blake&#039;s Bane'      ];      if (!whitelist.includes(username))        colour.chat.blockPM(username);    }); } window.colour.mw = mw; window.colour.log = log; importArticles({   type: 'script',    articles: [        'u:dev:PortableCSSPad/code.js'    ]  }); log.loaded('COMMUNITY global.js'); })(mediaWiki, jQuery);

/*Above two scripts block pms automatically and created by Colouratura */