wikiparser-node 1.41.0 → 1.42.0
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/README.md +5 -3
- package/bundle/bundle-es8.min.js +27 -27
- package/bundle/bundle-lsp.min.js +28 -28
- package/bundle/bundle.min.js +19 -19
- package/dist/addon/attribute.js +1 -1
- package/dist/addon/transclude.js +1 -3
- package/dist/bin/config.js +1 -1
- package/dist/index.js +1 -2
- package/dist/lib/element.d.ts +3 -8
- package/dist/lib/element.js +2 -26
- package/dist/lib/lsp.d.ts +2 -0
- package/dist/lib/lsp.js +8 -20
- package/dist/lib/node.d.ts +2 -0
- package/dist/lib/node.js +0 -7
- package/dist/lib/range.d.ts +0 -7
- package/dist/lib/range.js +5 -14
- package/dist/lib/text.js +3 -5
- package/dist/map.d.ts +66 -0
- package/dist/map.js +2 -0
- package/dist/mixin/attributesParent.d.ts +4 -3
- package/dist/mixin/elementLike.d.ts +13 -0
- package/dist/mixin/elementLike.js +66 -53
- package/dist/parser/selector.js +3 -3
- package/dist/render/extension.js +139 -8
- package/dist/render/html.js +72 -3
- package/dist/src/attribute.d.ts +2 -2
- package/dist/src/attribute.js +17 -13
- package/dist/src/attributes.d.ts +3 -3
- package/dist/src/attributes.js +30 -14
- package/dist/src/extLink.js +5 -4
- package/dist/src/heading.js +11 -3
- package/dist/src/index.js +3 -4
- package/dist/src/link/base.js +2 -4
- package/dist/src/link/file.js +5 -5
- package/dist/src/link/galleryImage.js +1 -3
- package/dist/src/magicLink.js +6 -5
- package/dist/src/multiLine/gallery.js +2 -3
- package/dist/src/nowiki/doubleUnderscore.d.ts +1 -0
- package/dist/src/nowiki/doubleUnderscore.js +4 -1
- package/dist/src/nowiki/quote.js +1 -3
- package/dist/src/parameter.js +5 -2
- package/dist/src/table/td.d.ts +2 -2
- package/dist/src/table/td.js +1 -1
- package/dist/src/tag/html.js +29 -12
- package/dist/src/tagPair/ext.js +4 -1
- package/dist/src/tagPair/translate.d.ts +1 -1
- package/dist/src/tagPair/translate.js +1 -1
- package/dist/util/debug.js +5 -7
- package/dist/util/html.js +3 -11
- package/extensions/dist/base.js +1 -1
- package/package.json +5 -5
package/bundle/bundle.min.js
CHANGED
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
"use strict";(()=>{var Ha=Object.create;var Ct=Object.defineProperty;var Pi=Object.getOwnPropertyDescriptor;var Qa=Object.getOwnPropertyNames;var Xa=Object.prototype.hasOwnProperty;var ji=(s,t)=>(t=Symbol[s])?t:Symbol.for("Symbol."+s),At=s=>{throw TypeError(s)};var Oi=(s,t,e)=>t in s?Ct(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e;var Bi=(s,t)=>Ct(s,"name",{value:t,configurable:!0});var x=(s,t)=>()=>(s&&(t=s(s=0)),t);var Ka=(s,t)=>()=>(t||s((t={exports:{}}).exports,t),t.exports),M=(s,t)=>{for(var e in t)Ct(s,e,{get:t[e],enumerable:!0})},Ja=(s,t,e,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Qa(t))!Xa.call(s,n)&&n!==e&&Ct(s,n,{get:()=>t[n],enumerable:!(r=Pi(t,n))||r.enumerable});return s};var O=s=>Ja(Ct({},"__esModule",{value:!0}),s);var I=s=>{var t;return[,,,Ha((t=s==null?void 0:s[ji("metadata")])!=null?t:null)]},qi=["class","method","getter","setter","accessor","field","value","get","set"],er=s=>s!==void 0&&typeof s!="function"?At("Function expected"):s,Ya=(s,t,e,r,n)=>({kind:qi[s],name:t,metadata:r,addInitializer:i=>e._?At("Already initialized"):n.push(er(i||null))}),tr=(s,t)=>Oi(t,ji("metadata"),s[3]),E=(s,t,e,r)=>{for(var n=0,i=s[t>>1],o=i&&i.length;n<o;n++)t&1?i[n].call(e):r=i[n].call(e,r);return r},N=(s,t,e,r,n,i)=>{var o,a,l,p,u,d=t&7,c=!!(t&8),f=!!(t&16),m=d>3?s.length+1:d?c?1:2:0,C=qi[d+5],A=d>3&&(s[m-1]=[]),S=s[m]||(s[m]=[]),k=d&&(!f&&!c&&(n=n.prototype),d<5&&(d>3||!f)&&Pi(d<4?n:{get[e](){return g(this,i)},set[e](T){return b(this,i,T)}},e));d?f&&d<4&&Bi(i,(d>2?"set ":d>1?"get ":"")+e):Bi(n,e);for(var y=r.length-1;y>=0;y--)p=Ya(d,e,l={},s[3],S),d&&(p.static=c,p.private=f,u=p.access={has:f?T=>Za(n,T):T=>e in T},d^3&&(u.get=f?T=>(d^1?g:$)(T,n,d^4?i:k.get):T=>T[e]),d>2&&(u.set=f?(T,w)=>b(T,n,w,d^4?i:k.set):(T,w)=>T[e]=w)),a=(0,r[y])(d?d<4?f?i:k[C]:d>4?void 0:{get:k.get,set:k.set}:n,p),l._=1,d^4||a===void 0?er(a)&&(d>4?A.unshift(a):d?f?i=a:k[C]=a:n=a):typeof a!="object"||a===null?At("Object expected"):(er(o=a.get)&&(k.get=o),er(o=a.set)&&(k.set=o),er(o=a.init)&&A.unshift(o));return d||tr(s,n),k&&Ct(n,e,k),f?d^4?i:k:n},Z=(s,t,e)=>Oi(s,typeof t!="symbol"?t+"":t,e),xn=(s,t,e)=>t.has(s)||At("Cannot "+e),Za=(s,t)=>Object(t)!==t?At('Cannot use the "in" operator on this value'):s.has(t),g=(s,t,e)=>(xn(s,t,"read from private field"),e?e.call(s):t.get(s)),h=(s,t,e)=>t.has(s)?At("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(s):t.set(s,e),b=(s,t,e,r)=>(xn(s,t,"write to private field"),r?r.call(s,e):t.set(s,e),e),$=(s,t,e)=>(xn(s,t,"access private method"),e);var Or=(s,t,e,r)=>({set _(n){b(s,t,n,e)},get _(){return g(s,t,r)}});function se(s,t,e){return e===1?s.replace(/\0(\d+)g\x7F/gu,(r,n)=>se(String(t[n]),t,2)):e===2?s.replace(/\0(\d+)n\x7F/gu,(r,n)=>String(t[n])):s.replace(/\0(\d+)\x7F/gu,(r,n)=>t[n])}var be,_i,Je,Ye,ve,rr,Wi,z,ge,el,tl,qr,bn,Mi,rl,nl,Ze,Ce,J=x(()=>{"use strict";be=String.raw` \xA0\u1680\u2000-\u200A\u202F\u205F\u3000`,_i=String.raw`[^[\]<>"\0-\x1F\x7F${be}\uFFFD]`,Je=String.raw`(?:\[[\da-f:.]+\]|${_i})`,Ye=String.raw`(?:${_i}|\0\d+[cn!~]\x7F)*`,ve=s=>s.trim().toLowerCase();rr=(s,t)=>e=>e.replace(s,t),Wi=rr(/[\0\x7F]|\r$/gmu,""),z=rr(/\0\d+[cn]\x7F/gu,""),ge=(s,t="")=>s.map(e=>typeof e=="string"?e:e.text()).join(t),el={lt:"<",gt:">",lbrack:"[",rbrack:"]",lbrace:"{",rbrace:"}",nbsp:" ",amp:"&",quot:'"'},tl=rr(/&(?:#(\d+|[Xx][\da-fA-F]+)|([lg]t|[LG]T|[lr]brac[ke]|nbsp|amp|AMP|quot|QUOT));/gu,(s,t,e)=>t?String.fromCodePoint(+((/^x/iu.test(t)?"0":"")+t)):el[e.toLowerCase()]),bn=s=>(qr!=null||(qr=tl),qr(s)),Mi=rr(/&#(\d+|x[\da-f]+);/giu,(s,t)=>String.fromCodePoint(+((/^x/iu.test(t)?"0":"")+t))),rl={"&":"amp","<":"lt",">":"gt",'"':"quot","\n":"#10"},nl=(s=/[&<>"{}[\]|]/gu)=>rr(s,t=>`&${rl[t]};`),Ze=nl(/[&<>]/gu),Ce=(s,t={})=>{let{pre:e="",post:r="",sep:n=""}=t;return e+s.map(i=>i.print()).join(n)+r}});var Ui=Ka((Od,il)=>{il.exports={ext:[],html:[["b","bdi","del","i","ins","u","font","big","small","sub","sup","h1","h2","h3","h4","h5","h6","cite","code","em","s","strike","strong","tt","var","div","center","blockquote","ol","ul","dl","table","caption","pre","ruby","rb","rp","rt","rtc","p","span","abbr","dfn","kbd","samp","data","time","mark","tr","td","th","q","bdo"],["li","dt","dd"],["br","wbr","hr","meta","link"]],namespaces:{"0":"","6":"File","10":"Template","14":"Category","828":"Module"},nsid:{"":0,file:6,template:10,category:14,module:828},functionHook:["msgnw"],variable:["!","=","pageid","articlepath","server","servername","scriptpath","stylepath"],parserFunction:[{msgnw:"msgnw",pageid:"pageid",articlepath:"articlepath",server:"server",servername:"servername",scriptpath:"scriptpath",stylepath:"stylepath"},{"!":"!","=":"="},["msg","raw"],["subst","safesubst"]],doubleUnderscore:[[],[],{},{}],protocol:"bitcoin:|ftp://|ftps://|geo:|git://|gopher://|http://|https://|irc://|ircs://|magnet:|mailto:|matrix:|mms://|news:|nntp://|redis://|sftp://|sip:|sips:|sms:|ssh://|svn://|tel:|telnet://|urn:|wikipedia://|worldwind://|xmpp:|commonsfinder://",interwiki:[],img:{},redirection:["#redirect"],variants:[]}});var Di,yn,Tn=x(()=>{"use strict";Di=new Set(["alt","link","lang","page","caption"]),yn=Ui()});function je(s){let t=new Map,e=new WeakMap;return r=>{let n=typeof r=="string"?t:e;if(n.has(r)){let o=n.get(r);return o.lastIndex=0,o}let i=s(r);return n.set(r,i),i}}var kn,nr=x(()=>{"use strict";kn=s=>decodeURIComponent(s.replace(/%(?![\da-f]{2})/giu,"%25"))});var sl,ol,_r,Oe,zi,ir=x(()=>{"use strict";Ae();ue();sl=new Set(["tr","td","th","caption"]),ol=new Set(["Template:!!","Template:!-"]),_r=s=>{let t=s.childNodes.find(e=>e.text().trim());if(!t||t.type==="text"&&t.data.trim().startsWith("!")||t.is("magic-word")&&t.name==="!"||t.is("template")&&ol.has(t.name)||t.is("html")&&sl.has(t.name))return!1;if(t.is("arg"))return t.length>1&&_r(t.childNodes[1]);if(t.is("magic-word"))try{let e=t.getPossibleValues().map(_r);return e.includes(2)?2:e.includes(1)&&1}catch{}return t.is("template")||t.is("magic-word")&&t.name==="invoke"?1:2},Oe=(s,t,e,r)=>{if(s&&(r||W.viewOnly&&s[0]===ee.rev))return s[1];let n=t();return(r||W.viewOnly)&&e([ee.rev,n]),n},zi=(s,t)=>s==="ol"&&t==="type"?["1","a","A","i","I"]:s==="th"&&t==="scope"?["row","col","rowgroup","colgroup"]:t==="dir"?["ltr","rtl","auto"]:t==="aria-hidden"?["true","false"]:[]});var al,Gi,Vi=x(()=>{"use strict";al=s=>{if(s.includes("#")){let t=s.indexOf("#"),e=s.slice(0,t),r=s.slice(t+1);return(n,i)=>(t===0||n===e)&&i===r}return t=>t===s},Gi=(s,t,e)=>{if(s=s.trim(),!s)return(()=>!0);let r=s.split(",").map(n=>n.trim()).filter(n=>n!=="").map(al);return(({type:n,name:i})=>r.some(o=>o(n,i)))}});var St,Wr=x(()=>{"use strict";ir();St=(s=!0)=>t=>{let e=new WeakMap;return function(...r){return Oe(e.get(this),()=>t.apply(this,r),n=>{e.set(this,n)},s)}}});var Hi,Qi=x(()=>{"use strict";Hi=s=>{class t extends s{get firstChild(){return this.childNodes[0]}get lastChild(){return this.childNodes[this.childNodes.length-1]}get offsetHeight(){}get offsetWidth(){}}return t}});var Xi,Ki,or,wt,Et,ar,qe,Nt,sr,ye,vn=x(()=>{"use strict";ir();Ae();Wr();Qi();ue();Ki=[Hi],Xi=[St(!1)];ye=class{constructor(){E(sr,5,this);Z(this,"childNodes",[]);h(this,or);h(this,wt);h(this,Et);h(this,ar);h(this,qe);h(this,Nt,{})}get parentNode(){return g(this,or)}get nextSibling(){return g(this,wt)}get previousSibling(){return g(this,Et)}getChildNodes(){let{childNodes:t}=this;return Object.isFrozen(t)?[...t]:t}getAttribute(t){return t==="padding"?0:this[t]}setAttribute(t,e){switch(t){case"parentNode":b(this,or,e),e||(b(this,wt,void 0),b(this,Et,void 0));break;case"nextSibling":b(this,wt,e);break;case"previousSibling":b(this,Et,e);break;case"aIndex":break;default:this[t]=e}}getRootNode(){return Oe(g(this,ar),()=>{var t,e;return(e=(t=this.parentNode)==null?void 0:t.getRootNode())!=null?e:this},t=>{let[,e]=t;e.type==="root"&&b(this,ar,t)})}indexFromPos(t,e){}posFromIndex(t){}getDimension(){}getGaps(t){return 0}getRelativeIndex(t){if(t===void 0){let{parentNode:e}=this;return e?e.getRelativeIndex(e.childNodes.indexOf(this)):0}return Oe(g(this,Nt)[t],()=>{var o;let{childNodes:e}=this,r=((o=g(this,qe))==null?void 0:o[0])===ee.rev&&g(this,qe)[1],n=t+(t<0?e.length:0),i=this.getAttribute("padding");for(let a=0;a<n;a++)W.viewOnly&&(g(this,Nt)[a]=[ee.rev,i],r!==!1&&b(e[a],qe,[ee.rev,r+i])),i+=e[a].toString().length+this.getGaps(a);return i},e=>{g(this,Nt)[t]=e})}getAbsoluteIndex(){return Oe(g(this,qe),()=>{let{parentNode:t}=this;return t?t.getAbsoluteIndex()+this.getRelativeIndex():0},t=>{b(this,qe,t)})}getBoundingClientRect(){this.lspError("AstNode.getBoundingClientRect")}is(t){return this.type===t}getLines(){}seal(t,e){}lspError(t){throw new Error(`${t} method is only available in the LSP version!`)}};sr=I(null),or=new WeakMap,wt=new WeakMap,Et=new WeakMap,ar=new WeakMap,qe=new WeakMap,Nt=new WeakMap,N(sr,1,"getLines",Xi,ye),ye=N(sr,0,"AstNode",Ki,ye),E(sr,1,ye)});var Ji,Yi=x(()=>{"use strict";Ji=s=>{}});var Zi,Cn,ll,et,es=x(()=>{"use strict";J();Ae();Vi();vn();Yi();Zi=[Ji];et=class extends(ll=ye){get length(){return this.childNodes.length}text(t){return ge(this.childNodes,t)}removeAt(t){this.lspError("AstElement.removeAt")}insertAt(t,e=this.length){return Mr(this,e,0,[t]),t}closest(t){let e=Gi(t,this),{parentNode:r}=this;for(;r;){if(e(r))return r;({parentNode:r}=r)}}isInside(t){var e;return((e=this.closest(`${t},ext`))==null?void 0:e.type)===t}append(...t){this.safeAppend(t)}safeAppend(t){for(let e of t)this.insertAt(e)}safeReplaceChildren(t){}setText(t,e=0){e+=e<0?this.length:0;let r=this.childNodes[e],{data:n}=r;return r.replaceData(t),n}toString(t,e=""){return this.childNodes.map(r=>r.toString(t)).join(e)}caretPositionFromIndex(t){this.lspError("AstElement.caretPositionFromIndex")}elementFromIndex(t){this.lspError("AstElement.elementFromIndex")}elementFromPoint(t,e){this.lspError("AstElement.elementFromPoint")}lint(t=this.getAbsoluteIndex(),e){}print(t={}){{let e=t.class;return this.toString()?(e===""?"":`<span class="wpb-${e!=null?e:this.type}${this.getAttribute("invalid")?" wpb-invalid":""}">`)+Ce(this.childNodes,t)+(e===""?"":"</span>"):""}}json(t,e=1/0,r=this.getAbsoluteIndex()){}};Cn=I(ll),et=N(Cn,0,"AstElement",Zi,et),E(Cn,1,et)});var Ur,ts,lr,rs=x(()=>{"use strict";J();vn();lr=class extends ye{constructor(e){super();h(this,Ur);Z(this,"data","");this.data=e}get type(){return"text"}toString(e){var r;return e&&!((r=this.parentNode)!=null&&r.getAttribute("built"))?z(this.data):this.data}text(){return this.data}lint(e=this.getAbsoluteIndex(),r){}replaceData(e){$(this,Ur,ts).call(this,e)}splitText(e){this.lspError("AstText.splitText")}escape(){}print(){return Ze(this.data)}};Ur=new WeakSet,ts=function(e){this.setAttribute("data",e)}});var oe,_e=x(()=>{"use strict";oe=(s=!0,t=!0)=>e=>{class r extends e{text(){return""}lint(i){}}return r}});var j,ne=x(()=>{"use strict";j=s=>{}});var dr,te,We=x(()=>{"use strict";B();te=class extends v{constructor(e,r,n,i,o){super(e,n,i,o);h(this,dr);b(this,dr,r)}get type(){return g(this,dr)}lint(e=this.getAbsoluteIndex()){}};dr=new WeakMap});var Y,Te=x(()=>{"use strict";Y=({length:s})=>t=>{class e extends t{getAttribute(n){return n==="padding"?s:super.getAttribute(n)}}return e}});var It,H,Me=x(()=>{"use strict";B();H=class extends v{constructor(e,r,n,i,o){super(e,n,i,o);h(this,It);b(this,It,r)}get type(){return g(this,It)}set type(e){b(this,It,e)}getAttribute(e){var r;return e==="invalid"?this.type==="converter-flag"&&!!((r=this.parentNode)!=null&&r.isInvalidFlag(this)):super.getAttribute(e)}};It=new WeakMap});var ns,tt,me,rt,Dr,is,An,dl,ie,$t=x(()=>{"use strict";Te();ne();ue();B();Me();ns=[j,Y("[[")];ie=class extends(dl=v){constructor(e,r,n=W.getConfig(),i=[],o="|"){super(void 0,n,i,{});h(this,Dr);h(this,tt,!0);h(this,me);h(this,rt);if(this.insertAt(new H(e,"link-target",n,i)),r!==void 0){let a=new v(r,{...n,excludes:[...n.excludes,"list"]},i);a.type="link-text",a.setAttribute("stage",10),this.insertAt(a)}b(this,me,o)}get link(){}get fragment(){}afterBuild(){b(this,rt,this.getTitle()),g(this,me).includes("\0")&&b(this,me,this.buildFromStr(g(this,me),0)),$(this,Dr,is).call(this),super.afterBuild()}setAttribute(e,r){e==="bracket"?b(this,tt,r):e==="title"?b(this,rt,r):super.setAttribute(e,r)}toString(e){let r=super.toString(e,g(this,me));return g(this,tt)?`[[${r}]]`:r}text(){let e=super.text("|");return g(this,tt)?`[[${e}]]`:e}getAttribute(e){return e==="title"?g(this,rt):super.getAttribute(e)}getGaps(e){return e===0?g(this,me).length:1}lint(e=this.getAbsoluteIndex(),r){}getTitle(e,r){return this.normalizeTitle(this.firstChild.text(),0,{halfParsed:r,temporary:e,decode:!0,selfLink:!0})}print(){return super.print(g(this,tt)?{pre:"[[",post:"]]",sep:g(this,me)}:{sep:g(this,me)})}json(e,r,n=this.getAbsoluteIndex()){}};An=I(dl),tt=new WeakMap,me=new WeakMap,rt=new WeakMap,Dr=new WeakSet,is=function(){this.type!=="ext-inner"&&this.setAttribute("name",g(this,rt).title)},ie=N(An,0,"LinkBaseToken",ns,ie),E(An,1,ie)});var ss,Sn,gl,Q,Ue=x(()=>{"use strict";ne();B();ss=[j];Q=class extends(gl=v){get innerText(){return this.firstChild.data}constructor(t="",e,r){super(t,e,r)}};Sn=I(gl),Q=N(Sn,0,"NowikiBaseToken",ss,Q),E(Sn,1,Q)});var os,wn,ul,X,nt=x(()=>{"use strict";_e();Ue();os=[oe(!1)];X=class extends(ul=Q){get type(){return"noinclude"}toString(t){return t?"":super.toString()}lint(t=this.getAbsoluteIndex()){}};wn=I(ul),X=N(wn,0,"NoincludeToken",os,X),E(wn,1,X)});var zr,as=x(()=>{"use strict";$t();nt();zr=class extends ie{get type(){return"redirect-target"}constructor(t,e,r,n){super(t,void 0,r,n),e!==void 0&&this.insertAt(new X(e,r,n))}getTitle(){return this.normalizeTitle(this.firstChild.toString(),0,{halfParsed:!0,decode:!0,page:""})}lint(t=this.getAbsoluteIndex()){}}});var ls,st,Lt,En,pl,it,ds=x(()=>{"use strict";_e();ne();B();We();as();ls=[oe(!1,!1),j];it=class extends(pl=v){constructor(e,r,n,i,o,a,l=[]){super(void 0,a,l);h(this,st);h(this,Lt);b(this,st,e),b(this,Lt,o),this.append(new te(r,"redirect-syntax",a,l),new zr(n,i==null?void 0:i.slice(1),a,l))}get type(){return"redirect"}getAttribute(e){return e==="padding"?g(this,st).length:super.getAttribute(e)}toString(e){return g(this,st)+super.toString(e)+g(this,Lt)}lint(e=this.getAbsoluteIndex()){}print(){return super.print({pre:g(this,st),post:g(this,Lt)})}};En=I(pl),st=new WeakMap,Lt=new WeakMap,it=N(En,0,"RedirectToken",ls,it),E(En,1,it)});var gs={};M(gs,{parseRedirect:()=>cl});var cl,us=x(()=>{"use strict";ue();ds();cl=(s,t,e)=>{var n;(n=t.regexRedirect)!=null||(t.regexRedirect=new RegExp(String.raw`^(\s*)((?:${t.redirection.join("|")})\s*(?::\s*)?)\[\[([^\n|\]]+)(\|.*?)?\]\](\s*)`,"iu"));let r=t.regexRedirect.exec(s);return r&&W.normalizeTitle(r[3],0,!1,t,{halfParsed:!0,temporary:!0,decode:!0,page:""}).valid?(s=`\0${e.length}o${s.slice(r[0].length)}`,new it(...r.slice(1),t,e),s):!1}});var ps,Nn,fl,ot,cs=x(()=>{"use strict";Te();ne();B();ps=[j,Y("<onlyinclude>")];ot=class extends(fl=v){get type(){return"onlyinclude"}toString(t){return`<onlyinclude>${super.toString(t)}</onlyinclude>`}isPlain(){return!0}print(){return super.print({pre:'<span class="wpb-ext"><onlyinclude></span>',post:'<span class="wpb-ext"></onlyinclude></span>'})}};Nn=I(fl),ot=N(Nn,0,"OnlyincludeToken",ps,ot),E(Nn,1,ot)});var De,gr=x(()=>{"use strict";De=(s=1)=>t=>{class e extends t{getGaps(){return s}}return e}});var fs,ze,Se,In,ml,he,Gr=x(()=>{"use strict";gr();ne();B();fs=[De(),j];he=class extends(ml=v){constructor(e,r,n,i,o,a=[]){super(void 0,o);h(this,ze);h(this,Se);Z(this,"closed");this.setAttribute("name",e.toLowerCase()),b(this,ze,[e,i||e]),this.closed=i!=="",b(this,Se,i===void 0),this.append(r,n);let l=typeof r=="string"?-1:a.indexOf(r);a.splice(l===-1?1/0:l,0,this)}get innerText(){return g(this,Se)?void 0:this.lastChild.text()}get selfClosing(){return g(this,Se)}toString(e){let{firstChild:r,lastChild:n}=this,[i,o]=g(this,ze);return g(this,Se)?`<${i}${r.toString(e)}/>`:`<${i}${r.toString(e)}>${n.toString(e)}${this.closed?`</${o}>`:""}`}text(){let[e,r]=g(this,ze);return g(this,Se)?`<${e}${this.firstChild.text()}/>`:`<${e}${super.text(">")}${this.closed?`</${r}>`:""}`}getAttribute(e){return e==="padding"?g(this,ze)[0].length+1:super.getAttribute(e)}print(){{let[e,r]=g(this,ze);return super.print(g(this,Se)?{pre:`<${e}`,post:"/>"}:{pre:`<${e}`,sep:">",post:this.closed?`</${r}>`:""})}}json(e,r,n=this.getAbsoluteIndex()){}};In=I(ml),ze=new WeakMap,Se=new WeakMap,he=N(In,0,"TagPairToken",fs,he),E(In,1,he)});var ms,$n,hl,at,hs=x(()=>{"use strict";_e();Gr();ms=[oe(!1)];at=class extends(hl=he){get type(){return"include"}constructor(t,e="",r,n,i,o){super(t,e,r!=null?r:"",r===void 0||n!=null?n:"",i,o)}toString(t){return t?"":super.toString()}lint(t=this.getAbsoluteIndex()){}};$n=I(hl),at=N($n,0,"IncludeToken",ms,at),E($n,1,at)});var Ft,Vr=x(()=>{"use strict";Ft=(s=0)=>t=>{}});var pe,xs,bs,ys,Ss,xl,Ts,ks,bl,yl,Ln,vs,Cs,As,lt,ws,Es,Ns,Is=x(()=>{"use strict";pe=new Set(["align"]),xs=new Set(["cite"]),bs=new Set(["cite","datetime"]),ys=new Set(["width"]),Ss=new Set(["bgcolor","align","valign"]),xl=new Set([...Ss,"axis","height","nowrap","width"]),Ts=new Set([...xl,"abbr","headers","scope","rowspan","colspan"]),ks=new Set(["type"]),bl=new Set(["summary","align","bgcolor","cellpadding","cellspacing","frame","rules","width"]),yl=new Set(["clear"]),Ln=new Set(["id","qid","forcemathmode","type","display"]),vs=new Set(["enclose","inline","lang","line","linelinks","style","class","id","dir","copy","highlight","start"]),Cs=new Set(["weight"]),As=new Set(["width","height","zoom","latitude","longitude","align","mapstyle","lang","alt","text"]),lt=new Set,ws=new Set(["id","class","style","lang","dir","title","tabindex","aria-describedby","aria-flowto","aria-hidden","aria-label","aria-labelledby","aria-level","aria-owns","role","about","property","resource","datatype","typeof","itemid","itemprop","itemref","itemscope","itemtype"]),Es={div:pe,h1:pe,h2:pe,h3:pe,h4:pe,h5:pe,h6:pe,blockquote:xs,q:xs,p:pe,br:yl,pre:ys,ins:bs,del:bs,ul:ks,ol:new Set(["type","start","reversed"]),li:new Set(["type","value"]),table:new Set([...bl,"border"]),caption:pe,tr:Ss,td:Ts,th:Ts,font:new Set(["size","color","face"]),hr:ys,data:new Set(["value"]),time:new Set(["datetime"]),meta:new Set(["itemprop","content"]),link:new Set(["itemprop","href","title"]),gallery:ks,poem:pe,categorytree:pe,combooption:pe,img:new Set(["alt","src","width","height","loading","srcset"])},Ns={pre:new Set(["format"]),gallery:new Set(["mode","showfilename","caption","perrow","widths","heights","showthumbnails"]),poem:new Set(["compact"]),categorytree:new Set(["hideroot","onlyroot","depth","mode","hideprefix","namespaces","showcount","notranslations"]),combooption:new Set(["name","for","inline"]),nowiki:lt,indicator:new Set(["name"]),langconvert:new Set(["from","to"]),ref:new Set(["group","name","follow","dir","details"]),references:new Set(["group","responsive"]),charinsert:new Set(["label"]),choose:new Set(["uncached","before","after"]),option:Cs,choicetemplate:Cs,imagemap:lt,inputbox:lt,templatestyles:new Set(["src","wrapper"]),dynamicpagelist:lt,poll:new Set(["id","show-results-before-voting"]),score:new Set(["line_width_inches","lang","override_midi","raw","note-language","override_audio","override_ogg","sound","vorbis"]),seo:new Set(["title","title_mode","title_separator","keywords","description","robots","google_bot","image","image_width","image_height","image_alt","type","site_name","locale","section","author","published_time","twitter_site"]),tab:new Set(["nested","name","index","class","block","inline","openname","closename","collapsed","dropdown","style","bgcolor","container","id","title"]),tabs:new Set(["plain","class","container","id","title","style"]),combobox:new Set(["placeholder","value","id","class","text","dropdown","style"]),math:new Set([...Ln,"chem"]),chem:Ln,ce:Ln,hiero:lt,phonos:new Set(["ipa","class","text","lang","wikibase","file"]),section:new Set(["begin","end"]),source:vs,syntaxhighlight:vs,templatedata:lt,timeline:new Set(["method","font"]),quiz:new Set(["display","shuffleanswers","points","shuffle","case"]),languages:lt,mapframe:new Set([...As,"frameless"]),maplink:new Set([...As,"class"]),rss:new Set(["template","templatename","max","highlight","filter","filterout","reverse","date","item-max-length"]),"page-collection":new Set(["lang","name","description","end-date"])}});var Tl,kl,vl,Cl,pr,Rt,re,dt,Bt,$s,Ls,ur,Fs=x(()=>{"use strict";ir();J();Is();B();Me();Tl=/expression|(?:accelerator|-o-link(?:-source)?|-o-replace)\s*:|(?:url|src|image(?:-set)?)\s*\(|attr\s*\([^)]+[\s,]url/u,kl=/(?:^|\s|\*\/)(?:java|vb)script(?:\W|$)/iu,vl=new Set(["ext","arg","magic-word","template"]),Cl=new Set(["about","property","resource","datatype","typeof","itemid","itemprop","itemref","itemscope","itemtype"]),ur=class extends v{constructor(e,r,n,i,o,a="",l,p=[]){let u=new H(n,"attr-key",o,p),d;if(n==="title"||r==="img"&&n==="alt")d=new v(l,o,p,{}),d.type="attr-value",d.setAttribute("stage",10);else if(r==="gallery"&&n==="caption"||r==="ref"&&n==="details"||(r==="mapframe"||r==="maplink")&&n==="text"||r==="choose"&&(n==="before"||n==="after")){let c={...o,excludes:[...o.excludes,"heading","html","table","hr","list"]};d=new v(l,c,p,{}),d.type="attr-value",d.setAttribute("stage",1)}else d=new H(l,"attr-value",o,p,{});super(void 0,o,p);h(this,Bt);h(this,pr);h(this,Rt);h(this,re);h(this,dt);b(this,pr,e),this.append(u,d),b(this,re,a),b(this,dt,[...i]),b(this,Rt,r),this.setAttribute("name",ve(z(n)))}get type(){return g(this,pr)}get tag(){return g(this,Rt)}get balanced(){}afterBuild(){g(this,re).includes("\0")&&b(this,re,this.buildFromStr(g(this,re),0)),this.parentNode&&b(this,Rt,this.parentNode.name),$(this,Bt,$s).call(this),super.afterBuild()}toString(e){let[r="",n=""]=g(this,dt);return g(this,re)?super.toString(e,g(this,re)+r)+n:this.firstChild.toString(e)}text(){return g(this,re)?`${super.text(`${g(this,re).trim()}"`)}"`:this.firstChild.text()}getGaps(){var e,r;return g(this,re)?g(this,re).length+((r=(e=g(this,dt)[0])==null?void 0:e.length)!=null?r:0):0}lint(e=this.getAbsoluteIndex(),r){}getValue(){return g(this,re)?this.lastChild.text().trim():this.type==="ext-attr"||""}escape(){}getAttribute(e){return e==="invalid"?$(this,Bt,Ls).call(this):super.getAttribute(e)}print(){{let[e="",r=""]=g(this,dt);return g(this,re)?super.print({sep:Ze(g(this,re))+e,post:r}):super.print()}}json(e,r,n=this.getAbsoluteIndex()){}};pr=new WeakMap,Rt=new WeakMap,re=new WeakMap,dt=new WeakMap,Bt=new WeakSet,$s=function(){this.setAttribute("name",ve(this.firstChild.text()))},Ls=function(e,r){let{firstChild:n,lastChild:i,type:o,name:a,tag:l,parentNode:p}=this,u=!i.childNodes.some(({type:k})=>vl.has(k)),d=this.getValue(),c=Ns[l],f=Es[l],{length:m}=this.toString(),C="illegal-attr",A,S;if(!(c!=null&&c.has(a))&&!(f!=null&&f.has(a))&&(o==="ext-attr"?c||f:!/\{\{[^{]+\}\}/u.test(a))&&(o==="ext-attr"&&!f||!/^(?:xmlns:[\w:.-]+|data-(?!ooui|mw|parsoid)[^:_]*)$/u.test(a)&&(l==="meta"||l==="link"||!ws.has(a)))||(a==="itemtype"||a==="itemid"||a==="itemref")&&!(p!=null&&p.hasAttr("itemscope"))){if(e===void 0)return!0}else if(a==="style"&&typeof d=="string"&&Tl.test(d)){if(e===void 0)return!0}else if(a==="tabindex"&&typeof d=="string"&&d!=="0"){if(e===void 0)return!0}else if(typeof d=="string"&&((/^xmlns:[\w:.-]+$/u.test(a)||Cl.has(a))&&kl.test(d)||u&&(a==="href"||o==="ext-attr"&&l==="img"&&a==="src")&&!new RegExp(String.raw`^(?:${this.getAttribute("config").protocol}|//)\S+$`,"iu").test(d))){if(e===void 0)return!0}else if(u&&o!=="ext-attr"){let k=zi(l,a),y=String(d).toLowerCase();if(k.length>0&&k.every(T=>T!==y)&&e===void 0)return!0}return!1}});var Rs,Al,cr,fr,Fn,Ge,Hr=x(()=>{"use strict";J();B();Me();Fs();Rs=s=>s.slice(0,-1),Al=s=>`${Rs(s)}-dirty`,Ge=class extends v{constructor(e,r,n,i,o=[]){super(void 0,i,o,{});h(this,fr);h(this,cr);if(b(this,cr,r),this.setAttribute("name",n),e){let a=/([^\s/](?:(?!\0\d+~\x7F)[^\s/=])*)(?:((?:\s(?:\s|\0\d+[cn]\x7F)*)?(?:=|\0\d+~\x7F)(?:\s|\0\d+[cn]\x7F)*)(?:(["'])([\s\S]*?)(\3|$)|(\S*)))?/gu,l="",p=a.exec(e),u=0,d=()=>{l&&(super.insertAt(new H(l,Al(r),i,o)),l="")};for(;p;){let{index:c,0:f,1:m,2:C,3:A,4:S,5:k,6:y}=p;if(l+=e.slice(u,c),/^(?:[\w:]|\0\d+t\x7F)(?:[\w:.-]|\0\d+t\x7F)*$/u.test(z(m).trim())){let T=S!=null?S:y,w=[A,k],F=new ur(Rs(r),n,m,w,i,C,T,o);d(),super.insertAt(F)}else l+=f;({lastIndex:u}=a),p=a.exec(e)}l+=e.slice(u),d()}}get type(){return g(this,cr)}afterBuild(){let{parentNode:e}=this;e!=null&&e.is("td")&&this.setAttribute("name",e.subtype),super.afterBuild()}getAttrTokens(e){return this.childNodes.filter(r=>r instanceof ur&&(!e||r.name===ve(e)))}hasAttr(e){return this.getAttrTokens(e).length>0}getAttrToken(e){}getAttr(e){}lint(e=this.getAbsoluteIndex(),r){}escape(){}getAttribute(e){return e==="invalid"?$(this,fr,Fn).call(this):super.getAttribute(e)}print(){return this.toString()?`<span class="wpb-${this.type}${$(this,fr,Fn).call(this)?" wpb-invalid":""}">${this.childNodes.map(e=>e.print(e instanceof H?{class:e.toString().trim()&&"attr-dirty"}:void 0)).join("")}</span>`:""}};cr=new WeakMap,fr=new WeakSet,Fn=function(){let{parentNode:e}=this;return(e==null?void 0:e.type)==="html"&&e.closing&&this.text().trim()!==""}});var Bs={};M(Bs,{PreToken:()=>Rn});var Rn,Ps=x(()=>{"use strict";B();nt();Rn=class extends v{get type(){return"ext-inner"}constructor(t,e,r=[]){if(t){let n=/<nowiki>/giu,i=/<\/nowiki>/giu,{length:o}=n.source,a=n.exec(t);a&&(i.lastIndex=a.index+o);let l=i.exec(t),p=0,u="";for(;a&&l;)new X(a[0],e,r,!0),new X(l[0],e,r,!0),u+=`${t.slice(p,a.index)}\0${r.length-1}n${t.slice(a.index+o,l.index)}\0${r.length}n`,p=l.index+o+1,n.lastIndex=p,a=n.exec(t),a&&(i.lastIndex=a.index+o),l=i.exec(t);t=u+t.slice(p)}super(t,e,r,{}),this.setAttribute("stage",10)}isPlain(){return!0}lint(t=this.getAbsoluteIndex()){}}});var Ve,Qr=x(()=>{"use strict";B();Ve=class extends v{get type(){return"ext-inner"}toString(t){return super.toString(t,`
|
|
1
|
+
"use strict";(()=>{var Ka=Object.create;var At=Object.defineProperty;var Pi=Object.getOwnPropertyDescriptor;var Qa=Object.getOwnPropertyNames;var Xa=Object.prototype.hasOwnProperty;var ji=(s,t)=>(t=Symbol[s])?t:Symbol.for("Symbol."+s),Ct=s=>{throw TypeError(s)};var qi=(s,t,e)=>t in s?At(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e;var Bi=(s,t)=>At(s,"name",{value:t,configurable:!0});var x=(s,t)=>()=>(s&&(t=s(s=0)),t);var Ja=(s,t)=>()=>(t||s((t={exports:{}}).exports,t),t.exports),W=(s,t)=>{for(var e in t)At(s,e,{get:t[e],enumerable:!0})},Ya=(s,t,e,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Qa(t))!Xa.call(s,n)&&n!==e&&At(s,n,{get:()=>t[n],enumerable:!(r=Pi(t,n))||r.enumerable});return s};var q=s=>Ya(At({},"__esModule",{value:!0}),s);var I=s=>{var t;return[,,,Ka((t=s==null?void 0:s[ji("metadata")])!=null?t:null)]},Oi=["class","method","getter","setter","accessor","field","value","get","set"],er=s=>s!==void 0&&typeof s!="function"?Ct("Function expected"):s,Za=(s,t,e,r,n)=>({kind:Oi[s],name:t,metadata:r,addInitializer:i=>e._?Ct("Already initialized"):n.push(er(i||null))}),tr=(s,t)=>qi(t,ji("metadata"),s[3]),E=(s,t,e,r)=>{for(var n=0,i=s[t>>1],o=i&&i.length;n<o;n++)t&1?i[n].call(e):r=i[n].call(e,r);return r},N=(s,t,e,r,n,i)=>{var o,a,l,p,u,d=t&7,c=!!(t&8),f=!!(t&16),m=d>3?s.length+1:d?c?1:2:0,A=Oi[d+5],C=d>3&&(s[m-1]=[]),S=s[m]||(s[m]=[]),k=d&&(!f&&!c&&(n=n.prototype),d<5&&(d>3||!f)&&Pi(d<4?n:{get[e](){return g(this,i)},set[e](T){return b(this,i,T)}},e));d?f&&d<4&&Bi(i,(d>2?"set ":d>1?"get ":"")+e):Bi(n,e);for(var y=r.length-1;y>=0;y--)p=Za(d,e,l={},s[3],S),d&&(p.static=c,p.private=f,u=p.access={has:f?T=>el(n,T):T=>e in T},d^3&&(u.get=f?T=>(d^1?g:$)(T,n,d^4?i:k.get):T=>T[e]),d>2&&(u.set=f?(T,w)=>b(T,n,w,d^4?i:k.set):(T,w)=>T[e]=w)),a=(0,r[y])(d?d<4?f?i:k[A]:d>4?void 0:{get:k.get,set:k.set}:n,p),l._=1,d^4||a===void 0?er(a)&&(d>4?C.unshift(a):d?f?i=a:k[A]=a:n=a):typeof a!="object"||a===null?Ct("Object expected"):(er(o=a.get)&&(k.get=o),er(o=a.set)&&(k.set=o),er(o=a.init)&&C.unshift(o));return d||tr(s,n),k&&At(n,e,k),f?d^4?i:k:n},Z=(s,t,e)=>qi(s,typeof t!="symbol"?t+"":t,e),xn=(s,t,e)=>t.has(s)||Ct("Cannot "+e),el=(s,t)=>Object(t)!==t?Ct('Cannot use the "in" operator on this value'):s.has(t),g=(s,t,e)=>(xn(s,t,"read from private field"),e?e.call(s):t.get(s)),h=(s,t,e)=>t.has(s)?Ct("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(s):t.set(s,e),b=(s,t,e,r)=>(xn(s,t,"write to private field"),r?r.call(s,e):t.set(s,e),e),$=(s,t,e)=>(xn(s,t,"access private method"),e);var qr=(s,t,e,r)=>({set _(n){b(s,t,n,e)},get _(){return g(s,t,r)}});function se(s,t,e){return e===1?s.replace(/\0(\d+)g\x7F/gu,(r,n)=>se(String(t[n]),t,2)):e===2?s.replace(/\0(\d+)n\x7F/gu,(r,n)=>String(t[n])):s.replace(/\0(\d+)\x7F/gu,(r,n)=>t[n])}var be,_i,Je,Ye,ve,rr,Mi,z,ge,tl,rl,Or,bn,Wi,nl,il,Ze,Ae,J=x(()=>{"use strict";be=String.raw` \xA0\u1680\u2000-\u200A\u202F\u205F\u3000`,_i=String.raw`[^[\]<>"\0-\x1F\x7F${be}\uFFFD]`,Je=String.raw`(?:\[[\da-f:.]+\]|${_i})`,Ye=String.raw`(?:${_i}|\0\d+[cn!~]\x7F)*`,ve=s=>s.trim().toLowerCase();rr=(s,t)=>e=>e.replace(s,t),Mi=rr(/[\0\x7F]|\r$/gmu,""),z=rr(/\0\d+[cn]\x7F/gu,""),ge=(s,t="")=>s.map(e=>typeof e=="string"?e:e.text()).join(t),tl={lt:"<",gt:">",lbrack:"[",rbrack:"]",lbrace:"{",rbrace:"}",nbsp:" ",amp:"&",quot:'"'},rl=rr(/&(?:#(\d+|[Xx][\da-fA-F]+)|([lg]t|[LG]T|[lr]brac[ke]|nbsp|amp|AMP|quot|QUOT));/gu,(s,t,e)=>t?String.fromCodePoint(+((/^x/iu.test(t)?"0":"")+t)):tl[e.toLowerCase()]),bn=s=>(Or!=null||(Or=rl),Or(s)),Wi=rr(/&#(\d+|x[\da-f]+);/giu,(s,t)=>String.fromCodePoint(+((/^x/iu.test(t)?"0":"")+t))),nl={"&":"amp","<":"lt",">":"gt",'"':"quot","\n":"#10"},il=(s=/[&<>"{}[\]|]/gu)=>rr(s,t=>`&${nl[t]};`),Ze=il(/[&<>]/gu),Ae=(s,t={})=>{let{pre:e="",post:r="",sep:n=""}=t;return e+s.map(i=>i.print()).join(n)+r}});var Ui=Ja((Od,sl)=>{sl.exports={ext:[],html:[["b","bdi","del","i","ins","u","font","big","small","sub","sup","h1","h2","h3","h4","h5","h6","cite","code","em","s","strike","strong","tt","var","div","center","blockquote","ol","ul","dl","table","caption","pre","ruby","rb","rp","rt","rtc","p","span","abbr","dfn","kbd","samp","data","time","mark","tr","td","th","q","bdo"],["li","dt","dd"],["br","wbr","hr","meta","link"]],namespaces:{"0":"","6":"File","10":"Template","14":"Category","828":"Module"},nsid:{"":0,file:6,template:10,category:14,module:828},functionHook:["msgnw"],variable:["!","=","pageid","articlepath","server","servername","scriptpath","stylepath"],parserFunction:[{msgnw:"msgnw",pageid:"pageid",articlepath:"articlepath",server:"server",servername:"servername",scriptpath:"scriptpath",stylepath:"stylepath"},{"!":"!","=":"="},["msg","raw"],["subst","safesubst"]],doubleUnderscore:[[],[],{},{}],protocol:"bitcoin:|ftp://|ftps://|geo:|git://|gopher://|http://|https://|irc://|ircs://|magnet:|mailto:|matrix:|mms://|news:|nntp://|redis://|sftp://|sip:|sips:|sms:|ssh://|svn://|tel:|telnet://|urn:|wikipedia://|worldwind://|xmpp:|commonsfinder://",interwiki:[],img:{},redirection:["#redirect"],variants:[]}});var Di,yn,Tn=x(()=>{"use strict";Di=new Set(["alt","link","lang","page","caption"]),yn=Ui()});function je(s){let t=new Map,e=new WeakMap;return r=>{let n=typeof r=="string"?t:e;if(n.has(r)){let o=n.get(r);return o.lastIndex=0,o}let i=s(r);return n.set(r,i),i}}var kn,nr=x(()=>{"use strict";kn=s=>decodeURIComponent(s.replace(/%(?![\da-f]{2})/giu,"%25"))});var ol,al,_r,qe,zi,ir=x(()=>{"use strict";Ce();ue();ol=new Set(["tr","td","th","caption"]),al=new Set(["Template:!!","Template:!-"]),_r=s=>{let t=s.childNodes.find(e=>e.text().trim());if(!t||t.type==="text"&&t.data.trim().startsWith("!")||t.is("magic-word")&&t.name==="!"||t.is("template")&&al.has(t.name)||t.is("html")&&ol.has(t.name))return!1;if(t.is("arg"))return t.length>1&&_r(t.childNodes[1]);if(t.is("magic-word"))try{let e=t.getPossibleValues().map(_r);return e.includes(2)?2:e.includes(1)&&1}catch{}return t.is("template")||t.is("magic-word")&&t.name==="invoke"?1:2},qe=(s,t,e,r)=>{if(s&&(r||M.viewOnly&&s[0]===ee.rev))return s[1];let n=t();return(r||M.viewOnly)&&e([ee.rev,n]),n},zi=(s,t)=>s==="ol"&&t==="type"?["1","a","A","i","I"]:s==="th"&&t==="scope"?["row","col","rowgroup","colgroup"]:t==="dir"?["ltr","rtl","auto"]:t==="aria-hidden"?["true","false"]:[]});var St,Mr=x(()=>{"use strict";ir();St=(s=!0)=>t=>{let e=new WeakMap;return function(...r){return qe(e.get(this),()=>t.apply(this,r),n=>{e.set(this,n)},s)}}});var Gi,Vi=x(()=>{"use strict";Gi=s=>{class t extends s{get firstChild(){return this.childNodes[0]}get lastChild(){return this.childNodes[this.childNodes.length-1]}get offsetHeight(){}get offsetWidth(){}}return t}});var Hi,Ki,or,wt,Et,ar,Oe,Nt,sr,ye,vn=x(()=>{"use strict";ir();Ce();Mr();Vi();ue();Ki=[Gi],Hi=[St(!1)];ye=class{constructor(){E(sr,5,this);Z(this,"childNodes",[]);h(this,or);h(this,wt);h(this,Et);h(this,ar);h(this,Oe);h(this,Nt,{})}get parentNode(){return g(this,or)}get nextSibling(){return g(this,wt)}get previousSibling(){return g(this,Et)}getChildNodes(){let{childNodes:t}=this;return Object.isFrozen(t)?[...t]:t}getAttribute(t){return t==="padding"?0:this[t]}setAttribute(t,e){switch(t){case"parentNode":b(this,or,e),e||(b(this,wt,void 0),b(this,Et,void 0));break;case"nextSibling":b(this,wt,e);break;case"previousSibling":b(this,Et,e);break;case"aIndex":break;default:this[t]=e}}getRootNode(){return qe(g(this,ar),()=>{var t,e;return(e=(t=this.parentNode)==null?void 0:t.getRootNode())!=null?e:this},t=>{let[,e]=t;e.type==="root"&&b(this,ar,t)})}indexFromPos(t,e){}posFromIndex(t){}getDimension(){}getGaps(t){return 0}getRelativeIndex(t){if(t===void 0){let{parentNode:e}=this;return e?e.getRelativeIndex(e.childNodes.indexOf(this)):0}return qe(g(this,Nt)[t],()=>{var o;let{childNodes:e}=this,r=((o=g(this,Oe))==null?void 0:o[0])===ee.rev&&g(this,Oe)[1],n=t+(t<0?e.length:0),i=this.getAttribute("padding");for(let a=0;a<n;a++)M.viewOnly&&(g(this,Nt)[a]=[ee.rev,i],r!==!1&&b(e[a],Oe,[ee.rev,r+i])),i+=e[a].toString().length+this.getGaps(a);return i},e=>{g(this,Nt)[t]=e})}getAbsoluteIndex(){return qe(g(this,Oe),()=>{let{parentNode:t}=this;return t?t.getAbsoluteIndex()+this.getRelativeIndex():0},t=>{b(this,Oe,t)})}getBoundingClientRect(){this.lspError("AstNode.getBoundingClientRect")}is(t){return this.type===t}getLines(){}seal(t,e){}lspError(t){throw new Error(`${t} method is only available in the LSP version!`)}};sr=I(null),or=new WeakMap,wt=new WeakMap,Et=new WeakMap,ar=new WeakMap,Oe=new WeakMap,Nt=new WeakMap,N(sr,1,"getLines",Hi,ye),ye=N(sr,0,"AstNode",Ki,ye),E(sr,1,ye)});var ll,Qi,Xi=x(()=>{"use strict";ll=s=>{if(s.includes("#")){let t=s.indexOf("#"),e=s.slice(0,t),r=s.slice(t+1);return(n,i)=>(t===0||n===e)&&i===r}return t=>t===s},Qi=(s,t,e)=>{if(s=s.trim(),!s)return(()=>!0);let r=s.split(",").map(n=>n.trim()).filter(n=>n!=="").map(ll);return(({type:n,name:i})=>r.some(o=>o(n,i)))}});var Ji,Zi=x(()=>{"use strict";Xi();Ji=s=>{var e,Yi;class t extends s{constructor(){super(...arguments);h(this,e)}closest(o){let a=$(this,e,Yi).call(this,o),{parentNode:l}=this;for(;l;){if(a(l))return l;({parentNode:l}=l)}}getElementBy(o){}querySelector(o){this.lspError("AstElement.querySelector")}getElementsBy(o){}querySelectorAll(o){this.lspError("AstElement.querySelectorAll")}escape(){}}return e=new WeakSet,Yi=function(o){return Qi(o,this)},t}});var es,An,dl,et,ts=x(()=>{"use strict";J();Ce();vn();Zi();es=[Ji];et=class extends(dl=ye){get length(){return this.childNodes.length}text(t){return ge(this.childNodes,t)}removeAt(t){this.lspError("AstElement.removeAt")}insertAt(t,e=this.length){return Wr(this,e,0,[t]),t}isInside(t){var e;return((e=this.closest(`${t},ext`))==null?void 0:e.type)===t}append(...t){this.safeAppend(t)}safeAppend(t){for(let e of t)this.insertAt(e)}safeReplaceChildren(t){}setText(t,e=0){e+=e<0?this.length:0;let r=this.childNodes[e],{data:n}=r;return r.replaceData(t),n}toString(t,e=""){return this.childNodes.map(r=>r.toString(t)).join(e)}caretPositionFromIndex(t){this.lspError("AstElement.caretPositionFromIndex")}elementFromIndex(t){this.lspError("AstElement.elementFromIndex")}elementFromPoint(t,e){this.lspError("AstElement.elementFromPoint")}lint(t=this.getAbsoluteIndex(),e){}print(t={}){{let e=t.class;return this.toString()?(e===""?"":`<span class="wpb-${e!=null?e:this.type}${this.getAttribute("invalid")?" wpb-invalid":""}">`)+Ae(this.childNodes,t)+(e===""?"":"</span>"):""}}json(t,e=1/0,r=this.getAbsoluteIndex()){}};An=I(dl),et=N(An,0,"AstElement",es,et),E(An,1,et)});var Ur,rs,lr,ns=x(()=>{"use strict";J();vn();lr=class extends ye{constructor(e){super();h(this,Ur);Z(this,"data","");this.data=e}get type(){return"text"}toString(e){var r;return e&&!((r=this.parentNode)!=null&&r.getAttribute("built"))?z(this.data):this.data}text(){return this.data}lint(e=this.getAbsoluteIndex(),r){}replaceData(e){$(this,Ur,rs).call(this,e)}splitText(e){this.lspError("AstText.splitText")}escape(){}print(){return Ze(this.data)}};Ur=new WeakSet,rs=function(e){this.setAttribute("data",e)}});var oe,_e=x(()=>{"use strict";oe=(s=!0,t=!0)=>e=>{class r extends e{text(){return""}lint(i){}}return r}});var j,ne=x(()=>{"use strict";j=s=>{}});var dr,te,Me=x(()=>{"use strict";B();te=class extends v{constructor(e,r,n,i,o){super(e,n,i,o);h(this,dr);b(this,dr,r)}get type(){return g(this,dr)}lint(e=this.getAbsoluteIndex()){}};dr=new WeakMap});var Y,Te=x(()=>{"use strict";Y=({length:s})=>t=>{class e extends t{getAttribute(n){return n==="padding"?s:super.getAttribute(n)}}return e}});var It,H,We=x(()=>{"use strict";B();H=class extends v{constructor(e,r,n,i,o){super(e,n,i,o);h(this,It);b(this,It,r)}get type(){return g(this,It)}set type(e){b(this,It,e)}getAttribute(e){var r;return e==="invalid"?this.type==="converter-flag"&&!!((r=this.parentNode)!=null&&r.isInvalidFlag(this)):super.getAttribute(e)}};It=new WeakMap});var is,tt,me,rt,Dr,ss,Cn,gl,ie,$t=x(()=>{"use strict";Te();ne();ue();B();We();is=[j,Y("[[")];ie=class extends(gl=v){constructor(e,r,n=M.getConfig(),i=[],o="|"){super(void 0,n,i,{});h(this,Dr);h(this,tt,!0);h(this,me);h(this,rt);if(this.insertAt(new H(e,"link-target",n,i)),r!==void 0){let a=new v(r,{...n,excludes:[...n.excludes,"list"]},i);a.type="link-text",a.setAttribute("stage",10),this.insertAt(a)}b(this,me,o)}get link(){}get fragment(){}afterBuild(){b(this,rt,this.getTitle()),g(this,me).includes("\0")&&b(this,me,this.buildFromStr(g(this,me),0)),$(this,Dr,ss).call(this),super.afterBuild()}setAttribute(e,r){e==="bracket"?b(this,tt,r):e==="title"?b(this,rt,r):super.setAttribute(e,r)}toString(e){let r=super.toString(e,g(this,me));return g(this,tt)?`[[${r}]]`:r}text(){let e=super.text("|");return g(this,tt)?`[[${e}]]`:e}getAttribute(e){return e==="title"?g(this,rt):super.getAttribute(e)}getGaps(e){return e===0?g(this,me).length:1}lint(e=this.getAbsoluteIndex(),r){}getTitle(e,r){return this.normalizeTitle(this.firstChild.text(),0,{halfParsed:r,temporary:e,decode:!0,selfLink:!0})}print(){return super.print(g(this,tt)?{pre:"[[",post:"]]",sep:g(this,me)}:{sep:g(this,me)})}json(e,r,n=this.getAbsoluteIndex()){}};Cn=I(gl),tt=new WeakMap,me=new WeakMap,rt=new WeakMap,Dr=new WeakSet,ss=function(){this.type!=="ext-inner"&&this.setAttribute("name",g(this,rt).title)},ie=N(Cn,0,"LinkBaseToken",is,ie),E(Cn,1,ie)});var os,Sn,ul,K,Ue=x(()=>{"use strict";ne();B();os=[j];K=class extends(ul=v){get innerText(){return this.firstChild.data}constructor(t="",e,r){super(t,e,r)}};Sn=I(ul),K=N(Sn,0,"NowikiBaseToken",os,K),E(Sn,1,K)});var as,wn,pl,Q,nt=x(()=>{"use strict";_e();Ue();as=[oe(!1)];Q=class extends(pl=K){get type(){return"noinclude"}toString(t){return t?"":super.toString()}lint(t=this.getAbsoluteIndex()){}};wn=I(pl),Q=N(wn,0,"NoincludeToken",as,Q),E(wn,1,Q)});var zr,ls=x(()=>{"use strict";$t();nt();zr=class extends ie{get type(){return"redirect-target"}constructor(t,e,r,n){super(t,void 0,r,n),e!==void 0&&this.insertAt(new Q(e,r,n))}getTitle(){return this.normalizeTitle(this.firstChild.toString(),0,{halfParsed:!0,decode:!0,page:""})}lint(t=this.getAbsoluteIndex()){}}});var ds,st,Lt,En,cl,it,gs=x(()=>{"use strict";_e();ne();B();Me();ls();ds=[oe(!1,!1),j];it=class extends(cl=v){constructor(e,r,n,i,o,a,l=[]){super(void 0,a,l);h(this,st);h(this,Lt);b(this,st,e),b(this,Lt,o),this.append(new te(r,"redirect-syntax",a,l),new zr(n,i==null?void 0:i.slice(1),a,l))}get type(){return"redirect"}getAttribute(e){return e==="padding"?g(this,st).length:super.getAttribute(e)}toString(e){return g(this,st)+super.toString(e)+g(this,Lt)}lint(e=this.getAbsoluteIndex()){}print(){return super.print({pre:g(this,st),post:g(this,Lt)})}};En=I(cl),st=new WeakMap,Lt=new WeakMap,it=N(En,0,"RedirectToken",ds,it),E(En,1,it)});var us={};W(us,{parseRedirect:()=>fl});var fl,ps=x(()=>{"use strict";ue();gs();fl=(s,t,e)=>{var n;(n=t.regexRedirect)!=null||(t.regexRedirect=new RegExp(String.raw`^(\s*)((?:${t.redirection.join("|")})\s*(?::\s*)?)\[\[([^\n|\]]+)(\|.*?)?\]\](\s*)`,"iu"));let r=t.regexRedirect.exec(s);return r&&M.normalizeTitle(r[3],0,!1,t,{halfParsed:!0,temporary:!0,decode:!0,page:""}).valid?(s=`\0${e.length}o${s.slice(r[0].length)}`,new it(...r.slice(1),t,e),s):!1}});var cs,Nn,ml,ot,fs=x(()=>{"use strict";Te();ne();B();cs=[j,Y("<onlyinclude>")];ot=class extends(ml=v){get type(){return"onlyinclude"}toString(t){return`<onlyinclude>${super.toString(t)}</onlyinclude>`}isPlain(){return!0}print(){return super.print({pre:'<span class="wpb-ext"><onlyinclude></span>',post:'<span class="wpb-ext"></onlyinclude></span>'})}};Nn=I(ml),ot=N(Nn,0,"OnlyincludeToken",cs,ot),E(Nn,1,ot)});var De,gr=x(()=>{"use strict";De=(s=1)=>t=>{class e extends t{getGaps(){return s}}return e}});var ms,ze,Se,In,hl,he,Gr=x(()=>{"use strict";gr();ne();B();ms=[De(),j];he=class extends(hl=v){constructor(e,r,n,i,o,a=[]){super(void 0,o);h(this,ze);h(this,Se);Z(this,"closed");this.setAttribute("name",e.toLowerCase()),b(this,ze,[e,i||e]),this.closed=i!=="",b(this,Se,i===void 0),this.append(r,n);let l=typeof r=="string"?-1:a.indexOf(r);a.splice(l===-1?1/0:l,0,this)}get innerText(){return g(this,Se)?void 0:this.lastChild.text()}get selfClosing(){return g(this,Se)}toString(e){let{firstChild:r,lastChild:n}=this,[i,o]=g(this,ze);return g(this,Se)?`<${i}${r.toString(e)}/>`:`<${i}${r.toString(e)}>${n.toString(e)}${this.closed?`</${o}>`:""}`}text(){let[e,r]=g(this,ze);return g(this,Se)?`<${e}${this.firstChild.text()}/>`:`<${e}${super.text(">")}${this.closed?`</${r}>`:""}`}getAttribute(e){return e==="padding"?g(this,ze)[0].length+1:super.getAttribute(e)}print(){{let[e,r]=g(this,ze);return super.print(g(this,Se)?{pre:`<${e}`,post:"/>"}:{pre:`<${e}`,sep:">",post:this.closed?`</${r}>`:""})}}json(e,r,n=this.getAbsoluteIndex()){}};In=I(hl),ze=new WeakMap,Se=new WeakMap,he=N(In,0,"TagPairToken",ms,he),E(In,1,he)});var hs,$n,xl,at,xs=x(()=>{"use strict";_e();Gr();hs=[oe(!1)];at=class extends(xl=he){get type(){return"include"}constructor(t,e="",r,n,i,o){super(t,e,r!=null?r:"",r===void 0||n!=null?n:"",i,o)}toString(t){return t?"":super.toString()}lint(t=this.getAbsoluteIndex()){}};$n=I(xl),at=N($n,0,"IncludeToken",hs,at),E($n,1,at)});var Ft,Vr=x(()=>{"use strict";Ft=(s=0)=>t=>{}});var pe,bs,ys,Ts,ws,bl,ks,vs,yl,Tl,Ln,As,Cs,Ss,lt,Es,Ns,Is,$s=x(()=>{"use strict";pe=new Set(["align"]),bs=new Set(["cite"]),ys=new Set(["cite","datetime"]),Ts=new Set(["width"]),ws=new Set(["bgcolor","align","valign"]),bl=new Set([...ws,"axis","height","nowrap","width"]),ks=new Set([...bl,"abbr","headers","scope","rowspan","colspan"]),vs=new Set(["type"]),yl=new Set(["summary","align","bgcolor","cellpadding","cellspacing","frame","rules","width"]),Tl=new Set(["clear"]),Ln=new Set(["id","qid","forcemathmode","type","display"]),As=new Set(["enclose","inline","lang","line","linelinks","style","class","id","dir","copy","highlight","start"]),Cs=new Set(["weight"]),Ss=new Set(["width","height","zoom","latitude","longitude","align","mapstyle","lang","alt","text"]),lt=new Set,Es=new Set(["id","class","style","lang","dir","title","tabindex","aria-describedby","aria-flowto","aria-hidden","aria-label","aria-labelledby","aria-level","aria-owns","role","about","property","resource","datatype","typeof","itemid","itemprop","itemref","itemscope","itemtype"]),Ns={div:pe,h1:pe,h2:pe,h3:pe,h4:pe,h5:pe,h6:pe,blockquote:bs,q:bs,p:pe,br:Tl,pre:Ts,ins:ys,del:ys,ul:vs,ol:new Set(["type","start","reversed"]),li:new Set(["type","value"]),table:new Set([...yl,"border"]),caption:pe,tr:ws,td:ks,th:ks,font:new Set(["size","color","face"]),hr:Ts,data:new Set(["value"]),time:new Set(["datetime"]),meta:new Set(["itemprop","content"]),link:new Set(["itemprop","href","title"]),gallery:vs,poem:pe,categorytree:pe,combooption:pe,img:new Set(["alt","src","width","height","loading","srcset"])},Is={pre:new Set(["format"]),gallery:new Set(["mode","showfilename","caption","perrow","widths","heights","showthumbnails"]),poem:new Set(["compact"]),categorytree:new Set(["hideroot","onlyroot","depth","mode","hideprefix","namespaces","showcount","notranslations"]),combooption:new Set(["name","for","inline"]),nowiki:lt,indicator:new Set(["name"]),langconvert:new Set(["from","to"]),ref:new Set(["group","name","follow","dir","details"]),references:new Set(["group","responsive"]),charinsert:new Set(["label"]),choose:new Set(["uncached","before","after"]),option:Cs,choicetemplate:Cs,imagemap:lt,inputbox:lt,templatestyles:new Set(["src","wrapper"]),dynamicpagelist:lt,poll:new Set(["id","show-results-before-voting"]),score:new Set(["line_width_inches","lang","override_midi","raw","note-language","override_audio","override_ogg","sound","vorbis"]),seo:new Set(["title","title_mode","title_separator","keywords","description","robots","google_bot","image","image_width","image_height","image_alt","type","site_name","locale","section","author","published_time","twitter_site"]),tab:new Set(["nested","name","index","class","block","inline","openname","closename","collapsed","dropdown","style","bgcolor","container","id","title"]),tabs:new Set(["plain","class","container","id","title","style"]),combobox:new Set(["placeholder","value","id","class","text","dropdown","style"]),math:new Set([...Ln,"chem"]),chem:Ln,ce:Ln,hiero:lt,phonos:new Set(["ipa","class","text","lang","wikibase","file"]),section:new Set(["begin","end"]),source:As,syntaxhighlight:As,templatedata:lt,timeline:new Set(["method","font"]),quiz:new Set(["display","shuffleanswers","points","shuffle","case"]),languages:lt,mapframe:new Set([...Ss,"frameless"]),maplink:new Set([...Ss,"class"]),rss:new Set(["template","templatename","max","highlight","filter","filterout","reverse","date","item-max-length"]),"page-collection":new Set(["lang","name","description","end-date"])}});var kl,vl,Al,Cl,pr,Rt,re,dt,Bt,Ls,Fs,ur,Rs=x(()=>{"use strict";ir();J();$s();B();We();kl=/expression|(?:accelerator|-o-link(?:-source)?|-o-replace)\s*:|(?:url|src|image(?:-set)?)\s*\(|attr\s*\([^)]+[\s,]url/u,vl=/(?:^|\s|\*\/)(?:java|vb)script(?:\W|$)/iu,Al=new Set(["ext","arg","magic-word","template"]),Cl=new Set(["about","property","resource","datatype","typeof","itemid","itemprop","itemref","itemscope","itemtype"]),ur=class extends v{constructor(e,r,n,i,o,a="",l,p=[]){let u=new H(n,"attr-key",o,p),d;if(n==="title"||r==="img"&&n==="alt")d=new v(l,o,p,{}),d.type="attr-value",d.setAttribute("stage",10);else if(r==="gallery"&&n==="caption"||r==="ref"&&n==="details"||(r==="mapframe"||r==="maplink")&&n==="text"||r==="choose"&&(n==="before"||n==="after")){let c={...o,excludes:[...o.excludes,"heading","html","table","hr","list"]};d=new v(l,c,p,{}),d.type="attr-value",d.setAttribute("stage",1)}else d=new H(l,"attr-value",o,p,{});super(void 0,o,p);h(this,Bt);h(this,pr);h(this,Rt);h(this,re);h(this,dt);b(this,pr,e),this.append(u,d),b(this,re,a),b(this,dt,[...i]),b(this,Rt,r),this.setAttribute("name",ve(z(n)))}get type(){return g(this,pr)}get tag(){return g(this,Rt)}get balanced(){}afterBuild(){g(this,re).includes("\0")&&b(this,re,this.buildFromStr(g(this,re),0)),this.parentNode&&b(this,Rt,this.parentNode.name),$(this,Bt,Ls).call(this),super.afterBuild()}toString(e){let[r="",n=""]=g(this,dt);return g(this,re)?super.toString(e,g(this,re)+r)+n:this.firstChild.toString(e)}text(){return g(this,re)?`${super.text(`${g(this,re).trim()}"`)}"`:this.firstChild.text()}getGaps(){var e,r;return g(this,re)?g(this,re).length+((r=(e=g(this,dt)[0])==null?void 0:e.length)!=null?r:0):0}lint(e=this.getAbsoluteIndex(),r){}getValue(){return g(this,re)?this.lastChild.text().replace(/[\t\r\n ]+/gu," ").trim():""}escape(){}getAttribute(e){return e==="invalid"?!!$(this,Bt,Fs).call(this):super.getAttribute(e)}print(){{let[e="",r=""]=g(this,dt);return g(this,re)?super.print({sep:Ze(g(this,re))+e,post:r}):super.print()}}json(e,r,n=this.getAbsoluteIndex()){}};pr=new WeakMap,Rt=new WeakMap,re=new WeakMap,dt=new WeakMap,Bt=new WeakSet,Ls=function(){this.setAttribute("name",ve(this.firstChild.text()))},Fs=function(e,r){let{firstChild:n,lastChild:i,type:o,name:a,tag:l,parentNode:p}=this,u=!i.childNodes.some(({type:k})=>Al.has(k)),d=this.getValue(),c=Is[l],f=Ns[l],{length:m}=this.toString(),A="illegal-attr",C,S;if(!(c!=null&&c.has(a))&&!(f!=null&&f.has(a))&&(o==="ext-attr"?c||f:!/\{\{[^{]+\}\}/u.test(a))&&(o==="ext-attr"&&!f||!/^(?:xmlns:[\w:.-]+|data-(?!ooui|mw|parsoid)[^:_]*)$/u.test(a)&&(l==="meta"||l==="link"||!Es.has(a)))||(a==="itemtype"||a==="itemid"||a==="itemref")&&!(p!=null&&p.hasAttr("itemscope"))){if(e===void 0)return 2}else if(a==="style"&&kl.test(d)){if(e===void 0)return 1}else if(a==="tabindex"&&d!=="0"){if(e===void 0)return 2}else if((/^xmlns:[\w:.-]+$/u.test(a)||Cl.has(a))&&vl.test(d)||u&&(a==="href"||o==="ext-attr"&&l==="img"&&a==="src")&&!new RegExp(String.raw`^(?:${this.getAttribute("config").protocol}|//)\S+$`,"iu").test(d)){if(e===void 0)return 2}else if(u&&o!=="ext-attr"){let k=zi(l,a),y=d.toLowerCase();if(k.length>0&&k.every(T=>T!==y)&&e===void 0)return 2}return!1}});var Bs,Sl,cr,fr,Fn,Ge,Hr=x(()=>{"use strict";J();B();We();Rs();Bs=s=>s.slice(0,-1),Sl=s=>`${Bs(s)}-dirty`,Ge=class extends v{constructor(e,r,n,i,o=[]){super(void 0,i,o,{});h(this,fr);h(this,cr);if(b(this,cr,r),this.setAttribute("name",n),e){let a=/([^\s/](?:(?!\0\d+~\x7F)[^\s/=])*)(?:((?:\s(?:\s|\0\d+[cn]\x7F)*)?(?:=|\0\d+~\x7F)(?:\s|\0\d+[cn]\x7F)*)(?:(["'])([\s\S]*?)(\3|$)|(\S*)))?/gu,l="",p=a.exec(e),u=0,d=()=>{l&&(super.insertAt(new H(l,Sl(r),i,o)),l="")};for(;p;){let{index:c,0:f,1:m,2:A,3:C,4:S,5:k,6:y}=p;if(l+=e.slice(u,c),/^(?:[\w:]|\0\d+t\x7F)(?:[\w:.-]|\0\d+t\x7F)*$/u.test(z(m).trim())){let T=S!=null?S:y,w=[C,k],F=new ur(Bs(r),n,m,w,i,A,T,o);d(),super.insertAt(F)}else l+=f;({lastIndex:u}=a),p=a.exec(e)}l+=e.slice(u),d()}}get type(){return g(this,cr)}afterBuild(){let{parentNode:e}=this;e!=null&&e.is("td")&&this.setAttribute("name",e.subtype),super.afterBuild()}getAttrTokens(e){return this.childNodes.filter(r=>r instanceof ur&&(!e||r.name===ve(e)))}hasAttr(e){return this.getAttrTokens(e).length>0}getAttrToken(e){}getAttr(e){}lint(e=this.getAbsoluteIndex(),r){}escape(){}getAttribute(e){return e==="invalid"?$(this,fr,Fn).call(this):super.getAttribute(e)}print(){return this.toString()?`<span class="wpb-${this.type}${$(this,fr,Fn).call(this)?" wpb-invalid":""}">${this.childNodes.map(e=>e.print(e instanceof H?{class:e.toString().trim()&&"attr-dirty"}:void 0)).join("")}</span>`:""}};cr=new WeakMap,fr=new WeakSet,Fn=function(){let{parentNode:e}=this;return(e==null?void 0:e.type)==="html"&&e.closing&&this.text().trim()!==""}});var Ps={};W(Ps,{PreToken:()=>Rn});var Rn,js=x(()=>{"use strict";B();nt();Rn=class extends v{get type(){return"ext-inner"}constructor(t,e,r=[]){if(t){let n=/<nowiki>/giu,i=/<\/nowiki>/giu,{length:o}=n.source,a=n.exec(t);a&&(i.lastIndex=a.index+o);let l=i.exec(t),p=0,u="";for(;a&&l;)new Q(a[0],e,r,!0),new Q(l[0],e,r,!0),u+=`${t.slice(p,a.index)}\0${r.length-1}n${t.slice(a.index+o,l.index)}\0${r.length}n`,p=l.index+o+1,n.lastIndex=p,a=n.exec(t),a&&(i.lastIndex=a.index+o),l=i.exec(t);t=u+t.slice(p)}super(t,e,r,{}),this.setAttribute("stage",10)}isPlain(){return!0}lint(t=this.getAbsoluteIndex()){}}});var Ve,Kr=x(()=>{"use strict";B();Ve=class extends v{get type(){return"ext-inner"}toString(t){return super.toString(t,`
|
|
2
2
|
`)}text(){return super.text(`
|
|
3
3
|
`).replace(/\n\s*\n/gu,`
|
|
4
4
|
`)}getGaps(){return 1}print(){return super.print({sep:`
|
|
5
|
-
`})}}});var
|
|
6
|
-
`).map(a=>o?a:gt(a,n,i,e)).map(a=>new
|
|
7
|
-
`,index:s.length},w=(
|
|
8
|
-
`){f=T+1;let{pos:
|
|
9
|
-
`)||(s=`${s.slice(0,L)}\0${e.length}h${s.slice(T)}`,f=L+4+String(e.length).length,new we(xe[1].length,xe.slice(2),t,e)))}}else if(y==="|"||V)f=T+1,a(s,R,P,T),y==="|"&&R.push([]),w.pos=f,w.findEqual=y==="|",i.push(w);else if(y.startsWith("}}")){let
|
|
10
|
-
)`:""}(\s*)$`,"u"));
|
|
11
|
-
`))!=null?i:[]){let a=/^([^|]+)(?:\|(.*))?/u.exec(o);if(!a){super.insertAt(o.trim()?new mt(o,r,n):o);continue}let[,l,p]=a;$(this,kr,
|
|
12
|
-
`),i=new Set(e.protocol.split("|")),o=!0,a=!1;for(let l of n){let p=l.trim();if(!(a||!p||p.startsWith("#"))){if(o){let u=l.indexOf("|"),d=u===-1?l:l.slice(0,u),c=this.normalizeTitle(d,0,{halfParsed:!0,temporary:!0,page:""});if(c.valid&&c.ns===6){let f=new Ne("imagemap",d,u===-1?void 0:l.slice(u+1),e,r);super.insertAt(f),o=!1;continue}else a=!0}else if(l.trim().split(/[\t ]/u,1)[0]==="desc"){super.insertAt(l);continue}else if(l.includes("[")){let u=l.indexOf("["),d=l.slice(u),c=/^\[\[([^|]+)(?:\|([^\]]*))?\]\][\w\s]*$/u.exec(d);if(c){if(this.normalizeTitle(c[1],0,{halfParsed:!0,temporary:!0,selfLink:!0,page:""}).valid){super.insertAt(new Ar(l.slice(0,u),c.slice(1),d.slice(d.indexOf("]]")+2),e,r));continue}}else if(d.startsWith("[//")||i.has(d.slice(1,d.indexOf(":")+1))||i.has(d.slice(1,d.indexOf("//")+2))){let f=/^\[([^\]\s]+)(?:(\s+(?!\s))([^\]]*))?\][\w\s]*$/u.exec(d);if(f){super.insertAt(new Ar(l.slice(0,u),f.slice(1),d.slice(d.indexOf("]")+1),e,r));continue}}}}super.insertAt(new mt(l,e,r))}}lint(t=this.getAbsoluteIndex(),e){}getAttribute(t){return t==="invalid"?!this.image:super.getAttribute(t)}}});var xo,ni,zl,Fe,ii=x(()=>{"use strict";_e();Te();Ue();xo=[oe(!1),Y("<!--")];Fe=class extends(zl=Q){constructor(e,r,n,i){super(e,n,i);Z(this,"closed");this.closed=r}get type(){return"comment"}lint(e=this.getAbsoluteIndex()){}toString(e){return e?"":`<!--${this.innerText}${this.closed?"-->":""}`}print(){return super.print({pre:"<!--",post:this.closed?"-->":""})}};ni=I(zl),Fe=N(ni,0,"CommentToken",xo,Fe),E(ni,1,Fe)});var bo={};M(bo,{CommentedToken:()=>si});var si,yo=x(()=>{"use strict";B();ii();si=class extends v{get type(){return"ext-inner"}constructor(t,e,r=[]){if(super(void 0,e,r,{AstText:":",CommentToken:":"}),t){let n=t.indexOf("<!--"),i=n!==-1&&t.indexOf("-->",n+4),o=0;for(;i!==!1&&i!==-1;)n>o&&this.insertAt(t.slice(o,n)),this.insertAt(new Fe(t.slice(n+4,i),!0,e,r)),o=i+3,n=t.indexOf("<!--",o),i=n!==-1&&t.indexOf("-->",n+4);o<t.length&&this.insertAt(t.slice(o))}}lint(t=this.getAbsoluteIndex()){}}});var ko={};M(ko,{CategorytreeToken:()=>Mt});var To,oi,Gl,Mt,vo=x(()=>{"use strict";Te();$t();To=[Y("")];Mt=class extends(Gl=ie){get type(){return"ext-inner"}constructor(t,e,r,n=[]){super(t,e,r,n),this.setAttribute("bracket",!1)}getTitle(){let t=this.firstChild.toString().trim(),e={halfParsed:!0},r=this.normalizeTitle(t,14,e);return r.valid&&r.ns===14?r:this.normalizeTitle(`Category:${t}`,0,e)}lint(t=this.getAbsoluteIndex()){}};oi=I(Gl),Mt=N(oi,0,"CategorytreeToken",To,Mt),E(oi,1,Mt)});var Ao={};M(Ao,{NowikiToken:()=>ai});var Vl,on,Co,ai,So=x(()=>{"use strict";Ue();Vl=new Set(["languages","section","templatestyles"]),ai=class extends Q{constructor(){super(...arguments);h(this,on)}get type(){return"ext-inner"}lint(e=this.getAbsoluteIndex()){}getAttribute(e){return e==="invalid"?$(this,on,Co).call(this):super.getAttribute(e)}};on=new WeakSet,Co=function(){let{name:e,firstChild:{data:r}}=this;return Vl.has(e)&&!!r}});var wo,li,Hl,Ee,Gn=x(()=>{"use strict";ue();Vr();B();Gr();Hr();wo=[Ft()];Ee=class extends(Hl=he){get type(){return"ext"}constructor(t,e,r,n,i=W.getConfig(),o=!1,a=[]){let l=t.toLowerCase(),p=new Ge(!e||/^\s/u.test(e)?e:` ${e}`,"ext-attrs",l,i,a),u={...i,ext:i.ext.filter(c=>c!==l),excludes:[...i.excludes],inExt:!0},d;switch(l){case"pre":if(p.getAttr("format")!=="wikitext"){let{PreToken:c}=(Ps(),O(Bs));d=new c(r,u,a);break}case"indicator":case"poem":case"ref":case"option":case"combooption":case"tab":case"tabs":case"poll":case"seo":case"langconvert":case"phonos":switch(l){case"poem":u.excludes.push("heading");break;case"langconvert":u.excludes.push("list");break;case"tab":u.ext=u.ext.filter(c=>c!=="tabs");break}d=new v(r,u,a);break;case"dynamicpagelist":{let{ParamTagToken:c}=(Bn(),O(Os));d=new c(l,o,r,u,a);break}case"inputbox":{let{InputboxToken:c}=(ro(),O(to));d=new c(l,o,r,u,a);break}case"references":{let{NestedToken:c}=(rn(),O(tn));u.excludes.push("heading"),d=new c(r,o,["ref"],u,a);break}case"choose":{let{NestedToken:c}=(rn(),O(tn));d=new c(r,/<(option|choicetemplate)(\s[^>]*?)?(?:\/>|>([\s\S]*?)<\/(\1)>)/gu,["option","choicetemplate"],u,a);break}case"combobox":{let{NestedToken:c}=(rn(),O(tn));d=new c(r,/<(combooption)(\s[^>]*?)?(?:\/>|>([\s\S]*?)<\/(combooption\s*)>)/giu,["combooption"],u,a);break}case"gallery":{let{GalleryToken:c}=(go(),O(lo));d=new c(r,u,a);break}case"imagemap":{let{ImagemapToken:c}=(mo(),O(fo));d=new c(r,u,a);break}case"hiero":{let{CommentedToken:c}=(yo(),O(bo));d=new c(r,u,a);break}case"categorytree":{let{CategorytreeToken:c}=(vo(),O(ko));d=new c(r,void 0,u,a);break}default:{let{NowikiToken:c}=(So(),O(Ao));d=new c(r,u,a)}}d.setAttribute("name",l),d.type==="plain"&&(d.type="ext-inner"),super(t,p,d,n,i,a),this.seal("closed",!0)}lint(t=this.getAbsoluteIndex(),e){}};li=I(Hl),Ee=N(li,0,"ExtToken",wo,Ee),E(li,1,Ee)});var Xe,Ke,di,Ut,gi=x(()=>{"use strict";B();Ut=class extends v{constructor(e,r,n,i,o){super(void 0,i,o);h(this,Xe);h(this,Ke);h(this,di);this.insertAt(r),b(this,Xe,n),b(this,Ke,e)}get closing(){return g(this,Xe)}toString(e){return`<${g(this,Xe)?"/":""}${g(this,Ke)}${super.toString(e)}${this.selfClosing?"/":""}>`}text(e=""){let{closing:r}=this;return`<${r&&!e?"/":""}${g(this,Ke)}${r?"":super.text()}${e}>`}getAttribute(e){return e==="padding"?g(this,Ke).length+(g(this,Xe)?2:1):super.getAttribute(e)}findMatchingTag(){}print(){return super.print({pre:`<${g(this,Xe)?"/":""}${g(this,Ke)}`,post:`${this.selfClosing?"/":""}>`})}json(e,r,n=this.getAbsoluteIndex()){}};Xe=new WeakMap,Ke=new WeakMap,di=new WeakMap});var Eo,ui,Ql,ke,No=x(()=>{"use strict";_e();ne();gi();We();Eo=[oe(),j];ke=class extends(Ql=Ut){get type(){return"tvar"}constructor(t,e,r,n,i){let o=new te(e,"tvar-name",n,i);super(t,o,r,n,i)}};ui=I(Ql),ke=N(ui,0,"TvarToken",Eo,ke),E(ui,1,ke)});var $o={};M($o,{TranslateToken:()=>pi});var an,Io,pi,Lo=x(()=>{"use strict";B();Gr();We();No();pi=class extends he{constructor(e,r,n,i=[]){let o=new te(e,"translate-attr",n,i);r=r==null?void 0:r.replace(/<tvar(\|[^>]+)>([\s\S]*?)<\/>/gu,(l,p,u)=>(new ke("tvar",p,!1,n,i),new ke("","",!0,n,i),`\0${i.length-2}n${u}\0${i.length}n`)).replace(/<(tvar)(\s+name\s*=(?:\s*(?:(["'])[\s\S]*?\3|[^"'\s>]+))?\s*)>([\s\S]*?)<\/(tvar)(\s*)>/giu,(l,p,u,d,c,f,m)=>(new ke(p,u,!1,n,i),new ke(f,m,!0,n,i),`\0${i.length-2}n${c}\0${i.length}n`));let a=new v(r,n,i);a.type="translate-inner";super("translate",o,a,"translate",n,i);h(this,an);this.seal("closed",!0)}get type(){return"translate"}get selfClosing(){return!1}toString(e){return e?this.lastChild.toString(!0):super.toString()}text(){return this.lastChild.text()}print(){return`<span class="wpb-ext"><translate${$(this,an,Io).call(this)?'<span class="wpb-ext-attrs"> <span class="wpb-ext-attr"><span class="wpb-attr-key">nowrap</span></span></span>':""}>${this.lastChild.print({class:"ext-inner"})}</translate></span>`}};an=new WeakSet,Io=function(){return this.firstChild.toString()===" nowrap"}});var Bo={};M(Bo,{parseCommentAndExt:()=>gt});var Ro,Xl,ci,Kl,Fo,gt,hr=x(()=>{"use strict";nr();J();cs();nt();hs();Gn();ii();Ro="<onlyinclude>",Xl="</onlyinclude>",{length:ci}=Ro,Kl=[!1,!0].map(s=>{let t=s?"includeonly":"(?:no|only)include",e=s?"noinclude":"includeonly";return je(r=>new RegExp(String.raw`<!--[\s\S]*?(?:-->|$)|<${t}(?:\s[^>]*)?/?>|</${t}\s*>|<(${r})(\s[^>]*?)?(?:/>|>([\s\S]*?)</(${"\\1"}\s*)>)|<(${e})(\s[^>]*?)?(?:/>|>([\s\S]*?)(?:</(${e}\s*)>|$))`,"giu"))}),Fo=s=>{let t=s.indexOf(Ro);return{i:t,j:s.indexOf(Xl,t+ci)}},gt=(s,t,e,r)=>{if(r){let{i:l,j:p}=Fo(s);if(l!==-1&&p!==-1){let u="",d=c=>{new X(c,t,e),u+=`\0${e.length-1}n`};for(;l!==-1&&p!==-1;){let c=`\0${e.length}g`;new ot(s.slice(l+ci,p),t,e),l>0&&d(s.slice(0,l)),u+=c,s=s.slice(p+ci+1),{i:l,j:p}=Fo(s)}return s&&d(s),u}}let{ext:n}=t,i=n,o=t;if(n.includes("translate")){let{TranslateToken:l}=(Lo(),O($o)),p=[];i=n.filter(u=>u!=="translate"&&u!=="tvar"),o={...t,ext:i},s=s.replace(/<nowiki>[\s\S]*?<\/nowiki>/giu,u=>(p.push(u),`\0${p.length-1}`)).replace(/<translate( nowrap)?>([\s\S]*?)<\/translate>/gu,(u,d,c)=>{let f=e.length;return new l(d,c&&se(c,p),o,e),`\0${f}g`}),s=se(s,p)}let a=Kl[r?1:0](i.join("|"));return a.lastIndex=0,a.test(s)?s.replace(a,(l,p,u,d,c,f,m,C,A)=>{let S=e.length,k="n";if(p)k="e",new Ee(p,u,d,c,o,f,e);else if(l.startsWith("<!--")){k="c";let y=l.endsWith("-->");new Fe(se(l,e,1).slice(4,y?-3:void 0),y,t,e)}else f?new at(f,m&&se(m,e,1),C&&se(C,e,1),A,t,e):new X(l,t,e,!0);return`\0${S}${k}`}):s}});var Po,Sr,fi,Jl,ht,jo=x(()=>{"use strict";Vr();gi();Po=[Ft()];ht=class extends(Jl=Ut){constructor(e,r,n,i,o,a){super(e,r,n,o,a);h(this,Sr);this.setAttribute("name",e.toLowerCase()),b(this,Sr,i)}get type(){return"html"}get selfClosing(){return g(this,Sr)}text(){let{closing:e,selfClosing:r,name:n}=this,[,,i]=this.getAttribute("config").html;return i.includes(n)?e&&n!=="br"?"":super.text("/"):super.text(r&&!e?"/":"")}lint(e=this.getAbsoluteIndex(),r){}getAttribute(e){return e==="invalid"?this.inTableAttrs()===2:super.getAttribute(e)}json(e,r,n=this.getAbsoluteIndex()){}};fi=I(Jl),Sr=new WeakMap,ht=N(fi,0,"HtmlToken",Po,ht),E(fi,1,ht)});var Oo={};M(Oo,{parseHtml:()=>Zl});var Yl,Zl,qo=x(()=>{"use strict";Hr();jo();Yl=/^(\/?)([a-z][^\s/>]*)((?:\s|\/(?!>))[^>]*?)?(\/?>)([^<]*)$/iu,Zl=(s,t,e)=>{var o;let{html:r}=t;(o=t.htmlElements)!=null||(t.htmlElements=new Set([...r[0],...r[1],...r[2]]));let n=s.split("<"),i=n.shift();for(let a of n){let l=Yl.exec(a),p=l==null?void 0:l[2],u=p==null?void 0:p.toLowerCase();if(!l||!t.htmlElements.has(u)){i+=`<${a}`;continue}let[,d,,c="",f,m]=l,{length:C}=e,A=new Ge(c,"html-attrs",u,t,e),S=A.hasAttr("itemprop");if(u==="meta"&&!(S&&A.hasAttr("content"))||u==="link"&&!(S&&A.hasAttr("href"))){i+=`<${a}`,e.length=C;continue}i+=`\0${e.length}x${m}`,new ht(p,A,d==="/",f==="/>",t,e)}return i}});var _o,mi,ed,Re,hi=x(()=>{"use strict";Vr();B();We();Hr();_o=[Ft(1)];Re=class extends(ed=v){constructor(t,e,r,n,i,o=[],a){super(void 0,i,o,a),this.append(new te(e,"table-syntax",i,o),new Ge(n,"table-attrs",r,i,o))}escape(){}};mi=I(ed),Re=N(mi,0,"TableBaseToken",_o,Re),E(mi,1,Re)});var Wo,Mo,fe,xi,Dt,wr,Er,Uo=x(()=>{"use strict";Wr();B();hi();Er=class extends(Mo=Re,Wo=[St(!1)],Mo){constructor(e,r,n,i=[]){var p;let o=/\||\0\d+!\x7F/u.exec(r!=null?r:""),a=o?r.slice(0,o.index):"";/\[\[|-\{/u.test(a)&&(o=null,a="");super(/^(?:\n[^\S\n]*(?:[|!]|\|\+|\{\{\s*!\s*\}\}\+?)|(?:\||\{\{\s*!\s*\}\}){2}|!!|\{\{\s*!!\s*\}\})$/u,e,"td",a,n,i);E(xi,5,this);h(this,Dt);h(this,fe,"");o&&([Or(this,fe)._]=o);let l=new v(r==null?void 0:r.slice(((p=o==null?void 0:o.index)!=null?p:NaN)+g(this,fe).length),n,i);l.type="td-inner",l.setAttribute("stage",4),this.insertAt(l)}get type(){return"td"}get rowspan(){}get colspan(){}get subtype(){return $(this,Dt,wr).call(this).subtype}afterBuild(){g(this,fe).includes("\0")&&b(this,fe,this.buildFromStr(g(this,fe),0)),super.afterBuild()}toString(e){let[r,n,i]=this.childNodes;return r.toString(e)+n.toString(e)+g(this,fe)+i.toString(e)}text(){let[e,r,n]=this.childNodes;return e.text()+r.text()+g(this,fe)+n.text()}getGaps(e){return e===1?g(this,fe).length:0}lint(e=this.getAbsoluteIndex(),r){}isIndependent(){return this.firstChild.text().startsWith(`
|
|
13
|
-
`)}getAttr(e){}escape(){}print(){{let[e,r,n]=this.childNodes;return`<span class="wpb-td">${e.print()}${r.print()}${g(this,fe)}${n.print()}</span>`}}json(e,r,n=this.getAbsoluteIndex()){}};xi=I(
|
|
14
|
-
|}`,r){ee.run(()=>{let n=new te(r?e:void 0,"table-syntax",this.getAttribute("config"),this.getAttribute("accum"));super.insertAt(n)})}getLayout(e){}getAllRows(){}getNthRow(e,r,n){}json(e,r,n=this.getAbsoluteIndex()){}};yi=I(
|
|
5
|
+
`})}}});var Qr,qs=x(()=>{"use strict";B();Qr=class extends v{get type(){return"param-line"}constructor(t,e,r,n,i){super(e,r,n,i),this.setAttribute("name",t)}lint(t=this.getAbsoluteIndex()){}}});var Os={};W(Os,{ParamTagToken:()=>mr});var mr,Bn=x(()=>{"use strict";hr();Kr();qs();mr=class extends Ve{constructor(t,e,r,n,i=[],o){super(void 0,n,i,{}),r&&this.safeAppend(r.split(`
|
|
6
|
+
`).map(a=>o?a:gt(a,n,i,e)).map(a=>new Qr(t,a,n,i,{}))),i.splice(i.indexOf(this),1),i.push(this)}}});var _s,xr,Pt,Xr,Pn,wl,we,jn=x(()=>{"use strict";ne();B();Me();_s=[j];we=class extends(wl=v){constructor(e,r,n,i=[]){super(void 0,n,i);h(this,Pt);h(this,xr);b(this,xr,e);let o=new v(r[0],n,i);o.type="heading-title",o.setAttribute("stage",2);let a=new te(r[1],"heading-trail",n,i);this.append(o,a)}get type(){return"heading"}get level(){return g(this,xr)}toString(e){let r=$(this,Pt,Xr).call(this);return r+this.firstChild.toString(e)+r+this.lastChild.toString(e)}text(){let e=$(this,Pt,Xr).call(this);return e+this.firstChild.text()+e}getAttribute(e){return e==="invalid"?this.inHtmlAttrs()===2:e==="padding"?this.level:super.getAttribute(e)}getGaps(){return this.level}lint(e=this.getAbsoluteIndex(),r){}print(){{let e=$(this,Pt,Xr).call(this);return super.print({pre:e,sep:e})}}json(e,r,n=this.getAbsoluteIndex()){}};Pn=I(wl),xr=new WeakMap,Pt=new WeakSet,Xr=function(){return"=".repeat(this.level)},we=N(Pn,0,"HeadingToken",_s,we),E(Pn,1,we)});var Jr,Ms=x(()=>{"use strict";B();Jr=class extends v{get type(){return"parameter"}get anon(){return this.firstChild.length===0}get duplicated(){}constructor(t,e,r,n=[]){super(void 0,r,n);let i=new v(typeof t=="number"?void 0:t,r,n,{}),o=new v(e,r,n);i.type="parameter-key",i.setAttribute("stage",2),o.type="parameter-value",o.setAttribute("stage",2),this.append(i,o)}trimName(t,e=!0){let r=(typeof t=="string"?t:t.toString(!0)).replace(/^[ \t\n\0\v]+|([^ \t\n\0\v])[ \t\n\0\v]+$/gu,"$1");return this.setAttribute("name",r),r}afterBuild(){if(!this.anon){let{parentNode:t,firstChild:e}=this,r=this.trimName(e);t&&t.getArgs(r,!1,!1).add(this)}super.afterBuild()}toString(t){return this.anon?this.lastChild.toString(t):super.toString(t,"=")}text(){return this.anon?this.lastChild.text():super.text("=")}getGaps(){return this.anon?0:1}lint(t=this.getAbsoluteIndex(),e){}print(){return super.print({sep:this.anon?"":"="})}json(t,e,r=this.getAbsoluteIndex()){}}});var Ws,br,Ke,jt,qt,yr,Ot,ut,On,Us,qn,El,He,Ds=x(()=>{"use strict";J();Ce();gr();ne();B();Ms();We();Me();Ws=[j,De()];He=class extends(El=v){constructor(e,r,n,i=[]){var S,k;let o,a=/^(?:\s|\0\d+[cn]\x7F)*\0(\d+)h\x7F(?:\s|\0\d+[cn]\x7F)*/u.exec(e);a&&(o=Number(a[1]),e=e.replace(`\0${o}h`,i[o].toString().replace(/^\n/u,"")));super(void 0,n,i,{});h(this,ut);Z(this,"modifier","");h(this,br,"template");h(this,Ke,":");h(this,jt,!1);h(this,qt,new Map);h(this,yr,0);h(this,Ot);let{parserFunction:l,variable:p,functionHook:u}=n,d=(S=/^(?:\s|\0\d+[cn]\x7F)*\0\d+s\x7F/u.exec(e))==null?void 0:S[0];if(d)this.setAttribute("modifier",d),e=e.slice(d.length);else if(e.includes(":")){let[y,...T]=e.split(":"),[w]=/^(?:\s|\0\d+[cn]\x7F)*/u.exec((k=T[0])!=null?k:"");this.setModifier(`${y}:${w}`)&&(e=T.join(":").slice(w.length))}let c=e.search(/[::]/u),f=e[c]===":",m=c!==-1;if(m||r.length===0&&!g(this,jt)){let y=m?e.slice(0,c):e,T=m&&e.slice(c+1),w=z(y),F=m?w.slice(w.search(/\S/u))+(f?":":""):w.trim(),[,L,R]=zs(F,l),G=!("functionHook"in n)||u.includes(R),P=p.includes(R);if(m?R&&G:P){this.setAttribute("name",R),b(this,br,"magic-word"),f&&b(this,Ke,":");let V=new te(y,"magic-word-name",n,i);if(super.insertAt(V),T!==!1&&r.unshift([T]),this.name==="invoke")for(let _=0;_<2;_++){let X=r.shift();if(!X)break;let ae=new H(X.join("="),`invoke-${_?"function":"module"}`,n,i);super.insertAt(ae)}}}if(this.type==="template"){let y=z(e).trim();if(!this.normalizeTitle(y,10,{halfParsed:!0,temporary:!0}).valid)throw i.pop(),new SyntaxError("Invalid template name");let T=new H(e,"template-name",n,i,{});super.insertAt(T)}typeof o=="number"&&(i[o]=void 0);let A=this.isTemplate(),C=1;for(let y=0;y<r.length;y++){let T=r[y];A||this.name==="switch"&&y>0||this.name==="tag"&&y>1||(T[0]=T.join("="),T.length=1),T.length===1&&(T.unshift(C),C++),this.insertAt(new Jr(...T,n,i))}this.seal("modifier")}get type(){return g(this,br)}get module(){}get function(){}setModifier(e){let[,,r,n]=this.getAttribute("config").parserFunction,i=z(e).trim();if(e&&!i.endsWith(":"))return!1;let o=i.slice(0,-1).toLowerCase(),a=r.includes(o),l=n.includes(o);return(g(this,jt)?a:l||!e)||(ee.running||this.length>1)&&(a||l||!e)?(this.setAttribute("modifier",e),b(this,jt,a),!!e):!1}isTemplate(){return this.type==="template"||this.name==="invoke"}afterBuild(){this.modifier.includes("\0")&&this.setAttribute("modifier",this.buildFromStr(this.modifier,0)),super.afterBuild(),this.isTemplate()&&this.type==="template"&&(b(this,Ot,$(this,ut,On).call(this)),this.setAttribute("name",g(this,Ot).title))}toString(e){let{childNodes:r,length:n,firstChild:i,modifier:o,type:a}=this;return`{{${o}${a==="magic-word"?i.toString(e)+(n===1?"":g(this,Ke))+r.slice(1).map(l=>l.toString(e)).join("|"):super.toString(e,"|")}}}`}text(){let{childNodes:e,length:r,firstChild:n,modifier:i,type:o,name:a}=this;return o==="magic-word"&&a==="vardefine"?"":`{{${i}${o==="magic-word"?n.text()+(r===1?"":g(this,Ke))+ge(e.slice(1),"|"):super.text("|")}}}`}getAttribute(e){switch(e){case"padding":return this.modifier.length+2;case"title":return g(this,Ot);case"colon":return g(this,Ke);case"invalid":return this.type==="magic-word"&&this.name==="invoke"&&(this.length===2||!$(this,ut,On).call(this).valid);default:return super.getAttribute(e)}}lint(e=this.getAbsoluteIndex(),r){}insertAt(e,r=this.length){return super.insertAt(e,r),e.anon?$(this,ut,Us).call(this,e):e.name&&this.getArgs(e.name,!1,!1).add(e),e}getArgs(e,r,n=!0,i=!0){let o=String(e).replace(/^[ \t\n\0\v]+|([^ \t\n\0\v])[ \t\n\0\v]+$/gu,"$1"),a;return g(this,qt).has(o)?a=g(this,qt).get(o):(a=new Set,g(this,qt).set(o,a)),a}getDuplicatedArgs(){}getPossibleValues(){let{type:e,name:r,childNodes:n}=this;if(e==="template")throw new Error("TranscludeToken.getPossibleValues method is only for specific magic words!");let i,o;switch(r){case"if":case"ifexist":case"ifexpr":case"iferror":i=2;break;case"ifeq":i=3;break;case"switch":{let a=n.slice(2),l=a[a.length-1];o=[...a.filter(({anon:p})=>!p),...l!=null&&l.anon?[l]:[]].map(({lastChild:p})=>p);break}default:throw new Error("TranscludeToken.getPossibleValues method is only for specific magic words!")}o!=null||(o=n.slice(i,i+2).map(({lastChild:a})=>a));for(let a=0;a<o.length;){let{length:l,0:p}=o[a].childNodes.filter(u=>u.text().trim());if(l===0)o.splice(a,1);else if(l>1||!p.is("magic-word"))a++;else try{let u=p.getPossibleValues();Array.prototype.splice.apply(o,[a,1,...u]),a+=u.length}catch{a++}}return o}print(){{let{childNodes:e,length:r,firstChild:n,modifier:i,type:o}=this;return`<span class="wpb-${o}${this.getAttribute("invalid")?" wpb-invalid":""}">{{${o==="magic-word"?Ze(i)+n.print()+(r===1?"":g(this,Ke))+Ae(e.slice(1),{sep:"|"}):(i?`<span class="wpb-magic-word">${Ze(i)}</span>`:"")+Ae(e,{sep:"|"})}}}</span>`}}};qn=I(El),br=new WeakMap,Ke=new WeakMap,jt=new WeakMap,qt=new WeakMap,yr=new WeakMap,Ot=new WeakMap,ut=new WeakSet,On=function(){let e=this.type==="template";return this.normalizeTitle((e?"":"Module:")+z(this.childNodes[e?0:1].text()),10,{temporary:!0,...!e&&{page:""}})},Us=function(e,r){b(this,yr,g(this,yr)+1);let n;n=g(this,yr)-1;let i=e,o=String(n+1);i.setAttribute("name",o),this.getArgs(o,!1,!1).add(i)},He=N(qn,0,"TranscludeToken",Ws,He),E(qn,1,He)});var Gs,_n,Nl,pt,Vs=x(()=>{"use strict";_e();ne();B();Gs=[oe(),j];pt=class extends(Nl=v){get type(){return"hidden"}getAttribute(t){return t==="invalid"||super.getAttribute(t)}};_n=I(Nl),pt=N(_n,0,"HiddenToken",Gs,pt),E(_n,1,pt)});var Hs,Wn,Il,Mn,$l,ct,Ks=x(()=>{"use strict";J();Te();gr();ne();B();We();Vs();Hs=[j,Y("{{{"),De()];ct=class extends($l=v){constructor(e,r,n=[]){super(void 0,r,n,{});h(this,Wn);for(let i=0;i<e.length;i++){let o=e[i];if(i===0){let a=new H(o,"arg-name",r,n,{});super.insertAt(a)}else if(i>1){let a=new pt(o,r,n);super.insertAt(a)}else{let a=new v(o,r,n);a.type="arg-default",a.setAttribute("stage",2),super.insertAt(a)}}}get type(){return"arg"}get default(){}toString(e){return`{{{${super.toString(e,"|")}}}}`}text(){return`{{{${ge(this.childNodes.slice(0,2),"|")}}}}`}afterBuild(){super.afterBuild()}lint(e=this.getAbsoluteIndex(),r){}print(){return super.print({pre:"{{{",post:"}}}",sep:"|"})}json(e,r,n=this.getAbsoluteIndex()){}};Mn=I($l),Wn=new WeakSet,Il=function(){},ct=N(Mn,0,"ArgToken",Hs,ct),E(Mn,1,ct)});var to={};W(to,{parseBraces:()=>Tr});var Ll,Qs,Un,Xs,Js,Ys,eo,Zs,Tr,Yr=x(()=>{"use strict";nr();J();jn();Ds();Ks();Ll={"=":String.raw`\n(?!(?:[^\S\n]|\0\d+[cn]\x7F)*\n)`,"{":String.raw`\}{2,}|\|`,"-":String.raw`\}-`,"[":String.raw`\]\]`},Qs=String.raw`\[(?!\[)`,Un=String.raw`\n(?![=\0])`,Xs=String.raw`|\{{2,}`,Js=new Map([["!","!"],["!!","+"],["(!","{"],["!)","}"],["!-","-"],["=","~"],["server","m"]]),Ys=je(s=>new RegExp(s,"gmu"));eo=new RegExp(String.raw`\{\{((?:[^\n{}[]|${Qs}|${Un})*)\}\}(?!\})`+"|"+String.raw`\[\[(?:[^\n[\]{]|${Un})*\]\]`+"|"+String.raw`-\{(?:[^\n{}[]|${Qs}|${Un})*\}-`,"gu");Zs=s=>{let t=ve(z(s));return Js.has(t)?Js.get(t):/^(?:filepath|(?:full|canonical)urle?):./u.test(t)?"m":/^#vardefine:./u.test(t)?"n":"t"},Tr=(s,t,e)=>{var m,A,C,S,k;let r=String.raw`${t.excludes.includes("heading")?"":String.raw`^((?:\0\d+[cno]\x7F)*)={1,6}|`}\[\[|-\{(?!\{)`,[,,,n]=t.parserFunction,i=[],o=[],a=(y,T,w,F)=>{T[T.length-1].push(se(y.slice(w,F),o))},l;do l!==void 0&&(s=l),l=s.replace(eo,(y,T,w)=>{if(T!==void 0||typeof w=="string")try{let{length:F}=e,L=(T!=null?T:w).split("|");return new He(se(L[0],o),L.slice(1).map(R=>{let G=R.indexOf("=");return(G===-1?[R]:[R.slice(0,G),R.slice(G+1)]).map(P=>se(P,o))}),t,e),`\0${F}${Zs(L[0])}`}catch(F){if(!(F instanceof SyntaxError)||F.message!=="Invalid template name")throw F}return o.push(se(y,o)),`\0${o.length-1}`});while(l!==s);s=l;let p=s.lastIndexOf("}}")-s.length,u=p+s.length!==-1,d=Ys(r+(u?Xs:"")),c=d.exec(s),f;for(;c||f!==void 0&&f<=s.length&&((A=(m=i[i.length-1])==null?void 0:m[0])!=null&&A.startsWith("="));){if(c!=null&&c[1]){let[,{length:X}]=c;c[0]=c[0].slice(X),c.index+=X}let{0:y,index:T}=c!=null?c:{0:`
|
|
7
|
+
`,index:s.length},w=(C=i.pop())!=null?C:{},{0:F,index:L,parts:R,findEqual:G,pos:P}=w,V=y==="="&&G;if(y==="]]"||y==="}-")f=T+2;else if(y===`
|
|
8
|
+
`){f=T+1;let{pos:X,findEqual:ae}=(S=i[i.length-1])!=null?S:{};if(X===void 0||ae||z(s.slice(X,L))!==""){let xe=/^(={1,6})(.+)\1((?:\s|\0\d+[cn]\x7F)*)$/u.exec(s.slice(L,T));xe&&(xe[2]=se(xe[2],o),xe[2].includes(`
|
|
9
|
+
`)||(s=`${s.slice(0,L)}\0${e.length}h${s.slice(T)}`,f=L+4+String(e.length).length,new we(xe[1].length,xe.slice(2),t,e)))}}else if(y==="|"||V)f=T+1,a(s,R,P,T),y==="|"&&R.push([]),w.pos=f,w.findEqual=y==="|",i.push(w);else if(y.startsWith("}}")){let X=y.slice(0,Math.min(F.length,3)),ae=F.length-X.length,{length:xe}=e;f=T+X.length,a(s,R,P,T);let hn=!1,Pr="t";if(X.length===3){let Pe=R.map(Ri=>Ri.join("=")),jr=Pe.length>1&&z(Pe[1]).trim();new ct(Pe,t,e),jr&&jr.endsWith(":")&&n.includes(jr.slice(0,-1).toLowerCase())&&(Pr="s")}else try{new He(R[0][0],R.slice(1),t,e),Pr=Zs(R[0][0])}catch(Pe){if(!(Pe instanceof SyntaxError&&Pe.message==="Invalid template name"))throw Pe;hn=!0}hn||(s=`${s.slice(0,L+ae)}\0${xe}${Pr}${s.slice(f)}`,f=L+ae+3+String(xe).length,ae>1?i.push({0:F.slice(0,ae),index:L,pos:L+ae,parts:[[]]}):ae===1&&s[L-1]==="-"&&i.push({0:"-{",index:L-1,pos:L+1,parts:[[]]}))}else f=T+y.length,y.startsWith("{")&&(c.pos=f,c.parts=[[]]),i.push(..."0"in w?[w]:[],c);let _=i[i.length-1];if(u&&p+s.length<f)for(u=!1;(k=_==null?void 0:_[0])!=null&&k.startsWith("{");)i.pop(),_=i[i.length-1];d=Ys(r+(u?Xs:"")+(_?`|${Ll[_[0][0]]}${_.findEqual?"|=":""}`:"")),d.lastIndex=f,c=d.exec(s)}return se(s,o)}});var ro={};W(ro,{InputboxToken:()=>Dn});var Dn,no=x(()=>{"use strict";hr();Yr();Bn();Dn=class extends mr{constructor(t,e,r,n,i=[]){let o=Symbol("InputboxToken"),a=n.excludes.includes("heading")?n:{...n,excludes:[...n.excludes,"heading"]},{length:l}=i;i.push(o),r&&(r=gt(r,a,i,e)),r&&(r=Tr(r,a,i)),i.splice(l,1),super(t,e,r,a,i,{})}}});var tn={};W(tn,{NestedToken:()=>zn});var Zr,en,zn,rn=x(()=>{"use strict";hr();Yr();B();Gn();nt();zn=class extends v{constructor(e,r,n,i,o=[]){if(typeof r=="boolean"){let a=Symbol("NestedToken"),{length:l}=o;o.push(a),e&&(e=gt(e,i,o,r)),e&&(e=Tr(e,i,o)),o.splice(l,1)}else e&&(e=e.replace(r,(a,l,p,u,d)=>{let c=`\0${o.length+1}e`;return new Ee(l,p,u,d,i,!1,o),c}));e&&(e=e.replace(/(^|\0\d+.\x7F)([^\0]+)(?=$|\0\d+.\x7F)/gu,(a,l,p)=>(new Q(p,i,o),`${l}\0${o.length}n`)));super(e,i,o);h(this,Zr);h(this,en);b(this,Zr,[...n]),b(this,en,r)}get type(){return"ext-inner"}lint(e=this.getAbsoluteIndex(),r){}};Zr=new WeakMap,en=new WeakMap});function Pl(s,t,e,r,n){t=z(t).trim();let i=t.replace(s==="link"?/\0\d+[tq]\x7F/gu:/\0\d+t\x7F/gu,"").trim();switch(s){case"width":return!i&&!!t||/^(?:\d+x?|\d*x\d+)(?:\s*px)?$/u.test(i);case"link":{let o=r==="gallery-image";if(i){if(Fl(e.protocol).test(i))return Rl(e.protocol).test(i)?t:o;i.startsWith("[[")&&i.endsWith("]]")&&(i=i.slice(2,-2))}else return t;let a=M.normalizeTitle(i,0,!1,e,{halfParsed:n,decode:!0,selfLink:!0,page:""});return a.valid?a:o}case"lang":return(r==="svg"||r==="svgz")&&!/[^a-z\d-]/u.test(i);case"alt":case"class":case"manualthumb":return!0;case"page":return(r==="djvu"||r==="djv"||r==="pdf")&&Number(i)>0;default:return!!i&&!isNaN(i)}}var Fl,Rl,Bl,io,ce,Hn,jl,Vn,ql,ft,so=x(()=>{"use strict";nr();J();Tn();ne();ue();B();Fl=je(s=>new RegExp(String.raw`^(?:${s}|//|\0\d+m\x7F)`,"iu")),Rl=je(s=>new RegExp(String.raw`^(?:(?:${s}|//)${Je}|\0\d+m\x7F)${Ye}$`,"iu")),Bl=je(s=>new RegExp(String.raw`^(\s*(?!\s))${s.replace("$1","(.*)")}${s.endsWith("$1")?`(?=$|
|
|
10
|
+
)`:""}(\s*)$`,"u"));io=[j];ft=class extends(ql=v){constructor(e,r,n,i,o){var t=(...Wp)=>(super(...Wp),h(this,Hn),h(this,ce,""),this);let a,l=Object.entries(i.img).map(([u,d])=>[u,d,Bl(u)]),p=l.find(([,u,d])=>(a=d.exec(e),a&&(a.length!==4||Pl(u,a[2],i,u==="link"?n:r,!0)!==!1)));if(p&&a){a.length===3?(t(void 0,i,o),b(this,ce,e)):(t(a[2],i,o,{}),b(this,ce,a[1]+p[0]+a[3])),this.setAttribute("name",p[1]),p[1]==="alt"&&this.setAttribute("stage",10);return}t(e,i.excludes.includes("list")?i:{...i,excludes:[...i.excludes,"list"]},o),this.setAttribute("name","caption"),this.setAttribute("stage",7)}get type(){return"image-parameter"}get thumb(){}get link(){}afterBuild(){var e;(e=this.parentNode)!=null&&e.is("gallery-image")&&!Di.has(this.name)&&this.setAttribute("name","invalid"),super.afterBuild()}toString(e){return g(this,ce)?g(this,ce).replace("$1",super.toString(e)):super.toString(e)}text(){return g(this,ce)?g(this,ce).replace("$1",super.text()).trim():super.text().trim()}isPlain(){return this.name==="caption"||this.name==="alt"}getAttribute(e){return e==="invalid"?this.name==="invalid":e==="padding"?Math.max(0,g(this,ce).indexOf("$1")):super.getAttribute(e)}lint(e=this.getAbsoluteIndex(),r){}getValue(){}print(){return g(this,ce)?`<span class="wpb-image-parameter${this.name==="invalid"?" wpb-invalid":""}">${g(this,ce).replace("$1",`<span class="wpb-image-caption">${Ae(this.childNodes)}</span>`)}</span>`:super.print({class:"image-caption"})}};Vn=I(ql),ce=new WeakMap,Hn=new WeakSet,jl=function(){},ft=N(Vn,0,"ImageParameterToken",io,ft),E(Vn,1,ft)});var Ol,_t,Kn=x(()=>{"use strict";$t();so();Ol=s=>{if(s===void 0)return[];let t=/-\{|\}-|\|/gu,e=[],r=t.exec(s),n=0,i=0;for(;r;){let{0:o,index:a}=r;o!=="|"?n+=o==="-{"?1:-1:n===0&&(e.push(s.slice(i,a)),{lastIndex:i}=t),r=t.exec(s)}return e.push(s.slice(i)),e},_t=class extends ie{get type(){return"file"}get extension(){}constructor(t,e,r,n=[],i="|",o){super(t,void 0,r,n,i);let{extension:a}=this.getTitle(!0,!0);this.safeAppend(Ol(e).map(l=>new ft(l,a,o,r,n)))}lint(t=this.getAbsoluteIndex(),e){}getAllArgs(){}getArgs(t){}getArg(t){}getValue(t){}json(t,e,r=this.getAbsoluteIndex()){}}});var oo,nn,ao,Qn,_l,Ne,Xn=x(()=>{"use strict";Te();B();Kn();oo=[Y("")];Ne=class extends(_l=_t){constructor(e,r,n,i,o=[]){let a;if(n!==void 0){let{length:p}=o;a=new v(n,i,o);for(let u=0;u<10;u++)a.parseOnce();o.splice(p,1)}let l=`${e}-image`;super(r,a==null?void 0:a.firstChild.toString(),i,o,void 0,l);h(this,nn);Z(this,"privateType","imagemap-image");this.setAttribute("bracket",!1),this.privateType=l,this.seal("privateType",!0)}get type(){return this.privateType}getTitle(e){let r=this.type==="imagemap-image";return this.normalizeTitle(this.firstChild.toString(),r?0:6,{halfParsed:!0,temporary:e,decode:!r,page:""})}lint(e=this.getAbsoluteIndex(),r){}getAttribute(e){return e==="invalid"?$(this,nn,ao).call(this):super.getAttribute(e)}};Qn=I(_l),nn=new WeakSet,ao=function(){return this.getAttribute("title").ns!==6},Ne=N(Qn,0,"GalleryImageToken",oo,Ne),E(Qn,1,Ne)});var mt,Jn=x(()=>{"use strict";nt();mt=class extends Q{}});var go={};W(go,{GalleryToken:()=>Yn});var kr,lo,Ml,Yn,uo=x(()=>{"use strict";Kr();Xn();Jn();Yn=class extends Ve{constructor(e,r,n=[]){var i;super(void 0,r,n,{});h(this,kr);for(let o of(i=e==null?void 0:e.split(`
|
|
11
|
+
`))!=null?i:[]){let a=/^([^|]+)(?:\|(.*))?/u.exec(o);if(!a){super.insertAt(o.trim()?new mt(o,r,n):o);continue}let[,l,p]=a;$(this,kr,lo).call(this,l)?super.insertAt(new Ne("gallery",l,p,r,n)):super.insertAt(new mt(o,r,n))}}get widths(){}get heights(){}lint(e=this.getAbsoluteIndex(),r){}json(e,r,n=this.getAbsoluteIndex()){}};kr=new WeakSet,lo=function(e){return this.normalizeTitle(e,6,{halfParsed:!0,temporary:!0,decode:!0,page:""}).valid},Ml=function(e){}});var Mt,Zn=x(()=>{"use strict";$t();Mt=class extends ie{get type(){return"link"}get innerText(){}lint(t=this.getAbsoluteIndex(),e){}}});var Wl,Ul,vr,Ar,po,Dl,Ie,sn=x(()=>{"use strict";J();ue();B();Wl=String.raw`(?:[${be}\t]| |�*160;|&#[xX]0*[aA]0;)`,Ul=new RegExp(`${Wl}+`,"gu"),Ie=class extends v{constructor(e,r="free-ext-link",n=M.getConfig(),i){super(e,n,i,{});h(this,Ar);h(this,vr);b(this,vr,r)}get type(){return g(this,vr)}get innerText(){let e=new Map([["!","|"],["=","="]]),r=ge(this.childNodes.map(n=>{let{type:i}=n,o=String(n.name);return i==="magic-word"&&e.has(o)?e.get(o):n}));return this.type==="magic-link"&&(r=r.replace(Ul," ")),r}get link(){let{innerText:e}=this;return this.type==="magic-link"?e.startsWith("ISBN")?`ISBN ${e.slice(5).replace(/[- ]/gu,"").replace(/x$/u,"X")}`:e:Wi(e).replace(/\n/gu,"%0A")}lint(e=this.getAbsoluteIndex(),r){}getUrl(e){this.lspError("MagicLinkToken.getUrl")}getAttribute(e){return e==="invalid"?$(this,Ar,po).call(this):super.getAttribute(e)}};vr=new WeakMap,Ar=new WeakSet,po=function(){if(this.type==="magic-link"){let{link:e}=this;if(e.startsWith("ISBN")){let r=[...e.slice(5)].map(n=>n==="X"?10:Number(n));return r.length===10?r.reduce((n,i,o)=>n+i*(10-o),0)%11!==0:r.length===13&&(r[12]===10||r.reduce((n,i,o)=>n+i*(o%2?3:1),0)%10!==0)}}return!1},Dl=function(){}});var co,$e,ei,zl,Le,ti=x(()=>{"use strict";Te();B();sn();co=[Y("[")];Le=class extends(zl=v){constructor(e,r="",n="",i,o=[]){super(void 0,i,o,{});h(this,$e);let a=e&&/^\0\d+f\x7F$/u.test(e)?o[Number(e.slice(1,-2))]:new Ie(e,"ext-link-url",i,o);if(this.insertAt(a),b(this,$e,r),n){let l=new v(n,i,o,{});l.type="ext-link-text",l.setAttribute("stage",10),this.insertAt(l)}}get type(){return"ext-link"}toString(e){return this.length===1?`[${super.toString(e)}${g(this,$e)}]`:`[${super.toString(e,g(this,$e))}]`}text(){return`[${super.text(" ")}]`}getGaps(){return g(this,$e).length}lint(e=this.getAbsoluteIndex(),r){}print(){return super.print(this.length===1?{pre:"[",post:`${g(this,$e)}]`}:{pre:"[",sep:g(this,$e),post:"]"})}};ei=I(zl),$e=new WeakMap,Le=N(ei,0,"ExtLinkToken",co,Le),E(ei,1,Le)});var Cr,fo=x(()=>{"use strict";B();nt();Zn();ti();Cr=class extends v{get type(){return"imagemap-link"}constructor(t,e,r,n,i=[]){super(void 0,n,i),this.append(t,e.length===2?new Mt(...e,n,i):new Le(...e,n,i),new Q(r,n,i))}}});var mo={};W(mo,{ImagemapToken:()=>ri});var ri,ho=x(()=>{"use strict";Ce();ue();Kr();Jn();Xn();fo();ri=class extends Ve{get image(){return this.childNodes.find(xo("imagemap-image"))}constructor(t,e=M.getConfig(),r=[]){if(super(void 0,e,r,{}),!t)return;let n=t.split(`
|
|
12
|
+
`),i=new Set(e.protocol.split("|")),o=!0,a=!1;for(let l of n){let p=l.trim();if(!(a||!p||p.startsWith("#"))){if(o){let u=l.indexOf("|"),d=u===-1?l:l.slice(0,u),c=this.normalizeTitle(d,0,{halfParsed:!0,temporary:!0,page:""});if(c.valid&&c.ns===6){let f=new Ne("imagemap",d,u===-1?void 0:l.slice(u+1),e,r);super.insertAt(f),o=!1;continue}else a=!0}else if(l.trim().split(/[\t ]/u,1)[0]==="desc"){super.insertAt(l);continue}else if(l.includes("[")){let u=l.indexOf("["),d=l.slice(u),c=/^\[\[([^|]+)(?:\|([^\]]*))?\]\][\w\s]*$/u.exec(d);if(c){if(this.normalizeTitle(c[1],0,{halfParsed:!0,temporary:!0,selfLink:!0,page:""}).valid){super.insertAt(new Cr(l.slice(0,u),c.slice(1),d.slice(d.indexOf("]]")+2),e,r));continue}}else if(d.startsWith("[//")||i.has(d.slice(1,d.indexOf(":")+1))||i.has(d.slice(1,d.indexOf("//")+2))){let f=/^\[([^\]\s]+)(?:(\s+(?!\s))([^\]]*))?\][\w\s]*$/u.exec(d);if(f){super.insertAt(new Cr(l.slice(0,u),f.slice(1),d.slice(d.indexOf("]")+1),e,r));continue}}}}super.insertAt(new mt(l,e,r))}}lint(t=this.getAbsoluteIndex(),e){}getAttribute(t){return t==="invalid"?!this.image:super.getAttribute(t)}}});var bo,ni,Gl,Fe,ii=x(()=>{"use strict";_e();Te();Ue();bo=[oe(!1),Y("<!--")];Fe=class extends(Gl=K){constructor(e,r,n,i){super(e,n,i);Z(this,"closed");this.closed=r}get type(){return"comment"}lint(e=this.getAbsoluteIndex()){}toString(e){return e?"":`<!--${this.innerText}${this.closed?"-->":""}`}print(){return super.print({pre:"<!--",post:this.closed?"-->":""})}};ni=I(Gl),Fe=N(ni,0,"CommentToken",bo,Fe),E(ni,1,Fe)});var yo={};W(yo,{CommentedToken:()=>si});var si,To=x(()=>{"use strict";B();ii();si=class extends v{get type(){return"ext-inner"}constructor(t,e,r=[]){if(super(void 0,e,r,{AstText:":",CommentToken:":"}),t){let n=t.indexOf("<!--"),i=n!==-1&&t.indexOf("-->",n+4),o=0;for(;i!==!1&&i!==-1;)n>o&&this.insertAt(t.slice(o,n)),this.insertAt(new Fe(t.slice(n+4,i),!0,e,r)),o=i+3,n=t.indexOf("<!--",o),i=n!==-1&&t.indexOf("-->",n+4);o<t.length&&this.insertAt(t.slice(o))}}lint(t=this.getAbsoluteIndex()){}}});var vo={};W(vo,{CategorytreeToken:()=>Wt});var ko,oi,Vl,Wt,Ao=x(()=>{"use strict";Te();$t();ko=[Y("")];Wt=class extends(Vl=ie){get type(){return"ext-inner"}constructor(t,e,r,n=[]){super(t,e,r,n),this.setAttribute("bracket",!1)}getTitle(){let t=this.firstChild.toString().trim(),e={halfParsed:!0},r=this.normalizeTitle(t,14,e);return r.valid&&r.ns===14?r:this.normalizeTitle(`Category:${t}`,0,e)}lint(t=this.getAbsoluteIndex()){}};oi=I(Vl),Wt=N(oi,0,"CategorytreeToken",ko,Wt),E(oi,1,Wt)});var So={};W(So,{NowikiToken:()=>ai});var Hl,on,Co,ai,wo=x(()=>{"use strict";Ue();Hl=new Set(["languages","section","templatestyles"]),ai=class extends K{constructor(){super(...arguments);h(this,on)}get type(){return"ext-inner"}lint(e=this.getAbsoluteIndex()){}getAttribute(e){return e==="invalid"?$(this,on,Co).call(this):super.getAttribute(e)}};on=new WeakSet,Co=function(){let{name:e,firstChild:{data:r}}=this;return Hl.has(e)&&!!r}});var Eo,li,Kl,Ee,Gn=x(()=>{"use strict";ue();Vr();B();Gr();Hr();Eo=[Ft()];Ee=class extends(Kl=he){get type(){return"ext"}constructor(t,e,r,n,i=M.getConfig(),o=!1,a=[]){let l=t.toLowerCase(),p=new Ge(!e||/^\s/u.test(e)?e:` ${e}`,"ext-attrs",l,i,a),u={...i,ext:i.ext.filter(c=>c!==l),excludes:[...i.excludes],inExt:!0},d;switch(l){case"pre":if(p.getAttr("format")!=="wikitext"){let{PreToken:c}=(js(),q(Ps));d=new c(r,u,a);break}u.excludes.push("list");case"indicator":case"poem":case"ref":case"option":case"combooption":case"tab":case"tabs":case"poll":case"seo":case"langconvert":case"phonos":switch(l){case"poem":u.excludes.push("heading");break;case"langconvert":u.excludes.push("list");break;case"tab":u.ext=u.ext.filter(c=>c!=="tabs");break;case"ref":u.ext=u.ext.filter(c=>c!=="references")}d=new v(r,u,a);break;case"dynamicpagelist":{let{ParamTagToken:c}=(Bn(),q(Os));d=new c(l,o,r,u,a);break}case"inputbox":{let{InputboxToken:c}=(no(),q(ro));d=new c(l,o,r,u,a);break}case"references":{let{NestedToken:c}=(rn(),q(tn));u.excludes.push("heading"),d=new c(r,o,["ref"],u,a);break}case"choose":{let{NestedToken:c}=(rn(),q(tn));d=new c(r,/<(option|choicetemplate)(\s[^>]*?)?(?:\/>|>([\s\S]*?)<\/(\1)>)/gu,["option","choicetemplate"],u,a);break}case"combobox":{let{NestedToken:c}=(rn(),q(tn));d=new c(r,/<(combooption)(\s[^>]*?)?(?:\/>|>([\s\S]*?)<\/(combooption\s*)>)/giu,["combooption"],u,a);break}case"gallery":{let{GalleryToken:c}=(uo(),q(go));d=new c(r,u,a);break}case"imagemap":{let{ImagemapToken:c}=(ho(),q(mo));d=new c(r,u,a);break}case"hiero":{let{CommentedToken:c}=(To(),q(yo));d=new c(r,u,a);break}case"categorytree":{let{CategorytreeToken:c}=(Ao(),q(vo));d=new c(r,void 0,u,a);break}default:{let{NowikiToken:c}=(wo(),q(So));d=new c(r,u,a)}}d.setAttribute("name",l),d.type==="plain"&&(d.type="ext-inner"),super(t,p,d,n,i,a),this.seal("closed",!0)}lint(t=this.getAbsoluteIndex(),e){}};li=I(Kl),Ee=N(li,0,"ExtToken",Eo,Ee),E(li,1,Ee)});var Qe,Xe,di,Ut,gi=x(()=>{"use strict";B();Ut=class extends v{constructor(e,r,n,i,o){super(void 0,i,o);h(this,Qe);h(this,Xe);h(this,di);this.insertAt(r),b(this,Qe,n),b(this,Xe,e)}get closing(){return g(this,Qe)}toString(e){return`<${g(this,Qe)?"/":""}${g(this,Xe)}${super.toString(e)}${this.selfClosing?"/":""}>`}text(e=""){let{closing:r}=this;return`<${r&&!e?"/":""}${g(this,Xe)}${r?"":super.text()}${e}>`}getAttribute(e){return e==="padding"?g(this,Xe).length+(g(this,Qe)?2:1):super.getAttribute(e)}findMatchingTag(){}print(){return super.print({pre:`<${g(this,Qe)?"/":""}${g(this,Xe)}`,post:`${this.selfClosing?"/":""}>`})}json(e,r,n=this.getAbsoluteIndex()){}};Qe=new WeakMap,Xe=new WeakMap,di=new WeakMap});var No,ui,Ql,ke,Io=x(()=>{"use strict";_e();ne();gi();Me();No=[oe(),j];ke=class extends(Ql=Ut){get type(){return"tvar"}constructor(t,e,r,n,i){let o=new te(e,"tvar-name",n,i);super(t,o,r,n,i)}};ui=I(Ql),ke=N(ui,0,"TvarToken",No,ke),E(ui,1,ke)});var Lo={};W(Lo,{TranslateToken:()=>pi});var an,$o,pi,Fo=x(()=>{"use strict";B();Gr();Me();Io();pi=class extends he{constructor(e,r,n,i=[]){let o=new te(e,"translate-attr",n,i);r=r==null?void 0:r.replace(/<tvar(\|[^>]+)>([\s\S]*?)<\/>/gu,(l,p,u)=>(new ke("tvar",p,!1,n,i),new ke("","",!0,n,i),`\0${i.length-2}n${u}\0${i.length}n`)).replace(/<(tvar)(\s+name\s*=(?:\s*(?:(["'])[\s\S]*?\3|[^"'\s>]+))?\s*)>([\s\S]*?)<\/(tvar)(\s*)>/giu,(l,p,u,d,c,f,m)=>(new ke(p,u,!1,n,i),new ke(f,m,!0,n,i),`\0${i.length-2}n${c}\0${i.length}n`));let a=new v(r,n,i);a.type="translate-inner";super("translate",o,a,"translate",n,i);h(this,an);this.seal("closed",!0)}get type(){return"translate"}get selfClosing(){return!1}toString(e){return e?this.lastChild.toString(!0):super.toString()}text(){return this.lastChild.text()}print(){return`<span class="wpb-ext"><translate${$(this,an,$o).call(this)?'<span class="wpb-ext-attrs"> <span class="wpb-ext-attr"><span class="wpb-attr-key">nowrap</span></span></span>':""}>${this.lastChild.print({class:"ext-inner"})}</translate></span>`}};an=new WeakSet,$o=function(){return this.firstChild.toString()===" nowrap"}});var Po={};W(Po,{parseCommentAndExt:()=>gt});var Bo,Xl,ci,Jl,Ro,gt,hr=x(()=>{"use strict";nr();J();fs();nt();xs();Gn();ii();Bo="<onlyinclude>",Xl="</onlyinclude>",{length:ci}=Bo,Jl=[!1,!0].map(s=>{let t=s?"includeonly":"(?:no|only)include",e=s?"noinclude":"includeonly";return je(r=>new RegExp(String.raw`<!--[\s\S]*?(?:-->|$)|<${t}(?:\s[^>]*)?/?>|</${t}\s*>|<(${r})(\s[^>]*?)?(?:/>|>([\s\S]*?)</(${"\\1"}\s*)>)|<(${e})(\s[^>]*?)?(?:/>|>([\s\S]*?)(?:</(${e}\s*)>|$))`,"giu"))}),Ro=s=>{let t=s.indexOf(Bo);return{i:t,j:s.indexOf(Xl,t+ci)}},gt=(s,t,e,r)=>{if(r){let{i:l,j:p}=Ro(s);if(l!==-1&&p!==-1){let u="",d=c=>{new Q(c,t,e),u+=`\0${e.length-1}n`};for(;l!==-1&&p!==-1;){let c=`\0${e.length}g`;new ot(s.slice(l+ci,p),t,e),l>0&&d(s.slice(0,l)),u+=c,s=s.slice(p+ci+1),{i:l,j:p}=Ro(s)}return s&&d(s),u}}let{ext:n}=t,i=n,o=t;if(n.includes("translate")){let{TranslateToken:l}=(Fo(),q(Lo)),p=[];i=n.filter(u=>u!=="translate"&&u!=="tvar"),o={...t,ext:i},s=s.replace(/<nowiki>[\s\S]*?<\/nowiki>/giu,u=>(p.push(u),`\0${p.length-1}`)).replace(/<translate( nowrap)?>([\s\S]*?)<\/translate>/gu,(u,d,c)=>{let f=e.length;return new l(d,c&&se(c,p),o,e),`\0${f}g`}),s=se(s,p)}let a=Jl[r?1:0](i.join("|"));return a.lastIndex=0,a.test(s)?s.replace(a,(l,p,u,d,c,f,m,A,C)=>{let S=e.length,k="n";if(p)k="e",new Ee(p,u,d,c,o,f,e);else if(l.startsWith("<!--")){k="c";let y=l.endsWith("-->");new Fe(se(l,e,1).slice(4,y?-3:void 0),y,t,e)}else f?new at(f,m&&se(m,e,1),A&&se(A,e,1),C,t,e):new Q(l,t,e,!0);return`\0${S}${k}`}):s}});var jo,Sr,fi,Yl,ht,qo=x(()=>{"use strict";Vr();gi();jo=[Ft()];ht=class extends(Yl=Ut){constructor(e,r,n,i,o,a){super(e,r,n,o,a);h(this,Sr);this.setAttribute("name",e.toLowerCase()),b(this,Sr,i)}get type(){return"html"}get selfClosing(){return g(this,Sr)}text(){let{closing:e,selfClosing:r,name:n}=this,[,,i]=this.getAttribute("config").html;return i.includes(n)?e&&n!=="br"?"":super.text("/"):super.text(r&&!e?"/":"")}lint(e=this.getAbsoluteIndex(),r){}getAttribute(e){return e==="invalid"?this.inTableAttrs()===2:super.getAttribute(e)}json(e,r,n=this.getAbsoluteIndex()){}};fi=I(Yl),Sr=new WeakMap,ht=N(fi,0,"HtmlToken",jo,ht),E(fi,1,ht)});var Oo={};W(Oo,{parseHtml:()=>ed});var Zl,ed,_o=x(()=>{"use strict";Hr();qo();Zl=/^(\/?)([a-z][^\s/>]*)((?:\s|\/(?!>))[^>]*?)?(\/?>)([^<]*)$/iu,ed=(s,t,e)=>{var o;let{html:r}=t;(o=t.htmlElements)!=null||(t.htmlElements=new Set([...r[0],...r[1],...r[2]]));let n=s.split("<"),i=n.shift();for(let a of n){let l=Zl.exec(a),p=l==null?void 0:l[2],u=p==null?void 0:p.toLowerCase();if(!l||!t.htmlElements.has(u)){i+=`<${a}`;continue}let[,d,,c="",f,m]=l,{length:A}=e,C=new Ge(c,"html-attrs",u,t,e),S=C.hasAttr("itemprop");if(u==="meta"&&!(S&&C.hasAttr("content"))||u==="link"&&!(S&&C.hasAttr("href"))){i+=`<${a}`,e.length=A;continue}i+=`\0${e.length}x${m}`,new ht(p,C,d==="/",f==="/>",t,e)}return i}});var Mo,mi,td,Re,hi=x(()=>{"use strict";Vr();B();Me();Hr();Mo=[Ft(1)];Re=class extends(td=v){constructor(t,e,r,n,i,o=[],a){super(void 0,i,o,a),this.append(new te(e,"table-syntax",i,o),new Ge(n,"table-attrs",r,i,o))}escape(){}};mi=I(td),Re=N(mi,0,"TableBaseToken",Mo,Re),E(mi,1,Re)});var Wo,Uo,fe,xi,Dt,wr,Er,Do=x(()=>{"use strict";Mr();B();hi();Er=class extends(Uo=Re,Wo=[St(!1)],Uo){constructor(e,r,n,i=[]){var p;let o=/\||\0\d+!\x7F/u.exec(r!=null?r:""),a=o?r.slice(0,o.index):"";/\[\[|-\{/u.test(a)&&(o=null,a="");super(/^(?:\n[^\S\n]*(?:[|!]|\|\+|\{\{\s*!\s*\}\}\+?)|(?:\||\{\{\s*!\s*\}\}){2}|!!|\{\{\s*!!\s*\}\})$/u,e,"td",a,n,i);E(xi,5,this);h(this,Dt);h(this,fe,"");o&&([qr(this,fe)._]=o);let l=new v(r==null?void 0:r.slice(((p=o==null?void 0:o.index)!=null?p:NaN)+g(this,fe).length),n,i);l.type="td-inner",l.setAttribute("stage",4),this.insertAt(l)}get type(){return"td"}get rowspan(){}get colspan(){}get subtype(){return $(this,Dt,wr).call(this).subtype}afterBuild(){g(this,fe).includes("\0")&&b(this,fe,this.buildFromStr(g(this,fe),0)),super.afterBuild()}toString(e){let[r,n,i]=this.childNodes;return r.toString(e)+n.toString(e)+g(this,fe)+i.toString(e)}text(){let[e,r,n]=this.childNodes;return e.text()+r.text()+g(this,fe)+n.text()}getGaps(e){return e===1?g(this,fe).length:0}lint(e=this.getAbsoluteIndex(),r){}isIndependent(){return this.firstChild.text().startsWith(`
|
|
13
|
+
`)}getAttr(e){}escape(){}print(){{let[e,r,n]=this.childNodes;return`<span class="wpb-td">${e.print()}${r.print()}${g(this,fe)}${n.print()}</span>`}}json(e,r,n=this.getAbsoluteIndex()){}};xi=I(Uo),fe=new WeakMap,Dt=new WeakSet,wr=function(){var a;let e=this.firstChild.text(),r=e.slice(-1),n="td";if(r==="!"?n="th":r==="+"&&(n="caption"),this.isIndependent())return{subtype:n};let{previousSibling:i}=this;return{...$(a=i,Dt,wr).call(a)}},wr=N(xi,17,"#getSyntax",Wo,Dt,wr),tr(xi,Er)});var zt,bi=x(()=>{"use strict";hi();zt=class extends Re{lint(t=this.getAbsoluteIndex(),e){}getRowCount(){}}});var zo,Go,yi,Gt,Vo=x(()=>{"use strict";Ce();Mr();bi();Me();Gt=class extends(Go=zt,zo=[St(!1)],Go){constructor(e,r,n,i){super(/^(?:\{\||\{\{\{\s*!\s*\}\}|\{\{\s*\(!\s*\}\})$/u,e,"table",r,n,i,{});E(yi,5,this)}get type(){return"table"}get closed(){}lint(e=this.getAbsoluteIndex(),r){}close(e=`
|
|
14
|
+
|}`,r){ee.run(()=>{let n=new te(r?e:void 0,"table-syntax",this.getAttribute("config"),this.getAttribute("accum"));super.insertAt(n)})}getLayout(e){}getAllRows(){}getNthRow(e,r,n){}json(e,r,n=this.getAbsoluteIndex()){}};yi=I(Go),N(yi,1,"getLayout",zo,Gt),tr(yi,Gt)});var ln,Ho=x(()=>{"use strict";bi();ln=class extends zt{get type(){return"tr"}constructor(t,e,r,n){super(/^\n[^\S\n]*(?:\|-+|\{\{\s*!\s*\}\}-+|\{\{\s*!-\s*\}\}-*)$/u,t,"tr",e,r,n)}}});var Vt,Ti=x(()=>{"use strict";Ue();Vt=class extends K{get indent(){}json(t,e,r=this.getAbsoluteIndex()){}}});var Ht,ki=x(()=>{"use strict";Ti();Ht=class extends Vt{get type(){return"dd"}}});var Qo={};W(Qo,{parseTable:()=>nd});var rd,Ko,nd,Xo=x(()=>{"use strict";B();Vo();Ho();Do();ki();rd=s=>s.lastChild.constructor!==v,Ko=(s,t)=>s.is("td")?t.pop():s,nd=({firstChild:{data:s},type:t,name:e},r,n)=>{let i=[],o=s.split(`
|
|
15
15
|
`),a=t==="root"||t==="parameter-value"||t==="ext-inner"&&e==="poem"?"":`
|
|
16
|
-
${o.shift()}`,l,p=(u,d)=>{if(!d){a+=u;return}let{lastChild:c}=d;if(
|
|
16
|
+
${o.shift()}`,l,p=(u,d)=>{if(!d){a+=u;return}let{lastChild:c}=d;if(rd(d)){let f=new v(u,r,n);f.type="table-inter",f.setAttribute("stage",3),d.insertAt(f)}else c.setText(c.toString()+u)};for(let u of o){l=i.pop();let[d]=/^(?:\s|\0\d+[cno]\x7F)*/u.exec(u),c=u.slice(d.length),f=/^(:*)((?:\s|\0\d+[cn]\x7F)*)(\{\||\{(?:\0\d+[cn]\x7F)*\0\d+!\x7F|\0\d+\{\x7F)(.*)$/u.exec(c);if(f){for(;l&&!l.is("td");)l=i.pop();let[,y,T,w,F]=f;y&&new Ht(y,r,n),p(`
|
|
17
17
|
${d}${y&&`\0${n.length-1}d`}${T}\0${n.length}b`,l),i.push(...l?[l]:[],new Gt(w,F,r,n));continue}else if(!l){a+=`
|
|
18
18
|
${u}`;continue}let m=/^(?:(\|\}|\0\d+!\x7F\}|\0\d+\}\x7F)|(\|-+|\0\d+!\x7F-+|\0\d+-\x7F-*)(?!-)|(!|(?:\||\0\d+!\x7F)\+?))(.*)$/u.exec(c);if(!m){p(`
|
|
19
|
-
${u}`,l),i.push(l);continue}let[,C,
|
|
20
|
-
${d}${
|
|
21
|
-
${d}${
|
|
22
|
-
${d}${S}`,L=R=>{let G=new Er(F,k.slice(w,T==null?void 0:T.index),r,n);return R.insertAt(G),G};for(;T;)L(l),{lastIndex:w}=y,[F]=T,T=y.exec(k);i.push(l,L(l))}}return a.slice(1)}});var Nr,
|
|
23
|
-
`)&&(S=z(f).trim());let{ns:y,valid:T}=W.normalizeTitle(S,0,!1,t,{halfParsed:!0,temporary:!0,decode:!0,selfLink:!0,page:r});if(T){if(u){if(y!==6){a+=`[[${C}`;continue}let F=!1;for(p++;p<o.length;p++){let L=o[p],R=L.split("]]");if(R.length>2){F=!0,f+=`[[${R[0]}]]${R[1]}`,m=R.slice(2).join("]]");break}else if(R.length===2)f+=`[[${R[0]}]]${R[1]}`;else{f+=`[[${L}`;break}}if(f=oa(f,t,e,r,n),!F){a+=`[[${d}${c}${f}`;continue}}}else{a+=`[[${C}`;continue}f&&(f=Ci(f,t,e,n));let w=Wt;k||(y===6?(f&&(f=Si(f,t,e,!0)),w=_t):y===14&&(w=pn)),f===void 0&&c&&(f=""),a+=`\0${e.length}l${m}`,new w(d,f,t,e,c)}return a}});var ca={};M(ca,{parseMagicLinks:()=>od});var pa,da,ga,ua,od,fa=x(()=>{"use strict";J();sn();pa=String.raw`[${be}\t]| |�*160;|�*a0;`,da=`(?:${pa})+`,ga=`(?:${pa}|-)`,ua=String.raw`(?:RFC|PMID)${da}\d+\b|ISBN${da}(?:97[89]${ga}?)?(?:\d${ga}?){9}[\dx]\b`,od=(s,t,e)=>{if(!t.regexMagicLinks)try{t.regexMagicLinks=new RegExp(String.raw`(^|[^\p{L}\p{N}_])(?:(?:${t.protocol})(${Je}${Ye})|${ua})`,"giu")}catch{t.regexMagicLinks=new RegExp(String.raw`(^|\W)(?:(?:${t.protocol})(${Je}${Ye})|${ua})`,"giu")}return s.replace(t.regexMagicLinks,(r,n,i)=>{let o=n?r.slice(n.length):r;if(i){let a="",l=/&(?:[lg]t|nbsp|#x0*(?:3[ce]|a0)|#0*(?:6[02]|160));/iu.exec(o);l&&(a=o.slice(l.index),o=o.slice(0,l.index));let p=o.includes("(")?/[^,;\\.:!?][,;\\.:!?]+$/u:/[^,;\\.:!?)][,;\\.:!?)]+$/u,u=p.exec(o);if(u){let d=1;u[0][1]===";"&&/&(?:[a-z]+|#x[\da-f]+|#\d+)$/iu.test(o.slice(0,u.index))&&(d=2),a=o.slice(u.index+d)+a,o=o.slice(0,u.index+d)}return a.length>=i.length?r:(new Ie(o,void 0,t,e),`${n}\0${e.length-1}w${a}`)}else if(!/^(?:RFC|PMID|ISBN)/u.test(o))return r;return new Ie(o,"magic-link",t,e),`${n}\0${e.length-1}i`})}});var ma,ha=x(()=>{"use strict";ma=(s,t)=>s.startsWith(t)?t.length:[...t].findIndex((e,r)=>e!==s[r])});var cn,xa=x(()=>{"use strict";Ti();cn=class extends Vt{get type(){return"list"}lint(t=this.getAbsoluteIndex()){}}});var ba={};M(ba,{parseList:()=>ad});var ad,ya=x(()=>{"use strict";ha();xa();ki();ad=(s,t,e,r)=>{let n=/^((?:\0\d+[cno]\x7F)*)([;:*#]+)(\s*)/u.exec(s);if(!n)return t.lastPrefix="",s;let[i,o,a,l]=n,p=a.replace(/;/gu,":"),u=ma(p,t.lastPrefix),d=((u>1?a.slice(u-1):a)+l).split(/(?=;)/u),c=d[0].startsWith(";"),f=d.length-(c?0:1);if(u>1){let P=a.slice(0,u-1);if(c){let V=P.split(/(?=;)/u);d.unshift(...V),f+=P.includes(";")?V.length:0}else d[0]=P+d[0]}t.lastPrefix=p;let m=o+d.map((P,V)=>`\0${r.length+V}d`).join("")+s.slice(i.length);for(let P of d)new cn(P,e,r);if(!f)return m;let[C,,A]=e.html,S=/:+|-\{|\0\d+[xq]\x7F/gu,k=S,y=k.exec(m),T=0,w=!1,F=!1,L=0,R=(P,V)=>(new Ht(P,e,r),`${m.slice(0,V)}\0${r.length-1}d${m.slice(V+P.length)}`),G=P=>{P?T&&T--:T++};for(;y&&f;){let{0:P,index:V}=y;if(P==="-{"){if(!L){let{lastIndex:_}=k;k=/-\{|\}-/gu,k.lastIndex=_}L++}else if(P==="}-"){if(L--,!L){let{lastIndex:_}=k;k=S,k.lastIndex=_}}else if(P.endsWith("x")){let{name:_,closing:K,selfClosing:ae}=r[Number(P.slice(1,-2))];(C.includes(_)||!ae&&!A.includes(_))&&G(K)}else if(P.endsWith("q")){let{bold:_,italic:K}=r[Number(P.slice(1,-2))];_&&(G(w),w=!w),K&&(G(F),F=!F)}else if(T===0){if(P.length>=f)return R(P.slice(0,f),V);f-=P.length,k.lastIndex=V+4+String(r.length).length,m=R(P,V)}y=k.exec(m)}return m}});var ld,Ta,yt,Ei,dd,bt,ka=x(()=>{"use strict";gr();ne();B();Me();ld=new Set(["A","T","R","D","-","H","N"]);Ta=[De(),j];bt=class extends(dd=v){constructor(e,r,n=[]){super(void 0,r,n,{});h(this,yt);this.safeAppend(e.map(i=>new H(i,"converter-flag",r,n)))}get type(){return"converter-flags"}afterBuild(){b(this,yt,this.childNodes.map(e=>e.text().trim())),super.afterBuild()}toString(e){return super.toString(e,";")}text(){return super.text(";")}getUnknownFlags(){return new Set(g(this,yt).filter(e=>/\{{3}[^{}]+\}{3}/u.test(e)))}getVariantFlags(){let e=new Set(this.getAttribute("config").variants);return new Set(g(this,yt).filter(r=>e.has(r)))}isInvalidFlag(e,r,n){if(typeof e=="object"){let i=new Set(this.getAttribute("config").variants);e=e.text().trim(),r=g(this,yt).some(o=>i.has(o))?i:new Set,n=this.getUnknownFlags()}return!!e&&!r.has(e)&&!n.has(e)&&(r.size>0||!ld.has(e))}lint(e=this.getAbsoluteIndex(),r){}print(){return super.print({sep:";"})}};Ei=I(dd),yt=new WeakMap,bt=N(Ei,0,"ConverterFlagsToken",Ta,bt),E(Ei,1,bt)});var Ni,va,Ii,gd,Be,Ca=x(()=>{"use strict";ne();ue();B();Me();Ni=(s,t,e,r)=>{let n=new v(s,e,r);return n.type=`converter-rule-${t}`,n.setAttribute("stage",11),n};va=[j];Be=class extends(gd=v){get type(){return"converter-rule"}get variant(){}constructor(t,e=!0,r=W.getConfig(),n=[]){super(void 0,r,n,{});let i=t.indexOf(":"),o=t.slice(0,i).indexOf("=>"),a=o===-1?t.slice(0,i):t.slice(o+2,i);e&&r.variants.includes(a.trim().toLowerCase())?(super.insertAt(new H(a,"converter-rule-variant",r,n)),super.insertAt(Ni(t.slice(i+1),"to",r,n)),o!==-1&&super.insertAt(Ni(t.slice(0,o),"from",r,n),0)):super.insertAt(Ni(t,"to",r,n))}toString(t){let{childNodes:e,firstChild:r,lastChild:n}=this;return e.length===3?`${r.toString(t)}=>${e[1].toString(t)}:${n.toString(t)}`:super.toString(t,":")}text(){let{childNodes:t,firstChild:e,lastChild:r}=this;return t.length===3?`${e.text()}=>${t[1].text()}:${r.text()}`:super.text(":")}getGaps(t){return t===0&&this.length===3?2:1}print(){{let{childNodes:t}=this;if(t.length===3){let[e,r,n]=t;return`<span class="wpb-converter-rule">${e.print()}=>${r.print()}:${n.print()}</span>`}return super.print({sep:":"})}}json(t,e,r=this.getAbsoluteIndex()){}};Ii=I(gd),Be=N(Ii,0,"ConverterRuleToken",va,Be),E(Ii,1,Be)});var Aa,$i,ud,Tt,Sa=x(()=>{"use strict";J();Te();ne();B();ka();Ca();Aa=[j,Y("-{")];Tt=class extends(ud=v){get type(){return"converter"}constructor(t,e,r,n=[]){super(void 0,r,n),this.insertAt(new bt(t,r,n));let[i]=e,o=i.includes(":"),a=new Be(i,o,r,n);(o?a.length===1:e.length===2&&!z(e[1]).trim())?this.insertAt(new Be(e.join(";"),!1,r,n)):this.safeAppend([a,...e.slice(1).map(l=>new Be(l,!0,r,n))])}toString(t){let[e,...r]=this.childNodes;return`-{${e.toString(t)}${e.length>0?"|":""}${r.map(n=>n.toString(t)).join(";")}}-`}text(){let[t,...e]=this.childNodes;return`-{${t.text()}|${ge(e,";")}}-`}getGaps(t){return t||this.firstChild.length>0?1:0}print(){{let[t,...e]=this.childNodes;return`<span class="wpb-converter">-{${t.print()}${t.length>0?"|":""}${Ce(e,{sep:";"})}}-</span>`}}};$i=I(ud),Tt=N($i,0,"ConverterToken",Aa,Tt),E($i,1,Tt)});var wa={};M(wa,{parseConverter:()=>pd});var pd,Ea=x(()=>{"use strict";Sa();pd=(s,t,e)=>{var l;(l=t.regexConverter)!=null||(t.regexConverter=new RegExp(String.raw`;(?=(?:[^;]*?=>)?\s*(?:${t.variants.join("|")})\s*:|(?:\s|\0\d+[cn]\x7F)*$)`,"iu"));let r=/-\{/gu,n=/-\{|\}-/gu,i=[],o=r,a=o.exec(s);for(;a;){let{0:p,index:u}=a;if(p==="}-"){let d=i.pop(),{length:c}=e,f=s.slice(d.index+2,u),m=f.indexOf("|"),[C,A]=m===-1?[[],f]:[f.slice(0,m).split(";"),f.slice(m+1)],S=A.replace(/(&[#a-z\d]+);/giu,"$1"),k=S.split(t.regexConverter).map(y=>y.replace(/\x01/gu,";"));new Tt(C,k,t,e),s=`${s.slice(0,d.index)}\0${c}v${s.slice(u+2)}`,i.length===0&&(o=r),o.lastIndex=d.index+3+String(c).length}else i.push(a),o=n,o.lastIndex=u+2;a=o.exec(s)}return s}});var fn={};M(fn,{Token:()=>v});var Ir,de,U,D,Xt,Kt,$r,Jt,q,Na,Ia,$a,La,Fa,Ra,Ba,Pa,ja,Oa,qa,_a,Li,v,B=x(()=>{"use strict";J();ir();Ae();ue();es();rs();Li=class Li extends et{constructor(e,r=W.getConfig(),n=[],i){super();h(this,q);h(this,Ir,"plain");h(this,de,0);h(this,U);h(this,D);h(this,Xt);h(this,Kt,!1);h(this,$r);h(this,Jt);typeof e=="string"&&this.insertAt(e),b(this,U,r),b(this,D,n),n.push(this)}get type(){return g(this,Ir)}set type(e){b(this,Ir,e)}get pageName(){return g(this.getRootNode(),Jt)}set pageName(e){if(e){let r=this.normalizeTitle(e,0,{temporary:!0,page:""});b(this,Jt,r.valid?r.title:void 0)}else b(this,Jt,e===""?"":void 0)}parseOnce(e=g(this,de),r=!1,n){if(e<g(this,de)||this.length!==1||!this.isPlain())return this;if(g(this,de)>=11)return this;switch(e){case 0:if(this.type==="root"){g(this,D).pop();let i=$(this,q,Na).call(this);r&&(r=!i)}b(this,Xt,r),$(this,q,Ia).call(this,r);break;case 1:$(this,q,$a).call(this);break;case 2:$(this,q,La).call(this);break;case 3:$(this,q,Fa).call(this);break;case 4:$(this,q,Ra).call(this);break;case 5:$(this,q,Ba).call(this,n);break;case 6:$(this,q,Pa).call(this,n);break;case 7:$(this,q,ja).call(this);break;case 8:$(this,q,Oa).call(this);break;case 9:$(this,q,qa).call(this);break;case 10:$(this,q,_a).call(this)}if(this.type==="root")for(let i of g(this,D))i==null||i.parseOnce(e,r,n);return Or(this,de)._++,this}buildFromStr(e,r){let n=e.split(/[\0\x7F]/u).map((i,o)=>{if(o%2===0)return i&&new lr(i);let a=Number(i.slice(0,-1));return g(this,D)[a]}).filter(i=>i!=="");return r===0?n.map(String).join(""):r===1?ge(n):n}build(){b(this,de,11);let{length:e,firstChild:r}=this,n=r==null?void 0:r.toString();if(e===1&&r.type==="text"&&n.includes("\0")&&(Mr(this,0,1,this.buildFromStr(n)),this.type==="root"))for(let i of g(this,D))i==null||i.build()}afterBuild(){if(this.type==="root")for(let e of g(this,D))e==null||e.afterBuild();b(this,Kt,!0)}parse(e=11,r,n){for(e=Math.min(e,11);g(this,de)<e;)this.parseOnce(g(this,de),r,n);return e&&(this.build(),this.afterBuild()),this}isPlain(){return this.constructor===Li}getAttribute(e){var r;switch(e){case"config":return g(this,U);case"include":return(r=g(this,Xt))!=null?r:!!g(this.getRootNode(),Xt);case"accum":return g(this,D);case"built":return g(this,Kt);case"stage":return g(this,de);case"invalid":return this.type==="table-inter"&&_r(this)===2;default:return super.getAttribute(e)}}setAttribute(e,r){e==="stage"?(g(this,de)===0&&this.type==="root"&&g(this,D).shift(),b(this,de,r)):super.setAttribute(e,r)}insertAt(e,r=this.length){let n=typeof e=="string"?new lr(e):e,{length:i}=this;r+=r<0?i:0,super.insertAt(n,r);let{type:o}=n;return o==="root"&&(n.type="plain"),n}normalizeTitle(e,r=0,n){return W.normalizeTitle(e,r,this.getAttribute("include"),g(this,U),{page:this.pageName,...n})}inTableAttrs(){var e;return this.isInside("table-attrs")&&((e=this.closest("table-attrs,arg,parameter"))!=null&&e.is("table-attrs")?2:1)}inHtmlAttrs(){return this.isInside("html-attrs")?2:this.inTableAttrs()}lint(e=this.getAbsoluteIndex(),r){}toString(e,r){return e?super.toString(!0,r):Oe(g(this,$r),()=>super.toString(!1,r),n=>{let i=this.getRootNode();i.type==="root"&&g(i,Kt)&&b(this,$r,n)})}};Ir=new WeakMap,de=new WeakMap,U=new WeakMap,D=new WeakMap,Xt=new WeakMap,Kt=new WeakMap,$r=new WeakMap,Jt=new WeakMap,q=new WeakSet,Na=function(){let{parseRedirect:e}=(us(),O(gs)),r=this.firstChild.toString(),n=e(r,g(this,U),g(this,D));return n!==!1&&this.setText(n),!!n},Ia=function(e){let{parseCommentAndExt:r}=(hr(),O(Bo));this.setText(r(this.firstChild.toString(),g(this,U),g(this,D),e))},$a=function(){let{parseBraces:e}=(Yr(),O(eo)),r=this.type==="root"?this.firstChild.toString():`\0${this.firstChild.toString()}`,n=e(r,g(this,U),g(this,D));this.setText(this.type==="root"?n:n.slice(1))},La=function(){if(g(this,U).excludes.includes("html"))return;let{parseHtml:e}=(qo(),O(Oo));this.setText(e(this.firstChild.toString(),g(this,U),g(this,D)))},Fa=function(){if(g(this,U).excludes.includes("table"))return;let{parseTable:e}=(Xo(),O(Qo));this.setText(e(this,g(this,U),g(this,D)))},Ra=function(){if(g(this,U).excludes.includes("hr"))return;let{parseHrAndDoubleUnderscore:e}=(ta(),O(ea));this.setText(e(this,g(this,U),g(this,D)))},Ba=function(e){let{parseLinks:r}=(la(),O(aa));this.setText(r(this.firstChild.toString(),g(this,U),g(this,D),this.pageName,e))},Pa=function(e){let{parseQuotes:r}=(Ai(),O(na)),n=this.firstChild.toString().split(`
|
|
19
|
+
${u}`,l),i.push(l);continue}let[,A,C,S,k]=m;if(A){for(;!l.is("table");)l=i.pop();l.close(`
|
|
20
|
+
${d}${A}`,!0),p(k,i[i.length-1])}else if(C){l=Ko(l,i),l.is("tr")&&(l=i.pop());let y=new ln(`
|
|
21
|
+
${d}${C}`,k,r,n);i.push(l,y),l.insertAt(y)}else{l=Ko(l,i);let y=S==="!"?/!!|(?:\||\0\d+!\x7F){2}|\0\d+\+\x7F/gu:/(?:\||\0\d+!\x7F){2}|\0\d+\+\x7F/gu,T=y.exec(k),w=0,F=`
|
|
22
|
+
${d}${S}`,L=R=>{let G=new Er(F,k.slice(w,T==null?void 0:T.index),r,n);return R.insertAt(G),G};for(;T;)L(l),{lastIndex:w}=y,[F]=T,T=y.exec(k);i.push(l,L(l))}}return a.slice(1)}});var Nr,Jo=x(()=>{"use strict";Nr=s=>!/^_{2}.+_{2}$/u.test(s)});var dn,Yo=x(()=>{"use strict";Ue();dn=class extends K{get type(){return"hr"}}});var Zo,Kt,vi,id,xt,ea=x(()=>{"use strict";_e();Te();Ue();Zo=[oe(!0,!1),Y("__")];xt=class extends(id=K){constructor(e,r,n,i,o){var u,d;super(e,i,o);h(this,Kt);let a=e.toLowerCase(),[,,l,p]=i.doubleUnderscore;this.setAttribute("name",(d=r?(u=p[e])==null?void 0:u.toLowerCase():l[a])!=null?d:a),b(this,Kt,n)}get type(){return"double-underscore"}toString(){let e=g(this,Kt)?"__":"__";return e+this.innerText+e}print(){{let e=g(this,Kt)?"__":"__";return super.print({pre:e,post:e})}}};vi=I(id),Kt=new WeakMap,xt=N(vi,0,"DoubleUnderscoreToken",Zo,xt),E(vi,1,xt)});var ta={};W(ta,{parseHrAndDoubleUnderscore:()=>sd});var sd,ra=x(()=>{"use strict";Jo();Yo();ea();jn();sd=({firstChild:{data:s},type:t,name:e},r,n)=>{var p,u,d;let[i,o,a]=r.doubleUnderscore,l=[...i,...o];return(p=r.insensitiveDoubleUnderscore)!=null||(r.insensitiveDoubleUnderscore=new Set(i.filter(Nr))),(u=r.sensitiveDoubleUnderscore)!=null||(r.sensitiveDoubleUnderscore=new Set(o.filter(Nr))),(d=r.regexHrAndDoubleUnderscore)!=null||(r.regexHrAndDoubleUnderscore=new RegExp(String.raw`^((?:\0\d+[cno]\x7F)*)(-{4,})|__(${l.filter(Nr).join("|")})__|_{2}(${l.filter(c=>!Nr(c)).map(c=>c.slice(2,-2)).join("|")})_{2}`,"gimu")),t!=="root"&&(t!=="ext-inner"||e!=="poem")&&(s=`\0${s}`),s=s.replace(r.regexHrAndDoubleUnderscore,(c,f,m,A,C)=>{var w;if(m)return new dn(m,r,n),`${f}\0${n.length-1}r`;let S=A!=null?A:C,k=r.sensitiveDoubleUnderscore.has(S),y=S.toLowerCase(),T=r.insensitiveDoubleUnderscore.has(y);return k||T?(new xt(S,k,!!C,r,n),`\0${n.length-1}${T&&((w=a[y])!=null?w:y)==="toc"?"u":"n"}`):c}),r.excludes.includes("heading")||(s=s.replace(/^((?:\0\d+[cn]\x7F)*)(={1,6})(.+)\2((?:\s|\0\d+[cn]\x7F)*)$/gmu,(c,f,m,A,C)=>{let S=`${f}\0${n.length}h`;return new we(m.length,[A,C],r,n),S})),t==="root"||t==="ext-inner"&&e==="poem"?s:s.slice(1)}});var un,gn,na=x(()=>{"use strict";Ue();gn=class extends K{constructor(e,r,n,i){super(e,n,i);h(this,un);b(this,un,r)}get type(){return"quote"}get bold(){return this.innerText.length!==2}get italic(){return this.innerText.length!==3}get closing(){}text(){let{parentNode:e,innerText:r}=this;return e!=null&&e.is("image-parameter")&&e.name!=="caption"?"":r}lint(e=this.getAbsoluteIndex()){}json(e,r,n=this.getAbsoluteIndex()){}};un=new WeakMap});var ia={};W(ia,{parseQuotes:()=>Ai});var Ai,Ci=x(()=>{"use strict";na();Ai=(s,t,e,r)=>{var f;let n=s.split(/('{2,})/u),{length:i}=n;if(i===1)return s;let o=0,a=0,l,p,u;for(let m=1;m<i;m+=2){let A=n[m].length;switch(A){case 2:a++;break;case 4:n[m-1]+="'",n[m]="'''";case 3:if(o++,l!==void 0)break;n[m-1].endsWith(" ")?p===void 0&&u===void 0&&(u=m):n[m-1].slice(-2,-1)===" "?l=m:p!=null||(p=m);break;default:n[m-1]+="'".repeat(A-5),n[m]="'''''",a++,o++}}if(a%2===1&&o%2===1){let m=(f=l!=null?l:p)!=null?f:u;m!==void 0&&(n[m]="''",n[m-1]+="'")}let d=!1,c=!1;for(let m=1;m<i;m+=2){let A=n[m].length,C=A!==2,S=A!==3,k=new gn(n[m],{bold:C&&!!d,italic:S&&!!c},t,e);C&&(d=!d&&k),S&&(c=!c&&k),n[m]=`\0${e.length-1}q`}return n.join("")}});var sa={};W(sa,{parseExternalLinks:()=>Si});var Si,wi=x(()=>{"use strict";J();ti();sn();Si=(s,t,e,r)=>{var n;return(n=t.regexExternalLinks)!=null||(t.regexExternalLinks=new RegExp(String.raw`\[((?:\0\d+[cn]\x7F)*(?:\0\d+f\x7F|(?:(?:${t.protocol}|//)${Je}|\0\d+m\x7F)${Ye}(?=[[\]<>"\t${be}]|\0\d)))([${be}]*(?![${be}]))([^\]\x01-\x08\x0A-\x1F\uFFFD]*)\]`,"giu")),s.replace(t.regexExternalLinks,(i,o,a,l)=>{let{length:p}=e,u=/&[lg]t;/u.exec(o);return u&&(a="",l=o.slice(u.index)+a+l,o=o.slice(0,u.index)),r?(new Ie(o,"ext-link-url",t,e),`[\0${p}f${a}${l}]`):(new Le(o,a,l,t,e),`\0${p}w`)})}});var pn,oa=x(()=>{"use strict";$t();pn=class extends ie{get type(){return"category"}get sortkey(){}json(t,e,r=this.getAbsoluteIndex()){}}});var la={};W(la,{parseLinks:()=>aa});var od,aa,da=x(()=>{"use strict";J();ue();Ci();wi();Zn();Kn();oa();od=/^((?:(?!\0\d+!\x7F)[^\n[\]{}|])+)(\||\0\d+!\x7F)([\s\S]*)$/u,aa=(s,t,e,r,n)=>{var l;(l=t.regexLinks)!=null||(t.regexLinks=new RegExp(String.raw`^\s*(?:${t.protocol}|//)`,"iu"));let i=t.inExt?/^((?:(?!\0\d+!\x7F)[^\n[\]{}|])+)(?:(\||\0\d+!\x7F)([\s\S]*?[^\]]))?\]\]([\s\S]*)$/u:/^((?:(?!\0\d+!\x7F)[^\n[\]{}|])*)(?:(\||\0\d+!\x7F)([\s\S]*?[^\]])?)?\]\]([\s\S]*)$/u,o=s.split("[["),a=o.shift();for(let p=0;p<o.length;p++){let u=!1,d,c,f,m,A=o[p],C=i.exec(A);if(C)[,d,c,f,m]=C,m.startsWith("]")&&(f!=null&&f.includes("["))&&(f+="]",m=m.slice(1));else{let F=od.exec(A);F&&(u=!0,[,d,c,f]=F)}if(d===void 0||t.regexLinks.test(d)||/\0\d+[exhbru]\x7F/u.test(d)){a+=`[[${A}`;continue}let S=z(d).trim(),k=S.startsWith(":");if(k&&u){a+=`[[${A}`;continue}else!S&&f&&!f.includes(`
|
|
23
|
+
`)&&(S=z(f).trim());let{ns:y,valid:T}=M.normalizeTitle(S,0,!1,t,{halfParsed:!0,temporary:!0,decode:!0,selfLink:!0,page:r});if(T){if(u){if(y!==6){a+=`[[${A}`;continue}let F=!1;for(p++;p<o.length;p++){let L=o[p],R=L.split("]]");if(R.length>2){F=!0,f+=`[[${R[0]}]]${R[1]}`,m=R.slice(2).join("]]");break}else if(R.length===2)f+=`[[${R[0]}]]${R[1]}`;else{f+=`[[${L}`;break}}if(f=aa(f,t,e,r,n),!F){a+=`[[${d}${c}${f}`;continue}}}else{a+=`[[${A}`;continue}f&&(f=Ai(f,t,e,n));let w=Mt;k||(y===6?(f&&(f=Si(f,t,e,!0)),w=_t):y===14&&(w=pn)),f===void 0&&c&&(f=""),a+=`\0${e.length}l${m}`,new w(d,f,t,e,c)}return a}});var fa={};W(fa,{parseMagicLinks:()=>ad});var ca,ga,ua,pa,ad,ma=x(()=>{"use strict";J();sn();ca=String.raw`[${be}\t]| |�*160;|�*a0;`,ga=`(?:${ca})+`,ua=`(?:${ca}|-)`,pa=String.raw`(?:RFC|PMID)${ga}\d+\b|ISBN${ga}(?:97[89]${ua}?)?(?:\d${ua}?){9}[\dx]\b`,ad=(s,t,e)=>{if(!t.regexMagicLinks)try{t.regexMagicLinks=new RegExp(String.raw`(^|[^\p{L}\p{N}_])(?:(?:${t.protocol})(${Je}${Ye})|${pa})`,"giu")}catch{t.regexMagicLinks=new RegExp(String.raw`(^|\W)(?:(?:${t.protocol})(${Je}${Ye})|${pa})`,"giu")}return s.replace(t.regexMagicLinks,(r,n,i)=>{let o=n?r.slice(n.length):r;if(i){let a="",l=/&(?:[lg]t|nbsp|#x0*(?:3[ce]|a0)|#0*(?:6[02]|160));/iu.exec(o);l&&(a=o.slice(l.index),o=o.slice(0,l.index));let p=o.includes("(")?/[^,;\\.:!?][,;\\.:!?]+$/u:/[^,;\\.:!?)][,;\\.:!?)]+$/u,u=p.exec(o);if(u){let d=1;u[0][1]===";"&&/&(?:[a-z]+|#x[\da-f]+|#\d+)$/iu.test(o.slice(0,u.index))&&(d=2),a=o.slice(u.index+d)+a,o=o.slice(0,u.index+d)}return a.length>=i.length?r:(new Ie(o,void 0,t,e),`${n}\0${e.length-1}w${a}`)}else if(!/^(?:RFC|PMID|ISBN)/u.test(o))return r;return new Ie(o,"magic-link",t,e),`${n}\0${e.length-1}i`})}});var ha,xa=x(()=>{"use strict";ha=(s,t)=>s.startsWith(t)?t.length:[...t].findIndex((e,r)=>e!==s[r])});var cn,ba=x(()=>{"use strict";Ti();cn=class extends Vt{get type(){return"list"}lint(t=this.getAbsoluteIndex()){}}});var ya={};W(ya,{parseList:()=>ld});var ld,Ta=x(()=>{"use strict";xa();ba();ki();ld=(s,t,e,r)=>{let n=/^((?:\0\d+[cno]\x7F)*)([;:*#]+)(\s*)/u.exec(s);if(!n)return t.lastPrefix="",s;let[i,o,a,l]=n,p=a.replace(/;/gu,":"),u=ha(p,t.lastPrefix),d=((u>1?a.slice(u-1):a)+l).split(/(?=;)/u),c=d[0].startsWith(";"),f=d.length-(c?0:1);if(u>1){let P=a.slice(0,u-1);if(c){let V=P.split(/(?=;)/u);d.unshift(...V),f+=P.includes(";")?V.length:0}else d[0]=P+d[0]}t.lastPrefix=p;let m=o+d.map((P,V)=>`\0${r.length+V}d`).join("")+s.slice(i.length);for(let P of d)new cn(P,e,r);if(!f)return m;let[A,,C]=e.html,S=/:+|-\{|\0\d+[xq]\x7F/gu,k=S,y=k.exec(m),T=0,w=!1,F=!1,L=0,R=(P,V)=>(new Ht(P,e,r),`${m.slice(0,V)}\0${r.length-1}d${m.slice(V+P.length)}`),G=P=>{P?T&&T--:T++};for(;y&&f;){let{0:P,index:V}=y;if(P==="-{"){if(!L){let{lastIndex:_}=k;k=/-\{|\}-/gu,k.lastIndex=_}L++}else if(P==="}-"){if(L--,!L){let{lastIndex:_}=k;k=S,k.lastIndex=_}}else if(P.endsWith("x")){let{name:_,closing:X,selfClosing:ae}=r[Number(P.slice(1,-2))];(A.includes(_)||!ae&&!C.includes(_))&&G(X)}else if(P.endsWith("q")){let{bold:_,italic:X}=r[Number(P.slice(1,-2))];_&&(G(w),w=!w),X&&(G(F),F=!F)}else if(T===0){if(P.length>=f)return R(P.slice(0,f),V);f-=P.length,k.lastIndex=V+4+String(r.length).length,m=R(P,V)}y=k.exec(m)}return m}});var dd,ka,yt,Ei,gd,bt,va=x(()=>{"use strict";gr();ne();B();We();dd=new Set(["A","T","R","D","-","H","N"]);ka=[De(),j];bt=class extends(gd=v){constructor(e,r,n=[]){super(void 0,r,n,{});h(this,yt);this.safeAppend(e.map(i=>new H(i,"converter-flag",r,n)))}get type(){return"converter-flags"}afterBuild(){b(this,yt,this.childNodes.map(e=>e.text().trim())),super.afterBuild()}toString(e){return super.toString(e,";")}text(){return super.text(";")}getUnknownFlags(){return new Set(g(this,yt).filter(e=>/\{{3}[^{}]+\}{3}/u.test(e)))}getVariantFlags(){let e=new Set(this.getAttribute("config").variants);return new Set(g(this,yt).filter(r=>e.has(r)))}isInvalidFlag(e,r,n){if(typeof e=="object"){let i=new Set(this.getAttribute("config").variants);e=e.text().trim(),r=g(this,yt).some(o=>i.has(o))?i:new Set,n=this.getUnknownFlags()}return!!e&&!r.has(e)&&!n.has(e)&&(r.size>0||!dd.has(e))}lint(e=this.getAbsoluteIndex(),r){}print(){return super.print({sep:";"})}};Ei=I(gd),yt=new WeakMap,bt=N(Ei,0,"ConverterFlagsToken",ka,bt),E(Ei,1,bt)});var Ni,Aa,Ii,ud,Be,Ca=x(()=>{"use strict";ne();ue();B();We();Ni=(s,t,e,r)=>{let n=new v(s,e,r);return n.type=`converter-rule-${t}`,n.setAttribute("stage",11),n};Aa=[j];Be=class extends(ud=v){get type(){return"converter-rule"}get variant(){}constructor(t,e=!0,r=M.getConfig(),n=[]){super(void 0,r,n,{});let i=t.indexOf(":"),o=t.slice(0,i).indexOf("=>"),a=o===-1?t.slice(0,i):t.slice(o+2,i);e&&r.variants.includes(a.trim().toLowerCase())?(super.insertAt(new H(a,"converter-rule-variant",r,n)),super.insertAt(Ni(t.slice(i+1),"to",r,n)),o!==-1&&super.insertAt(Ni(t.slice(0,o),"from",r,n),0)):super.insertAt(Ni(t,"to",r,n))}toString(t){let{childNodes:e,firstChild:r,lastChild:n}=this;return e.length===3?`${r.toString(t)}=>${e[1].toString(t)}:${n.toString(t)}`:super.toString(t,":")}text(){let{childNodes:t,firstChild:e,lastChild:r}=this;return t.length===3?`${e.text()}=>${t[1].text()}:${r.text()}`:super.text(":")}getGaps(t){return t===0&&this.length===3?2:1}print(){{let{childNodes:t}=this;if(t.length===3){let[e,r,n]=t;return`<span class="wpb-converter-rule">${e.print()}=>${r.print()}:${n.print()}</span>`}return super.print({sep:":"})}}json(t,e,r=this.getAbsoluteIndex()){}};Ii=I(ud),Be=N(Ii,0,"ConverterRuleToken",Aa,Be),E(Ii,1,Be)});var Sa,$i,pd,Tt,wa=x(()=>{"use strict";J();Te();ne();B();va();Ca();Sa=[j,Y("-{")];Tt=class extends(pd=v){get type(){return"converter"}constructor(t,e,r,n=[]){super(void 0,r,n),this.insertAt(new bt(t,r,n));let[i]=e,o=i.includes(":"),a=new Be(i,o,r,n);(o?a.length===1:e.length===2&&!z(e[1]).trim())?this.insertAt(new Be(e.join(";"),!1,r,n)):this.safeAppend([a,...e.slice(1).map(l=>new Be(l,!0,r,n))])}toString(t){let[e,...r]=this.childNodes;return`-{${e.toString(t)}${e.length>0?"|":""}${r.map(n=>n.toString(t)).join(";")}}-`}text(){let[t,...e]=this.childNodes;return`-{${t.text()}|${ge(e,";")}}-`}getGaps(t){return t||this.firstChild.length>0?1:0}print(){{let[t,...e]=this.childNodes;return`<span class="wpb-converter">-{${t.print()}${t.length>0?"|":""}${Ae(e,{sep:";"})}}-</span>`}}};$i=I(pd),Tt=N($i,0,"ConverterToken",Sa,Tt),E($i,1,Tt)});var Ea={};W(Ea,{parseConverter:()=>cd});var cd,Na=x(()=>{"use strict";wa();cd=(s,t,e)=>{var l;(l=t.regexConverter)!=null||(t.regexConverter=new RegExp(String.raw`;(?=(?:[^;]*?=>)?\s*(?:${t.variants.join("|")})\s*:|(?:\s|\0\d+[cn]\x7F)*$)`,"iu"));let r=/-\{/gu,n=/-\{|\}-/gu,i=[],o=r,a=o.exec(s);for(;a;){let{0:p,index:u}=a;if(p==="}-"){let d=i.pop(),{length:c}=e,f=s.slice(d.index+2,u),m=f.indexOf("|"),[A,C]=m===-1?[[],f]:[f.slice(0,m).split(";"),f.slice(m+1)],S=C.replace(/(&[#a-z\d]+);/giu,"$1"),k=S.split(t.regexConverter).map(y=>y.replace(/\x01/gu,";"));new Tt(A,k,t,e),s=`${s.slice(0,d.index)}\0${c}v${s.slice(u+2)}`,i.length===0&&(o=r),o.lastIndex=d.index+3+String(c).length}else i.push(a),o=n,o.lastIndex=u+2;a=o.exec(s)}return s}});var fn={};W(fn,{Token:()=>v});var Ir,de,U,D,Qt,Xt,$r,Jt,O,Ia,$a,La,Fa,Ra,Ba,Pa,ja,qa,Oa,_a,Ma,Li,v,B=x(()=>{"use strict";J();ir();Ce();ue();ts();ns();Li=class Li extends et{constructor(e,r=M.getConfig(),n=[],i){super();h(this,O);h(this,Ir,"plain");h(this,de,0);h(this,U);h(this,D);h(this,Qt);h(this,Xt,!1);h(this,$r);h(this,Jt);typeof e=="string"&&this.insertAt(e),b(this,U,r),b(this,D,n),n.push(this)}get type(){return g(this,Ir)}set type(e){b(this,Ir,e)}get pageName(){return g(this.getRootNode(),Jt)}set pageName(e){if(e){let r=this.normalizeTitle(e,0,{temporary:!0,page:""});b(this,Jt,r.valid?r.title:void 0)}else b(this,Jt,e===""?"":void 0)}parseOnce(e=g(this,de),r=!1,n){if(e<g(this,de)||this.length!==1||!this.isPlain())return this;if(g(this,de)>=11)return this;switch(e){case 0:if(this.type==="root"){g(this,D).pop();let i=$(this,O,Ia).call(this);r&&(r=!i)}b(this,Qt,r),$(this,O,$a).call(this,r);break;case 1:$(this,O,La).call(this);break;case 2:$(this,O,Fa).call(this);break;case 3:$(this,O,Ra).call(this);break;case 4:$(this,O,Ba).call(this);break;case 5:$(this,O,Pa).call(this,n);break;case 6:$(this,O,ja).call(this,n);break;case 7:$(this,O,qa).call(this);break;case 8:$(this,O,Oa).call(this);break;case 9:$(this,O,_a).call(this);break;case 10:$(this,O,Ma).call(this)}if(this.type==="root")for(let i of g(this,D))i==null||i.parseOnce(e,r,n);return qr(this,de)._++,this}buildFromStr(e,r){let n=e.split(/[\0\x7F]/u).map((i,o)=>{if(o%2===0)return i&&new lr(i);let a=Number(i.slice(0,-1));return g(this,D)[a]}).filter(i=>i!=="");return r===0?n.map(String).join(""):r===1?ge(n):n}build(){b(this,de,11);let{length:e,firstChild:r}=this,n=r==null?void 0:r.toString();if(e===1&&r.type==="text"&&n.includes("\0")&&(Wr(this,0,1,this.buildFromStr(n)),this.type==="root"))for(let i of g(this,D))i==null||i.build()}afterBuild(){if(this.type==="root")for(let e of g(this,D))e==null||e.afterBuild();b(this,Xt,!0)}parse(e=11,r,n){for(e=Math.min(e,11);g(this,de)<e;)this.parseOnce(g(this,de),r,n);return e&&(this.build(),this.afterBuild()),this}isPlain(){return this.constructor===Li}getAttribute(e){var r;switch(e){case"config":return g(this,U);case"include":return(r=g(this,Qt))!=null?r:!!g(this.getRootNode(),Qt);case"accum":return g(this,D);case"built":return g(this,Xt);case"stage":return g(this,de);case"invalid":return this.type==="table-inter"&&_r(this)===2;default:return super.getAttribute(e)}}setAttribute(e,r){e==="stage"?(g(this,de)===0&&this.type==="root"&&g(this,D).shift(),b(this,de,r)):super.setAttribute(e,r)}insertAt(e,r=this.length){let n=typeof e=="string"?new lr(e):e,{length:i}=this;r+=r<0?i:0,super.insertAt(n,r);let{type:o}=n;return o==="root"&&(n.type="plain"),n}normalizeTitle(e,r=0,n){return M.normalizeTitle(e,r,this.getAttribute("include"),g(this,U),{page:this.pageName,...n})}inTableAttrs(){var e;return this.isInside("table-attrs")&&((e=this.closest("table-attrs,arg,parameter"))!=null&&e.is("table-attrs")?2:1)}inHtmlAttrs(){return this.isInside("html-attrs")?2:this.inTableAttrs()}lint(e=this.getAbsoluteIndex(),r){}toString(e,r){return e?super.toString(!0,r):qe(g(this,$r),()=>super.toString(!1,r),n=>{let i=this.getRootNode();i.type==="root"&&g(i,Xt)&&b(this,$r,n)})}};Ir=new WeakMap,de=new WeakMap,U=new WeakMap,D=new WeakMap,Qt=new WeakMap,Xt=new WeakMap,$r=new WeakMap,Jt=new WeakMap,O=new WeakSet,Ia=function(){let{parseRedirect:e}=(ps(),q(us)),r=this.firstChild.toString(),n=e(r,g(this,U),g(this,D));return n!==!1&&this.setText(n),!!n},$a=function(e){let{parseCommentAndExt:r}=(hr(),q(Po));this.setText(r(this.firstChild.toString(),g(this,U),g(this,D),e))},La=function(){let{parseBraces:e}=(Yr(),q(to)),r=this.type==="root"?this.firstChild.toString():`\0${this.firstChild.toString()}`,n=e(r,g(this,U),g(this,D));this.setText(this.type==="root"?n:n.slice(1))},Fa=function(){if(g(this,U).excludes.includes("html"))return;let{parseHtml:e}=(_o(),q(Oo));this.setText(e(this.firstChild.toString(),g(this,U),g(this,D)))},Ra=function(){if(g(this,U).excludes.includes("table"))return;let{parseTable:e}=(Xo(),q(Qo));this.setText(e(this,g(this,U),g(this,D)))},Ba=function(){if(g(this,U).excludes.includes("hr"))return;let{parseHrAndDoubleUnderscore:e}=(ra(),q(ta));this.setText(e(this,g(this,U),g(this,D)))},Pa=function(e){let{parseLinks:r}=(da(),q(la));this.setText(r(this.firstChild.toString(),g(this,U),g(this,D),this.pageName,e))},ja=function(e){let{parseQuotes:r}=(Ci(),q(ia)),n=this.firstChild.toString().split(`
|
|
24
24
|
`);for(let i=0;i<n.length;i++)n[i]=r(n[i],g(this,U),g(this,D),e);this.setText(n.join(`
|
|
25
|
-
`))},
|
|
25
|
+
`))},qa=function(){let{parseExternalLinks:e}=(wi(),q(sa));this.setText(e(this.firstChild.toString(),g(this,U),g(this,D)))},Oa=function(){let{parseMagicLinks:e}=(ma(),q(fa));this.setText(e(this.firstChild.toString(),g(this,U),g(this,D)))},_a=function(){if(g(this,U).excludes.includes("list"))return;let{parseList:e}=(Ta(),q(ya)),{firstChild:r,type:n,name:i}=this,o=r.toString().split(`
|
|
26
26
|
`),a={lastPrefix:""},l=n==="root"||n==="ext-inner"&&i==="poem"?0:1;for(;l<o.length;l++)o[l]=e(o[l],a,g(this,U),g(this,D));this.setText(o.join(`
|
|
27
|
-
`))},
|
|
27
|
+
`))},Ma=function(){if(g(this,U).variants.length>0){let{parseConverter:e}=(Na(),q(Ea));this.setText(e(this.firstChild.toString(),g(this,U),g(this,D)))}};v=Li});function xo(s){return t=>t.type===s}var ee,Wr,zs,Ce=x(()=>{"use strict";ee={running:!1,run(s,t){let{running:e}=this;this.running=!0;let r=t==null?void 0:t.internal;t&&(t.internal=!0);let n=()=>{this.running=e,t&&(t.internal=r)};try{let{Token:i}=(B(),q(fn)),o=s();return o instanceof i&&!o.getAttribute("built")&&o.afterBuild(),n(),o}catch(i){throw n(),i}},internal(s,t){let{internal:e}=t;t.internal=!0;let r=s();return t.internal=e,r},rev:0};Wr=(s,t,e,r=[])=>{var o,a;let n=s.getChildNodes(),i;n.length===e?(i=n,n=r):i=Array.prototype.splice.apply(n,[t,e,...r]);for(let l=0;l<r.length;l++){let p=r[l];p.setAttribute("parentNode",s),p.setAttribute("nextSibling",n[t+l+1]),p.setAttribute("previousSibling",n[t+l-1])}return(o=n[t-1])==null||o.setAttribute("nextSibling",n[t]),(a=n[t+r.length])==null||a.setAttribute("previousSibling",n[t+r.length-1]),n===r&&s.setAttribute("childNodes",n),i},zs=(s,t)=>{let e=s.toLowerCase(),[r,n]=t,i=Object.prototype.hasOwnProperty.call(n,s);return[e,i,i?n[s]:Object.prototype.hasOwnProperty.call(r,e)&&r[e]]}});var Wa,Fr,Rr,kt,Yt,vt,mn,Ua,Lr,Da=x(()=>{"use strict";nr();J();Wa=s=>{let[,{length:t},e]=/^((?:\.\.\/)*)([\s\S]*)/u.exec(s);return[t/3,e]},Lr=class{constructor(t,e,r,{temporary:n,decode:i,selfLink:o,page:a}={}){h(this,mn);h(this,Fr);h(this,Rr);h(this,kt);h(this,Yt);h(this,vt);Z(this,"page");Z(this,"valid");Z(this,"encoded",!1);this.page=a;let l=t.trim(),p=l.startsWith("../");if(i&&t.includes("%"))try{let f=/%(?!21|3[ce]|5[bd]|7[b-d])[\da-f]{2}/iu.test(t);t=kn(t),this.encoded=f}catch{}if(t=bn(t).replace(/[_ ]+/gu," ").trim(),p||a&&l.startsWith("/"))b(this,Yt,0);else{let f=e;t.startsWith(":")&&(f=0,t=t.slice(1).trim());let m=t.split(":");if(m.length>1){let A=ve(m[0]),C=Object.prototype.hasOwnProperty.call(r.nsid,A)&&r.nsid[A];C&&(f=C,t=m.slice(1).join(":").trim())}b(this,Yt,f)}let u=t.indexOf("#");if(u!==-1){let f=t.slice(u).trim().slice(1);if(f.includes("%"))try{f=kn(f)}catch{}b(this,vt,f.replace(/ /gu,"_")),t=t.slice(0,u).trim()}let[d,c]=p?Wa(t):[0,t];this.valid=!!(t||o&&this.ns===0&&g(this,vt)!==void 0)&&bn(t)===t&&(d===0||a===void 0||a.split("/",d+1).length>d)&&!/^:|\0\d+[eh!+-]\x7F|[<>[\]{}|\n]|%[\da-f]{2}|(?:^|\/)\.{1,2}(?:$|\/)/iu.test(c),this.main=t,b(this,Rr,r.namespaces),b(this,kt,r.articlePath||"/wiki/$1"),g(this,kt).includes("$1")||b(this,kt,g(this,kt)+`${g(this,kt).endsWith("/")?"":"/"}$1`)}get ns(){return g(this,Yt)}get fragment(){return g(this,vt)}get main(){return g(this,Fr)}set main(t){t=t.replace(/_/gu," ").trim(),b(this,Fr,t&&t[0].toUpperCase()+t.slice(1))}get prefix(){let t=g(this,Rr)[this.ns];return t+(t&&":")}get title(){return this.getRedirection()[1]}get extension(){let{main:t}=this,e=t.lastIndexOf(".");return e===-1?void 0:t.slice(e+1).toLowerCase()}getRedirection(){let{prefix:t}=this,e=t;return $(this,mn,Ua).call(this,e)}setFragment(t){b(this,vt,t)}getUrl(t){throw new Error("Title.getUrl method is only available in the LSP version!")}};Fr=new WeakMap,Rr=new WeakMap,kt=new WeakMap,Yt=new WeakMap,vt=new WeakMap,mn=new WeakSet,Ua=function(t,e=!0){var n,i;let r=(t+this.main).replace(/ /gu,"_");if(r.startsWith("/"))r=((n=this.page)!=null?n:"")+r.replace(/(.)\/$/u,"$1");else if(r.startsWith("../")&&((i=this.page)!=null&&i.includes("/"))){let[o,a]=Wa(r),l=this.page.split("/");l.length>o&&(r=l.slice(0,-o).join("/")+(a&&"/")+a)}return[!1,r]}});var Fi,fd,Br,za,md,M,ue=x(()=>{Ce();Tn();J();Da();Fi=!0,fd=(s,t,e)=>typeof s=="string"?[!!t,e,s]:[!!s,t,e],Br={config:yn,get rules(){},get i18n(){},set i18n(s){},get lintConfig(){},set lintConfig(s){},get viewOnly(){return Fi},set viewOnly(s){Fi&&!s&&ee.rev++,Fi=s},internal:!1,getConfig(s){let t=s!=null?s:this.config,{doubleUnderscore:e,ext:r,parserFunction:n,variable:i}=t;for(let o=0;o<2;o++)e[o].length===0&&(e[o]=Object.keys(e[o+2]));return r.includes("translate")&&!i.includes("translationlanguage")&&(i.push("translationlanguage"),n[1].TRANSLATIONLANGUAGE="translationlanguage"),{...yn,...t,excludes:[]}},msg(s,t=""){},normalizeTitle(s,t=0,e,r=Br.getConfig(),n){let i;if(n!=null&&n.halfParsed)i=new Lr(s,t,r,n);else{let{Token:o}=(B(),q(fn));i=ee.run(()=>{let a=new o(s,r);a.type="root",a.pageName=n==null?void 0:n.page,a.parseOnce(0,e).parseOnce();let l=new Lr(a.firstChild.toString(),t,r,n);a.build();let p=["main","fragment"];for(let u of p){let d=l[u];if(d!=null&&d.includes("\0")){let c=a.buildFromStr(d,1);u==="main"?l.main=c:l.setFragment(c)}}return l},this)}return i},parse(s,t,e,r,n){s=Mi(s);let i,o,a,l;typeof t=="string"?(i=!!e,o=r,a=n,l=t):(i=!!t,o=e,a=r,l=n),o!=null||(o=11),a!=null||(a=this.getConfig());let p,{Token:u}=(B(),q(fn));return ee.run(()=>{let c=new u(s,a);return c.type="root",c.pageName=l,c.parse(o,i)})},parseWithRef(s,t,e,r=t.getAttribute("include")){return this.parse(s,r,e,t.getAttribute("config"),t.pageName)},createLanguageService(s={}){},lint(s,t,e,r){},print(s,t,e,r){{let[n,i,o]=fd(t,e,r);return ee.internal(()=>this.parse(s,n,void 0,i,o).print(),this)}}},za={},md=new Set(["lintConfig","normalizeTitle","parse","createLanguageService"]);for(let s in Br)md.has(s)||(za[s]={enumerable:!1});Object.defineProperties(Br,za);Object.assign(typeof globalThis=="object"?globalThis:self,{Parser:Br});M=Br});ue();})();
|
|
28
28
|
//# sourceMappingURL=bundle.min.js.map
|
package/dist/addon/attribute.js
CHANGED
|
@@ -163,7 +163,7 @@ attributes_1.AttributesToken.prototype.toggleAttr =
|
|
|
163
163
|
key = (0, string_1.trimLc)(key);
|
|
164
164
|
const attr = this.getAttrToken(key);
|
|
165
165
|
/* c8 ignore next 3 */
|
|
166
|
-
if (attr && attr.getValue() !==
|
|
166
|
+
if (attr && attr.getValue() !== '') {
|
|
167
167
|
throw new RangeError(`${key} attribute is not Boolean!`);
|
|
168
168
|
}
|
|
169
169
|
if (attr) {
|
package/dist/addon/transclude.js
CHANGED
|
@@ -18,9 +18,7 @@ const atom_1 = require("../src/atom");
|
|
|
18
18
|
*/
|
|
19
19
|
const format = (token) => {
|
|
20
20
|
const { lastChild, type } = token, isParameter = lastChild.is('parameter');
|
|
21
|
-
if (!(type === 'template'
|
|
22
|
-
? isParameter && lastChild.anon
|
|
23
|
-
: lastChild.is('magic-word-name'))
|
|
21
|
+
if (!(type === 'template' ? isParameter && lastChild.anon : lastChild.is('magic-word-name'))
|
|
24
22
|
&& !lastChild.toString().endsWith('\n')) {
|
|
25
23
|
(isParameter ? lastChild.lastChild : lastChild).insertAt('\n');
|
|
26
24
|
}
|
package/dist/bin/config.js
CHANGED
|
@@ -40,7 +40,7 @@ const filterGadget = (id) => {
|
|
|
40
40
|
const n = Number(id);
|
|
41
41
|
return n < 2300 || n > 2303; // Gadget, Gadget talk, Gadget definition, Gadget definition talk
|
|
42
42
|
};
|
|
43
|
-
const pkg = "wikiparser-node", version = "1.
|
|
43
|
+
const pkg = "wikiparser-node", version = "1.42.0";
|
|
44
44
|
/**
|
|
45
45
|
* Get the parser configuration for a Wikimedia Foundation project.
|
|
46
46
|
* @param site site nickname
|
package/dist/index.js
CHANGED
|
@@ -378,8 +378,7 @@ const Parser = {
|
|
|
378
378
|
[name] = entry;
|
|
379
379
|
}
|
|
380
380
|
const { firstChild, length } = debug_1.Shadow.internal(() => this.parse(`{{${name}:${args.join('|')}}}`, false, 2), this);
|
|
381
|
-
result = length === 1 && firstChild.is('magic-word')
|
|
382
|
-
&& constants_1.functionHooks.get(lcName)(firstChild);
|
|
381
|
+
result = length === 1 && firstChild.is('magic-word') && constants_1.functionHooks.get(lcName)(firstChild);
|
|
383
382
|
}
|
|
384
383
|
else {
|
|
385
384
|
const { expandMagicWord } = require('./render/magicWords');
|
package/dist/lib/element.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import { AstNode } from './node';
|
|
|
2
2
|
import type { TokenTypes, LintError, AST } from '../base';
|
|
3
3
|
import type { ElementLike } from '../mixin/elementLike';
|
|
4
4
|
import type { AstNodes, AstText, Token, FileToken, LinkToken, RedirectTargetToken, ExtLinkToken, MagicLinkToken, ImageParameterToken, TranscludeToken } from '../internal';
|
|
5
|
+
import type { TokenTypeMap, SelectedTokenTypes } from '../map';
|
|
5
6
|
declare type LinkTokens = LinkToken | RedirectTargetToken | ExtLinkToken | MagicLinkToken | ImageParameterToken;
|
|
6
7
|
export interface CaretPosition {
|
|
7
8
|
readonly offsetNode: AstNodes;
|
|
@@ -54,13 +55,6 @@ export declare abstract class AstElement extends AstNode {
|
|
|
54
55
|
* @throws `RangeError` 不能插入祖先或子节点
|
|
55
56
|
*/
|
|
56
57
|
insertAt<T extends AstNodes>(node: T, i?: number): T;
|
|
57
|
-
/**
|
|
58
|
-
* Get the closest ancestor node that matches the selector
|
|
59
|
-
*
|
|
60
|
-
* 最近的符合选择器的祖先节点
|
|
61
|
-
* @param selector selector / 选择器
|
|
62
|
-
*/
|
|
63
|
-
closest<T = Token>(selector: string): T | undefined;
|
|
64
58
|
/**
|
|
65
59
|
* Insert a batch of child nodes at the end
|
|
66
60
|
*
|
|
@@ -120,7 +114,8 @@ export declare abstract class AstElement extends AstNode {
|
|
|
120
114
|
* 检查是否符合选择器
|
|
121
115
|
* @param selector selector / 选择器
|
|
122
116
|
*/
|
|
123
|
-
matches<
|
|
117
|
+
matches<K extends SelectedTokenTypes>(selector: K): this is TokenTypeMap[K];
|
|
118
|
+
matches<T extends Token>(selector: string): this is T;
|
|
124
119
|
/**
|
|
125
120
|
* Insert a batch of child nodes at the start
|
|
126
121
|
*
|