wikiparser-node 1.5.2-b → 1.5.3-b
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundle/bundle.min.js +1 -1
- package/extensions/dist/base.js +1 -1
- package/package.json +4 -4
package/bundle/bundle.min.js
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
`})}}});var he,ft=k(()=>{"use strict";v();R();he=class extends T{constructor(i,e,t="plain",r=m.getConfig(),n=[],s){super(i,r,n,s),this.type=t}lint(){return[]}}});var xt,De,Gt,Ve,Pr=k(()=>{"use strict";q();v();R();ft();Ve=class extends T{constructor(e,t,r=m.getConfig(),n=[]){super(void 0,r,n);y(this,De);f(this,"type","heading");y(this,xt,void 0);$(this,xt,e);let s=new T(t[0],r,n);s.type="heading-title",s.setAttribute("stage",2);let o=new he(t[1],/^[^\S\n]*$/u,"heading-trail",r,n,{});this.append(s,o)}get level(){return u(this,xt)}toString(){let e=u(this,De,Gt);return`${e}${String(this.firstChild)}${e}${String(this.lastChild)}`}text(){let e=u(this,De,Gt);return`${e}${this.firstChild.text()}${e}`}getAttribute(e){return e==="padding"?this.level:super.getAttribute(e)}getGaps(){return this.level}lint(e=this.getAbsoluteIndex()){let t=super.lint(e),{firstChild:r,level:n}=this,s=String(r),o=r.childNodes.filter(d=>d.type==="quote"),a=o.filter(({bold:d})=>d),l=o.filter(({italic:d})=>d),p;return this.level===1&&(p={start:e,...this.getRootNode().posFromIndex(e)},t.push(w(r,p,"h1","<h1>"))),(s.startsWith("=")||s.endsWith("="))&&(p!=null||(p={start:e,...this.getRootNode().posFromIndex(e)}),t.push(w(r,p,"unbalanced-header",m.msg("unbalanced $1 in a section header",'"="')))),this.closest("html-attrs, table-attrs")&&(p!=null||(p={start:e,...this.getRootNode().posFromIndex(e)}),t.push(C(this,p,"parsing-order","section header in a HTML tag"))),a.length%2&&(p!=null||(p={start:e,...this.getRootNode().posFromIndex(e)}),t.push(w(a[a.length-1],{...p,start:e+n,left:p.left+n},"format-leakage",m.msg("unbalanced $1 in a section header","bold apostrophes")))),l.length%2&&(p!=null||(p={start:e,...this.getRootNode().posFromIndex(e)}),t.push(w(l[l.length-1],{start:e+n},"format-leakage",m.msg("unbalanced $1 in a section header","italic apostrophes")))),t}print(){let e=u(this,De,Gt);return super.print({pre:e,sep:e})}json(){let e=super.json();return e.level=this.level,e}};xt=new WeakMap,De=new WeakSet,Gt=function(){return"=".repeat(this.level)}});var ms,qt,zn=k(()=>{"use strict";V();q();v();R();ms=g=>g.text().replace(/^[ \t\n\0\v]+|([^ \t\n\0\v])[ \t\n\0\v]+$/gu,"$1"),qt=class extends T{constructor(e,t,r=m.getConfig(),n=[]){super(void 0,r,n);f(this,"type","parameter");let s=new T(typeof e=="number"?void 0:e,r,n,{}),o=new T(t,r,n);s.type="parameter-key",o.type="parameter-value",o.setAttribute("stage",2),this.append(s,o)}get anon(){return this.firstChild.length===0}afterBuild(){if(!this.anon){let{parentNode:e,firstChild:t}=this,r=ms(t);this.setAttribute("name",r),e&&e.getArgs(r,!1,!1).add(this)}}toString(){return this.anon?String(this.lastChild):super.toString("=")}text(){return this.anon?this.lastChild.text():super.text("=")}getGaps(){return this.anon?0:1}lint(e=this.getAbsoluteIndex()){var s;let t=super.lint(e),{firstChild:r}=this,n=(s=new RegExp(`https?://${ye}${ve}$`,"iu").exec(r.text()))==null?void 0:s[0];if(n&&new URL(n).search){let o=w(r,{start:e},"unescaped","unescaped query string in an anonymous parameter");o.startIndex=o.endIndex,o.startLine=o.endLine,o.startCol=o.endCol,o.endIndex++,o.endCol++,o.fix={range:[o.startIndex,o.endIndex],text:"{{=}}"},t.push(o)}return t}print(){return super.print({sep:this.anon?"":"="})}json(){let e=super.json();return e.anon=this.anon,e}}});var fs,Re,Pe,Bt,Mn,Ot,Wn,jt,Un=k(()=>{"use strict";V();q();Ee();pe();v();R();zn();Te();ft();fs=new Set(["pageid","articlepath","server","servername","scriptpath","stylepath"]),jt=class extends T{constructor(e,t,r=m.getConfig(),n=[]){var c,h;super(void 0,r,n,{});y(this,Bt);y(this,Ot);f(this,"type","template");f(this,"modifier","");y(this,Re,!1);y(this,Pe,new Map);let{parserFunction:[s,o]}=r,a=(c=/^(?:\s|\0\d+c\x7F)*\0\d+s\x7F/u.exec(e))==null?void 0:c[0];if(a)this.setAttribute("modifier",a),e=e.slice(a.length);else if(e.includes(":")){let[x,...b]=e.split(":"),[S]=/^(?:\s|\0\d+c\x7F)*/u.exec((h=b[0])!=null?h:"");this.setModifier(`${x}:${S}`)&&(e=b.join(":").slice(S.length))}let l=e.includes(":");if(l||t.length===0&&!u(this,Re)){let[x,...b]=e.split(":"),S=ie(x),I=S[b.length>0?"trimStart":"trim"](),N=I.toLowerCase(),A=s[N],F=o.includes(I);if(F||fs.has(A)||l&&A){this.setAttribute("name",A!=null?A:N),this.type="magic-word";let G=new RegExp(`^\\s*${I}\\s*$`,F?"u":"iu"),_=new he(x,G,"magic-word-name",r,n,{});if(super.insertAt(_),b.length>0&&t.unshift([b.join(":")]),this.name==="invoke")for(let Y=0;Y<2;Y++){let H=t.shift();if(!H)break;let me=new B(H.join("="),`invoke-${Y?"function":"module"}`,r,n);super.insertAt(me)}}}if(this.type==="template"){let x=ie(wt(e)).split("#")[0].trim();if(!x||/^:[\s_]*:|\0\d+[eh!+-]\x7F|[<>[\]{}\n]|%[\da-f]{2}/iu.test(x))throw n.pop(),new SyntaxError("\u975E\u6CD5\u7684\u6A21\u677F\u540D\u79F0");let b=new B(e,"template-name",r,n,{});super.insertAt(b)}let p=this.isTemplate(),d=1;for(let x=0;x<t.length;x++){let b=t[x];!p&&!(this.name==="switch"&&x>0)&&(b[0]=b.join("="),b.length=1),b.length===1&&(b.unshift(d),d++),this.insertAt(new qt(...b,r,n))}this.seal("modifier")}setModifier(e){let{parserFunction:[,,t,r]}=this.getAttribute("config"),n=ie(e).trim();if(e&&!n.endsWith(":"))return!1;let s=n.slice(0,-1).toLowerCase(),o=t.includes(s),a=r.includes(s);return u(this,Re)&&o||!u(this,Re)&&(a||e==="")||(Fe.running||this.length>1)&&(o||a||e==="")?(this.setAttribute("modifier",e),$(this,Re,o),!!e):!1}isTemplate(){return this.type==="template"||this.name==="invoke"}afterBuild(){this.modifier.includes("\0")&&this.setAttribute("modifier",this.buildFromStr(this.modifier,0))}toString(){return`{{${this.modifier}${this.type==="magic-word"?`${String(this.firstChild)}${this.length===1?"":":"}${this.childNodes.slice(1).map(String).join("|")}`:super.toString("|")}}}`}text(){let{childNodes:e,length:t,firstChild:r,modifier:n,type:s,name:o}=this;return s==="magic-word"&&o==="vardefine"?"":`{{${n}${s==="magic-word"?`${r.text()}${t===1?"":":"}${ue(e.slice(1),"|")}`:super.text("|")}}}`}getAttribute(e){switch(e){case"padding":return this.modifier.length+2;default:return super.getAttribute(e)}}getGaps(){return 1}lint(e=this.getAbsoluteIndex()){let t=super.lint(e),{type:r,childNodes:n,length:s}=this,o;if(!this.isTemplate())return t;let a=L(this,Bt,Mn).call(this);if(a.fragment!==void 0){o={start:e,...this.getRootNode().posFromIndex(e)};let p=n[r==="template"?0:1],d=w(p,o,"no-ignored","useless fragment"),c=p.childNodes.find(h=>h.type==="text"&&h.data.includes("#"));c&&(d.fix={range:[d.startIndex+c.getRelativeIndex()+c.data.indexOf("#"),d.endIndex],text:""}),t.push(d)}if(a.valid||(o!=null||(o={start:e,...this.getRootNode().posFromIndex(e)}),t.push(w(n[1],o,"invalid-invoke","illegal module name"))),r==="magic-word"&&s===2)return o!=null||(o={start:e,...this.getRootNode().posFromIndex(e)}),t.push(C(this,o,"invalid-invoke","missing module function")),t;let l=this.getDuplicatedArgs();return l.length>0&&(o!=null||(o={start:e,...this.getRootNode().posFromIndex(e)}),t.push(...l.flatMap(([,p])=>p).map(p=>w(p,o,"no-duplicate","duplicated parameter")))),t}insertAt(e,t=this.length){return super.insertAt(e,t),e.anon?L(this,Ot,Wn).call(this,e):e.name&&this.getArgs(e.name,!1,!1).add(e),e}getAllArgs(){return this.childNodes.filter(Ie("parameter"))}getAnonArgs(){return this.getAllArgs().filter(({anon:e})=>e)}getArgs(e,t=!1,r=!0){let n=String(e).replace(/^[ \t\n\0\v]+|([^ \t\n\0\v])[ \t\n\0\v]+$/gu,"$1"),s;return u(this,Pe).has(n)?s=u(this,Pe).get(n):(s=new Set(this.getAllArgs().filter(({name:o})=>n===o)),u(this,Pe).set(n,s)),s}getDuplicatedArgs(){return[...u(this,Pe)].filter(([,{size:e}])=>e>1).map(([e,t])=>[e,[...t]])}getPossibleValues(){let{type:e,name:t,childNodes:r,constructor:{name:n}}=this;if(e==="template")throw new Error(`${n}.getPossibleValues \u65B9\u6CD5\u4EC5\u4F9B\u7279\u5B9A\u9B54\u672F\u5B57\u4F7F\u7528\uFF01`);let s;switch(t){case"if":case"ifexist":case"ifexpr":case"iferror":s=2;break;case"ifeq":s=3;break;default:throw new Error(`${n}.getPossibleValues \u65B9\u6CD5\u4EC5\u4F9B\u7279\u5B9A\u9B54\u672F\u5B57\u4F7F\u7528\uFF01`)}let o=r.slice(s,s+2).map(({childNodes:[,a]})=>a);for(let a=0;a<o.length;){let{length:l,0:p}=o[a].childNodes.filter(d=>d.text().trim());if(l===0)o.splice(a,1);else if(l>1||p.type!=="magic-word")a++;else try{let d=p.getPossibleValues();o.splice(a,1,...d),a+=d.length}catch(d){a++}}return o}print(){let{childNodes:e,length:t,firstChild:r,modifier:n,type:s}=this;return`<span class="wpb-${s}">{{${n}${s==="magic-word"?`${r.print()}${t===1?"":":"}${xe(e.slice(1),{sep:"|"})}`:xe(e,{sep:"|"})}}}</span>`}};Re=new WeakMap,Pe=new WeakMap,Bt=new WeakSet,Mn=function(){let e=this.type==="template",t=this.childNodes[e?0:1];return this.normalizeTitle(t.text(),e?10:828)},Ot=new WeakSet,Wn=function(e){let t=this.getAnonArgs(),r=typeof e!="number";for(let n=r?t.indexOf(e):e-1;n<t.length;n++){let s=t[n],{name:o}=s,a=String(n+1);o!==a&&(s.setAttribute("name",a),this.getArgs(a,!1,!1).add(s))}}});var _t,Hn=k(()=>{"use strict";Me();R();_t=class extends ce(T){constructor(){super(...arguments);f(this,"type","hidden")}}});var zt,Dn=k(()=>{"use strict";V();q();v();R();Te();Hn();zt=class extends T{constructor(e,t=m.getConfig(),r=[]){super(void 0,t,r,{});f(this,"type","arg");for(let n=0;n<e.length;n++)if(n===0){let s=new B(e[n],"arg-name",t,r,{});super.insertAt(s)}else if(n>1){let s=new _t(e[n],t,r,{});super.insertAt(s)}else{let s=new T(e[n],t,r);s.type="arg-default",s.setAttribute("stage",2),super.insertAt(s)}}get default(){var e,t;return(t=(e=this.childNodes[1])==null?void 0:e.text())!=null?t:!1}toString(){return`{{{${super.toString("|")}}}}`}text(){return`{{{${ue(this.childNodes.slice(0,2),"|")}}}}`}getAttribute(e){return e==="padding"?3:super.getAttribute(e)}getGaps(){return 1}lint(e=this.getAbsoluteIndex()){let{childNodes:[t,r,...n]}=this;if(!this.getAttribute("include")){let o=C(this,{start:e},"no-arg","unexpected template argument");return r&&(o.fix={range:[e,o.endIndex],text:r.text()}),[o]}let s=t.lint(e+3);if(r&&s.push(...r.lint(e+4+String(t).length)),n.length>0){let o={start:e,...this.getRootNode().posFromIndex(e)};s.push(...n.map(a=>{let l=w(a,o,"no-ignored","invisible content inside triple braces");return l.startIndex--,l.startCol--,l.suggestions=[{desc:"remove",range:[l.startIndex,l.endIndex],text:""},{desc:"escape",range:[l.startIndex,l.startIndex+1],text:"{{!}}"}],l}))}return s}print(){return super.print({pre:"{{{",post:"}}}",sep:"|"})}json(){let e=super.json();return e.default=this.default,e}}});var Vn={};W(Vn,{parseBraces:()=>Gr});var Gr,qr=k(()=>{"use strict";V();v();Pr();Un();Dn();Gr=(g,i=m.getConfig(),e=[])=>{var c,h,x,b,S,I;let t=`${(c=i.excludes)!=null&&c.includes("heading")?"":"^(\0\\d+c\x7F)*={1,6}|"}\\[\\[|\\{{2,}|-\\{(?!\\{)`,{parserFunction:[,,,r]}=i,n=[],s={"=":`
|
|
9
9
|
`,"{":"\\}{2,}|\\|","-":"\\}-","[":"\\]\\]"},o=new Map([["!","!"],["!!","+"],["(!","{"],["!)","}"],["!-","-"],["=","~"]]),a=new RegExp(t,"gmu"),l=a.exec(g),p=g.includes("}}"),d;for(;l||d!==void 0&&d<=g.length&&((x=(h=n[n.length-1])==null?void 0:h[0])!=null&&x.startsWith("="));){if(l!=null&&l[1]){let[,{length:D}]=l;l[0]=l[0].slice(D),l.index+=D}let{0:N,index:A}=l!=null?l:{0:`
|
|
10
10
|
`,index:g.length},F=(b=n.pop())!=null?b:{},{0:E,index:G,parts:_,findEqual:Y,pos:H}=F,me=N==="="&&Y,fe=D=>{_[_.length-1].push(D.slice(H,A))};if(N==="]]"||N==="}-")d=A+2;else if(N===`
|
|
11
|
-
`){d=A+1;let{pos:D,findEqual:te}=(S=n[n.length-1])!=null?S:{};if(D===void 0||te||ie(g.slice(D,G))!==""){let X=/^(={1,6})(.+)\1((?:\s|\0\d+c\x7F)*)$/u.exec(g.slice(G,A));X&&(g=`${g.slice(0,G)}\0${e.length}h\x7F${g.slice(A)}`,d=G+4+String(e.length).length,new Ve(X[1].length,X.slice(2),i,e))}}else if(N==="|"||me)d=A+1,fe(g),N==="|"&&_.push([]),F.pos=d,F.findEqual=N==="|",n.push(F);else if(N.startsWith("}}")){let D=N.slice(0,Math.min(E.length,3)),te=E.length-D.length,{length:X}=e;d=A+D.length,fe(g);let P=!1,ge="t";if(D.length===3){let M=_.map(kt=>kt.join("=")),Oe=M.length>1&&ie(M[1]).trim();new zt(M,i,e),Oe&&Oe.endsWith(":")&&r.includes(Oe.slice(0,-1).toLowerCase())&&(ge="s")}else try{new jt(_[0][0],_.slice(1),i,e);let M=ie(_[0][0]).trim();o.has(M)?ge=o.get(M):/^(?:filepath|(?:full|canonical)urle?):.|^server$/iu.test(M)?ge="m":/^#vardefine:./iu.test(M)&&(ge="c")}catch(M){if(M instanceof SyntaxError&&M.message==="\u975E\u6CD5\u7684\u6A21\u677F\u540D\u79F0")P=!0;else throw M}P||(g=`${g.slice(0,G+te)}\0${X}${ge}\x7F${g.slice(d)}`,d=G+te+3+String(X).length,te>1?n.push({0:E.slice(0,te),index:G,pos:G+te,parts:[[]]}):te===1&&g[G-1]==="-"&&n.push({0:"-{",index:G-1,pos:G+1,parts:[[]]}))}else d=A+N.length,N.startsWith("{")&&(l.pos=d,l.parts=[[]]),n.push(..."0"in F?[F]:[],l);p&&(p=g.slice(d).includes("}}"));let ne=n[n.length-1];!p&&((I=ne==null?void 0:ne[0])!=null&&I.startsWith("{"))&&(n.pop(),ne=n[n.length-1]),a=new RegExp(t+(ne?`|${s[ne[0][0]]}${ne.findEqual?"|=":""}`:""),"gmu"),a.lastIndex=d,l=a.exec(g)}return g}});var Zn={};W(Zn,{InputboxToken:()=>jr});var jr,Qn=k(()=>{"use strict";qr();v();Rr();jr=class extends mt{constructor(i,e=m.getConfig(),t=[]){let r=Symbol("InputboxToken");t.push(r),i&&(i=Gr(i,e,t)),t.splice(t.indexOf(r),1),super(i,e,t,{})}}});var Ze,Br=k(()=>{"use strict";q();Me();v();Ae();Ze=class extends ce(K){constructor(e,t=!0,r=m.getConfig(),n=[]){super(e,r,n);f(this,"type","comment");f(this,"closed");this.closed=t}getAttribute(e){return e==="padding"?4:super.getAttribute(e)}lint(e=this.getAbsoluteIndex()){if(this.closed)return[];let t=C(this,{start:e},"unclosed-comment",m.msg("unclosed $1","HTML comment"));return t.fix={range:[t.endIndex,t.endIndex],text:"-->"},[t]}toString(){return`<!--${this.innerText}${this.closed?"-->":""}`}print(){return super.print({pre:"<!--",post:this.closed?"-->":""})}}});var Mt={};W(Mt,{NestedToken:()=>Or});var Or,Wt=k(()=>{"use strict";q();v();R();_r();Le();Br();Or=class extends T{constructor(e,t,r,n=m.getConfig(),s=[]){e=e==null?void 0:e.replace(t,(o,a,l,p,d)=>{let c=`\0${s.length+1}${a?"e":"c"}\x7F`;if(a)new Qe(a,l,p,d,n,s);else{let h=o.endsWith("-->");new Ze(o.slice(4,h?-3:void 0),h,n,s)}return c}).replace(/(^|\0\d+[ce]\x7F)([^\0]+)(?=$|\0\d+[ce]\x7F)/gu,(o,a,l)=>(new Z(l,n,s),`${a}\0${s.length}c\x7F`));super(e,n,s,{});f(this,"type","ext-inner")}lint(e=this.getAbsoluteIndex()){let t;return[...super.lint(e),...this.childNodes.filter(r=>{if(r.type==="ext"||r.type==="comment")return!1;let n=String(r).trim();return n&&!/^<!--.*-->$/su.test(n)}).map(r=>{t!=null||(t={start:e,...this.getRootNode().posFromIndex(e)});let n=w(r,t,"no-ignored",m.msg("invalid content in <$1>",this.name));return n.suggestions=[{desc:"remove",range:[n.startIndex,n.endIndex],text:""},{desc:"comment",range:[n.startIndex,n.startIndex],text:`<!--${String(r)}-->`}],n})]}}});var Ge,de,qe,$e,Ut=k(()=>{"use strict";q();pe();v();R();Te();$e=class extends T{constructor(e,t,r=m.getConfig(),n=[],s="|"){super(void 0,r,n,{});y(this,Ge,!0);y(this,de,void 0);y(this,qe,void 0);if(this.insertAt(new B(e,"link-target",r,n,{})),t!==void 0){let o=new T(t,r,n,{});o.type="link-text",o.setAttribute("stage",10),this.insertAt(o)}$(this,de,s)}afterBuild(){$(this,qe,this.getTitle()),u(this,de).includes("\0")&&$(this,de,this.buildFromStr(u(this,de),0))}setAttribute(e,t){e==="bracket"?$(this,Ge,!!t):e==="title"?$(this,qe,t):super.setAttribute(e,t)}toString(){let e=super.toString(u(this,de));return u(this,Ge)?`[[${e}]]`:e}text(){let e=super.text("|");return u(this,Ge)?`[[${e}]]`:e}getAttribute(e){return e==="title"?u(this,qe):e==="padding"?2:super.getAttribute(e)}getGaps(e){return e===0?u(this,de).length:1}lint(e=this.getAbsoluteIndex()){let t=super.lint(e),{childNodes:[r,n],type:s}=this,{encoded:o,fragment:a}=u(this,qe),l;if(r.childNodes.some(({type:p})=>p==="template")&&(l={start:e,...this.getRootNode().posFromIndex(e)},t.push(w(r,l,"unknown-page","template in an internal link target","warning"))),o&&(l!=null||(l={start:e,...this.getRootNode().posFromIndex(e)}),t.push(w(r,l,"url-encoding","unnecessary URL encoding in an internal link"))),s==="link"||s==="category"){let p=n==null?void 0:n.childNodes.find(d=>d.type==="text"&&d.data.includes("|"));if(p){l!=null||(l={start:e,...this.getRootNode().posFromIndex(e)});let d=w(n,l,"pipe-like",'additional "|" in the link text',"warning");d.suggestions=[{desc:"escape",range:[d.startIndex+p.getRelativeIndex(),d.startIndex+p.getRelativeIndex()+p.data.length],text:p.data.replace(/\|/gu,"|")}],t.push(d)}}if(s!=="link"&&a!==void 0){l!=null||(l={start:e,...this.getRootNode().posFromIndex(e)});let p=w(r,l,"no-ignored","useless fragment"),d=r.childNodes.find(c=>c.type==="text"&&c.data.includes("#"));d&&(p.fix={range:[p.startIndex+d.getRelativeIndex()+d.data.indexOf("#"),p.endIndex],text:""}),t.push(p)}return t}getTitle(){return this.normalizeTitle(this.firstChild.text(),0,!1,!0,!0)}print(){return super.print(u(this,Ge)?{pre:"[[",post:"]]",sep:u(this,de)}:{sep:u(this,de)})}};Ge=new WeakMap,de=new WeakMap,qe=new WeakMap});function Xn(g,i,e,t=!1,r){i=i.trim();let n=i.replace(/\0\d+t\x7F/gu,"").trim();switch(g){case"width":return!n||/^(?:\d+x?|\d*x\d+)$/u.test(n);case"link":{if(!n||new RegExp(`^(?:(?:${e.protocol}|//)${ye}|\0\\d+m\x7F)${ve}$`,"iu").test(n))return i;n.startsWith("[[")&&n.endsWith("]]")&&(n=n.slice(2,-2));let o=m.normalizeTitle(n,0,!1,e,t,!0,!0);return o.valid&&o}case"lang":return(r==="svg"||r==="svgz")&&!/[^a-z\d-]/u.test(n);case"alt":case"class":case"manualthumb":return!0;case"page":return(r==="djvu"||r==="djv")&&Number(n)>0;default:return!Number.isNaN(Number(n))}}var xs,ee,Dt,Kn,Ht,Jn=k(()=>{"use strict";V();q();v();R();xs=new Set(["alt","link","lang","page","caption"]);Ht=class extends T{constructor(e,t,r=m.getConfig(),n=[]){var i=(...kl)=>(super(...kl),y(this,Dt),f(this,"type","image-parameter"),y(this,ee,""),this);var l;let s,o=Object.entries(r.img).map(([p,d])=>[p,d,new RegExp(`^(\\s*)${p.replace("$1","(.*)")}(\\s*)$`,"u")]),a=o.find(([,p,d])=>(s=d.exec(e),s&&(s.length!==4||Xn(p,s[2],r,!0,t)!==!1)));if(a&&s){s.length===3?(i(void 0,r,n),$(this,ee,e)):(i(s[2],r,n,{}),$(this,ee,`${s[1]}${a[0]}${s[3]}`)),this.setAttribute("name",a[1]);return}i(e,{...r,excludes:[...(l=r.excludes)!=null?l:[],"list"]},n),this.setAttribute("name","caption"),this.setAttribute("stage",7)}get link(){return this.name==="link"?Xn("link",super.text(),this.getAttribute("config")):void 0}afterBuild(){var e;((e=this.parentNode)==null?void 0:e.type)==="gallery-image"&&!xs.has(this.name)&&this.setAttribute("name","invalid")}toString(){return u(this,ee)?u(this,ee).replace("$1",super.toString()):super.toString()}text(){return u(this,ee)?u(this,ee).replace("$1",super.text()).trim():super.text().trim()}getAttribute(e){return e==="plain"?this.name==="caption":e==="padding"?Math.max(0,u(this,ee).indexOf("$1")):super.getAttribute(e)}lint(e=this.getAbsoluteIndex()){let t=super.lint(e),{link:r,name:n}=this;if(n==="invalid"){let s=C(this,{start:e},"invalid-gallery","invalid gallery image parameter");s.fix={range:[e,e+s.endIndex],text:""},t.push(s)}else typeof r=="object"&&r.encoded&&t.push(C(this,{start:e},"url-encoding","unnecessary URL encoding in an internal link"));return t}getValue(){return this.name==="invalid"?this.text():L(this,Dt,Kn).call(this)||super.text()}print(){return u(this,ee)?`<span class="wpb-image-parameter">${u(this,ee).replace("$1",`<span class="wpb-image-caption">${xe(this.childNodes)}</span>`)}</span>`:super.print({class:"image-caption"})}};ee=new WeakMap,Dt=new WeakSet,Kn=function(){return u(this,ee)&&!u(this,ee).includes("$1")}});var zr,Mr,Wr,Ts,Xe,Vt,Ke,Ur=k(()=>{"use strict";V();q();v();Ut();Jn();zr=new Set(["manualthumb","frameless","framed","thumbnail"]),Mr=new Set(["left","right","center","none"]),Wr=new Set(["baseline","sub","super","top","text-top","middle","bottom","text-bottom"]),Ts=(g,i,e,t)=>{if(t===void 0)return[];let r=new RegExp(`${[g,i,e].map(xn).join("|")}`,"gu"),n=[],s=r.exec(t),o=0,a=0;for(;s;){let{0:l,index:p}=s;l!==e?o+=l===g?1:-1:o===0&&(n.push(t.slice(a,p)),{lastIndex:a}=r),s=r.exec(t)}return n.push(t.slice(a)),n},Ke=class extends $e{constructor(e,t,r=m.getConfig(),n=[],s="|"){super(e,void 0,r,n,s);y(this,Xe);f(this,"type","file");let{extension:o}=this;this.append(...Ts("-{","}-","|",t).map(a=>new Ht(a,o,r,n)))}get extension(){return this.getTitle().extension}lint(e=this.getAbsoluteIndex()){var d;let t=super.lint(e),r=this.getAllArgs().filter(({childNodes:c})=>{let h=c.filter(x=>x.text().trim());return h.length!==1||h[0].type!=="arg"}),n=[...new Set(r.map(({name:c})=>c))].filter(c=>c!=="invalid"),s=n.filter(c=>zr.has(c)),o=n.filter(c=>Mr.has(c)),a=n.filter(c=>Wr.has(c));if(this.closest("ext-link-text")&&((d=this.getValue("link"))==null?void 0:d.trim())!==""&&t.push(C(this,{start:e},"nested-link","internal link in an external link")),r.length===n.length&&s.length<2&&o.length<2&&a.length<2)return t;let l={start:e,...this.getRootNode().posFromIndex(e)},p=(c,h)=>x=>w(x,l,"no-duplicate",m.msg(`${c} image $1 parameter`,h));for(let c of n){let h=r.filter(({name:x})=>x===c);c==="caption"&&(h=[...h.slice(0,-1).filter(x=>x.text()),...h.slice(-1)]),h.length>1&&t.push(...h.map(p("duplicated",c)))}return s.length>1&&t.push(...r.filter(({name:c})=>zr.has(c)).map(p("conflicting","frame"))),o.length>1&&t.push(...r.filter(({name:c})=>Mr.has(c)).map(p("conflicting","horizontal-alignment"))),a.length>1&&t.push(...r.filter(({name:c})=>Wr.has(c)).map(p("conflicting","vertical-alignment"))),t}getAllArgs(){return this.childNodes.slice(1)}getArgs(e){return this.getAllArgs().filter(({name:t})=>e===t)}getFrameArgs(){return L(this,Xe,Vt).call(this,zr,"\u6846\u67B6")}getHorizAlignArgs(){return L(this,Xe,Vt).call(this,Mr,"\u6C34\u5E73\u5BF9\u9F50")}getVertAlignArgs(){return L(this,Xe,Vt).call(this,Wr,"\u5782\u76F4\u5BF9\u9F50")}getArg(e){let t=this.getArgs(e);return t[t.length-1]}getValue(e){var t;return(t=this.getArg(e))==null?void 0:t.getValue()}};Xe=new WeakSet,Vt=function(e,t){return this.getAllArgs().filter(({name:n})=>e.has(n))}});var Zt,Yn,Je,Hr=k(()=>{"use strict";q();pe();v();R();Ur();Je=class extends Ke{constructor(e,t,r,n=m.getConfig(),s=[]){let o;if(r!==void 0){o=new T(r,n,s),o.type="plain";for(let a=1;a<11;a++)o.parseOnce();s.splice(s.indexOf(o),1)}super(t,o==null?void 0:o.toString(),n,s);y(this,Zt);this.setAttribute("bracket",!1),this.type=`${e}-image`}getTitle(){let e=this.type==="imagemap-image";return this.normalizeTitle(String(this.firstChild),e?0:6,!0,!e)}getAttribute(e){return e==="padding"?0:super.getAttribute(e)}lint(e=this.getAbsoluteIndex()){let t=super.lint(e),{ns:r,interwiki:n}=this.getAttribute("title");return(n||r!==6)&&t.push(C(this,{start:e},"invalid-gallery","invalid gallery image")),t}afterBuild(){L(this,Zt,Yn).call(this,this.getTitle())}};Zt=new WeakSet,Yn=function(e){this.setAttribute("title",e)}});var ti={};W(ti,{GalleryToken:()=>Dr});var Qt,ei,Dr,ri=k(()=>{"use strict";v();R();Hr();Le();Dr=class extends T{constructor(e,t=m.getConfig(),r=[]){var n;super(void 0,t,r,{});y(this,Qt);f(this,"type","ext-inner");for(let s of(n=e==null?void 0:e.split(`
|
|
11
|
+
`){d=A+1;let{pos:D,findEqual:te}=(S=n[n.length-1])!=null?S:{};if(D===void 0||te||ie(g.slice(D,G))!==""){let X=/^(={1,6})(.+)\1((?:\s|\0\d+c\x7F)*)$/u.exec(g.slice(G,A));X&&(g=`${g.slice(0,G)}\0${e.length}h\x7F${g.slice(A)}`,d=G+4+String(e.length).length,new Ve(X[1].length,X.slice(2),i,e))}}else if(N==="|"||me)d=A+1,fe(g),N==="|"&&_.push([]),F.pos=d,F.findEqual=N==="|",n.push(F);else if(N.startsWith("}}")){let D=N.slice(0,Math.min(E.length,3)),te=E.length-D.length,{length:X}=e;d=A+D.length,fe(g);let P=!1,ge="t";if(D.length===3){let M=_.map(kt=>kt.join("=")),Oe=M.length>1&&ie(M[1]).trim();new zt(M,i,e),Oe&&Oe.endsWith(":")&&r.includes(Oe.slice(0,-1).toLowerCase())&&(ge="s")}else try{new jt(_[0][0],_.slice(1),i,e);let M=ie(_[0][0]).trim();o.has(M)?ge=o.get(M):/^(?:filepath|(?:full|canonical)urle?):.|^server$/iu.test(M)?ge="m":/^#vardefine:./iu.test(M)&&(ge="c")}catch(M){if(M instanceof SyntaxError&&M.message==="\u975E\u6CD5\u7684\u6A21\u677F\u540D\u79F0")P=!0;else throw M}P||(g=`${g.slice(0,G+te)}\0${X}${ge}\x7F${g.slice(d)}`,d=G+te+3+String(X).length,te>1?n.push({0:E.slice(0,te),index:G,pos:G+te,parts:[[]]}):te===1&&g[G-1]==="-"&&n.push({0:"-{",index:G-1,pos:G+1,parts:[[]]}))}else d=A+N.length,N.startsWith("{")&&(l.pos=d,l.parts=[[]]),n.push(..."0"in F?[F]:[],l);p&&(p=g.slice(d).includes("}}"));let ne=n[n.length-1];!p&&((I=ne==null?void 0:ne[0])!=null&&I.startsWith("{"))&&(n.pop(),ne=n[n.length-1]),a=new RegExp(t+(ne?`|${s[ne[0][0]]}${ne.findEqual?"|=":""}`:""),"gmu"),a.lastIndex=d,l=a.exec(g)}return g}});var Zn={};W(Zn,{InputboxToken:()=>jr});var jr,Qn=k(()=>{"use strict";qr();v();Rr();jr=class extends mt{constructor(i,e=m.getConfig(),t=[]){let r=Symbol("InputboxToken");t.push(r),i&&(i=Gr(i,e,t)),t.splice(t.indexOf(r),1),super(i,e,t,{})}}});var Ze,Br=k(()=>{"use strict";q();Me();v();Ae();Ze=class extends ce(K){constructor(e,t=!0,r=m.getConfig(),n=[]){super(e,r,n);f(this,"type","comment");f(this,"closed");this.closed=t}getAttribute(e){return e==="padding"?4:super.getAttribute(e)}lint(e=this.getAbsoluteIndex()){if(this.closed)return[];let t=C(this,{start:e},"unclosed-comment",m.msg("unclosed $1","HTML comment"));return t.fix={range:[t.endIndex,t.endIndex],text:"-->"},[t]}toString(){return`<!--${this.innerText}${this.closed?"-->":""}`}print(){return super.print({pre:"<!--",post:this.closed?"-->":""})}}});var Mt={};W(Mt,{NestedToken:()=>Or});var Or,Wt=k(()=>{"use strict";q();v();R();_r();Le();Br();Or=class extends T{constructor(e,t,r,n=m.getConfig(),s=[]){e=e==null?void 0:e.replace(t,(o,a,l,p,d)=>{let c=`\0${s.length+1}${a?"e":"c"}\x7F`;if(a)new Qe(a,l,p,d,n,s);else{let h=o.endsWith("-->");new Ze(o.slice(4,h?-3:void 0),h,n,s)}return c}).replace(/(^|\0\d+[ce]\x7F)([^\0]+)(?=$|\0\d+[ce]\x7F)/gu,(o,a,l)=>(new Z(l,n,s),`${a}\0${s.length}c\x7F`));super(e,n,s,{});f(this,"type","ext-inner")}lint(e=this.getAbsoluteIndex()){let t;return[...super.lint(e),...this.childNodes.filter(r=>{if(r.type==="ext"||r.type==="comment")return!1;let n=String(r).trim();return n&&!/^<!--.*-->$/su.test(n)}).map(r=>{t!=null||(t={start:e,...this.getRootNode().posFromIndex(e)});let n=w(r,t,"no-ignored",m.msg("invalid content in <$1>",this.name));return n.suggestions=[{desc:"remove",range:[n.startIndex,n.endIndex],text:""},{desc:"comment",range:[n.startIndex,n.startIndex],text:`<!--${String(r)}-->`}],n})]}}});var Ge,de,qe,$e,Ut=k(()=>{"use strict";q();pe();v();R();Te();$e=class extends T{constructor(e,t,r=m.getConfig(),n=[],s="|"){super(void 0,r,n,{});y(this,Ge,!0);y(this,de,void 0);y(this,qe,void 0);if(this.insertAt(new B(e,"link-target",r,n,{})),t!==void 0){let o=new T(t,r,n,{});o.type="link-text",o.setAttribute("stage",10),this.insertAt(o)}$(this,de,s)}afterBuild(){$(this,qe,this.getTitle()),u(this,de).includes("\0")&&$(this,de,this.buildFromStr(u(this,de),0))}setAttribute(e,t){e==="bracket"?$(this,Ge,!!t):e==="title"?$(this,qe,t):super.setAttribute(e,t)}toString(){let e=super.toString(u(this,de));return u(this,Ge)?`[[${e}]]`:e}text(){let e=super.text("|");return u(this,Ge)?`[[${e}]]`:e}getAttribute(e){return e==="title"?u(this,qe):e==="padding"?2:super.getAttribute(e)}getGaps(e){return e===0?u(this,de).length:1}lint(e=this.getAbsoluteIndex()){let t=super.lint(e),{childNodes:[r,n],type:s}=this,{encoded:o,fragment:a}=u(this,qe),l;if(r.childNodes.some(({type:p})=>p==="template")&&(l={start:e,...this.getRootNode().posFromIndex(e)},t.push(w(r,l,"unknown-page","template in an internal link target","warning"))),o&&(l!=null||(l={start:e,...this.getRootNode().posFromIndex(e)}),t.push(w(r,l,"url-encoding","unnecessary URL encoding in an internal link"))),s==="link"||s==="category"){let p=n==null?void 0:n.childNodes.find(d=>d.type==="text"&&d.data.includes("|"));if(p){l!=null||(l={start:e,...this.getRootNode().posFromIndex(e)});let d=w(n,l,"pipe-like",'additional "|" in the link text',"warning");d.suggestions=[{desc:"escape",range:[d.startIndex+p.getRelativeIndex(),d.startIndex+p.getRelativeIndex()+p.data.length],text:p.data.replace(/\|/gu,"|")}],t.push(d)}}if(s!=="link"&&a!==void 0){l!=null||(l={start:e,...this.getRootNode().posFromIndex(e)});let p=w(r,l,"no-ignored","useless fragment"),d=r.childNodes.find(c=>c.type==="text"&&c.data.includes("#"));d&&(p.fix={range:[p.startIndex+d.getRelativeIndex()+d.data.indexOf("#"),p.endIndex],text:""}),t.push(p)}return t}getTitle(e=!1){return this.normalizeTitle(this.firstChild.text(),0,e,!0,!0)}print(){return super.print(u(this,Ge)?{pre:"[[",post:"]]",sep:u(this,de)}:{sep:u(this,de)})}};Ge=new WeakMap,de=new WeakMap,qe=new WeakMap});function Xn(g,i,e,t=!1,r){i=i.trim();let n=i.replace(/\0\d+t\x7F/gu,"").trim();switch(g){case"width":return!n||/^(?:\d+x?|\d*x\d+)$/u.test(n);case"link":{if(!n||new RegExp(`^(?:(?:${e.protocol}|//)${ye}|\0\\d+m\x7F)${ve}$`,"iu").test(n))return i;n.startsWith("[[")&&n.endsWith("]]")&&(n=n.slice(2,-2));let o=m.normalizeTitle(n,0,!1,e,t,!0,!0);return o.valid&&o}case"lang":return(r==="svg"||r==="svgz")&&!/[^a-z\d-]/u.test(n);case"alt":case"class":case"manualthumb":return!0;case"page":return(r==="djvu"||r==="djv")&&Number(n)>0;default:return!Number.isNaN(Number(n))}}var xs,ee,Dt,Kn,Ht,Jn=k(()=>{"use strict";V();q();v();R();xs=new Set(["alt","link","lang","page","caption"]);Ht=class extends T{constructor(e,t,r=m.getConfig(),n=[]){var i=(...kl)=>(super(...kl),y(this,Dt),f(this,"type","image-parameter"),y(this,ee,""),this);var l;let s,o=Object.entries(r.img).map(([p,d])=>[p,d,new RegExp(`^(\\s*)${p.replace("$1","(.*)")}(\\s*)$`,"u")]),a=o.find(([,p,d])=>(s=d.exec(e),s&&(s.length!==4||Xn(p,s[2],r,!0,t)!==!1)));if(a&&s){s.length===3?(i(void 0,r,n),$(this,ee,e)):(i(s[2],r,n,{}),$(this,ee,`${s[1]}${a[0]}${s[3]}`)),this.setAttribute("name",a[1]);return}i(e,{...r,excludes:[...(l=r.excludes)!=null?l:[],"list"]},n),this.setAttribute("name","caption"),this.setAttribute("stage",7)}get link(){return this.name==="link"?Xn("link",super.text(),this.getAttribute("config")):void 0}afterBuild(){var e;((e=this.parentNode)==null?void 0:e.type)==="gallery-image"&&!xs.has(this.name)&&this.setAttribute("name","invalid")}toString(){return u(this,ee)?u(this,ee).replace("$1",super.toString()):super.toString()}text(){return u(this,ee)?u(this,ee).replace("$1",super.text()).trim():super.text().trim()}getAttribute(e){return e==="plain"?this.name==="caption":e==="padding"?Math.max(0,u(this,ee).indexOf("$1")):super.getAttribute(e)}lint(e=this.getAbsoluteIndex()){let t=super.lint(e),{link:r,name:n}=this;if(n==="invalid"){let s=C(this,{start:e},"invalid-gallery","invalid gallery image parameter");s.fix={range:[e,e+s.endIndex],text:""},t.push(s)}else typeof r=="object"&&r.encoded&&t.push(C(this,{start:e},"url-encoding","unnecessary URL encoding in an internal link"));return t}getValue(){return this.name==="invalid"?this.text():L(this,Dt,Kn).call(this)||super.text()}print(){return u(this,ee)?`<span class="wpb-image-parameter">${u(this,ee).replace("$1",`<span class="wpb-image-caption">${xe(this.childNodes)}</span>`)}</span>`:super.print({class:"image-caption"})}};ee=new WeakMap,Dt=new WeakSet,Kn=function(){return u(this,ee)&&!u(this,ee).includes("$1")}});var zr,Mr,Wr,Ts,Xe,Vt,Ke,Ur=k(()=>{"use strict";V();q();v();Ut();Jn();zr=new Set(["manualthumb","frameless","framed","thumbnail"]),Mr=new Set(["left","right","center","none"]),Wr=new Set(["baseline","sub","super","top","text-top","middle","bottom","text-bottom"]),Ts=(g,i,e,t)=>{if(t===void 0)return[];let r=new RegExp(`${[g,i,e].map(xn).join("|")}`,"gu"),n=[],s=r.exec(t),o=0,a=0;for(;s;){let{0:l,index:p}=s;l!==e?o+=l===g?1:-1:o===0&&(n.push(t.slice(a,p)),{lastIndex:a}=r),s=r.exec(t)}return n.push(t.slice(a)),n},Ke=class extends $e{constructor(e,t,r=m.getConfig(),n=[],s="|"){super(e,void 0,r,n,s);y(this,Xe);f(this,"type","file");let{extension:o}=this.getTitle(!0);this.append(...Ts("-{","}-","|",t).map(a=>new Ht(a,o,r,n)))}get extension(){return this.getTitle().extension}lint(e=this.getAbsoluteIndex()){var d;let t=super.lint(e),r=this.getAllArgs().filter(({childNodes:c})=>{let h=c.filter(x=>x.text().trim());return h.length!==1||h[0].type!=="arg"}),n=[...new Set(r.map(({name:c})=>c))].filter(c=>c!=="invalid"),s=n.filter(c=>zr.has(c)),o=n.filter(c=>Mr.has(c)),a=n.filter(c=>Wr.has(c));if(this.closest("ext-link-text")&&((d=this.getValue("link"))==null?void 0:d.trim())!==""&&t.push(C(this,{start:e},"nested-link","internal link in an external link")),r.length===n.length&&s.length<2&&o.length<2&&a.length<2)return t;let l={start:e,...this.getRootNode().posFromIndex(e)},p=(c,h)=>x=>w(x,l,"no-duplicate",m.msg(`${c} image $1 parameter`,h));for(let c of n){let h=r.filter(({name:x})=>x===c);c==="caption"&&(h=[...h.slice(0,-1).filter(x=>x.text()),...h.slice(-1)]),h.length>1&&t.push(...h.map(p("duplicated",c)))}return s.length>1&&t.push(...r.filter(({name:c})=>zr.has(c)).map(p("conflicting","frame"))),o.length>1&&t.push(...r.filter(({name:c})=>Mr.has(c)).map(p("conflicting","horizontal-alignment"))),a.length>1&&t.push(...r.filter(({name:c})=>Wr.has(c)).map(p("conflicting","vertical-alignment"))),t}getAllArgs(){return this.childNodes.slice(1)}getArgs(e){return this.getAllArgs().filter(({name:t})=>e===t)}getFrameArgs(){return L(this,Xe,Vt).call(this,zr,"\u6846\u67B6")}getHorizAlignArgs(){return L(this,Xe,Vt).call(this,Mr,"\u6C34\u5E73\u5BF9\u9F50")}getVertAlignArgs(){return L(this,Xe,Vt).call(this,Wr,"\u5782\u76F4\u5BF9\u9F50")}getArg(e){let t=this.getArgs(e);return t[t.length-1]}getValue(e){var t;return(t=this.getArg(e))==null?void 0:t.getValue()}};Xe=new WeakSet,Vt=function(e,t){return this.getAllArgs().filter(({name:n})=>e.has(n))}});var Zt,Yn,Je,Hr=k(()=>{"use strict";q();pe();v();R();Ur();Je=class extends Ke{constructor(e,t,r,n=m.getConfig(),s=[]){let o;if(r!==void 0){o=new T(r,n,s),o.type="plain";for(let a=1;a<11;a++)o.parseOnce();s.splice(s.indexOf(o),1)}super(t,o==null?void 0:o.toString(),n,s);y(this,Zt);this.setAttribute("bracket",!1),this.type=`${e}-image`}getTitle(){let e=this.type==="imagemap-image";return this.normalizeTitle(String(this.firstChild),e?0:6,!0,!e)}getAttribute(e){return e==="padding"?0:super.getAttribute(e)}lint(e=this.getAbsoluteIndex()){let t=super.lint(e),{ns:r,interwiki:n}=this.getAttribute("title");return(n||r!==6)&&t.push(C(this,{start:e},"invalid-gallery","invalid gallery image")),t}afterBuild(){L(this,Zt,Yn).call(this,this.getTitle())}};Zt=new WeakSet,Yn=function(e){this.setAttribute("title",e)}});var ti={};W(ti,{GalleryToken:()=>Dr});var Qt,ei,Dr,ri=k(()=>{"use strict";v();R();Hr();Le();Dr=class extends T{constructor(e,t=m.getConfig(),r=[]){var n;super(void 0,t,r,{});y(this,Qt);f(this,"type","ext-inner");for(let s of(n=e==null?void 0:e.split(`
|
|
12
12
|
`))!=null?n:[]){let o=/^([^|]+)(?:\|(.*))?/u.exec(s);if(!o){super.insertAt(s.trim()?new Z(s,t):s);continue}let[,a,l]=o;L(this,Qt,ei).call(this,a)?super.insertAt(new Je("gallery",a,l,t,r)):super.insertAt(new Z(s,t))}}toString(){return super.toString(`
|
|
13
13
|
`)}text(){return super.text(`
|
|
14
14
|
`).replace(/\n\s*\n/gu,`
|
package/extensions/dist/base.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
(() => {
|
|
2
2
|
const workerJS = () => {
|
|
3
|
-
importScripts('https://testingcf.jsdelivr.net/npm/wikiparser-node@1.5.
|
|
3
|
+
importScripts('https://testingcf.jsdelivr.net/npm/wikiparser-node@1.5.3-b/bundle/bundle.min.js');
|
|
4
4
|
const entities = { '&': 'amp', '<': 'lt', '>': 'gt' };
|
|
5
5
|
self.onmessage = ({ data }) => {
|
|
6
6
|
const [command, qid, wikitext, include, stage] = data;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "wikiparser-node",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.3-b",
|
|
4
4
|
"description": "A Node.js parser for MediaWiki markup with AST",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"mediawiki",
|
|
@@ -54,8 +54,8 @@
|
|
|
54
54
|
"@stylistic/stylelint-plugin": "^2.0.0",
|
|
55
55
|
"@types/node": "^20.11.6",
|
|
56
56
|
"@types/request": "^2.48.12",
|
|
57
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
58
|
-
"@typescript-eslint/parser": "^
|
|
57
|
+
"@typescript-eslint/eslint-plugin": "^7.1.0",
|
|
58
|
+
"@typescript-eslint/parser": "^7.1.0",
|
|
59
59
|
"ajv-cli": "^5.0.0",
|
|
60
60
|
"chalk": "^4.1.2",
|
|
61
61
|
"esbuild": "^0.19.12",
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
"eslint-plugin-n": "^16.6.2",
|
|
68
68
|
"eslint-plugin-promise": "^6.1.1",
|
|
69
69
|
"eslint-plugin-regexp": "^2.2.0",
|
|
70
|
-
"eslint-plugin-unicorn": "^
|
|
70
|
+
"eslint-plugin-unicorn": "^51.0.1",
|
|
71
71
|
"http-server": "^14.1.0",
|
|
72
72
|
"stylelint": "^16.1.0",
|
|
73
73
|
"stylelint-config-recommended": "^14.0.0",
|