google_forms/node_modules/prettier/plugins/babel.mjs

16 lines
306 KiB
JavaScript
Raw Normal View History

2024-08-09 12:04:48 +00:00
var $s=Object.create;var je=Object.defineProperty;var Vs=Object.getOwnPropertyDescriptor;var qs=Object.getOwnPropertyNames;var zs=Object.getPrototypeOf,Ks=Object.prototype.hasOwnProperty;var Hs=(a,t)=>()=>(t||a((t={exports:{}}).exports,t),t.exports),Ws=(a,t)=>{for(var e in t)je(a,e,{get:t[e],enumerable:!0})},Js=(a,t,e,s)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of qs(t))!Ks.call(a,i)&&i!==e&&je(a,i,{get:()=>t[i],enumerable:!(s=Vs(t,i))||s.enumerable});return a};var vt=(a,t,e)=>(e=a!=null?$s(zs(a)):{},Js(t||!a||!a.__esModule?je(e,"default",{value:a,enumerable:!0}):e,a));var At=Hs(xe=>{"use strict";Object.defineProperty(xe,"__esModule",{value:!0});function Ht(a,t){if(a==null)return{};var e={},s=Object.keys(a),i,r;for(r=0;r<s.length;r++)i=s[r],!(t.indexOf(i)>=0)&&(e[i]=a[i]);return e}var F=class{constructor(t,e,s){this.line=void 0,this.column=void 0,this.index=void 0,this.line=t,this.column=e,this.index=s}},ee=class{constructor(t,e){this.start=void 0,this.end=void 0,this.filename=void 0,this.identifierName=void 0,this.start=t,this.end=e}};function v(a,t){let{line:e,column:s,index:i}=a;return new F(e,s+t,i+t)}var Lt="BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED",Xs={ImportMetaOutsideModule:{message:`import.meta may appear only with 'sourceType: "module"'`,code:Lt},ImportOutsideModule:{message:`'import' and 'export' may appear only with 'sourceType: "module"'`,code:Lt}},Dt={ArrayPattern:"array destructuring pattern",AssignmentExpression:"assignment expression",AssignmentPattern:"assignment expression",ArrowFunctionExpression:"arrow function expression",ConditionalExpression:"conditional expression",CatchClause:"catch clause",ForOfStatement:"for-of statement",ForInStatement:"for-in statement",ForStatement:"for-loop",FormalParameters:"function parameter list",Identifier:"identifier",ImportSpecifier:"import specifier",ImportDefaultSpecifier:"import default specifier",ImportNamespaceSpecifier:"import namespace specifier",ObjectPattern:"object destructuring pattern",ParenthesizedExpression:"parenthesized expression",RestElement:"rest element",UpdateExpression:{true:"prefix operation",false:"postfix operation"},VariableDeclarator:"variable declaration",YieldExpression:"yield expression"},Ce=a=>a.type==="UpdateExpression"?Dt.UpdateExpression[`${a.prefix}`]:Dt[a.type],Gs={AccessorIsGenerator:({kind:a})=>`A ${a}ter cannot be a generator.`,ArgumentsInClass:"'arguments' is only allowed in functions and class methods.",AsyncFunctionInSingleStatementContext:"Async functions can only be declared at the top level or inside a block.",AwaitBindingIdentifier:"Can not use 'await' as identifier inside an async function.",AwaitBindingIdentifierInStaticBlock:"Can not use 'await' as identifier inside a static block.",AwaitExpressionFormalParameter:"'await' is not allowed in async function parameters.",AwaitUsingNotInAsyncContext:"'await using' is only allowed within async functions and at the top levels of modules.",AwaitNotInAsyncContext:"'await' is only allowed within async functions and at the top levels of modules.",AwaitNotInAsyncFunction:"'await' is only allowed within async functions.",BadGetterArity:"A 'get' accessor must not have any formal parameters.",BadSetterArity:"A 'set' accessor must have exactly one formal parameter.",BadSetterRestParameter:"A 'set' accessor function argument must not be a rest parameter.",ConstructorClassField:"Classes may not have a field named 'constructor'.",ConstructorClassPrivateField:"Classes may not have a private field named '#constructor'.",ConstructorIsAccessor:"Class constructor may not be an accessor.",ConstructorIsAsync:"Constructor can't be an async function.",ConstructorIsGenerator:"Constructor can't be a generator.",DeclarationMissingInitializer:({kind:a})=>`Missing initializer in ${a} declaration.`,DecoratorArgumentsOutsideParentheses:"Decorator arguments must be moved inside parentheses: use '@(decorator(args))' instead of '@(decorator)(args)'.",DecoratorBeforeExport:"Decorators must be placed *before* the 'export' keyword. Remove the 'decoratorsBeforeExport: true' option to use the
- Did you mean \`export { '${a}' as '${t}' } from 'some-module'\`?`,ExportDefaultFromAsIdentifier:"'from' is not allowed as an identifier after 'export default'.",ForInOfLoopInitializer:({type:a})=>`'${a==="ForInStatement"?"for-in":"for-of"}' loop variable declaration may not have an initializer.`,ForInUsing:"For-in loop may not start with 'using' declaration.",ForOfAsync:"The left-hand side of a for-of loop may not be 'async'.",ForOfLet:"The left-hand side of a for-of loop may not start with 'let'.",GeneratorInSingleStatementContext:"Generators can only be declared at the top level or inside a block.",IllegalBreakContinue:({type:a})=>`Unsyntactic ${a==="BreakStatement"?"break":"continue"}.`,IllegalLanguageModeDirective:"Illegal 'use strict' directive in function with non-simple parameter list.",IllegalReturn:"'return' outside of function.",ImportAttributesUseAssert:"The `assert` keyword in import attributes is deprecated and it has been replaced by the `with` keyword. You can enable the `deprecatedAssertSyntax: true` option in the import attributes plugin to suppress this error.",ImportBindingIsString:({importName:a})=>`A string literal cannot be used as an imported binding.
- Did you mean \`import { "${a}" as foo }\`?`,ImportCallArgumentTrailingComma:"Trailing comma is disallowed inside import(...) arguments.",ImportCallArity:({maxArgumentCount:a})=>`\`import()\` requires exactly ${a===1?"one argument":"one or two arguments"}.`,ImportCallNotNewExpression:"Cannot use new with import(...).",ImportCallSpreadArgument:"`...` is not allowed in `import()`.",ImportJSONBindingNotDefault:"A JSON module can only be imported with `default`.",ImportReflectionHasAssertion:"`import module x` cannot have assertions.",ImportReflectionNotBinding:'Only `import module x from "./module"` is valid.',IncompatibleRegExpUVFlags:"The 'u' and 'v' regular expression flags cannot be enabled at the same time.",InvalidBigIntLiteral:"Invalid BigIntLiteral.",InvalidCodePoint:"Code point out of bounds.",InvalidCoverInitializedName:"Invalid shorthand property initializer.",InvalidDecimal:"Invalid decimal.",InvalidDigit:({radix:a})=>`Expected number in radix ${a}.`,InvalidEscapeSequence:"Bad character escape sequence.",InvalidEscapeSequenceTemplate:"Invalid escape sequence in template.",InvalidEscapedReservedWord:({reservedWord:a})=>`Escape sequence in keyword ${a}.`,InvalidIdentifier:({identifierName:a})=>`Invalid identifier ${a}.`,InvalidLhs:({ancestor:a})=>`Invalid left-hand side in ${Ce(a)}.`,InvalidLhsBinding:({ancestor:a})=>`Binding invalid left-hand side in ${Ce(a)}.`,InvalidLhsOptionalChaining:({ancestor:a})=>`Invalid optional chaining in the left-hand side of ${Ce(a)}.`,InvalidNumber:"Invalid number.",InvalidOrMissingExponent:"Floating-point numbers require a valid exponent after the 'e'.",InvalidOrUnexpectedToken:({unexpected:a})=>`Unexpected character '${a}'.`,InvalidParenthesizedAssignment:"Invalid parenthesized assignment pattern.",InvalidPrivateFieldResolution:({identifierName:a})=>`Private name #${a} is not defined.`,InvalidPropertyBindingPattern:"Binding member expression.",InvalidRecordProperty:"Only properties and spread elements are allowed in record definitions.",InvalidRestAssignmentPattern:"Invalid rest operator's argument.",LabelRedeclaration:({labelName:a})=>`Label '${a}' is already declared.`,LetInLexicalBinding:"'let' is disallowed as a lexically bound name.",LineTerminatorBeforeArrow:"No line break is allowed before '=>'.",MalformedRegExpFlags:"Invalid regular expression flag.",MissingClassName:"A class name is required.",MissingEqInAssignment:"Only '=' operator can be used for specifying default value.",MissingSemicolon:"Missing semicolon.",MissingPlugin:({missingPlugin:a})=>`This experimental syntax requires enabling the parser plugin: ${a.map(t=>JSON.stringify(t)).join(", ")}.`,MissingOneOfPlugins:({missingPlugin:a})=>`This experimental syntax requires enabling one of the following parser plugin(s): ${a.map(t=>JSON.stringify(t)).join(", ")}.`,MissingUnicodeEscape:"Expecting Unicode escape sequence \\uXXXX.",MixingCoalesceWithLogical:"Nullish coalescing operator(??) requires parens when mixing with logical operators.",ModuleAttributeDifferentFromType:"The only accepted module attribute is `type`.",ModuleAttributeInvalidValue:"Only string literals are allowed as module attribute values.",ModuleAttributesWithDuplicateKeys:({key:a})=>`Duplicate key "${a}" is not allowed in module attributes.`,ModuleExportNameHasLoneSurrogate:({surrogateCharCode:a})=>`An export name cannot include a lone surrogate, found '\\u${a.toString(16)}'.`,ModuleExportUndefined:({localName:a})=>`Export '${a}' is not defined.`,MultipleDefaultsInSwitch:"Multiple default clauses.",NewlineAfterThrow:"Illegal newline after throw.",NoCatchOrFinally:"Missing catch or finally clause.",NumberIdentifier:"Identifier directly after number.",NumericSeparatorInEscapeSequence:"Numeric separators are not allowed inside unicode escape sequences or hex escape sequences.",ObsoleteAwaitStar:"'await*' has been removed from the async functions proposal. Use Promise.all() instead.",OptionalChainingNoNew:"Constructors in/after an Optional Chain are not allowed.",OptionalChainingNoTemplate:"Tagged Template Literals are not allowed in optionalChain.",Ov
`,++e,d===13&&t.charCodeAt(e)===10&&++e,++i,u=s=e):r.unterminated(n,o,h):++e}return{pos:e,str:c,firstInvalidLoc:l,lineStart:s,curLine:i,containsInvalid:!!l}}function vi(a,t,e,s){return a==="template"?t===96||t===36&&e.charCodeAt(s+1)===123:t===(a==="double"?34:39)}function Li(a,t,e,s,i,r){let n=!i;t++;let o=c=>({pos:t,ch:c,lineStart:e,curLine:s}),h=a.charCodeAt(t++);switch(h){case 110:return o(`
`);case 114:return o("\r");case 120:{let c;return{code:c,pos:t}=Ze(a,t,e,s,2,!1,n,r),o(c===null?null:String.fromCharCode(c))}case 117:{let c;return{code:c,pos:t}=is(a,t,e,s,n,r),o(c===null?null:String.fromCodePoint(c))}case 116:return o(" ");case 98:return o("\b");case 118:return o("\v");case 102:return o("\f");case 13:a.charCodeAt(t)===10&&++t;case 10:e=t,++s;case 8232:case 8233:return o("");case 56:case 57:if(i)return o(null);r.strictNumericEscape(t-1,e,s);default:if(h>=48&&h<=55){let c=t-1,u=/^[0-7]+/.exec(a.slice(c,t+2))[0],f=parseInt(u,8);f>255&&(u=u.slice(0,-1),f=parseInt(u,8)),t+=u.length-1;let d=a.charCodeAt(t);if(u!=="0"||d===56||d===57){if(i)return o(null);r.strictNumericEscape(c,e,s)}return o(String.fromCharCode(f))}return o(String.fromCharCode(h))}}function Ze(a,t,e,s,i,r,n,o){let h=t,c;return{n:c,pos:t}=ss(a,t,e,s,16,i,r,!1,o,!n),c===null&&(n?o.invalidEscapeSequence(h,e,s):t=h-1),{code:c,pos:t}}function ss(a,t,e,s,i,r,n,o,h,c){let l=t,u=i===16?Rt.hex:Rt.decBinOct,f=i===16?we.hex:i===10?we.dec:i===8?we.oct:we.bin,d=!1,y=0;for(let E=0,L=r??1/0;E<L;++E){let S=a.charCodeAt(t),I;if(S===95&&o!=="bail"){let Ae=a.charCodeAt(t-1),ne=a.charCodeAt(t+1);if(o){if(Number.isNaN(ne)||!f(ne)||u.has(Ae)||u.has(ne)){if(c)return{n:null,pos:t};h.unexpectedNumericSeparator(t,e,s)}}else{if(c)return{n:null,pos:t};h.numericSeparatorInEscapeSequence(t,e,s)}++t;continue}if(S>=97?I=S-97+10:S>=65?I=S-65+10:ki(S)?I=S-48:I=1/0,I>=i){if(I<=9&&c)return{n:null,pos:t};if(I<=9&&h.invalidDigit(t,e,s,i))I=0;else if(n)I=0,d=!0;else break}++t,y=y*i+I}return t===l||r!=null&&t-l!==r||d?{n:null,pos:t}:{n:y,pos:t}}function is(a,t,e,s,i,r){let n=a.charCodeAt(t),o;if(n===123){if(++t,{code:o,pos:t}=Ze(a,t,e,s,a.indexOf("}",t)-t,!0,i,r),++t,o!==null&&o>1114111)if(i)r.invalidCodePoint(t,e,s);else return{code:null,pos:t}}else({code:o,pos:t}=Ze(a,t,e,s,4,!1,i,r));return{code:o,pos:t}}function ce(a,t,e){return new F(e,a-t,a)}var Di=new Set([103,109,115,105,121,117,100,118]),O=class{constructor(t){this.type=t.type,this.value=t.value,this.start=t.start,this.end=t.end,this.loc=new ee(t.startLoc,t.endLoc)}},et=class extends Ye{constructor(t,e){super(),this.isLookahead=void 0,this.tokens=[],this.errorHandlers_readInt={invalidDigit:(s,i,r,n)=>this.options.errorRecovery?(this.raise(p.InvalidDigit,ce(s,i,r),{radix:n}),!0):!1,numericSeparatorInEscapeSequence:this.errorBuilder(p.NumericSeparatorInEscapeSequence),unexpectedNumericSeparator:this.errorBuilder(p.UnexpectedNumericSeparator)},this.errorHandlers_readCodePoint=Object.assign({},this.errorHandlers_readInt,{invalidEscapeSequence:this.errorBuilder(p.InvalidEscapeSequence),invalidCodePoint:this.errorBuilder(p.InvalidCodePoint)}),this.errorHandlers_readStringContents_string=Object.assign({},this.errorHandlers_readCodePoint,{strictNumericEscape:(s,i,r)=>{this.recordStrictModeErrors(p.StrictNumericEscape,ce(s,i,r))},unterminated:(s,i,r)=>{throw this.raise(p.UnterminatedString,ce(s-1,i,r))}}),this.errorHandlers_readStringContents_template=Object.assign({},this.errorHandlers_readCodePoint,{strictNumericEscape:this.errorBuilder(p.StrictNumericEscape),unterminated:(s,i,r)=>{throw this.raise(p.UnterminatedTemplate,ce(s,i,r))}}),this.state=new Qe,this.state.init(t),this.input=e,this.length=e.length,this.comments=[],this.isLookahead=!1}pushToken(t){this.tokens.length=this.state.tokensLength,this.tokens.push(t),++this.state.tokensLength}next(){this.checkKeywordEscapes(),this.options.tokens&&this.pushToken(new O(this.state)),this.state.lastTokEndLoc=this.state.endLoc,this.state.lastTokStartLoc=this.state.startLoc,this.nextToken()}eat(t){return this.match(t)?(this.next(),!0):!1}match(t){return this.state.type===t}createLookaheadState(t){return{pos:t.pos,value:null,type:t.type,start:t.start,end:t.end,context:[this.curContext()],inType:t.inType,startLoc:t.startLoc,lastTokEndLoc:t.lastTokEndLoc,curLine:t.curLine,lineStart:t.lineStart,curPosition:t.curPosition}}lookahead(){let t=this.state;this.state=this.createLookaheadState(t),this.isLookahead=!0,this.nextToken(),this.isLookahead=!1;let e=this.state;return this.state=t,e}nextTok
`:`\r
`):i=String.fromCharCode(s),++this.state.curLine,this.state.lineStart=this.state.pos,i}jsxReadString(e){let s="",i=++this.state.pos;for(;;){if(this.state.pos>=this.length)throw this.raise(p.UnterminatedString,this.state.startLoc);let r=this.input.charCodeAt(this.state.pos);if(r===e)break;r===38?(s+=this.input.slice(i,this.state.pos),s+=this.jsxReadEntity(),i=this.state.pos):fe(r)?(s+=this.input.slice(i,this.state.pos),s+=this.jsxReadNewLine(!1),i=this.state.pos):++this.state.pos}s+=this.input.slice(i,this.state.pos++),this.finishToken(133,s)}jsxReadEntity(){let e=++this.state.pos;if(this.codePointAtPos(this.state.pos)===35){++this.state.pos;let s=10;this.codePointAtPos(this.state.pos)===120&&(s=16,++this.state.pos);let i=this.readInt(s,void 0,!1,"bail");if(i!==null&&this.codePointAtPos(this.state.pos)===59)return++this.state.pos,String.fromCodePoint(i)}else{let s=0,i=!1;for(;s++<10&&this.state.pos<this.length&&!(i=this.codePointAtPos(this.state.pos)===59);)++this.state.pos;if(i){let r=this.input.slice(e,this.state.pos),n=void 0;if(++this.state.pos,n)return n}}return this.state.pos=e,"&"}jsxReadWord(){let e,s=this.state.pos;do e=this.input.charCodeAt(++this.state.pos);while(Q(e)||e===45);this.finishToken(140,this.input.slice(s,this.state.pos))}jsxParseIdentifier(){let e=this.startNode();return this.match(140)?e.name=this.state.value:Pt(this.state.type)?e.name=K(this.state.type):this.unexpected(),this.next(),this.finishNode(e,"JSXIdentifier")}jsxParseNamespacedName(){let e=this.state.startLoc,s=this.jsxParseIdentifier();if(!this.eat(14))return s;let i=this.startNodeAt(e);return i.namespace=s,i.name=this.jsxParseIdentifier(),this.finishNode(i,"JSXNamespacedName")}jsxParseElementName(){let e=this.state.startLoc,s=this.jsxParseNamespacedName();if(s.type==="JSXNamespacedName")return s;for(;this.eat(16);){let i=this.startNodeAt(e);i.object=s,i.property=this.jsxParseIdentifier(),s=this.finishNode(i,"JSXMemberExpression")}return s}jsxParseAttributeValue(){let e;switch(this.state.type){case 5:return e=this.startNode(),this.setContext(C.brace),this.next(),e=this.jsxParseExpressionContainer(e,C.j_oTag),e.expression.type==="JSXEmptyExpression"&&this.raise(W.AttributeIsEmpty,e),e;case 142:case 133:return this.parseExprAtom();default:throw this.raise(W.UnsupportedJsxValue,this.state.startLoc)}}jsxParseEmptyExpression(){let e=this.startNodeAt(this.state.lastTokEndLoc);return this.finishNodeAt(e,"JSXEmptyExpression",this.state.startLoc)}jsxParseSpreadChild(e){return this.next(),e.expression=this.parseExpression(),this.setContext(C.j_expr),this.state.canStartJSXElement=!0,this.expect(8),this.finishNode(e,"JSXSpreadChild")}jsxParseExpressionContainer(e,s){if(this.match(8))e.expression=this.jsxParseEmptyExpression();else{let i=this.parseExpression();e.expression=i}return this.setContext(s),this.state.canStartJSXElement=!0,this.expect(8),this.finishNode(e,"JSXExpressionContainer")}jsxParseAttribute(){let e=this.startNode();return this.match(5)?(this.setContext(C.brace),this.next(),this.expect(21),e.argument=this.parseMaybeAssignAllowIn(),this.setContext(C.j_oTag),this.state.canStartJSXElement=!0,this.expect(8),this.finishNode(e,"JSXSpreadAttribute")):(e.name=this.jsxParseNamespacedName(),e.value=this.eat(29)?this.jsxParseAttributeValue():null,this.finishNode(e,"JSXAttribute"))}jsxParseOpeningElementAt(e){let s=this.startNodeAt(e);return this.eat(143)?this.finishNode(s,"JSXOpeningFragment"):(s.name=this.jsxParseElementName(),this.jsxParseOpeningElementAfterName(s))}jsxParseOpeningElementAfterName(e){let s=[];for(;!this.match(56)&&!this.match(143);)s.push(this.jsxParseAttribute());return e.attributes=s,e.selfClosing=this.eat(56),this.expect(143),this.finishNode(e,"JSXOpeningElement")}jsxParseClosingElementAt(e){let s=this.startNodeAt(e);return this.eat(143)?this.finishNode(s,"JSXClosingFragment"):(s.name=this.jsxParseElementName(),this.expect(143),this.finishNode(s,"JSXClosingElement"))}jsxParseElementAt(e){let s=this.startNodeAt(e),i=[],r=this.jsxParseOpeningElementAt(e),n=null;if(!r.selfClosing){e:for(;;)switch(this.state.type){case 142:if(
`),cooked:r===null?null:r.slice(1,c)},o.tail=h,this.next();let u=this.finishNode(o,"TemplateElement");return this.resetEndLocation(u,v(this.state.lastTokEndLoc,c)),u}parseTemplate(t){let e=this.startNode(),s=this.parseTemplateElement(t),i=[s],r=[];for(;!s.tail;)r.push(this.parseTemplateSubstitution()),this.readTemplateContinuation(),i.push(s=this.parseTemplateElement(t));return e.expressions=r,e.quasis=i,this.finishNode(e,"TemplateLiteral")}parseTemplateSubstitution(){return this.parseExpression()}parseObjectLike(t,e,s,i){s&&this.expectPlugin("recordAndTuple");let r=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!1;let n=Object.create(null),o=!0,h=this.startNode();for(h.properties=[],this.next();!this.match(t);){if(o)o=!1;else if(this.expect(12),this.match(t)){this.addTrailingCommaExtraToNode(h);break}let l;e?l=this.parseBindingProperty():(l=this.parsePropertyDefinition(i),this.checkProto(l,s,n,i)),s&&!this.isObjectProperty(l)&&l.type!=="SpreadElement"&&this.raise(p.InvalidRecordProperty,l),l.shorthand&&this.addExtra(l,"shorthand",!0),h.properties.push(l)}this.next(),this.state.inFSharpPipelineDirectBody=r;let c="ObjectExpression";return e?c="ObjectPattern":s&&(c="RecordExpression"),this.finishNode(h,c)}addTrailingCommaExtraToNode(t){this.addExtra(t,"trailingComma",this.state.lastTokStartLoc.index),this.addExtra(t,"trailingCommaLoc",this.state.lastTokStartLoc,!1)}maybeAsyncOrAccessorProp(t){return!t.computed&&t.key.type==="Identifier"&&(this.isLiteralPropertyName()||this.match(0)||this.match(55))}parsePropertyDefinition(t){let e=[];if(this.match(26))for(this.hasPlugin("decorators")&&this.raise(p.UnsupportedPropertyDecorator,this.state.startLoc);this.match(26);)e.push(this.parseDecorator());let s=this.startNode(),i=!1,r=!1,n;if(this.match(21))return e.length&&this.unexpected(),this.parseSpread();e.length&&(s.decorators=e,e=[]),s.method=!1,t&&(n=this.state.startLoc);let o=this.eat(55);this.parsePropertyNamePrefixOperator(s);let h=this.state.containsEsc;if(this.parsePropertyName(s,t),!o&&!h&&this.maybeAsyncOrAccessorProp(s)){let{key:c}=s,l=c.name;l==="async"&&!this.hasPrecedingLineBreak()&&(i=!0,this.resetPreviousNodeTrailingComments(c),o=this.eat(55),this.parsePropertyName(s)),(l==="get"||l==="set")&&(r=!0,this.resetPreviousNodeTrailingComments(c),s.kind=l,this.match(55)&&(o=!0,this.raise(p.AccessorIsGenerator,this.state.curPosition(),{kind:l}),this.next()),this.parsePropertyName(s))}return this.parseObjPropValue(s,n,o,i,!1,r,t)}getGetterSetterExpectedParamCount(t){return t.kind==="get"?0:1}getObjectOrClassMethodParams(t){return t.params}checkGetterSetterParams(t){var e;let s=this.getGetterSetterExpectedParamCount(t),i=this.getObjectOrClassMethodParams(t);i.length!==s&&this.raise(t.kind==="get"?p.BadGetterArity:p.BadSetterArity,t),t.kind==="set"&&((e=i[i.length-1])==null?void 0:e.type)==="RestElement"&&this.raise(p.BadSetterRestParameter,t)}parseObjectMethod(t,e,s,i,r){if(r){let n=this.parseMethod(t,e,!1,!1,!1,"ObjectMethod");return this.checkGetterSetterParams(n),n}if(s||e||this.match(10))return i&&this.unexpected(),t.kind="method",t.method=!0,this.parseMethod(t,e,s,!1,!1,"ObjectMethod")}parseObjectProperty(t,e,s,i){if(t.shorthand=!1,this.eat(14))return t.value=s?this.parseMaybeDefault(this.state.startLoc):this.parseMaybeAssignAllowIn(i),this.finishNode(t,"ObjectProperty");if(!t.computed&&t.key.type==="Identifier"){if(this.checkReservedWord(t.key.name,t.key.loc.start,!0,!1),s)t.value=this.parseMaybeDefault(e,$(t.key));else if(this.match(29)){let r=this.state.startLoc;i!=null?i.shorthandAssignLoc===null&&(i.shorthandAssignLoc=r):this.raise(p.InvalidCoverInitializedName,r),t.value=this.parseMaybeDefault(e,$(t.key))}else t.value=$(t.key);return t.shorthand=!0,this.finishNode(t,"ObjectProperty")}}parseObjPropValue(t,e,s,i,r,n,o){let h=this.parseObjectMethod(t,s,i,r,n)||this.parseObjectProperty(t,e,r,o);return h||this.unexpected(),h}parsePropertyName(t,e){if(this.eat(0))t.computed=!0,t.key=this.parseMaybeAssignAllowIn(),this.expect(3);else{let{type:s,value:i}=this.state,r;if(M(s))r=this.parseIdent
`)return t-2;if(i===`
`||i==="\r"||i==="\u2028"||i==="\u2029")return t-1}else{if(i==="\r"&&a.charAt(t+1)===`
`)return t+2;if(i===`
`||i==="\r"||i==="\u2028"||i==="\u2029")return t+1}return t}var us=mr;function yr(a,t){return t===!1?!1:a.charAt(t)==="/"&&a.charAt(t+1)==="/"?cs(a,t):t}var fs=yr;function xr(a,t){let e=null,s=t;for(;s!==e;)e=s,s=ls(a,s),s=ps(a,s),s=fs(a,s),s=us(a,s);return s}var ds=xr;function Pr(a){let t=[];for(let e of a)try{return e()}catch(s){t.push(s)}throw Object.assign(new Error("All combinations failed"),{errors:t})}var ms=Pr;function gr(a){if(!a.startsWith("#!"))return"";let t=a.indexOf(`
`);return t===-1?a:a.slice(0,t)}var Oe=gr;var Tr=(a,t,e)=>{if(!(a&&t==null))return Array.isArray(t)||typeof t=="string"?t[e<0?t.length+e:e]:t.at(e)},St=Tr;function br(a){return Array.isArray(a)&&a.length>0}var Pe=br;function D(a){var s,i,r;let t=((s=a.range)==null?void 0:s[0])??a.start,e=(r=((i=a.declaration)==null?void 0:i.decorators)??a.decorators)==null?void 0:r[0];return e?Math.min(D(e),t):t}function B(a){var t;return((t=a.range)==null?void 0:t[1])??a.end}function Ar(a){let t=new Set(a);return e=>t.has(e==null?void 0:e.type)}var ys=Ar;var Sr=ys(["Block","CommentBlock","MultiLine"]),ge=Sr;function wr(a){let t=`*${a.value}*`.split(`
`);return t.length>1&&t.every(e=>e.trimStart()[0]==="*")}var wt=wr;function Cr(a){return ge(a)&&a.value[0]==="*"&&/@(?:type|satisfies)\b/u.test(a.value)}var xs=Cr;var Te=null;function be(a){if(Te!==null&&typeof Te.property){let t=Te;return Te=be.prototype=null,t}return Te=be.prototype=a??Object.create(null),new be}var Er=10;for(let a=0;a<=Er;a++)be();function Ct(a){return be(a)}function Ir(a,t="type"){Ct(a);function e(s){let i=s[t],r=a[i];if(!Array.isArray(r))throw Object.assign(new Error(`Missing visitor keys for '${i}'.`),{node:s});return r}return e}var Ps=Ir;var gs={ArrayExpression:["elements"],AssignmentExpression:["left","right"],BinaryExpression:["left","right"],InterpreterDirective:[],Directive:["value"],DirectiveLiteral:[],BlockStatement:["directives","body"],BreakStatement:["label"],CallExpression:["callee","arguments","typeParameters","typeArguments"],CatchClause:["param","body"],ConditionalExpression:["test","consequent","alternate"],ContinueStatement:["label"],DebuggerStatement:[],DoWhileStatement:["test","body"],EmptyStatement:[],ExpressionStatement:["expression"],File:["program"],ForInStatement:["left","right","body"],ForStatement:["init","test","update","body"],FunctionDeclaration:["id","params","body","returnType","typeParameters","predicate"],FunctionExpression:["id","params","body","returnType","typeParameters"],Identifier:["typeAnnotation","decorators"],IfStatement:["test","consequent","alternate"],LabeledStatement:["label","body"],StringLiteral:[],NumericLiteral:[],NullLiteral:[],BooleanLiteral:[],RegExpLiteral:[],LogicalExpression:["left","right"],MemberExpression:["object","property"],NewExpression:["callee","arguments","typeParameters","typeArguments"],Program:["directives","body"],ObjectExpression:["properties"],ObjectMethod:["key","params","body","decorators","returnType","typeParameters"],ObjectProperty:["key","value","decorators"],RestElement:["argument","typeAnnotation","decorators"],ReturnStatement:["argument"],SequenceExpression:["expressions"],ParenthesizedExpression:["expression"],SwitchCase:["test","consequent"],SwitchStatement:["discriminant","cases"],ThisExpression:[],ThrowStatement:["argument"],TryStatement:["block","handler","finalizer"],UnaryExpression:["argument"],UpdateExpression:["argument"],VariableDeclaration:["declarations"],VariableDeclarator:["id","init"],WhileStatement:["test","body"],WithStatement:["object","body"],AssignmentPattern:["left","right","decorators","typeAnnotation"],ArrayPattern:["elements","typeAnnotation","decorators"],ArrowFunctionExpression:["params","body","returnType","typeParameters","predicate"],ClassBody:["body"],ClassExpression:["id","body","superClass","mixins","typeParameters","superTypeParameters","implements","decorators","superTypeArguments"],ClassDeclaration:["id","body","superClass","mixins","typeParameters","superTypeParameters","implements","decorators","superTypeArguments"],ExportAllDeclaration:["source","attributes","exported"],ExportDefaultDeclaration:["declaration"],ExportNamedDeclaration:["declaration","specifiers","source","attributes"],ExportSpecifier:["local","exported"],ForOfStatement:["left","right","body"],ImportDeclaration:["specifiers","source","attributes"],ImportDefaultSpecifier:["local"],ImportNamespaceSpecifier:["local"],ImportSpecifier:["local","imported"],ImportExpression:["source","options","attributes"],MetaProperty:["meta","property"],ClassMethod:["key","params","body","decorators","returnType","typeParameters"],ObjectPattern:["properties","typeAnnotation","decorators"],SpreadElement:["argument"],Super:[],TaggedTemplateExpression:["tag","quasi","typeParameters","typeArguments"],TemplateElement:[],TemplateLiteral:["quasis","expressions"],YieldExpression:["argument"],AwaitExpression:["argument"],Import:[],BigIntLiteral:[],ExportNamespaceSpecifier:["exported"],OptionalMemberExpression:["object","property"],OptionalCallExpression:["callee","arguments","typeParameters","typeArguments"],ClassProperty:["key","value","typeAnnotation","decorators","variance"],ClassAccessorProperty:["key","value","typeAnnotation","decorators"],Cl
`;a=ie(!1,a.replace(Or,"").replace(Mr,""),Ur,"$1");let e="";for(;e!==a;)e=a,a=ie(!1,a,Rr,`${t}$1 $2${t}`);a=a.replace(Ss,"").trimEnd();let s=Object.create(null),i=ie(!1,a,ws,"").replace(Ss,"").trimEnd(),r;for(;r=ws.exec(a);){let n=ie(!1,r[2],Br,"");if(typeof s[r[1]]=="string"||Array.isArray(s[r[1]])){let o=s[r[1]];s[r[1]]=[..._r,...Array.isArray(o)?o:[o],n]}else s[r[1]]=n}return{comments:i,pragmas:s}}function jr(a){let t=Oe(a);t&&(a=a.slice(t.length+1));let e=Cs(a),{pragmas:s,comments:i}=Es(e);return{shebang:t,text:a,pragmas:s,comments:i}}function Is(a){let{pragmas:t}=jr(a);return Object.prototype.hasOwnProperty.call(t,"prettier")||Object.prototype.hasOwnProperty.call(t,"format")}function $r(a){return a=typeof a=="function"?{parse:a}:a,{astFormat:"estree",hasPragma:Is,locStart:D,locEnd:B,...a}}var G=$r;function Vr(a){let{filepath:t}=a;if(t){if(t=t.toLowerCase(),t.endsWith(".cjs"))return"script";if(t.endsWith(".mjs"))return"module"}}var Ns=Vr;function qr(a,t){let{type:e="JsExpressionRoot",rootMarker:s,text:i}=t,{tokens:r,comments:n}=a;return delete a.tokens,delete a.comments,{tokens:r,comments:n,type:e,node:a,range:[0,i.length],rootMarker:s}}var Ue=qr;var re=a=>G(Jr(a)),zr={sourceType:"module",allowImportExportEverywhere:!0,allowReturnOutsideFunction:!0,allowNewTargetOutsideFunction:!0,allowSuperOutsideMethod:!0,allowUndeclaredExports:!0,errorRecovery:!0,createParenthesizedExpressions:!0,createImportExpressions:!0,plugins:["doExpressions","exportDefaultFrom","functionBind","functionSent","throwExpressions","partialApplication","decorators","decimal","moduleBlocks","asyncDoExpressions","destructuringPrivate","decoratorAutoAccessors","importReflection","explicitResourceManagement",["importAttributes",{deprecatedAssertSyntax:!0}],"sourcePhaseImports","deferredImportEvaluation",["optionalChainingAssign",{version:"2023-07"}],"recordAndTuple"],tokens:!0,ranges:!0},ks="v8intrinsic",vs=[["pipelineOperator",{proposal:"hack",topicToken:"%"}],["pipelineOperator",{proposal:"minimal"}],["pipelineOperator",{proposal:"fsharp"}]],V=(a,t=zr)=>({...t,plugins:[...t.plugins,...a]}),Kr=/@(?:no)?flow\b/u;function Hr(a,t){var i;if((i=t.filepath)!=null&&i.endsWith(".js.flow"))return!0;let e=Oe(a);e&&(a=a.slice(e.length));let s=ds(a,0);return s!==!1&&(a=a.slice(0,s)),Kr.test(a)}function Wr(a,t,e){let s=a(t,e),i=s.errors.find(r=>!Xr.has(r.reasonCode));if(i)throw i;return s}function Jr({isExpression:a=!1,optionsCombinations:t}){return(e,s={})=>{if((s.parser==="babel"||s.parser==="__babel_estree")&&Hr(e,s))return s.parser="babel-flow",Bs.parse(e,s);let i=t;(s.__babelSourceType??Ns(s))==="script"&&(i=i.map(c=>({...c,sourceType:"script"})));let n=/%[A-Z]/u.test(e);e.includes("|>")?i=(n?[...vs,ks]:vs).flatMap(l=>i.map(u=>V([l],u))):n&&(i=i.map(c=>V([ks],c)));let o=a?_e.parseExpression:_e.parse,h;try{h=ms(i.map(c=>()=>Wr(o,e,c)))}catch({errors:[c]}){throw Re(c)}return a&&(h=Ue(h,{text:e,rootMarker:s.rootMarker})),As(h,{parser:"babel",text:e})}}var Xr=new Set(["StrictNumericEscape","StrictWith","StrictOctalLiteral","StrictDelete","StrictEvalArguments","StrictEvalArgumentsBinding","StrictFunction","ForInOfLoopInitializer","EmptyTypeArguments","EmptyTypeParameters","ConstructorHasTypeParameters","UnsupportedParameterPropertyKind","DecoratorExportClass","ParamDupe","InvalidDecimal","RestTrailingComma","UnsupportedParameterDecorator","UnterminatedJsxContent","UnexpectedReservedWord","ModuleAttributesWithDuplicateKeys","LineTerminatorBeforeArrow","InvalidEscapeSequenceTemplate","NonAbstractClassHasAbstractMethod","OptionalTypeBeforeRequired","PatternIsOptional","OptionalBindingPattern","DeclareClassFieldHasInitializer","TypeImportCannotSpecifyDefaultAndNamed","ConstructorClassField","VarRedeclaration","InvalidPrivateFieldResolution","DuplicateExport"]),Fs=[V(["jsx"])],Ls=re({optionsCombinations:Fs}),Ds=re({optionsCombinations:[V(["jsx","typescript"]),V(["typescript"])]}),Ms=re({isExpression:!0,optionsCombinations:[V(["jsx"])]}),Os=re({isExpression:!0,optionsCombinations:[V(["typescript"])]}),Bs=re({optionsCombinations:[V(["jsx",["flow",{all:!0,enums:!0}],"fl