-
-
Notifications
You must be signed in to change notification settings - Fork 970
/
Copy pathriot+compiler.min.js
1 lines (1 loc) · 339 KB
/
riot+compiler.min.js
1
var e,t;e=this,t=function(e){"use strict";function t(e,t){return typeof e===t}function n(e){const t=e.ownerSVGElement;return!!t||null===t}function r(e){return"template"===e.tagName.toLowerCase()}function i(e){return t(e,"function")}function a(e){return!s(e)&&e.constructor===Object}function s(e){return null==e}function o(){return void 0!==globalThis.process}const l=0,c=1,u=2,p=3,h=4,d={ATTRIBUTE:0,EVENT:c,TEXT:2,VALUE:3,REF:h};function f(e){return e.replace(/-(\w)/g,((e,t)=>t.toUpperCase()))}function m(e,t){throw Error(e,{cause:t})}function y(e){const t=new Map,n=n=>(t.has(n)||t.set(n,e.call(this,n)))&&t.get(n);return n.cache=t,n}function g(e){return e.reduce(((e,t)=>{const{value:n,type:r}=t;switch(!0){case!t.name&&0===r:return{...e,...n};case 3===r:e.value=t.value;break;default:e[f(t.name)]=t.value}return e}),{})}const b=0,v=1,x=2,S=3,E=4,T={EACH:0,IF:1,SIMPLE:2,TAG:3,SLOT:4},_=new Map,k=Symbol(),P=new Set,w="is",A="mount",C="update",I="unmount",N="shouldUpdate",O="onBeforeMount",D="onMounted",L="onBeforeUpdate",j="onUpdated",M="onBeforeUnmount",B="onUnmounted",F="props",V="state",R="slots",q="root",U=Symbol(),z=Symbol(),W=Symbol(),G=Symbol(),J=Symbol();function $(e){return Array.from(e.attributes).reduce(((e,t)=>(e[f(t.name)]=t.value,e)),{})}function H(e){for(;e.firstChild;)e.removeChild(e.firstChild)}const K=e=>e.remove(),X=(e,t)=>t&&t.parentNode&&t.parentNode.insertBefore(e,t);function Y(){return this}function Q(e){return i(e)?e.prototype&&e.prototype.constructor?new e:e():e}function Z(e,t,n,r={}){return Object.defineProperty(e,t,{value:n,enumerable:!1,writable:!1,configurable:!0,...r}),e}function ee(e,t,n){return Object.entries(t).forEach((([t,r])=>{Z(e,t,r,n)})),e}function te(e,t){return Object.entries(t).forEach((([t,n])=>{e[t]||(e[t]=n)})),e}const ne="exports",re="template",ie="riot",ae="RiotComponentWrapper",se="RiotComponent",oe="javascript",le="css",ce="template",ue="script",pe="style",he="textarea",de="isRaw",fe="isSelfClosing",me="isVoid",ye="isBoolean",ge="isCustom",be="isSpread";var ve=Object.freeze({__proto__:null,CSS_OUTPUT_NAME:"css",IS_BOOLEAN:ye,IS_CUSTOM:ge,IS_RAW:de,IS_SELF_CLOSING:fe,IS_SPREAD:be,IS_VOID:me,JAVASCRIPT_OUTPUT_NAME:oe,JAVASCRIPT_TAG:ue,STYLE_TAG:pe,TEMPLATE_OUTPUT_NAME:ce,TEXTAREA_TAG:he}),xe=Object.freeze({__proto__:null,ATTR:2,CDATA:4,COMMENT:8,DOCTYPE:10,DOCUMENT:9,DOCUMENT_FRAGMENT:11,TAG:1,TEXT:3});const Se=/^(?:\/[a-zA-Z]|[a-zA-Z][^\s>/]?)/,Ee=/(\/?[^\s>/]+)\s*(>)?/g,Te=/(\S[^>/=\s]*)(?:\s*=\s*([^>/])?)?/g,_e=/\.\.\./,ke={script:/<\/script\s*>/gi,style:/<\/style\s*>/gi,textarea:/<\/textarea\s*>/gi},Pe=/^\/?(?:pre|textarea)$/;function we(e,t,n){return e.lastIndex=t,e.exec(n)}var Ae=e=>e.replace(/(?=[-[\](){^*+?.$|\\])/g,"\\");function Ce(e,t,n){const r=/[`$\\]/g;let i;for(;r.lastIndex=t,r.exec(e);){if(i=e[(t=r.lastIndex)-1],"`"===i)return t;if("$"===i&&"{"===e[t++])return n.push("`","}"),t}throw function(e,t,n){n||(n=e.length);const r=(e.slice(0,n).match(/\r\n?|\n/g)||"").length+1;let i=0;for(;--n>=0&&!/[\r\n]/.test(e[n]);)++i;return`[${r},${i}]: Unclosed ES6 template literal.`}(e,0,t)}const Ie="[{(,;:?=|&!^~>%*/",Ne=Ie+"+-",Oe=["case","default","do","else","in","instanceof","prefix","return","typeof","void","yield"],De=Oe.reduce(((e,t)=>e+t.slice(-1)),""),Le=/^\/(?=[^*>/])[^[/\\]*(?:(?:\\.|\[(?:\\.|[^\]\\]*)*\])[^[\\/]*)*?\/[gimuy]*/,je=/[$\w]/,Me=/.*/g;function Be(e,t){for(;--t>=0&&/\s/.test(e[t]););return t}const Fe=/'[^'\n\r\\]*(?:\\(?:\r\n?|[\S\s])[^'\n\r\\]*)*'/.source,Ve=`${Fe}|${Fe.replace(/'/g,'"')}`,Re={};function qe(e,t,n,r){let i=0;switch(t){case"[":case"(":case"{":e.push("["===t?"]":"("===t?")":"}");break;case")":case"]":case"}":e.pop(),"}"===t&&"`"===e[e.length-1]&&(t=e.pop()),i=n+1;break;case"/":i=function(e,t){let n=Me.lastIndex=t++;const r=(Me.exec(e)||" ")[0].match(Le);if(r){const i=n+r[0].length;n=Be(e,n);let a=e[n];if(n<0||Ie.includes(a))return i;if("."===a)"."===e[n-1]&&(t=i);else{if(("+"===a||"-"===a)&&(e[--n]!==a||(n=Be(e,n))<0||Ne.includes(a=e[n])))return i;if(De.includes(a)){const r=n+1;for(;--n>=0&&je.test(e[n]););Oe.includes(e.slice(n+1,r))&&(t=i)}}}return t}(r,n)}return{char:t,index:i}}function Ue(e,t,n){const[r,i]=n,a=t+r.length,s=[],o=function(e){let t=Re[e];if(!t){let n=Ae(e);e.length>1?n+="|[":n=/[{}[\]()]/.test(e)?"[":"["+n,Re[e]=t=RegExp(`${Ve}|${n}\`/\\{}[\\]()]`,"g")}return t}(i);let l,c;for(o.lastIndex=a;c=o.exec(e);){const n=c.index,r=c[0];if(l=o.lastIndex,r===i&&!s.length)return{text:e.slice(a,n),start:t,end:l};const{char:u,index:p}=qe(s,r[0],n,e);l=p||l,o.lastIndex="`"===u?Ce(e,l,s):l}}function ze(e){const t=e.last;e.last=null,t&&e.root&&e.builder.push(t)}function We(e,t,n){return e.slice(t,n)}function Ge(e,t,n,r={}){const i=We(e.data,t,n),a=r.expressions,s=r.unescape;let o=e.last;return e.pos=n,o&&3===o.type?(o.text+=i,o.end=n):(ze(e),e.last=o={type:3,text:i,start:t,end:n}),a&&a.length&&(o.expressions=(o.expressions||[]).concat(a)),s&&(o.unescape=s),3}function Je(e,t,n,r){const i=function(e,t){const{brackets:n}=e.options,r=e.regexCache[t];if(r)return r;const i=Ae(n[0]);return Object.assign(e.regexCache,{[t]:RegExp(`(${t})|${i}`,"g")}),e.regexCache[t]}(e,n);i.lastIndex=r;const{unescape:a,expressions:s,end:o}=function(e,t){const{data:n,options:r}=e,{brackets:i}=r,a=[];let s,o,l;for(;(l=t.exec(n))&&!l[1];)if(o=l.index,"\\"===n[o-1])s=l[0];else{const e=Ue(n,o,i);e&&(a.push(e),t.lastIndex=e.end)}return{unescape:s,expressions:a,end:l.index}}(e,i);return t?(a&&(t.unescape=a),s.length&&(t.expressions=s)):Ge(e,r,o,{expressions:s,unescape:a}),o}const $e=e=>e.filter(((e,t,n)=>n.indexOf(e)===t)),He=["circle","ellipse","line","path","polygon","polyline","rect","stop","use"],Ke=["button","data","input","select","li","meter","option","output","progress","textarea","param"],Xe=$e(["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","animation","audio","canvas","clipPath","color-profile","cursor","defs","desc","discard","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignObject","g","glyph","glyphRef","handler","hatch","hatchpath","hkern","iframe","image","linearGradient","listener","marker","mask","mesh","meshgradient","meshpatch","meshrow","metadata","missing-glyph","mpath","pattern","prefetch","radialGradient","script","set","solidColor","solidcolor","style","svg","switch","symbol","tbreak","text","textArea","textPath","title","tref","tspan","unknown","video","view","vkern"].concat(He)).sort(),Ye=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"];function Qe(e){return e.join("|")}function Ze(...e){return RegExp(`^/?(?:${Qe(e.map(Qe))})$`,"i")}const et=Ze($e(["a","abbr","address","article","aside","audio","b","bdi","bdo","blockquote","body","canvas","caption","cite","code","colgroup","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","html","i","iframe","ins","kbd","label","legend","main","map","mark","math","menu","nav","noscript","object","ol","optgroup","p","picture","pre","q","rb","rp","rt","rtc","ruby","s","samp","script","section","select","slot","small","span","strong","style","sub","summary","sup","svg","table","tbody","td","template","tfoot","th","thead","time","title","tr","u","ul","var","video"].concat(Ye).concat(Ke)).sort()),tt=Ze(Xe),nt=Ze(Ye),rt=Ze(He);Ze(Ke);const it=Ze(["disabled","visible","checked","readonly","required","allowfullscreen","autofocus","autoplay","compact","controls","default","formnovalidate","hidden","ismap","itemscope","loop","multiple","muted","noresize","noshade","novalidate","nowrap","open","reversed","seamless","selected","sortable","truespeed","typemustmatch"]),at=function(){const e=new WeakMap;return(...t)=>{if(e.has(t[0]))return e.get(t[0]);const n=(e=>RegExp(`(${e[0]}[^${e[1]}]*?${e[1]})`,"g"))(...t);return e.set(t[0],n),n}}(),st=(e,t)=>Je(e,t,"[>/\\s]",t.start);function ot(e,...t){return(...n)=>(n=[...t,...n]).length<e.length?ot(e,...n):e(...n)}function lt(e,t,n,r){const i=e.root,a={type:1,name:t,start:n,end:r};var s;s=t,[et,tt].every((e=>!e.test(s)))&&(a[ge]=!0),function(e){return[nt,rt].some((t=>t.test(e)))}(t)&&(a[me]=!0),e.pos=r,i?(t===i.name?e.count++:t===i.close&&e.count--,ze(e)):(e.root={name:a.name,close:"/"+t},e.count=1),e.last=a}function ct(e){return e.replace(/\r/g,"\\r").replace(/\n/g,"\\n")}function ut(e){return e.replace(/\\/g,"\\\\")}const pt=Object.seal({get(){const e=this.store;return{[ce]:e.root.nodes[0],[le]:e[pe],[oe]:e[ue]}},push(e){const t=this.store;switch(e.type){case 8:this.pushComment(t,e);break;case 3:this.pushText(t,e);break;case 1:{const n=e.name,r="/",[i]=n;i!==r||e.isVoid?i!==r&&this.openTag(t,e):this.closeTag(t,e,n);break}}},pushComment(e,t){e.last.nodes.push(t)},closeTag(e,t){(e.scryle||e.last).end=t.end,e.root.nodes[0]&&(e.root.nodes[0].end=t.end),e.scryle?e.scryle=null:e.last=e.stack.pop()},openTag(e,t){const n=t.name,r=t.attributes,i=ue===n&&!(e=>(e.attributes||[]).some((e=>"src"===e.name)))(t)||n===pe;if(i)e[n]&&(this.store.data,t.start),e[n]=t,e.scryle=e[n];else{const r=e.last,i=t;r.nodes.push(i),(r[de]||Pe.test(n))&&(t[de]=!0),t[fe]||t[me]||(e.stack.push(r),i.nodes=[],e.last=i)}r&&this.attrs(r)},attrs(e){e.forEach((e=>{e.value&&this.split(e,e.value,e.valueStart,!0)}))},pushText(e,t){const n=t.text,r=e.scryle;if(r)r.text=t;else{const r=e.last,i=this.compact&&!r[de];if(i&&!/\S/.test(n))return;this.split(t,n,t.start,i),r.nodes.push(t)}},split(e,t,n,r){const i=e.expressions,a=[];if(i){let s=0;i.forEach((i=>{const o=t.slice(s,i.start-n),l=i.text;a.push(this.sanitise(e,o,r),ct(ut(l).trim())),s=i.end-n})),s<e.end&&a.push(this.sanitise(e,t.slice(s),r))}else a[0]=this.sanitise(e,t,r);e.parts=a.filter((e=>e))},sanitise(e,t,n){let r=e.unescape;if(r){let e=0;for(r="\\"+r;-1!==(e=t.indexOf(r,e));)t=t.substr(0,e)+t.substr(e+1),e++}return t=ut(t),n?t.replace(/\s+/g," "):ct(t)}});function ht(e,t){const n={type:1,name:"",start:0,end:0,nodes:[]};return Object.assign(Object.create(pt),{compact:!1!==t.compact,store:{last:n,stack:[],scryle:null,root:n,style:null,script:null,data:e}})}function dt(e,t){const n=ot(ft)(e,ht);return{parse:e=>function(e){const{data:t}=e;return mt(e),ze(e),e.count&&(e.count,e.pos),{data:t,output:e.builder.get()}}(n(e))}}function ft(e,t,n){const r=Object.assign({brackets:["{","}"],compact:!0,comments:!1},e);return{options:r,regexCache:{},pos:0,count:-1,root:null,last:null,scryle:null,builder:t(n,r),data:n}}function mt(e,t){const{data:n}=e,r=n.length;e.pos<r&&e.count&&mt(e,function(e,t){switch(t){case 1:return function(e){const{pos:t,data:n}=e,r=t-1,i=n.substr(t,2);switch(!0){case"!"===i[0]:return function(e,t,n){const r=n+2,i="--"===t.substr(r,2)?"--\x3e":">",a=t.indexOf(i,r);return function(e,t,n,r){e.pos=n,!0===e.options.comments&&(ze(e),e.last={type:8,start:t,end:n,text:r})}(e,n,a+i.length,t.substring(n,a+i.length)),3}(e,n,r);case Se.test(i):return function(e,t){const{data:n,pos:r}=e,i=Ee,a=we(i,r,n),s=i.lastIndex,o=a[1].toLowerCase();return o in ke&&(e.scryle=o),lt(e,o,t,s),a[2]?3:2}(e,r);default:return Ge(e,r,t)}}(e);case 2:return function(e){const{data:t,last:n,pos:r,root:i}=e,a=n,s=/\S/g,o=we(s,r,t);switch(!0){case!o:e.pos=t.length;break;case">"===o[0]:return e.pos=a.end=s.lastIndex,a[fe]&&(e.scryle=null,i&&i.name===a.name&&e.count--),3;case"/"===o[0]:e.pos=s.lastIndex,a[fe]=!0;break;default:delete a[fe],function(e,t,n){const{data:r}=e,i=at(e.options.brackets),a=Te,s=a.lastIndex=i.lastIndex=t,o=a.exec(r),l=(u=o[1],p=e.options.brackets,u[0]===p[0]),c=l?[null,i.exec(r)[1],null]:o;var u,p;if(c){const t=function(e,t,n,r,i){const a={name:t[1],value:"",start:n,end:r},s=t[2];switch(!0){case(e=>_e.test(e))(a.name):return function(e,t){const n=st(e,t);return{[be]:!0,start:t.start,expressions:t.expressions.map((e=>Object.assign(e,{text:e.text.replace(_e,"").trim()}))),end:n}}(e,a);case!0===i:return function(e,t){const n=st(e,t);return{start:t.start,name:t.expressions[0].text.trim(),expressions:t.expressions,end:n}}(e,a);default:return function(e,t,n){const{data:r}=e;let{end:i}=t;var a;if(a=t.name,it.test(a)&&(t[ye]=!0),n){let a=i;return'"'!==n&&"'"!==n&&(n="",a--),i=Je(e,t,n||"[>/\\s]",a),Object.assign(t,{value:We(r,a,i),valueStart:a,end:n?++i:i})}return t}(e,a,s)}}(e,c,s,a.lastIndex,l);e.pos=n.end=t.end,n.attributes=function(e=[],t){return e.push(t),e}(n.attributes,t)}}(e,o.index,a)}return 2}(e);default:return function(e){const{pos:t,data:n,scryle:r}=e;switch(!0){case"string"==typeof r:{const i=r,a=ke[i],s=we(a,t,n),o=s.index,l=a.lastIndex;e.scryle=null,o>t?function(e,t,n){const{pos:r}=e,i=n.index;t===he?Je(e,null,n[0],r):Ge(e,r,i)}(e,i,s):i!==he&&(e.last.text={type:3,text:"",start:t,end:t}),lt(e,"/"+i,o,l);break}case"<"===n[t]:return e.pos++,1;default:Je(e,null,"<",t)}return 3}(e)}}(e,t))}const yt=ve,gt=xe,bt="bindingTypes",vt="expressionTypes",xt="template",St="getComponent",Et="template",Tt="type",_t="evaluate",kt="name",Pt="attributes",wt="if",At="each",Ct="key",It="slot",Nt="name",Ot="is";yt.IS_RAW;const Dt=yt.IS_VOID,Lt=yt.IS_CUSTOM,jt=yt.IS_BOOLEAN,Mt=yt.IS_SPREAD;function Bt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Ft(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if("function"==typeof t){var n=function e(){return this instanceof e?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach((function(t){var r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,r.get?r:{enumerable:!0,get:function(){return e[t]}})})),n}var Vt={},Rt=function(e,t){return Rt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},Rt(e,t)};function qt(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+t+" is not a constructor or null");function n(){this.constructor=e}Rt(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var Ut=function(){return Ut=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},Ut.apply(this,arguments)};function zt(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n}function Wt(e,t,n,r){var i,a=arguments.length,s=a<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var o=e.length-1;o>=0;o--)(i=e[o])&&(s=(a<3?i(s):a>3?i(t,n,s):i(t,n))||s);return a>3&&s&&Object.defineProperty(t,n,s),s}function Gt(e,t){return function(n,r){t(n,r,e)}}function Jt(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)}function $t(e,t,n,r){return new(n||(n=Promise))((function(i,a){function s(e){try{l(r.next(e))}catch(e){a(e)}}function o(e){try{l(r.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,o)}l((r=r.apply(e,t||[])).next())}))}function Ht(e,t){var n,r,i,a,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return a={next:o(0),throw:o(1),return:o(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function o(o){return function(l){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,o[0]&&(s=0)),s;)try{if(n=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,r=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!((i=(i=s.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){s=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){s.label=o[1];break}if(6===o[0]&&s.label<i[1]){s.label=i[1],i=o;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(o);break}i[2]&&s.ops.pop(),s.trys.pop();continue}o=t.call(e,s)}catch(e){o=[6,e],r=0}finally{n=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,l])}}}var Kt=Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]};function Xt(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||Kt(t,e,n)}function Yt(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Qt(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,a=n.call(e),s=[];try{for(;(void 0===t||t-- >0)&&!(r=a.next()).done;)s.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=a.return)&&n.call(a)}finally{if(i)throw i.error}}return s}function Zt(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(Qt(arguments[t]));return e}function en(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),i=0;for(t=0;t<n;t++)for(var a=arguments[t],s=0,o=a.length;s<o;s++,i++)r[i]=a[s];return r}function tn(e,t,n){if(n||2===arguments.length)for(var r,i=0,a=t.length;i<a;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}function nn(e){return this instanceof nn?(this.v=e,this):new nn(e)}function rn(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r,i=n.apply(e,t||[]),a=[];return r={},s("next"),s("throw"),s("return"),r[Symbol.asyncIterator]=function(){return this},r;function s(e){i[e]&&(r[e]=function(t){return new Promise((function(n,r){a.push([e,t,n,r])>1||o(e,t)}))})}function o(e,t){try{(n=i[e](t)).value instanceof nn?Promise.resolve(n.value.v).then(l,c):u(a[0][2],n)}catch(e){u(a[0][3],e)}var n}function l(e){o("next",e)}function c(e){o("throw",e)}function u(e,t){e(t),a.shift(),a.length&&o(a[0][0],a[0][1])}}function an(e){var t,n;return t={},r("next"),r("throw",(function(e){throw e})),r("return"),t[Symbol.iterator]=function(){return this},t;function r(r,i){t[r]=e[r]?function(t){return(n=!n)?{value:nn(e[r](t)),done:!1}:i?i(t):t}:i}}function sn(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,n=e[Symbol.asyncIterator];return n?n.call(e):(e=Yt(e),t={},r("next"),r("throw"),r("return"),t[Symbol.asyncIterator]=function(){return this},t);function r(n){t[n]=e[n]&&function(t){return new Promise((function(r,i){!function(e,t,n,r){Promise.resolve(r).then((function(t){e({value:t,done:n})}),t)}(r,i,(t=e[n](t)).done,t.value)}))}}}function on(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var ln=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t};function cn(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&Kt(t,e,n);return ln(t,e),t}function un(e){return e&&e.__esModule?e:{default:e}}function pn(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)}function hn(e,t,n,r,i){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!i)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?i.call(e,n):i?i.value=n:t.set(e,n),n}function dn(e,t){if(null===t||"object"!=typeof t&&"function"!=typeof t)throw new TypeError("Cannot use 'in' operator on non-object");return"function"==typeof e?t===e:e.has(t)}function fn(e,t,n){if(null!=t){if("object"!=typeof t&&"function"!=typeof t)throw new TypeError("Object expected.");var r;if(n){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(void 0===r){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if("function"!=typeof r)throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:n})}else n&&e.stack.push({async:!0});return t}var mn="function"==typeof SuppressedError?SuppressedError:function(e,t,n){var r=Error(n);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};function yn(e){function t(t){e.error=e.hasError?new mn(t,e.error,"An error was suppressed during disposal."):t,e.hasError=!0}return function n(){for(;e.stack.length;){var r=e.stack.pop();try{var i=r.dispose&&r.dispose.call(r.value);if(r.async)return Promise.resolve(i).then(n,(function(e){return t(e),n()}))}catch(e){t(e)}}if(e.hasError)throw e.error}()}var gn,bn,vn={__extends:qt,__assign:Ut,__rest:zt,__decorate:Wt,__param:Gt,__metadata:Jt,__awaiter:$t,__generator:Ht,__createBinding:Kt,__exportStar:Xt,__values:Yt,__read:Qt,__spread:Zt,__spreadArrays:en,__spreadArray:tn,__await:nn,__asyncGenerator:rn,__asyncDelegator:an,__asyncValues:sn,__makeTemplateObject:on,__importStar:cn,__importDefault:un,__classPrivateFieldGet:pn,__classPrivateFieldSet:hn,__classPrivateFieldIn:dn,__addDisposableResource:fn,__disposeResources:yn},xn=Object.freeze({__proto__:null,__addDisposableResource:fn,get __assign(){return Ut},__asyncDelegator:an,__asyncGenerator:rn,__asyncValues:sn,__await:nn,__awaiter:$t,__classPrivateFieldGet:pn,__classPrivateFieldIn:dn,__classPrivateFieldSet:hn,__createBinding:Kt,__decorate:Wt,__disposeResources:yn,__esDecorate:function(e,t,n,r,i,a){function s(e){if(void 0!==e&&"function"!=typeof e)throw new TypeError("Function expected");return e}for(var o,l=r.kind,c="getter"===l?"get":"setter"===l?"set":"value",u=!t&&e?r.static?e:e.prototype:null,p=t||(u?Object.getOwnPropertyDescriptor(u,r.name):{}),h=!1,d=n.length-1;d>=0;d--){var f={};for(var m in r)f[m]="access"===m?{}:r[m];for(var m in r.access)f.access[m]=r.access[m];f.addInitializer=function(e){if(h)throw new TypeError("Cannot add initializers after decoration has completed");a.push(s(e||null))};var y=(0,n[d])("accessor"===l?{get:p.get,set:p.set}:p[c],f);if("accessor"===l){if(void 0===y)continue;if(null===y||"object"!=typeof y)throw new TypeError("Object expected");(o=s(y.get))&&(p.get=o),(o=s(y.set))&&(p.set=o),(o=s(y.init))&&i.unshift(o)}else(o=s(y))&&("field"===l?i.unshift(o):p[c]=o)}u&&Object.defineProperty(u,r.name,p),h=!0},__exportStar:Xt,__extends:qt,__generator:Ht,__importDefault:un,__importStar:cn,__makeTemplateObject:on,__metadata:Jt,__param:Gt,__propKey:function(e){return"symbol"==typeof e?e:"".concat(e)},__read:Qt,__rest:zt,__runInitializers:function(e,t,n){for(var r=arguments.length>2,i=0;i<t.length;i++)n=r?t[i].call(e,n):t[i].call(e);return r?n:void 0},__setFunctionName:function(e,t,n){return"symbol"==typeof t&&(t=t.description?"[".concat(t.description,"]"):""),Object.defineProperty(e,"name",{configurable:!0,value:n?"".concat(n," ",t):t})},__spread:Zt,__spreadArray:tn,__spreadArrays:en,__values:Yt,default:vn}),Sn=Ft(xn),En={},Tn={exports:{}},_n={exports:{}},kn={};function Pn(){if(gn)return kn;gn=1,Object.defineProperty(kn,"__esModule",{value:!0}),kn.maybeSetModuleExports=void 0;var e=Sn.__importDefault(wn());return kn.default=function(t){var n=t.use(e.default),r=n.Type,i=n.builtInTypes,a=i.number,s=r.or(i.string,i.number,i.boolean,i.null,i.undefined);return{geq:function(e){return r.from((function(t){return a.check(t)&&t>=e}),a+" >= "+e)},defaults:{null:function(){return null},emptyArray:function(){return[]},false:function(){return!1},true:function(){return!0},undefined:function(){},"use strict":function(){return"use strict"}},isPrimitive:r.from((function(e){if(null===e)return!0;var t=typeof e;return"object"!==t&&"function"!==t}),s.toString())}},kn.maybeSetModuleExports=function(e){try{var t=e(),n=t.exports,r=n.default}catch(e){return}r&&r!==n&&"object"==typeof n&&(Object.assign(r,n,{default:r}),n.__esModule&&Object.defineProperty(r,"__esModule",{value:!0}),t.exports=r)},kn}function wn(){return bn||(bn=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Def=void 0;var n=Sn,r=Pn(),i=Object.prototype,a=i.toString,s=i.hasOwnProperty,o=function(){function e(){}return e.prototype.assert=function(e,t){if(!this.check(e,t)){var n=m(e);throw Error(n+" does not match type "+this)}return!0},e.prototype.arrayOf=function(){return new l(this)},e}(),l=function(e){function t(t){var n=e.call(this)||this;return n.elemType=t,n.kind="ArrayType",n}return n.__extends(t,e),t.prototype.toString=function(){return"["+this.elemType+"]"},t.prototype.check=function(e,t){var n=this;return Array.isArray(e)&&e.every((function(e){return n.elemType.check(e,t)}))},t}(o),c=function(e){function t(t){var n=e.call(this)||this;return n.value=t,n.kind="IdentityType",n}return n.__extends(t,e),t.prototype.toString=function(){return this.value+""},t.prototype.check=function(e,t){var n=e===this.value;return n||"function"!=typeof t||t(this,e),n},t}(o),u=function(e){function t(t){var n=e.call(this)||this;return n.fields=t,n.kind="ObjectType",n}return n.__extends(t,e),t.prototype.toString=function(){return"{ "+this.fields.join(", ")+" }"},t.prototype.check=function(e,t){return a.call(e)===a.call({})&&this.fields.every((function(n){return n.type.check(e[n.name],t)}))},t}(o),p=function(e){function t(t){var n=e.call(this)||this;return n.types=t,n.kind="OrType",n}return n.__extends(t,e),t.prototype.toString=function(){return this.types.join(" | ")},t.prototype.check=function(e,t){return!!this.types.some((function(n){return n.check(e,!!t)}))||("function"==typeof t&&t(this,e),!1)},t}(o),h=function(e){function t(t,n){var r=e.call(this)||this;return r.name=t,r.predicate=n,r.kind="PredicateType",r}return n.__extends(t,e),t.prototype.toString=function(){return this.name},t.prototype.check=function(e,t){var n=this.predicate(e,t);return n||"function"!=typeof t||t(this,e),n},t}(o),d=function(){function e(e,t){this.type=e,this.typeName=t,this.baseNames=[],this.ownFields=Object.create(null),this.allSupertypes=Object.create(null),this.supertypeList=[],this.allFields=Object.create(null),this.fieldNames=[],this.finalized=!1,this.buildable=!1,this.buildParams=[]}return e.prototype.isSupertypeOf=function(t){if(t instanceof e){if(!0!==this.finalized||!0!==t.finalized)throw Error("");return s.call(t.allSupertypes,this.typeName)}throw Error(t+" is not a Def")},e.prototype.checkAllFields=function(e,t){var n=this.allFields;if(!0!==this.finalized)throw Error(""+this.typeName);return null!==e&&"object"==typeof e&&Object.keys(n).every((function(r){var i=n[r],a=i.type,s=i.getValue(e);return a.check(s,t)}))},e.prototype.bases=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=this.baseNames;if(this.finalized){if(e.length!==n.length)throw Error("");for(var r=0;r<e.length;r++)if(e[r]!==n[r])throw Error("");return this}return e.forEach((function(e){n.indexOf(e)<0&&n.push(e)})),this},e}();t.Def=d;var f=function(){function e(e,t,n,r){this.name=e,this.type=t,this.defaultFn=n,this.hidden=!!r}return e.prototype.toString=function(){return JSON.stringify(this.name)+": "+this.type},e.prototype.getValue=function(e){var t=e[this.name];return void 0!==t||"function"==typeof this.defaultFn&&(t=this.defaultFn.call(e)),t},e}();function m(e){return Array.isArray(e)?"["+e.map(m).join(", ")+"]":e&&"object"==typeof e?"{ "+Object.keys(e).map((function(t){return t+": "+e[t]})).join(", ")+" }":JSON.stringify(e)}t.default=function(e){var t={or:function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return new p(e.map((function(e){return t.from(e)})))},from:function(e,n){if(e instanceof l||e instanceof c||e instanceof u||e instanceof p||e instanceof h)return e;if(e instanceof d)return e.type;if(b.check(e)){if(1!==e.length)throw Error("only one element type is permitted for typed arrays");return new l(t.from(e[0]))}if(v.check(e))return new u(Object.keys(e).map((function(n){return new f(n,t.from(e[n],n))})));if("function"==typeof e){var a=r.indexOf(e);if(a>=0)return i[a];if("string"!=typeof n)throw Error("missing name");return new h(n,e)}return new c(e)},def:function(e){return s.call(A,e)?A[e]:A[e]=new I(e)},hasDef:function(e){return s.call(A,e)}},r=[],i=[];function o(e,t){var n=a.call(t),s=new h(e,(function(e){return a.call(e)===n}));return t&&"function"==typeof t.constructor&&(r.push(t.constructor),i.push(s)),s}var y=o("string","truthy"),g=o("function",(function(){})),b=o("array",[]),v=o("object",{}),x=o("RegExp",/./),S=o("Date",new Date),E=o("number",3),T=o("boolean",!0),_=o("null",null),k=o("undefined",void 0),P="function"==typeof BigInt?o("BigInt",BigInt(1234)):new h("BigInt",(function(){return!1})),w={string:y,function:g,array:b,object:v,RegExp:x,Date:S,number:E,boolean:T,null:_,undefined:k,BigInt:P},A=Object.create(null);function C(e){if(e&&"object"==typeof e){var t=e.type;if("string"==typeof t&&s.call(A,t)){var n=A[t];if(n.finalized)return n}}return null}var I=function(e){function r(t){var n=e.call(this,new h(t,(function(e,t){return n.check(e,t)})),t)||this;return n}return n.__extends(r,e),r.prototype.check=function(e,t){if(!0!==this.finalized)throw Error("prematurely checking unfinalized type "+this.typeName);if(null===e||"object"!=typeof e)return!1;var n=C(e);return n?t&&n===this?this.checkAllFields(e,t):!!this.isSupertypeOf(n)&&(!t||n.checkAllFields(e,t)&&this.checkAllFields(e,!1)):("SourceLocation"===this.typeName||"Position"===this.typeName)&&this.checkAllFields(e,t)},r.prototype.build=function(){for(var e=this,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];if(this.buildParams=t,this.buildable)return this;this.field("type",String,(function(){return e.typeName})),this.buildable=!0;var r=function(t,n,r,i){if(!s.call(t,n)){var a=e.allFields;if(!s.call(a,n))throw Error(""+n);var o,l=a[n],c=l.type;if(i)o=r;else{if(!l.defaultFn){var u="no value or default function given for field "+JSON.stringify(n)+" of "+e.typeName+"("+e.buildParams.map((function(e){return a[e]})).join(", ")+")";throw Error(u)}o=l.defaultFn.call(t)}if(!c.check(o))throw Error(m(o)+" does not match field "+l+" of type "+e.typeName);t[n]=o}},i=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var i=t.length;if(!e.finalized)throw Error("attempting to instantiate unfinalized type "+e.typeName);var a=Object.create(O);if(e.buildParams.forEach((function(e,n){n<i?r(a,e,t[n],!0):r(a,e,null,!1)})),Object.keys(e.allFields).forEach((function(e){r(a,e,null,!1)})),a.type!==e.typeName)throw Error("");return a};return i.from=function(t){if(!e.finalized)throw Error("attempting to instantiate unfinalized type "+e.typeName);var n=Object.create(O);if(Object.keys(e.allFields).forEach((function(e){s.call(t,e)?r(n,e,t[e],!0):r(n,e,null,!1)})),n.type!==e.typeName)throw Error("");return n},Object.defineProperty(N,D(this.typeName),{enumerable:!0,value:i}),this},r.prototype.field=function(e,n,r,i){return this.finalized?(console.error("Ignoring attempt to redefine field "+JSON.stringify(e)+" of finalized type "+JSON.stringify(this.typeName)),this):(this.ownFields[e]=new f(e,t.from(n),r,i),this)},r.prototype.finalize=function(){var e=this;if(!this.finalized){var t=this.allFields,n=this.allSupertypes;for(var r in this.baseNames.forEach((function(r){var i=A[r];if(!(i instanceof d)){var a="unknown supertype name "+JSON.stringify(r)+" for subtype "+JSON.stringify(e.typeName);throw Error(a)}i.finalize(),F(t,i.allFields),F(n,i.allSupertypes)})),F(t,this.ownFields),n[this.typeName]=this,this.fieldNames.length=0,t)s.call(t,r)&&!t[r].hidden&&this.fieldNames.push(r);Object.defineProperty(j,this.typeName,{enumerable:!0,value:this.type}),this.finalized=!0,function(e,t){t.length=0,t.push(e);for(var n=Object.create(null),r=0;r<t.length;++r){e=t[r];var i=A[e];if(!0!==i.finalized)throw Error("");s.call(n,e)&&delete t[n[e]],n[e]=r,t.push.apply(t,i.baseNames)}for(var a=0,o=a,l=t.length;o<l;++o)s.call(t,o)&&(t[a++]=t[o]);t.length=a}(this.typeName,this.supertypeList),this.buildable&&this.supertypeList.lastIndexOf("Expression")>=0&&function(e){var t=L(e);if(!N[t]){var n=N[D(e)];if(n){var r=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return N.expressionStatement(n.apply(N,e))};r.from=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return N.expressionStatement(n.from.apply(N,e))},N[t]=r}}}(this.typeName)}},r}(d),N=Object.create(null),O={};function D(e){return e.replace(/^[A-Z]+/,(function(e){var t=e.length;switch(t){case 0:return"";case 1:return e.toLowerCase();default:return e.slice(0,t-1).toLowerCase()+e.charAt(t-1)}}))}function L(e){return(e=D(e)).replace(/(Expression)?$/,"Statement")}var j={};function M(e){var t=C(e);if(t)return t.fieldNames.slice(0);if("type"in e)throw Error("did not recognize object of type "+JSON.stringify(e.type));return Object.keys(e)}function B(e,t){var n=C(e);if(n){var r=n.allFields[t];if(r)return r.getValue(e)}return e&&e[t]}function F(e,t){return Object.keys(t).forEach((function(n){e[n]=t[n]})),e}return{Type:t,builtInTypes:w,getSupertypeNames:function(e){if(!s.call(A,e))throw Error("");var t=A[e];if(!0!==t.finalized)throw Error("");return t.supertypeList.slice(1)},computeSupertypeLookupTable:function(e){for(var t={},n=Object.keys(A),r=n.length,i=0;i<r;++i){var a=n[i],o=A[a];if(!0!==o.finalized)throw Error(""+a);for(var l=0;l<o.supertypeList.length;++l){var c=o.supertypeList[l];if(s.call(e,c)){t[a]=c;break}}}return t},builders:N,defineMethod:function(e,t){var n=O[e];return k.check(t)?delete O[e]:(g.assert(t),Object.defineProperty(O,e,{enumerable:!0,configurable:!0,value:t})),n},getBuilderName:D,getStatementBuilderName:L,namedTypes:j,getFieldNames:M,getFieldValue:B,eachField:function(e,t,n){M(e).forEach((function(n){t.call(this,n,B(e,n))}),n)},someField:function(e,t,n){return M(e).some((function(n){return t.call(this,n,B(e,n))}),n)},finalize:function(){Object.keys(A).forEach((function(e){A[e].finalize()}))}}},(0,r.maybeSetModuleExports)((function(){return e}))}(_n,_n.exports)),_n.exports}var An,Cn={exports:{}},In={exports:{}},Nn={exports:{}};function On(){return An||(An=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=Pn(),i=n.__importDefault(wn()),a=Object.prototype.hasOwnProperty;t.default=function(e){var t=e.use(i.default),n=t.builtInTypes.array,r=t.builtInTypes.number,s=function e(t,n,r){if(!(this instanceof e))throw Error("Path constructor cannot be invoked without 'new'");if(n){if(!(n instanceof e))throw Error("")}else n=null,r=null;this.value=t,this.parentPath=n,this.name=r,this.__childCache=null},o=s.prototype;function l(e){return e.__childCache||(e.__childCache=Object.create(null))}function c(e,t){var n=l(e),r=e.getValueProperty(t),i=n[t];return a.call(n,t)&&i.value===r||(i=n[t]=new e.constructor(r,e,t)),i}function u(){}function p(e,t,i,s){if(n.assert(e.value),0===t)return u;var o=e.value.length;if(o<1)return u;var c=arguments.length;2===c?(i=0,s=o):3===c?(i=Math.max(i,0),s=o):(i=Math.max(i,0),s=Math.min(s,o)),r.assert(i),r.assert(s);for(var p=Object.create(null),h=l(e),d=i;d<s;++d)if(a.call(e.value,d)){var f=e.get(d);if(f.name!==d)throw Error("");var m=d+t;f.name=m,p[m]=f,delete h[d]}return delete h.length,function(){for(var t in p){var n=p[t];if(n.name!==+t)throw Error("");h[t]=n,e.value[t]=n.value}}}return o.getValueProperty=function(e){return this.value[e]},o.get=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=this,r=e.length,i=0;i<r;++i)n=c(n,e[i]);return n},o.each=function(e,t){var n=[],r=this.value.length,i=0;for(i=0;i<r;++i)a.call(this.value,i)&&(n[i]=this.get(i));for(t=t||this,i=0;i<r;++i)a.call(n,i)&&e.call(t,n[i])},o.map=function(e,t){var n=[];return this.each((function(t){n.push(e.call(this,t))}),t),n},o.filter=function(e,t){var n=[];return this.each((function(t){e.call(this,t)&&n.push(t)}),t),n},o.shift=function(){var e=p(this,-1),t=this.value.shift();return e(),t},o.unshift=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=p(this,e.length),r=this.value.unshift.apply(this.value,e);return n(),r},o.push=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return n.assert(this.value),delete l(this).length,this.value.push.apply(this.value,e)},o.pop=function(){n.assert(this.value);var e=l(this);return delete e[this.value.length-1],delete e.length,this.value.pop()},o.insertAt=function(e){var t=arguments.length,n=p(this,t-1,e);if(n===u&&t<=1)return this;e=Math.max(e,0);for(var r=1;r<t;++r)this.value[e+r-1]=arguments[r];return n(),this},o.insertBefore=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=this.parentPath,r=e.length,i=[this.name],a=0;a<r;++a)i.push(e[a]);return n.insertAt.apply(n,i)},o.insertAfter=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=this.parentPath,r=e.length,i=[this.name+1],a=0;a<r;++a)i.push(e[a]);return n.insertAt.apply(n,i)},o.replace=function(e){var t=[],r=this.parentPath.value,i=l(this.parentPath),a=arguments.length;if(function(e){if(!(e instanceof s))throw Error("");var t=e.parentPath;if(!t)return e;var r=t.value,i=l(t);if(r[e.name]===e.value)i[e.name]=e;else if(n.check(r)){var a=r.indexOf(e.value);a>=0&&(i[e.name=a]=e)}else r[e.name]=e.value,i[e.name]=e;if(r[e.name]!==e.value)throw Error("");if(e.parentPath.get(e.name)!==e)throw Error("")}(this),n.check(r)){for(var o=r.length,c=p(this.parentPath,a-1,this.name+1),u=[this.name,1],h=0;h<a;++h)u.push(arguments[h]);if(r.splice.apply(r,u)[0]!==this.value)throw Error("");if(r.length!==o-1+a)throw Error("");if(c(),0===a)delete this.value,delete i[this.name],this.__childCache=null;else{if(r[this.name]!==e)throw Error("");for(this.value!==e&&(this.value=e,this.__childCache=null),h=0;h<a;++h)t.push(this.parentPath.get(this.name+h));if(t[0]!==this)throw Error("")}}else if(1===a)this.value!==e&&(this.__childCache=null),this.value=r[this.name]=e,t.push(this);else{if(0!==a)throw Error("Could not replace path");delete r[this.name],delete this.value,this.__childCache=null}return t},s},(0,r.maybeSetModuleExports)((function(){return e}))}(Nn,Nn.exports)),Nn.exports}var Dn,Ln,jn,Mn={exports:{}};function Bn(){return Ln||(Ln=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(wn()),i=n.__importDefault(On()),a=n.__importDefault((Dn||(Dn=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=Pn(),i=n.__importDefault(wn()),a=Object.prototype.hasOwnProperty;t.default=function(e){var t=e.use(i.default),n=t.Type,r=t.namedTypes,s=r.Node,o=r.Expression,l=t.builtInTypes.array,c=t.builders,u=function e(t,n){if(!(this instanceof e))throw Error("Scope constructor cannot be invoked without 'new'");var r;if(h.check(t.value)||p.assert(t.value),n){if(!(n instanceof e))throw Error("");r=n.depth+1}else n=null,r=0;Object.defineProperties(this,{path:{value:t},node:{value:t.value},isGlobal:{value:!n,enumerable:!0},depth:{value:r},parent:{value:n},bindings:{value:{}},types:{value:{}}})},p=n.or(r.Program,r.Function,r.CatchClause),h=n.or(r.Function,r.ClassDeclaration,r.ClassExpression,r.InterfaceDeclaration,r.TSInterfaceDeclaration,r.TypeAlias,r.TSTypeAliasDeclaration),d=n.or(r.TypeParameter,r.TSTypeParameter);u.isEstablishedBy=function(e){return p.check(e)||h.check(e)};var f=u.prototype;function m(e,n,i){var a=e.value;e.parent&&r.FunctionExpression.check(e.parent.node)&&e.parent.node.id&&g(e.parent.get("id"),n),a&&(l.check(a)?e.each((function(e){y(e,n,i)})):r.Function.check(a)?(e.get("params").each((function(e){g(e,n)})),y(e.get("body"),n,i),m(e.get("typeParameters"),n,i)):r.TypeAlias&&r.TypeAlias.check(a)||r.InterfaceDeclaration&&r.InterfaceDeclaration.check(a)||r.TSTypeAliasDeclaration&&r.TSTypeAliasDeclaration.check(a)||r.TSInterfaceDeclaration&&r.TSInterfaceDeclaration.check(a)?b(e.get("id"),i):r.VariableDeclarator.check(a)?(g(e.get("id"),n),y(e.get("init"),n,i)):"ImportSpecifier"===a.type||"ImportNamespaceSpecifier"===a.type||"ImportDefaultSpecifier"===a.type?g(e.get(a.local?"local":a.name?"name":"id"),n):s.check(a)&&!o.check(a)&&t.eachField(a,(function(t,r){var a=e.get(t);if(!function(e,t){return e.value===t||!(!Array.isArray(e.value)||0!==e.value.length||!Array.isArray(t)||0!==t.length)}(a,r))throw Error("");y(a,n,i)})))}function y(e,t,n){var i=e.value;if(!i||o.check(i));else if(r.FunctionDeclaration.check(i)&&null!==i.id)g(e.get("id"),t);else if(r.ClassDeclaration&&r.ClassDeclaration.check(i)&&null!==i.id)g(e.get("id"),t),m(e.get("typeParameters"),t,n);else if(r.InterfaceDeclaration&&r.InterfaceDeclaration.check(i)||r.TSInterfaceDeclaration&&r.TSInterfaceDeclaration.check(i))b(e.get("id"),n);else if(p.check(i)){if(r.CatchClause.check(i)&&r.Identifier.check(i.param)){var s=i.param.name,l=a.call(t,s);m(e.get("body"),t,n),l||delete t[s]}}else m(e,t,n)}function g(e,t){var n=e.value;r.Pattern.assert(n),r.Identifier.check(n)?a.call(t,n.name)?t[n.name].push(e):t[n.name]=[e]:r.AssignmentPattern&&r.AssignmentPattern.check(n)?g(e.get("left"),t):r.ObjectPattern&&r.ObjectPattern.check(n)?e.get("properties").each((function(e){var n=e.value;r.Pattern.check(n)?g(e,t):r.Property.check(n)||r.ObjectProperty&&r.ObjectProperty.check(n)?g(e.get("value"),t):r.SpreadProperty&&r.SpreadProperty.check(n)&&g(e.get("argument"),t)})):r.ArrayPattern&&r.ArrayPattern.check(n)?e.get("elements").each((function(e){var n=e.value;r.Pattern.check(n)?g(e,t):r.SpreadElement&&r.SpreadElement.check(n)&&g(e.get("argument"),t)})):r.PropertyPattern&&r.PropertyPattern.check(n)?g(e.get("pattern"),t):(r.SpreadElementPattern&&r.SpreadElementPattern.check(n)||r.RestElement&&r.RestElement.check(n)||r.SpreadPropertyPattern&&r.SpreadPropertyPattern.check(n))&&g(e.get("argument"),t)}function b(e,t){var n=e.value;r.Pattern.assert(n),r.Identifier.check(n)&&(a.call(t,n.name)?t[n.name].push(e):t[n.name]=[e])}return f.didScan=!1,f.declares=function(e){return this.scan(),a.call(this.bindings,e)},f.declaresType=function(e){return this.scan(),a.call(this.types,e)},f.declareTemporary=function(e){if(e){if(!/^[a-z$_]/i.test(e))throw Error("")}else e="t$";e+=this.depth.toString(36)+"$",this.scan();for(var n=0;this.declares(e+n);)++n;var r=e+n;return this.bindings[r]=t.builders.identifier(r)},f.injectTemporary=function(e,t){e||(e=this.declareTemporary());var n=this.path.get("body");return r.BlockStatement.check(n.value)&&(n=n.get("body")),n.unshift(c.variableDeclaration("var",[c.variableDeclarator(e,t||null)])),e},f.scan=function(e){if(e||!this.didScan){for(var t in this.bindings)delete this.bindings[t];for(var t in this.types)delete this.types[t];!function(e,t,n){var i=e.value;if(h.check(i)){var s=e.get("typeParameters","params");l.check(s.value)&&s.each((function(e){!function(e,t){var n=e.value;d.assert(n),a.call(t,n.name)?t[n.name].push(e):t[n.name]=[e]}(e,n)}))}p.check(i)&&(r.CatchClause.check(i)?g(e.get("param"),t):m(e,t,n))}(this.path,this.bindings,this.types),this.didScan=!0}},f.getBindings=function(){return this.scan(),this.bindings},f.getTypes=function(){return this.scan(),this.types},f.lookup=function(e){for(var t=this;t&&!t.declares(e);t=t.parent);return t},f.lookupType=function(e){for(var t=this;t&&!t.declaresType(e);t=t.parent);return t},f.getGlobalScope=function(){for(var e=this;!e.isGlobal;)e=e.parent;return e},u},(0,r.maybeSetModuleExports)((function(){return e}))}(Mn,Mn.exports)),Mn.exports)),s=Pn();t.default=function(e){var t=e.use(r.default),n=t.namedTypes,s=t.builders,o=t.builtInTypes.number,l=t.builtInTypes.array,c=e.use(i.default),u=e.use(a.default),p=function e(t,n,r){if(!(this instanceof e))throw Error("NodePath constructor cannot be invoked without 'new'");c.call(this,t,n,r)},h=p.prototype=Object.create(c.prototype,{constructor:{value:p,enumerable:!1,writable:!0,configurable:!0}});function d(e){return n.BinaryExpression.check(e)||n.LogicalExpression.check(e)}Object.defineProperties(h,{node:{get:function(){return Object.defineProperty(this,"node",{configurable:!0,value:this._computeNode()}),this.node}},parent:{get:function(){return Object.defineProperty(this,"parent",{configurable:!0,value:this._computeParent()}),this.parent}},scope:{get:function(){return Object.defineProperty(this,"scope",{configurable:!0,value:this._computeScope()}),this.scope}}}),h.replace=function(){return delete this.node,delete this.parent,delete this.scope,c.prototype.replace.apply(this,arguments)},h.prune=function(){var e=this.parent;return this.replace(),function(e){if(n.VariableDeclaration.check(e.node)){var t=e.get("declarations").value;if(!t||0===t.length)return e.prune()}else if(n.ExpressionStatement.check(e.node)){if(!e.get("expression").value)return e.prune()}else n.IfStatement.check(e.node)&&function(e){var t=e.get("test").value,r=e.get("alternate").value,i=e.get("consequent").value;if(i||r){if(!i&&r){var a=s.unaryExpression("!",t,!0);n.UnaryExpression.check(t)&&"!"===t.operator&&(a=t.argument),e.get("test").replace(a),e.get("consequent").replace(r),e.get("alternate").replace()}}else{var o=s.expressionStatement(t);e.replace(o)}}(e);return e}(e)},h._computeNode=function(){var e=this.value;if(n.Node.check(e))return e;var t=this.parentPath;return t&&t.node||null},h._computeParent=function(){var e=this.value,t=this.parentPath;if(!n.Node.check(e)){for(;t&&!n.Node.check(t.value);)t=t.parentPath;t&&(t=t.parentPath)}for(;t&&!n.Node.check(t.value);)t=t.parentPath;return t||null},h._computeScope=function(){var e=this.value,t=this.parentPath,r=t&&t.scope;return n.Node.check(e)&&u.isEstablishedBy(e)&&(r=new u(this,r)),r||null},h.getValueProperty=function(e){return t.getFieldValue(this.value,e)},h.needsParens=function(e){var t=this.parentPath;if(!t)return!1;var r=this.value;if(!n.Expression.check(r))return!1;if("Identifier"===r.type)return!1;for(;!n.Node.check(t.value);)if(!(t=t.parentPath))return!1;var i=t.value;switch(r.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return"MemberExpression"===i.type&&"object"===this.name&&i.object===r;case"BinaryExpression":case"LogicalExpression":switch(i.type){case"CallExpression":return"callee"===this.name&&i.callee===r;case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return!0;case"MemberExpression":return"object"===this.name&&i.object===r;case"BinaryExpression":case"LogicalExpression":var a=r,s=i.operator,l=f[s],c=a.operator,u=f[c];if(l>u)return!0;if(l===u&&"right"===this.name){if(i.right!==a)throw Error("Nodes must be equal");return!0}default:return!1}case"SequenceExpression":switch(i.type){case"ForStatement":return!1;case"ExpressionStatement":return"expression"!==this.name;default:return!0}case"YieldExpression":switch(i.type){case"BinaryExpression":case"LogicalExpression":case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"CallExpression":case"MemberExpression":case"NewExpression":case"ConditionalExpression":case"YieldExpression":return!0;default:return!1}case"Literal":return"MemberExpression"===i.type&&o.check(r.value)&&"object"===this.name&&i.object===r;case"AssignmentExpression":case"ConditionalExpression":switch(i.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"BinaryExpression":case"LogicalExpression":return!0;case"CallExpression":return"callee"===this.name&&i.callee===r;case"ConditionalExpression":return"test"===this.name&&i.test===r;case"MemberExpression":return"object"===this.name&&i.object===r;default:return!1}default:if("NewExpression"===i.type&&"callee"===this.name&&i.callee===r)return m(r)}return!(!0===e||this.canBeFirstInStatement()||!this.firstInStatement())};var f={};function m(e){return!!n.CallExpression.check(e)||(l.check(e)?e.some(m):!!n.Node.check(e)&&t.someField(e,(function(e,t){return m(t)})))}return[["||"],["&&"],["|"],["^"],["&"],["==","===","!=","!=="],["<",">","<=",">=","in","instanceof"],[">>","<<",">>>"],["+","-"],["*","/","%"]].forEach((function(e,t){e.forEach((function(e){f[e]=t}))})),h.canBeFirstInStatement=function(){var e=this.node;return!n.FunctionExpression.check(e)&&!n.ObjectExpression.check(e)},h.firstInStatement=function(){return function(e){for(var t,r;e.parent;e=e.parent){if(t=e.node,r=e.parent.node,n.BlockStatement.check(r)&&"body"===e.parent.name&&0===e.name){if(r.body[0]!==t)throw Error("Nodes must be equal");return!0}if(n.ExpressionStatement.check(r)&&"expression"===e.name){if(r.expression!==t)throw Error("Nodes must be equal");return!0}if(n.SequenceExpression.check(r)&&"expressions"===e.parent.name&&0===e.name){if(r.expressions[0]!==t)throw Error("Nodes must be equal")}else if(n.CallExpression.check(r)&&"callee"===e.name){if(r.callee!==t)throw Error("Nodes must be equal")}else if(n.MemberExpression.check(r)&&"object"===e.name){if(r.object!==t)throw Error("Nodes must be equal")}else if(n.ConditionalExpression.check(r)&&"test"===e.name){if(r.test!==t)throw Error("Nodes must be equal")}else if(d(r)&&"left"===e.name){if(r.left!==t)throw Error("Nodes must be equal")}else{if(!n.UnaryExpression.check(r)||r.prefix||"argument"!==e.name)return!1;if(r.argument!==t)throw Error("Nodes must be equal")}}return!0}(this)},p},(0,s.maybeSetModuleExports)((function(){return e}))}(In,In.exports)),In.exports}var Fn,Vn,Rn={exports:{}};function qn(){return Fn||(Fn=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=Pn(),i=n.__importDefault(wn());t.default=function(e){var t=e.use(i.default),n=t.getFieldNames,r=t.getFieldValue,a=t.builtInTypes.array,s=t.builtInTypes.object,o=t.builtInTypes.Date,l=t.builtInTypes.RegExp,c=Object.prototype.hasOwnProperty;function u(e,t,n){return a.check(n)?n.length=0:n=null,h(e,t,n)}function p(e){return/[_$a-z][_$a-z0-9]*/i.test(e)?"."+e:"["+JSON.stringify(e)+"]"}function h(e,t,i){return e===t||(a.check(e)?function(e,t,n){a.assert(e);var r=e.length;if(!a.check(t)||t.length!==r)return n&&n.push("length"),!1;for(var i=0;i<r;++i){if(n&&n.push(i),i in e!=i in t)return!1;if(!h(e[i],t[i],n))return!1;if(n){var s=n.pop();if(s!==i)throw Error(""+s)}}return!0}(e,t,i):s.check(e)?function(e,t,i){if(s.assert(e),!s.check(t))return!1;if(e.type!==t.type)return i&&i.push("type"),!1;var a=n(e),o=a.length,l=n(t),u=l.length;if(o===u){for(var p=0;p<o;++p){var d=a[p],f=r(e,d),m=r(t,d);if(i&&i.push(d),!h(f,m,i))return!1;if(i){var y=i.pop();if(y!==d)throw Error(""+y)}}return!0}if(!i)return!1;var g=Object.create(null);for(p=0;p<o;++p)g[a[p]]=!0;for(p=0;p<u;++p){if(d=l[p],!c.call(g,d))return i.push(d),!1;delete g[d]}for(d in g){i.push(d);break}return!1}(e,t,i):o.check(e)?o.check(t)&&+e==+t:l.check(e)?l.check(t)&&e.source===t.source&&e.global===t.global&&e.multiline===t.multiline&&e.ignoreCase===t.ignoreCase:e==t)}return u.assert=function(e,t){var n=[];if(!u(e,t,n)){if(0!==n.length)throw Error("Nodes differ in the following path: "+n.map(p).join(""));if(e!==t)throw Error("Nodes must be equal")}},u},(0,r.maybeSetModuleExports)((function(){return e}))}(Rn,Rn.exports)),Rn.exports}var Un,zn,Wn,Gn,Jn={exports:{}},$n={exports:{}},Hn={exports:{}},Kn={exports:{}},Xn={exports:{}},Yn={exports:{}},Qn={exports:{}};function Zn(){return Un||(Un=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Pn();t.default=function(){return{BinaryOperators:["==","!=","===","!==","<","<=",">",">=","<<",">>",">>>","+","-","*","/","%","&","|","^","in","instanceof"],AssignmentOperators:["=","+=","-=","*=","/=","%=","<<=",">>=",">>>=","|=","^=","&="],LogicalOperators:["||","&&"]}},(0,n.maybeSetModuleExports)((function(){return e}))}(Qn,Qn.exports)),Qn.exports}function er(){return zn||(zn=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=Pn(),i=n.__importDefault(Zn());t.default=function(e){var t=e.use(i.default);return t.BinaryOperators.indexOf("**")<0&&t.BinaryOperators.push("**"),t.AssignmentOperators.indexOf("**=")<0&&t.AssignmentOperators.push("**="),t},(0,r.maybeSetModuleExports)((function(){return e}))}(Yn,Yn.exports)),Yn.exports}function tr(){return Wn||(Wn=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=Pn(),i=n.__importDefault(er());t.default=function(e){var t=e.use(i.default);return t.LogicalOperators.indexOf("??")<0&&t.LogicalOperators.push("??"),t},(0,r.maybeSetModuleExports)((function(){return e}))}(Xn,Xn.exports)),Xn.exports}var nr,rr,ir,ar,sr,or,lr,cr,ur,pr,hr={exports:{}},dr={exports:{}},fr={exports:{}},mr={exports:{}},yr={exports:{}},gr={exports:{}},br={exports:{}};function vr(){return pr||(pr=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(wn()),i=n.__importStar(Pn()),a=n.__importDefault((ur||(ur=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault((cr||(cr=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault((Gn||(Gn=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=Pn(),i=n.__importDefault(tr());t.default=function(e){var t=e.use(i.default);return t.LogicalOperators.forEach((function(e){var n=e+"=";t.AssignmentOperators.indexOf(n)<0&&t.AssignmentOperators.push(n)})),t},(0,r.maybeSetModuleExports)((function(){return e}))}(Kn,Kn.exports)),Kn.exports)),i=n.__importDefault((lr||(lr=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(tr()),i=n.__importDefault((or||(or=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault((sr||(sr=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault((ar||(ar=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault((ir||(ir=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(er()),i=n.__importDefault((rr||(rr=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault((nr||(nr=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(Zn()),i=n.__importDefault(wn()),a=n.__importStar(Pn());t.default=function(e){var t=e.use(i.default).Type,n=t.def,s=t.or,o=e.use(a.default),l=o.defaults,c=o.geq,u=e.use(r.default),p=u.BinaryOperators,h=u.AssignmentOperators,d=u.LogicalOperators;n("Printable").field("loc",s(n("SourceLocation"),null),l.null,!0),n("Node").bases("Printable").field("type",String).field("comments",s([n("Comment")],null),l.null,!0),n("SourceLocation").field("start",n("Position")).field("end",n("Position")).field("source",s(String,null),l.null),n("Position").field("line",c(1)).field("column",c(0)),n("File").bases("Node").build("program","name").field("program",n("Program")).field("name",s(String,null),l.null),n("Program").bases("Node").build("body").field("body",[n("Statement")]),n("Function").bases("Node").field("id",s(n("Identifier"),null),l.null).field("params",[n("Pattern")]).field("body",n("BlockStatement")).field("generator",Boolean,l.false).field("async",Boolean,l.false),n("Statement").bases("Node"),n("EmptyStatement").bases("Statement").build(),n("BlockStatement").bases("Statement").build("body").field("body",[n("Statement")]),n("ExpressionStatement").bases("Statement").build("expression").field("expression",n("Expression")),n("IfStatement").bases("Statement").build("test","consequent","alternate").field("test",n("Expression")).field("consequent",n("Statement")).field("alternate",s(n("Statement"),null),l.null),n("LabeledStatement").bases("Statement").build("label","body").field("label",n("Identifier")).field("body",n("Statement")),n("BreakStatement").bases("Statement").build("label").field("label",s(n("Identifier"),null),l.null),n("ContinueStatement").bases("Statement").build("label").field("label",s(n("Identifier"),null),l.null),n("WithStatement").bases("Statement").build("object","body").field("object",n("Expression")).field("body",n("Statement")),n("SwitchStatement").bases("Statement").build("discriminant","cases","lexical").field("discriminant",n("Expression")).field("cases",[n("SwitchCase")]).field("lexical",Boolean,l.false),n("ReturnStatement").bases("Statement").build("argument").field("argument",s(n("Expression"),null)),n("ThrowStatement").bases("Statement").build("argument").field("argument",n("Expression")),n("TryStatement").bases("Statement").build("block","handler","finalizer").field("block",n("BlockStatement")).field("handler",s(n("CatchClause"),null),(function(){return this.handlers&&this.handlers[0]||null})).field("handlers",[n("CatchClause")],(function(){return this.handler?[this.handler]:[]}),!0).field("guardedHandlers",[n("CatchClause")],l.emptyArray).field("finalizer",s(n("BlockStatement"),null),l.null),n("CatchClause").bases("Node").build("param","guard","body").field("param",n("Pattern")).field("guard",s(n("Expression"),null),l.null).field("body",n("BlockStatement")),n("WhileStatement").bases("Statement").build("test","body").field("test",n("Expression")).field("body",n("Statement")),n("DoWhileStatement").bases("Statement").build("body","test").field("body",n("Statement")).field("test",n("Expression")),n("ForStatement").bases("Statement").build("init","test","update","body").field("init",s(n("VariableDeclaration"),n("Expression"),null)).field("test",s(n("Expression"),null)).field("update",s(n("Expression"),null)).field("body",n("Statement")),n("ForInStatement").bases("Statement").build("left","right","body").field("left",s(n("VariableDeclaration"),n("Expression"))).field("right",n("Expression")).field("body",n("Statement")),n("DebuggerStatement").bases("Statement").build(),n("Declaration").bases("Statement"),n("FunctionDeclaration").bases("Function","Declaration").build("id","params","body").field("id",n("Identifier")),n("FunctionExpression").bases("Function","Expression").build("id","params","body"),n("VariableDeclaration").bases("Declaration").build("kind","declarations").field("kind",s("var","let","const")).field("declarations",[n("VariableDeclarator")]),n("VariableDeclarator").bases("Node").build("id","init").field("id",n("Pattern")).field("init",s(n("Expression"),null),l.null),n("Expression").bases("Node"),n("ThisExpression").bases("Expression").build(),n("ArrayExpression").bases("Expression").build("elements").field("elements",[s(n("Expression"),null)]),n("ObjectExpression").bases("Expression").build("properties").field("properties",[n("Property")]),n("Property").bases("Node").build("kind","key","value").field("kind",s("init","get","set")).field("key",s(n("Literal"),n("Identifier"))).field("value",n("Expression")),n("SequenceExpression").bases("Expression").build("expressions").field("expressions",[n("Expression")]);var f=s("-","+","!","~","typeof","void","delete");n("UnaryExpression").bases("Expression").build("operator","argument","prefix").field("operator",f).field("argument",n("Expression")).field("prefix",Boolean,l.true);var m=s.apply(void 0,p);n("BinaryExpression").bases("Expression").build("operator","left","right").field("operator",m).field("left",n("Expression")).field("right",n("Expression"));var y=s.apply(void 0,h);n("AssignmentExpression").bases("Expression").build("operator","left","right").field("operator",y).field("left",s(n("Pattern"),n("MemberExpression"))).field("right",n("Expression"));var g=s("++","--");n("UpdateExpression").bases("Expression").build("operator","argument","prefix").field("operator",g).field("argument",n("Expression")).field("prefix",Boolean);var b=s.apply(void 0,d);n("LogicalExpression").bases("Expression").build("operator","left","right").field("operator",b).field("left",n("Expression")).field("right",n("Expression")),n("ConditionalExpression").bases("Expression").build("test","consequent","alternate").field("test",n("Expression")).field("consequent",n("Expression")).field("alternate",n("Expression")),n("NewExpression").bases("Expression").build("callee","arguments").field("callee",n("Expression")).field("arguments",[n("Expression")]),n("CallExpression").bases("Expression").build("callee","arguments").field("callee",n("Expression")).field("arguments",[n("Expression")]),n("MemberExpression").bases("Expression").build("object","property","computed").field("object",n("Expression")).field("property",s(n("Identifier"),n("Expression"))).field("computed",Boolean,(function(){var e=this.property.type;return"Literal"===e||"MemberExpression"===e||"BinaryExpression"===e})),n("Pattern").bases("Node"),n("SwitchCase").bases("Node").build("test","consequent").field("test",s(n("Expression"),null)).field("consequent",[n("Statement")]),n("Identifier").bases("Expression","Pattern").build("name").field("name",String).field("optional",Boolean,l.false),n("Literal").bases("Expression").build("value").field("value",s(String,Boolean,null,Number,RegExp,BigInt)),n("Comment").bases("Printable").field("value",String).field("leading",Boolean,l.true).field("trailing",Boolean,l.false)},(0,a.maybeSetModuleExports)((function(){return e}))}(br,br.exports)),br.exports)),i=n.__importDefault(wn()),a=n.__importStar(Pn());t.default=function(e){e.use(r.default);var t=e.use(i.default),n=t.Type.def,s=t.Type.or,o=e.use(a.default).defaults;n("Function").field("generator",Boolean,o.false).field("expression",Boolean,o.false).field("defaults",[s(n("Expression"),null)],o.emptyArray).field("rest",s(n("Identifier"),null),o.null),n("RestElement").bases("Pattern").build("argument").field("argument",n("Pattern")).field("typeAnnotation",s(n("TypeAnnotation"),n("TSTypeAnnotation"),null),o.null),n("SpreadElementPattern").bases("Pattern").build("argument").field("argument",n("Pattern")),n("FunctionDeclaration").build("id","params","body","generator","expression").field("id",s(n("Identifier"),null)),n("FunctionExpression").build("id","params","body","generator","expression"),n("ArrowFunctionExpression").bases("Function","Expression").build("params","body","expression").field("id",null,o.null).field("body",s(n("BlockStatement"),n("Expression"))).field("generator",!1,o.false),n("ForOfStatement").bases("Statement").build("left","right","body").field("left",s(n("VariableDeclaration"),n("Pattern"))).field("right",n("Expression")).field("body",n("Statement")),n("YieldExpression").bases("Expression").build("argument","delegate").field("argument",s(n("Expression"),null)).field("delegate",Boolean,o.false),n("GeneratorExpression").bases("Expression").build("body","blocks","filter").field("body",n("Expression")).field("blocks",[n("ComprehensionBlock")]).field("filter",s(n("Expression"),null)),n("ComprehensionExpression").bases("Expression").build("body","blocks","filter").field("body",n("Expression")).field("blocks",[n("ComprehensionBlock")]).field("filter",s(n("Expression"),null)),n("ComprehensionBlock").bases("Node").build("left","right","each").field("left",n("Pattern")).field("right",n("Expression")).field("each",Boolean),n("Property").field("key",s(n("Literal"),n("Identifier"),n("Expression"))).field("value",s(n("Expression"),n("Pattern"))).field("method",Boolean,o.false).field("shorthand",Boolean,o.false).field("computed",Boolean,o.false),n("ObjectProperty").field("shorthand",Boolean,o.false),n("PropertyPattern").bases("Pattern").build("key","pattern").field("key",s(n("Literal"),n("Identifier"),n("Expression"))).field("pattern",n("Pattern")).field("computed",Boolean,o.false),n("ObjectPattern").bases("Pattern").build("properties").field("properties",[s(n("PropertyPattern"),n("Property"))]),n("ArrayPattern").bases("Pattern").build("elements").field("elements",[s(n("Pattern"),null)]),n("SpreadElement").bases("Node").build("argument").field("argument",n("Expression")),n("ArrayExpression").field("elements",[s(n("Expression"),n("SpreadElement"),n("RestElement"),null)]),n("NewExpression").field("arguments",[s(n("Expression"),n("SpreadElement"))]),n("CallExpression").field("arguments",[s(n("Expression"),n("SpreadElement"))]),n("AssignmentPattern").bases("Pattern").build("left","right").field("left",n("Pattern")).field("right",n("Expression")),n("MethodDefinition").bases("Declaration").build("kind","key","value","static").field("kind",s("constructor","method","get","set")).field("key",n("Expression")).field("value",n("Function")).field("computed",Boolean,o.false).field("static",Boolean,o.false);var l=s(n("MethodDefinition"),n("VariableDeclarator"),n("ClassPropertyDefinition"),n("ClassProperty"),n("StaticBlock"));n("ClassProperty").bases("Declaration").build("key").field("key",s(n("Literal"),n("Identifier"),n("Expression"))).field("computed",Boolean,o.false),n("ClassPropertyDefinition").bases("Declaration").build("definition").field("definition",l),n("ClassBody").bases("Declaration").build("body").field("body",[l]),n("ClassDeclaration").bases("Declaration").build("id","body","superClass").field("id",s(n("Identifier"),null)).field("body",n("ClassBody")).field("superClass",s(n("Expression"),null),o.null),n("ClassExpression").bases("Expression").build("id","body","superClass").field("id",s(n("Identifier"),null),o.null).field("body",n("ClassBody")).field("superClass",s(n("Expression"),null),o.null),n("Super").bases("Expression").build(),n("Specifier").bases("Node"),n("ModuleSpecifier").bases("Specifier").field("local",s(n("Identifier"),null),o.null).field("id",s(n("Identifier"),null),o.null).field("name",s(n("Identifier"),null),o.null),n("ImportSpecifier").bases("ModuleSpecifier").build("imported","local").field("imported",n("Identifier")),n("ImportDefaultSpecifier").bases("ModuleSpecifier").build("local"),n("ImportNamespaceSpecifier").bases("ModuleSpecifier").build("local"),n("ImportDeclaration").bases("Declaration").build("specifiers","source","importKind").field("specifiers",[s(n("ImportSpecifier"),n("ImportNamespaceSpecifier"),n("ImportDefaultSpecifier"))],o.emptyArray).field("source",n("Literal")).field("importKind",s("value","type"),(function(){return"value"})),n("ExportNamedDeclaration").bases("Declaration").build("declaration","specifiers","source").field("declaration",s(n("Declaration"),null)).field("specifiers",[n("ExportSpecifier")],o.emptyArray).field("source",s(n("Literal"),null),o.null),n("ExportSpecifier").bases("ModuleSpecifier").build("local","exported").field("exported",n("Identifier")),n("ExportDefaultDeclaration").bases("Declaration").build("declaration").field("declaration",s(n("Declaration"),n("Expression"))),n("ExportAllDeclaration").bases("Declaration").build("source").field("source",n("Literal")),n("TaggedTemplateExpression").bases("Expression").build("tag","quasi").field("tag",n("Expression")).field("quasi",n("TemplateLiteral")),n("TemplateLiteral").bases("Expression").build("quasis","expressions").field("quasis",[n("TemplateElement")]).field("expressions",[n("Expression")]),n("TemplateElement").bases("Node").build("value","tail").field("value",{cooked:String,raw:String}).field("tail",Boolean),n("MetaProperty").bases("Expression").build("meta","property").field("meta",n("Identifier")).field("property",n("Identifier"))},(0,a.maybeSetModuleExports)((function(){return e}))}(gr,gr.exports)),gr.exports)),a=Pn();t.default=function(e){e.use(r.default),e.use(i.default)},(0,a.maybeSetModuleExports)((function(){return e}))}(yr,yr.exports)),yr.exports)),i=n.__importDefault(wn()),a=n.__importStar(Pn());t.default=function(e){e.use(r.default);var t=e.use(i.default).Type.def,n=e.use(a.default).defaults;t("Function").field("async",Boolean,n.false),t("AwaitExpression").bases("Expression").build("argument").field("argument",t("Expression"))},(0,a.maybeSetModuleExports)((function(){return e}))}(mr,mr.exports)),mr.exports)),i=n.__importDefault(wn()),a=n.__importStar(Pn());t.default=function(e){e.use(r.default);var t=e.use(i.default),n=t.Type.def,s=t.Type.or,o=e.use(a.default).defaults;n("ForOfStatement").field("await",Boolean,o.false),n("SpreadProperty").bases("Node").build("argument").field("argument",n("Expression")),n("ObjectExpression").field("properties",[s(n("Property"),n("SpreadProperty"),n("SpreadElement"))]),n("TemplateElement").field("value",{cooked:s(String,null),raw:String}),n("SpreadPropertyPattern").bases("Pattern").build("argument").field("argument",n("Pattern")),n("ObjectPattern").field("properties",[s(n("PropertyPattern"),n("Property"),n("RestElement"),n("SpreadPropertyPattern"))])},(0,a.maybeSetModuleExports)((function(){return e}))}(fr,fr.exports)),fr.exports)),i=n.__importDefault(wn()),a=n.__importStar(Pn());t.default=function(e){e.use(r.default);var t=e.use(i.default),n=t.Type.def,s=t.Type.or,o=e.use(a.default).defaults;n("CatchClause").field("param",s(n("Pattern"),null),o.null)},(0,a.maybeSetModuleExports)((function(){return e}))}(dr,dr.exports)),dr.exports)),a=n.__importDefault(wn()),s=n.__importStar(Pn());t.default=function(e){e.use(r.default),e.use(i.default);var t=e.use(a.default),n=t.Type.def,o=t.Type.or,l=e.use(s.default).defaults;n("ImportExpression").bases("Expression").build("source").field("source",n("Expression")),n("ExportAllDeclaration").bases("Declaration").build("source","exported").field("source",n("Literal")).field("exported",o(n("Identifier"),null,void 0),l.null),n("ChainElement").bases("Node").field("optional",Boolean,l.false),n("CallExpression").bases("Expression","ChainElement"),n("MemberExpression").bases("Expression","ChainElement"),n("ChainExpression").bases("Expression").build("expression").field("expression",n("ChainElement")),n("OptionalCallExpression").bases("CallExpression").build("callee","arguments","optional").field("optional",Boolean,l.true),n("OptionalMemberExpression").bases("MemberExpression").build("object","property","computed","optional").field("optional",Boolean,l.true)},(0,s.maybeSetModuleExports)((function(){return e}))}(hr,hr.exports)),hr.exports)),a=Pn();t.default=function(e){e.use(r.default),e.use(i.default)},(0,a.maybeSetModuleExports)((function(){return e}))}(Hn,Hn.exports)),Hn.exports)),i=n.__importDefault(wn()),a=Pn();t.default=function(e){e.use(r.default);var t=e.use(i.default).Type.def;t("StaticBlock").bases("Declaration").build("body").field("body",[t("Statement")])},(0,a.maybeSetModuleExports)((function(){return e}))}($n,$n.exports)),$n.exports));t.default=function(e){e.use(a.default);var t=e.use(r.default),n=t.Type,s=t.Type.def,o=n.or,l=e.use(i.default).defaults;s("AwaitExpression").build("argument","all").field("argument",o(s("Expression"),null)).field("all",Boolean,l.false),s("Decorator").bases("Node").build("expression").field("expression",s("Expression")),s("Property").field("decorators",o([s("Decorator")],null),l.null),s("MethodDefinition").field("decorators",o([s("Decorator")],null),l.null),s("PrivateName").bases("Expression","Pattern").build("id").field("id",s("Identifier")),s("ClassPrivateProperty").bases("ClassProperty").build("key","value").field("key",s("PrivateName")).field("value",o(s("Expression"),null),l.null),s("ImportAttribute").bases("Node").build("key","value").field("key",o(s("Identifier"),s("Literal"))).field("value",s("Expression")),["ImportDeclaration","ExportAllDeclaration","ExportNamedDeclaration"].forEach((function(e){s(e).field("assertions",[s("ImportAttribute")],l.emptyArray)})),s("RecordExpression").bases("Expression").build("properties").field("properties",[o(s("ObjectProperty"),s("ObjectMethod"),s("SpreadElement"))]),s("TupleExpression").bases("Expression").build("elements").field("elements",[o(s("Expression"),s("SpreadElement"),null)]),s("ModuleExpression").bases("Node").build("body").field("body",s("Program"))},(0,i.maybeSetModuleExports)((function(){return e}))}(Jn,Jn.exports)),Jn.exports}var xr,Sr,Er,Tr={exports:{}},_r={exports:{}},kr={exports:{}};function Pr(){return Sr||(Sr=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(wn()),i=n.__importStar(Pn());t.default=function(e){var t=e.use(r.default),n=t.Type.def,a=t.Type.or,s=e.use(i.default).defaults,o=a(n("TypeAnnotation"),n("TSTypeAnnotation"),null),l=a(n("TypeParameterDeclaration"),n("TSTypeParameterDeclaration"),null);n("Identifier").field("typeAnnotation",o,s.null),n("ObjectPattern").field("typeAnnotation",o,s.null),n("Function").field("returnType",o,s.null).field("typeParameters",l,s.null),n("ClassProperty").build("key","value","typeAnnotation","static").field("value",a(n("Expression"),null)).field("static",Boolean,s.false).field("typeAnnotation",o,s.null),["ClassDeclaration","ClassExpression"].forEach((function(e){n(e).field("typeParameters",l,s.null).field("superTypeParameters",a(n("TypeParameterInstantiation"),n("TSTypeParameterInstantiation"),null),s.null).field("implements",a([n("ClassImplements")],[n("TSExpressionWithTypeArguments")]),s.emptyArray)}))},(0,i.maybeSetModuleExports)((function(){return e}))}(kr,kr.exports)),kr.exports}function wr(){return Er||(Er=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(vr()),i=n.__importDefault(Pr()),a=n.__importDefault(wn()),s=n.__importStar(Pn());t.default=function(e){e.use(r.default),e.use(i.default);var t=e.use(a.default),n=t.Type.def,o=t.Type.or,l=e.use(s.default).defaults;n("Flow").bases("Node"),n("FlowType").bases("Flow"),n("AnyTypeAnnotation").bases("FlowType").build(),n("EmptyTypeAnnotation").bases("FlowType").build(),n("MixedTypeAnnotation").bases("FlowType").build(),n("VoidTypeAnnotation").bases("FlowType").build(),n("SymbolTypeAnnotation").bases("FlowType").build(),n("NumberTypeAnnotation").bases("FlowType").build(),n("BigIntTypeAnnotation").bases("FlowType").build(),n("NumberLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Number).field("raw",String),n("NumericLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Number).field("raw",String),n("BigIntLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",null).field("raw",String),n("StringTypeAnnotation").bases("FlowType").build(),n("StringLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",String).field("raw",String),n("BooleanTypeAnnotation").bases("FlowType").build(),n("BooleanLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Boolean).field("raw",String),n("TypeAnnotation").bases("Node").build("typeAnnotation").field("typeAnnotation",n("FlowType")),n("NullableTypeAnnotation").bases("FlowType").build("typeAnnotation").field("typeAnnotation",n("FlowType")),n("NullLiteralTypeAnnotation").bases("FlowType").build(),n("NullTypeAnnotation").bases("FlowType").build(),n("ThisTypeAnnotation").bases("FlowType").build(),n("ExistsTypeAnnotation").bases("FlowType").build(),n("ExistentialTypeParam").bases("FlowType").build(),n("FunctionTypeAnnotation").bases("FlowType").build("params","returnType","rest","typeParameters").field("params",[n("FunctionTypeParam")]).field("returnType",n("FlowType")).field("rest",o(n("FunctionTypeParam"),null)).field("typeParameters",o(n("TypeParameterDeclaration"),null)),n("FunctionTypeParam").bases("Node").build("name","typeAnnotation","optional").field("name",o(n("Identifier"),null)).field("typeAnnotation",n("FlowType")).field("optional",Boolean),n("ArrayTypeAnnotation").bases("FlowType").build("elementType").field("elementType",n("FlowType")),n("ObjectTypeAnnotation").bases("FlowType").build("properties","indexers","callProperties").field("properties",[o(n("ObjectTypeProperty"),n("ObjectTypeSpreadProperty"))]).field("indexers",[n("ObjectTypeIndexer")],l.emptyArray).field("callProperties",[n("ObjectTypeCallProperty")],l.emptyArray).field("inexact",o(Boolean,void 0),l[void 0]).field("exact",Boolean,l.false).field("internalSlots",[n("ObjectTypeInternalSlot")],l.emptyArray),n("Variance").bases("Node").build("kind").field("kind",o("plus","minus"));var c=o(n("Variance"),"plus","minus",null);n("ObjectTypeProperty").bases("Node").build("key","value","optional").field("key",o(n("Literal"),n("Identifier"))).field("value",n("FlowType")).field("optional",Boolean).field("variance",c,l.null),n("ObjectTypeIndexer").bases("Node").build("id","key","value").field("id",n("Identifier")).field("key",n("FlowType")).field("value",n("FlowType")).field("variance",c,l.null).field("static",Boolean,l.false),n("ObjectTypeCallProperty").bases("Node").build("value").field("value",n("FunctionTypeAnnotation")).field("static",Boolean,l.false),n("QualifiedTypeIdentifier").bases("Node").build("qualification","id").field("qualification",o(n("Identifier"),n("QualifiedTypeIdentifier"))).field("id",n("Identifier")),n("GenericTypeAnnotation").bases("FlowType").build("id","typeParameters").field("id",o(n("Identifier"),n("QualifiedTypeIdentifier"))).field("typeParameters",o(n("TypeParameterInstantiation"),null)),n("MemberTypeAnnotation").bases("FlowType").build("object","property").field("object",n("Identifier")).field("property",o(n("MemberTypeAnnotation"),n("GenericTypeAnnotation"))),n("IndexedAccessType").bases("FlowType").build("objectType","indexType").field("objectType",n("FlowType")).field("indexType",n("FlowType")),n("OptionalIndexedAccessType").bases("FlowType").build("objectType","indexType","optional").field("objectType",n("FlowType")).field("indexType",n("FlowType")).field("optional",Boolean),n("UnionTypeAnnotation").bases("FlowType").build("types").field("types",[n("FlowType")]),n("IntersectionTypeAnnotation").bases("FlowType").build("types").field("types",[n("FlowType")]),n("TypeofTypeAnnotation").bases("FlowType").build("argument").field("argument",n("FlowType")),n("ObjectTypeSpreadProperty").bases("Node").build("argument").field("argument",n("FlowType")),n("ObjectTypeInternalSlot").bases("Node").build("id","value","optional","static","method").field("id",n("Identifier")).field("value",n("FlowType")).field("optional",Boolean).field("static",Boolean).field("method",Boolean),n("TypeParameterDeclaration").bases("Node").build("params").field("params",[n("TypeParameter")]),n("TypeParameterInstantiation").bases("Node").build("params").field("params",[n("FlowType")]),n("TypeParameter").bases("FlowType").build("name","variance","bound","default").field("name",String).field("variance",c,l.null).field("bound",o(n("TypeAnnotation"),null),l.null).field("default",o(n("FlowType"),null),l.null),n("ClassProperty").field("variance",c,l.null),n("ClassImplements").bases("Node").build("id").field("id",n("Identifier")).field("superClass",o(n("Expression"),null),l.null).field("typeParameters",o(n("TypeParameterInstantiation"),null),l.null),n("InterfaceTypeAnnotation").bases("FlowType").build("body","extends").field("body",n("ObjectTypeAnnotation")).field("extends",o([n("InterfaceExtends")],null),l.null),n("InterfaceDeclaration").bases("Declaration").build("id","body","extends").field("id",n("Identifier")).field("typeParameters",o(n("TypeParameterDeclaration"),null),l.null).field("body",n("ObjectTypeAnnotation")).field("extends",[n("InterfaceExtends")]),n("DeclareInterface").bases("InterfaceDeclaration").build("id","body","extends"),n("InterfaceExtends").bases("Node").build("id").field("id",n("Identifier")).field("typeParameters",o(n("TypeParameterInstantiation"),null),l.null),n("TypeAlias").bases("Declaration").build("id","typeParameters","right").field("id",n("Identifier")).field("typeParameters",o(n("TypeParameterDeclaration"),null)).field("right",n("FlowType")),n("DeclareTypeAlias").bases("TypeAlias").build("id","typeParameters","right"),n("OpaqueType").bases("Declaration").build("id","typeParameters","impltype","supertype").field("id",n("Identifier")).field("typeParameters",o(n("TypeParameterDeclaration"),null)).field("impltype",n("FlowType")).field("supertype",o(n("FlowType"),null)),n("DeclareOpaqueType").bases("OpaqueType").build("id","typeParameters","supertype").field("impltype",o(n("FlowType"),null)),n("TypeCastExpression").bases("Expression").build("expression","typeAnnotation").field("expression",n("Expression")).field("typeAnnotation",n("TypeAnnotation")),n("TupleTypeAnnotation").bases("FlowType").build("types").field("types",[n("FlowType")]),n("DeclareVariable").bases("Statement").build("id").field("id",n("Identifier")),n("DeclareFunction").bases("Statement").build("id").field("id",n("Identifier")).field("predicate",o(n("FlowPredicate"),null),l.null),n("DeclareClass").bases("InterfaceDeclaration").build("id"),n("DeclareModule").bases("Statement").build("id","body").field("id",o(n("Identifier"),n("Literal"))).field("body",n("BlockStatement")),n("DeclareModuleExports").bases("Statement").build("typeAnnotation").field("typeAnnotation",n("TypeAnnotation")),n("DeclareExportDeclaration").bases("Declaration").build("default","declaration","specifiers","source").field("default",Boolean).field("declaration",o(n("DeclareVariable"),n("DeclareFunction"),n("DeclareClass"),n("FlowType"),n("TypeAlias"),n("DeclareOpaqueType"),n("InterfaceDeclaration"),null)).field("specifiers",[o(n("ExportSpecifier"),n("ExportBatchSpecifier"))],l.emptyArray).field("source",o(n("Literal"),null),l.null),n("DeclareExportAllDeclaration").bases("Declaration").build("source").field("source",o(n("Literal"),null),l.null),n("ImportDeclaration").field("importKind",o("value","type","typeof"),(function(){return"value"})),n("FlowPredicate").bases("Flow"),n("InferredPredicate").bases("FlowPredicate").build(),n("DeclaredPredicate").bases("FlowPredicate").build("value").field("value",n("Expression")),n("Function").field("predicate",o(n("FlowPredicate"),null),l.null),n("CallExpression").field("typeArguments",o(null,n("TypeParameterInstantiation")),l.null),n("NewExpression").field("typeArguments",o(null,n("TypeParameterInstantiation")),l.null),n("EnumDeclaration").bases("Declaration").build("id","body").field("id",n("Identifier")).field("body",o(n("EnumBooleanBody"),n("EnumNumberBody"),n("EnumStringBody"),n("EnumSymbolBody"))),n("EnumBooleanBody").build("members","explicitType").field("members",[n("EnumBooleanMember")]).field("explicitType",Boolean),n("EnumNumberBody").build("members","explicitType").field("members",[n("EnumNumberMember")]).field("explicitType",Boolean),n("EnumStringBody").build("members","explicitType").field("members",o([n("EnumStringMember")],[n("EnumDefaultedMember")])).field("explicitType",Boolean),n("EnumSymbolBody").build("members").field("members",[n("EnumDefaultedMember")]),n("EnumBooleanMember").build("id","init").field("id",n("Identifier")).field("init",o(n("Literal"),Boolean)),n("EnumNumberMember").build("id","init").field("id",n("Identifier")).field("init",n("Literal")),n("EnumStringMember").build("id","init").field("id",n("Identifier")).field("init",n("Literal")),n("EnumDefaultedMember").build("id").field("id",n("Identifier"))},(0,s.maybeSetModuleExports)((function(){return e}))}(_r,_r.exports)),_r.exports}var Ar,Cr,Ir,Nr={exports:{}},Or={exports:{}},Dr={exports:{}};function Lr(){return Cr||(Cr=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(vr()),i=n.__importDefault(wn()),a=n.__importStar(Pn());t.default=function(e){var t,n,s,o,l;e.use(r.default);var c=e.use(i.default),u=e.use(a.default).defaults,p=c.Type.def,h=c.Type.or,d=c.builtInTypes.undefined;function f(e,t){return void 0===e&&(e=String),["extra",{rawValue:e,raw:String},function(){var e=c.getFieldValue(this,"value");return{rawValue:e,raw:t?t(e):e+""}}]}p("Noop").bases("Statement").build(),p("DoExpression").bases("Expression").build("body").field("body",[p("Statement")]),p("BindExpression").bases("Expression").build("object","callee").field("object",h(p("Expression"),null)).field("callee",p("Expression")),p("ParenthesizedExpression").bases("Expression").build("expression").field("expression",p("Expression")),p("ExportNamespaceSpecifier").bases("Specifier").build("exported").field("exported",p("Identifier")),p("ExportDefaultSpecifier").bases("Specifier").build("exported").field("exported",p("Identifier")),p("CommentBlock").bases("Comment").build("value","leading","trailing"),p("CommentLine").bases("Comment").build("value","leading","trailing"),p("Directive").bases("Node").build("value").field("value",p("DirectiveLiteral")),p("DirectiveLiteral").bases("Node","Expression").build("value").field("value",String,u["use strict"]),p("InterpreterDirective").bases("Node").build("value").field("value",String),p("BlockStatement").bases("Statement").build("body").field("body",[p("Statement")]).field("directives",[p("Directive")],u.emptyArray),p("Program").bases("Node").build("body").field("body",[p("Statement")]).field("directives",[p("Directive")],u.emptyArray).field("interpreter",h(p("InterpreterDirective"),null),u.null),(t=p("StringLiteral").bases("Literal").build("value").field("value",String)).field.apply(t,f(String,(function(e){return JSON.stringify(e)}))),(n=p("NumericLiteral").bases("Literal").build("value").field("value",Number).field("raw",h(String,null),u.null)).field.apply(n,f(Number)),(s=p("BigIntLiteral").bases("Literal").build("value").field("value",h(String,Number))).field.apply(s,f(String,(function(e){return e+"n"}))),(o=p("DecimalLiteral").bases("Literal").build("value").field("value",String)).field.apply(o,f(String,(function(e){return e+"m"}))),p("NullLiteral").bases("Literal").build().field("value",null,u.null),p("BooleanLiteral").bases("Literal").build("value").field("value",Boolean),(l=p("RegExpLiteral").bases("Literal").build("pattern","flags").field("pattern",String).field("flags",String).field("value",RegExp,(function(){return RegExp(this.pattern,this.flags)}))).field.apply(l,f(h(RegExp,d),(function(e){return"/".concat(e.pattern,"/").concat(e.flags||"")}))).field("regex",{pattern:String,flags:String},(function(){return{pattern:this.pattern,flags:this.flags}}));var m=h(p("Property"),p("ObjectMethod"),p("ObjectProperty"),p("SpreadProperty"),p("SpreadElement"));p("ObjectExpression").bases("Expression").build("properties").field("properties",[m]),p("ObjectMethod").bases("Node","Function").build("kind","key","params","body","computed").field("kind",h("method","get","set")).field("key",h(p("Literal"),p("Identifier"),p("Expression"))).field("params",[p("Pattern")]).field("body",p("BlockStatement")).field("computed",Boolean,u.false).field("generator",Boolean,u.false).field("async",Boolean,u.false).field("accessibility",h(p("Literal"),null),u.null).field("decorators",h([p("Decorator")],null),u.null),p("ObjectProperty").bases("Node").build("key","value").field("key",h(p("Literal"),p("Identifier"),p("Expression"))).field("value",h(p("Expression"),p("Pattern"))).field("accessibility",h(p("Literal"),null),u.null).field("computed",Boolean,u.false);var y=h(p("MethodDefinition"),p("VariableDeclarator"),p("ClassPropertyDefinition"),p("ClassProperty"),p("ClassPrivateProperty"),p("ClassMethod"),p("ClassPrivateMethod"),p("ClassAccessorProperty"),p("StaticBlock"));p("ClassBody").bases("Declaration").build("body").field("body",[y]),p("ClassMethod").bases("Declaration","Function").build("kind","key","params","body","computed","static").field("key",h(p("Literal"),p("Identifier"),p("Expression"))),p("ClassPrivateMethod").bases("Declaration","Function").build("key","params","body","kind","computed","static").field("key",p("PrivateName")),p("ClassAccessorProperty").bases("Declaration").build("key","value","decorators","computed","static").field("key",h(p("Literal"),p("Identifier"),p("PrivateName"),p("Expression"))).field("value",h(p("Expression"),null),u.null),["ClassMethod","ClassPrivateMethod"].forEach((function(e){p(e).field("kind",h("get","set","method","constructor"),(function(){return"method"})).field("body",p("BlockStatement")).field("access",h("public","private","protected",null),u.null)})),["ClassMethod","ClassPrivateMethod","ClassAccessorProperty"].forEach((function(e){p(e).field("computed",Boolean,u.false).field("static",Boolean,u.false).field("abstract",Boolean,u.false).field("accessibility",h("public","private","protected",null),u.null).field("decorators",h([p("Decorator")],null),u.null).field("definite",Boolean,u.false).field("optional",Boolean,u.false).field("override",Boolean,u.false).field("readonly",Boolean,u.false)}));var g=h(p("Property"),p("PropertyPattern"),p("SpreadPropertyPattern"),p("SpreadProperty"),p("ObjectProperty"),p("RestProperty"),p("RestElement"));p("ObjectPattern").bases("Pattern").build("properties").field("properties",[g]).field("decorators",h([p("Decorator")],null),u.null),p("SpreadProperty").bases("Node").build("argument").field("argument",p("Expression")),p("RestProperty").bases("Node").build("argument").field("argument",p("Expression")),p("ForAwaitStatement").bases("Statement").build("left","right","body").field("left",h(p("VariableDeclaration"),p("Expression"))).field("right",p("Expression")).field("body",p("Statement")),p("Import").bases("Expression").build()},(0,a.maybeSetModuleExports)((function(){return e}))}(Dr,Dr.exports)),Dr.exports}var jr,Mr,Br,Fr={exports:{}},Vr={};function Rr(){return Br||(Br=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.visit=e.use=e.Type=e.someField=e.PathVisitor=e.Path=e.NodePath=e.namedTypes=e.getSupertypeNames=e.getFieldValue=e.getFieldNames=e.getBuilderName=e.finalize=e.eachField=e.defineMethod=e.builtInTypes=e.builders=e.astNodesAreEquivalent=void 0;var t=Sn,n=t.__importDefault((Vn||(Vn=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(wn()),i=n.__importDefault((jn||(jn=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(wn()),i=n.__importDefault(Bn()),a=Pn(),s=Object.prototype.hasOwnProperty;t.default=function(e){var t=e.use(r.default),n=e.use(i.default),a=t.builtInTypes.array,o=t.builtInTypes.object,l=t.builtInTypes.function,c=function e(){if(!(this instanceof e))throw Error("PathVisitor constructor cannot be invoked without 'new'");this._reusableContextStack=[],this._methodNameTable=function(e){var n=Object.create(null);for(var r in e)/^visit[A-Z]/.test(r)&&(n[r.slice(5)]=!0);for(var i=t.computeSupertypeLookupTable(n),a=Object.create(null),s=Object.keys(i),o=s.length,c=0;c<o;++c){var u=s[c];r="visit"+i[u],l.check(e[r])&&(a[u]=r)}return a}(this),this._shouldVisitComments=s.call(this._methodNameTable,"Block")||s.call(this._methodNameTable,"Line"),this.Context=d(this),this._visiting=!1,this._changeReported=!1};function u(e,t){for(var n in t)s.call(t,n)&&(e[n]=t[n]);return e}c.fromMethodsObject=function(e){if(e instanceof c)return e;if(!o.check(e))return new c;var t=function e(){if(!(this instanceof e))throw Error("Visitor constructor cannot be invoked without 'new'");c.call(this)},n=t.prototype=Object.create(p);return n.constructor=t,u(n,e),u(t,c),l.assert(t.fromMethodsObject),l.assert(t.visit),new t},c.visit=function(e,t){return c.fromMethodsObject(t).visit(e)};var p=c.prototype;function h(e,r){if(!(e instanceof n))throw Error("");if(!(r instanceof c))throw Error("");var i=e.value;if(a.check(i))e.each(r.visitWithoutReset,r);else if(o.check(i)){var l=t.getFieldNames(i);r._shouldVisitComments&&i.comments&&l.indexOf("comments")<0&&l.push("comments");for(var u=l.length,p=[],h=0;h<u;++h){var d=l[h];s.call(i,d)||(i[d]=t.getFieldValue(i,d)),p.push(e.get(d))}for(h=0;h<u;++h)r.visitWithoutReset(p[h])}return e.value}function d(e){function t(r){if(!(this instanceof t))throw Error("");if(!(this instanceof c))throw Error("");if(!(r instanceof n))throw Error("");Object.defineProperty(this,"visitor",{value:e,writable:!1,enumerable:!0,configurable:!1}),this.currentPath=r,this.needToCallTraverse=!0,Object.seal(this)}if(!(e instanceof c))throw Error("");var r=t.prototype=Object.create(e);return r.constructor=t,u(r,f),t}p.visit=function(){if(this._visiting)throw Error("Recursively calling visitor.visit(path) resets visitor state. Try this.visit(path) or this.traverse(path) instead.");this._visiting=!0,this._changeReported=!1,this._abortRequested=!1;for(var e,t=arguments.length,r=Array(t),i=0;i<t;++i)r[i]=arguments[i];r[0]instanceof n||(r[0]=new n({root:r[0]}).get("root")),this.reset.apply(this,r);try{var a=this.visitWithoutReset(r[0]);e=!0}finally{if(this._visiting=!1,!e&&this._abortRequested)return r[0].value}return a},p.AbortRequest=function(){},p.abort=function(){var e=this;e._abortRequested=!0;var t=new e.AbortRequest;throw t.cancel=function(){e._abortRequested=!1},t},p.reset=function(e){},p.visitWithoutReset=function(e){if(this instanceof this.Context)return this.visitor.visitWithoutReset(e);if(!(e instanceof n))throw Error("");var t=e.value,r=t&&"object"==typeof t&&"string"==typeof t.type&&this._methodNameTable[t.type];if(!r)return h(e,this);var i=this.acquireContext(e);try{return i.invokeVisitorMethod(r)}finally{this.releaseContext(i)}},p.acquireContext=function(e){return 0===this._reusableContextStack.length?new this.Context(e):this._reusableContextStack.pop().reset(e)},p.releaseContext=function(e){if(!(e instanceof this.Context))throw Error("");this._reusableContextStack.push(e),e.currentPath=null},p.reportChanged=function(){this._changeReported=!0},p.wasChangeReported=function(){return this._changeReported};var f=Object.create(null);return f.reset=function(e){if(!(this instanceof this.Context))throw Error("");if(!(e instanceof n))throw Error("");return this.currentPath=e,this.needToCallTraverse=!0,this},f.invokeVisitorMethod=function(e){if(!(this instanceof this.Context))throw Error("");if(!(this.currentPath instanceof n))throw Error("");var t=this.visitor[e].call(this,this.currentPath);if(!1===t?this.needToCallTraverse=!1:void 0!==t&&(this.currentPath=this.currentPath.replace(t)[0],this.needToCallTraverse&&this.traverse(this.currentPath)),!1!==this.needToCallTraverse)throw Error("Must either call this.traverse or return false in "+e);var r=this.currentPath;return r&&r.value},f.traverse=function(e,t){if(!(this instanceof this.Context))throw Error("");if(!(e instanceof n))throw Error("");if(!(this.currentPath instanceof n))throw Error("");return this.needToCallTraverse=!1,h(e,c.fromMethodsObject(t||this.visitor))},f.visit=function(e,t){if(!(this instanceof this.Context))throw Error("");if(!(e instanceof n))throw Error("");if(!(this.currentPath instanceof n))throw Error("");return this.needToCallTraverse=!1,c.fromMethodsObject(t||this.visitor).visitWithoutReset(e)},f.reportChanged=function(){this.visitor.reportChanged()},f.abort=function(){this.needToCallTraverse=!1,this.visitor.abort()},c},(0,a.maybeSetModuleExports)((function(){return e}))}(Cn,Cn.exports)),Cn.exports)),a=n.__importDefault(qn()),s=n.__importDefault(On()),o=n.__importDefault(Bn()),l=Pn();t.default=function(e){var t=function(){var e=[],t=[],n={use:function(r){var i=e.indexOf(r);return-1===i&&(i=e.length,e.push(r),t[i]=r(n)),t[i]}};return n}(),n=t.use(r.default);e.forEach(t.use),n.finalize();var l=t.use(i.default);return{Type:n.Type,builtInTypes:n.builtInTypes,namedTypes:n.namedTypes,builders:n.builders,defineMethod:n.defineMethod,getFieldNames:n.getFieldNames,getFieldValue:n.getFieldValue,eachField:n.eachField,someField:n.someField,getSupertypeNames:n.getSupertypeNames,getBuilderName:n.getBuilderName,astNodesAreEquivalent:t.use(a.default),finalize:n.finalize,Path:t.use(s.default),NodePath:t.use(o.default),PathVisitor:l,use:t.use,visit:l.visit}},(0,l.maybeSetModuleExports)((function(){return e}))}(Tn,Tn.exports)),Tn.exports)),r=t.__importDefault(vr()),i=t.__importDefault((xr||(xr=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(vr()),i=n.__importDefault(wn()),a=n.__importStar(Pn());t.default=function(e){e.use(r.default);var t=e.use(i.default),n=t.Type.def,s=t.Type.or,o=e.use(a.default).defaults;n("JSXAttribute").bases("Node").build("name","value").field("name",s(n("JSXIdentifier"),n("JSXNamespacedName"))).field("value",s(n("Literal"),n("JSXExpressionContainer"),n("JSXElement"),n("JSXFragment"),null),o.null),n("JSXIdentifier").bases("Identifier").build("name").field("name",String),n("JSXNamespacedName").bases("Node").build("namespace","name").field("namespace",n("JSXIdentifier")).field("name",n("JSXIdentifier")),n("JSXMemberExpression").bases("MemberExpression").build("object","property").field("object",s(n("JSXIdentifier"),n("JSXMemberExpression"))).field("property",n("JSXIdentifier")).field("computed",Boolean,o.false);var l=s(n("JSXIdentifier"),n("JSXNamespacedName"),n("JSXMemberExpression"));n("JSXSpreadAttribute").bases("Node").build("argument").field("argument",n("Expression"));var c=[s(n("JSXAttribute"),n("JSXSpreadAttribute"))];n("JSXExpressionContainer").bases("Expression").build("expression").field("expression",s(n("Expression"),n("JSXEmptyExpression")));var u=[s(n("JSXText"),n("JSXExpressionContainer"),n("JSXSpreadChild"),n("JSXElement"),n("JSXFragment"),n("Literal"))];n("JSXElement").bases("Expression").build("openingElement","closingElement","children").field("openingElement",n("JSXOpeningElement")).field("closingElement",s(n("JSXClosingElement"),null),o.null).field("children",u,o.emptyArray).field("name",l,(function(){return this.openingElement.name}),!0).field("selfClosing",Boolean,(function(){return this.openingElement.selfClosing}),!0).field("attributes",c,(function(){return this.openingElement.attributes}),!0),n("JSXOpeningElement").bases("Node").build("name","attributes","selfClosing").field("name",l).field("attributes",c,o.emptyArray).field("selfClosing",Boolean,o.false),n("JSXClosingElement").bases("Node").build("name").field("name",l),n("JSXFragment").bases("Expression").build("openingFragment","closingFragment","children").field("openingFragment",n("JSXOpeningFragment")).field("closingFragment",n("JSXClosingFragment")).field("children",u,o.emptyArray),n("JSXOpeningFragment").bases("Node").build(),n("JSXClosingFragment").bases("Node").build(),n("JSXText").bases("Literal").build("value","raw").field("value",String).field("raw",String,(function(){return this.value})),n("JSXEmptyExpression").bases("Node").build(),n("JSXSpreadChild").bases("Node").build("expression").field("expression",n("Expression"))},(0,a.maybeSetModuleExports)((function(){return e}))}(Tr,Tr.exports)),Tr.exports)),a=t.__importDefault(wr()),s=t.__importDefault((Ar||(Ar=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(vr()),i=n.__importDefault(wn()),a=n.__importStar(Pn());t.default=function(e){e.use(r.default);var t=e.use(i.default),n=e.use(a.default).defaults,s=t.Type.def,o=t.Type.or;s("VariableDeclaration").field("declarations",[o(s("VariableDeclarator"),s("Identifier"))]),s("Property").field("value",o(s("Expression"),s("Pattern"))),s("ArrayPattern").field("elements",[o(s("Pattern"),s("SpreadElement"),null)]),s("ObjectPattern").field("properties",[o(s("Property"),s("PropertyPattern"),s("SpreadPropertyPattern"),s("SpreadProperty"))]),s("ExportSpecifier").bases("ModuleSpecifier").build("id","name"),s("ExportBatchSpecifier").bases("Specifier").build(),s("ExportDeclaration").bases("Declaration").build("default","declaration","specifiers","source").field("default",Boolean).field("declaration",o(s("Declaration"),s("Expression"),null)).field("specifiers",[o(s("ExportSpecifier"),s("ExportBatchSpecifier"))],n.emptyArray).field("source",o(s("Literal"),null),n.null),s("Block").bases("Comment").build("value","leading","trailing"),s("Line").bases("Comment").build("value","leading","trailing")},(0,a.maybeSetModuleExports)((function(){return e}))}(Nr,Nr.exports)),Nr.exports)),o=t.__importDefault((Ir||(Ir=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(wn()),i=n.__importDefault(Lr()),a=n.__importDefault(wr()),s=Pn();t.default=function(e){var t=e.use(r.default).Type.def;e.use(i.default),e.use(a.default),t("V8IntrinsicIdentifier").bases("Expression").build("name").field("name",String),t("TopicReference").bases("Expression").build()},(0,s.maybeSetModuleExports)((function(){return e}))}(Or,Or.exports)),Or.exports)),l=t.__importDefault((jr||(jr=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=Sn,r=n.__importDefault(Lr()),i=n.__importDefault(Pr()),a=n.__importDefault(wn()),s=n.__importStar(Pn());t.default=function(e){e.use(r.default),e.use(i.default);var t=e.use(a.default),n=t.namedTypes,o=t.Type.def,l=t.Type.or,c=e.use(s.default).defaults,u=t.Type.from((function(e,t){return!(!n.StringLiteral||!n.StringLiteral.check(e,t))||!(!n.Literal||!n.Literal.check(e,t)||"string"!=typeof e.value)}),"StringLiteral");o("TSType").bases("Node");var p=l(o("Identifier"),o("TSQualifiedName"));o("TSTypeReference").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("typeName","typeParameters").field("typeName",p),o("TSHasOptionalTypeParameterInstantiation").field("typeParameters",l(o("TSTypeParameterInstantiation"),null),c.null),o("TSHasOptionalTypeParameters").field("typeParameters",l(o("TSTypeParameterDeclaration"),null,void 0),c.null),o("TSHasOptionalTypeAnnotation").field("typeAnnotation",l(o("TSTypeAnnotation"),null),c.null),o("TSQualifiedName").bases("Node").build("left","right").field("left",p).field("right",p),o("TSAsExpression").bases("Expression","Pattern").build("expression","typeAnnotation").field("expression",o("Expression")).field("typeAnnotation",o("TSType")).field("extra",l({parenthesized:Boolean},null),c.null),o("TSTypeCastExpression").bases("Expression").build("expression","typeAnnotation").field("expression",o("Expression")).field("typeAnnotation",o("TSType")),o("TSSatisfiesExpression").bases("Expression","Pattern").build("expression","typeAnnotation").field("expression",o("Expression")).field("typeAnnotation",o("TSType")),o("TSNonNullExpression").bases("Expression","Pattern").build("expression").field("expression",o("Expression")),["TSAnyKeyword","TSBigIntKeyword","TSBooleanKeyword","TSNeverKeyword","TSNullKeyword","TSNumberKeyword","TSObjectKeyword","TSStringKeyword","TSSymbolKeyword","TSUndefinedKeyword","TSUnknownKeyword","TSVoidKeyword","TSIntrinsicKeyword","TSThisType"].forEach((function(e){o(e).bases("TSType").build()})),o("TSArrayType").bases("TSType").build("elementType").field("elementType",o("TSType")),o("TSLiteralType").bases("TSType").build("literal").field("literal",l(o("NumericLiteral"),o("StringLiteral"),o("BooleanLiteral"),o("TemplateLiteral"),o("UnaryExpression"),o("BigIntLiteral"))),o("TemplateLiteral").field("expressions",l([o("Expression")],[o("TSType")])),["TSUnionType","TSIntersectionType"].forEach((function(e){o(e).bases("TSType").build("types").field("types",[o("TSType")])})),o("TSConditionalType").bases("TSType").build("checkType","extendsType","trueType","falseType").field("checkType",o("TSType")).field("extendsType",o("TSType")).field("trueType",o("TSType")).field("falseType",o("TSType")),o("TSInferType").bases("TSType").build("typeParameter").field("typeParameter",o("TSTypeParameter")),o("TSParenthesizedType").bases("TSType").build("typeAnnotation").field("typeAnnotation",o("TSType"));var h=[l(o("Identifier"),o("RestElement"),o("ArrayPattern"),o("ObjectPattern"))];["TSFunctionType","TSConstructorType"].forEach((function(e){o(e).bases("TSType","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("parameters").field("parameters",h)})),o("TSDeclareFunction").bases("Declaration","TSHasOptionalTypeParameters").build("id","params","returnType").field("declare",Boolean,c.false).field("async",Boolean,c.false).field("generator",Boolean,c.false).field("id",l(o("Identifier"),null),c.null).field("params",[o("Pattern")]).field("returnType",l(o("TSTypeAnnotation"),o("Noop"),null),c.null),o("TSDeclareMethod").bases("Declaration","TSHasOptionalTypeParameters").build("key","params","returnType").field("async",Boolean,c.false).field("generator",Boolean,c.false).field("params",[o("Pattern")]).field("abstract",Boolean,c.false).field("accessibility",l("public","private","protected",void 0),c[void 0]).field("static",Boolean,c.false).field("computed",Boolean,c.false).field("optional",Boolean,c.false).field("key",l(o("Identifier"),o("StringLiteral"),o("NumericLiteral"),o("Expression"))).field("kind",l("get","set","method","constructor"),(function(){return"method"})).field("access",l("public","private","protected",void 0),c[void 0]).field("decorators",l([o("Decorator")],null),c.null).field("returnType",l(o("TSTypeAnnotation"),o("Noop"),null),c.null),o("TSMappedType").bases("TSType").build("typeParameter","typeAnnotation").field("readonly",l(Boolean,"+","-"),c.false).field("typeParameter",o("TSTypeParameter")).field("optional",l(Boolean,"+","-"),c.false).field("typeAnnotation",l(o("TSType"),null),c.null),o("TSTupleType").bases("TSType").build("elementTypes").field("elementTypes",[l(o("TSType"),o("TSNamedTupleMember"))]),o("TSNamedTupleMember").bases("TSType").build("label","elementType","optional").field("label",o("Identifier")).field("optional",Boolean,c.false).field("elementType",o("TSType")),o("TSRestType").bases("TSType").build("typeAnnotation").field("typeAnnotation",o("TSType")),o("TSOptionalType").bases("TSType").build("typeAnnotation").field("typeAnnotation",o("TSType")),o("TSIndexedAccessType").bases("TSType").build("objectType","indexType").field("objectType",o("TSType")).field("indexType",o("TSType")),o("TSTypeOperator").bases("TSType").build("operator").field("operator",String).field("typeAnnotation",o("TSType")),o("TSTypeAnnotation").bases("Node").build("typeAnnotation").field("typeAnnotation",l(o("TSType"),o("TSTypeAnnotation"))),o("TSIndexSignature").bases("Declaration","TSHasOptionalTypeAnnotation").build("parameters","typeAnnotation").field("parameters",[o("Identifier")]).field("readonly",Boolean,c.false),o("TSPropertySignature").bases("Declaration","TSHasOptionalTypeAnnotation").build("key","typeAnnotation","optional").field("key",o("Expression")).field("computed",Boolean,c.false).field("readonly",Boolean,c.false).field("optional",Boolean,c.false).field("initializer",l(o("Expression"),null),c.null),o("TSMethodSignature").bases("Declaration","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("key","parameters","typeAnnotation").field("key",o("Expression")).field("computed",Boolean,c.false).field("optional",Boolean,c.false).field("parameters",h),o("TSTypePredicate").bases("TSTypeAnnotation","TSType").build("parameterName","typeAnnotation","asserts").field("parameterName",l(o("Identifier"),o("TSThisType"))).field("typeAnnotation",l(o("TSTypeAnnotation"),null),c.null).field("asserts",Boolean,c.false),["TSCallSignatureDeclaration","TSConstructSignatureDeclaration"].forEach((function(e){o(e).bases("Declaration","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("parameters","typeAnnotation").field("parameters",h)})),o("TSEnumMember").bases("Node").build("id","initializer").field("id",l(o("Identifier"),u)).field("initializer",l(o("Expression"),null),c.null),o("TSTypeQuery").bases("TSType").build("exprName").field("exprName",l(p,o("TSImportType")));var d=l(o("TSCallSignatureDeclaration"),o("TSConstructSignatureDeclaration"),o("TSIndexSignature"),o("TSMethodSignature"),o("TSPropertySignature"));o("TSTypeLiteral").bases("TSType").build("members").field("members",[d]),o("TSTypeParameter").bases("Identifier").build("name","constraint","default").field("name",l(o("Identifier"),String)).field("constraint",l(o("TSType"),void 0),c[void 0]).field("default",l(o("TSType"),void 0),c[void 0]),o("TSTypeAssertion").bases("Expression","Pattern").build("typeAnnotation","expression").field("typeAnnotation",o("TSType")).field("expression",o("Expression")).field("extra",l({parenthesized:Boolean},null),c.null),o("TSTypeParameterDeclaration").bases("Declaration").build("params").field("params",[o("TSTypeParameter")]),o("TSInstantiationExpression").bases("Expression","TSHasOptionalTypeParameterInstantiation").build("expression","typeParameters").field("expression",o("Expression")),o("TSTypeParameterInstantiation").bases("Node").build("params").field("params",[o("TSType")]),o("TSEnumDeclaration").bases("Declaration").build("id","members").field("id",o("Identifier")).field("const",Boolean,c.false).field("declare",Boolean,c.false).field("members",[o("TSEnumMember")]).field("initializer",l(o("Expression"),null),c.null),o("TSTypeAliasDeclaration").bases("Declaration","TSHasOptionalTypeParameters").build("id","typeAnnotation").field("id",o("Identifier")).field("declare",Boolean,c.false).field("typeAnnotation",o("TSType")),o("TSModuleBlock").bases("Node").build("body").field("body",[o("Statement")]),o("TSModuleDeclaration").bases("Declaration").build("id","body").field("id",l(u,p)).field("declare",Boolean,c.false).field("global",Boolean,c.false).field("body",l(o("TSModuleBlock"),o("TSModuleDeclaration"),null),c.null),o("TSImportType").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("argument","qualifier","typeParameters").field("argument",u).field("qualifier",l(p,void 0),c[void 0]),o("TSImportEqualsDeclaration").bases("Declaration").build("id","moduleReference").field("id",o("Identifier")).field("isExport",Boolean,c.false).field("moduleReference",l(p,o("TSExternalModuleReference"))),o("TSExternalModuleReference").bases("Declaration").build("expression").field("expression",u),o("TSExportAssignment").bases("Statement").build("expression").field("expression",o("Expression")),o("TSNamespaceExportDeclaration").bases("Declaration").build("id").field("id",o("Identifier")),o("TSInterfaceBody").bases("Node").build("body").field("body",[d]),o("TSExpressionWithTypeArguments").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("expression","typeParameters").field("expression",p),o("TSInterfaceDeclaration").bases("Declaration","TSHasOptionalTypeParameters").build("id","body").field("id",p).field("declare",Boolean,c.false).field("extends",l([o("TSExpressionWithTypeArguments")],null),c.null).field("body",o("TSInterfaceBody")),o("TSParameterProperty").bases("Pattern").build("parameter").field("accessibility",l("public","private","protected",void 0),c[void 0]).field("readonly",Boolean,c.false).field("parameter",l(o("Identifier"),o("AssignmentPattern"))),o("ClassProperty").field("access",l("public","private","protected",void 0),c[void 0]),o("ClassAccessorProperty").bases("Declaration","TSHasOptionalTypeAnnotation"),o("ClassBody").field("body",[l(o("MethodDefinition"),o("VariableDeclarator"),o("ClassPropertyDefinition"),o("ClassProperty"),o("ClassPrivateProperty"),o("ClassAccessorProperty"),o("ClassMethod"),o("ClassPrivateMethod"),o("StaticBlock"),o("TSDeclareMethod"),d)])},(0,s.maybeSetModuleExports)((function(){return e}))}(Fr,Fr.exports)),Fr.exports)),c=(Mr||(Mr=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.namedTypes=void 0,e.namedTypes||(e.namedTypes={})}(Vr)),Vr);Object.defineProperty(e,"namedTypes",{enumerable:!0,get:function(){return c.namedTypes}});var u=(0,n.default)([r.default,i.default,a.default,s.default,o.default,l.default]),p=u.astNodesAreEquivalent,h=u.builders,d=u.builtInTypes,f=u.defineMethod,m=u.eachField,y=u.finalize,g=u.getBuilderName,b=u.getFieldNames,v=u.getFieldValue,x=u.getSupertypeNames,S=u.namedTypes,E=u.NodePath,T=u.Path,_=u.PathVisitor,k=u.someField,P=u.Type,w=u.use,A=u.visit;e.astNodesAreEquivalent=p,e.builders=h,e.builtInTypes=d,e.defineMethod=f,e.eachField=m,e.finalize=y,e.getBuilderName=g,e.getFieldNames=b,e.getFieldValue=v,e.getSupertypeNames=x,e.NodePath=E,e.Path=T,e.PathVisitor=_,e.someField=k,e.Type=P,e.use=w,e.visit=A,Object.assign(c.namedTypes,S)}(En)),En}var qr,Ur,zr={};function Wr(){return Ur?qr:(Ur=1,qr=function(e,t){if(!e)throw Error("Invariant failed")})}var Gr={},Jr={};const $r=function(){},Hr=function(){return{addMapping:$r,setSourceContent:$r,toJSON:()=>({})}},Kr=function(){},Xr=function(){};var Yr,Qr=Ft(Object.freeze({__proto__:null,SourceMapConsumer:Kr,SourceMapGenerator:Hr,SourceNode:Xr,default:{SourceNode:Xr,SourceMapConsumer:Kr,SourceMapGenerator:Hr}})),Zr=Ft(Object.freeze({__proto__:null,EOL:"\n"}));function ei(){if(Yr)return Jr;Yr=1,Object.defineProperty(Jr,"__esModule",{value:!0}),Jr.isTrailingCommaEnabled=Jr.getParentExportDeclaration=Jr.isExportDeclaration=Jr.fixFaultyLocations=Jr.getTrueLoc=Jr.composeSourceMaps=Jr.copyPos=Jr.comparePos=Jr.getUnionOfKeys=Jr.getOption=Jr.isBrowser=Jr.getLineTerminator=void 0;var e=Sn,t=e.__importDefault(Wr()),n=e.__importStar(Rr()).namedTypes,r=e.__importDefault(Qr),i=r.default.SourceMapConsumer,a=r.default.SourceMapGenerator,s=Object.prototype.hasOwnProperty;function o(){return"undefined"!=typeof window&&void 0!==window.document}function l(e,t){return e.line-t.line||e.column-t.column}function c(e){return{line:e.line,column:e.column}}function u(e,t){e&&t&&(l(t.start,e.start)<0&&(e.start=t.start),l(e.end,t.end)<0&&(e.end=t.end))}function p(e){if(e)switch(e.type){case"ExportDeclaration":case"ExportDefaultDeclaration":case"ExportDefaultSpecifier":case"DeclareExportDeclaration":case"ExportNamedDeclaration":case"ExportAllDeclaration":return!0}return!1}return Jr.getLineTerminator=function(){return o()?"\n":Zr.EOL||"\n"},Jr.isBrowser=o,Jr.getOption=function(e,t,n){return e&&s.call(e,t)?e[t]:n},Jr.getUnionOfKeys=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n={},r=e.length,i=0;i<r;++i)for(var a=Object.keys(e[i]),s=a.length,o=0;o<s;++o)n[a[o]]=!0;return n},Jr.comparePos=l,Jr.copyPos=c,Jr.composeSourceMaps=function(e,t){if(!e)return t||null;if(!t)return e;var n=new i(e),r=new i(t),o=new a({file:t.file,sourceRoot:t.sourceRoot}),l={};return r.eachMapping((function(e){var t=n.originalPositionFor({line:e.originalLine,column:e.originalColumn}),r=t.source;if(null!==r){o.addMapping({source:r,original:c(t),generated:{line:e.generatedLine,column:e.generatedColumn},name:e.name});var i=n.sourceContentFor(r);i&&!s.call(l,r)&&(l[r]=i,o.setSourceContent(r,i))}})),o.toJSON()},Jr.getTrueLoc=function(e,t){if(!e.loc)return null;var n={start:e.loc.start,end:e.loc.end};function r(e){u(n,e.loc)}return e.declaration&&e.declaration.decorators&&p(e)&&e.declaration.decorators.forEach(r),l(n.start,n.end)<0&&(n.start=c(n.start),t.skipSpaces(n.start,!1,!0),l(n.start,n.end)<0&&(n.end=c(n.end),t.skipSpaces(n.end,!0,!0))),e.comments&&e.comments.forEach(r),n},Jr.fixFaultyLocations=function(e,r){var i=e.loc;if(i&&(i.start.line<1&&(i.start.line=1),i.end.line<1&&(i.end.line=1)),"File"===e.type&&(i.start=r.firstPos(),i.end=r.lastPos()),function(e,t){function n(e){for(var n=e&&e.loc,r=n&&n.start,i=n&&c(n.end);r&&i&&l(r,i)<0&&(t.prevPos(i),";"===t.charAt(i));)n.end.line=i.line,n.end.column=i.column}"ForStatement"===e.type&&(n(e.init),n(e.test),n(e.update))}(e,r),function(e,n){if("TemplateLiteral"===e.type&&0!==e.quasis.length){if(e.loc){var r=c(e.loc.start);(0,t.default)("`"===n.charAt(r)),(0,t.default)(n.nextPos(r));var i=e.quasis[0];l(i.loc.start,r)<0&&(i.loc.start=r);var a=c(e.loc.end);(0,t.default)(n.prevPos(a)),(0,t.default)("`"===n.charAt(a));var s=e.quasis[e.quasis.length-1];l(a,s.loc.end)<0&&(s.loc.end=a)}e.expressions.forEach((function(r,i){var a=n.skipSpaces(r.loc.start,!0,!1);if(n.prevPos(a)&&"{"===n.charAt(a)&&n.prevPos(a)&&"$"===n.charAt(a)){var s=e.quasis[i];l(a,s.loc.end)<0&&(s.loc.end=a)}var o=n.skipSpaces(r.loc.end,!1,!1);if("}"===n.charAt(o)){(0,t.default)(n.nextPos(o));var c=e.quasis[i+1];l(c.loc.start,o)<0&&(c.loc.start=o)}}))}}(e,r),i&&e.decorators)e.decorators.forEach((function(e){u(i,e.loc)}));else if(e.declaration&&p(e)){e.declaration.loc=null;var a=e.declaration.decorators;a&&a.forEach((function(e){u(i,e.loc)}))}else if(n.MethodDefinition&&n.MethodDefinition.check(e)||n.Property.check(e)&&(e.method||e.shorthand))e.value.loc=null,n.FunctionExpression.check(e.value)&&(e.value.id=null);else if("ObjectTypeProperty"===e.type){var s=e.loc,o=s&&s.end;o&&(o=c(o),r.prevPos(o)&&","===r.charAt(o)&&(o=r.skipSpaces(o,!0,!0))&&(s.end=o))}},Jr.isExportDeclaration=p,Jr.getParentExportDeclaration=function(e){var t=e.getParentNode();return"declaration"===e.getName()&&p(t)?t:null},Jr.isTrailingCommaEnabled=function(e,t){var n=e.trailingComma;return"object"==typeof n?!!n[t]:!!n},Jr}var ti,ni,ri={},ii=void 0;function ai(){if(ti)return ri;ti=1,Object.defineProperty(ri,"__esModule",{value:!0}),ri.parse=void 0;var e=ei();return ri.parse=function(t,n){var r=[],i=ii.parse(t,{loc:!0,locations:!0,comment:!0,onComment:r,range:(0,e.getOption)(n,"range",!1),tolerant:(0,e.getOption)(n,"tolerant",!0),tokens:!0,jsx:(0,e.getOption)(n,"jsx",!1),sourceType:(0,e.getOption)(n,"sourceType","module")});return Array.isArray(i.comments)||(i.comments=r),i},ri}function si(){if(ni)return Gr;ni=1,Object.defineProperty(Gr,"__esModule",{value:!0}),Gr.normalize=void 0;var e=ei(),t={parser:ai(),tabWidth:4,useTabs:!1,reuseWhitespace:!0,lineTerminator:(0,e.getLineTerminator)(),wrapColumn:74,sourceFileName:null,sourceMapName:null,sourceRoot:null,inputSourceMap:null,range:!1,tolerant:!0,quote:null,trailingComma:!1,arrayBracketSpacing:!1,objectCurlySpacing:!0,arrowParensAlways:!1,flowObjectCommas:!0,tokens:!0},n=t.hasOwnProperty;return Gr.normalize=function(e){var r=e||t;function i(e){return n.call(r,e)?r[e]:t[e]}return{tabWidth:+i("tabWidth"),useTabs:!!i("useTabs"),reuseWhitespace:!!i("reuseWhitespace"),lineTerminator:i("lineTerminator"),wrapColumn:Math.max(i("wrapColumn"),0),sourceFileName:i("sourceFileName"),sourceMapName:i("sourceMapName"),sourceRoot:i("sourceRoot"),inputSourceMap:i("inputSourceMap"),parser:i("esprima")||i("parser"),range:i("range"),tolerant:i("tolerant"),quote:i("quote"),trailingComma:i("trailingComma"),arrayBracketSpacing:i("arrayBracketSpacing"),objectCurlySpacing:i("objectCurlySpacing"),arrowParensAlways:i("arrowParensAlways"),flowObjectCommas:i("flowObjectCommas"),tokens:!!i("tokens")}},Gr}var oi,li,ci={},ui={};function pi(){if(li)return ci;li=1,Object.defineProperty(ci,"__esModule",{value:!0}),ci.concat=ci.fromString=ci.countSpaces=ci.Lines=void 0;var e=Sn,t=e.__importDefault(Wr()),n=e.__importDefault(Qr),r=si(),i=ei(),a=e.__importDefault(function(){if(oi)return ui;oi=1,Object.defineProperty(ui,"__esModule",{value:!0});var e=Sn.__importDefault(Wr()),t=ei(),n=function(){function n(e,t,n){void 0===n&&(n=t),this.sourceLines=e,this.sourceLoc=t,this.targetLoc=n}return n.prototype.slice=function(r,a,s){void 0===s&&(s=r.lastPos());var o=this.sourceLines,l=this.sourceLoc,c=this.targetLoc;function u(n){var i=l[n],u=c[n],p=a;return"end"===n?p=s:(0,e.default)("start"===n),function(n,r,i,a,s){var o,l,c=(0,t.comparePos)(a,s);if(0===c)return r;if(c<0){o=n.skipSpaces(r)||n.lastPos(),l=i.skipSpaces(a)||i.lastPos();var u=s.line-l.line;for(o.line+=u,l.line+=u,u>0?(o.column=0,l.column=0):(0,e.default)(0===u);(0,t.comparePos)(l,s)<0&&i.nextPos(l,!0);)(0,e.default)(n.nextPos(o,!0)),(0,e.default)(n.charAt(o)===i.charAt(l))}else for(o=n.skipSpaces(r,!0)||n.firstPos(),l=i.skipSpaces(a,!0)||i.firstPos(),u=s.line-l.line,o.line+=u,l.line+=u,u<0?(o.column=n.getLineLength(o.line),l.column=i.getLineLength(l.line)):(0,e.default)(0===u);(0,t.comparePos)(s,l)<0&&i.prevPos(l,!0);)(0,e.default)(n.prevPos(o,!0)),(0,e.default)(n.charAt(o)===i.charAt(l));return o}(o,i,r,u,p)}if((0,t.comparePos)(a,c.start)<=0)if((0,t.comparePos)(c.end,s)<=0)c={start:i(c.start,a.line,a.column),end:i(c.end,a.line,a.column)};else{if((0,t.comparePos)(s,c.start)<=0)return null;l={start:l.start,end:u("end")},c={start:i(c.start,a.line,a.column),end:i(s,a.line,a.column)}}else{if((0,t.comparePos)(c.end,a)<=0)return null;(0,t.comparePos)(c.end,s)<=0?(l={start:u("start"),end:l.end},c={start:{line:1,column:0},end:i(c.end,a.line,a.column)}):(l={start:u("start"),end:u("end")},c={start:{line:1,column:0},end:i(s,a.line,a.column)})}return new n(this.sourceLines,l,c)},n.prototype.add=function(e,t){return new n(this.sourceLines,this.sourceLoc,{start:r(this.targetLoc.start,e,t),end:r(this.targetLoc.end,e,t)})},n.prototype.subtract=function(e,t){return new n(this.sourceLines,this.sourceLoc,{start:i(this.targetLoc.start,e,t),end:i(this.targetLoc.end,e,t)})},n.prototype.indent=function(e,t,r){if(void 0===t&&(t=!1),void 0===r&&(r=!1),0===e)return this;var i=this.targetLoc,a=i.start.line,s=i.end.line;if(t&&1===a&&1===s)return this;if(i={start:i.start,end:i.end},!t||a>1){var o=i.start.column+e;i.start={line:a,column:r?Math.max(0,o):o}}if(!t||s>1){var l=i.end.column+e;i.end={line:s,column:r?Math.max(0,l):l}}return new n(this.sourceLines,this.sourceLoc,i)},n}();function r(e,t,n){return{line:e.line+t-1,column:1===e.line?e.column+n:e.column}}function i(e,t,n){return{line:e.line-t+1,column:e.line===t?e.column-n:e.column}}return ui.default=n,ui}()),s=function(){function s(e,n){void 0===n&&(n=null),this.infos=e,this.mappings=[],this.cachedSourceMap=null,this.cachedTabWidth=void 0,(0,t.default)(e.length>0),this.length=e.length,this.name=n||null,this.name&&this.mappings.push(new a.default(this,{start:this.firstPos(),end:this.lastPos()}))}return s.prototype.toString=function(e){return this.sliceString(this.firstPos(),this.lastPos(),e)},s.prototype.getSourceMap=function(e,r){if(!e)return null;var a=this;function s(t){return(t=t||{}).file=e,r&&(t.sourceRoot=r),t}if(a.cachedSourceMap)return s(a.cachedSourceMap.toJSON());var o=new n.default.SourceMapGenerator(s()),c={};return a.mappings.forEach((function(e){for(var n=e.sourceLines.skipSpaces(e.sourceLoc.start)||e.sourceLines.lastPos(),r=a.skipSpaces(e.targetLoc.start)||a.lastPos();(0,i.comparePos)(n,e.sourceLoc.end)<0&&(0,i.comparePos)(r,e.targetLoc.end)<0;){var s=e.sourceLines.charAt(n),u=a.charAt(r);(0,t.default)(s===u);var p=e.sourceLines.name;if(o.addMapping({source:p,original:{line:n.line,column:n.column},generated:{line:r.line,column:r.column}}),!l.call(c,p)){var h=e.sourceLines.toString();o.setSourceContent(p,h),c[p]=h}a.nextPos(r,!0),e.sourceLines.nextPos(n,!0)}})),a.cachedSourceMap=o,o.toJSON()},s.prototype.bootstrapCharAt=function(e){(0,t.default)("object"==typeof e),(0,t.default)("number"==typeof e.line),(0,t.default)("number"==typeof e.column);var n=e.line,r=e.column,i=this.toString().split(h),a=i[n-1];return void 0===a?"":r===a.length&&n<i.length?"\n":r>=a.length?"":a.charAt(r)},s.prototype.charAt=function(e){(0,t.default)("object"==typeof e),(0,t.default)("number"==typeof e.line),(0,t.default)("number"==typeof e.column);var n=e.line,r=e.column,i=this.infos[n-1],a=r;if(void 0===i||a<0)return"";var s=this.getIndentAt(n);return a<s?" ":(a+=i.sliceStart-s)===i.sliceEnd&&n<this.length?"\n":a>=i.sliceEnd?"":i.line.charAt(a)},s.prototype.stripMargin=function(n,r){if(0===n)return this;if((0,t.default)(n>0,"negative margin: "+n),r&&1===this.length)return this;var i=new s(this.infos.map((function(t,i){return t.line&&(i>0||!r)&&(t=e.__assign(e.__assign({},t),{indent:Math.max(0,t.indent-n)})),t})));if(this.mappings.length>0){var a=i.mappings;(0,t.default)(0===a.length),this.mappings.forEach((function(e){a.push(e.indent(n,r,!0))}))}return i},s.prototype.indent=function(n){if(0===n)return this;var r=new s(this.infos.map((function(t){return t.line&&!t.locked&&(t=e.__assign(e.__assign({},t),{indent:t.indent+n})),t})));if(this.mappings.length>0){var i=r.mappings;(0,t.default)(0===i.length),this.mappings.forEach((function(e){i.push(e.indent(n))}))}return r},s.prototype.indentTail=function(n){if(0===n)return this;if(this.length<2)return this;var r=new s(this.infos.map((function(t,r){return r>0&&t.line&&!t.locked&&(t=e.__assign(e.__assign({},t),{indent:t.indent+n})),t})));if(this.mappings.length>0){var i=r.mappings;(0,t.default)(0===i.length),this.mappings.forEach((function(e){i.push(e.indent(n,!0))}))}return r},s.prototype.lockIndentTail=function(){return this.length<2?this:new s(this.infos.map((function(t,n){return e.__assign(e.__assign({},t),{locked:n>0})})))},s.prototype.getIndentAt=function(e){return(0,t.default)(e>=1,"no line "+e+" (line numbers start from 1)"),Math.max(this.infos[e-1].indent,0)},s.prototype.guessTabWidth=function(){if("number"==typeof this.cachedTabWidth)return this.cachedTabWidth;for(var e=[],t=0,n=1,r=this.length;n<=r;++n){var i=this.infos[n-1];if(!f(i.line.slice(i.sliceStart,i.sliceEnd))){var a=Math.abs(i.indent-t);e[a]=1+~~e[a],t=i.indent}}for(var s=-1,o=2,c=1;c<e.length;c+=1)l.call(e,c)&&e[c]>s&&(s=e[c],o=c);return this.cachedTabWidth=o},s.prototype.startsWithComment=function(){if(0===this.infos.length)return!1;var e=this.infos[0],t=e.sliceStart,n=e.sliceEnd,r=e.line.slice(t,n).trim();return 0===r.length||"//"===r.slice(0,2)||"/*"===r.slice(0,2)},s.prototype.isOnlyWhitespace=function(){return f(this.toString())},s.prototype.isPrecededOnlyByWhitespace=function(e){var t=this.infos[e.line-1],n=Math.max(t.indent,0),r=e.column-n;if(r<=0)return!0;var i=t.sliceStart,a=Math.min(i+r,t.sliceEnd);return f(t.line.slice(i,a))},s.prototype.getLineLength=function(e){var t=this.infos[e-1];return this.getIndentAt(e)+t.sliceEnd-t.sliceStart},s.prototype.nextPos=function(e,t){void 0===t&&(t=!1);var n=Math.max(e.line,0);return Math.max(e.column,0)<this.getLineLength(n)?(e.column+=1,!t||!!this.skipSpaces(e,!1,!0)):n<this.length&&(e.line+=1,e.column=0,!t||!!this.skipSpaces(e,!1,!0))},s.prototype.prevPos=function(e,t){void 0===t&&(t=!1);var n=e.line,r=e.column;if(r<1){if((n-=1)<1)return!1;r=this.getLineLength(n)}else r=Math.min(r-1,this.getLineLength(n));return e.line=n,e.column=r,!t||!!this.skipSpaces(e,!0,!0)},s.prototype.firstPos=function(){return{line:1,column:0}},s.prototype.lastPos=function(){return{line:this.length,column:this.getLineLength(this.length)}},s.prototype.skipSpaces=function(e,t,n){if(void 0===t&&(t=!1),void 0===n&&(n=!1),e=e?n?e:{line:e.line,column:e.column}:t?this.lastPos():this.firstPos(),t){for(;this.prevPos(e);)if(!f(this.charAt(e))&&this.nextPos(e))return e;return null}for(;f(this.charAt(e));)if(!this.nextPos(e))return null;return e},s.prototype.trimLeft=function(){var e=this.skipSpaces(this.firstPos(),!1,!0);return e?this.slice(e):y},s.prototype.trimRight=function(){var e=this.skipSpaces(this.lastPos(),!0,!0);return e?this.slice(this.firstPos(),e):y},s.prototype.trim=function(){var e=this.skipSpaces(this.firstPos(),!1,!0);if(null===e)return y;var t=this.skipSpaces(this.lastPos(),!0,!0);return null===t?y:this.slice(e,t)},s.prototype.eachPos=function(e,t,n){void 0===t&&(t=this.firstPos()),void 0===n&&(n=!1);var r=this.firstPos();if(t&&(r.line=t.line,r.column=t.column),!n||this.skipSpaces(r,!1,!0))do{e.call(this,r)}while(this.nextPos(r,n))},s.prototype.bootstrapSlice=function(e,t){var n=this.toString().split(h).slice(e.line-1,t.line);return n.length>0&&(n.push(n.pop().slice(0,t.column)),n[0]=n[0].slice(e.column)),d(n.join("\n"))},s.prototype.slice=function(e,n){if(!n){if(!e)return this;n=this.lastPos()}if(!e)throw Error("cannot slice with end but not start");var r=this.infos.slice(e.line-1,n.line);e.line===n.line?r[0]=m(r[0],e.column,n.column):((0,t.default)(e.line<n.line),r[0]=m(r[0],e.column),r.push(m(r.pop(),0,n.column)));var i=new s(r);if(this.mappings.length>0){var a=i.mappings;(0,t.default)(0===a.length),this.mappings.forEach((function(t){var r=t.slice(this,e,n);r&&a.push(r)}),this)}return i},s.prototype.bootstrapSliceString=function(e,t,n){return this.slice(e,t).toString(n)},s.prototype.sliceString=function(e,t,n){void 0===e&&(e=this.firstPos()),void 0===t&&(t=this.lastPos());for(var i=(0,r.normalize)(n),a=i.tabWidth,s=i.useTabs,o=i.reuseWhitespace,l=i.lineTerminator,c=[],p=e.line;p<=t.line;++p){var h=this.infos[p-1];p===e.line?h=p===t.line?m(h,e.column,t.column):m(h,e.column):p===t.line&&(h=m(h,0,t.column));var d=Math.max(h.indent,0),y=h.line.slice(0,h.sliceStart);if(o&&f(y)&&u(y,a)===d)c.push(h.line.slice(0,h.sliceEnd));else{var g=0,b=d;s&&(b-=(g=Math.floor(d/a))*a);var v="";g>0&&(v+=Array(g+1).join("\t")),b>0&&(v+=Array(b+1).join(" ")),v+=h.line.slice(h.sliceStart,h.sliceEnd),c.push(v)}}return c.join(l)},s.prototype.isEmpty=function(){return this.length<2&&this.getLineLength(1)<1},s.prototype.join=function(t){var n,r=this,i=[],a=[];function o(t){if(null!==t){if(n){var r=t.infos[0],s=Array(r.indent+1).join(" "),o=i.length,l=Math.max(n.indent,0)+n.sliceEnd-n.sliceStart;n.line=n.line.slice(0,n.sliceEnd)+s+r.line.slice(r.sliceStart,r.sliceEnd),n.locked=n.locked||r.locked,n.sliceEnd=n.line.length,t.mappings.length>0&&t.mappings.forEach((function(e){a.push(e.add(o,l))}))}else t.mappings.length>0&&a.push.apply(a,t.mappings);t.infos.forEach((function(t,r){(!n||r>0)&&(n=e.__assign({},t),i.push(n))}))}}if(t.map((function(e){var t=d(e);return t.isEmpty()?null:t})).forEach((function(e,t){r.isEmpty()?o(e):function(e,t){t>0&&o(r),o(e)}(e,t)})),i.length<1)return y;var l=new s(i);return l.mappings=a,l},s.prototype.concat=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var r=[this];return r.push.apply(r,e),(0,t.default)(r.length===e.length+1),y.join(r)},s}();ci.Lines=s;var o={},l=o.hasOwnProperty,c=10;function u(e,n){for(var r=0,i=e.length,a=0;a<i;++a)switch(e.charCodeAt(a)){case 9:(0,t.default)("number"==typeof n),(0,t.default)(n>0);var s=Math.ceil(r/n)*n;s===r?r+=n:r=s;break;case 11:case 12:case 13:case 65279:break;default:r+=1}return r}ci.countSpaces=u;var p=/^\s*/,h=/\u000D\u000A|\u000D(?!\u000A)|\u000A|\u2028|\u2029/;function d(e,n){if(e instanceof s)return e;e+="";var i=n&&n.tabWidth,a=e.indexOf("\t")<0,d=!n&&a&&e.length<=c;if((0,t.default)(i||a,"No tab width specified but encountered tabs in string\n"+e),d&&l.call(o,e))return o[e];var f=new s(e.split(h).map((function(e){var t=p.exec(e)[0];return{line:e,indent:u(t,i),locked:!1,sliceStart:t.length,sliceEnd:e.length}})),(0,r.normalize)(n).sourceFileName);return d&&(o[e]=f),f}function f(e){return!/\S/.test(e)}function m(e,n,r){var i=e.sliceStart,a=e.sliceEnd,s=Math.max(e.indent,0),o=s+a-i;return void 0===r&&(r=o),n=Math.max(n,0),(r=Math.max(r=Math.min(r,o),n))<s?(s=r,a=i):a-=o-r,o=r,o-=n,n<s?s-=n:(n-=s,s=0,i+=n),(0,t.default)(s>=0),(0,t.default)(i<=a),(0,t.default)(o===s+a-i),e.indent===s&&e.sliceStart===i&&e.sliceEnd===a?e:{line:e.line,indent:s,locked:!1,sliceStart:i,sliceEnd:a}}ci.fromString=d,ci.concat=function(e){return y.join(e)};var y=d("");return ci}var hi,di,fi={};function mi(){if(hi)return fi;hi=1,Object.defineProperty(fi,"__esModule",{value:!0}),fi.printComments=fi.attach=void 0;var e=Sn,t=e.__importDefault(Wr()),n=e.__importStar(Rr()),r=n.namedTypes,i=n.builtInTypes.array,a=n.builtInTypes.object,s=pi(),o=ei(),l=new WeakMap;function c(e,t,s){if(!e)return s;if((0,o.fixFaultyLocations)(e,t),s){if(r.Node.check(e)&&r.SourceLocation.check(e.loc)){for(var u=s.length-1;u>=0;--u){var p=s[u];if(p&&p.loc&&(0,o.comparePos)(p.loc.end,e.loc.start)<=0)break}return s.splice(u+1,0,e),s}}else{var h=l.get(e);if(h)return h}var d;if(i.check(e))d=Object.keys(e);else{if(!a.check(e))return s;d=n.getFieldNames(e)}s||l.set(e,s=[]),u=0;for(var f=d.length;u<f;++u)c(e[d[u]],t,s);return s}function u(e,t,n){for(var r,i,a=c(e,n),s=0,l=a&&a.length;"number"==typeof l&&s<l;){var p=s+l>>1,h=a[p];if((0,o.comparePos)(h.loc.start,t.loc.start)<=0&&(0,o.comparePos)(t.loc.end,h.loc.end)<=0)return void u(t.enclosingNode=h,t,n);if((0,o.comparePos)(h.loc.end,t.loc.start)<=0)r=h,s=p+1;else{if(!((0,o.comparePos)(t.loc.end,h.loc.start)<=0))throw Error("Comment location overlaps with node location");i=h,l=p}}r&&(t.precedingNode=r),i&&(t.followingNode=i)}function p(e,n){var r=e.length;if(0!==r){for(var i,a=e[0].precedingNode,s=e[0].followingNode,o=s.loc.start,l=r;l>0;--l){i=e[l-1],(0,t.default)(i.precedingNode===a),(0,t.default)(i.followingNode===s);var c=n.sliceString(i.loc.end,o);if(/\S/.test(c))break;o=i.loc.start}for(;l<=r&&(i=e[l])&&("Line"===i.type||"CommentLine"===i.type)&&i.loc.start.column>s.loc.start.column;)++l;if(l){var u=e[l-1].enclosingNode;"CallExpression"===(null==u?void 0:u.type)&&--l}e.forEach((function(e,t){t<l?f(a,e):d(s,e)})),e.length=0}}function h(e,t){(e.comments||(e.comments=[])).push(t)}function d(e,t){t.leading=!0,t.trailing=!1,h(e,t)}function f(e,t){t.leading=!1,t.trailing=!0,h(e,t)}return fi.attach=function(e,n,r){if(i.check(e)){var a=[];e.forEach((function(e){e.loc.lines=r,u(n,e,r);var i=e.precedingNode,s=e.enclosingNode,o=e.followingNode;if(i&&o){var l=a.length;if(l>0){var c=a[l-1];(0,t.default)(c.precedingNode===e.precedingNode==(c.followingNode===e.followingNode)),c.followingNode!==e.followingNode&&p(a,r)}a.push(e)}else if(i)p(a,r),f(i,e);else if(o)p(a,r),d(o,e);else{if(!s)throw Error("AST contains no nodes at all?");p(a,r),function(e,t){t.leading=!1,t.trailing=!1,h(e,t)}(s,e)}})),p(a,r),e.forEach((function(e){delete e.precedingNode,delete e.enclosingNode,delete e.followingNode}))}},fi.printComments=function(e,t){var i=e.getValue(),a=t(e),o=r.Node.check(i)&&n.getFieldValue(i,"comments");if(!o||0===o.length)return a;var l=[],c=[a];return e.each((function(e){var a=e.getValue(),o=n.getFieldValue(a,"leading"),u=n.getFieldValue(a,"trailing");o||u&&!r.Statement.check(i)&&"Block"!==a.type&&"CommentBlock"!==a.type?l.push(function(e,t){var n=e.getValue();r.Comment.assert(n);var i=n.loc,a=i&&i.lines,o=[t(e)];if(n.trailing)o.push("\n");else if(a instanceof s.Lines){var l=a.slice(i.end,a.skipSpaces(i.end)||a.lastPos());1===l.length?o.push(l):o.push(Array(l.length).join("\n"))}else o.push("\n");return(0,s.concat)(o)}(e,t)):u&&c.push(function(e,t){var n=e.getValue(e);r.Comment.assert(n);var i=n.loc,a=i&&i.lines,o=[];if(a instanceof s.Lines){var l=a.skipSpaces(i.start,!0)||a.firstPos(),c=a.slice(l,i.start);1===c.length?o.push(c):o.push(Array(c.length).join("\n"))}return o.push(t(e)),(0,s.concat)(o)}(e,t))}),"comments"),l.push.apply(l,c),(0,s.concat)(l)},fi}var yi,gi={},bi={};function vi(){if(yi)return bi;yi=1,Object.defineProperty(bi,"__esModule",{value:!0});var e=Sn,t=e.__importDefault(Wr()),n=e.__importStar(Rr()),r=e.__importStar(ei()),i=n.namedTypes,a=n.builtInTypes.array,s=n.builtInTypes.number,o={};[["??"],["||"],["&&"],["|"],["^"],["&"],["==","===","!=","!=="],["<",">","<=",">=","in","instanceof"],[">>","<<",">>>"],["+","-"],["*","/","%"],["**"]].forEach((function(e,t){e.forEach((function(e){o[e]=t}))}));var l=function e(n){(0,t.default)(this instanceof e),this.stack=[n]},c=l.prototype;function u(e,t){for(var n=e.stack,r=n.length-1;r>=0;r-=2){var a=n[r];if(i.Node.check(a)&&--t<0)return a}return null}function p(e){return i.BinaryExpression.check(e)||i.LogicalExpression.check(e)}function h(e){return!!i.CallExpression.check(e)||(a.check(e)?e.some(h):!!i.Node.check(e)&&n.someField(e,(function(e,t){return h(t)})))}return l.from=function(e){if(e instanceof l)return e.copy();if(e instanceof n.NodePath){for(var t=Object.create(l.prototype),r=[e.value],i=void 0;i=e.parentPath;e=i)r.push(e.name,i.value);return t.stack=r.reverse(),t}return new l(e)},c.copy=function(){var e=Object.create(l.prototype);return e.stack=this.stack.slice(0),e},c.getName=function(){var e=this.stack,t=e.length;return t>1?e[t-2]:null},c.getValue=function(){var e=this.stack;return e[e.length-1]},c.valueIsDuplicate=function(){var e=this.stack,t=e.length-1;return e.lastIndexOf(e[t],t-1)>=0},c.getNode=function(e){return void 0===e&&(e=0),u(this,~~e)},c.getParentNode=function(e){return void 0===e&&(e=0),u(this,1+~~e)},c.getRootValue=function(){var e=this.stack;return e.length%2==0?e[1]:e[0]},c.call=function(e){for(var t=this.stack,n=t.length,r=t[n-1],i=arguments.length,a=1;a<i;++a){var s=arguments[a];r=r[s],t.push(s,r)}var o=e(this);return t.length=n,o},c.each=function(e){for(var t=this.stack,n=t.length,r=t[n-1],i=arguments.length,a=1;a<i;++a){var s=arguments[a];r=r[s],t.push(s,r)}for(a=0;a<r.length;++a)a in r&&(t.push(a,r[a]),e(this),t.length-=2);t.length=n},c.map=function(e){for(var t=this.stack,n=t.length,r=t[n-1],i=arguments.length,a=1;a<i;++a){var s=arguments[a];r=r[s],t.push(s,r)}var o=Array(r.length);for(a=0;a<r.length;++a)a in r&&(t.push(a,r[a]),o[a]=e(this,a),t.length-=2);return t.length=n,o},c.hasParens=function(){var e=this.getNode(),t=this.getPrevToken(e);if(!t)return!1;var n=this.getNextToken(e);if(!n)return!1;if("("===t.value){if(")"===n.value)return!0;if(!this.canBeFirstInStatement()&&this.firstInStatement()&&!this.needsParens(!0))return!0}return!1},c.getPrevToken=function(e){var t=(e=e||this.getNode())&&e.loc,n=t&&t.tokens;if(n&&t.start.token>0){var i=n[t.start.token-1];if(i){var a=this.getRootValue().loc;if(r.comparePos(a.start,i.loc.start)<=0)return i}}return null},c.getNextToken=function(e){var t=(e=e||this.getNode())&&e.loc,n=t&&t.tokens;if(n&&t.end.token<n.length){var i=n[t.end.token];if(i){var a=this.getRootValue().loc;if(r.comparePos(i.loc.end,a.end)<=0)return i}}return null},c.needsParens=function(e){var n=this.getNode();if("AssignmentExpression"===n.type&&"ObjectPattern"===n.left.type)return!0;var r=this.getParentNode(),a=this.getName();if(this.getValue()!==n)return!1;if(i.Statement.check(n))return!1;if("Identifier"===n.type)return!1;if(r&&"ParenthesizedExpression"===r.type)return!1;if(n.extra&&n.extra.parenthesized)return!0;if(!r)return!1;if("UnaryExpression"===n.type&&"BinaryExpression"===r.type&&"left"===a&&r.left===n&&"**"===r.operator)return!0;switch(n.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return"MemberExpression"===r.type&&"object"===a&&r.object===n;case"BinaryExpression":case"LogicalExpression":switch(r.type){case"CallExpression":return"callee"===a&&r.callee===n;case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return!0;case"MemberExpression":return"object"===a&&r.object===n;case"BinaryExpression":case"LogicalExpression":var l=r.operator,c=o[l],u=n.operator,d=o[u];if(c>d)return!0;if(c===d&&"right"===a)return(0,t.default)(r.right===n),!0;break;default:return!1}break;case"SequenceExpression":switch(r.type){case"ReturnStatement":case"ForStatement":return!1;case"ExpressionStatement":return"expression"!==a;default:return!0}case"OptionalIndexedAccessType":return n.optional&&"IndexedAccessType"===r.type;case"IntersectionTypeAnnotation":case"UnionTypeAnnotation":return"NullableTypeAnnotation"===r.type;case"Literal":return"MemberExpression"===r.type&&s.check(n.value)&&"object"===a&&r.object===n;case"NumericLiteral":return"MemberExpression"===r.type&&"object"===a&&r.object===n;case"YieldExpression":case"AwaitExpression":case"AssignmentExpression":case"ConditionalExpression":switch(r.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"BinaryExpression":case"LogicalExpression":return!0;case"CallExpression":case"NewExpression":return"callee"===a&&r.callee===n;case"ConditionalExpression":return"test"===a&&r.test===n;case"MemberExpression":return"object"===a&&r.object===n;default:return!1}case"ArrowFunctionExpression":return!(!i.CallExpression.check(r)||"callee"!==a||r.callee!==n)||!(!i.MemberExpression.check(r)||"object"!==a||r.object!==n)||!(!i.TSAsExpression||!i.TSAsExpression.check(r)||"expression"!==a||r.expression!==n)||p(r);case"ObjectExpression":if("ArrowFunctionExpression"===r.type&&"body"===a&&r.body===n)return!0;break;case"TSAsExpression":if("ArrowFunctionExpression"===r.type&&"body"===a&&r.body===n&&"ObjectExpression"===n.expression.type)return!0;break;case"CallExpression":if("declaration"===a&&i.ExportDefaultDeclaration.check(r)&&i.FunctionExpression.check(n.callee))return!0}return"NewExpression"===r.type&&"callee"===a&&r.callee===n?h(n):!(!0===e||this.canBeFirstInStatement()||!this.firstInStatement())},c.canBeFirstInStatement=function(){var e=this.getNode();return!i.FunctionExpression.check(e)&&!i.ObjectExpression.check(e)&&!i.ClassExpression.check(e)},c.firstInStatement=function(){for(var e,n,r,a,s=this.stack,o=s.length-1;o>=0;o-=2)if(i.Node.check(s[o])&&(r=e,a=n,e=s[o-1],n=s[o]),n&&a){if(i.BlockStatement.check(n)&&"body"===e&&0===r)return(0,t.default)(n.body[0]===a),!0;if(i.ExpressionStatement.check(n)&&"expression"===r)return(0,t.default)(n.expression===a),!0;if(i.AssignmentExpression.check(n)&&"left"===r)return(0,t.default)(n.left===a),!0;if(i.ArrowFunctionExpression.check(n)&&"body"===r)return(0,t.default)(n.body===a),!0;if(i.SequenceExpression.check(n)&&"expressions"===s[o+1]&&0===r)(0,t.default)(n.expressions[0]===a);else if(i.CallExpression.check(n)&&"callee"===r)(0,t.default)(n.callee===a);else if(i.MemberExpression.check(n)&&"object"===r)(0,t.default)(n.object===a);else if(i.ConditionalExpression.check(n)&&"test"===r)(0,t.default)(n.test===a);else if(p(n)&&"left"===r)(0,t.default)(n.left===a);else{if(!i.UnaryExpression.check(n)||n.prefix||"argument"!==r)return!1;(0,t.default)(n.argument===a)}}return!0},bi.default=l,bi}var xi,Si,Ei,Ti={},_i=(Ei||(Ei=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.run=e.prettyPrint=e.print=e.visit=e.types=e.parse=void 0;var t=Sn,n=t.__importDefault(void 0),r=t.__importStar(Rr());e.types=r;var i=function(){if(di)return zr;di=1,Object.defineProperty(zr,"__esModule",{value:!0}),zr.parse=void 0;var e=Sn,t=e.__importDefault(Wr()),n=e.__importStar(Rr()),r=n.builders,i=n.builtInTypes.object,a=n.builtInTypes.array,s=si(),o=pi(),l=mi(),c=e.__importStar(ei());zr.parse=function(e,t){t=(0,s.normalize)(t);var n,i,a=(0,o.fromString)(e,t),p=a.toString({tabWidth:t.tabWidth,reuseWhitespace:!1,useTabs:!1}),h=[],d=t.parser.parse(p,{jsx:!0,loc:!0,locations:!0,range:t.range,comment:!0,onComment:h,tolerant:c.getOption(t,"tolerant",!0),ecmaVersion:6,sourceType:c.getOption(t,"sourceType","module")}),f=Array.isArray(d.tokens)?d.tokens:ii.tokenize(p,{loc:!0});delete d.tokens,f.forEach((function(e){"string"!=typeof e.value&&(e.value=a.sliceString(e.loc.start,e.loc.end))})),Array.isArray(d.comments)&&(h=d.comments,delete d.comments),d.loc?c.fixFaultyLocations(d,a):d.loc={start:a.firstPos(),end:a.lastPos()},d.loc.lines=a,d.loc.indent=0,"Program"===d.type?(i=d,(n=r.file(d,t.sourceFileName||null)).loc={start:a.firstPos(),end:a.lastPos(),lines:a,indent:0}):"File"===d.type&&(i=(n=d).program),t.tokens&&(n.tokens=f);var m=c.getTrueLoc({type:i.type,loc:i.loc,body:[],comments:h},a);return i.loc.start=m.start,i.loc.end=m.end,(0,l.attach)(h,i.body.length?n.program:n,a),new u(a,f).copy(n)};var u=function e(n,r){(0,t.default)(this instanceof e),this.lines=n,this.tokens=r,this.startTokenIndex=0,this.endTokenIndex=r.length,this.indent=0,this.seen=new Map},p=u.prototype;return p.copy=function(e){if(this.seen.has(e))return this.seen.get(e);if(a.check(e)){var t=Array(e.length);return this.seen.set(e,t),e.forEach((function(e,n){t[n]=this.copy(e)}),this),t}if(!i.check(e))return e;c.fixFaultyLocations(e,this.lines);var n=Object.create(Object.getPrototypeOf(e),{original:{value:e,configurable:!1,enumerable:!1,writable:!0}});this.seen.set(e,n);var r=e.loc,s=this.indent,o=s,l=this.startTokenIndex,u=this.endTokenIndex;r&&(("Block"===e.type||"Line"===e.type||"CommentBlock"===e.type||"CommentLine"===e.type||this.lines.isPrecededOnlyByWhitespace(r.start))&&(o=this.indent=r.start.column),r.lines=this.lines,r.tokens=this.tokens,r.indent=o,this.findTokenRange(r));for(var p=Object.keys(e),h=p.length,d=0;d<h;++d){var f=p[d];"loc"===f||"tokens"===f&&"File"===e.type?n[f]=e[f]:n[f]=this.copy(e[f])}return this.indent=s,this.startTokenIndex=l,this.endTokenIndex=u,n},p.findTokenRange=function(e){for(;this.startTokenIndex>0;){var t=e.tokens[this.startTokenIndex];if(!(c.comparePos(e.start,t.loc.start)<0))break;--this.startTokenIndex}for(;this.endTokenIndex<e.tokens.length&&(t=e.tokens[this.endTokenIndex],c.comparePos(t.loc.end,e.end)<0);)++this.endTokenIndex;for(;this.startTokenIndex<this.endTokenIndex&&(t=e.tokens[this.startTokenIndex],c.comparePos(t.loc.start,e.start)<0);)++this.startTokenIndex;for(e.start.token=this.startTokenIndex;this.endTokenIndex>this.startTokenIndex&&(t=e.tokens[this.endTokenIndex-1],c.comparePos(e.end,t.loc.end)<0);)--this.endTokenIndex;e.end.token=this.endTokenIndex},zr}();Object.defineProperty(e,"parse",{enumerable:!0,get:function(){return i.parse}});var a=function(){if(Si)return gi;Si=1,Object.defineProperty(gi,"__esModule",{value:!0}),gi.Printer=void 0;var e=Sn,t=e.__importDefault(Wr()),n=e.__importStar(Rr()),r=mi(),i=e.__importDefault(vi()),a=pi(),s=si(),o=function(){if(xi)return Ti;xi=1,Object.defineProperty(Ti,"__esModule",{value:!0}),Ti.getReprinter=Ti.Patcher=void 0;var e=Sn,t=e.__importDefault(Wr()),n=e.__importStar(pi()),r=e.__importStar(Rr()),i=r.namedTypes.Printable,a=r.namedTypes.Expression,s=r.namedTypes.ReturnStatement,o=r.namedTypes.SourceLocation,l=ei(),c=e.__importDefault(vi()),u=r.builtInTypes.object,p=r.builtInTypes.array,h=r.builtInTypes.string,d=/[0-9a-z_$]/i,f=function e(r){(0,t.default)(this instanceof e),(0,t.default)(r instanceof n.Lines);var i=[];this.replace=function(e,t){h.check(t)&&(t=n.fromString(t)),i.push({lines:t,start:e.start,end:e.end})},this.get=function(e){var a=(e=e||{start:{line:1,column:0},end:{line:r.length,column:r.getLineLength(r.length)}}).start,s=[];function o(e,n){(0,t.default)((0,l.comparePos)(e,n)<=0),s.push(r.slice(e,n))}return i.sort((function(e,t){return(0,l.comparePos)(e.start,t.start)})).forEach((function(e){(0,l.comparePos)(a,e.start)>0||(o(a,e.start),s.push(e.lines),a=e.end)})),o(a,e.end),n.concat(s)}};Ti.Patcher=f;var m=f.prototype;function y(e){var t=[];return e.comments&&e.comments.length>0&&e.comments.forEach((function(e){(e.leading||e.trailing)&&t.push(e)})),t}function g(e,t,n){var r=e.getValue();return r===t.getValue()||(p.check(r)?b(e,t,n):!!u.check(r)&&function(e,t,n){var r=e.getValue();if(u.assert(r),null===r.original)return!1;var s=t.getValue();if(!u.check(s))return!1;if(r===s||e.valueIsDuplicate()||t.valueIsDuplicate())return!0;if(i.check(r)){if(!i.check(s))return!1;var o=e.getParentNode(),l=t.getParentNode();if(null!==l&&"FunctionTypeAnnotation"===l.type&&null!==o&&"FunctionTypeAnnotation"===o.type){var c=1!==l.params.length||!!l.params[0].name,p=1!==o.params.length||!!o.params[0].name;if(!c&&p)return!1}if(r.type===s.type){var h=[];if(v(e,t,h))n.push.apply(n,h);else{if(!s.loc)return!1;n.push({oldPath:t.copy(),newPath:e.copy()})}return!0}return!!(a.check(r)&&a.check(s)&&s.loc)&&(n.push({oldPath:t.copy(),newPath:e.copy()}),!0)}return v(e,t,n)}(e,t,n))}function b(e,t,n){var r=e.getValue(),i=t.getValue();if(r===i||e.valueIsDuplicate()||t.valueIsDuplicate())return!0;p.assert(r);var a=r.length;if(!p.check(i)||i.length!==a)return!1;for(var s=0;s<a;++s){e.stack.push(s,r[s]),t.stack.push(s,i[s]);var o=g(e,t,n);if(e.stack.length-=2,t.stack.length-=2,!o)return!1}return!0}function v(e,t,n){var i=e.getValue(),a=t.getValue();if(u.assert(i),u.assert(a),null===i.original)return!1;if(e.needsParens()&&!t.hasParens())return!1;var o=(0,l.getUnionOfKeys)(a,i);"File"!==a.type&&"File"!==i.type||delete o.tokens,delete o.loc;var c=n.length;for(var p in o)if("_"!==p.charAt(0)){e.stack.push(p,r.getFieldValue(i,p)),t.stack.push(p,r.getFieldValue(a,p));var h=g(e,t,n);if(e.stack.length-=2,t.stack.length-=2,!h)return!1}return!(s.check(e.getNode())&&n.length>c)}return m.tryToReprintComments=function(e,n,r){var i=this;if(!e.comments&&!n.comments)return!0;var a=c.default.from(e),s=c.default.from(n);a.stack.push("comments",y(e)),s.stack.push("comments",y(n));var o=[],l=b(a,s,o);return l&&o.length>0&&o.forEach((function(e){var n=e.oldPath.getValue();(0,t.default)(n.leading||n.trailing),i.replace(n.loc,r(e.newPath).indentTail(n.loc.indent))})),l},m.deleteComments=function(e){if(e.comments){var t=this;e.comments.forEach((function(n){n.leading?t.replace({start:n.loc.start,end:e.loc.lines.skipSpaces(n.loc.end,!1,!1)},""):n.trailing&&t.replace({start:e.loc.lines.skipSpaces(n.loc.start,!0,!1),end:n.loc.end},"")}))}},Ti.getReprinter=function(e){(0,t.default)(e instanceof c.default);var r=e.getValue();if(i.check(r)){var a=r.original,s=a&&a.loc,u=s&&s.lines,p=[];if(u&&function(e,n){var r=e.getValue();i.assert(r);var a=r.original;if(i.assert(a),(0,t.default)(0===n.length),r.type!==a.type)return!1;var s=v(e,new c.default(a),n);return s||(n.length=0),s}(e,p))return function(t){var r=new f(u);p.forEach((function(e){var i=e.newPath.getValue(),a=e.oldPath.getValue();o.assert(a.loc,!0);var s=!r.tryToReprintComments(i,a,t);s&&r.deleteComments(a);var c=t(e.newPath,{includeComments:s,avoidRootParens:a.type===i.type&&e.oldPath.hasParens()}).indentTail(a.loc.indent),p=function(e,t,n){var r=(0,l.copyPos)(t.start),i=e.prevPos(r)&&e.charAt(r),a=n.charAt(n.firstPos());return i&&d.test(i)&&a&&d.test(a)}(u,a.loc,c),h=function(e,t,n){var r=e.charAt(t.end),i=n.lastPos(),a=n.prevPos(i)&&n.charAt(i);return a&&d.test(a)&&r&&d.test(r)}(u,a.loc,c);if(p||h){var f=[];p&&f.push(" "),f.push(c),h&&f.push(" "),c=n.concat(f)}r.replace(a.loc,c)}));var i=r.get(s).indentTail(-a.loc.indent);return e.needsParens()?n.concat(["(",i,")"]):i}}},Ti}(),l=e.__importStar(ei()),c=n.namedTypes,u=n.builtInTypes.string,p=n.builtInTypes.object,h=function e(n,r){(0,t.default)(this instanceof e),u.assert(n),this.code=n,r&&(p.assert(r),this.map=r)},d=!1;h.prototype.toString=function(){return d||(console.warn("Deprecation warning: recast.print now returns an object with a .code property. You appear to be treating the object as a string, which might still work but is strongly discouraged."),d=!0),this.code};var f=new h("");function m(r,s,o,u){(0,t.default)(r instanceof i.default);var p=r.getValue(),h=[],d=function(r,i,s){var o,u,p,h=r.getValue();if(!h)return(0,a.fromString)("");if("string"==typeof h)return(0,a.fromString)(h,i);c.Printable.assert(h);var d=[];switch(h.type){case"File":return r.call(s,"program");case"Program":return h.directives&&r.each((function(e){d.push(s(e),";\n")}),"directives"),h.interpreter&&d.push(r.call(s,"interpreter")),d.push(r.call((function(e){return y(e,i,s)}),"body")),(0,a.concat)(d);case"Noop":case"EmptyStatement":return(0,a.fromString)("");case"ExpressionStatement":return(0,a.concat)([r.call(s,"expression"),";"]);case"ParenthesizedExpression":return(0,a.concat)(["(",r.call(s,"expression"),")"]);case"BinaryExpression":case"LogicalExpression":case"AssignmentExpression":return(0,a.fromString)(" ").join([r.call(s,"left"),h.operator,r.call(s,"right")]);case"AssignmentPattern":return(0,a.concat)([r.call(s,"left")," = ",r.call(s,"right")]);case"MemberExpression":case"OptionalMemberExpression":d.push(r.call(s,"object"));var f=r.call(s,"property"),m=n.getFieldValue(h,"optional");return h.computed?d.push(m?"?.[":"[",f,"]"):d.push(m?"?.":".",f),(0,a.concat)(d);case"ChainExpression":return r.call(s,"expression");case"MetaProperty":return(0,a.concat)([r.call(s,"meta"),".",r.call(s,"property")]);case"BindExpression":return h.object&&d.push(r.call(s,"object")),d.push("::",r.call(s,"callee")),(0,a.concat)(d);case"Path":return(0,a.fromString)(".").join(h.body);case"Identifier":return(0,a.concat)([(0,a.fromString)(h.name,i),h.optional?"?":"",r.call(s,"typeAnnotation")]);case"SpreadElement":case"SpreadElementPattern":case"RestProperty":case"SpreadProperty":case"SpreadPropertyPattern":case"ObjectTypeSpreadProperty":case"RestElement":return(0,a.concat)(["...",r.call(s,"argument"),r.call(s,"typeAnnotation")]);case"FunctionDeclaration":case"FunctionExpression":case"TSDeclareFunction":return h.declare&&d.push("declare "),h.async&&d.push("async "),d.push("function"),h.generator&&d.push("*"),h.id?d.push(" ",r.call(s,"id"),r.call(s,"typeParameters")):h.typeParameters&&d.push(r.call(s,"typeParameters")),d.push("(",x(r,i,s),")",r.call(s,"returnType")),h.body&&d.push(" ",r.call(s,"body")),(0,a.concat)(d);case"ArrowFunctionExpression":return h.async&&d.push("async "),h.typeParameters&&d.push(r.call(s,"typeParameters")),i.arrowParensAlways||1!==h.params.length||h.rest||"Identifier"!==h.params[0].type||h.params[0].typeAnnotation||h.returnType?d.push("(",x(r,i,s),")",r.call(s,"returnType")):d.push(r.call(s,"params",0)),d.push(" => ",r.call(s,"body")),(0,a.concat)(d);case"MethodDefinition":return b(r,i,s);case"YieldExpression":return d.push("yield"),h.delegate&&d.push("*"),h.argument&&d.push(" ",r.call(s,"argument")),(0,a.concat)(d);case"AwaitExpression":return d.push("await"),h.all&&d.push("*"),h.argument&&d.push(" ",r.call(s,"argument")),(0,a.concat)(d);case"ModuleExpression":return(0,a.concat)(["module {\n",r.call(s,"body").indent(i.tabWidth),"\n}"]);case"ModuleDeclaration":return d.push("module",r.call(s,"id")),h.source?((0,t.default)(!h.body),d.push("from",r.call(s,"source"))):d.push(r.call(s,"body")),(0,a.fromString)(" ").join(d);case"ImportSpecifier":return h.importKind&&"value"!==h.importKind&&d.push(h.importKind+" "),h.imported?(d.push(r.call(s,"imported")),h.local&&h.local.name!==h.imported.name&&d.push(" as ",r.call(s,"local"))):h.id&&(d.push(r.call(s,"id")),h.name&&d.push(" as ",r.call(s,"name"))),(0,a.concat)(d);case"ExportSpecifier":return h.exportKind&&"value"!==h.exportKind&&d.push(h.exportKind+" "),h.local?(d.push(r.call(s,"local")),h.exported&&h.exported.name!==h.local.name&&d.push(" as ",r.call(s,"exported"))):h.id&&(d.push(r.call(s,"id")),h.name&&d.push(" as ",r.call(s,"name"))),(0,a.concat)(d);case"ExportBatchSpecifier":return(0,a.fromString)("*");case"ImportNamespaceSpecifier":return d.push("* as "),h.local?d.push(r.call(s,"local")):h.id&&d.push(r.call(s,"id")),(0,a.concat)(d);case"ImportDefaultSpecifier":return h.local?r.call(s,"local"):r.call(s,"id");case"TSExportAssignment":return(0,a.concat)(["export = ",r.call(s,"expression")]);case"ExportDeclaration":case"ExportDefaultDeclaration":case"ExportNamedDeclaration":return E(r,i,s);case"ExportAllDeclaration":return d.push("export *"),h.exported&&d.push(" as ",r.call(s,"exported")),d.push(" from ",r.call(s,"source"),";"),(0,a.concat)(d);case"TSNamespaceExportDeclaration":return d.push("export as namespace ",r.call(s,"id")),O((0,a.concat)(d));case"ExportNamespaceSpecifier":return(0,a.concat)(["* as ",r.call(s,"exported")]);case"ExportDefaultSpecifier":return r.call(s,"exported");case"Import":return(0,a.fromString)("import",i);case"ImportExpression":return(0,a.concat)(["import(",r.call(s,"source"),")"]);case"ImportDeclaration":if(d.push("import "),h.importKind&&"value"!==h.importKind&&d.push(h.importKind+" "),h.specifiers&&h.specifiers.length>0){var A=[],I=[];r.each((function(e){var t=e.getValue();"ImportSpecifier"===t.type?I.push(s(e)):"ImportDefaultSpecifier"!==t.type&&"ImportNamespaceSpecifier"!==t.type||A.push(s(e))}),"specifiers"),A.forEach((function(e,t){t>0&&d.push(", "),d.push(e)})),I.length>0&&((Ce=(0,a.fromString)(", ").join(I)).getLineLength(1)>i.wrapColumn&&(Ce=(0,a.concat)([(0,a.fromString)(",\n").join(I).indent(i.tabWidth),","])),A.length>0&&d.push(", "),Ce.length>1?d.push("{\n",Ce,"\n}"):i.objectCurlySpacing?d.push("{ ",Ce," }"):d.push("{",Ce,"}")),d.push(" from ")}return d.push(r.call(s,"source"),S(r,i,s),";"),(0,a.concat)(d);case"ImportAttribute":return(0,a.concat)([r.call(s,"key"),": ",r.call(s,"value")]);case"StaticBlock":d.push("static ");case"BlockStatement":var D=r.call((function(e){return y(e,i,s)}),"body");return!D.isEmpty()||h.directives&&0!==h.directives.length?(d.push("{\n"),h.directives&&r.each((function(e){d.push(O(s(e).indent(i.tabWidth)),h.directives.length>1||!D.isEmpty()?"\n":"")}),"directives"),d.push(D.indent(i.tabWidth)),d.push("\n}"),(0,a.concat)(d)):(d.push("{}"),(0,a.concat)(d));case"ReturnStatement":if(d.push("return"),h.argument){var L=(null===(o=c.JSXElement)||void 0===o?void 0:o.check(h.argument))||(null===(u=c.JSXFragment)||void 0===u?void 0:u.check(h.argument)),j=r.call(s,"argument");j.startsWithComment()||j.length>1&&L?(L&&(null===(p=h.argument.extra)||void 0===p?void 0:p.parenthesized)&&(h.argument.extra.parenthesized=!1,j=r.call(s,"argument"),h.argument.extra.parenthesized=!0),d.push(" ",(0,a.concat)(["(\n",j]).indentTail(i.tabWidth),"\n)")):d.push(" ",j)}return d.push(";"),(0,a.concat)(d);case"CallExpression":case"OptionalCallExpression":return d.push(r.call(s,"callee")),h.typeParameters&&d.push(r.call(s,"typeParameters")),h.typeArguments&&d.push(r.call(s,"typeArguments")),n.getFieldValue(h,"optional")&&d.push("?."),d.push(v(r,i,s)),(0,a.concat)(d);case"RecordExpression":d.push("#");case"ObjectExpression":case"ObjectPattern":case"ObjectTypeAnnotation":var M="ObjectTypeAnnotation"===h.type,B=i.flowObjectCommas?",":M?";":",",F=[],V=!1;M&&(F.push("indexers","callProperties"),null!=h.internalSlots&&F.push("internalSlots")),F.push("properties");var R=0;F.forEach((function(e){R+=h[e].length}));var q=M&&1===R||0===R,U=h.exact?"{|":"{",z=h.exact?"|}":"}";d.push(q?U:U+"\n");var W=d.length-1,G=0;if(F.forEach((function(e){r.each((function(e){var t=s(e);q||(t=t.indent(i.tabWidth));var n=!M&&t.length>1;n&&V&&d.push("\n"),d.push(t),G<R-1?(d.push(B+(n?"\n\n":"\n")),V=!n):(1!==R&&M||!q&&l.isTrailingCommaEnabled(i,"objects")&&"RestElement"!==e.getValue().type)&&d.push(B),G++}),e)})),h.inexact){var J=(0,a.fromString)("...",i);q?(R>0&&d.push(B," "),d.push(J)):d.push("\n",J.indent(i.tabWidth))}return d.push(q?z:"\n"+z),0!==G&&q&&i.objectCurlySpacing&&(d[W]=U+" ",d[d.length-1]=" "+z),h.typeAnnotation&&d.push(r.call(s,"typeAnnotation")),(0,a.concat)(d);case"PropertyPattern":return(0,a.concat)([r.call(s,"key"),": ",r.call(s,"pattern")]);case"ObjectProperty":case"Property":if(h.method||"get"===h.kind||"set"===h.kind)return b(r,i,s);if(h.shorthand&&"AssignmentPattern"===h.value.type)return r.call(s,"value");var $=r.call(s,"key");return h.computed?d.push("[",$,"]"):d.push($),h.shorthand&&h.key.name===h.value.name||d.push(": ",r.call(s,"value")),(0,a.concat)(d);case"ClassMethod":case"ObjectMethod":case"ClassPrivateMethod":case"TSDeclareMethod":return b(r,i,s);case"PrivateName":return(0,a.concat)(["#",r.call(s,"id")]);case"Decorator":return(0,a.concat)(["@",r.call(s,"expression")]);case"TupleExpression":d.push("#");case"ArrayExpression":case"ArrayPattern":var H=h.elements.length,K=r.map(s,"elements"),X=(0,a.fromString)(", ").join(K).getLineLength(1)<=i.wrapColumn;return X?i.arrayBracketSpacing?d.push("[ "):d.push("["):d.push("[\n"),r.each((function(e){var t=e.getName();if(e.getValue()){var n=K[t];X?t>0&&d.push(" "):n=n.indent(i.tabWidth),d.push(n),(t<H-1||!X&&l.isTrailingCommaEnabled(i,"arrays"))&&d.push(","),X||d.push("\n")}else d.push(",")}),"elements"),X&&i.arrayBracketSpacing?d.push(" ]"):d.push("]"),h.typeAnnotation&&d.push(r.call(s,"typeAnnotation")),(0,a.concat)(d);case"SequenceExpression":return(0,a.fromString)(", ").join(r.map(s,"expressions"));case"ThisExpression":return(0,a.fromString)("this");case"Super":return(0,a.fromString)("super");case"NullLiteral":return(0,a.fromString)("null");case"RegExpLiteral":return(0,a.fromString)(C(h)||"/".concat(h.pattern,"/").concat(h.flags||""),i);case"BigIntLiteral":return(0,a.fromString)(C(h)||h.value+"n",i);case"NumericLiteral":return(0,a.fromString)(C(h)||h.value,i);case"DecimalLiteral":return(0,a.fromString)(C(h)||h.value+"m",i);case"StringLiteral":return(0,a.fromString)(N(h.value,i));case"BooleanLiteral":case"Literal":return(0,a.fromString)(C(h)||("string"==typeof h.value?N(h.value,i):h.value),i);case"Directive":return r.call(s,"value");case"DirectiveLiteral":return(0,a.fromString)(C(h)||N(h.value,i),i);case"InterpreterDirective":return(0,a.fromString)("#!".concat(h.value,"\n"),i);case"ModuleSpecifier":if(h.local)throw Error("The ESTree ModuleSpecifier type should be abstract");return(0,a.fromString)(N(h.value,i),i);case"UnaryExpression":return d.push(h.operator),/[a-z]$/.test(h.operator)&&d.push(" "),d.push(r.call(s,"argument")),(0,a.concat)(d);case"UpdateExpression":return d.push(r.call(s,"argument"),h.operator),h.prefix&&d.reverse(),(0,a.concat)(d);case"ConditionalExpression":return(0,a.concat)([r.call(s,"test")," ? ",r.call(s,"consequent")," : ",r.call(s,"alternate")]);case"NewExpression":return d.push("new ",r.call(s,"callee")),h.typeParameters&&d.push(r.call(s,"typeParameters")),h.typeArguments&&d.push(r.call(s,"typeArguments")),h.arguments&&d.push(v(r,i,s)),(0,a.concat)(d);case"VariableDeclaration":h.declare&&d.push("declare "),d.push(h.kind," ");var Y=0,Q=r.map((function(e){var t=s(e);return Y=Math.max(t.length,Y),t}),"declarations");1===Y?d.push((0,a.fromString)(", ").join(Q)):Q.length>1?d.push((0,a.fromString)(",\n").join(Q).indentTail(h.kind.length+1)):d.push(Q[0]);var Z=r.getParentNode();return c.ForStatement.check(Z)||c.ForInStatement.check(Z)||c.ForOfStatement&&c.ForOfStatement.check(Z)||c.ForAwaitStatement&&c.ForAwaitStatement.check(Z)||d.push(";"),(0,a.concat)(d);case"VariableDeclarator":return h.init?(0,a.fromString)(" = ").join([r.call(s,"id"),r.call(s,"init")]):r.call(s,"id");case"WithStatement":return(0,a.concat)(["with (",r.call(s,"object"),") ",r.call(s,"body")]);case"IfStatement":var ee=k(r.call(s,"consequent"),i);return d.push("if (",r.call(s,"test"),")",ee),h.alternate&&d.push(w(ee)?" else":"\nelse",k(r.call(s,"alternate"),i)),(0,a.concat)(d);case"ForStatement":var te=r.call(s,"init"),ne=te.length>1?";\n":"; ",re=(0,a.fromString)(ne).join([te,r.call(s,"test"),r.call(s,"update")]).indentTail(5),ie=(0,a.concat)(["for (",re,")"]),ae=k(r.call(s,"body"),i);return d.push(ie),ie.length>1&&(d.push("\n"),ae=ae.trimLeft()),d.push(ae),(0,a.concat)(d);case"WhileStatement":return(0,a.concat)(["while (",r.call(s,"test"),")",k(r.call(s,"body"),i)]);case"ForInStatement":return(0,a.concat)([h.each?"for each (":"for (",r.call(s,"left")," in ",r.call(s,"right"),")",k(r.call(s,"body"),i)]);case"ForOfStatement":case"ForAwaitStatement":return d.push("for "),(h.await||"ForAwaitStatement"===h.type)&&d.push("await "),d.push("(",r.call(s,"left")," of ",r.call(s,"right"),")",k(r.call(s,"body"),i)),(0,a.concat)(d);case"DoWhileStatement":var se=(0,a.concat)(["do",k(r.call(s,"body"),i)]);return d.push(se),w(se)?d.push(" while"):d.push("\nwhile"),d.push(" (",r.call(s,"test"),");"),(0,a.concat)(d);case"DoExpression":var oe=r.call((function(e){return y(e,i,s)}),"body");return(0,a.concat)(["do {\n",oe.indent(i.tabWidth),"\n}"]);case"BreakStatement":return d.push("break"),h.label&&d.push(" ",r.call(s,"label")),d.push(";"),(0,a.concat)(d);case"ContinueStatement":return d.push("continue"),h.label&&d.push(" ",r.call(s,"label")),d.push(";"),(0,a.concat)(d);case"LabeledStatement":return(0,a.concat)([r.call(s,"label"),":\n",r.call(s,"body")]);case"TryStatement":return d.push("try ",r.call(s,"block")),h.handler?d.push(" ",r.call(s,"handler")):h.handlers&&r.each((function(e){d.push(" ",s(e))}),"handlers"),h.finalizer&&d.push(" finally ",r.call(s,"finalizer")),(0,a.concat)(d);case"CatchClause":return d.push("catch "),h.param&&d.push("(",r.call(s,"param")),h.guard&&d.push(" if ",r.call(s,"guard")),h.param&&d.push(") "),d.push(r.call(s,"body")),(0,a.concat)(d);case"ThrowStatement":return(0,a.concat)(["throw ",r.call(s,"argument"),";"]);case"SwitchStatement":return(0,a.concat)(["switch (",r.call(s,"discriminant"),") {\n",(0,a.fromString)("\n").join(r.map(s,"cases")),"\n}"]);case"SwitchCase":return h.test?d.push("case ",r.call(s,"test"),":"):d.push("default:"),h.consequent.length>0&&d.push("\n",r.call((function(e){return y(e,i,s)}),"consequent").indent(i.tabWidth)),(0,a.concat)(d);case"DebuggerStatement":return(0,a.fromString)("debugger;");case"JSXAttribute":return d.push(r.call(s,"name")),h.value&&d.push("=",r.call(s,"value")),(0,a.concat)(d);case"JSXIdentifier":return(0,a.fromString)(h.name,i);case"JSXNamespacedName":return(0,a.fromString)(":").join([r.call(s,"namespace"),r.call(s,"name")]);case"JSXMemberExpression":return(0,a.fromString)(".").join([r.call(s,"object"),r.call(s,"property")]);case"JSXSpreadAttribute":return(0,a.concat)(["{...",r.call(s,"argument"),"}"]);case"JSXSpreadChild":return(0,a.concat)(["{...",r.call(s,"expression"),"}"]);case"JSXExpressionContainer":return(0,a.concat)(["{",r.call(s,"expression"),"}"]);case"JSXElement":case"JSXFragment":var le="opening"+("JSXElement"===h.type?"Element":"Fragment"),ce="closing"+("JSXElement"===h.type?"Element":"Fragment"),ue=r.call(s,le);if(h[le].selfClosing)return(0,t.default)(!h[ce],"unexpected "+ce+" element in self-closing "+h.type),ue;var pe=(0,a.concat)(r.map((function(e){var t=e.getValue();if(c.Literal.check(t)&&"string"==typeof t.value){if(/\S/.test(t.value))return t.value.replace(/^\s+/g,"");if(/\n/.test(t.value))return"\n"}return s(e)}),"children")).indentTail(i.tabWidth),he=r.call(s,ce);return(0,a.concat)([ue,pe,he]);case"JSXOpeningElement":d.push("<",r.call(s,"name"));var de=r.call(s,"typeParameters");de.length&&d.push(de);var fe=[];r.each((function(e){fe.push(" ",s(e))}),"attributes");var me=(0,a.concat)(fe);return(me.length>1||me.getLineLength(1)>i.wrapColumn)&&(fe.forEach((function(e,n){" "===e&&((0,t.default)(n%2==0),fe[n]="\n")})),me=(0,a.concat)(fe).indentTail(i.tabWidth)),d.push(me,h.selfClosing?" />":">"),(0,a.concat)(d);case"JSXClosingElement":return(0,a.concat)(["</",r.call(s,"name"),">"]);case"JSXOpeningFragment":return(0,a.fromString)("<>");case"JSXClosingFragment":return(0,a.fromString)("</>");case"JSXText":return(0,a.fromString)(h.value,i);case"JSXEmptyExpression":return(0,a.fromString)("");case"TypeAnnotatedIdentifier":return(0,a.concat)([r.call(s,"annotation")," ",r.call(s,"identifier")]);case"ClassBody":return 0===h.body.length?(0,a.fromString)("{}"):(0,a.concat)(["{\n",r.call((function(e){return y(e,i,s)}),"body").indent(i.tabWidth),"\n}"]);case"ClassPropertyDefinition":return d.push("static ",r.call(s,"definition")),c.MethodDefinition.check(h.definition)||d.push(";"),(0,a.concat)(d);case"ClassProperty":h.declare&&d.push("declare ");var ye=h.accessibility||h.access;return"string"==typeof ye&&d.push(ye," "),h.static&&d.push("static "),h.abstract&&d.push("abstract "),h.readonly&&d.push("readonly "),$=r.call(s,"key"),h.computed&&($=(0,a.concat)(["[",$,"]"])),h.variance&&($=(0,a.concat)([_(r,s),$])),d.push($),h.optional&&d.push("?"),h.definite&&d.push("!"),h.typeAnnotation&&d.push(r.call(s,"typeAnnotation")),h.value&&d.push(" = ",r.call(s,"value")),d.push(";"),(0,a.concat)(d);case"ClassPrivateProperty":return h.static&&d.push("static "),d.push(r.call(s,"key")),h.typeAnnotation&&d.push(r.call(s,"typeAnnotation")),h.value&&d.push(" = ",r.call(s,"value")),d.push(";"),(0,a.concat)(d);case"ClassAccessorProperty":return d.push.apply(d,e.__spreadArray(e.__spreadArray([],g(h),!1),["accessor "],!1)),h.computed?d.push("[",r.call(s,"key"),"]"):d.push(r.call(s,"key")),h.optional&&d.push("?"),h.definite&&d.push("!"),h.typeAnnotation&&d.push(r.call(s,"typeAnnotation")),h.value&&d.push(" = ",r.call(s,"value")),d.push(";"),(0,a.concat)(d);case"ClassDeclaration":case"ClassExpression":case"DeclareClass":return h.declare&&d.push("declare "),h.abstract&&d.push("abstract "),d.push("class"),h.id&&d.push(" ",r.call(s,"id")),h.typeParameters&&d.push(r.call(s,"typeParameters")),h.superClass&&d.push(" extends ",r.call(s,"superClass"),r.call(s,"superTypeParameters")),h.extends&&h.extends.length>0&&d.push(" extends ",(0,a.fromString)(", ").join(r.map(s,"extends"))),h.implements&&h.implements.length>0&&d.push(" implements ",(0,a.fromString)(", ").join(r.map(s,"implements"))),d.push(" ",r.call(s,"body")),"DeclareClass"===h.type?T(r,d):(0,a.concat)(d);case"TemplateElement":return(0,a.fromString)(h.value.raw,i).lockIndentTail();case"TemplateLiteral":var ge=r.map(s,"expressions");return d.push("`"),r.each((function(e){var t=e.getName();d.push(s(e)),t<ge.length&&d.push("${",ge[t],"}")}),"quasis"),d.push("`"),(0,a.concat)(d).lockIndentTail();case"TaggedTemplateExpression":return d.push(r.call(s,"tag")),h.typeParameters&&d.push(r.call(s,"typeParameters")),d.push(r.call(s,"quasi")),(0,a.concat)(d);case"Node":case"Printable":case"SourceLocation":case"Position":case"Statement":case"Function":case"Pattern":case"Expression":case"Declaration":case"Specifier":case"NamedSpecifier":case"Comment":case"Flow":case"FlowType":case"FlowPredicate":case"MemberTypeAnnotation":case"Type":case"TSHasOptionalTypeParameterInstantiation":case"TSHasOptionalTypeParameters":case"TSHasOptionalTypeAnnotation":case"ChainElement":throw Error("unprintable type: "+JSON.stringify(h.type));case"CommentBlock":case"Block":return(0,a.concat)(["/*",(0,a.fromString)(h.value,i),"*/"]);case"CommentLine":case"Line":return(0,a.concat)(["//",(0,a.fromString)(h.value,i)]);case"TypeAnnotation":return h.typeAnnotation?("FunctionTypeAnnotation"!==h.typeAnnotation.type&&d.push(": "),d.push(r.call(s,"typeAnnotation")),(0,a.concat)(d)):(0,a.fromString)("");case"ExistentialTypeParam":case"ExistsTypeAnnotation":return(0,a.fromString)("*",i);case"EmptyTypeAnnotation":return(0,a.fromString)("empty",i);case"AnyTypeAnnotation":return(0,a.fromString)("any",i);case"MixedTypeAnnotation":return(0,a.fromString)("mixed",i);case"ArrayTypeAnnotation":return(0,a.concat)([r.call(s,"elementType"),"[]"]);case"TupleTypeAnnotation":var be=r.map(s,"types"),ve=(0,a.fromString)(", ").join(be).getLineLength(1)<=i.wrapColumn;return ve?i.arrayBracketSpacing?d.push("[ "):d.push("["):d.push("[\n"),r.each((function(e){var t=e.getName();if(e.getValue()){var n=be[t];ve?t>0&&d.push(" "):n=n.indent(i.tabWidth),d.push(n),(t<h.types.length-1||!ve&&l.isTrailingCommaEnabled(i,"arrays"))&&d.push(","),ve||d.push("\n")}else d.push(",")}),"types"),ve&&i.arrayBracketSpacing?d.push(" ]"):d.push("]"),(0,a.concat)(d);case"BooleanTypeAnnotation":return(0,a.fromString)("boolean",i);case"BooleanLiteralTypeAnnotation":return(0,t.default)("boolean"==typeof h.value),(0,a.fromString)(""+h.value,i);case"InterfaceTypeAnnotation":return d.push("interface"),h.extends&&h.extends.length>0&&d.push(" extends ",(0,a.fromString)(", ").join(r.map(s,"extends"))),d.push(" ",r.call(s,"body")),(0,a.concat)(d);case"DeclareFunction":return T(r,["function ",r.call(s,"id"),";"]);case"DeclareModule":return T(r,["module ",r.call(s,"id")," ",r.call(s,"body")]);case"DeclareModuleExports":return T(r,["module.exports",r.call(s,"typeAnnotation")]);case"DeclareVariable":return T(r,["var ",r.call(s,"id"),";"]);case"DeclareExportDeclaration":case"DeclareExportAllDeclaration":return(0,a.concat)(["declare ",E(r,i,s)]);case"EnumDeclaration":return(0,a.concat)(["enum ",r.call(s,"id"),r.call(s,"body")]);case"EnumBooleanBody":case"EnumNumberBody":case"EnumStringBody":case"EnumSymbolBody":return("EnumSymbolBody"===h.type||h.explicitType)&&d.push(" of ",h.type.slice(4,-4).toLowerCase()),d.push(" {\n",(0,a.fromString)("\n").join(r.map(s,"members")).indent(i.tabWidth),"\n}"),(0,a.concat)(d);case"EnumDefaultedMember":return(0,a.concat)([r.call(s,"id"),","]);case"EnumBooleanMember":case"EnumNumberMember":case"EnumStringMember":return(0,a.concat)([r.call(s,"id")," = ",r.call(s,"init"),","]);case"InferredPredicate":return(0,a.fromString)("%checks",i);case"DeclaredPredicate":return(0,a.concat)(["%checks(",r.call(s,"value"),")"]);case"FunctionTypeAnnotation":var xe=r.getParentNode(0),Se=!(c.ObjectTypeCallProperty.check(xe)||c.ObjectTypeInternalSlot.check(xe)&&xe.method||c.DeclareFunction.check(r.getParentNode(2)));Se&&!c.FunctionTypeParam.check(xe)&&!c.TypeAlias.check(xe)&&d.push(": ");var Ee=!!h.typeParameters,Te=Ee||1!==h.params.length||h.params[0].name;return d.push(Ee?r.call(s,"typeParameters"):"",Te?"(":"",x(r,i,s),Te?")":""),h.returnType&&d.push(Se?" => ":": ",r.call(s,"returnType")),(0,a.concat)(d);case"FunctionTypeParam":var _e=r.call(s,"name");return d.push(_e),h.optional&&d.push("?"),_e.infos[0].line&&d.push(": "),d.push(r.call(s,"typeAnnotation")),(0,a.concat)(d);case"GenericTypeAnnotation":return(0,a.concat)([r.call(s,"id"),r.call(s,"typeParameters")]);case"DeclareInterface":d.push("declare ");case"InterfaceDeclaration":case"TSInterfaceDeclaration":return h.declare&&d.push("declare "),d.push("interface ",r.call(s,"id"),r.call(s,"typeParameters")," "),h.extends&&h.extends.length>0&&d.push("extends ",(0,a.fromString)(", ").join(r.map(s,"extends"))," "),h.body&&d.push(r.call(s,"body")),(0,a.concat)(d);case"ClassImplements":case"InterfaceExtends":return(0,a.concat)([r.call(s,"id"),r.call(s,"typeParameters")]);case"IntersectionTypeAnnotation":return(0,a.fromString)(" & ").join(r.map(s,"types"));case"NullableTypeAnnotation":return(0,a.concat)(["?",r.call(s,"typeAnnotation")]);case"NullLiteralTypeAnnotation":return(0,a.fromString)("null",i);case"ThisTypeAnnotation":return(0,a.fromString)("this",i);case"NumberTypeAnnotation":return(0,a.fromString)("number",i);case"ObjectTypeCallProperty":return r.call(s,"value");case"ObjectTypeIndexer":return h.static&&d.push("static "),d.push(_(r,s),"["),h.id&&d.push(r.call(s,"id"),": "),d.push(r.call(s,"key"),"]: ",r.call(s,"value")),(0,a.concat)(d);case"ObjectTypeProperty":return(0,a.concat)([_(r,s),r.call(s,"key"),h.optional?"?":"",": ",r.call(s,"value")]);case"ObjectTypeInternalSlot":return(0,a.concat)([h.static?"static ":"","[[",r.call(s,"id"),"]]",h.optional?"?":"","FunctionTypeAnnotation"!==h.value.type?": ":"",r.call(s,"value")]);case"QualifiedTypeIdentifier":return(0,a.concat)([r.call(s,"qualification"),".",r.call(s,"id")]);case"StringLiteralTypeAnnotation":return(0,a.fromString)(N(h.value,i),i);case"NumberLiteralTypeAnnotation":case"NumericLiteralTypeAnnotation":return(0,t.default)("number"==typeof h.value),(0,a.fromString)(JSON.stringify(h.value),i);case"BigIntLiteralTypeAnnotation":return(0,a.fromString)(h.raw,i);case"StringTypeAnnotation":return(0,a.fromString)("string",i);case"DeclareTypeAlias":d.push("declare ");case"TypeAlias":return(0,a.concat)(["type ",r.call(s,"id"),r.call(s,"typeParameters")," = ",r.call(s,"right"),";"]);case"DeclareOpaqueType":d.push("declare ");case"OpaqueType":return d.push("opaque type ",r.call(s,"id"),r.call(s,"typeParameters")),h.supertype&&d.push(": ",r.call(s,"supertype")),h.impltype&&d.push(" = ",r.call(s,"impltype")),d.push(";"),(0,a.concat)(d);case"TypeCastExpression":return(0,a.concat)(["(",r.call(s,"expression"),r.call(s,"typeAnnotation"),")"]);case"TypeParameterDeclaration":case"TypeParameterInstantiation":return(0,a.concat)(["<",(0,a.fromString)(", ").join(r.map(s,"params")),">"]);case"Variance":return"plus"===h.kind?(0,a.fromString)("+"):"minus"===h.kind?(0,a.fromString)("-"):(0,a.fromString)("");case"TypeParameter":return h.variance&&d.push(_(r,s)),d.push(r.call(s,"name")),h.bound&&d.push(r.call(s,"bound")),h.default&&d.push("=",r.call(s,"default")),(0,a.concat)(d);case"TypeofTypeAnnotation":return(0,a.concat)([(0,a.fromString)("typeof ",i),r.call(s,"argument")]);case"IndexedAccessType":case"OptionalIndexedAccessType":return(0,a.concat)([r.call(s,"objectType"),h.optional?"?.":"","[",r.call(s,"indexType"),"]"]);case"UnionTypeAnnotation":return(0,a.fromString)(" | ").join(r.map(s,"types"));case"VoidTypeAnnotation":return(0,a.fromString)("void",i);case"NullTypeAnnotation":return(0,a.fromString)("null",i);case"SymbolTypeAnnotation":return(0,a.fromString)("symbol",i);case"BigIntTypeAnnotation":return(0,a.fromString)("bigint",i);case"TSType":throw Error("unprintable type: "+JSON.stringify(h.type));case"TSNumberKeyword":return(0,a.fromString)("number",i);case"TSBigIntKeyword":return(0,a.fromString)("bigint",i);case"TSObjectKeyword":return(0,a.fromString)("object",i);case"TSBooleanKeyword":return(0,a.fromString)("boolean",i);case"TSStringKeyword":return(0,a.fromString)("string",i);case"TSSymbolKeyword":return(0,a.fromString)("symbol",i);case"TSAnyKeyword":return(0,a.fromString)("any",i);case"TSVoidKeyword":return(0,a.fromString)("void",i);case"TSIntrinsicKeyword":return(0,a.fromString)("intrinsic",i);case"TSThisType":return(0,a.fromString)("this",i);case"TSNullKeyword":return(0,a.fromString)("null",i);case"TSUndefinedKeyword":return(0,a.fromString)("undefined",i);case"TSUnknownKeyword":return(0,a.fromString)("unknown",i);case"TSNeverKeyword":return(0,a.fromString)("never",i);case"TSArrayType":return(0,a.concat)([r.call(s,"elementType"),"[]"]);case"TSLiteralType":return r.call(s,"literal");case"TSUnionType":return(0,a.fromString)(" | ").join(r.map(s,"types"));case"TSIntersectionType":return(0,a.fromString)(" & ").join(r.map(s,"types"));case"TSConditionalType":return d.push(r.call(s,"checkType")," extends ",r.call(s,"extendsType")," ? ",r.call(s,"trueType")," : ",r.call(s,"falseType")),(0,a.concat)(d);case"TSInferType":return d.push("infer ",r.call(s,"typeParameter")),(0,a.concat)(d);case"TSParenthesizedType":return(0,a.concat)(["(",r.call(s,"typeAnnotation"),")"]);case"TSFunctionType":return(0,a.concat)([r.call(s,"typeParameters"),"(",x(r,i,s),") => ",r.call(s,"typeAnnotation","typeAnnotation")]);case"TSConstructorType":return(0,a.concat)(["new ",r.call(s,"typeParameters"),"(",x(r,i,s),") => ",r.call(s,"typeAnnotation","typeAnnotation")]);case"TSMappedType":return d.push(h.readonly?"readonly ":"","[",r.call(s,"typeParameter"),"]",h.optional?"?":""),h.typeAnnotation&&d.push(": ",r.call(s,"typeAnnotation"),";"),(0,a.concat)(["{\n",(0,a.concat)(d).indent(i.tabWidth),"\n}"]);case"TSTupleType":return(0,a.concat)(["[",(0,a.fromString)(", ").join(r.map(s,"elementTypes")),"]"]);case"TSNamedTupleMember":return d.push(r.call(s,"label")),h.optional&&d.push("?"),d.push(": ",r.call(s,"elementType")),(0,a.concat)(d);case"TSRestType":return(0,a.concat)(["...",r.call(s,"typeAnnotation")]);case"TSOptionalType":return(0,a.concat)([r.call(s,"typeAnnotation"),"?"]);case"TSIndexedAccessType":return(0,a.concat)([r.call(s,"objectType"),"[",r.call(s,"indexType"),"]"]);case"TSTypeOperator":return(0,a.concat)([r.call(s,"operator")," ",r.call(s,"typeAnnotation")]);case"TSTypeLiteral":var ke=(0,a.fromString)("\n").join(r.map(s,"members").map((function(e){return";"!==P(e)?e.concat(";"):e})));return ke.isEmpty()?(0,a.fromString)("{}",i):(d.push("{\n",ke.indent(i.tabWidth),"\n}"),(0,a.concat)(d));case"TSEnumMember":return d.push(r.call(s,"id")),h.initializer&&d.push(" = ",r.call(s,"initializer")),(0,a.concat)(d);case"TSTypeQuery":return(0,a.concat)(["typeof ",r.call(s,"exprName")]);case"TSParameterProperty":return h.accessibility&&d.push(h.accessibility," "),h.export&&d.push("export "),h.static&&d.push("static "),h.readonly&&d.push("readonly "),d.push(r.call(s,"parameter")),(0,a.concat)(d);case"TSTypeReference":return(0,a.concat)([r.call(s,"typeName"),r.call(s,"typeParameters")]);case"TSQualifiedName":return(0,a.concat)([r.call(s,"left"),".",r.call(s,"right")]);case"TSAsExpression":case"TSSatisfiesExpression":var Pe=r.call(s,"expression");return d.push(Pe,"TSSatisfiesExpression"===h.type?" satisfies ":" as ",r.call(s,"typeAnnotation")),(0,a.concat)(d);case"TSTypeCastExpression":return(0,a.concat)([r.call(s,"expression"),r.call(s,"typeAnnotation")]);case"TSNonNullExpression":return(0,a.concat)([r.call(s,"expression"),"!"]);case"TSTypeAnnotation":return(0,a.concat)([": ",r.call(s,"typeAnnotation")]);case"TSIndexSignature":return(0,a.concat)([h.readonly?"readonly ":"","[",r.map(s,"parameters"),"]",r.call(s,"typeAnnotation")]);case"TSPropertySignature":return d.push(_(r,s),h.readonly?"readonly ":""),h.computed?d.push("[",r.call(s,"key"),"]"):d.push(r.call(s,"key")),d.push(h.optional?"?":"",r.call(s,"typeAnnotation")),(0,a.concat)(d);case"TSMethodSignature":return"get"===h.kind?d.push("get "):"set"===h.kind&&d.push("set "),h.computed?d.push("[",r.call(s,"key"),"]"):d.push(r.call(s,"key")),h.optional&&d.push("?"),d.push(r.call(s,"typeParameters"),"(",x(r,i,s),")",r.call(s,"typeAnnotation")),(0,a.concat)(d);case"TSTypePredicate":return h.asserts&&d.push("asserts "),d.push(r.call(s,"parameterName")),h.typeAnnotation&&d.push(" is ",r.call(s,"typeAnnotation","typeAnnotation")),(0,a.concat)(d);case"TSCallSignatureDeclaration":return(0,a.concat)([r.call(s,"typeParameters"),"(",x(r,i,s),")",r.call(s,"typeAnnotation")]);case"TSConstructSignatureDeclaration":return h.typeParameters?d.push("new",r.call(s,"typeParameters")):d.push("new "),d.push("(",x(r,i,s),")",r.call(s,"typeAnnotation")),(0,a.concat)(d);case"TSTypeAliasDeclaration":return(0,a.concat)([h.declare?"declare ":"","type ",r.call(s,"id"),r.call(s,"typeParameters")," = ",r.call(s,"typeAnnotation"),";"]);case"TSTypeParameter":d.push(r.call(s,"name")),xe=r.getParentNode(0);var we=c.TSMappedType.check(xe);return h.constraint&&d.push(we?" in ":" extends ",r.call(s,"constraint")),h.default&&d.push(" = ",r.call(s,"default")),(0,a.concat)(d);case"TSTypeAssertion":return d.push("<",r.call(s,"typeAnnotation"),"> ",r.call(s,"expression")),(0,a.concat)(d);case"TSTypeParameterDeclaration":case"TSTypeParameterInstantiation":return(0,a.concat)(["<",(0,a.fromString)(", ").join(r.map(s,"params")),">"]);case"TSEnumDeclaration":d.push(h.declare?"declare ":"",h.const?"const ":"","enum ",r.call(s,"id"));var Ae=(0,a.fromString)(",\n").join(r.map(s,"members"));return Ae.isEmpty()?d.push(" {}"):d.push(" {\n",Ae.indent(i.tabWidth),"\n}"),(0,a.concat)(d);case"TSExpressionWithTypeArguments":return(0,a.concat)([r.call(s,"expression"),r.call(s,"typeParameters")]);case"TSInterfaceBody":var Ce;return(Ce=(0,a.fromString)("\n").join(r.map(s,"body").map((function(e){return";"!==P(e)?e.concat(";"):e})))).isEmpty()?(0,a.fromString)("{}",i):(0,a.concat)(["{\n",Ce.indent(i.tabWidth),"\n}"]);case"TSImportType":return d.push("import(",r.call(s,"argument"),")"),h.qualifier&&d.push(".",r.call(s,"qualifier")),h.typeParameters&&d.push(r.call(s,"typeParameters")),(0,a.concat)(d);case"TSImportEqualsDeclaration":return h.isExport&&d.push("export "),d.push("import ",r.call(s,"id")," = ",r.call(s,"moduleReference")),O((0,a.concat)(d));case"TSExternalModuleReference":return(0,a.concat)(["require(",r.call(s,"expression"),")"]);case"TSModuleDeclaration":return"TSModuleDeclaration"===(xe=r.getParentNode()).type?d.push("."):(h.declare&&d.push("declare "),h.global||("StringLiteral"===h.id.type||"Literal"===h.id.type&&"string"==typeof h.id.value||h.loc&&h.loc.lines&&h.id.loc&&h.loc.lines.sliceString(h.loc.start,h.id.loc.start).indexOf("module")>=0?d.push("module "):d.push("namespace "))),d.push(r.call(s,"id")),h.body&&(d.push(" "),d.push(r.call(s,"body"))),(0,a.concat)(d);case"TSModuleBlock":var Ie=r.call((function(e){return y(e,i,s)}),"body");return Ie.isEmpty()?d.push("{}"):d.push("{\n",Ie.indent(i.tabWidth),"\n}"),(0,a.concat)(d);case"TSInstantiationExpression":return d.push(r.call(s,"expression"),r.call(s,"typeParameters")),(0,a.concat)(d);case"V8IntrinsicIdentifier":return(0,a.concat)(["%",r.call(s,"name")]);case"TopicReference":return(0,a.fromString)("#");default:throw Error("unknown type: "+JSON.stringify(h.type))}}(r,s,u);if(!p||d.isEmpty())return d;var f=!1,m=function(e,t){var n=[],r=e.getValue();return r.decorators&&r.decorators.length>0&&!l.getParentExportDeclaration(e)?e.each((function(e){n.push(t(e),"\n")}),"decorators"):l.isExportDeclaration(r)&&r.declaration&&r.declaration.decorators&&e.each((function(e){n.push(t(e),"\n")}),"declaration","decorators"),(0,a.concat)(n)}(r,u);return m.isEmpty()?o.avoidRootParens||(f=r.needsParens()):h.push(m),f&&h.unshift("("),h.push(d),f&&h.push(")"),(0,a.concat)(h)}function y(e,n,r){var i=[],s=!1,o=!1;e.each((function(e){var t=e.getValue();t&&("EmptyStatement"!==t.type||t.comments&&t.comments.length>0)&&(c.Comment.check(t)?s=!0:c.Statement.check(t)?o=!0:u.assert(t),i.push({node:t,printed:r(e)}))})),s&&(0,t.default)(!1===o,"Comments may appear as statements in otherwise empty statement lists, but may not coexist with non-Comment nodes.");var p=null,h=i.length,d=[];return i.forEach((function(e,t){var r,i,s=e.printed,o=e.node,c=s.length>1,u=t>0,f=t<h-1,m=o&&o.loc&&o.loc.lines,y=m&&n.reuseWhitespace&&l.getTrueLoc(o,m);if(u)if(y){var g=m.skipSpaces(y.start,!0),b=g?g.line:1,v=y.start.line-b;r=Array(v+1).join("\n")}else r=c?"\n\n":"\n";else r="";if(f)if(y){var x=m.skipSpaces(y.end),S=(x?x.line:m.length)-y.end.line;i=Array(S+1).join("\n")}else i=c?"\n\n":"\n";else i="";d.push(function(e,t){if(!e&&!t)return(0,a.fromString)("");if(!e)return(0,a.fromString)(t);if(!t)return(0,a.fromString)(e);var n=(0,a.fromString)(e),r=(0,a.fromString)(t);return r.length>n.length?r:n}(p,r),s),f?p=i:i&&d.push(i)})),(0,a.concat)(d)}function g(e){var t=[];e.declare&&t.push("declare ");var n=e.accessibility||e.access;return"string"==typeof n&&t.push(n," "),e.static&&t.push("static "),e.override&&t.push("override "),e.abstract&&t.push("abstract "),e.readonly&&t.push("readonly "),t}function b(e,t,n){var r=e.getNode(),i=r.kind,s=[],o=r.value;c.FunctionExpression.check(o)||(o=r),s.push.apply(s,g(r)),o.async&&s.push("async "),o.generator&&s.push("*"),"get"!==i&&"set"!==i||s.push(i," ");var l=e.call(n,"key");return r.computed&&(l=(0,a.concat)(["[",l,"]"])),s.push(l),r.optional&&s.push("?"),r===o?(s.push(e.call(n,"typeParameters"),"(",x(e,t,n),")",e.call(n,"returnType")),r.body?s.push(" ",e.call(n,"body")):s.push(";")):(s.push(e.call(n,"value","typeParameters"),"(",e.call((function(e){return x(e,t,n)}),"value"),")",e.call(n,"value","returnType")),o.body?s.push(" ",e.call(n,"value","body")):s.push(";")),(0,a.concat)(s)}function v(e,t,n){var r=e.map(n,"arguments"),i=l.isTrailingCommaEnabled(t,"parameters"),s=(0,a.fromString)(", ").join(r);return s.getLineLength(1)>t.wrapColumn?(s=(0,a.fromString)(",\n").join(r),(0,a.concat)(["(\n",s.indent(t.tabWidth),i?",\n)":"\n)"])):(0,a.concat)(["(",s,")"])}function x(e,t,n){var r,i=e.getValue(),s=[];i.params?(r=i.params,s=e.map(n,"params")):i.parameters&&(r=i.parameters,s=e.map(n,"parameters")),i.defaults&&e.each((function(e){var t=e.getName(),r=s[t];r&&e.getValue()&&(s[t]=(0,a.concat)([r," = ",n(e)]))}),"defaults"),i.rest&&s.push((0,a.concat)(["...",e.call(n,"rest")]));var o=(0,a.fromString)(", ").join(s);return o.length>1||o.getLineLength(1)>t.wrapColumn?(o=(0,a.fromString)(",\n").join(s),o=l.isTrailingCommaEnabled(t,"parameters")&&!i.rest&&"RestElement"!==r[r.length-1].type?(0,a.concat)([o,",\n"]):(0,a.concat)([o,"\n"]),(0,a.concat)(["\n",o.indent(t.tabWidth)])):o}function S(e,t,n){var r=e.getValue();if(r.assertions&&r.assertions.length>0){var i=[" assert {"],s=e.map(n,"assertions"),o=(0,a.fromString)(", ").join(s);return o.length>1||o.getLineLength(1)>t.wrapColumn?i.push("\n",(0,a.fromString)(",\n").join(s).indent(t.tabWidth),"\n}"):i.push(" ",o," }"),(0,a.concat)(i)}return(0,a.fromString)("")}function E(e,t,n){var r=e.getValue(),i=["export "];r.exportKind&&"type"===r.exportKind&&(r.declaration||i.push("type "));var s=t.objectCurlySpacing;if(c.Declaration.assert(r),(r.default||"ExportDefaultDeclaration"===r.type)&&i.push("default "),r.declaration)i.push(e.call(n,"declaration"));else if(r.specifiers){if(1===r.specifiers.length&&"ExportBatchSpecifier"===r.specifiers[0].type)i.push("*");else if(0===r.specifiers.length)i.push("{}");else if("ExportDefaultSpecifier"===r.specifiers[0].type||"ExportNamespaceSpecifier"===r.specifiers[0].type){var o=[],l=[];if(e.each((function(e){var t=e.getValue();"ExportDefaultSpecifier"===t.type||"ExportNamespaceSpecifier"===t.type?o.push(n(e)):l.push(n(e))}),"specifiers"),o.forEach((function(e,t){t>0&&i.push(", "),i.push(e)})),l.length>0){var u=(0,a.fromString)(", ").join(l);u.getLineLength(1)>t.wrapColumn&&(u=(0,a.concat)([(0,a.fromString)(",\n").join(l).indent(t.tabWidth),","])),o.length>0&&i.push(", "),u.length>1?i.push("{\n",u,"\n}"):t.objectCurlySpacing?i.push("{ ",u," }"):i.push("{",u,"}")}}else i.push(s?"{ ":"{",(0,a.fromString)(", ").join(e.map(n,"specifiers")),s?" }":"}");r.source&&i.push(" from ",e.call(n,"source"),S(e,t,n))}var p=(0,a.concat)(i);return";"===P(p)||r.declaration&&("FunctionDeclaration"===r.declaration.type||"ClassDeclaration"===r.declaration.type||"TSModuleDeclaration"===r.declaration.type||"TSInterfaceDeclaration"===r.declaration.type||"TSEnumDeclaration"===r.declaration.type)||(p=(0,a.concat)([p,";"])),p}function T(e,n){var r=l.getParentExportDeclaration(e);return r?(0,t.default)("DeclareExportDeclaration"===r.type):n.unshift("declare "),(0,a.concat)(n)}function _(e,t){return e.call((function(e){var n=e.getValue();return n?"plus"===n?(0,a.fromString)("+"):"minus"===n?(0,a.fromString)("-"):t(e):(0,a.fromString)("")}),"variance")}function k(e,t){return e.length>1?(0,a.concat)([" ",e]):(0,a.concat)(["\n",O(e).indent(t.tabWidth)])}function P(e){var t=e.lastPos();do{var n=e.charAt(t);if(/\S/.test(n))return n}while(e.prevPos(t))}function w(e){return"}"===P(e)}function A(e){return e.replace(/['"]/g,(function(e){return'"'===e?"'":'"'}))}function C(e){var t=n.getFieldValue(e,"value"),r=n.getFieldValue(e,"extra");if(r&&"string"==typeof r.raw&&t==r.rawValue)return r.raw;if("Literal"===e.type){var i=e.raw;if("string"==typeof i&&t==i)return i}}function I(e){return JSON.stringify(e).replace(/[\u2028\u2029]/g,(function(e){return"\\u"+e.charCodeAt(0).toString(16)}))}function N(e,t){switch(u.assert(e),t.quote){case"auto":var n=I(e),r=A(I(A(e)));return n.length>r.length?r:n;case"single":return A(I(A(e)));default:return I(e)}}function O(e){var t=P(e);return!t||"\n};".indexOf(t)<0?(0,a.concat)([e,";"]):e}return gi.Printer=function e(n){(0,t.default)(this instanceof e);var a=n&&n.tabWidth;function c(e,t){return e=Object.assign({},e,t),function(t){return u(t,e)}}function u(e,s){if((0,t.default)(e instanceof i.default),(s=s||{}).includeComments)return(0,r.printComments)(e,c(s,{includeComments:!1}));var l=n.tabWidth;if(!a){var p=e.getNode().loc;p&&p.lines&&p.lines.guessTabWidth&&(n.tabWidth=p.lines.guessTabWidth())}var h=(0,o.getReprinter)(e),d=h?h(u):m(e,n,s,c(s,{includeComments:!0,avoidRootParens:!1}));return n.tabWidth=l,d}(n=(0,s.normalize)(n)).sourceFileName=null,this.print=function(e){if(!e)return f;var t=u(i.default.from(e),{includeComments:!0,avoidRootParens:!1});return new h(t.toString(n),l.composeSourceMaps(n.inputSourceMap,t.getSourceMap(n.sourceMapName,n.sourceRoot)))},this.printGenerically=function(e){if(!e)return f;var t=i.default.from(e),a=n.reuseWhitespace;n.reuseWhitespace=!1;var s=new h(function e(t){return(0,r.printComments)(t,(function(t){return m(t,n,{avoidRootParens:!1},e)}))}(t).toString(n));return n.reuseWhitespace=a,s}},gi}(),s=Rr();function o(e,t){return new a.Printer(t).print(e)}function l(e){process.stdout.write(e)}Object.defineProperty(e,"visit",{enumerable:!0,get:function(){return s.visit}}),e.print=o,e.prettyPrint=function(e,t){return new a.Printer(t).printGenerically(e)},e.run=function(e,t){return function(e,t,r){n.default.readFile(e,"utf-8",(function(e,n){e?console.error(e):function(e,t,n){var r=n&&n.writeback||l;t((0,i.parse)(e,n),(function(e){r(o(e,n).code)}))}(n,t,r)}))}(process.argv[2],e,t)}}(Vt)),Vt);const ki=_i.types,Pi=_i.types.builders,wi=_i.types.namedTypes,Ai=["window","document","console"],Ci=Object.keys({AggregateError:!1,Array:!1,ArrayBuffer:!1,Atomics:!1,BigInt:!1,BigInt64Array:!1,BigUint64Array:!1,Boolean:!1,DataView:!1,Date:!1,decodeURI:!1,decodeURIComponent:!1,encodeURI:!1,encodeURIComponent:!1,Error:!1,escape:!1,eval:!1,EvalError:!1,FinalizationRegistry:!1,Float32Array:!1,Float64Array:!1,Function:!1,globalThis:!1,Infinity:!1,Int16Array:!1,Int32Array:!1,Int8Array:!1,Intl:!1,isFinite:!1,isNaN:!1,Iterator:!1,JSON:!1,Map:!1,Math:!1,NaN:!1,Number:!1,Object:!1,parseFloat:!1,parseInt:!1,Promise:!1,Proxy:!1,RangeError:!1,ReferenceError:!1,Reflect:!1,RegExp:!1,Set:!1,SharedArrayBuffer:!1,String:!1,Symbol:!1,SyntaxError:!1,TypeError:!1,Uint16Array:!1,Uint32Array:!1,Uint8Array:!1,Uint8ClampedArray:!1,undefined:!1,unescape:!1,URIError:!1,WeakMap:!1,WeakRef:!1,WeakSet:!1}),Ii=e=>wi.Identifier.check(e),Ni=e=>wi.Literal.check(e),Oi=e=>wi.ExpressionStatement.check(e),Di=e=>Oi(e)&&Mi(e.expression.left)&&(e=>wi.ThisExpression.check(e))(e.expression.left.object),Li=e=>wi.SequenceExpression.check(e),ji=e=>wi.ExportDefaultDeclaration.check(e),Mi=e=>wi.MemberExpression.check(e),Bi=e=>wi.ImportDeclaration.check(e),Fi=e=>wi.TSTypeAliasDeclaration.check(e),Vi=e=>wi.TSInterfaceDeclaration.check(e),Ri=e=>wi.ExportNamedDeclaration.check(e);function qi(...e){return e.reduce(((e,t)=>(...n)=>e(t(...n))))}function Ui(e){return function(e){return"template"===e.name}(e)&&!s(ta(It,e))&&!Zi(e)&&!Qi(e)}function zi({scope:e,node:t}){return t.object?zi({node:t.object,scope:e}):!!((n=t)&&n.raw||(({name:e})=>Ci.includes(e))(t)||(({name:e})=>Ai.includes(e))(t)||(e=>wi.NewExpression.check(e))(t)||function(e,t){return((n=!1)=>(ki.visit(t,{visitIdentifier(t){e.lookup(ja(t.node))&&(n=!0),this.abort()}}),n))()}(e,t));var n}function Wi(e){return!(!e[Lt]&&!ea(e))}function Gi(e){return"slot"===e.name}function Ji(e){return!!e[Dt]}function $i(e){return e.type===gt.TAG}function Hi(e){return e.type===gt.TEXT}function Ki(e){return e.isRoot}const Xi=(()=>{const e=/^on/;return t=>e.test(t.name)})();function Yi(e){return!!(e.expressions||os(e).some((e=>Yi(e)))||e.nodes&&e.nodes.some((e=>Hi(e)&&Yi(e))))}const Qi=qi(Boolean,na),Zi=qi(Boolean,ra),ea=qi(Boolean,aa);function ta(e,t){return t.attributes&&t.attributes.find((t=>ja(t)===e))}function na(e){return ta(wt,e)}function ra(e){return ta(At,e)}function ia(e){return ta(Ct,e)}function aa(e){return ta(Ot,e)}function sa(){return Pi.literal(null)}function oa(e,t){const n=Pi.property("init",Pi.identifier(e),t,!1);return n.sho,n}qi(Boolean,ia);const la=/\r\n?|\n/g;function ca(e,t,n){const{column:r,line:i}=function(e,t){const n=function(e){return e.split(la)}(e.slice(0,t));return{line:n.length,column:n[n.length-1].length}}(t,n.start);return`${"\n".repeat(i-1)}${" ".repeat(r+1)}${e}`}const ua=e=>e.filter(((e,t,n)=>n.indexOf(e)===t)),pa=["circle","ellipse","line","path","polygon","polyline","rect","stop","use"],ha=["button","data","input","select","li","meter","option","output","progress","textarea","param"],da=ua(["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","animation","audio","canvas","clipPath","color-profile","cursor","defs","desc","discard","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignObject","g","glyph","glyphRef","handler","hatch","hatchpath","hkern","iframe","image","linearGradient","listener","marker","mask","mesh","meshgradient","meshpatch","meshrow","metadata","missing-glyph","mpath","pattern","prefetch","radialGradient","script","set","solidColor","solidcolor","style","svg","switch","symbol","tbreak","text","textArea","textPath","title","tref","tspan","unknown","video","view","vkern"].concat(pa)).sort(),fa=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"];function ma(e){return e.join("|")}function ya(...e){return RegExp(`^/?(?:${ma(e.map(ma))})$`,"i")}ya(ua(["a","abbr","address","article","aside","audio","b","bdi","bdo","blockquote","body","canvas","caption","cite","code","colgroup","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","html","i","iframe","ins","kbd","label","legend","main","map","mark","math","menu","nav","noscript","object","ol","optgroup","p","picture","pre","q","rb","rp","rt","rtc","ruby","s","samp","script","section","select","slot","small","span","strong","style","sub","summary","sup","svg","table","tbody","td","template","tfoot","th","thead","time","title","tr","u","ul","var","video"].concat(fa).concat(ha)).sort()),ya(da),ya(fa),ya(pa);const ga=ya(ha);ya(["disabled","visible","checked","readonly","required","allowfullscreen","autofocus","autoplay","compact","controls","default","formnovalidate","hidden","ismap","itemscope","loop","multiple","muted","noresize","noshade","novalidate","nowrap","open","reversed","seamless","selected","sortable","truespeed","typemustmatch"]);var ba={quot:'"',amp:"&",apos:"'",lt:"<",gt:">",nbsp:" ",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:"♦"};const va=/&(\S+);/g,xa=/^[\da-fA-F]+$/,Sa=/^\d+$/;function Ea(e){return e.replace(va,((e,t)=>{const[n,r]=t;return"#"===n?"x"===r?function(e){const t=e.substr(2);return xa.test(t)?String.fromCodePoint(parseInt(t,16)):e}(t):function(e){const t=e.substr(1);return Sa.test(t)?String.fromCodePoint(parseInt(t,10)):e}(t):ba[t]||t}))}function Ta(e,t){return e.replace(RegExp("\\\\"+t,"gm"),t)}function _a(e,t,n){if(1===e.parts.length)return Ha(e.expressions[0],t,n);const r=function(e,t){return e.expressions.reduce(((n,r,i)=>{const a=i?e.expressions[i-1].end:e.start,s=Ea(t.substring(a,r.start));return n.push(0===i?function(e){return(e.trimStart||e.trimLeft).apply(e)}(s):s),i===e.expressions.length-1&&n.push(Ea(function(e){return(e.trimEnd||e.trimRight).apply(e)}(t.substring(r.end,e.end)))),n}),[]).filter((e=>!(0===e.trim().indexOf("<!")))).map((t=>e.unescape?Ta(t,e.unescape):t))}(e,n),i=r.reduce(((r,i,a)=>{const s=e.expressions[a];return[...r,Pi.literal(i),s?Ha(s,t,n):sa()]}),[]).filter((e=>!Ni(e)||e.value));return ps(i)}function ka(e,t,n,r,i){switch(!0){case Hi(e):return function(e,t,n,r){return Pi.objectExpression([oa(Tt,Pi.memberExpression(Pi.identifier(vt),Pi.identifier("TEXT"),!1)),oa("childNodeIndex",Pi.literal(r)),oa(_t,Ja(_a(e,t,n)))])}(e,t,n,r);case"value"===e.name&&(a=i.name,ga.test(a))&&!("progress"===i.name):return function(e,t,n){return Pi.objectExpression([oa(Tt,Pi.memberExpression(Pi.identifier(vt),Pi.identifier("VALUE"),!1)),oa(_t,ms(e,t,n))])}(e,t,n);case"ref"===e.name:return function(e,t,n){return Pi.objectExpression([oa(Tt,Pi.memberExpression(Pi.identifier(vt),Pi.identifier("REF"),!1)),oa(_t,ms(e,t,n))])}(e,t,n);case Xi(e):return function(e,t,n){return Pi.objectExpression([oa(Tt,Pi.memberExpression(Pi.identifier(vt),Pi.identifier("EVENT"),!1)),oa(kt,Pi.literal(e.name)),oa(_t,ms(e,t,n))])}(e,t,n);default:return function(e,t,n,r){const i=e[Mt];return Pi.objectExpression([oa(Tt,Pi.memberExpression(Pi.identifier(vt),Pi.identifier("ATTRIBUTE"),!1)),oa("isBoolean",Pi.literal(!("hidden"!==e.name&&(t[Lt]||(a=t,a.isRoot&&!a.isNestedRoot)||i||!e[jt])))),oa(kt,i?sa():Pi.literal(e.name)),oa(_t,ms(e,n,r))]);var a}(e,i,t,n)}var a}function Pa(e,t,n){return(r=e,os(r).filter(Yi)).map((r=>ka(r,t,n,0,e)));var r}var wa,Aa,Ca={},Ia={exports:{}};function Na(){return wa||(wa=1,function(e,t){!function(e){var t=[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,80,3,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,343,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,330,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,726,6,110,6,6,9,4759,9,787719,239],n=[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,71,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,2,60,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,328,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,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,42,9,8936,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,496,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,4153,7,221,3,5761,15,7472,16,621,2467,541,1507,4938,6,4191],r="ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢎࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೝೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-Ა-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-Ꟑꟑꟓꟕ-ꟲ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",i={3:"abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile",5:"class enum extends super const export import",6:"enum",strict:"implements interface let package private protected public static yield",strictBind:"eval arguments"},a="break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this",s={5:a,"5module":a+" export import",6:a+" const class extends export import super"},o=/^in(stanceof)?$/,l=RegExp("["+r+"]"),c=RegExp("["+r+"·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ-ᫎᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・]");function u(e,t){for(var n=65536,r=0;r<t.length;r+=2){if((n+=t[r])>e)return!1;if((n+=t[r+1])>=e)return!0}return!1}function p(e,t){return e<65?36===e:e<91||(e<97?95===e:e<123||(e<=65535?e>=170&&l.test(String.fromCharCode(e)):!1!==t&&u(e,n)))}function h(e,r){return e<48?36===e:e<58||!(e<65)&&(e<91||(e<97?95===e:e<123||(e<=65535?e>=170&&c.test(String.fromCharCode(e)):!1!==r&&(u(e,n)||u(e,t)))))}var d=function(e,t){void 0===t&&(t={}),this.label=e,this.keyword=t.keyword,this.beforeExpr=!!t.beforeExpr,this.startsExpr=!!t.startsExpr,this.isLoop=!!t.isLoop,this.isAssign=!!t.isAssign,this.prefix=!!t.prefix,this.postfix=!!t.postfix,this.binop=t.binop||null,this.updateContext=null};function f(e,t){return new d(e,{beforeExpr:!0,binop:t})}var m={beforeExpr:!0},y={startsExpr:!0},g={};function b(e,t){return void 0===t&&(t={}),t.keyword=e,g[e]=new d(e,t)}var v={num:new d("num",y),regexp:new d("regexp",y),string:new d("string",y),name:new d("name",y),privateId:new d("privateId",y),eof:new d("eof"),bracketL:new d("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new d("]"),braceL:new d("{",{beforeExpr:!0,startsExpr:!0}),braceR:new d("}"),parenL:new d("(",{beforeExpr:!0,startsExpr:!0}),parenR:new d(")"),comma:new d(",",m),semi:new d(";",m),colon:new d(":",m),dot:new d("."),question:new d("?",m),questionDot:new d("?."),arrow:new d("=>",m),template:new d("template"),invalidTemplate:new d("invalidTemplate"),ellipsis:new d("...",m),backQuote:new d("`",y),dollarBraceL:new d("${",{beforeExpr:!0,startsExpr:!0}),eq:new d("=",{beforeExpr:!0,isAssign:!0}),assign:new d("_=",{beforeExpr:!0,isAssign:!0}),incDec:new d("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new d("!/~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:f("||",1),logicalAND:f("&&",2),bitwiseOR:f("|",3),bitwiseXOR:f("^",4),bitwiseAND:f("&",5),equality:f("==/!=/===/!==",6),relational:f("</>/<=/>=",7),bitShift:f("<</>>/>>>",8),plusMin:new d("+/-",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:f("%",10),star:f("*",10),slash:f("/",10),starstar:new d("**",{beforeExpr:!0}),coalesce:f("??",1),_break:b("break"),_case:b("case",m),_catch:b("catch"),_continue:b("continue"),_debugger:b("debugger"),_default:b("default",m),_do:b("do",{isLoop:!0,beforeExpr:!0}),_else:b("else",m),_finally:b("finally"),_for:b("for",{isLoop:!0}),_function:b("function",y),_if:b("if"),_return:b("return",m),_switch:b("switch"),_throw:b("throw",m),_try:b("try"),_var:b("var"),_const:b("const"),_while:b("while",{isLoop:!0}),_with:b("with"),_new:b("new",{beforeExpr:!0,startsExpr:!0}),_this:b("this",y),_super:b("super",y),_class:b("class",y),_extends:b("extends",m),_export:b("export"),_import:b("import",y),_null:b("null",y),_true:b("true",y),_false:b("false",y),_in:b("in",{beforeExpr:!0,binop:7}),_instanceof:b("instanceof",{beforeExpr:!0,binop:7}),_typeof:b("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:b("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:b("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})},x=/\r\n?|\n|\u2028|\u2029/,S=RegExp(x.source,"g");function E(e){return 10===e||13===e||8232===e||8233===e}function T(e,t,n){void 0===n&&(n=e.length);for(var r=t;r<n;r++){var i=e.charCodeAt(r);if(E(i))return r<n-1&&13===i&&10===e.charCodeAt(r+1)?r+2:r+1}return-1}var _=/[\u1680\u2000-\u200a\u202f\u205f\u3000\ufeff]/,k=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g,P=Object.prototype,w=P.hasOwnProperty,A=P.toString,C=Object.hasOwn||function(e,t){return w.call(e,t)},I=Array.isArray||function(e){return"[object Array]"===A.call(e)},N=Object.create(null);function O(e){return N[e]||(N[e]=RegExp("^(?:"+e.replace(/ /g,"|")+")$"))}function D(e){return e<=65535?String.fromCharCode(e):String.fromCharCode(55296+((e-=65536)>>10),56320+(1023&e))}var L=/(?:[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])/,j=function(e,t){this.line=e,this.column=t};j.prototype.offset=function(e){return new j(this.line,this.column+e)};var M=function(e,t,n){this.start=t,this.end=n,null!==e.sourceFile&&(this.source=e.sourceFile)};function B(e,t){for(var n=1,r=0;;){var i=T(e,r,t);if(i<0)return new j(n,t-r);++n,r=i}}var F={ecmaVersion:null,sourceType:"script",onInsertedSemicolon:null,onTrailingComma:null,allowReserved:null,allowReturnOutsideFunction:!1,allowImportExportEverywhere:!1,allowAwaitOutsideFunction:null,allowSuperOutsideMethod:null,allowHashBang:!1,checkPrivateFields:!0,locations:!1,onToken:null,onComment:null,ranges:!1,program:null,sourceFile:null,directSourceFile:null,preserveParens:!1},V=!1;function R(e,t){return 2|(e?4:0)|(t?8:0)}var q=function(e,t,n){this.options=e=function(e){var t={};for(var n in F)t[n]=e&&C(e,n)?e[n]:F[n];if("latest"===t.ecmaVersion?t.ecmaVersion=1e8:null==t.ecmaVersion?(!V&&"object"==typeof console&&console.warn&&(V=!0,console.warn("Since Acorn 8.0.0, options.ecmaVersion is required.\nDefaulting to 2020, but this will stop working in the future.")),t.ecmaVersion=11):t.ecmaVersion>=2015&&(t.ecmaVersion-=2009),null==t.allowReserved&&(t.allowReserved=t.ecmaVersion<5),e&&null!=e.allowHashBang||(t.allowHashBang=t.ecmaVersion>=14),I(t.onToken)){var r=t.onToken;t.onToken=function(e){return r.push(e)}}return I(t.onComment)&&(t.onComment=function(e,t){return function(n,r,i,a,s,o){var l={type:n?"Block":"Line",value:r,start:i,end:a};e.locations&&(l.loc=new M(this,s,o)),e.ranges&&(l.range=[i,a]),t.push(l)}}(t,t.onComment)),t}(e),this.sourceFile=e.sourceFile,this.keywords=O(s[e.ecmaVersion>=6?6:"module"===e.sourceType?"5module":5]);var r="";!0!==e.allowReserved&&(r=i[e.ecmaVersion>=6?6:5===e.ecmaVersion?5:3],"module"===e.sourceType&&(r+=" await")),this.reservedWords=O(r);var a=(r?r+" ":"")+i.strict;this.reservedWordsStrict=O(a),this.reservedWordsStrictBind=O(a+" "+i.strictBind),this.input=t+"",this.containsEsc=!1,n?(this.pos=n,this.lineStart=this.input.lastIndexOf("\n",n-1)+1,this.curLine=this.input.slice(0,this.lineStart).split(x).length):(this.pos=this.lineStart=0,this.curLine=1),this.type=v.eof,this.value=null,this.start=this.end=this.pos,this.startLoc=this.endLoc=this.curPosition(),this.lastTokEndLoc=this.lastTokStartLoc=null,this.lastTokStart=this.lastTokEnd=this.pos,this.context=this.initialContext(),this.exprAllowed=!0,this.inModule="module"===e.sourceType,this.strict=this.inModule||this.strictDirective(this.pos),this.potentialArrowAt=-1,this.potentialArrowInForAwait=!1,this.yieldPos=this.awaitPos=this.awaitIdentPos=0,this.labels=[],this.undefinedExports=Object.create(null),0===this.pos&&e.allowHashBang&&"#!"===this.input.slice(0,2)&&this.skipLineComment(2),this.scopeStack=[],this.enterScope(1),this.regexpState=null,this.privateNameStack=[]},U={inFunction:{configurable:!0},inGenerator:{configurable:!0},inAsync:{configurable:!0},canAwait:{configurable:!0},allowSuper:{configurable:!0},allowDirectSuper:{configurable:!0},treatFunctionsAsVar:{configurable:!0},allowNewDotTarget:{configurable:!0},inClassStaticBlock:{configurable:!0}};q.prototype.parse=function(){var e=this.options.program||this.startNode();return this.nextToken(),this.parseTopLevel(e)},U.inFunction.get=function(){return(2&this.currentVarScope().flags)>0},U.inGenerator.get=function(){return(8&this.currentVarScope().flags)>0},U.inAsync.get=function(){return(4&this.currentVarScope().flags)>0},U.canAwait.get=function(){for(var e=this.scopeStack.length-1;e>=0;e--){var t=this.scopeStack[e].flags;if(768&t)return!1;if(2&t)return(4&t)>0}return this.inModule&&this.options.ecmaVersion>=13||this.options.allowAwaitOutsideFunction},U.allowSuper.get=function(){return(64&this.currentThisScope().flags)>0||this.options.allowSuperOutsideMethod},U.allowDirectSuper.get=function(){return(128&this.currentThisScope().flags)>0},U.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())},U.allowNewDotTarget.get=function(){for(var e=this.scopeStack.length-1;e>=0;e--){var t=this.scopeStack[e].flags;if(768&t||2&t&&!(16&t))return!0}return!1},U.inClassStaticBlock.get=function(){return(256&this.currentVarScope().flags)>0},q.extend=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];for(var n=this,r=0;r<e.length;r++)n=e[r](n);return n},q.parse=function(e,t){return new this(t,e).parse()},q.parseExpressionAt=function(e,t,n){var r=new this(n,e,t);return r.nextToken(),r.parseExpression()},q.tokenizer=function(e,t){return new this(t,e)},Object.defineProperties(q.prototype,U);var z=q.prototype,W=/^(?:'((?:\\[^]|[^'\\])*?)'|"((?:\\[^]|[^"\\])*?)")/;z.strictDirective=function(e){if(this.options.ecmaVersion<5)return!1;for(;;){k.lastIndex=e,e+=k.exec(this.input)[0].length;var t=W.exec(this.input.slice(e));if(!t)return!1;if("use strict"===(t[1]||t[2])){k.lastIndex=e+t[0].length;var n=k.exec(this.input),r=n.index+n[0].length,i=this.input.charAt(r);return";"===i||"}"===i||x.test(n[0])&&!(/[(`.[+\-/*%<>=,?^&]/.test(i)||"!"===i&&"="===this.input.charAt(r+1))}e+=t[0].length,k.lastIndex=e,e+=k.exec(this.input)[0].length,";"===this.input[e]&&e++}},z.eat=function(e){return this.type===e&&(this.next(),!0)},z.isContextual=function(e){return this.type===v.name&&this.value===e&&!this.containsEsc},z.eatContextual=function(e){return!!this.isContextual(e)&&(this.next(),!0)},z.expectContextual=function(e){this.eatContextual(e)||this.unexpected()},z.canInsertSemicolon=function(){return this.type===v.eof||this.type===v.braceR||x.test(this.input.slice(this.lastTokEnd,this.start))},z.insertSemicolon=function(){if(this.canInsertSemicolon())return this.options.onInsertedSemicolon&&this.options.onInsertedSemicolon(this.lastTokEnd,this.lastTokEndLoc),!0},z.semicolon=function(){this.eat(v.semi)||this.insertSemicolon()||this.unexpected()},z.afterTrailingComma=function(e,t){if(this.type===e)return this.options.onTrailingComma&&this.options.onTrailingComma(this.lastTokStart,this.lastTokStartLoc),t||this.next(),!0},z.expect=function(e){this.eat(e)||this.unexpected()},z.unexpected=function(e){this.raise(null!=e?e:this.start,"Unexpected token")};var G=function(){this.shorthandAssign=this.trailingComma=this.parenthesizedAssign=this.parenthesizedBind=this.doubleProto=-1};z.checkPatternErrors=function(e,t){if(e){e.trailingComma>-1&&this.raiseRecoverable(e.trailingComma,"Comma is not permitted after the rest element");var n=t?e.parenthesizedAssign:e.parenthesizedBind;n>-1&&this.raiseRecoverable(n,t?"Assigning to rvalue":"Parenthesized pattern")}},z.checkExpressionErrors=function(e,t){if(!e)return!1;var n=e.shorthandAssign,r=e.doubleProto;if(!t)return n>=0||r>=0;n>=0&&this.raise(n,"Shorthand property assignments are valid only in destructuring patterns"),r>=0&&this.raiseRecoverable(r,"Redefinition of __proto__ property")},z.checkYieldAwaitInDefaultParams=function(){this.yieldPos&&(!this.awaitPos||this.yieldPos<this.awaitPos)&&this.raise(this.yieldPos,"Yield expression cannot be a default value"),this.awaitPos&&this.raise(this.awaitPos,"Await expression cannot be a default value")},z.isSimpleAssignTarget=function(e){return"ParenthesizedExpression"===e.type?this.isSimpleAssignTarget(e.expression):"Identifier"===e.type||"MemberExpression"===e.type};var J=q.prototype;J.parseTopLevel=function(e){var t=Object.create(null);for(e.body||(e.body=[]);this.type!==v.eof;){var n=this.parseStatement(null,!0,t);e.body.push(n)}if(this.inModule)for(var r=0,i=Object.keys(this.undefinedExports);r<i.length;r+=1){var a=i[r];this.raiseRecoverable(this.undefinedExports[a].start,"Export '"+a+"' is not defined")}return this.adaptDirectivePrologue(e.body),this.next(),e.sourceType=this.options.sourceType,this.finishNode(e,"Program")};var $={kind:"loop"},H={kind:"switch"};J.isLet=function(e){if(this.options.ecmaVersion<6||!this.isContextual("let"))return!1;k.lastIndex=this.pos;var t=k.exec(this.input),n=this.pos+t[0].length,r=this.input.charCodeAt(n);if(91===r||92===r)return!0;if(e)return!1;if(123===r||r>55295&&r<56320)return!0;if(p(r,!0)){for(var i=n+1;h(r=this.input.charCodeAt(i),!0);)++i;if(92===r||r>55295&&r<56320)return!0;var a=this.input.slice(n,i);if(!o.test(a))return!0}return!1},J.isAsyncFunction=function(){if(this.options.ecmaVersion<8||!this.isContextual("async"))return!1;k.lastIndex=this.pos;var e,t=k.exec(this.input),n=this.pos+t[0].length;return!(x.test(this.input.slice(this.pos,n))||"function"!==this.input.slice(n,n+8)||n+8!==this.input.length&&(h(e=this.input.charCodeAt(n+8))||e>55295&&e<56320))},J.parseStatement=function(e,t,n){var r,i=this.type,a=this.startNode();switch(this.isLet(e)&&(i=v._var,r="let"),i){case v._break:case v._continue:return this.parseBreakContinueStatement(a,i.keyword);case v._debugger:return this.parseDebuggerStatement(a);case v._do:return this.parseDoStatement(a);case v._for:return this.parseForStatement(a);case v._function:return e&&(this.strict||"if"!==e&&"label"!==e)&&this.options.ecmaVersion>=6&&this.unexpected(),this.parseFunctionStatement(a,!1,!e);case v._class:return e&&this.unexpected(),this.parseClass(a,!0);case v._if:return this.parseIfStatement(a);case v._return:return this.parseReturnStatement(a);case v._switch:return this.parseSwitchStatement(a);case v._throw:return this.parseThrowStatement(a);case v._try:return this.parseTryStatement(a);case v._const:case v._var:return r=r||this.value,e&&"var"!==r&&this.unexpected(),this.parseVarStatement(a,r);case v._while:return this.parseWhileStatement(a);case v._with:return this.parseWithStatement(a);case v.braceL:return this.parseBlock(!0,a);case v.semi:return this.parseEmptyStatement(a);case v._export:case v._import:if(this.options.ecmaVersion>10&&i===v._import){k.lastIndex=this.pos;var s=k.exec(this.input),o=this.pos+s[0].length,l=this.input.charCodeAt(o);if(40===l||46===l)return this.parseExpressionStatement(a,this.parseExpression())}return this.options.allowImportExportEverywhere||(t||this.raise(this.start,"'import' and 'export' may only appear at the top level"),this.inModule||this.raise(this.start,"'import' and 'export' may appear only with 'sourceType: module'")),i===v._import?this.parseImport(a):this.parseExport(a,n);default:if(this.isAsyncFunction())return e&&this.unexpected(),this.next(),this.parseFunctionStatement(a,!0,!e);var c=this.value,u=this.parseExpression();return i===v.name&&"Identifier"===u.type&&this.eat(v.colon)?this.parseLabeledStatement(a,c,u,e):this.parseExpressionStatement(a,u)}},J.parseBreakContinueStatement=function(e,t){var n="break"===t;this.next(),this.eat(v.semi)||this.insertSemicolon()?e.label=null:this.type!==v.name?this.unexpected():(e.label=this.parseIdent(),this.semicolon());for(var r=0;r<this.labels.length;++r){var i=this.labels[r];if(null==e.label||i.name===e.label.name){if(null!=i.kind&&(n||"loop"===i.kind))break;if(e.label&&n)break}}return r===this.labels.length&&this.raise(e.start,"Unsyntactic "+t),this.finishNode(e,n?"BreakStatement":"ContinueStatement")},J.parseDebuggerStatement=function(e){return this.next(),this.semicolon(),this.finishNode(e,"DebuggerStatement")},J.parseDoStatement=function(e){return this.next(),this.labels.push($),e.body=this.parseStatement("do"),this.labels.pop(),this.expect(v._while),e.test=this.parseParenExpression(),this.options.ecmaVersion>=6?this.eat(v.semi):this.semicolon(),this.finishNode(e,"DoWhileStatement")},J.parseForStatement=function(e){this.next();var t=this.options.ecmaVersion>=9&&this.canAwait&&this.eatContextual("await")?this.lastTokStart:-1;if(this.labels.push($),this.enterScope(0),this.expect(v.parenL),this.type===v.semi)return t>-1&&this.unexpected(t),this.parseFor(e,null);var n=this.isLet();if(this.type===v._var||this.type===v._const||n){var r=this.startNode(),i=n?"let":this.value;return this.next(),this.parseVar(r,!0,i),this.finishNode(r,"VariableDeclaration"),(this.type===v._in||this.options.ecmaVersion>=6&&this.isContextual("of"))&&1===r.declarations.length?(this.options.ecmaVersion>=9&&(this.type===v._in?t>-1&&this.unexpected(t):e.await=t>-1),this.parseForIn(e,r)):(t>-1&&this.unexpected(t),this.parseFor(e,r))}var a=this.isContextual("let"),s=!1,o=this.containsEsc,l=new G,c=this.start,u=t>-1?this.parseExprSubscripts(l,"await"):this.parseExpression(!0,l);return this.type===v._in||(s=this.options.ecmaVersion>=6&&this.isContextual("of"))?(t>-1?(this.type===v._in&&this.unexpected(t),e.await=!0):s&&this.options.ecmaVersion>=8&&(u.start!==c||o||"Identifier"!==u.type||"async"!==u.name?this.options.ecmaVersion>=9&&(e.await=!1):this.unexpected()),a&&s&&this.raise(u.start,"The left-hand side of a for-of loop may not start with 'let'."),this.toAssignable(u,!1,l),this.checkLValPattern(u),this.parseForIn(e,u)):(this.checkExpressionErrors(l,!0),t>-1&&this.unexpected(t),this.parseFor(e,u))},J.parseFunctionStatement=function(e,t,n){return this.next(),this.parseFunction(e,X|(n?0:Y),!1,t)},J.parseIfStatement=function(e){return this.next(),e.test=this.parseParenExpression(),e.consequent=this.parseStatement("if"),e.alternate=this.eat(v._else)?this.parseStatement("if"):null,this.finishNode(e,"IfStatement")},J.parseReturnStatement=function(e){return this.inFunction||this.options.allowReturnOutsideFunction||this.raise(this.start,"'return' outside of function"),this.next(),this.eat(v.semi)||this.insertSemicolon()?e.argument=null:(e.argument=this.parseExpression(),this.semicolon()),this.finishNode(e,"ReturnStatement")},J.parseSwitchStatement=function(e){var t;this.next(),e.discriminant=this.parseParenExpression(),e.cases=[],this.expect(v.braceL),this.labels.push(H),this.enterScope(0);for(var n=!1;this.type!==v.braceR;)if(this.type===v._case||this.type===v._default){var r=this.type===v._case;t&&this.finishNode(t,"SwitchCase"),e.cases.push(t=this.startNode()),t.consequent=[],this.next(),r?t.test=this.parseExpression():(n&&this.raiseRecoverable(this.lastTokStart,"Multiple default clauses"),n=!0,t.test=null),this.expect(v.colon)}else t||this.unexpected(),t.consequent.push(this.parseStatement(null));return this.exitScope(),t&&this.finishNode(t,"SwitchCase"),this.next(),this.labels.pop(),this.finishNode(e,"SwitchStatement")},J.parseThrowStatement=function(e){return this.next(),x.test(this.input.slice(this.lastTokEnd,this.start))&&this.raise(this.lastTokEnd,"Illegal newline after throw"),e.argument=this.parseExpression(),this.semicolon(),this.finishNode(e,"ThrowStatement")};var K=[];J.parseCatchClauseParam=function(){var e=this.parseBindingAtom(),t="Identifier"===e.type;return this.enterScope(t?32:0),this.checkLValPattern(e,t?4:2),this.expect(v.parenR),e},J.parseTryStatement=function(e){if(this.next(),e.block=this.parseBlock(),e.handler=null,this.type===v._catch){var t=this.startNode();this.next(),this.eat(v.parenL)?t.param=this.parseCatchClauseParam():(this.options.ecmaVersion<10&&this.unexpected(),t.param=null,this.enterScope(0)),t.body=this.parseBlock(!1),this.exitScope(),e.handler=this.finishNode(t,"CatchClause")}return e.finalizer=this.eat(v._finally)?this.parseBlock():null,e.handler||e.finalizer||this.raise(e.start,"Missing catch or finally clause"),this.finishNode(e,"TryStatement")},J.parseVarStatement=function(e,t,n){return this.next(),this.parseVar(e,!1,t,n),this.semicolon(),this.finishNode(e,"VariableDeclaration")},J.parseWhileStatement=function(e){return this.next(),e.test=this.parseParenExpression(),this.labels.push($),e.body=this.parseStatement("while"),this.labels.pop(),this.finishNode(e,"WhileStatement")},J.parseWithStatement=function(e){return this.strict&&this.raise(this.start,"'with' in strict mode"),this.next(),e.object=this.parseParenExpression(),e.body=this.parseStatement("with"),this.finishNode(e,"WithStatement")},J.parseEmptyStatement=function(e){return this.next(),this.finishNode(e,"EmptyStatement")},J.parseLabeledStatement=function(e,t,n,r){for(var i=0,a=this.labels;i<a.length;i+=1)a[i].name===t&&this.raise(n.start,"Label '"+t+"' is already declared");for(var s=this.type.isLoop?"loop":this.type===v._switch?"switch":null,o=this.labels.length-1;o>=0;o--){var l=this.labels[o];if(l.statementStart!==e.start)break;l.statementStart=this.start,l.kind=s}return this.labels.push({name:t,kind:s,statementStart:this.start}),e.body=this.parseStatement(r?-1===r.indexOf("label")?r+"label":r:"label"),this.labels.pop(),e.label=n,this.finishNode(e,"LabeledStatement")},J.parseExpressionStatement=function(e,t){return e.expression=t,this.semicolon(),this.finishNode(e,"ExpressionStatement")},J.parseBlock=function(e,t,n){for(void 0===e&&(e=!0),void 0===t&&(t=this.startNode()),t.body=[],this.expect(v.braceL),e&&this.enterScope(0);this.type!==v.braceR;){var r=this.parseStatement(null);t.body.push(r)}return n&&(this.strict=!1),this.next(),e&&this.exitScope(),this.finishNode(t,"BlockStatement")},J.parseFor=function(e,t){return e.init=t,this.expect(v.semi),e.test=this.type===v.semi?null:this.parseExpression(),this.expect(v.semi),e.update=this.type===v.parenR?null:this.parseExpression(),this.expect(v.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,"ForStatement")},J.parseForIn=function(e,t){var n=this.type===v._in;return this.next(),"VariableDeclaration"===t.type&&null!=t.declarations[0].init&&(!n||this.options.ecmaVersion<8||this.strict||"var"!==t.kind||"Identifier"!==t.declarations[0].id.type)&&this.raise(t.start,(n?"for-in":"for-of")+" loop variable declaration may not have an initializer"),e.left=t,e.right=n?this.parseExpression():this.parseMaybeAssign(),this.expect(v.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,n?"ForInStatement":"ForOfStatement")},J.parseVar=function(e,t,n,r){for(e.declarations=[],e.kind=n;;){var i=this.startNode();if(this.parseVarId(i,n),this.eat(v.eq)?i.init=this.parseMaybeAssign(t):r||"const"!==n||this.type===v._in||this.options.ecmaVersion>=6&&this.isContextual("of")?r||"Identifier"===i.id.type||t&&(this.type===v._in||this.isContextual("of"))?i.init=null:this.raise(this.lastTokEnd,"Complex binding patterns require an initialization value"):this.unexpected(),e.declarations.push(this.finishNode(i,"VariableDeclarator")),!this.eat(v.comma))break}return e},J.parseVarId=function(e,t){e.id=this.parseBindingAtom(),this.checkLValPattern(e.id,"var"===t?1:2,!1)};var X=1,Y=2;function Q(e,t){var n=t.key.name,r=e[n],i="true";return"MethodDefinition"!==t.type||"get"!==t.kind&&"set"!==t.kind||(i=(t.static?"s":"i")+t.kind),"iget"===r&&"iset"===i||"iset"===r&&"iget"===i||"sget"===r&&"sset"===i||"sset"===r&&"sget"===i?(e[n]="true",!1):!!r||(e[n]=i,!1)}function Z(e,t){var n=e.computed,r=e.key;return!n&&("Identifier"===r.type&&r.name===t||"Literal"===r.type&&r.value===t)}J.parseFunction=function(e,t,n,r,i){this.initFunction(e),(this.options.ecmaVersion>=9||this.options.ecmaVersion>=6&&!r)&&(this.type===v.star&&t&Y&&this.unexpected(),e.generator=this.eat(v.star)),this.options.ecmaVersion>=8&&(e.async=!!r),t&X&&(e.id=4&t&&this.type!==v.name?null:this.parseIdent(),!e.id||t&Y||this.checkLValSimple(e.id,this.strict||e.generator||e.async?this.treatFunctionsAsVar?1:2:3));var a=this.yieldPos,s=this.awaitPos,o=this.awaitIdentPos;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(R(e.async,e.generator)),t&X||(e.id=this.type===v.name?this.parseIdent():null),this.parseFunctionParams(e),this.parseFunctionBody(e,n,!1,i),this.yieldPos=a,this.awaitPos=s,this.awaitIdentPos=o,this.finishNode(e,t&X?"FunctionDeclaration":"FunctionExpression")},J.parseFunctionParams=function(e){this.expect(v.parenL),e.params=this.parseBindingList(v.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()},J.parseClass=function(e,t){this.next();var n=this.strict;this.strict=!0,this.parseClassId(e,t),this.parseClassSuper(e);var r=this.enterClassBody(),i=this.startNode(),a=!1;for(i.body=[],this.expect(v.braceL);this.type!==v.braceR;){var s=this.parseClassElement(null!==e.superClass);s&&(i.body.push(s),"MethodDefinition"===s.type&&"constructor"===s.kind?(a&&this.raiseRecoverable(s.start,"Duplicate constructor in the same class"),a=!0):s.key&&"PrivateIdentifier"===s.key.type&&Q(r,s)&&this.raiseRecoverable(s.key.start,"Identifier '#"+s.key.name+"' has already been declared"))}return this.strict=n,this.next(),e.body=this.finishNode(i,"ClassBody"),this.exitClassBody(),this.finishNode(e,t?"ClassDeclaration":"ClassExpression")},J.parseClassElement=function(e){if(this.eat(v.semi))return null;var t=this.options.ecmaVersion,n=this.startNode(),r="",i=!1,a=!1,s="method",o=!1;if(this.eatContextual("static")){if(t>=13&&this.eat(v.braceL))return this.parseClassStaticBlock(n),n;this.isClassElementNameStart()||this.type===v.star?o=!0:r="static"}if(n.static=o,!r&&t>=8&&this.eatContextual("async")&&(!this.isClassElementNameStart()&&this.type!==v.star||this.canInsertSemicolon()?r="async":a=!0),!r&&(t>=9||!a)&&this.eat(v.star)&&(i=!0),!r&&!a&&!i){var l=this.value;(this.eatContextual("get")||this.eatContextual("set"))&&(this.isClassElementNameStart()?s=l:r=l)}if(r?(n.computed=!1,n.key=this.startNodeAt(this.lastTokStart,this.lastTokStartLoc),n.key.name=r,this.finishNode(n.key,"Identifier")):this.parseClassElementName(n),t<13||this.type===v.parenL||"method"!==s||i||a){var c=!n.static&&Z(n,"constructor"),u=c&&e;c&&"method"!==s&&this.raise(n.key.start,"Constructor can't have get/set modifier"),n.kind=c?"constructor":s,this.parseClassMethod(n,i,a,u)}else this.parseClassField(n);return n},J.isClassElementNameStart=function(){return this.type===v.name||this.type===v.privateId||this.type===v.num||this.type===v.string||this.type===v.bracketL||this.type.keyword},J.parseClassElementName=function(e){this.type===v.privateId?("constructor"===this.value&&this.raise(this.start,"Classes can't have an element named '#constructor'"),e.computed=!1,e.key=this.parsePrivateIdent()):this.parsePropertyName(e)},J.parseClassMethod=function(e,t,n,r){var i=e.key;"constructor"===e.kind?(t&&this.raise(i.start,"Constructor can't be a generator"),n&&this.raise(i.start,"Constructor can't be an async method")):e.static&&Z(e,"prototype")&&this.raise(i.start,"Classes may not have a static property named prototype");var a=e.value=this.parseMethod(t,n,r);return"get"===e.kind&&0!==a.params.length&&this.raiseRecoverable(a.start,"getter should have no params"),"set"===e.kind&&1!==a.params.length&&this.raiseRecoverable(a.start,"setter should have exactly one param"),"set"===e.kind&&"RestElement"===a.params[0].type&&this.raiseRecoverable(a.params[0].start,"Setter cannot use rest params"),this.finishNode(e,"MethodDefinition")},J.parseClassField=function(e){return Z(e,"constructor")?this.raise(e.key.start,"Classes can't have a field named 'constructor'"):e.static&&Z(e,"prototype")&&this.raise(e.key.start,"Classes can't have a static field named 'prototype'"),this.eat(v.eq)?(this.enterScope(576),e.value=this.parseMaybeAssign(),this.exitScope()):e.value=null,this.semicolon(),this.finishNode(e,"PropertyDefinition")},J.parseClassStaticBlock=function(e){e.body=[];var t=this.labels;for(this.labels=[],this.enterScope(320);this.type!==v.braceR;){var n=this.parseStatement(null);e.body.push(n)}return this.next(),this.exitScope(),this.labels=t,this.finishNode(e,"StaticBlock")},J.parseClassId=function(e,t){this.type===v.name?(e.id=this.parseIdent(),t&&this.checkLValSimple(e.id,2,!1)):(!0===t&&this.unexpected(),e.id=null)},J.parseClassSuper=function(e){e.superClass=this.eat(v._extends)?this.parseExprSubscripts(null,!1):null},J.enterClassBody=function(){var e={declared:Object.create(null),used:[]};return this.privateNameStack.push(e),e.declared},J.exitClassBody=function(){var e=this.privateNameStack.pop(),t=e.declared,n=e.used;if(this.options.checkPrivateFields)for(var r=this.privateNameStack.length,i=0===r?null:this.privateNameStack[r-1],a=0;a<n.length;++a){var s=n[a];C(t,s.name)||(i?i.used.push(s):this.raiseRecoverable(s.start,"Private field '#"+s.name+"' must be declared in an enclosing class"))}},J.parseExportAllDeclaration=function(e,t){return this.options.ecmaVersion>=11&&(this.eatContextual("as")?(e.exported=this.parseModuleExportName(),this.checkExport(t,e.exported,this.lastTokStart)):e.exported=null),this.expectContextual("from"),this.type!==v.string&&this.unexpected(),e.source=this.parseExprAtom(),this.options.ecmaVersion>=16&&(e.attributes=this.parseWithClause()),this.semicolon(),this.finishNode(e,"ExportAllDeclaration")},J.parseExport=function(e,t){if(this.next(),this.eat(v.star))return this.parseExportAllDeclaration(e,t);if(this.eat(v._default))return this.checkExport(t,"default",this.lastTokStart),e.declaration=this.parseExportDefaultDeclaration(),this.finishNode(e,"ExportDefaultDeclaration");if(this.shouldParseExportStatement())e.declaration=this.parseExportDeclaration(e),"VariableDeclaration"===e.declaration.type?this.checkVariableExport(t,e.declaration.declarations):this.checkExport(t,e.declaration.id,e.declaration.id.start),e.specifiers=[],e.source=null,this.options.ecmaVersion>=16&&(e.attributes=[]);else{if(e.declaration=null,e.specifiers=this.parseExportSpecifiers(t),this.eatContextual("from"))this.type!==v.string&&this.unexpected(),e.source=this.parseExprAtom(),this.options.ecmaVersion>=16&&(e.attributes=this.parseWithClause());else{for(var n=0,r=e.specifiers;n<r.length;n+=1){var i=r[n];this.checkUnreserved(i.local),this.checkLocalExport(i.local),"Literal"===i.local.type&&this.raise(i.local.start,"A string literal cannot be used as an exported binding without `from`.")}e.source=null,this.options.ecmaVersion>=16&&(e.attributes=[])}this.semicolon()}return this.finishNode(e,"ExportNamedDeclaration")},J.parseExportDeclaration=function(e){return this.parseStatement(null)},J.parseExportDefaultDeclaration=function(){var e;if(this.type===v._function||(e=this.isAsyncFunction())){var t=this.startNode();return this.next(),e&&this.next(),this.parseFunction(t,4|X,!1,e)}if(this.type===v._class){var n=this.startNode();return this.parseClass(n,"nullableID")}var r=this.parseMaybeAssign();return this.semicolon(),r},J.checkExport=function(e,t,n){e&&("string"!=typeof t&&(t="Identifier"===t.type?t.name:t.value),C(e,t)&&this.raiseRecoverable(n,"Duplicate export '"+t+"'"),e[t]=!0)},J.checkPatternExport=function(e,t){var n=t.type;if("Identifier"===n)this.checkExport(e,t,t.start);else if("ObjectPattern"===n)for(var r=0,i=t.properties;r<i.length;r+=1){var a=i[r];this.checkPatternExport(e,a)}else if("ArrayPattern"===n)for(var s=0,o=t.elements;s<o.length;s+=1){var l=o[s];l&&this.checkPatternExport(e,l)}else"Property"===n?this.checkPatternExport(e,t.value):"AssignmentPattern"===n?this.checkPatternExport(e,t.left):"RestElement"===n&&this.checkPatternExport(e,t.argument)},J.checkVariableExport=function(e,t){if(e)for(var n=0,r=t;n<r.length;n+=1){var i=r[n];this.checkPatternExport(e,i.id)}},J.shouldParseExportStatement=function(){return"var"===this.type.keyword||"const"===this.type.keyword||"class"===this.type.keyword||"function"===this.type.keyword||this.isLet()||this.isAsyncFunction()},J.parseExportSpecifier=function(e){var t=this.startNode();return t.local=this.parseModuleExportName(),t.exported=this.eatContextual("as")?this.parseModuleExportName():t.local,this.checkExport(e,t.exported,t.exported.start),this.finishNode(t,"ExportSpecifier")},J.parseExportSpecifiers=function(e){var t=[],n=!0;for(this.expect(v.braceL);!this.eat(v.braceR);){if(n)n=!1;else if(this.expect(v.comma),this.afterTrailingComma(v.braceR))break;t.push(this.parseExportSpecifier(e))}return t},J.parseImport=function(e){return this.next(),this.type===v.string?(e.specifiers=K,e.source=this.parseExprAtom()):(e.specifiers=this.parseImportSpecifiers(),this.expectContextual("from"),e.source=this.type===v.string?this.parseExprAtom():this.unexpected()),this.options.ecmaVersion>=16&&(e.attributes=this.parseWithClause()),this.semicolon(),this.finishNode(e,"ImportDeclaration")},J.parseImportSpecifier=function(){var e=this.startNode();return e.imported=this.parseModuleExportName(),this.eatContextual("as")?e.local=this.parseIdent():(this.checkUnreserved(e.imported),e.local=e.imported),this.checkLValSimple(e.local,2),this.finishNode(e,"ImportSpecifier")},J.parseImportDefaultSpecifier=function(){var e=this.startNode();return e.local=this.parseIdent(),this.checkLValSimple(e.local,2),this.finishNode(e,"ImportDefaultSpecifier")},J.parseImportNamespaceSpecifier=function(){var e=this.startNode();return this.next(),this.expectContextual("as"),e.local=this.parseIdent(),this.checkLValSimple(e.local,2),this.finishNode(e,"ImportNamespaceSpecifier")},J.parseImportSpecifiers=function(){var e=[],t=!0;if(this.type===v.name&&(e.push(this.parseImportDefaultSpecifier()),!this.eat(v.comma)))return e;if(this.type===v.star)return e.push(this.parseImportNamespaceSpecifier()),e;for(this.expect(v.braceL);!this.eat(v.braceR);){if(t)t=!1;else if(this.expect(v.comma),this.afterTrailingComma(v.braceR))break;e.push(this.parseImportSpecifier())}return e},J.parseWithClause=function(){var e=[];if(!this.eat(v._with))return e;this.expect(v.braceL);for(var t={},n=!0;!this.eat(v.braceR);){if(n)n=!1;else if(this.expect(v.comma),this.afterTrailingComma(v.braceR))break;var r=this.parseImportAttribute(),i="Identifier"===r.key.type?r.key.name:r.key.value;C(t,i)&&this.raiseRecoverable(r.key.start,"Duplicate attribute key '"+i+"'"),t[i]=!0,e.push(r)}return e},J.parseImportAttribute=function(){var e=this.startNode();return e.key=this.type===v.string?this.parseExprAtom():this.parseIdent("never"!==this.options.allowReserved),this.expect(v.colon),this.type!==v.string&&this.unexpected(),e.value=this.parseExprAtom(),this.finishNode(e,"ImportAttribute")},J.parseModuleExportName=function(){if(this.options.ecmaVersion>=13&&this.type===v.string){var e=this.parseLiteral(this.value);return L.test(e.value)&&this.raise(e.start,"An export name cannot include a lone surrogate."),e}return this.parseIdent(!0)},J.adaptDirectivePrologue=function(e){for(var t=0;t<e.length&&this.isDirectiveCandidate(e[t]);++t)e[t].directive=e[t].expression.raw.slice(1,-1)},J.isDirectiveCandidate=function(e){return this.options.ecmaVersion>=5&&"ExpressionStatement"===e.type&&"Literal"===e.expression.type&&"string"==typeof e.expression.value&&('"'===this.input[e.start]||"'"===this.input[e.start])};var ee=q.prototype;ee.toAssignable=function(e,t,n){if(this.options.ecmaVersion>=6&&e)switch(e.type){case"Identifier":this.inAsync&&"await"===e.name&&this.raise(e.start,"Cannot use 'await' as identifier inside an async function");break;case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":case"RestElement":break;case"ObjectExpression":e.type="ObjectPattern",n&&this.checkPatternErrors(n,!0);for(var r=0,i=e.properties;r<i.length;r+=1){var a=i[r];this.toAssignable(a,t),"RestElement"!==a.type||"ArrayPattern"!==a.argument.type&&"ObjectPattern"!==a.argument.type||this.raise(a.argument.start,"Unexpected token")}break;case"Property":"init"!==e.kind&&this.raise(e.key.start,"Object pattern can't contain getter or setter"),this.toAssignable(e.value,t);break;case"ArrayExpression":e.type="ArrayPattern",n&&this.checkPatternErrors(n,!0),this.toAssignableList(e.elements,t);break;case"SpreadElement":e.type="RestElement",this.toAssignable(e.argument,t),"AssignmentPattern"===e.argument.type&&this.raise(e.argument.start,"Rest elements cannot have a default value");break;case"AssignmentExpression":"="!==e.operator&&this.raise(e.left.end,"Only '=' operator can be used for specifying default value."),e.type="AssignmentPattern",delete e.operator,this.toAssignable(e.left,t);break;case"ParenthesizedExpression":this.toAssignable(e.expression,t,n);break;case"ChainExpression":this.raiseRecoverable(e.start,"Optional chaining cannot appear in left-hand side");break;case"MemberExpression":if(!t)break;default:this.raise(e.start,"Assigning to rvalue")}else n&&this.checkPatternErrors(n,!0);return e},ee.toAssignableList=function(e,t){for(var n=e.length,r=0;r<n;r++){var i=e[r];i&&this.toAssignable(i,t)}if(n){var a=e[n-1];6===this.options.ecmaVersion&&t&&a&&"RestElement"===a.type&&"Identifier"!==a.argument.type&&this.unexpected(a.argument.start)}return e},ee.parseSpread=function(e){var t=this.startNode();return this.next(),t.argument=this.parseMaybeAssign(!1,e),this.finishNode(t,"SpreadElement")},ee.parseRestBinding=function(){var e=this.startNode();return this.next(),6===this.options.ecmaVersion&&this.type!==v.name&&this.unexpected(),e.argument=this.parseBindingAtom(),this.finishNode(e,"RestElement")},ee.parseBindingAtom=function(){if(this.options.ecmaVersion>=6)switch(this.type){case v.bracketL:var e=this.startNode();return this.next(),e.elements=this.parseBindingList(v.bracketR,!0,!0),this.finishNode(e,"ArrayPattern");case v.braceL:return this.parseObj(!0)}return this.parseIdent()},ee.parseBindingList=function(e,t,n,r){for(var i=[],a=!0;!this.eat(e);)if(a?a=!1:this.expect(v.comma),t&&this.type===v.comma)i.push(null);else{if(n&&this.afterTrailingComma(e))break;if(this.type===v.ellipsis){var s=this.parseRestBinding();this.parseBindingListItem(s),i.push(s),this.type===v.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.expect(e);break}i.push(this.parseAssignableListItem(r))}return i},ee.parseAssignableListItem=function(e){var t=this.parseMaybeDefault(this.start,this.startLoc);return this.parseBindingListItem(t),t},ee.parseBindingListItem=function(e){return e},ee.parseMaybeDefault=function(e,t,n){if(n=n||this.parseBindingAtom(),this.options.ecmaVersion<6||!this.eat(v.eq))return n;var r=this.startNodeAt(e,t);return r.left=n,r.right=this.parseMaybeAssign(),this.finishNode(r,"AssignmentPattern")},ee.checkLValSimple=function(e,t,n){void 0===t&&(t=0);var r=0!==t;switch(e.type){case"Identifier":this.strict&&this.reservedWordsStrictBind.test(e.name)&&this.raiseRecoverable(e.start,(r?"Binding ":"Assigning to ")+e.name+" in strict mode"),r&&(2===t&&"let"===e.name&&this.raiseRecoverable(e.start,"let is disallowed as a lexically bound name"),n&&(C(n,e.name)&&this.raiseRecoverable(e.start,"Argument name clash"),n[e.name]=!0),5!==t&&this.declareName(e.name,t,e.start));break;case"ChainExpression":this.raiseRecoverable(e.start,"Optional chaining cannot appear in left-hand side");break;case"MemberExpression":r&&this.raiseRecoverable(e.start,"Binding member expression");break;case"ParenthesizedExpression":return r&&this.raiseRecoverable(e.start,"Binding parenthesized expression"),this.checkLValSimple(e.expression,t,n);default:this.raise(e.start,(r?"Binding":"Assigning to")+" rvalue")}},ee.checkLValPattern=function(e,t,n){switch(void 0===t&&(t=0),e.type){case"ObjectPattern":for(var r=0,i=e.properties;r<i.length;r+=1){var a=i[r];this.checkLValInnerPattern(a,t,n)}break;case"ArrayPattern":for(var s=0,o=e.elements;s<o.length;s+=1){var l=o[s];l&&this.checkLValInnerPattern(l,t,n)}break;default:this.checkLValSimple(e,t,n)}},ee.checkLValInnerPattern=function(e,t,n){switch(void 0===t&&(t=0),e.type){case"Property":this.checkLValInnerPattern(e.value,t,n);break;case"AssignmentPattern":this.checkLValPattern(e.left,t,n);break;case"RestElement":this.checkLValPattern(e.argument,t,n);break;default:this.checkLValPattern(e,t,n)}};var te=function(e,t,n,r,i){this.token=e,this.isExpr=!!t,this.preserveSpace=!!n,this.override=r,this.generator=!!i},ne={b_stat:new te("{",!1),b_expr:new te("{",!0),b_tmpl:new te("${",!1),p_stat:new te("(",!1),p_expr:new te("(",!0),q_tmpl:new te("`",!0,!0,(function(e){return e.tryReadTemplateToken()})),f_stat:new te("function",!1),f_expr:new te("function",!0),f_expr_gen:new te("function",!0,!1,null,!0),f_gen:new te("function",!1,!1,null,!0)},re=q.prototype;re.initialContext=function(){return[ne.b_stat]},re.curContext=function(){return this.context[this.context.length-1]},re.braceIsBlock=function(e){var t=this.curContext();return t===ne.f_expr||t===ne.f_stat||(e!==v.colon||t!==ne.b_stat&&t!==ne.b_expr?e===v._return||e===v.name&&this.exprAllowed?x.test(this.input.slice(this.lastTokEnd,this.start)):e===v._else||e===v.semi||e===v.eof||e===v.parenR||e===v.arrow||(e===v.braceL?t===ne.b_stat:e!==v._var&&e!==v._const&&e!==v.name&&!this.exprAllowed):!t.isExpr)},re.inGeneratorContext=function(){for(var e=this.context.length-1;e>=1;e--){var t=this.context[e];if("function"===t.token)return t.generator}return!1},re.updateContext=function(e){var t,n=this.type;n.keyword&&e===v.dot?this.exprAllowed=!1:(t=n.updateContext)?t.call(this,e):this.exprAllowed=n.beforeExpr},re.overrideContext=function(e){this.curContext()!==e&&(this.context[this.context.length-1]=e)},v.parenR.updateContext=v.braceR.updateContext=function(){if(1!==this.context.length){var e=this.context.pop();e===ne.b_stat&&"function"===this.curContext().token&&(e=this.context.pop()),this.exprAllowed=!e.isExpr}else this.exprAllowed=!0},v.braceL.updateContext=function(e){this.context.push(this.braceIsBlock(e)?ne.b_stat:ne.b_expr),this.exprAllowed=!0},v.dollarBraceL.updateContext=function(){this.context.push(ne.b_tmpl),this.exprAllowed=!0},v.parenL.updateContext=function(e){var t=e===v._if||e===v._for||e===v._with||e===v._while;this.context.push(t?ne.p_stat:ne.p_expr),this.exprAllowed=!0},v.incDec.updateContext=function(){},v._function.updateContext=v._class.updateContext=function(e){!e.beforeExpr||e===v._else||e===v.semi&&this.curContext()!==ne.p_stat||e===v._return&&x.test(this.input.slice(this.lastTokEnd,this.start))||(e===v.colon||e===v.braceL)&&this.curContext()===ne.b_stat?this.context.push(ne.f_stat):this.context.push(ne.f_expr),this.exprAllowed=!1},v.colon.updateContext=function(){"function"===this.curContext().token&&this.context.pop(),this.exprAllowed=!0},v.backQuote.updateContext=function(){this.curContext()===ne.q_tmpl?this.context.pop():this.context.push(ne.q_tmpl),this.exprAllowed=!1},v.star.updateContext=function(e){if(e===v._function){var t=this.context.length-1;this.context[t]===ne.f_expr?this.context[t]=ne.f_expr_gen:this.context[t]=ne.f_gen}this.exprAllowed=!0},v.name.updateContext=function(e){var t=!1;this.options.ecmaVersion>=6&&e!==v.dot&&("of"===this.value&&!this.exprAllowed||"yield"===this.value&&this.inGeneratorContext())&&(t=!0),this.exprAllowed=t};var ie=q.prototype;function ae(e){return"Identifier"===e.type||"ParenthesizedExpression"===e.type&&ae(e.expression)}function se(e){return"MemberExpression"===e.type&&"PrivateIdentifier"===e.property.type||"ChainExpression"===e.type&&se(e.expression)||"ParenthesizedExpression"===e.type&&se(e.expression)}ie.checkPropClash=function(e,t,n){if(!(this.options.ecmaVersion>=9&&"SpreadElement"===e.type||this.options.ecmaVersion>=6&&(e.computed||e.method||e.shorthand))){var r,i=e.key;switch(i.type){case"Identifier":r=i.name;break;case"Literal":r=i.value+"";break;default:return}var a=e.kind;if(this.options.ecmaVersion>=6)"__proto__"===r&&"init"===a&&(t.proto&&(n?n.doubleProto<0&&(n.doubleProto=i.start):this.raiseRecoverable(i.start,"Redefinition of __proto__ property")),t.proto=!0);else{var s=t[r="$"+r];s?("init"===a?this.strict&&s.init||s.get||s.set:s.init||s[a])&&this.raiseRecoverable(i.start,"Redefinition of property"):s=t[r]={init:!1,get:!1,set:!1},s[a]=!0}}},ie.parseExpression=function(e,t){var n=this.start,r=this.startLoc,i=this.parseMaybeAssign(e,t);if(this.type===v.comma){var a=this.startNodeAt(n,r);for(a.expressions=[i];this.eat(v.comma);)a.expressions.push(this.parseMaybeAssign(e,t));return this.finishNode(a,"SequenceExpression")}return i},ie.parseMaybeAssign=function(e,t,n){if(this.isContextual("yield")){if(this.inGenerator)return this.parseYield(e);this.exprAllowed=!1}var r=!1,i=-1,a=-1,s=-1;t?(i=t.parenthesizedAssign,a=t.trailingComma,s=t.doubleProto,t.parenthesizedAssign=t.trailingComma=-1):(t=new G,r=!0);var o=this.start,l=this.startLoc;this.type!==v.parenL&&this.type!==v.name||(this.potentialArrowAt=this.start,this.potentialArrowInForAwait="await"===e);var c=this.parseMaybeConditional(e,t);if(n&&(c=n.call(this,c,o,l)),this.type.isAssign){var u=this.startNodeAt(o,l);return u.operator=this.value,this.type===v.eq&&(c=this.toAssignable(c,!1,t)),r||(t.parenthesizedAssign=t.trailingComma=t.doubleProto=-1),t.shorthandAssign>=c.start&&(t.shorthandAssign=-1),this.type===v.eq?this.checkLValPattern(c):this.checkLValSimple(c),u.left=c,this.next(),u.right=this.parseMaybeAssign(e),s>-1&&(t.doubleProto=s),this.finishNode(u,"AssignmentExpression")}return r&&this.checkExpressionErrors(t,!0),i>-1&&(t.parenthesizedAssign=i),a>-1&&(t.trailingComma=a),c},ie.parseMaybeConditional=function(e,t){var n=this.start,r=this.startLoc,i=this.parseExprOps(e,t);if(this.checkExpressionErrors(t))return i;if(this.eat(v.question)){var a=this.startNodeAt(n,r);return a.test=i,a.consequent=this.parseMaybeAssign(),this.expect(v.colon),a.alternate=this.parseMaybeAssign(e),this.finishNode(a,"ConditionalExpression")}return i},ie.parseExprOps=function(e,t){var n=this.start,r=this.startLoc,i=this.parseMaybeUnary(t,!1,!1,e);return this.checkExpressionErrors(t)||i.start===n&&"ArrowFunctionExpression"===i.type?i:this.parseExprOp(i,n,r,-1,e)},ie.parseExprOp=function(e,t,n,r,i){var a=this.type.binop;if(null!=a&&(!i||this.type!==v._in)&&a>r){var s=this.type===v.logicalOR||this.type===v.logicalAND,o=this.type===v.coalesce;o&&(a=v.logicalAND.binop);var l=this.value;this.next();var c=this.start,u=this.startLoc,p=this.parseExprOp(this.parseMaybeUnary(null,!1,!1,i),c,u,a,i),h=this.buildBinary(t,n,e,p,l,s||o);return(s&&this.type===v.coalesce||o&&(this.type===v.logicalOR||this.type===v.logicalAND))&&this.raiseRecoverable(this.start,"Logical expressions and coalesce expressions cannot be mixed. Wrap either by parentheses"),this.parseExprOp(h,t,n,r,i)}return e},ie.buildBinary=function(e,t,n,r,i,a){"PrivateIdentifier"===r.type&&this.raise(r.start,"Private identifier can only be left side of binary expression");var s=this.startNodeAt(e,t);return s.left=n,s.operator=i,s.right=r,this.finishNode(s,a?"LogicalExpression":"BinaryExpression")},ie.parseMaybeUnary=function(e,t,n,r){var i,a=this.start,s=this.startLoc;if(this.isContextual("await")&&this.canAwait)i=this.parseAwait(r),t=!0;else if(this.type.prefix){var o=this.startNode(),l=this.type===v.incDec;o.operator=this.value,o.prefix=!0,this.next(),o.argument=this.parseMaybeUnary(null,!0,l,r),this.checkExpressionErrors(e,!0),l?this.checkLValSimple(o.argument):this.strict&&"delete"===o.operator&&ae(o.argument)?this.raiseRecoverable(o.start,"Deleting local variable in strict mode"):"delete"===o.operator&&se(o.argument)?this.raiseRecoverable(o.start,"Private fields can not be deleted"):t=!0,i=this.finishNode(o,l?"UpdateExpression":"UnaryExpression")}else if(t||this.type!==v.privateId){if(i=this.parseExprSubscripts(e,r),this.checkExpressionErrors(e))return i;for(;this.type.postfix&&!this.canInsertSemicolon();){var c=this.startNodeAt(a,s);c.operator=this.value,c.prefix=!1,c.argument=i,this.checkLValSimple(i),this.next(),i=this.finishNode(c,"UpdateExpression")}}else(r||0===this.privateNameStack.length)&&this.options.checkPrivateFields&&this.unexpected(),i=this.parsePrivateIdent(),this.type!==v._in&&this.unexpected();return n||!this.eat(v.starstar)?i:t?void this.unexpected(this.lastTokStart):this.buildBinary(a,s,i,this.parseMaybeUnary(null,!1,!1,r),"**",!1)},ie.parseExprSubscripts=function(e,t){var n=this.start,r=this.startLoc,i=this.parseExprAtom(e,t);if("ArrowFunctionExpression"===i.type&&")"!==this.input.slice(this.lastTokStart,this.lastTokEnd))return i;var a=this.parseSubscripts(i,n,r,!1,t);return e&&"MemberExpression"===a.type&&(e.parenthesizedAssign>=a.start&&(e.parenthesizedAssign=-1),e.parenthesizedBind>=a.start&&(e.parenthesizedBind=-1),e.trailingComma>=a.start&&(e.trailingComma=-1)),a},ie.parseSubscripts=function(e,t,n,r,i){for(var a=this.options.ecmaVersion>=8&&"Identifier"===e.type&&"async"===e.name&&this.lastTokEnd===e.end&&!this.canInsertSemicolon()&&e.end-e.start==5&&this.potentialArrowAt===e.start,s=!1;;){var o=this.parseSubscript(e,t,n,r,a,s,i);if(o.optional&&(s=!0),o===e||"ArrowFunctionExpression"===o.type){if(s){var l=this.startNodeAt(t,n);l.expression=o,o=this.finishNode(l,"ChainExpression")}return o}e=o}},ie.shouldParseAsyncArrow=function(){return!this.canInsertSemicolon()&&this.eat(v.arrow)},ie.parseSubscriptAsyncArrow=function(e,t,n,r){return this.parseArrowExpression(this.startNodeAt(e,t),n,!0,r)},ie.parseSubscript=function(e,t,n,r,i,a,s){var o=this.options.ecmaVersion>=11,l=o&&this.eat(v.questionDot);r&&l&&this.raise(this.lastTokStart,"Optional chaining cannot appear in the callee of new expressions");var c=this.eat(v.bracketL);if(c||l&&this.type!==v.parenL&&this.type!==v.backQuote||this.eat(v.dot)){var u=this.startNodeAt(t,n);u.object=e,c?(u.property=this.parseExpression(),this.expect(v.bracketR)):this.type===v.privateId&&"Super"!==e.type?u.property=this.parsePrivateIdent():u.property=this.parseIdent("never"!==this.options.allowReserved),u.computed=!!c,o&&(u.optional=l),e=this.finishNode(u,"MemberExpression")}else if(!r&&this.eat(v.parenL)){var p=new G,h=this.yieldPos,d=this.awaitPos,f=this.awaitIdentPos;this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0;var m=this.parseExprList(v.parenR,this.options.ecmaVersion>=8,!1,p);if(i&&!l&&this.shouldParseAsyncArrow())return this.checkPatternErrors(p,!1),this.checkYieldAwaitInDefaultParams(),this.awaitIdentPos>0&&this.raise(this.awaitIdentPos,"Cannot use 'await' as identifier inside an async function"),this.yieldPos=h,this.awaitPos=d,this.awaitIdentPos=f,this.parseSubscriptAsyncArrow(t,n,m,s);this.checkExpressionErrors(p,!0),this.yieldPos=h||this.yieldPos,this.awaitPos=d||this.awaitPos,this.awaitIdentPos=f||this.awaitIdentPos;var y=this.startNodeAt(t,n);y.callee=e,y.arguments=m,o&&(y.optional=l),e=this.finishNode(y,"CallExpression")}else if(this.type===v.backQuote){(l||a)&&this.raise(this.start,"Optional chaining cannot appear in the tag of tagged template expressions");var g=this.startNodeAt(t,n);g.tag=e,g.quasi=this.parseTemplate({isTagged:!0}),e=this.finishNode(g,"TaggedTemplateExpression")}return e},ie.parseExprAtom=function(e,t,n){this.type===v.slash&&this.readRegexp();var r,i=this.potentialArrowAt===this.start;switch(this.type){case v._super:return this.allowSuper||this.raise(this.start,"'super' keyword outside a method"),r=this.startNode(),this.next(),this.type!==v.parenL||this.allowDirectSuper||this.raise(r.start,"super() call outside constructor of a subclass"),this.type!==v.dot&&this.type!==v.bracketL&&this.type!==v.parenL&&this.unexpected(),this.finishNode(r,"Super");case v._this:return r=this.startNode(),this.next(),this.finishNode(r,"ThisExpression");case v.name:var a=this.start,s=this.startLoc,o=this.containsEsc,l=this.parseIdent(!1);if(this.options.ecmaVersion>=8&&!o&&"async"===l.name&&!this.canInsertSemicolon()&&this.eat(v._function))return this.overrideContext(ne.f_expr),this.parseFunction(this.startNodeAt(a,s),0,!1,!0,t);if(i&&!this.canInsertSemicolon()){if(this.eat(v.arrow))return this.parseArrowExpression(this.startNodeAt(a,s),[l],!1,t);if(this.options.ecmaVersion>=8&&"async"===l.name&&this.type===v.name&&!o&&(!this.potentialArrowInForAwait||"of"!==this.value||this.containsEsc))return l=this.parseIdent(!1),!this.canInsertSemicolon()&&this.eat(v.arrow)||this.unexpected(),this.parseArrowExpression(this.startNodeAt(a,s),[l],!0,t)}return l;case v.regexp:var c=this.value;return(r=this.parseLiteral(c.value)).regex={pattern:c.pattern,flags:c.flags},r;case v.num:case v.string:return this.parseLiteral(this.value);case v._null:case v._true:case v._false:return(r=this.startNode()).value=this.type===v._null?null:this.type===v._true,r.raw=this.type.keyword,this.next(),this.finishNode(r,"Literal");case v.parenL:var u=this.start,p=this.parseParenAndDistinguishExpression(i,t);return e&&(e.parenthesizedAssign<0&&!this.isSimpleAssignTarget(p)&&(e.parenthesizedAssign=u),e.parenthesizedBind<0&&(e.parenthesizedBind=u)),p;case v.bracketL:return r=this.startNode(),this.next(),r.elements=this.parseExprList(v.bracketR,!0,!0,e),this.finishNode(r,"ArrayExpression");case v.braceL:return this.overrideContext(ne.b_expr),this.parseObj(!1,e);case v._function:return r=this.startNode(),this.next(),this.parseFunction(r,0);case v._class:return this.parseClass(this.startNode(),!1);case v._new:return this.parseNew();case v.backQuote:return this.parseTemplate();case v._import:return this.options.ecmaVersion>=11?this.parseExprImport(n):this.unexpected();default:return this.parseExprAtomDefault()}},ie.parseExprAtomDefault=function(){this.unexpected()},ie.parseExprImport=function(e){var t=this.startNode();if(this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword import"),this.next(),this.type===v.parenL&&!e)return this.parseDynamicImport(t);if(this.type===v.dot){var n=this.startNodeAt(t.start,t.loc&&t.loc.start);return n.name="import",t.meta=this.finishNode(n,"Identifier"),this.parseImportMeta(t)}this.unexpected()},ie.parseDynamicImport=function(e){if(this.next(),e.source=this.parseMaybeAssign(),this.options.ecmaVersion>=16)this.eat(v.parenR)?e.options=null:(this.expect(v.comma),this.afterTrailingComma(v.parenR)?e.options=null:(e.options=this.parseMaybeAssign(),this.eat(v.parenR)||(this.expect(v.comma),this.afterTrailingComma(v.parenR)||this.unexpected())));else if(!this.eat(v.parenR)){var t=this.start;this.eat(v.comma)&&this.eat(v.parenR)?this.raiseRecoverable(t,"Trailing comma is not allowed in import()"):this.unexpected(t)}return this.finishNode(e,"ImportExpression")},ie.parseImportMeta=function(e){this.next();var t=this.containsEsc;return e.property=this.parseIdent(!0),"meta"!==e.property.name&&this.raiseRecoverable(e.property.start,"The only valid meta property for import is 'import.meta'"),t&&this.raiseRecoverable(e.start,"'import.meta' must not contain escaped characters"),"module"===this.options.sourceType||this.options.allowImportExportEverywhere||this.raiseRecoverable(e.start,"Cannot use 'import.meta' outside a module"),this.finishNode(e,"MetaProperty")},ie.parseLiteral=function(e){var t=this.startNode();return t.value=e,t.raw=this.input.slice(this.start,this.end),110===t.raw.charCodeAt(t.raw.length-1)&&(t.bigint=t.raw.slice(0,-1).replace(/_/g,"")),this.next(),this.finishNode(t,"Literal")},ie.parseParenExpression=function(){this.expect(v.parenL);var e=this.parseExpression();return this.expect(v.parenR),e},ie.shouldParseArrow=function(e){return!this.canInsertSemicolon()},ie.parseParenAndDistinguishExpression=function(e,t){var n,r=this.start,i=this.startLoc,a=this.options.ecmaVersion>=8;if(this.options.ecmaVersion>=6){this.next();var s,o=this.start,l=this.startLoc,c=[],u=!0,p=!1,h=new G,d=this.yieldPos,f=this.awaitPos;for(this.yieldPos=0,this.awaitPos=0;this.type!==v.parenR;){if(u?u=!1:this.expect(v.comma),a&&this.afterTrailingComma(v.parenR,!0)){p=!0;break}if(this.type===v.ellipsis){s=this.start,c.push(this.parseParenItem(this.parseRestBinding())),this.type===v.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element");break}c.push(this.parseMaybeAssign(!1,h,this.parseParenItem))}var m=this.lastTokEnd,y=this.lastTokEndLoc;if(this.expect(v.parenR),e&&this.shouldParseArrow(c)&&this.eat(v.arrow))return this.checkPatternErrors(h,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=d,this.awaitPos=f,this.parseParenArrowList(r,i,c,t);c.length&&!p||this.unexpected(this.lastTokStart),s&&this.unexpected(s),this.checkExpressionErrors(h,!0),this.yieldPos=d||this.yieldPos,this.awaitPos=f||this.awaitPos,c.length>1?((n=this.startNodeAt(o,l)).expressions=c,this.finishNodeAt(n,"SequenceExpression",m,y)):n=c[0]}else n=this.parseParenExpression();if(this.options.preserveParens){var g=this.startNodeAt(r,i);return g.expression=n,this.finishNode(g,"ParenthesizedExpression")}return n},ie.parseParenItem=function(e){return e},ie.parseParenArrowList=function(e,t,n,r){return this.parseArrowExpression(this.startNodeAt(e,t),n,!1,r)};var oe=[];ie.parseNew=function(){this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword new");var e=this.startNode();if(this.next(),this.options.ecmaVersion>=6&&this.type===v.dot){var t=this.startNodeAt(e.start,e.loc&&e.loc.start);t.name="new",e.meta=this.finishNode(t,"Identifier"),this.next();var n=this.containsEsc;return e.property=this.parseIdent(!0),"target"!==e.property.name&&this.raiseRecoverable(e.property.start,"The only valid meta property for new is 'new.target'"),n&&this.raiseRecoverable(e.start,"'new.target' must not contain escaped characters"),this.allowNewDotTarget||this.raiseRecoverable(e.start,"'new.target' can only be used in functions and class static block"),this.finishNode(e,"MetaProperty")}var r=this.start,i=this.startLoc;return e.callee=this.parseSubscripts(this.parseExprAtom(null,!1,!0),r,i,!0,!1),this.eat(v.parenL)?e.arguments=this.parseExprList(v.parenR,this.options.ecmaVersion>=8,!1):e.arguments=oe,this.finishNode(e,"NewExpression")},ie.parseTemplateElement=function(e){var t=e.isTagged,n=this.startNode();return this.type===v.invalidTemplate?(t||this.raiseRecoverable(this.start,"Bad escape sequence in untagged template literal"),n.value={raw:this.value.replace(/\r\n?/g,"\n"),cooked:null}):n.value={raw:this.input.slice(this.start,this.end).replace(/\r\n?/g,"\n"),cooked:this.value},this.next(),n.tail=this.type===v.backQuote,this.finishNode(n,"TemplateElement")},ie.parseTemplate=function(e){void 0===e&&(e={});var t=e.isTagged;void 0===t&&(t=!1);var n=this.startNode();this.next(),n.expressions=[];var r=this.parseTemplateElement({isTagged:t});for(n.quasis=[r];!r.tail;)this.type===v.eof&&this.raise(this.pos,"Unterminated template literal"),this.expect(v.dollarBraceL),n.expressions.push(this.parseExpression()),this.expect(v.braceR),n.quasis.push(r=this.parseTemplateElement({isTagged:t}));return this.next(),this.finishNode(n,"TemplateLiteral")},ie.isAsyncProp=function(e){return!e.computed&&"Identifier"===e.key.type&&"async"===e.key.name&&(this.type===v.name||this.type===v.num||this.type===v.string||this.type===v.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===v.star)&&!x.test(this.input.slice(this.lastTokEnd,this.start))},ie.parseObj=function(e,t){var n=this.startNode(),r=!0,i={};for(n.properties=[],this.next();!this.eat(v.braceR);){if(r)r=!1;else if(this.expect(v.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(v.braceR))break;var a=this.parseProperty(e,t);e||this.checkPropClash(a,i,t),n.properties.push(a)}return this.finishNode(n,e?"ObjectPattern":"ObjectExpression")},ie.parseProperty=function(e,t){var n,r,i,a,s=this.startNode();if(this.options.ecmaVersion>=9&&this.eat(v.ellipsis))return e?(s.argument=this.parseIdent(!1),this.type===v.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.finishNode(s,"RestElement")):(s.argument=this.parseMaybeAssign(!1,t),this.type===v.comma&&t&&t.trailingComma<0&&(t.trailingComma=this.start),this.finishNode(s,"SpreadElement"));this.options.ecmaVersion>=6&&(s.method=!1,s.shorthand=!1,(e||t)&&(i=this.start,a=this.startLoc),e||(n=this.eat(v.star)));var o=this.containsEsc;return this.parsePropertyName(s),!e&&!o&&this.options.ecmaVersion>=8&&!n&&this.isAsyncProp(s)?(r=!0,n=this.options.ecmaVersion>=9&&this.eat(v.star),this.parsePropertyName(s)):r=!1,this.parsePropertyValue(s,e,n,r,i,a,t,o),this.finishNode(s,"Property")},ie.parseGetterSetter=function(e){var t=e.key.name;this.parsePropertyName(e),e.value=this.parseMethod(!1),e.kind=t;var n="get"===e.kind?0:1;if(e.value.params.length!==n){var r=e.value.start;"get"===e.kind?this.raiseRecoverable(r,"getter should have no params"):this.raiseRecoverable(r,"setter should have exactly one param")}else"set"===e.kind&&"RestElement"===e.value.params[0].type&&this.raiseRecoverable(e.value.params[0].start,"Setter cannot use rest params")},ie.parsePropertyValue=function(e,t,n,r,i,a,s,o){(n||r)&&this.type===v.colon&&this.unexpected(),this.eat(v.colon)?(e.value=t?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,s),e.kind="init"):this.options.ecmaVersion>=6&&this.type===v.parenL?(t&&this.unexpected(),e.method=!0,e.value=this.parseMethod(n,r),e.kind="init"):t||o||!(this.options.ecmaVersion>=5)||e.computed||"Identifier"!==e.key.type||"get"!==e.key.name&&"set"!==e.key.name||this.type===v.comma||this.type===v.braceR||this.type===v.eq?this.options.ecmaVersion>=6&&!e.computed&&"Identifier"===e.key.type?((n||r)&&this.unexpected(),this.checkUnreserved(e.key),"await"!==e.key.name||this.awaitIdentPos||(this.awaitIdentPos=i),t?e.value=this.parseMaybeDefault(i,a,this.copyNode(e.key)):this.type===v.eq&&s?(s.shorthandAssign<0&&(s.shorthandAssign=this.start),e.value=this.parseMaybeDefault(i,a,this.copyNode(e.key))):e.value=this.copyNode(e.key),e.kind="init",e.shorthand=!0):this.unexpected():((n||r)&&this.unexpected(),this.parseGetterSetter(e))},ie.parsePropertyName=function(e){if(this.options.ecmaVersion>=6){if(this.eat(v.bracketL))return e.computed=!0,e.key=this.parseMaybeAssign(),this.expect(v.bracketR),e.key;e.computed=!1}return e.key=this.type===v.num||this.type===v.string?this.parseExprAtom():this.parseIdent("never"!==this.options.allowReserved)},ie.initFunction=function(e){e.id=null,this.options.ecmaVersion>=6&&(e.generator=e.expression=!1),this.options.ecmaVersion>=8&&(e.async=!1)},ie.parseMethod=function(e,t,n){var r=this.startNode(),i=this.yieldPos,a=this.awaitPos,s=this.awaitIdentPos;return this.initFunction(r),this.options.ecmaVersion>=6&&(r.generator=e),this.options.ecmaVersion>=8&&(r.async=!!t),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(64|R(t,r.generator)|(n?128:0)),this.expect(v.parenL),r.params=this.parseBindingList(v.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(r,!1,!0,!1),this.yieldPos=i,this.awaitPos=a,this.awaitIdentPos=s,this.finishNode(r,"FunctionExpression")},ie.parseArrowExpression=function(e,t,n,r){var i=this.yieldPos,a=this.awaitPos,s=this.awaitIdentPos;return this.enterScope(16|R(n,!1)),this.initFunction(e),this.options.ecmaVersion>=8&&(e.async=!!n),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,e.params=this.toAssignableList(t,!0),this.parseFunctionBody(e,!0,!1,r),this.yieldPos=i,this.awaitPos=a,this.awaitIdentPos=s,this.finishNode(e,"ArrowFunctionExpression")},ie.parseFunctionBody=function(e,t,n,r){var i=t&&this.type!==v.braceL,a=this.strict,s=!1;if(i)e.body=this.parseMaybeAssign(r),e.expression=!0,this.checkParams(e,!1);else{var o=this.options.ecmaVersion>=7&&!this.isSimpleParamList(e.params);a&&!o||(s=this.strictDirective(this.end))&&o&&this.raiseRecoverable(e.start,"Illegal 'use strict' directive in function with non-simple parameter list");var l=this.labels;this.labels=[],s&&(this.strict=!0),this.checkParams(e,!a&&!s&&!t&&!n&&this.isSimpleParamList(e.params)),this.strict&&e.id&&this.checkLValSimple(e.id,5),e.body=this.parseBlock(!1,void 0,s&&!a),e.expression=!1,this.adaptDirectivePrologue(e.body.body),this.labels=l}this.exitScope()},ie.isSimpleParamList=function(e){for(var t=0,n=e;t<n.length;t+=1)if("Identifier"!==n[t].type)return!1;return!0},ie.checkParams=function(e,t){for(var n=Object.create(null),r=0,i=e.params;r<i.length;r+=1){var a=i[r];this.checkLValInnerPattern(a,1,t?null:n)}},ie.parseExprList=function(e,t,n,r){for(var i=[],a=!0;!this.eat(e);){if(a)a=!1;else if(this.expect(v.comma),t&&this.afterTrailingComma(e))break;var s=void 0;n&&this.type===v.comma?s=null:this.type===v.ellipsis?(s=this.parseSpread(r),r&&this.type===v.comma&&r.trailingComma<0&&(r.trailingComma=this.start)):s=this.parseMaybeAssign(!1,r),i.push(s)}return i},ie.checkUnreserved=function(e){var t=e.start,n=e.end,r=e.name;this.inGenerator&&"yield"===r&&this.raiseRecoverable(t,"Cannot use 'yield' as identifier inside a generator"),this.inAsync&&"await"===r&&this.raiseRecoverable(t,"Cannot use 'await' as identifier inside an async function"),259&this.currentThisScope().flags||"arguments"!==r||this.raiseRecoverable(t,"Cannot use 'arguments' in class field initializer"),!this.inClassStaticBlock||"arguments"!==r&&"await"!==r||this.raise(t,"Cannot use "+r+" in class static initialization block"),this.keywords.test(r)&&this.raise(t,"Unexpected keyword '"+r+"'"),this.options.ecmaVersion<6&&-1!==this.input.slice(t,n).indexOf("\\")||(this.strict?this.reservedWordsStrict:this.reservedWords).test(r)&&(this.inAsync||"await"!==r||this.raiseRecoverable(t,"Cannot use keyword 'await' outside an async function"),this.raiseRecoverable(t,"The keyword '"+r+"' is reserved"))},ie.parseIdent=function(e){var t=this.parseIdentNode();return this.next(!!e),this.finishNode(t,"Identifier"),e||(this.checkUnreserved(t),"await"!==t.name||this.awaitIdentPos||(this.awaitIdentPos=t.start)),t},ie.parseIdentNode=function(){var e=this.startNode();return this.type===v.name?e.name=this.value:this.type.keyword?(e.name=this.type.keyword,"class"!==e.name&&"function"!==e.name||this.lastTokEnd===this.lastTokStart+1&&46===this.input.charCodeAt(this.lastTokStart)||this.context.pop(),this.type=v.name):this.unexpected(),e},ie.parsePrivateIdent=function(){var e=this.startNode();return this.type===v.privateId?e.name=this.value:this.unexpected(),this.next(),this.finishNode(e,"PrivateIdentifier"),this.options.checkPrivateFields&&(0===this.privateNameStack.length?this.raise(e.start,"Private field '#"+e.name+"' must be declared in an enclosing class"):this.privateNameStack[this.privateNameStack.length-1].used.push(e)),e},ie.parseYield=function(e){this.yieldPos||(this.yieldPos=this.start);var t=this.startNode();return this.next(),this.type===v.semi||this.canInsertSemicolon()||this.type!==v.star&&!this.type.startsExpr?(t.delegate=!1,t.argument=null):(t.delegate=this.eat(v.star),t.argument=this.parseMaybeAssign(e)),this.finishNode(t,"YieldExpression")},ie.parseAwait=function(e){this.awaitPos||(this.awaitPos=this.start);var t=this.startNode();return this.next(),t.argument=this.parseMaybeUnary(null,!0,!1,e),this.finishNode(t,"AwaitExpression")};var le=q.prototype;le.raise=function(e,t){var n=B(this.input,e);t+=" ("+n.line+":"+n.column+")",this.sourceFile&&(t+=" in "+this.sourceFile);var r=new SyntaxError(t);throw r.pos=e,r.loc=n,r.raisedAt=this.pos,r},le.raiseRecoverable=le.raise,le.curPosition=function(){if(this.options.locations)return new j(this.curLine,this.pos-this.lineStart)};var ce=q.prototype,ue=function(e){this.flags=e,this.var=[],this.lexical=[],this.functions=[]};ce.enterScope=function(e){this.scopeStack.push(new ue(e))},ce.exitScope=function(){this.scopeStack.pop()},ce.treatFunctionsAsVarInScope=function(e){return 2&e.flags||!this.inModule&&1&e.flags},ce.declareName=function(e,t,n){var r=!1;if(2===t){var i=this.currentScope();r=i.lexical.indexOf(e)>-1||i.functions.indexOf(e)>-1||i.var.indexOf(e)>-1,i.lexical.push(e),this.inModule&&1&i.flags&&delete this.undefinedExports[e]}else if(4===t)this.currentScope().lexical.push(e);else if(3===t){var a=this.currentScope();r=this.treatFunctionsAsVar?a.lexical.indexOf(e)>-1:a.lexical.indexOf(e)>-1||a.var.indexOf(e)>-1,a.functions.push(e)}else for(var s=this.scopeStack.length-1;s>=0;--s){var o=this.scopeStack[s];if(o.lexical.indexOf(e)>-1&&!(32&o.flags&&o.lexical[0]===e)||!this.treatFunctionsAsVarInScope(o)&&o.functions.indexOf(e)>-1){r=!0;break}if(o.var.push(e),this.inModule&&1&o.flags&&delete this.undefinedExports[e],259&o.flags)break}r&&this.raiseRecoverable(n,"Identifier '"+e+"' has already been declared")},ce.checkLocalExport=function(e){-1===this.scopeStack[0].lexical.indexOf(e.name)&&-1===this.scopeStack[0].var.indexOf(e.name)&&(this.undefinedExports[e.name]=e)},ce.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]},ce.currentVarScope=function(){for(var e=this.scopeStack.length-1;;e--){var t=this.scopeStack[e];if(771&t.flags)return t}},ce.currentThisScope=function(){for(var e=this.scopeStack.length-1;;e--){var t=this.scopeStack[e];if(771&t.flags&&!(16&t.flags))return t}};var pe=function(e,t,n){this.type="",this.start=t,this.end=0,e.options.locations&&(this.loc=new M(e,n)),e.options.directSourceFile&&(this.sourceFile=e.options.directSourceFile),e.options.ranges&&(this.range=[t,0])},he=q.prototype;function de(e,t,n,r){return e.type=t,e.end=n,this.options.locations&&(e.loc.end=r),this.options.ranges&&(e.range[1]=n),e}he.startNode=function(){return new pe(this,this.start,this.startLoc)},he.startNodeAt=function(e,t){return new pe(this,e,t)},he.finishNode=function(e,t){return de.call(this,e,t,this.lastTokEnd,this.lastTokEndLoc)},he.finishNodeAt=function(e,t,n,r){return de.call(this,e,t,n,r)},he.copyNode=function(e){var t=new pe(this,e.start,this.startLoc);for(var n in e)t[n]=e[n];return t};for(var fe,me,ye="ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS",ge=ye+" Extended_Pictographic",be=ge+" EBase EComp EMod EPres ExtPict",ve={9:ye,10:ge,11:ge,12:be,13:be,14:be},xe={9:"",10:"",11:"",12:"",13:"",14:"Basic_Emoji Emoji_Keycap_Sequence RGI_Emoji_Modifier_Sequence RGI_Emoji_Flag_Sequence RGI_Emoji_Tag_Sequence RGI_Emoji_ZWJ_Sequence RGI_Emoji"},Se="Cased_Letter LC Close_Punctuation Pe Connector_Punctuation Pc Control Cc cntrl Currency_Symbol Sc Dash_Punctuation Pd Decimal_Number Nd digit Enclosing_Mark Me Final_Punctuation Pf Format Cf Initial_Punctuation Pi Letter L Letter_Number Nl Line_Separator Zl Lowercase_Letter Ll Mark M Combining_Mark Math_Symbol Sm Modifier_Letter Lm Modifier_Symbol Sk Nonspacing_Mark Mn Number N Open_Punctuation Ps Other C Other_Letter Lo Other_Number No Other_Punctuation Po Other_Symbol So Paragraph_Separator Zp Private_Use Co Punctuation P punct Separator Z Space_Separator Zs Spacing_Mark Mc Surrogate Cs Symbol S Titlecase_Letter Lt Unassigned Cn Uppercase_Letter Lu",Ee="Adlam Adlm Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb",Te=Ee+" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd",_e=Te+" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho",ke=_e+" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi",Pe=ke+" Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith",we={9:Ee,10:Te,11:_e,12:ke,13:Pe,14:Pe+" Gara Garay Gukh Gurung_Khema Hrkt Katakana_Or_Hiragana Kawi Kirat_Rai Krai Nag_Mundari Nagm Ol_Onal Onao Sunu Sunuwar Todhri Todr Tulu_Tigalari Tutg Unknown Zzzz"},Ae={},Ce=0,Ie=[9,10,11,12,13,14];Ce<Ie.length;Ce+=1)me=void 0,(me=Ae[fe=Ie[Ce]]={binary:O(ve[fe]+" "+Se),binaryOfStrings:O(xe[fe]),nonBinary:{General_Category:O(Se),Script:O(we[fe])}}).nonBinary.Script_Extensions=me.nonBinary.Script,me.nonBinary.gc=me.nonBinary.General_Category,me.nonBinary.sc=me.nonBinary.Script,me.nonBinary.scx=me.nonBinary.Script_Extensions;var Ne=q.prototype,Oe=function(e,t){this.parent=e,this.base=t||this};Oe.prototype.separatedFrom=function(e){for(var t=this;t;t=t.parent)for(var n=e;n;n=n.parent)if(t.base===n.base&&t!==n)return!0;return!1},Oe.prototype.sibling=function(){return new Oe(this.parent,this.base)};var De=function(e){this.parser=e,this.validFlags="gim"+(e.options.ecmaVersion>=6?"uy":"")+(e.options.ecmaVersion>=9?"s":"")+(e.options.ecmaVersion>=13?"d":"")+(e.options.ecmaVersion>=15?"v":""),this.unicodeProperties=Ae[e.options.ecmaVersion>=14?14:e.options.ecmaVersion],this.source="",this.flags="",this.start=0,this.switchU=!1,this.switchV=!1,this.switchN=!1,this.pos=0,this.lastIntValue=0,this.lastStringValue="",this.lastAssertionIsQuantifiable=!1,this.numCapturingParens=0,this.maxBackReference=0,this.groupNames=Object.create(null),this.backReferenceNames=[],this.branchID=null};function Le(e){return 105===e||109===e||115===e}function je(e){return 36===e||e>=40&&e<=43||46===e||63===e||e>=91&&e<=94||e>=123&&e<=125}function Me(e){return e>=65&&e<=90||e>=97&&e<=122}function Be(e){return Me(e)||95===e}function Fe(e){return Be(e)||Ve(e)}function Ve(e){return e>=48&&e<=57}function Re(e){return e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102}function qe(e){return e>=65&&e<=70?e-65+10:e>=97&&e<=102?e-97+10:e-48}function Ue(e){return e>=48&&e<=55}De.prototype.reset=function(e,t,n){var r=-1!==n.indexOf("v"),i=-1!==n.indexOf("u");this.start=0|e,this.source=t+"",this.flags=n,r&&this.parser.options.ecmaVersion>=15?(this.switchU=!0,this.switchV=!0,this.switchN=!0):(this.switchU=i&&this.parser.options.ecmaVersion>=6,this.switchV=!1,this.switchN=i&&this.parser.options.ecmaVersion>=9)},De.prototype.raise=function(e){this.parser.raiseRecoverable(this.start,"Invalid regular expression: /"+this.source+"/: "+e)},De.prototype.at=function(e,t){void 0===t&&(t=!1);var n=this.source,r=n.length;if(e>=r)return-1;var i=n.charCodeAt(e);if(!t&&!this.switchU||i<=55295||i>=57344||e+1>=r)return i;var a=n.charCodeAt(e+1);return a>=56320&&a<=57343?(i<<10)+a-56613888:i},De.prototype.nextIndex=function(e,t){void 0===t&&(t=!1);var n=this.source,r=n.length;if(e>=r)return r;var i,a=n.charCodeAt(e);return!t&&!this.switchU||a<=55295||a>=57344||e+1>=r||(i=n.charCodeAt(e+1))<56320||i>57343?e+1:e+2},De.prototype.current=function(e){return void 0===e&&(e=!1),this.at(this.pos,e)},De.prototype.lookahead=function(e){return void 0===e&&(e=!1),this.at(this.nextIndex(this.pos,e),e)},De.prototype.advance=function(e){void 0===e&&(e=!1),this.pos=this.nextIndex(this.pos,e)},De.prototype.eat=function(e,t){return void 0===t&&(t=!1),this.current(t)===e&&(this.advance(t),!0)},De.prototype.eatChars=function(e,t){void 0===t&&(t=!1);for(var n=this.pos,r=0,i=e;r<i.length;r+=1){var a=i[r],s=this.at(n,t);if(-1===s||s!==a)return!1;n=this.nextIndex(n,t)}return this.pos=n,!0},Ne.validateRegExpFlags=function(e){for(var t=e.validFlags,n=e.flags,r=!1,i=!1,a=0;a<n.length;a++){var s=n.charAt(a);-1===t.indexOf(s)&&this.raise(e.start,"Invalid regular expression flag"),n.indexOf(s,a+1)>-1&&this.raise(e.start,"Duplicate regular expression flag"),"u"===s&&(r=!0),"v"===s&&(i=!0)}this.options.ecmaVersion>=15&&r&&i&&this.raise(e.start,"Invalid regular expression flag")},Ne.validateRegExpPattern=function(e){this.regexp_pattern(e),!e.switchN&&this.options.ecmaVersion>=9&&function(e){for(var t in e)return!0;return!1}(e.groupNames)&&(e.switchN=!0,this.regexp_pattern(e))},Ne.regexp_pattern=function(e){e.pos=0,e.lastIntValue=0,e.lastStringValue="",e.lastAssertionIsQuantifiable=!1,e.numCapturingParens=0,e.maxBackReference=0,e.groupNames=Object.create(null),e.backReferenceNames.length=0,e.branchID=null,this.regexp_disjunction(e),e.pos!==e.source.length&&(e.eat(41)&&e.raise("Unmatched ')'"),(e.eat(93)||e.eat(125))&&e.raise("Lone quantifier brackets")),e.maxBackReference>e.numCapturingParens&&e.raise("Invalid escape");for(var t=0,n=e.backReferenceNames;t<n.length;t+=1){var r=n[t];e.groupNames[r]||e.raise("Invalid named capture referenced")}},Ne.regexp_disjunction=function(e){var t=this.options.ecmaVersion>=16;for(t&&(e.branchID=new Oe(e.branchID,null)),this.regexp_alternative(e);e.eat(124);)t&&(e.branchID=e.branchID.sibling()),this.regexp_alternative(e);t&&(e.branchID=e.branchID.parent),this.regexp_eatQuantifier(e,!0)&&e.raise("Nothing to repeat"),e.eat(123)&&e.raise("Lone quantifier brackets")},Ne.regexp_alternative=function(e){for(;e.pos<e.source.length&&this.regexp_eatTerm(e););},Ne.regexp_eatTerm=function(e){return this.regexp_eatAssertion(e)?(e.lastAssertionIsQuantifiable&&this.regexp_eatQuantifier(e)&&e.switchU&&e.raise("Invalid quantifier"),!0):!!(e.switchU?this.regexp_eatAtom(e):this.regexp_eatExtendedAtom(e))&&(this.regexp_eatQuantifier(e),!0)},Ne.regexp_eatAssertion=function(e){var t=e.pos;if(e.lastAssertionIsQuantifiable=!1,e.eat(94)||e.eat(36))return!0;if(e.eat(92)){if(e.eat(66)||e.eat(98))return!0;e.pos=t}if(e.eat(40)&&e.eat(63)){var n=!1;if(this.options.ecmaVersion>=9&&(n=e.eat(60)),e.eat(61)||e.eat(33))return this.regexp_disjunction(e),e.eat(41)||e.raise("Unterminated group"),e.lastAssertionIsQuantifiable=!n,!0}return e.pos=t,!1},Ne.regexp_eatQuantifier=function(e,t){return void 0===t&&(t=!1),!!this.regexp_eatQuantifierPrefix(e,t)&&(e.eat(63),!0)},Ne.regexp_eatQuantifierPrefix=function(e,t){return e.eat(42)||e.eat(43)||e.eat(63)||this.regexp_eatBracedQuantifier(e,t)},Ne.regexp_eatBracedQuantifier=function(e,t){var n=e.pos;if(e.eat(123)){var r=0,i=-1;if(this.regexp_eatDecimalDigits(e)&&(r=e.lastIntValue,e.eat(44)&&this.regexp_eatDecimalDigits(e)&&(i=e.lastIntValue),e.eat(125)))return-1!==i&&i<r&&!t&&e.raise("numbers out of order in {} quantifier"),!0;e.switchU&&!t&&e.raise("Incomplete quantifier"),e.pos=n}return!1},Ne.regexp_eatAtom=function(e){return this.regexp_eatPatternCharacters(e)||e.eat(46)||this.regexp_eatReverseSolidusAtomEscape(e)||this.regexp_eatCharacterClass(e)||this.regexp_eatUncapturingGroup(e)||this.regexp_eatCapturingGroup(e)},Ne.regexp_eatReverseSolidusAtomEscape=function(e){var t=e.pos;if(e.eat(92)){if(this.regexp_eatAtomEscape(e))return!0;e.pos=t}return!1},Ne.regexp_eatUncapturingGroup=function(e){var t=e.pos;if(e.eat(40)){if(e.eat(63)){if(this.options.ecmaVersion>=16){var n=this.regexp_eatModifiers(e),r=e.eat(45);if(n||r){for(var i=0;i<n.length;i++){var a=n.charAt(i);n.indexOf(a,i+1)>-1&&e.raise("Duplicate regular expression modifiers")}if(r){var s=this.regexp_eatModifiers(e);n||s||58!==e.current()||e.raise("Invalid regular expression modifiers");for(var o=0;o<s.length;o++){var l=s.charAt(o);(s.indexOf(l,o+1)>-1||n.indexOf(l)>-1)&&e.raise("Duplicate regular expression modifiers")}}}}if(e.eat(58)){if(this.regexp_disjunction(e),e.eat(41))return!0;e.raise("Unterminated group")}}e.pos=t}return!1},Ne.regexp_eatCapturingGroup=function(e){if(e.eat(40)){if(this.options.ecmaVersion>=9?this.regexp_groupSpecifier(e):63===e.current()&&e.raise("Invalid group"),this.regexp_disjunction(e),e.eat(41))return e.numCapturingParens+=1,!0;e.raise("Unterminated group")}return!1},Ne.regexp_eatModifiers=function(e){for(var t="",n=0;-1!==(n=e.current())&&Le(n);)t+=D(n),e.advance();return t},Ne.regexp_eatExtendedAtom=function(e){return e.eat(46)||this.regexp_eatReverseSolidusAtomEscape(e)||this.regexp_eatCharacterClass(e)||this.regexp_eatUncapturingGroup(e)||this.regexp_eatCapturingGroup(e)||this.regexp_eatInvalidBracedQuantifier(e)||this.regexp_eatExtendedPatternCharacter(e)},Ne.regexp_eatInvalidBracedQuantifier=function(e){return this.regexp_eatBracedQuantifier(e,!0)&&e.raise("Nothing to repeat"),!1},Ne.regexp_eatSyntaxCharacter=function(e){var t=e.current();return!!je(t)&&(e.lastIntValue=t,e.advance(),!0)},Ne.regexp_eatPatternCharacters=function(e){for(var t=e.pos,n=0;-1!==(n=e.current())&&!je(n);)e.advance();return e.pos!==t},Ne.regexp_eatExtendedPatternCharacter=function(e){var t=e.current();return!(-1===t||36===t||t>=40&&t<=43||46===t||63===t||91===t||94===t||124===t||(e.advance(),0))},Ne.regexp_groupSpecifier=function(e){if(e.eat(63)){this.regexp_eatGroupName(e)||e.raise("Invalid group");var t=this.options.ecmaVersion>=16,n=e.groupNames[e.lastStringValue];if(n)if(t)for(var r=0,i=n;r<i.length;r+=1)i[r].separatedFrom(e.branchID)||e.raise("Duplicate capture group name");else e.raise("Duplicate capture group name");t?(n||(e.groupNames[e.lastStringValue]=[])).push(e.branchID):e.groupNames[e.lastStringValue]=!0}},Ne.regexp_eatGroupName=function(e){if(e.lastStringValue="",e.eat(60)){if(this.regexp_eatRegExpIdentifierName(e)&&e.eat(62))return!0;e.raise("Invalid capture group name")}return!1},Ne.regexp_eatRegExpIdentifierName=function(e){if(e.lastStringValue="",this.regexp_eatRegExpIdentifierStart(e)){for(e.lastStringValue+=D(e.lastIntValue);this.regexp_eatRegExpIdentifierPart(e);)e.lastStringValue+=D(e.lastIntValue);return!0}return!1},Ne.regexp_eatRegExpIdentifierStart=function(e){var t=e.pos,n=this.options.ecmaVersion>=11,r=e.current(n);return e.advance(n),92===r&&this.regexp_eatRegExpUnicodeEscapeSequence(e,n)&&(r=e.lastIntValue),function(e){return p(e,!0)||36===e||95===e}(r)?(e.lastIntValue=r,!0):(e.pos=t,!1)},Ne.regexp_eatRegExpIdentifierPart=function(e){var t=e.pos,n=this.options.ecmaVersion>=11,r=e.current(n);return e.advance(n),92===r&&this.regexp_eatRegExpUnicodeEscapeSequence(e,n)&&(r=e.lastIntValue),function(e){return h(e,!0)||36===e||95===e||8204===e||8205===e}(r)?(e.lastIntValue=r,!0):(e.pos=t,!1)},Ne.regexp_eatAtomEscape=function(e){return!!(this.regexp_eatBackReference(e)||this.regexp_eatCharacterClassEscape(e)||this.regexp_eatCharacterEscape(e)||e.switchN&&this.regexp_eatKGroupName(e))||(e.switchU&&(99===e.current()&&e.raise("Invalid unicode escape"),e.raise("Invalid escape")),!1)},Ne.regexp_eatBackReference=function(e){var t=e.pos;if(this.regexp_eatDecimalEscape(e)){var n=e.lastIntValue;if(e.switchU)return n>e.maxBackReference&&(e.maxBackReference=n),!0;if(n<=e.numCapturingParens)return!0;e.pos=t}return!1},Ne.regexp_eatKGroupName=function(e){if(e.eat(107)){if(this.regexp_eatGroupName(e))return e.backReferenceNames.push(e.lastStringValue),!0;e.raise("Invalid named reference")}return!1},Ne.regexp_eatCharacterEscape=function(e){return this.regexp_eatControlEscape(e)||this.regexp_eatCControlLetter(e)||this.regexp_eatZero(e)||this.regexp_eatHexEscapeSequence(e)||this.regexp_eatRegExpUnicodeEscapeSequence(e,!1)||!e.switchU&&this.regexp_eatLegacyOctalEscapeSequence(e)||this.regexp_eatIdentityEscape(e)},Ne.regexp_eatCControlLetter=function(e){var t=e.pos;if(e.eat(99)){if(this.regexp_eatControlLetter(e))return!0;e.pos=t}return!1},Ne.regexp_eatZero=function(e){return 48===e.current()&&!Ve(e.lookahead())&&(e.lastIntValue=0,e.advance(),!0)},Ne.regexp_eatControlEscape=function(e){var t=e.current();return 116===t?(e.lastIntValue=9,e.advance(),!0):110===t?(e.lastIntValue=10,e.advance(),!0):118===t?(e.lastIntValue=11,e.advance(),!0):102===t?(e.lastIntValue=12,e.advance(),!0):114===t&&(e.lastIntValue=13,e.advance(),!0)},Ne.regexp_eatControlLetter=function(e){var t=e.current();return!!Me(t)&&(e.lastIntValue=t%32,e.advance(),!0)},Ne.regexp_eatRegExpUnicodeEscapeSequence=function(e,t){void 0===t&&(t=!1);var n,r=e.pos,i=t||e.switchU;if(e.eat(117)){if(this.regexp_eatFixedHexDigits(e,4)){var a=e.lastIntValue;if(i&&a>=55296&&a<=56319){var s=e.pos;if(e.eat(92)&&e.eat(117)&&this.regexp_eatFixedHexDigits(e,4)){var o=e.lastIntValue;if(o>=56320&&o<=57343)return e.lastIntValue=1024*(a-55296)+(o-56320)+65536,!0}e.pos=s,e.lastIntValue=a}return!0}if(i&&e.eat(123)&&this.regexp_eatHexDigits(e)&&e.eat(125)&&(n=e.lastIntValue)>=0&&n<=1114111)return!0;i&&e.raise("Invalid unicode escape"),e.pos=r}return!1},Ne.regexp_eatIdentityEscape=function(e){if(e.switchU)return!!this.regexp_eatSyntaxCharacter(e)||!!e.eat(47)&&(e.lastIntValue=47,!0);var t=e.current();return!(99===t||e.switchN&&107===t||(e.lastIntValue=t,e.advance(),0))},Ne.regexp_eatDecimalEscape=function(e){e.lastIntValue=0;var t=e.current();if(t>=49&&t<=57){do{e.lastIntValue=10*e.lastIntValue+(t-48),e.advance()}while((t=e.current())>=48&&t<=57);return!0}return!1},Ne.regexp_eatCharacterClassEscape=function(e){var t=e.current();if(function(e){return 100===e||68===e||115===e||83===e||119===e||87===e}(t))return e.lastIntValue=-1,e.advance(),1;var n=!1;if(e.switchU&&this.options.ecmaVersion>=9&&((n=80===t)||112===t)){var r;if(e.lastIntValue=-1,e.advance(),e.eat(123)&&(r=this.regexp_eatUnicodePropertyValueExpression(e))&&e.eat(125))return n&&2===r&&e.raise("Invalid property name"),r;e.raise("Invalid property name")}return 0},Ne.regexp_eatUnicodePropertyValueExpression=function(e){var t=e.pos;if(this.regexp_eatUnicodePropertyName(e)&&e.eat(61)){var n=e.lastStringValue;if(this.regexp_eatUnicodePropertyValue(e)){var r=e.lastStringValue;return this.regexp_validateUnicodePropertyNameAndValue(e,n,r),1}}if(e.pos=t,this.regexp_eatLoneUnicodePropertyNameOrValue(e)){var i=e.lastStringValue;return this.regexp_validateUnicodePropertyNameOrValue(e,i)}return 0},Ne.regexp_validateUnicodePropertyNameAndValue=function(e,t,n){C(e.unicodeProperties.nonBinary,t)||e.raise("Invalid property name"),e.unicodeProperties.nonBinary[t].test(n)||e.raise("Invalid property value")},Ne.regexp_validateUnicodePropertyNameOrValue=function(e,t){return e.unicodeProperties.binary.test(t)?1:e.switchV&&e.unicodeProperties.binaryOfStrings.test(t)?2:void e.raise("Invalid property name")},Ne.regexp_eatUnicodePropertyName=function(e){var t=0;for(e.lastStringValue="";Be(t=e.current());)e.lastStringValue+=D(t),e.advance();return""!==e.lastStringValue},Ne.regexp_eatUnicodePropertyValue=function(e){var t=0;for(e.lastStringValue="";Fe(t=e.current());)e.lastStringValue+=D(t),e.advance();return""!==e.lastStringValue},Ne.regexp_eatLoneUnicodePropertyNameOrValue=function(e){return this.regexp_eatUnicodePropertyValue(e)},Ne.regexp_eatCharacterClass=function(e){if(e.eat(91)){var t=e.eat(94),n=this.regexp_classContents(e);return e.eat(93)||e.raise("Unterminated character class"),t&&2===n&&e.raise("Negated character class may contain strings"),!0}return!1},Ne.regexp_classContents=function(e){return 93===e.current()?1:e.switchV?this.regexp_classSetExpression(e):(this.regexp_nonEmptyClassRanges(e),1)},Ne.regexp_nonEmptyClassRanges=function(e){for(;this.regexp_eatClassAtom(e);){var t=e.lastIntValue;if(e.eat(45)&&this.regexp_eatClassAtom(e)){var n=e.lastIntValue;!e.switchU||-1!==t&&-1!==n||e.raise("Invalid character class"),-1!==t&&-1!==n&&t>n&&e.raise("Range out of order in character class")}}},Ne.regexp_eatClassAtom=function(e){var t=e.pos;if(e.eat(92)){if(this.regexp_eatClassEscape(e))return!0;if(e.switchU){var n=e.current();(99===n||Ue(n))&&e.raise("Invalid class escape"),e.raise("Invalid escape")}e.pos=t}var r=e.current();return 93!==r&&(e.lastIntValue=r,e.advance(),!0)},Ne.regexp_eatClassEscape=function(e){var t=e.pos;if(e.eat(98))return e.lastIntValue=8,!0;if(e.switchU&&e.eat(45))return e.lastIntValue=45,!0;if(!e.switchU&&e.eat(99)){if(this.regexp_eatClassControlLetter(e))return!0;e.pos=t}return this.regexp_eatCharacterClassEscape(e)||this.regexp_eatCharacterEscape(e)},Ne.regexp_classSetExpression=function(e){var t,n=1;if(this.regexp_eatClassSetRange(e));else if(t=this.regexp_eatClassSetOperand(e)){2===t&&(n=2);for(var r=e.pos;e.eatChars([38,38]);)38!==e.current()&&(t=this.regexp_eatClassSetOperand(e))?2!==t&&(n=1):e.raise("Invalid character in character class");if(r!==e.pos)return n;for(;e.eatChars([45,45]);)this.regexp_eatClassSetOperand(e)||e.raise("Invalid character in character class");if(r!==e.pos)return n}else e.raise("Invalid character in character class");for(;;)if(!this.regexp_eatClassSetRange(e)){if(!(t=this.regexp_eatClassSetOperand(e)))return n;2===t&&(n=2)}},Ne.regexp_eatClassSetRange=function(e){var t=e.pos;if(this.regexp_eatClassSetCharacter(e)){var n=e.lastIntValue;if(e.eat(45)&&this.regexp_eatClassSetCharacter(e)){var r=e.lastIntValue;return-1!==n&&-1!==r&&n>r&&e.raise("Range out of order in character class"),!0}e.pos=t}return!1},Ne.regexp_eatClassSetOperand=function(e){return this.regexp_eatClassSetCharacter(e)?1:this.regexp_eatClassStringDisjunction(e)||this.regexp_eatNestedClass(e)},Ne.regexp_eatNestedClass=function(e){var t=e.pos;if(e.eat(91)){var n=e.eat(94),r=this.regexp_classContents(e);if(e.eat(93))return n&&2===r&&e.raise("Negated character class may contain strings"),r;e.pos=t}if(e.eat(92)){var i=this.regexp_eatCharacterClassEscape(e);if(i)return i;e.pos=t}return null},Ne.regexp_eatClassStringDisjunction=function(e){var t=e.pos;if(e.eatChars([92,113])){if(e.eat(123)){var n=this.regexp_classStringDisjunctionContents(e);if(e.eat(125))return n}else e.raise("Invalid escape");e.pos=t}return null},Ne.regexp_classStringDisjunctionContents=function(e){for(var t=this.regexp_classString(e);e.eat(124);)2===this.regexp_classString(e)&&(t=2);return t},Ne.regexp_classString=function(e){for(var t=0;this.regexp_eatClassSetCharacter(e);)t++;return 1===t?1:2},Ne.regexp_eatClassSetCharacter=function(e){var t=e.pos;if(e.eat(92))return!(!this.regexp_eatCharacterEscape(e)&&!this.regexp_eatClassSetReservedPunctuator(e)&&(e.eat(98)?(e.lastIntValue=8,0):(e.pos=t,1)));var n=e.current();return!(n<0||n===e.lookahead()&&function(e){return 33===e||e>=35&&e<=38||e>=42&&e<=44||46===e||e>=58&&e<=64||94===e||96===e||126===e}(n)||function(e){return 40===e||41===e||45===e||47===e||e>=91&&e<=93||e>=123&&e<=125}(n)||(e.advance(),e.lastIntValue=n,0))},Ne.regexp_eatClassSetReservedPunctuator=function(e){var t=e.current();return!!function(e){return 33===e||35===e||37===e||38===e||44===e||45===e||e>=58&&e<=62||64===e||96===e||126===e}(t)&&(e.lastIntValue=t,e.advance(),!0)},Ne.regexp_eatClassControlLetter=function(e){var t=e.current();return!(!Ve(t)&&95!==t||(e.lastIntValue=t%32,e.advance(),0))},Ne.regexp_eatHexEscapeSequence=function(e){var t=e.pos;if(e.eat(120)){if(this.regexp_eatFixedHexDigits(e,2))return!0;e.switchU&&e.raise("Invalid escape"),e.pos=t}return!1},Ne.regexp_eatDecimalDigits=function(e){var t=e.pos,n=0;for(e.lastIntValue=0;Ve(n=e.current());)e.lastIntValue=10*e.lastIntValue+(n-48),e.advance();return e.pos!==t},Ne.regexp_eatHexDigits=function(e){var t=e.pos,n=0;for(e.lastIntValue=0;Re(n=e.current());)e.lastIntValue=16*e.lastIntValue+qe(n),e.advance();return e.pos!==t},Ne.regexp_eatLegacyOctalEscapeSequence=function(e){if(this.regexp_eatOctalDigit(e)){var t=e.lastIntValue;if(this.regexp_eatOctalDigit(e)){var n=e.lastIntValue;t<=3&&this.regexp_eatOctalDigit(e)?e.lastIntValue=64*t+8*n+e.lastIntValue:e.lastIntValue=8*t+n}else e.lastIntValue=t;return!0}return!1},Ne.regexp_eatOctalDigit=function(e){var t=e.current();return Ue(t)?(e.lastIntValue=t-48,e.advance(),!0):(e.lastIntValue=0,!1)},Ne.regexp_eatFixedHexDigits=function(e,t){var n=e.pos;e.lastIntValue=0;for(var r=0;r<t;++r){var i=e.current();if(!Re(i))return e.pos=n,!1;e.lastIntValue=16*e.lastIntValue+qe(i),e.advance()}return!0};var ze=function(e){this.type=e.type,this.value=e.value,this.start=e.start,this.end=e.end,e.options.locations&&(this.loc=new M(e,e.startLoc,e.endLoc)),e.options.ranges&&(this.range=[e.start,e.end])},We=q.prototype;function Ge(e){return"function"!=typeof BigInt?null:BigInt(e.replace(/_/g,""))}We.next=function(e){!e&&this.type.keyword&&this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword "+this.type.keyword),this.options.onToken&&this.options.onToken(new ze(this)),this.lastTokEnd=this.end,this.lastTokStart=this.start,this.lastTokEndLoc=this.endLoc,this.lastTokStartLoc=this.startLoc,this.nextToken()},We.getToken=function(){return this.next(),new ze(this)},"undefined"!=typeof Symbol&&(We[Symbol.iterator]=function(){var e=this;return{next:function(){var t=e.getToken();return{done:t.type===v.eof,value:t}}}}),We.nextToken=function(){var e=this.curContext();return e&&e.preserveSpace||this.skipSpace(),this.start=this.pos,this.options.locations&&(this.startLoc=this.curPosition()),this.pos>=this.input.length?this.finishToken(v.eof):e.override?e.override(this):void this.readToken(this.fullCharCodeAtPos())},We.readToken=function(e){return p(e,this.options.ecmaVersion>=6)||92===e?this.readWord():this.getTokenFromCode(e)},We.fullCharCodeAtPos=function(){var e=this.input.charCodeAt(this.pos);if(e<=55295||e>=56320)return e;var t=this.input.charCodeAt(this.pos+1);return t<=56319||t>=57344?e:(e<<10)+t-56613888},We.skipBlockComment=function(){var e=this.options.onComment&&this.curPosition(),t=this.pos,n=this.input.indexOf("*/",this.pos+=2);if(-1===n&&this.raise(this.pos-2,"Unterminated comment"),this.pos=n+2,this.options.locations)for(var r=void 0,i=t;(r=T(this.input,i,this.pos))>-1;)++this.curLine,i=this.lineStart=r;this.options.onComment&&this.options.onComment(!0,this.input.slice(t+2,n),t,this.pos,e,this.curPosition())},We.skipLineComment=function(e){for(var t=this.pos,n=this.options.onComment&&this.curPosition(),r=this.input.charCodeAt(this.pos+=e);this.pos<this.input.length&&!E(r);)r=this.input.charCodeAt(++this.pos);this.options.onComment&&this.options.onComment(!1,this.input.slice(t+e,this.pos),t,this.pos,n,this.curPosition())},We.skipSpace=function(){e:for(;this.pos<this.input.length;){var e=this.input.charCodeAt(this.pos);switch(e){case 32:case 160:++this.pos;break;case 13:10===this.input.charCodeAt(this.pos+1)&&++this.pos;case 10:case 8232:case 8233:++this.pos,this.options.locations&&(++this.curLine,this.lineStart=this.pos);break;case 47:switch(this.input.charCodeAt(this.pos+1)){case 42:this.skipBlockComment();break;case 47:this.skipLineComment(2);break;default:break e}break;default:if(!(e>8&&e<14||e>=5760&&_.test(String.fromCharCode(e))))break e;++this.pos}}},We.finishToken=function(e,t){this.end=this.pos,this.options.locations&&(this.endLoc=this.curPosition());var n=this.type;this.type=e,this.value=t,this.updateContext(n)},We.readToken_dot=function(){var e=this.input.charCodeAt(this.pos+1);if(e>=48&&e<=57)return this.readNumber(!0);var t=this.input.charCodeAt(this.pos+2);return this.options.ecmaVersion>=6&&46===e&&46===t?(this.pos+=3,this.finishToken(v.ellipsis)):(++this.pos,this.finishToken(v.dot))},We.readToken_slash=function(){var e=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp()):61===e?this.finishOp(v.assign,2):this.finishOp(v.slash,1)},We.readToken_mult_modulo_exp=function(e){var t=this.input.charCodeAt(this.pos+1),n=1,r=42===e?v.star:v.modulo;return this.options.ecmaVersion>=7&&42===e&&42===t&&(++n,r=v.starstar,t=this.input.charCodeAt(this.pos+2)),61===t?this.finishOp(v.assign,n+1):this.finishOp(r,n)},We.readToken_pipe_amp=function(e){var t=this.input.charCodeAt(this.pos+1);return t===e?this.options.ecmaVersion>=12&&61===this.input.charCodeAt(this.pos+2)?this.finishOp(v.assign,3):this.finishOp(124===e?v.logicalOR:v.logicalAND,2):61===t?this.finishOp(v.assign,2):this.finishOp(124===e?v.bitwiseOR:v.bitwiseAND,1)},We.readToken_caret=function(){return 61===this.input.charCodeAt(this.pos+1)?this.finishOp(v.assign,2):this.finishOp(v.bitwiseXOR,1)},We.readToken_plus_min=function(e){var t=this.input.charCodeAt(this.pos+1);return t===e?45!==t||this.inModule||62!==this.input.charCodeAt(this.pos+2)||0!==this.lastTokEnd&&!x.test(this.input.slice(this.lastTokEnd,this.pos))?this.finishOp(v.incDec,2):(this.skipLineComment(3),this.skipSpace(),this.nextToken()):61===t?this.finishOp(v.assign,2):this.finishOp(v.plusMin,1)},We.readToken_lt_gt=function(e){var t=this.input.charCodeAt(this.pos+1),n=1;return t===e?(n=62===e&&62===this.input.charCodeAt(this.pos+2)?3:2,61===this.input.charCodeAt(this.pos+n)?this.finishOp(v.assign,n+1):this.finishOp(v.bitShift,n)):33!==t||60!==e||this.inModule||45!==this.input.charCodeAt(this.pos+2)||45!==this.input.charCodeAt(this.pos+3)?(61===t&&(n=2),this.finishOp(v.relational,n)):(this.skipLineComment(4),this.skipSpace(),this.nextToken())},We.readToken_eq_excl=function(e){var t=this.input.charCodeAt(this.pos+1);return 61===t?this.finishOp(v.equality,61===this.input.charCodeAt(this.pos+2)?3:2):61===e&&62===t&&this.options.ecmaVersion>=6?(this.pos+=2,this.finishToken(v.arrow)):this.finishOp(61===e?v.eq:v.prefix,1)},We.readToken_question=function(){var e=this.options.ecmaVersion;if(e>=11){var t=this.input.charCodeAt(this.pos+1);if(46===t){var n=this.input.charCodeAt(this.pos+2);if(n<48||n>57)return this.finishOp(v.questionDot,2)}if(63===t)return e>=12&&61===this.input.charCodeAt(this.pos+2)?this.finishOp(v.assign,3):this.finishOp(v.coalesce,2)}return this.finishOp(v.question,1)},We.readToken_numberSign=function(){var e=35;if(this.options.ecmaVersion>=13&&(++this.pos,p(e=this.fullCharCodeAtPos(),!0)||92===e))return this.finishToken(v.privateId,this.readWord1());this.raise(this.pos,"Unexpected character '"+D(e)+"'")},We.getTokenFromCode=function(e){switch(e){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(v.parenL);case 41:return++this.pos,this.finishToken(v.parenR);case 59:return++this.pos,this.finishToken(v.semi);case 44:return++this.pos,this.finishToken(v.comma);case 91:return++this.pos,this.finishToken(v.bracketL);case 93:return++this.pos,this.finishToken(v.bracketR);case 123:return++this.pos,this.finishToken(v.braceL);case 125:return++this.pos,this.finishToken(v.braceR);case 58:return++this.pos,this.finishToken(v.colon);case 96:if(this.options.ecmaVersion<6)break;return++this.pos,this.finishToken(v.backQuote);case 48:var t=this.input.charCodeAt(this.pos+1);if(120===t||88===t)return this.readRadixNumber(16);if(this.options.ecmaVersion>=6){if(111===t||79===t)return this.readRadixNumber(8);if(98===t||66===t)return this.readRadixNumber(2)}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return this.readNumber(!1);case 34:case 39:return this.readString(e);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(e);case 124:case 38:return this.readToken_pipe_amp(e);case 94:return this.readToken_caret();case 43:case 45:return this.readToken_plus_min(e);case 60:case 62:return this.readToken_lt_gt(e);case 61:case 33:return this.readToken_eq_excl(e);case 63:return this.readToken_question();case 126:return this.finishOp(v.prefix,1);case 35:return this.readToken_numberSign()}this.raise(this.pos,"Unexpected character '"+D(e)+"'")},We.finishOp=function(e,t){var n=this.input.slice(this.pos,this.pos+t);return this.pos+=t,this.finishToken(e,n)},We.readRegexp=function(){for(var e,t,n=this.pos;;){this.pos>=this.input.length&&this.raise(n,"Unterminated regular expression");var r=this.input.charAt(this.pos);if(x.test(r)&&this.raise(n,"Unterminated regular expression"),e)e=!1;else{if("["===r)t=!0;else if("]"===r&&t)t=!1;else if("/"===r&&!t)break;e="\\"===r}++this.pos}var i=this.input.slice(n,this.pos);++this.pos;var a=this.pos,s=this.readWord1();this.containsEsc&&this.unexpected(a);var o=this.regexpState||(this.regexpState=new De(this));o.reset(n,i,s),this.validateRegExpFlags(o),this.validateRegExpPattern(o);var l=null;try{l=RegExp(i,s)}catch(e){}return this.finishToken(v.regexp,{pattern:i,flags:s,value:l})},We.readInt=function(e,t,n){for(var r=this.options.ecmaVersion>=12&&void 0===t,i=n&&48===this.input.charCodeAt(this.pos),a=this.pos,s=0,o=0,l=0,c=null==t?1/0:t;l<c;++l,++this.pos){var u=this.input.charCodeAt(this.pos),p=void 0;if(r&&95===u)i&&this.raiseRecoverable(this.pos,"Numeric separator is not allowed in legacy octal numeric literals"),95===o&&this.raiseRecoverable(this.pos,"Numeric separator must be exactly one underscore"),0===l&&this.raiseRecoverable(this.pos,"Numeric separator is not allowed at the first of digits"),o=u;else{if((p=u>=97?u-97+10:u>=65?u-65+10:u>=48&&u<=57?u-48:1/0)>=e)break;o=u,s=s*e+p}}return r&&95===o&&this.raiseRecoverable(this.pos-1,"Numeric separator is not allowed at the last of digits"),this.pos===a||null!=t&&this.pos-a!==t?null:s},We.readRadixNumber=function(e){var t=this.pos;this.pos+=2;var n=this.readInt(e);return null==n&&this.raise(this.start+2,"Expected number in radix "+e),this.options.ecmaVersion>=11&&110===this.input.charCodeAt(this.pos)?(n=Ge(this.input.slice(t,this.pos)),++this.pos):p(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(v.num,n)},We.readNumber=function(e){var t=this.pos;e||null!==this.readInt(10,void 0,!0)||this.raise(t,"Invalid number");var n=this.pos-t>=2&&48===this.input.charCodeAt(t);n&&this.strict&&this.raise(t,"Invalid number");var r=this.input.charCodeAt(this.pos);if(!n&&!e&&this.options.ecmaVersion>=11&&110===r){var i=Ge(this.input.slice(t,this.pos));return++this.pos,p(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(v.num,i)}n&&/[89]/.test(this.input.slice(t,this.pos))&&(n=!1),46!==r||n||(++this.pos,this.readInt(10),r=this.input.charCodeAt(this.pos)),69!==r&&101!==r||n||(43!==(r=this.input.charCodeAt(++this.pos))&&45!==r||++this.pos,null===this.readInt(10)&&this.raise(t,"Invalid number")),p(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number");var a,s=(a=this.input.slice(t,this.pos),n?parseInt(a,8):parseFloat(a.replace(/_/g,"")));return this.finishToken(v.num,s)},We.readCodePoint=function(){var e;if(123===this.input.charCodeAt(this.pos)){this.options.ecmaVersion<6&&this.unexpected();var t=++this.pos;e=this.readHexChar(this.input.indexOf("}",this.pos)-this.pos),++this.pos,e>1114111&&this.invalidStringToken(t,"Code point out of bounds")}else e=this.readHexChar(4);return e},We.readString=function(e){for(var t="",n=++this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated string constant");var r=this.input.charCodeAt(this.pos);if(r===e)break;92===r?(t+=this.input.slice(n,this.pos),t+=this.readEscapedChar(!1),n=this.pos):8232===r||8233===r?(this.options.ecmaVersion<10&&this.raise(this.start,"Unterminated string constant"),++this.pos,this.options.locations&&(this.curLine++,this.lineStart=this.pos)):(E(r)&&this.raise(this.start,"Unterminated string constant"),++this.pos)}return t+=this.input.slice(n,this.pos++),this.finishToken(v.string,t)};var Je={};We.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(e){if(e!==Je)throw e;this.readInvalidTemplateToken()}this.inTemplateElement=!1},We.invalidStringToken=function(e,t){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw Je;this.raise(e,t)},We.readTmplToken=function(){for(var e="",t=this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated template");var n=this.input.charCodeAt(this.pos);if(96===n||36===n&&123===this.input.charCodeAt(this.pos+1))return this.pos!==this.start||this.type!==v.template&&this.type!==v.invalidTemplate?(e+=this.input.slice(t,this.pos),this.finishToken(v.template,e)):36===n?(this.pos+=2,this.finishToken(v.dollarBraceL)):(++this.pos,this.finishToken(v.backQuote));if(92===n)e+=this.input.slice(t,this.pos),e+=this.readEscapedChar(!0),t=this.pos;else if(E(n)){switch(e+=this.input.slice(t,this.pos),++this.pos,n){case 13:10===this.input.charCodeAt(this.pos)&&++this.pos;case 10:e+="\n";break;default:e+=String.fromCharCode(n)}this.options.locations&&(++this.curLine,this.lineStart=this.pos),t=this.pos}else++this.pos}},We.readInvalidTemplateToken=function(){for(;this.pos<this.input.length;this.pos++)switch(this.input[this.pos]){case"\\":++this.pos;break;case"$":if("{"!==this.input[this.pos+1])break;case"`":return this.finishToken(v.invalidTemplate,this.input.slice(this.start,this.pos));case"\r":"\n"===this.input[this.pos+1]&&++this.pos;case"\n":case"\u2028":case"\u2029":++this.curLine,this.lineStart=this.pos+1}this.raise(this.start,"Unterminated template")},We.readEscapedChar=function(e){var t=this.input.charCodeAt(++this.pos);switch(++this.pos,t){case 110:return"\n";case 114:return"\r";case 120:return String.fromCharCode(this.readHexChar(2));case 117:return D(this.readCodePoint());case 116:return"\t";case 98:return"\b";case 118:return"\v";case 102:return"\f";case 13:10===this.input.charCodeAt(this.pos)&&++this.pos;case 10:return this.options.locations&&(this.lineStart=this.pos,++this.curLine),"";case 56:case 57:if(this.strict&&this.invalidStringToken(this.pos-1,"Invalid escape sequence"),e){var n=this.pos-1;this.invalidStringToken(n,"Invalid escape sequence in template string")}default:if(t>=48&&t<=55){var r=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],i=parseInt(r,8);return i>255&&(r=r.slice(0,-1),i=parseInt(r,8)),this.pos+=r.length-1,t=this.input.charCodeAt(this.pos),"0"===r&&56!==t&&57!==t||!this.strict&&!e||this.invalidStringToken(this.pos-1-r.length,e?"Octal literal in template string":"Octal literal in strict mode"),String.fromCharCode(i)}return E(t)?(this.options.locations&&(this.lineStart=this.pos,++this.curLine),""):String.fromCharCode(t)}},We.readHexChar=function(e){var t=this.pos,n=this.readInt(16,e);return null===n&&this.invalidStringToken(t,"Bad character escape sequence"),n},We.readWord1=function(){this.containsEsc=!1;for(var e="",t=!0,n=this.pos,r=this.options.ecmaVersion>=6;this.pos<this.input.length;){var i=this.fullCharCodeAtPos();if(h(i,r))this.pos+=i<=65535?1:2;else{if(92!==i)break;this.containsEsc=!0,e+=this.input.slice(n,this.pos);var a=this.pos;117!==this.input.charCodeAt(++this.pos)&&this.invalidStringToken(this.pos,"Expecting Unicode escape sequence \\uXXXX"),++this.pos;var s=this.readCodePoint();(t?p:h)(s,r)||this.invalidStringToken(a,"Invalid Unicode escape"),e+=D(s),n=this.pos}t=!1}return e+this.input.slice(n,this.pos)},We.readWord=function(){var e=this.readWord1(),t=v.name;return this.keywords.test(e)&&(t=g[e]),this.finishToken(t,e)};var $e="8.14.1";q.acorn={Parser:q,version:$e,defaultOptions:F,Position:j,SourceLocation:M,getLineInfo:B,Node:pe,TokenType:d,tokTypes:v,keywordTypes:g,TokContext:te,tokContexts:ne,isIdentifierChar:h,isIdentifierStart:p,Token:ze,isNewLine:E,lineBreak:x,lineBreakG:S,nonASCIIwhitespace:_},e.Node=pe,e.Parser=q,e.Position=j,e.SourceLocation=M,e.TokContext=te,e.Token=ze,e.TokenType=d,e.defaultOptions=F,e.getLineInfo=B,e.isIdentifierChar=h,e.isIdentifierStart=p,e.isNewLine=E,e.keywordTypes=g,e.lineBreak=x,e.lineBreakG=S,e.nonASCIIwhitespace=_,e.parse=function(e,t){return q.parse(e,t)},e.parseExpressionAt=function(e,t,n){return q.parseExpressionAt(e,t,n)},e.tokContexts=ne,e.tokTypes=v,e.tokenizer=function(e,t){return q.tokenizer(e,t)},e.version=$e}(t)}(0,Ia.exports)),Ia.exports}var Oa=function(){if(Aa)return Ca;Aa=1,Object.defineProperty(Ca,"__esModule",{value:!0}),Ca.parse=void 0;var e=ei();return Ca.parse=function(t,n){var r=[],i=[],a=Na().parse(t,{allowHashBang:!0,allowImportExportEverywhere:!0,allowReturnOutsideFunction:!0,ecmaVersion:(0,e.getOption)(n,"ecmaVersion",8),sourceType:(0,e.getOption)(n,"sourceType","module"),locations:!0,onComment:r,onToken:i});return a.comments||(a.comments=r),a.tokens||(a.tokens=i),a},Ca}();function Da(e,t){return _i.parse(e,{parser:{parse:(e,t)=>Oa.parse(e,{...t,ecmaVersion:"latest"})},...t})}const La=Pi.identifier("_scope"),ja=e=>e&&e.name?e.name:e;function Ma(e,t){Ka(t),e.replace(Pi.memberExpression(La,t,!1))}function Ba(e){if(!zi(e))return Ma(e,e.node),!1;this.traverse(e)}function Fa(e){const t=()=>this.traverse(e.get("object")),n=e.node.object;switch(!0){case zi(e):n.arguments&&n.arguments.length&&t();break;case!e.value.computed&&Ii(n):Ma(e,e.node);break;default:this.traverse(e)}return!1}function Va(e){const t=e.node.value,n=e.node.shorthand;return Ii(t)||Mi(t)||n?(n&&(e.node.shorthand=!1),Ba.call(this,e.get("value"))):this.traverse(e.get("value")),!1}function Ra(e){return e.replace(La),this.traverse(e),!1}function qa(e){const t=e.parent.value;return(!Mi(t)&&t.key!==e.node||t.computed)&&Ba.call(this,e),!1}function Ua(e){return ki.visit(e,{visitIdentifier:qa,visitMemberExpression:Fa,visitObjectProperty:Va,visitThisExpression:Ra,visitClassExpression:()=>!1}),e}function za(e,t,n){return Da(`(${t?ca(e.text,n,e):e.text})`,{sourceFileName:t})}function Wa(e){return oa(Et,e?Ya(...e):sa())}function Ga(e){return e.expressions?e.expressions[0]:{...e,text:e.value}}function Ja(e){const t=Pi.arrowFunctionExpression([La],e);var n;return n=e,wi.ObjectExpression.check(n)&&(e.extra={parenthesized:!0}),t}function $a(e,t,n){return qi(Ja,Ha)(e,t,n)}function Ha(e,t,n){return qi(Ka,Xa,Ua,za)(e,t,n)}function Ka(e){return e.extra&&(e.extra.parenthesized=!1),e}function Xa(e){const t=e.program.body;return t[0]?t[0].expression:t}function Ya(e,t){return Pi.callExpression(Pi.identifier(xt),[e?Pi.literal(e):sa(),t?Pi.arrayExpression(t):sa()])}const Qa=e=>Pi.arrowFunctionExpression([xt,vt,bt,St].map(Pi.identifier),e),Za=e=>`[${e}]`;function es(e){return e?[oa("redundantAttribute",Pi.literal(e)),oa("selector",qi(Pi.literal,Za)(e))]:[]}function ts(e,t){return t?e.filter((e=>e.name!==t)):e}function ns(e){return os(e).filter((e=>![wt,At,Ct,It,Ot].includes(e.name)))}function rs(e){return{nodes:ss(e),isRoot:!0}}function is(e){return{...rs(e),isNestedRoot:!0,attributes:ns(e)}}function as(e){return e.map((e=>e.expressions?e:{...e,expressions:[{start:e.valueStart,end:e.end,text:`'${e.value?e.value:e[jt]?e.name:""}'`}]}))}function ss(e){return e&&e.nodes?e.nodes:[]}function os(e){return e.attributes?e.attributes:[]}function ls(e,t,n){const r=aa(e),i=e=>`'${e}'`;return r?r.expressions?Ja(hs(r,t,n)):$a({...r,text:i(r.value)},t,n):$a({...e,text:i(ja(e))},t,n)}function cs(e,t){return e.unescape?{...e,[t]:Ta(e[t],e.unescape)}:e}function us(e){const t=function(e){return function(e){return os(e).filter((e=>!Yi(e)))}(e).map((e=>e[jt]||!e.value?e.name:`${e.name}="${cs(e,"value").value}"`)).join(" ")}(e);switch(!0){case $i(e):return`<${e.name}${t?" "+t:""}${Ji(e)?"/":""}>`;case Hi(e):return Yi(e)?" ":cs(e,"text").text;default:return e.text||""}}function ps(e){return Pi.callExpression(Pi.memberExpression(Pi.arrayExpression(e),Pi.identifier("join"),!1),[Pi.literal("")])}function hs(e,t,n){if(!e.parts||1===e.parts.length)return Ha(e.expressions[0],t,n);const r=[...e.parts.reduce(((r,i)=>{const a=e.expressions.find((e=>e.text.trim()===i));return[...r,a?Ha(a,t,n):Pi.literal(Ea(i))]}),[])].filter((e=>!Ni(e)||e.value));return ps(r)}const ds=function(e=0){return()=>"expr"+e++}();function fs(e,t,n,r){return Pi.arrayExpression([...qi((t=>t.map((t=>ka(t,n,r,0,e)))),(e=>e.filter(Yi)),(e=>ts(e,t)),ns)(e)])}function ms(e,t,n){return Ja(hs(e,t,n))}function ys(e){return e&&e.toJSON?e.toJSON():e}var gs=ei();const bs=Object.freeze({code:"",ast:[],meta:{},map:null});function vs(e,t){const n={...bs,...e,meta:t};return!n.map&&t&&t.options&&t.options.file?{...n,map:(t.options.file,new Hr)}:n}const xs=new Set,Ss=Object.freeze({javascript:new Map,css:new Map,template:(new Map).set("default",(e=>({code:e})))});function Es(e){m(`No preprocessor of type "${e}" was found, please make sure to use one of these: 'javascript', 'css' or 'template'`)}function Ts(e,t,n,r){return Ss[e]||Es(e),Ss[e].has(t)||function(e){m(`No preprocessor named "${e}" was found, are you sure you have registered it?'`)}(t),function(e,t,n){return vs(e?e(n,t):{code:n},t)}(Ss[e].get(t),n,r)}function _s(e,t){return _i.print(e,{...t,parser:{parse:(e,t)=>Oa.parse(e,{...t,ecmaVersion:"latest"})},tabWidth:2,wrapColumn:0,quote:"single"})}const ks=e=>Li(e.left)?e.left.expressions[0]:e.left,Ps=e=>Li(e.left)?e.left.expressions[1]:null,ws=e=>e.right,As=qi(Pi.literal,ja),Cs=e=>oa("itemName",qi(As,ks)(e)),Is=e=>oa("indexName",qi(As,Ps)(e)),Ns=(e,t,n,r)=>oa(_t,qi((e=>$a(e,n,r)),(e=>({...t,text:_s(e).code})),ws)(e));function Os(e,t,n){const r=za(e,t,n).program.body[0];Oi(r)||m(`The each directives supported should be of type "ExpressionStatement",you have provided a "${r.type}"`);const{expression:i}=r;return[Cs(i),Is(i),Ns(i,e,t,n)]}function Ds(e,t,n,r){const[i,a,s]=[na,ra,ia].map((t=>t(e))),o=e=>e?$a(Ga(e),n,r):sa();return Pi.objectExpression([oa(Tt,Pi.memberExpression(Pi.identifier(bt),Pi.identifier("EACH"),!1)),oa("getKey",o(s)),oa("condition",o(i)),Wa(Us(e,n,r,t)),...es(t),...qi(Os,Ga)(a)])}function Ls(e,t,n,r){const i=na(e);return Pi.objectExpression([oa(Tt,Pi.memberExpression(Pi.identifier(bt),Pi.identifier("IF"),!1)),oa(_t,$a(i.expressions[0],n,r)),...es(t),Wa(Us(e,n,r,t))])}function js(e,t,n){const r=ss(e);return r.filter(Hi).filter(Yi).map((i=>ka(i,t,n,r.indexOf(i),e)))}function Ms(e,t,n,r){return Pi.objectExpression([...Ui(e)||Ki(e)?[]:es(t),oa("expressions",Pi.arrayExpression([...js(e,n,r),...Pa(e,n,r)]))])}function Bs(e,t,n,r){const i=ta(Nt,e),a=i?i.value:"default";return Pi.objectExpression([oa(Tt,Pi.memberExpression(Pi.identifier(bt),Pi.identifier("SLOT"),!1)),oa(Pt,fs({...e,attributes:os(e).filter((e=>ja(e)!==Nt))},t,n,r)),oa(kt,Pi.literal(a)),ss(e).length?Wa(Us({...e,attributes:[]},n,r,t)):oa(Et,Pi.nullLiteral()),...es(t)])}function Fs(e){return ss(e).reduce(((e,t)=>{const n=function(e){return os(e).find((e=>e.name===It))}(t);return n?e[n.value]=t:e.default=is({nodes:[...ss(e.default),t]}),e}),{default:null})}function Vs(e,t,n){return Pi.arrayExpression([...qi((e=>e.map((([e,r])=>function(e,t,n,r){const i={...t,attributes:os(t)},[a,s]=!Gi(i)||(o=i,o?.nodes?.length>0)?zs(i,n,r):[null,null];var o;return Pi.objectExpression([oa("id",Pi.literal(e)),a?oa("html",Pi.literal(a)):null,s?oa("bindings",Pi.arrayExpression(s)):null].filter(Boolean))}(e,r,t,n)))),(e=>e.filter((([,e])=>e))),Object.entries,Fs)(e)])}function Rs(e,t,n,r){return Pi.objectExpression([oa(Tt,Pi.memberExpression(Pi.identifier(bt),Pi.identifier("TAG"),!1)),oa("getComponent",Pi.identifier(St)),oa(_t,ls(e,n,r)),oa("slots",Vs(e,n,r)),oa(Pt,fs(e,t,n,r)),...es(t)])}const qs=Object.freeze({html:[],bindings:[],parent:null});function Us(e,t,n,r){const i=Wi(e),a=function(e,t){return{...e,attributes:ts(os(e),t)}}(e,r);return i?[null,[Rs(a,null,t,n)]]:zs(is(a),t,n)}function zs(e,t,n,r){e||m("Something went wrong with your tag DOM parsing, your tag template can't be created");const[i,a]=function(e,t,n){return r=e,[Yi,ra,na,Wi,Gi].every((e=>!e(r)))?[us(e),[]]:function(e,t,n){return!0===Hi(e)?[us(e),[]]:function(e,t,n){const r=Ki(e)?null:ds(),i=function(e,t){return t?{...e,attributes:[{name:t,value:t},...os(e)]}:e}(e,r),a=us(i);switch(!0){case Zi(i):return[a,[Ds(i,r,t,n)]];case Qi(i):return[a,[Ls(i,r,t,n)]];case Wi(i):return[a,[Rs(i,r,t,n)]];case Gi(i):return[a,[Bs(i,r,t,n)]];default:return[a,[Ms(i,r,t,n)]]}}(e,t,n)}(e,t,n);var r}(e,t,n),s=ss(e),o=!1===Ui(e),l={...(c=qs,JSON.parse(JSON.stringify(c))),...r};var c,u;return o&&l.html.push(...i),l.bindings.push(...a),s.length&&(u=e,![ra,na,Wi,Gi].some((e=>e(u))))&&s.forEach((r=>zs(r,t,n,{parent:e,...l}))),o&&$i(e)&&!Ji(e)&&l.html.push(function(e){return e.name?`</${e.name}>`:""}(e)),[l.html.join(""),l.bindings]}var Ws,Gs,Js=function(){if(Gs)return Ws;Gs=1;var e={}.hasOwnProperty,t=/[ -,\.\/:-@\[-\^`\{-~]/,n=/[ -,\.\/:-@\[\]\^`\{-~]/,r=/(^|\\+)?(\\[A-F0-9]{1,6})\x20(?![a-fA-F0-9\x20])/g,i=function i(a,s){"single"!=(s=function(t,n){if(!t)return n;var r={};for(var i in n)r[i]=e.call(t,i)?t[i]:n[i];return r}(s,i.options)).quotes&&"double"!=s.quotes&&(s.quotes="single");for(var o="double"==s.quotes?'"':"'",l=s.isIdentifier,c=a.charAt(0),u="",p=0,h=a.length;p<h;){var d=a.charAt(p++),f=d.charCodeAt(),m=void 0;if(f<32||f>126){if(f>=55296&&f<=56319&&p<h){var y=a.charCodeAt(p++);56320==(64512&y)?f=((1023&f)<<10)+(1023&y)+65536:p--}m="\\"+f.toString(16).toUpperCase()+" "}else m=s.escapeEverything?t.test(d)?"\\"+d:"\\"+f.toString(16).toUpperCase()+" ":/[\t\n\f\r\x0B]/.test(d)?"\\"+f.toString(16).toUpperCase()+" ":"\\"==d||!l&&('"'==d&&o==d||"'"==d&&o==d)||l&&n.test(d)?"\\"+d:d;u+=m}return l&&(/^-[-\d]/.test(u)?u="\\-"+u.slice(1):/\d/.test(c)&&(u="\\3"+c+" "+u.slice(1))),u=u.replace(r,(function(e,t,n){return t&&t.length%2?e:(t||"")+n})),!l&&s.wrap?o+u+o:u};return i.options={escapeEverything:!1,isIdentifier:!1,quotes:"single",wrap:!1},i.version="3.0.0",Ws=i}(),$s=Bt(Js);const Hs={SELECTOR:1,BODY_START:2,BODY_END:3},Ks=(e,t)=>{const n=[],r=t.length;let i=0;for(;;){const a=e.indexOf(t,i);if(-1===a)return n;n.push(a),i=a+r}},{SELECTOR:Xs,BODY_START:Ys,BODY_END:Qs}=Hs,Zs=(e,t=0,n)=>{let r=0,i=t;for(let a=t,s=e.length;a<s;a++){const t=e[a],s=t.index;if(s>=n)break;r=t.type===Ys?s:s+1,i=a+1}return[r,i]},{SELECTOR:eo,BODY_START:to,BODY_END:no}=Hs,ro=(e,t)=>{const{children:n}=e;let r="",i=e.bodyIndex;for(let e=0,a=n.length;e<a;e++){const a=n[e];r+=t.slice(i,a.index),i=a.indexEnd+1}return r+=t.slice(i,e.bodyIndexEnd),r};function io(e){const t=e.attributes?e.attributes.find((e=>"type"===e.name)):null;return t?t.value.replace("text/",""):null}function ao(e,t,n,r){const i=r.text;return t?Ts(e,t,n,i):{code:i}}const so=":host",oo=["from","to"],lo=/\/\*[^*]*\*+(?:[^*/][^*]*\*+)*\//g,co=/([^,]+)(?::(?!host)\w+(?:[\s|\S]*?\))?(?:[^,:]*)?)+|([^,]+)/g,uo=(e,t)=>{const{children:n}=e;return n.forEach((e=>{!1!==t(e)&&uo(e,t)})),e},po=e=>e.replace(/\\/g,"\\\\");function ho(e,t,n,r){const i=io(e),{options:a}=n,s=ao("css",i,n,e.text).code.replace(lo,"").replace(/\s+/g," ").trim(),o=(l=n.tagName,po($s(l,{isIdentifier:!0})));var l;const c=(a.scopedCss?function(e,t){const n=(e=>{const t=(e=>{const t=Ks(e,"{"),n=Ks(e,"}"),r=Array(t.length),i=Array(t.length),a=Array(n.length);let s=0,o=0,l=0;for(let e=0,n=t.length;e<n;e++)i[o++]={type:Ys,index:t[e]+1};for(let e=0,t=n.length;e<t;e++)a[l++]={type:Qs,index:n[e]};let c=0,u=0;for(let n=0,o=t.length;n<o;n++){const o=t[n],l=Zs(i,c,o),p=Zs(a,u,o);c=l[1],u=p[1];let h=l[0]>=p[0]?l[0]:p[0],d=e.slice(h,o),f=h+d.lastIndexOf(";",o)+1;f>h&&(h=f,d=e.slice(h,o)),r[s++]={type:Xs,index:h,indexEnd:o,selector:d}}return((e,t)=>{let n=e.length+t.length,r=e.length-1,i=t.length-1;const a=Array(n);for(;n>0;)a[--n]=i<0||r>=0&&e[r].index>t[i].index?e[r--]:t[i--];return a})(((e,t)=>{const n=e.length,r=Array(2*n);for(let i=0,a=0;i<n;i++,a+=2)r[a]=e[i],r[a+1]=t[i];return r})(r,i),a)})(e),n={parent:null,children:[]};let r=n,i=0;for(;;){if(!r)throw Error("Parent node not found");const n=t[i];if(!n)break;if(n.type===eo){const e=t[i+1];if(!e||e.type!==to)throw Error('Found "selector" token without expected subsequent "body_start" token');const a={parent:r,index:n.index,indexEnd:-1,selector:n.selector,selectorIndex:n.index,selectorIndexEnd:n.indexEnd,body:"",bodyIndex:e.index,bodyIndexEnd:-1,children:[]};r.children.push(a),r=a,i+=2}else{if(n.type!==no)throw Error(`Unexpected token of type: "${n.type}"`);{const t=r;t.indexEnd=n.index+1,t.bodyIndexEnd=n.index,t.body=ro(t,e),r=t.parent,i+=1}}}return n})(t),r=t.length;return uo(n,(n=>{const i=t.length-r;if(!n.selector.trim().startsWith("@")){const r=n.selector.replace(lo,"");return a=t,s=n.selectorIndex+i,o=n.selectorIndexEnd+i,l=function(e,t){return t.replace(co,((t,n)=>{const r=t.trim(),i=n?n.trim():r;return 0===i.indexOf(e)||!i||oo.indexOf(i)>-1||"%"===i.slice(-1)?t:r.indexOf(so)<0?`${e} ${r},[is="${e}"] ${r}`:`${r.replace(so,e)},${r.replace(so,`[is="${e}"]`)}`}))}(e,r),t=`${a.substring(0,s)}${l}${a.substring(o)}`,!1}var a,s,o,l})),t}(o,po(s)):po(s)).trim();return ki.visit(r,{visitProperty(e){if("css"===e.value.key.name)return e.value.value=Pi.templateLiteral([Pi.templateElement({raw:c,cooked:""},!1)],[]),!1;this.traverse(e)}}),r}function fo(e,...t){return(...n)=>(n=[...t,...n]).length<e.length?fo(e,...n):e(...n)}function mo(e){return!e||!e.length}function yo(e){return!e||mo(e.mappings)}function go(e){return e.filter(Bi)}function bo(e){return e.filter((e=>!Bi(e)))}function vo(e){return e.filter((e=>!Ri(e)||ji(e)))}function xo(e){return e.body||e.program.body}function So(e,t){return ki.visit(e,{visitProperty(e){if(e.value.key.name===ne)return e.value.value=t.declaration,!1;this.traverse(e)}}),e}function Eo(e,t,n,r){const i=io(e),a=ca(e.text.text,t,e),{options:o}=n,l=ao("javascript",i,n,{...e,text:a}),c=ys(l.map),u=xo(Da(l.code,{sourceFileName:o.file,inputSourceMap:yo(c)?null:c})),p=u.find(ji),h=s(p),d=xo(r),f=function(e){const t=e.filter(Ri).map((e=>e.declaration)),n=t.filter(Fi),r=t.filter(Vi),i=({typeName:e})=>!(!e||!e.name)&&e.name===se,a=({expression:e})=>e.name===se;return n.find((e=>e.typeAnnotation.types&&e.typeAnnotation.types.some(i)||i(e.typeAnnotation)))||r.find((e=>e.extends&&e.extends.some(a)))}(u);if(p&&u.some(Di))throw Error('You can\t use "export default {}" and root this statements in the same component');return d.unshift(...h?[...go(u),...(m=u,m.filter(Ri))]:function(e){return e.filter((e=>!ji(e)&&!Di(e)))}(u)),h&&So(r,function(e){return Pi.exportDefaultDeclaration(Pi.functionDeclaration(Pi.identifier(ne),[],Pi.blockStatement([...qi(bo,vo)(e),Pi.returnStatement(Pi.thisExpression())])))}(u)),p&&So(r,p),f?function(e,t){const n=xo(e),r=Pi.importSpecifier(Pi.identifier(ae)),i=t.id.name,a=go(n).find((e=>e.source.value===ie)),s=n.find(ji),o=s.declaration;return a?a.specifiers.push(r):n.unshift(0,Pi.importDeclaration([r],Pi.stringLiteral(ie))),s.declaration=Pi.tsAsExpression(o,Pi.tsTypeReference(Pi.identifier(ae),Pi.tsTypeParameterInstantiation([Pi.tsTypeReference(Pi.identifier(i))]))),e}(r,f):r;var m}function To(e,t,n,r){const{options:i}=n;return function(e,t,n,r){return ki.visit(e,{visitProperty(e){if(e.value.key.name===re)return e.value.value=Qa(function(e,t,n){return Ya(...zs((r=e,{...rs(r),attributes:qi(as,ns)(r)}),t,n));var r}(r,t,n)),!1;this.traverse(e)}}),e}(r,i.file,t,e)}const _o={template:"default",file:"[unknown-source-file]",scopedCss:!0};function ko({tagName:e}){return Pi.program([Pi.exportDefaultDeclaration(Pi.objectExpression([oa("css",sa()),oa(ne,sa()),oa(re,sa()),oa("name",Pi.literal(e))]))])}function Po(e){const t=ys(e);return yo(t)?null:t}function wo(e,t){return{...e,sourcesContent:[t]}}const Ao=(e,t)=>{const{parse:n}=dt(t);return n(e).output.template};function Co(e,t){return qi((({code:e})=>e),_s,Qa,Vs)(Ao(e,t),_o.file,e)}function Io(e,t={}){const n=function(e,t){return{tagName:null,fragments:null,options:{..._o,...t},source:e}}(e,t),{options:r}=n,{template:i,css:s,javascript:l,map:c,code:u}=function(e,t){if(a(e))return{...e.output,code:e.data,map:null};const{options:n}=t,{code:r,map:i}=Ts("template",n.template,t,e),s=dt(n).parse,{template:o,css:l,javascript:c}=s(r).output;if(function(e,t,n){const r=e?(""+t.substr(0,e.start)+t.substr(e.end,t.length)).trim():"";if(r)try{const{template:e,javascript:t,css:i}=n(r).output;return[e,t,i].some(a)}catch(e){return!1}return!1}(o||l||c,e,s))throw Error("Multiple HTML root nodes are not supported");return{template:o,css:l,javascript:c,map:i,code:r}}(e,n);return Object.assign(n,{tagName:i.name,fragments:{template:i,css:s,javascript:l}}),qi((e=>({...e,meta:n})),(e=>function(e,t){return Array.from(xs).reduce((function(e,n){const{code:r,map:i}=e,a=n(r,t);return{code:a.code,map:(s=i,l=a.map,o()&&s&&l&&l.mappings?gs.composeSourceMaps(ys(s),ys(l)):o()&&s?ys(s):{})};var s,l}),vs(e,t))}(e,n)),(t=>({...t,map:wo(t.map,e)})),(e=>n.ast=e&&_s(e,{sourceMapName:r.file+".map",inputSourceMap:Po(c)})),No(To,i,u,n),No(Eo,l,u,n),No(ho,s,u,n))(ko(n))}function No(e,t,n,r){return!t||!t.text&&mo(t.nodes)&&mo(t.attributes)?e=>e:fo(e)(t,n,r)}const Oo=Object.freeze({__proto__:null,compile:Io,createInitialInput:ko,generateSlotsFromString:Co,generateTemplateFunctionFromString:function(e,t){return qi((({code:e})=>e),_s,Ya)(...zs(Ao(e,t),_o.file,e))},registerPostprocessor:function(e){return xs.has(e)&&m(`This postprocessor "${e.name||e.toString()}" was already registered`),xs.add(e),xs},registerPreprocessor:function(e,t,n){return e||m("Please define the type of preprocessor you want to register 'javascript', 'css' or 'template'"),t||m("Please define a name for your preprocessor"),n||m("Please provide a preprocessor function"),Ss[e]||Es(e),Ss[e].has(t)&&m(`The preprocessor ${t} was already registered before`),Ss[e].set(t,n),Ss}}),Do={[A](e){this.el=e},[C]:Y,[I](e,t,n=!1){n?K(this.el):n||H(this.el)},clone(){return{...this}},createDOM:Y},Lo=Symbol(),jo=Symbol(),Mo=Symbol(),Bo={nodes:[],mount(e,t){return this.update(e,t)},update(e,t){const{placeholder:n,nodes:r,childrenMap:i}=this,a=e===Mo?null:this.evaluate(e),s=a?Array.from(a):[],{newChildrenMap:o,batches:l,futureNodes:c}=function(e,t,n,r){const{condition:i,template:a,childrenMap:s,itemName:o,getKey:l,indexName:c,root:u,isTemplateTag:p}=r,h=new Map,d=[],f=[];return e.forEach(((e,r)=>{const m=function(e,{itemName:t,indexName:n,index:r,item:i}){return Z(e,t,i),n&&Z(e,n,r),e}(Object.create(t),{itemName:o,indexName:c,index:r,item:e}),y=l?l(m):r,g=s.get(y),b=[];if(function(e,t){return!!e&&!e(t)}(i,m))return;const v=!g,x=g?g.template:a.clone(),S=x.el||u.cloneNode(),E=p&&v?function(e){const t=e.dom.cloneNode(!0),{head:n,tail:r}=function(){const e=document.createTextNode(""),t=document.createTextNode("");return e[Lo]=!0,t[jo]=!0,{head:e,tail:t}}();return{avoidDOMInjection:!0,fragment:t,head:n,tail:r,children:[n,...Array.from(t.childNodes),r]}}(x):x.meta;v?d.push((()=>x.mount(S,m,n,E))):d.push((()=>x.update(m,n))),p?b.push(...E.children):b.push(S),s.delete(y),f.push(...b),h.set(y,{nodes:b,template:x,context:m,index:r})})),{newChildrenMap:h,batches:d,futureNodes:f}}(s,e,t,this);return((e,t,n,r)=>{const i=t.length;let a=e.length,s=i,o=0,l=0,c=null;for(;o<a||l<s;)if(a===o){const e=s<i?l?n(t[l-1],-0).nextSibling:n(t[s-l],0):r;for(;l<s;)X(n(t[l++],1),e)}else if(s===l)for(;o<a;)c&&c.has(e[o])||K(n(e[o],-1)),o++;else if(e[o]===t[l])o++,l++;else if(e[a-1]===t[s-1])a--,s--;else if(e[o]===t[s-1]&&t[l]===e[a-1]){const r=n(e[--a],-1).nextSibling;X(n(t[l++],1),n(e[o++],-1).nextSibling),X(n(t[--s],1),r),e[a]=t[s]}else{if(!c){c=new Map;let e=l;for(;e<s;)c.set(t[e],e++)}if(c.has(e[o])){const r=c.get(e[o]);if(l<r&&r<s){let i=o,h=1;for(;++i<a&&i<s&&c.get(e[i])===r+h;)h++;if(h>r-l){const i=n(e[o],0);for(;l<r;)X(n(t[l++],1),i)}else u=n(t[l++],1),(p=n(e[o++],-1))&&p.parentNode&&p.parentNode.replaceChild(u,p)}else o++}else K(n(e[o++],-1))}var u,p})(r,c,function(e,t){return(n,r)=>{if(r<0){const n=e[e.length-1];if(n){const{template:r,nodes:i,context:a}=n;i.pop(),i.length||(e.pop(),r.unmount(a,t,null))}}return n}}(Array.from(i.values()),t),n),l.forEach((e=>e())),this.childrenMap=o,this.nodes=c,this},unmount(e,t){return this.update(Mo,t),this}},Fo={mount(e,t){return this.update(e,t)},update(e,t){const n=!!this.evaluate(e),r=!this.value&&n,i=this.value&&!n,a=()=>{const n=this.node.cloneNode();X(n,this.placeholder),this.template=this.template.clone(),this.template.mount(n,e,t)};switch(!0){case r:a();break;case i:this.unmount(e);break;default:n&&this.template.update(e,t)}return this.value=n,this},unmount(e,t){return this.template.unmount(e,t,!0),this}},Vo="undefined"==typeof Element?{}:Element.prototype,Ro=y((e=>Vo.hasOwnProperty(e))),qo=/^on/,Uo={handleEvent(e){this[e.type](e)}},zo=new WeakMap;function Wo(e){return s(e)?"":e}const Go=(e,t)=>e.childNodes[t],Jo={[l]:function e({node:n,name:r,isBoolean:s,value:o},l){if(!r)return o&&function(e,t,n){const r=t?Object.keys(t):[];Object.keys(n).filter((e=>!r.includes(e))).forEach((t=>e.removeAttribute(t)))}(n,l,o),void(l&&function(t,n){Object.keys(n).forEach((r=>e({node:t,name:r},n[r])))}(n,l));!Ro(r)&&(function(e){return t(e,"boolean")}(l)||a(l)||i(l))&&(n[r]=l),function(e,t){return t?!e&&0!==e:null==e}(l,s)?n.removeAttribute(r):function(e){return["string","number","boolean"].includes(typeof e)}(l)&&n.setAttribute(r,function(e,t,n){return!0===t&&n?e:t}(r,l,s))},[c]:function({node:e,name:t},n){const r=t.replace(qo,""),i=zo.get(e)||(e=>{const t=Object.create(Uo);return zo.set(e,t),t})(e),[a,s]=(e=>Array.isArray(e)?e:[e,!1])(n),o=i[r],l=a&&!o;o&&!a&&e.removeEventListener(r,i),l&&e.addEventListener(r,i,s),i[r]=a},[u]:function({node:e},t){e.data=Wo(t)},[p]:function({node:e},t){e.value=Wo(t)},[h]:function({node:e,value:t},n){n?n(e):t(null)}},$o={mount(e){return this.value=this.evaluate(e),Jo[this.type](this,this.value),this},update(e){const t=this.evaluate(e);return this.value!==t&&(Jo[this.type](this,t),this.value=t),this},unmount(){return[c,h].includes(this.type)&&Jo[this.type](this,null),this}};function Ho(e,t){return{...$o,...t,node:2===t.type?Go(e,t.childNodeIndex):e}}const Ko=(e,t)=>t?.find((t=>t.id===e)),Xo=(e,t)=>e[W]||t,Yo={attributes:[],getTemplateScope(e,t){return((e,t,n)=>{if(!e||!e.length)return n;const r=e.map((e=>({...e,value:e.evaluate(t)})));return Object.assign(Object.create(n||null),g(r))})(this.attributes,e,t)},mount(e,t){const n=!!e.slots&&Ko(this.name,e.slots),{parentNode:r}=this.node,i=n?Xo(e,t):e;return this.templateData=n?.html?n:Ko(this.name,i.slots),this.template=this.templateData&&al(this.templateData.html,this.templateData.bindings).createDOM(r)||this.template?.clone(),this.template&&(H(this.node),this.template.mount(this.node,this.getTemplateScope(e,i),i),this.template.children=Array.from(this.node.childNodes)),Qo(this.node),K(this.node),this},update(e,t){if(this.template){const n=this.templateData?Xo(e,t):e;this.template.update(this.getTemplateScope(e,n),n)}return this},unmount(e,t,n){return this.template&&this.template.unmount(this.getTemplateScope(e,t),null,n),this}};function Qo(e){const t=e&&e.firstChild;t&&(X(t,e),Qo(e))}function Zo(e){return e.reduce(((e,{bindings:t})=>e.concat(t)),[])}const el={mount(e){return this.update(e)},update(e,t){const n=this.evaluate(e);return n&&n===this.name?this.tag.update(e):(this.unmount(e,t,!0),this.name=n,this.tag=function(e,t=[],n=[]){return e?e({slots:t,attributes:n}):al(function(e){return e.reduce(((e,t)=>e+t.html),"")}(t),[...Zo(t),{expressions:n.map((e=>({type:0,...e})))}])}(this.getComponent(n),this.slots,this.attributes),this.tag.mount(this.node,e)),this},unmount(e,t,n){return this.tag&&this.tag.unmount(n),this}},tl={[v]:function(e,{evaluate:t,template:n}){const r=document.createTextNode("");return X(r,e),K(e),{...Fo,node:e,evaluate:t,placeholder:r,template:n.createDOM(e)}},[x]:function(e,{expressions:t}){return n=t.map((t=>Ho(e,t))),["mount","update","unmount"].reduce(((e,t)=>({...e,[t]:e=>n.map((n=>n[t](e)))&&void 0})),{});var n},[b]:function(e,{evaluate:t,condition:n,itemName:i,indexName:a,getKey:s,template:o}){const l=document.createTextNode(""),c=e.cloneNode();return X(l,e),K(e),{...Bo,childrenMap:new Map,node:e,root:c,condition:n,evaluate:t,isTemplateTag:r(c),template:o.createDOM(e),getKey:s,indexName:a,itemName:i,placeholder:l}},[S]:function(e,{evaluate:t,getComponent:n,slots:r,attributes:i}){return{...el,node:e,evaluate:t,slots:r,attributes:i,getComponent:n}},[E]:function(e,{name:t,attributes:n,template:r}){return{...Yo,attributes:n,template:r,node:e,name:t}}};function nl(e,t){return e.map((e=>2===e.type?{...e,childNodeIndex:e.childNodeIndex+t}:e))}function rl(e,t,n){const{selector:r,type:i,redundantAttribute:a,expressions:s}=t,o=r?e.querySelector(r):e;a&&o.removeAttribute(a);const l=s||[];return(tl[i]||tl[2])(o,{...t,expressions:n&&!r?nl(l,n):l})}const il={createDOM(e){return this.dom=this.dom||function(e,t){return t&&("string"==typeof t?function(e,t){return n(e)?function(e,t){return t.ownerDocument.importNode((new window.DOMParser).parseFromString(`<svg xmlns="http://www.w3.org/2000/svg">${e}</svg>`,"application/xml").documentElement,!0)}(t,e):function(e,t){const n=r(t)?t:document.createElement("template");return n.innerHTML=e,n.content}(t,e)}(e,t):t)}(e,this.html)||document.createDocumentFragment(),this},mount(e,t,i,a={}){e||m("Please provide DOM node to mount properly your template"),this.el&&this.unmount(t);const{fragment:s,children:o,avoidDOMInjection:l}=a,{parentNode:c}=o?o[0]:e,u=r(e),p=u?function(e,t,n){const r=Array.from(e.childNodes);return Math.max(r.indexOf(t),r.indexOf(n.head)+1,0)}(c,e,a):null;this.createDOM(e);const h=s||this.dom.cloneNode(!0);return this.el=u?c:e,this.children=u?o||Array.from(h.childNodes):null,!l&&h&&function(e,t){switch(!0){case n(e):!function(e,t){for(;e.firstChild;)t.appendChild(e.firstChild)}(t,e);break;case r(e):e.parentNode.replaceChild(t,e);break;default:e.appendChild(t)}}(e,h),this.bindings=this.bindingsData.map((e=>rl(this.el,e,p))),this.bindings.forEach((e=>e.mount(t,i))),this.meta=a,this},update(e,t){return this.bindings.forEach((n=>n.update(e,t))),this},unmount(e,t,n=!1){const r=this.el;if(!r)return this;switch(this.bindings.forEach((r=>r.unmount(e,t,n))),!0){case r[U]||null===n:break;case Array.isArray(this.children):!function(e){for(let t=0;t<e.length;t++)K(e[t])}(this.children);break;case!n:H(r);break;case!!n:K(r)}return this.el=null,this},clone(){return{...this,meta:{},el:null}}};function al(e,t=[]){return{...il,html:e,bindingsData:t}}const sl=Object.freeze({[A]:Y,[C]:Y,[I]:Y}),ol=(e,t)=>e[k]=t;function ll(e){return[A,C,I].reduce(((t,n)=>(t[n]=e(n),t)),{})}function cl(e){return Array.isArray(e)?e:/^\[object (HTMLCollection|NodeList|Object)\]$/.test(Object.prototype.toString.call(e))&&"number"==typeof e.length?Array.from(e):[e]}function ul(e,t){return cl("string"==typeof e?(t||document).querySelectorAll(e):e)}const pl=Object.freeze({$(e){return ul(e,this.root)[0]},$$(e){return ul(e,this.root)}}),hl=Object.freeze({[N]:Y,[O]:Y,[D]:Y,[L]:Y,[j]:Y,[M]:Y,[B]:Y}),dl=e=>1===e.length?e[0]:e;function fl(e,t,n){const r="object"==typeof t?t:{[t]:n},i=Object.keys(r);return cl(e).forEach((e=>{i.forEach((t=>e.setAttribute(t,r[t])))})),e}function ml(e,t){return function(e,t){const n="string"==typeof t?[t]:t;return dl(cl(e).map((e=>dl(n.map((t=>e.getAttribute(t)))))))}(e,t)}const yl=new Map;var gl;const bl={CSS_BY_NAME:yl,add(e,t){return yl.has(e)||(yl.set(e,t),this.inject()),this},inject(){return(gl||(fl(gl=ul("style[riot]")[0]||document.createElement("style"),"type","text/css"),gl.parentNode||document.head.appendChild(gl),gl)).innerHTML=[...yl.values()].join("\n"),this},remove(e){return yl.has(e)&&(yl.delete(e),this.inject()),this}};function vl(e,...t){return(...n)=>(n=[...t,...n]).length<e.length?vl(e,...n):e(...n)}function xl(e){return ml(e,w)||e.tagName.toLowerCase()}function Sl(e,t){return{...e,...Q(t)}}function El(e,t={}){return{...$(e),...Q(t)}}const Tl=y((e=>{const t=e?.bindingsData?.[0];return t?.selector?[]:t?.expressions?.reduce(((e,{name:t,type:n})=>n===d.ATTRIBUTE?e.concat([t]):e),[])??[]}));function _l(e,{slots:t,attributes:n,props:r}){return s=function(e){return[...P].reduce(((e,t)=>t(e)||e),e)}(ee(a(e)?Object.create(e):e,{mount(i,a={},s){return Z(i,U,!1),this[W]=s,this[G]=function(e,t=[]){const n=t.map((t=>Ho(e,t))),r={};return Object.assign(r,{expressions:n,...ll((e=>t=>(n.forEach((n=>n[e](t))),r)))})}(i,n).mount(s),Z(this,F,Object.freeze({...El(i,r),...g(this[G].expressions)})),this[V]=Sl(this[V],a),this[J]=this.template.createDOM(i).clone(),ol(i,this),e.name&&function(e,t){xl(e)!==t&&fl(e,w,t)}(i,e.name),Z(this,q,i),Z(this,R,t),this[O](this[F],this[V]),this[J].mount(i,this,s),this[D](this[F],this[V]),this},update(e={},t){t&&(this[W]=t,this[G].update(t));const n=Tl(this[J]),r=$({attributes:Array.from(this[q].attributes).filter((({name:e})=>!n.includes(e)))}),{[w]:i,...s}={...r,...g(this[G].expressions)};var o,l;if(!1!==this[N](s,this[F]))return Z(this,F,Object.freeze({...t?(o=this[F],l=n,a(o)?Object.fromEntries(l.map((e=>[e,o[e]]))):o):this[F],...s})),this[V]=Sl(this[V],e),this[L](this[F],this[V]),this[z]||(this[z]=!0,this[J].update(this,this[W])),this[j](this[F],this[V]),this[z]=!1,this},unmount(e){return this[M](this[F],this[V]),this[G].unmount(),this[J].unmount(this,this[W],null===e?null:!e),this[B](this[F],this[V]),this}})),Object.keys(e).filter((t=>i(e[t]))).forEach((e=>{s[e]=s[e].bind(s)})),s;var s}function kl({css:e,template:t,componentAPI:n,name:r}){return e&&r&&bl.add(r,e),vl(_l)(ee(te(n,{...hl,[F]:{},[V]:{}}),{[R]:null,[q]:null,...pl,name:r,css:e,template:t}))}const Pl=y(wl);function wl(e){const{css:t,template:n,exports:r,name:i}=e,a=n?function(e,t,n){return e(al,d,T,n)}(n,0,(e=>{const t=function(e={}){return Object.entries(Q(e)).reduce(((e,[t,n])=>{var r;return e[(r=t,r.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase())]=wl(n),e}),{})}(e.exports?e.exports.components:{});return n=>n===e.name?Pl(e):t[n]||_.get(n)})(e)):Do;return({slots:e,attributes:s,props:o})=>{if(r&&r[U])return function(e,{slots:t,attributes:n,props:r,css:i,template:a}){a&&m("Pure components can not have html"),i&&m("Pure components do not have css");const s=te(e({slots:t,attributes:n,props:r}),sl);return ll((e=>(...t)=>{if(e===A){const[e]=t;Z(e,U,!0),ol(e,s)}return s[e](...t),s}))}(r,{slots:e,attributes:s,props:o,css:t,template:n});const l=Q(r)||{},c=kl({css:t,template:a,componentAPI:l,name:i})({slots:e,attributes:s,props:o});return{mount:(e,t,n)=>c.mount(e,n,t),update:(e,t)=>c.update(t,e),unmount:e=>c.unmount(e)}}}function Al(e,{css:t,template:n,exports:r}){return _.has(e)&&m(`The component "${e}" was already registered`),_.set(e,wl({name:e,css:t,template:n,exports:r})),_}const Cl={cssManager:bl,DOMBindings:{template:al,createBinding:rl,createExpression:Ho,bindingTypes:T,expressionTypes:d},globals:{PROPS_KEY:F,STATE_KEY:V,IS_COMPONENT_UPDATING:z,ATTRIBUTES_KEY_SYMBOL:G,COMPONENTS_IMPLEMENTATION_MAP:_,PLUGINS_SET:P,DOM_COMPONENT_INSTANCE_PROPERTY:k,PARENT_KEY_SYMBOL:W}};async function Il(e,t){const n=await fetch(e);return Io(await n.text(),{file:e,...t})}const Nl="__riot_registry__",Ol="undefined"==typeof process;function Dl(e,t,n){window[Nl]=window[Nl]||{},function(e,t){Ol?((e,t)=>{const n=document.createElement("script"),r=document.documentElement;n.text=t?`${e}\n//# sourceURL=${t}.js`:e,r.appendChild(n),r.removeChild(n)})(e,t):Function(e)()}(`window.${Nl}['${t}'] = ${function(e){return`(function (global){${e}})(this)`.replace("export default","return")}(e)}`,n),Al(t,window[Nl][t])}function Ll(e){if(!e.innerHTML.trim())return null;const t=Co(e.outerHTML);return e.innerHTML="",Function("return "+t)()(al,d,T,(e=>_.get(e)))}e.__=Cl,e.compile=async function(e){const t=ul('script[type="riot"]').map((e=>ml(e,"src")||ml(e,"data-src")));(await Promise.all(t.map((t=>Il(t,e))))).forEach((({code:e,meta:n},r)=>{const i=t[r],{tagName:a}=n;Dl(e,a,i)}))},e.compileFromString=function(e,t){return Io(e,t)},e.compileFromUrl=Il,e.compiler=Oo,e.component=function(e){const t=function(e){return(t,n,{slots:r,attributes:i,parentScope:a}={})=>function(...e){return e.reduce(((e,t)=>(...n)=>e(t(...n))))}((e=>e.mount(t,a)),(e=>e({props:n,slots:r,attributes:i})),wl)(e)}(e);return(e,n,{slots:r,attributes:i,parentScope:a}={})=>t(e,n,{slots:r||Ll(e),attributes:i,parentScope:a})},e.inject=Dl,e.install=function(e){return i(e)||m("Plugins must be of type function"),P.has(e)&&m("This plugin was already installed"),P.add(e),P},e.mount=function(e,t,n){return ul(e).map((e=>function(e,t,n,r){const i=n||xl(e);return _.has(i)||m(`The component named "${i}" was never registered`),_.get(i)({props:t,slots:r}).mount(e)}(e,t,n,Ll(e))))},e.pure=function(e){return i(e)||m('riot.pure accepts only arguments of type "function"'),e[U]=!0,e},e.register=Al,e.uninstall=function(e){return P.has(e)||m("This plugin was never installed"),P.delete(e),P},e.unmount=function(e,t){return ul(e).map((e=>(e[k]&&e[k].unmount(t),e)))},e.unregister=function(e){return _.has(e)||m(`The component "${e}" was never registered`),_.delete(e),bl.remove(e),_},e.version="v9.4.7",e.withTypes=e=>e},"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).riot={});