User:Nanaki/global.js

/* "Create user page" content override */ qtUserPageTemplate = '';

PurgeButtonText = 'Odśwież';

ThreadInspection = { reviewAll: "Przejrzyj wszystkie wiadomości", reviewTitle: "Kliknij aby zobaczyć tą wiadomość", quickLinks: { viewText: "z", viewTitle: "Zobacz", editText: "e", editTitle: "Edytuj", deleteText: "u", deleteTitle: "Usuń", } }; nullEditDelay = 1000;

importArticles({   type: "script",    articles: [      "u:dev:WHAM/code.js",      "u:dev:AjaxBatchDelete/code.2.js",      "u:dev:RevealAnonIP/usercode.js",      "u:dev:RelatedDiscussionsModule/code.js",      "u:dev:PurgeButton/code.js",      "u:dev:PersistentParameters/code.js",      "u:dev:Thread Inspection/code.js",      "u:dev:LuaError/code.js",      'u:dev:PortableCSSPad/code.js',      'u:dev:AjaxRC.js',      'u:dev:MassNullEdit/code.js',    ] });

/* RC in On the Wiki nav */ $(function {   var wa = $('.subnav-2a[data-canonical="wikiactivity"]').parent;    wa.clone.insertBefore(wa).find('>a').attr('href', '/wiki/Special:RecentChanges').attr('data-canonical', 'recentchanges').text('Ostatnie zmiany'); });

/* Makes the Lua console auto scroll to bottom on textarea focus */ $(function {   setTimeout(function { $('#mw-scribunto-input').focus(function {           $('#mw-scribunto-output').scrollTop($('#mw-scribunto-output')[0].scrollHeight);        }); }, 5000); });

/* Fix for submit on 'Enter' in Special:CreatePage/Special:CreateBlogPage title input */ $('.mw-special-CreatePage input[name=wpTitle], .mw-special-CreateBlogPage input[name=wpTitle]').keydown(function(e){   if (e.keyCode == 13) {        $('#ok').click;        e.preventDefault;    } });

/* Link to my and bot's contribs */ $('#AccountNavigation ul.user-menu li:has(a[data-id="mytalk"])').clone.insertAfter('#AccountNavigation ul.user-menu li:has(a[data-id="mytalk"])').find('>a').attr('data-id', 'mybot').attr('href', '/wiki/Special:Contributions/Nanaki.bot').text('Bot'); $('#AccountNavigation ul.user-menu li:has(a[data-id="mytalk"])').clone.insertAfter('#AccountNavigation ul.user-menu li:has(a[data-id="mytalk"])').find('>a').attr('data-id', 'mycontribs').attr('href', '/wiki/Special:Contributions/Nanaki').text('Wkład');