sveast 0.5.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/walk.js CHANGED
@@ -1 +1 @@
1
- import{o,h}from"./shared-3ca5cgq8.js";var y={Root:["module","instance","fragment","css"],Script:["attributes","content"],Fragment:["nodes"],Text:[],Comment:[],ExpressionTag:["expression"],HtmlTag:["expression"],ConstTag:["declaration"],DeclarationTag:["declaration"],DebugTag:["identifiers"],RenderTag:["expression"],AttachTag:["expression"],Attribute:["value"],SpreadAttribute:["expression"],AnimateDirective:["expression"],BindDirective:["expression"],ClassDirective:["expression"],LetDirective:["expression"],OnDirective:["expression"],StyleDirective:["value"],TransitionDirective:["expression"],UseDirective:["expression"],Component:["attributes","fragment"],TitleElement:["attributes","fragment"],SlotElement:["attributes","fragment"],RegularElement:["attributes","fragment"],SvelteBody:["attributes","fragment"],SvelteBoundary:["attributes","fragment"],SvelteComponent:["expression","attributes","fragment"],SvelteDocument:["attributes","fragment"],SvelteElement:["tag","attributes","fragment"],SvelteFragment:["attributes","fragment"],SvelteHead:["attributes","fragment"],SvelteOptions:["attributes","fragment"],SvelteSelf:["attributes","fragment"],SvelteWindow:["attributes","fragment"],IfBlock:["test","consequent","alternate"],EachBlock:["expression","context","key","body","fallback"],AwaitBlock:["expression","pending","value","then","error","catch"],KeyBlock:["expression","fragment"],SnippetBlock:["expression","parameters","body"],StyleSheet:["attributes","children"],Rule:["prelude","block"],Atrule:["block"],SelectorList:["children"],ComplexSelector:["children"],RelativeSelector:["combinator","selectors"],Combinator:[],TypeSelector:[],IdSelector:[],ClassSelector:[],AttributeSelector:[],PseudoElementSelector:["args"],PseudoClassSelector:["args"],Percentage:[],Nth:[],NestingSelector:[],Block:["children"],Declaration:[],Program:["body"],ExpressionStatement:["expression"],BlockStatement:["body"],StaticBlock:["body"],EmptyStatement:[],DebuggerStatement:[],WithStatement:["object","body"],ReturnStatement:["argument"],LabeledStatement:["label","body"],BreakStatement:["label"],ContinueStatement:["label"],IfStatement:["test","consequent","alternate"],SwitchStatement:["discriminant","cases"],SwitchCase:["test","consequent"],ThrowStatement:["argument"],TryStatement:["block","handler","finalizer"],CatchClause:["param","body"],WhileStatement:["test","body"],DoWhileStatement:["body","test"],ForStatement:["init","test","update","body"],ForInStatement:["left","right","body"],ForOfStatement:["left","right","body"],FunctionDeclaration:["id","typeParameters","params","returnType","body"],FunctionExpression:["id","typeParameters","params","returnType","body"],ArrowFunctionExpression:["typeParameters","params","returnType","body"],VariableDeclaration:["declarations"],VariableDeclarator:["id","init"],ClassDeclaration:["decorators","id","typeParameters","superClass","superTypeParameters","implements","body"],ClassExpression:["decorators","id","typeParameters","superClass","superTypeParameters","implements","body"],ClassBody:["body"],MethodDefinition:["decorators","key","typeParameters","value"],PropertyDefinition:["decorators","key","typeAnnotation","value"],Property:["decorators","key","value"],ThisExpression:[],Super:[],Literal:[],Identifier:["decorators","typeAnnotation"],PrivateIdentifier:[],ArrayExpression:["elements"],ObjectExpression:["properties"],UnaryExpression:["argument"],UpdateExpression:["argument"],BinaryExpression:["left","right"],LogicalExpression:["left","right"],AssignmentExpression:["left","right"],MemberExpression:["object","property"],ConditionalExpression:["test","consequent","alternate"],CallExpression:["callee","typeArguments","arguments"],NewExpression:["callee","typeArguments","arguments"],SequenceExpression:["expressions"],TemplateLiteral:["quasis","expressions"],TaggedTemplateExpression:["tag","typeArguments","quasi"],TemplateElement:[],SpreadElement:["argument"],RestElement:["decorators","argument","typeAnnotation"],YieldExpression:["argument"],AwaitExpression:["argument"],ImportExpression:["source","options","arguments"],ChainExpression:["expression"],MetaProperty:["meta","property"],ObjectPattern:["decorators","properties","typeAnnotation"],ArrayPattern:["decorators","elements","typeAnnotation"],AssignmentPattern:["decorators","left","right"],ImportDeclaration:["specifiers","source","attributes"],ImportSpecifier:["imported","local"],ImportDefaultSpecifier:["local"],ImportNamespaceSpecifier:["local"],ImportAttribute:["key","value"],ExportNamedDeclaration:["declaration","specifiers","source","attributes"],ExportSpecifier:["local","exported"],ExportDefaultDeclaration:["declaration"],ExportAllDeclaration:["exported","source","attributes"],Decorator:["expression"],TSTypeAnnotation:["typeAnnotation"],TSTypeParameterDeclaration:["params"],TSTypeParameterInstantiation:["params"],TSTypeParameter:["constraint","default"],TSAnyKeyword:[],TSBigIntKeyword:[],TSBooleanKeyword:[],TSNeverKeyword:[],TSNullKeyword:[],TSNumberKeyword:[],TSObjectKeyword:[],TSStringKeyword:[],TSSymbolKeyword:[],TSUndefinedKeyword:[],TSUnknownKeyword:[],TSVoidKeyword:[],TSThisType:[],TSArrayType:["elementType"],TSTupleType:["elementTypes"],TSNamedTupleMember:["label","elementType"],TSOptionalType:["typeAnnotation"],TSRestType:["typeAnnotation"],TSUnionType:["types"],TSIntersectionType:["types"],TSConditionalType:["checkType","extendsType","trueType","falseType"],TSInferType:["typeParameter"],TSParenthesizedType:["typeAnnotation"],TSTypeOperator:["typeAnnotation"],TSIndexedAccessType:["objectType","indexType"],TSMappedType:["typeParameter","nameType","typeAnnotation"],TSLiteralType:["literal"],TSTypeReference:["typeName","typeArguments"],TSQualifiedName:["left","right"],TSTypeQuery:["exprName","typeArguments"],TSImportType:["argument","qualifier","typeArguments"],TSTypeLiteral:["members"],TSPropertySignature:["key","typeAnnotation"],TSMethodSignature:["key","typeParameters","parameters","typeAnnotation"],TSCallSignatureDeclaration:["typeParameters","parameters","typeAnnotation"],TSConstructSignatureDeclaration:["typeParameters","parameters","typeAnnotation"],TSFunctionType:["typeParameters","parameters","typeAnnotation"],TSConstructorType:["typeParameters","parameters","typeAnnotation"],TSIndexSignature:["decorators","parameters","typeAnnotation"],TSTypePredicate:["parameterName","typeAnnotation"],TSInterfaceDeclaration:["id","typeParameters","extends","body"],TSInterfaceBody:["body"],TSExpressionWithTypeArguments:["expression","typeParameters"],TSTypeAliasDeclaration:["id","typeParameters","typeAnnotation"],TSEnumDeclaration:["id","members"],TSEnumMember:["id","initializer"],TSModuleDeclaration:["id","body"],TSModuleBlock:["body"],TSImportEqualsDeclaration:["id","moduleReference"],TSExternalModuleReference:["expression"],TSExportAssignment:["expression"],TSNamespaceExportDeclaration:["id"],TSDeclareFunction:["id","typeParameters","params","returnType"],TSDeclareMethod:["typeParameters","params","returnType"],TSParameterProperty:["parameter"],TSAsExpression:["expression","typeAnnotation"],TSSatisfiesExpression:["expression","typeAnnotation"],TSTypeAssertion:["typeAnnotation","expression"],TSNonNullExpression:["expression"],TSInstantiationExpression:["expression","typeArguments"]},f=Object.assign(Object.create(null),y),g=[],S=Symbol("sveast.walk.stop");function E(e,t){m(e,null,null,null,t)}function m(e,t,r,a,i){let s=b(e);if(s===void 0)throw Error(`unknown node type: ${e.type}`);let n=i.enter?.(e,t,r,a);if(n===S)return!0;if(n!==!1){if(n!==e&&o(n))return x(n,t,r,a,i);let T=h(e);for(let c=0;c<s.length;c++){let u=s[c],l=T[u];if(Array.isArray(l))for(let p=0;p<l.length;p++){let d=l[p];if(o(d)&&m(d,e,u,p,i))return!0}else if(o(l)&&m(l,e,u,null,i))return!0}}return i.leave?.(e,t,r,a)===S}function b(e){let t=e.type;if(t==="Identifier")return e.typeAnnotation===void 0&&e.decorators===void 0?g:y.Identifier;if(t==="Literal")return y.Literal;if(t==="Text")return y.Text;return f[t]}function x(e,t,r,a,i){if(t===null||r===null)throw Error("walk can't replace the node it was called with");let s=h(t),n=s[r];if(a===null)s[r]=e;else if(Array.isArray(n))n[a]=e;return m(e,t,r,a,i)}export{S as STOP,y as visitorKeys,E as walk};
1
+ import{l,m}from"./shared-drsxcq8p.js";function g(t){let e=[];return s(t,e),e}function s(t,e){switch(t.type){case"Identifier":e.push(t);return;case"ObjectPattern":for(let r of t.properties)s(r.type==="RestElement"?r.argument:r.value,e);return;case"ArrayPattern":for(let r of t.elements)if(r!==null)s(r,e);return;case"RestElement":s(t.argument,e);return;case"AssignmentPattern":s(t.left,e);return;case"TSParameterProperty":s(t.parameter,e);return;case"TSAsExpression":case"TSNonNullExpression":case"TSSatisfiesExpression":case"TSTypeAssertion":s(t.expression,e)}}function b(t,e){if(t.type!=="Identifier")return!1;if(e===null)return!0;switch(e.type){case"MemberExpression":return e.computed||t===e.object;case"MethodDefinition":return e.computed;case"Property":case"PropertyDefinition":return e.computed||t===e.value;case"ExportSpecifier":case"ImportSpecifier":return t===e.local;case"MetaProperty":case"ImportAttribute":case"ExportAllDeclaration":case"LabeledStatement":case"BreakStatement":case"ContinueStatement":return!1;case"TSAsExpression":case"TSSatisfiesExpression":case"TSTypeAssertion":case"TSNonNullExpression":case"TSInstantiationExpression":case"TSExportAssignment":return t===e.expression;case"TSEnumMember":return t===e.initializer;case"TSParameterProperty":case"TSEnumDeclaration":case"TSImportEqualsDeclaration":return!0;default:return!e.type.startsWith("TS")}}var y={Root:["module","instance","fragment","css"],Script:["attributes","content"],Fragment:["nodes"],Text:[],Comment:[],ExpressionTag:["expression"],HtmlTag:["expression"],ConstTag:["declaration"],DeclarationTag:["declaration"],DebugTag:["identifiers"],RenderTag:["expression"],AttachTag:["expression"],Attribute:["value"],SpreadAttribute:["expression"],AnimateDirective:["expression"],BindDirective:["expression"],ClassDirective:["expression"],LetDirective:["expression"],OnDirective:["expression"],StyleDirective:["value"],TransitionDirective:["expression"],UseDirective:["expression"],Component:["attributes","fragment"],TitleElement:["attributes","fragment"],SlotElement:["attributes","fragment"],RegularElement:["attributes","fragment"],SvelteBody:["attributes","fragment"],SvelteBoundary:["attributes","fragment"],SvelteComponent:["expression","attributes","fragment"],SvelteDocument:["attributes","fragment"],SvelteElement:["tag","attributes","fragment"],SvelteFragment:["attributes","fragment"],SvelteHead:["attributes","fragment"],SvelteOptions:["attributes","fragment"],SvelteSelf:["attributes","fragment"],SvelteWindow:["attributes","fragment"],IfBlock:["test","consequent","alternate"],EachBlock:["expression","context","key","body","fallback"],AwaitBlock:["expression","pending","value","then","error","catch"],KeyBlock:["expression","fragment"],SnippetBlock:["expression","parameters","body"],StyleSheet:["attributes","children"],Rule:["prelude","block"],Atrule:["block"],SelectorList:["children"],ComplexSelector:["children"],RelativeSelector:["combinator","selectors"],Combinator:[],TypeSelector:[],IdSelector:[],ClassSelector:[],AttributeSelector:[],PseudoElementSelector:["args"],PseudoClassSelector:["args"],Percentage:[],Nth:[],NestingSelector:[],Block:["children"],Declaration:[],Program:["body"],ExpressionStatement:["expression"],BlockStatement:["body"],StaticBlock:["body"],EmptyStatement:[],DebuggerStatement:[],WithStatement:["object","body"],ReturnStatement:["argument"],LabeledStatement:["label","body"],BreakStatement:["label"],ContinueStatement:["label"],IfStatement:["test","consequent","alternate"],SwitchStatement:["discriminant","cases"],SwitchCase:["test","consequent"],ThrowStatement:["argument"],TryStatement:["block","handler","finalizer"],CatchClause:["param","body"],WhileStatement:["test","body"],DoWhileStatement:["body","test"],ForStatement:["init","test","update","body"],ForInStatement:["left","right","body"],ForOfStatement:["left","right","body"],FunctionDeclaration:["id","typeParameters","params","returnType","body"],FunctionExpression:["id","typeParameters","params","returnType","body"],ArrowFunctionExpression:["typeParameters","params","returnType","body"],VariableDeclaration:["declarations"],VariableDeclarator:["id","init"],ClassDeclaration:["decorators","id","typeParameters","superClass","superTypeParameters","implements","body"],ClassExpression:["decorators","id","typeParameters","superClass","superTypeParameters","implements","body"],ClassBody:["body"],MethodDefinition:["decorators","key","typeParameters","value"],PropertyDefinition:["decorators","key","typeAnnotation","value"],Property:["decorators","key","value"],ThisExpression:[],Super:[],Literal:[],Identifier:["decorators","typeAnnotation"],PrivateIdentifier:[],ArrayExpression:["elements"],ObjectExpression:["properties"],UnaryExpression:["argument"],UpdateExpression:["argument"],BinaryExpression:["left","right"],LogicalExpression:["left","right"],AssignmentExpression:["left","right"],MemberExpression:["object","property"],ConditionalExpression:["test","consequent","alternate"],CallExpression:["callee","typeArguments","arguments"],NewExpression:["callee","typeArguments","arguments"],SequenceExpression:["expressions"],TemplateLiteral:["quasis","expressions"],TaggedTemplateExpression:["tag","typeArguments","quasi"],TemplateElement:[],SpreadElement:["argument"],RestElement:["decorators","argument","typeAnnotation"],YieldExpression:["argument"],AwaitExpression:["argument"],ImportExpression:["source","options","arguments"],ChainExpression:["expression"],MetaProperty:["meta","property"],ObjectPattern:["decorators","properties","typeAnnotation"],ArrayPattern:["decorators","elements","typeAnnotation"],AssignmentPattern:["decorators","left","right"],ImportDeclaration:["specifiers","source","attributes"],ImportSpecifier:["imported","local"],ImportDefaultSpecifier:["local"],ImportNamespaceSpecifier:["local"],ImportAttribute:["key","value"],ExportNamedDeclaration:["declaration","specifiers","source","attributes"],ExportSpecifier:["local","exported"],ExportDefaultDeclaration:["declaration"],ExportAllDeclaration:["exported","source","attributes"],Decorator:["expression"],TSTypeAnnotation:["typeAnnotation"],TSTypeParameterDeclaration:["params"],TSTypeParameterInstantiation:["params"],TSTypeParameter:["constraint","default"],TSAnyKeyword:[],TSBigIntKeyword:[],TSBooleanKeyword:[],TSNeverKeyword:[],TSNullKeyword:[],TSNumberKeyword:[],TSObjectKeyword:[],TSStringKeyword:[],TSSymbolKeyword:[],TSUndefinedKeyword:[],TSUnknownKeyword:[],TSVoidKeyword:[],TSThisType:[],TSArrayType:["elementType"],TSTupleType:["elementTypes"],TSNamedTupleMember:["label","elementType"],TSOptionalType:["typeAnnotation"],TSRestType:["typeAnnotation"],TSUnionType:["types"],TSIntersectionType:["types"],TSConditionalType:["checkType","extendsType","trueType","falseType"],TSInferType:["typeParameter"],TSParenthesizedType:["typeAnnotation"],TSTypeOperator:["typeAnnotation"],TSIndexedAccessType:["objectType","indexType"],TSMappedType:["typeParameter","nameType","typeAnnotation"],TSLiteralType:["literal"],TSTypeReference:["typeName","typeArguments"],TSQualifiedName:["left","right"],TSTypeQuery:["exprName","typeArguments"],TSImportType:["argument","qualifier","typeArguments"],TSTypeLiteral:["members"],TSPropertySignature:["key","typeAnnotation"],TSMethodSignature:["key","typeParameters","parameters","typeAnnotation"],TSCallSignatureDeclaration:["typeParameters","parameters","typeAnnotation"],TSConstructSignatureDeclaration:["typeParameters","parameters","typeAnnotation"],TSFunctionType:["typeParameters","parameters","typeAnnotation"],TSConstructorType:["typeParameters","parameters","typeAnnotation"],TSIndexSignature:["decorators","parameters","typeAnnotation"],TSTypePredicate:["parameterName","typeAnnotation"],TSInterfaceDeclaration:["id","typeParameters","extends","body"],TSInterfaceBody:["body"],TSExpressionWithTypeArguments:["expression","typeParameters"],TSTypeAliasDeclaration:["id","typeParameters","typeAnnotation"],TSEnumDeclaration:["id","members"],TSEnumMember:["id","initializer"],TSModuleDeclaration:["id","body"],TSModuleBlock:["body"],TSImportEqualsDeclaration:["id","moduleReference"],TSExternalModuleReference:["expression"],TSExportAssignment:["expression"],TSNamespaceExportDeclaration:["id"],TSDeclareFunction:["id","typeParameters","params","returnType"],TSDeclareMethod:["typeParameters","params","returnType"],TSParameterProperty:["parameter"],TSAsExpression:["expression","typeAnnotation"],TSSatisfiesExpression:["expression","typeAnnotation"],TSTypeAssertion:["typeAnnotation","expression"],TSNonNullExpression:["expression"],TSInstantiationExpression:["expression","typeArguments"]},A=Object.assign(Object.create(null),y),E=[],f=Symbol("sveast.walk.stop"),P=Symbol("sveast.walk.skip");function w(t,e){u(t,null,null,null,e)}function u(t,e,r,a,o){let i=v(t);if(i===void 0)throw Error(`unknown node type: ${t.type}`);let n=o.enter?.(t,e,r,a);if(n===f)return!0;if(n!==P){if(n!==t&&l(n))return h(n,e,r,a,o);let x=m(t);for(let S=0;S<i.length;S++){let T=i[S],p=x[T];if(Array.isArray(p))for(let c=0;c<p.length;c++){let d=p[c];if(l(d)&&u(d,t,T,c,o))return!0}else if(l(p)&&u(p,t,T,null,o))return!0}}return o.leave?.(t,e,r,a)===f}function v(t){let e=t.type;if(e==="Identifier")return t.typeAnnotation===void 0&&t.decorators===void 0?E:y.Identifier;if(e==="Literal")return y.Literal;if(e==="Text")return y.Text;return A[e]}function h(t,e,r,a,o){if(e===null||r===null)throw Error("walk can't replace the node it was called with");let i=m(e),n=i[r];if(a===null)i[r]=t;else if(Array.isArray(n))n[a]=t;return u(t,e,r,a,o)}export{P as SKIP,f as STOP,g as extractIdentifiers,b as isReference,y as visitorKeys,w as walk};
@@ -1,2 +0,0 @@
1
- function o(e){return typeof e==="object"&&e!==null&&typeof h(e).type==="string"}function h(e){return e}function u(e,t){let n=h(e);for(let i in n){let s=n[i];if(Array.isArray(s)){for(let r=0;r<s.length;r++)if(o(s[r]))s[r]=t(s[r])}else if(o(s))n[i]=t(s)}}function f(e,...t){if(!t.some((n)=>n===e.type))throw Error(`expected ${t.join(" or ")}, got ${e.type}`)}
2
- export{o,h,u,f};
@@ -1,3 +0,0 @@
1
- import{r,a}from"./shared-cx7c0gk3.js";import{x,n,p,e,R,O,D,B,F,V,M,j,W,z,E,U,H,N,G,K,Q,X,T,C,Y,_,J,Z,s,ee,te,ie,se,re,ne,oe,ae,le,P,pe,ce,he,ue,fe,de,A,me,ye,xe,L,ge,be,ve,Se,i,ke,we,Te,g,c,Ae}from"./shared-t6kshmn4.js";import{k}from"./shared-c2k7d7rg.js";import{u,f}from"./shared-3ca5cgq8.js";import{w}from"./shared-da2hc1fx.js";var fn={li:["li"],dt:["dt","dd"],dd:["dt","dd"],p:"address article aside blockquote div dl fieldset footer form h1 h2 h3 h4 h5 h6 header hgroup hr main menu nav ol p pre section table ul".split(" "),rt:["rt","rp"],rp:["rt","rp"],optgroup:["optgroup"],option:["option","optgroup"],thead:["tbody","tfoot"],tbody:["tbody","tfoot"],tfoot:["tbody"],tr:["tr","tbody"],td:["td","th","tr"],th:["td","th","tr"]};function mn(t,o){return Object.hasOwn(fn,t)&&fn[t].includes(o)}var Ye=new Set("arguments await break case catch class const continue debugger default delete do else enum eval export extends false finally for function if implements import in instanceof interface let new null package private protected public return static super switch this throw true try typeof var void while with yield".split(" ")),Ke=/<!--[\s\S]*?-->|<script\s+(?:[^>]*|(?:[^=>'"/]+=(?:"[^"]*"|'[^']*'|[^>\s]+)\s+)*)lang=(["'])?([^"' >]+)\1[^>]*>/y,it=/\r(?!\n)|[\u2028\u2029]/;function Re(t){if(t===32||t<=13&&t>=9)return!0;if(t<160)return!1;return t===160||t===5760||t>=8192&&t<=8202||t===8232||t===8233||t===8239||t===8287||t===12288||t===65279}function De(t,o){let l=o;while(l<t.length&&Re(t.charCodeAt(l)))l++;return l}function Ve(t,o){let l=t.codePointAt(o);if(l===void 0||!r(l,!0))return o;let m=o+(l<=65535?1:2),h=t.codePointAt(m);while(h!==void 0&&a(h,!0))m+=h<=65535?1:2,h=t.codePointAt(m);return m}function ot(t){let o=t.indexOf("<");while(o!==-1){let l=t.charCodeAt(o+1);if(l===33||l===115){Ke.lastIndex=o;let m=Ke.exec(t);if(m){if(l===115)return m[2]==="ts";o=t.indexOf("<",Ke.lastIndex);continue}}o=t.indexOf("<",o+1)}return!1}class Je{source;index=0;loc;lfOnly;isTypeScript;typescript;entityNames;css;script;comments;root;stack;fragments;metaTags=new Set;lastAutoClosedTag;nextAngle=-1;nextBrace=-1;constructor(t,o,l,m={}){if(this.source=t,this.loc=m.loc??!1,this.lfOnly=this.loc&&!it.test(t),this.isTypeScript=ot(t),this.typescript=l.typescript,this.isTypeScript&&!this.typescript)w();this.entityNames=l.entityNames,this.css=m.css??!0,this.script=m.script??!0,this.comments=m.comments??!0,this.root={type:"Root",start:0,end:o,css:null,js:[],options:null,fragment:{type:"Fragment",nodes:[]},comments:[]},this.stack=[this.root],this.fragments=[this.root.fragment]}match(t){if(t.length===1)return this.source.charCodeAt(this.index)===t.charCodeAt(0);return this.source.startsWith(t,this.index)}matchRegex(t){return t.lastIndex=this.index,t.exec(this.source)?.[0]??null}eat(t,o=!1){if(this.match(t))return this.index+=t.length,!0;if(o)s(this.index,t);return!1}read(t){let o=this.matchRegex(t);if(o)this.index+=o.length;return o}readUntil(t){if(this.index>=this.source.length)i(this.source.length);let o=this.source.indexOf(t,this.index),l=o===-1?this.source.length:o,m=this.source.slice(this.index,l);return this.index=l,m}allowWhitespace(){this.index=De(this.source,this.index)}requireWhitespace(){if(!Re(this.source.charCodeAt(this.index)))ee(this.index);this.allowWhitespace()}eatClosingBrace(){this.allowWhitespace(),this.eat("}",!0)}sourceLocation(t,o){return this.loc?{start:n(t),end:n(o)}:void 0}readIdentifierName(){let t=this.index,o=Ve(this.source,t),l=this.source.slice(t,o);if(this.index=o,Ye.has(l))ke(t,l);let m={type:"Identifier",name:l,start:t,end:o};if(this.loc)m.loc=this.sourceLocation(t,o);return m}current(){return this.stack[this.stack.length-1]}append(t){this.fragments[this.fragments.length-1].nodes.push(t)}open(t,o){this.append(t),this.stack.push(t),this.fragments.push(o)}setFragment(t){this.fragments[this.fragments.length-1]=t}close(){this.stack.pop(),this.fragments.pop()}}var lt=["===","!==","==","!=","&&","||","??"];function en(t,o,l,m){return{type:"Literal",start:o,end:l,value:m,raw:t.slice(o,l)}}function hn(t,o){let l=t.charCodeAt(o);if(l===34||l===39){for(let h=o+1;h<t.length;h++){let S=t.charCodeAt(h);if(S===l)return en(t,o,h+1,t.slice(o+1,h));if(S===92||S===10||S===13)return null}return null}let m=o;for(;m<t.length;m++){let h=t.charCodeAt(m);if(h<48||h>57)break}if(m===o||l===48&&m-o>1)return null;return en(t,o,m,Number(t.slice(o,m)))}function st(t,o){let l=Ve(t,o);if(l===o)return hn(t,o);let m=t.slice(o,l);if(m==="true"||m==="false"||m==="null")return en(t,o,l,m==="null"?null:m==="true");if(Ye.has(m))return null;let h={type:"Identifier",start:o,end:l,name:m};for(let S=l;;){let y=t.charCodeAt(S),v,b;if(y===46){if(b=Ve(t,S+1),b===S+1)return null;v={type:"Identifier",start:S+1,end:b,name:t.slice(S+1,b)}}else if(y===91){if(v=hn(t,S+1),!v||t.charCodeAt(v.end)!==93)return null;b=v.end+1}else return h;h={type:"MemberExpression",start:o,end:b,object:h,property:v,computed:y===91,optional:!1},S=b}}function nn(t,o){if(t.charCodeAt(o)!==33||t.charCodeAt(o+1)===61)return st(t,o);let l=nn(t,De(t,o+1));if(!l)return null;return{type:"UnaryExpression",start:o,end:l.end,operator:"!",prefix:!0,argument:l}}function xn(t,o){let l=De(t,o);if(l>=t.length)return!1;let m=t.charCodeAt(l);return m===125||m===41}function ct(t,o){let l=nn(t,o);if(!l||xn(t,l.end))return l;let m=De(t,l.end),h=lt.find((v)=>t.startsWith(v,m));if(!h)return null;let S=nn(t,De(t,m+h.length));if(!S||!xn(t,S.end))return null;let{end:y}=S;if(h==="&&"||h==="||"||h==="??")return{type:"LogicalExpression",start:l.start,end:y,left:l,operator:h,right:S};return{type:"BinaryExpression",start:l.start,end:y,left:l,operator:h,right:S}}function We(t){if(t.loc={start:p(t.start),end:p(t.end)},t.type==="MemberExpression")We(t.object),We(t.property);else if(t.type==="UnaryExpression")We(t.argument);else if(t.type==="BinaryExpression"||t.type==="LogicalExpression")We(t.left),We(t.right)}function Ce(t){let o=!t.loc||t.lfOnly?ct(t.source,t.index):null;if(o){if(t.index=o.end,t.loc)We(o);return o}let{node:l,end:m}=c(t,t.source,t.index);return t.index=m,l}var Sn=/<\/script\s*>/g,at=new Set(["server","client","worker","test","default"]);function gn(t,o,l){let{source:m,index:h}=t;if(h>=m.length)i(m.length);Sn.lastIndex=h;let S=Sn.exec(m);if(!S)T(m.length,"script");t.index=S.index+S[0].length;let y=t.script?g(t,m.slice(0,S.index),h):pt(h,S.index);if(y.start=h,y.loc)Object.assign(y.loc.start,p(o)),Object.assign(y.loc.end,p(t.index));else if(t.loc)y.loc={start:p(o),end:p(t.index)};let v="default";for(let b of l){if(at.has(b.name))ne(b,b.name);if(b.name==="module"){if(b.value!==!0)se(b,b.name);v="module"}if(b.name==="context"){let I=b.value;if(I===!0||!Array.isArray(I)||I.length!==1||I[0].type!=="Text"||I[0].data!=="module")re(b);v="module"}}return{type:"Script",start:o,end:t.index,context:v,content:y,attributes:l}}function pt(t,o){return{type:"Program",start:t,end:o,body:[],sourceType:"module"}}var ut=/(even|odd|\+?(\d+|\d*n(\s*[+-]\s*\d+)?)|-\d*n(\s*\+\s*\d+))((?=\s*[,)])|\s+of(\s+|(?=[.#[*:&])))/y,dt=/\d+(\.\d+)?%/y,ft=/\\[0-9a-fA-F]{1,6}(\r\n|\s)?/y,mt=/\s*>/y,Ne=-1,on=34,ht=35,xt=36,St=38,ln=39,gt=40,yt=41,Ge=42,At=43,Tt=45,Et=46,sn=47,tn=58,bt=59,En=60,yn=61,Ct=62,_t=91,He=92,vt=93,wt=94,bn=123,rn=124,kt=125,Cn=126,$e=[];function _n(t,o,l){let m=t.index;$e=[];let h=t.css?Rt(t):Pt(t),S=t.index;return t.eat("</style",!0),t.read(mt),{type:"StyleSheet",start:o,end:t.index,attributes:l,children:h,comments:$e,content:{start:m,end:S,styles:t.source.slice(m,S),comment:null}}}function Pt(t){let{source:o,index:l}=t;while(l<o.length){let m=o.charCodeAt(l);if(m===sn&&o.charCodeAt(l+1)===Ge){let h=o.indexOf("*/",l+2);l=h===-1?o.length:h+2}else if(m===on||m===ln){l++;while(l<o.length){let h=o.charCodeAt(l);if(h===m||h===10)break;l+=h===He?2:1}l++}else if(m===En&&o.startsWith("</style",l))break;else l++}return t.index=Math.min(l,o.length),[]}function Rt(t){let o=[];for(;;){if(Ie(t,!0),t.match("</style")||t.index>=t.source.length)break;o.push(t.match("@")?vn(t):wn(t))}return o}function vn(t){let o=t.index;t.eat("@",!0);let l=Le(t),m=cn(t,!0),h=null;if(t.match("{"))h=Rn(t);else t.eat(";",!0);return{type:"Atrule",start:o,end:t.index,name:l,prelude:m,block:h}}function wn(t){let o=t.index;return{type:"Rule",prelude:kn(t,!1),block:Rn(t),start:o,end:t.index}}function kn(t,o){let l=[];Ie(t,!0);let m=t.index;while(t.index<t.source.length){l.push(Ot(t,o));let h=t.index;if(Ie(t,!0),t.match(o?")":"{"))return{type:"SelectorList",start:m,end:h,children:l};t.eat(",",!0),Ie(t,!0)}return i(t.source.length)}function An(t,o){return{type:"RelativeSelector",combinator:t,selectors:[],start:o,end:-1}}function Ot(t,o){let{source:l,index:m}=t,h=[],S=An(null,t.index);while(t.index<l.length){let y=t.index,v=l.charCodeAt(y),b=S.selectors;if(v===St)t.index++,b.push({type:"NestingSelector",name:"&",start:y,end:t.index});else if(v===Ge)t.index++,b.push(Tn(t,y,"*"));else if(v===ht)t.index++,b.push({type:"IdSelector",name:Le(t),start:y,end:t.index});else if(v===Et)t.index++,b.push({type:"ClassSelector",name:Le(t),start:y,end:t.index});else if(v===tn){let _e=l.charCodeAt(y+1)===tn;t.index+=_e?2:1;let Pe=Le(t),Be=null;if(t.eat("("))Be=kn(t,!0),t.eat(")",!0);if(_e)b.push({type:"PseudoElementSelector",name:Pe,start:y,end:t.index,...Be&&{args:Be}});else b.push({type:"PseudoClassSelector",name:Pe,args:Be,start:y,end:t.index})}else if(v===_t)t.index++,b.push(Nt(t,y));else{let _e=o?t.read(ut):null,Pe=!_e&&je(v)?t.read(dt):null;if(_e)b.push({type:"Nth",value:_e,start:y,end:t.index});else if(Pe)b.push({type:"Percentage",value:Pe,start:y,end:t.index});else if(Pn(l,y)===0){let Be=Le(t);b.push(Tn(t,y,Be))}}let I=t.index;Ie(t,!1);let q=t.match(",")||t.match(o?")":"{");if(t.index=I,q)return S.end=I,h.push(S),{type:"ComplexSelector",start:m,end:I,children:h};let Ee=Lt(t);if(Ee){if(S.selectors.length>0)S.end=I,h.push(S);if(S=An(Ee,Ee.start),t.allowWhitespace(),t.match(",")||t.match(o?")":"{"))U(t.index)}}return i(l.length)}function Tn(t,o,l){let m=l,h;if(t.eat("|"))h=m,m=t.eat("*")?"*":Le(t);return{type:"TypeSelector",name:m,...h!==void 0&&{namespace:h},start:o,end:t.index}}function Nt(t,o){let l=t.source;t.allowWhitespace();let m=Le(t);t.allowWhitespace();let h=null,S=null,y=l.charCodeAt(t.index);if(y===yn)S="=";else if((y===Cn||y===wt||y===xt||y===Ge||y===rn)&&l.charCodeAt(t.index+1)===yn)S=l.slice(t.index,t.index+2);if(S)t.index+=S.length,t.allowWhitespace(),h=It(t);t.allowWhitespace();let v=t.index;while(Nn(l.charCodeAt(t.index)))t.index++;let b=t.index>v?l.slice(v,t.index):null;return t.allowWhitespace(),t.eat("]",!0),{type:"AttributeSelector",start:o,end:t.index,name:m,matcher:S,value:h,flags:b}}function Pn(t,o){let l=t.charCodeAt(o);if(l===At||l===Cn||l===Ct)return 1;if(l===rn&&t.charCodeAt(o+1)===rn)return 2;return 0}function Lt(t){let o=t.index;t.allowWhitespace();let l=t.index,m=Pn(t.source,l);if(m>0){t.index+=m;let h=t.index;return t.allowWhitespace(),{type:"Combinator",name:t.source.slice(l,h),start:l,end:h}}if(t.index!==o)return{type:"Combinator",name:" ",start:o,end:t.index};return null}function Rn(t){let o=t.index;t.eat("{",!0);let l=[];while(t.index<t.source.length){if(Ie(t,!0),t.match("}"))break;l.push(Bt(t))}return t.eat("}",!0),{type:"Block",start:o,end:t.index,children:l}}function Bt(t){if(t.match("@"))return vn(t);let o=t.index;cn(t,!1);let l=t.source.charCodeAt(t.index);return t.index=o,l===bn?wn(t):Dt(t)}function Dt(t){let{source:o,index:l}=t;if(l>=o.length)i(o.length);let m=l;while(m<o.length){let b=o.charCodeAt(m);if(b===tn||Re(b))break;m++}let h=o.slice(l,m);t.index=m,t.allowWhitespace(),t.eat(":");let S=t.index;t.allowWhitespace();let y=cn(t,!0);if(!y&&!h.startsWith("--"))z({start:l,end:S});let v=t.index;if(!t.match("}"))t.eat(";",!0);return{type:"Declaration",start:l,end:v,property:h,value:y}}function cn(t,o){let l=t.source,m=l.length,h="",S=t.index,y=null,v=!1,b=!1,I=Ne,q=t.index;while(q<m){let Ee=l.charCodeAt(q);if(v){v=!1,q++;continue}if(Ee===He){v=!0,q++;continue}if(Ee===I)I=Ne;else if(Ee===yt)b=!1;else if(I===Ne&&(Ee===on||Ee===ln))I=Ee;else if(Ee===gt){if(Wt(l,h,S,q))b=!0}else if((Ee===bt||Ee===bn||Ee===kt)&&!b&&I===Ne){if(t.index=q,!o)return"";if(h+=l.slice(S,q),y){let _e=h.length-h.trimStart().length;for(let Pe of y)Pe.position=Math.max(0,(Pe.position??0)-_e)}return h.trim()}else if(Ee===sn&&!b&&I===Ne&&l.charCodeAt(q+1)===Ge){h+=l.slice(S,q),t.index=q;let _e=On(t);if(o)_e.position=h.length,$e.push(_e),y??=[],y.push(_e);q=t.index,S=q;continue}q++}return t.index=m,i(m)}function Wt(t,o,l,m){if(m-l>=3)return t.charCodeAt(m-3)===117&&t.charCodeAt(m-2)===114&&t.charCodeAt(m-1)===108;return(o+t.slice(l,m)).endsWith("url")}function It(t){let o=t.source,l=Ne;if(t.eat('"'))l=on;else if(t.eat("'"))l=ln;let m=t.index,h=!1,S=m;while(S<o.length){let y=o.charCodeAt(S);if(h)h=!1;else if(y===He)h=!0;else if(l===Ne?y===vt||Re(y):y===l)return t.index=l===Ne?S:S+1,o.slice(m,S).trim();S++}return t.index=S,i(o.length)}function Le(t){let{source:o,index:l}=t,m=o.charCodeAt(l);if(je(m)||m===Tt&&je(o.charCodeAt(l+1)))E(l);let h="",S=l,y=l;while(y<o.length){let v=o.charCodeAt(y);if(v===He){h+=o.slice(S,y),t.index=y;let b=t.matchRegex(ft);if(b){let I=String.fromCodePoint(Number.parseInt(b.slice(1),16));h+=I==="\\"?"\\\\":I,y+=b.length}else h+=`\\${o[y+1]}`,y+=2;S=y}else if(v>=160||Ft(v))y++;else break}if(h+=o.slice(S,y),t.index=y,h==="")E(l);return h}function Ie(t,o){let l=t.source;t.allowWhitespace();for(;;){let m=l.charCodeAt(t.index);if(m===sn&&l.charCodeAt(t.index+1)===Ge){let h=On(t);if(o)$e.push(h)}else if(m===En&&t.eat("<!--"))t.readUntil("-->"),t.eat("-->",!0);else break;t.allowWhitespace()}}function On(t){let o=t.index;t.eat("/*",!0);let l=t.readUntil("*/");return t.eat("*/",!0),{type:"CSSComment",value:l,start:o,end:t.index}}function je(t){return t>=48&&t<=57}function Nn(t){return t>=65&&t<=90||t>=97&&t<=122}function Ft(t){return Nn(t)||je(t)||t===95||t===45}var an=/<\/textarea(\s[^>]*)?>/iy,Mt=/^![a-zA-Z]+$/,Gt=/^[a-zA-Z][a-zA-Z0-9]*:[a-zA-Z][a-zA-Z0-9-]*[a-zA-Z0-9]$/,Ut=/^[a-zA-Z][a-zA-Z0-9]*(-[a-zA-Z0-9.\-_\u00B7\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u037D\u037F-\u1FFF\u200C-\u200D\u203F-\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u{10000}-\u{EFFFF}]*)?$/u,pn="\\u200C\\u200D",qt=new RegExp(`^(?:\\p{Lu}[$${pn}\\p{ID_Continue}.]*|\\p{ID_Start}[$${pn}\\p{ID_Continue}]*(?:\\.[$${pn}\\p{ID_Continue}]+)+)$`,"u"),Vt=new Set("area base br col command embed hr img input keygen link meta param source track wbr".split(" ")),$t=new Map([["use","UseDirective"],["animate","AnimateDirective"],["bind","BindDirective"],["class","ClassDirective"],["style","StyleDirective"],["on","OnDirective"],["let","LetDirective"],["in","TransitionDirective"],["out","TransitionDirective"],["transition","TransitionDirective"]]),un=new Map([["svelte:head",["SvelteHead",!0]],["svelte:options",["SvelteOptions",!0]],["svelte:window",["SvelteWindow",!0]],["svelte:document",["SvelteDocument",!0]],["svelte:body",["SvelteBody",!0]],["svelte:element",["SvelteElement",!1]],["svelte:component",["SvelteComponent",!1]],["svelte:self",["SvelteSelf",!1]],["svelte:fragment",["SvelteFragment",!1]],["svelte:boundary",["SvelteBoundary",!1]]]),Ln=[...un.keys()],jt=`${Ln.slice(0,-1).join(", ")} or ${Ln.at(-1)}`,Gn=47,Xe=62,Un=61,Ht=34,Xt=39,Bn=123,Fe=(t)=>t===Ht||t===Xt;function zt(t,o,l){let m=o;for(;m<t.length;m++){let h=t.charCodeAt(m);if(Re(h)||h===Gn||h===Xe)break;if(l&&(Fe(h)||h===Un))break}return m}function ze(t,o){let l=t.index;if(l>=t.source.length)i(t.source.length);let m=zt(t.source,l,o);return t.index=m,{name:t.source.slice(l,m),start:l,end:m,loc:t.sourceLocation(l,m)}}var Ue=(t,o,l,m=l)=>({start:t,end:o,type:"Text",raw:l,data:m});function qn(t){return Vt.has(t)||t.charCodeAt(0)===33&&t.toLowerCase()==="!doctype"}function Qt(t){let o=t.charCodeAt(0);if(o>=97&&o<=122&&!t.includes("."))return!1;return qt.test(t)}function Zt(t){let o=!0;for(let l=0;l<t.length&&o;l++){let m=t.charCodeAt(l);o=m>=97&&m<=122||l>0&&m>=48&&m<=57}return o&&t.length>0||Mt.test(t)||Gt.test(t)||Ut.test(t)}function Dn(t,o){for(let l=t.length-1;l>=0;l--){let m=o(t[l]);if(m!==void 0)return m}return!1}function Kt(t,o,l){let m=un.get(o);if(m)return m[0];if(l)return"Component";if(o==="title"){if(Dn(t.stack,({type:S})=>{if(S==="SvelteHead")return!0;return S==="RegularElement"||S==="Component"?!1:void 0}))return"TitleElement"}if(o==="slot"){if(!Dn(t.stack,(S)=>S.type==="RegularElement"&&S.attributes.some((y)=>y.type==="Attribute"&&y.name==="shadowrootmode")?!0:void 0))return"SlotElement"}return"RegularElement"}function Vn(t){let o=t.index++;if(t.eat("!--")){let l=t.readUntil("-->");t.eat("-->",!0),t.append({type:"Comment",start:o,end:t.index,data:l})}else if(t.eat("/"))Yt(t,o);else er(t,o)}function Yt(t,o){let{name:l}=ze(t,!1);if(t.allowWhitespace(),t.eat(">",!0),qn(l))Te(o);let m=t.current();while(!("name"in m)||m.name!==l){if(m.type!=="RegularElement"){let h=t.lastAutoClosedTag;if(h?.tag===l)X(o,l,h.reason);Q(o,l)}m.end=o,t.close(),m=t.current()}if(m.end=t.index,t.close(),t.stack.length<(t.lastAutoClosedTag?.depth??0))t.lastAutoClosedTag=void 0}function Jt(t,o,l){return{type:t,start:o,end:-1,name:l}}function er(t,o){let l=ze(t,!1),{name:m}=l,h=un.get(m);if(!h&&m.startsWith("svelte:"))ue(l,jt);let S=Qt(m);if(!S&&!Zt(m))ve(l);if(h?.[1]){if(t.metaTags.has(m))pe(o,m);if(t.current().type!=="Root")he(o,m);t.metaTags.add(m)}let y=Jt(Kt(t,m,S),o,m);if(t.loc)y.name_loc=l.loc;y.attributes=[],y.fragment={type:"Fragment",nodes:[]},t.allowWhitespace();let v=t.current();if(v.type==="RegularElement"&&mn(v.name,m))v.end=o,t.close(),t.lastAutoClosedTag={tag:v.name,reason:m,depth:t.stack.length};if((m==="script"||m==="style")&&t.current().type==="Root"){let I=[];y.attributes=I,Mn(t,I,lr),tr(t,y,o,I);return}if(Mn(t,y.attributes,cr),y.type==="SvelteComponent"){let I=Wn(y);if(!I)le(o);if(!In(I.value))ae(I.start);y.expression=Fn(I.value)}else if(y.type==="SvelteElement"){let I=Wn(y);if(!I)P(o);if(I.value===!0)P(I);y.tag=In(I.value)?Fn(I.value):or(I.value[0])}if(!t.eat("/")&&!qn(m))if(t.eat(">",!0),m==="textarea")y.fragment.nodes=jn(t,(I,q)=>(an.lastIndex=q,an.test(I)),"inside <textarea>"),t.read(an);else if(m==="script"||m==="style")y.fragment.nodes.push(nr(t,`</${m}>`));else{t.open(y,y.fragment);return}else t.eat(">",!0);y.end=t.index,t.append(y)}function nr(t,o){let l=t.index,m=t.source.indexOf(o,l);t.index=m===-1?t.source.length:m;let h=Ue(l,t.index,t.source.slice(l,t.index));return t.eat(o,!0),h}function tr(t,o,l,m){t.eat(">",!0);let h=rr(t.root.fragment.nodes,l);if(o.name==="style"){let v=_n(t,l,m);if(v.content.comment=h,t.root.css)oe(l);t.root.css=v;return}let S=gn(t,l,m);if(h&&t.comments)S.content.leadingComments=[{type:"Line",value:h.data}];let y=S.context==="module"?"module":"instance";if(t.root[y])ie(l);t.root[y]=S}function rr(t,o){let l=t.length-1;if(l<0||t[l].end!==o)return null;for(let m=l;m>=0;m--){let h=t[m];if(h.type==="Comment")return h;if(h.type!=="Text"||h.data.trim())return null}return null}var ir=(t)=>t.type==="Attribute"&&t.name==="this";function Wn(t){let o=t.attributes.find(ir);if(o)t.attributes.splice(t.attributes.indexOf(o),1);return o}function In(t){if(t===!0)return!1;if(!Array.isArray(t))return!0;return t.length===1&&t[0].type==="ExpressionTag"}function Fn(t){return(Array.isArray(t)?t[0]:t).expression}function or(t){if(t.type!=="Text")return t.expression;return{type:"Literal",value:t.data,raw:`'${t.raw}'`,start:t.start,end:t.end}}function Mn(t,o,l){let m=new Set;for(;;){let h=l(t);if(!h)return;let{type:S}=h;if(S==="Attribute"||S==="BindDirective"||S==="StyleDirective"||S==="ClassDirective"){let y=`${S==="BindDirective"?"Attribute":S}${h.name}`;if(m.has(y))R(h);if(h.name!=="this")m.add(y)}o.push(h),t.allowWhitespace()}}function dn(t,o,l,m,h){return t.loc?{type:"Attribute",start:l,end:m,name:o.name,name_loc:o.loc,value:h}:{type:"Attribute",start:l,end:m,name:o.name,value:h}}function $n(t){if(Fe(t.source.charCodeAt(t.index)))s(t.index,"=")}function lr(t){let o=t.index,l=ze(t,!0);if(!l.name)return null;let m=!0;if(t.eat("=")){t.allowWhitespace();let{source:h}=t,S=t.index,y=-1;if(Fe(h.charCodeAt(S))){let I=h.indexOf(h[S],S+1);if(I!==-1)y=I+1}if(y===-1){y=S;while(y<h.length&&h.charCodeAt(y)!==Xe&&!Re(h.charCodeAt(y)))y++;if(y===S)C(S)}t.index=y;let v=Fe(h.charCodeAt(S))?1:0,b=h.slice(S+v,y-v);m=[Ue(y-b.length-v,y-v,b,k(b,!0,t.entityNames))]}return $n(t),dn(t,l,o,t.index,m)}function sr(t){let o=t.index,l=t.match("/*");if(!l&&!t.match("//"))return!1;t.index+=2;let m=t.readUntil(l?"*/":`
2
- `);if(l)t.eat("*/");let h={type:l?"Block":"Line",start:o,end:t.index,value:m},S=t.sourceLocation(o,t.index);if(S)h.loc=S;if(t.comments)t.root.comments.push(h);return!0}function cr(t){while(sr(t))t.allowWhitespace();let o=t.index;if(t.eat("{"))return ar(t,o);let l=ze(t,!0);if(!l.name)return null;let m=t.index;t.allowWhitespace();let h=!0;if(t.eat("=")){if(t.allowWhitespace(),t.match("/>"))h=[Ue(t.index,t.index+1,"/")],t.index++;else h=dr(t);m=t.index}else $n(t);let S=l.name.indexOf(":"),y=S>0?$t.get(l.name.slice(0,S)):void 0;return y?ur(t,y,l,S,o,m,h):dn(t,l,o,m,h)}function ar(t,o){if(t.allowWhitespace(),t.eat("@attach")){t.requireWhitespace();let h=Ce(t);return t.eatClosingBrace(),{type:"AttachTag",start:o,end:t.index,expression:h}}if(t.eat("...")){let h=Ce(t);return t.eatClosingBrace(),{type:"SpreadAttribute",start:o,end:t.index,expression:h}}let l=t.readIdentifierName();if(l.name==="")O(o);t.eatClosingBrace();let m={type:"ExpressionTag",start:l.start,end:l.end,expression:l};return dn(t,l,o,t.index,m)}function pr(t){if(t===!0)return;return Array.isArray(t)?t[0]:t}function ur(t,o,l,m,h,S,y){let[v,...b]=l.name.slice(m+1).split("|");if(v==="")K({start:h,end:h+m+1},l.name);let I={start:h,end:S,type:o,name:v};if(t.loc)I.name_loc=l.loc;if(o==="StyleDirective")return I.modifiers=b,I.value=y,I;let q=pr(y);if(q&&(Array.isArray(y)&&y.length>1||q.type==="Text"))G(q.start);if(I.expression=q?.expression??null,I.modifiers=b,o==="TransitionDirective"){let Ee=l.name.slice(0,m);I.intro=Ee!=="out",I.outro=Ee!=="in"}if((o==="BindDirective"||o==="ClassDirective")&&!I.expression)I.expression={start:h+m+1,end:S,type:"Identifier",name:v};return I}function dr(t){let o=t.source.charCodeAt(t.index),l=Fe(o);if(l){if(t.index++,t.source.charCodeAt(t.index)===o)return t.index++,[Ue(t.index-1,t.index-1,"")]}let m;try{m=jn(t,l?(h,S)=>h.charCodeAt(S)===o:fr,"in attribute value",l?o:void 0)}catch(h){let S=h instanceof e?h.position?.[0]:void 0;if(h instanceof e&&h.code==="js_parse_error"&&S!==void 0&&t.source.startsWith("/>",S-1))t.index=S,s(S,l?String.fromCharCode(o):"}");throw h}if(l)t.index++;else if(m.length===0)C(t.index);return l||m.length>1||m[0].type==="Text"?m:m[0]}function fr(t,o){let l=t.charCodeAt(o);return Re(l)||Fe(l)||l===Un||l===60||l===Xe||l===96||l===Gn&&t.charCodeAt(o+1)===Xe}function jn(t,o,l,m){let{source:h}=t,S=[],y=t.index,v=(b)=>{if(b<=y)return;let I=h.slice(y,b);S.push(Ue(y,b,I,k(I,!0,t.entityNames)))};while(t.index<h.length){let b=t.index;if(o(h,b))return v(b),S;if(h.charCodeAt(b)!==Bn){if(t.index++,m!==void 0)while(t.index<h.length&&h.charCodeAt(t.index)!==Bn&&h.charCodeAt(t.index)!==m)t.index++;continue}t.index++;let I=h.charCodeAt(t.index);if(I===35||I===64){t.index++;let Ee=t.index;while(t.index<h.length&&h.charCodeAt(t.index)>=97&&h.charCodeAt(t.index)<=122)t.index++;let _e=h.slice(Ee,t.index);(I===35?V:Se)(b,_e,l)}v(b),t.allowWhitespace();let q=Ce(t);t.eatClosingBrace(),S.push({type:"ExpressionTag",start:b,end:t.index,expression:q}),y=t.index}i(h.length)}var mr=new Map([["html","html"],["svg","svg"],["mathml","mathml"],["http://www.w3.org/2000/svg","svg"],["http://www.w3.org/1998/Math/MathML","mathml"]]),hr=new Map([["type",(t,o)=>{if(o!=="String"&&o!=="Number"&&o!=="Boolean"&&o!=="Array"&&o!=="Object")return!1;return t.type=o,!0}],["reflect",(t,o)=>{if(typeof o!=="boolean")return!1;return t.reflect=o,!0}],["attribute",(t,o)=>{if(typeof o!=="string")return!1;return t.attribute=o,!0}]]),Hn="[a-z0-9_.\\xB7\\xC0-\\xD6\\xD8-\\xF6\\xF8-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u203F-\\u2040\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\u{10000}-\\u{EFFFF}-]",xr=new RegExp(`^[a-z]${Hn}*-${Hn}*$`,"u"),Sr=new Set("annotation-xml color-profile font-face font-face-src font-face-uri font-face-format font-face-name missing-glyph".split(" ")),Qe=(t)=>(o,l)=>{let m=Ze(l);if(typeof m!=="boolean")A(l,"true or false");o[t]=m},gr=new Map([["runes",Qe("runes")],["immutable",Qe("immutable")],["preserveWhitespace",Qe("preserveWhitespace")],["accessors",Qe("accessors")],["namespace",(t,o)=>{let l=mr.get(Ze(o));if(!l)A(o,'"html", "mathml" or "svg"');t.namespace=l}],["css",(t,o)=>{if(Ze(o)!=="injected")A(o,'"injected"');t.css="injected"}],["tag",(t,o)=>fe(o)],["customElement",(t,o)=>{let l=Ar(o);if(l)t.customElement=l}]]);function zn(t){let o=[],l={start:t.start,end:t.end,attributes:o};for(let m of t.attributes){if(m.type!=="Attribute")de(m);o.push(m);let h=gr.get(m.name);if(!h)be(m,m.name);h(l,m)}return l}function Ze({value:t}){if(t===!0)return!0;let o=Array.isArray(t)?t:[t];if(o.length===0)return!0;if(o.length>1)return null;let[l]=o;if(l.type==="Text")return l.data;return l.expression.type==="Literal"?l.expression.value:null}function Xn(t,o){if(typeof o!=="string")L(t);if(!o)return;if(!xr.test(o))L(t);if(Sr.has(o))ge(t)}function yr(t,o){let l=new Map;for(let m of t.properties){if(m.type!=="Property"||m.computed||m.key.type!=="Identifier")o();if(!l.has(m.key.name))l.set(m.key.name,m.value)}return l}function Ar(t){let o=()=>me(t);if(t.value===!0)o();let l=Array.isArray(t.value)?t.value[0]:t.value;if(l.type==="Text"){let q=Ze(t);return Xn(t,q),{tag:q}}let{expression:m}=l;if(m.type!=="ObjectExpression"){if(m.type==="Literal"&&m.value===null)return;o()}let h=yr(m,o),S={},y=h.get("tag");if(y){let q=y.type==="Literal"?y.value:void 0;Xn(null,q),S.tag=q}let v=h.get("props");if(v){let q=()=>ye(t);if(v.type!=="ObjectExpression")q();S.props={};for(let Ee of v.properties){if(Ee.type!=="Property"||Ee.computed||Ee.key.type!=="Identifier"||Ee.value.type!=="ObjectExpression")q();let _e={};S.props[Ee.key.name]=_e;for(let Pe of Ee.value.properties){if(Pe.type!=="Property"||Pe.computed||Pe.key.type!=="Identifier"||Pe.value.type!=="Literal")q();if(!hr.get(Pe.key.name)?.(_e,Pe.value.value))q()}}}let b=h.get("shadow");if(b)if(b.type==="ObjectExpression")S.shadow=b;else if(b.type==="Literal"&&(b.value==="open"||b.value==="none"))S.shadow=b.value;else xe(t);let I=h.get("extend");if(I)S.extend=I;return S}var Tr={"{":"}","(":")","[":"]"};function qe(t,o,l=Tr){let m=Object.values(l),h=[],S=o;while(S<t.length){let y=t[S++];if(y==="'"||y==='"'||y==="`")S=Er(t,S,y);else if(Object.hasOwn(l,y))h.push(y);else if(m.includes(y)){let v=l[h.pop()??""];if(y!==v)s(S-1,v);if(h.length===0)return S}}i(t.length)}function Er(t,o,l){let m=o;while(m<t.length){let h=t[m++];if(h===l)return m;if(h==="\\")m++;else if(l==="`"&&h==="$"&&t[m]==="{")m=qe(t,m)}we(o)}var br=/\?\s*:/g;function Me(t){let o=t.index,l=t.readIdentifierName();if(l.name!==""){let v=Qn(t);return{...l,typeAnnotation:v}}let m=t.source[t.index];if(m!=="{"&&m!=="[")J(t.index);t.index=qe(t.source,o);let{node:h}=c(t,`${t.source.slice(0,t.index)} = 1`,o);f(h,"AssignmentExpression");let S=h.left;f(S,"ObjectPattern","ArrayPattern");let y=Qn(t);if(S.typeAnnotation=y,y)S.end=y.end;return S}function Qn(t){let o=t.index;if(t.allowWhitespace(),!t.eat(":")){t.index=o;return}let l="_ as ",m=t.index-l.length,h=t.source.slice(0,m)+l+t.source.slice(t.index).replace(br,":"),S=c(t,h,m).node;if(S.type==="AssignmentExpression"){let y=S.right.start;while(h[y]!=="=")y-=1;S=c(t,h.slice(0,y),m).node}if(S.type==="SequenceExpression")S=S.expressions[0];return f(S,"TSAsExpression"),t.index=S.end,{type:"TSTypeAnnotation",start:o,end:t.index,typeAnnotation:S.typeAnnotation}}var Cr=/\s*}/y,_r={IfBlock:"if",EachBlock:"each",KeyBlock:"key",AwaitBlock:"await",SnippetBlock:"snippet"},Oe=()=>({type:"Fragment",nodes:[]});function Kn(t,o){if(t.eat("if")){t.requireWhitespace();let l=Ce(t);t.eatClosingBrace();let m=Oe();t.open({type:"IfBlock",elseif:!1,start:o,end:-1,test:l,consequent:m,alternate:null},m)}else if(t.eat("each"))wr(t,o);else if(t.eat("await")){t.requireWhitespace();let l=Ce(t);t.allowWhitespace();let m={type:"AwaitBlock",start:o,end:-1,expression:l,value:null,error:null,pending:null,then:null,catch:null},h=Oe();if(t.eat("then"))m.value=Zn(t),m.then=h;else if(t.eat("catch"))m.error=Zn(t),m.catch=h;else m.pending=h;t.eat("}",!0),t.open(m,h)}else if(t.eat("key")){t.requireWhitespace();let l=Ce(t);t.eatClosingBrace();let m=Oe();t.open({type:"KeyBlock",start:o,end:-1,expression:l,fragment:m},m)}else if(t.eat("snippet"))kr(t,o);else Y(t.index)}function Zn(t){if(t.matchRegex(Cr))return t.allowWhitespace(),null;t.requireWhitespace();let o=Me(t);return t.allowWhitespace(),o}function vr(t){let o={assertion:null},l=t.end,m=(S)=>{if(S.type==="TSAsExpression"&&S.end===t.end)return o.assertion=S,l=S.expression.end,S.expression;return u(S,m),S},h=t;if(t.type==="TSAsExpression")o.assertion=t,h=t.expression,l=h.end;else u(t,m);return h.end=l,{expression:h,assertion:o.assertion}}function wr(t,o){t.requireWhitespace();let l=t.source,m;while(!m)try{m=Ce(t)}catch(b){let q=((b instanceof e?b.position:void 0)?.[0]??o)-2;while(q>o&&t.source.slice(q,q+2)!=="as")q-=1;if(q<=o)throw t.source=l,b;t.source=l.slice(0,q)}if(t.source=l,t.allowWhitespace(),!t.match("as")){if(m.type==="SequenceExpression")m=m.expressions[0];let b=vr(m);if(m=b.expression,b.assertion){let I=b.assertion.typeAnnotation.start-2;while(t.source.slice(I,I+2)!=="as")I-=1;t.index=I}}let h=null,S,y;if(t.eat("as"))t.requireWhitespace(),h=Me(t);else t.index=m.end;if(t.allowWhitespace(),t.eat(",")){if(t.allowWhitespace(),S=t.readIdentifierName().name,!S)_(t.index);t.allowWhitespace()}if(t.eat("("))t.allowWhitespace(),y=Ce(t),t.allowWhitespace(),t.eat(")",!0),t.allowWhitespace();t.eat("}",!0);let v=Oe();t.open({type:"EachBlock",start:o,end:-1,expression:m,body:v,context:h,index:S,key:y},v)}function kr(t,o){t.requireWhitespace();let l=t.readIdentifierName();if(l.name==="")_(t.index);t.allowWhitespace();let m=t.index,h;if(t.isTypeScript&&t.match("<")){let b=qe(t.source,m,{"<":">"});h=t.source.slice(m+1,b-1),t.index=b}t.allowWhitespace(),t.eat("(",!0);let S=1;while(t.index<t.source.length&&(!t.match(")")||S!==1)){if(t.match("("))S++;if(t.match(")"))S--;t.index+=1}t.eat(")",!0);let{node:y}=c(t,`${t.source.slice(0,t.index)} => {}`,m,!0);f(y,"ArrowFunctionExpression"),t.eatClosingBrace();let v=Oe();t.open({type:"SnippetBlock",start:o,end:-1,expression:l,typeParams:h,parameters:y.params,body:v},v)}function Yn(t,o){let l=t.index-1,m=t.current();if(m.type==="IfBlock"){if(!t.eat("else"))s(l,"{:else} or {:else if}");if(t.eat("if"))F(l);if(t.allowWhitespace(),m.alternate=Oe(),t.setFragment(m.alternate),t.eat("if")){t.requireWhitespace();let h=Ce(t);t.eatClosingBrace();let S=Oe();t.open({start:o,end:-1,type:"IfBlock",elseif:!0,test:h,consequent:S,alternate:null},S)}else t.eatClosingBrace()}else if(m.type==="EachBlock"){if(!t.eat("else"))s(l,"{:else}");t.eatClosingBrace(),m.fallback=Oe(),t.setFragment(m.fallback)}else if(m.type==="AwaitBlock"){let h;if(t.eat("then"))h="then";else if(t.eat("catch"))h="catch";else s(l,"{:then ...} or {:catch ...}");if(m[h])D(l,`{:${h}}`);if(!t.eat("}")){t.requireWhitespace();let y=Me(t);if(h==="then")m.value=y;else m.error=y;t.eatClosingBrace()}let S=Oe();m[h]=S,t.setFragment(S)}else B(l)}function Jn(t){let o=t.current(),l=_r[o.type];if(!l)j(t.index-1);t.eat(l,!0),t.eatClosingBrace();while(o.type==="IfBlock"&&o.elseif)o.end=t.index,t.close(),o=t.current();o.end=t.index,t.close()}var Pr=/\s*}/y;function Rr(t){return t.type==="CallExpression"||t.type==="ChainExpression"&&t.expression.type==="CallExpression"}function et(t,o){if(t.eat("html")){t.requireWhitespace();let l=Ce(t);t.eatClosingBrace(),t.append({type:"HtmlTag",start:o,end:t.index,expression:l})}else if(t.eat("debug")){let l=[];if(!t.read(Pr)){let m=Ce(t),h=m.type==="SequenceExpression"?m.expressions:[m];for(let S of h){if(S.type!=="Identifier")H(S.start);l.push(S)}t.eatClosingBrace()}t.append({type:"DebugTag",start:o,end:t.index,identifiers:l})}else if(t.eat("const")){t.requireWhitespace();let l=Me(t);t.allowWhitespace(),t.eat("=",!0),t.allowWhitespace();let m=t.index,h=Ce(t),S=t.index;if(h.type==="SequenceExpression"&&!t.source.slice(m,h.start).includes("("))W(h);t.eatClosingBrace();let y={type:"VariableDeclarator",id:l,init:h,start:l.start,end:S};t.append({type:"ConstTag",start:o,end:t.index,declaration:{type:"VariableDeclaration",kind:"const",declarations:[y],start:o+2,end:t.index-1}})}else if(t.eat("render")){t.requireWhitespace();let l=Ce(t);if(!Rr(l))te(l);t.eatClosingBrace(),t.append({type:"RenderTag",start:o,end:t.index,expression:l})}else Z(t.index)}var Or=/(?:var|interface|enum)\b/y,Nr=/(?:let|const|type)\b/y;function nt(t){let o=t.index;if(t.index+=1,t.allowWhitespace(),t.eat("#"))Kn(t,o);else if(t.eat(":"))Yn(t,o);else if(t.eat("@"))et(t,o);else if(t.match("/")&&!t.match("/*")&&!t.match("//"))t.index+=1,Jn(t);else if(!Lr(t,o)){let l=Ce(t);t.eatClosingBrace(),t.append({type:"ExpressionTag",start:o,end:t.index,expression:l})}}function Lr(t,o){let l=t.index,m=t.matchRegex(Or);if(m)N({start:l,end:l+m.length});if(!t.matchRegex(Nr))return!1;let h=t.root.comments.length,S=Ae(t,t.source,l);if(S.type==="ExpressionStatement")return t.root.comments.length=h,!1;if(S.type!=="VariableDeclaration"||S.kind!=="let"&&S.kind!=="const")N(S);return t.index=S.end,t.eatClosingBrace(),t.append({type:"DeclarationTag",start:o,end:t.index,declaration:S}),!0}function rt(t){let{source:o,index:l}=t;if(t.nextAngle<l)t.nextAngle=tt(o,"<",l);if(t.nextBrace<l)t.nextBrace=tt(o,"{",l);let m=Math.min(t.nextAngle,t.nextBrace);t.index=m;let h=o.slice(l,m);t.append({type:"Text",start:l,end:m,raw:h,data:k(h,!1,t.entityNames)})}function tt(t,o,l){let m=t.indexOf(o,l);return m===-1?t.length:m}function d(t,o,l){let m=t.charCodeAt(0)===65279?t.slice(1):t;x(m);let h=new Je(m.trimEnd(),m.length,l,o);while(h.index<h.source.length)if(h.match("<"))Vn(h);else if(h.match("{"))nt(h);else rt(h);if(h.stack.length>1){let b=h.current();if(b.end=b.start+1,b.type==="RegularElement")T(b,b.name);M(b)}let{nodes:S}=h.root.fragment,y=S.findIndex((b)=>b.type==="SvelteOptions"),v=S[y];if(v?.type==="SvelteOptions"){S.splice(y,1),h.root.options=zn(v);let{nodes:b}=v.fragment;if(b.length>0)ce({start:b[0].start,end:b[b.length-1].end},v.name)}return h.root}
3
- export{d};
@@ -1,10 +0,0 @@
1
- var ht={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"},pt="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",qt={5:pt,"5module":pt+" export import",6:pt+" const class extends export import super"},St=/^in(stanceof)?$/,zt=/\p{ID_Start}/u,Wt=/[\p{ID_Continue}\u200c\u200d]/u;function r(e,i){if(e<65)return e===36;if(e<91)return!0;if(e<97)return e===95;if(e<123)return!0;if(e>65535&&i===!1)return!1;return e>=170&&zt.test(String.fromCodePoint(e))}function a(e,i){if(e<48)return e===36;if(e<58)return!0;if(e<65)return!1;if(e<91)return!0;if(e<97)return e===95;if(e<123)return!0;if(e>65535&&i===!1)return!1;return e>=170&&Wt.test(String.fromCodePoint(e))}var g=function(i,s){if(s===void 0)s={};this.label=i,this.keyword=s.keyword,this.beforeExpr=!!s.beforeExpr,this.startsExpr=!!s.startsExpr,this.isLoop=!!s.isLoop,this.isAssign=!!s.isAssign,this.prefix=!!s.prefix,this.postfix=!!s.postfix,this.binop=s.binop||null,this.updateContext=null};function P(e,i){return new g(e,{beforeExpr:!0,binop:i})}var I={beforeExpr:!0},E={startsExpr:!0},ft={};function k(e,i){if(i===void 0)i={};return i.keyword=e,ft[e]=new g(e,i)}var o={num:new g("num",E),regexp:new g("regexp",E),string:new g("string",E),name:new g("name",E),privateId:new g("privateId",E),eof:new g("eof"),bracketL:new g("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new g("]"),braceL:new g("{",{beforeExpr:!0,startsExpr:!0}),braceR:new g("}"),parenL:new g("(",{beforeExpr:!0,startsExpr:!0}),parenR:new g(")"),comma:new g(",",I),semi:new g(";",I),colon:new g(":",I),dot:new g("."),question:new g("?",I),questionDot:new g("?."),arrow:new g("=>",I),template:new g("template"),invalidTemplate:new g("invalidTemplate"),ellipsis:new g("...",I),backQuote:new g("`",E),dollarBraceL:new g("${",{beforeExpr:!0,startsExpr:!0}),eq:new g("=",{beforeExpr:!0,isAssign:!0}),assign:new g("_=",{beforeExpr:!0,isAssign:!0}),incDec:new g("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new g("!/~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:P("||",1),logicalAND:P("&&",2),bitwiseOR:P("|",3),bitwiseXOR:P("^",4),bitwiseAND:P("&",5),equality:P("==/!=/===/!==",6),relational:P("</>/<=/>=",7),bitShift:P("<</>>/>>>",8),plusMin:new g("+/-",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:P("%",10),star:P("*",10),slash:P("/",10),starstar:new g("**",{beforeExpr:!0}),coalesce:P("??",1),_break:k("break"),_case:k("case",I),_catch:k("catch"),_continue:k("continue"),_debugger:k("debugger"),_default:k("default",I),_do:k("do",{isLoop:!0,beforeExpr:!0}),_else:k("else",I),_finally:k("finally"),_for:k("for",{isLoop:!0}),_function:k("function",E),_if:k("if"),_return:k("return",I),_switch:k("switch"),_throw:k("throw",I),_try:k("try"),_var:k("var"),_const:k("const"),_while:k("while",{isLoop:!0}),_with:k("with"),_new:k("new",{beforeExpr:!0,startsExpr:!0}),_this:k("this",E),_super:k("super",E),_class:k("class",E),_extends:k("extends",I),_export:k("export"),_import:k("import",E),_null:k("null",E),_true:k("true",E),_false:k("false",E),_in:k("in",{beforeExpr:!0,binop:7}),_instanceof:k("instanceof",{beforeExpr:!0,binop:7}),_typeof:k("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:k("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:k("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})},T=/\r\n?|\n|\u2028|\u2029/,jt=new RegExp(T.source,"g");function z(e){return e===10||e===13||e===8232||e===8233}function Ct(e,i,s){if(s===void 0)s=e.length;for(var n=i;n<s;n++){var h=e.charCodeAt(n);if(z(h))return n<s-1&&h===13&&e.charCodeAt(n+1)===10?n+2:n+1}return-1}var At=/[\u1680\u2000-\u200a\u202f\u205f\u3000\ufeff]/,C=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g,Nt=Object.prototype,{hasOwnProperty:Gt,toString:Ht}=Nt,Y=Object.hasOwn||function(e,i){return Gt.call(e,i)},kt=Array.isArray||function(e){return Ht.call(e)==="[object Array]"},gt=Object.create(null);function J(e){return gt[e]||(gt[e]=new RegExp("^(?:"+e.replace(/ /g,"|")+")$"))}function it(e){if(e<=65535)return String.fromCharCode(e);return e-=65536,String.fromCharCode((e>>10)+55296,(e&1023)+56320)}var Yt=/(?:[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])/,H=function(i,s){this.line=i,this.column=s};H.prototype.offset=function(i){return new H(this.line,this.column+i)};var st=function(i,s,n){if(this.start=s,this.end=n,i.sourceFile!==null)this.source=i.sourceFile};function Et(e,i){for(var s=1,n=0;;){var h=Ct(e,n,i);if(h<0)return new H(s,i-n);++s,n=h}}var lt={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},wt=!1;function Qt(e){var i={};for(var s in lt)i[s]=e&&Y(e,s)?e[s]:lt[s];if(i.ecmaVersion==="latest")i.ecmaVersion=1e8;else if(i.ecmaVersion==null){if(!wt&&typeof console==="object"&&console.warn)wt=!0,console.warn(`Since Acorn 8.0.0, options.ecmaVersion is required.
2
- Defaulting to 2020, but this will stop working in the future.`);i.ecmaVersion=11}else if(i.ecmaVersion>=2015)i.ecmaVersion-=2009;if(i.allowReserved==null)i.allowReserved=i.ecmaVersion<5;if(!e||e.allowHashBang==null)i.allowHashBang=i.ecmaVersion>=14;if(kt(i.onToken)){var n=i.onToken;i.onToken=function(h){return n.push(h)}}if(kt(i.onComment))i.onComment=Kt(i,i.onComment);if(i.sourceType==="commonjs"&&i.allowAwaitOutsideFunction)throw Error("Cannot use allowAwaitOutsideFunction with sourceType: commonjs");return i}function Kt(e,i){return function(s,n,h,p,l,c){var u={type:s?"Block":"Line",value:n,start:h,end:p};if(e.locations)u.loc=new st(this,l,c);if(e.ranges)u.range=[h,p];i.push(u)}}var O=1,B=2,dt=4,Tt=8,mt=16,Pt=32,rt=64,It=128,M=256,Q=512,_t=1024,at=O|B|M;function vt(e,i){return B|(e?dt:0)|(i?Tt:0)}var Z=0,xt=1,V=2,Lt=3,Rt=4,Vt=5,t=function(i,s,n){this.options=i=Qt(i),this.sourceFile=i.sourceFile,this.keywords=J(qt[i.ecmaVersion>=6?6:i.sourceType==="module"?"5module":5]);var h="";if(i.allowReserved!==!0){if(h=ht[i.ecmaVersion>=6?6:i.ecmaVersion===5?5:3],i.sourceType==="module")h+=" await"}this.reservedWords=J(h);var p=(h?h+" ":"")+ht.strict;if(this.reservedWordsStrict=J(p),this.reservedWordsStrictBind=J(p+" "+ht.strictBind),this.input=String(s),this.containsEsc=!1,this.pos=n||0,this.curLine=1,i.startLocation)this.lineStart=this.pos-i.startLocation.column,this.curLine=i.startLocation.line;else if(n){if(this.lineStart=this.input.lastIndexOf(`
3
- `,n-1)+1,this.options.locations)this.curLine=this.input.slice(0,this.lineStart).split(T).length}else this.lineStart=0;if(this.type=o.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=i.sourceType==="module",this.strict=this.inModule||i.strict===!0||this.strictDirective(this.pos),this.potentialArrowAt=-1,this.potentialArrowInForAwait=!1,this.yieldPos=this.awaitPos=this.awaitIdentPos=0,this.labels=[],this.undefinedExports=Object.create(null),this.pos===0&&i.allowHashBang&&this.input.slice(0,2)==="#!")this.skipLineComment(2);this.scopeStack=[],this.enterScope(this.options.sourceType==="commonjs"?B:O),this.regexpState=null,this.privateNameStack=[]},_={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}};t.prototype.parse=function(){var i=this,s=this.options.program||this.startNode();return this.nextToken(),this.catchStackOverflow(function(){return i.parseTopLevel(s)})};_.inFunction.get=function(){return(this.currentVarScope().flags&B)>0};_.inGenerator.get=function(){return(this.currentVarScope().flags&Tt)>0};_.inAsync.get=function(){return(this.currentVarScope().flags&dt)>0};_.canAwait.get=function(){for(var e=this.scopeStack.length-1;e>=0;e--){var i=this.scopeStack[e],s=i.flags;if(s&(M|Q))return!1;if(s&B)return(s&dt)>0}return this.inModule&&this.options.ecmaVersion>=13||this.options.allowAwaitOutsideFunction};_.allowReturn.get=function(){if(this.inFunction)return!0;if(this.options.allowReturnOutsideFunction&&this.currentVarScope().flags&O)return!0;return!1};_.allowSuper.get=function(){var e=this.currentThisScope(),i=e.flags;return(i&rt)>0||this.options.allowSuperOutsideMethod};_.allowDirectSuper.get=function(){return(this.currentThisScope().flags&It)>0};_.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())};_.allowNewDotTarget.get=function(){for(var e=this.scopeStack.length-1;e>=0;e--){var i=this.scopeStack[e],s=i.flags;if(s&(M|Q)||s&B&&!(s&mt))return!0}return!1};_.allowUsing.get=function(){var e=this.currentScope(),i=e.flags;if(i&_t)return!1;if(!this.inModule&&i&O)return!1;return!0};_.inClassStaticBlock.get=function(){return(this.currentVarScope().flags&M)>0};t.extend=function(){var i=[],s=arguments.length;while(s--)i[s]=arguments[s];var n=this;for(var h=0;h<i.length;h++)n=i[h](n);return n};t.parse=function(i,s){return new this(s,i).parse()};t.parseExpressionAt=function(i,s,n){var h=new this(n,i,s);return h.nextToken(),h.parseExpression()};t.tokenizer=function(i,s){return new this(s,i)};Object.defineProperties(t.prototype,_);var N=t.prototype,Xt=/^(?:'((?:\\[^]|[^'\\])*?)'|"((?:\\[^]|[^"\\])*?)")/;N.strictDirective=function(e){if(this.options.ecmaVersion<5)return!1;for(;;){C.lastIndex=e,e+=C.exec(this.input)[0].length;var i=Xt.exec(this.input.slice(e));if(!i)return!1;if((i[1]||i[2])==="use strict"){C.lastIndex=e+i[0].length;var s=C.exec(this.input),n=s.index+s[0].length,h=this.input.charAt(n);return h===";"||h==="}"||T.test(s[0])&&!(/[(`.[+\-/*%<>=,?^&]/.test(h)||h==="!"&&this.input.charAt(n+1)==="=")}if(e+=i[0].length,C.lastIndex=e,e+=C.exec(this.input)[0].length,this.input[e]===";")e++}};N.eat=function(e){if(this.type===e)return this.next(),!0;else return!1};N.isContextual=function(e){return this.type===o.name&&this.value===e&&!this.containsEsc};N.eatContextual=function(e){if(!this.isContextual(e))return!1;return this.next(),!0};N.catchStackOverflow=function(e){try{return e()}catch(i){if(i instanceof Error&&(/\bstack\b.*\b(exceeded|overflow)\b/i.test(i.message)||/\btoo much recursion\b/i.test(i.message)))this.raise(this.start,"Not enough stack space to parse input");else throw i}};N.expectContextual=function(e){if(!this.eatContextual(e))this.unexpected()};N.canInsertSemicolon=function(){return this.type===o.eof||this.type===o.braceR||T.test(this.input.slice(this.lastTokEnd,this.start))};N.insertSemicolon=function(){if(this.canInsertSemicolon()){if(this.options.onInsertedSemicolon)this.options.onInsertedSemicolon(this.lastTokEnd,this.lastTokEndLoc);return!0}};N.semicolon=function(){if(!this.eat(o.semi)&&!this.insertSemicolon())this.unexpected()};N.afterTrailingComma=function(e,i){if(this.type===e){if(this.options.onTrailingComma)this.options.onTrailingComma(this.lastTokStart,this.lastTokStartLoc);if(!i)this.next();return!0}};N.expect=function(e){this.eat(e)||this.unexpected()};N.unexpected=function(e){this.raise(e!=null?e:this.start,"Unexpected token")};var nt=function(){this.shorthandAssign=this.trailingComma=this.parenthesizedAssign=this.parenthesizedBind=this.doubleProto=-1};N.checkPatternErrors=function(e,i){if(!e)return;if(e.trailingComma>-1)this.raiseRecoverable(e.trailingComma,"Comma is not permitted after the rest element");var s=i?e.parenthesizedAssign:e.parenthesizedBind;if(s>-1)this.raiseRecoverable(s,i?"Assigning to rvalue":"Parenthesized pattern")};N.checkExpressionErrors=function(e,i){if(!e)return!1;var{shorthandAssign:s,doubleProto:n}=e;if(!i)return s>=0||n>=0;if(s>=0)this.raise(s,"Shorthand property assignments are valid only in destructuring patterns");if(n>=0)this.raiseRecoverable(n,"Redefinition of __proto__ property")};N.checkYieldAwaitInDefaultParams=function(){if(this.yieldPos&&(!this.awaitPos||this.yieldPos<this.awaitPos))this.raise(this.yieldPos,"Yield expression cannot be a default value");if(this.awaitPos)this.raise(this.awaitPos,"Await expression cannot be a default value")};N.isSimpleAssignTarget=function(e){if(e.type==="ParenthesizedExpression")return this.isSimpleAssignTarget(e.expression);return e.type==="Identifier"||e.type==="MemberExpression"};var f=t.prototype;f.parseTopLevel=function(e){var i=Object.create(null);if(!e.body)e.body=[];while(this.type!==o.eof){var s=this.parseStatement(null,!0,i);e.body.push(s)}if(this.inModule)for(var n=0,h=Object.keys(this.undefinedExports);n<h.length;n+=1){var p=h[n];this.raiseRecoverable(this.undefinedExports[p].start,"Export '"+p+"' is not defined")}return this.adaptDirectivePrologue(e.body),this.next(),e.sourceType=this.options.sourceType==="commonjs"?"script":this.options.sourceType,this.finishNode(e,"Program")};var yt={kind:"loop"},Jt={kind:"switch"};f.isLet=function(e){if(this.options.ecmaVersion<6||!this.isContextual("let"))return!1;C.lastIndex=this.pos;var i=C.exec(this.input),s=this.pos+i[0].length,n=this.fullCharCodeAt(s);if(n===91||n===92)return!0;if(e)return!1;if(n===123)return!0;if(r(n)){var h=s;do s+=n<=65535?1:2;while(a(n=this.fullCharCodeAt(s)));if(n===92)return!0;var p=this.input.slice(h,s);if(!St.test(p))return!0}return!1};f.isAsyncFunction=function(){if(this.options.ecmaVersion<8||!this.isContextual("async"))return!1;C.lastIndex=this.pos;var e=C.exec(this.input),i=this.pos+e[0].length,s;return!T.test(this.input.slice(this.pos,i))&&this.input.slice(i,i+8)==="function"&&(i+8===this.input.length||!(a(s=this.fullCharCodeAt(i+8))||s===92))};f.isUsingKeyword=function(e,i){if(this.options.ecmaVersion<17||!this.isContextual(e?"await":"using"))return!1;C.lastIndex=this.pos;var s=C.exec(this.input),n=this.pos+s[0].length;if(T.test(this.input.slice(this.pos,n)))return!1;if(e){var h=n+5,p;if(this.input.slice(n,h)!=="using"||h===this.input.length||a(p=this.fullCharCodeAt(h))||p===92)return!1;C.lastIndex=h;var l=C.exec(this.input);if(n=h+l[0].length,l&&T.test(this.input.slice(h,n)))return!1}var c=this.fullCharCodeAt(n);if(!r(c)&&c!==92)return!1;var u=n;do n+=c<=65535?1:2;while(a(c=this.fullCharCodeAt(n)));if(c===92)return!0;var d=this.input.slice(u,n);if(St.test(d))return!1;if(i&&!e&&d==="of"){C.lastIndex=n;var x=C.exec(this.input);if(n=n+x[0].length,this.input.charCodeAt(n)!==61||(c=this.input.charCodeAt(n+1))===61||c===62)return!1}return!0};f.isAwaitUsing=function(e){return this.isUsingKeyword(!0,e)};f.isUsing=function(e){return this.isUsingKeyword(!1,e)};f.parseStatement=function(e,i,s){var n=this.type,h=this.startNode(),p;if(this.isLet(e))n=o._var,p="let";switch(n){case o._break:case o._continue:return this.parseBreakContinueStatement(h,n.keyword);case o._debugger:return this.parseDebuggerStatement(h);case o._do:return this.parseDoStatement(h);case o._for:return this.parseForStatement(h);case o._function:if(e&&(this.strict||e!=="if"&&e!=="label")&&this.options.ecmaVersion>=6)this.unexpected();return this.parseFunctionStatement(h,!1,!e);case o._class:if(e)this.unexpected();return this.parseClass(h,!0);case o._if:return this.parseIfStatement(h);case o._return:return this.parseReturnStatement(h);case o._switch:return this.parseSwitchStatement(h);case o._throw:return this.parseThrowStatement(h);case o._try:return this.parseTryStatement(h);case o._const:case o._var:if(p=p||this.value,e&&p!=="var")this.unexpected();return this.parseVarStatement(h,p);case o._while:return this.parseWhileStatement(h);case o._with:return this.parseWithStatement(h);case o.braceL:return this.parseBlock(!0,h);case o.semi:return this.parseEmptyStatement(h);case o._export:case o._import:if(this.options.ecmaVersion>10&&n===o._import){C.lastIndex=this.pos;var l=C.exec(this.input),c=this.pos+l[0].length,u=this.input.charCodeAt(c);if(u===40||u===46)return this.parseExpressionStatement(h,this.parseExpression())}if(!this.options.allowImportExportEverywhere){if(!i)this.raise(this.start,"'import' and 'export' may only appear at the top level");if(!this.inModule)this.raise(this.start,"'import' and 'export' may appear only with 'sourceType: module'")}return n===o._import?this.parseImport(h):this.parseExport(h,s);default:if(this.isAsyncFunction()){if(e)this.unexpected();return this.next(),this.parseFunctionStatement(h,!0,!e)}var d=this.isAwaitUsing(!1)?"await using":this.isUsing(!1)?"using":null;if(d){if(!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");if(e)this.raise(this.start,"Using declaration is not allowed in single-statement positions");if(d==="await using"){if(!this.canAwait)this.raise(this.start,"Await using cannot appear outside of async function");this.next()}return this.next(),this.parseVar(h,!1,d),this.semicolon(),this.finishNode(h,"VariableDeclaration")}var x=this.value,w=this.parseExpression();if(n===o.name&&w.type==="Identifier"&&this.eat(o.colon))return this.parseLabeledStatement(h,x,w,e);else return this.parseExpressionStatement(h,w)}};f.parseBreakContinueStatement=function(e,i){var s=i==="break";if(this.next(),this.eat(o.semi)||this.insertSemicolon())e.label=null;else if(this.type!==o.name)this.unexpected();else e.label=this.parseIdent(),this.semicolon();var n=0;for(;n<this.labels.length;++n){var h=this.labels[n];if(e.label==null||h.name===e.label.name){if(h.kind!=null&&(s||h.kind==="loop"))break;if(e.label&&s)break}}if(n===this.labels.length)this.raise(e.start,"Unsyntactic "+i);return this.finishNode(e,s?"BreakStatement":"ContinueStatement")};f.parseDebuggerStatement=function(e){return this.next(),this.semicolon(),this.finishNode(e,"DebuggerStatement")};f.parseDoStatement=function(e){if(this.next(),this.labels.push(yt),e.body=this.parseStatement("do"),this.labels.pop(),this.expect(o._while),e.test=this.parseParenExpression(),this.options.ecmaVersion>=6)this.eat(o.semi);else this.semicolon();return this.finishNode(e,"DoWhileStatement")};f.parseForStatement=function(e){this.next();var i=this.options.ecmaVersion>=9&&this.canAwait&&this.eatContextual("await")?this.lastTokStart:-1;if(this.labels.push(yt),this.enterScope(0),this.expect(o.parenL),this.type===o.semi){if(i>-1)this.unexpected(i);return this.parseFor(e,null)}var s=this.isLet();if(this.type===o._var||this.type===o._const||s){var n=this.startNode(),h=s?"let":this.value;return this.next(),this.parseVar(n,!0,h),this.finishNode(n,"VariableDeclaration"),this.parseForAfterInit(e,n,i)}var p=this.isContextual("let"),l=!1,c=this.isUsing(!0)?"using":this.isAwaitUsing(!0)?"await using":null;if(c){var u=this.startNode();if(this.next(),c==="await using"){if(!this.canAwait)this.raise(this.start,"Await using cannot appear outside of async function");this.next()}return this.parseVar(u,!0,c),this.finishNode(u,"VariableDeclaration"),this.parseForAfterInit(e,u,i)}var d=this.containsEsc,x=new nt,w=this.start,A=i>-1?this.parseExprSubscripts(x,"await"):this.parseExpression(!0,x);if(this.type===o._in||(l=this.options.ecmaVersion>=6&&this.isContextual("of"))){if(i>-1){if(this.type===o._in)this.unexpected(i);e.await=!0}else if(l&&this.options.ecmaVersion>=8){if(A.start===w&&!d&&A.type==="Identifier"&&A.name==="async")this.unexpected();else if(this.options.ecmaVersion>=9)e.await=!1}if(p&&l)this.raise(A.start,"The left-hand side of a for-of loop may not start with 'let'.");return this.toAssignable(A,!1,x),this.checkLValPattern(A),this.parseForIn(e,A)}else this.checkExpressionErrors(x,!0);if(i>-1)this.unexpected(i);return this.parseFor(e,A)};f.parseForAfterInit=function(e,i,s){if((this.type===o._in||this.options.ecmaVersion>=6&&this.isContextual("of"))&&i.declarations.length===1){if(this.type===o._in){if((i.kind==="using"||i.kind==="await using")&&!i.declarations[0].init)this.raise(this.start,"Using declaration is not allowed in for-in loops");if(this.options.ecmaVersion>=9&&s>-1)this.unexpected(s)}else if(this.options.ecmaVersion>=9)e.await=s>-1;return this.parseForIn(e,i)}if(s>-1)this.unexpected(s);return this.parseFor(e,i)};f.parseFunctionStatement=function(e,i,s){return this.next(),this.parseFunction(e,G|(s?0:ct),!1,i)};f.parseIfStatement=function(e){return this.next(),e.test=this.parseParenExpression(),e.consequent=this.parseStatement("if"),e.alternate=this.eat(o._else)?this.parseStatement("if"):null,this.finishNode(e,"IfStatement")};f.parseReturnStatement=function(e){if(!this.allowReturn)this.raise(this.start,"'return' outside of function");if(this.next(),this.eat(o.semi)||this.insertSemicolon())e.argument=null;else e.argument=this.parseExpression(),this.semicolon();return this.finishNode(e,"ReturnStatement")};f.parseSwitchStatement=function(e){this.next(),e.discriminant=this.parseParenExpression(),e.cases=[],this.expect(o.braceL),this.labels.push(Jt),this.enterScope(_t);var i;for(var s=!1;this.type!==o.braceR;)if(this.type===o._case||this.type===o._default){var n=this.type===o._case;if(i)this.finishNode(i,"SwitchCase");if(e.cases.push(i=this.startNode()),i.consequent=[],this.next(),n)i.test=this.parseExpression();else{if(s)this.raiseRecoverable(this.lastTokStart,"Multiple default clauses");s=!0,i.test=null}this.expect(o.colon)}else{if(!i)this.unexpected();i.consequent.push(this.parseStatement(null))}if(this.exitScope(),i)this.finishNode(i,"SwitchCase");return this.next(),this.labels.pop(),this.finishNode(e,"SwitchStatement")};f.parseThrowStatement=function(e){if(this.next(),T.test(this.input.slice(this.lastTokEnd,this.start)))this.raise(this.lastTokEnd,"Illegal newline after throw");return e.argument=this.parseExpression(),this.semicolon(),this.finishNode(e,"ThrowStatement")};var Zt=[];f.parseCatchClauseParam=function(){var e=this.parseBindingAtom(),i=e.type==="Identifier";return this.enterScope(i?Pt:0),this.checkLValPattern(e,i?Rt:V),this.expect(o.parenR),e};f.parseTryStatement=function(e){if(this.next(),e.block=this.parseBlock(),e.handler=null,this.type===o._catch){var i=this.startNode();if(this.next(),this.eat(o.parenL))i.param=this.parseCatchClauseParam();else{if(this.options.ecmaVersion<10)this.unexpected();i.param=null,this.enterScope(0)}i.body=this.parseBlock(!1),this.exitScope(),e.handler=this.finishNode(i,"CatchClause")}if(e.finalizer=this.eat(o._finally)?this.parseBlock():null,!e.handler&&!e.finalizer)this.raise(e.start,"Missing catch or finally clause");return this.finishNode(e,"TryStatement")};f.parseVarStatement=function(e,i,s){return this.next(),this.parseVar(e,!1,i,s),this.semicolon(),this.finishNode(e,"VariableDeclaration")};f.parseWhileStatement=function(e){return this.next(),e.test=this.parseParenExpression(),this.labels.push(yt),e.body=this.parseStatement("while"),this.labels.pop(),this.finishNode(e,"WhileStatement")};f.parseWithStatement=function(e){if(this.strict)this.raise(this.start,"'with' in strict mode");return this.next(),e.object=this.parseParenExpression(),e.body=this.parseStatement("with"),this.finishNode(e,"WithStatement")};f.parseEmptyStatement=function(e){return this.next(),this.finishNode(e,"EmptyStatement")};f.parseLabeledStatement=function(e,i,s,n){for(var h=0,p=this.labels;h<p.length;h+=1){var l=p[h];if(l.name===i)this.raise(s.start,"Label '"+i+"' is already declared")}var c=this.type.isLoop?"loop":this.type===o._switch?"switch":null;for(var u=this.labels.length-1;u>=0;u--){var d=this.labels[u];if(d.statementStart===e.start)d.statementStart=this.start,d.kind=c;else break}return this.labels.push({name:i,kind:c,statementStart:this.start}),e.body=this.parseStatement(n?n.indexOf("label")===-1?n+"label":n:"label"),this.labels.pop(),e.label=s,this.finishNode(e,"LabeledStatement")};f.parseExpressionStatement=function(e,i){return e.expression=i,this.semicolon(),this.finishNode(e,"ExpressionStatement")};f.parseBlock=function(e,i,s){if(e===void 0)e=!0;if(i===void 0)i=this.startNode();if(i.body=[],this.expect(o.braceL),e)this.enterScope(0);while(this.type!==o.braceR){var n=this.parseStatement(null);i.body.push(n)}if(s)this.strict=!1;if(this.next(),e)this.exitScope();return this.finishNode(i,"BlockStatement")};f.parseFor=function(e,i){return e.init=i,this.expect(o.semi),e.test=this.type===o.semi?null:this.parseExpression(),this.expect(o.semi),e.update=this.type===o.parenR?null:this.parseExpression(),this.expect(o.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,"ForStatement")};f.parseForIn=function(e,i){var s=this.type===o._in;if(this.next(),i.type==="VariableDeclaration"&&i.declarations[0].init!=null&&(!s||this.options.ecmaVersion<8||this.strict||i.kind!=="var"||i.declarations[0].id.type!=="Identifier"))this.raise(i.start,(s?"for-in":"for-of")+" loop variable declaration may not have an initializer");return e.left=i,e.right=s?this.parseExpression():this.parseMaybeAssign(),this.expect(o.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,s?"ForInStatement":"ForOfStatement")};f.parseVar=function(e,i,s,n){e.declarations=[],e.kind=s;for(;;){var h=this.startNode();if(this.parseVarId(h,s),this.eat(o.eq))h.init=this.parseMaybeAssign(i);else if(!n&&s==="const"&&!(this.type===o._in||this.options.ecmaVersion>=6&&this.isContextual("of")))this.unexpected();else if(!n&&(s==="using"||s==="await using")&&this.options.ecmaVersion>=17&&this.type!==o._in&&!this.isContextual("of"))this.raise(this.lastTokEnd,"Missing initializer in "+s+" declaration");else if(!n&&h.id.type!=="Identifier"&&!(i&&(this.type===o._in||this.isContextual("of"))))this.raise(this.lastTokEnd,"Complex binding patterns require an initialization value");else h.init=null;if(e.declarations.push(this.finishNode(h,"VariableDeclarator")),!this.eat(o.comma))break}return e};f.parseVarId=function(e,i){e.id=i==="using"||i==="await using"?this.parseIdent():this.parseBindingAtom(),this.checkLValPattern(e.id,i==="var"?xt:V,!1)};var G=1,ct=2,Ft=4;f.parseFunction=function(e,i,s,n,h){if(this.initFunction(e),this.options.ecmaVersion>=9||this.options.ecmaVersion>=6&&!n){if(this.type===o.star&&i&ct)this.unexpected();e.generator=this.eat(o.star)}if(this.options.ecmaVersion>=8)e.async=!!n;if(i&G){if(e.id=i&Ft&&this.type!==o.name?null:this.parseIdent(),e.id&&!(i&ct))this.checkLValSimple(e.id,this.strict||e.generator||e.async?this.treatFunctionsAsVar?xt:V:Lt)}var p=this.yieldPos,l=this.awaitPos,c=this.awaitIdentPos;if(this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(vt(e.async,e.generator)),!(i&G))e.id=this.type===o.name?this.parseIdent():null;return this.parseFunctionParams(e),this.parseFunctionBody(e,s,!1,h),this.yieldPos=p,this.awaitPos=l,this.awaitIdentPos=c,this.finishNode(e,i&G?"FunctionDeclaration":"FunctionExpression")};f.parseFunctionParams=function(e){this.expect(o.parenL),e.params=this.parseBindingList(o.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()};f.parseClass=function(e,i){this.next();var s=this.strict;this.strict=!0,this.parseClassId(e,i),this.parseClassSuper(e);var n=this.enterClassBody(),h=this.startNode(),p=!1;h.body=[],this.expect(o.braceL);while(this.type!==o.braceR){var l=this.parseClassElement(e.superClass!==null);if(l){if(h.body.push(l),l.type==="MethodDefinition"&&l.kind==="constructor"){if(p)this.raiseRecoverable(l.start,"Duplicate constructor in the same class");p=!0}else if(l.key&&l.key.type==="PrivateIdentifier"&&$t(n,l))this.raiseRecoverable(l.key.start,"Identifier '#"+l.key.name+"' has already been declared")}}return this.strict=s,this.next(),e.body=this.finishNode(h,"ClassBody"),this.exitClassBody(),this.finishNode(e,i?"ClassDeclaration":"ClassExpression")};f.parseClassElement=function(e){if(this.eat(o.semi))return null;var i=this.options.ecmaVersion,s=this.startNode(),n="",h=!1,p=!1,l="method",c=!1;if(this.eatContextual("static")){if(i>=13&&this.eat(o.braceL))return this.parseClassStaticBlock(s),s;if(this.isClassElementNameStart()||this.type===o.star)c=!0;else n="static"}if(s.static=c,!n&&i>=8&&this.eatContextual("async"))if((this.isClassElementNameStart()||this.type===o.star)&&!this.canInsertSemicolon())p=!0;else n="async";if(!n&&(i>=9||!p)&&this.eat(o.star))h=!0;if(!n&&!p&&!h){var u=this.value;if(this.eatContextual("get")||this.eatContextual("set"))if(this.isClassElementNameStart())l=u;else n=u}if(n)s.computed=!1,s.key=this.startNodeAt(this.lastTokStart,this.lastTokStartLoc),s.key.name=n,this.finishNode(s.key,"Identifier");else this.parseClassElementName(s);if(i<13||this.type===o.parenL||l!=="method"||h||p){var d=!s.static&&tt(s,"constructor"),x=d&&e;if(d&&l!=="method")this.raise(s.key.start,"Constructor can't have get/set modifier");s.kind=d?"constructor":l,this.parseClassMethod(s,h,p,x)}else this.parseClassField(s);return s};f.isClassElementNameStart=function(){return this.type===o.name||this.type===o.privateId||this.type===o.num||this.type===o.string||this.type===o.bracketL||this.type.keyword};f.parseClassElementName=function(e){if(this.type===o.privateId){if(this.value==="constructor")this.raise(this.start,"Classes can't have an element named '#constructor'");e.computed=!1,e.key=this.parsePrivateIdent()}else this.parsePropertyName(e)};f.parseClassMethod=function(e,i,s,n){var h=e.key;if(e.kind==="constructor"){if(i)this.raise(h.start,"Constructor can't be a generator");if(s)this.raise(h.start,"Constructor can't be an async method")}else if(e.static&&tt(e,"prototype"))this.raise(h.start,"Classes may not have a static property named prototype");var p=e.value=this.parseMethod(i,s,n);if(e.kind==="get"&&p.params.length!==0)this.raiseRecoverable(p.start,"getter should have no params");if(e.kind==="set"&&p.params.length!==1)this.raiseRecoverable(p.start,"setter should have exactly one param");if(e.kind==="set"&&p.params[0].type==="RestElement")this.raiseRecoverable(p.params[0].start,"Setter cannot use rest params");return this.finishNode(e,"MethodDefinition")};f.parseClassField=function(e){if(tt(e,"constructor"))this.raise(e.key.start,"Classes can't have a field named 'constructor'");else if(e.static&&tt(e,"prototype"))this.raise(e.key.start,"Classes can't have a static field named 'prototype'");if(this.eat(o.eq))this.enterScope(Q|rt),e.value=this.parseMaybeAssign(),this.exitScope();else e.value=null;return this.semicolon(),this.finishNode(e,"PropertyDefinition")};f.parseClassStaticBlock=function(e){e.body=[];var i=this.labels;this.labels=[],this.enterScope(M|rt);while(this.type!==o.braceR){var s=this.parseStatement(null);e.body.push(s)}return this.next(),this.exitScope(),this.labels=i,this.finishNode(e,"StaticBlock")};f.parseClassId=function(e,i){if(this.type===o.name){if(e.id=this.parseIdent(),i)this.checkLValSimple(e.id,V,!1)}else{if(i===!0)this.unexpected();e.id=null}};f.parseClassSuper=function(e){e.superClass=this.eat(o._extends)?this.parseExprSubscripts(null,!1):null};f.enterClassBody=function(){var e={declared:Object.create(null),used:[]};return this.privateNameStack.push(e),e.declared};f.exitClassBody=function(){var e=this.privateNameStack.pop(),{declared:i,used:s}=e;if(!this.options.checkPrivateFields)return;var n=this.privateNameStack.length,h=n===0?null:this.privateNameStack[n-1];for(var p=0;p<s.length;++p){var l=s[p];if(!Y(i,l.name))if(h)h.used.push(l);else this.raiseRecoverable(l.start,"Private field '#"+l.name+"' must be declared in an enclosing class")}};function $t(e,i){var s=i.key.name,n=e[s],h="true";if(i.type==="MethodDefinition"&&(i.kind==="get"||i.kind==="set"))h=(i.static?"s":"i")+i.kind;if(n==="iget"&&h==="iset"||n==="iset"&&h==="iget"||n==="sget"&&h==="sset"||n==="sset"&&h==="sget")return e[s]="true",!1;else if(!n)return e[s]=h,!1;else return!0}function tt(e,i){var{computed:s,key:n}=e;return!s&&(n.type==="Identifier"&&n.name===i||n.type==="Literal"&&n.value===i)}f.parseExportAllDeclaration=function(e,i){if(this.options.ecmaVersion>=11)if(this.eatContextual("as"))e.exported=this.parseModuleExportName(),this.checkExport(i,e.exported,this.lastTokStart);else e.exported=null;if(this.expectContextual("from"),this.type!==o.string)this.unexpected();if(e.source=this.parseExprAtom(),this.options.ecmaVersion>=16)e.attributes=this.parseWithClause();return this.semicolon(),this.finishNode(e,"ExportAllDeclaration")};f.parseExport=function(e,i){if(this.next(),this.eat(o.star))return this.parseExportAllDeclaration(e,i);if(this.eat(o._default))return this.checkExport(i,"default",this.lastTokStart),e.declaration=this.parseExportDefaultDeclaration(),this.finishNode(e,"ExportDefaultDeclaration");if(this.shouldParseExportStatement()){if(e.declaration=this.parseExportDeclaration(e),e.declaration.type==="VariableDeclaration")this.checkVariableExport(i,e.declaration.declarations);else this.checkExport(i,e.declaration.id,e.declaration.id.start);if(e.specifiers=[],e.source=null,this.options.ecmaVersion>=16)e.attributes=[]}else{if(e.declaration=null,e.specifiers=this.parseExportSpecifiers(i),this.eatContextual("from")){if(this.type!==o.string)this.unexpected();if(e.source=this.parseExprAtom(),this.options.ecmaVersion>=16)e.attributes=this.parseWithClause()}else{for(var s=0,n=e.specifiers;s<n.length;s+=1){var h=n[s];if(this.checkUnreserved(h.local),this.checkLocalExport(h.local),h.local.type==="Literal")this.raise(h.local.start,"A string literal cannot be used as an exported binding without `from`.")}if(e.source=null,this.options.ecmaVersion>=16)e.attributes=[]}this.semicolon()}return this.finishNode(e,"ExportNamedDeclaration")};f.parseExportDeclaration=function(e){return this.parseStatement(null)};f.parseExportDefaultDeclaration=function(){var e;if(this.type===o._function||(e=this.isAsyncFunction())){var i=this.startNode();if(this.next(),e)this.next();return this.parseFunction(i,G|Ft,!1,e)}else if(this.type===o._class){var s=this.startNode();return this.parseClass(s,"nullableID")}else{var n=this.parseMaybeAssign();return this.semicolon(),n}};f.checkExport=function(e,i,s){if(!e)return;if(typeof i!=="string")i=i.type==="Identifier"?i.name:i.value;if(Y(e,i))this.raiseRecoverable(s,"Duplicate export '"+i+"'");e[i]=!0};f.checkPatternExport=function(e,i){var s=i.type;if(s==="Identifier")this.checkExport(e,i,i.start);else if(s==="ObjectPattern")for(var n=0,h=i.properties;n<h.length;n+=1){var p=h[n];this.checkPatternExport(e,p)}else if(s==="ArrayPattern")for(var l=0,c=i.elements;l<c.length;l+=1){var u=c[l];if(u)this.checkPatternExport(e,u)}else if(s==="Property")this.checkPatternExport(e,i.value);else if(s==="AssignmentPattern")this.checkPatternExport(e,i.left);else if(s==="RestElement")this.checkPatternExport(e,i.argument)};f.checkVariableExport=function(e,i){if(!e)return;for(var s=0,n=i;s<n.length;s+=1){var h=n[s];this.checkPatternExport(e,h.id)}};f.shouldParseExportStatement=function(){return this.type.keyword==="var"||this.type.keyword==="const"||this.type.keyword==="class"||this.type.keyword==="function"||this.isLet()||this.isAsyncFunction()};f.parseExportSpecifier=function(e){var i=this.startNode();return i.local=this.parseModuleExportName(),i.exported=this.eatContextual("as")?this.parseModuleExportName():i.local,this.checkExport(e,i.exported,i.exported.start),this.finishNode(i,"ExportSpecifier")};f.parseExportSpecifiers=function(e){var i=[],s=!0;this.expect(o.braceL);while(!this.eat(o.braceR)){if(!s){if(this.expect(o.comma),this.afterTrailingComma(o.braceR))break}else s=!1;i.push(this.parseExportSpecifier(e))}return i};f.parseImport=function(e){if(this.next(),this.type===o.string)e.specifiers=Zt,e.source=this.parseExprAtom();else e.specifiers=this.parseImportSpecifiers(),this.expectContextual("from"),e.source=this.type===o.string?this.parseExprAtom():this.unexpected();if(this.options.ecmaVersion>=16)e.attributes=this.parseWithClause();return this.semicolon(),this.finishNode(e,"ImportDeclaration")};f.parseImportSpecifier=function(){var e=this.startNode();if(e.imported=this.parseModuleExportName(),this.eatContextual("as"))e.local=this.parseIdent();else this.checkUnreserved(e.imported),e.local=e.imported;return this.checkLValSimple(e.local,V),this.finishNode(e,"ImportSpecifier")};f.parseImportDefaultSpecifier=function(){var e=this.startNode();return e.local=this.parseIdent(),this.checkLValSimple(e.local,V),this.finishNode(e,"ImportDefaultSpecifier")};f.parseImportNamespaceSpecifier=function(){var e=this.startNode();return this.next(),this.expectContextual("as"),e.local=this.parseIdent(),this.checkLValSimple(e.local,V),this.finishNode(e,"ImportNamespaceSpecifier")};f.parseImportSpecifiers=function(){var e=[],i=!0;if(this.type===o.name){if(e.push(this.parseImportDefaultSpecifier()),!this.eat(o.comma))return e}if(this.type===o.star)return e.push(this.parseImportNamespaceSpecifier()),e;this.expect(o.braceL);while(!this.eat(o.braceR)){if(!i){if(this.expect(o.comma),this.afterTrailingComma(o.braceR))break}else i=!1;e.push(this.parseImportSpecifier())}return e};f.parseWithClause=function(){var e=[];if(!this.eat(o._with))return e;this.expect(o.braceL);var i={},s=!0;while(!this.eat(o.braceR)){if(!s){if(this.expect(o.comma),this.afterTrailingComma(o.braceR))break}else s=!1;var n=this.parseImportAttribute(),h=n.key.type==="Identifier"?n.key.name:n.key.value;if(Y(i,h))this.raiseRecoverable(n.key.start,"Duplicate attribute key '"+h+"'");i[h]=!0,e.push(n)}return e};f.parseImportAttribute=function(){var e=this.startNode();if(e.key=this.type===o.string?this.parseExprAtom():this.parseIdent(this.options.allowReserved!=="never"),this.expect(o.colon),this.type!==o.string)this.unexpected();return e.value=this.parseExprAtom(),this.finishNode(e,"ImportAttribute")};f.parseModuleExportName=function(){if(this.options.ecmaVersion>=13&&this.type===o.string){var e=this.parseLiteral(this.value);if(Yt.test(e.value))this.raise(e.start,"An export name cannot include a lone surrogate.");return e}return this.parseIdent(!0)};f.adaptDirectivePrologue=function(e){for(var i=0;i<e.length&&this.isDirectiveCandidate(e[i]);++i)e[i].directive=e[i].expression.raw.slice(1,-1)};f.isDirectiveCandidate=function(e){return this.options.ecmaVersion>=5&&e.type==="ExpressionStatement"&&e.expression.type==="Literal"&&typeof e.expression.value==="string"&&(this.input[e.start]==='"'||this.input[e.start]==="'")};var L=t.prototype;L.toAssignable=function(e,i,s){if(this.options.ecmaVersion>=6&&e)switch(e.type){case"Identifier":if(this.inAsync&&e.name==="await")this.raise(e.start,"Cannot use 'await' as identifier inside an async function");break;case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":case"RestElement":break;case"ObjectExpression":if(e.type="ObjectPattern",s)this.checkPatternErrors(s,!0);for(var n=0,h=e.properties;n<h.length;n+=1){var p=h[n];if(this.toAssignable(p,i),p.type==="RestElement"&&(p.argument.type==="ArrayPattern"||p.argument.type==="ObjectPattern"))this.raise(p.argument.start,"Unexpected token")}break;case"Property":if(e.kind!=="init")this.raise(e.key.start,"Object pattern can't contain getter or setter");this.toAssignable(e.value,i);break;case"ArrayExpression":if(e.type="ArrayPattern",s)this.checkPatternErrors(s,!0);this.toAssignableList(e.elements,i);break;case"SpreadElement":if(e.type="RestElement",this.toAssignable(e.argument,i),e.argument.type==="AssignmentPattern")this.raise(e.argument.start,"Rest elements cannot have a default value");break;case"AssignmentExpression":if(e.operator!=="=")this.raise(e.left.end,"Only '=' operator can be used for specifying default value.");e.type="AssignmentPattern",delete e.operator,this.toAssignable(e.left,i);break;case"ParenthesizedExpression":this.toAssignable(e.expression,i,s);break;case"ChainExpression":this.raiseRecoverable(e.start,"Optional chaining cannot appear in left-hand side");break;case"MemberExpression":if(!i)break;default:this.raise(e.start,"Assigning to rvalue")}else if(s)this.checkPatternErrors(s,!0);return e};L.toAssignableList=function(e,i){var s=e.length;for(var n=0;n<s;n++){var h=e[n];if(h)this.toAssignable(h,i)}if(s){var p=e[s-1];if(this.options.ecmaVersion===6&&i&&p&&p.type==="RestElement"&&p.argument.type!=="Identifier")this.unexpected(p.argument.start)}return e};L.parseSpread=function(e){var i=this.startNode();return this.next(),i.argument=this.parseMaybeAssign(!1,e),this.finishNode(i,"SpreadElement")};L.parseRestBinding=function(){var e=this.startNode();if(this.next(),this.options.ecmaVersion===6&&this.type!==o.name)this.unexpected();return e.argument=this.parseBindingAtom(),this.finishNode(e,"RestElement")};L.parseBindingAtom=function(){if(this.options.ecmaVersion>=6)switch(this.type){case o.bracketL:var e=this.startNode();return this.next(),e.elements=this.parseBindingList(o.bracketR,!0,!0),this.finishNode(e,"ArrayPattern");case o.braceL:return this.parseObj(!0)}return this.parseIdent()};L.parseBindingList=function(e,i,s,n){var h=[],p=!0;while(!this.eat(e)){if(p)p=!1;else this.expect(o.comma);if(i&&this.type===o.comma)h.push(null);else if(s&&this.afterTrailingComma(e))break;else if(this.type===o.ellipsis){var l=this.parseRestBinding();if(this.parseBindingListItem(l),h.push(l),this.type===o.comma)this.raiseRecoverable(this.start,"Comma is not permitted after the rest element");this.expect(e);break}else h.push(this.parseAssignableListItem(n))}return h};L.parseAssignableListItem=function(e){var i=this.parseMaybeDefault(this.start,this.startLoc);return this.parseBindingListItem(i),i};L.parseBindingListItem=function(e){return e};L.parseMaybeDefault=function(e,i,s){if(s=s||this.parseBindingAtom(),this.options.ecmaVersion<6||!this.eat(o.eq))return s;var n=this.startNodeAt(e,i);return n.left=s,n.right=this.parseMaybeAssign(),this.finishNode(n,"AssignmentPattern")};L.checkLValSimple=function(e,i,s){if(i===void 0)i=Z;var n=i!==Z;switch(e.type){case"Identifier":if(this.strict&&this.reservedWordsStrictBind.test(e.name))this.raiseRecoverable(e.start,(n?"Binding ":"Assigning to ")+e.name+" in strict mode");if(n){if(i===V&&e.name==="let")this.raiseRecoverable(e.start,"let is disallowed as a lexically bound name");if(s){if(Y(s,e.name))this.raiseRecoverable(e.start,"Argument name clash");s[e.name]=!0}if(i!==Vt)this.declareName(e.name,i,e.start)}break;case"ChainExpression":this.raiseRecoverable(e.start,"Optional chaining cannot appear in left-hand side");break;case"MemberExpression":if(n)this.raiseRecoverable(e.start,"Binding member expression");break;case"ParenthesizedExpression":if(n)this.raiseRecoverable(e.start,"Binding parenthesized expression");return this.checkLValSimple(e.expression,i,s);default:this.raise(e.start,(n?"Binding":"Assigning to")+" rvalue")}};L.checkLValPattern=function(e,i,s){if(i===void 0)i=Z;switch(e.type){case"ObjectPattern":for(var n=0,h=e.properties;n<h.length;n+=1){var p=h[n];this.checkLValInnerPattern(p,i,s)}break;case"ArrayPattern":for(var l=0,c=e.elements;l<c.length;l+=1){var u=c[l];if(u)this.checkLValInnerPattern(u,i,s)}break;default:this.checkLValSimple(e,i,s)}};L.checkLValInnerPattern=function(e,i,s){if(i===void 0)i=Z;switch(e.type){case"Property":this.checkLValInnerPattern(e.value,i,s);break;case"AssignmentPattern":this.checkLValPattern(e.left,i,s);break;case"RestElement":this.checkLValPattern(e.argument,i,s);break;default:this.checkLValPattern(e,i,s)}};var R=function(i,s,n,h,p){this.token=i,this.isExpr=!!s,this.preserveSpace=!!n,this.override=h,this.generator=!!p},S={b_stat:new R("{",!1),b_expr:new R("{",!0),b_tmpl:new R("${",!1),p_stat:new R("(",!1),p_expr:new R("(",!0),q_tmpl:new R("`",!0,!0,function(e){return e.tryReadTemplateToken()}),f_stat:new R("function",!1),f_expr:new R("function",!0),f_expr_gen:new R("function",!0,!1,null,!0),f_gen:new R("function",!1,!1,null,!0)},W=t.prototype;W.initialContext=function(){return[S.b_stat]};W.curContext=function(){return this.context[this.context.length-1]};W.braceIsBlock=function(e){var i=this.curContext();if(i===S.f_expr||i===S.f_stat)return!0;if(e===o.colon&&(i===S.b_stat||i===S.b_expr))return!i.isExpr;if(e===o._return||e===o.name&&this.exprAllowed)return T.test(this.input.slice(this.lastTokEnd,this.start));if(e===o._else||e===o.semi||e===o.eof||e===o.parenR||e===o.arrow)return!0;if(e===o.braceL)return i===S.b_stat;if(e===o._var||e===o._const||e===o.name)return!1;return!this.exprAllowed};W.inGeneratorContext=function(){for(var e=this.context.length-1;e>=1;e--){var i=this.context[e];if(i.token==="function")return i.generator}return!1};W.updateContext=function(e){var i,s=this.type;if(s.keyword&&e===o.dot)this.exprAllowed=!1;else if(i=s.updateContext)i.call(this,e);else this.exprAllowed=s.beforeExpr};W.overrideContext=function(e){if(this.curContext()!==e)this.context[this.context.length-1]=e};o.parenR.updateContext=o.braceR.updateContext=function(){if(this.context.length===1){this.exprAllowed=!0;return}var e=this.context.pop();if(e===S.b_stat&&this.curContext().token==="function")e=this.context.pop();this.exprAllowed=!e.isExpr};o.braceL.updateContext=function(e){this.context.push(this.braceIsBlock(e)?S.b_stat:S.b_expr),this.exprAllowed=!0};o.dollarBraceL.updateContext=function(){this.context.push(S.b_tmpl),this.exprAllowed=!0};o.parenL.updateContext=function(e){var i=e===o._if||e===o._for||e===o._with||e===o._while;this.context.push(i?S.p_stat:S.p_expr),this.exprAllowed=!0};o.incDec.updateContext=function(){};o._function.updateContext=o._class.updateContext=function(e){if(e.beforeExpr&&e!==o._else&&!(e===o.semi&&this.curContext()!==S.p_stat)&&!(e===o._return&&T.test(this.input.slice(this.lastTokEnd,this.start)))&&!((e===o.colon||e===o.braceL)&&this.curContext()===S.b_stat))this.context.push(S.f_expr);else this.context.push(S.f_stat);this.exprAllowed=!1};o.colon.updateContext=function(){if(this.curContext().token==="function")this.context.pop();this.exprAllowed=!0};o.backQuote.updateContext=function(){if(this.curContext()===S.q_tmpl)this.context.pop();else this.context.push(S.q_tmpl);this.exprAllowed=!1};o.star.updateContext=function(e){if(e===o._function){var i=this.context.length-1;if(this.context[i]===S.f_expr)this.context[i]=S.f_expr_gen;else this.context[i]=S.f_gen}this.exprAllowed=!0};o.name.updateContext=function(e){var i=!1;if(this.options.ecmaVersion>=6&&e!==o.dot){if(this.value==="of"&&!this.exprAllowed||this.value==="yield"&&this.inGeneratorContext())i=!0}this.exprAllowed=i};var m=t.prototype;m.checkPropClash=function(e,i,s){if(this.options.ecmaVersion>=9&&e.type==="SpreadElement")return;if(this.options.ecmaVersion>=6&&(e.computed||e.method||e.shorthand))return;var n=e.key,h;switch(n.type){case"Identifier":h=n.name;break;case"Literal":h=String(n.value);break;default:return}var p=e.kind;if(this.options.ecmaVersion>=6){if(h==="__proto__"&&p==="init"){if(i.proto)if(s){if(s.doubleProto<0)s.doubleProto=n.start}else this.raiseRecoverable(n.start,"Redefinition of __proto__ property");i.proto=!0}return}h="$"+h;var l=i[h];if(l){var c;if(p==="init")c=this.strict&&l.init||l.get||l.set;else c=l.init||l[p];if(c)this.raiseRecoverable(n.start,"Redefinition of property")}else l=i[h]={init:!1,get:!1,set:!1};l[p]=!0};m.parseExpression=function(e,i){var s=this;return this.catchStackOverflow(function(){var{start:n,startLoc:h}=s,p=s.parseMaybeAssign(e,i);if(s.type===o.comma){var l=s.startNodeAt(n,h);l.expressions=[p];while(s.eat(o.comma))l.expressions.push(s.parseMaybeAssign(e,i));return s.finishNode(l,"SequenceExpression")}return p})};m.parseMaybeAssign=function(e,i,s){if(this.isContextual("yield"))if(this.inGenerator)return this.parseYield(e);else this.exprAllowed=!1;var n=!1,h=-1,p=-1,l=-1;if(i)h=i.parenthesizedAssign,p=i.trailingComma,l=i.doubleProto,i.parenthesizedAssign=i.trailingComma=-1;else i=new nt,n=!0;var c=this.start,u=this.startLoc;if(this.type===o.parenL||this.type===o.name)this.potentialArrowAt=this.start,this.potentialArrowInForAwait=e==="await";var d=this.parseMaybeConditional(e,i);if(s)d=s.call(this,d,c,u);if(this.type.isAssign){var x=this.startNodeAt(c,u);if(x.operator=this.value,this.type===o.eq)d=this.toAssignable(d,!1,i);if(!n)i.parenthesizedAssign=i.trailingComma=i.doubleProto=-1;if(i.shorthandAssign>=d.start)i.shorthandAssign=-1;if(this.type===o.eq)this.checkLValPattern(d);else this.checkLValSimple(d);if(x.left=d,this.next(),x.right=this.parseMaybeAssign(e),l>-1)i.doubleProto=l;return this.finishNode(x,"AssignmentExpression")}else if(n)this.checkExpressionErrors(i,!0);if(h>-1)i.parenthesizedAssign=h;if(p>-1)i.trailingComma=p;return d};m.parseMaybeConditional=function(e,i){var s=this.start,n=this.startLoc,h=this.parseExprOps(e,i);if(this.checkExpressionErrors(i))return h;if(!(h.type==="ArrowFunctionExpression"&&h.start===s)&&this.eat(o.question)){var p=this.startNodeAt(s,n);return p.test=h,p.consequent=this.parseMaybeAssign(),this.expect(o.colon),p.alternate=this.parseMaybeAssign(e),this.finishNode(p,"ConditionalExpression")}return h};m.parseExprOps=function(e,i){var s=this.start,n=this.startLoc,h=this.parseMaybeUnary(i,!1,!1,e);if(this.checkExpressionErrors(i))return h;return h.start===s&&h.type==="ArrowFunctionExpression"?h:this.parseExprOp(h,s,n,-1,e)};m.parseExprOp=function(e,i,s,n,h){var p=this.type.binop;if(p!=null&&(!h||this.type!==o._in)){if(p>n){var l=this.type===o.logicalOR||this.type===o.logicalAND,c=this.type===o.coalesce;if(c)p=o.logicalAND.binop;var u=this.value;this.next();var d=this.start,x=this.startLoc,w=this.parseExprOp(this.parseMaybeUnary(null,!1,!1,h),d,x,p,h),A=this.buildBinary(i,s,e,w,u,l||c);if(l&&this.type===o.coalesce||c&&(this.type===o.logicalOR||this.type===o.logicalAND))this.raiseRecoverable(this.start,"Logical expressions and coalesce expressions cannot be mixed. Wrap either by parentheses");return this.parseExprOp(A,i,s,n,h)}}return e};m.buildBinary=function(e,i,s,n,h,p){if(n.type==="PrivateIdentifier")this.raise(n.start,"Private identifier can only be left side of binary expression");var l=this.startNodeAt(e,i);return l.left=s,l.operator=h,l.right=n,this.finishNode(l,p?"LogicalExpression":"BinaryExpression")};m.parseMaybeUnary=function(e,i,s,n){var h=this.start,p=this.startLoc,l;if(this.isContextual("await")&&this.canAwait)l=this.parseAwait(n),i=!0;else if(this.type.prefix){var c=this.startNode(),u=this.type===o.incDec;if(c.operator=this.value,c.prefix=!0,this.next(),c.argument=this.parseMaybeUnary(null,!0,u,n),this.checkExpressionErrors(e,!0),u)this.checkLValSimple(c.argument);else if(this.strict&&c.operator==="delete"&&Ot(c.argument))this.raiseRecoverable(c.start,"Deleting local variable in strict mode");else if(c.operator==="delete"&&ut(c.argument))this.raiseRecoverable(c.start,"Private fields can not be deleted");else i=!0;l=this.finishNode(c,u?"UpdateExpression":"UnaryExpression")}else if(!i&&this.type===o.privateId){if((n||this.privateNameStack.length===0)&&this.options.checkPrivateFields)this.unexpected();if(l=this.parsePrivateIdent(),this.type!==o._in)this.unexpected()}else{if(l=this.parseExprSubscripts(e,n),this.checkExpressionErrors(e))return l;while(this.type.postfix&&!this.canInsertSemicolon()){var d=this.startNodeAt(h,p);d.operator=this.value,d.prefix=!1,d.argument=l,this.checkLValSimple(l),this.next(),l=this.finishNode(d,"UpdateExpression")}}if(!s&&!(l.type==="ArrowFunctionExpression"&&l.start===h)&&this.eat(o.starstar))if(i)this.unexpected(this.lastTokStart);else return this.buildBinary(h,p,l,this.parseMaybeUnary(null,!1,!1,n),"**",!1);else return l};function Ot(e){return e.type==="Identifier"||e.type==="ParenthesizedExpression"&&Ot(e.expression)}function ut(e){return e.type==="MemberExpression"&&e.property.type==="PrivateIdentifier"||e.type==="ChainExpression"&&ut(e.expression)||e.type==="ParenthesizedExpression"&&ut(e.expression)}m.parseExprSubscripts=function(e,i){var s=this.start,n=this.startLoc,h=this.parseExprAtom(e,i);if(h.type==="ArrowFunctionExpression"&&this.input.slice(this.lastTokStart,this.lastTokEnd)!==")")return h;var p=this.parseSubscripts(h,s,n,!1,i);if(e&&p.type==="MemberExpression"){if(e.parenthesizedAssign>=p.start)e.parenthesizedAssign=-1;if(e.parenthesizedBind>=p.start)e.parenthesizedBind=-1;if(e.trailingComma>=p.start)e.trailingComma=-1}return p};m.parseSubscripts=function(e,i,s,n,h){var p=this.options.ecmaVersion>=8&&e.type==="Identifier"&&e.name==="async"&&this.lastTokEnd===e.end&&!this.canInsertSemicolon()&&e.end-e.start===5&&this.potentialArrowAt===e.start,l=!1;while(!0){var c=this.parseSubscript(e,i,s,n,p,l,h);if(c.optional)l=!0;if(c===e||c.type==="ArrowFunctionExpression"){if(l){var u=this.startNodeAt(i,s);u.expression=c,c=this.finishNode(u,"ChainExpression")}return c}e=c}};m.shouldParseAsyncArrow=function(){return!this.canInsertSemicolon()&&this.eat(o.arrow)};m.parseSubscriptAsyncArrow=function(e,i,s,n){return this.parseArrowExpression(this.startNodeAt(e,i),s,!0,n)};m.parseSubscript=function(e,i,s,n,h,p,l){var c=this.options.ecmaVersion>=11,u=c&&this.eat(o.questionDot);if(n&&u)this.raise(this.lastTokStart,"Optional chaining cannot appear in the callee of new expressions");var d=this.eat(o.bracketL);if(d||u&&this.type!==o.parenL&&this.type!==o.backQuote||this.eat(o.dot)){var x=this.startNodeAt(i,s);if(x.object=e,d)x.property=this.parseExpression(),this.expect(o.bracketR);else if(this.type===o.privateId&&e.type!=="Super")x.property=this.parsePrivateIdent();else x.property=this.parseIdent(this.options.allowReserved!=="never");if(x.computed=!!d,c)x.optional=u;e=this.finishNode(x,"MemberExpression")}else if(!n&&this.eat(o.parenL)){var w=new nt,A=this.yieldPos,j=this.awaitPos,D=this.awaitIdentPos;this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0;var X=this.parseExprList(o.parenR,this.options.ecmaVersion>=8,!1,w);if(h&&!u&&this.shouldParseAsyncArrow()){if(this.checkPatternErrors(w,!1),this.checkYieldAwaitInDefaultParams(),this.awaitIdentPos>0)this.raise(this.awaitIdentPos,"Cannot use 'await' as identifier inside an async function");return this.yieldPos=A,this.awaitPos=j,this.awaitIdentPos=D,this.parseSubscriptAsyncArrow(i,s,X,l)}this.checkExpressionErrors(w,!0),this.yieldPos=A||this.yieldPos,this.awaitPos=j||this.awaitPos,this.awaitIdentPos=D||this.awaitIdentPos;var U=this.startNodeAt(i,s);if(U.callee=e,U.arguments=X,c)U.optional=u;e=this.finishNode(U,"CallExpression")}else if(this.type===o.backQuote){if(u||p)this.raise(this.start,"Optional chaining cannot appear in the tag of tagged template expressions");var q=this.startNodeAt(i,s);q.tag=e,q.quasi=this.parseTemplate({isTagged:!0}),e=this.finishNode(q,"TaggedTemplateExpression")}return e};m.parseExprAtom=function(e,i,s){if(this.type===o.slash)this.readRegexp();var n,h=this.potentialArrowAt===this.start;switch(this.type){case o._super:if(!this.allowSuper)this.raise(this.start,"'super' keyword outside a method");if(n=this.startNode(),this.next(),this.type===o.parenL&&!this.allowDirectSuper)this.raise(n.start,"super() call outside constructor of a subclass");if(this.type!==o.dot&&this.type!==o.bracketL&&this.type!==o.parenL)this.unexpected();return this.finishNode(n,"Super");case o._this:return n=this.startNode(),this.next(),this.finishNode(n,"ThisExpression");case o.name:var p=this.start,l=this.startLoc,c=this.containsEsc,u=this.parseIdent(!1);if(this.options.ecmaVersion>=8&&!c&&u.name==="async"&&!this.canInsertSemicolon()&&this.eat(o._function))return this.overrideContext(S.f_expr),this.parseFunction(this.startNodeAt(p,l),0,!1,!0,i);if(h&&!this.canInsertSemicolon()){if(this.eat(o.arrow))return this.parseArrowExpression(this.startNodeAt(p,l),[u],!1,i);if(this.options.ecmaVersion>=8&&u.name==="async"&&this.type===o.name&&!c&&(!this.potentialArrowInForAwait||this.value!=="of"||this.containsEsc)){if(u=this.parseIdent(!1),this.canInsertSemicolon()||!this.eat(o.arrow))this.unexpected();return this.parseArrowExpression(this.startNodeAt(p,l),[u],!0,i)}}return u;case o.regexp:var d=this.value;return n=this.parseLiteral(d.value),n.regex={pattern:d.pattern,flags:d.flags},n;case o.num:case o.string:return this.parseLiteral(this.value);case o._null:case o._true:case o._false:return n=this.startNode(),n.value=this.type===o._null?null:this.type===o._true,n.raw=this.type.keyword,this.next(),this.finishNode(n,"Literal");case o.parenL:var x=this.start,w=this.parseParenAndDistinguishExpression(h,i);if(e){if(e.parenthesizedAssign<0&&!this.isSimpleAssignTarget(w))e.parenthesizedAssign=x;if(e.parenthesizedBind<0)e.parenthesizedBind=x}return w;case o.bracketL:return n=this.startNode(),this.next(),n.elements=this.parseExprList(o.bracketR,!0,!0,e),this.finishNode(n,"ArrayExpression");case o.braceL:return this.overrideContext(S.b_expr),this.parseObj(!1,e);case o._function:return n=this.startNode(),this.next(),this.parseFunction(n,0);case o._class:return this.parseClass(this.startNode(),!1);case o._new:return this.parseNew();case o.backQuote:return this.parseTemplate();case o._import:if(this.options.ecmaVersion>=11)return this.parseExprImport(s);else return this.unexpected();default:return this.parseExprAtomDefault()}};m.parseExprAtomDefault=function(){this.unexpected()};m.parseExprImport=function(e){var i=this.startNode();if(this.containsEsc)this.raiseRecoverable(this.start,"Escape sequence in keyword import");if(this.next(),this.type===o.parenL&&!e)return this.parseDynamicImport(i);else if(this.type===o.dot){var s=this.startNodeAt(i.start,i.loc&&i.loc.start);return s.name="import",i.meta=this.finishNode(s,"Identifier"),this.parseImportMeta(i)}else this.unexpected()};m.parseDynamicImport=function(e){if(this.next(),e.source=this.parseMaybeAssign(),this.options.ecmaVersion>=16)if(!this.eat(o.parenR))if(this.expect(o.comma),!this.afterTrailingComma(o.parenR)){if(e.options=this.parseMaybeAssign(),!this.eat(o.parenR)){if(this.expect(o.comma),!this.afterTrailingComma(o.parenR))this.unexpected()}}else e.options=null;else e.options=null;else if(!this.eat(o.parenR)){var i=this.start;if(this.eat(o.comma)&&this.eat(o.parenR))this.raiseRecoverable(i,"Trailing comma is not allowed in import()");else this.unexpected(i)}return this.finishNode(e,"ImportExpression")};m.parseImportMeta=function(e){this.next();var i=this.containsEsc;if(e.property=this.parseIdent(!0),e.property.name!=="meta")this.raiseRecoverable(e.property.start,"The only valid meta property for import is 'import.meta'");if(i)this.raiseRecoverable(e.start,"'import.meta' must not contain escaped characters");if(this.options.sourceType!=="module"&&!this.options.allowImportExportEverywhere)this.raiseRecoverable(e.start,"Cannot use 'import.meta' outside a module");return this.finishNode(e,"MetaProperty")};m.parseLiteral=function(e){var i=this.startNode();if(i.value=e,i.raw=this.input.slice(this.start,this.end),i.raw.charCodeAt(i.raw.length-1)===110)i.bigint=i.value!=null?i.value.toString():i.raw.slice(0,-1).replace(/_/g,"");return this.next(),this.finishNode(i,"Literal")};m.parseParenExpression=function(){this.expect(o.parenL);var e=this.parseExpression();return this.expect(o.parenR),e};m.shouldParseArrow=function(e){return!this.canInsertSemicolon()};m.parseParenAndDistinguishExpression=function(e,i){var s=this.start,n=this.startLoc,h,p=this.options.ecmaVersion>=8;if(this.options.ecmaVersion>=6){this.next();var l=this.start,c=this.startLoc,u=[],d=!0,x=!1,w=new nt,A=this.yieldPos,j=this.awaitPos,D;this.yieldPos=0,this.awaitPos=0;while(this.type!==o.parenR)if(d?d=!1:this.expect(o.comma),p&&this.afterTrailingComma(o.parenR,!0)){x=!0;break}else if(this.type===o.ellipsis){if(D=this.start,u.push(this.parseParenItem(this.parseRestBinding())),this.type===o.comma)this.raiseRecoverable(this.start,"Comma is not permitted after the rest element");break}else u.push(this.parseMaybeAssign(!1,w,this.parseParenItem));var X=this.lastTokEnd,U=this.lastTokEndLoc;if(this.expect(o.parenR),e&&this.shouldParseArrow(u)&&this.eat(o.arrow))return this.checkPatternErrors(w,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=A,this.awaitPos=j,this.parseParenArrowList(s,n,u,i);if(!u.length||x)this.unexpected(this.lastTokStart);if(D)this.unexpected(D);if(this.checkExpressionErrors(w,!0),this.yieldPos=A||this.yieldPos,this.awaitPos=j||this.awaitPos,u.length>1)h=this.startNodeAt(l,c),h.expressions=u,this.finishNodeAt(h,"SequenceExpression",X,U);else h=u[0]}else h=this.parseParenExpression();if(this.options.preserveParens){var q=this.startNodeAt(s,n);return q.expression=h,this.finishNode(q,"ParenthesizedExpression")}else return h};m.parseParenItem=function(e){return e};m.parseParenArrowList=function(e,i,s,n){return this.parseArrowExpression(this.startNodeAt(e,i),s,!1,n)};var te=[];m.parseNew=function(){if(this.containsEsc)this.raiseRecoverable(this.start,"Escape sequence in keyword new");var e=this.startNode();if(this.next(),this.options.ecmaVersion>=6&&this.type===o.dot){var i=this.startNodeAt(e.start,e.loc&&e.loc.start);i.name="new",e.meta=this.finishNode(i,"Identifier"),this.next();var s=this.containsEsc;if(e.property=this.parseIdent(!0),e.property.name!=="target")this.raiseRecoverable(e.property.start,"The only valid meta property for new is 'new.target'");if(s)this.raiseRecoverable(e.start,"'new.target' must not contain escaped characters");if(!this.allowNewDotTarget)this.raiseRecoverable(e.start,"'new.target' can only be used in functions and class static block");return this.finishNode(e,"MetaProperty")}var n=this.start,h=this.startLoc;if(e.callee=this.parseSubscripts(this.parseExprAtom(null,!1,!0),n,h,!0,!1),e.callee.type==="Super")this.raiseRecoverable(n,"Invalid use of 'super'");if(this.eat(o.parenL))e.arguments=this.parseExprList(o.parenR,this.options.ecmaVersion>=8,!1);else e.arguments=te;return this.finishNode(e,"NewExpression")};m.parseTemplateElement=function(e){var i=e.isTagged,s=this.startNode();if(this.type===o.invalidTemplate){if(!i)this.raiseRecoverable(this.start,"Bad escape sequence in untagged template literal");s.value={raw:this.value.replace(/\r\n?/g,`
4
- `),cooked:null}}else s.value={raw:this.input.slice(this.start,this.end).replace(/\r\n?/g,`
5
- `),cooked:this.value};return this.next(),s.tail=this.type===o.backQuote,this.finishNode(s,"TemplateElement")};m.parseTemplate=function(e){if(e===void 0)e={};var i=e.isTagged;if(i===void 0)i=!1;var s=this.startNode();this.next(),s.expressions=[];var n=this.parseTemplateElement({isTagged:i});s.quasis=[n];while(!n.tail){if(this.type===o.eof)this.raise(this.pos,"Unterminated template literal");this.expect(o.dollarBraceL),s.expressions.push(this.parseExpression()),this.expect(o.braceR),s.quasis.push(n=this.parseTemplateElement({isTagged:i}))}return this.next(),this.finishNode(s,"TemplateLiteral")};m.isAsyncProp=function(e){return!e.computed&&e.key.type==="Identifier"&&e.key.name==="async"&&(this.type===o.name||this.type===o.num||this.type===o.string||this.type===o.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===o.star)&&!T.test(this.input.slice(this.lastTokEnd,this.start))};m.parseObj=function(e,i){var s=this.startNode(),n=!0,h={};s.properties=[],this.next();while(!this.eat(o.braceR)){if(!n){if(this.expect(o.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(o.braceR))break}else n=!1;var p=this.parseProperty(e,i);if(!e)this.checkPropClash(p,h,i);s.properties.push(p)}return this.finishNode(s,e?"ObjectPattern":"ObjectExpression")};m.parseProperty=function(e,i){var s=this.startNode(),n,h,p,l;if(this.options.ecmaVersion>=9&&this.eat(o.ellipsis)){if(e){if(s.argument=this.parseIdent(!1),this.type===o.comma)this.raiseRecoverable(this.start,"Comma is not permitted after the rest element");return this.finishNode(s,"RestElement")}if(s.argument=this.parseMaybeAssign(!1,i),this.type===o.comma&&i&&i.trailingComma<0)i.trailingComma=this.start;return this.finishNode(s,"SpreadElement")}if(this.options.ecmaVersion>=6){if(s.method=!1,s.shorthand=!1,e||i)p=this.start,l=this.startLoc;if(!e)n=this.eat(o.star)}var c=this.containsEsc;if(this.parsePropertyName(s),!e&&!c&&this.options.ecmaVersion>=8&&!n&&this.isAsyncProp(s))h=!0,n=this.options.ecmaVersion>=9&&this.eat(o.star),this.parsePropertyName(s);else h=!1;return this.parsePropertyValue(s,e,n,h,p,l,i,c),this.finishNode(s,"Property")};m.parseGetterSetter=function(e){var i=e.key.name;this.parsePropertyName(e),e.value=this.parseMethod(!1),e.kind=i;var s=e.kind==="get"?0:1;if(e.value.params.length!==s){var n=e.value.start;if(e.kind==="get")this.raiseRecoverable(n,"getter should have no params");else this.raiseRecoverable(n,"setter should have exactly one param")}else if(e.kind==="set"&&e.value.params[0].type==="RestElement")this.raiseRecoverable(e.value.params[0].start,"Setter cannot use rest params")};m.parsePropertyValue=function(e,i,s,n,h,p,l,c){if((s||n)&&this.type===o.colon)this.unexpected();if(this.eat(o.colon))e.value=i?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,l),e.kind="init";else if(this.options.ecmaVersion>=6&&this.type===o.parenL){if(i)this.unexpected();e.method=!0,e.value=this.parseMethod(s,n),e.kind="init"}else if(!i&&!c&&this.options.ecmaVersion>=5&&!e.computed&&e.key.type==="Identifier"&&(e.key.name==="get"||e.key.name==="set")&&(this.type!==o.comma&&this.type!==o.braceR&&this.type!==o.eq)){if(s||n)this.unexpected();this.parseGetterSetter(e)}else if(this.options.ecmaVersion>=6&&!e.computed&&e.key.type==="Identifier"){if(s||n)this.unexpected();if(this.checkUnreserved(e.key),e.key.name==="await"&&!this.awaitIdentPos)this.awaitIdentPos=h;if(i)e.value=this.parseMaybeDefault(h,p,this.copyNode(e.key));else if(this.type===o.eq&&l){if(l.shorthandAssign<0)l.shorthandAssign=this.start;e.value=this.parseMaybeDefault(h,p,this.copyNode(e.key))}else e.value=this.copyNode(e.key);e.kind="init",e.shorthand=!0}else this.unexpected()};m.parsePropertyName=function(e){if(this.options.ecmaVersion>=6)if(this.eat(o.bracketL))return e.computed=!0,e.key=this.parseMaybeAssign(),this.expect(o.bracketR),e.key;else e.computed=!1;return e.key=this.type===o.num||this.type===o.string?this.parseExprAtom():this.parseIdent(this.options.allowReserved!=="never")};m.initFunction=function(e){if(e.id=null,this.options.ecmaVersion>=6)e.generator=e.expression=!1;if(this.options.ecmaVersion>=8)e.async=!1};m.parseMethod=function(e,i,s){var n=this.startNode(),h=this.yieldPos,p=this.awaitPos,l=this.awaitIdentPos;if(this.initFunction(n),this.options.ecmaVersion>=6)n.generator=e;if(this.options.ecmaVersion>=8)n.async=!!i;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(vt(i,n.generator)|rt|(s?It:0)),this.expect(o.parenL),n.params=this.parseBindingList(o.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(n,!1,!0,!1),this.yieldPos=h,this.awaitPos=p,this.awaitIdentPos=l,this.finishNode(n,"FunctionExpression")};m.parseArrowExpression=function(e,i,s,n){var h=this.yieldPos,p=this.awaitPos,l=this.awaitIdentPos;if(this.enterScope(vt(s,!1)|mt),this.initFunction(e),this.options.ecmaVersion>=8)e.async=!!s;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,e.params=this.toAssignableList(i,!0),this.parseFunctionBody(e,!0,!1,n),this.yieldPos=h,this.awaitPos=p,this.awaitIdentPos=l,this.finishNode(e,"ArrowFunctionExpression")};m.parseFunctionBody=function(e,i,s,n){var h=i&&this.type!==o.braceL,p=this.strict,l=!1;if(h)e.body=this.parseMaybeAssign(n),e.expression=!0,this.checkParams(e,!1);else{var c=this.options.ecmaVersion>=7&&!this.isSimpleParamList(e.params);if(!p||c){if(l=this.strictDirective(this.end),l&&c)this.raiseRecoverable(e.start,"Illegal 'use strict' directive in function with non-simple parameter list")}var u=this.labels;if(this.labels=[],l)this.strict=!0;if(this.checkParams(e,!p&&!l&&!i&&!s&&this.isSimpleParamList(e.params)),this.strict&&e.id)this.checkLValSimple(e.id,Vt);e.body=this.parseBlock(!1,void 0,l&&!p),e.expression=!1,this.adaptDirectivePrologue(e.body.body),this.labels=u}this.exitScope()};m.isSimpleParamList=function(e){for(var i=0,s=e;i<s.length;i+=1){var n=s[i];if(n.type!=="Identifier")return!1}return!0};m.checkParams=function(e,i){var s=Object.create(null);for(var n=0,h=e.params;n<h.length;n+=1){var p=h[n];this.checkLValInnerPattern(p,xt,i?null:s)}};m.parseExprList=function(e,i,s,n){var h=[],p=!0;while(!this.eat(e)){if(!p){if(this.expect(o.comma),i&&this.afterTrailingComma(e))break}else p=!1;var l=void 0;if(s&&this.type===o.comma)l=null;else if(this.type===o.ellipsis){if(l=this.parseSpread(n),n&&this.type===o.comma&&n.trailingComma<0)n.trailingComma=this.start}else l=this.parseMaybeAssign(!1,n);h.push(l)}return h};m.checkUnreserved=function(e){var{start:i,end:s,name:n}=e;if(this.inGenerator&&n==="yield")this.raiseRecoverable(i,"Cannot use 'yield' as identifier inside a generator");if(this.inAsync&&n==="await")this.raiseRecoverable(i,"Cannot use 'await' as identifier inside an async function");if(!(this.currentThisScope().flags&at)&&n==="arguments")this.raiseRecoverable(i,"Cannot use 'arguments' in class field initializer");if(this.inClassStaticBlock&&(n==="arguments"||n==="await"))this.raise(i,"Cannot use "+n+" in class static initialization block");if(this.keywords.test(n))this.raise(i,"Unexpected keyword '"+n+"'");if(this.options.ecmaVersion<6&&this.input.slice(i,s).indexOf("\\")!==-1)return;var h=this.strict?this.reservedWordsStrict:this.reservedWords;if(h.test(n)){if(!this.inAsync&&n==="await")this.raiseRecoverable(i,"Cannot use keyword 'await' outside an async function");this.raiseRecoverable(i,"The keyword '"+n+"' is reserved")}};m.parseIdent=function(e){var i=this.parseIdentNode();if(this.next(!!e),this.finishNode(i,"Identifier"),!e){if(this.checkUnreserved(i),i.name==="await"&&!this.awaitIdentPos)this.awaitIdentPos=i.start}return i};m.parseIdentNode=function(){var e=this.startNode();if(this.type===o.name)e.name=this.value;else if(this.type.keyword){if(e.name=this.type.keyword,(e.name==="class"||e.name==="function")&&(this.lastTokEnd!==this.lastTokStart+1||this.input.charCodeAt(this.lastTokStart)!==46))this.context.pop();this.type=o.name}else this.unexpected();return e};m.parsePrivateIdent=function(){var e=this.startNode();if(this.type===o.privateId)e.name=this.value;else this.unexpected();if(this.next(),this.finishNode(e,"PrivateIdentifier"),this.options.checkPrivateFields)if(this.privateNameStack.length===0)this.raise(e.start,"Private field '#"+e.name+"' must be declared in an enclosing class");else this.privateNameStack[this.privateNameStack.length-1].used.push(e);return e};m.parseYield=function(e){if(!this.yieldPos)this.yieldPos=this.start;var i=this.startNode();if(this.next(),this.type===o.semi||this.canInsertSemicolon()||this.type!==o.star&&!this.type.startsExpr)i.delegate=!1,i.argument=null;else i.delegate=this.eat(o.star),i.argument=this.parseMaybeAssign(e);return this.finishNode(i,"YieldExpression")};m.parseAwait=function(e){if(!this.awaitPos)this.awaitPos=this.start;var i=this.startNode();return this.next(),i.argument=this.parseMaybeUnary(null,!0,!1,e),this.finishNode(i,"AwaitExpression")};var et=t.prototype;et.raise=function(e,i){var s=Et(this.input,e);if(i+=" ("+s.line+":"+s.column+")",this.sourceFile)i+=" in "+this.sourceFile;var n=SyntaxError(i);throw n.pos=e,n.loc=s,n.raisedAt=this.pos,n};et.raiseRecoverable=et.raise;et.curPosition=function(){if(this.options.locations)return new H(this.curLine,this.pos-this.lineStart)};var F=t.prototype,ee=function(i){this.flags=i,this.var=[],this.lexical=[],this.functions=[]};F.enterScope=function(e){this.scopeStack.push(new ee(e))};F.exitScope=function(){this.scopeStack.pop()};F.treatFunctionsAsVarInScope=function(e){return e.flags&B||!this.inModule&&e.flags&O};F.declareName=function(e,i,s){var n=!1;if(i===V){var h=this.currentScope();if(n=h.lexical.indexOf(e)>-1||h.functions.indexOf(e)>-1||h.var.indexOf(e)>-1,h.lexical.push(e),this.inModule&&h.flags&O)delete this.undefinedExports[e]}else if(i===Rt){var p=this.currentScope();p.lexical.push(e)}else if(i===Lt){var l=this.currentScope();if(this.treatFunctionsAsVar)n=l.lexical.indexOf(e)>-1;else n=l.lexical.indexOf(e)>-1||l.var.indexOf(e)>-1;l.functions.push(e)}else for(var c=this.scopeStack.length-1;c>=0;--c){var u=this.scopeStack[c];if(u.lexical.indexOf(e)>-1&&!(u.flags&Pt&&u.lexical[0]===e)||!this.treatFunctionsAsVarInScope(u)&&u.functions.indexOf(e)>-1){n=!0;break}if(u.var.push(e),this.inModule&&u.flags&O)delete this.undefinedExports[e];if(u.flags&at)break}if(n)this.raiseRecoverable(s,"Identifier '"+e+"' has already been declared")};F.checkLocalExport=function(e){if(this.scopeStack[0].lexical.indexOf(e.name)===-1&&this.scopeStack[0].var.indexOf(e.name)===-1)this.undefinedExports[e.name]=e};F.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]};F.currentVarScope=function(){for(var e=this.scopeStack.length-1;;e--){var i=this.scopeStack[e];if(i.flags&(at|Q|M))return i}};F.currentThisScope=function(){for(var e=this.scopeStack.length-1;;e--){var i=this.scopeStack[e];if(i.flags&(at|Q|M)&&!(i.flags&mt))return i}};var ot=function(i,s,n){if(this.type="",this.start=s,this.end=0,i.options.locations)this.loc=new st(i,n);if(i.options.directSourceFile)this.sourceFile=i.options.directSourceFile;if(i.options.ranges)this.range=[s,0]},K=t.prototype;K.startNode=function(){return new ot(this,this.start,this.startLoc)};K.startNodeAt=function(e,i){return new ot(this,e,i)};function Bt(e,i,s,n){if(e.type=i,e.end=s,this.options.locations)e.loc.end=n;if(this.options.ranges)e.range[1]=s;return e}K.finishNode=function(e,i){return Bt.call(this,e,i,this.lastTokEnd,this.lastTokEndLoc)};K.finishNodeAt=function(e,i,s,n){return Bt.call(this,e,i,s,n)};K.copyNode=function(e){var i=new ot(this,e.start,this.startLoc);for(var s in e)i[s]=e[s];return i};var Mt=function(){};Mt.prototype.reset=function(){};t.prototype.validateRegExpFlags=function(){};t.prototype.validateRegExpPattern=function(){};var bt=function(i){if(this.type=i.type,this.value=i.value,this.start=i.start,this.end=i.end,i.options.locations)this.loc=new st(i,i.startLoc,i.endLoc);if(i.options.ranges)this.range=[i.start,i.end]},y=t.prototype;y.next=function(e){if(!e&&this.type.keyword&&this.containsEsc)this.raiseRecoverable(this.start,"Escape sequence in keyword "+this.type.keyword);if(this.options.onToken)this.options.onToken(new bt(this));this.lastTokEnd=this.end,this.lastTokStart=this.start,this.lastTokEndLoc=this.endLoc,this.lastTokStartLoc=this.startLoc,this.nextToken()};y.getToken=function(){return this.next(),new bt(this)};if(typeof Symbol<"u")y[Symbol.iterator]=function(){var e=this;return{next:function(){var i=e.getToken();return{done:i.type===o.eof,value:i}}}};y.nextToken=function(){var e=this.curContext();if(!e||!e.preserveSpace)this.skipSpace();if(this.start=this.pos,this.options.locations)this.startLoc=this.curPosition();if(this.pos>=this.input.length)return this.finishToken(o.eof);if(e.override)return e.override(this);else this.readToken(this.fullCharCodeAtPos())};y.readToken=function(e){if(r(e,this.options.ecmaVersion>=6)||e===92)return this.readWord();return this.getTokenFromCode(e)};y.fullCharCodeAt=function(e){var i=this.input.charCodeAt(e);if(i<=55295||i>=56320)return i;var s=this.input.charCodeAt(e+1);return s<=56319||s>=57344?i:(i<<10)+s-56613888};y.fullCharCodeAtPos=function(){return this.fullCharCodeAt(this.pos)};y.skipBlockComment=function(){var e=this.options.onComment&&this.curPosition(),i=this.pos,s=this.input.indexOf("*/",this.pos+=2);if(s===-1)this.raise(this.pos-2,"Unterminated comment");if(this.pos=s+2,this.options.locations)for(var n=void 0,h=i;(n=Ct(this.input,h,this.pos))>-1;)++this.curLine,h=this.lineStart=n;if(this.options.onComment)this.options.onComment(!0,this.input.slice(i+2,s),i,this.pos,e,this.curPosition())};y.skipLineComment=function(e){var i=this.pos,s=this.options.onComment&&this.curPosition(),n=this.input.charCodeAt(this.pos+=e);while(this.pos<this.input.length&&!z(n))n=this.input.charCodeAt(++this.pos);if(this.options.onComment)this.options.onComment(!1,this.input.slice(i+e,this.pos),i,this.pos,s,this.curPosition())};y.skipSpace=function(){t:while(this.pos<this.input.length){var e=this.input.charCodeAt(this.pos);switch(e){case 32:case 160:++this.pos;break;case 13:if(this.input.charCodeAt(this.pos+1)===10)++this.pos;case 10:case 8232:case 8233:if(++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(e>8&&e<14||e>=5760&&At.test(String.fromCharCode(e)))++this.pos;else break t}}};y.finishToken=function(e,i){if(this.end=this.pos,this.options.locations)this.endLoc=this.curPosition();var s=this.type;this.type=e,this.value=i,this.updateContext(s)};y.readToken_dot=function(){var e=this.input.charCodeAt(this.pos+1);if(e>=48&&e<=57)return this.readNumber(!0);var i=this.input.charCodeAt(this.pos+2);if(this.options.ecmaVersion>=6&&e===46&&i===46)return this.pos+=3,this.finishToken(o.ellipsis);else return++this.pos,this.finishToken(o.dot)};y.readToken_slash=function(){var e=this.input.charCodeAt(this.pos+1);if(this.exprAllowed)return++this.pos,this.readRegexp();if(e===61)return this.finishOp(o.assign,2);return this.finishOp(o.slash,1)};y.readToken_mult_modulo_exp=function(e){var i=this.input.charCodeAt(this.pos+1),s=1,n=e===42?o.star:o.modulo;if(this.options.ecmaVersion>=7&&e===42&&i===42)++s,n=o.starstar,i=this.input.charCodeAt(this.pos+2);if(i===61)return this.finishOp(o.assign,s+1);return this.finishOp(n,s)};y.readToken_pipe_amp=function(e){var i=this.input.charCodeAt(this.pos+1);if(i===e){if(this.options.ecmaVersion>=12){var s=this.input.charCodeAt(this.pos+2);if(s===61)return this.finishOp(o.assign,3)}return this.finishOp(e===124?o.logicalOR:o.logicalAND,2)}if(i===61)return this.finishOp(o.assign,2);return this.finishOp(e===124?o.bitwiseOR:o.bitwiseAND,1)};y.readToken_caret=function(){var e=this.input.charCodeAt(this.pos+1);if(e===61)return this.finishOp(o.assign,2);return this.finishOp(o.bitwiseXOR,1)};y.readToken_plus_min=function(e){var i=this.input.charCodeAt(this.pos+1);if(i===e){if(i===45&&!this.inModule&&this.input.charCodeAt(this.pos+2)===62&&(this.lastTokEnd===0||T.test(this.input.slice(this.lastTokEnd,this.pos))))return this.skipLineComment(3),this.skipSpace(),this.nextToken();return this.finishOp(o.incDec,2)}if(i===61)return this.finishOp(o.assign,2);return this.finishOp(o.plusMin,1)};y.readToken_lt_gt=function(e){var i=this.input.charCodeAt(this.pos+1),s=1;if(i===e){if(s=e===62&&this.input.charCodeAt(this.pos+2)===62?3:2,this.input.charCodeAt(this.pos+s)===61)return this.finishOp(o.assign,s+1);return this.finishOp(o.bitShift,s)}if(i===33&&e===60&&!this.inModule&&this.input.charCodeAt(this.pos+2)===45&&this.input.charCodeAt(this.pos+3)===45)return this.skipLineComment(4),this.skipSpace(),this.nextToken();if(i===61)s=2;return this.finishOp(o.relational,s)};y.readToken_eq_excl=function(e){var i=this.input.charCodeAt(this.pos+1);if(i===61)return this.finishOp(o.equality,this.input.charCodeAt(this.pos+2)===61?3:2);if(e===61&&i===62&&this.options.ecmaVersion>=6)return this.pos+=2,this.finishToken(o.arrow);return this.finishOp(e===61?o.eq:o.prefix,1)};y.readToken_question=function(){var e=this.options.ecmaVersion;if(e>=11){var i=this.input.charCodeAt(this.pos+1);if(i===46){var s=this.input.charCodeAt(this.pos+2);if(s<48||s>57)return this.finishOp(o.questionDot,2)}if(i===63){if(e>=12){var n=this.input.charCodeAt(this.pos+2);if(n===61)return this.finishOp(o.assign,3)}return this.finishOp(o.coalesce,2)}}return this.finishOp(o.question,1)};y.readToken_numberSign=function(){var e=this.options.ecmaVersion,i=35;if(e>=13){if(++this.pos,i=this.fullCharCodeAtPos(),r(i,!0)||i===92)return this.finishToken(o.privateId,this.readWord1())}this.raise(this.pos,"Unexpected character '"+it(i)+"'")};y.getTokenFromCode=function(e){switch(e){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(o.parenL);case 41:return++this.pos,this.finishToken(o.parenR);case 59:return++this.pos,this.finishToken(o.semi);case 44:return++this.pos,this.finishToken(o.comma);case 91:return++this.pos,this.finishToken(o.bracketL);case 93:return++this.pos,this.finishToken(o.bracketR);case 123:return++this.pos,this.finishToken(o.braceL);case 125:return++this.pos,this.finishToken(o.braceR);case 58:return++this.pos,this.finishToken(o.colon);case 96:if(this.options.ecmaVersion<6)break;return++this.pos,this.finishToken(o.backQuote);case 48:var i=this.input.charCodeAt(this.pos+1);if(i===120||i===88)return this.readRadixNumber(16);if(this.options.ecmaVersion>=6){if(i===111||i===79)return this.readRadixNumber(8);if(i===98||i===66)return this.readRadixNumber(2)}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return this.readNumber(!1);case 34:case 39:return this.readString(e);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(e);case 124:case 38:return this.readToken_pipe_amp(e);case 94:return this.readToken_caret();case 43:case 45:return this.readToken_plus_min(e);case 60:case 62:return this.readToken_lt_gt(e);case 61:case 33:return this.readToken_eq_excl(e);case 63:return this.readToken_question();case 126:return this.finishOp(o.prefix,1);case 35:return this.readToken_numberSign()}this.raise(this.pos,"Unexpected character '"+it(e)+"'")};y.finishOp=function(e,i){var s=this.input.slice(this.pos,this.pos+i);return this.pos+=i,this.finishToken(e,s)};y.readRegexp=function(){var e,i,s=this.pos;for(;;){if(this.pos>=this.input.length)this.raise(s,"Unterminated regular expression");var n=this.input.charAt(this.pos);if(T.test(n))this.raise(s,"Unterminated regular expression");if(!e){if(n==="[")i=!0;else if(n==="]"&&i)i=!1;else if(n==="/"&&!i)break;e=n==="\\"}else e=!1;++this.pos}var h=this.input.slice(s,this.pos);++this.pos;var p=this.pos,l=this.readWord1();if(this.containsEsc)this.unexpected(p);var c=this.regexpState||(this.regexpState=new Mt(this));c.reset(s,h,l),this.validateRegExpFlags(c),this.validateRegExpPattern(c);var u=null;try{u=new RegExp(h,l)}catch(d){}return this.finishToken(o.regexp,{pattern:h,flags:l,value:u})};y.readInt=function(e,i,s){var n=this.options.ecmaVersion>=12&&i===void 0,h=s&&this.input.charCodeAt(this.pos)===48,p=this.pos,l=0,c=0;for(var u=0,d=i==null?1/0:i;u<d;++u,++this.pos){var x=this.input.charCodeAt(this.pos),w=void 0;if(n&&x===95){if(h)this.raiseRecoverable(this.pos,"Numeric separator is not allowed in legacy octal numeric literals");if(c===95)this.raiseRecoverable(this.pos,"Numeric separator must be exactly one underscore");if(u===0)this.raiseRecoverable(this.pos,"Numeric separator is not allowed at the first of digits");c=x;continue}if(x>=97)w=x-97+10;else if(x>=65)w=x-65+10;else if(x>=48&&x<=57)w=x-48;else w=1/0;if(w>=e)break;c=x,l=l*e+w}if(n&&c===95)this.raiseRecoverable(this.pos-1,"Numeric separator is not allowed at the last of digits");if(this.pos===p||i!=null&&this.pos-p!==i)return null;return l};function ie(e,i){if(i)return parseInt(e,8);return parseFloat(e.replace(/_/g,""))}function Dt(e){if(typeof BigInt!=="function")return null;return BigInt(e.replace(/_/g,""))}y.readRadixNumber=function(e){var i=this.pos;this.pos+=2;var s=this.readInt(e);if(s==null)this.raise(this.start+2,"Expected number in radix "+e);if(this.options.ecmaVersion>=11&&this.input.charCodeAt(this.pos)===110)s=Dt(this.input.slice(i,this.pos)),++this.pos;else if(r(this.fullCharCodeAtPos()))this.raise(this.pos,"Identifier directly after number");return this.finishToken(o.num,s)};y.readNumber=function(e){var i=this.pos;if(!e&&this.readInt(10,void 0,!0)===null)this.raise(i,"Invalid number");var s=this.pos-i>=2&&this.input.charCodeAt(i)===48;if(s&&this.strict)this.raise(i,"Invalid number");var n=this.input.charCodeAt(this.pos);if(!s&&!e&&this.options.ecmaVersion>=11&&n===110){var h=Dt(this.input.slice(i,this.pos));if(++this.pos,r(this.fullCharCodeAtPos()))this.raise(this.pos,"Identifier directly after number");return this.finishToken(o.num,h)}if(s&&/[89]/.test(this.input.slice(i,this.pos)))s=!1;if(n===46&&!s)++this.pos,this.readInt(10),n=this.input.charCodeAt(this.pos);if((n===69||n===101)&&!s){if(n=this.input.charCodeAt(++this.pos),n===43||n===45)++this.pos;if(this.readInt(10)===null)this.raise(i,"Invalid number")}if(r(this.fullCharCodeAtPos()))this.raise(this.pos,"Identifier directly after number");var p=ie(this.input.slice(i,this.pos),s);return this.finishToken(o.num,p)};y.readCodePoint=function(){var e=this.input.charCodeAt(this.pos),i;if(e===123){if(this.options.ecmaVersion<6)this.unexpected();var s=++this.pos;if(i=this.readHexChar(this.input.indexOf("}",this.pos)-this.pos),++this.pos,i>1114111)this.invalidStringToken(s,"Code point out of bounds")}else i=this.readHexChar(4);return i};y.readString=function(e){var i="",s=++this.pos;for(;;){if(this.pos>=this.input.length)this.raise(this.start,"Unterminated string constant");var n=this.input.charCodeAt(this.pos);if(n===e)break;if(n===92)i+=this.input.slice(s,this.pos),i+=this.readEscapedChar(!1),s=this.pos;else if(n===8232||n===8233){if(this.options.ecmaVersion<10)this.raise(this.start,"Unterminated string constant");if(++this.pos,this.options.locations)this.curLine++,this.lineStart=this.pos}else{if(z(n))this.raise(this.start,"Unterminated string constant");++this.pos}}return i+=this.input.slice(s,this.pos++),this.finishToken(o.string,i)};var Ut={};y.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(e){if(e===Ut)this.readInvalidTemplateToken();else throw e}this.inTemplateElement=!1};y.invalidStringToken=function(e,i){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw Ut;else this.raise(e,i)};y.readTmplToken=function(){var e="",i=this.pos;for(;;){if(this.pos>=this.input.length)this.raise(this.start,"Unterminated template");var s=this.input.charCodeAt(this.pos);if(s===96||s===36&&this.input.charCodeAt(this.pos+1)===123){if(this.pos===this.start&&(this.type===o.template||this.type===o.invalidTemplate))if(s===36)return this.pos+=2,this.finishToken(o.dollarBraceL);else return++this.pos,this.finishToken(o.backQuote);return e+=this.input.slice(i,this.pos),this.finishToken(o.template,e)}if(s===92)e+=this.input.slice(i,this.pos),e+=this.readEscapedChar(!0),i=this.pos;else if(z(s)){switch(e+=this.input.slice(i,this.pos),++this.pos,s){case 13:if(this.input.charCodeAt(this.pos)===10)++this.pos;case 10:e+=`
6
- `;break;default:e+=String.fromCharCode(s);break}if(this.options.locations)++this.curLine,this.lineStart=this.pos;i=this.pos}else++this.pos}};y.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(o.invalidTemplate,this.input.slice(this.start,this.pos));case"\r":if(this.input[this.pos+1]===`
7
- `)++this.pos;case`
8
- `:case"\u2028":case"\u2029":++this.curLine,this.lineStart=this.pos+1;break}this.raise(this.start,"Unterminated template")};y.readEscapedChar=function(e){var i=this.input.charCodeAt(++this.pos);switch(++this.pos,i){case 110:return`
9
- `;case 114:return"\r";case 120:return String.fromCharCode(this.readHexChar(2));case 117:return it(this.readCodePoint());case 116:return"\t";case 98:return"\b";case 118:return"\v";case 102:return"\f";case 13:if(this.input.charCodeAt(this.pos)===10)++this.pos;case 10:if(this.options.locations)this.lineStart=this.pos,++this.curLine;return"";case 56:case 57:if(this.strict)this.invalidStringToken(this.pos-1,"Invalid escape sequence");if(e){var s=this.pos-1;this.invalidStringToken(s,"Invalid escape sequence in template string")}default:if(i>=48&&i<=55){var n=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],h=parseInt(n,8);if(h>255)n=n.slice(0,-1),h=parseInt(n,8);if(this.pos+=n.length-1,i=this.input.charCodeAt(this.pos),(n!=="0"||i===56||i===57)&&(this.strict||e))this.invalidStringToken(this.pos-1-n.length,e?"Octal literal in template string":"Octal literal in strict mode");return String.fromCharCode(h)}if(z(i)){if(this.options.locations)this.lineStart=this.pos,++this.curLine;return""}return String.fromCharCode(i)}};y.readHexChar=function(e){var i=this.pos,s=this.readInt(16,e);if(s===null)this.invalidStringToken(i,"Bad character escape sequence");return s};y.readWord1=function(){this.containsEsc=!1;var e="",i=!0,s=this.pos,n=this.options.ecmaVersion>=6;while(this.pos<this.input.length){var h=this.fullCharCodeAtPos();if(a(h,n))this.pos+=h<=65535?1:2;else if(h===92){this.containsEsc=!0,e+=this.input.slice(s,this.pos);var p=this.pos;if(this.input.charCodeAt(++this.pos)!==117)this.invalidStringToken(this.pos,"Expecting Unicode escape sequence \\uXXXX");++this.pos;var l=this.readCodePoint();if(!(i?r:a)(l,n))this.invalidStringToken(p,"Invalid Unicode escape");e+=it(l),s=this.pos}else break;i=!1}return e+this.input.slice(s,this.pos)};y.readWord=function(){var e=this.readWord1(),i=o.name;if(this.keywords.test(e))i=ft[e];return this.finishToken(i,e)};var se="8.18.0";t.acorn={Parser:t,version:se,defaultOptions:lt,Position:H,SourceLocation:st,getLineInfo:Et,Node:ot,TokenType:g,tokTypes:o,keywordTypes:ft,TokContext:R,tokContexts:S,isIdentifierChar:a,isIdentifierStart:r,Token:bt,isNewLine:z,lineBreak:T,lineBreakG:jt,nonASCIIwhitespace:At};function b(e){return(i)=>e(i)}function v(...e){return t.extend(...e)}
10
- export{r,a,t,b,v};
@@ -1,2 +0,0 @@
1
- function Ne(t){return{support:"typescript",parser:t}}function Ce(t){return{support:"entities",names:t}}function _e(t){return t&&"parser"in t?t.parser:void 0}function Pe(t){return t&&"names"in t?t.names:void 0}function w(){throw Error('sveast: parsing TypeScript needs `typescript` from "sveast/typescript": createParser({ typescript })')}
2
- export{Ne,Ce,_e,Pe,w};
@@ -1,2 +0,0 @@
1
- import{x,g}from"./shared-t6kshmn4.js";function m(e,r,o){return x(e),g({isTypeScript:r.typescript??!1,typescript:o,loc:r.loc??!1,comments:r.comments??!0,root:{comments:[]}},e)}
2
- export{m};
@@ -1,12 +0,0 @@
1
- import{b,v}from"./shared-cx7c0gk3.js";import{o,h,u}from"./shared-3ca5cgq8.js";import{w}from"./shared-da2hc1fx.js";var $e="",Le,Ce=0;function x(t){$e=t,Le=void 0,Ce=0}function n(t){if(!Le){Le=[0];let l=$e.indexOf(`
2
- `);while(l!==-1)Le.push(l+1),l=$e.indexOf(`
3
- `,l+1)}let r=0,a=Le.length-1;if(t>=Le[Ce])r=Ce;else a=Ce-1;if(r<a&&t<Le[r+1])a=r;while(r<a){let l=r+a+1>>>1;if(Le[l]<=t)r=l;else a=l-1}return Ce=r,{line:r+1,column:t-Le[r],character:t}}function p(t){let{line:r,column:a}=n(t);return{line:r,column:a}}function Fe(){return $e.split(`
4
- `)}var Ze=/^\t+/;class e extends Error{name="ParseError";code;reason;position;start;end;frame;constructor(t,r,a){super(`${a}
5
- https://svelte.dev/e/${r}`);this.code=r,this.reason=a;let l=typeof t==="number"?t:t?.start,d=typeof t==="number"?t:t?.end;if(l!==void 0)this.position=[l,d??l],this.start=n(this.position[0]),this.end=n(this.position[1]),this.frame=et(this.start.line-1,this.end.column)}}var je=(t)=>t.replace(Ze,(r)=>" ".repeat(r.length));function et(t,r){let a=Fe(),l=Math.max(0,t-2),d=Math.min(t+3,a.length),k=String(d+1).length;return a.slice(l,d).map((m,f)=>{let _e=String(f+l+1).padStart(k," ");if(l+f!==t)return`${_e}: ${je(m)}`;let q=`${" ".repeat(k+2+je(m.slice(0,r)).length)}^`;return`${_e}: ${je(m)}
6
- ${q}`}).join(`
7
- `)}function R(t){throw new e(t,"attribute_duplicate","Attributes need to be unique")}function O(t){throw new e(t,"attribute_empty_shorthand","Attribute shorthand cannot be empty")}function D(t,r){throw new e(t,"block_duplicate_clause",`${r} cannot appear more than once within a block`)}function B(t){throw new e(t,"block_invalid_continuation_placement","{:...} block is invalid at this position (did you forget to close the preceding element or block?)")}function F(t){throw new e(t,"block_invalid_elseif","'elseif' should be 'else if'")}function V(t,r,a){throw new e(t,"block_invalid_placement",`{#${r} ...} block cannot be ${a}`)}function M(t){throw new e(t,"block_unclosed","Block was left open")}function j(t){throw new e(t,"block_unexpected_close","Unexpected block closing tag")}function W(t){throw new e(t,"const_tag_invalid_expression","{@const ...} must consist of a single variable declaration")}function z(t){throw new e(t,"css_empty_declaration","Declaration cannot be empty")}function E(t){throw new e(t,"css_expected_identifier","Expected a valid CSS identifier")}function U(t){throw new e(t,"css_selector_invalid","Invalid selector")}function H(t){throw new e(t,"debug_tag_invalid_arguments","{@debug ...} arguments must be identifiers, not arbitrary expressions")}function N(t){throw new e(t,"declaration_tag_invalid_type","Declaration tags must be `let` or `const` declarations")}function G(t){throw new e(t,"directive_invalid_value","Directive value must be a JavaScript expression enclosed in curly braces")}function K(t,r){throw new e(t,"directive_missing_name",`\`${r}\` name cannot be empty`)}function Q(t,r){throw new e(t,"element_invalid_closing_tag",`\`</${r}>\` attempted to close an element that was not open`)}function X(t,r,a){throw new e(t,"element_invalid_closing_tag_autoclosed",`\`</${r}>\` attempted to close element that was already automatically closed by \`<${a}>\` (cannot nest \`<${a}>\` inside \`<${r}>\`)`)}function T(t,r){throw new e(t,"element_unclosed",`\`<${r}>\` was left open`)}function C(t){throw new e(t,"expected_attribute_value","Expected attribute value")}function Y(t){throw new e(t,"expected_block_type","Expected 'if', 'each', 'await', 'key' or 'snippet'")}function _(t){throw new e(t,"expected_identifier","Expected an identifier")}function J(t){throw new e(t,"expected_pattern","Expected identifier or destructure pattern")}function Z(t){throw new e(t,"expected_tag","Expected 'html', 'render', 'attach', 'const', or 'debug'")}function s(t,r){throw new e(t,"expected_token",`Expected token ${r}`)}function ee(t){throw new e(t,"expected_whitespace","Expected whitespace")}function ze(t,r){throw new e(t,"js_parse_error",`${r}`)}function te(t){throw new e(t,"render_tag_invalid_expression","`{@render ...}` tags can only contain call expressions")}function ie(t){throw new e(t,"script_duplicate","A component can have a single top-level `<script>` element and/or a single top-level `<script module>` element")}function se(t,r){throw new e(t,"script_invalid_attribute_value",`If the \`${r}\` attribute is supplied, it must be a boolean attribute`)}function re(t){throw new e(t,"script_invalid_context",'If the context attribute is supplied, its value must be "module"')}function ne(t,r){throw new e(t,"script_reserved_attribute",`The \`${r}\` attribute is reserved and cannot be used`)}function oe(t){throw new e(t,"style_duplicate","A component can have a single top-level `<style>` element")}function ae(t){throw new e(t,"svelte_component_invalid_this","Invalid component definition — must be an `{expression}`")}function le(t){throw new e(t,"svelte_component_missing_this","`<svelte:component>` must have a 'this' attribute")}function P(t){throw new e(t,"svelte_element_missing_this","`<svelte:element>` must have a 'this' attribute with a value")}function pe(t,r){throw new e(t,"svelte_meta_duplicate",`A component can only have one \`<${r}>\` element`)}function ce(t,r){throw new e(t,"svelte_meta_invalid_content",`<${r}> cannot have children`)}function he(t,r){throw new e(t,"svelte_meta_invalid_placement",`\`<${r}>\` tags cannot be inside elements or blocks`)}function ue(t,r){throw new e(t,"svelte_meta_invalid_tag",`Valid \`<svelte:...>\` tag names are ${r}`)}function fe(t){throw new e(t,"svelte_options_deprecated_tag",'"tag" option is deprecated — use "customElement" instead')}function de(t){throw new e(t,"svelte_options_invalid_attribute","`<svelte:options>` can only receive static attributes")}function A(t,r){throw new e(t,"svelte_options_invalid_attribute_value",`Value must be ${r}, if specified`)}function me(t){throw new e(t,"svelte_options_invalid_customelement",'"customElement" must be a string literal defining a valid custom element name or an object of the form { tag?: string; shadow?: "open" | "none" | `ShadowRootInit`; props?: { [key: string]: { attribute?: string; reflect?: boolean; type: .. } } }')}function ye(t){throw new e(t,"svelte_options_invalid_customelement_props",'"props" must be a statically analyzable object literal of the form "{ [key: string]: { attribute?: string; reflect?: boolean; type?: "String" | "Boolean" | "Number" | "Array" | "Object" }"')}function xe(t){throw new e(t,"svelte_options_invalid_customelement_shadow",'"shadow" must be either "open", "none" or `ShadowRootInit` object.')}function L(t){throw new e(t,"svelte_options_invalid_tagname","Tag name must be lowercase and hyphenated")}function ge(t){throw new e(t,"svelte_options_reserved_tagname","Tag name is reserved")}function be(t,r){throw new e(t,"svelte_options_unknown_attribute",`\`<svelte:options>\` unknown attribute '${r}'`)}function ve(t){throw new e(t,"tag_invalid_name","Expected a valid element or component name. Components must have a valid variable name or dot notation expression")}function Se(t,r,a){throw new e(t,"tag_invalid_placement",`{@${r} ...} tag cannot be ${a}`)}function i(t){throw new e(t,"unexpected_eof","Unexpected end of input")}function ke(t,r){throw new e(t,"unexpected_reserved_word",`'${r}' is a reserved word in JavaScript and cannot be used here`)}function we(t){throw new e(t,"unterminated_string_constant","Unterminated string constant")}function Te(t){throw new e(t,"void_element_invalid_content","Void elements cannot have children or closing tags")}var Ee="",Ve=[],Oe=0;function Ge(t,r){Ee=t,Ve=r,Oe=0}function Je(){return Oe}function Xe(t,r,a,l){Oe=l}function qe(t,r,a,l,d,k){Oe=l;let m=r;if(t&&m.includes(`
8
- `)){let _e=Ee.lastIndexOf(`
9
- `,a-1)+1,q=_e,Ne=Ee.charCodeAt(q);while(Ne===32||Ne===9)Ne=Ee.charCodeAt(++q);if(q>_e)m=tt(m,Ee.slice(_e,q))}let f={type:t?"Block":"Line",value:m,start:a,end:l};if(d&&k)f.loc={start:d,end:k};Ve.push(f)}function tt(t,r){let a=t.startsWith(r)?r.length:0,l="",d=t.indexOf(`
10
- `,a);while(d!==-1){if(l+=t.slice(a,d+1),a=d+1,t.startsWith(r,a))a+=r.length;d=t.indexOf(`
11
- `,a)}return l+t.slice(a)}function Ke(t,r,a){let l=0,d=r.length;while(l<d){let k=l+d>>>1;if(r[k].start<a)l=k+1;else d=k}if(l>=r.length)return;if(y=r.slice(l).map(({type:k,value:m,start:f,end:_e})=>({type:k,value:m,start:f,end:_e})),S=0,Be(t,void 0,!1),S<y.length&&(y[S].start>=t.end||t.type==="Program")){t.trailingComments??=[];while(S<y.length)t.trailingComments.push(y[S++])}}var y=[],S=0,nt=new Map([["BlockStatement","body"],["Program","body"],["ArrayExpression","elements"],["ObjectExpression","properties"]]);function Ue(t,r){for(let a=t;a<r;a++){let l=Ee.charCodeAt(a);if(l!==44&&l!==41&&l!==32&&l!==9)return!0}return!1}function Be(t,r,a){while(S<y.length&&y[S].start<t.start)t.leadingComments??=[],t.leadingComments.push(y[S++]);if(S>=y.length)return;let l=y[S].start;if(l<t.end||!Ue(t.end,l)){let d=h(t),k=nt.get(t.type),m=k===void 0?void 0:d[k],f=Array.isArray(m)&&m.length===0;for(let _e in d){if(S>=y.length)return;if(_e==="type")continue;let q=d[_e];if(Array.isArray(q)){let Ne=_e===k;for(let Pe=0;Pe<q.length;Pe++){let Me=q[Pe];if(o(Me))Be(Me,t,Ne?Pe===q.length-1:f)}}else if(o(q))Be(q,t,f)}if(S>=y.length)return}if(r!==void 0&&t.end===r.end)return;if(a)while(S<y.length){if(r&&y[S].start>=r.end)break;t.trailingComments??=[],t.trailingComments.push(y[S++])}else if(t.end<=y[S].start&&!Ue(t.end,y[S].start))t.trailingComments=[y[S++]]}var Re=!1,Ye=new Map;function We(t){if(!(t instanceof RegExp))return t;let r=Ye.get(t);if(!r){let a=new Set(t.source.slice(4,-2).split("|"));r={test:(l)=>a.has(l)},Ye.set(t,r)}return r}var I=b((t)=>{let{keywordTypes:r,tokTypes:a}=t.acorn,l=new Map("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 const class extends export import super".split(" ").map((d)=>[d,r[d]]));return class extends t{constructor(d,k,m){super(d,k,m);this.keywords=We(this.keywords),this.reservedWords=We(this.reservedWords),this.reservedWordsStrict=We(this.reservedWordsStrict),this.reservedWordsStrictBind=We(this.reservedWordsStrictBind)}parseParenAndDistinguishExpression(d,k){let m=super.parseParenAndDistinguishExpression(d,k);if(m.type==="ParenthesizedExpression")Re=!0;return m}checkLocalExport(){}skipSpace(){let d=this.input,k=this.options.locations,m=this.pos,f=d.charCodeAt(m);for(;;)if(f===32||f===9)f=d.charCodeAt(++m);else if(f===10){if(f=d.charCodeAt(++m),k)this.curLine++,this.lineStart=m}else break;if(this.pos=m,f===47||f<33||f>=128)super.skipSpace()}readWord1(){let d=this.input,k=this.pos,m=k,f=d.charCodeAt(m);while(f>=97&&f<=122||f>=65&&f<=90||f>=48&&f<=57||f===95||f===36)f=d.charCodeAt(++m);if(f>=128||f===92)return super.readWord1();return this.containsEsc=!1,this.pos=m,d.slice(k,m)}readWord(){let d=this.readWord1();return this.finishToken(l.get(d)??a.name,d)}}}),ot=v(I),rt=/ \(\d+:\d+\)$/;function Ie(t){return t}function He(t){return t instanceof SyntaxError&&"pos"in t&&typeof t.pos==="number"}function De(t,r,a,l,d,k=t.root.comments.length){let m=t.root.comments;Ge(r,m);let f={onComment:t.comments?qe:Xe,sourceType:"module",ecmaVersion:16,locations:t.loc,preserveParens:l};if(t.lfOnly)f.startLocation=n(a);let _e=t.isTypeScript?t.typescript:ot;if(!_e)w();let q;try{q=d(_e,f)}catch(Ne){if(!He(Ne))throw Ne;ze(Ne.pos,Ne.message.replace(rt,""))}if(m.length>k)Ke(Ie(q),m,a);return q}function g(t,r,a=0){return Ie(De(t,r,0,!1,(l,d)=>{if(a>0&&d.locations)d.startLocation=n(a);let k=new l(d,r,a).parse();return k.start=0,k},0))}var it={count:0};function c(t,r,a,l=!1){it.count+=1,Re=!1;let d=Ie(De(t,r,a,!0,(m,f)=>m.parseExpressionAt(r,a,f))),k=Math.max(d.end,Je());return{node:Re&&!l?Qe(d):d,end:k}}function Ae(t,r,a){return Ie(De(t,r,a,!1,(l,d)=>{let k=new l(d,r,a);try{return k.nextToken(),k.parseStatement(null,!0,Object.create(null))}catch(m){if(He(m)&&m.pos===r.length)i(r.length);throw m}}))}function Qe(t){let r=t;while(r.type==="ParenthesizedExpression")r=r.expression;return u(r,Qe),r}
12
- export{x,n,p,e,R,O,D,B,F,V,M,j,W,z,E,U,H,N,G,K,Q,X,T,C,Y,_,J,Z,s,ee,te,ie,se,re,ne,oe,ae,le,P,pe,ce,he,ue,fe,de,A,me,ye,xe,L,ge,be,ve,Se,i,ke,we,Te,I,g,c,Ae};
@@ -1,2 +0,0 @@
1
- import{v}from"./shared-cx7c0gk3.js";import{I}from"./shared-t6kshmn4.js";import{y}from"./shared-xw9zc4rz.js";var l=v(y,I);
2
- export{l};