MediaWiki:Common.js: Unterschied zwischen den Versionen

Zur Navigation springen Zur Suche springen
K
K
Zeile 56: Zeile 56:
 
addOnloadHook( function() { document.location = document.getElementById('mw-returnto').getElementsByTagName('a')[0].href; } );
 
addOnloadHook( function() { document.location = document.getElementById('mw-returnto').getElementsByTagName('a')[0].href; } );
  
/******************************/
+
/***** Sonderzeichen im Edit-Modus*****/
 +
 
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/no.gif",
 +
    "speedTip": "",
 +
    "tagOpen": "",
 +
    "tagClose": "",
 +
    "sampleText": ""};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/ndash.jpg",
 +
    "speedTip": "kurzer Bindestrich (n–dash)",
 +
    "tagOpen": "–",
 +
    "tagClose": "",
 +
    "sampleText": ""};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/mdash.jpg",
 +
    "speedTip": "Text zwischen langen Bindestrichen (m—dash)",
 +
    "tagOpen": "— ",
 +
    "tagClose": " — ",
 +
    "sampleText": "Text"};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/hyphens1_dt.jpg",
 +
    "speedTip": "dt. Anführungszeichen einfach",
 +
    "tagOpen": "‚",
 +
    "tagClose": "‘",
 +
    "sampleText": ""};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/hyphens2_dt.jpg",
 +
    "speedTip": "dt. Anführungszeichen doppelt",
 +
    "tagOpen": "„",
 +
    "tagClose": "“",
 +
    "sampleText": ""};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/oo.jpg",
 +
    "speedTip": "langes o, klein",
 +
    "tagOpen": "ō",
 +
    "tagClose": "",
 +
    "sampleText": ""};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/oo_gr.jpg",
 +
    "speedTip": "langes O, gross",
 +
    "tagOpen": "Ō",
 +
    "tagClose": "",
 +
    "sampleText": ""};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/uu.jpg",
 +
    "speedTip": "langes u, klein",
 +
    "tagOpen": "ū",
 +
    "tagClose": "",
 +
    "sampleText": ""};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/uu_gr.jpg",
 +
    "speedTip": "langes U, gross",
 +
    "tagOpen": "Ū",
 +
    "tagClose": "",
 +
    "sampleText": ""};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/shy.jpg",
 +
    "speedTip": "stummes Trennzeichen",
 +
    "tagOpen": "·",
 +
    "tagClose": "",
 +
    "sampleText": ""};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/nbsp.jpg",
 +
    "speedTip": "festes Leerzeichen (no breaking space)",
 +
    "tagOpen": " ",
 +
    "tagClose": "",
 +
    "sampleText": ""};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/no.gif",
 +
    "speedTip": "",
 +
    "tagOpen": "",
 +
    "tagClose": "",
 +
    "sampleText": ""};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/ref.jpg",
 +
    "speedTip": "Fussnoten",
 +
    "tagOpen": "<ref>",
 +
    "tagClose": "</ref>",
 +
    "sampleText": "Text"};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/cat.jpg",
 +
    "speedTip": "Kategorie",
 +
    "tagOpen": "[[Kategorie:",
 +
    "tagClose": "]]",
 +
    "sampleText": " "};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/glo.jpg",
 +
    "speedTip": "Glossar",
 +
    "tagOpen": "{{glossar:",
 +
    "tagClose": "}}",
 +
    "sampleText": " "};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/skt.jpg",
 +
    "speedTip": "Sanskrit",
 +
    "tagOpen": "{{skt:",
 +
    "tagClose": "}}",
 +
    "sampleText": " "};
 +
mwCustomEditButtons[mwCustomEditButtons.length] =
 +
  {"imageFile": "/rel_jap/w/skins/common/images/shy.jpg",
 +
    "speedTip": "TITEL",
 +
    "tagOpen": "{{DISPLAYTITLE:",
 +
    "tagClose": "",
 +
    "sampleText": "\}\}<!-- \n -->"};

Version vom 4. Januar 2012, 18:28 Uhr

for (i in wgUserGroups)
 if (wgUserGroups[i] == 'sysop')
  var sysopRights = true; 

/***********************************
       Stylesheet changes
***********************************/


