User:Δ/monobook.js
Appearance
< User:Δ
Code that you insert on this page could contain malicious content capable of compromising your account. If you import a script from another page with "importScript", "mw.loader.load", "iusc", or "lusc", take note that this causes you to dynamically load a remote script, which could be changed by others. Editors are responsible for all edits and actions they perform, including by scripts. User scripts are not centrally supported and may malfunction or become inoperable due to software changes. A guide to help you find broken scripts is available. If you are unsure whether code you are adding to this page is safe, you can ask at the appropriate village pump. This code will be executed when previewing this page. |
![]() | The accompanying .css page for this skin is at User:Δ/monobook.css. |
if (wgNamespaceNumber==0) mw.util.addPortletLink('p-cactions', 'http://toolserver.org/~betacommand/cgi-bin/sandbox?page=' + encodeURIComponent(mw.config.get('wgPageName'))+'&nr=True&min=True', 'NR');
if (wgNamespaceNumber==1) mw.util.addPortletLink('p-cactions', 'http://toolserver.org/~betacommand/cgi-bin/tag?page=' + encodeURIComponent(mw.config.get('wgPageName'))+'&ou=True', 'ou');
importScript('User:Δ/NFCC.js');
addOnloadHook(function() {
var item = addPortletLink('p-cactions','','βsocks','ca-betasocks','Check socks with Betacommand\'s tool','',null);
var link=item.firstChild;
link.onclick = function() {
jsMsg('<form action="http://tools.wikimedia.de/~betacommand/cgi-bin/compare">'+
'<table>' +
'<tr><th>Master<\/th><td><input name="master"><\/td><\/tr>' +
'<tr><th>Socks<\/th><td><input name="socks"><\/td><\/tr>' +
'<tr><th>Key<\/th><td><input name="key"><\/td><\/tr>' +
'<tr><th>Print<\/th><td><input name="Print"><\/td><\/tr>' +
'<tr><td colspan="2"><input type="submit"><\/td><\/tr><\/table>'+'<\/form>','betasocks');
return false;
};
});
importScript('User:Δ/Common.js');
importScript('User:Δ/Spam.js'); // Blog removal
importScript('User:AWeenieMan/furme.js');
importScriptURI('http://ru.wikipedia.org/w/index.php?title=MediaWiki:Gadget-markblocked.js&action=raw&ctype=text/javascript');
// background color of preview box
var previewBackground = '#ffffdd';
// loads the editor
importScript('User:Cacycle/editor.js');
importScript('User:AzaToth/twinkle.js');
if( typeof( TwinkleConfig ) == 'undefined' ) TwinkleConfig = {}; // DO NOT REMOVE THIS LINE - ALL TWINKLE SETTINGS AFTER THIS
TwinkleConfig.batchdeleteChunks = 50;
TwinkleConfig.batchDeleteMinCutOff = 5;
TwinkleConfig.batchMax = 5000;
TwinkleConfig.batchProtectChunks = 50;
TwinkleConfig.batchProtectMinCutOff = 5;
TwinkleConfig.batchundeleteChunks = 50;
TwinkleConfig.batchUndeleteMinCutOff = 5;
TwinkleConfig.blankTalkpageOnIndefBlock = false;
TwinkleConfig.defaultWarningGroup = 1;
TwinkleConfig.deleteTalkPageOnDelete = false;
TwinkleConfig.deletionSummaryAd = '';
TwinkleConfig.deliChunks = 500;
TwinkleConfig.deliMax = 5000;
TwinkleConfig.markAIVReportAsMinor = true;
TwinkleConfig.markSockReportAsMinor = true;
TwinkleConfig.markUAAReportAsMinor = true;
TwinkleConfig.markRevertedPagesAsMinor = [ 'vand' ];
TwinkleConfig.markSpeedyPagesAsMinor = false;
TwinkleConfig.markSpeedyPagesAsPatrolled = true;
TwinkleConfig.notifyUserOnDeli = false;
TwinkleConfig.notifyUserOnSpeedyDeletionNomination = [ 'g1', 'g2', 'g3', 'g4', 'g10', 'g11', 'g12', 'a1', 'a2', 'a3', 'a5', 'a7', 'a9', 'f1', 'f2', 'f3', 'f4', 'f5', 'f6', 'f7', 'f9', 'f10', 'f11', 'u3', 't2', 't3', 'p2' ];
TwinkleConfig.offerReasonOnNormalRevert = false;
TwinkleConfig.openTalkPage = [ 'agf', 'norm', 'vand' ];
TwinkleConfig.openTalkPageOnAutoRevert = false;
TwinkleConfig.openUserTalkPageOnSpeedyDelete = [ 'g1', 'g2', 'g3', 'g4', 'g5', 'g10', 'g11', 'g12', 'a1', 'a3', 'a7', 'a9', 'f3', 'f4', 'f5', 'f6', 'f7', 'f9', 'f11', 'u3', 't2' ];
TwinkleConfig.orphanBacklinksOnSpeedyDelete = {exclude:['g6'], orphan:true};
TwinkleConfig.proddeleteChunks = 50;
TwinkleConfig.prodReasonDefault = "";
TwinkleConfig.protectionSummaryAd = '';
TwinkleConfig.revertMaxRevisions = 50;
TwinkleConfig.showRollbackLinks = [ 'diff'];
TwinkleConfig.showSharedIPNotice = false;
TwinkleConfig.speedyWindowHeight = 500;
TwinkleConfig.speedyWindowWidth = 800;
TwinkleConfig.summaryAd = '';
TwinkleConfig.unlinkNamespaces = [ 0, 100 ];
TwinkleConfig.userTalkPageMode = 'window';
TwinkleConfig.watchProdPages = true;
TwinkleConfig.watchRevertedPages = [ 'agf', 'norm', 'vand', 'torev' ];
TwinkleConfig.watchSpeedyPages = [ 'g3', 'g5', 'g10', 'g11', 'g12', 't1' ];
TwinkleConfig.watchWarnings = true;
TwinkleConfig.welcomeUserOnSpeedyDeletionNotification = TwinkleConfig.notifyUserOnSpeedyDeletionNomination;
TwinkleConfig.xfdWatchDiscussion = "default";
TwinkleConfig.xfdWatchList = "no";
TwinkleConfig.xfdWatchPage = "default";
TwinkleConfig.xfdWatchUsages = "no";
TwinkleConfig.xfdWatchUser = "default";
// Live Preview ([[User:Pilaf/Live Preview]], )
wpUserName = 'Cacycle'; // User name to display in signatures
wpShowImages = true; // Enable downloading and displaying of images
importScript('User:Pilaf/livepreview.js');
window.onload = Main;
// installs the editor and other tools after loading the page
function Main() {
SetupEditor();
// othertools();
}
//////////////////////////////////////////
importScript('User:Δ/GeorgeMoney.js'); // GeorgeMoney
importScript('User:Δ/Sandbox.js'); // js sandbox
importScript('User:Quarl/util.js'); // Utility functions
importScript('User:Quarl/wikipage.js'); // WikiPage class
importScript('User:Quarl/wikiedit.js'); // WikiEditor
importScript('User:Quarl/diff.js'); // WikiEditor
importScript('User:Quarl/cookie.js'); // cookie helpers
importScript('User:Quarl/shortcuts.js'); // Shortcuts class
importScript('User:Δ/Personaltoolbox.js'); // Personal toolbox
importScript('User:Cactus.man/Scripts/ChangeTitles.js'); // New personal menu & tab titles
importScript('User:Cactus.man/Scripts/Time.js'); // Add date and time to the personal menu
//************
popupShortcutKeys=true; // optional: enable keyboard shortcuts
popupAdminLinks=true; // optional: enable admin links
popupSubpopups=true;
popupFixDabs=true;
popupFixRedits=true;
//END
//************
importScript('User:Gary King/show upload deletion logs.js');
//<nowiki> Helper tools
importScript('User:Δ/Addtabs/monobook.js');
//</nowiki>
// include comfortable javascript editor by cacycle
// levels of undo (each level holds the whole text)
var undoBufferMax = 20;
// text and popup title of summary buttons
var summaryButtons = [
['Copyedit', 'Copyedit'],
['Linkfix', 'Linkfix'],
['Vandal', 'Reverting vandalism'],
['Format', 'Formatting source text'],
['NFCC','remove Non-free images, reverting these is considered copyright violation and you will be blocked'],
['Cap lists', 'Capitalizing (link) lists as per [[Wikipedia:List]] and [[Wikipedia:Manual_of_Style]]']
];
// background color of preview box
var previewBackground = '#ffffdd';
// loads the editor
importScript('User:Cacycle/editor.js');
// Live Preview ([[User:Pilaf/Live Preview]], )
wpUserName = 'Cacycle'; // User name to display in signatures
wpShowImages = true; // Enable downloading and displaying of images
importScript('User:Pilaf/livepreview.js');
window.onload = Main;
// installs the editor and other tools after loading the page
function Main() {
SetupEditor();
// othertools();
}
//
//---------------------------------------------------------------
//Toolbox links
function changelinks() {
if(!document.getElementById) return;
document.getElementById('pt-mytalk').firstChild.innerHTML = 'Talk';
document.getElementById('pt-preferences').firstChild.innerHTML = 'Preferences';
document.getElementById('pt-watchlist').firstChild.innerHTML = 'Watchlist';
document.getElementById('pt-mycontris').firstChild.innerHTML = 'Contributions';
document.getElementById('pt-logout').firstChild.innerHTML = 'Log out';
}
function addtoolboxlinks() {
var tb = document.getElementById('p-tb').getElementsByTagName('ul')[0];
addlilink(tb, '/wiki/Wikipedia:Categories_for_deletion/Working', 'WP:CFD/W', '');
addlilink(tb, '/wiki/Wikipedia:Bots/Requests for approval', 'WP:B/RFA', '');
addlilink(tb, '/wiki/Wikipedia:Bot_requests', 'Bot Request', '');
addlilink(tb, '/wiki/User_Talk:Δbot', 'ΔBot', '');
addlilink(tb, '/wiki/WP:ANI', 'ANI', '');
addlilink(tb, '/wiki/WP:AN', 'AN', '');
}
//END
//************
//Editing options
//************
//Toolbar links
function InsertButtonsToToolBar()
{
tooly = document.getElementById('toolbar');
if (tooly != null)
{
StrikeTextButton = "<a href=\"javascript:insertTags('<s>','</s>','Insert text here');\"><img src=\"/media/wikipedia/en/c/c9/Button_strike.png\" alt=\"Strike\" title=\"Strike-through text\"></a>";
LeftTexttButton = "<a href=\"javascript:insertTags('<div style="text-align: left; direction: ltr; margin-left: 1em;">\\n','\\n</div>','Left-aligned text');\"><img src=\"/media/wikipedia/en/e/ea/Button_align_left.png\" alt=\"Left-align\" title=\"Left-aligned text\"></a>";
CenterTextButton = "<a href=\"javascript:insertTags('<div style="text-align: center;">','</div>','Centered text');\"><img src=\"/media/wikipedia/en/5/5f/Button_center.png\" alt=\"Centered\" title=\"Centered text\"></a>";
TableButton = "<a href=\"javascript:insertTags('\\n{| border="1" \\n|- \\n| 1 || 2\\n|- \\n| 3 || 4','\\n|}\\n','');\"><img src=\"/media/wikipedia/en/6/60/Button_insert_table.png\" alt=\"Table\" title=\"Insert table\"></a>";
EenterButton = "<a href=\"javascript:insertTags('<br />','','');\"><img src=\"/media/wikipedia/en/1/13/Button_enter.png\" alt=\"Break\" title=\"Line break\"></a>";
UpperTextButton = "<a href=\"javascript:insertTags('<sup>','</sup>','Superscript');\"><img src=\"/media/wikipedia/en/8/80/Button_upper_letter.png\" alt=\"Superscript\" title=\"Superscript text\"></a>";
LowerTextlButton = "<a href=\"javascript:insertTags('<sub>','</sub>','Subscript');\"><img src=\"/media/wikipedia/en/7/70/Button_lower_letter.png\" alt=\"Subscript\" title=\"Subscript text\"></a>";
SmallTextButton = "<a href=\"javascript:insertTags('<small>','</small>','Small text');\"><img src=\"/media/wikipedia/en/5/58/Button_small.png\" alt=\"Small\" title=\"Small text\"></a>";
CommentButton = "<a href=\"javascript:insertTags('<!--','-->','Comment here');\"><img src=\"/media/wikipedia/en/3/34/Button_hide_comment.png\" alt=\"Comment\" title=\"Insert hidden comment\"></a>";
GalleryButton = "<a href=\"javascript:insertTags('\\n<gallery>\\n','\\n</gallery>','Image:FileName.jpg|Caption1\\Image:FileName2.jpg|Caption2');\"><img src=\"/media/wikipedia/en/1/12/Button_gallery.png\" alt=\"Gallery\" title=\"Insert a picture gallery\"></a>";
SecondaryHeadlineButton = "<a href=\"javascript:insertTags('\\n===','===','Secondary headline');\"><img src=\"/media/wikipedia/en/e/e9/Button_headline2.png\" alt=\"2nd header\" title=\"Insert secondary headline\"></a>";
ShiftingButton = "<a href=\"javascript:insertTags(':','',':');\"><img src=\"/media/wikipedia/en/8/8e/Button_shifting.png\" alt=\"Tab\" title=\"Insert tab(s)\"></a>";
BlockQuoteButton = "<a href=\"javascript:insertTags('<blockquote style="border: 1px solid blue; padding: 2em;">\\n','\\n</blockquote>','Block quote');\"><img src=\"/media/wikipedia/en/f/fd/Button_blockquote.png\" alt=\"Block quote\" title=\"Insert block of quoted text\"></a>";
FontColorButton = "<a href=\"javascript:insertTags('<span style="color: ColorName">','</span>','Span of text');\"><img src=\"/media/wikipedia/en/1/1e/Button_font_color.png\" alt=\"Color\" title=\"Insert colored text\"></a>";
CodeButton = "<a href=\"javascript:insertTags('<code>','</code>','Code');\"><img src=\"/media/wikipedia/en/2/23/Button_code.png\" alt=\"Code\" title=\"Insert code\"></a>";
SubLinkButton = "<a href=\"javascript:insertTags('[[Page#',']]','Sub_page');\"><img src=\"/media/wikipedia/en/9/93/Button_sub_link.png\" alt=\"sub-page link\" title=\"Insert link to sub-page\"></a>";
DefinitionListCodeButton = "<a href=\"javascript:insertTags('\\n; ',' : ','Insert text');\"><img src=\"/media/wikipedia/en/d/d3/Button_definition_list.png\" alt=\"Definition\" title=\"Insert definition list\"></a>";
tooly.innerHTML = tooly.innerHTML + StrikeTextButton + LeftTexttButton + CenterTextButton + TableButton + EenterButton + UpperTextButton + LowerTextlButton + SmallTextButton + CommentButton + GalleryButton + SecondaryHeadlineButton + ShiftingButton + BlockQuoteButton + FontColorButton + CodeButton + SubLinkButton + DefinitionListCodeButton;
}
}
//END
//************
//************
//MAIN
addOnloadHook(Mainfast)
window.onload = Main;
function Main()
{
InsertButtonsToToolBar();
addtoplink();
}
//END
//************
//</nowiki>[[Category:Wikipedians who use VoA script ]]