gyosjs 0.3.0 → 0.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/router/csp-html.d.ts +2 -0
- package/dist/core/router/csp-html.d.ts.map +1 -0
- package/dist/core/router/diff-nodes.d.ts.map +1 -1
- package/dist/core/router/router.d.ts.map +1 -1
- package/dist/gyos.auto.esm.js +279 -32
- package/dist/gyos.auto.esm.js.map +1 -1
- package/dist/gyos.auto.js +279 -32
- package/dist/gyos.auto.js.map +1 -1
- package/dist/gyos.auto.min.js +2 -2
- package/dist/gyos.csp.auto.esm.js +375 -208
- package/dist/gyos.csp.auto.esm.js.map +1 -1
- package/dist/gyos.csp.auto.js +375 -208
- package/dist/gyos.csp.auto.js.map +1 -1
- package/dist/gyos.csp.auto.min.js +2 -2
- package/dist/gyos.csp.esm.js +375 -208
- package/dist/gyos.csp.esm.js.map +1 -1
- package/dist/gyos.csp.js +375 -208
- package/dist/gyos.csp.js.map +1 -1
- package/dist/gyos.csp.min.js +2 -2
- package/dist/gyos.esm.js +279 -32
- package/dist/gyos.esm.js.map +1 -1
- package/dist/gyos.js +279 -32
- package/dist/gyos.js.map +1 -1
- package/dist/gyos.min.js +2 -2
- package/dist/runtime/csp-nonce.d.ts +1 -1
- package/dist/runtime/csp-nonce.d.ts.map +1 -1
- package/dist/template/process.d.ts.map +1 -1
- package/dist/template/structurals/transition-helpers.d.ts +1 -1
- package/dist/template/structurals/transition-helpers.d.ts.map +1 -1
- package/package.json +1 -1
- package/dist/runtime/install-csp.d.ts +0 -2
- package/dist/runtime/install-csp.d.ts.map +0 -1
- package/dist/runtime/install-standard.d.ts +0 -2
- package/dist/runtime/install-standard.d.ts.map +0 -1
package/dist/gyos.csp.min.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* GyosJS v0.3.
|
|
2
|
+
* GyosJS v0.3.2
|
|
3
3
|
* (c) 2026
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
|
-
var t,e;t=this,e=function(t){"use strict";var e=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,7,9,32,4,318,1,78,5,71,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,3,0,158,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,68,8,2,0,3,0,2,3,2,4,2,0,15,1,83,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,7,19,58,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,199,7,137,9,54,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,55,9,266,3,10,1,2,0,49,6,4,4,14,10,5350,0,7,14,11465,27,2343,9,87,9,39,4,60,6,26,9,535,9,470,0,2,54,8,3,82,0,12,1,19628,1,4178,9,519,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,101,0,161,6,10,9,357,0,62,13,499,13,245,1,2,9,233,0,3,0,8,1,6,0,475,6,110,6,6,9,4759,9,787719,239],n=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,4,51,13,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,7,25,39,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,39,27,10,22,251,41,7,1,17,5,57,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,20,1,64,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,31,9,2,0,3,0,2,37,2,0,26,0,2,0,45,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,200,32,32,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,24,43,261,18,16,0,2,12,2,33,125,0,80,921,103,110,18,195,2637,96,16,1071,18,5,26,3994,6,582,6842,29,1763,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,433,44,212,63,33,24,3,24,45,74,6,0,67,12,65,1,2,0,15,4,10,7381,42,31,98,114,8702,3,2,6,2,1,2,290,16,0,30,2,3,0,15,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,7,5,262,61,147,44,11,6,17,0,322,29,19,43,485,27,229,29,3,0,208,30,2,2,2,1,2,6,3,4,10,1,225,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4381,3,5773,3,7472,16,621,2467,541,1507,4938,6,8489],s="ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽ-ೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-Ა-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ--ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",r={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"},i="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",a={5:i,"5module":i+" export import",6:i+" const class extends export import super"},o=/^in(stanceof)?$/,c=RegExp("["+s+"]"),l=RegExp("["+s+"·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ--ᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・]");function u(t,e){for(var n=65536,s=0;s<e.length;s+=2){if((n+=e[s])>t)return!1;if((n+=e[s+1])>=t)return!0}return!1}function h(t,e){return 65>t?36===t:91>t||(97>t?95===t:123>t||(t>65535?!1!==e&&u(t,n):t>=170&&c.test(String.fromCharCode(t))))}function p(t,s){return 48>t?36===t:58>t||t>=65&&(91>t||(97>t?95===t:123>t||(t>65535?!1!==s&&(u(t,n)||u(t,e)):t>=170&&l.test(String.fromCharCode(t)))))}var f=function(t,e){void 0===e&&(e={}),this.label=t,this.keyword=e.keyword,this.beforeExpr=!!e.beforeExpr,this.startsExpr=!!e.startsExpr,this.isLoop=!!e.isLoop,this.isAssign=!!e.isAssign,this.prefix=!!e.prefix,this.postfix=!!e.postfix,this.binop=e.binop||null,this.updateContext=null};function d(t,e){return new f(t,{beforeExpr:!0,binop:e})}var m={beforeExpr:!0},g={startsExpr:!0},y={};function v(t,e){return void 0===e&&(e={}),e.keyword=t,y[t]=new f(t,e)}var x={num:new f("num",g),regexp:new f("regexp",g),string:new f("string",g),name:new f("name",g),privateId:new f("privateId",g),eof:new f("eof"),bracketL:new f("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new f("]"),braceL:new f("{",{beforeExpr:!0,startsExpr:!0}),braceR:new f("}"),parenL:new f("(",{beforeExpr:!0,startsExpr:!0}),parenR:new f(")"),comma:new f(",",m),semi:new f(";",m),colon:new f(":",m),dot:new f("."),question:new f("?",m),questionDot:new f("?."),arrow:new f("=>",m),template:new f("template"),invalidTemplate:new f("invalidTemplate"),ellipsis:new f("...",m),backQuote:new f("`",g),dollarBraceL:new f("${",{beforeExpr:!0,startsExpr:!0}),eq:new f("=",{beforeExpr:!0,isAssign:!0}),assign:new f("_=",{beforeExpr:!0,isAssign:!0}),incDec:new f("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new f("!/~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:d("||",1),logicalAND:d("&&",2),bitwiseOR:d("|",3),bitwiseXOR:d("^",4),bitwiseAND:d("&",5),equality:d("==/!=/===/!==",6),relational:d("</>/<=/>=",7),bitShift:d("<</>>/>>>",8),plusMin:new f("+/-",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:d("%",10),star:d("*",10),slash:d("/",10),starstar:new f("**",{beforeExpr:!0}),coalesce:d("??",1),_break:v("break"),_case:v("case",m),_catch:v("catch"),_continue:v("continue"),_debugger:v("debugger"),_default:v("default",m),_do:v("do",{isLoop:!0,beforeExpr:!0}),_else:v("else",m),_finally:v("finally"),_for:v("for",{isLoop:!0}),_function:v("function",g),_if:v("if"),_return:v("return",m),_switch:v("switch"),_throw:v("throw",m),_try:v("try"),_var:v("var"),_const:v("const"),_while:v("while",{isLoop:!0}),_with:v("with"),_new:v("new",{beforeExpr:!0,startsExpr:!0}),_this:v("this",g),_super:v("super",g),_class:v("class",g),_extends:v("extends",m),_export:v("export"),_import:v("import",g),_null:v("null",g),_true:v("true",g),_false:v("false",g),_in:v("in",{beforeExpr:!0,binop:7}),_instanceof:v("instanceof",{beforeExpr:!0,binop:7}),_typeof:v("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:v("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:v("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})},b=/\r\n?|\n|\u2028|\u2029/,_=RegExp(b.source,"g");function w(t){return 10===t||13===t||8232===t||8233===t}function E(t,e,n){void 0===n&&(n=t.length);for(var s=e;n>s;s++){var r=t.charCodeAt(s);if(w(r))return n-1>s&&13===r&&10===t.charCodeAt(s+1)?s+2:s+1}return-1}var S=/[\u1680\u2000-\u200a\u202f\u205f\u3000\ufeff]/,k=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g,C=Object.prototype,A=C.hasOwnProperty,I=C.toString,T=Object.hasOwn||function(t,e){return A.call(t,e)},P=Array.isArray||function(t){return"[object Array]"===I.call(t)},N=Object.create(null);function L(t){return N[t]||(N[t]=RegExp("^(?:"+t.replace(/ /g,"|")+")$"))}function M(t){return t>65535?(t-=65536,String.fromCharCode(55296+(t>>10),56320+(1023&t))):String.fromCharCode(t)}var V=/(?:[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])/,O=function(t,e){this.line=t,this.column=e};O.prototype.offset=function(t){return new O(this.line,this.column+t)};var R=function(t,e,n){this.start=e,this.end=n,null!==t.sourceFile&&(this.source=t.sourceFile)};function D(t,e){for(var n=1,s=0;;){var r=E(t,s,e);if(0>r)return new O(n,e-s);++n,s=r}}var F={ecmaVersion:null,sourceType:"script",strict:!1,onInsertedSemicolon:null,onTrailingComma:null,allowReserved:null,allowReturnOutsideFunction:!1,allowImportExportEverywhere:!1,allowAwaitOutsideFunction:null,allowSuperOutsideMethod:null,allowHashBang:!1,checkPrivateFields:!0,locations:!1,startLocation:null,onToken:null,onComment:null,ranges:!1,program:null,sourceFile:null,directSourceFile:null,preserveParens:!1},B=!1;function U(t,e){return 2|(t?4:0)|(e?8:0)}var j=function(t,e,n){this.options=t=function(t){var e={};for(var n in F)e[n]=t&&T(t,n)?t[n]:F[n];if("latest"===e.ecmaVersion?e.ecmaVersion=1e8:null==e.ecmaVersion?(!B&&"object"==typeof console&&console.warn&&(B=!0),e.ecmaVersion=11):2015>e.ecmaVersion||(e.ecmaVersion-=2009),null==e.allowReserved&&(e.allowReserved=5>e.ecmaVersion),t&&null!=t.allowHashBang||(e.allowHashBang=e.ecmaVersion>=14),P(e.onToken)){var s=e.onToken;e.onToken=function(t){return s.push(t)}}if(P(e.onComment)&&(e.onComment=function(t,e){return function(n,s,r,i,a,o){var c={type:n?"Block":"Line",value:s,start:r,end:i};t.locations&&(c.loc=new R(this,a,o)),t.ranges&&(c.range=[r,i]),e.push(c)}}(e,e.onComment)),"commonjs"===e.sourceType&&e.allowAwaitOutsideFunction)throw Error("Cannot use allowAwaitOutsideFunction with sourceType: commonjs");return e}(t),this.sourceFile=t.sourceFile,this.keywords=L(a[6>t.ecmaVersion?"module"===t.sourceType?"5module":5:6]);var s="";!0!==t.allowReserved&&(s=r[6>t.ecmaVersion?5===t.ecmaVersion?5:3:6],"module"===t.sourceType&&(s+=" await")),this.reservedWords=L(s);var i=(s?s+" ":"")+r.strict;this.reservedWordsStrict=L(i),this.reservedWordsStrictBind=L(i+" "+r.strictBind),this.input=e+"",this.containsEsc=!1,this.pos=n||0,this.curLine=1,t.startLocation?(this.lineStart=this.pos-t.startLocation.column,this.curLine=t.startLocation.line):n?(this.lineStart=this.input.lastIndexOf("\n",n-1)+1,this.options.locations&&(this.curLine=this.input.slice(0,this.lineStart).split(b).length)):this.lineStart=0,this.type=x.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"===t.sourceType,this.strict=this.inModule||!0===t.strict||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&&t.allowHashBang&&"#!"===this.input.slice(0,2)&&this.skipLineComment(2),this.scopeStack=[],this.enterScope("commonjs"===this.options.sourceType?2:1),this.regexpState=null,this.privateNameStack=[]},W={inFunction:{configurable:!0},inGenerator:{configurable:!0},inAsync:{configurable:!0},canAwait:{configurable:!0},allowReturn:{configurable:!0},allowSuper:{configurable:!0},allowDirectSuper:{configurable:!0},treatFunctionsAsVar:{configurable:!0},allowNewDotTarget:{configurable:!0},allowUsing:{configurable:!0},inClassStaticBlock:{configurable:!0}};j.prototype.parse=function(){var t=this,e=this.options.program||this.startNode();return this.nextToken(),this.catchStackOverflow(function(){return t.parseTopLevel(e)})},W.inFunction.get=function(){return(2&this.currentVarScope().flags)>0},W.inGenerator.get=function(){return(8&this.currentVarScope().flags)>0},W.inAsync.get=function(){return(4&this.currentVarScope().flags)>0},W.canAwait.get=function(){for(var t=this.scopeStack.length-1;t>=0;t--){var e=this.scopeStack[t].flags;if(768&e)return!1;if(2&e)return(4&e)>0}return this.inModule&&this.options.ecmaVersion>=13||this.options.allowAwaitOutsideFunction},W.allowReturn.get=function(){return!!this.inFunction||!!(this.options.allowReturnOutsideFunction&&1&this.currentVarScope().flags)},W.allowSuper.get=function(){return(64&this.currentThisScope().flags)>0||this.options.allowSuperOutsideMethod},W.allowDirectSuper.get=function(){return(128&this.currentThisScope().flags)>0},W.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())},W.allowNewDotTarget.get=function(){for(var t=this.scopeStack.length-1;t>=0;t--){var e=this.scopeStack[t].flags;if(768&e||2&e&&!(16&e))return!0}return!1},W.allowUsing.get=function(){var t=this.currentScope().flags;return!(1024&t||!this.inModule&&1&t)},W.inClassStaticBlock.get=function(){return(256&this.currentVarScope().flags)>0},j.extend=function(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];for(var n=this,s=0;s<t.length;s++)n=t[s](n);return n},j.parse=function(t,e){return new this(e,t).parse()},j.parseExpressionAt=function(t,e,n){var s=new this(n,t,e);return s.nextToken(),s.parseExpression()},j.tokenizer=function(t,e){return new this(e,t)},Object.defineProperties(j.prototype,W);var $=j.prototype,q=/^(?:'((?:\\[^]|[^'\\])*?)'|"((?:\\[^]|[^"\\])*?)")/;$.strictDirective=function(t){if(5>this.options.ecmaVersion)return!1;for(;;){k.lastIndex=t,t+=k.exec(this.input)[0].length;var e=q.exec(this.input.slice(t));if(!e)return!1;if("use strict"===(e[1]||e[2])){k.lastIndex=t+e[0].length;var n=k.exec(this.input),s=n.index+n[0].length,r=this.input.charAt(s);return";"===r||"}"===r||b.test(n[0])&&!(/[(`.[+\-/*%<>=,?^&]/.test(r)||"!"===r&&"="===this.input.charAt(s+1))}t+=e[0].length,k.lastIndex=t,t+=k.exec(this.input)[0].length,";"===this.input[t]&&t++}},$.eat=function(t){return this.type===t&&(this.next(),!0)},$.isContextual=function(t){return this.type===x.name&&this.value===t&&!this.containsEsc},$.eatContextual=function(t){return!!this.isContextual(t)&&(this.next(),!0)},$.catchStackOverflow=function(t){try{return t()}catch(t){if(!(t instanceof Error&&(/\bstack\b.*\b(exceeded|overflow)\b/i.test(t.message)||/\btoo much recursion\b/i.test(t.message))))throw t;this.raise(this.start,"Not enough stack space to parse input")}},$.expectContextual=function(t){this.eatContextual(t)||this.unexpected()},$.canInsertSemicolon=function(){return this.type===x.eof||this.type===x.braceR||b.test(this.input.slice(this.lastTokEnd,this.start))},$.insertSemicolon=function(){if(this.canInsertSemicolon())return this.options.onInsertedSemicolon&&this.options.onInsertedSemicolon(this.lastTokEnd,this.lastTokEndLoc),!0},$.semicolon=function(){this.eat(x.semi)||this.insertSemicolon()||this.unexpected()},$.afterTrailingComma=function(t,e){if(this.type===t)return this.options.onTrailingComma&&this.options.onTrailingComma(this.lastTokStart,this.lastTokStartLoc),e||this.next(),!0},$.expect=function(t){this.eat(t)||this.unexpected()},$.unexpected=function(t){this.raise(null!=t?t:this.start,"Unexpected token")};var H=function(){this.shorthandAssign=this.trailingComma=this.parenthesizedAssign=this.parenthesizedBind=this.doubleProto=-1};$.checkPatternErrors=function(t,e){if(t){t.trailingComma>-1&&this.raiseRecoverable(t.trailingComma,"Comma is not permitted after the rest element");var n=e?t.parenthesizedAssign:t.parenthesizedBind;n>-1&&this.raiseRecoverable(n,e?"Assigning to rvalue":"Parenthesized pattern")}},$.checkExpressionErrors=function(t,e){if(!t)return!1;var n=t.shorthandAssign,s=t.doubleProto;if(!e)return n>=0||s>=0;0>n||this.raise(n,"Shorthand property assignments are valid only in destructuring patterns"),0>s||this.raiseRecoverable(s,"Redefinition of __proto__ property")},$.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")},$.isSimpleAssignTarget=function(t){return"ParenthesizedExpression"===t.type?this.isSimpleAssignTarget(t.expression):"Identifier"===t.type||"MemberExpression"===t.type};var G=j.prototype;G.parseTopLevel=function(t){var e=Object.create(null);for(t.body||(t.body=[]);this.type!==x.eof;){var n=this.parseStatement(null,!0,e);t.body.push(n)}if(this.inModule)for(var s=0,r=Object.keys(this.undefinedExports);s<r.length;s+=1){var i=r[s];this.raiseRecoverable(this.undefinedExports[i].start,"Export '"+i+"' is not defined")}return this.adaptDirectivePrologue(t.body),this.next(),t.sourceType="commonjs"===this.options.sourceType?"script":this.options.sourceType,this.finishNode(t,"Program")};var z={kind:"loop"},Y={kind:"switch"};G.isLet=function(t){if(6>this.options.ecmaVersion||!this.isContextual("let"))return!1;k.lastIndex=this.pos;var e=k.exec(this.input),n=this.pos+e[0].length,s=this.fullCharCodeAt(n);if(91===s||92===s)return!0;if(t)return!1;if(123===s)return!0;if(h(s)){var r=n;do{n+=s>65535?2:1}while(p(s=this.fullCharCodeAt(n)));if(92===s)return!0;var i=this.input.slice(r,n);if(!o.test(i))return!0}return!1},G.isAsyncFunction=function(){if(8>this.options.ecmaVersion||!this.isContextual("async"))return!1;k.lastIndex=this.pos;var t,e=k.exec(this.input),n=this.pos+e[0].length;return!(b.test(this.input.slice(this.pos,n))||"function"!==this.input.slice(n,n+8)||n+8!==this.input.length&&(p(t=this.fullCharCodeAt(n+8))||92===t))},G.isUsingKeyword=function(t,e){if(17>this.options.ecmaVersion||!this.isContextual(t?"await":"using"))return!1;k.lastIndex=this.pos;var n=k.exec(this.input),s=this.pos+n[0].length;if(b.test(this.input.slice(this.pos,s)))return!1;if(t){var r,i=s+5;if("using"!==this.input.slice(s,i)||i===this.input.length||p(r=this.fullCharCodeAt(i))||92===r)return!1;k.lastIndex=i;var a=k.exec(this.input);if(s=i+a[0].length,a&&b.test(this.input.slice(i,s)))return!1}var c=this.fullCharCodeAt(s);if(!h(c)&&92!==c)return!1;var l=s;do{s+=c>65535?2:1}while(p(c=this.fullCharCodeAt(s)));if(92===c)return!0;var u=this.input.slice(l,s);return!(o.test(u)||e&&!t&&"of"===u&&(k.lastIndex=s,s+=k.exec(this.input)[0].length,61!==this.input.charCodeAt(s)||61===(c=this.input.charCodeAt(s+1))||62===c))},G.isAwaitUsing=function(t){return this.isUsingKeyword(!0,t)},G.isUsing=function(t){return this.isUsingKeyword(!1,t)},G.parseStatement=function(t,e,n){var s,r=this.type,i=this.startNode();switch(this.isLet(t)&&(r=x._var,s="let"),r){case x._break:case x._continue:return this.parseBreakContinueStatement(i,r.keyword);case x._debugger:return this.parseDebuggerStatement(i);case x._do:return this.parseDoStatement(i);case x._for:return this.parseForStatement(i);case x._function:return t&&(this.strict||"if"!==t&&"label"!==t)&&this.options.ecmaVersion>=6&&this.unexpected(),this.parseFunctionStatement(i,!1,!t);case x._class:return t&&this.unexpected(),this.parseClass(i,!0);case x._if:return this.parseIfStatement(i);case x._return:return this.parseReturnStatement(i);case x._switch:return this.parseSwitchStatement(i);case x._throw:return this.parseThrowStatement(i);case x._try:return this.parseTryStatement(i);case x._const:case x._var:return s=s||this.value,t&&"var"!==s&&this.unexpected(),this.parseVarStatement(i,s);case x._while:return this.parseWhileStatement(i);case x._with:return this.parseWithStatement(i);case x.braceL:return this.parseBlock(!0,i);case x.semi:return this.parseEmptyStatement(i);case x._export:case x._import:if(this.options.ecmaVersion>10&&r===x._import){k.lastIndex=this.pos;var a=k.exec(this.input),o=this.pos+a[0].length,c=this.input.charCodeAt(o);if(40===c||46===c)return this.parseExpressionStatement(i,this.parseExpression())}return this.options.allowImportExportEverywhere||(e||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'")),r===x._import?this.parseImport(i):this.parseExport(i,n);default:if(this.isAsyncFunction())return t&&this.unexpected(),this.next(),this.parseFunctionStatement(i,!0,!t);var l=this.isAwaitUsing(!1)?"await using":this.isUsing(!1)?"using":null;if(l)return this.allowUsing||this.raise(this.start,"Using declaration cannot appear in the top level when source type is `script` or in the bare case statement"),t&&this.raise(this.start,"Using declaration is not allowed in single-statement positions"),"await using"===l&&(this.canAwait||this.raise(this.start,"Await using cannot appear outside of async function"),this.next()),this.next(),this.parseVar(i,!1,l),this.semicolon(),this.finishNode(i,"VariableDeclaration");var u=this.value,h=this.parseExpression();return r===x.name&&"Identifier"===h.type&&this.eat(x.colon)?this.parseLabeledStatement(i,u,h,t):this.parseExpressionStatement(i,h)}},G.parseBreakContinueStatement=function(t,e){var n="break"===e;this.next(),this.eat(x.semi)||this.insertSemicolon()?t.label=null:this.type!==x.name?this.unexpected():(t.label=this.parseIdent(),this.semicolon());for(var s=0;s<this.labels.length;++s){var r=this.labels[s];if(null==t.label||r.name===t.label.name){if(null!=r.kind&&(n||"loop"===r.kind))break;if(t.label&&n)break}}return s===this.labels.length&&this.raise(t.start,"Unsyntactic "+e),this.finishNode(t,n?"BreakStatement":"ContinueStatement")},G.parseDebuggerStatement=function(t){return this.next(),this.semicolon(),this.finishNode(t,"DebuggerStatement")},G.parseDoStatement=function(t){return this.next(),this.labels.push(z),t.body=this.parseStatement("do"),this.labels.pop(),this.expect(x._while),t.test=this.parseParenExpression(),6>this.options.ecmaVersion?this.semicolon():this.eat(x.semi),this.finishNode(t,"DoWhileStatement")},G.parseForStatement=function(t){this.next();var e=this.options.ecmaVersion>=9&&this.canAwait&&this.eatContextual("await")?this.lastTokStart:-1;if(this.labels.push(z),this.enterScope(0),this.expect(x.parenL),this.type===x.semi)return e>-1&&this.unexpected(e),this.parseFor(t,null);var n=this.isLet();if(this.type===x._var||this.type===x._const||n){var s=this.startNode(),r=n?"let":this.value;return this.next(),this.parseVar(s,!0,r),this.finishNode(s,"VariableDeclaration"),this.parseForAfterInit(t,s,e)}var i=this.isContextual("let"),a=!1,o=this.isUsing(!0)?"using":this.isAwaitUsing(!0)?"await using":null;if(o){var c=this.startNode();return this.next(),"await using"===o&&(this.canAwait||this.raise(this.start,"Await using cannot appear outside of async function"),this.next()),this.parseVar(c,!0,o),this.finishNode(c,"VariableDeclaration"),this.parseForAfterInit(t,c,e)}var l=this.containsEsc,u=new H,h=this.start,p=e>-1?this.parseExprSubscripts(u,"await"):this.parseExpression(!0,u);return this.type===x._in||(a=this.options.ecmaVersion>=6&&this.isContextual("of"))?(e>-1?(this.type===x._in&&this.unexpected(e),t.await=!0):a&&this.options.ecmaVersion>=8&&(p.start!==h||l||"Identifier"!==p.type||"async"!==p.name?9>this.options.ecmaVersion||(t.await=!1):this.unexpected()),i&&a&&this.raise(p.start,"The left-hand side of a for-of loop may not start with 'let'."),this.toAssignable(p,!1,u),this.checkLValPattern(p),this.parseForIn(t,p)):(this.checkExpressionErrors(u,!0),e>-1&&this.unexpected(e),this.parseFor(t,p))},G.parseForAfterInit=function(t,e,n){return(this.type===x._in||this.options.ecmaVersion>=6&&this.isContextual("of"))&&1===e.declarations.length?(this.type===x._in?("using"!==e.kind&&"await using"!==e.kind||e.declarations[0].init||this.raise(this.start,"Using declaration is not allowed in for-in loops"),this.options.ecmaVersion>=9&&n>-1&&this.unexpected(n)):9>this.options.ecmaVersion||(t.await=n>-1),this.parseForIn(t,e)):(n>-1&&this.unexpected(n),this.parseFor(t,e))},G.parseFunctionStatement=function(t,e,n){return this.next(),this.parseFunction(t,J|(n?0:Q),!1,e)},G.parseIfStatement=function(t){return this.next(),t.test=this.parseParenExpression(),t.consequent=this.parseStatement("if"),t.alternate=this.eat(x._else)?this.parseStatement("if"):null,this.finishNode(t,"IfStatement")},G.parseReturnStatement=function(t){return this.allowReturn||this.raise(this.start,"'return' outside of function"),this.next(),this.eat(x.semi)||this.insertSemicolon()?t.argument=null:(t.argument=this.parseExpression(),this.semicolon()),this.finishNode(t,"ReturnStatement")},G.parseSwitchStatement=function(t){var e;this.next(),t.discriminant=this.parseParenExpression(),t.cases=[],this.expect(x.braceL),this.labels.push(Y),this.enterScope(1024);for(var n=!1;this.type!==x.braceR;)if(this.type===x._case||this.type===x._default){var s=this.type===x._case;e&&this.finishNode(e,"SwitchCase"),t.cases.push(e=this.startNode()),e.consequent=[],this.next(),s?e.test=this.parseExpression():(n&&this.raiseRecoverable(this.lastTokStart,"Multiple default clauses"),n=!0,e.test=null),this.expect(x.colon)}else e||this.unexpected(),e.consequent.push(this.parseStatement(null));return this.exitScope(),e&&this.finishNode(e,"SwitchCase"),this.next(),this.labels.pop(),this.finishNode(t,"SwitchStatement")},G.parseThrowStatement=function(t){return this.next(),b.test(this.input.slice(this.lastTokEnd,this.start))&&this.raise(this.lastTokEnd,"Illegal newline after throw"),t.argument=this.parseExpression(),this.semicolon(),this.finishNode(t,"ThrowStatement")};var K=[];G.parseCatchClauseParam=function(){var t=this.parseBindingAtom(),e="Identifier"===t.type;return this.enterScope(e?32:0),this.checkLValPattern(t,e?4:2),this.expect(x.parenR),t},G.parseTryStatement=function(t){if(this.next(),t.block=this.parseBlock(),t.handler=null,this.type===x._catch){var e=this.startNode();this.next(),this.eat(x.parenL)?e.param=this.parseCatchClauseParam():(10>this.options.ecmaVersion&&this.unexpected(),e.param=null,this.enterScope(0)),e.body=this.parseBlock(!1),this.exitScope(),t.handler=this.finishNode(e,"CatchClause")}return t.finalizer=this.eat(x._finally)?this.parseBlock():null,t.handler||t.finalizer||this.raise(t.start,"Missing catch or finally clause"),this.finishNode(t,"TryStatement")},G.parseVarStatement=function(t,e,n){return this.next(),this.parseVar(t,!1,e,n),this.semicolon(),this.finishNode(t,"VariableDeclaration")},G.parseWhileStatement=function(t){return this.next(),t.test=this.parseParenExpression(),this.labels.push(z),t.body=this.parseStatement("while"),this.labels.pop(),this.finishNode(t,"WhileStatement")},G.parseWithStatement=function(t){return this.strict&&this.raise(this.start,"'with' in strict mode"),this.next(),t.object=this.parseParenExpression(),t.body=this.parseStatement("with"),this.finishNode(t,"WithStatement")},G.parseEmptyStatement=function(t){return this.next(),this.finishNode(t,"EmptyStatement")},G.parseLabeledStatement=function(t,e,n,s){for(var r=0,i=this.labels;r<i.length;r+=1)i[r].name===e&&this.raise(n.start,"Label '"+e+"' is already declared");for(var a=this.type.isLoop?"loop":this.type===x._switch?"switch":null,o=this.labels.length-1;o>=0;o--){var c=this.labels[o];if(c.statementStart!==t.start)break;c.statementStart=this.start,c.kind=a}return this.labels.push({name:e,kind:a,statementStart:this.start}),t.body=this.parseStatement(s?-1===s.indexOf("label")?s+"label":s:"label"),this.labels.pop(),t.label=n,this.finishNode(t,"LabeledStatement")},G.parseExpressionStatement=function(t,e){return t.expression=e,this.semicolon(),this.finishNode(t,"ExpressionStatement")},G.parseBlock=function(t,e,n){for(void 0===t&&(t=!0),void 0===e&&(e=this.startNode()),e.body=[],this.expect(x.braceL),t&&this.enterScope(0);this.type!==x.braceR;){var s=this.parseStatement(null);e.body.push(s)}return n&&(this.strict=!1),this.next(),t&&this.exitScope(),this.finishNode(e,"BlockStatement")},G.parseFor=function(t,e){return t.init=e,this.expect(x.semi),t.test=this.type===x.semi?null:this.parseExpression(),this.expect(x.semi),t.update=this.type===x.parenR?null:this.parseExpression(),this.expect(x.parenR),t.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(t,"ForStatement")},G.parseForIn=function(t,e){var n=this.type===x._in;return this.next(),"VariableDeclaration"!==e.type||null==e.declarations[0].init||n&&this.options.ecmaVersion>=8&&!this.strict&&"var"===e.kind&&"Identifier"===e.declarations[0].id.type||this.raise(e.start,(n?"for-in":"for-of")+" loop variable declaration may not have an initializer"),t.left=e,t.right=n?this.parseExpression():this.parseMaybeAssign(),this.expect(x.parenR),t.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(t,n?"ForInStatement":"ForOfStatement")},G.parseVar=function(t,e,n,s){for(t.declarations=[],t.kind=n;;){var r=this.startNode();if(this.parseVarId(r,n),this.eat(x.eq)?r.init=this.parseMaybeAssign(e):s||"const"!==n||this.type===x._in||this.options.ecmaVersion>=6&&this.isContextual("of")?s||"using"!==n&&"await using"!==n||17>this.options.ecmaVersion||this.type===x._in||this.isContextual("of")?s||"Identifier"===r.id.type||e&&(this.type===x._in||this.isContextual("of"))?r.init=null:this.raise(this.lastTokEnd,"Complex binding patterns require an initialization value"):this.raise(this.lastTokEnd,"Missing initializer in "+n+" declaration"):this.unexpected(),t.declarations.push(this.finishNode(r,"VariableDeclarator")),!this.eat(x.comma))break}return t},G.parseVarId=function(t,e){t.id="using"===e||"await using"===e?this.parseIdent():this.parseBindingAtom(),this.checkLValPattern(t.id,"var"===e?1:2,!1)};var J=1,Q=2;function X(t,e){var n=e.key.name,s=t[n],r="true";return"MethodDefinition"!==e.type||"get"!==e.kind&&"set"!==e.kind||(r=(e.static?"s":"i")+e.kind),"iget"===s&&"iset"===r||"iset"===s&&"iget"===r||"sget"===s&&"sset"===r||"sset"===s&&"sget"===r?(t[n]="true",!1):!!s||(t[n]=r,!1)}function Z(t,e){var n=t.computed,s=t.key;return!n&&("Identifier"===s.type&&s.name===e||"Literal"===s.type&&s.value===e)}G.parseFunction=function(t,e,n,s,r){this.initFunction(t),9>this.options.ecmaVersion&&(6>this.options.ecmaVersion||s)||(this.type===x.star&&e&Q&&this.unexpected(),t.generator=this.eat(x.star)),8>this.options.ecmaVersion||(t.async=!!s),e&J&&(t.id=4&e&&this.type!==x.name?null:this.parseIdent(),!t.id||e&Q||this.checkLValSimple(t.id,this.strict||t.generator||t.async?this.treatFunctionsAsVar?1:2:3));var i=this.yieldPos,a=this.awaitPos,o=this.awaitIdentPos;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(U(t.async,t.generator)),e&J||(t.id=this.type===x.name?this.parseIdent():null),this.parseFunctionParams(t),this.parseFunctionBody(t,n,!1,r),this.yieldPos=i,this.awaitPos=a,this.awaitIdentPos=o,this.finishNode(t,e&J?"FunctionDeclaration":"FunctionExpression")},G.parseFunctionParams=function(t){this.expect(x.parenL),t.params=this.parseBindingList(x.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()},G.parseClass=function(t,e){this.next();var n=this.strict;this.strict=!0,this.parseClassId(t,e),this.parseClassSuper(t);var s=this.enterClassBody(),r=this.startNode(),i=!1;for(r.body=[],this.expect(x.braceL);this.type!==x.braceR;){var a=this.parseClassElement(null!==t.superClass);a&&(r.body.push(a),"MethodDefinition"===a.type&&"constructor"===a.kind?(i&&this.raiseRecoverable(a.start,"Duplicate constructor in the same class"),i=!0):a.key&&"PrivateIdentifier"===a.key.type&&X(s,a)&&this.raiseRecoverable(a.key.start,"Identifier '#"+a.key.name+"' has already been declared"))}return this.strict=n,this.next(),t.body=this.finishNode(r,"ClassBody"),this.exitClassBody(),this.finishNode(t,e?"ClassDeclaration":"ClassExpression")},G.parseClassElement=function(t){if(this.eat(x.semi))return null;var e=this.options.ecmaVersion,n=this.startNode(),s="",r=!1,i=!1,a="method",o=!1;if(this.eatContextual("static")){if(e>=13&&this.eat(x.braceL))return this.parseClassStaticBlock(n),n;this.isClassElementNameStart()||this.type===x.star?o=!0:s="static"}if(n.static=o,s||8>e||!this.eatContextual("async")||(!this.isClassElementNameStart()&&this.type!==x.star||this.canInsertSemicolon()?s="async":i=!0),s||9>e&&i||!this.eat(x.star)||(r=!0),!s&&!i&&!r){var c=this.value;(this.eatContextual("get")||this.eatContextual("set"))&&(this.isClassElementNameStart()?a=c:s=c)}if(s?(n.computed=!1,n.key=this.startNodeAt(this.lastTokStart,this.lastTokStartLoc),n.key.name=s,this.finishNode(n.key,"Identifier")):this.parseClassElementName(n),13>e||this.type===x.parenL||"method"!==a||r||i){var l=!n.static&&Z(n,"constructor"),u=l&&t;l&&"method"!==a&&this.raise(n.key.start,"Constructor can't have get/set modifier"),n.kind=l?"constructor":a,this.parseClassMethod(n,r,i,u)}else this.parseClassField(n);return n},G.isClassElementNameStart=function(){return this.type===x.name||this.type===x.privateId||this.type===x.num||this.type===x.string||this.type===x.bracketL||this.type.keyword},G.parseClassElementName=function(t){this.type===x.privateId?("constructor"===this.value&&this.raise(this.start,"Classes can't have an element named '#constructor'"),t.computed=!1,t.key=this.parsePrivateIdent()):this.parsePropertyName(t)},G.parseClassMethod=function(t,e,n,s){var r=t.key;"constructor"===t.kind?(e&&this.raise(r.start,"Constructor can't be a generator"),n&&this.raise(r.start,"Constructor can't be an async method")):t.static&&Z(t,"prototype")&&this.raise(r.start,"Classes may not have a static property named prototype");var i=t.value=this.parseMethod(e,n,s);return"get"===t.kind&&0!==i.params.length&&this.raiseRecoverable(i.start,"getter should have no params"),"set"===t.kind&&1!==i.params.length&&this.raiseRecoverable(i.start,"setter should have exactly one param"),"set"===t.kind&&"RestElement"===i.params[0].type&&this.raiseRecoverable(i.params[0].start,"Setter cannot use rest params"),this.finishNode(t,"MethodDefinition")},G.parseClassField=function(t){return Z(t,"constructor")?this.raise(t.key.start,"Classes can't have a field named 'constructor'"):t.static&&Z(t,"prototype")&&this.raise(t.key.start,"Classes can't have a static field named 'prototype'"),this.eat(x.eq)?(this.enterScope(576),t.value=this.parseMaybeAssign(),this.exitScope()):t.value=null,this.semicolon(),this.finishNode(t,"PropertyDefinition")},G.parseClassStaticBlock=function(t){t.body=[];var e=this.labels;for(this.labels=[],this.enterScope(320);this.type!==x.braceR;){var n=this.parseStatement(null);t.body.push(n)}return this.next(),this.exitScope(),this.labels=e,this.finishNode(t,"StaticBlock")},G.parseClassId=function(t,e){this.type===x.name?(t.id=this.parseIdent(),e&&this.checkLValSimple(t.id,2,!1)):(!0===e&&this.unexpected(),t.id=null)},G.parseClassSuper=function(t){t.superClass=this.eat(x._extends)?this.parseExprSubscripts(null,!1):null},G.enterClassBody=function(){var t={declared:Object.create(null),used:[]};return this.privateNameStack.push(t),t.declared},G.exitClassBody=function(){var t=this.privateNameStack.pop(),e=t.declared,n=t.used;if(this.options.checkPrivateFields)for(var s=this.privateNameStack.length,r=0===s?null:this.privateNameStack[s-1],i=0;i<n.length;++i){var a=n[i];T(e,a.name)||(r?r.used.push(a):this.raiseRecoverable(a.start,"Private field '#"+a.name+"' must be declared in an enclosing class"))}},G.parseExportAllDeclaration=function(t,e){return 11>this.options.ecmaVersion||(this.eatContextual("as")?(t.exported=this.parseModuleExportName(),this.checkExport(e,t.exported,this.lastTokStart)):t.exported=null),this.expectContextual("from"),this.type!==x.string&&this.unexpected(),t.source=this.parseExprAtom(),16>this.options.ecmaVersion||(t.attributes=this.parseWithClause()),this.semicolon(),this.finishNode(t,"ExportAllDeclaration")},G.parseExport=function(t,e){if(this.next(),this.eat(x.star))return this.parseExportAllDeclaration(t,e);if(this.eat(x._default))return this.checkExport(e,"default",this.lastTokStart),t.declaration=this.parseExportDefaultDeclaration(),this.finishNode(t,"ExportDefaultDeclaration");if(this.shouldParseExportStatement())t.declaration=this.parseExportDeclaration(t),"VariableDeclaration"===t.declaration.type?this.checkVariableExport(e,t.declaration.declarations):this.checkExport(e,t.declaration.id,t.declaration.id.start),t.specifiers=[],t.source=null,16>this.options.ecmaVersion||(t.attributes=[]);else{if(t.declaration=null,t.specifiers=this.parseExportSpecifiers(e),this.eatContextual("from"))this.type!==x.string&&this.unexpected(),t.source=this.parseExprAtom(),16>this.options.ecmaVersion||(t.attributes=this.parseWithClause());else{for(var n=0,s=t.specifiers;n<s.length;n+=1){var r=s[n];this.checkUnreserved(r.local),this.checkLocalExport(r.local),"Literal"===r.local.type&&this.raise(r.local.start,"A string literal cannot be used as an exported binding without `from`.")}t.source=null,16>this.options.ecmaVersion||(t.attributes=[])}this.semicolon()}return this.finishNode(t,"ExportNamedDeclaration")},G.parseExportDeclaration=function(t){return this.parseStatement(null)},G.parseExportDefaultDeclaration=function(){var t;if(this.type===x._function||(t=this.isAsyncFunction())){var e=this.startNode();return this.next(),t&&this.next(),this.parseFunction(e,4|J,!1,t)}if(this.type===x._class){var n=this.startNode();return this.parseClass(n,"nullableID")}var s=this.parseMaybeAssign();return this.semicolon(),s},G.checkExport=function(t,e,n){t&&("string"!=typeof e&&(e="Identifier"===e.type?e.name:e.value),T(t,e)&&this.raiseRecoverable(n,"Duplicate export '"+e+"'"),t[e]=!0)},G.checkPatternExport=function(t,e){var n=e.type;if("Identifier"===n)this.checkExport(t,e,e.start);else if("ObjectPattern"===n)for(var s=0,r=e.properties;s<r.length;s+=1){var i=r[s];this.checkPatternExport(t,i)}else if("ArrayPattern"===n)for(var a=0,o=e.elements;a<o.length;a+=1){var c=o[a];c&&this.checkPatternExport(t,c)}else"Property"===n?this.checkPatternExport(t,e.value):"AssignmentPattern"===n?this.checkPatternExport(t,e.left):"RestElement"===n&&this.checkPatternExport(t,e.argument)},G.checkVariableExport=function(t,e){if(t)for(var n=0,s=e;n<s.length;n+=1){var r=s[n];this.checkPatternExport(t,r.id)}},G.shouldParseExportStatement=function(){return"var"===this.type.keyword||"const"===this.type.keyword||"class"===this.type.keyword||"function"===this.type.keyword||this.isLet()||this.isAsyncFunction()},G.parseExportSpecifier=function(t){var e=this.startNode();return e.local=this.parseModuleExportName(),e.exported=this.eatContextual("as")?this.parseModuleExportName():e.local,this.checkExport(t,e.exported,e.exported.start),this.finishNode(e,"ExportSpecifier")},G.parseExportSpecifiers=function(t){var e=[],n=!0;for(this.expect(x.braceL);!this.eat(x.braceR);){if(n)n=!1;else if(this.expect(x.comma),this.afterTrailingComma(x.braceR))break;e.push(this.parseExportSpecifier(t))}return e},G.parseImport=function(t){return this.next(),this.type===x.string?(t.specifiers=K,t.source=this.parseExprAtom()):(t.specifiers=this.parseImportSpecifiers(),this.expectContextual("from"),t.source=this.type===x.string?this.parseExprAtom():this.unexpected()),16>this.options.ecmaVersion||(t.attributes=this.parseWithClause()),this.semicolon(),this.finishNode(t,"ImportDeclaration")},G.parseImportSpecifier=function(){var t=this.startNode();return t.imported=this.parseModuleExportName(),this.eatContextual("as")?t.local=this.parseIdent():(this.checkUnreserved(t.imported),t.local=t.imported),this.checkLValSimple(t.local,2),this.finishNode(t,"ImportSpecifier")},G.parseImportDefaultSpecifier=function(){var t=this.startNode();return t.local=this.parseIdent(),this.checkLValSimple(t.local,2),this.finishNode(t,"ImportDefaultSpecifier")},G.parseImportNamespaceSpecifier=function(){var t=this.startNode();return this.next(),this.expectContextual("as"),t.local=this.parseIdent(),this.checkLValSimple(t.local,2),this.finishNode(t,"ImportNamespaceSpecifier")},G.parseImportSpecifiers=function(){var t=[],e=!0;if(this.type===x.name&&(t.push(this.parseImportDefaultSpecifier()),!this.eat(x.comma)))return t;if(this.type===x.star)return t.push(this.parseImportNamespaceSpecifier()),t;for(this.expect(x.braceL);!this.eat(x.braceR);){if(e)e=!1;else if(this.expect(x.comma),this.afterTrailingComma(x.braceR))break;t.push(this.parseImportSpecifier())}return t},G.parseWithClause=function(){var t=[];if(!this.eat(x._with))return t;this.expect(x.braceL);for(var e={},n=!0;!this.eat(x.braceR);){if(n)n=!1;else if(this.expect(x.comma),this.afterTrailingComma(x.braceR))break;var s=this.parseImportAttribute(),r="Identifier"===s.key.type?s.key.name:s.key.value;T(e,r)&&this.raiseRecoverable(s.key.start,"Duplicate attribute key '"+r+"'"),e[r]=!0,t.push(s)}return t},G.parseImportAttribute=function(){var t=this.startNode();return t.key=this.type===x.string?this.parseExprAtom():this.parseIdent("never"!==this.options.allowReserved),this.expect(x.colon),this.type!==x.string&&this.unexpected(),t.value=this.parseExprAtom(),this.finishNode(t,"ImportAttribute")},G.parseModuleExportName=function(){if(this.options.ecmaVersion>=13&&this.type===x.string){var t=this.parseLiteral(this.value);return V.test(t.value)&&this.raise(t.start,"An export name cannot include a lone surrogate."),t}return this.parseIdent(!0)},G.adaptDirectivePrologue=function(t){for(var e=0;e<t.length&&this.isDirectiveCandidate(t[e]);++e)t[e].directive=t[e].expression.raw.slice(1,-1)},G.isDirectiveCandidate=function(t){return this.options.ecmaVersion>=5&&"ExpressionStatement"===t.type&&"Literal"===t.expression.type&&"string"==typeof t.expression.value&&('"'===this.input[t.start]||"'"===this.input[t.start])};var tt=j.prototype;tt.toAssignable=function(t,e,n){if(this.options.ecmaVersion>=6&&t)switch(t.type){case"Identifier":this.inAsync&&"await"===t.name&&this.raise(t.start,"Cannot use 'await' as identifier inside an async function");break;case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":case"RestElement":break;case"ObjectExpression":t.type="ObjectPattern",n&&this.checkPatternErrors(n,!0);for(var s=0,r=t.properties;s<r.length;s+=1){var i=r[s];this.toAssignable(i,e),"RestElement"!==i.type||"ArrayPattern"!==i.argument.type&&"ObjectPattern"!==i.argument.type||this.raise(i.argument.start,"Unexpected token")}break;case"Property":"init"!==t.kind&&this.raise(t.key.start,"Object pattern can't contain getter or setter"),this.toAssignable(t.value,e);break;case"ArrayExpression":t.type="ArrayPattern",n&&this.checkPatternErrors(n,!0),this.toAssignableList(t.elements,e);break;case"SpreadElement":t.type="RestElement",this.toAssignable(t.argument,e),"AssignmentPattern"===t.argument.type&&this.raise(t.argument.start,"Rest elements cannot have a default value");break;case"AssignmentExpression":"="!==t.operator&&this.raise(t.left.end,"Only '=' operator can be used for specifying default value."),t.type="AssignmentPattern",delete t.operator,this.toAssignable(t.left,e);break;case"ParenthesizedExpression":this.toAssignable(t.expression,e,n);break;case"ChainExpression":this.raiseRecoverable(t.start,"Optional chaining cannot appear in left-hand side");break;case"MemberExpression":if(!e)break;default:this.raise(t.start,"Assigning to rvalue")}else n&&this.checkPatternErrors(n,!0);return t},tt.toAssignableList=function(t,e){for(var n=t.length,s=0;n>s;s++){var r=t[s];r&&this.toAssignable(r,e)}if(n){var i=t[n-1];6===this.options.ecmaVersion&&e&&i&&"RestElement"===i.type&&"Identifier"!==i.argument.type&&this.unexpected(i.argument.start)}return t},tt.parseSpread=function(t){var e=this.startNode();return this.next(),e.argument=this.parseMaybeAssign(!1,t),this.finishNode(e,"SpreadElement")},tt.parseRestBinding=function(){var t=this.startNode();return this.next(),6===this.options.ecmaVersion&&this.type!==x.name&&this.unexpected(),t.argument=this.parseBindingAtom(),this.finishNode(t,"RestElement")},tt.parseBindingAtom=function(){if(this.options.ecmaVersion>=6)switch(this.type){case x.bracketL:var t=this.startNode();return this.next(),t.elements=this.parseBindingList(x.bracketR,!0,!0),this.finishNode(t,"ArrayPattern");case x.braceL:return this.parseObj(!0)}return this.parseIdent()},tt.parseBindingList=function(t,e,n,s){for(var r=[],i=!0;!this.eat(t);)if(i?i=!1:this.expect(x.comma),e&&this.type===x.comma)r.push(null);else{if(n&&this.afterTrailingComma(t))break;if(this.type===x.ellipsis){var a=this.parseRestBinding();this.parseBindingListItem(a),r.push(a),this.type===x.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.expect(t);break}r.push(this.parseAssignableListItem(s))}return r},tt.parseAssignableListItem=function(t){var e=this.parseMaybeDefault(this.start,this.startLoc);return this.parseBindingListItem(e),e},tt.parseBindingListItem=function(t){return t},tt.parseMaybeDefault=function(t,e,n){if(n=n||this.parseBindingAtom(),6>this.options.ecmaVersion||!this.eat(x.eq))return n;var s=this.startNodeAt(t,e);return s.left=n,s.right=this.parseMaybeAssign(),this.finishNode(s,"AssignmentPattern")},tt.checkLValSimple=function(t,e,n){void 0===e&&(e=0);var s=0!==e;switch(t.type){case"Identifier":this.strict&&this.reservedWordsStrictBind.test(t.name)&&this.raiseRecoverable(t.start,(s?"Binding ":"Assigning to ")+t.name+" in strict mode"),s&&(2===e&&"let"===t.name&&this.raiseRecoverable(t.start,"let is disallowed as a lexically bound name"),n&&(T(n,t.name)&&this.raiseRecoverable(t.start,"Argument name clash"),n[t.name]=!0),5!==e&&this.declareName(t.name,e,t.start));break;case"ChainExpression":this.raiseRecoverable(t.start,"Optional chaining cannot appear in left-hand side");break;case"MemberExpression":s&&this.raiseRecoverable(t.start,"Binding member expression");break;case"ParenthesizedExpression":return s&&this.raiseRecoverable(t.start,"Binding parenthesized expression"),this.checkLValSimple(t.expression,e,n);default:this.raise(t.start,(s?"Binding":"Assigning to")+" rvalue")}},tt.checkLValPattern=function(t,e,n){switch(void 0===e&&(e=0),t.type){case"ObjectPattern":for(var s=0,r=t.properties;s<r.length;s+=1){var i=r[s];this.checkLValInnerPattern(i,e,n)}break;case"ArrayPattern":for(var a=0,o=t.elements;a<o.length;a+=1){var c=o[a];c&&this.checkLValInnerPattern(c,e,n)}break;default:this.checkLValSimple(t,e,n)}},tt.checkLValInnerPattern=function(t,e,n){switch(void 0===e&&(e=0),t.type){case"Property":this.checkLValInnerPattern(t.value,e,n);break;case"AssignmentPattern":this.checkLValPattern(t.left,e,n);break;case"RestElement":this.checkLValPattern(t.argument,e,n);break;default:this.checkLValPattern(t,e,n)}};var et=function(t,e,n,s,r){this.token=t,this.isExpr=!!e,this.preserveSpace=!!n,this.override=s,this.generator=!!r},nt={b_stat:new et("{",!1),b_expr:new et("{",!0),b_tmpl:new et("${",!1),p_stat:new et("(",!1),p_expr:new et("(",!0),q_tmpl:new et("`",!0,!0,function(t){return t.tryReadTemplateToken()}),f_stat:new et("function",!1),f_expr:new et("function",!0),f_expr_gen:new et("function",!0,!1,null,!0),f_gen:new et("function",!1,!1,null,!0)},st=j.prototype;st.initialContext=function(){return[nt.b_stat]},st.curContext=function(){return this.context[this.context.length-1]},st.braceIsBlock=function(t){var e=this.curContext();return e===nt.f_expr||e===nt.f_stat||(t!==x.colon||e!==nt.b_stat&&e!==nt.b_expr?t===x._return||t===x.name&&this.exprAllowed?b.test(this.input.slice(this.lastTokEnd,this.start)):t===x._else||t===x.semi||t===x.eof||t===x.parenR||t===x.arrow||(t===x.braceL?e===nt.b_stat:t!==x._var&&t!==x._const&&t!==x.name&&!this.exprAllowed):!e.isExpr)},st.inGeneratorContext=function(){for(var t=this.context.length-1;t>=1;t--){var e=this.context[t];if("function"===e.token)return e.generator}return!1},st.updateContext=function(t){var e,n=this.type;n.keyword&&t===x.dot?this.exprAllowed=!1:(e=n.updateContext)?e.call(this,t):this.exprAllowed=n.beforeExpr},st.overrideContext=function(t){this.curContext()!==t&&(this.context[this.context.length-1]=t)},x.parenR.updateContext=x.braceR.updateContext=function(){if(1!==this.context.length){var t=this.context.pop();t===nt.b_stat&&"function"===this.curContext().token&&(t=this.context.pop()),this.exprAllowed=!t.isExpr}else this.exprAllowed=!0},x.braceL.updateContext=function(t){this.context.push(this.braceIsBlock(t)?nt.b_stat:nt.b_expr),this.exprAllowed=!0},x.dollarBraceL.updateContext=function(){this.context.push(nt.b_tmpl),this.exprAllowed=!0},x.parenL.updateContext=function(t){var e=t===x._if||t===x._for||t===x._with||t===x._while;this.context.push(e?nt.p_stat:nt.p_expr),this.exprAllowed=!0},x.incDec.updateContext=function(){},x._function.updateContext=x._class.updateContext=function(t){!t.beforeExpr||t===x._else||t===x.semi&&this.curContext()!==nt.p_stat||t===x._return&&b.test(this.input.slice(this.lastTokEnd,this.start))||(t===x.colon||t===x.braceL)&&this.curContext()===nt.b_stat?this.context.push(nt.f_stat):this.context.push(nt.f_expr),this.exprAllowed=!1},x.colon.updateContext=function(){"function"===this.curContext().token&&this.context.pop(),this.exprAllowed=!0},x.backQuote.updateContext=function(){this.curContext()===nt.q_tmpl?this.context.pop():this.context.push(nt.q_tmpl),this.exprAllowed=!1},x.star.updateContext=function(t){if(t===x._function){var e=this.context.length-1;this.context[e]===nt.f_expr?this.context[e]=nt.f_expr_gen:this.context[e]=nt.f_gen}this.exprAllowed=!0},x.name.updateContext=function(t){var e=!1;6>this.options.ecmaVersion||t===x.dot||("of"===this.value&&!this.exprAllowed||"yield"===this.value&&this.inGeneratorContext())&&(e=!0),this.exprAllowed=e};var rt=j.prototype;function it(t){return"Identifier"===t.type||"ParenthesizedExpression"===t.type&&it(t.expression)}function at(t){return"MemberExpression"===t.type&&"PrivateIdentifier"===t.property.type||"ChainExpression"===t.type&&at(t.expression)||"ParenthesizedExpression"===t.type&&at(t.expression)}rt.checkPropClash=function(t,e,n){if((9>this.options.ecmaVersion||"SpreadElement"!==t.type)&&(6>this.options.ecmaVersion||!(t.computed||t.method||t.shorthand))){var s,r=t.key;switch(r.type){case"Identifier":s=r.name;break;case"Literal":s=r.value+"";break;default:return}var i=t.kind;if(6>this.options.ecmaVersion){var a=e[s="$"+s];a?("init"===i?this.strict&&a.init||a.get||a.set:a.init||a[i])&&this.raiseRecoverable(r.start,"Redefinition of property"):a=e[s]={init:!1,get:!1,set:!1},a[i]=!0}else"__proto__"===s&&"init"===i&&(e.proto&&(n?0>n.doubleProto&&(n.doubleProto=r.start):this.raiseRecoverable(r.start,"Redefinition of __proto__ property")),e.proto=!0)}},rt.parseExpression=function(t,e){var n=this;return this.catchStackOverflow(function(){var s=n.start,r=n.startLoc,i=n.parseMaybeAssign(t,e);if(n.type===x.comma){var a=n.startNodeAt(s,r);for(a.expressions=[i];n.eat(x.comma);)a.expressions.push(n.parseMaybeAssign(t,e));return n.finishNode(a,"SequenceExpression")}return i})},rt.parseMaybeAssign=function(t,e,n){if(this.isContextual("yield")){if(this.inGenerator)return this.parseYield(t);this.exprAllowed=!1}var s=!1,r=-1,i=-1,a=-1;e?(r=e.parenthesizedAssign,i=e.trailingComma,a=e.doubleProto,e.parenthesizedAssign=e.trailingComma=-1):(e=new H,s=!0);var o=this.start,c=this.startLoc;this.type!==x.parenL&&this.type!==x.name||(this.potentialArrowAt=this.start,this.potentialArrowInForAwait="await"===t);var l=this.parseMaybeConditional(t,e);if(n&&(l=n.call(this,l,o,c)),this.type.isAssign){var u=this.startNodeAt(o,c);return u.operator=this.value,this.type===x.eq&&(l=this.toAssignable(l,!1,e)),s||(e.parenthesizedAssign=e.trailingComma=e.doubleProto=-1),e.shorthandAssign<l.start||(e.shorthandAssign=-1),this.type===x.eq?this.checkLValPattern(l):this.checkLValSimple(l),u.left=l,this.next(),u.right=this.parseMaybeAssign(t),a>-1&&(e.doubleProto=a),this.finishNode(u,"AssignmentExpression")}return s&&this.checkExpressionErrors(e,!0),r>-1&&(e.parenthesizedAssign=r),i>-1&&(e.trailingComma=i),l},rt.parseMaybeConditional=function(t,e){var n=this.start,s=this.startLoc,r=this.parseExprOps(t,e);if(this.checkExpressionErrors(e))return r;if(("ArrowFunctionExpression"!==r.type||r.start!==n)&&this.eat(x.question)){var i=this.startNodeAt(n,s);return i.test=r,i.consequent=this.parseMaybeAssign(),this.expect(x.colon),i.alternate=this.parseMaybeAssign(t),this.finishNode(i,"ConditionalExpression")}return r},rt.parseExprOps=function(t,e){var n=this.start,s=this.startLoc,r=this.parseMaybeUnary(e,!1,!1,t);return this.checkExpressionErrors(e)||r.start===n&&"ArrowFunctionExpression"===r.type?r:this.parseExprOp(r,n,s,-1,t)},rt.parseExprOp=function(t,e,n,s,r){var i=this.type.binop;if(null!=i&&(!r||this.type!==x._in)&&i>s){var a=this.type===x.logicalOR||this.type===x.logicalAND,o=this.type===x.coalesce;o&&(i=x.logicalAND.binop);var c=this.value;this.next();var l=this.start,u=this.startLoc,h=this.parseExprOp(this.parseMaybeUnary(null,!1,!1,r),l,u,i,r),p=this.buildBinary(e,n,t,h,c,a||o);return(a&&this.type===x.coalesce||o&&(this.type===x.logicalOR||this.type===x.logicalAND))&&this.raiseRecoverable(this.start,"Logical expressions and coalesce expressions cannot be mixed. Wrap either by parentheses"),this.parseExprOp(p,e,n,s,r)}return t},rt.buildBinary=function(t,e,n,s,r,i){"PrivateIdentifier"===s.type&&this.raise(s.start,"Private identifier can only be left side of binary expression");var a=this.startNodeAt(t,e);return a.left=n,a.operator=r,a.right=s,this.finishNode(a,i?"LogicalExpression":"BinaryExpression")},rt.parseMaybeUnary=function(t,e,n,s){var r,i=this.start,a=this.startLoc;if(this.isContextual("await")&&this.canAwait)r=this.parseAwait(s),e=!0;else if(this.type.prefix){var o=this.startNode(),c=this.type===x.incDec;o.operator=this.value,o.prefix=!0,this.next(),o.argument=this.parseMaybeUnary(null,!0,c,s),this.checkExpressionErrors(t,!0),c?this.checkLValSimple(o.argument):this.strict&&"delete"===o.operator&&it(o.argument)?this.raiseRecoverable(o.start,"Deleting local variable in strict mode"):"delete"===o.operator&&at(o.argument)?this.raiseRecoverable(o.start,"Private fields can not be deleted"):e=!0,r=this.finishNode(o,c?"UpdateExpression":"UnaryExpression")}else if(e||this.type!==x.privateId){if(r=this.parseExprSubscripts(t,s),this.checkExpressionErrors(t))return r;for(;this.type.postfix&&!this.canInsertSemicolon();){var l=this.startNodeAt(i,a);l.operator=this.value,l.prefix=!1,l.argument=r,this.checkLValSimple(r),this.next(),r=this.finishNode(l,"UpdateExpression")}}else(s||0===this.privateNameStack.length)&&this.options.checkPrivateFields&&this.unexpected(),r=this.parsePrivateIdent(),this.type!==x._in&&this.unexpected();return n||"ArrowFunctionExpression"===r.type&&r.start===i||!this.eat(x.starstar)?r:e?void this.unexpected(this.lastTokStart):this.buildBinary(i,a,r,this.parseMaybeUnary(null,!1,!1,s),"**",!1)},rt.parseExprSubscripts=function(t,e){var n=this.start,s=this.startLoc,r=this.parseExprAtom(t,e);if("ArrowFunctionExpression"===r.type&&")"!==this.input.slice(this.lastTokStart,this.lastTokEnd))return r;var i=this.parseSubscripts(r,n,s,!1,e);return t&&"MemberExpression"===i.type&&(t.parenthesizedAssign<i.start||(t.parenthesizedAssign=-1),t.parenthesizedBind<i.start||(t.parenthesizedBind=-1),t.trailingComma<i.start||(t.trailingComma=-1)),i},rt.parseSubscripts=function(t,e,n,s,r){for(var i=this.options.ecmaVersion>=8&&"Identifier"===t.type&&"async"===t.name&&this.lastTokEnd===t.end&&!this.canInsertSemicolon()&&t.end-t.start===5&&this.potentialArrowAt===t.start,a=!1;;){var o=this.parseSubscript(t,e,n,s,i,a,r);if(o.optional&&(a=!0),o===t||"ArrowFunctionExpression"===o.type){if(a){var c=this.startNodeAt(e,n);c.expression=o,o=this.finishNode(c,"ChainExpression")}return o}t=o}},rt.shouldParseAsyncArrow=function(){return!this.canInsertSemicolon()&&this.eat(x.arrow)},rt.parseSubscriptAsyncArrow=function(t,e,n,s){return this.parseArrowExpression(this.startNodeAt(t,e),n,!0,s)},rt.parseSubscript=function(t,e,n,s,r,i,a){var o=this.options.ecmaVersion>=11,c=o&&this.eat(x.questionDot);s&&c&&this.raise(this.lastTokStart,"Optional chaining cannot appear in the callee of new expressions");var l=this.eat(x.bracketL);if(l||c&&this.type!==x.parenL&&this.type!==x.backQuote||this.eat(x.dot)){var u=this.startNodeAt(e,n);u.object=t,l?(u.property=this.parseExpression(),this.expect(x.bracketR)):this.type===x.privateId&&"Super"!==t.type?u.property=this.parsePrivateIdent():u.property=this.parseIdent("never"!==this.options.allowReserved),u.computed=!!l,o&&(u.optional=c),t=this.finishNode(u,"MemberExpression")}else if(!s&&this.eat(x.parenL)){var h=new H,p=this.yieldPos,f=this.awaitPos,d=this.awaitIdentPos;this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0;var m=this.parseExprList(x.parenR,this.options.ecmaVersion>=8,!1,h);if(r&&!c&&this.shouldParseAsyncArrow())return this.checkPatternErrors(h,!1),this.checkYieldAwaitInDefaultParams(),this.awaitIdentPos>0&&this.raise(this.awaitIdentPos,"Cannot use 'await' as identifier inside an async function"),this.yieldPos=p,this.awaitPos=f,this.awaitIdentPos=d,this.parseSubscriptAsyncArrow(e,n,m,a);this.checkExpressionErrors(h,!0),this.yieldPos=p||this.yieldPos,this.awaitPos=f||this.awaitPos,this.awaitIdentPos=d||this.awaitIdentPos;var g=this.startNodeAt(e,n);g.callee=t,g.arguments=m,o&&(g.optional=c),t=this.finishNode(g,"CallExpression")}else if(this.type===x.backQuote){(c||i)&&this.raise(this.start,"Optional chaining cannot appear in the tag of tagged template expressions");var y=this.startNodeAt(e,n);y.tag=t,y.quasi=this.parseTemplate({isTagged:!0}),t=this.finishNode(y,"TaggedTemplateExpression")}return t},rt.parseExprAtom=function(t,e,n){this.type===x.slash&&this.readRegexp();var s,r=this.potentialArrowAt===this.start;switch(this.type){case x._super:return this.allowSuper||this.raise(this.start,"'super' keyword outside a method"),s=this.startNode(),this.next(),this.type!==x.parenL||this.allowDirectSuper||this.raise(s.start,"super() call outside constructor of a subclass"),this.type!==x.dot&&this.type!==x.bracketL&&this.type!==x.parenL&&this.unexpected(),this.finishNode(s,"Super");case x._this:return s=this.startNode(),this.next(),this.finishNode(s,"ThisExpression");case x.name:var i=this.start,a=this.startLoc,o=this.containsEsc,c=this.parseIdent(!1);if(this.options.ecmaVersion>=8&&!o&&"async"===c.name&&!this.canInsertSemicolon()&&this.eat(x._function))return this.overrideContext(nt.f_expr),this.parseFunction(this.startNodeAt(i,a),0,!1,!0,e);if(r&&!this.canInsertSemicolon()){if(this.eat(x.arrow))return this.parseArrowExpression(this.startNodeAt(i,a),[c],!1,e);if(this.options.ecmaVersion>=8&&"async"===c.name&&this.type===x.name&&!o&&(!this.potentialArrowInForAwait||"of"!==this.value||this.containsEsc))return c=this.parseIdent(!1),!this.canInsertSemicolon()&&this.eat(x.arrow)||this.unexpected(),this.parseArrowExpression(this.startNodeAt(i,a),[c],!0,e)}return c;case x.regexp:var l=this.value;return(s=this.parseLiteral(l.value)).regex={pattern:l.pattern,flags:l.flags},s;case x.num:case x.string:return this.parseLiteral(this.value);case x._null:case x._true:case x._false:return(s=this.startNode()).value=this.type===x._null?null:this.type===x._true,s.raw=this.type.keyword,this.next(),this.finishNode(s,"Literal");case x.parenL:var u=this.start,h=this.parseParenAndDistinguishExpression(r,e);return t&&(0>t.parenthesizedAssign&&!this.isSimpleAssignTarget(h)&&(t.parenthesizedAssign=u),0>t.parenthesizedBind&&(t.parenthesizedBind=u)),h;case x.bracketL:return s=this.startNode(),this.next(),s.elements=this.parseExprList(x.bracketR,!0,!0,t),this.finishNode(s,"ArrayExpression");case x.braceL:return this.overrideContext(nt.b_expr),this.parseObj(!1,t);case x._function:return s=this.startNode(),this.next(),this.parseFunction(s,0);case x._class:return this.parseClass(this.startNode(),!1);case x._new:return this.parseNew();case x.backQuote:return this.parseTemplate();case x._import:return 11>this.options.ecmaVersion?this.unexpected():this.parseExprImport(n);default:return this.parseExprAtomDefault()}},rt.parseExprAtomDefault=function(){this.unexpected()},rt.parseExprImport=function(t){var e=this.startNode();if(this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword import"),this.next(),this.type===x.parenL&&!t)return this.parseDynamicImport(e);if(this.type===x.dot){var n=this.startNodeAt(e.start,e.loc&&e.loc.start);return n.name="import",e.meta=this.finishNode(n,"Identifier"),this.parseImportMeta(e)}this.unexpected()},rt.parseDynamicImport=function(t){if(this.next(),t.source=this.parseMaybeAssign(),16>this.options.ecmaVersion){if(!this.eat(x.parenR)){var e=this.start;this.eat(x.comma)&&this.eat(x.parenR)?this.raiseRecoverable(e,"Trailing comma is not allowed in import()"):this.unexpected(e)}}else this.eat(x.parenR)?t.options=null:(this.expect(x.comma),this.afterTrailingComma(x.parenR)?t.options=null:(t.options=this.parseMaybeAssign(),this.eat(x.parenR)||(this.expect(x.comma),this.afterTrailingComma(x.parenR)||this.unexpected())));return this.finishNode(t,"ImportExpression")},rt.parseImportMeta=function(t){this.next();var e=this.containsEsc;return t.property=this.parseIdent(!0),"meta"!==t.property.name&&this.raiseRecoverable(t.property.start,"The only valid meta property for import is 'import.meta'"),e&&this.raiseRecoverable(t.start,"'import.meta' must not contain escaped characters"),"module"===this.options.sourceType||this.options.allowImportExportEverywhere||this.raiseRecoverable(t.start,"Cannot use 'import.meta' outside a module"),this.finishNode(t,"MetaProperty")},rt.parseLiteral=function(t){var e=this.startNode();return e.value=t,e.raw=this.input.slice(this.start,this.end),110===e.raw.charCodeAt(e.raw.length-1)&&(e.bigint=null!=e.value?e.value.toString():e.raw.slice(0,-1).replace(/_/g,"")),this.next(),this.finishNode(e,"Literal")},rt.parseParenExpression=function(){this.expect(x.parenL);var t=this.parseExpression();return this.expect(x.parenR),t},rt.shouldParseArrow=function(t){return!this.canInsertSemicolon()},rt.parseParenAndDistinguishExpression=function(t,e){var n,s=this.start,r=this.startLoc,i=this.options.ecmaVersion>=8;if(6>this.options.ecmaVersion)n=this.parseParenExpression();else{this.next();var a,o=this.start,c=this.startLoc,l=[],u=!0,h=!1,p=new H,f=this.yieldPos,d=this.awaitPos;for(this.yieldPos=0,this.awaitPos=0;this.type!==x.parenR;){if(u?u=!1:this.expect(x.comma),i&&this.afterTrailingComma(x.parenR,!0)){h=!0;break}if(this.type===x.ellipsis){a=this.start,l.push(this.parseParenItem(this.parseRestBinding())),this.type===x.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element");break}l.push(this.parseMaybeAssign(!1,p,this.parseParenItem))}var m=this.lastTokEnd,g=this.lastTokEndLoc;if(this.expect(x.parenR),t&&this.shouldParseArrow(l)&&this.eat(x.arrow))return this.checkPatternErrors(p,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=f,this.awaitPos=d,this.parseParenArrowList(s,r,l,e);l.length&&!h||this.unexpected(this.lastTokStart),a&&this.unexpected(a),this.checkExpressionErrors(p,!0),this.yieldPos=f||this.yieldPos,this.awaitPos=d||this.awaitPos,l.length>1?((n=this.startNodeAt(o,c)).expressions=l,this.finishNodeAt(n,"SequenceExpression",m,g)):n=l[0]}if(this.options.preserveParens){var y=this.startNodeAt(s,r);return y.expression=n,this.finishNode(y,"ParenthesizedExpression")}return n},rt.parseParenItem=function(t){return t},rt.parseParenArrowList=function(t,e,n,s){return this.parseArrowExpression(this.startNodeAt(t,e),n,!1,s)};var ot=[];rt.parseNew=function(){this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword new");var t=this.startNode();if(this.next(),this.options.ecmaVersion>=6&&this.type===x.dot){var e=this.startNodeAt(t.start,t.loc&&t.loc.start);e.name="new",t.meta=this.finishNode(e,"Identifier"),this.next();var n=this.containsEsc;return t.property=this.parseIdent(!0),"target"!==t.property.name&&this.raiseRecoverable(t.property.start,"The only valid meta property for new is 'new.target'"),n&&this.raiseRecoverable(t.start,"'new.target' must not contain escaped characters"),this.allowNewDotTarget||this.raiseRecoverable(t.start,"'new.target' can only be used in functions and class static block"),this.finishNode(t,"MetaProperty")}var s=this.start,r=this.startLoc;return t.callee=this.parseSubscripts(this.parseExprAtom(null,!1,!0),s,r,!0,!1),"Super"===t.callee.type&&this.raiseRecoverable(s,"Invalid use of 'super'"),this.eat(x.parenL)?t.arguments=this.parseExprList(x.parenR,this.options.ecmaVersion>=8,!1):t.arguments=ot,this.finishNode(t,"NewExpression")},rt.parseTemplateElement=function(t){var e=t.isTagged,n=this.startNode();return this.type===x.invalidTemplate?(e||this.raiseRecoverable(this.start,"Bad escape sequence in untagged template literal"),n.value={raw:this.value.replace(/\r\n?/g,"\n"),cooked:null}):n.value={raw:this.input.slice(this.start,this.end).replace(/\r\n?/g,"\n"),cooked:this.value},this.next(),n.tail=this.type===x.backQuote,this.finishNode(n,"TemplateElement")},rt.parseTemplate=function(t){void 0===t&&(t={});var e=t.isTagged;void 0===e&&(e=!1);var n=this.startNode();this.next(),n.expressions=[];var s=this.parseTemplateElement({isTagged:e});for(n.quasis=[s];!s.tail;)this.type===x.eof&&this.raise(this.pos,"Unterminated template literal"),this.expect(x.dollarBraceL),n.expressions.push(this.parseExpression()),this.expect(x.braceR),n.quasis.push(s=this.parseTemplateElement({isTagged:e}));return this.next(),this.finishNode(n,"TemplateLiteral")},rt.isAsyncProp=function(t){return!t.computed&&"Identifier"===t.key.type&&"async"===t.key.name&&(this.type===x.name||this.type===x.num||this.type===x.string||this.type===x.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===x.star)&&!b.test(this.input.slice(this.lastTokEnd,this.start))},rt.parseObj=function(t,e){var n=this.startNode(),s=!0,r={};for(n.properties=[],this.next();!this.eat(x.braceR);){if(s)s=!1;else if(this.expect(x.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(x.braceR))break;var i=this.parseProperty(t,e);t||this.checkPropClash(i,r,e),n.properties.push(i)}return this.finishNode(n,t?"ObjectPattern":"ObjectExpression")},rt.parseProperty=function(t,e){var n,s,r,i,a=this.startNode();if(this.options.ecmaVersion>=9&&this.eat(x.ellipsis))return t?(a.argument=this.parseIdent(!1),this.type===x.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.finishNode(a,"RestElement")):(a.argument=this.parseMaybeAssign(!1,e),this.type===x.comma&&e&&0>e.trailingComma&&(e.trailingComma=this.start),this.finishNode(a,"SpreadElement"));6>this.options.ecmaVersion||(a.method=!1,a.shorthand=!1,(t||e)&&(r=this.start,i=this.startLoc),t||(n=this.eat(x.star)));var o=this.containsEsc;return this.parsePropertyName(a),t||o||8>this.options.ecmaVersion||n||!this.isAsyncProp(a)?s=!1:(s=!0,n=this.options.ecmaVersion>=9&&this.eat(x.star),this.parsePropertyName(a)),this.parsePropertyValue(a,t,n,s,r,i,e,o),this.finishNode(a,"Property")},rt.parseGetterSetter=function(t){var e=t.key.name;this.parsePropertyName(t),t.value=this.parseMethod(!1),t.kind=e;var n="get"===t.kind?0:1;if(t.value.params.length!==n){var s=t.value.start;"get"===t.kind?this.raiseRecoverable(s,"getter should have no params"):this.raiseRecoverable(s,"setter should have exactly one param")}else"set"===t.kind&&"RestElement"===t.value.params[0].type&&this.raiseRecoverable(t.value.params[0].start,"Setter cannot use rest params")},rt.parsePropertyValue=function(t,e,n,s,r,i,a,o){(n||s)&&this.type===x.colon&&this.unexpected(),this.eat(x.colon)?(t.value=e?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,a),t.kind="init"):6>this.options.ecmaVersion||this.type!==x.parenL?e||o||5>this.options.ecmaVersion||t.computed||"Identifier"!==t.key.type||"get"!==t.key.name&&"set"!==t.key.name||this.type===x.comma||this.type===x.braceR||this.type===x.eq?6>this.options.ecmaVersion||t.computed||"Identifier"!==t.key.type?this.unexpected():((n||s)&&this.unexpected(),this.checkUnreserved(t.key),"await"!==t.key.name||this.awaitIdentPos||(this.awaitIdentPos=r),e?t.value=this.parseMaybeDefault(r,i,this.copyNode(t.key)):this.type===x.eq&&a?(0>a.shorthandAssign&&(a.shorthandAssign=this.start),t.value=this.parseMaybeDefault(r,i,this.copyNode(t.key))):t.value=this.copyNode(t.key),t.kind="init",t.shorthand=!0):((n||s)&&this.unexpected(),this.parseGetterSetter(t)):(e&&this.unexpected(),t.method=!0,t.value=this.parseMethod(n,s),t.kind="init")},rt.parsePropertyName=function(t){if(this.options.ecmaVersion>=6){if(this.eat(x.bracketL))return t.computed=!0,t.key=this.parseMaybeAssign(),this.expect(x.bracketR),t.key;t.computed=!1}return t.key=this.type===x.num||this.type===x.string?this.parseExprAtom():this.parseIdent("never"!==this.options.allowReserved)},rt.initFunction=function(t){t.id=null,6>this.options.ecmaVersion||(t.generator=t.expression=!1),8>this.options.ecmaVersion||(t.async=!1)},rt.parseMethod=function(t,e,n){var s=this.startNode(),r=this.yieldPos,i=this.awaitPos,a=this.awaitIdentPos;return this.initFunction(s),6>this.options.ecmaVersion||(s.generator=t),8>this.options.ecmaVersion||(s.async=!!e),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(64|U(e,s.generator)|(n?128:0)),this.expect(x.parenL),s.params=this.parseBindingList(x.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(s,!1,!0,!1),this.yieldPos=r,this.awaitPos=i,this.awaitIdentPos=a,this.finishNode(s,"FunctionExpression")},rt.parseArrowExpression=function(t,e,n,s){var r=this.yieldPos,i=this.awaitPos,a=this.awaitIdentPos;return this.enterScope(16|U(n,!1)),this.initFunction(t),8>this.options.ecmaVersion||(t.async=!!n),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,t.params=this.toAssignableList(e,!0),this.parseFunctionBody(t,!0,!1,s),this.yieldPos=r,this.awaitPos=i,this.awaitIdentPos=a,this.finishNode(t,"ArrowFunctionExpression")},rt.parseFunctionBody=function(t,e,n,s){var r=e&&this.type!==x.braceL,i=this.strict,a=!1;if(r)t.body=this.parseMaybeAssign(s),t.expression=!0,this.checkParams(t,!1);else{var o=this.options.ecmaVersion>=7&&!this.isSimpleParamList(t.params);i&&!o||(a=this.strictDirective(this.end))&&o&&this.raiseRecoverable(t.start,"Illegal 'use strict' directive in function with non-simple parameter list");var c=this.labels;this.labels=[],a&&(this.strict=!0),this.checkParams(t,!i&&!a&&!e&&!n&&this.isSimpleParamList(t.params)),this.strict&&t.id&&this.checkLValSimple(t.id,5),t.body=this.parseBlock(!1,void 0,a&&!i),t.expression=!1,this.adaptDirectivePrologue(t.body.body),this.labels=c}this.exitScope()},rt.isSimpleParamList=function(t){for(var e=0,n=t;e<n.length;e+=1)if("Identifier"!==n[e].type)return!1;return!0},rt.checkParams=function(t,e){for(var n=Object.create(null),s=0,r=t.params;s<r.length;s+=1){var i=r[s];this.checkLValInnerPattern(i,1,e?null:n)}},rt.parseExprList=function(t,e,n,s){for(var r=[],i=!0;!this.eat(t);){if(i)i=!1;else if(this.expect(x.comma),e&&this.afterTrailingComma(t))break;var a=void 0;n&&this.type===x.comma?a=null:this.type===x.ellipsis?(a=this.parseSpread(s),s&&this.type===x.comma&&0>s.trailingComma&&(s.trailingComma=this.start)):a=this.parseMaybeAssign(!1,s),r.push(a)}return r},rt.checkUnreserved=function(t){var e=t.start,n=t.end,s=t.name;this.inGenerator&&"yield"===s&&this.raiseRecoverable(e,"Cannot use 'yield' as identifier inside a generator"),this.inAsync&&"await"===s&&this.raiseRecoverable(e,"Cannot use 'await' as identifier inside an async function"),259&this.currentThisScope().flags||"arguments"!==s||this.raiseRecoverable(e,"Cannot use 'arguments' in class field initializer"),!this.inClassStaticBlock||"arguments"!==s&&"await"!==s||this.raise(e,"Cannot use "+s+" in class static initialization block"),this.keywords.test(s)&&this.raise(e,"Unexpected keyword '"+s+"'"),6>this.options.ecmaVersion&&-1!==this.input.slice(e,n).indexOf("\\")||(this.strict?this.reservedWordsStrict:this.reservedWords).test(s)&&(this.inAsync||"await"!==s||this.raiseRecoverable(e,"Cannot use keyword 'await' outside an async function"),this.raiseRecoverable(e,"The keyword '"+s+"' is reserved"))},rt.parseIdent=function(t){var e=this.parseIdentNode();return this.next(!!t),this.finishNode(e,"Identifier"),t||(this.checkUnreserved(e),"await"!==e.name||this.awaitIdentPos||(this.awaitIdentPos=e.start)),e},rt.parseIdentNode=function(){var t=this.startNode();return this.type===x.name?t.name=this.value:this.type.keyword?(t.name=this.type.keyword,"class"!==t.name&&"function"!==t.name||this.lastTokEnd===this.lastTokStart+1&&46===this.input.charCodeAt(this.lastTokStart)||this.context.pop(),this.type=x.name):this.unexpected(),t},rt.parsePrivateIdent=function(){var t=this.startNode();return this.type===x.privateId?t.name=this.value:this.unexpected(),this.next(),this.finishNode(t,"PrivateIdentifier"),this.options.checkPrivateFields&&(0===this.privateNameStack.length?this.raise(t.start,"Private field '#"+t.name+"' must be declared in an enclosing class"):this.privateNameStack[this.privateNameStack.length-1].used.push(t)),t},rt.parseYield=function(t){this.yieldPos||(this.yieldPos=this.start);var e=this.startNode();return this.next(),this.type===x.semi||this.canInsertSemicolon()||this.type!==x.star&&!this.type.startsExpr?(e.delegate=!1,e.argument=null):(e.delegate=this.eat(x.star),e.argument=this.parseMaybeAssign(t)),this.finishNode(e,"YieldExpression")},rt.parseAwait=function(t){this.awaitPos||(this.awaitPos=this.start);var e=this.startNode();return this.next(),e.argument=this.parseMaybeUnary(null,!0,!1,t),this.finishNode(e,"AwaitExpression")};var ct=j.prototype;ct.raise=function(t,e){var n=D(this.input,t);e+=" ("+n.line+":"+n.column+")",this.sourceFile&&(e+=" in "+this.sourceFile);var s=new SyntaxError(e);throw s.pos=t,s.loc=n,s.raisedAt=this.pos,s},ct.raiseRecoverable=ct.raise,ct.curPosition=function(){if(this.options.locations)return new O(this.curLine,this.pos-this.lineStart)};var lt=j.prototype,ut=function(t){this.flags=t,this.var=[],this.lexical=[],this.functions=[]};lt.enterScope=function(t){this.scopeStack.push(new ut(t))},lt.exitScope=function(){this.scopeStack.pop()},lt.treatFunctionsAsVarInScope=function(t){return 2&t.flags||!this.inModule&&1&t.flags},lt.declareName=function(t,e,n){var s=!1;if(2===e){var r=this.currentScope();s=r.lexical.indexOf(t)>-1||r.functions.indexOf(t)>-1||r.var.indexOf(t)>-1,r.lexical.push(t),this.inModule&&1&r.flags&&delete this.undefinedExports[t]}else if(4===e)this.currentScope().lexical.push(t);else if(3===e){var i=this.currentScope();s=this.treatFunctionsAsVar?i.lexical.indexOf(t)>-1:i.lexical.indexOf(t)>-1||i.var.indexOf(t)>-1,i.functions.push(t)}else for(var a=this.scopeStack.length-1;a>=0;--a){var o=this.scopeStack[a];if(o.lexical.indexOf(t)>-1&&!(32&o.flags&&o.lexical[0]===t)||!this.treatFunctionsAsVarInScope(o)&&o.functions.indexOf(t)>-1){s=!0;break}if(o.var.push(t),this.inModule&&1&o.flags&&delete this.undefinedExports[t],259&o.flags)break}s&&this.raiseRecoverable(n,"Identifier '"+t+"' has already been declared")},lt.checkLocalExport=function(t){-1===this.scopeStack[0].lexical.indexOf(t.name)&&-1===this.scopeStack[0].var.indexOf(t.name)&&(this.undefinedExports[t.name]=t)},lt.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]},lt.currentVarScope=function(){for(var t=this.scopeStack.length-1;;t--){var e=this.scopeStack[t];if(771&e.flags)return e}},lt.currentThisScope=function(){for(var t=this.scopeStack.length-1;;t--){var e=this.scopeStack[t];if(771&e.flags&&!(16&e.flags))return e}};var ht=function(t,e,n){this.type="",this.start=e,this.end=0,t.options.locations&&(this.loc=new R(t,n)),t.options.directSourceFile&&(this.sourceFile=t.options.directSourceFile),t.options.ranges&&(this.range=[e,0])},pt=j.prototype;function ft(t,e,n,s){return t.type=e,t.end=n,this.options.locations&&(t.loc.end=s),this.options.ranges&&(t.range[1]=n),t}pt.startNode=function(){return new ht(this,this.start,this.startLoc)},pt.startNodeAt=function(t,e){return new ht(this,t,e)},pt.finishNode=function(t,e){return ft.call(this,t,e,this.lastTokEnd,this.lastTokEndLoc)},pt.finishNodeAt=function(t,e,n,s){return ft.call(this,t,e,n,s)},pt.copyNode=function(t){var e=new ht(this,t.start,this.startLoc);for(var n in t)e[n]=t[n];return e};var dt="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",mt=dt+" Extended_Pictographic",gt=mt+" EBase EComp EMod EPres ExtPict",yt={9:dt,10:mt,11:mt,12:gt,13:gt,14:gt},vt={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"},xt="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",bt="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",_t=bt+" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd",wt=_t+" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho",Et=wt+" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi",St=Et+" Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith",kt={9:bt,10:_t,11:wt,12:Et,13:St,14:St+" Berf Beria_Erfe Gara Garay Gukh Gurung_Khema Hrkt Katakana_Or_Hiragana Kawi Kirat_Rai Krai Nag_Mundari Nagm Ol_Onal Onao Sidetic Sidt Sunu Sunuwar Tai_Yo Tayo Todhri Todr Tolong_Siki Tols Tulu_Tigalari Tutg Unknown Zzzz"},Ct={};function At(t){var e=Ct[t]={binary:L(yt[t]+" "+xt),binaryOfStrings:L(vt[t]),nonBinary:{General_Category:L(xt),Script:L(kt[t])}};e.nonBinary.Script_Extensions=e.nonBinary.Script,e.nonBinary.gc=e.nonBinary.General_Category,e.nonBinary.sc=e.nonBinary.Script,e.nonBinary.scx=e.nonBinary.Script_Extensions}for(var It=0,Tt=[9,10,11,12,13,14];It<Tt.length;It+=1)At(Tt[It]);var Pt=j.prototype,Nt=function(t,e){this.parent=t,this.base=e||this};Nt.prototype.separatedFrom=function(t){for(var e=this;e;e=e.parent)for(var n=t;n;n=n.parent)if(e.base===n.base&&e!==n)return!0;return!1},Nt.prototype.sibling=function(){return new Nt(this.parent,this.base)};var Lt=function(t){this.parser=t,this.validFlags="gim"+(6>t.options.ecmaVersion?"":"uy")+(9>t.options.ecmaVersion?"":"s")+(13>t.options.ecmaVersion?"":"d")+(15>t.options.ecmaVersion?"":"v"),this.unicodeProperties=Ct[14>t.options.ecmaVersion?t.options.ecmaVersion:14],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 Mt(t){return 105===t||109===t||115===t}function Vt(t){return 36===t||t>=40&&43>=t||46===t||63===t||t>=91&&94>=t||t>=123&&125>=t}function Ot(t){return t>=65&&90>=t||t>=97&&122>=t}function Rt(t){return Ot(t)||95===t}function Dt(t){return Rt(t)||Ft(t)}function Ft(t){return t>=48&&57>=t}function Bt(t){return t>=48&&57>=t||t>=65&&70>=t||t>=97&&102>=t}function Ut(t){return 65>t||t>70?97>t||t>102?t-48:t-97+10:t-65+10}function jt(t){return t>=48&&55>=t}Lt.prototype.reset=function(t,e,n){var s=-1!==n.indexOf("v"),r=-1!==n.indexOf("u");this.start=0|t,this.source=e+"",this.flags=n,s&&this.parser.options.ecmaVersion>=15?(this.switchU=!0,this.switchV=!0,this.switchN=!0):(this.switchU=r&&this.parser.options.ecmaVersion>=6,this.switchV=!1,this.switchN=r&&this.parser.options.ecmaVersion>=9)},Lt.prototype.raise=function(t){this.parser.raiseRecoverable(this.start,"Invalid regular expression: /"+this.source+"/: "+t)},Lt.prototype.at=function(t,e){void 0===e&&(e=!1);var n=this.source,s=n.length;if(t>=s)return-1;var r=n.charCodeAt(t);if(!e&&!this.switchU||55295>=r||r>=57344||t+1>=s)return r;var i=n.charCodeAt(t+1);return 56320>i||i>57343?r:(r<<10)+i-56613888},Lt.prototype.nextIndex=function(t,e){void 0===e&&(e=!1);var n=this.source,s=n.length;if(t>=s)return s;var r,i=n.charCodeAt(t);return(e||this.switchU)&&i>55295&&57344>i&&s>t+1&&(r=n.charCodeAt(t+1))>=56320&&57343>=r?t+2:t+1},Lt.prototype.current=function(t){return void 0===t&&(t=!1),this.at(this.pos,t)},Lt.prototype.lookahead=function(t){return void 0===t&&(t=!1),this.at(this.nextIndex(this.pos,t),t)},Lt.prototype.advance=function(t){void 0===t&&(t=!1),this.pos=this.nextIndex(this.pos,t)},Lt.prototype.eat=function(t,e){return void 0===e&&(e=!1),this.current(e)===t&&(this.advance(e),!0)},Lt.prototype.eatChars=function(t,e){void 0===e&&(e=!1);for(var n=this.pos,s=0,r=t;s<r.length;s+=1){var i=r[s],a=this.at(n,e);if(-1===a||a!==i)return!1;n=this.nextIndex(n,e)}return this.pos=n,!0},Pt.validateRegExpFlags=function(t){for(var e=t.validFlags,n=t.flags,s=!1,r=!1,i=0;i<n.length;i++){var a=n.charAt(i);-1===e.indexOf(a)&&this.raise(t.start,"Invalid regular expression flag"),n.indexOf(a,i+1)>-1&&this.raise(t.start,"Duplicate regular expression flag"),"u"===a&&(s=!0),"v"===a&&(r=!0)}this.options.ecmaVersion>=15&&s&&r&&this.raise(t.start,"Invalid regular expression flag")},Pt.validateRegExpPattern=function(t){this.regexp_pattern(t),t.switchN||9>this.options.ecmaVersion||!function(t){for(var e in t)return!0;return!1}(t.groupNames)||(t.switchN=!0,this.regexp_pattern(t))},Pt.regexp_pattern=function(t){t.pos=0,t.lastIntValue=0,t.lastStringValue="",t.lastAssertionIsQuantifiable=!1,t.numCapturingParens=0,t.maxBackReference=0,t.groupNames=Object.create(null),t.backReferenceNames.length=0,t.branchID=null,this.regexp_disjunction(t),t.pos!==t.source.length&&(t.eat(41)&&t.raise("Unmatched ')'"),(t.eat(93)||t.eat(125))&&t.raise("Lone quantifier brackets")),t.maxBackReference>t.numCapturingParens&&t.raise("Invalid escape");for(var e=0,n=t.backReferenceNames;e<n.length;e+=1){var s=n[e];t.groupNames[s]||t.raise("Invalid named capture referenced")}},Pt.regexp_disjunction=function(t){var e=this.options.ecmaVersion>=16;for(e&&(t.branchID=new Nt(t.branchID,null)),this.regexp_alternative(t);t.eat(124);)e&&(t.branchID=t.branchID.sibling()),this.regexp_alternative(t);e&&(t.branchID=t.branchID.parent),this.regexp_eatQuantifier(t,!0)&&t.raise("Nothing to repeat"),t.eat(123)&&t.raise("Lone quantifier brackets")},Pt.regexp_alternative=function(t){for(;t.pos<t.source.length&&this.regexp_eatTerm(t););},Pt.regexp_eatTerm=function(t){return this.regexp_eatAssertion(t)?(t.lastAssertionIsQuantifiable&&this.regexp_eatQuantifier(t)&&t.switchU&&t.raise("Invalid quantifier"),!0):!!(t.switchU?this.regexp_eatAtom(t):this.regexp_eatExtendedAtom(t))&&(this.regexp_eatQuantifier(t),!0)},Pt.regexp_eatAssertion=function(t){var e=t.pos;if(t.lastAssertionIsQuantifiable=!1,t.eat(94)||t.eat(36))return!0;if(t.eat(92)){if(t.eat(66)||t.eat(98))return!0;t.pos=e}if(t.eat(40)&&t.eat(63)){var n=!1;if(9>this.options.ecmaVersion||(n=t.eat(60)),t.eat(61)||t.eat(33))return this.regexp_disjunction(t),t.eat(41)||t.raise("Unterminated group"),t.lastAssertionIsQuantifiable=!n,!0}return t.pos=e,!1},Pt.regexp_eatQuantifier=function(t,e){return void 0===e&&(e=!1),!!this.regexp_eatQuantifierPrefix(t,e)&&(t.eat(63),!0)},Pt.regexp_eatQuantifierPrefix=function(t,e){return t.eat(42)||t.eat(43)||t.eat(63)||this.regexp_eatBracedQuantifier(t,e)},Pt.regexp_eatBracedQuantifier=function(t,e){var n=t.pos;if(t.eat(123)){var s=0,r=-1;if(this.regexp_eatDecimalDigits(t)&&(s=t.lastIntValue,t.eat(44)&&this.regexp_eatDecimalDigits(t)&&(r=t.lastIntValue),t.eat(125)))return-1!==r&&s>r&&!e&&t.raise("numbers out of order in {} quantifier"),!0;t.switchU&&!e&&t.raise("Incomplete quantifier"),t.pos=n}return!1},Pt.regexp_eatAtom=function(t){return this.regexp_eatPatternCharacters(t)||t.eat(46)||this.regexp_eatReverseSolidusAtomEscape(t)||this.regexp_eatCharacterClass(t)||this.regexp_eatUncapturingGroup(t)||this.regexp_eatCapturingGroup(t)},Pt.regexp_eatReverseSolidusAtomEscape=function(t){var e=t.pos;if(t.eat(92)){if(this.regexp_eatAtomEscape(t))return!0;t.pos=e}return!1},Pt.regexp_eatUncapturingGroup=function(t){var e=t.pos;if(t.eat(40)){if(t.eat(63)){if(this.options.ecmaVersion>=16){var n=this.regexp_eatModifiers(t),s=t.eat(45);if(n||s){for(var r=0;r<n.length;r++){var i=n.charAt(r);n.indexOf(i,r+1)>-1&&t.raise("Duplicate regular expression modifiers")}if(s){var a=this.regexp_eatModifiers(t);n||a||58!==t.current()||t.raise("Invalid regular expression modifiers");for(var o=0;o<a.length;o++){var c=a.charAt(o);(a.indexOf(c,o+1)>-1||n.indexOf(c)>-1)&&t.raise("Duplicate regular expression modifiers")}}}}if(t.eat(58)){if(this.regexp_disjunction(t),t.eat(41))return!0;t.raise("Unterminated group")}}t.pos=e}return!1},Pt.regexp_eatCapturingGroup=function(t){if(t.eat(40)){if(9>this.options.ecmaVersion?63===t.current()&&t.raise("Invalid group"):this.regexp_groupSpecifier(t),this.regexp_disjunction(t),t.eat(41))return t.numCapturingParens+=1,!0;t.raise("Unterminated group")}return!1},Pt.regexp_eatModifiers=function(t){for(var e="",n=0;-1!==(n=t.current())&&Mt(n);)e+=M(n),t.advance();return e},Pt.regexp_eatExtendedAtom=function(t){return t.eat(46)||this.regexp_eatReverseSolidusAtomEscape(t)||this.regexp_eatCharacterClass(t)||this.regexp_eatUncapturingGroup(t)||this.regexp_eatCapturingGroup(t)||this.regexp_eatInvalidBracedQuantifier(t)||this.regexp_eatExtendedPatternCharacter(t)},Pt.regexp_eatInvalidBracedQuantifier=function(t){return this.regexp_eatBracedQuantifier(t,!0)&&t.raise("Nothing to repeat"),!1},Pt.regexp_eatSyntaxCharacter=function(t){var e=t.current();return!!Vt(e)&&(t.lastIntValue=e,t.advance(),!0)},Pt.regexp_eatPatternCharacters=function(t){for(var e=t.pos,n=0;-1!==(n=t.current())&&!Vt(n);)t.advance();return t.pos!==e},Pt.regexp_eatExtendedPatternCharacter=function(t){var e=t.current();return-1!==e&&36!==e&&(40>e||e>43)&&46!==e&&63!==e&&91!==e&&94!==e&&124!==e&&(t.advance(),!0)},Pt.regexp_groupSpecifier=function(t){if(t.eat(63)){this.regexp_eatGroupName(t)||t.raise("Invalid group");var e=this.options.ecmaVersion>=16,n=t.groupNames[t.lastStringValue];if(n)if(e)for(var s=0,r=n;s<r.length;s+=1)r[s].separatedFrom(t.branchID)||t.raise("Duplicate capture group name");else t.raise("Duplicate capture group name");e?(n||(t.groupNames[t.lastStringValue]=[])).push(t.branchID):t.groupNames[t.lastStringValue]=!0}},Pt.regexp_eatGroupName=function(t){if(t.lastStringValue="",t.eat(60)){if(this.regexp_eatRegExpIdentifierName(t)&&t.eat(62))return!0;t.raise("Invalid capture group name")}return!1},Pt.regexp_eatRegExpIdentifierName=function(t){if(t.lastStringValue="",this.regexp_eatRegExpIdentifierStart(t)){for(t.lastStringValue+=M(t.lastIntValue);this.regexp_eatRegExpIdentifierPart(t);)t.lastStringValue+=M(t.lastIntValue);return!0}return!1},Pt.regexp_eatRegExpIdentifierStart=function(t){var e=t.pos,n=this.options.ecmaVersion>=11,s=t.current(n);return t.advance(n),92===s&&this.regexp_eatRegExpUnicodeEscapeSequence(t,n)&&(s=t.lastIntValue),function(t){return h(t,!0)||36===t||95===t}(s)?(t.lastIntValue=s,!0):(t.pos=e,!1)},Pt.regexp_eatRegExpIdentifierPart=function(t){var e=t.pos,n=this.options.ecmaVersion>=11,s=t.current(n);return t.advance(n),92===s&&this.regexp_eatRegExpUnicodeEscapeSequence(t,n)&&(s=t.lastIntValue),function(t){return p(t,!0)||36===t||95===t||8204===t||8205===t}(s)?(t.lastIntValue=s,!0):(t.pos=e,!1)},Pt.regexp_eatAtomEscape=function(t){return!!(this.regexp_eatBackReference(t)||this.regexp_eatCharacterClassEscape(t)||this.regexp_eatCharacterEscape(t)||t.switchN&&this.regexp_eatKGroupName(t))||(t.switchU&&(99===t.current()&&t.raise("Invalid unicode escape"),t.raise("Invalid escape")),!1)},Pt.regexp_eatBackReference=function(t){var e=t.pos;if(this.regexp_eatDecimalEscape(t)){var n=t.lastIntValue;if(t.switchU)return n>t.maxBackReference&&(t.maxBackReference=n),!0;if(n<=t.numCapturingParens)return!0;t.pos=e}return!1},Pt.regexp_eatKGroupName=function(t){if(t.eat(107)){if(this.regexp_eatGroupName(t))return t.backReferenceNames.push(t.lastStringValue),!0;t.raise("Invalid named reference")}return!1},Pt.regexp_eatCharacterEscape=function(t){return this.regexp_eatControlEscape(t)||this.regexp_eatCControlLetter(t)||this.regexp_eatZero(t)||this.regexp_eatHexEscapeSequence(t)||this.regexp_eatRegExpUnicodeEscapeSequence(t,!1)||!t.switchU&&this.regexp_eatLegacyOctalEscapeSequence(t)||this.regexp_eatIdentityEscape(t)},Pt.regexp_eatCControlLetter=function(t){var e=t.pos;if(t.eat(99)){if(this.regexp_eatControlLetter(t))return!0;t.pos=e}return!1},Pt.regexp_eatZero=function(t){return 48===t.current()&&!Ft(t.lookahead())&&(t.lastIntValue=0,t.advance(),!0)},Pt.regexp_eatControlEscape=function(t){var e=t.current();return 116===e?(t.lastIntValue=9,t.advance(),!0):110===e?(t.lastIntValue=10,t.advance(),!0):118===e?(t.lastIntValue=11,t.advance(),!0):102===e?(t.lastIntValue=12,t.advance(),!0):114===e&&(t.lastIntValue=13,t.advance(),!0)},Pt.regexp_eatControlLetter=function(t){var e=t.current();return!!Ot(e)&&(t.lastIntValue=e%32,t.advance(),!0)},Pt.regexp_eatRegExpUnicodeEscapeSequence=function(t,e){void 0===e&&(e=!1);var n,s=t.pos,r=e||t.switchU;if(t.eat(117)){if(this.regexp_eatFixedHexDigits(t,4)){var i=t.lastIntValue;if(r&&i>=55296&&56319>=i){var a=t.pos;if(t.eat(92)&&t.eat(117)&&this.regexp_eatFixedHexDigits(t,4)){var o=t.lastIntValue;if(o>=56320&&57343>=o)return t.lastIntValue=1024*(i-55296)+(o-56320)+65536,!0}t.pos=a,t.lastIntValue=i}return!0}if(r&&t.eat(123)&&this.regexp_eatHexDigits(t)&&t.eat(125)&&(n=t.lastIntValue)>=0&&1114111>=n)return!0;r&&t.raise("Invalid unicode escape"),t.pos=s}return!1},Pt.regexp_eatIdentityEscape=function(t){if(t.switchU)return!!this.regexp_eatSyntaxCharacter(t)||!!t.eat(47)&&(t.lastIntValue=47,!0);var e=t.current();return!(99===e||t.switchN&&107===e||(t.lastIntValue=e,t.advance(),0))},Pt.regexp_eatDecimalEscape=function(t){t.lastIntValue=0;var e=t.current();if(e>=49&&57>=e){do{t.lastIntValue=10*t.lastIntValue+(e-48),t.advance()}while((e=t.current())>=48&&57>=e);return!0}return!1},Pt.regexp_eatCharacterClassEscape=function(t){var e=t.current();if(function(t){return 100===t||68===t||115===t||83===t||119===t||87===t}(e))return t.lastIntValue=-1,t.advance(),1;var n=!1;if(t.switchU&&this.options.ecmaVersion>=9&&((n=80===e)||112===e)){var s;if(t.lastIntValue=-1,t.advance(),t.eat(123)&&(s=this.regexp_eatUnicodePropertyValueExpression(t))&&t.eat(125))return n&&2===s&&t.raise("Invalid property name"),s;t.raise("Invalid property name")}return 0},Pt.regexp_eatUnicodePropertyValueExpression=function(t){var e=t.pos;if(this.regexp_eatUnicodePropertyName(t)&&t.eat(61)){var n=t.lastStringValue;if(this.regexp_eatUnicodePropertyValue(t)){var s=t.lastStringValue;return this.regexp_validateUnicodePropertyNameAndValue(t,n,s),1}}if(t.pos=e,this.regexp_eatLoneUnicodePropertyNameOrValue(t)){var r=t.lastStringValue;return this.regexp_validateUnicodePropertyNameOrValue(t,r)}return 0},Pt.regexp_validateUnicodePropertyNameAndValue=function(t,e,n){T(t.unicodeProperties.nonBinary,e)||t.raise("Invalid property name"),t.unicodeProperties.nonBinary[e].test(n)||t.raise("Invalid property value")},Pt.regexp_validateUnicodePropertyNameOrValue=function(t,e){return t.unicodeProperties.binary.test(e)?1:t.switchV&&t.unicodeProperties.binaryOfStrings.test(e)?2:void t.raise("Invalid property name")},Pt.regexp_eatUnicodePropertyName=function(t){var e=0;for(t.lastStringValue="";Rt(e=t.current());)t.lastStringValue+=M(e),t.advance();return""!==t.lastStringValue},Pt.regexp_eatUnicodePropertyValue=function(t){var e=0;for(t.lastStringValue="";Dt(e=t.current());)t.lastStringValue+=M(e),t.advance();return""!==t.lastStringValue},Pt.regexp_eatLoneUnicodePropertyNameOrValue=function(t){return this.regexp_eatUnicodePropertyValue(t)},Pt.regexp_eatCharacterClass=function(t){if(t.eat(91)){var e=t.eat(94),n=this.regexp_classContents(t);return t.eat(93)||t.raise("Unterminated character class"),e&&2===n&&t.raise("Negated character class may contain strings"),!0}return!1},Pt.regexp_classContents=function(t){return 93===t.current()?1:t.switchV?this.regexp_classSetExpression(t):(this.regexp_nonEmptyClassRanges(t),1)},Pt.regexp_nonEmptyClassRanges=function(t){for(;this.regexp_eatClassAtom(t);){var e=t.lastIntValue;if(t.eat(45)&&this.regexp_eatClassAtom(t)){var n=t.lastIntValue;!t.switchU||-1!==e&&-1!==n||t.raise("Invalid character class"),-1!==e&&-1!==n&&e>n&&t.raise("Range out of order in character class")}}},Pt.regexp_eatClassAtom=function(t){var e=t.pos;if(t.eat(92)){if(this.regexp_eatClassEscape(t))return!0;if(t.switchU){var n=t.current();(99===n||jt(n))&&t.raise("Invalid class escape"),t.raise("Invalid escape")}t.pos=e}var s=t.current();return 93!==s&&(t.lastIntValue=s,t.advance(),!0)},Pt.regexp_eatClassEscape=function(t){var e=t.pos;if(t.eat(98))return t.lastIntValue=8,!0;if(t.switchU&&t.eat(45))return t.lastIntValue=45,!0;if(!t.switchU&&t.eat(99)){if(this.regexp_eatClassControlLetter(t))return!0;t.pos=e}return this.regexp_eatCharacterClassEscape(t)||this.regexp_eatCharacterEscape(t)},Pt.regexp_classSetExpression=function(t){var e,n=1;if(this.regexp_eatClassSetRange(t));else if(e=this.regexp_eatClassSetOperand(t)){2===e&&(n=2);for(var s=t.pos;t.eatChars([38,38]);)38!==t.current()&&(e=this.regexp_eatClassSetOperand(t))?2!==e&&(n=1):t.raise("Invalid character in character class");if(s!==t.pos)return n;for(;t.eatChars([45,45]);)this.regexp_eatClassSetOperand(t)||t.raise("Invalid character in character class");if(s!==t.pos)return n}else t.raise("Invalid character in character class");for(;;)if(!this.regexp_eatClassSetRange(t)){if(!(e=this.regexp_eatClassSetOperand(t)))return n;2===e&&(n=2)}},Pt.regexp_eatClassSetRange=function(t){var e=t.pos;if(this.regexp_eatClassSetCharacter(t)){var n=t.lastIntValue;if(t.eat(45)&&this.regexp_eatClassSetCharacter(t)){var s=t.lastIntValue;return-1!==n&&-1!==s&&n>s&&t.raise("Range out of order in character class"),!0}t.pos=e}return!1},Pt.regexp_eatClassSetOperand=function(t){return this.regexp_eatClassSetCharacter(t)?1:this.regexp_eatClassStringDisjunction(t)||this.regexp_eatNestedClass(t)},Pt.regexp_eatNestedClass=function(t){var e=t.pos;if(t.eat(91)){var n=t.eat(94),s=this.regexp_classContents(t);if(t.eat(93))return n&&2===s&&t.raise("Negated character class may contain strings"),s;t.pos=e}if(t.eat(92)){var r=this.regexp_eatCharacterClassEscape(t);if(r)return r;t.pos=e}return null},Pt.regexp_eatClassStringDisjunction=function(t){var e=t.pos;if(t.eatChars([92,113])){if(t.eat(123)){var n=this.regexp_classStringDisjunctionContents(t);if(t.eat(125))return n}else t.raise("Invalid escape");t.pos=e}return null},Pt.regexp_classStringDisjunctionContents=function(t){for(var e=this.regexp_classString(t);t.eat(124);)2===this.regexp_classString(t)&&(e=2);return e},Pt.regexp_classString=function(t){for(var e=0;this.regexp_eatClassSetCharacter(t);)e++;return 1===e?1:2},Pt.regexp_eatClassSetCharacter=function(t){var e=t.pos;if(t.eat(92))return!(!this.regexp_eatCharacterEscape(t)&&!this.regexp_eatClassSetReservedPunctuator(t)&&(t.eat(98)?(t.lastIntValue=8,0):(t.pos=e,1)));var n=t.current();return!(0>n||n===t.lookahead()&&function(t){return 33===t||t>=35&&38>=t||t>=42&&44>=t||46===t||t>=58&&64>=t||94===t||96===t||126===t}(n)||function(t){return 40===t||41===t||45===t||47===t||t>=91&&93>=t||t>=123&&125>=t}(n)||(t.advance(),t.lastIntValue=n,0))},Pt.regexp_eatClassSetReservedPunctuator=function(t){var e=t.current();return!!function(t){return 33===t||35===t||37===t||38===t||44===t||45===t||t>=58&&62>=t||64===t||96===t||126===t}(e)&&(t.lastIntValue=e,t.advance(),!0)},Pt.regexp_eatClassControlLetter=function(t){var e=t.current();return!(!Ft(e)&&95!==e||(t.lastIntValue=e%32,t.advance(),0))},Pt.regexp_eatHexEscapeSequence=function(t){var e=t.pos;if(t.eat(120)){if(this.regexp_eatFixedHexDigits(t,2))return!0;t.switchU&&t.raise("Invalid escape"),t.pos=e}return!1},Pt.regexp_eatDecimalDigits=function(t){var e=t.pos,n=0;for(t.lastIntValue=0;Ft(n=t.current());)t.lastIntValue=10*t.lastIntValue+(n-48),t.advance();return t.pos!==e},Pt.regexp_eatHexDigits=function(t){var e=t.pos,n=0;for(t.lastIntValue=0;Bt(n=t.current());)t.lastIntValue=16*t.lastIntValue+Ut(n),t.advance();return t.pos!==e},Pt.regexp_eatLegacyOctalEscapeSequence=function(t){if(this.regexp_eatOctalDigit(t)){var e=t.lastIntValue;if(this.regexp_eatOctalDigit(t)){var n=t.lastIntValue;3>=e&&this.regexp_eatOctalDigit(t)?t.lastIntValue=64*e+8*n+t.lastIntValue:t.lastIntValue=8*e+n}else t.lastIntValue=e;return!0}return!1},Pt.regexp_eatOctalDigit=function(t){var e=t.current();return jt(e)?(t.lastIntValue=e-48,t.advance(),!0):(t.lastIntValue=0,!1)},Pt.regexp_eatFixedHexDigits=function(t,e){var n=t.pos;t.lastIntValue=0;for(var s=0;e>s;++s){var r=t.current();if(!Bt(r))return t.pos=n,!1;t.lastIntValue=16*t.lastIntValue+Ut(r),t.advance()}return!0};var Wt=function(t){this.type=t.type,this.value=t.value,this.start=t.start,this.end=t.end,t.options.locations&&(this.loc=new R(t,t.startLoc,t.endLoc)),t.options.ranges&&(this.range=[t.start,t.end])},$t=j.prototype;function qt(t){return"function"!=typeof BigInt?null:BigInt(t.replace(/_/g,""))}$t.next=function(t){!t&&this.type.keyword&&this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword "+this.type.keyword),this.options.onToken&&this.options.onToken(new Wt(this)),this.lastTokEnd=this.end,this.lastTokStart=this.start,this.lastTokEndLoc=this.endLoc,this.lastTokStartLoc=this.startLoc,this.nextToken()},$t.getToken=function(){return this.next(),new Wt(this)},"undefined"!=typeof Symbol&&($t[Symbol.iterator]=function(){var t=this;return{next:function(){var e=t.getToken();return{done:e.type===x.eof,value:e}}}}),$t.nextToken=function(){var t=this.curContext();return t&&t.preserveSpace||this.skipSpace(),this.start=this.pos,this.options.locations&&(this.startLoc=this.curPosition()),this.pos<this.input.length?t.override?t.override(this):void this.readToken(this.fullCharCodeAtPos()):this.finishToken(x.eof)},$t.readToken=function(t){return h(t,this.options.ecmaVersion>=6)||92===t?this.readWord():this.getTokenFromCode(t)},$t.fullCharCodeAt=function(t){var e=this.input.charCodeAt(t);if(55295>=e||e>=56320)return e;var n=this.input.charCodeAt(t+1);return n>56319&&57344>n?(e<<10)+n-56613888:e},$t.fullCharCodeAtPos=function(){return this.fullCharCodeAt(this.pos)},$t.skipBlockComment=function(){var t=this.options.onComment&&this.curPosition(),e=this.pos,n=this.input.indexOf("*/",this.pos+=2);if(-1===n&&this.raise(this.pos-2,"Unterminated comment"),this.pos=n+2,this.options.locations)for(var s=void 0,r=e;(s=E(this.input,r,this.pos))>-1;)++this.curLine,r=this.lineStart=s;this.options.onComment&&this.options.onComment(!0,this.input.slice(e+2,n),e,this.pos,t,this.curPosition())},$t.skipLineComment=function(t){for(var e=this.pos,n=this.options.onComment&&this.curPosition(),s=this.input.charCodeAt(this.pos+=t);this.pos<this.input.length&&!w(s);)s=this.input.charCodeAt(++this.pos);this.options.onComment&&this.options.onComment(!1,this.input.slice(e+t,this.pos),e,this.pos,n,this.curPosition())},$t.skipSpace=function(){t:for(;this.pos<this.input.length;){var t=this.input.charCodeAt(this.pos);switch(t){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 t}break;default:if(!(t>8&&14>t||t>=5760&&S.test(String.fromCharCode(t))))break t;++this.pos}}},$t.finishToken=function(t,e){this.end=this.pos,this.options.locations&&(this.endLoc=this.curPosition());var n=this.type;this.type=t,this.value=e,this.updateContext(n)},$t.readToken_dot=function(){var t=this.input.charCodeAt(this.pos+1);if(t>=48&&57>=t)return this.readNumber(!0);var e=this.input.charCodeAt(this.pos+2);return 6>this.options.ecmaVersion||46!==t||46!==e?(++this.pos,this.finishToken(x.dot)):(this.pos+=3,this.finishToken(x.ellipsis))},$t.readToken_slash=function(){var t=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp()):61===t?this.finishOp(x.assign,2):this.finishOp(x.slash,1)},$t.readToken_mult_modulo_exp=function(t){var e=this.input.charCodeAt(this.pos+1),n=1,s=42===t?x.star:x.modulo;return 7>this.options.ecmaVersion||42!==t||42!==e||(++n,s=x.starstar,e=this.input.charCodeAt(this.pos+2)),61===e?this.finishOp(x.assign,n+1):this.finishOp(s,n)},$t.readToken_pipe_amp=function(t){var e=this.input.charCodeAt(this.pos+1);return e===t?12>this.options.ecmaVersion||61!==this.input.charCodeAt(this.pos+2)?this.finishOp(124===t?x.logicalOR:x.logicalAND,2):this.finishOp(x.assign,3):61===e?this.finishOp(x.assign,2):this.finishOp(124===t?x.bitwiseOR:x.bitwiseAND,1)},$t.readToken_caret=function(){return 61===this.input.charCodeAt(this.pos+1)?this.finishOp(x.assign,2):this.finishOp(x.bitwiseXOR,1)},$t.readToken_plus_min=function(t){var e=this.input.charCodeAt(this.pos+1);return e===t?45!==e||this.inModule||62!==this.input.charCodeAt(this.pos+2)||0!==this.lastTokEnd&&!b.test(this.input.slice(this.lastTokEnd,this.pos))?this.finishOp(x.incDec,2):(this.skipLineComment(3),this.skipSpace(),this.nextToken()):61===e?this.finishOp(x.assign,2):this.finishOp(x.plusMin,1)},$t.readToken_lt_gt=function(t){var e=this.input.charCodeAt(this.pos+1),n=1;return e===t?(n=62===t&&62===this.input.charCodeAt(this.pos+2)?3:2,61===this.input.charCodeAt(this.pos+n)?this.finishOp(x.assign,n+1):this.finishOp(x.bitShift,n)):33!==e||60!==t||this.inModule||45!==this.input.charCodeAt(this.pos+2)||45!==this.input.charCodeAt(this.pos+3)?(61===e&&(n=2),this.finishOp(x.relational,n)):(this.skipLineComment(4),this.skipSpace(),this.nextToken())},$t.readToken_eq_excl=function(t){var e=this.input.charCodeAt(this.pos+1);return 61===e?this.finishOp(x.equality,61===this.input.charCodeAt(this.pos+2)?3:2):61!==t||62!==e||6>this.options.ecmaVersion?this.finishOp(61===t?x.eq:x.prefix,1):(this.pos+=2,this.finishToken(x.arrow))},$t.readToken_question=function(){var t=this.options.ecmaVersion;if(t>=11){var e=this.input.charCodeAt(this.pos+1);if(46===e){var n=this.input.charCodeAt(this.pos+2);if(48>n||n>57)return this.finishOp(x.questionDot,2)}if(63===e)return 12>t||61!==this.input.charCodeAt(this.pos+2)?this.finishOp(x.coalesce,2):this.finishOp(x.assign,3)}return this.finishOp(x.question,1)},$t.readToken_numberSign=function(){var t=35;if(this.options.ecmaVersion>=13&&(++this.pos,h(t=this.fullCharCodeAtPos(),!0)||92===t))return this.finishToken(x.privateId,this.readWord1());this.raise(this.pos,"Unexpected character '"+M(t)+"'")},$t.getTokenFromCode=function(t){switch(t){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(x.parenL);case 41:return++this.pos,this.finishToken(x.parenR);case 59:return++this.pos,this.finishToken(x.semi);case 44:return++this.pos,this.finishToken(x.comma);case 91:return++this.pos,this.finishToken(x.bracketL);case 93:return++this.pos,this.finishToken(x.bracketR);case 123:return++this.pos,this.finishToken(x.braceL);case 125:return++this.pos,this.finishToken(x.braceR);case 58:return++this.pos,this.finishToken(x.colon);case 96:if(6>this.options.ecmaVersion)break;return++this.pos,this.finishToken(x.backQuote);case 48:var e=this.input.charCodeAt(this.pos+1);if(120===e||88===e)return this.readRadixNumber(16);if(this.options.ecmaVersion>=6){if(111===e||79===e)return this.readRadixNumber(8);if(98===e||66===e)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(t);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(t);case 124:case 38:return this.readToken_pipe_amp(t);case 94:return this.readToken_caret();case 43:case 45:return this.readToken_plus_min(t);case 60:case 62:return this.readToken_lt_gt(t);case 61:case 33:return this.readToken_eq_excl(t);case 63:return this.readToken_question();case 126:return this.finishOp(x.prefix,1);case 35:return this.readToken_numberSign()}this.raise(this.pos,"Unexpected character '"+M(t)+"'")},$t.finishOp=function(t,e){var n=this.input.slice(this.pos,this.pos+e);return this.pos+=e,this.finishToken(t,n)},$t.readRegexp=function(){for(var t,e,n=this.pos;;){this.pos<this.input.length||this.raise(n,"Unterminated regular expression");var s=this.input.charAt(this.pos);if(b.test(s)&&this.raise(n,"Unterminated regular expression"),t)t=!1;else{if("["===s)e=!0;else if("]"===s&&e)e=!1;else if("/"===s&&!e)break;t="\\"===s}++this.pos}var r=this.input.slice(n,this.pos);++this.pos;var i=this.pos,a=this.readWord1();this.containsEsc&&this.unexpected(i);var o=this.regexpState||(this.regexpState=new Lt(this));o.reset(n,r,a),this.validateRegExpFlags(o),this.validateRegExpPattern(o);var c=null;try{c=RegExp(r,a)}catch(t){}return this.finishToken(x.regexp,{pattern:r,flags:a,value:c})},$t.readInt=function(t,e,n){for(var s=this.options.ecmaVersion>=12&&void 0===e,r=n&&48===this.input.charCodeAt(this.pos),i=this.pos,a=0,o=0,c=0,l=null==e?1/0:e;l>c;++c,++this.pos){var u=this.input.charCodeAt(this.pos),h=void 0;if(s&&95===u)r&&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===c&&this.raiseRecoverable(this.pos,"Numeric separator is not allowed at the first of digits"),o=u;else{if((h=97>u?65>u?48>u||u>57?1/0:u-48:u-65+10:u-97+10)>=t)break;o=u,a=a*t+h}}return s&&95===o&&this.raiseRecoverable(this.pos-1,"Numeric separator is not allowed at the last of digits"),this.pos===i||null!=e&&this.pos-i!==e?null:a},$t.readRadixNumber=function(t){var e=this.pos;this.pos+=2;var n=this.readInt(t);return null==n&&this.raise(this.start+2,"Expected number in radix "+t),11>this.options.ecmaVersion||110!==this.input.charCodeAt(this.pos)?h(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"):(n=qt(this.input.slice(e,this.pos)),++this.pos),this.finishToken(x.num,n)},$t.readNumber=function(t){var e=this.pos;t||null!==this.readInt(10,void 0,!0)||this.raise(e,"Invalid number");var n=this.pos-e>=2&&48===this.input.charCodeAt(e);n&&this.strict&&this.raise(e,"Invalid number");var s=this.input.charCodeAt(this.pos);if(!n&&!t&&this.options.ecmaVersion>=11&&110===s){var r=qt(this.input.slice(e,this.pos));return++this.pos,h(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(x.num,r)}n&&/[89]/.test(this.input.slice(e,this.pos))&&(n=!1),46!==s||n||(++this.pos,this.readInt(10),s=this.input.charCodeAt(this.pos)),69!==s&&101!==s||n||(43!==(s=this.input.charCodeAt(++this.pos))&&45!==s||++this.pos,null===this.readInt(10)&&this.raise(e,"Invalid number")),h(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number");var i,a=(i=this.input.slice(e,this.pos),n?parseInt(i,8):parseFloat(i.replace(/_/g,"")));return this.finishToken(x.num,a)},$t.readCodePoint=function(){var t;if(123===this.input.charCodeAt(this.pos)){6>this.options.ecmaVersion&&this.unexpected();var e=++this.pos;t=this.readHexChar(this.input.indexOf("}",this.pos)-this.pos),++this.pos,t>1114111&&this.invalidStringToken(e,"Code point out of bounds")}else t=this.readHexChar(4);return t},$t.readString=function(t){for(var e="",n=++this.pos;;){this.pos<this.input.length||this.raise(this.start,"Unterminated string constant");var s=this.input.charCodeAt(this.pos);if(s===t)break;92===s?(e+=this.input.slice(n,this.pos),e+=this.readEscapedChar(!1),n=this.pos):8232===s||8233===s?(10>this.options.ecmaVersion&&this.raise(this.start,"Unterminated string constant"),++this.pos,this.options.locations&&(this.curLine++,this.lineStart=this.pos)):(w(s)&&this.raise(this.start,"Unterminated string constant"),++this.pos)}return e+=this.input.slice(n,this.pos++),this.finishToken(x.string,e)};var Ht={};function Gt(t,e){return j.parse(t,e)}$t.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(t){if(t!==Ht)throw t;this.readInvalidTemplateToken()}this.inTemplateElement=!1},$t.invalidStringToken=function(t,e){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw Ht;this.raise(t,e)},$t.readTmplToken=function(){for(var t="",e=this.pos;;){this.pos<this.input.length||this.raise(this.start,"Unterminated template");var n=this.input.charCodeAt(this.pos);if(96===n||36===n&&123===this.input.charCodeAt(this.pos+1))return this.pos!==this.start||this.type!==x.template&&this.type!==x.invalidTemplate?(t+=this.input.slice(e,this.pos),this.finishToken(x.template,t)):36===n?(this.pos+=2,this.finishToken(x.dollarBraceL)):(++this.pos,this.finishToken(x.backQuote));if(92===n)t+=this.input.slice(e,this.pos),t+=this.readEscapedChar(!0),e=this.pos;else if(w(n)){switch(t+=this.input.slice(e,this.pos),++this.pos,n){case 13:10===this.input.charCodeAt(this.pos)&&++this.pos;case 10:t+="\n";break;default:t+=String.fromCharCode(n)}this.options.locations&&(++this.curLine,this.lineStart=this.pos),e=this.pos}else++this.pos}},$t.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(x.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")},$t.readEscapedChar=function(t){var e=this.input.charCodeAt(++this.pos);switch(++this.pos,e){case 110:return"\n";case 114:return"\r";case 120:return String.fromCharCode(this.readHexChar(2));case 117:return M(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"),t){var n=this.pos-1;this.invalidStringToken(n,"Invalid escape sequence in template string")}default:if(e>=48&&55>=e){var s=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],r=parseInt(s,8);return r>255&&(s=s.slice(0,-1),r=parseInt(s,8)),this.pos+=s.length-1,e=this.input.charCodeAt(this.pos),"0"===s&&56!==e&&57!==e||!this.strict&&!t||this.invalidStringToken(this.pos-1-s.length,t?"Octal literal in template string":"Octal literal in strict mode"),String.fromCharCode(r)}return w(e)?(this.options.locations&&(this.lineStart=this.pos,++this.curLine),""):String.fromCharCode(e)}},$t.readHexChar=function(t){var e=this.pos,n=this.readInt(16,t);return null===n&&this.invalidStringToken(e,"Bad character escape sequence"),n},$t.readWord1=function(){this.containsEsc=!1;for(var t="",e=!0,n=this.pos,s=this.options.ecmaVersion>=6;this.pos<this.input.length;){var r=this.fullCharCodeAtPos();if(p(r,s))this.pos+=r>65535?2:1;else{if(92!==r)break;this.containsEsc=!0,t+=this.input.slice(n,this.pos);var i=this.pos;117!==this.input.charCodeAt(++this.pos)&&this.invalidStringToken(this.pos,"Expecting Unicode escape sequence \\uXXXX"),++this.pos;var a=this.readCodePoint();(e?h:p)(a,s)||this.invalidStringToken(i,"Invalid Unicode escape"),t+=M(a),n=this.pos}e=!1}return t+this.input.slice(n,this.pos)},$t.readWord=function(){var t=this.readWord1(),e=x.name;return this.keywords.test(t)&&(e=y[t]),this.finishToken(e,t)},j.acorn={Parser:j,version:"8.18.0",defaultOptions:F,Position:O,SourceLocation:R,getLineInfo:D,Node:ht,TokenType:f,tokTypes:x,keywordTypes:y,TokContext:et,tokContexts:nt,isIdentifierChar:p,isIdentifierStart:h,Token:Wt,isNewLine:w,lineBreak:b,lineBreakG:_,nonASCIIwhitespace:S};class zt{constructor(t){this.value=t}}const Yt=new Map,Kt=new Map,Jt=new Set(["constructor","__proto__","prototype"]),Qt=Symbol("GyosJS CSP optional chain");function Xt(t,e,n){const s="number"==typeof n?.start?" at position "+n.start:"";return Error(`[GyosJS CSP] ${t}${s}: ${e}`)}function Zt(t){const e=Yt.get(t);if(e)return e;try{const e=Gt(`(${t})`,{ecmaVersion:"latest"}),n=e.body[0]?.expression;if(!n)throw Xt("Empty expression",t);return Yt.set(t,n),n}catch(e){if(e instanceof Error&&e.message.startsWith("[GyosJS CSP]"))throw e;const n="number"==typeof e?.pos?" at position "+(e.pos-1):"";throw Error(`[GyosJS CSP] Invalid expression${n}: ${t}`)}}function te(t,e=!1){const n=`${e?"return":"event"}:${t}`,s=Kt.get(n);if(s)return s;try{const s=Gt(t,{ecmaVersion:"latest",allowReturnOutsideFunction:e});return Kt.set(n,s),s}catch(e){const n="number"==typeof e?.pos?" at position "+e.pos:"";throw Error(`[GyosJS CSP] Invalid expression body${n}: ${t}`)}}function ee(t,e,n){if(("string"==typeof t||"number"==typeof t)&&Jt.has(t+""))throw Xt(`Access to property "${t+""}" is forbidden`,e,n);if("string"!=typeof t&&"number"!=typeof t&&"symbol"!=typeof t)throw Xt("Invalid property key",e,n);return t}function ne(t,e,n,s){if(Object.prototype.hasOwnProperty.call(e.locals,t))return e.locals[t];if(t in e.scope)return e.scope[t];if("undefined"!==t){if("NaN"===t)return NaN;if("Infinity"===t)return 1/0;throw Xt(`Undefined identifier "${t}"`,n,s)}}function se(t,e,n){const s=ie(t.object,e,n);if(s===Qt)return[Qt,""];if(null==s){if(t.optional)return[Qt,""];throw Xt("Cannot read a property of null or undefined",n,t)}return[s,ee(t.computed?ie(t.property,e,n):t.property.name,n,t.property)]}function re(t,e,n){if("Identifier"===t.type)return{get:()=>ne(t.name,e,n,t),set:n=>(Object.prototype.hasOwnProperty.call(e.locals,t.name)?e.locals[t.name]=n:e.scope[t.name]=n,n)};if("MemberExpression"===t.type){const[s,r]=se(t,e,n);if(null==s)throw Xt("Invalid assignment target",n,t);return{get:()=>s[r],set:t=>(s[r]=t,t)}}throw Xt("Invalid assignment target",n,t)}function ie(t,e,n){switch(t.type){case"Literal":if(t.regex||"bigint"==typeof t.value)throw Xt("Unsupported literal",n,t);return t.value;case"Identifier":return ne(t.name,e,n,t);case"ArrayExpression":return t.elements.map(t=>{if(t){if("SpreadElement"===t.type)throw Xt("Spread elements are not supported",n,t);return ie(t,e,n)}});case"ObjectExpression":{const s={};for(const r of t.properties){if("Property"!==r.type||"init"!==r.kind||r.method)throw Xt("Object methods, getters, setters, and spread are not supported",n,r);s[ee(r.computed?ie(r.key,e,n):r.key.name??r.key.value,n,r.key)]=r.shorthand?ne(r.key.name,e,n,r.key):ie(r.value,e,n)}return s}case"MemberExpression":{const[s,r]=se(t,e,n);return s===Qt?Qt:s[r]}case"ChainExpression":{const s=ie(t.expression,e,n);return s===Qt?void 0:s}case"CallExpression":return function(t,e,n){const s=t.arguments.map(t=>{if("SpreadElement"===t.type)throw Xt("Spread arguments are not supported",n,t);return ie(t,e,n)});if("MemberExpression"===t.callee.type){const[r,i]=se(t.callee,e,n);if(r===Qt)return Qt;const a=r[i];if(null==a&&t.optional)return Qt;if("function"!=typeof a)throw Xt("Called value is not a function",n,t.callee);return a.apply(r,s)}const r=ie(t.callee,e,n);if(r===Qt)return Qt;if(null==r&&t.optional)return Qt;if("function"!=typeof r)throw Xt("Called value is not a function",n,t.callee);return r.apply(e.scope,s)}(t,e,n);case"UnaryExpression":{if("delete"===t.operator)throw Xt("The delete operator is not supported",n,t);const s=ie(t.argument,e,n);switch(t.operator){case"!":return!s;case"+":return+s;case"-":return-s;case"typeof":return typeof s;case"void":return;default:throw Xt(`Unsupported unary operator "${t.operator}"`,n,t)}}case"BinaryExpression":{const s=ie(t.left,e,n),r=ie(t.right,e,n);switch(t.operator){case"+":return s+r;case"-":return s-r;case"*":return s*r;case"/":return s/r;case"%":return s%r;case"**":return s**r;case"==":return s==r;case"!=":return s!=r;case"===":return s===r;case"!==":return s!==r;case"<":return r>s;case"<=":return r>=s;case">":return s>r;case">=":return s>=r;case"in":return s in r;case"instanceof":return s instanceof r;default:throw Xt(`Unsupported binary operator "${t.operator}"`,n,t)}}case"LogicalExpression":{const s=ie(t.left,e,n);if("&&"===t.operator)return s&&ie(t.right,e,n);if("||"===t.operator)return s||ie(t.right,e,n);if("??"===t.operator)return s??ie(t.right,e,n);throw Xt(`Unsupported logical operator "${t.operator}"`,n,t)}case"ConditionalExpression":return ie(t.test,e,n)?ie(t.consequent,e,n):ie(t.alternate,e,n);case"AssignmentExpression":{const s=re(t.left,e,n),r="="===t.operator?void 0:s.get();if("&&="===t.operator&&!r)return r;if("||="===t.operator&&r)return r;if("??="===t.operator&&null!=r)return r;const i=ie(t.right,e,n);return s.set(function(t,e,n,s,r){switch(t){case"=":return n;case"+=":return e+n;case"-=":return e-n;case"*=":return e*n;case"/=":return e/n;case"%=":return e%n;case"**=":return e**n;case"&&=":return e&&n;case"||=":return e||n;case"??=":return e??n;default:throw Xt(`Unsupported assignment operator "${t}"`,s,r)}}(t.operator,r,i,n,t))}case"UpdateExpression":{const s=re(t.argument,e,n),r=s.get(),i="++"===t.operator?r+1:r-1;return s.set(i),t.prefix?i:r}case"SequenceExpression":{let s;for(const r of t.expressions)s=ie(r,e,n);return s}default:throw Xt(`Unsupported syntax "${t.type}"`,n,t)}}function ae(t,e,n,s){let r;for(const i of t.body)if("EmptyStatement"!==i.type){if("ExpressionStatement"!==i.type){if(s&&"ReturnStatement"===i.type)throw new zt(i.argument?ie(i.argument,e,n):void 0);throw Xt(`Unsupported statement "${i.type}"`,n,i)}r=ie(i.expression,e,n)}return r}const oe={mode:"csp",evaluate(t,e){try{const n=e?.[t];return"function"==typeof n?n.call(e):ie(Zt(t),{scope:e,locals:{}},t)}catch(t){return}},execute(t,e,n){const s=e?.[t];return"function"==typeof s?s.call(e,n):ae(te(t),{scope:e,locals:{$event:n}},t,!1)},parseScope(t){try{const e=ie(Zt(t),{scope:{},locals:{}},t);if(!e||"object"!=typeof e||Array.isArray(e))throw Xt("Inline g-scope must evaluate to an object",t);return e}catch(t){return}},createMethod(t,e){let n;try{n=te(e,!0)}catch(t){return()=>{}}return function(...s){const r={};t.forEach((t,e)=>{r[t]=s[e]});try{return ae(n,{scope:this,locals:r},e,!0)}catch(t){return t instanceof zt?t.value:void 0}}}};let ce;function le(){if(!ce)throw Error("[GyosJS] Expression runtime is not configured. Import GyosJS from a public entry point.");return ce}function ue(){return ce?.mode??"standard"}function he(t){Promise.resolve().then(t)}function pe(t){"undefined"!=typeof document?"loading"===document.readyState?document.addEventListener("DOMContentLoaded",t,{once:!0}):queueMicrotask(t):t()}function fe(t,e){let n=null;return(...s)=>{null!==n&&clearTimeout(n),n=setTimeout(()=>{t(...s)},e)}}function de(t,e){let n=0;return(...s)=>{const r=Date.now();e>r-n||(n=r,t(...s))}}function me(t){if(null===t||"object"!=typeof t)return t;if(t instanceof Date)return new Date(t.getTime());if(t instanceof Array)return t.map(t=>me(t));const e={};for(const n in t)t.hasOwnProperty(n)&&(e[n]=me(t[n]));return e}function ge(t,e){if(t===e)return!0;if("object"!=typeof t||"object"!=typeof e||null==t||null==e)return!1;const n=Object.keys(t),s=Object.keys(e);if(n.length!==s.length)return!1;for(const s of n)if(!ge(t[s],e[s]))return!1;return!0}function ye(t,e){let n=t.parentElement;for(;n&&n!==e;){if(n.hasAttribute("g-static")||n.__gyos_static__)return!0;n=n.parentElement}return!1}function ve(t){return null!==t.closest("[g-ignore]")}const xe=new Set(["__proto__","prototype","constructor"]);function be(t){return t.split(/[.[\]]+/).filter(Boolean).some(t=>xe.has(t))}const _e=()=>"undefined"!=typeof window&&window.GYOS_DEBUG,we=()=>"undefined"!=typeof window&&window.GYOS_DEBUG_VERBOSE;function Ee(t,e,n=3){const s=document.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode:t=>e(t)?NodeFilter.FILTER_ACCEPT:n}),r=[];for(;s.nextNode();)r.push(s.currentNode);return r}function Se(...t){_e()}function ke(t){let e=t.parentElement;for(;e;){if(e.hasAttribute("*if")||e.hasAttribute("*for")||e.hasAttribute("*switch")||e.hasAttribute("*await"))return!0;e=e.parentElement}return!1}let Ce=null,Ae=0;const Ie=new Set;let Te=0;const Pe=new Set;let Ne=!1;function Le(){if(0===Pe.size||Ne)return;Ne=!0;const t=Array.from(Pe);Pe.clear(),t.forEach(t=>{if(!Ie.has(t))try{t()}catch(t){}}),Ne=!1}function Me(t){Pe.add(t),Ne||0!==Te||queueMicrotask(Le)}let Ve=new Set,Oe=!1;function Re(t,e){const n="string"==typeof e?e:e?.debugLabel,s="object"==typeof e&&e?.equals?e.equals:Object.is,r=++Ae;let i=t;const a=new Set;let o=!1;const c=()=>(Ce&&(a.has(Ce)||(a.add(Ce),Ce.__dependencies&&Ce.__dependencies.add(a),we(),!o&&"undefined"!=typeof window&&window.GYOS_DEBUG_WARN_SUBSCRIBERS&&_e()&&a.size>=200&&(o=!0))),i),l=t=>{s(i,t)||(i=t,we(),u())},u=()=>{we(),Oe?a.forEach(t=>Ve.add(t)):a.forEach(t=>Me(t))},h=function(t){return 0===arguments.length?c():(l(t),t)};return Object.defineProperties(h,{value:{get:c,set:l,enumerable:!0,configurable:!0},peek:{get:()=>i,enumerable:!0,configurable:!0},update:{value:function(t){l(t(i))},enumerable:!0,configurable:!0},subscribe:{value:function(t){return a.add(t),()=>a.delete(t)},enumerable:!0,configurable:!0},__gyos_signal__:{value:!0,enumerable:!0,configurable:!0},__gyos_debug_id__:{value:r,enumerable:!1},__gyos_debug_label__:{value:n,enumerable:!1},__gyos_equals__:{value:s,enumerable:!1}}),h}function De(t){let e,n=!0,s=!0;const r=new Set;let i;const a=()=>{(n||s)&&(i&&i(),i=Fe(()=>{try{const i=t();(s||e!==i)&&(e=i,s=!1,n=!1,Oe?r.forEach(t=>Ve.add(t)):r.forEach(t=>Me(t)))}catch(t){throw t}}),n=!1)},o=()=>((n||s)&&a(),Ce&&!r.has(Ce)&&(r.add(Ce),Ce.__dependencies&&Ce.__dependencies.add(r)),e),c=function(){return o()};return Object.defineProperties(c,{value:{get:o,enumerable:!0,configurable:!0},peek:{get:()=>((n||s)&&a(),e),enumerable:!0,configurable:!0},subscribe:{value:function(t){return r.add(t),()=>r.delete(t)},enumerable:!0,configurable:!0},__gyos_computed__:{value:!0}}),c}function Fe(t){let e,n=new Set,s=!0;const r=()=>{if(!s)return;if(Ie.has(r))return void _e();if(Ie.add(r),Te++,n.forEach(t=>{t.delete(r)}),_e(),n.clear(),e)try{e()}catch(t){}const i=Ce;Ce=r,r.__dependencies=n;try{const n=t();e="function"==typeof n?n:void 0}catch(t){}finally{Ce=i,Te--,Ie.delete(r),0===Te&&Pe.size>0&&queueMicrotask(Le)}};return r(),()=>{if(s&&(s=!1,n.forEach(t=>{t.delete(r)}),n.clear(),e))try{e()}catch(t){}}}function Be(t){if(Oe)t();else{Oe=!0,Ve.clear();try{t()}catch(t){throw t}finally{Oe=!1;const t=Array.from(Ve);Ve.clear(),t.forEach(t=>{try{t()}catch(t){}})}}}function Ue(t){return t&&"function"==typeof t&&"value"in t&&"peek"in t&&"__gyos_signal__"in t}function je(){return null!==Ce}function We(t){return t&&"function"==typeof t&&"value"in t&&"peek"in t&&"__gyos_computed__"in t}function $e(t){return Ue(t)?t.value:t}function qe(t){const e=Ce;Ce=null;try{return t()}finally{Ce=e}}class He{constructor(t){this.services=new Map,this.parent=null,this.parent=t||null}set(t,e){this.services.set(t,e)}get(t){if(this.services.has(t))return this.services.get(t);if(this.parent)return this.parent.get(t);throw Error(`[GyosJS] Service "${t}" not found in DI container`)}has(t){return this.services.has(t)||(this.parent?.has(t)??!1)}createChild(){return new He(this)}}const Ge=new He,ze=new WeakMap;function Ye(t){if(ze.has(t))return ze.get(t);let e=t.parentElement,n=Ge;for(;e;){if(ze.has(e)){n=ze.get(e);break}if(e.hasAttribute("g-provide")){n=Ye(e);break}e=e.parentElement}const s=n.createChild();ze.set(t,s);const r=t.getAttribute("g-provide");if(r)try{const t=JSON.parse(r);if(!t||Array.isArray(t)||"object"!=typeof t)throw new TypeError("g-provide must contain a JSON object");Object.entries(t).forEach(([t,e])=>{s.set(t,e)})}catch(t){}return s}function Ke(t,e){Ge.set(t,e)}function Je(t,e){if(Ge.has(t))return Ge.get(t);if(void 0!==e)return e;throw Error(`[GyosJS] Service "${t}" not found in DI container`)}function Qe(){return Ge}const Xe=new Map;function Ze(t,e){Xe.set(t,e)}function tn(t,e,n=[]){const s=Xe.get(e);if(!s)return _e(),t;try{return s(t,...n)}catch(e){return _e(),t}}function en(t,e){return t.replace(/\{([^}]+)\}/g,(t,n)=>{try{const t=nn(n.trim(),e);return null==t?"":t+""}catch(e){return t}})}function nn(t,e,n=!0){if(n&&function(t){let e=!1,n="";for(let s=0;s<t.length;s++){const r=t[s],i=s>0?t[s-1]:"";if('"'!==r&&"'"!==r||"\\"===i||(e?r===n&&(e=!1,n=""):(e=!0,n=r)),"|"===r&&!e&&"|"!==(s<t.length-1?t[s+1]:"")&&"|"!==i)return!0}return!1}(t)){const{base:n,pipes:s}=function(t){const e=[];let n="",s=!1,r="",i=0;for(;i<t.length;){const a=t[i],o=i>0?t[i-1]:"";'"'!==a&&"'"!==a||"\\"===o?"|"!==a||s?(n+=a,i++):"|"===t[i+1]?(n+="||",i+=2):(e.push(n.trim()),n="",i++):(s?a===r&&(s=!1,r=""):(s=!0,r=a),n+=a,i++)}e.push(n.trim());const a=e[0],o=e.slice(1).map(t=>{const e=t.indexOf("(");if(-1===e)return{name:t.trim(),args:[]};const n=t.substring(0,e).trim();let s=0,r=-1,i=!1,a="";for(let n=e;n<t.length;n++){const e=t[n],o=n>0?t[n-1]:"";if('"'!==e&&"'"!==e||"\\"===o||(i?e===a&&(i=!1,a=""):(i=!0,a=e)),!i&&("("===e&&s++,")"===e&&(s--,0===s))){r=n;break}}if(-1===r)return{name:t,args:[]};const o=t.substring(e+1,r),c=[];if(o){let t="",e=!1,n="";for(let s=0;s<o.length;s++){const r=o[s];'"'!==r&&"'"!==r||0!==s&&"\\"===o[s-1]?","!==r||e?t+=r:(c.push(t.trim()),t=""):(e?r===n&&(e=!1,n=""):(e=!0,n=r),t+=r)}t.trim()&&c.push(t.trim())}return{name:n,args:c}});return{base:a,pipes:o}}(t);let r=sn(n,e);for(const{name:t,args:n}of s)r=tn(r,t,n.map(t=>sn(t,e)));return r}return sn(t,e)}function sn(t,e){return t.startsWith("'")&&t.endsWith("'")||t.startsWith('"')&&t.endsWith('"')?t.slice(1,-1):isNaN(Number(t))?le().evaluate(t,e):Number(t)}Ze("currency",(t,e="USD",n="en-US")=>new Intl.NumberFormat(n,{style:"currency",currency:e}).format(t)),Ze("date",(t,e="MM/DD/YYYY")=>{const n=t instanceof Date?t:new Date(t),s=t=>t.toString().padStart(2,"0");return e.replace("YYYY",n.getFullYear().toString()).replace("MM",s(n.getMonth()+1)).replace("DD",s(n.getDate())).replace("HH",s(n.getHours())).replace("mm",s(n.getMinutes())).replace("ss",s(n.getSeconds()))}),Ze("slug",t=>t.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/\s+/g,"-").replace(/-+/g,"-")),Ze("truncate",(t,e=100,n="...")=>t.length>e?t.substring(0,e)+n:t),Ze("uppercase",t=>t.toUpperCase()),Ze("lowercase",t=>t.toLowerCase()),Ze("capitalize",t=>t.charAt(0).toUpperCase()+t.slice(1).toLowerCase()),Ze("fallback",(t,e)=>t||e),Ze("json",(t,e=2)=>JSON.stringify(t,null,e)),Ze("number",(t,e=0)=>t.toFixed(e)),Ze("pluralize",(t,e,n)=>`${t} ${1===t?e:n||e+"s"}`),Ze("percent",(t,e=0)=>(100*t).toFixed(e)+"%"),Ze("join",(t,e=", ")=>Array.isArray(t)?t.join(e):t),Ze("limit",(t,e)=>Array.isArray(t)?t.slice(0,e):t),Ze("reverse",t=>"string"==typeof t?t.split("").reverse().join(""):Array.isArray(t)?[...t].reverse():t);const rn=new Map,an=new Map;function on(t){return rn.get(t)}function cn(){return rn}function ln(t){let e=rn.get(t);e&&(e.__gyos_effects__&&(e.__gyos_effects__.forEach(t=>{try{t()}catch(t){}}),e.__gyos_effects__=null),e.onUnmount&&e.onUnmount.call(e),t.__gyos_scope__=null,rn.delete(t))}function un(t){let e=t;for(;e;){if(e.__gyos_scope__)return e.__gyos_scope__;e=e.parentElement}return null}function hn(t){rn.forEach((e,n)=>{t.contains(n)&&t!==n&&ln(n)})}const pn=[];function fn(){return pn[pn.length-1]}function dn(t,e){const n=Fe(e);t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(n)}function mn(t,e){const n=fn();n?n.push({target:t,runner:e}):dn(t,e)}const gn=new Set(["SCRIPT","STYLE","NOSCRIPT","TEXTAREA","TITLE","XMP","IFRAME","NOEMBED","NOFRAMES"]);function yn(t,e,n){let s=t.parentElement;for(;s;){if(ve(s)||gn.has(s.tagName))return!0;if(s.hasAttribute("*if")||s.hasAttribute("*for"))return!0;if(s.__gyos_static__&&(void 0!==n||s!==e))return!0;if(s===e)break;s=s.parentElement}if(void 0!==n&&t.parentElement){const e=un(t.parentElement);if(e&&e!==n)return!0}return!1}function vn(t,e){const n=document.createTreeWalker(t,NodeFilter.SHOW_TEXT,null),s=[];let r;for(;r=n.nextNode();){if(yn(r,t))continue;const e=r.textContent||"";e.includes("{")&&e.includes("}")&&s.push({node:r,template:e})}s.forEach(({node:t,template:n})=>{t.textContent=en(n,e)})}const xn={classNames:["is-revealed"],rootMargin:"0px",threshold:.1},bn=new Map,_n=new WeakMap;function wn(t){const e=Number(t);return Number.isFinite(e)?Math.min(1,Math.max(0,e)):xn.threshold}function En(t){if(!Array.isArray(t))return wn(t);const e=Array.from(new Set(t.map(wn))).sort((t,e)=>t-e);return e.length?e:xn.threshold}function Sn(t){const e=t.value&&"object"==typeof t.value&&!Array.isArray(t.value)?t.value:{},n=new Set(t.arg||[]);return{classNames:"string"==typeof e.className?e.className.split(/\s+/).filter(Boolean):xn.classNames,once:"boolean"==typeof e.once?e.once:!n.has("repeat"),rootMargin:"string"==typeof e.rootMargin?e.rootMargin:xn.rootMargin,target:"parent"===e.target||n.has("parent")?"parent":"self",threshold:En(e.threshold??xn.threshold)}}function kn(t,e){const{element:n,options:s}=t;if(e){n.setAttribute("data-gyos-revealed","");for(const t of s.classNames)n.classList.add(t)}else{n.removeAttribute("data-gyos-revealed");for(const t of s.classNames)n.classList.remove(t)}}function Cn(t){if(_n.get(t.element)!==t)return;_n.delete(t.element);const e=t.pool.records.get(t.observedTarget);e&&(e.delete(t),0===e.size&&(t.pool.records.delete(t.observedTarget),t.pool.observer.unobserve(t.observedTarget))),0===t.pool.records.size&&(t.pool.observer.disconnect(),bn.delete(t.pool.key))}function An(t,e){In(t),document.documentElement.classList.add("gyos-reveal-ready");const n=Sn(e);if(n.once&&t.hasAttribute("data-gyos-revealed")){for(const e of n.classNames)t.classList.add(e);return}if("function"==typeof window.matchMedia&&window.matchMedia("(prefers-reduced-motion: reduce)").matches||"function"!=typeof window.IntersectionObserver)return void kn({element:t,options:n},!0);const s=function(t){const e=function(t){return JSON.stringify([t.rootMargin,t.threshold])}(t),n=bn.get(e);if(n)return n;let s;try{const n=new Map;s={key:e,observer:new IntersectionObserver(t=>{for(const e of t){const t=Array.from(n.get(e.target)||[]);for(const n of t)e.isIntersecting?(kn(n,!0),n.options.once&&Cn(n)):n.options.once||kn(n,!1)}},{rootMargin:t.rootMargin,threshold:t.threshold}),records:n}}catch{return null}return bn.set(e,s),s}(n);if(!s)return void kn({element:t,options:n},!0);const r="parent"===n.target&&t.parentElement||t,i={element:t,observedTarget:r,options:n,pool:s};let a=s.records.get(r);a||(a=new Set,s.records.set(r,a),s.observer.observe(r)),a.add(i),_n.set(t,i)}function In(t){const e=_n.get(t);e&&(Cn(e),e.options.once||kn(e,!1))}const Tn={mounted:An,updated(t,e){const n=Sn({...e,value:e.oldValue}),s=Sn(e);for(const e of n.classNames)s.classNames.includes(e)||t.classList.remove(e);An(t,e)},unmounted:In},Pn=new Map;function Nn(t,e){"function"==typeof e?Pn.set(t,{mounted:e,updated:e}):Pn.set(t,e)}function Ln(t,e,n,s){const r=Pn.get(e);if(!r)return()=>{};const i={value:n,oldValue:void 0,arg:s};return r.mounted&&r.mounted(t,i),()=>{r.unmounted&&r.unmounted(t)}}function Mn(t,e){const n=t.trim().replace(/[\u0000-\u0020]+/g,"").toLowerCase();return!n.startsWith("javascript:")&&!n.startsWith("vbscript:")&&(!n.startsWith("data:")||e&&/^data:image\/(?:png|gif|jpe?g|webp|avif);base64,/i.test(n))}Nn("cloak",{mounted(t,e){setTimeout(()=>t.removeAttribute("g-cloak"),e.value?e.value:0)}}),Nn("focus",{mounted(t){t.focus()}}),Nn("tooltip",{mounted(t,e){t.title=e.value},updated(t,e){t.title=e.value}}),Nn("on",{mounted(t,e){const n=e.arg?e.arg[0]:void 0;if(!n)return;const s=un(t),r=e.value,i="function"==typeof r?r:s?.[r];if("function"!=typeof i)return;if(!s)return;const a=s.$on(n,i.bind(s));t.__gyos_effects__=t.__gyos_effects__||[],t.__gyos_effects__.push(a)}}),Nn("markdown",{updated(t,e){const n=((e.value||"")+"").replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'").replace(/^### (.*$)/gim,"<h3>$1</h3>").replace(/^## (.*$)/gim,"<h2>$1</h2>").replace(/^# (.*$)/gim,"<h1>$1</h1>").replace(/^\> (.*$)/gim,"<blockquote>$1</blockquote>").replace(/^- (.*$)/gim,"<li>$1</li>").replace(/\*\*(.*)\*\*/gim,"<b>$1</b>").replace(/\*(.*)\*/gim,"<i>$1</i>").replace(/!\[(.*?)\]\((.*?)\)/gim,(t,e,n)=>Mn(n,!0)?`<img alt="${e}" src="${n}" />`:e).replace(/\[(.*?)\]\((.*?)\)/gim,(t,e,n)=>Mn(n,!1)?`<a href="${n}">${e}</a>`:e).replace(/`(.*)`/gim,"<code>$1</code>").replace(/\n/gim,"<br />");t.innerHTML=n}}),Nn("reveal",Tn);const Vn={fade:{enterFrom:"gyos-t-opacity-0",enterTo:"gyos-t-opacity-100",leaveFrom:"gyos-t-opacity-100",leaveTo:"gyos-t-opacity-0",duration:250},"slide-down":{enterFrom:"gyos-t-translate-y--100 gyos-t-opacity-0",enterTo:"gyos-t-translate-y-0 gyos-t-opacity-100",leaveFrom:"gyos-t-translate-y-0 gyos-t-opacity-100",leaveTo:"gyos-t-translate-y-100 gyos-t-opacity-0",duration:250},"slide-up":{enterFrom:"gyos-t-translate-y-100 gyos-t-opacity-0",enterTo:"gyos-t-translate-y-0 gyos-t-opacity-100",leaveFrom:"gyos-t-translate-y-0 gyos-t-opacity-100",leaveTo:"gyos-t-translate-y--100 gyos-t-opacity-0",duration:250},"slide-left":{enterFrom:"gyos-t-translate-x-100 gyos-t-opacity-0",enterTo:"gyos-t-translate-x-0 gyos-t-opacity-100",leaveFrom:"gyos-t-translate-x-0 gyos-t-opacity-100",leaveTo:"gyos-t-translate-x--100 gyos-t-opacity-0",duration:250},"slide-right":{enterFrom:"gyos-t-translate-x--100 gyos-t-opacity-0",enterTo:"gyos-t-translate-x-0 gyos-t-opacity-100",leaveFrom:"gyos-t-translate-x-0 gyos-t-opacity-100",leaveTo:"gyos-t-translate-x-100 gyos-t-opacity-0",duration:250},scale:{enterFrom:"gyos-t-scale-50 gyos-t-opacity-0",enterTo:"gyos-t-scale-100 gyos-t-opacity-100",leaveFrom:"gyos-t-scale-100 gyos-t-opacity-100",leaveTo:"gyos-t-scale-50 gyos-t-opacity-0",duration:250},zoom:{enterFrom:"gyos-t-scale-0 gyos-t-opacity-0",enterTo:"gyos-t-scale-100 gyos-t-opacity-100",leaveFrom:"gyos-t-scale-100 gyos-t-opacity-100",leaveTo:"gyos-t-scale-0 gyos-t-opacity-0",duration:250}};function On(t,e){Vn[t]=e}const Rn=new class{constructor(){this.active=new WeakMap}cancel(t){this.active.get(t)?.cancel()}enter(t,e,n=!1){return t.isConnected&&("leave"!==this.active.get(t)?.phase||n)?this.run(t,e,"enter",!1):Promise.resolve(!1)}leave(t,e,n=!0){return this.run(t,e,"leave",n)}run(t,e,n,s){this.cancel(t);const r="enter"===n?e.enterFrom:e.leaveFrom,i="enter"===n?e.enterTo:e.leaveTo,a="enter"===n?e.enter:e.leave,o="enter"===n?e.onBeforeEnter:e.onBeforeLeave,c="enter"===n?e.onAfterEnter:e.onAfterLeave,l="function"==typeof matchMedia&&matchMedia("(prefers-reduced-motion: reduce)").matches?0:e.duration??250,u=t.style.transition,h=t.style.animation;return new Promise(e=>{let p,f=!1;const d=()=>{r&&this.removeClasses(t,r),i&&this.removeClasses(t,i),t.style.transition=u,t.style.animation=h,t.removeEventListener("transitionend",g),t.removeEventListener("animationend",g),void 0!==p&&clearTimeout(p),this.active.delete(t)},m=r=>{f||(f=!0,d(),r||(c?.(t),"leave"===n&&s&&t.remove()),e(!r))},g=e=>{e.target===t&&m(!1)};this.active.set(t,{phase:n,cancel:()=>m(!0)});try{o?.(t),r&&this.applyClasses(t,r),t.offsetHeight,t.style.transition=`all ${l}ms ${"enter"===n?"ease-out":"ease-in"}`,r&&this.removeClasses(t,r),i&&this.applyClasses(t,i),a&&(t.style.animation=a),0===l?queueMicrotask(()=>m(!1)):(t.addEventListener("transitionend",g),t.addEventListener("animationend",g),p=setTimeout(()=>m(!1),l+50))}catch(t){m(!1)}})}applyClasses(t,e){e.split(" ").forEach(e=>{e&&t.classList.add(e)})}removeClasses(t,e){e.split(" ").forEach(e=>{e&&t.classList.remove(e)})}getConfig(t){return"object"==typeof t?t:Vn[t]||Vn.fade}getAvailableTransitions(){return Object.keys(Vn)}};function Dn(t){if("string"==typeof t)return Vn[t]||null;const e=Array.from(t.attributes).find(t=>"g-transition"===t.name||t.name.startsWith("g-transition."));if(!e)return null;const n=e.value;try{return JSON.parse(n)}catch{const t=Vn[n];if(!t)return Vn.fade;if(e.name.startsWith("g-transition.")){const n=e.name.match(/g-transition\.(\d+)/);if(n)return{...t,duration:parseInt(n[1],10)}}return t}}function Fn(){if("undefined"==typeof document)return;if("csp"===ue())return;const t="gyos-transitions";if(document.getElementById(t))return;const e=document.createElement("style");e.id=t,e.textContent="\n /* Opacity utilities */\n .gyos-t-opacity-0 { opacity: 0; }\n .gyos-t-opacity-100 { opacity: 1; }\n \n /* Transform - Translate Y */\n .gyos-t-translate-y-0 { transform: translateY(0); }\n .gyos-t-translate-y--100 { transform: translateY(-100%); }\n .gyos-t-translate-y-100 { transform: translateY(100%); }\n \n /* Transform - Translate X */\n .gyos-t-translate-x-0 { transform: translateX(0); }\n .gyos-t-translate-x--100 { transform: translateX(-100%); }\n .gyos-t-translate-x-100 { transform: translateX(100%); }\n \n /* Transform - Scale */\n .gyos-t-scale-0 { transform: scale(0); }\n .gyos-t-scale-50 { transform: scale(0.5); }\n .gyos-t-scale-100 { transform: scale(1); }\n \n /* Animation Keyframes */\n @keyframes gyos-fade-in {\n\t\tfrom { opacity: 0; }\n\t\tto { opacity: 1; }\n }\n \n @keyframes gyos-fade-out {\n\t\tfrom { opacity: 1; }\n\t\tto { opacity: 0; }\n }\n \n @keyframes gyos-slide-down {\n\t\tfrom { transform: translateY(-100%); opacity: 0; }\n\t\tto { transform: translateY(0); opacity: 1; }\n }\n \n @keyframes gyos-slide-up {\n\t\tfrom { transform: translateY(100%); opacity: 0; }\n\t\tto { transform: translateY(0); opacity: 1; }\n }\n \n @keyframes gyos-scale-in {\n\t\tfrom { transform: scale(0); opacity: 0; }\n\t\tto { transform: scale(1); opacity: 1; }\n }\n \n @keyframes gyos-scale-out {\n\t\tfrom { transform: scale(1); opacity: 1; }\n\t\tto { transform: scale(0); opacity: 0; }\n }\n\n [g-cloak] {\n\t\tdisplay: none !important;\n }",document.head.appendChild(e)}function Bn(t,e){const n=Array.from(t.attributes).find(t=>t.name.startsWith("g-transition"));if(!n)return null;const s=n.name.split(".").slice(1).find(t=>/^\d+$/.test(t)),r=function(t,e){if(t.includes("{")&&t.includes("}")){const n=t.match(/\{([^}]+)\}/);if(n)return nn(n[1].trim(),e)}try{const n=nn(t,e);if(null!=n)return n}catch(t){}return t}(n.value,e);return{name:r,duration:s?parseInt(s):void 0}}function Un(t){if(ve(t))return[];const e=[];Array.from(t.attributes).some(t=>t.name.startsWith("g-transition"))&&e.push(t);const n=Ee(t,t=>!ve(t),NodeFilter.FILTER_REJECT).filter(t=>Array.from(t.attributes).some(t=>t.name.startsWith("g-transition")));return e.push(...n),e}function jn(t,e,n=!1){const s=Bn(t,e);if(!s)return Promise.resolve(!0);_e();const r={...Rn.getConfig(s.name)};return s.duration&&(r.duration=s.duration),Rn.enter(t,r,n)}function Wn(t,e,n=!0){const s=Bn(t,e);if(!s)return Promise.resolve(!0);_e();const r={...Rn.getConfig(s.name)};return s.duration&&(r.duration=s.duration),Rn.leave(t,r,n)}function $n(t,e){Array.from(t.querySelectorAll("[g-show], [g-html], [g-text]")).filter(t=>!ve(t)).forEach(t=>{const n=t;if(n.hasAttribute("g-show")){const t=nn(n.getAttribute("g-show"),e);n.style.display=t?"":"none"}if(n.hasAttribute("g-html")){const t=nn(n.getAttribute("g-html"),e);n.innerHTML=t}if(n.hasAttribute("g-text")){const t=nn(n.getAttribute("g-text"),e);n.textContent=t}})}function qn(t){return{staticClasses:new Set(t.classList),dynamicClasses:new Set}}function Hn(t,e,n){const s=function(t){return"string"==typeof t?new Set(t.split(/\s+/).filter(Boolean)):t&&"object"==typeof t?new Set(Object.entries(t).filter(([,t])=>!!t).flatMap(([t])=>t.split(/\s+/).filter(Boolean))):new Set}(e);if(e&&"object"==typeof e)for(const[n,s]of Object.entries(e))if(!s)for(const e of n.split(/\s+/).filter(Boolean))t.classList.remove(e);for(const e of n.dynamicClasses)s.has(e)||n.staticClasses.has(e)||t.classList.remove(e);for(const e of s)t.classList.add(e);n.dynamicClasses=s}function Gn(t){const e=new Map;for(let n=0;n<t.length;n++){const s=t.item(n);e.set(s,{priority:t.getPropertyPriority(s),value:t.getPropertyValue(s)})}return e}function zn(t){return t.startsWith("--")||t.includes("-")?t.toLowerCase():t.replace(/[A-Z]/g,t=>"-"+t.toLowerCase())}function Yn(t){return{staticStyles:Gn(t.style),dynamicProperties:new Set}}function Kn(t,e,n){const s=n.staticStyles.get(e);s?t.style.setProperty(e,s.value,s.priority):t.style.removeProperty(e)}function Jn(t,e,n){const s=function(t){const e=document.createElement("div").style,n=new Set;if("string"==typeof t){e.cssText=t;for(const t of Gn(e).keys())n.add(t)}else if(t&&"object"==typeof t)for(const[s,r]of Object.entries(t)){const t=zn(s);n.add(t),null!=r&&!1!==r&&(s.startsWith("--")?e.setProperty(s,r+""):e[s]=r)}return{mentioned:n,values:Gn(e)}}(e);for(const e of n.dynamicProperties)s.mentioned.has(e)||Kn(t,e,n);for(const e of s.mentioned){const n=s.values.get(e);n?t.style.setProperty(e,n.value,n.priority):t.style.removeProperty(e)}n.dynamicProperties=s.mentioned}const Qn=new Set(["allowfullscreen","async","autofocus","autoplay","checked","controls","defer","disabled","formnovalidate","hidden","inert","ismap","itemscope","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","selected"]),Xn={allowfullscreen:"allowFullscreen",formnovalidate:"formNoValidate",ismap:"isMap",itemscope:"itemScope",nomodule:"noModule",novalidate:"noValidate",playsinline:"playsInline",readonly:"readOnly"},Zn=new Set(["action","background","cite","formaction","href","poster","src","xlink:href"]),ts=new Set(["BASE","EMBED","IFRAME","LINK","OBJECT","SCRIPT"]);function es(t,e,n){const s=e.toLowerCase();if(!function(t){const e=t.toLowerCase();return!(!e||e.startsWith("@")||e.startsWith(":")||e.startsWith("*")||/^on/i.test(e)||"srcdoc"===e||"xmlns"===e||e.startsWith("g-")||e.startsWith("gd-")||e.startsWith("gm-"))}(s))return t.removeAttribute(s),void _e();if(!function(t,e,n){if(!Zn.has(e))return!("data"===e&&"OBJECT"===t.tagName);if(null==n||!1===n)return!0;if(ts.has(t.tagName))return!1;const s=(n+"").trim().replace(/[\u0000-\u0020]+/g,"").toLowerCase();return!s.startsWith("javascript:")&&!s.startsWith("vbscript:")&&(!s.startsWith("data:")||"src"===e&&t instanceof HTMLImageElement&&/^data:image\/(?:png|gif|jpe?g|webp|avif);base64,/i.test(s))}(t,s,n))return t.removeAttribute(s),void _e();if(Qn.has(s)){const e=!!n;return t.toggleAttribute(s,e),void function(t,e,n){const s=Xn[e]||e;if(s in t)try{t[s]=n}catch{}}(t,s,e)}if(null==n||!1===n&&!s.startsWith("aria-")&&!s.startsWith("data-"))return void t.removeAttribute(s);const r=n+"";"value"===s&&"value"in t&&(t.value=r),t.setAttribute(s,r)}function ns(t){return Array.from(t.attributes).filter(t=>t.name.startsWith(":"))}function ss(t,e){const n=[t,...Ee(t,t=>!ve(t),NodeFilter.FILTER_REJECT)];for(const t of n)if(!ve(t))for(const n of ns(t)){const s=n.name.slice(1),r=nn(n.value,e);"class"===s?Hn(t,r,qn(t)):"style"===s?Jn(t,r,Yn(t)):es(t,s,r)}}function rs(t,e){if(!t)return;const n=document.querySelector(e);if(!n)return;const s=document.createComment("g-portal");t.parentNode?.insertBefore(s,t),t.__portal_placeholder__=s,t.__portal_target__=n,n.appendChild(t),_e()}function is(t){if(!t)return;const e=t.__portal_placeholder__;e&&e.parentNode&&(e.parentNode.insertBefore(t,e),e.remove(),delete t.__portal_placeholder__,delete t.__portal_target__,_e())}const as=new Map;function os(t,e){as.set(t,e)}function cs(t){return as.get(t)}function ls(){return Array.from(as.keys())}async function us(t,e,n){const s=e.split("|");for(const e of s){const s=e.lastIndexOf(":");let r,i=e;if(s>0){const t=e.substring(0,s),n=t.indexOf("("),a=t.lastIndexOf(")");(-1===n||a>n&&a===t.length-1)&&(i=t,r=e.substring(s+1).trim())}const a=i.match(/^(\w+)(?:\((.*?)\))?$/);if(!a)continue;const[,o,c]=a,l=c?c.split(",").map(t=>t.trim().replace(/['"]/g,"")):[],u=as.get(o);if(!u)continue;const h=await u(t,...l,n);if(!0!==h)return r||(n?.messages?.[o]?n.messages[o]:"string"==typeof h?h:"Validation failed for "+o)}return null}os("required",t=>!(null==t||""===t||Array.isArray(t)&&0===t.length)||"This field is required"),os("email",t=>!t||/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t)||"Invalid email address"),os("minLength",(t,e)=>{if(!t)return!0;const n=parseInt(e);return t.length>=n||"Minimum length is "+n}),os("maxLength",(t,e)=>{if(!t)return!0;const n=parseInt(e);return t.length<=n||"Maximum length is "+n}),os("min",(t,e)=>{if(!t)return!0;const n=parseFloat(e);return parseFloat(t)>=n||"Minimum value is "+n}),os("max",(t,e)=>{if(!t)return!0;const n=parseFloat(e);return n>=parseFloat(t)||"Maximum value is "+n}),os("number",t=>!t||!isNaN(parseFloat(t))&&isFinite(t)||"Must be a number"),os("integer",t=>!t||Number.isInteger(parseFloat(t))||"Must be an integer"),os("numeric",t=>!t||/^\d+$/.test(t)||"Must contain only digits"),os("alpha",t=>!t||/^[a-zA-Z]+$/.test(t)||"Must contain only letters"),os("alphanumeric",t=>!t||/^[a-zA-Z0-9]+$/.test(t)||"Must contain only letters and numbers"),os("pattern",(t,e)=>!t||RegExp(e).test(t)||"Invalid format"),os("same",(t,e,n)=>!t||!n?.form||t===n.form[e]||"Must match "+e),os("different",(t,e,n)=>!t||!n?.form||t!==n.form[e]||"Must be different from "+e),os("url",t=>{if(!t)return!0;try{return new URL(t),!0}catch{return"Invalid URL"}}),os("phone",t=>!t||/^0\d{9}$/.test(t)||"Invalid phone number (format: 0xxxxxxxxx)"),os("date",t=>!t||(/^\d{4}-\d{2}-\d{2}$/.test(t)?!isNaN(new Date(t).getTime())||"Invalid date":"Invalid date format (use YYYY-MM-DD)")),os("before",(t,e)=>{if(!t)return!0;const n=new Date(t);return new Date(e)>n||"Must be before "+e}),os("after",(t,e)=>!t||new Date(t)>new Date(e)||"Must be after "+e),os("password",t=>{if(!t)return!0;if(8>t.length)return"Password must be at least 8 characters";const e=/[A-Z]/.test(t),n=/[a-z]/.test(t),s=/[0-9]/.test(t);return e?n?!!s||"Password must contain at least one number":"Password must contain at least one lowercase letter":"Password must contain at least one uppercase letter"}),os("in",(t,...e)=>{if(!t)return!0;const n=e.filter(t=>"string"==typeof t||"number"==typeof t);return n.includes(t)||"Must be one of: "+n.join(", ")}),os("notIn",(t,...e)=>{if(!t)return!0;const n=e.filter(t=>"string"==typeof t||"number"==typeof t);return!n.includes(t)||"Cannot be: "+n.join(", ")}),os("between",(t,e,n)=>{if(!t)return!0;const s=parseFloat(t),r=parseFloat(e),i=parseFloat(n);return s>=r&&i>=s||`Must be between ${r} and ${i}`});const hs=new WeakSet,ps=new WeakSet,fs=new WeakMap,ds=new WeakMap,ms=Symbol("gyos.validation-field");function gs(t){const e=t[ms];if(e)return e;const n=Array.from(t.attributes).find(t=>"g-model"===t.name||t.name.startsWith("g-model."));return n?.value||t.getAttribute("name")||t.id}function ys(t,e){if(!(t instanceof HTMLInputElement))return t.value;if("checkbox"===t.type)return t.checked?t.value:"";if("radio"!==t.type)return t.value;const n=gs(t),s=Array.from(e.querySelectorAll('input[type="radio"]')).find(e=>!(ve(e)||!e.checked||(!t.name||e.name!==t.name)&&gs(e)!==n));return s?.value??""}function vs(t){return fs.has(t)||fs.set(t,{errors:Re({}),touched:Re({}),$invalid:Re(!1),$valid:Re(!0),$dirty:Re(!1),$pristine:Re(!0)}),fs.get(t)}function xs(t){const e=t.errors.value,n=t.touched.value,s=Object.values(e).some(t=>null!==t),r=Object.values(n).some(t=>t);t.$invalid.value!==s&&(t.$invalid.value=s,t.$valid.value=!s),t.$dirty.value!==r&&(t.$dirty.value=r,t.$pristine.value=!r)}const bs={enter:"enter",esc:"escape",escape:"escape",space:" ",up:"arrowup",down:"arrowdown",left:"arrowleft",right:"arrowright",delete:"delete",tab:"tab"},_s=new Set(["prevent","stop","once","capture","passive","debounce","outside","global"]);function ws(t,e,n,s){s.includes("prevent")&&n.preventDefault(),s.includes("stop")&&n.stopPropagation();try{le().execute(t,e,n)}catch(t){}}const Es=Symbol("gyos.parent-scope");function Ss(t){return t?.[Es]}function ks(t){const e=[],n=/[^.[\]]+|\[(\d+)\]/g;let s;for(;s=n.exec(t);)void 0!==s[1]?e.push(Number(s[1])):e.push(s[0]);return e}function Cs(t,e,n){if(be(e))return;const s=ks(e);if(0===s.length)return;let r=t;Ue(r)&&(r=r.value);for(let t=0;t<s.length-1;t++){let e=r[s[t]];Ue(e)&&(e=e.value),r=e}const i=s[s.length-1],a=r[i];Ue(a)?a.value=n:r[i]=n}function As(t=document.body,e=!1){t&&((t.hasAttribute?.("g-scope")||t.__gyos_scope__)&&ln(t),t.__gyos_effects__&&(t.__gyos_effects__.forEach(t=>{try{t()}catch(t){}}),t.__gyos_effects__=null),t.querySelectorAll("*").forEach(t=>{(t.hasAttribute?.("g-scope")||t.__gyos_scope__)&&ln(t),t.__gyos_effects__&&(t.__gyos_effects__.forEach(t=>{try{t()}catch(t){}}),t.__gyos_effects__=null)}),is(t),e&&t.remove())}const Is=new WeakMap,Ts=new WeakSet,Ps=new WeakMap,Ns=new WeakMap,Ls=new WeakMap,Ms=new WeakMap,Vs=Symbol.for("gyos_scope_version");function Os(t){const e=Gs(t),n=new Set,s=t=>{if(n.has(t))return;n.add(t),t.value=t.value+1;const e=Ms.get(t);e&&e.forEach(t=>s(t))};s(e)}function Rs(t){return t instanceof Date||t instanceof RegExp||t instanceof Map||t instanceof Set||t instanceof WeakMap||t instanceof WeakSet||t instanceof Promise}function Ds(t){return"string"==typeof t&&(t.startsWith("__gyos_")||t.startsWith("$")||["onMount","onUpdate","onUnmount"].includes(t))}function Fs(t,e,n){let s=Ps.get(t);s||(s=new Map,Ps.set(t,s));let r=s.get(e);return r||(r=Re(n,_e()?`(${e.toString()})`:void 0),s.set(e,r)),r}const Bs=Symbol.for("gyos.store");function Us(t){return!(!t||!t[Bs])}const js=Symbol.for("gyos.raw");function Ws(t){return t.hasOwnProperty(js)||Reflect.defineProperty(t,js,{value:!0,enumerable:!1}),t}function $s(t){return!(!t||!t[js])}const qs=Symbol.for("gyos.shallow");function Hs(t){return t.hasOwnProperty(qs)||Reflect.defineProperty(t,qs,{value:!0,enumerable:!1}),t}function Gs(t){let e=Ns.get(t);return e||(e=Re(0),Ns.set(t,e)),e}function zs(t){if(!t||"object"!=typeof t||Rs(t))return t;if(Ts.has(t))return t;if($s(t))return t;if(Us(t))return t;if(Is.has(t))return Is.get(t);let e;e=new Proxy(t,{get(t,n,s){const r=Reflect.get(t,n,s);if(!Object.prototype.hasOwnProperty.call(t,n)){if("symbol"!=typeof n&&!Ds(n)&&!(n in t)){const e=Ps.get(t)?.get(n);if(je())return(e||Fs(t,n,void 0)).value;if(e)return e.peek}return r}if("symbol"==typeof n||Ds(n))return r;if(Us(r))return r;const i=Object.getOwnPropertyDescriptor(t,n);if(i&&i.get)return r;if("function"==typeof r)return r.bind(e);const a=je(),o=Ps.get(t)?.get(n);if(r&&"object"==typeof r&&$s(r))return a&&(o||Fs(t,n,r)).value,r;if(r&&"object"==typeof r&&!Rs(r)){const e=Ns.get(t);return Ns.has(r)||Gs(r),e&&function(t,e){const n=Gs(t);let s=Ls.get(t);s||(s=new Set,Ls.set(t,s)),s.add(e);let r=Ms.get(n);r||(r=new Set,Ms.set(n,r)),r.add(e)}(r,e),a&&(o||Fs(t,n,r)).value,(c=t)&&c[qs]?r:zs(r)}var c;return a?(o||Fs(t,n,r)).value:o?o.peek:r},set(t,e,n,s){if("symbol"==typeof e||Ds(e))return Reflect.set(t,e,n,s);const r=Object.getOwnPropertyDescriptor(t,e);if(r&&r.set){const r=Reflect.set(t,e,n,s);return r&&Os(t),r}const i=t[e];if(Us(n))return Reflect.set(t,e,n,s);if(!Reflect.set(t,e,n,s))return!1;const a=Fs(t,e,n);return Object.is(i,n)||(a.value=n,Os(t)),!0},ownKeys:t=>(Gs(t).value,Reflect.ownKeys(t).filter(t=>!Ds(t))),getOwnPropertyDescriptor(t,e){if("string"!=typeof e||!Ds(e))return Reflect.getOwnPropertyDescriptor(t,e)},deleteProperty(t,e){if("symbol"==typeof e||Ds(e))return Reflect.deleteProperty(t,e);const n=Object.prototype.hasOwnProperty.call(t,e),s=Reflect.deleteProperty(t,e);return s&&n&&(Fs(t,e,void 0).value=void 0,Os(t)),s},defineProperty(t,e,n){if("symbol"==typeof e||Ds(e))return Reflect.defineProperty(t,e,n);const s=Object.getOwnPropertyDescriptor(t,e),r=s&&"value"in s?s.value:void 0,i="value"in n?n.value:r;return!!Reflect.defineProperty(t,e,n)&&("value"in n&&(Fs(t,e,n.value).value=n.value,s&&Object.is(r,i)||Os(t)),!0)}});const n=Ns.get(t);return n&&Ns.set(e,n),Ts.add(e),Is.set(t,e),e}function Ys(t){const e=Gs(t),n=zs(t);return n.hasOwnProperty(Vs)||Object.defineProperty(n,Vs,{value:e,enumerable:!1,configurable:!1,writable:!1}),n}let Ks=null;const Js=new WeakMap,Qs=Symbol("gyos.for-scope-state");function Xs(t){return Js.has(t)||Js.set(t,t.cloneNode(!0)),Js.get(t).cloneNode(!0)}function Zs(t,e){t.__gyos_scope__=e}function tr(t,e,n,s){const r={};!function(t,e){Object.defineProperty(t,Es,{value:e,configurable:!1,enumerable:!1,writable:!1})}(r,t);const i=Re({list:n,index:s});Object.defineProperty(r,Qs,{value:i});const[a,o]=e.split(",").map(t=>t.trim());o?Object.defineProperty(r,o,{get:()=>i.value.index,enumerable:!1,configurable:!1}):Object.defineProperty(r,"$index",{get:()=>i.value.index,enumerable:!0,configurable:!1}),Object.defineProperty(r,a,{get:()=>{const t=i.value;return t.list[t.index]},set:t=>{const e=i.peek;e.list[e.index]=t},enumerable:!0,configurable:!1});for(const e in t)e in r||Object.defineProperty(r,e,{get:()=>t[e],set:n=>{t[e]=n},enumerable:!0,configurable:!0});return r}let er=null;Ks=sr;const nr=(t,e)=>{const n=un(t);return!(!n||n===e)};function sr(t,e,n=!1){if(ve(t))return;pn.push([]);const s=[t,...Ee(t,t=>!ve(t),NodeFilter.FILTER_REJECT)];if(n&&er&&t.querySelectorAll("[g-scope]").forEach(t=>{ve(t)||ke(t)||er(t)}),function(t,e){const n=[],s=t[0];t.forEach(t=>{const e=t.hasAttribute("*if"),r=t.hasAttribute("*for"),i=t.hasAttribute("*switch"),a=t.hasAttribute("*await");if(e||r||i||a){let e=0,o=t;for(;o&&o!==s;)e++,o=o.parentNode;let c="if";r?c="for":i?c="switch":a&&(c="await"),n.push({element:t,type:c,depth:e})}}),n.sort((t,e)=>t.depth-e.depth),n.forEach(({element:t,type:n})=>{"for"===n?function(t,e){const n=t.getAttribute("*for"),s=t.cloneNode(!0);s.removeAttribute("*for");const r=s.getAttribute("g-key"),i=!!r;i&&s.removeAttribute("g-key");const a=document.createComment("*for");t.parentNode?.replaceChild(a,t);let o,c=new Map,l=null;mn(t,()=>{const t=n.match(/(.+?)\s+in\s+(.+)/);if(!t)return;const u=t[1].trim(),h=nn(t[2].trim(),e,!1);if(!Array.isArray(h))return;const p=(f=h,Ns.get(f));var f;const d=p?p.value:void 0;(i||h!==l||d!==o)&&(l=h,o=d,qe(()=>{i?function(t,e,n,s,r,i,a){const o=new Map,c=[];n.forEach((t,e)=>{const a=tr(i,s,n,e),l=nn(r,a,!1);o.set(l,{index:e}),c.push(l)});const l=[];a.forEach((t,e)=>{o.has(e)||l.push({key:e,data:t})}),l.forEach(({key:t,data:e})=>{a.delete(t);const n=Un(e.element);if(hn(e.element),n.length>0){e.element.style.pointerEvents="none";const t=n.map(t=>Wn(t,e.scope));Promise.all(t).then(()=>{As(e.element,!0)})}else As(e.element,!0)});let u=t;c.forEach(r=>{const c=o.get(r),{index:l}=c;let h;if(a.has(r)){const t=a.get(r),e=t.scope[Qs],s=e.peek;s.list===n&&s.index===l||(e.value={list:n,index:l}),h=t.element}else{const o=Xs(e),c=tr(i,s,n,l);Zs(o,c);const p=Un(o);p.length>0&&p.forEach(t=>{const e=Bn(t,c);if(e){const n=Rn.getConfig(e.name);n.enterFrom&&n.enterFrom.split(/\s+/).forEach(e=>{e&&t.classList.add(e)})}}),h=o,t.parentNode?.insertBefore(o,u.nextSibling),Ks&&Ks(o,c,!0),a.set(r,{element:o,scope:c}),p.length>0&&requestAnimationFrame(()=>{p.forEach(t=>jn(t,c))})}h!==u.nextSibling&&t.parentNode?.insertBefore(h,u.nextSibling),u=h})}(a,s,h,u,r,e,c):function(t,e,n,s,r){let i=t.nextSibling;for(;i&&i.nodeType!==Node.COMMENT_NODE;){const t=i;i=i.nextSibling,t instanceof Element&&(hn(t),As(t,!0))}let a=t;n.forEach((i,o)=>{const c=Xs(e),l=tr(r,s,n,o);Zs(c,l);const u=Un(c);u.length>0&&u.forEach(t=>{const e=Bn(t,l);if(e){const n=Rn.getConfig(e.name);n.enterFrom&&n.enterFrom.split(/\s+/).forEach(e=>{e&&t.classList.add(e)})}}),t.parentNode?.insertBefore(c,a.nextSibling),a=c,Ks&&Ks(c,l,!0),u.length>0&&requestAnimationFrame(()=>{u.forEach(t=>jn(t,l))})})}(a,s,h,u,e)}))})}(t,e):"if"===n?function(t,e){const n=[];n.push({element:t,condition:t.getAttribute("*if")});let s=t.nextElementSibling;for(;s&&!ve(s);){if(!s.hasAttribute("*elseif")){if(s.hasAttribute("*else")){n.push({element:s,condition:null}),s.remove();break}break}{n.push({element:s,condition:s.getAttribute("*elseif")});const t=s.nextElementSibling;s.remove(),s=t}}const r=n.map(({element:t,condition:e})=>{const n=t.cloneNode(!0);return n.removeAttribute("*if"),n.removeAttribute("*elseif"),n.removeAttribute("*else"),{template:n,condition:e}}),i=document.createComment("*if-chain");t.parentNode?.replaceChild(i,t);let a=null,o=-1;mn(t,()=>{let t=-1;for(let n=0;n<r.length;n++){const{condition:s}=r[n];if(null===s){t=n;break}if(nn(s,e,!1)){t=n;break}}if(t!==o){if(a){const t=a;hn(t),a=null;const n=Un(t);if(n.length>0){t.style.pointerEvents="none";const s=n.map(t=>Wn(t,e));Promise.all(s).then(()=>{As(t,!0)})}else As(t,!0)}if(-1!==t){const{template:n}=r[t];a=Xs(n),o=t,Zs(a,e);const s=Un(a);s.length>0&&s.forEach(t=>{const n=Bn(t,e);if(n){const e=Rn.getConfig(n.name);e.enterFrom&&e.enterFrom.split(/\s+/).forEach(e=>{e&&t.classList.add(e)})}}),i.parentNode?.insertBefore(a,i.nextSibling),Ks&&Ks(a,e,!0),s.length>0&&requestAnimationFrame(()=>{s.forEach(t=>jn(t,e))})}else o=-1}})}(t,e):"switch"===n?function(t,e){const n=t.getAttribute("*switch"),s=[];Array.from(t.children).forEach(t=>{ve(t)||(t.hasAttribute("*case")?s.push({element:t,value:t.getAttribute("*case")}):t.hasAttribute("*default")&&s.push({element:t,value:null}))});const r=s.map(({element:t,value:e})=>{const n=t.cloneNode(!0);return n.removeAttribute("*case"),n.removeAttribute("*default"),t.remove(),{template:n,value:e}});t.removeAttribute("*switch");const i=document.createComment("*switch-content");t.appendChild(i);let a=null,o=-1;mn(t,()=>{const t=nn(n,e,!1);let s=-1;for(let n=0;n<r.length;n++){const{value:i}=r[n];if(null===i){-1===s&&(s=n);break}if(t===nn(i,e,!1)){s=n;break}}if(s!==o){if(a){const t=a;hn(t),a=null;const n=Un(t);if(n.length>0){t.style.pointerEvents="none";const s=n.map(t=>Wn(t,e));Promise.all(s).then(()=>{As(t,!0)})}else As(t,!0)}if(-1!==s){const{template:t}=r[s];a=Xs(t),o=s,Zs(a,e);const n=Un(a);n.length>0&&n.forEach(t=>{const n=Bn(t,e);if(n){const e=Rn.getConfig(n.name);e.enterFrom&&e.enterFrom.split(/\s+/).forEach(e=>{e&&t.classList.add(e)})}}),i.parentNode?.insertBefore(a,i.nextSibling),Ks&&Ks(a,e,!0),n.length>0&&requestAnimationFrame(()=>{n.forEach(t=>jn(t,e))})}else o=-1}})}(t,e):"await"===n&&function(t,e){const n=t.getAttribute("*await");t.removeAttribute("*await");const s=Array.from(t.children);let r=null,i=null,a=null;s.forEach(t=>{if(!ve(t))if(t.hasAttribute("*pending"))r=t.cloneNode(!0),r.removeAttribute("*pending"),t.remove();else if(t.hasAttribute("*then")){const e=t.getAttribute("*then")||null;i={template:t.cloneNode(!0),varName:e},i.template.removeAttribute("*then"),t.remove()}else if(t.hasAttribute("*catch")){const e=t.getAttribute("*catch")||null;a={template:t.cloneNode(!0),varName:e},a.template.removeAttribute("*catch"),t.remove()}});const o=document.createComment("*await");t.appendChild(o);let c=null,l="pending",u=0;const h=(t,n)=>{if(c){const t=c;c=null;const n=Un(t);if(n.length>0){t.style.pointerEvents="none";const s=n.map(t=>Wn(t,e));Promise.all(s).then(()=>{As(t,!0)})}else As(t,!0)}let s=null,u=e;if("pending"===t&&r?s=r:"fulfilled"===t&&i?(s=i.template,i.varName&&void 0!==n&&(u={...e,[i.varName]:n})):"rejected"===t&&a&&(s=a.template,a.varName&&void 0!==n&&(u={...e,[a.varName]:n})),s){c=Xs(s),l=t,Zs(c,u);const e=Un(c);e.length>0&&e.forEach(t=>{const e=Bn(t,u);if(e){const n=Rn.getConfig(e.name);n.enterFrom&&n.enterFrom.split(/\s+/).forEach(e=>{e&&t.classList.add(e)})}}),o.parentNode?.insertBefore(c,o.nextSibling),Ks&&Ks(c,u,!0),e.length>0&&requestAnimationFrame(()=>{e.forEach(t=>jn(t,u))})}};h("pending"),mn(t,()=>{const t=nn(n,e,!1),s=++u;t instanceof Promise?(h("pending"),t.then(t=>{s===u&&"pending"===l&&h("fulfilled",t)}).catch(t=>{s===u&&"pending"===l&&h("rejected",t)})):h("fulfilled",t)})}(t,e)})}(s,e),s.forEach(s=>{if(!document.body.contains(s))return;if(0===s.attributes.length)return;if(nr(s,e)&&!n)return;const r=Array.from(s.attributes);s.hasAttribute("g-static")&&function(t,e){t.removeAttribute("g-static"),t.__gyos_static__=!0,vn(t,e),$n(t,e),ss(t,e)}(s,e),s.hasAttribute("g-form")&&function(t,e){t instanceof HTMLFormElement&&t.hasAttribute("g-form")&&function(t,e){const n=t.getAttribute("g-form");if(!n||be(n))return;t.removeAttribute("g-form");const s=vs(t);!function(t){hs.add(t)}(t);const r=async()=>{const e=ds.get(t)||[],n={...s.touched.value};return Object.keys(n).forEach(t=>{n[t]=!0}),s.touched.value={...n},await Promise.all(e.map(t=>t())),xs(s),!s.$invalid.value};s.validateAll=r;const i={errors:s.errors,touched:s.touched,$invalid:s.$invalid,$valid:s.$valid,$dirty:s.$dirty,$pristine:s.$pristine,validateAll:r};n in e?Object.assign(e[n],i):e[n]=i;let a,o=!1,c=!1,l=!1,u=!0;const h=async n=>{if(o)o=!1;else if(n.preventDefault(),n.stopImmediatePropagation(),!c&&!l){c=!0;try{const s=await r();if(!u||!s)return;const i=t.getAttribute("g-submit");if(!i){const e="undefined"!=typeof SubmitEvent&&n instanceof SubmitEvent&&(n.submitter instanceof HTMLButtonElement||n.submitter instanceof HTMLInputElement)?n.submitter:void 0;return l=!0,void(a=setTimeout(()=>{if(l=!1,a=void 0,u){!function(t){ps.add(t)}(t),o=!0;try{t.requestSubmit(e)}finally{o&&(o=!1),function(t){ps.delete(t)}(t)}}},0))}const c=e[i];"function"==typeof c&&c.call(e)}finally{c=!1}}};t.addEventListener("submit",h,!0),t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(()=>{u=!1,void 0!==a&&clearTimeout(a),l=!1,t.removeEventListener("submit",h,!0),function(t){hs.delete(t),ps.delete(t)}(t),fs.delete(t),ds.delete(t)})}(t,e),t.querySelectorAll("[g-validate]").forEach(t=>{ve(t)||t instanceof HTMLElement&&function(t){if(!(t instanceof HTMLInputElement||t instanceof HTMLTextAreaElement||t instanceof HTMLSelectElement))return;const e=t.getAttribute("g-validate");if(!e)return;t.removeAttribute("g-validate");const n=gs(t);if(!n)return;t[ms]=n;const s=t.closest("form");if(!s)return;const r=vs(s);r.errors.value[n]=null,r.touched.value[n]=!1;const i=async()=>{const i=ys(t,s),a={};s.querySelectorAll("input, textarea, select").forEach(t=>{if(!ve(t)&&(t instanceof HTMLInputElement||t instanceof HTMLTextAreaElement||t instanceof HTMLSelectElement)){const e=gs(t);e&&(a[e]=ys(t,s))}});const o=await us(i,e,{form:a,field:n}),c=r.errors.value;c[n]!==o&&(c[n]=o,r.errors.value={...c},xs(r))};ds.has(s)||ds.set(s,[]),ds.get(s).push(i);const a=()=>{const t=r.touched.value;t[n]||(t[n]=!0,r.touched.value={...t},xs(r)),i()};let o;t.addEventListener("blur",a);const c=()=>{clearTimeout(o),o=setTimeout(()=>{i()},300)};t.addEventListener("input",c),t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(()=>{t.removeEventListener("blur",a),t.removeEventListener("input",c),clearTimeout(o)})}(t)}),t.querySelectorAll("[g-errors]").forEach(t=>{ve(t)||t instanceof HTMLElement&&function(t){const e=t.getAttribute("g-errors");t.removeAttribute("g-errors");const n=t.closest("form");if(!n)return;const s=vs(n);if(""===e||null===e){const e=Fe(()=>{const e=s.errors.value,n=Object.entries(e).filter(([t,e])=>null!==e);t.replaceChildren(...n.map(([t,e])=>{const n=document.createElement("div"),s=document.createElement("strong");return s.textContent=t+":",n.append(s,document.createTextNode(" "+e)),n})),t.style.display=n.length?"":"none"});t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(e)}else{const n=Fe(()=>{const n=s.errors.value[e];n?(t.textContent=n,t.style.display=""):(t.textContent="",t.style.display="none")});t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(n)}}(t)})}(s,e),r.some(t=>t.name.startsWith("g-")&&!t.name.startsWith("g-portal"))&&function(t,e,n){if(!ve(t)&&!ye(t,n)){if(t.hasAttribute("g-show")){const n=t.getAttribute("g-show"),s="none"===t.style.display?"":t.style.display;let r=!1,i=0;mn(t,()=>{const a=!!nn(n,e),o=++i;return Rn.cancel(t),r?Bn(t,e)?(a?(t.style.display=s,jn(t,e,!0)):"none"!==t.style.display&&Wn(t,e,!1).then(e=>{!1!==e&&o===i&&(t.style.display="none")}),()=>Rn.cancel(t)):(t.style.display=a?s:"none",()=>Rn.cancel(t)):(r=!0,t.style.display=a?s:"none",()=>Rn.cancel(t))})}if(t.hasAttribute("g-html")){const n=t.getAttribute("g-html");mn(t,()=>{const s=nn(n,e);t.innerHTML=s})}if(t.hasAttribute("g-text")){const n=t.getAttribute("g-text");mn(t,()=>{const s=nn(n,e);t.textContent=s})}Array.from(t.attributes).forEach(n=>{if(n.name.startsWith("g-")&&!["g-scope","g-show","g-html","g-text","g-model","g-static","g-portal","g-transition","g-hydrate","g-provide"].includes(n.name)){const r=n.name.slice(2).replace(/:.+$/,""),i=(s=r,Pn.get(s)),a=n.name.split(":");let o;if(a.length>1&&(o=a.slice(1)),i){const s=()=>{if(""!==n.value.trim())return"on"===r&&"function"==typeof e[n.value]?e[n.value]:nn(n.value,e,!1)},a=s();let c=i.mounted?a:void 0,l=!i.mounted;if(i.mounted&&i.mounted(t,{value:a,arg:o,oldValue:void 0},e),i.unmounted){let e=!0;const n=()=>{e&&(e=!1,i.unmounted(t))};t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(n)}i.updated&&mn(t,()=>{const n=s();if(!l)return l=!0,void(c=n);Object.is(c,n)||(i.updated(t,{value:n,oldValue:c,arg:o},e),c=n)})}}var s})}}(s,e,t),r.some(t=>t.name.startsWith(":"))&&function(t,e,n){if(!(ve(t)||ye(t,n)||t.hasAttribute("*if")||t.hasAttribute("*for")))for(const n of ns(t)){const s=n.name.slice(1),r=n.value,i="class"===s?qn(t):void 0,a="style"===s?Yn(t):void 0;mn(t,()=>{const n=un(t)||e,o=nn(r,n);"class"===s?Hn(t,o,i):"style"===s?Jn(t,o,a):es(t,s,o)})}}(s,e,t),r.some(t=>t.name.match(/^g-model($|[.])/))&&function(t,e,n){if(ve(t))return;if(ye(t,n))return;const s=Array.from(t.attributes).find(t=>t.name.startsWith("g-model"));if(!s)return;const r=t,i=s.name.split(".").slice(1),a=s.value,o=i.includes("debounce");let c=300;if(o){const t=i.find(t=>/^\d+$/.test(t));t&&(c=parseInt(t))}_e();const l=un(t)||e,u=ks(a);"string"==typeof u[0]&&function(t,e){if(!Ss(t)||e in t)return;let n=t,s=Ss(n);for(;s;)n=s,s=Ss(n);e in n||(n[e]=void 0),Object.defineProperty(t,e,{get:()=>n[e],set:t=>{n[e]=t},configurable:!0,enumerable:!0})}(l,u[0]);const h=nn(a,l,!1);let p;"checkbox"===r.type?r.checked=!!h:"radio"===r.type?r.checked=$e(h)+""===r.value:r.value=$e(h);const f=t=>{const e=t.target;var n;("radio"!==e.type||e.checked)&&(n="checkbox"===e.type?e.checked:e.value,i.includes("number")&&(n=Number(n)),i.includes("trim")&&"string"==typeof n&&(n=n.trim()),o?(clearTimeout(p),p=setTimeout(()=>{Cs(l,a,n)},c)):Cs(l,a,n))};r.addEventListener("input",f),mn(t,()=>{const t=nn(a,l,!1);"checkbox"===r.type?r.checked=!!t:"radio"===r.type?r.checked=$e(t)+""===r.value:r.value!==t&&(r.value=$e(t))}),t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(()=>{r.removeEventListener("input",f),p&&(clearTimeout(p),p=void 0)}),t.removeAttribute(s.name)}(s,e,t)}),function(t,e){const n=document.createTreeWalker(t,NodeFilter.SHOW_TEXT,null),s=[];let r;for(;r=n.nextNode();){if(yn(r,t,e))continue;const n=r.textContent||"";n.includes("{")&&n.includes("}")&&s.push({node:r,template:n})}s.forEach(({node:t,template:n})=>{const s=t.parentElement;s&&mn(s,()=>{const s=un(t.parentElement)||e;t.textContent=en(n,s)})})}(t,e),function(t,e){const n=Ee(t,t=>!ve(t)&&!t.hasAttribute("g-static"),NodeFilter.FILTER_REJECT);n.unshift(t),n.forEach(n=>{if(ye(n,t))return;const s=un(n);s&&s!==e||Array.from(n.attributes).forEach(t=>{if(t.name.startsWith("@")){const s=t.name.substring(1).split("."),r=s[0],i=s.slice(1),a=t.value;if(i.includes("outside"))return void function(t,e,n,s,r){let i,a=!0;const o=r=>{const i=r.target;if(document.body.contains(t)){if(!(i instanceof Element&&i.closest("[g-ignore-outside-click]")||t===i||t.contains(i))){const i=un(t)||s;n.includes("once")&&c(),ws(e,i,r,n)}}else c()},c=()=>{a&&(a=!1,void 0!==i&&(clearTimeout(i),i=void 0),document.removeEventListener("click",o,!0),l.disconnect())},l=new MutationObserver(e=>{for(const n of e)n.removedNodes.forEach(e=>{(e===t||e instanceof Element&&e.contains(t))&&!document.body.contains(t)&&c()})});l.observe(document.body,{childList:!0,subtree:!0}),t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(c),i=window.setTimeout(()=>{a&&document.addEventListener("click",o,!0)},0),t.removeAttribute(r)}(n,a,i,e,t.name);const o=function(t){const e=t.findIndex(t=>"debounce"===t||/^\d+$/.test(t));if(-1===e)return 0;if("debounce"===t[e]){const n=t[e+1];return n&&/^\d+$/.test(n)?parseInt(n):300}return 0}(i),c="keyup"===r||"keydown"===r||"keypress"===r,l={timeoutId:0};let u=()=>{};const h=t=>{if(c&&!function(t,e){let n=!1;for(const t of e)if(!_s.has(t)&&!/^\d+$/.test(t)){n=!0;break}if(!n)return!0;const s=t.key.toLowerCase();for(const t of e){if(_s.has(t)||/^\d+$/.test(t))continue;const e=bs[t];if(e){if(s===e)return!0}else if(s===t.toLowerCase())return!0}return!("backspace"!==s||!e.includes("delete"))}(t,i))return;const s=()=>{i.includes("once")&&u(),Be(()=>{const s=un(n)||e;ws(a,s,t,i)})};o>0?(clearTimeout(l.timeoutId),l.timeoutId=window.setTimeout(s,o)):s()},p={};let f=n;i.includes("capture")&&(p.capture=!0),i.includes("passive")&&(p.passive=!0),i.includes("global")&&(f=document.documentElement),f.addEventListener(r,h,p),u=()=>{f.removeEventListener(r,h,!!p.capture),l.timeoutId&&clearTimeout(l.timeoutId)},n.__gyos_effects__||(n.__gyos_effects__=[]),n.__gyos_effects__.push(u),n.removeAttribute(t.name)}})})}(t,e),function(){const t=fn();if(t){for(let e=0;e<t.length;e++){const{target:n,runner:s}=t[e];dn(n,s)}t.length=0,pn.pop()}}(),t.hasAttribute("g-portal")){const e=t.getAttribute("g-portal");rs(t,e)}}const rr=new class{constructor(){this.observers=new Map,this.pending=new WeakSet}setup(t,e,n){if(this.pending.has(t))return;this.pending.add(t);const s=()=>{this.pending.delete(t),n()};switch(e){case"idle":this.hydrateOnIdle(t,s);break;case"visible":this.hydrateOnVisible(t,s);break;case"interaction":this.hydrateOnInteraction(t,s);break;default:if(e.startsWith("media(")){const n=`(${e.slice(6,-1)})`;this.hydrateOnMedia(t,n,s)}else s()}}hydrateOnIdle(t,e){let n=!0;const s=()=>{n&&(n=!1,e())};if("requestIdleCallback"in window){const e=window.requestIdleCallback(s,{timeout:2e3});this.trackCleanup(t,()=>{n=!1,window.cancelIdleCallback?.(e)})}else{const e=setTimeout(s,1);this.trackCleanup(t,()=>{n=!1,clearTimeout(e)})}}hydrateOnVisible(t,e){if(_e(),!("IntersectionObserver"in window))return _e(),void e();this.intersectionObserver||(_e(),this.intersectionObserver=new IntersectionObserver(t=>{_e(),t.forEach(t=>{if(_e(),t.isIntersecting){const e=t.target,n=this.observers.get(e);n&&(_e(),n(),this.observers.delete(e),this.intersectionObserver?.unobserve(e))}})},{rootMargin:"50px"})),this.observers.set(t,e),this.intersectionObserver.observe(t),this.trackCleanup(t,()=>this.cleanup(t)),_e()}hydrateOnInteraction(t,e){const n=["mouseenter","touchstart","focus"];let s=!1;const r=()=>{s||(s=!0,n.forEach(e=>{t.removeEventListener(e,r)}),e())};n.forEach(e=>{t.addEventListener(e,r,{once:!0,passive:!0})}),this.trackCleanup(t,()=>{s=!0,n.forEach(e=>t.removeEventListener(e,r))})}hydrateOnMedia(t,e,n){const s=window.matchMedia(e);if(s.matches)n();else{let e=!0;const r=t=>{e&&t.matches&&(e=!1,n(),s.removeEventListener("change",r))};s.addEventListener("change",r),this.trackCleanup(t,()=>{e=!1,s.removeEventListener("change",r)})}}trackCleanup(t,e){t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(()=>{this.pending.delete(t),e()})}cleanup(t){this.pending.delete(t),this.observers.delete(t),this.intersectionObserver&&this.intersectionObserver.unobserve(t)}};er=ur;const ir=new Map;function ar(t,e){if(t instanceof HTMLElement){const n=Math.random().toString(36);return t.setAttribute("g-scope",n),void ir.set(n,e)}ir.set(t,e)}function or(t){let e=0;for(;t.parentElement;)e++,t=t.parentElement;return e}function cr(t){if(t)return void(t instanceof HTMLElement?[t]:Array.from(t)).forEach(t=>lr(t));const e=[...document.querySelectorAll("[g-scope]"),...Ee(document.body,t=>{if(t.hasAttribute("g-scope"))return!1;for(const e of t.attributes){const t=e.name;if(t.startsWith("gd-")||t.startsWith("gm-"))return!0}return!1})].filter(t=>!ve(t));e.sort((t,e)=>or(e)-or(t)),e.forEach(t=>!ke(t)&&ur(t))}function lr(t){if(ve(t)||!document.body.contains(t))return;const e=[t,...Ee(t,t=>!ve(t),NodeFilter.FILTER_REJECT)].filter(t=>t.hasAttribute("g-scope")||(t=>Array.from(t.attributes).some(t=>t.name.startsWith("gd-")||t.name.startsWith("gm-")))(t));if(e.sort((t,e)=>or(e)-or(t)),e.forEach(t=>!ke(t)&&ur(t)),on(t))return;const n=un(t);n&&sr(t,n)}function ur(t){document.body.contains(t)&&(ve(t)||(cn().forEach((t,e)=>{document.body.contains(e)||As(e)}),function(t,e){const n=function(t,e){let n;const s=pr(t,t=>an.get(t));if(s)return s;n=function(t){t=decodeURIComponent(t);try{const e=t.trim();if(!e.startsWith("{"))return;const n=le().parseScope(e);return _e(),n}catch(t){return void _e()}}(e),n||(n=ir.get(e)||{});const r=function(t){const e=["constructor","__proto__","prototype","globalThis","window","document","Function","eval","require","import"],n=t=>{if(0===t.length)return t;const e=t.trim();if("true"===e.toLocaleLowerCase())return!0;if("false"===e.toLocaleLowerCase())return!1;if(!isNaN(Number(t))&&e===t)return Number(t);if(!/^[\[{]/.test(e))return t;try{return JSON.parse(e)}catch(e){return t}},s=t.attributes;let r={},i=[];for(let t=0;t<s.length;t++){const a=s[t],o=a.name.substring(3).replace(/-([a-z])/g,t=>t[1].toUpperCase());if(be(o.split(":",1)[0]))i.push(a.name);else if(a.name.match(/^gd-.+/))r[o]=n(a.value),i.push(a.name);else if(a.name.match(/^gm-.+/)){const t=decodeURIComponent(a.value.trim());e.some(e=>t.includes(e))&&_e();const n=o.split(":").slice(1),s=o.split(":")[0];try{r[s]=le().createMethod(n,t),i.push(a.name)}catch(t){_e()}}}return i.forEach(e=>t.removeAttribute(e)),r}(t);if("function"==typeof n){const e=n;return n=>{const s=e(n);return s&&"object"==typeof s?(Object.keys(r).forEach(t=>{s[t]=r[t]}),hr(t,s),s):s}}return Object.keys(r).forEach(t=>{n[t]=r[t]}),hr(t,n),n}(t,e);if(on(t))return;if(t.hasAttribute("g-static"))return;const s=function(t){return t.getAttribute("g-hydrate")||null}(t);s?rr.setup(t,s,()=>{document.body.contains(t)&&!ve(t)&&fr(t,n)}):fr(t,n)}(t,t.getAttribute("g-scope")||Math.random().toString(36))))}function hr(t,e){const n=Ee(t,t=>t.getAttributeNames().some(t=>t.startsWith("g-model"))),s=new Map;for(const t of n){if(ve(t))continue;const n=t.attributes,r=Array.from(n).find(t=>t.name.startsWith("g-model"));if(!r)continue;if(r.value.includes("."))continue;const i=t;if("radio"===i.type){if(r.value in e)continue;if(s.has(r.value)||s.set(r.value,""),i.checked){const t=r.name.split(".").includes("number")?Number(i.value):i.value;s.set(r.value,t)}continue}if(r.value in e)continue;const a="checkbox"===i.type?i.checked:i.value;e[r.value]=a,_e()}for(const[t,n]of s)t in e||(e[t]=n,_e())}function pr(t,e){if(!t.hasAttribute("g-scope-persist"))return;const n=t.getAttribute("g-scope-persist");if(!n)return;if(!n.startsWith("{")||!n.endsWith("}"))return e(n);const s=t.parentElement.__gyos_scope__;return s?e(nn(n.slice(1,-1),s,!1)):void 0}function fr(t,e){let n=null;"object"==typeof e&&(n=Ys(e));const s=function(t,e){const n={},s=new Map;return t.querySelectorAll("[g-ref]").forEach(t=>{if(ve(t))return;const e=t.getAttribute("g-ref");e&&!be(e)&&(n[e]=t)}),{inject:e=>Ye(t).get(e),provide:(e,n)=>{Ye(t).set(e,n)},$refs:n,$emit:(e,...n)=>{const r=s.get(e);r&&r.forEach(t=>{try{t(...n)}catch(t){_e()}}),t.dispatchEvent(new CustomEvent(e,{detail:n}))},$on:(t,e)=>(s.has(t)||s.set(t,new Set),s.get(t).add(e),()=>{s.get(t)?.delete(e)}),$watch:(t,n,s={})=>{if(!e)return _e(),()=>{};const{immediate:r=!1,deep:i=!1,debounce:a=0}=s;let o;if(a>0){const t=n;n=(...e)=>{clearTimeout(o),o=setTimeout(()=>{t(...e)},a)}}let c,l=!1;const u=Fe(()=>{const s=((t,e)=>{const n=e.split(".");let s=t;for(const t of n){if(null==s)return;s=s[t]}return s})(e,t),a=i&&"object"==typeof s?me(s):s;if(!l)return c=a,l=!0,void(r&&n.call(e,a,void 0));(i?!ge(c,a):c!==a)&&(n.call(e,a,c),c=i&&"object"==typeof a?me(a):a)});return e.__gyos_effects__||(e.__gyos_effects__=[]),e.__gyos_effects__.push(u),u},$effect:t=>{if(!e)return _e(),()=>{};const n=Fe(t);return e.__gyos_effects__||(e.__gyos_effects__=[]),e.__gyos_effects__.push(n),n}}}(t,n);if("function"==typeof e&&!n){const t=e(s);n=t&&"object"==typeof t?Ys(t):t}if(n&&"object"==typeof n){if(n.onUpdate){const e=n[Vs],s=Fe(()=>{e&&(e.value,on(t)&&n.onUpdate.call(n))});n.__gyos_effects__||(n.__gyos_effects__=[]),n.__gyos_effects__.push(s)}n.$refs=s.$refs,n.$emit=s.$emit,n.$on=s.$on,n.$watch=s.$watch,n.$effect=s.$effect,n.$inject=s.inject,n.$provide=s.provide,function(t,e,n){t.__gyos_scope__=e,function(t,e){if(t.hasAttribute("g-static"))return _e(),t.removeAttribute("g-static"),t.__gyos_static__=!0,vn(t,e),$n(t,e),void ss(t,e);sr(t,e)}(t,e),n&&n()}(t,n,()=>{n.onMount&&Promise.resolve(n.onMount.call(n)).catch(console.error)}),function(t,e){rn.set(t,e)}(t,n),pr(t,t=>{an.has(t)||an.set(t,n)})}else _e()}const dr=new Map;function mr(t,e){if(e){const s=Ys(e);return(n=s).hasOwnProperty(Bs)||Reflect.defineProperty(n,Bs,{value:!0,enumerable:!1}),dr.set(t,s),s}var n;const s=dr.get(t);if(!s)throw Error(`[GyosJS] Store "${t}" not found`);return s}function gr(t){return dr.has(t)}function yr(t){dr.delete(t)}function vr(){return Array.from(dr.keys())}const xr=new Map;function br(t,e){return xr.has(t)||xr.set(t,new Set),xr.get(t).add(e),()=>{xr.get(t)?.delete(e)}}function _r(t,...e){const n=xr.get(t);n&&n.forEach(t=>{try{t(...e)}catch(t){}})}function wr(t,e){e?xr.get(t)?.delete(e):xr.delete(t)}function Er(t,e){const n=(...s)=>{e(...s),wr(t,n)};return br(t,n)}function Sr(){const t={};return xr.forEach((e,n)=>{t[n]=e.size}),t}function kr(){xr.clear()}function Cr(t){const e=Re(null),n=Re(!0),s=Re(null),r=async()=>{n.value=!0,s.value=null,e.value=null;try{const n="function"==typeof t?await t():t,s="string"==typeof n?await fetch(n):n;if(!s.ok)throw Error("HTTP error! status: "+s.status);e.value=await s.json()}catch(t){s.value=t}finally{n.value=!1}};return{data:e,loading:n,error:s,refetch:r,onMount:r}}function Ar(t=0){const e=Re(t),n=De(()=>2*e.value);return{count:e,double:n,increment:(t=1)=>{e.update(e=>e+t)},decrement:(t=1)=>{e.value-=t},reset:()=>{e.update(()=>t)}}}function Ir(t=!1){const e=Re(t);return{state:e,toggle:()=>{e.value=!e.value},setTrue:()=>{e.value=!0},setFalse:()=>{e.value=!1},value:e}}function Tr(t,e){const n=localStorage.getItem(t),s=Re(n?JSON.parse(n):e??""),r=s.subscribe(()=>localStorage.setItem(t,JSON.stringify(s.value)));return{state:s,remove:()=>localStorage.removeItem(t),onUnmount:r}}function Pr(t,e){let n=null;const s=()=>{r(),null!==e&&(n=setInterval(t,e))},r=()=>{null!==n&&(clearInterval(n),n=null)};return{start:s,stop:r,onMount:()=>s(),onUnmount:()=>r(),restart:()=>{r(),s()}}}function Nr(t,e){let n=null;const s=()=>{r(),n=setTimeout(()=>{n=null,t()},e)},r=()=>{null!==n&&(clearTimeout(n),n=null)};return{start:s,clear:r,onMount:()=>s(),onUnmount:()=>r()}}function Lr(t="",e){const n=Re(t),s=Re(t);let r=null;const i=Fe(()=>{const t=n.value;null!==r&&clearTimeout(r),r=setTimeout(()=>{s.value=t},e)});return{value:n,debounced:De(()=>s.value),onUnmount:()=>{i(),null!==r&&clearTimeout(r)}}}function Mr(t="",e){const n=Re(t),s=Re(t);let r=0;const i=Fe(()=>{const t=n.value,i=Date.now();e>i-r||(r=i,s.value=t)});return{value:n,throttled:De(()=>s.value),onUnmount:()=>{i()}}}function Vr(){const t=Re(0),e=Re(0),n=n=>{t.value=n.clientX,e.value=n.clientY};return{x:t,y:e,onMount:()=>{window.addEventListener("mousemove",n)},onUnmount:()=>{window.removeEventListener("mousemove",n)}}}function Or(){const t=Re(window.innerWidth),e=Re(window.innerHeight),n=()=>{t.value=window.innerWidth,e.value=window.innerHeight};return{width:t,height:e,onMount:()=>{window.addEventListener("resize",n)},onUnmount:()=>{window.removeEventListener("resize",n)}}}function Rr(t){const e={},n={},s={},r=Object.keys(t);for(const i of r){const r=window.matchMedia(t[i]);n[i]=r,e[i]=Re(r.matches),s[i]=t=>{e[i].value=t.matches}}return{matches:e,onMount:()=>{for(const t of r){const e=n[t],r=s[t];e.addEventListener?e.addEventListener("change",r):e.addListener(r)}},onUnmount:()=>{for(const t of r){const e=n[t],r=s[t];e.removeEventListener?e.removeEventListener("change",r):e.removeListener(r)}}}}function Dr(t,e=!0){const n=Re(null),s=Re(!1),r=Re(null),i=async()=>{s.value=!0,r.value=null;try{n.value=await t()}catch(t){r.value=t}finally{s.value=!1}};return{data:n,loading:s,error:r,execute:i,onMount:()=>{e&&i()}}}class Fr{constructor(t=!0){this.element=null,this.animationFrame=null,this.hideTimer=null,this.resetTimer=null,this.currentProgress=0,this.progressBarEnabled=!0,this.progressBarEnabled=t,this.createBar()}getCurrentProgress(){return this.currentProgress}createBar(){"undefined"!=typeof document&&(this.element=document.createElement("div"),this.element.id="gyos-progress-bar",this.element.style.cssText="\n position: fixed;\n top: 0;\n left: 0;\n width: 0%;\n height: 6px;\n background: var(--gyos-progress-color, linear-gradient(90deg, #aab9ff, #77889f));\n z-index: 999999;\n transition: width 0.3s linear, opacity 0.3s linear;\n opacity: 0;\n pointer-events: none;\n box-shadow: 0 0 10px rgba(102, 126, 234, 0.5);\n ","loading"===document.readyState?document.addEventListener("DOMContentLoaded",()=>{document.body.insertAdjacentElement("beforeend",this.element)}):document.body.insertAdjacentElement("beforeend",this.element))}start(){this.element&&this.progressBarEnabled&&(this.hideTimer&&(clearTimeout(this.hideTimer),this.hideTimer=null),this.resetTimer&&(clearTimeout(this.resetTimer),this.resetTimer=null),this.currentProgress=0,this.element.style.width="0%",this.setProgress(20))}setProgress(t){this.element&&this.progressBarEnabled&&(t=Math.min(100,Math.max(0,t)),this.currentProgress=t,this.animationFrame&&cancelAnimationFrame(this.animationFrame),this.element.style.width=t+"%",this.element.style.opacity=""+Math.max(.6,t/100))}complete(){this.element&&this.progressBarEnabled&&(this.setProgress(100),this.hideTimer=window.setTimeout(()=>{this.hideTimer=null,this.hide()},300))}hide(){this.element&&(this.element.style.opacity="0",this.resetTimer&&clearTimeout(this.resetTimer),this.resetTimer=window.setTimeout(()=>{this.resetTimer=null,this.element&&(this.element.style.width="0%",this.currentProgress=0)},300))}}function Br(t){t&&t.parentNode&&t.remove()}let Ur;function jr(t){Ur=t}const Wr=new Set;function $r(t){let e=0;for(let n=0;n<t.length;n++)e=(e<<5)-e+t.charCodeAt(n),e&=e;return"inline:"+e}function qr(t){if(!t.hasAttribute("g-script-once"))return!0;const e=t.src||$r(t.textContent||"");return!Wr.has(e)&&(Wr.add(e),!0)}function Hr(t){return t.hasAttribute("g-script-once")?t.src||$r(t.textContent||""):null}function Gr(t,e=Hr(t)){const n=e;n&&Wr.delete(n)}function zr(t,e,n=Hr(t)){return t.src||"module"===t.type?new Promise(s=>{let r=!1;const i=()=>{r||(r=!0,e?.removeEventListener("abort",a),s())},a=()=>{Gr(t,n),t.remove(),i()};t.addEventListener("load",i,{once:!0}),t.addEventListener("error",()=>{Gr(t,n),t.remove(),i()},{once:!0}),e?.aborted?a():e?.addEventListener("abort",a,{once:!0})}):Promise.resolve()}async function Yr(t,e){if(e?.aborted)return void t.remove();const n=("function"==typeof Ur?Ur():Ur)||void 0;if("csp"===ue()&&!t.src&&!n)return void(t.textContent="");const s=Hr(t);if(!qr(t))return void(t.textContent="");const r=document.createElement("script");Array.from(t.attributes).forEach(t=>r.setAttribute(t.name,t.value)),"csp"===ue()&&r.removeAttribute("nonce"),n&&r.setAttribute("nonce",n),r.textContent=t.hasAttribute("g-script-wrap")?Jr(t.textContent):t.textContent,r.removeAttribute("g-script-wrap");const i=zr(r,e,s);t.replaceWith(r),await i}async function Kr(t,e){const n=[];for(const e of t)e instanceof HTMLScriptElement&&n.push(e),e instanceof Element&&n.push(...Array.from(e.querySelectorAll("script")));for(const t of n)if(await Yr(t,e),e?.aborted)return}function Jr(t){return t?`(() => { ${t} })();`:t}const Qr=new Map;let Xr=0;function Zr(t,e=!1){if(t.dataset.gyosPersistId)return t.dataset.gyosPersistId;const n=t.getAttribute("g-persist");if(n&&n.trim().length)return t.dataset.gyosPersistId=n.trim(),t.dataset.gyosPersistId;if(t.id)return t.dataset.gyosPersistId="id:"+t.id,t.dataset.gyosPersistId;if(!e)return null;const s="gyos-persist-"+Xr++;return t.dataset.gyosPersistId=s,s}const ti="undefined"!=typeof document?(()=>{const t=document.createElement("div");return t.style.position="fixed",t.style.left="-99999px",t.style.top="-99999px",t.style.width="0",t.style.height="0","loading"===document.readyState?document.addEventListener("DOMContentLoaded",()=>document.body.appendChild(t)):document.body.appendChild(t),t})():null;function ei(t){const e=Array.from(t.querySelectorAll("[g-persist]"));return t instanceof HTMLElement&&t.matches("[g-persist]")&&e.unshift(t),e}function ni(t,e){const n=new Set;Array.from(e.attributes).forEach(e=>{n.add(e.name),t.getAttribute(e.name)!==e.value&&t.setAttribute(e.name,e.value)}),Array.from(t.attributes).forEach(e=>{n.has(e.name)||t.removeAttribute(e.name)})}function si(t,e,n){if(e&&e.hasAttribute("g-noscroll"))return;const s=new URL(t).hash;if(s){const t=document.querySelector(s);if(t)return void t.scrollIntoView({behavior:"smooth"})}n?window.scrollTo(n.x,n.y):window.scrollTo({top:0,behavior:"smooth"})}function ri(t){const e=new Map;return t.map(t=>{const n=function(t){const e=t.tagName.toLowerCase(),n="script"===e||"style"===e?function(t){let e=0;for(let n=0;n<t.length;n++)e=(e<<5)-e+t.charCodeAt(n)|0;return e+""}(t.textContent||""):"";return`${e}|${function(t){return Array.from(t.attributes).map(t=>`${t.name}=${t.value}`).sort().join("|")}(t)}|${n}`}(t),s=e.get(n)||0;return e.set(n,s+1),{key:`${n}|${s}`,node:t}})}async function ii(t,e,n=document.head,s){const r=ri(t),i=ri(e),a=new Set(r.map(t=>t.key)),o=new Set(i.map(t=>t.key));r.forEach(({key:t,node:e})=>{o.has(t)||e.remove()});for(const{key:t,node:e}of i){if(s?.aborted)return;if(!a.has(t)){if("SCRIPT"===e.tagName){const t=e,r=Hr(t);if(!qr(t)){e.remove();continue}const i=document.createElement("script");Array.from(e.attributes).forEach(t=>i.setAttribute(t.name,t.value)),i.textContent=e.hasAttribute("g-script-wrap")?Jr(e.textContent||""):e.textContent||"",i.removeAttribute("g-script-wrap");const a=zr(i,s,r);n.appendChild(i),await a;continue}n.appendChild(document.importNode(e,!0))}}}const ai=new Map,oi=new Map,ci=new Map,li=new Map,ui=new Map;let hi=!1,pi=0,fi=0,di=!0,mi=Ii(window.location.href,!0),gi=history.state?.gyosEntryId||null,yi=null,vi=null;const xi=[],bi=[];function _i(t){xi.push(t)}function wi(t){bi.push(t)}function Ei(t){document.querySelector("[g-boost]")&&(hi||"undefined"!=typeof window&&"undefined"!=typeof document&&(di=!1!==t?.showProgress,di&&(vi=new Fr(di)),document.addEventListener("click",ji),document.addEventListener("submit",$i),document.addEventListener("mouseover",Wi,!0),window.addEventListener("popstate",qi),"scrollRestoration"in history&&(history.scrollRestoration="manual"),document.querySelectorAll("script").forEach(t=>{const e=t.hasAttribute("g-script-once"),n=e?t.src||$r(t.textContent||""):null;t.hasAttribute("g-script-wrap")&&t.removeAttribute("g-script-wrap"),e&&n&&Wr.add(n)}),hi=!0,Se()))}function Si(){return!!document.body?.hasAttribute("g-boost")}function ki(){return document.querySelector("[g-outlet]")}function Ci(t){t.querySelectorAll("noscript").forEach(t=>t.remove())}function Ai(t){const e=(new DOMParser).parseFromString(t,"text/html");return Ci(e),e}function Ii(t,e=!1){const n=new URL(t,window.location.href);return e||(n.hash=""),n.href}function Ti(){return`gyos-${Date.now().toString(36)}-${++fi}`}function Pi(t=!0){if(gi)return gi;const e=history.state||{};return gi=e.gyosEntryId||Ti(),t&&!e.gyosEntryId&&history.replaceState({...e,gyosEntryId:gi},""),gi}function Ni(t,e,n){let s=ui.get(t);s||(s=new Map,ui.set(t,s)),s.set(e,n.cloneNode(!0))}function Li(t,e){const n=ui.get(t)?.get(e);return n?.cloneNode(!0)}function Mi(t){return yi?.id===t.id&&!t.controller.signal.aborted}function Vi(t){if(!Mi(t))throw new DOMException("Navigation superseded","AbortError")}function Oi(t){t.controller.abort(),t.interval&&(clearInterval(t.interval),t.interval=null),t.spinner&&(Br(t.spinner),t.spinner=null)}function Ri(t){t?.catch(()=>{})}function Di(t,e){t.forEach(t=>{try{t(e)}catch(t){}})}function Fi(t,e){t.querySelectorAll("script[src]").forEach(t=>{const n=t.getAttribute("src");n&&(t.src=new URL(n,e).href)})}function Bi(t,e,n){"GET"!==(t.method||"GET").toUpperCase()?n||!t.form||HTMLFormElement.prototype.submit.call(t.form):window.location.href=e}async function Ui(t){for(;yi;){const t=yi;if(!t.committing){Se(),Oi(t);break}Se(),await t.done}let e;const n=new Promise(t=>{e=t}),s={id:++pi,controller:new AbortController,interval:null,spinner:null,committing:!1,done:n,resolveDone:e};yi=s;const r=t.trigger?.hasAttribute("g-router-spin"),i=()=>{Mi(s)&&70>vi?.getCurrentProgress()&&vi?.setProgress(vi?.getCurrentProgress()+8*Math.random())};try{Di(xi,t.url),vi?.start(),(a=t.scrollSourceEntryId??gi)&&li.set(a,{x:window.scrollX,y:window.scrollY}),t.popstate||function(){const t=history.state||{},e={x:window.scrollX,y:window.scrollY};history.replaceState({...t,scroll:e},"")}();let e=function(t,e,n){if(e)try{const t=document.querySelector(e);if(t instanceof HTMLElement)return t}catch{}if(null!=n){const t=document.querySelectorAll("[g-outlet]")[n];if(t)return t}if(t){const e=t.getAttribute("g-target");if(e){const t=document.querySelector(e);if(t instanceof HTMLElement)return t}const n=t.closest("[g-outlet]");if(n instanceof HTMLElement)return n}const s=ki();return s instanceof HTMLElement?s:null}(t.trigger,t.targetSelector,t.targetOutletIndex);if(!e)return void(Mi(s)&&Bi(t,t.url,!1));const n=(t.swapMode||t.trigger?.getAttribute("g-swap")||"inner").toLowerCase(),o=t.trigger instanceof HTMLElement&&t.trigger.hasAttribute("g-router-remove"),c=!["append","prepend"].includes(n),l=e===ki(),u=function(t,e){if(!e.hasAttribute("g-outlet"))return null;const n=Array.from(t.querySelectorAll("[g-outlet]")).indexOf(e);return-1===n?null:n}(document,e),h=l?null:t.targetSelector||t.trigger?.getAttribute("g-target")||(e.id?"#"+e.id:null),p=t.currentHead??t.trigger?.hasAttribute("g-current-head")??!1,f={targetSelector:h,targetOutletIndex:l?null:u,swapMode:l?"inner":"morph",currentHead:p};r&&(s.spinner=function(t,e){const n=function(){const t=document.createElement("div");if(t.className="gyos-target-spinner",t.innerHTML='\n\t\t<div class="gyos-spinner-content">\n\t\t\t<svg class="gyos-spinner-icon" viewBox="0 0 50 50">\n\t\t\t\t<circle cx="25" cy="25" r="20" fill="none" stroke="currentColor" stroke-width="4" stroke-dasharray="31.4 31.4" />\n\t\t\t</svg>\n\t\t</div>\n\t',"standard"===ue()&&!document.getElementById("gyos-target-spinner-styles")){const t=document.createElement("style");t.id="gyos-target-spinner-styles",t.textContent="\n\t\t\t.gyos-target-spinner {\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t\tjustify-content: center;\n\t\t\t\tpadding: 20px;\n\t\t\t\tmin-height: 60px;\n\t\t\t}\n\t\t\t.gyos-spinner-content {\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t\tgap: 10px;\n\t\t\t\tcolor: var(--gyos-spinner-color, #667eea);\n\t\t\t\tfont-size: 14px;\n\t\t\t}\n\t\t\t.gyos-spinner-icon {\n\t\t\t\twidth: 24px;\n\t\t\t\theight: 24px;\n\t\t\t\tanimation: gyos-spin 1s linear infinite;\n\t\t\t}\n\t\t\t@keyframes gyos-spin {\n\t\t\t\t0% { transform: rotate(0deg); }\n\t\t\t\t100% { transform: rotate(360deg); }\n\t\t\t}\n\t\t",document.head.appendChild(t)}return t}();return"prepend"===e?t.prepend(n):t.appendChild(n),n}(e,n));const{finalUrl:d,init:m}=function(t){const e=(t.method||"GET").toUpperCase(),n=new Headers({"X-Gyos-Boost":"1",Accept:"text/html,application/xhtml+xml"}),s={method:e,headers:n,redirect:"follow",mode:"same-origin"};let r=new URL(t.url,window.location.href);const i="GET"===e;if(t.formData)i?r=function(t,e){return e.forEach((e,n)=>{"string"==typeof e?t.searchParams.append(n,e):t.searchParams.append(n,e.name)}),t}(r,t.formData):s.body=t.formData;else if(t.jsonData){const e=(t,e)=>{"object"==typeof e?r.searchParams.append(t,JSON.stringify(e)):r.searchParams.append(t,e+"")};i?Object.entries(t.jsonData).forEach(([t,n])=>e(t,n)):(n.set("Content-Type","application/json"),s.body=JSON.stringify(t.jsonData))}return{finalUrl:r.toString(),init:s}}(t);let g,y;m.signal=s.controller.signal;const v=Ii(d);if(t.popstate&&t.historyFragment)Se();else if(t.popstate&&ai.has(v))Se(),g=ai.get(v).html;else{const n=Ii(d,!0);if("GET"===t.method.toUpperCase()&&oi.has(n)){Se();try{y=await function(t,e){return e.aborted?Promise.reject(new DOMException("Navigation superseded","AbortError")):new Promise((n,s)=>{const r=()=>s(new DOMException("Navigation superseded","AbortError"));e.addEventListener("abort",r,{once:!0}),t.then(t=>{e.removeEventListener("abort",r),n(t)},t=>{e.removeEventListener("abort",r),s(t)})})}(oi.get(n),s.controller.signal)}catch(t){if(oi.delete(n),ci.get(n)?.abort(),ci.delete(n),"AbortError"===t.name)throw t;return Vi(s),void(window.location.href=d)}oi.delete(n),ci.delete(n)}else try{vi?.setProgress(10*Math.random()+20),s.interval=setInterval(i,300),y=await fetch(d,m),Vi(s),vi?.setProgress(10*Math.random()+70),s.interval&&clearInterval(s.interval),s.interval=null}catch(e){return"AbortError"===e.name?void Se():void(Mi(s)&&Bi(t,d,!0))}if(Vi(s),!y||!y.ok||!function(t){try{if(t.url&&new URL(t.url,window.location.href).origin!==window.location.origin)return!1}catch{return!1}const e=t.headers.get("Content-Disposition")||"";if(/\battachment\b/i.test(e))return!1;const n=(t.headers.get("Content-Type")||"").split(";",1)[0].trim().toLowerCase();return"text/html"===n||"application/xhtml+xml"===n}(y))return void(Mi(s)&&Bi(t,d,!0));g=await y.text(),Vi(s),!t.popstate&&e.hasAttribute("g-snapshot")&&function(t,e){const n=Ai(e);t.includes("#")&&(t=t.split("#")[0]),Array.from(n.scripts).forEach(t=>{t.hasAttribute("g-script-once")&&(t.textContent="")}),ai.set(t,{html:n.documentElement.outerHTML}),Se()}(Ii(y.url||d),g)}const x=g?Ai(g):document.implementation.createHTMLDocument(),b=t.historyFragment||function(t,e,n){if(e.id){const n=t.getElementById(e.id);if(n instanceof HTMLElement)return n}if(null!==n){const e=t.querySelectorAll("[g-outlet]")[n];if(e)return e}const s=t.querySelector("[g-outlet]");return s instanceof HTMLElement?s:t.body}(x,e,u);Ci(b),Vi(s);let _=y?.url||d;d.includes("#")&&y?.url&&(_+=d.substring(d.indexOf("#"))),Fi(x,_),t.historyFragment&&Fi(b,_);const w=t.trigger?.hasAttribute("g-change-state")||!1,E=t.trigger?.hasAttribute("g-current-state")||!1,S="GET"!==t.method.toUpperCase()&&!0===y?.redirected,k=!E&&(!0===t.changeState||w||S),C=async()=>{Vi(s),s.committing=!0,vi?.setProgress(10*Math.random()+80);const r=!k||t.replace||l?null:function(t){const e=t.cloneNode(!0);return e.querySelectorAll(".gyos-target-spinner").forEach(t=>t.remove()),e}(e);let i=null,a=[],o=!1;if(c&&(function(t=document){ti&&(ti&&document.body&&!ti.isConnected&&document.body.appendChild(ti),ei(t).forEach(t=>{if(t===ti||ti.contains(t))return;const e=Zr(t,!0);e&&(Qr.set(e,t),ti.appendChild(t))}))}(e),function(t){As(t)}(e)),k)if(t.replace){const t=Pi(!1);history.replaceState({...history.state||{},gyos:!0,gyosEntryId:t},"",_)}else{const t=Pi(!1),e=Ti(),n=history.state||{};history.replaceState({...n,gyos:!0,gyosEntryId:t,gyosRoutes:{...n.gyosRoutes||{},[e]:f}},""),history.pushState({gyos:!0,gyosEntryId:e,gyosRoutes:{[t]:f}},"",_),r&&(Ni(t,e,r),i={currentEntryId:t,nextEntryId:e}),gi=e}try{e=await async function(t,e,n,s={}){const r=(n||"inner").toLowerCase(),i=document.importNode(e,!0),a=Array.from(i.childNodes);let o;if("replace"===r)Se(),t.replaceWith(i),o=i;else if("morph"===r)Se(),t.tagName!==i.tagName?(t.replaceWith(i),o=i):(function(t,e){const n=t=>t instanceof Element&&!!t.closest("[g-persist]"),s=t=>t?.nodeType===Node.COMMENT_NODE&&!!t.nodeValue?.includes("g-persist:"),r=t=>{if(t instanceof Element)return t.getAttribute("g-persist")||null;if(s(t)){const e=t.nodeValue.match(/g-persist:(\S+)/);return e?e[1]:null}return null},i=t=>`${t.tagName}|${t.id||""}|${t.dataset.gyosPersistId||""}|${t.dataset.gyosKey||""}`,a=t=>{if(!(t instanceof HTMLElement))return null;const{id:e,dataset:n}=t;return e||n.gyosPersistId||n.gyosKey?i(t):null},o=(t,e)=>{if(!t||!e)return;if(t===e)return;if(t.nodeType===Node.TEXT_NODE&&e.nodeType===Node.TEXT_NODE)return void(t.textContent!==e.textContent&&(t.textContent=e.textContent));if(!(t instanceof Element&&e instanceof Element))return void t.replaceWith(e.cloneNode(!0));if(n(t)||n(e))return;if(t.tagName!==e.tagName)return void t.replaceWith(e.cloneNode(!0));const c=(t=>{if(t instanceof HTMLInputElement){const e="checkbox"===t.type||"radio"===t.type,n="file"!==t.type&&t.value!==t.defaultValue,s=e&&t.checked!==t.defaultChecked;return n||s?{kind:"input",type:t.type,value:n?t.value:void 0,checked:s?t.checked:void 0}:null}if(t instanceof HTMLSelectElement){const e=Array.from(t.options);return e.some(t=>t.selected!==t.defaultSelected)?{kind:"select",values:e.filter(t=>t.selected).map(t=>t.value)}:null}return t instanceof HTMLTextAreaElement&&t.value!==t.defaultValue?{kind:"textarea",value:t.value}:null})(t);ni(t,e);const l=t=>Array.from(t).filter(t=>!(t.nodeType===Node.TEXT_NODE&&""===(t.textContent||"").trim())),u=l(e.childNodes);let h=l(t.childNodes);const p=new Map;h.forEach(t=>{const e=r(t);e&&p.set(e,t)});let f=0;for(;f<u.length||f<h.length;){const e=u[f]||null;let c=h[f]||null;const d=a(e);if(d&&a(c)!==d){const n=h.findIndex((t,e)=>e>f&&a(t)===d);-1!==n?(t.insertBefore(h[n],c),h=l(t.childNodes),c=h[f]||null):e&&(t.insertBefore(e.cloneNode(!0),c),h=l(t.childNodes),c=h[f]||null)}const m=r(e),g=r(c);if(m){if(p.get(m)){f++;continue}t.insertBefore(e.cloneNode(!0),c||null),h=l(t.childNodes),f++;continue}if(g){f++;continue}if(!c&&e){t.appendChild(e.cloneNode(!0)),h=l(t.childNodes),f++;continue}if(c&&!e){if(!n(c)&&!s(c)){c.remove(),h=l(t.childNodes);continue}f++;continue}if(!c||!e){f++;continue}const y=c instanceof Element?i(c):"",v=e instanceof Element?i(e):"";y&&v&&y===v?(o(c,e),f++):y||v||c.nodeType!==e.nodeType?(n(c)||s(c)||(c.replaceWith(e.cloneNode(!0)),h=l(t.childNodes)),f++):(o(c,e),f++)}((t,e)=>{if(e){if("input"===e.kind&&t instanceof HTMLInputElement){if(t.type!==e.type)return;return void 0!==e.value&&(t.value=e.value),void(void 0!==e.checked&&(t.checked=e.checked))}if("select"===e.kind&&t instanceof HTMLSelectElement){const n=new Set(e.values);return void((0===n.size||Array.from(t.options).some(t=>n.has(t.value)))&&Array.from(t.options).forEach(t=>{t.selected=n.has(t.value)}))}"textarea"===e.kind&&t instanceof HTMLTextAreaElement&&(t.value=e.value)}})(t,c)};o(t,e)}(t,i),o=t);else if("append"===r)Se(),t.append(...a),o=t;else if("prepend"===r)Se(),t.prepend(...a),o=t;else{for(Se(),s.syncRootAttributes&&ni(t,i),t.replaceChildren();i.firstChild;)t.appendChild(i.firstChild);o=t}return await(s.beforeScripts?.()),s.onCommitted?.(o,"append"===r||"prepend"===r?a:[o]),"append"===r||"prepend"===r?await Kr(a,s.signal):await async function(t,e){await Kr([t],e)}(o,s.signal),o}(e,b,n,{syncRootAttributes:l,signal:s.controller.signal,beforeScripts:async()=>{if(!l||p)return;const t=x.querySelector("title");t&&(document.title=t.textContent||document.title),await async function(t,e){const n="meta, link, style:not(#gyos-transitions), script",s=Array.from(document.head.querySelectorAll(n)),r=Array.from(t.head.querySelectorAll(n));await ii(s,r,document.head,e)}(x,s.controller.signal),Vi(s)},onCommitted:(t,n)=>{e=t,a=n}}),Vi(s),l&&(await async function(t,e,n,s){const r=Array.from(document.scripts).filter(t=>!e.contains(t)&&!document.head.contains(t)),i=Array.from(t.scripts).filter(e=>!n.contains(e)&&!t.head.contains(e));await ii(r,i,document.body,s)}(x,e,b,s.controller.signal),Vi(s))}finally{(()=>{if(o)return;o=!0;const t=a.filter(t=>t instanceof HTMLElement&&t.isConnected);!function(t){if(!Qr.size)return;if(1===Qr.size){const e=Array.from(Qr.keys())[0];ei(t).forEach(t=>{Zr(t,!1)||(t.dataset.gyosPersistId=e)})}ei(t).forEach(t=>{const e=Zr(t,!1);if(!e)return;const n=Qr.get(e);n?(t.replaceWith(n),Qr.delete(e)):t.dataset.gyosPersistId=e});const e=document.createTreeWalker(t,NodeFilter.SHOW_COMMENT,null),n=[];for(;e.nextNode();){const t=e.currentNode,s=t.data.match(/g-persist[:=]\s*([A-Za-z0-9_\-:.]+)/);s&&n.push({node:t,key:s[1]})}n.forEach(({node:t,key:e})=>{const n=Qr.get(e);n&&(t.replaceWith(n),Qr.delete(e))})}(e),i&&Ni(i.nextEntryId,i.currentEntryId,e),cr(t.length>0?t:void 0)})()}if(k)si(_,t.trigger);else if(t.popstate)si(_,t.trigger,t.savedScroll);else{const e=history.state;si(_,t.trigger,e?.scroll)}};if(document.startViewTransition){const t=document.startViewTransition(()=>C());Ri(t?.ready),Ri(t?.finished),t?.updateCallbackDone&&await t.updateCallbackDone}else await C();Vi(s),o&&t.trigger instanceof HTMLElement&&t.trigger.isConnected&&(As(t.trigger),t.trigger.remove()),r&&Br(s.spinner),s.spinner=null,Di(bi,_),Se(),mi=Ii(k?_:window.location.href,!0),t.popstate&&t.historyEntryId&&(gi=t.historyEntryId)}catch(e){if("AbortError"===e.name)return void Se();Mi(s)&&Bi(t,t.url,!0)}finally{s.interval&&clearInterval(s.interval),s.spinner&&Br(s.spinner),yi?.id===s.id&&(yi=null,vi?.complete()),s.resolveDone()}var a}function ji(t){if(t.defaultPrevented)return;if(0!==t.button)return;if(t.metaKey||t.ctrlKey||t.shiftKey||t.altKey)return;const e=t.target;if(!e)return;const n=e.closest("[g-router-link]");if(n){if(n.closest("[g-no-boost]"))return;return t.preventDefault(),void function(t){Se();const e=t.getAttribute("g-router-link"),n=t.getAttribute("g-router-method")||"GET";if(!e||!["GET","POST","PUT","DELETE","PATCH"].includes(n.toUpperCase()))return;let s;try{s=new URL(e,window.location.href)}catch{return}if(s.origin===window.location.origin)try{const e=un(t),r=nn(decodeURIComponent(t.getAttribute("g-router-params")||""),e,!1);Ui({url:s.toString(),method:n,trigger:t,jsonData:r,changeState:!1})}catch(t){return}}(n)}const s=e.closest("a");if(!s)return;const r=s.getAttribute("href");if(!r)return;const i=new URL(r,window.location.href);var a;i.origin===window.location.origin&&(i.hash&&Ii(i.href)===Ii(window.location.href)||s.closest("[g-no-boost]")||s.hasAttribute("download")||s.getAttribute("target")&&"_self"!==s.getAttribute("target")||(a=s).closest("[g-no-boost]")||!a.hasAttribute("g-boost")&&!Si()||(t.preventDefault(),Ui({url:i.toString(),method:"GET",trigger:s,changeState:!0})))}function Wi(t){const e=t.target;if(!e)return;const n=e.closest("a[g-preload]");if(!n)return;const s=n.getAttribute("href");if(!s)return;const r=new URL(s,window.location.href);r.origin===window.location.origin&&function(t){const e=Ii(t,!0);if(oi.has(e))return;Se();const n=new AbortController,s=fetch(e,{headers:{"X-Gyos-Boost":"1",Accept:"text/html,application/xhtml+xml"},signal:n.signal,mode:"same-origin"});oi.set(e,s),ci.set(e,n),s.catch(()=>{oi.delete(e),ci.delete(e)})}(r.toString())}function $i(t){if(t.defaultPrevented)return;const e=t.target;if(!e||"form"!==e.tagName.toLowerCase())return;if(e.closest("[g-no-boost]"))return;if(!e.hasAttribute("g-boost")&&!Si())return;if(function(t){return!(!hs.has(t)||ps.has(t)&&(ps.delete(t),1))}(e))return;t.preventDefault();const n=e.action||window.location.href,s=(e.method||"GET").toUpperCase(),r=new URL(n,window.location.href);if(r.origin!==window.location.origin)return void(window.location.href=r.toString());const i=new FormData(e);Ui({url:r.toString(),method:s,trigger:e,form:e,formData:i,changeState:"GET"===s})}function qi(t){const e=window.location.href,n=gi,s=t.state||{},r=s.gyosEntryId||null,i=n?s.gyosRoutes?.[n]:void 0;if(Ii(e)===Ii(mi)&&(!r||r===n))return mi=Ii(e,!0),void(gi=r||n);t.preventDefault(),yi?.committing&&Oi(yi),gi=r,Ui({url:e,method:"GET",replace:!0,changeState:!1,popstate:!0,savedScroll:(r?li.get(r):void 0)||s.scroll,targetSelector:i?.targetSelector,targetOutletIndex:i?.targetOutletIndex,swapMode:i?.swapMode,currentHead:i?.currentHead,historyFragment:n&&r?Li(r,n):void 0,historyEntryId:r,scrollSourceEntryId:n})}const Hi={scope:ar,mount:ur,mountAll:cr,mountTree:lr,cleanup:As,mountedScopes:cn,markRaw:Ws,shallow:Hs,directive:Nn,pipe:Ze,provide:Ke,inject:Je,getGlobalContainer:Qe,store:mr,hasStore:gr,removeStore:yr,getStoreNames:vr,on:br,emit:_r,off:wr,once:Er,getEventListeners:Sr,clearAllEvents:kr,validator:os,validate:us,getValidator:cs,getValidatorNames:ls,signal:Re,computed:De,effect:Fe,batch:Be,isSignal:Ue,isComputed:We,unref:$e,untrack:qe,registerTransition:On,getTransitionConfig:Dn,useFetch:Cr,useCounter:Ar,useToggle:Ir,useLocalStorage:Tr,useInterval:Pr,useTimeout:Nr,useDebounce:Lr,useThrottle:Mr,useMouse:Vr,useWindowSize:Or,useMediaQuery:Rr,useAsync:Dr,nextTick:he,debounce:fe,throttle:de,ready:pe,applyDirective:Ln,applyTransitionStyles:Fn,startRouter:Ei,onBeforeNavigate:_i,onAfterNavigate:wi,portalCreate:rs,portalDestroy:is,setCspNonce:jr,version:"0.3.0"};ce=oe,t.applyDirective=Ln,t.applyTransitionStyles=Fn,t.batch=Be,t.cleanup=As,t.clearAllEvents=kr,t.computed=De,t.debounce=fe,t.default=Hi,t.directive=Nn,t.effect=Fe,t.emit=_r,t.getEventListeners=Sr,t.getGlobalContainer=Qe,t.getStoreNames=vr,t.getTransitionConfig=Dn,t.getValidator=cs,t.getValidatorNames=ls,t.hasStore=gr,t.inject=Je,t.isComputed=We,t.isSignal=Ue,t.markRaw=Ws,t.mount=ur,t.mountAll=cr,t.mountTree=lr,t.mountedScopes=cn,t.nextTick=he,t.off=wr,t.on=br,t.onAfterNavigate=wi,t.onBeforeNavigate=_i,t.once=Er,t.pipe=Ze,t.portalCreate=rs,t.portalDestroy=is,t.provide=Ke,t.ready=pe,t.registerTransition=On,t.removeStore=yr,t.scope=ar,t.setCspNonce=jr,t.shallow=Hs,t.signal=Re,t.startRouter=Ei,t.store=mr,t.throttle=de,t.unref=$e,t.untrack=qe,t.useAsync=Dr,t.useCounter=Ar,t.useDebounce=Lr,t.useFetch=Cr,t.useInterval=Pr,t.useLocalStorage=Tr,t.useMediaQuery=Rr,t.useMouse=Vr,t.useThrottle=Mr,t.useTimeout=Nr,t.useToggle=Ir,t.useWindowSize=Or,t.validate=us,t.validator=os,Object.defineProperty(t,"__esModule",{value:!0})},"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).Gyos={});
|
|
6
|
+
var t,e;t=this,e=function(t){"use strict";var e=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,7,9,32,4,318,1,80,3,71,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,3,0,158,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,68,8,2,0,3,0,2,3,2,4,2,0,15,1,83,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,7,19,58,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,343,9,54,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,10,1,2,0,49,6,4,4,14,10,5350,0,7,14,11465,27,2343,9,87,9,39,4,60,6,26,9,535,9,470,0,2,54,8,3,82,0,12,1,19628,1,4178,9,519,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,101,0,161,6,10,9,357,0,62,13,499,13,245,1,2,9,726,6,110,6,6,9,4759,9,787719,239],n=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,4,51,13,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,39,27,10,22,251,41,7,1,17,2,60,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,20,1,64,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,31,9,2,0,3,0,2,37,2,0,26,0,2,0,45,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,200,32,32,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,16,0,2,12,2,33,125,0,80,921,103,110,18,195,2637,96,16,1071,18,5,26,3994,6,582,6842,29,1763,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,433,44,212,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,42,9,8936,3,2,6,2,1,2,290,16,0,30,2,3,0,15,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,7,5,262,61,147,44,11,6,17,0,322,29,19,43,485,27,229,29,3,0,496,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4153,7,221,3,5761,15,7472,16,621,2467,541,1507,4938,6,4191],s="ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢎࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೝೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-Ა-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-Ꟑꟑꟓꟕ-ꟲ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",r={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"},i="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",a={5:i,"5module":i+" export import",6:i+" const class extends export import super"},o=/^in(stanceof)?$/,c=RegExp("["+s+"]"),l=RegExp("["+s+"·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ-ᫎᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・]");function u(t,e){for(var n=65536,s=0;s<e.length;s+=2){if((n+=e[s])>t)return!1;if((n+=e[s+1])>=t)return!0}return!1}function h(t,e){return 65>t?36===t:91>t||(97>t?95===t:123>t||(t>65535?!1!==e&&u(t,n):t>=170&&c.test(String.fromCharCode(t))))}function p(t,s){return 48>t?36===t:58>t||t>=65&&(91>t||(97>t?95===t:123>t||(t>65535?!1!==s&&(u(t,n)||u(t,e)):t>=170&&l.test(String.fromCharCode(t)))))}var f=function(t,e){void 0===e&&(e={}),this.label=t,this.keyword=e.keyword,this.beforeExpr=!!e.beforeExpr,this.startsExpr=!!e.startsExpr,this.isLoop=!!e.isLoop,this.isAssign=!!e.isAssign,this.prefix=!!e.prefix,this.postfix=!!e.postfix,this.binop=e.binop||null,this.updateContext=null};function d(t,e){return new f(t,{beforeExpr:!0,binop:e})}var m={beforeExpr:!0},g={startsExpr:!0},y={};function v(t,e){return void 0===e&&(e={}),e.keyword=t,y[t]=new f(t,e)}var x={num:new f("num",g),regexp:new f("regexp",g),string:new f("string",g),name:new f("name",g),privateId:new f("privateId",g),eof:new f("eof"),bracketL:new f("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new f("]"),braceL:new f("{",{beforeExpr:!0,startsExpr:!0}),braceR:new f("}"),parenL:new f("(",{beforeExpr:!0,startsExpr:!0}),parenR:new f(")"),comma:new f(",",m),semi:new f(";",m),colon:new f(":",m),dot:new f("."),question:new f("?",m),questionDot:new f("?."),arrow:new f("=>",m),template:new f("template"),invalidTemplate:new f("invalidTemplate"),ellipsis:new f("...",m),backQuote:new f("`",g),dollarBraceL:new f("${",{beforeExpr:!0,startsExpr:!0}),eq:new f("=",{beforeExpr:!0,isAssign:!0}),assign:new f("_=",{beforeExpr:!0,isAssign:!0}),incDec:new f("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new f("!/~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:d("||",1),logicalAND:d("&&",2),bitwiseOR:d("|",3),bitwiseXOR:d("^",4),bitwiseAND:d("&",5),equality:d("==/!=/===/!==",6),relational:d("</>/<=/>=",7),bitShift:d("<</>>/>>>",8),plusMin:new f("+/-",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:d("%",10),star:d("*",10),slash:d("/",10),starstar:new f("**",{beforeExpr:!0}),coalesce:d("??",1),_break:v("break"),_case:v("case",m),_catch:v("catch"),_continue:v("continue"),_debugger:v("debugger"),_default:v("default",m),_do:v("do",{isLoop:!0,beforeExpr:!0}),_else:v("else",m),_finally:v("finally"),_for:v("for",{isLoop:!0}),_function:v("function",g),_if:v("if"),_return:v("return",m),_switch:v("switch"),_throw:v("throw",m),_try:v("try"),_var:v("var"),_const:v("const"),_while:v("while",{isLoop:!0}),_with:v("with"),_new:v("new",{beforeExpr:!0,startsExpr:!0}),_this:v("this",g),_super:v("super",g),_class:v("class",g),_extends:v("extends",m),_export:v("export"),_import:v("import",g),_null:v("null",g),_true:v("true",g),_false:v("false",g),_in:v("in",{beforeExpr:!0,binop:7}),_instanceof:v("instanceof",{beforeExpr:!0,binop:7}),_typeof:v("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:v("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:v("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})},b=/\r\n?|\n|\u2028|\u2029/,_=RegExp(b.source,"g");function w(t){return 10===t||13===t||8232===t||8233===t}function E(t,e,n){void 0===n&&(n=t.length);for(var s=e;n>s;s++){var r=t.charCodeAt(s);if(w(r))return n-1>s&&13===r&&10===t.charCodeAt(s+1)?s+2:s+1}return-1}var S=/[\u1680\u2000-\u200a\u202f\u205f\u3000\ufeff]/,k=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g,C=Object.prototype,A=C.hasOwnProperty,I=C.toString,T=Object.hasOwn||function(t,e){return A.call(t,e)},N=Array.isArray||function(t){return"[object Array]"===I.call(t)},P=Object.create(null);function L(t){return P[t]||(P[t]=RegExp("^(?:"+t.replace(/ /g,"|")+")$"))}function M(t){return t>65535?(t-=65536,String.fromCharCode(55296+(t>>10),56320+(1023&t))):String.fromCharCode(t)}var V=/(?:[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])/,O=function(t,e){this.line=t,this.column=e};O.prototype.offset=function(t){return new O(this.line,this.column+t)};var R=function(t,e,n){this.start=e,this.end=n,null!==t.sourceFile&&(this.source=t.sourceFile)};function D(t,e){for(var n=1,s=0;;){var r=E(t,s,e);if(0>r)return new O(n,e-s);++n,s=r}}var F={ecmaVersion:null,sourceType:"script",onInsertedSemicolon:null,onTrailingComma:null,allowReserved:null,allowReturnOutsideFunction:!1,allowImportExportEverywhere:!1,allowAwaitOutsideFunction:null,allowSuperOutsideMethod:null,allowHashBang:!1,checkPrivateFields:!0,locations:!1,onToken:null,onComment:null,ranges:!1,program:null,sourceFile:null,directSourceFile:null,preserveParens:!1},B=!1;function U(t,e){return 2|(t?4:0)|(e?8:0)}var j=function(t,e,n){this.options=t=function(t){var e={};for(var n in F)e[n]=t&&T(t,n)?t[n]:F[n];if("latest"===e.ecmaVersion?e.ecmaVersion=1e8:null==e.ecmaVersion?(!B&&"object"==typeof console&&console.warn&&(B=!0),e.ecmaVersion=11):2015>e.ecmaVersion||(e.ecmaVersion-=2009),null==e.allowReserved&&(e.allowReserved=5>e.ecmaVersion),t&&null!=t.allowHashBang||(e.allowHashBang=e.ecmaVersion>=14),N(e.onToken)){var s=e.onToken;e.onToken=function(t){return s.push(t)}}return N(e.onComment)&&(e.onComment=function(t,e){return function(n,s,r,i,a,o){var c={type:n?"Block":"Line",value:s,start:r,end:i};t.locations&&(c.loc=new R(this,a,o)),t.ranges&&(c.range=[r,i]),e.push(c)}}(e,e.onComment)),e}(t),this.sourceFile=t.sourceFile,this.keywords=L(a[6>t.ecmaVersion?"module"===t.sourceType?"5module":5:6]);var s="";!0!==t.allowReserved&&(s=r[6>t.ecmaVersion?5===t.ecmaVersion?5:3:6],"module"===t.sourceType&&(s+=" await")),this.reservedWords=L(s);var i=(s?s+" ":"")+r.strict;this.reservedWordsStrict=L(i),this.reservedWordsStrictBind=L(i+" "+r.strictBind),this.input=e+"",this.containsEsc=!1,n?(this.pos=n,this.lineStart=this.input.lastIndexOf("\n",n-1)+1,this.curLine=this.input.slice(0,this.lineStart).split(b).length):(this.pos=this.lineStart=0,this.curLine=1),this.type=x.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"===t.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&&t.allowHashBang&&"#!"===this.input.slice(0,2)&&this.skipLineComment(2),this.scopeStack=[],this.enterScope(1),this.regexpState=null,this.privateNameStack=[]},W={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}};j.prototype.parse=function(){var t=this.options.program||this.startNode();return this.nextToken(),this.parseTopLevel(t)},W.inFunction.get=function(){return(2&this.currentVarScope().flags)>0},W.inGenerator.get=function(){return(8&this.currentVarScope().flags)>0},W.inAsync.get=function(){return(4&this.currentVarScope().flags)>0},W.canAwait.get=function(){for(var t=this.scopeStack.length-1;t>=0;t--){var e=this.scopeStack[t].flags;if(768&e)return!1;if(2&e)return(4&e)>0}return this.inModule&&this.options.ecmaVersion>=13||this.options.allowAwaitOutsideFunction},W.allowSuper.get=function(){return(64&this.currentThisScope().flags)>0||this.options.allowSuperOutsideMethod},W.allowDirectSuper.get=function(){return(128&this.currentThisScope().flags)>0},W.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())},W.allowNewDotTarget.get=function(){for(var t=this.scopeStack.length-1;t>=0;t--){var e=this.scopeStack[t].flags;if(768&e||2&e&&!(16&e))return!0}return!1},W.inClassStaticBlock.get=function(){return(256&this.currentVarScope().flags)>0},j.extend=function(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];for(var n=this,s=0;s<t.length;s++)n=t[s](n);return n},j.parse=function(t,e){return new this(e,t).parse()},j.parseExpressionAt=function(t,e,n){var s=new this(n,t,e);return s.nextToken(),s.parseExpression()},j.tokenizer=function(t,e){return new this(e,t)},Object.defineProperties(j.prototype,W);var $=j.prototype,q=/^(?:'((?:\\[^]|[^'\\])*?)'|"((?:\\[^]|[^"\\])*?)")/;$.strictDirective=function(t){if(5>this.options.ecmaVersion)return!1;for(;;){k.lastIndex=t,t+=k.exec(this.input)[0].length;var e=q.exec(this.input.slice(t));if(!e)return!1;if("use strict"===(e[1]||e[2])){k.lastIndex=t+e[0].length;var n=k.exec(this.input),s=n.index+n[0].length,r=this.input.charAt(s);return";"===r||"}"===r||b.test(n[0])&&!(/[(`.[+\-/*%<>=,?^&]/.test(r)||"!"===r&&"="===this.input.charAt(s+1))}t+=e[0].length,k.lastIndex=t,t+=k.exec(this.input)[0].length,";"===this.input[t]&&t++}},$.eat=function(t){return this.type===t&&(this.next(),!0)},$.isContextual=function(t){return this.type===x.name&&this.value===t&&!this.containsEsc},$.eatContextual=function(t){return!!this.isContextual(t)&&(this.next(),!0)},$.expectContextual=function(t){this.eatContextual(t)||this.unexpected()},$.canInsertSemicolon=function(){return this.type===x.eof||this.type===x.braceR||b.test(this.input.slice(this.lastTokEnd,this.start))},$.insertSemicolon=function(){if(this.canInsertSemicolon())return this.options.onInsertedSemicolon&&this.options.onInsertedSemicolon(this.lastTokEnd,this.lastTokEndLoc),!0},$.semicolon=function(){this.eat(x.semi)||this.insertSemicolon()||this.unexpected()},$.afterTrailingComma=function(t,e){if(this.type===t)return this.options.onTrailingComma&&this.options.onTrailingComma(this.lastTokStart,this.lastTokStartLoc),e||this.next(),!0},$.expect=function(t){this.eat(t)||this.unexpected()},$.unexpected=function(t){this.raise(null!=t?t:this.start,"Unexpected token")};var H=function(){this.shorthandAssign=this.trailingComma=this.parenthesizedAssign=this.parenthesizedBind=this.doubleProto=-1};$.checkPatternErrors=function(t,e){if(t){t.trailingComma>-1&&this.raiseRecoverable(t.trailingComma,"Comma is not permitted after the rest element");var n=e?t.parenthesizedAssign:t.parenthesizedBind;n>-1&&this.raiseRecoverable(n,e?"Assigning to rvalue":"Parenthesized pattern")}},$.checkExpressionErrors=function(t,e){if(!t)return!1;var n=t.shorthandAssign,s=t.doubleProto;if(!e)return n>=0||s>=0;0>n||this.raise(n,"Shorthand property assignments are valid only in destructuring patterns"),0>s||this.raiseRecoverable(s,"Redefinition of __proto__ property")},$.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")},$.isSimpleAssignTarget=function(t){return"ParenthesizedExpression"===t.type?this.isSimpleAssignTarget(t.expression):"Identifier"===t.type||"MemberExpression"===t.type};var G=j.prototype;G.parseTopLevel=function(t){var e=Object.create(null);for(t.body||(t.body=[]);this.type!==x.eof;){var n=this.parseStatement(null,!0,e);t.body.push(n)}if(this.inModule)for(var s=0,r=Object.keys(this.undefinedExports);s<r.length;s+=1){var i=r[s];this.raiseRecoverable(this.undefinedExports[i].start,"Export '"+i+"' is not defined")}return this.adaptDirectivePrologue(t.body),this.next(),t.sourceType=this.options.sourceType,this.finishNode(t,"Program")};var z={kind:"loop"},Y={kind:"switch"};G.isLet=function(t){if(6>this.options.ecmaVersion||!this.isContextual("let"))return!1;k.lastIndex=this.pos;var e=k.exec(this.input),n=this.pos+e[0].length,s=this.input.charCodeAt(n);if(91===s||92===s)return!0;if(t)return!1;if(123===s||s>55295&&56320>s)return!0;if(h(s,!0)){for(var r=n+1;p(s=this.input.charCodeAt(r),!0);)++r;if(92===s||s>55295&&56320>s)return!0;var i=this.input.slice(n,r);if(!o.test(i))return!0}return!1},G.isAsyncFunction=function(){if(8>this.options.ecmaVersion||!this.isContextual("async"))return!1;k.lastIndex=this.pos;var t,e=k.exec(this.input),n=this.pos+e[0].length;return!(b.test(this.input.slice(this.pos,n))||"function"!==this.input.slice(n,n+8)||n+8!==this.input.length&&(p(t=this.input.charCodeAt(n+8))||t>55295&&56320>t))},G.isUsingKeyword=function(t,e){if(17>this.options.ecmaVersion||!this.isContextual(t?"await":"using"))return!1;k.lastIndex=this.pos;var n=k.exec(this.input),s=this.pos+n[0].length;if(b.test(this.input.slice(this.pos,s)))return!1;if(t){var r,i=s+5;if("using"!==this.input.slice(s,i)||i===this.input.length||p(r=this.input.charCodeAt(i))||r>55295&&56320>r)return!1;k.lastIndex=i;var a=k.exec(this.input);if(a&&b.test(this.input.slice(i,i+a[0].length)))return!1}if(e){var o,c=s+2;if(!("of"!==this.input.slice(s,c)||c!==this.input.length&&(p(o=this.input.charCodeAt(c))||o>55295&&56320>o)))return!1}var l=this.input.charCodeAt(s);return h(l,!0)||92===l},G.isAwaitUsing=function(t){return this.isUsingKeyword(!0,t)},G.isUsing=function(t){return this.isUsingKeyword(!1,t)},G.parseStatement=function(t,e,n){var s,r=this.type,i=this.startNode();switch(this.isLet(t)&&(r=x._var,s="let"),r){case x._break:case x._continue:return this.parseBreakContinueStatement(i,r.keyword);case x._debugger:return this.parseDebuggerStatement(i);case x._do:return this.parseDoStatement(i);case x._for:return this.parseForStatement(i);case x._function:return t&&(this.strict||"if"!==t&&"label"!==t)&&this.options.ecmaVersion>=6&&this.unexpected(),this.parseFunctionStatement(i,!1,!t);case x._class:return t&&this.unexpected(),this.parseClass(i,!0);case x._if:return this.parseIfStatement(i);case x._return:return this.parseReturnStatement(i);case x._switch:return this.parseSwitchStatement(i);case x._throw:return this.parseThrowStatement(i);case x._try:return this.parseTryStatement(i);case x._const:case x._var:return s=s||this.value,t&&"var"!==s&&this.unexpected(),this.parseVarStatement(i,s);case x._while:return this.parseWhileStatement(i);case x._with:return this.parseWithStatement(i);case x.braceL:return this.parseBlock(!0,i);case x.semi:return this.parseEmptyStatement(i);case x._export:case x._import:if(this.options.ecmaVersion>10&&r===x._import){k.lastIndex=this.pos;var a=k.exec(this.input),o=this.pos+a[0].length,c=this.input.charCodeAt(o);if(40===c||46===c)return this.parseExpressionStatement(i,this.parseExpression())}return this.options.allowImportExportEverywhere||(e||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'")),r===x._import?this.parseImport(i):this.parseExport(i,n);default:if(this.isAsyncFunction())return t&&this.unexpected(),this.next(),this.parseFunctionStatement(i,!0,!t);var l=this.isAwaitUsing(!1)?"await using":this.isUsing(!1)?"using":null;if(l)return e&&"script"===this.options.sourceType&&this.raise(this.start,"Using declaration cannot appear in the top level when source type is `script`"),"await using"===l&&(this.canAwait||this.raise(this.start,"Await using cannot appear outside of async function"),this.next()),this.next(),this.parseVar(i,!1,l),this.semicolon(),this.finishNode(i,"VariableDeclaration");var u=this.value,h=this.parseExpression();return r===x.name&&"Identifier"===h.type&&this.eat(x.colon)?this.parseLabeledStatement(i,u,h,t):this.parseExpressionStatement(i,h)}},G.parseBreakContinueStatement=function(t,e){var n="break"===e;this.next(),this.eat(x.semi)||this.insertSemicolon()?t.label=null:this.type!==x.name?this.unexpected():(t.label=this.parseIdent(),this.semicolon());for(var s=0;s<this.labels.length;++s){var r=this.labels[s];if(null==t.label||r.name===t.label.name){if(null!=r.kind&&(n||"loop"===r.kind))break;if(t.label&&n)break}}return s===this.labels.length&&this.raise(t.start,"Unsyntactic "+e),this.finishNode(t,n?"BreakStatement":"ContinueStatement")},G.parseDebuggerStatement=function(t){return this.next(),this.semicolon(),this.finishNode(t,"DebuggerStatement")},G.parseDoStatement=function(t){return this.next(),this.labels.push(z),t.body=this.parseStatement("do"),this.labels.pop(),this.expect(x._while),t.test=this.parseParenExpression(),6>this.options.ecmaVersion?this.semicolon():this.eat(x.semi),this.finishNode(t,"DoWhileStatement")},G.parseForStatement=function(t){this.next();var e=this.options.ecmaVersion>=9&&this.canAwait&&this.eatContextual("await")?this.lastTokStart:-1;if(this.labels.push(z),this.enterScope(0),this.expect(x.parenL),this.type===x.semi)return e>-1&&this.unexpected(e),this.parseFor(t,null);var n=this.isLet();if(this.type===x._var||this.type===x._const||n){var s=this.startNode(),r=n?"let":this.value;return this.next(),this.parseVar(s,!0,r),this.finishNode(s,"VariableDeclaration"),this.parseForAfterInit(t,s,e)}var i=this.isContextual("let"),a=!1,o=this.isUsing(!0)?"using":this.isAwaitUsing(!0)?"await using":null;if(o){var c=this.startNode();return this.next(),"await using"===o&&this.next(),this.parseVar(c,!0,o),this.finishNode(c,"VariableDeclaration"),this.parseForAfterInit(t,c,e)}var l=this.containsEsc,u=new H,h=this.start,p=e>-1?this.parseExprSubscripts(u,"await"):this.parseExpression(!0,u);return this.type===x._in||(a=this.options.ecmaVersion>=6&&this.isContextual("of"))?(e>-1?(this.type===x._in&&this.unexpected(e),t.await=!0):a&&this.options.ecmaVersion>=8&&(p.start!==h||l||"Identifier"!==p.type||"async"!==p.name?9>this.options.ecmaVersion||(t.await=!1):this.unexpected()),i&&a&&this.raise(p.start,"The left-hand side of a for-of loop may not start with 'let'."),this.toAssignable(p,!1,u),this.checkLValPattern(p),this.parseForIn(t,p)):(this.checkExpressionErrors(u,!0),e>-1&&this.unexpected(e),this.parseFor(t,p))},G.parseForAfterInit=function(t,e,n){return(this.type===x._in||this.options.ecmaVersion>=6&&this.isContextual("of"))&&1===e.declarations.length?(9>this.options.ecmaVersion||(this.type===x._in?n>-1&&this.unexpected(n):t.await=n>-1),this.parseForIn(t,e)):(n>-1&&this.unexpected(n),this.parseFor(t,e))},G.parseFunctionStatement=function(t,e,n){return this.next(),this.parseFunction(t,J|(n?0:Q),!1,e)},G.parseIfStatement=function(t){return this.next(),t.test=this.parseParenExpression(),t.consequent=this.parseStatement("if"),t.alternate=this.eat(x._else)?this.parseStatement("if"):null,this.finishNode(t,"IfStatement")},G.parseReturnStatement=function(t){return this.inFunction||this.options.allowReturnOutsideFunction||this.raise(this.start,"'return' outside of function"),this.next(),this.eat(x.semi)||this.insertSemicolon()?t.argument=null:(t.argument=this.parseExpression(),this.semicolon()),this.finishNode(t,"ReturnStatement")},G.parseSwitchStatement=function(t){var e;this.next(),t.discriminant=this.parseParenExpression(),t.cases=[],this.expect(x.braceL),this.labels.push(Y),this.enterScope(0);for(var n=!1;this.type!==x.braceR;)if(this.type===x._case||this.type===x._default){var s=this.type===x._case;e&&this.finishNode(e,"SwitchCase"),t.cases.push(e=this.startNode()),e.consequent=[],this.next(),s?e.test=this.parseExpression():(n&&this.raiseRecoverable(this.lastTokStart,"Multiple default clauses"),n=!0,e.test=null),this.expect(x.colon)}else e||this.unexpected(),e.consequent.push(this.parseStatement(null));return this.exitScope(),e&&this.finishNode(e,"SwitchCase"),this.next(),this.labels.pop(),this.finishNode(t,"SwitchStatement")},G.parseThrowStatement=function(t){return this.next(),b.test(this.input.slice(this.lastTokEnd,this.start))&&this.raise(this.lastTokEnd,"Illegal newline after throw"),t.argument=this.parseExpression(),this.semicolon(),this.finishNode(t,"ThrowStatement")};var K=[];G.parseCatchClauseParam=function(){var t=this.parseBindingAtom(),e="Identifier"===t.type;return this.enterScope(e?32:0),this.checkLValPattern(t,e?4:2),this.expect(x.parenR),t},G.parseTryStatement=function(t){if(this.next(),t.block=this.parseBlock(),t.handler=null,this.type===x._catch){var e=this.startNode();this.next(),this.eat(x.parenL)?e.param=this.parseCatchClauseParam():(10>this.options.ecmaVersion&&this.unexpected(),e.param=null,this.enterScope(0)),e.body=this.parseBlock(!1),this.exitScope(),t.handler=this.finishNode(e,"CatchClause")}return t.finalizer=this.eat(x._finally)?this.parseBlock():null,t.handler||t.finalizer||this.raise(t.start,"Missing catch or finally clause"),this.finishNode(t,"TryStatement")},G.parseVarStatement=function(t,e,n){return this.next(),this.parseVar(t,!1,e,n),this.semicolon(),this.finishNode(t,"VariableDeclaration")},G.parseWhileStatement=function(t){return this.next(),t.test=this.parseParenExpression(),this.labels.push(z),t.body=this.parseStatement("while"),this.labels.pop(),this.finishNode(t,"WhileStatement")},G.parseWithStatement=function(t){return this.strict&&this.raise(this.start,"'with' in strict mode"),this.next(),t.object=this.parseParenExpression(),t.body=this.parseStatement("with"),this.finishNode(t,"WithStatement")},G.parseEmptyStatement=function(t){return this.next(),this.finishNode(t,"EmptyStatement")},G.parseLabeledStatement=function(t,e,n,s){for(var r=0,i=this.labels;r<i.length;r+=1)i[r].name===e&&this.raise(n.start,"Label '"+e+"' is already declared");for(var a=this.type.isLoop?"loop":this.type===x._switch?"switch":null,o=this.labels.length-1;o>=0;o--){var c=this.labels[o];if(c.statementStart!==t.start)break;c.statementStart=this.start,c.kind=a}return this.labels.push({name:e,kind:a,statementStart:this.start}),t.body=this.parseStatement(s?-1===s.indexOf("label")?s+"label":s:"label"),this.labels.pop(),t.label=n,this.finishNode(t,"LabeledStatement")},G.parseExpressionStatement=function(t,e){return t.expression=e,this.semicolon(),this.finishNode(t,"ExpressionStatement")},G.parseBlock=function(t,e,n){for(void 0===t&&(t=!0),void 0===e&&(e=this.startNode()),e.body=[],this.expect(x.braceL),t&&this.enterScope(0);this.type!==x.braceR;){var s=this.parseStatement(null);e.body.push(s)}return n&&(this.strict=!1),this.next(),t&&this.exitScope(),this.finishNode(e,"BlockStatement")},G.parseFor=function(t,e){return t.init=e,this.expect(x.semi),t.test=this.type===x.semi?null:this.parseExpression(),this.expect(x.semi),t.update=this.type===x.parenR?null:this.parseExpression(),this.expect(x.parenR),t.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(t,"ForStatement")},G.parseForIn=function(t,e){var n=this.type===x._in;return this.next(),"VariableDeclaration"!==e.type||null==e.declarations[0].init||n&&this.options.ecmaVersion>=8&&!this.strict&&"var"===e.kind&&"Identifier"===e.declarations[0].id.type||this.raise(e.start,(n?"for-in":"for-of")+" loop variable declaration may not have an initializer"),t.left=e,t.right=n?this.parseExpression():this.parseMaybeAssign(),this.expect(x.parenR),t.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(t,n?"ForInStatement":"ForOfStatement")},G.parseVar=function(t,e,n,s){for(t.declarations=[],t.kind=n;;){var r=this.startNode();if(this.parseVarId(r,n),this.eat(x.eq)?r.init=this.parseMaybeAssign(e):s||"const"!==n||this.type===x._in||this.options.ecmaVersion>=6&&this.isContextual("of")?s||"using"!==n&&"await using"!==n||17>this.options.ecmaVersion||this.type===x._in||this.isContextual("of")?s||"Identifier"===r.id.type||e&&(this.type===x._in||this.isContextual("of"))?r.init=null:this.raise(this.lastTokEnd,"Complex binding patterns require an initialization value"):this.raise(this.lastTokEnd,"Missing initializer in "+n+" declaration"):this.unexpected(),t.declarations.push(this.finishNode(r,"VariableDeclarator")),!this.eat(x.comma))break}return t},G.parseVarId=function(t,e){t.id="using"===e||"await using"===e?this.parseIdent():this.parseBindingAtom(),this.checkLValPattern(t.id,"var"===e?1:2,!1)};var J=1,Q=2;function X(t,e){var n=e.key.name,s=t[n],r="true";return"MethodDefinition"!==e.type||"get"!==e.kind&&"set"!==e.kind||(r=(e.static?"s":"i")+e.kind),"iget"===s&&"iset"===r||"iset"===s&&"iget"===r||"sget"===s&&"sset"===r||"sset"===s&&"sget"===r?(t[n]="true",!1):!!s||(t[n]=r,!1)}function Z(t,e){var n=t.computed,s=t.key;return!n&&("Identifier"===s.type&&s.name===e||"Literal"===s.type&&s.value===e)}G.parseFunction=function(t,e,n,s,r){this.initFunction(t),9>this.options.ecmaVersion&&(6>this.options.ecmaVersion||s)||(this.type===x.star&&e&Q&&this.unexpected(),t.generator=this.eat(x.star)),8>this.options.ecmaVersion||(t.async=!!s),e&J&&(t.id=4&e&&this.type!==x.name?null:this.parseIdent(),!t.id||e&Q||this.checkLValSimple(t.id,this.strict||t.generator||t.async?this.treatFunctionsAsVar?1:2:3));var i=this.yieldPos,a=this.awaitPos,o=this.awaitIdentPos;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(U(t.async,t.generator)),e&J||(t.id=this.type===x.name?this.parseIdent():null),this.parseFunctionParams(t),this.parseFunctionBody(t,n,!1,r),this.yieldPos=i,this.awaitPos=a,this.awaitIdentPos=o,this.finishNode(t,e&J?"FunctionDeclaration":"FunctionExpression")},G.parseFunctionParams=function(t){this.expect(x.parenL),t.params=this.parseBindingList(x.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()},G.parseClass=function(t,e){this.next();var n=this.strict;this.strict=!0,this.parseClassId(t,e),this.parseClassSuper(t);var s=this.enterClassBody(),r=this.startNode(),i=!1;for(r.body=[],this.expect(x.braceL);this.type!==x.braceR;){var a=this.parseClassElement(null!==t.superClass);a&&(r.body.push(a),"MethodDefinition"===a.type&&"constructor"===a.kind?(i&&this.raiseRecoverable(a.start,"Duplicate constructor in the same class"),i=!0):a.key&&"PrivateIdentifier"===a.key.type&&X(s,a)&&this.raiseRecoverable(a.key.start,"Identifier '#"+a.key.name+"' has already been declared"))}return this.strict=n,this.next(),t.body=this.finishNode(r,"ClassBody"),this.exitClassBody(),this.finishNode(t,e?"ClassDeclaration":"ClassExpression")},G.parseClassElement=function(t){if(this.eat(x.semi))return null;var e=this.options.ecmaVersion,n=this.startNode(),s="",r=!1,i=!1,a="method",o=!1;if(this.eatContextual("static")){if(e>=13&&this.eat(x.braceL))return this.parseClassStaticBlock(n),n;this.isClassElementNameStart()||this.type===x.star?o=!0:s="static"}if(n.static=o,s||8>e||!this.eatContextual("async")||(!this.isClassElementNameStart()&&this.type!==x.star||this.canInsertSemicolon()?s="async":i=!0),s||9>e&&i||!this.eat(x.star)||(r=!0),!s&&!i&&!r){var c=this.value;(this.eatContextual("get")||this.eatContextual("set"))&&(this.isClassElementNameStart()?a=c:s=c)}if(s?(n.computed=!1,n.key=this.startNodeAt(this.lastTokStart,this.lastTokStartLoc),n.key.name=s,this.finishNode(n.key,"Identifier")):this.parseClassElementName(n),13>e||this.type===x.parenL||"method"!==a||r||i){var l=!n.static&&Z(n,"constructor"),u=l&&t;l&&"method"!==a&&this.raise(n.key.start,"Constructor can't have get/set modifier"),n.kind=l?"constructor":a,this.parseClassMethod(n,r,i,u)}else this.parseClassField(n);return n},G.isClassElementNameStart=function(){return this.type===x.name||this.type===x.privateId||this.type===x.num||this.type===x.string||this.type===x.bracketL||this.type.keyword},G.parseClassElementName=function(t){this.type===x.privateId?("constructor"===this.value&&this.raise(this.start,"Classes can't have an element named '#constructor'"),t.computed=!1,t.key=this.parsePrivateIdent()):this.parsePropertyName(t)},G.parseClassMethod=function(t,e,n,s){var r=t.key;"constructor"===t.kind?(e&&this.raise(r.start,"Constructor can't be a generator"),n&&this.raise(r.start,"Constructor can't be an async method")):t.static&&Z(t,"prototype")&&this.raise(r.start,"Classes may not have a static property named prototype");var i=t.value=this.parseMethod(e,n,s);return"get"===t.kind&&0!==i.params.length&&this.raiseRecoverable(i.start,"getter should have no params"),"set"===t.kind&&1!==i.params.length&&this.raiseRecoverable(i.start,"setter should have exactly one param"),"set"===t.kind&&"RestElement"===i.params[0].type&&this.raiseRecoverable(i.params[0].start,"Setter cannot use rest params"),this.finishNode(t,"MethodDefinition")},G.parseClassField=function(t){return Z(t,"constructor")?this.raise(t.key.start,"Classes can't have a field named 'constructor'"):t.static&&Z(t,"prototype")&&this.raise(t.key.start,"Classes can't have a static field named 'prototype'"),this.eat(x.eq)?(this.enterScope(576),t.value=this.parseMaybeAssign(),this.exitScope()):t.value=null,this.semicolon(),this.finishNode(t,"PropertyDefinition")},G.parseClassStaticBlock=function(t){t.body=[];var e=this.labels;for(this.labels=[],this.enterScope(320);this.type!==x.braceR;){var n=this.parseStatement(null);t.body.push(n)}return this.next(),this.exitScope(),this.labels=e,this.finishNode(t,"StaticBlock")},G.parseClassId=function(t,e){this.type===x.name?(t.id=this.parseIdent(),e&&this.checkLValSimple(t.id,2,!1)):(!0===e&&this.unexpected(),t.id=null)},G.parseClassSuper=function(t){t.superClass=this.eat(x._extends)?this.parseExprSubscripts(null,!1):null},G.enterClassBody=function(){var t={declared:Object.create(null),used:[]};return this.privateNameStack.push(t),t.declared},G.exitClassBody=function(){var t=this.privateNameStack.pop(),e=t.declared,n=t.used;if(this.options.checkPrivateFields)for(var s=this.privateNameStack.length,r=0===s?null:this.privateNameStack[s-1],i=0;i<n.length;++i){var a=n[i];T(e,a.name)||(r?r.used.push(a):this.raiseRecoverable(a.start,"Private field '#"+a.name+"' must be declared in an enclosing class"))}},G.parseExportAllDeclaration=function(t,e){return 11>this.options.ecmaVersion||(this.eatContextual("as")?(t.exported=this.parseModuleExportName(),this.checkExport(e,t.exported,this.lastTokStart)):t.exported=null),this.expectContextual("from"),this.type!==x.string&&this.unexpected(),t.source=this.parseExprAtom(),16>this.options.ecmaVersion||(t.attributes=this.parseWithClause()),this.semicolon(),this.finishNode(t,"ExportAllDeclaration")},G.parseExport=function(t,e){if(this.next(),this.eat(x.star))return this.parseExportAllDeclaration(t,e);if(this.eat(x._default))return this.checkExport(e,"default",this.lastTokStart),t.declaration=this.parseExportDefaultDeclaration(),this.finishNode(t,"ExportDefaultDeclaration");if(this.shouldParseExportStatement())t.declaration=this.parseExportDeclaration(t),"VariableDeclaration"===t.declaration.type?this.checkVariableExport(e,t.declaration.declarations):this.checkExport(e,t.declaration.id,t.declaration.id.start),t.specifiers=[],t.source=null,16>this.options.ecmaVersion||(t.attributes=[]);else{if(t.declaration=null,t.specifiers=this.parseExportSpecifiers(e),this.eatContextual("from"))this.type!==x.string&&this.unexpected(),t.source=this.parseExprAtom(),16>this.options.ecmaVersion||(t.attributes=this.parseWithClause());else{for(var n=0,s=t.specifiers;n<s.length;n+=1){var r=s[n];this.checkUnreserved(r.local),this.checkLocalExport(r.local),"Literal"===r.local.type&&this.raise(r.local.start,"A string literal cannot be used as an exported binding without `from`.")}t.source=null,16>this.options.ecmaVersion||(t.attributes=[])}this.semicolon()}return this.finishNode(t,"ExportNamedDeclaration")},G.parseExportDeclaration=function(t){return this.parseStatement(null)},G.parseExportDefaultDeclaration=function(){var t;if(this.type===x._function||(t=this.isAsyncFunction())){var e=this.startNode();return this.next(),t&&this.next(),this.parseFunction(e,4|J,!1,t)}if(this.type===x._class){var n=this.startNode();return this.parseClass(n,"nullableID")}var s=this.parseMaybeAssign();return this.semicolon(),s},G.checkExport=function(t,e,n){t&&("string"!=typeof e&&(e="Identifier"===e.type?e.name:e.value),T(t,e)&&this.raiseRecoverable(n,"Duplicate export '"+e+"'"),t[e]=!0)},G.checkPatternExport=function(t,e){var n=e.type;if("Identifier"===n)this.checkExport(t,e,e.start);else if("ObjectPattern"===n)for(var s=0,r=e.properties;s<r.length;s+=1){var i=r[s];this.checkPatternExport(t,i)}else if("ArrayPattern"===n)for(var a=0,o=e.elements;a<o.length;a+=1){var c=o[a];c&&this.checkPatternExport(t,c)}else"Property"===n?this.checkPatternExport(t,e.value):"AssignmentPattern"===n?this.checkPatternExport(t,e.left):"RestElement"===n&&this.checkPatternExport(t,e.argument)},G.checkVariableExport=function(t,e){if(t)for(var n=0,s=e;n<s.length;n+=1){var r=s[n];this.checkPatternExport(t,r.id)}},G.shouldParseExportStatement=function(){return"var"===this.type.keyword||"const"===this.type.keyword||"class"===this.type.keyword||"function"===this.type.keyword||this.isLet()||this.isAsyncFunction()},G.parseExportSpecifier=function(t){var e=this.startNode();return e.local=this.parseModuleExportName(),e.exported=this.eatContextual("as")?this.parseModuleExportName():e.local,this.checkExport(t,e.exported,e.exported.start),this.finishNode(e,"ExportSpecifier")},G.parseExportSpecifiers=function(t){var e=[],n=!0;for(this.expect(x.braceL);!this.eat(x.braceR);){if(n)n=!1;else if(this.expect(x.comma),this.afterTrailingComma(x.braceR))break;e.push(this.parseExportSpecifier(t))}return e},G.parseImport=function(t){return this.next(),this.type===x.string?(t.specifiers=K,t.source=this.parseExprAtom()):(t.specifiers=this.parseImportSpecifiers(),this.expectContextual("from"),t.source=this.type===x.string?this.parseExprAtom():this.unexpected()),16>this.options.ecmaVersion||(t.attributes=this.parseWithClause()),this.semicolon(),this.finishNode(t,"ImportDeclaration")},G.parseImportSpecifier=function(){var t=this.startNode();return t.imported=this.parseModuleExportName(),this.eatContextual("as")?t.local=this.parseIdent():(this.checkUnreserved(t.imported),t.local=t.imported),this.checkLValSimple(t.local,2),this.finishNode(t,"ImportSpecifier")},G.parseImportDefaultSpecifier=function(){var t=this.startNode();return t.local=this.parseIdent(),this.checkLValSimple(t.local,2),this.finishNode(t,"ImportDefaultSpecifier")},G.parseImportNamespaceSpecifier=function(){var t=this.startNode();return this.next(),this.expectContextual("as"),t.local=this.parseIdent(),this.checkLValSimple(t.local,2),this.finishNode(t,"ImportNamespaceSpecifier")},G.parseImportSpecifiers=function(){var t=[],e=!0;if(this.type===x.name&&(t.push(this.parseImportDefaultSpecifier()),!this.eat(x.comma)))return t;if(this.type===x.star)return t.push(this.parseImportNamespaceSpecifier()),t;for(this.expect(x.braceL);!this.eat(x.braceR);){if(e)e=!1;else if(this.expect(x.comma),this.afterTrailingComma(x.braceR))break;t.push(this.parseImportSpecifier())}return t},G.parseWithClause=function(){var t=[];if(!this.eat(x._with))return t;this.expect(x.braceL);for(var e={},n=!0;!this.eat(x.braceR);){if(n)n=!1;else if(this.expect(x.comma),this.afterTrailingComma(x.braceR))break;var s=this.parseImportAttribute(),r="Identifier"===s.key.type?s.key.name:s.key.value;T(e,r)&&this.raiseRecoverable(s.key.start,"Duplicate attribute key '"+r+"'"),e[r]=!0,t.push(s)}return t},G.parseImportAttribute=function(){var t=this.startNode();return t.key=this.type===x.string?this.parseExprAtom():this.parseIdent("never"!==this.options.allowReserved),this.expect(x.colon),this.type!==x.string&&this.unexpected(),t.value=this.parseExprAtom(),this.finishNode(t,"ImportAttribute")},G.parseModuleExportName=function(){if(this.options.ecmaVersion>=13&&this.type===x.string){var t=this.parseLiteral(this.value);return V.test(t.value)&&this.raise(t.start,"An export name cannot include a lone surrogate."),t}return this.parseIdent(!0)},G.adaptDirectivePrologue=function(t){for(var e=0;e<t.length&&this.isDirectiveCandidate(t[e]);++e)t[e].directive=t[e].expression.raw.slice(1,-1)},G.isDirectiveCandidate=function(t){return this.options.ecmaVersion>=5&&"ExpressionStatement"===t.type&&"Literal"===t.expression.type&&"string"==typeof t.expression.value&&('"'===this.input[t.start]||"'"===this.input[t.start])};var tt=j.prototype;tt.toAssignable=function(t,e,n){if(this.options.ecmaVersion>=6&&t)switch(t.type){case"Identifier":this.inAsync&&"await"===t.name&&this.raise(t.start,"Cannot use 'await' as identifier inside an async function");break;case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":case"RestElement":break;case"ObjectExpression":t.type="ObjectPattern",n&&this.checkPatternErrors(n,!0);for(var s=0,r=t.properties;s<r.length;s+=1){var i=r[s];this.toAssignable(i,e),"RestElement"!==i.type||"ArrayPattern"!==i.argument.type&&"ObjectPattern"!==i.argument.type||this.raise(i.argument.start,"Unexpected token")}break;case"Property":"init"!==t.kind&&this.raise(t.key.start,"Object pattern can't contain getter or setter"),this.toAssignable(t.value,e);break;case"ArrayExpression":t.type="ArrayPattern",n&&this.checkPatternErrors(n,!0),this.toAssignableList(t.elements,e);break;case"SpreadElement":t.type="RestElement",this.toAssignable(t.argument,e),"AssignmentPattern"===t.argument.type&&this.raise(t.argument.start,"Rest elements cannot have a default value");break;case"AssignmentExpression":"="!==t.operator&&this.raise(t.left.end,"Only '=' operator can be used for specifying default value."),t.type="AssignmentPattern",delete t.operator,this.toAssignable(t.left,e);break;case"ParenthesizedExpression":this.toAssignable(t.expression,e,n);break;case"ChainExpression":this.raiseRecoverable(t.start,"Optional chaining cannot appear in left-hand side");break;case"MemberExpression":if(!e)break;default:this.raise(t.start,"Assigning to rvalue")}else n&&this.checkPatternErrors(n,!0);return t},tt.toAssignableList=function(t,e){for(var n=t.length,s=0;n>s;s++){var r=t[s];r&&this.toAssignable(r,e)}if(n){var i=t[n-1];6===this.options.ecmaVersion&&e&&i&&"RestElement"===i.type&&"Identifier"!==i.argument.type&&this.unexpected(i.argument.start)}return t},tt.parseSpread=function(t){var e=this.startNode();return this.next(),e.argument=this.parseMaybeAssign(!1,t),this.finishNode(e,"SpreadElement")},tt.parseRestBinding=function(){var t=this.startNode();return this.next(),6===this.options.ecmaVersion&&this.type!==x.name&&this.unexpected(),t.argument=this.parseBindingAtom(),this.finishNode(t,"RestElement")},tt.parseBindingAtom=function(){if(this.options.ecmaVersion>=6)switch(this.type){case x.bracketL:var t=this.startNode();return this.next(),t.elements=this.parseBindingList(x.bracketR,!0,!0),this.finishNode(t,"ArrayPattern");case x.braceL:return this.parseObj(!0)}return this.parseIdent()},tt.parseBindingList=function(t,e,n,s){for(var r=[],i=!0;!this.eat(t);)if(i?i=!1:this.expect(x.comma),e&&this.type===x.comma)r.push(null);else{if(n&&this.afterTrailingComma(t))break;if(this.type===x.ellipsis){var a=this.parseRestBinding();this.parseBindingListItem(a),r.push(a),this.type===x.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.expect(t);break}r.push(this.parseAssignableListItem(s))}return r},tt.parseAssignableListItem=function(t){var e=this.parseMaybeDefault(this.start,this.startLoc);return this.parseBindingListItem(e),e},tt.parseBindingListItem=function(t){return t},tt.parseMaybeDefault=function(t,e,n){if(n=n||this.parseBindingAtom(),6>this.options.ecmaVersion||!this.eat(x.eq))return n;var s=this.startNodeAt(t,e);return s.left=n,s.right=this.parseMaybeAssign(),this.finishNode(s,"AssignmentPattern")},tt.checkLValSimple=function(t,e,n){void 0===e&&(e=0);var s=0!==e;switch(t.type){case"Identifier":this.strict&&this.reservedWordsStrictBind.test(t.name)&&this.raiseRecoverable(t.start,(s?"Binding ":"Assigning to ")+t.name+" in strict mode"),s&&(2===e&&"let"===t.name&&this.raiseRecoverable(t.start,"let is disallowed as a lexically bound name"),n&&(T(n,t.name)&&this.raiseRecoverable(t.start,"Argument name clash"),n[t.name]=!0),5!==e&&this.declareName(t.name,e,t.start));break;case"ChainExpression":this.raiseRecoverable(t.start,"Optional chaining cannot appear in left-hand side");break;case"MemberExpression":s&&this.raiseRecoverable(t.start,"Binding member expression");break;case"ParenthesizedExpression":return s&&this.raiseRecoverable(t.start,"Binding parenthesized expression"),this.checkLValSimple(t.expression,e,n);default:this.raise(t.start,(s?"Binding":"Assigning to")+" rvalue")}},tt.checkLValPattern=function(t,e,n){switch(void 0===e&&(e=0),t.type){case"ObjectPattern":for(var s=0,r=t.properties;s<r.length;s+=1){var i=r[s];this.checkLValInnerPattern(i,e,n)}break;case"ArrayPattern":for(var a=0,o=t.elements;a<o.length;a+=1){var c=o[a];c&&this.checkLValInnerPattern(c,e,n)}break;default:this.checkLValSimple(t,e,n)}},tt.checkLValInnerPattern=function(t,e,n){switch(void 0===e&&(e=0),t.type){case"Property":this.checkLValInnerPattern(t.value,e,n);break;case"AssignmentPattern":this.checkLValPattern(t.left,e,n);break;case"RestElement":this.checkLValPattern(t.argument,e,n);break;default:this.checkLValPattern(t,e,n)}};var et=function(t,e,n,s,r){this.token=t,this.isExpr=!!e,this.preserveSpace=!!n,this.override=s,this.generator=!!r},nt={b_stat:new et("{",!1),b_expr:new et("{",!0),b_tmpl:new et("${",!1),p_stat:new et("(",!1),p_expr:new et("(",!0),q_tmpl:new et("`",!0,!0,function(t){return t.tryReadTemplateToken()}),f_stat:new et("function",!1),f_expr:new et("function",!0),f_expr_gen:new et("function",!0,!1,null,!0),f_gen:new et("function",!1,!1,null,!0)},st=j.prototype;st.initialContext=function(){return[nt.b_stat]},st.curContext=function(){return this.context[this.context.length-1]},st.braceIsBlock=function(t){var e=this.curContext();return e===nt.f_expr||e===nt.f_stat||(t!==x.colon||e!==nt.b_stat&&e!==nt.b_expr?t===x._return||t===x.name&&this.exprAllowed?b.test(this.input.slice(this.lastTokEnd,this.start)):t===x._else||t===x.semi||t===x.eof||t===x.parenR||t===x.arrow||(t===x.braceL?e===nt.b_stat:t!==x._var&&t!==x._const&&t!==x.name&&!this.exprAllowed):!e.isExpr)},st.inGeneratorContext=function(){for(var t=this.context.length-1;t>=1;t--){var e=this.context[t];if("function"===e.token)return e.generator}return!1},st.updateContext=function(t){var e,n=this.type;n.keyword&&t===x.dot?this.exprAllowed=!1:(e=n.updateContext)?e.call(this,t):this.exprAllowed=n.beforeExpr},st.overrideContext=function(t){this.curContext()!==t&&(this.context[this.context.length-1]=t)},x.parenR.updateContext=x.braceR.updateContext=function(){if(1!==this.context.length){var t=this.context.pop();t===nt.b_stat&&"function"===this.curContext().token&&(t=this.context.pop()),this.exprAllowed=!t.isExpr}else this.exprAllowed=!0},x.braceL.updateContext=function(t){this.context.push(this.braceIsBlock(t)?nt.b_stat:nt.b_expr),this.exprAllowed=!0},x.dollarBraceL.updateContext=function(){this.context.push(nt.b_tmpl),this.exprAllowed=!0},x.parenL.updateContext=function(t){var e=t===x._if||t===x._for||t===x._with||t===x._while;this.context.push(e?nt.p_stat:nt.p_expr),this.exprAllowed=!0},x.incDec.updateContext=function(){},x._function.updateContext=x._class.updateContext=function(t){!t.beforeExpr||t===x._else||t===x.semi&&this.curContext()!==nt.p_stat||t===x._return&&b.test(this.input.slice(this.lastTokEnd,this.start))||(t===x.colon||t===x.braceL)&&this.curContext()===nt.b_stat?this.context.push(nt.f_stat):this.context.push(nt.f_expr),this.exprAllowed=!1},x.colon.updateContext=function(){"function"===this.curContext().token&&this.context.pop(),this.exprAllowed=!0},x.backQuote.updateContext=function(){this.curContext()===nt.q_tmpl?this.context.pop():this.context.push(nt.q_tmpl),this.exprAllowed=!1},x.star.updateContext=function(t){if(t===x._function){var e=this.context.length-1;this.context[e]===nt.f_expr?this.context[e]=nt.f_expr_gen:this.context[e]=nt.f_gen}this.exprAllowed=!0},x.name.updateContext=function(t){var e=!1;6>this.options.ecmaVersion||t===x.dot||("of"===this.value&&!this.exprAllowed||"yield"===this.value&&this.inGeneratorContext())&&(e=!0),this.exprAllowed=e};var rt=j.prototype;function it(t){return"Identifier"===t.type||"ParenthesizedExpression"===t.type&&it(t.expression)}function at(t){return"MemberExpression"===t.type&&"PrivateIdentifier"===t.property.type||"ChainExpression"===t.type&&at(t.expression)||"ParenthesizedExpression"===t.type&&at(t.expression)}rt.checkPropClash=function(t,e,n){if((9>this.options.ecmaVersion||"SpreadElement"!==t.type)&&(6>this.options.ecmaVersion||!(t.computed||t.method||t.shorthand))){var s,r=t.key;switch(r.type){case"Identifier":s=r.name;break;case"Literal":s=r.value+"";break;default:return}var i=t.kind;if(6>this.options.ecmaVersion){var a=e[s="$"+s];a?("init"===i?this.strict&&a.init||a.get||a.set:a.init||a[i])&&this.raiseRecoverable(r.start,"Redefinition of property"):a=e[s]={init:!1,get:!1,set:!1},a[i]=!0}else"__proto__"===s&&"init"===i&&(e.proto&&(n?0>n.doubleProto&&(n.doubleProto=r.start):this.raiseRecoverable(r.start,"Redefinition of __proto__ property")),e.proto=!0)}},rt.parseExpression=function(t,e){var n=this.start,s=this.startLoc,r=this.parseMaybeAssign(t,e);if(this.type===x.comma){var i=this.startNodeAt(n,s);for(i.expressions=[r];this.eat(x.comma);)i.expressions.push(this.parseMaybeAssign(t,e));return this.finishNode(i,"SequenceExpression")}return r},rt.parseMaybeAssign=function(t,e,n){if(this.isContextual("yield")){if(this.inGenerator)return this.parseYield(t);this.exprAllowed=!1}var s=!1,r=-1,i=-1,a=-1;e?(r=e.parenthesizedAssign,i=e.trailingComma,a=e.doubleProto,e.parenthesizedAssign=e.trailingComma=-1):(e=new H,s=!0);var o=this.start,c=this.startLoc;this.type!==x.parenL&&this.type!==x.name||(this.potentialArrowAt=this.start,this.potentialArrowInForAwait="await"===t);var l=this.parseMaybeConditional(t,e);if(n&&(l=n.call(this,l,o,c)),this.type.isAssign){var u=this.startNodeAt(o,c);return u.operator=this.value,this.type===x.eq&&(l=this.toAssignable(l,!1,e)),s||(e.parenthesizedAssign=e.trailingComma=e.doubleProto=-1),e.shorthandAssign<l.start||(e.shorthandAssign=-1),this.type===x.eq?this.checkLValPattern(l):this.checkLValSimple(l),u.left=l,this.next(),u.right=this.parseMaybeAssign(t),a>-1&&(e.doubleProto=a),this.finishNode(u,"AssignmentExpression")}return s&&this.checkExpressionErrors(e,!0),r>-1&&(e.parenthesizedAssign=r),i>-1&&(e.trailingComma=i),l},rt.parseMaybeConditional=function(t,e){var n=this.start,s=this.startLoc,r=this.parseExprOps(t,e);if(this.checkExpressionErrors(e))return r;if(this.eat(x.question)){var i=this.startNodeAt(n,s);return i.test=r,i.consequent=this.parseMaybeAssign(),this.expect(x.colon),i.alternate=this.parseMaybeAssign(t),this.finishNode(i,"ConditionalExpression")}return r},rt.parseExprOps=function(t,e){var n=this.start,s=this.startLoc,r=this.parseMaybeUnary(e,!1,!1,t);return this.checkExpressionErrors(e)||r.start===n&&"ArrowFunctionExpression"===r.type?r:this.parseExprOp(r,n,s,-1,t)},rt.parseExprOp=function(t,e,n,s,r){var i=this.type.binop;if(null!=i&&(!r||this.type!==x._in)&&i>s){var a=this.type===x.logicalOR||this.type===x.logicalAND,o=this.type===x.coalesce;o&&(i=x.logicalAND.binop);var c=this.value;this.next();var l=this.start,u=this.startLoc,h=this.parseExprOp(this.parseMaybeUnary(null,!1,!1,r),l,u,i,r),p=this.buildBinary(e,n,t,h,c,a||o);return(a&&this.type===x.coalesce||o&&(this.type===x.logicalOR||this.type===x.logicalAND))&&this.raiseRecoverable(this.start,"Logical expressions and coalesce expressions cannot be mixed. Wrap either by parentheses"),this.parseExprOp(p,e,n,s,r)}return t},rt.buildBinary=function(t,e,n,s,r,i){"PrivateIdentifier"===s.type&&this.raise(s.start,"Private identifier can only be left side of binary expression");var a=this.startNodeAt(t,e);return a.left=n,a.operator=r,a.right=s,this.finishNode(a,i?"LogicalExpression":"BinaryExpression")},rt.parseMaybeUnary=function(t,e,n,s){var r,i=this.start,a=this.startLoc;if(this.isContextual("await")&&this.canAwait)r=this.parseAwait(s),e=!0;else if(this.type.prefix){var o=this.startNode(),c=this.type===x.incDec;o.operator=this.value,o.prefix=!0,this.next(),o.argument=this.parseMaybeUnary(null,!0,c,s),this.checkExpressionErrors(t,!0),c?this.checkLValSimple(o.argument):this.strict&&"delete"===o.operator&&it(o.argument)?this.raiseRecoverable(o.start,"Deleting local variable in strict mode"):"delete"===o.operator&&at(o.argument)?this.raiseRecoverable(o.start,"Private fields can not be deleted"):e=!0,r=this.finishNode(o,c?"UpdateExpression":"UnaryExpression")}else if(e||this.type!==x.privateId){if(r=this.parseExprSubscripts(t,s),this.checkExpressionErrors(t))return r;for(;this.type.postfix&&!this.canInsertSemicolon();){var l=this.startNodeAt(i,a);l.operator=this.value,l.prefix=!1,l.argument=r,this.checkLValSimple(r),this.next(),r=this.finishNode(l,"UpdateExpression")}}else(s||0===this.privateNameStack.length)&&this.options.checkPrivateFields&&this.unexpected(),r=this.parsePrivateIdent(),this.type!==x._in&&this.unexpected();return n||!this.eat(x.starstar)?r:e?void this.unexpected(this.lastTokStart):this.buildBinary(i,a,r,this.parseMaybeUnary(null,!1,!1,s),"**",!1)},rt.parseExprSubscripts=function(t,e){var n=this.start,s=this.startLoc,r=this.parseExprAtom(t,e);if("ArrowFunctionExpression"===r.type&&")"!==this.input.slice(this.lastTokStart,this.lastTokEnd))return r;var i=this.parseSubscripts(r,n,s,!1,e);return t&&"MemberExpression"===i.type&&(t.parenthesizedAssign<i.start||(t.parenthesizedAssign=-1),t.parenthesizedBind<i.start||(t.parenthesizedBind=-1),t.trailingComma<i.start||(t.trailingComma=-1)),i},rt.parseSubscripts=function(t,e,n,s,r){for(var i=this.options.ecmaVersion>=8&&"Identifier"===t.type&&"async"===t.name&&this.lastTokEnd===t.end&&!this.canInsertSemicolon()&&t.end-t.start===5&&this.potentialArrowAt===t.start,a=!1;;){var o=this.parseSubscript(t,e,n,s,i,a,r);if(o.optional&&(a=!0),o===t||"ArrowFunctionExpression"===o.type){if(a){var c=this.startNodeAt(e,n);c.expression=o,o=this.finishNode(c,"ChainExpression")}return o}t=o}},rt.shouldParseAsyncArrow=function(){return!this.canInsertSemicolon()&&this.eat(x.arrow)},rt.parseSubscriptAsyncArrow=function(t,e,n,s){return this.parseArrowExpression(this.startNodeAt(t,e),n,!0,s)},rt.parseSubscript=function(t,e,n,s,r,i,a){var o=this.options.ecmaVersion>=11,c=o&&this.eat(x.questionDot);s&&c&&this.raise(this.lastTokStart,"Optional chaining cannot appear in the callee of new expressions");var l=this.eat(x.bracketL);if(l||c&&this.type!==x.parenL&&this.type!==x.backQuote||this.eat(x.dot)){var u=this.startNodeAt(e,n);u.object=t,l?(u.property=this.parseExpression(),this.expect(x.bracketR)):this.type===x.privateId&&"Super"!==t.type?u.property=this.parsePrivateIdent():u.property=this.parseIdent("never"!==this.options.allowReserved),u.computed=!!l,o&&(u.optional=c),t=this.finishNode(u,"MemberExpression")}else if(!s&&this.eat(x.parenL)){var h=new H,p=this.yieldPos,f=this.awaitPos,d=this.awaitIdentPos;this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0;var m=this.parseExprList(x.parenR,this.options.ecmaVersion>=8,!1,h);if(r&&!c&&this.shouldParseAsyncArrow())return this.checkPatternErrors(h,!1),this.checkYieldAwaitInDefaultParams(),this.awaitIdentPos>0&&this.raise(this.awaitIdentPos,"Cannot use 'await' as identifier inside an async function"),this.yieldPos=p,this.awaitPos=f,this.awaitIdentPos=d,this.parseSubscriptAsyncArrow(e,n,m,a);this.checkExpressionErrors(h,!0),this.yieldPos=p||this.yieldPos,this.awaitPos=f||this.awaitPos,this.awaitIdentPos=d||this.awaitIdentPos;var g=this.startNodeAt(e,n);g.callee=t,g.arguments=m,o&&(g.optional=c),t=this.finishNode(g,"CallExpression")}else if(this.type===x.backQuote){(c||i)&&this.raise(this.start,"Optional chaining cannot appear in the tag of tagged template expressions");var y=this.startNodeAt(e,n);y.tag=t,y.quasi=this.parseTemplate({isTagged:!0}),t=this.finishNode(y,"TaggedTemplateExpression")}return t},rt.parseExprAtom=function(t,e,n){this.type===x.slash&&this.readRegexp();var s,r=this.potentialArrowAt===this.start;switch(this.type){case x._super:return this.allowSuper||this.raise(this.start,"'super' keyword outside a method"),s=this.startNode(),this.next(),this.type!==x.parenL||this.allowDirectSuper||this.raise(s.start,"super() call outside constructor of a subclass"),this.type!==x.dot&&this.type!==x.bracketL&&this.type!==x.parenL&&this.unexpected(),this.finishNode(s,"Super");case x._this:return s=this.startNode(),this.next(),this.finishNode(s,"ThisExpression");case x.name:var i=this.start,a=this.startLoc,o=this.containsEsc,c=this.parseIdent(!1);if(this.options.ecmaVersion>=8&&!o&&"async"===c.name&&!this.canInsertSemicolon()&&this.eat(x._function))return this.overrideContext(nt.f_expr),this.parseFunction(this.startNodeAt(i,a),0,!1,!0,e);if(r&&!this.canInsertSemicolon()){if(this.eat(x.arrow))return this.parseArrowExpression(this.startNodeAt(i,a),[c],!1,e);if(this.options.ecmaVersion>=8&&"async"===c.name&&this.type===x.name&&!o&&(!this.potentialArrowInForAwait||"of"!==this.value||this.containsEsc))return c=this.parseIdent(!1),!this.canInsertSemicolon()&&this.eat(x.arrow)||this.unexpected(),this.parseArrowExpression(this.startNodeAt(i,a),[c],!0,e)}return c;case x.regexp:var l=this.value;return(s=this.parseLiteral(l.value)).regex={pattern:l.pattern,flags:l.flags},s;case x.num:case x.string:return this.parseLiteral(this.value);case x._null:case x._true:case x._false:return(s=this.startNode()).value=this.type===x._null?null:this.type===x._true,s.raw=this.type.keyword,this.next(),this.finishNode(s,"Literal");case x.parenL:var u=this.start,h=this.parseParenAndDistinguishExpression(r,e);return t&&(0>t.parenthesizedAssign&&!this.isSimpleAssignTarget(h)&&(t.parenthesizedAssign=u),0>t.parenthesizedBind&&(t.parenthesizedBind=u)),h;case x.bracketL:return s=this.startNode(),this.next(),s.elements=this.parseExprList(x.bracketR,!0,!0,t),this.finishNode(s,"ArrayExpression");case x.braceL:return this.overrideContext(nt.b_expr),this.parseObj(!1,t);case x._function:return s=this.startNode(),this.next(),this.parseFunction(s,0);case x._class:return this.parseClass(this.startNode(),!1);case x._new:return this.parseNew();case x.backQuote:return this.parseTemplate();case x._import:return 11>this.options.ecmaVersion?this.unexpected():this.parseExprImport(n);default:return this.parseExprAtomDefault()}},rt.parseExprAtomDefault=function(){this.unexpected()},rt.parseExprImport=function(t){var e=this.startNode();if(this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword import"),this.next(),this.type===x.parenL&&!t)return this.parseDynamicImport(e);if(this.type===x.dot){var n=this.startNodeAt(e.start,e.loc&&e.loc.start);return n.name="import",e.meta=this.finishNode(n,"Identifier"),this.parseImportMeta(e)}this.unexpected()},rt.parseDynamicImport=function(t){if(this.next(),t.source=this.parseMaybeAssign(),16>this.options.ecmaVersion){if(!this.eat(x.parenR)){var e=this.start;this.eat(x.comma)&&this.eat(x.parenR)?this.raiseRecoverable(e,"Trailing comma is not allowed in import()"):this.unexpected(e)}}else this.eat(x.parenR)?t.options=null:(this.expect(x.comma),this.afterTrailingComma(x.parenR)?t.options=null:(t.options=this.parseMaybeAssign(),this.eat(x.parenR)||(this.expect(x.comma),this.afterTrailingComma(x.parenR)||this.unexpected())));return this.finishNode(t,"ImportExpression")},rt.parseImportMeta=function(t){this.next();var e=this.containsEsc;return t.property=this.parseIdent(!0),"meta"!==t.property.name&&this.raiseRecoverable(t.property.start,"The only valid meta property for import is 'import.meta'"),e&&this.raiseRecoverable(t.start,"'import.meta' must not contain escaped characters"),"module"===this.options.sourceType||this.options.allowImportExportEverywhere||this.raiseRecoverable(t.start,"Cannot use 'import.meta' outside a module"),this.finishNode(t,"MetaProperty")},rt.parseLiteral=function(t){var e=this.startNode();return e.value=t,e.raw=this.input.slice(this.start,this.end),110===e.raw.charCodeAt(e.raw.length-1)&&(e.bigint=null!=e.value?e.value.toString():e.raw.slice(0,-1).replace(/_/g,"")),this.next(),this.finishNode(e,"Literal")},rt.parseParenExpression=function(){this.expect(x.parenL);var t=this.parseExpression();return this.expect(x.parenR),t},rt.shouldParseArrow=function(t){return!this.canInsertSemicolon()},rt.parseParenAndDistinguishExpression=function(t,e){var n,s=this.start,r=this.startLoc,i=this.options.ecmaVersion>=8;if(6>this.options.ecmaVersion)n=this.parseParenExpression();else{this.next();var a,o=this.start,c=this.startLoc,l=[],u=!0,h=!1,p=new H,f=this.yieldPos,d=this.awaitPos;for(this.yieldPos=0,this.awaitPos=0;this.type!==x.parenR;){if(u?u=!1:this.expect(x.comma),i&&this.afterTrailingComma(x.parenR,!0)){h=!0;break}if(this.type===x.ellipsis){a=this.start,l.push(this.parseParenItem(this.parseRestBinding())),this.type===x.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element");break}l.push(this.parseMaybeAssign(!1,p,this.parseParenItem))}var m=this.lastTokEnd,g=this.lastTokEndLoc;if(this.expect(x.parenR),t&&this.shouldParseArrow(l)&&this.eat(x.arrow))return this.checkPatternErrors(p,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=f,this.awaitPos=d,this.parseParenArrowList(s,r,l,e);l.length&&!h||this.unexpected(this.lastTokStart),a&&this.unexpected(a),this.checkExpressionErrors(p,!0),this.yieldPos=f||this.yieldPos,this.awaitPos=d||this.awaitPos,l.length>1?((n=this.startNodeAt(o,c)).expressions=l,this.finishNodeAt(n,"SequenceExpression",m,g)):n=l[0]}if(this.options.preserveParens){var y=this.startNodeAt(s,r);return y.expression=n,this.finishNode(y,"ParenthesizedExpression")}return n},rt.parseParenItem=function(t){return t},rt.parseParenArrowList=function(t,e,n,s){return this.parseArrowExpression(this.startNodeAt(t,e),n,!1,s)};var ot=[];rt.parseNew=function(){this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword new");var t=this.startNode();if(this.next(),this.options.ecmaVersion>=6&&this.type===x.dot){var e=this.startNodeAt(t.start,t.loc&&t.loc.start);e.name="new",t.meta=this.finishNode(e,"Identifier"),this.next();var n=this.containsEsc;return t.property=this.parseIdent(!0),"target"!==t.property.name&&this.raiseRecoverable(t.property.start,"The only valid meta property for new is 'new.target'"),n&&this.raiseRecoverable(t.start,"'new.target' must not contain escaped characters"),this.allowNewDotTarget||this.raiseRecoverable(t.start,"'new.target' can only be used in functions and class static block"),this.finishNode(t,"MetaProperty")}var s=this.start,r=this.startLoc;return t.callee=this.parseSubscripts(this.parseExprAtom(null,!1,!0),s,r,!0,!1),this.eat(x.parenL)?t.arguments=this.parseExprList(x.parenR,this.options.ecmaVersion>=8,!1):t.arguments=ot,this.finishNode(t,"NewExpression")},rt.parseTemplateElement=function(t){var e=t.isTagged,n=this.startNode();return this.type===x.invalidTemplate?(e||this.raiseRecoverable(this.start,"Bad escape sequence in untagged template literal"),n.value={raw:this.value.replace(/\r\n?/g,"\n"),cooked:null}):n.value={raw:this.input.slice(this.start,this.end).replace(/\r\n?/g,"\n"),cooked:this.value},this.next(),n.tail=this.type===x.backQuote,this.finishNode(n,"TemplateElement")},rt.parseTemplate=function(t){void 0===t&&(t={});var e=t.isTagged;void 0===e&&(e=!1);var n=this.startNode();this.next(),n.expressions=[];var s=this.parseTemplateElement({isTagged:e});for(n.quasis=[s];!s.tail;)this.type===x.eof&&this.raise(this.pos,"Unterminated template literal"),this.expect(x.dollarBraceL),n.expressions.push(this.parseExpression()),this.expect(x.braceR),n.quasis.push(s=this.parseTemplateElement({isTagged:e}));return this.next(),this.finishNode(n,"TemplateLiteral")},rt.isAsyncProp=function(t){return!t.computed&&"Identifier"===t.key.type&&"async"===t.key.name&&(this.type===x.name||this.type===x.num||this.type===x.string||this.type===x.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===x.star)&&!b.test(this.input.slice(this.lastTokEnd,this.start))},rt.parseObj=function(t,e){var n=this.startNode(),s=!0,r={};for(n.properties=[],this.next();!this.eat(x.braceR);){if(s)s=!1;else if(this.expect(x.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(x.braceR))break;var i=this.parseProperty(t,e);t||this.checkPropClash(i,r,e),n.properties.push(i)}return this.finishNode(n,t?"ObjectPattern":"ObjectExpression")},rt.parseProperty=function(t,e){var n,s,r,i,a=this.startNode();if(this.options.ecmaVersion>=9&&this.eat(x.ellipsis))return t?(a.argument=this.parseIdent(!1),this.type===x.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.finishNode(a,"RestElement")):(a.argument=this.parseMaybeAssign(!1,e),this.type===x.comma&&e&&0>e.trailingComma&&(e.trailingComma=this.start),this.finishNode(a,"SpreadElement"));6>this.options.ecmaVersion||(a.method=!1,a.shorthand=!1,(t||e)&&(r=this.start,i=this.startLoc),t||(n=this.eat(x.star)));var o=this.containsEsc;return this.parsePropertyName(a),t||o||8>this.options.ecmaVersion||n||!this.isAsyncProp(a)?s=!1:(s=!0,n=this.options.ecmaVersion>=9&&this.eat(x.star),this.parsePropertyName(a)),this.parsePropertyValue(a,t,n,s,r,i,e,o),this.finishNode(a,"Property")},rt.parseGetterSetter=function(t){var e=t.key.name;this.parsePropertyName(t),t.value=this.parseMethod(!1),t.kind=e;var n="get"===t.kind?0:1;if(t.value.params.length!==n){var s=t.value.start;"get"===t.kind?this.raiseRecoverable(s,"getter should have no params"):this.raiseRecoverable(s,"setter should have exactly one param")}else"set"===t.kind&&"RestElement"===t.value.params[0].type&&this.raiseRecoverable(t.value.params[0].start,"Setter cannot use rest params")},rt.parsePropertyValue=function(t,e,n,s,r,i,a,o){(n||s)&&this.type===x.colon&&this.unexpected(),this.eat(x.colon)?(t.value=e?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,a),t.kind="init"):6>this.options.ecmaVersion||this.type!==x.parenL?e||o||5>this.options.ecmaVersion||t.computed||"Identifier"!==t.key.type||"get"!==t.key.name&&"set"!==t.key.name||this.type===x.comma||this.type===x.braceR||this.type===x.eq?6>this.options.ecmaVersion||t.computed||"Identifier"!==t.key.type?this.unexpected():((n||s)&&this.unexpected(),this.checkUnreserved(t.key),"await"!==t.key.name||this.awaitIdentPos||(this.awaitIdentPos=r),e?t.value=this.parseMaybeDefault(r,i,this.copyNode(t.key)):this.type===x.eq&&a?(0>a.shorthandAssign&&(a.shorthandAssign=this.start),t.value=this.parseMaybeDefault(r,i,this.copyNode(t.key))):t.value=this.copyNode(t.key),t.kind="init",t.shorthand=!0):((n||s)&&this.unexpected(),this.parseGetterSetter(t)):(e&&this.unexpected(),t.method=!0,t.value=this.parseMethod(n,s),t.kind="init")},rt.parsePropertyName=function(t){if(this.options.ecmaVersion>=6){if(this.eat(x.bracketL))return t.computed=!0,t.key=this.parseMaybeAssign(),this.expect(x.bracketR),t.key;t.computed=!1}return t.key=this.type===x.num||this.type===x.string?this.parseExprAtom():this.parseIdent("never"!==this.options.allowReserved)},rt.initFunction=function(t){t.id=null,6>this.options.ecmaVersion||(t.generator=t.expression=!1),8>this.options.ecmaVersion||(t.async=!1)},rt.parseMethod=function(t,e,n){var s=this.startNode(),r=this.yieldPos,i=this.awaitPos,a=this.awaitIdentPos;return this.initFunction(s),6>this.options.ecmaVersion||(s.generator=t),8>this.options.ecmaVersion||(s.async=!!e),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(64|U(e,s.generator)|(n?128:0)),this.expect(x.parenL),s.params=this.parseBindingList(x.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(s,!1,!0,!1),this.yieldPos=r,this.awaitPos=i,this.awaitIdentPos=a,this.finishNode(s,"FunctionExpression")},rt.parseArrowExpression=function(t,e,n,s){var r=this.yieldPos,i=this.awaitPos,a=this.awaitIdentPos;return this.enterScope(16|U(n,!1)),this.initFunction(t),8>this.options.ecmaVersion||(t.async=!!n),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,t.params=this.toAssignableList(e,!0),this.parseFunctionBody(t,!0,!1,s),this.yieldPos=r,this.awaitPos=i,this.awaitIdentPos=a,this.finishNode(t,"ArrowFunctionExpression")},rt.parseFunctionBody=function(t,e,n,s){var r=e&&this.type!==x.braceL,i=this.strict,a=!1;if(r)t.body=this.parseMaybeAssign(s),t.expression=!0,this.checkParams(t,!1);else{var o=this.options.ecmaVersion>=7&&!this.isSimpleParamList(t.params);i&&!o||(a=this.strictDirective(this.end))&&o&&this.raiseRecoverable(t.start,"Illegal 'use strict' directive in function with non-simple parameter list");var c=this.labels;this.labels=[],a&&(this.strict=!0),this.checkParams(t,!i&&!a&&!e&&!n&&this.isSimpleParamList(t.params)),this.strict&&t.id&&this.checkLValSimple(t.id,5),t.body=this.parseBlock(!1,void 0,a&&!i),t.expression=!1,this.adaptDirectivePrologue(t.body.body),this.labels=c}this.exitScope()},rt.isSimpleParamList=function(t){for(var e=0,n=t;e<n.length;e+=1)if("Identifier"!==n[e].type)return!1;return!0},rt.checkParams=function(t,e){for(var n=Object.create(null),s=0,r=t.params;s<r.length;s+=1){var i=r[s];this.checkLValInnerPattern(i,1,e?null:n)}},rt.parseExprList=function(t,e,n,s){for(var r=[],i=!0;!this.eat(t);){if(i)i=!1;else if(this.expect(x.comma),e&&this.afterTrailingComma(t))break;var a=void 0;n&&this.type===x.comma?a=null:this.type===x.ellipsis?(a=this.parseSpread(s),s&&this.type===x.comma&&0>s.trailingComma&&(s.trailingComma=this.start)):a=this.parseMaybeAssign(!1,s),r.push(a)}return r},rt.checkUnreserved=function(t){var e=t.start,n=t.end,s=t.name;this.inGenerator&&"yield"===s&&this.raiseRecoverable(e,"Cannot use 'yield' as identifier inside a generator"),this.inAsync&&"await"===s&&this.raiseRecoverable(e,"Cannot use 'await' as identifier inside an async function"),259&this.currentThisScope().flags||"arguments"!==s||this.raiseRecoverable(e,"Cannot use 'arguments' in class field initializer"),!this.inClassStaticBlock||"arguments"!==s&&"await"!==s||this.raise(e,"Cannot use "+s+" in class static initialization block"),this.keywords.test(s)&&this.raise(e,"Unexpected keyword '"+s+"'"),6>this.options.ecmaVersion&&-1!==this.input.slice(e,n).indexOf("\\")||(this.strict?this.reservedWordsStrict:this.reservedWords).test(s)&&(this.inAsync||"await"!==s||this.raiseRecoverable(e,"Cannot use keyword 'await' outside an async function"),this.raiseRecoverable(e,"The keyword '"+s+"' is reserved"))},rt.parseIdent=function(t){var e=this.parseIdentNode();return this.next(!!t),this.finishNode(e,"Identifier"),t||(this.checkUnreserved(e),"await"!==e.name||this.awaitIdentPos||(this.awaitIdentPos=e.start)),e},rt.parseIdentNode=function(){var t=this.startNode();return this.type===x.name?t.name=this.value:this.type.keyword?(t.name=this.type.keyword,"class"!==t.name&&"function"!==t.name||this.lastTokEnd===this.lastTokStart+1&&46===this.input.charCodeAt(this.lastTokStart)||this.context.pop(),this.type=x.name):this.unexpected(),t},rt.parsePrivateIdent=function(){var t=this.startNode();return this.type===x.privateId?t.name=this.value:this.unexpected(),this.next(),this.finishNode(t,"PrivateIdentifier"),this.options.checkPrivateFields&&(0===this.privateNameStack.length?this.raise(t.start,"Private field '#"+t.name+"' must be declared in an enclosing class"):this.privateNameStack[this.privateNameStack.length-1].used.push(t)),t},rt.parseYield=function(t){this.yieldPos||(this.yieldPos=this.start);var e=this.startNode();return this.next(),this.type===x.semi||this.canInsertSemicolon()||this.type!==x.star&&!this.type.startsExpr?(e.delegate=!1,e.argument=null):(e.delegate=this.eat(x.star),e.argument=this.parseMaybeAssign(t)),this.finishNode(e,"YieldExpression")},rt.parseAwait=function(t){this.awaitPos||(this.awaitPos=this.start);var e=this.startNode();return this.next(),e.argument=this.parseMaybeUnary(null,!0,!1,t),this.finishNode(e,"AwaitExpression")};var ct=j.prototype;ct.raise=function(t,e){var n=D(this.input,t);e+=" ("+n.line+":"+n.column+")",this.sourceFile&&(e+=" in "+this.sourceFile);var s=new SyntaxError(e);throw s.pos=t,s.loc=n,s.raisedAt=this.pos,s},ct.raiseRecoverable=ct.raise,ct.curPosition=function(){if(this.options.locations)return new O(this.curLine,this.pos-this.lineStart)};var lt=j.prototype,ut=function(t){this.flags=t,this.var=[],this.lexical=[],this.functions=[]};lt.enterScope=function(t){this.scopeStack.push(new ut(t))},lt.exitScope=function(){this.scopeStack.pop()},lt.treatFunctionsAsVarInScope=function(t){return 2&t.flags||!this.inModule&&1&t.flags},lt.declareName=function(t,e,n){var s=!1;if(2===e){var r=this.currentScope();s=r.lexical.indexOf(t)>-1||r.functions.indexOf(t)>-1||r.var.indexOf(t)>-1,r.lexical.push(t),this.inModule&&1&r.flags&&delete this.undefinedExports[t]}else if(4===e)this.currentScope().lexical.push(t);else if(3===e){var i=this.currentScope();s=this.treatFunctionsAsVar?i.lexical.indexOf(t)>-1:i.lexical.indexOf(t)>-1||i.var.indexOf(t)>-1,i.functions.push(t)}else for(var a=this.scopeStack.length-1;a>=0;--a){var o=this.scopeStack[a];if(o.lexical.indexOf(t)>-1&&!(32&o.flags&&o.lexical[0]===t)||!this.treatFunctionsAsVarInScope(o)&&o.functions.indexOf(t)>-1){s=!0;break}if(o.var.push(t),this.inModule&&1&o.flags&&delete this.undefinedExports[t],259&o.flags)break}s&&this.raiseRecoverable(n,"Identifier '"+t+"' has already been declared")},lt.checkLocalExport=function(t){-1===this.scopeStack[0].lexical.indexOf(t.name)&&-1===this.scopeStack[0].var.indexOf(t.name)&&(this.undefinedExports[t.name]=t)},lt.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]},lt.currentVarScope=function(){for(var t=this.scopeStack.length-1;;t--){var e=this.scopeStack[t];if(771&e.flags)return e}},lt.currentThisScope=function(){for(var t=this.scopeStack.length-1;;t--){var e=this.scopeStack[t];if(771&e.flags&&!(16&e.flags))return e}};var ht=function(t,e,n){this.type="",this.start=e,this.end=0,t.options.locations&&(this.loc=new R(t,n)),t.options.directSourceFile&&(this.sourceFile=t.options.directSourceFile),t.options.ranges&&(this.range=[e,0])},pt=j.prototype;function ft(t,e,n,s){return t.type=e,t.end=n,this.options.locations&&(t.loc.end=s),this.options.ranges&&(t.range[1]=n),t}pt.startNode=function(){return new ht(this,this.start,this.startLoc)},pt.startNodeAt=function(t,e){return new ht(this,t,e)},pt.finishNode=function(t,e){return ft.call(this,t,e,this.lastTokEnd,this.lastTokEndLoc)},pt.finishNodeAt=function(t,e,n,s){return ft.call(this,t,e,n,s)},pt.copyNode=function(t){var e=new ht(this,t.start,this.startLoc);for(var n in t)e[n]=t[n];return e};var dt="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",mt=dt+" Extended_Pictographic",gt=mt+" EBase EComp EMod EPres ExtPict",yt={9:dt,10:mt,11:mt,12:gt,13:gt,14:gt},vt={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"},xt="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",bt="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",_t=bt+" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd",wt=_t+" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho",Et=wt+" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi",St=Et+" Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith",kt={9:bt,10:_t,11:wt,12:Et,13:St,14:St+" 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"},Ct={};function At(t){var e=Ct[t]={binary:L(yt[t]+" "+xt),binaryOfStrings:L(vt[t]),nonBinary:{General_Category:L(xt),Script:L(kt[t])}};e.nonBinary.Script_Extensions=e.nonBinary.Script,e.nonBinary.gc=e.nonBinary.General_Category,e.nonBinary.sc=e.nonBinary.Script,e.nonBinary.scx=e.nonBinary.Script_Extensions}for(var It=0,Tt=[9,10,11,12,13,14];It<Tt.length;It+=1)At(Tt[It]);var Nt=j.prototype,Pt=function(t,e){this.parent=t,this.base=e||this};Pt.prototype.separatedFrom=function(t){for(var e=this;e;e=e.parent)for(var n=t;n;n=n.parent)if(e.base===n.base&&e!==n)return!0;return!1},Pt.prototype.sibling=function(){return new Pt(this.parent,this.base)};var Lt=function(t){this.parser=t,this.validFlags="gim"+(6>t.options.ecmaVersion?"":"uy")+(9>t.options.ecmaVersion?"":"s")+(13>t.options.ecmaVersion?"":"d")+(15>t.options.ecmaVersion?"":"v"),this.unicodeProperties=Ct[14>t.options.ecmaVersion?t.options.ecmaVersion:14],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 Mt(t){return 105===t||109===t||115===t}function Vt(t){return 36===t||t>=40&&43>=t||46===t||63===t||t>=91&&94>=t||t>=123&&125>=t}function Ot(t){return t>=65&&90>=t||t>=97&&122>=t}function Rt(t){return Ot(t)||95===t}function Dt(t){return Rt(t)||Ft(t)}function Ft(t){return t>=48&&57>=t}function Bt(t){return t>=48&&57>=t||t>=65&&70>=t||t>=97&&102>=t}function Ut(t){return 65>t||t>70?97>t||t>102?t-48:t-97+10:t-65+10}function jt(t){return t>=48&&55>=t}Lt.prototype.reset=function(t,e,n){var s=-1!==n.indexOf("v"),r=-1!==n.indexOf("u");this.start=0|t,this.source=e+"",this.flags=n,s&&this.parser.options.ecmaVersion>=15?(this.switchU=!0,this.switchV=!0,this.switchN=!0):(this.switchU=r&&this.parser.options.ecmaVersion>=6,this.switchV=!1,this.switchN=r&&this.parser.options.ecmaVersion>=9)},Lt.prototype.raise=function(t){this.parser.raiseRecoverable(this.start,"Invalid regular expression: /"+this.source+"/: "+t)},Lt.prototype.at=function(t,e){void 0===e&&(e=!1);var n=this.source,s=n.length;if(t>=s)return-1;var r=n.charCodeAt(t);if(!e&&!this.switchU||55295>=r||r>=57344||t+1>=s)return r;var i=n.charCodeAt(t+1);return 56320>i||i>57343?r:(r<<10)+i-56613888},Lt.prototype.nextIndex=function(t,e){void 0===e&&(e=!1);var n=this.source,s=n.length;if(t>=s)return s;var r,i=n.charCodeAt(t);return(e||this.switchU)&&i>55295&&57344>i&&s>t+1&&(r=n.charCodeAt(t+1))>=56320&&57343>=r?t+2:t+1},Lt.prototype.current=function(t){return void 0===t&&(t=!1),this.at(this.pos,t)},Lt.prototype.lookahead=function(t){return void 0===t&&(t=!1),this.at(this.nextIndex(this.pos,t),t)},Lt.prototype.advance=function(t){void 0===t&&(t=!1),this.pos=this.nextIndex(this.pos,t)},Lt.prototype.eat=function(t,e){return void 0===e&&(e=!1),this.current(e)===t&&(this.advance(e),!0)},Lt.prototype.eatChars=function(t,e){void 0===e&&(e=!1);for(var n=this.pos,s=0,r=t;s<r.length;s+=1){var i=r[s],a=this.at(n,e);if(-1===a||a!==i)return!1;n=this.nextIndex(n,e)}return this.pos=n,!0},Nt.validateRegExpFlags=function(t){for(var e=t.validFlags,n=t.flags,s=!1,r=!1,i=0;i<n.length;i++){var a=n.charAt(i);-1===e.indexOf(a)&&this.raise(t.start,"Invalid regular expression flag"),n.indexOf(a,i+1)>-1&&this.raise(t.start,"Duplicate regular expression flag"),"u"===a&&(s=!0),"v"===a&&(r=!0)}this.options.ecmaVersion>=15&&s&&r&&this.raise(t.start,"Invalid regular expression flag")},Nt.validateRegExpPattern=function(t){this.regexp_pattern(t),t.switchN||9>this.options.ecmaVersion||!function(t){for(var e in t)return!0;return!1}(t.groupNames)||(t.switchN=!0,this.regexp_pattern(t))},Nt.regexp_pattern=function(t){t.pos=0,t.lastIntValue=0,t.lastStringValue="",t.lastAssertionIsQuantifiable=!1,t.numCapturingParens=0,t.maxBackReference=0,t.groupNames=Object.create(null),t.backReferenceNames.length=0,t.branchID=null,this.regexp_disjunction(t),t.pos!==t.source.length&&(t.eat(41)&&t.raise("Unmatched ')'"),(t.eat(93)||t.eat(125))&&t.raise("Lone quantifier brackets")),t.maxBackReference>t.numCapturingParens&&t.raise("Invalid escape");for(var e=0,n=t.backReferenceNames;e<n.length;e+=1){var s=n[e];t.groupNames[s]||t.raise("Invalid named capture referenced")}},Nt.regexp_disjunction=function(t){var e=this.options.ecmaVersion>=16;for(e&&(t.branchID=new Pt(t.branchID,null)),this.regexp_alternative(t);t.eat(124);)e&&(t.branchID=t.branchID.sibling()),this.regexp_alternative(t);e&&(t.branchID=t.branchID.parent),this.regexp_eatQuantifier(t,!0)&&t.raise("Nothing to repeat"),t.eat(123)&&t.raise("Lone quantifier brackets")},Nt.regexp_alternative=function(t){for(;t.pos<t.source.length&&this.regexp_eatTerm(t););},Nt.regexp_eatTerm=function(t){return this.regexp_eatAssertion(t)?(t.lastAssertionIsQuantifiable&&this.regexp_eatQuantifier(t)&&t.switchU&&t.raise("Invalid quantifier"),!0):!!(t.switchU?this.regexp_eatAtom(t):this.regexp_eatExtendedAtom(t))&&(this.regexp_eatQuantifier(t),!0)},Nt.regexp_eatAssertion=function(t){var e=t.pos;if(t.lastAssertionIsQuantifiable=!1,t.eat(94)||t.eat(36))return!0;if(t.eat(92)){if(t.eat(66)||t.eat(98))return!0;t.pos=e}if(t.eat(40)&&t.eat(63)){var n=!1;if(9>this.options.ecmaVersion||(n=t.eat(60)),t.eat(61)||t.eat(33))return this.regexp_disjunction(t),t.eat(41)||t.raise("Unterminated group"),t.lastAssertionIsQuantifiable=!n,!0}return t.pos=e,!1},Nt.regexp_eatQuantifier=function(t,e){return void 0===e&&(e=!1),!!this.regexp_eatQuantifierPrefix(t,e)&&(t.eat(63),!0)},Nt.regexp_eatQuantifierPrefix=function(t,e){return t.eat(42)||t.eat(43)||t.eat(63)||this.regexp_eatBracedQuantifier(t,e)},Nt.regexp_eatBracedQuantifier=function(t,e){var n=t.pos;if(t.eat(123)){var s=0,r=-1;if(this.regexp_eatDecimalDigits(t)&&(s=t.lastIntValue,t.eat(44)&&this.regexp_eatDecimalDigits(t)&&(r=t.lastIntValue),t.eat(125)))return-1!==r&&s>r&&!e&&t.raise("numbers out of order in {} quantifier"),!0;t.switchU&&!e&&t.raise("Incomplete quantifier"),t.pos=n}return!1},Nt.regexp_eatAtom=function(t){return this.regexp_eatPatternCharacters(t)||t.eat(46)||this.regexp_eatReverseSolidusAtomEscape(t)||this.regexp_eatCharacterClass(t)||this.regexp_eatUncapturingGroup(t)||this.regexp_eatCapturingGroup(t)},Nt.regexp_eatReverseSolidusAtomEscape=function(t){var e=t.pos;if(t.eat(92)){if(this.regexp_eatAtomEscape(t))return!0;t.pos=e}return!1},Nt.regexp_eatUncapturingGroup=function(t){var e=t.pos;if(t.eat(40)){if(t.eat(63)){if(this.options.ecmaVersion>=16){var n=this.regexp_eatModifiers(t),s=t.eat(45);if(n||s){for(var r=0;r<n.length;r++){var i=n.charAt(r);n.indexOf(i,r+1)>-1&&t.raise("Duplicate regular expression modifiers")}if(s){var a=this.regexp_eatModifiers(t);n||a||58!==t.current()||t.raise("Invalid regular expression modifiers");for(var o=0;o<a.length;o++){var c=a.charAt(o);(a.indexOf(c,o+1)>-1||n.indexOf(c)>-1)&&t.raise("Duplicate regular expression modifiers")}}}}if(t.eat(58)){if(this.regexp_disjunction(t),t.eat(41))return!0;t.raise("Unterminated group")}}t.pos=e}return!1},Nt.regexp_eatCapturingGroup=function(t){if(t.eat(40)){if(9>this.options.ecmaVersion?63===t.current()&&t.raise("Invalid group"):this.regexp_groupSpecifier(t),this.regexp_disjunction(t),t.eat(41))return t.numCapturingParens+=1,!0;t.raise("Unterminated group")}return!1},Nt.regexp_eatModifiers=function(t){for(var e="",n=0;-1!==(n=t.current())&&Mt(n);)e+=M(n),t.advance();return e},Nt.regexp_eatExtendedAtom=function(t){return t.eat(46)||this.regexp_eatReverseSolidusAtomEscape(t)||this.regexp_eatCharacterClass(t)||this.regexp_eatUncapturingGroup(t)||this.regexp_eatCapturingGroup(t)||this.regexp_eatInvalidBracedQuantifier(t)||this.regexp_eatExtendedPatternCharacter(t)},Nt.regexp_eatInvalidBracedQuantifier=function(t){return this.regexp_eatBracedQuantifier(t,!0)&&t.raise("Nothing to repeat"),!1},Nt.regexp_eatSyntaxCharacter=function(t){var e=t.current();return!!Vt(e)&&(t.lastIntValue=e,t.advance(),!0)},Nt.regexp_eatPatternCharacters=function(t){for(var e=t.pos,n=0;-1!==(n=t.current())&&!Vt(n);)t.advance();return t.pos!==e},Nt.regexp_eatExtendedPatternCharacter=function(t){var e=t.current();return-1!==e&&36!==e&&(40>e||e>43)&&46!==e&&63!==e&&91!==e&&94!==e&&124!==e&&(t.advance(),!0)},Nt.regexp_groupSpecifier=function(t){if(t.eat(63)){this.regexp_eatGroupName(t)||t.raise("Invalid group");var e=this.options.ecmaVersion>=16,n=t.groupNames[t.lastStringValue];if(n)if(e)for(var s=0,r=n;s<r.length;s+=1)r[s].separatedFrom(t.branchID)||t.raise("Duplicate capture group name");else t.raise("Duplicate capture group name");e?(n||(t.groupNames[t.lastStringValue]=[])).push(t.branchID):t.groupNames[t.lastStringValue]=!0}},Nt.regexp_eatGroupName=function(t){if(t.lastStringValue="",t.eat(60)){if(this.regexp_eatRegExpIdentifierName(t)&&t.eat(62))return!0;t.raise("Invalid capture group name")}return!1},Nt.regexp_eatRegExpIdentifierName=function(t){if(t.lastStringValue="",this.regexp_eatRegExpIdentifierStart(t)){for(t.lastStringValue+=M(t.lastIntValue);this.regexp_eatRegExpIdentifierPart(t);)t.lastStringValue+=M(t.lastIntValue);return!0}return!1},Nt.regexp_eatRegExpIdentifierStart=function(t){var e=t.pos,n=this.options.ecmaVersion>=11,s=t.current(n);return t.advance(n),92===s&&this.regexp_eatRegExpUnicodeEscapeSequence(t,n)&&(s=t.lastIntValue),function(t){return h(t,!0)||36===t||95===t}(s)?(t.lastIntValue=s,!0):(t.pos=e,!1)},Nt.regexp_eatRegExpIdentifierPart=function(t){var e=t.pos,n=this.options.ecmaVersion>=11,s=t.current(n);return t.advance(n),92===s&&this.regexp_eatRegExpUnicodeEscapeSequence(t,n)&&(s=t.lastIntValue),function(t){return p(t,!0)||36===t||95===t||8204===t||8205===t}(s)?(t.lastIntValue=s,!0):(t.pos=e,!1)},Nt.regexp_eatAtomEscape=function(t){return!!(this.regexp_eatBackReference(t)||this.regexp_eatCharacterClassEscape(t)||this.regexp_eatCharacterEscape(t)||t.switchN&&this.regexp_eatKGroupName(t))||(t.switchU&&(99===t.current()&&t.raise("Invalid unicode escape"),t.raise("Invalid escape")),!1)},Nt.regexp_eatBackReference=function(t){var e=t.pos;if(this.regexp_eatDecimalEscape(t)){var n=t.lastIntValue;if(t.switchU)return n>t.maxBackReference&&(t.maxBackReference=n),!0;if(n<=t.numCapturingParens)return!0;t.pos=e}return!1},Nt.regexp_eatKGroupName=function(t){if(t.eat(107)){if(this.regexp_eatGroupName(t))return t.backReferenceNames.push(t.lastStringValue),!0;t.raise("Invalid named reference")}return!1},Nt.regexp_eatCharacterEscape=function(t){return this.regexp_eatControlEscape(t)||this.regexp_eatCControlLetter(t)||this.regexp_eatZero(t)||this.regexp_eatHexEscapeSequence(t)||this.regexp_eatRegExpUnicodeEscapeSequence(t,!1)||!t.switchU&&this.regexp_eatLegacyOctalEscapeSequence(t)||this.regexp_eatIdentityEscape(t)},Nt.regexp_eatCControlLetter=function(t){var e=t.pos;if(t.eat(99)){if(this.regexp_eatControlLetter(t))return!0;t.pos=e}return!1},Nt.regexp_eatZero=function(t){return 48===t.current()&&!Ft(t.lookahead())&&(t.lastIntValue=0,t.advance(),!0)},Nt.regexp_eatControlEscape=function(t){var e=t.current();return 116===e?(t.lastIntValue=9,t.advance(),!0):110===e?(t.lastIntValue=10,t.advance(),!0):118===e?(t.lastIntValue=11,t.advance(),!0):102===e?(t.lastIntValue=12,t.advance(),!0):114===e&&(t.lastIntValue=13,t.advance(),!0)},Nt.regexp_eatControlLetter=function(t){var e=t.current();return!!Ot(e)&&(t.lastIntValue=e%32,t.advance(),!0)},Nt.regexp_eatRegExpUnicodeEscapeSequence=function(t,e){void 0===e&&(e=!1);var n,s=t.pos,r=e||t.switchU;if(t.eat(117)){if(this.regexp_eatFixedHexDigits(t,4)){var i=t.lastIntValue;if(r&&i>=55296&&56319>=i){var a=t.pos;if(t.eat(92)&&t.eat(117)&&this.regexp_eatFixedHexDigits(t,4)){var o=t.lastIntValue;if(o>=56320&&57343>=o)return t.lastIntValue=1024*(i-55296)+(o-56320)+65536,!0}t.pos=a,t.lastIntValue=i}return!0}if(r&&t.eat(123)&&this.regexp_eatHexDigits(t)&&t.eat(125)&&(n=t.lastIntValue)>=0&&1114111>=n)return!0;r&&t.raise("Invalid unicode escape"),t.pos=s}return!1},Nt.regexp_eatIdentityEscape=function(t){if(t.switchU)return!!this.regexp_eatSyntaxCharacter(t)||!!t.eat(47)&&(t.lastIntValue=47,!0);var e=t.current();return!(99===e||t.switchN&&107===e||(t.lastIntValue=e,t.advance(),0))},Nt.regexp_eatDecimalEscape=function(t){t.lastIntValue=0;var e=t.current();if(e>=49&&57>=e){do{t.lastIntValue=10*t.lastIntValue+(e-48),t.advance()}while((e=t.current())>=48&&57>=e);return!0}return!1},Nt.regexp_eatCharacterClassEscape=function(t){var e=t.current();if(function(t){return 100===t||68===t||115===t||83===t||119===t||87===t}(e))return t.lastIntValue=-1,t.advance(),1;var n=!1;if(t.switchU&&this.options.ecmaVersion>=9&&((n=80===e)||112===e)){var s;if(t.lastIntValue=-1,t.advance(),t.eat(123)&&(s=this.regexp_eatUnicodePropertyValueExpression(t))&&t.eat(125))return n&&2===s&&t.raise("Invalid property name"),s;t.raise("Invalid property name")}return 0},Nt.regexp_eatUnicodePropertyValueExpression=function(t){var e=t.pos;if(this.regexp_eatUnicodePropertyName(t)&&t.eat(61)){var n=t.lastStringValue;if(this.regexp_eatUnicodePropertyValue(t)){var s=t.lastStringValue;return this.regexp_validateUnicodePropertyNameAndValue(t,n,s),1}}if(t.pos=e,this.regexp_eatLoneUnicodePropertyNameOrValue(t)){var r=t.lastStringValue;return this.regexp_validateUnicodePropertyNameOrValue(t,r)}return 0},Nt.regexp_validateUnicodePropertyNameAndValue=function(t,e,n){T(t.unicodeProperties.nonBinary,e)||t.raise("Invalid property name"),t.unicodeProperties.nonBinary[e].test(n)||t.raise("Invalid property value")},Nt.regexp_validateUnicodePropertyNameOrValue=function(t,e){return t.unicodeProperties.binary.test(e)?1:t.switchV&&t.unicodeProperties.binaryOfStrings.test(e)?2:void t.raise("Invalid property name")},Nt.regexp_eatUnicodePropertyName=function(t){var e=0;for(t.lastStringValue="";Rt(e=t.current());)t.lastStringValue+=M(e),t.advance();return""!==t.lastStringValue},Nt.regexp_eatUnicodePropertyValue=function(t){var e=0;for(t.lastStringValue="";Dt(e=t.current());)t.lastStringValue+=M(e),t.advance();return""!==t.lastStringValue},Nt.regexp_eatLoneUnicodePropertyNameOrValue=function(t){return this.regexp_eatUnicodePropertyValue(t)},Nt.regexp_eatCharacterClass=function(t){if(t.eat(91)){var e=t.eat(94),n=this.regexp_classContents(t);return t.eat(93)||t.raise("Unterminated character class"),e&&2===n&&t.raise("Negated character class may contain strings"),!0}return!1},Nt.regexp_classContents=function(t){return 93===t.current()?1:t.switchV?this.regexp_classSetExpression(t):(this.regexp_nonEmptyClassRanges(t),1)},Nt.regexp_nonEmptyClassRanges=function(t){for(;this.regexp_eatClassAtom(t);){var e=t.lastIntValue;if(t.eat(45)&&this.regexp_eatClassAtom(t)){var n=t.lastIntValue;!t.switchU||-1!==e&&-1!==n||t.raise("Invalid character class"),-1!==e&&-1!==n&&e>n&&t.raise("Range out of order in character class")}}},Nt.regexp_eatClassAtom=function(t){var e=t.pos;if(t.eat(92)){if(this.regexp_eatClassEscape(t))return!0;if(t.switchU){var n=t.current();(99===n||jt(n))&&t.raise("Invalid class escape"),t.raise("Invalid escape")}t.pos=e}var s=t.current();return 93!==s&&(t.lastIntValue=s,t.advance(),!0)},Nt.regexp_eatClassEscape=function(t){var e=t.pos;if(t.eat(98))return t.lastIntValue=8,!0;if(t.switchU&&t.eat(45))return t.lastIntValue=45,!0;if(!t.switchU&&t.eat(99)){if(this.regexp_eatClassControlLetter(t))return!0;t.pos=e}return this.regexp_eatCharacterClassEscape(t)||this.regexp_eatCharacterEscape(t)},Nt.regexp_classSetExpression=function(t){var e,n=1;if(this.regexp_eatClassSetRange(t));else if(e=this.regexp_eatClassSetOperand(t)){2===e&&(n=2);for(var s=t.pos;t.eatChars([38,38]);)38!==t.current()&&(e=this.regexp_eatClassSetOperand(t))?2!==e&&(n=1):t.raise("Invalid character in character class");if(s!==t.pos)return n;for(;t.eatChars([45,45]);)this.regexp_eatClassSetOperand(t)||t.raise("Invalid character in character class");if(s!==t.pos)return n}else t.raise("Invalid character in character class");for(;;)if(!this.regexp_eatClassSetRange(t)){if(!(e=this.regexp_eatClassSetOperand(t)))return n;2===e&&(n=2)}},Nt.regexp_eatClassSetRange=function(t){var e=t.pos;if(this.regexp_eatClassSetCharacter(t)){var n=t.lastIntValue;if(t.eat(45)&&this.regexp_eatClassSetCharacter(t)){var s=t.lastIntValue;return-1!==n&&-1!==s&&n>s&&t.raise("Range out of order in character class"),!0}t.pos=e}return!1},Nt.regexp_eatClassSetOperand=function(t){return this.regexp_eatClassSetCharacter(t)?1:this.regexp_eatClassStringDisjunction(t)||this.regexp_eatNestedClass(t)},Nt.regexp_eatNestedClass=function(t){var e=t.pos;if(t.eat(91)){var n=t.eat(94),s=this.regexp_classContents(t);if(t.eat(93))return n&&2===s&&t.raise("Negated character class may contain strings"),s;t.pos=e}if(t.eat(92)){var r=this.regexp_eatCharacterClassEscape(t);if(r)return r;t.pos=e}return null},Nt.regexp_eatClassStringDisjunction=function(t){var e=t.pos;if(t.eatChars([92,113])){if(t.eat(123)){var n=this.regexp_classStringDisjunctionContents(t);if(t.eat(125))return n}else t.raise("Invalid escape");t.pos=e}return null},Nt.regexp_classStringDisjunctionContents=function(t){for(var e=this.regexp_classString(t);t.eat(124);)2===this.regexp_classString(t)&&(e=2);return e},Nt.regexp_classString=function(t){for(var e=0;this.regexp_eatClassSetCharacter(t);)e++;return 1===e?1:2},Nt.regexp_eatClassSetCharacter=function(t){var e=t.pos;if(t.eat(92))return!(!this.regexp_eatCharacterEscape(t)&&!this.regexp_eatClassSetReservedPunctuator(t)&&(t.eat(98)?(t.lastIntValue=8,0):(t.pos=e,1)));var n=t.current();return!(0>n||n===t.lookahead()&&function(t){return 33===t||t>=35&&38>=t||t>=42&&44>=t||46===t||t>=58&&64>=t||94===t||96===t||126===t}(n)||function(t){return 40===t||41===t||45===t||47===t||t>=91&&93>=t||t>=123&&125>=t}(n)||(t.advance(),t.lastIntValue=n,0))},Nt.regexp_eatClassSetReservedPunctuator=function(t){var e=t.current();return!!function(t){return 33===t||35===t||37===t||38===t||44===t||45===t||t>=58&&62>=t||64===t||96===t||126===t}(e)&&(t.lastIntValue=e,t.advance(),!0)},Nt.regexp_eatClassControlLetter=function(t){var e=t.current();return!(!Ft(e)&&95!==e||(t.lastIntValue=e%32,t.advance(),0))},Nt.regexp_eatHexEscapeSequence=function(t){var e=t.pos;if(t.eat(120)){if(this.regexp_eatFixedHexDigits(t,2))return!0;t.switchU&&t.raise("Invalid escape"),t.pos=e}return!1},Nt.regexp_eatDecimalDigits=function(t){var e=t.pos,n=0;for(t.lastIntValue=0;Ft(n=t.current());)t.lastIntValue=10*t.lastIntValue+(n-48),t.advance();return t.pos!==e},Nt.regexp_eatHexDigits=function(t){var e=t.pos,n=0;for(t.lastIntValue=0;Bt(n=t.current());)t.lastIntValue=16*t.lastIntValue+Ut(n),t.advance();return t.pos!==e},Nt.regexp_eatLegacyOctalEscapeSequence=function(t){if(this.regexp_eatOctalDigit(t)){var e=t.lastIntValue;if(this.regexp_eatOctalDigit(t)){var n=t.lastIntValue;3>=e&&this.regexp_eatOctalDigit(t)?t.lastIntValue=64*e+8*n+t.lastIntValue:t.lastIntValue=8*e+n}else t.lastIntValue=e;return!0}return!1},Nt.regexp_eatOctalDigit=function(t){var e=t.current();return jt(e)?(t.lastIntValue=e-48,t.advance(),!0):(t.lastIntValue=0,!1)},Nt.regexp_eatFixedHexDigits=function(t,e){var n=t.pos;t.lastIntValue=0;for(var s=0;e>s;++s){var r=t.current();if(!Bt(r))return t.pos=n,!1;t.lastIntValue=16*t.lastIntValue+Ut(r),t.advance()}return!0};var Wt=function(t){this.type=t.type,this.value=t.value,this.start=t.start,this.end=t.end,t.options.locations&&(this.loc=new R(t,t.startLoc,t.endLoc)),t.options.ranges&&(this.range=[t.start,t.end])},$t=j.prototype;function qt(t){return"function"!=typeof BigInt?null:BigInt(t.replace(/_/g,""))}$t.next=function(t){!t&&this.type.keyword&&this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword "+this.type.keyword),this.options.onToken&&this.options.onToken(new Wt(this)),this.lastTokEnd=this.end,this.lastTokStart=this.start,this.lastTokEndLoc=this.endLoc,this.lastTokStartLoc=this.startLoc,this.nextToken()},$t.getToken=function(){return this.next(),new Wt(this)},"undefined"!=typeof Symbol&&($t[Symbol.iterator]=function(){var t=this;return{next:function(){var e=t.getToken();return{done:e.type===x.eof,value:e}}}}),$t.nextToken=function(){var t=this.curContext();return t&&t.preserveSpace||this.skipSpace(),this.start=this.pos,this.options.locations&&(this.startLoc=this.curPosition()),this.pos<this.input.length?t.override?t.override(this):void this.readToken(this.fullCharCodeAtPos()):this.finishToken(x.eof)},$t.readToken=function(t){return h(t,this.options.ecmaVersion>=6)||92===t?this.readWord():this.getTokenFromCode(t)},$t.fullCharCodeAtPos=function(){var t=this.input.charCodeAt(this.pos);if(55295>=t||t>=56320)return t;var e=this.input.charCodeAt(this.pos+1);return e>56319&&57344>e?(t<<10)+e-56613888:t},$t.skipBlockComment=function(){var t=this.options.onComment&&this.curPosition(),e=this.pos,n=this.input.indexOf("*/",this.pos+=2);if(-1===n&&this.raise(this.pos-2,"Unterminated comment"),this.pos=n+2,this.options.locations)for(var s=void 0,r=e;(s=E(this.input,r,this.pos))>-1;)++this.curLine,r=this.lineStart=s;this.options.onComment&&this.options.onComment(!0,this.input.slice(e+2,n),e,this.pos,t,this.curPosition())},$t.skipLineComment=function(t){for(var e=this.pos,n=this.options.onComment&&this.curPosition(),s=this.input.charCodeAt(this.pos+=t);this.pos<this.input.length&&!w(s);)s=this.input.charCodeAt(++this.pos);this.options.onComment&&this.options.onComment(!1,this.input.slice(e+t,this.pos),e,this.pos,n,this.curPosition())},$t.skipSpace=function(){t:for(;this.pos<this.input.length;){var t=this.input.charCodeAt(this.pos);switch(t){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 t}break;default:if(!(t>8&&14>t||t>=5760&&S.test(String.fromCharCode(t))))break t;++this.pos}}},$t.finishToken=function(t,e){this.end=this.pos,this.options.locations&&(this.endLoc=this.curPosition());var n=this.type;this.type=t,this.value=e,this.updateContext(n)},$t.readToken_dot=function(){var t=this.input.charCodeAt(this.pos+1);if(t>=48&&57>=t)return this.readNumber(!0);var e=this.input.charCodeAt(this.pos+2);return 6>this.options.ecmaVersion||46!==t||46!==e?(++this.pos,this.finishToken(x.dot)):(this.pos+=3,this.finishToken(x.ellipsis))},$t.readToken_slash=function(){var t=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp()):61===t?this.finishOp(x.assign,2):this.finishOp(x.slash,1)},$t.readToken_mult_modulo_exp=function(t){var e=this.input.charCodeAt(this.pos+1),n=1,s=42===t?x.star:x.modulo;return 7>this.options.ecmaVersion||42!==t||42!==e||(++n,s=x.starstar,e=this.input.charCodeAt(this.pos+2)),61===e?this.finishOp(x.assign,n+1):this.finishOp(s,n)},$t.readToken_pipe_amp=function(t){var e=this.input.charCodeAt(this.pos+1);return e===t?12>this.options.ecmaVersion||61!==this.input.charCodeAt(this.pos+2)?this.finishOp(124===t?x.logicalOR:x.logicalAND,2):this.finishOp(x.assign,3):61===e?this.finishOp(x.assign,2):this.finishOp(124===t?x.bitwiseOR:x.bitwiseAND,1)},$t.readToken_caret=function(){return 61===this.input.charCodeAt(this.pos+1)?this.finishOp(x.assign,2):this.finishOp(x.bitwiseXOR,1)},$t.readToken_plus_min=function(t){var e=this.input.charCodeAt(this.pos+1);return e===t?45!==e||this.inModule||62!==this.input.charCodeAt(this.pos+2)||0!==this.lastTokEnd&&!b.test(this.input.slice(this.lastTokEnd,this.pos))?this.finishOp(x.incDec,2):(this.skipLineComment(3),this.skipSpace(),this.nextToken()):61===e?this.finishOp(x.assign,2):this.finishOp(x.plusMin,1)},$t.readToken_lt_gt=function(t){var e=this.input.charCodeAt(this.pos+1),n=1;return e===t?(n=62===t&&62===this.input.charCodeAt(this.pos+2)?3:2,61===this.input.charCodeAt(this.pos+n)?this.finishOp(x.assign,n+1):this.finishOp(x.bitShift,n)):33!==e||60!==t||this.inModule||45!==this.input.charCodeAt(this.pos+2)||45!==this.input.charCodeAt(this.pos+3)?(61===e&&(n=2),this.finishOp(x.relational,n)):(this.skipLineComment(4),this.skipSpace(),this.nextToken())},$t.readToken_eq_excl=function(t){var e=this.input.charCodeAt(this.pos+1);return 61===e?this.finishOp(x.equality,61===this.input.charCodeAt(this.pos+2)?3:2):61!==t||62!==e||6>this.options.ecmaVersion?this.finishOp(61===t?x.eq:x.prefix,1):(this.pos+=2,this.finishToken(x.arrow))},$t.readToken_question=function(){var t=this.options.ecmaVersion;if(t>=11){var e=this.input.charCodeAt(this.pos+1);if(46===e){var n=this.input.charCodeAt(this.pos+2);if(48>n||n>57)return this.finishOp(x.questionDot,2)}if(63===e)return 12>t||61!==this.input.charCodeAt(this.pos+2)?this.finishOp(x.coalesce,2):this.finishOp(x.assign,3)}return this.finishOp(x.question,1)},$t.readToken_numberSign=function(){var t=35;if(this.options.ecmaVersion>=13&&(++this.pos,h(t=this.fullCharCodeAtPos(),!0)||92===t))return this.finishToken(x.privateId,this.readWord1());this.raise(this.pos,"Unexpected character '"+M(t)+"'")},$t.getTokenFromCode=function(t){switch(t){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(x.parenL);case 41:return++this.pos,this.finishToken(x.parenR);case 59:return++this.pos,this.finishToken(x.semi);case 44:return++this.pos,this.finishToken(x.comma);case 91:return++this.pos,this.finishToken(x.bracketL);case 93:return++this.pos,this.finishToken(x.bracketR);case 123:return++this.pos,this.finishToken(x.braceL);case 125:return++this.pos,this.finishToken(x.braceR);case 58:return++this.pos,this.finishToken(x.colon);case 96:if(6>this.options.ecmaVersion)break;return++this.pos,this.finishToken(x.backQuote);case 48:var e=this.input.charCodeAt(this.pos+1);if(120===e||88===e)return this.readRadixNumber(16);if(this.options.ecmaVersion>=6){if(111===e||79===e)return this.readRadixNumber(8);if(98===e||66===e)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(t);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(t);case 124:case 38:return this.readToken_pipe_amp(t);case 94:return this.readToken_caret();case 43:case 45:return this.readToken_plus_min(t);case 60:case 62:return this.readToken_lt_gt(t);case 61:case 33:return this.readToken_eq_excl(t);case 63:return this.readToken_question();case 126:return this.finishOp(x.prefix,1);case 35:return this.readToken_numberSign()}this.raise(this.pos,"Unexpected character '"+M(t)+"'")},$t.finishOp=function(t,e){var n=this.input.slice(this.pos,this.pos+e);return this.pos+=e,this.finishToken(t,n)},$t.readRegexp=function(){for(var t,e,n=this.pos;;){this.pos<this.input.length||this.raise(n,"Unterminated regular expression");var s=this.input.charAt(this.pos);if(b.test(s)&&this.raise(n,"Unterminated regular expression"),t)t=!1;else{if("["===s)e=!0;else if("]"===s&&e)e=!1;else if("/"===s&&!e)break;t="\\"===s}++this.pos}var r=this.input.slice(n,this.pos);++this.pos;var i=this.pos,a=this.readWord1();this.containsEsc&&this.unexpected(i);var o=this.regexpState||(this.regexpState=new Lt(this));o.reset(n,r,a),this.validateRegExpFlags(o),this.validateRegExpPattern(o);var c=null;try{c=RegExp(r,a)}catch(t){}return this.finishToken(x.regexp,{pattern:r,flags:a,value:c})},$t.readInt=function(t,e,n){for(var s=this.options.ecmaVersion>=12&&void 0===e,r=n&&48===this.input.charCodeAt(this.pos),i=this.pos,a=0,o=0,c=0,l=null==e?1/0:e;l>c;++c,++this.pos){var u=this.input.charCodeAt(this.pos),h=void 0;if(s&&95===u)r&&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===c&&this.raiseRecoverable(this.pos,"Numeric separator is not allowed at the first of digits"),o=u;else{if((h=97>u?65>u?48>u||u>57?1/0:u-48:u-65+10:u-97+10)>=t)break;o=u,a=a*t+h}}return s&&95===o&&this.raiseRecoverable(this.pos-1,"Numeric separator is not allowed at the last of digits"),this.pos===i||null!=e&&this.pos-i!==e?null:a},$t.readRadixNumber=function(t){var e=this.pos;this.pos+=2;var n=this.readInt(t);return null==n&&this.raise(this.start+2,"Expected number in radix "+t),11>this.options.ecmaVersion||110!==this.input.charCodeAt(this.pos)?h(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"):(n=qt(this.input.slice(e,this.pos)),++this.pos),this.finishToken(x.num,n)},$t.readNumber=function(t){var e=this.pos;t||null!==this.readInt(10,void 0,!0)||this.raise(e,"Invalid number");var n=this.pos-e>=2&&48===this.input.charCodeAt(e);n&&this.strict&&this.raise(e,"Invalid number");var s=this.input.charCodeAt(this.pos);if(!n&&!t&&this.options.ecmaVersion>=11&&110===s){var r=qt(this.input.slice(e,this.pos));return++this.pos,h(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(x.num,r)}n&&/[89]/.test(this.input.slice(e,this.pos))&&(n=!1),46!==s||n||(++this.pos,this.readInt(10),s=this.input.charCodeAt(this.pos)),69!==s&&101!==s||n||(43!==(s=this.input.charCodeAt(++this.pos))&&45!==s||++this.pos,null===this.readInt(10)&&this.raise(e,"Invalid number")),h(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number");var i,a=(i=this.input.slice(e,this.pos),n?parseInt(i,8):parseFloat(i.replace(/_/g,"")));return this.finishToken(x.num,a)},$t.readCodePoint=function(){var t;if(123===this.input.charCodeAt(this.pos)){6>this.options.ecmaVersion&&this.unexpected();var e=++this.pos;t=this.readHexChar(this.input.indexOf("}",this.pos)-this.pos),++this.pos,t>1114111&&this.invalidStringToken(e,"Code point out of bounds")}else t=this.readHexChar(4);return t},$t.readString=function(t){for(var e="",n=++this.pos;;){this.pos<this.input.length||this.raise(this.start,"Unterminated string constant");var s=this.input.charCodeAt(this.pos);if(s===t)break;92===s?(e+=this.input.slice(n,this.pos),e+=this.readEscapedChar(!1),n=this.pos):8232===s||8233===s?(10>this.options.ecmaVersion&&this.raise(this.start,"Unterminated string constant"),++this.pos,this.options.locations&&(this.curLine++,this.lineStart=this.pos)):(w(s)&&this.raise(this.start,"Unterminated string constant"),++this.pos)}return e+=this.input.slice(n,this.pos++),this.finishToken(x.string,e)};var Ht={};function Gt(t,e){return j.parse(t,e)}$t.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(t){if(t!==Ht)throw t;this.readInvalidTemplateToken()}this.inTemplateElement=!1},$t.invalidStringToken=function(t,e){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw Ht;this.raise(t,e)},$t.readTmplToken=function(){for(var t="",e=this.pos;;){this.pos<this.input.length||this.raise(this.start,"Unterminated template");var n=this.input.charCodeAt(this.pos);if(96===n||36===n&&123===this.input.charCodeAt(this.pos+1))return this.pos!==this.start||this.type!==x.template&&this.type!==x.invalidTemplate?(t+=this.input.slice(e,this.pos),this.finishToken(x.template,t)):36===n?(this.pos+=2,this.finishToken(x.dollarBraceL)):(++this.pos,this.finishToken(x.backQuote));if(92===n)t+=this.input.slice(e,this.pos),t+=this.readEscapedChar(!0),e=this.pos;else if(w(n)){switch(t+=this.input.slice(e,this.pos),++this.pos,n){case 13:10===this.input.charCodeAt(this.pos)&&++this.pos;case 10:t+="\n";break;default:t+=String.fromCharCode(n)}this.options.locations&&(++this.curLine,this.lineStart=this.pos),e=this.pos}else++this.pos}},$t.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(x.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")},$t.readEscapedChar=function(t){var e=this.input.charCodeAt(++this.pos);switch(++this.pos,e){case 110:return"\n";case 114:return"\r";case 120:return String.fromCharCode(this.readHexChar(2));case 117:return M(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"),t){var n=this.pos-1;this.invalidStringToken(n,"Invalid escape sequence in template string")}default:if(e>=48&&55>=e){var s=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],r=parseInt(s,8);return r>255&&(s=s.slice(0,-1),r=parseInt(s,8)),this.pos+=s.length-1,e=this.input.charCodeAt(this.pos),"0"===s&&56!==e&&57!==e||!this.strict&&!t||this.invalidStringToken(this.pos-1-s.length,t?"Octal literal in template string":"Octal literal in strict mode"),String.fromCharCode(r)}return w(e)?(this.options.locations&&(this.lineStart=this.pos,++this.curLine),""):String.fromCharCode(e)}},$t.readHexChar=function(t){var e=this.pos,n=this.readInt(16,t);return null===n&&this.invalidStringToken(e,"Bad character escape sequence"),n},$t.readWord1=function(){this.containsEsc=!1;for(var t="",e=!0,n=this.pos,s=this.options.ecmaVersion>=6;this.pos<this.input.length;){var r=this.fullCharCodeAtPos();if(p(r,s))this.pos+=r>65535?2:1;else{if(92!==r)break;this.containsEsc=!0,t+=this.input.slice(n,this.pos);var i=this.pos;117!==this.input.charCodeAt(++this.pos)&&this.invalidStringToken(this.pos,"Expecting Unicode escape sequence \\uXXXX"),++this.pos;var a=this.readCodePoint();(e?h:p)(a,s)||this.invalidStringToken(i,"Invalid Unicode escape"),t+=M(a),n=this.pos}e=!1}return t+this.input.slice(n,this.pos)},$t.readWord=function(){var t=this.readWord1(),e=x.name;return this.keywords.test(t)&&(e=y[t]),this.finishToken(e,t)},j.acorn={Parser:j,version:"8.15.0",defaultOptions:F,Position:O,SourceLocation:R,getLineInfo:D,Node:ht,TokenType:f,tokTypes:x,keywordTypes:y,TokContext:et,tokContexts:nt,isIdentifierChar:p,isIdentifierStart:h,Token:Wt,isNewLine:w,lineBreak:b,lineBreakG:_,nonASCIIwhitespace:S};class zt{constructor(t){this.value=t}}const Yt=new Map,Kt=new Map,Jt=new Set(["constructor","__proto__","prototype"]),Qt=Symbol("GyosJS CSP optional chain");function Xt(t,e,n){const s="number"==typeof n?.start?" at position "+n.start:"";return Error(`[GyosJS CSP] ${t}${s}: ${e}`)}function Zt(t){const e=Yt.get(t);if(e)return e;try{const e=Gt(`(${t})`,{ecmaVersion:"latest"}),n=e.body[0]?.expression;if(!n)throw Xt("Empty expression",t);return Yt.set(t,n),n}catch(e){if(e instanceof Error&&e.message.startsWith("[GyosJS CSP]"))throw e;const n="number"==typeof e?.pos?" at position "+(e.pos-1):"";throw Error(`[GyosJS CSP] Invalid expression${n}: ${t}`)}}function te(t,e=!1){const n=`${e?"return":"event"}:${t}`,s=Kt.get(n);if(s)return s;try{const s=Gt(t,{ecmaVersion:"latest",allowReturnOutsideFunction:e});return Kt.set(n,s),s}catch(e){const n="number"==typeof e?.pos?" at position "+e.pos:"";throw Error(`[GyosJS CSP] Invalid expression body${n}: ${t}`)}}function ee(t,e,n){if(("string"==typeof t||"number"==typeof t)&&Jt.has(t+""))throw Xt(`Access to property "${t+""}" is forbidden`,e,n);if("string"!=typeof t&&"number"!=typeof t&&"symbol"!=typeof t)throw Xt("Invalid property key",e,n);return t}function ne(t,e,n,s){if(Object.prototype.hasOwnProperty.call(e.locals,t))return e.locals[t];if(t in e.scope)return e.scope[t];if("undefined"!==t){if("NaN"===t)return NaN;if("Infinity"===t)return 1/0;throw Xt(`Undefined identifier "${t}"`,n,s)}}function se(t,e,n){const s=ie(t.object,e,n);if(s===Qt)return[Qt,""];if(null==s){if(t.optional)return[Qt,""];throw Xt("Cannot read a property of null or undefined",n,t)}return[s,ee(t.computed?ie(t.property,e,n):t.property.name,n,t.property)]}function re(t,e,n){if("Identifier"===t.type)return{get:()=>ne(t.name,e,n,t),set:n=>(Object.prototype.hasOwnProperty.call(e.locals,t.name)?e.locals[t.name]=n:e.scope[t.name]=n,n)};if("MemberExpression"===t.type){const[s,r]=se(t,e,n);if(null==s)throw Xt("Invalid assignment target",n,t);return{get:()=>s[r],set:t=>(s[r]=t,t)}}throw Xt("Invalid assignment target",n,t)}function ie(t,e,n){switch(t.type){case"Literal":if(t.regex||"bigint"==typeof t.value)throw Xt("Unsupported literal",n,t);return t.value;case"Identifier":return ne(t.name,e,n,t);case"ArrayExpression":return t.elements.map(t=>{if(t){if("SpreadElement"===t.type)throw Xt("Spread elements are not supported",n,t);return ie(t,e,n)}});case"ObjectExpression":{const s={};for(const r of t.properties){if("Property"!==r.type||"init"!==r.kind||r.method)throw Xt("Object methods, getters, setters, and spread are not supported",n,r);s[ee(r.computed?ie(r.key,e,n):r.key.name??r.key.value,n,r.key)]=r.shorthand?ne(r.key.name,e,n,r.key):ie(r.value,e,n)}return s}case"MemberExpression":{const[s,r]=se(t,e,n);return s===Qt?Qt:s[r]}case"ChainExpression":{const s=ie(t.expression,e,n);return s===Qt?void 0:s}case"CallExpression":return function(t,e,n){const s=t.arguments.map(t=>{if("SpreadElement"===t.type)throw Xt("Spread arguments are not supported",n,t);return ie(t,e,n)});if("MemberExpression"===t.callee.type){const[r,i]=se(t.callee,e,n);if(r===Qt)return Qt;const a=r[i];if(null==a&&t.optional)return Qt;if("function"!=typeof a)throw Xt("Called value is not a function",n,t.callee);return a.apply(r,s)}const r=ie(t.callee,e,n);if(r===Qt)return Qt;if(null==r&&t.optional)return Qt;if("function"!=typeof r)throw Xt("Called value is not a function",n,t.callee);return r.apply(e.scope,s)}(t,e,n);case"UnaryExpression":{if("delete"===t.operator)throw Xt("The delete operator is not supported",n,t);const s=ie(t.argument,e,n);switch(t.operator){case"!":return!s;case"+":return+s;case"-":return-s;case"typeof":return typeof s;case"void":return;default:throw Xt(`Unsupported unary operator "${t.operator}"`,n,t)}}case"BinaryExpression":{const s=ie(t.left,e,n),r=ie(t.right,e,n);switch(t.operator){case"+":return s+r;case"-":return s-r;case"*":return s*r;case"/":return s/r;case"%":return s%r;case"**":return s**r;case"==":return s==r;case"!=":return s!=r;case"===":return s===r;case"!==":return s!==r;case"<":return r>s;case"<=":return r>=s;case">":return s>r;case">=":return s>=r;case"in":return s in r;case"instanceof":return s instanceof r;default:throw Xt(`Unsupported binary operator "${t.operator}"`,n,t)}}case"LogicalExpression":{const s=ie(t.left,e,n);if("&&"===t.operator)return s&&ie(t.right,e,n);if("||"===t.operator)return s||ie(t.right,e,n);if("??"===t.operator)return s??ie(t.right,e,n);throw Xt(`Unsupported logical operator "${t.operator}"`,n,t)}case"ConditionalExpression":return ie(t.test,e,n)?ie(t.consequent,e,n):ie(t.alternate,e,n);case"AssignmentExpression":{const s=re(t.left,e,n),r="="===t.operator?void 0:s.get();if("&&="===t.operator&&!r)return r;if("||="===t.operator&&r)return r;if("??="===t.operator&&null!=r)return r;const i=ie(t.right,e,n);return s.set(function(t,e,n,s,r){switch(t){case"=":return n;case"+=":return e+n;case"-=":return e-n;case"*=":return e*n;case"/=":return e/n;case"%=":return e%n;case"**=":return e**n;case"&&=":return e&&n;case"||=":return e||n;case"??=":return e??n;default:throw Xt(`Unsupported assignment operator "${t}"`,s,r)}}(t.operator,r,i,n,t))}case"UpdateExpression":{const s=re(t.argument,e,n),r=s.get(),i="++"===t.operator?r+1:r-1;return s.set(i),t.prefix?i:r}case"SequenceExpression":{let s;for(const r of t.expressions)s=ie(r,e,n);return s}default:throw Xt(`Unsupported syntax "${t.type}"`,n,t)}}function ae(t,e,n,s){let r;for(const i of t.body)if("EmptyStatement"!==i.type){if("ExpressionStatement"!==i.type){if(s&&"ReturnStatement"===i.type)throw new zt(i.argument?ie(i.argument,e,n):void 0);throw Xt(`Unsupported statement "${i.type}"`,n,i)}r=ie(i.expression,e,n)}return r}const oe={mode:"csp",evaluate(t,e){try{const n=e?.[t];return"function"==typeof n?n.call(e):ie(Zt(t),{scope:e,locals:{}},t)}catch(t){return}},execute(t,e,n){const s=e?.[t];return"function"==typeof s?s.call(e,n):ae(te(t),{scope:e,locals:{$event:n}},t,!1)},parseScope(t){try{const e=ie(Zt(t),{scope:{},locals:{}},t);if(!e||"object"!=typeof e||Array.isArray(e))throw Xt("Inline g-scope must evaluate to an object",t);return e}catch(t){return}},createMethod(t,e){let n;try{n=te(e,!0)}catch(t){return()=>{}}return function(...s){const r={};t.forEach((t,e)=>{r[t]=s[e]});try{return ae(n,{scope:this,locals:r},e,!0)}catch(t){return t instanceof zt?t.value:void 0}}}};let ce;function le(){if(!ce)throw Error("[GyosJS] Expression runtime is not configured. Import GyosJS from a public entry point.");return ce}function ue(){return ce?.mode??"standard"}function he(t){Promise.resolve().then(t)}function pe(t){"undefined"!=typeof document?"loading"===document.readyState?document.addEventListener("DOMContentLoaded",t,{once:!0}):queueMicrotask(t):t()}function fe(t,e){let n=null;return(...s)=>{null!==n&&clearTimeout(n),n=setTimeout(()=>{t(...s)},e)}}function de(t,e){let n=0;return(...s)=>{const r=Date.now();e>r-n||(n=r,t(...s))}}function me(t){if(null===t||"object"!=typeof t)return t;if(t instanceof Date)return new Date(t.getTime());if(t instanceof Array)return t.map(t=>me(t));const e={};for(const n in t)t.hasOwnProperty(n)&&(e[n]=me(t[n]));return e}function ge(t,e){if(t===e)return!0;if("object"!=typeof t||"object"!=typeof e||null==t||null==e)return!1;const n=Object.keys(t),s=Object.keys(e);if(n.length!==s.length)return!1;for(const s of n)if(!ge(t[s],e[s]))return!1;return!0}function ye(t,e){let n=t.parentElement;for(;n&&n!==e;){if(n.hasAttribute("g-static")||n.__gyos_static__)return!0;n=n.parentElement}return!1}function ve(t){return null!==t.closest("[g-ignore]")}const xe=new Set(["__proto__","prototype","constructor"]);function be(t){return t.split(/[.[\]]+/).filter(Boolean).some(t=>xe.has(t))}const _e=()=>"undefined"!=typeof window&&window.GYOS_DEBUG,we=()=>"undefined"!=typeof window&&window.GYOS_DEBUG_VERBOSE;function Ee(t,e,n=3){const s=document.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode:t=>e(t)?NodeFilter.FILTER_ACCEPT:n}),r=[];for(;s.nextNode();)r.push(s.currentNode);return r}function Se(...t){_e()}function ke(t){let e=t.parentElement;for(;e;){if(e.hasAttribute("*if")||e.hasAttribute("*for")||e.hasAttribute("*switch")||e.hasAttribute("*await"))return!0;e=e.parentElement}return!1}let Ce=null,Ae=0;const Ie=new Set;let Te=0;const Ne=new Set;let Pe=!1;function Le(){if(0===Ne.size||Pe)return;Pe=!0;const t=Array.from(Ne);Ne.clear(),t.forEach(t=>{if(!Ie.has(t))try{t()}catch(t){}}),Pe=!1}function Me(t){Ne.add(t),Pe||0!==Te||queueMicrotask(Le)}let Ve=new Set,Oe=!1;function Re(t,e){const n="string"==typeof e?e:e?.debugLabel,s="object"==typeof e&&e?.equals?e.equals:Object.is,r=++Ae;let i=t;const a=new Set;let o=!1;const c=()=>(Ce&&(a.has(Ce)||(a.add(Ce),Ce.__dependencies&&Ce.__dependencies.add(a),we(),!o&&"undefined"!=typeof window&&window.GYOS_DEBUG_WARN_SUBSCRIBERS&&_e()&&a.size>=200&&(o=!0))),i),l=t=>{s(i,t)||(i=t,we(),u())},u=()=>{we(),Oe?a.forEach(t=>Ve.add(t)):a.forEach(t=>Me(t))},h=function(t){return 0===arguments.length?c():(l(t),t)};return Object.defineProperties(h,{value:{get:c,set:l,enumerable:!0,configurable:!0},peek:{get:()=>i,enumerable:!0,configurable:!0},update:{value:function(t){l(t(i))},enumerable:!0,configurable:!0},subscribe:{value:function(t){return a.add(t),()=>a.delete(t)},enumerable:!0,configurable:!0},__gyos_signal__:{value:!0,enumerable:!0,configurable:!0},__gyos_debug_id__:{value:r,enumerable:!1},__gyos_debug_label__:{value:n,enumerable:!1},__gyos_equals__:{value:s,enumerable:!1}}),h}function De(t){let e,n=!0,s=!0;const r=new Set;let i;const a=()=>{(n||s)&&(i&&i(),i=Fe(()=>{try{const i=t();(s||e!==i)&&(e=i,s=!1,n=!1,Oe?r.forEach(t=>Ve.add(t)):r.forEach(t=>Me(t)))}catch(t){throw t}}),n=!1)},o=()=>((n||s)&&a(),Ce&&!r.has(Ce)&&(r.add(Ce),Ce.__dependencies&&Ce.__dependencies.add(r)),e),c=function(){return o()};return Object.defineProperties(c,{value:{get:o,enumerable:!0,configurable:!0},peek:{get:()=>((n||s)&&a(),e),enumerable:!0,configurable:!0},subscribe:{value:function(t){return r.add(t),()=>r.delete(t)},enumerable:!0,configurable:!0},__gyos_computed__:{value:!0}}),c}function Fe(t){let e,n=new Set,s=!0;const r=()=>{if(!s)return;if(Ie.has(r))return void _e();if(Ie.add(r),Te++,n.forEach(t=>{t.delete(r)}),_e(),n.clear(),e)try{e()}catch(t){}const i=Ce;Ce=r,r.__dependencies=n;try{const n=t();e="function"==typeof n?n:void 0}catch(t){}finally{Ce=i,Te--,Ie.delete(r),0===Te&&Ne.size>0&&queueMicrotask(Le)}};return r(),()=>{if(s&&(s=!1,n.forEach(t=>{t.delete(r)}),n.clear(),e))try{e()}catch(t){}}}function Be(t){if(Oe)t();else{Oe=!0,Ve.clear();try{t()}catch(t){throw t}finally{Oe=!1;const t=Array.from(Ve);Ve.clear(),t.forEach(t=>{try{t()}catch(t){}})}}}function Ue(t){return t&&"function"==typeof t&&"value"in t&&"peek"in t&&"__gyos_signal__"in t}function je(){return null!==Ce}function We(t){return t&&"function"==typeof t&&"value"in t&&"peek"in t&&"__gyos_computed__"in t}function $e(t){return Ue(t)?t.value:t}function qe(t){const e=Ce;Ce=null;try{return t()}finally{Ce=e}}class He{constructor(t){this.services=new Map,this.parent=null,this.parent=t||null}set(t,e){this.services.set(t,e)}get(t){if(this.services.has(t))return this.services.get(t);if(this.parent)return this.parent.get(t);throw Error(`[GyosJS] Service "${t}" not found in DI container`)}has(t){return this.services.has(t)||(this.parent?.has(t)??!1)}createChild(){return new He(this)}}const Ge=new He,ze=new WeakMap;function Ye(t){if(ze.has(t))return ze.get(t);let e=t.parentElement,n=Ge;for(;e;){if(ze.has(e)){n=ze.get(e);break}if(e.hasAttribute("g-provide")){n=Ye(e);break}e=e.parentElement}const s=n.createChild();ze.set(t,s);const r=t.getAttribute("g-provide");if(r)try{const t=JSON.parse(r);if(!t||Array.isArray(t)||"object"!=typeof t)throw new TypeError("g-provide must contain a JSON object");Object.entries(t).forEach(([t,e])=>{s.set(t,e)})}catch(t){}return s}function Ke(t,e){Ge.set(t,e)}function Je(t,e){if(Ge.has(t))return Ge.get(t);if(void 0!==e)return e;throw Error(`[GyosJS] Service "${t}" not found in DI container`)}function Qe(){return Ge}const Xe=new Map;function Ze(t,e){Xe.set(t,e)}function tn(t,e,n=[]){const s=Xe.get(e);if(!s)return _e(),t;try{return s(t,...n)}catch(e){return _e(),t}}function en(t,e){return t.replace(/\{([^}]+)\}/g,(t,n)=>{try{const t=nn(n.trim(),e);return null==t?"":t+""}catch(e){return t}})}function nn(t,e,n=!0){if(n&&function(t){let e=!1,n="";for(let s=0;s<t.length;s++){const r=t[s],i=s>0?t[s-1]:"";if('"'!==r&&"'"!==r||"\\"===i||(e?r===n&&(e=!1,n=""):(e=!0,n=r)),"|"===r&&!e&&"|"!==(s<t.length-1?t[s+1]:"")&&"|"!==i)return!0}return!1}(t)){const{base:n,pipes:s}=function(t){const e=[];let n="",s=!1,r="",i=0;for(;i<t.length;){const a=t[i],o=i>0?t[i-1]:"";'"'!==a&&"'"!==a||"\\"===o?"|"!==a||s?(n+=a,i++):"|"===t[i+1]?(n+="||",i+=2):(e.push(n.trim()),n="",i++):(s?a===r&&(s=!1,r=""):(s=!0,r=a),n+=a,i++)}e.push(n.trim());const a=e[0],o=e.slice(1).map(t=>{const e=t.indexOf("(");if(-1===e)return{name:t.trim(),args:[]};const n=t.substring(0,e).trim();let s=0,r=-1,i=!1,a="";for(let n=e;n<t.length;n++){const e=t[n],o=n>0?t[n-1]:"";if('"'!==e&&"'"!==e||"\\"===o||(i?e===a&&(i=!1,a=""):(i=!0,a=e)),!i&&("("===e&&s++,")"===e&&(s--,0===s))){r=n;break}}if(-1===r)return{name:t,args:[]};const o=t.substring(e+1,r),c=[];if(o){let t="",e=!1,n="";for(let s=0;s<o.length;s++){const r=o[s];'"'!==r&&"'"!==r||0!==s&&"\\"===o[s-1]?","!==r||e?t+=r:(c.push(t.trim()),t=""):(e?r===n&&(e=!1,n=""):(e=!0,n=r),t+=r)}t.trim()&&c.push(t.trim())}return{name:n,args:c}});return{base:a,pipes:o}}(t);let r=sn(n,e);for(const{name:t,args:n}of s)r=tn(r,t,n.map(t=>sn(t,e)));return r}return sn(t,e)}function sn(t,e){return t.startsWith("'")&&t.endsWith("'")||t.startsWith('"')&&t.endsWith('"')?t.slice(1,-1):isNaN(Number(t))?le().evaluate(t,e):Number(t)}Ze("currency",(t,e="USD",n="en-US")=>new Intl.NumberFormat(n,{style:"currency",currency:e}).format(t)),Ze("date",(t,e="MM/DD/YYYY")=>{const n=t instanceof Date?t:new Date(t),s=t=>t.toString().padStart(2,"0");return e.replace("YYYY",n.getFullYear().toString()).replace("MM",s(n.getMonth()+1)).replace("DD",s(n.getDate())).replace("HH",s(n.getHours())).replace("mm",s(n.getMinutes())).replace("ss",s(n.getSeconds()))}),Ze("slug",t=>t.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/\s+/g,"-").replace(/-+/g,"-")),Ze("truncate",(t,e=100,n="...")=>t.length>e?t.substring(0,e)+n:t),Ze("uppercase",t=>t.toUpperCase()),Ze("lowercase",t=>t.toLowerCase()),Ze("capitalize",t=>t.charAt(0).toUpperCase()+t.slice(1).toLowerCase()),Ze("fallback",(t,e)=>t||e),Ze("json",(t,e=2)=>JSON.stringify(t,null,e)),Ze("number",(t,e=0)=>t.toFixed(e)),Ze("pluralize",(t,e,n)=>`${t} ${1===t?e:n||e+"s"}`),Ze("percent",(t,e=0)=>(100*t).toFixed(e)+"%"),Ze("join",(t,e=", ")=>Array.isArray(t)?t.join(e):t),Ze("limit",(t,e)=>Array.isArray(t)?t.slice(0,e):t),Ze("reverse",t=>"string"==typeof t?t.split("").reverse().join(""):Array.isArray(t)?[...t].reverse():t);const rn=new Map,an=new Map;function on(t){return rn.get(t)}function cn(){return rn}function ln(t){let e=rn.get(t);e&&(e.__gyos_effects__&&(e.__gyos_effects__.forEach(t=>{try{t()}catch(t){}}),e.__gyos_effects__=null),e.onUnmount&&e.onUnmount.call(e),t.__gyos_scope__=null,rn.delete(t))}function un(t){let e=t;for(;e;){if(e.__gyos_scope__)return e.__gyos_scope__;e=e.parentElement}return null}function hn(t){rn.forEach((e,n)=>{t.contains(n)&&t!==n&&ln(n)})}const pn=[];function fn(){return pn[pn.length-1]}function dn(t,e){const n=Fe(e);t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(n)}function mn(t,e){const n=fn();n?n.push({target:t,runner:e}):dn(t,e)}const gn=new Set(["SCRIPT","STYLE","NOSCRIPT","TEXTAREA","TITLE","XMP","IFRAME","NOEMBED","NOFRAMES"]);function yn(t,e,n){let s=t.parentElement;for(;s;){if(ve(s)||gn.has(s.tagName))return!0;if(s.hasAttribute("*if")||s.hasAttribute("*for"))return!0;if(s.__gyos_static__&&(void 0!==n||s!==e))return!0;if(s===e)break;s=s.parentElement}if(void 0!==n&&t.parentElement){const e=un(t.parentElement);if(e&&e!==n)return!0}return!1}function vn(t,e){const n=document.createTreeWalker(t,NodeFilter.SHOW_TEXT,null),s=[];let r;for(;r=n.nextNode();){if(yn(r,t))continue;const e=r.textContent||"";e.includes("{")&&e.includes("}")&&s.push({node:r,template:e})}s.forEach(({node:t,template:n})=>{t.textContent=en(n,e)})}const xn={classNames:["is-revealed"],rootMargin:"0px",threshold:.1},bn=new Map,_n=new WeakMap;function wn(t){const e=Number(t);return Number.isFinite(e)?Math.min(1,Math.max(0,e)):xn.threshold}function En(t){if(!Array.isArray(t))return wn(t);const e=Array.from(new Set(t.map(wn))).sort((t,e)=>t-e);return e.length?e:xn.threshold}function Sn(t){const e=t.value&&"object"==typeof t.value&&!Array.isArray(t.value)?t.value:{},n=new Set(t.arg||[]);return{classNames:"string"==typeof e.className?e.className.split(/\s+/).filter(Boolean):xn.classNames,once:"boolean"==typeof e.once?e.once:!n.has("repeat"),rootMargin:"string"==typeof e.rootMargin?e.rootMargin:xn.rootMargin,target:"parent"===e.target||n.has("parent")?"parent":"self",threshold:En(e.threshold??xn.threshold)}}function kn(t,e){const{element:n,options:s}=t;if(e){n.setAttribute("data-gyos-revealed","");for(const t of s.classNames)n.classList.add(t)}else{n.removeAttribute("data-gyos-revealed");for(const t of s.classNames)n.classList.remove(t)}}function Cn(t){if(_n.get(t.element)!==t)return;_n.delete(t.element);const e=t.pool.records.get(t.observedTarget);e&&(e.delete(t),0===e.size&&(t.pool.records.delete(t.observedTarget),t.pool.observer.unobserve(t.observedTarget))),0===t.pool.records.size&&(t.pool.observer.disconnect(),bn.delete(t.pool.key))}function An(t,e){In(t),document.documentElement.classList.add("gyos-reveal-ready");const n=Sn(e);if(n.once&&t.hasAttribute("data-gyos-revealed")){for(const e of n.classNames)t.classList.add(e);return}if("function"==typeof window.matchMedia&&window.matchMedia("(prefers-reduced-motion: reduce)").matches||"function"!=typeof window.IntersectionObserver)return void kn({element:t,options:n},!0);const s=function(t){const e=function(t){return JSON.stringify([t.rootMargin,t.threshold])}(t),n=bn.get(e);if(n)return n;let s;try{const n=new Map;s={key:e,observer:new IntersectionObserver(t=>{for(const e of t){const t=Array.from(n.get(e.target)||[]);for(const n of t)e.isIntersecting?(kn(n,!0),n.options.once&&Cn(n)):n.options.once||kn(n,!1)}},{rootMargin:t.rootMargin,threshold:t.threshold}),records:n}}catch{return null}return bn.set(e,s),s}(n);if(!s)return void kn({element:t,options:n},!0);const r="parent"===n.target&&t.parentElement||t,i={element:t,observedTarget:r,options:n,pool:s};let a=s.records.get(r);a||(a=new Set,s.records.set(r,a),s.observer.observe(r)),a.add(i),_n.set(t,i)}function In(t){const e=_n.get(t);e&&(Cn(e),e.options.once||kn(e,!1))}const Tn={mounted:An,updated(t,e){const n=Sn({...e,value:e.oldValue}),s=Sn(e);for(const e of n.classNames)s.classNames.includes(e)||t.classList.remove(e);An(t,e)},unmounted:In},Nn=new Map;function Pn(t,e){"function"==typeof e?Nn.set(t,{mounted:e,updated:e}):Nn.set(t,e)}function Ln(t,e,n,s){const r=Nn.get(e);if(!r)return()=>{};const i={value:n,oldValue:void 0,arg:s};return r.mounted&&r.mounted(t,i),()=>{r.unmounted&&r.unmounted(t)}}function Mn(t,e){const n=t.trim().replace(/[\u0000-\u0020]+/g,"").toLowerCase();return!n.startsWith("javascript:")&&!n.startsWith("vbscript:")&&(!n.startsWith("data:")||e&&/^data:image\/(?:png|gif|jpe?g|webp|avif);base64,/i.test(n))}Pn("cloak",{mounted(t,e){setTimeout(()=>t.removeAttribute("g-cloak"),e.value?e.value:0)}}),Pn("focus",{mounted(t){t.focus()}}),Pn("tooltip",{mounted(t,e){t.title=e.value},updated(t,e){t.title=e.value}}),Pn("on",{mounted(t,e){const n=e.arg?e.arg[0]:void 0;if(!n)return;const s=un(t),r=e.value,i="function"==typeof r?r:s?.[r];if("function"!=typeof i)return;if(!s)return;const a=s.$on(n,i.bind(s));t.__gyos_effects__=t.__gyos_effects__||[],t.__gyos_effects__.push(a)}}),Pn("markdown",{updated(t,e){const n=((e.value||"")+"").replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'").replace(/^### (.*$)/gim,"<h3>$1</h3>").replace(/^## (.*$)/gim,"<h2>$1</h2>").replace(/^# (.*$)/gim,"<h1>$1</h1>").replace(/^\> (.*$)/gim,"<blockquote>$1</blockquote>").replace(/^- (.*$)/gim,"<li>$1</li>").replace(/\*\*(.*)\*\*/gim,"<b>$1</b>").replace(/\*(.*)\*/gim,"<i>$1</i>").replace(/!\[(.*?)\]\((.*?)\)/gim,(t,e,n)=>Mn(n,!0)?`<img alt="${e}" src="${n}" />`:e).replace(/\[(.*?)\]\((.*?)\)/gim,(t,e,n)=>Mn(n,!1)?`<a href="${n}">${e}</a>`:e).replace(/`(.*)`/gim,"<code>$1</code>").replace(/\n/gim,"<br />");t.innerHTML=n}}),Pn("reveal",Tn);const Vn={fade:{enterFrom:"gyos-t-opacity-0",enterTo:"gyos-t-opacity-100",leaveFrom:"gyos-t-opacity-100",leaveTo:"gyos-t-opacity-0",duration:250},"slide-down":{enterFrom:"gyos-t-translate-y--100 gyos-t-opacity-0",enterTo:"gyos-t-translate-y-0 gyos-t-opacity-100",leaveFrom:"gyos-t-translate-y-0 gyos-t-opacity-100",leaveTo:"gyos-t-translate-y-100 gyos-t-opacity-0",duration:250},"slide-up":{enterFrom:"gyos-t-translate-y-100 gyos-t-opacity-0",enterTo:"gyos-t-translate-y-0 gyos-t-opacity-100",leaveFrom:"gyos-t-translate-y-0 gyos-t-opacity-100",leaveTo:"gyos-t-translate-y--100 gyos-t-opacity-0",duration:250},"slide-left":{enterFrom:"gyos-t-translate-x-100 gyos-t-opacity-0",enterTo:"gyos-t-translate-x-0 gyos-t-opacity-100",leaveFrom:"gyos-t-translate-x-0 gyos-t-opacity-100",leaveTo:"gyos-t-translate-x--100 gyos-t-opacity-0",duration:250},"slide-right":{enterFrom:"gyos-t-translate-x--100 gyos-t-opacity-0",enterTo:"gyos-t-translate-x-0 gyos-t-opacity-100",leaveFrom:"gyos-t-translate-x-0 gyos-t-opacity-100",leaveTo:"gyos-t-translate-x-100 gyos-t-opacity-0",duration:250},scale:{enterFrom:"gyos-t-scale-50 gyos-t-opacity-0",enterTo:"gyos-t-scale-100 gyos-t-opacity-100",leaveFrom:"gyos-t-scale-100 gyos-t-opacity-100",leaveTo:"gyos-t-scale-50 gyos-t-opacity-0",duration:250},zoom:{enterFrom:"gyos-t-scale-0 gyos-t-opacity-0",enterTo:"gyos-t-scale-100 gyos-t-opacity-100",leaveFrom:"gyos-t-scale-100 gyos-t-opacity-100",leaveTo:"gyos-t-scale-0 gyos-t-opacity-0",duration:250}};function On(t,e){Vn[t]=e}const Rn=new class{constructor(){this.active=new WeakMap}cancel(t){this.active.get(t)?.cancel()}enter(t,e,n=!1){return t.isConnected&&("leave"!==this.active.get(t)?.phase||n)?this.run(t,e,"enter",!1):Promise.resolve(!1)}leave(t,e,n=!0){return this.run(t,e,"leave",n)}run(t,e,n,s){this.cancel(t);const r="enter"===n?e.enterFrom:e.leaveFrom,i="enter"===n?e.enterTo:e.leaveTo,a="enter"===n?e.enter:e.leave,o="enter"===n?e.onBeforeEnter:e.onBeforeLeave,c="enter"===n?e.onAfterEnter:e.onAfterLeave,l="function"==typeof matchMedia&&matchMedia("(prefers-reduced-motion: reduce)").matches?0:e.duration??250,u=t.style.transition,h=t.style.animation;return new Promise(e=>{let p,f=!1;const d=()=>{r&&this.removeClasses(t,r),i&&this.removeClasses(t,i),t.style.transition=u,t.style.animation=h,t.removeEventListener("transitionend",g),t.removeEventListener("animationend",g),void 0!==p&&clearTimeout(p),this.active.delete(t)},m=r=>{f||(f=!0,d(),r||(c?.(t),"leave"===n&&s&&t.remove()),e(!r))},g=e=>{e.target===t&&m(!1)};this.active.set(t,{phase:n,cancel:()=>m(!0)});try{o?.(t),r&&this.applyClasses(t,r),t.offsetHeight,t.style.transition=`all ${l}ms ${"enter"===n?"ease-out":"ease-in"}`,r&&this.removeClasses(t,r),i&&this.applyClasses(t,i),a&&(t.style.animation=a),0===l?queueMicrotask(()=>m(!1)):(t.addEventListener("transitionend",g),t.addEventListener("animationend",g),p=setTimeout(()=>m(!1),l+50))}catch(t){m(!1)}})}applyClasses(t,e){e.split(" ").forEach(e=>{e&&t.classList.add(e)})}removeClasses(t,e){e.split(" ").forEach(e=>{e&&t.classList.remove(e)})}getConfig(t){return"object"==typeof t?t:Vn[t]||Vn.fade}getAvailableTransitions(){return Object.keys(Vn)}};function Dn(t){if("string"==typeof t)return Vn[t]||null;const e=Array.from(t.attributes).find(t=>"g-transition"===t.name||t.name.startsWith("g-transition."));if(!e)return null;const n=e.value;try{return JSON.parse(n)}catch{const t=Vn[n];if(!t)return Vn.fade;if(e.name.startsWith("g-transition.")){const n=e.name.match(/g-transition\.(\d+)/);if(n)return{...t,duration:parseInt(n[1],10)}}return t}}function Fn(){if("undefined"==typeof document)return;if("csp"===ue())return;const t="gyos-transitions";if(document.getElementById(t))return;const e=document.createElement("style");e.id=t,e.textContent="\n /* Opacity utilities */\n .gyos-t-opacity-0 { opacity: 0; }\n .gyos-t-opacity-100 { opacity: 1; }\n \n /* Transform - Translate Y */\n .gyos-t-translate-y-0 { transform: translateY(0); }\n .gyos-t-translate-y--100 { transform: translateY(-100%); }\n .gyos-t-translate-y-100 { transform: translateY(100%); }\n \n /* Transform - Translate X */\n .gyos-t-translate-x-0 { transform: translateX(0); }\n .gyos-t-translate-x--100 { transform: translateX(-100%); }\n .gyos-t-translate-x-100 { transform: translateX(100%); }\n \n /* Transform - Scale */\n .gyos-t-scale-0 { transform: scale(0); }\n .gyos-t-scale-50 { transform: scale(0.5); }\n .gyos-t-scale-100 { transform: scale(1); }\n \n /* Animation Keyframes */\n @keyframes gyos-fade-in {\n\t\tfrom { opacity: 0; }\n\t\tto { opacity: 1; }\n }\n \n @keyframes gyos-fade-out {\n\t\tfrom { opacity: 1; }\n\t\tto { opacity: 0; }\n }\n \n @keyframes gyos-slide-down {\n\t\tfrom { transform: translateY(-100%); opacity: 0; }\n\t\tto { transform: translateY(0); opacity: 1; }\n }\n \n @keyframes gyos-slide-up {\n\t\tfrom { transform: translateY(100%); opacity: 0; }\n\t\tto { transform: translateY(0); opacity: 1; }\n }\n \n @keyframes gyos-scale-in {\n\t\tfrom { transform: scale(0); opacity: 0; }\n\t\tto { transform: scale(1); opacity: 1; }\n }\n \n @keyframes gyos-scale-out {\n\t\tfrom { transform: scale(1); opacity: 1; }\n\t\tto { transform: scale(0); opacity: 0; }\n }\n\n [g-cloak] {\n\t\tdisplay: none !important;\n }",document.head.appendChild(e)}function Bn(t,e){const n=Array.from(t.attributes).find(t=>t.name.startsWith("g-transition"));if(!n)return null;const s=n.name.split(".").slice(1).find(t=>/^\d+$/.test(t)),r=function(t,e){const n=t.trim(),s=/^\{([\s\S]+)\}$/.exec(n);if(s){const t=nn(s[1].trim(),e);return null==t?"":t+""}return n.length>=2&&(n.startsWith("'")&&n.endsWith("'")||n.startsWith('"')&&n.endsWith('"'))?n.slice(1,-1):n}(n.value,e);return{name:r,duration:s?parseInt(s):void 0}}function Un(t){if(ve(t))return[];const e=[];Array.from(t.attributes).some(t=>t.name.startsWith("g-transition"))&&e.push(t);const n=Ee(t,t=>!ve(t),NodeFilter.FILTER_REJECT).filter(t=>Array.from(t.attributes).some(t=>t.name.startsWith("g-transition")));return e.push(...n),e}function jn(t,e,n=!1){const s=Bn(t,e);if(!s)return Promise.resolve(!0);_e();const r={...Rn.getConfig(s.name)};return s.duration&&(r.duration=s.duration),Rn.enter(t,r,n)}function Wn(t,e,n=!0){const s=Bn(t,e);if(!s)return Promise.resolve(!0);_e();const r={...Rn.getConfig(s.name)};return s.duration&&(r.duration=s.duration),Rn.leave(t,r,n)}function $n(t,e){Array.from(t.querySelectorAll("[g-show], [g-html], [g-text]")).filter(t=>!ve(t)).forEach(t=>{const n=t;if(n.hasAttribute("g-show")){const t=nn(n.getAttribute("g-show"),e);n.style.display=t?"":"none"}if(n.hasAttribute("g-html")){const t=nn(n.getAttribute("g-html"),e);n.innerHTML=t}if(n.hasAttribute("g-text")){const t=nn(n.getAttribute("g-text"),e);n.textContent=t}})}function qn(t){return{staticClasses:new Set(t.classList),dynamicClasses:new Set}}function Hn(t,e,n){const s=function(t){return"string"==typeof t?new Set(t.split(/\s+/).filter(Boolean)):t&&"object"==typeof t?new Set(Object.entries(t).filter(([,t])=>!!t).flatMap(([t])=>t.split(/\s+/).filter(Boolean))):new Set}(e);if(e&&"object"==typeof e)for(const[n,s]of Object.entries(e))if(!s)for(const e of n.split(/\s+/).filter(Boolean))t.classList.remove(e);for(const e of n.dynamicClasses)s.has(e)||n.staticClasses.has(e)||t.classList.remove(e);for(const e of s)t.classList.add(e);n.dynamicClasses=s}function Gn(t){const e=new Map;for(let n=0;n<t.length;n++){const s=t.item(n);e.set(s,{priority:t.getPropertyPriority(s),value:t.getPropertyValue(s)})}return e}function zn(t){return t.startsWith("--")||t.includes("-")?t.toLowerCase():t.replace(/[A-Z]/g,t=>"-"+t.toLowerCase())}function Yn(t){return{staticStyles:Gn(t.style),dynamicProperties:new Set}}function Kn(t,e,n){const s=n.staticStyles.get(e);s?t.style.setProperty(e,s.value,s.priority):t.style.removeProperty(e)}function Jn(t,e,n){const s=function(t){const e=document.createElement("div").style,n=new Set;if("string"==typeof t){e.cssText=t;for(const t of Gn(e).keys())n.add(t)}else if(t&&"object"==typeof t)for(const[s,r]of Object.entries(t)){const t=zn(s);n.add(t),null!=r&&!1!==r&&(s.startsWith("--")?e.setProperty(s,r+""):e[s]=r)}return{mentioned:n,values:Gn(e)}}(e);for(const e of n.dynamicProperties)s.mentioned.has(e)||Kn(t,e,n);for(const e of s.mentioned){const n=s.values.get(e);n?t.style.setProperty(e,n.value,n.priority):t.style.removeProperty(e)}n.dynamicProperties=s.mentioned}const Qn=new Set(["allowfullscreen","async","autofocus","autoplay","checked","controls","defer","disabled","formnovalidate","hidden","inert","ismap","itemscope","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","selected"]),Xn={allowfullscreen:"allowFullscreen",formnovalidate:"formNoValidate",ismap:"isMap",itemscope:"itemScope",nomodule:"noModule",novalidate:"noValidate",playsinline:"playsInline",readonly:"readOnly"},Zn=new Set(["action","background","cite","formaction","href","poster","src","xlink:href"]),ts=new Set(["BASE","EMBED","IFRAME","LINK","OBJECT","SCRIPT"]);function es(t,e,n){const s=e.toLowerCase();if(!function(t){const e=t.toLowerCase();return!(!e||e.startsWith("@")||e.startsWith(":")||e.startsWith("*")||/^on/i.test(e)||"srcdoc"===e||"xmlns"===e||e.startsWith("g-")||e.startsWith("gd-")||e.startsWith("gm-"))}(s))return t.removeAttribute(s),void _e();if(!function(t,e,n){if(!Zn.has(e))return!("data"===e&&"OBJECT"===t.tagName);if(null==n||!1===n)return!0;if(ts.has(t.tagName))return!1;const s=(n+"").trim().replace(/[\u0000-\u0020]+/g,"").toLowerCase();return!s.startsWith("javascript:")&&!s.startsWith("vbscript:")&&(!s.startsWith("data:")||"src"===e&&t instanceof HTMLImageElement&&/^data:image\/(?:png|gif|jpe?g|webp|avif);base64,/i.test(s))}(t,s,n))return t.removeAttribute(s),void _e();if(Qn.has(s)){const e=!!n;return t.toggleAttribute(s,e),void function(t,e,n){const s=Xn[e]||e;if(s in t)try{t[s]=n}catch{}}(t,s,e)}if(null==n||!1===n&&!s.startsWith("aria-")&&!s.startsWith("data-"))return void t.removeAttribute(s);const r=n+"";"value"===s&&"value"in t&&(t.value=r),t.setAttribute(s,r)}function ns(t){return Array.from(t.attributes).filter(t=>t.name.startsWith(":"))}function ss(t,e){const n=[t,...Ee(t,t=>!ve(t),NodeFilter.FILTER_REJECT)];for(const t of n)if(!ve(t))for(const n of ns(t)){const s=n.name.slice(1),r=nn(n.value,e);"class"===s?Hn(t,r,qn(t)):"style"===s?Jn(t,r,Yn(t)):es(t,s,r)}}function rs(t,e){if(!t)return;const n=document.querySelector(e);if(!n)return;const s=document.createComment("g-portal");t.parentNode?.insertBefore(s,t),t.__portal_placeholder__=s,t.__portal_target__=n,n.appendChild(t),_e()}function is(t){if(!t)return;const e=t.__portal_placeholder__;e&&e.parentNode&&(e.parentNode.insertBefore(t,e),e.remove(),delete t.__portal_placeholder__,delete t.__portal_target__,_e())}const as=new Map;function os(t,e){as.set(t,e)}function cs(t){return as.get(t)}function ls(){return Array.from(as.keys())}async function us(t,e,n){const s=e.split("|");for(const e of s){const s=e.lastIndexOf(":");let r,i=e;if(s>0){const t=e.substring(0,s),n=t.indexOf("("),a=t.lastIndexOf(")");(-1===n||a>n&&a===t.length-1)&&(i=t,r=e.substring(s+1).trim())}const a=i.match(/^(\w+)(?:\((.*?)\))?$/);if(!a)continue;const[,o,c]=a,l=c?c.split(",").map(t=>t.trim().replace(/['"]/g,"")):[],u=as.get(o);if(!u)continue;const h=await u(t,...l,n);if(!0!==h)return r||(n?.messages?.[o]?n.messages[o]:"string"==typeof h?h:"Validation failed for "+o)}return null}os("required",t=>!(null==t||""===t||Array.isArray(t)&&0===t.length)||"This field is required"),os("email",t=>!t||/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t)||"Invalid email address"),os("minLength",(t,e)=>{if(!t)return!0;const n=parseInt(e);return t.length>=n||"Minimum length is "+n}),os("maxLength",(t,e)=>{if(!t)return!0;const n=parseInt(e);return t.length<=n||"Maximum length is "+n}),os("min",(t,e)=>{if(!t)return!0;const n=parseFloat(e);return parseFloat(t)>=n||"Minimum value is "+n}),os("max",(t,e)=>{if(!t)return!0;const n=parseFloat(e);return n>=parseFloat(t)||"Maximum value is "+n}),os("number",t=>!t||!isNaN(parseFloat(t))&&isFinite(t)||"Must be a number"),os("integer",t=>!t||Number.isInteger(parseFloat(t))||"Must be an integer"),os("numeric",t=>!t||/^\d+$/.test(t)||"Must contain only digits"),os("alpha",t=>!t||/^[a-zA-Z]+$/.test(t)||"Must contain only letters"),os("alphanumeric",t=>!t||/^[a-zA-Z0-9]+$/.test(t)||"Must contain only letters and numbers"),os("pattern",(t,e)=>!t||RegExp(e).test(t)||"Invalid format"),os("same",(t,e,n)=>!t||!n?.form||t===n.form[e]||"Must match "+e),os("different",(t,e,n)=>!t||!n?.form||t!==n.form[e]||"Must be different from "+e),os("url",t=>{if(!t)return!0;try{return new URL(t),!0}catch{return"Invalid URL"}}),os("phone",t=>!t||/^0\d{9}$/.test(t)||"Invalid phone number (format: 0xxxxxxxxx)"),os("date",t=>!t||(/^\d{4}-\d{2}-\d{2}$/.test(t)?!isNaN(new Date(t).getTime())||"Invalid date":"Invalid date format (use YYYY-MM-DD)")),os("before",(t,e)=>{if(!t)return!0;const n=new Date(t);return new Date(e)>n||"Must be before "+e}),os("after",(t,e)=>!t||new Date(t)>new Date(e)||"Must be after "+e),os("password",t=>{if(!t)return!0;if(8>t.length)return"Password must be at least 8 characters";const e=/[A-Z]/.test(t),n=/[a-z]/.test(t),s=/[0-9]/.test(t);return e?n?!!s||"Password must contain at least one number":"Password must contain at least one lowercase letter":"Password must contain at least one uppercase letter"}),os("in",(t,...e)=>{if(!t)return!0;const n=e.filter(t=>"string"==typeof t||"number"==typeof t);return n.includes(t)||"Must be one of: "+n.join(", ")}),os("notIn",(t,...e)=>{if(!t)return!0;const n=e.filter(t=>"string"==typeof t||"number"==typeof t);return!n.includes(t)||"Cannot be: "+n.join(", ")}),os("between",(t,e,n)=>{if(!t)return!0;const s=parseFloat(t),r=parseFloat(e),i=parseFloat(n);return s>=r&&i>=s||`Must be between ${r} and ${i}`});const hs=new WeakSet,ps=new WeakSet,fs=new WeakMap,ds=new WeakMap,ms=Symbol("gyos.validation-field");function gs(t){const e=t[ms];if(e)return e;const n=Array.from(t.attributes).find(t=>"g-model"===t.name||t.name.startsWith("g-model."));return n?.value||t.getAttribute("name")||t.id}function ys(t,e){if(!(t instanceof HTMLInputElement))return t.value;if("checkbox"===t.type)return t.checked?t.value:"";if("radio"!==t.type)return t.value;const n=gs(t),s=Array.from(e.querySelectorAll('input[type="radio"]')).find(e=>!(ve(e)||!e.checked||(!t.name||e.name!==t.name)&&gs(e)!==n));return s?.value??""}function vs(t){return fs.has(t)||fs.set(t,{errors:Re({}),touched:Re({}),$invalid:Re(!1),$valid:Re(!0),$dirty:Re(!1),$pristine:Re(!0)}),fs.get(t)}function xs(t){const e=t.errors.value,n=t.touched.value,s=Object.values(e).some(t=>null!==t),r=Object.values(n).some(t=>t);t.$invalid.value!==s&&(t.$invalid.value=s,t.$valid.value=!s),t.$dirty.value!==r&&(t.$dirty.value=r,t.$pristine.value=!r)}const bs={enter:"enter",esc:"escape",escape:"escape",space:" ",up:"arrowup",down:"arrowdown",left:"arrowleft",right:"arrowright",delete:"delete",tab:"tab"},_s=new Set(["prevent","stop","once","capture","passive","debounce","outside","global"]);function ws(t,e,n,s){s.includes("prevent")&&n.preventDefault(),s.includes("stop")&&n.stopPropagation();try{le().execute(t,e,n)}catch(t){}}const Es=Symbol("gyos.parent-scope");function Ss(t){return t?.[Es]}function ks(t){const e=[],n=/[^.[\]]+|\[(\d+)\]/g;let s;for(;s=n.exec(t);)void 0!==s[1]?e.push(Number(s[1])):e.push(s[0]);return e}function Cs(t,e,n){if(be(e))return;const s=ks(e);if(0===s.length)return;let r=t;Ue(r)&&(r=r.value);for(let t=0;t<s.length-1;t++){let e=r[s[t]];Ue(e)&&(e=e.value),r=e}const i=s[s.length-1],a=r[i];Ue(a)?a.value=n:r[i]=n}function As(t=document.body,e=!1){t&&((t.hasAttribute?.("g-scope")||t.__gyos_scope__)&&ln(t),t.__gyos_effects__&&(t.__gyos_effects__.forEach(t=>{try{t()}catch(t){}}),t.__gyos_effects__=null),t.querySelectorAll("*").forEach(t=>{(t.hasAttribute?.("g-scope")||t.__gyos_scope__)&&ln(t),t.__gyos_effects__&&(t.__gyos_effects__.forEach(t=>{try{t()}catch(t){}}),t.__gyos_effects__=null)}),is(t),e&&t.remove())}const Is=new WeakMap,Ts=new WeakSet,Ns=new WeakMap,Ps=new WeakMap,Ls=new WeakMap,Ms=new WeakMap,Vs=Symbol.for("gyos_scope_version");function Os(t){const e=Gs(t),n=new Set,s=t=>{if(n.has(t))return;n.add(t),t.value=t.value+1;const e=Ms.get(t);e&&e.forEach(t=>s(t))};s(e)}function Rs(t){return t instanceof Date||t instanceof RegExp||t instanceof Map||t instanceof Set||t instanceof WeakMap||t instanceof WeakSet||t instanceof Promise}function Ds(t){return"string"==typeof t&&(t.startsWith("__gyos_")||t.startsWith("$")||["onMount","onUpdate","onUnmount"].includes(t))}function Fs(t,e,n){let s=Ns.get(t);s||(s=new Map,Ns.set(t,s));let r=s.get(e);return r||(r=Re(n,_e()?`(${e.toString()})`:void 0),s.set(e,r)),r}const Bs=Symbol.for("gyos.store");function Us(t){return!(!t||!t[Bs])}const js=Symbol.for("gyos.raw");function Ws(t){return t.hasOwnProperty(js)||Reflect.defineProperty(t,js,{value:!0,enumerable:!1}),t}function $s(t){return!(!t||!t[js])}const qs=Symbol.for("gyos.shallow");function Hs(t){return t.hasOwnProperty(qs)||Reflect.defineProperty(t,qs,{value:!0,enumerable:!1}),t}function Gs(t){let e=Ps.get(t);return e||(e=Re(0),Ps.set(t,e)),e}function zs(t){if(!t||"object"!=typeof t||Rs(t))return t;if(Ts.has(t))return t;if($s(t))return t;if(Us(t))return t;if(Is.has(t))return Is.get(t);let e;e=new Proxy(t,{get(t,n,s){const r=Reflect.get(t,n,s);if(!Object.prototype.hasOwnProperty.call(t,n)){if("symbol"!=typeof n&&!Ds(n)&&!(n in t)){const e=Ns.get(t)?.get(n);if(je())return(e||Fs(t,n,void 0)).value;if(e)return e.peek}return r}if("symbol"==typeof n||Ds(n))return r;if(Us(r))return r;const i=Object.getOwnPropertyDescriptor(t,n);if(i&&i.get)return r;if("function"==typeof r)return r.bind(e);const a=je(),o=Ns.get(t)?.get(n);if(r&&"object"==typeof r&&$s(r))return a&&(o||Fs(t,n,r)).value,r;if(r&&"object"==typeof r&&!Rs(r)){const e=Ps.get(t);return Ps.has(r)||Gs(r),e&&function(t,e){const n=Gs(t);let s=Ls.get(t);s||(s=new Set,Ls.set(t,s)),s.add(e);let r=Ms.get(n);r||(r=new Set,Ms.set(n,r)),r.add(e)}(r,e),a&&(o||Fs(t,n,r)).value,(c=t)&&c[qs]?r:zs(r)}var c;return a?(o||Fs(t,n,r)).value:o?o.peek:r},set(t,e,n,s){if("symbol"==typeof e||Ds(e))return Reflect.set(t,e,n,s);const r=Object.getOwnPropertyDescriptor(t,e);if(r&&r.set){const r=Reflect.set(t,e,n,s);return r&&Os(t),r}const i=t[e];if(Us(n))return Reflect.set(t,e,n,s);if(!Reflect.set(t,e,n,s))return!1;const a=Fs(t,e,n);return Object.is(i,n)||(a.value=n,Os(t)),!0},ownKeys:t=>(Gs(t).value,Reflect.ownKeys(t).filter(t=>!Ds(t))),getOwnPropertyDescriptor(t,e){if("string"!=typeof e||!Ds(e))return Reflect.getOwnPropertyDescriptor(t,e)},deleteProperty(t,e){if("symbol"==typeof e||Ds(e))return Reflect.deleteProperty(t,e);const n=Object.prototype.hasOwnProperty.call(t,e),s=Reflect.deleteProperty(t,e);return s&&n&&(Fs(t,e,void 0).value=void 0,Os(t)),s},defineProperty(t,e,n){if("symbol"==typeof e||Ds(e))return Reflect.defineProperty(t,e,n);const s=Object.getOwnPropertyDescriptor(t,e),r=s&&"value"in s?s.value:void 0,i="value"in n?n.value:r;return!!Reflect.defineProperty(t,e,n)&&("value"in n&&(Fs(t,e,n.value).value=n.value,s&&Object.is(r,i)||Os(t)),!0)}});const n=Ps.get(t);return n&&Ps.set(e,n),Ts.add(e),Is.set(t,e),e}function Ys(t){const e=Gs(t),n=zs(t);return n.hasOwnProperty(Vs)||Object.defineProperty(n,Vs,{value:e,enumerable:!1,configurable:!1,writable:!1}),n}let Ks=null;const Js=new WeakMap,Qs=Symbol("gyos.for-scope-state");function Xs(t){return Js.has(t)||Js.set(t,t.cloneNode(!0)),Js.get(t).cloneNode(!0)}function Zs(t,e){t.__gyos_scope__=e}function tr(t,e,n,s){const r={};!function(t,e){Object.defineProperty(t,Es,{value:e,configurable:!1,enumerable:!1,writable:!1})}(r,t);const i=Re({list:n,index:s});Object.defineProperty(r,Qs,{value:i});const[a,o]=e.split(",").map(t=>t.trim());o?Object.defineProperty(r,o,{get:()=>i.value.index,enumerable:!1,configurable:!1}):Object.defineProperty(r,"$index",{get:()=>i.value.index,enumerable:!0,configurable:!1}),Object.defineProperty(r,a,{get:()=>{const t=i.value;return t.list[t.index]},set:t=>{const e=i.peek;e.list[e.index]=t},enumerable:!0,configurable:!1});for(const e in t)e in r||Object.defineProperty(r,e,{get:()=>t[e],set:n=>{t[e]=n},enumerable:!0,configurable:!0});return r}let er=null;Ks=sr;const nr=(t,e)=>{const n=un(t);return!(!n||n===e)};function sr(t,e,n=!1){if(ve(t))return;pn.push([]);const s=[t,...Ee(t,t=>!ve(t),NodeFilter.FILTER_REJECT)];if(n&&er&&t.querySelectorAll("[g-scope]").forEach(t=>{ve(t)||ke(t)||er(t)}),function(t,e){const n=[],s=t[0];t.forEach(t=>{if(function(t){let e=t,n=t.parentElement;for(;n&&n!==document.body;){if(n.hasAttribute("*await")&&(e.hasAttribute("*pending")||e.hasAttribute("*then")||e.hasAttribute("*catch")))return!0;e=n,n=n.parentElement}return!1}(t))return;const e=t.hasAttribute("*if"),r=t.hasAttribute("*for"),i=t.hasAttribute("*switch"),a=t.hasAttribute("*await");if(e||r||i||a){let e=0,o=t;for(;o&&o!==s;)e++,o=o.parentNode;let c="if";r?c="for":i?c="switch":a&&(c="await"),n.push({element:t,type:c,depth:e})}}),n.sort((t,e)=>t.depth-e.depth),n.forEach(({element:t,type:n})=>{"for"===n?function(t,e){const n=t.getAttribute("*for"),s=t.cloneNode(!0);s.removeAttribute("*for");const r=s.getAttribute("g-key"),i=!!r;i&&s.removeAttribute("g-key");const a=document.createComment("*for");t.parentNode?.replaceChild(a,t);let o,c=new Map,l=null;mn(t,()=>{const t=n.match(/(.+?)\s+in\s+(.+)/);if(!t)return;const u=t[1].trim(),h=nn(t[2].trim(),e,!1);if(!Array.isArray(h))return;const p=(f=h,Ps.get(f));var f;const d=p?p.value:void 0;(i||h!==l||d!==o)&&(l=h,o=d,qe(()=>{i?function(t,e,n,s,r,i,a){const o=new Map,c=[];n.forEach((t,e)=>{const a=tr(i,s,n,e),l=nn(r,a,!1);o.set(l,{index:e}),c.push(l)});const l=[];a.forEach((t,e)=>{o.has(e)||l.push({key:e,data:t})}),l.forEach(({key:t,data:e})=>{a.delete(t);const n=Un(e.element);if(hn(e.element),n.length>0){e.element.style.pointerEvents="none";const t=n.map(t=>Wn(t,e.scope));Promise.all(t).then(()=>{As(e.element,!0)})}else As(e.element,!0)});let u=t;c.forEach(r=>{const c=o.get(r),{index:l}=c;let h;if(a.has(r)){const t=a.get(r),e=t.scope[Qs],s=e.peek;s.list===n&&s.index===l||(e.value={list:n,index:l}),h=t.element}else{const o=Xs(e),c=tr(i,s,n,l);Zs(o,c);const p=Un(o);p.length>0&&p.forEach(t=>{const e=Bn(t,c);if(e){const n=Rn.getConfig(e.name);n.enterFrom&&n.enterFrom.split(/\s+/).forEach(e=>{e&&t.classList.add(e)})}}),h=o,t.parentNode?.insertBefore(o,u.nextSibling),Ks&&Ks(o,c,!0),a.set(r,{element:o,scope:c}),p.length>0&&requestAnimationFrame(()=>{p.forEach(t=>jn(t,c))})}h!==u.nextSibling&&t.parentNode?.insertBefore(h,u.nextSibling),u=h})}(a,s,h,u,r,e,c):function(t,e,n,s,r){let i=t.nextSibling;for(;i&&i.nodeType!==Node.COMMENT_NODE;){const t=i;i=i.nextSibling,t instanceof Element&&(hn(t),As(t,!0))}let a=t;n.forEach((i,o)=>{const c=Xs(e),l=tr(r,s,n,o);Zs(c,l);const u=Un(c);u.length>0&&u.forEach(t=>{const e=Bn(t,l);if(e){const n=Rn.getConfig(e.name);n.enterFrom&&n.enterFrom.split(/\s+/).forEach(e=>{e&&t.classList.add(e)})}}),t.parentNode?.insertBefore(c,a.nextSibling),a=c,Ks&&Ks(c,l,!0),u.length>0&&requestAnimationFrame(()=>{u.forEach(t=>jn(t,l))})})}(a,s,h,u,e)}))})}(t,e):"if"===n?function(t,e){const n=[];n.push({element:t,condition:t.getAttribute("*if")});let s=t.nextElementSibling;for(;s&&!ve(s);){if(!s.hasAttribute("*elseif")){if(s.hasAttribute("*else")){n.push({element:s,condition:null}),s.remove();break}break}{n.push({element:s,condition:s.getAttribute("*elseif")});const t=s.nextElementSibling;s.remove(),s=t}}const r=n.map(({element:t,condition:e})=>{const n=t.cloneNode(!0);return n.removeAttribute("*if"),n.removeAttribute("*elseif"),n.removeAttribute("*else"),{template:n,condition:e}}),i=document.createComment("*if-chain");t.parentNode?.replaceChild(i,t);let a=null,o=-1;mn(t,()=>{let t=-1;for(let n=0;n<r.length;n++){const{condition:s}=r[n];if(null===s){t=n;break}if(nn(s,e,!1)){t=n;break}}if(t!==o){if(a){const t=a;hn(t),a=null;const n=Un(t);if(n.length>0){t.style.pointerEvents="none";const s=n.map(t=>Wn(t,e));Promise.all(s).then(()=>{As(t,!0)})}else As(t,!0)}if(-1!==t){const{template:n}=r[t];a=Xs(n),o=t,Zs(a,e);const s=Un(a);s.length>0&&s.forEach(t=>{const n=Bn(t,e);if(n){const e=Rn.getConfig(n.name);e.enterFrom&&e.enterFrom.split(/\s+/).forEach(e=>{e&&t.classList.add(e)})}}),i.parentNode?.insertBefore(a,i.nextSibling),Ks&&Ks(a,e,!0),s.length>0&&requestAnimationFrame(()=>{s.forEach(t=>jn(t,e))})}else o=-1}})}(t,e):"switch"===n?function(t,e){const n=t.getAttribute("*switch"),s=[];Array.from(t.children).forEach(t=>{ve(t)||(t.hasAttribute("*case")?s.push({element:t,value:t.getAttribute("*case")}):t.hasAttribute("*default")&&s.push({element:t,value:null}))});const r=s.map(({element:t,value:e})=>{const n=t.cloneNode(!0);return n.removeAttribute("*case"),n.removeAttribute("*default"),t.remove(),{template:n,value:e}});t.removeAttribute("*switch");const i=document.createComment("*switch-content");t.appendChild(i);let a=null,o=-1;mn(t,()=>{const t=nn(n,e,!1);let s=-1;for(let n=0;n<r.length;n++){const{value:i}=r[n];if(null===i){-1===s&&(s=n);break}if(t===nn(i,e,!1)){s=n;break}}if(s!==o){if(a){const t=a;hn(t),a=null;const n=Un(t);if(n.length>0){t.style.pointerEvents="none";const s=n.map(t=>Wn(t,e));Promise.all(s).then(()=>{As(t,!0)})}else As(t,!0)}if(-1!==s){const{template:t}=r[s];a=Xs(t),o=s,Zs(a,e);const n=Un(a);n.length>0&&n.forEach(t=>{const n=Bn(t,e);if(n){const e=Rn.getConfig(n.name);e.enterFrom&&e.enterFrom.split(/\s+/).forEach(e=>{e&&t.classList.add(e)})}}),i.parentNode?.insertBefore(a,i.nextSibling),Ks&&Ks(a,e,!0),n.length>0&&requestAnimationFrame(()=>{n.forEach(t=>jn(t,e))})}else o=-1}})}(t,e):"await"===n&&function(t,e){const n=t.getAttribute("*await");t.removeAttribute("*await");const s=Array.from(t.children);let r=null,i=null,a=null;s.forEach(t=>{if(!ve(t))if(t.hasAttribute("*pending"))r=t.cloneNode(!0),r.removeAttribute("*pending"),t.remove();else if(t.hasAttribute("*then")){const e=t.getAttribute("*then")||null;i={template:t.cloneNode(!0),varName:e},i.template.removeAttribute("*then"),t.remove()}else if(t.hasAttribute("*catch")){const e=t.getAttribute("*catch")||null;a={template:t.cloneNode(!0),varName:e},a.template.removeAttribute("*catch"),t.remove()}});const o=document.createComment("*await");t.appendChild(o);let c=null,l="pending",u=0;const h=(t,n)=>{if(c){const t=c;c=null;const n=Un(t);if(n.length>0){t.style.pointerEvents="none";const s=n.map(t=>Wn(t,e));Promise.all(s).then(()=>{As(t,!0)})}else As(t,!0)}let s=null,u=e;if("pending"===t&&r?s=r:"fulfilled"===t&&i?(s=i.template,i.varName&&void 0!==n&&(u={...e,[i.varName]:n})):"rejected"===t&&a&&(s=a.template,a.varName&&void 0!==n&&(u={...e,[a.varName]:n})),s){c=Xs(s),l=t,Zs(c,u);const e=Un(c);e.length>0&&e.forEach(t=>{const e=Bn(t,u);if(e){const n=Rn.getConfig(e.name);n.enterFrom&&n.enterFrom.split(/\s+/).forEach(e=>{e&&t.classList.add(e)})}}),o.parentNode?.insertBefore(c,o.nextSibling),Ks&&Ks(c,u,!0),e.length>0&&requestAnimationFrame(()=>{e.forEach(t=>jn(t,u))})}};h("pending"),mn(t,()=>{const t=nn(n,e,!1),s=++u;t instanceof Promise?(h("pending"),t.then(t=>{s===u&&"pending"===l&&h("fulfilled",t)}).catch(t=>{s===u&&"pending"===l&&h("rejected",t)})):h("fulfilled",t)})}(t,e)})}(s,e),s.forEach(s=>{if(!document.body.contains(s))return;if(0===s.attributes.length)return;if(nr(s,e)&&!n)return;const r=Array.from(s.attributes);s.hasAttribute("g-static")&&function(t,e){t.removeAttribute("g-static"),t.__gyos_static__=!0,vn(t,e),$n(t,e),ss(t,e)}(s,e),s.hasAttribute("g-form")&&function(t,e){t instanceof HTMLFormElement&&t.hasAttribute("g-form")&&function(t,e){const n=t.getAttribute("g-form");if(!n||be(n))return;t.removeAttribute("g-form");const s=vs(t);!function(t){hs.add(t)}(t);const r=async()=>{const e=ds.get(t)||[],n={...s.touched.value};return Object.keys(n).forEach(t=>{n[t]=!0}),s.touched.value={...n},await Promise.all(e.map(t=>t())),xs(s),!s.$invalid.value};s.validateAll=r;const i={errors:s.errors,touched:s.touched,$invalid:s.$invalid,$valid:s.$valid,$dirty:s.$dirty,$pristine:s.$pristine,validateAll:r};n in e?Object.assign(e[n],i):e[n]=i;let a,o=!1,c=!1,l=!1,u=!0;const h=async n=>{if(o)o=!1;else if(n.preventDefault(),n.stopImmediatePropagation(),!c&&!l){c=!0;try{const s=await r();if(!u||!s)return;const i=t.getAttribute("g-submit");if(!i){const e="undefined"!=typeof SubmitEvent&&n instanceof SubmitEvent&&(n.submitter instanceof HTMLButtonElement||n.submitter instanceof HTMLInputElement)?n.submitter:void 0;return l=!0,void(a=setTimeout(()=>{if(l=!1,a=void 0,u){!function(t){ps.add(t)}(t),o=!0;try{t.requestSubmit(e)}finally{o&&(o=!1),function(t){ps.delete(t)}(t)}}},0))}const c=e[i];"function"==typeof c&&c.call(e)}finally{c=!1}}};t.addEventListener("submit",h,!0),t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(()=>{u=!1,void 0!==a&&clearTimeout(a),l=!1,t.removeEventListener("submit",h,!0),function(t){hs.delete(t),ps.delete(t)}(t),fs.delete(t),ds.delete(t)})}(t,e),t.querySelectorAll("[g-validate]").forEach(t=>{ve(t)||t instanceof HTMLElement&&function(t){if(!(t instanceof HTMLInputElement||t instanceof HTMLTextAreaElement||t instanceof HTMLSelectElement))return;const e=t.getAttribute("g-validate");if(!e)return;t.removeAttribute("g-validate");const n=gs(t);if(!n)return;t[ms]=n;const s=t.closest("form");if(!s)return;const r=vs(s);r.errors.value[n]=null,r.touched.value[n]=!1;const i=async()=>{const i=ys(t,s),a={};s.querySelectorAll("input, textarea, select").forEach(t=>{if(!ve(t)&&(t instanceof HTMLInputElement||t instanceof HTMLTextAreaElement||t instanceof HTMLSelectElement)){const e=gs(t);e&&(a[e]=ys(t,s))}});const o=await us(i,e,{form:a,field:n}),c=r.errors.value;c[n]!==o&&(c[n]=o,r.errors.value={...c},xs(r))};ds.has(s)||ds.set(s,[]),ds.get(s).push(i);const a=()=>{const t=r.touched.value;t[n]||(t[n]=!0,r.touched.value={...t},xs(r)),i()};let o;t.addEventListener("blur",a);const c=()=>{clearTimeout(o),o=setTimeout(()=>{i()},300)};t.addEventListener("input",c),t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(()=>{t.removeEventListener("blur",a),t.removeEventListener("input",c),clearTimeout(o)})}(t)}),t.querySelectorAll("[g-errors]").forEach(t=>{ve(t)||t instanceof HTMLElement&&function(t){const e=t.getAttribute("g-errors");t.removeAttribute("g-errors");const n=t.closest("form");if(!n)return;const s=vs(n);if(""===e||null===e){const e=Fe(()=>{const e=s.errors.value,n=Object.entries(e).filter(([t,e])=>null!==e);t.replaceChildren(...n.map(([t,e])=>{const n=document.createElement("div"),s=document.createElement("strong");return s.textContent=t+":",n.append(s,document.createTextNode(" "+e)),n})),t.style.display=n.length?"":"none"});t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(e)}else{const n=Fe(()=>{const n=s.errors.value[e];n?(t.textContent=n,t.style.display=""):(t.textContent="",t.style.display="none")});t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(n)}}(t)})}(s,e),r.some(t=>t.name.startsWith("g-")&&!t.name.startsWith("g-portal"))&&function(t,e,n){if(!ve(t)&&!ye(t,n)){if(t.hasAttribute("g-show")){const n=t.getAttribute("g-show"),s="none"===t.style.display?"":t.style.display;let r=!1,i=0;mn(t,()=>{const a=!!nn(n,e),o=++i;return Rn.cancel(t),r?Bn(t,e)?(a?(t.style.display=s,jn(t,e,!0)):"none"!==t.style.display&&Wn(t,e,!1).then(e=>{!1!==e&&o===i&&(t.style.display="none")}),()=>Rn.cancel(t)):(t.style.display=a?s:"none",()=>Rn.cancel(t)):(r=!0,t.style.display=a?s:"none",()=>Rn.cancel(t))})}if(t.hasAttribute("g-html")){const n=t.getAttribute("g-html");mn(t,()=>{const s=nn(n,e);t.innerHTML=s})}if(t.hasAttribute("g-text")){const n=t.getAttribute("g-text");mn(t,()=>{const s=nn(n,e);t.textContent=s})}Array.from(t.attributes).forEach(n=>{if(n.name.startsWith("g-")&&!["g-scope","g-show","g-html","g-text","g-model","g-static","g-portal","g-transition","g-hydrate","g-provide"].includes(n.name)){const r=n.name.slice(2).replace(/:.+$/,""),i=(s=r,Nn.get(s)),a=n.name.split(":");let o;if(a.length>1&&(o=a.slice(1)),i){const s=()=>{if(""!==n.value.trim())return"on"===r&&"function"==typeof e[n.value]?e[n.value]:nn(n.value,e,!1)},a=s();let c=i.mounted?a:void 0,l=!i.mounted;if(i.mounted&&i.mounted(t,{value:a,arg:o,oldValue:void 0},e),i.unmounted){let e=!0;const n=()=>{e&&(e=!1,i.unmounted(t))};t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(n)}i.updated&&mn(t,()=>{const n=s();if(!l)return l=!0,void(c=n);Object.is(c,n)||(i.updated(t,{value:n,oldValue:c,arg:o},e),c=n)})}}var s})}}(s,e,t),r.some(t=>t.name.startsWith(":"))&&function(t,e,n){if(!(ve(t)||ye(t,n)||t.hasAttribute("*if")||t.hasAttribute("*for")))for(const n of ns(t)){const s=n.name.slice(1),r=n.value,i="class"===s?qn(t):void 0,a="style"===s?Yn(t):void 0;mn(t,()=>{const n=un(t)||e,o=nn(r,n);"class"===s?Hn(t,o,i):"style"===s?Jn(t,o,a):es(t,s,o)})}}(s,e,t),r.some(t=>t.name.match(/^g-model($|[.])/))&&function(t,e,n){if(ve(t))return;if(ye(t,n))return;const s=Array.from(t.attributes).find(t=>t.name.startsWith("g-model"));if(!s)return;const r=t,i=s.name.split(".").slice(1),a=s.value,o=i.includes("debounce");let c=300;if(o){const t=i.find(t=>/^\d+$/.test(t));t&&(c=parseInt(t))}_e();const l=un(t)||e,u=ks(a);"string"==typeof u[0]&&function(t,e){if(!Ss(t)||e in t)return;let n=t,s=Ss(n);for(;s;)n=s,s=Ss(n);e in n||(n[e]=void 0),Object.defineProperty(t,e,{get:()=>n[e],set:t=>{n[e]=t},configurable:!0,enumerable:!0})}(l,u[0]);const h=nn(a,l,!1);let p;"checkbox"===r.type?r.checked=!!h:"radio"===r.type?r.checked=$e(h)+""===r.value:r.value=$e(h);const f=t=>{const e=t.target;var n;("radio"!==e.type||e.checked)&&(n="checkbox"===e.type?e.checked:e.value,i.includes("number")&&(n=Number(n)),i.includes("trim")&&"string"==typeof n&&(n=n.trim()),o?(clearTimeout(p),p=setTimeout(()=>{Cs(l,a,n)},c)):Cs(l,a,n))};r.addEventListener("input",f),mn(t,()=>{const t=nn(a,l,!1);"checkbox"===r.type?r.checked=!!t:"radio"===r.type?r.checked=$e(t)+""===r.value:r.value!==t&&(r.value=$e(t))}),t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(()=>{r.removeEventListener("input",f),p&&(clearTimeout(p),p=void 0)}),t.removeAttribute(s.name)}(s,e,t)}),function(t,e){const n=document.createTreeWalker(t,NodeFilter.SHOW_TEXT,null),s=[];let r;for(;r=n.nextNode();){if(yn(r,t,e))continue;const n=r.textContent||"";n.includes("{")&&n.includes("}")&&s.push({node:r,template:n})}s.forEach(({node:t,template:n})=>{const s=t.parentElement;s&&mn(s,()=>{const s=un(t.parentElement)||e;t.textContent=en(n,s)})})}(t,e),function(t,e){const n=Ee(t,t=>!ve(t)&&!t.hasAttribute("g-static"),NodeFilter.FILTER_REJECT);n.unshift(t),n.forEach(n=>{if(ye(n,t))return;const s=un(n);s&&s!==e||Array.from(n.attributes).forEach(t=>{if(t.name.startsWith("@")){const s=t.name.substring(1).split("."),r=s[0],i=s.slice(1),a=t.value;if(i.includes("outside"))return void function(t,e,n,s,r){let i,a=!0;const o=r=>{const i=r.target;if(document.body.contains(t)){if(!(i instanceof Element&&i.closest("[g-ignore-outside-click]")||t===i||t.contains(i))){const i=un(t)||s;n.includes("once")&&c(),ws(e,i,r,n)}}else c()},c=()=>{a&&(a=!1,void 0!==i&&(clearTimeout(i),i=void 0),document.removeEventListener("click",o,!0),l.disconnect())},l=new MutationObserver(e=>{for(const n of e)n.removedNodes.forEach(e=>{(e===t||e instanceof Element&&e.contains(t))&&!document.body.contains(t)&&c()})});l.observe(document.body,{childList:!0,subtree:!0}),t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(c),i=window.setTimeout(()=>{a&&document.addEventListener("click",o,!0)},0),t.removeAttribute(r)}(n,a,i,e,t.name);const o=function(t){const e=t.findIndex(t=>"debounce"===t||/^\d+$/.test(t));if(-1===e)return 0;if("debounce"===t[e]){const n=t[e+1];return n&&/^\d+$/.test(n)?parseInt(n):300}return 0}(i),c="keyup"===r||"keydown"===r||"keypress"===r,l={timeoutId:0};let u=()=>{};const h=t=>{if(c&&!function(t,e){let n=!1;for(const t of e)if(!_s.has(t)&&!/^\d+$/.test(t)){n=!0;break}if(!n)return!0;const s=t.key.toLowerCase();for(const t of e){if(_s.has(t)||/^\d+$/.test(t))continue;const e=bs[t];if(e){if(s===e)return!0}else if(s===t.toLowerCase())return!0}return!("backspace"!==s||!e.includes("delete"))}(t,i))return;const s=()=>{i.includes("once")&&u(),Be(()=>{const s=un(n)||e;ws(a,s,t,i)})};o>0?(clearTimeout(l.timeoutId),l.timeoutId=window.setTimeout(s,o)):s()},p={};let f=n;i.includes("capture")&&(p.capture=!0),i.includes("passive")&&(p.passive=!0),i.includes("global")&&(f=document.documentElement),f.addEventListener(r,h,p),u=()=>{f.removeEventListener(r,h,!!p.capture),l.timeoutId&&clearTimeout(l.timeoutId)},n.__gyos_effects__||(n.__gyos_effects__=[]),n.__gyos_effects__.push(u),n.removeAttribute(t.name)}})})}(t,e),function(){const t=fn();if(t){for(let e=0;e<t.length;e++){const{target:n,runner:s}=t[e];dn(n,s)}t.length=0,pn.pop()}}(),t.hasAttribute("g-portal")){const e=t.getAttribute("g-portal");rs(t,e)}}const rr=new class{constructor(){this.observers=new Map,this.pending=new WeakSet}setup(t,e,n){if(this.pending.has(t))return;this.pending.add(t);const s=()=>{this.pending.delete(t),n()};switch(e){case"idle":this.hydrateOnIdle(t,s);break;case"visible":this.hydrateOnVisible(t,s);break;case"interaction":this.hydrateOnInteraction(t,s);break;default:if(e.startsWith("media(")){const n=`(${e.slice(6,-1)})`;this.hydrateOnMedia(t,n,s)}else s()}}hydrateOnIdle(t,e){let n=!0;const s=()=>{n&&(n=!1,e())};if("requestIdleCallback"in window){const e=window.requestIdleCallback(s,{timeout:2e3});this.trackCleanup(t,()=>{n=!1,window.cancelIdleCallback?.(e)})}else{const e=setTimeout(s,1);this.trackCleanup(t,()=>{n=!1,clearTimeout(e)})}}hydrateOnVisible(t,e){if(_e(),!("IntersectionObserver"in window))return _e(),void e();this.intersectionObserver||(_e(),this.intersectionObserver=new IntersectionObserver(t=>{_e(),t.forEach(t=>{if(_e(),t.isIntersecting){const e=t.target,n=this.observers.get(e);n&&(_e(),n(),this.observers.delete(e),this.intersectionObserver?.unobserve(e))}})},{rootMargin:"50px"})),this.observers.set(t,e),this.intersectionObserver.observe(t),this.trackCleanup(t,()=>this.cleanup(t)),_e()}hydrateOnInteraction(t,e){const n=["mouseenter","touchstart","focus"];let s=!1;const r=()=>{s||(s=!0,n.forEach(e=>{t.removeEventListener(e,r)}),e())};n.forEach(e=>{t.addEventListener(e,r,{once:!0,passive:!0})}),this.trackCleanup(t,()=>{s=!0,n.forEach(e=>t.removeEventListener(e,r))})}hydrateOnMedia(t,e,n){const s=window.matchMedia(e);if(s.matches)n();else{let e=!0;const r=t=>{e&&t.matches&&(e=!1,n(),s.removeEventListener("change",r))};s.addEventListener("change",r),this.trackCleanup(t,()=>{e=!1,s.removeEventListener("change",r)})}}trackCleanup(t,e){t.__gyos_effects__||(t.__gyos_effects__=[]),t.__gyos_effects__.push(()=>{this.pending.delete(t),e()})}cleanup(t){this.pending.delete(t),this.observers.delete(t),this.intersectionObserver&&this.intersectionObserver.unobserve(t)}};er=ur;const ir=new Map;function ar(t,e){if(t instanceof HTMLElement){const n=Math.random().toString(36);return t.setAttribute("g-scope",n),void ir.set(n,e)}ir.set(t,e)}function or(t){let e=0;for(;t.parentElement;)e++,t=t.parentElement;return e}function cr(t){if(t)return void(t instanceof HTMLElement?[t]:Array.from(t)).forEach(t=>lr(t));const e=[...document.querySelectorAll("[g-scope]"),...Ee(document.body,t=>{if(t.hasAttribute("g-scope"))return!1;for(const e of t.attributes){const t=e.name;if(t.startsWith("gd-")||t.startsWith("gm-"))return!0}return!1})].filter(t=>!ve(t));e.sort((t,e)=>or(e)-or(t)),e.forEach(t=>!ke(t)&&ur(t))}function lr(t){if(ve(t)||!document.body.contains(t))return;const e=[t,...Ee(t,t=>!ve(t),NodeFilter.FILTER_REJECT)].filter(t=>t.hasAttribute("g-scope")||(t=>Array.from(t.attributes).some(t=>t.name.startsWith("gd-")||t.name.startsWith("gm-")))(t));if(e.sort((t,e)=>or(e)-or(t)),e.forEach(t=>!ke(t)&&ur(t)),on(t))return;const n=un(t);n&&sr(t,n)}function ur(t){document.body.contains(t)&&(ve(t)||(cn().forEach((t,e)=>{document.body.contains(e)||As(e)}),function(t,e){const n=function(t,e){let n;const s=pr(t,t=>an.get(t));if(s)return s;n=function(t){t=decodeURIComponent(t);try{const e=t.trim();if(!e.startsWith("{"))return;const n=le().parseScope(e);return _e(),n}catch(t){return void _e()}}(e),n||(n=ir.get(e)||{});const r=function(t){const e=["constructor","__proto__","prototype","globalThis","window","document","Function","eval","require","import"],n=t=>{if(0===t.length)return t;const e=t.trim();if("true"===e.toLocaleLowerCase())return!0;if("false"===e.toLocaleLowerCase())return!1;if(!isNaN(Number(t))&&e===t)return Number(t);if(!/^[\[{]/.test(e))return t;try{return JSON.parse(e)}catch(e){return t}},s=t.attributes;let r={},i=[];for(let t=0;t<s.length;t++){const a=s[t],o=a.name.substring(3).replace(/-([a-z])/g,t=>t[1].toUpperCase());if(be(o.split(":",1)[0]))i.push(a.name);else if(a.name.match(/^gd-.+/))r[o]=n(a.value),i.push(a.name);else if(a.name.match(/^gm-.+/)){const t=decodeURIComponent(a.value.trim());e.some(e=>t.includes(e))&&_e();const n=o.split(":").slice(1),s=o.split(":")[0];try{r[s]=le().createMethod(n,t),i.push(a.name)}catch(t){_e()}}}return i.forEach(e=>t.removeAttribute(e)),r}(t);if("function"==typeof n){const e=n;return n=>{const s=e(n);return s&&"object"==typeof s?(Object.keys(r).forEach(t=>{s[t]=r[t]}),hr(t,s),s):s}}return Object.keys(r).forEach(t=>{n[t]=r[t]}),hr(t,n),n}(t,e);if(on(t))return;if(t.hasAttribute("g-static"))return;const s=function(t){return t.getAttribute("g-hydrate")||null}(t);s?rr.setup(t,s,()=>{document.body.contains(t)&&!ve(t)&&fr(t,n)}):fr(t,n)}(t,t.getAttribute("g-scope")||Math.random().toString(36))))}function hr(t,e){const n=Ee(t,t=>t.getAttributeNames().some(t=>t.startsWith("g-model"))),s=new Map;for(const t of n){if(ve(t))continue;const n=t.attributes,r=Array.from(n).find(t=>t.name.startsWith("g-model"));if(!r)continue;if(r.value.includes("."))continue;const i=t;if("radio"===i.type){if(r.value in e)continue;if(s.has(r.value)||s.set(r.value,""),i.checked){const t=r.name.split(".").includes("number")?Number(i.value):i.value;s.set(r.value,t)}continue}if(r.value in e)continue;const a="checkbox"===i.type?i.checked:i.value;e[r.value]=a,_e()}for(const[t,n]of s)t in e||(e[t]=n,_e())}function pr(t,e){if(!t.hasAttribute("g-scope-persist"))return;const n=t.getAttribute("g-scope-persist");if(!n)return;if(!n.startsWith("{")||!n.endsWith("}"))return e(n);const s=t.parentElement.__gyos_scope__;return s?e(nn(n.slice(1,-1),s,!1)):void 0}function fr(t,e){let n=null;"object"==typeof e&&(n=Ys(e));const s=function(t,e){const n={},s=new Map;return t.querySelectorAll("[g-ref]").forEach(t=>{if(ve(t))return;const e=t.getAttribute("g-ref");e&&!be(e)&&(n[e]=t)}),{inject:e=>Ye(t).get(e),provide:(e,n)=>{Ye(t).set(e,n)},$refs:n,$emit:(e,...n)=>{const r=s.get(e);r&&r.forEach(t=>{try{t(...n)}catch(t){_e()}}),t.dispatchEvent(new CustomEvent(e,{detail:n}))},$on:(t,e)=>(s.has(t)||s.set(t,new Set),s.get(t).add(e),()=>{s.get(t)?.delete(e)}),$watch:(t,n,s={})=>{if(!e)return _e(),()=>{};const{immediate:r=!1,deep:i=!1,debounce:a=0}=s;let o;if(a>0){const t=n;n=(...e)=>{clearTimeout(o),o=setTimeout(()=>{t(...e)},a)}}let c,l=!1;const u=Fe(()=>{const s=((t,e)=>{const n=e.split(".");let s=t;for(const t of n){if(null==s)return;s=s[t]}return s})(e,t),a=i&&"object"==typeof s?me(s):s;if(!l)return c=a,l=!0,void(r&&n.call(e,a,void 0));(i?!ge(c,a):c!==a)&&(n.call(e,a,c),c=i&&"object"==typeof a?me(a):a)});return e.__gyos_effects__||(e.__gyos_effects__=[]),e.__gyos_effects__.push(u),u},$effect:t=>{if(!e)return _e(),()=>{};const n=Fe(t);return e.__gyos_effects__||(e.__gyos_effects__=[]),e.__gyos_effects__.push(n),n}}}(t,n);if("function"==typeof e&&!n){const t=e(s);n=t&&"object"==typeof t?Ys(t):t}if(n&&"object"==typeof n){if(n.onUpdate){const e=n[Vs],s=Fe(()=>{e&&(e.value,on(t)&&n.onUpdate.call(n))});n.__gyos_effects__||(n.__gyos_effects__=[]),n.__gyos_effects__.push(s)}n.$refs=s.$refs,n.$emit=s.$emit,n.$on=s.$on,n.$watch=s.$watch,n.$effect=s.$effect,n.$inject=s.inject,n.$provide=s.provide,function(t,e,n){t.__gyos_scope__=e,function(t,e){if(t.hasAttribute("g-static"))return _e(),t.removeAttribute("g-static"),t.__gyos_static__=!0,vn(t,e),$n(t,e),void ss(t,e);sr(t,e)}(t,e),n&&n()}(t,n,()=>{n.onMount&&Promise.resolve(n.onMount.call(n)).catch(console.error)}),function(t,e){rn.set(t,e)}(t,n),pr(t,t=>{an.has(t)||an.set(t,n)})}else _e()}const dr=new Map;function mr(t,e){if(e){const s=Ys(e);return(n=s).hasOwnProperty(Bs)||Reflect.defineProperty(n,Bs,{value:!0,enumerable:!1}),dr.set(t,s),s}var n;const s=dr.get(t);if(!s)throw Error(`[GyosJS] Store "${t}" not found`);return s}function gr(t){return dr.has(t)}function yr(t){dr.delete(t)}function vr(){return Array.from(dr.keys())}const xr=new Map;function br(t,e){return xr.has(t)||xr.set(t,new Set),xr.get(t).add(e),()=>{xr.get(t)?.delete(e)}}function _r(t,...e){const n=xr.get(t);n&&n.forEach(t=>{try{t(...e)}catch(t){}})}function wr(t,e){e?xr.get(t)?.delete(e):xr.delete(t)}function Er(t,e){const n=(...s)=>{e(...s),wr(t,n)};return br(t,n)}function Sr(){const t={};return xr.forEach((e,n)=>{t[n]=e.size}),t}function kr(){xr.clear()}function Cr(t){const e=Re(null),n=Re(!0),s=Re(null),r=async()=>{n.value=!0,s.value=null,e.value=null;try{const n="function"==typeof t?await t():t,s="string"==typeof n?await fetch(n):n;if(!s.ok)throw Error("HTTP error! status: "+s.status);e.value=await s.json()}catch(t){s.value=t}finally{n.value=!1}};return{data:e,loading:n,error:s,refetch:r,onMount:r}}function Ar(t=0){const e=Re(t),n=De(()=>2*e.value);return{count:e,double:n,increment:(t=1)=>{e.update(e=>e+t)},decrement:(t=1)=>{e.value-=t},reset:()=>{e.update(()=>t)}}}function Ir(t=!1){const e=Re(t);return{state:e,toggle:()=>{e.value=!e.value},setTrue:()=>{e.value=!0},setFalse:()=>{e.value=!1},value:e}}function Tr(t,e){const n=localStorage.getItem(t),s=Re(n?JSON.parse(n):e??""),r=s.subscribe(()=>localStorage.setItem(t,JSON.stringify(s.value)));return{state:s,remove:()=>localStorage.removeItem(t),onUnmount:r}}function Nr(t,e){let n=null;const s=()=>{r(),null!==e&&(n=setInterval(t,e))},r=()=>{null!==n&&(clearInterval(n),n=null)};return{start:s,stop:r,onMount:()=>s(),onUnmount:()=>r(),restart:()=>{r(),s()}}}function Pr(t,e){let n=null;const s=()=>{r(),n=setTimeout(()=>{n=null,t()},e)},r=()=>{null!==n&&(clearTimeout(n),n=null)};return{start:s,clear:r,onMount:()=>s(),onUnmount:()=>r()}}function Lr(t="",e){const n=Re(t),s=Re(t);let r=null;const i=Fe(()=>{const t=n.value;null!==r&&clearTimeout(r),r=setTimeout(()=>{s.value=t},e)});return{value:n,debounced:De(()=>s.value),onUnmount:()=>{i(),null!==r&&clearTimeout(r)}}}function Mr(t="",e){const n=Re(t),s=Re(t);let r=0;const i=Fe(()=>{const t=n.value,i=Date.now();e>i-r||(r=i,s.value=t)});return{value:n,throttled:De(()=>s.value),onUnmount:()=>{i()}}}function Vr(){const t=Re(0),e=Re(0),n=n=>{t.value=n.clientX,e.value=n.clientY};return{x:t,y:e,onMount:()=>{window.addEventListener("mousemove",n)},onUnmount:()=>{window.removeEventListener("mousemove",n)}}}function Or(){const t=Re(window.innerWidth),e=Re(window.innerHeight),n=()=>{t.value=window.innerWidth,e.value=window.innerHeight};return{width:t,height:e,onMount:()=>{window.addEventListener("resize",n)},onUnmount:()=>{window.removeEventListener("resize",n)}}}function Rr(t){const e={},n={},s={},r=Object.keys(t);for(const i of r){const r=window.matchMedia(t[i]);n[i]=r,e[i]=Re(r.matches),s[i]=t=>{e[i].value=t.matches}}return{matches:e,onMount:()=>{for(const t of r){const e=n[t],r=s[t];e.addEventListener?e.addEventListener("change",r):e.addListener(r)}},onUnmount:()=>{for(const t of r){const e=n[t],r=s[t];e.removeEventListener?e.removeEventListener("change",r):e.removeListener(r)}}}}function Dr(t,e=!0){const n=Re(null),s=Re(!1),r=Re(null),i=async()=>{s.value=!0,r.value=null;try{n.value=await t()}catch(t){r.value=t}finally{s.value=!1}};return{data:n,loading:s,error:r,execute:i,onMount:()=>{e&&i()}}}class Fr{constructor(t=!0){this.element=null,this.animationFrame=null,this.hideTimer=null,this.resetTimer=null,this.currentProgress=0,this.progressBarEnabled=!0,this.progressBarEnabled=t,this.createBar()}getCurrentProgress(){return this.currentProgress}createBar(){"undefined"!=typeof document&&(this.element=document.createElement("div"),this.element.id="gyos-progress-bar",this.element.style.cssText="\n position: fixed;\n top: 0;\n left: 0;\n width: 0%;\n height: 6px;\n background: var(--gyos-progress-color, linear-gradient(90deg, #aab9ff, #77889f));\n z-index: 999999;\n transition: width 0.3s linear, opacity 0.3s linear;\n opacity: 0;\n pointer-events: none;\n box-shadow: 0 0 10px rgba(102, 126, 234, 0.5);\n ","loading"===document.readyState?document.addEventListener("DOMContentLoaded",()=>{document.body.insertAdjacentElement("beforeend",this.element)}):document.body.insertAdjacentElement("beforeend",this.element))}start(){this.element&&this.progressBarEnabled&&(this.hideTimer&&(clearTimeout(this.hideTimer),this.hideTimer=null),this.resetTimer&&(clearTimeout(this.resetTimer),this.resetTimer=null),this.currentProgress=0,this.element.style.width="0%",this.setProgress(20))}setProgress(t){this.element&&this.progressBarEnabled&&(t=Math.min(100,Math.max(0,t)),this.currentProgress=t,this.animationFrame&&cancelAnimationFrame(this.animationFrame),this.element.style.width=t+"%",this.element.style.opacity=""+Math.max(.6,t/100))}complete(){this.element&&this.progressBarEnabled&&(this.setProgress(100),this.hideTimer=window.setTimeout(()=>{this.hideTimer=null,this.hide()},300))}hide(){this.element&&(this.element.style.opacity="0",this.resetTimer&&clearTimeout(this.resetTimer),this.resetTimer=window.setTimeout(()=>{this.resetTimer=null,this.element&&(this.element.style.width="0%",this.currentProgress=0)},300))}}function Br(t){t&&t.parentNode&&t.remove()}let Ur;function jr(t){Ur=t}function Wr(){return("function"==typeof Ur?Ur():Ur)||void 0}const $r=new Set;function qr(t){let e=0;for(let n=0;n<t.length;n++)e=(e<<5)-e+t.charCodeAt(n),e&=e;return"inline:"+e}function Hr(t){if(!t.hasAttribute("g-script-once"))return!0;const e=t.src||qr(t.textContent||"");return!$r.has(e)&&($r.add(e),!0)}function Gr(t){return t.hasAttribute("g-script-once")?t.src||qr(t.textContent||""):null}function zr(t,e=Gr(t)){const n=e;n&&$r.delete(n)}function Yr(t,e,n=Gr(t)){return t.src||"module"===t.type?new Promise(s=>{let r=!1;const i=()=>{r||(r=!0,e?.removeEventListener("abort",a),s())},a=()=>{zr(t,n),t.remove(),i()};t.addEventListener("load",i,{once:!0}),t.addEventListener("error",()=>{zr(t,n),t.remove(),i()},{once:!0}),e?.aborted?a():e?.addEventListener("abort",a,{once:!0})}):Promise.resolve()}async function Kr(t,e){if(e?.aborted)return void t.remove();const n=Wr();if("csp"===ue()&&!t.src&&!n)return void(t.textContent="");const s=Gr(t);if(!Hr(t))return void(t.textContent="");const r=document.createElement("script");Array.from(t.attributes).forEach(t=>r.setAttribute(t.name,t.value)),"csp"===ue()&&r.removeAttribute("nonce"),n&&r.setAttribute("nonce",n),r.textContent=t.hasAttribute("g-script-wrap")?Qr(t.textContent):t.textContent,r.removeAttribute("g-script-wrap");const i=Yr(r,e,s);t.replaceWith(r),await i}async function Jr(t,e){const n=[];for(const e of t)e instanceof HTMLScriptElement&&n.push(e),e instanceof Element&&n.push(...Array.from(e.querySelectorAll("script")));for(const t of n)if(await Kr(t,e),e?.aborted)return}function Qr(t){return t?`(() => { ${t} })();`:t}const Xr=new Map;let Zr=0;function ti(t,e=!1){if(t.dataset.gyosPersistId)return t.dataset.gyosPersistId;const n=t.getAttribute("g-persist");if(n&&n.trim().length)return t.dataset.gyosPersistId=n.trim(),t.dataset.gyosPersistId;if(t.id)return t.dataset.gyosPersistId="id:"+t.id,t.dataset.gyosPersistId;if(!e)return null;const s="gyos-persist-"+Zr++;return t.dataset.gyosPersistId=s,s}const ei="undefined"!=typeof document?(()=>{const t=document.createElement("div");return t.style.position="fixed",t.style.left="-99999px",t.style.top="-99999px",t.style.width="0",t.style.height="0","loading"===document.readyState?document.addEventListener("DOMContentLoaded",()=>document.body.appendChild(t)):document.body.appendChild(t),t})():null;function ni(t){const e=Array.from(t.querySelectorAll("[g-persist]"));return t instanceof HTMLElement&&t.matches("[g-persist]")&&e.unshift(t),e}function si(t,e){const n=new Set;Array.from(e.attributes).forEach(e=>{n.add(e.name),t.getAttribute(e.name)!==e.value&&t.setAttribute(e.name,e.value)}),Array.from(t.attributes).forEach(e=>{n.has(e.name)||t.removeAttribute(e.name)})}function ri(t,e,n){if(e&&e.hasAttribute("g-noscroll"))return;const s=new URL(t).hash;if(s){const t=document.querySelector(s);if(t)return void t.scrollIntoView({behavior:"smooth"})}n?window.scrollTo(n.x,n.y):window.scrollTo({top:0,behavior:"smooth"})}function ii(t){return"META"===t.tagName&&"csp-nonce"===t.getAttribute("name")?.toLowerCase()}function ai(t){return"SCRIPT"===t.tagName||"STYLE"===t.tagName||function(t){return"LINK"===t.tagName&&(t.getAttribute("rel")||"").toLowerCase().split(/\s+/).includes("stylesheet")}(t)}function oi(t,e){const n=new Map;return t.map(t=>{const s=function(t,e){const n=t.tagName.toLowerCase(),s="script"===n||"style"===n?function(t){let e=0;for(let n=0;n<t.length;n++)e=(e<<5)-e+t.charCodeAt(n)|0;return e+""}(t.textContent||""):"";return`${n}|${function(t,e){const n=new Map;return Array.from(t.attributes).forEach(s=>{e.csp&&ai(t)&&"nonce"===s.name.toLowerCase()||e.csp&&ii(t)&&"content"===s.name.toLowerCase()||n.set(s.name,s.value)}),e.csp&&ai(t)&&e.activeNonce&&n.set("nonce",e.activeNonce),e.csp&&ii(t)&&e.activeNonce&&n.set("content",e.activeNonce),Array.from(n).map(([t,e])=>`${t}=${e}`).sort().join("|")}(t,e)}|${s}`}(t,e),r=n.get(s)||0;return n.set(s,r+1),{key:`${s}|${r}`,node:t}})}function ci(t,e){return!(e.csp&&(ii(t)||"STYLE"===t.tagName||"SCRIPT"===t.tagName&&!t.hasAttribute("src"))&&!e.activeNonce)}function li(t,e){e.csp&&(ii(t)?e.activeNonce&&t.setAttribute("content",e.activeNonce):ai(t)&&(t.removeAttribute("nonce"),e.activeNonce&&t.setAttribute("nonce",e.activeNonce)))}function ui(t){"STYLE"===t.tagName||"SCRIPT"===t.tagName&&t.hasAttribute("src")}async function hi(t,e,n=document.head,s){const r="csp"===ue(),i={csp:r,activeNonce:r?Wr():void 0},a=oi(t,i),o=oi(e,i),c=new Set(a.map(t=>t.key)),l=new Set(o.map(t=>t.key));a.forEach(({key:t,node:e})=>{l.has(t)||e.remove()});for(const{key:t,node:e}of o){if(s?.aborted)return;if(!c.has(t)){if(!ci(e,i)){ui(e);continue}if("STYLE"===e.tagName){const t=document.createElement("style");Array.from(e.attributes).forEach(e=>t.setAttribute(e.name,e.value)),li(t,i),t.textContent=e.textContent||"",n.appendChild(t);continue}if("SCRIPT"===e.tagName){const t=e,r=Gr(t);if(!Hr(t)){e.remove();continue}const a=document.createElement("script");Array.from(e.attributes).forEach(t=>a.setAttribute(t.name,t.value)),li(a,i),a.textContent=e.hasAttribute("g-script-wrap")?Qr(e.textContent||""):e.textContent||"",a.removeAttribute("g-script-wrap");const o=Yr(a,s,r);n.appendChild(a),await o;continue}const t=document.importNode(e,!0);li(t,i),n.appendChild(t)}}}const pi=new Set(["iframe","noembed","noframes","plaintext","script","textarea","title","xmp"]);function fi(t,e){let n="";for(let s=e;s<t.length;s+=1){const e=t[s];if(n)e===n&&(n="");else if('"'!==e&&"'"!==e){if(">"===e)return s+1}else n=e}return t.length}function di(t,e,n,s){const r="</"+n;let i=e.indexOf(r,s);for(;-1!==i;){const n=e[i+r.length];if(">"===n||/\s/.test(n||""))return{start:i,end:fi(t,i+r.length)};i=e.indexOf(r,i+r.length)}return null}function mi(t,e){const n=function(t){const e=/^<\s*style\b/i.exec(t);if(!e)return t;let n=e[0],s=e[0].length;const r=t.length-1;for(;r>s;){const e=s;for(;r>s&&/\s/.test(t[s]);)s+=1;if(s>=r||">"===t[s]){n+=t.slice(e,s);break}const i=s;for(;r>s&&!/[\s=/>]/.test(t[s]);)s+=1;if(s===i){n+=t.slice(e,s+1),s+=1;continue}const a=t.slice(i,s).toLowerCase();for(;r>s&&/\s/.test(t[s]);)s+=1;if("="===t[s]){for(s+=1;r>s&&/\s/.test(t[s]);)s+=1;const e='"'===t[s]||"'"===t[s]?t[s]:"";if(e){for(s+=1;r>s&&t[s]!==e;)s+=1;t[s]===e&&(s+=1)}else for(;r>s&&!/[\s>]/.test(t[s]);)s+=1}"nonce"!==a&&(n+=t.slice(e,s))}return n+t.slice(r)}(t);return`${n.slice(0,-1)} nonce="${s=e,s.replace(/&/g,"&").replace(/"/g,""").replace(/</g,"<").replace(/>/g,">")}">`;var s}const gi=new Map,yi=new Map,vi=new Map,xi=new Map,bi=new Map;let _i=!1,wi=0,Ei=0,Si=!0,ki=Fi(window.location.href,!0),Ci=history.state?.gyosEntryId||null,Ai=null,Ii=null;const Ti=[],Ni=[];function Pi(t){Ti.push(t)}function Li(t){Ni.push(t)}function Mi(t){document.querySelector("[g-boost]")&&(_i||"undefined"!=typeof window&&"undefined"!=typeof document&&(Si=!1!==t?.showProgress,Si&&(Ii=new Fr(Si)),document.addEventListener("click",Qi),document.addEventListener("submit",Zi),document.addEventListener("mouseover",Xi,!0),window.addEventListener("popstate",ta),"scrollRestoration"in history&&(history.scrollRestoration="manual"),document.querySelectorAll("script").forEach(t=>{const e=t.hasAttribute("g-script-once"),n=e?t.src||qr(t.textContent||""):null;t.hasAttribute("g-script-wrap")&&t.removeAttribute("g-script-wrap"),e&&n&&$r.add(n)}),_i=!0,Se()))}function Vi(){return!!document.body?.hasAttribute("g-boost")}function Oi(){return document.querySelector("[g-outlet]")}function Ri(t){t.querySelectorAll("noscript").forEach(t=>t.remove())}function Di(t){const e=(new DOMParser).parseFromString(function(t){if("csp"!==ue())return t;const e=Wr(),n=t.toLowerCase();let s="",r=0,i=0;for(;r<t.length;){const a=t.indexOf("<",r);if(-1===a){s+=t.slice(r);break}if(s+=t.slice(r,a),t.startsWith("\x3c!--",a)){const e=t.indexOf("--\x3e",a+4),n=-1===e?t.length:e+3;s+=t.slice(a,n),r=n;continue}const o=fi(t,a+1),c=t.slice(a,o),l=/^<\s*(\/?)\s*([a-z][\w:-]*)/i.exec(c);if(!l||l[1]){s+=c,r=o;continue}const u=l[2].toLowerCase();if("plaintext"===u){s+=t.slice(a);break}if("style"===u||"noscript"===u||pi.has(u)){const l=di(t,n,u,o),h=l?.end??t.length;if("noscript"===u){r=h;continue}if("style"===u){if(!e){i+=1,r=h;continue}s+=mi(c,e),s+=t.slice(o,h),r=h;continue}s+=t.slice(a,h),r=h;continue}s+=c,r=o}return s}(t),"text/html");return Ri(e),e}function Fi(t,e=!1){const n=new URL(t,window.location.href);return e||(n.hash=""),n.href}function Bi(){return`gyos-${Date.now().toString(36)}-${++Ei}`}function Ui(t=!0){if(Ci)return Ci;const e=history.state||{};return Ci=e.gyosEntryId||Bi(),t&&!e.gyosEntryId&&history.replaceState({...e,gyosEntryId:Ci},""),Ci}function ji(t,e,n){let s=bi.get(t);s||(s=new Map,bi.set(t,s)),s.set(e,n.cloneNode(!0))}function Wi(t,e){const n=bi.get(t)?.get(e);return n?.cloneNode(!0)}function $i(t){return Ai?.id===t.id&&!t.controller.signal.aborted}function qi(t){if(!$i(t))throw new DOMException("Navigation superseded","AbortError")}function Hi(t){t.controller.abort(),t.interval&&(clearInterval(t.interval),t.interval=null),t.spinner&&(Br(t.spinner),t.spinner=null)}function Gi(t){t?.catch(()=>{})}function zi(t,e){t.forEach(t=>{try{t(e)}catch(t){}})}function Yi(t,e){t.querySelectorAll("script[src]").forEach(t=>{const n=t.getAttribute("src");n&&(t.src=new URL(n,e).href)})}function Ki(t,e,n){"GET"!==(t.method||"GET").toUpperCase()?n||!t.form||HTMLFormElement.prototype.submit.call(t.form):window.location.href=e}async function Ji(t){for(;Ai;){const t=Ai;if(!t.committing){Se(),Hi(t);break}Se(),await t.done}let e;const n=new Promise(t=>{e=t}),s={id:++wi,controller:new AbortController,interval:null,spinner:null,committing:!1,done:n,resolveDone:e};Ai=s;const r=t.trigger?.hasAttribute("g-router-spin"),i=()=>{$i(s)&&70>Ii?.getCurrentProgress()&&Ii?.setProgress(Ii?.getCurrentProgress()+8*Math.random())};try{zi(Ti,t.url),Ii?.start(),(a=t.scrollSourceEntryId??Ci)&&xi.set(a,{x:window.scrollX,y:window.scrollY}),t.popstate||function(){const t=history.state||{},e={x:window.scrollX,y:window.scrollY};history.replaceState({...t,scroll:e},"")}();let e=function(t,e,n){if(e)try{const t=document.querySelector(e);if(t instanceof HTMLElement)return t}catch{}if(null!=n){const t=document.querySelectorAll("[g-outlet]")[n];if(t)return t}if(t){const e=t.getAttribute("g-target");if(e){const t=document.querySelector(e);if(t instanceof HTMLElement)return t}const n=t.closest("[g-outlet]");if(n instanceof HTMLElement)return n}const s=Oi();return s instanceof HTMLElement?s:null}(t.trigger,t.targetSelector,t.targetOutletIndex);if(!e)return void($i(s)&&Ki(t,t.url,!1));const n=(t.swapMode||t.trigger?.getAttribute("g-swap")||"inner").toLowerCase(),o=t.trigger instanceof HTMLElement&&t.trigger.hasAttribute("g-router-remove"),c=!["append","prepend"].includes(n),l=e===Oi(),u=function(t,e){if(!e.hasAttribute("g-outlet"))return null;const n=Array.from(t.querySelectorAll("[g-outlet]")).indexOf(e);return-1===n?null:n}(document,e),h=l?null:t.targetSelector||t.trigger?.getAttribute("g-target")||(e.id?"#"+e.id:null),p=t.currentHead??t.trigger?.hasAttribute("g-current-head")??!1,f={targetSelector:h,targetOutletIndex:l?null:u,swapMode:l?"inner":"morph",currentHead:p};r&&(s.spinner=function(t,e){const n=function(){const t=document.createElement("div");if(t.className="gyos-target-spinner",t.innerHTML='\n\t\t<div class="gyos-spinner-content">\n\t\t\t<svg class="gyos-spinner-icon" viewBox="0 0 50 50">\n\t\t\t\t<circle cx="25" cy="25" r="20" fill="none" stroke="currentColor" stroke-width="4" stroke-dasharray="31.4 31.4" />\n\t\t\t</svg>\n\t\t</div>\n\t',"standard"===ue()&&!document.getElementById("gyos-target-spinner-styles")){const t=document.createElement("style");t.id="gyos-target-spinner-styles",t.textContent="\n\t\t\t.gyos-target-spinner {\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t\tjustify-content: center;\n\t\t\t\tpadding: 20px;\n\t\t\t\tmin-height: 60px;\n\t\t\t}\n\t\t\t.gyos-spinner-content {\n\t\t\t\tdisplay: flex;\n\t\t\t\talign-items: center;\n\t\t\t\tgap: 10px;\n\t\t\t\tcolor: var(--gyos-spinner-color, #667eea);\n\t\t\t\tfont-size: 14px;\n\t\t\t}\n\t\t\t.gyos-spinner-icon {\n\t\t\t\twidth: 24px;\n\t\t\t\theight: 24px;\n\t\t\t\tanimation: gyos-spin 1s linear infinite;\n\t\t\t}\n\t\t\t@keyframes gyos-spin {\n\t\t\t\t0% { transform: rotate(0deg); }\n\t\t\t\t100% { transform: rotate(360deg); }\n\t\t\t}\n\t\t",document.head.appendChild(t)}return t}();return"prepend"===e?t.prepend(n):t.appendChild(n),n}(e,n));const{finalUrl:d,init:m}=function(t){const e=(t.method||"GET").toUpperCase(),n=new Headers({"X-Gyos-Boost":"1",Accept:"text/html,application/xhtml+xml"}),s={method:e,headers:n,redirect:"follow",mode:"same-origin"};let r=new URL(t.url,window.location.href);const i="GET"===e;if(t.formData)i?r=function(t,e){return e.forEach((e,n)=>{"string"==typeof e?t.searchParams.append(n,e):t.searchParams.append(n,e.name)}),t}(r,t.formData):s.body=t.formData;else if(t.jsonData){const e=(t,e)=>{"object"==typeof e?r.searchParams.append(t,JSON.stringify(e)):r.searchParams.append(t,e+"")};i?Object.entries(t.jsonData).forEach(([t,n])=>e(t,n)):(n.set("Content-Type","application/json"),s.body=JSON.stringify(t.jsonData))}return{finalUrl:r.toString(),init:s}}(t);let g,y;m.signal=s.controller.signal;const v=Fi(d);if(t.popstate&&t.historyFragment)Se();else if(t.popstate&&gi.has(v))Se(),g=gi.get(v).html;else{const n=Fi(d,!0);if("GET"===t.method.toUpperCase()&&yi.has(n)){Se();try{y=await function(t,e){return e.aborted?Promise.reject(new DOMException("Navigation superseded","AbortError")):new Promise((n,s)=>{const r=()=>s(new DOMException("Navigation superseded","AbortError"));e.addEventListener("abort",r,{once:!0}),t.then(t=>{e.removeEventListener("abort",r),n(t)},t=>{e.removeEventListener("abort",r),s(t)})})}(yi.get(n),s.controller.signal)}catch(t){if(yi.delete(n),vi.get(n)?.abort(),vi.delete(n),"AbortError"===t.name)throw t;return qi(s),void(window.location.href=d)}yi.delete(n),vi.delete(n)}else try{Ii?.setProgress(10*Math.random()+20),s.interval=setInterval(i,300),y=await fetch(d,m),qi(s),Ii?.setProgress(10*Math.random()+70),s.interval&&clearInterval(s.interval),s.interval=null}catch(e){return"AbortError"===e.name?void Se():void($i(s)&&Ki(t,d,!0))}if(qi(s),!y||!y.ok||!function(t){try{if(t.url&&new URL(t.url,window.location.href).origin!==window.location.origin)return!1}catch{return!1}const e=t.headers.get("Content-Disposition")||"";if(/\battachment\b/i.test(e))return!1;const n=(t.headers.get("Content-Type")||"").split(";",1)[0].trim().toLowerCase();return"text/html"===n||"application/xhtml+xml"===n}(y))return void($i(s)&&Ki(t,d,!0));g=await y.text(),qi(s),!t.popstate&&e.hasAttribute("g-snapshot")&&function(t,e){const n=Di(e);t.includes("#")&&(t=t.split("#")[0]),Array.from(n.scripts).forEach(t=>{t.hasAttribute("g-script-once")&&(t.textContent="")}),gi.set(t,{html:n.documentElement.outerHTML}),Se()}(Fi(y.url||d),g)}const x=g?Di(g):document.implementation.createHTMLDocument(),b=t.historyFragment||function(t,e,n){if(e.id){const n=t.getElementById(e.id);if(n instanceof HTMLElement)return n}if(null!==n){const e=t.querySelectorAll("[g-outlet]")[n];if(e)return e}const s=t.querySelector("[g-outlet]");return s instanceof HTMLElement?s:t.body}(x,e,u);Ri(b),qi(s);let _=y?.url||d;d.includes("#")&&y?.url&&(_+=d.substring(d.indexOf("#"))),Yi(x,_),t.historyFragment&&Yi(b,_);const w=t.trigger?.hasAttribute("g-change-state")||!1,E=t.trigger?.hasAttribute("g-current-state")||!1,S="GET"!==t.method.toUpperCase()&&!0===y?.redirected,k=!E&&(!0===t.changeState||w||S),C=async()=>{qi(s),s.committing=!0,Ii?.setProgress(10*Math.random()+80);const r=!k||t.replace||l?null:function(t){const e=t.cloneNode(!0);return e.querySelectorAll(".gyos-target-spinner").forEach(t=>t.remove()),e}(e);let i=null,a=[],o=!1;if(c&&(function(t=document){ei&&(ei&&document.body&&!ei.isConnected&&document.body.appendChild(ei),ni(t).forEach(t=>{if(t===ei||ei.contains(t))return;const e=ti(t,!0);e&&(Xr.set(e,t),ei.appendChild(t))}))}(e),function(t){As(t)}(e)),k)if(t.replace){const t=Ui(!1);history.replaceState({...history.state||{},gyos:!0,gyosEntryId:t},"",_)}else{const t=Ui(!1),e=Bi(),n=history.state||{};history.replaceState({...n,gyos:!0,gyosEntryId:t,gyosRoutes:{...n.gyosRoutes||{},[e]:f}},""),history.pushState({gyos:!0,gyosEntryId:e,gyosRoutes:{[t]:f}},"",_),r&&(ji(t,e,r),i={currentEntryId:t,nextEntryId:e}),Ci=e}try{e=await async function(t,e,n,s={}){const r=(n||"inner").toLowerCase(),i=document.importNode(e,!0),a=Array.from(i.childNodes);let o;if("replace"===r)Se(),t.replaceWith(i),o=i;else if("morph"===r)Se(),t.tagName!==i.tagName?(t.replaceWith(i),o=i):(function(t,e){const n=t=>t instanceof Element&&!!t.closest("[g-persist]"),s=t=>t?.nodeType===Node.COMMENT_NODE&&!!t.nodeValue?.includes("g-persist:"),r=t=>{if(t instanceof Element)return t.getAttribute("g-persist")||null;if(s(t)){const e=t.nodeValue.match(/g-persist:(\S+)/);return e?e[1]:null}return null},i=t=>`${t.tagName}|${t.id||""}|${t.dataset.gyosPersistId||""}|${t.dataset.gyosKey||""}`,a=t=>{if(!(t instanceof HTMLElement))return null;const{id:e,dataset:n}=t;return e||n.gyosPersistId||n.gyosKey?i(t):null},o=(t,e)=>{if(!t||!e)return;if(t===e)return;if(t.nodeType===Node.TEXT_NODE&&e.nodeType===Node.TEXT_NODE)return void(t.textContent!==e.textContent&&(t.textContent=e.textContent));if(!(t instanceof Element&&e instanceof Element))return void t.replaceWith(e.cloneNode(!0));if(n(t)||n(e))return;if(t.tagName!==e.tagName)return void t.replaceWith(e.cloneNode(!0));const c=(t=>{if(t instanceof HTMLInputElement){const e="checkbox"===t.type||"radio"===t.type,n="file"!==t.type&&t.value!==t.defaultValue,s=e&&t.checked!==t.defaultChecked;return n||s?{kind:"input",type:t.type,value:n?t.value:void 0,checked:s?t.checked:void 0}:null}if(t instanceof HTMLSelectElement){const e=Array.from(t.options);return e.some(t=>t.selected!==t.defaultSelected)?{kind:"select",values:e.filter(t=>t.selected).map(t=>t.value)}:null}return t instanceof HTMLTextAreaElement&&t.value!==t.defaultValue?{kind:"textarea",value:t.value}:null})(t);si(t,e);const l=t=>Array.from(t).filter(t=>!(t.nodeType===Node.TEXT_NODE&&""===(t.textContent||"").trim())),u=l(e.childNodes);let h=l(t.childNodes);const p=new Map;h.forEach(t=>{const e=r(t);e&&p.set(e,t)});let f=0;for(;f<u.length||f<h.length;){const e=u[f]||null;let c=h[f]||null;const d=a(e);if(d&&a(c)!==d){const n=h.findIndex((t,e)=>e>f&&a(t)===d);-1!==n?(t.insertBefore(h[n],c),h=l(t.childNodes),c=h[f]||null):e&&(t.insertBefore(e.cloneNode(!0),c),h=l(t.childNodes),c=h[f]||null)}const m=r(e),g=r(c);if(m){if(p.get(m)){f++;continue}t.insertBefore(e.cloneNode(!0),c||null),h=l(t.childNodes),f++;continue}if(g){f++;continue}if(!c&&e){t.appendChild(e.cloneNode(!0)),h=l(t.childNodes),f++;continue}if(c&&!e){if(!n(c)&&!s(c)){c.remove(),h=l(t.childNodes);continue}f++;continue}if(!c||!e){f++;continue}const y=c instanceof Element?i(c):"",v=e instanceof Element?i(e):"";y&&v&&y===v?(o(c,e),f++):y||v||c.nodeType!==e.nodeType?(n(c)||s(c)||(c.replaceWith(e.cloneNode(!0)),h=l(t.childNodes)),f++):(o(c,e),f++)}((t,e)=>{if(e){if("input"===e.kind&&t instanceof HTMLInputElement){if(t.type!==e.type)return;return void 0!==e.value&&(t.value=e.value),void(void 0!==e.checked&&(t.checked=e.checked))}if("select"===e.kind&&t instanceof HTMLSelectElement){const n=new Set(e.values);return void((0===n.size||Array.from(t.options).some(t=>n.has(t.value)))&&Array.from(t.options).forEach(t=>{t.selected=n.has(t.value)}))}"textarea"===e.kind&&t instanceof HTMLTextAreaElement&&(t.value=e.value)}})(t,c)};o(t,e)}(t,i),o=t);else if("append"===r)Se(),t.append(...a),o=t;else if("prepend"===r)Se(),t.prepend(...a),o=t;else{for(Se(),s.syncRootAttributes&&si(t,i),t.replaceChildren();i.firstChild;)t.appendChild(i.firstChild);o=t}return await(s.beforeScripts?.()),s.onCommitted?.(o,"append"===r||"prepend"===r?a:[o]),"append"===r||"prepend"===r?await Jr(a,s.signal):await async function(t,e){await Jr([t],e)}(o,s.signal),o}(e,b,n,{syncRootAttributes:l,signal:s.controller.signal,beforeScripts:async()=>{if(!l||p)return;const t=x.querySelector("title");t&&(document.title=t.textContent||document.title),await async function(t,e){const n="meta, link, style:not(#gyos-transitions), script",s=Array.from(document.head.querySelectorAll(n)),r=Array.from(t.head.querySelectorAll(n));await hi(s,r,document.head,e)}(x,s.controller.signal),qi(s)},onCommitted:(t,n)=>{e=t,a=n}}),qi(s),l&&(await async function(t,e,n,s){const r=Array.from(document.scripts).filter(t=>!e.contains(t)&&!document.head.contains(t)),i=Array.from(t.scripts).filter(e=>!n.contains(e)&&!t.head.contains(e));await hi(r,i,document.body,s)}(x,e,b,s.controller.signal),qi(s))}finally{(()=>{if(o)return;o=!0;const t=a.filter(t=>t instanceof HTMLElement&&t.isConnected);!function(t){if(!Xr.size)return;if(1===Xr.size){const e=Array.from(Xr.keys())[0];ni(t).forEach(t=>{ti(t,!1)||(t.dataset.gyosPersistId=e)})}ni(t).forEach(t=>{const e=ti(t,!1);if(!e)return;const n=Xr.get(e);n?(t.replaceWith(n),Xr.delete(e)):t.dataset.gyosPersistId=e});const e=document.createTreeWalker(t,NodeFilter.SHOW_COMMENT,null),n=[];for(;e.nextNode();){const t=e.currentNode,s=t.data.match(/g-persist[:=]\s*([A-Za-z0-9_\-:.]+)/);s&&n.push({node:t,key:s[1]})}n.forEach(({node:t,key:e})=>{const n=Xr.get(e);n&&(t.replaceWith(n),Xr.delete(e))})}(e),i&&ji(i.nextEntryId,i.currentEntryId,e),cr(t.length>0?t:void 0)})()}if(k)ri(_,t.trigger);else if(t.popstate)ri(_,t.trigger,t.savedScroll);else{const e=history.state;ri(_,t.trigger,e?.scroll)}};if(document.startViewTransition){const t=document.startViewTransition(()=>C());Gi(t?.ready),Gi(t?.finished),t?.updateCallbackDone&&await t.updateCallbackDone}else await C();qi(s),o&&t.trigger instanceof HTMLElement&&t.trigger.isConnected&&(As(t.trigger),t.trigger.remove()),r&&Br(s.spinner),s.spinner=null,zi(Ni,_),Se(),ki=Fi(k?_:window.location.href,!0),t.popstate&&t.historyEntryId&&(Ci=t.historyEntryId)}catch(e){if("AbortError"===e.name)return void Se();$i(s)&&Ki(t,t.url,!0)}finally{s.interval&&clearInterval(s.interval),s.spinner&&Br(s.spinner),Ai?.id===s.id&&(Ai=null,Ii?.complete()),s.resolveDone()}var a}function Qi(t){if(t.defaultPrevented)return;if(0!==t.button)return;if(t.metaKey||t.ctrlKey||t.shiftKey||t.altKey)return;const e=t.target;if(!e)return;const n=e.closest("[g-router-link]");if(n){if(n.closest("[g-no-boost]"))return;return t.preventDefault(),void function(t){Se();const e=t.getAttribute("g-router-link"),n=t.getAttribute("g-router-method")||"GET";if(!e||!["GET","POST","PUT","DELETE","PATCH"].includes(n.toUpperCase()))return;let s;try{s=new URL(e,window.location.href)}catch{return}if(s.origin===window.location.origin)try{const e=un(t),r=nn(decodeURIComponent(t.getAttribute("g-router-params")||""),e,!1);Ji({url:s.toString(),method:n,trigger:t,jsonData:r,changeState:!1})}catch(t){return}}(n)}const s=e.closest("a");if(!s)return;const r=s.getAttribute("href");if(!r)return;const i=new URL(r,window.location.href);var a;i.origin===window.location.origin&&(i.hash&&Fi(i.href)===Fi(window.location.href)||s.closest("[g-no-boost]")||s.hasAttribute("download")||s.getAttribute("target")&&"_self"!==s.getAttribute("target")||(a=s).closest("[g-no-boost]")||!a.hasAttribute("g-boost")&&!Vi()||(t.preventDefault(),Ji({url:i.toString(),method:"GET",trigger:s,changeState:!0})))}function Xi(t){const e=t.target;if(!e)return;const n=e.closest("a[g-preload]");if(!n)return;const s=n.getAttribute("href");if(!s)return;const r=new URL(s,window.location.href);r.origin===window.location.origin&&function(t){const e=Fi(t,!0);if(yi.has(e))return;Se();const n=new AbortController,s=fetch(e,{headers:{"X-Gyos-Boost":"1",Accept:"text/html,application/xhtml+xml"},signal:n.signal,mode:"same-origin"});yi.set(e,s),vi.set(e,n),s.catch(()=>{yi.delete(e),vi.delete(e)})}(r.toString())}function Zi(t){if(t.defaultPrevented)return;const e=t.target;if(!e||"form"!==e.tagName.toLowerCase())return;if(e.closest("[g-no-boost]"))return;if(!e.hasAttribute("g-boost")&&!Vi())return;if(function(t){return!(!hs.has(t)||ps.has(t)&&(ps.delete(t),1))}(e))return;t.preventDefault();const n=e.action||window.location.href,s=(e.method||"GET").toUpperCase(),r=new URL(n,window.location.href);if(r.origin!==window.location.origin)return void(window.location.href=r.toString());const i=new FormData(e);Ji({url:r.toString(),method:s,trigger:e,form:e,formData:i,changeState:"GET"===s})}function ta(t){const e=window.location.href,n=Ci,s=t.state||{},r=s.gyosEntryId||null,i=n?s.gyosRoutes?.[n]:void 0;if(Fi(e)===Fi(ki)&&(!r||r===n))return ki=Fi(e,!0),void(Ci=r||n);t.preventDefault(),Ai?.committing&&Hi(Ai),Ci=r,Ji({url:e,method:"GET",replace:!0,changeState:!1,popstate:!0,savedScroll:(r?xi.get(r):void 0)||s.scroll,targetSelector:i?.targetSelector,targetOutletIndex:i?.targetOutletIndex,swapMode:i?.swapMode,currentHead:i?.currentHead,historyFragment:n&&r?Wi(r,n):void 0,historyEntryId:r,scrollSourceEntryId:n})}const ea={scope:ar,mount:ur,mountAll:cr,mountTree:lr,cleanup:As,mountedScopes:cn,markRaw:Ws,shallow:Hs,directive:Pn,pipe:Ze,provide:Ke,inject:Je,getGlobalContainer:Qe,store:mr,hasStore:gr,removeStore:yr,getStoreNames:vr,on:br,emit:_r,off:wr,once:Er,getEventListeners:Sr,clearAllEvents:kr,validator:os,validate:us,getValidator:cs,getValidatorNames:ls,signal:Re,computed:De,effect:Fe,batch:Be,isSignal:Ue,isComputed:We,unref:$e,untrack:qe,registerTransition:On,getTransitionConfig:Dn,useFetch:Cr,useCounter:Ar,useToggle:Ir,useLocalStorage:Tr,useInterval:Nr,useTimeout:Pr,useDebounce:Lr,useThrottle:Mr,useMouse:Vr,useWindowSize:Or,useMediaQuery:Rr,useAsync:Dr,nextTick:he,debounce:fe,throttle:de,ready:pe,applyDirective:Ln,applyTransitionStyles:Fn,startRouter:Mi,onBeforeNavigate:Pi,onAfterNavigate:Li,portalCreate:rs,portalDestroy:is,setCspNonce:jr,version:"0.3.2"};ce=oe,t.applyDirective=Ln,t.applyTransitionStyles=Fn,t.batch=Be,t.cleanup=As,t.clearAllEvents=kr,t.computed=De,t.debounce=fe,t.default=ea,t.directive=Pn,t.effect=Fe,t.emit=_r,t.getEventListeners=Sr,t.getGlobalContainer=Qe,t.getStoreNames=vr,t.getTransitionConfig=Dn,t.getValidator=cs,t.getValidatorNames=ls,t.hasStore=gr,t.inject=Je,t.isComputed=We,t.isSignal=Ue,t.markRaw=Ws,t.mount=ur,t.mountAll=cr,t.mountTree=lr,t.mountedScopes=cn,t.nextTick=he,t.off=wr,t.on=br,t.onAfterNavigate=Li,t.onBeforeNavigate=Pi,t.once=Er,t.pipe=Ze,t.portalCreate=rs,t.portalDestroy=is,t.provide=Ke,t.ready=pe,t.registerTransition=On,t.removeStore=yr,t.scope=ar,t.setCspNonce=jr,t.shallow=Hs,t.signal=Re,t.startRouter=Mi,t.store=mr,t.throttle=de,t.unref=$e,t.untrack=qe,t.useAsync=Dr,t.useCounter=Ar,t.useDebounce=Lr,t.useFetch=Cr,t.useInterval=Nr,t.useLocalStorage=Tr,t.useMediaQuery=Rr,t.useMouse=Vr,t.useThrottle=Mr,t.useTimeout=Pr,t.useToggle=Ir,t.useWindowSize=Or,t.validate=us,t.validator=os,Object.defineProperty(t,"__esModule",{value:!0})},"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).Gyos={});
|