document.write (
    '<style>' +
    ' body {}' + //0
    ' #content #bodyContent {}' + //1
    ' #p-personal {}' + //2 
    ' #siteNotice.fixed {}' + //3
    ' .glossar2:hover small small {}' + //4
    ' div#footer {}' + //5
    ' </style>'
    );   
var newCSS = document.styleSheets[document.styleSheets.length-1],
  newRules = newCSS.cssRules || newCSS.rules;  // für alle Browser ansprechbar

/***********************************
      IMPORT
***********************************/

for (i in wgCategories) {
  if (wgCategories[i]=='Styles') {

/*** LAYOUT ***/
importScript('mediawiki:layout.js');

/*** GLOSSAR ***/
importScript('mediawiki:glossar.js');

/*** NAVIGATION ***/
importScript('mediawiki:navigation.js');

/*** POPUPS ***/
importScript('mediawiki:popup.js');
 
}
}

/***********************************
      IMPORT
***********************************/


/***********************************
      GADGETS
***********************************/

//Nach dem Einloggen wieder zur Ausgangsseite:
if (wgCanonicalSpecialPageName == "Userlogin")
	addOnloadHook( function() { document.location = document.getElementById('mw-returnto').getElementsByTagName('a')[0].href; } );

/***** Sonderzeichen im Edit-Modus*****/

mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/no.gif",
    "speedTip": "",
    "tagOpen": "",
    "tagClose": "",
    "sampleText": ""};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/ndash.jpg",
    "speedTip": "kurzer Bindestrich (n–dash)",
    "tagOpen": "–",
    "tagClose": "",
    "sampleText": ""};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/mdash.jpg",
    "speedTip": "Text zwischen langen Bindestrichen (m—dash)",
    "tagOpen": "— ",
    "tagClose": " — ",
    "sampleText": "Text"};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/hyphens1_dt.jpg",
    "speedTip": "dt. Anführungszeichen einfach",
    "tagOpen": "‚",
    "tagClose": "‘",
    "sampleText": ""};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/hyphens2_dt.jpg",
    "speedTip": "dt. Anführungszeichen doppelt",
    "tagOpen": "„",
    "tagClose": "“",
    "sampleText": ""};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/oo.jpg",
    "speedTip": "langes o, klein",
    "tagOpen": "ō",
    "tagClose": "",
    "sampleText": ""};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/oo_gr.jpg",
    "speedTip": "langes O, gross",
    "tagOpen": "Ō",
    "tagClose": "",
    "sampleText": ""};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/uu.jpg",
    "speedTip": "langes u, klein",
    "tagOpen": "ū",
    "tagClose": "",
    "sampleText": ""};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/uu_gr.jpg",
    "speedTip": "langes U, gross",
    "tagOpen": "Ū",
    "tagClose": "",
    "sampleText": ""};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/shy.jpg",
    "speedTip": "stummes Trennzeichen",
    "tagOpen": "·",
    "tagClose": "",
    "sampleText": ""};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/nbsp.jpg",
    "speedTip": "festes Leerzeichen (no breaking space)",
    "tagOpen": "&nbsp;",
    "tagClose": "",
    "sampleText": ""};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/no.gif",
    "speedTip": "",
    "tagOpen": "",
    "tagClose": "",
    "sampleText": ""};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/ref.jpg",
    "speedTip": "Fussnoten",
    "tagOpen": "<ref>",
    "tagClose": "</ref>",
    "sampleText": "Text"};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/cat.jpg",
    "speedTip": "Kategorie",
    "tagOpen": "[[Kategorie:",
    "tagClose": "]]",
    "sampleText": " "};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/glo.jpg",
    "speedTip": "Glossar",
    "tagOpen": "{{glossar:",
    "tagClose": "}}",
    "sampleText": " "};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/skt.jpg",
    "speedTip": "Sanskrit",
    "tagOpen": "{{skt:",
    "tagClose": "}}",
    "sampleText": " "};
mwCustomEditButtons[mwCustomEditButtons.length] =
  {"imageFile": "/rel_jap/w/skins/common/images/shy.jpg",
    "speedTip": "TITEL",
    "tagOpen": "{{DISPLAYTITLE:",
    "tagClose": "",
    "sampleText": "\}\}<!-- \n -->"};