17 lines
150 KiB
JavaScript
Raw Permalink Normal View History

2026-05-31 13:21:13 +02:00
var Ii=Object.create;var Be=Object.defineProperty;var Ni=Object.getOwnPropertyDescriptor;var Li=Object.getOwnPropertyNames;var Ri=Object.getPrototypeOf,Vi=Object.prototype.hasOwnProperty;var ot=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Oi=(e,t)=>{for(var i in t)Be(e,i,{get:t[i],enumerable:!0})},Bi=(e,t,i,s)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of Li(t))!Vi.call(e,r)&&r!==i&&Be(e,r,{get:()=>t[r],enumerable:!(s=Ni(t,r))||s.enumerable});return e};var ut=(e,t,i)=>(i=e!=null?Ii(Ri(e)):{},Bi(t||!e||!e.__esModule?Be(i,"default",{value:e,enumerable:!0}):i,e));var Qt=ot((xr,zt)=>{zt.exports={}});var $e=ot((yr,Ye)=>{"use strict";var _s=Qt(),Cs=/^[\da-fA-F]+$/,Ts=/^\d+$/,Yt=new WeakMap;function $t(e){e=e.Parser.acorn||e;let t=Yt.get(e);if(!t){let i=e.tokTypes,s=e.TokContext,r=e.TokenType,o=new s("<tag",!1),u=new s("</tag",!1),p=new s("<tag>...</tag>",!0,!0),h={tc_oTag:o,tc_cTag:u,tc_expr:p},l={jsxName:new r("jsxName"),jsxText:new r("jsxText",{beforeExpr:!0}),jsxTagStart:new r("jsxTagStart",{startsExpr:!0}),jsxTagEnd:new r("jsxTagEnd")};l.jsxTagStart.updateContext=function(){this.context.push(p),this.context.push(o),this.exprAllowed=!1},l.jsxTagEnd.updateContext=function(m){let S=this.context.pop();S===o&&m===i.slash||S===u?(this.context.pop(),this.exprAllowed=this.curContext()===p):this.exprAllowed=!0},t={tokContexts:h,tokTypes:l},Yt.set(e,t)}return t}function pe(e){if(!e)return e;if(e.type==="JSXIdentifier")return e.name;if(e.type==="JSXNamespacedName")return e.namespace.name+":"+e.name.name;if(e.type==="JSXMemberExpression")return pe(e.object)+"."+pe(e.property)}Ye.exports=function(e){return e=e||{},function(t){return Es({allowNamespaces:e.allowNamespaces!==!1,allowNamespacedObjects:!!e.allowNamespacedObjects},t)}};Object.defineProperty(Ye.exports,"tokTypes",{get:function(){return $t(void 0).tokTypes},configurable:!0,enumerable:!0});function Es(e,t){let i=t.acorn||void 0,s=$t(i),r=i.tokTypes,o=s.tokTypes,u=i.tokContexts,p=s.tokContexts.tc_oTag,h=s.tokContexts.tc_cTag,l=s.tokContexts.tc_expr,m=i.isNewLine,S=i.isIdentifierStart,E=i.isIdentifierChar;return class extends t{static get acornJsx(){return s}jsx_readToken(){let c="",x=this.pos;for(;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated JSX contents");let y=this.input.charCodeAt(this.pos);switch(y){case 60:case 123:return this.pos===this.start?y===60&&this.exprAllowed?(++this.pos,this.finishToken(o.jsxTagStart)):this.getTokenFromCode(y):(c+=this.input.slice(x,this.pos),this.finishToken(o.jsxText,c));case 38:c+=this.input.slice(x,this.pos),c+=this.jsx_readEntity(),x=this.pos;break;case 62:case 125:this.raise(this.pos,"Unexpected token `"+this.input[this.pos]+"`. Did you mean `"+(y===62?"&gt;":"&rbrace;")+'` or `{"'+this.input[this.pos]+'"}`?');default:m(y)?(c+=this.input.slice(x,this.pos),c+=this.jsx_readNewLine(!0),x=this.pos):++this.pos}}}jsx_readNewLine(c){let x=this.input.charCodeAt(this.pos),y;return++this.pos,x===13&&this.input.charCodeAt(this.pos)===10?(++this.pos,y=c?`
`:`\r
`):y=String.fromCharCode(x),this.options.locations&&(++this.curLine,this.lineStart=this.pos),y}jsx_readString(c){let x="",y=++this.pos;for(;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated string constant");let v=this.input.charCodeAt(this.pos);if(v===c)break;v===38?(x+=this.input.slice(y,this.pos),x+=this.jsx_readEntity(),y=this.pos):m(v)?(x+=this.input.slice(y,this.pos),x+=this.jsx_readNewLine(!1),y=this.pos):++this.pos}return x+=this.input.slice(y,this.pos++),this.finishToken(r.string,x)}jsx_readEntity(){let c="",x=0,y,v=this.input[this.pos];v!=="&"&&this.raise(this.pos,"Entity must start with an ampersand");let I=++this.pos;for(;this.pos<this.input.length&&x++<10;){if(v=this.input[this.pos++],v===";"){c[0]==="#"?c[1]==="x"?(c=c.substr(2),Cs.test(c)&&(y=String.fromCharCode(parseInt(c,16)))):(c=c.substr(1),Ts.test(c)&&(y=String.fromCharCode(parseInt(c,10)))):y=_s[c];break}c+=v}return y||(this.pos=I,"&")}jsx_readWord(){let c,x=this.pos;do c=this.input.charCodeAt(++this.pos);while(E(c)||c===45);return this.finishToken(o.jsxName,this.input.slice(x,this.pos))}jsx_parseIdentifier(){let c=this.startNode();return this.type===o.jsxName?c.name=this.value:this.type.keyword?c.name=this.type.keyword:this.unexpected(),this.next(),this.finishNode(c,"JSXIdentifier")}jsx_parseNamespacedName(){let c=this.start,x=this.startLoc,y=this.jsx_parseIdentifier();if(!e.allowNamespaces||!this.eat(r.colon))return y;var v=this.startNodeAt(c,x);return v.namespace=y,v.name=this.jsx_parseIdentifier(),this.finishNode(v,"JSXNamespacedName")}jsx_parseElementName(){if(this.type===o.jsxTagEnd)return"";let c=this.start,x=this.startLoc,y=this.jsx_parseNamespacedName();for(this.type===r.dot&&y.type==="JSXNamespacedName"&&!e.allowNamespacedObjects&&this.unexpected();this.eat(r.dot);){let v=this.startNodeAt(c,x);v.object=y,v.property=this.jsx_parseIdentifier(),y=this.finishNode(v,"JSXMemberExpression")}return y}jsx_parseAttributeValue(){switch(this.type){case r.braceL:let c=this.jsx_parseExpressionContainer();return c.expression.type==="JSXEmptyExpression"&&this.raise(c.start,"JSX attributes must only be assigned a non-empty expression"),c;case o.jsxTagStart:case r.string:return this.parseExprAtom();default:this.raise(this.start,"JSX value should be either an expression or a quoted JSX text")}}jsx_parseEmptyExpression(){let c=this.startNodeAt(this.lastTokEnd,this.lastTokEndLoc);return this.finishNodeAt(c,"JSXEmptyExpression",this.start,this.startLoc)}jsx_parseExpressionContainer(){let c=this.startNode();return this.next(),c.expression=this.type===r.braceR?this.jsx_parseEmptyExpression():this.parseExpression(),this.expect(r.braceR),this.finishNode(c,"JSXExpressionContainer")}jsx_parseAttribute(){let c=this.startNode();return this.eat(r.braceL)?(this.expect(r.ellipsis),c.argument=this.parseMaybeAssign(),this.expect(r.braceR),this.finishNode(c,"JSXSpreadAttribute")):(c.name=this.jsx_parseNamespacedName(),c.value=this.eat(r.eq)?this.jsx_parseAttributeValue():null,this.finishNode(c,"JSXAttribute"))}jsx_parseOpeningElementAt(c,x){let y=this.startNodeAt(c,x);y.attributes=[];let v=this.jsx_parseElementName();for(v&&(y.name=v);this.type!==r.slash&&this.type!==o.jsxTagEnd;)y.attributes.push(this.jsx_parseAttribute());return y.selfClosing=this.eat(r.slash),this.expect(o.jsxTagEnd),this.finishNode(y,v?"JSXOpeningElement":"JSXOpeningFragment")}jsx_parseClosingElementAt(c,x){let y=this.startNodeAt(c,x),v=this.jsx_parseElementName();return v&&(y.name=v),this.expect(o.jsxTagEnd),this.finishNode(y,v?"JSXClosingElement":"JSXClosingFragment")}jsx_parseElementAt(c,x){let y=this.startNodeAt(c,x),v=[],I=this.jsx_parseOpeningElementAt(c,x),de=null;if(!I.selfClosing){e:for(;;)switch(this.type){case o.jsxTagStart:if(c=this.start,x=this.startLoc,this.next(),this.eat(r.slash)){de=this.jsx_parseClosingElementAt(c,x);break e}v.push(this.jsx_parseElementAt(c,x));break;case o.jsxText:v.push(this.parseExprAtom());break;case r.braceL:v.push(this.jsx_parseExpressionContainer());break;default:this.unexpected()}pe(de.name)!==pe(I.name)&&this.raise(de.start,"Expected correspon
Defaulting to 2020, but this will stop working in the future.`)),t.ecmaVersion=11):t.ecmaVersion>=2015&&(t.ecmaVersion-=2009),t.allowReserved==null&&(t.allowReserved=t.ecmaVersion<5),(!e||e.allowHashBang==null)&&(t.allowHashBang=t.ecmaVersion>=14),ht(t.onToken)){var s=t.onToken;t.onToken=function(r){return s.push(r)}}return ht(t.onComment)&&(t.onComment=Wi(t,t.onComment)),t}function Wi(e,t){return function(i,s,r,o,u,p){var h={type:i?"Block":"Line",value:s,start:r,end:o};e.locations&&(h.loc=new be(this,u,p)),e.ranges&&(h.range=[r,o]),t.push(h)}}var oe=1,Z=2,Ke=4,bt=8,He=16,St=32,Se=64,_t=128,z=256,ue=512,_e=oe|Z|z;function Xe(e,t){return Z|(e?Ke:0)|(t?bt:0)}var xe=0,We=1,K=2,Ct=3,Tt=4,Et=5,A=function(t,i,s){this.options=t=Xi(t),this.sourceFile=t.sourceFile,this.keywords=H(Fi[t.ecmaVersion>=6?6:t.sourceType==="module"?"5module":5]);var r="";t.allowReserved!==!0&&(r=De[t.ecmaVersion>=6?6:t.ecmaVersion===5?5:3],t.sourceType==="module"&&(r+=" await")),this.reservedWords=H(r);var o=(r?r+" ":"")+De.strict;this.reservedWordsStrict=H(o),this.reservedWordsStrictBind=H(o+" "+De.strictBind),this.input=String(i),this.containsEsc=!1,s?(this.pos=s,this.lineStart=this.input.lastIndexOf(`
`,s-1)+1,this.curLine=this.input.slice(0,this.lineStart).split(L).length):(this.pos=this.lineStart=0,this.curLine=1),this.type=a.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=t.sourceType==="module",this.strict=this.inModule||this.strictDirective(this.pos),this.potentialArrowAt=-1,this.potentialArrowInForAwait=!1,this.yieldPos=this.awaitPos=this.awaitIdentPos=0,this.labels=[],this.undefinedExports=Object.create(null),this.pos===0&&t.allowHashBang&&this.input.slice(0,2)==="#!"&&this.skipLineComment(2),this.scopeStack=[],this.enterScope(oe),this.regexpState=null,this.privateNameStack=[]},U={inFunction:{configurable:!0},inGenerator:{configurable:!0},inAsync:{configurable:!0},canAwait:{configurable:!0},allowSuper:{configurable:!0},allowDirectSuper:{configurable:!0},treatFunctionsAsVar:{configurable:!0},allowNewDotTarget:{configurable:!0},inClassStaticBlock:{configurable:!0}};A.prototype.parse=function(){var t=this.options.program||this.startNode();return this.nextToken(),this.parseTopLevel(t)};U.inFunction.get=function(){return(this.currentVarScope().flags&Z)>0};U.inGenerator.get=function(){return(this.currentVarScope().flags&bt)>0};U.inAsync.get=function(){return(this.currentVarScope().flags&Ke)>0};U.canAwait.get=function(){for(var e=this.scopeStack.length-1;e>=0;e--){var t=this.scopeStack[e],i=t.flags;if(i&(z|ue))return!1;if(i&Z)return(i&Ke)>0}return this.inModule&&this.options.ecmaVersion>=13||this.options.allowAwaitOutsideFunction};U.allowSuper.get=function(){var e=this.currentThisScope(),t=e.flags;return(t&Se)>0||this.options.allowSuperOutsideMethod};U.allowDirectSuper.get=function(){return(this.currentThisScope().flags&_t)>0};U.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())};U.allowNewDotTarget.get=function(){for(var e=this.scopeStack.length-1;e>=0;e--){var t=this.scopeStack[e],i=t.flags;if(i&(z|ue)||i&Z&&!(i&He))return!0}return!1};U.inClassStaticBlock.get=function(){return(this.currentVarScope().flags&z)>0};A.extend=function(){for(var t=[],i=arguments.length;i--;)t[i]=arguments[i];for(var s=this,r=0;r<t.length;r++)s=t[r](s);return s};A.parse=function(t,i){return new this(i,t).parse()};A.parseExpressionAt=function(t,i,s){var r=new this(s,t,i);return r.nextToken(),r.parseExpression()};A.tokenizer=function(t,i){return new this(i,t)};Object.defineProperties(A.prototype,U);var w=A.prototype,zi=/^(?:'((?:\\[^]|[^'\\])*?)'|"((?:\\[^]|[^"\\])*?)")/;w.strictDirective=function(e){if(this.options.ecmaVersion<5)return!1;for(;;){k.lastIndex=e,e+=k.exec(this.input)[0].length;var t=zi.exec(this.input.slice(e));if(!t)return!1;if((t[1]||t[2])==="use strict"){k.lastIndex=e+t[0].length;var i=k.exec(this.input),s=i.index+i[0].length,r=this.input.charAt(s);return r===";"||r==="}"||L.test(i[0])&&!(/[(`.[+\-/*%<>=,?^&]/.test(r)||r==="!"&&this.input.charAt(s+1)==="=")}e+=t[0].length,k.lastIndex=e,e+=k.exec(this.input)[0].length,this.input[e]===";"&&e++}};w.eat=function(e){return this.type===e?(this.next(),!0):!1};w.isContextual=function(e){return this.type===a.name&&this.value===e&&!this.containsEsc};w.eatContextual=function(e){return this.isContextual(e)?(this.next(),!0):!1};w.expectContextual=function(e){this.eatContextual(e)||this.unexpected()};w.canInsertSemicolon=function(){return this.type===a.eof||this.type===a.braceR||L.test(this.input.slice(this.lastTokEnd,this.start))};w.insertSemicolon=function(){if(this.canInsertSemicolon())return this.options.onInsertedSemicolon&&this.options.onInsertedSemicolon(this.lastTokEnd,this.lastTokEndLoc),!0};w.semicolon=function(){!this.eat(a.semi)&&!this.insertSemicolon()&&this.unexpected()};w.afterTrailingComma=function(e,t){if(this.type===e)return this.options.onTrailingComma&&this.options.onTrailingComma(this.lastTokStart,this.lastTokStartLoc),t||this.next(),!0};w.expect=function(e){this.eat(e)||this.unexpected()};w.unexpected=function(e){this.raise
`),cooked:null}):i.value={raw:this.input.slice(this.start,this.end).replace(/\r\n?/g,`
`),cooked:this.value},this.next(),i.tail=this.type===a.backQuote,this.finishNode(i,"TemplateElement")};g.parseTemplate=function(e){e===void 0&&(e={});var t=e.isTagged;t===void 0&&(t=!1);var i=this.startNode();this.next(),i.expressions=[];var s=this.parseTemplateElement({isTagged:t});for(i.quasis=[s];!s.tail;)this.type===a.eof&&this.raise(this.pos,"Unterminated template literal"),this.expect(a.dollarBraceL),i.expressions.push(this.parseExpression()),this.expect(a.braceR),i.quasis.push(s=this.parseTemplateElement({isTagged:t}));return this.next(),this.finishNode(i,"TemplateLiteral")};g.isAsyncProp=function(e){return!e.computed&&e.key.type==="Identifier"&&e.key.name==="async"&&(this.type===a.name||this.type===a.num||this.type===a.string||this.type===a.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===a.star)&&!L.test(this.input.slice(this.lastTokEnd,this.start))};g.parseObj=function(e,t){var i=this.startNode(),s=!0,r={};for(i.properties=[],this.next();!this.eat(a.braceR);){if(s)s=!1;else if(this.expect(a.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(a.braceR))break;var o=this.parseProperty(e,t);e||this.checkPropClash(o,r,t),i.properties.push(o)}return this.finishNode(i,e?"ObjectPattern":"ObjectExpression")};g.parseProperty=function(e,t){var i=this.startNode(),s,r,o,u;if(this.options.ecmaVersion>=9&&this.eat(a.ellipsis))return e?(i.argument=this.parseIdent(!1),this.type===a.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.finishNode(i,"RestElement")):(i.argument=this.parseMaybeAssign(!1,t),this.type===a.comma&&t&&t.trailingComma<0&&(t.trailingComma=this.start),this.finishNode(i,"SpreadElement"));this.options.ecmaVersion>=6&&(i.method=!1,i.shorthand=!1,(e||t)&&(o=this.start,u=this.startLoc),e||(s=this.eat(a.star)));var p=this.containsEsc;return this.parsePropertyName(i),!e&&!p&&this.options.ecmaVersion>=8&&!s&&this.isAsyncProp(i)?(r=!0,s=this.options.ecmaVersion>=9&&this.eat(a.star),this.parsePropertyName(i)):r=!1,this.parsePropertyValue(i,e,s,r,o,u,t,p),this.finishNode(i,"Property")};g.parseGetterSetter=function(e){var t=e.key.name;this.parsePropertyName(e),e.value=this.parseMethod(!1),e.kind=t;var i=e.kind==="get"?0:1;if(e.value.params.length!==i){var s=e.value.start;e.kind==="get"?this.raiseRecoverable(s,"getter should have no params"):this.raiseRecoverable(s,"setter should have exactly one param")}else e.kind==="set"&&e.value.params[0].type==="RestElement"&&this.raiseRecoverable(e.value.params[0].start,"Setter cannot use rest params")};g.parsePropertyValue=function(e,t,i,s,r,o,u,p){(i||s)&&this.type===a.colon&&this.unexpected(),this.eat(a.colon)?(e.value=t?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,u),e.kind="init"):this.options.ecmaVersion>=6&&this.type===a.parenL?(t&&this.unexpected(),e.method=!0,e.value=this.parseMethod(i,s),e.kind="init"):!t&&!p&&this.options.ecmaVersion>=5&&!e.computed&&e.key.type==="Identifier"&&(e.key.name==="get"||e.key.name==="set")&&this.type!==a.comma&&this.type!==a.braceR&&this.type!==a.eq?((i||s)&&this.unexpected(),this.parseGetterSetter(e)):this.options.ecmaVersion>=6&&!e.computed&&e.key.type==="Identifier"?((i||s)&&this.unexpected(),this.checkUnreserved(e.key),e.key.name==="await"&&!this.awaitIdentPos&&(this.awaitIdentPos=r),t?e.value=this.parseMaybeDefault(r,o,this.copyNode(e.key)):this.type===a.eq&&u?(u.shorthandAssign<0&&(u.shorthandAssign=this.start),e.value=this.parseMaybeDefault(r,o,this.copyNode(e.key))):e.value=this.copyNode(e.key),e.kind="init",e.shorthand=!0):this.unexpected()};g.parsePropertyName=function(e){if(this.options.ecmaVersion>=6){if(this.eat(a.bracketL))return e.computed=!0,e.key=this.parseMaybeAssign(),this.expect(a.bracketR),e.key;e.computed=!1}return e.key=this.type===a.num||this.type===a.string?this.parseExprAtom():this.parseIdent(this.options.allowReserved!=="never")};g.initFunction=function(e){e.id=null,this.options.ecmaVersion>=6&&(e.generator=e.expression=!1),this.options.ecmaVersion>=8&&(e.async=!1)};g.parseMethod=function(e,t,i){var s=this.startNode()
`;break;default:e+=String.fromCharCode(i);break}this.options.locations&&(++this.curLine,this.lineStart=this.pos),t=this.pos}else++this.pos}};b.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(a.invalidTemplate,this.input.slice(this.start,this.pos));case"\r":this.input[this.pos+1]===`
`&&++this.pos;case`
`:case"\u2028":case"\u2029":++this.curLine,this.lineStart=this.pos+1;break}this.raise(this.start,"Unterminated template")};b.readEscapedChar=function(e){var t=this.input.charCodeAt(++this.pos);switch(++this.pos,t){case 110:return`
`;case 114:return"\r";case 120:return String.fromCharCode(this.readHexChar(2));case 117:return q(this.readCodePoint());case 116:return" ";case 98:return"\b";case 118:return"\v";case 102:return"\f";case 13:this.input.charCodeAt(this.pos)===10&&++this.pos;case 10:return this.options.locations&&(this.lineStart=this.pos,++this.curLine),"";case 56:case 57:if(this.strict&&this.invalidStringToken(this.pos-1,"Invalid escape sequence"),e){var i=this.pos-1;this.invalidStringToken(i,"Invalid escape sequence in template string")}default:if(t>=48&&t<=55){var s=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],r=parseInt(s,8);return r>255&&(s=s.slice(0,-1),r=parseInt(s,8)),this.pos+=s.length-1,t=this.input.charCodeAt(this.pos),(s!=="0"||t===56||t===57)&&(this.strict||e)&&this.invalidStringToken(this.pos-1-s.length,e?"Octal literal in template string":"Octal literal in strict mode"),String.fromCharCode(r)}return Y(t)?(this.options.locations&&(this.lineStart=this.pos,++this.curLine),""):String.fromCharCode(t)}};b.readHexChar=function(e){var t=this.pos,i=this.readInt(16,e);return i===null&&this.invalidStringToken(t,"Bad character escape sequence"),i};b.readWord1=function(){this.containsEsc=!1;for(var e="",t=!0,i=this.pos,s=this.options.ecmaVersion>=6;this.pos<this.input.length;){var r=this.fullCharCodeAtPos();if(X(r,s))this.pos+=r<=65535?1:2;else if(r===92){this.containsEsc=!0,e+=this.input.slice(i,this.pos);var o=this.pos;this.input.charCodeAt(++this.pos)!==117&&this.invalidStringToken(this.pos,"Expecting Unicode escape sequence \\uXXXX"),++this.pos;var u=this.readCodePoint();(t?j:X)(u,s)||this.invalidStringToken(o,"Invalid Unicode escape"),e+=q(u),i=this.pos}else break;t=!1}return e+this.input.slice(i,this.pos)};b.readWord=function(){var e=this.readWord1(),t=a.name;return this.keywords.test(e)&&(t=Je[e]),this.finishToken(t,e)};var bs="8.15.0";A.acorn={Parser:A,version:bs,defaultOptions:Ue,Position:ne,SourceLocation:be,getLineInfo:vt,Node:Te,TokenType:C,tokTypes:a,keywordTypes:Je,TokContext:F,tokContexts:T,isIdentifierChar:X,isIdentifierStart:j,Token:Qe,isNewLine:Y,lineBreak:L,lineBreakG:qi,nonASCIIwhitespace:yt};var Si=ut($e(),1);function As(e,t){let i=new SyntaxError(e+" ("+t.loc.start.line+":"+t.loc.start.column+")");return Object.assign(i,t)}var Ae=As;function ke(e){let t=[];for(let i of e)try{return i()}catch(s){t.push(s)}throw Object.assign(new Error("All combinations failed"),{errors:t})}var te=(e,t)=>(i,s,...r)=>i|1&&s==null?void 0:(t.call(s)??s[e]).apply(s,r);var ks=Array.prototype.findLast??function(e){for(let t=this.length-1;t>=0;t--){let i=this[t];if(e(i,t,this))return i}},ws=te("findLast",function(){if(Array.isArray(this))return ks}),Zt=ws;function Ps(e){return this[e<0?this.length+e:e]}var Is=te("at",function(){if(Array.isArray(this)||typeof this=="string")return Ps}),ie=Is;function M(e){let t=e.range?.[0]??e.start,i=(e.declaration?.decorators??e.decorators)?.[0];return i?Math.min(M(i),t):t}function R(e){return e.range?.[1]??e.end}function Ns(e){let t=new Set(e);return i=>t.has(i?.type)}var se=Ns;var Ls=se(["Block","CommentBlock","MultiLine"]),re=Ls;var Rs=se(["Line","CommentLine","SingleLine","HashbangComment","HTMLOpen","HTMLClose","Hashbang","InterpreterDirective"]),ei=Rs;var Ze=new WeakMap;function Vs(e){return Ze.has(e)||Ze.set(e,re(e)&&e.value[0]==="*"&&/@(?:type|satisfies)\b/u.test(e.value)),Ze.get(e)}var ti=Vs;function Os(e){if(!re(e))return!1;let t=`*${e.value}*`.split(`
`);return t.length>1&&t.every(i=>i.trimStart()[0]==="*")}var et=new WeakMap;function Bs(e){return et.has(e)||et.set(e,Os(e)),et.get(e)}var tt=Bs;function Ds(e){if(e.length<2)return;let t;for(let i=e.length-1;i>=0;i--){let s=e[i];if(t&&R(s)===M(t)&&tt(s)&&tt(t)&&(e.splice(i+1,1),s.value+="*//*"+t.value,s.range=[M(s),R(t)]),!ei(s)&&!re(s))throw new TypeError(`Unknown comment type: "${s.type}".`);t=s}}var ii=Ds;function Ms(e){return e!==null&&typeof e=="object"}var si=Ms;var ce=null;function le(e){if(ce!==null&&typeof ce.property){let t=ce;return ce=le.prototype=null,t}return ce=le.prototype=e??Object.create(null),new le}var Fs=10;for(let e=0;e<=Fs;e++)le();function it(e){return le(e)}function js(e,t="type"){it(e);function i(s){let r=s[t],o=e[r];if(!Array.isArray(o))throw Object.assign(new Error(`Missing visitor keys for '${r}'.`),{node:s});return o}return i}var ri=js;var n=[["decorators","key","typeAnnotation","value"],[],["elementType"],["expression"],["expression","typeAnnotation"],["left","right"],["argument"],["directives","body"],["label"],["callee","typeArguments","arguments"],["body"],["decorators","id","typeParameters","superClass","superTypeArguments","mixins","implements","body","superTypeParameters"],["id","typeParameters"],["decorators","key","typeParameters","params","returnType","body"],["decorators","variance","key","typeAnnotation","value"],["name","typeAnnotation"],["test","consequent","alternate"],["checkType","extendsType","trueType","falseType"],["value"],["id","body"],["declaration","specifiers","source","attributes"],["id"],["id","typeParameters","extends","body"],["typeAnnotation"],["id","typeParameters","right"],["body","test"],["members"],["id","init"],["exported"],["left","right","body"],["id","typeParameters","params","predicate","returnType","body"],["id","params","body","typeParameters","returnType"],["key","value"],["local"],["objectType","indexType"],["typeParameter"],["types"],["node"],["object","property"],["argument","cases"],["pattern","body","guard"],["literal"],["decorators","key","value"],["expressions"],["qualification","id"],["decorators","key","typeAnnotation"],["typeParameters","params","returnType"],["expression","typeArguments"],["params"],["parameterName","typeAnnotation"]],ai={AccessorProperty:n[0],AnyTypeAnnotation:n[1],ArgumentPlaceholder:n[1],ArrayExpression:["elements"],ArrayPattern:["elements","typeAnnotation","decorators"],ArrayTypeAnnotation:n[2],ArrowFunctionExpression:["typeParameters","params","predicate","returnType","body"],AsConstExpression:n[3],AsExpression:n[4],AssignmentExpression:n[5],AssignmentPattern:["left","right","decorators","typeAnnotation"],AwaitExpression:n[6],BigIntLiteral:n[1],BigIntLiteralTypeAnnotation:n[1],BigIntTypeAnnotation:n[1],BinaryExpression:n[5],BindExpression:["object","callee"],BlockStatement:n[7],BooleanLiteral:n[1],BooleanLiteralTypeAnnotation:n[1],BooleanTypeAnnotation:n[1],BreakStatement:n[8],CallExpression:n[9],CatchClause:["param","body"],ChainExpression:n[3],ClassAccessorProperty:n[0],ClassBody:n[10],ClassDeclaration:n[11],ClassExpression:n[11],ClassImplements:n[12],ClassMethod:n[13],ClassPrivateMethod:n[13],ClassPrivateProperty:n[14],ClassProperty:n[14],ComponentDeclaration:["id","params","body","typeParameters","rendersType"],ComponentParameter:["name","local"],ComponentTypeAnnotation:["params","rest","typeParameters","rendersType"],ComponentTypeParameter:n[15],ConditionalExpression:n[16],ConditionalTypeAnnotation:n[17],ContinueStatement:n[8],DebuggerStatement:n[1],DeclareClass:["id","typeParameters","extends","mixins","implements","body"],DeclareComponent:["id","params","rest","typeParameters","rendersType"],DeclaredPredicate:n[18],DeclareEnum:n[19],DeclareExportAllDeclaration:["source","attributes"],DeclareExportDeclaration:n[20],DeclareFunction:["id","predicate"],DeclareHook:n[21],DeclareInterface:n[22],DeclareModule:n[19],DeclareModuleExports:n[23],DeclareNamespace:n[19],DeclareOpaqueType:["id","typeParameters","supertype","lowerBound","upperBound"],DeclareTypeAlias:n[24],DeclareVariable:n[21],Decorator:n[3],Directive:n[18]
$1 $2
`);e=e.replace(hi,"").trimEnd();let s=Object.create(null),r=fe(0,e,pi,"").replace(hi,"").trimEnd(),o;for(;o=pi.exec(e);){let u=fe(0,o[2],Ws,"");if(typeof s[o[1]]=="string"||Array.isArray(s[o[1]])){let p=s[o[1]];s[o[1]]=[...Ys,...Array.isArray(p)?p:[p],u]}else s[o[1]]=u}return{comments:r,pragmas:s}}var fi=["noformat","noprettier"],di=["format","prettier"];function $s(e){if(!e.startsWith("#!"))return"";let t=e.indexOf(`
`);return t===-1?e:e.slice(0,t)}var mi=$s;function xi(e){let t=mi(e);t&&(e=e.slice(t.length+1));let i=ci(e),{pragmas:s,comments:r}=li(i);return{shebang:t,text:e,pragmas:s,comments:r}}function yi(e){let{pragmas:t}=xi(e);return di.some(i=>Object.prototype.hasOwnProperty.call(t,i))}function gi(e){let{pragmas:t}=xi(e);return fi.some(i=>Object.prototype.hasOwnProperty.call(t,i))}function Zs(e){return e=typeof e=="function"?{parse:e}:e,{astFormat:"estree",hasPragma:yi,hasIgnorePragma:gi,locStart:M,locEnd:R,...e}}var Ie=Zs;var Ne="module",vi="script",Le="commonjs",Re=[Ne,Le];function Ve(e){if(typeof e=="string"){if(e=e.toLowerCase(),/\.(?:mjs|mts)$/iu.test(e))return Ne;if(/\.(?:cjs|cts)$/iu.test(e))return Le}}var er={ecmaVersion:"latest",allowReserved:!0,allowReturnOutsideFunction:!0,allowSuperOutsideMethod:!0,checkPrivateFields:!1,locations:!1,ranges:!0,preserveParens:!0};function tr(e){let{message:t,loc:i}=e;if(!i)return e;let{line:s,column:r}=i;return Ae(t.replace(/ \(\d+:\d+\)$/u,""),{loc:{start:{line:s,column:r+1}},cause:e})}var bi,ir=()=>(bi??(bi=A.extend((0,Si.default)())),bi);function sr(e,t){let i=ir(),s=[],r=i.parse(e,{...er,sourceType:t===Le?vi:t,allowImportExportEverywhere:t===Ne,onComment:s});return r.comments=s,r}function rr(e,t){let i=Ve(t?.filepath),s=(i?[i]:Re).map(o=>()=>sr(e,o)),r;try{r=ke(s)}catch({errors:[o]}){throw tr(o)}return Pe(r,{text:e})}var _i=Ie(rr);var Ai=ut($e(),1);var P={Boolean:"Boolean",EOF:"<end>",Identifier:"Identifier",PrivateIdentifier:"PrivateIdentifier",Keyword:"Keyword",Null:"Null",Numeric:"Numeric",Punctuator:"Punctuator",String:"String",RegularExpression:"RegularExpression",Template:"Template",JSXIdentifier:"JSXIdentifier",JSXText:"JSXText"};function ar(e,t){let i=e[0],s=ie(0,e,-1),r={type:P.Template,value:t.slice(i.start,s.end)};return i.loc&&(r.loc={start:i.loc.start,end:s.loc.end}),i.range&&(r.start=i.range[0],r.end=s.range[1],r.range=[r.start,r.end]),r}function rt(e,t){this._acornTokTypes=e,this._tokens=[],this._curlyBrace=null,this._code=t}rt.prototype={constructor:rt,translate(e,t){let i=e.type,s=this._acornTokTypes;if(i===s.name)e.type=P.Identifier,e.value==="static"&&(e.type=P.Keyword),t.ecmaVersion>5&&(e.value==="yield"||e.value==="let")&&(e.type=P.Keyword);else if(i===s.privateId)e.type=P.PrivateIdentifier;else if(i===s.semi||i===s.comma||i===s.parenL||i===s.parenR||i===s.braceL||i===s.braceR||i===s.dot||i===s.bracketL||i===s.colon||i===s.question||i===s.bracketR||i===s.ellipsis||i===s.arrow||i===s.jsxTagStart||i===s.incDec||i===s.starstar||i===s.jsxTagEnd||i===s.prefix||i===s.questionDot||i.binop&&!i.keyword||i.isAssign)e.type=P.Punctuator,e.value=this._code.slice(e.start,e.end);else if(i===s.jsxName)e.type=P.JSXIdentifier;else if(i.label==="jsxText"||i===s.jsxAttrValueToken)e.type=P.JSXText;else if(i.keyword)i.keyword==="true"||i.keyword==="false"?e.type=P.Boolean:i.keyword==="null"?e.type=P.Null:e.type=P.Keyword;else if(i===s.num)e.type=P.Numeric,e.value=this._code.slice(e.start,e.end);else if(i===s.string)t.jsxAttrValueToken?(t.jsxAttrValueToken=!1,e.type=P.JSXText):e.type=P.String,e.value=this._code.slice(e.start,e.end);else if(i===s.regexp){e.type=P.RegularExpression;let r=e.value;e.regex={flags:r.flags,pattern:r.pattern},e.value=`/${r.pattern}/${r.flags}`}return e},onToken(e,t){let i=this._acornTokTypes,s=t.tokens,r=this._tokens,o=()=>{s.push(ar(this._tokens,this._code)),this._tokens=[]};if(e.type===i.eof){this._curlyBrace&&s.push(this.translate(this._curlyBrace,t));return}if(e.type===i.backQuote){this._curlyBrace&&(s.push(this.translate(this._curlyBrace,t)),this._curlyBrace=null),r.push(e),r.length>1&&o();return}if(e.type===i.dollarBraceL){r.push(e),o();return}if(e.type===i.braceR){this._curlyBrace&&s.push(this.translate(this._curlyBrace,t)),this._curlyBrace=e;return}if(e.type===i.template||e.type===i.invalidTemplate){this._curlyBrace&&(r.push(this._curlyBrace),this._curlyBrace=null),r.push(e);return}this._curlyBrace&&(s.push(this.translate(this._curlyBrace,t)),this._curlyBrace=null),s.push(this.translate(e,t))}};var Ci=rt;var Ti=[3,5,6,7,8,9,10,11,12,13,14,15,16,17]
`,this.lineStart-2)+1,--this.curLine;this.nextToken()}this.end>this.start&&(r+=` ${this.input.slice(this.start,this.end)}`),this.raise(this.start,r)}jsx_readString(s){let r=super.jsx_readString(s);return this.type===t.string&&(this[Q].jsxAttrValueToken=!0),r}[at](s){return s.type==="TemplateElement"&&this[Q].templateElements.push(s),s.type.includes("Function")&&!s.generator&&(s.generator=!1),s}}};var pr={_regular:null,_jsx:null,get regular(){return this._regular===null&&(this._regular=A.extend(nt())),this._regular},get jsx(){return this._jsx===null&&(this._jsx=A.extend((0,Ai.default)(),nt())),this._jsx},get(e){return!!(e&&e.ecmaFeatures&&e.ecmaFeatures.jsx)?this.jsx:this.regular}};function ki(e,t){let i=pr.get(t);return new i(t,e).parse()}var cr={ecmaVersion:"latest",range:!0,loc:!1,comment:!0,tokens:!1,ecmaFeatures:{jsx:!0,impliedStrict:!1}};function lr(e){let{message:t,lineNumber:i,column:s}=e;return typeof i!="number"?e:Ae(t,{loc:{start:{line:i,column:s}},cause:e})}function fr(e,t){let i=Ve(t?.filepath),s=(i?[i]:Re).map(o=>()=>ki(e,{...cr,sourceType:o})),r;try{r=ke(s)}catch({errors:[o]}){throw lr(o)}return Pe(r,{parser:"espree",text:e})}var wi=Ie(fr);var dr={acorn:_i,espree:wi};export{Pi as default,dr as parsers};