@fastgpt-plugin/cli 0.1.0-alpha.5 → 0.1.0-alpha.7
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/dist/{context-DoVwxr5H-B6IEtQ3M.js → context-DoVwxr5H-CUnaSkDS.js} +1 -1
- package/dist/dist-BClt8EYk.js +27 -0
- package/dist/index.js +51 -51
- package/dist/{resolver-o20sdYK5-D5TGopbk.js → resolver-o20sdYK5-Dnq-MmKm.js} +1 -1
- package/dist/{tsc-By9Scnlt.js → tsc-BoybAFN3.js} +1 -1
- package/package.json +7 -7
- package/templates/tool/package.json +2 -1
- package/templates/tool/src/tool.test.ts +3 -3
- package/templates/tool-suite/package.json +2 -1
- package/dist/dist-mM4pkTG1.js +0 -27
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import{C as e,S as t,_ as n,a as r,b as i,c as a,d as o,f as s,g as c,h as l,i as u,l as d,m as f,n as p,o as m,p as h,s as g,t as ee,u as _,v,x as te,y as ne}from"./index.js";import{n as y,r as b,t as re}from"./context-DoVwxr5H-CUnaSkDS.js";import ie,{createRequire as ae}from"node:module";import x,{dirname as oe,extname as se}from"node:path";import ce from"node:process";import le from"node:fs";import ue from"fs";import de from"path";import S from"os";var fe=44,pe=59,me=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/`,he=new Uint8Array(64),ge=new Uint8Array(128);for(let e=0;e<me.length;e++){let t=me.charCodeAt(e);he[e]=t,ge[t]=e}function _e(e,t){let n=0,r=0,i=0;do i=ge[e.next()],n|=(i&31)<<r,r+=5;while(i&32);let a=n&1;return n>>>=1,a&&(n=-2147483648|-n),t+n}function ve(e,t,n){let r=t-n;r=r<0?-r<<1|1:r<<1;do{let t=r&31;r>>>=5,r>0&&(t|=32),e.write(he[t])}while(r>0);return t}function ye(e,t){return e.pos>=t?!1:e.peek()!==fe}var be=1024*16,xe=typeof TextDecoder<`u`?new TextDecoder:typeof Buffer<`u`?{decode(e){return Buffer.from(e.buffer,e.byteOffset,e.byteLength).toString()}}:{decode(e){let t=``;for(let n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return t}},Se=class{constructor(){this.pos=0,this.out=``,this.buffer=new Uint8Array(be)}write(e){let{buffer:t}=this;t[this.pos++]=e,this.pos===be&&(this.out+=xe.decode(t),this.pos=0)}flush(){let{buffer:e,out:t,pos:n}=this;return n>0?t+xe.decode(e.subarray(0,n)):t}},Ce=class{constructor(e){this.pos=0,this.buffer=e}next(){return this.buffer.charCodeAt(this.pos++)}peek(){return this.buffer.charCodeAt(this.pos)}indexOf(e){let{buffer:t,pos:n}=this,r=t.indexOf(e,n);return r===-1?t.length:r}};function we(e){let{length:t}=e,n=new Ce(e),r=[],i=0,a=0,o=0,s=0,c=0;do{let e=n.indexOf(`;`),t=[],l=!0,u=0;for(i=0;n.pos<e;){let r;i=_e(n,i),i<u&&(l=!1),u=i,ye(n,e)?(a=_e(n,a),o=_e(n,o),s=_e(n,s),ye(n,e)?(c=_e(n,c),r=[i,a,o,s,c]):r=[i,a,o,s]):r=[i],t.push(r),n.pos++}l||Te(t),r.push(t),n.pos=e+1}while(n.pos<=t);return r}function Te(e){e.sort(Ee)}function Ee(e,t){return e[0]-t[0]}function De(e){let t=new Se,n=0,r=0,i=0,a=0;for(let o=0;o<e.length;o++){let s=e[o];if(o>0&&t.write(pe),s.length===0)continue;let c=0;for(let e=0;e<s.length;e++){let o=s[e];e>0&&t.write(fe),c=ve(t,o[0],c),o.length!==1&&(n=ve(t,o[1],n),r=ve(t,o[2],r),i=ve(t,o[3],i),o.length!==4&&(a=ve(t,o[4],a)))}}return t.flush()}const Oe=/^[\w+.-]+:\/\//,ke=/^([\w+.-]+:)\/\/([^@/#?]*@)?([^:/#?]*)(:\d+)?(\/[^#?]*)?(\?[^#]*)?(#.*)?/,Ae=/^file:(?:\/\/((?![a-z]:)[^/#?]*)?)?(\/?[^#?]*)(\?[^#]*)?(#.*)?/i;function je(e){return Oe.test(e)}function Me(e){return e.startsWith(`//`)}function Ne(e){return e.startsWith(`/`)}function Pe(e){return e.startsWith(`file:`)}function Fe(e){return/^[.?#]/.test(e)}function Ie(e){let t=ke.exec(e);return Re(t[1],t[2]||``,t[3],t[4]||``,t[5]||`/`,t[6]||``,t[7]||``)}function Le(e){let t=Ae.exec(e),n=t[2];return Re(`file:`,``,t[1]||``,``,Ne(n)?n:`/`+n,t[3]||``,t[4]||``)}function Re(e,t,n,r,i,a,o){return{scheme:e,user:t,host:n,port:r,path:i,query:a,hash:o,type:7}}function ze(e){if(Me(e)){let t=Ie(`http:`+e);return t.scheme=``,t.type=6,t}if(Ne(e)){let t=Ie(`http://foo.com`+e);return t.scheme=``,t.host=``,t.type=5,t}if(Pe(e))return Le(e);if(je(e))return Ie(e);let t=Ie(`http://foo.com/`+e);return t.scheme=``,t.host=``,t.type=e?e.startsWith(`?`)?3:e.startsWith(`#`)?2:4:1,t}function Be(e){if(e.endsWith(`/..`))return e;let t=e.lastIndexOf(`/`);return e.slice(0,t+1)}function Ve(e,t){He(t,t.type),e.path===`/`?e.path=t.path:e.path=Be(t.path)+e.path}function He(e,t){let n=t<=4,r=e.path.split(`/`),i=1,a=0,o=!1;for(let e=1;e<r.length;e++){let t=r[e];if(!t){o=!0;continue}if(o=!1,t!==`.`){if(t===`..`){a?(o=!0,a--,i--):n&&(r[i++]=t);continue}r[i++]=t,a++}}let s=``;for(let e=1;e<i;e++)s+=`/`+r[e];(!s||o&&!s.endsWith(`/..`))&&(s+=`/`),e.path=s}function Ue(e,t){if(!e&&!t)return``;let n=ze(e),r=n.type;if(t&&r!==7){let e=ze(t),i=e.type;switch(r){case 1:n.hash=e.hash;case 2:n.query=e.query;case 3:case 4:Ve(n,e);case 5:n.user=e.user,n.host=e.host,n.port=e.port;case 6:n.scheme=e.scheme}i>r&&(r=i)}He(n,r);let i=n.query+n.hash;switch(r){case 2:case 3:return i;case 4:{let r=n.path.slice(1);return r?Fe(t||e)&&!Fe(r)?`./`+r+i:r+i:i||`.`}case 5:return n.path+i;default:return n.scheme+`//`+n.user+n.host+n.port+n.path+i}}function We(e){if(!e)return``;let t=e.lastIndexOf(`/`);return e.slice(0,t+1)}function Ge(e,t){let n=We(e),r=t?t+`/`:``;return e=>Ue(r+(e||``),n)}var Ke=0,qe=1,Je=2,Ye=3,Xe=4;function Ze(e,t){let n=Qe(e,0);if(n===e.length)return e;t||(e=e.slice());for(let r=n;r<e.length;r=Qe(e,r+1))e[r]=et(e[r],t);return e}function Qe(e,t){for(let n=t;n<e.length;n++)if(!$e(e[n]))return n;return e.length}function $e(e){for(let t=1;t<e.length;t++)if(e[t][Ke]<e[t-1][Ke])return!1;return!0}function et(e,t){return t||(e=e.slice()),e.sort(tt)}function tt(e,t){return e[Ke]-t[Ke]}var nt=!1;function rt(e,t,n,r){for(;n<=r;){let i=n+(r-n>>1),a=e[i][Ke]-t;if(a===0)return nt=!0,i;a<0?n=i+1:r=i-1}return nt=!1,n-1}function it(e,t,n){for(let r=n+1;r<e.length&&e[r][Ke]===t;n=r++);return n}function at(e,t,n){for(let r=n-1;r>=0&&e[r][Ke]===t;n=r--);return n}function ot(){return{lastKey:-1,lastNeedle:-1,lastIndex:-1}}function st(e,t,n,r){let{lastKey:i,lastNeedle:a,lastIndex:o}=n,s=0,c=e.length-1;if(r===i){if(t===a)return nt=o!==-1&&e[o][Ke]===t,o;t>=a?s=o===-1?0:o:c=o}return n.lastKey=r,n.lastNeedle=t,n.lastIndex=rt(e,t,s,c)}function ct(e){return typeof e==`string`?JSON.parse(e):e}var lt="`line` must be greater than 0 (lines start at line 1)",ut="`column` must be greater than or equal to 0 (columns start at column 0)",dt=-1,ft=1,pt=class{constructor(e,t){let n=typeof e==`string`;if(!n&&e._decodedMemo)return e;let r=ct(e),{version:i,file:a,names:o,sourceRoot:s,sources:c,sourcesContent:l}=r;this.version=i,this.file=a,this.names=o||[],this.sourceRoot=s,this.sources=c,this.sourcesContent=l,this.ignoreList=r.ignoreList||r.x_google_ignoreList||void 0;let u=Ge(t,s);this.resolvedSources=c.map(u);let{mappings:d}=r;if(typeof d==`string`)this._encoded=d,this._decoded=void 0;else if(Array.isArray(d))this._encoded=void 0,this._decoded=Ze(d,n);else if(r.sections)throw Error(`TraceMap passed sectioned source map, please use FlattenMap export instead`);else throw Error(`invalid source map: ${JSON.stringify(r)}`);this._decodedMemo=ot(),this._bySources=void 0,this._bySourceMemos=void 0}};function mt(e){return e}function ht(e){var t;return(t=mt(e))._decoded||(t._decoded=we(mt(e)._encoded))}function gt(e,t){let{line:n,column:r,bias:i}=t;if(n--,n<0)throw Error(lt);if(r<0)throw Error(ut);let a=ht(e);if(n>=a.length)return _t(null,null,null,null);let o=a[n],s=vt(o,mt(e)._decodedMemo,n,r,i||ft);if(s===-1)return _t(null,null,null,null);let c=o[s];if(c.length===1)return _t(null,null,null,null);let{names:l,resolvedSources:u}=e;return _t(u[c[qe]],c[Je]+1,c[Ye],c.length===5?l[c[Xe]]:null)}function _t(e,t,n,r){return{source:e,line:t,column:n,name:r}}function vt(e,t,n,r,i){let a=st(e,r,t,n);return nt?a=(i===dt?it:at)(e,r,a):i===dt&&a++,a===-1||a===e.length?-1:a}var yt=class{constructor(){this._indexes={__proto__:null},this.array=[]}};function bt(e){return e}function xt(e,t){return bt(e)._indexes[t]}function St(e,t){let n=xt(e,t);if(n!==void 0)return n;let{array:r,_indexes:i}=bt(e);return i[t]=r.push(t)-1}var Ct=0,wt=1,Tt=2,Et=3,Dt=4,Ot=-1,kt=class{constructor({file:e,sourceRoot:t}={}){this._names=new yt,this._sources=new yt,this._sourcesContent=[],this._mappings=[],this.file=e,this.sourceRoot=t,this._ignoreList=new yt}};function At(e){return e}var jt=(e,t)=>Ut(!0,e,t);function Mt(e,t,n){let{_sources:r,_sourcesContent:i}=At(e),a=St(r,t);i[a]=n}function Nt(e){let{_mappings:t,_sources:n,_sourcesContent:r,_names:i,_ignoreList:a}=At(e);return Bt(t),{version:3,file:e.file||void 0,names:i.array,sourceRoot:e.sourceRoot||void 0,sources:n.array,sourcesContent:r,mappings:t,ignoreList:a.array}}function Pt(e){let t=Nt(e);return Object.assign({},t,{mappings:De(t.mappings)})}function Ft(e){let t=[],{_mappings:n,_sources:r,_names:i}=At(e);for(let e=0;e<n.length;e++){let a=n[e];for(let n=0;n<a.length;n++){let o=a[n],s={line:e+1,column:o[Ct]},c,l,u;o.length!==1&&(c=r.array[o[wt]],l={line:o[Tt]+1,column:o[Et]},o.length===5&&(u=i.array[o[Dt]])),t.push({generated:s,source:c,original:l,name:u})}}return t}function It(e,t,n,r,i,a,o,s,c){let{_mappings:l,_sources:u,_sourcesContent:d,_names:f}=At(t),p=Lt(l,n),m=Rt(p,r);if(!i)return e&&Vt(p,m)?void 0:zt(p,m,[r]);let h=St(u,i),g=s?St(f,s):Ot;if(h===d.length&&(d[h]=c??null),!(e&&Ht(p,m,h,a,o,g)))return zt(p,m,s?[r,h,a,o,g]:[r,h,a,o])}function Lt(e,t){for(let n=e.length;n<=t;n++)e[n]=[];return e[t]}function Rt(e,t){let n=e.length;for(let r=n-1;r>=0&&!(t>=e[r][Ct]);n=r--);return n}function zt(e,t,n){for(let n=e.length;n>t;n--)e[n]=e[n-1];e[t]=n}function Bt(e){let{length:t}=e,n=t;for(let t=n-1;t>=0&&!(e[t].length>0);n=t,t--);n<t&&(e.length=n)}function Vt(e,t){return t===0?!0:e[t-1].length===1}function Ht(e,t,n,r,i,a){if(t===0)return!1;let o=e[t-1];return o.length===1?!1:n===o[wt]&&r===o[Tt]&&i===o[Et]&&a===(o.length===5?o[Dt]:Ot)}function Ut(e,t,n){let{generated:r,source:i,original:a,name:o,content:s}=n;return i?It(e,t,r.line-1,r.column,i,a.line-1,a.column,o,s):It(e,t,r.line-1,r.column,null,null,null,null,null)}let Wt=`ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽ-ೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-Ა-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ--ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ`,Gt=`·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ--ᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・`;const Kt=RegExp(`[`+Wt+`]`),qt=RegExp(`[`+Wt+Gt+`]`);Wt=Gt=null;const Jt=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,4,51,13,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,7,25,39,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,39,27,10,22,251,41,7,1,17,5,57,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,20,1,64,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,31,9,2,0,3,0,2,37,2,0,26,0,2,0,45,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,200,32,32,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,24,43,261,18,16,0,2,12,2,33,125,0,80,921,103,110,18,195,2637,96,16,1071,18,5,26,3994,6,582,6842,29,1763,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,433,44,212,63,33,24,3,24,45,74,6,0,67,12,65,1,2,0,15,4,10,7381,42,31,98,114,8702,3,2,6,2,1,2,290,16,0,30,2,3,0,15,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,7,5,262,61,147,44,11,6,17,0,322,29,19,43,485,27,229,29,3,0,208,30,2,2,2,1,2,6,3,4,10,1,225,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4381,3,5773,3,7472,16,621,2467,541,1507,4938,6,8489],Yt=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,7,9,32,4,318,1,78,5,71,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,3,0,158,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,68,8,2,0,3,0,2,3,2,4,2,0,15,1,83,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,7,19,58,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,199,7,137,9,54,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,55,9,266,3,10,1,2,0,49,6,4,4,14,10,5350,0,7,14,11465,27,2343,9,87,9,39,4,60,6,26,9,535,9,470,0,2,54,8,3,82,0,12,1,19628,1,4178,9,519,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,101,0,161,6,10,9,357,0,62,13,499,13,245,1,2,9,233,0,3,0,8,1,6,0,475,6,110,6,6,9,4759,9,787719,239];function Xt(e,t){let n=65536;for(let r=0,i=t.length;r<i;r+=2){if(n+=t[r],n>e)return!1;if(n+=t[r+1],n>=e)return!0}return!1}function Zt(e){return e<65?e===36:e<=90?!0:e<97?e===95:e<=122?!0:e<=65535?e>=170&&Kt.test(String.fromCharCode(e)):Xt(e,Jt)}function Qt(e){return e<48?e===36:e<58?!0:e<65?!1:e<=90?!0:e<97?e===95:e<=122?!0:e<=65535?e>=170&&qt.test(String.fromCharCode(e)):Xt(e,Jt)||Xt(e,Yt)}function $t(e){let t=!0;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);if((r&64512)==55296&&n+1<e.length){let t=e.charCodeAt(++n);(t&64512)==56320&&(r=65536+((r&1023)<<10)+(t&1023))}if(t){if(t=!1,!Zt(r))return!1}else if(!Qt(r))return!1}return!t}const en={keyword:`break.case.catch.continue.debugger.default.do.else.finally.for.function.if.return.switch.throw.try.var.const.while.with.new.this.super.class.extends.export.import.null.true.false.in.instanceof.typeof.void.delete`.split(`.`),strict:[`implements`,`interface`,`let`,`package`,`private`,`protected`,`public`,`static`,`yield`],strictBind:[`eval`,`arguments`]},tn=new Set(en.keyword),nn=new Set(en.strict);new Set(en.strictBind);function rn(e,t){return t&&e===`await`||e===`enum`}function an(e,t){return rn(e,t)||nn.has(e)}function on(e){return tn.has(e)}var sn=function(e){return e>=48&&e<=57};const cn={decBinOct:new Set([46,66,69,79,95,98,101,111]),hex:new Set([46,88,95,120])},ln={bin:e=>e===48||e===49,oct:e=>e>=48&&e<=55,dec:e=>e>=48&&e<=57,hex:e=>e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102};function un(e,t,n,r,i,a){let o=n,s=r,c=i,l=``,u=null,d=n,{length:f}=t;for(;;){if(n>=f){a.unterminated(o,s,c),l+=t.slice(d,n);break}let p=t.charCodeAt(n);if(dn(e,p,t,n)){l+=t.slice(d,n);break}if(p===92){l+=t.slice(d,n);let o=fn(t,n,r,i,e===`template`,a);o.ch===null&&!u?u={pos:n,lineStart:r,curLine:i}:l+=o.ch,{pos:n,lineStart:r,curLine:i}=o,d=n}else p===8232||p===8233?(++n,++i,r=n):p===10||p===13?e===`template`?(l+=t.slice(d,n)+`
|
|
2
|
+
`,++n,p===13&&t.charCodeAt(n)===10&&++n,++i,d=r=n):a.unterminated(o,s,c):++n}return{pos:n,str:l,firstInvalidLoc:u,lineStart:r,curLine:i}}function dn(e,t,n,r){return e===`template`?t===96||t===36&&n.charCodeAt(r+1)===123:t===(e===`double`?34:39)}function fn(e,t,n,r,i,a){let o=!i;t++;let s=e=>({pos:t,ch:e,lineStart:n,curLine:r}),c=e.charCodeAt(t++);switch(c){case 110:return s(`
|
|
3
|
+
`);case 114:return s(`\r`);case 120:{let i;return{code:i,pos:t}=pn(e,t,n,r,2,!1,o,a),s(i===null?null:String.fromCharCode(i))}case 117:{let i;return{code:i,pos:t}=hn(e,t,n,r,o,a),s(i===null?null:String.fromCodePoint(i))}case 116:return s(` `);case 98:return s(`\b`);case 118:return s(`\v`);case 102:return s(`\f`);case 13:e.charCodeAt(t)===10&&++t;case 10:n=t,++r;case 8232:case 8233:return s(``);case 56:case 57:if(i)return s(null);a.strictNumericEscape(t-1,n,r);default:if(c>=48&&c<=55){let o=t-1,c=/^[0-7]+/.exec(e.slice(o,t+2))[0],l=parseInt(c,8);l>255&&(c=c.slice(0,-1),l=parseInt(c,8)),t+=c.length-1;let u=e.charCodeAt(t);if(c!==`0`||u===56||u===57){if(i)return s(null);a.strictNumericEscape(o,n,r)}return s(String.fromCharCode(l))}return s(String.fromCharCode(c))}}function pn(e,t,n,r,i,a,o,s){let c=t,l;return{n:l,pos:t}=mn(e,t,n,r,16,i,a,!1,s,!o),l===null&&(o?s.invalidEscapeSequence(c,n,r):t=c-1),{code:l,pos:t}}function mn(e,t,n,r,i,a,o,s,c,l){let u=t,d=i===16?cn.hex:cn.decBinOct,f=i===16?ln.hex:i===10?ln.dec:i===8?ln.oct:ln.bin,p=!1,m=0;for(let u=0,h=a??1/0;u<h;++u){let a=e.charCodeAt(t),u;if(a===95&&s!==`bail`){let i=e.charCodeAt(t-1),a=e.charCodeAt(t+1);if(!s){if(l)return{n:null,pos:t};c.numericSeparatorInEscapeSequence(t,n,r)}else if(Number.isNaN(a)||!f(a)||d.has(i)||d.has(a)){if(l)return{n:null,pos:t};c.unexpectedNumericSeparator(t,n,r)}++t;continue}if(u=a>=97?a-97+10:a>=65?a-65+10:sn(a)?a-48:1/0,u>=i){if(u<=9&&l)return{n:null,pos:t};if(u<=9&&c.invalidDigit(t,n,r,i))u=0;else if(o)u=0,p=!0;else break}++t,m=m*i+u}return t===u||a!=null&&t-u!==a||p?{n:null,pos:t}:{n:m,pos:t}}function hn(e,t,n,r,i,a){let o=e.charCodeAt(t),s;if(o===123){if(++t,{code:s,pos:t}=pn(e,t,n,r,e.indexOf(`}`,t)-t,!0,i,a),++t,s!==null&&s>1114111)if(i)a.invalidCodePoint(t,n,r);else return{code:null,pos:t}}else ({code:s,pos:t}=pn(e,t,n,r,4,!1,i,a));return{code:s,pos:t}}var gn=t({ACCESSOR_TYPES:()=>jT,ALIAS_KEYS:()=>wc,ASSIGNMENT_OPERATORS:()=>_c,AnyTypeAnnotation:()=>Fh,ArgumentPlaceholder:()=>l_,ArrayExpression:()=>tm,ArrayPattern:()=>$m,ArrayTypeAnnotation:()=>Ih,ArrowFunctionExpression:()=>eh,AssignmentExpression:()=>nm,AssignmentPattern:()=>Qm,AwaitExpression:()=>Ch,BINARY_OPERATORS:()=>gc,BINARY_TYPES:()=>Hw,BLOCKPARENT_TYPES:()=>Ww,BLOCK_TYPES:()=>Gw,BOOLEAN_BINARY_OPERATORS:()=>mc,BOOLEAN_NUMBER_BINARY_OPERATORS:()=>dc,BOOLEAN_UNARY_OPERATORS:()=>vc,BUILDER_KEYS:()=>Ec,BigIntLiteral:()=>Th,BinaryExpression:()=>rm,BindExpression:()=>u_,BlockStatement:()=>sm,BooleanLiteral:()=>Om,BooleanLiteralTypeAnnotation:()=>Rh,BooleanTypeAnnotation:()=>Lh,BreakStatement:()=>cm,CLASS_TYPES:()=>_T,COMMENT_KEYS:()=>cc,COMPARISON_BINARY_OPERATORS:()=>pc,COMPLETIONSTATEMENT_TYPES:()=>Jw,CONDITIONAL_TYPES:()=>Yw,CallExpression:()=>lm,CatchClause:()=>um,ClassAccessorProperty:()=>d_,ClassBody:()=>th,ClassDeclaration:()=>rh,ClassExpression:()=>nh,ClassImplements:()=>Bh,ClassMethod:()=>hh,ClassPrivateMethod:()=>jh,ClassPrivateProperty:()=>Ah,ClassProperty:()=>kh,ConditionalExpression:()=>dm,ContinueStatement:()=>fm,DECLARATION_TYPES:()=>iT,DEPRECATED_ALIASES:()=>pl,DEPRECATED_KEYS:()=>Dc,DebuggerStatement:()=>pm,DeclareClass:()=>Vh,DeclareExportAllDeclaration:()=>Xh,DeclareExportDeclaration:()=>Yh,DeclareFunction:()=>Hh,DeclareInterface:()=>Uh,DeclareModule:()=>Wh,DeclareModuleExports:()=>Gh,DeclareOpaqueType:()=>qh,DeclareTypeAlias:()=>Kh,DeclareVariable:()=>Jh,DeclaredPredicate:()=>Zh,Decorator:()=>f_,Directive:()=>am,DirectiveLiteral:()=>om,DoExpression:()=>p_,DoWhileStatement:()=>mm,ENUMBODY_TYPES:()=>DT,ENUMMEMBER_TYPES:()=>OT,EQUALITY_BINARY_OPERATORS:()=>fc,EXPORTDECLARATION_TYPES:()=>yT,EXPRESSIONWRAPPER_TYPES:()=>Qw,EXPRESSION_TYPES:()=>Vw,EmptyStatement:()=>hm,EmptyTypeAnnotation:()=>cg,EnumBooleanBody:()=>Ig,EnumBooleanMember:()=>Bg,EnumDeclaration:()=>Fg,EnumDefaultedMember:()=>Ug,EnumNumberBody:()=>Lg,EnumNumberMember:()=>Vg,EnumStringBody:()=>Rg,EnumStringMember:()=>Hg,EnumSymbolBody:()=>zg,ExistsTypeAnnotation:()=>Qh,ExportAllDeclaration:()=>ih,ExportDefaultDeclaration:()=>ah,ExportDefaultSpecifier:()=>m_,ExportNamedDeclaration:()=>oh,ExportNamespaceSpecifier:()=>Eh,ExportSpecifier:()=>sh,ExpressionStatement:()=>gm,FLATTENABLE_KEYS:()=>oc,FLIPPED_ALIAS_KEYS:()=>E,FLOWBASEANNOTATION_TYPES:()=>wT,FLOWDECLARATION_TYPES:()=>TT,FLOWPREDICATE_TYPES:()=>ET,FLOWTYPE_TYPES:()=>CT,FLOW_TYPES:()=>ST,FORXSTATEMENT_TYPES:()=>eT,FOR_INIT_KEYS:()=>sc,FOR_TYPES:()=>$w,FUNCTIONPARAMETER_TYPES:()=>aT,FUNCTIONPARENT_TYPES:()=>nT,FUNCTION_TYPES:()=>tT,File:()=>_m,ForInStatement:()=>vm,ForOfStatement:()=>ch,ForStatement:()=>ym,FunctionDeclaration:()=>bm,FunctionExpression:()=>xm,FunctionTypeAnnotation:()=>$h,FunctionTypeParam:()=>eg,GenericTypeAnnotation:()=>tg,IMMUTABLE_TYPES:()=>uT,IMPORTOREXPORTDECLARATION_TYPES:()=>vT,INHERIT_KEYS:()=>Sc,Identifier:()=>Sm,IfStatement:()=>Cm,Import:()=>wh,ImportAttribute:()=>Ph,ImportDeclaration:()=>lh,ImportDefaultSpecifier:()=>uh,ImportExpression:()=>ph,ImportNamespaceSpecifier:()=>dh,ImportSpecifier:()=>fh,IndexedAccessType:()=>Wg,InferredPredicate:()=>ng,InterfaceDeclaration:()=>ig,InterfaceExtends:()=>rg,InterfaceTypeAnnotation:()=>ag,InterpreterDirective:()=>im,IntersectionTypeAnnotation:()=>og,JSXAttribute:()=>Kg,JSXClosingElement:()=>qg,JSXClosingFragment:()=>o_,JSXElement:()=>Jg,JSXEmptyExpression:()=>Yg,JSXExpressionContainer:()=>Xg,JSXFragment:()=>i_,JSXIdentifier:()=>Qg,JSXMemberExpression:()=>$g,JSXNamespacedName:()=>e_,JSXOpeningElement:()=>t_,JSXOpeningFragment:()=>a_,JSXSpreadAttribute:()=>n_,JSXSpreadChild:()=>Zg,JSXText:()=>r_,JSX_TYPES:()=>kT,LITERAL_TYPES:()=>lT,LOGICAL_OPERATORS:()=>lc,LOOP_TYPES:()=>Xw,LVAL_TYPES:()=>sT,LabeledStatement:()=>wm,LogicalExpression:()=>Am,METHOD_TYPES:()=>fT,MISCELLANEOUS_TYPES:()=>AT,MODULEDECLARATION_TYPES:()=>IT,MODULESPECIFIER_TYPES:()=>bT,MemberExpression:()=>jm,MetaProperty:()=>mh,MixedTypeAnnotation:()=>sg,ModuleExpression:()=>h_,NODE_FIELDS:()=>Tc,NODE_PARENT_VALIDATIONS:()=>Oc,NODE_UNION_SHAPES__PRIVATE:()=>kc,NUMBER_BINARY_OPERATORS:()=>hc,NUMBER_UNARY_OPERATORS:()=>yc,NewExpression:()=>Mm,NullLiteral:()=>Dm,NullLiteralTypeAnnotation:()=>zh,NullableTypeAnnotation:()=>lg,NumberLiteralTypeAnnotation:()=>ug,NumberTypeAnnotation:()=>dg,NumericLiteral:()=>Em,OBJECTMEMBER_TYPES:()=>pT,ObjectExpression:()=>Pm,ObjectMethod:()=>Fm,ObjectPattern:()=>gh,ObjectProperty:()=>Im,ObjectTypeAnnotation:()=>fg,ObjectTypeCallProperty:()=>mg,ObjectTypeIndexer:()=>hg,ObjectTypeInternalSlot:()=>pg,ObjectTypeProperty:()=>gg,ObjectTypeSpreadProperty:()=>_g,OpaqueType:()=>vg,OptionalCallExpression:()=>Oh,OptionalIndexedAccessType:()=>Gg,OptionalMemberExpression:()=>Dh,PATTERNLIKE_TYPES:()=>oT,PATTERN_TYPES:()=>gT,PLACEHOLDERS:()=>tl,PLACEHOLDERS_ALIAS:()=>nl,PLACEHOLDERS_FLIPPED_ALIAS:()=>rl,PRIVATE_TYPES:()=>xT,PROPERTY_TYPES:()=>mT,PUREISH_TYPES:()=>rT,ParenthesizedExpression:()=>Bm,Placeholder:()=>s_,PrivateName:()=>Mh,Program:()=>Nm,QualifiedTypeIdentifier:()=>yg,RegExpLiteral:()=>km,RestElement:()=>Lm,ReturnStatement:()=>Rm,SCOPABLE_TYPES:()=>Uw,STANDARDIZED_TYPES:()=>Bw,STATEMENT_OR_BLOCK_KEYS:()=>ac,STATEMENT_TYPES:()=>Kw,STRING_UNARY_OPERATORS:()=>bc,SequenceExpression:()=>zm,SpreadElement:()=>_h,StaticBlock:()=>Nh,StringLiteral:()=>Tm,StringLiteralTypeAnnotation:()=>bg,StringTypeAnnotation:()=>xg,Super:()=>vh,SwitchCase:()=>Vm,SwitchStatement:()=>Hm,SymbolTypeAnnotation:()=>Sg,TERMINATORLESS_TYPES:()=>qw,TSAnyKeyword:()=>D_,TSArrayType:()=>q_,TSAsExpression:()=>mv,TSBASETYPE_TYPES:()=>FT,TSBigIntKeyword:()=>k_,TSBooleanKeyword:()=>O_,TSCallSignatureDeclaration:()=>S_,TSClassImplements:()=>cv,TSConditionalType:()=>ev,TSConstructSignatureDeclaration:()=>C_,TSConstructorType:()=>H_,TSDeclareFunction:()=>y_,TSDeclareMethod:()=>b_,TSENTITYNAME_TYPES:()=>cT,TSEnumBody:()=>_v,TSEnumDeclaration:()=>vv,TSEnumMember:()=>yv,TSExportAssignment:()=>Ev,TSExternalModuleReference:()=>wv,TSFunctionType:()=>V_,TSImportEqualsDeclaration:()=>Cv,TSImportType:()=>Sv,TSIndexSignature:()=>E_,TSIndexedAccessType:()=>iv,TSInferType:()=>tv,TSInstantiationExpression:()=>pv,TSInterfaceBody:()=>dv,TSInterfaceDeclaration:()=>uv,TSInterfaceHeritage:()=>lv,TSIntersectionType:()=>$_,TSIntrinsicKeyword:()=>A_,TSLiteralType:()=>sv,TSMappedType:()=>av,TSMethodSignature:()=>T_,TSModuleBlock:()=>xv,TSModuleDeclaration:()=>bv,TSNamedTupleMember:()=>Z_,TSNamespaceExportDeclaration:()=>Dv,TSNeverKeyword:()=>j_,TSNonNullExpression:()=>Tv,TSNullKeyword:()=>M_,TSNumberKeyword:()=>N_,TSObjectKeyword:()=>P_,TSOptionalType:()=>Y_,TSParameterProperty:()=>v_,TSParenthesizedType:()=>nv,TSPropertySignature:()=>w_,TSQualifiedName:()=>x_,TSRestType:()=>X_,TSSatisfiesExpression:()=>hv,TSStringKeyword:()=>F_,TSSymbolKeyword:()=>I_,TSTYPEELEMENT_TYPES:()=>NT,TSTYPE_TYPES:()=>PT,TSTemplateLiteralType:()=>ov,TSThisType:()=>B_,TSTupleType:()=>J_,TSTypeAliasDeclaration:()=>fv,TSTypeAnnotation:()=>Ov,TSTypeAssertion:()=>gv,TSTypeLiteral:()=>K_,TSTypeOperator:()=>rv,TSTypeParameter:()=>jv,TSTypeParameterDeclaration:()=>Av,TSTypeParameterInstantiation:()=>kv,TSTypePredicate:()=>W_,TSTypeQuery:()=>G_,TSTypeReference:()=>U_,TSUndefinedKeyword:()=>L_,TSUnionType:()=>Q_,TSUnknownKeyword:()=>R_,TSVoidKeyword:()=>z_,TYPES:()=>ml,TYPESCRIPT_TYPES:()=>MT,TaggedTemplateExpression:()=>yh,TemplateElement:()=>bh,TemplateLiteral:()=>xh,ThisExpression:()=>Um,ThisTypeAnnotation:()=>Cg,ThrowStatement:()=>Wm,TopicReference:()=>g_,TryStatement:()=>Gm,TupleTypeAnnotation:()=>wg,TypeAlias:()=>Eg,TypeAnnotation:()=>Dg,TypeCastExpression:()=>Og,TypeParameter:()=>kg,TypeParameterDeclaration:()=>Ag,TypeParameterInstantiation:()=>jg,TypeofTypeAnnotation:()=>Tg,UNARYLIKE_TYPES:()=>hT,UNARY_OPERATORS:()=>xc,UPDATE_OPERATORS:()=>uc,USERWHITESPACABLE_TYPES:()=>dT,UnaryExpression:()=>Km,UnionTypeAnnotation:()=>Mg,UpdateExpression:()=>qm,V8IntrinsicIdentifier:()=>c_,VISITOR_KEYS:()=>Cc,VariableDeclaration:()=>Jm,VariableDeclarator:()=>Ym,Variance:()=>Ng,VoidPattern:()=>__,VoidTypeAnnotation:()=>Pg,WHILE_TYPES:()=>Zw,WhileStatement:()=>Xm,WithStatement:()=>Zm,YieldExpression:()=>Sh,__internal__deprecationWarning:()=>w,addComment:()=>Nw,addComments:()=>Mw,anyTypeAnnotation:()=>Qu,appendToMemberExpression:()=>nE,argumentPlaceholder:()=>Df,arrayExpression:()=>yl,arrayPattern:()=>gu,arrayTypeAnnotation:()=>$u,arrowFunctionExpression:()=>_u,assertAccessor:()=>iw,assertAnyTypeAnnotation:()=>gb,assertArgumentPlaceholder:()=>Wx,assertArrayExpression:()=>Iv,assertArrayPattern:()=>Py,assertArrayTypeAnnotation:()=>_b,assertArrowFunctionExpression:()=>Fy,assertAssignmentExpression:()=>Lv,assertAssignmentPattern:()=>Ny,assertAwaitExpression:()=>ib,assertBigIntLiteral:()=>ob,assertBinary:()=>hC,assertBinaryExpression:()=>Rv,assertBindExpression:()=>Gx,assertBlock:()=>vC,assertBlockParent:()=>_C,assertBlockStatement:()=>Hv,assertBooleanLiteral:()=>ly,assertBooleanLiteralTypeAnnotation:()=>yb,assertBooleanTypeAnnotation:()=>vb,assertBreakStatement:()=>Uv,assertCallExpression:()=>Wv,assertCatchClause:()=>Gv,assertClass:()=>WC,assertClassAccessorProperty:()=>Kx,assertClassBody:()=>Iy,assertClassDeclaration:()=>Ry,assertClassExpression:()=>Ly,assertClassImplements:()=>xb,assertClassMethod:()=>Xy,assertClassPrivateMethod:()=>fb,assertClassPrivateProperty:()=>db,assertClassProperty:()=>ub,assertCompletionStatement:()=>xC,assertConditional:()=>SC,assertConditionalExpression:()=>Kv,assertContinueStatement:()=>qv,assertDebuggerStatement:()=>Jv,assertDeclaration:()=>jC,assertDeclareClass:()=>Sb,assertDeclareExportAllDeclaration:()=>jb,assertDeclareExportDeclaration:()=>Ab,assertDeclareFunction:()=>Cb,assertDeclareInterface:()=>wb,assertDeclareModule:()=>Tb,assertDeclareModuleExports:()=>Eb,assertDeclareOpaqueType:()=>Ob,assertDeclareTypeAlias:()=>Db,assertDeclareVariable:()=>kb,assertDeclaredPredicate:()=>Mb,assertDecorator:()=>qx,assertDirective:()=>Bv,assertDirectiveLiteral:()=>Vv,assertDoExpression:()=>Jx,assertDoWhileStatement:()=>Yv,assertEmptyStatement:()=>Xv,assertEmptyTypeAnnotation:()=>Ub,assertEnumBody:()=>ew,assertEnumBooleanBody:()=>_x,assertEnumBooleanMember:()=>xx,assertEnumDeclaration:()=>gx,assertEnumDefaultedMember:()=>wx,assertEnumMember:()=>tw,assertEnumNumberBody:()=>vx,assertEnumNumberMember:()=>Sx,assertEnumStringBody:()=>yx,assertEnumStringMember:()=>Cx,assertEnumSymbolBody:()=>bx,assertExistsTypeAnnotation:()=>Nb,assertExportAllDeclaration:()=>zy,assertExportDeclaration:()=>KC,assertExportDefaultDeclaration:()=>By,assertExportDefaultSpecifier:()=>Yx,assertExportNamedDeclaration:()=>Vy,assertExportNamespaceSpecifier:()=>sb,assertExportSpecifier:()=>Hy,assertExpression:()=>mC,assertExpressionStatement:()=>Zv,assertExpressionWrapper:()=>TC,assertFile:()=>Qv,assertFlow:()=>YC,assertFlowBaseAnnotation:()=>ZC,assertFlowDeclaration:()=>QC,assertFlowPredicate:()=>$C,assertFlowType:()=>XC,assertFor:()=>EC,assertForInStatement:()=>$v,assertForOfStatement:()=>Uy,assertForStatement:()=>ey,assertForXStatement:()=>DC,assertFunction:()=>OC,assertFunctionDeclaration:()=>ty,assertFunctionExpression:()=>ny,assertFunctionParameter:()=>MC,assertFunctionParent:()=>kC,assertFunctionTypeAnnotation:()=>Pb,assertFunctionTypeParam:()=>Fb,assertGenericTypeAnnotation:()=>Ib,assertIdentifier:()=>ry,assertIfStatement:()=>iy,assertImmutable:()=>LC,assertImport:()=>ab,assertImportAttribute:()=>hb,assertImportDeclaration:()=>Wy,assertImportDefaultSpecifier:()=>Gy,assertImportExpression:()=>Jy,assertImportNamespaceSpecifier:()=>Ky,assertImportOrExportDeclaration:()=>GC,assertImportSpecifier:()=>qy,assertIndexedAccessType:()=>Tx,assertInferredPredicate:()=>Lb,assertInterfaceDeclaration:()=>zb,assertInterfaceExtends:()=>Rb,assertInterfaceTypeAnnotation:()=>Bb,assertInterpreterDirective:()=>zv,assertIntersectionTypeAnnotation:()=>Vb,assertJSX:()=>nw,assertJSXAttribute:()=>Dx,assertJSXClosingElement:()=>Ox,assertJSXClosingFragment:()=>Vx,assertJSXElement:()=>kx,assertJSXEmptyExpression:()=>Ax,assertJSXExpressionContainer:()=>jx,assertJSXFragment:()=>zx,assertJSXIdentifier:()=>Nx,assertJSXMemberExpression:()=>Px,assertJSXNamespacedName:()=>Fx,assertJSXOpeningElement:()=>Ix,assertJSXOpeningFragment:()=>Bx,assertJSXSpreadAttribute:()=>Lx,assertJSXSpreadChild:()=>Mx,assertJSXText:()=>Rx,assertLVal:()=>PC,assertLabeledStatement:()=>ay,assertLiteral:()=>IC,assertLogicalExpression:()=>dy,assertLoop:()=>CC,assertMemberExpression:()=>fy,assertMetaProperty:()=>Yy,assertMethod:()=>zC,assertMiscellaneous:()=>rw,assertMixedTypeAnnotation:()=>Hb,assertModuleDeclaration:()=>pw,assertModuleExpression:()=>Xx,assertModuleSpecifier:()=>qC,assertNewExpression:()=>py,assertNode:()=>Fv,assertNullLiteral:()=>cy,assertNullLiteralTypeAnnotation:()=>bb,assertNullableTypeAnnotation:()=>Wb,assertNumberLiteral:()=>lw,assertNumberLiteralTypeAnnotation:()=>Gb,assertNumberTypeAnnotation:()=>Kb,assertNumericLiteral:()=>sy,assertObjectExpression:()=>hy,assertObjectMember:()=>BC,assertObjectMethod:()=>gy,assertObjectPattern:()=>Zy,assertObjectProperty:()=>_y,assertObjectTypeAnnotation:()=>qb,assertObjectTypeCallProperty:()=>Yb,assertObjectTypeIndexer:()=>Xb,assertObjectTypeInternalSlot:()=>Jb,assertObjectTypeProperty:()=>Zb,assertObjectTypeSpreadProperty:()=>Qb,assertOpaqueType:()=>$b,assertOptionalCallExpression:()=>lb,assertOptionalIndexedAccessType:()=>Ex,assertOptionalMemberExpression:()=>cb,assertParenthesizedExpression:()=>xy,assertPattern:()=>UC,assertPatternLike:()=>NC,assertPlaceholder:()=>Hx,assertPrivate:()=>JC,assertPrivateName:()=>pb,assertProgram:()=>my,assertProperty:()=>VC,assertPureish:()=>AC,assertQualifiedTypeIdentifier:()=>ex,assertRegExpLiteral:()=>uy,assertRegexLiteral:()=>uw,assertRestElement:()=>vy,assertRestProperty:()=>dw,assertReturnStatement:()=>yy,assertScopable:()=>gC,assertSequenceExpression:()=>by,assertSpreadElement:()=>Qy,assertSpreadProperty:()=>fw,assertStandardized:()=>pC,assertStatement:()=>yC,assertStaticBlock:()=>mb,assertStringLiteral:()=>oy,assertStringLiteralTypeAnnotation:()=>tx,assertStringTypeAnnotation:()=>nx,assertSuper:()=>$y,assertSwitchCase:()=>Sy,assertSwitchStatement:()=>Cy,assertSymbolTypeAnnotation:()=>rx,assertTSAnyKeyword:()=>cS,assertTSArrayType:()=>OS,assertTSAsExpression:()=>YS,assertTSBaseType:()=>cw,assertTSBigIntKeyword:()=>uS,assertTSBooleanKeyword:()=>lS,assertTSCallSignatureDeclaration:()=>rS,assertTSClassImplements:()=>US,assertTSConditionalType:()=>FS,assertTSConstructSignatureDeclaration:()=>iS,assertTSConstructorType:()=>CS,assertTSDeclareFunction:()=>eS,assertTSDeclareMethod:()=>tS,assertTSEntityName:()=>FC,assertTSEnumBody:()=>QS,assertTSEnumDeclaration:()=>$S,assertTSEnumMember:()=>eC,assertTSExportAssignment:()=>sC,assertTSExternalModuleReference:()=>aC,assertTSFunctionType:()=>SS,assertTSImportEqualsDeclaration:()=>iC,assertTSImportType:()=>rC,assertTSIndexSignature:()=>sS,assertTSIndexedAccessType:()=>zS,assertTSInferType:()=>IS,assertTSInstantiationExpression:()=>JS,assertTSInterfaceBody:()=>KS,assertTSInterfaceDeclaration:()=>GS,assertTSInterfaceHeritage:()=>WS,assertTSIntersectionType:()=>PS,assertTSIntrinsicKeyword:()=>dS,assertTSLiteralType:()=>HS,assertTSMappedType:()=>BS,assertTSMethodSignature:()=>oS,assertTSModuleBlock:()=>nC,assertTSModuleDeclaration:()=>tC,assertTSNamedTupleMember:()=>MS,assertTSNamespaceExportDeclaration:()=>cC,assertTSNeverKeyword:()=>fS,assertTSNonNullExpression:()=>oC,assertTSNullKeyword:()=>pS,assertTSNumberKeyword:()=>mS,assertTSObjectKeyword:()=>hS,assertTSOptionalType:()=>AS,assertTSParameterProperty:()=>$x,assertTSParenthesizedType:()=>LS,assertTSPropertySignature:()=>aS,assertTSQualifiedName:()=>nS,assertTSRestType:()=>jS,assertTSSatisfiesExpression:()=>XS,assertTSStringKeyword:()=>gS,assertTSSymbolKeyword:()=>_S,assertTSTemplateLiteralType:()=>VS,assertTSThisType:()=>xS,assertTSTupleType:()=>kS,assertTSType:()=>sw,assertTSTypeAliasDeclaration:()=>qS,assertTSTypeAnnotation:()=>lC,assertTSTypeAssertion:()=>ZS,assertTSTypeElement:()=>ow,assertTSTypeLiteral:()=>DS,assertTSTypeOperator:()=>RS,assertTSTypeParameter:()=>fC,assertTSTypeParameterDeclaration:()=>dC,assertTSTypeParameterInstantiation:()=>uC,assertTSTypePredicate:()=>TS,assertTSTypeQuery:()=>ES,assertTSTypeReference:()=>wS,assertTSUndefinedKeyword:()=>vS,assertTSUnionType:()=>NS,assertTSUnknownKeyword:()=>yS,assertTSVoidKeyword:()=>bS,assertTaggedTemplateExpression:()=>eb,assertTemplateElement:()=>tb,assertTemplateLiteral:()=>nb,assertTerminatorless:()=>bC,assertThisExpression:()=>wy,assertThisTypeAnnotation:()=>ix,assertThrowStatement:()=>Ty,assertTopicReference:()=>Zx,assertTryStatement:()=>Ey,assertTupleTypeAnnotation:()=>ax,assertTypeAlias:()=>sx,assertTypeAnnotation:()=>cx,assertTypeCastExpression:()=>lx,assertTypeParameter:()=>ux,assertTypeParameterDeclaration:()=>dx,assertTypeParameterInstantiation:()=>fx,assertTypeScript:()=>aw,assertTypeofTypeAnnotation:()=>ox,assertUnaryExpression:()=>Dy,assertUnaryLike:()=>HC,assertUnionTypeAnnotation:()=>px,assertUpdateExpression:()=>Oy,assertUserWhitespacable:()=>RC,assertV8IntrinsicIdentifier:()=>Ux,assertVariableDeclaration:()=>ky,assertVariableDeclarator:()=>Ay,assertVariance:()=>mx,assertVoidPattern:()=>Qx,assertVoidTypeAnnotation:()=>hx,assertWhile:()=>wC,assertWhileStatement:()=>jy,assertWithStatement:()=>My,assertYieldExpression:()=>rb,assignmentExpression:()=>bl,assignmentPattern:()=>hu,awaitExpression:()=>Bu,bigIntLiteral:()=>Hu,binaryExpression:()=>xl,bindExpression:()=>Of,blockStatement:()=>Tl,booleanLiteral:()=>Gl,booleanLiteralTypeAnnotation:()=>td,booleanTypeAnnotation:()=>ed,breakStatement:()=>El,buildMatchMemberExpression:()=>$s,buildUndefinedNode:()=>xw,callExpression:()=>Dl,catchClause:()=>Ol,classAccessorProperty:()=>kf,classBody:()=>vu,classDeclaration:()=>bu,classExpression:()=>yu,classImplements:()=>rd,classMethod:()=>Mu,classPrivateMethod:()=>Ju,classPrivateProperty:()=>qu,classProperty:()=>Ku,clone:()=>Ow,cloneDeep:()=>kw,cloneDeepWithoutLoc:()=>Aw,cloneNode:()=>Tw,cloneWithoutLoc:()=>jw,conditionalExpression:()=>kl,continueStatement:()=>Al,createFlowUnionType:()=>_w,createTSUnionType:()=>bw,createTypeAnnotationBasedOnTypeof:()=>mw,createUnionTypeAnnotation:()=>_w,debuggerStatement:()=>jl,declareClass:()=>id,declareExportAllDeclaration:()=>pd,declareExportDeclaration:()=>fd,declareFunction:()=>ad,declareInterface:()=>od,declareModule:()=>sd,declareModuleExports:()=>cd,declareOpaqueType:()=>ud,declareTypeAlias:()=>ld,declareVariable:()=>dd,declaredPredicate:()=>md,decorator:()=>Af,directive:()=>Cl,directiveLiteral:()=>wl,doExpression:()=>jf,doWhileStatement:()=>Ml,emptyStatement:()=>Nl,emptyTypeAnnotation:()=>Td,ensureBlock:()=>RT,enumBooleanBody:()=>$d,enumBooleanMember:()=>rf,enumDeclaration:()=>Qd,enumDefaultedMember:()=>sf,enumNumberBody:()=>ef,enumNumberMember:()=>af,enumStringBody:()=>tf,enumStringMember:()=>of,enumSymbolBody:()=>nf,existsTypeAnnotation:()=>hd,exportAllDeclaration:()=>xu,exportDefaultDeclaration:()=>Su,exportDefaultSpecifier:()=>Mf,exportNamedDeclaration:()=>Cu,exportNamespaceSpecifier:()=>Uu,exportSpecifier:()=>wu,expressionStatement:()=>Pl,file:()=>Fl,forInStatement:()=>Il,forOfStatement:()=>Tu,forStatement:()=>Ll,functionDeclaration:()=>Rl,functionExpression:()=>zl,functionTypeAnnotation:()=>gd,functionTypeParam:()=>_d,genericTypeAnnotation:()=>vd,getAssignmentIdentifiers:()=>aE,getBindingIdentifiers:()=>oE,getFunctionName:()=>uE,getOuterBindingIdentifiers:()=>sE,identifier:()=>H,ifStatement:()=>Bl,import:()=>Vu,importAttribute:()=>Zu,importDeclaration:()=>Eu,importDefaultSpecifier:()=>Du,importExpression:()=>Au,importNamespaceSpecifier:()=>Ou,importSpecifier:()=>ku,indexedAccessType:()=>cf,inferredPredicate:()=>yd,inheritInnerComments:()=>Fw,inheritLeadingComments:()=>Iw,inheritTrailingComments:()=>Lw,inherits:()=>rE,inheritsComments:()=>Rw,interfaceDeclaration:()=>xd,interfaceExtends:()=>bd,interfaceTypeAnnotation:()=>Sd,interpreterDirective:()=>Sl,intersectionTypeAnnotation:()=>Cd,is:()=>T,isAccessor:()=>Vs,isAnyTypeAnnotation:()=>$r,isArgumentPlaceholder:()=>Da,isArrayExpression:()=>yn,isArrayPattern:()=>_r,isArrayTypeAnnotation:()=>ei,isArrowFunctionExpression:()=>vr,isAssignmentExpression:()=>bn,isAssignmentPattern:()=>gr,isAwaitExpression:()=>Vr,isBigIntLiteral:()=>Ur,isBinary:()=>$o,isBinaryExpression:()=>xn,isBindExpression:()=>Oa,isBinding:()=>pE,isBlock:()=>ns,isBlockParent:()=>ts,isBlockScoped:()=>hE,isBlockStatement:()=>Tn,isBooleanLiteral:()=>Kn,isBooleanLiteralTypeAnnotation:()=>ni,isBooleanTypeAnnotation:()=>ti,isBreakStatement:()=>En,isCallExpression:()=>Dn,isCatchClause:()=>On,isClass:()=>Ds,isClassAccessorProperty:()=>ka,isClassBody:()=>yr,isClassDeclaration:()=>xr,isClassExpression:()=>br,isClassImplements:()=>ii,isClassMethod:()=>Nr,isClassPrivateMethod:()=>Yr,isClassPrivateProperty:()=>Jr,isClassProperty:()=>qr,isCompletionStatement:()=>as,isConditional:()=>os,isConditionalExpression:()=>kn,isContinueStatement:()=>An,isDebuggerStatement:()=>jn,isDeclaration:()=>hs,isDeclareClass:()=>ai,isDeclareExportAllDeclaration:()=>mi,isDeclareExportDeclaration:()=>pi,isDeclareFunction:()=>oi,isDeclareInterface:()=>si,isDeclareModule:()=>ci,isDeclareModuleExports:()=>li,isDeclareOpaqueType:()=>di,isDeclareTypeAlias:()=>ui,isDeclareVariable:()=>fi,isDeclaredPredicate:()=>hi,isDecorator:()=>Aa,isDirective:()=>Cn,isDirectiveLiteral:()=>wn,isDoExpression:()=>ja,isDoWhileStatement:()=>Mn,isEmptyStatement:()=>Nn,isEmptyTypeAnnotation:()=>Ei,isEnumBody:()=>Ls,isEnumBooleanBody:()=>ea,isEnumBooleanMember:()=>ia,isEnumDeclaration:()=>$i,isEnumDefaultedMember:()=>sa,isEnumMember:()=>Rs,isEnumNumberBody:()=>ta,isEnumNumberMember:()=>aa,isEnumStringBody:()=>na,isEnumStringMember:()=>oa,isEnumSymbolBody:()=>ra,isExistsTypeAnnotation:()=>gi,isExportAllDeclaration:()=>Sr,isExportDeclaration:()=>ks,isExportDefaultDeclaration:()=>Cr,isExportDefaultSpecifier:()=>Ma,isExportNamedDeclaration:()=>wr,isExportNamespaceSpecifier:()=>Wr,isExportSpecifier:()=>Tr,isExpression:()=>Qo,isExpressionStatement:()=>Pn,isExpressionWrapper:()=>ls,isFile:()=>Fn,isFlow:()=>Ms,isFlowBaseAnnotation:()=>Ps,isFlowDeclaration:()=>Fs,isFlowPredicate:()=>Is,isFlowType:()=>Ns,isFor:()=>us,isForInStatement:()=>In,isForOfStatement:()=>Er,isForStatement:()=>Ln,isForXStatement:()=>ds,isFunction:()=>fs,isFunctionDeclaration:()=>Rn,isFunctionExpression:()=>zn,isFunctionParameter:()=>gs,isFunctionParent:()=>ps,isFunctionTypeAnnotation:()=>_i,isFunctionTypeParam:()=>vi,isGenericTypeAnnotation:()=>yi,isIdentifier:()=>Bn,isIfStatement:()=>Vn,isImmutable:()=>gE,isImport:()=>Hr,isImportAttribute:()=>Qr,isImportDeclaration:()=>Dr,isImportDefaultSpecifier:()=>Or,isImportExpression:()=>jr,isImportNamespaceSpecifier:()=>kr,isImportOrExportDeclaration:()=>Os,isImportSpecifier:()=>Ar,isIndexedAccessType:()=>ca,isInferredPredicate:()=>bi,isInterfaceDeclaration:()=>Si,isInterfaceExtends:()=>xi,isInterfaceTypeAnnotation:()=>Ci,isInterpreterDirective:()=>Sn,isIntersectionTypeAnnotation:()=>wi,isJSX:()=>zs,isJSXAttribute:()=>ua,isJSXClosingElement:()=>da,isJSXClosingFragment:()=>wa,isJSXElement:()=>fa,isJSXEmptyExpression:()=>pa,isJSXExpressionContainer:()=>ma,isJSXFragment:()=>Sa,isJSXIdentifier:()=>ga,isJSXMemberExpression:()=>_a,isJSXNamespacedName:()=>va,isJSXOpeningElement:()=>ya,isJSXOpeningFragment:()=>Ca,isJSXSpreadAttribute:()=>ba,isJSXSpreadChild:()=>ha,isJSXText:()=>xa,isLVal:()=>vs,isLabeledStatement:()=>Hn,isLet:()=>mE,isLiteral:()=>bs,isLogicalExpression:()=>Jn,isLoop:()=>ss,isMemberExpression:()=>Yn,isMetaProperty:()=>Mr,isMethod:()=>Ss,isMiscellaneous:()=>Bs,isMixedTypeAnnotation:()=>Ti,isModuleDeclaration:()=>Xs,isModuleExpression:()=>Na,isModuleSpecifier:()=>As,isNewExpression:()=>Xn,isNode:()=>Pv,isNodesEquivalent:()=>_E,isNullLiteral:()=>Gn,isNullLiteralTypeAnnotation:()=>ri,isNullableTypeAnnotation:()=>Di,isNumberLiteral:()=>Ks,isNumberLiteralTypeAnnotation:()=>Oi,isNumberTypeAnnotation:()=>ki,isNumericLiteral:()=>Wn,isObjectExpression:()=>Qn,isObjectMember:()=>Cs,isObjectMethod:()=>$n,isObjectPattern:()=>Pr,isObjectProperty:()=>er,isObjectTypeAnnotation:()=>Ai,isObjectTypeCallProperty:()=>Mi,isObjectTypeIndexer:()=>Ni,isObjectTypeInternalSlot:()=>ji,isObjectTypeProperty:()=>Pi,isObjectTypeSpreadProperty:()=>Fi,isOpaqueType:()=>Ii,isOptionalCallExpression:()=>Kr,isOptionalIndexedAccessType:()=>la,isOptionalMemberExpression:()=>Gr,isParenthesizedExpression:()=>ir,isPattern:()=>Es,isPatternLike:()=>_s,isPlaceholder:()=>Ta,isPlaceholderType:()=>rc,isPrivate:()=>js,isPrivateName:()=>Xr,isProgram:()=>Zn,isProperty:()=>ws,isPureish:()=>ms,isQualifiedTypeIdentifier:()=>Li,isReferenced:()=>vE,isRegExpLiteral:()=>qn,isRegexLiteral:()=>qs,isRestElement:()=>tr,isRestProperty:()=>Js,isReturnStatement:()=>nr,isScopable:()=>es,isScope:()=>yE,isSequenceExpression:()=>rr,isSpecifierDefault:()=>bE,isSpreadElement:()=>Fr,isSpreadProperty:()=>Ys,isStandardized:()=>Zo,isStatement:()=>rs,isStaticBlock:()=>Zr,isStringLiteral:()=>Un,isStringLiteralTypeAnnotation:()=>Ri,isStringTypeAnnotation:()=>zi,isSuper:()=>Ir,isSwitchCase:()=>ar,isSwitchStatement:()=>or,isSymbolTypeAnnotation:()=>Bi,isTSAnyKeyword:()=>Ga,isTSArrayType:()=>fo,isTSAsExpression:()=>No,isTSBaseType:()=>Gs,isTSBigIntKeyword:()=>qa,isTSBooleanKeyword:()=>Ka,isTSCallSignatureDeclaration:()=>Ba,isTSClassImplements:()=>Do,isTSConditionalType:()=>yo,isTSConstructSignatureDeclaration:()=>Va,isTSConstructorType:()=>oo,isTSDeclareFunction:()=>La,isTSDeclareMethod:()=>Ra,isTSEntityName:()=>ys,isTSEnumBody:()=>Io,isTSEnumDeclaration:()=>Lo,isTSEnumMember:()=>Ro,isTSExportAssignment:()=>Go,isTSExternalModuleReference:()=>Uo,isTSFunctionType:()=>ao,isTSImportEqualsDeclaration:()=>Ho,isTSImportType:()=>Vo,isTSIndexSignature:()=>Wa,isTSIndexedAccessType:()=>Co,isTSInferType:()=>bo,isTSInstantiationExpression:()=>Mo,isTSInterfaceBody:()=>Ao,isTSInterfaceDeclaration:()=>ko,isTSInterfaceHeritage:()=>Oo,isTSIntersectionType:()=>vo,isTSIntrinsicKeyword:()=>Ja,isTSLiteralType:()=>Eo,isTSMappedType:()=>wo,isTSMethodSignature:()=>Ua,isTSModuleBlock:()=>Bo,isTSModuleDeclaration:()=>zo,isTSNamedTupleMember:()=>go,isTSNamespaceExportDeclaration:()=>Ko,isTSNeverKeyword:()=>Ya,isTSNonNullExpression:()=>Wo,isTSNullKeyword:()=>Xa,isTSNumberKeyword:()=>Za,isTSObjectKeyword:()=>Qa,isTSOptionalType:()=>mo,isTSParameterProperty:()=>Ia,isTSParenthesizedType:()=>xo,isTSPropertySignature:()=>Ha,isTSQualifiedName:()=>za,isTSRestType:()=>ho,isTSSatisfiesExpression:()=>Po,isTSStringKeyword:()=>$a,isTSSymbolKeyword:()=>eo,isTSTemplateLiteralType:()=>To,isTSThisType:()=>io,isTSTupleType:()=>po,isTSType:()=>Ws,isTSTypeAliasDeclaration:()=>jo,isTSTypeAnnotation:()=>qo,isTSTypeAssertion:()=>Fo,isTSTypeElement:()=>Us,isTSTypeLiteral:()=>uo,isTSTypeOperator:()=>So,isTSTypeParameter:()=>Xo,isTSTypeParameterDeclaration:()=>Yo,isTSTypeParameterInstantiation:()=>Jo,isTSTypePredicate:()=>co,isTSTypeQuery:()=>lo,isTSTypeReference:()=>so,isTSUndefinedKeyword:()=>to,isTSUnionType:()=>_o,isTSUnknownKeyword:()=>no,isTSVoidKeyword:()=>ro,isTaggedTemplateExpression:()=>Lr,isTemplateElement:()=>Rr,isTemplateLiteral:()=>zr,isTerminatorless:()=>is,isThisExpression:()=>sr,isThisTypeAnnotation:()=>Vi,isThrowStatement:()=>cr,isTopicReference:()=>Pa,isTryStatement:()=>lr,isTupleTypeAnnotation:()=>Hi,isType:()=>nc,isTypeAlias:()=>Wi,isTypeAnnotation:()=>Gi,isTypeCastExpression:()=>Ki,isTypeParameter:()=>qi,isTypeParameterDeclaration:()=>Ji,isTypeParameterInstantiation:()=>Yi,isTypeScript:()=>Hs,isTypeofTypeAnnotation:()=>Ui,isUnaryExpression:()=>ur,isUnaryLike:()=>Ts,isUnionTypeAnnotation:()=>Xi,isUpdateExpression:()=>dr,isUserWhitespacable:()=>xs,isV8IntrinsicIdentifier:()=>Ea,isValidES3Identifier:()=>SE,isValidIdentifier:()=>ic,isVar:()=>CE,isVariableDeclaration:()=>fr,isVariableDeclarator:()=>pr,isVariance:()=>Zi,isVoidPattern:()=>Fa,isVoidTypeAnnotation:()=>Qi,isWhile:()=>cs,isWhileStatement:()=>mr,isWithStatement:()=>hr,isYieldExpression:()=>Br,jsxAttribute:()=>uf,jsxClosingElement:()=>df,jsxClosingFragment:()=>wf,jsxElement:()=>ff,jsxEmptyExpression:()=>pf,jsxExpressionContainer:()=>mf,jsxFragment:()=>Sf,jsxIdentifier:()=>gf,jsxMemberExpression:()=>_f,jsxNamespacedName:()=>vf,jsxOpeningElement:()=>yf,jsxOpeningFragment:()=>Cf,jsxSpreadAttribute:()=>bf,jsxSpreadChild:()=>hf,jsxText:()=>xf,labeledStatement:()=>Vl,logicalExpression:()=>ql,matchesPattern:()=>Qs,memberExpression:()=>Jl,metaProperty:()=>ju,mixedTypeAnnotation:()=>wd,moduleExpression:()=>Nf,newExpression:()=>Yl,nullLiteral:()=>Wl,nullLiteralTypeAnnotation:()=>nd,nullableTypeAnnotation:()=>Ed,numberLiteral:()=>Xp,numberLiteralTypeAnnotation:()=>Dd,numberTypeAnnotation:()=>Od,numericLiteral:()=>Ul,objectExpression:()=>Zl,objectMethod:()=>Ql,objectPattern:()=>Nu,objectProperty:()=>$l,objectTypeAnnotation:()=>kd,objectTypeCallProperty:()=>jd,objectTypeIndexer:()=>Md,objectTypeInternalSlot:()=>Ad,objectTypeProperty:()=>Nd,objectTypeSpreadProperty:()=>Pd,opaqueType:()=>Fd,optionalCallExpression:()=>Gu,optionalIndexedAccessType:()=>lf,optionalMemberExpression:()=>Wu,parenthesizedExpression:()=>ru,placeholder:()=>Tf,prependToMemberExpression:()=>iE,privateName:()=>Yu,program:()=>Xl,qualifiedTypeIdentifier:()=>Id,react:()=>wE,regExpLiteral:()=>Kl,regexLiteral:()=>Zp,removeComments:()=>zw,removeProperties:()=>JT,removePropertiesDeep:()=>YT,removeTypeDuplicates:()=>gw,restElement:()=>eu,restProperty:()=>Qp,returnStatement:()=>tu,sequenceExpression:()=>nu,shallowEqual:()=>C,spreadElement:()=>Pu,spreadProperty:()=>$p,staticBlock:()=>Xu,stringLiteral:()=>Hl,stringLiteralTypeAnnotation:()=>Ld,stringTypeAnnotation:()=>Rd,super:()=>Fu,switchCase:()=>iu,switchStatement:()=>au,symbolTypeAnnotation:()=>zd,taggedTemplateExpression:()=>Iu,templateElement:()=>Lu,templateLiteral:()=>Ru,thisExpression:()=>ou,thisTypeAnnotation:()=>Bd,throwStatement:()=>su,toBindingIdentifierName:()=>BT,toBlock:()=>LT,toComputedKey:()=>VT,toExpression:()=>HT,toIdentifier:()=>zT,toKeyAlias:()=>XT,toStatement:()=>ZT,topicReference:()=>Pf,traverse:()=>dE,traverseFast:()=>GT,tryStatement:()=>cu,tsAnyKeyword:()=>Gf,tsArrayType:()=>dp,tsAsExpression:()=>Mp,tsBigIntKeyword:()=>qf,tsBooleanKeyword:()=>Kf,tsCallSignatureDeclaration:()=>Bf,tsClassImplements:()=>Ep,tsConditionalType:()=>vp,tsConstructSignatureDeclaration:()=>Vf,tsConstructorType:()=>op,tsDeclareFunction:()=>Lf,tsDeclareMethod:()=>Rf,tsEnumBody:()=>Fp,tsEnumDeclaration:()=>Ip,tsEnumMember:()=>Lp,tsExportAssignment:()=>Wp,tsExternalModuleReference:()=>Hp,tsFunctionType:()=>ap,tsImportEqualsDeclaration:()=>Vp,tsImportType:()=>Bp,tsIndexSignature:()=>Wf,tsIndexedAccessType:()=>Sp,tsInferType:()=>yp,tsInstantiationExpression:()=>jp,tsInterfaceBody:()=>kp,tsInterfaceDeclaration:()=>Op,tsInterfaceHeritage:()=>Dp,tsIntersectionType:()=>_p,tsIntrinsicKeyword:()=>Jf,tsLiteralType:()=>Tp,tsMappedType:()=>Cp,tsMethodSignature:()=>Uf,tsModuleBlock:()=>zp,tsModuleDeclaration:()=>Rp,tsNamedTupleMember:()=>hp,tsNamespaceExportDeclaration:()=>Gp,tsNeverKeyword:()=>Yf,tsNonNullExpression:()=>Up,tsNullKeyword:()=>Xf,tsNumberKeyword:()=>Zf,tsObjectKeyword:()=>Qf,tsOptionalType:()=>pp,tsParameterProperty:()=>If,tsParenthesizedType:()=>bp,tsPropertySignature:()=>Hf,tsQualifiedName:()=>zf,tsRestType:()=>mp,tsSatisfiesExpression:()=>Np,tsStringKeyword:()=>$f,tsSymbolKeyword:()=>ep,tsTemplateLiteralType:()=>wp,tsThisType:()=>ip,tsTupleType:()=>fp,tsTypeAliasDeclaration:()=>Ap,tsTypeAnnotation:()=>Kp,tsTypeAssertion:()=>Pp,tsTypeLiteral:()=>up,tsTypeOperator:()=>xp,tsTypeParameter:()=>Yp,tsTypeParameterDeclaration:()=>Jp,tsTypeParameterInstantiation:()=>qp,tsTypePredicate:()=>cp,tsTypeQuery:()=>lp,tsTypeReference:()=>sp,tsUndefinedKeyword:()=>tp,tsUnionType:()=>gp,tsUnknownKeyword:()=>np,tsVoidKeyword:()=>rp,tupleTypeAnnotation:()=>Vd,typeAlias:()=>Ud,typeAnnotation:()=>Wd,typeCastExpression:()=>Gd,typeParameter:()=>Kd,typeParameterDeclaration:()=>qd,typeParameterInstantiation:()=>Jd,typeofTypeAnnotation:()=>Hd,unaryExpression:()=>lu,unionTypeAnnotation:()=>Yd,updateExpression:()=>uu,v8IntrinsicIdentifier:()=>Ef,validate:()=>hl,valueToNode:()=>tE,variableDeclaration:()=>du,variableDeclarator:()=>fu,variance:()=>Xd,voidPattern:()=>Ff,voidTypeAnnotation:()=>Zd,whileStatement:()=>pu,withStatement:()=>mu,yieldExpression:()=>zu});function C(e,t){let n=Object.keys(t);for(let r of n)if(e[r]!==t[r])return!1;return!0}const _n=new Set;function w(e,t,n=``,r=e){if(_n.has(r))return;_n.add(r);let{internal:i,trace:a}=vn(1,2);i||console.warn(`${n}\`${e}\` has been deprecated, please migrate to \`${t}\`\n${a}`)}function vn(e,t){let{stackTraceLimit:n,prepareStackTrace:r}=Error,i;if(Error.stackTraceLimit=1+e+t,Error.prepareStackTrace=function(e,t){i=t},Error().stack,Error.stackTraceLimit=n,Error.prepareStackTrace=r,!i)return{internal:!1,trace:``};let a=i.slice(1+e,1+e+t);return{internal:/[\\/]@babel[\\/]/.test(a[1].getFileName()),trace:a.map(e=>` at ${e}`).join(`
|
|
4
|
+
`)}}function yn(e,t){return!e||e.type!==`ArrayExpression`?!1:t==null||C(e,t)}function bn(e,t){return!e||e.type!==`AssignmentExpression`?!1:t==null||C(e,t)}function xn(e,t){return!e||e.type!==`BinaryExpression`?!1:t==null||C(e,t)}function Sn(e,t){return!e||e.type!==`InterpreterDirective`?!1:t==null||C(e,t)}function Cn(e,t){return!e||e.type!==`Directive`?!1:t==null||C(e,t)}function wn(e,t){return!e||e.type!==`DirectiveLiteral`?!1:t==null||C(e,t)}function Tn(e,t){return!e||e.type!==`BlockStatement`?!1:t==null||C(e,t)}function En(e,t){return!e||e.type!==`BreakStatement`?!1:t==null||C(e,t)}function Dn(e,t){return!e||e.type!==`CallExpression`?!1:t==null||C(e,t)}function On(e,t){return!e||e.type!==`CatchClause`?!1:t==null||C(e,t)}function kn(e,t){return!e||e.type!==`ConditionalExpression`?!1:t==null||C(e,t)}function An(e,t){return!e||e.type!==`ContinueStatement`?!1:t==null||C(e,t)}function jn(e,t){return!e||e.type!==`DebuggerStatement`?!1:t==null||C(e,t)}function Mn(e,t){return!e||e.type!==`DoWhileStatement`?!1:t==null||C(e,t)}function Nn(e,t){return!e||e.type!==`EmptyStatement`?!1:t==null||C(e,t)}function Pn(e,t){return!e||e.type!==`ExpressionStatement`?!1:t==null||C(e,t)}function Fn(e,t){return!e||e.type!==`File`?!1:t==null||C(e,t)}function In(e,t){return!e||e.type!==`ForInStatement`?!1:t==null||C(e,t)}function Ln(e,t){return!e||e.type!==`ForStatement`?!1:t==null||C(e,t)}function Rn(e,t){return!e||e.type!==`FunctionDeclaration`?!1:t==null||C(e,t)}function zn(e,t){return!e||e.type!==`FunctionExpression`?!1:t==null||C(e,t)}function Bn(e,t){return!e||e.type!==`Identifier`?!1:t==null||C(e,t)}function Vn(e,t){return!e||e.type!==`IfStatement`?!1:t==null||C(e,t)}function Hn(e,t){return!e||e.type!==`LabeledStatement`?!1:t==null||C(e,t)}function Un(e,t){return!e||e.type!==`StringLiteral`?!1:t==null||C(e,t)}function Wn(e,t){return!e||e.type!==`NumericLiteral`?!1:t==null||C(e,t)}function Gn(e,t){return!e||e.type!==`NullLiteral`?!1:t==null||C(e,t)}function Kn(e,t){return!e||e.type!==`BooleanLiteral`?!1:t==null||C(e,t)}function qn(e,t){return!e||e.type!==`RegExpLiteral`?!1:t==null||C(e,t)}function Jn(e,t){return!e||e.type!==`LogicalExpression`?!1:t==null||C(e,t)}function Yn(e,t){return!e||e.type!==`MemberExpression`?!1:t==null||C(e,t)}function Xn(e,t){return!e||e.type!==`NewExpression`?!1:t==null||C(e,t)}function Zn(e,t){return!e||e.type!==`Program`?!1:t==null||C(e,t)}function Qn(e,t){return!e||e.type!==`ObjectExpression`?!1:t==null||C(e,t)}function $n(e,t){return!e||e.type!==`ObjectMethod`?!1:t==null||C(e,t)}function er(e,t){return!e||e.type!==`ObjectProperty`?!1:t==null||C(e,t)}function tr(e,t){return!e||e.type!==`RestElement`?!1:t==null||C(e,t)}function nr(e,t){return!e||e.type!==`ReturnStatement`?!1:t==null||C(e,t)}function rr(e,t){return!e||e.type!==`SequenceExpression`?!1:t==null||C(e,t)}function ir(e,t){return!e||e.type!==`ParenthesizedExpression`?!1:t==null||C(e,t)}function ar(e,t){return!e||e.type!==`SwitchCase`?!1:t==null||C(e,t)}function or(e,t){return!e||e.type!==`SwitchStatement`?!1:t==null||C(e,t)}function sr(e,t){return!e||e.type!==`ThisExpression`?!1:t==null||C(e,t)}function cr(e,t){return!e||e.type!==`ThrowStatement`?!1:t==null||C(e,t)}function lr(e,t){return!e||e.type!==`TryStatement`?!1:t==null||C(e,t)}function ur(e,t){return!e||e.type!==`UnaryExpression`?!1:t==null||C(e,t)}function dr(e,t){return!e||e.type!==`UpdateExpression`?!1:t==null||C(e,t)}function fr(e,t){return!e||e.type!==`VariableDeclaration`?!1:t==null||C(e,t)}function pr(e,t){return!e||e.type!==`VariableDeclarator`?!1:t==null||C(e,t)}function mr(e,t){return!e||e.type!==`WhileStatement`?!1:t==null||C(e,t)}function hr(e,t){return!e||e.type!==`WithStatement`?!1:t==null||C(e,t)}function gr(e,t){return!e||e.type!==`AssignmentPattern`?!1:t==null||C(e,t)}function _r(e,t){return!e||e.type!==`ArrayPattern`?!1:t==null||C(e,t)}function vr(e,t){return!e||e.type!==`ArrowFunctionExpression`?!1:t==null||C(e,t)}function yr(e,t){return!e||e.type!==`ClassBody`?!1:t==null||C(e,t)}function br(e,t){return!e||e.type!==`ClassExpression`?!1:t==null||C(e,t)}function xr(e,t){return!e||e.type!==`ClassDeclaration`?!1:t==null||C(e,t)}function Sr(e,t){return!e||e.type!==`ExportAllDeclaration`?!1:t==null||C(e,t)}function Cr(e,t){return!e||e.type!==`ExportDefaultDeclaration`?!1:t==null||C(e,t)}function wr(e,t){return!e||e.type!==`ExportNamedDeclaration`?!1:t==null||C(e,t)}function Tr(e,t){return!e||e.type!==`ExportSpecifier`?!1:t==null||C(e,t)}function Er(e,t){return!e||e.type!==`ForOfStatement`?!1:t==null||C(e,t)}function Dr(e,t){return!e||e.type!==`ImportDeclaration`?!1:t==null||C(e,t)}function Or(e,t){return!e||e.type!==`ImportDefaultSpecifier`?!1:t==null||C(e,t)}function kr(e,t){return!e||e.type!==`ImportNamespaceSpecifier`?!1:t==null||C(e,t)}function Ar(e,t){return!e||e.type!==`ImportSpecifier`?!1:t==null||C(e,t)}function jr(e,t){return!e||e.type!==`ImportExpression`?!1:t==null||C(e,t)}function Mr(e,t){return!e||e.type!==`MetaProperty`?!1:t==null||C(e,t)}function Nr(e,t){return!e||e.type!==`ClassMethod`?!1:t==null||C(e,t)}function Pr(e,t){return!e||e.type!==`ObjectPattern`?!1:t==null||C(e,t)}function Fr(e,t){return!e||e.type!==`SpreadElement`?!1:t==null||C(e,t)}function Ir(e,t){return!e||e.type!==`Super`?!1:t==null||C(e,t)}function Lr(e,t){return!e||e.type!==`TaggedTemplateExpression`?!1:t==null||C(e,t)}function Rr(e,t){return!e||e.type!==`TemplateElement`?!1:t==null||C(e,t)}function zr(e,t){return!e||e.type!==`TemplateLiteral`?!1:t==null||C(e,t)}function Br(e,t){return!e||e.type!==`YieldExpression`?!1:t==null||C(e,t)}function Vr(e,t){return!e||e.type!==`AwaitExpression`?!1:t==null||C(e,t)}function Hr(e,t){return!e||e.type!==`Import`?!1:t==null||C(e,t)}function Ur(e,t){return!e||e.type!==`BigIntLiteral`?!1:t==null||C(e,t)}function Wr(e,t){return!e||e.type!==`ExportNamespaceSpecifier`?!1:t==null||C(e,t)}function Gr(e,t){return!e||e.type!==`OptionalMemberExpression`?!1:t==null||C(e,t)}function Kr(e,t){return!e||e.type!==`OptionalCallExpression`?!1:t==null||C(e,t)}function qr(e,t){return!e||e.type!==`ClassProperty`?!1:t==null||C(e,t)}function Jr(e,t){return!e||e.type!==`ClassPrivateProperty`?!1:t==null||C(e,t)}function Yr(e,t){return!e||e.type!==`ClassPrivateMethod`?!1:t==null||C(e,t)}function Xr(e,t){return!e||e.type!==`PrivateName`?!1:t==null||C(e,t)}function Zr(e,t){return!e||e.type!==`StaticBlock`?!1:t==null||C(e,t)}function Qr(e,t){return!e||e.type!==`ImportAttribute`?!1:t==null||C(e,t)}function $r(e,t){return!e||e.type!==`AnyTypeAnnotation`?!1:t==null||C(e,t)}function ei(e,t){return!e||e.type!==`ArrayTypeAnnotation`?!1:t==null||C(e,t)}function ti(e,t){return!e||e.type!==`BooleanTypeAnnotation`?!1:t==null||C(e,t)}function ni(e,t){return!e||e.type!==`BooleanLiteralTypeAnnotation`?!1:t==null||C(e,t)}function ri(e,t){return!e||e.type!==`NullLiteralTypeAnnotation`?!1:t==null||C(e,t)}function ii(e,t){return!e||e.type!==`ClassImplements`?!1:t==null||C(e,t)}function ai(e,t){return!e||e.type!==`DeclareClass`?!1:t==null||C(e,t)}function oi(e,t){return!e||e.type!==`DeclareFunction`?!1:t==null||C(e,t)}function si(e,t){return!e||e.type!==`DeclareInterface`?!1:t==null||C(e,t)}function ci(e,t){return!e||e.type!==`DeclareModule`?!1:t==null||C(e,t)}function li(e,t){return!e||e.type!==`DeclareModuleExports`?!1:t==null||C(e,t)}function ui(e,t){return!e||e.type!==`DeclareTypeAlias`?!1:t==null||C(e,t)}function di(e,t){return!e||e.type!==`DeclareOpaqueType`?!1:t==null||C(e,t)}function fi(e,t){return!e||e.type!==`DeclareVariable`?!1:t==null||C(e,t)}function pi(e,t){return!e||e.type!==`DeclareExportDeclaration`?!1:t==null||C(e,t)}function mi(e,t){return!e||e.type!==`DeclareExportAllDeclaration`?!1:t==null||C(e,t)}function hi(e,t){return!e||e.type!==`DeclaredPredicate`?!1:t==null||C(e,t)}function gi(e,t){return!e||e.type!==`ExistsTypeAnnotation`?!1:t==null||C(e,t)}function _i(e,t){return!e||e.type!==`FunctionTypeAnnotation`?!1:t==null||C(e,t)}function vi(e,t){return!e||e.type!==`FunctionTypeParam`?!1:t==null||C(e,t)}function yi(e,t){return!e||e.type!==`GenericTypeAnnotation`?!1:t==null||C(e,t)}function bi(e,t){return!e||e.type!==`InferredPredicate`?!1:t==null||C(e,t)}function xi(e,t){return!e||e.type!==`InterfaceExtends`?!1:t==null||C(e,t)}function Si(e,t){return!e||e.type!==`InterfaceDeclaration`?!1:t==null||C(e,t)}function Ci(e,t){return!e||e.type!==`InterfaceTypeAnnotation`?!1:t==null||C(e,t)}function wi(e,t){return!e||e.type!==`IntersectionTypeAnnotation`?!1:t==null||C(e,t)}function Ti(e,t){return!e||e.type!==`MixedTypeAnnotation`?!1:t==null||C(e,t)}function Ei(e,t){return!e||e.type!==`EmptyTypeAnnotation`?!1:t==null||C(e,t)}function Di(e,t){return!e||e.type!==`NullableTypeAnnotation`?!1:t==null||C(e,t)}function Oi(e,t){return!e||e.type!==`NumberLiteralTypeAnnotation`?!1:t==null||C(e,t)}function ki(e,t){return!e||e.type!==`NumberTypeAnnotation`?!1:t==null||C(e,t)}function Ai(e,t){return!e||e.type!==`ObjectTypeAnnotation`?!1:t==null||C(e,t)}function ji(e,t){return!e||e.type!==`ObjectTypeInternalSlot`?!1:t==null||C(e,t)}function Mi(e,t){return!e||e.type!==`ObjectTypeCallProperty`?!1:t==null||C(e,t)}function Ni(e,t){return!e||e.type!==`ObjectTypeIndexer`?!1:t==null||C(e,t)}function Pi(e,t){return!e||e.type!==`ObjectTypeProperty`?!1:t==null||C(e,t)}function Fi(e,t){return!e||e.type!==`ObjectTypeSpreadProperty`?!1:t==null||C(e,t)}function Ii(e,t){return!e||e.type!==`OpaqueType`?!1:t==null||C(e,t)}function Li(e,t){return!e||e.type!==`QualifiedTypeIdentifier`?!1:t==null||C(e,t)}function Ri(e,t){return!e||e.type!==`StringLiteralTypeAnnotation`?!1:t==null||C(e,t)}function zi(e,t){return!e||e.type!==`StringTypeAnnotation`?!1:t==null||C(e,t)}function Bi(e,t){return!e||e.type!==`SymbolTypeAnnotation`?!1:t==null||C(e,t)}function Vi(e,t){return!e||e.type!==`ThisTypeAnnotation`?!1:t==null||C(e,t)}function Hi(e,t){return!e||e.type!==`TupleTypeAnnotation`?!1:t==null||C(e,t)}function Ui(e,t){return!e||e.type!==`TypeofTypeAnnotation`?!1:t==null||C(e,t)}function Wi(e,t){return!e||e.type!==`TypeAlias`?!1:t==null||C(e,t)}function Gi(e,t){return!e||e.type!==`TypeAnnotation`?!1:t==null||C(e,t)}function Ki(e,t){return!e||e.type!==`TypeCastExpression`?!1:t==null||C(e,t)}function qi(e,t){return!e||e.type!==`TypeParameter`?!1:t==null||C(e,t)}function Ji(e,t){return!e||e.type!==`TypeParameterDeclaration`?!1:t==null||C(e,t)}function Yi(e,t){return!e||e.type!==`TypeParameterInstantiation`?!1:t==null||C(e,t)}function Xi(e,t){return!e||e.type!==`UnionTypeAnnotation`?!1:t==null||C(e,t)}function Zi(e,t){return!e||e.type!==`Variance`?!1:t==null||C(e,t)}function Qi(e,t){return!e||e.type!==`VoidTypeAnnotation`?!1:t==null||C(e,t)}function $i(e,t){return!e||e.type!==`EnumDeclaration`?!1:t==null||C(e,t)}function ea(e,t){return!e||e.type!==`EnumBooleanBody`?!1:t==null||C(e,t)}function ta(e,t){return!e||e.type!==`EnumNumberBody`?!1:t==null||C(e,t)}function na(e,t){return!e||e.type!==`EnumStringBody`?!1:t==null||C(e,t)}function ra(e,t){return!e||e.type!==`EnumSymbolBody`?!1:t==null||C(e,t)}function ia(e,t){return!e||e.type!==`EnumBooleanMember`?!1:t==null||C(e,t)}function aa(e,t){return!e||e.type!==`EnumNumberMember`?!1:t==null||C(e,t)}function oa(e,t){return!e||e.type!==`EnumStringMember`?!1:t==null||C(e,t)}function sa(e,t){return!e||e.type!==`EnumDefaultedMember`?!1:t==null||C(e,t)}function ca(e,t){return!e||e.type!==`IndexedAccessType`?!1:t==null||C(e,t)}function la(e,t){return!e||e.type!==`OptionalIndexedAccessType`?!1:t==null||C(e,t)}function ua(e,t){return!e||e.type!==`JSXAttribute`?!1:t==null||C(e,t)}function da(e,t){return!e||e.type!==`JSXClosingElement`?!1:t==null||C(e,t)}function fa(e,t){return!e||e.type!==`JSXElement`?!1:t==null||C(e,t)}function pa(e,t){return!e||e.type!==`JSXEmptyExpression`?!1:t==null||C(e,t)}function ma(e,t){return!e||e.type!==`JSXExpressionContainer`?!1:t==null||C(e,t)}function ha(e,t){return!e||e.type!==`JSXSpreadChild`?!1:t==null||C(e,t)}function ga(e,t){return!e||e.type!==`JSXIdentifier`?!1:t==null||C(e,t)}function _a(e,t){return!e||e.type!==`JSXMemberExpression`?!1:t==null||C(e,t)}function va(e,t){return!e||e.type!==`JSXNamespacedName`?!1:t==null||C(e,t)}function ya(e,t){return!e||e.type!==`JSXOpeningElement`?!1:t==null||C(e,t)}function ba(e,t){return!e||e.type!==`JSXSpreadAttribute`?!1:t==null||C(e,t)}function xa(e,t){return!e||e.type!==`JSXText`?!1:t==null||C(e,t)}function Sa(e,t){return!e||e.type!==`JSXFragment`?!1:t==null||C(e,t)}function Ca(e,t){return!e||e.type!==`JSXOpeningFragment`?!1:t==null||C(e,t)}function wa(e,t){return!e||e.type!==`JSXClosingFragment`?!1:t==null||C(e,t)}function Ta(e,t){return!e||e.type!==`Placeholder`?!1:t==null||C(e,t)}function Ea(e,t){return!e||e.type!==`V8IntrinsicIdentifier`?!1:t==null||C(e,t)}function Da(e,t){return!e||e.type!==`ArgumentPlaceholder`?!1:t==null||C(e,t)}function Oa(e,t){return!e||e.type!==`BindExpression`?!1:t==null||C(e,t)}function ka(e,t){return!e||e.type!==`ClassAccessorProperty`?!1:t==null||C(e,t)}function Aa(e,t){return!e||e.type!==`Decorator`?!1:t==null||C(e,t)}function ja(e,t){return!e||e.type!==`DoExpression`?!1:t==null||C(e,t)}function Ma(e,t){return!e||e.type!==`ExportDefaultSpecifier`?!1:t==null||C(e,t)}function Na(e,t){return!e||e.type!==`ModuleExpression`?!1:t==null||C(e,t)}function Pa(e,t){return!e||e.type!==`TopicReference`?!1:t==null||C(e,t)}function Fa(e,t){return!e||e.type!==`VoidPattern`?!1:t==null||C(e,t)}function Ia(e,t){return!e||e.type!==`TSParameterProperty`?!1:t==null||C(e,t)}function La(e,t){return!e||e.type!==`TSDeclareFunction`?!1:t==null||C(e,t)}function Ra(e,t){return!e||e.type!==`TSDeclareMethod`?!1:t==null||C(e,t)}function za(e,t){return!e||e.type!==`TSQualifiedName`?!1:t==null||C(e,t)}function Ba(e,t){return!e||e.type!==`TSCallSignatureDeclaration`?!1:t==null||C(e,t)}function Va(e,t){return!e||e.type!==`TSConstructSignatureDeclaration`?!1:t==null||C(e,t)}function Ha(e,t){return!e||e.type!==`TSPropertySignature`?!1:t==null||C(e,t)}function Ua(e,t){return!e||e.type!==`TSMethodSignature`?!1:t==null||C(e,t)}function Wa(e,t){return!e||e.type!==`TSIndexSignature`?!1:t==null||C(e,t)}function Ga(e,t){return!e||e.type!==`TSAnyKeyword`?!1:t==null||C(e,t)}function Ka(e,t){return!e||e.type!==`TSBooleanKeyword`?!1:t==null||C(e,t)}function qa(e,t){return!e||e.type!==`TSBigIntKeyword`?!1:t==null||C(e,t)}function Ja(e,t){return!e||e.type!==`TSIntrinsicKeyword`?!1:t==null||C(e,t)}function Ya(e,t){return!e||e.type!==`TSNeverKeyword`?!1:t==null||C(e,t)}function Xa(e,t){return!e||e.type!==`TSNullKeyword`?!1:t==null||C(e,t)}function Za(e,t){return!e||e.type!==`TSNumberKeyword`?!1:t==null||C(e,t)}function Qa(e,t){return!e||e.type!==`TSObjectKeyword`?!1:t==null||C(e,t)}function $a(e,t){return!e||e.type!==`TSStringKeyword`?!1:t==null||C(e,t)}function eo(e,t){return!e||e.type!==`TSSymbolKeyword`?!1:t==null||C(e,t)}function to(e,t){return!e||e.type!==`TSUndefinedKeyword`?!1:t==null||C(e,t)}function no(e,t){return!e||e.type!==`TSUnknownKeyword`?!1:t==null||C(e,t)}function ro(e,t){return!e||e.type!==`TSVoidKeyword`?!1:t==null||C(e,t)}function io(e,t){return!e||e.type!==`TSThisType`?!1:t==null||C(e,t)}function ao(e,t){return!e||e.type!==`TSFunctionType`?!1:t==null||C(e,t)}function oo(e,t){return!e||e.type!==`TSConstructorType`?!1:t==null||C(e,t)}function so(e,t){return!e||e.type!==`TSTypeReference`?!1:t==null||C(e,t)}function co(e,t){return!e||e.type!==`TSTypePredicate`?!1:t==null||C(e,t)}function lo(e,t){return!e||e.type!==`TSTypeQuery`?!1:t==null||C(e,t)}function uo(e,t){return!e||e.type!==`TSTypeLiteral`?!1:t==null||C(e,t)}function fo(e,t){return!e||e.type!==`TSArrayType`?!1:t==null||C(e,t)}function po(e,t){return!e||e.type!==`TSTupleType`?!1:t==null||C(e,t)}function mo(e,t){return!e||e.type!==`TSOptionalType`?!1:t==null||C(e,t)}function ho(e,t){return!e||e.type!==`TSRestType`?!1:t==null||C(e,t)}function go(e,t){return!e||e.type!==`TSNamedTupleMember`?!1:t==null||C(e,t)}function _o(e,t){return!e||e.type!==`TSUnionType`?!1:t==null||C(e,t)}function vo(e,t){return!e||e.type!==`TSIntersectionType`?!1:t==null||C(e,t)}function yo(e,t){return!e||e.type!==`TSConditionalType`?!1:t==null||C(e,t)}function bo(e,t){return!e||e.type!==`TSInferType`?!1:t==null||C(e,t)}function xo(e,t){return!e||e.type!==`TSParenthesizedType`?!1:t==null||C(e,t)}function So(e,t){return!e||e.type!==`TSTypeOperator`?!1:t==null||C(e,t)}function Co(e,t){return!e||e.type!==`TSIndexedAccessType`?!1:t==null||C(e,t)}function wo(e,t){return!e||e.type!==`TSMappedType`?!1:t==null||C(e,t)}function To(e,t){return!e||e.type!==`TSTemplateLiteralType`?!1:t==null||C(e,t)}function Eo(e,t){return!e||e.type!==`TSLiteralType`?!1:t==null||C(e,t)}function Do(e,t){return!e||e.type!==`TSClassImplements`?!1:t==null||C(e,t)}function Oo(e,t){return!e||e.type!==`TSInterfaceHeritage`?!1:t==null||C(e,t)}function ko(e,t){return!e||e.type!==`TSInterfaceDeclaration`?!1:t==null||C(e,t)}function Ao(e,t){return!e||e.type!==`TSInterfaceBody`?!1:t==null||C(e,t)}function jo(e,t){return!e||e.type!==`TSTypeAliasDeclaration`?!1:t==null||C(e,t)}function Mo(e,t){return!e||e.type!==`TSInstantiationExpression`?!1:t==null||C(e,t)}function No(e,t){return!e||e.type!==`TSAsExpression`?!1:t==null||C(e,t)}function Po(e,t){return!e||e.type!==`TSSatisfiesExpression`?!1:t==null||C(e,t)}function Fo(e,t){return!e||e.type!==`TSTypeAssertion`?!1:t==null||C(e,t)}function Io(e,t){return!e||e.type!==`TSEnumBody`?!1:t==null||C(e,t)}function Lo(e,t){return!e||e.type!==`TSEnumDeclaration`?!1:t==null||C(e,t)}function Ro(e,t){return!e||e.type!==`TSEnumMember`?!1:t==null||C(e,t)}function zo(e,t){return!e||e.type!==`TSModuleDeclaration`?!1:t==null||C(e,t)}function Bo(e,t){return!e||e.type!==`TSModuleBlock`?!1:t==null||C(e,t)}function Vo(e,t){return!e||e.type!==`TSImportType`?!1:t==null||C(e,t)}function Ho(e,t){return!e||e.type!==`TSImportEqualsDeclaration`?!1:t==null||C(e,t)}function Uo(e,t){return!e||e.type!==`TSExternalModuleReference`?!1:t==null||C(e,t)}function Wo(e,t){return!e||e.type!==`TSNonNullExpression`?!1:t==null||C(e,t)}function Go(e,t){return!e||e.type!==`TSExportAssignment`?!1:t==null||C(e,t)}function Ko(e,t){return!e||e.type!==`TSNamespaceExportDeclaration`?!1:t==null||C(e,t)}function qo(e,t){return!e||e.type!==`TSTypeAnnotation`?!1:t==null||C(e,t)}function Jo(e,t){return!e||e.type!==`TSTypeParameterInstantiation`?!1:t==null||C(e,t)}function Yo(e,t){return!e||e.type!==`TSTypeParameterDeclaration`?!1:t==null||C(e,t)}function Xo(e,t){return!e||e.type!==`TSTypeParameter`?!1:t==null||C(e,t)}function Zo(e,t){if(!e)return!1;switch(e.type){case`ArrayExpression`:case`AssignmentExpression`:case`BinaryExpression`:case`InterpreterDirective`:case`Directive`:case`DirectiveLiteral`:case`BlockStatement`:case`BreakStatement`:case`CallExpression`:case`CatchClause`:case`ConditionalExpression`:case`ContinueStatement`:case`DebuggerStatement`:case`DoWhileStatement`:case`EmptyStatement`:case`ExpressionStatement`:case`File`:case`ForInStatement`:case`ForStatement`:case`FunctionDeclaration`:case`FunctionExpression`:case`Identifier`:case`IfStatement`:case`LabeledStatement`:case`StringLiteral`:case`NumericLiteral`:case`NullLiteral`:case`BooleanLiteral`:case`RegExpLiteral`:case`LogicalExpression`:case`MemberExpression`:case`NewExpression`:case`Program`:case`ObjectExpression`:case`ObjectMethod`:case`ObjectProperty`:case`RestElement`:case`ReturnStatement`:case`SequenceExpression`:case`ParenthesizedExpression`:case`SwitchCase`:case`SwitchStatement`:case`ThisExpression`:case`ThrowStatement`:case`TryStatement`:case`UnaryExpression`:case`UpdateExpression`:case`VariableDeclaration`:case`VariableDeclarator`:case`WhileStatement`:case`WithStatement`:case`AssignmentPattern`:case`ArrayPattern`:case`ArrowFunctionExpression`:case`ClassBody`:case`ClassExpression`:case`ClassDeclaration`:case`ExportAllDeclaration`:case`ExportDefaultDeclaration`:case`ExportNamedDeclaration`:case`ExportSpecifier`:case`ForOfStatement`:case`ImportDeclaration`:case`ImportDefaultSpecifier`:case`ImportNamespaceSpecifier`:case`ImportSpecifier`:case`ImportExpression`:case`MetaProperty`:case`ClassMethod`:case`ObjectPattern`:case`SpreadElement`:case`Super`:case`TaggedTemplateExpression`:case`TemplateElement`:case`TemplateLiteral`:case`YieldExpression`:case`AwaitExpression`:case`Import`:case`BigIntLiteral`:case`ExportNamespaceSpecifier`:case`OptionalMemberExpression`:case`OptionalCallExpression`:case`ClassProperty`:case`ClassPrivateProperty`:case`ClassPrivateMethod`:case`PrivateName`:case`StaticBlock`:case`ImportAttribute`:break;case`Placeholder`:switch(e.expectedNode){case`Identifier`:case`StringLiteral`:case`BlockStatement`:case`ClassBody`:break;default:return!1}break;default:return!1}return t==null||C(e,t)}function Qo(e,t){if(!e)return!1;switch(e.type){case`ArrayExpression`:case`AssignmentExpression`:case`BinaryExpression`:case`CallExpression`:case`ConditionalExpression`:case`FunctionExpression`:case`Identifier`:case`StringLiteral`:case`NumericLiteral`:case`NullLiteral`:case`BooleanLiteral`:case`RegExpLiteral`:case`LogicalExpression`:case`MemberExpression`:case`NewExpression`:case`ObjectExpression`:case`SequenceExpression`:case`ParenthesizedExpression`:case`ThisExpression`:case`UnaryExpression`:case`UpdateExpression`:case`ArrowFunctionExpression`:case`ClassExpression`:case`ImportExpression`:case`MetaProperty`:case`TaggedTemplateExpression`:case`TemplateLiteral`:case`YieldExpression`:case`AwaitExpression`:case`Import`:case`BigIntLiteral`:case`OptionalMemberExpression`:case`OptionalCallExpression`:case`TypeCastExpression`:case`JSXElement`:case`JSXFragment`:case`BindExpression`:case`DoExpression`:case`ModuleExpression`:case`TopicReference`:case`TSInstantiationExpression`:case`TSAsExpression`:case`TSSatisfiesExpression`:case`TSTypeAssertion`:case`TSNonNullExpression`:break;case`Placeholder`:switch(e.expectedNode){case`Expression`:case`Identifier`:case`StringLiteral`:break;default:return!1}break;default:return!1}return t==null||C(e,t)}function $o(e,t){if(!e)return!1;switch(e.type){case`BinaryExpression`:case`LogicalExpression`:break;default:return!1}return t==null||C(e,t)}function es(e,t){if(!e)return!1;switch(e.type){case`BlockStatement`:case`CatchClause`:case`DoWhileStatement`:case`ForInStatement`:case`ForStatement`:case`FunctionDeclaration`:case`FunctionExpression`:case`Program`:case`ObjectMethod`:case`SwitchStatement`:case`WhileStatement`:case`ArrowFunctionExpression`:case`ClassExpression`:case`ClassDeclaration`:case`ForOfStatement`:case`ClassMethod`:case`ClassPrivateMethod`:case`StaticBlock`:case`TSModuleBlock`:break;case`Placeholder`:if(e.expectedNode===`BlockStatement`)break;default:return!1}return t==null||C(e,t)}function ts(e,t){if(!e)return!1;switch(e.type){case`BlockStatement`:case`CatchClause`:case`DoWhileStatement`:case`ForInStatement`:case`ForStatement`:case`FunctionDeclaration`:case`FunctionExpression`:case`Program`:case`ObjectMethod`:case`SwitchStatement`:case`WhileStatement`:case`ArrowFunctionExpression`:case`ForOfStatement`:case`ClassMethod`:case`ClassPrivateMethod`:case`StaticBlock`:case`TSModuleBlock`:break;case`Placeholder`:if(e.expectedNode===`BlockStatement`)break;default:return!1}return t==null||C(e,t)}function ns(e,t){if(!e)return!1;switch(e.type){case`BlockStatement`:case`Program`:case`TSModuleBlock`:break;case`Placeholder`:if(e.expectedNode===`BlockStatement`)break;default:return!1}return t==null||C(e,t)}function rs(e,t){if(!e)return!1;switch(e.type){case`BlockStatement`:case`BreakStatement`:case`ContinueStatement`:case`DebuggerStatement`:case`DoWhileStatement`:case`EmptyStatement`:case`ExpressionStatement`:case`ForInStatement`:case`ForStatement`:case`FunctionDeclaration`:case`IfStatement`:case`LabeledStatement`:case`ReturnStatement`:case`SwitchStatement`:case`ThrowStatement`:case`TryStatement`:case`VariableDeclaration`:case`WhileStatement`:case`WithStatement`:case`ClassDeclaration`:case`ExportAllDeclaration`:case`ExportDefaultDeclaration`:case`ExportNamedDeclaration`:case`ForOfStatement`:case`ImportDeclaration`:case`DeclareClass`:case`DeclareFunction`:case`DeclareInterface`:case`DeclareModule`:case`DeclareModuleExports`:case`DeclareTypeAlias`:case`DeclareOpaqueType`:case`DeclareVariable`:case`DeclareExportDeclaration`:case`DeclareExportAllDeclaration`:case`InterfaceDeclaration`:case`OpaqueType`:case`TypeAlias`:case`EnumDeclaration`:case`TSDeclareFunction`:case`TSInterfaceDeclaration`:case`TSTypeAliasDeclaration`:case`TSEnumDeclaration`:case`TSModuleDeclaration`:case`TSImportEqualsDeclaration`:case`TSExportAssignment`:case`TSNamespaceExportDeclaration`:break;case`Placeholder`:switch(e.expectedNode){case`Statement`:case`Declaration`:case`BlockStatement`:break;default:return!1}break;default:return!1}return t==null||C(e,t)}function is(e,t){if(!e)return!1;switch(e.type){case`BreakStatement`:case`ContinueStatement`:case`ReturnStatement`:case`ThrowStatement`:case`YieldExpression`:case`AwaitExpression`:break;default:return!1}return t==null||C(e,t)}function as(e,t){if(!e)return!1;switch(e.type){case`BreakStatement`:case`ContinueStatement`:case`ReturnStatement`:case`ThrowStatement`:break;default:return!1}return t==null||C(e,t)}function os(e,t){if(!e)return!1;switch(e.type){case`ConditionalExpression`:case`IfStatement`:break;default:return!1}return t==null||C(e,t)}function ss(e,t){if(!e)return!1;switch(e.type){case`DoWhileStatement`:case`ForInStatement`:case`ForStatement`:case`WhileStatement`:case`ForOfStatement`:break;default:return!1}return t==null||C(e,t)}function cs(e,t){if(!e)return!1;switch(e.type){case`DoWhileStatement`:case`WhileStatement`:break;default:return!1}return t==null||C(e,t)}function ls(e,t){if(!e)return!1;switch(e.type){case`ExpressionStatement`:case`ParenthesizedExpression`:case`TypeCastExpression`:break;default:return!1}return t==null||C(e,t)}function us(e,t){if(!e)return!1;switch(e.type){case`ForInStatement`:case`ForStatement`:case`ForOfStatement`:break;default:return!1}return t==null||C(e,t)}function ds(e,t){if(!e)return!1;switch(e.type){case`ForInStatement`:case`ForOfStatement`:break;default:return!1}return t==null||C(e,t)}function fs(e,t){if(!e)return!1;switch(e.type){case`FunctionDeclaration`:case`FunctionExpression`:case`ObjectMethod`:case`ArrowFunctionExpression`:case`ClassMethod`:case`ClassPrivateMethod`:break;default:return!1}return t==null||C(e,t)}function ps(e,t){if(!e)return!1;switch(e.type){case`FunctionDeclaration`:case`FunctionExpression`:case`ObjectMethod`:case`ArrowFunctionExpression`:case`ClassMethod`:case`ClassPrivateMethod`:case`StaticBlock`:case`TSModuleBlock`:break;default:return!1}return t==null||C(e,t)}function ms(e,t){if(!e)return!1;switch(e.type){case`FunctionDeclaration`:case`FunctionExpression`:case`StringLiteral`:case`NumericLiteral`:case`NullLiteral`:case`BooleanLiteral`:case`RegExpLiteral`:case`ArrowFunctionExpression`:case`BigIntLiteral`:break;case`Placeholder`:if(e.expectedNode===`StringLiteral`)break;default:return!1}return t==null||C(e,t)}function hs(e,t){if(!e)return!1;switch(e.type){case`FunctionDeclaration`:case`VariableDeclaration`:case`ClassDeclaration`:case`ExportAllDeclaration`:case`ExportDefaultDeclaration`:case`ExportNamedDeclaration`:case`ImportDeclaration`:case`DeclareClass`:case`DeclareFunction`:case`DeclareInterface`:case`DeclareModule`:case`DeclareModuleExports`:case`DeclareTypeAlias`:case`DeclareOpaqueType`:case`DeclareVariable`:case`DeclareExportDeclaration`:case`DeclareExportAllDeclaration`:case`InterfaceDeclaration`:case`OpaqueType`:case`TypeAlias`:case`EnumDeclaration`:case`TSDeclareFunction`:case`TSInterfaceDeclaration`:case`TSTypeAliasDeclaration`:case`TSEnumDeclaration`:case`TSModuleDeclaration`:case`TSImportEqualsDeclaration`:break;case`Placeholder`:if(e.expectedNode===`Declaration`)break;default:return!1}return t==null||C(e,t)}function gs(e,t){if(!e)return!1;switch(e.type){case`Identifier`:case`RestElement`:case`AssignmentPattern`:case`ArrayPattern`:case`ObjectPattern`:case`VoidPattern`:break;case`Placeholder`:if(e.expectedNode===`Identifier`)break;default:return!1}return t==null||C(e,t)}function _s(e,t){if(!e)return!1;switch(e.type){case`Identifier`:case`MemberExpression`:case`RestElement`:case`AssignmentPattern`:case`ArrayPattern`:case`ObjectPattern`:case`VoidPattern`:case`TSAsExpression`:case`TSSatisfiesExpression`:case`TSTypeAssertion`:case`TSNonNullExpression`:break;case`Placeholder`:switch(e.expectedNode){case`Pattern`:case`Identifier`:break;default:return!1}break;default:return!1}return t==null||C(e,t)}function vs(e,t){if(!e)return!1;switch(e.type){case`Identifier`:case`MemberExpression`:case`ArrayPattern`:case`ObjectPattern`:case`TSAsExpression`:case`TSSatisfiesExpression`:case`TSTypeAssertion`:case`TSNonNullExpression`:break;case`Placeholder`:switch(e.expectedNode){case`Pattern`:case`Identifier`:break;default:return!1}break;default:return!1}return t==null||C(e,t)}function ys(e,t){if(!e)return!1;switch(e.type){case`Identifier`:case`ThisExpression`:case`TSQualifiedName`:break;case`Placeholder`:if(e.expectedNode===`Identifier`)break;default:return!1}return t==null||C(e,t)}function bs(e,t){if(!e)return!1;switch(e.type){case`StringLiteral`:case`NumericLiteral`:case`NullLiteral`:case`BooleanLiteral`:case`RegExpLiteral`:case`TemplateLiteral`:case`BigIntLiteral`:break;case`Placeholder`:if(e.expectedNode===`StringLiteral`)break;default:return!1}return t==null||C(e,t)}function xs(e,t){if(!e)return!1;switch(e.type){case`ObjectMethod`:case`ObjectProperty`:case`ObjectTypeInternalSlot`:case`ObjectTypeCallProperty`:case`ObjectTypeIndexer`:case`ObjectTypeProperty`:case`ObjectTypeSpreadProperty`:break;default:return!1}return t==null||C(e,t)}function Ss(e,t){if(!e)return!1;switch(e.type){case`ObjectMethod`:case`ClassMethod`:case`ClassPrivateMethod`:break;default:return!1}return t==null||C(e,t)}function Cs(e,t){if(!e)return!1;switch(e.type){case`ObjectMethod`:case`ObjectProperty`:break;default:return!1}return t==null||C(e,t)}function ws(e,t){if(!e)return!1;switch(e.type){case`ObjectProperty`:case`ClassProperty`:case`ClassPrivateProperty`:case`ClassAccessorProperty`:break;default:return!1}return t==null||C(e,t)}function Ts(e,t){if(!e)return!1;switch(e.type){case`UnaryExpression`:case`SpreadElement`:break;default:return!1}return t==null||C(e,t)}function Es(e,t){if(!e)return!1;switch(e.type){case`AssignmentPattern`:case`ArrayPattern`:case`ObjectPattern`:case`VoidPattern`:break;case`Placeholder`:if(e.expectedNode===`Pattern`)break;default:return!1}return t==null||C(e,t)}function Ds(e,t){if(!e)return!1;switch(e.type){case`ClassExpression`:case`ClassDeclaration`:break;default:return!1}return t==null||C(e,t)}function Os(e,t){if(!e)return!1;switch(e.type){case`ExportAllDeclaration`:case`ExportDefaultDeclaration`:case`ExportNamedDeclaration`:case`ImportDeclaration`:break;default:return!1}return t==null||C(e,t)}function ks(e,t){if(!e)return!1;switch(e.type){case`ExportAllDeclaration`:case`ExportDefaultDeclaration`:case`ExportNamedDeclaration`:break;default:return!1}return t==null||C(e,t)}function As(e,t){if(!e)return!1;switch(e.type){case`ExportSpecifier`:case`ImportDefaultSpecifier`:case`ImportNamespaceSpecifier`:case`ImportSpecifier`:case`ExportNamespaceSpecifier`:case`ExportDefaultSpecifier`:break;default:return!1}return t==null||C(e,t)}function js(e,t){if(!e)return!1;switch(e.type){case`ClassPrivateProperty`:case`ClassPrivateMethod`:case`PrivateName`:break;default:return!1}return t==null||C(e,t)}function Ms(e,t){if(!e)return!1;switch(e.type){case`AnyTypeAnnotation`:case`ArrayTypeAnnotation`:case`BooleanTypeAnnotation`:case`BooleanLiteralTypeAnnotation`:case`NullLiteralTypeAnnotation`:case`ClassImplements`:case`DeclareClass`:case`DeclareFunction`:case`DeclareInterface`:case`DeclareModule`:case`DeclareModuleExports`:case`DeclareTypeAlias`:case`DeclareOpaqueType`:case`DeclareVariable`:case`DeclareExportDeclaration`:case`DeclareExportAllDeclaration`:case`DeclaredPredicate`:case`ExistsTypeAnnotation`:case`FunctionTypeAnnotation`:case`FunctionTypeParam`:case`GenericTypeAnnotation`:case`InferredPredicate`:case`InterfaceExtends`:case`InterfaceDeclaration`:case`InterfaceTypeAnnotation`:case`IntersectionTypeAnnotation`:case`MixedTypeAnnotation`:case`EmptyTypeAnnotation`:case`NullableTypeAnnotation`:case`NumberLiteralTypeAnnotation`:case`NumberTypeAnnotation`:case`ObjectTypeAnnotation`:case`ObjectTypeInternalSlot`:case`ObjectTypeCallProperty`:case`ObjectTypeIndexer`:case`ObjectTypeProperty`:case`ObjectTypeSpreadProperty`:case`OpaqueType`:case`QualifiedTypeIdentifier`:case`StringLiteralTypeAnnotation`:case`StringTypeAnnotation`:case`SymbolTypeAnnotation`:case`ThisTypeAnnotation`:case`TupleTypeAnnotation`:case`TypeofTypeAnnotation`:case`TypeAlias`:case`TypeAnnotation`:case`TypeCastExpression`:case`TypeParameter`:case`TypeParameterDeclaration`:case`TypeParameterInstantiation`:case`UnionTypeAnnotation`:case`Variance`:case`VoidTypeAnnotation`:case`EnumDeclaration`:case`EnumBooleanBody`:case`EnumNumberBody`:case`EnumStringBody`:case`EnumSymbolBody`:case`EnumBooleanMember`:case`EnumNumberMember`:case`EnumStringMember`:case`EnumDefaultedMember`:case`IndexedAccessType`:case`OptionalIndexedAccessType`:break;default:return!1}return t==null||C(e,t)}function Ns(e,t){if(!e)return!1;switch(e.type){case`AnyTypeAnnotation`:case`ArrayTypeAnnotation`:case`BooleanTypeAnnotation`:case`BooleanLiteralTypeAnnotation`:case`NullLiteralTypeAnnotation`:case`ExistsTypeAnnotation`:case`FunctionTypeAnnotation`:case`GenericTypeAnnotation`:case`InterfaceTypeAnnotation`:case`IntersectionTypeAnnotation`:case`MixedTypeAnnotation`:case`EmptyTypeAnnotation`:case`NullableTypeAnnotation`:case`NumberLiteralTypeAnnotation`:case`NumberTypeAnnotation`:case`ObjectTypeAnnotation`:case`StringLiteralTypeAnnotation`:case`StringTypeAnnotation`:case`SymbolTypeAnnotation`:case`ThisTypeAnnotation`:case`TupleTypeAnnotation`:case`TypeofTypeAnnotation`:case`UnionTypeAnnotation`:case`VoidTypeAnnotation`:case`IndexedAccessType`:case`OptionalIndexedAccessType`:break;default:return!1}return t==null||C(e,t)}function Ps(e,t){if(!e)return!1;switch(e.type){case`AnyTypeAnnotation`:case`BooleanTypeAnnotation`:case`NullLiteralTypeAnnotation`:case`MixedTypeAnnotation`:case`EmptyTypeAnnotation`:case`NumberTypeAnnotation`:case`StringTypeAnnotation`:case`SymbolTypeAnnotation`:case`ThisTypeAnnotation`:case`VoidTypeAnnotation`:break;default:return!1}return t==null||C(e,t)}function Fs(e,t){if(!e)return!1;switch(e.type){case`DeclareClass`:case`DeclareFunction`:case`DeclareInterface`:case`DeclareModule`:case`DeclareModuleExports`:case`DeclareTypeAlias`:case`DeclareOpaqueType`:case`DeclareVariable`:case`DeclareExportDeclaration`:case`DeclareExportAllDeclaration`:case`InterfaceDeclaration`:case`OpaqueType`:case`TypeAlias`:break;default:return!1}return t==null||C(e,t)}function Is(e,t){if(!e)return!1;switch(e.type){case`DeclaredPredicate`:case`InferredPredicate`:break;default:return!1}return t==null||C(e,t)}function Ls(e,t){if(!e)return!1;switch(e.type){case`EnumBooleanBody`:case`EnumNumberBody`:case`EnumStringBody`:case`EnumSymbolBody`:break;default:return!1}return t==null||C(e,t)}function Rs(e,t){if(!e)return!1;switch(e.type){case`EnumBooleanMember`:case`EnumNumberMember`:case`EnumStringMember`:case`EnumDefaultedMember`:break;default:return!1}return t==null||C(e,t)}function zs(e,t){if(!e)return!1;switch(e.type){case`JSXAttribute`:case`JSXClosingElement`:case`JSXElement`:case`JSXEmptyExpression`:case`JSXExpressionContainer`:case`JSXSpreadChild`:case`JSXIdentifier`:case`JSXMemberExpression`:case`JSXNamespacedName`:case`JSXOpeningElement`:case`JSXSpreadAttribute`:case`JSXText`:case`JSXFragment`:case`JSXOpeningFragment`:case`JSXClosingFragment`:break;default:return!1}return t==null||C(e,t)}function Bs(e,t){if(!e)return!1;switch(e.type){case`Placeholder`:case`V8IntrinsicIdentifier`:break;default:return!1}return t==null||C(e,t)}function Vs(e,t){if(!e)return!1;switch(e.type){case`ClassAccessorProperty`:break;default:return!1}return t==null||C(e,t)}function Hs(e,t){if(!e)return!1;switch(e.type){case`TSParameterProperty`:case`TSDeclareFunction`:case`TSDeclareMethod`:case`TSQualifiedName`:case`TSCallSignatureDeclaration`:case`TSConstructSignatureDeclaration`:case`TSPropertySignature`:case`TSMethodSignature`:case`TSIndexSignature`:case`TSAnyKeyword`:case`TSBooleanKeyword`:case`TSBigIntKeyword`:case`TSIntrinsicKeyword`:case`TSNeverKeyword`:case`TSNullKeyword`:case`TSNumberKeyword`:case`TSObjectKeyword`:case`TSStringKeyword`:case`TSSymbolKeyword`:case`TSUndefinedKeyword`:case`TSUnknownKeyword`:case`TSVoidKeyword`:case`TSThisType`:case`TSFunctionType`:case`TSConstructorType`:case`TSTypeReference`:case`TSTypePredicate`:case`TSTypeQuery`:case`TSTypeLiteral`:case`TSArrayType`:case`TSTupleType`:case`TSOptionalType`:case`TSRestType`:case`TSNamedTupleMember`:case`TSUnionType`:case`TSIntersectionType`:case`TSConditionalType`:case`TSInferType`:case`TSParenthesizedType`:case`TSTypeOperator`:case`TSIndexedAccessType`:case`TSMappedType`:case`TSTemplateLiteralType`:case`TSLiteralType`:case`TSClassImplements`:case`TSInterfaceHeritage`:case`TSInterfaceDeclaration`:case`TSInterfaceBody`:case`TSTypeAliasDeclaration`:case`TSInstantiationExpression`:case`TSAsExpression`:case`TSSatisfiesExpression`:case`TSTypeAssertion`:case`TSEnumBody`:case`TSEnumDeclaration`:case`TSEnumMember`:case`TSModuleDeclaration`:case`TSModuleBlock`:case`TSImportType`:case`TSImportEqualsDeclaration`:case`TSExternalModuleReference`:case`TSNonNullExpression`:case`TSExportAssignment`:case`TSNamespaceExportDeclaration`:case`TSTypeAnnotation`:case`TSTypeParameterInstantiation`:case`TSTypeParameterDeclaration`:case`TSTypeParameter`:break;default:return!1}return t==null||C(e,t)}function Us(e,t){if(!e)return!1;switch(e.type){case`TSCallSignatureDeclaration`:case`TSConstructSignatureDeclaration`:case`TSPropertySignature`:case`TSMethodSignature`:case`TSIndexSignature`:break;default:return!1}return t==null||C(e,t)}function Ws(e,t){if(!e)return!1;switch(e.type){case`TSAnyKeyword`:case`TSBooleanKeyword`:case`TSBigIntKeyword`:case`TSIntrinsicKeyword`:case`TSNeverKeyword`:case`TSNullKeyword`:case`TSNumberKeyword`:case`TSObjectKeyword`:case`TSStringKeyword`:case`TSSymbolKeyword`:case`TSUndefinedKeyword`:case`TSUnknownKeyword`:case`TSVoidKeyword`:case`TSThisType`:case`TSFunctionType`:case`TSConstructorType`:case`TSTypeReference`:case`TSTypePredicate`:case`TSTypeQuery`:case`TSTypeLiteral`:case`TSArrayType`:case`TSTupleType`:case`TSOptionalType`:case`TSRestType`:case`TSUnionType`:case`TSIntersectionType`:case`TSConditionalType`:case`TSInferType`:case`TSParenthesizedType`:case`TSTypeOperator`:case`TSIndexedAccessType`:case`TSMappedType`:case`TSTemplateLiteralType`:case`TSLiteralType`:case`TSClassImplements`:case`TSInterfaceHeritage`:case`TSImportType`:break;default:return!1}return t==null||C(e,t)}function Gs(e,t){if(!e)return!1;switch(e.type){case`TSAnyKeyword`:case`TSBooleanKeyword`:case`TSBigIntKeyword`:case`TSIntrinsicKeyword`:case`TSNeverKeyword`:case`TSNullKeyword`:case`TSNumberKeyword`:case`TSObjectKeyword`:case`TSStringKeyword`:case`TSSymbolKeyword`:case`TSUndefinedKeyword`:case`TSUnknownKeyword`:case`TSVoidKeyword`:case`TSThisType`:case`TSTemplateLiteralType`:case`TSLiteralType`:break;default:return!1}return t==null||C(e,t)}function Ks(e,t){return w(`isNumberLiteral`,`isNumericLiteral`),!e||e.type!==`NumberLiteral`?!1:t==null||C(e,t)}function qs(e,t){return w(`isRegexLiteral`,`isRegExpLiteral`),!e||e.type!==`RegexLiteral`?!1:t==null||C(e,t)}function Js(e,t){return w(`isRestProperty`,`isRestElement`),!e||e.type!==`RestProperty`?!1:t==null||C(e,t)}function Ys(e,t){return w(`isSpreadProperty`,`isSpreadElement`),!e||e.type!==`SpreadProperty`?!1:t==null||C(e,t)}function Xs(e,t){return w(`isModuleDeclaration`,`isImportOrExportDeclaration`),Os(e,t)}function Zs(e){return Yn(e)||Mr(e)}function Qs(e,t,n){if(!Zs(e))return!1;let r=Array.isArray(t)?t:t.split(`.`),i=[],a;for(a=e;Zs(a);a=a.object??a.meta)i.push(a.property);if(i.push(a),i.length<r.length||!n&&i.length>r.length)return!1;for(let e=0,t=i.length-1;e<r.length;e++,t--){let n=i[t],a;if(Bn(n))a=n.name;else if(Un(n))a=n.value;else if(sr(n))a=`this`;else if(Ir(n))a=`super`;else if(Xr(n))a=`#`+n.id.name;else return!1;if(r[e]!==a)return!1}return!0}function $s(e,t){let n=e.split(`.`);return e=>Qs(e,n,t)}const ec=$s(`React.Component`);function tc(e){return!!e&&/^[a-z]/.test(e)}function nc(e,t){return e===t?!0:e==null||wc[t]?!1:!!E[t]?.includes(e)}function rc(e,t){return!!(e===t||nl[e]?.includes(t))}function T(e,t,n){return t?nc(t.type,e)?n===void 0?!0:C(t,n):!n&&t.type===`Placeholder`&&e in E?rc(t.expectedNode,e):!1:!1}function ic(e,t=!0){return typeof e!=`string`||t&&(on(e)||an(e,!0))?!1:$t(e)}const ac=[`consequent`,`body`,`alternate`],oc=[`body`,`expressions`],sc=[`left`,`init`],cc=[`leadingComments`,`trailingComments`,`innerComments`],lc=[`||`,`&&`,`??`],uc=[`++`,`--`],dc=[`>`,`<`,`>=`,`<=`],fc=[`==`,`===`,`!=`,`!==`],pc=[...fc,`in`,`instanceof`],mc=[...pc,...dc],hc=[`-`,`/`,`%`,`*`,`**`,`&`,`|`,`>>`,`>>>`,`<<`,`^`],gc=[`+`,...hc,...mc,`|>`],_c=[`=`,`+=`,...hc.map(e=>e+`=`),...lc.map(e=>e+`=`)],vc=[`delete`,`!`],yc=[`+`,`-`,`~`],bc=[`typeof`],xc=[`void`,`throw`,...vc,...yc,...bc],Sc={optional:[`typeAnnotation`,`typeParameters`,`returnType`],force:[`start`,`loc`,`end`]},Cc={},wc={},E={},Tc={},Ec={},Dc={},Oc={},kc={};function Ac(e){return Array.isArray(e)?`array`:e===null?`null`:typeof e}function D(e){return{validate:e}}function O(...e){return D(P(...e))}function k(e){return{validate:e,optional:!0}}function jc(e,t){return{validate:e,default:t,optional:!1}}function A(...e){return{validate:P(...e),optional:!0}}function Mc(e){return I(F(`array`),Nc(e))}function j(...e){return Mc(P(...e))}function M(...e){return D(j(...e))}function Nc(e){let t=vl;function n(n,r,i){if(!Array.isArray(i))return;let a=0,o={toString(){return`${r}[${a}]`}};for(;a<i.length;a++){let r=i[a];e(n,o,r),t(n,o,r)}}return n.each=e,n}function N(...e){function t(t,n,r){if(!e.includes(r))throw TypeError(`Property ${n} expected value to be one of ${JSON.stringify(e)} but got ${JSON.stringify(r)}`)}return t.oneOf=e,t}const Pc=[];function P(...e){let t=new Set;Pc.push({types:e,set:t});function n(n,r,i){let a=i?.type;if(a!=null){if(t.has(a)){vl(n,r,i);return}if(a===`Placeholder`){for(let t of e)if(T(t,i)){vl(n,r,i);return}}}throw TypeError(`Property ${r} of ${n.type} expected node to be of a type ${JSON.stringify(e)} but instead got ${JSON.stringify(a)}`)}return n.oneOfNodeTypes=e,n}function Fc(...e){function t(t,n,r){let i=Ac(r);for(let a of e)if(i===a||T(a,r)){vl(t,n,r);return}throw TypeError(`Property ${n} of ${t.type} expected node to be of a type ${JSON.stringify(e)} but instead got ${JSON.stringify(r?.type)}`)}return t.oneOfNodeOrValueTypes=e,t}function F(e){function t(t,n,r){if(Ac(r)!==e)throw TypeError(`Property ${n} expected type of ${e} but got ${Ac(r)}`)}return t.type=e,t}function Ic(e){let t=Object.keys(e);function n(n,r,i){let a=[];for(let r of t)try{_l(n,r,i[r],e[r])}catch(e){if(e instanceof TypeError){a.push(e.message);continue}throw e}if(a.length)throw TypeError(`Property ${r} of ${n.type} expected to have the following:\n${a.join(`
|
|
5
|
+
`)}`)}return n.shapeOf=e,n}function Lc(){function e(e){let t=e;for(;e;){let{type:e}=t;if(e===`OptionalCallExpression`){if(t.optional)return;t=t.callee;continue}if(e===`OptionalMemberExpression`){if(t.optional)return;t=t.object;continue}break}throw TypeError(`Non-optional ${e.type} must chain from an optional OptionalMemberExpression or OptionalCallExpression. Found chain from ${t?.type}`)}return e}function I(...e){function t(...t){for(let n of e)n(...t)}if(t.chainOf=e,e.length>=2&&`type`in e[0]&&e[0].type===`array`&&!(`each`in e[1]))throw Error(`An assertValueType("array") validator can only be followed by an assertEach(...) validator.`);return t}const Rc=new Set([`aliases`,`builder`,`deprecatedAlias`,`fields`,`inherits`,`visitor`,`validate`,`unionShape`]),zc=new Set([`default`,`optional`,`deprecated`,`validate`]),Bc={};function Vc(...e){return(t,n={})=>{let r=n.aliases;r||(n.inherits&&(r=Bc[n.inherits].aliases?.slice()),r??=[],n.aliases=r);let i=e.filter(e=>!r.includes(e));r.unshift(...i),Hc(t,n)}}function Hc(e,t={}){let n=t.inherits&&Bc[t.inherits]||{},r=t.visitor||n.visitor||[],i=t.aliases||n.aliases||[],a=t.builder||n.builder||t.visitor||[],o=t.fields;if(!o&&(o={},n.fields)){let e=Object.getOwnPropertyNames(n.fields);for(let t of e){let e=n.fields[t],r=e.default;if(Array.isArray(r)?r.length>0:r&&typeof r==`object`)throw Error(`field defaults can only be primitives or empty arrays currently`);o[t]={default:Array.isArray(r)?[]:r,optional:e.optional,deprecated:e.deprecated,validate:e.validate}}}for(let n of Object.keys(t))if(!Rc.has(n))throw Error(`Unknown type option "${n}" on ${e}`);t.deprecatedAlias&&(Dc[t.deprecatedAlias]=e);for(let e of r.concat(a))o[e]=o[e]||{};for(let t of Object.keys(o)){let n=o[t];n.default===null&&(n.optional??=!0),n.default===void 0?(n.default=null,n.optional??=!1):!n.validate&&n.default!=null&&(n.validate=F(Ac(n.default)));for(let r of Object.keys(n))if(!zc.has(r))throw Error(`Unknown field key "${r}" on ${e}.${t}`)}Cc[e]=t.visitor=r,Ec[e]=t.builder=a,Tc[e]=t.fields=o,wc[e]=t.aliases=i,i.forEach(t=>{E[t]=E[t]||[],E[t].push(e)}),t.validate&&(Oc[e]=t.validate),t.unionShape&&(kc[e]=t.unionShape),Bc[e]=t}var Uc=Object.freeze({__proto__:null,ALIAS_KEYS:wc,BUILDER_KEYS:Ec,DEPRECATED_KEYS:Dc,FLIPPED_ALIAS_KEYS:E,NODE_FIELDS:Tc,NODE_PARENT_VALIDATIONS:Oc,NODE_UNION_SHAPES__PRIVATE:kc,VISITOR_KEYS:Cc,allExpandedTypes:Pc,arrayOf:Mc,arrayOfType:j,assertEach:Nc,assertNodeOrValueType:Fc,assertNodeType:P,assertOneOf:N,assertOptionalChainStart:Lc,assertShape:Ic,assertValueType:F,chain:I,default:Hc,defineAliasedType:Vc,validate:D,validateArrayOfType:M,validateDefault:jc,validateOptional:k,validateOptionalType:A,validateType:O});const Wc=(e=!1)=>({unionShape:{discriminator:`computed`,shapes:[{name:`computed`,value:[!0],properties:{key:{validate:P(`Expression`)}}},{name:`nonComputed`,value:[!1],properties:{key:{validate:e?P(`Identifier`,`StringLiteral`,`NumericLiteral`,`BigIntLiteral`,`PrivateName`):P(`Identifier`,`StringLiteral`,`NumericLiteral`,`BigIntLiteral`)}}}]}}),L=Vc(`Standardized`);L(`ArrayExpression`,{fields:{elements:{validate:Mc(Fc(`null`,`Expression`,`SpreadElement`)),default:void 0}},visitor:[`elements`],aliases:[`Expression`]}),L(`AssignmentExpression`,{fields:{operator:{validate:Object.assign(function(){let e=N(..._c),t=N(`=`);return function(n,r,i){(T(`Pattern`,n.left)?t:e)(n,r,i)}}(),{oneOf:_c})},left:{validate:P(`Identifier`,`MemberExpression`,`OptionalMemberExpression`,`ArrayPattern`,`ObjectPattern`,`TSAsExpression`,`TSSatisfiesExpression`,`TSTypeAssertion`,`TSNonNullExpression`)},right:{validate:P(`Expression`)}},builder:[`operator`,`left`,`right`],visitor:[`left`,`right`],aliases:[`Expression`]}),L(`BinaryExpression`,{builder:[`operator`,`left`,`right`],fields:{operator:{validate:N(...gc)},left:{validate:function(){let e=P(`Expression`),t=P(`Expression`,`PrivateName`);return Object.assign(function(n,r,i){(n.operator===`in`?t:e)(n,r,i)},{oneOfNodeTypes:[`Expression`,`PrivateName`]})}()},right:{validate:P(`Expression`)}},visitor:[`left`,`right`],aliases:[`Binary`,`Expression`]}),L(`InterpreterDirective`,{builder:[`value`],fields:{value:{validate:F(`string`)}}}),L(`Directive`,{visitor:[`value`],fields:{value:{validate:P(`DirectiveLiteral`)}}}),L(`DirectiveLiteral`,{builder:[`value`],fields:{value:{validate:F(`string`)}}}),L(`BlockStatement`,{builder:[`body`,`directives`],visitor:[`directives`,`body`],fields:{directives:{validate:j(`Directive`),default:[]},body:M(`Statement`)},aliases:[`Scopable`,`BlockParent`,`Block`,`Statement`]}),L(`BreakStatement`,{visitor:[`label`],fields:{label:{validate:P(`Identifier`),optional:!0}},aliases:[`Statement`,`Terminatorless`,`CompletionStatement`]}),L(`CallExpression`,{visitor:[`callee`,`typeArguments`,`arguments`],builder:[`callee`,`arguments`],aliases:[`Expression`],fields:{callee:{validate:P(`Expression`,`Super`,`V8IntrinsicIdentifier`)},arguments:M(`Expression`,`SpreadElement`,`ArgumentPlaceholder`),typeArguments:{validate:P(`TypeParameterInstantiation`,`TSTypeParameterInstantiation`),optional:!0}}}),L(`CatchClause`,{visitor:[`param`,`body`],fields:{param:{validate:P(`Identifier`,`ArrayPattern`,`ObjectPattern`),optional:!0},body:{validate:P(`BlockStatement`)}},aliases:[`Scopable`,`BlockParent`]}),L(`ConditionalExpression`,{visitor:[`test`,`consequent`,`alternate`],fields:{test:{validate:P(`Expression`)},consequent:{validate:P(`Expression`)},alternate:{validate:P(`Expression`)}},aliases:[`Expression`,`Conditional`]}),L(`ContinueStatement`,{visitor:[`label`],fields:{label:{validate:P(`Identifier`),optional:!0}},aliases:[`Statement`,`Terminatorless`,`CompletionStatement`]}),L(`DebuggerStatement`,{aliases:[`Statement`]}),L(`DoWhileStatement`,{builder:[`test`,`body`],visitor:[`body`,`test`],fields:{test:{validate:P(`Expression`)},body:{validate:P(`Statement`)}},aliases:[`Statement`,`BlockParent`,`Loop`,`While`,`Scopable`]}),L(`EmptyStatement`,{aliases:[`Statement`]}),L(`ExpressionStatement`,{visitor:[`expression`],fields:{expression:{validate:P(`Expression`)}},aliases:[`Statement`,`ExpressionWrapper`]}),L(`File`,{builder:[`program`,`comments`,`tokens`],visitor:[`program`],fields:{program:{validate:P(`Program`)},comments:{validate:Nc(P(`CommentBlock`,`CommentLine`)),optional:!0},tokens:{validate:Nc(Object.assign(()=>{},{type:`any`})),optional:!0}}}),L(`ForInStatement`,{visitor:[`left`,`right`,`body`],aliases:[`Scopable`,`Statement`,`For`,`BlockParent`,`Loop`,`ForXStatement`],fields:{left:{validate:P(`VariableDeclaration`,`Identifier`,`MemberExpression`,`ArrayPattern`,`ObjectPattern`,`TSAsExpression`,`TSSatisfiesExpression`,`TSTypeAssertion`,`TSNonNullExpression`)},right:{validate:P(`Expression`)},body:{validate:P(`Statement`)}}}),L(`ForStatement`,{visitor:[`init`,`test`,`update`,`body`],aliases:[`Scopable`,`Statement`,`For`,`BlockParent`,`Loop`],fields:{init:{validate:P(`VariableDeclaration`,`Expression`),optional:!0},test:{validate:P(`Expression`),optional:!0},update:{validate:P(`Expression`),optional:!0},body:{validate:P(`Statement`)}}});const Gc=()=>({params:M(`FunctionParameter`),generator:{default:!1},async:{default:!1}}),Kc=()=>({returnType:{validate:P(`TypeAnnotation`,`TSTypeAnnotation`),optional:!0},typeParameters:{validate:P(`TypeParameterDeclaration`,`TSTypeParameterDeclaration`),optional:!0}}),qc=()=>({...Gc(),declare:{validate:F(`boolean`),optional:!0},id:{validate:P(`Identifier`),optional:!0}});L(`FunctionDeclaration`,{builder:[`id`,`params`,`body`,`generator`,`async`],visitor:[`id`,`typeParameters`,`params`,`predicate`,`returnType`,`body`],fields:{...qc(),...Kc(),body:{validate:P(`BlockStatement`)},predicate:{validate:P(`DeclaredPredicate`,`InferredPredicate`),optional:!0}},aliases:[`Scopable`,`Function`,`BlockParent`,`FunctionParent`,`Statement`,`Pureish`,`Declaration`],validate:function(){let e=P(`Identifier`);return function(t,n,r){T(`ExportDefaultDeclaration`,t)||e(r,`id`,r.id)}}()}),L(`FunctionExpression`,{inherits:`FunctionDeclaration`,aliases:[`Scopable`,`Function`,`BlockParent`,`FunctionParent`,`Expression`,`Pureish`],fields:{...Gc(),...Kc(),id:{validate:P(`Identifier`),optional:!0},body:{validate:P(`BlockStatement`)},predicate:{validate:P(`DeclaredPredicate`,`InferredPredicate`),optional:!0}}});const Jc=()=>({typeAnnotation:{validate:P(`TypeAnnotation`,`TSTypeAnnotation`),optional:!0},optional:{validate:F(`boolean`),optional:!0},decorators:{validate:j(`Decorator`),optional:!0}});L(`Identifier`,{builder:[`name`],visitor:[`typeAnnotation`,`decorators`],aliases:[`Expression`,`FunctionParameter`,`PatternLike`,`LVal`,`TSEntityName`],fields:{...Jc(),name:{validate:I(F(`string`),Object.assign(function(e,t,n){if(!ic(n,!1))throw TypeError(`"${n}" is not a valid identifier name`)},{type:`string`}))}},validate:function(e,t,n){let r=/\.(\w+)$/.exec(t.toString());if(!r)return;let[,i]=r,a={computed:!1};if(i===`property`){if(T(`MemberExpression`,e,a)||T(`OptionalMemberExpression`,e,a))return}else if(i===`key`){if(T(`Property`,e,a)||T(`Method`,e,a))return}else if(i===`exported`){if(T(`ExportSpecifier`,e))return}else if(i===`imported`){if(T(`ImportSpecifier`,e,{imported:n}))return}else if(i===`meta`&&T(`MetaProperty`,e,{meta:n}))return;if((on(n.name)||rn(n.name,!1))&&n.name!==`this`)throw TypeError(`"${n.name}" is not a valid identifier`)}}),L(`IfStatement`,{visitor:[`test`,`consequent`,`alternate`],aliases:[`Statement`,`Conditional`],fields:{test:{validate:P(`Expression`)},consequent:{validate:P(`Statement`)},alternate:{optional:!0,validate:P(`Statement`)}}}),L(`LabeledStatement`,{visitor:[`label`,`body`],aliases:[`Statement`],fields:{label:{validate:P(`Identifier`)},body:{validate:P(`Statement`)}}}),L(`StringLiteral`,{builder:[`value`],fields:{value:{validate:F(`string`)}},aliases:[`Expression`,`Pureish`,`Literal`,`Immutable`]}),L(`NumericLiteral`,{builder:[`value`],deprecatedAlias:`NumberLiteral`,fields:{value:{validate:I(F(`number`),Object.assign(function(e,t,n){if(1/n<0||!Number.isFinite(n)){let e=Error(`NumericLiterals must be non-negative finite numbers. You can use t.valueToNode(${n}) instead.`);if(!Error().stack.includes(`regenerator`))throw e}},{type:`number`}))}},aliases:[`Expression`,`Pureish`,`Literal`,`Immutable`]}),L(`NullLiteral`,{aliases:[`Expression`,`Pureish`,`Literal`,`Immutable`]}),L(`BooleanLiteral`,{builder:[`value`],fields:{value:{validate:F(`boolean`)}},aliases:[`Expression`,`Pureish`,`Literal`,`Immutable`]}),L(`RegExpLiteral`,{builder:[`pattern`,`flags`],deprecatedAlias:`RegexLiteral`,aliases:[`Expression`,`Pureish`,`Literal`],fields:{pattern:{validate:F(`string`)},flags:{validate:I(F(`string`),Object.assign(function(e,t,n){let r=/[^dgimsuvy]/.exec(n);if(r)throw TypeError(`"${r[0]}" is not a valid RegExp flag`)},{type:`string`})),default:``}}}),L(`LogicalExpression`,{builder:[`operator`,`left`,`right`],visitor:[`left`,`right`],aliases:[`Binary`,`Expression`],fields:{operator:{validate:N(...lc)},left:{validate:P(`Expression`)},right:{validate:P(`Expression`)}}}),L(`MemberExpression`,{builder:[`object`,`property`,`computed`,...[]],visitor:[`object`,`property`],aliases:[`Expression`,`LVal`,`PatternLike`],unionShape:{discriminator:`computed`,shapes:[{name:`computed`,value:[!0],properties:{property:{validate:P(`Expression`)}}},{name:`nonComputed`,value:[!1],properties:{property:{validate:P(`Identifier`,`PrivateName`)}}}]},fields:{object:{validate:P(`Expression`,`Super`)},property:{validate:function(){let e=P(`Identifier`,`PrivateName`),t=P(`Expression`),n=function(n,r,i){(n.computed?t:e)(n,r,i)};return n.oneOfNodeTypes=[`Expression`,`Identifier`,`PrivateName`],n}()},computed:{default:!1}}}),L(`NewExpression`,{inherits:`CallExpression`}),L(`Program`,{visitor:[`directives`,`body`],builder:[`body`,`directives`,`sourceType`,`interpreter`],fields:{sourceType:{validate:N(`script`,`module`),default:`script`},interpreter:{validate:P(`InterpreterDirective`),default:null,optional:!0},directives:{validate:j(`Directive`),default:[]},body:M(`Statement`)},aliases:[`Scopable`,`BlockParent`,`Block`]}),L(`ObjectExpression`,{visitor:[`properties`],aliases:[`Expression`],fields:{properties:M(`ObjectMethod`,`ObjectProperty`,`SpreadElement`)}}),L(`ObjectMethod`,{builder:[`kind`,`key`,`params`,`body`,`computed`,`generator`,`async`],visitor:[`decorators`,`key`,`typeParameters`,`params`,`returnType`,`body`],...Wc(),fields:{...Gc(),...Kc(),kind:{validate:N(`method`,`get`,`set`)},computed:{default:!1},key:{validate:function(){let e=P(`Identifier`,`StringLiteral`,`NumericLiteral`,`BigIntLiteral`),t=P(`Expression`),n=function(n,r,i){(n.computed?t:e)(n,r,i)};return n.oneOfNodeTypes=[`Expression`,`Identifier`,`StringLiteral`,`NumericLiteral`,`BigIntLiteral`],n}()},decorators:{validate:j(`Decorator`),optional:!0},body:{validate:P(`BlockStatement`)}},aliases:[`UserWhitespacable`,`Function`,`Scopable`,`BlockParent`,`FunctionParent`,`Method`,`ObjectMember`]}),L(`ObjectProperty`,{builder:[`key`,`value`,`computed`,`shorthand`,...[]],unionShape:{discriminator:`computed`,shapes:[{name:`computed`,value:[!0],properties:{key:{validate:P(`Expression`)}}},{name:`nonComputed`,value:[!1],properties:{key:{validate:P(`Identifier`,`StringLiteral`,`NumericLiteral`,`BigIntLiteral`,`PrivateName`)}}}]},fields:{computed:{default:!1},key:{validate:function(){let e=P(`Identifier`,`StringLiteral`,`NumericLiteral`,`BigIntLiteral`,`PrivateName`),t=P(`Expression`);return Object.assign(function(n,r,i){(n.computed?t:e)(n,r,i)},{oneOfNodeTypes:[`Expression`,`Identifier`,`StringLiteral`,`NumericLiteral`,`BigIntLiteral`,`PrivateName`]})}()},value:{validate:P(`Expression`,`PatternLike`)},shorthand:{validate:I(F(`boolean`),Object.assign(function(e,t,n){if(n){if(e.computed)throw TypeError(`Property shorthand of ObjectProperty cannot be true if computed is true`);if(!T(`Identifier`,e.key))throw TypeError(`Property shorthand of ObjectProperty cannot be true if key is not an Identifier`)}},{type:`boolean`})),default:!1},decorators:{validate:j(`Decorator`),optional:!0}},visitor:[`decorators`,`key`,`value`],aliases:[`UserWhitespacable`,`Property`,`ObjectMember`],validate:function(){let e=P(`Identifier`,`Pattern`,`TSAsExpression`,`TSSatisfiesExpression`,`TSNonNullExpression`,`TSTypeAssertion`),t=P(`Expression`);return function(n,r,i){(T(`ObjectPattern`,n)?e:t)(i,`value`,i.value)}}()}),L(`RestElement`,{visitor:[`argument`,`typeAnnotation`],builder:[`argument`],aliases:[`FunctionParameter`,`PatternLike`],deprecatedAlias:`RestProperty`,fields:{...Jc(),argument:{validate:P(`Identifier`,`ArrayPattern`,`ObjectPattern`,`MemberExpression`,`TSAsExpression`,`TSSatisfiesExpression`,`TSTypeAssertion`,`TSNonNullExpression`)}},validate:function(e,t){let n=/(\w+)\[(\d+)\]/.exec(t.toString());if(!n)throw Error(`Internal Babel error: malformed key.`);let[,r,i]=n;if(e[r].length>+i+1)throw TypeError(`RestElement must be last element of ${r}`)}}),L(`ReturnStatement`,{visitor:[`argument`],aliases:[`Statement`,`Terminatorless`,`CompletionStatement`],fields:{argument:{validate:P(`Expression`),optional:!0}}}),L(`SequenceExpression`,{visitor:[`expressions`],fields:{expressions:M(`Expression`)},aliases:[`Expression`]}),L(`ParenthesizedExpression`,{visitor:[`expression`],aliases:[`Expression`,`ExpressionWrapper`],fields:{expression:{validate:P(`Expression`)}}}),L(`SwitchCase`,{visitor:[`test`,`consequent`],fields:{test:{validate:P(`Expression`),optional:!0},consequent:M(`Statement`)}}),L(`SwitchStatement`,{visitor:[`discriminant`,`cases`],aliases:[`Statement`,`BlockParent`,`Scopable`],fields:{discriminant:{validate:P(`Expression`)},cases:M(`SwitchCase`)}}),L(`ThisExpression`,{aliases:[`Expression`,`TSEntityName`]}),L(`ThrowStatement`,{visitor:[`argument`],aliases:[`Statement`,`Terminatorless`,`CompletionStatement`],fields:{argument:{validate:P(`Expression`)}}}),L(`TryStatement`,{visitor:[`block`,`handler`,`finalizer`],aliases:[`Statement`],fields:{block:{validate:I(P(`BlockStatement`),Object.assign(function(e){if(!e.handler&&!e.finalizer)throw TypeError(`TryStatement expects either a handler or finalizer, or both`)},{oneOfNodeTypes:[`BlockStatement`]}))},handler:{optional:!0,validate:P(`CatchClause`)},finalizer:{optional:!0,validate:P(`BlockStatement`)}}}),L(`UnaryExpression`,{builder:[`operator`,`argument`,`prefix`],fields:{prefix:{default:!0},argument:{validate:P(`Expression`)},operator:{validate:N(...xc)}},visitor:[`argument`],aliases:[`UnaryLike`,`Expression`]}),L(`UpdateExpression`,{builder:[`operator`,`argument`,`prefix`],fields:{prefix:{default:!1},argument:{validate:P(`Identifier`,`MemberExpression`)},operator:{validate:N(...uc)}},visitor:[`argument`],aliases:[`Expression`]}),L(`VariableDeclaration`,{builder:[`kind`,`declarations`],visitor:[`declarations`],aliases:[`Statement`,`Declaration`],fields:{declare:{validate:F(`boolean`),optional:!0},kind:{validate:N(`var`,`let`,`const`,`using`,`await using`)},declarations:M(`VariableDeclarator`)},validate:(()=>{let e=P(`Identifier`,`Placeholder`),t=P(`Identifier`,`ArrayPattern`,`ObjectPattern`,`Placeholder`),n=P(`Identifier`,`VoidPattern`,`Placeholder`);return function(r,i,a){let{kind:o,declarations:s}=a,c=T(`ForXStatement`,r,{left:a});if(c&&s.length!==1)throw TypeError(`Exactly one VariableDeclarator is required in the VariableDeclaration of a ${r.type}`);for(let r of s)o===`const`||o===`let`||o===`var`?!c&&!r.init?e(r,`id`,r.id):t(r,`id`,r.id):n(r,`id`,r.id)}})()}),L(`VariableDeclarator`,{visitor:[`id`,`init`],fields:{id:{validate:P(`Identifier`,`ArrayPattern`,`ObjectPattern`,`VoidPattern`)},definite:{optional:!0,validate:F(`boolean`)},init:{optional:!0,validate:P(`Expression`)}}}),L(`WhileStatement`,{visitor:[`test`,`body`],aliases:[`Statement`,`BlockParent`,`Loop`,`While`,`Scopable`],fields:{test:{validate:P(`Expression`)},body:{validate:P(`Statement`)}}}),L(`WithStatement`,{visitor:[`object`,`body`],aliases:[`Statement`],fields:{object:{validate:P(`Expression`)},body:{validate:P(`Statement`)}}}),L(`AssignmentPattern`,{visitor:[`left`,`right`,`decorators`],builder:[`left`,`right`],aliases:[`FunctionParameter`,`Pattern`,`PatternLike`],fields:{...Jc(),left:{validate:P(`Identifier`,`ObjectPattern`,`ArrayPattern`,`MemberExpression`,`TSAsExpression`,`TSSatisfiesExpression`,`TSTypeAssertion`,`TSNonNullExpression`)},right:{validate:P(`Expression`)},decorators:{validate:j(`Decorator`),optional:!0}}}),L(`ArrayPattern`,{visitor:[`elements`,`typeAnnotation`],builder:[`elements`],aliases:[`FunctionParameter`,`Pattern`,`PatternLike`,`LVal`],fields:{...Jc(),elements:{validate:I(F(`array`),Nc(Fc(`null`,`PatternLike`)))}}}),L(`ArrowFunctionExpression`,{builder:[`params`,`body`,`async`],visitor:[`typeParameters`,`params`,`predicate`,`returnType`,`body`],aliases:[`Scopable`,`Function`,`BlockParent`,`FunctionParent`,`Expression`,`Pureish`],fields:{...Gc(),generator:{default:null,optional:!0,validate:Object.assign((e,t,n)=>{if(n)throw TypeError(`ArrowFunctionExpression cannot be a generator`)},{type:`boolean`})},...Kc(),expression:{validate:F(`boolean`)},body:{validate:P(`BlockStatement`,`Expression`)},predicate:{validate:P(`DeclaredPredicate`,`InferredPredicate`),optional:!0}}}),L(`ClassBody`,{visitor:[`body`],fields:{body:M(`ClassMethod`,`ClassPrivateMethod`,`ClassProperty`,`ClassPrivateProperty`,`ClassAccessorProperty`,`TSDeclareMethod`,`TSIndexSignature`,`StaticBlock`)}}),L(`ClassExpression`,{builder:[`id`,`superClass`,`body`,`decorators`],visitor:[`decorators`,`id`,`typeParameters`,`superClass`,`superTypeArguments`,`mixins`,`implements`,`body`],aliases:[`Scopable`,`Class`,`Expression`],fields:{id:{validate:P(`Identifier`),optional:!0},typeParameters:{validate:P(`TypeParameterDeclaration`,`TSTypeParameterDeclaration`),optional:!0},body:{validate:P(`ClassBody`)},superClass:{optional:!0,validate:P(`Expression`)},superTypeArguments:{validate:P(`TypeParameterInstantiation`,`TSTypeParameterInstantiation`),optional:!0},implements:{validate:j(`TSClassImplements`,`ClassImplements`),optional:!0},decorators:{validate:j(`Decorator`),optional:!0},mixins:{validate:P(`InterfaceExtends`),optional:!0}}}),L(`ClassDeclaration`,{inherits:`ClassExpression`,aliases:[`Scopable`,`Class`,`Statement`,`Declaration`],fields:{id:{validate:P(`Identifier`),optional:!0},typeParameters:{validate:P(`TypeParameterDeclaration`,`TSTypeParameterDeclaration`),optional:!0},body:{validate:P(`ClassBody`)},superClass:{optional:!0,validate:P(`Expression`)},superTypeArguments:{validate:P(`TypeParameterInstantiation`,`TSTypeParameterInstantiation`),optional:!0},implements:{validate:j(`TSClassImplements`,`ClassImplements`),optional:!0},decorators:{validate:j(`Decorator`),optional:!0},mixins:{validate:P(`InterfaceExtends`),optional:!0},declare:{validate:F(`boolean`),optional:!0},abstract:{validate:F(`boolean`),optional:!0}},validate:function(){let e=P(`Identifier`);return function(t,n,r){T(`ExportDefaultDeclaration`,t)||e(r,`id`,r.id)}}()});const Yc={attributes:{optional:!0,validate:j(`ImportAttribute`)}};L(`ExportAllDeclaration`,{visitor:[`source`,`attributes`],aliases:[`Statement`,`Declaration`,`ImportOrExportDeclaration`,`ExportDeclaration`],fields:{source:{validate:P(`StringLiteral`)},exportKind:k(N(`type`,`value`)),...Yc}}),L(`ExportDefaultDeclaration`,{visitor:[`declaration`],aliases:[`Statement`,`Declaration`,`ImportOrExportDeclaration`,`ExportDeclaration`],fields:{declaration:O(`TSDeclareFunction`,`FunctionDeclaration`,`ClassDeclaration`,`Expression`),exportKind:k(N(`value`))}}),L(`ExportNamedDeclaration`,{builder:[`declaration`,`specifiers`,`source`,`attributes`],visitor:[`declaration`,`specifiers`,`source`,`attributes`],aliases:[`Statement`,`Declaration`,`ImportOrExportDeclaration`,`ExportDeclaration`],fields:{declaration:{optional:!0,validate:I(P(`Declaration`),Object.assign(function(e,t,n){if(n&&e.specifiers.length)throw TypeError(`Only declaration or specifiers is allowed on ExportNamedDeclaration`);if(n&&e.source)throw TypeError(`Cannot export a declaration from a source`)},{oneOfNodeTypes:[`Declaration`]}))},...Yc,specifiers:{default:[],validate:Mc(function(){let e=P(`ExportSpecifier`,`ExportDefaultSpecifier`,`ExportNamespaceSpecifier`),t=P(`ExportSpecifier`);return Object.assign(function(n,r,i){(n.source?e:t)(n,r,i)},{oneOfNodeTypes:[`ExportSpecifier`,`ExportDefaultSpecifier`,`ExportNamespaceSpecifier`]})}())},source:{validate:P(`StringLiteral`),optional:!0},exportKind:k(N(`type`,`value`))}}),L(`ExportSpecifier`,{visitor:[`local`,`exported`],aliases:[`ModuleSpecifier`],fields:{local:{validate:P(`Identifier`)},exported:{validate:P(`Identifier`,`StringLiteral`)},exportKind:{validate:N(`type`,`value`),optional:!0}}}),L(`ForOfStatement`,{visitor:[`left`,`right`,`body`],builder:[`left`,`right`,`body`,`await`],aliases:[`Scopable`,`Statement`,`For`,`BlockParent`,`Loop`,`ForXStatement`],fields:{left:{validate:function(){let e=P(`VariableDeclaration`),t=P(`Identifier`,`MemberExpression`,`ArrayPattern`,`ObjectPattern`,`TSAsExpression`,`TSSatisfiesExpression`,`TSTypeAssertion`,`TSNonNullExpression`);return Object.assign(function(n,r,i){T(`VariableDeclaration`,i)?e(n,r,i):t(n,r,i)},{oneOfNodeTypes:[`VariableDeclaration`,`Identifier`,`MemberExpression`,`ArrayPattern`,`ObjectPattern`,`TSAsExpression`,`TSSatisfiesExpression`,`TSTypeAssertion`,`TSNonNullExpression`]})}()},right:{validate:P(`Expression`)},body:{validate:P(`Statement`)},await:{default:!1}}}),L(`ImportDeclaration`,{builder:[`specifiers`,`source`,`attributes`],visitor:[`specifiers`,`source`,`attributes`],aliases:[`Statement`,`Declaration`,`ImportOrExportDeclaration`],fields:{...Yc,module:{optional:!0,validate:F(`boolean`)},phase:{default:null,validate:N(`source`,`defer`)},specifiers:M(`ImportSpecifier`,`ImportDefaultSpecifier`,`ImportNamespaceSpecifier`),source:{validate:P(`StringLiteral`)},importKind:{validate:N(`type`,`typeof`,`value`),optional:!0}}}),L(`ImportDefaultSpecifier`,{visitor:[`local`],aliases:[`ModuleSpecifier`],fields:{local:{validate:P(`Identifier`)}}}),L(`ImportNamespaceSpecifier`,{visitor:[`local`],aliases:[`ModuleSpecifier`],fields:{local:{validate:P(`Identifier`)}}}),L(`ImportSpecifier`,{visitor:[`imported`,`local`],builder:[`local`,`imported`],aliases:[`ModuleSpecifier`],fields:{local:{validate:P(`Identifier`)},imported:{validate:P(`Identifier`,`StringLiteral`)},importKind:{validate:N(`type`,`typeof`,`value`),optional:!0}}}),L(`ImportExpression`,{visitor:[`source`,`options`],aliases:[`Expression`],fields:{phase:{default:null,validate:N(`source`,`defer`)},source:{validate:P(`Expression`)},options:{validate:P(`Expression`),optional:!0}}}),L(`MetaProperty`,{visitor:[`meta`,`property`],aliases:[`Expression`],fields:{meta:{validate:I(P(`Identifier`),Object.assign(function(e,t,n){let r;switch(n.name){case`function`:r=`sent`;break;case`new`:r=`target`;break;case`import`:r=`meta`;break}if(!T(`Identifier`,e.property,{name:r}))throw TypeError(`Unrecognised MetaProperty`)},{oneOfNodeTypes:[`Identifier`]}))},property:{validate:P(`Identifier`)}}});const Xc=()=>({abstract:{validate:F(`boolean`),default:!1,optional:!0},accessibility:{validate:N(`public`,`private`,`protected`),optional:!0},static:{default:!1},override:{optional:!0,validate:F(`boolean`),default:!1},computed:{default:!1},optional:{validate:F(`boolean`),optional:!0},key:{validate:I(function(){let e=P(`Identifier`,`StringLiteral`,`NumericLiteral`,`BigIntLiteral`),t=P(`Expression`);return function(n,r,i){(n.computed?t:e)(n,r,i)}}(),P(`Identifier`,`StringLiteral`,`NumericLiteral`,`BigIntLiteral`,`Expression`))}}),Zc=()=>({...Gc(),...Xc(),params:M(`FunctionParameter`,`TSParameterProperty`),kind:{validate:N(`get`,`set`,`method`,`constructor`),default:`method`},access:{validate:I(F(`string`),N(`public`,`private`,`protected`)),optional:!0},decorators:{validate:j(`Decorator`),optional:!0}});L(`ClassMethod`,{aliases:[`Function`,`Scopable`,`BlockParent`,`FunctionParent`,`Method`],builder:[`kind`,`key`,`params`,`body`,`computed`,`static`,`generator`,`async`],visitor:[`decorators`,`key`,`typeParameters`,`params`,`returnType`,`body`],...Wc(),fields:{...Zc(),...Kc(),body:{validate:P(`BlockStatement`)}}}),L(`ObjectPattern`,{visitor:[`decorators`,`properties`,`typeAnnotation`],builder:[`properties`],aliases:[`FunctionParameter`,`Pattern`,`PatternLike`,`LVal`],fields:{...Jc(),properties:M(`RestElement`,`ObjectProperty`)}}),L(`SpreadElement`,{visitor:[`argument`],aliases:[`UnaryLike`],deprecatedAlias:`SpreadProperty`,fields:{argument:{validate:P(`Expression`)}}}),L(`Super`,void 0),L(`TaggedTemplateExpression`,{visitor:[`tag`,`typeArguments`,`quasi`],builder:[`tag`,`quasi`],aliases:[`Expression`],fields:{tag:{validate:P(`Expression`)},quasi:{validate:P(`TemplateLiteral`)},typeArguments:{validate:P(`TypeParameterInstantiation`,`TSTypeParameterInstantiation`),optional:!0}}}),L(`TemplateElement`,{builder:[`value`,`tail`],fields:{value:{validate:I(Ic({raw:{validate:F(`string`)},cooked:{validate:F(`string`),optional:!0}}),function(e){let t=e.value.raw,n=!1,r=()=>{throw Error(`Internal @babel/types error.`)},{str:i,firstInvalidLoc:a}=un(`template`,t,0,0,0,{unterminated(){n=!0},strictNumericEscape:r,invalidEscapeSequence:r,numericSeparatorInEscapeSequence:r,unexpectedNumericSeparator:r,invalidDigit:r,invalidCodePoint:r});if(!n)throw Error(`Invalid raw`);e.value.cooked=a?null:i})},tail:{default:!1}}}),L(`TemplateLiteral`,{visitor:[`quasis`,`expressions`],aliases:[`Expression`,`Literal`],fields:{quasis:M(`TemplateElement`),expressions:{validate:I(F(`array`),Nc(P(`Expression`,`TSType`)),function(e,t,n){if(e.quasis.length!==n.length+1)throw TypeError(`Number of ${e.type} quasis should be exactly one more than the number of expressions.\nExpected ${n.length+1} quasis but got ${e.quasis.length}`)})}}}),L(`YieldExpression`,{builder:[`argument`,`delegate`],visitor:[`argument`],aliases:[`Expression`,`Terminatorless`],fields:{delegate:{validate:I(F(`boolean`),Object.assign(function(e,t,n){if(n&&!e.argument)throw TypeError(`Property delegate of YieldExpression cannot be true if there is no argument`)},{type:`boolean`})),default:!1},argument:{optional:!0,validate:P(`Expression`)}}}),L(`AwaitExpression`,{builder:[`argument`],visitor:[`argument`],aliases:[`Expression`,`Terminatorless`],fields:{argument:{validate:P(`Expression`)}}}),L(`Import`,{aliases:[`Expression`]}),L(`BigIntLiteral`,{builder:[`value`],fields:{value:{validate:F(`bigint`)}},aliases:[`Expression`,`Pureish`,`Literal`,`Immutable`]}),L(`ExportNamespaceSpecifier`,{visitor:[`exported`],aliases:[`ModuleSpecifier`],fields:{exported:{validate:P(`Identifier`)}}}),L(`OptionalMemberExpression`,{builder:[`object`,`property`,`computed`,`optional`],visitor:[`object`,`property`],aliases:[`Expression`],fields:{object:{validate:P(`Expression`)},property:{validate:function(){let e=P(`Identifier`),t=P(`Expression`);return Object.assign(function(n,r,i){(n.computed?t:e)(n,r,i)},{oneOfNodeTypes:[`Expression`,`Identifier`]})}()},computed:{default:!1},optional:{validate:I(F(`boolean`),Lc())}}}),L(`OptionalCallExpression`,{visitor:[`callee`,`typeArguments`,`arguments`],builder:[`callee`,`arguments`,`optional`],aliases:[`Expression`],fields:{callee:{validate:P(`Expression`)},arguments:M(`Expression`,`SpreadElement`,`ArgumentPlaceholder`),optional:{validate:I(F(`boolean`),Lc())},typeArguments:{validate:P(`TypeParameterInstantiation`,`TSTypeParameterInstantiation`),optional:!0}}}),L(`ClassProperty`,{visitor:[`decorators`,`variance`,`key`,`typeAnnotation`,`value`],builder:[`key`,`value`,`typeAnnotation`,`decorators`,`computed`,`static`],aliases:[`Property`],...Wc(),fields:{...Xc(),value:{validate:P(`Expression`),optional:!0},definite:{validate:F(`boolean`),optional:!0},typeAnnotation:{validate:P(`TypeAnnotation`,`TSTypeAnnotation`),optional:!0},decorators:{validate:j(`Decorator`),optional:!0},readonly:{validate:F(`boolean`),optional:!0},declare:{validate:F(`boolean`),optional:!0},variance:{validate:P(`Variance`),optional:!0}}}),L(`ClassPrivateProperty`,{visitor:[`decorators`,`variance`,`key`,`typeAnnotation`,`value`],builder:[`key`,`value`,`decorators`,`static`],aliases:[`Property`,`Private`],fields:{key:{validate:P(`PrivateName`)},value:{validate:P(`Expression`),optional:!0},typeAnnotation:{validate:P(`TypeAnnotation`,`TSTypeAnnotation`),optional:!0},decorators:{validate:j(`Decorator`),optional:!0},static:{validate:F(`boolean`),default:!1},readonly:{validate:F(`boolean`),optional:!0},optional:{validate:F(`boolean`),optional:!0},definite:{validate:F(`boolean`),optional:!0},variance:{validate:P(`Variance`),optional:!0}}}),L(`ClassPrivateMethod`,{builder:[`kind`,`key`,`params`,`body`,`static`],visitor:[`decorators`,`key`,`typeParameters`,`params`,`returnType`,`body`],aliases:[`Function`,`Scopable`,`BlockParent`,`FunctionParent`,`Method`,`Private`],fields:{...Zc(),...Kc(),kind:{validate:N(`get`,`set`,`method`),default:`method`},key:{validate:P(`PrivateName`)},body:{validate:P(`BlockStatement`)}}}),L(`PrivateName`,{visitor:[`id`],aliases:[`Private`],fields:{id:{validate:P(`Identifier`)}}}),L(`StaticBlock`,{visitor:[`body`],fields:{body:M(`Statement`)},aliases:[`Scopable`,`BlockParent`,`FunctionParent`]}),L(`ImportAttribute`,{visitor:[`key`,`value`],fields:{key:{validate:P(`Identifier`,`StringLiteral`)},value:{validate:P(`StringLiteral`)}}});const R=Vc(`Flow`),Qc=e=>{let t=e===`DeclareClass`;R(e,{builder:[`id`,`typeParameters`,`extends`,`body`],visitor:[`id`,`typeParameters`,`extends`,...t?[`mixins`,`implements`]:[],`body`],aliases:[`FlowDeclaration`,`Statement`,`Declaration`],fields:{id:O(`Identifier`),typeParameters:A(`TypeParameterDeclaration`),extends:k(j(`InterfaceExtends`)),...t?{mixins:k(j(`InterfaceExtends`)),implements:k(j(`ClassImplements`))}:{},body:O(`ObjectTypeAnnotation`)}})};R(`AnyTypeAnnotation`,{aliases:[`FlowType`,`FlowBaseAnnotation`]}),R(`ArrayTypeAnnotation`,{visitor:[`elementType`],aliases:[`FlowType`],fields:{elementType:O(`FlowType`)}}),R(`BooleanTypeAnnotation`,{aliases:[`FlowType`,`FlowBaseAnnotation`]}),R(`BooleanLiteralTypeAnnotation`,{builder:[`value`],aliases:[`FlowType`],fields:{value:D(F(`boolean`))}}),R(`NullLiteralTypeAnnotation`,{aliases:[`FlowType`,`FlowBaseAnnotation`]}),R(`ClassImplements`,{visitor:[`id`,`typeParameters`],fields:{id:O(`Identifier`),typeParameters:A(`TypeParameterInstantiation`)}}),Qc(`DeclareClass`),R(`DeclareFunction`,{builder:[`id`],visitor:[`id`,`predicate`],aliases:[`FlowDeclaration`,`Statement`,`Declaration`],fields:{id:O(`Identifier`),predicate:A(`DeclaredPredicate`)}}),Qc(`DeclareInterface`),R(`DeclareModule`,{builder:[`id`,`body`,`kind`],visitor:[`id`,`body`],aliases:[`FlowDeclaration`,`Statement`,`Declaration`],fields:{id:O(`Identifier`,`StringLiteral`),body:O(`BlockStatement`),kind:k(N(`CommonJS`,`ES`))}}),R(`DeclareModuleExports`,{visitor:[`typeAnnotation`],aliases:[`FlowDeclaration`,`Statement`,`Declaration`],fields:{typeAnnotation:O(`TypeAnnotation`)}}),R(`DeclareTypeAlias`,{visitor:[`id`,`typeParameters`,`right`],aliases:[`FlowDeclaration`,`Statement`,`Declaration`],fields:{id:O(`Identifier`),typeParameters:A(`TypeParameterDeclaration`),right:O(`FlowType`)}}),R(`DeclareOpaqueType`,{visitor:[`id`,`typeParameters`,`supertype`],aliases:[`FlowDeclaration`,`Statement`,`Declaration`],fields:{id:O(`Identifier`),typeParameters:A(`TypeParameterDeclaration`),supertype:A(`FlowType`),impltype:A(`FlowType`)}}),R(`DeclareVariable`,{visitor:[`id`],aliases:[`FlowDeclaration`,`Statement`,`Declaration`],fields:{id:O(`Identifier`)}}),R(`DeclareExportDeclaration`,{visitor:[`declaration`,`specifiers`,`source`,`attributes`],aliases:[`FlowDeclaration`,`Statement`,`Declaration`],fields:{declaration:A(`Flow`),specifiers:k(j(`ExportSpecifier`,`ExportNamespaceSpecifier`)),source:A(`StringLiteral`),default:k(F(`boolean`)),...Yc}}),R(`DeclareExportAllDeclaration`,{visitor:[`source`,`attributes`],aliases:[`FlowDeclaration`,`Statement`,`Declaration`],fields:{source:O(`StringLiteral`),exportKind:k(N(`type`,`value`)),...Yc}}),R(`DeclaredPredicate`,{visitor:[`value`],aliases:[`FlowPredicate`],fields:{value:O(`Flow`)}}),R(`ExistsTypeAnnotation`,{aliases:[`FlowType`]}),R(`FunctionTypeAnnotation`,{builder:[`typeParameters`,`params`,`rest`,`returnType`],visitor:[`typeParameters`,`this`,`params`,`rest`,`returnType`],aliases:[`FlowType`],fields:{typeParameters:A(`TypeParameterDeclaration`),params:M(`FunctionTypeParam`),rest:A(`FunctionTypeParam`),this:A(`FunctionTypeParam`),returnType:O(`FlowType`)}}),R(`FunctionTypeParam`,{visitor:[`name`,`typeAnnotation`],fields:{name:A(`Identifier`),typeAnnotation:O(`FlowType`),optional:k(F(`boolean`))}}),R(`GenericTypeAnnotation`,{visitor:[`id`,`typeParameters`],aliases:[`FlowType`],fields:{id:O(`Identifier`,`QualifiedTypeIdentifier`),typeParameters:A(`TypeParameterInstantiation`)}}),R(`InferredPredicate`,{aliases:[`FlowPredicate`]}),R(`InterfaceExtends`,{visitor:[`id`,`typeParameters`],fields:{id:O(`Identifier`,`QualifiedTypeIdentifier`),typeParameters:A(`TypeParameterInstantiation`)}}),Qc(`InterfaceDeclaration`),R(`InterfaceTypeAnnotation`,{visitor:[`extends`,`body`],aliases:[`FlowType`],fields:{extends:k(j(`InterfaceExtends`)),body:O(`ObjectTypeAnnotation`)}}),R(`IntersectionTypeAnnotation`,{visitor:[`types`],aliases:[`FlowType`],fields:{types:D(j(`FlowType`))}}),R(`MixedTypeAnnotation`,{aliases:[`FlowType`,`FlowBaseAnnotation`]}),R(`EmptyTypeAnnotation`,{aliases:[`FlowType`,`FlowBaseAnnotation`]}),R(`NullableTypeAnnotation`,{visitor:[`typeAnnotation`],aliases:[`FlowType`],fields:{typeAnnotation:O(`FlowType`)}}),R(`NumberLiteralTypeAnnotation`,{builder:[`value`],aliases:[`FlowType`],fields:{value:D(F(`number`))}}),R(`NumberTypeAnnotation`,{aliases:[`FlowType`,`FlowBaseAnnotation`]}),R(`ObjectTypeAnnotation`,{visitor:[`properties`,`indexers`,`callProperties`,`internalSlots`],aliases:[`FlowType`],builder:[`properties`,`indexers`,`callProperties`,`internalSlots`,`exact`],fields:{properties:D(j(`ObjectTypeProperty`,`ObjectTypeSpreadProperty`)),indexers:{validate:j(`ObjectTypeIndexer`),optional:!1,default:[]},callProperties:{validate:j(`ObjectTypeCallProperty`),optional:!1,default:[]},internalSlots:{validate:j(`ObjectTypeInternalSlot`),optional:!1,default:[]},exact:{validate:F(`boolean`),default:!1},inexact:k(F(`boolean`))}}),R(`ObjectTypeInternalSlot`,{visitor:[`id`,`value`],builder:[`id`,`value`,`optional`,`static`,`method`],aliases:[`UserWhitespacable`],fields:{id:O(`Identifier`),value:O(`FlowType`),optional:D(F(`boolean`)),static:D(F(`boolean`)),method:D(F(`boolean`))}}),R(`ObjectTypeCallProperty`,{visitor:[`value`],aliases:[`UserWhitespacable`],fields:{value:O(`FlowType`),static:jc(F(`boolean`),!1)}}),R(`ObjectTypeIndexer`,{visitor:[`variance`,`id`,`key`,`value`],builder:[`id`,`key`,`value`,`variance`],aliases:[`UserWhitespacable`],fields:{id:A(`Identifier`),key:O(`FlowType`),value:O(`FlowType`),static:jc(F(`boolean`),!1),variance:A(`Variance`)}}),R(`ObjectTypeProperty`,{visitor:[`key`,`value`,`variance`],aliases:[`UserWhitespacable`],fields:{key:O(`Identifier`,`StringLiteral`),value:O(`FlowType`),kind:{validate:N(`init`,`get`,`set`),default:`init`,optional:!1},static:jc(F(`boolean`),!1),proto:jc(F(`boolean`),!1),optional:jc(F(`boolean`),!1),variance:A(`Variance`),method:jc(F(`boolean`),!1)}}),R(`ObjectTypeSpreadProperty`,{visitor:[`argument`],aliases:[`UserWhitespacable`],fields:{argument:O(`FlowType`)}}),R(`OpaqueType`,{visitor:[`id`,`typeParameters`,`supertype`,`impltype`],aliases:[`FlowDeclaration`,`Statement`,`Declaration`],fields:{id:O(`Identifier`),typeParameters:A(`TypeParameterDeclaration`),supertype:A(`FlowType`),impltype:O(`FlowType`)}}),R(`QualifiedTypeIdentifier`,{visitor:[`qualification`,`id`],builder:[`id`,`qualification`],fields:{id:O(`Identifier`),qualification:O(`Identifier`,`QualifiedTypeIdentifier`)}}),R(`StringLiteralTypeAnnotation`,{builder:[`value`],aliases:[`FlowType`],fields:{value:D(F(`string`))}}),R(`StringTypeAnnotation`,{aliases:[`FlowType`,`FlowBaseAnnotation`]}),R(`SymbolTypeAnnotation`,{aliases:[`FlowType`,`FlowBaseAnnotation`]}),R(`ThisTypeAnnotation`,{aliases:[`FlowType`,`FlowBaseAnnotation`]}),R(`TupleTypeAnnotation`,{visitor:[`types`],aliases:[`FlowType`],fields:{types:D(j(`FlowType`))}}),R(`TypeofTypeAnnotation`,{visitor:[`argument`],aliases:[`FlowType`],fields:{argument:O(`FlowType`)}}),R(`TypeAlias`,{visitor:[`id`,`typeParameters`,`right`],aliases:[`FlowDeclaration`,`Statement`,`Declaration`],fields:{id:O(`Identifier`),typeParameters:A(`TypeParameterDeclaration`),right:O(`FlowType`)}}),R(`TypeAnnotation`,{visitor:[`typeAnnotation`],fields:{typeAnnotation:O(`FlowType`)}}),R(`TypeCastExpression`,{visitor:[`expression`,`typeAnnotation`],aliases:[`ExpressionWrapper`,`Expression`],fields:{expression:O(`Expression`),typeAnnotation:O(`TypeAnnotation`)}}),R(`TypeParameter`,{builder:[`name`,`bound`,`default`,`variance`],visitor:[`bound`,`default`,`variance`],fields:{name:D(F(`string`)),bound:A(`TypeAnnotation`),default:A(`FlowType`),variance:A(`Variance`)}}),R(`TypeParameterDeclaration`,{visitor:[`params`],fields:{params:D(j(`TypeParameter`))}}),R(`TypeParameterInstantiation`,{visitor:[`params`],fields:{params:D(j(`FlowType`))}}),R(`UnionTypeAnnotation`,{visitor:[`types`],aliases:[`FlowType`],fields:{types:D(j(`FlowType`))}}),R(`Variance`,{builder:[`kind`],fields:{kind:D(N(`minus`,`plus`))}}),R(`VoidTypeAnnotation`,{aliases:[`FlowType`,`FlowBaseAnnotation`]}),R(`EnumDeclaration`,{aliases:[`Statement`,`Declaration`],visitor:[`id`,`body`],fields:{id:O(`Identifier`),body:O(`EnumBooleanBody`,`EnumNumberBody`,`EnumStringBody`,`EnumSymbolBody`)}});const $c={explicitType:jc(F(`boolean`),!1),hasUnknownMembers:jc(F(`boolean`),!1)};R(`EnumBooleanBody`,{aliases:[`EnumBody`],visitor:[`members`],fields:{...$c,members:M(`EnumBooleanMember`)}}),R(`EnumNumberBody`,{aliases:[`EnumBody`],visitor:[`members`],fields:{...$c,members:M(`EnumNumberMember`)}}),R(`EnumStringBody`,{aliases:[`EnumBody`],visitor:[`members`],fields:{...$c,members:M(`EnumStringMember`,`EnumDefaultedMember`)}}),R(`EnumSymbolBody`,{aliases:[`EnumBody`],visitor:[`members`],fields:{members:M(`EnumDefaultedMember`),hasUnknownMembers:jc(F(`boolean`),!1)}}),R(`EnumBooleanMember`,{aliases:[`EnumMember`],visitor:[`id`,`init`],fields:{id:O(`Identifier`),init:O(`BooleanLiteral`)}}),R(`EnumNumberMember`,{aliases:[`EnumMember`],visitor:[`id`,`init`],fields:{id:O(`Identifier`),init:O(`NumericLiteral`)}}),R(`EnumStringMember`,{aliases:[`EnumMember`],visitor:[`id`,`init`],fields:{id:O(`Identifier`),init:O(`StringLiteral`)}}),R(`EnumDefaultedMember`,{aliases:[`EnumMember`],visitor:[`id`],fields:{id:O(`Identifier`)}}),R(`IndexedAccessType`,{visitor:[`objectType`,`indexType`],aliases:[`FlowType`],fields:{objectType:O(`FlowType`),indexType:O(`FlowType`)}}),R(`OptionalIndexedAccessType`,{visitor:[`objectType`,`indexType`],aliases:[`FlowType`],fields:{objectType:O(`FlowType`),indexType:O(`FlowType`),optional:jc(F(`boolean`),!1)}});const el=Vc(`JSX`);el(`JSXAttribute`,{visitor:[`name`,`value`],aliases:[`Immutable`],fields:{name:{validate:P(`JSXIdentifier`,`JSXNamespacedName`)},value:{optional:!0,validate:P(`JSXElement`,`JSXFragment`,`StringLiteral`,`JSXExpressionContainer`)}}}),el(`JSXClosingElement`,{visitor:[`name`],aliases:[`Immutable`],fields:{name:{validate:P(`JSXIdentifier`,`JSXMemberExpression`,`JSXNamespacedName`)}}}),el(`JSXElement`,{builder:[`openingElement`,`closingElement`,`children`],visitor:[`openingElement`,`children`,`closingElement`],aliases:[`Immutable`,`Expression`],fields:{openingElement:{validate:P(`JSXOpeningElement`)},closingElement:{optional:!0,validate:P(`JSXClosingElement`)},children:M(`JSXText`,`JSXExpressionContainer`,`JSXSpreadChild`,`JSXElement`,`JSXFragment`)}}),el(`JSXEmptyExpression`,{}),el(`JSXExpressionContainer`,{visitor:[`expression`],aliases:[`Immutable`],fields:{expression:{validate:P(`Expression`,`JSXEmptyExpression`)}}}),el(`JSXSpreadChild`,{visitor:[`expression`],aliases:[`Immutable`],fields:{expression:{validate:P(`Expression`)}}}),el(`JSXIdentifier`,{builder:[`name`],fields:{name:{validate:F(`string`)}}}),el(`JSXMemberExpression`,{visitor:[`object`,`property`],fields:{object:{validate:P(`JSXMemberExpression`,`JSXIdentifier`)},property:{validate:P(`JSXIdentifier`)}}}),el(`JSXNamespacedName`,{visitor:[`namespace`,`name`],fields:{namespace:{validate:P(`JSXIdentifier`)},name:{validate:P(`JSXIdentifier`)}}}),el(`JSXOpeningElement`,{builder:[`name`,`attributes`,`selfClosing`],visitor:[`name`,`typeArguments`,`attributes`],aliases:[`Immutable`],fields:{name:{validate:P(`JSXIdentifier`,`JSXMemberExpression`,`JSXNamespacedName`)},selfClosing:{default:!1},attributes:M(`JSXAttribute`,`JSXSpreadAttribute`),typeArguments:{validate:P(`TypeParameterInstantiation`,`TSTypeParameterInstantiation`),optional:!0}}}),el(`JSXSpreadAttribute`,{visitor:[`argument`],fields:{argument:{validate:P(`Expression`)}}}),el(`JSXText`,{aliases:[`Immutable`],builder:[`value`],fields:{value:{validate:F(`string`)}}}),el(`JSXFragment`,{builder:[`openingFragment`,`closingFragment`,`children`],visitor:[`openingFragment`,`children`,`closingFragment`],aliases:[`Immutable`,`Expression`],fields:{openingFragment:{validate:P(`JSXOpeningFragment`)},closingFragment:{validate:P(`JSXClosingFragment`)},children:M(`JSXText`,`JSXExpressionContainer`,`JSXSpreadChild`,`JSXElement`,`JSXFragment`)}}),el(`JSXOpeningFragment`,{aliases:[`Immutable`]}),el(`JSXClosingFragment`,{aliases:[`Immutable`]});const tl=[`Identifier`,`StringLiteral`,`Expression`,`Statement`,`Declaration`,`BlockStatement`,`ClassBody`,`Pattern`],nl={Declaration:[`Statement`],Pattern:[`PatternLike`,`LVal`]};for(let e of tl){let t=wc[e];t?.length&&(nl[e]=t)}const rl={};Object.keys(nl).forEach(e=>{nl[e].forEach(t=>{Object.hasOwn(rl,t)||(rl[t]=[]),rl[t].push(e)})});const il=Vc(`Miscellaneous`);il(`Placeholder`,{visitor:[],builder:[`expectedNode`,`name`],fields:{name:{validate:P(`Identifier`)},expectedNode:{validate:N(...tl)},...Jc()}}),il(`V8IntrinsicIdentifier`,{builder:[`name`],fields:{name:{validate:F(`string`)}}}),Hc(`ArgumentPlaceholder`,{}),Hc(`BindExpression`,{visitor:[`object`,`callee`],aliases:[`Expression`],fields:{object:{validate:P(`Expression`)},callee:{validate:P(`Expression`)}}}),Hc(`ClassAccessorProperty`,{visitor:[`decorators`,`key`,`typeAnnotation`,`value`],builder:[`key`,`value`,`typeAnnotation`,`decorators`,`computed`,`static`],aliases:[`Property`,`Accessor`],...Wc(!0),fields:{...Xc(),key:{validate:I(function(){let e=P(`Identifier`,`StringLiteral`,`NumericLiteral`,`BigIntLiteral`,`PrivateName`),t=P(`Expression`);return function(n,r,i){(n.computed?t:e)(n,r,i)}}(),P(`Identifier`,`StringLiteral`,`NumericLiteral`,`BigIntLiteral`,`Expression`,`PrivateName`))},value:{validate:P(`Expression`),optional:!0},definite:{validate:F(`boolean`),optional:!0},typeAnnotation:{validate:P(`TypeAnnotation`,`TSTypeAnnotation`),optional:!0},decorators:{validate:j(`Decorator`),optional:!0},readonly:{validate:F(`boolean`),optional:!0},declare:{validate:F(`boolean`),optional:!0},variance:{validate:P(`Variance`),optional:!0}}}),Hc(`Decorator`,{visitor:[`expression`],fields:{expression:{validate:P(`Expression`)}}}),Hc(`DoExpression`,{visitor:[`body`],builder:[`body`,`async`],aliases:[`Expression`],fields:{body:{validate:P(`BlockStatement`)},async:{validate:F(`boolean`),default:!1}}}),Hc(`ExportDefaultSpecifier`,{visitor:[`exported`],aliases:[`ModuleSpecifier`],fields:{exported:{validate:P(`Identifier`)}}}),Hc(`ModuleExpression`,{visitor:[`body`],fields:{body:{validate:P(`Program`)}},aliases:[`Expression`]}),Hc(`TopicReference`,{aliases:[`Expression`]}),Hc(`VoidPattern`,{aliases:[`Pattern`,`PatternLike`,`FunctionParameter`]});const z=Vc(`TypeScript`),al=F(`boolean`),ol=()=>({returnType:{validate:P(`TSTypeAnnotation`),optional:!0},typeParameters:{validate:P(`TSTypeParameterDeclaration`),optional:!0}});z(`TSParameterProperty`,{aliases:[],visitor:[`parameter`],fields:{accessibility:{validate:N(`public`,`private`,`protected`),optional:!0},readonly:{validate:F(`boolean`),optional:!0},parameter:{validate:P(`Identifier`,`AssignmentPattern`)},override:{validate:F(`boolean`),optional:!0},decorators:{validate:j(`Decorator`),optional:!0}}}),z(`TSDeclareFunction`,{aliases:[`Statement`,`Declaration`],visitor:[`id`,`typeParameters`,`params`,`returnType`],fields:{...qc(),...ol()}}),z(`TSDeclareMethod`,{visitor:[`decorators`,`key`,`typeParameters`,`params`,`returnType`],...Wc(),fields:{...Zc(),...ol()}}),z(`TSQualifiedName`,{aliases:[`TSEntityName`],visitor:[`left`,`right`],fields:{left:O(`TSEntityName`),right:O(`Identifier`)}});const sl=()=>({typeParameters:A(`TSTypeParameterDeclaration`),params:M(`ArrayPattern`,`Identifier`,`ObjectPattern`,`RestElement`),returnType:A(`TSTypeAnnotation`)}),cl={aliases:[`TSTypeElement`],visitor:[`typeParameters`,`params`,`returnType`],fields:sl()};z(`TSCallSignatureDeclaration`,cl),z(`TSConstructSignatureDeclaration`,cl);const ll=()=>({key:O(`Expression`),computed:{default:!1},optional:k(al)});z(`TSPropertySignature`,{aliases:[`TSTypeElement`],visitor:[`key`,`typeAnnotation`],fields:{...ll(),readonly:k(al),typeAnnotation:A(`TSTypeAnnotation`),kind:{optional:!0,validate:N(`get`,`set`)}}}),z(`TSMethodSignature`,{aliases:[`TSTypeElement`],visitor:[`key`,`typeParameters`,`params`,`returnType`],fields:{...sl(),...ll(),kind:{validate:N(`method`,`get`,`set`),default:`method`}}}),z(`TSIndexSignature`,{aliases:[`TSTypeElement`],visitor:[`parameters`,`typeAnnotation`],fields:{readonly:k(al),static:k(al),parameters:M(`Identifier`),typeAnnotation:A(`TSTypeAnnotation`)}});for(let e of[`TSAnyKeyword`,`TSBooleanKeyword`,`TSBigIntKeyword`,`TSIntrinsicKeyword`,`TSNeverKeyword`,`TSNullKeyword`,`TSNumberKeyword`,`TSObjectKeyword`,`TSStringKeyword`,`TSSymbolKeyword`,`TSUndefinedKeyword`,`TSUnknownKeyword`,`TSVoidKeyword`])z(e,{aliases:[`TSType`,`TSBaseType`],visitor:[],fields:{}});z(`TSThisType`,{aliases:[`TSType`,`TSBaseType`],visitor:[],fields:{}});const ul={aliases:[`TSType`],visitor:[`typeParameters`,`params`,`returnType`]};z(`TSFunctionType`,{...ul,fields:sl()}),z(`TSConstructorType`,{...ul,fields:{...sl(),abstract:k(al)}}),z(`TSTypeReference`,{aliases:[`TSType`],visitor:[`typeName`,`typeArguments`],fields:{typeName:O(`TSEntityName`),typeArguments:A(`TSTypeParameterInstantiation`)}}),z(`TSTypePredicate`,{aliases:[`TSType`],visitor:[`parameterName`,`typeAnnotation`],builder:[`parameterName`,`typeAnnotation`,`asserts`],fields:{parameterName:O(`Identifier`,`TSThisType`),typeAnnotation:A(`TSTypeAnnotation`),asserts:k(al)}}),z(`TSTypeQuery`,{aliases:[`TSType`],visitor:[`exprName`,`typeArguments`],fields:{exprName:O(`TSEntityName`,`TSImportType`),typeArguments:A(`TSTypeParameterInstantiation`)}}),z(`TSTypeLiteral`,{aliases:[`TSType`],visitor:[`members`],fields:{members:M(`TSTypeElement`)}}),z(`TSArrayType`,{aliases:[`TSType`],visitor:[`elementType`],fields:{elementType:O(`TSType`)}}),z(`TSTupleType`,{aliases:[`TSType`],visitor:[`elementTypes`],fields:{elementTypes:M(`TSType`,`TSNamedTupleMember`)}}),z(`TSOptionalType`,{aliases:[`TSType`],visitor:[`typeAnnotation`],fields:{typeAnnotation:O(`TSType`)}}),z(`TSRestType`,{aliases:[`TSType`],visitor:[`typeAnnotation`],fields:{typeAnnotation:O(`TSType`)}}),z(`TSNamedTupleMember`,{visitor:[`label`,`elementType`],builder:[`label`,`elementType`,`optional`],fields:{label:O(`Identifier`),optional:{validate:al,default:!1},elementType:O(`TSType`)}});const dl={aliases:[`TSType`],visitor:[`types`],fields:{types:M(`TSType`)}};z(`TSUnionType`,dl),z(`TSIntersectionType`,dl),z(`TSConditionalType`,{aliases:[`TSType`],visitor:[`checkType`,`extendsType`,`trueType`,`falseType`],fields:{checkType:O(`TSType`),extendsType:O(`TSType`),trueType:O(`TSType`),falseType:O(`TSType`)}}),z(`TSInferType`,{aliases:[`TSType`],visitor:[`typeParameter`],fields:{typeParameter:O(`TSTypeParameter`)}}),z(`TSParenthesizedType`,{aliases:[`TSType`],visitor:[`typeAnnotation`],fields:{typeAnnotation:O(`TSType`)}}),z(`TSTypeOperator`,{aliases:[`TSType`],visitor:[`typeAnnotation`],builder:[`typeAnnotation`,`operator`],fields:{operator:{validate:N(`keyof`,`readonly`,`unique`),default:void 0},typeAnnotation:O(`TSType`)}}),z(`TSIndexedAccessType`,{aliases:[`TSType`],visitor:[`objectType`,`indexType`],fields:{objectType:O(`TSType`),indexType:O(`TSType`)}}),z(`TSMappedType`,{aliases:[`TSType`],visitor:[`key`,`constraint`,`nameType`,`typeAnnotation`],builder:[`key`,`constraint`,`nameType`,`typeAnnotation`],fields:{key:O(`Identifier`),constraint:O(`TSType`),readonly:k(N(!0,!1,`+`,`-`)),optional:k(N(!0,!1,`+`,`-`)),typeAnnotation:A(`TSType`),nameType:A(`TSType`)}}),z(`TSTemplateLiteralType`,{aliases:[`TSType`,`TSBaseType`],visitor:[`quasis`,`types`],fields:{quasis:M(`TemplateElement`),types:{validate:I(F(`array`),Nc(P(`TSType`)),function(e,t,n){if(e.quasis.length!==n.length+1)throw TypeError(`Number of ${e.type} quasis should be exactly one more than the number of types.\nExpected ${n.length+1} quasis but got ${e.quasis.length}`)})}}}),z(`TSLiteralType`,{aliases:[`TSType`,`TSBaseType`],visitor:[`literal`],fields:{literal:{validate:function(){let e=P(`NumericLiteral`,`BigIntLiteral`),t=N(`-`),n=P(`NumericLiteral`,`StringLiteral`,`BooleanLiteral`,`BigIntLiteral`,`TemplateLiteral`),r=function(r,i,a){T(`UnaryExpression`,a)?(t(a,`operator`,a.operator),e(a,`argument`,a.argument)):n(r,i,a)};return r.oneOfNodeTypes=[`NumericLiteral`,`StringLiteral`,`BooleanLiteral`,`BigIntLiteral`,`TemplateLiteral`,`UnaryExpression`],r}()}}}),z(`TSClassImplements`,{aliases:[`TSType`],visitor:[`expression`,`typeArguments`],fields:{expression:O(`Expression`),typeArguments:A(`TSTypeParameterInstantiation`)}}),z(`TSInterfaceHeritage`,{aliases:[`TSType`],visitor:[`expression`,`typeArguments`],fields:{expression:O(`Expression`),typeArguments:A(`TSTypeParameterInstantiation`)}}),z(`TSInterfaceDeclaration`,{aliases:[`Statement`,`Declaration`],visitor:[`id`,`typeParameters`,`extends`,`body`],fields:{declare:k(al),id:O(`Identifier`),typeParameters:A(`TSTypeParameterDeclaration`),extends:k(j(`TSClassImplements`)),body:O(`TSInterfaceBody`)}}),z(`TSInterfaceBody`,{visitor:[`body`],fields:{body:M(`TSTypeElement`)}}),z(`TSTypeAliasDeclaration`,{aliases:[`Statement`,`Declaration`],visitor:[`id`,`typeParameters`,`typeAnnotation`],fields:{declare:k(al),id:O(`Identifier`),typeParameters:A(`TSTypeParameterDeclaration`),typeAnnotation:O(`TSType`)}}),z(`TSInstantiationExpression`,{aliases:[`Expression`],visitor:[`expression`,`typeArguments`],fields:{expression:O(`Expression`),typeArguments:A(`TSTypeParameterInstantiation`)}});const fl={aliases:[`Expression`,`LVal`,`PatternLike`],visitor:[`expression`,`typeAnnotation`],fields:{expression:O(`Expression`),typeAnnotation:O(`TSType`)}};z(`TSAsExpression`,fl),z(`TSSatisfiesExpression`,fl),z(`TSTypeAssertion`,{aliases:[`Expression`,`LVal`,`PatternLike`],visitor:[`typeAnnotation`,`expression`],fields:{typeAnnotation:O(`TSType`),expression:O(`Expression`)}}),z(`TSEnumBody`,{visitor:[`members`],fields:{members:M(`TSEnumMember`)}}),z(`TSEnumDeclaration`,{aliases:[`Statement`,`Declaration`],visitor:[`id`,`body`],fields:{declare:k(al),const:k(al),id:O(`Identifier`),body:O(`TSEnumBody`)}}),z(`TSEnumMember`,{visitor:[`id`,`initializer`],fields:{id:O(`Identifier`,`StringLiteral`),initializer:A(`Expression`)}}),z(`TSModuleDeclaration`,{aliases:[`Statement`,`Declaration`],visitor:[`id`,`body`],fields:{kind:{validate:N(`global`,`namespace`),default:`namespace`},declare:k(al),id:{validate:I(P(`TSEntityName`,`StringLiteral`),Object.assign(function(e,t,n){if(e.kind===`namespace`&&T(`StringLiteral`,n))throw TypeError(`TSModuleDeclaration of kind 'namespace' cannot have a StringLiteral id.`)},{oneOfNodeTypes:[`TSEntityName`,`StringLiteral`]}))},body:O(`TSModuleBlock`)}}),z(`TSModuleBlock`,{aliases:[`Scopable`,`Block`,`BlockParent`,`FunctionParent`],visitor:[`body`],fields:{body:M(`Statement`)}}),z(`TSImportType`,{aliases:[`TSType`],builder:[`source`,`qualifier`,`typeArguments`],visitor:[`source`,`options`,`qualifier`,`typeArguments`],fields:{source:O(`StringLiteral`),qualifier:A(`TSEntityName`),typeArguments:A(`TSTypeParameterInstantiation`),options:{validate:P(`ObjectExpression`),optional:!0}}}),z(`TSImportEqualsDeclaration`,{aliases:[`Statement`,`Declaration`],visitor:[`id`,`moduleReference`],fields:{id:O(`Identifier`),moduleReference:O(`TSEntityName`,`TSExternalModuleReference`),importKind:{validate:N(`type`,`value`),optional:!0}}}),z(`TSExternalModuleReference`,{visitor:[`expression`],fields:{expression:O(`StringLiteral`)}}),z(`TSNonNullExpression`,{aliases:[`Expression`,`LVal`,`PatternLike`],visitor:[`expression`],fields:{expression:O(`Expression`)}}),z(`TSExportAssignment`,{aliases:[`Statement`],visitor:[`expression`],fields:{expression:O(`Expression`)}}),z(`TSNamespaceExportDeclaration`,{aliases:[`Statement`],visitor:[`id`],fields:{id:O(`Identifier`)}}),z(`TSTypeAnnotation`,{visitor:[`typeAnnotation`],fields:{typeAnnotation:{validate:P(`TSType`)}}}),z(`TSTypeParameterInstantiation`,{visitor:[`params`],fields:{params:M(`TSType`)}}),z(`TSTypeParameterDeclaration`,{visitor:[`params`],fields:{params:M(`TSTypeParameter`)}}),z(`TSTypeParameter`,{builder:[`constraint`,`default`,`name`],visitor:[`name`,`constraint`,`default`],fields:{name:{validate:P(`Identifier`)},in:{validate:F(`boolean`),optional:!0},out:{validate:F(`boolean`),optional:!0},const:{validate:F(`boolean`),optional:!0},constraint:{validate:P(`TSType`),optional:!0},default:{validate:P(`TSType`),optional:!0}}});const pl={ModuleDeclaration:`ImportOrExportDeclaration`};Object.keys(pl).forEach(e=>{E[e]=E[pl[e]]});for(let{types:e,set:t}of Pc)for(let n of e){let e=E[n];e?e.forEach(t.add,t):t.add(n)}const ml=[].concat(Object.keys(Cc),Object.keys(E),Object.keys(Dc));function hl(e,t,n){if(!e)return;let r=Tc[e.type];if(!r)return;let i=r[t];_l(e,t,n,i),vl(e,t,n)}function gl(e,t,n,r,i){if(e?.validate&&!(e.optional&&r==null)&&(e.validate(t,n,r),i)){let e=r.type;if(e==null)return;Oc[e]?.(t,n,r)}}function _l(e,t,n,r){r?.validate&&(r.optional&&n==null||r.validate(e,t,n))}function vl(e,t,n){let r=n?.type;r!=null&&Oc[r]?.(e,t,n)}const{validateInternal:B}=Object.freeze({__proto__:null,default:hl,validateChild:vl,validateField:_l,validateInternal:gl}),{NODE_FIELDS:V}=Uc;function yl(e){let t={type:`ArrayExpression`,elements:e},n=V.ArrayExpression;return B(n.elements,t,`elements`,e,1),t}function bl(e,t,n){let r={type:`AssignmentExpression`,operator:e,left:t,right:n},i=V.AssignmentExpression;return B(i.operator,r,`operator`,e),B(i.left,r,`left`,t,1),B(i.right,r,`right`,n,1),r}function xl(e,t,n){let r={type:`BinaryExpression`,operator:e,left:t,right:n},i=V.BinaryExpression;return B(i.operator,r,`operator`,e),B(i.left,r,`left`,t,1),B(i.right,r,`right`,n,1),r}function Sl(e){let t={type:`InterpreterDirective`,value:e},n=V.InterpreterDirective;return B(n.value,t,`value`,e),t}function Cl(e){let t={type:`Directive`,value:e},n=V.Directive;return B(n.value,t,`value`,e,1),t}function wl(e){let t={type:`DirectiveLiteral`,value:e},n=V.DirectiveLiteral;return B(n.value,t,`value`,e),t}function Tl(e,t=[]){let n={type:`BlockStatement`,body:e,directives:t},r=V.BlockStatement;return B(r.body,n,`body`,e,1),B(r.directives,n,`directives`,t,1),n}function El(e=null){let t={type:`BreakStatement`,label:e},n=V.BreakStatement;return B(n.label,t,`label`,e,1),t}function Dl(e,t){let n={type:`CallExpression`,callee:e,arguments:t},r=V.CallExpression;return B(r.callee,n,`callee`,e,1),B(r.arguments,n,`arguments`,t,1),n}function Ol(e=null,t){let n={type:`CatchClause`,param:e,body:t},r=V.CatchClause;return B(r.param,n,`param`,e,1),B(r.body,n,`body`,t,1),n}function kl(e,t,n){let r={type:`ConditionalExpression`,test:e,consequent:t,alternate:n},i=V.ConditionalExpression;return B(i.test,r,`test`,e,1),B(i.consequent,r,`consequent`,t,1),B(i.alternate,r,`alternate`,n,1),r}function Al(e=null){let t={type:`ContinueStatement`,label:e},n=V.ContinueStatement;return B(n.label,t,`label`,e,1),t}function jl(){return{type:`DebuggerStatement`}}function Ml(e,t){let n={type:`DoWhileStatement`,test:e,body:t},r=V.DoWhileStatement;return B(r.test,n,`test`,e,1),B(r.body,n,`body`,t,1),n}function Nl(){return{type:`EmptyStatement`}}function Pl(e){let t={type:`ExpressionStatement`,expression:e},n=V.ExpressionStatement;return B(n.expression,t,`expression`,e,1),t}function Fl(e,t=null,n=null){let r={type:`File`,program:e,comments:t,tokens:n},i=V.File;return B(i.program,r,`program`,e,1),B(i.comments,r,`comments`,t,1),B(i.tokens,r,`tokens`,n),r}function Il(e,t,n){let r={type:`ForInStatement`,left:e,right:t,body:n},i=V.ForInStatement;return B(i.left,r,`left`,e,1),B(i.right,r,`right`,t,1),B(i.body,r,`body`,n,1),r}function Ll(e=null,t=null,n=null,r){let i={type:`ForStatement`,init:e,test:t,update:n,body:r},a=V.ForStatement;return B(a.init,i,`init`,e,1),B(a.test,i,`test`,t,1),B(a.update,i,`update`,n,1),B(a.body,i,`body`,r,1),i}function Rl(e=null,t,n,r=!1,i=!1){let a={type:`FunctionDeclaration`,id:e,params:t,body:n,generator:r,async:i},o=V.FunctionDeclaration;return B(o.id,a,`id`,e,1),B(o.params,a,`params`,t,1),B(o.body,a,`body`,n,1),B(o.generator,a,`generator`,r),B(o.async,a,`async`,i),a}function zl(e=null,t,n,r=!1,i=!1){let a={type:`FunctionExpression`,id:e,params:t,body:n,generator:r,async:i},o=V.FunctionExpression;return B(o.id,a,`id`,e,1),B(o.params,a,`params`,t,1),B(o.body,a,`body`,n,1),B(o.generator,a,`generator`,r),B(o.async,a,`async`,i),a}function H(e){let t={type:`Identifier`,name:e},n=V.Identifier;return B(n.name,t,`name`,e),t}function Bl(e,t,n=null){let r={type:`IfStatement`,test:e,consequent:t,alternate:n},i=V.IfStatement;return B(i.test,r,`test`,e,1),B(i.consequent,r,`consequent`,t,1),B(i.alternate,r,`alternate`,n,1),r}function Vl(e,t){let n={type:`LabeledStatement`,label:e,body:t},r=V.LabeledStatement;return B(r.label,n,`label`,e,1),B(r.body,n,`body`,t,1),n}function Hl(e){let t={type:`StringLiteral`,value:e},n=V.StringLiteral;return B(n.value,t,`value`,e),t}function Ul(e){let t={type:`NumericLiteral`,value:e},n=V.NumericLiteral;return B(n.value,t,`value`,e),t}function Wl(){return{type:`NullLiteral`}}function Gl(e){let t={type:`BooleanLiteral`,value:e},n=V.BooleanLiteral;return B(n.value,t,`value`,e),t}function Kl(e,t=``){let n={type:`RegExpLiteral`,pattern:e,flags:t},r=V.RegExpLiteral;return B(r.pattern,n,`pattern`,e),B(r.flags,n,`flags`,t),n}function ql(e,t,n){let r={type:`LogicalExpression`,operator:e,left:t,right:n},i=V.LogicalExpression;return B(i.operator,r,`operator`,e),B(i.left,r,`left`,t,1),B(i.right,r,`right`,n,1),r}function Jl(e,t,n=!1){let r={type:`MemberExpression`,object:e,property:t,computed:n},i=V.MemberExpression;return B(i.object,r,`object`,e,1),B(i.property,r,`property`,t,1),B(i.computed,r,`computed`,n),r}function Yl(e,t){let n={type:`NewExpression`,callee:e,arguments:t},r=V.NewExpression;return B(r.callee,n,`callee`,e,1),B(r.arguments,n,`arguments`,t,1),n}function Xl(e,t=[],n=`script`,r=null){let i={type:`Program`,body:e,directives:t,sourceType:n,interpreter:r},a=V.Program;return B(a.body,i,`body`,e,1),B(a.directives,i,`directives`,t,1),B(a.sourceType,i,`sourceType`,n),B(a.interpreter,i,`interpreter`,r,1),i}function Zl(e){let t={type:`ObjectExpression`,properties:e},n=V.ObjectExpression;return B(n.properties,t,`properties`,e,1),t}function Ql(e,t,n,r,i=!1,a=!1,o=!1){let s={type:`ObjectMethod`,kind:e,key:t,params:n,body:r,computed:i,generator:a,async:o},c=V.ObjectMethod;return B(c.kind,s,`kind`,e),B(c.key,s,`key`,t,1),B(c.params,s,`params`,n,1),B(c.body,s,`body`,r,1),B(c.computed,s,`computed`,i),B(c.generator,s,`generator`,a),B(c.async,s,`async`,o),s}function $l(e,t,n=!1,r=!1){let i={type:`ObjectProperty`,key:e,value:t,computed:n,shorthand:r},a=V.ObjectProperty;return B(a.key,i,`key`,e,1),B(a.value,i,`value`,t,1),B(a.computed,i,`computed`,n),B(a.shorthand,i,`shorthand`,r),i}function eu(e){let t={type:`RestElement`,argument:e},n=V.RestElement;return B(n.argument,t,`argument`,e,1),t}function tu(e=null){let t={type:`ReturnStatement`,argument:e},n=V.ReturnStatement;return B(n.argument,t,`argument`,e,1),t}function nu(e){let t={type:`SequenceExpression`,expressions:e},n=V.SequenceExpression;return B(n.expressions,t,`expressions`,e,1),t}function ru(e){let t={type:`ParenthesizedExpression`,expression:e},n=V.ParenthesizedExpression;return B(n.expression,t,`expression`,e,1),t}function iu(e=null,t){let n={type:`SwitchCase`,test:e,consequent:t},r=V.SwitchCase;return B(r.test,n,`test`,e,1),B(r.consequent,n,`consequent`,t,1),n}function au(e,t){let n={type:`SwitchStatement`,discriminant:e,cases:t},r=V.SwitchStatement;return B(r.discriminant,n,`discriminant`,e,1),B(r.cases,n,`cases`,t,1),n}function ou(){return{type:`ThisExpression`}}function su(e){let t={type:`ThrowStatement`,argument:e},n=V.ThrowStatement;return B(n.argument,t,`argument`,e,1),t}function cu(e,t=null,n=null){let r={type:`TryStatement`,block:e,handler:t,finalizer:n},i=V.TryStatement;return B(i.block,r,`block`,e,1),B(i.handler,r,`handler`,t,1),B(i.finalizer,r,`finalizer`,n,1),r}function lu(e,t,n=!0){let r={type:`UnaryExpression`,operator:e,argument:t,prefix:n},i=V.UnaryExpression;return B(i.operator,r,`operator`,e),B(i.argument,r,`argument`,t,1),B(i.prefix,r,`prefix`,n),r}function uu(e,t,n=!1){let r={type:`UpdateExpression`,operator:e,argument:t,prefix:n},i=V.UpdateExpression;return B(i.operator,r,`operator`,e),B(i.argument,r,`argument`,t,1),B(i.prefix,r,`prefix`,n),r}function du(e,t){let n={type:`VariableDeclaration`,kind:e,declarations:t},r=V.VariableDeclaration;return B(r.kind,n,`kind`,e),B(r.declarations,n,`declarations`,t,1),n}function fu(e,t=null){let n={type:`VariableDeclarator`,id:e,init:t},r=V.VariableDeclarator;return B(r.id,n,`id`,e,1),B(r.init,n,`init`,t,1),n}function pu(e,t){let n={type:`WhileStatement`,test:e,body:t},r=V.WhileStatement;return B(r.test,n,`test`,e,1),B(r.body,n,`body`,t,1),n}function mu(e,t){let n={type:`WithStatement`,object:e,body:t},r=V.WithStatement;return B(r.object,n,`object`,e,1),B(r.body,n,`body`,t,1),n}function hu(e,t){let n={type:`AssignmentPattern`,left:e,right:t},r=V.AssignmentPattern;return B(r.left,n,`left`,e,1),B(r.right,n,`right`,t,1),n}function gu(e){let t={type:`ArrayPattern`,elements:e},n=V.ArrayPattern;return B(n.elements,t,`elements`,e,1),t}function _u(e,t,n=!1){let r={type:`ArrowFunctionExpression`,params:e,body:t,async:n,expression:t.type!==`BlockStatement`},i=V.ArrowFunctionExpression;return B(i.params,r,`params`,e,1),B(i.body,r,`body`,t,1),B(i.async,r,`async`,n),r}function vu(e){let t={type:`ClassBody`,body:e},n=V.ClassBody;return B(n.body,t,`body`,e,1),t}function yu(e=null,t=null,n,r=null){let i={type:`ClassExpression`,id:e,superClass:t,body:n,decorators:r},a=V.ClassExpression;return B(a.id,i,`id`,e,1),B(a.superClass,i,`superClass`,t,1),B(a.body,i,`body`,n,1),B(a.decorators,i,`decorators`,r,1),i}function bu(e=null,t=null,n,r=null){let i={type:`ClassDeclaration`,id:e,superClass:t,body:n,decorators:r},a=V.ClassDeclaration;return B(a.id,i,`id`,e,1),B(a.superClass,i,`superClass`,t,1),B(a.body,i,`body`,n,1),B(a.decorators,i,`decorators`,r,1),i}function xu(e,t=null){let n={type:`ExportAllDeclaration`,source:e,attributes:t},r=V.ExportAllDeclaration;return B(r.source,n,`source`,e,1),B(r.attributes,n,`attributes`,t,1),n}function Su(e){let t={type:`ExportDefaultDeclaration`,declaration:e},n=V.ExportDefaultDeclaration;return B(n.declaration,t,`declaration`,e,1),t}function Cu(e=null,t=[],n=null,r=null){let i={type:`ExportNamedDeclaration`,declaration:e,specifiers:t,source:n,attributes:r},a=V.ExportNamedDeclaration;return B(a.declaration,i,`declaration`,e,1),B(a.specifiers,i,`specifiers`,t,1),B(a.source,i,`source`,n,1),B(a.attributes,i,`attributes`,r,1),i}function wu(e,t){let n={type:`ExportSpecifier`,local:e,exported:t},r=V.ExportSpecifier;return B(r.local,n,`local`,e,1),B(r.exported,n,`exported`,t,1),n}function Tu(e,t,n,r=!1){let i={type:`ForOfStatement`,left:e,right:t,body:n,await:r},a=V.ForOfStatement;return B(a.left,i,`left`,e,1),B(a.right,i,`right`,t,1),B(a.body,i,`body`,n,1),B(a.await,i,`await`,r),i}function Eu(e,t,n=null){let r={type:`ImportDeclaration`,specifiers:e,source:t,attributes:n},i=V.ImportDeclaration;return B(i.specifiers,r,`specifiers`,e,1),B(i.source,r,`source`,t,1),B(i.attributes,r,`attributes`,n,1),r}function Du(e){let t={type:`ImportDefaultSpecifier`,local:e},n=V.ImportDefaultSpecifier;return B(n.local,t,`local`,e,1),t}function Ou(e){let t={type:`ImportNamespaceSpecifier`,local:e},n=V.ImportNamespaceSpecifier;return B(n.local,t,`local`,e,1),t}function ku(e,t){let n={type:`ImportSpecifier`,local:e,imported:t},r=V.ImportSpecifier;return B(r.local,n,`local`,e,1),B(r.imported,n,`imported`,t,1),n}function Au(e,t=null){let n={type:`ImportExpression`,source:e,options:t},r=V.ImportExpression;return B(r.source,n,`source`,e,1),B(r.options,n,`options`,t,1),n}function ju(e,t){let n={type:`MetaProperty`,meta:e,property:t},r=V.MetaProperty;return B(r.meta,n,`meta`,e,1),B(r.property,n,`property`,t,1),n}function Mu(e=`method`,t,n,r,i=!1,a=!1,o=!1,s=!1){let c={type:`ClassMethod`,kind:e,key:t,params:n,body:r,computed:i,static:a,generator:o,async:s},l=V.ClassMethod;return B(l.kind,c,`kind`,e),B(l.key,c,`key`,t,1),B(l.params,c,`params`,n,1),B(l.body,c,`body`,r,1),B(l.computed,c,`computed`,i),B(l.static,c,`static`,a),B(l.generator,c,`generator`,o),B(l.async,c,`async`,s),c}function Nu(e){let t={type:`ObjectPattern`,properties:e},n=V.ObjectPattern;return B(n.properties,t,`properties`,e,1),t}function Pu(e){let t={type:`SpreadElement`,argument:e},n=V.SpreadElement;return B(n.argument,t,`argument`,e,1),t}function Fu(){return{type:`Super`}}function Iu(e,t){let n={type:`TaggedTemplateExpression`,tag:e,quasi:t},r=V.TaggedTemplateExpression;return B(r.tag,n,`tag`,e,1),B(r.quasi,n,`quasi`,t,1),n}function Lu(e,t=!1){let n={type:`TemplateElement`,value:e,tail:t},r=V.TemplateElement;return B(r.value,n,`value`,e),B(r.tail,n,`tail`,t),n}function Ru(e,t){let n={type:`TemplateLiteral`,quasis:e,expressions:t},r=V.TemplateLiteral;return B(r.quasis,n,`quasis`,e,1),B(r.expressions,n,`expressions`,t,1),n}function zu(e=null,t=!1){let n={type:`YieldExpression`,argument:e,delegate:t},r=V.YieldExpression;return B(r.argument,n,`argument`,e,1),B(r.delegate,n,`delegate`,t),n}function Bu(e){let t={type:`AwaitExpression`,argument:e},n=V.AwaitExpression;return B(n.argument,t,`argument`,e,1),t}function Vu(){return{type:`Import`}}function Hu(e){let t={type:`BigIntLiteral`,value:e},n=V.BigIntLiteral;return B(n.value,t,`value`,e),t}function Uu(e){let t={type:`ExportNamespaceSpecifier`,exported:e},n=V.ExportNamespaceSpecifier;return B(n.exported,t,`exported`,e,1),t}function Wu(e,t,n=!1,r){let i={type:`OptionalMemberExpression`,object:e,property:t,computed:n,optional:r},a=V.OptionalMemberExpression;return B(a.object,i,`object`,e,1),B(a.property,i,`property`,t,1),B(a.computed,i,`computed`,n),B(a.optional,i,`optional`,r),i}function Gu(e,t,n){let r={type:`OptionalCallExpression`,callee:e,arguments:t,optional:n},i=V.OptionalCallExpression;return B(i.callee,r,`callee`,e,1),B(i.arguments,r,`arguments`,t,1),B(i.optional,r,`optional`,n),r}function Ku(e,t=null,n=null,r=null,i=!1,a=!1){let o={type:`ClassProperty`,key:e,value:t,typeAnnotation:n,decorators:r,computed:i,static:a},s=V.ClassProperty;return B(s.key,o,`key`,e,1),B(s.value,o,`value`,t,1),B(s.typeAnnotation,o,`typeAnnotation`,n,1),B(s.decorators,o,`decorators`,r,1),B(s.computed,o,`computed`,i),B(s.static,o,`static`,a),o}function qu(e,t=null,n=null,r=!1){let i={type:`ClassPrivateProperty`,key:e,value:t,decorators:n,static:r},a=V.ClassPrivateProperty;return B(a.key,i,`key`,e,1),B(a.value,i,`value`,t,1),B(a.decorators,i,`decorators`,n,1),B(a.static,i,`static`,r),i}function Ju(e=`method`,t,n,r,i=!1){let a={type:`ClassPrivateMethod`,kind:e,key:t,params:n,body:r,static:i,async:!1,computed:!1,generator:!1},o=V.ClassPrivateMethod;return B(o.kind,a,`kind`,e),B(o.key,a,`key`,t,1),B(o.params,a,`params`,n,1),B(o.body,a,`body`,r,1),B(o.static,a,`static`,i),a}function Yu(e){let t={type:`PrivateName`,id:e},n=V.PrivateName;return B(n.id,t,`id`,e,1),t}function Xu(e){let t={type:`StaticBlock`,body:e},n=V.StaticBlock;return B(n.body,t,`body`,e,1),t}function Zu(e,t){let n={type:`ImportAttribute`,key:e,value:t},r=V.ImportAttribute;return B(r.key,n,`key`,e,1),B(r.value,n,`value`,t,1),n}function Qu(){return{type:`AnyTypeAnnotation`}}function $u(e){let t={type:`ArrayTypeAnnotation`,elementType:e},n=V.ArrayTypeAnnotation;return B(n.elementType,t,`elementType`,e,1),t}function ed(){return{type:`BooleanTypeAnnotation`}}function td(e){let t={type:`BooleanLiteralTypeAnnotation`,value:e},n=V.BooleanLiteralTypeAnnotation;return B(n.value,t,`value`,e),t}function nd(){return{type:`NullLiteralTypeAnnotation`}}function rd(e,t=null){let n={type:`ClassImplements`,id:e,typeParameters:t},r=V.ClassImplements;return B(r.id,n,`id`,e,1),B(r.typeParameters,n,`typeParameters`,t,1),n}function id(e,t=null,n=null,r){let i={type:`DeclareClass`,id:e,typeParameters:t,extends:n,body:r},a=V.DeclareClass;return B(a.id,i,`id`,e,1),B(a.typeParameters,i,`typeParameters`,t,1),B(a.extends,i,`extends`,n,1),B(a.body,i,`body`,r,1),i}function ad(e){let t={type:`DeclareFunction`,id:e},n=V.DeclareFunction;return B(n.id,t,`id`,e,1),t}function od(e,t=null,n=null,r){let i={type:`DeclareInterface`,id:e,typeParameters:t,extends:n,body:r},a=V.DeclareInterface;return B(a.id,i,`id`,e,1),B(a.typeParameters,i,`typeParameters`,t,1),B(a.extends,i,`extends`,n,1),B(a.body,i,`body`,r,1),i}function sd(e,t,n=null){let r={type:`DeclareModule`,id:e,body:t,kind:n},i=V.DeclareModule;return B(i.id,r,`id`,e,1),B(i.body,r,`body`,t,1),B(i.kind,r,`kind`,n),r}function cd(e){let t={type:`DeclareModuleExports`,typeAnnotation:e},n=V.DeclareModuleExports;return B(n.typeAnnotation,t,`typeAnnotation`,e,1),t}function ld(e,t=null,n){let r={type:`DeclareTypeAlias`,id:e,typeParameters:t,right:n},i=V.DeclareTypeAlias;return B(i.id,r,`id`,e,1),B(i.typeParameters,r,`typeParameters`,t,1),B(i.right,r,`right`,n,1),r}function ud(e,t=null,n=null){let r={type:`DeclareOpaqueType`,id:e,typeParameters:t,supertype:n},i=V.DeclareOpaqueType;return B(i.id,r,`id`,e,1),B(i.typeParameters,r,`typeParameters`,t,1),B(i.supertype,r,`supertype`,n,1),r}function dd(e){let t={type:`DeclareVariable`,id:e},n=V.DeclareVariable;return B(n.id,t,`id`,e,1),t}function fd(e=null,t=null,n=null,r=null){let i={type:`DeclareExportDeclaration`,declaration:e,specifiers:t,source:n,attributes:r},a=V.DeclareExportDeclaration;return B(a.declaration,i,`declaration`,e,1),B(a.specifiers,i,`specifiers`,t,1),B(a.source,i,`source`,n,1),B(a.attributes,i,`attributes`,r,1),i}function pd(e,t=null){let n={type:`DeclareExportAllDeclaration`,source:e,attributes:t},r=V.DeclareExportAllDeclaration;return B(r.source,n,`source`,e,1),B(r.attributes,n,`attributes`,t,1),n}function md(e){let t={type:`DeclaredPredicate`,value:e},n=V.DeclaredPredicate;return B(n.value,t,`value`,e,1),t}function hd(){return{type:`ExistsTypeAnnotation`}}function gd(e=null,t,n=null,r){let i={type:`FunctionTypeAnnotation`,typeParameters:e,params:t,rest:n,returnType:r},a=V.FunctionTypeAnnotation;return B(a.typeParameters,i,`typeParameters`,e,1),B(a.params,i,`params`,t,1),B(a.rest,i,`rest`,n,1),B(a.returnType,i,`returnType`,r,1),i}function _d(e=null,t){let n={type:`FunctionTypeParam`,name:e,typeAnnotation:t},r=V.FunctionTypeParam;return B(r.name,n,`name`,e,1),B(r.typeAnnotation,n,`typeAnnotation`,t,1),n}function vd(e,t=null){let n={type:`GenericTypeAnnotation`,id:e,typeParameters:t},r=V.GenericTypeAnnotation;return B(r.id,n,`id`,e,1),B(r.typeParameters,n,`typeParameters`,t,1),n}function yd(){return{type:`InferredPredicate`}}function bd(e,t=null){let n={type:`InterfaceExtends`,id:e,typeParameters:t},r=V.InterfaceExtends;return B(r.id,n,`id`,e,1),B(r.typeParameters,n,`typeParameters`,t,1),n}function xd(e,t=null,n=null,r){let i={type:`InterfaceDeclaration`,id:e,typeParameters:t,extends:n,body:r},a=V.InterfaceDeclaration;return B(a.id,i,`id`,e,1),B(a.typeParameters,i,`typeParameters`,t,1),B(a.extends,i,`extends`,n,1),B(a.body,i,`body`,r,1),i}function Sd(e=null,t){let n={type:`InterfaceTypeAnnotation`,extends:e,body:t},r=V.InterfaceTypeAnnotation;return B(r.extends,n,`extends`,e,1),B(r.body,n,`body`,t,1),n}function Cd(e){let t={type:`IntersectionTypeAnnotation`,types:e},n=V.IntersectionTypeAnnotation;return B(n.types,t,`types`,e,1),t}function wd(){return{type:`MixedTypeAnnotation`}}function Td(){return{type:`EmptyTypeAnnotation`}}function Ed(e){let t={type:`NullableTypeAnnotation`,typeAnnotation:e},n=V.NullableTypeAnnotation;return B(n.typeAnnotation,t,`typeAnnotation`,e,1),t}function Dd(e){let t={type:`NumberLiteralTypeAnnotation`,value:e},n=V.NumberLiteralTypeAnnotation;return B(n.value,t,`value`,e),t}function Od(){return{type:`NumberTypeAnnotation`}}function kd(e,t=[],n=[],r=[],i=!1){let a={type:`ObjectTypeAnnotation`,properties:e,indexers:t,callProperties:n,internalSlots:r,exact:i},o=V.ObjectTypeAnnotation;return B(o.properties,a,`properties`,e,1),B(o.indexers,a,`indexers`,t,1),B(o.callProperties,a,`callProperties`,n,1),B(o.internalSlots,a,`internalSlots`,r,1),B(o.exact,a,`exact`,i),a}function Ad(e,t,n,r,i){let a={type:`ObjectTypeInternalSlot`,id:e,value:t,optional:n,static:r,method:i},o=V.ObjectTypeInternalSlot;return B(o.id,a,`id`,e,1),B(o.value,a,`value`,t,1),B(o.optional,a,`optional`,n),B(o.static,a,`static`,r),B(o.method,a,`method`,i),a}function jd(e){let t={type:`ObjectTypeCallProperty`,value:e,static:!1},n=V.ObjectTypeCallProperty;return B(n.value,t,`value`,e,1),t}function Md(e=null,t,n,r=null){let i={type:`ObjectTypeIndexer`,id:e,key:t,value:n,variance:r,static:!1},a=V.ObjectTypeIndexer;return B(a.id,i,`id`,e,1),B(a.key,i,`key`,t,1),B(a.value,i,`value`,n,1),B(a.variance,i,`variance`,r,1),i}function Nd(e,t,n=null){let r={type:`ObjectTypeProperty`,key:e,value:t,variance:n,kind:`init`,method:!1,optional:!1,proto:!1,static:!1},i=V.ObjectTypeProperty;return B(i.key,r,`key`,e,1),B(i.value,r,`value`,t,1),B(i.variance,r,`variance`,n,1),r}function Pd(e){let t={type:`ObjectTypeSpreadProperty`,argument:e},n=V.ObjectTypeSpreadProperty;return B(n.argument,t,`argument`,e,1),t}function Fd(e,t=null,n=null,r){let i={type:`OpaqueType`,id:e,typeParameters:t,supertype:n,impltype:r},a=V.OpaqueType;return B(a.id,i,`id`,e,1),B(a.typeParameters,i,`typeParameters`,t,1),B(a.supertype,i,`supertype`,n,1),B(a.impltype,i,`impltype`,r,1),i}function Id(e,t){let n={type:`QualifiedTypeIdentifier`,id:e,qualification:t},r=V.QualifiedTypeIdentifier;return B(r.id,n,`id`,e,1),B(r.qualification,n,`qualification`,t,1),n}function Ld(e){let t={type:`StringLiteralTypeAnnotation`,value:e},n=V.StringLiteralTypeAnnotation;return B(n.value,t,`value`,e),t}function Rd(){return{type:`StringTypeAnnotation`}}function zd(){return{type:`SymbolTypeAnnotation`}}function Bd(){return{type:`ThisTypeAnnotation`}}function Vd(e){let t={type:`TupleTypeAnnotation`,types:e},n=V.TupleTypeAnnotation;return B(n.types,t,`types`,e,1),t}function Hd(e){let t={type:`TypeofTypeAnnotation`,argument:e},n=V.TypeofTypeAnnotation;return B(n.argument,t,`argument`,e,1),t}function Ud(e,t=null,n){let r={type:`TypeAlias`,id:e,typeParameters:t,right:n},i=V.TypeAlias;return B(i.id,r,`id`,e,1),B(i.typeParameters,r,`typeParameters`,t,1),B(i.right,r,`right`,n,1),r}function Wd(e){let t={type:`TypeAnnotation`,typeAnnotation:e},n=V.TypeAnnotation;return B(n.typeAnnotation,t,`typeAnnotation`,e,1),t}function Gd(e,t){let n={type:`TypeCastExpression`,expression:e,typeAnnotation:t},r=V.TypeCastExpression;return B(r.expression,n,`expression`,e,1),B(r.typeAnnotation,n,`typeAnnotation`,t,1),n}function Kd(e,t=null,n=null,r=null){let i={type:`TypeParameter`,name:e,bound:t,default:n,variance:r},a=V.TypeParameter;return B(a.name,i,`name`,e),B(a.bound,i,`bound`,t,1),B(a.default,i,`default`,n,1),B(a.variance,i,`variance`,r,1),i}function qd(e){let t={type:`TypeParameterDeclaration`,params:e},n=V.TypeParameterDeclaration;return B(n.params,t,`params`,e,1),t}function Jd(e){let t={type:`TypeParameterInstantiation`,params:e},n=V.TypeParameterInstantiation;return B(n.params,t,`params`,e,1),t}function Yd(e){let t={type:`UnionTypeAnnotation`,types:e},n=V.UnionTypeAnnotation;return B(n.types,t,`types`,e,1),t}function Xd(e){let t={type:`Variance`,kind:e},n=V.Variance;return B(n.kind,t,`kind`,e),t}function Zd(){return{type:`VoidTypeAnnotation`}}function Qd(e,t){let n={type:`EnumDeclaration`,id:e,body:t},r=V.EnumDeclaration;return B(r.id,n,`id`,e,1),B(r.body,n,`body`,t,1),n}function $d(e){let t={type:`EnumBooleanBody`,members:e,explicitType:!1,hasUnknownMembers:!1},n=V.EnumBooleanBody;return B(n.members,t,`members`,e,1),t}function ef(e){let t={type:`EnumNumberBody`,members:e,explicitType:!1,hasUnknownMembers:!1},n=V.EnumNumberBody;return B(n.members,t,`members`,e,1),t}function tf(e){let t={type:`EnumStringBody`,members:e,explicitType:!1,hasUnknownMembers:!1},n=V.EnumStringBody;return B(n.members,t,`members`,e,1),t}function nf(e){let t={type:`EnumSymbolBody`,members:e,hasUnknownMembers:!1},n=V.EnumSymbolBody;return B(n.members,t,`members`,e,1),t}function rf(e,t){let n={type:`EnumBooleanMember`,id:e,init:t},r=V.EnumBooleanMember;return B(r.id,n,`id`,e,1),B(r.init,n,`init`,t,1),n}function af(e,t){let n={type:`EnumNumberMember`,id:e,init:t},r=V.EnumNumberMember;return B(r.id,n,`id`,e,1),B(r.init,n,`init`,t,1),n}function of(e,t){let n={type:`EnumStringMember`,id:e,init:t},r=V.EnumStringMember;return B(r.id,n,`id`,e,1),B(r.init,n,`init`,t,1),n}function sf(e){let t={type:`EnumDefaultedMember`,id:e},n=V.EnumDefaultedMember;return B(n.id,t,`id`,e,1),t}function cf(e,t){let n={type:`IndexedAccessType`,objectType:e,indexType:t},r=V.IndexedAccessType;return B(r.objectType,n,`objectType`,e,1),B(r.indexType,n,`indexType`,t,1),n}function lf(e,t){let n={type:`OptionalIndexedAccessType`,objectType:e,indexType:t,optional:!1},r=V.OptionalIndexedAccessType;return B(r.objectType,n,`objectType`,e,1),B(r.indexType,n,`indexType`,t,1),n}function uf(e,t=null){let n={type:`JSXAttribute`,name:e,value:t},r=V.JSXAttribute;return B(r.name,n,`name`,e,1),B(r.value,n,`value`,t,1),n}function df(e){let t={type:`JSXClosingElement`,name:e},n=V.JSXClosingElement;return B(n.name,t,`name`,e,1),t}function ff(e,t=null,n){let r={type:`JSXElement`,openingElement:e,closingElement:t,children:n},i=V.JSXElement;return B(i.openingElement,r,`openingElement`,e,1),B(i.closingElement,r,`closingElement`,t,1),B(i.children,r,`children`,n,1),r}function pf(){return{type:`JSXEmptyExpression`}}function mf(e){let t={type:`JSXExpressionContainer`,expression:e},n=V.JSXExpressionContainer;return B(n.expression,t,`expression`,e,1),t}function hf(e){let t={type:`JSXSpreadChild`,expression:e},n=V.JSXSpreadChild;return B(n.expression,t,`expression`,e,1),t}function gf(e){let t={type:`JSXIdentifier`,name:e},n=V.JSXIdentifier;return B(n.name,t,`name`,e),t}function _f(e,t){let n={type:`JSXMemberExpression`,object:e,property:t},r=V.JSXMemberExpression;return B(r.object,n,`object`,e,1),B(r.property,n,`property`,t,1),n}function vf(e,t){let n={type:`JSXNamespacedName`,namespace:e,name:t},r=V.JSXNamespacedName;return B(r.namespace,n,`namespace`,e,1),B(r.name,n,`name`,t,1),n}function yf(e,t,n=!1){let r={type:`JSXOpeningElement`,name:e,attributes:t,selfClosing:n},i=V.JSXOpeningElement;return B(i.name,r,`name`,e,1),B(i.attributes,r,`attributes`,t,1),B(i.selfClosing,r,`selfClosing`,n),r}function bf(e){let t={type:`JSXSpreadAttribute`,argument:e},n=V.JSXSpreadAttribute;return B(n.argument,t,`argument`,e,1),t}function xf(e){let t={type:`JSXText`,value:e},n=V.JSXText;return B(n.value,t,`value`,e),t}function Sf(e,t,n){let r={type:`JSXFragment`,openingFragment:e,closingFragment:t,children:n},i=V.JSXFragment;return B(i.openingFragment,r,`openingFragment`,e,1),B(i.closingFragment,r,`closingFragment`,t,1),B(i.children,r,`children`,n,1),r}function Cf(){return{type:`JSXOpeningFragment`}}function wf(){return{type:`JSXClosingFragment`}}function Tf(e,t){let n={type:`Placeholder`,expectedNode:e,name:t},r=V.Placeholder;return B(r.expectedNode,n,`expectedNode`,e),B(r.name,n,`name`,t,1),n}function Ef(e){let t={type:`V8IntrinsicIdentifier`,name:e},n=V.V8IntrinsicIdentifier;return B(n.name,t,`name`,e),t}function Df(){return{type:`ArgumentPlaceholder`}}function Of(e,t){let n={type:`BindExpression`,object:e,callee:t},r=V.BindExpression;return B(r.object,n,`object`,e,1),B(r.callee,n,`callee`,t,1),n}function kf(e,t=null,n=null,r=null,i=!1,a=!1){let o={type:`ClassAccessorProperty`,key:e,value:t,typeAnnotation:n,decorators:r,computed:i,static:a},s=V.ClassAccessorProperty;return B(s.key,o,`key`,e,1),B(s.value,o,`value`,t,1),B(s.typeAnnotation,o,`typeAnnotation`,n,1),B(s.decorators,o,`decorators`,r,1),B(s.computed,o,`computed`,i),B(s.static,o,`static`,a),o}function Af(e){let t={type:`Decorator`,expression:e},n=V.Decorator;return B(n.expression,t,`expression`,e,1),t}function jf(e,t=!1){let n={type:`DoExpression`,body:e,async:t},r=V.DoExpression;return B(r.body,n,`body`,e,1),B(r.async,n,`async`,t),n}function Mf(e){let t={type:`ExportDefaultSpecifier`,exported:e},n=V.ExportDefaultSpecifier;return B(n.exported,t,`exported`,e,1),t}function Nf(e){let t={type:`ModuleExpression`,body:e},n=V.ModuleExpression;return B(n.body,t,`body`,e,1),t}function Pf(){return{type:`TopicReference`}}function Ff(){return{type:`VoidPattern`}}function If(e){let t={type:`TSParameterProperty`,parameter:e},n=V.TSParameterProperty;return B(n.parameter,t,`parameter`,e,1),t}function Lf(e=null,t=null,n,r=null){let i={type:`TSDeclareFunction`,id:e,typeParameters:t,params:n,returnType:r,async:!1,generator:!1},a=V.TSDeclareFunction;return B(a.id,i,`id`,e,1),B(a.typeParameters,i,`typeParameters`,t,1),B(a.params,i,`params`,n,1),B(a.returnType,i,`returnType`,r,1),i}function Rf(e=null,t,n=null,r,i=null){let a={type:`TSDeclareMethod`,decorators:e,key:t,typeParameters:n,params:r,returnType:i,async:!1,computed:!1,generator:!1,kind:`method`,static:!1},o=V.TSDeclareMethod;return B(o.decorators,a,`decorators`,e,1),B(o.key,a,`key`,t,1),B(o.typeParameters,a,`typeParameters`,n,1),B(o.params,a,`params`,r,1),B(o.returnType,a,`returnType`,i,1),a}function zf(e,t){let n={type:`TSQualifiedName`,left:e,right:t},r=V.TSQualifiedName;return B(r.left,n,`left`,e,1),B(r.right,n,`right`,t,1),n}function Bf(e=null,t,n=null){let r={type:`TSCallSignatureDeclaration`,typeParameters:e,params:t,returnType:n},i=V.TSCallSignatureDeclaration;return B(i.typeParameters,r,`typeParameters`,e,1),B(i.params,r,`params`,t,1),B(i.returnType,r,`returnType`,n,1),r}function Vf(e=null,t,n=null){let r={type:`TSConstructSignatureDeclaration`,typeParameters:e,params:t,returnType:n},i=V.TSConstructSignatureDeclaration;return B(i.typeParameters,r,`typeParameters`,e,1),B(i.params,r,`params`,t,1),B(i.returnType,r,`returnType`,n,1),r}function Hf(e,t=null){let n={type:`TSPropertySignature`,key:e,typeAnnotation:t,computed:!1},r=V.TSPropertySignature;return B(r.key,n,`key`,e,1),B(r.typeAnnotation,n,`typeAnnotation`,t,1),n}function Uf(e,t=null,n,r=null){let i={type:`TSMethodSignature`,key:e,typeParameters:t,params:n,returnType:r,computed:!1,kind:`method`},a=V.TSMethodSignature;return B(a.key,i,`key`,e,1),B(a.typeParameters,i,`typeParameters`,t,1),B(a.params,i,`params`,n,1),B(a.returnType,i,`returnType`,r,1),i}function Wf(e,t=null){let n={type:`TSIndexSignature`,parameters:e,typeAnnotation:t},r=V.TSIndexSignature;return B(r.parameters,n,`parameters`,e,1),B(r.typeAnnotation,n,`typeAnnotation`,t,1),n}function Gf(){return{type:`TSAnyKeyword`}}function Kf(){return{type:`TSBooleanKeyword`}}function qf(){return{type:`TSBigIntKeyword`}}function Jf(){return{type:`TSIntrinsicKeyword`}}function Yf(){return{type:`TSNeverKeyword`}}function Xf(){return{type:`TSNullKeyword`}}function Zf(){return{type:`TSNumberKeyword`}}function Qf(){return{type:`TSObjectKeyword`}}function $f(){return{type:`TSStringKeyword`}}function ep(){return{type:`TSSymbolKeyword`}}function tp(){return{type:`TSUndefinedKeyword`}}function np(){return{type:`TSUnknownKeyword`}}function rp(){return{type:`TSVoidKeyword`}}function ip(){return{type:`TSThisType`}}function ap(e=null,t,n=null){let r={type:`TSFunctionType`,typeParameters:e,params:t,returnType:n},i=V.TSFunctionType;return B(i.typeParameters,r,`typeParameters`,e,1),B(i.params,r,`params`,t,1),B(i.returnType,r,`returnType`,n,1),r}function op(e=null,t,n=null){let r={type:`TSConstructorType`,typeParameters:e,params:t,returnType:n},i=V.TSConstructorType;return B(i.typeParameters,r,`typeParameters`,e,1),B(i.params,r,`params`,t,1),B(i.returnType,r,`returnType`,n,1),r}function sp(e,t=null){let n={type:`TSTypeReference`,typeName:e,typeArguments:t},r=V.TSTypeReference;return B(r.typeName,n,`typeName`,e,1),B(r.typeArguments,n,`typeArguments`,t,1),n}function cp(e,t=null,n=null){let r={type:`TSTypePredicate`,parameterName:e,typeAnnotation:t,asserts:n},i=V.TSTypePredicate;return B(i.parameterName,r,`parameterName`,e,1),B(i.typeAnnotation,r,`typeAnnotation`,t,1),B(i.asserts,r,`asserts`,n),r}function lp(e,t=null){let n={type:`TSTypeQuery`,exprName:e,typeArguments:t},r=V.TSTypeQuery;return B(r.exprName,n,`exprName`,e,1),B(r.typeArguments,n,`typeArguments`,t,1),n}function up(e){let t={type:`TSTypeLiteral`,members:e},n=V.TSTypeLiteral;return B(n.members,t,`members`,e,1),t}function dp(e){let t={type:`TSArrayType`,elementType:e},n=V.TSArrayType;return B(n.elementType,t,`elementType`,e,1),t}function fp(e){let t={type:`TSTupleType`,elementTypes:e},n=V.TSTupleType;return B(n.elementTypes,t,`elementTypes`,e,1),t}function pp(e){let t={type:`TSOptionalType`,typeAnnotation:e},n=V.TSOptionalType;return B(n.typeAnnotation,t,`typeAnnotation`,e,1),t}function mp(e){let t={type:`TSRestType`,typeAnnotation:e},n=V.TSRestType;return B(n.typeAnnotation,t,`typeAnnotation`,e,1),t}function hp(e,t,n=!1){let r={type:`TSNamedTupleMember`,label:e,elementType:t,optional:n},i=V.TSNamedTupleMember;return B(i.label,r,`label`,e,1),B(i.elementType,r,`elementType`,t,1),B(i.optional,r,`optional`,n),r}function gp(e){let t={type:`TSUnionType`,types:e},n=V.TSUnionType;return B(n.types,t,`types`,e,1),t}function _p(e){let t={type:`TSIntersectionType`,types:e},n=V.TSIntersectionType;return B(n.types,t,`types`,e,1),t}function vp(e,t,n,r){let i={type:`TSConditionalType`,checkType:e,extendsType:t,trueType:n,falseType:r},a=V.TSConditionalType;return B(a.checkType,i,`checkType`,e,1),B(a.extendsType,i,`extendsType`,t,1),B(a.trueType,i,`trueType`,n,1),B(a.falseType,i,`falseType`,r,1),i}function yp(e){let t={type:`TSInferType`,typeParameter:e},n=V.TSInferType;return B(n.typeParameter,t,`typeParameter`,e,1),t}function bp(e){let t={type:`TSParenthesizedType`,typeAnnotation:e},n=V.TSParenthesizedType;return B(n.typeAnnotation,t,`typeAnnotation`,e,1),t}function xp(e,t){let n={type:`TSTypeOperator`,typeAnnotation:e,operator:t},r=V.TSTypeOperator;return B(r.typeAnnotation,n,`typeAnnotation`,e,1),B(r.operator,n,`operator`,t),n}function Sp(e,t){let n={type:`TSIndexedAccessType`,objectType:e,indexType:t},r=V.TSIndexedAccessType;return B(r.objectType,n,`objectType`,e,1),B(r.indexType,n,`indexType`,t,1),n}function Cp(e,t,n=null,r=null){let i={type:`TSMappedType`,key:e,constraint:t,nameType:n,typeAnnotation:r},a=V.TSMappedType;return B(a.key,i,`key`,e,1),B(a.constraint,i,`constraint`,t,1),B(a.nameType,i,`nameType`,n,1),B(a.typeAnnotation,i,`typeAnnotation`,r,1),i}function wp(e,t){let n={type:`TSTemplateLiteralType`,quasis:e,types:t},r=V.TSTemplateLiteralType;return B(r.quasis,n,`quasis`,e,1),B(r.types,n,`types`,t,1),n}function Tp(e){let t={type:`TSLiteralType`,literal:e},n=V.TSLiteralType;return B(n.literal,t,`literal`,e,1),t}function Ep(e,t=null){let n={type:`TSClassImplements`,expression:e,typeArguments:t},r=V.TSClassImplements;return B(r.expression,n,`expression`,e,1),B(r.typeArguments,n,`typeArguments`,t,1),n}function Dp(e,t=null){let n={type:`TSInterfaceHeritage`,expression:e,typeArguments:t},r=V.TSInterfaceHeritage;return B(r.expression,n,`expression`,e,1),B(r.typeArguments,n,`typeArguments`,t,1),n}function Op(e,t=null,n=null,r){let i={type:`TSInterfaceDeclaration`,id:e,typeParameters:t,extends:n,body:r},a=V.TSInterfaceDeclaration;return B(a.id,i,`id`,e,1),B(a.typeParameters,i,`typeParameters`,t,1),B(a.extends,i,`extends`,n,1),B(a.body,i,`body`,r,1),i}function kp(e){let t={type:`TSInterfaceBody`,body:e},n=V.TSInterfaceBody;return B(n.body,t,`body`,e,1),t}function Ap(e,t=null,n){let r={type:`TSTypeAliasDeclaration`,id:e,typeParameters:t,typeAnnotation:n},i=V.TSTypeAliasDeclaration;return B(i.id,r,`id`,e,1),B(i.typeParameters,r,`typeParameters`,t,1),B(i.typeAnnotation,r,`typeAnnotation`,n,1),r}function jp(e,t=null){let n={type:`TSInstantiationExpression`,expression:e,typeArguments:t},r=V.TSInstantiationExpression;return B(r.expression,n,`expression`,e,1),B(r.typeArguments,n,`typeArguments`,t,1),n}function Mp(e,t){let n={type:`TSAsExpression`,expression:e,typeAnnotation:t},r=V.TSAsExpression;return B(r.expression,n,`expression`,e,1),B(r.typeAnnotation,n,`typeAnnotation`,t,1),n}function Np(e,t){let n={type:`TSSatisfiesExpression`,expression:e,typeAnnotation:t},r=V.TSSatisfiesExpression;return B(r.expression,n,`expression`,e,1),B(r.typeAnnotation,n,`typeAnnotation`,t,1),n}function Pp(e,t){let n={type:`TSTypeAssertion`,typeAnnotation:e,expression:t},r=V.TSTypeAssertion;return B(r.typeAnnotation,n,`typeAnnotation`,e,1),B(r.expression,n,`expression`,t,1),n}function Fp(e){let t={type:`TSEnumBody`,members:e},n=V.TSEnumBody;return B(n.members,t,`members`,e,1),t}function Ip(e,t){let n={type:`TSEnumDeclaration`,id:e,body:t},r=V.TSEnumDeclaration;return B(r.id,n,`id`,e,1),B(r.body,n,`body`,t,1),n}function Lp(e,t=null){let n={type:`TSEnumMember`,id:e,initializer:t},r=V.TSEnumMember;return B(r.id,n,`id`,e,1),B(r.initializer,n,`initializer`,t,1),n}function Rp(e,t){let n={type:`TSModuleDeclaration`,id:e,body:t,kind:`namespace`},r=V.TSModuleDeclaration;return B(r.id,n,`id`,e,1),B(r.body,n,`body`,t,1),n}function zp(e){let t={type:`TSModuleBlock`,body:e},n=V.TSModuleBlock;return B(n.body,t,`body`,e,1),t}function Bp(e,t=null,n=null){let r={type:`TSImportType`,source:e,qualifier:t,typeArguments:n},i=V.TSImportType;return B(i.source,r,`source`,e,1),B(i.qualifier,r,`qualifier`,t,1),B(i.typeArguments,r,`typeArguments`,n,1),r}function Vp(e,t){let n={type:`TSImportEqualsDeclaration`,id:e,moduleReference:t},r=V.TSImportEqualsDeclaration;return B(r.id,n,`id`,e,1),B(r.moduleReference,n,`moduleReference`,t,1),n}function Hp(e){let t={type:`TSExternalModuleReference`,expression:e},n=V.TSExternalModuleReference;return B(n.expression,t,`expression`,e,1),t}function Up(e){let t={type:`TSNonNullExpression`,expression:e},n=V.TSNonNullExpression;return B(n.expression,t,`expression`,e,1),t}function Wp(e){let t={type:`TSExportAssignment`,expression:e},n=V.TSExportAssignment;return B(n.expression,t,`expression`,e,1),t}function Gp(e){let t={type:`TSNamespaceExportDeclaration`,id:e},n=V.TSNamespaceExportDeclaration;return B(n.id,t,`id`,e,1),t}function Kp(e){let t={type:`TSTypeAnnotation`,typeAnnotation:e},n=V.TSTypeAnnotation;return B(n.typeAnnotation,t,`typeAnnotation`,e,1),t}function qp(e){let t={type:`TSTypeParameterInstantiation`,params:e},n=V.TSTypeParameterInstantiation;return B(n.params,t,`params`,e,1),t}function Jp(e){let t={type:`TSTypeParameterDeclaration`,params:e},n=V.TSTypeParameterDeclaration;return B(n.params,t,`params`,e,1),t}function Yp(e=null,t=null,n){let r={type:`TSTypeParameter`,constraint:e,default:t,name:n},i=V.TSTypeParameter;return B(i.constraint,r,`constraint`,e,1),B(i.default,r,`default`,t,1),B(i.name,r,`name`,n,1),r}function Xp(e){return w(`NumberLiteral`,`NumericLiteral`,`The node type `),Ul(e)}function Zp(e,t=``){return w(`RegexLiteral`,`RegExpLiteral`,`The node type `),Kl(e,t)}function Qp(e){return w(`RestProperty`,`RestElement`,`The node type `),eu(e)}function $p(e){return w(`SpreadProperty`,`SpreadElement`,`The node type `),Pu(e)}var em=Object.freeze({__proto__:null,anyTypeAnnotation:Qu,argumentPlaceholder:Df,arrayExpression:yl,arrayPattern:gu,arrayTypeAnnotation:$u,arrowFunctionExpression:_u,assignmentExpression:bl,assignmentPattern:hu,awaitExpression:Bu,bigIntLiteral:Hu,binaryExpression:xl,bindExpression:Of,blockStatement:Tl,booleanLiteral:Gl,booleanLiteralTypeAnnotation:td,booleanTypeAnnotation:ed,breakStatement:El,callExpression:Dl,catchClause:Ol,classAccessorProperty:kf,classBody:vu,classDeclaration:bu,classExpression:yu,classImplements:rd,classMethod:Mu,classPrivateMethod:Ju,classPrivateProperty:qu,classProperty:Ku,conditionalExpression:kl,continueStatement:Al,debuggerStatement:jl,declareClass:id,declareExportAllDeclaration:pd,declareExportDeclaration:fd,declareFunction:ad,declareInterface:od,declareModule:sd,declareModuleExports:cd,declareOpaqueType:ud,declareTypeAlias:ld,declareVariable:dd,declaredPredicate:md,decorator:Af,directive:Cl,directiveLiteral:wl,doExpression:jf,doWhileStatement:Ml,emptyStatement:Nl,emptyTypeAnnotation:Td,enumBooleanBody:$d,enumBooleanMember:rf,enumDeclaration:Qd,enumDefaultedMember:sf,enumNumberBody:ef,enumNumberMember:af,enumStringBody:tf,enumStringMember:of,enumSymbolBody:nf,existsTypeAnnotation:hd,exportAllDeclaration:xu,exportDefaultDeclaration:Su,exportDefaultSpecifier:Mf,exportNamedDeclaration:Cu,exportNamespaceSpecifier:Uu,exportSpecifier:wu,expressionStatement:Pl,file:Fl,forInStatement:Il,forOfStatement:Tu,forStatement:Ll,functionDeclaration:Rl,functionExpression:zl,functionTypeAnnotation:gd,functionTypeParam:_d,genericTypeAnnotation:vd,identifier:H,ifStatement:Bl,import:Vu,importAttribute:Zu,importDeclaration:Eu,importDefaultSpecifier:Du,importExpression:Au,importNamespaceSpecifier:Ou,importSpecifier:ku,indexedAccessType:cf,inferredPredicate:yd,interfaceDeclaration:xd,interfaceExtends:bd,interfaceTypeAnnotation:Sd,interpreterDirective:Sl,intersectionTypeAnnotation:Cd,jsxAttribute:uf,jsxClosingElement:df,jsxClosingFragment:wf,jsxElement:ff,jsxEmptyExpression:pf,jsxExpressionContainer:mf,jsxFragment:Sf,jsxIdentifier:gf,jsxMemberExpression:_f,jsxNamespacedName:vf,jsxOpeningElement:yf,jsxOpeningFragment:Cf,jsxSpreadAttribute:bf,jsxSpreadChild:hf,jsxText:xf,labeledStatement:Vl,logicalExpression:ql,memberExpression:Jl,metaProperty:ju,mixedTypeAnnotation:wd,moduleExpression:Nf,newExpression:Yl,nullLiteral:Wl,nullLiteralTypeAnnotation:nd,nullableTypeAnnotation:Ed,numberLiteral:Xp,numberLiteralTypeAnnotation:Dd,numberTypeAnnotation:Od,numericLiteral:Ul,objectExpression:Zl,objectMethod:Ql,objectPattern:Nu,objectProperty:$l,objectTypeAnnotation:kd,objectTypeCallProperty:jd,objectTypeIndexer:Md,objectTypeInternalSlot:Ad,objectTypeProperty:Nd,objectTypeSpreadProperty:Pd,opaqueType:Fd,optionalCallExpression:Gu,optionalIndexedAccessType:lf,optionalMemberExpression:Wu,parenthesizedExpression:ru,placeholder:Tf,privateName:Yu,program:Xl,qualifiedTypeIdentifier:Id,regExpLiteral:Kl,regexLiteral:Zp,restElement:eu,restProperty:Qp,returnStatement:tu,sequenceExpression:nu,spreadElement:Pu,spreadProperty:$p,staticBlock:Xu,stringLiteral:Hl,stringLiteralTypeAnnotation:Ld,stringTypeAnnotation:Rd,super:Fu,switchCase:iu,switchStatement:au,symbolTypeAnnotation:zd,taggedTemplateExpression:Iu,templateElement:Lu,templateLiteral:Ru,thisExpression:ou,thisTypeAnnotation:Bd,throwStatement:su,topicReference:Pf,tryStatement:cu,tsAnyKeyword:Gf,tsArrayType:dp,tsAsExpression:Mp,tsBigIntKeyword:qf,tsBooleanKeyword:Kf,tsCallSignatureDeclaration:Bf,tsClassImplements:Ep,tsConditionalType:vp,tsConstructSignatureDeclaration:Vf,tsConstructorType:op,tsDeclareFunction:Lf,tsDeclareMethod:Rf,tsEnumBody:Fp,tsEnumDeclaration:Ip,tsEnumMember:Lp,tsExportAssignment:Wp,tsExternalModuleReference:Hp,tsFunctionType:ap,tsImportEqualsDeclaration:Vp,tsImportType:Bp,tsIndexSignature:Wf,tsIndexedAccessType:Sp,tsInferType:yp,tsInstantiationExpression:jp,tsInterfaceBody:kp,tsInterfaceDeclaration:Op,tsInterfaceHeritage:Dp,tsIntersectionType:_p,tsIntrinsicKeyword:Jf,tsLiteralType:Tp,tsMappedType:Cp,tsMethodSignature:Uf,tsModuleBlock:zp,tsModuleDeclaration:Rp,tsNamedTupleMember:hp,tsNamespaceExportDeclaration:Gp,tsNeverKeyword:Yf,tsNonNullExpression:Up,tsNullKeyword:Xf,tsNumberKeyword:Zf,tsObjectKeyword:Qf,tsOptionalType:pp,tsParameterProperty:If,tsParenthesizedType:bp,tsPropertySignature:Hf,tsQualifiedName:zf,tsRestType:mp,tsSatisfiesExpression:Np,tsStringKeyword:$f,tsSymbolKeyword:ep,tsTemplateLiteralType:wp,tsThisType:ip,tsTupleType:fp,tsTypeAliasDeclaration:Ap,tsTypeAnnotation:Kp,tsTypeAssertion:Pp,tsTypeLiteral:up,tsTypeOperator:xp,tsTypeParameter:Yp,tsTypeParameterDeclaration:Jp,tsTypeParameterInstantiation:qp,tsTypePredicate:cp,tsTypeQuery:lp,tsTypeReference:sp,tsUndefinedKeyword:tp,tsUnionType:gp,tsUnknownKeyword:np,tsVoidKeyword:rp,tupleTypeAnnotation:Vd,typeAlias:Ud,typeAnnotation:Wd,typeCastExpression:Gd,typeParameter:Kd,typeParameterDeclaration:qd,typeParameterInstantiation:Jd,typeofTypeAnnotation:Hd,unaryExpression:lu,unionTypeAnnotation:Yd,updateExpression:uu,v8IntrinsicIdentifier:Ef,variableDeclaration:du,variableDeclarator:fu,variance:Xd,voidPattern:Ff,voidTypeAnnotation:Zd,whileStatement:pu,withStatement:mu,yieldExpression:zu});function U(e){return function(){return w(e.replace(/^(?:ts|jsx|[a-z])/,e=>e.toUpperCase()),e,`Usage of builders starting with an uppercase letter such as `,`uppercase builders`),em[e](...arguments)}}const tm=U(`arrayExpression`),nm=U(`assignmentExpression`),rm=U(`binaryExpression`),im=U(`interpreterDirective`),am=U(`directive`),om=U(`directiveLiteral`),sm=U(`blockStatement`),cm=U(`breakStatement`),lm=U(`callExpression`),um=U(`catchClause`),dm=U(`conditionalExpression`),fm=U(`continueStatement`),pm=U(`debuggerStatement`),mm=U(`doWhileStatement`),hm=U(`emptyStatement`),gm=U(`expressionStatement`),_m=U(`file`),vm=U(`forInStatement`),ym=U(`forStatement`),bm=U(`functionDeclaration`),xm=U(`functionExpression`),Sm=U(`identifier`),Cm=U(`ifStatement`),wm=U(`labeledStatement`),Tm=U(`stringLiteral`),Em=U(`numericLiteral`),Dm=U(`nullLiteral`),Om=U(`booleanLiteral`),km=U(`regExpLiteral`),Am=U(`logicalExpression`),jm=U(`memberExpression`),Mm=U(`newExpression`),Nm=U(`program`),Pm=U(`objectExpression`),Fm=U(`objectMethod`),Im=U(`objectProperty`),Lm=U(`restElement`),Rm=U(`returnStatement`),zm=U(`sequenceExpression`),Bm=U(`parenthesizedExpression`),Vm=U(`switchCase`),Hm=U(`switchStatement`),Um=U(`thisExpression`),Wm=U(`throwStatement`),Gm=U(`tryStatement`),Km=U(`unaryExpression`),qm=U(`updateExpression`),Jm=U(`variableDeclaration`),Ym=U(`variableDeclarator`),Xm=U(`whileStatement`),Zm=U(`withStatement`),Qm=U(`assignmentPattern`),$m=U(`arrayPattern`),eh=U(`arrowFunctionExpression`),th=U(`classBody`),nh=U(`classExpression`),rh=U(`classDeclaration`),ih=U(`exportAllDeclaration`),ah=U(`exportDefaultDeclaration`),oh=U(`exportNamedDeclaration`),sh=U(`exportSpecifier`),ch=U(`forOfStatement`),lh=U(`importDeclaration`),uh=U(`importDefaultSpecifier`),dh=U(`importNamespaceSpecifier`),fh=U(`importSpecifier`),ph=U(`importExpression`),mh=U(`metaProperty`),hh=U(`classMethod`),gh=U(`objectPattern`),_h=U(`spreadElement`),vh=U(`super`),yh=U(`taggedTemplateExpression`),bh=U(`templateElement`),xh=U(`templateLiteral`),Sh=U(`yieldExpression`),Ch=U(`awaitExpression`),wh=U(`import`),Th=U(`bigIntLiteral`),Eh=U(`exportNamespaceSpecifier`),Dh=U(`optionalMemberExpression`),Oh=U(`optionalCallExpression`),kh=U(`classProperty`),Ah=U(`classPrivateProperty`),jh=U(`classPrivateMethod`),Mh=U(`privateName`),Nh=U(`staticBlock`),Ph=U(`importAttribute`),Fh=U(`anyTypeAnnotation`),Ih=U(`arrayTypeAnnotation`),Lh=U(`booleanTypeAnnotation`),Rh=U(`booleanLiteralTypeAnnotation`),zh=U(`nullLiteralTypeAnnotation`),Bh=U(`classImplements`),Vh=U(`declareClass`),Hh=U(`declareFunction`),Uh=U(`declareInterface`),Wh=U(`declareModule`),Gh=U(`declareModuleExports`),Kh=U(`declareTypeAlias`),qh=U(`declareOpaqueType`),Jh=U(`declareVariable`),Yh=U(`declareExportDeclaration`),Xh=U(`declareExportAllDeclaration`),Zh=U(`declaredPredicate`),Qh=U(`existsTypeAnnotation`),$h=U(`functionTypeAnnotation`),eg=U(`functionTypeParam`),tg=U(`genericTypeAnnotation`),ng=U(`inferredPredicate`),rg=U(`interfaceExtends`),ig=U(`interfaceDeclaration`),ag=U(`interfaceTypeAnnotation`),og=U(`intersectionTypeAnnotation`),sg=U(`mixedTypeAnnotation`),cg=U(`emptyTypeAnnotation`),lg=U(`nullableTypeAnnotation`),ug=U(`numberLiteralTypeAnnotation`),dg=U(`numberTypeAnnotation`),fg=U(`objectTypeAnnotation`),pg=U(`objectTypeInternalSlot`),mg=U(`objectTypeCallProperty`),hg=U(`objectTypeIndexer`),gg=U(`objectTypeProperty`),_g=U(`objectTypeSpreadProperty`),vg=U(`opaqueType`),yg=U(`qualifiedTypeIdentifier`),bg=U(`stringLiteralTypeAnnotation`),xg=U(`stringTypeAnnotation`),Sg=U(`symbolTypeAnnotation`),Cg=U(`thisTypeAnnotation`),wg=U(`tupleTypeAnnotation`),Tg=U(`typeofTypeAnnotation`),Eg=U(`typeAlias`),Dg=U(`typeAnnotation`),Og=U(`typeCastExpression`),kg=U(`typeParameter`),Ag=U(`typeParameterDeclaration`),jg=U(`typeParameterInstantiation`),Mg=U(`unionTypeAnnotation`),Ng=U(`variance`),Pg=U(`voidTypeAnnotation`),Fg=U(`enumDeclaration`),Ig=U(`enumBooleanBody`),Lg=U(`enumNumberBody`),Rg=U(`enumStringBody`),zg=U(`enumSymbolBody`),Bg=U(`enumBooleanMember`),Vg=U(`enumNumberMember`),Hg=U(`enumStringMember`),Ug=U(`enumDefaultedMember`),Wg=U(`indexedAccessType`),Gg=U(`optionalIndexedAccessType`),Kg=U(`jsxAttribute`),qg=U(`jsxClosingElement`),Jg=U(`jsxElement`),Yg=U(`jsxEmptyExpression`),Xg=U(`jsxExpressionContainer`),Zg=U(`jsxSpreadChild`),Qg=U(`jsxIdentifier`),$g=U(`jsxMemberExpression`),e_=U(`jsxNamespacedName`),t_=U(`jsxOpeningElement`),n_=U(`jsxSpreadAttribute`),r_=U(`jsxText`),i_=U(`jsxFragment`),a_=U(`jsxOpeningFragment`),o_=U(`jsxClosingFragment`),s_=U(`placeholder`),c_=U(`v8IntrinsicIdentifier`),l_=U(`argumentPlaceholder`),u_=U(`bindExpression`),d_=U(`classAccessorProperty`),f_=U(`decorator`),p_=U(`doExpression`),m_=U(`exportDefaultSpecifier`),h_=U(`moduleExpression`),g_=U(`topicReference`),__=U(`voidPattern`),v_=U(`tsParameterProperty`),y_=U(`tsDeclareFunction`),b_=U(`tsDeclareMethod`),x_=U(`tsQualifiedName`),S_=U(`tsCallSignatureDeclaration`),C_=U(`tsConstructSignatureDeclaration`),w_=U(`tsPropertySignature`),T_=U(`tsMethodSignature`),E_=U(`tsIndexSignature`),D_=U(`tsAnyKeyword`),O_=U(`tsBooleanKeyword`),k_=U(`tsBigIntKeyword`),A_=U(`tsIntrinsicKeyword`),j_=U(`tsNeverKeyword`),M_=U(`tsNullKeyword`),N_=U(`tsNumberKeyword`),P_=U(`tsObjectKeyword`),F_=U(`tsStringKeyword`),I_=U(`tsSymbolKeyword`),L_=U(`tsUndefinedKeyword`),R_=U(`tsUnknownKeyword`),z_=U(`tsVoidKeyword`),B_=U(`tsThisType`),V_=U(`tsFunctionType`),H_=U(`tsConstructorType`),U_=U(`tsTypeReference`),W_=U(`tsTypePredicate`),G_=U(`tsTypeQuery`),K_=U(`tsTypeLiteral`),q_=U(`tsArrayType`),J_=U(`tsTupleType`),Y_=U(`tsOptionalType`),X_=U(`tsRestType`),Z_=U(`tsNamedTupleMember`),Q_=U(`tsUnionType`),$_=U(`tsIntersectionType`),ev=U(`tsConditionalType`),tv=U(`tsInferType`),nv=U(`tsParenthesizedType`),rv=U(`tsTypeOperator`),iv=U(`tsIndexedAccessType`),av=U(`tsMappedType`),ov=U(`tsTemplateLiteralType`),sv=U(`tsLiteralType`),cv=U(`tsClassImplements`),lv=U(`tsInterfaceHeritage`),uv=U(`tsInterfaceDeclaration`),dv=U(`tsInterfaceBody`),fv=U(`tsTypeAliasDeclaration`),pv=U(`tsInstantiationExpression`),mv=U(`tsAsExpression`),hv=U(`tsSatisfiesExpression`),gv=U(`tsTypeAssertion`),_v=U(`tsEnumBody`),vv=U(`tsEnumDeclaration`),yv=U(`tsEnumMember`),bv=U(`tsModuleDeclaration`),xv=U(`tsModuleBlock`),Sv=U(`tsImportType`),Cv=U(`tsImportEqualsDeclaration`),wv=U(`tsExternalModuleReference`),Tv=U(`tsNonNullExpression`),Ev=U(`tsExportAssignment`),Dv=U(`tsNamespaceExportDeclaration`),Ov=U(`tsTypeAnnotation`),kv=U(`tsTypeParameterInstantiation`),Av=U(`tsTypeParameterDeclaration`),jv=U(`tsTypeParameter`);function Mv(e,t){let n=e.value.split(/\r\n|\n|\r/),r=0;for(let e=0;e<n.length;e++)/[^ \t]/.exec(n[e])&&(r=e);let i=``;for(let e=0;e<n.length;e++){let t=n[e],a=e===0,o=e===n.length-1,s=e===r,c=t.replace(/\t/g,` `);a||(c=c.replace(/^ +/,``)),o||(c=c.replace(/ +$/,``)),c&&(s||(c+=` `),i+=c)}i&&t.push(rE(Hl(i),e))}function Nv(e){let t=[];for(let n=0;n<e.children.length;n++){let r=e.children[n];if(xa(r)){Mv(r,t);continue}ma(r)&&(r=r.expression),!pa(r)&&t.push(r)}return t}function Pv(e){return!!(e&&Cc[e.type])}function Fv(e){if(!Pv(e)){let t=e?.type??JSON.stringify(e);throw TypeError(`Not a valid node of type "${t}"`)}}function W(e,t,n){if(!T(e,t,n))throw Error(`Expected type "${e}" with option ${JSON.stringify(n)}, but instead got "${t.type}".`)}function Iv(e,t){W(`ArrayExpression`,e,t)}function Lv(e,t){W(`AssignmentExpression`,e,t)}function Rv(e,t){W(`BinaryExpression`,e,t)}function zv(e,t){W(`InterpreterDirective`,e,t)}function Bv(e,t){W(`Directive`,e,t)}function Vv(e,t){W(`DirectiveLiteral`,e,t)}function Hv(e,t){W(`BlockStatement`,e,t)}function Uv(e,t){W(`BreakStatement`,e,t)}function Wv(e,t){W(`CallExpression`,e,t)}function Gv(e,t){W(`CatchClause`,e,t)}function Kv(e,t){W(`ConditionalExpression`,e,t)}function qv(e,t){W(`ContinueStatement`,e,t)}function Jv(e,t){W(`DebuggerStatement`,e,t)}function Yv(e,t){W(`DoWhileStatement`,e,t)}function Xv(e,t){W(`EmptyStatement`,e,t)}function Zv(e,t){W(`ExpressionStatement`,e,t)}function Qv(e,t){W(`File`,e,t)}function $v(e,t){W(`ForInStatement`,e,t)}function ey(e,t){W(`ForStatement`,e,t)}function ty(e,t){W(`FunctionDeclaration`,e,t)}function ny(e,t){W(`FunctionExpression`,e,t)}function ry(e,t){W(`Identifier`,e,t)}function iy(e,t){W(`IfStatement`,e,t)}function ay(e,t){W(`LabeledStatement`,e,t)}function oy(e,t){W(`StringLiteral`,e,t)}function sy(e,t){W(`NumericLiteral`,e,t)}function cy(e,t){W(`NullLiteral`,e,t)}function ly(e,t){W(`BooleanLiteral`,e,t)}function uy(e,t){W(`RegExpLiteral`,e,t)}function dy(e,t){W(`LogicalExpression`,e,t)}function fy(e,t){W(`MemberExpression`,e,t)}function py(e,t){W(`NewExpression`,e,t)}function my(e,t){W(`Program`,e,t)}function hy(e,t){W(`ObjectExpression`,e,t)}function gy(e,t){W(`ObjectMethod`,e,t)}function _y(e,t){W(`ObjectProperty`,e,t)}function vy(e,t){W(`RestElement`,e,t)}function yy(e,t){W(`ReturnStatement`,e,t)}function by(e,t){W(`SequenceExpression`,e,t)}function xy(e,t){W(`ParenthesizedExpression`,e,t)}function Sy(e,t){W(`SwitchCase`,e,t)}function Cy(e,t){W(`SwitchStatement`,e,t)}function wy(e,t){W(`ThisExpression`,e,t)}function Ty(e,t){W(`ThrowStatement`,e,t)}function Ey(e,t){W(`TryStatement`,e,t)}function Dy(e,t){W(`UnaryExpression`,e,t)}function Oy(e,t){W(`UpdateExpression`,e,t)}function ky(e,t){W(`VariableDeclaration`,e,t)}function Ay(e,t){W(`VariableDeclarator`,e,t)}function jy(e,t){W(`WhileStatement`,e,t)}function My(e,t){W(`WithStatement`,e,t)}function Ny(e,t){W(`AssignmentPattern`,e,t)}function Py(e,t){W(`ArrayPattern`,e,t)}function Fy(e,t){W(`ArrowFunctionExpression`,e,t)}function Iy(e,t){W(`ClassBody`,e,t)}function Ly(e,t){W(`ClassExpression`,e,t)}function Ry(e,t){W(`ClassDeclaration`,e,t)}function zy(e,t){W(`ExportAllDeclaration`,e,t)}function By(e,t){W(`ExportDefaultDeclaration`,e,t)}function Vy(e,t){W(`ExportNamedDeclaration`,e,t)}function Hy(e,t){W(`ExportSpecifier`,e,t)}function Uy(e,t){W(`ForOfStatement`,e,t)}function Wy(e,t){W(`ImportDeclaration`,e,t)}function Gy(e,t){W(`ImportDefaultSpecifier`,e,t)}function Ky(e,t){W(`ImportNamespaceSpecifier`,e,t)}function qy(e,t){W(`ImportSpecifier`,e,t)}function Jy(e,t){W(`ImportExpression`,e,t)}function Yy(e,t){W(`MetaProperty`,e,t)}function Xy(e,t){W(`ClassMethod`,e,t)}function Zy(e,t){W(`ObjectPattern`,e,t)}function Qy(e,t){W(`SpreadElement`,e,t)}function $y(e,t){W(`Super`,e,t)}function eb(e,t){W(`TaggedTemplateExpression`,e,t)}function tb(e,t){W(`TemplateElement`,e,t)}function nb(e,t){W(`TemplateLiteral`,e,t)}function rb(e,t){W(`YieldExpression`,e,t)}function ib(e,t){W(`AwaitExpression`,e,t)}function ab(e,t){W(`Import`,e,t)}function ob(e,t){W(`BigIntLiteral`,e,t)}function sb(e,t){W(`ExportNamespaceSpecifier`,e,t)}function cb(e,t){W(`OptionalMemberExpression`,e,t)}function lb(e,t){W(`OptionalCallExpression`,e,t)}function ub(e,t){W(`ClassProperty`,e,t)}function db(e,t){W(`ClassPrivateProperty`,e,t)}function fb(e,t){W(`ClassPrivateMethod`,e,t)}function pb(e,t){W(`PrivateName`,e,t)}function mb(e,t){W(`StaticBlock`,e,t)}function hb(e,t){W(`ImportAttribute`,e,t)}function gb(e,t){W(`AnyTypeAnnotation`,e,t)}function _b(e,t){W(`ArrayTypeAnnotation`,e,t)}function vb(e,t){W(`BooleanTypeAnnotation`,e,t)}function yb(e,t){W(`BooleanLiteralTypeAnnotation`,e,t)}function bb(e,t){W(`NullLiteralTypeAnnotation`,e,t)}function xb(e,t){W(`ClassImplements`,e,t)}function Sb(e,t){W(`DeclareClass`,e,t)}function Cb(e,t){W(`DeclareFunction`,e,t)}function wb(e,t){W(`DeclareInterface`,e,t)}function Tb(e,t){W(`DeclareModule`,e,t)}function Eb(e,t){W(`DeclareModuleExports`,e,t)}function Db(e,t){W(`DeclareTypeAlias`,e,t)}function Ob(e,t){W(`DeclareOpaqueType`,e,t)}function kb(e,t){W(`DeclareVariable`,e,t)}function Ab(e,t){W(`DeclareExportDeclaration`,e,t)}function jb(e,t){W(`DeclareExportAllDeclaration`,e,t)}function Mb(e,t){W(`DeclaredPredicate`,e,t)}function Nb(e,t){W(`ExistsTypeAnnotation`,e,t)}function Pb(e,t){W(`FunctionTypeAnnotation`,e,t)}function Fb(e,t){W(`FunctionTypeParam`,e,t)}function Ib(e,t){W(`GenericTypeAnnotation`,e,t)}function Lb(e,t){W(`InferredPredicate`,e,t)}function Rb(e,t){W(`InterfaceExtends`,e,t)}function zb(e,t){W(`InterfaceDeclaration`,e,t)}function Bb(e,t){W(`InterfaceTypeAnnotation`,e,t)}function Vb(e,t){W(`IntersectionTypeAnnotation`,e,t)}function Hb(e,t){W(`MixedTypeAnnotation`,e,t)}function Ub(e,t){W(`EmptyTypeAnnotation`,e,t)}function Wb(e,t){W(`NullableTypeAnnotation`,e,t)}function Gb(e,t){W(`NumberLiteralTypeAnnotation`,e,t)}function Kb(e,t){W(`NumberTypeAnnotation`,e,t)}function qb(e,t){W(`ObjectTypeAnnotation`,e,t)}function Jb(e,t){W(`ObjectTypeInternalSlot`,e,t)}function Yb(e,t){W(`ObjectTypeCallProperty`,e,t)}function Xb(e,t){W(`ObjectTypeIndexer`,e,t)}function Zb(e,t){W(`ObjectTypeProperty`,e,t)}function Qb(e,t){W(`ObjectTypeSpreadProperty`,e,t)}function $b(e,t){W(`OpaqueType`,e,t)}function ex(e,t){W(`QualifiedTypeIdentifier`,e,t)}function tx(e,t){W(`StringLiteralTypeAnnotation`,e,t)}function nx(e,t){W(`StringTypeAnnotation`,e,t)}function rx(e,t){W(`SymbolTypeAnnotation`,e,t)}function ix(e,t){W(`ThisTypeAnnotation`,e,t)}function ax(e,t){W(`TupleTypeAnnotation`,e,t)}function ox(e,t){W(`TypeofTypeAnnotation`,e,t)}function sx(e,t){W(`TypeAlias`,e,t)}function cx(e,t){W(`TypeAnnotation`,e,t)}function lx(e,t){W(`TypeCastExpression`,e,t)}function ux(e,t){W(`TypeParameter`,e,t)}function dx(e,t){W(`TypeParameterDeclaration`,e,t)}function fx(e,t){W(`TypeParameterInstantiation`,e,t)}function px(e,t){W(`UnionTypeAnnotation`,e,t)}function mx(e,t){W(`Variance`,e,t)}function hx(e,t){W(`VoidTypeAnnotation`,e,t)}function gx(e,t){W(`EnumDeclaration`,e,t)}function _x(e,t){W(`EnumBooleanBody`,e,t)}function vx(e,t){W(`EnumNumberBody`,e,t)}function yx(e,t){W(`EnumStringBody`,e,t)}function bx(e,t){W(`EnumSymbolBody`,e,t)}function xx(e,t){W(`EnumBooleanMember`,e,t)}function Sx(e,t){W(`EnumNumberMember`,e,t)}function Cx(e,t){W(`EnumStringMember`,e,t)}function wx(e,t){W(`EnumDefaultedMember`,e,t)}function Tx(e,t){W(`IndexedAccessType`,e,t)}function Ex(e,t){W(`OptionalIndexedAccessType`,e,t)}function Dx(e,t){W(`JSXAttribute`,e,t)}function Ox(e,t){W(`JSXClosingElement`,e,t)}function kx(e,t){W(`JSXElement`,e,t)}function Ax(e,t){W(`JSXEmptyExpression`,e,t)}function jx(e,t){W(`JSXExpressionContainer`,e,t)}function Mx(e,t){W(`JSXSpreadChild`,e,t)}function Nx(e,t){W(`JSXIdentifier`,e,t)}function Px(e,t){W(`JSXMemberExpression`,e,t)}function Fx(e,t){W(`JSXNamespacedName`,e,t)}function Ix(e,t){W(`JSXOpeningElement`,e,t)}function Lx(e,t){W(`JSXSpreadAttribute`,e,t)}function Rx(e,t){W(`JSXText`,e,t)}function zx(e,t){W(`JSXFragment`,e,t)}function Bx(e,t){W(`JSXOpeningFragment`,e,t)}function Vx(e,t){W(`JSXClosingFragment`,e,t)}function Hx(e,t){W(`Placeholder`,e,t)}function Ux(e,t){W(`V8IntrinsicIdentifier`,e,t)}function Wx(e,t){W(`ArgumentPlaceholder`,e,t)}function Gx(e,t){W(`BindExpression`,e,t)}function Kx(e,t){W(`ClassAccessorProperty`,e,t)}function qx(e,t){W(`Decorator`,e,t)}function Jx(e,t){W(`DoExpression`,e,t)}function Yx(e,t){W(`ExportDefaultSpecifier`,e,t)}function Xx(e,t){W(`ModuleExpression`,e,t)}function Zx(e,t){W(`TopicReference`,e,t)}function Qx(e,t){W(`VoidPattern`,e,t)}function $x(e,t){W(`TSParameterProperty`,e,t)}function eS(e,t){W(`TSDeclareFunction`,e,t)}function tS(e,t){W(`TSDeclareMethod`,e,t)}function nS(e,t){W(`TSQualifiedName`,e,t)}function rS(e,t){W(`TSCallSignatureDeclaration`,e,t)}function iS(e,t){W(`TSConstructSignatureDeclaration`,e,t)}function aS(e,t){W(`TSPropertySignature`,e,t)}function oS(e,t){W(`TSMethodSignature`,e,t)}function sS(e,t){W(`TSIndexSignature`,e,t)}function cS(e,t){W(`TSAnyKeyword`,e,t)}function lS(e,t){W(`TSBooleanKeyword`,e,t)}function uS(e,t){W(`TSBigIntKeyword`,e,t)}function dS(e,t){W(`TSIntrinsicKeyword`,e,t)}function fS(e,t){W(`TSNeverKeyword`,e,t)}function pS(e,t){W(`TSNullKeyword`,e,t)}function mS(e,t){W(`TSNumberKeyword`,e,t)}function hS(e,t){W(`TSObjectKeyword`,e,t)}function gS(e,t){W(`TSStringKeyword`,e,t)}function _S(e,t){W(`TSSymbolKeyword`,e,t)}function vS(e,t){W(`TSUndefinedKeyword`,e,t)}function yS(e,t){W(`TSUnknownKeyword`,e,t)}function bS(e,t){W(`TSVoidKeyword`,e,t)}function xS(e,t){W(`TSThisType`,e,t)}function SS(e,t){W(`TSFunctionType`,e,t)}function CS(e,t){W(`TSConstructorType`,e,t)}function wS(e,t){W(`TSTypeReference`,e,t)}function TS(e,t){W(`TSTypePredicate`,e,t)}function ES(e,t){W(`TSTypeQuery`,e,t)}function DS(e,t){W(`TSTypeLiteral`,e,t)}function OS(e,t){W(`TSArrayType`,e,t)}function kS(e,t){W(`TSTupleType`,e,t)}function AS(e,t){W(`TSOptionalType`,e,t)}function jS(e,t){W(`TSRestType`,e,t)}function MS(e,t){W(`TSNamedTupleMember`,e,t)}function NS(e,t){W(`TSUnionType`,e,t)}function PS(e,t){W(`TSIntersectionType`,e,t)}function FS(e,t){W(`TSConditionalType`,e,t)}function IS(e,t){W(`TSInferType`,e,t)}function LS(e,t){W(`TSParenthesizedType`,e,t)}function RS(e,t){W(`TSTypeOperator`,e,t)}function zS(e,t){W(`TSIndexedAccessType`,e,t)}function BS(e,t){W(`TSMappedType`,e,t)}function VS(e,t){W(`TSTemplateLiteralType`,e,t)}function HS(e,t){W(`TSLiteralType`,e,t)}function US(e,t){W(`TSClassImplements`,e,t)}function WS(e,t){W(`TSInterfaceHeritage`,e,t)}function GS(e,t){W(`TSInterfaceDeclaration`,e,t)}function KS(e,t){W(`TSInterfaceBody`,e,t)}function qS(e,t){W(`TSTypeAliasDeclaration`,e,t)}function JS(e,t){W(`TSInstantiationExpression`,e,t)}function YS(e,t){W(`TSAsExpression`,e,t)}function XS(e,t){W(`TSSatisfiesExpression`,e,t)}function ZS(e,t){W(`TSTypeAssertion`,e,t)}function QS(e,t){W(`TSEnumBody`,e,t)}function $S(e,t){W(`TSEnumDeclaration`,e,t)}function eC(e,t){W(`TSEnumMember`,e,t)}function tC(e,t){W(`TSModuleDeclaration`,e,t)}function nC(e,t){W(`TSModuleBlock`,e,t)}function rC(e,t){W(`TSImportType`,e,t)}function iC(e,t){W(`TSImportEqualsDeclaration`,e,t)}function aC(e,t){W(`TSExternalModuleReference`,e,t)}function oC(e,t){W(`TSNonNullExpression`,e,t)}function sC(e,t){W(`TSExportAssignment`,e,t)}function cC(e,t){W(`TSNamespaceExportDeclaration`,e,t)}function lC(e,t){W(`TSTypeAnnotation`,e,t)}function uC(e,t){W(`TSTypeParameterInstantiation`,e,t)}function dC(e,t){W(`TSTypeParameterDeclaration`,e,t)}function fC(e,t){W(`TSTypeParameter`,e,t)}function pC(e,t){W(`Standardized`,e,t)}function mC(e,t){W(`Expression`,e,t)}function hC(e,t){W(`Binary`,e,t)}function gC(e,t){W(`Scopable`,e,t)}function _C(e,t){W(`BlockParent`,e,t)}function vC(e,t){W(`Block`,e,t)}function yC(e,t){W(`Statement`,e,t)}function bC(e,t){W(`Terminatorless`,e,t)}function xC(e,t){W(`CompletionStatement`,e,t)}function SC(e,t){W(`Conditional`,e,t)}function CC(e,t){W(`Loop`,e,t)}function wC(e,t){W(`While`,e,t)}function TC(e,t){W(`ExpressionWrapper`,e,t)}function EC(e,t){W(`For`,e,t)}function DC(e,t){W(`ForXStatement`,e,t)}function OC(e,t){W(`Function`,e,t)}function kC(e,t){W(`FunctionParent`,e,t)}function AC(e,t){W(`Pureish`,e,t)}function jC(e,t){W(`Declaration`,e,t)}function MC(e,t){W(`FunctionParameter`,e,t)}function NC(e,t){W(`PatternLike`,e,t)}function PC(e,t){W(`LVal`,e,t)}function FC(e,t){W(`TSEntityName`,e,t)}function IC(e,t){W(`Literal`,e,t)}function LC(e,t){W(`Immutable`,e,t)}function RC(e,t){W(`UserWhitespacable`,e,t)}function zC(e,t){W(`Method`,e,t)}function BC(e,t){W(`ObjectMember`,e,t)}function VC(e,t){W(`Property`,e,t)}function HC(e,t){W(`UnaryLike`,e,t)}function UC(e,t){W(`Pattern`,e,t)}function WC(e,t){W(`Class`,e,t)}function GC(e,t){W(`ImportOrExportDeclaration`,e,t)}function KC(e,t){W(`ExportDeclaration`,e,t)}function qC(e,t){W(`ModuleSpecifier`,e,t)}function JC(e,t){W(`Private`,e,t)}function YC(e,t){W(`Flow`,e,t)}function XC(e,t){W(`FlowType`,e,t)}function ZC(e,t){W(`FlowBaseAnnotation`,e,t)}function QC(e,t){W(`FlowDeclaration`,e,t)}function $C(e,t){W(`FlowPredicate`,e,t)}function ew(e,t){W(`EnumBody`,e,t)}function tw(e,t){W(`EnumMember`,e,t)}function nw(e,t){W(`JSX`,e,t)}function rw(e,t){W(`Miscellaneous`,e,t)}function iw(e,t){W(`Accessor`,e,t)}function aw(e,t){W(`TypeScript`,e,t)}function ow(e,t){W(`TSTypeElement`,e,t)}function sw(e,t){W(`TSType`,e,t)}function cw(e,t){W(`TSBaseType`,e,t)}function lw(e,t){w(`assertNumberLiteral`,`assertNumericLiteral`),W(`NumberLiteral`,e,t)}function uw(e,t){w(`assertRegexLiteral`,`assertRegExpLiteral`),W(`RegexLiteral`,e,t)}function dw(e,t){w(`assertRestProperty`,`assertRestElement`),W(`RestProperty`,e,t)}function fw(e,t){w(`assertSpreadProperty`,`assertSpreadElement`),W(`SpreadProperty`,e,t)}function pw(e,t){w(`assertModuleDeclaration`,`assertImportOrExportDeclaration`),W(`ModuleDeclaration`,e,t)}function mw(e){switch(e){case`string`:return Rd();case`number`:return Od();case`undefined`:return Zd();case`boolean`:return ed();case`function`:return vd(H(`Function`));case`object`:return vd(H(`Object`));case`symbol`:return vd(H(`Symbol`));case`bigint`:return Qu()}throw Error(`Invalid typeof value: `+e)}function hw(e){return Bn(e)?e.name:`${e.id.name}.${hw(e.qualification)}`}function gw(e){let t=Array.from(e),n=new Map,r=new Map,i=new Set,a=[];for(let e=0;e<t.length;e++){let o=t[e];if(o&&!a.includes(o)){if($r(o))return[o];if(Ps(o)){r.set(o.type,o);continue}if(Xi(o)){i.has(o.types)||(t.push(...o.types),i.add(o.types));continue}if(yi(o)){let e=hw(o.id);if(n.has(e)){let t=n.get(e);t.typeParameters?o.typeParameters&&(t.typeParameters.params.push(...o.typeParameters.params),t.typeParameters.params=gw(t.typeParameters.params)):t=o.typeParameters}else n.set(e,o);continue}a.push(o)}}for(let[,e]of r)a.push(e);for(let[,e]of n)a.push(e);return a}function _w(e){let t=gw(e);return t.length===1?t[0]:Yd(t)}function vw(e){return Bn(e)?e.name:sr(e)?`this`:`${e.right.name}.${vw(e.left)}`}function yw(e){let t=Array.from(e),n=new Map,r=new Map,i=new Set,a=[];for(let e=0;e<t.length;e++){let o=t[e];if(!o||a.includes(o))continue;if(Ga(o))return[o];if(Gs(o)){r.set(o.type,o);continue}if(_o(o)){i.has(o.types)||(t.push(...o.types),i.add(o.types));continue}let s=`typeArguments`;if(so(o)&&o[s]){let e=o[s],t=vw(o.typeName);if(n.has(t)){let r=n.get(t),i=r[s];i?(i.params.push(...e.params),i.params=yw(i.params)):r=e}else n.set(t,o);continue}a.push(o)}for(let[,e]of r)a.push(e);for(let[,e]of n)a.push(e);return a}function bw(e){let t=yw(e.map(e=>qo(e)?e.typeAnnotation:e));return t.length===1?t[0]:gp(t)}function xw(){return lu(`void`,Ul(0),!0)}const{hasOwn:Sw}=Object;function Cw(e,t,n,r){return e&&typeof e.type==`string`?Ew(e,t,n,r):e}function ww(e,t,n,r){return Array.isArray(e)?e.map(e=>Cw(e,t,n,r)):Cw(e,t,n,r)}function Tw(e,t=!0,n=!1){return Ew(e,t,n,new Map)}function Ew(e,t=!0,n=!1,r){if(!e)return e;let{type:i}=e,a={type:e.type};if(Bn(e))a.name=e.name,Sw(e,`optional`)&&typeof e.optional==`boolean`&&(a.optional=e.optional),Sw(e,`typeAnnotation`)&&(a.typeAnnotation=t?ww(e.typeAnnotation,!0,n,r):e.typeAnnotation),Sw(e,`decorators`)&&(a.decorators=t?ww(e.decorators,!0,n,r):e.decorators);else if(Sw(Tc,i))for(let o of Object.keys(Tc[i]))Sw(e,o)&&(t?a[o]=Fn(e)&&o===`comments`?Dw(e.comments,t,n,r):ww(e[o],!0,n,r):a[o]=e[o]);else throw Error(`Unknown node type: "${i}"`);return Sw(e,`loc`)&&(n?a.loc=null:a.loc=e.loc),Sw(e,`leadingComments`)&&(a.leadingComments=Dw(e.leadingComments,t,n,r)),Sw(e,`innerComments`)&&(a.innerComments=Dw(e.innerComments,t,n,r)),Sw(e,`trailingComments`)&&(a.trailingComments=Dw(e.trailingComments,t,n,r)),Sw(e,`extra`)&&(a.extra={...e.extra}),a}function Dw(e,t,n,r){return!e||!t?e:e.map(e=>{let t=r.get(e);if(t)return t;let{type:i,value:a,loc:o}=e,s={type:i,value:a,loc:o};return n&&(s.loc=void 0),r.set(e,s),s})}function Ow(e){return Tw(e,!1)}function kw(e){return Tw(e)}function Aw(e){return Tw(e,!0,!0)}function jw(e){return Tw(e,!1,!0)}function Mw(e,t,n){if(!n||!e)return e;let r=`${t}Comments`;return e[r]?t===`leading`?e[r]=n.concat(e[r]):e[r].push(...n):e[r]=n,e}function Nw(e,t,n,r){return Mw(e,t,[{type:r?`CommentLine`:`CommentBlock`,value:n}])}function Pw(e,t,n){t&&n&&(t[e]=Array.from(new Set([].concat(t[e],n[e]).filter(Boolean))))}function Fw(e,t){Pw(`innerComments`,e,t)}function Iw(e,t){Pw(`leadingComments`,e,t)}function Lw(e,t){Pw(`trailingComments`,e,t)}function Rw(e,t){return Lw(e,t),Iw(e,t),Fw(e,t),e}function zw(e){return cc.forEach(t=>{e[t]=null}),e}const Bw=E.Standardized,Vw=E.Expression,Hw=E.Binary,Uw=E.Scopable,Ww=E.BlockParent,Gw=E.Block,Kw=E.Statement,qw=E.Terminatorless,Jw=E.CompletionStatement,Yw=E.Conditional,Xw=E.Loop,Zw=E.While,Qw=E.ExpressionWrapper,$w=E.For,eT=E.ForXStatement,tT=E.Function,nT=E.FunctionParent,rT=E.Pureish,iT=E.Declaration,aT=E.FunctionParameter,oT=E.PatternLike,sT=E.LVal,cT=E.TSEntityName,lT=E.Literal,uT=E.Immutable,dT=E.UserWhitespacable,fT=E.Method,pT=E.ObjectMember,mT=E.Property,hT=E.UnaryLike,gT=E.Pattern,_T=E.Class,vT=E.ImportOrExportDeclaration,yT=E.ExportDeclaration,bT=E.ModuleSpecifier,xT=E.Private,ST=E.Flow,CT=E.FlowType,wT=E.FlowBaseAnnotation,TT=E.FlowDeclaration,ET=E.FlowPredicate,DT=E.EnumBody,OT=E.EnumMember,kT=E.JSX,AT=E.Miscellaneous,jT=E.Accessor,MT=E.TypeScript,NT=E.TSTypeElement,PT=E.TSType,FT=E.TSBaseType,IT=vT;function LT(e,t){if(Tn(e))return e;let n=[];return Nn(e)?n=[]:(rs(e)||(e=fs(t)?tu(e):Pl(e)),n=[e]),Tl(n)}function RT(e,t=`body`){let n=LT(e[t],e);return e[t]=n,n}function zT(e){e+=``;let t=``;for(let n of e)t+=Qt(n.codePointAt(0))?n:`-`;return t=t.replace(/^[-0-9]+/,``),t=t.replace(/[-\s]+(.)?/g,function(e,t){return t?t.toUpperCase():``}),ic(t)||(t=`_${t}`),t||`_`}function BT(e){return e=zT(e),(e===`eval`||e===`arguments`)&&(e=`_`+e),e}function VT(e,t=e.key||e.property){return!e.computed&&Bn(t)&&(t=Hl(t.name)),t}function HT(e){if(Pn(e)&&(e=e.expression),Qo(e))return e;if(Ds(e)?(e.type=`ClassExpression`,e.abstract=!1):fs(e)&&(e.type=`FunctionExpression`),!Qo(e))throw Error(`cannot turn ${e.type} to an expression`);return e}const UT=Symbol(),WT=Symbol();function GT(e,t,n){if(!e)return!1;let r=Cc[e.type];if(!r)return!1;n||={};let i=t(e,n);if(i!==void 0)switch(i){case UT:return!1;case WT:return!0}for(let i of r){let r=e[i];if(r){if(Array.isArray(r)){for(let e of r)if(GT(e,t,n))return!0}else if(GT(r,t,n))return!0}}return!1}GT.skip=UT,GT.stop=WT;const KT=[`tokens`,`start`,`end`,`loc`,`raw`,`rawValue`],qT=[...cc,`comments`,...KT];function JT(e,t={}){let n=t.preserveComments?KT:qT;for(let t of n)e[t]!=null&&(e[t]=void 0);for(let t of Object.keys(e))t.startsWith(`_`)&&e[t]!=null&&(e[t]=void 0);let r=Object.getOwnPropertySymbols(e);for(let t of r)e[t]=null}function YT(e,t){return GT(e,JT,t),e}function XT(e,t=e.key){let n;return e.kind===`method`?XT.increment()+``:(n=Bn(t)?t.name:Un(t)?JSON.stringify(t.value):JSON.stringify(YT(Tw(t))),e.computed&&(n=`[${n}]`),e.static&&(n=`static:${n}`),n)}XT.uid=0,XT.increment=function(){return XT.uid>=2**53-1?XT.uid=0:XT.uid++};function ZT(e,t){if(rs(e))return e;let n=!1,r;if(Ds(e))n=!0,r=`ClassDeclaration`;else if(fs(e))n=!0,r=`FunctionDeclaration`;else if(bn(e))return Pl(e);if(n&&!e.id&&(r=!1),!r){if(t)return!1;throw Error(`cannot turn ${e.type} to a statement`)}return e.type=r,e}const QT=Function.call.bind(Object.prototype.toString);function $T(e){return QT(e)===`[object RegExp]`}function eE(e){if(typeof e!=`object`||!e||Object.prototype.toString.call(e)!==`[object Object]`)return!1;let t=Object.getPrototypeOf(e);return t===null||Object.getPrototypeOf(t)===null}function tE(e){if(e===void 0)return H(`undefined`);if(e===!0||e===!1)return Gl(e);if(e===null)return Wl();if(typeof e==`string`)return Hl(e);if(typeof e==`number`){let t;if(Number.isFinite(e))t=Ul(Math.abs(e));else{let n;n=Ul(Number.isNaN(e)?0:1),t=xl(`/`,n,Ul(0))}return(e<0||Object.is(e,-0))&&(t=lu(`-`,t)),t}if(typeof e==`bigint`)return e<0?lu(`-`,Hu(-e)):Hu(e);if($T(e)){let t=e.source,n=/\/([a-z]*)$/.exec(e.toString())[1];return Kl(t,n)}if(Array.isArray(e))return yl(e.map(tE));if(eE(e)){let t=[];for(let n of Object.keys(e)){let r,i=!1;ic(n)?n===`__proto__`?(i=!0,r=Hl(n)):r=H(n):r=Hl(n),t.push($l(r,tE(e[n]),i))}return Zl(t)}throw Error(`don't know how to turn this value into a node`)}function nE(e,t,n=!1){return e.object=Jl(e.object,e.property,e.computed),e.property=t,e.computed=!!n,e}function rE(e,t){if(!e||!t)return e;for(let n of Sc.optional)e[n]??(e[n]=t[n]);for(let n of Object.keys(t))n.startsWith(`_`)&&n!==`__clone`&&(e[n]=t[n]);for(let n of Sc.force)e[n]=t[n];return Rw(e,t),e}function iE(e,t){if(Ir(e.object))throw Error("Cannot prepend node to super property access (`super.foo`).");return e.object=Jl(t,e.object),e}function aE(e){let t=[].concat(e),n=Object.create(null);for(;t.length;){let e=t.pop();if(e)switch(e.type){case`ArrayPattern`:t.push(...e.elements);break;case`AssignmentExpression`:case`AssignmentPattern`:case`ForInStatement`:case`ForOfStatement`:t.push(e.left);break;case`ObjectPattern`:t.push(...e.properties);break;case`ObjectProperty`:t.push(e.value);break;case`RestElement`:case`UpdateExpression`:t.push(e.argument);break;case`UnaryExpression`:e.operator===`delete`&&t.push(e.argument);break;case`Identifier`:n[e.name]=e;break}}return n}function oE(e,t,n,r){let i=[].concat(e),a=Object.create(null);for(;i.length;){let e=i.shift();if(!e||r&&(bn(e)||ur(e)||dr(e)))continue;if(Bn(e)){t?(a[e.name]=a[e.name]||[]).push(e):a[e.name]=e;continue}if(ks(e)&&!Sr(e)){hs(e.declaration)&&i.push(e.declaration);continue}if(n){if(Rn(e)){i.push(e.id);continue}if(zn(e)||br(e))continue}let o=oE.keys[e.type];if(o)for(let t=0;t<o.length;t++){let n=e[o[t]];n&&(Array.isArray(n)?i.push(...n):i.push(n))}}return a}oE.keys={DeclareClass:[`id`],DeclareFunction:[`id`],DeclareModule:[`id`],DeclareVariable:[`id`],DeclareInterface:[`id`],DeclareTypeAlias:[`id`],DeclareOpaqueType:[`id`],InterfaceDeclaration:[`id`],TypeAlias:[`id`],OpaqueType:[`id`],CatchClause:[`param`],LabeledStatement:[`label`],UnaryExpression:[`argument`],AssignmentExpression:[`left`],ImportSpecifier:[`local`],ImportNamespaceSpecifier:[`local`],ImportDefaultSpecifier:[`local`],ImportDeclaration:[`specifiers`],TSImportEqualsDeclaration:[`id`],ExportSpecifier:[`exported`],ExportNamespaceSpecifier:[`exported`],ExportDefaultSpecifier:[`exported`],FunctionDeclaration:[`id`,`params`],FunctionExpression:[`id`,`params`],ArrowFunctionExpression:[`params`],ObjectMethod:[`params`],ClassMethod:[`params`],ClassPrivateMethod:[`params`],ForInStatement:[`left`],ForOfStatement:[`left`],ClassDeclaration:[`id`],ClassExpression:[`id`],RestElement:[`argument`],UpdateExpression:[`argument`],ObjectProperty:[`value`],AssignmentPattern:[`left`],ArrayPattern:[`elements`],ObjectPattern:[`properties`],VariableDeclaration:[`declarations`],VariableDeclarator:[`id`]};function sE(e,t){return oE(e,t,!0)}function cE(e){return Gn(e)?`null`:qn(e)?`/${e.pattern}/${e.flags}`:zr(e)?e.quasis.map(e=>e.value.raw).join(``):e.value===void 0?null:String(e.value)}function lE(e){return!e.computed||bs(e.key)?e.key:null}function uE(e,t){if(`id`in e&&e.id)return{name:e.id.name,originalNode:e.id};let n=``,r;if(er(t,{value:e})?r=lE(t):$n(e)||Nr(e)?(r=lE(e),e.kind===`get`?n=`get `:e.kind===`set`&&(n=`set `)):pr(t)&&t.init===e?r=t.id:bn(t,{operator:`=`,right:e})&&(r=t.left),!r)return null;let i=bs(r)?cE(r):Bn(r)?r.name:Xr(r)?r.id.name:null;return i==null?null:{name:n+i,originalNode:r}}function dE(e,t,n){typeof t==`function`&&(t={enter:t});let{enter:r,exit:i}=t;fE(e,r,i,n,[])}function fE(e,t,n,r,i){let a=Cc[e.type];if(a){t&&t(e,i,r);for(let o of a){let a=e[o];if(Array.isArray(a))for(let s=0;s<a.length;s++){let c=a[s];c&&(i.push({node:e,key:o,index:s}),fE(c,t,n,r,i),i.pop())}else a&&(i.push({node:e,key:o}),fE(a,t,n,r,i),i.pop())}n&&n(e,i,r)}}function pE(e,t,n){if(n&&e.type===`Identifier`&&t.type===`ObjectProperty`&&n.type===`ObjectExpression`)return!1;let r=oE.keys[t.type];if(r)for(let n=0;n<r.length;n++){let i=t[r[n]];if(Array.isArray(i)){if(i.includes(e))return!0}else if(i===e)return!0}return!1}function mE(e){return fr(e)&&e.kind!==`var`}function hE(e){return Rn(e)||xr(e)||mE(e)}function gE(e){return nc(e.type,`Immutable`)?!0:Bn(e)?e.name===`undefined`:!1}function _E(e,t){if(typeof e!=`object`||typeof t!=`object`||e==null||t==null)return e===t;if(e.type!==t.type)return!1;let n=Object.keys(Tc[e.type]||e.type),r=Cc[e.type];for(let i of n){let n=e[i],a=t[i];if(typeof n!=typeof a)return!1;if(!(n==null&&a==null)){if(n==null||a==null)return!1;if(Array.isArray(n)){if(!Array.isArray(a)||n.length!==a.length)return!1;for(let e=0;e<n.length;e++)if(!_E(n[e],a[e]))return!1;continue}if(typeof n==`object`&&!r?.includes(i)){for(let e of Object.keys(n))if(n[e]!==a[e])return!1;continue}if(!_E(n,a))return!1}}return!0}function vE(e,t,n){switch(t.type){case`MemberExpression`:case`OptionalMemberExpression`:return t.property===e?!!t.computed:t.object===e;case`JSXMemberExpression`:return t.object===e;case`VariableDeclarator`:return t.init===e;case`ArrowFunctionExpression`:return t.body===e;case`PrivateName`:return!1;case`ClassMethod`:case`ClassPrivateMethod`:case`ObjectMethod`:return t.key===e?!!t.computed:!1;case`ObjectProperty`:return t.key===e?!!t.computed:n?.type!==`ObjectPattern`;case`ClassProperty`:case`ClassAccessorProperty`:return t.key===e?!!t.computed:!0;case`ClassPrivateProperty`:return t.key!==e;case`ClassDeclaration`:case`ClassExpression`:return t.superClass===e;case`AssignmentExpression`:return t.right===e;case`AssignmentPattern`:return t.right===e;case`LabeledStatement`:return!1;case`CatchClause`:return!1;case`RestElement`:return!1;case`BreakStatement`:case`ContinueStatement`:return!1;case`FunctionDeclaration`:case`FunctionExpression`:return!1;case`ExportNamespaceSpecifier`:case`ExportDefaultSpecifier`:return!1;case`ExportSpecifier`:return n?.source?!1:t.local===e;case`ImportDefaultSpecifier`:case`ImportNamespaceSpecifier`:case`ImportSpecifier`:return!1;case`ImportAttribute`:return!1;case`JSXAttribute`:return!1;case`ObjectPattern`:case`ArrayPattern`:return!1;case`MetaProperty`:return!1;case`ObjectTypeProperty`:return t.key!==e;case`TSEnumMember`:return t.id!==e;case`TSPropertySignature`:return t.key===e?!!t.computed:!0}return!0}function yE(e,t){return Tn(e)&&(fs(t)||On(t))?!1:Es(e)&&(fs(t)||On(t))?!0:es(e)}function bE(e){return Or(e)||Bn(e.imported||e.exported,{name:`default`})}const xE=new Set([`abstract`,`boolean`,`byte`,`char`,`double`,`enum`,`final`,`float`,`goto`,`implements`,`int`,`interface`,`long`,`native`,`package`,`private`,`protected`,`public`,`short`,`static`,`synchronized`,`throws`,`transient`,`volatile`]);function SE(e){return ic(e)&&!xE.has(e)}function CE(e){return fr(e)&&e.kind===`var`}const wE={isReactComponent:ec,isCompatTag:tc,buildChildren:Nv};var TE=e(te(((e,t)=>{let n={},r=n.hasOwnProperty,i=(e,t)=>{for(let n in e)r.call(e,n)&&t(n,e[n])},a=(e,t)=>(t&&i(t,(t,n)=>{e[t]=n}),e),o=(e,t)=>{let n=e.length,r=-1;for(;++r<n;)t(e[r])},s=e=>`\\u`+(`0000`+e).slice(-4),c=(e,t)=>{let n=e.toString(16);return t?n:n.toUpperCase()},l=n.toString,u=Array.isArray,d=e=>typeof Buffer==`function`&&Buffer.isBuffer(e),f=e=>l.call(e)==`[object Object]`,p=e=>typeof e==`string`||l.call(e)==`[object String]`,m=e=>typeof e==`number`||l.call(e)==`[object Number]`,h=e=>typeof e==`bigint`,g=e=>typeof e==`function`,ee=e=>l.call(e)==`[object Map]`,_=e=>l.call(e)==`[object Set]`,v={"\\":`\\\\`,"\b":`\\b`,"\f":`\\f`,"\n":`\\n`,"\r":`\\r`," ":`\\t`},te=/[\\\b\f\n\r\t]/,ne=/[0-9]/,y=/[\xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/,b=/([\uD800-\uDBFF][\uDC00-\uDFFF])|([\uD800-\uDFFF])|(['"`])|[^]/g,re=/([\uD800-\uDBFF][\uDC00-\uDFFF])|([\uD800-\uDFFF])|(['"`])|[^ !#-&\(-\[\]-_a-~]/g,ie=(e,t)=>{let n=()=>{ce=se,++t.indentLevel,se=t.indent.repeat(t.indentLevel)},r={escapeEverything:!1,minimal:!1,isScriptContext:!1,quotes:`single`,wrap:!1,es6:!1,json:!1,compact:!0,lowercaseHex:!1,numbers:`decimal`,indent:` `,indentLevel:0,__inline1__:!1,__inline2__:!1},l=t&&t.json;l&&(r.quotes=`double`,r.wrap=!0),t=a(r,t),t.quotes!=`single`&&t.quotes!=`double`&&t.quotes!=`backtick`&&(t.quotes=`single`);let ae=t.quotes==`double`?`"`:t.quotes==`backtick`?"`":`'`,x=t.compact,oe=t.lowercaseHex,se=t.indent.repeat(t.indentLevel),ce=``,le=t.__inline1__,ue=t.__inline2__,de=x?``:`
|
|
6
|
+
`,S,fe=!0,pe=t.numbers==`binary`,me=t.numbers==`octal`,he=t.numbers==`decimal`,ge=t.numbers==`hexadecimal`;if(l&&e&&g(e.toJSON)&&(e=e.toJSON()),!p(e)){if(ee(e))return e.size==0?`new Map()`:(x||(t.__inline1__=!0,t.__inline2__=!1),`new Map(`+ie(Array.from(e),t)+`)`);if(_(e))return e.size==0?`new Set()`:`new Set(`+ie(Array.from(e),t)+`)`;if(d(e))return e.length==0?`Buffer.from([])`:`Buffer.from(`+ie(Array.from(e),t)+`)`;if(u(e))return S=[],t.wrap=!0,le&&(t.__inline1__=!1,t.__inline2__=!0),ue||n(),o(e,e=>{fe=!1,ue&&(t.__inline2__=!1),S.push((x||ue?``:se)+ie(e,t))}),fe?`[]`:ue?`[`+S.join(`, `)+`]`:`[`+de+S.join(`,`+de)+de+(x?``:ce)+`]`;if(m(e)||h(e)){if(l)return JSON.stringify(Number(e));let t;if(he)t=String(e);else if(ge){let n=e.toString(16);oe||(n=n.toUpperCase()),t=`0x`+n}else pe?t=`0b`+e.toString(2):me&&(t=`0o`+e.toString(8));return h(e)?t+`n`:t}else if(h(e))return l?JSON.stringify(Number(e)):e+`n`;else if(f(e))return S=[],t.wrap=!0,n(),i(e,(e,n)=>{fe=!1,S.push((x?``:se)+ie(e,t)+`:`+(x?``:` `)+ie(n,t))}),fe?`{}`:`{`+de+S.join(`,`+de)+de+(x?``:ce)+`}`;else return l?JSON.stringify(e)||`null`:String(e)}let _e=t.escapeEverything?b:re;return S=e.replace(_e,(e,n,r,i,a,o)=>{if(n){if(t.minimal)return n;let e=n.charCodeAt(0),r=n.charCodeAt(1);return t.es6?`\\u{`+c((e-55296)*1024+r-56320+65536,oe)+`}`:s(c(e,oe))+s(c(r,oe))}if(r)return s(c(r.charCodeAt(0),oe));if(e==`\0`&&!l&&!ne.test(o.charAt(a+1)))return`\\0`;if(i)return i==ae||t.escapeEverything?`\\`+i:i;if(te.test(e))return v[e];if(t.minimal&&!y.test(e))return e;let u=c(e.charCodeAt(0),oe);return l||u.length>2?s(u):`\\x`+(`00`+u).slice(-2)}),ae=="`"&&(S=S.replace(/\$\{/g,"\\${")),t.isScriptContext&&(S=S.replace(/<\/(script|style)/gi,`<\\/$1`).replace(/<!--/g,l?`\\u003C!--`:`\\x3C!--`)),t.wrap&&(S=ae+S+ae),S};ie.version=`3.0.2`,t.exports=ie}))(),1),EE=class{_map;_rawMappings;_sourceFileName;_lastGenLine=0;_lastSourceLine=0;_lastSourceColumn=0;_inputMap=null;constructor(e,t){let n=this._map=new kt({sourceRoot:e.sourceRoot});if(this._sourceFileName=e.sourceFileName?.replace(/\\/g,`/`),this._rawMappings=void 0,e.inputSourceMap){this._inputMap=new pt(e.inputSourceMap);let t=this._inputMap.resolvedSources;if(t.length)for(let e=0;e<t.length;e++)Mt(n,t[e],this._inputMap.sourcesContent?.[e])}if(typeof t==`string`&&!e.inputSourceMap)Mt(n,this._sourceFileName,t);else if(typeof t==`object`)for(let e of Object.keys(t))Mt(n,e.replace(/\\/g,`/`),t[e])}get(){return Pt(this._map)}getDecoded(){return Nt(this._map)}getRawMappings(){return this._rawMappings||=Ft(this._map)}mark(e,t,n,r,i,a){this._rawMappings=void 0;let o;if(t!=null)if(this._inputMap){if(o=gt(this._inputMap,{line:t,column:n}),!o.name&&i){let e=gt(this._inputMap,i);e.name&&(r=e.name)}}else o={name:null,source:a?.replace(/\\/g,`/`)||this._sourceFileName,line:t,column:n};jt(this._map,{name:r,generated:e,source:o?.source,original:o})}};const DE=[];for(let e=0;e<32;e++)DE.push(` `.repeat(e*2));var OE=class{constructor(e,t){this._map=e,this._indentChar=t}_map=null;_buf=``;_str=``;_appendCount=0;_last=0;_canMarkIdName=!0;_indentChar=``;_queuedChar=0;_position={line:1,column:0};_sourcePosition={identifierName:void 0,identifierNamePos:void 0,line:void 0,column:void 0,filename:void 0};get(){let{_map:e,_last:t}=this;this._queuedChar!==32&&this._flush();let n=t===10?(this._buf+this._str).trimRight():this._buf+this._str;if(e===null)return{code:n,decodedMap:void 0,map:null,rawMappings:void 0};let r={code:n,decodedMap:e.getDecoded(),get __mergedMap(){return this.map},get map(){let t=e.get();return r.map=t,t},set map(e){Object.defineProperty(r,`map`,{value:e,writable:!0})},get rawMappings(){let t=e.getRawMappings();return r.rawMappings=t,t},set rawMappings(e){Object.defineProperty(r,`rawMappings`,{value:e,writable:!0})}};return r}append(e,t){this._flush(),this._append(e,t)}appendChar(e){this._flush(),this._appendChar(e,1,!0)}queue(e){this._flush(),this._queuedChar=e}_flush(){let e=this._queuedChar;e!==0&&(this._appendChar(e,1,!0),this._queuedChar=0)}_appendChar(e,t,n){if(this._last=e,e===-1){let e=t>64?this._indentChar.repeat(t):DE[t/2];this._str+=e}else this._str+=t>1?String.fromCharCode(e).repeat(t):String.fromCharCode(e);let r=e===32,i=this._position;if(e!==10){if(this._map){let e=this._sourcePosition;n&&e?(this._map.mark(i,e.line,e.column,r?void 0:e.identifierName,r?void 0:e.identifierNamePos,e.filename),!r&&this._canMarkIdName&&(e.identifierName=void 0,e.identifierNamePos=void 0)):this._map.mark(i)}i.column+=t}else i.line++,i.column=0}_append(e,t){let n=e.length,r=this._position,i=this._sourcePosition;this._last=-1,++this._appendCount>4096?(+this._str,this._buf+=this._str,this._str=e,this._appendCount=0):this._str+=e;let a=this._map!==null;if(!t&&!a){r.column+=n;return}let{column:o,identifierName:s,identifierNamePos:c,filename:l}=i,u=i.line;(s!=null||c!=null)&&this._canMarkIdName&&(i.identifierName=void 0,i.identifierNamePos=void 0);let d=e.indexOf(`
|
|
7
|
+
`),f=0;for(a&&d!==0&&this._map.mark(r,u,o,s,c,l);d!==-1;)r.line++,r.column=0,f=d+1,f<n&&u!==void 0&&(u++,a&&this._map.mark(r,u,0,void 0,void 0,l)),d=e.indexOf(`
|
|
8
|
+
`,f);r.column+=n-f}removeLastSemicolon(){this._queuedChar===59&&(this._queuedChar=0)}getLastChar(e){if(!e)return this._last;let t=this._queuedChar;return t===0?this._last:t}getNewlineCount(){return this._queuedChar===0&&this._last===10?1:0}hasContent(){return this._last!==0}exactSource(e,t){if(!this._map){t();return}this.source(`start`,e);let n=e.identifierName,r=this._sourcePosition;n!=null&&(this._canMarkIdName=!1,r.identifierName=n),t(),n!=null&&(this._canMarkIdName=!0,r.identifierName=void 0,r.identifierNamePos=void 0),this.source(`end`,e)}source(e,t){this._map&&this._normalizePosition(e,t,0)}sourceWithOffset(e,t,n){this._map&&this._normalizePosition(e,t,n)}_normalizePosition(e,t,n){this._flush();let r=t[e],i=this._sourcePosition;r&&(i.line=r.line,i.column=Math.max(r.column+n,0),i.filename=t.filename)}getCurrentColumn(){return this._position.column+(this._queuedChar?1:0)}getCurrentLine(){return this._position.line}};const{isMemberExpression:kE,isOptionalMemberExpression:AE,isYieldExpression:jE,isStatement:ME}=gn,NE=new Map([[`||`,0],[`??`,1],[`&&`,2],[`|`,3],[`^`,4],[`&`,5],[`==`,6],[`===`,6],[`!=`,6],[`!==`,6],[`<`,7],[`>`,7],[`<=`,7],[`>=`,7],[`in`,7],[`instanceof`,7],[`>>`,8],[`<<`,8],[`>>>`,8],[`+`,9],[`-`,9],[`*`,10],[`/`,10],[`%`,10],[`**`,11]]);function PE(e){return e===153||e===198||e===206}const FE=(e,t,n)=>(n===21||n===22)&&t.superClass===e,IE=(e,t,n)=>{switch(n){case 108:case 132:return t.object===e;case 17:case 130:case 112:return t.callee===e;case 219:return t.tag===e;case 188:return!0}return!1};function LE(e,t,n){return n===4}function RE(e,t,n,r){return n===236||n===90||n===4||(r&8)>0}function zE(e,t,n){return IE(e,t,n)||FE(e,t,n)}function BE(e){return(e&3)>0}function VE(e,t,n,r){return BE(r)}function HE(e,t,n,r){return(r&1)>0&&!e.async}function UE(e,t,n,r){if(FE(e,t,n)||IE(e,t,n)||n===235||n===142||n===8)return!0;let i;switch(n){case 10:case 107:i=NE.get(t.operator);break;case 153:case 198:i=7}if(i!==void 0){let a=r===2?7:NE.get(e.operator);if(i>a||i===a&&n===10&&(a===11?t.left===e:t.right===e)||r===1&&n===107&&(a===1&&i!==1||i===1&&a!==1))return!0}return!1}function WE(e,t,n){switch(n){case 4:case 115:case 90:case 236:return!0}return!1}function GE(e,t,n){return n===84&&t.objectType===e}function KE(e,t,n){return(n===6||n===7)&&t.left===e||n===10&&(t.operator===`|`||t.operator===`&`)&&e===t.left?!0:UE(e,t,n,2)}function qE(e,t,n){switch(n){case 152:case 192:case 208:case 209:case 178:case 216:return!0;case 172:return t.objectType===e;case 158:return t.checkType===e||t.extendsType===e}return!1}function JE(e,t,n){switch(n){case 178:case 208:case 152:case 192:return!0;case 172:return t.objectType===e}return!1}function YE(e,t,n){return n===208||ZE(e,t,n)}function XE(e,t,n){return!!(ZE(e,t,n)||(n===178||n===216)&&e.typeParameter.constraint!=null)}function ZE(e,t,n){switch(n){case 152:case 192:return!0;case 172:if(t.objectType===e)return!0}return!1}function QE(e,t,n){switch(n){case 17:case 130:case 112:case 174:return t.typeArguments!=null}return!1}function $E(e,t,n){return JE(e,t,n)?!0:n===216||n===158&&(t.checkType===e||t.extendsType===e)}function eD(e,t,n,r){return UE(e,t,n,0)?!0:(r&128)>0&&e.operator===`in`}function tD(e,t,n){return UE(e,t,n,1)}function nD(e,t,n){return n===141||n===133||n===108&&t.property===e||n===132&&t.property===e||n===221?!1:n===21?!0:n===68?t.right===e:n===60?!0:!ME(t)}function rD(e,t,n){return n===10||n===107||n===235||n===142||IE(e,t,n)||n===8&&jE(e)||n===28&&e===t.test||FE(e,t,n)||PE(n)}function iD(e,t,n,r){return(r&5)>0}function aD(e,t,n){return IE(e,t,n)||n===10&&t.operator===`**`&&t.left===e||FE(e,t,n)}function oD(e,t,n,r){return(r&5)>0}function sD(e,t,n){switch(n){case 235:case 142:case 10:case 107:case 8:return!0;case 28:if(t.test===e)return!0}return PE(n)?!0:aD(e,t,n)}function cD(e,t,n){switch(n){case 17:return t.callee===e;case 108:return t.object===e}return!1}function lD(e,t,n,r){return BE(r)&&e.left.type===`ObjectPattern`?!0:sD(e,t,n)}function uD(e,t,n,r,i){if(i&&i(e)!==e.name)return!1;if(n===6&&e.extra?.parenthesized&&t.left===e){let e=t.right.type;if((e===`FunctionExpression`||e===`ClassExpression`)&&t.right.id==null)return!0}return(r&64||(n===108||n===132)&&r&49)&&e.name===`let`?(kE(t,{object:e,computed:!0})||AE(t,{object:e,computed:!0,optional:!1}))&&r&49?!0:(r&64)>0:n===68&&t.left===e&&e.name===`async`&&!t.await}var dD=Object.freeze({__proto__:null,ArrowFunctionExpression:sD,AssignmentExpression:lD,AwaitExpression:rD,BinaryExpression:eD,ClassExpression:iD,ConditionalExpression:sD,DoExpression:HE,FunctionExpression:oD,FunctionTypeAnnotation:RE,Identifier:uD,IntersectionTypeAnnotation:WE,LogicalExpression:tD,NullableTypeAnnotation:LE,ObjectExpression:VE,OptionalCallExpression:cD,OptionalIndexedAccessType:GE,OptionalMemberExpression:cD,SequenceExpression:nD,SpreadElement:aD,TSAsExpression:KE,TSConditionalType:qE,TSConstructorType:$E,TSFunctionType:$E,TSInferType:XE,TSInstantiationExpression:QE,TSIntersectionType:YE,TSSatisfiesExpression:KE,TSTypeAssertion:aD,TSTypeOperator:ZE,TSUnionType:JE,UnaryExpression:aD,UnionTypeAnnotation:WE,UpdateExpression:zE,YieldExpression:rD});function fD(e){this.print(e.tag),this.print(e.typeArguments),this.print(e.quasi)}function pD(){throw Error(`TemplateElement printing is handled in TemplateLiteral`)}function mD(e,t){let n=e.quasis,r="`";for(let e=0;e<n.length-1;e++)r+=n[e].value.raw,this.token(r+"${",!0),this.print(t[e]),r=`}`;r+=n[n.length-1].value.raw,this.token(r+"`",!0)}function hD(e){mD.call(this,e,e.expressions)}const{isCallExpression:gD,isLiteral:_D,isMemberExpression:vD,isNewExpression:yD,isPattern:bD}=gn;function xD(e){let{operator:t}=e,n=t.charCodeAt(0);n>=97&&n<=122?(this.word(t),this.space()):this.tokenChar(n),this.print(e.argument)}function SD(e){e.async&&(this.word(`async`,!0),this.space()),this.word(`do`),this.space(),this.print(e.body)}function CD(e){this.tokenChar(40);let t=this.enterDelimited();this.print(e.expression,void 0,!0),this._noLineTerminatorAfterNode=t,this.rightParens(e)}function wD(e){e.prefix?(this.token(e.operator,!1,0,!0),this.print(e.argument)):(this.print(e.argument,!0),this.token(e.operator,!1,0,!0))}function TD(e){this.print(e.test),this.space(),this.tokenChar(63),this.space(),this.print(e.consequent),this.space(),this.tokenChar(58),this.space(),this.print(e.alternate)}function ED(e,t){if(this.word(`new`),this.space(),this.print(e.callee),this.format.minified&&e.arguments.length===0&&!gD(t,{callee:e})&&!vD(t)&&!yD(t)||(this.print(e.typeArguments),e.arguments.length===0&&this.tokenMap&&!this.tokenMap.endMatches(e,`)`)))return;this.tokenChar(40);let n=this.enterDelimited();this.printList(e.arguments,this.shouldPrintTrailingComma(`)`),void 0,void 0,void 0,!0),this._noLineTerminatorAfterNode=n,this.rightParens(e)}function DD(e){this.printList(e.expressions)}function OD(){this.word(`this`)}function kD(){this.word(`super`)}function AD(e){return typeof e.start==`number`&&e.start===e.declaration.start}function jD(e){this.tokenChar(64);let{expression:t}=e;this.print(t),this.newline()}function MD(e){let{computed:t}=e,{optional:n,property:r}=e;if(this.print(e.object),!t&&vD(r))throw TypeError(`Got a MemberExpression for MemberExpression property`);_D(r)&&typeof r.value==`number`&&(t=!0),n&&this.token(`?.`),t?(this.tokenChar(91),this.print(r),this.tokenChar(93)):(n||this.tokenChar(46),this.print(r))}function ND(e){this.print(e.callee),e.optional&&this.token(`?.`),this.print(e.typeArguments),this.tokenChar(40);let t=this.enterDelimited();this.printList(e.arguments,void 0,void 0,void 0,void 0,!0),this._noLineTerminatorAfterNode=t,this.rightParens(e)}function PD(e){this.print(e.callee),this.print(e.typeArguments),this.tokenChar(40);let t=this.enterDelimited();this.printList(e.arguments,this.shouldPrintTrailingComma(`)`),void 0,void 0,void 0,!0),this._noLineTerminatorAfterNode=t,this.rightParens(e)}function FD(){this.word(`import`)}function ID(e){this.word(`await`),this.space(),this.print(e.argument)}function LD(e){e.delegate?(this.word(`yield`,!0),this.tokenChar(42),e.argument&&(this.space(),this.print(e.argument))):e.argument?(this.word(`yield`,!0),this.space(),this.print(e.argument)):this.word(`yield`)}function RD(){this.semicolon(!0)}function zD(e){this.tokenContext|=1,this.print(e.expression),this.semicolon()}function BD(e){this.print(e.left),(e.left.type===`Identifier`||bD(e.left))&&(e.left.optional&&this.tokenChar(63),this.print(e.left.typeAnnotation)),this.space(),this.tokenChar(61),this.space(),this.print(e.right)}function VD(e){this.print(e.left),this.space(),this.token(e.operator,!1,0,!0),this.space(),this.print(e.right)}function HD(e){this.print(e.left),this.space();let{operator:t}=e;t.charCodeAt(0)===105?this.word(t):(this.token(t,!1,0,!0),this.setLastChar(t.charCodeAt(t.length-1))),this.space(),this.print(e.right)}function UD(e){this.print(e.object),this.token(`::`),this.print(e.callee)}function WD(e){if(this.print(e.object),!e.computed&&vD(e.property))throw TypeError(`Got a MemberExpression for MemberExpression property`);let t=e.computed;if(_D(e.property)&&typeof e.property.value==`number`&&(t=!0),t){let t=this.enterDelimited();this.tokenChar(91),this.print(e.property,void 0,!0),this.tokenChar(93),this._noLineTerminatorAfterNode=t}else this.tokenChar(46),this.print(e.property)}function GD(e){this.print(e.meta),this.tokenChar(46),this.print(e.property)}function KD(e){this.tokenChar(35),this.print(e.id)}function qD(e){this.tokenChar(37),this.word(e.name)}function JD(e){this.word(`module`,!0),this.space(),this.tokenChar(123),this.indent();let{body:t}=e;(t.body.length||t.directives.length)&&this.newline(),this.print(t),this.dedent(),this.rightBrace(e)}const{isFor:YD,isIfStatement:XD,isStatement:ZD,isVoidPattern:QD}=gn;function $D(e){this.word(`with`),this.space(),this.tokenChar(40),this.print(e.object),this.tokenChar(41),this.printBlock(e.body)}function eO(e){this.word(`if`),this.space(),this.tokenChar(40),this.print(e.test),this.tokenChar(41),this.space();let t=e.alternate&&XD(tO(e.consequent));t&&(this.tokenChar(123),this.newline(),this.indent()),this.printAndIndentOnComments(e.consequent),t&&(this.dedent(),this.newline(),this.tokenChar(125)),e.alternate&&(this.endsWith(125)&&this.space(),this.word(`else`),this.space(),this.printAndIndentOnComments(e.alternate))}function tO(e){let{body:t}=e;return ZD(t)===!1?e:tO(t)}function nO(e){this.word(`for`),this.space(),this.tokenChar(40),this.tokenContext|=144,this.print(e.init),this.tokenContext=0,this.tokenChar(59),e.test&&(this.space(),this.print(e.test)),this.tokenChar(59,1),e.update&&(this.space(),this.print(e.update)),this.tokenChar(41),this.printBlock(e.body)}function rO(e){this.word(`while`),this.space(),this.tokenChar(40),this.print(e.test),this.tokenChar(41),this.printBlock(e.body)}function iO(e){this.word(`for`),this.space(),this.noIndentInnerCommentsHere(),this.tokenChar(40),this.tokenContext|=160,this.print(e.left),this.tokenContext=0,this.space(),this.word(`in`),this.space(),this.print(e.right),this.tokenChar(41),this.printBlock(e.body)}function aO(e){this.word(`for`),this.space(),e.await&&(this.word(`await`),this.space()),this.noIndentInnerCommentsHere(),this.tokenChar(40),this.tokenContext|=64,this.print(e.left),this.space(),this.word(`of`),this.space(),this.print(e.right),this.tokenChar(41),this.printBlock(e.body)}function oO(e){this.word(`do`),this.space(),this.print(e.body),this.space(),this.word(`while`),this.space(),this.tokenChar(40),this.print(e.test),this.tokenChar(41),this.semicolon()}function sO(e,t){t&&(e.space(),e.printTerminatorless(t)),e.semicolon()}function cO(e){this.word(`break`),sO(this,e.label)}function lO(e){this.word(`continue`),sO(this,e.label)}function uO(e){this.word(`return`),sO(this,e.argument)}function dO(e){this.word(`throw`),sO(this,e.argument)}function fO(e){this.print(e.label),this.tokenChar(58),this.space(),this.print(e.body)}function pO(e){this.word(`try`),this.space(),this.print(e.block),this.space(),e.handlers?this.print(e.handlers[0]):this.print(e.handler),e.finalizer&&(this.space(),this.word(`finally`),this.space(),this.print(e.finalizer))}function mO(e){this.word(`catch`),this.space(),e.param&&(this.tokenChar(40),this.print(e.param),this.print(e.param.typeAnnotation),this.tokenChar(41),this.space()),this.print(e.body)}function hO(e){this.word(`switch`),this.space(),this.tokenChar(40),this.print(e.discriminant),this.tokenChar(41),this.space(),this.tokenChar(123),this.printSequence(e.cases,!0),this.rightBrace(e)}function gO(e){e.test?(this.word(`case`),this.space(),this.print(e.test),this.tokenChar(58)):(this.word(`default`),this.tokenChar(58)),e.consequent.length&&(this.newline(),this.printSequence(e.consequent,!0))}function _O(){this.word(`debugger`),this.semicolon()}function vO(e){this.tokenChar(44,e),this.newline()}function yO(e,t){e.declare&&(this.word(`declare`),this.space());let{kind:n}=e;switch(n){case`await using`:this.word(`await`),this.space();case`using`:this.word(`using`,!0);break;default:this.word(n)}this.space();let r=!1;if(!YD(t)){for(let t of e.declarations)if(t.init){r=!0;break}}if(this.printList(e.declarations,void 0,void 0,e.declarations.length>1,r?vO:void 0),t!=null)switch(t.type){case`ForStatement`:if(t.init===e)return;break;case`ForInStatement`:case`ForOfStatement`:if(t.left===e)return}this.semicolon()}function bO(e){this.print(e.id),e.definite&&this.tokenChar(33),QD(e.id)||this.print(e.id.typeAnnotation),e.init&&(this.space(),this.tokenChar(61),this.space(),this.print(e.init))}const{isIdentifier:xO}=gn;function SO(e,t,n,r){if(this.print(e.typeParameters),n!==void 0||r!==void 0){let e=jO.call(this,n,r);e&&this.sourceIdentifierName(e.name,e.pos)}this.tokenChar(40),CO.call(this,e.params,41),this.print(e.returnType,t),this._noLineTerminator=t}function CO(e,t){let n=this.enterDelimited(),r=this.shouldPrintTrailingComma(t),i=e.length;for(let t=0;t<i;t++)wO.call(this,e[t]),(r||t<i-1)&&(this.tokenChar(44,t),this.space());this.tokenChar(t),this._noLineTerminatorAfterNode=n}function wO(e){this.printJoin(e.decorators,void 0,void 0,void 0,void 0,!0),this.print(e,void 0,!0),e.optional&&this.tokenChar(63),this.print(e.typeAnnotation,void 0,!0)}function TO(e){let t=e.kind,n=e.key;(t===`get`||t===`set`)&&(this.word(t),this.space()),e.async&&(this.word(`async`,!0),this.space()),(t===`method`||t===`init`)&&e.generator&&this.tokenChar(42),e.computed?(this.tokenChar(91),this.print(n),this.tokenChar(93)):this.print(n),e.optional&&this.tokenChar(63),this._buf._map?SO.call(this,e,!1,e.computed&&e.key.type!==`StringLiteral`?void 0:e.key):SO.call(this,e,!1)}function EO(e,t){e.predicate&&(e.returnType||this.tokenChar(58),this.space(),this.print(e.predicate,t))}function DO(e,t,n){e.async&&(this.word(`async`),this.format.preserveFormat||(this._innerCommentsState=0),this.space()),this.word(`function`),e.generator&&(this.format.preserveFormat||(this._innerCommentsState=0),this.tokenChar(42)),this.space(),e.id&&this.print(e.id),this._buf._map?SO.call(this,e,!1,e.id,t):SO.call(this,e,!1),n&&EO.call(this,e)}function OO(e,t){DO.call(this,e,t,!0),this.space(),this.print(e.body)}function kO(e,t){e.async&&(this.word(`async`,!0),this.space()),AO.call(this,e)?SO.call(this,e,!0,void 0,this._buf._map?t:void 0):this.print(e.params[0],!0),EO.call(this,e,!0),this.space(),this.printInnerComments(),this.token(`=>`),this.space(),this.tokenContext|=2,this.print(e.body)}function AO(e){if(e.params.length!==1||e.typeParameters||e.returnType||e.predicate)return!0;let t=e.params[0];if(!xO(t)||t.typeAnnotation||t.optional||t.leadingComments?.length||t.trailingComments?.length)return!0;if(this.tokenMap){if(e.loc==null||this.tokenMap.findMatching(e,`(`)!==null)return!0;let t=this.tokenMap.findMatching(e,`=>`);return t?.loc==null?!0:t.loc.start.line!==e.loc.start.line}return!!this.format.retainLines}function jO(e,t){let n=e;if(!n&&t){let e=t.type;e===`VariableDeclarator`?n=t.id:e===`AssignmentExpression`||e===`AssignmentPattern`?n=t.left:e===`ObjectProperty`||e===`ClassProperty`?(!t.computed||t.key.type===`StringLiteral`)&&(n=t.key):(e===`ClassPrivateProperty`||e===`ClassAccessorProperty`)&&(n=t.key)}if(!n)return;let r;return n.type===`Identifier`?r={pos:n.loc?.start,name:n.loc?.identifierName||n.name}:n.type===`PrivateName`?r={pos:n.loc?.start,name:`#`+n.id.name}:n.type===`StringLiteral`&&(r={pos:n.loc?.start,name:n.value}),r}function MO(e,t){this.token((t.type===`TSFunctionType`||t.type===`TSConstructorType`)&&t.returnType===e?`=>`:`:`),this.space(),e.optional&&this.tokenChar(63),this.print(e.typeAnnotation)}function NO(e,t){this.tokenChar(60);let n=t.type===`ArrowFunctionExpression`&&e.params.length===1;this.tokenMap&&e.start!=null&&e.end!=null&&(n&&=!!this.tokenMap.find(e,e=>this.tokenMap.matchesOriginal(e,`,`)),n||=this.shouldPrintTrailingComma(`>`)),this.printList(e.params,n),this.tokenChar(62)}function PO(e){e.const&&(this.word(`const`),this.space()),e.in&&(this.word(`in`),this.space()),e.out&&(this.word(`out`),this.space()),this.word(e.name.name),e.constraint&&(this.space(),this.word(`extends`),this.space(),this.print(e.constraint)),e.default&&(this.space(),this.tokenChar(61),this.space(),this.print(e.default))}function FO(e){e.accessibility&&(this.word(e.accessibility),this.space()),e.readonly&&(this.word(`readonly`),this.space()),wO.call(this,e.parameter)}function IO(e,t){e.declare&&(this.word(`declare`),this.space()),DO.call(this,e,t,!1),this.semicolon()}function LO(e){dM.call(this,e),this.semicolon()}function RO(e){this.print(e.left),this.tokenChar(46),this.print(e.right)}function zO(e){Yk.call(this,e),BO(this,e)}function BO(e,t){if(!e.tokenMap||!t.start||!t.end){e.semicolon();return}e.tokenMap.endMatches(t,`,`)?e.token(`,`):e.tokenMap.endMatches(t,`;`)&&e.semicolon()}function VO(e){this.word(`new`),this.space(),Yk.call(this,e),BO(this,e)}function HO(e){let{readonly:t}=e;t&&(this.word(`readonly`),this.space()),UO.call(this,e),this.print(e.typeAnnotation),BO(this,e)}function UO(e){e.computed&&this.tokenChar(91),this.print(e.key),e.computed&&this.tokenChar(93),e.optional&&this.tokenChar(63)}function WO(e){let{kind:t}=e;(t===`set`||t===`get`)&&(this.word(t),this.space()),UO.call(this,e),Yk.call(this,e),BO(this,e)}function GO(e){let{readonly:t,static:n}=e;n&&(this.word(`static`),this.space()),t&&(this.word(`readonly`),this.space()),this.tokenChar(91),CO.call(this,e.parameters,93),this.print(e.typeAnnotation),BO(this,e)}function KO(){this.word(`any`)}function qO(){this.word(`bigint`)}function JO(){this.word(`unknown`)}function YO(){this.word(`number`)}function XO(){this.word(`object`)}function ZO(){this.word(`boolean`)}function QO(){this.word(`string`)}function $O(){this.word(`symbol`)}function ek(){this.word(`void`)}function tk(){this.word(`undefined`)}function nk(){this.word(`null`)}function rk(){this.word(`never`)}function ik(){this.word(`intrinsic`)}function ak(){this.word(`this`)}function ok(e){ck.call(this,e)}function sk(e){e.abstract&&(this.word(`abstract`),this.space()),this.word(`new`),this.space(),ck.call(this,e)}function ck(e){let{typeParameters:t}=e,n=e.params;this.print(t),this.tokenChar(40),CO.call(this,n,41),this.space();let r=e.returnType;this.print(r)}function lk(e){let t=e.typeArguments;this.print(e.typeName,!!t),this.print(t)}function uk(e){e.asserts&&(this.word(`asserts`),this.space()),this.print(e.parameterName),e.typeAnnotation&&(this.space(),this.word(`is`),this.space(),this.print(e.typeAnnotation.typeAnnotation))}function dk(e){this.word(`typeof`),this.space(),this.print(e.exprName);let t=e.typeArguments;t&&this.print(t)}function fk(e){Zk(this,e,()=>this.printJoin(e.members,!0,!0,void 0,void 0,!0))}function pk(e){this.print(e.elementType,!0),this.tokenChar(91),this.tokenChar(93)}function mk(e){this.tokenChar(91),this.printList(e.elementTypes,this.shouldPrintTrailingComma(`]`)),this.tokenChar(93)}function hk(e){this.print(e.typeAnnotation),this.tokenChar(63)}function gk(e){this.token(`...`),this.print(e.typeAnnotation)}function _k(e){this.print(e.label),e.optional&&this.tokenChar(63),this.tokenChar(58),this.space(),this.print(e.elementType)}function vk(e){bk(this,e,`|`)}function yk(e){bk(this,e,`&`)}function bk(e,t,n){let r=0;e.tokenMap?.startMatches(t,n)&&(r=1,e.token(n)),e.printJoin(t.types,void 0,void 0,function(e){this.space(),this.token(n,void 0,e+r),this.space()})}function xk(e){this.print(e.checkType),this.space(),this.word(`extends`),this.space(),this.print(e.extendsType),this.space(),this.tokenChar(63),this.space(),this.print(e.trueType),this.space(),this.tokenChar(58),this.space(),this.print(e.falseType)}function Sk(e){this.word(`infer`),this.print(e.typeParameter)}function Ck(e){this.tokenChar(40),this.print(e.typeAnnotation),this.tokenChar(41)}function wk(e){this.word(e.operator),this.space(),this.print(e.typeAnnotation)}function Tk(e){this.print(e.objectType,!0),this.tokenChar(91),this.print(e.indexType),this.tokenChar(93)}function Ek(e){let{nameType:t,optional:n,readonly:r,typeAnnotation:i}=e;this.tokenChar(123);let a=this.enterDelimited();this.space(),r&&(Dk(this,r),this.word(`readonly`),this.space()),this.tokenChar(91),this.word(e.key.name),this.space(),this.word(`in`),this.space(),this.print(e.constraint),t&&(this.space(),this.word(`as`),this.space(),this.print(t,void 0,!0)),this.tokenChar(93),n&&(Dk(this,n),this.tokenChar(63)),i&&(this.tokenChar(58),this.space(),this.print(i,void 0,!0)),this.space(),this._noLineTerminatorAfterNode=a,this.tokenChar(125)}function Dk(e,t){t!==!0&&e.token(t)}function Ok(e){mD.call(this,e,e.types)}function kk(e){this.print(e.literal)}function Ak(e){this.print(e.expression),this.print(e.typeArguments)}function jk(e){let{declare:t,id:n,typeParameters:r,extends:i,body:a}=e;t&&(this.word(`declare`),this.space()),this.word(`interface`),this.space(),this.print(n),this.print(r),i?.length&&(this.space(),this.word(`extends`),this.space(),this.printList(i)),this.space(),this.print(a)}function Mk(e){Zk(this,e,()=>this.printJoin(e.body,!0,!0,void 0,void 0,!0))}function Nk(e){let{declare:t,id:n,typeParameters:r,typeAnnotation:i}=e;t&&(this.word(`declare`),this.space()),this.word(`type`),this.space(),this.print(n),this.print(r),this.space(),this.tokenChar(61),this.space(),this.print(i),this.semicolon()}function Pk(e){let{expression:t,typeAnnotation:n}=e;this.print(t,!0),this.space(),this.word(`as`),this.space(),this.print(n)}function Fk(e){let{expression:t,typeAnnotation:n}=e;this.print(t,!0),this.space(),this.word(`satisfies`),this.space(),this.print(n)}function Ik(e){let{typeAnnotation:t,expression:n}=e;this.tokenChar(60),this.print(t),this.tokenChar(62),this.space(),this.print(n)}function Lk(e){this.print(e.expression),this.print(e.typeArguments)}function Rk(e){let{declare:t,const:n,id:r}=e;t&&(this.word(`declare`),this.space()),n&&(this.word(`const`),this.space()),this.word(`enum`),this.space(),this.print(r),this.space(),this.print(e.body)}function zk(e){Zk(this,e,()=>this.printList(e.members,this.shouldPrintTrailingComma(`}`)??!1,!0,!0,void 0,!0))}function Bk(e){let{id:t,initializer:n}=e;this.print(t),n&&(this.space(),this.tokenChar(61),this.space(),this.print(n))}function Vk(e){let{declare:t,kind:n}=e;if(t&&(this.word(`declare`),this.space()),n!==`global`&&(this.word(n),this.space()),this.print(e.id),!e.body){this.semicolon();return}this.space(),this.print(e.body)}function Hk(e){Zk(this,e,()=>this.printSequence(e.body,!0,!0))}function Uk(e){let{qualifier:t,options:n}=e;this.word(`import`),this.tokenChar(40),this.print(e.source),n&&(this.tokenChar(44),this.print(n)),this.tokenChar(41),t&&(this.tokenChar(46),this.print(t));let r=e.typeArguments;r&&this.print(r)}function Wk(e){let{id:t,moduleReference:n}=e;this.word(`import`),this.space(),this.print(t),this.space(),this.tokenChar(61),this.space(),this.print(n),this.semicolon()}function Gk(e){this.token(`require(`),this.print(e.expression),this.tokenChar(41)}function Kk(e){this.print(e.expression),this.tokenChar(33),this.setLastChar(33)}function qk(e){this.word(`export`),this.space(),this.tokenChar(61),this.space(),this.print(e.expression),this.semicolon()}function Jk(e){this.word(`export`),this.space(),this.word(`as`),this.space(),this.word(`namespace`),this.space(),this.print(e.id),this.semicolon()}function Yk(e){let{typeParameters:t}=e,n=e.params;this.print(t),this.tokenChar(40),CO.call(this,n,41),this.print(e.returnType)}function Xk(e){let t=e.type===`ClassPrivateProperty`,n=e.type===`ClassAccessorProperty`||e.type===`ClassProperty`;Qk(this,e,[n&&e.declare&&`declare`,!t&&e.accessibility]),e.static&&(this.word(`static`),this.space()),Qk(this,e,[!t&&e.abstract&&`abstract`,!t&&e.override&&`override`,(n||t)&&e.readonly&&`readonly`])}function Zk(e,t,n){e.token(`{`);let r=e.enterDelimited();n(),e._noLineTerminatorAfterNode=r,e.rightBrace(t)}function Qk(e,t,n){let r=new Set;for(let e of n)e&&r.add(e);e.tokenMap?.find(t,t=>r.has(t.value)?(e.token(t.value),e.space(),r.delete(t.value),r.size===0):!1);for(let t of r)e.word(t),e.space()}const{isClassDeclaration:$k,isExportDefaultSpecifier:eA,isExportNamespaceSpecifier:tA,isImportDefaultSpecifier:nA,isImportNamespaceSpecifier:rA,isStatement:iA}=gn;function aA(e){(e.importKind===`type`||e.importKind===`typeof`)&&(this.word(e.importKind),this.space()),this.print(e.imported),e.local&&e.local.name!==e.imported.name&&(this.space(),this.word(`as`),this.space(),this.print(e.local))}function oA(e){this.print(e.local)}function sA(e){this.print(e.exported)}function cA(e){e.exportKind===`type`&&(this.word(`type`),this.space()),this.print(e.local),e.exported&&e.local.name!==e.exported.name&&(this.space(),this.word(`as`),this.space(),this.print(e.exported))}function lA(e){this.tokenChar(42),this.space(),this.word(`as`),this.space(),this.print(e.exported)}function uA(e,t){let{attributes:n}=e;this.word(`with`),this.space();let r=t?1:0;this.token(`{`,void 0,r),this.space(),this.printList(n,this.shouldPrintTrailingComma(`}`)),this.space(),this.token(`}`,void 0,r)}function dA(e){this.word(`export`),this.space(),e.exportKind===`type`&&(this.word(`type`),this.space()),this.tokenChar(42),this.space(),this.word(`from`),this.space(),e.attributes?.length?(this.print(e.source,!0),this.space(),uA.call(this,e,!1)):this.print(e.source),this.semicolon()}function fA(e,t){$k(t.declaration)&&AD.call(e,t)&&e.printJoin(t.declaration.decorators)}function pA(e){if(fA(this,e),this.word(`export`),this.space(),e.declaration){let t=e.declaration;this.print(t),iA(t)||this.semicolon()}else{e.exportKind===`type`&&(this.word(`type`),this.space());let t=e.specifiers.slice(0),n=!1;for(;;){let e=t[0];if(eA(e)||tA(e))n=!0,this.print(t.shift()),t.length&&(this.tokenChar(44),this.space());else break}let r=!1;(t.length||!t.length&&!n)&&(r=!0,this.tokenChar(123),t.length&&(this.space(),this.printList(t,this.shouldPrintTrailingComma(`}`)),this.space()),this.tokenChar(125)),e.source&&(this.space(),this.word(`from`),this.space(),e.attributes?.length?(this.print(e.source,!0),this.space(),uA.call(this,e,r)):this.print(e.source)),this.semicolon()}}function mA(e){fA(this,e),this.word(`export`),this.noIndentInnerCommentsHere(),this.space(),this.word(`default`),this.space(),this.tokenContext|=4;let t=e.declaration;this.print(t),iA(t)||this.semicolon()}function hA(e){this.word(`import`),this.space();let t=e.importKind===`type`||e.importKind===`typeof`;t?(this.noIndentInnerCommentsHere(),this.word(e.importKind),this.space()):e.module?(this.noIndentInnerCommentsHere(),this.word(`module`),this.space()):e.phase&&(this.noIndentInnerCommentsHere(),this.word(e.phase),this.space());let n=e.specifiers.slice(0),r=!!n.length;for(;r;){let e=n[0];if(nA(e)||rA(e))this.print(n.shift()),n.length&&(this.tokenChar(44),this.space());else break}let i=!1;n.length?(i=!0,this.tokenChar(123),this.space(),this.printList(n,this.shouldPrintTrailingComma(`}`)),this.space(),this.tokenChar(125)):t&&!r&&(i=!0,this.tokenChar(123),this.tokenChar(125)),(r||t)&&(this.space(),this.word(`from`),this.space()),e.attributes?.length?(this.print(e.source,!0),this.space(),uA.call(this,e,i)):this.print(e.source),this.semicolon()}function gA(e){this.print(e.key),this.tokenChar(58),this.space(),this.print(e.value)}function _A(e){this.tokenChar(42),this.space(),this.word(`as`),this.space(),this.print(e.local)}function vA(e){this.word(`import`),e.phase&&(this.tokenChar(46),this.word(e.phase)),this.tokenChar(40);let t=this.shouldPrintTrailingComma(`)`);this.print(e.source),e.options!=null&&(this.tokenChar(44),this.space(),this.print(e.options)),t&&this.tokenChar(44),this.rightParens(e)}const{isAssignmentPattern:yA,isIdentifier:bA}=gn;let xA=``;function SA(e){let{name:t}=e,n=this.tokenMap.find(e,e=>e.value===t);return n?(xA=this._originalCode.slice(n.start,n.end),xA):xA=e.name}function CA(e){this._buf._map&&this.sourceIdentifierName(e.loc?.identifierName||e.name),this.word(this.tokenMap?xA:e.name)}function wA(){this.tokenChar(63)}function TA(e){this.token(`...`),this.print(e.argument)}function EA(e){let t=e.properties;if(this.tokenChar(123),t.length){let e=this.enterDelimited();this.space(),this.printList(t,this.shouldPrintTrailingComma(`}`),!0,!0,void 0,!0),this.space(),this._noLineTerminatorAfterNode=e}this.rightBrace(e)}function DA(e){this.printJoin(e.decorators),TO.call(this,e),this.space(),this.print(e.body)}function OA(e){if(this.printJoin(e.decorators),e.computed)this.tokenChar(91),this.print(e.key),this.tokenChar(93);else{if(yA(e.value)&&bA(e.key)&&e.key.name===e.value.left.name){this.print(e.value);return}if(this.print(e.key),e.shorthand&&bA(e.key)&&bA(e.value)&&e.key.name===e.value.name)return}this.tokenChar(58),this.space(),this.print(e.value)}function kA(e){let t=e.elements,n=t.length;this.tokenChar(91);let r=this.enterDelimited();for(let e=0;e<t.length;e++){let r=t[e];r?(e>0&&this.space(),this.print(r,void 0,!0),(e<n-1||this.shouldPrintTrailingComma(`]`))&&this.tokenChar(44,e)):this.tokenChar(44,e)}this._noLineTerminatorAfterNode=r,this.tokenChar(93)}function AA(e){this.word(`/${e.pattern}/${e.flags}`,!1)}function jA(e){this.word(e.value?`true`:`false`)}function MA(){this.word(`null`)}function NA(e){let t=this.getPossibleRaw(e),n=this.format.jsescOption,r=e.value,i=r+``;n.numbers?this.number((0,TE.default)(r,n),r):t==null?this.number(i,r):this.format.minified?this.number(t.length<i.length?t:i,r):this.number(t,r)}function PA(e){let t=this.getPossibleRaw(e);if(!this.format.minified&&t!==void 0){this.token(t);return}let n=(0,TE.default)(e.value,this.format.jsescOption);this.token(n)}function FA(e){let t=this.getPossibleRaw(e);if(!this.format.minified&&t!==void 0){this.word(t);return}this.word(e.value+`n`)}const IA=new Set([`^^`,`@@`,`^`,`%`,`#`]);function LA(){let{topicToken:e}=this.format;if(IA.has(e))this.token(e);else{let t=JSON.stringify(e),n=Array.from(IA,e=>JSON.stringify(e));throw Error(`The "topicToken" generator option must be one of ${n.join(`, `)} (${t} received instead).`)}}function RA(){this.word(`void`)}const{isDeclareExportDeclaration:zA,isStatement:BA}=gn;function VA(){this.word(`any`)}function HA(e){this.print(e.elementType,!0),this.tokenChar(91),this.tokenChar(93)}function UA(){this.word(`boolean`)}function WA(e){this.word(e.value?`true`:`false`)}function GA(){this.word(`null`)}function KA(e,t){zA(t)||(this.word(`declare`),this.space()),this.word(`class`),this.space(),xj.call(this,e)}function qA(e,t){zA(t)||(this.word(`declare`),this.space()),this.word(`function`),this.space(),this.print(e.id),this.print(e.id.typeAnnotation?.typeAnnotation),e.predicate&&(this.space(),this.print(e.predicate)),this.semicolon()}function JA(){this.tokenChar(37),this.word(`checks`)}function YA(e){this.tokenChar(37),this.word(`checks`),this.tokenChar(40),this.print(e.value),this.tokenChar(41)}function XA(e){this.word(`declare`),this.space(),Cj.call(this,e)}function ZA(e){this.word(`declare`),this.space(),this.word(`module`),this.space(),this.print(e.id),this.space(),this.print(e.body)}function QA(e){this.word(`declare`),this.space(),this.word(`module`),this.tokenChar(46),this.word(`exports`),this.print(e.typeAnnotation)}function $A(e){this.word(`declare`),this.space(),Fj.call(this,e)}function ej(e,t){zA(t)||(this.word(`declare`),this.space()),zj.call(this,e)}function tj(e,t){zA(t)||(this.word(`declare`),this.space()),this.word(`var`),this.space(),this.print(e.id),this.print(e.id.typeAnnotation),this.semicolon()}function nj(e){this.word(`declare`),this.space(),this.word(`export`),this.space(),e.default&&(this.word(`default`),this.space()),gj.call(this,e)}function rj(e){this.word(`declare`),this.space(),dA.call(this,e)}function ij(e){let{id:t,body:n}=e;this.word(`enum`),this.space(),this.print(t),this.print(n)}function aj(e,t,n){n&&(e.space(),e.word(`of`),e.space(),e.word(t)),e.space()}function oj(e,t){let{members:n}=t;e.token(`{`),e.indent(),e.newline();for(let t of n)e.print(t),e.newline();t.hasUnknownMembers&&(e.token(`...`),e.newline()),e.dedent(),e.token(`}`)}function sj(e){let{explicitType:t}=e;aj(this,`boolean`,t),oj(this,e)}function cj(e){let{explicitType:t}=e;aj(this,`number`,t),oj(this,e)}function lj(e){let{explicitType:t}=e;aj(this,`string`,t),oj(this,e)}function uj(e){aj(this,`symbol`,!0),oj(this,e)}function dj(e){let{id:t}=e;this.print(t),this.tokenChar(44)}function fj(e,t){e.print(t.id),e.space(),e.token(`=`),e.space(),e.print(t.init),e.token(`,`)}function pj(e){fj(this,e)}function mj(e){fj(this,e)}function hj(e){fj(this,e)}function gj(e){if(e.declaration){let t=e.declaration;this.print(t),BA(t)||this.semicolon()}else this.tokenChar(123),e.specifiers.length&&(this.space(),this.printList(e.specifiers),this.space()),this.tokenChar(125),e.source&&(this.space(),this.word(`from`),this.space(),this.print(e.source)),this.semicolon()}function _j(){this.tokenChar(42)}function vj(e,t){this.print(e.typeParameters),this.tokenChar(40),e.this&&(this.word(`this`),this.tokenChar(58),this.space(),this.print(e.this.typeAnnotation),(e.params.length||e.rest)&&(this.tokenChar(44),this.space())),this.printList(e.params),e.rest&&(e.params.length&&(this.tokenChar(44),this.space()),this.token(`...`),this.print(e.rest)),this.tokenChar(41);let n=t?.type;n!=null&&(n===`ObjectTypeCallProperty`||n===`ObjectTypeInternalSlot`||n===`DeclareFunction`||n===`ObjectTypeProperty`&&t.method)?this.tokenChar(58):(this.space(),this.token(`=>`)),this.space(),this.print(e.returnType)}function yj(e){this.print(e.name),e.optional&&this.tokenChar(63),e.name&&(this.tokenChar(58),this.space()),this.print(e.typeAnnotation)}function bj(e){this.print(e.id),this.print(e.typeParameters,!0)}function xj(e){this.print(e.id),this.print(e.typeParameters),e.extends?.length&&(this.space(),this.word(`extends`),this.space(),this.printList(e.extends)),e.type===`DeclareClass`&&(e.mixins?.length&&(this.space(),this.word(`mixins`),this.space(),this.printList(e.mixins)),e.implements?.length&&(this.space(),this.word(`implements`),this.space(),this.printList(e.implements))),this.space(),this.print(e.body)}function Sj(e){let t=e.variance?.kind;t!=null&&(t===`plus`?this.tokenChar(43):t===`minus`&&this.tokenChar(45))}function Cj(e){this.word(`interface`),this.space(),xj.call(this,e)}function wj(e){this.space(),this.token(`&`,!1,e),this.space()}function Tj(e){this.word(`interface`),e.extends?.length&&(this.space(),this.word(`extends`),this.space(),this.printList(e.extends)),this.space(),this.print(e.body)}function Ej(e){this.printJoin(e.types,void 0,void 0,wj)}function Dj(){this.word(`mixed`)}function Oj(){this.word(`empty`)}function kj(e){this.tokenChar(63),this.print(e.typeAnnotation)}function Aj(){this.word(`number`)}function jj(){this.word(`string`)}function Mj(){this.word(`this`)}function Nj(e){this.tokenChar(91),this.printList(e.types),this.tokenChar(93)}function Pj(e){this.word(`typeof`),this.space(),this.print(e.argument)}function Fj(e){this.word(`type`),this.space(),this.print(e.id),this.print(e.typeParameters),this.space(),this.tokenChar(61),this.space(),this.print(e.right),this.semicolon()}function Ij(e,t){this.tokenChar(58),this.space(),t.type===`ArrowFunctionExpression`?this.tokenContext|=8:e.optional&&this.tokenChar(63),this.print(e.typeAnnotation)}function Lj(e){this.tokenChar(60),this.printList(e.params),this.tokenChar(62)}function Rj(e){Sj.call(this,e),this.word(e.name),e.bound&&this.print(e.bound),e.default&&(this.space(),this.tokenChar(61),this.space(),this.print(e.default))}function zj(e){this.word(`opaque`),this.space(),this.word(`type`),this.space(),this.print(e.id),this.print(e.typeParameters),e.supertype&&(this.tokenChar(58),this.space(),this.print(e.supertype)),e.impltype&&(this.space(),this.tokenChar(61),this.space(),this.print(e.impltype)),this.semicolon()}function Bj(e){e.exact?this.token(`{|`):this.tokenChar(123);let t=[...e.properties,...e.callProperties||[],...e.indexers||[],...e.internalSlots||[]];t.length&&(this.newline(),this.space(),this.printJoin(t,!0,!0,()=>{(t.length!==1||e.inexact)&&(this.tokenChar(44),this.space())},!0),this.space()),e.inexact&&(this.indent(),this.token(`...`),t.length&&this.newline(),this.dedent()),e.exact?this.token(`|}`):this.tokenChar(125)}function Vj(e){e.static&&(this.word(`static`),this.space()),this.tokenChar(91),this.tokenChar(91),this.print(e.id),this.tokenChar(93),this.tokenChar(93),e.optional&&this.tokenChar(63),e.method||(this.tokenChar(58),this.space()),this.print(e.value)}function Hj(e){e.static&&(this.word(`static`),this.space()),this.print(e.value)}function Uj(e){e.static&&(this.word(`static`),this.space()),Sj.call(this,e),this.tokenChar(91),e.id&&(this.print(e.id),this.tokenChar(58),this.space()),this.print(e.key),this.tokenChar(93),this.tokenChar(58),this.space(),this.print(e.value)}function Wj(e){e.proto&&(this.word(`proto`),this.space()),e.static&&(this.word(`static`),this.space()),(e.kind===`get`||e.kind===`set`)&&(this.word(e.kind),this.space()),Sj.call(this,e),this.print(e.key),e.optional&&this.tokenChar(63),e.method||(this.tokenChar(58),this.space()),this.print(e.value)}function Gj(e){this.token(`...`),this.print(e.argument)}function Kj(e){this.print(e.qualification),this.tokenChar(46),this.print(e.id)}function qj(){this.word(`symbol`)}function Jj(e){this.space(),this.token(`|`,!1,e),this.space()}function Yj(e){this.printJoin(e.types,void 0,void 0,Jj)}function Xj(e){this.tokenChar(40),this.print(e.expression),this.print(e.typeAnnotation),this.tokenChar(41)}function Zj(e){e.kind===`plus`?this.tokenChar(43):this.tokenChar(45)}function Qj(){this.word(`void`)}function $j(e){this.print(e.objectType,!0),this.tokenChar(91),this.print(e.indexType),this.tokenChar(93)}function eM(e){this.print(e.objectType),e.optional&&this.token(`?.`),this.tokenChar(91),this.print(e.indexType),this.tokenChar(93)}const{isExportDefaultDeclaration:tM,isExportNamedDeclaration:nM}=gn;function rM(e,t){(!(tM(t)||nM(t))||!AD.call(this,t))&&this.printJoin(e.decorators),e.declare&&(this.word(`declare`),this.space()),e.abstract&&(this.word(`abstract`),this.space()),this.word(`class`),e.id&&(this.space(),this.print(e.id)),this.print(e.typeParameters),e.superClass&&(this.space(),this.word(`extends`),this.space(),this.print(e.superClass),this.print(e.superTypeArguments)),e.implements&&(this.space(),this.word(`implements`),this.space(),this.printList(e.implements)),this.space(),this.print(e.body)}function iM(e){if(this.tokenChar(123),e.body.length===0)this.tokenChar(125);else{let t=aM(this,e);t?.(-1);let n=this.enterDelimited();this.printJoin(e.body,!0,!0,t,!0,!0),this._noLineTerminatorAfterNode=n,this.endsWith(10)||this.newline(),this.rightBrace(e)}}function aM(e,t){if(!e.tokenMap||t.start==null||t.end==null)return null;let n=e.tokenMap.getIndexes(t);if(!n)return null;let r=1,i=0,a=0,o=()=>{for(;a<t.body.length&&t.body[a].start==null;)a++};return o(),s=>{a<=s&&(a=s+1,o());let c=a===t.body.length?t.end:t.body[a].start,l;for(;r<n.length&&e.tokenMap.matchesOriginal(l=e._tokens[n[r]],`;`)&&l.start<c;)e.tokenChar(59,i++),r++}}function oM(e){if(this.printJoin(e.decorators),!e.static&&!this.format.preserveFormat){let t=e.key.loc?.end?.line;t&&this.catchUp(t)}Xk.call(this,e),e.computed?(this.tokenChar(91),this.print(e.key),this.tokenChar(93)):(Sj.call(this,e),this.print(e.key)),e.optional&&this.tokenChar(63),e.definite&&this.tokenChar(33),this.print(e.typeAnnotation),e.value&&(this.space(),this.tokenChar(61),this.space(),this.print(e.value)),this.semicolon()}function sM(e){this.printJoin(e.decorators);let t=e.key.loc?.end?.line;t&&this.catchUp(t),Xk.call(this,e),this.word(`accessor`,!0),this.space(),e.computed?(this.tokenChar(91),this.print(e.key),this.tokenChar(93)):(Sj.call(this,e),this.print(e.key)),e.optional&&this.tokenChar(63),e.definite&&this.tokenChar(33),this.print(e.typeAnnotation),e.value&&(this.space(),this.tokenChar(61),this.space(),this.print(e.value)),this.semicolon()}function cM(e){this.printJoin(e.decorators),Xk.call(this,e),this.print(e.key),e.optional&&this.tokenChar(63),e.definite&&this.tokenChar(33),this.print(e.typeAnnotation),e.value&&(this.space(),this.tokenChar(61),this.space(),this.print(e.value)),this.semicolon()}function lM(e){dM.call(this,e),this.space(),this.print(e.body)}function uM(e){dM.call(this,e),this.space(),this.print(e.body)}function dM(e){if(this.printJoin(e.decorators),!this.format.preserveFormat){let t=e.key.loc?.end?.line;t&&this.catchUp(t)}Xk.call(this,e),TO.call(this,e)}function fM(e){this.word(`static`),this.space(),this.tokenChar(123),e.body.length===0?this.tokenChar(125):(this.newline(),this.printSequence(e.body,!0),this.rightBrace(e))}function pM(e){e.program&&this.print(e.program.interpreter),this.print(e.program)}function mM(e){this.printInnerComments(!1);let t=e.directives?.length;if(t){let n=e.body.length?2:1;this.printSequence(e.directives,void 0,void 0,n),e.directives[t-1].trailingComments?.length||this.newline(n)}this.printSequence(e.body)}function hM(e){this.tokenChar(123);let t=this.enterDelimited(),n=e.directives?.length;if(n){let t=e.body.length?2:1;this.printSequence(e.directives,!0,!0,t),e.directives[n-1].trailingComments?.length||this.newline(t)}this.printSequence(e.body,!0,!0),this._noLineTerminatorAfterNode=t,this.rightBrace(e)}function gM(e){this.print(e.value),this.semicolon()}const _M=/(?:^|[^\\])(?:\\\\)*'/,vM=/(?:^|[^\\])(?:\\\\)*"/;function yM(e){let t=this.getPossibleRaw(e);if(!this.format.minified&&t!==void 0){this.token(t);return}let{value:n}=e;if(!vM.test(n))this.token(`"${n}"`);else if(!_M.test(n))this.token(`'${n}'`);else throw Error(`Malformed AST: it is not possible to print a directive containing both unescaped single and double quotes.`)}function bM(e){this.token(`#!${e.value}`),this._newline()}function xM(e){this.token(`%%`),this.print(e.name),this.token(`%%`),e.expectedNode===`Statement`&&this.semicolon()}function SM(e){this.print(e.name),e.value&&(this.tokenChar(61),this.print(e.value))}function CM(e){this.word(e.name)}function wM(e){this.print(e.namespace),this.tokenChar(58),this.print(e.name)}function TM(e){this.print(e.object),this.tokenChar(46),this.print(e.property)}function EM(e){this.tokenChar(123),this.token(`...`),this.print(e.argument),this.rightBrace(e)}function DM(e){this.tokenChar(123),this.print(e.expression),this.rightBrace(e)}function OM(e){this.tokenChar(123),this.token(`...`),this.print(e.expression),this.rightBrace(e)}function kM(e){let t=this.getPossibleRaw(e);t===void 0?this.token(e.value,!0):this.token(t,!0)}function AM(e){let t=e.openingElement;if(this.print(t),!t.selfClosing){this.indent();for(let t of e.children)this.print(t);this.dedent(),this.print(e.closingElement)}}function jM(){this.space()}function MM(e){this.tokenChar(60),this.print(e.name),this.print(e.typeArguments),e.attributes.length>0&&(this.space(),this.printJoin(e.attributes,void 0,void 0,jM)),e.selfClosing&&(this.space(),this.tokenChar(47)),this.tokenChar(62)}function NM(e){this.tokenChar(60),this.tokenChar(47),this.print(e.name),this.tokenChar(62)}function PM(){this.printInnerComments()}function FM(e){this.print(e.openingFragment),this.indent();for(let t of e.children)this.print(t);this.dedent(),this.print(e.closingFragment)}function IM(){this.tokenChar(60),this.tokenChar(62)}function LM(){this.token(`</`),this.tokenChar(62)}var RM=Object.freeze({__proto__:null,AnyTypeAnnotation:VA,ArgumentPlaceholder:wA,ArrayExpression:kA,ArrayPattern:kA,ArrayTypeAnnotation:HA,ArrowFunctionExpression:kO,AssignmentExpression:VD,AssignmentPattern:BD,AwaitExpression:ID,BigIntLiteral:FA,BinaryExpression:HD,BindExpression:UD,BlockStatement:hM,BooleanLiteral:jA,BooleanLiteralTypeAnnotation:WA,BooleanTypeAnnotation:UA,BreakStatement:cO,CallExpression:PD,CatchClause:mO,ClassAccessorProperty:sM,ClassBody:iM,ClassDeclaration:rM,ClassExpression:rM,ClassImplements:bj,ClassMethod:lM,ClassPrivateMethod:uM,ClassPrivateProperty:cM,ClassProperty:oM,ConditionalExpression:TD,ContinueStatement:lO,DebuggerStatement:_O,DeclareClass:KA,DeclareExportAllDeclaration:rj,DeclareExportDeclaration:nj,DeclareFunction:qA,DeclareInterface:XA,DeclareModule:ZA,DeclareModuleExports:QA,DeclareOpaqueType:ej,DeclareTypeAlias:$A,DeclareVariable:tj,DeclaredPredicate:YA,Decorator:jD,Directive:gM,DirectiveLiteral:yM,DoExpression:SD,DoWhileStatement:oO,EmptyStatement:RD,EmptyTypeAnnotation:Oj,EnumBooleanBody:sj,EnumBooleanMember:pj,EnumDeclaration:ij,EnumDefaultedMember:dj,EnumNumberBody:cj,EnumNumberMember:mj,EnumStringBody:lj,EnumStringMember:hj,EnumSymbolBody:uj,ExistsTypeAnnotation:_j,ExportAllDeclaration:dA,ExportDefaultDeclaration:mA,ExportDefaultSpecifier:sA,ExportNamedDeclaration:pA,ExportNamespaceSpecifier:lA,ExportSpecifier:cA,ExpressionStatement:zD,File:pM,ForInStatement:iO,ForOfStatement:aO,ForStatement:nO,FunctionDeclaration:OO,FunctionExpression:OO,FunctionTypeAnnotation:vj,FunctionTypeParam:yj,GenericTypeAnnotation:bj,Identifier:CA,IfStatement:eO,Import:FD,ImportAttribute:gA,ImportDeclaration:hA,ImportDefaultSpecifier:oA,ImportExpression:vA,ImportNamespaceSpecifier:_A,ImportSpecifier:aA,IndexedAccessType:$j,InferredPredicate:JA,InterfaceDeclaration:Cj,InterfaceExtends:bj,InterfaceTypeAnnotation:Tj,InterpreterDirective:bM,IntersectionTypeAnnotation:Ej,JSXAttribute:SM,JSXClosingElement:NM,JSXClosingFragment:LM,JSXElement:AM,JSXEmptyExpression:PM,JSXExpressionContainer:DM,JSXFragment:FM,JSXIdentifier:CM,JSXMemberExpression:TM,JSXNamespacedName:wM,JSXOpeningElement:MM,JSXOpeningFragment:IM,JSXSpreadAttribute:EM,JSXSpreadChild:OM,JSXText:kM,LabeledStatement:fO,LogicalExpression:VD,MemberExpression:WD,MetaProperty:GD,MixedTypeAnnotation:Dj,ModuleExpression:JD,NewExpression:ED,NullLiteral:MA,NullLiteralTypeAnnotation:GA,NullableTypeAnnotation:kj,NumberLiteralTypeAnnotation:NA,NumberTypeAnnotation:Aj,NumericLiteral:NA,ObjectExpression:EA,ObjectMethod:DA,ObjectPattern:EA,ObjectProperty:OA,ObjectTypeAnnotation:Bj,ObjectTypeCallProperty:Hj,ObjectTypeIndexer:Uj,ObjectTypeInternalSlot:Vj,ObjectTypeProperty:Wj,ObjectTypeSpreadProperty:Gj,OpaqueType:zj,OptionalCallExpression:ND,OptionalIndexedAccessType:eM,OptionalMemberExpression:MD,ParenthesizedExpression:CD,Placeholder:xM,PrivateName:KD,Program:mM,QualifiedTypeIdentifier:Kj,RegExpLiteral:AA,RestElement:TA,ReturnStatement:uO,SequenceExpression:DD,SpreadElement:TA,StaticBlock:fM,StringLiteral:PA,StringLiteralTypeAnnotation:PA,StringTypeAnnotation:jj,Super:kD,SwitchCase:gO,SwitchStatement:hO,SymbolTypeAnnotation:qj,TSAnyKeyword:KO,TSArrayType:pk,TSAsExpression:Pk,TSBigIntKeyword:qO,TSBooleanKeyword:ZO,TSCallSignatureDeclaration:zO,TSClassImplements:Ak,TSConditionalType:xk,TSConstructSignatureDeclaration:VO,TSConstructorType:sk,TSDeclareFunction:IO,TSDeclareMethod:LO,TSEnumBody:zk,TSEnumDeclaration:Rk,TSEnumMember:Bk,TSExportAssignment:qk,TSExternalModuleReference:Gk,TSFunctionType:ok,TSImportEqualsDeclaration:Wk,TSImportType:Uk,TSIndexSignature:GO,TSIndexedAccessType:Tk,TSInferType:Sk,TSInstantiationExpression:Lk,TSInterfaceBody:Mk,TSInterfaceDeclaration:jk,TSInterfaceHeritage:Ak,TSIntersectionType:yk,TSIntrinsicKeyword:ik,TSLiteralType:kk,TSMappedType:Ek,TSMethodSignature:WO,TSModuleBlock:Hk,TSModuleDeclaration:Vk,TSNamedTupleMember:_k,TSNamespaceExportDeclaration:Jk,TSNeverKeyword:rk,TSNonNullExpression:Kk,TSNullKeyword:nk,TSNumberKeyword:YO,TSObjectKeyword:XO,TSOptionalType:hk,TSParameterProperty:FO,TSParenthesizedType:Ck,TSPropertySignature:HO,TSQualifiedName:RO,TSRestType:gk,TSSatisfiesExpression:Fk,TSStringKeyword:QO,TSSymbolKeyword:$O,TSTemplateLiteralType:Ok,TSThisType:ak,TSTupleType:mk,TSTypeAliasDeclaration:Nk,TSTypeAnnotation:MO,TSTypeAssertion:Ik,TSTypeLiteral:fk,TSTypeOperator:wk,TSTypeParameter:PO,TSTypeParameterDeclaration:NO,TSTypeParameterInstantiation:NO,TSTypePredicate:uk,TSTypeQuery:dk,TSTypeReference:lk,TSUndefinedKeyword:tk,TSUnionType:vk,TSUnknownKeyword:JO,TSVoidKeyword:ek,TaggedTemplateExpression:fD,TemplateElement:pD,TemplateLiteral:hD,ThisExpression:OD,ThisTypeAnnotation:Mj,ThrowStatement:dO,TopicReference:LA,TryStatement:pO,TupleTypeAnnotation:Nj,TypeAlias:Fj,TypeAnnotation:Ij,TypeCastExpression:Xj,TypeParameter:Rj,TypeParameterDeclaration:Lj,TypeParameterInstantiation:Lj,TypeofTypeAnnotation:Pj,UnaryExpression:xD,UnionTypeAnnotation:Yj,UpdateExpression:wD,V8IntrinsicIdentifier:qD,VariableDeclaration:yO,VariableDeclarator:bO,Variance:Zj,VoidPattern:RA,VoidTypeAnnotation:Qj,WhileStatement:rO,WithStatement:$D,YieldExpression:LD,_classMethodHead:dM,_functionHead:DO,_getRawIdentifier:SA,_interfaceish:xj,_methodHead:TO,_param:wO,_parameters:CO,_params:SO,_predicate:EO,_printAttributes:uA,_printTemplate:mD,_shouldPrintArrowParamsParens:AO,_shouldPrintDecoratorsBeforeExport:AD,_tsPrintClassMemberModifiers:Xk,_variance:Sj});const zM=new Map;let BM=0;for(let e of Object.keys(RM).sort())e.startsWith(`_`)||zM.set(e,[RM[e],BM++,void 0]);const{VISITOR_KEYS:VM}=gn;for(let e of Object.keys(dD)){let t=dD[e];zM.has(e)&&(zM.get(e)[2]=t)}function HM(e){switch(e.type){case`CallExpression`:return!0;case`MemberExpression`:return HM(e.object)}return!1}function UM(e,t,n){switch(n){case 112:if(t.callee===e&&HM(e))return!0;break;case 42:return!WM(e)&&!(e.type===`CallExpression`&&WM(e.callee))&&e.type!==`ParenthesizedExpression`}return!1}function WM(e){switch(e.type){case`Identifier`:return!0;case`MemberExpression`:return!e.computed&&e.property.type===`Identifier`&&WM(e.object);default:return!1}}function GM(e,t){let n=VM[e.type];for(let r=n.length-1;r>=0;r--){let i=e[n[r]];if(i===t)return!0;if(Array.isArray(i)){let e=i.length-1;for(;e>=0&&i[e]===null;)e--;return e>=0&&i[e]===t}else if(i)return!1}return!1}const{traverseFast:KM,VISITOR_KEYS:qM}=gn;var JM=class{_tokens;_source;_nodesToTokenIndexes=new Map;_nodesOccurrencesCountCache=new Map;_tokensCache=new Map;constructor(e,t,n){this._tokens=t,this._source=n,KM(e,e=>{let t=this._getTokensIndexesOfNode(e);t.length>0&&this._nodesToTokenIndexes.set(e,t)}),this._tokensCache.clear()}has(e){return this._nodesToTokenIndexes.has(e)}getIndexes(e){return this._nodesToTokenIndexes.get(e)}find(e,t){let n=this._nodesToTokenIndexes.get(e);if(n)for(let e=0;e<n.length;e++){let r=n[e],i=this._tokens[r];if(t(i,r))return i}return null}findLastIndex(e,t){let n=this._nodesToTokenIndexes.get(e);if(n)for(let e=n.length-1;e>=0;e--){let r=n[e],i=this._tokens[r];if(t(i,r))return r}return-1}findMatching(e,t,n=0){let r=this._nodesToTokenIndexes.get(e);if(r){typeof t==`number`&&(t=String.fromCharCode(t));let i=0,a=n;if(a>1){let r=this._nodesOccurrencesCountCache.get(e);r?.test===t&&r.count<a&&(i=r.i+1,n-=r.count+1)}for(;i<r.length;i++){let o=this._tokens[r[i]];if(this.matchesOriginal(o,t)){if(n===0)return a>0&&this._nodesOccurrencesCountCache.set(e,{test:t,count:a,i}),o;n--}}}return null}matchesOriginal(e,t){return e.end-e.start===t.length?e.value==null?this._source.startsWith(t,e.start):e.value===t:!1}startMatches(e,t){let n=this._nodesToTokenIndexes.get(e);if(!n)return!1;let r=this._tokens[n[0]];return r.start===e.start?this.matchesOriginal(r,t):!1}endMatches(e,t){let n=this._nodesToTokenIndexes.get(e);if(!n)return!1;let r=this._tokens[n[n.length-1]];return r.end===e.end?this.matchesOriginal(r,t):!1}_getTokensIndexesOfNode(e){if(e.start==null||e.end==null)return[];let{first:t,last:n}=this._findTokensOfNode(e,0,this._tokens.length-1),r=t,i=YM(e);(e.type===`ExportNamedDeclaration`||e.type===`ExportDefaultDeclaration`)&&e.declaration?.type===`ClassDeclaration`&&i.next();let a=[];for(let e of i){if(e==null||e.start==null||e.end==null)continue;let t=this._findTokensOfNode(e,r,n),i=t.first;for(let e=r;e<i;e++)a.push(e);r=t.last+1}for(let e=r;e<=n;e++)a.push(e);return a}_findTokensOfNode(e,t,n){let r=this._tokensCache.get(e);if(r)return r;let i=this._findFirstTokenOfNode(e.start,t,n),a=this._findLastTokenOfNode(e.end,i,n);return this._tokensCache.set(e,{first:i,last:a}),{first:i,last:a}}_findFirstTokenOfNode(e,t,n){for(;t<=n;){let r=n+t>>1;if(e<this._tokens[r].start)n=r-1;else if(e>this._tokens[r].start)t=r+1;else return r}return t}_findLastTokenOfNode(e,t,n){for(;t<=n;){let r=n+t>>1;if(e<this._tokens[r].end)n=r-1;else if(e>this._tokens[r].end)t=r+1;else return r}return n}};function*YM(e){if(e.type===`TemplateLiteral`){yield e.quasis[0];for(let t=1;t<e.quasis.length;t++)yield e.expressions[t-1],yield e.quasis[t];return}let t=qM[e.type];for(let n of t){let t=e[n];t&&(Array.isArray(t)?yield*t:yield t)}}const{isExpression:XM,isFunction:ZM,isStatement:QM,isClassBody:$M,isTSInterfaceBody:eN,isTSEnumMember:tN}=gn,nN=/e/i,rN=/\.0+$/,iN=/[\n\r\u2028\u2029]/,aN=/[\n\r\u2028\u2029]|\*\//;function oN(e){return e.type===`CommentLine`||iN.test(e.value)}var sN=class{constructor(e,t,n=null,r=null){this.format=e,this._tokens=n,this._originalCode=r,this._indentRepeat=e.indent.style.length,this._inputMap=t?._inputMap||null,this._buf=new OE(t,e.indent.style[0]);let{preserveFormat:i,compact:a,concise:o,retainLines:s,retainFunctionParens:c}=e;i&&(this._flags|=1),a&&(this._flags|=2),o&&(this._flags|=4),s&&(this._flags|=8),c&&(this._flags|=16),(e.auxiliaryCommentBefore||e.auxiliaryCommentAfter)&&(this._flags|=32)}enterDelimited(){let e=this._noLineTerminatorAfterNode;return e!==null&&(this._noLineTerminatorAfterNode=null),e}tokenContext=0;_tokens=null;_originalCode=null;_currentNode=null;_currentTypeId=null;_indent=0;_indentRepeat=0;_insideAux=!1;_noLineTerminator=!1;_noLineTerminatorAfterNode=null;_printAuxAfterOnNextUserNode=!1;_printedComments=new Set;_lastCommentLine=0;_innerCommentsState=0;_flags=0;tokenMap=null;_boundGetRawIdentifier=null;generate(e){return this.format.preserveFormat&&(this.tokenMap=new JM(e,this._tokens,this._originalCode),this._boundGetRawIdentifier=SA.bind(this)),this.print(e),this._maybeAddAuxComment(),this._buf.get()}indent(e=this._flags){e&7||(this._indent+=this._indentRepeat)}dedent(e=this._flags){e&7||(this._indent-=this._indentRepeat)}_printSemicolonBeforeNextNode=-1;_printSemicolonBeforeNextToken=-1;semicolon(e=!1){let t=this._flags;if(t&32&&this._maybeAddAuxComment(),t&1){let e=this._currentNode;if(e.start!=null&&e.end!=null){if(!this.tokenMap.endMatches(e,`;`)){this._printSemicolonBeforeNextNode=this._buf.getCurrentLine();return}let t=this.tokenMap.getIndexes(this._currentNode);this._catchUpTo(this._tokens[t[t.length-1]].loc.start)}}e?this._appendChar(59):this._queue(59),this._noLineTerminator=!1}rightBrace(e){this.format.minified&&this._buf.removeLastSemicolon(),this.sourceWithOffset(`end`,e.loc,-1),this.tokenChar(125)}rightParens(e){this.sourceWithOffset(`end`,e.loc,-1),this.tokenChar(41)}space(e=!1){if(!(this._flags&3))if(e)this._space();else{let e=this.getLastChar(!0);e!==0&&e!==32&&e!==10&&this._space()}}word(e,t=!1){this.tokenContext&=128,this._maybePrintInnerComments(e);let n=this._flags;n&32&&this._maybeAddAuxComment(),n&1&&this._catchUpToCurrentToken(e);let r=this.getLastChar();(r===-2||r===-3||r===47&&e.charCodeAt(0)===47)&&this._space(),this._append(e,!1),this.setLastChar(-3),this._noLineTerminator=t}number(e,t){function n(e){if(e.length>2&&e.charCodeAt(0)===48){let t=e.charCodeAt(1);return t===98||t===111||t===120}return!1}this.word(e),Number.isInteger(t)&&!n(e)&&!nN.test(e)&&!rN.test(e)&&e.charCodeAt(e.length-1)!==46&&this.setLastChar(-2)}token(e,t=!1,n=0,r=!1){this.tokenContext&=128,this._maybePrintInnerComments(e,n);let i=this._flags;if(i&32&&this._maybeAddAuxComment(),i&1&&this._catchUpToCurrentToken(e,n),r){let t=e.charCodeAt(0);((t===45&&e===`--`||t===61)&&this.getLastChar()===33||t===43&&this.getLastChar()===43||t===45&&this.getLastChar()===45||t===46&&this.getLastChar()===-2)&&this._space()}this._append(e,t),this._noLineTerminator=!1}tokenChar(e,t=0){this.tokenContext&=128,this._maybePrintInnerComments(e,t);let n=this._flags;n&32&&this._maybeAddAuxComment(),n&1&&this._catchUpToCurrentToken(e,t),(e===43&&this.getLastChar()===43||e===45&&this.getLastChar()===45||e===46&&this.getLastChar()===-2)&&this._space(),this._appendChar(e),this._noLineTerminator=!1}newline(e=1,t=this._flags){if(!(e<=0)&&!(t&10)){if(t&4){this.space();return}e>2&&(e=2),e-=this._buf.getNewlineCount();for(let t=0;t<e;t++)this._newline()}}endsWith(e){return this.getLastChar(!0)===e}getLastChar(e){return this._buf.getLastChar(e)}setLastChar(e){this._buf._last=e}exactSource(e,t){if(!e){t();return}this._catchUp(`start`,e),this._buf.exactSource(e,t)}source(e,t){t&&(this._catchUp(e,t),this._buf.source(e,t))}sourceWithOffset(e,t,n){!t||this.format.preserveFormat||(this._catchUp(e,t),this._buf.sourceWithOffset(e,t,n))}sourceIdentifierName(e,t){if(!this._buf._canMarkIdName)return;let n=this._buf._sourcePosition;n.identifierNamePos=t,n.identifierName=e}_space(){this._queue(32)}_newline(){this._buf._queuedChar===32&&(this._buf._queuedChar=0),this._appendChar(10,!0)}_catchUpToCurrentToken(e,t=0){let n=this.tokenMap.findMatching(this._currentNode,e,t);n&&this._catchUpTo(n.loc.start),this._printSemicolonBeforeNextToken!==-1&&this._printSemicolonBeforeNextToken===this._buf.getCurrentLine()&&this._appendChar(59,!0),this._printSemicolonBeforeNextToken=-1,this._printSemicolonBeforeNextNode=-1}_append(e,t){this._maybeIndent(),this._buf.append(e,t)}_appendChar(e,t){t||this._maybeIndent(),this._buf.appendChar(e)}_queue(e){this._buf.queue(e),this.setLastChar(-1)}_maybeIndent(){let e=this._shouldIndent();e>0&&this._buf._appendChar(-1,e,!1)}_shouldIndent(){return this.endsWith(10)?this._indent:0}catchUp(e){if(!this.format.retainLines)return;let t=e-this._buf.getCurrentLine();for(let e=0;e<t;e++)this._newline()}_catchUp(e,t){let n=this._flags;if(!(n&1)){n&8&&t?.[e]&&this.catchUp(t[e].line);return}let r=t?.[e];r!=null&&this._catchUpTo(r)}_catchUpTo({line:e,column:t,index:n}){let r=e-this._buf.getCurrentLine();if(r>0&&this._noLineTerminator)return;for(let e=0;e<r;e++)this._newline();let i=r>0?t:t-this._buf.getCurrentColumn();if(i>0){let e=this._originalCode?this._originalCode.slice(n-i,n).replace(/[^\t\v\f\uFEFF\p{Space_Separator}]/gu,` `):` `.repeat(i);this._append(e,!1),this.setLastChar(32)}}printTerminatorless(e){this._noLineTerminator=!0,this.print(e)}print(e,t=!1,n=!1,r){if(!e)return;this._innerCommentsState=0;let{type:i,loc:a,extra:o}=e,s=this._flags,c=!1;e._compact&&(this._flags|=4,c=!0);let l=zM.get(i);if(l===void 0)throw ReferenceError(`unknown node of type ${JSON.stringify(i)} with constructor ${JSON.stringify(e.constructor.name)}`);let[u,d,f]=l,p=this._currentNode,m=this._currentTypeId;this._currentNode=e,this._currentTypeId=d,s&1&&(this._printSemicolonBeforeNextToken=this._printSemicolonBeforeNextNode);let h;s&32&&(h=this._insideAux,this._insideAux=a==null,this._maybeAddAuxComment(this._insideAux&&!h));let g=0;n&&(g=this.tokenContext,g&128?this.tokenContext=0:g=0);let ee=o!=null&&o.parenthesized,_=ee&&s&1||ee&&s&16&&d===71||p&&(UM(e,p,m)||f!=null&&f(e,p,m,this.tokenContext,s&1?this._boundGetRawIdentifier:void 0));if(!_&&ee&&e.leadingComments?.length&&e.leadingComments[0].type===`CommentBlock`)switch(m){case 65:case 240:case 6:case 140:break;case 17:case 130:case 112:if(p.callee!==e)break;default:_=!0}let v=!1;!_&&this._noLineTerminator&&(e.leadingComments?.some(oN)||s&8&&a&&a.start.line>this._buf.getCurrentLine())&&(_=!0,v=!0);let te;_||(t||=!!p&&this._noLineTerminatorAfterNode===p&&GM(p,e),t&&(e.trailingComments?.some(oN)?XM(e)&&(_=!0):(te=this._noLineTerminatorAfterNode,this._noLineTerminatorAfterNode=e))),_&&(this.tokenChar(40),v&&this.indent(),this._innerCommentsState=0,n||(g=this.tokenContext),g&128&&(this.tokenContext=0),te=this._noLineTerminatorAfterNode,this._noLineTerminatorAfterNode=null),this._printLeadingComments(e,p),this.exactSource(d===136||d===66?null:a,u.bind(this,e,p)),_?(this._printTrailingComments(e,p),v&&(this.dedent(),this.newline()),this.tokenChar(41),this._noLineTerminator=t):t&&!this._noLineTerminator?(this._noLineTerminator=!0,this._printTrailingComments(e,p)):this._printTrailingComments(e,p,r),g&&(this.tokenContext=g),this._currentNode=p,this._currentTypeId=m,c&&(this._flags=s),s&32&&(this._insideAux=h),te!=null&&(this._noLineTerminatorAfterNode=te),this._innerCommentsState=0}_maybeAddAuxComment(e){e&&this._printAuxBeforeComment(),this._insideAux||this._printAuxAfterComment()}_printAuxBeforeComment(){if(this._printAuxAfterOnNextUserNode)return;this._printAuxAfterOnNextUserNode=!0;let e=this.format.auxiliaryCommentBefore;e&&this._printComment({type:`CommentBlock`,value:e},0)}_printAuxAfterComment(){if(!this._printAuxAfterOnNextUserNode)return;this._printAuxAfterOnNextUserNode=!1;let e=this.format.auxiliaryCommentAfter;e&&this._printComment({type:`CommentBlock`,value:e},0)}getPossibleRaw(e){let t=e.extra;if(t?.raw!=null&&t.rawValue!=null&&e.value===t.rawValue)return t.raw}printJoin(e,t,n,r,i,a,o){if(!e?.length)return;let s=this._flags;if(n==null&&s&8){let t=e[0].loc?.start.line;t!=null&&t!==this._buf.getCurrentLine()&&(n=!0)}n&&this.indent(s);let c=e.length;for(let n=0;n<c;n++){let l=e[n];if(l&&(t&&n===0&&this._buf.hasContent()&&this.newline(1,s),this.print(l,!1,a,o||0),r!=null&&(n<c-1?r.call(this,n,!1):i&&r.call(this,n,!0)),t))if(n+1===c)this.newline(1,s);else{let t=this._lastCommentLine;if(t>0){let r=(e[n+1].loc?.start.line||0)-t;if(r>=0){this.newline(r||1,s);continue}}this.newline(1,s)}}n&&this.dedent(s)}printAndIndentOnComments(e){let t=e.leadingComments&&e.leadingComments.length>0;t&&this.indent(),this.print(e),t&&this.dedent()}printBlock(e){e.type!==`EmptyStatement`&&this.space(),this.print(e)}_printTrailingComments(e,t,n){let{innerComments:r,trailingComments:i}=e;r?.length&&this._printComments(2,r,e,t,n),i?.length?this._printComments(2,i,e,t,n):this._lastCommentLine=0}_printLeadingComments(e,t){let n=e.leadingComments;n?.length&&this._printComments(0,n,e,t)}_maybePrintInnerComments(e,t){let n=this._innerCommentsState;switch(n&3){case 0:this._innerCommentsState=5;return;case 1:this.printInnerComments((n&4)>0,this.tokenMap?.findMatching(this._currentNode,e,t))}}printInnerComments(e=!0,t){let n=this._currentNode,r=n.innerComments;if(!r?.length){this._innerCommentsState=2;return}let i=this.endsWith(32);switch(e&&this.indent(),this._printComments(1,r,n,void 0,void 0,t)){case 2:this._innerCommentsState=2;case 1:i&&this.space()}e&&this.dedent()}noIndentInnerCommentsHere(){this._innerCommentsState&=-5}printSequence(e,t,n,r){this.printJoin(e,!0,t??!1,void 0,void 0,n,r)}printList(e,t,n,r,i,a){this.printJoin(e,n,r,i??cN,t,a)}shouldPrintTrailingComma(e){if(!this.tokenMap)return null;let t=this.tokenMap.findLastIndex(this._currentNode,t=>this.tokenMap.matchesOriginal(t,typeof e==`number`?String.fromCharCode(e):e));return t<=0?null:this.tokenMap.matchesOriginal(this._tokens[t-1],`,`)}_shouldPrintComment(e,t){if(e.ignore||this._printedComments.has(e))return 0;if(this._noLineTerminator&&aN.test(e.value))return 2;if(t&&this.tokenMap){let n=this.tokenMap.find(this._currentNode,t=>t.value===e.value);if(n&&n.start>t.start)return 2}return this._printedComments.add(e),this.format.shouldPrintComment(e.value)?1:0}_printComment(e,t){let n=this._noLineTerminator,r=e.type===`CommentBlock`,i=r&&t!==1&&!n;switch(i&&this._buf.hasContent()&&t!==2&&this.newline(1),this.getLastChar(!0)){case 47:this._space();case 91:case 123:case 40:break;default:this.space()}let a;if(r){if(a=`/*${e.value}*/`,this.format.indent.adjustMultilineComment){let t=e.loc?.start.column;if(t){let e=RegExp(`\\n\\s{1,`+t+`}`,`g`);a=a.replace(e,`
|
|
9
|
+
`)}if(this._flags&4)a=a.replace(/\n(?!$)/g,`
|
|
10
|
+
`);else{let e=this.format.retainLines?0:this._buf.getCurrentColumn();(this._shouldIndent()||this.format.retainLines)&&(e+=this._indent),a=a.replace(/\n(?!$)/g,`\n${` `.repeat(e)}`)}}}else a=n?`/*${e.value}*/`:`//${e.value}`;this.source(`start`,e.loc),this._append(a,r),!r&&!n&&this._newline(),i&&t!==3&&this.newline(1)}_printComments(e,t,n,r,i=0,a){let o=n.loc,s=t.length,c=!!o,l=c?o.start.line:0,u=c?o.end.line:0,d=0,f=0,{_noLineTerminator:p,_flags:m}=this;for(let o=0;o<s;o++){let h=t[o],g=this._shouldPrintComment(h,a);if(g===2)return o===0?0:1;if(c&&h.loc&&g===1){let t=h.loc.start.line,n=h.loc.end.line;if(e===0){let e=0;if(o===0?this._buf.hasContent()&&(h.type===`CommentLine`||t!==n)&&(e=f=1):e=t-d,d=n,e>0&&!p&&this.newline(e,m),this._printComment(h,1),o+1===s){let e=Math.max(l-d,f);e>0&&!p&&this.newline(e,m),d=l}}else if(e===1){let e=t-(o===0?l:d);if(d=n,e>0&&!p&&this.newline(e,m),this._printComment(h,1),o+1===s){let e=Math.min(1,u-d);e>0&&!p&&this.newline(e,m),d=u}}else{let e=t-(o===0?u-i:d);d=n,e>0&&!p&&this.newline(e,m),this._printComment(h,1)}}else{if(c=!1,g!==1)continue;if(s===1){let t=h.loc?h.loc.start.line===h.loc.end.line:!iN.test(h.value),i=t&&!QM(n)&&!$M(r)&&!eN(r)&&!tN(n);e===0?this._printComment(h,i&&n.type!==`ObjectExpression`||t&&ZM(r)&&r.body===n?1:0):i&&e===2?this._printComment(h,1):this._printComment(h,0)}else e===1&&!(n.type===`ObjectExpression`&&n.properties.length>1)&&n.type!==`ClassBody`&&n.type!==`TSInterfaceBody`?this._printComment(h,o===0?2:o===s-1?3:0):this._printComment(h,0)}}return e===2&&c&&d&&(this._lastCommentLine=d),2}};function cN(e,t){this.tokenChar(44,e),t||this.space()}function lN(e,t,n){if(t.experimental_preserveFormat){if(typeof e!=`string`)throw Error("`experimental_preserveFormat` requires the original `code` to be passed to @babel/generator as a string");if(!t.retainLines)throw Error("`experimental_preserveFormat` requires `retainLines` to be set to `true`");if(t.compact&&t.compact!==`auto`)throw Error("`experimental_preserveFormat` is not compatible with the `compact` option");if(t.minified)throw Error("`experimental_preserveFormat` is not compatible with the `minified` option");if(t.jsescOption)throw Error("`experimental_preserveFormat` is not compatible with the `jsescOption` option");if(!Array.isArray(n.tokens))throw Error("`experimental_preserveFormat` requires the AST to have attached the token of the input code. Make sure to enable the `tokens: true` parser option.")}let r={auxiliaryCommentBefore:t.auxiliaryCommentBefore,auxiliaryCommentAfter:t.auxiliaryCommentAfter,shouldPrintComment:t.shouldPrintComment,preserveFormat:t.experimental_preserveFormat,retainLines:t.retainLines,retainFunctionParens:t.retainFunctionParens,comments:t.comments==null||t.comments,compact:t.compact,minified:t.minified,concise:t.concise,indent:{adjustMultilineComment:!0,style:` `},jsescOption:{quotes:`double`,wrap:!0,minimal:!0,...t.jsescOption},topicToken:t.topicToken};r.minified?(r.compact=!0,r.shouldPrintComment=r.shouldPrintComment||(()=>r.comments)):r.shouldPrintComment=r.shouldPrintComment||(e=>r.comments||e.includes(`@license`)||e.includes(`@preserve`)),r.compact===`auto`&&(r.compact=typeof e==`string`&&e.length>5e5,r.compact&&console.error(`[BABEL] Note: The code generator has deoptimised the styling of ${t.filename} as it exceeds the max of 500KB.`)),(r.compact||r.preserveFormat)&&(r.indent.adjustMultilineComment=!1);let{auxiliaryCommentBefore:i,auxiliaryCommentAfter:a,shouldPrintComment:o}=r;return i&&!o(i)&&(r.auxiliaryCommentBefore=void 0),a&&!o(a)&&(r.auxiliaryCommentAfter=void 0),r}function uN(e,t={},n){return new sN(lN(n,t,e),t.sourceMaps?new EE(t,n):null,e.tokens,typeof n==`string`?n:null).generate(e)}var dN=class{line;column;index;constructor(e,t,n){this.line=e,this.column=t,this.index=n}},fN=class{start;end;filename;identifierName;constructor(e,t){this.start=e,this.end=t}};function pN(e,t){let{line:n,column:r,index:i}=e;return new dN(n,r+t,i+t)}const mN=`BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED`;var hN={ImportMetaOutsideModule:{message:`import.meta may appear only with 'sourceType: "module"'`,code:mN},ImportOutsideModule:{message:`'import' and 'export' may appear only with 'sourceType: "module"'`,code:mN}};const gN={ArrayPattern:`array destructuring pattern`,AssignmentExpression:`assignment expression`,AssignmentPattern:`assignment expression`,ArrowFunctionExpression:`arrow function expression`,ConditionalExpression:`conditional expression`,CatchClause:`catch clause`,ForOfStatement:`for-of statement`,ForInStatement:`for-in statement`,ForStatement:`for-loop`,FormalParameters:`function parameter list`,Identifier:`identifier`,ImportSpecifier:`import specifier`,ImportDefaultSpecifier:`import default specifier`,ImportNamespaceSpecifier:`import namespace specifier`,ObjectPattern:`object destructuring pattern`,ParenthesizedExpression:`parenthesized expression`,RestElement:`rest element`,UpdateExpression:{true:`prefix operation`,false:`postfix operation`},VariableDeclarator:`variable declaration`,YieldExpression:`yield expression`},_N=e=>e.type===`UpdateExpression`?gN.UpdateExpression[`${e.prefix}`]:gN[e.type];var vN={AccessorIsGenerator:({kind:e})=>`A ${e}ter cannot be a generator.`,ArgumentsInClass:`'arguments' is only allowed in functions and class methods.`,AsyncFunctionInSingleStatementContext:`Async functions can only be declared at the top level or inside a block.`,AwaitBindingIdentifier:`Can not use 'await' as identifier inside an async function.`,AwaitBindingIdentifierInStaticBlock:`Can not use 'await' as identifier inside a static block.`,AwaitExpressionFormalParameter:`'await' is not allowed in async function parameters.`,AwaitUsingNotInAsyncContext:`'await using' is only allowed within async functions and at the top levels of modules.`,AwaitNotInAsyncContext:`'await' is only allowed within async functions and at the top levels of modules.`,BadGetterArity:`A 'get' accessor must not have any formal parameters.`,BadSetterArity:`A 'set' accessor must have exactly one formal parameter.`,BadSetterRestParameter:`A 'set' accessor function argument must not be a rest parameter.`,ConstructorClassField:`Classes may not have a field named 'constructor'.`,ConstructorClassPrivateField:`Classes may not have a private field named '#constructor'.`,ConstructorIsAccessor:`Class constructor may not be an accessor.`,ConstructorIsAsync:`Constructor can't be an async function.`,ConstructorIsGenerator:`Constructor can't be a generator.`,DeclarationMissingInitializer:({kind:e})=>`Missing initializer in ${e} declaration.`,DecoratorArgumentsOutsideParentheses:`Decorator arguments must be moved inside parentheses: use '@(decorator(args))' instead of '@(decorator)(args)'.`,DecoratorsBeforeAfterExport:`Decorators can be placed *either* before or after the 'export' keyword, but not in both locations at the same time.`,DecoratorConstructor:`Decorators can't be used with a constructor. Did you mean '@dec class { ... }'?`,DecoratorSemicolon:`Decorators must not be followed by a semicolon.`,DecoratorStaticBlock:`Decorators can't be used with a static block.`,DeferImportRequiresNamespace:'Only `import defer * as x from "./module"` is valid.',DeletePrivateField:`Deleting a private field is not allowed.`,DestructureNamedImport:`ES2015 named imports do not destructure. Use another statement for destructuring after the import.`,DuplicateConstructor:`Duplicate constructor in the same class.`,DuplicateDefaultExport:`Only one default export allowed per module.`,DuplicateExport:({exportName:e})=>`\`${e}\` has already been exported. Exported identifiers must be unique.`,DuplicateProto:`Redefinition of __proto__ property.`,DuplicateRegExpFlags:`Duplicate regular expression flag.`,ElementAfterRest:`Rest element must be last element.`,EscapedCharNotAnIdentifier:`Invalid Unicode escape.`,ExportBindingIsString:({localName:e,exportName:t})=>`A string literal cannot be used as an exported binding without \`from\`.\n- Did you mean \`export { '${e}' as '${t}' } from 'some-module'\`?`,ExportDefaultFromAsIdentifier:`'from' is not allowed as an identifier after 'export default'.`,ForInOfLoopInitializer:({type:e})=>`'${e===`ForInStatement`?`for-in`:`for-of`}' loop variable declaration may not have an initializer.`,ForInUsing:`For-in loop may not start with 'using' declaration.`,ForOfAsync:`The left-hand side of a for-of loop may not be 'async'.`,ForOfLet:`The left-hand side of a for-of loop may not start with 'let'.`,GeneratorInSingleStatementContext:`Generators can only be declared at the top level or inside a block.`,IllegalBreakContinue:({type:e})=>`Unsyntactic ${e===`BreakStatement`?`break`:`continue`}.`,IllegalLanguageModeDirective:`Illegal 'use strict' directive in function with non-simple parameter list.`,IllegalReturn:`'return' outside of function.`,ImportBindingIsString:({importName:e})=>`A string literal cannot be used as an imported binding.\n- Did you mean \`import { "${e}" as foo }\`?`,ImportCallArity:"`import()` requires exactly one or two arguments.",ImportCallNotNewExpression:`Cannot use new with import(...).`,ImportCallSpreadArgument:"`...` is not allowed in `import()`.",IncompatibleRegExpUVFlags:`The 'u' and 'v' regular expression flags cannot be enabled at the same time.`,InvalidBigIntLiteral:`Invalid BigIntLiteral.`,InvalidCodePoint:`Code point out of bounds.`,InvalidCoverDiscardElement:`'void' must be followed by an expression when not used in a binding position.`,InvalidCoverInitializedName:`Invalid shorthand property initializer.`,InvalidDigit:({radix:e})=>`Expected number in radix ${e}.`,InvalidEscapeSequence:`Bad character escape sequence.`,InvalidEscapeSequenceTemplate:`Invalid escape sequence in template.`,InvalidEscapedReservedWord:({reservedWord:e})=>`Escape sequence in keyword ${e}.`,InvalidIdentifier:({identifierName:e})=>`Invalid identifier ${e}.`,InvalidLhs:({ancestor:e})=>`Invalid left-hand side in ${_N(e)}.`,InvalidLhsBinding:({ancestor:e})=>`Binding invalid left-hand side in ${_N(e)}.`,InvalidLhsOptionalChaining:({ancestor:e})=>`Invalid optional chaining in the left-hand side of ${_N(e)}.`,InvalidNumber:`Invalid number.`,InvalidOrMissingExponent:`Floating-point numbers require a valid exponent after the 'e'.`,InvalidOrUnexpectedToken:({unexpected:e})=>`Unexpected character '${e}'.`,InvalidParenthesizedAssignment:`Invalid parenthesized assignment pattern.`,InvalidPrivateFieldResolution:({identifierName:e})=>`Private name #${e} is not defined.`,InvalidPropertyBindingPattern:`Binding member expression.`,InvalidRestAssignmentPattern:`Invalid rest operator's argument.`,LabelRedeclaration:({labelName:e})=>`Label '${e}' is already declared.`,LetInLexicalBinding:`'let' is disallowed as a lexically bound name.`,LineTerminatorBeforeArrow:`No line break is allowed before '=>'.`,MalformedRegExpFlags:`Invalid regular expression flag.`,MissingClassName:`A class name is required.`,MissingEqInAssignment:`Only '=' operator can be used for specifying default value.`,MissingSemicolon:`Missing semicolon.`,MissingPlugin:({missingPlugin:e})=>`This experimental syntax requires enabling the parser plugin: ${e.map(e=>JSON.stringify(e)).join(`, `)}.`,MissingOneOfPlugins:({missingPlugin:e})=>`This experimental syntax requires enabling one of the following parser plugin(s): ${e.map(e=>JSON.stringify(e)).join(`, `)}.`,MissingUnicodeEscape:`Expecting Unicode escape sequence \\uXXXX.`,MixingCoalesceWithLogical:`Nullish coalescing operator(??) requires parens when mixing with logical operators.`,ModuleAttributeInvalidValue:`Only string literals are allowed as module attribute values.`,ModuleAttributesWithDuplicateKeys:({key:e})=>`Duplicate key "${e}" is not allowed in module attributes.`,ModuleExportNameHasLoneSurrogate:({surrogateCharCode:e})=>`An export name cannot include a lone surrogate, found '\\u${e.toString(16)}'.`,ModuleExportUndefined:({localName:e})=>`Export '${e}' is not defined.`,MultipleDefaultsInSwitch:`Multiple default clauses.`,NewlineAfterThrow:`Illegal newline after throw.`,NoCatchOrFinally:`Missing catch or finally clause.`,NumberIdentifier:`Identifier directly after number.`,NumericSeparatorInEscapeSequence:`Numeric separators are not allowed inside unicode escape sequences or hex escape sequences.`,ObsoleteAwaitStar:`'await*' has been removed from the async functions proposal. Use Promise.all() instead.`,OptionalChainingNoNew:`Constructors in/after an Optional Chain are not allowed.`,OptionalChainingNoTemplate:`Tagged Template Literals are not allowed in optionalChain.`,OverrideOnConstructor:`'override' modifier cannot appear on a constructor declaration.`,ParamDupe:`Argument name clash.`,PatternHasAccessor:`Object pattern can't contain getter or setter.`,PatternHasMethod:`Object pattern can't contain methods.`,PrivateInExpectedIn:({identifierName:e})=>`Private names are only allowed in property accesses (\`obj.#${e}\`) or in \`in\` expressions (\`#${e} in obj\`).`,PrivateNameRedeclaration:({identifierName:e})=>`Duplicate private name #${e}.`,RestTrailingComma:`Unexpected trailing comma after rest element.`,SloppyFunction:`In non-strict mode code, functions can only be declared at top level or inside a block.`,SloppyFunctionAnnexB:`In non-strict mode code, functions can only be declared at top level, inside a block, or as the body of an if statement.`,SourcePhaseImportRequiresDefault:'Only `import source x from "./module"` is valid.',StaticPrototype:`Classes may not have static property named prototype.`,SuperNotAllowed:"`super()` is only valid inside a class constructor of a subclass. Maybe a typo in the method name ('constructor') or not extending another class?",SuperPrivateField:`Private fields can't be accessed on super.`,TrailingDecorator:`Decorators must be attached to a class element.`,UnexpectedArgumentPlaceholder:`Unexpected argument placeholder.`,UnexpectedDigitAfterHash:`Unexpected digit after hash token.`,UnexpectedImportExport:`'import' and 'export' may only appear at the top level.`,UnexpectedKeyword:({keyword:e})=>`Unexpected keyword '${e}'.`,UnexpectedLeadingDecorator:`Leading decorators must be attached to a class declaration.`,UnexpectedLexicalDeclaration:`Lexical declaration cannot appear in a single-statement context.`,UnexpectedNewTarget:"`new.target` can only be used in functions or class properties.",UnexpectedNumericSeparator:`A numeric separator is only allowed between two digits.`,UnexpectedPrivateField:`Unexpected private name.`,UnexpectedReservedWord:({reservedWord:e})=>`Unexpected reserved word '${e}'.`,UnexpectedSuper:`'super' is only allowed in object methods and classes.`,UnexpectedToken:({expected:e,unexpected:t})=>`Unexpected token${t?` '${t}'.`:``}${e?`, expected "${e}"`:``}`,UnexpectedTokenUnaryExponentiation:`Illegal expression. Wrap left hand side or entire exponentiation in parentheses.`,UnexpectedUsingDeclaration:"Using declaration cannot appear in the top level when source type is `script` or in the bare case statement.",UnexpectedVoidPattern:`Unexpected void binding.`,UnsupportedBind:`Binding should be performed on object property.`,UnsupportedDecoratorExport:`A decorated export must export a class declaration.`,UnsupportedDefaultExport:"Only expressions, functions or classes are allowed as the `default` export.",UnsupportedImport:"`import` can only be used in `import()` or `import.meta`.",UnsupportedMetaProperty:({target:e,onlyValidPropertyName:t})=>`The only valid meta property for ${e} is ${e}.${t}.`,UnsupportedParameterDecorator:`Decorators cannot be used to decorate parameters.`,UnsupportedPropertyDecorator:`Decorators cannot be used to decorate object literal properties.`,UnsupportedSuper:`'super' can only be used with function calls (i.e. super()) or in property accesses (i.e. super.prop or super[prop]).`,UnterminatedComment:`Unterminated comment.`,UnterminatedRegExp:`Unterminated regular expression.`,UnterminatedString:`Unterminated string constant.`,UnterminatedTemplate:`Unterminated template.`,UsingDeclarationExport:`Using declaration cannot be exported.`,UsingDeclarationHasBindingPattern:`Using declaration cannot have destructuring patterns.`,VarRedeclaration:({identifierName:e})=>`Identifier '${e}' has already been declared.`,VoidPatternCatchClauseParam:"A void binding can not be the catch clause parameter. Use `try { ... } catch { ... }` if you want to discard the caught error.",VoidPatternInitializer:`A void binding may not have an initializer.`,YieldBindingIdentifier:`Can not use 'yield' as identifier inside a generator.`,YieldInParameter:`Yield expression is not allowed in formal parameters.`,YieldNotInGeneratorFunction:`'yield' is only allowed within generator functions.`,ZeroDigitNumericSeparator:`Numeric separator can not be used after leading 0.`},yN={StrictDelete:`Deleting local variable in strict mode.`,StrictEvalArguments:({referenceName:e})=>`Assigning to '${e}' in strict mode.`,StrictEvalArgumentsBinding:({bindingName:e})=>`Binding '${e}' in strict mode.`,StrictFunction:`In strict mode code, functions can only be declared at top level or inside a block.`,StrictNumericEscape:`The only valid numeric escape in strict mode is '\\0'.`,StrictOctalLiteral:`Legacy octal literals are not allowed in strict mode.`,StrictWith:`'with' in strict mode.`},bN={ParseExpressionEmptyInput:`Unexpected parseExpression() input: The input is empty or contains only comments.`,ParseExpressionExpectsEOF:({unexpected:e})=>`Unexpected parseExpression() input: The input should contain exactly one expression, but the first expression is followed by the unexpected character \`${String.fromCodePoint(e)}\`.`};const xN=new Set([`ArrowFunctionExpression`,`AssignmentExpression`,`ConditionalExpression`,`YieldExpression`]);var SN={PipeBodyIsTighter:`Unexpected yield after pipeline body; any yield expression acting as Hack-style pipe body must be parenthesized due to its loose operator precedence.`,PipeTopicRequiresHackPipes:'Topic references are only supported when using the `"proposal": "hack"` version of the pipeline proposal.',PipeTopicUnbound:`Topic reference is unbound; it must be inside a pipe body.`,PipeTopicUnconfiguredToken:({token:e})=>`Invalid topic token ${e}. In order to use ${e} as a topic reference, the pipelineOperator plugin must be configured with { "proposal": "hack", "topicToken": "${e}" }.`,PipeTopicUnused:`Hack-style pipe body does not contain a topic reference; Hack-style pipes must use topic at least once.`,PipeUnparenthesizedBody:({type:e})=>`Hack-style pipe body cannot be an unparenthesized ${_N({type:e})}; please wrap it in parentheses.`};function CN(e,t,n){Object.defineProperty(e,t,{enumerable:!1,configurable:!0,value:n})}function wN({toMessage:e,code:t,reasonCode:n,syntaxPlugin:r}){let i=n===`MissingPlugin`||n===`MissingOneOfPlugins`;return function a(o,s){let c=SyntaxError();return c.code=t,c.reasonCode=n,c.loc=o,c.pos=o.index,c.syntaxPlugin=r,i&&(c.missingPlugin=s.missingPlugin),CN(c,`clone`,function(e={}){let{line:t,column:n,index:r}=e.loc??o;return a(new dN(t,n,r),{...s,...e.details})}),CN(c,`details`,s),Object.defineProperty(c,`message`,{configurable:!0,get(){let t=`${e(s)} (${o.line}:${o.column})`;return this.message=t,t},set(e){Object.defineProperty(this,`message`,{value:e,writable:!0})}}),c}}function TN(e,t){if(Array.isArray(e))return t=>TN(t,e[0]);let n={};for(let r of Object.keys(e)){let i=e[r],{message:a,...o}=typeof i==`string`?{message:()=>i}:typeof i==`function`?{message:i}:i;n[r]=wN({code:`BABEL_PARSER_SYNTAX_ERROR`,reasonCode:r,toMessage:typeof a==`string`?()=>a:a,...t?{syntaxPlugin:t}:{},...o})}return n}const G={...TN(hN),...TN(vN),...TN(yN),...TN(bN),...TN`pipelineOperator`(SN)};function EN(){return{sourceType:`script`,sourceFilename:void 0,startIndex:0,startColumn:0,startLine:1,allowAwaitOutsideFunction:!1,allowReturnOutsideFunction:!1,allowNewTargetOutsideFunction:!1,allowImportExportEverywhere:!1,allowSuperOutsideMethod:!1,allowUndeclaredExports:!1,allowYieldOutsideFunction:!1,plugins:[],strictMode:void 0,ranges:!1,tokens:!1,createImportExpressions:!0,createParenthesizedExpressions:!1,errorRecovery:!1,attachComment:!0,annexB:!0}}function DN(e){let t=EN();if(e==null)return t;if(e.annexB!=null&&e.annexB!==!1)throw Error("The `annexB` option can only be set to `false`.");for(let n of Object.keys(t))e[n]!=null&&(t[n]=e[n]);if(t.startLine===1)e.startIndex==null&&t.startColumn>0?t.startIndex=t.startColumn:e.startColumn==null&&t.startIndex>0&&(t.startColumn=t.startIndex);else if(e.startColumn==null||e.startIndex==null)throw Error("With a `startLine > 1` you must also specify `startIndex` and `startColumn`.");if(t.sourceType===`commonjs`){if(e.allowAwaitOutsideFunction!=null)throw Error("The `allowAwaitOutsideFunction` option cannot be used with `sourceType: 'commonjs'`.");if(e.allowReturnOutsideFunction!=null)throw Error("`sourceType: 'commonjs'` implies `allowReturnOutsideFunction: true`, please remove the `allowReturnOutsideFunction` option or use `sourceType: 'script'`.");if(e.allowNewTargetOutsideFunction!=null)throw Error("`sourceType: 'commonjs'` implies `allowNewTargetOutsideFunction: true`, please remove the `allowNewTargetOutsideFunction` option or use `sourceType: 'script'`.")}return t}const{defineProperty:ON}=Object,kN=(e,t)=>{e&&ON(e,t,{enumerable:!1,value:e[t]})};function AN(e){return kN(e.loc.start,`index`),kN(e.loc.end,`index`),e}var jN=e=>class extends e{parse(){let e=AN(super.parse());return this.optionFlags&256&&(e.tokens=e.tokens.map(AN)),e}parseRegExpLiteral({pattern:e,flags:t}){let n=null;try{n=new RegExp(e,t)}catch{}let r=this.estreeParseLiteral(n);return r.regex={pattern:e,flags:t},r}parseBigIntLiteral(e){let t;try{t=BigInt(e)}catch{t=null}let n=this.estreeParseLiteral(t);return n.bigint=String(n.value||e),n}estreeParseLiteral(e){return this.parseLiteral(e,`Literal`)}parseStringLiteral(e){return this.estreeParseLiteral(e)}parseNumericLiteral(e){return this.estreeParseLiteral(e)}parseNullLiteral(){return this.estreeParseLiteral(null)}parseBooleanLiteral(e){return this.estreeParseLiteral(e)}estreeParseChainExpression(e,t){let n=this.startNodeAtNode(e);return n.expression=e,this.finishNodeAt(n,`ChainExpression`,t)}directiveToStmt(e){let t=e.value;delete e.value,this.castNodeTo(t,`Literal`),t.raw=t.extra.raw,t.value=t.extra.expressionValue;let n=this.castNodeTo(e,`ExpressionStatement`);return n.expression=t,n.directive=t.extra.rawValue,delete t.extra,n}fillOptionalPropertiesForTSESLint(e){}cloneEstreeStringLiteral(e){let{start:t,end:n,loc:r,range:i,raw:a,value:o}=e,s=Object.create(e.constructor.prototype);return s.type=`Literal`,s.start=t,s.end=n,s.loc=r,s.range=i,s.raw=a,s.value=o,s}initFunction(e,t){super.initFunction(e,t),e.expression=!1}checkDeclaration(e){e!=null&&this.isObjectProperty(e)?this.checkDeclaration(e.value):super.checkDeclaration(e)}getObjectOrClassMethodParams(e){return e.value.params}isValidDirective(e){return e.type===`ExpressionStatement`&&e.expression.type===`Literal`&&typeof e.expression.value==`string`&&!e.expression.extra?.parenthesized}parseBlockBody(e,t,n,r,i){super.parseBlockBody(e,t,n,r,i),e.body=e.directives.map(e=>this.directiveToStmt(e)).concat(e.body),delete e.directives}parsePrivateName(){let e=super.parsePrivateName();return this.convertPrivateNameToPrivateIdentifier(e)}convertPrivateNameToPrivateIdentifier(e){let t=super.getPrivateNameSV(e);return delete e.id,e.name=t,this.castNodeTo(e,`PrivateIdentifier`)}isPrivateName(e){return e.type===`PrivateIdentifier`}getPrivateNameSV(e){return e.name}parseLiteral(e,t){let n=super.parseLiteral(e,t);return n.raw=n.extra.raw,delete n.extra,n}parseFunctionBody(e,t,n=!1){super.parseFunctionBody(e,t,n),e.expression=e.body.type!==`BlockStatement`}parseMethod(e,t,n,r,i,a,o=!1){let s=this.startNode();s.kind=e.kind,s=super.parseMethod(s,t,n,r,i,a,o),delete s.kind;let{typeParameters:c}=e;return c&&(delete e.typeParameters,s.typeParameters=c,this.resetStartLocationFromNode(s,c)),e.value=this.castNodeTo(s,this.hasPlugin(`typescript`)&&!s.body?`TSEmptyBodyFunctionExpression`:`FunctionExpression`),a===`ClassPrivateMethod`&&(e.computed=!1),this.hasPlugin(`typescript`)&&e.abstract?(delete e.abstract,this.finishNode(e,`TSAbstractMethodDefinition`)):a===`ObjectMethod`?(e.kind===`method`&&(e.kind=`init`),e.shorthand=!1,this.finishNode(e,`Property`)):this.finishNode(e,`MethodDefinition`)}nameIsConstructor(e){return e.type===`Literal`?e.value===`constructor`:super.nameIsConstructor(e)}parseClassProperty(...e){let t=super.parseClassProperty(...e);return t.abstract&&this.hasPlugin(`typescript`)?(delete t.abstract,this.castNodeTo(t,`TSAbstractPropertyDefinition`)):this.castNodeTo(t,`PropertyDefinition`),t}parseClassPrivateProperty(...e){let t=super.parseClassPrivateProperty(...e);return t.abstract&&this.hasPlugin(`typescript`)?this.castNodeTo(t,`TSAbstractPropertyDefinition`):this.castNodeTo(t,`PropertyDefinition`),t.computed=!1,t}parseClassAccessorProperty(e){let t=super.parseClassAccessorProperty(e);return t.abstract&&this.hasPlugin(`typescript`)?(delete t.abstract,this.castNodeTo(t,`TSAbstractAccessorProperty`)):this.castNodeTo(t,`AccessorProperty`),t}parseObjectProperty(e,t,n,r){let i=super.parseObjectProperty(e,t,n,r);return i&&(i.kind=`init`,this.castNodeTo(i,`Property`)),i}finishObjectProperty(e){return e.kind=`init`,this.finishNode(e,`Property`)}isValidLVal(e,t,n,r){return e===`Property`?`value`:super.isValidLVal(e,t,n,r)}isAssignable(e,t){return e!=null&&this.isObjectProperty(e)?this.isAssignable(e.value,t):super.isAssignable(e,t)}toAssignable(e,t=!1){if(e!=null&&this.isObjectProperty(e)){let{key:n,value:r}=e;this.isPrivateName(n)&&this.classScope.usePrivateName(this.getPrivateNameSV(n),n.loc.start),this.toAssignable(r,t)}else super.toAssignable(e,t)}toAssignableObjectExpressionProp(e,t,n){e.type===`Property`&&(e.kind===`get`||e.kind===`set`)?this.raise(G.PatternHasAccessor,e.key):e.type===`Property`&&e.method?this.raise(G.PatternHasMethod,e.key):super.toAssignableObjectExpressionProp(e,t,n)}finishCallExpression(e,t){let n=super.finishCallExpression(e,t);return n.callee.type===`Import`?(this.castNodeTo(n,`ImportExpression`),n.source=n.arguments[0],n.options=n.arguments[1]??null,delete n.arguments,delete n.callee):n.type===`OptionalCallExpression`?this.castNodeTo(n,`CallExpression`):n.optional=!1,n}toReferencedArguments(e){e.type!==`ImportExpression`&&super.toReferencedArguments(e)}parseExport(e,t){let n=this.state.lastTokStartLoc,r=super.parseExport(e,t);switch(r.type){case`ExportAllDeclaration`:r.exported=null;break;case`ExportNamedDeclaration`:r.specifiers.length===1&&r.specifiers[0].type===`ExportNamespaceSpecifier`&&(this.castNodeTo(r,`ExportAllDeclaration`),r.exported=r.specifiers[0].exported,delete r.specifiers);case`ExportDefaultDeclaration`:{let{declaration:e}=r;e?.type===`ClassDeclaration`&&e.decorators?.length>0&&e.start===r.start&&this.resetStartLocation(r,n)}break}return r}stopParseSubscript(e,t){let n=super.stopParseSubscript(e,t);return t.optionalChainMember?this.estreeParseChainExpression(n,e.loc.end):n}parseMember(e,t,n,r,i){let a=super.parseMember(e,t,n,r,i);return a.type===`OptionalMemberExpression`?this.castNodeTo(a,`MemberExpression`):a.optional=!1,a}isOptionalMemberExpression(e){return e.type===`ChainExpression`?e.expression.type===`MemberExpression`:super.isOptionalMemberExpression(e)}hasPropertyAsPrivateName(e){return e.type===`ChainExpression`&&(e=e.expression),super.hasPropertyAsPrivateName(e)}isObjectProperty(e){return e.type===`Property`&&e.kind===`init`&&!e.method}isObjectMethod(e){return e.type===`Property`&&(e.method||e.kind===`get`||e.kind===`set`)}castNodeTo(e,t){let n=super.castNodeTo(e,t);return this.fillOptionalPropertiesForTSESLint(n),n}cloneIdentifier(e){let t=super.cloneIdentifier(e);return this.fillOptionalPropertiesForTSESLint(t),t}cloneStringLiteral(e){return e.type===`Literal`?this.cloneEstreeStringLiteral(e):super.cloneStringLiteral(e)}finishNodeAt(e,t,n){return AN(super.finishNodeAt(e,t,n))}finishNode(e,t){let n=super.finishNode(e,t);return this.fillOptionalPropertiesForTSESLint(n),n}resetStartLocation(e,t){super.resetStartLocation(e,t),AN(e)}resetEndLocation(e,t=this.state.lastTokEndLoc){super.resetEndLocation(e,t),AN(e)}},MN=class{label;keyword;beforeExpr;startsExpr;rightAssociative;isLoop;isAssign;prefix;postfix;binop;constructor(e,t={}){this.label=e,this.keyword=t.keyword,this.beforeExpr=!!t.beforeExpr,this.startsExpr=!!t.startsExpr,this.rightAssociative=!!t.rightAssociative,this.isLoop=!!t.isLoop,this.isAssign=!!t.isAssign,this.prefix=!!t.prefix,this.postfix=!!t.postfix,this.binop=t.binop==null?null:t.binop}};const NN=new Map;function K(e,t={}){t.keyword=e;let n=q(e,t);return NN.set(e,n),n}function PN(e,t){return q(e,{beforeExpr:!0,binop:t})}let FN=-1;const IN=[],LN=[],RN=[],zN=[],BN=[],VN=[];function q(e,t={}){return++FN,LN.push(e),RN.push(t.binop??-1),zN.push(t.beforeExpr??!1),BN.push(t.startsExpr??!1),VN.push(t.prefix??!1),IN.push(new MN(e,t)),FN}function J(e,t={}){return++FN,NN.set(e,FN),LN.push(e),RN.push(t.binop??-1),zN.push(t.beforeExpr??!1),BN.push(t.startsExpr??!1),VN.push(t.prefix??!1),IN.push(new MN(`name`,t)),FN}const HN={bracketL:q(`[`,{beforeExpr:!0,startsExpr:!0}),bracketR:q(`]`),braceL:q(`{`,{beforeExpr:!0,startsExpr:!0}),braceBarL:q(`{|`,{beforeExpr:!0,startsExpr:!0}),braceR:q(`}`),braceBarR:q(`|}`),parenL:q(`(`,{beforeExpr:!0,startsExpr:!0}),parenR:q(`)`),comma:q(`,`,{beforeExpr:!0}),semi:q(`;`,{beforeExpr:!0}),colon:q(`:`,{beforeExpr:!0}),doubleColon:q(`::`,{beforeExpr:!0}),dot:q(`.`),question:q(`?`,{beforeExpr:!0}),questionDot:q(`?.`),arrow:q(`=>`,{beforeExpr:!0}),template:q(`template`),ellipsis:q(`...`,{beforeExpr:!0}),backQuote:q("`",{startsExpr:!0}),dollarBraceL:q("${",{beforeExpr:!0,startsExpr:!0}),templateTail:q("...`",{startsExpr:!0}),templateNonTail:q("...${",{beforeExpr:!0,startsExpr:!0}),at:q(`@`),hash:q(`#`,{startsExpr:!0}),interpreterDirective:q(`#!...`),eq:q(`=`,{beforeExpr:!0,isAssign:!0}),assign:q(`_=`,{beforeExpr:!0,isAssign:!0}),slashAssign:q(`_=`,{beforeExpr:!0,isAssign:!0}),xorAssign:q(`_=`,{beforeExpr:!0,isAssign:!0}),moduloAssign:q(`_=`,{beforeExpr:!0,isAssign:!0}),incDec:q(`++/--`,{prefix:!0,postfix:!0,startsExpr:!0}),bang:q(`!`,{beforeExpr:!0,prefix:!0,startsExpr:!0}),tilde:q(`~`,{beforeExpr:!0,prefix:!0,startsExpr:!0}),doubleCaret:q(`^^`,{startsExpr:!0}),doubleAt:q(`@@`,{startsExpr:!0}),pipeline:PN(`|>`,0),nullishCoalescing:PN(`??`,1),logicalOR:PN(`||`,1),logicalAND:PN(`&&`,2),bitwiseOR:PN(`|`,3),bitwiseXOR:PN(`^`,4),bitwiseAND:PN(`&`,5),equality:PN(`==/!=/===/!==`,6),lt:PN(`</>/<=/>=`,7),gt:PN(`</>/<=/>=`,7),relational:PN(`</>/<=/>=`,7),bitShift:PN(`<</>>/>>>`,8),bitShiftL:PN(`<</>>/>>>`,8),bitShiftR:PN(`<</>>/>>>`,8),plusMin:q(`+/-`,{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:q(`%`,{binop:10,startsExpr:!0}),star:q(`*`,{binop:10}),slash:PN(`/`,10),exponent:q(`**`,{beforeExpr:!0,binop:11,rightAssociative:!0}),_in:K(`in`,{beforeExpr:!0,binop:7}),_instanceof:K(`instanceof`,{beforeExpr:!0,binop:7}),_break:K(`break`),_case:K(`case`,{beforeExpr:!0}),_catch:K(`catch`),_continue:K(`continue`),_debugger:K(`debugger`),_default:K(`default`,{beforeExpr:!0}),_else:K(`else`,{beforeExpr:!0}),_finally:K(`finally`),_function:K(`function`,{startsExpr:!0}),_if:K(`if`),_return:K(`return`,{beforeExpr:!0}),_switch:K(`switch`),_throw:K(`throw`,{beforeExpr:!0,prefix:!0,startsExpr:!0}),_try:K(`try`),_var:K(`var`),_const:K(`const`),_with:K(`with`),_new:K(`new`,{beforeExpr:!0,startsExpr:!0}),_this:K(`this`,{startsExpr:!0}),_super:K(`super`,{startsExpr:!0}),_class:K(`class`,{startsExpr:!0}),_extends:K(`extends`,{beforeExpr:!0}),_export:K(`export`),_import:K(`import`,{startsExpr:!0}),_null:K(`null`,{startsExpr:!0}),_true:K(`true`,{startsExpr:!0}),_false:K(`false`,{startsExpr:!0}),_typeof:K(`typeof`,{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:K(`void`,{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:K(`delete`,{beforeExpr:!0,prefix:!0,startsExpr:!0}),_do:K(`do`,{isLoop:!0,beforeExpr:!0}),_for:K(`for`,{isLoop:!0}),_while:K(`while`,{isLoop:!0}),_as:J(`as`,{startsExpr:!0}),_assert:J(`assert`,{startsExpr:!0}),_async:J(`async`,{startsExpr:!0}),_await:J(`await`,{startsExpr:!0}),_defer:J(`defer`,{startsExpr:!0}),_from:J(`from`,{startsExpr:!0}),_get:J(`get`,{startsExpr:!0}),_let:J(`let`,{startsExpr:!0}),_meta:J(`meta`,{startsExpr:!0}),_of:J(`of`,{startsExpr:!0}),_sent:J(`sent`,{startsExpr:!0}),_set:J(`set`,{startsExpr:!0}),_source:J(`source`,{startsExpr:!0}),_static:J(`static`,{startsExpr:!0}),_using:J(`using`,{startsExpr:!0}),_yield:J(`yield`,{startsExpr:!0}),_asserts:J(`asserts`,{startsExpr:!0}),_checks:J(`checks`,{startsExpr:!0}),_exports:J(`exports`,{startsExpr:!0}),_global:J(`global`,{startsExpr:!0}),_implements:J(`implements`,{startsExpr:!0}),_intrinsic:J(`intrinsic`,{startsExpr:!0}),_infer:J(`infer`,{startsExpr:!0}),_is:J(`is`,{startsExpr:!0}),_mixins:J(`mixins`,{startsExpr:!0}),_proto:J(`proto`,{startsExpr:!0}),_require:J(`require`,{startsExpr:!0}),_satisfies:J(`satisfies`,{startsExpr:!0}),_keyof:J(`keyof`,{startsExpr:!0}),_readonly:J(`readonly`,{startsExpr:!0}),_unique:J(`unique`,{startsExpr:!0}),_abstract:J(`abstract`,{startsExpr:!0}),_declare:J(`declare`,{startsExpr:!0}),_enum:J(`enum`,{startsExpr:!0}),_module:J(`module`,{startsExpr:!0}),_namespace:J(`namespace`,{startsExpr:!0}),_interface:J(`interface`,{startsExpr:!0}),_type:J(`type`,{startsExpr:!0}),_opaque:J(`opaque`,{startsExpr:!0}),name:q(`name`,{startsExpr:!0}),placeholder:q(`%%`,{startsExpr:!0}),string:q(`string`,{startsExpr:!0}),num:q(`num`,{startsExpr:!0}),bigint:q(`bigint`,{startsExpr:!0}),regexp:q(`regexp`,{startsExpr:!0}),privateName:q(`#name`,{startsExpr:!0}),eof:q(`eof`),jsxName:q(`jsxName`),jsxText:q(`jsxText`,{beforeExpr:!0}),jsxTagStart:q(`jsxTagStart`,{startsExpr:!0}),jsxTagEnd:q(`jsxTagEnd`)};function Y(e){return e>=89&&e<=129}function UN(e){return e<=88}function WN(e){return e>=54&&e<=129}function GN(e){return e>=54&&e<=132}function KN(e){return zN[e]}function qN(e){return BN[e]}function JN(e){return e>=25&&e<=29}function YN(e){return e>=125&&e<=127}function XN(e){return e>=86&&e<=88}function ZN(e){return e>=54&&e<=88}function QN(e){return e>=35&&e<=55}function $N(e){return e===30}function eP(e){return VN[e]}function tP(e){return e>=117&&e<=119}function nP(e){return e>=120&&e<=126}function rP(e){return LN[e]}function iP(e){return RN[e]}function aP(e){return e===53}function oP(e){return e>=20&&e<=21}function sP(e){return IN[e]}var cP=class{constructor(e,t){this.token=e,this.preserveSpace=!!t}token;preserveSpace};const X={brace:new cP(`{`),j_oTag:new cP(`<tag`),j_cTag:new cP(`</tag`),j_expr:new cP(`<tag>...</tag>`,!0)};let lP=`ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽ-ೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-Ა-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ--ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ`,uP=`·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ--ᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・`;const dP=RegExp(`[`+lP+`]`),fP=RegExp(`[`+lP+uP+`]`);lP=uP=null;const pP=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,4,51,13,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,7,25,39,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,39,27,10,22,251,41,7,1,17,5,57,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,20,1,64,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,31,9,2,0,3,0,2,37,2,0,26,0,2,0,45,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,200,32,32,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,24,43,261,18,16,0,2,12,2,33,125,0,80,921,103,110,18,195,2637,96,16,1071,18,5,26,3994,6,582,6842,29,1763,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,433,44,212,63,33,24,3,24,45,74,6,0,67,12,65,1,2,0,15,4,10,7381,42,31,98,114,8702,3,2,6,2,1,2,290,16,0,30,2,3,0,15,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,7,5,262,61,147,44,11,6,17,0,322,29,19,43,485,27,229,29,3,0,208,30,2,2,2,1,2,6,3,4,10,1,225,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4381,3,5773,3,7472,16,621,2467,541,1507,4938,6,8489],mP=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,7,9,32,4,318,1,78,5,71,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,3,0,158,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,68,8,2,0,3,0,2,3,2,4,2,0,15,1,83,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,7,19,58,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,199,7,137,9,54,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,55,9,266,3,10,1,2,0,49,6,4,4,14,10,5350,0,7,14,11465,27,2343,9,87,9,39,4,60,6,26,9,535,9,470,0,2,54,8,3,82,0,12,1,19628,1,4178,9,519,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,101,0,161,6,10,9,357,0,62,13,499,13,245,1,2,9,233,0,3,0,8,1,6,0,475,6,110,6,6,9,4759,9,787719,239];function hP(e,t){let n=65536;for(let r=0,i=t.length;r<i;r+=2){if(n+=t[r],n>e)return!1;if(n+=t[r+1],n>=e)return!0}return!1}function gP(e){return e<65?e===36:e<=90?!0:e<97?e===95:e<=122?!0:e<=65535?e>=170&&dP.test(String.fromCharCode(e)):hP(e,pP)}function _P(e){return e<48?e===36:e<58?!0:e<65?!1:e<=90?!0:e<97?e===95:e<=122?!0:e<=65535?e>=170&&fP.test(String.fromCharCode(e)):hP(e,pP)||hP(e,mP)}const vP={keyword:`break.case.catch.continue.debugger.default.do.else.finally.for.function.if.return.switch.throw.try.var.const.while.with.new.this.super.class.extends.export.import.null.true.false.in.instanceof.typeof.void.delete`.split(`.`),strict:[`implements`,`interface`,`let`,`package`,`private`,`protected`,`public`,`static`,`yield`],strictBind:[`eval`,`arguments`]},yP=new Set(vP.keyword),bP=new Set(vP.strict),xP=new Set(vP.strictBind);function SP(e,t){return t&&e===`await`||e===`enum`}function CP(e,t){return SP(e,t)||bP.has(e)}function wP(e){return xP.has(e)}function TP(e,t){return CP(e,t)||wP(e)}function EP(e){return yP.has(e)}function DP(e,t,n){return e===64&&t===64&&gP(n)}const OP=new Set(`break.case.catch.continue.debugger.default.do.else.finally.for.function.if.return.switch.throw.try.var.const.while.with.new.this.super.class.extends.export.import.null.true.false.in.instanceof.typeof.void.delete.implements.interface.let.package.private.protected.public.static.yield.eval.arguments.enum.await`.split(`.`));function kP(e){return OP.has(e)}var AP=class{flags=0;names=new Map;firstLexicalName=``;constructor(e){this.flags=e}},jP=class{parser;scopeStack=[];inModule;undefinedExports=new Map;constructor(e,t){this.parser=e,this.inModule=t}get inTopLevel(){return(this.currentScope().flags&1)>0}get inFunction(){return(this.currentVarScopeFlags()&2)>0}get allowSuper(){return(this.currentThisScopeFlags()&16)>0}get allowDirectSuper(){return(this.currentThisScopeFlags()&32)>0}get allowNewTarget(){return(this.currentThisScopeFlags()&512)>0}get inClass(){return(this.currentThisScopeFlags()&64)>0}get inClassAndNotInNonArrowFunction(){let e=this.currentThisScopeFlags();return(e&64)>0&&(e&2)==0}get inStaticBlock(){for(let e=this.scopeStack.length-1;;e--){let{flags:t}=this.scopeStack[e];if(t&128)return!0;if(t&1731)return!1}}get inNonArrowFunction(){return(this.currentThisScopeFlags()&2)>0}get inBareCaseStatement(){return(this.currentScope().flags&256)>0}get treatFunctionsAsVar(){return this.treatFunctionsAsVarInScope(this.currentScope())}createScope(e){return new AP(e)}enter(e){this.scopeStack.push(this.createScope(e))}exit(){return this.scopeStack.pop().flags}treatFunctionsAsVarInScope(e){return!!(e.flags&130||!this.parser.inModule&&e.flags&1)}declareName(e,t,n){let r=this.currentScope();if(t&8||t&16){this.checkRedeclarationInScope(r,e,t,n);let i=r.names.get(e)||0;t&16?i|=4:(r.firstLexicalName||=e,i|=2),r.names.set(e,i),t&8&&this.maybeExportDefined(r,e)}else if(t&4)for(let i=this.scopeStack.length-1;i>=0&&(r=this.scopeStack[i],this.checkRedeclarationInScope(r,e,t,n),r.names.set(e,(r.names.get(e)||0)|1),this.maybeExportDefined(r,e),!(r.flags&1667));--i);this.parser.inModule&&r.flags&1&&this.undefinedExports.delete(e)}maybeExportDefined(e,t){this.parser.inModule&&e.flags&1&&this.undefinedExports.delete(t)}checkRedeclarationInScope(e,t,n,r){this.isRedeclaredInScope(e,t,n)&&this.parser.raise(G.VarRedeclaration,r,{identifierName:t})}isRedeclaredInScope(e,t,n){if(!(n&1))return!1;if(n&8)return e.names.has(t);let r=e.names.get(t)||0;return n&16?(r&2)>0||!this.treatFunctionsAsVarInScope(e)&&(r&1)>0:(r&2)>0&&!(e.flags&8&&e.firstLexicalName===t)||!this.treatFunctionsAsVarInScope(e)&&(r&4)>0}checkLocalExport(e){let{name:t}=e;this.scopeStack[0].names.has(t)||this.undefinedExports.set(t,e.loc.start)}currentScope(){return this.scopeStack[this.scopeStack.length-1]}currentVarScopeFlags(){for(let e=this.scopeStack.length-1;;e--){let{flags:t}=this.scopeStack[e];if(t&1667)return t}}currentThisScopeFlags(){for(let e=this.scopeStack.length-1;;e--){let{flags:t}=this.scopeStack[e];if(t&1731&&!(t&4))return t}}},MP=class extends AP{declareFunctions=new Set},NP=class extends jP{createScope(e){return new MP(e)}declareName(e,t,n){let r=this.currentScope();if(t&2048){this.checkRedeclarationInScope(r,e,t,n),this.maybeExportDefined(r,e),r.declareFunctions.add(e);return}super.declareName(e,t,n)}isRedeclaredInScope(e,t,n){if(super.isRedeclaredInScope(e,t,n))return!0;if(n&2048&&!e.declareFunctions.has(t)){let n=e.names.get(t);return(n&4)>0||(n&2)>0}return!1}checkLocalExport(e){this.scopeStack[0].declareFunctions.has(e.name)||super.checkLocalExport(e)}};const PP=new Set([`_`,`any`,`bool`,`boolean`,`empty`,`extends`,`false`,`interface`,`mixed`,`null`,`number`,`static`,`string`,`true`,`typeof`,`void`]),Z=TN`flow`({AmbiguousConditionalArrow:`Ambiguous expression: wrap the arrow functions in parentheses to disambiguate.`,AmbiguousDeclareModuleKind:"Found both `declare module.exports` and `declare export` in the same module. Modules can only have 1 since they are either an ES module or they are a CommonJS module.",AssignReservedType:({reservedType:e})=>`Cannot overwrite reserved type ${e}.`,DeclareClassElement:"The `declare` modifier can only appear on class fields.",DeclareClassFieldInitializer:"Initializers are not allowed in fields with the `declare` modifier.",DuplicateDeclareModuleExports:"Duplicate `declare module.exports` statement.",EnumBooleanMemberNotInitialized:({memberName:e,enumName:t})=>`Boolean enum members need to be initialized. Use either \`${e} = true,\` or \`${e} = false,\` in enum \`${t}\`.`,EnumDuplicateMemberName:({memberName:e,enumName:t})=>`Enum member names need to be unique, but the name \`${e}\` has already been used before in enum \`${t}\`.`,EnumInconsistentMemberValues:({enumName:e})=>`Enum \`${e}\` has inconsistent member initializers. Either use no initializers, or consistently use literals (either booleans, numbers, or strings) for all member initializers.`,EnumInvalidExplicitType:({invalidEnumType:e,enumName:t})=>`Enum type \`${e}\` is not valid. Use one of \`boolean\`, \`number\`, \`string\`, or \`symbol\` in enum \`${t}\`.`,EnumInvalidExplicitTypeUnknownSupplied:({enumName:e})=>`Supplied enum type is not valid. Use one of \`boolean\`, \`number\`, \`string\`, or \`symbol\` in enum \`${e}\`.`,EnumInvalidMemberInitializerPrimaryType:({enumName:e,memberName:t,explicitType:n})=>`Enum \`${e}\` has type \`${n}\`, so the initializer of \`${t}\` needs to be a ${n} literal.`,EnumInvalidMemberInitializerSymbolType:({enumName:e,memberName:t})=>`Symbol enum members cannot be initialized. Use \`${t},\` in enum \`${e}\`.`,EnumInvalidMemberInitializerUnknownType:({enumName:e,memberName:t})=>`The enum member initializer for \`${t}\` needs to be a literal (either a boolean, number, or string) in enum \`${e}\`.`,EnumInvalidMemberName:({enumName:e,memberName:t,suggestion:n})=>`Enum member names cannot start with lowercase 'a' through 'z'. Instead of using \`${t}\`, consider using \`${n}\`, in enum \`${e}\`.`,EnumNumberMemberNotInitialized:({enumName:e,memberName:t})=>`Number enum members need to be initialized, e.g. \`${t} = 1\` in enum \`${e}\`.`,EnumStringMemberInconsistentlyInitialized:({enumName:e})=>`String enum members need to consistently either all use initializers, or use no initializers, in enum \`${e}\`.`,GetterMayNotHaveThisParam:"A getter cannot have a `this` parameter.",ImportTypeShorthandOnlyInPureImport:"The `type` and `typeof` keywords on named imports can only be used on regular `import` statements. It cannot be used with `import type` or `import typeof` statements.",InexactInsideExact:`Explicit inexact syntax cannot appear inside an explicit exact object type.`,InexactInsideNonObject:`Explicit inexact syntax cannot appear in class or interface definitions.`,InexactVariance:`Explicit inexact syntax cannot have variance.`,InvalidNonTypeImportInDeclareModule:"Imports within a `declare module` body must always be `import type` or `import typeof`.",MissingTypeParamDefault:`Type parameter declaration needs a default, since a preceding type parameter declaration has a default.`,NestedDeclareModule:"`declare module` cannot be used inside another `declare module`.",NestedFlowComment:`Cannot have a flow comment inside another flow comment.`,PatternIsOptional:{message:`A binding pattern parameter cannot be optional in an implementation signature.`},SetterMayNotHaveThisParam:"A setter cannot have a `this` parameter.",SpreadVariance:`Spread properties cannot have variance.`,ThisParamAnnotationRequired:"A type annotation is required for the `this` parameter.",ThisParamBannedInConstructor:"Constructors cannot have a `this` parameter; constructors don't bind `this` like other functions.",ThisParamMayNotBeOptional:"The `this` parameter cannot be optional.",ThisParamMustBeFirst:"The `this` parameter must be the first function parameter.",ThisParamNoDefault:"The `this` parameter may not have a default value.",TypeBeforeInitializer:"Type annotations must come before default assignments, e.g. instead of `age = 25: number` use `age: number = 25`.",TypeCastInPattern:`The type cast expression is expected to be wrapped with parenthesis.`,UnexpectedExplicitInexactInObject:`Explicit inexact syntax must appear at the end of an inexact object.`,UnexpectedReservedType:({reservedType:e})=>`Unexpected reserved type ${e}.`,UnexpectedReservedUnderscore:"`_` is only allowed as a type argument to call or new.",UnexpectedSpaceBetweenModuloChecks:"Spaces between `%` and `checks` are not allowed here.",UnexpectedSpreadType:`Spread operator cannot appear in class or interface definitions.`,UnexpectedSubtractionOperand:`Unexpected token, expected "number" or "bigint".`,UnexpectedTokenAfterTypeParameter:`Expected an arrow function after this type parameter declaration.`,UnexpectedTypeParameterBeforeAsyncArrowFunction:"Type parameters must come after the async keyword, e.g. instead of `<T> async () => {}`, use `async <T>() => {}`.",UnsupportedDeclareExportKind:({unsupportedExportKind:e,suggestion:t})=>`\`declare export ${e}\` is not supported. Use \`${t}\` instead.`,UnsupportedStatementInDeclareModule:`Only declares and type imports are allowed inside declare module.`,UnterminatedFlowComment:`Unterminated flow-comment.`});function FP(e){return e.type===`DeclareExportAllDeclaration`||e.type===`DeclareExportDeclaration`&&(!e.declaration||e.declaration.type!==`TypeAlias`&&e.declaration.type!==`InterfaceDeclaration`)}function IP(e){return e.importKind===`type`||e.importKind===`typeof`}const LP={const:`declare export var`,let:`declare export var`,type:`export type`,interface:`export interface`};function RP(e,t){let n=[],r=[];for(let i=0;i<e.length;i++)(t(e[i],i,e)?n:r).push(e[i]);return[n,r]}const zP=/\*?\s*@((?:no)?flow)\b/;var BP=e=>class extends e{flowPragma=void 0;getScopeHandler(){return NP}shouldParseTypes(){return this.getPluginOption(`flow`,`all`)||this.flowPragma===`flow`}finishToken(e,t){e!==130&&e!==9&&e!==24&&this.flowPragma===void 0&&(this.flowPragma=null),super.finishToken(e,t)}addComment(e){if(this.flowPragma===void 0){let t=zP.exec(e.value);if(t)if(t[1]===`flow`)this.flowPragma=`flow`;else if(t[1]===`noflow`)this.flowPragma=`noflow`;else throw Error(`Unexpected flow pragma`)}super.addComment(e)}flowParseTypeInitialiser(e){let t=this.state.inType;this.state.inType=!0,this.expect(e||10);let n=this.flowParseType();return this.state.inType=t,n}flowParsePredicate(){let e=this.startNode(),t=this.state.startLoc;return this.next(),this.expectContextual(106),this.state.lastTokStartLoc.index>t.index+1&&this.raise(Z.UnexpectedSpaceBetweenModuloChecks,t),this.eat(6)?(e.value=super.parseExpression(),this.expect(7),this.finishNode(e,`DeclaredPredicate`)):this.finishNode(e,`InferredPredicate`)}flowParseTypeAndPredicateInitialiser(){let e=this.state.inType;this.state.inType=!0,this.expect(10);let t=null,n=null;return this.match(50)?(this.state.inType=e,n=this.flowParsePredicate()):(t=this.flowParseType(),this.state.inType=e,this.match(50)&&(n=this.flowParsePredicate())),[t,n]}flowParseDeclareClass(e){return this.next(),this.flowParseInterfaceish(e,!0),this.finishNode(e,`DeclareClass`)}flowParseDeclareFunction(e){this.next();let t=e.id=this.parseIdentifier(),n=this.startNode(),r=this.startNode();this.match(43)?n.typeParameters=this.flowParseTypeParameterDeclaration():n.typeParameters=null,this.expect(6);let i=this.flowParseFunctionTypeParams();return n.params=i.params,n.rest=i.rest,n.this=i._this,this.expect(7),[n.returnType,e.predicate]=this.flowParseTypeAndPredicateInitialiser(),r.typeAnnotation=this.finishNode(n,`FunctionTypeAnnotation`),t.typeAnnotation=this.finishNode(r,`TypeAnnotation`),this.resetEndLocation(t),this.semicolon(),this.scope.declareName(e.id.name,2048,e.id.loc.start),this.finishNode(e,`DeclareFunction`)}flowParseDeclare(e,t){if(this.match(76))return this.flowParseDeclareClass(e);if(this.match(64))return this.flowParseDeclareFunction(e);if(this.match(70))return this.flowParseDeclareVariable(e);if(this.eatContextual(123))return this.match(12)?this.flowParseDeclareModuleExports(e):(t&&this.raise(Z.NestedDeclareModule,this.state.lastTokStartLoc),this.flowParseDeclareModule(e));if(this.isContextual(126))return this.flowParseDeclareTypeAlias(e);if(this.isContextual(127))return this.flowParseDeclareOpaqueType(e);if(this.isContextual(125))return this.flowParseDeclareInterface(e);if(this.match(78))return this.flowParseDeclareExportDeclaration(e,t);throw this.unexpected()}flowParseDeclareVariable(e){return this.next(),e.id=this.flowParseTypeAnnotatableIdentifier(!0),this.scope.declareName(e.id.name,5,e.id.loc.start),this.semicolon(),this.finishNode(e,`DeclareVariable`)}flowParseDeclareModule(e){this.scope.enter(0),this.match(130)?e.id=super.parseExprAtom():e.id=this.parseIdentifier();let t=e.body=this.startNode(),n=t.body=[];for(this.expect(2);!this.match(4);){let e=this.startNode();this.match(79)?(this.next(),!this.isContextual(126)&&!this.match(83)&&this.raise(Z.InvalidNonTypeImportInDeclareModule,this.state.lastTokStartLoc),n.push(super.parseImport(e))):(this.expectContextual(121,Z.UnsupportedStatementInDeclareModule),n.push(this.flowParseDeclare(e,!0)))}this.scope.exit(),this.expect(4),this.finishNode(t,`BlockStatement`);let r=null,i=!1;return n.forEach(e=>{FP(e)?(r===`CommonJS`&&this.raise(Z.AmbiguousDeclareModuleKind,e),r=`ES`):e.type===`DeclareModuleExports`&&(i&&this.raise(Z.DuplicateDeclareModuleExports,e),r===`ES`&&this.raise(Z.AmbiguousDeclareModuleKind,e),r=`CommonJS`,i=!0)}),e.kind=r||`CommonJS`,this.finishNode(e,`DeclareModule`)}flowParseDeclareExportDeclaration(e,t){if(this.expect(78),this.eat(61))return this.match(64)||this.match(76)?e.declaration=this.flowParseDeclare(this.startNode()):(e.declaration=this.flowParseType(),this.semicolon()),e.default=!0,this.finishNode(e,`DeclareExportDeclaration`);if(this.match(71)||this.isLet()||(this.isContextual(126)||this.isContextual(125))&&!t){let e=this.state.value;throw this.raise(Z.UnsupportedDeclareExportKind,this.state.startLoc,{unsupportedExportKind:e,suggestion:LP[e]})}if(this.match(70)||this.match(64)||this.match(76)||this.isContextual(127))return e.declaration=this.flowParseDeclare(this.startNode()),e.default=!1,this.finishNode(e,`DeclareExportDeclaration`);if(this.match(51)||this.match(2)||this.isContextual(125)||this.isContextual(126)||this.isContextual(127))return e=this.parseExport(e,null),e.type===`ExportNamedDeclaration`?(e.default=!1,delete e.exportKind,this.castNodeTo(e,`DeclareExportDeclaration`)):this.castNodeTo(e,`DeclareExportAllDeclaration`);throw this.unexpected()}flowParseDeclareModuleExports(e){return this.next(),this.expectContextual(107),e.typeAnnotation=this.flowParseTypeAnnotation(),this.semicolon(),this.finishNode(e,`DeclareModuleExports`)}flowParseDeclareTypeAlias(e){this.next();let t=this.flowParseTypeAlias(e);return this.castNodeTo(t,`DeclareTypeAlias`),t}flowParseDeclareOpaqueType(e){this.next();let t=this.flowParseOpaqueType(e,!0);return this.castNodeTo(t,`DeclareOpaqueType`),t}flowParseDeclareInterface(e){return this.next(),this.flowParseInterfaceish(e,!1),this.finishNode(e,`DeclareInterface`)}flowParseInterfaceish(e,t){if(e.id=this.flowParseRestrictedIdentifier(!t,!0),this.scope.declareName(e.id.name,t?17:8201,e.id.loc.start),this.match(43)?e.typeParameters=this.flowParseTypeParameterDeclaration():e.typeParameters=null,e.extends=[],this.eat(77))do e.extends.push(this.flowParseInterfaceExtends());while(!t&&this.eat(8));if(t){if(e.implements=[],e.mixins=[],this.eatContextual(113))do e.mixins.push(this.flowParseInterfaceExtends());while(this.eat(8));if(this.eatContextual(109))do e.implements.push(this.flowParseInterfaceExtends());while(this.eat(8))}e.body=this.flowParseObjectType({allowStatic:t,allowExact:!1,allowSpread:!1,allowProto:t,allowInexact:!1})}flowParseInterfaceExtends(){let e=this.startNode();return e.id=this.flowParseQualifiedTypeIdentifier(),this.match(43)?e.typeParameters=this.flowParseTypeParameterInstantiation():e.typeParameters=null,this.finishNode(e,`InterfaceExtends`)}flowParseInterface(e){return this.flowParseInterfaceish(e,!1),this.finishNode(e,`InterfaceDeclaration`)}checkNotUnderscore(e){e===`_`&&this.raise(Z.UnexpectedReservedUnderscore,this.state.startLoc)}checkReservedType(e,t,n){PP.has(e)&&this.raise(n?Z.AssignReservedType:Z.UnexpectedReservedType,t,{reservedType:e})}flowParseRestrictedIdentifier(e,t){return this.checkReservedType(this.state.value,this.state.startLoc,t),this.parseIdentifier(e)}flowParseTypeAlias(e){return e.id=this.flowParseRestrictedIdentifier(!1,!0),this.scope.declareName(e.id.name,8201,e.id.loc.start),this.match(43)?e.typeParameters=this.flowParseTypeParameterDeclaration():e.typeParameters=null,e.right=this.flowParseTypeInitialiser(25),this.semicolon(),this.finishNode(e,`TypeAlias`)}flowParseOpaqueType(e,t){return this.expectContextual(126),e.id=this.flowParseRestrictedIdentifier(!0,!0),this.scope.declareName(e.id.name,8201,e.id.loc.start),this.match(43)?e.typeParameters=this.flowParseTypeParameterDeclaration():e.typeParameters=null,e.supertype=null,this.match(10)&&(e.supertype=this.flowParseTypeInitialiser(10)),e.impltype=null,t||(e.impltype=this.flowParseTypeInitialiser(25)),this.semicolon(),this.finishNode(e,`OpaqueType`)}flowParseTypeParameter(e=!1){let t=this.state.startLoc,n=this.startNode(),r=this.flowParseVariance(),i=this.flowParseTypeAnnotatableIdentifier();return n.name=i.name,n.variance=r,n.bound=i.typeAnnotation,this.match(25)?(this.eat(25),n.default=this.flowParseType()):e&&this.raise(Z.MissingTypeParamDefault,t),this.finishNode(n,`TypeParameter`)}flowParseTypeParameterDeclaration(){let e=this.state.inType,t=this.startNode();t.params=[],this.state.inType=!0,this.match(43)||this.match(138)?this.next():this.unexpected();let n=!1;do{let e=this.flowParseTypeParameter(n);t.params.push(e),e.default&&(n=!0),this.match(44)||this.expect(8)}while(!this.match(44));return this.expect(44),this.state.inType=e,this.finishNode(t,`TypeParameterDeclaration`)}flowInTopLevelContext(e){if(this.curContext()!==X.brace){let t=this.state.context;this.state.context=[t[0]];try{return e()}finally{this.state.context=t}}else return e()}flowParseTypeParameterInstantiationInExpression(){if(this.reScan_lt()===43)return this.flowParseTypeParameterInstantiation()}flowParseTypeParameterInstantiation(){let e=this.startNode(),t=this.state.inType;return this.state.inType=!0,e.params=[],this.flowInTopLevelContext(()=>{this.expect(43);let t=this.state.noAnonFunctionType;for(this.state.noAnonFunctionType=!1;!this.match(44);)e.params.push(this.flowParseType()),this.match(44)||this.expect(8);this.state.noAnonFunctionType=t}),this.state.inType=t,!this.state.inType&&this.curContext()===X.brace&&this.reScan_lt_gt(),this.expect(44),this.finishNode(e,`TypeParameterInstantiation`)}flowParseTypeParameterInstantiationCallOrNew(){if(this.reScan_lt()!==43)return null;let e=this.startNode(),t=this.state.inType;for(e.params=[],this.state.inType=!0,this.expect(43);!this.match(44);)e.params.push(this.flowParseTypeOrImplicitInstantiation()),this.match(44)||this.expect(8);return this.expect(44),this.state.inType=t,this.finishNode(e,`TypeParameterInstantiation`)}flowParseInterfaceType(){let e=this.startNode();if(this.expectContextual(125),e.extends=[],this.eat(77))do e.extends.push(this.flowParseInterfaceExtends());while(this.eat(8));return e.body=this.flowParseObjectType({allowStatic:!1,allowExact:!1,allowSpread:!1,allowProto:!1,allowInexact:!1}),this.finishNode(e,`InterfaceTypeAnnotation`)}flowParseObjectPropertyKey(){return this.match(131)||this.match(130)?super.parseExprAtom():this.parseIdentifier(!0)}flowParseObjectTypeIndexer(e,t,n){return e.static=t,this.lookahead().type===10?(e.id=this.flowParseObjectPropertyKey(),e.key=this.flowParseTypeInitialiser()):(e.id=null,e.key=this.flowParseType()),this.expect(1),e.value=this.flowParseTypeInitialiser(),e.variance=n,this.finishNode(e,`ObjectTypeIndexer`)}flowParseObjectTypeInternalSlot(e,t){return e.static=t,e.id=this.flowParseObjectPropertyKey(),this.expect(1),this.expect(1),this.match(43)||this.match(6)?(e.method=!0,e.optional=!1,e.value=this.flowParseObjectTypeMethodish(this.startNodeAt(e.loc.start))):(e.method=!1,this.eat(13)&&(e.optional=!0),e.value=this.flowParseTypeInitialiser()),this.finishNode(e,`ObjectTypeInternalSlot`)}flowParseObjectTypeMethodish(e){for(e.params=[],e.rest=null,e.typeParameters=null,e.this=null,this.match(43)&&(e.typeParameters=this.flowParseTypeParameterDeclaration()),this.expect(6),this.match(74)&&(e.this=this.flowParseFunctionTypeParam(!0),e.this.name=null,this.match(7)||this.expect(8));!this.match(7)&&!this.match(17);)e.params.push(this.flowParseFunctionTypeParam(!1)),this.match(7)||this.expect(8);return this.eat(17)&&(e.rest=this.flowParseFunctionTypeParam(!1)),this.expect(7),e.returnType=this.flowParseTypeInitialiser(),this.finishNode(e,`FunctionTypeAnnotation`)}flowParseObjectTypeCallProperty(e,t){let n=this.startNode();return e.static=t,e.value=this.flowParseObjectTypeMethodish(n),this.finishNode(e,`ObjectTypeCallProperty`)}flowParseObjectType({allowStatic:e,allowExact:t,allowSpread:n,allowProto:r,allowInexact:i}){let a=this.state.inType;this.state.inType=!0;let o=this.startNode();o.callProperties=[],o.properties=[],o.indexers=[],o.internalSlots=[];let s,c,l=!1;for(t&&this.match(3)?(this.expect(3),s=5,c=!0):(this.expect(2),s=4,c=!1),o.exact=c;!this.match(s);){let t=!1,a=null,s=null,u=this.startNode();if(r&&this.isContextual(114)){let t=this.lookahead();t.type!==10&&t.type!==13&&(this.next(),a=this.state.startLoc,e=!1)}if(e&&this.isContextual(102)){let e=this.lookahead();e.type!==10&&e.type!==13&&(this.next(),t=!0)}let d=this.flowParseVariance();if(this.eat(0))a!=null&&this.unexpected(a),this.eat(0)?(d&&this.unexpected(d.loc.start),o.internalSlots.push(this.flowParseObjectTypeInternalSlot(u,t))):o.indexers.push(this.flowParseObjectTypeIndexer(u,t,d));else if(this.match(6)||this.match(43))a!=null&&this.unexpected(a),d&&this.unexpected(d.loc.start),o.callProperties.push(this.flowParseObjectTypeCallProperty(u,t));else{let e=`init`;(this.isContextual(95)||this.isContextual(100))&&GN(this.lookahead().type)&&(e=this.state.value,this.next());let r=this.flowParseObjectTypeProperty(u,t,a,d,e,n,i??!c);r===null?(l=!0,s=this.state.lastTokStartLoc):o.properties.push(r)}this.flowObjectTypeSemicolon(),s&&!this.match(4)&&!this.match(5)&&this.raise(Z.UnexpectedExplicitInexactInObject,s)}this.expect(s),n&&(o.inexact=l);let u=this.finishNode(o,`ObjectTypeAnnotation`);return this.state.inType=a,u}flowParseObjectTypeProperty(e,t,n,r,i,a,o){if(this.eat(17))return this.match(8)||this.match(9)||this.match(4)||this.match(5)?(a?o||this.raise(Z.InexactInsideExact,this.state.lastTokStartLoc):this.raise(Z.InexactInsideNonObject,this.state.lastTokStartLoc),r&&this.raise(Z.InexactVariance,r),null):(a||this.raise(Z.UnexpectedSpreadType,this.state.lastTokStartLoc),n!=null&&this.unexpected(n),r&&this.raise(Z.SpreadVariance,r),e.argument=this.flowParseType(),this.finishNode(e,`ObjectTypeSpreadProperty`));{e.key=this.flowParseObjectPropertyKey(),e.static=t,e.proto=n!=null,e.kind=i;let o=!1;return this.match(43)||this.match(6)?(e.method=!0,n!=null&&this.unexpected(n),r&&this.unexpected(r.loc.start),e.value=this.flowParseObjectTypeMethodish(this.startNodeAt(e.loc.start)),(i===`get`||i===`set`)&&this.flowCheckGetterSetterParams(e),!a&&e.key.name===`constructor`&&e.value.this&&this.raise(Z.ThisParamBannedInConstructor,e.value.this)):(i!==`init`&&this.unexpected(),e.method=!1,this.eat(13)&&(o=!0),e.value=this.flowParseTypeInitialiser(),e.variance=r),e.optional=o,this.finishNode(e,`ObjectTypeProperty`)}}flowCheckGetterSetterParams(e){let t=e.kind===`get`?0:1,n=e.value.params.length+(e.value.rest?1:0);e.value.this&&this.raise(e.kind===`get`?Z.GetterMayNotHaveThisParam:Z.SetterMayNotHaveThisParam,e.value.this),n!==t&&this.raise(e.kind===`get`?G.BadGetterArity:G.BadSetterArity,e),e.kind===`set`&&e.value.rest&&this.raise(G.BadSetterRestParameter,e)}flowObjectTypeSemicolon(){!this.eat(9)&&!this.eat(8)&&!this.match(4)&&!this.match(5)&&this.unexpected()}flowParseQualifiedTypeIdentifier(e,t){e??=this.state.startLoc;let n=t||this.flowParseRestrictedIdentifier(!0);for(;this.eat(12);){let t=this.startNodeAt(e);t.qualification=n,t.id=this.flowParseRestrictedIdentifier(!0),n=this.finishNode(t,`QualifiedTypeIdentifier`)}return n}flowParseGenericType(e,t){let n=this.startNodeAt(e);return n.typeParameters=null,n.id=this.flowParseQualifiedTypeIdentifier(e,t),this.match(43)&&(n.typeParameters=this.flowParseTypeParameterInstantiation()),this.finishNode(n,`GenericTypeAnnotation`)}flowParseTypeofType(){let e=this.startNode();return this.expect(83),e.argument=this.flowParsePrimaryType(),this.finishNode(e,`TypeofTypeAnnotation`)}flowParseTupleType(){let e=this.startNode();for(e.types=[],this.expect(0);this.state.pos<this.length&&!this.match(1)&&(e.types.push(this.flowParseType()),!this.match(1));)this.expect(8);return this.expect(1),this.finishNode(e,`TupleTypeAnnotation`)}flowParseFunctionTypeParam(e){let t=null,n=!1,r=null,i=this.startNode(),a=this.lookahead(),o=this.state.type===74;return a.type===10||a.type===13?(o&&!e&&this.raise(Z.ThisParamMustBeFirst,i),t=this.parseIdentifier(o),this.eat(13)&&(n=!0,o&&this.raise(Z.ThisParamMayNotBeOptional,i)),r=this.flowParseTypeInitialiser()):r=this.flowParseType(),i.name=t,i.optional=n,i.typeAnnotation=r,this.finishNode(i,`FunctionTypeParam`)}reinterpretTypeAsFunctionTypeParam(e){let t=this.startNodeAt(e.loc.start);return t.name=null,t.optional=!1,t.typeAnnotation=e,this.finishNode(t,`FunctionTypeParam`)}flowParseFunctionTypeParams(e=[]){let t=null,n=null;for(this.match(74)&&(n=this.flowParseFunctionTypeParam(!0),n.name=null,this.match(7)||this.expect(8));!this.match(7)&&!this.match(17);)e.push(this.flowParseFunctionTypeParam(!1)),this.match(7)||this.expect(8);return this.eat(17)&&(t=this.flowParseFunctionTypeParam(!1)),{params:e,rest:t,_this:n}}flowIdentToTypeAnnotation(e,t,n){switch(n.name){case`any`:return this.finishNode(t,`AnyTypeAnnotation`);case`bool`:case`boolean`:return this.finishNode(t,`BooleanTypeAnnotation`);case`mixed`:return this.finishNode(t,`MixedTypeAnnotation`);case`empty`:return this.finishNode(t,`EmptyTypeAnnotation`);case`number`:return this.finishNode(t,`NumberTypeAnnotation`);case`string`:return this.finishNode(t,`StringTypeAnnotation`);case`symbol`:return this.finishNode(t,`SymbolTypeAnnotation`);default:return this.checkNotUnderscore(n.name),this.flowParseGenericType(e,n)}}flowParsePrimaryType(){let e=this.state.startLoc,t=this.startNode(),n,r,i=!1,a=this.state.noAnonFunctionType;switch(this.state.type){case 2:return this.flowParseObjectType({allowStatic:!1,allowExact:!1,allowSpread:!0,allowProto:!1,allowInexact:!0});case 3:return this.flowParseObjectType({allowStatic:!1,allowExact:!0,allowSpread:!0,allowProto:!1,allowInexact:!1});case 0:return this.state.noAnonFunctionType=!1,r=this.flowParseTupleType(),this.state.noAnonFunctionType=a,r;case 43:{let e=this.startNode();return e.typeParameters=this.flowParseTypeParameterDeclaration(),this.expect(6),n=this.flowParseFunctionTypeParams(),e.params=n.params,e.rest=n.rest,e.this=n._this,this.expect(7),this.expect(15),e.returnType=this.flowParseType(),this.finishNode(e,`FunctionTypeAnnotation`)}case 6:{let e=this.startNode();if(this.next(),!this.match(7)&&!this.match(17))if(Y(this.state.type)||this.match(74)){let e=this.lookahead().type;i=e!==13&&e!==10}else i=!0;if(i){if(this.state.noAnonFunctionType=!1,r=this.flowParseType(),this.state.noAnonFunctionType=a,this.state.noAnonFunctionType||!(this.match(8)||this.match(7)&&this.lookahead().type===15))return this.expect(7),r;this.eat(8)}return n=r?this.flowParseFunctionTypeParams([this.reinterpretTypeAsFunctionTypeParam(r)]):this.flowParseFunctionTypeParams(),e.params=n.params,e.rest=n.rest,e.this=n._this,this.expect(7),this.expect(15),e.returnType=this.flowParseType(),e.typeParameters=null,this.finishNode(e,`FunctionTypeAnnotation`)}case 130:return this.parseLiteral(this.state.value,`StringLiteralTypeAnnotation`);case 81:case 82:return t.value=this.match(81),this.next(),this.finishNode(t,`BooleanLiteralTypeAnnotation`);case 49:if(this.state.value===`-`){if(this.next(),this.match(131))return this.parseLiteralAtNode(-this.state.value,`NumberLiteralTypeAnnotation`,t);if(this.match(132))return this.parseLiteralAtNode(-this.state.value,`BigIntLiteralTypeAnnotation`,t);throw this.raise(Z.UnexpectedSubtractionOperand,this.state.startLoc)}throw this.unexpected();case 131:return this.parseLiteral(this.state.value,`NumberLiteralTypeAnnotation`);case 132:return this.parseLiteral(this.state.value,`BigIntLiteralTypeAnnotation`);case 84:return this.next(),this.finishNode(t,`VoidTypeAnnotation`);case 80:return this.next(),this.finishNode(t,`NullLiteralTypeAnnotation`);case 74:return this.next(),this.finishNode(t,`ThisTypeAnnotation`);case 51:return this.next(),this.finishNode(t,`ExistsTypeAnnotation`);case 83:return this.flowParseTypeofType();default:if(ZN(this.state.type)){let e=rP(this.state.type);return this.next(),super.createIdentifier(t,e)}else if(Y(this.state.type))return this.isContextual(125)?this.flowParseInterfaceType():this.flowIdentToTypeAnnotation(e,t,this.parseIdentifier())}throw this.unexpected()}flowParsePostfixType(){let e=this.state.startLoc,t=this.flowParsePrimaryType(),n=!1;for(;(this.match(0)||this.match(14))&&!this.canInsertSemicolon();){let r=this.startNodeAt(e),i=this.eat(14);n||=i,this.expect(0),!i&&this.match(1)?(r.elementType=t,this.next(),t=this.finishNode(r,`ArrayTypeAnnotation`)):(r.objectType=t,r.indexType=this.flowParseType(),this.expect(1),n?(r.optional=i,t=this.finishNode(r,`OptionalIndexedAccessType`)):t=this.finishNode(r,`IndexedAccessType`))}return t}flowParsePrefixType(){let e=this.startNode();return this.eat(13)?(e.typeAnnotation=this.flowParsePrefixType(),this.finishNode(e,`NullableTypeAnnotation`)):this.flowParsePostfixType()}flowParseAnonFunctionWithoutParens(){let e=this.flowParsePrefixType();if(!this.state.noAnonFunctionType&&this.eat(15)){let t=this.startNodeAt(e.loc.start);return t.params=[this.reinterpretTypeAsFunctionTypeParam(e)],t.rest=null,t.this=null,t.returnType=this.flowParseType(),t.typeParameters=null,this.finishNode(t,`FunctionTypeAnnotation`)}return e}flowParseIntersectionType(){let e=this.startNode();this.eat(41);let t=this.flowParseAnonFunctionWithoutParens();for(e.types=[t];this.eat(41);)e.types.push(this.flowParseAnonFunctionWithoutParens());return e.types.length===1?t:this.finishNode(e,`IntersectionTypeAnnotation`)}flowParseUnionType(){let e=this.startNode();this.eat(39);let t=this.flowParseIntersectionType();for(e.types=[t];this.eat(39);)e.types.push(this.flowParseIntersectionType());return e.types.length===1?t:this.finishNode(e,`UnionTypeAnnotation`)}flowParseType(){let e=this.state.inType;this.state.inType=!0;let t=this.flowParseUnionType();return this.state.inType=e,t}flowParseTypeOrImplicitInstantiation(){if(this.state.type===128&&this.state.value===`_`){let e=this.state.startLoc,t=this.parseIdentifier();return this.flowParseGenericType(e,t)}else return this.flowParseType()}flowParseTypeAnnotation(){let e=this.startNode();return e.typeAnnotation=this.flowParseTypeInitialiser(),this.finishNode(e,`TypeAnnotation`)}flowParseTypeAnnotatableIdentifier(e){let t=e?this.parseIdentifier():this.flowParseRestrictedIdentifier();return this.match(10)&&(t.typeAnnotation=this.flowParseTypeAnnotation(),this.resetEndLocation(t)),t}typeCastToParameter(e){return e.expression.typeAnnotation=e.typeAnnotation,this.resetEndLocation(e.expression,e.typeAnnotation.loc.end),e.expression}flowParseVariance(){let e=null;return this.match(49)?(e=this.startNode(),this.state.value===`+`?e.kind=`plus`:e.kind=`minus`,this.next(),this.finishNode(e,`Variance`)):e}parseFunctionBody(e,t,n=!1){if(t){this.forwardNoArrowParamsConversionAt(e,()=>super.parseFunctionBody(e,!0,n));return}super.parseFunctionBody(e,!1,n)}parseFunctionBodyAndFinish(e,t,n=!1){if(this.match(10)){let t=this.startNode();[t.typeAnnotation,e.predicate]=this.flowParseTypeAndPredicateInitialiser(),e.returnType=t.typeAnnotation?this.finishNode(t,`TypeAnnotation`):null}return super.parseFunctionBodyAndFinish(e,t,n)}parseStatementLike(e){if(this.state.strict&&this.isContextual(125)){if(WN(this.lookahead().type)){let e=this.startNode();return this.next(),this.flowParseInterface(e)}}else if(this.isContextual(122)){let e=this.startNode();return this.next(),this.flowParseEnumDeclaration(e)}let t=super.parseStatementLike(e);return this.flowPragma===void 0&&!this.isValidDirective(t)&&(this.flowPragma=null),t}parseExpressionStatement(e,t,n){if(t.type===`Identifier`){if(t.name===`declare`){if(this.match(76)||Y(this.state.type)||this.match(64)||this.match(70)||this.match(78))return this.flowParseDeclare(e)}else if(Y(this.state.type)){if(t.name===`interface`)return this.flowParseInterface(e);if(t.name===`type`)return this.flowParseTypeAlias(e);if(t.name===`opaque`)return this.flowParseOpaqueType(e,!1)}}return super.parseExpressionStatement(e,t,n)}shouldParseExportDeclaration(){let{type:e}=this.state;return e===122||YN(e)?!this.state.containsEsc:super.shouldParseExportDeclaration()}isExportDefaultSpecifier(){let{type:e}=this.state;return e===122||YN(e)?this.state.containsEsc:super.isExportDefaultSpecifier()}parseExportDefaultExpression(){if(this.isContextual(122)){let e=this.startNode();return this.next(),this.flowParseEnumDeclaration(e)}return super.parseExportDefaultExpression()}parseConditional(e,t,n){if(!this.match(13))return e;if(this.state.maybeInArrowParameters){let t=this.lookaheadCharCode();if(t===44||t===61||t===58||t===41)return this.setOptionalParametersError(n),e}this.expect(13);let r=this.state.clone(),i=this.state.noArrowAt,a=this.startNodeAt(t),{consequent:o,failed:s}=this.tryParseConditionalConsequent(),[c,l]=this.getArrowLikeExpressions(o);if(s||l.length>0){let e=[...i];if(l.length>0){this.state=r,this.state.noArrowAt=e;for(let t=0;t<l.length;t++)e.push(l[t].start);({consequent:o,failed:s}=this.tryParseConditionalConsequent()),[c,l]=this.getArrowLikeExpressions(o)}s&&c.length>1&&this.raise(Z.AmbiguousConditionalArrow,r.startLoc),s&&c.length===1&&(this.state=r,e.push(c[0].start),this.state.noArrowAt=e,{consequent:o,failed:s}=this.tryParseConditionalConsequent())}return this.getArrowLikeExpressions(o,!0),this.state.noArrowAt=i,this.expect(10),a.test=e,a.consequent=o,a.alternate=this.forwardNoArrowParamsConversionAt(a,()=>this.parseMaybeAssign(void 0,void 0)),this.finishNode(a,`ConditionalExpression`)}tryParseConditionalConsequent(){this.state.noArrowParamsConversionAt.push(this.state.start);let e=this.parseMaybeAssignAllowIn(),t=!this.match(10);return this.state.noArrowParamsConversionAt.pop(),{consequent:e,failed:t}}getArrowLikeExpressions(e,t){let n=[e],r=[];for(;n.length!==0;){let e=n.pop();e.type===`ArrowFunctionExpression`&&e.body.type!==`BlockStatement`?(e.typeParameters||!e.returnType?this.finishArrowValidation(e):r.push(e),n.push(e.body)):e.type===`ConditionalExpression`&&(n.push(e.consequent),n.push(e.alternate))}return t?(r.forEach(e=>this.finishArrowValidation(e)),[r,[]]):RP(r,e=>e.params.every(e=>this.isAssignable(e,!0)))}finishArrowValidation(e){this.toAssignableList(e.params,e.extra?.trailingCommaLoc,!1),this.scope.enter(518),super.checkParams(e,!1,!0),this.scope.exit()}forwardNoArrowParamsConversionAt(e,t){let n;return this.state.noArrowParamsConversionAt.includes(this.offsetToSourcePos(e.start))?(this.state.noArrowParamsConversionAt.push(this.state.start),n=t(),this.state.noArrowParamsConversionAt.pop()):n=t(),n}parseParenItem(e,t){let n=super.parseParenItem(e,t);if(this.eat(13)&&(n.optional=!0,this.resetEndLocation(e)),this.match(10)){let e=this.startNodeAt(t);return e.expression=n,e.typeAnnotation=this.flowParseTypeAnnotation(),this.finishNode(e,`TypeCastExpression`)}return n}assertModuleNodeAllowed(e){e.type===`ImportDeclaration`&&(e.importKind===`type`||e.importKind===`typeof`)||e.type===`ExportNamedDeclaration`&&e.exportKind===`type`||e.type===`ExportAllDeclaration`&&e.exportKind===`type`||super.assertModuleNodeAllowed(e)}parseExportDeclaration(e){if(this.isContextual(126)){e.exportKind=`type`;let t=this.startNode();return this.next(),this.match(2)?(e.specifiers=this.parseExportSpecifiers(!0),super.parseExportFrom(e),null):this.flowParseTypeAlias(t)}else if(this.isContextual(127)){e.exportKind=`type`;let t=this.startNode();return this.next(),this.flowParseOpaqueType(t,!1)}else if(this.isContextual(125)){e.exportKind=`type`;let t=this.startNode();return this.next(),this.flowParseInterface(t)}else if(this.isContextual(122)){e.exportKind=`value`;let t=this.startNode();return this.next(),this.flowParseEnumDeclaration(t)}else return super.parseExportDeclaration(e)}eatExportStar(e){return super.eatExportStar(e)?!0:this.isContextual(126)&&this.lookahead().type===51?(e.exportKind=`type`,this.next(),this.next(),!0):!1}maybeParseExportNamespaceSpecifier(e){let{startLoc:t}=this.state,n=super.maybeParseExportNamespaceSpecifier(e);return n&&e.exportKind===`type`&&this.unexpected(t),n}parseClassId(e,t,n){super.parseClassId(e,t,n),this.match(43)&&(e.typeParameters=this.flowParseTypeParameterDeclaration())}parseClassMember(e,t,n){let{startLoc:r}=this.state;if(this.isContextual(121)){if(super.parseClassMemberFromModifier(e,t))return;t.declare=!0}super.parseClassMember(e,t,n),t.declare&&(t.type!==`ClassProperty`&&t.type!==`ClassPrivateProperty`&&t.type!==`PropertyDefinition`?this.raise(Z.DeclareClassElement,r):t.value&&this.raise(Z.DeclareClassFieldInitializer,t.value))}isIterator(e){return e===`iterator`||e===`asyncIterator`}readIterator(){let e=super.readWord1(),t=`@@`+e;(!this.isIterator(e)||!this.state.inType)&&this.raise(G.InvalidIdentifier,this.state.curPosition(),{identifierName:t}),this.finishToken(128,t)}getTokenFromCode(e){let t=this.input.charCodeAt(this.state.pos+1);e===123&&t===124?this.finishOp(3,2):this.state.inType&&(e===62||e===60)?this.finishOp(e===62?44:43,1):this.state.inType&&e===63?t===46?this.finishOp(14,2):this.finishOp(13,1):DP(e,t,this.input.charCodeAt(this.state.pos+2))?(this.state.pos+=2,this.readIterator()):super.getTokenFromCode(e)}isAssignable(e,t){return e.type===`TypeCastExpression`?this.isAssignable(e.expression,t):super.isAssignable(e,t)}toAssignable(e,t=!1){!t&&e.type===`AssignmentExpression`&&e.left.type===`TypeCastExpression`&&(e.left=this.typeCastToParameter(e.left)),super.toAssignable(e,t)}toAssignableList(e,t,n){for(let t=0;t<e.length;t++){let n=e[t];n?.type===`TypeCastExpression`&&(e[t]=this.typeCastToParameter(n))}super.toAssignableList(e,t,n)}toReferencedList(e,t){for(let n=0;n<e.length;n++){let r=e[n];r&&r.type===`TypeCastExpression`&&!r.extra?.parenthesized&&(e.length>1||!t)&&this.raise(Z.TypeCastInPattern,r.typeAnnotation)}return e}parseArrayLike(e,t){let n=super.parseArrayLike(e,t);return t!=null&&!this.state.maybeInArrowParameters&&this.toReferencedList(n.elements),n}isValidLVal(e,t,n,r){return e===`TypeCastExpression`||super.isValidLVal(e,t,n,r)}parseClassProperty(e){return this.match(10)&&(e.typeAnnotation=this.flowParseTypeAnnotation()),super.parseClassProperty(e)}parseClassPrivateProperty(e){return this.match(10)&&(e.typeAnnotation=this.flowParseTypeAnnotation()),super.parseClassPrivateProperty(e)}isClassMethod(){return this.match(43)||super.isClassMethod()}isClassProperty(){return this.match(10)||super.isClassProperty()}isNonstaticConstructor(e){return!this.match(10)&&super.isNonstaticConstructor(e)}pushClassMethod(e,t,n,r,i,a){if(t.variance&&this.unexpected(t.variance.loc.start),delete t.variance,this.match(43)&&(t.typeParameters=this.flowParseTypeParameterDeclaration()),super.pushClassMethod(e,t,n,r,i,a),t.params&&i){let e=t.params;e.length>0&&this.isThisParam(e[0])&&this.raise(Z.ThisParamBannedInConstructor,t)}else if(t.type===`MethodDefinition`&&i&&t.value.params){let e=t.value.params;e.length>0&&this.isThisParam(e[0])&&this.raise(Z.ThisParamBannedInConstructor,t)}}pushClassPrivateMethod(e,t,n,r){t.variance&&this.unexpected(t.variance.loc.start),delete t.variance,this.match(43)&&(t.typeParameters=this.flowParseTypeParameterDeclaration()),super.pushClassPrivateMethod(e,t,n,r)}parseClassSuper(e){if(super.parseClassSuper(e),e.superClass&&(this.match(43)||this.match(47))&&(e.superTypeArguments=this.flowParseTypeParameterInstantiationInExpression()),this.isContextual(109)){this.next();let t=e.implements=[];do{let e=this.startNode();e.id=this.flowParseRestrictedIdentifier(!0),this.match(43)?e.typeParameters=this.flowParseTypeParameterInstantiation():e.typeParameters=null,t.push(this.finishNode(e,`ClassImplements`))}while(this.eat(8))}}checkGetterSetterParams(e){super.checkGetterSetterParams(e);let t=this.getObjectOrClassMethodParams(e);if(t.length>0){let n=t[0];this.isThisParam(n)&&e.kind===`get`?this.raise(Z.GetterMayNotHaveThisParam,n):this.isThisParam(n)&&this.raise(Z.SetterMayNotHaveThisParam,n)}}parsePropertyNamePrefixOperator(e){e.variance=this.flowParseVariance()}parseObjPropValue(e,t,n,r,i,a,o){e.variance&&this.unexpected(e.variance.loc.start),delete e.variance;let s;this.match(43)&&!a&&(s=this.flowParseTypeParameterDeclaration(),this.match(6)||this.unexpected());let c=super.parseObjPropValue(e,t,n,r,i,a,o);return s&&((c.value||c).typeParameters=s),c}parseFunctionParamType(e){return this.eat(13)&&(e.type!==`Identifier`&&this.raise(Z.PatternIsOptional,e),this.isThisParam(e)&&this.raise(Z.ThisParamMayNotBeOptional,e),e.optional=!0),this.match(10)?e.typeAnnotation=this.flowParseTypeAnnotation():this.isThisParam(e)&&this.raise(Z.ThisParamAnnotationRequired,e),this.match(25)&&this.isThisParam(e)&&this.raise(Z.ThisParamNoDefault,e),this.resetEndLocation(e),e}parseMaybeDefault(e,t){let n=super.parseMaybeDefault(e,t);return n.type===`AssignmentPattern`&&n.typeAnnotation&&n.right.start<n.typeAnnotation.start&&this.raise(Z.TypeBeforeInitializer,n.typeAnnotation),n}parseImportSpecifierLocal(e,t,n){t.local=IP(e)?this.flowParseRestrictedIdentifier(!0,!0):this.parseIdentifier(),e.specifiers.push(this.finishImportSpecifier(t,n))}isPotentialImportPhase(e){if(super.isPotentialImportPhase(e))return!0;if(this.isContextual(126)){if(!e)return!0;let t=this.lookaheadCharCode();return t===123||t===42}return!e&&this.isContextual(83)}applyImportPhase(e,t,n,r){if(super.applyImportPhase(e,t,n,r),t){if(!n&&this.match(61))return;e.exportKind=n===`type`?n:`value`}else n===`type`&&this.match(51)&&this.unexpected(),e.importKind=n===`type`||n===`typeof`?n:`value`}parseImportSpecifier(e,t,n,r,i){let a=e.imported,o=null;a.type===`Identifier`&&(a.name===`type`?o=`type`:a.name===`typeof`&&(o=`typeof`));let s=!1;if(this.isContextual(89)&&!this.isLookaheadContextual(`as`)){let t=this.parseIdentifier(!0);o!==null&&!WN(this.state.type)?(e.imported=t,e.importKind=o,e.local=this.cloneIdentifier(t)):(e.imported=a,e.importKind=null,e.local=this.parseIdentifier())}else{if(o!==null&&WN(this.state.type))e.imported=this.parseIdentifier(!0),e.importKind=o;else{if(t)throw this.raise(G.ImportBindingIsString,e,{importName:a.value});e.imported=a,e.importKind=null}this.eatContextual(89)?e.local=this.parseIdentifier():(s=!0,e.local=this.cloneIdentifier(e.imported))}let c=IP(e);return n&&c&&this.raise(Z.ImportTypeShorthandOnlyInPureImport,e),(n||c)&&this.checkReservedType(e.local.name,e.local.loc.start,!0),s&&!n&&!c&&this.checkReservedWord(e.local.name,e.loc.start,!0,!0),this.finishImportSpecifier(e,`ImportSpecifier`)}parseBindingAtom(){switch(this.state.type){case 74:return this.parseIdentifier(!0);default:return super.parseBindingAtom()}}parseFunctionParams(e,t){let n=e.kind;n!==`get`&&n!==`set`&&this.match(43)&&(e.typeParameters=this.flowParseTypeParameterDeclaration()),super.parseFunctionParams(e,t)}parseVarId(e,t){super.parseVarId(e,t),this.match(10)&&(e.id.typeAnnotation=this.flowParseTypeAnnotation(),this.resetEndLocation(e.id))}parseAsyncArrowFromCallExpression(e,t){if(this.match(10)){let t=this.state.noAnonFunctionType;this.state.noAnonFunctionType=!0,e.returnType=this.flowParseTypeAnnotation(),this.state.noAnonFunctionType=t}return super.parseAsyncArrowFromCallExpression(e,t)}shouldParseAsyncArrow(){return this.match(10)||super.shouldParseAsyncArrow()}parseMaybeAssign(e,t){let n=null,r;if(this.hasPlugin(`jsx`)&&(this.match(138)||this.match(43))){if(n=this.state.clone(),r=this.tryParse(()=>super.parseMaybeAssign(e,t),n),!r.error)return r.node;let{context:i}=this.state,a=i[i.length-1];(a===X.j_oTag||a===X.j_expr)&&i.pop()}if(r?.error||this.match(43)){n||=this.state.clone();let i,a=this.tryParse(n=>{i=this.flowParseTypeParameterDeclaration();let r=this.forwardNoArrowParamsConversionAt(i,()=>{let n=super.parseMaybeAssign(e,t);return this.resetStartLocationFromNode(n,i),n});r.extra?.parenthesized&&n();let a=this.maybeUnwrapTypeCastExpression(r);return a.type!==`ArrowFunctionExpression`&&n(),a.typeParameters=i,this.resetStartLocationFromNode(a,i),r},n),o=null;if(a.node&&this.maybeUnwrapTypeCastExpression(a.node).type===`ArrowFunctionExpression`){if(!a.error&&!a.aborted)return a.node.async&&this.raise(Z.UnexpectedTypeParameterBeforeAsyncArrowFunction,i),a.node;o=a.node}if(r?.node)return this.state=r.failState,r.node;if(o)return this.state=a.failState,o;throw r?.thrown?r.error:a.thrown?a.error:this.raise(Z.UnexpectedTokenAfterTypeParameter,i)}return super.parseMaybeAssign(e,t)}parseArrow(e){if(this.match(10)){let t=this.tryParse(()=>{let t=this.state.noAnonFunctionType;this.state.noAnonFunctionType=!0;let n=this.startNode();return[n.typeAnnotation,e.predicate]=this.flowParseTypeAndPredicateInitialiser(),this.state.noAnonFunctionType=t,this.canInsertSemicolon()&&this.unexpected(),this.match(15)||this.unexpected(),n});if(t.thrown)return null;t.error&&(this.state=t.failState),e.returnType=t.node.typeAnnotation?this.finishNode(t.node,`TypeAnnotation`):null}return super.parseArrow(e)}shouldParseArrow(e){return this.match(10)||super.shouldParseArrow(e)}setArrowFunctionParameters(e,t){this.state.noArrowParamsConversionAt.includes(this.offsetToSourcePos(e.start))?e.params=t:super.setArrowFunctionParameters(e,t)}checkParams(e,t,n,r=!0){if(!(n&&this.state.noArrowParamsConversionAt.includes(this.offsetToSourcePos(e.start)))){for(let t=0;t<e.params.length;t++)this.isThisParam(e.params[t])&&t>0&&this.raise(Z.ThisParamMustBeFirst,e.params[t]);super.checkParams(e,t,n,r)}}parseParenAndDistinguishExpression(e){return super.parseParenAndDistinguishExpression(e&&!this.state.noArrowAt.includes(this.sourceToOffsetPos(this.state.start)))}parseSubscripts(e,t,n){if(e.type===`Identifier`&&e.name===`async`&&this.state.noArrowAt.includes(t.index)){this.next();let n=this.startNodeAt(t);n.callee=e,n.arguments=super.parseCallExpressionArguments(),e=this.finishNode(n,`CallExpression`)}else if(e.type===`Identifier`&&e.name===`async`&&this.match(43)){let r=this.state.clone(),i=this.tryParse(e=>this.parseAsyncArrowWithTypeParameters(t)||e(),r);if(!i.error&&!i.aborted)return i.node;let a=this.tryParse(()=>super.parseSubscripts(e,t,n),r);if(a.node&&!a.error)return a.node;if(i.node)return this.state=i.failState,i.node;if(a.node)return this.state=a.failState,a.node;throw i.error||a.error}return super.parseSubscripts(e,t,n)}parseSubscript(e,t,n,r){if(this.match(14)&&this.isLookaheadToken_lt()){if(r.optionalChainMember=!0,n)return r.stop=!0,e;this.next();let i=this.startNodeAt(t);return i.callee=e,i.typeArguments=this.flowParseTypeParameterInstantiationInExpression(),this.expect(6),i.arguments=this.parseCallExpressionArguments(),i.optional=!0,this.finishCallExpression(i,!0)}else if(!n&&this.shouldParseTypes()&&(this.match(43)||this.match(47))){let n=this.startNodeAt(t);n.callee=e;let i=this.tryParse(()=>(n.typeArguments=this.flowParseTypeParameterInstantiationCallOrNew(),this.expect(6),n.arguments=super.parseCallExpressionArguments(),r.optionalChainMember&&(n.optional=!1),this.finishCallExpression(n,r.optionalChainMember)));if(i.node)return i.error&&(this.state=i.failState),i.node}return super.parseSubscript(e,t,n,r)}parseNewCallee(e){super.parseNewCallee(e);let t=null;this.shouldParseTypes()&&this.match(43)&&(t=this.tryParse(()=>this.flowParseTypeParameterInstantiationCallOrNew()).node),e.typeArguments=t}parseAsyncArrowWithTypeParameters(e){let t=this.startNodeAt(e);if(this.parseFunctionParams(t,!1),this.parseArrow(t))return super.parseArrowExpression(t,void 0,!0)}readToken_mult_modulo(e){let t=this.input.charCodeAt(this.state.pos+1);if(e===42&&t===47&&this.state.hasFlowComment){this.state.hasFlowComment=!1,this.state.pos+=2,this.nextToken();return}super.readToken_mult_modulo(e)}readToken_pipe_amp(e){let t=this.input.charCodeAt(this.state.pos+1);if(e===124&&t===125){this.finishOp(5,2);return}super.readToken_pipe_amp(e)}parseTopLevel(e,t){let n=super.parseTopLevel(e,t);return this.state.hasFlowComment&&this.raise(Z.UnterminatedFlowComment,this.state.curPosition()),n}skipBlockComment(){if(this.hasPlugin(`flowComments`)&&this.skipFlowComment()){if(this.state.hasFlowComment)throw this.raise(Z.NestedFlowComment,this.state.startLoc);this.hasFlowCommentCompletion();let e=this.skipFlowComment();e&&(this.state.pos+=e,this.state.hasFlowComment=!0);return}return super.skipBlockComment(this.state.hasFlowComment?`*-/`:`*/`)}skipFlowComment(){let{pos:e}=this.state,t=2;for(;[32,9].includes(this.input.charCodeAt(e+t));)t++;let n=this.input.charCodeAt(t+e),r=this.input.charCodeAt(t+e+1);return n===58&&r===58?t+2:this.input.slice(t+e,t+e+12)===`flow-include`?t+12:n===58&&r!==58?t:!1}hasFlowCommentCompletion(){if(this.input.indexOf(`*/`,this.state.pos)===-1)throw this.raise(G.UnterminatedComment,this.state.curPosition())}flowEnumErrorBooleanMemberNotInitialized(e,{enumName:t,memberName:n}){this.raise(Z.EnumBooleanMemberNotInitialized,e,{memberName:n,enumName:t})}flowEnumErrorInvalidMemberInitializer(e,t){return this.raise(t.explicitType?t.explicitType===`symbol`?Z.EnumInvalidMemberInitializerSymbolType:Z.EnumInvalidMemberInitializerPrimaryType:Z.EnumInvalidMemberInitializerUnknownType,e,t)}flowEnumErrorNumberMemberNotInitialized(e,t){this.raise(Z.EnumNumberMemberNotInitialized,e,t)}flowEnumErrorStringMemberInconsistentlyInitialized(e,t){this.raise(Z.EnumStringMemberInconsistentlyInitialized,e,t)}flowEnumMemberInit(){let e=this.state.startLoc,t=()=>this.match(8)||this.match(4);switch(this.state.type){case 131:{let n=this.parseNumericLiteral(this.state.value);return t()?{type:`number`,loc:n.loc.start,value:n}:{type:`invalid`,loc:e}}case 130:{let n=this.parseStringLiteral(this.state.value);return t()?{type:`string`,loc:n.loc.start,value:n}:{type:`invalid`,loc:e}}case 81:case 82:{let n=this.parseBooleanLiteral(this.match(81));return t()?{type:`boolean`,loc:n.loc.start,value:n}:{type:`invalid`,loc:e}}default:return{type:`invalid`,loc:e}}}flowEnumMemberRaw(){let e=this.state.startLoc;return{id:this.parseIdentifier(!0),init:this.eat(25)?this.flowEnumMemberInit():{type:`none`,loc:e}}}flowEnumCheckExplicitTypeMismatch(e,t,n){let{explicitType:r}=t;r!==null&&r!==n&&this.flowEnumErrorInvalidMemberInitializer(e,t)}flowEnumMembers({enumName:e,explicitType:t}){let n=new Set,r={booleanMembers:[],numberMembers:[],stringMembers:[],defaultedMembers:[]},i=!1;for(;!this.match(4);){if(this.eat(17)){i=!0;break}let a=this.startNode(),{id:o,init:s}=this.flowEnumMemberRaw(),c=o.name;if(c===``)continue;/^[a-z]/.test(c)&&this.raise(Z.EnumInvalidMemberName,o,{memberName:c,suggestion:c[0].toUpperCase()+c.slice(1),enumName:e}),n.has(c)&&this.raise(Z.EnumDuplicateMemberName,o,{memberName:c,enumName:e}),n.add(c);let l={enumName:e,explicitType:t,memberName:c};switch(a.id=o,s.type){case`boolean`:this.flowEnumCheckExplicitTypeMismatch(s.loc,l,`boolean`),a.init=s.value,r.booleanMembers.push(this.finishNode(a,`EnumBooleanMember`));break;case`number`:this.flowEnumCheckExplicitTypeMismatch(s.loc,l,`number`),a.init=s.value,r.numberMembers.push(this.finishNode(a,`EnumNumberMember`));break;case`string`:this.flowEnumCheckExplicitTypeMismatch(s.loc,l,`string`),a.init=s.value,r.stringMembers.push(this.finishNode(a,`EnumStringMember`));break;case`invalid`:throw this.flowEnumErrorInvalidMemberInitializer(s.loc,l);case`none`:switch(t){case`boolean`:this.flowEnumErrorBooleanMemberNotInitialized(s.loc,l);break;case`number`:this.flowEnumErrorNumberMemberNotInitialized(s.loc,l);break;default:r.defaultedMembers.push(this.finishNode(a,`EnumDefaultedMember`))}}this.match(4)||this.expect(8)}return{members:r,hasUnknownMembers:i}}flowEnumStringMembers(e,t,{enumName:n}){if(e.length===0)return t;if(t.length===0)return e;if(t.length>e.length){for(let t of e)this.flowEnumErrorStringMemberInconsistentlyInitialized(t,{enumName:n});return t}else{for(let e of t)this.flowEnumErrorStringMemberInconsistentlyInitialized(e,{enumName:n});return e}}flowEnumParseExplicitType({enumName:e}){if(!this.eatContextual(98))return null;if(!Y(this.state.type))throw this.raise(Z.EnumInvalidExplicitTypeUnknownSupplied,this.state.startLoc,{enumName:e});let{value:t}=this.state;return this.next(),t!==`boolean`&&t!==`number`&&t!==`string`&&t!==`symbol`&&this.raise(Z.EnumInvalidExplicitType,this.state.startLoc,{enumName:e,invalidEnumType:t}),t}flowEnumBody(e,t){let n=t.name,r=t.loc.start,i=this.flowEnumParseExplicitType({enumName:n});this.expect(2);let{members:a,hasUnknownMembers:o}=this.flowEnumMembers({enumName:n,explicitType:i});switch(e.hasUnknownMembers=o,i){case`boolean`:return e.explicitType=!0,e.members=a.booleanMembers,this.expect(4),this.finishNode(e,`EnumBooleanBody`);case`number`:return e.explicitType=!0,e.members=a.numberMembers,this.expect(4),this.finishNode(e,`EnumNumberBody`);case`string`:return e.explicitType=!0,e.members=this.flowEnumStringMembers(a.stringMembers,a.defaultedMembers,{enumName:n}),this.expect(4),this.finishNode(e,`EnumStringBody`);case`symbol`:return e.members=a.defaultedMembers,this.expect(4),this.finishNode(e,`EnumSymbolBody`);default:{let t=()=>(e.members=[],this.expect(4),this.finishNode(e,`EnumStringBody`));e.explicitType=!1;let i=a.booleanMembers.length,o=a.numberMembers.length,s=a.stringMembers.length,c=a.defaultedMembers.length;if(!i&&!o&&!s&&!c)return t();if(!i&&!o)return e.members=this.flowEnumStringMembers(a.stringMembers,a.defaultedMembers,{enumName:n}),this.expect(4),this.finishNode(e,`EnumStringBody`);if(!o&&!s&&i>=c){for(let e of a.defaultedMembers)this.flowEnumErrorBooleanMemberNotInitialized(e.loc.start,{enumName:n,memberName:e.id.name});return e.members=a.booleanMembers,this.expect(4),this.finishNode(e,`EnumBooleanBody`)}else if(!i&&!s&&o>=c){for(let e of a.defaultedMembers)this.flowEnumErrorNumberMemberNotInitialized(e.loc.start,{enumName:n,memberName:e.id.name});return e.members=a.numberMembers,this.expect(4),this.finishNode(e,`EnumNumberBody`)}else return this.raise(Z.EnumInconsistentMemberValues,r,{enumName:n}),t()}}}flowParseEnumDeclaration(e){let t=this.parseIdentifier();return e.id=t,e.body=this.flowEnumBody(this.startNode(),t),this.finishNode(e,`EnumDeclaration`)}jsxParseOpeningElementAfterName(e){return this.shouldParseTypes()&&(this.match(43)||this.match(47))&&(e.typeArguments=this.flowParseTypeParameterInstantiationInExpression()),super.jsxParseOpeningElementAfterName(e)}isLookaheadToken_lt(){let e=this.nextTokenStart();if(this.input.charCodeAt(e)===60){let t=this.input.charCodeAt(e+1);return t!==60&&t!==61}return!1}reScan_lt_gt(){let{type:e}=this.state;e===43?(--this.state.pos,this.readToken_lt()):e===44&&(--this.state.pos,this.readToken_gt())}reScan_lt(){let{type:e}=this.state;return e===47?(this.state.pos-=2,this.finishOp(43,1),43):e}maybeUnwrapTypeCastExpression(e){return e.type===`TypeCastExpression`?e.expression:e}};const VP={__proto__:null,quot:`"`,amp:`&`,apos:`'`,lt:`<`,gt:`>`,nbsp:`\xA0`,iexcl:`¡`,cent:`¢`,pound:`£`,curren:`¤`,yen:`¥`,brvbar:`¦`,sect:`§`,uml:`¨`,copy:`©`,ordf:`ª`,laquo:`«`,not:`¬`,shy:``,reg:`®`,macr:`¯`,deg:`°`,plusmn:`±`,sup2:`²`,sup3:`³`,acute:`´`,micro:`µ`,para:`¶`,middot:`·`,cedil:`¸`,sup1:`¹`,ordm:`º`,raquo:`»`,frac14:`¼`,frac12:`½`,frac34:`¾`,iquest:`¿`,Agrave:`À`,Aacute:`Á`,Acirc:`Â`,Atilde:`Ã`,Auml:`Ä`,Aring:`Å`,AElig:`Æ`,Ccedil:`Ç`,Egrave:`È`,Eacute:`É`,Ecirc:`Ê`,Euml:`Ë`,Igrave:`Ì`,Iacute:`Í`,Icirc:`Î`,Iuml:`Ï`,ETH:`Ð`,Ntilde:`Ñ`,Ograve:`Ò`,Oacute:`Ó`,Ocirc:`Ô`,Otilde:`Õ`,Ouml:`Ö`,times:`×`,Oslash:`Ø`,Ugrave:`Ù`,Uacute:`Ú`,Ucirc:`Û`,Uuml:`Ü`,Yacute:`Ý`,THORN:`Þ`,szlig:`ß`,agrave:`à`,aacute:`á`,acirc:`â`,atilde:`ã`,auml:`ä`,aring:`å`,aelig:`æ`,ccedil:`ç`,egrave:`è`,eacute:`é`,ecirc:`ê`,euml:`ë`,igrave:`ì`,iacute:`í`,icirc:`î`,iuml:`ï`,eth:`ð`,ntilde:`ñ`,ograve:`ò`,oacute:`ó`,ocirc:`ô`,otilde:`õ`,ouml:`ö`,divide:`÷`,oslash:`ø`,ugrave:`ù`,uacute:`ú`,ucirc:`û`,uuml:`ü`,yacute:`ý`,thorn:`þ`,yuml:`ÿ`,OElig:`Œ`,oelig:`œ`,Scaron:`Š`,scaron:`š`,Yuml:`Ÿ`,fnof:`ƒ`,circ:`ˆ`,tilde:`˜`,Alpha:`Α`,Beta:`Β`,Gamma:`Γ`,Delta:`Δ`,Epsilon:`Ε`,Zeta:`Ζ`,Eta:`Η`,Theta:`Θ`,Iota:`Ι`,Kappa:`Κ`,Lambda:`Λ`,Mu:`Μ`,Nu:`Ν`,Xi:`Ξ`,Omicron:`Ο`,Pi:`Π`,Rho:`Ρ`,Sigma:`Σ`,Tau:`Τ`,Upsilon:`Υ`,Phi:`Φ`,Chi:`Χ`,Psi:`Ψ`,Omega:`Ω`,alpha:`α`,beta:`β`,gamma:`γ`,delta:`δ`,epsilon:`ε`,zeta:`ζ`,eta:`η`,theta:`θ`,iota:`ι`,kappa:`κ`,lambda:`λ`,mu:`μ`,nu:`ν`,xi:`ξ`,omicron:`ο`,pi:`π`,rho:`ρ`,sigmaf:`ς`,sigma:`σ`,tau:`τ`,upsilon:`υ`,phi:`φ`,chi:`χ`,psi:`ψ`,omega:`ω`,thetasym:`ϑ`,upsih:`ϒ`,piv:`ϖ`,ensp:` `,emsp:` `,thinsp:` `,zwnj:``,zwj:``,lrm:``,rlm:``,ndash:`–`,mdash:`—`,lsquo:`‘`,rsquo:`’`,sbquo:`‚`,ldquo:`“`,rdquo:`”`,bdquo:`„`,dagger:`†`,Dagger:`‡`,bull:`•`,hellip:`…`,permil:`‰`,prime:`′`,Prime:`″`,lsaquo:`‹`,rsaquo:`›`,oline:`‾`,frasl:`⁄`,euro:`€`,image:`ℑ`,weierp:`℘`,real:`ℜ`,trade:`™`,alefsym:`ℵ`,larr:`←`,uarr:`↑`,rarr:`→`,darr:`↓`,harr:`↔`,crarr:`↵`,lArr:`⇐`,uArr:`⇑`,rArr:`⇒`,dArr:`⇓`,hArr:`⇔`,forall:`∀`,part:`∂`,exist:`∃`,empty:`∅`,nabla:`∇`,isin:`∈`,notin:`∉`,ni:`∋`,prod:`∏`,sum:`∑`,minus:`−`,lowast:`∗`,radic:`√`,prop:`∝`,infin:`∞`,ang:`∠`,and:`∧`,or:`∨`,cap:`∩`,cup:`∪`,int:`∫`,there4:`∴`,sim:`∼`,cong:`≅`,asymp:`≈`,ne:`≠`,equiv:`≡`,le:`≤`,ge:`≥`,sub:`⊂`,sup:`⊃`,nsub:`⊄`,sube:`⊆`,supe:`⊇`,oplus:`⊕`,otimes:`⊗`,perp:`⊥`,sdot:`⋅`,lceil:`⌈`,rceil:`⌉`,lfloor:`⌊`,rfloor:`⌋`,lang:`〈`,rang:`〉`,loz:`◊`,spades:`♠`,clubs:`♣`,hearts:`♥`,diams:`♦`},HP=RegExp(`\\r\\n|[\\r\\n\\u2028\\u2029]`,`g`);function UP(e){switch(e){case 10:case 13:case 8232:case 8233:return!0;default:return!1}}function WP(e,t,n){for(let r=t;r<n;r++)if(UP(e.charCodeAt(r)))return!0;return!1}const GP=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g,KP=/(?:[^\S\n\r\u2028\u2029]|\/\/.*|\/\*.*?\*\/)*/g;function qP(e){switch(e){case 9:case 11:case 12:case 32:case 160:case 5760:case 8192:case 8193:case 8194:case 8195:case 8196:case 8197:case 8198:case 8199:case 8200:case 8201:case 8202:case 8239:case 8287:case 12288:case 65279:return!0;default:return!1}}const JP=TN`jsx`({AttributeIsEmpty:`JSX attributes must only be assigned a non-empty expression.`,MissingClosingTagElement:({openingTagName:e})=>`Expected corresponding JSX closing tag for <${e}>.`,MissingClosingTagFragment:`Expected corresponding JSX closing tag for <>.`,UnexpectedSequenceExpression:`Sequence expressions cannot be directly nested inside JSX. Did you mean to wrap it in parentheses (...)?`,UnexpectedToken:({unexpected:e,HTMLEntity:t})=>`Unexpected token \`${e}\`. Did you mean \`${t}\` or \`{'${e}'}\`?`,UnsupportedJsxValue:`JSX value should be either an expression or a quoted JSX text.`,UnterminatedJsxContent:`Unterminated JSX contents.`,UnwrappedAdjacentJSXElements:`Adjacent JSX elements must be wrapped in an enclosing tag. Did you want a JSX fragment <>...</>?`});function YP(e){return e?e.type===`JSXOpeningFragment`||e.type===`JSXClosingFragment`:!1}function XP(e){if(e.type===`JSXIdentifier`)return e.name;if(e.type===`JSXNamespacedName`)return e.namespace.name+`:`+e.name.name;if(e.type===`JSXMemberExpression`)return XP(e.object)+`.`+XP(e.property);throw Error(`Node had unexpected type: `+e.type)}var ZP=e=>class extends e{jsxReadToken(){let e=``,t=this.state.pos;for(;;){if(this.state.pos>=this.length)throw this.raise(JP.UnterminatedJsxContent,this.state.startLoc);let n=this.input.charCodeAt(this.state.pos);switch(n){case 60:case 123:if(this.state.pos===this.state.start){n===60&&this.state.canStartJSXElement?(++this.state.pos,this.finishToken(138)):super.getTokenFromCode(n);return}e+=this.input.slice(t,this.state.pos),this.finishToken(137,e);return;case 38:e+=this.input.slice(t,this.state.pos),e+=this.jsxReadEntity(),t=this.state.pos;break;case 62:case 125:this.raise(JP.UnexpectedToken,this.state.curPosition(),{unexpected:this.input[this.state.pos],HTMLEntity:n===125?`}`:`>`});default:UP(n)?(e+=this.input.slice(t,this.state.pos),e+=this.jsxReadNewLine(!0),t=this.state.pos):++this.state.pos}}}jsxReadNewLine(e){let t=this.input.charCodeAt(this.state.pos),n;return++this.state.pos,t===13&&this.input.charCodeAt(this.state.pos)===10?(++this.state.pos,n=e?`
|
|
11
|
+
`:`\r
|
|
12
|
+
`):n=String.fromCharCode(t),++this.state.curLine,this.state.lineStart=this.state.pos,n}jsxReadString(e){let t=``,n=++this.state.pos;for(;;){if(this.state.pos>=this.length)throw this.raise(G.UnterminatedString,this.state.startLoc);let r=this.input.charCodeAt(this.state.pos);if(r===e)break;r===38?(t+=this.input.slice(n,this.state.pos),t+=this.jsxReadEntity(),n=this.state.pos):UP(r)?(t+=this.input.slice(n,this.state.pos),t+=this.jsxReadNewLine(!1),n=this.state.pos):++this.state.pos}t+=this.input.slice(n,this.state.pos++),this.finishToken(130,t)}jsxReadEntity(){let e=++this.state.pos;if(this.codePointAtPos(this.state.pos)===35){++this.state.pos;let e=10;this.codePointAtPos(this.state.pos)===120&&(e=16,++this.state.pos);let t=this.readInt(e,void 0,!1,`bail`);if(t!==null&&this.codePointAtPos(this.state.pos)===59)return++this.state.pos,String.fromCodePoint(t)}else{let t=0,n=!1;for(;t++<10&&this.state.pos<this.length&&!(n=this.codePointAtPos(this.state.pos)===59);)++this.state.pos;if(n){let t=VP[this.input.slice(e,this.state.pos)];if(++this.state.pos,t)return t}}return this.state.pos=e,`&`}jsxReadWord(){let e,t=this.state.pos;do e=this.input.charCodeAt(++this.state.pos);while(_P(e)||e===45);this.finishToken(136,this.input.slice(t,this.state.pos))}jsxParseIdentifier(){let e=this.startNode();return this.match(136)?e.name=this.state.value:ZN(this.state.type)?e.name=rP(this.state.type):this.unexpected(),this.next(),this.finishNode(e,`JSXIdentifier`)}jsxParseNamespacedName(){let e=this.state.startLoc,t=this.jsxParseIdentifier();if(!this.eat(10))return t;let n=this.startNodeAt(e);return n.namespace=t,n.name=this.jsxParseIdentifier(),this.finishNode(n,`JSXNamespacedName`)}jsxParseElementName(){let e=this.state.startLoc,t=this.jsxParseNamespacedName();if(t.type===`JSXNamespacedName`)return t;for(;this.eat(12);){let n=this.startNodeAt(e);n.object=t,n.property=this.jsxParseIdentifier(),t=this.finishNode(n,`JSXMemberExpression`)}return t}jsxParseAttributeValue(){let e;switch(this.state.type){case 2:return e=this.startNode(),this.setContext(X.brace),this.next(),e=this.jsxParseExpressionContainer(e,X.j_oTag),e.expression.type===`JSXEmptyExpression`&&this.raise(JP.AttributeIsEmpty,e),e;case 138:case 130:return this.parseExprAtom();default:throw this.raise(JP.UnsupportedJsxValue,this.state.startLoc)}}jsxParseEmptyExpression(){let e=this.startNodeAt(this.state.lastTokEndLoc);return this.finishNodeAt(e,`JSXEmptyExpression`,this.state.startLoc)}jsxParseSpreadChild(e){return this.next(),e.expression=this.parseExpression(),this.setContext(X.j_expr),this.state.canStartJSXElement=!0,this.expect(4),this.finishNode(e,`JSXSpreadChild`)}jsxParseExpressionContainer(e,t){if(this.match(4))e.expression=this.jsxParseEmptyExpression();else{let t=this.parseExpression();t.type===`SequenceExpression`&&!t.extra?.parenthesized&&this.raise(JP.UnexpectedSequenceExpression,t.expressions[1]),e.expression=t}return this.setContext(t),this.state.canStartJSXElement=!0,this.expect(4),this.finishNode(e,`JSXExpressionContainer`)}jsxParseAttribute(){let e=this.startNode();return this.match(2)?(this.setContext(X.brace),this.next(),this.expect(17),e.argument=this.parseMaybeAssignAllowIn(),this.setContext(X.j_oTag),this.state.canStartJSXElement=!0,this.expect(4),this.finishNode(e,`JSXSpreadAttribute`)):(e.name=this.jsxParseNamespacedName(),e.value=this.eat(25)?this.jsxParseAttributeValue():null,this.finishNode(e,`JSXAttribute`))}jsxParseOpeningElementAt(e){let t=this.startNodeAt(e);return this.eat(139)?this.finishNode(t,`JSXOpeningFragment`):(t.name=this.jsxParseElementName(),this.jsxParseOpeningElementAfterName(t))}jsxParseOpeningElementAfterName(e){let t=[];for(;!this.match(52)&&!this.match(139);)t.push(this.jsxParseAttribute());return e.attributes=t,e.selfClosing=this.eat(52),this.expect(139),this.finishNode(e,`JSXOpeningElement`)}jsxParseClosingElementAt(e){let t=this.startNodeAt(e);return this.eat(139)?this.finishNode(t,`JSXClosingFragment`):(t.name=this.jsxParseElementName(),this.expect(139),this.finishNode(t,`JSXClosingElement`))}jsxParseElementAt(e){let t=this.startNodeAt(e),n=[],r=this.jsxParseOpeningElementAt(e),i=null;if(!r.selfClosing){contents:for(;;)switch(this.state.type){case 138:if(e=this.state.startLoc,this.next(),this.eat(52)){i=this.jsxParseClosingElementAt(e);break contents}n.push(this.jsxParseElementAt(e));break;case 137:n.push(this.parseLiteral(this.state.value,`JSXText`));break;case 2:{let e=this.startNode();this.setContext(X.brace),this.next(),this.match(17)?n.push(this.jsxParseSpreadChild(e)):n.push(this.jsxParseExpressionContainer(e,X.j_expr));break}default:this.unexpected()}YP(r)&&!YP(i)&&i!==null?this.raise(JP.MissingClosingTagFragment,i):(!YP(r)&&YP(i)||!YP(r)&&!YP(i)&&XP(i.name)!==XP(r.name))&&this.raise(JP.MissingClosingTagElement,i,{openingTagName:XP(r.name)})}if(YP(r)?(t.openingFragment=r,t.closingFragment=i):(t.openingElement=r,t.closingElement=i),t.children=n,this.match(43))throw this.raise(JP.UnwrappedAdjacentJSXElements,this.state.startLoc);return YP(r)?this.finishNode(t,`JSXFragment`):this.finishNode(t,`JSXElement`)}jsxParseElement(){let e=this.state.startLoc;return this.next(),this.jsxParseElementAt(e)}setContext(e){let{context:t}=this.state;t[t.length-1]=e}parseExprAtom(e){return this.match(138)?this.jsxParseElement():this.match(43)&&this.input.charCodeAt(this.state.pos)!==33?(this.replaceToken(138),this.jsxParseElement()):super.parseExprAtom(e)}skipSpace(){this.curContext().preserveSpace||super.skipSpace()}getTokenFromCode(e){let t=this.curContext();if(t===X.j_expr){this.jsxReadToken();return}if(t===X.j_oTag||t===X.j_cTag){if(gP(e)){this.jsxReadWord();return}if(e===62){++this.state.pos,this.finishToken(139);return}if((e===34||e===39)&&t===X.j_oTag){this.jsxReadString(e);return}}if(e===60&&this.state.canStartJSXElement&&this.input.charCodeAt(this.state.pos+1)!==33){++this.state.pos,this.finishToken(138);return}super.getTokenFromCode(e)}updateContext(e){let{context:t,type:n}=this.state;if(n===52&&e===138)t.splice(-2,2,X.j_cTag),this.state.canStartJSXElement=!1;else if(n===138)t.push(X.j_oTag);else if(n===139){let n=t[t.length-1];n===X.j_oTag&&e===52||n===X.j_cTag?(t.pop(),this.state.canStartJSXElement=t[t.length-1]===X.j_expr):(this.setContext(X.j_expr),this.state.canStartJSXElement=!0)}else this.state.canStartJSXElement=KN(n)}},QP=class extends AP{tsNames=new Map},$P=class extends jP{importsStack=[];createScope(e){return this.importsStack.push(new Set),new QP(e)}enter(e){e===1024&&this.importsStack.push(new Set),super.enter(e)}exit(){let e=super.exit();return e===1024&&this.importsStack.pop(),e}hasImport(e,t){let n=this.importsStack.length;if(this.importsStack[n-1].has(e))return!0;if(!t&&n>1){for(let t=0;t<n-1;t++)if(this.importsStack[t].has(e))return!0}return!1}declareName(e,t,n){if(t&4096){this.hasImport(e,!0)&&this.parser.raise(G.VarRedeclaration,n,{identifierName:e}),this.importsStack[this.importsStack.length-1].add(e);return}let r=this.currentScope(),i=r.tsNames.get(e)||0;if(t&1024){this.maybeExportDefined(r,e),r.tsNames.set(e,i|16);return}super.declareName(e,t,n),t&2&&(t&1||(this.checkRedeclarationInScope(r,e,t,n),this.maybeExportDefined(r,e)),i|=1),t&256&&(i|=2),t&512&&(i|=4),t&128&&(i|=8),i&&r.tsNames.set(e,i)}isRedeclaredInScope(e,t,n){let r=e.tsNames.get(t);return(r&2)>0?n&256?!!(n&512)!=(r&4)>0:!0:n&128&&(r&8)>0?e.names.get(t)&2?!!(n&1):!1:n&2&&(r&1)>0?!0:super.isRedeclaredInScope(e,t,n)}checkLocalExport(e){let{name:t}=e;if(this.hasImport(t))return;let n=this.scopeStack.length;for(let e=n-1;e>=0;e--){let n=this.scopeStack[e].tsNames.get(t);if((n&1)>0||(n&16)>0)return}super.checkLocalExport(e)}},eF=class{stacks=[];enter(e){this.stacks.push(e)}exit(){this.stacks.pop()}currentFlags(){return this.stacks[this.stacks.length-1]}get hasAwait(){return(this.currentFlags()&2)>0}get hasYield(){return(this.currentFlags()&1)>0}get hasReturn(){return(this.currentFlags()&4)>0}get hasIn(){return(this.currentFlags()&8)>0}};function tF(e,t){return(e?2:0)|(t?1:0)}var nF=class{sawUnambiguousESM=!1;ambiguousScriptDifferentAst=!1;sourceToOffsetPos(e){return e+this.startIndex}offsetToSourcePos(e){return e-this.startIndex}hasPlugin(e){if(typeof e==`string`)return this.plugins.has(e);{let[t,n]=e;if(!this.hasPlugin(t))return!1;let r=this.plugins.get(t);for(let e of Object.keys(n))if(r?.[e]!==n[e])return!1;return!0}}getPluginOption(e,t){return this.plugins.get(e)?.[t]}};function rF(e,t){e.trailingComments===void 0?e.trailingComments=t:e.trailingComments.unshift(...t)}function iF(e,t){e.leadingComments===void 0?e.leadingComments=t:e.leadingComments.unshift(...t)}function aF(e,t){e.innerComments===void 0?e.innerComments=t:e.innerComments.unshift(...t)}function oF(e,t,n){let r=null,i=t.length;for(;r===null&&i>0;)r=t[--i];r===null||r.start>n.start?aF(e,n.comments):rF(r,n.comments)}var sF=class extends nF{addComment(e){this.filename&&(e.loc.filename=this.filename);let{commentsLen:t}=this.state;this.comments.length!==t&&(this.comments.length=t),this.comments.push(e),this.state.commentsLen++}processComment(e){let{commentStack:t}=this.state,n=t.length;if(n===0)return;let r=n-1,i=t[r];i.start===e.end&&(i.leadingNode=e,r--);let{start:a}=e;for(;r>=0;r--){let n=t[r],i=n.end;if(i>a)n.containingNode=e,this.finalizeComment(n),t.splice(r,1);else{i===a&&(n.trailingNode=e);break}}}finalizeComment(e){let{comments:t}=e;if(e.leadingNode!==null||e.trailingNode!==null)e.leadingNode!==null&&rF(e.leadingNode,t),e.trailingNode!==null&&iF(e.trailingNode,t);else{let n=e.containingNode,r=e.start;if(this.input.charCodeAt(this.offsetToSourcePos(r)-1)===44)switch(n.type){case`ObjectExpression`:case`ObjectPattern`:oF(n,n.properties,e);break;case`CallExpression`:case`OptionalCallExpression`:oF(n,n.arguments,e);break;case`ImportExpression`:oF(n,[n.source,n.options??null],e);break;case`FunctionDeclaration`:case`FunctionExpression`:case`ArrowFunctionExpression`:case`ObjectMethod`:case`ClassMethod`:case`ClassPrivateMethod`:oF(n,n.params,e);break;case`ArrayExpression`:case`ArrayPattern`:oF(n,n.elements,e);break;case`ExportNamedDeclaration`:case`ImportDeclaration`:oF(n,n.specifiers,e);break;case`TSEnumDeclaration`:aF(n,t);break;case`TSEnumBody`:oF(n,n.members,e);break;default:aF(n,t)}else aF(n,t)}}finalizeRemainingComments(){let{commentStack:e}=this.state;for(let t=e.length-1;t>=0;t--)this.finalizeComment(e[t]);this.state.commentStack=[]}resetPreviousNodeTrailingComments(e){let{commentStack:t}=this.state,{length:n}=t;if(n===0)return;let r=t[n-1];r.leadingNode===e&&(r.leadingNode=null)}takeSurroundingComments(e,t,n){let{commentStack:r}=this.state,i=r.length;if(i===0)return;let a=i-1;for(;a>=0;a--){let i=r[a],o=i.end;if(i.start===n)i.leadingNode=e;else if(o===t)i.trailingNode=e;else if(o<t)break}}},cF=class e{flags=1024;get strict(){return(this.flags&1)>0}set strict(e){e?this.flags|=1:this.flags&=-2}startIndex;curLine;lineStart;startLoc;endLoc;init({strictMode:e,sourceType:t,startIndex:n,startLine:r,startColumn:i}){this.strict=e===!1?!1:e===!0?!0:t===`module`,this.startIndex=n,this.curLine=r,this.lineStart=-i,this.startLoc=this.endLoc=new dN(r,i,n)}errors=[];potentialArrowAt=-1;noArrowAt=[];noArrowParamsConversionAt=[];get maybeInArrowParameters(){return(this.flags&2)>0}set maybeInArrowParameters(e){e?this.flags|=2:this.flags&=-3}get inType(){return(this.flags&4)>0}set inType(e){e?this.flags|=4:this.flags&=-5}get noAnonFunctionType(){return(this.flags&8)>0}set noAnonFunctionType(e){e?this.flags|=8:this.flags&=-9}get hasFlowComment(){return(this.flags&16)>0}set hasFlowComment(e){e?this.flags|=16:this.flags&=-17}get isAmbientContext(){return(this.flags&32)>0}set isAmbientContext(e){e?this.flags|=32:this.flags&=-33}get inAbstractClass(){return(this.flags&64)>0}set inAbstractClass(e){e?this.flags|=64:this.flags&=-65}get inDisallowConditionalTypesContext(){return(this.flags&128)>0}set inDisallowConditionalTypesContext(e){e?this.flags|=128:this.flags&=-129}topicContext={maxNumOfResolvableTopics:0,maxTopicIndex:null};get soloAwait(){return(this.flags&256)>0}set soloAwait(e){e?this.flags|=256:this.flags&=-257}get inFSharpPipelineDirectBody(){return(this.flags&512)>0}set inFSharpPipelineDirectBody(e){e?this.flags|=512:this.flags&=-513}labels=[];commentsLen=0;commentStack=[];pos=0;type=135;value=null;start=0;end=0;lastTokEndLoc=null;lastTokStartLoc=null;context=[X.brace];get canStartJSXElement(){return(this.flags&1024)>0}set canStartJSXElement(e){e?this.flags|=1024:this.flags&=-1025}get containsEsc(){return(this.flags&2048)>0}set containsEsc(e){e?this.flags|=2048:this.flags&=-2049}firstInvalidTemplateEscapePos=null;get hasTopLevelAwait(){return(this.flags&4096)>0}set hasTopLevelAwait(e){e?this.flags|=4096:this.flags&=-4097}strictErrors=new Map;tokensLength=0;curPosition(){return new dN(this.curLine,this.pos-this.lineStart,this.pos+this.startIndex)}clone(){let t=new e;return t.flags=this.flags,t.startIndex=this.startIndex,t.curLine=this.curLine,t.lineStart=this.lineStart,t.startLoc=this.startLoc,t.endLoc=this.endLoc,t.errors=this.errors.slice(),t.potentialArrowAt=this.potentialArrowAt,t.noArrowAt=this.noArrowAt.slice(),t.noArrowParamsConversionAt=this.noArrowParamsConversionAt.slice(),t.topicContext=this.topicContext,t.labels=this.labels.slice(),t.commentsLen=this.commentsLen,t.commentStack=this.commentStack.slice(),t.pos=this.pos,t.type=this.type,t.value=this.value,t.start=this.start,t.end=this.end,t.lastTokEndLoc=this.lastTokEndLoc,t.lastTokStartLoc=this.lastTokStartLoc,t.context=this.context.slice(),t.firstInvalidTemplateEscapePos=this.firstInvalidTemplateEscapePos,t.strictErrors=this.strictErrors,t.tokensLength=this.tokensLength,t}},lF=function(e){return e>=48&&e<=57};const uF={decBinOct:new Set([46,66,69,79,95,98,101,111]),hex:new Set([46,88,95,120])},dF={bin:e=>e===48||e===49,oct:e=>e>=48&&e<=55,dec:e=>e>=48&&e<=57,hex:e=>e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102};function fF(e,t,n,r,i,a){let o=n,s=r,c=i,l=``,u=null,d=n,{length:f}=t;for(;;){if(n>=f){a.unterminated(o,s,c),l+=t.slice(d,n);break}let p=t.charCodeAt(n);if(pF(e,p,t,n)){l+=t.slice(d,n);break}if(p===92){l+=t.slice(d,n);let o=mF(t,n,r,i,e===`template`,a);o.ch===null&&!u?u={pos:n,lineStart:r,curLine:i}:l+=o.ch,{pos:n,lineStart:r,curLine:i}=o,d=n}else p===8232||p===8233?(++n,++i,r=n):p===10||p===13?e===`template`?(l+=t.slice(d,n)+`
|
|
13
|
+
`,++n,p===13&&t.charCodeAt(n)===10&&++n,++i,d=r=n):a.unterminated(o,s,c):++n}return{pos:n,str:l,firstInvalidLoc:u,lineStart:r,curLine:i}}function pF(e,t,n,r){return e===`template`?t===96||t===36&&n.charCodeAt(r+1)===123:t===(e===`double`?34:39)}function mF(e,t,n,r,i,a){let o=!i;t++;let s=e=>({pos:t,ch:e,lineStart:n,curLine:r}),c=e.charCodeAt(t++);switch(c){case 110:return s(`
|
|
14
|
+
`);case 114:return s(`\r`);case 120:{let i;return{code:i,pos:t}=hF(e,t,n,r,2,!1,o,a),s(i===null?null:String.fromCharCode(i))}case 117:{let i;return{code:i,pos:t}=_F(e,t,n,r,o,a),s(i===null?null:String.fromCodePoint(i))}case 116:return s(` `);case 98:return s(`\b`);case 118:return s(`\v`);case 102:return s(`\f`);case 13:e.charCodeAt(t)===10&&++t;case 10:n=t,++r;case 8232:case 8233:return s(``);case 56:case 57:if(i)return s(null);a.strictNumericEscape(t-1,n,r);default:if(c>=48&&c<=55){let o=t-1,c=/^[0-7]+/.exec(e.slice(o,t+2))[0],l=parseInt(c,8);l>255&&(c=c.slice(0,-1),l=parseInt(c,8)),t+=c.length-1;let u=e.charCodeAt(t);if(c!==`0`||u===56||u===57){if(i)return s(null);a.strictNumericEscape(o,n,r)}return s(String.fromCharCode(l))}return s(String.fromCharCode(c))}}function hF(e,t,n,r,i,a,o,s){let c=t,l;return{n:l,pos:t}=gF(e,t,n,r,16,i,a,!1,s,!o),l===null&&(o?s.invalidEscapeSequence(c,n,r):t=c-1),{code:l,pos:t}}function gF(e,t,n,r,i,a,o,s,c,l){let u=t,d=i===16?uF.hex:uF.decBinOct,f=i===16?dF.hex:i===10?dF.dec:i===8?dF.oct:dF.bin,p=!1,m=0;for(let u=0,h=a??1/0;u<h;++u){let a=e.charCodeAt(t),u;if(a===95&&s!==`bail`){let i=e.charCodeAt(t-1),a=e.charCodeAt(t+1);if(!s){if(l)return{n:null,pos:t};c.numericSeparatorInEscapeSequence(t,n,r)}else if(Number.isNaN(a)||!f(a)||d.has(i)||d.has(a)){if(l)return{n:null,pos:t};c.unexpectedNumericSeparator(t,n,r)}++t;continue}if(u=a>=97?a-97+10:a>=65?a-65+10:lF(a)?a-48:1/0,u>=i){if(u<=9&&l)return{n:null,pos:t};if(u<=9&&c.invalidDigit(t,n,r,i))u=0;else if(o)u=0,p=!0;else break}++t,m=m*i+u}return t===u||a!=null&&t-u!==a||p?{n:null,pos:t}:{n:m,pos:t}}function _F(e,t,n,r,i,a){let o=e.charCodeAt(t),s;if(o===123){if(++t,{code:s,pos:t}=hF(e,t,n,r,e.indexOf(`}`,t)-t,!0,i,a),++t,s!==null&&s>1114111)if(i)a.invalidCodePoint(t,n,r);else return{code:null,pos:t}}else ({code:s,pos:t}=hF(e,t,n,r,4,!1,i,a));return{code:s,pos:t}}function vF(e,t,n){return new dN(n,e-t,e)}const yF=new Set([103,109,115,105,121,117,100,118]);var bF=class{constructor(e){let t=e.startIndex||0;this.type=e.type,this.value=e.value,this.start=t+e.start,this.end=t+e.end,this.loc=new fN(e.startLoc,e.endLoc)}},xF=class extends sF{isLookahead;tokens=[];constructor(e,t){super(),this.state=new cF,this.state.init(e),this.input=t,this.length=t.length,this.comments=[],this.isLookahead=!1}pushToken(e){this.tokens.length=this.state.tokensLength,this.tokens.push(e),++this.state.tokensLength}next(){this.checkKeywordEscapes(),this.optionFlags&256&&this.pushToken(new bF(this.state)),this.state.lastTokEndLoc=this.state.endLoc,this.state.lastTokStartLoc=this.state.startLoc,this.nextToken()}eat(e){return this.match(e)?(this.next(),!0):!1}match(e){return this.state.type===e}createLookaheadState(e){return{pos:e.pos,value:null,type:e.type,start:e.start,end:e.end,context:[this.curContext()],inType:e.inType,startLoc:e.startLoc,lastTokEndLoc:e.lastTokEndLoc,curLine:e.curLine,lineStart:e.lineStart,curPosition:e.curPosition}}lookahead(){let e=this.state;this.state=this.createLookaheadState(e),this.isLookahead=!0,this.nextToken(),this.isLookahead=!1;let t=this.state;return this.state=e,t}nextTokenStart(){return this.nextTokenStartSince(this.state.pos)}nextTokenStartSince(e){return GP.lastIndex=e,GP.test(this.input)?GP.lastIndex:e}lookaheadCharCode(){return this.lookaheadCharCodeSince(this.state.pos)}lookaheadCharCodeSince(e){return this.input.charCodeAt(this.nextTokenStartSince(e))}nextTokenInLineStart(){return this.nextTokenInLineStartSince(this.state.pos)}nextTokenInLineStartSince(e){return KP.lastIndex=e,KP.test(this.input)?KP.lastIndex:e}lookaheadInLineCharCode(){return this.input.charCodeAt(this.nextTokenInLineStart())}codePointAtPos(e){let t=this.input.charCodeAt(e);if((t&64512)==55296&&++e<this.input.length){let n=this.input.charCodeAt(e);(n&64512)==56320&&(t=65536+((t&1023)<<10)+(n&1023))}return t}setStrict(e){this.state.strict=e,e&&(this.state.strictErrors.forEach(([e,t])=>this.raise(e,t)),this.state.strictErrors.clear())}curContext(){return this.state.context[this.state.context.length-1]}nextToken(){if(this.skipSpace(),this.state.start=this.state.pos,this.isLookahead||(this.state.startLoc=this.state.curPosition()),this.state.pos>=this.length){this.finishToken(135);return}this.getTokenFromCode(this.codePointAtPos(this.state.pos))}skipBlockComment(e){let t;this.isLookahead||(t=this.state.curPosition());let n=this.state.pos,r=this.input.indexOf(e,n+2);if(r===-1)throw this.raise(G.UnterminatedComment,this.state.curPosition());for(this.state.pos=r+e.length,HP.lastIndex=n+2;HP.test(this.input)&&HP.lastIndex<=r;)++this.state.curLine,this.state.lineStart=HP.lastIndex;if(this.isLookahead)return;let i={type:`CommentBlock`,value:this.input.slice(n+2,r),start:this.sourceToOffsetPos(n),end:this.sourceToOffsetPos(r+e.length),loc:new fN(t,this.state.curPosition())};return this.optionFlags&256&&this.pushToken(i),i}skipLineComment(e){let t=this.state.pos,n;this.isLookahead||(n=this.state.curPosition());let r=this.input.charCodeAt(this.state.pos+=e);if(this.state.pos<this.length)for(;!UP(r)&&++this.state.pos<this.length;)r=this.input.charCodeAt(this.state.pos);if(this.isLookahead)return;let i=this.state.pos,a={type:`CommentLine`,value:this.input.slice(t+e,i),start:this.sourceToOffsetPos(t),end:this.sourceToOffsetPos(i),loc:new fN(n,this.state.curPosition())};return this.optionFlags&256&&this.pushToken(a),a}skipSpace(){let e=this.state.pos,t=this.optionFlags&4096?[]:null;loop:for(;this.state.pos<this.length;){let n=this.input.charCodeAt(this.state.pos);switch(n){case 32:case 160:case 9:++this.state.pos;break;case 13:this.input.charCodeAt(this.state.pos+1)===10&&++this.state.pos;case 10:case 8232:case 8233:++this.state.pos,++this.state.curLine,this.state.lineStart=this.state.pos;break;case 47:switch(this.input.charCodeAt(this.state.pos+1)){case 42:{let e=this.skipBlockComment(`*/`);e!==void 0&&(this.addComment(e),t?.push(e));break}case 47:{let e=this.skipLineComment(2);e!==void 0&&(this.addComment(e),t?.push(e));break}default:break loop}break;default:if(qP(n))++this.state.pos;else if(n===45&&!this.inModule&&this.optionFlags&8192){let n=this.state.pos;if(this.input.charCodeAt(n+1)===45&&this.input.charCodeAt(n+2)===62&&(e===0||this.state.lineStart>e)){let e=this.skipLineComment(3);e!==void 0&&(this.addComment(e),t?.push(e))}else break loop}else if(n===60&&!this.inModule&&this.optionFlags&8192){let e=this.state.pos;if(this.input.charCodeAt(e+1)===33&&this.input.charCodeAt(e+2)===45&&this.input.charCodeAt(e+3)===45){let e=this.skipLineComment(4);e!==void 0&&(this.addComment(e),t?.push(e))}else break loop}else break loop}}if(t?.length>0){let n=this.state.pos,r={start:this.sourceToOffsetPos(e),end:this.sourceToOffsetPos(n),comments:t,leadingNode:null,trailingNode:null,containingNode:null};this.state.commentStack.push(r)}}finishToken(e,t){this.state.end=this.state.pos,this.state.endLoc=this.state.curPosition();let n=this.state.type;this.state.type=e,this.state.value=t,this.isLookahead||this.updateContext(n)}replaceToken(e){this.state.type=e,this.updateContext()}readToken_numberSign(){if(this.state.pos===0&&this.readToken_interpreter())return;let e=this.state.pos+1,t=this.codePointAtPos(e);if(t>=48&&t<=57)throw this.raise(G.UnexpectedDigitAfterHash,this.state.curPosition());gP(t)?(++this.state.pos,this.finishToken(134,this.readWord1(t))):t===92?(++this.state.pos,this.finishToken(134,this.readWord1())):this.finishOp(23,1)}readToken_dot(){let e=this.input.charCodeAt(this.state.pos+1);if(e>=48&&e<=57){this.readNumber(!0);return}e===46&&this.input.charCodeAt(this.state.pos+2)===46?(this.state.pos+=3,this.finishToken(17)):(++this.state.pos,this.finishToken(12))}readToken_slash(){this.input.charCodeAt(this.state.pos+1)===61?this.finishOp(27,2):this.finishOp(52,1)}readToken_interpreter(){if(this.state.pos!==0||this.length<2)return!1;let e=this.input.charCodeAt(this.state.pos+1);if(e!==33)return!1;let t=this.state.pos;for(this.state.pos+=1;!UP(e)&&++this.state.pos<this.length;)e=this.input.charCodeAt(this.state.pos);let n=this.input.slice(t+2,this.state.pos);return this.finishToken(24,n),!0}readToken_mult_modulo(e){let t=e===42?51:50,n=1,r=this.input.charCodeAt(this.state.pos+1);e===42&&r===42&&(n++,r=this.input.charCodeAt(this.state.pos+2),t=53),r===61&&!this.state.inType&&(n++,t=e===37?29:26),this.finishOp(t,n)}readToken_pipe_amp(e){let t=this.input.charCodeAt(this.state.pos+1);if(t===e){this.input.charCodeAt(this.state.pos+2)===61?this.finishOp(26,3):this.finishOp(e===124?37:38,2);return}if(e===124&&t===62){this.finishOp(35,2);return}if(t===61){this.finishOp(26,2);return}this.finishOp(e===124?39:41,1)}readToken_caret(){let e=this.input.charCodeAt(this.state.pos+1);e===61&&!this.state.inType?this.finishOp(28,2):e===94&&this.hasPlugin([`pipelineOperator`,{proposal:`hack`,topicToken:`^^`}])?(this.finishOp(33,2),this.input.codePointAt(this.state.pos)===94&&this.unexpected()):this.finishOp(40,1)}readToken_atSign(){this.input.charCodeAt(this.state.pos+1)===64&&this.hasPlugin([`pipelineOperator`,{proposal:`hack`,topicToken:`@@`}])?this.finishOp(34,2):this.finishOp(22,1)}readToken_plus_min(e){let t=this.input.charCodeAt(this.state.pos+1);if(t===e){this.finishOp(30,2);return}t===61?this.finishOp(26,2):this.finishOp(49,1)}readToken_lt(){let{pos:e}=this.state,t=this.input.charCodeAt(e+1);if(t===60){if(this.input.charCodeAt(e+2)===61){this.finishOp(26,3);return}this.finishOp(47,2);return}if(t===61){this.finishOp(45,2);return}this.finishOp(43,1)}readToken_gt(){let{pos:e}=this.state,t=this.input.charCodeAt(e+1);if(t===62){let t=this.input.charCodeAt(e+2)===62?3:2;if(this.input.charCodeAt(e+t)===61){this.finishOp(26,t+1);return}this.finishOp(48,t);return}if(t===61){this.finishOp(45,2);return}this.finishOp(44,1)}readToken_eq_excl(e){let t=this.input.charCodeAt(this.state.pos+1);if(t===61){this.finishOp(42,this.input.charCodeAt(this.state.pos+2)===61?3:2);return}if(e===61&&t===62){this.state.pos+=2,this.finishToken(15);return}this.finishOp(e===61?25:31,1)}readToken_question(){let e=this.input.charCodeAt(this.state.pos+1),t=this.input.charCodeAt(this.state.pos+2);e===63?t===61?this.finishOp(26,3):this.finishOp(36,2):e===46&&!(t>=48&&t<=57)?(this.state.pos+=2,this.finishToken(14)):(++this.state.pos,this.finishToken(13))}getTokenFromCode(e){switch(e){case 46:this.readToken_dot();return;case 40:++this.state.pos,this.finishToken(6);return;case 41:++this.state.pos,this.finishToken(7);return;case 59:++this.state.pos,this.finishToken(9);return;case 44:++this.state.pos,this.finishToken(8);return;case 91:++this.state.pos,this.finishToken(0);return;case 93:++this.state.pos,this.finishToken(1);return;case 123:++this.state.pos,this.finishToken(2);return;case 125:++this.state.pos,this.finishToken(4);return;case 58:this.hasPlugin(`functionBind`)&&this.input.charCodeAt(this.state.pos+1)===58?this.finishOp(11,2):(++this.state.pos,this.finishToken(10));return;case 63:this.readToken_question();return;case 96:this.readTemplateToken();return;case 48:{let e=this.input.charCodeAt(this.state.pos+1);if(e===120||e===88){this.readRadixNumber(16);return}if(e===111||e===79){this.readRadixNumber(8);return}if(e===98||e===66){this.readRadixNumber(2);return}}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:this.readNumber(!1);return;case 34:case 39:this.readString(e);return;case 47:this.readToken_slash();return;case 37:case 42:this.readToken_mult_modulo(e);return;case 124:case 38:this.readToken_pipe_amp(e);return;case 94:this.readToken_caret();return;case 43:case 45:this.readToken_plus_min(e);return;case 60:this.readToken_lt();return;case 62:this.readToken_gt();return;case 61:case 33:this.readToken_eq_excl(e);return;case 126:this.finishOp(32,1);return;case 64:this.readToken_atSign();return;case 35:this.readToken_numberSign();return;case 92:this.readWord();return;default:if(gP(e)){this.readWord(e);return}}throw this.raise(G.InvalidOrUnexpectedToken,this.state.curPosition(),{unexpected:String.fromCodePoint(e)})}finishOp(e,t){let n=this.input.slice(this.state.pos,this.state.pos+t);this.state.pos+=t,this.finishToken(e,n)}readRegexp(){let e=this.state.startLoc,t=this.state.start+1,n,r,{pos:i}=this.state;for(;;++i){if(i>=this.length)throw this.raise(G.UnterminatedRegExp,pN(e,1));let t=this.input.charCodeAt(i);if(UP(t))throw this.raise(G.UnterminatedRegExp,pN(e,1));if(n)n=!1;else{if(t===91)r=!0;else if(t===93&&r)r=!1;else if(t===47&&!r)break;n=t===92}}let a=this.input.slice(t,i);++i;let o=``,s=()=>pN(e,i+2-t);for(;i<this.length;){let e=this.codePointAtPos(i),t=String.fromCharCode(e);if(yF.has(e))e===118?o.includes(`u`)&&this.raise(G.IncompatibleRegExpUVFlags,s()):e===117&&o.includes(`v`)&&this.raise(G.IncompatibleRegExpUVFlags,s()),o.includes(t)&&this.raise(G.DuplicateRegExpFlags,s());else if(_P(e)||e===92)this.raise(G.MalformedRegExpFlags,s());else break;++i,o+=t}this.state.pos=i,this.finishToken(133,{pattern:a,flags:o})}readInt(e,t,n=!1,r=!0){let{n:i,pos:a}=gF(this.input,this.state.pos,this.state.lineStart,this.state.curLine,e,t,n,r,this.errorHandlers_readInt,!1);return this.state.pos=a,i}readRadixNumber(e){let t=this.state.pos,n=this.state.curPosition(),r=!1;this.state.pos+=2;let i=this.readInt(e);if(i??this.raise(G.InvalidDigit,pN(n,2),{radix:e}),this.input.charCodeAt(this.state.pos)===110&&(++this.state.pos,r=!0),gP(this.codePointAtPos(this.state.pos)))throw this.raise(G.NumberIdentifier,this.state.curPosition());if(r){let e=this.input.slice(t,this.state.pos).replace(/[_n]/g,``);this.finishToken(132,e);return}this.finishToken(131,i)}readNumber(e){let t=this.state.pos,n=this.state.curPosition(),r=!1,i=!1,a=!1;!e&&this.readInt(10)===null&&this.raise(G.InvalidNumber,this.state.curPosition());let o=this.state.pos-t>=2&&this.input.charCodeAt(t)===48;if(o){let e=this.input.slice(t,this.state.pos);if(this.recordStrictModeErrors(G.StrictOctalLiteral,n),!this.state.strict){let t=e.indexOf(`_`);t>0&&this.raise(G.ZeroDigitNumericSeparator,pN(n,t))}a=o&&!/[89]/.test(e)}let s=this.input.charCodeAt(this.state.pos);if(s===46&&!a&&(++this.state.pos,this.readInt(10),r=!0,s=this.input.charCodeAt(this.state.pos)),(s===69||s===101)&&!a&&(s=this.input.charCodeAt(++this.state.pos),(s===43||s===45)&&++this.state.pos,this.readInt(10)===null&&this.raise(G.InvalidOrMissingExponent,n),r=!0,s=this.input.charCodeAt(this.state.pos)),s===110&&((r||o)&&this.raise(G.InvalidBigIntLiteral,n),++this.state.pos,i=!0),gP(this.codePointAtPos(this.state.pos)))throw this.raise(G.NumberIdentifier,this.state.curPosition());let c=this.input.slice(t,this.state.pos).replace(/[_mn]/g,``);if(i){this.finishToken(132,c);return}let l=a?parseInt(c,8):parseFloat(c);this.finishToken(131,l)}readCodePoint(e){let{code:t,pos:n}=_F(this.input,this.state.pos,this.state.lineStart,this.state.curLine,e,this.errorHandlers_readCodePoint);return this.state.pos=n,t}readString(e){let{str:t,pos:n,curLine:r,lineStart:i}=fF(e===34?`double`:`single`,this.input,this.state.pos+1,this.state.lineStart,this.state.curLine,this.errorHandlers_readStringContents_string);this.state.pos=n+1,this.state.lineStart=i,this.state.curLine=r,this.finishToken(130,t)}readTemplateContinuation(){this.match(4)||this.unexpected(null,4),this.state.pos--,this.readTemplateToken()}readTemplateToken(){let e=this.input[this.state.pos],{str:t,firstInvalidLoc:n,pos:r,curLine:i,lineStart:a}=fF(`template`,this.input,this.state.pos+1,this.state.lineStart,this.state.curLine,this.errorHandlers_readStringContents_template);this.state.pos=r+1,this.state.lineStart=a,this.state.curLine=i,n&&(this.state.firstInvalidTemplateEscapePos=new dN(n.curLine,n.pos-n.lineStart,this.sourceToOffsetPos(n.pos))),this.input.codePointAt(r)===96?this.finishToken(20,n?null:e+t+"`"):(this.state.pos++,this.finishToken(21,n?null:e+t+"${"))}recordStrictModeErrors(e,t){let n=t.index;this.state.strict&&!this.state.strictErrors.has(n)?this.raise(e,t):this.state.strictErrors.set(n,[e,t])}readWord1(e){this.state.containsEsc=!1;let t=``,n=this.state.pos,r=this.state.pos;for(e!==void 0&&(this.state.pos+=e<=65535?1:2);this.state.pos<this.length;){let e=this.codePointAtPos(this.state.pos);if(_P(e))this.state.pos+=e<=65535?1:2;else if(e===92){this.state.containsEsc=!0,t+=this.input.slice(r,this.state.pos);let e=this.state.curPosition(),i=this.state.pos===n?gP:_P;if(this.input.charCodeAt(++this.state.pos)!==117){this.raise(G.MissingUnicodeEscape,this.state.curPosition()),r=this.state.pos-1;continue}++this.state.pos;let a=this.readCodePoint(!0);a!==null&&(i(a)||this.raise(G.EscapedCharNotAnIdentifier,e),t+=String.fromCodePoint(a)),r=this.state.pos}else break}return t+this.input.slice(r,this.state.pos)}readWord(e){let t=this.readWord1(e),n=NN.get(t);n===void 0?this.finishToken(128,t):this.finishToken(n,rP(n))}checkKeywordEscapes(){let{type:e}=this.state;ZN(e)&&this.state.containsEsc&&this.raise(G.InvalidEscapedReservedWord,this.state.startLoc,{reservedWord:rP(e)})}raise(e,t,n={}){let r=e(t instanceof dN?t:t.loc.start,n);if(!(this.optionFlags&2048))throw r;return this.isLookahead||this.state.errors.push(r),r}raiseOverwrite(e,t,n={}){let r=t instanceof dN?t:t.loc.start,i=r.index,a=this.state.errors;for(let t=a.length-1;t>=0;t--){let o=a[t];if(o.loc.index===i)return a[t]=e(r,n);if(o.loc.index<i)break}return this.raise(e,t,n)}updateContext(e){}unexpected(e,t){throw this.raise(G.UnexpectedToken,e??this.state.startLoc,{expected:t?rP(t):null})}expectPlugin(e,t){if(this.hasPlugin(e))return!0;throw this.raise(G.MissingPlugin,t??this.state.startLoc,{missingPlugin:[e]})}expectOnePlugin(e){if(!e.some(e=>this.hasPlugin(e)))throw this.raise(G.MissingOneOfPlugins,this.state.startLoc,{missingPlugin:e})}errorBuilder(e){return(t,n,r)=>{this.raise(e,vF(t,n,r))}}errorHandlers_readInt={invalidDigit:(e,t,n,r)=>this.optionFlags&2048?(this.raise(G.InvalidDigit,vF(e,t,n),{radix:r}),!0):!1,numericSeparatorInEscapeSequence:this.errorBuilder(G.NumericSeparatorInEscapeSequence),unexpectedNumericSeparator:this.errorBuilder(G.UnexpectedNumericSeparator)};errorHandlers_readCodePoint={...this.errorHandlers_readInt,invalidEscapeSequence:this.errorBuilder(G.InvalidEscapeSequence),invalidCodePoint:this.errorBuilder(G.InvalidCodePoint)};errorHandlers_readStringContents_string={...this.errorHandlers_readCodePoint,strictNumericEscape:(e,t,n)=>{this.recordStrictModeErrors(G.StrictNumericEscape,vF(e,t,n))},unterminated:(e,t,n)=>{throw this.raise(G.UnterminatedString,vF(e-1,t,n))}};errorHandlers_readStringContents_template={...this.errorHandlers_readCodePoint,strictNumericEscape:this.errorBuilder(G.StrictNumericEscape),unterminated:(e,t,n)=>{throw this.raise(G.UnterminatedTemplate,vF(e,t,n))}}},SF=class{privateNames=new Set;loneAccessors=new Map;undefinedPrivateNames=new Map},CF=class{parser;stack=[];undefinedPrivateNames=new Map;constructor(e){this.parser=e}current(){return this.stack[this.stack.length-1]}enter(){this.stack.push(new SF)}exit(){let e=this.stack.pop(),t=this.current();for(let[n,r]of Array.from(e.undefinedPrivateNames))t?t.undefinedPrivateNames.has(n)||t.undefinedPrivateNames.set(n,r):this.parser.raise(G.InvalidPrivateFieldResolution,r,{identifierName:n})}declarePrivateName(e,t,n){let{privateNames:r,loneAccessors:i,undefinedPrivateNames:a}=this.current(),o=r.has(e);if(t&3){let n=o&&i.get(e);if(n){let r=n&4,a=t&4;o=(n&3)==(t&3)||r!==a,o||i.delete(e)}else o||i.set(e,t)}o&&this.parser.raise(G.PrivateNameRedeclaration,n,{identifierName:e}),r.add(e),a.delete(e)}usePrivateName(e,t){let n;for(n of this.stack)if(n.privateNames.has(e))return;n?n.undefinedPrivateNames.set(e,t):this.parser.raise(G.InvalidPrivateFieldResolution,t,{identifierName:e})}},wF=class{constructor(e=0){this.type=e}canBeArrowParameterDeclaration(){return this.type===2||this.type===1}isCertainlyParameterDeclaration(){return this.type===3}},TF=class extends wF{declarationErrors=new Map;constructor(e){super(e)}recordDeclarationError(e,t){let n=t.index;this.declarationErrors.set(n,[e,t])}clearDeclarationError(e){this.declarationErrors.delete(e)}iterateErrors(e){this.declarationErrors.forEach(e)}},EF=class{parser;stack=[new wF];constructor(e){this.parser=e}enter(e){this.stack.push(e)}exit(){this.stack.pop()}recordParameterInitializerError(e,t){let n=t.loc.start,{stack:r}=this,i=r.length-1,a=r[i];for(;!a.isCertainlyParameterDeclaration();){if(a.canBeArrowParameterDeclaration())a.recordDeclarationError(e,n);else return;a=r[--i]}this.parser.raise(e,n)}recordArrowParameterBindingError(e,t){let{stack:n}=this,r=n[n.length-1],i=t.loc.start;if(r.isCertainlyParameterDeclaration())this.parser.raise(e,i);else if(r.canBeArrowParameterDeclaration())r.recordDeclarationError(e,i);else return}recordAsyncArrowParametersError(e){let{stack:t}=this,n=t.length-1,r=t[n];for(;r.canBeArrowParameterDeclaration();)r.type===2&&r.recordDeclarationError(G.AwaitBindingIdentifier,e),r=t[--n]}validateAsPattern(){let{stack:e}=this,t=e[e.length-1];t.canBeArrowParameterDeclaration()&&t.iterateErrors(([t,n])=>{this.parser.raise(t,n);let r=e.length-2,i=e[r];for(;i.canBeArrowParameterDeclaration();)i.clearDeclarationError(n.index),i=e[--r]})}};function DF(){return new wF(3)}function OF(){return new TF(1)}function kF(){return new TF(2)}function AF(){return new wF}var jF=class extends xF{addExtra(e,t,n,r=!0){if(!e)return;let{extra:i}=e;i??(i={},e.extra=i),r?i[t]=n:Object.defineProperty(i,t,{enumerable:r,value:n})}isContextual(e){return this.state.type===e&&!this.state.containsEsc}isUnparsedContextual(e,t){if(this.input.startsWith(t,e)){let n=this.input.charCodeAt(e+t.length);return!(_P(n)||(n&64512)==55296)}return!1}isLookaheadContextual(e){let t=this.nextTokenStart();return this.isUnparsedContextual(t,e)}eatContextual(e){return this.isContextual(e)?(this.next(),!0):!1}expectContextual(e,t){if(!this.eatContextual(e)){if(t!=null)throw this.raise(t,this.state.startLoc);this.unexpected(null,e)}}canInsertSemicolon(){return this.match(135)||this.match(4)||this.hasPrecedingLineBreak()}hasPrecedingLineBreak(){return WP(this.input,this.offsetToSourcePos(this.state.lastTokEndLoc.index),this.state.start)}hasFollowingLineBreak(){return WP(this.input,this.state.end,this.nextTokenStart())}isLineTerminator(){return this.eat(9)||this.canInsertSemicolon()}semicolon(e=!0){(e?this.isLineTerminator():this.eat(9))||this.raise(G.MissingSemicolon,this.state.lastTokEndLoc)}expect(e,t){this.eat(e)||this.unexpected(t,e)}tryParse(e,t=this.state.clone()){let n={node:null};try{let r=e((e=null)=>{throw n.node=e,n});if(this.state.errors.length>t.errors.length){let e=this.state;return this.state=t,this.state.tokensLength=e.tokensLength,{node:r,error:e.errors[t.errors.length],thrown:!1,aborted:!1,failState:e}}return{node:r,error:null,thrown:!1,aborted:!1,failState:null}}catch(e){let r=this.state;if(this.state=t,e instanceof SyntaxError)return{node:null,error:e,thrown:!0,aborted:!1,failState:r};if(e===n)return{node:n.node,error:null,thrown:!1,aborted:!0,failState:r};throw e}}checkExpressionErrors(e,t){if(!e)return!1;let{shorthandAssignLoc:n,doubleProtoLoc:r,privateKeyLoc:i,optionalParametersLoc:a,voidPatternLoc:o}=e,s=!!n||!!r||!!a||!!i||!!o;if(!t)return s;n!=null&&this.raise(G.InvalidCoverInitializedName,n),r!=null&&this.raise(G.DuplicateProto,r),i!=null&&this.raise(G.UnexpectedPrivateField,i),a!=null&&this.unexpected(a),o!=null&&this.raise(G.InvalidCoverDiscardElement,o)}isLiteralPropertyName(){return GN(this.state.type)}isPrivateName(e){return e.type===`PrivateName`}getPrivateNameSV(e){return e.id.name}hasPropertyAsPrivateName(e){return(e.type===`MemberExpression`||e.type===`OptionalMemberExpression`)&&this.isPrivateName(e.property)}isObjectProperty(e){return e.type===`ObjectProperty`}isObjectMethod(e){return e.type===`ObjectMethod`}initializeScopes(e=this.options.sourceType===`module`){let t=this.state.labels;this.state.labels=[];let n=this.exportedIdentifiers;this.exportedIdentifiers=new Set;let r=this.inModule;this.inModule=e;let i=this.scope;this.scope=new(this.getScopeHandler())(this,e);let a=this.prodParam;this.prodParam=new eF;let o=this.classScope;this.classScope=new CF(this);let s=this.expressionScope;return this.expressionScope=new EF(this),()=>{this.state.labels=t,this.exportedIdentifiers=n,this.inModule=r,this.scope=i,this.prodParam=a,this.classScope=o,this.expressionScope=s}}enterInitialScopes(){let e=0;(this.inModule||this.optionFlags&1)&&(e|=2),this.optionFlags&32&&(e|=1);let t=!this.inModule&&this.options.sourceType===`commonjs`;(t||this.optionFlags&2)&&(e|=4),this.prodParam.enter(e);let n=t?514:1;this.optionFlags&4&&(n|=512),this.optionFlags&16&&(n|=48),this.scope.enter(n)}checkDestructuringPrivate(e){let{privateKeyLoc:t}=e;t!==null&&this.expectPlugin(`destructuringPrivate`,t)}},MF=class{shorthandAssignLoc=null;doubleProtoLoc=null;privateKeyLoc=null;optionalParametersLoc=null;voidPatternLoc=null},NF=class{constructor(e,t,n){this.start=t,this.end=0,this.loc=new fN(n),e?.optionFlags&128&&(this.range=[t,0]),e?.filename&&(this.loc.filename=e.filename)}type=``};const PF=NF.prototype;var FF=class extends jF{startNode(){let e=this.state.startLoc;return new NF(this,e.index,e)}startNodeAt(e){return new NF(this,e.index,e)}startNodeAtNode(e){return this.startNodeAt(e.loc.start)}finishNode(e,t){return this.finishNodeAt(e,t,this.state.lastTokEndLoc)}finishNodeAt(e,t,n){if(process.env.NODE_ENV!==`production`&&e.end>0)throw Error(`Do not call finishNode*() twice on the same node. Instead use resetEndLocation() or change type directly.`);return e.type=t,e.end=n.index,e.loc.end=n,this.optionFlags&128&&(e.range[1]=n.index),this.optionFlags&4096&&this.processComment(e),e}resetStartLocation(e,t){e.start=t.index,e.loc.start=t,this.optionFlags&128&&(e.range[0]=t.index)}resetEndLocation(e,t=this.state.lastTokEndLoc){e.end=t.index,e.loc.end=t,this.optionFlags&128&&(e.range[1]=t.index)}resetStartLocationFromNode(e,t){this.resetStartLocation(e,t.loc.start)}castNodeTo(e,t){return e.type=t,e}cloneIdentifier(e){let{type:t,start:n,end:r,loc:i,range:a,name:o}=e,s=Object.create(PF);return s.type=t,s.start=n,s.end=r,s.loc=i,s.range=a,s.name=o,e.extra&&(s.extra=e.extra),s}cloneStringLiteral(e){let{type:t,start:n,end:r,loc:i,range:a,extra:o}=e,s=Object.create(PF);return s.type=t,s.start=n,s.end=r,s.loc=i,s.range=a,s.extra=o,s.value=e.value,s}};const IF=e=>e.type===`ParenthesizedExpression`?IF(e.expression):e;var LF=class extends FF{toAssignable(e,t=!1){let n;switch((e.type===`ParenthesizedExpression`||e.extra?.parenthesized)&&(n=IF(e),t?n.type===`Identifier`?this.expressionScope.recordArrowParameterBindingError(G.InvalidParenthesizedAssignment,e):n.type!==`CallExpression`&&n.type!==`MemberExpression`&&!this.isOptionalMemberExpression(n)&&this.raise(G.InvalidParenthesizedAssignment,e):this.raise(G.InvalidParenthesizedAssignment,e)),e.type){case`Identifier`:case`ObjectPattern`:case`ArrayPattern`:case`AssignmentPattern`:case`RestElement`:case`VoidPattern`:break;case`ObjectExpression`:this.castNodeTo(e,`ObjectPattern`);for(let n=0,r=e.properties.length,i=r-1;n<r;n++){let r=e.properties[n],a=n===i;this.toAssignableObjectExpressionProp(r,a,t),a&&r.type===`RestElement`&&e.extra?.trailingCommaLoc&&this.raise(G.RestTrailingComma,e.extra.trailingCommaLoc)}break;case`ObjectProperty`:{let{key:n,value:r}=e;this.isPrivateName(n)&&this.classScope.usePrivateName(this.getPrivateNameSV(n),n.loc.start),this.toAssignable(r,t);break}case`SpreadElement`:throw Error(`Internal @babel/parser error (this is a bug, please report it). SpreadElement should be converted by .toAssignable's caller.`);case`ArrayExpression`:this.castNodeTo(e,`ArrayPattern`),this.toAssignableList(e.elements,e.extra?.trailingCommaLoc,t);break;case`AssignmentExpression`:e.operator!==`=`&&this.raise(G.MissingEqInAssignment,e.left.loc.end),this.castNodeTo(e,`AssignmentPattern`),delete e.operator,e.left.type===`VoidPattern`&&this.raise(G.VoidPatternInitializer,e.left),this.toAssignable(e.left,t);break;case`ParenthesizedExpression`:this.toAssignable(n,t);break}}toAssignableObjectExpressionProp(e,t,n){if(e.type===`ObjectMethod`)this.raise(e.kind===`get`||e.kind===`set`?G.PatternHasAccessor:G.PatternHasMethod,e.key);else if(e.type===`SpreadElement`){this.castNodeTo(e,`RestElement`);let r=e.argument;this.checkToRestConversion(r,!1),this.toAssignable(r,n),t||this.raise(G.RestTrailingComma,e)}else this.toAssignable(e,n)}toAssignableList(e,t,n){let r=e.length-1;for(let i=0;i<=r;i++){let a=e[i];a&&(this.toAssignableListItem(e,i,n),a.type===`RestElement`&&(i<r?this.raise(G.RestTrailingComma,a):t&&this.raise(G.RestTrailingComma,t)))}}toAssignableListItem(e,t,n){let r=e[t];if(r.type===`SpreadElement`){this.castNodeTo(r,`RestElement`);let e=r.argument;this.checkToRestConversion(e,!0),this.toAssignable(e,n)}else this.toAssignable(r,n)}isAssignable(e,t){switch(e.type){case`Identifier`:case`ObjectPattern`:case`ArrayPattern`:case`AssignmentPattern`:case`RestElement`:case`VoidPattern`:return!0;case`ObjectExpression`:{let t=e.properties.length-1;return e.properties.every((e,n)=>e.type!==`ObjectMethod`&&(n===t||e.type!==`SpreadElement`)&&this.isAssignable(e))}case`ObjectProperty`:return this.isAssignable(e.value);case`SpreadElement`:return this.isAssignable(e.argument);case`ArrayExpression`:return e.elements.every(e=>e===null||this.isAssignable(e));case`AssignmentExpression`:return e.operator===`=`;case`ParenthesizedExpression`:return this.isAssignable(e.expression);case`MemberExpression`:case`OptionalMemberExpression`:return!t;default:return!1}}toReferencedList(e,t){return e}toReferencedListDeep(e,t){this.toReferencedList(e,t);for(let t of e)t?.type===`ArrayExpression`&&this.toReferencedListDeep(t.elements)}parseSpread(e){let t=this.startNode();return this.next(),t.argument=this.parseMaybeAssignAllowIn(e,void 0),this.finishNode(t,`SpreadElement`)}parseRestBinding(){let e=this.startNode();this.next();let t=this.parseBindingAtom();return t.type===`VoidPattern`&&this.raise(G.UnexpectedVoidPattern,t),e.argument=t,this.finishNode(e,`RestElement`)}parseBindingAtom(){switch(this.state.type){case 0:{let e=this.startNode();return this.next(),e.elements=this.parseBindingList(1,93,1),this.finishNode(e,`ArrayPattern`)}case 2:return this.parseObjectLike(4,!0);case 84:return this.parseVoidPattern(null)}return this.parseIdentifier()}parseBindingList(e,t,n){let r=n&1,i=[],a=!0;for(;!this.eat(e);)if(a?a=!1:this.expect(8),r&&this.match(8))i.push(null);else if(this.eat(e))break;else if(this.match(17)){let r=this.parseRestBinding();if(n&2&&(r=this.parseFunctionParamType(r)),i.push(r),!this.checkCommaAfterRest(t)){this.expect(e);break}}else{let e=[];if(n&2)for(this.match(22)&&this.hasPlugin(`decorators`)&&this.raise(G.UnsupportedParameterDecorator,this.state.startLoc);this.match(22);)e.push(this.parseDecorator());i.push(this.parseBindingElement(n,e))}return i}parseBindingRestProperty(e){return this.next(),this.hasPlugin(`discardBinding`)&&this.match(84)?(e.argument=this.parseVoidPattern(null),this.raise(G.UnexpectedVoidPattern,e.argument)):e.argument=this.parseIdentifier(),this.checkCommaAfterRest(125),this.finishNode(e,`RestElement`)}parseBindingProperty(){let{type:e,startLoc:t}=this.state;if(e===17)return this.parseBindingRestProperty(this.startNode());let n=this.startNode();return e===134?(this.expectPlugin(`destructuringPrivate`,t),this.classScope.usePrivateName(this.state.value,t),n.key=this.parsePrivateName()):this.parsePropertyName(n),n.method=!1,this.parseObjPropValue(n,t,!1,!1,!0,!1)}parseBindingElement(e,t){let n=this.parseMaybeDefault();return e&2&&this.parseFunctionParamType(n),t.length&&(n.decorators=t,this.resetStartLocationFromNode(n,t[0])),this.parseMaybeDefault(n.loc.start,n)}parseFunctionParamType(e){return e}parseMaybeDefault(e,t){if(e??=this.state.startLoc,t??=this.parseBindingAtom(),!this.eat(25))return t;let n=this.startNodeAt(e);return t.type===`VoidPattern`&&this.raise(G.VoidPatternInitializer,t),n.left=t,n.right=this.parseMaybeAssignAllowIn(),this.finishNode(n,`AssignmentPattern`)}isValidLVal(e,t,n,r){switch(e){case`AssignmentPattern`:return`left`;case`RestElement`:return`argument`;case`ObjectProperty`:return`value`;case`ParenthesizedExpression`:return`expression`;case`ArrayPattern`:return`elements`;case`ObjectPattern`:return`properties`;case`VoidPattern`:return!0;case`CallExpression`:if(!t&&!this.state.strict&&this.optionFlags&8192)return!0}return!1}isOptionalMemberExpression(e){return e.type===`OptionalMemberExpression`}checkLVal(e,t,n=64,r=!1,i=!1,a=!1,o=!1){let s=e.type;if(this.isObjectMethod(e))return;let c=this.isOptionalMemberExpression(e);if(c||s===`MemberExpression`){c&&(this.expectPlugin(`optionalChainingAssign`,e.loc.start),t.type!==`AssignmentExpression`&&this.raise(G.InvalidLhsOptionalChaining,e,{ancestor:t})),n!==64&&this.raise(G.InvalidPropertyBindingPattern,e);return}if(s===`Identifier`){this.checkIdentifier(e,n,i);let{name:t}=e;r&&(r.has(t)?this.raise(G.ParamDupe,e):r.add(t));return}else s===`VoidPattern`&&t.type===`CatchClause`&&this.raise(G.VoidPatternCatchClauseParam,e);let l=IF(e);o||=l.type===`CallExpression`&&(l.callee.type===`Import`||l.callee.type===`Super`);let u=this.isValidLVal(s,o,!(a||e.extra?.parenthesized)&&t.type===`AssignmentExpression`,n);if(u===!0)return;if(u===!1){let r=n===64?G.InvalidLhs:G.InvalidLhsBinding;this.raise(r,e,{ancestor:t});return}let d,f;typeof u==`string`?(d=u,f=s===`ParenthesizedExpression`):[d,f]=u;let p=s===`ArrayPattern`||s===`ObjectPattern`?{type:s}:t,m=e[d];if(Array.isArray(m))for(let e of m)e&&this.checkLVal(e,p,n,r,i,f,!0);else m&&this.checkLVal(m,p,n,r,i,f,o)}checkIdentifier(e,t,n=!1){this.state.strict&&(n?TP(e.name,this.inModule):wP(e.name))&&(t===64?this.raise(G.StrictEvalArguments,e,{referenceName:e.name}):this.raise(G.StrictEvalArgumentsBinding,e,{bindingName:e.name})),t&8192&&e.name===`let`&&this.raise(G.LetInLexicalBinding,e),t&64||this.declareNameFromIdentifier(e,t)}declareNameFromIdentifier(e,t){this.scope.declareName(e.name,t,e.loc.start)}checkToRestConversion(e,t){switch(e.type){case`ParenthesizedExpression`:this.checkToRestConversion(e.expression,t);break;case`Identifier`:case`MemberExpression`:break;case`ArrayExpression`:case`ObjectExpression`:if(t)break;default:this.raise(G.InvalidRestAssignmentPattern,e)}}checkCommaAfterRest(e){return this.match(8)?(this.raise(this.lookaheadCharCode()===e?G.RestTrailingComma:G.ElementAfterRest,this.state.startLoc),!0):!1}};const RF=/in(?:stanceof)?|as|satisfies/y;function zF(e){if(e==null)throw Error(`Unexpected ${e} value.`);return e}function BF(e){if(!e)throw Error(`Assert fail`)}const Q=TN`typescript`({AbstractMethodHasImplementation:({methodName:e})=>`Method '${e}' cannot have an implementation because it is marked abstract.`,AbstractPropertyHasInitializer:({propertyName:e})=>`Property '${e}' cannot have an initializer because it is marked abstract.`,AccessorCannotBeOptional:`An 'accessor' property cannot be declared optional.`,AccessorCannotDeclareThisParameter:`'get' and 'set' accessors cannot declare 'this' parameters.`,AccessorCannotHaveTypeParameters:`An accessor cannot have type parameters.`,ClassMethodHasDeclare:`Class methods cannot have the 'declare' modifier.`,ClassMethodHasReadonly:`Class methods cannot have the 'readonly' modifier.`,ConstInitializerMustBeStringOrNumericLiteralOrLiteralEnumReference:`A 'const' initializer in an ambient context must be a string or numeric literal or literal enum reference.`,ConstructorHasTypeParameters:`Type parameters cannot appear on a constructor declaration.`,DeclareAccessor:({kind:e})=>`'declare' is not allowed in ${e}ters.`,DeclareClassFieldHasInitializer:`Initializers are not allowed in ambient contexts.`,DeclareFunctionHasImplementation:`An implementation cannot be declared in ambient contexts.`,DuplicateAccessibilityModifier:({modifier:e})=>`Accessibility modifier already seen: '${e}'.`,DuplicateModifier:({modifier:e})=>`Duplicate modifier: '${e}'.`,EmptyHeritageClauseType:({token:e})=>`'${e}' list cannot be empty.`,EmptyTypeArguments:`Type argument list cannot be empty.`,EmptyTypeParameters:`Type parameter list cannot be empty.`,ExpectedAmbientAfterExportDeclare:`'export declare' must be followed by an ambient declaration.`,ImportAliasHasImportType:`An import alias can not use 'import type'.`,IncompatibleModifiers:({modifiers:e})=>`'${e[0]}' modifier cannot be used with '${e[1]}' modifier.`,IndexSignatureHasAbstract:`Index signatures cannot have the 'abstract' modifier.`,IndexSignatureHasAccessibility:({modifier:e})=>`Index signatures cannot have an accessibility modifier ('${e}').`,IndexSignatureHasDeclare:`Index signatures cannot have the 'declare' modifier.`,IndexSignatureHasOverride:`'override' modifier cannot appear on an index signature.`,IndexSignatureHasStatic:`Index signatures cannot have the 'static' modifier.`,InitializerNotAllowedInAmbientContext:`Initializers are not allowed in ambient contexts.`,InlineModuleDeclarationMustUseString:"`module ... {}` declarations must have a string name. Use `namespace ... {}` instead.",InvalidHeritageClauseType:({token:e})=>`'${e}' list can only include identifiers or qualified-names with optional type arguments.`,InvalidModifierOnAwaitUsingDeclaration:e=>`'${e}' modifier cannot appear on an await using declaration.`,InvalidModifierOnTypeMember:({modifier:e})=>`'${e}' modifier cannot appear on a type member.`,InvalidModifierOnTypeParameter:({modifier:e})=>`'${e}' modifier cannot appear on a type parameter.`,InvalidModifierOnTypeParameterPositions:({modifier:e})=>`'${e}' modifier can only appear on a type parameter of a class, interface or type alias.`,InvalidModifierOnUsingDeclaration:e=>`'${e}' modifier cannot appear on a using declaration.`,InvalidModifiersOrder:({orderedModifiers:e})=>`'${e[0]}' modifier must precede '${e[1]}' modifier.`,InvalidPropertyAccessAfterInstantiationExpression:`Invalid property access after an instantiation expression. You can either wrap the instantiation expression in parentheses, or delete the type arguments.`,InvalidTupleMemberLabel:`Tuple members must be labeled with a simple identifier.`,MissingInterfaceName:`'interface' declarations must be followed by an identifier.`,NonAbstractClassHasAbstractMethod:`Abstract methods can only appear within an abstract class.`,NonClassMethodPropertyHasAbstractModifier:`'abstract' modifier can only appear on a class, method, or property declaration.`,OptionalTypeBeforeRequired:`A required element cannot follow an optional element.`,OverrideNotInSubClass:`This member cannot have an 'override' modifier because its containing class does not extend another class.`,PatternIsOptional:`A binding pattern parameter cannot be optional in an implementation signature.`,PrivateElementHasAbstract:`Private elements cannot have the 'abstract' modifier.`,PrivateElementHasAccessibility:({modifier:e})=>`Private elements cannot have an accessibility modifier ('${e}').`,ReadonlyForMethodSignature:`'readonly' modifier can only appear on a property declaration or index signature.`,ReservedArrowTypeParam:"This syntax is reserved in files with the .mts or .cts extension. Add a trailing comma, as in `<T,>() => ...`.",ReservedTypeAssertion:"This syntax is reserved in files with the .mts or .cts extension. Use an `as` expression instead.",SetAccessorCannotHaveOptionalParameter:`A 'set' accessor cannot have an optional parameter.`,SetAccessorCannotHaveRestParameter:`A 'set' accessor cannot have rest parameter.`,SetAccessorCannotHaveReturnType:`A 'set' accessor cannot have a return type annotation.`,SingleTypeParameterWithoutTrailingComma:({typeParameterName:e})=>`Single type parameter ${e} should have a trailing comma. Example usage: <${e},>.`,StaticBlockCannotHaveModifier:`Static class blocks cannot have any modifier.`,TupleOptionalAfterType:"A labeled tuple optional element must be declared using a question mark after the name and before the colon (`name?: type`), rather than after the type (`name: type?`).",TypeAnnotationAfterAssign:"Type annotations must come before default assignments, e.g. instead of `age = 25: number` use `age: number = 25`.",TypeImportCannotSpecifyDefaultAndNamed:`A type-only import can specify a default import or named bindings, but not both.`,TypeModifierIsUsedInTypeExports:`The 'type' modifier cannot be used on a named export when 'export type' is used on its export statement.`,TypeModifierIsUsedInTypeImports:`The 'type' modifier cannot be used on a named import when 'import type' is used on its import statement.`,UnexpectedParameterModifier:`A parameter property is only allowed in a constructor implementation.`,UnexpectedReadonly:`'readonly' type modifier is only permitted on array and tuple literal types.`,UnexpectedTypeAnnotation:`Did not expect a type annotation here.`,UnexpectedTypeCastInParameter:`Unexpected type cast in parameter position.`,UnsupportedImportTypeArgument:`Argument in a type import must be a string literal.`,UnsupportedParameterPropertyKind:`A parameter property may not be declared using a binding pattern.`,UnsupportedSignatureParameterKind:({type:e})=>`Name in a signature must be an Identifier, ObjectPattern or ArrayPattern, instead got ${e}.`,UsingDeclarationInAmbientContext:e=>`'${e}' declarations are not allowed in ambient contexts.`});function VF(e){switch(e){case`any`:return`TSAnyKeyword`;case`boolean`:return`TSBooleanKeyword`;case`bigint`:return`TSBigIntKeyword`;case`never`:return`TSNeverKeyword`;case`number`:return`TSNumberKeyword`;case`object`:return`TSObjectKeyword`;case`string`:return`TSStringKeyword`;case`symbol`:return`TSSymbolKeyword`;case`undefined`:return`TSUndefinedKeyword`;case`unknown`:return`TSUnknownKeyword`;default:return}}function HF(e){return e===`private`||e===`public`||e===`protected`}function UF(e){return e===`in`||e===`out`}function WF(e){if(e.extra?.parenthesized)return!1;switch(e.type){case`Identifier`:return!0;case`MemberExpression`:return!e.computed&&WF(e.object);case`TSInstantiationExpression`:return WF(e.expression);default:return!1}}var GF=e=>class extends e{getScopeHandler(){return $P}tsIsIdentifier(){return Y(this.state.type)}tsTokenCanFollowModifier(){return this.match(0)||this.match(2)||this.match(51)||this.match(17)||this.match(134)||this.isLiteralPropertyName()}tsNextTokenOnSameLineAndCanFollowModifier(){return this.next(),this.hasPrecedingLineBreak()?!1:this.tsTokenCanFollowModifier()}tsNextTokenCanFollowModifier(){return this.match(102)?(this.next(),this.tsTokenCanFollowModifier()):this.tsNextTokenOnSameLineAndCanFollowModifier()}tsParseModifier(e,t,n){if(!Y(this.state.type)&&this.state.type!==54&&this.state.type!==71)return;let r=this.state.value;if(e.includes(r)){if(n&&this.match(102)||t&&this.tsIsStartOfStaticBlocks())return;if(this.tsTryParse(this.tsNextTokenCanFollowModifier.bind(this)))return r}}tsParseModifiers({allowedModifiers:e,disallowedModifiers:t,stopOnStartOfClassStaticBlock:n,errorTemplate:r=Q.InvalidModifierOnTypeMember},i){let a=(e,t,n,r)=>{t===n&&i[r]&&this.raise(Q.InvalidModifiersOrder,e,{orderedModifiers:[n,r]})},o=(e,t,n,r)=>{(i[n]&&t===r||i[r]&&t===n)&&this.raise(Q.IncompatibleModifiers,e,{modifiers:[n,r]})};for(;;){let{startLoc:s}=this.state,c=this.tsParseModifier(e.concat(t??[]),n,i.static);if(!c)break;HF(c)?i.accessibility?this.raise(Q.DuplicateAccessibilityModifier,s,{modifier:c}):(a(s,c,c,`override`),a(s,c,c,`static`),a(s,c,c,`readonly`),i.accessibility=c):UF(c)?(i[c]&&this.raise(Q.DuplicateModifier,s,{modifier:c}),i[c]=!0,a(s,c,`in`,`out`)):(Object.hasOwn(i,c)?this.raise(Q.DuplicateModifier,s,{modifier:c}):(a(s,c,`static`,`readonly`),a(s,c,`static`,`override`),a(s,c,`override`,`readonly`),a(s,c,`abstract`,`override`),o(s,c,`declare`,`override`),o(s,c,`static`,`abstract`)),i[c]=!0),t?.includes(c)&&this.raise(r,s,{modifier:c})}}tsIsListTerminator(e){switch(e){case`EnumMembers`:case`TypeMembers`:return this.match(4);case`HeritageClauseElement`:return this.match(2);case`TupleElementTypes`:return this.match(1);case`TypeParametersOrArguments`:return this.match(44)}}tsParseList(e,t){let n=[];for(;!this.tsIsListTerminator(e);)n.push(t());return n}tsParseDelimitedList(e,t,n){return zF(this.tsParseDelimitedListWorker(e,t,!0,n))}tsParseDelimitedListWorker(e,t,n,r){let i=[],a=-1;for(;!this.tsIsListTerminator(e);){a=-1;let r=t();if(r==null)return;if(i.push(r),this.eat(8)){a=this.state.lastTokStartLoc.index;continue}if(this.tsIsListTerminator(e))break;n&&this.expect(8);return}return r&&(r.value=a),i}tsParseBracketedList(e,t,n,r,i){r||(n?this.expect(0):this.expect(43));let a=this.tsParseDelimitedList(e,t,i);return n?this.expect(1):this.expect(44),a}tsParseImportType(){let e=this.startNode();return this.expect(79),this.expect(6),this.match(130)?e.source=this.parseStringLiteral(this.state.value):(this.raise(Q.UnsupportedImportTypeArgument,this.state.startLoc),e.source=this.tsParseNonConditionalType()),this.eat(8)?e.options=this.tsParseImportTypeOptions():e.options=null,this.expect(7),this.eat(12)&&(e.qualifier=this.tsParseEntityName(3)),this.match(43)&&(e.typeArguments=this.tsParseTypeArguments()),this.finishNode(e,`TSImportType`)}tsParseImportTypeOptions(){let e=this.startNode();this.expect(2);let t=this.startNode();return this.isContextual(72)?(t.method=!1,t.key=this.parseIdentifier(!0),t.computed=!1,t.shorthand=!1):this.unexpected(null,72),this.expect(10),t.value=this.tsParseImportTypeWithPropertyValue(),e.properties=[this.finishObjectProperty(t)],this.eat(8),this.expect(4),this.finishNode(e,`ObjectExpression`)}tsParseImportTypeWithPropertyValue(){let e=this.startNode(),t=[];for(this.expect(2);!this.match(4);){let e=this.state.type;Y(e)||e===130?t.push(super.parsePropertyDefinition(null)):this.unexpected(),this.eat(8)}return e.properties=t,this.next(),this.finishNode(e,`ObjectExpression`)}tsParseEntityName(e){let t;if(e&1&&this.match(74))if(e&2)t=this.parseIdentifier(!0);else{let e=this.startNode();this.next(),t=this.finishNode(e,`ThisExpression`)}else t=this.parseIdentifier(!!(e&1));for(;this.eat(12);){let n=this.startNodeAtNode(t);n.left=t,n.right=this.parseIdentifier(!!(e&1)),t=this.finishNode(n,`TSQualifiedName`)}return t}tsParseTypeReference(){let e=this.startNode();return e.typeName=this.tsParseEntityName(1),!this.hasPrecedingLineBreak()&&this.match(43)&&(e.typeArguments=this.tsParseTypeArguments()),this.finishNode(e,`TSTypeReference`)}tsParseThisTypePredicate(e){this.next();let t=this.startNodeAtNode(e);return t.parameterName=e,t.typeAnnotation=this.tsParseTypeAnnotation(!1),t.asserts=!1,this.finishNode(t,`TSTypePredicate`)}tsParseThisTypeNode(){let e=this.startNode();return this.next(),this.finishNode(e,`TSThisType`)}tsParseTypeQuery(){let e=this.startNode();return this.expect(83),this.match(79)?e.exprName=this.tsParseImportType():e.exprName=this.tsParseEntityName(1),!this.hasPrecedingLineBreak()&&this.match(43)&&(e.typeArguments=this.tsParseTypeArguments()),this.finishNode(e,`TSTypeQuery`)}tsParseInOutModifiers=this.tsParseModifiers.bind(this,{allowedModifiers:[`in`,`out`],disallowedModifiers:[`const`,`public`,`private`,`protected`,`readonly`,`declare`,`abstract`,`override`],errorTemplate:Q.InvalidModifierOnTypeParameter});tsParseConstModifier=this.tsParseModifiers.bind(this,{allowedModifiers:[`const`],disallowedModifiers:[`in`,`out`],errorTemplate:Q.InvalidModifierOnTypeParameterPositions});tsParseInOutConstModifiers=this.tsParseModifiers.bind(this,{allowedModifiers:[`in`,`out`,`const`],disallowedModifiers:[`public`,`private`,`protected`,`readonly`,`declare`,`abstract`,`override`],errorTemplate:Q.InvalidModifierOnTypeParameter});tsParseTypeParameter(e){let t=this.startNode();return e(t),t.name=this.tsParseTypeParameterName(),t.constraint=this.tsEatThenParseType(77),t.default=this.tsEatThenParseType(25),this.finishNode(t,`TSTypeParameter`)}tsTryParseTypeParameters(e){if(this.match(43))return this.tsParseTypeParameters(e)}tsParseTypeParameters(e){let t=this.startNode();this.match(43)||this.match(138)?this.next():this.unexpected();let n={value:-1};return t.params=this.tsParseBracketedList(`TypeParametersOrArguments`,this.tsParseTypeParameter.bind(this,e),!1,!0,n),t.params.length===0&&this.raise(Q.EmptyTypeParameters,t),n.value!==-1&&this.addExtra(t,`trailingComma`,n.value),this.finishNode(t,`TSTypeParameterDeclaration`)}tsFillSignature(e,t){let n=e===15;t.typeParameters=this.tsTryParseTypeParameters(this.tsParseConstModifier),this.expect(6),t.params=this.tsParseBindingListForSignature(),(n||this.match(e))&&(t.returnType=this.tsParseTypeOrTypePredicateAnnotation(e))}tsParseBindingListForSignature(){let e=super.parseBindingList(7,41,2);for(let t of e){let{type:e}=t;(e===`AssignmentPattern`||e===`TSParameterProperty`)&&this.raise(Q.UnsupportedSignatureParameterKind,t,{type:e})}return e}tsParseTypeMemberSemicolon(){!this.eat(8)&&!this.isLineTerminator()&&this.expect(9)}tsParseSignatureMember(e,t){return this.tsFillSignature(10,t),this.tsParseTypeMemberSemicolon(),this.finishNode(t,e)}tsIsUnambiguouslyIndexSignature(){return this.next(),Y(this.state.type)?(this.next(),this.match(10)):!1}tsTryParseIndexSignature(e){if(!(this.match(0)&&this.tsLookAhead(this.tsIsUnambiguouslyIndexSignature.bind(this))))return;this.expect(0);let t=this.parseIdentifier();t.typeAnnotation=this.tsParseTypeAnnotation(),this.resetEndLocation(t),this.expect(1),e.parameters=[t];let n=this.tsTryParseTypeAnnotation();return n&&(e.typeAnnotation=n),this.tsParseTypeMemberSemicolon(),this.finishNode(e,`TSIndexSignature`)}tsParsePropertyOrMethodSignature(e,t){if(this.eat(13)&&(e.optional=!0),this.match(6)||this.match(43)){t&&this.raise(Q.ReadonlyForMethodSignature,e);let n=e;if(n.kind&&this.match(43)&&this.raise(Q.AccessorCannotHaveTypeParameters,this.state.curPosition()),this.tsFillSignature(10,n),this.tsParseTypeMemberSemicolon(),n.kind===`get`)n.params.length>0&&(this.raise(G.BadGetterArity,this.state.curPosition()),this.isThisParam(n.params[0])&&this.raise(Q.AccessorCannotDeclareThisParameter,this.state.curPosition()));else if(n.kind===`set`){if(n.params.length!==1)this.raise(G.BadSetterArity,this.state.curPosition());else{let e=n.params[0];this.isThisParam(e)&&this.raise(Q.AccessorCannotDeclareThisParameter,this.state.curPosition()),e.type===`Identifier`&&e.optional&&this.raise(Q.SetAccessorCannotHaveOptionalParameter,this.state.curPosition()),e.type===`RestElement`&&this.raise(Q.SetAccessorCannotHaveRestParameter,this.state.curPosition())}n.returnType&&this.raise(Q.SetAccessorCannotHaveReturnType,n.returnType)}else n.kind=`method`;return this.finishNode(n,`TSMethodSignature`)}else{let n=e;t&&(n.readonly=!0);let r=this.tsTryParseTypeAnnotation();return r&&(n.typeAnnotation=r),this.tsParseTypeMemberSemicolon(),this.finishNode(n,`TSPropertySignature`)}}tsParseTypeMember(){let e=this.startNode();if(this.match(6)||this.match(43))return this.tsParseSignatureMember(`TSCallSignatureDeclaration`,e);if(this.match(73)){let t=this.startNode();return this.next(),this.match(6)||this.match(43)?this.tsParseSignatureMember(`TSConstructSignatureDeclaration`,e):(e.key=this.createIdentifier(t,`new`),this.tsParsePropertyOrMethodSignature(e,!1))}return this.tsParseModifiers({allowedModifiers:[`readonly`],disallowedModifiers:[`declare`,`abstract`,`private`,`protected`,`public`,`static`,`override`]},e),this.tsTryParseIndexSignature(e)||(super.parsePropertyName(e),!e.computed&&e.key.type===`Identifier`&&(e.key.name===`get`||e.key.name===`set`)&&this.tsTokenCanFollowModifier()&&(e.kind=e.key.name,super.parsePropertyName(e),!this.match(6)&&!this.match(43)&&this.unexpected(null,6)),this.tsParsePropertyOrMethodSignature(e,!!e.readonly))}tsParseTypeLiteral(){let e=this.startNode();return e.members=this.tsParseObjectTypeMembers(),this.finishNode(e,`TSTypeLiteral`)}tsParseObjectTypeMembers(){this.expect(2);let e=this.tsParseList(`TypeMembers`,this.tsParseTypeMember.bind(this));return this.expect(4),e}tsIsStartOfMappedType(){return this.next(),this.eat(49)?this.isContextual(118):(this.isContextual(118)&&this.next(),!this.match(0)||(this.next(),!this.tsIsIdentifier())?!1:(this.next(),this.match(54)))}tsParseMappedType(){let e=this.startNode();return this.expect(2),this.match(49)?(e.readonly=this.state.value,this.next(),this.expectContextual(118)):this.eatContextual(118)&&(e.readonly=!0),this.expect(0),e.key=this.tsParseTypeParameterName(),e.constraint=this.tsExpectThenParseType(54),e.nameType=this.eatContextual(89)?this.tsParseType():null,this.expect(1),this.match(49)?(e.optional=this.state.value,this.next(),this.expect(13)):this.eat(13)&&(e.optional=!0),e.typeAnnotation=this.tsTryParseType(),this.semicolon(),this.expect(4),this.finishNode(e,`TSMappedType`)}tsParseTupleType(){let e=this.startNode();e.elementTypes=this.tsParseBracketedList(`TupleElementTypes`,this.tsParseTupleElementType.bind(this),!0,!1);let t=!1;return e.elementTypes.forEach(e=>{let{type:n}=e;t&&n!==`TSRestType`&&n!==`TSOptionalType`&&!(n===`TSNamedTupleMember`&&e.optional)&&this.raise(Q.OptionalTypeBeforeRequired,e),t||=n===`TSNamedTupleMember`&&e.optional||n===`TSOptionalType`}),this.finishNode(e,`TSTupleType`)}tsParseTupleElementType(){let e=this.state.startLoc,t=this.eat(17),{startLoc:n}=this.state,r,i,a,o,s=WN(this.state.type)?this.lookaheadCharCode():null;if(s===58)r=!0,a=!1,i=this.parseIdentifier(!0),this.expect(10),o=this.tsParseType();else if(s===63){a=!0;let e=this.state.value,t=this.tsParseNonArrayType();this.lookaheadCharCode()===58?(r=!0,i=this.createIdentifier(this.startNodeAt(n),e),this.expect(13),this.expect(10),o=this.tsParseType()):(r=!1,o=t,this.expect(13))}else o=this.tsParseType(),a=this.eat(13),r=this.eat(10);if(r){let e;i?(e=this.startNodeAt(n),e.optional=a,e.label=i,e.elementType=o,this.eat(13)&&(e.optional=!0,this.raise(Q.TupleOptionalAfterType,this.state.lastTokStartLoc))):(e=this.startNodeAt(n),e.optional=a,this.raise(Q.InvalidTupleMemberLabel,o),e.label=o,e.elementType=this.tsParseType()),o=this.finishNode(e,`TSNamedTupleMember`)}else if(a){let e=this.startNodeAt(n);e.typeAnnotation=o,o=this.finishNode(e,`TSOptionalType`)}if(t){let t=this.startNodeAt(e);t.typeAnnotation=o,o=this.finishNode(t,`TSRestType`)}return o}tsParseParenthesizedType(){let e=this.startNode();return this.expect(6),e.typeAnnotation=this.tsParseType(),this.expect(7),this.finishNode(e,`TSParenthesizedType`)}tsParseFunctionOrConstructorType(e,t){let n=this.startNode();return e===`TSConstructorType`&&(n.abstract=!!t,t&&this.next(),this.next()),this.tsInAllowConditionalTypesContext(()=>this.tsFillSignature(15,n)),this.finishNode(n,e)}tsParseLiteralTypeNode(){let e=this.startNode();switch(this.state.type){case 131:case 132:case 130:case 81:case 82:e.literal=super.parseExprAtom();break;default:this.unexpected()}return this.finishNode(e,`TSLiteralType`)}tsParseTemplateLiteralType(){let e=this.state.startLoc,t=this.parseTemplateElement(!1),n=[t];if(t.tail){let t=this.startNodeAt(e),r=this.startNodeAt(e);return r.expressions=[],r.quasis=n,t.literal=this.finishNode(r,`TemplateLiteral`),this.finishNode(t,`TSLiteralType`)}else{let r=[];for(;!t.tail;)r.push(this.tsParseType()),this.readTemplateContinuation(),n.push(t=this.parseTemplateElement(!1));let i=this.startNodeAt(e);return i.types=r,i.quasis=n,this.finishNode(i,`TSTemplateLiteralType`)}}parseTemplateSubstitution(){return this.state.inType?this.tsParseType():super.parseTemplateSubstitution()}tsParseThisTypeOrThisTypePredicate(){let e=this.tsParseThisTypeNode();return this.isContextual(112)&&!this.hasPrecedingLineBreak()?this.tsParseThisTypePredicate(e):e}tsParseNonArrayType(){switch(this.state.type){case 130:case 131:case 132:case 81:case 82:return this.tsParseLiteralTypeNode();case 49:if(this.state.value===`-`){let e=this.startNode(),t=this.lookahead();return t.type!==131&&t.type!==132&&this.unexpected(),e.literal=this.parseMaybeUnary(),this.finishNode(e,`TSLiteralType`)}break;case 74:return this.tsParseThisTypeOrThisTypePredicate();case 83:return this.tsParseTypeQuery();case 79:return this.tsParseImportType();case 2:return this.tsLookAhead(this.tsIsStartOfMappedType.bind(this))?this.tsParseMappedType():this.tsParseTypeLiteral();case 0:return this.tsParseTupleType();case 6:if(!(this.optionFlags&1024)){let e=this.state.startLoc;this.next();let t=this.tsParseType();return this.expect(7),this.addExtra(t,`parenthesized`,!0),this.addExtra(t,`parenStart`,e.index),t}return this.tsParseParenthesizedType();case 21:case 20:return this.tsParseTemplateLiteralType();default:{let{type:e}=this.state;if(Y(e)||e===84||e===80){let t=e===84?`TSVoidKeyword`:e===80?`TSNullKeyword`:VF(this.state.value);if(t!==void 0&&this.lookaheadCharCode()!==46){let e=this.startNode();return this.next(),this.finishNode(e,t)}return this.tsParseTypeReference()}}}throw this.unexpected()}tsParseArrayTypeOrHigher(){let{startLoc:e}=this.state,t=this.tsParseNonArrayType();for(;!this.hasPrecedingLineBreak()&&this.eat(0);)if(this.match(1)){let n=this.startNodeAt(e);n.elementType=t,this.expect(1),t=this.finishNode(n,`TSArrayType`)}else{let n=this.startNodeAt(e);n.objectType=t,n.indexType=this.tsParseType(),this.expect(1),t=this.finishNode(n,`TSIndexedAccessType`)}return t}tsParseTypeOperator(){let e=this.startNode(),t=this.state.value;return this.next(),e.operator=t,e.typeAnnotation=this.tsParseTypeOperatorOrHigher(),t===`readonly`&&this.tsCheckTypeAnnotationForReadOnly(e),this.finishNode(e,`TSTypeOperator`)}tsCheckTypeAnnotationForReadOnly(e){switch(e.typeAnnotation.type){case`TSTupleType`:case`TSArrayType`:return;default:this.raise(Q.UnexpectedReadonly,e)}}tsParseInferType(){let e=this.startNode();this.expectContextual(111);let t=this.startNode();return t.name=this.tsParseTypeParameterName(),t.constraint=this.tsTryParse(()=>this.tsParseConstraintForInferType()),e.typeParameter=this.finishNode(t,`TSTypeParameter`),this.finishNode(e,`TSInferType`)}tsParseConstraintForInferType(){if(this.eat(77)){let e=this.tsInDisallowConditionalTypesContext(()=>this.tsParseType());if(this.state.inDisallowConditionalTypesContext||!this.match(13))return e}}tsParseTypeOperatorOrHigher(){return tP(this.state.type)&&!this.state.containsEsc?this.tsParseTypeOperator():this.isContextual(111)?this.tsParseInferType():this.tsInAllowConditionalTypesContext(()=>this.tsParseArrayTypeOrHigher())}tsParseUnionOrIntersectionType(e,t,n){let r=this.startNode(),i=this.eat(n),a=[];do a.push(t());while(this.eat(n));return a.length===1&&!i?a[0]:(r.types=a,this.finishNode(r,e))}tsParseIntersectionTypeOrHigher(){return this.tsParseUnionOrIntersectionType(`TSIntersectionType`,this.tsParseTypeOperatorOrHigher.bind(this),41)}tsParseUnionTypeOrHigher(){return this.tsParseUnionOrIntersectionType(`TSUnionType`,this.tsParseIntersectionTypeOrHigher.bind(this),39)}tsIsStartOfFunctionType(){return this.match(43)?!0:this.match(6)&&this.tsLookAhead(this.tsIsUnambiguouslyStartOfFunctionType.bind(this))}tsSkipParameterStart(){if(Y(this.state.type)||this.match(74))return this.next(),!0;if(this.match(2)){let{errors:e}=this.state,t=e.length;try{return this.parseObjectLike(4,!0),e.length===t}catch{return!1}}if(this.match(0)){this.next();let{errors:e}=this.state,t=e.length;try{return super.parseBindingList(1,93,1),e.length===t}catch{return!1}}return!1}tsIsUnambiguouslyStartOfFunctionType(){return this.next(),!!(this.match(7)||this.match(17)||this.tsSkipParameterStart()&&(this.match(10)||this.match(8)||this.match(13)||this.match(25)||this.match(7)&&(this.next(),this.match(15))))}tsParseTypeOrTypePredicateAnnotation(e){return this.tsInType(()=>{let t=this.startNode();this.expect(e);let n=this.startNode(),r=!!this.tsTryParse(this.tsParseTypePredicateAsserts.bind(this));if(r&&this.match(74)){let e=this.tsParseThisTypeOrThisTypePredicate();return e.type===`TSThisType`?(n.parameterName=e,n.asserts=!0,n.typeAnnotation=null,e=this.finishNode(n,`TSTypePredicate`)):(this.resetStartLocationFromNode(e,n),e.asserts=!0),t.typeAnnotation=e,this.finishNode(t,`TSTypeAnnotation`)}let i=this.tsIsIdentifier()&&this.tsTryParse(this.tsParseTypePredicatePrefix.bind(this));if(!i)return r?(n.parameterName=this.parseIdentifier(),n.asserts=r,n.typeAnnotation=null,t.typeAnnotation=this.finishNode(n,`TSTypePredicate`),this.finishNode(t,`TSTypeAnnotation`)):this.tsParseTypeAnnotation(!1,t);let a=this.tsParseTypeAnnotation(!1);return n.parameterName=i,n.typeAnnotation=a,n.asserts=r,t.typeAnnotation=this.finishNode(n,`TSTypePredicate`),this.finishNode(t,`TSTypeAnnotation`)})}tsTryParseTypeOrTypePredicateAnnotation(){if(this.match(10))return this.tsParseTypeOrTypePredicateAnnotation(10)}tsTryParseTypeAnnotation(){if(this.match(10))return this.tsParseTypeAnnotation()}tsTryParseType(){return this.tsEatThenParseType(10)}tsParseTypePredicatePrefix(){let e=this.parseIdentifier();if(this.isContextual(112)&&!this.hasPrecedingLineBreak())return this.next(),e}tsParseTypePredicateAsserts(){if(this.state.type!==105)return!1;let e=this.state.containsEsc;return this.next(),!Y(this.state.type)&&!this.match(74)?!1:(e&&this.raise(G.InvalidEscapedReservedWord,this.state.lastTokStartLoc,{reservedWord:`asserts`}),!0)}tsParseTypeAnnotation(e=!0,t=this.startNode()){return this.tsInType(()=>{e&&this.expect(10),t.typeAnnotation=this.tsParseType()}),this.finishNode(t,`TSTypeAnnotation`)}tsParseType(){BF(this.state.inType);let e=this.tsParseNonConditionalType();if(this.state.inDisallowConditionalTypesContext||this.hasPrecedingLineBreak()||!this.eat(77))return e;let t=this.startNodeAtNode(e);return t.checkType=e,t.extendsType=this.tsInDisallowConditionalTypesContext(()=>this.tsParseNonConditionalType()),this.expect(13),t.trueType=this.tsInAllowConditionalTypesContext(()=>this.tsParseType()),this.expect(10),t.falseType=this.tsInAllowConditionalTypesContext(()=>this.tsParseType()),this.finishNode(t,`TSConditionalType`)}isAbstractConstructorSignature(){return this.isContextual(120)&&this.isLookaheadContextual(`new`)}tsParseNonConditionalType(){return this.tsIsStartOfFunctionType()?this.tsParseFunctionOrConstructorType(`TSFunctionType`):this.match(73)?this.tsParseFunctionOrConstructorType(`TSConstructorType`):this.isAbstractConstructorSignature()?this.tsParseFunctionOrConstructorType(`TSConstructorType`,!0):this.tsParseUnionTypeOrHigher()}tsParseTypeAssertion(){this.getPluginOption(`typescript`,`disallowAmbiguousJSXLike`)&&this.raise(Q.ReservedTypeAssertion,this.state.startLoc);let e=this.startNode();return e.typeAnnotation=this.tsInType(()=>(this.next(),this.match(71)?this.tsParseTypeReference():this.tsParseType())),this.expect(44),e.expression=this.parseMaybeUnary(),this.finishNode(e,`TSTypeAssertion`)}tsParseHeritageClause(e){let t=this.state.startLoc,n=this.tsParseDelimitedList(`HeritageClauseElement`,()=>{let t=super.parseExprSubscripts();WF(t)||this.raise(Q.InvalidHeritageClauseType,t.loc.start,{token:e});let n=e===`extends`?`TSInterfaceHeritage`:`TSClassImplements`;if(t.type===`TSInstantiationExpression`)return t.type=n,t;let r=this.startNodeAtNode(t);return r.expression=t,(this.match(43)||this.match(47))&&(r.typeArguments=this.tsParseTypeArgumentsInExpression()),this.finishNode(r,n)});return n.length||this.raise(Q.EmptyHeritageClauseType,t,{token:e}),n}tsParseInterfaceDeclaration(e,t={}){if(this.hasFollowingLineBreak())return null;this.expectContextual(125),t.declare&&(e.declare=!0),Y(this.state.type)?(e.id=this.parseIdentifier(),this.checkIdentifier(e.id,130)):(e.id=null,this.raise(Q.MissingInterfaceName,this.state.startLoc)),e.typeParameters=this.tsTryParseTypeParameters(this.tsParseInOutConstModifiers),this.eat(77)&&(e.extends=this.tsParseHeritageClause(`extends`));let n=this.startNode();return n.body=this.tsInType(this.tsParseObjectTypeMembers.bind(this)),e.body=this.finishNode(n,`TSInterfaceBody`),this.finishNode(e,`TSInterfaceDeclaration`)}tsParseTypeAliasDeclaration(e){return e.id=this.parseIdentifier(),this.checkIdentifier(e.id,2),e.typeAnnotation=this.tsInType(()=>{if(e.typeParameters=this.tsTryParseTypeParameters(this.tsParseInOutModifiers),this.expect(25),this.isContextual(110)&&this.lookaheadCharCode()!==46){let e=this.startNode();return this.next(),this.finishNode(e,`TSIntrinsicKeyword`)}return this.tsParseType()}),this.semicolon(),this.finishNode(e,`TSTypeAliasDeclaration`)}tsInTopLevelContext(e){if(this.curContext()!==X.brace){let t=this.state.context;this.state.context=[t[0]];try{return e()}finally{this.state.context=t}}else return e()}tsInType(e){let t=this.state.inType;this.state.inType=!0;try{return e()}finally{this.state.inType=t}}tsInDisallowConditionalTypesContext(e){let t=this.state.inDisallowConditionalTypesContext;this.state.inDisallowConditionalTypesContext=!0;try{return e()}finally{this.state.inDisallowConditionalTypesContext=t}}tsInAllowConditionalTypesContext(e){let t=this.state.inDisallowConditionalTypesContext;this.state.inDisallowConditionalTypesContext=!1;try{return e()}finally{this.state.inDisallowConditionalTypesContext=t}}tsEatThenParseType(e){if(this.match(e))return this.tsNextThenParseType()}tsExpectThenParseType(e){return this.tsInType(()=>(this.expect(e),this.tsParseType()))}tsNextThenParseType(){return this.tsInType(()=>(this.next(),this.tsParseType()))}tsParseEnumMember(){let e=this.startNode();return e.id=this.match(130)?super.parseStringLiteral(this.state.value):this.parseIdentifier(!0),this.eat(25)&&(e.initializer=super.parseMaybeAssignAllowIn()),this.finishNode(e,`TSEnumMember`)}tsParseEnumDeclaration(e,t={}){return t.const&&(e.const=!0),t.declare&&(e.declare=!0),this.expectContextual(122),e.id=this.parseIdentifier(),this.checkIdentifier(e.id,e.const?8971:8459),e.body=this.tsParseEnumBody(),this.finishNode(e,`TSEnumDeclaration`)}tsParseEnumBody(){let e=this.startNode();return this.expect(2),e.members=this.tsParseDelimitedList(`EnumMembers`,this.tsParseEnumMember.bind(this)),this.expect(4),this.finishNode(e,`TSEnumBody`)}tsParseModuleBlock(){let e=this.startNode();return this.scope.enter(0),this.expect(2),super.parseBlockOrModuleBlockBody(e.body=[],void 0,!0,4),this.scope.exit(),this.finishNode(e,`TSModuleBlock`)}tsParseNamespaceDeclaration(e){return e.id=this.tsParseEntityName(1),e.id.type===`Identifier`&&this.checkIdentifier(e.id,1024),this.scope.enter(1024),this.prodParam.enter(0),e.body=this.tsParseModuleBlock(),this.prodParam.exit(),this.scope.exit(),this.finishNode(e,`TSModuleDeclaration`)}tsParseAmbientExternalModuleDeclaration(e){return this.isContextual(108)?(e.kind=`global`,e.id=this.parseIdentifier()):(e.kind=`module`,e.id=super.parseStringLiteral(this.state.value)),this.match(2)?(this.scope.enter(1024),this.prodParam.enter(0),e.body=this.tsParseModuleBlock(),this.prodParam.exit(),this.scope.exit()):this.semicolon(),this.finishNode(e,`TSModuleDeclaration`)}tsParseImportEqualsDeclaration(e,t){e.id=t||this.parseIdentifier(),this.checkIdentifier(e.id,4096),this.expect(25);let n=this.tsParseModuleReference();return e.importKind===`type`&&n.type!==`TSExternalModuleReference`&&this.raise(Q.ImportAliasHasImportType,n),e.moduleReference=n,this.semicolon(),this.finishNode(e,`TSImportEqualsDeclaration`)}tsIsExternalModuleReference(){return this.isContextual(115)&&this.lookaheadCharCode()===40}tsParseModuleReference(){return this.tsIsExternalModuleReference()?this.tsParseExternalModuleReference():this.tsParseEntityName(0)}tsParseExternalModuleReference(){let e=this.startNode();return this.expectContextual(115),this.expect(6),this.match(130)||this.unexpected(),e.expression=super.parseExprAtom(),this.expect(7),this.sawUnambiguousESM=!0,this.finishNode(e,`TSExternalModuleReference`)}tsLookAhead(e){let t=this.state.clone(),n=e();return this.state=t,n}tsTryParseAndCatch(e){let t=this.tryParse(t=>e()||t());if(!(t.aborted||!t.node))return t.error&&(this.state=t.failState),t.node}tsTryParse(e){let t=this.state.clone(),n=e();if(n!==void 0&&n!==!1)return n;this.state=t}tsTryParseDeclare(e){if(this.isLineTerminator())return;let t=this.state.type;return this.tsInAmbientContext(()=>{switch(t){case 64:return e.declare=!0,super.parseFunctionStatement(e,!1,!1);case 76:return e.declare=!0,this.parseClass(e,!0,!1);case 122:return this.tsParseEnumDeclaration(e,{declare:!0});case 108:return this.tsParseAmbientExternalModuleDeclaration(e);case 96:if(this.state.containsEsc)return;case 71:case 70:return!this.match(71)||!this.isLookaheadContextual(`enum`)?(e.declare=!0,this.parseVarStatement(e,this.state.value,!0)):(this.expect(71),this.tsParseEnumDeclaration(e,{const:!0,declare:!0}));case 103:if(this.isUsing())return this.raise(Q.InvalidModifierOnUsingDeclaration,this.state.startLoc,`declare`),e.declare=!0,this.parseVarStatement(e,`using`,!0);break;case 92:if(this.isAwaitUsing())return this.raise(Q.InvalidModifierOnAwaitUsingDeclaration,this.state.startLoc,`declare`),e.declare=!0,this.next(),this.parseVarStatement(e,`await using`,!0);break;case 125:{let t=this.tsParseInterfaceDeclaration(e,{declare:!0});if(t)return t}default:if(Y(t))return this.tsParseDeclaration(e,this.state.type,!0,null)}})}tsTryParseExportDeclaration(){return this.tsParseDeclaration(this.startNode(),this.state.type,!0,null)}tsParseDeclaration(e,t,n,r){switch(t){case 120:if(this.tsCheckLineTerminator(n)&&(this.match(76)||Y(this.state.type)))return this.tsParseAbstractDeclaration(e,r);break;case 123:if(this.tsCheckLineTerminator(n))return this.tsParseAmbientExternalModuleDeclaration(e);break;case 124:if(this.tsCheckLineTerminator(n)&&Y(this.state.type))return e.kind=`namespace`,this.tsParseNamespaceDeclaration(e);break;case 126:if(this.tsCheckLineTerminator(n)&&Y(this.state.type))return this.tsParseTypeAliasDeclaration(e);break}}tsCheckLineTerminator(e){return e?this.hasFollowingLineBreak()?!1:(this.next(),!0):!this.isLineTerminator()}tsTryParseGenericAsyncArrowFunction(e){if(!this.match(43))return;let t=this.state.maybeInArrowParameters;this.state.maybeInArrowParameters=!0;let n=this.tsTryParseAndCatch(()=>{let t=this.startNodeAt(e);return t.typeParameters=this.tsParseTypeParameters(this.tsParseConstModifier),super.parseFunctionParams(t),t.returnType=this.tsTryParseTypeOrTypePredicateAnnotation(),this.expect(15),t});if(this.state.maybeInArrowParameters=t,n)return super.parseArrowExpression(n,null,!0)}tsParseTypeArgumentsInExpression(){if(this.reScan_lt()===43)return this.tsParseTypeArguments()}tsParseTypeArguments(){let e=this.startNode();return e.params=this.tsInType(()=>this.tsInTopLevelContext(()=>(this.expect(43),this.tsParseDelimitedList(`TypeParametersOrArguments`,this.tsParseType.bind(this))))),e.params.length===0?this.raise(Q.EmptyTypeArguments,e):!this.state.inType&&this.curContext()===X.brace&&this.reScan_lt_gt(),this.expect(44),this.finishNode(e,`TSTypeParameterInstantiation`)}tsIsDeclarationStart(){return nP(this.state.type)}isExportDefaultSpecifier(){return this.tsIsDeclarationStart()?!1:super.isExportDefaultSpecifier()}parseBindingElement(e,t){let n=t.length?t[0].loc.start:this.state.startLoc,r={};this.tsParseModifiers({allowedModifiers:[`public`,`private`,`protected`,`override`,`readonly`]},r);let i=r.accessibility,a=r.override,o=r.readonly;!(e&4)&&(i||o||a)&&this.raise(Q.UnexpectedParameterModifier,n);let s=this.parseMaybeDefault();e&2&&this.parseFunctionParamType(s);let c=this.parseMaybeDefault(s.loc.start,s);if(i||o||a){let e=this.startNodeAt(n);return t.length&&(e.decorators=t),i&&(e.accessibility=i),o&&(e.readonly=o),a&&(e.override=a),c.type!==`Identifier`&&c.type!==`AssignmentPattern`&&this.raise(Q.UnsupportedParameterPropertyKind,e),e.parameter=c,this.finishNode(e,`TSParameterProperty`)}return t.length&&(s.decorators=t),c}isSimpleParameter(e){return e.type===`TSParameterProperty`&&super.isSimpleParameter(e.parameter)||super.isSimpleParameter(e)}tsDisallowOptionalPattern(e){for(let t of e.params)t.type!==`Identifier`&&t.optional&&!this.state.isAmbientContext&&this.raise(Q.PatternIsOptional,t)}setArrowFunctionParameters(e,t,n){super.setArrowFunctionParameters(e,t,n),this.tsDisallowOptionalPattern(e)}parseFunctionBodyAndFinish(e,t,n=!1){this.match(10)&&(e.returnType=this.tsParseTypeOrTypePredicateAnnotation(10));let r=t===`FunctionDeclaration`?`TSDeclareFunction`:t===`ClassMethod`||t===`ClassPrivateMethod`?`TSDeclareMethod`:void 0;return r&&!this.match(2)&&this.isLineTerminator()?this.finishNode(e,r):r===`TSDeclareFunction`&&this.state.isAmbientContext&&(this.raise(Q.DeclareFunctionHasImplementation,e),e.declare)?super.parseFunctionBodyAndFinish(e,r,n):(this.tsDisallowOptionalPattern(e),super.parseFunctionBodyAndFinish(e,t,n))}registerFunctionStatementId(e){!e.body&&e.id?this.checkIdentifier(e.id,1024):super.registerFunctionStatementId(e)}tsCheckForInvalidTypeCasts(e){e.forEach(e=>{e?.type===`TSTypeCastExpression`&&this.raise(Q.UnexpectedTypeAnnotation,e.typeAnnotation)})}toReferencedList(e,t){return this.tsCheckForInvalidTypeCasts(e),e}parseArrayLike(e,t){let n=super.parseArrayLike(e,t);return n.type===`ArrayExpression`&&this.tsCheckForInvalidTypeCasts(n.elements),n}parseSubscript(e,t,n,r){if(!this.hasPrecedingLineBreak()&&this.match(31)){this.state.canStartJSXElement=!1,this.next();let n=this.startNodeAt(t);return n.expression=e,this.finishNode(n,`TSNonNullExpression`)}let i=!1;if(this.match(14)&&this.lookaheadCharCode()===60){if(n)return r.stop=!0,e;r.optionalChainMember=i=!0,this.next()}if(this.match(43)||this.match(47)){let a,o=this.tsTryParseAndCatch(()=>{if(!n&&this.atPossibleAsyncArrow(e)){let e=this.tsTryParseGenericAsyncArrowFunction(t);if(e)return r.stop=!0,e}let o=this.tsParseTypeArgumentsInExpression();if(!o)return;if(i&&!this.match(6)){a=this.state.curPosition();return}if(oP(this.state.type)){let n=super.parseTaggedTemplateExpression(e,t,r);return n.typeArguments=o,n}if(!n&&this.eat(6)){let n=this.startNodeAt(t);return n.callee=e,n.arguments=this.parseCallExpressionArguments(),this.tsCheckForInvalidTypeCasts(n.arguments),n.typeArguments=o,r.optionalChainMember&&(n.optional=i),this.finishCallExpression(n,r.optionalChainMember)}let s=this.state.type;if(s===44||s===48||s!==6&&s!==89&&s!==116&&qN(s)&&!this.hasPrecedingLineBreak())return;let c=this.startNodeAt(t);return c.expression=e,c.typeArguments=o,this.finishNode(c,`TSInstantiationExpression`)});if(a&&this.unexpected(a,6),o)return o.type===`TSInstantiationExpression`&&((this.match(12)||this.match(14)&&this.lookaheadCharCode()!==40)&&this.raise(Q.InvalidPropertyAccessAfterInstantiationExpression,this.state.startLoc),!this.match(12)&&!this.match(14)&&(o.expression=super.stopParseSubscript(e,r))),o}return super.parseSubscript(e,t,n,r)}parseNewCallee(e){super.parseNewCallee(e);let{callee:t}=e;t.type===`TSInstantiationExpression`&&!t.extra?.parenthesized&&(e.typeArguments=t.typeArguments,e.callee=t.expression)}parseExprOp(e,t,n){let r;if(iP(54)>n&&!this.hasPrecedingLineBreak()&&(this.isContextual(89)||(r=this.isContextual(116)))){let i=this.startNodeAt(t);return i.expression=e,i.typeAnnotation=this.tsInType(()=>(this.next(),this.match(71)?(r&&this.raise(G.UnexpectedKeyword,this.state.startLoc,{keyword:`const`}),this.tsParseTypeReference()):this.tsParseType())),this.finishNode(i,r?`TSSatisfiesExpression`:`TSAsExpression`),this.reScan_lt_gt(),this.parseExprOp(i,t,n)}return super.parseExprOp(e,t,n)}checkReservedWord(e,t,n,r){this.state.isAmbientContext||super.checkReservedWord(e,t,n,r)}checkDuplicateExports(){}isPotentialImportPhase(e){if(super.isPotentialImportPhase(e))return!0;if(this.isContextual(126)){let t=this.lookaheadCharCode();return e?t===123||t===42:t!==61}return!e&&this.isContextual(83)}applyImportPhase(e,t,n,r){super.applyImportPhase(e,t,n,r),t?e.exportKind=n===`type`?`type`:`value`:e.importKind=n===`type`||n===`typeof`?n:`value`}parseImport(e){if(this.match(130))return e.importKind=`value`,super.parseImport(e);let t;if(Y(this.state.type)&&this.lookaheadCharCode()===61)return e.importKind=`value`,this.tsParseImportEqualsDeclaration(e);if(this.isContextual(126)){let n=this.parseMaybeImportPhase(e,!1);if(this.lookaheadCharCode()===61)return this.tsParseImportEqualsDeclaration(e,n);t=super.parseImportSpecifiersAndAfter(e,n)}else t=super.parseImport(e);return t.importKind===`type`&&t.specifiers.length>1&&t.specifiers[0].type===`ImportDefaultSpecifier`&&this.raise(Q.TypeImportCannotSpecifyDefaultAndNamed,t),t}parseExport(e,t){if(this.match(79)){let t=this.startNode();this.next();let n=null;this.isContextual(126)&&this.isPotentialImportPhase(!1)?n=this.parseMaybeImportPhase(t,!1):t.importKind=`value`;let r=this.tsParseImportEqualsDeclaration(t,n);return e.attributes=[],e.declaration=r,e.exportKind=`value`,e.source=null,e.specifiers=[],this.finishNode(e,`ExportNamedDeclaration`)}else if(this.eat(25)){let t=e;return t.expression=super.parseExpression(),this.semicolon(),this.sawUnambiguousESM=!0,this.finishNode(t,`TSExportAssignment`)}else if(this.eatContextual(89)){let t=e;return this.expectContextual(124),t.id=this.parseIdentifier(),this.semicolon(),this.finishNode(t,`TSNamespaceExportDeclaration`)}else return super.parseExport(e,t)}isAbstractClass(){return this.isContextual(120)&&this.isLookaheadContextual(`class`)}parseExportDefaultExpression(){if(this.isAbstractClass()){let e=this.startNode();return this.next(),e.abstract=!0,this.parseClass(e,!0,!0)}if(this.match(125)){let e=this.tsParseInterfaceDeclaration(this.startNode());if(e)return e}return super.parseExportDefaultExpression()}parseVarStatement(e,t,n=!1){let{isAmbientContext:r}=this.state,i=super.parseVarStatement(e,t,n||r);if(!r)return i;if(!e.declare&&(t===`using`||t===`await using`))return this.raiseOverwrite(Q.UsingDeclarationInAmbientContext,e,t),i;for(let{id:e,init:n}of i.declarations)n&&(t===`var`||t===`let`||e.typeAnnotation?this.raise(Q.InitializerNotAllowedInAmbientContext,n):qF(n,this.hasPlugin(`estree`))||this.raise(Q.ConstInitializerMustBeStringOrNumericLiteralOrLiteralEnumReference,n));return i}parseStatementContent(e,t){if(!this.state.containsEsc)switch(this.state.type){case 71:if(this.isLookaheadContextual(`enum`)){let e=this.startNode();return this.expect(71),this.tsParseEnumDeclaration(e,{const:!0})}break;case 120:case 121:if(this.nextTokenIsIdentifierAndNotTSRelationalOperatorOnSameLine()){let e=this.state.type,n=this.startNode();this.next();let r=e===121?this.tsTryParseDeclare(n):this.tsParseAbstractDeclaration(n,t);return r?(e===121&&(r.declare=!0),r):(n.expression=this.createIdentifier(this.startNodeAt(n.loc.start),e===121?`declare`:`abstract`),this.semicolon(!1),this.finishNode(n,`ExpressionStatement`))}break;case 122:return this.tsParseEnumDeclaration(this.startNode());case 108:if(this.lookaheadCharCode()===123){let e=this.startNode();return this.tsParseAmbientExternalModuleDeclaration(e)}break;case 125:{let e=this.tsParseInterfaceDeclaration(this.startNode());if(e)return e;break}case 123:if(this.nextTokenIsStringLiteralOnSameLine()){let e=this.startNode();return this.next(),this.tsParseDeclaration(e,123,!1,t)}else if(this.nextTokenIsIdentifierOnSameLine()){this.raise(Q.InlineModuleDeclarationMustUseString,this.state.startLoc);let e=this.startNode();return this.next(),this.tsParseDeclaration(e,124,!1,t)}break;case 124:if(this.nextTokenIsIdentifierOnSameLine()){let e=this.startNode();return this.next(),this.tsParseDeclaration(e,124,!1,t)}break;case 126:if(this.nextTokenIsIdentifierOnSameLine()){let e=this.startNode();return this.next(),this.tsParseTypeAliasDeclaration(e)}break}return super.parseStatementContent(e,t)}parseAccessModifier(){return this.tsParseModifier([`public`,`protected`,`private`])}tsHasSomeModifiers(e,t){return t.some(t=>HF(t)?e.accessibility===t:!!e[t])}tsIsStartOfStaticBlocks(){return this.isContextual(102)&&this.lookaheadCharCode()===123}parseClassMember(e,t,n){let r=[`declare`,`private`,`public`,`protected`,`override`,`abstract`,`readonly`,`static`];this.tsParseModifiers({allowedModifiers:r,disallowedModifiers:[`in`,`out`],stopOnStartOfClassStaticBlock:!0,errorTemplate:Q.InvalidModifierOnTypeParameterPositions},t);let i=()=>{this.tsIsStartOfStaticBlocks()?(this.next(),this.next(),this.tsHasSomeModifiers(t,r)&&this.raise(Q.StaticBlockCannotHaveModifier,this.state.curPosition()),super.parseClassStaticBlock(e,t)):this.parseClassMemberWithIsStatic(e,t,n,!!t.static)};t.declare?this.tsInAmbientContext(i):i()}parseClassMemberWithIsStatic(e,t,n,r){let i=this.tsTryParseIndexSignature(t);if(i){e.body.push(i),t.abstract&&this.raise(Q.IndexSignatureHasAbstract,t),t.accessibility&&this.raise(Q.IndexSignatureHasAccessibility,t,{modifier:t.accessibility}),t.declare&&this.raise(Q.IndexSignatureHasDeclare,t),t.override&&this.raise(Q.IndexSignatureHasOverride,t);return}!this.state.inAbstractClass&&t.abstract&&this.raise(Q.NonAbstractClassHasAbstractMethod,t),t.override&&(n.hadSuperClass||this.raise(Q.OverrideNotInSubClass,t)),super.parseClassMemberWithIsStatic(e,t,n,r)}parsePostMemberNameModifiers(e){this.eat(13)&&(e.optional=!0),e.readonly&&this.match(6)&&this.raise(Q.ClassMethodHasReadonly,e),e.declare&&this.match(6)&&this.raise(Q.ClassMethodHasDeclare,e)}shouldParseExportDeclaration(){return this.tsIsDeclarationStart()?!0:super.shouldParseExportDeclaration()}parseConditional(e,t,n){if(!this.match(13))return e;if(this.state.maybeInArrowParameters){let t=this.lookaheadCharCode();if(t===44||t===61||t===58||t===41)return this.setOptionalParametersError(n),e}return super.parseConditional(e,t,n)}parseParenItem(e,t){let n=super.parseParenItem(e,t);if(this.eat(13)&&(n.optional=!0,this.resetEndLocation(e)),this.match(10)){let n=this.startNodeAt(t);return n.expression=e,n.typeAnnotation=this.tsParseTypeAnnotation(),this.finishNode(n,`TSTypeCastExpression`)}return e}parseExportDeclaration(e){if(!this.state.isAmbientContext&&this.isContextual(121))return this.tsInAmbientContext(()=>this.parseExportDeclaration(e));let t=this.state.startLoc,n=this.eatContextual(121);if(n&&(this.isContextual(121)||!this.shouldParseExportDeclaration()))throw this.raise(Q.ExpectedAmbientAfterExportDeclare,this.state.startLoc);let r=Y(this.state.type)&&this.tsTryParseExportDeclaration()||super.parseExportDeclaration(e);return r?((r.type===`TSInterfaceDeclaration`||r.type===`TSTypeAliasDeclaration`||n)&&(e.exportKind=`type`),n&&r.type!==`TSImportEqualsDeclaration`&&(this.resetStartLocation(r,t),r.declare=!0),r):null}parseClassId(e,t,n,r){if((!t||n)&&this.isContextual(109))return;super.parseClassId(e,t,n,e.declare?1024:8331);let i=this.tsTryParseTypeParameters(this.tsParseInOutConstModifiers);i&&(e.typeParameters=i)}parseClassPropertyAnnotation(e){e.optional||(this.eat(31)?e.definite=!0:this.eat(13)&&(e.optional=!0));let t=this.tsTryParseTypeAnnotation();t&&(e.typeAnnotation=t)}parseClassProperty(e){if(this.parseClassPropertyAnnotation(e),this.state.isAmbientContext&&!(e.readonly&&!e.typeAnnotation)&&this.match(25)&&this.raise(Q.DeclareClassFieldHasInitializer,this.state.startLoc),e.abstract&&this.match(25)){let{key:t}=e;this.raise(Q.AbstractPropertyHasInitializer,this.state.startLoc,{propertyName:t.type===`Identifier`&&!e.computed?t.name:`[${this.input.slice(this.offsetToSourcePos(t.start),this.offsetToSourcePos(t.end))}]`})}return super.parseClassProperty(e)}parseClassPrivateProperty(e){return e.abstract&&this.raise(Q.PrivateElementHasAbstract,e),e.accessibility&&this.raise(Q.PrivateElementHasAccessibility,e,{modifier:e.accessibility}),this.parseClassPropertyAnnotation(e),super.parseClassPrivateProperty(e)}parseClassAccessorProperty(e){return this.parseClassPropertyAnnotation(e),e.optional&&this.raise(Q.AccessorCannotBeOptional,e),super.parseClassAccessorProperty(e)}pushClassMethod(e,t,n,r,i,a){let o=this.tsTryParseTypeParameters(this.tsParseConstModifier);o&&i&&this.raise(Q.ConstructorHasTypeParameters,o);let{declare:s=!1,kind:c}=t;s&&(c===`get`||c===`set`)&&this.raise(Q.DeclareAccessor,t,{kind:c}),o&&(t.typeParameters=o),super.pushClassMethod(e,t,n,r,i,a)}pushClassPrivateMethod(e,t,n,r){let i=this.tsTryParseTypeParameters(this.tsParseConstModifier);i&&(t.typeParameters=i),super.pushClassPrivateMethod(e,t,n,r)}declareClassPrivateMethodInScope(e,t){e.type!==`TSDeclareMethod`&&(e.type===`MethodDefinition`&&e.value.body==null||super.declareClassPrivateMethodInScope(e,t))}parseClassSuper(e){if(super.parseClassSuper(e),e.superClass)if(e.superClass.type===`TSInstantiationExpression`){let t=e.superClass,n=t.expression;this.takeSurroundingComments(n,n.start,n.end);let r=t.typeArguments;this.takeSurroundingComments(r,r.start,r.end),e.superClass=n,e.superTypeArguments=r}else (this.match(43)||this.match(47))&&(e.superTypeArguments=this.tsParseTypeArgumentsInExpression());this.eatContextual(109)&&(e.implements=this.tsParseHeritageClause(`implements`))}parseObjPropValue(e,t,n,r,i,a,o){let s=this.tsTryParseTypeParameters(this.tsParseConstModifier);return s&&(e.typeParameters=s),super.parseObjPropValue(e,t,n,r,i,a,o)}parseFunctionParams(e,t){let n=this.tsTryParseTypeParameters(this.tsParseConstModifier);n&&(e.typeParameters=n),super.parseFunctionParams(e,t)}parseVarId(e,t){super.parseVarId(e,t),e.id.type===`Identifier`&&!this.hasPrecedingLineBreak()&&this.eat(31)&&(e.definite=!0);let n=this.tsTryParseTypeAnnotation();n&&(e.id.typeAnnotation=n,this.resetEndLocation(e.id))}parseAsyncArrowFromCallExpression(e,t){return this.match(10)&&(e.returnType=this.tsParseTypeAnnotation()),super.parseAsyncArrowFromCallExpression(e,t)}parseMaybeAssign(e,t){let n,r,i;if(this.hasPlugin(`jsx`)&&(this.match(138)||this.match(43))){if(n=this.state.clone(),r=this.tryParse(()=>super.parseMaybeAssign(e,t),n),!r.error)return r.node;let{context:i}=this.state,a=i[i.length-1];(a===X.j_oTag||a===X.j_expr)&&i.pop()}if(!r?.error&&!this.match(43))return super.parseMaybeAssign(e,t);(!n||n===this.state)&&(n=this.state.clone());let a,o=this.tryParse(n=>{a=this.tsParseTypeParameters(this.tsParseConstModifier);let r=super.parseMaybeAssign(e,t);if((r.type!==`ArrowFunctionExpression`||r.extra?.parenthesized)&&n(),a?.params.length!==0&&this.resetStartLocationFromNode(r,a),r.typeParameters=a,this.hasPlugin(`jsx`)&&r.typeParameters.params.length===1&&!r.typeParameters.extra?.trailingComma){let e=r.typeParameters.params[0];e.constraint||this.raise(Q.SingleTypeParameterWithoutTrailingComma,pN(e.loc.end,1),{typeParameterName:e.name.name})}return r},n);if(!o.error&&!o.aborted)return a&&this.reportReservedArrowTypeParam(a),o.node;if(!r&&(BF(!this.hasPlugin(`jsx`)),i=this.tryParse(()=>super.parseMaybeAssign(e,t),n),!i.error))return i.node;if(r?.node)return this.state=r.failState,r.node;if(o.node)return this.state=o.failState,a&&this.reportReservedArrowTypeParam(a),o.node;if(i?.node)return this.state=i.failState,i.node;throw r?.error||o.error||i?.error}reportReservedArrowTypeParam(e){e.params.length===1&&!e.params[0].constraint&&!e.extra?.trailingComma&&this.getPluginOption(`typescript`,`disallowAmbiguousJSXLike`)&&this.raise(Q.ReservedArrowTypeParam,e)}parseMaybeUnary(e,t){return!this.hasPlugin(`jsx`)&&this.match(43)?this.tsParseTypeAssertion():super.parseMaybeUnary(e,t)}parseArrow(e){if(this.match(10)){let t=this.tryParse(e=>{let t=this.tsParseTypeOrTypePredicateAnnotation(10);return(this.canInsertSemicolon()||!this.match(15))&&e(),t});if(t.aborted)return;t.thrown||(t.error&&(this.state=t.failState),e.returnType=t.node)}return super.parseArrow(e)}parseFunctionParamType(e){this.eat(13)&&(e.optional=!0);let t=this.tsTryParseTypeAnnotation();return t&&(e.typeAnnotation=t),this.resetEndLocation(e),e}isAssignable(e,t){switch(e.type){case`TSTypeCastExpression`:return this.isAssignable(e.expression,t);case`TSParameterProperty`:return!0;default:return super.isAssignable(e,t)}}toAssignable(e,t=!1){switch(e.type){case`ParenthesizedExpression`:this.toAssignableParenthesizedExpression(e,t);break;case`TSAsExpression`:case`TSSatisfiesExpression`:case`TSNonNullExpression`:case`TSTypeAssertion`:t?this.expressionScope.recordArrowParameterBindingError(Q.UnexpectedTypeCastInParameter,e):this.raise(Q.UnexpectedTypeCastInParameter,e),this.toAssignable(e.expression,t);break;case`AssignmentExpression`:!t&&e.left.type===`TSTypeCastExpression`&&(e.left=this.typeCastToParameter(e.left));default:super.toAssignable(e,t)}}toAssignableParenthesizedExpression(e,t){switch(e.expression.type){case`TSAsExpression`:case`TSSatisfiesExpression`:case`TSNonNullExpression`:case`TSTypeAssertion`:case`ParenthesizedExpression`:this.toAssignable(e.expression,t);break;default:super.toAssignable(e,t)}}checkToRestConversion(e,t){switch(e.type){case`TSAsExpression`:case`TSSatisfiesExpression`:case`TSTypeAssertion`:case`TSNonNullExpression`:this.checkToRestConversion(e.expression,!1);break;default:super.checkToRestConversion(e,t)}}isValidLVal(e,t,n,r){switch(e){case`TSTypeCastExpression`:return!0;case`TSParameterProperty`:return`parameter`;case`TSNonNullExpression`:return`expression`;case`TSAsExpression`:case`TSSatisfiesExpression`:case`TSTypeAssertion`:return(r!==64||!n)&&[`expression`,!0];default:return super.isValidLVal(e,t,n,r)}}parseBindingAtom(){return this.state.type===74?this.parseIdentifier(!0):super.parseBindingAtom()}parseMaybeDecoratorArguments(e,t){if(this.match(43)||this.match(47)){let n=this.tsParseTypeArgumentsInExpression();if(this.match(6)){let r=super.parseMaybeDecoratorArguments(e,t);return r.typeArguments=n,r}this.unexpected(null,6)}return super.parseMaybeDecoratorArguments(e,t)}checkCommaAfterRest(e){return this.state.isAmbientContext&&this.match(8)&&this.lookaheadCharCode()===e?(this.next(),!1):super.checkCommaAfterRest(e)}isClassMethod(){return this.match(43)||super.isClassMethod()}isClassProperty(){return this.match(31)||this.match(10)||super.isClassProperty()}parseMaybeDefault(e,t){let n=super.parseMaybeDefault(e,t);return n.type===`AssignmentPattern`&&n.typeAnnotation&&n.right.start<n.typeAnnotation.start&&this.raise(Q.TypeAnnotationAfterAssign,n.typeAnnotation),n}getTokenFromCode(e){if(this.state.inType){if(e===62){this.finishOp(44,1);return}if(e===60){this.finishOp(43,1);return}}super.getTokenFromCode(e)}reScan_lt_gt(){let{type:e}=this.state;e===43?(--this.state.pos,this.readToken_lt()):e===44&&(--this.state.pos,this.readToken_gt())}reScan_lt(){let{type:e}=this.state;return e===47?(this.state.pos-=2,this.finishOp(43,1),43):e}toAssignableListItem(e,t,n){let r=e[t];r.type===`TSTypeCastExpression`&&(e[t]=this.typeCastToParameter(r)),super.toAssignableListItem(e,t,n)}typeCastToParameter(e){return e.expression.typeAnnotation=e.typeAnnotation,this.resetEndLocation(e.expression,e.typeAnnotation.loc.end),e.expression}shouldParseArrow(e){return this.match(10)?e.every(e=>this.isAssignable(e,!0)):super.shouldParseArrow(e)}shouldParseAsyncArrow(){return this.match(10)||super.shouldParseAsyncArrow()}canHaveLeadingDecorator(){return super.canHaveLeadingDecorator()||this.isAbstractClass()}jsxParseOpeningElementAfterName(e){if(this.match(43)||this.match(47)){let t=this.tsTryParseAndCatch(()=>this.tsParseTypeArgumentsInExpression());t&&(e.typeArguments=t)}return super.jsxParseOpeningElementAfterName(e)}getGetterSetterExpectedParamCount(e){let t=super.getGetterSetterExpectedParamCount(e),n=this.getObjectOrClassMethodParams(e)[0];return n&&this.isThisParam(n)?t+1:t}parseCatchClauseParam(){let e=super.parseCatchClauseParam(),t=this.tsTryParseTypeAnnotation();return t&&(e.typeAnnotation=t,this.resetEndLocation(e)),e}tsInAmbientContext(e){let{isAmbientContext:t,strict:n}=this.state;this.state.isAmbientContext=!0,this.state.strict=!1;try{return e()}finally{this.state.isAmbientContext=t,this.state.strict=n}}parseClass(e,t,n){let r=this.state.inAbstractClass;this.state.inAbstractClass=!!e.abstract;try{return super.parseClass(e,t,n)}finally{this.state.inAbstractClass=r}}tsParseAbstractDeclaration(e,t){if(this.match(76))return e.abstract=!0,this.maybeTakeDecorators(t,this.parseClass(e,!0,!1));if(this.isContextual(125))return this.hasFollowingLineBreak()?null:(e.abstract=!0,this.raise(Q.NonClassMethodPropertyHasAbstractModifier,e),this.tsParseInterfaceDeclaration(e));throw this.unexpected(null,76)}parseMethod(e,t,n,r,i,a,o){let s=super.parseMethod(e,t,n,r,i,a,o);if((s.abstract||s.type===`TSAbstractMethodDefinition`)&&(this.hasPlugin(`estree`)?s.value:s).body){let{key:e}=s;this.raise(Q.AbstractMethodHasImplementation,s,{methodName:e.type===`Identifier`&&!s.computed?e.name:`[${this.input.slice(this.offsetToSourcePos(e.start),this.offsetToSourcePos(e.end))}]`})}return s}tsParseTypeParameterName(){return this.parseIdentifier()}shouldParseAsAmbientContext(){return!!this.getPluginOption(`typescript`,`dts`)}parse(){return this.shouldParseAsAmbientContext()&&(this.state.isAmbientContext=!0),super.parse()}getExpression(){return this.shouldParseAsAmbientContext()&&(this.state.isAmbientContext=!0),super.getExpression()}parseExportSpecifier(e,t,n,r){return!t&&r?(this.parseTypeOnlyImportExportSpecifier(e,!1,n),this.finishNode(e,`ExportSpecifier`)):(e.exportKind=`value`,super.parseExportSpecifier(e,t,n,r))}parseImportSpecifier(e,t,n,r,i){return!t&&r?(this.parseTypeOnlyImportExportSpecifier(e,!0,n),this.finishNode(e,`ImportSpecifier`)):(e.importKind=`value`,super.parseImportSpecifier(e,t,n,r,n?4098:4096))}parseTypeOnlyImportExportSpecifier(e,t,n){let r=t?`imported`:`local`,i=t?`local`:`exported`,a=e[r],o,s=!1,c=!0,l=a.loc.start;if(this.isContextual(89)){let e=this.parseIdentifier();if(this.isContextual(89)){let n=this.parseIdentifier();WN(this.state.type)?(s=!0,a=e,o=t?this.parseIdentifier():this.parseModuleExportName(),c=!1):(o=n,c=!1)}else WN(this.state.type)?(c=!1,o=t?this.parseIdentifier():this.parseModuleExportName()):(s=!0,a=e)}else WN(this.state.type)&&(s=!0,t?(a=this.parseIdentifier(!0),this.isContextual(89)||this.checkReservedWord(a.name,a.loc.start,!0,!0)):a=this.parseModuleExportName());s&&n&&this.raise(t?Q.TypeModifierIsUsedInTypeImports:Q.TypeModifierIsUsedInTypeExports,l),e[r]=a,e[i]=o;let u=t?`importKind`:`exportKind`;e[u]=s?`type`:`value`,c&&this.eatContextual(89)&&(e[i]=t?this.parseIdentifier():this.parseModuleExportName()),e[i]||(e[i]=this.cloneIdentifier(e[r])),t&&this.checkIdentifier(e[i],s?4098:4096)}fillOptionalPropertiesForTSESLint(e){switch(e.type){case`ExpressionStatement`:e.directive??=void 0;return;case`RestElement`:e.value=void 0;case`Identifier`:case`ArrayPattern`:case`AssignmentPattern`:case`ObjectPattern`:e.decorators??=[],e.optional??=!1,e.typeAnnotation??=void 0;return;case`TSParameterProperty`:e.accessibility??=void 0,e.decorators??=[],e.override??=!1,e.readonly??=!1,e.static??=!1;return;case`TSEmptyBodyFunctionExpression`:e.body=null;case`TSDeclareFunction`:case`FunctionDeclaration`:case`FunctionExpression`:case`ClassMethod`:case`ClassPrivateMethod`:e.declare??=!1,e.returnType??=void 0,e.typeParameters??=void 0;return;case`Property`:e.optional??=!1;return;case`TSMethodSignature`:case`TSPropertySignature`:e.optional??=!1;case`TSIndexSignature`:e.accessibility??=void 0,e.readonly??=!1,e.static??=!1;return;case`TSAbstractPropertyDefinition`:case`PropertyDefinition`:case`TSAbstractAccessorProperty`:case`AccessorProperty`:e.declare??=!1,e.definite??=!1,e.readonly??=!1,e.typeAnnotation??=void 0;case`TSAbstractMethodDefinition`:case`MethodDefinition`:e.accessibility??=void 0,e.decorators??=[],e.override??=!1,e.optional??=!1;return;case`ClassExpression`:e.id??=null;case`ClassDeclaration`:e.abstract??=!1,e.declare??=!1,e.decorators??=[],e.implements??=[],e.superTypeArguments??=void 0,e.typeParameters??=void 0;return;case`TSTypeAliasDeclaration`:case`VariableDeclaration`:e.declare??=!1;return;case`VariableDeclarator`:e.definite??=!1;return;case`TSEnumDeclaration`:e.const??=!1,e.declare??=!1;return;case`TSEnumMember`:e.computed??=!1;return;case`TSImportType`:e.qualifier??=null,e.options??=null,e.typeArguments??=null;return;case`TSInterfaceDeclaration`:e.declare??=!1,e.extends??=[];return;case`TSMappedType`:e.optional??=!1,e.readonly??=void 0;return;case`TSModuleDeclaration`:e.declare??=!1,e.global??=e.kind===`global`;return;case`TSTypeParameter`:e.const??=!1,e.in??=!1,e.out??=!1;return}}chStartsBindingIdentifierAndNotRelationalOperator(e,t){if(gP(e)){if(RF.lastIndex=t,RF.test(this.input)){let e=this.codePointAtPos(RF.lastIndex);if(!_P(e)&&e!==92)return!1}return!0}else if(e===92)return!0;else return!1}nextTokenIsIdentifierAndNotTSRelationalOperatorOnSameLine(){let e=this.nextTokenInLineStart(),t=this.codePointAtPos(e);return this.chStartsBindingIdentifierAndNotRelationalOperator(t,e)}nextTokenIsStringLiteralOnSameLine(){let e=this.nextTokenInLineStart(),t=this.codePointAtPos(e);return t===34||t===39}};function KF(e){if(e.type!==`MemberExpression`)return!1;let{computed:t,property:n}=e;return t&&n.type!==`StringLiteral`&&(n.type!==`TemplateLiteral`||n.expressions.length>0)?!1:XF(e.object)}function qF(e,t){let{type:n}=e;if(e.extra?.parenthesized)return!1;if(t){if(n===`Literal`){let{value:t}=e;if(typeof t==`string`||typeof t==`boolean`)return!0}}else if(n===`StringLiteral`||n===`BooleanLiteral`)return!0;return!!(JF(e,t)||YF(e,t)||n===`TemplateLiteral`&&e.expressions.length===0||KF(e))}function JF(e,t){return t?e.type===`Literal`&&(typeof e.value==`number`||`bigint`in e):e.type===`NumericLiteral`||e.type===`BigIntLiteral`}function YF(e,t){if(e.type===`UnaryExpression`){let{operator:n,argument:r}=e;if(n===`-`&&JF(r,t))return!0}return!1}function XF(e){return e.type===`Identifier`?!0:e.type!==`MemberExpression`||e.computed?!1:XF(e.object)}const ZF=TN`placeholders`({ClassNameIsRequired:`A class name is required.`,UnexpectedSpace:`Unexpected space in placeholder.`});var QF=e=>class extends e{parsePlaceholder(e){if(this.match(129)){let t=this.startNode();return this.next(),this.assertNoSpace(),t.name=super.parseIdentifier(!0),this.assertNoSpace(),this.expect(129),this.finishPlaceholder(t,e)}}finishPlaceholder(e,t){let n=e;return(!n.expectedNode||!n.type)&&(n=this.finishNode(n,`Placeholder`)),n.expectedNode=t,n}getTokenFromCode(e){e===37&&this.input.charCodeAt(this.state.pos+1)===37?this.finishOp(129,2):super.getTokenFromCode(e)}parseExprAtom(e){return this.parsePlaceholder(`Expression`)||super.parseExprAtom(e)}parseIdentifier(e){return this.parsePlaceholder(`Identifier`)||super.parseIdentifier(e)}checkReservedWord(e,t,n,r){e!==void 0&&super.checkReservedWord(e,t,n,r)}cloneIdentifier(e){let t=super.cloneIdentifier(e);return t.type===`Placeholder`&&(t.expectedNode=e.expectedNode),t}cloneStringLiteral(e){return e.type===`Placeholder`?this.cloneIdentifier(e):super.cloneStringLiteral(e)}parseBindingAtom(){return this.parsePlaceholder(`Pattern`)||super.parseBindingAtom()}isValidLVal(e,t,n,r){return e===`Placeholder`||super.isValidLVal(e,t,n,r)}toAssignable(e,t){e&&e.type===`Placeholder`&&e.expectedNode===`Expression`?e.expectedNode=`Pattern`:super.toAssignable(e,t)}chStartsBindingIdentifier(e,t){if(super.chStartsBindingIdentifier(e,t))return!0;let n=this.nextTokenStart();return this.input.charCodeAt(n)===37&&this.input.charCodeAt(n+1)===37}verifyBreakContinue(e,t){e.label?.type!==`Placeholder`&&super.verifyBreakContinue(e,t)}parseExpressionStatement(e,t){if(t.type!==`Placeholder`||t.extra?.parenthesized)return super.parseExpressionStatement(e,t);if(this.match(10)){let n=e;return n.label=this.finishPlaceholder(t,`Identifier`),this.next(),n.body=super.parseStatementOrSloppyAnnexBFunctionDeclaration(),this.finishNode(n,`LabeledStatement`)}this.semicolon();let n=e;return n.name=t.name,this.finishPlaceholder(n,`Statement`)}parseBlock(e,t,n){return this.parsePlaceholder(`BlockStatement`)||super.parseBlock(e,t,n)}parseFunctionId(e){return this.parsePlaceholder(`Identifier`)||super.parseFunctionId(e)}parseClass(e,t,n){let r=t?`ClassDeclaration`:`ClassExpression`;this.next();let i=this.state.strict,a=this.parsePlaceholder(`Identifier`);if(a)if(this.match(77)||this.match(129)||this.match(2))e.id=a;else if(n||!t)return e.id=null,e.body=this.finishPlaceholder(a,`ClassBody`),this.finishNode(e,r);else throw this.raise(ZF.ClassNameIsRequired,this.state.startLoc);else this.parseClassId(e,t,n);return super.parseClassSuper(e),e.body=this.parsePlaceholder(`ClassBody`)||super.parseClassBody(!!e.superClass,i),this.finishNode(e,r)}parseExport(e,t){let n=this.parsePlaceholder(`Identifier`);if(!n)return super.parseExport(e,t);let r=e;if(!this.isContextual(94)&&!this.match(8))return r.specifiers=[],r.source=null,r.declaration=this.finishPlaceholder(n,`Declaration`),this.finishNode(r,`ExportNamedDeclaration`);this.expectPlugin(`exportDefaultFrom`);let i=this.startNode();return i.exported=n,r.specifiers=[this.finishNode(i,`ExportDefaultSpecifier`)],super.parseExport(r,t)}isExportDefaultSpecifier(){if(this.match(61)){let e=this.nextTokenStart();if(this.isUnparsedContextual(e,`from`)&&this.input.startsWith(rP(129),this.nextTokenStartSince(e+4)))return!0}return super.isExportDefaultSpecifier()}maybeParseExportDefaultSpecifier(e,t){return e.specifiers?.length?!0:super.maybeParseExportDefaultSpecifier(e,t)}checkExport(e){let{specifiers:t}=e;t?.length&&(e.specifiers=t.filter(e=>e.exported.type===`Placeholder`)),super.checkExport(e),e.specifiers=t}parseImport(e){let t=this.parsePlaceholder(`Identifier`);if(!t)return super.parseImport(e);if(e.specifiers=[],!this.isContextual(94)&&!this.match(8))return e.source=this.finishPlaceholder(t,`StringLiteral`),this.semicolon(),this.finishNode(e,`ImportDeclaration`);let n=this.startNodeAtNode(t);return n.local=t,e.specifiers.push(this.finishNode(n,`ImportDefaultSpecifier`)),this.eat(8)&&(this.maybeParseStarImportSpecifier(e)||this.parseNamedImportSpecifiers(e)),this.expectContextual(94),e.source=this.parseImportSource(),this.semicolon(),this.finishNode(e,`ImportDeclaration`)}parseImportSource(){return this.parsePlaceholder(`StringLiteral`)||super.parseImportSource()}assertNoSpace(){this.state.start>this.offsetToSourcePos(this.state.lastTokEndLoc.index)&&this.raise(ZF.UnexpectedSpace,this.state.lastTokEndLoc)}},$F=e=>class extends e{parseV8Intrinsic(){if(this.match(50)){let e=this.state.startLoc,t=this.startNode();if(this.next(),Y(this.state.type)){let e=this.parseIdentifierName(),n=this.createIdentifier(t,e);if(this.castNodeTo(n,`V8IntrinsicIdentifier`),this.match(6))return n}this.unexpected(e)}}parseExprAtom(e){return this.parseV8Intrinsic()||super.parseExprAtom(e)}};const eI=[`fsharp`,`hack`],tI=[`^^`,`@@`,`^`,`%`,`#`];function nI(e){if(e.has(`decorators`)&&e.has(`decorators-legacy`))throw Error(`Cannot use the decorators and decorators-legacy plugin together`);if(e.has(`flow`)&&e.has(`typescript`))throw Error(`Cannot combine flow and typescript plugins.`);if(e.has(`placeholders`)&&e.has(`v8intrinsic`))throw Error(`Cannot combine placeholders and v8intrinsic plugins.`);if(e.has(`pipelineOperator`)){let t=e.get(`pipelineOperator`).proposal;if(!eI.includes(t)){let e=eI.map(e=>`"${e}"`).join(`, `);throw Error(`"pipelineOperator" requires "proposal" option whose value must be one of: ${e}.`)}if(t===`hack`){if(e.has(`placeholders`))throw Error(`Cannot combine placeholders plugin and Hack-style pipes.`);if(e.has(`v8intrinsic`))throw Error(`Cannot combine v8intrinsic plugin and Hack-style pipes.`);let t=e.get(`pipelineOperator`).topicToken;if(!tI.includes(t)){let e=tI.map(e=>`"${e}"`).join(`, `);throw Error(`"pipelineOperator" in "proposal": "hack" mode also requires a "topicToken" option whose value must be one of: ${e}.`)}}}if(e.has(`moduleAttributes`))throw Error("`moduleAttributes` has been removed in Babel 8, please migrate to import attributes instead.");if(e.has(`importAssertions`))throw Error("`importAssertions` has been removed in Babel 8, please use import attributes instead.");if(e.has(`deprecatedImportAssert`)?console.warn("`deprecatedImportAssert` has been removed in Babel 8, please use import attributes instead."):e.has(`importAttributes`)&&e.get(`importAttributes`).deprecatedAssertSyntax&&console.warn("The 'importAttributes' plugin has been removed in Babel 8. Please migrate any usage of `assert`-style attributes to `with`."),e.has(`recordAndTuple`))throw Error(`The 'recordAndTuple' plugin has been removed in Babel 8. Please remove it from your configuration.`);if(e.has(`asyncDoExpressions`)&&!e.has(`doExpressions`)){let e=Error(`'asyncDoExpressions' requires 'doExpressions', please add 'doExpressions' to parser plugins.`);throw e.missingPlugins=`doExpressions`,e}if(e.has(`optionalChainingAssign`)&&e.get(`optionalChainingAssign`).version!==`2023-07`)throw Error(`The 'optionalChainingAssign' plugin requires a 'version' option, representing the last proposal update. Currently, the only supported value is '2023-07'.`);if(e.has(`discardBinding`)&&e.get(`discardBinding`).syntaxType!==`void`)throw Error(`The 'discardBinding' plugin requires a 'syntaxType' option. Currently the only supported value is 'void'.`);if(e.has(`decimal`))throw Error(`The 'decimal' plugin has been removed in Babel 8. Please remove it from your configuration.`);if(e.has(`importReflection`))throw Error(`The 'importReflection' plugin has been removed in Babel 8. Use 'sourcePhaseImports' instead, and replace 'import module' with 'import source' in your code.`)}const rI={estree:jN,jsx:ZP,flow:BP,typescript:GF,v8intrinsic:$F,placeholders:QF},iI=Object.keys(rI);var aI=class extends LF{checkProto(e,t,n){if(e.type===`SpreadElement`||this.isObjectMethod(e)||e.computed||e.shorthand)return t;let r=e.key;return(r.type===`Identifier`?r.name:r.value)===`__proto__`?(t&&(n?n.doubleProtoLoc===null&&(n.doubleProtoLoc=r.loc.start):this.raise(G.DuplicateProto,r)),!0):t}shouldExitDescending(e,t){return e.type===`ArrowFunctionExpression`&&this.offsetToSourcePos(e.start)===t}getExpression(){if(this.enterInitialScopes(),this.nextToken(),this.match(135))throw this.raise(G.ParseExpressionEmptyInput,this.state.startLoc);let e=this.parseExpression();if(!this.match(135))throw this.raise(G.ParseExpressionExpectsEOF,this.state.startLoc,{unexpected:this.input.codePointAt(this.state.start)});return this.finalizeRemainingComments(),e.comments=this.comments,e.errors=this.state.errors,this.optionFlags&256&&(e.tokens=uI(this.tokens)),e}parseExpression(e,t){return e?this.disallowInAnd(()=>this.parseExpressionBase(t)):this.allowInAnd(()=>this.parseExpressionBase(t))}parseExpressionBase(e){let t=this.state.startLoc,n=this.parseMaybeAssign(e);if(this.match(8)){let r=this.startNodeAt(t);for(r.expressions=[n];this.eat(8);)r.expressions.push(this.parseMaybeAssign(e));return this.toReferencedList(r.expressions),this.finishNode(r,`SequenceExpression`)}return n}parseMaybeAssignDisallowIn(e,t){return this.disallowInAnd(()=>this.parseMaybeAssign(e,t))}parseMaybeAssignAllowIn(e,t){return this.allowInAnd(()=>this.parseMaybeAssign(e,t))}setOptionalParametersError(e){e.optionalParametersLoc=this.state.startLoc}parseMaybeAssign(e,t){let n=this.state.startLoc,r=this.isContextual(104);if(r&&this.prodParam.hasYield){this.next();let e=this.parseYield(n);return t&&(e=t.call(this,e,n)),e}let i;e?i=!1:(e=new MF,i=!0);let{type:a}=this.state;(a===6||Y(a))&&(this.state.potentialArrowAt=this.state.start);let o=this.parseMaybeConditional(e);if(t&&(o=t.call(this,o,n)),JN(this.state.type)){let t=this.startNodeAt(n),r=this.state.value;if(t.operator=r,this.match(25)){this.toAssignable(o,!0),t.left=o;let r=n.index;e.doubleProtoLoc!=null&&e.doubleProtoLoc.index>=r&&(e.doubleProtoLoc=null),e.shorthandAssignLoc!=null&&e.shorthandAssignLoc.index>=r&&(e.shorthandAssignLoc=null),e.privateKeyLoc!=null&&e.privateKeyLoc.index>=r&&(this.checkDestructuringPrivate(e),e.privateKeyLoc=null),e.voidPatternLoc!=null&&e.voidPatternLoc.index>=r&&(e.voidPatternLoc=null)}else t.left=o;return this.next(),t.right=this.parseMaybeAssign(),this.checkLVal(o,this.finishNode(t,`AssignmentExpression`),void 0,void 0,void 0,void 0,r===`||=`||r===`&&=`||r===`??=`),t}else i&&this.checkExpressionErrors(e,!0);if(r){let{type:e}=this.state;if((this.hasPlugin(`v8intrinsic`)?qN(e):qN(e)&&!this.match(50))&&!this.isAmbiguousPrefixOrIdentifier())return this.raiseOverwrite(G.YieldNotInGeneratorFunction,n),this.parseYield(n)}return o}parseMaybeConditional(e){let t=this.state.startLoc,n=this.state.potentialArrowAt,r=this.parseExprOps(e);return this.shouldExitDescending(r,n)?r:this.parseConditional(r,t,e)}parseConditional(e,t,n){if(this.eat(13)){let n=this.startNodeAt(t);return n.test=e,n.consequent=this.parseMaybeAssignAllowIn(),this.expect(10),n.alternate=this.parseMaybeAssign(),this.finishNode(n,`ConditionalExpression`)}return e}parseMaybeUnaryOrPrivate(e){return this.match(134)?this.parsePrivateName():this.parseMaybeUnary(e)}parseExprOps(e){let t=this.state.startLoc,n=this.state.potentialArrowAt,r=this.parseMaybeUnaryOrPrivate(e);return this.shouldExitDescending(r,n)?r:this.parseExprOp(r,t,-1)}parseExprOp(e,t,n){if(this.isPrivateName(e)){let t=this.getPrivateNameSV(e);(n>=iP(54)||!this.prodParam.hasIn||!this.match(54))&&this.raise(G.PrivateInExpectedIn,e,{identifierName:t}),this.classScope.usePrivateName(t,e.loc.start)}let r=this.state.type;if(QN(r)&&(this.prodParam.hasIn||!this.match(54))){let i=iP(r);if(i>n){if(r===35&&(this.expectPlugin(`pipelineOperator`),this.state.inFSharpPipelineDirectBody))return e;let a=this.startNodeAt(t);a.left=e,a.operator=this.state.value;let o=r===37||r===38,s=r===36;s&&(i=iP(38)),this.next(),a.right=this.parseExprOpRightExpr(r,i);let c=this.finishNode(a,o||s?`LogicalExpression`:`BinaryExpression`),l=this.state.type;if(s&&(l===37||l===38)||o&&l===36)throw this.raise(G.MixingCoalesceWithLogical,this.state.startLoc);return this.parseExprOp(c,t,n)}}return e}parseExprOpRightExpr(e,t){switch(e){case 35:switch(this.getPluginOption(`pipelineOperator`,`proposal`)){case`hack`:return this.withTopicBindingContext(()=>this.parseHackPipeBody());case`fsharp`:return this.withSoloAwaitPermittingContext(()=>this.parseFSharpPipelineBody(t))}default:return this.parseExprOpBaseRightExpr(e,t)}}parseExprOpBaseRightExpr(e,t){let n=this.state.startLoc;return this.parseExprOp(this.parseMaybeUnaryOrPrivate(),n,aP(e)?t-1:t)}parseHackPipeBody(){let{startLoc:e}=this.state,t=this.parseMaybeAssign();return xN.has(t.type)&&!t.extra?.parenthesized&&this.raise(G.PipeUnparenthesizedBody,e,{type:t.type}),this.topicReferenceWasUsedInCurrentContext()||this.raise(G.PipeTopicUnused,e),t}checkExponentialAfterUnary(e){this.match(53)&&this.raise(G.UnexpectedTokenUnaryExponentiation,e.argument)}parseMaybeUnary(e,t){let n=this.state.startLoc,r=this.isContextual(92);if(r&&this.recordAwaitIfAllowed()){this.next();let e=this.parseAwait(n);return t||this.checkExponentialAfterUnary(e),e}let i=this.match(30),a=this.startNode();if(eP(this.state.type)){a.operator=this.state.value,a.prefix=!0,this.match(68)&&this.expectPlugin(`throwExpressions`);let n=this.match(85);if(this.next(),a.argument=this.parseMaybeUnary(null,!0),this.checkExpressionErrors(e,!0),this.state.strict&&n){let e=a.argument;e.type===`Identifier`?this.raise(G.StrictDelete,a):this.hasPropertyAsPrivateName(e)&&this.raise(G.DeletePrivateField,a)}if(!i)return t||this.checkExponentialAfterUnary(a),this.finishNode(a,`UnaryExpression`)}let o=this.parseUpdate(a,i,e);if(r){let{type:e}=this.state;if((this.hasPlugin(`v8intrinsic`)?qN(e):qN(e)&&!this.match(50))&&!this.isAmbiguousPrefixOrIdentifier())return this.raiseOverwrite(G.AwaitNotInAsyncContext,n),this.parseAwait(n)}return o}parseUpdate(e,t,n){if(t){let t=e;return this.checkLVal(t.argument,this.finishNode(t,`UpdateExpression`)),e}let r=this.state.startLoc,i=this.parseExprSubscripts(n);if(this.checkExpressionErrors(n,!1))return i;for(;$N(this.state.type)&&!this.canInsertSemicolon();){let e=this.startNodeAt(r);e.operator=this.state.value,e.prefix=!1,e.argument=i,this.next(),this.checkLVal(i,i=this.finishNode(e,`UpdateExpression`))}return i}parseExprSubscripts(e){let t=this.state.startLoc,n=this.state.potentialArrowAt,r=this.parseExprAtom(e);return this.shouldExitDescending(r,n)?r:this.parseSubscripts(r,t)}parseSubscripts(e,t,n){let r={optionalChainMember:!1,maybeAsyncArrow:this.atPossibleAsyncArrow(e),stop:!1};do e=this.parseSubscript(e,t,n,r),r.maybeAsyncArrow=!1;while(!r.stop);return e}parseSubscript(e,t,n,r){let{type:i}=this.state;if(!n&&i===11)return this.parseBind(e,t,n,r);if(oP(i))return this.parseTaggedTemplateExpression(e,t,r);let a=!1;if(i===14){if(n&&(this.raise(G.OptionalChainingNoNew,this.state.startLoc),this.lookaheadCharCode()===40))return this.stopParseSubscript(e,r);r.optionalChainMember=a=!0,this.next()}if(!n&&this.match(6))return this.parseCoverCallAndAsyncArrowHead(e,t,r,a);{let n=this.eat(0);return n||a||this.eat(12)?this.parseMember(e,t,r,n,a):this.stopParseSubscript(e,r)}}stopParseSubscript(e,t){return t.stop=!0,e}parseMember(e,t,n,r,i){let a=this.startNodeAt(t);return a.object=e,a.computed=r,r?(a.property=this.parseExpression(),this.expect(1)):this.match(134)?(e.type===`Super`&&this.raise(G.SuperPrivateField,t),this.classScope.usePrivateName(this.state.value,this.state.startLoc),a.property=this.parsePrivateName()):a.property=this.parseIdentifier(!0),n.optionalChainMember?(a.optional=i,this.finishNode(a,`OptionalMemberExpression`)):this.finishNode(a,`MemberExpression`)}parseBind(e,t,n,r){let i=this.startNodeAt(t);return i.object=e,this.next(),i.callee=this.parseNoCallExpr(),r.stop=!0,this.parseSubscripts(this.finishNode(i,`BindExpression`),t,n)}parseCoverCallAndAsyncArrowHead(e,t,n,r){let i=this.state.maybeInArrowParameters,a=null;this.state.maybeInArrowParameters=!0,this.next();let o=this.startNodeAt(t);o.callee=e;let{maybeAsyncArrow:s,optionalChainMember:c}=n;s&&(this.expressionScope.enter(kF()),a=new MF),c&&(o.optional=r),r?o.arguments=this.parseCallExpressionArguments():o.arguments=this.parseCallExpressionArguments(e.type!==`Super`,o,a);let l=this.finishCallExpression(o,c);return s&&this.shouldParseAsyncArrow()&&!r?(n.stop=!0,this.checkDestructuringPrivate(a),this.expressionScope.validateAsPattern(),this.expressionScope.exit(),l=this.parseAsyncArrowFromCallExpression(this.startNodeAt(t),l)):(s&&(this.checkExpressionErrors(a,!0),this.expressionScope.exit()),this.toReferencedArguments(l)),this.state.maybeInArrowParameters=i,l}toReferencedArguments(e,t){this.toReferencedListDeep(e.arguments,t)}parseTaggedTemplateExpression(e,t,n){let r=this.startNodeAt(t);return r.tag=e,r.quasi=this.parseTemplate(!0),n.optionalChainMember&&this.raise(G.OptionalChainingNoTemplate,t),this.finishNode(r,`TaggedTemplateExpression`)}atPossibleAsyncArrow(e){return e.type===`Identifier`&&e.name===`async`&&this.state.lastTokEndLoc.index===e.end&&!this.canInsertSemicolon()&&e.end-e.start===5&&this.offsetToSourcePos(e.start)===this.state.potentialArrowAt}finishCallExpression(e,t){if(e.callee.type===`Import`)if(e.arguments.length===0||e.arguments.length>2)this.raise(G.ImportCallArity,e);else for(let t of e.arguments)t.type===`SpreadElement`&&this.raise(G.ImportCallSpreadArgument,t);return this.finishNode(e,t?`OptionalCallExpression`:`CallExpression`)}parseCallExpressionArguments(e,t,n){let r=[],i=!0,a=this.state.inFSharpPipelineDirectBody;for(this.state.inFSharpPipelineDirectBody=!1;!this.eat(7);){if(i)i=!1;else if(this.expect(8),this.match(7)){t&&this.addTrailingCommaExtraToNode(t),this.next();break}r.push(this.parseExprListItem(7,!1,n,e))}return this.state.inFSharpPipelineDirectBody=a,r}shouldParseAsyncArrow(){return this.match(15)&&!this.canInsertSemicolon()}parseAsyncArrowFromCallExpression(e,t){return this.resetPreviousNodeTrailingComments(t),this.expect(15),this.parseArrowExpression(e,t.arguments,!0,t.extra?.trailingCommaLoc),t.innerComments&&aF(e,t.innerComments),t.callee.trailingComments&&aF(e,t.callee.trailingComments),e}parseNoCallExpr(){let e=this.state.startLoc;return this.parseSubscripts(this.parseExprAtom(),e,!0)}parseExprAtom(e){let t,n=null,{type:r}=this.state;switch(r){case 75:return this.parseSuper();case 79:return t=this.startNode(),this.next(),this.match(12)?this.parseImportMetaPropertyOrPhaseCall(t):this.match(6)?this.optionFlags&512?this.parseImportCall(t):this.finishNode(t,`Import`):(this.raise(G.UnsupportedImport,this.state.lastTokStartLoc),this.finishNode(t,`Import`));case 74:return t=this.startNode(),this.next(),this.finishNode(t,`ThisExpression`);case 86:return this.parseDo(this.startNode(),!1);case 52:case 27:return this.readRegexp(),this.parseRegExpLiteral(this.state.value);case 131:return this.parseNumericLiteral(this.state.value);case 132:return this.parseBigIntLiteral(this.state.value);case 130:return this.parseStringLiteral(this.state.value);case 80:return this.parseNullLiteral();case 81:return this.parseBooleanLiteral(!0);case 82:return this.parseBooleanLiteral(!1);case 6:{let e=this.state.potentialArrowAt===this.state.start;return this.parseParenAndDistinguishExpression(e)}case 0:return this.parseArrayLike(1,e);case 2:return this.parseObjectLike(4,!1,e);case 64:return this.parseFunctionOrFunctionSent();case 22:n=this.parseDecorators();case 76:return this.parseClass(this.maybeTakeDecorators(n,this.startNode()),!1);case 73:return this.parseNewOrNewTarget();case 21:case 20:return this.parseTemplate(!1);case 11:{t=this.startNode(),this.next(),t.object=null;let e=t.callee=this.parseNoCallExpr();if(e.type===`MemberExpression`)return this.finishNode(t,`BindExpression`);throw this.raise(G.UnsupportedBind,e)}case 134:return this.raise(G.PrivateInExpectedIn,this.state.startLoc,{identifierName:this.state.value}),this.parsePrivateName();case 29:return this.parseTopicReferenceThenEqualsSign(50,`%`);case 28:return this.parseTopicReferenceThenEqualsSign(40,`^`);case 33:case 34:return this.parseTopicReference(`hack`);case 40:case 50:case 23:{let e=this.getPluginOption(`pipelineOperator`,`proposal`);if(e)return this.parseTopicReference(e);throw this.unexpected()}case 43:{let e=this.input.codePointAt(this.nextTokenStart());throw gP(e)||e===62?this.expectOnePlugin([`jsx`,`flow`,`typescript`]):this.unexpected()}default:if(Y(r)){if(this.isContextual(123)&&this.lookaheadInLineCharCode()===123)return this.parseModuleExpression();let e=this.state.potentialArrowAt===this.state.start,t=this.state.containsEsc,n=this.parseIdentifier();if(!t&&n.name===`async`&&!this.canInsertSemicolon()){let{type:e}=this.state;if(e===64)return this.resetPreviousNodeTrailingComments(n),this.next(),this.parseAsyncFunctionExpression(this.startNodeAtNode(n));if(Y(e))return this.lookaheadCharCode()===61?this.parseAsyncArrowUnaryFunction(this.startNodeAtNode(n)):n;if(e===86)return this.resetPreviousNodeTrailingComments(n),this.parseDo(this.startNodeAtNode(n),!0)}return e&&this.match(15)&&!this.canInsertSemicolon()?(this.next(),this.parseArrowExpression(this.startNodeAtNode(n),[n],!1)):n}else throw this.unexpected()}}parseTopicReferenceThenEqualsSign(e,t){let n=this.getPluginOption(`pipelineOperator`,`proposal`);if(n)return this.state.type=e,this.state.value=t,this.state.pos--,this.state.end--,this.state.endLoc=pN(this.state.endLoc,-1),this.parseTopicReference(n);throw this.unexpected()}parseTopicReference(e){let t=this.startNode(),n=this.state.startLoc,r=this.state.type;return this.next(),this.finishTopicReference(t,n,e,r)}finishTopicReference(e,t,n,r){if(this.testTopicReferenceConfiguration(n,t,r))return this.topicReferenceIsAllowedInCurrentContext()||this.raise(G.PipeTopicUnbound,t),this.registerTopicReference(),this.finishNode(e,`TopicReference`);throw this.raise(G.PipeTopicUnconfiguredToken,t,{token:rP(r)})}testTopicReferenceConfiguration(e,t,n){switch(e){case`hack`:return this.hasPlugin([`pipelineOperator`,{topicToken:rP(n)}]);default:throw this.raise(G.PipeTopicRequiresHackPipes,t)}}parseAsyncArrowUnaryFunction(e){this.prodParam.enter(tF(!0,this.prodParam.hasYield));let t=[this.parseIdentifier()];return this.prodParam.exit(),this.hasPrecedingLineBreak()&&this.raise(G.LineTerminatorBeforeArrow,this.state.curPosition()),this.expect(15),this.parseArrowExpression(e,t,!0)}parseDo(e,t){this.expectPlugin(`doExpressions`),t&&this.expectPlugin(`asyncDoExpressions`),e.async=t,this.next();let n=this.state.labels;return this.state.labels=[],t?(this.prodParam.enter(2),e.body=this.parseBlock(),this.prodParam.exit()):e.body=this.parseBlock(),this.state.labels=n,this.finishNode(e,`DoExpression`)}parseSuper(){let e=this.startNode();return this.next(),this.match(6)&&!this.scope.allowDirectSuper?this.raise(G.SuperNotAllowed,e):this.scope.allowSuper||this.raise(G.UnexpectedSuper,e),!this.match(6)&&!this.match(0)&&!this.match(12)&&this.raise(G.UnsupportedSuper,e),this.finishNode(e,`Super`)}parsePrivateName(){let e=this.startNode(),t=this.startNodeAt(pN(this.state.startLoc,1)),n=this.state.value;return this.next(),e.id=this.createIdentifier(t,n),this.finishNode(e,`PrivateName`)}parseFunctionOrFunctionSent(){let e=this.startNode();if(this.next(),this.prodParam.hasYield&&this.match(12)){let t=this.createIdentifier(this.startNodeAtNode(e),`function`);return this.next(),this.match(99)?this.expectPlugin(`functionSent`):this.hasPlugin(`functionSent`)||this.unexpected(),this.parseMetaProperty(e,t,`sent`)}return this.parseFunction(e)}parseMetaProperty(e,t,n){e.meta=t;let r=this.state.containsEsc;return e.property=this.parseIdentifier(!0),(e.property.name!==n||r)&&this.raise(G.UnsupportedMetaProperty,e.property,{target:t.name,onlyValidPropertyName:n}),this.finishNode(e,`MetaProperty`)}parseImportMetaPropertyOrPhaseCall(e){if(this.next(),this.isContextual(101)||this.isContextual(93)){let t=this.isContextual(101);return this.expectPlugin(t?`sourcePhaseImports`:`deferredImportEvaluation`),this.next(),e.phase=t?`source`:`defer`,this.parseImportCall(e)}else{let t=this.createIdentifierAt(this.startNodeAtNode(e),`import`,this.state.lastTokStartLoc);return this.isContextual(97)&&(this.inModule||this.raise(G.ImportMetaOutsideModule,t),this.sawUnambiguousESM=!0),this.parseMetaProperty(e,t,`meta`)}}parseLiteralAtNode(e,t,n){return this.addExtra(n,`rawValue`,e),this.addExtra(n,`raw`,this.input.slice(this.offsetToSourcePos(n.start),this.state.end)),n.value=e,this.next(),this.finishNode(n,t)}parseLiteral(e,t){let n=this.startNode();return this.parseLiteralAtNode(e,t,n)}parseStringLiteral(e){return this.parseLiteral(e,`StringLiteral`)}parseNumericLiteral(e){return this.parseLiteral(e,`NumericLiteral`)}parseBigIntLiteral(e){let t;try{t=BigInt(e)}catch{t=null}return this.parseLiteral(t,`BigIntLiteral`)}parseRegExpLiteral(e){let t=this.startNode();return this.addExtra(t,`raw`,this.input.slice(this.offsetToSourcePos(t.start),this.state.end)),t.pattern=e.pattern,t.flags=e.flags,this.next(),this.finishNode(t,`RegExpLiteral`)}parseBooleanLiteral(e){let t=this.startNode();return t.value=e,this.next(),this.finishNode(t,`BooleanLiteral`)}parseNullLiteral(){let e=this.startNode();return this.next(),this.finishNode(e,`NullLiteral`)}parseParenAndDistinguishExpression(e){let t=this.state.startLoc,n;this.next(),this.expressionScope.enter(OF());let r=this.state.maybeInArrowParameters,i=this.state.inFSharpPipelineDirectBody;this.state.maybeInArrowParameters=!0,this.state.inFSharpPipelineDirectBody=!1;let a=this.state.startLoc,o=[],s=new MF,c=!0,l,u;for(;!this.match(7);){if(c)c=!1;else if(this.expect(8,s.optionalParametersLoc===null?null:s.optionalParametersLoc),this.match(7)){u=this.state.startLoc;break}if(this.match(17)){let e=this.state.startLoc;if(l=this.state.startLoc,o.push(this.parseParenItem(this.parseRestBinding(),e)),!this.checkCommaAfterRest(41))break}else o.push(this.parseMaybeAssignAllowInOrVoidPattern(7,s,this.parseParenItem))}let d=this.state.lastTokEndLoc;this.expect(7),this.state.maybeInArrowParameters=r,this.state.inFSharpPipelineDirectBody=i;let f=this.startNodeAt(t);return e&&this.shouldParseArrow(o)&&(f=this.parseArrow(f))?(this.checkDestructuringPrivate(s),this.expressionScope.validateAsPattern(),this.expressionScope.exit(),this.parseArrowExpression(f,o,!1),f):(this.expressionScope.exit(),o.length||this.unexpected(this.state.lastTokStartLoc),u&&this.unexpected(u),l&&this.unexpected(l),this.checkExpressionErrors(s,!0),this.toReferencedListDeep(o,!0),o.length>1?(n=this.startNodeAt(a),n.expressions=o,this.finishNode(n,`SequenceExpression`),this.resetEndLocation(n,d)):n=o[0],this.wrapParenthesis(t,n))}wrapParenthesis(e,t){if(!(this.optionFlags&1024))return this.addExtra(t,`parenthesized`,!0),this.addExtra(t,`parenStart`,e.index),this.takeSurroundingComments(t,e.index,this.state.lastTokEndLoc.index),t;let n=this.startNodeAt(e);return n.expression=t,this.finishNode(n,`ParenthesizedExpression`)}shouldParseArrow(e){return!this.canInsertSemicolon()}parseArrow(e){if(this.eat(15))return e}parseParenItem(e,t){return e}parseNewOrNewTarget(){let e=this.startNode();if(this.next(),this.match(12)){let t=this.createIdentifier(this.startNodeAtNode(e),`new`);this.next();let n=this.parseMetaProperty(e,t,`target`);return this.scope.allowNewTarget||this.raise(G.UnexpectedNewTarget,n),n}return this.parseNew(e)}parseNew(e){if(this.parseNewCallee(e),this.eat(6)){let t=this.parseExprList(7);this.toReferencedList(t),e.arguments=t}else e.arguments=[];return this.finishNode(e,`NewExpression`)}parseNewCallee(e){let t=this.match(79),n=this.parseNoCallExpr();e.callee=n,t&&(n.type===`Import`||n.type===`ImportExpression`)&&this.raise(G.ImportCallNotNewExpression,n)}parseTemplateElement(e){let{start:t,startLoc:n,end:r,value:i}=this.state,a=t+1,o=this.startNodeAt(pN(n,1));i===null&&(e||this.raise(G.InvalidEscapeSequenceTemplate,pN(this.state.firstInvalidTemplateEscapePos,1)));let s=this.match(20),c=s?-1:-2,l=r+c;o.value={raw:this.input.slice(a,l).replace(/\r\n?/g,`
|
|
15
|
+
`),cooked:i===null?null:i.slice(1,c)},o.tail=s,this.next();let u=this.finishNode(o,`TemplateElement`);return this.resetEndLocation(u,pN(this.state.lastTokEndLoc,c)),u}parseTemplate(e){let t=this.startNode(),n=this.parseTemplateElement(e),r=[n],i=[];for(;!n.tail;)i.push(this.parseTemplateSubstitution()),this.readTemplateContinuation(),r.push(n=this.parseTemplateElement(e));return t.expressions=i,t.quasis=r,this.finishNode(t,`TemplateLiteral`)}parseTemplateSubstitution(){return this.parseExpression()}parseObjectLike(e,t,n){let r=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!1;let i=!1,a=!0,o=this.startNode();for(o.properties=[],this.next();!this.match(e);){if(a)a=!1;else if(this.expect(8),this.match(e)){this.addTrailingCommaExtraToNode(o);break}let r;t?r=this.parseBindingProperty():(r=this.parsePropertyDefinition(n),i=this.checkProto(r,i,n)),o.properties.push(r)}this.next(),this.state.inFSharpPipelineDirectBody=r;let s=t?`ObjectPattern`:`ObjectExpression`;return this.finishNode(o,s)}addTrailingCommaExtraToNode(e){this.addExtra(e,`trailingComma`,this.state.lastTokStartLoc.index),this.addExtra(e,`trailingCommaLoc`,this.state.lastTokStartLoc,!1)}maybeAsyncOrAccessorProp(e){return!e.computed&&e.key.type===`Identifier`&&(this.isLiteralPropertyName()||this.match(0)||this.match(51))}parsePropertyDefinition(e){let t=[];if(this.match(22))for(this.hasPlugin(`decorators`)&&this.raise(G.UnsupportedPropertyDecorator,this.state.startLoc);this.match(22);)t.push(this.parseDecorator());let n=this.startNode(),r=!1,i=!1,a;if(this.match(17))return t.length&&this.unexpected(),this.parseSpread();t.length&&(n.decorators=t,t=[]),n.method=!1,e&&(a=this.state.startLoc);let o=this.eat(51);this.parsePropertyNamePrefixOperator(n);let s=this.state.containsEsc;if(this.parsePropertyName(n,e),!o&&!s&&this.maybeAsyncOrAccessorProp(n)){let{key:e}=n,t=e.name;t===`async`&&!this.hasPrecedingLineBreak()&&(r=!0,this.resetPreviousNodeTrailingComments(e),o=this.eat(51),this.parsePropertyName(n)),(t===`get`||t===`set`)&&(i=!0,this.resetPreviousNodeTrailingComments(e),n.kind=t,this.match(51)&&(o=!0,this.raise(G.AccessorIsGenerator,this.state.curPosition(),{kind:t}),this.next()),this.parsePropertyName(n))}return this.parseObjPropValue(n,a,o,r,!1,i,e)}getGetterSetterExpectedParamCount(e){return e.kind===`get`?0:1}getObjectOrClassMethodParams(e){return e.params}checkGetterSetterParams(e){let t=this.getGetterSetterExpectedParamCount(e),n=this.getObjectOrClassMethodParams(e);n.length!==t&&this.raise(e.kind===`get`?G.BadGetterArity:G.BadSetterArity,e),e.kind===`set`&&n[n.length-1]?.type===`RestElement`&&this.raise(G.BadSetterRestParameter,e)}parseObjectMethod(e,t,n,r,i){if(i){let n=this.parseMethod(e,t,!1,!1,!1,`ObjectMethod`);return this.checkGetterSetterParams(n),n}if(n||t||this.match(6))return r&&this.unexpected(),e.kind=`method`,e.method=!0,this.parseMethod(e,t,n,!1,!1,`ObjectMethod`)}parseObjectProperty(e,t,n,r){if(e.shorthand=!1,this.eat(10))return e.value=n?this.parseMaybeDefault(this.state.startLoc):this.parseMaybeAssignAllowInOrVoidPattern(4,r),this.finishObjectProperty(e);if(!e.computed&&e.key.type===`Identifier`){if(this.checkReservedWord(e.key.name,e.key.loc.start,!0,!1),n)e.value=this.parseMaybeDefault(t,this.cloneIdentifier(e.key));else if(this.match(25)){let n=this.state.startLoc;r==null?this.raise(G.InvalidCoverInitializedName,n):r.shorthandAssignLoc===null&&(r.shorthandAssignLoc=n),e.value=this.parseMaybeDefault(t,this.cloneIdentifier(e.key))}else e.value=this.cloneIdentifier(e.key);return e.shorthand=!0,this.finishObjectProperty(e)}}finishObjectProperty(e){return this.finishNode(e,`ObjectProperty`)}parseObjPropValue(e,t,n,r,i,a,o){let s=this.parseObjectMethod(e,n,r,i,a)||this.parseObjectProperty(e,t,i,o);return s||this.unexpected(),s}parsePropertyName(e,t){if(this.eat(0))e.computed=!0,e.key=this.parseMaybeAssignAllowIn(),this.expect(1);else{let{type:n,value:r}=this.state,i;if(WN(n))i=this.parseIdentifier(!0);else switch(n){case 131:i=this.parseNumericLiteral(r);break;case 130:i=this.parseStringLiteral(r);break;case 132:i=this.parseBigIntLiteral(r);break;case 134:{let e=this.state.startLoc;t==null?this.raise(G.UnexpectedPrivateField,e):t.privateKeyLoc===null&&(t.privateKeyLoc=e),i=this.parsePrivateName();break}default:this.unexpected()}e.key=i,n!==134&&(e.computed=!1)}}initFunction(e,t){e.id=null,e.generator=!1,e.async=t}parseMethod(e,t,n,r,i,a,o=!1){this.initFunction(e,n),e.generator=t,this.scope.enter(530|(o?576:0)|(i?32:0)),this.prodParam.enter(tF(n,e.generator)),this.parseFunctionParams(e,r);let s=this.parseFunctionBodyAndFinish(e,a,!0);return this.prodParam.exit(),this.scope.exit(),s}parseArrayLike(e,t){let n=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!1;let r=this.startNode();return this.next(),r.elements=this.parseExprList(e,!0,t,r),this.state.inFSharpPipelineDirectBody=n,this.finishNode(r,`ArrayExpression`)}parseArrowExpression(e,t,n,r){this.scope.enter(518);let i=tF(n,!1);!this.match(2)&&this.prodParam.hasIn&&(i|=8),this.prodParam.enter(i),this.initFunction(e,n);let a=this.state.maybeInArrowParameters;return t&&(this.state.maybeInArrowParameters=!0,this.setArrowFunctionParameters(e,t,r)),this.state.maybeInArrowParameters=!1,this.parseFunctionBody(e,!0),this.prodParam.exit(),this.scope.exit(),this.state.maybeInArrowParameters=a,this.finishNode(e,`ArrowFunctionExpression`)}setArrowFunctionParameters(e,t,n){this.toAssignableList(t,n,!1),e.params=t}parseFunctionBodyAndFinish(e,t,n=!1){return this.parseFunctionBody(e,!1,n),this.finishNode(e,t)}parseFunctionBody(e,t,n=!1){let r=t&&!this.match(2);if(this.expressionScope.enter(AF()),r)e.body=this.parseMaybeAssign(),this.checkParams(e,!1,t,!1);else{let r=this.state.strict,i=this.state.labels;this.state.labels=[],this.prodParam.enter(this.prodParam.currentFlags()|4),e.body=this.parseBlock(!0,!1,i=>{let a=!this.isSimpleParamList(e.params);i&&a&&this.raise(G.IllegalLanguageModeDirective,(e.kind===`method`||e.kind===`constructor`)&&e.key?e.key.loc.end:e);let o=!r&&this.state.strict;this.checkParams(e,!this.state.strict&&!t&&!n&&!a,t,o),this.state.strict&&e.id&&this.checkIdentifier(e.id,65,o)}),this.prodParam.exit(),this.state.labels=i}this.expressionScope.exit()}isSimpleParameter(e){return e.type===`Identifier`}isSimpleParamList(e){for(let t=0,n=e.length;t<n;t++)if(!this.isSimpleParameter(e[t]))return!1;return!0}checkParams(e,t,n,r=!0){let i=!t&&new Set,a={type:`FormalParameters`};for(let t of e.params)this.checkLVal(t,a,5,i,r)}parseExprList(e,t,n,r){let i=[],a=!0;for(;!this.eat(e);){if(a)a=!1;else if(this.expect(8),this.match(e)){r&&this.addTrailingCommaExtraToNode(r),this.next();break}i.push(this.parseExprListItem(e,t,n))}return i}parseExprListItem(e,t,n,r){let i;if(this.match(8))t||this.raise(G.UnexpectedToken,this.state.curPosition(),{unexpected:`,`}),i=null;else if(this.match(17)){let e=this.state.startLoc;i=this.parseParenItem(this.parseSpread(n),e)}else if(this.match(13)){this.expectPlugin(`partialApplication`),r||this.raise(G.UnexpectedArgumentPlaceholder,this.state.startLoc);let e=this.startNode();this.next(),i=this.finishNode(e,`ArgumentPlaceholder`)}else i=this.parseMaybeAssignAllowInOrVoidPattern(e,n,this.parseParenItem);return i}parseIdentifier(e){let t=this.startNode(),n=this.parseIdentifierName(e);return this.createIdentifier(t,n)}createIdentifier(e,t){return e.name=t,e.loc.identifierName=t,this.finishNode(e,`Identifier`)}createIdentifierAt(e,t,n){return e.name=t,e.loc.identifierName=t,this.finishNodeAt(e,`Identifier`,n)}parseIdentifierName(e){let t,{startLoc:n,type:r}=this.state;WN(r)?t=this.state.value:this.unexpected();let i=UN(r);return e?i&&this.replaceToken(128):this.checkReservedWord(t,n,i,!1),this.next(),t}checkReservedWord(e,t,n,r){if(!(e.length>10)&&kP(e)){if(n&&EP(e)){this.raise(G.UnexpectedKeyword,t,{keyword:e});return}if((this.state.strict?r?TP:CP:SP)(e,this.inModule)){this.raise(G.UnexpectedReservedWord,t,{reservedWord:e});return}else if(e===`yield`){if(this.prodParam.hasYield){this.raise(G.YieldBindingIdentifier,t);return}}else if(e===`await`){if(this.prodParam.hasAwait){this.raise(G.AwaitBindingIdentifier,t);return}if(this.scope.inStaticBlock){this.raise(G.AwaitBindingIdentifierInStaticBlock,t);return}this.expressionScope.recordAsyncArrowParametersError(t)}else if(e===`arguments`&&this.scope.inClassAndNotInNonArrowFunction){this.raise(G.ArgumentsInClass,t);return}}}recordAwaitIfAllowed(){let e=this.prodParam.hasAwait;return e&&!this.scope.inFunction&&(this.state.hasTopLevelAwait=!0),e}parseAwait(e){let t=this.startNodeAt(e);return this.expressionScope.recordParameterInitializerError(G.AwaitExpressionFormalParameter,t),this.eat(51)&&this.raise(G.ObsoleteAwaitStar,t),!this.scope.inFunction&&!(this.optionFlags&1)&&(this.isAmbiguousPrefixOrIdentifier()?this.ambiguousScriptDifferentAst=!0:this.sawUnambiguousESM=!0),this.state.soloAwait||(t.argument=this.parseMaybeUnary(null,!0)),this.finishNode(t,`AwaitExpression`)}isAmbiguousPrefixOrIdentifier(){if(this.hasPrecedingLineBreak())return!0;let{type:e}=this.state;return e===49||e===6||e===0||oP(e)||e===98&&!this.state.containsEsc||e===133||e===52||this.hasPlugin(`v8intrinsic`)&&e===50}parseYield(e){let t=this.startNodeAt(e);this.expressionScope.recordParameterInitializerError(G.YieldInParameter,t);let n=!1,r=null;if(!this.hasPrecedingLineBreak())switch(n=this.eat(51),this.state.type){case 9:case 135:case 4:case 7:case 1:case 5:case 10:case 8:if(!n)break;default:r=this.parseMaybeAssign()}return t.delegate=n,t.argument=r,this.finishNode(t,`YieldExpression`)}parseImportCall(e){if(this.next(),e.source=this.parseMaybeAssignAllowIn(),e.options=null,this.eat(8)){if(this.match(7))this.addTrailingCommaExtraToNode(e.source);else if(e.options=this.parseMaybeAssignAllowIn(),this.eat(8)&&(this.addTrailingCommaExtraToNode(e.options),!this.match(7))){do this.parseMaybeAssignAllowIn();while(this.eat(8)&&!this.match(7));this.raise(G.ImportCallArity,e)}}return this.expect(7),this.finishNode(e,`ImportExpression`)}withTopicBindingContext(e){let t=this.state.topicContext;this.state.topicContext={maxNumOfResolvableTopics:1,maxTopicIndex:null};try{return e()}finally{this.state.topicContext=t}}withSoloAwaitPermittingContext(e){let t=this.state.soloAwait;this.state.soloAwait=!0;try{return e()}finally{this.state.soloAwait=t}}allowInAnd(e){let t=this.prodParam.currentFlags();if(8&~t){this.prodParam.enter(t|8);try{return e()}finally{this.prodParam.exit()}}return e()}disallowInAnd(e){let t=this.prodParam.currentFlags();if(8&t){this.prodParam.enter(t&-9);try{return e()}finally{this.prodParam.exit()}}return e()}registerTopicReference(){this.state.topicContext.maxTopicIndex=0}topicReferenceIsAllowedInCurrentContext(){return this.state.topicContext.maxNumOfResolvableTopics>=1}topicReferenceWasUsedInCurrentContext(){return this.state.topicContext.maxTopicIndex!=null&&this.state.topicContext.maxTopicIndex>=0}parseFSharpPipelineBody(e){let t=this.state.startLoc;this.state.potentialArrowAt=this.state.start;let n=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!0;let r=this.parseExprOp(this.parseMaybeUnaryOrPrivate(),t,e);return this.state.inFSharpPipelineDirectBody=n,r}parseModuleExpression(){this.expectPlugin(`moduleBlocks`);let e=this.startNode();this.next(),this.match(2)||this.unexpected(null,2);let t=this.startNodeAt(this.state.endLoc);this.next();let n=this.initializeScopes(!0);this.enterInitialScopes();try{e.body=this.parseProgram(t,4,`module`)}finally{n()}return this.finishNode(e,`ModuleExpression`)}parseVoidPattern(e){this.expectPlugin(`discardBinding`);let t=this.startNode();return e!=null&&(e.voidPatternLoc=this.state.startLoc),this.next(),this.finishNode(t,`VoidPattern`)}parseMaybeAssignAllowInOrVoidPattern(e,t,n){if(t!=null&&this.match(84)){let n=this.lookaheadCharCode();if(n===44||n===(e===1?93:e===4?125:41)||n===61)return this.parseMaybeDefault(this.state.startLoc,this.parseVoidPattern(t))}return this.parseMaybeAssignAllowIn(t,n)}parsePropertyNamePrefixOperator(e){}};const oI={kind:1},sI={kind:2},cI=/[\uD800-\uDFFF]/u,lI=/in(?:stanceof)?/y;function uI(e){for(let t=0;t<e.length;t++){let n=e[t],{type:r}=n;typeof r==`number`&&(n.type=sP(r))}return e}var dI=class extends aI{parseTopLevel(e,t){return e.program=this.parseProgram(t,135,this.options.sourceType===`module`?`module`:`script`),e.comments=this.comments,this.optionFlags&256&&(e.tokens=uI(this.tokens)),this.finishNode(e,`File`)}parseProgram(e,t,n){if(e.sourceType=n,e.interpreter=this.parseInterpreterDirective(),this.parseBlockBody(e,!0,!0,t),this.inModule){if(!(this.optionFlags&64)&&this.scope.undefinedExports.size>0)for(let[e,t]of Array.from(this.scope.undefinedExports))this.raise(G.ModuleExportUndefined,t,{localName:e});this.addExtra(e,`topLevelAwait`,this.state.hasTopLevelAwait)}let r;return r=t===135?this.finishNode(e,`Program`):this.finishNodeAt(e,`Program`,pN(this.state.startLoc,-1)),r}stmtToDirective(e){let t=this.castNodeTo(e,`Directive`),n=this.castNodeTo(e.expression,`DirectiveLiteral`),r=n.value,i=this.input.slice(this.offsetToSourcePos(n.start),this.offsetToSourcePos(n.end)),a=n.value=i.slice(1,-1);return this.addExtra(n,`raw`,i),this.addExtra(n,`rawValue`,a),this.addExtra(n,`expressionValue`,r),t.value=n,delete e.expression,t}parseInterpreterDirective(){if(!this.match(24))return null;let e=this.startNode();return e.value=this.state.value,this.next(),this.finishNode(e,`InterpreterDirective`)}isLet(){return this.isContextual(96)?this.hasFollowingBindingAtom():!1}isUsing(){return this.isContextual(103)?this.nextTokenIsIdentifierOnSameLine():!1}isForUsing(){if(!this.isContextual(103))return!1;let e=this.nextTokenInLineStart(),t=this.codePointAtPos(e);if(this.isUnparsedContextual(e,`of`)){let t=this.lookaheadCharCodeSince(e+2);if(t!==61&&t!==58&&t!==59)return!1}return!!(this.chStartsBindingIdentifier(t,e)||this.isUnparsedContextual(e,`void`))}nextTokenIsIdentifierOnSameLine(){let e=this.nextTokenInLineStart(),t=this.codePointAtPos(e);return this.chStartsBindingIdentifier(t,e)}isAwaitUsing(){if(!this.isContextual(92))return!1;let e=this.nextTokenInLineStart();if(this.isUnparsedContextual(e,`using`)){e=this.nextTokenInLineStartSince(e+5);let t=this.codePointAtPos(e);if(this.chStartsBindingIdentifier(t,e))return!0}return!1}chStartsBindingIdentifier(e,t){if(gP(e)){if(lI.lastIndex=t,lI.test(this.input)){let e=this.codePointAtPos(lI.lastIndex);if(!_P(e)&&e!==92)return!1}return!0}else if(e===92)return!0;else return!1}chStartsBindingPattern(e){return e===91||e===123}hasFollowingBindingAtom(){let e=this.nextTokenStart(),t=this.codePointAtPos(e);return this.chStartsBindingPattern(t)||this.chStartsBindingIdentifier(t,e)}hasInLineFollowingBindingIdentifierOrBrace(){let e=this.nextTokenInLineStart(),t=this.codePointAtPos(e);return t===123||this.chStartsBindingIdentifier(t,e)}allowsUsing(){return(this.scope.inModule||!this.scope.inTopLevel)&&!this.scope.inBareCaseStatement}parseModuleItem(){return this.parseStatementLike(15)}parseStatementListItem(){return this.parseStatementLike(6|(!this.options.annexB||this.state.strict?0:8))}parseStatementOrSloppyAnnexBFunctionDeclaration(e=!1){let t=0;return this.options.annexB&&!this.state.strict&&(t|=4,e&&(t|=8)),this.parseStatementLike(t)}parseStatement(){return this.parseStatementLike(0)}parseStatementLike(e){let t=null;return this.match(22)&&(t=this.parseDecorators(!0)),this.parseStatementContent(e,t)}parseStatementContent(e,t){let n=this.state.type,r=this.startNode(),i=!!(e&2),a=!!(e&4),o=e&1;switch(n){case 56:return this.parseBreakContinueStatement(r,!0);case 59:return this.parseBreakContinueStatement(r,!1);case 60:return this.parseDebuggerStatement(r);case 86:return this.parseDoWhileStatement(r);case 87:return this.parseForStatement(r);case 64:if(this.lookaheadCharCode()===46)break;return a||this.raise(this.state.strict?G.StrictFunction:this.options.annexB?G.SloppyFunctionAnnexB:G.SloppyFunction,this.state.startLoc),this.parseFunctionStatement(r,!1,!i&&a);case 76:return i||this.unexpected(),this.parseClass(this.maybeTakeDecorators(t,r),!0);case 65:return this.parseIfStatement(r);case 66:return this.parseReturnStatement(r);case 67:return this.parseSwitchStatement(r);case 68:return this.parseThrowStatement(r);case 69:return this.parseTryStatement(r);case 92:if(this.isAwaitUsing())return this.allowsUsing()?i?this.recordAwaitIfAllowed()||this.raise(G.AwaitUsingNotInAsyncContext,r):this.raise(G.UnexpectedLexicalDeclaration,r):this.raise(G.UnexpectedUsingDeclaration,r),this.next(),this.parseVarStatement(r,`await using`);break;case 103:if(this.state.containsEsc||!this.hasInLineFollowingBindingIdentifierOrBrace())break;return this.allowsUsing()?i||this.raise(G.UnexpectedLexicalDeclaration,this.state.startLoc):this.raise(G.UnexpectedUsingDeclaration,this.state.startLoc),this.parseVarStatement(r,`using`);case 96:{if(this.state.containsEsc)break;let e=this.nextTokenStart(),t=this.codePointAtPos(e);if(t!==91&&(!i&&this.hasFollowingLineBreak()||!this.chStartsBindingIdentifier(t,e)&&t!==123))break}case 71:i||this.raise(G.UnexpectedLexicalDeclaration,this.state.startLoc);case 70:{let e=this.state.value;return this.parseVarStatement(r,e)}case 88:return this.parseWhileStatement(r);case 72:return this.parseWithStatement(r);case 2:return this.parseBlock();case 9:return this.parseEmptyStatement(r);case 79:{let e=this.lookaheadCharCode();if(e===40||e===46)break}case 78:{!(this.optionFlags&8)&&!o&&this.raise(G.UnexpectedImportExport,this.state.startLoc),this.next();let e;return e=n===79?this.parseImport(r):this.parseExport(r,t),this.assertModuleNodeAllowed(e),e}default:if(this.isAsyncFunction())return i||this.raise(G.AsyncFunctionInSingleStatementContext,this.state.startLoc),this.next(),this.parseFunctionStatement(r,!0,!i&&a)}let s=this.state.value,c=this.parseExpression();return Y(n)&&c.type===`Identifier`&&this.eat(10)?this.parseLabeledStatement(r,s,c,e):this.parseExpressionStatement(r,c,t)}assertModuleNodeAllowed(e){!(this.optionFlags&8)&&!this.inModule&&this.raise(G.ImportOutsideModule,e)}maybeTakeDecorators(e,t,n){return e&&(t.decorators?.length?(this.raise(G.DecoratorsBeforeAfterExport,t.decorators[0]),t.decorators.unshift(...e)):t.decorators=e,this.resetStartLocationFromNode(t,e[0]),n&&this.resetStartLocationFromNode(n,t)),t}canHaveLeadingDecorator(){return this.match(76)}parseDecorators(e){let t=[];do t.push(this.parseDecorator());while(this.match(22));if(this.match(78))e||this.unexpected();else if(!this.canHaveLeadingDecorator())throw this.raise(G.UnexpectedLeadingDecorator,this.state.startLoc);return t}parseDecorator(){this.expectOnePlugin([`decorators`,`decorators-legacy`]);let e=this.startNode();if(this.next(),this.hasPlugin(`decorators`)){let t=this.state.startLoc,n;if(this.match(6)){let t=this.state.startLoc;this.next(),n=this.parseExpression(),this.expect(7),n=this.wrapParenthesis(t,n);let r=this.state.startLoc;e.expression=this.parseMaybeDecoratorArguments(n,t),e.expression!==n&&this.raise(G.DecoratorArgumentsOutsideParentheses,r)}else{for(n=this.parseIdentifier(!1);this.eat(12);){let e=this.startNodeAt(t);e.object=n,this.match(134)?(this.classScope.usePrivateName(this.state.value,this.state.startLoc),e.property=this.parsePrivateName()):e.property=this.parseIdentifier(!0),e.computed=!1,n=this.finishNode(e,`MemberExpression`)}e.expression=this.parseMaybeDecoratorArguments(n,t)}}else e.expression=this.parseExprSubscripts();return this.finishNode(e,`Decorator`)}parseMaybeDecoratorArguments(e,t){if(this.eat(6)){let n=this.startNodeAt(t);return n.callee=e,n.arguments=this.parseCallExpressionArguments(),this.toReferencedList(n.arguments),this.finishNode(n,`CallExpression`)}return e}parseBreakContinueStatement(e,t){return this.next(),this.isLineTerminator()?e.label=null:(e.label=this.parseIdentifier(),this.semicolon()),this.verifyBreakContinue(e,t),this.finishNode(e,t?`BreakStatement`:`ContinueStatement`)}verifyBreakContinue(e,t){let n;for(n=0;n<this.state.labels.length;++n){let r=this.state.labels[n];if((e.label==null||r.name===e.label.name)&&(r.kind!=null&&(t||r.kind===1)||e.label&&t))break}if(n===this.state.labels.length){let n=t?`BreakStatement`:`ContinueStatement`;this.raise(G.IllegalBreakContinue,e,{type:n})}}parseDebuggerStatement(e){return this.next(),this.semicolon(),this.finishNode(e,`DebuggerStatement`)}parseHeaderExpression(){this.expect(6);let e=this.parseExpression();return this.expect(7),e}parseDoWhileStatement(e){return this.next(),this.state.labels.push(oI),e.body=this.parseStatement(),this.state.labels.pop(),this.expect(88),e.test=this.parseHeaderExpression(),this.eat(9),this.finishNode(e,`DoWhileStatement`)}parseForStatement(e){this.next(),this.state.labels.push(oI);let t=null;if(this.isContextual(92)&&this.recordAwaitIfAllowed()&&(t=this.state.startLoc,this.next()),this.scope.enter(0),this.expect(6),this.match(9))return t!==null&&this.unexpected(t),this.parseFor(e,null);let n=this.isContextual(96);{let r=this.isAwaitUsing(),i=r||this.isForUsing(),a=n&&this.hasFollowingBindingAtom()||i;if(this.match(70)||this.match(71)||a){let n=this.startNode(),a;r?(a=`await using`,this.recordAwaitIfAllowed()||this.raise(G.AwaitUsingNotInAsyncContext,this.state.startLoc),this.next()):a=this.state.value,this.next(),this.parseVar(n,!0,a);let o=this.finishNode(n,`VariableDeclaration`),s=this.match(54);return s&&i&&this.raise(G.ForInUsing,o),(s||this.isContextual(98))&&o.declarations.length===1?this.parseForIn(e,o,t):(t!==null&&this.unexpected(t),this.parseFor(e,o))}}let r=this.isContextual(91),i=new MF,a=this.parseExpression(!0,i),o=this.isContextual(98);if(o&&(n&&this.raise(G.ForOfLet,a),t===null&&r&&a.type===`Identifier`&&this.raise(G.ForOfAsync,a)),o||this.match(54)){this.checkDestructuringPrivate(i),this.toAssignable(a,!0);let n=o?`ForOfStatement`:`ForInStatement`;return this.checkLVal(a,{type:n}),this.parseForIn(e,a,t)}else this.checkExpressionErrors(i,!0);return t!==null&&this.unexpected(t),this.parseFor(e,a)}parseFunctionStatement(e,t,n){return this.next(),this.parseFunction(e,1|(n?2:0)|(t?8:0))}parseIfStatement(e){return this.next(),e.test=this.parseHeaderExpression(),e.consequent=this.parseStatementOrSloppyAnnexBFunctionDeclaration(),e.alternate=this.eat(62)?this.parseStatementOrSloppyAnnexBFunctionDeclaration():null,this.finishNode(e,`IfStatement`)}parseReturnStatement(e){return this.prodParam.hasReturn||this.raise(G.IllegalReturn,this.state.startLoc),this.next(),this.isLineTerminator()?e.argument=null:(e.argument=this.parseExpression(),this.semicolon()),this.finishNode(e,`ReturnStatement`)}parseSwitchStatement(e){this.next(),e.discriminant=this.parseHeaderExpression();let t=e.cases=[];this.expect(2),this.state.labels.push(sI),this.scope.enter(256);let n;for(let e;!this.match(4);)if(this.match(57)||this.match(61)){let r=this.match(57);n&&this.finishNode(n,`SwitchCase`),t.push(n=this.startNode()),n.consequent=[],this.next(),r?n.test=this.parseExpression():(e&&this.raise(G.MultipleDefaultsInSwitch,this.state.lastTokStartLoc),e=!0,n.test=null),this.expect(10)}else n?n.consequent.push(this.parseStatementListItem()):this.unexpected();return this.scope.exit(),n&&this.finishNode(n,`SwitchCase`),this.next(),this.state.labels.pop(),this.finishNode(e,`SwitchStatement`)}parseThrowStatement(e){return this.next(),this.hasPrecedingLineBreak()&&this.raise(G.NewlineAfterThrow,this.state.lastTokEndLoc),e.argument=this.parseExpression(),this.semicolon(),this.finishNode(e,`ThrowStatement`)}parseCatchClauseParam(){let e=this.parseBindingAtom();return this.scope.enter(this.options.annexB&&e.type===`Identifier`?8:0),this.checkLVal(e,{type:`CatchClause`},9),e}parseTryStatement(e){if(this.next(),e.block=this.parseBlock(),e.handler=null,this.match(58)){let t=this.startNode();this.next(),this.match(6)?(this.expect(6),t.param=this.parseCatchClauseParam(),this.expect(7)):(t.param=null,this.scope.enter(0)),t.body=this.parseBlock(!1,!1),this.scope.exit(),e.handler=this.finishNode(t,`CatchClause`)}return e.finalizer=this.eat(63)?this.parseBlock():null,!e.handler&&!e.finalizer&&this.raise(G.NoCatchOrFinally,e),this.finishNode(e,`TryStatement`)}parseVarStatement(e,t,n=!1){return this.next(),this.parseVar(e,!1,t,n),this.semicolon(),this.finishNode(e,`VariableDeclaration`)}parseWhileStatement(e){return this.next(),e.test=this.parseHeaderExpression(),this.state.labels.push(oI),e.body=this.parseStatement(),this.state.labels.pop(),this.finishNode(e,`WhileStatement`)}parseWithStatement(e){return this.state.strict&&this.raise(G.StrictWith,this.state.startLoc),this.next(),e.object=this.parseHeaderExpression(),e.body=this.parseStatement(),this.finishNode(e,`WithStatement`)}parseEmptyStatement(e){return this.next(),this.finishNode(e,`EmptyStatement`)}parseLabeledStatement(e,t,n,r){for(let e of this.state.labels)e.name===t&&this.raise(G.LabelRedeclaration,n,{labelName:t});let i=XN(this.state.type)?1:this.match(67)?2:null;for(let t=this.state.labels.length-1;t>=0;t--){let n=this.state.labels[t];if(n.statementStart===e.start)n.statementStart=this.sourceToOffsetPos(this.state.start),n.kind=i;else break}return this.state.labels.push({name:t,kind:i,statementStart:this.sourceToOffsetPos(this.state.start)}),e.body=r&8?this.parseStatementOrSloppyAnnexBFunctionDeclaration(!0):this.parseStatement(),this.state.labels.pop(),e.label=n,this.finishNode(e,`LabeledStatement`)}parseExpressionStatement(e,t,n){return e.expression=t,this.semicolon(),this.finishNode(e,`ExpressionStatement`)}parseBlock(e=!1,t=!0,n){let r=this.startNode();return e&&this.state.strictErrors.clear(),this.expect(2),t&&this.scope.enter(0),this.parseBlockBody(r,e,!1,4,n),t&&this.scope.exit(),this.finishNode(r,`BlockStatement`)}isValidDirective(e){return e.type===`ExpressionStatement`&&e.expression.type===`StringLiteral`&&!e.expression.extra.parenthesized}parseBlockBody(e,t,n,r,i){let a=e.body=[],o=e.directives=[];this.parseBlockOrModuleBlockBody(a,t?o:void 0,n,r,i)}parseBlockOrModuleBlockBody(e,t,n,r,i){let a=this.state.strict,o=!1,s=!1;for(;!this.match(r);){let r=n?this.parseModuleItem():this.parseStatementListItem();if(t&&!s){if(this.isValidDirective(r)){let e=this.stmtToDirective(r);t.push(e),!o&&e.value.value===`use strict`&&(o=!0,this.setStrict(!0));continue}s=!0,this.state.strictErrors.clear()}e.push(r)}i?.call(this,o),a||this.setStrict(!1),this.next()}parseFor(e,t){return e.init=t,this.semicolon(!1),e.test=this.match(9)?null:this.parseExpression(),this.semicolon(!1),e.update=this.match(7)?null:this.parseExpression(),this.expect(7),e.body=this.parseStatement(),this.scope.exit(),this.state.labels.pop(),this.finishNode(e,`ForStatement`)}parseForIn(e,t,n){let r=this.match(54);return this.next(),r?n!==null&&this.unexpected(n):e.await=n!==null,t.type===`VariableDeclaration`&&t.declarations[0].init!=null&&(!r||!this.options.annexB||this.state.strict||t.kind!==`var`||t.declarations[0].id.type!==`Identifier`)&&this.raise(G.ForInOfLoopInitializer,t,{type:r?`ForInStatement`:`ForOfStatement`}),t.type===`AssignmentPattern`&&this.raise(G.InvalidLhs,t,{ancestor:{type:`ForStatement`}}),e.left=t,e.right=r?this.parseExpression():this.parseMaybeAssignAllowIn(),this.expect(7),e.body=this.parseStatement(),this.scope.exit(),this.state.labels.pop(),this.finishNode(e,r?`ForInStatement`:`ForOfStatement`)}parseVar(e,t,n,r=!1){let i=e.declarations=[];for(e.kind=n;;){let e=this.startNode();if(this.parseVarId(e,n),e.init=this.eat(25)?t?this.parseMaybeAssignDisallowIn():this.parseMaybeAssignAllowIn():null,e.init===null&&!r&&(e.id.type!==`Identifier`&&!(t&&(this.match(54)||this.isContextual(98)))?this.raise(G.DeclarationMissingInitializer,this.state.lastTokEndLoc,{kind:`destructuring`}):(n===`const`||n===`using`||n===`await using`)&&!(this.match(54)||this.isContextual(98))&&this.raise(G.DeclarationMissingInitializer,this.state.lastTokEndLoc,{kind:n})),i.push(this.finishNode(e,`VariableDeclarator`)),!this.eat(8))break}return e}parseVarId(e,t){let n=this.parseBindingAtom();t===`using`||t===`await using`?(n.type===`ArrayPattern`||n.type===`ObjectPattern`)&&this.raise(G.UsingDeclarationHasBindingPattern,n.loc.start):n.type===`VoidPattern`&&this.raise(G.UnexpectedVoidPattern,n.loc.start),this.checkLVal(n,{type:`VariableDeclarator`},t===`var`?5:8201),e.id=n}parseAsyncFunctionExpression(e){return this.parseFunction(e,8)}parseFunction(e,t=0){let n=t&2,r=!!(t&1),i=r&&!(t&4),a=!!(t&8);this.initFunction(e,a),this.match(51)&&(n&&this.raise(G.GeneratorInSingleStatementContext,this.state.startLoc),this.next(),e.generator=!0),r&&(e.id=this.parseFunctionId(i));let o=this.state.maybeInArrowParameters;return this.state.maybeInArrowParameters=!1,this.scope.enter(514),this.prodParam.enter(tF(a,e.generator)),r||(e.id=this.parseFunctionId()),this.parseFunctionParams(e,!1),this.parseFunctionBodyAndFinish(e,r?`FunctionDeclaration`:`FunctionExpression`),this.prodParam.exit(),this.scope.exit(),r&&!n&&this.registerFunctionStatementId(e),this.state.maybeInArrowParameters=o,e}parseFunctionId(e){return e||Y(this.state.type)?this.parseIdentifier():null}parseFunctionParams(e,t){this.expect(6),this.expressionScope.enter(DF()),e.params=this.parseBindingList(7,41,2|(t?4:0)),this.expressionScope.exit()}registerFunctionStatementId(e){e.id&&this.scope.declareName(e.id.name,!this.options.annexB||this.state.strict||e.generator||e.async?this.scope.treatFunctionsAsVar?5:8201:17,e.id.loc.start)}parseClass(e,t,n){this.next();let r=this.state.strict;return this.state.strict=!0,this.parseClassId(e,t,n),this.parseClassSuper(e),e.body=this.parseClassBody(!!e.superClass,r),this.finishNode(e,t?`ClassDeclaration`:`ClassExpression`)}isClassProperty(){return this.match(25)||this.match(9)||this.match(4)}isClassMethod(){return this.match(6)}nameIsConstructor(e){return e.type===`Identifier`&&e.name===`constructor`||e.type===`StringLiteral`&&e.value===`constructor`}isNonstaticConstructor(e){return!e.computed&&!e.static&&this.nameIsConstructor(e.key)}parseClassBody(e,t){this.classScope.enter();let n={hadConstructor:!1,hadSuperClass:e},r=[],i=this.startNode();for(i.body=[],this.expect(2);!this.match(4);){if(this.eat(9)){if(r.length>0)throw this.raise(G.DecoratorSemicolon,this.state.lastTokEndLoc);continue}if(this.match(22)){r.push(this.parseDecorator());continue}let e=this.startNode();r.length&&(e.decorators=r,this.resetStartLocationFromNode(e,r[0]),r=[]),this.parseClassMember(i,e,n),e.kind===`constructor`&&e.decorators&&e.decorators.length>0&&this.raise(G.DecoratorConstructor,e)}if(this.state.strict=t,this.next(),r.length)throw this.raise(G.TrailingDecorator,this.state.startLoc);return this.classScope.exit(),this.finishNode(i,`ClassBody`)}parseClassMemberFromModifier(e,t){let n=this.parseIdentifier(!0);if(this.isClassMethod()){let r=t;return r.kind=`method`,r.computed=!1,r.key=n,r.static=!1,this.pushClassMethod(e,r,!1,!1,!1,!1),!0}else if(this.isClassProperty()){let r=t;return r.computed=!1,r.key=n,r.static=!1,e.body.push(this.parseClassProperty(r)),!0}return this.resetPreviousNodeTrailingComments(n),!1}parseClassMember(e,t,n){let r=this.isContextual(102);if(r){if(this.parseClassMemberFromModifier(e,t))return;if(this.eat(2)){this.parseClassStaticBlock(e,t);return}}this.parseClassMemberWithIsStatic(e,t,n,r)}parseClassMemberWithIsStatic(e,t,n,r){let i=t,a=t,o=t,s=t,c=t,l=i,u=i;if(t.static=r,this.parsePropertyNamePrefixOperator(t),this.eat(51)){l.kind=`method`;let t=this.match(134);if(this.parseClassElementName(l),this.parsePostMemberNameModifiers(l),t){this.pushClassPrivateMethod(e,a,!0,!1);return}this.isNonstaticConstructor(i)&&this.raise(G.ConstructorIsGenerator,i.key),this.pushClassMethod(e,i,!0,!1,!1,!1);return}let d=!this.state.containsEsc&&Y(this.state.type),f=this.parseClassElementName(t),p=d?f.name:null,m=this.isPrivateName(f),h=this.state.startLoc;if(this.parsePostMemberNameModifiers(u),this.isClassMethod()){if(l.kind=`method`,m){this.pushClassPrivateMethod(e,a,!1,!1);return}let r=this.isNonstaticConstructor(i),o=!1;r&&(i.kind=`constructor`,n.hadConstructor&&!this.hasPlugin(`typescript`)&&this.raise(G.DuplicateConstructor,f),r&&this.hasPlugin(`typescript`)&&t.override&&this.raise(G.OverrideOnConstructor,f),n.hadConstructor=!0,o=n.hadSuperClass),this.pushClassMethod(e,i,!1,!1,r,o)}else if(this.isClassProperty())m?this.pushClassPrivateProperty(e,s):this.pushClassProperty(e,o);else if(p===`async`&&!this.isLineTerminator()){this.resetPreviousNodeTrailingComments(f);let t=this.eat(51);u.optional&&this.unexpected(h),l.kind=`method`;let n=this.match(134);this.parseClassElementName(l),this.parsePostMemberNameModifiers(u),n?this.pushClassPrivateMethod(e,a,t,!0):(this.isNonstaticConstructor(i)&&this.raise(G.ConstructorIsAsync,i.key),this.pushClassMethod(e,i,t,!0,!1,!1))}else if((p===`get`||p===`set`)&&!(this.match(51)&&this.isLineTerminator())){this.resetPreviousNodeTrailingComments(f),l.kind=p;let t=this.match(134);this.parseClassElementName(i),t?this.pushClassPrivateMethod(e,a,!1,!1):(this.isNonstaticConstructor(i)&&this.raise(G.ConstructorIsAccessor,i.key),this.pushClassMethod(e,i,!1,!1,!1,!1)),this.checkGetterSetterParams(i)}else if(p===`accessor`&&!this.isLineTerminator()){this.expectPlugin(`decoratorAutoAccessors`),this.resetPreviousNodeTrailingComments(f);let t=this.match(134);this.parseClassElementName(o),this.pushClassAccessorProperty(e,c,t)}else this.isLineTerminator()?m?this.pushClassPrivateProperty(e,s):this.pushClassProperty(e,o):this.unexpected()}parseClassElementName(e){let{type:t,value:n}=this.state;if((t===128||t===130)&&e.static&&n===`prototype`&&this.raise(G.StaticPrototype,this.state.startLoc),t===134){n===`constructor`&&this.raise(G.ConstructorClassPrivateField,this.state.startLoc);let t=this.parsePrivateName();return e.key=t,t}return this.parsePropertyName(e),e.key}parseClassStaticBlock(e,t){this.scope.enter(720);let n=this.state.labels;this.state.labels=[],this.prodParam.enter(0);let r=t.body=[];this.parseBlockOrModuleBlockBody(r,void 0,!1,4),this.prodParam.exit(),this.scope.exit(),this.state.labels=n,e.body.push(this.finishNode(t,`StaticBlock`)),t.decorators?.length&&this.raise(G.DecoratorStaticBlock,t)}pushClassProperty(e,t){!t.computed&&this.nameIsConstructor(t.key)&&this.raise(G.ConstructorClassField,t.key),e.body.push(this.parseClassProperty(t))}pushClassPrivateProperty(e,t){let n=this.parseClassPrivateProperty(t);e.body.push(n),this.classScope.declarePrivateName(this.getPrivateNameSV(n.key),0,n.key.loc.start)}pushClassAccessorProperty(e,t,n){!n&&!t.computed&&this.nameIsConstructor(t.key)&&this.raise(G.ConstructorClassField,t.key);let r=this.parseClassAccessorProperty(t);e.body.push(r),n&&this.classScope.declarePrivateName(this.getPrivateNameSV(r.key),0,r.key.loc.start)}pushClassMethod(e,t,n,r,i,a){e.body.push(this.parseMethod(t,n,r,i,a,`ClassMethod`,!0))}pushClassPrivateMethod(e,t,n,r){let i=this.parseMethod(t,n,r,!1,!1,`ClassPrivateMethod`,!0);e.body.push(i);let a=i.kind===`get`?i.static?6:2:i.kind===`set`?i.static?5:1:0;this.declareClassPrivateMethodInScope(i,a)}declareClassPrivateMethodInScope(e,t){this.classScope.declarePrivateName(this.getPrivateNameSV(e.key),t,e.key.loc.start)}parsePostMemberNameModifiers(e){}parseClassPrivateProperty(e){return this.parseInitializer(e),this.semicolon(),this.finishNode(e,`ClassPrivateProperty`)}parseClassProperty(e){return this.parseInitializer(e),this.semicolon(),this.finishNode(e,`ClassProperty`)}parseClassAccessorProperty(e){return this.parseInitializer(e),this.semicolon(),this.finishNode(e,`ClassAccessorProperty`)}parseInitializer(e){this.scope.enter(592),this.expressionScope.enter(AF()),this.prodParam.enter(0),e.value=this.eat(25)?this.parseMaybeAssignAllowIn():null,this.expressionScope.exit(),this.prodParam.exit(),this.scope.exit()}parseClassId(e,t,n,r=8331){if(Y(this.state.type))e.id=this.parseIdentifier(),t&&this.declareNameFromIdentifier(e.id,r);else if(n||!t)e.id=null;else throw this.raise(G.MissingClassName,this.state.startLoc)}parseClassSuper(e){e.superClass=this.eat(77)?this.parseExprSubscripts():null}parseExport(e,t){let n=this.parseMaybeImportPhase(e,!0),r=this.maybeParseExportDefaultSpecifier(e,n),i=!r||this.eat(8),a=i&&this.eatExportStar(e),o=a&&this.maybeParseExportNamespaceSpecifier(e),s=i&&(!o||this.eat(8)),c=r||a;if(a&&!o){if(r&&this.unexpected(),t)throw this.raise(G.UnsupportedDecoratorExport,e);return this.parseExportFrom(e,!0),this.sawUnambiguousESM=!0,this.finishNode(e,`ExportAllDeclaration`)}let l=this.maybeParseExportNamedSpecifiers(e);r&&i&&!a&&!l&&this.unexpected(null,2),o&&s&&this.unexpected(null,94);let u;if(c||l){if(u=!1,t)throw this.raise(G.UnsupportedDecoratorExport,e);this.parseExportFrom(e,c)}else u=this.maybeParseExportDeclaration(e);if(c||l||u){let n=e;if(this.checkExport(n,!0,!1,!!n.source),n.declaration?.type===`ClassDeclaration`)this.maybeTakeDecorators(t,n.declaration,n);else if(t)throw this.raise(G.UnsupportedDecoratorExport,e);return this.sawUnambiguousESM=!0,this.finishNode(n,`ExportNamedDeclaration`)}if(this.eat(61)){let n=e,r=this.parseExportDefaultExpression();if(n.declaration=r,r.type===`ClassDeclaration`)this.maybeTakeDecorators(t,r,n);else if(t)throw this.raise(G.UnsupportedDecoratorExport,e);return this.checkExport(n,!0,!0),this.sawUnambiguousESM=!0,this.finishNode(n,`ExportDefaultDeclaration`)}throw this.unexpected(null,2)}eatExportStar(e){return this.eat(51)}maybeParseExportDefaultSpecifier(e,t){if(t||this.isExportDefaultSpecifier()){this.expectPlugin(`exportDefaultFrom`,t?.loc.start);let n=t||this.parseIdentifier(!0),r=this.startNodeAtNode(n);return r.exported=n,e.specifiers=[this.finishNode(r,`ExportDefaultSpecifier`)],!0}return!1}maybeParseExportNamespaceSpecifier(e){if(this.isContextual(89)){e.specifiers??=[];let t=this.startNodeAt(this.state.lastTokStartLoc);return this.next(),t.exported=this.parseModuleExportName(),e.specifiers.push(this.finishNode(t,`ExportNamespaceSpecifier`)),!0}return!1}maybeParseExportNamedSpecifiers(e){if(this.match(2)){let t=e;t.specifiers||=[];let n=t.exportKind===`type`;return t.specifiers.push(...this.parseExportSpecifiers(n)),t.source=null,t.attributes=[],t.declaration=null,!0}return!1}maybeParseExportDeclaration(e){return this.shouldParseExportDeclaration()?(e.specifiers=[],e.source=null,e.attributes=[],e.declaration=this.parseExportDeclaration(e),!0):!1}isAsyncFunction(){if(!this.isContextual(91))return!1;let e=this.nextTokenInLineStart();return this.isUnparsedContextual(e,`function`)}parseExportDefaultExpression(){let e=this.startNode();if(this.match(64))return this.next(),this.parseFunction(e,5);if(this.isAsyncFunction())return this.next(),this.next(),this.parseFunction(e,13);if(this.match(76))return this.parseClass(e,!0,!0);if(this.match(22))return this.parseClass(this.maybeTakeDecorators(this.parseDecorators(!1),this.startNode()),!0,!0);if(this.match(71)||this.match(70)||this.isLet()||this.isUsing()||this.isAwaitUsing())throw this.raise(G.UnsupportedDefaultExport,this.state.startLoc);let t=this.parseMaybeAssignAllowIn();return this.semicolon(),t}parseExportDeclaration(e){return this.match(76)?this.parseClass(this.startNode(),!0,!1):this.parseStatementListItem()}isExportDefaultSpecifier(){let{type:e}=this.state;if(Y(e)){if(e===91&&!this.state.containsEsc||e===96)return!1;if((e===126||e===125)&&!this.state.containsEsc){let e=this.nextTokenStart(),t=this.input.charCodeAt(e);if(t===123||this.chStartsBindingIdentifier(t,e)&&!this.input.startsWith(`from`,e))return this.expectOnePlugin([`flow`,`typescript`]),!1}}else if(!this.match(61))return!1;let t=this.nextTokenStart(),n=this.isUnparsedContextual(t,`from`);if(this.input.charCodeAt(t)===44||Y(this.state.type)&&n)return!0;if(this.match(61)&&n){let e=this.input.charCodeAt(this.nextTokenStartSince(t+4));return e===34||e===39}return!1}parseExportFrom(e,t){this.eatContextual(94)?(e.source=this.parseImportSource(),this.checkExport(e),this.maybeParseImportAttributes(e)):t&&this.unexpected(),this.semicolon()}shouldParseExportDeclaration(){let{type:e}=this.state;return e===22&&(this.expectOnePlugin([`decorators`,`decorators-legacy`]),this.hasPlugin(`decorators`))?!0:this.isUsing()||this.isAwaitUsing()?(this.raise(G.UsingDeclarationExport,this.state.startLoc),!0):e===70||e===71||e===64||e===76||this.isLet()||this.isAsyncFunction()}checkExport(e,t,n,r){if(t){if(n){if(this.checkDuplicateExports(e,`default`),this.hasPlugin(`exportDefaultFrom`)){let t=e.declaration;t.type===`Identifier`&&t.name===`from`&&t.end-t.start===4&&!t.extra?.parenthesized&&this.raise(G.ExportDefaultFromAsIdentifier,t)}}else if(e.specifiers?.length)for(let t of e.specifiers){let{exported:e}=t,n=e.type===`Identifier`?e.name:e.value;if(this.checkDuplicateExports(t,n),!r&&t.local){let{local:e}=t;e.type===`Identifier`?(this.checkReservedWord(e.name,e.loc.start,!0,!1),this.scope.checkLocalExport(e)):this.raise(G.ExportBindingIsString,t,{localName:e.value,exportName:n})}}else if(e.declaration){let t=e.declaration;if(t.type===`FunctionDeclaration`||t.type===`ClassDeclaration`){let{id:n}=t;if(!n)throw Error(`Assertion failure`);this.checkDuplicateExports(e,n.name)}else if(t.type===`VariableDeclaration`)for(let e of t.declarations)this.checkDeclaration(e.id)}}}checkDeclaration(e){if(e.type===`Identifier`)this.checkDuplicateExports(e,e.name);else if(e.type===`ObjectPattern`)for(let t of e.properties)this.checkDeclaration(t);else if(e.type===`ArrayPattern`)for(let t of e.elements)t&&this.checkDeclaration(t);else e.type===`ObjectProperty`?this.checkDeclaration(e.value):e.type===`RestElement`?this.checkDeclaration(e.argument):e.type===`AssignmentPattern`&&this.checkDeclaration(e.left)}checkDuplicateExports(e,t){this.exportedIdentifiers.has(t)&&(t===`default`?this.raise(G.DuplicateDefaultExport,e):this.raise(G.DuplicateExport,e,{exportName:t})),this.exportedIdentifiers.add(t)}parseExportSpecifiers(e){let t=[],n=!0;for(this.expect(2);!this.eat(4);){if(n)n=!1;else if(this.expect(8),this.eat(4))break;let r=this.isContextual(126),i=this.match(130),a=this.startNode();a.local=this.parseModuleExportName(),t.push(this.parseExportSpecifier(a,i,e,r))}return t}parseExportSpecifier(e,t,n,r){return this.eatContextual(89)?e.exported=this.parseModuleExportName():t?e.exported=this.cloneStringLiteral(e.local):e.exported||=this.cloneIdentifier(e.local),this.finishNode(e,`ExportSpecifier`)}parseModuleExportName(){if(this.match(130)){let e=this.parseStringLiteral(this.state.value),t=cI.exec(e.value);return t&&this.raise(G.ModuleExportNameHasLoneSurrogate,e,{surrogateCharCode:t[0].charCodeAt(0)}),e}return this.parseIdentifier(!0)}checkImportPhase(e){let{specifiers:t}=e,n=t.length===1?t[0].type:null;e.phase===`source`?n!==`ImportDefaultSpecifier`&&this.raise(G.SourcePhaseImportRequiresDefault,t[0].loc.start):e.phase===`defer`&&n!==`ImportNamespaceSpecifier`&&this.raise(G.DeferImportRequiresNamespace,t[0].loc.start)}isPotentialImportPhase(e){return e?!1:this.isContextual(101)||this.isContextual(93)}applyImportPhase(e,t,n,r){t||(n===`source`?(this.expectPlugin(`sourcePhaseImports`,r),e.phase=`source`):n===`defer`?(this.expectPlugin(`deferredImportEvaluation`,r),e.phase=`defer`):this.hasPlugin(`sourcePhaseImports`)&&(e.phase=null))}parseMaybeImportPhase(e,t){if(!this.isPotentialImportPhase(t))return this.applyImportPhase(e,t,null),null;let n=this.startNode(),r=this.parseIdentifierName(!0),{type:i}=this.state;return(WN(i)?i!==94||this.lookaheadCharCode()===102:i!==8)?(this.applyImportPhase(e,t,r,n.loc.start),null):(this.applyImportPhase(e,t,null),this.createIdentifier(n,r))}isPrecedingIdImportPhase(e){let{type:t}=this.state;return Y(t)?t!==94||this.lookaheadCharCode()===102:t!==8}parseImport(e){return this.match(130)?this.parseImportSourceAndAttributes(e):this.parseImportSpecifiersAndAfter(e,this.parseMaybeImportPhase(e,!1))}parseImportSpecifiersAndAfter(e,t){e.specifiers=[];let n=!this.maybeParseDefaultImportSpecifier(e,t)||this.eat(8),r=n&&this.maybeParseStarImportSpecifier(e);return n&&!r&&this.parseNamedImportSpecifiers(e),this.expectContextual(94),this.parseImportSourceAndAttributes(e)}parseImportSourceAndAttributes(e){return e.specifiers??=[],e.source=this.parseImportSource(),this.maybeParseImportAttributes(e),this.checkImportPhase(e),this.semicolon(),this.sawUnambiguousESM=!0,this.finishNode(e,`ImportDeclaration`)}parseImportSource(){return this.match(130)||this.unexpected(),this.parseExprAtom()}parseImportSpecifierLocal(e,t,n){t.local=this.parseIdentifier(),e.specifiers.push(this.finishImportSpecifier(t,n))}finishImportSpecifier(e,t,n=8201){return this.checkLVal(e.local,{type:t},n),this.finishNode(e,t)}parseImportAttributes(){this.expect(2);let e=[],t=new Set;do{if(this.match(4))break;let n=this.startNode(),r=this.state.value;if(t.has(r)&&this.raise(G.ModuleAttributesWithDuplicateKeys,this.state.startLoc,{key:r}),t.add(r),this.match(130)?n.key=this.parseStringLiteral(r):n.key=this.parseIdentifier(!0),this.expect(10),!this.match(130))throw this.raise(G.ModuleAttributeInvalidValue,this.state.startLoc);n.value=this.parseStringLiteral(this.state.value),e.push(this.finishNode(n,`ImportAttribute`))}while(this.eat(8));return this.expect(4),e}maybeParseImportAttributes(e){let t;if(this.match(72)){if(this.hasPrecedingLineBreak()&&this.lookaheadCharCode()===40)return;this.next(),t=this.parseImportAttributes()}else t=[];e.attributes=t}maybeParseDefaultImportSpecifier(e,t){if(t){let n=this.startNodeAtNode(t);return n.local=t,e.specifiers.push(this.finishImportSpecifier(n,`ImportDefaultSpecifier`)),!0}else if(WN(this.state.type))return this.parseImportSpecifierLocal(e,this.startNode(),`ImportDefaultSpecifier`),!0;return!1}maybeParseStarImportSpecifier(e){if(this.match(51)){let t=this.startNode();return this.next(),this.expectContextual(89),this.parseImportSpecifierLocal(e,t,`ImportNamespaceSpecifier`),!0}return!1}parseNamedImportSpecifiers(e){let t=!0;for(this.expect(2);!this.eat(4);){if(t)t=!1;else{if(this.eat(10))throw this.raise(G.DestructureNamedImport,this.state.startLoc);if(this.expect(8),this.eat(4))break}let n=this.startNode(),r=this.match(130),i=this.isContextual(126);n.imported=this.parseModuleExportName();let a=this.parseImportSpecifier(n,r,e.importKind===`type`||e.importKind===`typeof`,i,void 0);e.specifiers.push(a)}}parseImportSpecifier(e,t,n,r,i){if(this.eatContextual(89))e.local=this.parseIdentifier();else{let{imported:n}=e;if(t)throw this.raise(G.ImportBindingIsString,e,{importName:n.value});this.checkReservedWord(n.name,e.loc.start,!0,!0),e.local||=this.cloneIdentifier(n)}return this.finishImportSpecifier(e,`ImportSpecifier`,i)}isThisParam(e){return e.type===`Identifier`&&e.name===`this`}},fI=class extends dI{constructor(e,t,n){let r=DN(e);super(r,t),this.options=r,this.initializeScopes(),this.plugins=n,this.filename=r.sourceFilename,this.startIndex=r.startIndex;let i=0;r.allowAwaitOutsideFunction&&(i|=1),r.allowReturnOutsideFunction&&(i|=2),r.allowImportExportEverywhere&&(i|=8),r.allowSuperOutsideMethod&&(i|=16),r.allowUndeclaredExports&&(i|=64),r.allowNewTargetOutsideFunction&&(i|=4),r.allowYieldOutsideFunction&&(i|=32),r.ranges&&(i|=128),r.tokens&&(i|=256),r.createImportExpressions&&(i|=512),r.createParenthesizedExpressions&&(i|=1024),r.errorRecovery&&(i|=2048),r.attachComment&&(i|=4096),r.annexB&&(i|=8192),this.optionFlags=i}getScopeHandler(){return jP}parse(){this.enterInitialScopes();let e=this.startNode(),t=this.startNode();this.nextToken(),e.errors=[];let n=this.parseTopLevel(e,t);return n.errors=this.state.errors,n.comments.length=this.state.commentsLen,n}};function pI(e,t){if(t?.sourceType===`unambiguous`){t={...t};try{t.sourceType=`module`;let n=hI(t,e),r=n.parse();if(n.sawUnambiguousESM)return r;if(n.ambiguousScriptDifferentAst)try{return t.sourceType=`script`,hI(t,e).parse()}catch{}else r.program.sourceType=`script`;return r}catch(n){try{return t.sourceType=`script`,hI(t,e).parse()}catch{}throw n}}else return hI(t,e).parse()}function mI(e){let t={};for(let n of Object.keys(e))t[n]=sP(e[n]);return t}mI(HN);function hI(e,t){let n=fI,r=new Map;if(e?.plugins){for(let t of e.plugins){let e,n;typeof t==`string`?e=t:[e,n]=t,r.has(e)||r.set(e,n||{})}nI(r),n=_I(r)}return new n(e,t,r)}const gI=new Map;function _I(e){let t=[];for(let n of iI)e.has(n)&&t.push(n);let n=t.join(`|`),r=gI.get(n);if(!r){r=fI;for(let e of t)r=rI[e](r);gI.set(n,r)}return r}var vI=class{constructor(){this.should_skip=!1,this.should_remove=!1,this.replacement=null,this.context={skip:()=>this.should_skip=!0,remove:()=>this.should_remove=!0,replace:e=>this.replacement=e}}replace(e,t,n,r){e&&t&&(n==null?e[t]=r:e[t][n]=r)}remove(e,t,n){e&&t&&(n==null?delete e[t]:e[t].splice(n,1))}},yI=class extends vI{constructor(e,t){super(),this.should_skip=!1,this.should_remove=!1,this.replacement=null,this.context={skip:()=>this.should_skip=!0,remove:()=>this.should_remove=!0,replace:e=>this.replacement=e},this.enter=e,this.leave=t}visit(e,t,n,r){if(e){if(this.enter){let i=this.should_skip,a=this.should_remove,o=this.replacement;this.should_skip=!1,this.should_remove=!1,this.replacement=null,this.enter.call(this.context,e,t,n,r),this.replacement&&(e=this.replacement,this.replace(t,n,r,e)),this.should_remove&&this.remove(t,n,r);let s=this.should_skip,c=this.should_remove;if(this.should_skip=i,this.should_remove=a,this.replacement=o,s)return e;if(c)return null}let i;for(i in e){let t=e[i];if(t&&typeof t==`object`)if(Array.isArray(t)){let n=t;for(let t=0;t<n.length;t+=1){let r=n[t];bI(r)&&(this.visit(r,e,i,t)||t--)}}else bI(t)&&this.visit(t,e,i,null)}if(this.leave){let i=this.replacement,a=this.should_remove;this.replacement=null,this.should_remove=!1,this.leave.call(this.context,e,t,n,r),this.replacement&&(e=this.replacement,this.replace(t,n,r,e)),this.should_remove&&this.remove(t,n,r);let o=this.should_remove;if(this.replacement=i,this.should_remove=a,o)return null}}return e}};function bI(e){return typeof e==`object`&&!!e&&`type`in e&&typeof e.type==`string`}function xI(e,{enter:t,leave:n}){return new yI(t,n).visit(e,null)}function SI(e,t){return e?[].concat(t).some(t=>{switch(t){case`Function`:return TI(e);case`Literal`:return wI(e);case`Expression`:return DI(e);default:return e.type===t}}):!1}function CI(e,t){return kI(e)&&OI(e.name,t)}function wI(e){return!!e&&e.type.endsWith(`Literal`)}function TI(e){return!!e&&!e.type.startsWith(`TS`)&&/Function(?:Expression|Declaration)$|Method$/.test(e.type)}function EI(e){if(!e)return!1;switch(e.type){case`FunctionDeclaration`:case`VariableDeclaration`:case`ClassDeclaration`:case`ExportAllDeclaration`:case`ExportDefaultDeclaration`:case`ExportNamedDeclaration`:case`ImportDeclaration`:case`DeclareClass`:case`DeclareFunction`:case`DeclareInterface`:case`DeclareModule`:case`DeclareModuleExports`:case`DeclareTypeAlias`:case`DeclareOpaqueType`:case`DeclareVariable`:case`DeclareExportDeclaration`:case`DeclareExportAllDeclaration`:case`InterfaceDeclaration`:case`OpaqueType`:case`TypeAlias`:case`EnumDeclaration`:case`TSDeclareFunction`:case`TSInterfaceDeclaration`:case`TSTypeAliasDeclaration`:case`TSEnumDeclaration`:case`TSModuleDeclaration`:return!0;case`Placeholder`:if(e.expectedNode===`Declaration`)return!0}return!1}function DI(e){return!!e&&(e.type.endsWith(`Expression`)||wI(e)||[`Identifier`,`MetaProperty`,`Super`,`Import`,`JSXElement`,`JSXFragment`,`TopicReference`,`PipelineBareFunction`,`PipelinePrimaryTopicReference`,`TSTypeAssertion`].includes(e.type))}function OI(e,t){return Array.isArray(t)?t.includes(e):typeof t==`function`?t(e):e===t}function kI(e){return!!e&&(e.type===`Identifier`||e.type===`JSXIdentifier`)}function AI(e,t=!1){if(typeof e==`string`)return e;switch(e.type){case`Identifier`:if(t)throw TypeError(`Invalid Identifier`);return e.name;case`PrivateName`:return`#${e.id.name}`;case`ThisExpression`:return`this`;case`Super`:return`super`}return String(jI(e))}function jI(e){switch(e.type){case`TemplateLiteral`:return MI(e);case`NullLiteral`:return null;case`BigIntLiteral`:return BigInt(e.value);case`RegExpLiteral`:return new RegExp(e.pattern,e.flags);case`BooleanLiteral`:case`NumericLiteral`:case`StringLiteral`:return e.value}}function MI(e){return e.quasis.reduce((t,n,r)=>{let i=e.expressions[r];if(i){if(!wI(i))throw TypeError(`TemplateLiteral expression must be a literal`);return t+n.value.cooked+jI(i)}return t+n.value.cooked},``)}const NI=xI,PI=e=>typeof e==`object`&&!!e,FI=(e,t)=>Object.assign(Error(`[${e}]: ${t}`),{code:e}),II=`ERR_INVALID_PACKAGE_CONFIG`,LI=`ERR_INVALID_PACKAGE_TARGET`,RI=/^\d+$/,zI=/^(\.{1,2}|node_modules)$/i,BI=/\/|\\/;var VI=(e=>(e.Export=`exports`,e.Import=`imports`,e))(VI||{});const HI=(e,t,n,r,i)=>{if(t==null)return[];if(typeof t==`string`){let[n,...r]=t.split(BI);if(n===`..`||r.some(e=>zI.test(e)))throw FI(LI,`Invalid "${e}" target "${t}" defined in the package config`);return[i?t.replace(/\*/g,i):t]}if(Array.isArray(t))return t.flatMap(t=>HI(e,t,n,r,i));if(PI(t)){for(let a of Object.keys(t)){if(RI.test(a))throw FI(II,`Cannot contain numeric property keys`);if(a===`default`||r.includes(a))return HI(e,t[a],n,r,i)}return[]}throw FI(LI,`Invalid "${e}" target "${t}"`)},UI=(e,t)=>{let n=e.indexOf(`*`),r=t.indexOf(`*`);return n===r?t.length>e.length:r>n};function WI(e,t){if(!t.includes(`*`)&&e.hasOwnProperty(t))return[t];let n,r;for(let i of Object.keys(e))if(i.includes(`*`)){let[e,a,o]=i.split(`*`);if(o===void 0&&t.startsWith(e)&&t.endsWith(a)){let o=t.slice(e.length,-a.length||void 0);o&&(!n||UI(n,i))&&(n=i,r=o)}}return[n,r]}const GI=e=>Object.keys(e).reduce((e,t)=>{let n=t===``||t[0]!==`.`;if(e===void 0||e===n)return n;throw FI(II,`"exports" cannot contain some keys starting with "." and some not`)},void 0),KI=/^\w+:/,qI=(e,t,n)=>{if(!e)throw Error(`"exports" is required`);t=t===``?`.`:`./${t}`,(typeof e==`string`||Array.isArray(e)||PI(e)&&GI(e))&&(e={".":e});let[r,i]=WI(e,t),a=HI(VI.Export,e[r],t,n,i);if(a.length===0)throw FI(`ERR_PACKAGE_PATH_NOT_EXPORTED`,t===`.`?`No "exports" main defined`:`Package subpath '${t}' is not defined by "exports"`);for(let e of a)if(!e.startsWith(`./`)&&!KI.test(e))throw FI(LI,`Invalid "exports" target "${e}" defined in the package config`);return a};var JI=Object.defineProperty,$=(e,t)=>JI(e,`name`,{value:t,configurable:!0});function YI(e){return e.startsWith(`\\\\?\\`)?e:e.replace(/\\/g,`/`)}$(YI,`slash`);const XI=$(e=>{let t=le[e];return(n,...r)=>{let i=`${e}:${r.join(`:`)}`,a=n?.get(i);return a===void 0&&(a=Reflect.apply(t,le,r),n?.set(i,a)),a}},`cacheFs`),ZI=XI(`existsSync`),QI=XI(`readFileSync`),$I=XI(`statSync`),eL=$((e,t,n)=>{for(;;){let r=x.posix.join(e,t);if(ZI(n,r))return r;let i=x.dirname(e);if(i===e)return;e=i}},`findUp`),tL=/^\.{1,2}(\/.*)?$/,nL=$(e=>{let t=YI(e);return tL.test(t)?t:`./${t}`},`normalizeRelativePath`);function rL(e,t=!1){let n=e.length,r=0,i=``,a=0,o=16,s=0,c=0,l=0,u=0,d=0;function f(t,n){let i=0,a=0;for(;i<t;){let t=e.charCodeAt(r);if(t>=48&&t<=57)a=a*16+t-48;else if(t>=65&&t<=70)a=a*16+t-65+10;else if(t>=97&&t<=102)a=a*16+t-97+10;else break;r++,i++}return i<t&&(a=-1),a}$(f,`scanHexDigits`);function p(e){r=e,i=``,a=0,o=16,d=0}$(p,`setPosition`);function m(){let t=r;if(e.charCodeAt(r)===48)r++;else for(r++;r<e.length&&oL(e.charCodeAt(r));)r++;if(r<e.length&&e.charCodeAt(r)===46)if(r++,r<e.length&&oL(e.charCodeAt(r)))for(r++;r<e.length&&oL(e.charCodeAt(r));)r++;else return d=3,e.substring(t,r);let n=r;if(r<e.length&&(e.charCodeAt(r)===69||e.charCodeAt(r)===101))if(r++,(r<e.length&&e.charCodeAt(r)===43||e.charCodeAt(r)===45)&&r++,r<e.length&&oL(e.charCodeAt(r))){for(r++;r<e.length&&oL(e.charCodeAt(r));)r++;n=r}else d=3;return e.substring(t,n)}$(m,`scanNumber`);function h(){let t=``,i=r;for(;;){if(r>=n){t+=e.substring(i,r),d=2;break}let a=e.charCodeAt(r);if(a===34){t+=e.substring(i,r),r++;break}if(a===92){if(t+=e.substring(i,r),r++,r>=n){d=2;break}switch(e.charCodeAt(r++)){case 34:t+=`"`;break;case 92:t+=`\\`;break;case 47:t+=`/`;break;case 98:t+=`\b`;break;case 102:t+=`\f`;break;case 110:t+=`
|
|
16
|
+
`;break;case 114:t+=`\r`;break;case 116:t+=` `;break;case 117:let e=f(4);e>=0?t+=String.fromCharCode(e):d=4;break;default:d=5}i=r;continue}if(a>=0&&a<=31)if(aL(a)){t+=e.substring(i,r),d=2;break}else d=6;r++}return t}$(h,`scanString`);function g(){if(i=``,d=0,a=r,c=s,u=l,r>=n)return a=n,o=17;let t=e.charCodeAt(r);if(iL(t)){do r++,i+=String.fromCharCode(t),t=e.charCodeAt(r);while(iL(t));return o=15}if(aL(t))return r++,i+=String.fromCharCode(t),t===13&&e.charCodeAt(r)===10&&(r++,i+=`
|
|
17
|
+
`),s++,l=r,o=14;switch(t){case 123:return r++,o=1;case 125:return r++,o=2;case 91:return r++,o=3;case 93:return r++,o=4;case 58:return r++,o=6;case 44:return r++,o=5;case 34:return r++,i=h(),o=10;case 47:let c=r-1;if(e.charCodeAt(r+1)===47){for(r+=2;r<n&&!aL(e.charCodeAt(r));)r++;return i=e.substring(c,r),o=12}if(e.charCodeAt(r+1)===42){r+=2;let t=n-1,a=!1;for(;r<t;){let t=e.charCodeAt(r);if(t===42&&e.charCodeAt(r+1)===47){r+=2,a=!0;break}r++,aL(t)&&(t===13&&e.charCodeAt(r)===10&&r++,s++,l=r)}return a||(r++,d=1),i=e.substring(c,r),o=13}return i+=String.fromCharCode(t),r++,o=16;case 45:if(i+=String.fromCharCode(t),r++,r===n||!oL(e.charCodeAt(r)))return o=16;case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return i+=m(),o=11;default:for(;r<n&&ee(t);)r++,t=e.charCodeAt(r);if(a!==r){switch(i=e.substring(a,r),i){case`true`:return o=8;case`false`:return o=9;case`null`:return o=7}return o=16}return i+=String.fromCharCode(t),r++,o=16}}$(g,`scanNext`);function ee(e){if(iL(e)||aL(e))return!1;switch(e){case 125:case 93:case 123:case 91:case 34:case 58:case 44:case 47:return!1}return!0}$(ee,`isUnknownContentCharacter`);function _(){let e;do e=g();while(e>=12&&e<=15);return e}return $(_,`scanNextNonTrivia`),{setPosition:p,getPosition:$(()=>r,`getPosition`),scan:t?_:g,getToken:$(()=>o,`getToken`),getTokenValue:$(()=>i,`getTokenValue`),getTokenOffset:$(()=>a,`getTokenOffset`),getTokenLength:$(()=>r-a,`getTokenLength`),getTokenStartLine:$(()=>c,`getTokenStartLine`),getTokenStartCharacter:$(()=>a-u,`getTokenStartCharacter`),getTokenError:$(()=>d,`getTokenError`)}}$(rL,`createScanner`);function iL(e){return e===32||e===9}$(iL,`isWhiteSpace`);function aL(e){return e===10||e===13}$(aL,`isLineBreak`);function oL(e){return e>=48&&e<=57}$(oL,`isDigit`);var sL;(function(e){e[e.lineFeed=10]=`lineFeed`,e[e.carriageReturn=13]=`carriageReturn`,e[e.space=32]=`space`,e[e._0=48]=`_0`,e[e._1=49]=`_1`,e[e._2=50]=`_2`,e[e._3=51]=`_3`,e[e._4=52]=`_4`,e[e._5=53]=`_5`,e[e._6=54]=`_6`,e[e._7=55]=`_7`,e[e._8=56]=`_8`,e[e._9=57]=`_9`,e[e.a=97]=`a`,e[e.b=98]=`b`,e[e.c=99]=`c`,e[e.d=100]=`d`,e[e.e=101]=`e`,e[e.f=102]=`f`,e[e.g=103]=`g`,e[e.h=104]=`h`,e[e.i=105]=`i`,e[e.j=106]=`j`,e[e.k=107]=`k`,e[e.l=108]=`l`,e[e.m=109]=`m`,e[e.n=110]=`n`,e[e.o=111]=`o`,e[e.p=112]=`p`,e[e.q=113]=`q`,e[e.r=114]=`r`,e[e.s=115]=`s`,e[e.t=116]=`t`,e[e.u=117]=`u`,e[e.v=118]=`v`,e[e.w=119]=`w`,e[e.x=120]=`x`,e[e.y=121]=`y`,e[e.z=122]=`z`,e[e.A=65]=`A`,e[e.B=66]=`B`,e[e.C=67]=`C`,e[e.D=68]=`D`,e[e.E=69]=`E`,e[e.F=70]=`F`,e[e.G=71]=`G`,e[e.H=72]=`H`,e[e.I=73]=`I`,e[e.J=74]=`J`,e[e.K=75]=`K`,e[e.L=76]=`L`,e[e.M=77]=`M`,e[e.N=78]=`N`,e[e.O=79]=`O`,e[e.P=80]=`P`,e[e.Q=81]=`Q`,e[e.R=82]=`R`,e[e.S=83]=`S`,e[e.T=84]=`T`,e[e.U=85]=`U`,e[e.V=86]=`V`,e[e.W=87]=`W`,e[e.X=88]=`X`,e[e.Y=89]=`Y`,e[e.Z=90]=`Z`,e[e.asterisk=42]=`asterisk`,e[e.backslash=92]=`backslash`,e[e.closeBrace=125]=`closeBrace`,e[e.closeBracket=93]=`closeBracket`,e[e.colon=58]=`colon`,e[e.comma=44]=`comma`,e[e.dot=46]=`dot`,e[e.doubleQuote=34]=`doubleQuote`,e[e.minus=45]=`minus`,e[e.openBrace=123]=`openBrace`,e[e.openBracket=91]=`openBracket`,e[e.plus=43]=`plus`,e[e.slash=47]=`slash`,e[e.formFeed=12]=`formFeed`,e[e.tab=9]=`tab`})(sL||={}),Array(20).fill(0).map((e,t)=>` `.repeat(t)),Array(200).fill(0).map((e,t)=>`
|
|
18
|
+
`+` `.repeat(t)),Array(200).fill(0).map((e,t)=>`\r`+` `.repeat(t)),Array(200).fill(0).map((e,t)=>`\r
|
|
19
|
+
`+` `.repeat(t)),Array(200).fill(0).map((e,t)=>`
|
|
20
|
+
`+` `.repeat(t)),Array(200).fill(0).map((e,t)=>`\r`+` `.repeat(t)),Array(200).fill(0).map((e,t)=>`\r
|
|
21
|
+
`+` `.repeat(t));var cL;(function(e){e.DEFAULT={allowTrailingComma:!1}})(cL||={});function lL(e,t=[],n=cL.DEFAULT){let r=null,i=[],a=[];function o(e){Array.isArray(i)?i.push(e):r!==null&&(i[r]=e)}return $(o,`onValue`),uL(e,{onObjectBegin:$(()=>{let e={};o(e),a.push(i),i=e,r=null},`onObjectBegin`),onObjectProperty:$(e=>{r=e},`onObjectProperty`),onObjectEnd:$(()=>{i=a.pop()},`onObjectEnd`),onArrayBegin:$(()=>{let e=[];o(e),a.push(i),i=e,r=null},`onArrayBegin`),onArrayEnd:$(()=>{i=a.pop()},`onArrayEnd`),onLiteralValue:o,onError:$((e,n,r)=>{t.push({error:e,offset:n,length:r})},`onError`)},n),i[0]}$(lL,`parse$1`);function uL(e,t,n=cL.DEFAULT){let r=rL(e,!1),i=[],a=0;function o(e){return e?()=>a===0&&e(r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter()):()=>!0}$(o,`toNoArgVisit`);function s(e){return e?t=>a===0&&e(t,r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter()):()=>!0}$(s,`toOneArgVisit`);function c(e){return e?t=>a===0&&e(t,r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter(),()=>i.slice()):()=>!0}$(c,`toOneArgVisitWithPath`);function l(e){return e?()=>{a>0?a++:e(r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter(),()=>i.slice())===!1&&(a=1)}:()=>!0}$(l,`toBeginVisit`);function u(e){return e?()=>{a>0&&a--,a===0&&e(r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter())}:()=>!0}$(u,`toEndVisit`);let d=l(t.onObjectBegin),f=c(t.onObjectProperty),p=u(t.onObjectEnd),m=l(t.onArrayBegin),h=u(t.onArrayEnd),g=c(t.onLiteralValue),ee=s(t.onSeparator),_=o(t.onComment),v=s(t.onError),te=n&&n.disallowComments,ne=n&&n.allowTrailingComma;function y(){for(;;){let e=r.scan();switch(r.getTokenError()){case 4:b(14);break;case 5:b(15);break;case 3:b(13);break;case 1:te||b(11);break;case 2:b(12);break;case 6:b(16);break}switch(e){case 12:case 13:te?b(10):_();break;case 16:b(1);break;case 15:case 14:break;default:return e}}}$(y,`scanNext`);function b(e,t=[],n=[]){if(v(e),t.length+n.length>0){let e=r.getToken();for(;e!==17;){if(t.indexOf(e)!==-1){y();break}else if(n.indexOf(e)!==-1)break;e=y()}}}$(b,`handleError`);function re(e){let t=r.getTokenValue();return e?g(t):(f(t),i.push(t)),y(),!0}$(re,`parseString`);function ie(){switch(r.getToken()){case 11:let e=r.getTokenValue(),t=Number(e);isNaN(t)&&(b(2),t=0),g(t);break;case 7:g(null);break;case 8:g(!0);break;case 9:g(!1);break;default:return!1}return y(),!0}$(ie,`parseLiteral`);function ae(){return r.getToken()===10?(re(!1),r.getToken()===6?(ee(`:`),y(),se()||b(4,[],[2,5])):b(5,[],[2,5]),i.pop(),!0):(b(3,[],[2,5]),!1)}$(ae,`parseProperty`);function x(){d(),y();let e=!1;for(;r.getToken()!==2&&r.getToken()!==17;){if(r.getToken()===5){if(e||b(4,[],[]),ee(`,`),y(),r.getToken()===2&&ne)break}else e&&b(6,[],[]);ae()||b(4,[],[2,5]),e=!0}return p(),r.getToken()===2?y():b(7,[2],[]),!0}$(x,`parseObject`);function oe(){m(),y();let e=!0,t=!1;for(;r.getToken()!==4&&r.getToken()!==17;){if(r.getToken()===5){if(t||b(4,[],[]),ee(`,`),y(),r.getToken()===4&&ne)break}else t&&b(6,[],[]);e?(i.push(0),e=!1):i[i.length-1]++,se()||b(4,[],[4,5]),t=!0}return h(),e||i.pop(),r.getToken()===4?y():b(8,[4],[]),!0}$(oe,`parseArray`);function se(){switch(r.getToken()){case 3:return oe();case 1:return x();case 10:return re(!0);default:return ie()}}return $(se,`parseValue`),y(),r.getToken()===17?n.allowEmptyContent?!0:(b(4,[],[]),!1):se()?(r.getToken()!==17&&b(9,[],[]),!0):(b(4,[],[]),!1)}$(uL,`visit`);var dL;(function(e){e[e.None=0]=`None`,e[e.UnexpectedEndOfComment=1]=`UnexpectedEndOfComment`,e[e.UnexpectedEndOfString=2]=`UnexpectedEndOfString`,e[e.UnexpectedEndOfNumber=3]=`UnexpectedEndOfNumber`,e[e.InvalidUnicode=4]=`InvalidUnicode`,e[e.InvalidEscapeCharacter=5]=`InvalidEscapeCharacter`,e[e.InvalidCharacter=6]=`InvalidCharacter`})(dL||={});var fL;(function(e){e[e.OpenBraceToken=1]=`OpenBraceToken`,e[e.CloseBraceToken=2]=`CloseBraceToken`,e[e.OpenBracketToken=3]=`OpenBracketToken`,e[e.CloseBracketToken=4]=`CloseBracketToken`,e[e.CommaToken=5]=`CommaToken`,e[e.ColonToken=6]=`ColonToken`,e[e.NullKeyword=7]=`NullKeyword`,e[e.TrueKeyword=8]=`TrueKeyword`,e[e.FalseKeyword=9]=`FalseKeyword`,e[e.StringLiteral=10]=`StringLiteral`,e[e.NumericLiteral=11]=`NumericLiteral`,e[e.LineCommentTrivia=12]=`LineCommentTrivia`,e[e.BlockCommentTrivia=13]=`BlockCommentTrivia`,e[e.LineBreakTrivia=14]=`LineBreakTrivia`,e[e.Trivia=15]=`Trivia`,e[e.Unknown=16]=`Unknown`,e[e.EOF=17]=`EOF`})(fL||={});const pL=lL;var mL;(function(e){e[e.InvalidSymbol=1]=`InvalidSymbol`,e[e.InvalidNumberFormat=2]=`InvalidNumberFormat`,e[e.PropertyNameExpected=3]=`PropertyNameExpected`,e[e.ValueExpected=4]=`ValueExpected`,e[e.ColonExpected=5]=`ColonExpected`,e[e.CommaExpected=6]=`CommaExpected`,e[e.CloseBraceExpected=7]=`CloseBraceExpected`,e[e.CloseBracketExpected=8]=`CloseBracketExpected`,e[e.EndOfFileExpected=9]=`EndOfFileExpected`,e[e.InvalidCommentToken=10]=`InvalidCommentToken`,e[e.UnexpectedEndOfComment=11]=`UnexpectedEndOfComment`,e[e.UnexpectedEndOfString=12]=`UnexpectedEndOfString`,e[e.UnexpectedEndOfNumber=13]=`UnexpectedEndOfNumber`,e[e.InvalidUnicode=14]=`InvalidUnicode`,e[e.InvalidEscapeCharacter=15]=`InvalidEscapeCharacter`,e[e.InvalidCharacter=16]=`InvalidCharacter`})(mL||={});const hL=$((e,t)=>pL(QI(t,e,`utf8`)),`readJsonc`),gL=Symbol(`implicitBaseUrl`),_L="${configDir}",vL=$(()=>{let{findPnpApi:e}=ie;return e&&e(process.cwd())},`getPnpApi`),yL=$((e,t,n,r)=>{let i=`resolveFromPackageJsonPath:${e}:${t}:${n}`;if(r!=null&&r.has(i))return r.get(i);let a=hL(e,r);if(!a)return;let o=t||`tsconfig.json`;if(!n&&a.exports)try{let[e]=qI(a.exports,t,[`require`,`types`]);o=e}catch{return!1}else !t&&a.tsconfig&&(o=a.tsconfig);return o=x.join(e,`..`,o),r?.set(i,o),o},`resolveFromPackageJsonPath`),bL=`package.json`,xL=`tsconfig.json`,SL=$((e,t,n)=>{let r=e;if(e===`..`&&(r=x.join(r,xL)),e[0]===`.`&&(r=x.resolve(t,r)),x.isAbsolute(r)){if(ZI(n,r)){if($I(n,r).isFile())return r}else if(!r.endsWith(`.json`)){let e=`${r}.json`;if(ZI(n,e))return e}return}let[i,...a]=e.split(`/`),o=i[0]===`@`?`${i}/${a.shift()}`:i,s=a.join(`/`),c=vL();if(c){let{resolveRequest:r}=c;try{if(o===e){let e=r(x.join(o,bL),t);if(e){let t=yL(e,s,!1,n);if(t&&ZI(n,t))return t}}else{let n;try{n=r(e,t,{extensions:[`.json`]})}catch{n=r(x.join(e,xL),t)}if(n)return n}}catch{}}let l=eL(x.resolve(t),x.join(`node_modules`,o),n);if(!l||!$I(n,l).isDirectory())return;let u=x.join(l,bL);if(ZI(n,u)){let e=yL(u,s,!1,n);if(e===!1)return;if(e&&ZI(n,e)&&$I(n,e).isFile())return e}let d=x.join(l,s),f=d.endsWith(`.json`);if(!f){let e=`${d}.json`;if(ZI(n,e))return e}if(ZI(n,d)){if($I(n,d).isDirectory()){let e=x.join(d,bL);if(ZI(n,e)){let t=yL(e,``,!0,n);if(t&&ZI(n,t))return t}let t=x.join(d,xL);if(ZI(n,t))return t}else if(f)return d}},`resolveExtendsPath`),CL=$((e,t)=>nL(x.relative(e,t)),`pathRelative`),wL=[`files`,`include`,`exclude`],TL=$((e,t,n)=>{let r=x.join(t,n);return YI(x.relative(e,r))||`./`},`resolveAndRelativize`),EL=$((e,t,n)=>{let r=x.relative(e,t);return r?YI(`${r}/${n.startsWith(`./`)?n.slice(2):n}`):n},`prefixPattern`),DL=$((e,t,n,r)=>{let i=SL(e,t,r);if(!i)throw Error(`File '${e}' not found.`);if(n.has(i))throw Error(`Circularity detected while resolving configuration: ${i}`);n.add(i);let a=x.dirname(i),o=kL(i,r,n);delete o.references;let{compilerOptions:s}=o;if(s){let{baseUrl:e}=s;e&&!e.startsWith(_L)&&(s.baseUrl=TL(t,a,e));let{outDir:n}=s;n&&!n.startsWith(_L)&&(s.outDir=TL(t,a,n))}for(let e of wL){let n=o[e];n&&(o[e]=n.map(e=>e.startsWith(_L)?e:EL(t,a,e)))}return o},`resolveExtends`),OL=[`outDir`,`declarationDir`],kL=$((e,t,n=new Set)=>{let r;try{r=hL(e,t)||{}}catch{throw Error(`Cannot resolve tsconfig at path: ${e}`)}if(typeof r!=`object`)throw SyntaxError(`Failed to parse tsconfig at: ${e}`);let i=x.dirname(e);if(r.compilerOptions){let{compilerOptions:e}=r;e.paths&&!e.baseUrl&&(e[gL]=i)}if(r.extends){let e=Array.isArray(r.extends)?r.extends:[r.extends];delete r.extends;for(let a of e.reverse()){let e=DL(a,i,new Set(n),t),o={...e,...r,compilerOptions:{...e.compilerOptions,...r.compilerOptions}};e.watchOptions&&(o.watchOptions={...e.watchOptions,...r.watchOptions}),r=o}}if(r.compilerOptions){let{compilerOptions:e}=r;for(let t of[`baseUrl`,`rootDir`]){let n=e[t];n&&!n.startsWith(_L)&&(e[t]=CL(i,x.resolve(i,n)))}for(let t of OL){let n=e[t];n&&(Array.isArray(r.exclude)||(r.exclude=[]),r.exclude.includes(n)||r.exclude.push(n),n.startsWith(_L)||(n=nL(n)),e[t]=n)}}else r.compilerOptions={};if(r.include?(r.include=r.include.map(YI),r.files&&delete r.files):r.files&&=r.files.map(e=>e.startsWith(_L)?e:nL(e)),r.watchOptions){let{watchOptions:e}=r;e.excludeDirectories&&=e.excludeDirectories.map(e=>YI(x.resolve(i,e)))}return r},`_parseTsconfig`),AL=$((e,t)=>{if(e.startsWith(_L))return YI(x.join(t,e.slice(12)))},`interpolateConfigDir`),jL=[`outDir`,`declarationDir`,`outFile`,`rootDir`,`baseUrl`,`tsBuildInfoFile`],ML=$(e=>{if(e.strict)for(let t of[`noImplicitAny`,`noImplicitThis`,`strictNullChecks`,`strictFunctionTypes`,`strictBindCallApply`,`strictPropertyInitialization`,`strictBuiltinIteratorReturn`,`alwaysStrict`,`useUnknownInCatchVariables`])e[t]===void 0&&(e[t]=!0);if(e.target){let t=e.target.toLowerCase();t===`es2015`&&(t=`es6`),e.target=t,t===`esnext`&&(e.module??=`es6`,e.useDefineForClassFields??=!0),(t===`es6`||t===`es2016`||t===`es2017`||t===`es2018`||t===`es2019`||t===`es2020`||t===`es2021`||t===`es2022`||t===`es2023`||t===`es2024`)&&(e.module??=`es6`),(t===`es2022`||t===`es2023`||t===`es2024`)&&(e.useDefineForClassFields??=!0)}if(e.module){let t=e.module.toLowerCase();t===`es2015`&&(t=`es6`),e.module=t,(t===`es6`||t===`es2020`||t===`es2022`||t===`esnext`||t===`none`||t===`system`||t===`umd`||t===`amd`)&&(e.moduleResolution??=`classic`),t===`system`&&(e.allowSyntheticDefaultImports??=!0),(t===`node16`||t===`nodenext`||t===`preserve`)&&(e.esModuleInterop??=!0,e.allowSyntheticDefaultImports??=!0),(t===`node16`||t===`nodenext`)&&(e.moduleDetection??=`force`,e.useDefineForClassFields??=!0),t===`node16`&&(e.target??=`es2022`,e.moduleResolution??=`node16`),t===`nodenext`&&(e.target??=`esnext`,e.moduleResolution??=`nodenext`),t===`preserve`&&(e.moduleResolution??=`bundler`)}if(e.moduleResolution){let t=e.moduleResolution.toLowerCase();t===`node`&&(t=`node10`),e.moduleResolution=t,(t===`node16`||t===`nodenext`||t===`bundler`)&&(e.resolvePackageJsonExports??=!0,e.resolvePackageJsonImports??=!0),t===`bundler`&&(e.allowSyntheticDefaultImports??=!0,e.resolveJsonModule??=!0)}e.esModuleInterop&&(e.allowSyntheticDefaultImports??=!0),e.verbatimModuleSyntax&&(e.isolatedModules??=!0,e.preserveConstEnums??=!0),e.isolatedModules&&(e.preserveConstEnums??=!0),e.rewriteRelativeImportExtensions&&(e.allowImportingTsExtensions??=!0)},`normalizeCompilerOptions`),NL=$((e,t=new Map)=>{let n=x.resolve(e),r=kL(n,t),i=x.dirname(n),{compilerOptions:a}=r;if(a){for(let e of jL){let t=a[e];if(t){let n=AL(t,i);a[e]=n?CL(i,n):t}}for(let e of[`rootDirs`,`typeRoots`]){let t=a[e];t&&(a[e]=t.map(e=>{let t=AL(e,i);return t?CL(i,t):e}))}let{paths:e}=a;if(e)for(let t of Object.keys(e))e[t]=e[t].map(e=>AL(e,i)??e);ML(a)}for(let e of wL){let t=r[e];t&&(r[e]=t.map(e=>AL(e,i)??e))}return r},`parseTsconfig`),PL=$((e=process.cwd(),t=`tsconfig.json`,n=new Map)=>{let r=eL(YI(e),t,n);return r?{path:r,config:NL(r,n)}:null},`getTsconfig`),FL=/\*/g,IL=$((e,t)=>{let n=e.match(FL);if(n&&n.length>1)throw Error(t)},`assertStarCount`),LL=$(e=>{if(e.includes(`*`)){let[t,n]=e.split(`*`);return{prefix:t,suffix:n}}return e},`parsePattern`),RL=$(({prefix:e,suffix:t},n)=>n.startsWith(e)&&n.endsWith(t),`isPatternMatch`),zL=$((e,t,n)=>Object.entries(e).map(([e,r])=>(IL(e,`Pattern '${e}' can have at most one '*' character.`),{pattern:LL(e),substitutions:r.map(r=>{if(IL(r,`Substitution '${r}' in pattern '${e}' can have at most one '*' character.`),!t&&!tL.test(r))throw Error(`Non-relative paths are not allowed when 'baseUrl' is not set. Did you forget a leading './'?`);return x.resolve(n,r)})})),`parsePaths`);$(e=>{let{compilerOptions:t}=e.config;if(!t)return null;let{baseUrl:n,paths:r}=t;if(!n&&!r)return null;let i=gL in t&&t[gL],a=x.resolve(x.dirname(e.path),n||i||`.`),o=r?zL(r,n,a):[];return e=>{if(tL.test(e))return[];let t=[];for(let n of o){if(n.pattern===e)return n.substitutions.map(YI);typeof n.pattern!=`string`&&t.push(n)}let r,i=-1;for(let n of t)RL(n.pattern,e)&&n.pattern.prefix.length>i&&(i=n.pattern.prefix.length,r=n);if(!r)return n?[YI(x.join(a,e))]:[];let s=e.slice(r.pattern.prefix.length,e.length-r.pattern.suffix.length);return r.substitutions.map(e=>YI(e.replace(`*`,s)))}},`createPathsMatcher`);var BL=Object.defineProperty,VL=$((e,t)=>BL(e,`name`,{value:t,configurable:!0}),`s`);const HL=VL(e=>{let t=``;for(let n=0;n<e.length;n+=1){let r=e[n],i=r.toUpperCase();t+=r===i?r.toLowerCase():i}return t},`invertCase`),UL=new Map,WL=VL((e,t)=>{let n=de.join(e,`.is-fs-case-sensitive-test-${process.pid}`);try{return t.writeFileSync(n,``),!t.existsSync(HL(n))}finally{try{t.unlinkSync(n)}catch{}}},`checkDirectoryCaseWithWrite`),GL=VL((e,t,n)=>{try{return WL(e,n)}catch(e){if(t===void 0)return WL(S.tmpdir(),n);throw e}},`checkDirectoryCaseWithFallback`),KL=VL((e,t=ue,n=!0)=>{let r=e??process.cwd();if(n&&UL.has(r))return UL.get(r);let i,a=HL(r);return i=a!==r&&t.existsSync(r)?!t.existsSync(a):GL(r,e,t),n&&UL.set(r,i),i},`isFsCaseSensitive`),{join:qL}=x.posix,JL={ts:[`.ts`,`.tsx`,`.d.ts`],cts:[`.cts`,`.d.cts`],mts:[`.mts`,`.d.mts`]},YL=$(e=>{let t=[...JL.ts],n=[...JL.cts],r=[...JL.mts];return e!=null&&e.allowJs&&(t.push(`.js`,`.jsx`),n.push(`.cjs`),r.push(`.mjs`)),[...t,...n,...r]},`getSupportedExtensions`),XL=$(e=>{let t=[];if(!e)return t;let{outDir:n,declarationDir:r}=e;return n&&t.push(n),r&&t.push(r),t},`getDefaultExcludeSpec`),ZL=$(e=>e.replaceAll(/[.*+?^${}()|[\]\\]/g,String.raw`\$&`),`escapeForRegexp`),QL=`(?!(${[`node_modules`,`bower_components`,`jspm_packages`].join(`|`)})(/|$))`,$L=/(?:^|\/)[^.*?]+$/,eR=`**/*`,tR=`[^/]`,nR=`[^./]`,rR=process.platform===`win32`;$(({config:e,path:t},n=KL())=>{if(`extends`in e)throw Error(`tsconfig#extends must be resolved. Use getTsconfig or parseTsconfig to resolve it.`);if(!x.isAbsolute(t))throw Error(`The tsconfig path must be absolute`);rR&&(t=YI(t));let r=x.dirname(t),{files:i,include:a,exclude:o,compilerOptions:s}=e,c=$(e=>x.isAbsolute(e)?e:qL(r,e),`resolvePattern`),l=i?.map(c),u=YL(s),d=n?``:`i`,f=(o||XL(s)).map(e=>{let t=ZL(c(e)).replaceAll(String.raw`\*\*/`,`(.+/)?`).replaceAll(String.raw`\*`,`${tR}*`).replaceAll(String.raw`\?`,tR);return RegExp(`^${t}($|/)`,d)}),p=i||a?a:[eR],m=p?p.map(e=>{let t=c(e);$L.test(t)&&(t=qL(t,eR));let n=ZL(t).replaceAll(String.raw`/\*\*`,`(/${QL}${nR}${tR}*)*?`).replaceAll(/(\/)?\\\*/g,(e,t)=>{let n=`(${nR}|(\\.(?!min\\.js$))?)*`;return t?`/${QL}${nR}${n}`:n}).replaceAll(/(\/)?\\\?/g,(e,t)=>{let n=tR;return t?`/${QL}${n}`:n});return RegExp(`^${n}$`,d)}):void 0;return t=>{if(!x.isAbsolute(t))throw Error(`filePath must be absolute`);if(rR&&(t=YI(t)),l!=null&&l.includes(t)||!(!u.some(e=>t.endsWith(e))||f.some(e=>e.test(t)))&&m&&m.some(e=>e.test(t)))return e}},`createFilesMatcher`);var iR=ae(import.meta.url);function aR({tsconfig:e,cwd:t=ce.cwd(),resolveNodeModules:n=!1,ResolverFactory:r}={}){r||=iR(`oxc-resolver`).ResolverFactory;let i=new r({mainFields:[`types`,`typings`,`module`,`main`],conditionNames:[`types`,`typings`,`import`,`require`],extensions:[`.d.ts`,`.d.mts`,`.d.cts`,`.ts`,`.mts`,`.cts`,`.tsx`,`.js`,`.mjs`,`.cjs`,`.jsx`],extensionAlias:{".js":[`.d.ts`,`.ts`,`.tsx`,`.js`,`.jsx`],".jsx":[`.d.ts`,`.ts`,`.tsx`,`.jsx`,`.js`],".mjs":[`.d.mts`,`.mts`,`.mjs`],".cjs":[`.d.cts`,`.cts`,`.cjs`],".ts":[`.d.ts`,`.ts`,`.tsx`,`.js`,`.jsx`],".tsx":[`.d.ts`,`.tsx`,`.ts`,`.js`,`.jsx`],".mts":[`.d.mts`,`.mts`,`.mjs`],".cts":[`.d.cts`,`.cts`,`.cjs`]},modules:n?[`node_modules`,`node_modules/@types`]:[],tsconfig:e?{configFile:e,references:`auto`}:void 0});return(e,n)=>{let r=n?oe(n):t,a=i.sync(r,e);if(!a.path)return null;let o=a.path;return sR(o)}}const oR=new Set([`.js`,`.cjs`,`.mjs`,`.jsx`,`.ts`,`.cts`,`.mts`,`.tsx`,`.json`,`.vue`,`.svelte`,`.astro`]);function sR(e){return e&&oR.has(se(e))?e.replaceAll(`\\`,`/`):null}const{fork:cR,spawn:lR}=globalThis.process.getBuiltinModule(`node:child_process`),{existsSync:uR}=globalThis.process.getBuiltinModule(`node:fs`),{mkdtemp:dR,readFile:fR,rm:pR}=globalThis.process.getBuiltinModule(`node:fs/promises`),mR=globalThis.process.getBuiltinModule(`node:path`),{tmpdir:hR}=globalThis.process.getBuiltinModule(`node:os`),gR=globalThis.process;function _R({sideEffects:e}){return{name:`rolldown-plugin-dts:dts-input`,options:e===!1?e=>({treeshake:e.treeshake===!1?!1:{...e.treeshake===!0?{}:e.treeshake,moduleSideEffects:!1},...e}):void 0,outputOptions(e){return{...e,entryFileNames(t){let{entryFileNames:n}=e;if(n){let e=ne(n,t),r=v(e,t.name);if(g.test(r))return e;let i=v(e,`${t.name}.d`);if(g.test(i))return i}return g.test(t.name)?t.name:t.name.endsWith(`.d`)?`[name].ts`:`[name].d.ts`}}}}}function vR({sourcemap:e,cjsDefault:t,sideEffects:n}){let r=0,i=Object.create(null),o=new Map,s=new Map,l=new Map;return{name:`rolldown-plugin-dts:fake-js`,outputOptions(t){if(t.format===`cjs`||t.format===`commonjs`)throw Error("[rolldown-plugin-dts] Cannot bundle dts files with `cjs` format.");let{chunkFileNames:n,entryFileNames:r}=t;return{...t,sourcemap:t.sourcemap||e,chunkFileNames(e){let t=ne(e.isEntry?r||`[name].js`:n||`[name]-[hash].js`,e);if(e.name.endsWith(`.d`)){let n=c(v(t,e.name.slice(0,-2)));if(g.test(n))return n;let r=c(v(t,e.name));if(g.test(r))return r}return t}}},transform:{filter:{id:g},handler:u},renderChunk:d,generateBundle(t,n){for(let t of Object.values(n))if(a.test(t.fileName))if(e){if(t.type===`chunk`||typeof t.source!=`string`)continue;let e=JSON.parse(t.source);e.sourcesContent=void 0,t.source=JSON.stringify(e)}else delete n[t.fileName]}};function u(t,r){let i=pI(t,{plugins:[[`typescript`,{dts:!0}]],sourceType:`module`,errorRecovery:!0,createParenthesizedExpressions:!0}),{program:a,comments:o}=i,c=[];if(o){let e=SR(o);s.set(r,e)}let u=[],d=new Map;for(let[e,n]of a.body.entries()){let i=t=>a.body[e]=t;if(FR(n,i,c))continue;let o=n.type===`TSModuleDeclaration`&&n.kind!==`namespace`;if(o&&n.id.type===`StringLiteral`&&n.id.value[0]===`.`&&this.warn(`\`declare module ${JSON.stringify(n.id.value)}\` will be kept as-is in the output. Relative module declaration may cause unexpected issues. Found in ${r}.`),o&&r.endsWith(`.vue.d.ts`)&&t.slice(n.start,n.end).includes(`__VLS_`))continue;let s=n.type===`ExportDefaultDeclaration`,l=SI(n,[`ExportNamedDeclaration`,`ExportDefaultDeclaration`])&&!!n.declaration,m=l?n.declaration:n,g=l?e=>n.declaration=e:i;if(m.type!==`TSDeclareFunction`&&!EI(m))continue;SI(m,[`TSEnumDeclaration`,`ClassDeclaration`,`FunctionDeclaration`,`TSDeclareFunction`,`TSModuleDeclaration`,`VariableDeclaration`])&&(m.declare=!0);let _=[];if(m.type===`VariableDeclaration`)_.push(...m.declarations.map(e=>e.id));else if(`id`in m&&m.id){let e=m.id;if(e.type===`TSQualifiedName`&&(e=kR(e)),e=o?H(`_${f(``)}`):e,e.type!==`Identifier`)throw Error(`Unexpected ${e.type} declaration id`);_.push(e)}else{let e=H(`export_default`);_.push(e),m.id=e}let v=h(m),te=new Set,ne=ee(m,d,te),y=Array.from(te).filter(e=>_.every(t=>e!==t));m!==n&&(m.leadingComments=n.leadingComments);let b=Ul(p({decl:m,deps:ne,bindings:_,params:v,children:y})),re=_u(v.map(({name:e})=>H(e)),yl(ne)),ie=yl(y.map(e=>({type:`StringLiteral`,value:``,start:e.start,end:e.end,loc:e.loc}))),ae=o&&Dl(H(`sideEffect`),[_[0]]),x=ER([b,re,ie,...ae?[ae]:[]]),oe={type:`VariableDeclaration`,kind:`var`,declarations:[{type:`VariableDeclarator`,id:{..._[0],typeAnnotation:null},init:x},..._.slice(1).map(e=>({type:`VariableDeclarator`,id:{...e,typeAnnotation:null}}))]};s?(u.push(Cu(null,[wu(_[0],H(`default`))])),i(oe)):g(oe)}n&&u.push(Pl(Dl(H(`sideEffect`),[]))),a.body=[...Array.from(d.values()).map(({stmt:e})=>e),...a.body,...u],l.set(r,c);let m=uN(i,{comments:!1,sourceMaps:e,sourceFileName:r});return{code:m.code,map:m.map}}function d(n,r){if(!g.test(r.fileName))return;let i=[];for(let e of r.moduleIds){let t=l.get(e);t&&i.push(...t)}let a=pI(n,{sourceType:`module`}),{program:o}=a;if(o.body=NR(o.body),o.body=PR(o.body),o.body=o.body.map(e=>{if(jR(e)||e.type===`ExpressionStatement`)return null;let n=MR(e,i,t);if(n||n===!1)return n;if(e.type!==`VariableDeclaration`)return e;if(!CR(e))return null;let[r,a,o]=e.declarations[0].init.elements,s=r.value,c=m(s);NI(c.decl,{enter(e){e.type!==`CommentBlock`&&delete e.loc}});for(let[t,n]of e.declarations.entries()){let e={...n.id,typeAnnotation:c.bindings[t].typeAnnotation};IR(c.bindings[t],e)}for(let[e,t]of o.elements.entries())Object.assign(c.children[e],{loc:t.loc});let l=a.params;for(let[e,t]of l.entries()){let n=t.name;for(let t of c.params[e].typeParams)t.name=n}let u=a.body.elements;for(let[e,t]of c.deps.entries()){let n=u[e];n.type===`UnaryExpression`&&n.operator===`void`&&(n={...H(`undefined`),loc:n.loc,start:n.start,end:n.end}),t.replace?t.replace(n):Object.assign(t,n)}return LR(e,c.decl)}).filter(e=>!!e),o.body.length===0)return`export { };`;let c=new Set,u=new Set;for(let e of r.moduleIds){let t=s.get(e);t&&(t.forEach(e=>{let t=e.type+e.value;u.has(t)||(u.add(t),c.add(e))}),s.delete(e))}c.size&&(o.body[0].leadingComments||=[],o.body[0].leadingComments.unshift(...c));let d=uN(a,{sourceMaps:e,sourceFileName:r.fileName});return{code:d.code,map:d.map}}function f(e){return e in i?i[e]++:i[e]=0}function p(e){let t=r++;return o.set(t,e),t}function m(e){return o.get(e)}function h(e){let t=[];NI(e,{leave(e){`typeParameters`in e&&e.typeParameters?.type===`TSTypeParameterDeclaration`&&t.push(...e.typeParameters.params.map(({name:e})=>typeof e==`string`?H(e):e))}});let n=new Map;for(let e of t){let t=e.name,r=n.get(t);r?r.push(e):n.set(t,[e])}return Array.from(n.entries()).map(([e,t])=>({name:e,typeParams:t}))}function ee(e,t,n){let r=new Set,i=new Set,a=[],o=new Set;function s(e){return e.type===`Identifier`&&o.has(e.name)}return NI(e,{enter(e){if(e.type===`TSConditionalType`){let t=bR(e.extendsType);a.push(t)}},leave(e,s){if(e.type===`TSConditionalType`)a.pop();else if(s?.type===`TSConditionalType`){let t=s.trueType===e;o=new Set((t?a:a.slice(0,-1)).flat())}else o=new Set;if(e.type===`ExportNamedDeclaration`)for(let t of e.specifiers)t.type===`ExportSpecifier`&&c(t.local);else if(e.type===`TSInterfaceDeclaration`&&e.extends)for(let t of e.extends||[])c(t.expression);else if(e.type===`ClassDeclaration`){if(e.superClass&&c(e.superClass),e.implements)for(let t of e.implements){if(t.type===`ClassImplements`)throw Error(`Unexpected Flow syntax`);c(t.expression)}}else if(SI(e,[`ObjectMethod`,`ObjectProperty`,`ClassProperty`,`TSPropertySignature`,`TSDeclareMethod`]))e.computed&&AR(e.key)&&c(e.key),`value`in e&&AR(e.value)&&c(e.value);else switch(e.type){case`TSTypeReference`:c(OR(e.typeName));break;case`TSTypeQuery`:if(i.has(e.exprName))return;if(e.exprName.type===`TSImportType`)break;c(OR(e.exprName));break;case`TSImportType`:{i.add(e);let{source:n,qualifier:r}=e;c(_(e,r,n,t));break}}s&&!r.has(e)&&yR(e,s)&&n.add(e)}}),Array.from(r);function c(e){DR(e)||s(e)||r.add(e)}}function _(e,t,n,r){let i=n.value.replaceAll(/\W/g,`_`),a=H(`${i}${f(i)}`);if(r.has(n.value)?a=r.get(n.value).local:r.set(n.value,{stmt:Eu([Ou(a)],n),local:a}),t){let e=kR(t);if(t.type===`ThisExpression`||e.type===`ThisExpression`)throw Error("Cannot import `this` from module.");IR(e,zf(a,{...e})),a=t}let o=e;return e.typeArguments?(IR(e,sp(a,e.typeArguments)),o=a):IR(e,a),{...OR(a),replace(e){IR(o,e)}}}}function yR(e,t){return!!(e.type===`Identifier`||SI(t,[`TSPropertySignature`,`TSMethodSignature`])&&t.key===e)}function bR(e){let t=[];return NI(e,{enter(e){e.type===`TSInferType`&&e.typeParameter&&t.push(e.typeParameter.name.name)}}),t}const xR=/\/\s*<reference\s+(?:path|types)=/;function SR(e,t=!1){return e.filter(e=>xR.test(e.value)!==t)}function CR(e){return e?.type===`VariableDeclaration`&&e.declarations.length>0&&e.declarations[0].type===`VariableDeclarator`&&wR(e.declarations[0].init)}function wR(e){return e?.type===`ArrayExpression`&&TR(e.elements)}function TR(e){let[t,n,r,i]=e;return t?.type===`NumericLiteral`&&n?.type===`ArrowFunctionExpression`&&r?.type===`ArrayExpression`&&(!i||i.type===`CallExpression`)}function ER(e){return yl(e)}function DR(e){return CI(e,`this`)||e.type===`ThisExpression`||e.type===`MemberExpression`&&DR(e.object)}function OR(e){if(e.type===`Identifier`||e.type===`ThisExpression`)return e;let t=OR(e.left);return Object.assign(e,Jl(t,e.right))}function kR(e){return e.type===`Identifier`||e.type===`ThisExpression`?e:kR(e.left)}function AR(e){return SI(e,[`Identifier`,`MemberExpression`])}function jR(e){return e.type===`ImportDeclaration`&&e.specifiers.length===1&&e.specifiers.every(e=>e.type===`ImportSpecifier`&&e.imported.type===`Identifier`&&[`__exportAll`,`__reExport`].includes(e.local.name))}function MR(e,t,n){if(e.type===`ExportNamedDeclaration`&&!e.declaration&&!e.source&&!e.specifiers.length&&!e.attributes?.length)return!1;if(SI(e,[`ImportDeclaration`,`ExportAllDeclaration`,`ExportNamedDeclaration`])){if(e.type===`ExportNamedDeclaration`&&t.length)for(let n of e.specifiers){let r=AI(n.exported);t.includes(r)&&(n.type===`ExportSpecifier`?n.exportKind=`type`:e.exportKind=`type`)}if(e.source?.value&&g.test(e.source.value))return e.source.value=l(e.source.value,`js`),e;if(n&&e.type===`ExportNamedDeclaration`&&!e.source&&e.specifiers.length===1&&e.specifiers[0].type===`ExportSpecifier`&&AI(e.specifiers[0].exported)===`default`)return{type:`TSExportAssignment`,expression:e.specifiers[0].local}}}function NR(e){let t=new Set;for(let[t,r]of e.entries()){let i=n(r);if(!i)continue;let[a,o]=i;e[t]={type:`TSModuleDeclaration`,id:a,kind:`namespace`,declare:!0,body:{type:`TSModuleBlock`,body:[{type:`ExportNamedDeclaration`,specifiers:o.properties.filter(e=>e.type===`ObjectProperty`).map(e=>{let t=e.value.body,n=e.key;return wu(t,n)}),source:null,declaration:null}]}}}return e.filter(e=>!t.has(e));function n(e){return e.type!==`VariableDeclaration`||e.declarations.length!==1||e.declarations[0].id.type!==`Identifier`||e.declarations[0].init?.type!==`CallExpression`||e.declarations[0].init.callee.type!==`Identifier`||e.declarations[0].init.callee.name!==`__exportAll`||e.declarations[0].init.arguments.length!==1||e.declarations[0].init.arguments[0].type!==`ObjectExpression`?!1:[e.declarations[0].id,e.declarations[0].init.arguments[0]]}}function PR(e){let t=new Map;for(let[n,r]of e.entries())if(r.type===`ImportDeclaration`&&r.specifiers.length===1&&r.specifiers[0].type===`ImportSpecifier`&&r.specifiers[0].local.type===`Identifier`&&r.specifiers[0].local.name.endsWith(`_exports`))t.set(r.specifiers[0].local.name,r.specifiers[0].local.name);else if(r.type===`ExpressionStatement`&&r.expression.type===`CallExpression`&&CI(r.expression.callee,`__reExport`)){let e=r.expression.arguments;t.set(e[0].name,e[1].name)}else r.type===`VariableDeclaration`&&r.declarations.length===1&&r.declarations[0].init?.type===`MemberExpression`&&r.declarations[0].init.object.type===`Identifier`&&t.has(r.declarations[0].init.object.name)?e[n]={type:`TSTypeAliasDeclaration`,id:{type:`Identifier`,name:r.declarations[0].id.name},typeAnnotation:{type:`TSTypeReference`,typeName:{type:`TSQualifiedName`,left:{type:`Identifier`,name:t.get(r.declarations[0].init.object.name)},right:{type:`Identifier`,name:r.declarations[0].init.property.name}}}}:r.type===`ExportNamedDeclaration`&&r.specifiers.length===1&&r.specifiers[0].type===`ExportSpecifier`&&r.specifiers[0].local.type===`Identifier`&&t.has(r.specifiers[0].local.name)&&(r.specifiers[0].local.name=t.get(r.specifiers[0].local.name));return e}function FR(e,t,n){if(e.type===`ImportDeclaration`||e.type===`ExportNamedDeclaration`&&!e.declaration){for(let t of e.specifiers)(`exportKind`in t&&t.exportKind===`type`||`exportKind`in e&&e.exportKind===`type`)&&n.push(AI(t.exported)),t.type===`ImportSpecifier`?t.importKind=`value`:t.type===`ExportSpecifier`&&(t.exportKind=`value`);return e.type===`ImportDeclaration`?e.importKind=`value`:e.type===`ExportNamedDeclaration`&&(e.exportKind=`value`),!0}else if(e.type===`ExportAllDeclaration`)return e.exportKind=`value`,!0;else if(e.type===`TSImportEqualsDeclaration`)return e.moduleReference.type===`TSExternalModuleReference`&&t({type:`ImportDeclaration`,specifiers:[{type:`ImportDefaultSpecifier`,local:e.id}],source:e.moduleReference.expression}),!0;else if(e.type===`TSExportAssignment`&&e.expression.type===`Identifier`)return t({type:`ExportNamedDeclaration`,specifiers:[{type:`ExportSpecifier`,local:e.expression,exported:{type:`Identifier`,name:`default`}}]}),!0;else if(e.type===`ExportDefaultDeclaration`&&e.declaration.type===`Identifier`)return t({type:`ExportNamedDeclaration`,specifiers:[{type:`ExportSpecifier`,local:e.declaration,exported:H(`default`)}]}),!0;return!1}function IR(e,t){for(let t of Object.keys(e))delete e[t];return Object.assign(e,t),e}function LR(e,t){t.leadingComments||=[];let n=e.leadingComments?.filter(e=>e.value.startsWith(`#`));return n&&t.leadingComments.unshift(...n),t.leadingComments=SR(t.leadingComments,!0),t}const RR=i(`rolldown-plugin-dts:tsgo`),zR=(...e)=>new Promise((t,n)=>{let r=lR(...e);r.on(`close`,()=>t()),r.on(`error`,e=>n(e))});async function BR(){let e=import.meta.resolve(`@typescript/native-preview/package.json`),{default:t}=await import(new URL(`lib/getExePath.js`,e).href);return t()}async function VR(e,t,n,r){RR(`[tsgo] rootDir`,e);let i;r?(i=r,RR(`[tsgo] using custom path`,i)):(i=await BR(),RR(`[tsgo] using tsgo from node_modules`,i));let a=await dR(mR.join(hR(),`rolldown-plugin-dts-`));RR(`[tsgo] tsgoDist`,a);let o=[`--noEmit`,`false`,`--declaration`,`--emitDeclarationOnly`,...t?[`-p`,t]:[],`--outDir`,a,`--rootDir`,e,`--noCheck`,...n?[`--declarationMap`]:[]];return RR(`[tsgo] args %o`,o),await zR(i,o,{stdio:`inherit`}),a}const HR=i(`rolldown-plugin-dts:generate`);function UR({tsconfig:e,tsconfigRaw:t,build:r,incremental:i,cwd:c,oxc:l,emitDtsOnly:u,vue:m,tsMacro:ee,parallel:te,eager:ie,tsgo:ae,newContext:x,emitJs:oe,sourcemap:se}){let ce=new Map,le=new Map,ue,de,S,fe,pe,me=e?mR.dirname(e):c;return{name:`rolldown-plugin-dts:generate`,async buildStart(t){if(ae?pe=await VR(me,e,se,ae.path):l||(te?(ue=cR(new URL(`./tsc-worker.mjs`,import.meta.url),{stdio:`inherit`}),de=(await import(`./dist-DHF5Otz1.js`)).createBirpc({},{post:e=>ue.send(e),on:e=>ue.on(`message`,e)})):(S=await import(`./tsc-BoybAFN3.js`),x&&(fe=re()))),!Array.isArray(t.input))for(let[e,n]of Object.entries(t.input)){HR(`resolving input alias %s -> %s`,e,n);let t=await this.resolve(n);n.startsWith(`./`)||(t||=await this.resolve(`./${n}`));let r=t?.id||n;HR(`resolved input alias %s -> %s`,n,r),le.set(r,e)}},outputOptions(e){return{...e,entryFileNames(t){let{entryFileNames:n}=e,r=ne(n||`[name].js`,t);if(t.name.endsWith(`.d`)){if(g.test(r))return v(r,t.name.slice(0,-2));if(d.test(r))return r.replace(d,`.$1ts`)}return r}}},resolveId(e){if(ce.has(e))return HR(`resolve dts id %s`,e),{id:e}},transform:{order:`pre`,filter:{id:{include:[d,h,f,_],exclude:[g,o,s]}},handler(e,t){if(!d.test(t)||oe){let r=!!this.getModuleInfo(t)?.isEntry,i=n(t);if(ce.set(i,{code:e,id:t,isEntry:r}),HR(`register dts source: %s`,t),r){let e=le.get(t);this.emitFile({type:`chunk`,id:i,name:e?`${e}.d`:void 0})}}if(u)return _.test(t)?`{}`:`export { }`}},load:{filter:{id:{include:[g],exclude:[o]}},async handler(a){if(!ce.has(a))return;let{code:o,id:s}=ce.get(a),u,d;if(HR(`generate dts %s from %s`,a,s),ae){if(f.test(s))throw Error(`tsgo does not support Vue files.`);let e=mR.resolve(pe,mR.relative(mR.resolve(me),n(s)));if(!uR(e))throw HR(`[tsgo]`,e,`is missing`),Error(`tsgo did not generate dts file for ${s}, please check your tsconfig.`);u=await fR(e,`utf8`);let t=`${e}.map`;if(uR(t)){let e=await fR(t,`utf8`);d={...JSON.parse(e),sources:[s]}}}else if(l&&!f.test(s)){let e=p(s,o,l);if(e.errors.length){let[t]=e.errors;return this.error({message:t.message,frame:t.codeframe||void 0})}u=e.code,e.map&&(d=e.map,d.sourcesContent=void 0)}else{let n={tsconfig:e,tsconfigRaw:t,build:r,incremental:i,cwd:c,entries:ie?void 0:Array.from(ce.values()).filter(e=>e.isEntry).map(e=>e.id),id:s,sourcemap:se,vue:m,tsMacro:ee,context:fe},a;if(a=te?await de.tscEmit(n):S.tscEmit(n),a.error)return this.error(a.error);if(u=a.code,d=a.map,u&&_.test(s))if(u.includes(`declare const _exports`)){if(u.includes(`declare const _exports: {`)&&!u.includes(`
|
|
22
|
+
}[];`)){let e=GR(u),t=0;u+=e.map(e=>{let n=`_${e.replaceAll(/[^\w$]/g,`_`)}${t++}`,r=JSON.stringify(e);return`declare let ${n}: typeof _exports[${r}]\nexport { ${n} as ${r} }`}).join(`
|
|
23
|
+
`)}}else{let e=WR(u);u+=`
|
|
24
|
+
declare namespace __json_default_export {
|
|
25
|
+
export { ${Array.from(e.entries()).map(([e,t])=>e===t?e:`${t} as ${e}`).join(`, `)} }
|
|
26
|
+
}
|
|
27
|
+
export { __json_default_export as default }`}}return{code:u||``,map:d}}},generateBundle:u?(e,t)=>{for(let e of Object.keys(t))t[e].type===`chunk`&&!g.test(e)&&!a.test(e)&&delete t[e]}:void 0,async buildEnd(){ue?.kill(),!HR.enabled&&pe&&await pR(pe,{recursive:!0,force:!0}).catch(()=>{}),pe=void 0,x&&(fe=void 0)},watchChange(e){S&&b(fe||y,e)}}}function WR(e){let t=new Map,{program:n}=pI(e,{sourceType:`module`,plugins:[[`typescript`,{dts:!0}]],errorRecovery:!0});for(let e of n.body)if(e.type===`ExportNamedDeclaration`){if(e.declaration)if(e.declaration.type===`VariableDeclaration`)for(let n of e.declaration.declarations)n.id.type===`Identifier`&&t.set(n.id.name,n.id.name);else e.declaration.type===`TSModuleDeclaration`&&e.declaration.id.type===`Identifier`&&t.set(e.declaration.id.name,e.declaration.id.name);else if(e.specifiers.length)for(let n of e.specifiers)n.type===`ExportSpecifier`&&n.exported.type===`Identifier`&&t.set(n.exported.name,n.local.type===`Identifier`?n.local.name:n.exported.name)}return t}function GR(e){let t=[],{program:n}=pI(e,{sourceType:`module`,plugins:[[`typescript`,{dts:!0}]]}),r=n.body[0].declarations[0].id.typeAnnotation.typeAnnotation.members;for(let e of r)e.key.type===`Identifier`?t.push(e.key.name):e.key.type===`StringLiteral`&&t.push(e.key.value);return t}let KR=!1;function qR({cwd:e=gR.cwd(),dtsInput:t=!1,emitDtsOnly:n=!1,tsconfig:r,tsconfigRaw:i={},compilerOptions:a={},sourcemap:o,resolver:s=`oxc`,cjsDefault:c=!1,sideEffects:l=!1,build:u=!1,incremental:d=!1,vue:f=!1,tsMacro:p=!1,parallel:m=!1,eager:h=!1,newContext:g=!1,emitJs:ee,oxc:_,tsgo:v=!1}){v===!0?v={}:typeof v==`object`&&v.enabled===!1&&(v=!1);let te;if(r===!0||r==null){let{config:t,path:n}=PL(e)||{};r=n,te=t}else typeof r==`string`?(r=mR.resolve(e||gR.cwd(),r),te=NL(r)):r=void 0;a={...te?.compilerOptions,...a},d||=a.incremental||!!a.tsBuildInfoFile,o??=!!a.declarationMap,a.declarationMap=o;let ne={...te,...i,compilerOptions:a};if(_??=!!(a?.isolatedDeclarations&&!f&&!v&&!p),_===!0&&(_={}),_&&(_.stripInternal??=!!a?.stripInternal,_.sourcemap=!!a.declarationMap),ee??=!!(a.checkJs||a.allowJs),v){if(f)throw Error("[rolldown-plugin-dts] The `tsgo` option is not compatible with the `vue` option. Please disable one of them.");if(p)throw Error("[rolldown-plugin-dts] The `tsgo` option is not compatible with the `tsMacro` option. Please disable one of them.");if(_)throw Error("[rolldown-plugin-dts] The `tsgo` option is not compatible with the `oxc` option. Please disable one of them.")}if(_&&f)throw Error("[rolldown-plugin-dts] The `oxc` option is not compatible with the `vue` option. Please disable one of them.");if(_&&p)throw Error("[rolldown-plugin-dts] The `oxc` option is not compatible with the `tsMacro` option. Please disable one of them.");return v&&!KR&&(console.warn("The `tsgo` option is experimental and may change in the future."),KR=!0),{cwd:e,dtsInput:t,emitDtsOnly:n,tsconfig:r,tsconfigRaw:ne,sourcemap:o,resolver:s,cjsDefault:c,sideEffects:l,build:u,incremental:d,vue:f,tsMacro:p,parallel:m,eager:h,newContext:g,emitJs:ee,oxc:_,tsgo:v}}const JR=i(`rolldown-plugin-dts:resolver`);function YR(e){return h.test(e)||f.test(e)||_.test(e)}function XR({cwd:e,tsconfig:t,tsconfigRaw:i,resolver:a,sideEffects:o}){let s=aR({tsconfig:t,resolveNodeModules:!0,ResolverFactory:ee}),c=o?!0:null;return{name:`rolldown-plugin-dts:resolver`,resolveId:{order:`pre`,filter:[r(u(g))],async handler(e,t,r){if(!t)return;let i={id:e,external:!0,moduleSideEffects:o},a=await this.resolve(e,t,r);if(JR(`Rolldown resolution for dts import %O from %O: %O`,e,t,a),a?.external)return JR(`Rolldown marked dts import as external:`,e),i;let s=await l(e,t,a);if(JR(`Dts resolution for dts import %O from %O: %O`,e,t,s),!s)return m.test(e)?(JR(`Externalizing css import:`,e),i):(JR(`Unresolvable dts import:`,e,`from`,t),ZR(e)?null:i);if(g.test(s))return JR(`Resolving dts import to declaration file:`,e),{id:s,moduleSideEffects:c};if(YR(s))return JR(`Resolving dts import to source file:`,e),await this.load({id:s}),{id:n(s),moduleSideEffects:c}}}};async function l(n,r,o){let c;if(a===`tsc`){let{tscResolve:a}=await import(`./resolver-o20sdYK5-Dnq-MmKm.js`);c=a(n,r,e,t,i)}else c=s(n,r);return JR(`Using %s for dts import: %O -> %O`,a,n,c),c&&=mR.normalize(c),!c||!YR(c)?o&&ZR(o.id)&&YR(o.id)&&!o.external?o.id:null:c}}function ZR(e){return e.startsWith(`.`)||mR.isAbsolute(e)}const QR=i(`rolldown-plugin-dts:options`);function $R(e={}){QR(`resolving dts options`);let t=qR(e);QR(`resolved dts options %o`,t);let n=[];return e.dtsInput?n.push(_R(t)):n.push(UR(t)),n.push(XR(t),vR(t)),n}export{$R as dts};
|