User:Danhash/common.js: Difference between revisions
Appearance
Content deleted Content added
wikEd customization |
trying something else |
||
Line 53: | Line 53: | ||
importScript('User:Cacycle/wikEd.js'); |
importScript('User:Cacycle/wikEd.js'); |
||
var wikEdConfig = {}; |
var wikEdConfig = {}; |
||
wikEdConfig. |
wikEdConfig.showSourceButton = true; |
||
wikEdConfig.regExTypoFix = true; |
wikEdConfig.regExTypoFix = true; |
||
Revision as of 18:55, 26 January 2012
/*
==Misc. script imports==
*/
importScript("User:Smith609/refsByName.js");
importScript("User:Smith609/toolbox.js");
importScript('User:AzaToth/twinkle.js'); //install twinkle
//importScript("User:Fred_Gandt/sectionLinks.js");
importScript('User:Bility/copySectionLink.js');
importScript('User:Ale_jrb/Scripts/userhist.js'); //[[User:Ale_jrb/Scripts]]
// Add [[WP:Reflinks]] launcher in the toolbox on left; from [[User:Dispenser/Reflinks#User_script]]
/*
addOnloadHook(function () {
addPortletLink(
"p-tb", // toolbox portlet
"http://toolserver.org/~dispenser/cgi-bin/webreflinks.py/" + wgPageName
+ "?client=script&citeweb=on&overwrite=&limit=20&lang=" + wgContentLanguage,
"Reflinks" // link label
)});
*/
addOnloadHook(function () {
addPortletLink(
"p-tb", // toolbox portlet
"http://en.wikipedia.org/wiki/Special:NewPages",
"New Pages" // link label
)});
addOnloadHook(function () {
addPortletLink(
"p-tb", // toolbox portlet
"http://en.wikipedia.org/w/index.php?title=User:Danhash/common.js&action=edit",
"edit common.js" // link label
)});
/*
==[[User:Js]] stuff==
*/
if( wgPageName == 'User:Js' ) importScript('user:js/tools.js')
dfNoPopups=true; //disable diff popups
//importScript('user:js/diffs.js'); commented out until diff popups can be disabled
/*if (wgCanonicalSpecialPageName == 'Watchlist')
importScript('user:js/watchlist.js');*/
/*
END [[User:Js]] stuff
*/
/*
==wikEd==
*/
importScript('User:Cacycle/wikEd.js');
var wikEdConfig = {};
wikEdConfig.showSourceButton = true;
wikEdConfig.regExTypoFix = true;
/*
===Default edit summaries===
*/
wikEdConfig.comboPresetOptions = {};
wikEdConfig.comboPresetOptions.summary = [
'single to double [[WP:MOS#Quotation marks|quotation marks]]',
'curly to straight [[WP:MOS#Quotation marks|quotation marks]]',
'fix [[WP:MOS#Quotation marks|quotation marks]]',
'fix [[MOS:DASH|dashes]]',
'[[WP:REFPUNC]]',
'rewrite [[WP:MOS#Contractions|contractions]]',
'[[WP:WEASEL|weasel words]]',
'fix [[Wikipedia:Double redirects|double redirect]] after page move',
'update [[WP:DEFAULTSORT|DEFAULTSORT]]',
'{{[[WP:Citation Needed|citation needed]]}}',
'rm extra [[WP:WHITE|whitespace]]',
'copyedit',
'rm unsourced',
'rm spam',
'rm red links',
'update links',
'fix links',
'Cleaned up using [[WP:AutoEd|AutoEd]]',
'[[Wikipedia:RegExTypoFix|RegExTypoFix]] using [[User:Cacycle/wikEd|wikEd]]',
'(using [[User:Cacycle/wikEd|wikEd]])',
'edit wikEd RegEx defaults',
'edit wikEd edit summaries'
];
/*
===Find/replace regex presets===
*/
wikEdConfig.comboPresetOptions.find = [ '(“|”)', "(‘|’)", '\'', '-', ' – ' ];
wikEdConfig.comboPresetOptions.replace = [ '\n', '"', '\'', '–'];
/*
===Other configuration===
*/
//enable show source button
//button to append wikEd plug
wikEdConfig.showUsingButton = true;
wikEdConfig.summaryUsing = '(using [[User:Cacycle/wikEd|wikEd]])';
/* END wikEd */
/*
== AutoEd ==
=== AutoEd modules ===
*/
importScript('Wikipedia:AutoEd/core.js');
importScript('Wikipedia:AutoEd/fullwidth.js');
importScript('Wikipedia:AutoEd/headlines.js');
importScript('Wikipedia:AutoEd/htmltowikitext.js');
importScript('Wikipedia:AutoEd/isbn.js');
importScript('Wikipedia:AutoEd/links.js');
importScript('Wikipedia:AutoEd/templates.js');
importScript('Wikipedia:AutoEd/unicodecontrolchars.js');
importScript('Wikipedia:AutoEd/unicodehex.js');
importScript('Wikipedia:AutoEd/unicodify.js');
importScript('Wikipedia:AutoEd/wikilinks.js');
//importScript('Wikipedia:AutoEd/dashes.js');
//importScript("User:GregU/dashes.js");
//importScript('Wikipedia:AutoEd/extrabreaks.js');
//importScript('Wikipedia:AutoEd/tablestowikitext.js');
//importScript('Wikipedia:AutoEd/whitespace.js');
/*
=== AutoEd functions ===
*/
function autoEdFunctions() { //Activates individual modules when "auto ed" tab is clicked
var txt = document.editform.wpTextbox1;
txt.value = autoEdFullwidth(txt.value);
txt.value = autoEdHeadlines(txt.value);
txt.value = autoEdHTMLtoWikitext(txt.value);
txt.value = autoEdISBN(txt.value);
txt.value = autoEdLinks(txt.value);
txt.value = autoEdTemplates(txt.value);
txt.value = autoEdUnicodeControlChars(txt.value);
txt.value = autoEdUnicodeHex(txt.value);
txt.value = autoEdUnicodify(txt.value);
txt.value = autoEdWikilinks(txt.value);
//txt.value = autoEdDashes(txt.value);
//txt.value = autoEdExtraBreaks(txt.value);
//txt.value = autoEdTablestoWikitext(txt.value);
//txt.value = autoEdWhitespace(txt.value);
}
autoEdClick = false; //for compatibility with wikEd
/* END AutoEd */
/*
==Gary King scripts==
*/
importScript('User:Gary King/comments in local time.js'); // [[User:Gary King/comments in local time.js]]
importScript('User:Gary King/highlight my username in history.js');
importScript('User:Gary_King/contribs_alt_link.js');
importScript('User:Gary_King/mark_edits_after_my_own.js');
importScript('User:Gary_King/mark_todays_edits.js');
importScript('User:Gary_King/mark_unviewed_watchlist_items.js');
//importScript('User:Gary_King/default_summary.js');
importScript('User:Gary_King/link_intermediate_revisions.js');
importScript('User:Gary_King/namespace_redirect.js');
importScript('User:Gary King/nominations viewer.js'); // [[User:Gary King/nominations viewer.js]]
importScript('User:Gary_King/comment_highlighter.js');
importScript('User:Gary_King/minutes_later_for_diff.js');
importScript('User:Gary_King/prose_size.js'); //[[User:Gary_King/prose_size.js]]
/* END Gary King scripts */
/*
==Lupin scripts==
*/
//importScript('User:Lupin/recent2.js');
// [[User:Lupin/popups.js]]
/* var popupModifier = 'shift';
var popupFixRedirs = 'true';
var popupRedlinkRemoval = 'true';
var popupFixDabs = 'true';
var popupDelay = 0.2;
var popupHideDelay = 0.2;
var popupStructure = 'menus';
importScript('User:Lupin/popups.js');
*/
/* END LUPIN SCRIPTS */