Benutzer:Florian Walder/common.js: Unterschied zwischen den Versionen
Aus revampedia
(Änderung 3273 von Florian Walder (Diskussion) rückgängig gemacht.) |
|||
(6 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt) | |||
Zeile 60: | Zeile 60: | ||
// removes [[Special:Upload]] from toolbox | // removes [[Special:Upload]] from toolbox | ||
//ModifySidebar( 'remove', 'toolbox', 'Upload file', 'http://en.wikipedia.org/wiki/Special:Upload' ); | //ModifySidebar( 'remove', 'toolbox', 'Upload file', 'http://en.wikipedia.org/wiki/Special:Upload' ); | ||
− | ModifySidebar( 'add', 'toolbox', ' | + | ModifySidebar( 'add', 'toolbox', 'Edit(forced)', window.location.href + '&action=edit' ); |
} | } | ||
jQuery( CustomizeModificationsOfSidebar ); | jQuery( CustomizeModificationsOfSidebar ); | ||
+ | |||
+ | // Warning! Global gadget file! | ||
+ | ( function ( mw, $ ) { | ||
+ | |||
+ | var $target; | ||
+ | |||
+ | function showTime( $target ) { | ||
+ | var dateNode = UTCLiveClockConfig.node; | ||
+ | if ( !dateNode ) { | ||
+ | return; | ||
+ | } | ||
+ | |||
+ | var now = new Date(); | ||
+ | var hh = now.getUTCHours(); | ||
+ | var mm = now.getUTCMinutes(); | ||
+ | var ss = now.getUTCSeconds(); | ||
+ | if ( $target === undefined ) { | ||
+ | $target = $( dateNode ).find( 'a:first' ); | ||
+ | } | ||
+ | var time = ( hh < 10 ? '0' + hh : hh ) + ':' + ( mm < 10 ? '0' + mm : mm ) + ':' + ( ss < 10 ? '0' + ss : ss ); | ||
+ | $target.text( 'UTC ' + time ); | ||
+ | |||
+ | var ms = now.getUTCMilliseconds(); | ||
+ | |||
+ | setTimeout( function () { | ||
+ | showTime( $target ); | ||
+ | }, 1100 - ms ); | ||
+ | } | ||
+ | |||
+ | function liveClock() { | ||
+ | mw.util.addCSS( '#utcdate a { font-weight:bolder; font-size:120%; }' ); | ||
+ | |||
+ | if ( window.UTCLiveClockConfig === undefined ) { | ||
+ | window.UTCLiveClockConfig = {}; | ||
+ | } | ||
+ | var portletId = UTCLiveClockConfig.portletId || 'p-personal'; | ||
+ | var nextNode = UTCLiveClockConfig.nextNodeId ? document.getElementById( UTCLiveClockConfig.nextNodeId ) : undefined; | ||
+ | UTCLiveClockConfig.node = mw.util.addPortletLink( | ||
+ | portletId, | ||
+ | mw.config.get( 'wgScript' ) + '?title=' + encodeURIComponent( mw.config.get( 'wgPageName' ) ) + '&action=purge', | ||
+ | '', | ||
+ | 'utcdate', | ||
+ | null, | ||
+ | null, | ||
+ | nextNode | ||
+ | ); | ||
+ | if ( !UTCLiveClockConfig.node ) { | ||
+ | return; | ||
+ | } | ||
+ | |||
+ | showTime(); | ||
+ | } | ||
+ | $( document ).ready( liveClock ); | ||
+ | |||
+ | } )( mediaWiki, jQuery ); | ||
+ | mw.loader.load( '//commons.wikimedia.org/w/index.php?title=MediaWiki:Gadget-HotCat.js&action=raw&ctype=text/javascript&smaxage=21600&maxage=86400' ); | ||
+ | // ********************************************************************** | ||
+ | // ** ***WARNING GLOBAL GADGET FILE*** ** | ||
+ | // ** changes to this file affect many users. ** | ||
+ | // ** please discuss on the talk page before editing ** | ||
+ | // ** ** | ||
+ | // ********************************************************************** | ||
+ | // Imported from [[User:Alex Smotrov/edittop.js]], version as of: 2007-06-19T04:28:52 | ||
+ | // Updated from [[User:TheDJ/Gadget-edittop.js]], version as of: 2009-04-28T11:54:22 | ||
+ | // Imported from https://en.wikipedia.org/w/index.php?title=MediaWiki:Gadget-edittop.js&oldid=555020676 on 2013-May-14T13:42:00 | ||
+ | |||
+ | if ($.inArray( mw.config.get('wgAction'), [ 'view', 'purge' ]) !== -1 && mw.config.get( 'wgNamespaceNumber' ) >=0) { | ||
+ | $(function edittop_hook () { | ||
+ | var localtitles = { | ||
+ | cs: 'Editovat úvodní sekci', | ||
+ | en: 'Edit lead section', | ||
+ | fa: 'ویرایش بخش آغازین', | ||
+ | fr: 'Modifier le résumé introductif', | ||
+ | id: 'Sunting bagian atas', | ||
+ | it: 'Modifica della sezione iniziale', | ||
+ | ja: '導入部を編集', | ||
+ | min: 'Suntiang bagian ateh', | ||
+ | ko: '도입부를 편집', | ||
+ | pa: 'ਸੋਧ', | ||
+ | pt: 'Editar a seção superior', | ||
+ | 'pt-br': 'Editar a seção superior', | ||
+ | sr: 'Уреди уводни део', | ||
+ | vi: 'Sửa phần mở đầu' | ||
+ | }; | ||
+ | |||
+ | var our_content = document.getElementById ("content") || document.getElementById ("mw_content") || document.body; | ||
+ | var editspans = getElementsByClassName (our_content, "span", "mw-editsection"); | ||
+ | var span1; | ||
+ | |||
+ | for (var i = 0; editspans && i < editspans.length; i++) { | ||
+ | if (editspans[i].className.indexOf ("plainlinks") == -1) { | ||
+ | span1 = editspans[i]; | ||
+ | break; | ||
+ | } | ||
+ | } | ||
+ | if (!span1) { | ||
+ | return; | ||
+ | } | ||
+ | var span0 = span1.cloneNode (true); | ||
+ | our_content = document.getElementById ("mw_header") || document.getElementById ("content") || document.body; | ||
+ | var parent = our_content.getElementsByTagName ("H1")[0]; | ||
+ | parent.appendChild (span0); | ||
+ | var a = span0.getElementsByTagName ("A")[0]; | ||
+ | if (a.href.indexOf ("§ion=T") == -1) { | ||
+ | a.title = a.title.replace (/(: |:).*$/, "$1" + "0"); | ||
+ | a.setAttribute ("href", a.getAttribute ("href", 2).replace (/§ion=\d+/, "§ion=0")); | ||
+ | } | ||
+ | else { //transcluded | ||
+ | a.title = localtitles[mw.config.get( 'wgUserLanguage' )] || localtitles.en; | ||
+ | a.setAttribute ("href", mw.util.wikiGetlink( mw.config.get( 'wgPageName' ) ) + "?action=edit§ion=0"); | ||
+ | } | ||
+ | }); | ||
+ | } | ||
+ | (function(){"use strict";function a(e){return new RegExp("("+e+")\n*|"+u,"gm")}function E(){function C(e,t){if(w){e=e.replace(/ +/g,"$&")}if(t!=S){g+="'}#s"+b;if(x){g+=":before{";x=false}else{g+=":after{";x=true;++b}if(t){g+="background-color:"+t+";"}g+="content:'";S=t}g+=e}function k(t,n){var r;for(n.lastIndex=u;r=n.exec(e);n.lastIndex=u){if(r[1]){C(e.substring(u,n.lastIndex),t);u=n.lastIndex;return}var i=n.lastIndex-r[0].length;if(u<i){C(e.substring(u,i),t)}u=n.lastIndex;switch(r[0].charAt(0)){case"[":if(r[0].charAt(1)=="["){C("[[",syntaxHighlighterConfig.wikilinkColor||t);k(syntaxHighlighterConfig.wikilinkColor||t,l)}else{C(r[0],syntaxHighlighterConfig.externalLinkColor||t);k(syntaxHighlighterConfig.externalLinkColor||t,c)}break;case"{":if(r[0].charAt(1)=="{"){if(r[0].length==3){C("{{{",syntaxHighlighterConfig.parameterColor||t);k(syntaxHighlighterConfig.parameterColor||t,h)}else{C("{{",syntaxHighlighterConfig.templateColor||t);k(syntaxHighlighterConfig.templateColor||t,p)}}else{C("{|",syntaxHighlighterConfig.tableColor||t);k(syntaxHighlighterConfig.tableColor||t,d)}break;case"<":if(r[0].charAt(1)=="!"){C(r[0],syntaxHighlighterConfig.commentColor||t);break}else{var s=e.indexOf(">",u)+1;if(s==0){C("<",t);u=u-r[0].length+1;break}if(e.charAt(s-2)=="/"){C(e.substring(u-r[0].length,s),syntaxHighlighterConfig.tagColor||t);u=s}else{var o=r[0].substring(1);if(/^(?:nowiki|pre|math|syntaxhighlight|source|timeline|hiero)$/.test(o)){var g="</"+o+">";var y=e.indexOf(g,u);if(y==-1){y=e.length}else{y+=g.length}C(e.substring(u-r[0].length,y),syntaxHighlighterConfig.tagColor||t);u=y}else{C(e.substring(u-r[0].length,s),syntaxHighlighterConfig.tagColor||t);u=s;if(!m[o]){m[o]=a("</"+o+">")}k(syntaxHighlighterConfig.tagColor||t,m[o])}}}break;case"h":case"f":case"m":C(r[0],syntaxHighlighterConfig.externalLinkColor||t);break;case"=":if(/[^=]=+$/.test(e.substring(u,e.indexOf("\n",u)))){C("=",syntaxHighlighterConfig.headingColor||t);k(syntaxHighlighterConfig.headingColor||t,v)}else{C("=",t)}break;case"*":case"#":case":":C(r[0],syntaxHighlighterConfig.listOrIndentColor||t);break;case";":C(";",syntaxHighlighterConfig.headingColor||t);k(syntaxHighlighterConfig.headingColor||t,v);break;case"-":C(r[0],syntaxHighlighterConfig.hrColor||t);break;case"\\":C(r[0],syntaxHighlighterConfig.boldOrItalicColor||t);if(r[0].length==6){if(T){T=false;return}else{T=true;k(syntaxHighlighterConfig.boldOrItalicColor||t,f)}}else{if(N){N=false;return}else{N=true;k(syntaxHighlighterConfig.boldOrItalicColor||t,f)}}break;case"&":C(r[0],syntaxHighlighterConfig.entityColor||t);break;case"~":C(r[0],syntaxHighlighterConfig.signatureColor||t)}}}i=n.value;var e=i.replace(/['\\]/g,"\\$&")+"\n";var u=0;var g="";var b=0;var S;var x=true;var T=false;var N=false;if(y){e+=(new Array(n.scrollWidth)).join(" ")}var L=Date.now();k("",f);if(u<e.length){C(e.substring(u),"")}while(s<b){t.appendChild(document.createElement("span")).id="s"+ ++s}r.nodeValue=g.substring(2).replace(/\n/g,"\\A ")+"'}";var A=Date.now();if(A-L>syntaxHighlighterConfig.timeout){clearInterval(o);r.nodeValue="";n.removeEventListener("input",E);var O={};O["ca"]='S\'ha desactivat el remarcar de sintaxi en aquesta pàgina perquè ha tardat massa. El temps màxim permès per a remarcar és $1ms, i el teu ordinador ha trigat $2ms. Prova tancar algunes pestanyes i programes i fer clic en "Mostra la previsualització" o "Mostra els canvis". Si no funciona això, prova altre navegador web, i si això no funciona, prova un ordinador més ràpid.';O["en"]='Syntax highlighting on this page was disabled because it took too long. The maximum allowed highlighting time is $1ms, and your computer took $2ms. Try closing some tabs and programs and clicking "Show preview" or "Show changes". If that doesn\'t work, try a different web browser, and if that doesn\'t work, try a faster computer.';O["es"]='Se desactivó el resaltar de sintaxis en esta página porque tardó demasiado. El tiempo máximum permitido para resaltar es $1ms, y tu ordenador tardó $2ms. Prueba cerrar algunas pestañas y programas y hacer clic en "Mostrar previsualización" o "Mostrar cambios". Si no funciona esto, prueba otro navegador web, y si eso no funciona, prueba un ordenador más rápido.';O["io"]='Sintaxo-hailaitar en ca pagino esis nekapabligata pro ke konsumis tro multa tempo. La maxima permisata hailaitala tempo es $1ms, e tua ordinatro konsumis $2ms. Probez klozar kelka tabi e programi e kliktar "Previdar" o "Montrez chanji". Se to ne funcionas, probez altra brauzero, e se to ne funcionas, probez plu rapida ordinatro.';O["pt"]='O marcador de sintaxe foi desativado nesta pagina porque demorou demais. O tempo máximo permitido para marcar e $1ms, e seu computador demorou $2ms. Tenta sair de alguns programas e clique em "Mostrar previsão" ou "Mostrar alterações". Se isso não funciona, tenta usar uma outra navegador web, e se ainda não funciona, procura um computador mais rápido.';O=O[wgUserLanguage]||O[wgUserLanguage.substring(0,wgUserLanguage.indexOf("-"))]||O["en"];n.style.backgroundColor="";n.style.position="";t.style.color="red";t.style.fontFamily="";t.style.fontWeight="bold";t.style.height="";var M=document.createRange();M.selectNode(t);t.appendChild(M.createContextualFragment(O.replace("$1",syntaxHighlighterConfig.timeout).replace("$2",A-L)))}}function S(){t.scrollLeft=n.scrollLeft}function x(){t.scrollTop=n.scrollTop}function T(){if(n.value!=i){E()}if(n.scrollLeft!=t.scrollLeft){S()}if(n.scrollTop!=t.scrollTop){x()}}function N(){function i(e,t){if(syntaxHighlighterConfig[e]=="normal"){syntaxHighlighterConfig[e]=t}else if(typeof syntaxHighlighterConfig[e]!="undefined"){return}else if(typeof syntaxHighlighterConfig.defaultColor!="undefined"){syntaxHighlighterConfig[e]=syntaxHighlighterConfig.defaultColor}else{syntaxHighlighterConfig[e]=t}}window.syntaxHighlighterConfig=window.syntaxHighlighterConfig||{};i("boldOrItalicColor","#EEE");i("commentColor","#EFE");i("entityColor","#DFD");i("externalLinkColor","#EFF");i("headingColor","#EEE");i("hrColor","#EEE");i("listOrIndentColor","#EFE");i("parameterColor","#FC6");i("signatureColor","#FC6");i("tagColor","#FEF");i("tableColor","#FFC");i("templateColor","#FFC");i("wikilinkColor","#EEF");syntaxHighlighterConfig.timeout=syntaxHighlighterConfig.timeout||100;e=document.createElement("div");t=document.createElement("div");n=document.getElementById("wpTextbox1");var s=document.createElement("style");s.type="text/css";r=s.appendChild(document.createTextNode(""));t.style.backgroundColor=window.getComputedStyle(n).backgroundColor;if(t.style.backgroundColor=="transparent"){t.style.backgroundColor="white"}t.style.border="1px solid transparent";t.style.boxSizing="border-box";t.style.MozBoxSizing="border-box";t.style.color="transparent";t.style.direction=window.getComputedStyle(n).direction;t.style.fontFamily=window.getComputedStyle(n).fontFamily;t.style.fontSize=window.getComputedStyle(n).fontSize;t.style.lineHeight="normal";t.style.overflowX="auto";t.style.overflowY="scroll";t.style.whiteSpace="pre-wrap";t.style.width="100%";t.style.wordWrap="normal";n.style.backgroundColor="transparent";n.style.border="1px inset gray";n.style.boxSizing="border-box";n.style.MozBoxSizing="border-box";n.style.lineHeight="normal";n.style.margin="0";n.style.overflowX="auto";n.style.overflowY="scroll";n.style.padding="0";n.style.position="absolute";n.style.resize="none";n.style.left="0";n.style.top="0";n.style.width="100%";n.style.wordWrap="normal";t.style.height=n.offsetHeight+"px";n.style.height=t.style.height;if(g){t.style.paddingLeft="1px";t.style.paddingRight="1px"}else if(y){n.style.overflowX="scroll"}e.style.position="relative";n.parentNode.insertBefore(e,n);e.appendChild(n);e.appendChild(t);$(".tool-select *").css({zIndex:5});document.head.appendChild(s);n.addEventListener("input",E);n.addEventListener("scroll",S);n.addEventListener("scroll",x);o=setInterval(T,500);E()}function C(){setTimeout(N,0)}var e;var t;var n;var r;var i;var s=-1;var o;var u="\\[(?:\\[|(?:https?:|ftp:)?//|mailto:)|\\{(?:\\{\\{?|\\|)|<(?:[:A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-⁰-Ⰰ-、-豈-﷏ﷰ-�][:\\wÀ-ÖØ-öø-˿Ͱ-ͽͿ-⁰-Ⰰ-、-豈-﷏ﷰ-�-\\.·̀-ͯ‿-‿-⁀]*(?=/?>| )|!--[^]*?-->)|(?:https?://|ftp://|mailto:)[^\\s\"<>[\\]{-}]*[^\\s\",\\.:;<>[\\]{-}]|^(?:=|[*#:;]+|-{4,})|\\\\'\\\\'(?:\\\\')?|&(?:(?:n(?:bsp|dash)|m(?:dash|inus)|lt|e[mn]sp|thinsp|amp|quot|gt|shy|zwn?j|lrm|rlm|Alpha|Beta|Epsilon|Zeta|Eta|Iota|Kappa|[Mm]u|micro|Nu|[Oo]micron|[Rr]ho|Tau|Upsilon|Chi)|#x[0-9a-fA-F]+);|~{3,5}";var f=new RegExp(u,"gm");var l=a("]][a-zA-Z]*");var c=a("]");var h=a("}}}");var p=a("}}");var d=a("\\|}");var v=a("\n");var m={};var g=$.client.profile().layout=="gecko";var y=$.client.profile().layout=="presto";var b=$.client.profile().layout=="trident";var w=$.client.profile().layout=="webkit"&&$.client.profile().platform!="win";if((wgAction=="edit"||wgAction=="submit")&&wgPageContentModel=="wikitext"&&!b){if(document.readyState=="complete"){C()}else{$(window).load(C)}}})() |
Aktuelle Version vom 2. Februar 2016, 19:42 Uhr
function ModifySidebar( action, section, name, link ) {
try {
switch ( section ) {
case 'languages':
var target = 'p-lang';
break;
case 'toolbox':
var target = 'p-tb';
break;
case 'navigation':
var target = 'p-navigation';
break;
default:
var target = 'p-' + section;
break;
}
if ( action == 'add' ) {
var node = document.getElementById( target )
.getElementsByTagName( 'div' )[0]
.getElementsByTagName( 'ul' )[0];
var aNode = document.createElement( 'a' );
var liNode = document.createElement( 'li' );
aNode.appendChild( document.createTextNode( name ) );
aNode.setAttribute( 'href', link );
liNode.appendChild( aNode );
liNode.className = 'plainlinks';
node.appendChild( liNode );
}
if ( action == 'remove' ) {
var list = document.getElementById( target )
.getElementsByTagName( 'div' )[0]
.getElementsByTagName( 'ul' )[0];
var listelements = list.getElementsByTagName( 'li' );
for ( var i = 0; i < listelements.length; i++ ) {
if (
listelements[i].getElementsByTagName( 'a' )[0].innerHTML == name ||
listelements[i].getElementsByTagName( 'a' )[0].href == link
)
{
list.removeChild( listelements[i] );
}
}
}
} catch( e ) {
// let's just ignore what's happened
return;
}
}
function CustomizeModificationsOfSidebar() {
// adds [[Special:CategoryTree]] to toolbox
//ModifySidebar( 'add', 'toolbox', 'CategoryTree', 'http://en.wikipedia.org/wiki/Special:CategoryTree' );
// removes [[Special:Upload]] from toolbox
//ModifySidebar( 'remove', 'toolbox', 'Upload file', 'http://en.wikipedia.org/wiki/Special:Upload' );
ModifySidebar( 'add', 'toolbox', 'Edit(forced)', window.location.href + '&action=edit' );
}
jQuery( CustomizeModificationsOfSidebar );
// Warning! Global gadget file!
( function ( mw, $ ) {
var $target;
function showTime( $target ) {
var dateNode = UTCLiveClockConfig.node;
if ( !dateNode ) {
return;
}
var now = new Date();
var hh = now.getUTCHours();
var mm = now.getUTCMinutes();
var ss = now.getUTCSeconds();
if ( $target === undefined ) {
$target = $( dateNode ).find( 'a:first' );
}
var time = ( hh < 10 ? '0' + hh : hh ) + ':' + ( mm < 10 ? '0' + mm : mm ) + ':' + ( ss < 10 ? '0' + ss : ss );
$target.text( 'UTC ' + time );
var ms = now.getUTCMilliseconds();
setTimeout( function () {
showTime( $target );
}, 1100 - ms );
}
function liveClock() {
mw.util.addCSS( '#utcdate a { font-weight:bolder; font-size:120%; }' );
if ( window.UTCLiveClockConfig === undefined ) {
window.UTCLiveClockConfig = {};
}
var portletId = UTCLiveClockConfig.portletId || 'p-personal';
var nextNode = UTCLiveClockConfig.nextNodeId ? document.getElementById( UTCLiveClockConfig.nextNodeId ) : undefined;
UTCLiveClockConfig.node = mw.util.addPortletLink(
portletId,
mw.config.get( 'wgScript' ) + '?title=' + encodeURIComponent( mw.config.get( 'wgPageName' ) ) + '&action=purge',
'',
'utcdate',
null,
null,
nextNode
);
if ( !UTCLiveClockConfig.node ) {
return;
}
showTime();
}
$( document ).ready( liveClock );
} )( mediaWiki, jQuery );
mw.loader.load( '//commons.wikimedia.org/w/index.php?title=MediaWiki:Gadget-HotCat.js&action=raw&ctype=text/javascript&smaxage=21600&maxage=86400' );
// **********************************************************************
// ** ***WARNING GLOBAL GADGET FILE*** **
// ** changes to this file affect many users. **
// ** please discuss on the talk page before editing **
// ** **
// **********************************************************************
// Imported from [[User:Alex Smotrov/edittop.js]], version as of: 2007-06-19T04:28:52
// Updated from [[User:TheDJ/Gadget-edittop.js]], version as of: 2009-04-28T11:54:22
// Imported from https://en.wikipedia.org/w/index.php?title=MediaWiki:Gadget-edittop.js&oldid=555020676 on 2013-May-14T13:42:00
if ($.inArray( mw.config.get('wgAction'), [ 'view', 'purge' ]) !== -1 && mw.config.get( 'wgNamespaceNumber' ) >=0) {
$(function edittop_hook () {
var localtitles = {
cs: 'Editovat úvodní sekci',
en: 'Edit lead section',
fa: 'ویرایش بخش آغازین',
fr: 'Modifier le résumé introductif',
id: 'Sunting bagian atas',
it: 'Modifica della sezione iniziale',
ja: '導入部を編集',
min: 'Suntiang bagian ateh',
ko: '도입부를 편집',
pa: 'ਸੋਧ',
pt: 'Editar a seção superior',
'pt-br': 'Editar a seção superior',
sr: 'Уреди уводни део',
vi: 'Sửa phần mở đầu'
};
var our_content = document.getElementById ("content") || document.getElementById ("mw_content") || document.body;
var editspans = getElementsByClassName (our_content, "span", "mw-editsection");
var span1;
for (var i = 0; editspans && i < editspans.length; i++) {
if (editspans[i].className.indexOf ("plainlinks") == -1) {
span1 = editspans[i];
break;
}
}
if (!span1) {
return;
}
var span0 = span1.cloneNode (true);
our_content = document.getElementById ("mw_header") || document.getElementById ("content") || document.body;
var parent = our_content.getElementsByTagName ("H1")[0];
parent.appendChild (span0);
var a = span0.getElementsByTagName ("A")[0];
if (a.href.indexOf ("§ion=T") == -1) {
a.title = a.title.replace (/(: |:).*$/, "$1" + "0");
a.setAttribute ("href", a.getAttribute ("href", 2).replace (/§ion=\d+/, "§ion=0"));
}
else { //transcluded
a.title = localtitles[mw.config.get( 'wgUserLanguage' )] || localtitles.en;
a.setAttribute ("href", mw.util.wikiGetlink( mw.config.get( 'wgPageName' ) ) + "?action=edit§ion=0");
}
});
}
(function(){"use strict";function a(e){return new RegExp("("+e+")\n*|"+u,"gm")}function E(){function C(e,t){if(w){e=e.replace(/ +/g,"$&")}if(t!=S){g+="'}#s"+b;if(x){g+=":before{";x=false}else{g+=":after{";x=true;++b}if(t){g+="background-color:"+t+";"}g+="content:'";S=t}g+=e}function k(t,n){var r;for(n.lastIndex=u;r=n.exec(e);n.lastIndex=u){if(r[1]){C(e.substring(u,n.lastIndex),t);u=n.lastIndex;return}var i=n.lastIndex-r[0].length;if(u<i){C(e.substring(u,i),t)}u=n.lastIndex;switch(r[0].charAt(0)){case"[":if(r[0].charAt(1)=="["){C("[[",syntaxHighlighterConfig.wikilinkColor||t);k(syntaxHighlighterConfig.wikilinkColor||t,l)}else{C(r[0],syntaxHighlighterConfig.externalLinkColor||t);k(syntaxHighlighterConfig.externalLinkColor||t,c)}break;case"{":if(r[0].charAt(1)=="{"){if(r[0].length==3){C("{{{",syntaxHighlighterConfig.parameterColor||t);k(syntaxHighlighterConfig.parameterColor||t,h)}else{C("{{",syntaxHighlighterConfig.templateColor||t);k(syntaxHighlighterConfig.templateColor||t,p)}}else{C("{|",syntaxHighlighterConfig.tableColor||t);k(syntaxHighlighterConfig.tableColor||t,d)}break;case"<":if(r[0].charAt(1)=="!"){C(r[0],syntaxHighlighterConfig.commentColor||t);break}else{var s=e.indexOf(">",u)+1;if(s==0){C("<",t);u=u-r[0].length+1;break}if(e.charAt(s-2)=="/"){C(e.substring(u-r[0].length,s),syntaxHighlighterConfig.tagColor||t);u=s}else{var o=r[0].substring(1);if(/^(?:nowiki|pre|math|syntaxhighlight|source|timeline|hiero)$/.test(o)){var g="</"+o+">";var y=e.indexOf(g,u);if(y==-1){y=e.length}else{y+=g.length}C(e.substring(u-r[0].length,y),syntaxHighlighterConfig.tagColor||t);u=y}else{C(e.substring(u-r[0].length,s),syntaxHighlighterConfig.tagColor||t);u=s;if(!m[o]){m[o]=a("</"+o+">")}k(syntaxHighlighterConfig.tagColor||t,m[o])}}}break;case"h":case"f":case"m":C(r[0],syntaxHighlighterConfig.externalLinkColor||t);break;case"=":if(/[^=]=+$/.test(e.substring(u,e.indexOf("\n",u)))){C("=",syntaxHighlighterConfig.headingColor||t);k(syntaxHighlighterConfig.headingColor||t,v)}else{C("=",t)}break;case"*":case"#":case":":C(r[0],syntaxHighlighterConfig.listOrIndentColor||t);break;case";":C(";",syntaxHighlighterConfig.headingColor||t);k(syntaxHighlighterConfig.headingColor||t,v);break;case"-":C(r[0],syntaxHighlighterConfig.hrColor||t);break;case"\\":C(r[0],syntaxHighlighterConfig.boldOrItalicColor||t);if(r[0].length==6){if(T){T=false;return}else{T=true;k(syntaxHighlighterConfig.boldOrItalicColor||t,f)}}else{if(N){N=false;return}else{N=true;k(syntaxHighlighterConfig.boldOrItalicColor||t,f)}}break;case"&":C(r[0],syntaxHighlighterConfig.entityColor||t);break;case"~":C(r[0],syntaxHighlighterConfig.signatureColor||t)}}}i=n.value;var e=i.replace(/['\\]/g,"\\$&")+"\n";var u=0;var g="";var b=0;var S;var x=true;var T=false;var N=false;if(y){e+=(new Array(n.scrollWidth)).join(" ")}var L=Date.now();k("",f);if(u<e.length){C(e.substring(u),"")}while(s<b){t.appendChild(document.createElement("span")).id="s"+ ++s}r.nodeValue=g.substring(2).replace(/\n/g,"\\A ")+"'}";var A=Date.now();if(A-L>syntaxHighlighterConfig.timeout){clearInterval(o);r.nodeValue="";n.removeEventListener("input",E);var O={};O["ca"]='S\'ha desactivat el remarcar de sintaxi en aquesta pàgina perquè ha tardat massa. El temps màxim permès per a remarcar és $1ms, i el teu ordinador ha trigat $2ms. Prova tancar algunes pestanyes i programes i fer clic en "Mostra la previsualització" o "Mostra els canvis". Si no funciona això, prova altre navegador web, i si això no funciona, prova un ordinador més ràpid.';O["en"]='Syntax highlighting on this page was disabled because it took too long. The maximum allowed highlighting time is $1ms, and your computer took $2ms. Try closing some tabs and programs and clicking "Show preview" or "Show changes". If that doesn\'t work, try a different web browser, and if that doesn\'t work, try a faster computer.';O["es"]='Se desactivó el resaltar de sintaxis en esta página porque tardó demasiado. El tiempo máximum permitido para resaltar es $1ms, y tu ordenador tardó $2ms. Prueba cerrar algunas pestañas y programas y hacer clic en "Mostrar previsualización" o "Mostrar cambios". Si no funciona esto, prueba otro navegador web, y si eso no funciona, prueba un ordenador más rápido.';O["io"]='Sintaxo-hailaitar en ca pagino esis nekapabligata pro ke konsumis tro multa tempo. La maxima permisata hailaitala tempo es $1ms, e tua ordinatro konsumis $2ms. Probez klozar kelka tabi e programi e kliktar "Previdar" o "Montrez chanji". Se to ne funcionas, probez altra brauzero, e se to ne funcionas, probez plu rapida ordinatro.';O["pt"]='O marcador de sintaxe foi desativado nesta pagina porque demorou demais. O tempo máximo permitido para marcar e $1ms, e seu computador demorou $2ms. Tenta sair de alguns programas e clique em "Mostrar previsão" ou "Mostrar alterações". Se isso não funciona, tenta usar uma outra navegador web, e se ainda não funciona, procura um computador mais rápido.';O=O[wgUserLanguage]||O[wgUserLanguage.substring(0,wgUserLanguage.indexOf("-"))]||O["en"];n.style.backgroundColor="";n.style.position="";t.style.color="red";t.style.fontFamily="";t.style.fontWeight="bold";t.style.height="";var M=document.createRange();M.selectNode(t);t.appendChild(M.createContextualFragment(O.replace("$1",syntaxHighlighterConfig.timeout).replace("$2",A-L)))}}function S(){t.scrollLeft=n.scrollLeft}function x(){t.scrollTop=n.scrollTop}function T(){if(n.value!=i){E()}if(n.scrollLeft!=t.scrollLeft){S()}if(n.scrollTop!=t.scrollTop){x()}}function N(){function i(e,t){if(syntaxHighlighterConfig[e]=="normal"){syntaxHighlighterConfig[e]=t}else if(typeof syntaxHighlighterConfig[e]!="undefined"){return}else if(typeof syntaxHighlighterConfig.defaultColor!="undefined"){syntaxHighlighterConfig[e]=syntaxHighlighterConfig.defaultColor}else{syntaxHighlighterConfig[e]=t}}window.syntaxHighlighterConfig=window.syntaxHighlighterConfig||{};i("boldOrItalicColor","#EEE");i("commentColor","#EFE");i("entityColor","#DFD");i("externalLinkColor","#EFF");i("headingColor","#EEE");i("hrColor","#EEE");i("listOrIndentColor","#EFE");i("parameterColor","#FC6");i("signatureColor","#FC6");i("tagColor","#FEF");i("tableColor","#FFC");i("templateColor","#FFC");i("wikilinkColor","#EEF");syntaxHighlighterConfig.timeout=syntaxHighlighterConfig.timeout||100;e=document.createElement("div");t=document.createElement("div");n=document.getElementById("wpTextbox1");var s=document.createElement("style");s.type="text/css";r=s.appendChild(document.createTextNode(""));t.style.backgroundColor=window.getComputedStyle(n).backgroundColor;if(t.style.backgroundColor=="transparent"){t.style.backgroundColor="white"}t.style.border="1px solid transparent";t.style.boxSizing="border-box";t.style.MozBoxSizing="border-box";t.style.color="transparent";t.style.direction=window.getComputedStyle(n).direction;t.style.fontFamily=window.getComputedStyle(n).fontFamily;t.style.fontSize=window.getComputedStyle(n).fontSize;t.style.lineHeight="normal";t.style.overflowX="auto";t.style.overflowY="scroll";t.style.whiteSpace="pre-wrap";t.style.width="100%";t.style.wordWrap="normal";n.style.backgroundColor="transparent";n.style.border="1px inset gray";n.style.boxSizing="border-box";n.style.MozBoxSizing="border-box";n.style.lineHeight="normal";n.style.margin="0";n.style.overflowX="auto";n.style.overflowY="scroll";n.style.padding="0";n.style.position="absolute";n.style.resize="none";n.style.left="0";n.style.top="0";n.style.width="100%";n.style.wordWrap="normal";t.style.height=n.offsetHeight+"px";n.style.height=t.style.height;if(g){t.style.paddingLeft="1px";t.style.paddingRight="1px"}else if(y){n.style.overflowX="scroll"}e.style.position="relative";n.parentNode.insertBefore(e,n);e.appendChild(n);e.appendChild(t);$(".tool-select *").css({zIndex:5});document.head.appendChild(s);n.addEventListener("input",E);n.addEventListener("scroll",S);n.addEventListener("scroll",x);o=setInterval(T,500);E()}function C(){setTimeout(N,0)}var e;var t;var n;var r;var i;var s=-1;var o;var u="\\[(?:\\[|(?:https?:|ftp:)?//|mailto:)|\\{(?:\\{\\{?|\\|)|<(?:[:A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-⁰-Ⰰ-、-豈-﷏ﷰ-�][:\\wÀ-ÖØ-öø-˿Ͱ-ͽͿ-⁰-Ⰰ-、-豈-﷏ﷰ-�-\\.·̀-ͯ‿-‿-⁀]*(?=/?>| )|!--[^]*?-->)|(?:https?://|ftp://|mailto:)[^\\s\"<>[\\]{-}]*[^\\s\",\\.:;<>[\\]{-}]|^(?:=|[*#:;]+|-{4,})|\\\\'\\\\'(?:\\\\')?|&(?:(?:n(?:bsp|dash)|m(?:dash|inus)|lt|e[mn]sp|thinsp|amp|quot|gt|shy|zwn?j|lrm|rlm|Alpha|Beta|Epsilon|Zeta|Eta|Iota|Kappa|[Mm]u|micro|Nu|[Oo]micron|[Rr]ho|Tau|Upsilon|Chi)|#x[0-9a-fA-F]+);|~{3,5}";var f=new RegExp(u,"gm");var l=a("]][a-zA-Z]*");var c=a("]");var h=a("}}}");var p=a("}}");var d=a("\\|}");var v=a("\n");var m={};var g=$.client.profile().layout=="gecko";var y=$.client.profile().layout=="presto";var b=$.client.profile().layout=="trident";var w=$.client.profile().layout=="webkit"&&$.client.profile().platform!="win";if((wgAction=="edit"||wgAction=="submit")&&wgPageContentModel=="wikitext"&&!b){if(document.readyState=="complete"){C()}else{$(window).load(C)}}})()