@mintjamsinc/ichigojs 0.1.14 → 0.1.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,2 +1,2 @@
1
- !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).ichigo={})}(this,function(e){"use strict";class t{id;createInstance;templateID;constructor(e,t,i){if(!e||"string"!=typeof e)throw new Error("Component ID must be a non-empty string.");if("function"!=typeof t)throw new Error("createInstance must be a function.");this.id=e.trim(),this.createInstance=t,this.templateID=i?.trim()||this.id}}class i{#e=new Map;register(e,i,s){if(this.has(e))return!1;const n=new t(e,i,s);return this.#e.set(e,n),!0}has(e){return this.#e.has(e)}get(e){return this.#e.get(e)}unregister(e){return this.#e.delete(e)}clear(){this.#e.clear()}}class s{#t=[];get parsers(){return this.#t.slice()}register(e){this.#t.push(e)}unregister(e){const t=this.#t.indexOf(e);t>=0&&this.#t.splice(t,1)}findParser(e){return this.#t.find(t=>t.canParse(e))||null}}var n;!function(e){e.V_IF="v-if",e.V_ELSE_IF="v-else-if",e.V_ELSE="v-else",e.V_SHOW="v-show",e.V_FOR="v-for",e.V_ON="v-on",e.V_BIND="v-bind",e.V_MODEL="v-model",e.V_RESIZE="v-resize",e.V_INTERSECTION="v-intersection",e.V_PERFORMANCE="v-performance",e.V_COMPONENT="v-component"}(n||(n={}));var r=[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],a=[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],o="ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢎࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೝೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-ᲊᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꟍꟐꟑꟓꟕ-Ƛꟲ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",h={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"},p="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",c={5:p,"5module":p+" export import",6:p+" const class extends export import super"},u=/^in(stanceof)?$/,d=new RegExp("["+o+"]"),l=new RegExp("["+o+"‌‍·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛ࢗ-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ-ᫎᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‌‍‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・]");function f(e,t){for(var i=65536,s=0;s<t.length;s+=2){if((i+=t[s])>e)return!1;if((i+=t[s+1])>=e)return!0}return!1}function m(e,t){return e<65?36===e:e<91||(e<97?95===e:e<123||(e<=65535?e>=170&&d.test(String.fromCharCode(e)):!1!==t&&f(e,a)))}function g(e,t){return e<48?36===e:e<58||!(e<65)&&(e<91||(e<97?95===e:e<123||(e<=65535?e>=170&&l.test(String.fromCharCode(e)):!1!==t&&(f(e,a)||f(e,r)))))}var v=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 x(e,t){return new v(e,{beforeExpr:!0,binop:t})}var y={beforeExpr:!0},b={startsExpr:!0},E={};function N(e,t){return void 0===t&&(t={}),t.keyword=e,E[e]=new v(e,t)}var _={num:new v("num",b),regexp:new v("regexp",b),string:new v("string",b),name:new v("name",b),privateId:new v("privateId",b),eof:new v("eof"),bracketL:new v("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new v("]"),braceL:new v("{",{beforeExpr:!0,startsExpr:!0}),braceR:new v("}"),parenL:new v("(",{beforeExpr:!0,startsExpr:!0}),parenR:new v(")"),comma:new v(",",y),semi:new v(";",y),colon:new v(":",y),dot:new v("."),question:new v("?",y),questionDot:new v("?."),arrow:new v("=>",y),template:new v("template"),invalidTemplate:new v("invalidTemplate"),ellipsis:new v("...",y),backQuote:new v("`",b),dollarBraceL:new v("${",{beforeExpr:!0,startsExpr:!0}),eq:new v("=",{beforeExpr:!0,isAssign:!0}),assign:new v("_=",{beforeExpr:!0,isAssign:!0}),incDec:new v("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new v("!/~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:x("||",1),logicalAND:x("&&",2),bitwiseOR:x("|",3),bitwiseXOR:x("^",4),bitwiseAND:x("&",5),equality:x("==/!=/===/!==",6),relational:x("</>/<=/>=",7),bitShift:x("<</>>/>>>",8),plusMin:new v("+/-",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:x("%",10),star:x("*",10),slash:x("/",10),starstar:new v("**",{beforeExpr:!0}),coalesce:x("??",1),_break:N("break"),_case:N("case",y),_catch:N("catch"),_continue:N("continue"),_debugger:N("debugger"),_default:N("default",y),_do:N("do",{isLoop:!0,beforeExpr:!0}),_else:N("else",y),_finally:N("finally"),_for:N("for",{isLoop:!0}),_function:N("function",b),_if:N("if"),_return:N("return",y),_switch:N("switch"),_throw:N("throw",y),_try:N("try"),_var:N("var"),_const:N("const"),_while:N("while",{isLoop:!0}),_with:N("with"),_new:N("new",{beforeExpr:!0,startsExpr:!0}),_this:N("this",b),_super:N("super",b),_class:N("class",b),_extends:N("extends",y),_export:N("export"),_import:N("import",b),_null:N("null",b),_true:N("true",b),_false:N("false",b),_in:N("in",{beforeExpr:!0,binop:7}),_instanceof:N("instanceof",{beforeExpr:!0,binop:7}),_typeof:N("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:N("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:N("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})},S=/\r\n?|\n|\u2028|\u2029/,w=new RegExp(S.source,"g");function I(e){return 10===e||13===e||8232===e||8233===e}function k(e,t,i){void 0===i&&(i=e.length);for(var s=t;s<i;s++){var n=e.charCodeAt(s);if(I(n))return s<i-1&&13===n&&10===e.charCodeAt(s+1)?s+2:s+1}return-1}var C=/[\u1680\u2000-\u200a\u202f\u205f\u3000\ufeff]/,A=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g,V=Object.prototype,P=V.hasOwnProperty,T=V.toString,D=Object.hasOwn||function(e,t){return P.call(e,t)},L=Array.isArray||function(e){return"[object Array]"===T.call(e)},M=Object.create(null);function R(e){return M[e]||(M[e]=new RegExp("^(?:"+e.replace(/ /g,"|")+")$"))}function O(e){return e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10),56320+(1023&e)))}var F=/(?:[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])/,U=function(e,t){this.line=e,this.column=t};U.prototype.offset=function(e){return new U(this.line,this.column+e)};var B=function(e,t,i){this.start=t,this.end=i,null!==e.sourceFile&&(this.source=e.sourceFile)};function W(e,t){for(var i=1,s=0;;){var n=k(e,s,t);if(n<0)return new U(i,t-s);++i,s=n}}var $={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},j=!1;function z(e){var t={};for(var i in $)t[i]=e&&D(e,i)?e[i]:$[i];if("latest"===t.ecmaVersion?t.ecmaVersion=1e8:null==t.ecmaVersion?(!j&&"object"==typeof console&&console.warn&&(j=!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),L(t.onToken)){var s=t.onToken;t.onToken=function(e){return s.push(e)}}return L(t.onComment)&&(t.onComment=function(e,t){return function(i,s,n,r,a,o){var h={type:i?"Block":"Line",value:s,start:n,end:r};e.locations&&(h.loc=new B(this,a,o)),e.ranges&&(h.range=[n,r]),t.push(h)}}(t,t.onComment)),t}var H=256,q=259;function G(e,t){return 2|(e?4:0)|(t?8:0)}var K=function(e,t,i){this.options=e=z(e),this.sourceFile=e.sourceFile,this.keywords=R(c[e.ecmaVersion>=6?6:"module"===e.sourceType?"5module":5]);var s="";!0!==e.allowReserved&&(s=h[e.ecmaVersion>=6?6:5===e.ecmaVersion?5:3],"module"===e.sourceType&&(s+=" await")),this.reservedWords=R(s);var n=(s?s+" ":"")+h.strict;this.reservedWordsStrict=R(n),this.reservedWordsStrictBind=R(n+" "+h.strictBind),this.input=String(t),this.containsEsc=!1,i?(this.pos=i,this.lineStart=this.input.lastIndexOf("\n",i-1)+1,this.curLine=this.input.slice(0,this.lineStart).split(S).length):(this.pos=this.lineStart=0,this.curLine=1),this.type=_.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=[]},Q={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}};K.prototype.parse=function(){var e=this.options.program||this.startNode();return this.nextToken(),this.parseTopLevel(e)},Q.inFunction.get=function(){return(2&this.currentVarScope().flags)>0},Q.inGenerator.get=function(){return(8&this.currentVarScope().flags)>0},Q.inAsync.get=function(){return(4&this.currentVarScope().flags)>0},Q.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},Q.allowSuper.get=function(){return(64&this.currentThisScope().flags)>0||this.options.allowSuperOutsideMethod},Q.allowDirectSuper.get=function(){return(128&this.currentThisScope().flags)>0},Q.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())},Q.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},Q.inClassStaticBlock.get=function(){return(this.currentVarScope().flags&H)>0},K.extend=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];for(var i=this,s=0;s<e.length;s++)i=e[s](i);return i},K.parse=function(e,t){return new this(t,e).parse()},K.parseExpressionAt=function(e,t,i){var s=new this(i,e,t);return s.nextToken(),s.parseExpression()},K.tokenizer=function(e,t){return new this(t,e)},Object.defineProperties(K.prototype,Q);var Z=K.prototype,X=/^(?:'((?:\\[^]|[^'\\])*?)'|"((?:\\[^]|[^"\\])*?)")/;Z.strictDirective=function(e){if(this.options.ecmaVersion<5)return!1;for(;;){A.lastIndex=e,e+=A.exec(this.input)[0].length;var t=X.exec(this.input.slice(e));if(!t)return!1;if("use strict"===(t[1]||t[2])){A.lastIndex=e+t[0].length;var i=A.exec(this.input),s=i.index+i[0].length,n=this.input.charAt(s);return";"===n||"}"===n||S.test(i[0])&&!(/[(`.[+\-/*%<>=,?^&]/.test(n)||"!"===n&&"="===this.input.charAt(s+1))}e+=t[0].length,A.lastIndex=e,e+=A.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===_.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===_.eof||this.type===_.braceR||S.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(_.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 Y=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 i=t?e.parenthesizedAssign:e.parenthesizedBind;i>-1&&this.raiseRecoverable(i,t?"Assigning to rvalue":"Parenthesized pattern")}},Z.checkExpressionErrors=function(e,t){if(!e)return!1;var i=e.shorthandAssign,s=e.doubleProto;if(!t)return i>=0||s>=0;i>=0&&this.raise(i,"Shorthand property assignments are valid only in destructuring patterns"),s>=0&&this.raiseRecoverable(s,"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=K.prototype;J.parseTopLevel=function(e){var t=Object.create(null);for(e.body||(e.body=[]);this.type!==_.eof;){var i=this.parseStatement(null,!0,t);e.body.push(i)}if(this.inModule)for(var s=0,n=Object.keys(this.undefinedExports);s<n.length;s+=1){var r=n[s];this.raiseRecoverable(this.undefinedExports[r].start,"Export '"+r+"' is not defined")}return this.adaptDirectivePrologue(e.body),this.next(),e.sourceType=this.options.sourceType,this.finishNode(e,"Program")};var ee={kind:"loop"},te={kind:"switch"};J.isLet=function(e){if(this.options.ecmaVersion<6||!this.isContextual("let"))return!1;A.lastIndex=this.pos;var t=A.exec(this.input),i=this.pos+t[0].length,s=this.input.charCodeAt(i);if(91===s||92===s)return!0;if(e)return!1;if(123===s||s>55295&&s<56320)return!0;if(m(s,!0)){for(var n=i+1;g(s=this.input.charCodeAt(n),!0);)++n;if(92===s||s>55295&&s<56320)return!0;var r=this.input.slice(i,n);if(!u.test(r))return!0}return!1},J.isAsyncFunction=function(){if(this.options.ecmaVersion<8||!this.isContextual("async"))return!1;A.lastIndex=this.pos;var e,t=A.exec(this.input),i=this.pos+t[0].length;return!(S.test(this.input.slice(this.pos,i))||"function"!==this.input.slice(i,i+8)||i+8!==this.input.length&&(g(e=this.input.charCodeAt(i+8))||e>55295&&e<56320))},J.isUsingKeyword=function(e,t){if(this.options.ecmaVersion<17||!this.isContextual(e?"await":"using"))return!1;A.lastIndex=this.pos;var i=A.exec(this.input),s=this.pos+i[0].length;if(S.test(this.input.slice(this.pos,s)))return!1;if(e){var n,r=s+5;if("using"!==this.input.slice(s,r)||r===this.input.length||g(n=this.input.charCodeAt(r))||n>55295&&n<56320)return!1;A.lastIndex=r;var a=A.exec(this.input);if(a&&S.test(this.input.slice(r,r+a[0].length)))return!1}if(t){var o,h=s+2;if(!("of"!==this.input.slice(s,h)||h!==this.input.length&&(g(o=this.input.charCodeAt(h))||o>55295&&o<56320)))return!1}var p=this.input.charCodeAt(s);return m(p,!0)||92===p},J.isAwaitUsing=function(e){return this.isUsingKeyword(!0,e)},J.isUsing=function(e){return this.isUsingKeyword(!1,e)},J.parseStatement=function(e,t,i){var s,n=this.type,r=this.startNode();switch(this.isLet(e)&&(n=_._var,s="let"),n){case _._break:case _._continue:return this.parseBreakContinueStatement(r,n.keyword);case _._debugger:return this.parseDebuggerStatement(r);case _._do:return this.parseDoStatement(r);case _._for:return this.parseForStatement(r);case _._function:return e&&(this.strict||"if"!==e&&"label"!==e)&&this.options.ecmaVersion>=6&&this.unexpected(),this.parseFunctionStatement(r,!1,!e);case _._class:return e&&this.unexpected(),this.parseClass(r,!0);case _._if:return this.parseIfStatement(r);case _._return:return this.parseReturnStatement(r);case _._switch:return this.parseSwitchStatement(r);case _._throw:return this.parseThrowStatement(r);case _._try:return this.parseTryStatement(r);case _._const:case _._var:return s=s||this.value,e&&"var"!==s&&this.unexpected(),this.parseVarStatement(r,s);case _._while:return this.parseWhileStatement(r);case _._with:return this.parseWithStatement(r);case _.braceL:return this.parseBlock(!0,r);case _.semi:return this.parseEmptyStatement(r);case _._export:case _._import:if(this.options.ecmaVersion>10&&n===_._import){A.lastIndex=this.pos;var a=A.exec(this.input),o=this.pos+a[0].length,h=this.input.charCodeAt(o);if(40===h||46===h)return this.parseExpressionStatement(r,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'")),n===_._import?this.parseImport(r):this.parseExport(r,i);default:if(this.isAsyncFunction())return e&&this.unexpected(),this.next(),this.parseFunctionStatement(r,!0,!e);var p=this.isAwaitUsing(!1)?"await using":this.isUsing(!1)?"using":null;if(p)return t&&"script"===this.options.sourceType&&this.raise(this.start,"Using declaration cannot appear in the top level when source type is `script`"),"await using"===p&&(this.canAwait||this.raise(this.start,"Await using cannot appear outside of async function"),this.next()),this.next(),this.parseVar(r,!1,p),this.semicolon(),this.finishNode(r,"VariableDeclaration");var c=this.value,u=this.parseExpression();return n===_.name&&"Identifier"===u.type&&this.eat(_.colon)?this.parseLabeledStatement(r,c,u,e):this.parseExpressionStatement(r,u)}},J.parseBreakContinueStatement=function(e,t){var i="break"===t;this.next(),this.eat(_.semi)||this.insertSemicolon()?e.label=null:this.type!==_.name?this.unexpected():(e.label=this.parseIdent(),this.semicolon());for(var s=0;s<this.labels.length;++s){var n=this.labels[s];if(null==e.label||n.name===e.label.name){if(null!=n.kind&&(i||"loop"===n.kind))break;if(e.label&&i)break}}return s===this.labels.length&&this.raise(e.start,"Unsyntactic "+t),this.finishNode(e,i?"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(ee),e.body=this.parseStatement("do"),this.labels.pop(),this.expect(_._while),e.test=this.parseParenExpression(),this.options.ecmaVersion>=6?this.eat(_.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(ee),this.enterScope(0),this.expect(_.parenL),this.type===_.semi)return t>-1&&this.unexpected(t),this.parseFor(e,null);var i=this.isLet();if(this.type===_._var||this.type===_._const||i){var s=this.startNode(),n=i?"let":this.value;return this.next(),this.parseVar(s,!0,n),this.finishNode(s,"VariableDeclaration"),this.parseForAfterInit(e,s,t)}var r=this.isContextual("let"),a=!1,o=this.isUsing(!0)?"using":this.isAwaitUsing(!0)?"await using":null;if(o){var h=this.startNode();return this.next(),"await using"===o&&this.next(),this.parseVar(h,!0,o),this.finishNode(h,"VariableDeclaration"),this.parseForAfterInit(e,h,t)}var p=this.containsEsc,c=new Y,u=this.start,d=t>-1?this.parseExprSubscripts(c,"await"):this.parseExpression(!0,c);return this.type===_._in||(a=this.options.ecmaVersion>=6&&this.isContextual("of"))?(t>-1?(this.type===_._in&&this.unexpected(t),e.await=!0):a&&this.options.ecmaVersion>=8&&(d.start!==u||p||"Identifier"!==d.type||"async"!==d.name?this.options.ecmaVersion>=9&&(e.await=!1):this.unexpected()),r&&a&&this.raise(d.start,"The left-hand side of a for-of loop may not start with 'let'."),this.toAssignable(d,!1,c),this.checkLValPattern(d),this.parseForIn(e,d)):(this.checkExpressionErrors(c,!0),t>-1&&this.unexpected(t),this.parseFor(e,d))},J.parseForAfterInit=function(e,t,i){return(this.type===_._in||this.options.ecmaVersion>=6&&this.isContextual("of"))&&1===t.declarations.length?(this.options.ecmaVersion>=9&&(this.type===_._in?i>-1&&this.unexpected(i):e.await=i>-1),this.parseForIn(e,t)):(i>-1&&this.unexpected(i),this.parseFor(e,t))},J.parseFunctionStatement=function(e,t,i){return this.next(),this.parseFunction(e,se|(i?0:ne),!1,t)},J.parseIfStatement=function(e){return this.next(),e.test=this.parseParenExpression(),e.consequent=this.parseStatement("if"),e.alternate=this.eat(_._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(_.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(_.braceL),this.labels.push(te),this.enterScope(0);for(var i=!1;this.type!==_.braceR;)if(this.type===_._case||this.type===_._default){var s=this.type===_._case;t&&this.finishNode(t,"SwitchCase"),e.cases.push(t=this.startNode()),t.consequent=[],this.next(),s?t.test=this.parseExpression():(i&&this.raiseRecoverable(this.lastTokStart,"Multiple default clauses"),i=!0,t.test=null),this.expect(_.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(),S.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 ie=[];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(_.parenR),e},J.parseTryStatement=function(e){if(this.next(),e.block=this.parseBlock(),e.handler=null,this.type===_._catch){var t=this.startNode();this.next(),this.eat(_.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(_._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,i){return this.next(),this.parseVar(e,!1,t,i),this.semicolon(),this.finishNode(e,"VariableDeclaration")},J.parseWhileStatement=function(e){return this.next(),e.test=this.parseParenExpression(),this.labels.push(ee),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,i,s){for(var n=0,r=this.labels;n<r.length;n+=1){r[n].name===t&&this.raise(i.start,"Label '"+t+"' is already declared")}for(var a=this.type.isLoop?"loop":this.type===_._switch?"switch":null,o=this.labels.length-1;o>=0;o--){var h=this.labels[o];if(h.statementStart!==e.start)break;h.statementStart=this.start,h.kind=a}return this.labels.push({name:t,kind:a,statementStart:this.start}),e.body=this.parseStatement(s?-1===s.indexOf("label")?s+"label":s:"label"),this.labels.pop(),e.label=i,this.finishNode(e,"LabeledStatement")},J.parseExpressionStatement=function(e,t){return e.expression=t,this.semicolon(),this.finishNode(e,"ExpressionStatement")},J.parseBlock=function(e,t,i){for(void 0===e&&(e=!0),void 0===t&&(t=this.startNode()),t.body=[],this.expect(_.braceL),e&&this.enterScope(0);this.type!==_.braceR;){var s=this.parseStatement(null);t.body.push(s)}return i&&(this.strict=!1),this.next(),e&&this.exitScope(),this.finishNode(t,"BlockStatement")},J.parseFor=function(e,t){return e.init=t,this.expect(_.semi),e.test=this.type===_.semi?null:this.parseExpression(),this.expect(_.semi),e.update=this.type===_.parenR?null:this.parseExpression(),this.expect(_.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,"ForStatement")},J.parseForIn=function(e,t){var i=this.type===_._in;return this.next(),"VariableDeclaration"===t.type&&null!=t.declarations[0].init&&(!i||this.options.ecmaVersion<8||this.strict||"var"!==t.kind||"Identifier"!==t.declarations[0].id.type)&&this.raise(t.start,(i?"for-in":"for-of")+" loop variable declaration may not have an initializer"),e.left=t,e.right=i?this.parseExpression():this.parseMaybeAssign(),this.expect(_.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,i?"ForInStatement":"ForOfStatement")},J.parseVar=function(e,t,i,s){for(e.declarations=[],e.kind=i;;){var n=this.startNode();if(this.parseVarId(n,i),this.eat(_.eq)?n.init=this.parseMaybeAssign(t):s||"const"!==i||this.type===_._in||this.options.ecmaVersion>=6&&this.isContextual("of")?s||"using"!==i&&"await using"!==i||!(this.options.ecmaVersion>=17)||this.type===_._in||this.isContextual("of")?s||"Identifier"===n.id.type||t&&(this.type===_._in||this.isContextual("of"))?n.init=null:this.raise(this.lastTokEnd,"Complex binding patterns require an initialization value"):this.raise(this.lastTokEnd,"Missing initializer in "+i+" declaration"):this.unexpected(),e.declarations.push(this.finishNode(n,"VariableDeclarator")),!this.eat(_.comma))break}return e},J.parseVarId=function(e,t){e.id="using"===t||"await using"===t?this.parseIdent():this.parseBindingAtom(),this.checkLValPattern(e.id,"var"===t?1:2,!1)};var se=1,ne=2;function re(e,t){var i=t.key.name,s=e[i],n="true";return"MethodDefinition"!==t.type||"get"!==t.kind&&"set"!==t.kind||(n=(t.static?"s":"i")+t.kind),"iget"===s&&"iset"===n||"iset"===s&&"iget"===n||"sget"===s&&"sset"===n||"sset"===s&&"sget"===n?(e[i]="true",!1):!!s||(e[i]=n,!1)}function ae(e,t){var i=e.computed,s=e.key;return!i&&("Identifier"===s.type&&s.name===t||"Literal"===s.type&&s.value===t)}J.parseFunction=function(e,t,i,s,n){this.initFunction(e),(this.options.ecmaVersion>=9||this.options.ecmaVersion>=6&&!s)&&(this.type===_.star&&t&ne&&this.unexpected(),e.generator=this.eat(_.star)),this.options.ecmaVersion>=8&&(e.async=!!s),t&se&&(e.id=4&t&&this.type!==_.name?null:this.parseIdent(),!e.id||t&ne||this.checkLValSimple(e.id,this.strict||e.generator||e.async?this.treatFunctionsAsVar?1:2:3));var r=this.yieldPos,a=this.awaitPos,o=this.awaitIdentPos;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(G(e.async,e.generator)),t&se||(e.id=this.type===_.name?this.parseIdent():null),this.parseFunctionParams(e),this.parseFunctionBody(e,i,!1,n),this.yieldPos=r,this.awaitPos=a,this.awaitIdentPos=o,this.finishNode(e,t&se?"FunctionDeclaration":"FunctionExpression")},J.parseFunctionParams=function(e){this.expect(_.parenL),e.params=this.parseBindingList(_.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()},J.parseClass=function(e,t){this.next();var i=this.strict;this.strict=!0,this.parseClassId(e,t),this.parseClassSuper(e);var s=this.enterClassBody(),n=this.startNode(),r=!1;for(n.body=[],this.expect(_.braceL);this.type!==_.braceR;){var a=this.parseClassElement(null!==e.superClass);a&&(n.body.push(a),"MethodDefinition"===a.type&&"constructor"===a.kind?(r&&this.raiseRecoverable(a.start,"Duplicate constructor in the same class"),r=!0):a.key&&"PrivateIdentifier"===a.key.type&&re(s,a)&&this.raiseRecoverable(a.key.start,"Identifier '#"+a.key.name+"' has already been declared"))}return this.strict=i,this.next(),e.body=this.finishNode(n,"ClassBody"),this.exitClassBody(),this.finishNode(e,t?"ClassDeclaration":"ClassExpression")},J.parseClassElement=function(e){if(this.eat(_.semi))return null;var t=this.options.ecmaVersion,i=this.startNode(),s="",n=!1,r=!1,a="method",o=!1;if(this.eatContextual("static")){if(t>=13&&this.eat(_.braceL))return this.parseClassStaticBlock(i),i;this.isClassElementNameStart()||this.type===_.star?o=!0:s="static"}if(i.static=o,!s&&t>=8&&this.eatContextual("async")&&(!this.isClassElementNameStart()&&this.type!==_.star||this.canInsertSemicolon()?s="async":r=!0),!s&&(t>=9||!r)&&this.eat(_.star)&&(n=!0),!s&&!r&&!n){var h=this.value;(this.eatContextual("get")||this.eatContextual("set"))&&(this.isClassElementNameStart()?a=h:s=h)}if(s?(i.computed=!1,i.key=this.startNodeAt(this.lastTokStart,this.lastTokStartLoc),i.key.name=s,this.finishNode(i.key,"Identifier")):this.parseClassElementName(i),t<13||this.type===_.parenL||"method"!==a||n||r){var p=!i.static&&ae(i,"constructor"),c=p&&e;p&&"method"!==a&&this.raise(i.key.start,"Constructor can't have get/set modifier"),i.kind=p?"constructor":a,this.parseClassMethod(i,n,r,c)}else this.parseClassField(i);return i},J.isClassElementNameStart=function(){return this.type===_.name||this.type===_.privateId||this.type===_.num||this.type===_.string||this.type===_.bracketL||this.type.keyword},J.parseClassElementName=function(e){this.type===_.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,i,s){var n=e.key;"constructor"===e.kind?(t&&this.raise(n.start,"Constructor can't be a generator"),i&&this.raise(n.start,"Constructor can't be an async method")):e.static&&ae(e,"prototype")&&this.raise(n.start,"Classes may not have a static property named prototype");var r=e.value=this.parseMethod(t,i,s);return"get"===e.kind&&0!==r.params.length&&this.raiseRecoverable(r.start,"getter should have no params"),"set"===e.kind&&1!==r.params.length&&this.raiseRecoverable(r.start,"setter should have exactly one param"),"set"===e.kind&&"RestElement"===r.params[0].type&&this.raiseRecoverable(r.params[0].start,"Setter cannot use rest params"),this.finishNode(e,"MethodDefinition")},J.parseClassField=function(e){return ae(e,"constructor")?this.raise(e.key.start,"Classes can't have a field named 'constructor'"):e.static&&ae(e,"prototype")&&this.raise(e.key.start,"Classes can't have a static field named 'prototype'"),this.eat(_.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!==_.braceR;){var i=this.parseStatement(null);e.body.push(i)}return this.next(),this.exitScope(),this.labels=t,this.finishNode(e,"StaticBlock")},J.parseClassId=function(e,t){this.type===_.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(_._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,i=e.used;if(this.options.checkPrivateFields)for(var s=this.privateNameStack.length,n=0===s?null:this.privateNameStack[s-1],r=0;r<i.length;++r){var a=i[r];D(t,a.name)||(n?n.used.push(a):this.raiseRecoverable(a.start,"Private field '#"+a.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!==_.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(_.star))return this.parseExportAllDeclaration(e,t);if(this.eat(_._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!==_.string&&this.unexpected(),e.source=this.parseExprAtom(),this.options.ecmaVersion>=16&&(e.attributes=this.parseWithClause());else{for(var i=0,s=e.specifiers;i<s.length;i+=1){var n=s[i];this.checkUnreserved(n.local),this.checkLocalExport(n.local),"Literal"===n.local.type&&this.raise(n.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===_._function||(e=this.isAsyncFunction())){var t=this.startNode();return this.next(),e&&this.next(),this.parseFunction(t,4|se,!1,e)}if(this.type===_._class){var i=this.startNode();return this.parseClass(i,"nullableID")}var s=this.parseMaybeAssign();return this.semicolon(),s},J.checkExport=function(e,t,i){e&&("string"!=typeof t&&(t="Identifier"===t.type?t.name:t.value),D(e,t)&&this.raiseRecoverable(i,"Duplicate export '"+t+"'"),e[t]=!0)},J.checkPatternExport=function(e,t){var i=t.type;if("Identifier"===i)this.checkExport(e,t,t.start);else if("ObjectPattern"===i)for(var s=0,n=t.properties;s<n.length;s+=1){var r=n[s];this.checkPatternExport(e,r)}else if("ArrayPattern"===i)for(var a=0,o=t.elements;a<o.length;a+=1){var h=o[a];h&&this.checkPatternExport(e,h)}else"Property"===i?this.checkPatternExport(e,t.value):"AssignmentPattern"===i?this.checkPatternExport(e,t.left):"RestElement"===i&&this.checkPatternExport(e,t.argument)},J.checkVariableExport=function(e,t){if(e)for(var i=0,s=t;i<s.length;i+=1){var n=s[i];this.checkPatternExport(e,n.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=[],i=!0;for(this.expect(_.braceL);!this.eat(_.braceR);){if(i)i=!1;else if(this.expect(_.comma),this.afterTrailingComma(_.braceR))break;t.push(this.parseExportSpecifier(e))}return t},J.parseImport=function(e){return this.next(),this.type===_.string?(e.specifiers=ie,e.source=this.parseExprAtom()):(e.specifiers=this.parseImportSpecifiers(),this.expectContextual("from"),e.source=this.type===_.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===_.name&&(e.push(this.parseImportDefaultSpecifier()),!this.eat(_.comma)))return e;if(this.type===_.star)return e.push(this.parseImportNamespaceSpecifier()),e;for(this.expect(_.braceL);!this.eat(_.braceR);){if(t)t=!1;else if(this.expect(_.comma),this.afterTrailingComma(_.braceR))break;e.push(this.parseImportSpecifier())}return e},J.parseWithClause=function(){var e=[];if(!this.eat(_._with))return e;this.expect(_.braceL);for(var t={},i=!0;!this.eat(_.braceR);){if(i)i=!1;else if(this.expect(_.comma),this.afterTrailingComma(_.braceR))break;var s=this.parseImportAttribute(),n="Identifier"===s.key.type?s.key.name:s.key.value;D(t,n)&&this.raiseRecoverable(s.key.start,"Duplicate attribute key '"+n+"'"),t[n]=!0,e.push(s)}return e},J.parseImportAttribute=function(){var e=this.startNode();return e.key=this.type===_.string?this.parseExprAtom():this.parseIdent("never"!==this.options.allowReserved),this.expect(_.colon),this.type!==_.string&&this.unexpected(),e.value=this.parseExprAtom(),this.finishNode(e,"ImportAttribute")},J.parseModuleExportName=function(){if(this.options.ecmaVersion>=13&&this.type===_.string){var e=this.parseLiteral(this.value);return F.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 oe=K.prototype;oe.toAssignable=function(e,t,i){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",i&&this.checkPatternErrors(i,!0);for(var s=0,n=e.properties;s<n.length;s+=1){var r=n[s];this.toAssignable(r,t),"RestElement"!==r.type||"ArrayPattern"!==r.argument.type&&"ObjectPattern"!==r.argument.type||this.raise(r.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",i&&this.checkPatternErrors(i,!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,i);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 i&&this.checkPatternErrors(i,!0);return e},oe.toAssignableList=function(e,t){for(var i=e.length,s=0;s<i;s++){var n=e[s];n&&this.toAssignable(n,t)}if(i){var r=e[i-1];6===this.options.ecmaVersion&&t&&r&&"RestElement"===r.type&&"Identifier"!==r.argument.type&&this.unexpected(r.argument.start)}return e},oe.parseSpread=function(e){var t=this.startNode();return this.next(),t.argument=this.parseMaybeAssign(!1,e),this.finishNode(t,"SpreadElement")},oe.parseRestBinding=function(){var e=this.startNode();return this.next(),6===this.options.ecmaVersion&&this.type!==_.name&&this.unexpected(),e.argument=this.parseBindingAtom(),this.finishNode(e,"RestElement")},oe.parseBindingAtom=function(){if(this.options.ecmaVersion>=6)switch(this.type){case _.bracketL:var e=this.startNode();return this.next(),e.elements=this.parseBindingList(_.bracketR,!0,!0),this.finishNode(e,"ArrayPattern");case _.braceL:return this.parseObj(!0)}return this.parseIdent()},oe.parseBindingList=function(e,t,i,s){for(var n=[],r=!0;!this.eat(e);)if(r?r=!1:this.expect(_.comma),t&&this.type===_.comma)n.push(null);else{if(i&&this.afterTrailingComma(e))break;if(this.type===_.ellipsis){var a=this.parseRestBinding();this.parseBindingListItem(a),n.push(a),this.type===_.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.expect(e);break}n.push(this.parseAssignableListItem(s))}return n},oe.parseAssignableListItem=function(e){var t=this.parseMaybeDefault(this.start,this.startLoc);return this.parseBindingListItem(t),t},oe.parseBindingListItem=function(e){return e},oe.parseMaybeDefault=function(e,t,i){if(i=i||this.parseBindingAtom(),this.options.ecmaVersion<6||!this.eat(_.eq))return i;var s=this.startNodeAt(e,t);return s.left=i,s.right=this.parseMaybeAssign(),this.finishNode(s,"AssignmentPattern")},oe.checkLValSimple=function(e,t,i){void 0===t&&(t=0);var s=0!==t;switch(e.type){case"Identifier":this.strict&&this.reservedWordsStrictBind.test(e.name)&&this.raiseRecoverable(e.start,(s?"Binding ":"Assigning to ")+e.name+" in strict mode"),s&&(2===t&&"let"===e.name&&this.raiseRecoverable(e.start,"let is disallowed as a lexically bound name"),i&&(D(i,e.name)&&this.raiseRecoverable(e.start,"Argument name clash"),i[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":s&&this.raiseRecoverable(e.start,"Binding member expression");break;case"ParenthesizedExpression":return s&&this.raiseRecoverable(e.start,"Binding parenthesized expression"),this.checkLValSimple(e.expression,t,i);default:this.raise(e.start,(s?"Binding":"Assigning to")+" rvalue")}},oe.checkLValPattern=function(e,t,i){switch(void 0===t&&(t=0),e.type){case"ObjectPattern":for(var s=0,n=e.properties;s<n.length;s+=1){var r=n[s];this.checkLValInnerPattern(r,t,i)}break;case"ArrayPattern":for(var a=0,o=e.elements;a<o.length;a+=1){var h=o[a];h&&this.checkLValInnerPattern(h,t,i)}break;default:this.checkLValSimple(e,t,i)}},oe.checkLValInnerPattern=function(e,t,i){switch(void 0===t&&(t=0),e.type){case"Property":this.checkLValInnerPattern(e.value,t,i);break;case"AssignmentPattern":this.checkLValPattern(e.left,t,i);break;case"RestElement":this.checkLValPattern(e.argument,t,i);break;default:this.checkLValPattern(e,t,i)}};var he=function(e,t,i,s,n){this.token=e,this.isExpr=!!t,this.preserveSpace=!!i,this.override=s,this.generator=!!n},pe={b_stat:new he("{",!1),b_expr:new he("{",!0),b_tmpl:new he("${",!1),p_stat:new he("(",!1),p_expr:new he("(",!0),q_tmpl:new he("`",!0,!0,function(e){return e.tryReadTemplateToken()}),f_stat:new he("function",!1),f_expr:new he("function",!0),f_expr_gen:new he("function",!0,!1,null,!0),f_gen:new he("function",!1,!1,null,!0)},ce=K.prototype;ce.initialContext=function(){return[pe.b_stat]},ce.curContext=function(){return this.context[this.context.length-1]},ce.braceIsBlock=function(e){var t=this.curContext();return t===pe.f_expr||t===pe.f_stat||(e!==_.colon||t!==pe.b_stat&&t!==pe.b_expr?e===_._return||e===_.name&&this.exprAllowed?S.test(this.input.slice(this.lastTokEnd,this.start)):e===_._else||e===_.semi||e===_.eof||e===_.parenR||e===_.arrow||(e===_.braceL?t===pe.b_stat:e!==_._var&&e!==_._const&&e!==_.name&&!this.exprAllowed):!t.isExpr)},ce.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},ce.updateContext=function(e){var t,i=this.type;i.keyword&&e===_.dot?this.exprAllowed=!1:(t=i.updateContext)?t.call(this,e):this.exprAllowed=i.beforeExpr},ce.overrideContext=function(e){this.curContext()!==e&&(this.context[this.context.length-1]=e)},_.parenR.updateContext=_.braceR.updateContext=function(){if(1!==this.context.length){var e=this.context.pop();e===pe.b_stat&&"function"===this.curContext().token&&(e=this.context.pop()),this.exprAllowed=!e.isExpr}else this.exprAllowed=!0},_.braceL.updateContext=function(e){this.context.push(this.braceIsBlock(e)?pe.b_stat:pe.b_expr),this.exprAllowed=!0},_.dollarBraceL.updateContext=function(){this.context.push(pe.b_tmpl),this.exprAllowed=!0},_.parenL.updateContext=function(e){var t=e===_._if||e===_._for||e===_._with||e===_._while;this.context.push(t?pe.p_stat:pe.p_expr),this.exprAllowed=!0},_.incDec.updateContext=function(){},_._function.updateContext=_._class.updateContext=function(e){!e.beforeExpr||e===_._else||e===_.semi&&this.curContext()!==pe.p_stat||e===_._return&&S.test(this.input.slice(this.lastTokEnd,this.start))||(e===_.colon||e===_.braceL)&&this.curContext()===pe.b_stat?this.context.push(pe.f_stat):this.context.push(pe.f_expr),this.exprAllowed=!1},_.colon.updateContext=function(){"function"===this.curContext().token&&this.context.pop(),this.exprAllowed=!0},_.backQuote.updateContext=function(){this.curContext()===pe.q_tmpl?this.context.pop():this.context.push(pe.q_tmpl),this.exprAllowed=!1},_.star.updateContext=function(e){if(e===_._function){var t=this.context.length-1;this.context[t]===pe.f_expr?this.context[t]=pe.f_expr_gen:this.context[t]=pe.f_gen}this.exprAllowed=!0},_.name.updateContext=function(e){var t=!1;this.options.ecmaVersion>=6&&e!==_.dot&&("of"===this.value&&!this.exprAllowed||"yield"===this.value&&this.inGeneratorContext())&&(t=!0),this.exprAllowed=t};var ue=K.prototype;function de(e){return"Identifier"===e.type||"ParenthesizedExpression"===e.type&&de(e.expression)}function le(e){return"MemberExpression"===e.type&&"PrivateIdentifier"===e.property.type||"ChainExpression"===e.type&&le(e.expression)||"ParenthesizedExpression"===e.type&&le(e.expression)}ue.checkPropClash=function(e,t,i){if(!(this.options.ecmaVersion>=9&&"SpreadElement"===e.type||this.options.ecmaVersion>=6&&(e.computed||e.method||e.shorthand))){var s,n=e.key;switch(n.type){case"Identifier":s=n.name;break;case"Literal":s=String(n.value);break;default:return}var r=e.kind;if(this.options.ecmaVersion>=6)"__proto__"===s&&"init"===r&&(t.proto&&(i?i.doubleProto<0&&(i.doubleProto=n.start):this.raiseRecoverable(n.start,"Redefinition of __proto__ property")),t.proto=!0);else{var a=t[s="$"+s];if(a)("init"===r?this.strict&&a.init||a.get||a.set:a.init||a[r])&&this.raiseRecoverable(n.start,"Redefinition of property");else a=t[s]={init:!1,get:!1,set:!1};a[r]=!0}}},ue.parseExpression=function(e,t){var i=this.start,s=this.startLoc,n=this.parseMaybeAssign(e,t);if(this.type===_.comma){var r=this.startNodeAt(i,s);for(r.expressions=[n];this.eat(_.comma);)r.expressions.push(this.parseMaybeAssign(e,t));return this.finishNode(r,"SequenceExpression")}return n},ue.parseMaybeAssign=function(e,t,i){if(this.isContextual("yield")){if(this.inGenerator)return this.parseYield(e);this.exprAllowed=!1}var s=!1,n=-1,r=-1,a=-1;t?(n=t.parenthesizedAssign,r=t.trailingComma,a=t.doubleProto,t.parenthesizedAssign=t.trailingComma=-1):(t=new Y,s=!0);var o=this.start,h=this.startLoc;this.type!==_.parenL&&this.type!==_.name||(this.potentialArrowAt=this.start,this.potentialArrowInForAwait="await"===e);var p=this.parseMaybeConditional(e,t);if(i&&(p=i.call(this,p,o,h)),this.type.isAssign){var c=this.startNodeAt(o,h);return c.operator=this.value,this.type===_.eq&&(p=this.toAssignable(p,!1,t)),s||(t.parenthesizedAssign=t.trailingComma=t.doubleProto=-1),t.shorthandAssign>=p.start&&(t.shorthandAssign=-1),this.type===_.eq?this.checkLValPattern(p):this.checkLValSimple(p),c.left=p,this.next(),c.right=this.parseMaybeAssign(e),a>-1&&(t.doubleProto=a),this.finishNode(c,"AssignmentExpression")}return s&&this.checkExpressionErrors(t,!0),n>-1&&(t.parenthesizedAssign=n),r>-1&&(t.trailingComma=r),p},ue.parseMaybeConditional=function(e,t){var i=this.start,s=this.startLoc,n=this.parseExprOps(e,t);if(this.checkExpressionErrors(t))return n;if(this.eat(_.question)){var r=this.startNodeAt(i,s);return r.test=n,r.consequent=this.parseMaybeAssign(),this.expect(_.colon),r.alternate=this.parseMaybeAssign(e),this.finishNode(r,"ConditionalExpression")}return n},ue.parseExprOps=function(e,t){var i=this.start,s=this.startLoc,n=this.parseMaybeUnary(t,!1,!1,e);return this.checkExpressionErrors(t)||n.start===i&&"ArrowFunctionExpression"===n.type?n:this.parseExprOp(n,i,s,-1,e)},ue.parseExprOp=function(e,t,i,s,n){var r=this.type.binop;if(null!=r&&(!n||this.type!==_._in)&&r>s){var a=this.type===_.logicalOR||this.type===_.logicalAND,o=this.type===_.coalesce;o&&(r=_.logicalAND.binop);var h=this.value;this.next();var p=this.start,c=this.startLoc,u=this.parseExprOp(this.parseMaybeUnary(null,!1,!1,n),p,c,r,n),d=this.buildBinary(t,i,e,u,h,a||o);return(a&&this.type===_.coalesce||o&&(this.type===_.logicalOR||this.type===_.logicalAND))&&this.raiseRecoverable(this.start,"Logical expressions and coalesce expressions cannot be mixed. Wrap either by parentheses"),this.parseExprOp(d,t,i,s,n)}return e},ue.buildBinary=function(e,t,i,s,n,r){"PrivateIdentifier"===s.type&&this.raise(s.start,"Private identifier can only be left side of binary expression");var a=this.startNodeAt(e,t);return a.left=i,a.operator=n,a.right=s,this.finishNode(a,r?"LogicalExpression":"BinaryExpression")},ue.parseMaybeUnary=function(e,t,i,s){var n,r=this.start,a=this.startLoc;if(this.isContextual("await")&&this.canAwait)n=this.parseAwait(s),t=!0;else if(this.type.prefix){var o=this.startNode(),h=this.type===_.incDec;o.operator=this.value,o.prefix=!0,this.next(),o.argument=this.parseMaybeUnary(null,!0,h,s),this.checkExpressionErrors(e,!0),h?this.checkLValSimple(o.argument):this.strict&&"delete"===o.operator&&de(o.argument)?this.raiseRecoverable(o.start,"Deleting local variable in strict mode"):"delete"===o.operator&&le(o.argument)?this.raiseRecoverable(o.start,"Private fields can not be deleted"):t=!0,n=this.finishNode(o,h?"UpdateExpression":"UnaryExpression")}else if(t||this.type!==_.privateId){if(n=this.parseExprSubscripts(e,s),this.checkExpressionErrors(e))return n;for(;this.type.postfix&&!this.canInsertSemicolon();){var p=this.startNodeAt(r,a);p.operator=this.value,p.prefix=!1,p.argument=n,this.checkLValSimple(n),this.next(),n=this.finishNode(p,"UpdateExpression")}}else(s||0===this.privateNameStack.length)&&this.options.checkPrivateFields&&this.unexpected(),n=this.parsePrivateIdent(),this.type!==_._in&&this.unexpected();return i||!this.eat(_.starstar)?n:t?void this.unexpected(this.lastTokStart):this.buildBinary(r,a,n,this.parseMaybeUnary(null,!1,!1,s),"**",!1)},ue.parseExprSubscripts=function(e,t){var i=this.start,s=this.startLoc,n=this.parseExprAtom(e,t);if("ArrowFunctionExpression"===n.type&&")"!==this.input.slice(this.lastTokStart,this.lastTokEnd))return n;var r=this.parseSubscripts(n,i,s,!1,t);return e&&"MemberExpression"===r.type&&(e.parenthesizedAssign>=r.start&&(e.parenthesizedAssign=-1),e.parenthesizedBind>=r.start&&(e.parenthesizedBind=-1),e.trailingComma>=r.start&&(e.trailingComma=-1)),r},ue.parseSubscripts=function(e,t,i,s,n){for(var r=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,a=!1;;){var o=this.parseSubscript(e,t,i,s,r,a,n);if(o.optional&&(a=!0),o===e||"ArrowFunctionExpression"===o.type){if(a){var h=this.startNodeAt(t,i);h.expression=o,o=this.finishNode(h,"ChainExpression")}return o}e=o}},ue.shouldParseAsyncArrow=function(){return!this.canInsertSemicolon()&&this.eat(_.arrow)},ue.parseSubscriptAsyncArrow=function(e,t,i,s){return this.parseArrowExpression(this.startNodeAt(e,t),i,!0,s)},ue.parseSubscript=function(e,t,i,s,n,r,a){var o=this.options.ecmaVersion>=11,h=o&&this.eat(_.questionDot);s&&h&&this.raise(this.lastTokStart,"Optional chaining cannot appear in the callee of new expressions");var p=this.eat(_.bracketL);if(p||h&&this.type!==_.parenL&&this.type!==_.backQuote||this.eat(_.dot)){var c=this.startNodeAt(t,i);c.object=e,p?(c.property=this.parseExpression(),this.expect(_.bracketR)):this.type===_.privateId&&"Super"!==e.type?c.property=this.parsePrivateIdent():c.property=this.parseIdent("never"!==this.options.allowReserved),c.computed=!!p,o&&(c.optional=h),e=this.finishNode(c,"MemberExpression")}else if(!s&&this.eat(_.parenL)){var u=new Y,d=this.yieldPos,l=this.awaitPos,f=this.awaitIdentPos;this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0;var m=this.parseExprList(_.parenR,this.options.ecmaVersion>=8,!1,u);if(n&&!h&&this.shouldParseAsyncArrow())return this.checkPatternErrors(u,!1),this.checkYieldAwaitInDefaultParams(),this.awaitIdentPos>0&&this.raise(this.awaitIdentPos,"Cannot use 'await' as identifier inside an async function"),this.yieldPos=d,this.awaitPos=l,this.awaitIdentPos=f,this.parseSubscriptAsyncArrow(t,i,m,a);this.checkExpressionErrors(u,!0),this.yieldPos=d||this.yieldPos,this.awaitPos=l||this.awaitPos,this.awaitIdentPos=f||this.awaitIdentPos;var g=this.startNodeAt(t,i);g.callee=e,g.arguments=m,o&&(g.optional=h),e=this.finishNode(g,"CallExpression")}else if(this.type===_.backQuote){(h||r)&&this.raise(this.start,"Optional chaining cannot appear in the tag of tagged template expressions");var v=this.startNodeAt(t,i);v.tag=e,v.quasi=this.parseTemplate({isTagged:!0}),e=this.finishNode(v,"TaggedTemplateExpression")}return e},ue.parseExprAtom=function(e,t,i){this.type===_.slash&&this.readRegexp();var s,n=this.potentialArrowAt===this.start;switch(this.type){case _._super:return this.allowSuper||this.raise(this.start,"'super' keyword outside a method"),s=this.startNode(),this.next(),this.type!==_.parenL||this.allowDirectSuper||this.raise(s.start,"super() call outside constructor of a subclass"),this.type!==_.dot&&this.type!==_.bracketL&&this.type!==_.parenL&&this.unexpected(),this.finishNode(s,"Super");case _._this:return s=this.startNode(),this.next(),this.finishNode(s,"ThisExpression");case _.name:var r=this.start,a=this.startLoc,o=this.containsEsc,h=this.parseIdent(!1);if(this.options.ecmaVersion>=8&&!o&&"async"===h.name&&!this.canInsertSemicolon()&&this.eat(_._function))return this.overrideContext(pe.f_expr),this.parseFunction(this.startNodeAt(r,a),0,!1,!0,t);if(n&&!this.canInsertSemicolon()){if(this.eat(_.arrow))return this.parseArrowExpression(this.startNodeAt(r,a),[h],!1,t);if(this.options.ecmaVersion>=8&&"async"===h.name&&this.type===_.name&&!o&&(!this.potentialArrowInForAwait||"of"!==this.value||this.containsEsc))return h=this.parseIdent(!1),!this.canInsertSemicolon()&&this.eat(_.arrow)||this.unexpected(),this.parseArrowExpression(this.startNodeAt(r,a),[h],!0,t)}return h;case _.regexp:var p=this.value;return(s=this.parseLiteral(p.value)).regex={pattern:p.pattern,flags:p.flags},s;case _.num:case _.string:return this.parseLiteral(this.value);case _._null:case _._true:case _._false:return(s=this.startNode()).value=this.type===_._null?null:this.type===_._true,s.raw=this.type.keyword,this.next(),this.finishNode(s,"Literal");case _.parenL:var c=this.start,u=this.parseParenAndDistinguishExpression(n,t);return e&&(e.parenthesizedAssign<0&&!this.isSimpleAssignTarget(u)&&(e.parenthesizedAssign=c),e.parenthesizedBind<0&&(e.parenthesizedBind=c)),u;case _.bracketL:return s=this.startNode(),this.next(),s.elements=this.parseExprList(_.bracketR,!0,!0,e),this.finishNode(s,"ArrayExpression");case _.braceL:return this.overrideContext(pe.b_expr),this.parseObj(!1,e);case _._function:return s=this.startNode(),this.next(),this.parseFunction(s,0);case _._class:return this.parseClass(this.startNode(),!1);case _._new:return this.parseNew();case _.backQuote:return this.parseTemplate();case _._import:return this.options.ecmaVersion>=11?this.parseExprImport(i):this.unexpected();default:return this.parseExprAtomDefault()}},ue.parseExprAtomDefault=function(){this.unexpected()},ue.parseExprImport=function(e){var t=this.startNode();if(this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword import"),this.next(),this.type===_.parenL&&!e)return this.parseDynamicImport(t);if(this.type===_.dot){var i=this.startNodeAt(t.start,t.loc&&t.loc.start);return i.name="import",t.meta=this.finishNode(i,"Identifier"),this.parseImportMeta(t)}this.unexpected()},ue.parseDynamicImport=function(e){if(this.next(),e.source=this.parseMaybeAssign(),this.options.ecmaVersion>=16)this.eat(_.parenR)?e.options=null:(this.expect(_.comma),this.afterTrailingComma(_.parenR)?e.options=null:(e.options=this.parseMaybeAssign(),this.eat(_.parenR)||(this.expect(_.comma),this.afterTrailingComma(_.parenR)||this.unexpected())));else if(!this.eat(_.parenR)){var t=this.start;this.eat(_.comma)&&this.eat(_.parenR)?this.raiseRecoverable(t,"Trailing comma is not allowed in import()"):this.unexpected(t)}return this.finishNode(e,"ImportExpression")},ue.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")},ue.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=null!=t.value?t.value.toString():t.raw.slice(0,-1).replace(/_/g,"")),this.next(),this.finishNode(t,"Literal")},ue.parseParenExpression=function(){this.expect(_.parenL);var e=this.parseExpression();return this.expect(_.parenR),e},ue.shouldParseArrow=function(e){return!this.canInsertSemicolon()},ue.parseParenAndDistinguishExpression=function(e,t){var i,s=this.start,n=this.startLoc,r=this.options.ecmaVersion>=8;if(this.options.ecmaVersion>=6){this.next();var a,o=this.start,h=this.startLoc,p=[],c=!0,u=!1,d=new Y,l=this.yieldPos,f=this.awaitPos;for(this.yieldPos=0,this.awaitPos=0;this.type!==_.parenR;){if(c?c=!1:this.expect(_.comma),r&&this.afterTrailingComma(_.parenR,!0)){u=!0;break}if(this.type===_.ellipsis){a=this.start,p.push(this.parseParenItem(this.parseRestBinding())),this.type===_.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element");break}p.push(this.parseMaybeAssign(!1,d,this.parseParenItem))}var m=this.lastTokEnd,g=this.lastTokEndLoc;if(this.expect(_.parenR),e&&this.shouldParseArrow(p)&&this.eat(_.arrow))return this.checkPatternErrors(d,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=l,this.awaitPos=f,this.parseParenArrowList(s,n,p,t);p.length&&!u||this.unexpected(this.lastTokStart),a&&this.unexpected(a),this.checkExpressionErrors(d,!0),this.yieldPos=l||this.yieldPos,this.awaitPos=f||this.awaitPos,p.length>1?((i=this.startNodeAt(o,h)).expressions=p,this.finishNodeAt(i,"SequenceExpression",m,g)):i=p[0]}else i=this.parseParenExpression();if(this.options.preserveParens){var v=this.startNodeAt(s,n);return v.expression=i,this.finishNode(v,"ParenthesizedExpression")}return i},ue.parseParenItem=function(e){return e},ue.parseParenArrowList=function(e,t,i,s){return this.parseArrowExpression(this.startNodeAt(e,t),i,!1,s)};var fe=[];ue.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===_.dot){var t=this.startNodeAt(e.start,e.loc&&e.loc.start);t.name="new",e.meta=this.finishNode(t,"Identifier"),this.next();var i=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'"),i&&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 s=this.start,n=this.startLoc;return e.callee=this.parseSubscripts(this.parseExprAtom(null,!1,!0),s,n,!0,!1),this.eat(_.parenL)?e.arguments=this.parseExprList(_.parenR,this.options.ecmaVersion>=8,!1):e.arguments=fe,this.finishNode(e,"NewExpression")},ue.parseTemplateElement=function(e){var t=e.isTagged,i=this.startNode();return this.type===_.invalidTemplate?(t||this.raiseRecoverable(this.start,"Bad escape sequence in untagged template literal"),i.value={raw:this.value.replace(/\r\n?/g,"\n"),cooked:null}):i.value={raw:this.input.slice(this.start,this.end).replace(/\r\n?/g,"\n"),cooked:this.value},this.next(),i.tail=this.type===_.backQuote,this.finishNode(i,"TemplateElement")},ue.parseTemplate=function(e){void 0===e&&(e={});var t=e.isTagged;void 0===t&&(t=!1);var i=this.startNode();this.next(),i.expressions=[];var s=this.parseTemplateElement({isTagged:t});for(i.quasis=[s];!s.tail;)this.type===_.eof&&this.raise(this.pos,"Unterminated template literal"),this.expect(_.dollarBraceL),i.expressions.push(this.parseExpression()),this.expect(_.braceR),i.quasis.push(s=this.parseTemplateElement({isTagged:t}));return this.next(),this.finishNode(i,"TemplateLiteral")},ue.isAsyncProp=function(e){return!e.computed&&"Identifier"===e.key.type&&"async"===e.key.name&&(this.type===_.name||this.type===_.num||this.type===_.string||this.type===_.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===_.star)&&!S.test(this.input.slice(this.lastTokEnd,this.start))},ue.parseObj=function(e,t){var i=this.startNode(),s=!0,n={};for(i.properties=[],this.next();!this.eat(_.braceR);){if(s)s=!1;else if(this.expect(_.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(_.braceR))break;var r=this.parseProperty(e,t);e||this.checkPropClash(r,n,t),i.properties.push(r)}return this.finishNode(i,e?"ObjectPattern":"ObjectExpression")},ue.parseProperty=function(e,t){var i,s,n,r,a=this.startNode();if(this.options.ecmaVersion>=9&&this.eat(_.ellipsis))return e?(a.argument=this.parseIdent(!1),this.type===_.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.finishNode(a,"RestElement")):(a.argument=this.parseMaybeAssign(!1,t),this.type===_.comma&&t&&t.trailingComma<0&&(t.trailingComma=this.start),this.finishNode(a,"SpreadElement"));this.options.ecmaVersion>=6&&(a.method=!1,a.shorthand=!1,(e||t)&&(n=this.start,r=this.startLoc),e||(i=this.eat(_.star)));var o=this.containsEsc;return this.parsePropertyName(a),!e&&!o&&this.options.ecmaVersion>=8&&!i&&this.isAsyncProp(a)?(s=!0,i=this.options.ecmaVersion>=9&&this.eat(_.star),this.parsePropertyName(a)):s=!1,this.parsePropertyValue(a,e,i,s,n,r,t,o),this.finishNode(a,"Property")},ue.parseGetterSetter=function(e){var t=e.key.name;this.parsePropertyName(e),e.value=this.parseMethod(!1),e.kind=t;var i="get"===e.kind?0:1;if(e.value.params.length!==i){var s=e.value.start;"get"===e.kind?this.raiseRecoverable(s,"getter should have no params"):this.raiseRecoverable(s,"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")},ue.parsePropertyValue=function(e,t,i,s,n,r,a,o){(i||s)&&this.type===_.colon&&this.unexpected(),this.eat(_.colon)?(e.value=t?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,a),e.kind="init"):this.options.ecmaVersion>=6&&this.type===_.parenL?(t&&this.unexpected(),e.method=!0,e.value=this.parseMethod(i,s),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===_.comma||this.type===_.braceR||this.type===_.eq?this.options.ecmaVersion>=6&&!e.computed&&"Identifier"===e.key.type?((i||s)&&this.unexpected(),this.checkUnreserved(e.key),"await"!==e.key.name||this.awaitIdentPos||(this.awaitIdentPos=n),t?e.value=this.parseMaybeDefault(n,r,this.copyNode(e.key)):this.type===_.eq&&a?(a.shorthandAssign<0&&(a.shorthandAssign=this.start),e.value=this.parseMaybeDefault(n,r,this.copyNode(e.key))):e.value=this.copyNode(e.key),e.kind="init",e.shorthand=!0):this.unexpected():((i||s)&&this.unexpected(),this.parseGetterSetter(e))},ue.parsePropertyName=function(e){if(this.options.ecmaVersion>=6){if(this.eat(_.bracketL))return e.computed=!0,e.key=this.parseMaybeAssign(),this.expect(_.bracketR),e.key;e.computed=!1}return e.key=this.type===_.num||this.type===_.string?this.parseExprAtom():this.parseIdent("never"!==this.options.allowReserved)},ue.initFunction=function(e){e.id=null,this.options.ecmaVersion>=6&&(e.generator=e.expression=!1),this.options.ecmaVersion>=8&&(e.async=!1)},ue.parseMethod=function(e,t,i){var s=this.startNode(),n=this.yieldPos,r=this.awaitPos,a=this.awaitIdentPos;return this.initFunction(s),this.options.ecmaVersion>=6&&(s.generator=e),this.options.ecmaVersion>=8&&(s.async=!!t),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(64|G(t,s.generator)|(i?128:0)),this.expect(_.parenL),s.params=this.parseBindingList(_.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(s,!1,!0,!1),this.yieldPos=n,this.awaitPos=r,this.awaitIdentPos=a,this.finishNode(s,"FunctionExpression")},ue.parseArrowExpression=function(e,t,i,s){var n=this.yieldPos,r=this.awaitPos,a=this.awaitIdentPos;return this.enterScope(16|G(i,!1)),this.initFunction(e),this.options.ecmaVersion>=8&&(e.async=!!i),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,e.params=this.toAssignableList(t,!0),this.parseFunctionBody(e,!0,!1,s),this.yieldPos=n,this.awaitPos=r,this.awaitIdentPos=a,this.finishNode(e,"ArrowFunctionExpression")},ue.parseFunctionBody=function(e,t,i,s){var n=t&&this.type!==_.braceL,r=this.strict,a=!1;if(n)e.body=this.parseMaybeAssign(s),e.expression=!0,this.checkParams(e,!1);else{var o=this.options.ecmaVersion>=7&&!this.isSimpleParamList(e.params);r&&!o||(a=this.strictDirective(this.end))&&o&&this.raiseRecoverable(e.start,"Illegal 'use strict' directive in function with non-simple parameter list");var h=this.labels;this.labels=[],a&&(this.strict=!0),this.checkParams(e,!r&&!a&&!t&&!i&&this.isSimpleParamList(e.params)),this.strict&&e.id&&this.checkLValSimple(e.id,5),e.body=this.parseBlock(!1,void 0,a&&!r),e.expression=!1,this.adaptDirectivePrologue(e.body.body),this.labels=h}this.exitScope()},ue.isSimpleParamList=function(e){for(var t=0,i=e;t<i.length;t+=1){if("Identifier"!==i[t].type)return!1}return!0},ue.checkParams=function(e,t){for(var i=Object.create(null),s=0,n=e.params;s<n.length;s+=1){var r=n[s];this.checkLValInnerPattern(r,1,t?null:i)}},ue.parseExprList=function(e,t,i,s){for(var n=[],r=!0;!this.eat(e);){if(r)r=!1;else if(this.expect(_.comma),t&&this.afterTrailingComma(e))break;var a=void 0;i&&this.type===_.comma?a=null:this.type===_.ellipsis?(a=this.parseSpread(s),s&&this.type===_.comma&&s.trailingComma<0&&(s.trailingComma=this.start)):a=this.parseMaybeAssign(!1,s),n.push(a)}return n},ue.checkUnreserved=function(e){var t=e.start,i=e.end,s=e.name;(this.inGenerator&&"yield"===s&&this.raiseRecoverable(t,"Cannot use 'yield' as identifier inside a generator"),this.inAsync&&"await"===s&&this.raiseRecoverable(t,"Cannot use 'await' as identifier inside an async function"),this.currentThisScope().flags&q||"arguments"!==s||this.raiseRecoverable(t,"Cannot use 'arguments' in class field initializer"),!this.inClassStaticBlock||"arguments"!==s&&"await"!==s||this.raise(t,"Cannot use "+s+" in class static initialization block"),this.keywords.test(s)&&this.raise(t,"Unexpected keyword '"+s+"'"),this.options.ecmaVersion<6&&-1!==this.input.slice(t,i).indexOf("\\"))||(this.strict?this.reservedWordsStrict:this.reservedWords).test(s)&&(this.inAsync||"await"!==s||this.raiseRecoverable(t,"Cannot use keyword 'await' outside an async function"),this.raiseRecoverable(t,"The keyword '"+s+"' is reserved"))},ue.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},ue.parseIdentNode=function(){var e=this.startNode();return this.type===_.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=_.name):this.unexpected(),e},ue.parsePrivateIdent=function(){var e=this.startNode();return this.type===_.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},ue.parseYield=function(e){this.yieldPos||(this.yieldPos=this.start);var t=this.startNode();return this.next(),this.type===_.semi||this.canInsertSemicolon()||this.type!==_.star&&!this.type.startsExpr?(t.delegate=!1,t.argument=null):(t.delegate=this.eat(_.star),t.argument=this.parseMaybeAssign(e)),this.finishNode(t,"YieldExpression")},ue.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 me=K.prototype;me.raise=function(e,t){var i=W(this.input,e);t+=" ("+i.line+":"+i.column+")",this.sourceFile&&(t+=" in "+this.sourceFile);var s=new SyntaxError(t);throw s.pos=e,s.loc=i,s.raisedAt=this.pos,s},me.raiseRecoverable=me.raise,me.curPosition=function(){if(this.options.locations)return new U(this.curLine,this.pos-this.lineStart)};var ge=K.prototype,ve=function(e){this.flags=e,this.var=[],this.lexical=[],this.functions=[]};ge.enterScope=function(e){this.scopeStack.push(new ve(e))},ge.exitScope=function(){this.scopeStack.pop()},ge.treatFunctionsAsVarInScope=function(e){return 2&e.flags||!this.inModule&&1&e.flags},ge.declareName=function(e,t,i){var s=!1;if(2===t){var n=this.currentScope();s=n.lexical.indexOf(e)>-1||n.functions.indexOf(e)>-1||n.var.indexOf(e)>-1,n.lexical.push(e),this.inModule&&1&n.flags&&delete this.undefinedExports[e]}else if(4===t){this.currentScope().lexical.push(e)}else if(3===t){var r=this.currentScope();s=this.treatFunctionsAsVar?r.lexical.indexOf(e)>-1:r.lexical.indexOf(e)>-1||r.var.indexOf(e)>-1,r.functions.push(e)}else for(var a=this.scopeStack.length-1;a>=0;--a){var o=this.scopeStack[a];if(o.lexical.indexOf(e)>-1&&!(32&o.flags&&o.lexical[0]===e)||!this.treatFunctionsAsVarInScope(o)&&o.functions.indexOf(e)>-1){s=!0;break}if(o.var.push(e),this.inModule&&1&o.flags&&delete this.undefinedExports[e],o.flags&q)break}s&&this.raiseRecoverable(i,"Identifier '"+e+"' has already been declared")},ge.checkLocalExport=function(e){-1===this.scopeStack[0].lexical.indexOf(e.name)&&-1===this.scopeStack[0].var.indexOf(e.name)&&(this.undefinedExports[e.name]=e)},ge.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]},ge.currentVarScope=function(){for(var e=this.scopeStack.length-1;;e--){var t=this.scopeStack[e];if(771&t.flags)return t}},ge.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 xe=function(e,t,i){this.type="",this.start=t,this.end=0,e.options.locations&&(this.loc=new B(e,i)),e.options.directSourceFile&&(this.sourceFile=e.options.directSourceFile),e.options.ranges&&(this.range=[t,0])},ye=K.prototype;function be(e,t,i,s){return e.type=t,e.end=i,this.options.locations&&(e.loc.end=s),this.options.ranges&&(e.range[1]=i),e}ye.startNode=function(){return new xe(this,this.start,this.startLoc)},ye.startNodeAt=function(e,t){return new xe(this,e,t)},ye.finishNode=function(e,t){return be.call(this,e,t,this.lastTokEnd,this.lastTokEndLoc)},ye.finishNodeAt=function(e,t,i,s){return be.call(this,e,t,i,s)},ye.copyNode=function(e){var t=new xe(this,e.start,this.startLoc);for(var i in e)t[i]=e[i];return t};var Ee="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",Ne=Ee+" Extended_Pictographic",_e=Ne+" EBase EComp EMod EPres ExtPict",Se={9:Ee,10:Ne,11:Ne,12:_e,13:_e,14:_e},we={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"},Ie="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",ke="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",Ce=ke+" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd",Ae=Ce+" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho",Ve=Ae+" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi",Pe=Ve+" Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith",Te={9:ke,10:Ce,11:Ae,12:Ve,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"},De={};function Le(e){var t=De[e]={binary:R(Se[e]+" "+Ie),binaryOfStrings:R(we[e]),nonBinary:{General_Category:R(Ie),Script:R(Te[e])}};t.nonBinary.Script_Extensions=t.nonBinary.Script,t.nonBinary.gc=t.nonBinary.General_Category,t.nonBinary.sc=t.nonBinary.Script,t.nonBinary.scx=t.nonBinary.Script_Extensions}for(var Me=0,Re=[9,10,11,12,13,14];Me<Re.length;Me+=1){Le(Re[Me])}var Oe=K.prototype,Fe=function(e,t){this.parent=e,this.base=t||this};Fe.prototype.separatedFrom=function(e){for(var t=this;t;t=t.parent)for(var i=e;i;i=i.parent)if(t.base===i.base&&t!==i)return!0;return!1},Fe.prototype.sibling=function(){return new Fe(this.parent,this.base)};var Ue=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=De[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 Be(e){return 105===e||109===e||115===e}function We(e){return 36===e||e>=40&&e<=43||46===e||63===e||e>=91&&e<=94||e>=123&&e<=125}function $e(e){return e>=65&&e<=90||e>=97&&e<=122}Ue.prototype.reset=function(e,t,i){var s=-1!==i.indexOf("v"),n=-1!==i.indexOf("u");this.start=0|e,this.source=t+"",this.flags=i,s&&this.parser.options.ecmaVersion>=15?(this.switchU=!0,this.switchV=!0,this.switchN=!0):(this.switchU=n&&this.parser.options.ecmaVersion>=6,this.switchV=!1,this.switchN=n&&this.parser.options.ecmaVersion>=9)},Ue.prototype.raise=function(e){this.parser.raiseRecoverable(this.start,"Invalid regular expression: /"+this.source+"/: "+e)},Ue.prototype.at=function(e,t){void 0===t&&(t=!1);var i=this.source,s=i.length;if(e>=s)return-1;var n=i.charCodeAt(e);if(!t&&!this.switchU||n<=55295||n>=57344||e+1>=s)return n;var r=i.charCodeAt(e+1);return r>=56320&&r<=57343?(n<<10)+r-56613888:n},Ue.prototype.nextIndex=function(e,t){void 0===t&&(t=!1);var i=this.source,s=i.length;if(e>=s)return s;var n,r=i.charCodeAt(e);return!t&&!this.switchU||r<=55295||r>=57344||e+1>=s||(n=i.charCodeAt(e+1))<56320||n>57343?e+1:e+2},Ue.prototype.current=function(e){return void 0===e&&(e=!1),this.at(this.pos,e)},Ue.prototype.lookahead=function(e){return void 0===e&&(e=!1),this.at(this.nextIndex(this.pos,e),e)},Ue.prototype.advance=function(e){void 0===e&&(e=!1),this.pos=this.nextIndex(this.pos,e)},Ue.prototype.eat=function(e,t){return void 0===t&&(t=!1),this.current(t)===e&&(this.advance(t),!0)},Ue.prototype.eatChars=function(e,t){void 0===t&&(t=!1);for(var i=this.pos,s=0,n=e;s<n.length;s+=1){var r=n[s],a=this.at(i,t);if(-1===a||a!==r)return!1;i=this.nextIndex(i,t)}return this.pos=i,!0},Oe.validateRegExpFlags=function(e){for(var t=e.validFlags,i=e.flags,s=!1,n=!1,r=0;r<i.length;r++){var a=i.charAt(r);-1===t.indexOf(a)&&this.raise(e.start,"Invalid regular expression flag"),i.indexOf(a,r+1)>-1&&this.raise(e.start,"Duplicate regular expression flag"),"u"===a&&(s=!0),"v"===a&&(n=!0)}this.options.ecmaVersion>=15&&s&&n&&this.raise(e.start,"Invalid regular expression flag")},Oe.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))},Oe.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,i=e.backReferenceNames;t<i.length;t+=1){var s=i[t];e.groupNames[s]||e.raise("Invalid named capture referenced")}},Oe.regexp_disjunction=function(e){var t=this.options.ecmaVersion>=16;for(t&&(e.branchID=new Fe(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")},Oe.regexp_alternative=function(e){for(;e.pos<e.source.length&&this.regexp_eatTerm(e););},Oe.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)},Oe.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 i=!1;if(this.options.ecmaVersion>=9&&(i=e.eat(60)),e.eat(61)||e.eat(33))return this.regexp_disjunction(e),e.eat(41)||e.raise("Unterminated group"),e.lastAssertionIsQuantifiable=!i,!0}return e.pos=t,!1},Oe.regexp_eatQuantifier=function(e,t){return void 0===t&&(t=!1),!!this.regexp_eatQuantifierPrefix(e,t)&&(e.eat(63),!0)},Oe.regexp_eatQuantifierPrefix=function(e,t){return e.eat(42)||e.eat(43)||e.eat(63)||this.regexp_eatBracedQuantifier(e,t)},Oe.regexp_eatBracedQuantifier=function(e,t){var i=e.pos;if(e.eat(123)){var s=0,n=-1;if(this.regexp_eatDecimalDigits(e)&&(s=e.lastIntValue,e.eat(44)&&this.regexp_eatDecimalDigits(e)&&(n=e.lastIntValue),e.eat(125)))return-1!==n&&n<s&&!t&&e.raise("numbers out of order in {} quantifier"),!0;e.switchU&&!t&&e.raise("Incomplete quantifier"),e.pos=i}return!1},Oe.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)},Oe.regexp_eatReverseSolidusAtomEscape=function(e){var t=e.pos;if(e.eat(92)){if(this.regexp_eatAtomEscape(e))return!0;e.pos=t}return!1},Oe.regexp_eatUncapturingGroup=function(e){var t=e.pos;if(e.eat(40)){if(e.eat(63)){if(this.options.ecmaVersion>=16){var i=this.regexp_eatModifiers(e),s=e.eat(45);if(i||s){for(var n=0;n<i.length;n++){var r=i.charAt(n);i.indexOf(r,n+1)>-1&&e.raise("Duplicate regular expression modifiers")}if(s){var a=this.regexp_eatModifiers(e);i||a||58!==e.current()||e.raise("Invalid regular expression modifiers");for(var o=0;o<a.length;o++){var h=a.charAt(o);(a.indexOf(h,o+1)>-1||i.indexOf(h)>-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},Oe.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},Oe.regexp_eatModifiers=function(e){for(var t="",i=0;-1!==(i=e.current())&&Be(i);)t+=O(i),e.advance();return t},Oe.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)},Oe.regexp_eatInvalidBracedQuantifier=function(e){return this.regexp_eatBracedQuantifier(e,!0)&&e.raise("Nothing to repeat"),!1},Oe.regexp_eatSyntaxCharacter=function(e){var t=e.current();return!!We(t)&&(e.lastIntValue=t,e.advance(),!0)},Oe.regexp_eatPatternCharacters=function(e){for(var t=e.pos,i=0;-1!==(i=e.current())&&!We(i);)e.advance();return e.pos!==t},Oe.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)},Oe.regexp_groupSpecifier=function(e){if(e.eat(63)){this.regexp_eatGroupName(e)||e.raise("Invalid group");var t=this.options.ecmaVersion>=16,i=e.groupNames[e.lastStringValue];if(i)if(t)for(var s=0,n=i;s<n.length;s+=1){n[s].separatedFrom(e.branchID)||e.raise("Duplicate capture group name")}else e.raise("Duplicate capture group name");t?(i||(e.groupNames[e.lastStringValue]=[])).push(e.branchID):e.groupNames[e.lastStringValue]=!0}},Oe.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},Oe.regexp_eatRegExpIdentifierName=function(e){if(e.lastStringValue="",this.regexp_eatRegExpIdentifierStart(e)){for(e.lastStringValue+=O(e.lastIntValue);this.regexp_eatRegExpIdentifierPart(e);)e.lastStringValue+=O(e.lastIntValue);return!0}return!1},Oe.regexp_eatRegExpIdentifierStart=function(e){var t=e.pos,i=this.options.ecmaVersion>=11,s=e.current(i);return e.advance(i),92===s&&this.regexp_eatRegExpUnicodeEscapeSequence(e,i)&&(s=e.lastIntValue),function(e){return m(e,!0)||36===e||95===e}(s)?(e.lastIntValue=s,!0):(e.pos=t,!1)},Oe.regexp_eatRegExpIdentifierPart=function(e){var t=e.pos,i=this.options.ecmaVersion>=11,s=e.current(i);return e.advance(i),92===s&&this.regexp_eatRegExpUnicodeEscapeSequence(e,i)&&(s=e.lastIntValue),function(e){return g(e,!0)||36===e||95===e||8204===e||8205===e}(s)?(e.lastIntValue=s,!0):(e.pos=t,!1)},Oe.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)},Oe.regexp_eatBackReference=function(e){var t=e.pos;if(this.regexp_eatDecimalEscape(e)){var i=e.lastIntValue;if(e.switchU)return i>e.maxBackReference&&(e.maxBackReference=i),!0;if(i<=e.numCapturingParens)return!0;e.pos=t}return!1},Oe.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},Oe.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)},Oe.regexp_eatCControlLetter=function(e){var t=e.pos;if(e.eat(99)){if(this.regexp_eatControlLetter(e))return!0;e.pos=t}return!1},Oe.regexp_eatZero=function(e){return 48===e.current()&&!He(e.lookahead())&&(e.lastIntValue=0,e.advance(),!0)},Oe.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)},Oe.regexp_eatControlLetter=function(e){var t=e.current();return!!$e(t)&&(e.lastIntValue=t%32,e.advance(),!0)},Oe.regexp_eatRegExpUnicodeEscapeSequence=function(e,t){void 0===t&&(t=!1);var i,s=e.pos,n=t||e.switchU;if(e.eat(117)){if(this.regexp_eatFixedHexDigits(e,4)){var r=e.lastIntValue;if(n&&r>=55296&&r<=56319){var a=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*(r-55296)+(o-56320)+65536,!0}e.pos=a,e.lastIntValue=r}return!0}if(n&&e.eat(123)&&this.regexp_eatHexDigits(e)&&e.eat(125)&&((i=e.lastIntValue)>=0&&i<=1114111))return!0;n&&e.raise("Invalid unicode escape"),e.pos=s}return!1},Oe.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)},Oe.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};function je(e){return $e(e)||95===e}function ze(e){return je(e)||He(e)}function He(e){return e>=48&&e<=57}function qe(e){return e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102}function Ge(e){return e>=65&&e<=70?e-65+10:e>=97&&e<=102?e-97+10:e-48}function Ke(e){return e>=48&&e<=55}Oe.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 i=!1;if(e.switchU&&this.options.ecmaVersion>=9&&((i=80===t)||112===t)){var s;if(e.lastIntValue=-1,e.advance(),e.eat(123)&&(s=this.regexp_eatUnicodePropertyValueExpression(e))&&e.eat(125))return i&&2===s&&e.raise("Invalid property name"),s;e.raise("Invalid property name")}return 0},Oe.regexp_eatUnicodePropertyValueExpression=function(e){var t=e.pos;if(this.regexp_eatUnicodePropertyName(e)&&e.eat(61)){var i=e.lastStringValue;if(this.regexp_eatUnicodePropertyValue(e)){var s=e.lastStringValue;return this.regexp_validateUnicodePropertyNameAndValue(e,i,s),1}}if(e.pos=t,this.regexp_eatLoneUnicodePropertyNameOrValue(e)){var n=e.lastStringValue;return this.regexp_validateUnicodePropertyNameOrValue(e,n)}return 0},Oe.regexp_validateUnicodePropertyNameAndValue=function(e,t,i){D(e.unicodeProperties.nonBinary,t)||e.raise("Invalid property name"),e.unicodeProperties.nonBinary[t].test(i)||e.raise("Invalid property value")},Oe.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")},Oe.regexp_eatUnicodePropertyName=function(e){var t=0;for(e.lastStringValue="";je(t=e.current());)e.lastStringValue+=O(t),e.advance();return""!==e.lastStringValue},Oe.regexp_eatUnicodePropertyValue=function(e){var t=0;for(e.lastStringValue="";ze(t=e.current());)e.lastStringValue+=O(t),e.advance();return""!==e.lastStringValue},Oe.regexp_eatLoneUnicodePropertyNameOrValue=function(e){return this.regexp_eatUnicodePropertyValue(e)},Oe.regexp_eatCharacterClass=function(e){if(e.eat(91)){var t=e.eat(94),i=this.regexp_classContents(e);return e.eat(93)||e.raise("Unterminated character class"),t&&2===i&&e.raise("Negated character class may contain strings"),!0}return!1},Oe.regexp_classContents=function(e){return 93===e.current()?1:e.switchV?this.regexp_classSetExpression(e):(this.regexp_nonEmptyClassRanges(e),1)},Oe.regexp_nonEmptyClassRanges=function(e){for(;this.regexp_eatClassAtom(e);){var t=e.lastIntValue;if(e.eat(45)&&this.regexp_eatClassAtom(e)){var i=e.lastIntValue;!e.switchU||-1!==t&&-1!==i||e.raise("Invalid character class"),-1!==t&&-1!==i&&t>i&&e.raise("Range out of order in character class")}}},Oe.regexp_eatClassAtom=function(e){var t=e.pos;if(e.eat(92)){if(this.regexp_eatClassEscape(e))return!0;if(e.switchU){var i=e.current();(99===i||Ke(i))&&e.raise("Invalid class escape"),e.raise("Invalid escape")}e.pos=t}var s=e.current();return 93!==s&&(e.lastIntValue=s,e.advance(),!0)},Oe.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)},Oe.regexp_classSetExpression=function(e){var t,i=1;if(this.regexp_eatClassSetRange(e));else if(t=this.regexp_eatClassSetOperand(e)){2===t&&(i=2);for(var s=e.pos;e.eatChars([38,38]);)38!==e.current()&&(t=this.regexp_eatClassSetOperand(e))?2!==t&&(i=1):e.raise("Invalid character in character class");if(s!==e.pos)return i;for(;e.eatChars([45,45]);)this.regexp_eatClassSetOperand(e)||e.raise("Invalid character in character class");if(s!==e.pos)return i}else e.raise("Invalid character in character class");for(;;)if(!this.regexp_eatClassSetRange(e)){if(!(t=this.regexp_eatClassSetOperand(e)))return i;2===t&&(i=2)}},Oe.regexp_eatClassSetRange=function(e){var t=e.pos;if(this.regexp_eatClassSetCharacter(e)){var i=e.lastIntValue;if(e.eat(45)&&this.regexp_eatClassSetCharacter(e)){var s=e.lastIntValue;return-1!==i&&-1!==s&&i>s&&e.raise("Range out of order in character class"),!0}e.pos=t}return!1},Oe.regexp_eatClassSetOperand=function(e){return this.regexp_eatClassSetCharacter(e)?1:this.regexp_eatClassStringDisjunction(e)||this.regexp_eatNestedClass(e)},Oe.regexp_eatNestedClass=function(e){var t=e.pos;if(e.eat(91)){var i=e.eat(94),s=this.regexp_classContents(e);if(e.eat(93))return i&&2===s&&e.raise("Negated character class may contain strings"),s;e.pos=t}if(e.eat(92)){var n=this.regexp_eatCharacterClassEscape(e);if(n)return n;e.pos=t}return null},Oe.regexp_eatClassStringDisjunction=function(e){var t=e.pos;if(e.eatChars([92,113])){if(e.eat(123)){var i=this.regexp_classStringDisjunctionContents(e);if(e.eat(125))return i}else e.raise("Invalid escape");e.pos=t}return null},Oe.regexp_classStringDisjunctionContents=function(e){for(var t=this.regexp_classString(e);e.eat(124);)2===this.regexp_classString(e)&&(t=2);return t},Oe.regexp_classString=function(e){for(var t=0;this.regexp_eatClassSetCharacter(e);)t++;return 1===t?1:2},Oe.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 i=e.current();return!(i<0||i===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}(i))&&(!function(e){return 40===e||41===e||45===e||47===e||e>=91&&e<=93||e>=123&&e<=125}(i)&&(e.advance(),e.lastIntValue=i,!0))},Oe.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)},Oe.regexp_eatClassControlLetter=function(e){var t=e.current();return!(!He(t)&&95!==t)&&(e.lastIntValue=t%32,e.advance(),!0)},Oe.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},Oe.regexp_eatDecimalDigits=function(e){var t=e.pos,i=0;for(e.lastIntValue=0;He(i=e.current());)e.lastIntValue=10*e.lastIntValue+(i-48),e.advance();return e.pos!==t},Oe.regexp_eatHexDigits=function(e){var t=e.pos,i=0;for(e.lastIntValue=0;qe(i=e.current());)e.lastIntValue=16*e.lastIntValue+Ge(i),e.advance();return e.pos!==t},Oe.regexp_eatLegacyOctalEscapeSequence=function(e){if(this.regexp_eatOctalDigit(e)){var t=e.lastIntValue;if(this.regexp_eatOctalDigit(e)){var i=e.lastIntValue;t<=3&&this.regexp_eatOctalDigit(e)?e.lastIntValue=64*t+8*i+e.lastIntValue:e.lastIntValue=8*t+i}else e.lastIntValue=t;return!0}return!1},Oe.regexp_eatOctalDigit=function(e){var t=e.current();return Ke(t)?(e.lastIntValue=t-48,e.advance(),!0):(e.lastIntValue=0,!1)},Oe.regexp_eatFixedHexDigits=function(e,t){var i=e.pos;e.lastIntValue=0;for(var s=0;s<t;++s){var n=e.current();if(!qe(n))return e.pos=i,!1;e.lastIntValue=16*e.lastIntValue+Ge(n),e.advance()}return!0};var Qe=function(e){this.type=e.type,this.value=e.value,this.start=e.start,this.end=e.end,e.options.locations&&(this.loc=new B(e,e.startLoc,e.endLoc)),e.options.ranges&&(this.range=[e.start,e.end])},Ze=K.prototype;function Xe(e){return"function"!=typeof BigInt?null:BigInt(e.replace(/_/g,""))}Ze.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 Qe(this)),this.lastTokEnd=this.end,this.lastTokStart=this.start,this.lastTokEndLoc=this.endLoc,this.lastTokStartLoc=this.startLoc,this.nextToken()},Ze.getToken=function(){return this.next(),new Qe(this)},"undefined"!=typeof Symbol&&(Ze[Symbol.iterator]=function(){var e=this;return{next:function(){var t=e.getToken();return{done:t.type===_.eof,value:t}}}}),Ze.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(_.eof):e.override?e.override(this):void this.readToken(this.fullCharCodeAtPos())},Ze.readToken=function(e){return m(e,this.options.ecmaVersion>=6)||92===e?this.readWord():this.getTokenFromCode(e)},Ze.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},Ze.skipBlockComment=function(){var e=this.options.onComment&&this.curPosition(),t=this.pos,i=this.input.indexOf("*/",this.pos+=2);if(-1===i&&this.raise(this.pos-2,"Unterminated comment"),this.pos=i+2,this.options.locations)for(var s=void 0,n=t;(s=k(this.input,n,this.pos))>-1;)++this.curLine,n=this.lineStart=s;this.options.onComment&&this.options.onComment(!0,this.input.slice(t+2,i),t,this.pos,e,this.curPosition())},Ze.skipLineComment=function(e){for(var t=this.pos,i=this.options.onComment&&this.curPosition(),s=this.input.charCodeAt(this.pos+=e);this.pos<this.input.length&&!I(s);)s=this.input.charCodeAt(++this.pos);this.options.onComment&&this.options.onComment(!1,this.input.slice(t+e,this.pos),t,this.pos,i,this.curPosition())},Ze.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&&C.test(String.fromCharCode(e))))break e;++this.pos}}},Ze.finishToken=function(e,t){this.end=this.pos,this.options.locations&&(this.endLoc=this.curPosition());var i=this.type;this.type=e,this.value=t,this.updateContext(i)},Ze.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(_.ellipsis)):(++this.pos,this.finishToken(_.dot))},Ze.readToken_slash=function(){var e=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp()):61===e?this.finishOp(_.assign,2):this.finishOp(_.slash,1)},Ze.readToken_mult_modulo_exp=function(e){var t=this.input.charCodeAt(this.pos+1),i=1,s=42===e?_.star:_.modulo;return this.options.ecmaVersion>=7&&42===e&&42===t&&(++i,s=_.starstar,t=this.input.charCodeAt(this.pos+2)),61===t?this.finishOp(_.assign,i+1):this.finishOp(s,i)},Ze.readToken_pipe_amp=function(e){var t=this.input.charCodeAt(this.pos+1);if(t===e){if(this.options.ecmaVersion>=12)if(61===this.input.charCodeAt(this.pos+2))return this.finishOp(_.assign,3);return this.finishOp(124===e?_.logicalOR:_.logicalAND,2)}return 61===t?this.finishOp(_.assign,2):this.finishOp(124===e?_.bitwiseOR:_.bitwiseAND,1)},Ze.readToken_caret=function(){return 61===this.input.charCodeAt(this.pos+1)?this.finishOp(_.assign,2):this.finishOp(_.bitwiseXOR,1)},Ze.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&&!S.test(this.input.slice(this.lastTokEnd,this.pos))?this.finishOp(_.incDec,2):(this.skipLineComment(3),this.skipSpace(),this.nextToken()):61===t?this.finishOp(_.assign,2):this.finishOp(_.plusMin,1)},Ze.readToken_lt_gt=function(e){var t=this.input.charCodeAt(this.pos+1),i=1;return t===e?(i=62===e&&62===this.input.charCodeAt(this.pos+2)?3:2,61===this.input.charCodeAt(this.pos+i)?this.finishOp(_.assign,i+1):this.finishOp(_.bitShift,i)):33!==t||60!==e||this.inModule||45!==this.input.charCodeAt(this.pos+2)||45!==this.input.charCodeAt(this.pos+3)?(61===t&&(i=2),this.finishOp(_.relational,i)):(this.skipLineComment(4),this.skipSpace(),this.nextToken())},Ze.readToken_eq_excl=function(e){var t=this.input.charCodeAt(this.pos+1);return 61===t?this.finishOp(_.equality,61===this.input.charCodeAt(this.pos+2)?3:2):61===e&&62===t&&this.options.ecmaVersion>=6?(this.pos+=2,this.finishToken(_.arrow)):this.finishOp(61===e?_.eq:_.prefix,1)},Ze.readToken_question=function(){var e=this.options.ecmaVersion;if(e>=11){var t=this.input.charCodeAt(this.pos+1);if(46===t){var i=this.input.charCodeAt(this.pos+2);if(i<48||i>57)return this.finishOp(_.questionDot,2)}if(63===t){if(e>=12)if(61===this.input.charCodeAt(this.pos+2))return this.finishOp(_.assign,3);return this.finishOp(_.coalesce,2)}}return this.finishOp(_.question,1)},Ze.readToken_numberSign=function(){var e=35;if(this.options.ecmaVersion>=13&&(++this.pos,m(e=this.fullCharCodeAtPos(),!0)||92===e))return this.finishToken(_.privateId,this.readWord1());this.raise(this.pos,"Unexpected character '"+O(e)+"'")},Ze.getTokenFromCode=function(e){switch(e){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(_.parenL);case 41:return++this.pos,this.finishToken(_.parenR);case 59:return++this.pos,this.finishToken(_.semi);case 44:return++this.pos,this.finishToken(_.comma);case 91:return++this.pos,this.finishToken(_.bracketL);case 93:return++this.pos,this.finishToken(_.bracketR);case 123:return++this.pos,this.finishToken(_.braceL);case 125:return++this.pos,this.finishToken(_.braceR);case 58:return++this.pos,this.finishToken(_.colon);case 96:if(this.options.ecmaVersion<6)break;return++this.pos,this.finishToken(_.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(_.prefix,1);case 35:return this.readToken_numberSign()}this.raise(this.pos,"Unexpected character '"+O(e)+"'")},Ze.finishOp=function(e,t){var i=this.input.slice(this.pos,this.pos+t);return this.pos+=t,this.finishToken(e,i)},Ze.readRegexp=function(){for(var e,t,i=this.pos;;){this.pos>=this.input.length&&this.raise(i,"Unterminated regular expression");var s=this.input.charAt(this.pos);if(S.test(s)&&this.raise(i,"Unterminated regular expression"),e)e=!1;else{if("["===s)t=!0;else if("]"===s&&t)t=!1;else if("/"===s&&!t)break;e="\\"===s}++this.pos}var n=this.input.slice(i,this.pos);++this.pos;var r=this.pos,a=this.readWord1();this.containsEsc&&this.unexpected(r);var o=this.regexpState||(this.regexpState=new Ue(this));o.reset(i,n,a),this.validateRegExpFlags(o),this.validateRegExpPattern(o);var h=null;try{h=new RegExp(n,a)}catch(e){}return this.finishToken(_.regexp,{pattern:n,flags:a,value:h})},Ze.readInt=function(e,t,i){for(var s=this.options.ecmaVersion>=12&&void 0===t,n=i&&48===this.input.charCodeAt(this.pos),r=this.pos,a=0,o=0,h=0,p=null==t?1/0:t;h<p;++h,++this.pos){var c=this.input.charCodeAt(this.pos),u=void 0;if(s&&95===c)n&&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===h&&this.raiseRecoverable(this.pos,"Numeric separator is not allowed at the first of digits"),o=c;else{if((u=c>=97?c-97+10:c>=65?c-65+10:c>=48&&c<=57?c-48:1/0)>=e)break;o=c,a=a*e+u}}return s&&95===o&&this.raiseRecoverable(this.pos-1,"Numeric separator is not allowed at the last of digits"),this.pos===r||null!=t&&this.pos-r!==t?null:a},Ze.readRadixNumber=function(e){var t=this.pos;this.pos+=2;var i=this.readInt(e);return null==i&&this.raise(this.start+2,"Expected number in radix "+e),this.options.ecmaVersion>=11&&110===this.input.charCodeAt(this.pos)?(i=Xe(this.input.slice(t,this.pos)),++this.pos):m(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(_.num,i)},Ze.readNumber=function(e){var t=this.pos;e||null!==this.readInt(10,void 0,!0)||this.raise(t,"Invalid number");var i=this.pos-t>=2&&48===this.input.charCodeAt(t);i&&this.strict&&this.raise(t,"Invalid number");var s=this.input.charCodeAt(this.pos);if(!i&&!e&&this.options.ecmaVersion>=11&&110===s){var n=Xe(this.input.slice(t,this.pos));return++this.pos,m(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(_.num,n)}i&&/[89]/.test(this.input.slice(t,this.pos))&&(i=!1),46!==s||i||(++this.pos,this.readInt(10),s=this.input.charCodeAt(this.pos)),69!==s&&101!==s||i||(43!==(s=this.input.charCodeAt(++this.pos))&&45!==s||++this.pos,null===this.readInt(10)&&this.raise(t,"Invalid number")),m(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number");var r,a=(r=this.input.slice(t,this.pos),i?parseInt(r,8):parseFloat(r.replace(/_/g,"")));return this.finishToken(_.num,a)},Ze.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},Ze.readString=function(e){for(var t="",i=++this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated string constant");var s=this.input.charCodeAt(this.pos);if(s===e)break;92===s?(t+=this.input.slice(i,this.pos),t+=this.readEscapedChar(!1),i=this.pos):8232===s||8233===s?(this.options.ecmaVersion<10&&this.raise(this.start,"Unterminated string constant"),++this.pos,this.options.locations&&(this.curLine++,this.lineStart=this.pos)):(I(s)&&this.raise(this.start,"Unterminated string constant"),++this.pos)}return t+=this.input.slice(i,this.pos++),this.finishToken(_.string,t)};var Ye={};Ze.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(e){if(e!==Ye)throw e;this.readInvalidTemplateToken()}this.inTemplateElement=!1},Ze.invalidStringToken=function(e,t){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw Ye;this.raise(e,t)},Ze.readTmplToken=function(){for(var e="",t=this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated template");var i=this.input.charCodeAt(this.pos);if(96===i||36===i&&123===this.input.charCodeAt(this.pos+1))return this.pos!==this.start||this.type!==_.template&&this.type!==_.invalidTemplate?(e+=this.input.slice(t,this.pos),this.finishToken(_.template,e)):36===i?(this.pos+=2,this.finishToken(_.dollarBraceL)):(++this.pos,this.finishToken(_.backQuote));if(92===i)e+=this.input.slice(t,this.pos),e+=this.readEscapedChar(!0),t=this.pos;else if(I(i)){switch(e+=this.input.slice(t,this.pos),++this.pos,i){case 13:10===this.input.charCodeAt(this.pos)&&++this.pos;case 10:e+="\n";break;default:e+=String.fromCharCode(i)}this.options.locations&&(++this.curLine,this.lineStart=this.pos),t=this.pos}else++this.pos}},Ze.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(_.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")},Ze.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 O(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 i=this.pos-1;this.invalidStringToken(i,"Invalid escape sequence in template string")}default:if(t>=48&&t<=55){var s=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],n=parseInt(s,8);return n>255&&(s=s.slice(0,-1),n=parseInt(s,8)),this.pos+=s.length-1,t=this.input.charCodeAt(this.pos),"0"===s&&56!==t&&57!==t||!this.strict&&!e||this.invalidStringToken(this.pos-1-s.length,e?"Octal literal in template string":"Octal literal in strict mode"),String.fromCharCode(n)}return I(t)?(this.options.locations&&(this.lineStart=this.pos,++this.curLine),""):String.fromCharCode(t)}},Ze.readHexChar=function(e){var t=this.pos,i=this.readInt(16,e);return null===i&&this.invalidStringToken(t,"Bad character escape sequence"),i},Ze.readWord1=function(){this.containsEsc=!1;for(var e="",t=!0,i=this.pos,s=this.options.ecmaVersion>=6;this.pos<this.input.length;){var n=this.fullCharCodeAtPos();if(g(n,s))this.pos+=n<=65535?1:2;else{if(92!==n)break;this.containsEsc=!0,e+=this.input.slice(i,this.pos);var r=this.pos;117!==this.input.charCodeAt(++this.pos)&&this.invalidStringToken(this.pos,"Expecting Unicode escape sequence \\uXXXX"),++this.pos;var a=this.readCodePoint();(t?m:g)(a,s)||this.invalidStringToken(r,"Invalid Unicode escape"),e+=O(a),i=this.pos}t=!1}return e+this.input.slice(i,this.pos)},Ze.readWord=function(){var e=this.readWord1(),t=_.name;return this.keywords.test(e)&&(t=E[e]),this.finishToken(t,e)};function Je(e,t){return K.parse(e,t)}function et(e,t,i,s,n){i||(i=rt),function e(s,n,r){var a=r||s.type;i[a](s,n,e),t[a]&&t[a](s,n)}(e,s,n)}function tt(e,t,i,s,n){var r=[];i||(i=rt),function e(s,n,a){var o=a||s.type,h=s!==r[r.length-1];h&&r.push(s),i[o](s,n,e),t[o]&&t[o](s,n||r,r),h&&r.pop()}(e,s,n)}function it(e,t,i){i(e,t)}function st(e,t,i){}K.acorn={Parser:K,version:"8.15.0",defaultOptions:$,Position:U,SourceLocation:B,getLineInfo:W,Node:xe,TokenType:v,tokTypes:_,keywordTypes:E,TokContext:he,tokContexts:pe,isIdentifierChar:g,isIdentifierStart:m,Token:Qe,isNewLine:I,lineBreak:S,lineBreakG:w,nonASCIIwhitespace:C};var nt,rt={};rt.Program=rt.BlockStatement=rt.StaticBlock=function(e,t,i){for(var s=0,n=e.body;s<n.length;s+=1){i(n[s],t,"Statement")}},rt.Statement=it,rt.EmptyStatement=st,rt.ExpressionStatement=rt.ParenthesizedExpression=rt.ChainExpression=function(e,t,i){return i(e.expression,t,"Expression")},rt.IfStatement=function(e,t,i){i(e.test,t,"Expression"),i(e.consequent,t,"Statement"),e.alternate&&i(e.alternate,t,"Statement")},rt.LabeledStatement=function(e,t,i){return i(e.body,t,"Statement")},rt.BreakStatement=rt.ContinueStatement=st,rt.WithStatement=function(e,t,i){i(e.object,t,"Expression"),i(e.body,t,"Statement")},rt.SwitchStatement=function(e,t,i){i(e.discriminant,t,"Expression");for(var s=0,n=e.cases;s<n.length;s+=1){i(n[s],t)}},rt.SwitchCase=function(e,t,i){e.test&&i(e.test,t,"Expression");for(var s=0,n=e.consequent;s<n.length;s+=1){i(n[s],t,"Statement")}},rt.ReturnStatement=rt.YieldExpression=rt.AwaitExpression=function(e,t,i){e.argument&&i(e.argument,t,"Expression")},rt.ThrowStatement=rt.SpreadElement=function(e,t,i){return i(e.argument,t,"Expression")},rt.TryStatement=function(e,t,i){i(e.block,t,"Statement"),e.handler&&i(e.handler,t),e.finalizer&&i(e.finalizer,t,"Statement")},rt.CatchClause=function(e,t,i){e.param&&i(e.param,t,"Pattern"),i(e.body,t,"Statement")},rt.WhileStatement=rt.DoWhileStatement=function(e,t,i){i(e.test,t,"Expression"),i(e.body,t,"Statement")},rt.ForStatement=function(e,t,i){e.init&&i(e.init,t,"ForInit"),e.test&&i(e.test,t,"Expression"),e.update&&i(e.update,t,"Expression"),i(e.body,t,"Statement")},rt.ForInStatement=rt.ForOfStatement=function(e,t,i){i(e.left,t,"ForInit"),i(e.right,t,"Expression"),i(e.body,t,"Statement")},rt.ForInit=function(e,t,i){"VariableDeclaration"===e.type?i(e,t):i(e,t,"Expression")},rt.DebuggerStatement=st,rt.FunctionDeclaration=function(e,t,i){return i(e,t,"Function")},rt.VariableDeclaration=function(e,t,i){for(var s=0,n=e.declarations;s<n.length;s+=1){i(n[s],t)}},rt.VariableDeclarator=function(e,t,i){i(e.id,t,"Pattern"),e.init&&i(e.init,t,"Expression")},rt.Function=function(e,t,i){e.id&&i(e.id,t,"Pattern");for(var s=0,n=e.params;s<n.length;s+=1){i(n[s],t,"Pattern")}i(e.body,t,e.expression?"Expression":"Statement")},rt.Pattern=function(e,t,i){"Identifier"===e.type?i(e,t,"VariablePattern"):"MemberExpression"===e.type?i(e,t,"MemberPattern"):i(e,t)},rt.VariablePattern=st,rt.MemberPattern=it,rt.RestElement=function(e,t,i){return i(e.argument,t,"Pattern")},rt.ArrayPattern=function(e,t,i){for(var s=0,n=e.elements;s<n.length;s+=1){var r=n[s];r&&i(r,t,"Pattern")}},rt.ObjectPattern=function(e,t,i){for(var s=0,n=e.properties;s<n.length;s+=1){var r=n[s];"Property"===r.type?(r.computed&&i(r.key,t,"Expression"),i(r.value,t,"Pattern")):"RestElement"===r.type&&i(r.argument,t,"Pattern")}},rt.Expression=it,rt.ThisExpression=rt.Super=rt.MetaProperty=st,rt.ArrayExpression=function(e,t,i){for(var s=0,n=e.elements;s<n.length;s+=1){var r=n[s];r&&i(r,t,"Expression")}},rt.ObjectExpression=function(e,t,i){for(var s=0,n=e.properties;s<n.length;s+=1){i(n[s],t)}},rt.FunctionExpression=rt.ArrowFunctionExpression=rt.FunctionDeclaration,rt.SequenceExpression=function(e,t,i){for(var s=0,n=e.expressions;s<n.length;s+=1){i(n[s],t,"Expression")}},rt.TemplateLiteral=function(e,t,i){for(var s=0,n=e.quasis;s<n.length;s+=1){i(n[s],t)}for(var r=0,a=e.expressions;r<a.length;r+=1){i(a[r],t,"Expression")}},rt.TemplateElement=st,rt.UnaryExpression=rt.UpdateExpression=function(e,t,i){i(e.argument,t,"Expression")},rt.BinaryExpression=rt.LogicalExpression=function(e,t,i){i(e.left,t,"Expression"),i(e.right,t,"Expression")},rt.AssignmentExpression=rt.AssignmentPattern=function(e,t,i){i(e.left,t,"Pattern"),i(e.right,t,"Expression")},rt.ConditionalExpression=function(e,t,i){i(e.test,t,"Expression"),i(e.consequent,t,"Expression"),i(e.alternate,t,"Expression")},rt.NewExpression=rt.CallExpression=function(e,t,i){if(i(e.callee,t,"Expression"),e.arguments)for(var s=0,n=e.arguments;s<n.length;s+=1){i(n[s],t,"Expression")}},rt.MemberExpression=function(e,t,i){i(e.object,t,"Expression"),e.computed&&i(e.property,t,"Expression")},rt.ExportNamedDeclaration=rt.ExportDefaultDeclaration=function(e,t,i){e.declaration&&i(e.declaration,t,"ExportNamedDeclaration"===e.type||e.declaration.id?"Statement":"Expression"),e.source&&i(e.source,t,"Expression")},rt.ExportAllDeclaration=function(e,t,i){e.exported&&i(e.exported,t),i(e.source,t,"Expression")},rt.ImportDeclaration=function(e,t,i){for(var s=0,n=e.specifiers;s<n.length;s+=1){i(n[s],t)}i(e.source,t,"Expression")},rt.ImportExpression=function(e,t,i){i(e.source,t,"Expression")},rt.ImportSpecifier=rt.ImportDefaultSpecifier=rt.ImportNamespaceSpecifier=rt.Identifier=rt.PrivateIdentifier=rt.Literal=st,rt.TaggedTemplateExpression=function(e,t,i){i(e.tag,t,"Expression"),i(e.quasi,t,"Expression")},rt.ClassDeclaration=rt.ClassExpression=function(e,t,i){return i(e,t,"Class")},rt.Class=function(e,t,i){e.id&&i(e.id,t,"Pattern"),e.superClass&&i(e.superClass,t,"Expression"),i(e.body,t)},rt.ClassBody=function(e,t,i){for(var s=0,n=e.body;s<n.length;s+=1){i(n[s],t)}},rt.MethodDefinition=rt.PropertyDefinition=rt.Property=function(e,t,i){e.computed&&i(e.key,t,"Expression"),e.value&&i(e.value,t,"Expression")};class at{static extractIdentifiers(e,t){const i=new Set;return et(Je(`(${e})`,{ecmaVersion:"latest"}),{Identifier(e){if(i.add(e.name),t[e.name])for(const s of t[e.name])i.add(s)}}),Array.from(i)}static analyzeFunctionDependencies(e){const t={};for(const[i,s]of Object.entries(e))try{let e=s.toString();const n=/^\s*(\([^)]*\)|[a-zA-Z_$][a-zA-Z0-9_$]*)\s*=>/.test(e),r=e.startsWith("function"),a=e.startsWith("async");r||n||(e=a?`async function ${e.substring(5).trim()}`:`function ${e}`),e=`(${e})`;const o=Je(e,{ecmaVersion:"latest"}),h=new Set,p=new Set;tt(o,{VariableDeclarator(e){"Identifier"===e.id.type&&p.add(e.id.name)},FunctionDeclaration(e){e.id&&"Identifier"===e.id.type&&p.add(e.id.name),e.params.forEach(e=>{"Identifier"===e.type&&p.add(e.name)})},FunctionExpression(e,t){1===t.filter(e=>"FunctionExpression"===e.type||"FunctionDeclaration"===e.type||"ArrowFunctionExpression"===e.type).length&&e.params.forEach(e=>{"Identifier"===e.type&&p.add(e.name)})},ArrowFunctionExpression(e,t){1===t.filter(e=>"FunctionExpression"===e.type||"FunctionDeclaration"===e.type||"ArrowFunctionExpression"===e.type).length&&e.params.forEach(e=>{"Identifier"===e.type&&p.add(e.name)})}}),et(o,{Identifier(e){e.name===i||p.has(e.name)||h.add(e.name)},MemberExpression(e){"ThisExpression"===e.object.type&&"Identifier"===e.property.type&&h.add(e.property.name)}}),t[i]=Array.from(h)}catch(e){console.warn(`Failed to analyze function '${i}':`,e),t[i]=[]}const i={},s=new Set,n=r=>{if(i[r])return i[r];if(s.has(r))return console.warn(`Circular dependency detected for function: ${r}`),[];s.add(r);const a=new Set,o=t[r]||[];for(const t of o)if(e[t]){n(t).forEach(e=>a.add(e))}else a.add(t);return s.delete(r),i[r]=Array.from(a),i[r]};for(const t of Object.keys(e))n(t);return i}}class ot{#i;#s;#n;#r;#a;#o=new Set;#h=new Set;constructor(e){this.#i=e.vNode;const t=e.attribute.name;t.startsWith("v-bind:")?this.#r=t.substring(7):t.startsWith(":")&&(this.#r=t.substring(1)),this.#a=e.attribute.value,this.#a&&(this.#s=at.extractIdentifiers(this.#a,e.vNode.vApplication.functionDependencies),this.#n=this.#p(this.#a)),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_BIND}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){const e=this.#s??[],t=()=>this.#c();return{get dependentIdentifiers(){return e},applyToDOM(){t()}}}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get isKey(){return"key"===this.#r}get isOptions(){return"options"===this.#r||!0===this.#r?.startsWith("options.")}get attributeName(){return this.#r}get expression(){return this.#a}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){}#c(){if(this.isKey||this.isOptions)return;const e=this.#i.node,t=this.#r;if(!this.#n||!t)return;const i=this.#n();"class"===t?this.#u(e,i):"style"===t?this.#d(e,i):this.#l(t)?this.#f(e,t,i):this.#m(t)?this.#g(e,t,i):this.#v(e,t,i)}#u(e,t){let i=[];"string"==typeof t?i=t.split(/\s+/).filter(Boolean):Array.isArray(t)?i=t.filter(Boolean):"object"==typeof t&&null!==t&&(i=Object.keys(t).filter(e=>t[e])),this.#o.forEach(t=>e.classList.remove(t)),i.forEach(t=>e.classList.add(t)),this.#o=new Set(i)}#d(e,t){let i=[];if("string"==typeof t)e.style.cssText=t,i=t.split(";").map(e=>e.split(":")[0].trim()).filter(Boolean);else if("object"==typeof t&&null!==t){this.#h.forEach(t=>{e.style.removeProperty(this.#x(t))});for(const s in t)if(Object.prototype.hasOwnProperty.call(t,s)){const n=this.#x(s),r=t[s];null!=r&&(e.style.setProperty(n,String(r)),i.push(s))}}this.#h=new Set(i)}#x(e){return e.replace(/([A-Z])/g,"-$1").toLowerCase()}#l(e){return["value","checked","selected","innerHTML","textContent"].includes(e)}#m(e){return["disabled","readonly","required","checked","selected","multiple","autofocus","autoplay","controls","loop","muted","open","hidden"].includes(e)}#f(e,t,i){e[t]=i}#g(e,t,i){i?e.setAttribute(t,""):e.removeAttribute(t)}#v(e,t,i){null==i||!1===i?e.removeAttribute(t):e.setAttribute(t,String(i))}#p(e){const t=this.#s??[],i=t.join(", "),s=new Function(i,`return (${e});`);return()=>{const e=t.map(e=>this.#i.bindings?.get(e));return s(...e)}}}class ht{#i;#y;#b;#E=!1;constructor(e){this.#i=e.vNode,this.#y=e.attribute.value.trim(),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_COMPONENT}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){return{get dependentIdentifiers(){return[]},applyToDOM:()=>{this.#E||this.#N()}}}get templatize(){return!1}get dependentIdentifiers(){return[]}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){return()=>this.#_()}get onUnmounted(){}cloneNode(){const e=this.#i.vApplication.componentRegistry.get(this.#y);if(!e)throw new Error(`Component '${this.#y}' not found in registry`);const t=e.templateID||e.id,i=document.querySelector(`#${t}`);if(!(i&&i instanceof HTMLTemplateElement))throw new Error(`Template element '#${t}' not found`);const s=i.content.cloneNode(!0),n=Array.from(s.childNodes);for(const e of n)if(e.nodeType===Node.ELEMENT_NODE)return e;throw new Error(`No element found in template '#${t}'`)}destroy(){this.#_()}#N(){let e={};const t=this.#i.directiveManager?.optionsDirective("component");if(t&&t.expression){const i=t.dependentIdentifiers,s=i.map(e=>this.#i.bindings?.get(e)),n=i.join(", "),r=`return (${t.expression});`,a=new Function(n,r)(...s);"object"==typeof a&&null!==a&&(e=a)}const i=this.#i.vApplication.componentRegistry.get(this.#y);if(!i)throw new Error(`Component '${this.#y}' not found in registry`);const s=i.createInstance(e);this.#b=this.#i.vApplication.createChildApp(s),this.#b.mount(this.#i.node),this.#E=!0}#_(){this.#b&&(this.#b.unmount(),this.#b=void 0),this.#E=!1}}class pt{static proxyCache=new WeakMap;static create(e,t,i=""){if("object"!=typeof e||null===e)return e;let s=this.proxyCache.get(e);if(s){const e=s.get(i);if(e)return e}else s=new Map,this.proxyCache.set(e,s);const n=new Proxy(e,{get(e,s){const n=Reflect.get(e,s);if("object"==typeof n&&null!==n){const r=String(s),a=i?Array.isArray(e)?`${i}[${r}]`:`${i}.${r}`:r;return pt.create(n,t,a)}if(Array.isArray(e)&&"function"==typeof n){if(["push","pop","shift","unshift","splice","sort","reverse"].includes(s))return function(...e){const s=n.apply(this,e);return t(i||void 0),s}}return n},set(e,s,n){const r=Reflect.get(e,s),a=Reflect.set(e,s,n);if(r!==n){const n=String(s),r=i?Array.isArray(e)?`${i}[${n}]`:`${i}.${n}`:n;t(r)}return a},deleteProperty(e,s){const n=Reflect.deleteProperty(e,s),r=String(s),a=i?Array.isArray(e)?`${i}[${r}]`:`${i}.${r}`:r;return t(a),n}});return s.set(i,n),n}static isReactive(e){return this.proxyCache.has(e)}static unwrap(e){return e}}class ct{#S;#w;#I;#k;#C=new Set;#A=new Map;constructor(e={}){this.#S=e.parent,this.#I=e.onChange,this.#k=e.vApplication?.logManager.getLogger("VBindings"),this.#k?.isDebugEnabled&&this.#k.debug("VBindings created. Parent: "+(this.#S?"yes":"no")),this.#w=new Proxy({},{get:(e,t)=>Reflect.has(e,t)?Reflect.get(e,t):this.#S?.raw[t],set:(e,t,i)=>{let s=e;if(!Reflect.has(s,t))for(let e=this.#S;e;e=e.#S)if(Reflect.has(e.#w,t)){s=e.#w;break}let n=i;"object"==typeof i&&null!==i&&(n=pt.create(i,e=>{let t="";for(const i of e?.split(".")||[])t=t?`${t}.${i}`:i,this.#k?.debug(`Binding changed: ${t}`),this.#C.add(t);this.#I?.(e)},t));const r=Reflect.get(s,t),a=Reflect.set(s,t,n);let o=r!==n;if(Array.isArray(n)){const e=this.#A.get(t),i=n.length;o||void 0===e||e===i||(o=!0),this.#A.set(t,i)}if(o){if(this.#k?.isDebugEnabled){const i="string"==typeof r?`"${r}"`:JSON.stringify(r)||"undefined",a="string"==typeof n?`"${n}"`:JSON.stringify(n)||"undefined",o=i.length>100?`${i.substring(0,100)}...`:i,h=a.length>100?`${a.substring(0,100)}...`:a;this.#k.debug(`Binding set on ${s===e?"local":"parent"}: ${t}: ${o} -> ${h}`)}this.#C.add(t),this.#I?.(t)}return a},deleteProperty:(e,t)=>{const i=Reflect.deleteProperty(e,t);return this.#k?.debug(`Binding deleted: ${t}`),this.#C.add(t),this.#I?.(t),i}})}get raw(){return this.#w}get hasChanges(){return!!this.#S?.hasChanges||this.#C.size>0}get changes(){const e=new Set(this.#S?.changes||[]);return this.#C.forEach(t=>e.add(t)),Array.from(e)}get isRoot(){return!this.#S}clearChanges(){this.#C.clear()}set(e,t){this.#w[e]=t}get(e){return this.#w[e]}has(e,t=!0){return e in this.#w||!!t&&(this.#S?.has(e)??!1)}remove(e){delete this.#w[e]}}class ut{#i;#V;#P;#T;#D;#L;#M={};#R;constructor(e){if(e.nodeType!==Node.ELEMENT_NODE)throw new Error("Directives can only be associated with element nodes.");if(this.#i=e,this.#V=this.#O(),this.#V?.some(e=>e.needsAnchor)){this.#P=document.createComment("#vnode-anchor");const e=this.#i.node;e.parentNode?.insertBefore(this.#P,e),e.parentNode?.removeChild(e)}this.#T=this.#V?.map(e=>e.bindingsPreparer).filter(e=>void 0!==e),this.#D=this.#V?.map(e=>e.domUpdater).filter(e=>void 0!==e)}get directives(){return this.#V}get anchorNode(){return this.#P}get bindingsPreparers(){return this.#T}get domUpdaters(){return this.#D}get keyDirective(){return this.#L}get componentDirective(){return this.#R}optionsDirective(e){if(!this.#V||0===this.#V.length)return;const t=`options.${e}`;return this.#M[t]?this.#M[t]:this.#M.options?this.#M.options:void 0}destroy(){if(this.#V)for(const e of this.#V)try{e.destroy()}catch(t){this.#i.vApplication.logManager.getLogger(this.constructor.name).error(`Error destroying '${e.name}' directive: ${t}`)}}#O(){const e=this.#i.node,t=[];if(e.hasAttribute(n.V_FOR)){t.push(e.getAttributeNode(n.V_FOR));for(const i of Array.from(e.attributes))if(["v-bind:key",":key"].includes(i.name)){t.push(i);break}}else e.hasAttribute(n.V_IF)?t.push(e.getAttributeNode(n.V_IF)):e.hasAttribute(n.V_ELSE_IF)?t.push(e.getAttributeNode(n.V_ELSE_IF)):e.hasAttribute(n.V_ELSE)?t.push(e.getAttributeNode(n.V_ELSE)):t.push(...Array.from(e.attributes));const i=[];for(const e of t){const t={vNode:this.#i,attribute:e},s=this.#i.vApplication.directiveParserRegistry.findParser(t);if(s){const e=s.parse(t);if(i.push(e),e.name===n.V_BIND&&e.isKey&&(this.#L=e),e.name===n.V_BIND&&e.isOptions){const t=e,i=t.attributeName;i&&(this.#M[i]=t)}e.name===n.V_COMPONENT&&(this.#R=e)}}const s=[n.V_FOR,n.V_IF,n.V_ELSE_IF,n.V_ELSE,n.V_SHOW],r=i.slice().sort((e,t)=>{const i=s.indexOf(e.name),n=s.indexOf(t.name);return(-1===i?s.length:i)-(-1===n?s.length:n)});return r.length>0?r:void 0}}class dt{#F=[];#n;constructor(e,t){const i=Array.from(e.matchAll(/\{\{([^}]+)\}\}/g));if(this.#F=[],0===i.length)return void(this.#n=()=>e);const s=i.map(e=>{const i=e[1].trim(),s=at.extractIdentifiers(i,t);this.#F.push(...s.filter(e=>!this.#F.includes(e)));const n=s.join(", ");return{ids:s,func:new Function(n,`return (${i});`)}});this.#n=t=>{let n=e;return s.forEach((e,s)=>{const r=e.ids.map(e=>t.get(e));n=n.replace(i[s][0],String(e.func(...r)))}),n}}static containsExpression(e){return/\{\{([^}]+)\}\}/g.test(e)}get identifiers(){return this.#F}evaluate(e){return this.#n(e)}}class lt{#U;#B;#W;#$;#j;#z;#H;#q;#G;#K;#Q;#s;#Z;#X;#Y;#J;constructor(e){if(this.#U=e.vApplication,this.#B=e.node,this.#W=e.node.nodeType,this.#$=e.node.nodeName,this.#j=e.parentVNode,this.#H=e.bindings,this.#q=e.dependentIdentifiers,this.#j?.addChild(this),this.#W===Node.TEXT_NODE){const e=this.#B;dt.containsExpression(e.data)&&(this.#G=new dt(e.data,this.#U.functionDependencies))}else if(this.#W===Node.ELEMENT_NODE){if(this.#B,this.#z=[],this.#K=new ut(this),this.#Y=this.#K.directives?.some(e=>e.templatize)??!1,this.#Y||this.#K.directives?.forEach(e=>{e.onMount?.()}),!this.#Y)for(const e of Array.from(this.#B.childNodes))new lt({node:e,vApplication:this.#U,parentVNode:this});this.#Y||requestAnimationFrame(()=>{this.#K?.directives?.forEach(e=>{e.onMounted?.()})})}this.#X=this.#j?.addDependent(this)}get vApplication(){return this.#U}get node(){return this.#B}get nodeType(){return this.#W}get nodeName(){return this.#$}get parentVNode(){return this.#j}get childVNodes(){return this.#z}get previousSibling(){if(!this.#j||!this.#j.childVNodes)return;const e=this.#j.childVNodes,t=e.indexOf(this);return t>0?e[t-1]:void 0}get nextSibling(){if(!this.#j||!this.#j.childVNodes)return;const e=this.#j.childVNodes,t=e.indexOf(this);return-1!==t&&t<e.length-1?e[t+1]:void 0}get bindings(){return this.#H?this.#H:this.#j?.bindings}get directiveManager(){return this.#K}get anchorNode(){return this.#K?.anchorNode}get isInDOM(){return null!==this.#B.parentNode&&this.#B.parentNode.nodeType!==Node.DOCUMENT_FRAGMENT_NODE}get isRoot(){return void 0===this.#j}get dependentIdentifiers(){if(this.#s)return this.#s;const e=[];return e.push(...this.#q??[]),this.#G&&e.push(...this.#G.identifiers),this.#K?.bindingsPreparers?.forEach(t=>{e.push(...t.dependentIdentifiers)}),this.#K?.domUpdaters?.forEach(t=>{e.push(...t.dependentIdentifiers)}),this.#s=[...new Set(e)],this.#s}get preparableIdentifiers(){if(this.#Z)return this.#Z;const e=[];return this.#K?.bindingsPreparers?.forEach(t=>{e.push(...t.preparableIdentifiers)}),this.#Z=0===e.length?[]:[...new Set(e)],this.#Z}get userData(){return this.#J||(this.#J=new Map),this.#J}get domPath(){const e=[];let t=this;for(;t;){if(t.parentVNode&&t.parentVNode.childVNodes){const i=t.parentVNode.childVNodes.filter(e=>e.nodeName===t?.nodeName).indexOf(t);e.unshift(`${t.nodeName}[${i}]`)}else e.unshift(t.nodeName);t=t.parentVNode}return e.join("/")}update(){const e=this.bindings?.changes||[];if(this.#W===Node.TEXT_NODE&&this.#G){if(this.#G.identifiers.some(t=>e.includes(t))){this.#B.data=this.#G.evaluate(this.bindings)}}else if(this.#W===Node.ELEMENT_NODE){if(this.#Y||this.#K?.directives?.forEach(e=>{e.onUpdate?.()}),this.#K?.bindingsPreparers){this.#H||(this.#H=new ct({parent:this.bindings}));for(const t of this.#K.bindingsPreparers){t.dependentIdentifiers.some(t=>e.includes(t))&&t.prepareBindings()}}if(this.#K?.domUpdaters)for(const t of this.#K.domUpdaters){t.dependentIdentifiers.some(t=>e.includes(t))&&t.applyToDOM()}this.#Q?.forEach(t=>{t.dependentIdentifiers.some(t=>e.includes(t))&&t.update()}),this.#Y||this.#K?.directives?.forEach(e=>{e.onUpdated?.()})}}forceUpdate(){if(this.#W===Node.TEXT_NODE&&this.#G){this.#B.data=this.#G.evaluate(this.bindings)}else if(this.#W===Node.ELEMENT_NODE){if(this.#Y||this.#K?.directives?.forEach(e=>{e.onUpdate?.()}),this.#K?.bindingsPreparers){this.#H||(this.#H=new ct({parent:this.bindings}));for(const e of this.#K.bindingsPreparers)e.prepareBindings()}if(this.#K?.domUpdaters)for(const e of this.#K.domUpdaters)e.applyToDOM();this.#z?.forEach(e=>{e.forceUpdate()}),this.#Y||this.#K?.directives?.forEach(e=>{e.onUpdated?.()})}}addChild(e){this.#z?.push(e)}addDependent(e,t=void 0){const i=[];t||(t=[...e.dependentIdentifiers]);const s=new Set;t.forEach(e=>{s.add(e);const t=e.indexOf("[");-1!==t&&s.add(e.substring(0,t))});const n=[...this.preparableIdentifiers];return this.#H&&n.push(...this.#H?.raw?Object.keys(this.#H.raw):[]),[...s].some(e=>n.includes(e))&&(this.#Q||(this.#Q=[]),this.#Q.push(e),n.forEach(e=>{const i=t.indexOf(e);-1!==i&&t.splice(i,1)}),i.push({close:()=>{const t=this.#Q?.indexOf(e)??-1;-1!==t&&this.#Q?.splice(t,1)}})),this.#j?.addDependent(e,t)?.forEach(e=>i.push(e)),i.length>0?i:void 0}destroy(){if(this.#Y||this.#K?.directives?.forEach(e=>{e.onUnmount?.()}),this.#J){for(const[e,t]of this.#J.entries())try{t&&"object"==typeof t&&"function"==typeof t.close&&t.close()}catch(t){this.#U.logManager.getLogger(this.constructor.name).error(`Error closing user data '${e}': ${t}`)}this.#J.clear()}if(this.#z)for(const e of this.#z)try{e.destroy()}catch(e){this.#U.logManager.getLogger(this.constructor.name).error(`Error destroying child VNode: ${e}`)}if(this.#X)for(const e of this.#X)try{e.close()}catch(e){this.#U.logManager.getLogger(this.constructor.name).error(`Error closing dependency closer: ${e}`)}this.#K?.destroy(),this.#Y||this.#K?.directives?.forEach(e=>{e.onUnmounted?.()})}}class ft{#V=[];#ee=[];get allDependentIdentifiers(){return this.#ee}addDirective(e){if(this.#V.push(e),e.dependentIdentifiers)for(const t of e.dependentIdentifiers)this.#ee.includes(t)||this.#ee.push(t)}isPrecedingConditionMet(e){const t=this.#V.indexOf(e);if(-1===t)throw new Error("Directive not found in context.");for(let e=0;e<t;e++){if(!0===this.#V[e].conditionIsMet)return!0}return!1}}class mt{#i;#s;#n;#te;#ie;constructor(e){this.#i=e.vNode;const t=e.attribute.value;t&&(this.#s=at.extractIdentifiers(t,e.vNode.vApplication.functionDependencies),this.#n=this.#p(t)),this.#i.node.removeAttribute(e.attribute.name),this.#te=this.#se(),this.#te.addDirective(this)}get vNode(){return this.#i}get needsAnchor(){return!0}get bindingsPreparer(){}get domUpdater(){const e=this.#te.allDependentIdentifiers,t=()=>this.#c();return{get dependentIdentifiers(){return e},applyToDOM(){t()}}}get templatize(){return!0}get dependentIdentifiers(){return this.#s??[]}get conditionalContext(){return this.#te}get conditionIsMet(){return!this.#n||this.#n()}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){}#c(){if(this.#te.isPrecedingConditionMet(this))return void this.#ne();if(!this.#n)return void this.#re();this.#n()?this.#re():this.#ne()}#re(){this.#ie||(this.#ie=this.#ae(),this.#i.anchorNode?.parentNode?.insertBefore(this.#ie.node,this.#i.anchorNode.nextSibling),this.#ie.forceUpdate())}#ne(){this.#ie&&(this.#ie.destroy(),this.#ie.node.parentNode?.removeChild(this.#ie.node),this.#ie=void 0)}#ae(){let e;if(this.vNode.directiveManager?.componentDirective)e=this.vNode.directiveManager.componentDirective.cloneNode();else{e=this.#i.node.cloneNode(!0)}return new lt({node:e,vApplication:this.#i.vApplication,parentVNode:this.#i.parentVNode})}#p(e){const t=this.#s??[],i=t.join(", "),s=new Function(i,`return (${e});`);return()=>{const e=t.map(e=>this.#i.bindings?.get(e));return Boolean(s(...e))}}#se(){if(this.name===n.V_IF)return new ft;let e=this.vNode.previousSibling;for(;e&&e.nodeType!==Node.ELEMENT_NODE;)e=e.previousSibling;const t=e?.directiveManager?.directives?.find(e=>e.name===n.V_IF||e.name===n.V_ELSE_IF);if(!t)throw new Error("preceding v-if or v-else-if directive not found.");return t.conditionalContext}}class gt extends mt{constructor(e){super(e)}get name(){return n.V_ELSE}}class vt extends mt{constructor(e){super(e)}get name(){return n.V_ELSE_IF}}class xt{#i;#s;#oe;#he;#pe;#ce;#ue;#de=new Map;#le=[];constructor(e){this.#i=e.vNode;const t=this.#i.node,i=e.attribute.value;if(i){const t=this.#fe(i);this.#pe=t.itemName,this.#ce=t.indexName,this.#ue=t.sourceName,this.#s=at.extractIdentifiers(t.sourceName,e.vNode.vApplication.functionDependencies),this.#oe=this.#me(t.sourceName)}t.removeAttribute(e.attribute.name)}get name(){return n.V_FOR}get vNode(){return this.#i}get needsAnchor(){return!0}get bindingsPreparer(){}get domUpdater(){const e=this.#s??[],t=()=>this.#c();return{get dependentIdentifiers(){return e},applyToDOM(){t()}}}get templatize(){return!0}get dependentIdentifiers(){return this.#s??[]}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){for(const e of this.#de.values())e.destroy();for(const e of this.#de.values())e.node.parentNode&&e.node.parentNode.removeChild(e.node);this.#de.clear(),this.#le=[]}#c(){if(!this.#oe)return;const e=this.#oe();let t=this.#ge(e);const i=this.#i.directiveManager?.keyDirective?.expression;this.#he||void 0===i||(this.#he=this.#ve(i)),this.#he&&this.#pe&&(t=t.map(e=>{const t=new ct({parent:this.#i.bindings});t.set(this.#pe,e.item),this.#ce&&t.set(this.#ce,e.index);const i=this.#he(t);return{...e,key:i}})),this.#xe(t),this.#le=t}#xe(e){const t=this.#i.anchorNode?.parentNode,i=this.#i.anchorNode;if(!t||!i)throw new Error("v-for element must have a parent and anchor");const s=new Map,n=new Set(e.map(e=>e.key)),r=[];for(const[e,t]of this.#de)n.has(e)||(r.push(t),t.destroy());for(const e of r)e.node.parentNode&&e.node.parentNode.removeChild(e.node);let a=i;for(const i of e){const{key:e}=i;let n=this.#de.get(e);n?(s.set(e,n),this.#ye(n,i),a.nextSibling!==n.node&&(a.nextSibling?t.insertBefore(n.node,a.nextSibling):t.appendChild(n.node))):(n=this.#ae(i),s.set(e,n),a.nextSibling?t.insertBefore(n.node,a.nextSibling):t.appendChild(n.node),n.forceUpdate()),a=n.node}this.#de=s}#fe(e){const t=e.replace(/\s+/g," ").trim().split(" in ");if(2!==t.length)throw new Error(`Invalid v-for expression: ${e}`);const[i,s]=t;if(i.startsWith("(")&&i.endsWith(")")){const e=i.slice(1,-1).split(",").map(e=>e.trim());return{itemName:e[0],indexName:e[1],sourceName:s.trim()}}return{itemName:i.trim(),sourceName:s.trim()}}#me(e){const t=this.#s??[],i=t.join(", "),s=new Function(i,`return (${e});`);return()=>{const e=t.map(e=>this.#i.bindings?.get(e));return s(...e)}}#ve(e){const t=at.extractIdentifiers(e,this.#i.vApplication.functionDependencies),i=t.join(", "),s=new Function(i,`return (${e});`);return e=>{const i=t.map(t=>e.get(t));return s(...i)}}#ae(e){let t;if(this.vNode.directiveManager?.componentDirective)t=this.vNode.directiveManager.componentDirective.cloneNode();else{t=this.#i.node.cloneNode(!0)}this.#pe,this.#ce;const i=new ct({parent:this.#i.bindings});this.#pe&&i.set(this.#pe,e.item),this.#ce&&i.set(this.#ce,e.index);return new lt({node:t,vApplication:this.#i.vApplication,parentVNode:this.#i.parentVNode,bindings:i,dependentIdentifiers:[`${this.#ue}[${e.index}]`]})}#ye(e,t){this.#pe&&e.bindings?.set(this.#pe,t.item),this.#ce&&e.bindings?.set(this.#ce,t.index),e.update()}#ge(e){return e?Array.isArray(e)?e.map((e,t)=>({item:e,index:t,key:t})):"object"==typeof e?Object.entries(e).map(([e,t],i)=>({item:t,index:i,key:e})):"number"==typeof e?Array.from({length:e},(e,t)=>({item:t+1,index:t,key:t+1})):"string"==typeof e?Array.from(e).map((e,t)=>({item:e,index:t,key:t})):[]:[]}}class yt extends mt{constructor(e){super(e)}get name(){return n.V_IF}}class bt{#i;#s;#be;#Ee;constructor(e){this.#i=e.vNode;const t=e.attribute.value;t&&(this.#s=at.extractIdentifiers(t,e.vNode.vApplication.functionDependencies),this.#be=this.#Ne(t)),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_INTERSECTION}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get onMount(){}get onMounted(){if(!this.#be)return;const e=this.#i.node,t=this.#be;return()=>{let i,s=this.#i.directiveManager?.optionsDirective("intersection");if(s&&s.expression){const e=s.dependentIdentifiers,t=e.map(e=>this.#i.bindings?.get(e)),n=e.join(", "),r=`return (${s.expression});`;i=new Function(n,r)(...t)}this.#Ee=new IntersectionObserver(e=>{t(e)},i),this.#Ee.observe(e)}}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){this.#Ee&&(this.#Ee.disconnect(),this.#Ee=void 0)}#Ne(e){const t=this.#s??[],i=this.#i;return s=>{const n=i.bindings,r={element:i.node,vnode:i,userData:i.userData},a=e.trim();if(t.includes(a)&&"function"==typeof n?.get(a)){const e=a,t=n?.get(e);return t(s,r)}const o=t.map(e=>i.bindings?.get(e)),h=[...t,"entries","$ctx"].join(", ");return new Function(h,`return (${e});`).call(n?.raw,...o,s,r)}}}class Et{#i;#s;#n;#a;#_e;#Se=new Set;constructor(e){this.#i=e.vNode;const t=e.attribute.name;if(t.startsWith("v-model.")){t.split(".").slice(1).forEach(e=>this.#Se.add(e))}const i=e.attribute.value;i&&(this.#a=i,this.#s=at.extractIdentifiers(i,e.vNode.vApplication.functionDependencies),this.#n=this.#p(i),this.#we()),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_MODEL}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){const e=this.#s??[],t=()=>this.#c();return{get dependentIdentifiers(){return e},applyToDOM(){t()}}}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){if(this.#_e){const e=this.#i.node,t=this.#Ie();e.removeEventListener(t,this.#_e)}}#c(){const e=this.#i.node;if(!this.#n)return;const t=this.#n();e instanceof HTMLInputElement?"checkbox"===e.type?e.checked=!!t:"radio"===e.type?e.checked=e.value===String(t):e.value=t??"":(e instanceof HTMLTextAreaElement||e instanceof HTMLSelectElement)&&(e.value=t??"")}#we(){const e=this.#i.node,t=this.#Ie();this.#_e=e=>{const t=e.target;let i;t instanceof HTMLInputElement?i="checkbox"===t.type?t.checked:(t.type,t.value):(t instanceof HTMLTextAreaElement||t instanceof HTMLSelectElement)&&(i=t.value),i=this.#ke(i),this.#Ce(i)},e.addEventListener(t,this.#_e)}#ke(e){if("boolean"==typeof e)return e;let t=e;if(this.#Se.has("trim")&&"string"==typeof t&&(t=t.trim()),this.#Se.has("number")&&""!==t){const e=Number(t);isNaN(e)||(t=e)}return t}#Ie(){const e=this.#i.node;return this.#Se.has("lazy")?"change":e instanceof HTMLInputElement?"checkbox"===e.type||"radio"===e.type?"change":"input":e instanceof HTMLSelectElement?"change":"input"}#Ce(e){if(!this.#a)return;const t=this.#a.trim(),i=[e],s=["$newValue"].join(", ");new Function(s,`(this.${t} = $newValue);`).call(this.#i.bindings?.raw,...i)}#p(e){const t=this.#s??[],i=t.join(", "),s=new Function(i,`return (${e});`);return()=>{const e=t.map(e=>this.#i.bindings?.get(e));return s(...e)}}}class Nt{#i;#s;#be;#Ae;#Se=new Set;#_e;#Ve=new Map;constructor(e){this.#i=e.vNode;const t=e.attribute.name;if(t.startsWith("v-on:")){const e=t.substring(5).split(".");this.#Ae=e[0],e.slice(1).forEach(e=>this.#Se.add(e))}else if(t.startsWith("@")){const e=t.substring(1).split(".");this.#Ae=e[0],e.slice(1).forEach(e=>this.#Se.add(e))}const i=e.attribute.value;if(i&&(this.#s=at.extractIdentifiers(i,e.vNode.vApplication.functionDependencies)),this.#Ae&&this.#Pe(this.#Ae)){if(i){const e=this.#Te(i);this.#be=e,this.#Ve.set(this.#Ae,e)}}else this.#Ae&&(i&&(this.#be=this.#De(i)),this.#we());this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_ON}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get onMount(){return this.#Ve.get("mount")}get onMounted(){return this.#Ve.get("mounted")}get onUpdate(){return this.#Ve.get("update")}get onUpdated(){return this.#Ve.get("updated")}get onUnmount(){return this.#Ve.get("unmount")}get onUnmounted(){return this.#Ve.get("unmounted")}destroy(){if(this.#Ae&&this.#_e){const e=this.#i.node,t=this.#Se.has("capture");e.removeEventListener(this.#Ae,this.#_e,t)}}#we(){if(!this.#Ae||!this.#be)return;const e=this.#i.node,t=this.#Ae,i=this.#Se.has("capture"),s=this.#Se.has("once");this.#_e=n=>{if(n instanceof KeyboardEvent){if(["enter","tab","delete","esc","space","up","down","left","right"].some(e=>this.#Se.has(e))){const e={enter:"Enter",tab:"Tab",delete:"Delete",esc:"Escape",space:" ",up:"ArrowUp",down:"ArrowDown",left:"ArrowLeft",right:"ArrowRight"};let t=!1;for(const[i,s]of Object.entries(e))if(this.#Se.has(i)&&n.key===s){t=!0;break}if(!t)return}}this.#Se.has("stop")&&n.stopPropagation(),this.#Se.has("prevent")&&n.preventDefault(),this.#Se.has("self")&&n.target!==e||(this.#be(n),s&&this.#_e&&e.removeEventListener(t,this.#_e,i))},e.addEventListener(t,this.#_e,i)}#Pe(e){return["mount","mounted","update","updated","unmount","unmounted"].includes(e)}#Te(e){const t=this.#s??[],i=this.#i;return()=>{const s=i.bindings,n={element:i.node,vnode:i,userData:i.userData},r=e.trim();if(t.includes(r)&&"function"==typeof s?.get(r)){const e=r,t=s?.get(e);return t(n)}const a=t.map(e=>i.bindings?.get(e)),o=[...t,"$ctx"].join(", ");return new Function(o,`return (${e});`).call(s?.raw,...a,n)}}#De(e){const t=this.#s??[],i=this.#i;return s=>{const n=i.bindings,r={element:i.node,vnode:i,userData:i.userData},a=e.trim();if(t.includes(a)&&"function"==typeof n?.get(a)){const e=a,t=n?.get(e);return t(s,r)}const o=t.map(e=>i.bindings?.get(e)),h=[...t,"event","$ctx"].join(", ");return new Function(h,`return (${e});`).call(n?.raw,...o,s,r)}}}class _t{#i;#s;#be;#Le;constructor(e){this.#i=e.vNode;const t=e.attribute.value;t&&(this.#s=at.extractIdentifiers(t,e.vNode.vApplication.functionDependencies),this.#be=this.#Me(t)),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_PERFORMANCE}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get onMount(){}get onMounted(){if(!this.#be)return;const e=this.#be;return()=>{let t,i=this.#i.directiveManager?.optionsDirective("performance");if(i&&i.expression){const e=i.dependentIdentifiers,s=e.map(e=>this.#i.bindings?.get(e)),n=e.join(", "),r=`return (${i.expression});`;t=new Function(n,r)(...s)}this.#Le=new PerformanceObserver((...t)=>{const[i,s,n]=t;e(i,s,n)}),t||(t={entryTypes:["mark","measure"]}),this.#Le.observe(t)}}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){this.#Le&&(this.#Le.disconnect(),this.#Le=void 0)}#Me(e){const t=this.#s??[],i=this.#i;return(s,n,r)=>{const a=i.bindings,o={element:i.node,vnode:i,userData:i.userData},h=e.trim();if(t.includes(h)&&"function"==typeof a?.get(h)){const e=h,t=a?.get(e);return t(s,n,r,o)}const p=t.map(e=>i.bindings?.get(e)),c=[...t,"entries","observer","options","$ctx"].join(", ");return new Function(c,`return (${e});`).call(a?.raw,...p,s,n,r,o)}}}class St{#i;#s;#be;#Re;constructor(e){this.#i=e.vNode;const t=e.attribute.value;t&&(this.#s=at.extractIdentifiers(t,e.vNode.vApplication.functionDependencies),this.#be=this.#Oe(t)),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_RESIZE}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get onMount(){}get onMounted(){if(!this.#be)return;const e=this.#i.node,t=this.#be;return()=>{let i,s=this.#i.directiveManager?.optionsDirective("resize");if(s&&s.expression){const e=s.dependentIdentifiers,t=e.map(e=>this.#i.bindings?.get(e)),n=e.join(", "),r=`return (${s.expression});`;i=new Function(n,r)(...t)}this.#Re=new ResizeObserver(e=>{t(e)}),this.#Re.observe(e,i)}}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){this.#Re&&(this.#Re.disconnect(),this.#Re=void 0)}#Oe(e){const t=this.#s??[],i=this.#i;return s=>{const n=i.bindings,r={element:i.node,vnode:i,userData:i.userData},a=e.trim();if(t.includes(a)&&"function"==typeof n?.get(a)){const e=a,t=n?.get(e);return t(s,r)}const o=t.map(e=>i.bindings?.get(e)),h=[...t,"entries","$ctx"].join(", ");return new Function(h,`return (${e});`).call(n?.raw,...o,s,r)}}}class wt{#i;#s;#n;#Fe;constructor(e){this.#i=e.vNode;const t=e.attribute.value;this.#s=at.extractIdentifiers(t,e.vNode.vApplication.functionDependencies),this.#n=this.#p(t),this.#i.node.removeAttribute(e.attribute.name);const i=this.#i.node;this.#Fe="none"===i.style.display?"":i.style.display}get name(){return n.V_SHOW}get vNode(){return this.#i}get needsAnchor(){return!0}get bindingsPreparer(){}get domUpdater(){const e=this.#s??[],t=this.#n,i=()=>this.visibleNode(),s=()=>this.invisibleNode();return{get dependentIdentifiers(){return e},applyToDOM(){t()?i():s()}}}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}visibleNode(){const e=this.#i.node;"none"!==e.style.display&&(e.style.display=this.#Fe)}invisibleNode(){const e=this.#i.node;"none"!==e.style.display&&(this.#Fe="none"===e.style.display?"":e.style.display,e.style.display="none")}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){}#p(e){const t=this.#s??[],i=t.join(", "),s=new Function(i,`return (${e});`);return()=>{const e=t.map(e=>this.#i.bindings?.get(e));return Boolean(s(...e))}}}class It{get name(){return"VStandardDirectiveParser"}canParse(e){return!!(e.attribute.name===n.V_IF||e.attribute.name===n.V_ELSE_IF||e.attribute.name===n.V_ELSE||e.attribute.name===n.V_SHOW||e.attribute.name===n.V_FOR||e.attribute.name.startsWith(n.V_ON+":")||e.attribute.name.startsWith("@")||e.attribute.name.startsWith(n.V_BIND+":")||e.attribute.name.startsWith(":")||e.attribute.name===n.V_MODEL||e.attribute.name.startsWith(n.V_MODEL+".")||e.attribute.name===n.V_RESIZE||e.attribute.name===n.V_INTERSECTION||e.attribute.name===n.V_PERFORMANCE||e.attribute.name===n.V_COMPONENT||e.attribute.name.startsWith(n.V_COMPONENT+"."))}parse(e){if(e.attribute.name===n.V_IF)return new yt(e);if(e.attribute.name===n.V_ELSE_IF)return new vt(e);if(e.attribute.name===n.V_ELSE)return new gt(e);if(e.attribute.name===n.V_SHOW)return new wt(e);if(e.attribute.name===n.V_FOR)return new xt(e);if(e.attribute.name.startsWith(n.V_ON+":")||e.attribute.name.startsWith("@"))return new Nt(e);if(e.attribute.name.startsWith(n.V_BIND+":")||e.attribute.name.startsWith(":"))return new ot(e);if(e.attribute.name===n.V_MODEL||e.attribute.name.startsWith(n.V_MODEL+"."))return new Et(e);if(e.attribute.name===n.V_RESIZE)return new St(e);if(e.attribute.name===n.V_INTERSECTION)return new bt(e);if(e.attribute.name===n.V_PERFORMANCE)return new _t(e);if(e.attribute.name===n.V_COMPONENT||e.attribute.name.startsWith(n.V_COMPONENT+"."))return new ht(e);throw new Error(`The attribute "${e.attribute.name}" cannot be parsed by ${this.name}.`)}}!function(e){e.DEBUG="debug",e.INFO="info",e.WARN="warn",e.ERROR="error"}(nt||(nt={}));class kt{#Ue;#Be;constructor(e,t){this.#Ue=e,this.#Be=t}get isDebugEnabled(){return[nt.DEBUG].includes(this.#Be.logLevel)}get isInfoEnabled(){return[nt.DEBUG,nt.INFO].includes(this.#Be.logLevel)}get isWarnEnabled(){return[nt.DEBUG,nt.INFO,nt.WARN].includes(this.#Be.logLevel)}debug(e){this.isDebugEnabled&&console.debug(`[${this.#Ue}] ${nt.DEBUG}: ${e}`)}info(e){this.isInfoEnabled&&console.info(`[${this.#Ue}] ${nt.INFO}: ${e}`)}warn(e){this.isWarnEnabled&&console.warn(`[${this.#Ue}] ${nt.WARN}: ${e}`)}error(e){console.error(`[${this.#Ue}] ${nt.ERROR}: ${e}`)}}class Ct{#We;#$e=new Map;constructor(e=nt.INFO){this.#We=e}set logLevel(e){this.#We=e}get logLevel(){return this.#We}getLogger(e){if(this.#$e.has(e))return this.#$e.get(e);const t=new kt(e,this);return this.#$e.set(e,t),t}}class At{#je;#ze;#He;#i;#H;#Be;#k;#qe;#Ge;#Ke=!1;constructor(e,t,i){this.#je=e,this.#ze=t,this.#He=i,this.#Be=new Ct(e.logLevel),this.#k=this.#Be.getLogger("VApplication"),this.#qe=at.analyzeFunctionDependencies(e.methods||{}),this.#Ge=at.analyzeFunctionDependencies(e.computed||{}),this.#Qe()}get directiveParserRegistry(){return this.#ze}get componentRegistry(){return this.#He}get rootVNode(){return this.#i}get bindings(){return this.#H}get logManager(){return this.#Be}get functionDependencies(){return this.#qe}mount(e){let t;if("string"==typeof e){if(t=document.querySelector(e),!t)throw new Error(`Element not found for selector: ${e}`)}else t=e;this.#Ze(t),this.#i=new lt({node:t,vApplication:this,bindings:this.#H}),this.#i.update(),this.#k.info("Application mounted.")}unmount(){this.#i&&(this.#i.destroy(),this.#i=void 0),this.#k.info("Application unmounted.")}createChildApp(e){return new At(e,this.#ze,this.#He)}#Ze(e){let t=null;for(const i of Array.from(e.childNodes))if(i.nodeType===Node.TEXT_NODE){const s=i;/^[\s\n\r\t]*$/.test(s.nodeValue||"")?e.removeChild(s):t?(t.nodeValue+=s.nodeValue||"",e.removeChild(s)):t=s}else t=null,i.nodeType===Node.ELEMENT_NODE&&this.#Ze(i)}#Qe(){if(this.#H=new ct({onChange:e=>{this.#Xe()},vApplication:this}),this.#H.set("$nextTick",e=>this.#Ye(e)),this.#je.methods)for(const[e,t]of Object.entries(this.#je.methods))"function"==typeof t?this.#H.set(e,t.bind(this.#H.raw)):this.#k.warn(`Method '${e}' is not a function and will be ignored.`);if(this.#je.data){const e=this.#je.data();if(e&&"object"==typeof e)for(const[t,i]of Object.entries(e))this.#H.set(t,i)}this.#Je()}#Xe(){this.#Ke||(this.#Ke=!0,queueMicrotask(()=>{this.#et(),this.#Ke=!1}))}#et(){this.#Je(),this.#i?.update(),this.#H?.clearChanges()}#Je(){if(!this.#je.computed)return;const e=new Set,t=new Set,i=new Set;this.#H?.changes.forEach(e=>{i.add(e);const t=e.indexOf("[");-1!==t&&i.add(e.substring(0,t))});const s=n=>{if(e.has(n))return;if(t.has(n))return void this.#k.error(`Circular dependency detected for computed property '${n}'`);t.add(n);const r=this.#Ge[n]||[];if(!r.some(e=>i.has(e)))return void e.add(n);for(const e of r)this.#je.computed[e]&&s(e);const a=this.#je.computed[n];try{const e=this.#H?.get(n),t=a.call(this.#H?.raw);e!==t&&(this.#H?.set(n,t),i.add(n))}catch(e){this.#k.error(`Error evaluating computed property '${n}': ${e}`)}e.add(n),t.delete(n)};for(const[e,t]of Object.entries(this.#Ge))t.some(e=>i.has(e))&&s(e)}#Ye(e){this.#Ke?queueMicrotask(()=>{queueMicrotask(e)}):queueMicrotask(e)}}class Vt{static#He=new i;static#ze=new s;static{this.#ze.register(new It)}static get componentRegistry(){return this.#He}static get directiveParserRegistry(){return this.#ze}static get isSupported(){try{return"function"==typeof structuredClone&&("undefined"!=typeof document&&"function"==typeof document.createElement)}catch{return!1}}static createApp(e){return new At(e,this.#ze,this.#He)}}e.VComponent=t,e.VComponentRegistry=i,e.VDOM=Vt});
1
+ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).ichigo={})}(this,function(e){"use strict";class t{id;createInstance;templateID;constructor(e,t,i){if(!e||"string"!=typeof e)throw new Error("Component ID must be a non-empty string.");if("function"!=typeof t)throw new Error("createInstance must be a function.");this.id=e.trim(),this.createInstance=t,this.templateID=i?.trim()||this.id}}class i{#e=new Map;register(e,i,s){if(this.has(e))return!1;const n=new t(e,i,s);return this.#e.set(e,n),!0}has(e){return this.#e.has(e)}get(e){return this.#e.get(e)}unregister(e){return this.#e.delete(e)}clear(){this.#e.clear()}}class s{#t=[];get parsers(){return this.#t.slice()}register(e){this.#t.push(e)}unregister(e){const t=this.#t.indexOf(e);t>=0&&this.#t.splice(t,1)}findParser(e){return this.#t.find(t=>t.canParse(e))||null}}var n;!function(e){e.V_IF="v-if",e.V_ELSE_IF="v-else-if",e.V_ELSE="v-else",e.V_SHOW="v-show",e.V_FOR="v-for",e.V_ON="v-on",e.V_BIND="v-bind",e.V_MODEL="v-model",e.V_RESIZE="v-resize",e.V_INTERSECTION="v-intersection",e.V_PERFORMANCE="v-performance",e.V_COMPONENT="v-component"}(n||(n={}));var r=[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],a=[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],o="ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢎࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೝೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-ᲊᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꟍꟐꟑꟓꟕ-Ƛꟲ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",h={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"},p="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",c={5:p,"5module":p+" export import",6:p+" const class extends export import super"},u=/^in(stanceof)?$/,d=new RegExp("["+o+"]"),l=new RegExp("["+o+"‌‍·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛ࢗ-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ-ᫎᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‌‍‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・]");function f(e,t){for(var i=65536,s=0;s<t.length;s+=2){if((i+=t[s])>e)return!1;if((i+=t[s+1])>=e)return!0}return!1}function m(e,t){return e<65?36===e:e<91||(e<97?95===e:e<123||(e<=65535?e>=170&&d.test(String.fromCharCode(e)):!1!==t&&f(e,a)))}function g(e,t){return e<48?36===e:e<58||!(e<65)&&(e<91||(e<97?95===e:e<123||(e<=65535?e>=170&&l.test(String.fromCharCode(e)):!1!==t&&(f(e,a)||f(e,r)))))}var v=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 x(e,t){return new v(e,{beforeExpr:!0,binop:t})}var y={beforeExpr:!0},b={startsExpr:!0},E={};function N(e,t){return void 0===t&&(t={}),t.keyword=e,E[e]=new v(e,t)}var _={num:new v("num",b),regexp:new v("regexp",b),string:new v("string",b),name:new v("name",b),privateId:new v("privateId",b),eof:new v("eof"),bracketL:new v("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new v("]"),braceL:new v("{",{beforeExpr:!0,startsExpr:!0}),braceR:new v("}"),parenL:new v("(",{beforeExpr:!0,startsExpr:!0}),parenR:new v(")"),comma:new v(",",y),semi:new v(";",y),colon:new v(":",y),dot:new v("."),question:new v("?",y),questionDot:new v("?."),arrow:new v("=>",y),template:new v("template"),invalidTemplate:new v("invalidTemplate"),ellipsis:new v("...",y),backQuote:new v("`",b),dollarBraceL:new v("${",{beforeExpr:!0,startsExpr:!0}),eq:new v("=",{beforeExpr:!0,isAssign:!0}),assign:new v("_=",{beforeExpr:!0,isAssign:!0}),incDec:new v("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new v("!/~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:x("||",1),logicalAND:x("&&",2),bitwiseOR:x("|",3),bitwiseXOR:x("^",4),bitwiseAND:x("&",5),equality:x("==/!=/===/!==",6),relational:x("</>/<=/>=",7),bitShift:x("<</>>/>>>",8),plusMin:new v("+/-",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:x("%",10),star:x("*",10),slash:x("/",10),starstar:new v("**",{beforeExpr:!0}),coalesce:x("??",1),_break:N("break"),_case:N("case",y),_catch:N("catch"),_continue:N("continue"),_debugger:N("debugger"),_default:N("default",y),_do:N("do",{isLoop:!0,beforeExpr:!0}),_else:N("else",y),_finally:N("finally"),_for:N("for",{isLoop:!0}),_function:N("function",b),_if:N("if"),_return:N("return",y),_switch:N("switch"),_throw:N("throw",y),_try:N("try"),_var:N("var"),_const:N("const"),_while:N("while",{isLoop:!0}),_with:N("with"),_new:N("new",{beforeExpr:!0,startsExpr:!0}),_this:N("this",b),_super:N("super",b),_class:N("class",b),_extends:N("extends",y),_export:N("export"),_import:N("import",b),_null:N("null",b),_true:N("true",b),_false:N("false",b),_in:N("in",{beforeExpr:!0,binop:7}),_instanceof:N("instanceof",{beforeExpr:!0,binop:7}),_typeof:N("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:N("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:N("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})},S=/\r\n?|\n|\u2028|\u2029/,w=new RegExp(S.source,"g");function I(e){return 10===e||13===e||8232===e||8233===e}function k(e,t,i){void 0===i&&(i=e.length);for(var s=t;s<i;s++){var n=e.charCodeAt(s);if(I(n))return s<i-1&&13===n&&10===e.charCodeAt(s+1)?s+2:s+1}return-1}var C=/[\u1680\u2000-\u200a\u202f\u205f\u3000\ufeff]/,A=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g,V=Object.prototype,P=V.hasOwnProperty,T=V.toString,D=Object.hasOwn||function(e,t){return P.call(e,t)},L=Array.isArray||function(e){return"[object Array]"===T.call(e)},M=Object.create(null);function R(e){return M[e]||(M[e]=new RegExp("^(?:"+e.replace(/ /g,"|")+")$"))}function O(e){return e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10),56320+(1023&e)))}var F=/(?:[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])/,U=function(e,t){this.line=e,this.column=t};U.prototype.offset=function(e){return new U(this.line,this.column+e)};var B=function(e,t,i){this.start=t,this.end=i,null!==e.sourceFile&&(this.source=e.sourceFile)};function W(e,t){for(var i=1,s=0;;){var n=k(e,s,t);if(n<0)return new U(i,t-s);++i,s=n}}var $={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},j=!1;function z(e){var t={};for(var i in $)t[i]=e&&D(e,i)?e[i]:$[i];if("latest"===t.ecmaVersion?t.ecmaVersion=1e8:null==t.ecmaVersion?(!j&&"object"==typeof console&&console.warn&&(j=!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),L(t.onToken)){var s=t.onToken;t.onToken=function(e){return s.push(e)}}return L(t.onComment)&&(t.onComment=function(e,t){return function(i,s,n,r,a,o){var h={type:i?"Block":"Line",value:s,start:n,end:r};e.locations&&(h.loc=new B(this,a,o)),e.ranges&&(h.range=[n,r]),t.push(h)}}(t,t.onComment)),t}var H=256,q=259;function G(e,t){return 2|(e?4:0)|(t?8:0)}var K=function(e,t,i){this.options=e=z(e),this.sourceFile=e.sourceFile,this.keywords=R(c[e.ecmaVersion>=6?6:"module"===e.sourceType?"5module":5]);var s="";!0!==e.allowReserved&&(s=h[e.ecmaVersion>=6?6:5===e.ecmaVersion?5:3],"module"===e.sourceType&&(s+=" await")),this.reservedWords=R(s);var n=(s?s+" ":"")+h.strict;this.reservedWordsStrict=R(n),this.reservedWordsStrictBind=R(n+" "+h.strictBind),this.input=String(t),this.containsEsc=!1,i?(this.pos=i,this.lineStart=this.input.lastIndexOf("\n",i-1)+1,this.curLine=this.input.slice(0,this.lineStart).split(S).length):(this.pos=this.lineStart=0,this.curLine=1),this.type=_.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=[]},Q={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}};K.prototype.parse=function(){var e=this.options.program||this.startNode();return this.nextToken(),this.parseTopLevel(e)},Q.inFunction.get=function(){return(2&this.currentVarScope().flags)>0},Q.inGenerator.get=function(){return(8&this.currentVarScope().flags)>0},Q.inAsync.get=function(){return(4&this.currentVarScope().flags)>0},Q.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},Q.allowSuper.get=function(){return(64&this.currentThisScope().flags)>0||this.options.allowSuperOutsideMethod},Q.allowDirectSuper.get=function(){return(128&this.currentThisScope().flags)>0},Q.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())},Q.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},Q.inClassStaticBlock.get=function(){return(this.currentVarScope().flags&H)>0},K.extend=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];for(var i=this,s=0;s<e.length;s++)i=e[s](i);return i},K.parse=function(e,t){return new this(t,e).parse()},K.parseExpressionAt=function(e,t,i){var s=new this(i,e,t);return s.nextToken(),s.parseExpression()},K.tokenizer=function(e,t){return new this(t,e)},Object.defineProperties(K.prototype,Q);var Z=K.prototype,X=/^(?:'((?:\\[^]|[^'\\])*?)'|"((?:\\[^]|[^"\\])*?)")/;Z.strictDirective=function(e){if(this.options.ecmaVersion<5)return!1;for(;;){A.lastIndex=e,e+=A.exec(this.input)[0].length;var t=X.exec(this.input.slice(e));if(!t)return!1;if("use strict"===(t[1]||t[2])){A.lastIndex=e+t[0].length;var i=A.exec(this.input),s=i.index+i[0].length,n=this.input.charAt(s);return";"===n||"}"===n||S.test(i[0])&&!(/[(`.[+\-/*%<>=,?^&]/.test(n)||"!"===n&&"="===this.input.charAt(s+1))}e+=t[0].length,A.lastIndex=e,e+=A.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===_.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===_.eof||this.type===_.braceR||S.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(_.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 Y=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 i=t?e.parenthesizedAssign:e.parenthesizedBind;i>-1&&this.raiseRecoverable(i,t?"Assigning to rvalue":"Parenthesized pattern")}},Z.checkExpressionErrors=function(e,t){if(!e)return!1;var i=e.shorthandAssign,s=e.doubleProto;if(!t)return i>=0||s>=0;i>=0&&this.raise(i,"Shorthand property assignments are valid only in destructuring patterns"),s>=0&&this.raiseRecoverable(s,"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=K.prototype;J.parseTopLevel=function(e){var t=Object.create(null);for(e.body||(e.body=[]);this.type!==_.eof;){var i=this.parseStatement(null,!0,t);e.body.push(i)}if(this.inModule)for(var s=0,n=Object.keys(this.undefinedExports);s<n.length;s+=1){var r=n[s];this.raiseRecoverable(this.undefinedExports[r].start,"Export '"+r+"' is not defined")}return this.adaptDirectivePrologue(e.body),this.next(),e.sourceType=this.options.sourceType,this.finishNode(e,"Program")};var ee={kind:"loop"},te={kind:"switch"};J.isLet=function(e){if(this.options.ecmaVersion<6||!this.isContextual("let"))return!1;A.lastIndex=this.pos;var t=A.exec(this.input),i=this.pos+t[0].length,s=this.input.charCodeAt(i);if(91===s||92===s)return!0;if(e)return!1;if(123===s||s>55295&&s<56320)return!0;if(m(s,!0)){for(var n=i+1;g(s=this.input.charCodeAt(n),!0);)++n;if(92===s||s>55295&&s<56320)return!0;var r=this.input.slice(i,n);if(!u.test(r))return!0}return!1},J.isAsyncFunction=function(){if(this.options.ecmaVersion<8||!this.isContextual("async"))return!1;A.lastIndex=this.pos;var e,t=A.exec(this.input),i=this.pos+t[0].length;return!(S.test(this.input.slice(this.pos,i))||"function"!==this.input.slice(i,i+8)||i+8!==this.input.length&&(g(e=this.input.charCodeAt(i+8))||e>55295&&e<56320))},J.isUsingKeyword=function(e,t){if(this.options.ecmaVersion<17||!this.isContextual(e?"await":"using"))return!1;A.lastIndex=this.pos;var i=A.exec(this.input),s=this.pos+i[0].length;if(S.test(this.input.slice(this.pos,s)))return!1;if(e){var n,r=s+5;if("using"!==this.input.slice(s,r)||r===this.input.length||g(n=this.input.charCodeAt(r))||n>55295&&n<56320)return!1;A.lastIndex=r;var a=A.exec(this.input);if(a&&S.test(this.input.slice(r,r+a[0].length)))return!1}if(t){var o,h=s+2;if(!("of"!==this.input.slice(s,h)||h!==this.input.length&&(g(o=this.input.charCodeAt(h))||o>55295&&o<56320)))return!1}var p=this.input.charCodeAt(s);return m(p,!0)||92===p},J.isAwaitUsing=function(e){return this.isUsingKeyword(!0,e)},J.isUsing=function(e){return this.isUsingKeyword(!1,e)},J.parseStatement=function(e,t,i){var s,n=this.type,r=this.startNode();switch(this.isLet(e)&&(n=_._var,s="let"),n){case _._break:case _._continue:return this.parseBreakContinueStatement(r,n.keyword);case _._debugger:return this.parseDebuggerStatement(r);case _._do:return this.parseDoStatement(r);case _._for:return this.parseForStatement(r);case _._function:return e&&(this.strict||"if"!==e&&"label"!==e)&&this.options.ecmaVersion>=6&&this.unexpected(),this.parseFunctionStatement(r,!1,!e);case _._class:return e&&this.unexpected(),this.parseClass(r,!0);case _._if:return this.parseIfStatement(r);case _._return:return this.parseReturnStatement(r);case _._switch:return this.parseSwitchStatement(r);case _._throw:return this.parseThrowStatement(r);case _._try:return this.parseTryStatement(r);case _._const:case _._var:return s=s||this.value,e&&"var"!==s&&this.unexpected(),this.parseVarStatement(r,s);case _._while:return this.parseWhileStatement(r);case _._with:return this.parseWithStatement(r);case _.braceL:return this.parseBlock(!0,r);case _.semi:return this.parseEmptyStatement(r);case _._export:case _._import:if(this.options.ecmaVersion>10&&n===_._import){A.lastIndex=this.pos;var a=A.exec(this.input),o=this.pos+a[0].length,h=this.input.charCodeAt(o);if(40===h||46===h)return this.parseExpressionStatement(r,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'")),n===_._import?this.parseImport(r):this.parseExport(r,i);default:if(this.isAsyncFunction())return e&&this.unexpected(),this.next(),this.parseFunctionStatement(r,!0,!e);var p=this.isAwaitUsing(!1)?"await using":this.isUsing(!1)?"using":null;if(p)return t&&"script"===this.options.sourceType&&this.raise(this.start,"Using declaration cannot appear in the top level when source type is `script`"),"await using"===p&&(this.canAwait||this.raise(this.start,"Await using cannot appear outside of async function"),this.next()),this.next(),this.parseVar(r,!1,p),this.semicolon(),this.finishNode(r,"VariableDeclaration");var c=this.value,u=this.parseExpression();return n===_.name&&"Identifier"===u.type&&this.eat(_.colon)?this.parseLabeledStatement(r,c,u,e):this.parseExpressionStatement(r,u)}},J.parseBreakContinueStatement=function(e,t){var i="break"===t;this.next(),this.eat(_.semi)||this.insertSemicolon()?e.label=null:this.type!==_.name?this.unexpected():(e.label=this.parseIdent(),this.semicolon());for(var s=0;s<this.labels.length;++s){var n=this.labels[s];if(null==e.label||n.name===e.label.name){if(null!=n.kind&&(i||"loop"===n.kind))break;if(e.label&&i)break}}return s===this.labels.length&&this.raise(e.start,"Unsyntactic "+t),this.finishNode(e,i?"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(ee),e.body=this.parseStatement("do"),this.labels.pop(),this.expect(_._while),e.test=this.parseParenExpression(),this.options.ecmaVersion>=6?this.eat(_.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(ee),this.enterScope(0),this.expect(_.parenL),this.type===_.semi)return t>-1&&this.unexpected(t),this.parseFor(e,null);var i=this.isLet();if(this.type===_._var||this.type===_._const||i){var s=this.startNode(),n=i?"let":this.value;return this.next(),this.parseVar(s,!0,n),this.finishNode(s,"VariableDeclaration"),this.parseForAfterInit(e,s,t)}var r=this.isContextual("let"),a=!1,o=this.isUsing(!0)?"using":this.isAwaitUsing(!0)?"await using":null;if(o){var h=this.startNode();return this.next(),"await using"===o&&this.next(),this.parseVar(h,!0,o),this.finishNode(h,"VariableDeclaration"),this.parseForAfterInit(e,h,t)}var p=this.containsEsc,c=new Y,u=this.start,d=t>-1?this.parseExprSubscripts(c,"await"):this.parseExpression(!0,c);return this.type===_._in||(a=this.options.ecmaVersion>=6&&this.isContextual("of"))?(t>-1?(this.type===_._in&&this.unexpected(t),e.await=!0):a&&this.options.ecmaVersion>=8&&(d.start!==u||p||"Identifier"!==d.type||"async"!==d.name?this.options.ecmaVersion>=9&&(e.await=!1):this.unexpected()),r&&a&&this.raise(d.start,"The left-hand side of a for-of loop may not start with 'let'."),this.toAssignable(d,!1,c),this.checkLValPattern(d),this.parseForIn(e,d)):(this.checkExpressionErrors(c,!0),t>-1&&this.unexpected(t),this.parseFor(e,d))},J.parseForAfterInit=function(e,t,i){return(this.type===_._in||this.options.ecmaVersion>=6&&this.isContextual("of"))&&1===t.declarations.length?(this.options.ecmaVersion>=9&&(this.type===_._in?i>-1&&this.unexpected(i):e.await=i>-1),this.parseForIn(e,t)):(i>-1&&this.unexpected(i),this.parseFor(e,t))},J.parseFunctionStatement=function(e,t,i){return this.next(),this.parseFunction(e,se|(i?0:ne),!1,t)},J.parseIfStatement=function(e){return this.next(),e.test=this.parseParenExpression(),e.consequent=this.parseStatement("if"),e.alternate=this.eat(_._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(_.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(_.braceL),this.labels.push(te),this.enterScope(0);for(var i=!1;this.type!==_.braceR;)if(this.type===_._case||this.type===_._default){var s=this.type===_._case;t&&this.finishNode(t,"SwitchCase"),e.cases.push(t=this.startNode()),t.consequent=[],this.next(),s?t.test=this.parseExpression():(i&&this.raiseRecoverable(this.lastTokStart,"Multiple default clauses"),i=!0,t.test=null),this.expect(_.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(),S.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 ie=[];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(_.parenR),e},J.parseTryStatement=function(e){if(this.next(),e.block=this.parseBlock(),e.handler=null,this.type===_._catch){var t=this.startNode();this.next(),this.eat(_.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(_._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,i){return this.next(),this.parseVar(e,!1,t,i),this.semicolon(),this.finishNode(e,"VariableDeclaration")},J.parseWhileStatement=function(e){return this.next(),e.test=this.parseParenExpression(),this.labels.push(ee),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,i,s){for(var n=0,r=this.labels;n<r.length;n+=1){r[n].name===t&&this.raise(i.start,"Label '"+t+"' is already declared")}for(var a=this.type.isLoop?"loop":this.type===_._switch?"switch":null,o=this.labels.length-1;o>=0;o--){var h=this.labels[o];if(h.statementStart!==e.start)break;h.statementStart=this.start,h.kind=a}return this.labels.push({name:t,kind:a,statementStart:this.start}),e.body=this.parseStatement(s?-1===s.indexOf("label")?s+"label":s:"label"),this.labels.pop(),e.label=i,this.finishNode(e,"LabeledStatement")},J.parseExpressionStatement=function(e,t){return e.expression=t,this.semicolon(),this.finishNode(e,"ExpressionStatement")},J.parseBlock=function(e,t,i){for(void 0===e&&(e=!0),void 0===t&&(t=this.startNode()),t.body=[],this.expect(_.braceL),e&&this.enterScope(0);this.type!==_.braceR;){var s=this.parseStatement(null);t.body.push(s)}return i&&(this.strict=!1),this.next(),e&&this.exitScope(),this.finishNode(t,"BlockStatement")},J.parseFor=function(e,t){return e.init=t,this.expect(_.semi),e.test=this.type===_.semi?null:this.parseExpression(),this.expect(_.semi),e.update=this.type===_.parenR?null:this.parseExpression(),this.expect(_.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,"ForStatement")},J.parseForIn=function(e,t){var i=this.type===_._in;return this.next(),"VariableDeclaration"===t.type&&null!=t.declarations[0].init&&(!i||this.options.ecmaVersion<8||this.strict||"var"!==t.kind||"Identifier"!==t.declarations[0].id.type)&&this.raise(t.start,(i?"for-in":"for-of")+" loop variable declaration may not have an initializer"),e.left=t,e.right=i?this.parseExpression():this.parseMaybeAssign(),this.expect(_.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,i?"ForInStatement":"ForOfStatement")},J.parseVar=function(e,t,i,s){for(e.declarations=[],e.kind=i;;){var n=this.startNode();if(this.parseVarId(n,i),this.eat(_.eq)?n.init=this.parseMaybeAssign(t):s||"const"!==i||this.type===_._in||this.options.ecmaVersion>=6&&this.isContextual("of")?s||"using"!==i&&"await using"!==i||!(this.options.ecmaVersion>=17)||this.type===_._in||this.isContextual("of")?s||"Identifier"===n.id.type||t&&(this.type===_._in||this.isContextual("of"))?n.init=null:this.raise(this.lastTokEnd,"Complex binding patterns require an initialization value"):this.raise(this.lastTokEnd,"Missing initializer in "+i+" declaration"):this.unexpected(),e.declarations.push(this.finishNode(n,"VariableDeclarator")),!this.eat(_.comma))break}return e},J.parseVarId=function(e,t){e.id="using"===t||"await using"===t?this.parseIdent():this.parseBindingAtom(),this.checkLValPattern(e.id,"var"===t?1:2,!1)};var se=1,ne=2;function re(e,t){var i=t.key.name,s=e[i],n="true";return"MethodDefinition"!==t.type||"get"!==t.kind&&"set"!==t.kind||(n=(t.static?"s":"i")+t.kind),"iget"===s&&"iset"===n||"iset"===s&&"iget"===n||"sget"===s&&"sset"===n||"sset"===s&&"sget"===n?(e[i]="true",!1):!!s||(e[i]=n,!1)}function ae(e,t){var i=e.computed,s=e.key;return!i&&("Identifier"===s.type&&s.name===t||"Literal"===s.type&&s.value===t)}J.parseFunction=function(e,t,i,s,n){this.initFunction(e),(this.options.ecmaVersion>=9||this.options.ecmaVersion>=6&&!s)&&(this.type===_.star&&t&ne&&this.unexpected(),e.generator=this.eat(_.star)),this.options.ecmaVersion>=8&&(e.async=!!s),t&se&&(e.id=4&t&&this.type!==_.name?null:this.parseIdent(),!e.id||t&ne||this.checkLValSimple(e.id,this.strict||e.generator||e.async?this.treatFunctionsAsVar?1:2:3));var r=this.yieldPos,a=this.awaitPos,o=this.awaitIdentPos;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(G(e.async,e.generator)),t&se||(e.id=this.type===_.name?this.parseIdent():null),this.parseFunctionParams(e),this.parseFunctionBody(e,i,!1,n),this.yieldPos=r,this.awaitPos=a,this.awaitIdentPos=o,this.finishNode(e,t&se?"FunctionDeclaration":"FunctionExpression")},J.parseFunctionParams=function(e){this.expect(_.parenL),e.params=this.parseBindingList(_.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()},J.parseClass=function(e,t){this.next();var i=this.strict;this.strict=!0,this.parseClassId(e,t),this.parseClassSuper(e);var s=this.enterClassBody(),n=this.startNode(),r=!1;for(n.body=[],this.expect(_.braceL);this.type!==_.braceR;){var a=this.parseClassElement(null!==e.superClass);a&&(n.body.push(a),"MethodDefinition"===a.type&&"constructor"===a.kind?(r&&this.raiseRecoverable(a.start,"Duplicate constructor in the same class"),r=!0):a.key&&"PrivateIdentifier"===a.key.type&&re(s,a)&&this.raiseRecoverable(a.key.start,"Identifier '#"+a.key.name+"' has already been declared"))}return this.strict=i,this.next(),e.body=this.finishNode(n,"ClassBody"),this.exitClassBody(),this.finishNode(e,t?"ClassDeclaration":"ClassExpression")},J.parseClassElement=function(e){if(this.eat(_.semi))return null;var t=this.options.ecmaVersion,i=this.startNode(),s="",n=!1,r=!1,a="method",o=!1;if(this.eatContextual("static")){if(t>=13&&this.eat(_.braceL))return this.parseClassStaticBlock(i),i;this.isClassElementNameStart()||this.type===_.star?o=!0:s="static"}if(i.static=o,!s&&t>=8&&this.eatContextual("async")&&(!this.isClassElementNameStart()&&this.type!==_.star||this.canInsertSemicolon()?s="async":r=!0),!s&&(t>=9||!r)&&this.eat(_.star)&&(n=!0),!s&&!r&&!n){var h=this.value;(this.eatContextual("get")||this.eatContextual("set"))&&(this.isClassElementNameStart()?a=h:s=h)}if(s?(i.computed=!1,i.key=this.startNodeAt(this.lastTokStart,this.lastTokStartLoc),i.key.name=s,this.finishNode(i.key,"Identifier")):this.parseClassElementName(i),t<13||this.type===_.parenL||"method"!==a||n||r){var p=!i.static&&ae(i,"constructor"),c=p&&e;p&&"method"!==a&&this.raise(i.key.start,"Constructor can't have get/set modifier"),i.kind=p?"constructor":a,this.parseClassMethod(i,n,r,c)}else this.parseClassField(i);return i},J.isClassElementNameStart=function(){return this.type===_.name||this.type===_.privateId||this.type===_.num||this.type===_.string||this.type===_.bracketL||this.type.keyword},J.parseClassElementName=function(e){this.type===_.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,i,s){var n=e.key;"constructor"===e.kind?(t&&this.raise(n.start,"Constructor can't be a generator"),i&&this.raise(n.start,"Constructor can't be an async method")):e.static&&ae(e,"prototype")&&this.raise(n.start,"Classes may not have a static property named prototype");var r=e.value=this.parseMethod(t,i,s);return"get"===e.kind&&0!==r.params.length&&this.raiseRecoverable(r.start,"getter should have no params"),"set"===e.kind&&1!==r.params.length&&this.raiseRecoverable(r.start,"setter should have exactly one param"),"set"===e.kind&&"RestElement"===r.params[0].type&&this.raiseRecoverable(r.params[0].start,"Setter cannot use rest params"),this.finishNode(e,"MethodDefinition")},J.parseClassField=function(e){return ae(e,"constructor")?this.raise(e.key.start,"Classes can't have a field named 'constructor'"):e.static&&ae(e,"prototype")&&this.raise(e.key.start,"Classes can't have a static field named 'prototype'"),this.eat(_.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!==_.braceR;){var i=this.parseStatement(null);e.body.push(i)}return this.next(),this.exitScope(),this.labels=t,this.finishNode(e,"StaticBlock")},J.parseClassId=function(e,t){this.type===_.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(_._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,i=e.used;if(this.options.checkPrivateFields)for(var s=this.privateNameStack.length,n=0===s?null:this.privateNameStack[s-1],r=0;r<i.length;++r){var a=i[r];D(t,a.name)||(n?n.used.push(a):this.raiseRecoverable(a.start,"Private field '#"+a.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!==_.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(_.star))return this.parseExportAllDeclaration(e,t);if(this.eat(_._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!==_.string&&this.unexpected(),e.source=this.parseExprAtom(),this.options.ecmaVersion>=16&&(e.attributes=this.parseWithClause());else{for(var i=0,s=e.specifiers;i<s.length;i+=1){var n=s[i];this.checkUnreserved(n.local),this.checkLocalExport(n.local),"Literal"===n.local.type&&this.raise(n.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===_._function||(e=this.isAsyncFunction())){var t=this.startNode();return this.next(),e&&this.next(),this.parseFunction(t,4|se,!1,e)}if(this.type===_._class){var i=this.startNode();return this.parseClass(i,"nullableID")}var s=this.parseMaybeAssign();return this.semicolon(),s},J.checkExport=function(e,t,i){e&&("string"!=typeof t&&(t="Identifier"===t.type?t.name:t.value),D(e,t)&&this.raiseRecoverable(i,"Duplicate export '"+t+"'"),e[t]=!0)},J.checkPatternExport=function(e,t){var i=t.type;if("Identifier"===i)this.checkExport(e,t,t.start);else if("ObjectPattern"===i)for(var s=0,n=t.properties;s<n.length;s+=1){var r=n[s];this.checkPatternExport(e,r)}else if("ArrayPattern"===i)for(var a=0,o=t.elements;a<o.length;a+=1){var h=o[a];h&&this.checkPatternExport(e,h)}else"Property"===i?this.checkPatternExport(e,t.value):"AssignmentPattern"===i?this.checkPatternExport(e,t.left):"RestElement"===i&&this.checkPatternExport(e,t.argument)},J.checkVariableExport=function(e,t){if(e)for(var i=0,s=t;i<s.length;i+=1){var n=s[i];this.checkPatternExport(e,n.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=[],i=!0;for(this.expect(_.braceL);!this.eat(_.braceR);){if(i)i=!1;else if(this.expect(_.comma),this.afterTrailingComma(_.braceR))break;t.push(this.parseExportSpecifier(e))}return t},J.parseImport=function(e){return this.next(),this.type===_.string?(e.specifiers=ie,e.source=this.parseExprAtom()):(e.specifiers=this.parseImportSpecifiers(),this.expectContextual("from"),e.source=this.type===_.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===_.name&&(e.push(this.parseImportDefaultSpecifier()),!this.eat(_.comma)))return e;if(this.type===_.star)return e.push(this.parseImportNamespaceSpecifier()),e;for(this.expect(_.braceL);!this.eat(_.braceR);){if(t)t=!1;else if(this.expect(_.comma),this.afterTrailingComma(_.braceR))break;e.push(this.parseImportSpecifier())}return e},J.parseWithClause=function(){var e=[];if(!this.eat(_._with))return e;this.expect(_.braceL);for(var t={},i=!0;!this.eat(_.braceR);){if(i)i=!1;else if(this.expect(_.comma),this.afterTrailingComma(_.braceR))break;var s=this.parseImportAttribute(),n="Identifier"===s.key.type?s.key.name:s.key.value;D(t,n)&&this.raiseRecoverable(s.key.start,"Duplicate attribute key '"+n+"'"),t[n]=!0,e.push(s)}return e},J.parseImportAttribute=function(){var e=this.startNode();return e.key=this.type===_.string?this.parseExprAtom():this.parseIdent("never"!==this.options.allowReserved),this.expect(_.colon),this.type!==_.string&&this.unexpected(),e.value=this.parseExprAtom(),this.finishNode(e,"ImportAttribute")},J.parseModuleExportName=function(){if(this.options.ecmaVersion>=13&&this.type===_.string){var e=this.parseLiteral(this.value);return F.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 oe=K.prototype;oe.toAssignable=function(e,t,i){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",i&&this.checkPatternErrors(i,!0);for(var s=0,n=e.properties;s<n.length;s+=1){var r=n[s];this.toAssignable(r,t),"RestElement"!==r.type||"ArrayPattern"!==r.argument.type&&"ObjectPattern"!==r.argument.type||this.raise(r.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",i&&this.checkPatternErrors(i,!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,i);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 i&&this.checkPatternErrors(i,!0);return e},oe.toAssignableList=function(e,t){for(var i=e.length,s=0;s<i;s++){var n=e[s];n&&this.toAssignable(n,t)}if(i){var r=e[i-1];6===this.options.ecmaVersion&&t&&r&&"RestElement"===r.type&&"Identifier"!==r.argument.type&&this.unexpected(r.argument.start)}return e},oe.parseSpread=function(e){var t=this.startNode();return this.next(),t.argument=this.parseMaybeAssign(!1,e),this.finishNode(t,"SpreadElement")},oe.parseRestBinding=function(){var e=this.startNode();return this.next(),6===this.options.ecmaVersion&&this.type!==_.name&&this.unexpected(),e.argument=this.parseBindingAtom(),this.finishNode(e,"RestElement")},oe.parseBindingAtom=function(){if(this.options.ecmaVersion>=6)switch(this.type){case _.bracketL:var e=this.startNode();return this.next(),e.elements=this.parseBindingList(_.bracketR,!0,!0),this.finishNode(e,"ArrayPattern");case _.braceL:return this.parseObj(!0)}return this.parseIdent()},oe.parseBindingList=function(e,t,i,s){for(var n=[],r=!0;!this.eat(e);)if(r?r=!1:this.expect(_.comma),t&&this.type===_.comma)n.push(null);else{if(i&&this.afterTrailingComma(e))break;if(this.type===_.ellipsis){var a=this.parseRestBinding();this.parseBindingListItem(a),n.push(a),this.type===_.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.expect(e);break}n.push(this.parseAssignableListItem(s))}return n},oe.parseAssignableListItem=function(e){var t=this.parseMaybeDefault(this.start,this.startLoc);return this.parseBindingListItem(t),t},oe.parseBindingListItem=function(e){return e},oe.parseMaybeDefault=function(e,t,i){if(i=i||this.parseBindingAtom(),this.options.ecmaVersion<6||!this.eat(_.eq))return i;var s=this.startNodeAt(e,t);return s.left=i,s.right=this.parseMaybeAssign(),this.finishNode(s,"AssignmentPattern")},oe.checkLValSimple=function(e,t,i){void 0===t&&(t=0);var s=0!==t;switch(e.type){case"Identifier":this.strict&&this.reservedWordsStrictBind.test(e.name)&&this.raiseRecoverable(e.start,(s?"Binding ":"Assigning to ")+e.name+" in strict mode"),s&&(2===t&&"let"===e.name&&this.raiseRecoverable(e.start,"let is disallowed as a lexically bound name"),i&&(D(i,e.name)&&this.raiseRecoverable(e.start,"Argument name clash"),i[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":s&&this.raiseRecoverable(e.start,"Binding member expression");break;case"ParenthesizedExpression":return s&&this.raiseRecoverable(e.start,"Binding parenthesized expression"),this.checkLValSimple(e.expression,t,i);default:this.raise(e.start,(s?"Binding":"Assigning to")+" rvalue")}},oe.checkLValPattern=function(e,t,i){switch(void 0===t&&(t=0),e.type){case"ObjectPattern":for(var s=0,n=e.properties;s<n.length;s+=1){var r=n[s];this.checkLValInnerPattern(r,t,i)}break;case"ArrayPattern":for(var a=0,o=e.elements;a<o.length;a+=1){var h=o[a];h&&this.checkLValInnerPattern(h,t,i)}break;default:this.checkLValSimple(e,t,i)}},oe.checkLValInnerPattern=function(e,t,i){switch(void 0===t&&(t=0),e.type){case"Property":this.checkLValInnerPattern(e.value,t,i);break;case"AssignmentPattern":this.checkLValPattern(e.left,t,i);break;case"RestElement":this.checkLValPattern(e.argument,t,i);break;default:this.checkLValPattern(e,t,i)}};var he=function(e,t,i,s,n){this.token=e,this.isExpr=!!t,this.preserveSpace=!!i,this.override=s,this.generator=!!n},pe={b_stat:new he("{",!1),b_expr:new he("{",!0),b_tmpl:new he("${",!1),p_stat:new he("(",!1),p_expr:new he("(",!0),q_tmpl:new he("`",!0,!0,function(e){return e.tryReadTemplateToken()}),f_stat:new he("function",!1),f_expr:new he("function",!0),f_expr_gen:new he("function",!0,!1,null,!0),f_gen:new he("function",!1,!1,null,!0)},ce=K.prototype;ce.initialContext=function(){return[pe.b_stat]},ce.curContext=function(){return this.context[this.context.length-1]},ce.braceIsBlock=function(e){var t=this.curContext();return t===pe.f_expr||t===pe.f_stat||(e!==_.colon||t!==pe.b_stat&&t!==pe.b_expr?e===_._return||e===_.name&&this.exprAllowed?S.test(this.input.slice(this.lastTokEnd,this.start)):e===_._else||e===_.semi||e===_.eof||e===_.parenR||e===_.arrow||(e===_.braceL?t===pe.b_stat:e!==_._var&&e!==_._const&&e!==_.name&&!this.exprAllowed):!t.isExpr)},ce.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},ce.updateContext=function(e){var t,i=this.type;i.keyword&&e===_.dot?this.exprAllowed=!1:(t=i.updateContext)?t.call(this,e):this.exprAllowed=i.beforeExpr},ce.overrideContext=function(e){this.curContext()!==e&&(this.context[this.context.length-1]=e)},_.parenR.updateContext=_.braceR.updateContext=function(){if(1!==this.context.length){var e=this.context.pop();e===pe.b_stat&&"function"===this.curContext().token&&(e=this.context.pop()),this.exprAllowed=!e.isExpr}else this.exprAllowed=!0},_.braceL.updateContext=function(e){this.context.push(this.braceIsBlock(e)?pe.b_stat:pe.b_expr),this.exprAllowed=!0},_.dollarBraceL.updateContext=function(){this.context.push(pe.b_tmpl),this.exprAllowed=!0},_.parenL.updateContext=function(e){var t=e===_._if||e===_._for||e===_._with||e===_._while;this.context.push(t?pe.p_stat:pe.p_expr),this.exprAllowed=!0},_.incDec.updateContext=function(){},_._function.updateContext=_._class.updateContext=function(e){!e.beforeExpr||e===_._else||e===_.semi&&this.curContext()!==pe.p_stat||e===_._return&&S.test(this.input.slice(this.lastTokEnd,this.start))||(e===_.colon||e===_.braceL)&&this.curContext()===pe.b_stat?this.context.push(pe.f_stat):this.context.push(pe.f_expr),this.exprAllowed=!1},_.colon.updateContext=function(){"function"===this.curContext().token&&this.context.pop(),this.exprAllowed=!0},_.backQuote.updateContext=function(){this.curContext()===pe.q_tmpl?this.context.pop():this.context.push(pe.q_tmpl),this.exprAllowed=!1},_.star.updateContext=function(e){if(e===_._function){var t=this.context.length-1;this.context[t]===pe.f_expr?this.context[t]=pe.f_expr_gen:this.context[t]=pe.f_gen}this.exprAllowed=!0},_.name.updateContext=function(e){var t=!1;this.options.ecmaVersion>=6&&e!==_.dot&&("of"===this.value&&!this.exprAllowed||"yield"===this.value&&this.inGeneratorContext())&&(t=!0),this.exprAllowed=t};var ue=K.prototype;function de(e){return"Identifier"===e.type||"ParenthesizedExpression"===e.type&&de(e.expression)}function le(e){return"MemberExpression"===e.type&&"PrivateIdentifier"===e.property.type||"ChainExpression"===e.type&&le(e.expression)||"ParenthesizedExpression"===e.type&&le(e.expression)}ue.checkPropClash=function(e,t,i){if(!(this.options.ecmaVersion>=9&&"SpreadElement"===e.type||this.options.ecmaVersion>=6&&(e.computed||e.method||e.shorthand))){var s,n=e.key;switch(n.type){case"Identifier":s=n.name;break;case"Literal":s=String(n.value);break;default:return}var r=e.kind;if(this.options.ecmaVersion>=6)"__proto__"===s&&"init"===r&&(t.proto&&(i?i.doubleProto<0&&(i.doubleProto=n.start):this.raiseRecoverable(n.start,"Redefinition of __proto__ property")),t.proto=!0);else{var a=t[s="$"+s];if(a)("init"===r?this.strict&&a.init||a.get||a.set:a.init||a[r])&&this.raiseRecoverable(n.start,"Redefinition of property");else a=t[s]={init:!1,get:!1,set:!1};a[r]=!0}}},ue.parseExpression=function(e,t){var i=this.start,s=this.startLoc,n=this.parseMaybeAssign(e,t);if(this.type===_.comma){var r=this.startNodeAt(i,s);for(r.expressions=[n];this.eat(_.comma);)r.expressions.push(this.parseMaybeAssign(e,t));return this.finishNode(r,"SequenceExpression")}return n},ue.parseMaybeAssign=function(e,t,i){if(this.isContextual("yield")){if(this.inGenerator)return this.parseYield(e);this.exprAllowed=!1}var s=!1,n=-1,r=-1,a=-1;t?(n=t.parenthesizedAssign,r=t.trailingComma,a=t.doubleProto,t.parenthesizedAssign=t.trailingComma=-1):(t=new Y,s=!0);var o=this.start,h=this.startLoc;this.type!==_.parenL&&this.type!==_.name||(this.potentialArrowAt=this.start,this.potentialArrowInForAwait="await"===e);var p=this.parseMaybeConditional(e,t);if(i&&(p=i.call(this,p,o,h)),this.type.isAssign){var c=this.startNodeAt(o,h);return c.operator=this.value,this.type===_.eq&&(p=this.toAssignable(p,!1,t)),s||(t.parenthesizedAssign=t.trailingComma=t.doubleProto=-1),t.shorthandAssign>=p.start&&(t.shorthandAssign=-1),this.type===_.eq?this.checkLValPattern(p):this.checkLValSimple(p),c.left=p,this.next(),c.right=this.parseMaybeAssign(e),a>-1&&(t.doubleProto=a),this.finishNode(c,"AssignmentExpression")}return s&&this.checkExpressionErrors(t,!0),n>-1&&(t.parenthesizedAssign=n),r>-1&&(t.trailingComma=r),p},ue.parseMaybeConditional=function(e,t){var i=this.start,s=this.startLoc,n=this.parseExprOps(e,t);if(this.checkExpressionErrors(t))return n;if(this.eat(_.question)){var r=this.startNodeAt(i,s);return r.test=n,r.consequent=this.parseMaybeAssign(),this.expect(_.colon),r.alternate=this.parseMaybeAssign(e),this.finishNode(r,"ConditionalExpression")}return n},ue.parseExprOps=function(e,t){var i=this.start,s=this.startLoc,n=this.parseMaybeUnary(t,!1,!1,e);return this.checkExpressionErrors(t)||n.start===i&&"ArrowFunctionExpression"===n.type?n:this.parseExprOp(n,i,s,-1,e)},ue.parseExprOp=function(e,t,i,s,n){var r=this.type.binop;if(null!=r&&(!n||this.type!==_._in)&&r>s){var a=this.type===_.logicalOR||this.type===_.logicalAND,o=this.type===_.coalesce;o&&(r=_.logicalAND.binop);var h=this.value;this.next();var p=this.start,c=this.startLoc,u=this.parseExprOp(this.parseMaybeUnary(null,!1,!1,n),p,c,r,n),d=this.buildBinary(t,i,e,u,h,a||o);return(a&&this.type===_.coalesce||o&&(this.type===_.logicalOR||this.type===_.logicalAND))&&this.raiseRecoverable(this.start,"Logical expressions and coalesce expressions cannot be mixed. Wrap either by parentheses"),this.parseExprOp(d,t,i,s,n)}return e},ue.buildBinary=function(e,t,i,s,n,r){"PrivateIdentifier"===s.type&&this.raise(s.start,"Private identifier can only be left side of binary expression");var a=this.startNodeAt(e,t);return a.left=i,a.operator=n,a.right=s,this.finishNode(a,r?"LogicalExpression":"BinaryExpression")},ue.parseMaybeUnary=function(e,t,i,s){var n,r=this.start,a=this.startLoc;if(this.isContextual("await")&&this.canAwait)n=this.parseAwait(s),t=!0;else if(this.type.prefix){var o=this.startNode(),h=this.type===_.incDec;o.operator=this.value,o.prefix=!0,this.next(),o.argument=this.parseMaybeUnary(null,!0,h,s),this.checkExpressionErrors(e,!0),h?this.checkLValSimple(o.argument):this.strict&&"delete"===o.operator&&de(o.argument)?this.raiseRecoverable(o.start,"Deleting local variable in strict mode"):"delete"===o.operator&&le(o.argument)?this.raiseRecoverable(o.start,"Private fields can not be deleted"):t=!0,n=this.finishNode(o,h?"UpdateExpression":"UnaryExpression")}else if(t||this.type!==_.privateId){if(n=this.parseExprSubscripts(e,s),this.checkExpressionErrors(e))return n;for(;this.type.postfix&&!this.canInsertSemicolon();){var p=this.startNodeAt(r,a);p.operator=this.value,p.prefix=!1,p.argument=n,this.checkLValSimple(n),this.next(),n=this.finishNode(p,"UpdateExpression")}}else(s||0===this.privateNameStack.length)&&this.options.checkPrivateFields&&this.unexpected(),n=this.parsePrivateIdent(),this.type!==_._in&&this.unexpected();return i||!this.eat(_.starstar)?n:t?void this.unexpected(this.lastTokStart):this.buildBinary(r,a,n,this.parseMaybeUnary(null,!1,!1,s),"**",!1)},ue.parseExprSubscripts=function(e,t){var i=this.start,s=this.startLoc,n=this.parseExprAtom(e,t);if("ArrowFunctionExpression"===n.type&&")"!==this.input.slice(this.lastTokStart,this.lastTokEnd))return n;var r=this.parseSubscripts(n,i,s,!1,t);return e&&"MemberExpression"===r.type&&(e.parenthesizedAssign>=r.start&&(e.parenthesizedAssign=-1),e.parenthesizedBind>=r.start&&(e.parenthesizedBind=-1),e.trailingComma>=r.start&&(e.trailingComma=-1)),r},ue.parseSubscripts=function(e,t,i,s,n){for(var r=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,a=!1;;){var o=this.parseSubscript(e,t,i,s,r,a,n);if(o.optional&&(a=!0),o===e||"ArrowFunctionExpression"===o.type){if(a){var h=this.startNodeAt(t,i);h.expression=o,o=this.finishNode(h,"ChainExpression")}return o}e=o}},ue.shouldParseAsyncArrow=function(){return!this.canInsertSemicolon()&&this.eat(_.arrow)},ue.parseSubscriptAsyncArrow=function(e,t,i,s){return this.parseArrowExpression(this.startNodeAt(e,t),i,!0,s)},ue.parseSubscript=function(e,t,i,s,n,r,a){var o=this.options.ecmaVersion>=11,h=o&&this.eat(_.questionDot);s&&h&&this.raise(this.lastTokStart,"Optional chaining cannot appear in the callee of new expressions");var p=this.eat(_.bracketL);if(p||h&&this.type!==_.parenL&&this.type!==_.backQuote||this.eat(_.dot)){var c=this.startNodeAt(t,i);c.object=e,p?(c.property=this.parseExpression(),this.expect(_.bracketR)):this.type===_.privateId&&"Super"!==e.type?c.property=this.parsePrivateIdent():c.property=this.parseIdent("never"!==this.options.allowReserved),c.computed=!!p,o&&(c.optional=h),e=this.finishNode(c,"MemberExpression")}else if(!s&&this.eat(_.parenL)){var u=new Y,d=this.yieldPos,l=this.awaitPos,f=this.awaitIdentPos;this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0;var m=this.parseExprList(_.parenR,this.options.ecmaVersion>=8,!1,u);if(n&&!h&&this.shouldParseAsyncArrow())return this.checkPatternErrors(u,!1),this.checkYieldAwaitInDefaultParams(),this.awaitIdentPos>0&&this.raise(this.awaitIdentPos,"Cannot use 'await' as identifier inside an async function"),this.yieldPos=d,this.awaitPos=l,this.awaitIdentPos=f,this.parseSubscriptAsyncArrow(t,i,m,a);this.checkExpressionErrors(u,!0),this.yieldPos=d||this.yieldPos,this.awaitPos=l||this.awaitPos,this.awaitIdentPos=f||this.awaitIdentPos;var g=this.startNodeAt(t,i);g.callee=e,g.arguments=m,o&&(g.optional=h),e=this.finishNode(g,"CallExpression")}else if(this.type===_.backQuote){(h||r)&&this.raise(this.start,"Optional chaining cannot appear in the tag of tagged template expressions");var v=this.startNodeAt(t,i);v.tag=e,v.quasi=this.parseTemplate({isTagged:!0}),e=this.finishNode(v,"TaggedTemplateExpression")}return e},ue.parseExprAtom=function(e,t,i){this.type===_.slash&&this.readRegexp();var s,n=this.potentialArrowAt===this.start;switch(this.type){case _._super:return this.allowSuper||this.raise(this.start,"'super' keyword outside a method"),s=this.startNode(),this.next(),this.type!==_.parenL||this.allowDirectSuper||this.raise(s.start,"super() call outside constructor of a subclass"),this.type!==_.dot&&this.type!==_.bracketL&&this.type!==_.parenL&&this.unexpected(),this.finishNode(s,"Super");case _._this:return s=this.startNode(),this.next(),this.finishNode(s,"ThisExpression");case _.name:var r=this.start,a=this.startLoc,o=this.containsEsc,h=this.parseIdent(!1);if(this.options.ecmaVersion>=8&&!o&&"async"===h.name&&!this.canInsertSemicolon()&&this.eat(_._function))return this.overrideContext(pe.f_expr),this.parseFunction(this.startNodeAt(r,a),0,!1,!0,t);if(n&&!this.canInsertSemicolon()){if(this.eat(_.arrow))return this.parseArrowExpression(this.startNodeAt(r,a),[h],!1,t);if(this.options.ecmaVersion>=8&&"async"===h.name&&this.type===_.name&&!o&&(!this.potentialArrowInForAwait||"of"!==this.value||this.containsEsc))return h=this.parseIdent(!1),!this.canInsertSemicolon()&&this.eat(_.arrow)||this.unexpected(),this.parseArrowExpression(this.startNodeAt(r,a),[h],!0,t)}return h;case _.regexp:var p=this.value;return(s=this.parseLiteral(p.value)).regex={pattern:p.pattern,flags:p.flags},s;case _.num:case _.string:return this.parseLiteral(this.value);case _._null:case _._true:case _._false:return(s=this.startNode()).value=this.type===_._null?null:this.type===_._true,s.raw=this.type.keyword,this.next(),this.finishNode(s,"Literal");case _.parenL:var c=this.start,u=this.parseParenAndDistinguishExpression(n,t);return e&&(e.parenthesizedAssign<0&&!this.isSimpleAssignTarget(u)&&(e.parenthesizedAssign=c),e.parenthesizedBind<0&&(e.parenthesizedBind=c)),u;case _.bracketL:return s=this.startNode(),this.next(),s.elements=this.parseExprList(_.bracketR,!0,!0,e),this.finishNode(s,"ArrayExpression");case _.braceL:return this.overrideContext(pe.b_expr),this.parseObj(!1,e);case _._function:return s=this.startNode(),this.next(),this.parseFunction(s,0);case _._class:return this.parseClass(this.startNode(),!1);case _._new:return this.parseNew();case _.backQuote:return this.parseTemplate();case _._import:return this.options.ecmaVersion>=11?this.parseExprImport(i):this.unexpected();default:return this.parseExprAtomDefault()}},ue.parseExprAtomDefault=function(){this.unexpected()},ue.parseExprImport=function(e){var t=this.startNode();if(this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword import"),this.next(),this.type===_.parenL&&!e)return this.parseDynamicImport(t);if(this.type===_.dot){var i=this.startNodeAt(t.start,t.loc&&t.loc.start);return i.name="import",t.meta=this.finishNode(i,"Identifier"),this.parseImportMeta(t)}this.unexpected()},ue.parseDynamicImport=function(e){if(this.next(),e.source=this.parseMaybeAssign(),this.options.ecmaVersion>=16)this.eat(_.parenR)?e.options=null:(this.expect(_.comma),this.afterTrailingComma(_.parenR)?e.options=null:(e.options=this.parseMaybeAssign(),this.eat(_.parenR)||(this.expect(_.comma),this.afterTrailingComma(_.parenR)||this.unexpected())));else if(!this.eat(_.parenR)){var t=this.start;this.eat(_.comma)&&this.eat(_.parenR)?this.raiseRecoverable(t,"Trailing comma is not allowed in import()"):this.unexpected(t)}return this.finishNode(e,"ImportExpression")},ue.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")},ue.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=null!=t.value?t.value.toString():t.raw.slice(0,-1).replace(/_/g,"")),this.next(),this.finishNode(t,"Literal")},ue.parseParenExpression=function(){this.expect(_.parenL);var e=this.parseExpression();return this.expect(_.parenR),e},ue.shouldParseArrow=function(e){return!this.canInsertSemicolon()},ue.parseParenAndDistinguishExpression=function(e,t){var i,s=this.start,n=this.startLoc,r=this.options.ecmaVersion>=8;if(this.options.ecmaVersion>=6){this.next();var a,o=this.start,h=this.startLoc,p=[],c=!0,u=!1,d=new Y,l=this.yieldPos,f=this.awaitPos;for(this.yieldPos=0,this.awaitPos=0;this.type!==_.parenR;){if(c?c=!1:this.expect(_.comma),r&&this.afterTrailingComma(_.parenR,!0)){u=!0;break}if(this.type===_.ellipsis){a=this.start,p.push(this.parseParenItem(this.parseRestBinding())),this.type===_.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element");break}p.push(this.parseMaybeAssign(!1,d,this.parseParenItem))}var m=this.lastTokEnd,g=this.lastTokEndLoc;if(this.expect(_.parenR),e&&this.shouldParseArrow(p)&&this.eat(_.arrow))return this.checkPatternErrors(d,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=l,this.awaitPos=f,this.parseParenArrowList(s,n,p,t);p.length&&!u||this.unexpected(this.lastTokStart),a&&this.unexpected(a),this.checkExpressionErrors(d,!0),this.yieldPos=l||this.yieldPos,this.awaitPos=f||this.awaitPos,p.length>1?((i=this.startNodeAt(o,h)).expressions=p,this.finishNodeAt(i,"SequenceExpression",m,g)):i=p[0]}else i=this.parseParenExpression();if(this.options.preserveParens){var v=this.startNodeAt(s,n);return v.expression=i,this.finishNode(v,"ParenthesizedExpression")}return i},ue.parseParenItem=function(e){return e},ue.parseParenArrowList=function(e,t,i,s){return this.parseArrowExpression(this.startNodeAt(e,t),i,!1,s)};var fe=[];ue.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===_.dot){var t=this.startNodeAt(e.start,e.loc&&e.loc.start);t.name="new",e.meta=this.finishNode(t,"Identifier"),this.next();var i=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'"),i&&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 s=this.start,n=this.startLoc;return e.callee=this.parseSubscripts(this.parseExprAtom(null,!1,!0),s,n,!0,!1),this.eat(_.parenL)?e.arguments=this.parseExprList(_.parenR,this.options.ecmaVersion>=8,!1):e.arguments=fe,this.finishNode(e,"NewExpression")},ue.parseTemplateElement=function(e){var t=e.isTagged,i=this.startNode();return this.type===_.invalidTemplate?(t||this.raiseRecoverable(this.start,"Bad escape sequence in untagged template literal"),i.value={raw:this.value.replace(/\r\n?/g,"\n"),cooked:null}):i.value={raw:this.input.slice(this.start,this.end).replace(/\r\n?/g,"\n"),cooked:this.value},this.next(),i.tail=this.type===_.backQuote,this.finishNode(i,"TemplateElement")},ue.parseTemplate=function(e){void 0===e&&(e={});var t=e.isTagged;void 0===t&&(t=!1);var i=this.startNode();this.next(),i.expressions=[];var s=this.parseTemplateElement({isTagged:t});for(i.quasis=[s];!s.tail;)this.type===_.eof&&this.raise(this.pos,"Unterminated template literal"),this.expect(_.dollarBraceL),i.expressions.push(this.parseExpression()),this.expect(_.braceR),i.quasis.push(s=this.parseTemplateElement({isTagged:t}));return this.next(),this.finishNode(i,"TemplateLiteral")},ue.isAsyncProp=function(e){return!e.computed&&"Identifier"===e.key.type&&"async"===e.key.name&&(this.type===_.name||this.type===_.num||this.type===_.string||this.type===_.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===_.star)&&!S.test(this.input.slice(this.lastTokEnd,this.start))},ue.parseObj=function(e,t){var i=this.startNode(),s=!0,n={};for(i.properties=[],this.next();!this.eat(_.braceR);){if(s)s=!1;else if(this.expect(_.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(_.braceR))break;var r=this.parseProperty(e,t);e||this.checkPropClash(r,n,t),i.properties.push(r)}return this.finishNode(i,e?"ObjectPattern":"ObjectExpression")},ue.parseProperty=function(e,t){var i,s,n,r,a=this.startNode();if(this.options.ecmaVersion>=9&&this.eat(_.ellipsis))return e?(a.argument=this.parseIdent(!1),this.type===_.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.finishNode(a,"RestElement")):(a.argument=this.parseMaybeAssign(!1,t),this.type===_.comma&&t&&t.trailingComma<0&&(t.trailingComma=this.start),this.finishNode(a,"SpreadElement"));this.options.ecmaVersion>=6&&(a.method=!1,a.shorthand=!1,(e||t)&&(n=this.start,r=this.startLoc),e||(i=this.eat(_.star)));var o=this.containsEsc;return this.parsePropertyName(a),!e&&!o&&this.options.ecmaVersion>=8&&!i&&this.isAsyncProp(a)?(s=!0,i=this.options.ecmaVersion>=9&&this.eat(_.star),this.parsePropertyName(a)):s=!1,this.parsePropertyValue(a,e,i,s,n,r,t,o),this.finishNode(a,"Property")},ue.parseGetterSetter=function(e){var t=e.key.name;this.parsePropertyName(e),e.value=this.parseMethod(!1),e.kind=t;var i="get"===e.kind?0:1;if(e.value.params.length!==i){var s=e.value.start;"get"===e.kind?this.raiseRecoverable(s,"getter should have no params"):this.raiseRecoverable(s,"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")},ue.parsePropertyValue=function(e,t,i,s,n,r,a,o){(i||s)&&this.type===_.colon&&this.unexpected(),this.eat(_.colon)?(e.value=t?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,a),e.kind="init"):this.options.ecmaVersion>=6&&this.type===_.parenL?(t&&this.unexpected(),e.method=!0,e.value=this.parseMethod(i,s),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===_.comma||this.type===_.braceR||this.type===_.eq?this.options.ecmaVersion>=6&&!e.computed&&"Identifier"===e.key.type?((i||s)&&this.unexpected(),this.checkUnreserved(e.key),"await"!==e.key.name||this.awaitIdentPos||(this.awaitIdentPos=n),t?e.value=this.parseMaybeDefault(n,r,this.copyNode(e.key)):this.type===_.eq&&a?(a.shorthandAssign<0&&(a.shorthandAssign=this.start),e.value=this.parseMaybeDefault(n,r,this.copyNode(e.key))):e.value=this.copyNode(e.key),e.kind="init",e.shorthand=!0):this.unexpected():((i||s)&&this.unexpected(),this.parseGetterSetter(e))},ue.parsePropertyName=function(e){if(this.options.ecmaVersion>=6){if(this.eat(_.bracketL))return e.computed=!0,e.key=this.parseMaybeAssign(),this.expect(_.bracketR),e.key;e.computed=!1}return e.key=this.type===_.num||this.type===_.string?this.parseExprAtom():this.parseIdent("never"!==this.options.allowReserved)},ue.initFunction=function(e){e.id=null,this.options.ecmaVersion>=6&&(e.generator=e.expression=!1),this.options.ecmaVersion>=8&&(e.async=!1)},ue.parseMethod=function(e,t,i){var s=this.startNode(),n=this.yieldPos,r=this.awaitPos,a=this.awaitIdentPos;return this.initFunction(s),this.options.ecmaVersion>=6&&(s.generator=e),this.options.ecmaVersion>=8&&(s.async=!!t),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(64|G(t,s.generator)|(i?128:0)),this.expect(_.parenL),s.params=this.parseBindingList(_.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(s,!1,!0,!1),this.yieldPos=n,this.awaitPos=r,this.awaitIdentPos=a,this.finishNode(s,"FunctionExpression")},ue.parseArrowExpression=function(e,t,i,s){var n=this.yieldPos,r=this.awaitPos,a=this.awaitIdentPos;return this.enterScope(16|G(i,!1)),this.initFunction(e),this.options.ecmaVersion>=8&&(e.async=!!i),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,e.params=this.toAssignableList(t,!0),this.parseFunctionBody(e,!0,!1,s),this.yieldPos=n,this.awaitPos=r,this.awaitIdentPos=a,this.finishNode(e,"ArrowFunctionExpression")},ue.parseFunctionBody=function(e,t,i,s){var n=t&&this.type!==_.braceL,r=this.strict,a=!1;if(n)e.body=this.parseMaybeAssign(s),e.expression=!0,this.checkParams(e,!1);else{var o=this.options.ecmaVersion>=7&&!this.isSimpleParamList(e.params);r&&!o||(a=this.strictDirective(this.end))&&o&&this.raiseRecoverable(e.start,"Illegal 'use strict' directive in function with non-simple parameter list");var h=this.labels;this.labels=[],a&&(this.strict=!0),this.checkParams(e,!r&&!a&&!t&&!i&&this.isSimpleParamList(e.params)),this.strict&&e.id&&this.checkLValSimple(e.id,5),e.body=this.parseBlock(!1,void 0,a&&!r),e.expression=!1,this.adaptDirectivePrologue(e.body.body),this.labels=h}this.exitScope()},ue.isSimpleParamList=function(e){for(var t=0,i=e;t<i.length;t+=1){if("Identifier"!==i[t].type)return!1}return!0},ue.checkParams=function(e,t){for(var i=Object.create(null),s=0,n=e.params;s<n.length;s+=1){var r=n[s];this.checkLValInnerPattern(r,1,t?null:i)}},ue.parseExprList=function(e,t,i,s){for(var n=[],r=!0;!this.eat(e);){if(r)r=!1;else if(this.expect(_.comma),t&&this.afterTrailingComma(e))break;var a=void 0;i&&this.type===_.comma?a=null:this.type===_.ellipsis?(a=this.parseSpread(s),s&&this.type===_.comma&&s.trailingComma<0&&(s.trailingComma=this.start)):a=this.parseMaybeAssign(!1,s),n.push(a)}return n},ue.checkUnreserved=function(e){var t=e.start,i=e.end,s=e.name;(this.inGenerator&&"yield"===s&&this.raiseRecoverable(t,"Cannot use 'yield' as identifier inside a generator"),this.inAsync&&"await"===s&&this.raiseRecoverable(t,"Cannot use 'await' as identifier inside an async function"),this.currentThisScope().flags&q||"arguments"!==s||this.raiseRecoverable(t,"Cannot use 'arguments' in class field initializer"),!this.inClassStaticBlock||"arguments"!==s&&"await"!==s||this.raise(t,"Cannot use "+s+" in class static initialization block"),this.keywords.test(s)&&this.raise(t,"Unexpected keyword '"+s+"'"),this.options.ecmaVersion<6&&-1!==this.input.slice(t,i).indexOf("\\"))||(this.strict?this.reservedWordsStrict:this.reservedWords).test(s)&&(this.inAsync||"await"!==s||this.raiseRecoverable(t,"Cannot use keyword 'await' outside an async function"),this.raiseRecoverable(t,"The keyword '"+s+"' is reserved"))},ue.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},ue.parseIdentNode=function(){var e=this.startNode();return this.type===_.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=_.name):this.unexpected(),e},ue.parsePrivateIdent=function(){var e=this.startNode();return this.type===_.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},ue.parseYield=function(e){this.yieldPos||(this.yieldPos=this.start);var t=this.startNode();return this.next(),this.type===_.semi||this.canInsertSemicolon()||this.type!==_.star&&!this.type.startsExpr?(t.delegate=!1,t.argument=null):(t.delegate=this.eat(_.star),t.argument=this.parseMaybeAssign(e)),this.finishNode(t,"YieldExpression")},ue.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 me=K.prototype;me.raise=function(e,t){var i=W(this.input,e);t+=" ("+i.line+":"+i.column+")",this.sourceFile&&(t+=" in "+this.sourceFile);var s=new SyntaxError(t);throw s.pos=e,s.loc=i,s.raisedAt=this.pos,s},me.raiseRecoverable=me.raise,me.curPosition=function(){if(this.options.locations)return new U(this.curLine,this.pos-this.lineStart)};var ge=K.prototype,ve=function(e){this.flags=e,this.var=[],this.lexical=[],this.functions=[]};ge.enterScope=function(e){this.scopeStack.push(new ve(e))},ge.exitScope=function(){this.scopeStack.pop()},ge.treatFunctionsAsVarInScope=function(e){return 2&e.flags||!this.inModule&&1&e.flags},ge.declareName=function(e,t,i){var s=!1;if(2===t){var n=this.currentScope();s=n.lexical.indexOf(e)>-1||n.functions.indexOf(e)>-1||n.var.indexOf(e)>-1,n.lexical.push(e),this.inModule&&1&n.flags&&delete this.undefinedExports[e]}else if(4===t){this.currentScope().lexical.push(e)}else if(3===t){var r=this.currentScope();s=this.treatFunctionsAsVar?r.lexical.indexOf(e)>-1:r.lexical.indexOf(e)>-1||r.var.indexOf(e)>-1,r.functions.push(e)}else for(var a=this.scopeStack.length-1;a>=0;--a){var o=this.scopeStack[a];if(o.lexical.indexOf(e)>-1&&!(32&o.flags&&o.lexical[0]===e)||!this.treatFunctionsAsVarInScope(o)&&o.functions.indexOf(e)>-1){s=!0;break}if(o.var.push(e),this.inModule&&1&o.flags&&delete this.undefinedExports[e],o.flags&q)break}s&&this.raiseRecoverable(i,"Identifier '"+e+"' has already been declared")},ge.checkLocalExport=function(e){-1===this.scopeStack[0].lexical.indexOf(e.name)&&-1===this.scopeStack[0].var.indexOf(e.name)&&(this.undefinedExports[e.name]=e)},ge.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]},ge.currentVarScope=function(){for(var e=this.scopeStack.length-1;;e--){var t=this.scopeStack[e];if(771&t.flags)return t}},ge.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 xe=function(e,t,i){this.type="",this.start=t,this.end=0,e.options.locations&&(this.loc=new B(e,i)),e.options.directSourceFile&&(this.sourceFile=e.options.directSourceFile),e.options.ranges&&(this.range=[t,0])},ye=K.prototype;function be(e,t,i,s){return e.type=t,e.end=i,this.options.locations&&(e.loc.end=s),this.options.ranges&&(e.range[1]=i),e}ye.startNode=function(){return new xe(this,this.start,this.startLoc)},ye.startNodeAt=function(e,t){return new xe(this,e,t)},ye.finishNode=function(e,t){return be.call(this,e,t,this.lastTokEnd,this.lastTokEndLoc)},ye.finishNodeAt=function(e,t,i,s){return be.call(this,e,t,i,s)},ye.copyNode=function(e){var t=new xe(this,e.start,this.startLoc);for(var i in e)t[i]=e[i];return t};var Ee="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",Ne=Ee+" Extended_Pictographic",_e=Ne+" EBase EComp EMod EPres ExtPict",Se={9:Ee,10:Ne,11:Ne,12:_e,13:_e,14:_e},we={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"},Ie="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",ke="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",Ce=ke+" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd",Ae=Ce+" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho",Ve=Ae+" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi",Pe=Ve+" Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith",Te={9:ke,10:Ce,11:Ae,12:Ve,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"},De={};function Le(e){var t=De[e]={binary:R(Se[e]+" "+Ie),binaryOfStrings:R(we[e]),nonBinary:{General_Category:R(Ie),Script:R(Te[e])}};t.nonBinary.Script_Extensions=t.nonBinary.Script,t.nonBinary.gc=t.nonBinary.General_Category,t.nonBinary.sc=t.nonBinary.Script,t.nonBinary.scx=t.nonBinary.Script_Extensions}for(var Me=0,Re=[9,10,11,12,13,14];Me<Re.length;Me+=1){Le(Re[Me])}var Oe=K.prototype,Fe=function(e,t){this.parent=e,this.base=t||this};Fe.prototype.separatedFrom=function(e){for(var t=this;t;t=t.parent)for(var i=e;i;i=i.parent)if(t.base===i.base&&t!==i)return!0;return!1},Fe.prototype.sibling=function(){return new Fe(this.parent,this.base)};var Ue=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=De[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 Be(e){return 105===e||109===e||115===e}function We(e){return 36===e||e>=40&&e<=43||46===e||63===e||e>=91&&e<=94||e>=123&&e<=125}function $e(e){return e>=65&&e<=90||e>=97&&e<=122}Ue.prototype.reset=function(e,t,i){var s=-1!==i.indexOf("v"),n=-1!==i.indexOf("u");this.start=0|e,this.source=t+"",this.flags=i,s&&this.parser.options.ecmaVersion>=15?(this.switchU=!0,this.switchV=!0,this.switchN=!0):(this.switchU=n&&this.parser.options.ecmaVersion>=6,this.switchV=!1,this.switchN=n&&this.parser.options.ecmaVersion>=9)},Ue.prototype.raise=function(e){this.parser.raiseRecoverable(this.start,"Invalid regular expression: /"+this.source+"/: "+e)},Ue.prototype.at=function(e,t){void 0===t&&(t=!1);var i=this.source,s=i.length;if(e>=s)return-1;var n=i.charCodeAt(e);if(!t&&!this.switchU||n<=55295||n>=57344||e+1>=s)return n;var r=i.charCodeAt(e+1);return r>=56320&&r<=57343?(n<<10)+r-56613888:n},Ue.prototype.nextIndex=function(e,t){void 0===t&&(t=!1);var i=this.source,s=i.length;if(e>=s)return s;var n,r=i.charCodeAt(e);return!t&&!this.switchU||r<=55295||r>=57344||e+1>=s||(n=i.charCodeAt(e+1))<56320||n>57343?e+1:e+2},Ue.prototype.current=function(e){return void 0===e&&(e=!1),this.at(this.pos,e)},Ue.prototype.lookahead=function(e){return void 0===e&&(e=!1),this.at(this.nextIndex(this.pos,e),e)},Ue.prototype.advance=function(e){void 0===e&&(e=!1),this.pos=this.nextIndex(this.pos,e)},Ue.prototype.eat=function(e,t){return void 0===t&&(t=!1),this.current(t)===e&&(this.advance(t),!0)},Ue.prototype.eatChars=function(e,t){void 0===t&&(t=!1);for(var i=this.pos,s=0,n=e;s<n.length;s+=1){var r=n[s],a=this.at(i,t);if(-1===a||a!==r)return!1;i=this.nextIndex(i,t)}return this.pos=i,!0},Oe.validateRegExpFlags=function(e){for(var t=e.validFlags,i=e.flags,s=!1,n=!1,r=0;r<i.length;r++){var a=i.charAt(r);-1===t.indexOf(a)&&this.raise(e.start,"Invalid regular expression flag"),i.indexOf(a,r+1)>-1&&this.raise(e.start,"Duplicate regular expression flag"),"u"===a&&(s=!0),"v"===a&&(n=!0)}this.options.ecmaVersion>=15&&s&&n&&this.raise(e.start,"Invalid regular expression flag")},Oe.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))},Oe.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,i=e.backReferenceNames;t<i.length;t+=1){var s=i[t];e.groupNames[s]||e.raise("Invalid named capture referenced")}},Oe.regexp_disjunction=function(e){var t=this.options.ecmaVersion>=16;for(t&&(e.branchID=new Fe(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")},Oe.regexp_alternative=function(e){for(;e.pos<e.source.length&&this.regexp_eatTerm(e););},Oe.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)},Oe.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 i=!1;if(this.options.ecmaVersion>=9&&(i=e.eat(60)),e.eat(61)||e.eat(33))return this.regexp_disjunction(e),e.eat(41)||e.raise("Unterminated group"),e.lastAssertionIsQuantifiable=!i,!0}return e.pos=t,!1},Oe.regexp_eatQuantifier=function(e,t){return void 0===t&&(t=!1),!!this.regexp_eatQuantifierPrefix(e,t)&&(e.eat(63),!0)},Oe.regexp_eatQuantifierPrefix=function(e,t){return e.eat(42)||e.eat(43)||e.eat(63)||this.regexp_eatBracedQuantifier(e,t)},Oe.regexp_eatBracedQuantifier=function(e,t){var i=e.pos;if(e.eat(123)){var s=0,n=-1;if(this.regexp_eatDecimalDigits(e)&&(s=e.lastIntValue,e.eat(44)&&this.regexp_eatDecimalDigits(e)&&(n=e.lastIntValue),e.eat(125)))return-1!==n&&n<s&&!t&&e.raise("numbers out of order in {} quantifier"),!0;e.switchU&&!t&&e.raise("Incomplete quantifier"),e.pos=i}return!1},Oe.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)},Oe.regexp_eatReverseSolidusAtomEscape=function(e){var t=e.pos;if(e.eat(92)){if(this.regexp_eatAtomEscape(e))return!0;e.pos=t}return!1},Oe.regexp_eatUncapturingGroup=function(e){var t=e.pos;if(e.eat(40)){if(e.eat(63)){if(this.options.ecmaVersion>=16){var i=this.regexp_eatModifiers(e),s=e.eat(45);if(i||s){for(var n=0;n<i.length;n++){var r=i.charAt(n);i.indexOf(r,n+1)>-1&&e.raise("Duplicate regular expression modifiers")}if(s){var a=this.regexp_eatModifiers(e);i||a||58!==e.current()||e.raise("Invalid regular expression modifiers");for(var o=0;o<a.length;o++){var h=a.charAt(o);(a.indexOf(h,o+1)>-1||i.indexOf(h)>-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},Oe.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},Oe.regexp_eatModifiers=function(e){for(var t="",i=0;-1!==(i=e.current())&&Be(i);)t+=O(i),e.advance();return t},Oe.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)},Oe.regexp_eatInvalidBracedQuantifier=function(e){return this.regexp_eatBracedQuantifier(e,!0)&&e.raise("Nothing to repeat"),!1},Oe.regexp_eatSyntaxCharacter=function(e){var t=e.current();return!!We(t)&&(e.lastIntValue=t,e.advance(),!0)},Oe.regexp_eatPatternCharacters=function(e){for(var t=e.pos,i=0;-1!==(i=e.current())&&!We(i);)e.advance();return e.pos!==t},Oe.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)},Oe.regexp_groupSpecifier=function(e){if(e.eat(63)){this.regexp_eatGroupName(e)||e.raise("Invalid group");var t=this.options.ecmaVersion>=16,i=e.groupNames[e.lastStringValue];if(i)if(t)for(var s=0,n=i;s<n.length;s+=1){n[s].separatedFrom(e.branchID)||e.raise("Duplicate capture group name")}else e.raise("Duplicate capture group name");t?(i||(e.groupNames[e.lastStringValue]=[])).push(e.branchID):e.groupNames[e.lastStringValue]=!0}},Oe.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},Oe.regexp_eatRegExpIdentifierName=function(e){if(e.lastStringValue="",this.regexp_eatRegExpIdentifierStart(e)){for(e.lastStringValue+=O(e.lastIntValue);this.regexp_eatRegExpIdentifierPart(e);)e.lastStringValue+=O(e.lastIntValue);return!0}return!1},Oe.regexp_eatRegExpIdentifierStart=function(e){var t=e.pos,i=this.options.ecmaVersion>=11,s=e.current(i);return e.advance(i),92===s&&this.regexp_eatRegExpUnicodeEscapeSequence(e,i)&&(s=e.lastIntValue),function(e){return m(e,!0)||36===e||95===e}(s)?(e.lastIntValue=s,!0):(e.pos=t,!1)},Oe.regexp_eatRegExpIdentifierPart=function(e){var t=e.pos,i=this.options.ecmaVersion>=11,s=e.current(i);return e.advance(i),92===s&&this.regexp_eatRegExpUnicodeEscapeSequence(e,i)&&(s=e.lastIntValue),function(e){return g(e,!0)||36===e||95===e||8204===e||8205===e}(s)?(e.lastIntValue=s,!0):(e.pos=t,!1)},Oe.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)},Oe.regexp_eatBackReference=function(e){var t=e.pos;if(this.regexp_eatDecimalEscape(e)){var i=e.lastIntValue;if(e.switchU)return i>e.maxBackReference&&(e.maxBackReference=i),!0;if(i<=e.numCapturingParens)return!0;e.pos=t}return!1},Oe.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},Oe.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)},Oe.regexp_eatCControlLetter=function(e){var t=e.pos;if(e.eat(99)){if(this.regexp_eatControlLetter(e))return!0;e.pos=t}return!1},Oe.regexp_eatZero=function(e){return 48===e.current()&&!He(e.lookahead())&&(e.lastIntValue=0,e.advance(),!0)},Oe.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)},Oe.regexp_eatControlLetter=function(e){var t=e.current();return!!$e(t)&&(e.lastIntValue=t%32,e.advance(),!0)},Oe.regexp_eatRegExpUnicodeEscapeSequence=function(e,t){void 0===t&&(t=!1);var i,s=e.pos,n=t||e.switchU;if(e.eat(117)){if(this.regexp_eatFixedHexDigits(e,4)){var r=e.lastIntValue;if(n&&r>=55296&&r<=56319){var a=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*(r-55296)+(o-56320)+65536,!0}e.pos=a,e.lastIntValue=r}return!0}if(n&&e.eat(123)&&this.regexp_eatHexDigits(e)&&e.eat(125)&&((i=e.lastIntValue)>=0&&i<=1114111))return!0;n&&e.raise("Invalid unicode escape"),e.pos=s}return!1},Oe.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)},Oe.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};function je(e){return $e(e)||95===e}function ze(e){return je(e)||He(e)}function He(e){return e>=48&&e<=57}function qe(e){return e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102}function Ge(e){return e>=65&&e<=70?e-65+10:e>=97&&e<=102?e-97+10:e-48}function Ke(e){return e>=48&&e<=55}Oe.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 i=!1;if(e.switchU&&this.options.ecmaVersion>=9&&((i=80===t)||112===t)){var s;if(e.lastIntValue=-1,e.advance(),e.eat(123)&&(s=this.regexp_eatUnicodePropertyValueExpression(e))&&e.eat(125))return i&&2===s&&e.raise("Invalid property name"),s;e.raise("Invalid property name")}return 0},Oe.regexp_eatUnicodePropertyValueExpression=function(e){var t=e.pos;if(this.regexp_eatUnicodePropertyName(e)&&e.eat(61)){var i=e.lastStringValue;if(this.regexp_eatUnicodePropertyValue(e)){var s=e.lastStringValue;return this.regexp_validateUnicodePropertyNameAndValue(e,i,s),1}}if(e.pos=t,this.regexp_eatLoneUnicodePropertyNameOrValue(e)){var n=e.lastStringValue;return this.regexp_validateUnicodePropertyNameOrValue(e,n)}return 0},Oe.regexp_validateUnicodePropertyNameAndValue=function(e,t,i){D(e.unicodeProperties.nonBinary,t)||e.raise("Invalid property name"),e.unicodeProperties.nonBinary[t].test(i)||e.raise("Invalid property value")},Oe.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")},Oe.regexp_eatUnicodePropertyName=function(e){var t=0;for(e.lastStringValue="";je(t=e.current());)e.lastStringValue+=O(t),e.advance();return""!==e.lastStringValue},Oe.regexp_eatUnicodePropertyValue=function(e){var t=0;for(e.lastStringValue="";ze(t=e.current());)e.lastStringValue+=O(t),e.advance();return""!==e.lastStringValue},Oe.regexp_eatLoneUnicodePropertyNameOrValue=function(e){return this.regexp_eatUnicodePropertyValue(e)},Oe.regexp_eatCharacterClass=function(e){if(e.eat(91)){var t=e.eat(94),i=this.regexp_classContents(e);return e.eat(93)||e.raise("Unterminated character class"),t&&2===i&&e.raise("Negated character class may contain strings"),!0}return!1},Oe.regexp_classContents=function(e){return 93===e.current()?1:e.switchV?this.regexp_classSetExpression(e):(this.regexp_nonEmptyClassRanges(e),1)},Oe.regexp_nonEmptyClassRanges=function(e){for(;this.regexp_eatClassAtom(e);){var t=e.lastIntValue;if(e.eat(45)&&this.regexp_eatClassAtom(e)){var i=e.lastIntValue;!e.switchU||-1!==t&&-1!==i||e.raise("Invalid character class"),-1!==t&&-1!==i&&t>i&&e.raise("Range out of order in character class")}}},Oe.regexp_eatClassAtom=function(e){var t=e.pos;if(e.eat(92)){if(this.regexp_eatClassEscape(e))return!0;if(e.switchU){var i=e.current();(99===i||Ke(i))&&e.raise("Invalid class escape"),e.raise("Invalid escape")}e.pos=t}var s=e.current();return 93!==s&&(e.lastIntValue=s,e.advance(),!0)},Oe.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)},Oe.regexp_classSetExpression=function(e){var t,i=1;if(this.regexp_eatClassSetRange(e));else if(t=this.regexp_eatClassSetOperand(e)){2===t&&(i=2);for(var s=e.pos;e.eatChars([38,38]);)38!==e.current()&&(t=this.regexp_eatClassSetOperand(e))?2!==t&&(i=1):e.raise("Invalid character in character class");if(s!==e.pos)return i;for(;e.eatChars([45,45]);)this.regexp_eatClassSetOperand(e)||e.raise("Invalid character in character class");if(s!==e.pos)return i}else e.raise("Invalid character in character class");for(;;)if(!this.regexp_eatClassSetRange(e)){if(!(t=this.regexp_eatClassSetOperand(e)))return i;2===t&&(i=2)}},Oe.regexp_eatClassSetRange=function(e){var t=e.pos;if(this.regexp_eatClassSetCharacter(e)){var i=e.lastIntValue;if(e.eat(45)&&this.regexp_eatClassSetCharacter(e)){var s=e.lastIntValue;return-1!==i&&-1!==s&&i>s&&e.raise("Range out of order in character class"),!0}e.pos=t}return!1},Oe.regexp_eatClassSetOperand=function(e){return this.regexp_eatClassSetCharacter(e)?1:this.regexp_eatClassStringDisjunction(e)||this.regexp_eatNestedClass(e)},Oe.regexp_eatNestedClass=function(e){var t=e.pos;if(e.eat(91)){var i=e.eat(94),s=this.regexp_classContents(e);if(e.eat(93))return i&&2===s&&e.raise("Negated character class may contain strings"),s;e.pos=t}if(e.eat(92)){var n=this.regexp_eatCharacterClassEscape(e);if(n)return n;e.pos=t}return null},Oe.regexp_eatClassStringDisjunction=function(e){var t=e.pos;if(e.eatChars([92,113])){if(e.eat(123)){var i=this.regexp_classStringDisjunctionContents(e);if(e.eat(125))return i}else e.raise("Invalid escape");e.pos=t}return null},Oe.regexp_classStringDisjunctionContents=function(e){for(var t=this.regexp_classString(e);e.eat(124);)2===this.regexp_classString(e)&&(t=2);return t},Oe.regexp_classString=function(e){for(var t=0;this.regexp_eatClassSetCharacter(e);)t++;return 1===t?1:2},Oe.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 i=e.current();return!(i<0||i===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}(i))&&(!function(e){return 40===e||41===e||45===e||47===e||e>=91&&e<=93||e>=123&&e<=125}(i)&&(e.advance(),e.lastIntValue=i,!0))},Oe.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)},Oe.regexp_eatClassControlLetter=function(e){var t=e.current();return!(!He(t)&&95!==t)&&(e.lastIntValue=t%32,e.advance(),!0)},Oe.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},Oe.regexp_eatDecimalDigits=function(e){var t=e.pos,i=0;for(e.lastIntValue=0;He(i=e.current());)e.lastIntValue=10*e.lastIntValue+(i-48),e.advance();return e.pos!==t},Oe.regexp_eatHexDigits=function(e){var t=e.pos,i=0;for(e.lastIntValue=0;qe(i=e.current());)e.lastIntValue=16*e.lastIntValue+Ge(i),e.advance();return e.pos!==t},Oe.regexp_eatLegacyOctalEscapeSequence=function(e){if(this.regexp_eatOctalDigit(e)){var t=e.lastIntValue;if(this.regexp_eatOctalDigit(e)){var i=e.lastIntValue;t<=3&&this.regexp_eatOctalDigit(e)?e.lastIntValue=64*t+8*i+e.lastIntValue:e.lastIntValue=8*t+i}else e.lastIntValue=t;return!0}return!1},Oe.regexp_eatOctalDigit=function(e){var t=e.current();return Ke(t)?(e.lastIntValue=t-48,e.advance(),!0):(e.lastIntValue=0,!1)},Oe.regexp_eatFixedHexDigits=function(e,t){var i=e.pos;e.lastIntValue=0;for(var s=0;s<t;++s){var n=e.current();if(!qe(n))return e.pos=i,!1;e.lastIntValue=16*e.lastIntValue+Ge(n),e.advance()}return!0};var Qe=function(e){this.type=e.type,this.value=e.value,this.start=e.start,this.end=e.end,e.options.locations&&(this.loc=new B(e,e.startLoc,e.endLoc)),e.options.ranges&&(this.range=[e.start,e.end])},Ze=K.prototype;function Xe(e){return"function"!=typeof BigInt?null:BigInt(e.replace(/_/g,""))}Ze.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 Qe(this)),this.lastTokEnd=this.end,this.lastTokStart=this.start,this.lastTokEndLoc=this.endLoc,this.lastTokStartLoc=this.startLoc,this.nextToken()},Ze.getToken=function(){return this.next(),new Qe(this)},"undefined"!=typeof Symbol&&(Ze[Symbol.iterator]=function(){var e=this;return{next:function(){var t=e.getToken();return{done:t.type===_.eof,value:t}}}}),Ze.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(_.eof):e.override?e.override(this):void this.readToken(this.fullCharCodeAtPos())},Ze.readToken=function(e){return m(e,this.options.ecmaVersion>=6)||92===e?this.readWord():this.getTokenFromCode(e)},Ze.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},Ze.skipBlockComment=function(){var e=this.options.onComment&&this.curPosition(),t=this.pos,i=this.input.indexOf("*/",this.pos+=2);if(-1===i&&this.raise(this.pos-2,"Unterminated comment"),this.pos=i+2,this.options.locations)for(var s=void 0,n=t;(s=k(this.input,n,this.pos))>-1;)++this.curLine,n=this.lineStart=s;this.options.onComment&&this.options.onComment(!0,this.input.slice(t+2,i),t,this.pos,e,this.curPosition())},Ze.skipLineComment=function(e){for(var t=this.pos,i=this.options.onComment&&this.curPosition(),s=this.input.charCodeAt(this.pos+=e);this.pos<this.input.length&&!I(s);)s=this.input.charCodeAt(++this.pos);this.options.onComment&&this.options.onComment(!1,this.input.slice(t+e,this.pos),t,this.pos,i,this.curPosition())},Ze.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&&C.test(String.fromCharCode(e))))break e;++this.pos}}},Ze.finishToken=function(e,t){this.end=this.pos,this.options.locations&&(this.endLoc=this.curPosition());var i=this.type;this.type=e,this.value=t,this.updateContext(i)},Ze.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(_.ellipsis)):(++this.pos,this.finishToken(_.dot))},Ze.readToken_slash=function(){var e=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp()):61===e?this.finishOp(_.assign,2):this.finishOp(_.slash,1)},Ze.readToken_mult_modulo_exp=function(e){var t=this.input.charCodeAt(this.pos+1),i=1,s=42===e?_.star:_.modulo;return this.options.ecmaVersion>=7&&42===e&&42===t&&(++i,s=_.starstar,t=this.input.charCodeAt(this.pos+2)),61===t?this.finishOp(_.assign,i+1):this.finishOp(s,i)},Ze.readToken_pipe_amp=function(e){var t=this.input.charCodeAt(this.pos+1);if(t===e){if(this.options.ecmaVersion>=12)if(61===this.input.charCodeAt(this.pos+2))return this.finishOp(_.assign,3);return this.finishOp(124===e?_.logicalOR:_.logicalAND,2)}return 61===t?this.finishOp(_.assign,2):this.finishOp(124===e?_.bitwiseOR:_.bitwiseAND,1)},Ze.readToken_caret=function(){return 61===this.input.charCodeAt(this.pos+1)?this.finishOp(_.assign,2):this.finishOp(_.bitwiseXOR,1)},Ze.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&&!S.test(this.input.slice(this.lastTokEnd,this.pos))?this.finishOp(_.incDec,2):(this.skipLineComment(3),this.skipSpace(),this.nextToken()):61===t?this.finishOp(_.assign,2):this.finishOp(_.plusMin,1)},Ze.readToken_lt_gt=function(e){var t=this.input.charCodeAt(this.pos+1),i=1;return t===e?(i=62===e&&62===this.input.charCodeAt(this.pos+2)?3:2,61===this.input.charCodeAt(this.pos+i)?this.finishOp(_.assign,i+1):this.finishOp(_.bitShift,i)):33!==t||60!==e||this.inModule||45!==this.input.charCodeAt(this.pos+2)||45!==this.input.charCodeAt(this.pos+3)?(61===t&&(i=2),this.finishOp(_.relational,i)):(this.skipLineComment(4),this.skipSpace(),this.nextToken())},Ze.readToken_eq_excl=function(e){var t=this.input.charCodeAt(this.pos+1);return 61===t?this.finishOp(_.equality,61===this.input.charCodeAt(this.pos+2)?3:2):61===e&&62===t&&this.options.ecmaVersion>=6?(this.pos+=2,this.finishToken(_.arrow)):this.finishOp(61===e?_.eq:_.prefix,1)},Ze.readToken_question=function(){var e=this.options.ecmaVersion;if(e>=11){var t=this.input.charCodeAt(this.pos+1);if(46===t){var i=this.input.charCodeAt(this.pos+2);if(i<48||i>57)return this.finishOp(_.questionDot,2)}if(63===t){if(e>=12)if(61===this.input.charCodeAt(this.pos+2))return this.finishOp(_.assign,3);return this.finishOp(_.coalesce,2)}}return this.finishOp(_.question,1)},Ze.readToken_numberSign=function(){var e=35;if(this.options.ecmaVersion>=13&&(++this.pos,m(e=this.fullCharCodeAtPos(),!0)||92===e))return this.finishToken(_.privateId,this.readWord1());this.raise(this.pos,"Unexpected character '"+O(e)+"'")},Ze.getTokenFromCode=function(e){switch(e){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(_.parenL);case 41:return++this.pos,this.finishToken(_.parenR);case 59:return++this.pos,this.finishToken(_.semi);case 44:return++this.pos,this.finishToken(_.comma);case 91:return++this.pos,this.finishToken(_.bracketL);case 93:return++this.pos,this.finishToken(_.bracketR);case 123:return++this.pos,this.finishToken(_.braceL);case 125:return++this.pos,this.finishToken(_.braceR);case 58:return++this.pos,this.finishToken(_.colon);case 96:if(this.options.ecmaVersion<6)break;return++this.pos,this.finishToken(_.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(_.prefix,1);case 35:return this.readToken_numberSign()}this.raise(this.pos,"Unexpected character '"+O(e)+"'")},Ze.finishOp=function(e,t){var i=this.input.slice(this.pos,this.pos+t);return this.pos+=t,this.finishToken(e,i)},Ze.readRegexp=function(){for(var e,t,i=this.pos;;){this.pos>=this.input.length&&this.raise(i,"Unterminated regular expression");var s=this.input.charAt(this.pos);if(S.test(s)&&this.raise(i,"Unterminated regular expression"),e)e=!1;else{if("["===s)t=!0;else if("]"===s&&t)t=!1;else if("/"===s&&!t)break;e="\\"===s}++this.pos}var n=this.input.slice(i,this.pos);++this.pos;var r=this.pos,a=this.readWord1();this.containsEsc&&this.unexpected(r);var o=this.regexpState||(this.regexpState=new Ue(this));o.reset(i,n,a),this.validateRegExpFlags(o),this.validateRegExpPattern(o);var h=null;try{h=new RegExp(n,a)}catch(e){}return this.finishToken(_.regexp,{pattern:n,flags:a,value:h})},Ze.readInt=function(e,t,i){for(var s=this.options.ecmaVersion>=12&&void 0===t,n=i&&48===this.input.charCodeAt(this.pos),r=this.pos,a=0,o=0,h=0,p=null==t?1/0:t;h<p;++h,++this.pos){var c=this.input.charCodeAt(this.pos),u=void 0;if(s&&95===c)n&&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===h&&this.raiseRecoverable(this.pos,"Numeric separator is not allowed at the first of digits"),o=c;else{if((u=c>=97?c-97+10:c>=65?c-65+10:c>=48&&c<=57?c-48:1/0)>=e)break;o=c,a=a*e+u}}return s&&95===o&&this.raiseRecoverable(this.pos-1,"Numeric separator is not allowed at the last of digits"),this.pos===r||null!=t&&this.pos-r!==t?null:a},Ze.readRadixNumber=function(e){var t=this.pos;this.pos+=2;var i=this.readInt(e);return null==i&&this.raise(this.start+2,"Expected number in radix "+e),this.options.ecmaVersion>=11&&110===this.input.charCodeAt(this.pos)?(i=Xe(this.input.slice(t,this.pos)),++this.pos):m(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(_.num,i)},Ze.readNumber=function(e){var t=this.pos;e||null!==this.readInt(10,void 0,!0)||this.raise(t,"Invalid number");var i=this.pos-t>=2&&48===this.input.charCodeAt(t);i&&this.strict&&this.raise(t,"Invalid number");var s=this.input.charCodeAt(this.pos);if(!i&&!e&&this.options.ecmaVersion>=11&&110===s){var n=Xe(this.input.slice(t,this.pos));return++this.pos,m(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(_.num,n)}i&&/[89]/.test(this.input.slice(t,this.pos))&&(i=!1),46!==s||i||(++this.pos,this.readInt(10),s=this.input.charCodeAt(this.pos)),69!==s&&101!==s||i||(43!==(s=this.input.charCodeAt(++this.pos))&&45!==s||++this.pos,null===this.readInt(10)&&this.raise(t,"Invalid number")),m(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number");var r,a=(r=this.input.slice(t,this.pos),i?parseInt(r,8):parseFloat(r.replace(/_/g,"")));return this.finishToken(_.num,a)},Ze.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},Ze.readString=function(e){for(var t="",i=++this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated string constant");var s=this.input.charCodeAt(this.pos);if(s===e)break;92===s?(t+=this.input.slice(i,this.pos),t+=this.readEscapedChar(!1),i=this.pos):8232===s||8233===s?(this.options.ecmaVersion<10&&this.raise(this.start,"Unterminated string constant"),++this.pos,this.options.locations&&(this.curLine++,this.lineStart=this.pos)):(I(s)&&this.raise(this.start,"Unterminated string constant"),++this.pos)}return t+=this.input.slice(i,this.pos++),this.finishToken(_.string,t)};var Ye={};Ze.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(e){if(e!==Ye)throw e;this.readInvalidTemplateToken()}this.inTemplateElement=!1},Ze.invalidStringToken=function(e,t){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw Ye;this.raise(e,t)},Ze.readTmplToken=function(){for(var e="",t=this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated template");var i=this.input.charCodeAt(this.pos);if(96===i||36===i&&123===this.input.charCodeAt(this.pos+1))return this.pos!==this.start||this.type!==_.template&&this.type!==_.invalidTemplate?(e+=this.input.slice(t,this.pos),this.finishToken(_.template,e)):36===i?(this.pos+=2,this.finishToken(_.dollarBraceL)):(++this.pos,this.finishToken(_.backQuote));if(92===i)e+=this.input.slice(t,this.pos),e+=this.readEscapedChar(!0),t=this.pos;else if(I(i)){switch(e+=this.input.slice(t,this.pos),++this.pos,i){case 13:10===this.input.charCodeAt(this.pos)&&++this.pos;case 10:e+="\n";break;default:e+=String.fromCharCode(i)}this.options.locations&&(++this.curLine,this.lineStart=this.pos),t=this.pos}else++this.pos}},Ze.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(_.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")},Ze.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 O(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 i=this.pos-1;this.invalidStringToken(i,"Invalid escape sequence in template string")}default:if(t>=48&&t<=55){var s=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],n=parseInt(s,8);return n>255&&(s=s.slice(0,-1),n=parseInt(s,8)),this.pos+=s.length-1,t=this.input.charCodeAt(this.pos),"0"===s&&56!==t&&57!==t||!this.strict&&!e||this.invalidStringToken(this.pos-1-s.length,e?"Octal literal in template string":"Octal literal in strict mode"),String.fromCharCode(n)}return I(t)?(this.options.locations&&(this.lineStart=this.pos,++this.curLine),""):String.fromCharCode(t)}},Ze.readHexChar=function(e){var t=this.pos,i=this.readInt(16,e);return null===i&&this.invalidStringToken(t,"Bad character escape sequence"),i},Ze.readWord1=function(){this.containsEsc=!1;for(var e="",t=!0,i=this.pos,s=this.options.ecmaVersion>=6;this.pos<this.input.length;){var n=this.fullCharCodeAtPos();if(g(n,s))this.pos+=n<=65535?1:2;else{if(92!==n)break;this.containsEsc=!0,e+=this.input.slice(i,this.pos);var r=this.pos;117!==this.input.charCodeAt(++this.pos)&&this.invalidStringToken(this.pos,"Expecting Unicode escape sequence \\uXXXX"),++this.pos;var a=this.readCodePoint();(t?m:g)(a,s)||this.invalidStringToken(r,"Invalid Unicode escape"),e+=O(a),i=this.pos}t=!1}return e+this.input.slice(i,this.pos)},Ze.readWord=function(){var e=this.readWord1(),t=_.name;return this.keywords.test(e)&&(t=E[e]),this.finishToken(t,e)};function Je(e,t){return K.parse(e,t)}function et(e,t,i,s,n){i||(i=rt),function e(s,n,r){var a=r||s.type;i[a](s,n,e),t[a]&&t[a](s,n)}(e,s,n)}function tt(e,t,i,s,n){var r=[];i||(i=rt),function e(s,n,a){var o=a||s.type,h=s!==r[r.length-1];h&&r.push(s),i[o](s,n,e),t[o]&&t[o](s,n||r,r),h&&r.pop()}(e,s,n)}function it(e,t,i){i(e,t)}function st(e,t,i){}K.acorn={Parser:K,version:"8.15.0",defaultOptions:$,Position:U,SourceLocation:B,getLineInfo:W,Node:xe,TokenType:v,tokTypes:_,keywordTypes:E,TokContext:he,tokContexts:pe,isIdentifierChar:g,isIdentifierStart:m,Token:Qe,isNewLine:I,lineBreak:S,lineBreakG:w,nonASCIIwhitespace:C};var nt,rt={};rt.Program=rt.BlockStatement=rt.StaticBlock=function(e,t,i){for(var s=0,n=e.body;s<n.length;s+=1){i(n[s],t,"Statement")}},rt.Statement=it,rt.EmptyStatement=st,rt.ExpressionStatement=rt.ParenthesizedExpression=rt.ChainExpression=function(e,t,i){return i(e.expression,t,"Expression")},rt.IfStatement=function(e,t,i){i(e.test,t,"Expression"),i(e.consequent,t,"Statement"),e.alternate&&i(e.alternate,t,"Statement")},rt.LabeledStatement=function(e,t,i){return i(e.body,t,"Statement")},rt.BreakStatement=rt.ContinueStatement=st,rt.WithStatement=function(e,t,i){i(e.object,t,"Expression"),i(e.body,t,"Statement")},rt.SwitchStatement=function(e,t,i){i(e.discriminant,t,"Expression");for(var s=0,n=e.cases;s<n.length;s+=1){i(n[s],t)}},rt.SwitchCase=function(e,t,i){e.test&&i(e.test,t,"Expression");for(var s=0,n=e.consequent;s<n.length;s+=1){i(n[s],t,"Statement")}},rt.ReturnStatement=rt.YieldExpression=rt.AwaitExpression=function(e,t,i){e.argument&&i(e.argument,t,"Expression")},rt.ThrowStatement=rt.SpreadElement=function(e,t,i){return i(e.argument,t,"Expression")},rt.TryStatement=function(e,t,i){i(e.block,t,"Statement"),e.handler&&i(e.handler,t),e.finalizer&&i(e.finalizer,t,"Statement")},rt.CatchClause=function(e,t,i){e.param&&i(e.param,t,"Pattern"),i(e.body,t,"Statement")},rt.WhileStatement=rt.DoWhileStatement=function(e,t,i){i(e.test,t,"Expression"),i(e.body,t,"Statement")},rt.ForStatement=function(e,t,i){e.init&&i(e.init,t,"ForInit"),e.test&&i(e.test,t,"Expression"),e.update&&i(e.update,t,"Expression"),i(e.body,t,"Statement")},rt.ForInStatement=rt.ForOfStatement=function(e,t,i){i(e.left,t,"ForInit"),i(e.right,t,"Expression"),i(e.body,t,"Statement")},rt.ForInit=function(e,t,i){"VariableDeclaration"===e.type?i(e,t):i(e,t,"Expression")},rt.DebuggerStatement=st,rt.FunctionDeclaration=function(e,t,i){return i(e,t,"Function")},rt.VariableDeclaration=function(e,t,i){for(var s=0,n=e.declarations;s<n.length;s+=1){i(n[s],t)}},rt.VariableDeclarator=function(e,t,i){i(e.id,t,"Pattern"),e.init&&i(e.init,t,"Expression")},rt.Function=function(e,t,i){e.id&&i(e.id,t,"Pattern");for(var s=0,n=e.params;s<n.length;s+=1){i(n[s],t,"Pattern")}i(e.body,t,e.expression?"Expression":"Statement")},rt.Pattern=function(e,t,i){"Identifier"===e.type?i(e,t,"VariablePattern"):"MemberExpression"===e.type?i(e,t,"MemberPattern"):i(e,t)},rt.VariablePattern=st,rt.MemberPattern=it,rt.RestElement=function(e,t,i){return i(e.argument,t,"Pattern")},rt.ArrayPattern=function(e,t,i){for(var s=0,n=e.elements;s<n.length;s+=1){var r=n[s];r&&i(r,t,"Pattern")}},rt.ObjectPattern=function(e,t,i){for(var s=0,n=e.properties;s<n.length;s+=1){var r=n[s];"Property"===r.type?(r.computed&&i(r.key,t,"Expression"),i(r.value,t,"Pattern")):"RestElement"===r.type&&i(r.argument,t,"Pattern")}},rt.Expression=it,rt.ThisExpression=rt.Super=rt.MetaProperty=st,rt.ArrayExpression=function(e,t,i){for(var s=0,n=e.elements;s<n.length;s+=1){var r=n[s];r&&i(r,t,"Expression")}},rt.ObjectExpression=function(e,t,i){for(var s=0,n=e.properties;s<n.length;s+=1){i(n[s],t)}},rt.FunctionExpression=rt.ArrowFunctionExpression=rt.FunctionDeclaration,rt.SequenceExpression=function(e,t,i){for(var s=0,n=e.expressions;s<n.length;s+=1){i(n[s],t,"Expression")}},rt.TemplateLiteral=function(e,t,i){for(var s=0,n=e.quasis;s<n.length;s+=1){i(n[s],t)}for(var r=0,a=e.expressions;r<a.length;r+=1){i(a[r],t,"Expression")}},rt.TemplateElement=st,rt.UnaryExpression=rt.UpdateExpression=function(e,t,i){i(e.argument,t,"Expression")},rt.BinaryExpression=rt.LogicalExpression=function(e,t,i){i(e.left,t,"Expression"),i(e.right,t,"Expression")},rt.AssignmentExpression=rt.AssignmentPattern=function(e,t,i){i(e.left,t,"Pattern"),i(e.right,t,"Expression")},rt.ConditionalExpression=function(e,t,i){i(e.test,t,"Expression"),i(e.consequent,t,"Expression"),i(e.alternate,t,"Expression")},rt.NewExpression=rt.CallExpression=function(e,t,i){if(i(e.callee,t,"Expression"),e.arguments)for(var s=0,n=e.arguments;s<n.length;s+=1){i(n[s],t,"Expression")}},rt.MemberExpression=function(e,t,i){i(e.object,t,"Expression"),e.computed&&i(e.property,t,"Expression")},rt.ExportNamedDeclaration=rt.ExportDefaultDeclaration=function(e,t,i){e.declaration&&i(e.declaration,t,"ExportNamedDeclaration"===e.type||e.declaration.id?"Statement":"Expression"),e.source&&i(e.source,t,"Expression")},rt.ExportAllDeclaration=function(e,t,i){e.exported&&i(e.exported,t),i(e.source,t,"Expression")},rt.ImportDeclaration=function(e,t,i){for(var s=0,n=e.specifiers;s<n.length;s+=1){i(n[s],t)}i(e.source,t,"Expression")},rt.ImportExpression=function(e,t,i){i(e.source,t,"Expression")},rt.ImportSpecifier=rt.ImportDefaultSpecifier=rt.ImportNamespaceSpecifier=rt.Identifier=rt.PrivateIdentifier=rt.Literal=st,rt.TaggedTemplateExpression=function(e,t,i){i(e.tag,t,"Expression"),i(e.quasi,t,"Expression")},rt.ClassDeclaration=rt.ClassExpression=function(e,t,i){return i(e,t,"Class")},rt.Class=function(e,t,i){e.id&&i(e.id,t,"Pattern"),e.superClass&&i(e.superClass,t,"Expression"),i(e.body,t)},rt.ClassBody=function(e,t,i){for(var s=0,n=e.body;s<n.length;s+=1){i(n[s],t)}},rt.MethodDefinition=rt.PropertyDefinition=rt.Property=function(e,t,i){e.computed&&i(e.key,t,"Expression"),e.value&&i(e.value,t,"Expression")};class at{static extractIdentifiers(e,t){const i=new Set;return et(Je(`(${e})`,{ecmaVersion:"latest"}),{Identifier(e){if(i.add(e.name),t[e.name])for(const s of t[e.name])i.add(s)}}),Array.from(i)}static analyzeFunctionDependencies(e){const t={};for(const[i,s]of Object.entries(e))try{let e=s.toString();const n=/^\s*(\([^)]*\)|[a-zA-Z_$][a-zA-Z0-9_$]*)\s*=>/.test(e),r=e.startsWith("function"),a=e.startsWith("async");r||n||(e=a?`async function ${e.substring(5).trim()}`:`function ${e}`),e=`(${e})`;const o=Je(e,{ecmaVersion:"latest"}),h=new Set,p=new Set;tt(o,{VariableDeclarator(e){"Identifier"===e.id.type&&p.add(e.id.name)},FunctionDeclaration(e){e.id&&"Identifier"===e.id.type&&p.add(e.id.name),e.params.forEach(e=>{"Identifier"===e.type&&p.add(e.name)})},FunctionExpression(e,t){1===t.filter(e=>"FunctionExpression"===e.type||"FunctionDeclaration"===e.type||"ArrowFunctionExpression"===e.type).length&&e.params.forEach(e=>{"Identifier"===e.type&&p.add(e.name)})},ArrowFunctionExpression(e,t){1===t.filter(e=>"FunctionExpression"===e.type||"FunctionDeclaration"===e.type||"ArrowFunctionExpression"===e.type).length&&e.params.forEach(e=>{"Identifier"===e.type&&p.add(e.name)})}}),et(o,{Identifier(e){e.name===i||p.has(e.name)||h.add(e.name)},MemberExpression(e){"ThisExpression"===e.object.type&&"Identifier"===e.property.type&&h.add(e.property.name)}}),t[i]=Array.from(h)}catch(e){console.warn(`Failed to analyze function '${i}':`,e),t[i]=[]}const i={},s=new Set,n=r=>{if(i[r])return i[r];if(s.has(r))return console.warn(`Circular dependency detected for function: ${r}`),[];s.add(r);const a=new Set,o=t[r]||[];for(const t of o)if(e[t]){n(t).forEach(e=>a.add(e))}else a.add(t);return s.delete(r),i[r]=Array.from(a),i[r]};for(const t of Object.keys(e))n(t);return i}}class ot{#i;#s;#n;#r;#a;#o=new Set;#h=new Set;constructor(e){this.#i=e.vNode;const t=e.attribute.name;t.startsWith("v-bind:")?this.#r=t.substring(7):t.startsWith(":")&&(this.#r=t.substring(1)),this.#a=e.attribute.value,this.#a&&(this.#s=at.extractIdentifiers(this.#a,e.vNode.vApplication.functionDependencies),this.#n=this.#p(this.#a)),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_BIND}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){const e=this.#s??[];return{get dependentIdentifiers(){return e},applyToDOM:()=>{this.#c()}}}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get isKey(){return"key"===this.#r}get isOptions(){return"options"===this.#r||!0===this.#r?.startsWith("options.")}get attributeName(){return this.#r}get expression(){return this.#a}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){}#c(){if(this.isKey||this.isOptions)return;const e=this.#i.node,t=this.#r;if(!this.#n||!t)return;const i=this.#n();"class"===t?this.#u(e,i):"style"===t?this.#d(e,i):this.#l(t)?this.#f(e,t,i):this.#m(t)?this.#g(e,t,i):this.#v(e,t,i)}#u(e,t){let i=[];"string"==typeof t?i=t.split(/\s+/).filter(Boolean):Array.isArray(t)?i=t.filter(Boolean):"object"==typeof t&&null!==t&&(i=Object.keys(t).filter(e=>t[e])),this.#o.forEach(t=>e.classList.remove(t)),i.forEach(t=>e.classList.add(t)),this.#o=new Set(i)}#d(e,t){let i=[];if("string"==typeof t)e.style.cssText=t,i=t.split(";").map(e=>e.split(":")[0].trim()).filter(Boolean);else if("object"==typeof t&&null!==t){this.#h.forEach(t=>{e.style.removeProperty(this.#x(t))});for(const s in t)if(Object.prototype.hasOwnProperty.call(t,s)){const n=this.#x(s),r=t[s];null!=r&&(e.style.setProperty(n,String(r)),i.push(s))}}this.#h=new Set(i)}#x(e){return e.replace(/([A-Z])/g,"-$1").toLowerCase()}#l(e){return["value","checked","selected","innerHTML","textContent"].includes(e)}#m(e){return["disabled","readonly","required","checked","selected","multiple","autofocus","autoplay","controls","loop","muted","open","hidden"].includes(e)}#f(e,t,i){e[t]=i}#g(e,t,i){i?e.setAttribute(t,""):e.removeAttribute(t)}#v(e,t,i){null==i||!1===i?e.removeAttribute(t):e.setAttribute(t,String(i))}#p(e){const t=this.#s??[],i=t.join(", "),s=new Function(i,`return (${e});`);return()=>{const e=t.map(e=>this.#i.bindings?.get(e));return s(...e)}}}class ht{#i;#y;#b;constructor(e){this.#i=e.vNode,this.#y=e.attribute.value.trim(),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_COMPONENT}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){return{get dependentIdentifiers(){return[]},applyToDOM:()=>{this.#c()}}}get templatize(){return!0}get dependentIdentifiers(){return[]}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}cloneNode(){const e=this.#i.vApplication.componentRegistry.get(this.#y);if(!e)throw new Error(`Component '${this.#y}' not found in registry`);const t=e.templateID||e.id,i=document.querySelector(`#${t}`);if(!(i&&i instanceof HTMLTemplateElement))throw new Error(`Template element '#${t}' not found`);const s=i.content.cloneNode(!0),n=Array.from(s.childNodes);for(const e of n)if(e.nodeType===Node.ELEMENT_NODE)return e;throw new Error(`No element found in template '#${t}'`)}destroy(){if(!this.#b)return;this.#b.unmount();const e=this.#b.rootVNode;e?.node.parentNode&&e.node.parentNode.removeChild(e.node),this.#b=void 0}#c(){if(this.#b)return;let e={};const t=this.#i.directiveManager?.optionsDirective("component");if(t&&t.expression){const i=t.dependentIdentifiers,s=i.map(e=>this.#i.bindings?.get(e)),n=i.join(", "),r=`return (${t.expression});`,a=new Function(n,r)(...s);"object"==typeof a&&null!==a&&(e=a)}const i=this.#i.vApplication.componentRegistry.get(this.#y);if(!i)throw new Error(`Component '${this.#y}' not found in registry`);const s=i.createInstance(e);this.#b=this.#i.vApplication.createChildApp(s),this.#b.mount(this.#i.node)}}class pt{static proxyCache=new WeakMap;static create(e,t,i=""){if("object"!=typeof e||null===e)return e;let s=this.proxyCache.get(e);if(s){const e=s.get(i);if(e)return e}else s=new Map,this.proxyCache.set(e,s);const n=new Proxy(e,{get(e,s){const n=Reflect.get(e,s);if("object"==typeof n&&null!==n){const r=String(s),a=i?Array.isArray(e)?`${i}[${r}]`:`${i}.${r}`:r;return pt.create(n,t,a)}if(Array.isArray(e)&&"function"==typeof n){if(["push","pop","shift","unshift","splice","sort","reverse"].includes(s))return function(...e){const s=n.apply(this,e);return t(i||void 0),s}}return n},set(e,s,n){const r=Reflect.get(e,s),a=Reflect.set(e,s,n);if(r!==n){const n=String(s),r=i?Array.isArray(e)?`${i}[${n}]`:`${i}.${n}`:n;t(r)}return a},deleteProperty(e,s){const n=Reflect.deleteProperty(e,s),r=String(s),a=i?Array.isArray(e)?`${i}[${r}]`:`${i}.${r}`:r;return t(a),n}});return s.set(i,n),n}static isReactive(e){return this.proxyCache.has(e)}static unwrap(e){return e}}class ct{#E;#N;#_;#S;#w=new Set;#I=new Map;constructor(e={}){this.#E=e.parent,this.#_=e.onChange,this.#S=e.vApplication?.logManager.getLogger("VBindings"),this.#S?.isDebugEnabled&&this.#S.debug("VBindings created. Parent: "+(this.#E?"yes":"no")),this.#N=new Proxy({},{get:(e,t)=>Reflect.has(e,t)?Reflect.get(e,t):this.#E?.raw[t],set:(e,t,i)=>{let s=e;if(!Reflect.has(s,t))for(let e=this.#E;e;e=e.#E)if(Reflect.has(e.#N,t)){s=e.#N;break}let n=i;"object"==typeof i&&null!==i&&(n=pt.create(i,e=>{let t="";for(const i of e?.split(".")||[])t=t?`${t}.${i}`:i,this.#S?.debug(`Binding changed: ${t}`),this.#w.add(t);this.#_?.(e)},t));const r=Reflect.get(s,t),a=Reflect.set(s,t,n);let o=r!==n;if(Array.isArray(n)){const e=this.#I.get(t),i=n.length;o||void 0===e||e===i||(o=!0),this.#I.set(t,i)}if(o){if(this.#S?.isDebugEnabled){const i="string"==typeof r?`"${r}"`:JSON.stringify(r)||"undefined",a="string"==typeof n?`"${n}"`:JSON.stringify(n)||"undefined",o=i.length>100?`${i.substring(0,100)}...`:i,h=a.length>100?`${a.substring(0,100)}...`:a;this.#S.debug(`Binding set on ${s===e?"local":"parent"}: ${t}: ${o} -> ${h}`)}this.#w.add(t),this.#_?.(t)}return a},deleteProperty:(e,t)=>{const i=Reflect.deleteProperty(e,t);return this.#S?.debug(`Binding deleted: ${t}`),this.#w.add(t),this.#_?.(t),i}})}get raw(){return this.#N}get hasChanges(){return!!this.#E?.hasChanges||this.#w.size>0}get changes(){const e=new Set(this.#E?.changes||[]);return this.#w.forEach(t=>e.add(t)),Array.from(e)}get isRoot(){return!this.#E}clearChanges(){this.#w.clear()}set(e,t){this.#N[e]=t}get(e){return this.#N[e]}has(e,t=!0){return e in this.#N||!!t&&(this.#E?.has(e)??!1)}remove(e){delete this.#N[e]}}class ut{#i;#k;#C;#A;#V;#P;#T={};#D;constructor(e){if(e.nodeType!==Node.ELEMENT_NODE)throw new Error("Directives can only be associated with element nodes.");if(this.#i=e,this.#k=this.#L(),this.#k?.some(e=>e.needsAnchor)){this.#C=document.createComment("#vnode-anchor");const e=this.#i.node;e.parentNode?.insertBefore(this.#C,e),e.parentNode?.removeChild(e)}this.#A=this.#k?.map(e=>e.bindingsPreparer).filter(e=>void 0!==e),this.#V=this.#k?.map(e=>e.domUpdater).filter(e=>void 0!==e)}get directives(){return this.#k}get anchorNode(){return this.#C}get bindingsPreparers(){return this.#A}get domUpdaters(){return this.#V}get keyDirective(){return this.#P}get componentDirective(){return this.#D}optionsDirective(e){if(!this.#k||0===this.#k.length)return;const t=`options.${e}`;return this.#T[t]?this.#T[t]:this.#T.options?this.#T.options:void 0}destroy(){if(this.#k)for(const e of this.#k)try{e.destroy()}catch(t){this.#i.vApplication.logManager.getLogger(this.constructor.name).error(`Error destroying '${e.name}' directive: ${t}`)}}#L(){const e=this.#i.node,t=[];if(e.hasAttribute(n.V_FOR)){t.push(e.getAttributeNode(n.V_FOR));for(const i of Array.from(e.attributes))if(["v-bind:key",":key"].includes(i.name)){t.push(i);break}}else e.hasAttribute(n.V_IF)?t.push(e.getAttributeNode(n.V_IF)):e.hasAttribute(n.V_ELSE_IF)?t.push(e.getAttributeNode(n.V_ELSE_IF)):e.hasAttribute(n.V_ELSE)?t.push(e.getAttributeNode(n.V_ELSE)):t.push(...Array.from(e.attributes));const i=[];for(const e of t){const t={vNode:this.#i,attribute:e},s=this.#i.vApplication.directiveParserRegistry.findParser(t);if(s){const e=s.parse(t);if(i.push(e),e.name===n.V_BIND&&e.isKey&&(this.#P=e),e.name===n.V_BIND&&e.isOptions){const t=e,i=t.attributeName;i&&(this.#T[i]=t)}e.name===n.V_COMPONENT&&(this.#D=e)}}const s=[n.V_FOR,n.V_IF,n.V_ELSE_IF,n.V_ELSE,n.V_SHOW],r=i.slice().sort((e,t)=>{const i=s.indexOf(e.name),n=s.indexOf(t.name);return(-1===i?s.length:i)-(-1===n?s.length:n)});return r.length>0?r:void 0}}class dt{#M=[];#n;constructor(e,t){const i=Array.from(e.matchAll(/\{\{([^}]+)\}\}/g));if(this.#M=[],0===i.length)return void(this.#n=()=>e);const s=i.map(e=>{const i=e[1].trim(),s=at.extractIdentifiers(i,t);this.#M.push(...s.filter(e=>!this.#M.includes(e)));const n=s.join(", ");return{ids:s,func:new Function(n,`return (${i});`)}});this.#n=t=>{let n=e;return s.forEach((e,s)=>{const r=e.ids.map(e=>t.get(e));n=n.replace(i[s][0],String(e.func(...r)))}),n}}static containsExpression(e){return/\{\{([^}]+)\}\}/g.test(e)}get identifiers(){return this.#M}evaluate(e){return this.#n(e)}}class lt{#R;#O;#F;#U;#B;#W;#$;#j;#z;#H;#q;#s;#G;#K;#Q;#Z;constructor(e){if(this.#R=e.vApplication,this.#O=e.node,this.#F=e.node.nodeType,this.#U=e.node.nodeName,this.#B=e.parentVNode,this.#$=e.bindings,this.#j=e.dependentIdentifiers,this.#B?.addChild(this),this.#F===Node.TEXT_NODE){const e=this.#O;dt.containsExpression(e.data)&&(this.#z=new dt(e.data,this.#R.functionDependencies))}else if(this.#F===Node.ELEMENT_NODE){if(this.#O,this.#W=[],this.#H=new ut(this),this.#Q=this.#H.directives?.some(e=>e.templatize)??!1,this.#Q||this.#H.directives?.forEach(e=>{e.onMount?.()}),!this.#Q)for(const e of Array.from(this.#O.childNodes))new lt({node:e,vApplication:this.#R,parentVNode:this});this.#Q||requestAnimationFrame(()=>{this.#H?.directives?.forEach(e=>{e.onMounted?.()})})}this.#K=this.#B?.addDependent(this)}get vApplication(){return this.#R}get node(){return this.#O}get nodeType(){return this.#F}get nodeName(){return this.#U}get parentVNode(){return this.#B}get childVNodes(){return this.#W}get previousSibling(){if(!this.#B||!this.#B.childVNodes)return;const e=this.#B.childVNodes,t=e.indexOf(this);return t>0?e[t-1]:void 0}get nextSibling(){if(!this.#B||!this.#B.childVNodes)return;const e=this.#B.childVNodes,t=e.indexOf(this);return-1!==t&&t<e.length-1?e[t+1]:void 0}get bindings(){return this.#$?this.#$:this.#B?.bindings}get directiveManager(){return this.#H}get anchorNode(){return this.#H?.anchorNode}get isInDOM(){return null!==this.#O.parentNode&&this.#O.parentNode.nodeType!==Node.DOCUMENT_FRAGMENT_NODE}get isRoot(){return void 0===this.#B}get dependentIdentifiers(){if(this.#s)return this.#s;const e=[];return e.push(...this.#j??[]),this.#z&&e.push(...this.#z.identifiers),this.#H?.bindingsPreparers?.forEach(t=>{e.push(...t.dependentIdentifiers)}),this.#H?.domUpdaters?.forEach(t=>{e.push(...t.dependentIdentifiers)}),this.#s=[...new Set(e)],this.#s}get preparableIdentifiers(){if(this.#G)return this.#G;const e=[];return this.#H?.bindingsPreparers?.forEach(t=>{e.push(...t.preparableIdentifiers)}),this.#G=0===e.length?[]:[...new Set(e)],this.#G}get userData(){return this.#Z||(this.#Z=new Map),this.#Z}get domPath(){const e=[];let t=this;for(;t;){if(t.parentVNode&&t.parentVNode.childVNodes){const i=t.parentVNode.childVNodes.filter(e=>e.nodeName===t?.nodeName).indexOf(t);e.unshift(`${t.nodeName}[${i}]`)}else e.unshift(t.nodeName);t=t.parentVNode}return e.join("/")}update(){const e=this.bindings?.changes||[];if(this.#F===Node.TEXT_NODE&&this.#z){if(this.#z.identifiers.some(t=>e.includes(t))){this.#O.data=this.#z.evaluate(this.bindings)}}else if(this.#F===Node.ELEMENT_NODE){if(this.#Q||this.#H?.directives?.forEach(e=>{e.onUpdate?.()}),this.#H?.bindingsPreparers){this.#$||(this.#$=new ct({parent:this.bindings}));for(const t of this.#H.bindingsPreparers){t.dependentIdentifiers.some(t=>e.includes(t))&&t.prepareBindings()}}if(this.#H?.domUpdaters)for(const t of this.#H.domUpdaters){t.dependentIdentifiers.some(t=>e.includes(t))&&t.applyToDOM()}this.#q?.forEach(t=>{t.dependentIdentifiers.some(t=>e.includes(t))&&t.update()}),this.#Q||this.#H?.directives?.forEach(e=>{e.onUpdated?.()})}}forceUpdate(){if(this.#F===Node.TEXT_NODE&&this.#z){this.#O.data=this.#z.evaluate(this.bindings)}else if(this.#F===Node.ELEMENT_NODE){if(this.#Q||this.#H?.directives?.forEach(e=>{e.onUpdate?.()}),this.#H?.bindingsPreparers){this.#$||(this.#$=new ct({parent:this.bindings}));for(const e of this.#H.bindingsPreparers)e.prepareBindings()}if(this.#H?.domUpdaters)for(const e of this.#H.domUpdaters)e.applyToDOM();this.#W?.forEach(e=>{e.forceUpdate()}),this.#Q||this.#H?.directives?.forEach(e=>{e.onUpdated?.()})}}addChild(e){this.#W?.push(e)}addDependent(e,t=void 0){const i=[];t||(t=[...e.dependentIdentifiers]);const s=new Set;t.forEach(e=>{s.add(e);const t=e.indexOf("[");-1!==t&&s.add(e.substring(0,t))});const n=[...this.preparableIdentifiers];return this.#$&&n.push(...this.#$?.raw?Object.keys(this.#$.raw):[]),[...s].some(e=>n.includes(e))&&(this.#q||(this.#q=[]),this.#q.push(e),n.forEach(e=>{const i=t.indexOf(e);-1!==i&&t.splice(i,1)}),i.push({close:()=>{const t=this.#q?.indexOf(e)??-1;-1!==t&&this.#q?.splice(t,1)}})),this.#B?.addDependent(e,t)?.forEach(e=>i.push(e)),i.length>0?i:void 0}destroy(){if(this.#Q||this.#H?.directives?.forEach(e=>{e.onUnmount?.()}),this.#Z){for(const[e,t]of this.#Z.entries())try{t&&"object"==typeof t&&"function"==typeof t.close&&t.close()}catch(t){this.#R.logManager.getLogger(this.constructor.name).error(`Error closing user data '${e}': ${t}`)}this.#Z.clear()}if(this.#W)for(const e of this.#W)try{e.destroy()}catch(e){this.#R.logManager.getLogger(this.constructor.name).error(`Error destroying child VNode: ${e}`)}if(this.#K)for(const e of this.#K)try{e.close()}catch(e){this.#R.logManager.getLogger(this.constructor.name).error(`Error closing dependency closer: ${e}`)}this.#H?.destroy(),this.#Q||this.#H?.directives?.forEach(e=>{e.onUnmounted?.()})}}class ft{#k=[];#X=[];get allDependentIdentifiers(){return this.#X}addDirective(e){if(this.#k.push(e),e.dependentIdentifiers)for(const t of e.dependentIdentifiers)this.#X.includes(t)||this.#X.push(t)}isPrecedingConditionMet(e){const t=this.#k.indexOf(e);if(-1===t)throw new Error("Directive not found in context.");for(let e=0;e<t;e++){if(!0===this.#k[e].conditionIsMet)return!0}return!1}}class mt{#i;#s;#n;#Y;#J;constructor(e){this.#i=e.vNode;const t=e.attribute.value;t&&(this.#s=at.extractIdentifiers(t,e.vNode.vApplication.functionDependencies),this.#n=this.#p(t)),this.#i.node.removeAttribute(e.attribute.name),this.#Y=this.#ee(),this.#Y.addDirective(this)}get vNode(){return this.#i}get needsAnchor(){return!0}get bindingsPreparer(){}get domUpdater(){const e=this.#Y.allDependentIdentifiers;return{get dependentIdentifiers(){return e},applyToDOM:()=>{this.#c()}}}get templatize(){return!0}get dependentIdentifiers(){return this.#s??[]}get conditionalContext(){return this.#Y}get conditionIsMet(){return!this.#n||this.#n()}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){}#c(){if(this.#Y.isPrecedingConditionMet(this))return void this.#te();if(!this.#n)return void this.#ie();this.#n()?this.#ie():this.#te()}#ie(){this.#J||(this.#J=this.#se(),this.#i.anchorNode?.parentNode?.insertBefore(this.#J.node,this.#i.anchorNode.nextSibling),this.#J.forceUpdate())}#te(){this.#J&&(this.#J.destroy(),this.#J.node.parentNode?.removeChild(this.#J.node),this.#J=void 0)}#se(){let e;if(this.vNode.directiveManager?.componentDirective)e=this.vNode.directiveManager.componentDirective.cloneNode();else{e=this.#i.node.cloneNode(!0)}return new lt({node:e,vApplication:this.#i.vApplication,parentVNode:this.#i.parentVNode})}#p(e){const t=this.#s??[],i=t.join(", "),s=new Function(i,`return (${e});`);return()=>{const e=t.map(e=>this.#i.bindings?.get(e));return Boolean(s(...e))}}#ee(){if(this.name===n.V_IF)return new ft;let e=this.vNode.previousSibling;for(;e&&e.nodeType!==Node.ELEMENT_NODE;)e=e.previousSibling;const t=e?.directiveManager?.directives?.find(e=>e.name===n.V_IF||e.name===n.V_ELSE_IF);if(!t)throw new Error("preceding v-if or v-else-if directive not found.");return t.conditionalContext}}class gt extends mt{constructor(e){super(e)}get name(){return n.V_ELSE}}class vt extends mt{constructor(e){super(e)}get name(){return n.V_ELSE_IF}}class xt{#i;#s;#ne;#re;#ae;#oe;#he;#pe=new Map;#ce=[];constructor(e){this.#i=e.vNode;const t=this.#i.node,i=e.attribute.value;if(i){const t=this.#ue(i);this.#ae=t.itemName,this.#oe=t.indexName,this.#he=t.sourceName,this.#s=at.extractIdentifiers(t.sourceName,e.vNode.vApplication.functionDependencies),this.#ne=this.#de(t.sourceName)}t.removeAttribute(e.attribute.name)}get name(){return n.V_FOR}get vNode(){return this.#i}get needsAnchor(){return!0}get bindingsPreparer(){}get domUpdater(){const e=this.#s??[];return{get dependentIdentifiers(){return e},applyToDOM:()=>{this.#c()}}}get templatize(){return!0}get dependentIdentifiers(){return this.#s??[]}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){for(const e of this.#pe.values())e.destroy();for(const e of this.#pe.values())e.node.parentNode&&e.node.parentNode.removeChild(e.node);this.#pe.clear(),this.#ce=[]}#c(){if(!this.#ne)return;const e=this.#ne();let t=this.#le(e);const i=this.#i.directiveManager?.keyDirective?.expression;this.#re||void 0===i||(this.#re=this.#fe(i)),this.#re&&this.#ae&&(t=t.map(e=>{const t=new ct({parent:this.#i.bindings});t.set(this.#ae,e.item),this.#oe&&t.set(this.#oe,e.index);const i=this.#re(t);return{...e,key:i}})),this.#me(t),this.#ce=t}#me(e){const t=this.#i.anchorNode?.parentNode,i=this.#i.anchorNode;if(!t||!i)throw new Error("v-for element must have a parent and anchor");const s=new Map,n=new Set(e.map(e=>e.key)),r=[];for(const[e,t]of this.#pe)n.has(e)||(r.push(t),t.destroy());for(const e of r)e.node.parentNode&&e.node.parentNode.removeChild(e.node);let a=i;for(const i of e){const{key:e}=i;let n=this.#pe.get(e);n?(s.set(e,n),this.#ge(n,i),a.nextSibling!==n.node&&(a.nextSibling?t.insertBefore(n.node,a.nextSibling):t.appendChild(n.node))):(n=this.#se(i),s.set(e,n),a.nextSibling?t.insertBefore(n.node,a.nextSibling):t.appendChild(n.node),n.forceUpdate()),a=n.node}this.#pe=s}#ue(e){const t=e.replace(/\s+/g," ").trim().split(" in ");if(2!==t.length)throw new Error(`Invalid v-for expression: ${e}`);const[i,s]=t;if(i.startsWith("(")&&i.endsWith(")")){const e=i.slice(1,-1).split(",").map(e=>e.trim());return{itemName:e[0],indexName:e[1],sourceName:s.trim()}}return{itemName:i.trim(),sourceName:s.trim()}}#de(e){const t=this.#s??[],i=t.join(", "),s=new Function(i,`return (${e});`);return()=>{const e=t.map(e=>this.#i.bindings?.get(e));return s(...e)}}#fe(e){const t=at.extractIdentifiers(e,this.#i.vApplication.functionDependencies),i=t.join(", "),s=new Function(i,`return (${e});`);return e=>{const i=t.map(t=>e.get(t));return s(...i)}}#se(e){let t;if(this.vNode.directiveManager?.componentDirective)t=this.vNode.directiveManager.componentDirective.cloneNode();else{t=this.#i.node.cloneNode(!0)}this.#ae,this.#oe;const i=new ct({parent:this.#i.bindings});this.#ae&&i.set(this.#ae,e.item),this.#oe&&i.set(this.#oe,e.index);return new lt({node:t,vApplication:this.#i.vApplication,parentVNode:this.#i.parentVNode,bindings:i,dependentIdentifiers:[`${this.#he}[${e.index}]`]})}#ge(e,t){this.#ae&&e.bindings?.set(this.#ae,t.item),this.#oe&&e.bindings?.set(this.#oe,t.index),e.update()}#le(e){return e?Array.isArray(e)?e.map((e,t)=>({item:e,index:t,key:t})):"object"==typeof e?Object.entries(e).map(([e,t],i)=>({item:t,index:i,key:e})):"number"==typeof e?Array.from({length:e},(e,t)=>({item:t+1,index:t,key:t+1})):"string"==typeof e?Array.from(e).map((e,t)=>({item:e,index:t,key:t})):[]:[]}}class yt extends mt{constructor(e){super(e)}get name(){return n.V_IF}}class bt{#i;#s;#ve;#xe;constructor(e){this.#i=e.vNode;const t=e.attribute.value;t&&(this.#s=at.extractIdentifiers(t,e.vNode.vApplication.functionDependencies),this.#ve=this.#ye(t)),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_INTERSECTION}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get onMount(){}get onMounted(){if(!this.#ve)return;const e=this.#i.node,t=this.#ve;return()=>{let i,s=this.#i.directiveManager?.optionsDirective("intersection");if(s&&s.expression){const e=s.dependentIdentifiers,t=e.map(e=>this.#i.bindings?.get(e)),n=e.join(", "),r=`return (${s.expression});`;i=new Function(n,r)(...t)}this.#xe=new IntersectionObserver(e=>{t(e)},i),this.#xe.observe(e)}}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){this.#xe&&(this.#xe.disconnect(),this.#xe=void 0)}#ye(e){const t=this.#s??[],i=this.#i;return s=>{const n=i.bindings,r={element:i.node,vnode:i,userData:i.userData},a=e.trim();if(t.includes(a)&&"function"==typeof n?.get(a)){const e=a,t=n?.get(e);return t(s,r)}const o=t.map(e=>i.bindings?.get(e)),h=[...t,"entries","$ctx"].join(", ");return new Function(h,`return (${e});`).call(n?.raw,...o,s,r)}}}class Et{#i;#s;#n;#a;#be;#Ee=new Set;constructor(e){this.#i=e.vNode;const t=e.attribute.name;if(t.startsWith("v-model.")){t.split(".").slice(1).forEach(e=>this.#Ee.add(e))}const i=e.attribute.value;i&&(this.#a=i,this.#s=at.extractIdentifiers(i,e.vNode.vApplication.functionDependencies),this.#n=this.#p(i),this.#Ne()),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_MODEL}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){const e=this.#s??[];return{get dependentIdentifiers(){return e},applyToDOM:()=>{this.#c()}}}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){if(this.#be){const e=this.#i.node,t=this.#_e();e.removeEventListener(t,this.#be)}}#c(){const e=this.#i.node;if(!this.#n)return;const t=this.#n();e instanceof HTMLInputElement?"checkbox"===e.type?e.checked=!!t:"radio"===e.type?e.checked=e.value===String(t):e.value=t??"":(e instanceof HTMLTextAreaElement||e instanceof HTMLSelectElement)&&(e.value=t??"")}#Ne(){const e=this.#i.node,t=this.#_e();this.#be=e=>{const t=e.target;let i;t instanceof HTMLInputElement?i="checkbox"===t.type?t.checked:(t.type,t.value):(t instanceof HTMLTextAreaElement||t instanceof HTMLSelectElement)&&(i=t.value),i=this.#Se(i),this.#we(i)},e.addEventListener(t,this.#be)}#Se(e){if("boolean"==typeof e)return e;let t=e;if(this.#Ee.has("trim")&&"string"==typeof t&&(t=t.trim()),this.#Ee.has("number")&&""!==t){const e=Number(t);isNaN(e)||(t=e)}return t}#_e(){const e=this.#i.node;return this.#Ee.has("lazy")?"change":e instanceof HTMLInputElement?"checkbox"===e.type||"radio"===e.type?"change":"input":e instanceof HTMLSelectElement?"change":"input"}#we(e){if(!this.#a)return;const t=this.#a.trim(),i=[e],s=["$newValue"].join(", ");new Function(s,`(this.${t} = $newValue);`).call(this.#i.bindings?.raw,...i)}#p(e){const t=this.#s??[],i=t.join(", "),s=new Function(i,`return (${e});`);return()=>{const e=t.map(e=>this.#i.bindings?.get(e));return s(...e)}}}class Nt{#i;#s;#ve;#Ie;#Ee=new Set;#be;#ke=new Map;constructor(e){this.#i=e.vNode;const t=e.attribute.name;if(t.startsWith("v-on:")){const e=t.substring(5).split(".");this.#Ie=e[0],e.slice(1).forEach(e=>this.#Ee.add(e))}else if(t.startsWith("@")){const e=t.substring(1).split(".");this.#Ie=e[0],e.slice(1).forEach(e=>this.#Ee.add(e))}const i=e.attribute.value;if(i&&(this.#s=at.extractIdentifiers(i,e.vNode.vApplication.functionDependencies)),this.#Ie&&this.#Ce(this.#Ie)){if(i){const e=this.#Ae(i);this.#ve=e,this.#ke.set(this.#Ie,e)}}else this.#Ie&&(i&&(this.#ve=this.#Ve(i)),this.#Ne());this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_ON}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get onMount(){return this.#ke.get("mount")}get onMounted(){return this.#ke.get("mounted")}get onUpdate(){return this.#ke.get("update")}get onUpdated(){return this.#ke.get("updated")}get onUnmount(){return this.#ke.get("unmount")}get onUnmounted(){return this.#ke.get("unmounted")}destroy(){if(this.#Ie&&this.#be){const e=this.#i.node,t=this.#Ee.has("capture");e.removeEventListener(this.#Ie,this.#be,t)}}#Ne(){if(!this.#Ie||!this.#ve)return;const e=this.#i.node,t=this.#Ie,i=this.#Ee.has("capture"),s=this.#Ee.has("once");this.#be=n=>{if(n instanceof KeyboardEvent){if(["enter","tab","delete","esc","space","up","down","left","right"].some(e=>this.#Ee.has(e))){const e={enter:"Enter",tab:"Tab",delete:"Delete",esc:"Escape",space:" ",up:"ArrowUp",down:"ArrowDown",left:"ArrowLeft",right:"ArrowRight"};let t=!1;for(const[i,s]of Object.entries(e))if(this.#Ee.has(i)&&n.key===s){t=!0;break}if(!t)return}}this.#Ee.has("stop")&&n.stopPropagation(),this.#Ee.has("prevent")&&n.preventDefault(),this.#Ee.has("self")&&n.target!==e||(this.#ve(n),s&&this.#be&&e.removeEventListener(t,this.#be,i))},e.addEventListener(t,this.#be,i)}#Ce(e){return["mount","mounted","update","updated","unmount","unmounted"].includes(e)}#Ae(e){const t=this.#s??[],i=this.#i;return()=>{const s=i.bindings,n={element:i.node,vnode:i,userData:i.userData},r=e.trim();if(t.includes(r)&&"function"==typeof s?.get(r)){const e=r,t=s?.get(e);return t(n)}const a=t.map(e=>i.bindings?.get(e)),o=[...t,"$ctx"].join(", ");return new Function(o,`return (${e});`).call(s?.raw,...a,n)}}#Ve(e){const t=this.#s??[],i=this.#i;return s=>{const n=i.bindings,r={element:i.node,vnode:i,userData:i.userData},a=e.trim();if(t.includes(a)&&"function"==typeof n?.get(a)){const e=a,t=n?.get(e);return t(s,r)}const o=t.map(e=>i.bindings?.get(e)),h=[...t,"event","$ctx"].join(", ");return new Function(h,`return (${e});`).call(n?.raw,...o,s,r)}}}class _t{#i;#s;#ve;#Pe;constructor(e){this.#i=e.vNode;const t=e.attribute.value;t&&(this.#s=at.extractIdentifiers(t,e.vNode.vApplication.functionDependencies),this.#ve=this.#Te(t)),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_PERFORMANCE}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get onMount(){}get onMounted(){if(!this.#ve)return;const e=this.#ve;return()=>{let t,i=this.#i.directiveManager?.optionsDirective("performance");if(i&&i.expression){const e=i.dependentIdentifiers,s=e.map(e=>this.#i.bindings?.get(e)),n=e.join(", "),r=`return (${i.expression});`;t=new Function(n,r)(...s)}this.#Pe=new PerformanceObserver((...t)=>{const[i,s,n]=t;e(i,s,n)}),t||(t={entryTypes:["mark","measure"]}),this.#Pe.observe(t)}}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){this.#Pe&&(this.#Pe.disconnect(),this.#Pe=void 0)}#Te(e){const t=this.#s??[],i=this.#i;return(s,n,r)=>{const a=i.bindings,o={element:i.node,vnode:i,userData:i.userData},h=e.trim();if(t.includes(h)&&"function"==typeof a?.get(h)){const e=h,t=a?.get(e);return t(s,n,r,o)}const p=t.map(e=>i.bindings?.get(e)),c=[...t,"entries","observer","options","$ctx"].join(", ");return new Function(c,`return (${e});`).call(a?.raw,...p,s,n,r,o)}}}class St{#i;#s;#ve;#De;constructor(e){this.#i=e.vNode;const t=e.attribute.value;t&&(this.#s=at.extractIdentifiers(t,e.vNode.vApplication.functionDependencies),this.#ve=this.#Le(t)),this.#i.node.removeAttribute(e.attribute.name)}get name(){return n.V_RESIZE}get vNode(){return this.#i}get needsAnchor(){return!1}get bindingsPreparer(){}get domUpdater(){}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}get onMount(){}get onMounted(){if(!this.#ve)return;const e=this.#i.node,t=this.#ve;return()=>{let i,s=this.#i.directiveManager?.optionsDirective("resize");if(s&&s.expression){const e=s.dependentIdentifiers,t=e.map(e=>this.#i.bindings?.get(e)),n=e.join(", "),r=`return (${s.expression});`;i=new Function(n,r)(...t)}this.#De=new ResizeObserver(e=>{t(e)}),this.#De.observe(e,i)}}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){this.#De&&(this.#De.disconnect(),this.#De=void 0)}#Le(e){const t=this.#s??[],i=this.#i;return s=>{const n=i.bindings,r={element:i.node,vnode:i,userData:i.userData},a=e.trim();if(t.includes(a)&&"function"==typeof n?.get(a)){const e=a,t=n?.get(e);return t(s,r)}const o=t.map(e=>i.bindings?.get(e)),h=[...t,"entries","$ctx"].join(", ");return new Function(h,`return (${e});`).call(n?.raw,...o,s,r)}}}class wt{#i;#s;#n;#Me;constructor(e){this.#i=e.vNode;const t=e.attribute.value;this.#s=at.extractIdentifiers(t,e.vNode.vApplication.functionDependencies),this.#n=this.#p(t),this.#i.node.removeAttribute(e.attribute.name);const i=this.#i.node;this.#Me="none"===i.style.display?"":i.style.display}get name(){return n.V_SHOW}get vNode(){return this.#i}get needsAnchor(){return!0}get bindingsPreparer(){}get domUpdater(){const e=this.#s??[],t=this.#n,i=()=>this.visibleNode(),s=()=>this.invisibleNode();return{get dependentIdentifiers(){return e},applyToDOM(){t()?i():s()}}}get templatize(){return!1}get dependentIdentifiers(){return this.#s??[]}visibleNode(){const e=this.#i.node;"none"!==e.style.display&&(e.style.display=this.#Me)}invisibleNode(){const e=this.#i.node;"none"!==e.style.display&&(this.#Me="none"===e.style.display?"":e.style.display,e.style.display="none")}get onMount(){}get onMounted(){}get onUpdate(){}get onUpdated(){}get onUnmount(){}get onUnmounted(){}destroy(){}#p(e){const t=this.#s??[],i=t.join(", "),s=new Function(i,`return (${e});`);return()=>{const e=t.map(e=>this.#i.bindings?.get(e));return Boolean(s(...e))}}}class It{get name(){return"VStandardDirectiveParser"}canParse(e){return!!(e.attribute.name===n.V_IF||e.attribute.name===n.V_ELSE_IF||e.attribute.name===n.V_ELSE||e.attribute.name===n.V_SHOW||e.attribute.name===n.V_FOR||e.attribute.name.startsWith(n.V_ON+":")||e.attribute.name.startsWith("@")||e.attribute.name.startsWith(n.V_BIND+":")||e.attribute.name.startsWith(":")||e.attribute.name===n.V_MODEL||e.attribute.name.startsWith(n.V_MODEL+".")||e.attribute.name===n.V_RESIZE||e.attribute.name===n.V_INTERSECTION||e.attribute.name===n.V_PERFORMANCE||e.attribute.name===n.V_COMPONENT||e.attribute.name.startsWith(n.V_COMPONENT+"."))}parse(e){if(e.attribute.name===n.V_IF)return new yt(e);if(e.attribute.name===n.V_ELSE_IF)return new vt(e);if(e.attribute.name===n.V_ELSE)return new gt(e);if(e.attribute.name===n.V_SHOW)return new wt(e);if(e.attribute.name===n.V_FOR)return new xt(e);if(e.attribute.name.startsWith(n.V_ON+":")||e.attribute.name.startsWith("@"))return new Nt(e);if(e.attribute.name.startsWith(n.V_BIND+":")||e.attribute.name.startsWith(":"))return new ot(e);if(e.attribute.name===n.V_MODEL||e.attribute.name.startsWith(n.V_MODEL+"."))return new Et(e);if(e.attribute.name===n.V_RESIZE)return new St(e);if(e.attribute.name===n.V_INTERSECTION)return new bt(e);if(e.attribute.name===n.V_PERFORMANCE)return new _t(e);if(e.attribute.name===n.V_COMPONENT||e.attribute.name.startsWith(n.V_COMPONENT+"."))return new ht(e);throw new Error(`The attribute "${e.attribute.name}" cannot be parsed by ${this.name}.`)}}!function(e){e.DEBUG="debug",e.INFO="info",e.WARN="warn",e.ERROR="error"}(nt||(nt={}));class kt{#Re;#Oe;constructor(e,t){this.#Re=e,this.#Oe=t}get isDebugEnabled(){return[nt.DEBUG].includes(this.#Oe.logLevel)}get isInfoEnabled(){return[nt.DEBUG,nt.INFO].includes(this.#Oe.logLevel)}get isWarnEnabled(){return[nt.DEBUG,nt.INFO,nt.WARN].includes(this.#Oe.logLevel)}debug(e){this.isDebugEnabled&&console.debug(`[${this.#Re}] ${nt.DEBUG}: ${e}`)}info(e){this.isInfoEnabled&&console.info(`[${this.#Re}] ${nt.INFO}: ${e}`)}warn(e){this.isWarnEnabled&&console.warn(`[${this.#Re}] ${nt.WARN}: ${e}`)}error(e){console.error(`[${this.#Re}] ${nt.ERROR}: ${e}`)}}class Ct{#Fe;#Ue=new Map;constructor(e=nt.INFO){this.#Fe=e}set logLevel(e){this.#Fe=e}get logLevel(){return this.#Fe}getLogger(e){if(this.#Ue.has(e))return this.#Ue.get(e);const t=new kt(e,this);return this.#Ue.set(e,t),t}}class At{#Be;#We;#$e;#i;#$;#Oe;#S;#je;#ze;#He=!1;constructor(e,t,i){this.#Be=e,this.#We=t,this.#$e=i,this.#Oe=new Ct(e.logLevel),this.#S=this.#Oe.getLogger("VApplication"),this.#je=at.analyzeFunctionDependencies(e.methods||{}),this.#ze=at.analyzeFunctionDependencies(e.computed||{}),this.#qe()}get directiveParserRegistry(){return this.#We}get componentRegistry(){return this.#$e}get rootVNode(){return this.#i}get bindings(){return this.#$}get logManager(){return this.#Oe}get functionDependencies(){return this.#je}mount(e){let t;if("string"==typeof e){if(t=document.querySelector(e),!t)throw new Error(`Element not found for selector: ${e}`)}else t=e;this.#Ge(t),this.#i=new lt({node:t,vApplication:this,bindings:this.#$}),this.#i.update(),this.#S.info("Application mounted.")}unmount(){this.#i&&(this.#i.destroy(),this.#i=void 0),this.#S.info("Application unmounted.")}createChildApp(e){return new At(e,this.#We,this.#$e)}#Ge(e){let t=null;for(const i of Array.from(e.childNodes))if(i.nodeType===Node.TEXT_NODE){const s=i;/^[\s\n\r\t]*$/.test(s.nodeValue||"")?e.removeChild(s):t?(t.nodeValue+=s.nodeValue||"",e.removeChild(s)):t=s}else t=null,i.nodeType===Node.ELEMENT_NODE&&this.#Ge(i)}#qe(){if(this.#$=new ct({onChange:e=>{this.#Ke()},vApplication:this}),this.#$.set("$nextTick",e=>this.#Qe(e)),this.#Be.methods)for(const[e,t]of Object.entries(this.#Be.methods))"function"==typeof t?this.#$.set(e,t.bind(this.#$.raw)):this.#S.warn(`Method '${e}' is not a function and will be ignored.`);if(this.#Be.data){const e=this.#Be.data();if(e&&"object"==typeof e)for(const[t,i]of Object.entries(e))this.#$.set(t,i)}this.#Ze()}#Ke(){this.#He||(this.#He=!0,queueMicrotask(()=>{this.#Xe(),this.#He=!1}))}#Xe(){this.#Ze(),this.#i?.update(),this.#$?.clearChanges()}#Ze(){if(!this.#Be.computed)return;const e=new Set,t=new Set,i=new Set;this.#$?.changes.forEach(e=>{i.add(e);const t=e.indexOf("[");-1!==t&&i.add(e.substring(0,t))});const s=n=>{if(e.has(n))return;if(t.has(n))return void this.#S.error(`Circular dependency detected for computed property '${n}'`);t.add(n);const r=this.#ze[n]||[];if(!r.some(e=>i.has(e)))return void e.add(n);for(const e of r)this.#Be.computed[e]&&s(e);const a=this.#Be.computed[n];try{const e=this.#$?.get(n),t=a.call(this.#$?.raw);e!==t&&(this.#$?.set(n,t),i.add(n))}catch(e){this.#S.error(`Error evaluating computed property '${n}': ${e}`)}e.add(n),t.delete(n)};for(const[e,t]of Object.entries(this.#ze))t.some(e=>i.has(e))&&s(e)}#Qe(e){this.#He?queueMicrotask(()=>{queueMicrotask(e)}):queueMicrotask(e)}}class Vt{static#$e=new i;static#We=new s;static{this.#We.register(new It)}static get componentRegistry(){return this.#$e}static get directiveParserRegistry(){return this.#We}static get isSupported(){try{return"function"==typeof structuredClone&&("undefined"!=typeof document&&"function"==typeof document.createElement)}catch{return!1}}static createApp(e){return new At(e,this.#We,this.#$e)}}e.VComponent=t,e.VComponentRegistry=i,e.VDOM=Vt});
2
2
  //# sourceMappingURL=ichigo.umd.min.js.map