User:PerfektesChaos/js/lintHint/r.js: Difference between revisions

Content deleted Content added
2.01 + tidy-font-bug
2.11
Line 1:
/// User:PerfektesChaos/js/lintHint/r.js
/// 2017-11-0115 PerfektesChaos@de.wikipedia
/// Fingerprint:#0#69744BF2F79E7713#
/// @license GPL [//www.mediawiki.org/w/COPYING](+GFDL,LGPL,CC-BY-SA)
///<nowiki>
(function(mw,$){
"use strict";
var Version=2.0111,Signature="lintHint",HINT={doc:"en:User:PerfektesChaos/js/"+Signature,errors:["bogus-image-options","deletable-table-tag","fostered","html5-misnesting","ignored-table-attr","misnested-tag","missing-end-tag","missing-start-tag","mixed-content","multi-colon-escape","obsolete-tag","pwrap-bug-workaround","self-closed-tag","stripped-tag","tidy-font-bug","tidy-whitespace-bug"],idRev:0,last:true,later:false,launch:false,launched:false,layer:false,lazy:false,live:false,ltr:true,using:["mediawiki.api","mediawiki.api.messages","mediawiki.util"],$body:false,$page:false,$textarea:false},API={Api:false,errors:false,scream:false,service:"transform/wikitext/to/lint"},BOX={bgc:"FFFF00",bgcErr:"FFE4E1",bgcOk:"ADFF2F",bgcRun:"C0C0C0",boc:"808080",fgc:"000000",fgcRun:"A0A0A0",swift:false,$box:false,$collapsed:false,$failure:false,$null:false,$other:false,$pagename:false,$swift:false,$tbody:false,$table:false,$top:false},EDIT={listen:false,live:false,$source:false},GUIDER={last:false,live:false,reTrim:false,using:["jquery.textSelection","mediawiki.ui.button","mediawiki.ui.input"],$pagename:false},LINTER={},PREGO={app:false,signature:"preferencesGadgetOptions"};
HINT.texts={
"desc":{"en":"Show LintErrors analysis live.","de":"Zeige LintErrors-Analyse live."},
Line 42:
if(typeof apply.launch==="boolean"){
HINT.launch=apply.launch;}
if(typeof apply.layer==="boolean"){
HINT.layer=apply.layer;}
if(typeof apply.lazy==="boolean"){
HINT.lazy=apply.lazy;
Line 101 ⟶ 103:
case "edit":
case "submit":
case "parsermigration-edit":
EDIT.live=true;
HINT.nsn=mw.config.get("wgNamespaceNumber");
Line 538 ⟶ 541:
LINTER.fire=function($area){
var $table=$area.find(".TablePager");
if($table.length&&){
if(typeof $table.tablesorter==="function"){
$table.tablesorter();}
if(HINT.layer){
LINTER.reEdit=new RegExp("([?&]action=)edit(&.+)?$");
$table.find("a").each(LINTER.further);}}
};
LINTER.first=function(){
if(mw.config.get("wgTitle").indexOf("/")>0){
mw.hook("wikipage.content").add(LINTER.fire);}
};
LINTER.further=function(any,a){
var $a=$(a),s=$a.attr("href");
if(s.indexOf("action=edit")>0){
$a.attr("href",s.replace(LINTER.reEdit,"$1parsermigration-edit$2"));}
};
GUIDER.find=function(){