Jump to content

User:PerfektesChaos/js/paneMarker/dialog/r.js

From mediawiki.org

Note: After publishing, you may have to bypass your browser's cache to see the changes.

  • Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
  • Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
  • Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5.
/// mw:User:PerfektesChaos/js/paneMarker/dialog/r.js
/// 2016-10-21 PerfektesChaos@de.wikipedia
/// Fingerprint:#0#BE0E3CF2#
/// @license GPL [//www.mediawiki.org/w/COPYING](+GFDL,LGPL,CC-BY-SA)
///<nowiki>
(function(mw){
"use strict";
var PaneMk="paneMarker";
if(typeof mw.libs[PaneMk]!=="object"||!mw.libs[PaneMk]){
mw.libs[PaneMk]={prefs:{}};}
PaneMk=mw.libs[PaneMk];
if(!PaneMk.prefs){
PaneMk.prefs={};}
PaneMk.prefs.vsn=2.6;
PaneMk.prefs.texts={
"suffix":{"en":"&#8211; emphasize browser windows or tabs currently used for input activities","de":"&#8211; Browser-Fenster oder Tabs hervorheben, in denen Bearbeitung offen"},
"?icon":{"en":"<ul style='margin-left:3em'><li>URL of alternative icon</li><li><code>0</code> &#8211; regular page icon</li><li>empty: use red favicon</li></ul>",
"de":"<ul style='margin-left:3em'><li>URL eines alternativen Icons</li><li><code>0</code> &#8211; hier kein abweichender Icon</li><li>leer: Roter Standard-Favicon</li></ul>"},
"?mark":{"en":"<ul style='margin-left:3em'><li>marker string as desired</li><li><code>U+</code><i>nnnn</i> &#8211; Unicode of specific marker</li><li><code>U+0</code> &#8211; do not prepend any marker</li><li>empty: use default marker</li></ul>",
"de":"<ul style='margin-left:3em'><li>Gewünschter Marker (direkt)</li><li><code>U+</code><i>nnnn</i> &#8211; Unicode des gewünschten Markers</li><li><code>U+0</code> &#8211; keinen Marker voranstellen</li><li>leer: Standard-Marker</li></ul>"},
"^appleIcon":{"en":"Alternative red apple-touch-icon, or disabled","de":"Alternativer apple-touch-icon, oder deaktiviert"},
"^faviconICO":{"en":"Alternative red favicon in .ICO format, or disabled","de":"Alternativer Favicon im .ICO-Format, oder deaktiviert"},
"^faviconPNG":{"en":"Alternative red favicon in .PNG format, or disabled","de":"Alternativer Favicon im .PNG-Format, oder deaktiviert"},
"^lazy":{"en":"Always keep standard icon","de":"Konventionellen Icon immer beibehalten"},
"^chars":{"en":"Distinguishing mark:  general activation/deactivation",
"de":"Unterscheidungszeichen allgemein aktivieren/deaktivieren"},
"^charDiff":{"en":"Marker for diffpages","de":"Marker für diffpages"},
"^charHistory":{"en":"Marker for history pages","de":"Marker für Versionsgeschichte"},
"^charLinks":{"en":"Marker for “Whatlinkshere”","de":"Marker für Links auf diese Seite"},
"^charVitally":{"en":"Marker for important pages","de":"Marker für wichtige Seiten-Aktivitäten"},
"^lowChar":{"en":"Use ANSI characters","de":"ANSI-Zeichen benutzen"},
"^favicon":{"en":"Alternative default favicon for this project","de":"Alternativer Favicon für dieses Projekt"},
"^leave":{"en":"Create window titles as short as possible","de":"(Benutze kurzen Seitentitel)"},
"^shortcut":{"en":"Use shortcuts on page","de":"Benutze Shortcuts auf der Seite"}
};
PaneMk.prefs.userlang={
"de":"de","als":"de",
"bar":"de","dsb":"de",
"frr":"de","gsw":"de",
"hsb":"de","ksh":"de",
"lb":"de","nds":"de",
"pdc":"de","pdt":"de",
"pfl":"de","sli":"de",
"stq":"de","vmf":"de"
};
PaneMk.prefs.favorite=function(){
var r=mw.config.get("wgUserLanguage").toLowerCase();
if(r.length>4){
if(r.charCodeAt(2)===45){
r=r.substr(0,2);}}
r=this.userlang[r];
r=(r?r:"en");
switch(r){
case "de":
this.support=r+".wikipedia.org";
break;
default:
this.support="www.mediawiki.org";}
this.support="//"+this.support+"/wiki/"+PaneMk.support;
return r;
};
PaneMk.prefs.furnish=function(){
var dialog,slang=this.favorite();
this.fetch();
dialog={script:PaneMk.type,support:this.support,suffix:this.texts.suffix[slang],opts:[{signature:"appleIcon",type:"text",show:this.texts["^appleIcon"][slang],suffix:this.texts["?icon"][slang],val:this.fiat("appleIcon")},{signature:"faviconICO",type:"text",show:this.texts["^faviconICO"][slang],suffix:this.texts["?icon"][slang],val:this.fiat("faviconICO")
},{signature:"faviconPNG",type:"text",show:this.texts["^faviconPNG"][slang],suffix:this.texts["?icon"][slang],val:this.fiat("faviconPNG")},{signature:"lazy",type:"checkbox",show:this.texts["^lazy"][slang],val:this.fiat("lazy",false)},{signature:"chars",type:"checkbox",show:this.texts["^chars"][slang],val:this.fiat("chars",false)},{signature:"charDiff",type:"text",show:this.texts["^charDiff"][slang],suffix:this.texts["?mark"][slang],val:this.fiat("charDiff")
},{signature:"charHistory",type:"text",show:this.texts["^charHistory"][slang],suffix:this.texts["?mark"][slang],val:this.fiat("charHistory")},{signature:"charLinks",type:"text",show:this.texts["^charLinks"][slang],suffix:this.texts["?mark"][slang],val:this.fiat("charLinks")
},{signature:"charVitally",type:"text",show:this.texts["^charVitally"][slang],suffix:this.texts["?mark"][slang],val:this.fiat("charVitally")},{signature:"lowChar",type:"checkbox",show:this.texts["^lowChar"][slang],val:this.fiat("lowChar",false)},{signature:"favicon",type:"text",show:this.texts["^favicon"][slang],val:this.fiat("favicon")},{signature:"leave",type:"checkbox",show:this.texts["^leave"][slang],val:this.fiat("leave",false)},{signature:"shortcut",type:"checkbox",show:this.texts["^shortcut"][slang],val:this.fiat("shortcut",true)}
]};
mw.libs[this.supply].form(dialog);
};
if(mw.config.get("wgCanonicalSpecialPageName")==="Blankpage"){
PaneMk.prefs.furnish();}
}(window.mediaWiki));
/// EOF</nowiki>paneMarker/dialog/r.js