From 67f122d70453bd62b00cfe25b3c68e5f9936fc2c Mon Sep 17 00:00:00 2001 From: easylogic Date: Sun, 13 Dec 2020 00:12:18 +0900 Subject: [PATCH] support to snap in LayerAppendView --- dist/editor.js | 6 +- dist/main.css | 2 +- docs/index.html | 2 +- ...2f448d.js => main.b47a51015045c6a9b0f6.js} | 6 +- ...dc56.css => main.cb6848d5f7a9a936e342.css} | 2 +- docs/service-worker.js | 2 +- src/commands/newComponent.js | 10 ++ src/commands/updatePathItem.js | 48 +++++---- src/manager/SnapManager.js | 13 +-- .../HTMLRenderer/SVGTextPathRender.js | 19 ++-- src/scss/csseditor/layer-add-view.scss | 14 +++ src/scss/csseditor/path-editor-view.scss | 2 +- src/ui/view-items/LayerAppendView.js | 98 +++++++++++++++++-- src/ui/view-items/PathEditorView.js | 18 +--- src/ui/view-items/SelectionToolView.js | 3 + 15 files changed, 170 insertions(+), 75 deletions(-) rename docs/{main.5c48347fd36f092f448d.js => main.b47a51015045c6a9b0f6.js} (56%) rename docs/{main.b135e85657d1655edc56.css => main.cb6848d5f7a9a936e342.css} (90%) diff --git a/dist/editor.js b/dist/editor.js index 29da3a9d8..1e680f3ce 100644 --- a/dist/editor.js +++ b/dist/editor.js @@ -1,11 +1,11 @@ -!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.EasylogicStudio=t():e.EasylogicStudio=t()}(window,(function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=413)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r={react:!0,assertNode:!0,createTypeAnnotationBasedOnTypeof:!0,createUnionTypeAnnotation:!0,cloneNode:!0,clone:!0,cloneDeep:!0,cloneWithoutLoc:!0,addComment:!0,addComments:!0,inheritInnerComments:!0,inheritLeadingComments:!0,inheritsComments:!0,inheritTrailingComments:!0,removeComments:!0,ensureBlock:!0,toBindingIdentifierName:!0,toBlock:!0,toComputedKey:!0,toExpression:!0,toIdentifier:!0,toKeyAlias:!0,toSequenceExpression:!0,toStatement:!0,valueToNode:!0,appendToMemberExpression:!0,inherits:!0,prependToMemberExpression:!0,removeProperties:!0,removePropertiesDeep:!0,removeTypeDuplicates:!0,getBindingIdentifiers:!0,getOuterBindingIdentifiers:!0,traverse:!0,traverseFast:!0,shallowEqual:!0,is:!0,isBinding:!0,isBlockScoped:!0,isImmutable:!0,isLet:!0,isNode:!0,isNodesEquivalent:!0,isPlaceholderType:!0,isReferenced:!0,isScope:!0,isSpecifierDefault:!0,isType:!0,isValidES3Identifier:!0,isValidIdentifier:!0,isVar:!0,matchesPattern:!0,validate:!0,buildMatchMemberExpression:!0};Object.defineProperty(t,"assertNode",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"createTypeAnnotationBasedOnTypeof",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"createUnionTypeAnnotation",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"cloneNode",{enumerable:!0,get:function(){return p.default}}),Object.defineProperty(t,"clone",{enumerable:!0,get:function(){return h.default}}),Object.defineProperty(t,"cloneDeep",{enumerable:!0,get:function(){return d.default}}),Object.defineProperty(t,"cloneWithoutLoc",{enumerable:!0,get:function(){return y.default}}),Object.defineProperty(t,"addComment",{enumerable:!0,get:function(){return m.default}}),Object.defineProperty(t,"addComments",{enumerable:!0,get:function(){return v.default}}),Object.defineProperty(t,"inheritInnerComments",{enumerable:!0,get:function(){return b.default}}),Object.defineProperty(t,"inheritLeadingComments",{enumerable:!0,get:function(){return g.default}}),Object.defineProperty(t,"inheritsComments",{enumerable:!0,get:function(){return w.default}}),Object.defineProperty(t,"inheritTrailingComments",{enumerable:!0,get:function(){return S.default}}),Object.defineProperty(t,"removeComments",{enumerable:!0,get:function(){return O.default}}),Object.defineProperty(t,"ensureBlock",{enumerable:!0,get:function(){return x.default}}),Object.defineProperty(t,"toBindingIdentifierName",{enumerable:!0,get:function(){return E.default}}),Object.defineProperty(t,"toBlock",{enumerable:!0,get:function(){return j.default}}),Object.defineProperty(t,"toComputedKey",{enumerable:!0,get:function(){return T.default}}),Object.defineProperty(t,"toExpression",{enumerable:!0,get:function(){return C.default}}),Object.defineProperty(t,"toIdentifier",{enumerable:!0,get:function(){return _.default}}),Object.defineProperty(t,"toKeyAlias",{enumerable:!0,get:function(){return A.default}}),Object.defineProperty(t,"toSequenceExpression",{enumerable:!0,get:function(){return D.default}}),Object.defineProperty(t,"toStatement",{enumerable:!0,get:function(){return I.default}}),Object.defineProperty(t,"valueToNode",{enumerable:!0,get:function(){return F.default}}),Object.defineProperty(t,"appendToMemberExpression",{enumerable:!0,get:function(){return M.default}}),Object.defineProperty(t,"inherits",{enumerable:!0,get:function(){return R.default}}),Object.defineProperty(t,"prependToMemberExpression",{enumerable:!0,get:function(){return L.default}}),Object.defineProperty(t,"removeProperties",{enumerable:!0,get:function(){return B.default}}),Object.defineProperty(t,"removePropertiesDeep",{enumerable:!0,get:function(){return N.default}}),Object.defineProperty(t,"removeTypeDuplicates",{enumerable:!0,get:function(){return V.default}}),Object.defineProperty(t,"getBindingIdentifiers",{enumerable:!0,get:function(){return z.default}}),Object.defineProperty(t,"getOuterBindingIdentifiers",{enumerable:!0,get:function(){return G.default}}),Object.defineProperty(t,"traverse",{enumerable:!0,get:function(){return H.default}}),Object.defineProperty(t,"traverseFast",{enumerable:!0,get:function(){return U.default}}),Object.defineProperty(t,"shallowEqual",{enumerable:!0,get:function(){return Y.default}}),Object.defineProperty(t,"is",{enumerable:!0,get:function(){return W.default}}),Object.defineProperty(t,"isBinding",{enumerable:!0,get:function(){return X.default}}),Object.defineProperty(t,"isBlockScoped",{enumerable:!0,get:function(){return K.default}}),Object.defineProperty(t,"isImmutable",{enumerable:!0,get:function(){return q.default}}),Object.defineProperty(t,"isLet",{enumerable:!0,get:function(){return J.default}}),Object.defineProperty(t,"isNode",{enumerable:!0,get:function(){return Z.default}}),Object.defineProperty(t,"isNodesEquivalent",{enumerable:!0,get:function(){return Q.default}}),Object.defineProperty(t,"isPlaceholderType",{enumerable:!0,get:function(){return ee.default}}),Object.defineProperty(t,"isReferenced",{enumerable:!0,get:function(){return te.default}}),Object.defineProperty(t,"isScope",{enumerable:!0,get:function(){return ne.default}}),Object.defineProperty(t,"isSpecifierDefault",{enumerable:!0,get:function(){return re.default}}),Object.defineProperty(t,"isType",{enumerable:!0,get:function(){return ie.default}}),Object.defineProperty(t,"isValidES3Identifier",{enumerable:!0,get:function(){return oe.default}}),Object.defineProperty(t,"isValidIdentifier",{enumerable:!0,get:function(){return ae.default}}),Object.defineProperty(t,"isVar",{enumerable:!0,get:function(){return se.default}}),Object.defineProperty(t,"matchesPattern",{enumerable:!0,get:function(){return ue.default}}),Object.defineProperty(t,"validate",{enumerable:!0,get:function(){return ce.default}}),Object.defineProperty(t,"buildMatchMemberExpression",{enumerable:!0,get:function(){return le.default}}),t.react=void 0;var i=pe(n(161)),o=pe(n(162)),a=pe(n(163)),s=pe(n(234)),u=n(235);Object.keys(u).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(r,e)||Object.defineProperty(t,e,{enumerable:!0,get:function(){return u[e]}}))}));var c=pe(n(236)),l=pe(n(237)),f=n(3);Object.keys(f).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(r,e)||Object.defineProperty(t,e,{enumerable:!0,get:function(){return f[e]}}))}));var p=pe(n(22)),h=pe(n(106)),d=pe(n(238)),y=pe(n(239)),m=pe(n(240)),v=pe(n(107)),b=pe(n(108)),g=pe(n(112)),w=pe(n(113)),S=pe(n(114)),O=pe(n(252)),P=n(253);Object.keys(P).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(r,e)||Object.defineProperty(t,e,{enumerable:!0,get:function(){return P[e]}}))}));var k=n(14);Object.keys(k).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(r,e)||Object.defineProperty(t,e,{enumerable:!0,get:function(){return k[e]}}))}));var x=pe(n(254)),E=pe(n(255)),j=pe(n(115)),T=pe(n(256)),C=pe(n(257)),_=pe(n(116)),A=pe(n(258)),D=pe(n(259)),I=pe(n(261)),F=pe(n(262)),$=n(2);Object.keys($).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(r,e)||Object.defineProperty(t,e,{enumerable:!0,get:function(){return $[e]}}))}));var M=pe(n(266)),R=pe(n(267)),L=pe(n(268)),B=pe(n(119)),N=pe(n(117)),V=pe(n(105)),z=pe(n(34)),G=pe(n(269)),H=pe(n(270)),U=pe(n(118)),Y=pe(n(45)),W=pe(n(61)),X=pe(n(271)),K=pe(n(272)),q=pe(n(273)),J=pe(n(120)),Z=pe(n(104)),Q=pe(n(274)),ee=pe(n(102)),te=pe(n(275)),ne=pe(n(276)),re=pe(n(277)),ie=pe(n(62)),oe=pe(n(278)),ae=pe(n(21)),se=pe(n(279)),ue=pe(n(82)),ce=pe(n(63)),le=pe(n(81)),fe=n(1);function pe(e){return e&&e.__esModule?e:{default:e}}Object.keys(fe).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(r,e)||Object.defineProperty(t,e,{enumerable:!0,get:function(){return fe[e]}}))}));const he={isReactComponent:i.default,isCompatTag:o.default,buildChildren:a.default};t.react=he},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isArrayExpression=function(e,t){if(!e)return!1;if("ArrayExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isAssignmentExpression=function(e,t){if(!e)return!1;if("AssignmentExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isBinaryExpression=function(e,t){if(!e)return!1;if("BinaryExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isInterpreterDirective=function(e,t){if(!e)return!1;if("InterpreterDirective"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDirective=function(e,t){if(!e)return!1;if("Directive"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDirectiveLiteral=function(e,t){if(!e)return!1;if("DirectiveLiteral"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isBlockStatement=function(e,t){if(!e)return!1;if("BlockStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isBreakStatement=function(e,t){if(!e)return!1;if("BreakStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isCallExpression=function(e,t){if(!e)return!1;if("CallExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isCatchClause=function(e,t){if(!e)return!1;if("CatchClause"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isConditionalExpression=function(e,t){if(!e)return!1;if("ConditionalExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isContinueStatement=function(e,t){if(!e)return!1;if("ContinueStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDebuggerStatement=function(e,t){if(!e)return!1;if("DebuggerStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDoWhileStatement=function(e,t){if(!e)return!1;if("DoWhileStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isEmptyStatement=function(e,t){if(!e)return!1;if("EmptyStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isExpressionStatement=function(e,t){if(!e)return!1;if("ExpressionStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isFile=function(e,t){if(!e)return!1;if("File"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isForInStatement=function(e,t){if(!e)return!1;if("ForInStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isForStatement=function(e,t){if(!e)return!1;if("ForStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isFunctionDeclaration=function(e,t){if(!e)return!1;if("FunctionDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isFunctionExpression=function(e,t){if(!e)return!1;if("FunctionExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isIdentifier=function(e,t){if(!e)return!1;if("Identifier"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isIfStatement=function(e,t){if(!e)return!1;if("IfStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isLabeledStatement=function(e,t){if(!e)return!1;if("LabeledStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isStringLiteral=function(e,t){if(!e)return!1;if("StringLiteral"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isNumericLiteral=function(e,t){if(!e)return!1;if("NumericLiteral"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isNullLiteral=function(e,t){if(!e)return!1;if("NullLiteral"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isBooleanLiteral=function(e,t){if(!e)return!1;if("BooleanLiteral"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isRegExpLiteral=function(e,t){if(!e)return!1;if("RegExpLiteral"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isLogicalExpression=function(e,t){if(!e)return!1;if("LogicalExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isMemberExpression=function(e,t){if(!e)return!1;if("MemberExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isNewExpression=function(e,t){if(!e)return!1;if("NewExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isProgram=function(e,t){if(!e)return!1;if("Program"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isObjectExpression=function(e,t){if(!e)return!1;if("ObjectExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isObjectMethod=function(e,t){if(!e)return!1;if("ObjectMethod"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isObjectProperty=function(e,t){if(!e)return!1;if("ObjectProperty"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isRestElement=function(e,t){if(!e)return!1;if("RestElement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isReturnStatement=function(e,t){if(!e)return!1;if("ReturnStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isSequenceExpression=function(e,t){if(!e)return!1;if("SequenceExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isParenthesizedExpression=function(e,t){if(!e)return!1;if("ParenthesizedExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isSwitchCase=function(e,t){if(!e)return!1;if("SwitchCase"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isSwitchStatement=function(e,t){if(!e)return!1;if("SwitchStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isThisExpression=function(e,t){if(!e)return!1;if("ThisExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isThrowStatement=function(e,t){if(!e)return!1;if("ThrowStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTryStatement=function(e,t){if(!e)return!1;if("TryStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isUnaryExpression=function(e,t){if(!e)return!1;if("UnaryExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isUpdateExpression=function(e,t){if(!e)return!1;if("UpdateExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isVariableDeclaration=function(e,t){if(!e)return!1;if("VariableDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isVariableDeclarator=function(e,t){if(!e)return!1;if("VariableDeclarator"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isWhileStatement=function(e,t){if(!e)return!1;if("WhileStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isWithStatement=function(e,t){if(!e)return!1;if("WithStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isAssignmentPattern=function(e,t){if(!e)return!1;if("AssignmentPattern"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isArrayPattern=function(e,t){if(!e)return!1;if("ArrayPattern"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isArrowFunctionExpression=function(e,t){if(!e)return!1;if("ArrowFunctionExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isClassBody=function(e,t){if(!e)return!1;if("ClassBody"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isClassDeclaration=function(e,t){if(!e)return!1;if("ClassDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isClassExpression=function(e,t){if(!e)return!1;if("ClassExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isExportAllDeclaration=function(e,t){if(!e)return!1;if("ExportAllDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isExportDefaultDeclaration=function(e,t){if(!e)return!1;if("ExportDefaultDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isExportNamedDeclaration=function(e,t){if(!e)return!1;if("ExportNamedDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isExportSpecifier=function(e,t){if(!e)return!1;if("ExportSpecifier"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isForOfStatement=function(e,t){if(!e)return!1;if("ForOfStatement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isImportDeclaration=function(e,t){if(!e)return!1;if("ImportDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isImportDefaultSpecifier=function(e,t){if(!e)return!1;if("ImportDefaultSpecifier"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isImportNamespaceSpecifier=function(e,t){if(!e)return!1;if("ImportNamespaceSpecifier"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isImportSpecifier=function(e,t){if(!e)return!1;if("ImportSpecifier"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isMetaProperty=function(e,t){if(!e)return!1;if("MetaProperty"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isClassMethod=function(e,t){if(!e)return!1;if("ClassMethod"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isObjectPattern=function(e,t){if(!e)return!1;if("ObjectPattern"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isSpreadElement=function(e,t){if(!e)return!1;if("SpreadElement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isSuper=function(e,t){if(!e)return!1;if("Super"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTaggedTemplateExpression=function(e,t){if(!e)return!1;if("TaggedTemplateExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTemplateElement=function(e,t){if(!e)return!1;if("TemplateElement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTemplateLiteral=function(e,t){if(!e)return!1;if("TemplateLiteral"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isYieldExpression=function(e,t){if(!e)return!1;if("YieldExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isAnyTypeAnnotation=function(e,t){if(!e)return!1;if("AnyTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isArrayTypeAnnotation=function(e,t){if(!e)return!1;if("ArrayTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isBooleanTypeAnnotation=function(e,t){if(!e)return!1;if("BooleanTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isBooleanLiteralTypeAnnotation=function(e,t){if(!e)return!1;if("BooleanLiteralTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isNullLiteralTypeAnnotation=function(e,t){if(!e)return!1;if("NullLiteralTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isClassImplements=function(e,t){if(!e)return!1;if("ClassImplements"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclareClass=function(e,t){if(!e)return!1;if("DeclareClass"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclareFunction=function(e,t){if(!e)return!1;if("DeclareFunction"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclareInterface=function(e,t){if(!e)return!1;if("DeclareInterface"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclareModule=function(e,t){if(!e)return!1;if("DeclareModule"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclareModuleExports=function(e,t){if(!e)return!1;if("DeclareModuleExports"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclareTypeAlias=function(e,t){if(!e)return!1;if("DeclareTypeAlias"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclareOpaqueType=function(e,t){if(!e)return!1;if("DeclareOpaqueType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclareVariable=function(e,t){if(!e)return!1;if("DeclareVariable"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclareExportDeclaration=function(e,t){if(!e)return!1;if("DeclareExportDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclareExportAllDeclaration=function(e,t){if(!e)return!1;if("DeclareExportAllDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclaredPredicate=function(e,t){if(!e)return!1;if("DeclaredPredicate"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isExistsTypeAnnotation=function(e,t){if(!e)return!1;if("ExistsTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isFunctionTypeAnnotation=function(e,t){if(!e)return!1;if("FunctionTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isFunctionTypeParam=function(e,t){if(!e)return!1;if("FunctionTypeParam"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isGenericTypeAnnotation=function(e,t){if(!e)return!1;if("GenericTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isInferredPredicate=function(e,t){if(!e)return!1;if("InferredPredicate"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isInterfaceExtends=function(e,t){if(!e)return!1;if("InterfaceExtends"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isInterfaceDeclaration=function(e,t){if(!e)return!1;if("InterfaceDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isInterfaceTypeAnnotation=function(e,t){if(!e)return!1;if("InterfaceTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isIntersectionTypeAnnotation=function(e,t){if(!e)return!1;if("IntersectionTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isMixedTypeAnnotation=function(e,t){if(!e)return!1;if("MixedTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isEmptyTypeAnnotation=function(e,t){if(!e)return!1;if("EmptyTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isNullableTypeAnnotation=function(e,t){if(!e)return!1;if("NullableTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isNumberLiteralTypeAnnotation=function(e,t){if(!e)return!1;if("NumberLiteralTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isNumberTypeAnnotation=function(e,t){if(!e)return!1;if("NumberTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isObjectTypeAnnotation=function(e,t){if(!e)return!1;if("ObjectTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isObjectTypeInternalSlot=function(e,t){if(!e)return!1;if("ObjectTypeInternalSlot"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isObjectTypeCallProperty=function(e,t){if(!e)return!1;if("ObjectTypeCallProperty"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isObjectTypeIndexer=function(e,t){if(!e)return!1;if("ObjectTypeIndexer"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isObjectTypeProperty=function(e,t){if(!e)return!1;if("ObjectTypeProperty"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isObjectTypeSpreadProperty=function(e,t){if(!e)return!1;if("ObjectTypeSpreadProperty"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isOpaqueType=function(e,t){if(!e)return!1;if("OpaqueType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isQualifiedTypeIdentifier=function(e,t){if(!e)return!1;if("QualifiedTypeIdentifier"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isStringLiteralTypeAnnotation=function(e,t){if(!e)return!1;if("StringLiteralTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isStringTypeAnnotation=function(e,t){if(!e)return!1;if("StringTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isThisTypeAnnotation=function(e,t){if(!e)return!1;if("ThisTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTupleTypeAnnotation=function(e,t){if(!e)return!1;if("TupleTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTypeofTypeAnnotation=function(e,t){if(!e)return!1;if("TypeofTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTypeAlias=function(e,t){if(!e)return!1;if("TypeAlias"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTypeAnnotation=function(e,t){if(!e)return!1;if("TypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTypeCastExpression=function(e,t){if(!e)return!1;if("TypeCastExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTypeParameter=function(e,t){if(!e)return!1;if("TypeParameter"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTypeParameterDeclaration=function(e,t){if(!e)return!1;if("TypeParameterDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTypeParameterInstantiation=function(e,t){if(!e)return!1;if("TypeParameterInstantiation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isUnionTypeAnnotation=function(e,t){if(!e)return!1;if("UnionTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isVariance=function(e,t){if(!e)return!1;if("Variance"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isVoidTypeAnnotation=function(e,t){if(!e)return!1;if("VoidTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isEnumDeclaration=function(e,t){if(!e)return!1;if("EnumDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isEnumBooleanBody=function(e,t){if(!e)return!1;if("EnumBooleanBody"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isEnumNumberBody=function(e,t){if(!e)return!1;if("EnumNumberBody"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isEnumStringBody=function(e,t){if(!e)return!1;if("EnumStringBody"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isEnumSymbolBody=function(e,t){if(!e)return!1;if("EnumSymbolBody"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isEnumBooleanMember=function(e,t){if(!e)return!1;if("EnumBooleanMember"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isEnumNumberMember=function(e,t){if(!e)return!1;if("EnumNumberMember"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isEnumStringMember=function(e,t){if(!e)return!1;if("EnumStringMember"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isEnumDefaultedMember=function(e,t){if(!e)return!1;if("EnumDefaultedMember"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXAttribute=function(e,t){if(!e)return!1;if("JSXAttribute"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXClosingElement=function(e,t){if(!e)return!1;if("JSXClosingElement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXElement=function(e,t){if(!e)return!1;if("JSXElement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXEmptyExpression=function(e,t){if(!e)return!1;if("JSXEmptyExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXExpressionContainer=function(e,t){if(!e)return!1;if("JSXExpressionContainer"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXSpreadChild=function(e,t){if(!e)return!1;if("JSXSpreadChild"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXIdentifier=function(e,t){if(!e)return!1;if("JSXIdentifier"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXMemberExpression=function(e,t){if(!e)return!1;if("JSXMemberExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXNamespacedName=function(e,t){if(!e)return!1;if("JSXNamespacedName"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXOpeningElement=function(e,t){if(!e)return!1;if("JSXOpeningElement"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXSpreadAttribute=function(e,t){if(!e)return!1;if("JSXSpreadAttribute"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXText=function(e,t){if(!e)return!1;if("JSXText"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXFragment=function(e,t){if(!e)return!1;if("JSXFragment"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXOpeningFragment=function(e,t){if(!e)return!1;if("JSXOpeningFragment"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isJSXClosingFragment=function(e,t){if(!e)return!1;if("JSXClosingFragment"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isNoop=function(e,t){if(!e)return!1;if("Noop"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isPlaceholder=function(e,t){if(!e)return!1;if("Placeholder"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isV8IntrinsicIdentifier=function(e,t){if(!e)return!1;if("V8IntrinsicIdentifier"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isArgumentPlaceholder=function(e,t){if(!e)return!1;if("ArgumentPlaceholder"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isAwaitExpression=function(e,t){if(!e)return!1;if("AwaitExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isBindExpression=function(e,t){if(!e)return!1;if("BindExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isClassProperty=function(e,t){if(!e)return!1;if("ClassProperty"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isOptionalMemberExpression=function(e,t){if(!e)return!1;if("OptionalMemberExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isPipelineTopicExpression=function(e,t){if(!e)return!1;if("PipelineTopicExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isPipelineBareFunction=function(e,t){if(!e)return!1;if("PipelineBareFunction"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isPipelinePrimaryTopicReference=function(e,t){if(!e)return!1;if("PipelinePrimaryTopicReference"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isOptionalCallExpression=function(e,t){if(!e)return!1;if("OptionalCallExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isClassPrivateProperty=function(e,t){if(!e)return!1;if("ClassPrivateProperty"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isClassPrivateMethod=function(e,t){if(!e)return!1;if("ClassPrivateMethod"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isImport=function(e,t){if(!e)return!1;if("Import"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDecorator=function(e,t){if(!e)return!1;if("Decorator"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isDoExpression=function(e,t){if(!e)return!1;if("DoExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isExportDefaultSpecifier=function(e,t){if(!e)return!1;if("ExportDefaultSpecifier"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isExportNamespaceSpecifier=function(e,t){if(!e)return!1;if("ExportNamespaceSpecifier"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isPrivateName=function(e,t){if(!e)return!1;if("PrivateName"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isBigIntLiteral=function(e,t){if(!e)return!1;if("BigIntLiteral"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSParameterProperty=function(e,t){if(!e)return!1;if("TSParameterProperty"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSDeclareFunction=function(e,t){if(!e)return!1;if("TSDeclareFunction"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSDeclareMethod=function(e,t){if(!e)return!1;if("TSDeclareMethod"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSQualifiedName=function(e,t){if(!e)return!1;if("TSQualifiedName"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSCallSignatureDeclaration=function(e,t){if(!e)return!1;if("TSCallSignatureDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSConstructSignatureDeclaration=function(e,t){if(!e)return!1;if("TSConstructSignatureDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSPropertySignature=function(e,t){if(!e)return!1;if("TSPropertySignature"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSMethodSignature=function(e,t){if(!e)return!1;if("TSMethodSignature"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSIndexSignature=function(e,t){if(!e)return!1;if("TSIndexSignature"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSAnyKeyword=function(e,t){if(!e)return!1;if("TSAnyKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSBooleanKeyword=function(e,t){if(!e)return!1;if("TSBooleanKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSBigIntKeyword=function(e,t){if(!e)return!1;if("TSBigIntKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSNeverKeyword=function(e,t){if(!e)return!1;if("TSNeverKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSNullKeyword=function(e,t){if(!e)return!1;if("TSNullKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSNumberKeyword=function(e,t){if(!e)return!1;if("TSNumberKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSObjectKeyword=function(e,t){if(!e)return!1;if("TSObjectKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSStringKeyword=function(e,t){if(!e)return!1;if("TSStringKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSSymbolKeyword=function(e,t){if(!e)return!1;if("TSSymbolKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSUndefinedKeyword=function(e,t){if(!e)return!1;if("TSUndefinedKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSUnknownKeyword=function(e,t){if(!e)return!1;if("TSUnknownKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSVoidKeyword=function(e,t){if(!e)return!1;if("TSVoidKeyword"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSThisType=function(e,t){if(!e)return!1;if("TSThisType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSFunctionType=function(e,t){if(!e)return!1;if("TSFunctionType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSConstructorType=function(e,t){if(!e)return!1;if("TSConstructorType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypeReference=function(e,t){if(!e)return!1;if("TSTypeReference"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypePredicate=function(e,t){if(!e)return!1;if("TSTypePredicate"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypeQuery=function(e,t){if(!e)return!1;if("TSTypeQuery"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypeLiteral=function(e,t){if(!e)return!1;if("TSTypeLiteral"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSArrayType=function(e,t){if(!e)return!1;if("TSArrayType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTupleType=function(e,t){if(!e)return!1;if("TSTupleType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSOptionalType=function(e,t){if(!e)return!1;if("TSOptionalType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSRestType=function(e,t){if(!e)return!1;if("TSRestType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSUnionType=function(e,t){if(!e)return!1;if("TSUnionType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSIntersectionType=function(e,t){if(!e)return!1;if("TSIntersectionType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSConditionalType=function(e,t){if(!e)return!1;if("TSConditionalType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSInferType=function(e,t){if(!e)return!1;if("TSInferType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSParenthesizedType=function(e,t){if(!e)return!1;if("TSParenthesizedType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypeOperator=function(e,t){if(!e)return!1;if("TSTypeOperator"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSIndexedAccessType=function(e,t){if(!e)return!1;if("TSIndexedAccessType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSMappedType=function(e,t){if(!e)return!1;if("TSMappedType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSLiteralType=function(e,t){if(!e)return!1;if("TSLiteralType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSExpressionWithTypeArguments=function(e,t){if(!e)return!1;if("TSExpressionWithTypeArguments"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSInterfaceDeclaration=function(e,t){if(!e)return!1;if("TSInterfaceDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSInterfaceBody=function(e,t){if(!e)return!1;if("TSInterfaceBody"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypeAliasDeclaration=function(e,t){if(!e)return!1;if("TSTypeAliasDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSAsExpression=function(e,t){if(!e)return!1;if("TSAsExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypeAssertion=function(e,t){if(!e)return!1;if("TSTypeAssertion"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSEnumDeclaration=function(e,t){if(!e)return!1;if("TSEnumDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSEnumMember=function(e,t){if(!e)return!1;if("TSEnumMember"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSModuleDeclaration=function(e,t){if(!e)return!1;if("TSModuleDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSModuleBlock=function(e,t){if(!e)return!1;if("TSModuleBlock"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSImportType=function(e,t){if(!e)return!1;if("TSImportType"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSImportEqualsDeclaration=function(e,t){if(!e)return!1;if("TSImportEqualsDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSExternalModuleReference=function(e,t){if(!e)return!1;if("TSExternalModuleReference"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSNonNullExpression=function(e,t){if(!e)return!1;if("TSNonNullExpression"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSExportAssignment=function(e,t){if(!e)return!1;if("TSExportAssignment"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSNamespaceExportDeclaration=function(e,t){if(!e)return!1;if("TSNamespaceExportDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypeAnnotation=function(e,t){if(!e)return!1;if("TSTypeAnnotation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypeParameterInstantiation=function(e,t){if(!e)return!1;if("TSTypeParameterInstantiation"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypeParameterDeclaration=function(e,t){if(!e)return!1;if("TSTypeParameterDeclaration"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypeParameter=function(e,t){if(!e)return!1;if("TSTypeParameter"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isExpression=function(e,t){if(!e)return!1;const n=e.type;if("Expression"===n||"ArrayExpression"===n||"AssignmentExpression"===n||"BinaryExpression"===n||"CallExpression"===n||"ConditionalExpression"===n||"FunctionExpression"===n||"Identifier"===n||"StringLiteral"===n||"NumericLiteral"===n||"NullLiteral"===n||"BooleanLiteral"===n||"RegExpLiteral"===n||"LogicalExpression"===n||"MemberExpression"===n||"NewExpression"===n||"ObjectExpression"===n||"SequenceExpression"===n||"ParenthesizedExpression"===n||"ThisExpression"===n||"UnaryExpression"===n||"UpdateExpression"===n||"ArrowFunctionExpression"===n||"ClassExpression"===n||"MetaProperty"===n||"Super"===n||"TaggedTemplateExpression"===n||"TemplateLiteral"===n||"YieldExpression"===n||"TypeCastExpression"===n||"JSXElement"===n||"JSXFragment"===n||"AwaitExpression"===n||"BindExpression"===n||"OptionalMemberExpression"===n||"PipelinePrimaryTopicReference"===n||"OptionalCallExpression"===n||"Import"===n||"DoExpression"===n||"BigIntLiteral"===n||"TSAsExpression"===n||"TSTypeAssertion"===n||"TSNonNullExpression"===n||"Placeholder"===n&&("Expression"===e.expectedNode||"Identifier"===e.expectedNode||"StringLiteral"===e.expectedNode))return void 0===t||(0,i.default)(e,t);return!1},t.isBinary=function(e,t){if(!e)return!1;const n=e.type;if("Binary"===n||"BinaryExpression"===n||"LogicalExpression"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isScopable=function(e,t){if(!e)return!1;const n=e.type;if("Scopable"===n||"BlockStatement"===n||"CatchClause"===n||"DoWhileStatement"===n||"ForInStatement"===n||"ForStatement"===n||"FunctionDeclaration"===n||"FunctionExpression"===n||"Program"===n||"ObjectMethod"===n||"SwitchStatement"===n||"WhileStatement"===n||"ArrowFunctionExpression"===n||"ClassDeclaration"===n||"ClassExpression"===n||"ForOfStatement"===n||"ClassMethod"===n||"ClassPrivateMethod"===n||"TSModuleBlock"===n||"Placeholder"===n&&"BlockStatement"===e.expectedNode)return void 0===t||(0,i.default)(e,t);return!1},t.isBlockParent=function(e,t){if(!e)return!1;const n=e.type;if("BlockParent"===n||"BlockStatement"===n||"CatchClause"===n||"DoWhileStatement"===n||"ForInStatement"===n||"ForStatement"===n||"FunctionDeclaration"===n||"FunctionExpression"===n||"Program"===n||"ObjectMethod"===n||"SwitchStatement"===n||"WhileStatement"===n||"ArrowFunctionExpression"===n||"ForOfStatement"===n||"ClassMethod"===n||"ClassPrivateMethod"===n||"TSModuleBlock"===n||"Placeholder"===n&&"BlockStatement"===e.expectedNode)return void 0===t||(0,i.default)(e,t);return!1},t.isBlock=function(e,t){if(!e)return!1;const n=e.type;if("Block"===n||"BlockStatement"===n||"Program"===n||"TSModuleBlock"===n||"Placeholder"===n&&"BlockStatement"===e.expectedNode)return void 0===t||(0,i.default)(e,t);return!1},t.isStatement=function(e,t){if(!e)return!1;const n=e.type;if("Statement"===n||"BlockStatement"===n||"BreakStatement"===n||"ContinueStatement"===n||"DebuggerStatement"===n||"DoWhileStatement"===n||"EmptyStatement"===n||"ExpressionStatement"===n||"ForInStatement"===n||"ForStatement"===n||"FunctionDeclaration"===n||"IfStatement"===n||"LabeledStatement"===n||"ReturnStatement"===n||"SwitchStatement"===n||"ThrowStatement"===n||"TryStatement"===n||"VariableDeclaration"===n||"WhileStatement"===n||"WithStatement"===n||"ClassDeclaration"===n||"ExportAllDeclaration"===n||"ExportDefaultDeclaration"===n||"ExportNamedDeclaration"===n||"ForOfStatement"===n||"ImportDeclaration"===n||"DeclareClass"===n||"DeclareFunction"===n||"DeclareInterface"===n||"DeclareModule"===n||"DeclareModuleExports"===n||"DeclareTypeAlias"===n||"DeclareOpaqueType"===n||"DeclareVariable"===n||"DeclareExportDeclaration"===n||"DeclareExportAllDeclaration"===n||"InterfaceDeclaration"===n||"OpaqueType"===n||"TypeAlias"===n||"TSDeclareFunction"===n||"TSInterfaceDeclaration"===n||"TSTypeAliasDeclaration"===n||"TSEnumDeclaration"===n||"TSModuleDeclaration"===n||"TSImportEqualsDeclaration"===n||"TSExportAssignment"===n||"TSNamespaceExportDeclaration"===n||"Placeholder"===n&&("Statement"===e.expectedNode||"Declaration"===e.expectedNode||"BlockStatement"===e.expectedNode))return void 0===t||(0,i.default)(e,t);return!1},t.isTerminatorless=function(e,t){if(!e)return!1;const n=e.type;if("Terminatorless"===n||"BreakStatement"===n||"ContinueStatement"===n||"ReturnStatement"===n||"ThrowStatement"===n||"YieldExpression"===n||"AwaitExpression"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isCompletionStatement=function(e,t){if(!e)return!1;const n=e.type;if("CompletionStatement"===n||"BreakStatement"===n||"ContinueStatement"===n||"ReturnStatement"===n||"ThrowStatement"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isConditional=function(e,t){if(!e)return!1;const n=e.type;if("Conditional"===n||"ConditionalExpression"===n||"IfStatement"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isLoop=function(e,t){if(!e)return!1;const n=e.type;if("Loop"===n||"DoWhileStatement"===n||"ForInStatement"===n||"ForStatement"===n||"WhileStatement"===n||"ForOfStatement"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isWhile=function(e,t){if(!e)return!1;const n=e.type;if("While"===n||"DoWhileStatement"===n||"WhileStatement"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isExpressionWrapper=function(e,t){if(!e)return!1;const n=e.type;if("ExpressionWrapper"===n||"ExpressionStatement"===n||"ParenthesizedExpression"===n||"TypeCastExpression"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isFor=function(e,t){if(!e)return!1;const n=e.type;if("For"===n||"ForInStatement"===n||"ForStatement"===n||"ForOfStatement"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isForXStatement=function(e,t){if(!e)return!1;const n=e.type;if("ForXStatement"===n||"ForInStatement"===n||"ForOfStatement"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isFunction=function(e,t){if(!e)return!1;const n=e.type;if("Function"===n||"FunctionDeclaration"===n||"FunctionExpression"===n||"ObjectMethod"===n||"ArrowFunctionExpression"===n||"ClassMethod"===n||"ClassPrivateMethod"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isFunctionParent=function(e,t){if(!e)return!1;const n=e.type;if("FunctionParent"===n||"FunctionDeclaration"===n||"FunctionExpression"===n||"ObjectMethod"===n||"ArrowFunctionExpression"===n||"ClassMethod"===n||"ClassPrivateMethod"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isPureish=function(e,t){if(!e)return!1;const n=e.type;if("Pureish"===n||"FunctionDeclaration"===n||"FunctionExpression"===n||"StringLiteral"===n||"NumericLiteral"===n||"NullLiteral"===n||"BooleanLiteral"===n||"ArrowFunctionExpression"===n||"ClassDeclaration"===n||"ClassExpression"===n||"BigIntLiteral"===n||"Placeholder"===n&&"StringLiteral"===e.expectedNode)return void 0===t||(0,i.default)(e,t);return!1},t.isDeclaration=function(e,t){if(!e)return!1;const n=e.type;if("Declaration"===n||"FunctionDeclaration"===n||"VariableDeclaration"===n||"ClassDeclaration"===n||"ExportAllDeclaration"===n||"ExportDefaultDeclaration"===n||"ExportNamedDeclaration"===n||"ImportDeclaration"===n||"DeclareClass"===n||"DeclareFunction"===n||"DeclareInterface"===n||"DeclareModule"===n||"DeclareModuleExports"===n||"DeclareTypeAlias"===n||"DeclareOpaqueType"===n||"DeclareVariable"===n||"DeclareExportDeclaration"===n||"DeclareExportAllDeclaration"===n||"InterfaceDeclaration"===n||"OpaqueType"===n||"TypeAlias"===n||"TSDeclareFunction"===n||"TSInterfaceDeclaration"===n||"TSTypeAliasDeclaration"===n||"TSEnumDeclaration"===n||"TSModuleDeclaration"===n||"Placeholder"===n&&"Declaration"===e.expectedNode)return void 0===t||(0,i.default)(e,t);return!1},t.isPatternLike=function(e,t){if(!e)return!1;const n=e.type;if("PatternLike"===n||"Identifier"===n||"RestElement"===n||"AssignmentPattern"===n||"ArrayPattern"===n||"ObjectPattern"===n||"Placeholder"===n&&("Pattern"===e.expectedNode||"Identifier"===e.expectedNode))return void 0===t||(0,i.default)(e,t);return!1},t.isLVal=function(e,t){if(!e)return!1;const n=e.type;if("LVal"===n||"Identifier"===n||"MemberExpression"===n||"RestElement"===n||"AssignmentPattern"===n||"ArrayPattern"===n||"ObjectPattern"===n||"TSParameterProperty"===n||"Placeholder"===n&&("Pattern"===e.expectedNode||"Identifier"===e.expectedNode))return void 0===t||(0,i.default)(e,t);return!1},t.isTSEntityName=function(e,t){if(!e)return!1;const n=e.type;if("TSEntityName"===n||"Identifier"===n||"TSQualifiedName"===n||"Placeholder"===n&&"Identifier"===e.expectedNode)return void 0===t||(0,i.default)(e,t);return!1},t.isLiteral=function(e,t){if(!e)return!1;const n=e.type;if("Literal"===n||"StringLiteral"===n||"NumericLiteral"===n||"NullLiteral"===n||"BooleanLiteral"===n||"RegExpLiteral"===n||"TemplateLiteral"===n||"BigIntLiteral"===n||"Placeholder"===n&&"StringLiteral"===e.expectedNode)return void 0===t||(0,i.default)(e,t);return!1},t.isImmutable=function(e,t){if(!e)return!1;const n=e.type;if("Immutable"===n||"StringLiteral"===n||"NumericLiteral"===n||"NullLiteral"===n||"BooleanLiteral"===n||"JSXAttribute"===n||"JSXClosingElement"===n||"JSXElement"===n||"JSXExpressionContainer"===n||"JSXSpreadChild"===n||"JSXOpeningElement"===n||"JSXText"===n||"JSXFragment"===n||"JSXOpeningFragment"===n||"JSXClosingFragment"===n||"BigIntLiteral"===n||"Placeholder"===n&&"StringLiteral"===e.expectedNode)return void 0===t||(0,i.default)(e,t);return!1},t.isUserWhitespacable=function(e,t){if(!e)return!1;const n=e.type;if("UserWhitespacable"===n||"ObjectMethod"===n||"ObjectProperty"===n||"ObjectTypeInternalSlot"===n||"ObjectTypeCallProperty"===n||"ObjectTypeIndexer"===n||"ObjectTypeProperty"===n||"ObjectTypeSpreadProperty"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isMethod=function(e,t){if(!e)return!1;const n=e.type;if("Method"===n||"ObjectMethod"===n||"ClassMethod"===n||"ClassPrivateMethod"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isObjectMember=function(e,t){if(!e)return!1;const n=e.type;if("ObjectMember"===n||"ObjectMethod"===n||"ObjectProperty"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isProperty=function(e,t){if(!e)return!1;const n=e.type;if("Property"===n||"ObjectProperty"===n||"ClassProperty"===n||"ClassPrivateProperty"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isUnaryLike=function(e,t){if(!e)return!1;const n=e.type;if("UnaryLike"===n||"UnaryExpression"===n||"SpreadElement"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isPattern=function(e,t){if(!e)return!1;const n=e.type;if("Pattern"===n||"AssignmentPattern"===n||"ArrayPattern"===n||"ObjectPattern"===n||"Placeholder"===n&&"Pattern"===e.expectedNode)return void 0===t||(0,i.default)(e,t);return!1},t.isClass=function(e,t){if(!e)return!1;const n=e.type;if("Class"===n||"ClassDeclaration"===n||"ClassExpression"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isModuleDeclaration=function(e,t){if(!e)return!1;const n=e.type;if("ModuleDeclaration"===n||"ExportAllDeclaration"===n||"ExportDefaultDeclaration"===n||"ExportNamedDeclaration"===n||"ImportDeclaration"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isExportDeclaration=function(e,t){if(!e)return!1;const n=e.type;if("ExportDeclaration"===n||"ExportAllDeclaration"===n||"ExportDefaultDeclaration"===n||"ExportNamedDeclaration"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isModuleSpecifier=function(e,t){if(!e)return!1;const n=e.type;if("ModuleSpecifier"===n||"ExportSpecifier"===n||"ImportDefaultSpecifier"===n||"ImportNamespaceSpecifier"===n||"ImportSpecifier"===n||"ExportDefaultSpecifier"===n||"ExportNamespaceSpecifier"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isFlow=function(e,t){if(!e)return!1;const n=e.type;if("Flow"===n||"AnyTypeAnnotation"===n||"ArrayTypeAnnotation"===n||"BooleanTypeAnnotation"===n||"BooleanLiteralTypeAnnotation"===n||"NullLiteralTypeAnnotation"===n||"ClassImplements"===n||"DeclareClass"===n||"DeclareFunction"===n||"DeclareInterface"===n||"DeclareModule"===n||"DeclareModuleExports"===n||"DeclareTypeAlias"===n||"DeclareOpaqueType"===n||"DeclareVariable"===n||"DeclareExportDeclaration"===n||"DeclareExportAllDeclaration"===n||"DeclaredPredicate"===n||"ExistsTypeAnnotation"===n||"FunctionTypeAnnotation"===n||"FunctionTypeParam"===n||"GenericTypeAnnotation"===n||"InferredPredicate"===n||"InterfaceExtends"===n||"InterfaceDeclaration"===n||"InterfaceTypeAnnotation"===n||"IntersectionTypeAnnotation"===n||"MixedTypeAnnotation"===n||"EmptyTypeAnnotation"===n||"NullableTypeAnnotation"===n||"NumberLiteralTypeAnnotation"===n||"NumberTypeAnnotation"===n||"ObjectTypeAnnotation"===n||"ObjectTypeInternalSlot"===n||"ObjectTypeCallProperty"===n||"ObjectTypeIndexer"===n||"ObjectTypeProperty"===n||"ObjectTypeSpreadProperty"===n||"OpaqueType"===n||"QualifiedTypeIdentifier"===n||"StringLiteralTypeAnnotation"===n||"StringTypeAnnotation"===n||"ThisTypeAnnotation"===n||"TupleTypeAnnotation"===n||"TypeofTypeAnnotation"===n||"TypeAlias"===n||"TypeAnnotation"===n||"TypeCastExpression"===n||"TypeParameter"===n||"TypeParameterDeclaration"===n||"TypeParameterInstantiation"===n||"UnionTypeAnnotation"===n||"Variance"===n||"VoidTypeAnnotation"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isFlowType=function(e,t){if(!e)return!1;const n=e.type;if("FlowType"===n||"AnyTypeAnnotation"===n||"ArrayTypeAnnotation"===n||"BooleanTypeAnnotation"===n||"BooleanLiteralTypeAnnotation"===n||"NullLiteralTypeAnnotation"===n||"ExistsTypeAnnotation"===n||"FunctionTypeAnnotation"===n||"GenericTypeAnnotation"===n||"InterfaceTypeAnnotation"===n||"IntersectionTypeAnnotation"===n||"MixedTypeAnnotation"===n||"EmptyTypeAnnotation"===n||"NullableTypeAnnotation"===n||"NumberLiteralTypeAnnotation"===n||"NumberTypeAnnotation"===n||"ObjectTypeAnnotation"===n||"StringLiteralTypeAnnotation"===n||"StringTypeAnnotation"===n||"ThisTypeAnnotation"===n||"TupleTypeAnnotation"===n||"TypeofTypeAnnotation"===n||"UnionTypeAnnotation"===n||"VoidTypeAnnotation"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isFlowBaseAnnotation=function(e,t){if(!e)return!1;const n=e.type;if("FlowBaseAnnotation"===n||"AnyTypeAnnotation"===n||"BooleanTypeAnnotation"===n||"NullLiteralTypeAnnotation"===n||"MixedTypeAnnotation"===n||"EmptyTypeAnnotation"===n||"NumberTypeAnnotation"===n||"StringTypeAnnotation"===n||"ThisTypeAnnotation"===n||"VoidTypeAnnotation"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isFlowDeclaration=function(e,t){if(!e)return!1;const n=e.type;if("FlowDeclaration"===n||"DeclareClass"===n||"DeclareFunction"===n||"DeclareInterface"===n||"DeclareModule"===n||"DeclareModuleExports"===n||"DeclareTypeAlias"===n||"DeclareOpaqueType"===n||"DeclareVariable"===n||"DeclareExportDeclaration"===n||"DeclareExportAllDeclaration"===n||"InterfaceDeclaration"===n||"OpaqueType"===n||"TypeAlias"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isFlowPredicate=function(e,t){if(!e)return!1;const n=e.type;if("FlowPredicate"===n||"DeclaredPredicate"===n||"InferredPredicate"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isEnumBody=function(e,t){if(!e)return!1;const n=e.type;if("EnumBody"===n||"EnumBooleanBody"===n||"EnumNumberBody"===n||"EnumStringBody"===n||"EnumSymbolBody"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isEnumMember=function(e,t){if(!e)return!1;const n=e.type;if("EnumMember"===n||"EnumBooleanMember"===n||"EnumNumberMember"===n||"EnumStringMember"===n||"EnumDefaultedMember"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isJSX=function(e,t){if(!e)return!1;const n=e.type;if("JSX"===n||"JSXAttribute"===n||"JSXClosingElement"===n||"JSXElement"===n||"JSXEmptyExpression"===n||"JSXExpressionContainer"===n||"JSXSpreadChild"===n||"JSXIdentifier"===n||"JSXMemberExpression"===n||"JSXNamespacedName"===n||"JSXOpeningElement"===n||"JSXSpreadAttribute"===n||"JSXText"===n||"JSXFragment"===n||"JSXOpeningFragment"===n||"JSXClosingFragment"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isPrivate=function(e,t){if(!e)return!1;const n=e.type;if("Private"===n||"ClassPrivateProperty"===n||"ClassPrivateMethod"===n||"PrivateName"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isTSTypeElement=function(e,t){if(!e)return!1;const n=e.type;if("TSTypeElement"===n||"TSCallSignatureDeclaration"===n||"TSConstructSignatureDeclaration"===n||"TSPropertySignature"===n||"TSMethodSignature"===n||"TSIndexSignature"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isTSType=function(e,t){if(!e)return!1;const n=e.type;if("TSType"===n||"TSAnyKeyword"===n||"TSBooleanKeyword"===n||"TSBigIntKeyword"===n||"TSNeverKeyword"===n||"TSNullKeyword"===n||"TSNumberKeyword"===n||"TSObjectKeyword"===n||"TSStringKeyword"===n||"TSSymbolKeyword"===n||"TSUndefinedKeyword"===n||"TSUnknownKeyword"===n||"TSVoidKeyword"===n||"TSThisType"===n||"TSFunctionType"===n||"TSConstructorType"===n||"TSTypeReference"===n||"TSTypePredicate"===n||"TSTypeQuery"===n||"TSTypeLiteral"===n||"TSArrayType"===n||"TSTupleType"===n||"TSOptionalType"===n||"TSRestType"===n||"TSUnionType"===n||"TSIntersectionType"===n||"TSConditionalType"===n||"TSInferType"===n||"TSParenthesizedType"===n||"TSTypeOperator"===n||"TSIndexedAccessType"===n||"TSMappedType"===n||"TSLiteralType"===n||"TSExpressionWithTypeArguments"===n||"TSImportType"===n)return void 0===t||(0,i.default)(e,t);return!1},t.isNumberLiteral=function(e,t){if(console.trace("The node type NumberLiteral has been renamed to NumericLiteral"),!e)return!1;if("NumberLiteral"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isRegexLiteral=function(e,t){if(console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"),!e)return!1;if("RegexLiteral"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isRestProperty=function(e,t){if(console.trace("The node type RestProperty has been renamed to RestElement"),!e)return!1;if("RestProperty"===e.type)return void 0===t||(0,i.default)(e,t);return!1},t.isSpreadProperty=function(e,t){if(console.trace("The node type SpreadProperty has been renamed to SpreadElement"),!e)return!1;if("SpreadProperty"===e.type)return void 0===t||(0,i.default)(e,t);return!1};var r,i=(r=n(45))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"VISITOR_KEYS",{enumerable:!0,get:function(){return o.VISITOR_KEYS}}),Object.defineProperty(t,"ALIAS_KEYS",{enumerable:!0,get:function(){return o.ALIAS_KEYS}}),Object.defineProperty(t,"FLIPPED_ALIAS_KEYS",{enumerable:!0,get:function(){return o.FLIPPED_ALIAS_KEYS}}),Object.defineProperty(t,"NODE_FIELDS",{enumerable:!0,get:function(){return o.NODE_FIELDS}}),Object.defineProperty(t,"BUILDER_KEYS",{enumerable:!0,get:function(){return o.BUILDER_KEYS}}),Object.defineProperty(t,"DEPRECATED_KEYS",{enumerable:!0,get:function(){return o.DEPRECATED_KEYS}}),Object.defineProperty(t,"PLACEHOLDERS",{enumerable:!0,get:function(){return a.PLACEHOLDERS}}),Object.defineProperty(t,"PLACEHOLDERS_ALIAS",{enumerable:!0,get:function(){return a.PLACEHOLDERS_ALIAS}}),Object.defineProperty(t,"PLACEHOLDERS_FLIPPED_ALIAS",{enumerable:!0,get:function(){return a.PLACEHOLDERS_FLIPPED_ALIAS}}),t.TYPES=void 0;var r,i=(r=n(226))&&r.__esModule?r:{default:r};n(60),n(64),n(229),n(230),n(231),n(232),n(233);var o=n(8),a=n(103);(0,i.default)(o.VISITOR_KEYS),(0,i.default)(o.ALIAS_KEYS),(0,i.default)(o.FLIPPED_ALIAS_KEYS),(0,i.default)(o.NODE_FIELDS),(0,i.default)(o.BUILDER_KEYS),(0,i.default)(o.DEPRECATED_KEYS),(0,i.default)(a.PLACEHOLDERS_ALIAS),(0,i.default)(a.PLACEHOLDERS_FLIPPED_ALIAS);const s=Object.keys(o.VISITOR_KEYS).concat(Object.keys(o.FLIPPED_ALIAS_KEYS)).concat(Object.keys(o.DEPRECATED_KEYS));t.TYPES=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.arrayExpression=t.ArrayExpression=function(...e){return(0,i.default)("ArrayExpression",...e)},t.assignmentExpression=t.AssignmentExpression=function(...e){return(0,i.default)("AssignmentExpression",...e)},t.binaryExpression=t.BinaryExpression=function(...e){return(0,i.default)("BinaryExpression",...e)},t.interpreterDirective=t.InterpreterDirective=function(...e){return(0,i.default)("InterpreterDirective",...e)},t.directive=t.Directive=function(...e){return(0,i.default)("Directive",...e)},t.directiveLiteral=t.DirectiveLiteral=function(...e){return(0,i.default)("DirectiveLiteral",...e)},t.blockStatement=t.BlockStatement=function(...e){return(0,i.default)("BlockStatement",...e)},t.breakStatement=t.BreakStatement=function(...e){return(0,i.default)("BreakStatement",...e)},t.callExpression=t.CallExpression=function(...e){return(0,i.default)("CallExpression",...e)},t.catchClause=t.CatchClause=function(...e){return(0,i.default)("CatchClause",...e)},t.conditionalExpression=t.ConditionalExpression=function(...e){return(0,i.default)("ConditionalExpression",...e)},t.continueStatement=t.ContinueStatement=function(...e){return(0,i.default)("ContinueStatement",...e)},t.debuggerStatement=t.DebuggerStatement=function(...e){return(0,i.default)("DebuggerStatement",...e)},t.doWhileStatement=t.DoWhileStatement=function(...e){return(0,i.default)("DoWhileStatement",...e)},t.emptyStatement=t.EmptyStatement=function(...e){return(0,i.default)("EmptyStatement",...e)},t.expressionStatement=t.ExpressionStatement=function(...e){return(0,i.default)("ExpressionStatement",...e)},t.file=t.File=function(...e){return(0,i.default)("File",...e)},t.forInStatement=t.ForInStatement=function(...e){return(0,i.default)("ForInStatement",...e)},t.forStatement=t.ForStatement=function(...e){return(0,i.default)("ForStatement",...e)},t.functionDeclaration=t.FunctionDeclaration=function(...e){return(0,i.default)("FunctionDeclaration",...e)},t.functionExpression=t.FunctionExpression=function(...e){return(0,i.default)("FunctionExpression",...e)},t.identifier=t.Identifier=function(...e){return(0,i.default)("Identifier",...e)},t.ifStatement=t.IfStatement=function(...e){return(0,i.default)("IfStatement",...e)},t.labeledStatement=t.LabeledStatement=function(...e){return(0,i.default)("LabeledStatement",...e)},t.stringLiteral=t.StringLiteral=function(...e){return(0,i.default)("StringLiteral",...e)},t.numericLiteral=t.NumericLiteral=function(...e){return(0,i.default)("NumericLiteral",...e)},t.nullLiteral=t.NullLiteral=function(...e){return(0,i.default)("NullLiteral",...e)},t.booleanLiteral=t.BooleanLiteral=function(...e){return(0,i.default)("BooleanLiteral",...e)},t.regExpLiteral=t.RegExpLiteral=function(...e){return(0,i.default)("RegExpLiteral",...e)},t.logicalExpression=t.LogicalExpression=function(...e){return(0,i.default)("LogicalExpression",...e)},t.memberExpression=t.MemberExpression=function(...e){return(0,i.default)("MemberExpression",...e)},t.newExpression=t.NewExpression=function(...e){return(0,i.default)("NewExpression",...e)},t.program=t.Program=function(...e){return(0,i.default)("Program",...e)},t.objectExpression=t.ObjectExpression=function(...e){return(0,i.default)("ObjectExpression",...e)},t.objectMethod=t.ObjectMethod=function(...e){return(0,i.default)("ObjectMethod",...e)},t.objectProperty=t.ObjectProperty=function(...e){return(0,i.default)("ObjectProperty",...e)},t.restElement=t.RestElement=function(...e){return(0,i.default)("RestElement",...e)},t.returnStatement=t.ReturnStatement=function(...e){return(0,i.default)("ReturnStatement",...e)},t.sequenceExpression=t.SequenceExpression=function(...e){return(0,i.default)("SequenceExpression",...e)},t.parenthesizedExpression=t.ParenthesizedExpression=function(...e){return(0,i.default)("ParenthesizedExpression",...e)},t.switchCase=t.SwitchCase=function(...e){return(0,i.default)("SwitchCase",...e)},t.switchStatement=t.SwitchStatement=function(...e){return(0,i.default)("SwitchStatement",...e)},t.thisExpression=t.ThisExpression=function(...e){return(0,i.default)("ThisExpression",...e)},t.throwStatement=t.ThrowStatement=function(...e){return(0,i.default)("ThrowStatement",...e)},t.tryStatement=t.TryStatement=function(...e){return(0,i.default)("TryStatement",...e)},t.unaryExpression=t.UnaryExpression=function(...e){return(0,i.default)("UnaryExpression",...e)},t.updateExpression=t.UpdateExpression=function(...e){return(0,i.default)("UpdateExpression",...e)},t.variableDeclaration=t.VariableDeclaration=function(...e){return(0,i.default)("VariableDeclaration",...e)},t.variableDeclarator=t.VariableDeclarator=function(...e){return(0,i.default)("VariableDeclarator",...e)},t.whileStatement=t.WhileStatement=function(...e){return(0,i.default)("WhileStatement",...e)},t.withStatement=t.WithStatement=function(...e){return(0,i.default)("WithStatement",...e)},t.assignmentPattern=t.AssignmentPattern=function(...e){return(0,i.default)("AssignmentPattern",...e)},t.arrayPattern=t.ArrayPattern=function(...e){return(0,i.default)("ArrayPattern",...e)},t.arrowFunctionExpression=t.ArrowFunctionExpression=function(...e){return(0,i.default)("ArrowFunctionExpression",...e)},t.classBody=t.ClassBody=function(...e){return(0,i.default)("ClassBody",...e)},t.classDeclaration=t.ClassDeclaration=function(...e){return(0,i.default)("ClassDeclaration",...e)},t.classExpression=t.ClassExpression=function(...e){return(0,i.default)("ClassExpression",...e)},t.exportAllDeclaration=t.ExportAllDeclaration=function(...e){return(0,i.default)("ExportAllDeclaration",...e)},t.exportDefaultDeclaration=t.ExportDefaultDeclaration=function(...e){return(0,i.default)("ExportDefaultDeclaration",...e)},t.exportNamedDeclaration=t.ExportNamedDeclaration=function(...e){return(0,i.default)("ExportNamedDeclaration",...e)},t.exportSpecifier=t.ExportSpecifier=function(...e){return(0,i.default)("ExportSpecifier",...e)},t.forOfStatement=t.ForOfStatement=function(...e){return(0,i.default)("ForOfStatement",...e)},t.importDeclaration=t.ImportDeclaration=function(...e){return(0,i.default)("ImportDeclaration",...e)},t.importDefaultSpecifier=t.ImportDefaultSpecifier=function(...e){return(0,i.default)("ImportDefaultSpecifier",...e)},t.importNamespaceSpecifier=t.ImportNamespaceSpecifier=function(...e){return(0,i.default)("ImportNamespaceSpecifier",...e)},t.importSpecifier=t.ImportSpecifier=function(...e){return(0,i.default)("ImportSpecifier",...e)},t.metaProperty=t.MetaProperty=function(...e){return(0,i.default)("MetaProperty",...e)},t.classMethod=t.ClassMethod=function(...e){return(0,i.default)("ClassMethod",...e)},t.objectPattern=t.ObjectPattern=function(...e){return(0,i.default)("ObjectPattern",...e)},t.spreadElement=t.SpreadElement=function(...e){return(0,i.default)("SpreadElement",...e)},t.super=t.Super=function(...e){return(0,i.default)("Super",...e)},t.taggedTemplateExpression=t.TaggedTemplateExpression=function(...e){return(0,i.default)("TaggedTemplateExpression",...e)},t.templateElement=t.TemplateElement=function(...e){return(0,i.default)("TemplateElement",...e)},t.templateLiteral=t.TemplateLiteral=function(...e){return(0,i.default)("TemplateLiteral",...e)},t.yieldExpression=t.YieldExpression=function(...e){return(0,i.default)("YieldExpression",...e)},t.anyTypeAnnotation=t.AnyTypeAnnotation=function(...e){return(0,i.default)("AnyTypeAnnotation",...e)},t.arrayTypeAnnotation=t.ArrayTypeAnnotation=function(...e){return(0,i.default)("ArrayTypeAnnotation",...e)},t.booleanTypeAnnotation=t.BooleanTypeAnnotation=function(...e){return(0,i.default)("BooleanTypeAnnotation",...e)},t.booleanLiteralTypeAnnotation=t.BooleanLiteralTypeAnnotation=function(...e){return(0,i.default)("BooleanLiteralTypeAnnotation",...e)},t.nullLiteralTypeAnnotation=t.NullLiteralTypeAnnotation=function(...e){return(0,i.default)("NullLiteralTypeAnnotation",...e)},t.classImplements=t.ClassImplements=function(...e){return(0,i.default)("ClassImplements",...e)},t.declareClass=t.DeclareClass=function(...e){return(0,i.default)("DeclareClass",...e)},t.declareFunction=t.DeclareFunction=function(...e){return(0,i.default)("DeclareFunction",...e)},t.declareInterface=t.DeclareInterface=function(...e){return(0,i.default)("DeclareInterface",...e)},t.declareModule=t.DeclareModule=function(...e){return(0,i.default)("DeclareModule",...e)},t.declareModuleExports=t.DeclareModuleExports=function(...e){return(0,i.default)("DeclareModuleExports",...e)},t.declareTypeAlias=t.DeclareTypeAlias=function(...e){return(0,i.default)("DeclareTypeAlias",...e)},t.declareOpaqueType=t.DeclareOpaqueType=function(...e){return(0,i.default)("DeclareOpaqueType",...e)},t.declareVariable=t.DeclareVariable=function(...e){return(0,i.default)("DeclareVariable",...e)},t.declareExportDeclaration=t.DeclareExportDeclaration=function(...e){return(0,i.default)("DeclareExportDeclaration",...e)},t.declareExportAllDeclaration=t.DeclareExportAllDeclaration=function(...e){return(0,i.default)("DeclareExportAllDeclaration",...e)},t.declaredPredicate=t.DeclaredPredicate=function(...e){return(0,i.default)("DeclaredPredicate",...e)},t.existsTypeAnnotation=t.ExistsTypeAnnotation=function(...e){return(0,i.default)("ExistsTypeAnnotation",...e)},t.functionTypeAnnotation=t.FunctionTypeAnnotation=function(...e){return(0,i.default)("FunctionTypeAnnotation",...e)},t.functionTypeParam=t.FunctionTypeParam=function(...e){return(0,i.default)("FunctionTypeParam",...e)},t.genericTypeAnnotation=t.GenericTypeAnnotation=function(...e){return(0,i.default)("GenericTypeAnnotation",...e)},t.inferredPredicate=t.InferredPredicate=function(...e){return(0,i.default)("InferredPredicate",...e)},t.interfaceExtends=t.InterfaceExtends=function(...e){return(0,i.default)("InterfaceExtends",...e)},t.interfaceDeclaration=t.InterfaceDeclaration=function(...e){return(0,i.default)("InterfaceDeclaration",...e)},t.interfaceTypeAnnotation=t.InterfaceTypeAnnotation=function(...e){return(0,i.default)("InterfaceTypeAnnotation",...e)},t.intersectionTypeAnnotation=t.IntersectionTypeAnnotation=function(...e){return(0,i.default)("IntersectionTypeAnnotation",...e)},t.mixedTypeAnnotation=t.MixedTypeAnnotation=function(...e){return(0,i.default)("MixedTypeAnnotation",...e)},t.emptyTypeAnnotation=t.EmptyTypeAnnotation=function(...e){return(0,i.default)("EmptyTypeAnnotation",...e)},t.nullableTypeAnnotation=t.NullableTypeAnnotation=function(...e){return(0,i.default)("NullableTypeAnnotation",...e)},t.numberLiteralTypeAnnotation=t.NumberLiteralTypeAnnotation=function(...e){return(0,i.default)("NumberLiteralTypeAnnotation",...e)},t.numberTypeAnnotation=t.NumberTypeAnnotation=function(...e){return(0,i.default)("NumberTypeAnnotation",...e)},t.objectTypeAnnotation=t.ObjectTypeAnnotation=function(...e){return(0,i.default)("ObjectTypeAnnotation",...e)},t.objectTypeInternalSlot=t.ObjectTypeInternalSlot=function(...e){return(0,i.default)("ObjectTypeInternalSlot",...e)},t.objectTypeCallProperty=t.ObjectTypeCallProperty=function(...e){return(0,i.default)("ObjectTypeCallProperty",...e)},t.objectTypeIndexer=t.ObjectTypeIndexer=function(...e){return(0,i.default)("ObjectTypeIndexer",...e)},t.objectTypeProperty=t.ObjectTypeProperty=function(...e){return(0,i.default)("ObjectTypeProperty",...e)},t.objectTypeSpreadProperty=t.ObjectTypeSpreadProperty=function(...e){return(0,i.default)("ObjectTypeSpreadProperty",...e)},t.opaqueType=t.OpaqueType=function(...e){return(0,i.default)("OpaqueType",...e)},t.qualifiedTypeIdentifier=t.QualifiedTypeIdentifier=function(...e){return(0,i.default)("QualifiedTypeIdentifier",...e)},t.stringLiteralTypeAnnotation=t.StringLiteralTypeAnnotation=function(...e){return(0,i.default)("StringLiteralTypeAnnotation",...e)},t.stringTypeAnnotation=t.StringTypeAnnotation=function(...e){return(0,i.default)("StringTypeAnnotation",...e)},t.thisTypeAnnotation=t.ThisTypeAnnotation=function(...e){return(0,i.default)("ThisTypeAnnotation",...e)},t.tupleTypeAnnotation=t.TupleTypeAnnotation=function(...e){return(0,i.default)("TupleTypeAnnotation",...e)},t.typeofTypeAnnotation=t.TypeofTypeAnnotation=function(...e){return(0,i.default)("TypeofTypeAnnotation",...e)},t.typeAlias=t.TypeAlias=function(...e){return(0,i.default)("TypeAlias",...e)},t.typeAnnotation=t.TypeAnnotation=function(...e){return(0,i.default)("TypeAnnotation",...e)},t.typeCastExpression=t.TypeCastExpression=function(...e){return(0,i.default)("TypeCastExpression",...e)},t.typeParameter=t.TypeParameter=function(...e){return(0,i.default)("TypeParameter",...e)},t.typeParameterDeclaration=t.TypeParameterDeclaration=function(...e){return(0,i.default)("TypeParameterDeclaration",...e)},t.typeParameterInstantiation=t.TypeParameterInstantiation=function(...e){return(0,i.default)("TypeParameterInstantiation",...e)},t.unionTypeAnnotation=t.UnionTypeAnnotation=function(...e){return(0,i.default)("UnionTypeAnnotation",...e)},t.variance=t.Variance=function(...e){return(0,i.default)("Variance",...e)},t.voidTypeAnnotation=t.VoidTypeAnnotation=function(...e){return(0,i.default)("VoidTypeAnnotation",...e)},t.enumDeclaration=t.EnumDeclaration=function(...e){return(0,i.default)("EnumDeclaration",...e)},t.enumBooleanBody=t.EnumBooleanBody=function(...e){return(0,i.default)("EnumBooleanBody",...e)},t.enumNumberBody=t.EnumNumberBody=function(...e){return(0,i.default)("EnumNumberBody",...e)},t.enumStringBody=t.EnumStringBody=function(...e){return(0,i.default)("EnumStringBody",...e)},t.enumSymbolBody=t.EnumSymbolBody=function(...e){return(0,i.default)("EnumSymbolBody",...e)},t.enumBooleanMember=t.EnumBooleanMember=function(...e){return(0,i.default)("EnumBooleanMember",...e)},t.enumNumberMember=t.EnumNumberMember=function(...e){return(0,i.default)("EnumNumberMember",...e)},t.enumStringMember=t.EnumStringMember=function(...e){return(0,i.default)("EnumStringMember",...e)},t.enumDefaultedMember=t.EnumDefaultedMember=function(...e){return(0,i.default)("EnumDefaultedMember",...e)},t.jSXAttribute=t.jsxAttribute=t.JSXAttribute=function(...e){return(0,i.default)("JSXAttribute",...e)},t.jSXClosingElement=t.jsxClosingElement=t.JSXClosingElement=function(...e){return(0,i.default)("JSXClosingElement",...e)},t.jSXElement=t.jsxElement=t.JSXElement=function(...e){return(0,i.default)("JSXElement",...e)},t.jSXEmptyExpression=t.jsxEmptyExpression=t.JSXEmptyExpression=function(...e){return(0,i.default)("JSXEmptyExpression",...e)},t.jSXExpressionContainer=t.jsxExpressionContainer=t.JSXExpressionContainer=function(...e){return(0,i.default)("JSXExpressionContainer",...e)},t.jSXSpreadChild=t.jsxSpreadChild=t.JSXSpreadChild=function(...e){return(0,i.default)("JSXSpreadChild",...e)},t.jSXIdentifier=t.jsxIdentifier=t.JSXIdentifier=function(...e){return(0,i.default)("JSXIdentifier",...e)},t.jSXMemberExpression=t.jsxMemberExpression=t.JSXMemberExpression=function(...e){return(0,i.default)("JSXMemberExpression",...e)},t.jSXNamespacedName=t.jsxNamespacedName=t.JSXNamespacedName=function(...e){return(0,i.default)("JSXNamespacedName",...e)},t.jSXOpeningElement=t.jsxOpeningElement=t.JSXOpeningElement=function(...e){return(0,i.default)("JSXOpeningElement",...e)},t.jSXSpreadAttribute=t.jsxSpreadAttribute=t.JSXSpreadAttribute=function(...e){return(0,i.default)("JSXSpreadAttribute",...e)},t.jSXText=t.jsxText=t.JSXText=function(...e){return(0,i.default)("JSXText",...e)},t.jSXFragment=t.jsxFragment=t.JSXFragment=function(...e){return(0,i.default)("JSXFragment",...e)},t.jSXOpeningFragment=t.jsxOpeningFragment=t.JSXOpeningFragment=function(...e){return(0,i.default)("JSXOpeningFragment",...e)},t.jSXClosingFragment=t.jsxClosingFragment=t.JSXClosingFragment=function(...e){return(0,i.default)("JSXClosingFragment",...e)},t.noop=t.Noop=function(...e){return(0,i.default)("Noop",...e)},t.placeholder=t.Placeholder=function(...e){return(0,i.default)("Placeholder",...e)},t.v8IntrinsicIdentifier=t.V8IntrinsicIdentifier=function(...e){return(0,i.default)("V8IntrinsicIdentifier",...e)},t.argumentPlaceholder=t.ArgumentPlaceholder=function(...e){return(0,i.default)("ArgumentPlaceholder",...e)},t.awaitExpression=t.AwaitExpression=function(...e){return(0,i.default)("AwaitExpression",...e)},t.bindExpression=t.BindExpression=function(...e){return(0,i.default)("BindExpression",...e)},t.classProperty=t.ClassProperty=function(...e){return(0,i.default)("ClassProperty",...e)},t.optionalMemberExpression=t.OptionalMemberExpression=function(...e){return(0,i.default)("OptionalMemberExpression",...e)},t.pipelineTopicExpression=t.PipelineTopicExpression=function(...e){return(0,i.default)("PipelineTopicExpression",...e)},t.pipelineBareFunction=t.PipelineBareFunction=function(...e){return(0,i.default)("PipelineBareFunction",...e)},t.pipelinePrimaryTopicReference=t.PipelinePrimaryTopicReference=function(...e){return(0,i.default)("PipelinePrimaryTopicReference",...e)},t.optionalCallExpression=t.OptionalCallExpression=function(...e){return(0,i.default)("OptionalCallExpression",...e)},t.classPrivateProperty=t.ClassPrivateProperty=function(...e){return(0,i.default)("ClassPrivateProperty",...e)},t.classPrivateMethod=t.ClassPrivateMethod=function(...e){return(0,i.default)("ClassPrivateMethod",...e)},t.import=t.Import=function(...e){return(0,i.default)("Import",...e)},t.decorator=t.Decorator=function(...e){return(0,i.default)("Decorator",...e)},t.doExpression=t.DoExpression=function(...e){return(0,i.default)("DoExpression",...e)},t.exportDefaultSpecifier=t.ExportDefaultSpecifier=function(...e){return(0,i.default)("ExportDefaultSpecifier",...e)},t.exportNamespaceSpecifier=t.ExportNamespaceSpecifier=function(...e){return(0,i.default)("ExportNamespaceSpecifier",...e)},t.privateName=t.PrivateName=function(...e){return(0,i.default)("PrivateName",...e)},t.bigIntLiteral=t.BigIntLiteral=function(...e){return(0,i.default)("BigIntLiteral",...e)},t.tSParameterProperty=t.tsParameterProperty=t.TSParameterProperty=function(...e){return(0,i.default)("TSParameterProperty",...e)},t.tSDeclareFunction=t.tsDeclareFunction=t.TSDeclareFunction=function(...e){return(0,i.default)("TSDeclareFunction",...e)},t.tSDeclareMethod=t.tsDeclareMethod=t.TSDeclareMethod=function(...e){return(0,i.default)("TSDeclareMethod",...e)},t.tSQualifiedName=t.tsQualifiedName=t.TSQualifiedName=function(...e){return(0,i.default)("TSQualifiedName",...e)},t.tSCallSignatureDeclaration=t.tsCallSignatureDeclaration=t.TSCallSignatureDeclaration=function(...e){return(0,i.default)("TSCallSignatureDeclaration",...e)},t.tSConstructSignatureDeclaration=t.tsConstructSignatureDeclaration=t.TSConstructSignatureDeclaration=function(...e){return(0,i.default)("TSConstructSignatureDeclaration",...e)},t.tSPropertySignature=t.tsPropertySignature=t.TSPropertySignature=function(...e){return(0,i.default)("TSPropertySignature",...e)},t.tSMethodSignature=t.tsMethodSignature=t.TSMethodSignature=function(...e){return(0,i.default)("TSMethodSignature",...e)},t.tSIndexSignature=t.tsIndexSignature=t.TSIndexSignature=function(...e){return(0,i.default)("TSIndexSignature",...e)},t.tSAnyKeyword=t.tsAnyKeyword=t.TSAnyKeyword=function(...e){return(0,i.default)("TSAnyKeyword",...e)},t.tSBooleanKeyword=t.tsBooleanKeyword=t.TSBooleanKeyword=function(...e){return(0,i.default)("TSBooleanKeyword",...e)},t.tSBigIntKeyword=t.tsBigIntKeyword=t.TSBigIntKeyword=function(...e){return(0,i.default)("TSBigIntKeyword",...e)},t.tSNeverKeyword=t.tsNeverKeyword=t.TSNeverKeyword=function(...e){return(0,i.default)("TSNeverKeyword",...e)},t.tSNullKeyword=t.tsNullKeyword=t.TSNullKeyword=function(...e){return(0,i.default)("TSNullKeyword",...e)},t.tSNumberKeyword=t.tsNumberKeyword=t.TSNumberKeyword=function(...e){return(0,i.default)("TSNumberKeyword",...e)},t.tSObjectKeyword=t.tsObjectKeyword=t.TSObjectKeyword=function(...e){return(0,i.default)("TSObjectKeyword",...e)},t.tSStringKeyword=t.tsStringKeyword=t.TSStringKeyword=function(...e){return(0,i.default)("TSStringKeyword",...e)},t.tSSymbolKeyword=t.tsSymbolKeyword=t.TSSymbolKeyword=function(...e){return(0,i.default)("TSSymbolKeyword",...e)},t.tSUndefinedKeyword=t.tsUndefinedKeyword=t.TSUndefinedKeyword=function(...e){return(0,i.default)("TSUndefinedKeyword",...e)},t.tSUnknownKeyword=t.tsUnknownKeyword=t.TSUnknownKeyword=function(...e){return(0,i.default)("TSUnknownKeyword",...e)},t.tSVoidKeyword=t.tsVoidKeyword=t.TSVoidKeyword=function(...e){return(0,i.default)("TSVoidKeyword",...e)},t.tSThisType=t.tsThisType=t.TSThisType=function(...e){return(0,i.default)("TSThisType",...e)},t.tSFunctionType=t.tsFunctionType=t.TSFunctionType=function(...e){return(0,i.default)("TSFunctionType",...e)},t.tSConstructorType=t.tsConstructorType=t.TSConstructorType=function(...e){return(0,i.default)("TSConstructorType",...e)},t.tSTypeReference=t.tsTypeReference=t.TSTypeReference=function(...e){return(0,i.default)("TSTypeReference",...e)},t.tSTypePredicate=t.tsTypePredicate=t.TSTypePredicate=function(...e){return(0,i.default)("TSTypePredicate",...e)},t.tSTypeQuery=t.tsTypeQuery=t.TSTypeQuery=function(...e){return(0,i.default)("TSTypeQuery",...e)},t.tSTypeLiteral=t.tsTypeLiteral=t.TSTypeLiteral=function(...e){return(0,i.default)("TSTypeLiteral",...e)},t.tSArrayType=t.tsArrayType=t.TSArrayType=function(...e){return(0,i.default)("TSArrayType",...e)},t.tSTupleType=t.tsTupleType=t.TSTupleType=function(...e){return(0,i.default)("TSTupleType",...e)},t.tSOptionalType=t.tsOptionalType=t.TSOptionalType=function(...e){return(0,i.default)("TSOptionalType",...e)},t.tSRestType=t.tsRestType=t.TSRestType=function(...e){return(0,i.default)("TSRestType",...e)},t.tSUnionType=t.tsUnionType=t.TSUnionType=function(...e){return(0,i.default)("TSUnionType",...e)},t.tSIntersectionType=t.tsIntersectionType=t.TSIntersectionType=function(...e){return(0,i.default)("TSIntersectionType",...e)},t.tSConditionalType=t.tsConditionalType=t.TSConditionalType=function(...e){return(0,i.default)("TSConditionalType",...e)},t.tSInferType=t.tsInferType=t.TSInferType=function(...e){return(0,i.default)("TSInferType",...e)},t.tSParenthesizedType=t.tsParenthesizedType=t.TSParenthesizedType=function(...e){return(0,i.default)("TSParenthesizedType",...e)},t.tSTypeOperator=t.tsTypeOperator=t.TSTypeOperator=function(...e){return(0,i.default)("TSTypeOperator",...e)},t.tSIndexedAccessType=t.tsIndexedAccessType=t.TSIndexedAccessType=function(...e){return(0,i.default)("TSIndexedAccessType",...e)},t.tSMappedType=t.tsMappedType=t.TSMappedType=function(...e){return(0,i.default)("TSMappedType",...e)},t.tSLiteralType=t.tsLiteralType=t.TSLiteralType=function(...e){return(0,i.default)("TSLiteralType",...e)},t.tSExpressionWithTypeArguments=t.tsExpressionWithTypeArguments=t.TSExpressionWithTypeArguments=function(...e){return(0,i.default)("TSExpressionWithTypeArguments",...e)},t.tSInterfaceDeclaration=t.tsInterfaceDeclaration=t.TSInterfaceDeclaration=function(...e){return(0,i.default)("TSInterfaceDeclaration",...e)},t.tSInterfaceBody=t.tsInterfaceBody=t.TSInterfaceBody=function(...e){return(0,i.default)("TSInterfaceBody",...e)},t.tSTypeAliasDeclaration=t.tsTypeAliasDeclaration=t.TSTypeAliasDeclaration=function(...e){return(0,i.default)("TSTypeAliasDeclaration",...e)},t.tSAsExpression=t.tsAsExpression=t.TSAsExpression=function(...e){return(0,i.default)("TSAsExpression",...e)},t.tSTypeAssertion=t.tsTypeAssertion=t.TSTypeAssertion=function(...e){return(0,i.default)("TSTypeAssertion",...e)},t.tSEnumDeclaration=t.tsEnumDeclaration=t.TSEnumDeclaration=function(...e){return(0,i.default)("TSEnumDeclaration",...e)},t.tSEnumMember=t.tsEnumMember=t.TSEnumMember=function(...e){return(0,i.default)("TSEnumMember",...e)},t.tSModuleDeclaration=t.tsModuleDeclaration=t.TSModuleDeclaration=function(...e){return(0,i.default)("TSModuleDeclaration",...e)},t.tSModuleBlock=t.tsModuleBlock=t.TSModuleBlock=function(...e){return(0,i.default)("TSModuleBlock",...e)},t.tSImportType=t.tsImportType=t.TSImportType=function(...e){return(0,i.default)("TSImportType",...e)},t.tSImportEqualsDeclaration=t.tsImportEqualsDeclaration=t.TSImportEqualsDeclaration=function(...e){return(0,i.default)("TSImportEqualsDeclaration",...e)},t.tSExternalModuleReference=t.tsExternalModuleReference=t.TSExternalModuleReference=function(...e){return(0,i.default)("TSExternalModuleReference",...e)},t.tSNonNullExpression=t.tsNonNullExpression=t.TSNonNullExpression=function(...e){return(0,i.default)("TSNonNullExpression",...e)},t.tSExportAssignment=t.tsExportAssignment=t.TSExportAssignment=function(...e){return(0,i.default)("TSExportAssignment",...e)},t.tSNamespaceExportDeclaration=t.tsNamespaceExportDeclaration=t.TSNamespaceExportDeclaration=function(...e){return(0,i.default)("TSNamespaceExportDeclaration",...e)},t.tSTypeAnnotation=t.tsTypeAnnotation=t.TSTypeAnnotation=function(...e){return(0,i.default)("TSTypeAnnotation",...e)},t.tSTypeParameterInstantiation=t.tsTypeParameterInstantiation=t.TSTypeParameterInstantiation=function(...e){return(0,i.default)("TSTypeParameterInstantiation",...e)},t.tSTypeParameterDeclaration=t.tsTypeParameterDeclaration=t.TSTypeParameterDeclaration=function(...e){return(0,i.default)("TSTypeParameterDeclaration",...e)},t.tSTypeParameter=t.tsTypeParameter=t.TSTypeParameter=function(...e){return(0,i.default)("TSTypeParameter",...e)},t.numberLiteral=t.NumberLiteral=function e(...t){return console.trace("The node type NumberLiteral has been renamed to NumericLiteral"),e("NumberLiteral",...t)},t.regexLiteral=t.RegexLiteral=function e(...t){return console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"),e("RegexLiteral",...t)},t.restProperty=t.RestProperty=function e(...t){return console.trace("The node type RestProperty has been renamed to RestElement"),e("RestProperty",...t)},t.spreadProperty=t.SpreadProperty=function e(...t){return console.trace("The node type SpreadProperty has been renamed to SpreadElement"),e("SpreadProperty",...t)};var r,i=(r=n(165))&&r.__esModule?r:{default:r}},function(e,t){var n=Array.isArray;e.exports=n},function(e,t,n){var r=n(86),i="object"==typeof self&&self&&self.Object===Object&&self,o=r||i||Function("return this")();e.exports=o},function(e,t){e.exports=function(e){return null!=e&&"object"==typeof e}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=d,Object.defineProperty(t,"NodePath",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"Scope",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"Hub",{enumerable:!0,get:function(){return l.default}}),t.visitors=void 0;var r=h(n(160)),i=p(n(357));t.visitors=i;var o=h(n(68)),a=p(n(0)),s=p(n(36)),u=h(n(10)),c=h(n(121)),l=h(n(358));function f(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return f=function(){return e},e}function p(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=f();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}return n.default=e,t&&t.set(e,n),n}function h(e){return e&&e.__esModule?e:{default:e}}function d(e,t,n,r,o){if(e){if(t||(t={}),!t.noScope&&!n&&"Program"!==e.type&&"File"!==e.type)throw new Error("You must pass a scope and parentPath unless traversing a Program/File. "+`Instead of that you tried to traverse a ${e.type} node without `+"passing scope and parentPath.");a.VISITOR_KEYS[e.type]&&(i.explode(t),d.node(e,t,n,r,o))}}function y(e,t){e.node.type===t.type&&(t.has=!0,e.stop())}d.visitors=i,d.verify=i.verify,d.explode=i.explode,d.cheap=function(e,t){return a.traverseFast(e,t)},d.node=function(e,t,n,i,o,s){const u=a.VISITOR_KEYS[e.type];if(!u)return;const c=new r.default(n,t,i,o);for(const t of u)if((!s||!s[t])&&c.visit(e,t))return},d.clearNode=function(e,t){a.removeProperties(e,t),s.path.delete(e)},d.removeProperties=function(e,t){return a.traverseFast(e,d.clearNode,t),e},d.hasType=function(e,t,n){if((0,o.default)(n,e.type))return!1;if(e.type===t)return!0;const r={has:!1,type:t};return d(e,{noScope:!0,blacklist:n,enter:y},null,r),r.has},d.cache=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validate=h,t.typeIs=d,t.validateType=function(e){return h(d(e))},t.validateOptional=function(e){return{validate:e,optional:!0}},t.validateOptionalType=function(e){return{validate:d(e),optional:!0}},t.arrayOf=y,t.arrayOfType=m,t.validateArrayOfType=function(e){return h(m(e))},t.assertEach=v,t.assertOneOf=function(...e){function t(t,n,r){if(e.indexOf(r)<0)throw new TypeError(`Property ${n} expected value to be one of ${JSON.stringify(e)} but got ${JSON.stringify(r)}`)}return t.oneOf=e,t},t.assertNodeType=b,t.assertNodeOrValueType=function(...e){function t(t,n,r){let o=!1;for(const t of e)if(p(r)===t||(0,i.default)(t,r)){o=!0;break}if(!o)throw new TypeError(`Property ${n} of ${t.type} expected node to be of a type ${JSON.stringify(e)} `+`but instead got ${JSON.stringify(r&&r.type)}`)}return t.oneOfNodeOrValueTypes=e,t},t.assertValueType=g,t.assertShape=function(e){function t(t,n,r){const i=[];for(const n of Object.keys(e))try{(0,o.validateField)(t,n,r[n],e[n])}catch(e){if(e instanceof TypeError){i.push(e.message);continue}throw e}if(i.length)throw new TypeError(`Property ${n} of ${t.type} expected to have the following:\n${i.join("\n")}`)}return t.shapeOf=e,t},t.chain=w,t.default=function(e,t={}){const n=t.inherits&&S[t.inherits]||{},r=t.fields||n.fields||{},i=t.visitor||n.visitor||[],o=t.aliases||n.aliases||[],h=t.builder||n.builder||t.visitor||[];t.deprecatedAlias&&(f[t.deprecatedAlias]=e);for(const e of i.concat(h))r[e]=r[e]||{};for(const e of Object.keys(r)){const t=r[e];-1===h.indexOf(e)&&(t.optional=!0),void 0===t.default?t.default=null:t.validate||(t.validate=g(p(t.default)))}a[e]=t.visitor=i,l[e]=t.builder=h,c[e]=t.fields=r,s[e]=t.aliases=o,o.forEach(t=>{u[t]=u[t]||[],u[t].push(e)}),S[e]=t},t.DEPRECATED_KEYS=t.BUILDER_KEYS=t.NODE_FIELDS=t.FLIPPED_ALIAS_KEYS=t.ALIAS_KEYS=t.VISITOR_KEYS=void 0;var r,i=(r=n(61))&&r.__esModule?r:{default:r},o=n(63);const a={};t.VISITOR_KEYS=a;const s={};t.ALIAS_KEYS=s;const u={};t.FLIPPED_ALIAS_KEYS=u;const c={};t.NODE_FIELDS=c;const l={};t.BUILDER_KEYS=l;const f={};function p(e){return Array.isArray(e)?"array":null===e?"null":void 0===e?"undefined":typeof e}function h(e){return{validate:e}}function d(e){return"string"==typeof e?b(e):b(...e)}function y(e){return w(g("array"),v(e))}function m(e){return y(d(e))}function v(e){function t(t,n,r){if(Array.isArray(r))for(let i=0;i1)for(var n=1;n","<",">=","<="];t.BOOLEAN_NUMBER_BINARY_OPERATORS=r;const i=["==","===","!=","!=="];t.EQUALITY_BINARY_OPERATORS=i;const o=[...i,"in","instanceof"];t.COMPARISON_BINARY_OPERATORS=o;const a=[...o,...r];t.BOOLEAN_BINARY_OPERATORS=a;const s=["-","/","%","*","**","&","|",">>",">>>","<<","^"];t.NUMBER_BINARY_OPERATORS=s;const u=["+",...s,...a];t.BINARY_OPERATORS=u;const c=["delete","!"];t.BOOLEAN_UNARY_OPERATORS=c;const l=["+","-","~"];t.NUMBER_UNARY_OPERATORS=l;const f=["typeof"];t.STRING_UNARY_OPERATORS=f;const p=["void","throw",...c,...l,...f];t.UNARY_OPERATORS=p;t.INHERIT_KEYS={optional:["typeAnnotation","typeParameters","returnType"],force:["start","loc","end"]};const h=Symbol.for("var used to be block scoped");t.BLOCK_SCOPED_SYMBOL=h;const d=Symbol.for("should not be considered a local binding");t.NOT_LOCAL_BINDING=d},function(e,t,n){(function(e){function n(e,t){for(var n=0,r=e.length-1;r>=0;r--){var i=e[r];"."===i?e.splice(r,1):".."===i?(e.splice(r,1),n++):n&&(e.splice(r,1),n--)}if(t)for(;n--;n)e.unshift("..");return e}function r(e,t){if(e.filter)return e.filter(t);for(var n=[],r=0;r=-1&&!i;o--){var a=o>=0?arguments[o]:e.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(t=a+"/"+t,i="/"===a.charAt(0))}return(i?"/":"")+(t=n(r(t.split("/"),(function(e){return!!e})),!i).join("/"))||"."},t.normalize=function(e){var o=t.isAbsolute(e),a="/"===i(e,-1);return(e=n(r(e.split("/"),(function(e){return!!e})),!o).join("/"))||o||(e="."),e&&a&&(e+="/"),(o?"/":"")+e},t.isAbsolute=function(e){return"/"===e.charAt(0)},t.join=function(){var e=Array.prototype.slice.call(arguments,0);return t.normalize(r(e,(function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e})).join("/"))},t.relative=function(e,n){function r(e){for(var t=0;t=0&&""===e[n];n--);return t>n?[]:e.slice(t,n-t+1)}e=t.resolve(e).substr(1),n=t.resolve(n).substr(1);for(var i=r(e.split("/")),o=r(n.split("/")),a=Math.min(i.length,o.length),s=a,u=0;u=1;--o)if(47===(t=e.charCodeAt(o))){if(!i){r=o;break}}else i=!1;return-1===r?n?"/":".":n&&1===r?"/":e.slice(0,r)},t.basename=function(e,t){var n=function(e){"string"!=typeof e&&(e+="");var t,n=0,r=-1,i=!0;for(t=e.length-1;t>=0;--t)if(47===e.charCodeAt(t)){if(!i){n=t+1;break}}else-1===r&&(i=!1,r=t+1);return-1===r?"":e.slice(n,r)}(e);return t&&n.substr(-1*t.length)===t&&(n=n.substr(0,n.length-t.length)),n},t.extname=function(e){"string"!=typeof e&&(e+="");for(var t=-1,n=0,r=-1,i=!0,o=0,a=e.length-1;a>=0;--a){var s=e.charCodeAt(a);if(47!==s)-1===r&&(i=!1,r=a+1),46===s?-1===t?t=a:1!==o&&(o=1):-1!==t&&(o=-1);else if(!i){n=a+1;break}}return-1===t||-1===r||0===o||1===o&&t===r-1&&t===n+1?"":e.slice(t,r)};var i="b"==="ab".substr(-1)?function(e,t,n){return e.substr(t,n)}:function(e,t,n){return t<0&&(t=e.length+t),e.substr(t,n)}}).call(this,n(9))},function(e,t,n){var r=n(5).Symbol;e.exports=r},function(e,t,n){var r=n(91),i=n(200),o=n(18);e.exports=function(e){return o(e)?r(e):i(e)}},function(e,t,n){var r=n(85),i=n(53);e.exports=function(e){return null!=e&&i(e.length)&&!r(e)}},function(e,t){e.exports=function(e,t){return e===t||e!=e&&t!=t}},function(e,t){e.exports=function(e){return function(t){return e(t)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return"string"==typeof e&&!i.default.keyword.isReservedWordES6(e,!0)&&("await"!==e&&i.default.keyword.isIdentifierNameES6(e))};var r,i=(r=n(100))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=s;var r=n(2);const i=Function.call.bind(Object.prototype.hasOwnProperty);function o(e,t){return e&&"string"==typeof e.type&&"CommentLine"!==e.type&&"CommentBlock"!==e.type?s(e,t):e}function a(e,t){return Array.isArray(e)?e.map(e=>o(e,t)):o(e,t)}function s(e,t=!0){if(!e)return e;const{type:n}=e,o={type:n};if("Identifier"===n)o.name=e.name,i(e,"optional")&&"boolean"==typeof e.optional&&(o.optional=e.optional),i(e,"typeAnnotation")&&(o.typeAnnotation=t?a(e.typeAnnotation,!0):e.typeAnnotation);else{if(!i(r.NODE_FIELDS,n))throw new Error(`Unknown node type: "${n}"`);for(const s of Object.keys(r.NODE_FIELDS[n]))i(e,s)&&(o[s]=t?a(e[s],!0):e[s])}return i(e,"loc")&&(o.loc=e.loc),i(e,"leadingComments")&&(o.leadingComments=e.leadingComments),i(e,"innerComments")&&(o.innerComments=e.innerComments),i(e,"trailingComments")&&(o.trailingComments=e.trailingComments),i(e,"extra")&&(o.extra=Object.assign({},e.extra)),o}},function(e,t,n){var r=n(11),i=n(6);e.exports=function(e){return"symbol"==typeof e||i(e)&&"[object Symbol]"==r(e)}},function(e,t){t.getArg=function(e,t,n){if(t in e)return e[t];if(3===arguments.length)return n;throw new Error('"'+t+'" is a required argument.')};var n=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.]*)(?::(\d+))?(\S*)$/,r=/^data:.+\,.+$/;function i(e){var t=e.match(n);return t?{scheme:t[1],auth:t[2],host:t[3],port:t[4],path:t[5]}:null}function o(e){var t="";return e.scheme&&(t+=e.scheme+":"),t+="//",e.auth&&(t+=e.auth+"@"),e.host&&(t+=e.host),e.port&&(t+=":"+e.port),e.path&&(t+=e.path),t}function a(e){var n=e,r=i(e);if(r){if(!r.path)return e;n=r.path}for(var a,s=t.isAbsolute(n),u=n.split(/\/+/),c=0,l=u.length-1;l>=0;l--)"."===(a=u[l])?u.splice(l,1):".."===a?c++:c>0&&(""===a?(u.splice(l+1,c),c=0):(u.splice(l,2),c--));return""===(n=u.join("/"))&&(n=s?"/":"."),r?(r.path=n,o(r)):n}t.urlParse=i,t.urlGenerate=o,t.normalize=a,t.join=function(e,t){""===e&&(e="."),""===t&&(t=".");var n=i(t),s=i(e);if(s&&(e=s.path||"/"),n&&!n.scheme)return s&&(n.scheme=s.scheme),o(n);if(n||t.match(r))return t;if(s&&!s.host&&!s.path)return s.host=t,o(s);var u="/"===t.charAt(0)?t:a(e.replace(/\/+$/,"")+"/"+t);return s?(s.path=u,o(s)):u},t.isAbsolute=function(e){return"/"===e.charAt(0)||!!e.match(n)},t.relative=function(e,t){""===e&&(e="."),e=e.replace(/\/$/,"");for(var n=0;0!==t.indexOf(e+"/");){var r=e.lastIndexOf("/");if(r<0)return t;if((e=e.slice(0,r)).match(/^([^\/]+:\/)?\/*$/))return t;++n}return Array(n+1).join("../")+t.substr(e.length+1)};var s=!("__proto__"in Object.create(null));function u(e){return e}function c(e){if(!e)return!1;var t=e.length;if(t<9)return!1;if(95!==e.charCodeAt(t-1)||95!==e.charCodeAt(t-2)||111!==e.charCodeAt(t-3)||116!==e.charCodeAt(t-4)||111!==e.charCodeAt(t-5)||114!==e.charCodeAt(t-6)||112!==e.charCodeAt(t-7)||95!==e.charCodeAt(t-8)||95!==e.charCodeAt(t-9))return!1;for(var n=t-10;n>=0;n--)if(36!==e.charCodeAt(n))return!1;return!0}function l(e,t){return e===t?0:e>t?1:-1}t.toSetString=s?u:function(e){return c(e)?"$"+e:e},t.fromSetString=s?u:function(e){return c(e)?e.slice(1):e},t.compareByOriginalPositions=function(e,t,n){var r=e.source-t.source;return 0!==r?r:0!==(r=e.originalLine-t.originalLine)?r:0!==(r=e.originalColumn-t.originalColumn)||n?r:0!==(r=e.generatedColumn-t.generatedColumn)?r:0!==(r=e.generatedLine-t.generatedLine)?r:e.name-t.name},t.compareByGeneratedPositionsDeflated=function(e,t,n){var r=e.generatedLine-t.generatedLine;return 0!==r?r:0!==(r=e.generatedColumn-t.generatedColumn)||n?r:0!==(r=e.source-t.source)?r:0!==(r=e.originalLine-t.originalLine)?r:0!==(r=e.originalColumn-t.originalColumn)?r:e.name-t.name},t.compareByGeneratedPositionsInflated=function(e,t){var n=e.generatedLine-t.generatedLine;return 0!==n?n:0!==(n=e.generatedColumn-t.generatedColumn)?n:0!==(n=l(e.source,t.source))?n:0!==(n=e.originalLine-t.originalLine)?n:0!==(n=e.originalColumn-t.originalColumn)?n:l(e.name,t.name)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.loadOptions=function(e){const t=(0,i.default)(e);return t?t.options:null},Object.defineProperty(t,"default",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"loadPartialConfig",{enumerable:!0,get:function(){return o.loadPartialConfig}});var r,i=(r=n(362))&&r.__esModule?r:{default:r},o=n(142)},function(e,t,n){var r=n(166),i=n(167),o=n(168),a=n(169),s=n(170);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++ti?e(t):t,c=e.split(o),{start:l,end:f,markerLines:p}=function(e,t,n){const r=Object.assign({column:0,line:-1},e.start),i=Object.assign({},r,e.end),{linesAbove:o=2,linesBelow:a=3}=n||{},s=r.line,u=r.column,c=i.line,l=i.column;let f=Math.max(s-(o+1),0),p=Math.min(t.length,c+a);-1===s&&(f=0),-1===c&&(p=t.length);const h=c-s,d={};if(h)for(let e=0;e<=h;e++){const n=e+s;if(u)if(0===e){const e=t[n-1].length;d[n]=[u,e-u+1]}else if(e===h)d[n]=[0,l];else{const r=t[n-e].length;d[n]=[0,r]}else d[n]=!0}else d[s]=u===l?!u||[u,0]:[u,l-u];return{start:f,end:p,markerLines:d}}(t,c,n),h=t.start&&"number"==typeof t.start.column,d=String(f).length;let y=(i?(0,r().default)(e,n):e).split(o).slice(l,f).map((e,t)=>{const r=l+1+t,i=` ${` ${r}`.slice(-d)} | `,o=p[r],a=!p[r+1];if(o){let t="";if(Array.isArray(o)){const r=e.slice(0,Math.max(o[0]-1,0)).replace(/[^\t]/g," "),c=o[1]||1;t=["\n ",u(s.gutter,i.replace(/\d/g," ")),r,u(s.marker,"^").repeat(c)].join(""),a&&n.message&&(t+=" "+u(s.message,n.message))}return[u(s.marker,">"),u(s.gutter,i),e,t].join("")}return` ${u(s.gutter,i)}${e}`}).join("\n");return n.message&&!h&&(y=`${" ".repeat(d+1)}${n.message}\n${y}`),i?a.reset(y):y}}).call(this,n(9))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});class r{constructor(e,t={}){this.label=e,this.keyword=t.keyword,this.beforeExpr=!!t.beforeExpr,this.startsExpr=!!t.startsExpr,this.rightAssociative=!!t.rightAssociative,this.isLoop=!!t.isLoop,this.isAssign=!!t.isAssign,this.prefix=!!t.prefix,this.postfix=!!t.postfix,this.binop=null!=t.binop?t.binop:null,this.updateContext=null}}const i=new Map;function o(e,t={}){t.keyword=e;const n=new r(e,t);return i.set(e,n),n}function a(e,t){return new r(e,{beforeExpr:!0,binop:t})}const s={num:new r("num",{startsExpr:!0}),bigint:new r("bigint",{startsExpr:!0}),regexp:new r("regexp",{startsExpr:!0}),string:new r("string",{startsExpr:!0}),name:new r("name",{startsExpr:!0}),eof:new r("eof"),bracketL:new r("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new r("]"),braceL:new r("{",{beforeExpr:!0,startsExpr:!0}),braceBarL:new r("{|",{beforeExpr:!0,startsExpr:!0}),braceR:new r("}"),braceBarR:new r("|}"),parenL:new r("(",{beforeExpr:!0,startsExpr:!0}),parenR:new r(")"),comma:new r(",",{beforeExpr:!0}),semi:new r(";",{beforeExpr:!0}),colon:new r(":",{beforeExpr:!0}),doubleColon:new r("::",{beforeExpr:!0}),dot:new r("."),question:new r("?",{beforeExpr:!0}),questionDot:new r("?."),arrow:new r("=>",{beforeExpr:!0}),template:new r("template"),ellipsis:new r("...",{beforeExpr:!0}),backQuote:new r("`",{startsExpr:!0}),dollarBraceL:new r("${",{beforeExpr:!0,startsExpr:!0}),at:new r("@"),hash:new r("#",{startsExpr:!0}),interpreterDirective:new r("#!..."),eq:new r("=",{beforeExpr:!0,isAssign:!0}),assign:new r("_=",{beforeExpr:!0,isAssign:!0}),incDec:new r("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),bang:new r("!",{beforeExpr:!0,prefix:!0,startsExpr:!0}),tilde:new r("~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),pipeline:a("|>",0),nullishCoalescing:a("??",1),logicalOR:a("||",2),logicalAND:a("&&",3),bitwiseOR:a("|",4),bitwiseXOR:a("^",5),bitwiseAND:a("&",6),equality:a("==/!=/===/!==",7),relational:a("/<=/>=",8),bitShift:a("<>/>>>",9),plusMin:new r("+/-",{beforeExpr:!0,binop:10,prefix:!0,startsExpr:!0}),modulo:new r("%",{beforeExpr:!0,binop:11,startsExpr:!0}),star:a("*",11),slash:a("/",11),exponent:new r("**",{beforeExpr:!0,binop:12,rightAssociative:!0}),_break:o("break"),_case:o("case",{beforeExpr:!0}),_catch:o("catch"),_continue:o("continue"),_debugger:o("debugger"),_default:o("default",{beforeExpr:!0}),_do:o("do",{isLoop:!0,beforeExpr:!0}),_else:o("else",{beforeExpr:!0}),_finally:o("finally"),_for:o("for",{isLoop:!0}),_function:o("function",{startsExpr:!0}),_if:o("if"),_return:o("return",{beforeExpr:!0}),_switch:o("switch"),_throw:o("throw",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_try:o("try"),_var:o("var"),_const:o("const"),_while:o("while",{isLoop:!0}),_with:o("with"),_new:o("new",{beforeExpr:!0,startsExpr:!0}),_this:o("this",{startsExpr:!0}),_super:o("super",{startsExpr:!0}),_class:o("class",{startsExpr:!0}),_extends:o("extends",{beforeExpr:!0}),_export:o("export"),_import:o("import",{startsExpr:!0}),_null:o("null",{startsExpr:!0}),_true:o("true",{startsExpr:!0}),_false:o("false",{startsExpr:!0}),_in:o("in",{beforeExpr:!0,binop:8}),_instanceof:o("instanceof",{beforeExpr:!0,binop:8}),_typeof:o("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:o("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:o("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})};function u(e,t){return 2|(e?4:0)|(t?8:0)}function c(e){return null!=e&&"Property"===e.type&&"init"===e.kind&&!1===e.method}const l=/\r\n?|[\n\u2028\u2029]/,f=new RegExp(l.source,"g");function p(e){switch(e){case 10:case 13:case 8232:case 8233:return!0;default:return!1}}const h=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g;function d(e){switch(e){case 9:case 11:case 12:case 32:case 160:case 5760:case 8192:case 8193:case 8194:case 8195:case 8196:case 8197:case 8198:case 8199:case 8200:case 8201:case 8202:case 8239:case 8287:case 12288:case 65279:return!0;default:return!1}}class y{constructor(e,t,n,r){this.token=e,this.isExpr=!!t,this.preserveSpace=!!n,this.override=r}}const m={braceStatement:new y("{",!1),braceExpression:new y("{",!0),templateQuasi:new y("${",!1),parenStatement:new y("(",!1),parenExpression:new y("(",!0),template:new y("`",!0,!0,e=>e.readTmplToken()),functionExpression:new y("function",!0),functionStatement:new y("function",!1)};s.parenR.updateContext=s.braceR.updateContext=function(){if(1===this.state.context.length)return void(this.state.exprAllowed=!0);let e=this.state.context.pop();e===m.braceStatement&&"function"===this.curContext().token&&(e=this.state.context.pop()),this.state.exprAllowed=!e.isExpr},s.name.updateContext=function(e){let t=!1;e!==s.dot&&("of"===this.state.value&&!this.state.exprAllowed||"yield"===this.state.value&&this.scope.inGenerator)&&(t=!0),this.state.exprAllowed=t,this.state.isIterator&&(this.state.isIterator=!1)},s.braceL.updateContext=function(e){this.state.context.push(this.braceIsBlock(e)?m.braceStatement:m.braceExpression),this.state.exprAllowed=!0},s.dollarBraceL.updateContext=function(){this.state.context.push(m.templateQuasi),this.state.exprAllowed=!0},s.parenL.updateContext=function(e){const t=e===s._if||e===s._for||e===s._with||e===s._while;this.state.context.push(t?m.parenStatement:m.parenExpression),this.state.exprAllowed=!0},s.incDec.updateContext=function(){},s._function.updateContext=s._class.updateContext=function(e){!e.beforeExpr||e===s.semi||e===s._else||e===s._return&&l.test(this.input.slice(this.state.lastTokEnd,this.state.start))||(e===s.colon||e===s.braceL)&&this.curContext()===m.b_stat?this.state.context.push(m.functionStatement):this.state.context.push(m.functionExpression),this.state.exprAllowed=!1},s.backQuote.updateContext=function(){this.curContext()===m.template?this.state.context.pop():this.state.context.push(m.template),this.state.exprAllowed=!1};const v=["eval","arguments"],b=new Set(["implements","interface","let","package","private","protected","public","static","yield"]),g=new Set(v),w=(e,t)=>t&&"await"===e||"enum"===e;function S(e,t){return w(e,t)||b.has(e)}function O(e){return g.has(e)}function P(e,t){return S(e,t)||O(e)}const k=/^in(stanceof)?$/;let x="ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࢠ-ࢴࢶ-ࢽऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೞೠೡೱೲഅ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜌᜎ-ᜑᜠ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭋᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-ᲈᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿯ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꞿꟂ-Ᶎꟷ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭧꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",E="‌‍·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛࣓-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍ୖୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ංඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-ໍ໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜔ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠐-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷹᷻-᷿‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_";const j=new RegExp("["+x+"]"),T=new RegExp("["+x+E+"]");x=E=null;const C=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,157,310,10,21,11,7,153,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,477,28,11,0,9,21,155,22,13,52,76,44,33,24,27,35,30,0,12,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,85,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,159,52,19,3,21,0,33,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,230,43,117,63,32,0,161,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,35,56,264,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,270,921,103,110,18,195,2749,1070,4050,582,8634,568,8,30,114,29,19,47,17,3,32,20,6,18,689,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,754,9486,286,50,2,18,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,2357,44,11,6,17,0,370,43,1301,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42710,42,4148,12,221,3,5761,15,7472,3104,541],_=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,525,10,176,2,54,14,32,9,16,3,46,10,54,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,4,9,83,11,7,0,161,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,193,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,84,14,5,9,243,14,166,9,232,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,406,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,19306,9,135,4,60,6,26,9,1014,0,2,54,8,3,19723,1,5319,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,262,6,10,9,419,13,1495,6,110,6,6,9,792487,239];function A(e,t){let n=65536;for(let r=0,i=t.length;re)return!1;if(n+=t[r+1],n>=e)return!0}return!1}function D(e){return e<65?36===e:e<=90||(e<97?95===e:e<=122||(e<=65535?e>=170&&j.test(String.fromCharCode(e)):A(e,C)))}function I(e){return e<48?36===e:e<58||!(e<65)&&(e<=90||(e<97?95===e:e<=122||(e<=65535?e>=170&&T.test(String.fromCharCode(e)):A(e,C)||A(e,_))))}const F=new Set(["_","any","bool","boolean","empty","extends","false","interface","mixed","null","number","static","string","true","typeof","void"]);function $(e){return"type"===e.importKind||"typeof"===e.importKind}function M(e){return(e.type===s.name||!!e.type.keyword)&&"from"!==e.value}const R={const:"declare export var",let:"declare export var",type:"export type",interface:"export interface"};const L=/\*?\s*@((?:no)?flow)\b/;const B={quot:'"',amp:"&",apos:"'",lt:"<",gt:">",nbsp:" ",iexcl:"¡",cent:"¢",pound:"£",curren:"¤",yen:"¥",brvbar:"¦",sect:"§",uml:"¨",copy:"©",ordf:"ª",laquo:"«",not:"¬",shy:"­",reg:"®",macr:"¯",deg:"°",plusmn:"±",sup2:"²",sup3:"³",acute:"´",micro:"µ",para:"¶",middot:"·",cedil:"¸",sup1:"¹",ordm:"º",raquo:"»",frac14:"¼",frac12:"½",frac34:"¾",iquest:"¿",Agrave:"À",Aacute:"Á",Acirc:"Â",Atilde:"Ã",Auml:"Ä",Aring:"Å",AElig:"Æ",Ccedil:"Ç",Egrave:"È",Eacute:"É",Ecirc:"Ê",Euml:"Ë",Igrave:"Ì",Iacute:"Í",Icirc:"Î",Iuml:"Ï",ETH:"Ð",Ntilde:"Ñ",Ograve:"Ò",Oacute:"Ó",Ocirc:"Ô",Otilde:"Õ",Ouml:"Ö",times:"×",Oslash:"Ø",Ugrave:"Ù",Uacute:"Ú",Ucirc:"Û",Uuml:"Ü",Yacute:"Ý",THORN:"Þ",szlig:"ß",agrave:"à",aacute:"á",acirc:"â",atilde:"ã",auml:"ä",aring:"å",aelig:"æ",ccedil:"ç",egrave:"è",eacute:"é",ecirc:"ê",euml:"ë",igrave:"ì",iacute:"í",icirc:"î",iuml:"ï",eth:"ð",ntilde:"ñ",ograve:"ò",oacute:"ó",ocirc:"ô",otilde:"õ",ouml:"ö",divide:"÷",oslash:"ø",ugrave:"ù",uacute:"ú",ucirc:"û",uuml:"ü",yacute:"ý",thorn:"þ",yuml:"ÿ",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",fnof:"ƒ",circ:"ˆ",tilde:"˜",Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigmaf:"ς",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",chi:"χ",psi:"ψ",omega:"ω",thetasym:"ϑ",upsih:"ϒ",piv:"ϖ",ensp:" ",emsp:" ",thinsp:" ",zwnj:"‌",zwj:"‍",lrm:"‎",rlm:"‏",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",bull:"•",hellip:"…",permil:"‰",prime:"′",Prime:"″",lsaquo:"‹",rsaquo:"›",oline:"‾",frasl:"⁄",euro:"€",image:"ℑ",weierp:"℘",real:"ℜ",trade:"™",alefsym:"ℵ",larr:"←",uarr:"↑",rarr:"→",darr:"↓",harr:"↔",crarr:"↵",lArr:"⇐",uArr:"⇑",rArr:"⇒",dArr:"⇓",hArr:"⇔",forall:"∀",part:"∂",exist:"∃",empty:"∅",nabla:"∇",isin:"∈",notin:"∉",ni:"∋",prod:"∏",sum:"∑",minus:"−",lowast:"∗",radic:"√",prop:"∝",infin:"∞",ang:"∠",and:"∧",or:"∨",cap:"∩",cup:"∪",int:"∫",there4:"∴",sim:"∼",cong:"≅",asymp:"≈",ne:"≠",equiv:"≡",le:"≤",ge:"≥",sub:"⊂",sup:"⊃",nsub:"⊄",sube:"⊆",supe:"⊇",oplus:"⊕",otimes:"⊗",perp:"⊥",sdot:"⋅",lceil:"⌈",rceil:"⌉",lfloor:"⌊",rfloor:"⌋",lang:"〈",rang:"〉",loz:"◊",spades:"♠",clubs:"♣",hearts:"♥",diams:"♦"},N=/^[\da-fA-F]+$/,V=/^\d+$/;function z(e){return!!e&&("JSXOpeningFragment"===e.type||"JSXClosingFragment"===e.type)}function G(e){if("JSXIdentifier"===e.type)return e.name;if("JSXNamespacedName"===e.type)return e.namespace.name+":"+e.name.name;if("JSXMemberExpression"===e.type)return G(e.object)+"."+G(e.property);throw new Error("Node had unexpected type: "+e.type)}m.j_oTag=new y("...",!0,!0),s.jsxName=new r("jsxName"),s.jsxText=new r("jsxText",{beforeExpr:!0}),s.jsxTagStart=new r("jsxTagStart",{startsExpr:!0}),s.jsxTagEnd=new r("jsxTagEnd"),s.jsxTagStart.updateContext=function(){this.state.context.push(m.j_expr),this.state.context.push(m.j_oTag),this.state.exprAllowed=!1},s.jsxTagEnd.updateContext=function(e){const t=this.state.context.pop();t===m.j_oTag&&e===s.slash||t===m.j_cTag?(this.state.context.pop(),this.state.exprAllowed=this.curContext()===m.j_expr):this.state.exprAllowed=!0};class H{constructor(e){this.var=[],this.lexical=[],this.functions=[],this.flags=e}}class U{constructor(e,t){this.scopeStack=[],this.undefinedExports=new Map,this.raise=e,this.inModule=t}get inFunction(){return(2&this.currentVarScope().flags)>0}get inGenerator(){return(8&this.currentVarScope().flags)>0}get inAsync(){return(4&this.currentVarScope().flags)>0}get allowSuper(){return(64&this.currentThisScope().flags)>0}get allowDirectSuper(){return(128&this.currentThisScope().flags)>0}get inClass(){return(256&this.currentThisScope().flags)>0}get inNonArrowFunction(){return(2&this.currentThisScope().flags)>0}get treatFunctionsAsVar(){return this.treatFunctionsAsVarInScope(this.currentScope())}createScope(e){return new H(e)}enter(e){this.scopeStack.push(this.createScope(e))}exit(){this.scopeStack.pop()}treatFunctionsAsVarInScope(e){return!!(2&e.flags||!this.inModule&&1&e.flags)}declareName(e,t,n){let r=this.currentScope();if(8&t||16&t)this.checkRedeclarationInScope(r,e,t,n),16&t?r.functions.push(e):r.lexical.push(e),8&t&&this.maybeExportDefined(r,e);else if(4&t)for(let i=this.scopeStack.length-1;i>=0&&(r=this.scopeStack[i],this.checkRedeclarationInScope(r,e,t,n),r.var.push(e),this.maybeExportDefined(r,e),!(515&r.flags));--i);this.inModule&&1&r.flags&&this.undefinedExports.delete(e)}maybeExportDefined(e,t){this.inModule&&1&e.flags&&this.undefinedExports.delete(t)}checkRedeclarationInScope(e,t,n,r){this.isRedeclaredInScope(e,t,n)&&this.raise(r,`Identifier '${t}' has already been declared`)}isRedeclaredInScope(e,t,n){return!!(1&n)&&(8&n?e.lexical.indexOf(t)>-1||e.functions.indexOf(t)>-1||e.var.indexOf(t)>-1:16&n?e.lexical.indexOf(t)>-1||!this.treatFunctionsAsVarInScope(e)&&e.var.indexOf(t)>-1:e.lexical.indexOf(t)>-1&&!(32&e.flags&&e.lexical[0]===t)||!this.treatFunctionsAsVarInScope(e)&&e.functions.indexOf(t)>-1)}checkLocalExport(e){-1===this.scopeStack[0].lexical.indexOf(e.name)&&-1===this.scopeStack[0].var.indexOf(e.name)&&-1===this.scopeStack[0].functions.indexOf(e.name)&&this.undefinedExports.set(e.name,e.start)}currentScope(){return this.scopeStack[this.scopeStack.length-1]}currentVarScope(){for(let e=this.scopeStack.length-1;;e--){const t=this.scopeStack[e];if(515&t.flags)return t}}currentThisScope(){for(let e=this.scopeStack.length-1;;e--){const t=this.scopeStack[e];if((515&t.flags||256&t.flags)&&!(16&t.flags))return t}}}class Y extends H{constructor(...e){super(...e),this.types=[],this.enums=[],this.constEnums=[],this.classes=[],this.exportOnlyBindings=[]}}class W extends U{createScope(e){return new Y(e)}declareName(e,t,n){const r=this.currentScope();if(1024&t)return this.maybeExportDefined(r,e),void r.exportOnlyBindings.push(e);super.declareName(...arguments),2&t&&(1&t||(this.checkRedeclarationInScope(r,e,t,n),this.maybeExportDefined(r,e)),r.types.push(e)),256&t&&r.enums.push(e),512&t&&r.constEnums.push(e),128&t&&r.classes.push(e)}isRedeclaredInScope(e,t,n){if(e.enums.indexOf(t)>-1){if(256&n){return!!(512&n)!==e.constEnums.indexOf(t)>-1}return!0}return 128&n&&e.classes.indexOf(t)>-1?e.lexical.indexOf(t)>-1&&!!(1&n):!!(2&n&&e.types.indexOf(t)>-1)||super.isRedeclaredInScope(...arguments)}checkLocalExport(e){-1===this.scopeStack[0].types.indexOf(e.name)&&-1===this.scopeStack[0].exportOnlyBindings.indexOf(e.name)&&super.checkLocalExport(e)}}function X(e){if(null==e)throw new Error(`Unexpected ${e} value.`);return e}function K(e){if(!e)throw new Error("Assert fail")}s.placeholder=new r("%%",{startsExpr:!0});function q(e,t){return e.some(e=>Array.isArray(e)?e[0]===t:e===t)}function J(e,t,n){const r=e.find(e=>Array.isArray(e)?e[0]===t:e===t);return r&&Array.isArray(r)?r[1][n]:null}const Z=["minimal","smart","fsharp"];const Q={estree:e=>class extends e{estreeParseRegExpLiteral({pattern:e,flags:t}){let n=null;try{n=new RegExp(e,t)}catch(e){}const r=this.estreeParseLiteral(n);return r.regex={pattern:e,flags:t},r}estreeParseLiteral(e){return this.parseLiteral(e,"Literal")}directiveToStmt(e){const t=e.value,n=this.startNodeAt(e.start,e.loc.start),r=this.startNodeAt(t.start,t.loc.start);return r.value=t.value,r.raw=t.extra.raw,n.expression=this.finishNodeAt(r,"Literal",t.end,t.loc.end),n.directive=t.extra.raw.slice(1,-1),this.finishNodeAt(n,"ExpressionStatement",e.end,e.loc.end)}initFunction(e,t){super.initFunction(e,t),e.expression=!1}checkDeclaration(e){c(e)?this.checkDeclaration(e.value):super.checkDeclaration(e)}checkGetterSetterParams(e){const t=e,n="get"===t.kind?0:1,r=t.start;t.value.params.length!==n?"get"===t.kind?this.raise(r,"getter must not have any formal parameters"):this.raise(r,"setter must have exactly one formal parameter"):"set"===t.kind&&"RestElement"===t.value.params[0].type&&this.raise(r,"setter function argument must not be a rest parameter")}checkLVal(e,t=64,n,r,i){switch(e.type){case"ObjectPattern":e.properties.forEach(e=>{this.checkLVal("Property"===e.type?e.value:e,t,n,"object destructuring pattern",i)});break;default:super.checkLVal(e,t,n,r,i)}}checkDuplicatedProto(e,t){if("SpreadElement"===e.type||e.computed||e.method||e.shorthand)return;const n=e.key;"__proto__"===("Identifier"===n.type?n.name:String(n.value))&&"init"===e.kind&&(t.used&&!t.start&&(t.start=n.start),t.used=!0)}isStrictBody(e){if("BlockStatement"===e.body.type&&e.body.body.length>0)for(let t=0,n=e.body.body;tthis.directiveToStmt(e));e.body=i.concat(e.body),delete e.directives}pushClassMethod(e,t,n,r,i,o){this.parseMethod(t,n,r,i,o,"ClassMethod",!0),t.typeParameters&&(t.value.typeParameters=t.typeParameters,delete t.typeParameters),e.body.push(t)}parseExprAtom(e){switch(this.state.type){case s.regexp:return this.estreeParseRegExpLiteral(this.state.value);case s.num:case s.string:return this.estreeParseLiteral(this.state.value);case s._null:return this.estreeParseLiteral(null);case s._true:return this.estreeParseLiteral(!0);case s._false:return this.estreeParseLiteral(!1);default:return super.parseExprAtom(e)}}parseLiteral(e,t,n,r){const i=super.parseLiteral(e,t,n,r);return i.raw=i.extra.raw,delete i.extra,i}parseFunctionBody(e,t,n=!1){super.parseFunctionBody(e,t,n),e.expression="BlockStatement"!==e.body.type}parseMethod(e,t,n,r,i,o,a=!1){let s=this.startNode();return s.kind=e.kind,s=super.parseMethod(s,t,n,r,i,o,a),s.type="FunctionExpression",delete s.kind,e.value=s,o="ClassMethod"===o?"MethodDefinition":o,this.finishNode(e,o)}parseObjectMethod(e,t,n,r,i){const o=super.parseObjectMethod(e,t,n,r,i);return o&&(o.type="Property","method"===o.kind&&(o.kind="init"),o.shorthand=!1),o}parseObjectProperty(e,t,n,r,i){const o=super.parseObjectProperty(e,t,n,r,i);return o&&(o.kind="init",o.type="Property"),o}toAssignable(e,t,n){return c(e)?(this.toAssignable(e.value,t,n),e):super.toAssignable(e,t,n)}toAssignableObjectExpressionProp(e,t,n){if("get"===e.kind||"set"===e.kind)throw this.raise(e.key.start,"Object pattern can't contain getter or setter");if(e.method)throw this.raise(e.key.start,"Object pattern can't contain methods");super.toAssignableObjectExpressionProp(e,t,n)}},jsx:e=>class extends e{jsxReadToken(){let e="",t=this.state.pos;for(;;){if(this.state.pos>=this.length)throw this.raise(this.state.start,"Unterminated JSX contents");const n=this.input.charCodeAt(this.state.pos);switch(n){case 60:case 123:return this.state.pos===this.state.start?60===n&&this.state.exprAllowed?(++this.state.pos,this.finishToken(s.jsxTagStart)):super.getTokenFromCode(n):(e+=this.input.slice(t,this.state.pos),this.finishToken(s.jsxText,e));case 38:e+=this.input.slice(t,this.state.pos),e+=this.jsxReadEntity(),t=this.state.pos;break;default:p(n)?(e+=this.input.slice(t,this.state.pos),e+=this.jsxReadNewLine(!0),t=this.state.pos):++this.state.pos}}}jsxReadNewLine(e){const t=this.input.charCodeAt(this.state.pos);let n;return++this.state.pos,13===t&&10===this.input.charCodeAt(this.state.pos)?(++this.state.pos,n=e?"\n":"\r\n"):n=String.fromCharCode(t),++this.state.curLine,this.state.lineStart=this.state.pos,n}jsxReadString(e){let t="",n=++this.state.pos;for(;;){if(this.state.pos>=this.length)throw this.raise(this.state.start,"Unterminated string constant");const r=this.input.charCodeAt(this.state.pos);if(r===e)break;38===r?(t+=this.input.slice(n,this.state.pos),t+=this.jsxReadEntity(),n=this.state.pos):p(r)?(t+=this.input.slice(n,this.state.pos),t+=this.jsxReadNewLine(!1),n=this.state.pos):++this.state.pos}return t+=this.input.slice(n,this.state.pos++),this.finishToken(s.string,t)}jsxReadEntity(){let e,t="",n=0,r=this.input[this.state.pos];const i=++this.state.pos;for(;this.state.pos"):!z(i)&&z(o)?this.raise(o.start,"Expected corresponding JSX closing tag for <"+G(i.name)+">"):z(i)||z(o)||G(o.name)!==G(i.name)&&this.raise(o.start,"Expected corresponding JSX closing tag for <"+G(i.name)+">")}if(z(i)?(n.openingFragment=i,n.closingFragment=o):(n.openingElement=i,n.closingElement=o),n.children=r,this.isRelational("<"))throw this.raise(this.state.start,"Adjacent JSX elements must be wrapped in an enclosing tag. Did you want a JSX fragment <>...?");return z(i)?this.finishNode(n,"JSXFragment"):this.finishNode(n,"JSXElement")}jsxParseElement(){const e=this.state.start,t=this.state.startLoc;return this.next(),this.jsxParseElementAt(e,t)}parseExprAtom(e){return this.match(s.jsxText)?this.parseLiteral(this.state.value,"JSXText"):this.match(s.jsxTagStart)?this.jsxParseElement():this.isRelational("<")&&33!==this.input.charCodeAt(this.state.pos)?(this.finishToken(s.jsxTagStart),this.jsxParseElement()):super.parseExprAtom(e)}getTokenFromCode(e){if(this.state.inPropertyName)return super.getTokenFromCode(e);const t=this.curContext();if(t===m.j_expr)return this.jsxReadToken();if(t===m.j_oTag||t===m.j_cTag){if(D(e))return this.jsxReadWord();if(62===e)return++this.state.pos,this.finishToken(s.jsxTagEnd);if((34===e||39===e)&&t===m.j_oTag)return this.jsxReadString(e)}return 60===e&&this.state.exprAllowed&&33!==this.input.charCodeAt(this.state.pos+1)?(++this.state.pos,this.finishToken(s.jsxTagStart)):super.getTokenFromCode(e)}updateContext(e){if(this.match(s.braceL)){const t=this.curContext();t===m.j_oTag?this.state.context.push(m.braceExpression):t===m.j_expr?this.state.context.push(m.templateQuasi):super.updateContext(e),this.state.exprAllowed=!0}else{if(!this.match(s.slash)||e!==s.jsxTagStart)return super.updateContext(e);this.state.context.length-=2,this.state.context.push(m.j_cTag),this.state.exprAllowed=!1}}},flow:e=>class extends e{constructor(e,t){super(e,t),this.flowPragma=void 0}shouldParseTypes(){return this.getPluginOption("flow","all")||"flow"===this.flowPragma}shouldParseEnums(){return!!this.getPluginOption("flow","enums")}finishToken(e,t){return e!==s.string&&e!==s.semi&&e!==s.interpreterDirective&&void 0===this.flowPragma&&(this.flowPragma=null),super.finishToken(e,t)}addComment(e){if(void 0===this.flowPragma){const t=L.exec(e.value);if(t)if("flow"===t[1])this.flowPragma="flow";else{if("noflow"!==t[1])throw new Error("Unexpected flow pragma");this.flowPragma="noflow"}else;}return super.addComment(e)}flowParseTypeInitialiser(e){const t=this.state.inType;this.state.inType=!0,this.expect(e||s.colon);const n=this.flowParseType();return this.state.inType=t,n}flowParsePredicate(){const e=this.startNode(),t=this.state.startLoc,n=this.state.start;this.expect(s.modulo);const r=this.state.startLoc;return this.expectContextual("checks"),t.line===r.line&&t.column===r.column-1||this.raise(n,"Spaces between ´%´ and ´checks´ are not allowed here."),this.eat(s.parenL)?(e.value=this.parseExpression(),this.expect(s.parenR),this.finishNode(e,"DeclaredPredicate")):this.finishNode(e,"InferredPredicate")}flowParseTypeAndPredicateInitialiser(){const e=this.state.inType;this.state.inType=!0,this.expect(s.colon);let t=null,n=null;return this.match(s.modulo)?(this.state.inType=e,n=this.flowParsePredicate()):(t=this.flowParseType(),this.state.inType=e,this.match(s.modulo)&&(n=this.flowParsePredicate())),[t,n]}flowParseDeclareClass(e){return this.next(),this.flowParseInterfaceish(e,!0),this.finishNode(e,"DeclareClass")}flowParseDeclareFunction(e){this.next();const t=e.id=this.parseIdentifier(),n=this.startNode(),r=this.startNode();this.isRelational("<")?n.typeParameters=this.flowParseTypeParameterDeclaration():n.typeParameters=null,this.expect(s.parenL);const i=this.flowParseFunctionTypeParams();return n.params=i.params,n.rest=i.rest,this.expect(s.parenR),[n.returnType,e.predicate]=this.flowParseTypeAndPredicateInitialiser(),r.typeAnnotation=this.finishNode(n,"FunctionTypeAnnotation"),t.typeAnnotation=this.finishNode(r,"TypeAnnotation"),this.resetEndLocation(t),this.semicolon(),this.finishNode(e,"DeclareFunction")}flowParseDeclare(e,t){if(this.match(s._class))return this.flowParseDeclareClass(e);if(this.match(s._function))return this.flowParseDeclareFunction(e);if(this.match(s._var))return this.flowParseDeclareVariable(e);if(this.eatContextual("module"))return this.match(s.dot)?this.flowParseDeclareModuleExports(e):(t&&this.raise(this.state.lastTokStart,"`declare module` cannot be used inside another `declare module`"),this.flowParseDeclareModule(e));if(this.isContextual("type"))return this.flowParseDeclareTypeAlias(e);if(this.isContextual("opaque"))return this.flowParseDeclareOpaqueType(e);if(this.isContextual("interface"))return this.flowParseDeclareInterface(e);if(this.match(s._export))return this.flowParseDeclareExportDeclaration(e,t);throw this.unexpected()}flowParseDeclareVariable(e){return this.next(),e.id=this.flowParseTypeAnnotatableIdentifier(!0),this.scope.declareName(e.id.name,5,e.id.start),this.semicolon(),this.finishNode(e,"DeclareVariable")}flowParseDeclareModule(e){this.scope.enter(0),this.match(s.string)?e.id=this.parseExprAtom():e.id=this.parseIdentifier();const t=e.body=this.startNode(),n=t.body=[];for(this.expect(s.braceL);!this.match(s.braceR);){let e=this.startNode();this.match(s._import)?(this.next(),this.isContextual("type")||this.match(s._typeof)||this.raise(this.state.lastTokStart,"Imports within a `declare module` body must always be `import type` or `import typeof`"),this.parseImport(e)):(this.expectContextual("declare","Only declares and type imports are allowed inside declare module"),e=this.flowParseDeclare(e,!0)),n.push(e)}this.scope.exit(),this.expect(s.braceR),this.finishNode(t,"BlockStatement");let r=null,i=!1;const o="Found both `declare module.exports` and `declare export` in the same module. Modules can only have 1 since they are either an ES module or they are a CommonJS module";return n.forEach(e=>{!function(e){return"DeclareExportAllDeclaration"===e.type||"DeclareExportDeclaration"===e.type&&(!e.declaration||"TypeAlias"!==e.declaration.type&&"InterfaceDeclaration"!==e.declaration.type)}(e)?"DeclareModuleExports"===e.type&&(i&&this.raise(e.start,"Duplicate `declare module.exports` statement"),"ES"===r&&this.raise(e.start,o),r="CommonJS",i=!0):("CommonJS"===r&&this.raise(e.start,o),r="ES")}),e.kind=r||"CommonJS",this.finishNode(e,"DeclareModule")}flowParseDeclareExportDeclaration(e,t){if(this.expect(s._export),this.eat(s._default))return this.match(s._function)||this.match(s._class)?e.declaration=this.flowParseDeclare(this.startNode()):(e.declaration=this.flowParseType(),this.semicolon()),e.default=!0,this.finishNode(e,"DeclareExportDeclaration");if(this.match(s._const)||this.isLet()||(this.isContextual("type")||this.isContextual("interface"))&&!t){const e=this.state.value,t=R[e];this.unexpected(this.state.start,`\`declare export ${e}\` is not supported. Use \`${t}\` instead`)}if(this.match(s._var)||this.match(s._function)||this.match(s._class)||this.isContextual("opaque"))return e.declaration=this.flowParseDeclare(this.startNode()),e.default=!1,this.finishNode(e,"DeclareExportDeclaration");if(this.match(s.star)||this.match(s.braceL)||this.isContextual("interface")||this.isContextual("type")||this.isContextual("opaque"))return"ExportNamedDeclaration"===(e=this.parseExport(e)).type&&(e.type="ExportDeclaration",e.default=!1,delete e.exportKind),e.type="Declare"+e.type,e;throw this.unexpected()}flowParseDeclareModuleExports(e){return this.next(),this.expectContextual("exports"),e.typeAnnotation=this.flowParseTypeAnnotation(),this.semicolon(),this.finishNode(e,"DeclareModuleExports")}flowParseDeclareTypeAlias(e){return this.next(),this.flowParseTypeAlias(e),e.type="DeclareTypeAlias",e}flowParseDeclareOpaqueType(e){return this.next(),this.flowParseOpaqueType(e,!0),e.type="DeclareOpaqueType",e}flowParseDeclareInterface(e){return this.next(),this.flowParseInterfaceish(e),this.finishNode(e,"DeclareInterface")}flowParseInterfaceish(e,t=!1){if(e.id=this.flowParseRestrictedIdentifier(!t,!0),this.scope.declareName(e.id.name,t?17:9,e.id.start),this.isRelational("<")?e.typeParameters=this.flowParseTypeParameterDeclaration():e.typeParameters=null,e.extends=[],e.implements=[],e.mixins=[],this.eat(s._extends))do{e.extends.push(this.flowParseInterfaceExtends())}while(!t&&this.eat(s.comma));if(this.isContextual("mixins")){this.next();do{e.mixins.push(this.flowParseInterfaceExtends())}while(this.eat(s.comma))}if(this.isContextual("implements")){this.next();do{e.implements.push(this.flowParseInterfaceExtends())}while(this.eat(s.comma))}e.body=this.flowParseObjectType({allowStatic:t,allowExact:!1,allowSpread:!1,allowProto:t,allowInexact:!1})}flowParseInterfaceExtends(){const e=this.startNode();return e.id=this.flowParseQualifiedTypeIdentifier(),this.isRelational("<")?e.typeParameters=this.flowParseTypeParameterInstantiation():e.typeParameters=null,this.finishNode(e,"InterfaceExtends")}flowParseInterface(e){return this.flowParseInterfaceish(e),this.finishNode(e,"InterfaceDeclaration")}checkNotUnderscore(e){"_"===e&&this.raise(this.state.start,"`_` is only allowed as a type argument to call or new")}checkReservedType(e,t,n){F.has(e)&&(n?this.raise(t,`Cannot overwrite reserved type ${e}`):this.raise(t,`Unexpected reserved type ${e}`))}flowParseRestrictedIdentifier(e,t){return this.checkReservedType(this.state.value,this.state.start,t),this.parseIdentifier(e)}flowParseTypeAlias(e){return e.id=this.flowParseRestrictedIdentifier(!1,!0),this.scope.declareName(e.id.name,9,e.id.start),this.isRelational("<")?e.typeParameters=this.flowParseTypeParameterDeclaration():e.typeParameters=null,e.right=this.flowParseTypeInitialiser(s.eq),this.semicolon(),this.finishNode(e,"TypeAlias")}flowParseOpaqueType(e,t){return this.expectContextual("type"),e.id=this.flowParseRestrictedIdentifier(!0,!0),this.scope.declareName(e.id.name,9,e.id.start),this.isRelational("<")?e.typeParameters=this.flowParseTypeParameterDeclaration():e.typeParameters=null,e.supertype=null,this.match(s.colon)&&(e.supertype=this.flowParseTypeInitialiser(s.colon)),e.impltype=null,t||(e.impltype=this.flowParseTypeInitialiser(s.eq)),this.semicolon(),this.finishNode(e,"OpaqueType")}flowParseTypeParameter(e=!1){const t=this.state.start,n=this.startNode(),r=this.flowParseVariance(),i=this.flowParseTypeAnnotatableIdentifier();return n.name=i.name,n.variance=r,n.bound=i.typeAnnotation,this.match(s.eq)?(this.eat(s.eq),n.default=this.flowParseType()):e&&this.raise(t,"Type parameter declaration needs a default, since a preceding type parameter declaration has a default."),this.finishNode(n,"TypeParameter")}flowParseTypeParameterDeclaration(){const e=this.state.inType,t=this.startNode();t.params=[],this.state.inType=!0,this.isRelational("<")||this.match(s.jsxTagStart)?this.next():this.unexpected();let n=!1;do{const e=this.flowParseTypeParameter(n);t.params.push(e),e.default&&(n=!0),this.isRelational(">")||this.expect(s.comma)}while(!this.isRelational(">"));return this.expectRelational(">"),this.state.inType=e,this.finishNode(t,"TypeParameterDeclaration")}flowParseTypeParameterInstantiation(){const e=this.startNode(),t=this.state.inType;e.params=[],this.state.inType=!0,this.expectRelational("<");const n=this.state.noAnonFunctionType;for(this.state.noAnonFunctionType=!1;!this.isRelational(">");)e.params.push(this.flowParseType()),this.isRelational(">")||this.expect(s.comma);return this.state.noAnonFunctionType=n,this.expectRelational(">"),this.state.inType=t,this.finishNode(e,"TypeParameterInstantiation")}flowParseTypeParameterInstantiationCallOrNew(){const e=this.startNode(),t=this.state.inType;for(e.params=[],this.state.inType=!0,this.expectRelational("<");!this.isRelational(">");)e.params.push(this.flowParseTypeOrImplicitInstantiation()),this.isRelational(">")||this.expect(s.comma);return this.expectRelational(">"),this.state.inType=t,this.finishNode(e,"TypeParameterInstantiation")}flowParseInterfaceType(){const e=this.startNode();if(this.expectContextual("interface"),e.extends=[],this.eat(s._extends))do{e.extends.push(this.flowParseInterfaceExtends())}while(this.eat(s.comma));return e.body=this.flowParseObjectType({allowStatic:!1,allowExact:!1,allowSpread:!1,allowProto:!1,allowInexact:!1}),this.finishNode(e,"InterfaceTypeAnnotation")}flowParseObjectPropertyKey(){return this.match(s.num)||this.match(s.string)?this.parseExprAtom():this.parseIdentifier(!0)}flowParseObjectTypeIndexer(e,t,n){return e.static=t,this.lookahead().type===s.colon?(e.id=this.flowParseObjectPropertyKey(),e.key=this.flowParseTypeInitialiser()):(e.id=null,e.key=this.flowParseType()),this.expect(s.bracketR),e.value=this.flowParseTypeInitialiser(),e.variance=n,this.finishNode(e,"ObjectTypeIndexer")}flowParseObjectTypeInternalSlot(e,t){return e.static=t,e.id=this.flowParseObjectPropertyKey(),this.expect(s.bracketR),this.expect(s.bracketR),this.isRelational("<")||this.match(s.parenL)?(e.method=!0,e.optional=!1,e.value=this.flowParseObjectTypeMethodish(this.startNodeAt(e.start,e.loc.start))):(e.method=!1,this.eat(s.question)&&(e.optional=!0),e.value=this.flowParseTypeInitialiser()),this.finishNode(e,"ObjectTypeInternalSlot")}flowParseObjectTypeMethodish(e){for(e.params=[],e.rest=null,e.typeParameters=null,this.isRelational("<")&&(e.typeParameters=this.flowParseTypeParameterDeclaration()),this.expect(s.parenL);!this.match(s.parenR)&&!this.match(s.ellipsis);)e.params.push(this.flowParseFunctionTypeParam()),this.match(s.parenR)||this.expect(s.comma);return this.eat(s.ellipsis)&&(e.rest=this.flowParseFunctionTypeParam()),this.expect(s.parenR),e.returnType=this.flowParseTypeInitialiser(),this.finishNode(e,"FunctionTypeAnnotation")}flowParseObjectTypeCallProperty(e,t){const n=this.startNode();return e.static=t,e.value=this.flowParseObjectTypeMethodish(n),this.finishNode(e,"ObjectTypeCallProperty")}flowParseObjectType({allowStatic:e,allowExact:t,allowSpread:n,allowProto:r,allowInexact:i}){const o=this.state.inType;this.state.inType=!0;const a=this.startNode();let u,c;a.callProperties=[],a.properties=[],a.indexers=[],a.internalSlots=[];let l=!1;for(t&&this.match(s.braceBarL)?(this.expect(s.braceBarL),u=s.braceBarR,c=!0):(this.expect(s.braceL),u=s.braceR,c=!1),a.exact=c;!this.match(u);){let t=!1,o=null,u=null;const p=this.startNode();if(r&&this.isContextual("proto")){const t=this.lookahead();t.type!==s.colon&&t.type!==s.question&&(this.next(),o=this.state.start,e=!1)}if(e&&this.isContextual("static")){const e=this.lookahead();e.type!==s.colon&&e.type!==s.question&&(this.next(),t=!0)}const h=this.flowParseVariance();if(this.eat(s.bracketL))null!=o&&this.unexpected(o),this.eat(s.bracketL)?(h&&this.unexpected(h.start),a.internalSlots.push(this.flowParseObjectTypeInternalSlot(p,t))):a.indexers.push(this.flowParseObjectTypeIndexer(p,t,h));else if(this.match(s.parenL)||this.isRelational("<"))null!=o&&this.unexpected(o),h&&this.unexpected(h.start),a.callProperties.push(this.flowParseObjectTypeCallProperty(p,t));else{var f;let e="init";if(this.isContextual("get")||this.isContextual("set")){const t=this.lookahead();t.type!==s.name&&t.type!==s.string&&t.type!==s.num||(e=this.state.value,this.next())}const r=this.flowParseObjectTypeProperty(p,t,o,h,e,n,null!=(f=i)?f:!c);null===r?(l=!0,u=this.state.lastTokStart):a.properties.push(r)}this.flowObjectTypeSemicolon(),!u||this.match(s.braceR)||this.match(s.braceBarR)||this.raise(u,"Explicit inexact syntax must appear at the end of an inexact object")}this.expect(u),n&&(a.inexact=l);const p=this.finishNode(a,"ObjectTypeAnnotation");return this.state.inType=o,p}flowParseObjectTypeProperty(e,t,n,r,i,o,a){if(this.eat(s.ellipsis)){return this.match(s.comma)||this.match(s.semi)||this.match(s.braceR)||this.match(s.braceBarR)?(o?a||this.raise(this.state.lastTokStart,"Explicit inexact syntax cannot appear inside an explicit exact object type"):this.raise(this.state.lastTokStart,"Explicit inexact syntax cannot appear in class or interface definitions"),r&&this.raise(r.start,"Explicit inexact syntax cannot have variance"),null):(o||this.raise(this.state.lastTokStart,"Spread operator cannot appear in class or interface definitions"),null!=n&&this.unexpected(n),r&&this.raise(r.start,"Spread properties cannot have variance"),e.argument=this.flowParseType(),this.finishNode(e,"ObjectTypeSpreadProperty"))}{e.key=this.flowParseObjectPropertyKey(),e.static=t,e.proto=null!=n,e.kind=i;let o=!1;return this.isRelational("<")||this.match(s.parenL)?(e.method=!0,null!=n&&this.unexpected(n),r&&this.unexpected(r.start),e.value=this.flowParseObjectTypeMethodish(this.startNodeAt(e.start,e.loc.start)),"get"!==i&&"set"!==i||this.flowCheckGetterSetterParams(e)):("init"!==i&&this.unexpected(),e.method=!1,this.eat(s.question)&&(o=!0),e.value=this.flowParseTypeInitialiser(),e.variance=r),e.optional=o,this.finishNode(e,"ObjectTypeProperty")}}flowCheckGetterSetterParams(e){const t="get"===e.kind?0:1,n=e.start;e.value.params.length+(e.value.rest?1:0)!==t&&("get"===e.kind?this.raise(n,"getter must not have any formal parameters"):this.raise(n,"setter must have exactly one formal parameter")),"set"===e.kind&&e.value.rest&&this.raise(n,"setter function argument must not be a rest parameter")}flowObjectTypeSemicolon(){this.eat(s.semi)||this.eat(s.comma)||this.match(s.braceR)||this.match(s.braceBarR)||this.unexpected()}flowParseQualifiedTypeIdentifier(e,t,n){e=e||this.state.start,t=t||this.state.startLoc;let r=n||this.flowParseRestrictedIdentifier(!0);for(;this.eat(s.dot);){const n=this.startNodeAt(e,t);n.qualification=r,n.id=this.flowParseRestrictedIdentifier(!0),r=this.finishNode(n,"QualifiedTypeIdentifier")}return r}flowParseGenericType(e,t,n){const r=this.startNodeAt(e,t);return r.typeParameters=null,r.id=this.flowParseQualifiedTypeIdentifier(e,t,n),this.isRelational("<")&&(r.typeParameters=this.flowParseTypeParameterInstantiation()),this.finishNode(r,"GenericTypeAnnotation")}flowParseTypeofType(){const e=this.startNode();return this.expect(s._typeof),e.argument=this.flowParsePrimaryType(),this.finishNode(e,"TypeofTypeAnnotation")}flowParseTupleType(){const e=this.startNode();for(e.types=[],this.expect(s.bracketL);this.state.possuper.parseFunctionBody(e,!0,n)):super.parseFunctionBody(e,!1,n)}parseFunctionBodyAndFinish(e,t,n=!1){if(this.match(s.colon)){const t=this.startNode();[t.typeAnnotation,e.predicate]=this.flowParseTypeAndPredicateInitialiser(),e.returnType=t.typeAnnotation?this.finishNode(t,"TypeAnnotation"):null}super.parseFunctionBodyAndFinish(e,t,n)}parseStatement(e,t){if(this.state.strict&&this.match(s.name)&&"interface"===this.state.value){const e=this.startNode();return this.next(),this.flowParseInterface(e)}if(this.shouldParseEnums()&&this.isContextual("enum")){const e=this.startNode();return this.next(),this.flowParseEnumDeclaration(e)}{const n=super.parseStatement(e,t);return void 0!==this.flowPragma||this.isValidDirective(n)||(this.flowPragma=null),n}}parseExpressionStatement(e,t){if("Identifier"===t.type)if("declare"===t.name){if(this.match(s._class)||this.match(s.name)||this.match(s._function)||this.match(s._var)||this.match(s._export))return this.flowParseDeclare(e)}else if(this.match(s.name)){if("interface"===t.name)return this.flowParseInterface(e);if("type"===t.name)return this.flowParseTypeAlias(e);if("opaque"===t.name)return this.flowParseOpaqueType(e,!1)}return super.parseExpressionStatement(e,t)}shouldParseExportDeclaration(){return this.isContextual("type")||this.isContextual("interface")||this.isContextual("opaque")||this.shouldParseEnums()&&this.isContextual("enum")||super.shouldParseExportDeclaration()}isExportDefaultSpecifier(){return(!this.match(s.name)||!("type"===this.state.value||"interface"===this.state.value||"opaque"===this.state.value||this.shouldParseEnums()&&"enum"===this.state.value))&&super.isExportDefaultSpecifier()}parseExportDefaultExpression(){if(this.shouldParseEnums()&&this.isContextual("enum")){const e=this.startNode();return this.next(),this.flowParseEnumDeclaration(e)}return super.parseExportDefaultExpression()}parseConditional(e,t,n,r,i){if(!this.match(s.question))return e;if(i){const o=this.tryParse(()=>super.parseConditional(e,t,n,r));return o.node?(o.error&&(this.state=o.failState),o.node):(i.start=o.error.pos||this.state.start,e)}this.expect(s.question);const o=this.state.clone(),a=this.state.noArrowAt,u=this.startNodeAt(n,r);let{consequent:c,failed:l}=this.tryParseConditionalConsequent(),[f,p]=this.getArrowLikeExpressions(c);if(l||p.length>0){const e=[...a];if(p.length>0){this.state=o,this.state.noArrowAt=e;for(let t=0;t1&&this.raise(o.start,"Ambiguous expression: wrap the arrow functions in parentheses to disambiguate."),l&&1===f.length&&(this.state=o,this.state.noArrowAt=e.concat(f[0].start),({consequent:c,failed:l}=this.tryParseConditionalConsequent()))}return this.getArrowLikeExpressions(c,!0),this.state.noArrowAt=a,this.expect(s.colon),u.test=e,u.consequent=c,u.alternate=this.forwardNoArrowParamsConversionAt(u,()=>this.parseMaybeAssign(t,void 0,void 0,void 0)),this.finishNode(u,"ConditionalExpression")}tryParseConditionalConsequent(){this.state.noArrowParamsConversionAt.push(this.state.start);const e=this.parseMaybeAssign(),t=!this.match(s.colon);return this.state.noArrowParamsConversionAt.pop(),{consequent:e,failed:t}}getArrowLikeExpressions(e,t){const n=[e],r=[];for(;0!==n.length;){const e=n.pop();"ArrowFunctionExpression"===e.type?(e.typeParameters||!e.returnType?this.finishArrowValidation(e):r.push(e),n.push(e.body)):"ConditionalExpression"===e.type&&(n.push(e.consequent),n.push(e.alternate))}return t?(r.forEach(e=>this.finishArrowValidation(e)),[r,[]]):function(e,t){const n=[],r=[];for(let i=0;ie.params.every(e=>this.isAssignable(e,!0)))}finishArrowValidation(e){var t;this.toAssignableList(e.params,!0,"arrow function parameters",null==(t=e.extra)?void 0:t.trailingComma),this.scope.enter(16|u(!1,!1)),super.checkParams(e,!1,!0),this.scope.exit()}forwardNoArrowParamsConversionAt(e,t){let n;return-1!==this.state.noArrowParamsConversionAt.indexOf(e.start)?(this.state.noArrowParamsConversionAt.push(this.state.start),n=t(),this.state.noArrowParamsConversionAt.pop()):n=t(),n}parseParenItem(e,t,n){if(e=super.parseParenItem(e,t,n),this.eat(s.question)&&(e.optional=!0,this.resetEndLocation(e)),this.match(s.colon)){const r=this.startNodeAt(t,n);return r.expression=e,r.typeAnnotation=this.flowParseTypeAnnotation(),this.finishNode(r,"TypeCastExpression")}return e}assertModuleNodeAllowed(e){"ImportDeclaration"===e.type&&("type"===e.importKind||"typeof"===e.importKind)||"ExportNamedDeclaration"===e.type&&"type"===e.exportKind||"ExportAllDeclaration"===e.type&&"type"===e.exportKind||super.assertModuleNodeAllowed(e)}parseExport(e){const t=super.parseExport(e);return"ExportNamedDeclaration"!==t.type&&"ExportAllDeclaration"!==t.type||(t.exportKind=t.exportKind||"value"),t}parseExportDeclaration(e){if(this.isContextual("type")){e.exportKind="type";const t=this.startNode();return this.next(),this.match(s.braceL)?(e.specifiers=this.parseExportSpecifiers(),this.parseExportFrom(e),null):this.flowParseTypeAlias(t)}if(this.isContextual("opaque")){e.exportKind="type";const t=this.startNode();return this.next(),this.flowParseOpaqueType(t,!1)}if(this.isContextual("interface")){e.exportKind="type";const t=this.startNode();return this.next(),this.flowParseInterface(t)}if(this.shouldParseEnums()&&this.isContextual("enum")){e.exportKind="value";const t=this.startNode();return this.next(),this.flowParseEnumDeclaration(t)}return super.parseExportDeclaration(e)}eatExportStar(e){return!!super.eatExportStar(...arguments)||!(!this.isContextual("type")||this.lookahead().type!==s.star)&&(e.exportKind="type",this.next(),this.next(),!0)}maybeParseExportNamespaceSpecifier(e){const t=this.state.start,n=super.maybeParseExportNamespaceSpecifier(e);return n&&"type"===e.exportKind&&this.unexpected(t),n}parseClassId(e,t,n){super.parseClassId(e,t,n),this.isRelational("<")&&(e.typeParameters=this.flowParseTypeParameterDeclaration())}getTokenFromCode(e){const t=this.input.charCodeAt(this.state.pos+1);return 123===e&&124===t?this.finishOp(s.braceBarL,2):!this.state.inType||62!==e&&60!==e?function(e,t){return 64===e&&64===t}(e,t)?(this.state.isIterator=!0,super.readWord()):super.getTokenFromCode(e):this.finishOp(s.relational,1)}isAssignable(e,t){switch(e.type){case"Identifier":case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":return!0;case"ObjectExpression":{const t=e.properties.length-1;return e.properties.every((e,n)=>"ObjectMethod"!==e.type&&(n===t||"SpreadElement"===e.type)&&this.isAssignable(e))}case"ObjectProperty":return this.isAssignable(e.value);case"SpreadElement":return this.isAssignable(e.argument);case"ArrayExpression":return e.elements.every(e=>this.isAssignable(e));case"AssignmentExpression":return"="===e.operator;case"ParenthesizedExpression":case"TypeCastExpression":return this.isAssignable(e.expression);case"MemberExpression":case"OptionalMemberExpression":return!t;default:return!1}}toAssignable(e,t,n){return"TypeCastExpression"===e.type?super.toAssignable(this.typeCastToParameter(e),t,n):super.toAssignable(e,t,n)}toAssignableList(e,t,n,r){for(let t=0;t1)&&t||this.raise(r.typeAnnotation.start,"The type cast expression is expected to be wrapped with parenthesis")}return e}checkLVal(e,t=64,n,r){if("TypeCastExpression"!==e.type)return super.checkLVal(e,t,n,r)}parseClassProperty(e){return this.match(s.colon)&&(e.typeAnnotation=this.flowParseTypeAnnotation()),super.parseClassProperty(e)}parseClassPrivateProperty(e){return this.match(s.colon)&&(e.typeAnnotation=this.flowParseTypeAnnotation()),super.parseClassPrivateProperty(e)}isClassMethod(){return this.isRelational("<")||super.isClassMethod()}isClassProperty(){return this.match(s.colon)||super.isClassProperty()}isNonstaticConstructor(e){return!this.match(s.colon)&&super.isNonstaticConstructor(e)}pushClassMethod(e,t,n,r,i,o){t.variance&&this.unexpected(t.variance.start),delete t.variance,this.isRelational("<")&&(t.typeParameters=this.flowParseTypeParameterDeclaration()),super.pushClassMethod(e,t,n,r,i,o)}pushClassPrivateMethod(e,t,n,r){t.variance&&this.unexpected(t.variance.start),delete t.variance,this.isRelational("<")&&(t.typeParameters=this.flowParseTypeParameterDeclaration()),super.pushClassPrivateMethod(e,t,n,r)}parseClassSuper(e){if(super.parseClassSuper(e),e.superClass&&this.isRelational("<")&&(e.superTypeParameters=this.flowParseTypeParameterInstantiation()),this.isContextual("implements")){this.next();const t=e.implements=[];do{const e=this.startNode();e.id=this.flowParseRestrictedIdentifier(!0),this.isRelational("<")?e.typeParameters=this.flowParseTypeParameterInstantiation():e.typeParameters=null,t.push(this.finishNode(e,"ClassImplements"))}while(this.eat(s.comma))}}parsePropertyName(e){const t=this.flowParseVariance(),n=super.parsePropertyName(e);return e.variance=t,n}parseObjPropValue(e,t,n,r,i,o,a,u){let c;e.variance&&this.unexpected(e.variance.start),delete e.variance,this.isRelational("<")&&(c=this.flowParseTypeParameterDeclaration(),this.match(s.parenL)||this.unexpected()),super.parseObjPropValue(e,t,n,r,i,o,a,u),c&&((e.value||e).typeParameters=c)}parseAssignableListItemTypes(e){return this.eat(s.question)&&("Identifier"!==e.type&&this.raise(e.start,"A binding pattern parameter cannot be optional in an implementation signature."),e.optional=!0),this.match(s.colon)&&(e.typeAnnotation=this.flowParseTypeAnnotation()),this.resetEndLocation(e),e}parseMaybeDefault(e,t,n){const r=super.parseMaybeDefault(e,t,n);return"AssignmentPattern"===r.type&&r.typeAnnotation&&r.right.startsuper.parseMaybeAssign(e,t,n,r),o),!i.error)return i.node;const{context:a}=this.state;a[a.length-1]===m.j_oTag?a.length-=2:a[a.length-1]===m.j_expr&&(a.length-=1)}if(i&&i.error||this.isRelational("<")){let a;o=o||this.state.clone();const s=this.tryParse(()=>{a=this.flowParseTypeParameterDeclaration();const i=this.forwardNoArrowParamsConversionAt(a,()=>super.parseMaybeAssign(e,t,n,r));return i.typeParameters=a,this.resetStartLocationFromNode(i,a),i},o),u=s.node&&"ArrowFunctionExpression"===s.node.type?s.node:null;if(!s.error&&u)return u;if(i&&i.node)return this.state=i.failState,i.node;if(u)return this.state=s.failState,u;if(i&&i.thrown)throw i.error;if(s.thrown)throw s.error;throw this.raise(a.start,"Expected an arrow function after this type parameter declaration")}return super.parseMaybeAssign(e,t,n,r)}parseArrow(e){if(this.match(s.colon)){const t=this.tryParse(()=>{const t=this.state.noAnonFunctionType;this.state.noAnonFunctionType=!0;const n=this.startNode();return[n.typeAnnotation,e.predicate]=this.flowParseTypeAndPredicateInitialiser(),this.state.noAnonFunctionType=t,this.canInsertSemicolon()&&this.unexpected(),this.match(s.arrow)||this.unexpected(),n});if(t.thrown)return null;t.error&&(this.state=t.failState),e.returnType=t.node.typeAnnotation?this.finishNode(t.node,"TypeAnnotation"):null}return super.parseArrow(e)}shouldParseArrow(){return this.match(s.colon)||super.shouldParseArrow()}setArrowFunctionParameters(e,t){-1!==this.state.noArrowParamsConversionAt.indexOf(e.start)?e.params=t:super.setArrowFunctionParameters(e,t)}checkParams(e,t,n){if(!n||-1===this.state.noArrowParamsConversionAt.indexOf(e.start))return super.checkParams(...arguments)}parseParenAndDistinguishExpression(e){return super.parseParenAndDistinguishExpression(e&&-1===this.state.noArrowAt.indexOf(this.state.start))}parseSubscripts(e,t,n,r){if("Identifier"===e.type&&"async"===e.name&&-1!==this.state.noArrowAt.indexOf(t)){this.next();const r=this.startNodeAt(t,n);r.callee=e,r.arguments=this.parseCallExpressionArguments(s.parenR,!1),e=this.finishNode(r,"CallExpression")}else if("Identifier"===e.type&&"async"===e.name&&this.isRelational("<")){const i=this.state.clone(),o=this.tryParse(e=>this.parseAsyncArrowWithTypeParameters(t,n)||e(),i);if(!o.error&&!o.aborted)return o.node;const a=this.tryParse(()=>super.parseSubscripts(e,t,n,r),i);if(a.node&&!a.error)return a.node;if(o.node)return this.state=o.failState,o.node;if(a.node)return this.state=a.failState,a.node;throw o.error||a.error}return super.parseSubscripts(e,t,n,r)}parseSubscript(e,t,n,r,i){if(this.match(s.questionDot)&&this.isLookaheadRelational("<")){if(this.expectPlugin("optionalChaining"),i.optionalChainMember=!0,r)return i.stop=!0,e;this.next();const o=this.startNodeAt(t,n);return o.callee=e,o.typeArguments=this.flowParseTypeParameterInstantiation(),this.expect(s.parenL),o.arguments=this.parseCallExpressionArguments(s.parenR,!1),o.optional=!0,this.finishCallExpression(o,!0)}if(!r&&this.shouldParseTypes()&&this.isRelational("<")){const r=this.startNodeAt(t,n);r.callee=e;const o=this.tryParse(()=>(r.typeArguments=this.flowParseTypeParameterInstantiationCallOrNew(),this.expect(s.parenL),r.arguments=this.parseCallExpressionArguments(s.parenR,!1),i.optionalChainMember&&(r.optional=!1),this.finishCallExpression(r,i.optionalChainMember)));if(o.node)return o.error&&(this.state=o.failState),o.node}return super.parseSubscript(e,t,n,r,i)}parseNewArguments(e){let t=null;this.shouldParseTypes()&&this.isRelational("<")&&(t=this.tryParse(()=>this.flowParseTypeParameterInstantiationCallOrNew()).node),e.typeArguments=t,super.parseNewArguments(e)}parseAsyncArrowWithTypeParameters(e,t){const n=this.startNodeAt(e,t);if(this.parseFunctionParams(n),this.parseArrow(n))return this.parseArrowExpression(n,void 0,!0)}readToken_mult_modulo(e){const t=this.input.charCodeAt(this.state.pos+1);if(42===e&&47===t&&this.state.hasFlowComment)return this.state.hasFlowComment=!1,this.state.pos+=2,void this.nextToken();super.readToken_mult_modulo(e)}readToken_pipe_amp(e){const t=this.input.charCodeAt(this.state.pos+1);124!==e||125!==t?super.readToken_pipe_amp(e):this.finishOp(s.braceBarR,2)}parseTopLevel(e,t){const n=super.parseTopLevel(e,t);return this.state.hasFlowComment&&this.raise(this.state.pos,"Unterminated flow-comment"),n}skipBlockComment(){if(this.hasPlugin("flowComments")&&this.skipFlowComment())return this.state.hasFlowComment&&this.unexpected(null,"Cannot have a flow comment inside another flow comment"),this.hasFlowCommentCompletion(),this.state.pos+=this.skipFlowComment(),void(this.state.hasFlowComment=!0);if(this.state.hasFlowComment){const e=this.input.indexOf("*-/",this.state.pos+=2);if(-1===e)throw this.raise(this.state.pos-2,"Unterminated comment");this.state.pos=e+3}else super.skipBlockComment()}skipFlowComment(){const{pos:e}=this.state;let t=2;for(;[32,9].includes(this.input.charCodeAt(e+t));)t++;const n=this.input.charCodeAt(t+e),r=this.input.charCodeAt(t+e+1);return 58===n&&58===r?t+2:"flow-include"===this.input.slice(t+e,t+e+12)?t+12:58===n&&58!==r&&t}hasFlowCommentCompletion(){if(-1===this.input.indexOf("*/",this.state.pos))throw this.raise(this.state.pos,"Unterminated comment")}flowEnumErrorBooleanMemberNotInitialized(e,{enumName:t,memberName:n}){this.raise(e,`Boolean enum members need to be initialized. Use either \`${n} = true,\` `+`or \`${n} = false,\` in enum \`${t}\`.`)}flowEnumErrorInvalidMemberName(e,{enumName:t,memberName:n}){const r=n[0].toUpperCase()+n.slice(1);this.raise(e,"Enum member names cannot start with lowercase 'a' through 'z'. Instead of using "+`\`${n}\`, consider using \`${r}\`, in enum \`${t}\`.`)}flowEnumErrorDuplicateMemberName(e,{enumName:t,memberName:n}){this.raise(e,`Enum member names need to be unique, but the name \`${n}\` has already been used `+`before in enum \`${t}\`.`)}flowEnumErrorInconsistentMemberValues(e,{enumName:t}){this.raise(e,`Enum \`${t}\` has inconsistent member initializers. Either use no initializers, or `+"consistently use literals (either booleans, numbers, or strings) for all member initializers.")}flowEnumErrorInvalidExplicitType(e,{enumName:t,suppliedType:n}){const r="Use one of `boolean`, `number`, `string`, or `symbol` in "+`enum \`${t}\`.`,i=null===n?`Supplied enum type is not valid. ${r}`:`Enum type \`${n}\` is not valid. ${r}`;return this.raise(e,i)}flowEnumErrorInvalidMemberInitializer(e,{enumName:t,explicitType:n,memberName:r}){let i=null;switch(n){case"boolean":case"number":case"string":i=`Enum \`${t}\` has type \`${n}\`, so the initializer of `+`\`${r}\` needs to be a ${n} literal.`;break;case"symbol":i=`Symbol enum members cannot be initialized. Use \`${r},\` in `+`enum \`${t}\`.`;break;default:i=`The enum member initializer for \`${r}\` needs to be a literal (either `+`a boolean, number, or string) in enum \`${t}\`.`}return this.raise(e,i)}flowEnumErrorNumberMemberNotInitialized(e,{enumName:t,memberName:n}){this.raise(e,`Number enum members need to be initialized, e.g. \`${n} = 1\` in enum \`${t}\`.`)}flowEnumErrorStringMemberInconsistentlyInitailized(e,{enumName:t}){this.raise(e,"String enum members need to consistently either all use initializers, or use no initializers, "+`in enum \`${t}\`.`)}flowEnumMemberInit(){const e=this.state.start,t=()=>this.match(s.comma)||this.match(s.braceR);switch(this.state.type){case s.num:{const n=this.parseLiteral(this.state.value,"NumericLiteral");return t()?{type:"number",pos:n.start,value:n}:{type:"invalid",pos:e}}case s.string:{const n=this.parseLiteral(this.state.value,"StringLiteral");return t()?{type:"string",pos:n.start,value:n}:{type:"invalid",pos:e}}case s._true:case s._false:{const n=this.parseBooleanLiteral();return t()?{type:"boolean",pos:n.start,value:n}:{type:"invalid",pos:e}}default:return{type:"invalid",pos:e}}}flowEnumMemberRaw(){const e=this.state.start;return{id:this.parseIdentifier(!0),init:this.eat(s.eq)?this.flowEnumMemberInit():{type:"none",pos:e}}}flowEnumCheckExplicitTypeMismatch(e,t,n){const{explicitType:r}=t;null!==r&&r!==n&&this.flowEnumErrorInvalidMemberInitializer(e,t)}flowEnumMembers({enumName:e,explicitType:t}){const n=new Set,r={booleanMembers:[],numberMembers:[],stringMembers:[],defaultedMembers:[]};for(;!this.match(s.braceR);){const i=this.startNode(),{id:o,init:a}=this.flowEnumMemberRaw(),u=o.name;if(""===u)continue;/^[a-z]/.test(u)&&this.flowEnumErrorInvalidMemberName(o.start,{enumName:e,memberName:u}),n.has(u)&&this.flowEnumErrorDuplicateMemberName(o.start,{enumName:e,memberName:u}),n.add(u);const c={enumName:e,explicitType:t,memberName:u};switch(i.id=o,a.type){case"boolean":this.flowEnumCheckExplicitTypeMismatch(a.pos,c,"boolean"),i.init=a.value,r.booleanMembers.push(this.finishNode(i,"EnumBooleanMember"));break;case"number":this.flowEnumCheckExplicitTypeMismatch(a.pos,c,"number"),i.init=a.value,r.numberMembers.push(this.finishNode(i,"EnumNumberMember"));break;case"string":this.flowEnumCheckExplicitTypeMismatch(a.pos,c,"string"),i.init=a.value,r.stringMembers.push(this.finishNode(i,"EnumStringMember"));break;case"invalid":throw this.flowEnumErrorInvalidMemberInitializer(a.pos,c);case"none":switch(t){case"boolean":this.flowEnumErrorBooleanMemberNotInitialized(a.pos,c);break;case"number":this.flowEnumErrorNumberMemberNotInitialized(a.pos,c);break;default:r.defaultedMembers.push(this.finishNode(i,"EnumDefaultedMember"))}}this.match(s.braceR)||this.expect(s.comma)}return r}flowEnumStringMembers(e,t,{enumName:n}){if(0===e.length)return t;if(0===t.length)return e;if(t.length>e.length){for(let t=0;t(e.members=[],this.expect(s.braceR),this.finishNode(e,"EnumStringBody"));e.explicitType=!1;const o=i.booleanMembers.length,a=i.numberMembers.length,u=i.stringMembers.length,c=i.defaultedMembers.length;if(o||a||u||c){if(o||a){if(!a&&!u&&o>=c){for(let e=0,n=i.defaultedMembers;e=c){for(let e=0,n=i.defaultedMembers;eclass extends e{getScopeHandler(){return W}tsIsIdentifier(){return this.match(s.name)}tsNextTokenCanFollowModifier(){return this.next(),!(this.hasPrecedingLineBreak()||this.match(s.parenL)||this.match(s.parenR)||this.match(s.colon)||this.match(s.eq)||this.match(s.question)||this.match(s.bang))}tsParseModifier(e){if(!this.match(s.name))return;const t=this.state.value;return-1!==e.indexOf(t)&&this.tsTryParse(this.tsNextTokenCanFollowModifier.bind(this))?t:void 0}tsParseModifiers(e){const t=Object.create(null);for(;;){const n=this.state.start,r=this.tsParseModifier(e);if(!r)break;Object.hasOwnProperty.call(t,r)&&this.raise(n,`Duplicate modifier: '${r}'`),t[r]=!0}return t}tsIsListTerminator(e){switch(e){case"EnumMembers":case"TypeMembers":return this.match(s.braceR);case"HeritageClauseElement":return this.match(s.braceL);case"TupleElementTypes":return this.match(s.bracketR);case"TypeParametersOrArguments":return this.isRelational(">")}throw new Error("Unreachable")}tsParseList(e,t){const n=[];for(;!this.tsIsListTerminator(e);)n.push(t());return n}tsParseDelimitedList(e,t){return X(this.tsParseDelimitedListWorker(e,t,!0))}tsParseDelimitedListWorker(e,t,n){const r=[];for(;!this.tsIsListTerminator(e);){const i=t();if(null==i)return;if(r.push(i),!this.eat(s.comma)){if(this.tsIsListTerminator(e))break;return void(n&&this.expect(s.comma))}}return r}tsParseBracketedList(e,t,n,r){r||(n?this.expect(s.bracketL):this.expectRelational("<"));const i=this.tsParseDelimitedList(e,t);return n?this.expect(s.bracketR):this.expectRelational(">"),i}tsParseImportType(){const e=this.startNode();return this.expect(s._import),this.expect(s.parenL),this.match(s.string)||this.raise(this.state.start,"Argument in a type import must be a string literal"),e.argument=this.parseExprAtom(),this.expect(s.parenR),this.eat(s.dot)&&(e.qualifier=this.tsParseEntityName(!0)),this.isRelational("<")&&(e.typeParameters=this.tsParseTypeArguments()),this.finishNode(e,"TSImportType")}tsParseEntityName(e){let t=this.parseIdentifier();for(;this.eat(s.dot);){const n=this.startNodeAtNode(t);n.left=t,n.right=this.parseIdentifier(e),t=this.finishNode(n,"TSQualifiedName")}return t}tsParseTypeReference(){const e=this.startNode();return e.typeName=this.tsParseEntityName(!1),!this.hasPrecedingLineBreak()&&this.isRelational("<")&&(e.typeParameters=this.tsParseTypeArguments()),this.finishNode(e,"TSTypeReference")}tsParseThisTypePredicate(e){this.next();const t=this.startNodeAtNode(e);return t.parameterName=e,t.typeAnnotation=this.tsParseTypeAnnotation(!1),this.finishNode(t,"TSTypePredicate")}tsParseThisTypeNode(){const e=this.startNode();return this.next(),this.finishNode(e,"TSThisType")}tsParseTypeQuery(){const e=this.startNode();return this.expect(s._typeof),this.match(s._import)?e.exprName=this.tsParseImportType():e.exprName=this.tsParseEntityName(!0),this.finishNode(e,"TSTypeQuery")}tsParseTypeParameter(){const e=this.startNode();return e.name=this.parseIdentifierName(e.start),e.constraint=this.tsEatThenParseType(s._extends),e.default=this.tsEatThenParseType(s.eq),this.finishNode(e,"TSTypeParameter")}tsTryParseTypeParameters(){if(this.isRelational("<"))return this.tsParseTypeParameters()}tsParseTypeParameters(){const e=this.startNode();return this.isRelational("<")||this.match(s.jsxTagStart)?this.next():this.unexpected(),e.params=this.tsParseBracketedList("TypeParametersOrArguments",this.tsParseTypeParameter.bind(this),!1,!0),this.finishNode(e,"TSTypeParameterDeclaration")}tsTryNextParseConstantContext(){return this.lookahead().type===s._const?(this.next(),this.tsParseTypeReference()):null}tsFillSignature(e,t){const n=e===s.arrow;t.typeParameters=this.tsTryParseTypeParameters(),this.expect(s.parenL),t.parameters=this.tsParseBindingListForSignature(),n?t.typeAnnotation=this.tsParseTypeOrTypePredicateAnnotation(e):this.match(e)&&(t.typeAnnotation=this.tsParseTypeOrTypePredicateAnnotation(e))}tsParseBindingListForSignature(){return this.parseBindingList(s.parenR,41).map(e=>("Identifier"!==e.type&&"RestElement"!==e.type&&"ObjectPattern"!==e.type&&"ArrayPattern"!==e.type&&this.raise(e.start,"Name in a signature must be an Identifier, ObjectPattern or ArrayPattern,"+`instead got ${e.type}`),e))}tsParseTypeMemberSemicolon(){this.eat(s.comma)||this.semicolon()}tsParseSignatureMember(e,t){return this.tsFillSignature(s.colon,t),this.tsParseTypeMemberSemicolon(),this.finishNode(t,e)}tsIsUnambiguouslyIndexSignature(){return this.next(),this.eat(s.name)&&this.match(s.colon)}tsTryParseIndexSignature(e){if(!this.match(s.bracketL)||!this.tsLookAhead(this.tsIsUnambiguouslyIndexSignature.bind(this)))return;this.expect(s.bracketL);const t=this.parseIdentifier();t.typeAnnotation=this.tsParseTypeAnnotation(),this.resetEndLocation(t),this.expect(s.bracketR),e.parameters=[t];const n=this.tsTryParseTypeAnnotation();return n&&(e.typeAnnotation=n),this.tsParseTypeMemberSemicolon(),this.finishNode(e,"TSIndexSignature")}tsParsePropertyOrMethodSignature(e,t){this.eat(s.question)&&(e.optional=!0);const n=e;if(t||!this.match(s.parenL)&&!this.isRelational("<")){const e=n;t&&(e.readonly=!0);const r=this.tsTryParseTypeAnnotation();return r&&(e.typeAnnotation=r),this.tsParseTypeMemberSemicolon(),this.finishNode(e,"TSPropertySignature")}{const e=n;return this.tsFillSignature(s.colon,e),this.tsParseTypeMemberSemicolon(),this.finishNode(e,"TSMethodSignature")}}tsParseTypeMember(){const e=this.startNode();if(this.match(s.parenL)||this.isRelational("<"))return this.tsParseSignatureMember("TSCallSignatureDeclaration",e);if(this.match(s._new)){const t=this.startNode();return this.next(),this.match(s.parenL)||this.isRelational("<")?this.tsParseSignatureMember("TSConstructSignatureDeclaration",e):(e.key=this.createIdentifier(t,"new"),this.tsParsePropertyOrMethodSignature(e,!1))}const t=!!this.tsParseModifier(["readonly"]),n=this.tsTryParseIndexSignature(e);return n?(t&&(e.readonly=!0),n):(this.parsePropertyName(e),this.tsParsePropertyOrMethodSignature(e,t))}tsParseTypeLiteral(){const e=this.startNode();return e.members=this.tsParseObjectTypeMembers(),this.finishNode(e,"TSTypeLiteral")}tsParseObjectTypeMembers(){this.expect(s.braceL);const e=this.tsParseList("TypeMembers",this.tsParseTypeMember.bind(this));return this.expect(s.braceR),e}tsIsStartOfMappedType(){return this.next(),this.eat(s.plusMin)?this.isContextual("readonly"):(this.isContextual("readonly")&&this.next(),!!this.match(s.bracketL)&&(this.next(),!!this.tsIsIdentifier()&&(this.next(),this.match(s._in))))}tsParseMappedTypeParameter(){const e=this.startNode();return e.name=this.parseIdentifierName(e.start),e.constraint=this.tsExpectThenParseType(s._in),this.finishNode(e,"TSTypeParameter")}tsParseMappedType(){const e=this.startNode();return this.expect(s.braceL),this.match(s.plusMin)?(e.readonly=this.state.value,this.next(),this.expectContextual("readonly")):this.eatContextual("readonly")&&(e.readonly=!0),this.expect(s.bracketL),e.typeParameter=this.tsParseMappedTypeParameter(),this.expect(s.bracketR),this.match(s.plusMin)?(e.optional=this.state.value,this.next(),this.expect(s.question)):this.eat(s.question)&&(e.optional=!0),e.typeAnnotation=this.tsTryParseType(),this.semicolon(),this.expect(s.braceR),this.finishNode(e,"TSMappedType")}tsParseTupleType(){const e=this.startNode();e.elementTypes=this.tsParseBracketedList("TupleElementTypes",this.tsParseTupleElementType.bind(this),!0,!1);let t=!1;return e.elementTypes.forEach(e=>{"TSOptionalType"===e.type?t=!0:t&&"TSRestType"!==e.type&&this.raise(e.start,"A required element cannot follow an optional element.")}),this.finishNode(e,"TSTupleType")}tsParseTupleElementType(){if(this.match(s.ellipsis)){const e=this.startNode();return this.next(),e.typeAnnotation=this.tsParseType(),this.match(s.comma)&&93!==this.lookaheadCharCode()&&this.raiseRestNotLast(this.state.start),this.finishNode(e,"TSRestType")}const e=this.tsParseType();if(this.eat(s.question)){const t=this.startNodeAtNode(e);return t.typeAnnotation=e,this.finishNode(t,"TSOptionalType")}return e}tsParseParenthesizedType(){const e=this.startNode();return this.expect(s.parenL),e.typeAnnotation=this.tsParseType(),this.expect(s.parenR),this.finishNode(e,"TSParenthesizedType")}tsParseFunctionOrConstructorType(e){const t=this.startNode();return"TSConstructorType"===e&&this.expect(s._new),this.tsFillSignature(s.arrow,t),this.finishNode(t,e)}tsParseLiteralTypeNode(){const e=this.startNode();return e.literal=(()=>{switch(this.state.type){case s.num:case s.string:case s._true:case s._false:return this.parseExprAtom();default:throw this.unexpected()}})(),this.finishNode(e,"TSLiteralType")}tsParseTemplateLiteralType(){const e=this.startNode(),t=this.parseTemplate(!1);return t.expressions.length>0&&this.raise(t.expressions[0].start,"Template literal types cannot have any substitution"),e.literal=t,this.finishNode(e,"TSLiteralType")}tsParseThisTypeOrThisTypePredicate(){const e=this.tsParseThisTypeNode();return this.isContextual("is")&&!this.hasPrecedingLineBreak()?this.tsParseThisTypePredicate(e):e}tsParseNonArrayType(){switch(this.state.type){case s.name:case s._void:case s._null:{const e=this.match(s._void)?"TSVoidKeyword":this.match(s._null)?"TSNullKeyword":function(e){switch(e){case"any":return"TSAnyKeyword";case"boolean":return"TSBooleanKeyword";case"bigint":return"TSBigIntKeyword";case"never":return"TSNeverKeyword";case"number":return"TSNumberKeyword";case"object":return"TSObjectKeyword";case"string":return"TSStringKeyword";case"symbol":return"TSSymbolKeyword";case"undefined":return"TSUndefinedKeyword";case"unknown":return"TSUnknownKeyword";default:return}}(this.state.value);if(void 0!==e&&46!==this.lookaheadCharCode()){const t=this.startNode();return this.next(),this.finishNode(t,e)}return this.tsParseTypeReference()}case s.string:case s.num:case s._true:case s._false:return this.tsParseLiteralTypeNode();case s.plusMin:if("-"===this.state.value){const e=this.startNode();if(this.lookahead().type!==s.num)throw this.unexpected();return e.literal=this.parseMaybeUnary(),this.finishNode(e,"TSLiteralType")}break;case s._this:return this.tsParseThisTypeOrThisTypePredicate();case s._typeof:return this.tsParseTypeQuery();case s._import:return this.tsParseImportType();case s.braceL:return this.tsLookAhead(this.tsIsStartOfMappedType.bind(this))?this.tsParseMappedType():this.tsParseTypeLiteral();case s.bracketL:return this.tsParseTupleType();case s.parenL:return this.tsParseParenthesizedType();case s.backQuote:return this.tsParseTemplateLiteralType()}throw this.unexpected()}tsParseArrayTypeOrHigher(){let e=this.tsParseNonArrayType();for(;!this.hasPrecedingLineBreak()&&this.eat(s.bracketL);)if(this.match(s.bracketR)){const t=this.startNodeAtNode(e);t.elementType=e,this.expect(s.bracketR),e=this.finishNode(t,"TSArrayType")}else{const t=this.startNodeAtNode(e);t.objectType=e,t.indexType=this.tsParseType(),this.expect(s.bracketR),e=this.finishNode(t,"TSIndexedAccessType")}return e}tsParseTypeOperator(e){const t=this.startNode();return this.expectContextual(e),t.operator=e,t.typeAnnotation=this.tsParseTypeOperatorOrHigher(),"readonly"===e&&this.tsCheckTypeAnnotationForReadOnly(t),this.finishNode(t,"TSTypeOperator")}tsCheckTypeAnnotationForReadOnly(e){switch(e.typeAnnotation.type){case"TSTupleType":case"TSArrayType":return;default:this.raise(e.start,"'readonly' type modifier is only permitted on array and tuple literal types.")}}tsParseInferType(){const e=this.startNode();this.expectContextual("infer");const t=this.startNode();return t.name=this.parseIdentifierName(t.start),e.typeParameter=this.finishNode(t,"TSTypeParameter"),this.finishNode(e,"TSInferType")}tsParseTypeOperatorOrHigher(){const e=["keyof","unique","readonly"].find(e=>this.isContextual(e));return e?this.tsParseTypeOperator(e):this.isContextual("infer")?this.tsParseInferType():this.tsParseArrayTypeOrHigher()}tsParseUnionOrIntersectionType(e,t,n){this.eat(n);let r=t();if(this.match(n)){const i=[r];for(;this.eat(n);)i.push(t());const o=this.startNodeAtNode(r);o.types=i,r=this.finishNode(o,e)}return r}tsParseIntersectionTypeOrHigher(){return this.tsParseUnionOrIntersectionType("TSIntersectionType",this.tsParseTypeOperatorOrHigher.bind(this),s.bitwiseAND)}tsParseUnionTypeOrHigher(){return this.tsParseUnionOrIntersectionType("TSUnionType",this.tsParseIntersectionTypeOrHigher.bind(this),s.bitwiseOR)}tsIsStartOfFunctionType(){return!!this.isRelational("<")||this.match(s.parenL)&&this.tsLookAhead(this.tsIsUnambiguouslyStartOfFunctionType.bind(this))}tsSkipParameterStart(){if(this.match(s.name)||this.match(s._this))return this.next(),!0;if(this.match(s.braceL)){let e=1;for(this.next();e>0;)this.match(s.braceL)?++e:this.match(s.braceR)&&--e,this.next();return!0}if(this.match(s.bracketL)){let e=1;for(this.next();e>0;)this.match(s.bracketL)?++e:this.match(s.bracketR)&&--e,this.next();return!0}return!1}tsIsUnambiguouslyStartOfFunctionType(){if(this.next(),this.match(s.parenR)||this.match(s.ellipsis))return!0;if(this.tsSkipParameterStart()){if(this.match(s.colon)||this.match(s.comma)||this.match(s.question)||this.match(s.eq))return!0;if(this.match(s.parenR)&&(this.next(),this.match(s.arrow)))return!0}return!1}tsParseTypeOrTypePredicateAnnotation(e){return this.tsInType(()=>{const t=this.startNode();this.expect(e);const n=this.tsTryParse(this.tsParseTypePredicateAsserts.bind(this));if(n&&this.match(s._this)){let e=this.tsParseThisTypeOrThisTypePredicate();if("TSThisType"===e.type){const n=this.startNodeAtNode(t);n.parameterName=e,n.asserts=!0,e=this.finishNode(n,"TSTypePredicate")}else e.asserts=!0;return t.typeAnnotation=e,this.finishNode(t,"TSTypeAnnotation")}const r=this.tsIsIdentifier()&&this.tsTryParse(this.tsParseTypePredicatePrefix.bind(this));if(!r){if(!n)return this.tsParseTypeAnnotation(!1,t);const e=this.startNodeAtNode(t);return e.parameterName=this.parseIdentifier(),e.asserts=n,t.typeAnnotation=this.finishNode(e,"TSTypePredicate"),this.finishNode(t,"TSTypeAnnotation")}const i=this.tsParseTypeAnnotation(!1),o=this.startNodeAtNode(t);return o.parameterName=r,o.typeAnnotation=i,o.asserts=n,t.typeAnnotation=this.finishNode(o,"TSTypePredicate"),this.finishNode(t,"TSTypeAnnotation")})}tsTryParseTypeOrTypePredicateAnnotation(){return this.match(s.colon)?this.tsParseTypeOrTypePredicateAnnotation(s.colon):void 0}tsTryParseTypeAnnotation(){return this.match(s.colon)?this.tsParseTypeAnnotation():void 0}tsTryParseType(){return this.tsEatThenParseType(s.colon)}tsParseTypePredicatePrefix(){const e=this.parseIdentifier();if(this.isContextual("is")&&!this.hasPrecedingLineBreak())return this.next(),e}tsParseTypePredicateAsserts(){if(!this.match(s.name)||"asserts"!==this.state.value||this.hasPrecedingLineBreak())return!1;const e=this.state.containsEsc;return this.next(),!(!this.match(s.name)&&!this.match(s._this))&&(e&&this.raise(this.state.lastTokStart,"Escape sequence in keyword asserts"),!0)}tsParseTypeAnnotation(e=!0,t=this.startNode()){return this.tsInType(()=>{e&&this.expect(s.colon),t.typeAnnotation=this.tsParseType()}),this.finishNode(t,"TSTypeAnnotation")}tsParseType(){K(this.state.inType);const e=this.tsParseNonConditionalType();if(this.hasPrecedingLineBreak()||!this.eat(s._extends))return e;const t=this.startNodeAtNode(e);return t.checkType=e,t.extendsType=this.tsParseNonConditionalType(),this.expect(s.question),t.trueType=this.tsParseType(),this.expect(s.colon),t.falseType=this.tsParseType(),this.finishNode(t,"TSConditionalType")}tsParseNonConditionalType(){return this.tsIsStartOfFunctionType()?this.tsParseFunctionOrConstructorType("TSFunctionType"):this.match(s._new)?this.tsParseFunctionOrConstructorType("TSConstructorType"):this.tsParseUnionTypeOrHigher()}tsParseTypeAssertion(){const e=this.startNode(),t=this.tsTryNextParseConstantContext();return e.typeAnnotation=t||this.tsNextThenParseType(),this.expectRelational(">"),e.expression=this.parseMaybeUnary(),this.finishNode(e,"TSTypeAssertion")}tsParseHeritageClause(e){const t=this.state.start,n=this.tsParseDelimitedList("HeritageClauseElement",this.tsParseExpressionWithTypeArguments.bind(this));return n.length||this.raise(t,`'${e}' list cannot be empty.`),n}tsParseExpressionWithTypeArguments(){const e=this.startNode();return e.expression=this.tsParseEntityName(!1),this.isRelational("<")&&(e.typeParameters=this.tsParseTypeArguments()),this.finishNode(e,"TSExpressionWithTypeArguments")}tsParseInterfaceDeclaration(e){e.id=this.parseIdentifier(),this.checkLVal(e.id,130,void 0,"typescript interface declaration"),e.typeParameters=this.tsTryParseTypeParameters(),this.eat(s._extends)&&(e.extends=this.tsParseHeritageClause("extends"));const t=this.startNode();return t.body=this.tsInType(this.tsParseObjectTypeMembers.bind(this)),e.body=this.finishNode(t,"TSInterfaceBody"),this.finishNode(e,"TSInterfaceDeclaration")}tsParseTypeAliasDeclaration(e){return e.id=this.parseIdentifier(),this.checkLVal(e.id,2,void 0,"typescript type alias"),e.typeParameters=this.tsTryParseTypeParameters(),e.typeAnnotation=this.tsExpectThenParseType(s.eq),this.semicolon(),this.finishNode(e,"TSTypeAliasDeclaration")}tsInNoContext(e){const t=this.state.context;this.state.context=[t[0]];try{return e()}finally{this.state.context=t}}tsInType(e){const t=this.state.inType;this.state.inType=!0;try{return e()}finally{this.state.inType=t}}tsEatThenParseType(e){return this.match(e)?this.tsNextThenParseType():void 0}tsExpectThenParseType(e){return this.tsDoThenParseType(()=>this.expect(e))}tsNextThenParseType(){return this.tsDoThenParseType(()=>this.next())}tsDoThenParseType(e){return this.tsInType(()=>(e(),this.tsParseType()))}tsParseEnumMember(){const e=this.startNode();return e.id=this.match(s.string)?this.parseExprAtom():this.parseIdentifier(!0),this.eat(s.eq)&&(e.initializer=this.parseMaybeAssign()),this.finishNode(e,"TSEnumMember")}tsParseEnumDeclaration(e,t){return t&&(e.const=!0),e.id=this.parseIdentifier(),this.checkLVal(e.id,t?779:267,void 0,"typescript enum declaration"),this.expect(s.braceL),e.members=this.tsParseDelimitedList("EnumMembers",this.tsParseEnumMember.bind(this)),this.expect(s.braceR),this.finishNode(e,"TSEnumDeclaration")}tsParseModuleBlock(){const e=this.startNode();return this.scope.enter(0),this.expect(s.braceL),this.parseBlockOrModuleBlockBody(e.body=[],void 0,!0,s.braceR),this.scope.exit(),this.finishNode(e,"TSModuleBlock")}tsParseModuleOrNamespaceDeclaration(e,t=!1){if(e.id=this.parseIdentifier(),t||this.checkLVal(e.id,1024,null,"module or namespace declaration"),this.eat(s.dot)){const t=this.startNode();this.tsParseModuleOrNamespaceDeclaration(t,!0),e.body=t}else this.scope.enter(512),e.body=this.tsParseModuleBlock(),this.scope.exit();return this.finishNode(e,"TSModuleDeclaration")}tsParseAmbientExternalModuleDeclaration(e){return this.isContextual("global")?(e.global=!0,e.id=this.parseIdentifier()):this.match(s.string)?e.id=this.parseExprAtom():this.unexpected(),this.match(s.braceL)?(this.scope.enter(512),e.body=this.tsParseModuleBlock(),this.scope.exit()):this.semicolon(),this.finishNode(e,"TSModuleDeclaration")}tsParseImportEqualsDeclaration(e,t){return e.isExport=t||!1,e.id=this.parseIdentifier(),this.checkLVal(e.id,9,void 0,"import equals declaration"),this.expect(s.eq),e.moduleReference=this.tsParseModuleReference(),this.semicolon(),this.finishNode(e,"TSImportEqualsDeclaration")}tsIsExternalModuleReference(){return this.isContextual("require")&&40===this.lookaheadCharCode()}tsParseModuleReference(){return this.tsIsExternalModuleReference()?this.tsParseExternalModuleReference():this.tsParseEntityName(!1)}tsParseExternalModuleReference(){const e=this.startNode();if(this.expectContextual("require"),this.expect(s.parenL),!this.match(s.string))throw this.unexpected();return e.expression=this.parseExprAtom(),this.expect(s.parenR),this.finishNode(e,"TSExternalModuleReference")}tsLookAhead(e){const t=this.state.clone(),n=e();return this.state=t,n}tsTryParseAndCatch(e){const t=this.tryParse(t=>e()||t());if(!t.aborted&&t.node)return t.error&&(this.state=t.failState),t.node}tsTryParse(e){const t=this.state.clone(),n=e();return void 0!==n&&!1!==n?n:void(this.state=t)}tsTryParseDeclare(e){if(this.isLineTerminator())return;let t,n=this.state.type;switch(this.isContextual("let")&&(n=s._var,t="let"),n){case s._function:return this.parseFunctionStatement(e,!1,!0);case s._class:return e.declare=!0,this.parseClass(e,!0,!1);case s._const:if(this.match(s._const)&&this.isLookaheadContextual("enum"))return this.expect(s._const),this.expectContextual("enum"),this.tsParseEnumDeclaration(e,!0);case s._var:return t=t||this.state.value,this.parseVarStatement(e,t);case s.name:{const t=this.state.value;return"global"===t?this.tsParseAmbientExternalModuleDeclaration(e):this.tsParseDeclaration(e,t,!0)}}}tsTryParseExportDeclaration(){return this.tsParseDeclaration(this.startNode(),this.state.value,!0)}tsParseExpressionStatement(e,t){switch(t.name){case"declare":{const t=this.tsTryParseDeclare(e);if(t)return t.declare=!0,t;break}case"global":if(this.match(s.braceL)){this.scope.enter(512);const n=e;return n.global=!0,n.id=t,n.body=this.tsParseModuleBlock(),this.scope.exit(),this.finishNode(n,"TSModuleDeclaration")}break;default:return this.tsParseDeclaration(e,t.name,!1)}}tsParseDeclaration(e,t,n){switch(t){case"abstract":if(this.tsCheckLineTerminatorAndMatch(s._class,n)){const t=e;return t.abstract=!0,n&&(this.next(),this.match(s._class)||this.unexpected(null,s._class)),this.parseClass(t,!0,!1)}break;case"enum":if(n||this.match(s.name))return n&&this.next(),this.tsParseEnumDeclaration(e,!1);break;case"interface":if(this.tsCheckLineTerminatorAndMatch(s.name,n))return n&&this.next(),this.tsParseInterfaceDeclaration(e);break;case"module":if(n&&this.next(),this.match(s.string))return this.tsParseAmbientExternalModuleDeclaration(e);if(this.tsCheckLineTerminatorAndMatch(s.name,n))return this.tsParseModuleOrNamespaceDeclaration(e);break;case"namespace":if(this.tsCheckLineTerminatorAndMatch(s.name,n))return n&&this.next(),this.tsParseModuleOrNamespaceDeclaration(e);break;case"type":if(this.tsCheckLineTerminatorAndMatch(s.name,n))return n&&this.next(),this.tsParseTypeAliasDeclaration(e)}}tsCheckLineTerminatorAndMatch(e,t){return(t||this.match(e))&&!this.isLineTerminator()}tsTryParseGenericAsyncArrowFunction(e,t){if(!this.isRelational("<"))return;const n=this.tsTryParseAndCatch(()=>{const n=this.startNodeAt(e,t);return n.typeParameters=this.tsParseTypeParameters(),super.parseFunctionParams(n),n.returnType=this.tsTryParseTypeOrTypePredicateAnnotation(),this.expect(s.arrow),n});return n?this.parseArrowExpression(n,null,!0):void 0}tsParseTypeArguments(){const e=this.startNode();return e.params=this.tsInType(()=>this.tsInNoContext(()=>(this.expectRelational("<"),this.tsParseDelimitedList("TypeParametersOrArguments",this.tsParseType.bind(this))))),this.state.exprAllowed=!1,this.expectRelational(">"),this.finishNode(e,"TSTypeParameterInstantiation")}tsIsDeclarationStart(){if(this.match(s.name))switch(this.state.value){case"abstract":case"declare":case"enum":case"interface":case"module":case"namespace":case"type":return!0}return!1}isExportDefaultSpecifier(){return!this.tsIsDeclarationStart()&&super.isExportDefaultSpecifier()}parseAssignableListItem(e,t){const n=this.state.start,r=this.state.startLoc;let i,o=!1;e&&(i=this.parseAccessModifier(),o=!!this.tsParseModifier(["readonly"]));const a=this.parseMaybeDefault();this.parseAssignableListItemTypes(a);const s=this.parseMaybeDefault(a.start,a.loc.start,a);if(i||o){const e=this.startNodeAt(n,r);return t.length&&(e.decorators=t),i&&(e.accessibility=i),o&&(e.readonly=o),"Identifier"!==s.type&&"AssignmentPattern"!==s.type&&this.raise(e.start,"A parameter property may not be declared using a binding pattern."),e.parameter=s,this.finishNode(e,"TSParameterProperty")}return t.length&&(a.decorators=t),s}parseFunctionBodyAndFinish(e,t,n=!1){this.match(s.colon)&&(e.returnType=this.tsParseTypeOrTypePredicateAnnotation(s.colon));const r="FunctionDeclaration"===t?"TSDeclareFunction":"ClassMethod"===t?"TSDeclareMethod":void 0;r&&!this.match(s.braceL)&&this.isLineTerminator()?this.finishNode(e,r):super.parseFunctionBodyAndFinish(e,t,n)}registerFunctionStatementId(e){!e.body&&e.id?this.checkLVal(e.id,1024,null,"function name"):super.registerFunctionStatementId(...arguments)}parseSubscript(e,t,n,r,i){if(!this.hasPrecedingLineBreak()&&this.match(s.bang)){this.state.exprAllowed=!1,this.next();const r=this.startNodeAt(t,n);return r.expression=e,this.finishNode(r,"TSNonNullExpression")}if(this.isRelational("<")){const o=this.tsTryParseAndCatch(()=>{if(!r&&this.atPossibleAsync(e)){const e=this.tsTryParseGenericAsyncArrowFunction(t,n);if(e)return e}const o=this.startNodeAt(t,n);o.callee=e;const a=this.tsParseTypeArguments();if(a){if(!r&&this.eat(s.parenL))return o.arguments=this.parseCallExpressionArguments(s.parenR,!1),o.typeParameters=a,this.finishCallExpression(o,i.optionalChainMember);if(this.match(s.backQuote))return this.parseTaggedTemplateExpression(t,n,e,i,a)}this.unexpected()});if(o)return o}return super.parseSubscript(e,t,n,r,i)}parseNewArguments(e){if(this.isRelational("<")){const t=this.tsTryParseAndCatch(()=>{const e=this.tsParseTypeArguments();return this.match(s.parenL)||this.unexpected(),e});t&&(e.typeParameters=t)}super.parseNewArguments(e)}parseExprOp(e,t,n,r,i){if(X(s._in.binop)>r&&!this.hasPrecedingLineBreak()&&this.isContextual("as")){const o=this.startNodeAt(t,n);o.expression=e;const a=this.tsTryNextParseConstantContext();return o.typeAnnotation=a||this.tsNextThenParseType(),this.finishNode(o,"TSAsExpression"),this.parseExprOp(o,t,n,r,i)}return super.parseExprOp(e,t,n,r,i)}checkReservedWord(e,t,n,r){}checkDuplicateExports(){}parseImport(e){return this.match(s.name)&&this.lookahead().type===s.eq?this.tsParseImportEqualsDeclaration(e):super.parseImport(e)}parseExport(e){if(this.match(s._import))return this.expect(s._import),this.tsParseImportEqualsDeclaration(e,!0);if(this.eat(s.eq)){const t=e;return t.expression=this.parseExpression(),this.semicolon(),this.finishNode(t,"TSExportAssignment")}if(this.eatContextual("as")){const t=e;return this.expectContextual("namespace"),t.id=this.parseIdentifier(),this.semicolon(),this.finishNode(t,"TSNamespaceExportDeclaration")}return super.parseExport(e)}isAbstractClass(){return this.isContextual("abstract")&&this.lookahead().type===s._class}parseExportDefaultExpression(){if(this.isAbstractClass()){const e=this.startNode();return this.next(),this.parseClass(e,!0,!0),e.abstract=!0,e}if("interface"===this.state.value){const e=this.tsParseDeclaration(this.startNode(),this.state.value,!0);if(e)return e}return super.parseExportDefaultExpression()}parseStatementContent(e,t){if(this.state.type===s._const){const e=this.lookahead();if(e.type===s.name&&"enum"===e.value){const e=this.startNode();return this.expect(s._const),this.expectContextual("enum"),this.tsParseEnumDeclaration(e,!0)}}return super.parseStatementContent(e,t)}parseAccessModifier(){return this.tsParseModifier(["public","protected","private"])}parseClassMember(e,t,n,r){const i=this.parseAccessModifier();i&&(t.accessibility=i),super.parseClassMember(e,t,n,r)}parseClassMemberWithIsStatic(e,t,n,r,i){const o=this.tsParseModifiers(["abstract","readonly","declare"]);Object.assign(t,o);const a=this.tsTryParseIndexSignature(t);if(a)return e.body.push(a),o.abstract&&this.raise(t.start,"Index signatures cannot have the 'abstract' modifier"),r&&this.raise(t.start,"Index signatures cannot have the 'static' modifier"),void(t.accessibility&&this.raise(t.start,`Index signatures cannot have an accessibility modifier ('${t.accessibility}')`));super.parseClassMemberWithIsStatic(e,t,n,r,i)}parsePostMemberNameModifiers(e){this.eat(s.question)&&(e.optional=!0),e.readonly&&this.match(s.parenL)&&this.raise(e.start,"Class methods cannot have the 'readonly' modifier"),e.declare&&this.match(s.parenL)&&this.raise(e.start,"Class methods cannot have the 'declare' modifier")}parseExpressionStatement(e,t){return("Identifier"===t.type?this.tsParseExpressionStatement(e,t):void 0)||super.parseExpressionStatement(e,t)}shouldParseExportDeclaration(){return!!this.tsIsDeclarationStart()||super.shouldParseExportDeclaration()}parseConditional(e,t,n,r,i){if(!i||!this.match(s.question))return super.parseConditional(e,t,n,r,i);const o=this.tryParse(()=>super.parseConditional(e,t,n,r));return o.node?(o.error&&(this.state=o.failState),o.node):(i.start=o.error.pos||this.state.start,e)}parseParenItem(e,t,n){if(e=super.parseParenItem(e,t,n),this.eat(s.question)&&(e.optional=!0,this.resetEndLocation(e)),this.match(s.colon)){const r=this.startNodeAt(t,n);return r.expression=e,r.typeAnnotation=this.tsParseTypeAnnotation(),this.finishNode(r,"TSTypeCastExpression")}return e}parseExportDeclaration(e){const t=this.state.start,n=this.state.startLoc,r=this.eatContextual("declare");let i;return this.match(s.name)&&(i=this.tsTryParseExportDeclaration()),i||(i=super.parseExportDeclaration(e)),i&&r&&(this.resetStartLocation(i,t,n),i.declare=!0),i}parseClassId(e,t,n){if((!t||n)&&this.isContextual("implements"))return;super.parseClassId(e,t,n,e.declare?1024:139);const r=this.tsTryParseTypeParameters();r&&(e.typeParameters=r)}parseClassPropertyAnnotation(e){!e.optional&&this.eat(s.bang)&&(e.definite=!0);const t=this.tsTryParseTypeAnnotation();t&&(e.typeAnnotation=t)}parseClassProperty(e){return this.parseClassPropertyAnnotation(e),e.declare&&this.match(s.equal)&&this.raise(this.state.start,"'declare' class fields cannot have an initializer"),super.parseClassProperty(e)}parseClassPrivateProperty(e){return e.abstract&&this.raise(e.start,"Private elements cannot have the 'abstract' modifier."),e.accessibility&&this.raise(e.start,`Private elements cannot have an accessibility modifier ('${e.accessibility}')`),this.parseClassPropertyAnnotation(e),super.parseClassPrivateProperty(e)}pushClassMethod(e,t,n,r,i,o){const a=this.tsTryParseTypeParameters();a&&(t.typeParameters=a),super.pushClassMethod(e,t,n,r,i,o)}pushClassPrivateMethod(e,t,n,r){const i=this.tsTryParseTypeParameters();i&&(t.typeParameters=i),super.pushClassPrivateMethod(e,t,n,r)}parseClassSuper(e){super.parseClassSuper(e),e.superClass&&this.isRelational("<")&&(e.superTypeParameters=this.tsParseTypeArguments()),this.eatContextual("implements")&&(e.implements=this.tsParseHeritageClause("implements"))}parseObjPropValue(e,...t){const n=this.tsTryParseTypeParameters();n&&(e.typeParameters=n),super.parseObjPropValue(e,...t)}parseFunctionParams(e,t){const n=this.tsTryParseTypeParameters();n&&(e.typeParameters=n),super.parseFunctionParams(e,t)}parseVarId(e,t){super.parseVarId(e,t),"Identifier"===e.id.type&&this.eat(s.bang)&&(e.definite=!0);const n=this.tsTryParseTypeAnnotation();n&&(e.id.typeAnnotation=n,this.resetEndLocation(e.id))}parseAsyncArrowFromCallExpression(e,t){return this.match(s.colon)&&(e.returnType=this.tsParseTypeAnnotation()),super.parseAsyncArrowFromCallExpression(e,t)}parseMaybeAssign(...e){let t,n,r,i;if(this.match(s.jsxTagStart)){if(t=this.state.clone(),n=this.tryParse(()=>super.parseMaybeAssign(...e),t),!n.error)return n.node;const{context:r}=this.state;r[r.length-1]===m.j_oTag?r.length-=2:r[r.length-1]===m.j_expr&&(r.length-=1)}if(!(n&&n.error||this.isRelational("<")))return super.parseMaybeAssign(...e);t=t||this.state.clone();const o=this.tryParse(t=>{i=this.tsParseTypeParameters();const n=super.parseMaybeAssign(...e);return("ArrowFunctionExpression"!==n.type||n.extra&&n.extra.parenthesized)&&t(),i&&0!==i.params.length&&this.resetStartLocationFromNode(n,i),n.typeParameters=i,n},t);if(!o.error&&!o.aborted)return o.node;if(!n&&(K(!this.hasPlugin("jsx")),r=this.tryParse(()=>super.parseMaybeAssign(...e),t),!r.error))return r.node;if(n&&n.node)return this.state=n.failState,n.node;if(o.node)return this.state=o.failState,o.node;if(r&&r.node)return this.state=r.failState,r.node;if(n&&n.thrown)throw n.error;if(o.thrown)throw o.error;if(r&&r.thrown)throw r.error;throw n&&n.error||o.error||r&&r.error}parseMaybeUnary(e){return!this.hasPlugin("jsx")&&this.isRelational("<")?this.tsParseTypeAssertion():super.parseMaybeUnary(e)}parseArrow(e){if(this.match(s.colon)){const t=this.tryParse(e=>{const t=this.tsParseTypeOrTypePredicateAnnotation(s.colon);return!this.canInsertSemicolon()&&this.match(s.arrow)||e(),t});if(t.aborted)return;t.thrown||(t.error&&(this.state=t.failState),e.returnType=t.node)}return super.parseArrow(e)}parseAssignableListItemTypes(e){this.eat(s.question)&&("Identifier"!==e.type&&this.raise(e.start,"A binding pattern parameter cannot be optional in an implementation signature."),e.optional=!0);const t=this.tsTryParseTypeAnnotation();return t&&(e.typeAnnotation=t),this.resetEndLocation(e),e}toAssignable(e,t,n){switch(e.type){case"TSTypeCastExpression":return super.toAssignable(this.typeCastToParameter(e),t,n);case"TSParameterProperty":return super.toAssignable(e,t,n);case"TSAsExpression":case"TSNonNullExpression":case"TSTypeAssertion":return e.expression=this.toAssignable(e.expression,t,n),e;default:return super.toAssignable(e,t,n)}}checkLVal(e,t=64,n,r){switch(e.type){case"TSTypeCastExpression":return;case"TSParameterProperty":return void this.checkLVal(e.parameter,t,n,"parameter property");case"TSAsExpression":case"TSNonNullExpression":case"TSTypeAssertion":return void this.checkLVal(e.expression,t,n,r);default:return void super.checkLVal(e,t,n,r)}}parseBindingAtom(){switch(this.state.type){case s._this:return this.parseIdentifier(!0);default:return super.parseBindingAtom()}}parseMaybeDecoratorArguments(e){if(this.isRelational("<")){const t=this.tsParseTypeArguments();if(this.match(s.parenL)){const n=super.parseMaybeDecoratorArguments(e);return n.typeParameters=t,n}this.unexpected(this.state.start,s.parenL)}return super.parseMaybeDecoratorArguments(e)}isClassMethod(){return this.isRelational("<")||super.isClassMethod()}isClassProperty(){return this.match(s.bang)||this.match(s.colon)||super.isClassProperty()}parseMaybeDefault(...e){const t=super.parseMaybeDefault(...e);return"AssignmentPattern"===t.type&&t.typeAnnotation&&t.right.startthis.tsParseTypeArguments());t&&(e.typeParameters=t)}return super.jsxParseOpeningElementAfterName(e)}getGetterSetterExpectedParamCount(e){const t=super.getGetterSetterExpectedParamCount(e),n=e.params[0];return n&&"Identifier"===n.type&&"this"===n.name?t+1:t}},v8intrinsic:e=>class extends e{parseV8Intrinsic(){if(this.match(s.modulo)){const e=this.state.start,t=this.startNode();if(this.eat(s.modulo),this.match(s.name)){const e=this.parseIdentifierName(this.state.start),n=this.createIdentifier(t,e);if(n.type="V8IntrinsicIdentifier",this.match(s.parenL))return n}this.unexpected(e)}}parseExprAtom(){return this.parseV8Intrinsic()||super.parseExprAtom(...arguments)}},placeholders:e=>class extends e{parsePlaceholder(e){if(this.match(s.placeholder)){const t=this.startNode();return this.next(),this.assertNoSpace("Unexpected space in placeholder."),t.name=super.parseIdentifier(!0),this.assertNoSpace("Unexpected space in placeholder."),this.expect(s.placeholder),this.finishPlaceholder(t,e)}}finishPlaceholder(e,t){const n=!(!e.expectedNode||"Placeholder"!==e.type);return e.expectedNode=t,n?e:this.finishNode(e,"Placeholder")}getTokenFromCode(e){return 37===e&&37===this.input.charCodeAt(this.state.pos+1)?this.finishOp(s.placeholder,2):super.getTokenFromCode(...arguments)}parseExprAtom(){return this.parsePlaceholder("Expression")||super.parseExprAtom(...arguments)}parseIdentifier(){return this.parsePlaceholder("Identifier")||super.parseIdentifier(...arguments)}checkReservedWord(e){void 0!==e&&super.checkReservedWord(...arguments)}parseBindingAtom(){return this.parsePlaceholder("Pattern")||super.parseBindingAtom(...arguments)}checkLVal(e){"Placeholder"!==e.type&&super.checkLVal(...arguments)}toAssignable(e){return e&&"Placeholder"===e.type&&"Expression"===e.expectedNode?(e.expectedNode="Pattern",e):super.toAssignable(...arguments)}verifyBreakContinue(e){e.label&&"Placeholder"===e.label.type||super.verifyBreakContinue(...arguments)}parseExpressionStatement(e,t){if("Placeholder"!==t.type||t.extra&&t.extra.parenthesized)return super.parseExpressionStatement(...arguments);if(this.match(s.colon)){const n=e;return n.label=this.finishPlaceholder(t,"Identifier"),this.next(),n.body=this.parseStatement("label"),this.finishNode(n,"LabeledStatement")}return this.semicolon(),e.name=t.name,this.finishPlaceholder(e,"Statement")}parseBlock(){return this.parsePlaceholder("BlockStatement")||super.parseBlock(...arguments)}parseFunctionId(){return this.parsePlaceholder("Identifier")||super.parseFunctionId(...arguments)}parseClass(e,t,n){const r=t?"ClassDeclaration":"ClassExpression";this.next(),this.takeDecorators(e);const i=this.parsePlaceholder("Identifier");if(i)if(this.match(s._extends)||this.match(s.placeholder)||this.match(s.braceL))e.id=i;else{if(n||!t)return e.id=null,e.body=this.finishPlaceholder(i,"ClassBody"),this.finishNode(e,r);this.unexpected(null,"A class name is required")}else this.parseClassId(e,t,n);return this.parseClassSuper(e),e.body=this.parsePlaceholder("ClassBody")||this.parseClassBody(!!e.superClass),this.finishNode(e,r)}parseExport(e){const t=this.parsePlaceholder("Identifier");if(!t)return super.parseExport(...arguments);if(!this.isContextual("from")&&!this.match(s.comma))return e.specifiers=[],e.source=null,e.declaration=this.finishPlaceholder(t,"Declaration"),this.finishNode(e,"ExportNamedDeclaration");this.expectPlugin("exportDefaultFrom");const n=this.startNode();return n.exported=t,e.specifiers=[this.finishNode(n,"ExportDefaultSpecifier")],super.parseExport(e)}maybeParseExportDefaultSpecifier(e){return!!(e.specifiers&&e.specifiers.length>0)||super.maybeParseExportDefaultSpecifier(...arguments)}checkExport(e){const{specifiers:t}=e;t&&t.length&&(e.specifiers=t.filter(e=>"Placeholder"===e.exported.type)),super.checkExport(e),e.specifiers=t}parseImport(e){const t=this.parsePlaceholder("Identifier");if(!t)return super.parseImport(...arguments);if(e.specifiers=[],!this.isContextual("from")&&!this.match(s.comma))return e.source=this.finishPlaceholder(t,"StringLiteral"),this.semicolon(),this.finishNode(e,"ImportDeclaration");const n=this.startNodeAtNode(t);if(n.local=t,this.finishNode(n,"ImportDefaultSpecifier"),e.specifiers.push(n),this.eat(s.comma)){this.maybeParseStarImportSpecifier(e)||this.parseNamedImportSpecifiers(e)}return this.expectContextual("from"),e.source=this.parseImportSource(),this.semicolon(),this.finishNode(e,"ImportDeclaration")}parseImportSource(){return this.parsePlaceholder("StringLiteral")||super.parseImportSource(...arguments)}}},ee=Object.keys(Q),te={sourceType:"script",sourceFilename:void 0,startLine:1,allowAwaitOutsideFunction:!1,allowReturnOutsideFunction:!1,allowImportExportEverywhere:!1,allowSuperOutsideMethod:!1,allowUndeclaredExports:!1,plugins:[],strictMode:null,ranges:!1,tokens:!1,createParenthesizedExpressions:!1,errorRecovery:!1};class ne{constructor(e,t){this.line=e,this.column=t}}class re{constructor(e,t){this.start=e,this.end=t}}function ie(e){return e[e.length-1]}class oe{constructor(){this.errors=[],this.potentialArrowAt=-1,this.noArrowAt=[],this.noArrowParamsConversionAt=[],this.inParameters=!1,this.maybeInArrowParameters=!1,this.inPipeline=!1,this.inType=!1,this.noAnonFunctionType=!1,this.inPropertyName=!1,this.inClassProperty=!1,this.hasFlowComment=!1,this.isIterator=!1,this.topicContext={maxNumOfResolvableTopics:0,maxTopicIndex:null},this.soloAwait=!1,this.inFSharpPipelineDirectBody=!1,this.classLevel=0,this.labels=[],this.decoratorStack=[[]],this.yieldPos=-1,this.awaitPos=-1,this.tokens=[],this.comments=[],this.trailingComments=[],this.leadingComments=[],this.commentStack=[],this.commentPreviousNode=null,this.pos=0,this.lineStart=0,this.type=s.eof,this.value=null,this.start=0,this.end=0,this.lastTokEndLoc=null,this.lastTokStartLoc=null,this.lastTokStart=0,this.lastTokEnd=0,this.context=[m.braceStatement],this.exprAllowed=!0,this.containsEsc=!1,this.containsOctal=!1,this.octalPosition=null,this.exportedIdentifiers=[],this.invalidTemplateEscapePosition=null}init(e){this.strict=!1!==e.strictMode&&"module"===e.sourceType,this.curLine=e.startLine,this.startLoc=this.endLoc=this.curPosition()}curPosition(){return new ne(this.curLine,this.pos-this.lineStart)}clone(e){const t=new oe,n=Object.keys(this);for(let r=0,i=n.length;r=48&&e<=57};const se=new Set(["g","m","s","i","y","u"]),ue={decBinOct:[46,66,69,79,95,98,101,111],hex:[46,88,95,120]},ce={bin:[48,49]};ce.oct=[...ce.bin,50,51,52,53,54,55],ce.dec=[...ce.oct,56,57],ce.hex=[...ce.dec,65,66,67,68,69,70,97,98,99,100,101,102];class le{constructor(e){this.type=e.type,this.value=e.value,this.start=e.start,this.end=e.end,this.loc=new re(e.startLoc,e.endLoc)}}const fe=/^('|")((?:\\?.)*?)\1/;class pe{constructor(e,t,n){this.type="",this.start=t,this.end=0,this.loc=new re(n),e&&e.options.ranges&&(this.range=[t,0]),e&&e.filename&&(this.loc.filename=e.filename)}__clone(){const e=new pe,t=Object.keys(this);for(let n=0,r=t.length;n"ParenthesizedExpression"===e.type?he(e.expression):e;const de={kind:"loop"},ye={kind:"switch"};class me extends class extends class extends class extends class extends class extends class extends class extends class extends class{constructor(){this.sawUnambiguousESM=!1,this.ambiguousScriptDifferentAst=!1}hasPlugin(e){return this.plugins.has(e)}getPluginOption(e,t){if(this.hasPlugin(e))return this.plugins.get(e)[t]}}{addComment(e){this.filename&&(e.loc.filename=this.filename),this.state.trailingComments.push(e),this.state.leadingComments.push(e)}adjustCommentsAfterTrailingComma(e,t,n){if(0===this.state.leadingComments.length)return;let r=null,i=t.length;for(;null===r&&i>0;)r=t[--i];if(null===r)return;for(let e=0;e0?r.trailingComments=o:void 0!==r.trailingComments&&(r.trailingComments=[])}processComment(e){if("Program"===e.type&&e.body.length>0)return;const t=this.state.commentStack;let n,r,i,o,a;if(this.state.trailingComments.length>0)this.state.trailingComments[0].start>=e.end?(i=this.state.trailingComments,this.state.trailingComments=[]):this.state.trailingComments.length=0;else if(t.length>0){const n=ie(t);n.trailingComments&&n.trailingComments[0].start>=e.end&&(i=n.trailingComments,delete n.trailingComments)}for(t.length>0&&ie(t).start>=e.start&&(n=t.pop());t.length>0&&ie(t).start>=e.start;)r=t.pop();if(!r&&n&&(r=n),n)switch(e.type){case"ObjectExpression":this.adjustCommentsAfterTrailingComma(e,e.properties);break;case"ObjectPattern":this.adjustCommentsAfterTrailingComma(e,e.properties,!0);break;case"CallExpression":this.adjustCommentsAfterTrailingComma(e,e.arguments);break;case"ArrayExpression":this.adjustCommentsAfterTrailingComma(e,e.elements);break;case"ArrayPattern":this.adjustCommentsAfterTrailingComma(e,e.elements,!0)}else this.state.commentPreviousNode&&("ImportSpecifier"===this.state.commentPreviousNode.type&&"ImportSpecifier"!==e.type||"ExportSpecifier"===this.state.commentPreviousNode.type&&"ExportSpecifier"!==e.type)&&this.adjustCommentsAfterTrailingComma(e,[this.state.commentPreviousNode],!0);if(r){if(r.leadingComments)if(r!==e&&r.leadingComments.length>0&&ie(r.leadingComments).end<=e.start)e.leadingComments=r.leadingComments,delete r.leadingComments;else for(o=r.leadingComments.length-2;o>=0;--o)if(r.leadingComments[o].end<=e.start){e.leadingComments=r.leadingComments.splice(0,o+1);break}}else if(this.state.leadingComments.length>0)if(ie(this.state.leadingComments).end<=e.start){if(this.state.commentPreviousNode)for(a=0;a0&&(e.leadingComments=this.state.leadingComments,this.state.leadingComments=[])}else{for(o=0;oe.start);o++);const t=this.state.leadingComments.slice(0,o);t.length&&(e.leadingComments=t),i=this.state.leadingComments.slice(o),0===i.length&&(i=null)}this.state.commentPreviousNode=e,i&&(i.length&&i[0].start>=e.start&&ie(i).end<=e.end?e.innerComments=i:e.trailingComments=i),t.push(e)}}{getLocationForPosition(e){let t;return t=e===this.state.start?this.state.startLoc:e===this.state.lastTokStart?this.state.lastTokStartLoc:e===this.state.end?this.state.endLoc:e===this.state.lastTokEnd?this.state.lastTokEndLoc:function(e,t){let n,r=1,i=0;for(f.lastIndex=0;(n=f.exec(e))&&n.index=this.length?this.finishToken(s.eof):e.override?e.override(this):this.getTokenFromCode(this.input.codePointAt(this.state.pos))}pushComment(e,t,n,r,i,o){const a={type:e?"CommentBlock":"CommentLine",value:t,start:n,end:r,loc:new re(i,o)};this.options.tokens&&this.state.tokens.push(a),this.state.comments.push(a),this.addComment(a)}skipBlockComment(){const e=this.state.curPosition(),t=this.state.pos,n=this.input.indexOf("*/",this.state.pos+2);if(-1===n)throw this.raise(t,"Unterminated comment");let r;for(this.state.pos=n+2,f.lastIndex=t;(r=f.exec(this.input))&&r.index=48&&t<=57)throw this.raise(this.state.pos,"Unexpected digit after hash token");if((this.hasPlugin("classPrivateProperties")||this.hasPlugin("classPrivateMethods"))&&this.state.classLevel>0)return++this.state.pos,void this.finishToken(s.hash);if("smart"!==this.getPluginOption("pipelineOperator","proposal"))throw this.raise(this.state.pos,"Unexpected character '#'");this.finishOp(s.hash,1)}readToken_dot(){const e=this.input.charCodeAt(this.state.pos+1);e>=48&&e<=57?this.readNumber(!0):46===e&&46===this.input.charCodeAt(this.state.pos+2)?(this.state.pos+=3,this.finishToken(s.ellipsis)):(++this.state.pos,this.finishToken(s.dot))}readToken_slash(){if(this.state.exprAllowed&&!this.state.inType)return++this.state.pos,void this.readRegexp();61===this.input.charCodeAt(this.state.pos+1)?this.finishOp(s.assign,2):this.finishOp(s.slash,1)}readToken_interpreter(){if(0!==this.state.pos||this.length<2)return!1;const e=this.state.pos;this.state.pos+=1;let t=this.input.charCodeAt(this.state.pos);if(33!==t)return!1;for(;!p(t)&&++this.state.pos=48&&t<=57?(++this.state.pos,this.finishToken(s.question)):(this.state.pos+=2,this.finishToken(s.questionDot)):61===t?this.finishOp(s.assign,3):this.finishOp(s.nullishCoalescing,2)}getTokenFromCode(e){switch(e){case 46:return void this.readToken_dot();case 40:return++this.state.pos,void this.finishToken(s.parenL);case 41:return++this.state.pos,void this.finishToken(s.parenR);case 59:return++this.state.pos,void this.finishToken(s.semi);case 44:return++this.state.pos,void this.finishToken(s.comma);case 91:return++this.state.pos,void this.finishToken(s.bracketL);case 93:return++this.state.pos,void this.finishToken(s.bracketR);case 123:return++this.state.pos,void this.finishToken(s.braceL);case 125:return++this.state.pos,void this.finishToken(s.braceR);case 58:return void(this.hasPlugin("functionBind")&&58===this.input.charCodeAt(this.state.pos+1)?this.finishOp(s.doubleColon,2):(++this.state.pos,this.finishToken(s.colon)));case 63:return void this.readToken_question();case 96:return++this.state.pos,void this.finishToken(s.backQuote);case 48:{const e=this.input.charCodeAt(this.state.pos+1);if(120===e||88===e)return void this.readRadixNumber(16);if(111===e||79===e)return void this.readRadixNumber(8);if(98===e||66===e)return void this.readRadixNumber(2)}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return void this.readNumber(!1);case 34:case 39:return void this.readString(e);case 47:return void this.readToken_slash();case 37:case 42:return void this.readToken_mult_modulo(e);case 124:case 38:return void this.readToken_pipe_amp(e);case 94:return void this.readToken_caret();case 43:case 45:return void this.readToken_plus_min(e);case 60:case 62:return void this.readToken_lt_gt(e);case 61:case 33:return void this.readToken_eq_excl(e);case 126:return void this.finishOp(s.tilde,1);case 64:return++this.state.pos,void this.finishToken(s.at);case 35:return void this.readToken_numberSign();case 92:return void this.readWord();default:if(D(e))return void this.readWord()}throw this.raise(this.state.pos,`Unexpected character '${String.fromCodePoint(e)}'`)}finishOp(e,t){const n=this.input.slice(this.state.pos,this.state.pos+t);this.state.pos+=t,this.finishToken(e,n)}readRegexp(){const e=this.state.pos;let t,n;for(;;){if(this.state.pos>=this.length)throw this.raise(e,"Unterminated regular expression");const r=this.input.charAt(this.state.pos);if(l.test(r))throw this.raise(e,"Unterminated regular expression");if(t)t=!1;else{if("["===r)n=!0;else if("]"===r&&n)n=!1;else if("/"===r&&!n)break;t="\\"===r}++this.state.pos}const r=this.input.slice(e,this.state.pos);++this.state.pos;let i="";for(;this.state.pos-1&&this.raise(this.state.pos+1,"Duplicate regular expression flag");else{if(!I(t)&&92!==t)break;this.raise(this.state.pos+1,"Invalid regular expression flag")}++this.state.pos,i+=e}this.finishToken(s.regexp,{pattern:r,flags:i})}readInt(e,t,n,r=!0){const i=this.state.pos,o=16===e?ue.hex:ue.decBinOct,a=16===e?ce.hex:10===e?ce.dec:8===e?ce.oct:ce.bin;let s=!1,u=0;for(let i=0,c=null==t?1/0:t;i-1||o.indexOf(t)>-1||Number.isNaN(t))&&this.raise(this.state.pos,"A numeric separator is only allowed between two digits"),r||this.raise(this.state.pos,"Numeric separators are not allowed inside unicode escape sequences or hex escape sequences"),++this.state.pos}else{if(c=t>=97?t-97+10:t>=65?t-65+10:ae(t)?t-48:1/0,c>=e)if(this.options.errorRecovery&&c<=9)c=0,this.raise(this.state.start+i+2,"Expected number in radix "+e);else{if(!n)break;c=0,s=!0}++this.state.pos,u=u*e+c}}return this.state.pos===i||null!=t&&this.state.pos-i!==t||s?null:u}readRadixNumber(e){const t=this.state.pos;let n=!1;this.state.pos+=2;const r=this.readInt(e);if(null==r&&this.raise(this.state.start+2,"Expected number in radix "+e),this.hasPlugin("bigInt")&&110===this.input.charCodeAt(this.state.pos)&&(++this.state.pos,n=!0),D(this.input.codePointAt(this.state.pos)))throw this.raise(this.state.pos,"Identifier directly after number");if(n){const e=this.input.slice(t,this.state.pos).replace(/[_n]/g,"");this.finishToken(s.bigint,e)}else this.finishToken(s.num,r)}readNumber(e){const t=this.state.pos;let n=!1,r=!1,i=!1;e||null!==this.readInt(10)||this.raise(t,"Invalid number");let o=this.state.pos-t>=2&&48===this.input.charCodeAt(t);o&&(this.state.strict&&this.raise(t,"Legacy octal literals are not allowed in strict mode"),/[89]/.test(this.input.slice(t,this.state.pos))&&(o=!1,i=!0));let a=this.input.charCodeAt(this.state.pos);if(46!==a||o||(++this.state.pos,this.readInt(10),n=!0,a=this.input.charCodeAt(this.state.pos)),69!==a&&101!==a||o||(a=this.input.charCodeAt(++this.state.pos),43!==a&&45!==a||++this.state.pos,null===this.readInt(10)&&this.raise(t,"Invalid number"),n=!0,a=this.input.charCodeAt(this.state.pos)),this.hasPlugin("numericSeparator")&&(o||i)){const e=this.input.slice(t,this.state.pos).indexOf("_");e>0&&this.raise(e+t,"Numeric separator can not be used after leading 0")}if(this.hasPlugin("bigInt")&&110===a&&((n||o||i)&&this.raise(t,"Invalid BigIntLiteral"),++this.state.pos,r=!0),D(this.input.codePointAt(this.state.pos)))throw this.raise(this.state.pos,"Identifier directly after number");const u=this.input.slice(t,this.state.pos).replace(/[_n]/g,"");if(r)return void this.finishToken(s.bigint,u);const c=o?parseInt(u,8):parseFloat(u);this.finishToken(s.num,c)}readCodePoint(e){let t;if(123===this.input.charCodeAt(this.state.pos)){const n=++this.state.pos;if(t=this.readHexChar(this.input.indexOf("}",this.state.pos)-this.state.pos,!0,e),++this.state.pos,null===t)--this.state.invalidTemplateEscapePosition;else if(t>1114111){if(!e)return this.state.invalidTemplateEscapePosition=n-2,null;this.raise(n,"Code point out of bounds")}}else t=this.readHexChar(4,!1,e);return t}readString(e){let t="",n=++this.state.pos;for(;;){if(this.state.pos>=this.length)throw this.raise(this.state.start,"Unterminated string constant");const r=this.input.charCodeAt(this.state.pos);if(r===e)break;if(92===r)t+=this.input.slice(n,this.state.pos),t+=this.readEscapedChar(!1),n=this.state.pos;else if(8232===r||8233===r)++this.state.pos,++this.state.curLine;else{if(p(r))throw this.raise(this.state.start,"Unterminated string constant");++this.state.pos}}t+=this.input.slice(n,this.state.pos++),this.finishToken(s.string,t)}readTmplToken(){let e="",t=this.state.pos,n=!1;for(;;){if(this.state.pos>=this.length)throw this.raise(this.state.start,"Unterminated template");const r=this.input.charCodeAt(this.state.pos);if(96===r||36===r&&123===this.input.charCodeAt(this.state.pos+1))return this.state.pos===this.state.start&&this.match(s.template)?36===r?(this.state.pos+=2,void this.finishToken(s.dollarBraceL)):(++this.state.pos,void this.finishToken(s.backQuote)):(e+=this.input.slice(t,this.state.pos),void this.finishToken(s.template,n?null:e));if(92===r){e+=this.input.slice(t,this.state.pos);const r=this.readEscapedChar(!0);null===r?n=!0:e+=r,t=this.state.pos}else if(p(r)){switch(e+=this.input.slice(t,this.state.pos),++this.state.pos,r){case 13:10===this.input.charCodeAt(this.state.pos)&&++this.state.pos;case 10:e+="\n";break;default:e+=String.fromCharCode(r)}++this.state.curLine,this.state.lineStart=this.state.pos,t=this.state.pos}else++this.state.pos}}readEscapedChar(e){const t=!e,n=this.input.charCodeAt(++this.state.pos);switch(++this.state.pos,n){case 110:return"\n";case 114:return"\r";case 120:{const e=this.readHexChar(2,!1,t);return null===e?null:String.fromCharCode(e)}case 117:{const e=this.readCodePoint(t);return null===e?null:String.fromCodePoint(e)}case 116:return"\t";case 98:return"\b";case 118:return"\v";case 102:return"\f";case 13:10===this.input.charCodeAt(this.state.pos)&&++this.state.pos;case 10:this.state.lineStart=this.state.pos,++this.state.curLine;case 8232:case 8233:return"";case 56:case 57:if(e){const e=this.state.pos-1;return this.state.invalidTemplateEscapePosition=e,null}default:if(n>=48&&n<=55){const t=this.state.pos-1;let n=this.input.substr(this.state.pos-1,3).match(/^[0-7]+/)[0],r=parseInt(n,8);r>255&&(n=n.slice(0,-1),r=parseInt(n,8)),this.state.pos+=n.length-1;const i=this.input.charCodeAt(this.state.pos);if("0"!==n||56===i||57===i){if(e)return this.state.invalidTemplateEscapePosition=t,null;this.state.strict?this.raise(t,"Octal literal in strict mode"):this.state.containsOctal||(this.state.containsOctal=!0,this.state.octalPosition=t)}return String.fromCharCode(r)}return String.fromCharCode(n)}}readHexChar(e,t,n){const r=this.state.pos,i=this.readInt(16,e,t,!1);return null===i&&(n?this.raise(r,"Bad character escape sequence"):(this.state.pos=r-1,this.state.invalidTemplateEscapePosition=r-1)),i}readWord1(){let e="";this.state.containsEsc=!1;const t=this.state.pos;let n=this.state.pos;for(;this.state.posthis.state.lastTokEnd&&this.raise(this.state.lastTokEnd,e)}unexpected(e,t="Unexpected token"){throw"string"!=typeof t&&(t=`Unexpected token, expected "${t.label}"`),this.raise(null!=e?e:this.state.start,t)}expectPlugin(e,t){if(!this.hasPlugin(e))throw this.raise(null!=t?t:this.state.start,`This experimental syntax requires enabling the parser plugin: '${e}'`,{missingPluginNames:[e]});return!0}expectOnePlugin(e,t){if(!e.some(e=>this.hasPlugin(e)))throw this.raise(null!=t?t:this.state.start,`This experimental syntax requires enabling one of the following parser plugin(s): '${e.join(", ")}'`,{missingPluginNames:e})}checkYieldAwaitInDefaultParams(){-1!==this.state.yieldPos&&(-1===this.state.awaitPos||this.state.yieldPos{throw n.node=e,n});if(this.state.errors.length>t.errors.length){const e=this.state;return this.state=t,{node:r,error:e.errors[t.errors.length],thrown:!1,aborted:!1,failState:e}}return{node:r,error:null,thrown:!1,aborted:!1,failState:null}}catch(e){const r=this.state;if(this.state=t,e instanceof SyntaxError)return{node:null,error:e,thrown:!0,aborted:!1,failState:r};if(e===n)return{node:n.node,error:null,thrown:!1,aborted:!0,failState:r};throw e}}}{startNode(){return new pe(this,this.state.start,this.state.startLoc)}startNodeAt(e,t){return new pe(this,e,t)}startNodeAtNode(e){return this.startNodeAt(e.start,e.loc.start)}finishNode(e,t){return this.finishNodeAt(e,t,this.state.lastTokEnd,this.state.lastTokEndLoc)}finishNodeAt(e,t,n,r){return e.type=t,e.end=n,e.loc.end=r,this.options.ranges&&(e.range[1]=n),this.processComment(e),e}resetStartLocation(e,t,n){e.start=t,e.loc.start=n,this.options.ranges&&(e.range[0]=t)}resetEndLocation(e,t=this.state.lastTokEnd,n=this.state.lastTokEndLoc){e.end=t,e.loc.end=n,this.options.ranges&&(e.range[1]=t)}resetStartLocationFromNode(e,t){this.resetStartLocation(e,t.start,t.loc.start)}}{toAssignable(e,t,n){var r;if(e)switch(e.type){case"Identifier":case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":break;case"ObjectExpression":e.type="ObjectPattern";for(let n=0,r=e.properties.length,o=r-1;n=n.left.start&&(t.start=0),this.checkLVal(u,void 0,void 0,"assignment expression");const a=he(u);let c;return"ObjectPattern"===a.type?c="`({a}) = 0` use `({a} = 0)`":"ArrayPattern"===a.type&&(c="`([a]) = 0` use `([a] = 0)`"),c&&(u.extra&&u.extra.parenthesized||"ParenthesizedExpression"===u.type)&&this.raise(a.start,`You're trying to assign to a parenthesized expression, eg. instead of ${c}`),this.next(),n.right=this.parseMaybeAssign(e),this.finishNode(n,"AssignmentExpression")}return a&&t.start&&this.unexpected(t.start),u}parseMaybeConditional(e,t,n){const r=this.state.start,i=this.state.startLoc,o=this.state.potentialArrowAt,a=this.parseExprOps(e,t);return"ArrowFunctionExpression"===a.type&&a.start===o?a:t&&t.start?a:this.parseConditional(a,e,r,i,n)}parseConditional(e,t,n,r,i){if(this.eat(s.question)){const i=this.startNodeAt(n,r);return i.test=e,i.consequent=this.parseMaybeAssign(),this.expect(s.colon),i.alternate=this.parseMaybeAssign(t),this.finishNode(i,"ConditionalExpression")}return e}parseExprOps(e,t){const n=this.state.start,r=this.state.startLoc,i=this.state.potentialArrowAt,o=this.parseMaybeUnary(t);return"ArrowFunctionExpression"===o.type&&o.start===i?o:t&&t.start?o:this.parseExprOp(o,n,r,-1,e)}parseExprOp(e,t,n,r,i){const o=this.state.type.binop;if(!(null==o||i&&this.match(s._in))&&o>r){const a=this.state.value;if("|>"===a&&this.state.inFSharpPipelineDirectBody)return e;const u=this.startNodeAt(t,n);u.left=e,u.operator=a,"**"!==a||"UnaryExpression"!==e.type||!this.options.createParenthesizedExpressions&&e.extra&&e.extra.parenthesized||this.raise(e.argument.start,"Illegal expression. Wrap left hand side or entire exponentiation in parentheses.");const c=this.state.type;if(c===s.pipeline?(this.expectPlugin("pipelineOperator"),this.state.inPipeline=!0,this.checkPipelineAtInfixOperator(e,t)):c===s.nullishCoalescing&&this.expectPlugin("nullishCoalescingOperator"),this.next(),c===s.pipeline&&"minimal"===this.getPluginOption("pipelineOperator","proposal")&&this.match(s.name)&&"await"===this.state.value&&this.scope.inAsync)throw this.raise(this.state.start,'Unexpected "await" after pipeline body; await must have parentheses in minimal proposal');if(u.right=this.parseExprOpRightExpr(c,o,i),c===s.nullishCoalescing){if(!("LogicalExpression"!==e.type||"??"===e.operator||e.extra&&e.extra.parenthesized))throw this.raise(e.start,"Nullish coalescing operator(??) requires parens when mixing with logical operators");if(!("LogicalExpression"!==u.right.type||"??"===u.right.operator||u.right.extra&&u.right.extra.parenthesized))throw this.raise(u.right.start,"Nullish coalescing operator(??) requires parens when mixing with logical operators")}return this.finishNode(u,c===s.logicalOR||c===s.logicalAND||c===s.nullishCoalescing?"LogicalExpression":"BinaryExpression"),this.parseExprOp(u,t,n,r,i)}return e}parseExprOpRightExpr(e,t,n){const r=this.state.start,i=this.state.startLoc;switch(e){case s.pipeline:switch(this.getPluginOption("pipelineOperator","proposal")){case"smart":return this.withTopicPermittingContext(()=>this.parseSmartPipelineBody(this.parseExprOpBaseRightExpr(e,t,n),r,i));case"fsharp":return this.withSoloAwaitPermittingContext(()=>this.parseFSharpPipelineBody(t,n))}default:return this.parseExprOpBaseRightExpr(e,t,n)}}parseExprOpBaseRightExpr(e,t,n){const r=this.state.start,i=this.state.startLoc;return this.parseExprOp(this.parseMaybeUnary(),r,i,e.rightAssociative?t-1:t,n)}parseMaybeUnary(e){if(this.isContextual("await")&&this.isAwaitAllowed())return this.parseAwait();if(this.state.type.prefix){const t=this.startNode(),n=this.match(s.incDec);if(t.operator=this.state.value,t.prefix=!0,"throw"===t.operator&&this.expectPlugin("throwExpressions"),this.next(),t.argument=this.parseMaybeUnary(),e&&e.start&&this.unexpected(e.start),n)this.checkLVal(t.argument,void 0,void 0,"prefix operation");else if(this.state.strict&&"delete"===t.operator){const e=t.argument;"Identifier"===e.type?this.raise(t.start,"Deleting local variable in strict mode"):"MemberExpression"===e.type&&"PrivateName"===e.property.type&&this.raise(t.start,"Deleting a private field is not allowed")}return this.finishNode(t,n?"UpdateExpression":"UnaryExpression")}const t=this.state.start,n=this.state.startLoc;let r=this.parseExprSubscripts(e);if(e&&e.start)return r;for(;this.state.type.postfix&&!this.canInsertSemicolon();){const e=this.startNodeAt(t,n);e.operator=this.state.value,e.prefix=!1,e.argument=r,this.checkLVal(r,void 0,void 0,"postfix operation"),this.next(),r=this.finishNode(e,"UpdateExpression")}return r}parseExprSubscripts(e){const t=this.state.start,n=this.state.startLoc,r=this.state.potentialArrowAt,i=this.parseExprAtom(e);return"ArrowFunctionExpression"===i.type&&i.start===r?i:e&&e.start?i:this.parseSubscripts(i,t,n)}parseSubscripts(e,t,n,r){const i={optionalChainMember:!1,maybeAsyncArrow:this.atPossibleAsync(e),stop:!1};do{e=this.parseSubscript(e,t,n,r,i),i.maybeAsyncArrow=!1}while(!i.stop);return e}parseSubscript(e,t,n,r,i){if(!r&&this.eat(s.doubleColon)){const o=this.startNodeAt(t,n);return o.object=e,o.callee=this.parseNoCallExpr(),i.stop=!0,this.parseSubscripts(this.finishNode(o,"BindExpression"),t,n,r)}if(this.match(s.questionDot)){if(this.expectPlugin("optionalChaining"),i.optionalChainMember=!0,r&&40===this.lookaheadCharCode())return i.stop=!0,e;this.next();const o=this.startNodeAt(t,n);return this.eat(s.bracketL)?(o.object=e,o.property=this.parseExpression(),o.computed=!0,o.optional=!0,this.expect(s.bracketR),this.finishNode(o,"OptionalMemberExpression")):this.eat(s.parenL)?(o.callee=e,o.arguments=this.parseCallExpressionArguments(s.parenR,!1),o.optional=!0,this.finishCallExpression(o,!0)):(o.object=e,o.property=this.parseIdentifier(!0),o.computed=!1,o.optional=!0,this.finishNode(o,"OptionalMemberExpression"))}if(this.eat(s.dot)){const r=this.startNodeAt(t,n);return r.object=e,r.property=this.parseMaybePrivateName(),r.computed=!1,"PrivateName"===r.property.type&&"Super"===r.object.type&&this.raise(t,"Private fields can't be accessed on super"),i.optionalChainMember?(r.optional=!1,this.finishNode(r,"OptionalMemberExpression")):this.finishNode(r,"MemberExpression")}if(this.eat(s.bracketL)){const r=this.startNodeAt(t,n);return r.object=e,r.property=this.parseExpression(),r.computed=!0,this.expect(s.bracketR),i.optionalChainMember?(r.optional=!1,this.finishNode(r,"OptionalMemberExpression")):this.finishNode(r,"MemberExpression")}if(!r&&this.match(s.parenL)){const r=this.state.maybeInArrowParameters,o=this.state.yieldPos,a=this.state.awaitPos;this.state.maybeInArrowParameters=!0,this.state.yieldPos=-1,this.state.awaitPos=-1,this.next();let u=this.startNodeAt(t,n);return u.callee=e,u.arguments=this.parseCallExpressionArguments(s.parenR,i.maybeAsyncArrow,"Import"===e.type,"Super"!==e.type,u),this.finishCallExpression(u,i.optionalChainMember),i.maybeAsyncArrow&&this.shouldParseAsyncArrow()?(i.stop=!0,u=this.parseAsyncArrowFromCallExpression(this.startNodeAt(t,n),u),this.checkYieldAwaitInDefaultParams(),this.state.yieldPos=o,this.state.awaitPos=a):(this.toReferencedListDeep(u.arguments),-1!==o&&(this.state.yieldPos=o),(this.isAwaitAllowed()||r)&&-1===a||(this.state.awaitPos=a)),this.state.maybeInArrowParameters=r,u}return this.match(s.backQuote)?this.parseTaggedTemplateExpression(t,n,e,i):(i.stop=!0,e)}parseTaggedTemplateExpression(e,t,n,r,i){const o=this.startNodeAt(e,t);return o.tag=n,o.quasi=this.parseTemplate(!0),i&&(o.typeParameters=i),r.optionalChainMember&&this.raise(e,"Tagged Template Literals are not allowed in optionalChain"),this.finishNode(o,"TaggedTemplateExpression")}atPossibleAsync(e){return"Identifier"===e.type&&"async"===e.name&&this.state.lastTokEnd===e.end&&!this.canInsertSemicolon()&&"async"===this.input.slice(e.start,e.end)}finishCallExpression(e,t){if("Import"===e.callee.type)if(1!==e.arguments.length)this.raise(e.start,"import() requires exactly one argument");else{const t=e.arguments[0];t&&"SpreadElement"===t.type&&this.raise(t.start,"... is not allowed in import()")}return this.finishNode(e,t?"OptionalCallExpression":"CallExpression")}parseCallExpressionArguments(e,t,n,r,i){const o=[];let a,u=!0;const c=this.state.inFSharpPipelineDirectBody;for(this.state.inFSharpPipelineDirectBody=!1;!this.eat(e);){if(u)u=!1;else if(this.expect(s.comma),this.match(e)){n&&this.raise(this.state.lastTokStart,"Trailing comma is disallowed inside import(...) arguments"),i&&this.addExtra(i,"trailingComma",this.state.lastTokStart),this.next();break}this.match(s.parenL)&&!a&&(a=this.state.start),o.push(this.parseExprListItem(!1,t?{start:0}:void 0,t?{start:0}:void 0,r))}return t&&a&&this.shouldParseAsyncArrow()&&this.unexpected(),this.state.inFSharpPipelineDirectBody=c,o}shouldParseAsyncArrow(){return this.match(s.arrow)&&!this.canInsertSemicolon()}parseAsyncArrowFromCallExpression(e,t){var n;return this.expect(s.arrow),this.parseArrowExpression(e,t.arguments,!0,null==(n=t.extra)?void 0:n.trailingComma),e}parseNoCallExpr(){const e=this.state.start,t=this.state.startLoc;return this.parseSubscripts(this.parseExprAtom(),e,t,!0)}parseExprAtom(e){this.state.type===s.slash&&this.readRegexp();const t=this.state.potentialArrowAt===this.state.start;let n;switch(this.state.type){case s._super:return n=this.startNode(),this.next(),!this.match(s.parenL)||this.scope.allowDirectSuper||this.options.allowSuperOutsideMethod?this.scope.allowSuper||this.options.allowSuperOutsideMethod||this.raise(n.start,"super is only allowed in object methods and classes"):this.raise(n.start,"super() is only valid inside a class constructor of a subclass. Maybe a typo in the method name ('constructor') or not extending another class?"),this.match(s.parenL)||this.match(s.bracketL)||this.match(s.dot)||this.raise(n.start,"super can only be used with function calls (i.e. super()) or in property accesses (i.e. super.prop or super[prop])"),this.finishNode(n,"Super");case s._import:return n=this.startNode(),this.next(),this.match(s.dot)?this.parseImportMetaProperty(n):(this.expectPlugin("dynamicImport",n.start),this.match(s.parenL)||this.unexpected(null,s.parenL),this.finishNode(n,"Import"));case s._this:return n=this.startNode(),this.next(),this.finishNode(n,"ThisExpression");case s.name:{n=this.startNode();const e=this.state.containsEsc,r=this.parseIdentifier();if(!e&&"async"===r.name&&this.match(s._function)&&!this.canInsertSemicolon()){const e=this.state.context.length-1;if(this.state.context[e]!==m.functionStatement)throw new Error("Internal error");return this.state.context[e]=m.functionExpression,this.next(),this.parseFunction(n,void 0,!0)}if(t&&!e&&"async"===r.name&&this.match(s.name)&&!this.canInsertSemicolon()){const e=[this.parseIdentifier()];return this.expect(s.arrow),this.parseArrowExpression(n,e,!0),n}return t&&this.match(s.arrow)&&!this.canInsertSemicolon()?(this.next(),this.parseArrowExpression(n,[r],!1),n):r}case s._do:{this.expectPlugin("doExpressions");const e=this.startNode();this.next();const t=this.state.labels;return this.state.labels=[],e.body=this.parseBlock(),this.state.labels=t,this.finishNode(e,"DoExpression")}case s.regexp:{const e=this.state.value;return n=this.parseLiteral(e.value,"RegExpLiteral"),n.pattern=e.pattern,n.flags=e.flags,n}case s.num:return this.parseLiteral(this.state.value,"NumericLiteral");case s.bigint:return this.parseLiteral(this.state.value,"BigIntLiteral");case s.string:return this.parseLiteral(this.state.value,"StringLiteral");case s._null:return n=this.startNode(),this.next(),this.finishNode(n,"NullLiteral");case s._true:case s._false:return this.parseBooleanLiteral();case s.parenL:return this.parseParenAndDistinguishExpression(t);case s.bracketL:{const t=this.state.inFSharpPipelineDirectBody;return this.state.inFSharpPipelineDirectBody=!1,n=this.startNode(),this.next(),n.elements=this.parseExprList(s.bracketR,!0,e,n),this.state.maybeInArrowParameters||this.toReferencedList(n.elements),this.state.inFSharpPipelineDirectBody=t,this.finishNode(n,"ArrayExpression")}case s.braceL:{const t=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!1;const n=this.parseObj(!1,e);return this.state.inFSharpPipelineDirectBody=t,n}case s._function:return this.parseFunctionExpression();case s.at:this.parseDecorators();case s._class:return n=this.startNode(),this.takeDecorators(n),this.parseClass(n,!1);case s._new:return this.parseNew();case s.backQuote:return this.parseTemplate(!1);case s.doubleColon:{n=this.startNode(),this.next(),n.object=null;const e=n.callee=this.parseNoCallExpr();if("MemberExpression"===e.type)return this.finishNode(n,"BindExpression");throw this.raise(e.start,"Binding should be performed on object property.")}case s.hash:if(this.state.inPipeline)return n=this.startNode(),"smart"!==this.getPluginOption("pipelineOperator","proposal")&&this.raise(n.start,"Primary Topic Reference found but pipelineOperator not passed 'smart' for 'proposal' option."),this.next(),this.primaryTopicReferenceIsAllowedInCurrentTopicContext()||this.raise(n.start,"Topic reference was used in a lexical context without topic binding"),this.registerTopicReference(),this.finishNode(n,"PipelinePrimaryTopicReference");default:throw this.unexpected()}}parseBooleanLiteral(){const e=this.startNode();return e.value=this.match(s._true),this.next(),this.finishNode(e,"BooleanLiteral")}parseMaybePrivateName(){if(this.match(s.hash)){this.expectOnePlugin(["classPrivateProperties","classPrivateMethods"]);const e=this.startNode();return this.next(),this.assertNoSpace("Unexpected space between # and identifier"),e.id=this.parseIdentifier(!0),this.finishNode(e,"PrivateName")}return this.parseIdentifier(!0)}parseFunctionExpression(){const e=this.startNode();let t=this.startNode();return this.next(),t=this.createIdentifier(t,"function"),this.scope.inGenerator&&this.eat(s.dot)?this.parseMetaProperty(e,t,"sent"):this.parseFunction(e)}parseMetaProperty(e,t,n){e.meta=t,"function"===t.name&&"sent"===n&&(this.isContextual(n)?this.expectPlugin("functionSent"):this.hasPlugin("functionSent")||this.unexpected());const r=this.state.containsEsc;return e.property=this.parseIdentifier(!0),(e.property.name!==n||r)&&this.raise(e.property.start,`The only valid meta property for ${t.name} is ${t.name}.${n}`),this.finishNode(e,"MetaProperty")}parseImportMetaProperty(e){const t=this.createIdentifier(this.startNodeAtNode(e),"import");return this.expect(s.dot),this.isContextual("meta")?(this.expectPlugin("importMeta"),this.inModule||this.raise(t.start,"import.meta may appear only with 'sourceType: \"module\"'",{code:"BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED"}),this.sawUnambiguousESM=!0):this.hasPlugin("importMeta")||this.raise(t.start,"Dynamic imports require a parameter: import('a.js')"),this.parseMetaProperty(e,t,"meta")}parseLiteral(e,t,n,r){n=n||this.state.start,r=r||this.state.startLoc;const i=this.startNodeAt(n,r);return this.addExtra(i,"rawValue",e),this.addExtra(i,"raw",this.input.slice(n,this.state.end)),i.value=e,this.next(),this.finishNode(i,t)}parseParenAndDistinguishExpression(e){const t=this.state.start,n=this.state.startLoc;let r;this.expect(s.parenL);const i=this.state.maybeInArrowParameters,o=this.state.yieldPos,a=this.state.awaitPos,u=this.state.inFSharpPipelineDirectBody;this.state.maybeInArrowParameters=!0,this.state.yieldPos=-1,this.state.awaitPos=-1,this.state.inFSharpPipelineDirectBody=!1;const c=this.state.start,l=this.state.startLoc,f=[],p={start:0},h={start:0};let d,y,m=!0;for(;!this.match(s.parenR);){if(m)m=!1;else if(this.expect(s.comma,h.start||null),this.match(s.parenR)){y=this.state.start;break}if(this.match(s.ellipsis)){const e=this.state.start,t=this.state.startLoc;d=this.state.start,f.push(this.parseParenItem(this.parseRestBinding(),e,t)),this.checkCommaAfterRest(41);break}f.push(this.parseMaybeAssign(!1,p,this.parseParenItem,h))}const v=this.state.start,b=this.state.startLoc;this.expect(s.parenR),this.state.maybeInArrowParameters=i,this.state.inFSharpPipelineDirectBody=u;let g=this.startNodeAt(t,n);if(e&&this.shouldParseArrow()&&(g=this.parseArrow(g))){this.checkYieldAwaitInDefaultParams(),this.state.yieldPos=o,this.state.awaitPos=a;for(let e=0;e1?(r=this.startNodeAt(c,l),r.expressions=f,this.finishNodeAt(r,"SequenceExpression",v,b)):r=f[0],!this.options.createParenthesizedExpressions)return this.addExtra(r,"parenthesized",!0),this.addExtra(r,"parenStart",t),r;const w=this.startNodeAt(t,n);return w.expression=r,this.finishNode(w,"ParenthesizedExpression"),w}shouldParseArrow(){return!this.canInsertSemicolon()}parseArrow(e){if(this.eat(s.arrow))return e}parseParenItem(e,t,n){return e}parseNew(){const e=this.startNode();let t=this.startNode();if(this.next(),t=this.createIdentifier(t,"new"),this.eat(s.dot)){const n=this.parseMetaProperty(e,t,"target");if(!this.scope.inNonArrowFunction&&!this.state.inClassProperty){let e="new.target can only be used in functions";this.hasPlugin("classProperties")&&(e+=" or class properties"),this.raise(n.start,e)}return n}return e.callee=this.parseNoCallExpr(),"Import"===e.callee.type?this.raise(e.callee.start,"Cannot use new with import(...)"):"OptionalMemberExpression"===e.callee.type||"OptionalCallExpression"===e.callee.type?this.raise(this.state.lastTokEnd,"constructors in/after an Optional Chain are not allowed"):this.eat(s.questionDot)&&this.raise(this.state.start,"constructors in/after an Optional Chain are not allowed"),this.parseNewArguments(e),this.finishNode(e,"NewExpression")}parseNewArguments(e){if(this.eat(s.parenL)){const t=this.parseExprList(s.parenR);this.toReferencedList(t),e.arguments=t}else e.arguments=[]}parseTemplateElement(e){const t=this.startNode();return null===this.state.value&&(e?this.state.invalidTemplateEscapePosition=null:this.raise(this.state.invalidTemplateEscapePosition||0,"Invalid escape sequence in template")),t.value={raw:this.input.slice(this.state.start,this.state.end).replace(/\r\n?/g,"\n"),cooked:this.state.value},this.next(),t.tail=this.match(s.backQuote),this.finishNode(t,"TemplateElement")}parseTemplate(e){const t=this.startNode();this.next(),t.expressions=[];let n=this.parseTemplateElement(e);for(t.quasis=[n];!n.tail;)this.expect(s.dollarBraceL),t.expressions.push(this.parseExpression()),this.expect(s.braceR),t.quasis.push(n=this.parseTemplateElement(e));return this.next(),this.finishNode(t,"TemplateLiteral")}parseObj(e,t){const n=Object.create(null);let r=!0;const i=this.startNode();for(i.properties=[],this.next();!this.eat(s.braceR);){if(r)r=!1;else if(this.expect(s.comma),this.match(s.braceR)){this.addExtra(i,"trailingComma",this.state.lastTokStart),this.next();break}const o=this.parseObjectMember(e,t);e||this.checkDuplicatedProto(o,n),o.shorthand&&this.addExtra(o,"shorthand",!0),i.properties.push(o)}return this.match(s.eq)||void 0===n.start||this.raise(n.start,"Redefinition of __proto__ property"),this.finishNode(i,e?"ObjectPattern":"ObjectExpression")}isAsyncProp(e){return!e.computed&&"Identifier"===e.key.type&&"async"===e.key.name&&(this.match(s.name)||this.match(s.num)||this.match(s.string)||this.match(s.bracketL)||this.state.type.keyword||this.match(s.star))&&!this.hasPrecedingLineBreak()}parseObjectMember(e,t){let n=[];if(this.match(s.at))for(this.hasPlugin("decorators")&&this.raise(this.state.start,"Stage 2 decorators disallow object literal property decorators");this.match(s.at);)n.push(this.parseDecorator());const r=this.startNode();let i,o,a=!1,u=!1;if(this.match(s.ellipsis))return n.length&&this.unexpected(),e?(this.next(),r.argument=this.parseIdentifier(),this.checkCommaAfterRest(125),this.finishNode(r,"RestElement")):this.parseSpread();n.length&&(r.decorators=n,n=[]),r.method=!1,(e||t)&&(i=this.state.start,o=this.state.startLoc),e||(a=this.eat(s.star));const c=this.state.containsEsc;return this.parsePropertyName(r),e||c||a||!this.isAsyncProp(r)?u=!1:(u=!0,a=this.eat(s.star),this.parsePropertyName(r)),this.parseObjPropValue(r,i,o,a,u,e,t,c),r}isGetterOrSetterMethod(e,t){return!t&&!e.computed&&"Identifier"===e.key.type&&("get"===e.key.name||"set"===e.key.name)&&(this.match(s.string)||this.match(s.num)||this.match(s.bracketL)||this.match(s.name)||!!this.state.type.keyword)}getGetterSetterExpectedParamCount(e){return"get"===e.kind?0:1}checkGetterSetterParams(e){const t=this.getGetterSetterExpectedParamCount(e),n=e.start;e.params.length!==t&&("get"===e.kind?this.raise(n,"getter must not have any formal parameters"):this.raise(n,"setter must have exactly one formal parameter")),"set"===e.kind&&"RestElement"===e.params[e.params.length-1].type&&this.raise(n,"setter function argument must not be a rest parameter")}parseObjectMethod(e,t,n,r,i){return n||t||this.match(s.parenL)?(r&&this.unexpected(),e.kind="method",e.method=!0,this.parseMethod(e,t,n,!1,!1,"ObjectMethod")):!i&&this.isGetterOrSetterMethod(e,r)?((t||n)&&this.unexpected(),e.kind=e.key.name,this.parsePropertyName(e),this.parseMethod(e,!1,!1,!1,!1,"ObjectMethod"),this.checkGetterSetterParams(e),e):void 0}parseObjectProperty(e,t,n,r,i){return e.shorthand=!1,this.eat(s.colon)?(e.value=r?this.parseMaybeDefault(this.state.start,this.state.startLoc):this.parseMaybeAssign(!1,i),this.finishNode(e,"ObjectProperty")):e.computed||"Identifier"!==e.key.type?void 0:(this.checkReservedWord(e.key.name,e.key.start,!0,!0),r?e.value=this.parseMaybeDefault(t,n,e.key.__clone()):this.match(s.eq)&&i?(i.start||(i.start=this.state.start),e.value=this.parseMaybeDefault(t,n,e.key.__clone())):e.value=e.key.__clone(),e.shorthand=!0,this.finishNode(e,"ObjectProperty"))}parseObjPropValue(e,t,n,r,i,o,a,s){const u=this.parseObjectMethod(e,r,i,o,s)||this.parseObjectProperty(e,t,n,o,a);return u||this.unexpected(),u}parsePropertyName(e){if(this.eat(s.bracketL))e.computed=!0,e.key=this.parseMaybeAssign(),this.expect(s.bracketR);else{const t=this.state.inPropertyName;this.state.inPropertyName=!0,e.key=this.match(s.num)||this.match(s.string)?this.parseExprAtom():this.parseMaybePrivateName(),"PrivateName"!==e.key.type&&(e.computed=!1),this.state.inPropertyName=t}return e.key}initFunction(e,t){e.id=null,e.generator=!1,e.async=!!t}parseMethod(e,t,n,r,i,o,a=!1){const s=this.state.yieldPos,c=this.state.awaitPos;this.state.yieldPos=-1,this.state.awaitPos=-1,this.initFunction(e,n),e.generator=!!t;const l=r;return this.scope.enter(64|u(n,e.generator)|(a?256:0)|(i?128:0)),this.parseFunctionParams(e,l),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBodyAndFinish(e,o,!0),this.scope.exit(),this.state.yieldPos=s,this.state.awaitPos=c,e}parseArrowExpression(e,t,n,r){this.scope.enter(16|u(n,!1)),this.initFunction(e,n);const i=this.state.maybeInArrowParameters,o=this.state.yieldPos,a=this.state.awaitPos;return this.state.maybeInArrowParameters=!1,this.state.yieldPos=-1,this.state.awaitPos=-1,t&&this.setArrowFunctionParameters(e,t,r),this.parseFunctionBody(e,!0),this.scope.exit(),this.state.maybeInArrowParameters=i,this.state.yieldPos=o,this.state.awaitPos=a,this.finishNode(e,"ArrowFunctionExpression")}setArrowFunctionParameters(e,t,n){e.params=this.toAssignableList(t,!0,"arrow function parameters",n)}isStrictBody(e){if("BlockStatement"===e.body.type&&e.body.directives.length)for(let t=0,n=e.body.directives;t" after pipeline body; arrow function in pipeline body must be parenthesized');"PipelineTopicExpression"===t&&"SequenceExpression"===e.type&&this.raise(n,"Pipeline body may not be a comma-separated sequence expression")}parseSmartPipelineBodyInStyle(e,t,n,r){const i=this.startNodeAt(n,r);switch(t){case"PipelineBareFunction":i.callee=e;break;case"PipelineBareConstructor":i.callee=e.callee;break;case"PipelineBareAwaitedFunction":i.callee=e.argument;break;case"PipelineTopicExpression":this.topicReferenceWasUsedInCurrentTopicContext()||this.raise(n,"Pipeline is in topic style but does not use topic reference"),i.expression=e;break;default:throw new Error(`Internal @babel/parser error: Unknown pipeline style (${t})`)}return this.finishNode(i,t)}checkSmartPipelineBodyStyle(e){return e.type,this.isSimpleReference(e)?"PipelineBareFunction":"PipelineTopicExpression"}isSimpleReference(e){switch(e.type){case"MemberExpression":return!e.computed&&this.isSimpleReference(e.object);case"Identifier":return!0;default:return!1}}withTopicPermittingContext(e){const t=this.state.topicContext;this.state.topicContext={maxNumOfResolvableTopics:1,maxTopicIndex:null};try{return e()}finally{this.state.topicContext=t}}withTopicForbiddingContext(e){const t=this.state.topicContext;this.state.topicContext={maxNumOfResolvableTopics:0,maxTopicIndex:null};try{return e()}finally{this.state.topicContext=t}}withSoloAwaitPermittingContext(e){const t=this.state.soloAwait;this.state.soloAwait=!0;try{return e()}finally{this.state.soloAwait=t}}registerTopicReference(){this.state.topicContext.maxTopicIndex=0}primaryTopicReferenceIsAllowedInCurrentTopicContext(){return this.state.topicContext.maxNumOfResolvableTopics>=1}topicReferenceWasUsedInCurrentTopicContext(){return null!=this.state.topicContext.maxTopicIndex&&this.state.topicContext.maxTopicIndex>=0}parseFSharpPipelineBody(e,t){const n=this.state.start,r=this.state.startLoc;this.state.potentialArrowAt=this.state.start;const i=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!0;const o=this.parseExprOp(this.parseMaybeUnary(),n,r,e,t);return this.state.inFSharpPipelineDirectBody=i,o}}{parseTopLevel(e,t){if(t.sourceType=this.options.sourceType,t.interpreter=this.parseInterpreterDirective(),this.parseBlockBody(t,!0,!0,s.eof),this.inModule&&!this.options.allowUndeclaredExports&&this.scope.undefinedExports.size>0)for(let e=0,t=Array.from(this.scope.undefinedExports);ethis.parseStatement("do")),this.state.labels.pop(),this.expect(s._while),e.test=this.parseHeaderExpression(),this.eat(s.semi),this.finishNode(e,"DoWhileStatement")}parseForStatement(e){this.next(),this.state.labels.push(de);let t=-1;if(this.isAwaitAllowed()&&this.eatContextual("await")&&(t=this.state.lastTokStart),this.scope.enter(0),this.expect(s.parenL),this.match(s.semi))return t>-1&&this.unexpected(t),this.parseFor(e,null);const n=this.isLet();if(this.match(s._var)||this.match(s._const)||n){const r=this.startNode(),i=n?"let":this.state.value;return this.next(),this.parseVar(r,!0,i),this.finishNode(r,"VariableDeclaration"),(this.match(s._in)||this.isContextual("of"))&&1===r.declarations.length?this.parseForIn(e,r,t):(t>-1&&this.unexpected(t),this.parseFor(e,r))}const r={start:0},i=this.parseExpression(!0,r);if(this.match(s._in)||this.isContextual("of")){const n=this.isContextual("of")?"for-of statement":"for-in statement";return this.toAssignable(i,void 0,n),this.checkLVal(i,void 0,void 0,n),this.parseForIn(e,i,t)}return r.start&&this.unexpected(r.start),t>-1&&this.unexpected(t),this.parseFor(e,i)}parseFunctionStatement(e,t,n){return this.next(),this.parseFunction(e,1|(n?0:2),t)}parseIfStatement(e){return this.next(),e.test=this.parseHeaderExpression(),e.consequent=this.parseStatement("if"),e.alternate=this.eat(s._else)?this.parseStatement("if"):null,this.finishNode(e,"IfStatement")}parseReturnStatement(e){return this.scope.inFunction||this.options.allowReturnOutsideFunction||this.raise(this.state.start,"'return' outside of function"),this.next(),this.isLineTerminator()?e.argument=null:(e.argument=this.parseExpression(),this.semicolon()),this.finishNode(e,"ReturnStatement")}parseSwitchStatement(e){this.next(),e.discriminant=this.parseHeaderExpression();const t=e.cases=[];let n,r;for(this.expect(s.braceL),this.state.labels.push(ye),this.scope.enter(0);!this.match(s.braceR);)if(this.match(s._case)||this.match(s._default)){const e=this.match(s._case);n&&this.finishNode(n,"SwitchCase"),t.push(n=this.startNode()),n.consequent=[],this.next(),e?n.test=this.parseExpression():(r&&this.raise(this.state.lastTokStart,"Multiple default clauses"),r=!0,n.test=null),this.expect(s.colon)}else n?n.consequent.push(this.parseStatement(null)):this.unexpected();return this.scope.exit(),n&&this.finishNode(n,"SwitchCase"),this.next(),this.state.labels.pop(),this.finishNode(e,"SwitchStatement")}parseThrowStatement(e){return this.next(),l.test(this.input.slice(this.state.lastTokEnd,this.state.start))&&this.raise(this.state.lastTokEnd,"Illegal newline after throw"),e.argument=this.parseExpression(),this.semicolon(),this.finishNode(e,"ThrowStatement")}parseTryStatement(e){if(this.next(),e.block=this.parseBlock(),e.handler=null,this.match(s._catch)){const t=this.startNode();if(this.next(),this.match(s.parenL)){this.expect(s.parenL),t.param=this.parseBindingAtom();const e="Identifier"===t.param.type;this.scope.enter(e?32:0),this.checkLVal(t.param,9,null,"catch clause"),this.expect(s.parenR)}else t.param=null,this.scope.enter(0);t.body=this.withTopicForbiddingContext(()=>this.parseBlock(!1,!1)),this.scope.exit(),e.handler=this.finishNode(t,"CatchClause")}return e.finalizer=this.eat(s._finally)?this.parseBlock():null,e.handler||e.finalizer||this.raise(e.start,"Missing catch or finally clause"),this.finishNode(e,"TryStatement")}parseVarStatement(e,t){return this.next(),this.parseVar(e,!1,t),this.semicolon(),this.finishNode(e,"VariableDeclaration")}parseWhileStatement(e){return this.next(),e.test=this.parseHeaderExpression(),this.state.labels.push(de),e.body=this.withTopicForbiddingContext(()=>this.parseStatement("while")),this.state.labels.pop(),this.finishNode(e,"WhileStatement")}parseWithStatement(e){return this.state.strict&&this.raise(this.state.start,"'with' in strict mode"),this.next(),e.object=this.parseHeaderExpression(),e.body=this.withTopicForbiddingContext(()=>this.parseStatement("with")),this.finishNode(e,"WithStatement")}parseEmptyStatement(e){return this.next(),this.finishNode(e,"EmptyStatement")}parseLabeledStatement(e,t,n,r){for(let e=0,r=this.state.labels;e=0;t--){const n=this.state.labels[t];if(n.statementStart!==e.start)break;n.statementStart=this.state.start,n.kind=i}return this.state.labels.push({name:t,kind:i,statementStart:this.state.start}),e.body=this.parseStatement(r?-1===r.indexOf("label")?r+"label":r:"label"),this.state.labels.pop(),e.label=n,this.finishNode(e,"LabeledStatement")}parseExpressionStatement(e,t){return e.expression=t,this.semicolon(),this.finishNode(e,"ExpressionStatement")}parseBlock(e=!1,t=!0){const n=this.startNode();return this.expect(s.braceL),t&&this.scope.enter(0),this.parseBlockBody(n,e,!1,s.braceR),t&&this.scope.exit(),this.finishNode(n,"BlockStatement")}isValidDirective(e){return"ExpressionStatement"===e.type&&"StringLiteral"===e.expression.type&&!e.expression.extra.parenthesized}parseBlockBody(e,t,n,r){const i=e.body=[],o=e.directives=[];this.parseBlockOrModuleBlockBody(i,t?o:void 0,n,r)}parseBlockOrModuleBlockBody(e,t,n,r){let i,o,a=!1;for(;!this.eat(r);){a||!this.state.containsOctal||o||(o=this.state.octalPosition);const r=this.parseStatement(null,n);if(t&&!a&&this.isValidDirective(r)){const e=this.stmtToDirective(r);t.push(e),void 0===i&&"use strict"===e.value.value&&(i=this.state.strict,this.setStrict(!0),o&&this.raise(o,"Octal literal in strict mode"))}else a=!0,e.push(r)}!1===i&&this.setStrict(!1)}parseFor(e,t){return e.init=t,this.expect(s.semi),e.test=this.match(s.semi)?null:this.parseExpression(),this.expect(s.semi),e.update=this.match(s.parenR)?null:this.parseExpression(),this.expect(s.parenR),e.body=this.withTopicForbiddingContext(()=>this.parseStatement("for")),this.scope.exit(),this.state.labels.pop(),this.finishNode(e,"ForStatement")}parseForIn(e,t,n){const r=this.match(s._in);return this.next(),r?n>-1&&this.unexpected(n):e.await=n>-1,"VariableDeclaration"!==t.type||null==t.declarations[0].init||r&&!this.state.strict&&"var"===t.kind&&"Identifier"===t.declarations[0].id.type?"AssignmentPattern"===t.type&&this.raise(t.start,"Invalid left-hand side in for-loop"):this.raise(t.start,`${r?"for-in":"for-of"} loop variable declaration may not have an initializer`),e.left=t,e.right=r?this.parseExpression():this.parseMaybeAssign(),this.expect(s.parenR),e.body=this.withTopicForbiddingContext(()=>this.parseStatement("for")),this.scope.exit(),this.state.labels.pop(),this.finishNode(e,r?"ForInStatement":"ForOfStatement")}parseVar(e,t,n){const r=e.declarations=[],i=this.hasPlugin("typescript");for(e.kind=n;;){const e=this.startNode();if(this.parseVarId(e,n),this.eat(s.eq)?e.init=this.parseMaybeAssign(t):("const"!==n||this.match(s._in)||this.isContextual("of")?"Identifier"===e.id.type||t&&(this.match(s._in)||this.isContextual("of"))||this.raise(this.state.lastTokEnd,"Complex binding patterns require an initialization value"):i||this.unexpected(),e.init=null),r.push(this.finishNode(e,"VariableDeclarator")),!this.eat(s.comma))break}return e}parseVarId(e,t){e.id=this.parseBindingAtom(),this.checkLVal(e.id,"var"===t?5:9,void 0,"variable declaration","var"!==t)}parseFunction(e,t=0,n=!1){const r=1&t,i=2&t,o=!(!r||4&t);this.initFunction(e,n),this.match(s.star)&&i&&this.raise(this.state.start,"Generators can only be declared at the top level or inside a block"),e.generator=this.eat(s.star),r&&(e.id=this.parseFunctionId(o));const a=this.state.maybeInArrowParameters,c=this.state.inClassProperty,l=this.state.yieldPos,f=this.state.awaitPos;return this.state.maybeInArrowParameters=!1,this.state.inClassProperty=!1,this.state.yieldPos=-1,this.state.awaitPos=-1,this.scope.enter(u(e.async,e.generator)),r||(e.id=this.parseFunctionId()),this.parseFunctionParams(e),this.withTopicForbiddingContext(()=>{this.parseFunctionBodyAndFinish(e,r?"FunctionDeclaration":"FunctionExpression")}),this.scope.exit(),r&&!i&&this.registerFunctionStatementId(e),this.state.maybeInArrowParameters=a,this.state.inClassProperty=c,this.state.yieldPos=l,this.state.awaitPos=f,e}parseFunctionId(e){return e||this.match(s.name)?this.parseIdentifier():null}parseFunctionParams(e,t){const n=this.state.inParameters;this.state.inParameters=!0,this.expect(s.parenL),e.params=this.parseBindingList(s.parenR,41,!1,t),this.state.inParameters=n,this.checkYieldAwaitInDefaultParams()}registerFunctionStatementId(e){e.id&&this.scope.declareName(e.id.name,this.state.strict||e.generator||e.async?this.scope.treatFunctionsAsVar?5:9:17,e.id.start)}parseClass(e,t,n){this.next(),this.takeDecorators(e);const r=this.state.strict;return this.state.strict=!0,this.parseClassId(e,t,n),this.parseClassSuper(e),e.body=this.parseClassBody(!!e.superClass),this.state.strict=r,this.finishNode(e,t?"ClassDeclaration":"ClassExpression")}isClassProperty(){return this.match(s.eq)||this.match(s.semi)||this.match(s.braceR)}isClassMethod(){return this.match(s.parenL)}isNonstaticConstructor(e){return!(e.computed||e.static||"constructor"!==e.key.name&&"constructor"!==e.key.value)}parseClassBody(e){this.state.classLevel++;const t={hadConstructor:!1};let n=[];const r=this.startNode();if(r.body=[],this.expect(s.braceL),this.withTopicForbiddingContext(()=>{for(;!this.eat(s.braceR);){if(this.eat(s.semi)){if(n.length>0)throw this.raise(this.state.lastTokEnd,"Decorators must not be followed by a semicolon");continue}if(this.match(s.at)){n.push(this.parseDecorator());continue}const i=this.startNode();n.length&&(i.decorators=n,this.resetStartLocationFromNode(i,n[0]),n=[]),this.parseClassMember(r,i,t,e),"constructor"===i.kind&&i.decorators&&i.decorators.length>0&&this.raise(i.start,"Decorators can't be used with a constructor. Did you mean '@dec class { ... }'?")}}),n.length)throw this.raise(this.state.start,"You have trailing decorators with no method");return this.state.classLevel--,this.finishNode(r,"ClassBody")}parseClassMember(e,t,n,r){let i=!1;const o=this.state.containsEsc;if(this.match(s.name)&&"static"===this.state.value){const n=this.parseIdentifier(!0);if(this.isClassMethod()){const r=t;return r.kind="method",r.computed=!1,r.key=n,r.static=!1,void this.pushClassMethod(e,r,!1,!1,!1,!1)}if(this.isClassProperty()){const r=t;return r.computed=!1,r.key=n,r.static=!1,void e.body.push(this.parseClassProperty(r))}if(o)throw this.unexpected();i=!0}this.parseClassMemberWithIsStatic(e,t,n,i,r)}parseClassMemberWithIsStatic(e,t,n,r,i){const o=t,a=t,u=t,c=t,l=o,f=o;if(t.static=r,this.eat(s.star))return l.kind="method",this.parseClassPropertyName(l),"PrivateName"===l.key.type?void this.pushClassPrivateMethod(e,a,!0,!1):(this.isNonstaticConstructor(o)&&this.raise(o.key.start,"Constructor can't be a generator"),void this.pushClassMethod(e,o,!0,!1,!1,!1));const p=this.state.containsEsc,h=this.parseClassPropertyName(t),d="PrivateName"===h.type,y="Identifier"===h.type,m=this.state.start;if(this.parsePostMemberNameModifiers(f),this.isClassMethod()){if(l.kind="method",d)return void this.pushClassPrivateMethod(e,a,!1,!1);const t=this.isNonstaticConstructor(o);let r=!1;t&&(o.kind="constructor",n.hadConstructor&&!this.hasPlugin("typescript")&&this.raise(h.start,"Duplicate constructor in the same class"),n.hadConstructor=!0,r=i),this.pushClassMethod(e,o,!1,!1,t,r)}else if(this.isClassProperty())d?this.pushClassPrivateProperty(e,c):this.pushClassProperty(e,u);else if(!y||"async"!==h.name||p||this.isLineTerminator())!y||"get"!==h.name&&"set"!==h.name||p||this.match(s.star)&&this.isLineTerminator()?this.isLineTerminator()?d?this.pushClassPrivateProperty(e,c):this.pushClassProperty(e,u):this.unexpected():(l.kind=h.name,this.parseClassPropertyName(o),"PrivateName"===l.key.type?this.pushClassPrivateMethod(e,a,!1,!1):(this.isNonstaticConstructor(o)&&this.raise(o.key.start,"Constructor can't have get/set modifier"),this.pushClassMethod(e,o,!1,!1,!1,!1)),this.checkGetterSetterParams(o));else{const t=this.eat(s.star);f.optional&&this.unexpected(m),l.kind="method",this.parseClassPropertyName(l),this.parsePostMemberNameModifiers(f),"PrivateName"===l.key.type?this.pushClassPrivateMethod(e,a,t,!0):(this.isNonstaticConstructor(o)&&this.raise(o.key.start,"Constructor can't be an async function"),this.pushClassMethod(e,o,t,!0,!1,!1))}}parseClassPropertyName(e){const t=this.parsePropertyName(e);return e.computed||!e.static||"prototype"!==t.name&&"prototype"!==t.value||this.raise(t.start,"Classes may not have static property named prototype"),"PrivateName"===t.type&&"constructor"===t.id.name&&this.raise(t.start,"Classes may not have a private field named '#constructor'"),t}pushClassProperty(e,t){t.computed||"constructor"!==t.key.name&&"constructor"!==t.key.value||this.raise(t.key.start,"Classes may not have a field named 'constructor'"),e.body.push(this.parseClassProperty(t))}pushClassPrivateProperty(e,t){this.expectPlugin("classPrivateProperties",t.key.start),e.body.push(this.parseClassPrivateProperty(t))}pushClassMethod(e,t,n,r,i,o){e.body.push(this.parseMethod(t,n,r,i,o,"ClassMethod",!0))}pushClassPrivateMethod(e,t,n,r){this.expectPlugin("classPrivateMethods",t.key.start),e.body.push(this.parseMethod(t,n,r,!1,!1,"ClassPrivateMethod",!0))}parsePostMemberNameModifiers(e){}parseAccessModifier(){}parseClassPrivateProperty(e){return this.state.inClassProperty=!0,this.scope.enter(320),e.value=this.eat(s.eq)?this.parseMaybeAssign():null,this.semicolon(),this.state.inClassProperty=!1,this.scope.exit(),this.finishNode(e,"ClassPrivateProperty")}parseClassProperty(e){return e.typeAnnotation||this.expectPlugin("classProperties"),this.state.inClassProperty=!0,this.scope.enter(320),this.match(s.eq)?(this.expectPlugin("classProperties"),this.next(),e.value=this.parseMaybeAssign()):e.value=null,this.semicolon(),this.state.inClassProperty=!1,this.scope.exit(),this.finishNode(e,"ClassProperty")}parseClassId(e,t,n,r=139){this.match(s.name)?(e.id=this.parseIdentifier(),t&&this.checkLVal(e.id,r,void 0,"class name")):n||!t?e.id=null:this.unexpected(null,"A class name is required")}parseClassSuper(e){e.superClass=this.eat(s._extends)?this.parseExprSubscripts():null}parseExport(e){const t=this.maybeParseExportDefaultSpecifier(e),n=!t||this.eat(s.comma),r=n&&this.eatExportStar(e),i=r&&this.maybeParseExportNamespaceSpecifier(e),o=n&&(!i||this.eat(s.comma)),a=t||r;if(r&&!i)return t&&this.unexpected(),this.parseExportFrom(e,!0),this.finishNode(e,"ExportAllDeclaration");const u=this.maybeParseExportNamedSpecifiers(e);if(t&&n&&!r&&!u||i&&o&&!u)throw this.unexpected(null,s.braceL);let c;if(a||u?(c=!1,this.parseExportFrom(e,a)):c=this.maybeParseExportDeclaration(e),a||u||c)return this.checkExport(e,!0,!1,!!e.source),this.finishNode(e,"ExportNamedDeclaration");if(this.eat(s._default))return e.declaration=this.parseExportDefaultExpression(),this.checkExport(e,!0,!0),this.finishNode(e,"ExportDefaultDeclaration");throw this.unexpected(null,s.braceL)}eatExportStar(e){return this.eat(s.star)}maybeParseExportDefaultSpecifier(e){if(this.isExportDefaultSpecifier()){this.expectPlugin("exportDefaultFrom");const t=this.startNode();return t.exported=this.parseIdentifier(!0),e.specifiers=[this.finishNode(t,"ExportDefaultSpecifier")],!0}return!1}maybeParseExportNamespaceSpecifier(e){if(this.isContextual("as")){e.specifiers||(e.specifiers=[]);const t=this.startNodeAt(this.state.lastTokStart,this.state.lastTokStartLoc);return this.next(),t.exported=this.parseIdentifier(!0),e.specifiers.push(this.finishNode(t,"ExportNamespaceSpecifier")),!0}return!1}maybeParseExportNamedSpecifiers(e){return!!this.match(s.braceL)&&(e.specifiers||(e.specifiers=[]),e.specifiers.push(...this.parseExportSpecifiers()),e.source=null,e.declaration=null,!0)}maybeParseExportDeclaration(e){if(this.shouldParseExportDeclaration()){if(this.isContextual("async")){const e=this.nextTokenStart();this.isUnparsedContextual(e,"function")||this.unexpected(e,'Unexpected token, expected "function"')}return e.specifiers=[],e.source=null,e.declaration=this.parseExportDeclaration(e),!0}return!1}isAsyncFunction(){if(!this.isContextual("async"))return!1;const e=this.nextTokenStart();return!l.test(this.input.slice(this.state.pos,e))&&this.isUnparsedContextual(e,"function")}parseExportDefaultExpression(){const e=this.startNode(),t=this.isAsyncFunction();if(this.match(s._function)||t)return this.next(),t&&this.next(),this.parseFunction(e,5,t);if(this.match(s._class))return this.parseClass(e,!0,!0);if(this.match(s.at))return this.hasPlugin("decorators")&&this.getPluginOption("decorators","decoratorsBeforeExport")&&this.raise(this.state.start,"Decorators must be placed *before* the 'export' keyword. You can set the 'decoratorsBeforeExport' option to false to use the 'export @decorator class {}' syntax"),this.parseDecorators(!1),this.parseClass(e,!0,!0);if(this.match(s._const)||this.match(s._var)||this.isLet())throw this.raise(this.state.start,"Only expressions, functions or classes are allowed as the `default` export.");{const e=this.parseMaybeAssign();return this.semicolon(),e}}parseExportDeclaration(e){return this.parseStatement(null)}isExportDefaultSpecifier(){if(this.match(s.name))return"async"!==this.state.value&&"let"!==this.state.value;if(!this.match(s._default))return!1;const e=this.nextTokenStart();return 44===this.input.charCodeAt(e)||this.isUnparsedContextual(e,"from")}parseExportFrom(e,t){this.eatContextual("from")?(e.source=this.parseImportSource(),this.checkExport(e)):t?this.unexpected():e.source=null,this.semicolon()}shouldParseExportDeclaration(){if(this.match(s.at)&&(this.expectOnePlugin(["decorators","decorators-legacy"]),this.hasPlugin("decorators"))){if(!this.getPluginOption("decorators","decoratorsBeforeExport"))return!0;this.unexpected(this.state.start,"Decorators must be placed *before* the 'export' keyword. You can set the 'decoratorsBeforeExport' option to false to use the 'export @decorator class {}' syntax")}return"var"===this.state.type.keyword||"const"===this.state.type.keyword||"function"===this.state.type.keyword||"class"===this.state.type.keyword||this.isLet()||this.isAsyncFunction()}checkExport(e,t,n,r){if(t)if(n)this.checkDuplicateExports(e,"default");else if(e.specifiers&&e.specifiers.length)for(let t=0,n=e.specifiers;t-1&&this.raise(e.start,"default"===t?"Only one default export allowed per module.":`\`${t}\` has already been exported. Exported identifiers must be unique.`),this.state.exportedIdentifiers.push(t)}parseExportSpecifiers(){const e=[];let t=!0;for(this.expect(s.braceL);!this.eat(s.braceR);){if(t)t=!1;else if(this.expect(s.comma),this.eat(s.braceR))break;const n=this.startNode();n.local=this.parseIdentifier(!0),n.exported=this.eatContextual("as")?this.parseIdentifier(!0):n.local.__clone(),e.push(this.finishNode(n,"ExportSpecifier"))}return e}parseImport(e){if(e.specifiers=[],!this.match(s.string)){const t=!this.maybeParseDefaultImportSpecifier(e)||this.eat(s.comma),n=t&&this.maybeParseStarImportSpecifier(e);t&&!n&&this.parseNamedImportSpecifiers(e),this.expectContextual("from")}return e.source=this.parseImportSource(),this.semicolon(),this.finishNode(e,"ImportDeclaration")}parseImportSource(){return this.match(s.string)||this.unexpected(),this.parseExprAtom()}shouldParseDefaultImport(e){return this.match(s.name)}parseImportSpecifierLocal(e,t,n,r){t.local=this.parseIdentifier(),this.checkLVal(t.local,9,void 0,r),e.specifiers.push(this.finishNode(t,n))}maybeParseDefaultImportSpecifier(e){return!!this.shouldParseDefaultImport(e)&&(this.parseImportSpecifierLocal(e,this.startNode(),"ImportDefaultSpecifier","default import specifier"),!0)}maybeParseStarImportSpecifier(e){if(this.match(s.star)){const t=this.startNode();return this.next(),this.expectContextual("as"),this.parseImportSpecifierLocal(e,t,"ImportNamespaceSpecifier","import namespace specifier"),!0}return!1}parseNamedImportSpecifiers(e){let t=!0;for(this.expect(s.braceL);!this.eat(s.braceR);){if(t)t=!1;else{if(this.eat(s.colon))throw this.raise(this.state.start,"ES2015 named imports do not destructure. Use another statement for destructuring after the import.");if(this.expect(s.comma),this.eat(s.braceR))break}this.parseImportSpecifier(e)}}parseImportSpecifier(e){const t=this.startNode();t.imported=this.parseIdentifier(!0),this.eatContextual("as")?t.local=this.parseIdentifier():(this.checkReservedWord(t.imported.name,t.start,!0,!0),t.local=t.imported.__clone()),this.checkLVal(t.local,9,void 0,"import specifier"),e.specifiers.push(this.finishNode(t,"ImportSpecifier"))}}{constructor(e,t){super(e=function(e){const t={};for(let n=0,r=Object.keys(te);n`'${e}'`).join(", "))}(e.plugins),n=function(e){const t=ee.filter(t=>q(e,t)),n=t.join("/");let r=be[n];if(!r){r=me;for(let e=0;e!0}],e.set(n,o);break;case"invalidate":o=[{value:s,valid:a.validator()}],e.set(n,o);break;case"valid":o?o.push({value:s,valid:a.validator()}):(o=[{value:s,valid:a.validator()}],e.set(n,o))}return s}}Object.defineProperty(t,"__esModule",{value:!0}),t.makeStrongCache=function(e){return r(new Map,e)},t.makeWeakCache=function(e){return r(new WeakMap,e)},t.assertSimpleType=o;class i{constructor(e){this._active=!0,this._never=!1,this._forever=!1,this._invalidate=!1,this._configured=!1,this._pairs=[],this._data=e}simple(){return function(e){function t(t){if("boolean"!=typeof t)return e.using(()=>o(t()));t?e.forever():e.never()}return t.forever=()=>e.forever(),t.never=()=>e.never(),t.using=t=>e.using(()=>o(t())),t.invalidate=t=>e.invalidate(()=>o(t())),t}(this)}mode(){return this._never?"never":this._forever?"forever":this._invalidate?"invalidate":"valid"}forever(){if(!this._active)throw new Error("Cannot change caching after evaluation has completed.");if(this._never)throw new Error("Caching has already been configured with .never()");this._forever=!0,this._configured=!0}never(){if(!this._active)throw new Error("Cannot change caching after evaluation has completed.");if(this._forever)throw new Error("Caching has already been configured with .forever()");this._never=!0,this._configured=!0}using(e){if(!this._active)throw new Error("Cannot change caching after evaluation has completed.");if(this._never||this._forever)throw new Error("Caching has already been configured with .never or .forever()");this._configured=!0;const t=e(this._data);return this._pairs.push([t,e]),t}invalidate(e){if(!this._active)throw new Error("Cannot change caching after evaluation has completed.");if(this._never||this._forever)throw new Error("Caching has already been configured with .never or .forever()");this._invalidate=!0,this._configured=!0;const t=e(this._data);return this._pairs.push([t,e]),t}validator(){const e=this._pairs;return t=>e.every(([e,n])=>e===n(t))}deactivate(){this._active=!1}configured(){return this._configured}}function o(e){if(null!=e&&"string"!=typeof e&&"boolean"!=typeof e&&"number"!=typeof e)throw new Error("Cache keys must be either string, boolean, number, null, or undefined.");return e}},function(e,t,n){var r=n(23);e.exports=function(e){if("string"==typeof e||r(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Plugin=function(e){throw new Error(`The (${e}) Babel 5 plugin is being run with an unsupported Babel version.`)},Object.defineProperty(t,"File",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"buildExternalHelpers",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"resolvePlugin",{enumerable:!0,get:function(){return o.resolvePlugin}}),Object.defineProperty(t,"resolvePreset",{enumerable:!0,get:function(){return o.resolvePreset}}),Object.defineProperty(t,"version",{enumerable:!0,get:function(){return a.version}}),Object.defineProperty(t,"getEnv",{enumerable:!0,get:function(){return s.getEnv}}),Object.defineProperty(t,"tokTypes",{enumerable:!0,get:function(){return function(){const e=n(38);return function(){return e},e}().tokTypes}}),Object.defineProperty(t,"traverse",{enumerable:!0,get:function(){return function(){const e=m(n(7));return function(){return e},e}().default}}),Object.defineProperty(t,"template",{enumerable:!0,get:function(){return function(){const e=m(n(39));return function(){return e},e}().default}}),Object.defineProperty(t,"createConfigItem",{enumerable:!0,get:function(){return c.createConfigItem}}),Object.defineProperty(t,"loadPartialConfig",{enumerable:!0,get:function(){return l.loadPartialConfig}}),Object.defineProperty(t,"loadOptions",{enumerable:!0,get:function(){return l.loadOptions}}),Object.defineProperty(t,"transform",{enumerable:!0,get:function(){return f.transform}}),Object.defineProperty(t,"transformSync",{enumerable:!0,get:function(){return f.transformSync}}),Object.defineProperty(t,"transformAsync",{enumerable:!0,get:function(){return f.transformAsync}}),Object.defineProperty(t,"transformFile",{enumerable:!0,get:function(){return p.transformFile}}),Object.defineProperty(t,"transformFileSync",{enumerable:!0,get:function(){return p.transformFileSync}}),Object.defineProperty(t,"transformFileAsync",{enumerable:!0,get:function(){return p.transformFileAsync}}),Object.defineProperty(t,"transformFromAst",{enumerable:!0,get:function(){return h.transformFromAst}}),Object.defineProperty(t,"transformFromAstSync",{enumerable:!0,get:function(){return h.transformFromAstSync}}),Object.defineProperty(t,"transformFromAstAsync",{enumerable:!0,get:function(){return h.transformFromAstAsync}}),Object.defineProperty(t,"parse",{enumerable:!0,get:function(){return d.parse}}),Object.defineProperty(t,"parseSync",{enumerable:!0,get:function(){return d.parseSync}}),Object.defineProperty(t,"parseAsync",{enumerable:!0,get:function(){return d.parseAsync}}),t.types=t.OptionManager=t.DEFAULT_EXTENSIONS=void 0;var r=m(n(78)),i=m(n(360)),o=n(40),a=n(361),s=n(137);function u(){const e=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=y();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(n(0));return u=function(){return e},e}Object.defineProperty(t,"types",{enumerable:!0,get:function(){return u()}});var c=n(41),l=n(25),f=n(368),p=n(410),h=n(411),d=n(412);function y(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return y=function(){return e},e}function m(e){return e&&e.__esModule?e:{default:e}}const v=Object.freeze([".js",".jsx",".es6",".es",".mjs"]);t.DEFAULT_EXTENSIONS=v;t.OptionManager=class{init(e){return(0,l.loadOptions)(e)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){const n=Object.keys(t);for(const r of n)if(e[r]!==t[r])return!1;return!0}},function(e,t,n){var r=n(26),i=n(171),o=n(172),a=n(173),s=n(174),u=n(175);function c(e){var t=this.__data__=new r(e);this.size=t.size}c.prototype.clear=i,c.prototype.delete=o,c.prototype.get=a,c.prototype.has=s,c.prototype.set=u,e.exports=c},function(e,t,n){var r=n(13)(n(5),"Map");e.exports=r},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){var r=n(182),i=n(189),o=n(191),a=n(192),s=n(193);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t-1&&e%1==0&&e-1&&e%1==0&&e<=9007199254740991}},function(e,t){var n=Object.prototype;e.exports=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||n)}},function(e,t,n){var r=n(91),i=n(203),o=n(18);e.exports=function(e){return o(e)?r(e,!0):i(e)}},function(e,t,n){var r=n(208),i=n(94),o=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,s=a?function(e){return null==e?[]:(e=Object(e),r(a(e),(function(t){return o.call(e,t)})))}:i;e.exports=s},function(e,t){e.exports=function(e,t){for(var n=-1,r=t.length,i=e.length;++n{"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(280)(t);const{formatters:i}=e.exports;i.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(9))},function(e,t,n){var r=n(110),i=n(18),o=n(282),a=n(69),s=n(285),u=Math.max;e.exports=function(e,t,n,c){e=i(e)?e:s(e),n=n&&!c?a(n):0;var l=e.length;return n<0&&(n=u(l+n,0)),o(e)?n<=l&&e.indexOf(t,n)>-1:!!l&&r(e,t,n)>-1}},function(e,t,n){var r=n(283);e.exports=function(e){var t=r(e),n=t%1;return t==t?n?t-n:t:0}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,i=Array(r);++nn.comments)):n.shouldPrintComment=n.shouldPrintComment||(e=>n.comments||e.indexOf("@license")>=0||e.indexOf("@preserve")>=0);"auto"===n.compact&&(n.compact=e.length>5e5,n.compact&&console.error("[BABEL] Note: The code generator has deoptimised the styling of "+`${t.filename} as it exceeds the max of 500KB.`));n.compact&&(n.indent.adjustMultilineComment=!1);return n}(n,t),t.sourceMaps?new r.default(t,n):null),this.ast=e}generate(){return super.generate(this.ast)}}t.CodeGenerator=class{constructor(e,t,n){this._generator=new a(e,t,n)}generate(){return this._generator.generate()}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.merge=function(e,t){const{placeholderWhitelist:n=e.placeholderWhitelist,placeholderPattern:r=e.placeholderPattern,preserveComments:i=e.preserveComments,syntacticPlaceholders:o=e.syntacticPlaceholders}=t;return{parser:Object.assign({},e.parser,{},t.parser),placeholderWhitelist:n,placeholderPattern:r,preserveComments:i,syntacticPlaceholders:o}},t.validate=function(e){if(null!=e&&"object"!=typeof e)throw new Error("Unknown template options.");const t=e||{},{placeholderWhitelist:n,placeholderPattern:r,preserveComments:i,syntacticPlaceholders:o}=t,a=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}(t,["placeholderWhitelist","placeholderPattern","preserveComments","syntacticPlaceholders"]);if(null!=n&&!(n instanceof Set))throw new Error("'.placeholderWhitelist' must be a Set, null, or undefined");if(null!=r&&!(r instanceof RegExp)&&!1!==r)throw new Error("'.placeholderPattern' must be a RegExp, false, null, or undefined");if(null!=i&&"boolean"!=typeof i)throw new Error("'.preserveComments' must be a boolean, null, or undefined");if(null!=o&&"boolean"!=typeof o)throw new Error("'.syntacticPlaceholders' must be a boolean, null, or undefined");if(!0===o&&(null!=n||null!=r))throw new Error("'.placeholderWhitelist' and '.placeholderPattern' aren't compatible with '.syntacticPlaceholders: true'");return{parser:a,placeholderWhitelist:n||void 0,placeholderPattern:null==r?void 0:r,preserveComments:null!=i&&i,syntacticPlaceholders:null==o?void 0:o}},t.normalizeReplacements=function(e){if(Array.isArray(e))return e.reduce((e,t,n)=>(e["$"+n]=t,e),{});if("object"==typeof e||null==e)return e||void 0;throw new Error("Template replacements must be an array, object, null, or undefined")}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{constructor(e,t,n){this.key=e.name||n,this.manipulateOptions=e.manipulateOptions,this.post=e.post,this.pre=e.pre,this.visitor=e.visitor||{},this.parserOverride=e.parserOverride,this.generatorOverride=e.generatorOverride,this.options=t}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validate=function(e,t){return l({type:"root",source:e},t)};o(n(75));var r=o(n(363)),i=n(141);function o(e){return e&&e.__esModule?e:{default:e}}const a={cwd:i.assertString,root:i.assertString,rootMode:i.assertRootMode,configFile:i.assertConfigFileSearch,caller:i.assertCallerMetadata,filename:i.assertString,filenameRelative:i.assertString,code:i.assertBoolean,ast:i.assertBoolean,envName:i.assertString},s={babelrc:i.assertBoolean,babelrcRoots:i.assertBabelrcSearch},u={extends:i.assertString,ignore:i.assertIgnoreList,only:i.assertIgnoreList},c={inputSourceMap:i.assertInputSourceMap,presets:i.assertPluginList,plugins:i.assertPluginList,passPerPreset:i.assertBoolean,env:function(e,t){if("env"===e.parent.type)throw new Error(`${(0,i.msg)(e)} is not allowed inside of another .env block`);const n=e.parent,r=(0,i.assertObject)(e,t);if(r)for(const t of Object.keys(r)){const o=(0,i.assertObject)((0,i.access)(e,t),r[t]);o&&l({type:"env",name:t,parent:n},o)}return r},overrides:function(e,t){if("env"===e.parent.type)throw new Error(`${(0,i.msg)(e)} is not allowed inside an .env block`);if("overrides"===e.parent.type)throw new Error(`${(0,i.msg)(e)} is not allowed inside an .overrides block`);const n=e.parent,r=(0,i.assertArray)(e,t);if(r)for(const[t,o]of r.entries()){const r=(0,i.access)(e,t),a=(0,i.assertObject)(r,o);if(!a)throw new Error(`${(0,i.msg)(r)} must be an object`);l({type:"overrides",index:t,parent:n},a)}return r},test:i.assertConfigApplicableTest,include:i.assertConfigApplicableTest,exclude:i.assertConfigApplicableTest,retainLines:i.assertBoolean,comments:i.assertBoolean,shouldPrintComment:i.assertFunction,compact:i.assertCompact,minified:i.assertBoolean,auxiliaryCommentBefore:i.assertString,auxiliaryCommentAfter:i.assertString,sourceType:i.assertSourceType,wrapPluginVisitorMethod:i.assertFunction,highlightCode:i.assertBoolean,sourceMaps:i.assertSourceMaps,sourceMap:i.assertSourceMaps,sourceFileName:i.assertString,sourceRoot:i.assertString,getModuleId:i.assertFunction,moduleRoot:i.assertString,moduleIds:i.assertBoolean,moduleId:i.assertString,parserOpts:i.assertObject,generatorOpts:i.assertObject};function l(e,t){const n=function e(t){return"root"===t.type?t.source:e(t.parent)}(e);return function(e){if(p(e,"sourceMap")&&p(e,"sourceMaps"))throw new Error(".sourceMap is an alias for .sourceMaps, cannot use both")}(t),Object.keys(t).forEach(r=>{const o={type:"option",name:r,parent:e};if("preset"===n&&u[r])throw new Error(`${(0,i.msg)(o)} is not allowed in preset options`);if("arguments"!==n&&a[r])throw new Error(`${(0,i.msg)(o)} is only allowed in root programmatic options`);if("arguments"!==n&&"configfile"!==n&&s[r]){if("babelrcfile"===n||"extendsfile"===n)throw new Error(`${(0,i.msg)(o)} is not allowed in .babelrc or "extends"ed files, only in root programmatic options, `+"or babel.config.js/config file options");throw new Error(`${(0,i.msg)(o)} is only allowed in root programmatic options, or babel.config.js/config file options`)}(c[r]||u[r]||s[r]||a[r]||f)(o,t[r])}),t}function f(e){const t=e.name;if(r.default[t]){const{message:n,version:o=5}=r.default[t];throw new ReferenceError(`Using removed Babel ${o} option: ${(0,i.msg)(e)} - ${n}`)}{const t=`Unknown option: ${(0,i.msg)(e)}. Check out https://babeljs.io/docs/en/babel-core/#options for more information about options.`;throw new ReferenceError(t)}}function p(e,t){return Object.prototype.hasOwnProperty.call(e,t)}},function(e,t,n){var r=n(4),i=n(23),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;e.exports=function(e,t){if(r(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!i(e))||(a.test(e)||!o.test(e)||null!=t&&e in Object(t))}},function(e,t,n){"use strict";function r(){const e=c(n(79));return r=function(){return e},e}function i(){const e=c(n(7));return i=function(){return e},e}function o(){const e=n(37);return o=function(){return e},e}function a(){const e=c(n(0));return a=function(){return e},e}function s(){const e=(t=n(136))&&t.__esModule?t:{default:t};var t;return s=function(){return e},e}function u(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return u=function(){return e},e}function c(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=u();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}return n.default=e,t&&t.set(e,n),n}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;const l={enter(e,t){const n=e.node.loc;n&&(t.loc=n,e.stop())}};t.default=class{constructor(e,{code:t,ast:n,inputMap:r}){this._map=new Map,this.declarations={},this.path=null,this.ast={},this.metadata={},this.code="",this.inputMap=null,this.hub={file:this,getCode:()=>this.code,getScope:()=>this.scope,addHelper:this.addHelper.bind(this),buildError:this.buildCodeFrameError.bind(this)},this.opts=e,this.code=t,this.ast=n,this.inputMap=r,this.path=i().NodePath.get({hub:this.hub,parentPath:null,parent:this.ast,container:this.ast,key:"program"}).setContext(),this.scope=this.path.scope}get shebang(){const{interpreter:e}=this.path.node;return e?e.value:""}set shebang(e){e?this.path.get("interpreter").replaceWith(a().interpreterDirective(e)):this.path.get("interpreter").remove()}set(e,t){if("helpersNamespace"===e)throw new Error("Babel 7.0.0-beta.56 has dropped support for the 'helpersNamespace' utility.If you are using @babel/plugin-external-helpers you will need to use a newer version than the one you currently have installed. If you have your own implementation, you'll want to explore using 'helperGenerator' alongside 'file.availableHelper()'.");this._map.set(e,t)}get(e){return this._map.get(e)}has(e){return this._map.has(e)}getModuleName(){const{filename:e,filenameRelative:t=e,moduleId:n,moduleIds:r=!!n,getModuleId:i,sourceRoot:o,moduleRoot:a=o,sourceRoot:s=a}=this.opts;if(!r)return null;if(null!=n&&!i)return n;let u=null!=a?a+"/":"";if(t){const e=null!=s?new RegExp("^"+s+"/?"):"";u+=t.replace(e,"").replace(/\.(\w*?)$/,"")}return u=u.replace(/\\/g,"/"),i&&i(u)||u}addImport(){throw new Error("This API has been removed. If you're looking for this functionality in Babel 7, you should import the '@babel/helper-module-imports' module and use the functions exposed from that module, such as 'addNamed' or 'addDefault'.")}availableHelper(e,t){let n;try{n=r().minVersion(e)}catch(e){if("BABEL_HELPER_UNKNOWN"!==e.code)throw e;return!1}return"string"!=typeof t||(s().default.valid(t)&&(t=`^${t}`),!s().default.intersects(`<${n}`,t)&&!s().default.intersects(">=8.0.0",t))}addHelper(e){const t=this.declarations[e];if(t)return a().cloneNode(t);const n=this.get("helperGenerator");if(n){const t=n(e);if(t)return t}r().ensure(e);const i=this.declarations[e]=this.scope.generateUidIdentifier(e),o={};for(const t of r().getDependencies(e))o[t]=this.addHelper(t);const{nodes:s,globals:u}=r().get(e,e=>o[e],i,Object.keys(this.scope.getAllBindings()));return u.forEach(e=>{this.path.scope.hasBinding(e,!0)&&this.path.scope.rename(e)}),s.forEach(e=>{e._compact=!0}),this.path.unshiftContainer("body",s),this.path.get("body").forEach(e=>{-1!==s.indexOf(e.node)&&e.isVariableDeclaration()&&this.scope.registerDeclaration(e)}),i}addTemplateObject(){throw new Error("This function has been moved into the template literal transform itself.")}buildCodeFrameError(e,t,n=SyntaxError){let r=e&&(e.loc||e._loc);if(!r&&e){const n={loc:null};(0,i().default)(e,l,this.scope,n),r=n.loc;let o="This is an error on an internal node. Probably an internal error.";r&&(o+=" Location has been estimated."),t+=` (${o})`}if(r){const{highlightCode:e=!0}=this.opts;t+="\n"+(0,o().codeFrameColumns)(this.code,{start:{line:r.start.line,column:r.start.column+1},end:r.end&&r.start.line===r.end.line?{line:r.end.line,column:r.end.column+1}:void 0},{highlightCode:e})}return new n(t)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.get=f,t.minVersion=function(e){return l(e).minVersion()},t.getDependencies=function(e){return Array.from(l(e).dependencies.values())},t.ensure=function(e){l(e)},t.default=t.list=void 0;var r=s(n(7)),i=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=a();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(n(0)),o=s(n(359));function a(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return a=function(){return e},e}function s(e){return e&&e.__esModule?e:{default:e}}function u(e){const t=[];for(;e.parentPath;e=e.parentPath)t.push(e.key),e.inList&&t.push(e.listKey);return t.reverse().join(".")}const c=Object.create(null);function l(e){if(!c[e]){const t=o.default[e];if(!t)throw Object.assign(new ReferenceError(`Unknown helper ${e}`),{code:"BABEL_HELPER_UNKNOWN",helper:e});const n=()=>i.file(t.ast()),a=function(e){const t=new Set,n=new Set,i=new Map;let a,s;const c=[],l=[],f=[];if((0,r.default)(e,{ImportDeclaration(e){const t=e.node.source.value;if(!o.default[t])throw e.buildCodeFrameError(`Unknown helper ${t}`);if(1!==e.get("specifiers").length||!e.get("specifiers.0").isImportDefaultSpecifier())throw e.buildCodeFrameError("Helpers can only import a default value");const n=e.node.specifiers[0].local;i.set(n,t),l.push(u(e))},ExportDefaultDeclaration(e){const t=e.get("declaration");if(t.isFunctionDeclaration()){if(!t.node.id)throw t.buildCodeFrameError("Helpers should give names to their exported func declaration");a=t.node.id.name}s=u(e)},ExportAllDeclaration(e){throw e.buildCodeFrameError("Helpers can only export default")},ExportNamedDeclaration(e){throw e.buildCodeFrameError("Helpers can only export default")},Statement(e){e.isModuleDeclaration()||e.skip()}}),(0,r.default)(e,{Program(e){const t=e.scope.getAllBindings();Object.keys(t).forEach(e=>{e!==a&&(i.has(t[e].identifier)||n.add(e))})},ReferencedIdentifier(e){const n=e.node.name,r=e.scope.getBinding(n,!0);r?i.has(r.identifier)&&f.push(u(e)):t.add(n)},AssignmentExpression(e){const t=e.get("left");if(!(a in t.getBindingIdentifiers()))return;if(!t.isIdentifier())throw t.buildCodeFrameError("Only simple assignments to exports are allowed in helpers");const n=e.scope.getBinding(a);n&&n.scope.path.isProgram()&&c.push(u(e))}}),!s)throw new Error("Helpers must default-export something.");return c.reverse(),{globals:Array.from(t),localBindingNames:Array.from(n),dependencies:i,exportBindingAssignments:c,exportPath:s,exportName:a,importBindingsReferences:f,importPaths:l}}(n());c[e]={build(e,t,o){const s=n();return function(e,t,n,o,a){if(o&&!n)throw new Error("Unexpected local bindings for module-based helpers.");if(!n)return;const{localBindingNames:s,dependencies:u,exportBindingAssignments:c,exportPath:l,exportName:f,importBindingsReferences:p,importPaths:h}=t,d={};u.forEach((e,t)=>{d[t.name]="function"==typeof a&&a(e)||t});const y={},m=new Set(o||[]);s.forEach(e=>{let t=e;for(;m.has(t);)t="_"+t;t!==e&&(y[e]=t)}),"Identifier"===n.type&&f!==n.name&&(y[f]=n.name),(0,r.default)(e,{Program(e){const t=e.get(l),r=h.map(t=>e.get(t)),o=p.map(t=>e.get(t)),a=t.get("declaration");if("Identifier"===n.type)a.isFunctionDeclaration()?t.replaceWith(a):t.replaceWith(i.variableDeclaration("var",[i.variableDeclarator(n,a.node)]));else{if("MemberExpression"!==n.type)throw new Error("Unexpected helper format.");a.isFunctionDeclaration()?(c.forEach(t=>{const r=e.get(t);r.replaceWith(i.assignmentExpression("=",n,r.node))}),t.replaceWith(a),e.pushContainer("body",i.expressionStatement(i.assignmentExpression("=",n,i.identifier(f))))):t.replaceWith(i.expressionStatement(i.assignmentExpression("=",n,a.node)))}Object.keys(y).forEach(t=>{e.scope.rename(t,y[t])});for(const e of r)e.remove();for(const e of o){const t=i.cloneNode(d[e.node.name]);e.replaceWith(t)}e.stop()}})}(s,a,t,o,e),{nodes:s.program.body,globals:a.globals}},minVersion:()=>t.minVersion,dependencies:a.dependencies}}return c[e]}function f(e,t,n,r){return l(e).build(t,n,r)}const p=Object.keys(o.default).map(e=>e.replace(/^_/,"")).filter(e=>"__esModule"!==e);t.list=p;var h=f;t.default=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ForAwaitStatement=t.NumericLiteralTypeAnnotation=t.ExistentialTypeParam=t.SpreadProperty=t.RestProperty=t.Flow=t.Pure=t.Generated=t.User=t.Var=t.BlockScoped=t.Referenced=t.Scope=t.Expression=t.Statement=t.BindingIdentifier=t.ReferencedMemberExpression=t.ReferencedIdentifier=void 0;var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=r?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(0));function i(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}const o={types:["Identifier","JSXIdentifier"],checkPath(e,t){const{node:n,parent:i}=e;if(!r.isIdentifier(n,t)&&!r.isJSXMemberExpression(i,t)){if(!r.isJSXIdentifier(n,t))return!1;if(r.react.isCompatTag(n.name))return!1}return r.isReferenced(n,i,e.parentPath.parent)}};t.ReferencedIdentifier=o;const a={types:["MemberExpression"],checkPath:({node:e,parent:t})=>r.isMemberExpression(e)&&r.isReferenced(e,t)};t.ReferencedMemberExpression=a;const s={types:["Identifier"],checkPath(e){const{node:t,parent:n}=e,i=e.parentPath.parent;return r.isIdentifier(t)&&r.isBinding(t,n,i)}};t.BindingIdentifier=s;const u={types:["Statement"],checkPath({node:e,parent:t}){if(r.isStatement(e)){if(r.isVariableDeclaration(e)){if(r.isForXStatement(t,{left:e}))return!1;if(r.isForStatement(t,{init:e}))return!1}return!0}return!1}};t.Statement=u;const c={types:["Expression"],checkPath:e=>e.isIdentifier()?e.isReferencedIdentifier():r.isExpression(e.node)};t.Expression=c;const l={types:["Scopable"],checkPath:e=>r.isScope(e.node,e.parent)};t.Scope=l;const f={checkPath:e=>r.isReferenced(e.node,e.parent)};t.Referenced=f;const p={checkPath:e=>r.isBlockScoped(e.node)};t.BlockScoped=p;const h={types:["VariableDeclaration"],checkPath:e=>r.isVar(e.node)};t.Var=h;const d={checkPath:e=>e.node&&!!e.node.loc};t.User=d;const y={checkPath:e=>!e.isUser()};t.Generated=y;const m={checkPath:(e,t)=>e.scope.isPure(e.node,t)};t.Pure=m;const v={types:["Flow","ImportDeclaration","ExportDeclaration","ImportSpecifier"],checkPath:({node:e})=>!!r.isFlow(e)||(r.isImportDeclaration(e)?"type"===e.importKind||"typeof"===e.importKind:r.isExportDeclaration(e)?"type"===e.exportKind:!!r.isImportSpecifier(e)&&("type"===e.importKind||"typeof"===e.importKind))};t.Flow=v;const b={types:["RestElement"],checkPath:e=>e.parentPath&&e.parentPath.isObjectPattern()};t.RestProperty=b;const g={types:["RestElement"],checkPath:e=>e.parentPath&&e.parentPath.isObjectExpression()};t.SpreadProperty=g;t.ExistentialTypeParam={types:["ExistsTypeAnnotation"]};t.NumericLiteralTypeAnnotation={types:["NumberLiteralTypeAnnotation"]};const w={types:["ForOfStatement"],checkPath:({node:e})=>!0===e.await};t.ForAwaitStatement=w},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){const n=e.split(".");return e=>(0,i.default)(e,n,t)};var r,i=(r=n(82))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n){if(!(0,r.isMemberExpression)(e))return!1;const i=Array.isArray(t)?t:t.split("."),o=[];let a;for(a=e;(0,r.isMemberExpression)(a);a=a.object)o.push(a.property);if(o.push(a),o.lengthi.length)return!1;for(let e=0,t=o.length-1;e=97&&a<=122||a>=65&&a<=90||36===a||95===a;for(o=new Array(128),a=0;a<128;++a)o[a]=a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57||36===a||95===a;e.exports={isDecimalDigit:function(e){return 48<=e&&e<=57},isHexDigit:function(e){return 48<=e&&e<=57||97<=e&&e<=102||65<=e&&e<=70},isOctalDigit:function(e){return e>=48&&e<=55},isWhiteSpace:function(e){return 32===e||9===e||11===e||12===e||160===e||e>=5760&&r.indexOf(e)>=0},isLineTerminator:function(e){return 10===e||13===e||8232===e||8233===e},isIdentifierStartES5:function(e){return e<128?i[e]:n.NonAsciiIdentifierStart.test(s(e))},isIdentifierPartES5:function(e){return e<128?o[e]:n.NonAsciiIdentifierPart.test(s(e))},isIdentifierStartES6:function(e){return e<128?i[e]:t.NonAsciiIdentifierStart.test(s(e))},isIdentifierPartES6:function(e){return e<128?o[e]:t.NonAsciiIdentifierPart.test(s(e))}}}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if(e===t)return!0;const n=r.PLACEHOLDERS_ALIAS[e];if(n)for(const e of n)if(t===e)return!0;return!1};var r=n(2)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PLACEHOLDERS_FLIPPED_ALIAS=t.PLACEHOLDERS_ALIAS=t.PLACEHOLDERS=void 0;var r=n(8);const i=["Identifier","StringLiteral","Expression","Statement","Declaration","BlockStatement","ClassBody","Pattern"];t.PLACEHOLDERS=i;const o={Declaration:["Statement"],Pattern:["PatternLike","LVal"]};t.PLACEHOLDERS_ALIAS=o;for(const e of i){const t=r.ALIAS_KEYS[e];t&&t.length&&(o[e]=t)}const a={};t.PLACEHOLDERS_FLIPPED_ALIAS=a,Object.keys(o).forEach(e=>{o[e].forEach(t=>{Object.hasOwnProperty.call(a,t)||(a[t]=[]),a[t].push(e)})})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return!(!e||!r.VISITOR_KEYS[e.type])};var r=n(2)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t){const n={},i={},o=[],a=[];for(let s=0;s=0)){if((0,r.isAnyTypeAnnotation)(u))return[u];if((0,r.isFlowBaseAnnotation)(u))i[u.type]=u;else if((0,r.isUnionTypeAnnotation)(u))o.indexOf(u.types)<0&&(t=t.concat(u.types),o.push(u.types));else if((0,r.isGenericTypeAnnotation)(u)){const t=u.id.name;if(n[t]){let r=n[t];r.typeParameters?u.typeParameters&&(r.typeParameters.params=e(r.typeParameters.params.concat(u.typeParameters.params))):r=u.typeParameters}else n[t]=u}else a.push(u)}}for(const e of Object.keys(i))a.push(i[e]);for(const e of Object.keys(n))a.push(n[e]);return a};var r=n(1)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return(0,i.default)(e,!1)};var r,i=(r=n(22))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n){if(!n||!e)return e;const r=`${t}Comments`;e[r]?e[r]="leading"===t?n.concat(e[r]):e[r].concat(n):e[r]=n;return e}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){(0,i.default)("innerComments",e,t)};var r,i=(r=n(65))&&r.__esModule?r:{default:r}},function(e,t,n){var r=n(49),i=n(243),o=n(244);function a(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new r;++te.isScope());return e&&e.scope}get parentBlock(){return this.path.parent}get hub(){return this.path.hub}traverse(e,t,n){(0,a.default)(e,t,this,n,this.path)}generateDeclaredUidIdentifier(e){const t=this.generateUidIdentifier(e);return this.push({id:t}),l.cloneNode(t)}generateUidIdentifier(e){return l.identifier(this.generateUid(e))}generateUid(e="temp"){let t;e=l.toIdentifier(e).replace(/^_+/,"").replace(/[0-9]+$/g,"");let n=0;do{t=this._generateUid(e,n),n++}while(this.hasLabel(t)||this.hasBinding(t)||this.hasGlobal(t)||this.hasReference(t));const r=this.getProgramParent();return r.references[t]=!0,r.uids[t]=!0,t}_generateUid(e,t){let n=e;return t>1&&(n+=t),`_${n}`}generateUidBasedOnNode(e,t){let n=e;l.isAssignmentExpression(e)?n=e.left:l.isVariableDeclarator(e)?n=e.id:(l.isObjectProperty(n)||l.isObjectMethod(n))&&(n=n.key);const r=[];!function e(t,n){if(l.isModuleDeclaration(t))if(t.source)e(t.source,n);else if(t.specifiers&&t.specifiers.length)for(const r of t.specifiers)e(r,n);else t.declaration&&e(t.declaration,n);else if(l.isModuleSpecifier(t))e(t.local,n);else if(l.isMemberExpression(t))e(t.object,n),e(t.property,n);else if(l.isIdentifier(t))n.push(t.name);else if(l.isLiteral(t))n.push(t.value);else if(l.isCallExpression(t))e(t.callee,n);else if(l.isObjectExpression(t)||l.isObjectPattern(t))for(const r of t.properties)e(r.key||r.argument,n);else l.isPrivateName(t)?e(t.id,n):l.isThisExpression(t)?n.push("this"):l.isSuper(t)&&n.push("super")}(n,r);let i=r.join("$");return i=i.replace(/^_/,"")||t||"ref",this.generateUid(i.slice(0,20))}generateUidIdentifierBasedOnNode(e,t){return l.identifier(this.generateUidBasedOnNode(e,t))}isStatic(e){if(l.isThisExpression(e)||l.isSuper(e))return!0;if(l.isIdentifier(e)){const t=this.getBinding(e.name);return t?t.constant:this.hasBinding(e.name)}return!1}maybeGenerateMemoised(e,t){if(this.isStatic(e))return null;{const n=this.generateUidIdentifierBasedOnNode(e);return t?n:(this.push({id:n}),l.cloneNode(n))}}checkBlockScopedCollisions(e,t,n,r){if("param"===t)return;if("local"===e.kind)return;if("let"===t||"let"===e.kind||"const"===e.kind||"module"===e.kind||"param"===e.kind&&("let"===t||"const"===t))throw this.hub.buildError(r,`Duplicate declaration "${n}"`,TypeError)}rename(e,t,n){const r=this.getBinding(e);if(r)return t=t||this.generateUidIdentifier(e).name,new o.default(r,e,t).rename(n)}_renameFromMap(e,t,n,r){e[t]&&(e[n]=r,e[t]=null)}dump(){const e=(0,i.default)("-",60);console.log(e);let t=this;do{console.log("#",t.block.type);for(const e of Object.keys(t.bindings)){const n=t.bindings[e];console.log(" -",e,{constant:n.constant,references:n.references,violations:n.constantViolations.length,kind:n.kind})}}while(t=t.parent);console.log(e)}toArray(e,t){if(l.isIdentifier(e)){const t=this.getBinding(e.name);if(t&&t.constant&&t.path.isGenericType("Array"))return e}if(l.isArrayExpression(e))return e;if(l.isIdentifier(e,{name:"arguments"}))return l.callExpression(l.memberExpression(l.memberExpression(l.memberExpression(l.identifier("Array"),l.identifier("prototype")),l.identifier("slice")),l.identifier("call")),[e]);let n;const r=[e];return!0===t?n="toConsumableArray":t?(r.push(l.numericLiteral(t)),n="slicedToArray"):n="toArray",l.callExpression(this.hub.addHelper(n),r)}hasLabel(e){return!!this.getLabel(e)}getLabel(e){return this.labels.get(e)}registerLabel(e){this.labels.set(e.node.label.name,e)}registerDeclaration(e){if(e.isLabeledStatement())this.registerLabel(e);else if(e.isFunctionDeclaration())this.registerBinding("hoisted",e.get("id"),e);else if(e.isVariableDeclaration()){const t=e.get("declarations");for(const n of t)this.registerBinding(e.node.kind,n)}else if(e.isClassDeclaration())this.registerBinding("let",e);else if(e.isImportDeclaration()){const t=e.get("specifiers");for(const e of t)this.registerBinding("module",e)}else if(e.isExportDeclaration()){const t=e.get("declaration");(t.isClassDeclaration()||t.isFunctionDeclaration()||t.isVariableDeclaration())&&this.registerDeclaration(t)}else this.registerBinding("unknown",e)}buildUndefinedNode(){return l.unaryExpression("void",l.numericLiteral(0),!0)}registerConstantViolation(e){const t=e.getBindingIdentifiers();for(const n of Object.keys(t)){const t=this.getBinding(n);t&&t.reassign(e)}}registerBinding(e,t,n=t){if(!e)throw new ReferenceError("no `kind`");if(t.isVariableDeclaration()){const n=t.get("declarations");for(const t of n)this.registerBinding(e,t);return}const r=this.getProgramParent(),i=t.getOuterBindingIdentifiers(!0);for(const t of Object.keys(i))for(const o of i[t]){const i=this.getOwnBinding(t);if(i){if(i.identifier===o)continue;this.checkBlockScopedCollisions(i,e,t,o)}r.references[t]=!0,i?this.registerConstantViolation(n):this.bindings[t]=new u.default({identifier:o,scope:this,path:n,kind:e})}}addGlobal(e){this.globals[e.name]=e}hasUid(e){let t=this;do{if(t.uids[e])return!0}while(t=t.parent);return!1}hasGlobal(e){let t=this;do{if(t.globals[e])return!0}while(t=t.parent);return!1}hasReference(e){let t=this;do{if(t.references[e])return!0}while(t=t.parent);return!1}isPure(e,t){if(l.isIdentifier(e)){const n=this.getBinding(e.name);return!!n&&(!t||n.constant)}if(l.isClass(e))return!(e.superClass&&!this.isPure(e.superClass,t))&&this.isPure(e.body,t);if(l.isClassBody(e)){for(const n of e.body)if(!this.isPure(n,t))return!1;return!0}if(l.isBinary(e))return this.isPure(e.left,t)&&this.isPure(e.right,t);if(l.isArrayExpression(e)){for(const n of e.elements)if(!this.isPure(n,t))return!1;return!0}if(l.isObjectExpression(e)){for(const n of e.properties)if(!this.isPure(n,t))return!1;return!0}if(l.isClassMethod(e))return!(e.computed&&!this.isPure(e.key,t))&&("get"!==e.kind&&"set"!==e.kind);if(l.isProperty(e))return!(e.computed&&!this.isPure(e.key,t))&&this.isPure(e.value,t);if(l.isUnaryExpression(e))return this.isPure(e.argument,t);if(l.isTaggedTemplateExpression(e))return l.matchesPattern(e.tag,"String.raw")&&!this.hasBinding("String",!0)&&this.isPure(e.quasi,t);if(l.isTemplateLiteral(e)){for(const n of e.expressions)if(!this.isPure(n,t))return!1;return!0}return l.isPureish(e)}setData(e,t){return this.data[e]=t}getData(e){let t=this;do{const n=t.data[e];if(null!=n)return n}while(t=t.parent)}removeData(e){let t=this;do{null!=t.data[e]&&(t.data[e]=null)}while(t=t.parent)}init(){this.references||this.crawl()}crawl(){const e=this.path;if(this.references=Object.create(null),this.bindings=Object.create(null),this.globals=Object.create(null),this.uids=Object.create(null),this.data=Object.create(null),e.isLoop())for(const t of l.FOR_INIT_KEYS){const n=e.get(t);n.isBlockScoped()&&this.registerBinding(n.node.kind,n)}if(e.isFunctionExpression()&&e.has("id")&&(e.get("id").node[l.NOT_LOCAL_BINDING]||this.registerBinding("local",e.get("id"),e)),e.isClassExpression()&&e.has("id")&&(e.get("id").node[l.NOT_LOCAL_BINDING]||this.registerBinding("local",e)),e.isFunction()){const t=e.get("params");for(const e of t)this.registerBinding("param",e)}if(e.isCatchClause()&&this.registerBinding("let",e),this.getProgramParent().crawling)return;const t={references:[],constantViolations:[],assignments:[]};this.crawling=!0,e.traverse(d,t),this.crawling=!1;for(const e of t.assignments){const t=e.getBindingIdentifiers();let n;for(const r of Object.keys(t))e.scope.getBinding(r)||(n=n||e.scope.getProgramParent(),n.addGlobal(t[r]));e.scope.registerConstantViolation(e)}for(const e of t.references){const t=e.scope.getBinding(e.node.name);t?t.reference(e):e.scope.getProgramParent().addGlobal(e.node)}for(const e of t.constantViolations)e.scope.registerConstantViolation(e)}push(e){let t=this.path;t.isBlockStatement()||t.isProgram()||(t=this.getBlockParent().path),t.isSwitchStatement()&&(t=(this.getFunctionParent()||this.getProgramParent()).path),(t.isLoop()||t.isCatchClause()||t.isFunction())&&(t.ensureBlock(),t=t.get("body"));const n=e.unique,r=e.kind||"var",i=null==e._blockHoist?2:e._blockHoist,o=`declaration:${r}:${i}`;let a=!n&&t.getData(o);if(!a){const e=l.variableDeclaration(r,[]);e._blockHoist=i,[a]=t.unshiftContainer("body",[e]),n||t.setData(o,a)}const s=l.variableDeclarator(e.id,e.init);a.node.declarations.push(s),this.registerBinding(r,a.get("declarations").pop())}getProgramParent(){let e=this;do{if(e.path.isProgram())return e}while(e=e.parent);throw new Error("Couldn't find a Program")}getFunctionParent(){let e=this;do{if(e.path.isFunctionParent())return e}while(e=e.parent);return null}getBlockParent(){let e=this;do{if(e.path.isBlockParent())return e}while(e=e.parent);throw new Error("We couldn't find a BlockStatement, For, Switch, Function, Loop or Program...")}getAllBindings(){const e=Object.create(null);let t=this;do{(0,s.default)(e,t.bindings),t=t.parent}while(t);return e}getAllBindingsOfKind(){const e=Object.create(null);for(const t of arguments){let n=this;do{for(const r of Object.keys(n.bindings)){const i=n.bindings[r];i.kind===t&&(e[r]=i)}n=n.parent}while(n)}return e}bindingIdentifierEquals(e,t){return this.getBindingIdentifier(e)===t}getBinding(e){let t=this;do{const n=t.getOwnBinding(e);if(n)return n}while(t=t.parent)}getOwnBinding(e){return this.bindings[e]}getBindingIdentifier(e){const t=this.getBinding(e);return t&&t.identifier}getOwnBindingIdentifier(e){const t=this.bindings[e];return t&&t.identifier}hasOwnBinding(e){return!!this.getOwnBinding(e)}hasBinding(e,t){return!!e&&(!!this.hasOwnBinding(e)||(!!this.parentHasBinding(e,t)||(!!this.hasUid(e)||(!(t||!(0,r.default)(m.globals,e))||!(t||!(0,r.default)(m.contextVariables,e))))))}parentHasBinding(e,t){return this.parent&&this.parent.hasBinding(e,t)}moveBindingTo(e,t){const n=this.getBinding(e);n&&(n.scope.removeOwnBinding(e),n.scope=t,t.bindings[e]=n)}removeOwnBinding(e){delete this.bindings[e]}removeBinding(e){const t=this.getBinding(e);t&&t.scope.removeOwnBinding(e);let n=this;do{n.uids[e]&&(n.uids[e]=!1)}while(n=n.parent)}}t.default=m,m.globals=Object.keys(c.default.builtin),m.contextVariables=["arguments","undefined","Infinity","NaN"]},function(e,t,n){var r=n(287),i=n(71),o=n(69),a=n(72);e.exports=function(e,t,n){return t=(n?i(e,t,n):void 0===t)?1:o(t),r(a(e),t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{constructor({identifier:e,scope:t,path:n,kind:r}){this.identifier=e,this.scope=t,this.path=n,this.kind=r,this.constantViolations=[],this.constant=!0,this.referencePaths=[],this.referenced=!1,this.references=0,this.clearValue()}deoptValue(){this.clearValue(),this.hasDeoptedValue=!0}setValue(e){this.hasDeoptedValue||(this.hasValue=!0,this.value=e)}clearValue(){this.hasDeoptedValue=!1,this.hasValue=!1,this.value=null}reassign(e){this.constant=!1,-1===this.constantViolations.indexOf(e)&&this.constantViolations.push(e)}reference(e){-1===this.referencePaths.indexOf(e)&&(this.referenced=!0,this.references++,this.referencePaths.push(e))}dereference(){this.references--,this.referenced=!!this.references}}},function(e,t,n){var r=n(35),i=n(292),o=n(294);e.exports=function(e,t){return o(i(e,t,r),e+"")}},function(e,t,n){t.SourceMapGenerator=n(126).SourceMapGenerator,t.SourceMapConsumer=n(303).SourceMapConsumer,t.SourceNode=n(306).SourceNode},function(e,t,n){var r=n(127),i=n(24),o=n(128).ArraySet,a=n(302).MappingList;function s(e){e||(e={}),this._file=i.getArg(e,"file",null),this._sourceRoot=i.getArg(e,"sourceRoot",null),this._skipValidation=i.getArg(e,"skipValidation",!1),this._sources=new o,this._names=new o,this._mappings=new a,this._sourcesContents=null}s.prototype._version=3,s.fromSourceMap=function(e){var t=e.sourceRoot,n=new s({file:e.file,sourceRoot:t});return e.eachMapping((function(e){var r={generated:{line:e.generatedLine,column:e.generatedColumn}};null!=e.source&&(r.source=e.source,null!=t&&(r.source=i.relative(t,r.source)),r.original={line:e.originalLine,column:e.originalColumn},null!=e.name&&(r.name=e.name)),n.addMapping(r)})),e.sources.forEach((function(t){var r=e.sourceContentFor(t);null!=r&&n.setSourceContent(t,r)})),n},s.prototype.addMapping=function(e){var t=i.getArg(e,"generated"),n=i.getArg(e,"original",null),r=i.getArg(e,"source",null),o=i.getArg(e,"name",null);this._skipValidation||this._validateMapping(t,n,r,o),null!=r&&(r=String(r),this._sources.has(r)||this._sources.add(r)),null!=o&&(o=String(o),this._names.has(o)||this._names.add(o)),this._mappings.add({generatedLine:t.line,generatedColumn:t.column,originalLine:null!=n&&n.line,originalColumn:null!=n&&n.column,source:r,name:o})},s.prototype.setSourceContent=function(e,t){var n=e;null!=this._sourceRoot&&(n=i.relative(this._sourceRoot,n)),null!=t?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[i.toSetString(n)]=t):this._sourcesContents&&(delete this._sourcesContents[i.toSetString(n)],0===Object.keys(this._sourcesContents).length&&(this._sourcesContents=null))},s.prototype.applySourceMap=function(e,t,n){var r=t;if(null==t){if(null==e.file)throw new Error('SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map\'s "file" property. Both were omitted.');r=e.file}var a=this._sourceRoot;null!=a&&(r=i.relative(a,r));var s=new o,u=new o;this._mappings.unsortedForEach((function(t){if(t.source===r&&null!=t.originalLine){var o=e.originalPositionFor({line:t.originalLine,column:t.originalColumn});null!=o.source&&(t.source=o.source,null!=n&&(t.source=i.join(n,t.source)),null!=a&&(t.source=i.relative(a,t.source)),t.originalLine=o.line,t.originalColumn=o.column,null!=o.name&&(t.name=o.name))}var c=t.source;null==c||s.has(c)||s.add(c);var l=t.name;null==l||u.has(l)||u.add(l)}),this),this._sources=s,this._names=u,e.sources.forEach((function(t){var r=e.sourceContentFor(t);null!=r&&(null!=n&&(t=i.join(n,t)),null!=a&&(t=i.relative(a,t)),this.setSourceContent(t,r))}),this)},s.prototype._validateMapping=function(e,t,n,r){if(t&&"number"!=typeof t.line&&"number"!=typeof t.column)throw new Error("original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.");if((!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0)||t||n||r)&&!(e&&"line"in e&&"column"in e&&t&&"line"in t&&"column"in t&&e.line>0&&e.column>=0&&t.line>0&&t.column>=0&&n))throw new Error("Invalid mapping: "+JSON.stringify({generated:e,source:n,original:t,name:r}))},s.prototype._serializeMappings=function(){for(var e,t,n,o,a=0,s=1,u=0,c=0,l=0,f=0,p="",h=this._mappings.toArray(),d=0,y=h.length;d0){if(!i.compareByGeneratedPositionsInflated(t,h[d-1]))continue;e+=","}e+=r.encode(t.generatedColumn-a),a=t.generatedColumn,null!=t.source&&(o=this._sources.indexOf(t.source),e+=r.encode(o-f),f=o,e+=r.encode(t.originalLine-1-c),c=t.originalLine-1,e+=r.encode(t.originalColumn-u),u=t.originalColumn,null!=t.name&&(n=this._names.indexOf(t.name),e+=r.encode(n-l),l=n)),p+=e}return p},s.prototype._generateSourcesContent=function(e,t){return e.map((function(e){if(!this._sourcesContents)return null;null!=t&&(e=i.relative(t,e));var n=i.toSetString(e);return Object.prototype.hasOwnProperty.call(this._sourcesContents,n)?this._sourcesContents[n]:null}),this)},s.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return null!=this._file&&(e.file=this._file),null!=this._sourceRoot&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e},s.prototype.toString=function(){return JSON.stringify(this.toJSON())},t.SourceMapGenerator=s},function(e,t,n){var r=n(301);t.encode=function(e){var t,n="",i=function(e){return e<0?1+(-e<<1):0+(e<<1)}(e);do{t=31&i,(i>>>=5)>0&&(t|=32),n+=r.encode(t)}while(i>0);return n},t.decode=function(e,t,n){var i,o,a,s,u=e.length,c=0,l=0;do{if(t>=u)throw new Error("Expected more digits in base 64 VLQ value.");if(-1===(o=r.decode(e.charCodeAt(t++))))throw new Error("Invalid base64 digit: "+e.charAt(t-1));i=!!(32&o),c+=(o&=31)<>1,1==(1&a)?-s:s),n.rest=t}},function(e,t,n){var r=n(24),i=Object.prototype.hasOwnProperty,o="undefined"!=typeof Map;function a(){this._array=[],this._set=o?new Map:Object.create(null)}a.fromArray=function(e,t){for(var n=new a,r=0,i=e.length;r=0)return t}else{var n=r.toSetString(e);if(i.call(this._set,n))return this._set[n]}throw new Error('"'+e+'" is not in the set.')},a.prototype.at=function(e){if(e>=0&&e{this.word(e.name)})},t.ArgumentPlaceholder=function(){this.token("?")},t.SpreadElement=t.RestElement=function(e){this.token("..."),this.print(e.argument,e)},t.ObjectPattern=t.ObjectExpression=function(e){const t=e.properties;this.token("{"),this.printInnerComments(e),t.length&&(this.space(),this.printList(t,e,{indent:!0,statement:!0}),this.space());this.token("}")},t.ObjectMethod=function(e){this.printJoin(e.decorators,e),this._methodHead(e),this.space(),this.print(e.body,e)},t.ObjectProperty=function(e){if(this.printJoin(e.decorators,e),e.computed)this.token("["),this.print(e.key,e),this.token("]");else{if(i.isAssignmentPattern(e.value)&&i.isIdentifier(e.key)&&e.key.name===e.value.left.name)return void this.print(e.value,e);if(this.print(e.key,e),e.shorthand&&i.isIdentifier(e.key)&&i.isIdentifier(e.value)&&e.key.name===e.value.name)return}this.token(":"),this.space(),this.print(e.value,e)},t.ArrayPattern=t.ArrayExpression=function(e){const t=e.elements,n=t.length;this.token("["),this.printInnerComments(e);for(let r=0;r0&&this.space(),this.print(i,e),r{u[t]=u[t]||[],u[t].push(e)}),S[e]=t},t.DEPRECATED_KEYS=t.BUILDER_KEYS=t.NODE_FIELDS=t.FLIPPED_ALIAS_KEYS=t.ALIAS_KEYS=t.VISITOR_KEYS=void 0;var r,i=(r=n(61))&&r.__esModule?r:{default:r},o=n(63);const a={};t.VISITOR_KEYS=a;const s={};t.ALIAS_KEYS=s;const u={};t.FLIPPED_ALIAS_KEYS=u;const c={};t.NODE_FIELDS=c;const l={};t.BUILDER_KEYS=l;const f={};function p(e){return Array.isArray(e)?"array":null===e?"null":void 0===e?"undefined":typeof e}function h(e){return{validate:e}}function d(e){return"string"==typeof e?b(e):b(...e)}function y(e){return w(g("array"),v(e))}function m(e){return y(d(e))}function v(e){function t(t,n,r){if(Array.isArray(r))for(let i=0;i1)for(var n=1;n","<",">=","<="];t.BOOLEAN_NUMBER_BINARY_OPERATORS=r;const i=["==","===","!=","!=="];t.EQUALITY_BINARY_OPERATORS=i;const o=[...i,"in","instanceof"];t.COMPARISON_BINARY_OPERATORS=o;const a=[...o,...r];t.BOOLEAN_BINARY_OPERATORS=a;const s=["-","/","%","*","**","&","|",">>",">>>","<<","^"];t.NUMBER_BINARY_OPERATORS=s;const u=["+",...s,...a];t.BINARY_OPERATORS=u;const c=["delete","!"];t.BOOLEAN_UNARY_OPERATORS=c;const l=["+","-","~"];t.NUMBER_UNARY_OPERATORS=l;const f=["typeof"];t.STRING_UNARY_OPERATORS=f;const p=["void","throw",...c,...l,...f];t.UNARY_OPERATORS=p;t.INHERIT_KEYS={optional:["typeAnnotation","typeParameters","returnType"],force:["start","loc","end"]};const h=Symbol.for("var used to be block scoped");t.BLOCK_SCOPED_SYMBOL=h;const d=Symbol.for("should not be considered a local binding");t.NOT_LOCAL_BINDING=d},function(e,t,n){(function(e){function n(e,t){for(var n=0,r=e.length-1;r>=0;r--){var i=e[r];"."===i?e.splice(r,1):".."===i?(e.splice(r,1),n++):n&&(e.splice(r,1),n--)}if(t)for(;n--;n)e.unshift("..");return e}function r(e,t){if(e.filter)return e.filter(t);for(var n=[],r=0;r=-1&&!i;o--){var a=o>=0?arguments[o]:e.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(t=a+"/"+t,i="/"===a.charAt(0))}return(i?"/":"")+(t=n(r(t.split("/"),(function(e){return!!e})),!i).join("/"))||"."},t.normalize=function(e){var o=t.isAbsolute(e),a="/"===i(e,-1);return(e=n(r(e.split("/"),(function(e){return!!e})),!o).join("/"))||o||(e="."),e&&a&&(e+="/"),(o?"/":"")+e},t.isAbsolute=function(e){return"/"===e.charAt(0)},t.join=function(){var e=Array.prototype.slice.call(arguments,0);return t.normalize(r(e,(function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e})).join("/"))},t.relative=function(e,n){function r(e){for(var t=0;t=0&&""===e[n];n--);return t>n?[]:e.slice(t,n-t+1)}e=t.resolve(e).substr(1),n=t.resolve(n).substr(1);for(var i=r(e.split("/")),o=r(n.split("/")),a=Math.min(i.length,o.length),s=a,u=0;u=1;--o)if(47===(t=e.charCodeAt(o))){if(!i){r=o;break}}else i=!1;return-1===r?n?"/":".":n&&1===r?"/":e.slice(0,r)},t.basename=function(e,t){var n=function(e){"string"!=typeof e&&(e+="");var t,n=0,r=-1,i=!0;for(t=e.length-1;t>=0;--t)if(47===e.charCodeAt(t)){if(!i){n=t+1;break}}else-1===r&&(i=!1,r=t+1);return-1===r?"":e.slice(n,r)}(e);return t&&n.substr(-1*t.length)===t&&(n=n.substr(0,n.length-t.length)),n},t.extname=function(e){"string"!=typeof e&&(e+="");for(var t=-1,n=0,r=-1,i=!0,o=0,a=e.length-1;a>=0;--a){var s=e.charCodeAt(a);if(47!==s)-1===r&&(i=!1,r=a+1),46===s?-1===t?t=a:1!==o&&(o=1):-1!==t&&(o=-1);else if(!i){n=a+1;break}}return-1===t||-1===r||0===o||1===o&&t===r-1&&t===n+1?"":e.slice(t,r)};var i="b"==="ab".substr(-1)?function(e,t,n){return e.substr(t,n)}:function(e,t,n){return t<0&&(t=e.length+t),e.substr(t,n)}}).call(this,n(9))},function(e,t,n){var r=n(5).Symbol;e.exports=r},function(e,t,n){var r=n(91),i=n(200),o=n(18);e.exports=function(e){return o(e)?r(e):i(e)}},function(e,t,n){var r=n(85),i=n(53);e.exports=function(e){return null!=e&&i(e.length)&&!r(e)}},function(e,t){e.exports=function(e,t){return e===t||e!=e&&t!=t}},function(e,t){e.exports=function(e){return function(t){return e(t)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return"string"==typeof e&&!i.default.keyword.isReservedWordES6(e,!0)&&("await"!==e&&i.default.keyword.isIdentifierNameES6(e))};var r,i=(r=n(100))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=s;var r=n(2);const i=Function.call.bind(Object.prototype.hasOwnProperty);function o(e,t){return e&&"string"==typeof e.type&&"CommentLine"!==e.type&&"CommentBlock"!==e.type?s(e,t):e}function a(e,t){return Array.isArray(e)?e.map(e=>o(e,t)):o(e,t)}function s(e,t=!0){if(!e)return e;const{type:n}=e,o={type:n};if("Identifier"===n)o.name=e.name,i(e,"optional")&&"boolean"==typeof e.optional&&(o.optional=e.optional),i(e,"typeAnnotation")&&(o.typeAnnotation=t?a(e.typeAnnotation,!0):e.typeAnnotation);else{if(!i(r.NODE_FIELDS,n))throw new Error(`Unknown node type: "${n}"`);for(const s of Object.keys(r.NODE_FIELDS[n]))i(e,s)&&(o[s]=t?a(e[s],!0):e[s])}return i(e,"loc")&&(o.loc=e.loc),i(e,"leadingComments")&&(o.leadingComments=e.leadingComments),i(e,"innerComments")&&(o.innerComments=e.innerComments),i(e,"trailingComments")&&(o.trailingComments=e.trailingComments),i(e,"extra")&&(o.extra=Object.assign({},e.extra)),o}},function(e,t,n){var r=n(11),i=n(6);e.exports=function(e){return"symbol"==typeof e||i(e)&&"[object Symbol]"==r(e)}},function(e,t){t.getArg=function(e,t,n){if(t in e)return e[t];if(3===arguments.length)return n;throw new Error('"'+t+'" is a required argument.')};var n=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.]*)(?::(\d+))?(\S*)$/,r=/^data:.+\,.+$/;function i(e){var t=e.match(n);return t?{scheme:t[1],auth:t[2],host:t[3],port:t[4],path:t[5]}:null}function o(e){var t="";return e.scheme&&(t+=e.scheme+":"),t+="//",e.auth&&(t+=e.auth+"@"),e.host&&(t+=e.host),e.port&&(t+=":"+e.port),e.path&&(t+=e.path),t}function a(e){var n=e,r=i(e);if(r){if(!r.path)return e;n=r.path}for(var a,s=t.isAbsolute(n),u=n.split(/\/+/),c=0,l=u.length-1;l>=0;l--)"."===(a=u[l])?u.splice(l,1):".."===a?c++:c>0&&(""===a?(u.splice(l+1,c),c=0):(u.splice(l,2),c--));return""===(n=u.join("/"))&&(n=s?"/":"."),r?(r.path=n,o(r)):n}t.urlParse=i,t.urlGenerate=o,t.normalize=a,t.join=function(e,t){""===e&&(e="."),""===t&&(t=".");var n=i(t),s=i(e);if(s&&(e=s.path||"/"),n&&!n.scheme)return s&&(n.scheme=s.scheme),o(n);if(n||t.match(r))return t;if(s&&!s.host&&!s.path)return s.host=t,o(s);var u="/"===t.charAt(0)?t:a(e.replace(/\/+$/,"")+"/"+t);return s?(s.path=u,o(s)):u},t.isAbsolute=function(e){return"/"===e.charAt(0)||!!e.match(n)},t.relative=function(e,t){""===e&&(e="."),e=e.replace(/\/$/,"");for(var n=0;0!==t.indexOf(e+"/");){var r=e.lastIndexOf("/");if(r<0)return t;if((e=e.slice(0,r)).match(/^([^\/]+:\/)?\/*$/))return t;++n}return Array(n+1).join("../")+t.substr(e.length+1)};var s=!("__proto__"in Object.create(null));function u(e){return e}function c(e){if(!e)return!1;var t=e.length;if(t<9)return!1;if(95!==e.charCodeAt(t-1)||95!==e.charCodeAt(t-2)||111!==e.charCodeAt(t-3)||116!==e.charCodeAt(t-4)||111!==e.charCodeAt(t-5)||114!==e.charCodeAt(t-6)||112!==e.charCodeAt(t-7)||95!==e.charCodeAt(t-8)||95!==e.charCodeAt(t-9))return!1;for(var n=t-10;n>=0;n--)if(36!==e.charCodeAt(n))return!1;return!0}function l(e,t){return e===t?0:e>t?1:-1}t.toSetString=s?u:function(e){return c(e)?"$"+e:e},t.fromSetString=s?u:function(e){return c(e)?e.slice(1):e},t.compareByOriginalPositions=function(e,t,n){var r=e.source-t.source;return 0!==r?r:0!==(r=e.originalLine-t.originalLine)?r:0!==(r=e.originalColumn-t.originalColumn)||n?r:0!==(r=e.generatedColumn-t.generatedColumn)?r:0!==(r=e.generatedLine-t.generatedLine)?r:e.name-t.name},t.compareByGeneratedPositionsDeflated=function(e,t,n){var r=e.generatedLine-t.generatedLine;return 0!==r?r:0!==(r=e.generatedColumn-t.generatedColumn)||n?r:0!==(r=e.source-t.source)?r:0!==(r=e.originalLine-t.originalLine)?r:0!==(r=e.originalColumn-t.originalColumn)?r:e.name-t.name},t.compareByGeneratedPositionsInflated=function(e,t){var n=e.generatedLine-t.generatedLine;return 0!==n?n:0!==(n=e.generatedColumn-t.generatedColumn)?n:0!==(n=l(e.source,t.source))?n:0!==(n=e.originalLine-t.originalLine)?n:0!==(n=e.originalColumn-t.originalColumn)?n:l(e.name,t.name)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.loadOptions=function(e){const t=(0,i.default)(e);return t?t.options:null},Object.defineProperty(t,"default",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"loadPartialConfig",{enumerable:!0,get:function(){return o.loadPartialConfig}});var r,i=(r=n(362))&&r.__esModule?r:{default:r},o=n(142)},function(e,t,n){var r=n(166),i=n(167),o=n(168),a=n(169),s=n(170);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++ti?e(t):t,c=e.split(o),{start:l,end:f,markerLines:p}=function(e,t,n){const r=Object.assign({column:0,line:-1},e.start),i=Object.assign({},r,e.end),{linesAbove:o=2,linesBelow:a=3}=n||{},s=r.line,u=r.column,c=i.line,l=i.column;let f=Math.max(s-(o+1),0),p=Math.min(t.length,c+a);-1===s&&(f=0),-1===c&&(p=t.length);const h=c-s,d={};if(h)for(let e=0;e<=h;e++){const n=e+s;if(u)if(0===e){const e=t[n-1].length;d[n]=[u,e-u+1]}else if(e===h)d[n]=[0,l];else{const r=t[n-e].length;d[n]=[0,r]}else d[n]=!0}else d[s]=u===l?!u||[u,0]:[u,l-u];return{start:f,end:p,markerLines:d}}(t,c,n),h=t.start&&"number"==typeof t.start.column,d=String(f).length;let y=(i?(0,r().default)(e,n):e).split(o).slice(l,f).map((e,t)=>{const r=l+1+t,i=` ${` ${r}`.slice(-d)} | `,o=p[r],a=!p[r+1];if(o){let t="";if(Array.isArray(o)){const r=e.slice(0,Math.max(o[0]-1,0)).replace(/[^\t]/g," "),c=o[1]||1;t=["\n ",u(s.gutter,i.replace(/\d/g," ")),r,u(s.marker,"^").repeat(c)].join(""),a&&n.message&&(t+=" "+u(s.message,n.message))}return[u(s.marker,">"),u(s.gutter,i),e,t].join("")}return` ${u(s.gutter,i)}${e}`}).join("\n");return n.message&&!h&&(y=`${" ".repeat(d+1)}${n.message}\n${y}`),i?a.reset(y):y}}).call(this,n(9))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});class r{constructor(e,t={}){this.label=e,this.keyword=t.keyword,this.beforeExpr=!!t.beforeExpr,this.startsExpr=!!t.startsExpr,this.rightAssociative=!!t.rightAssociative,this.isLoop=!!t.isLoop,this.isAssign=!!t.isAssign,this.prefix=!!t.prefix,this.postfix=!!t.postfix,this.binop=null!=t.binop?t.binop:null,this.updateContext=null}}const i=new Map;function o(e,t={}){t.keyword=e;const n=new r(e,t);return i.set(e,n),n}function a(e,t){return new r(e,{beforeExpr:!0,binop:t})}const s={num:new r("num",{startsExpr:!0}),bigint:new r("bigint",{startsExpr:!0}),regexp:new r("regexp",{startsExpr:!0}),string:new r("string",{startsExpr:!0}),name:new r("name",{startsExpr:!0}),eof:new r("eof"),bracketL:new r("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new r("]"),braceL:new r("{",{beforeExpr:!0,startsExpr:!0}),braceBarL:new r("{|",{beforeExpr:!0,startsExpr:!0}),braceR:new r("}"),braceBarR:new r("|}"),parenL:new r("(",{beforeExpr:!0,startsExpr:!0}),parenR:new r(")"),comma:new r(",",{beforeExpr:!0}),semi:new r(";",{beforeExpr:!0}),colon:new r(":",{beforeExpr:!0}),doubleColon:new r("::",{beforeExpr:!0}),dot:new r("."),question:new r("?",{beforeExpr:!0}),questionDot:new r("?."),arrow:new r("=>",{beforeExpr:!0}),template:new r("template"),ellipsis:new r("...",{beforeExpr:!0}),backQuote:new r("`",{startsExpr:!0}),dollarBraceL:new r("${",{beforeExpr:!0,startsExpr:!0}),at:new r("@"),hash:new r("#",{startsExpr:!0}),interpreterDirective:new r("#!..."),eq:new r("=",{beforeExpr:!0,isAssign:!0}),assign:new r("_=",{beforeExpr:!0,isAssign:!0}),incDec:new r("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),bang:new r("!",{beforeExpr:!0,prefix:!0,startsExpr:!0}),tilde:new r("~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),pipeline:a("|>",0),nullishCoalescing:a("??",1),logicalOR:a("||",2),logicalAND:a("&&",3),bitwiseOR:a("|",4),bitwiseXOR:a("^",5),bitwiseAND:a("&",6),equality:a("==/!=/===/!==",7),relational:a("/<=/>=",8),bitShift:a("<>/>>>",9),plusMin:new r("+/-",{beforeExpr:!0,binop:10,prefix:!0,startsExpr:!0}),modulo:new r("%",{beforeExpr:!0,binop:11,startsExpr:!0}),star:a("*",11),slash:a("/",11),exponent:new r("**",{beforeExpr:!0,binop:12,rightAssociative:!0}),_break:o("break"),_case:o("case",{beforeExpr:!0}),_catch:o("catch"),_continue:o("continue"),_debugger:o("debugger"),_default:o("default",{beforeExpr:!0}),_do:o("do",{isLoop:!0,beforeExpr:!0}),_else:o("else",{beforeExpr:!0}),_finally:o("finally"),_for:o("for",{isLoop:!0}),_function:o("function",{startsExpr:!0}),_if:o("if"),_return:o("return",{beforeExpr:!0}),_switch:o("switch"),_throw:o("throw",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_try:o("try"),_var:o("var"),_const:o("const"),_while:o("while",{isLoop:!0}),_with:o("with"),_new:o("new",{beforeExpr:!0,startsExpr:!0}),_this:o("this",{startsExpr:!0}),_super:o("super",{startsExpr:!0}),_class:o("class",{startsExpr:!0}),_extends:o("extends",{beforeExpr:!0}),_export:o("export"),_import:o("import",{startsExpr:!0}),_null:o("null",{startsExpr:!0}),_true:o("true",{startsExpr:!0}),_false:o("false",{startsExpr:!0}),_in:o("in",{beforeExpr:!0,binop:8}),_instanceof:o("instanceof",{beforeExpr:!0,binop:8}),_typeof:o("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:o("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:o("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})};function u(e,t){return 2|(e?4:0)|(t?8:0)}function c(e){return null!=e&&"Property"===e.type&&"init"===e.kind&&!1===e.method}const l=/\r\n?|[\n\u2028\u2029]/,f=new RegExp(l.source,"g");function p(e){switch(e){case 10:case 13:case 8232:case 8233:return!0;default:return!1}}const h=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g;function d(e){switch(e){case 9:case 11:case 12:case 32:case 160:case 5760:case 8192:case 8193:case 8194:case 8195:case 8196:case 8197:case 8198:case 8199:case 8200:case 8201:case 8202:case 8239:case 8287:case 12288:case 65279:return!0;default:return!1}}class y{constructor(e,t,n,r){this.token=e,this.isExpr=!!t,this.preserveSpace=!!n,this.override=r}}const m={braceStatement:new y("{",!1),braceExpression:new y("{",!0),templateQuasi:new y("${",!1),parenStatement:new y("(",!1),parenExpression:new y("(",!0),template:new y("`",!0,!0,e=>e.readTmplToken()),functionExpression:new y("function",!0),functionStatement:new y("function",!1)};s.parenR.updateContext=s.braceR.updateContext=function(){if(1===this.state.context.length)return void(this.state.exprAllowed=!0);let e=this.state.context.pop();e===m.braceStatement&&"function"===this.curContext().token&&(e=this.state.context.pop()),this.state.exprAllowed=!e.isExpr},s.name.updateContext=function(e){let t=!1;e!==s.dot&&("of"===this.state.value&&!this.state.exprAllowed||"yield"===this.state.value&&this.scope.inGenerator)&&(t=!0),this.state.exprAllowed=t,this.state.isIterator&&(this.state.isIterator=!1)},s.braceL.updateContext=function(e){this.state.context.push(this.braceIsBlock(e)?m.braceStatement:m.braceExpression),this.state.exprAllowed=!0},s.dollarBraceL.updateContext=function(){this.state.context.push(m.templateQuasi),this.state.exprAllowed=!0},s.parenL.updateContext=function(e){const t=e===s._if||e===s._for||e===s._with||e===s._while;this.state.context.push(t?m.parenStatement:m.parenExpression),this.state.exprAllowed=!0},s.incDec.updateContext=function(){},s._function.updateContext=s._class.updateContext=function(e){!e.beforeExpr||e===s.semi||e===s._else||e===s._return&&l.test(this.input.slice(this.state.lastTokEnd,this.state.start))||(e===s.colon||e===s.braceL)&&this.curContext()===m.b_stat?this.state.context.push(m.functionStatement):this.state.context.push(m.functionExpression),this.state.exprAllowed=!1},s.backQuote.updateContext=function(){this.curContext()===m.template?this.state.context.pop():this.state.context.push(m.template),this.state.exprAllowed=!1};const v=["eval","arguments"],b=new Set(["implements","interface","let","package","private","protected","public","static","yield"]),g=new Set(v),w=(e,t)=>t&&"await"===e||"enum"===e;function S(e,t){return w(e,t)||b.has(e)}function O(e){return g.has(e)}function P(e,t){return S(e,t)||O(e)}const k=/^in(stanceof)?$/;let x="ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࢠ-ࢴࢶ-ࢽऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೞೠೡೱೲഅ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜌᜎ-ᜑᜠ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭋᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-ᲈᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿯ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꞿꟂ-Ᶎꟷ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭧꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",E="‌‍·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛࣓-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍ୖୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ංඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-ໍ໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜔ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠐-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷹᷻-᷿‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_";const j=new RegExp("["+x+"]"),T=new RegExp("["+x+E+"]");x=E=null;const C=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,157,310,10,21,11,7,153,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,477,28,11,0,9,21,155,22,13,52,76,44,33,24,27,35,30,0,12,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,85,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,159,52,19,3,21,0,33,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,230,43,117,63,32,0,161,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,35,56,264,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,270,921,103,110,18,195,2749,1070,4050,582,8634,568,8,30,114,29,19,47,17,3,32,20,6,18,689,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,754,9486,286,50,2,18,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,2357,44,11,6,17,0,370,43,1301,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42710,42,4148,12,221,3,5761,15,7472,3104,541],_=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,525,10,176,2,54,14,32,9,16,3,46,10,54,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,4,9,83,11,7,0,161,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,193,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,84,14,5,9,243,14,166,9,232,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,406,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,19306,9,135,4,60,6,26,9,1014,0,2,54,8,3,19723,1,5319,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,262,6,10,9,419,13,1495,6,110,6,6,9,792487,239];function A(e,t){let n=65536;for(let r=0,i=t.length;re)return!1;if(n+=t[r+1],n>=e)return!0}return!1}function D(e){return e<65?36===e:e<=90||(e<97?95===e:e<=122||(e<=65535?e>=170&&j.test(String.fromCharCode(e)):A(e,C)))}function I(e){return e<48?36===e:e<58||!(e<65)&&(e<=90||(e<97?95===e:e<=122||(e<=65535?e>=170&&T.test(String.fromCharCode(e)):A(e,C)||A(e,_))))}const F=new Set(["_","any","bool","boolean","empty","extends","false","interface","mixed","null","number","static","string","true","typeof","void"]);function $(e){return"type"===e.importKind||"typeof"===e.importKind}function M(e){return(e.type===s.name||!!e.type.keyword)&&"from"!==e.value}const R={const:"declare export var",let:"declare export var",type:"export type",interface:"export interface"};const L=/\*?\s*@((?:no)?flow)\b/;const B={quot:'"',amp:"&",apos:"'",lt:"<",gt:">",nbsp:" ",iexcl:"¡",cent:"¢",pound:"£",curren:"¤",yen:"¥",brvbar:"¦",sect:"§",uml:"¨",copy:"©",ordf:"ª",laquo:"«",not:"¬",shy:"­",reg:"®",macr:"¯",deg:"°",plusmn:"±",sup2:"²",sup3:"³",acute:"´",micro:"µ",para:"¶",middot:"·",cedil:"¸",sup1:"¹",ordm:"º",raquo:"»",frac14:"¼",frac12:"½",frac34:"¾",iquest:"¿",Agrave:"À",Aacute:"Á",Acirc:"Â",Atilde:"Ã",Auml:"Ä",Aring:"Å",AElig:"Æ",Ccedil:"Ç",Egrave:"È",Eacute:"É",Ecirc:"Ê",Euml:"Ë",Igrave:"Ì",Iacute:"Í",Icirc:"Î",Iuml:"Ï",ETH:"Ð",Ntilde:"Ñ",Ograve:"Ò",Oacute:"Ó",Ocirc:"Ô",Otilde:"Õ",Ouml:"Ö",times:"×",Oslash:"Ø",Ugrave:"Ù",Uacute:"Ú",Ucirc:"Û",Uuml:"Ü",Yacute:"Ý",THORN:"Þ",szlig:"ß",agrave:"à",aacute:"á",acirc:"â",atilde:"ã",auml:"ä",aring:"å",aelig:"æ",ccedil:"ç",egrave:"è",eacute:"é",ecirc:"ê",euml:"ë",igrave:"ì",iacute:"í",icirc:"î",iuml:"ï",eth:"ð",ntilde:"ñ",ograve:"ò",oacute:"ó",ocirc:"ô",otilde:"õ",ouml:"ö",divide:"÷",oslash:"ø",ugrave:"ù",uacute:"ú",ucirc:"û",uuml:"ü",yacute:"ý",thorn:"þ",yuml:"ÿ",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",fnof:"ƒ",circ:"ˆ",tilde:"˜",Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigmaf:"ς",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",chi:"χ",psi:"ψ",omega:"ω",thetasym:"ϑ",upsih:"ϒ",piv:"ϖ",ensp:" ",emsp:" ",thinsp:" ",zwnj:"‌",zwj:"‍",lrm:"‎",rlm:"‏",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",bull:"•",hellip:"…",permil:"‰",prime:"′",Prime:"″",lsaquo:"‹",rsaquo:"›",oline:"‾",frasl:"⁄",euro:"€",image:"ℑ",weierp:"℘",real:"ℜ",trade:"™",alefsym:"ℵ",larr:"←",uarr:"↑",rarr:"→",darr:"↓",harr:"↔",crarr:"↵",lArr:"⇐",uArr:"⇑",rArr:"⇒",dArr:"⇓",hArr:"⇔",forall:"∀",part:"∂",exist:"∃",empty:"∅",nabla:"∇",isin:"∈",notin:"∉",ni:"∋",prod:"∏",sum:"∑",minus:"−",lowast:"∗",radic:"√",prop:"∝",infin:"∞",ang:"∠",and:"∧",or:"∨",cap:"∩",cup:"∪",int:"∫",there4:"∴",sim:"∼",cong:"≅",asymp:"≈",ne:"≠",equiv:"≡",le:"≤",ge:"≥",sub:"⊂",sup:"⊃",nsub:"⊄",sube:"⊆",supe:"⊇",oplus:"⊕",otimes:"⊗",perp:"⊥",sdot:"⋅",lceil:"⌈",rceil:"⌉",lfloor:"⌊",rfloor:"⌋",lang:"〈",rang:"〉",loz:"◊",spades:"♠",clubs:"♣",hearts:"♥",diams:"♦"},N=/^[\da-fA-F]+$/,V=/^\d+$/;function z(e){return!!e&&("JSXOpeningFragment"===e.type||"JSXClosingFragment"===e.type)}function G(e){if("JSXIdentifier"===e.type)return e.name;if("JSXNamespacedName"===e.type)return e.namespace.name+":"+e.name.name;if("JSXMemberExpression"===e.type)return G(e.object)+"."+G(e.property);throw new Error("Node had unexpected type: "+e.type)}m.j_oTag=new y("...",!0,!0),s.jsxName=new r("jsxName"),s.jsxText=new r("jsxText",{beforeExpr:!0}),s.jsxTagStart=new r("jsxTagStart",{startsExpr:!0}),s.jsxTagEnd=new r("jsxTagEnd"),s.jsxTagStart.updateContext=function(){this.state.context.push(m.j_expr),this.state.context.push(m.j_oTag),this.state.exprAllowed=!1},s.jsxTagEnd.updateContext=function(e){const t=this.state.context.pop();t===m.j_oTag&&e===s.slash||t===m.j_cTag?(this.state.context.pop(),this.state.exprAllowed=this.curContext()===m.j_expr):this.state.exprAllowed=!0};class H{constructor(e){this.var=[],this.lexical=[],this.functions=[],this.flags=e}}class Y{constructor(e,t){this.scopeStack=[],this.undefinedExports=new Map,this.raise=e,this.inModule=t}get inFunction(){return(2&this.currentVarScope().flags)>0}get inGenerator(){return(8&this.currentVarScope().flags)>0}get inAsync(){return(4&this.currentVarScope().flags)>0}get allowSuper(){return(64&this.currentThisScope().flags)>0}get allowDirectSuper(){return(128&this.currentThisScope().flags)>0}get inClass(){return(256&this.currentThisScope().flags)>0}get inNonArrowFunction(){return(2&this.currentThisScope().flags)>0}get treatFunctionsAsVar(){return this.treatFunctionsAsVarInScope(this.currentScope())}createScope(e){return new H(e)}enter(e){this.scopeStack.push(this.createScope(e))}exit(){this.scopeStack.pop()}treatFunctionsAsVarInScope(e){return!!(2&e.flags||!this.inModule&&1&e.flags)}declareName(e,t,n){let r=this.currentScope();if(8&t||16&t)this.checkRedeclarationInScope(r,e,t,n),16&t?r.functions.push(e):r.lexical.push(e),8&t&&this.maybeExportDefined(r,e);else if(4&t)for(let i=this.scopeStack.length-1;i>=0&&(r=this.scopeStack[i],this.checkRedeclarationInScope(r,e,t,n),r.var.push(e),this.maybeExportDefined(r,e),!(515&r.flags));--i);this.inModule&&1&r.flags&&this.undefinedExports.delete(e)}maybeExportDefined(e,t){this.inModule&&1&e.flags&&this.undefinedExports.delete(t)}checkRedeclarationInScope(e,t,n,r){this.isRedeclaredInScope(e,t,n)&&this.raise(r,`Identifier '${t}' has already been declared`)}isRedeclaredInScope(e,t,n){return!!(1&n)&&(8&n?e.lexical.indexOf(t)>-1||e.functions.indexOf(t)>-1||e.var.indexOf(t)>-1:16&n?e.lexical.indexOf(t)>-1||!this.treatFunctionsAsVarInScope(e)&&e.var.indexOf(t)>-1:e.lexical.indexOf(t)>-1&&!(32&e.flags&&e.lexical[0]===t)||!this.treatFunctionsAsVarInScope(e)&&e.functions.indexOf(t)>-1)}checkLocalExport(e){-1===this.scopeStack[0].lexical.indexOf(e.name)&&-1===this.scopeStack[0].var.indexOf(e.name)&&-1===this.scopeStack[0].functions.indexOf(e.name)&&this.undefinedExports.set(e.name,e.start)}currentScope(){return this.scopeStack[this.scopeStack.length-1]}currentVarScope(){for(let e=this.scopeStack.length-1;;e--){const t=this.scopeStack[e];if(515&t.flags)return t}}currentThisScope(){for(let e=this.scopeStack.length-1;;e--){const t=this.scopeStack[e];if((515&t.flags||256&t.flags)&&!(16&t.flags))return t}}}class U extends H{constructor(...e){super(...e),this.types=[],this.enums=[],this.constEnums=[],this.classes=[],this.exportOnlyBindings=[]}}class X extends Y{createScope(e){return new U(e)}declareName(e,t,n){const r=this.currentScope();if(1024&t)return this.maybeExportDefined(r,e),void r.exportOnlyBindings.push(e);super.declareName(...arguments),2&t&&(1&t||(this.checkRedeclarationInScope(r,e,t,n),this.maybeExportDefined(r,e)),r.types.push(e)),256&t&&r.enums.push(e),512&t&&r.constEnums.push(e),128&t&&r.classes.push(e)}isRedeclaredInScope(e,t,n){if(e.enums.indexOf(t)>-1){if(256&n){return!!(512&n)!==e.constEnums.indexOf(t)>-1}return!0}return 128&n&&e.classes.indexOf(t)>-1?e.lexical.indexOf(t)>-1&&!!(1&n):!!(2&n&&e.types.indexOf(t)>-1)||super.isRedeclaredInScope(...arguments)}checkLocalExport(e){-1===this.scopeStack[0].types.indexOf(e.name)&&-1===this.scopeStack[0].exportOnlyBindings.indexOf(e.name)&&super.checkLocalExport(e)}}function W(e){if(null==e)throw new Error(`Unexpected ${e} value.`);return e}function K(e){if(!e)throw new Error("Assert fail")}s.placeholder=new r("%%",{startsExpr:!0});function q(e,t){return e.some(e=>Array.isArray(e)?e[0]===t:e===t)}function J(e,t,n){const r=e.find(e=>Array.isArray(e)?e[0]===t:e===t);return r&&Array.isArray(r)?r[1][n]:null}const Z=["minimal","smart","fsharp"];const Q={estree:e=>class extends e{estreeParseRegExpLiteral({pattern:e,flags:t}){let n=null;try{n=new RegExp(e,t)}catch(e){}const r=this.estreeParseLiteral(n);return r.regex={pattern:e,flags:t},r}estreeParseLiteral(e){return this.parseLiteral(e,"Literal")}directiveToStmt(e){const t=e.value,n=this.startNodeAt(e.start,e.loc.start),r=this.startNodeAt(t.start,t.loc.start);return r.value=t.value,r.raw=t.extra.raw,n.expression=this.finishNodeAt(r,"Literal",t.end,t.loc.end),n.directive=t.extra.raw.slice(1,-1),this.finishNodeAt(n,"ExpressionStatement",e.end,e.loc.end)}initFunction(e,t){super.initFunction(e,t),e.expression=!1}checkDeclaration(e){c(e)?this.checkDeclaration(e.value):super.checkDeclaration(e)}checkGetterSetterParams(e){const t=e,n="get"===t.kind?0:1,r=t.start;t.value.params.length!==n?"get"===t.kind?this.raise(r,"getter must not have any formal parameters"):this.raise(r,"setter must have exactly one formal parameter"):"set"===t.kind&&"RestElement"===t.value.params[0].type&&this.raise(r,"setter function argument must not be a rest parameter")}checkLVal(e,t=64,n,r,i){switch(e.type){case"ObjectPattern":e.properties.forEach(e=>{this.checkLVal("Property"===e.type?e.value:e,t,n,"object destructuring pattern",i)});break;default:super.checkLVal(e,t,n,r,i)}}checkDuplicatedProto(e,t){if("SpreadElement"===e.type||e.computed||e.method||e.shorthand)return;const n=e.key;"__proto__"===("Identifier"===n.type?n.name:String(n.value))&&"init"===e.kind&&(t.used&&!t.start&&(t.start=n.start),t.used=!0)}isStrictBody(e){if("BlockStatement"===e.body.type&&e.body.body.length>0)for(let t=0,n=e.body.body;tthis.directiveToStmt(e));e.body=i.concat(e.body),delete e.directives}pushClassMethod(e,t,n,r,i,o){this.parseMethod(t,n,r,i,o,"ClassMethod",!0),t.typeParameters&&(t.value.typeParameters=t.typeParameters,delete t.typeParameters),e.body.push(t)}parseExprAtom(e){switch(this.state.type){case s.regexp:return this.estreeParseRegExpLiteral(this.state.value);case s.num:case s.string:return this.estreeParseLiteral(this.state.value);case s._null:return this.estreeParseLiteral(null);case s._true:return this.estreeParseLiteral(!0);case s._false:return this.estreeParseLiteral(!1);default:return super.parseExprAtom(e)}}parseLiteral(e,t,n,r){const i=super.parseLiteral(e,t,n,r);return i.raw=i.extra.raw,delete i.extra,i}parseFunctionBody(e,t,n=!1){super.parseFunctionBody(e,t,n),e.expression="BlockStatement"!==e.body.type}parseMethod(e,t,n,r,i,o,a=!1){let s=this.startNode();return s.kind=e.kind,s=super.parseMethod(s,t,n,r,i,o,a),s.type="FunctionExpression",delete s.kind,e.value=s,o="ClassMethod"===o?"MethodDefinition":o,this.finishNode(e,o)}parseObjectMethod(e,t,n,r,i){const o=super.parseObjectMethod(e,t,n,r,i);return o&&(o.type="Property","method"===o.kind&&(o.kind="init"),o.shorthand=!1),o}parseObjectProperty(e,t,n,r,i){const o=super.parseObjectProperty(e,t,n,r,i);return o&&(o.kind="init",o.type="Property"),o}toAssignable(e,t,n){return c(e)?(this.toAssignable(e.value,t,n),e):super.toAssignable(e,t,n)}toAssignableObjectExpressionProp(e,t,n){if("get"===e.kind||"set"===e.kind)throw this.raise(e.key.start,"Object pattern can't contain getter or setter");if(e.method)throw this.raise(e.key.start,"Object pattern can't contain methods");super.toAssignableObjectExpressionProp(e,t,n)}},jsx:e=>class extends e{jsxReadToken(){let e="",t=this.state.pos;for(;;){if(this.state.pos>=this.length)throw this.raise(this.state.start,"Unterminated JSX contents");const n=this.input.charCodeAt(this.state.pos);switch(n){case 60:case 123:return this.state.pos===this.state.start?60===n&&this.state.exprAllowed?(++this.state.pos,this.finishToken(s.jsxTagStart)):super.getTokenFromCode(n):(e+=this.input.slice(t,this.state.pos),this.finishToken(s.jsxText,e));case 38:e+=this.input.slice(t,this.state.pos),e+=this.jsxReadEntity(),t=this.state.pos;break;default:p(n)?(e+=this.input.slice(t,this.state.pos),e+=this.jsxReadNewLine(!0),t=this.state.pos):++this.state.pos}}}jsxReadNewLine(e){const t=this.input.charCodeAt(this.state.pos);let n;return++this.state.pos,13===t&&10===this.input.charCodeAt(this.state.pos)?(++this.state.pos,n=e?"\n":"\r\n"):n=String.fromCharCode(t),++this.state.curLine,this.state.lineStart=this.state.pos,n}jsxReadString(e){let t="",n=++this.state.pos;for(;;){if(this.state.pos>=this.length)throw this.raise(this.state.start,"Unterminated string constant");const r=this.input.charCodeAt(this.state.pos);if(r===e)break;38===r?(t+=this.input.slice(n,this.state.pos),t+=this.jsxReadEntity(),n=this.state.pos):p(r)?(t+=this.input.slice(n,this.state.pos),t+=this.jsxReadNewLine(!1),n=this.state.pos):++this.state.pos}return t+=this.input.slice(n,this.state.pos++),this.finishToken(s.string,t)}jsxReadEntity(){let e,t="",n=0,r=this.input[this.state.pos];const i=++this.state.pos;for(;this.state.pos"):!z(i)&&z(o)?this.raise(o.start,"Expected corresponding JSX closing tag for <"+G(i.name)+">"):z(i)||z(o)||G(o.name)!==G(i.name)&&this.raise(o.start,"Expected corresponding JSX closing tag for <"+G(i.name)+">")}if(z(i)?(n.openingFragment=i,n.closingFragment=o):(n.openingElement=i,n.closingElement=o),n.children=r,this.isRelational("<"))throw this.raise(this.state.start,"Adjacent JSX elements must be wrapped in an enclosing tag. Did you want a JSX fragment <>...?");return z(i)?this.finishNode(n,"JSXFragment"):this.finishNode(n,"JSXElement")}jsxParseElement(){const e=this.state.start,t=this.state.startLoc;return this.next(),this.jsxParseElementAt(e,t)}parseExprAtom(e){return this.match(s.jsxText)?this.parseLiteral(this.state.value,"JSXText"):this.match(s.jsxTagStart)?this.jsxParseElement():this.isRelational("<")&&33!==this.input.charCodeAt(this.state.pos)?(this.finishToken(s.jsxTagStart),this.jsxParseElement()):super.parseExprAtom(e)}getTokenFromCode(e){if(this.state.inPropertyName)return super.getTokenFromCode(e);const t=this.curContext();if(t===m.j_expr)return this.jsxReadToken();if(t===m.j_oTag||t===m.j_cTag){if(D(e))return this.jsxReadWord();if(62===e)return++this.state.pos,this.finishToken(s.jsxTagEnd);if((34===e||39===e)&&t===m.j_oTag)return this.jsxReadString(e)}return 60===e&&this.state.exprAllowed&&33!==this.input.charCodeAt(this.state.pos+1)?(++this.state.pos,this.finishToken(s.jsxTagStart)):super.getTokenFromCode(e)}updateContext(e){if(this.match(s.braceL)){const t=this.curContext();t===m.j_oTag?this.state.context.push(m.braceExpression):t===m.j_expr?this.state.context.push(m.templateQuasi):super.updateContext(e),this.state.exprAllowed=!0}else{if(!this.match(s.slash)||e!==s.jsxTagStart)return super.updateContext(e);this.state.context.length-=2,this.state.context.push(m.j_cTag),this.state.exprAllowed=!1}}},flow:e=>class extends e{constructor(e,t){super(e,t),this.flowPragma=void 0}shouldParseTypes(){return this.getPluginOption("flow","all")||"flow"===this.flowPragma}shouldParseEnums(){return!!this.getPluginOption("flow","enums")}finishToken(e,t){return e!==s.string&&e!==s.semi&&e!==s.interpreterDirective&&void 0===this.flowPragma&&(this.flowPragma=null),super.finishToken(e,t)}addComment(e){if(void 0===this.flowPragma){const t=L.exec(e.value);if(t)if("flow"===t[1])this.flowPragma="flow";else{if("noflow"!==t[1])throw new Error("Unexpected flow pragma");this.flowPragma="noflow"}else;}return super.addComment(e)}flowParseTypeInitialiser(e){const t=this.state.inType;this.state.inType=!0,this.expect(e||s.colon);const n=this.flowParseType();return this.state.inType=t,n}flowParsePredicate(){const e=this.startNode(),t=this.state.startLoc,n=this.state.start;this.expect(s.modulo);const r=this.state.startLoc;return this.expectContextual("checks"),t.line===r.line&&t.column===r.column-1||this.raise(n,"Spaces between ´%´ and ´checks´ are not allowed here."),this.eat(s.parenL)?(e.value=this.parseExpression(),this.expect(s.parenR),this.finishNode(e,"DeclaredPredicate")):this.finishNode(e,"InferredPredicate")}flowParseTypeAndPredicateInitialiser(){const e=this.state.inType;this.state.inType=!0,this.expect(s.colon);let t=null,n=null;return this.match(s.modulo)?(this.state.inType=e,n=this.flowParsePredicate()):(t=this.flowParseType(),this.state.inType=e,this.match(s.modulo)&&(n=this.flowParsePredicate())),[t,n]}flowParseDeclareClass(e){return this.next(),this.flowParseInterfaceish(e,!0),this.finishNode(e,"DeclareClass")}flowParseDeclareFunction(e){this.next();const t=e.id=this.parseIdentifier(),n=this.startNode(),r=this.startNode();this.isRelational("<")?n.typeParameters=this.flowParseTypeParameterDeclaration():n.typeParameters=null,this.expect(s.parenL);const i=this.flowParseFunctionTypeParams();return n.params=i.params,n.rest=i.rest,this.expect(s.parenR),[n.returnType,e.predicate]=this.flowParseTypeAndPredicateInitialiser(),r.typeAnnotation=this.finishNode(n,"FunctionTypeAnnotation"),t.typeAnnotation=this.finishNode(r,"TypeAnnotation"),this.resetEndLocation(t),this.semicolon(),this.finishNode(e,"DeclareFunction")}flowParseDeclare(e,t){if(this.match(s._class))return this.flowParseDeclareClass(e);if(this.match(s._function))return this.flowParseDeclareFunction(e);if(this.match(s._var))return this.flowParseDeclareVariable(e);if(this.eatContextual("module"))return this.match(s.dot)?this.flowParseDeclareModuleExports(e):(t&&this.raise(this.state.lastTokStart,"`declare module` cannot be used inside another `declare module`"),this.flowParseDeclareModule(e));if(this.isContextual("type"))return this.flowParseDeclareTypeAlias(e);if(this.isContextual("opaque"))return this.flowParseDeclareOpaqueType(e);if(this.isContextual("interface"))return this.flowParseDeclareInterface(e);if(this.match(s._export))return this.flowParseDeclareExportDeclaration(e,t);throw this.unexpected()}flowParseDeclareVariable(e){return this.next(),e.id=this.flowParseTypeAnnotatableIdentifier(!0),this.scope.declareName(e.id.name,5,e.id.start),this.semicolon(),this.finishNode(e,"DeclareVariable")}flowParseDeclareModule(e){this.scope.enter(0),this.match(s.string)?e.id=this.parseExprAtom():e.id=this.parseIdentifier();const t=e.body=this.startNode(),n=t.body=[];for(this.expect(s.braceL);!this.match(s.braceR);){let e=this.startNode();this.match(s._import)?(this.next(),this.isContextual("type")||this.match(s._typeof)||this.raise(this.state.lastTokStart,"Imports within a `declare module` body must always be `import type` or `import typeof`"),this.parseImport(e)):(this.expectContextual("declare","Only declares and type imports are allowed inside declare module"),e=this.flowParseDeclare(e,!0)),n.push(e)}this.scope.exit(),this.expect(s.braceR),this.finishNode(t,"BlockStatement");let r=null,i=!1;const o="Found both `declare module.exports` and `declare export` in the same module. Modules can only have 1 since they are either an ES module or they are a CommonJS module";return n.forEach(e=>{!function(e){return"DeclareExportAllDeclaration"===e.type||"DeclareExportDeclaration"===e.type&&(!e.declaration||"TypeAlias"!==e.declaration.type&&"InterfaceDeclaration"!==e.declaration.type)}(e)?"DeclareModuleExports"===e.type&&(i&&this.raise(e.start,"Duplicate `declare module.exports` statement"),"ES"===r&&this.raise(e.start,o),r="CommonJS",i=!0):("CommonJS"===r&&this.raise(e.start,o),r="ES")}),e.kind=r||"CommonJS",this.finishNode(e,"DeclareModule")}flowParseDeclareExportDeclaration(e,t){if(this.expect(s._export),this.eat(s._default))return this.match(s._function)||this.match(s._class)?e.declaration=this.flowParseDeclare(this.startNode()):(e.declaration=this.flowParseType(),this.semicolon()),e.default=!0,this.finishNode(e,"DeclareExportDeclaration");if(this.match(s._const)||this.isLet()||(this.isContextual("type")||this.isContextual("interface"))&&!t){const e=this.state.value,t=R[e];this.unexpected(this.state.start,`\`declare export ${e}\` is not supported. Use \`${t}\` instead`)}if(this.match(s._var)||this.match(s._function)||this.match(s._class)||this.isContextual("opaque"))return e.declaration=this.flowParseDeclare(this.startNode()),e.default=!1,this.finishNode(e,"DeclareExportDeclaration");if(this.match(s.star)||this.match(s.braceL)||this.isContextual("interface")||this.isContextual("type")||this.isContextual("opaque"))return"ExportNamedDeclaration"===(e=this.parseExport(e)).type&&(e.type="ExportDeclaration",e.default=!1,delete e.exportKind),e.type="Declare"+e.type,e;throw this.unexpected()}flowParseDeclareModuleExports(e){return this.next(),this.expectContextual("exports"),e.typeAnnotation=this.flowParseTypeAnnotation(),this.semicolon(),this.finishNode(e,"DeclareModuleExports")}flowParseDeclareTypeAlias(e){return this.next(),this.flowParseTypeAlias(e),e.type="DeclareTypeAlias",e}flowParseDeclareOpaqueType(e){return this.next(),this.flowParseOpaqueType(e,!0),e.type="DeclareOpaqueType",e}flowParseDeclareInterface(e){return this.next(),this.flowParseInterfaceish(e),this.finishNode(e,"DeclareInterface")}flowParseInterfaceish(e,t=!1){if(e.id=this.flowParseRestrictedIdentifier(!t,!0),this.scope.declareName(e.id.name,t?17:9,e.id.start),this.isRelational("<")?e.typeParameters=this.flowParseTypeParameterDeclaration():e.typeParameters=null,e.extends=[],e.implements=[],e.mixins=[],this.eat(s._extends))do{e.extends.push(this.flowParseInterfaceExtends())}while(!t&&this.eat(s.comma));if(this.isContextual("mixins")){this.next();do{e.mixins.push(this.flowParseInterfaceExtends())}while(this.eat(s.comma))}if(this.isContextual("implements")){this.next();do{e.implements.push(this.flowParseInterfaceExtends())}while(this.eat(s.comma))}e.body=this.flowParseObjectType({allowStatic:t,allowExact:!1,allowSpread:!1,allowProto:t,allowInexact:!1})}flowParseInterfaceExtends(){const e=this.startNode();return e.id=this.flowParseQualifiedTypeIdentifier(),this.isRelational("<")?e.typeParameters=this.flowParseTypeParameterInstantiation():e.typeParameters=null,this.finishNode(e,"InterfaceExtends")}flowParseInterface(e){return this.flowParseInterfaceish(e),this.finishNode(e,"InterfaceDeclaration")}checkNotUnderscore(e){"_"===e&&this.raise(this.state.start,"`_` is only allowed as a type argument to call or new")}checkReservedType(e,t,n){F.has(e)&&(n?this.raise(t,`Cannot overwrite reserved type ${e}`):this.raise(t,`Unexpected reserved type ${e}`))}flowParseRestrictedIdentifier(e,t){return this.checkReservedType(this.state.value,this.state.start,t),this.parseIdentifier(e)}flowParseTypeAlias(e){return e.id=this.flowParseRestrictedIdentifier(!1,!0),this.scope.declareName(e.id.name,9,e.id.start),this.isRelational("<")?e.typeParameters=this.flowParseTypeParameterDeclaration():e.typeParameters=null,e.right=this.flowParseTypeInitialiser(s.eq),this.semicolon(),this.finishNode(e,"TypeAlias")}flowParseOpaqueType(e,t){return this.expectContextual("type"),e.id=this.flowParseRestrictedIdentifier(!0,!0),this.scope.declareName(e.id.name,9,e.id.start),this.isRelational("<")?e.typeParameters=this.flowParseTypeParameterDeclaration():e.typeParameters=null,e.supertype=null,this.match(s.colon)&&(e.supertype=this.flowParseTypeInitialiser(s.colon)),e.impltype=null,t||(e.impltype=this.flowParseTypeInitialiser(s.eq)),this.semicolon(),this.finishNode(e,"OpaqueType")}flowParseTypeParameter(e=!1){const t=this.state.start,n=this.startNode(),r=this.flowParseVariance(),i=this.flowParseTypeAnnotatableIdentifier();return n.name=i.name,n.variance=r,n.bound=i.typeAnnotation,this.match(s.eq)?(this.eat(s.eq),n.default=this.flowParseType()):e&&this.raise(t,"Type parameter declaration needs a default, since a preceding type parameter declaration has a default."),this.finishNode(n,"TypeParameter")}flowParseTypeParameterDeclaration(){const e=this.state.inType,t=this.startNode();t.params=[],this.state.inType=!0,this.isRelational("<")||this.match(s.jsxTagStart)?this.next():this.unexpected();let n=!1;do{const e=this.flowParseTypeParameter(n);t.params.push(e),e.default&&(n=!0),this.isRelational(">")||this.expect(s.comma)}while(!this.isRelational(">"));return this.expectRelational(">"),this.state.inType=e,this.finishNode(t,"TypeParameterDeclaration")}flowParseTypeParameterInstantiation(){const e=this.startNode(),t=this.state.inType;e.params=[],this.state.inType=!0,this.expectRelational("<");const n=this.state.noAnonFunctionType;for(this.state.noAnonFunctionType=!1;!this.isRelational(">");)e.params.push(this.flowParseType()),this.isRelational(">")||this.expect(s.comma);return this.state.noAnonFunctionType=n,this.expectRelational(">"),this.state.inType=t,this.finishNode(e,"TypeParameterInstantiation")}flowParseTypeParameterInstantiationCallOrNew(){const e=this.startNode(),t=this.state.inType;for(e.params=[],this.state.inType=!0,this.expectRelational("<");!this.isRelational(">");)e.params.push(this.flowParseTypeOrImplicitInstantiation()),this.isRelational(">")||this.expect(s.comma);return this.expectRelational(">"),this.state.inType=t,this.finishNode(e,"TypeParameterInstantiation")}flowParseInterfaceType(){const e=this.startNode();if(this.expectContextual("interface"),e.extends=[],this.eat(s._extends))do{e.extends.push(this.flowParseInterfaceExtends())}while(this.eat(s.comma));return e.body=this.flowParseObjectType({allowStatic:!1,allowExact:!1,allowSpread:!1,allowProto:!1,allowInexact:!1}),this.finishNode(e,"InterfaceTypeAnnotation")}flowParseObjectPropertyKey(){return this.match(s.num)||this.match(s.string)?this.parseExprAtom():this.parseIdentifier(!0)}flowParseObjectTypeIndexer(e,t,n){return e.static=t,this.lookahead().type===s.colon?(e.id=this.flowParseObjectPropertyKey(),e.key=this.flowParseTypeInitialiser()):(e.id=null,e.key=this.flowParseType()),this.expect(s.bracketR),e.value=this.flowParseTypeInitialiser(),e.variance=n,this.finishNode(e,"ObjectTypeIndexer")}flowParseObjectTypeInternalSlot(e,t){return e.static=t,e.id=this.flowParseObjectPropertyKey(),this.expect(s.bracketR),this.expect(s.bracketR),this.isRelational("<")||this.match(s.parenL)?(e.method=!0,e.optional=!1,e.value=this.flowParseObjectTypeMethodish(this.startNodeAt(e.start,e.loc.start))):(e.method=!1,this.eat(s.question)&&(e.optional=!0),e.value=this.flowParseTypeInitialiser()),this.finishNode(e,"ObjectTypeInternalSlot")}flowParseObjectTypeMethodish(e){for(e.params=[],e.rest=null,e.typeParameters=null,this.isRelational("<")&&(e.typeParameters=this.flowParseTypeParameterDeclaration()),this.expect(s.parenL);!this.match(s.parenR)&&!this.match(s.ellipsis);)e.params.push(this.flowParseFunctionTypeParam()),this.match(s.parenR)||this.expect(s.comma);return this.eat(s.ellipsis)&&(e.rest=this.flowParseFunctionTypeParam()),this.expect(s.parenR),e.returnType=this.flowParseTypeInitialiser(),this.finishNode(e,"FunctionTypeAnnotation")}flowParseObjectTypeCallProperty(e,t){const n=this.startNode();return e.static=t,e.value=this.flowParseObjectTypeMethodish(n),this.finishNode(e,"ObjectTypeCallProperty")}flowParseObjectType({allowStatic:e,allowExact:t,allowSpread:n,allowProto:r,allowInexact:i}){const o=this.state.inType;this.state.inType=!0;const a=this.startNode();let u,c;a.callProperties=[],a.properties=[],a.indexers=[],a.internalSlots=[];let l=!1;for(t&&this.match(s.braceBarL)?(this.expect(s.braceBarL),u=s.braceBarR,c=!0):(this.expect(s.braceL),u=s.braceR,c=!1),a.exact=c;!this.match(u);){let t=!1,o=null,u=null;const p=this.startNode();if(r&&this.isContextual("proto")){const t=this.lookahead();t.type!==s.colon&&t.type!==s.question&&(this.next(),o=this.state.start,e=!1)}if(e&&this.isContextual("static")){const e=this.lookahead();e.type!==s.colon&&e.type!==s.question&&(this.next(),t=!0)}const h=this.flowParseVariance();if(this.eat(s.bracketL))null!=o&&this.unexpected(o),this.eat(s.bracketL)?(h&&this.unexpected(h.start),a.internalSlots.push(this.flowParseObjectTypeInternalSlot(p,t))):a.indexers.push(this.flowParseObjectTypeIndexer(p,t,h));else if(this.match(s.parenL)||this.isRelational("<"))null!=o&&this.unexpected(o),h&&this.unexpected(h.start),a.callProperties.push(this.flowParseObjectTypeCallProperty(p,t));else{var f;let e="init";if(this.isContextual("get")||this.isContextual("set")){const t=this.lookahead();t.type!==s.name&&t.type!==s.string&&t.type!==s.num||(e=this.state.value,this.next())}const r=this.flowParseObjectTypeProperty(p,t,o,h,e,n,null!=(f=i)?f:!c);null===r?(l=!0,u=this.state.lastTokStart):a.properties.push(r)}this.flowObjectTypeSemicolon(),!u||this.match(s.braceR)||this.match(s.braceBarR)||this.raise(u,"Explicit inexact syntax must appear at the end of an inexact object")}this.expect(u),n&&(a.inexact=l);const p=this.finishNode(a,"ObjectTypeAnnotation");return this.state.inType=o,p}flowParseObjectTypeProperty(e,t,n,r,i,o,a){if(this.eat(s.ellipsis)){return this.match(s.comma)||this.match(s.semi)||this.match(s.braceR)||this.match(s.braceBarR)?(o?a||this.raise(this.state.lastTokStart,"Explicit inexact syntax cannot appear inside an explicit exact object type"):this.raise(this.state.lastTokStart,"Explicit inexact syntax cannot appear in class or interface definitions"),r&&this.raise(r.start,"Explicit inexact syntax cannot have variance"),null):(o||this.raise(this.state.lastTokStart,"Spread operator cannot appear in class or interface definitions"),null!=n&&this.unexpected(n),r&&this.raise(r.start,"Spread properties cannot have variance"),e.argument=this.flowParseType(),this.finishNode(e,"ObjectTypeSpreadProperty"))}{e.key=this.flowParseObjectPropertyKey(),e.static=t,e.proto=null!=n,e.kind=i;let o=!1;return this.isRelational("<")||this.match(s.parenL)?(e.method=!0,null!=n&&this.unexpected(n),r&&this.unexpected(r.start),e.value=this.flowParseObjectTypeMethodish(this.startNodeAt(e.start,e.loc.start)),"get"!==i&&"set"!==i||this.flowCheckGetterSetterParams(e)):("init"!==i&&this.unexpected(),e.method=!1,this.eat(s.question)&&(o=!0),e.value=this.flowParseTypeInitialiser(),e.variance=r),e.optional=o,this.finishNode(e,"ObjectTypeProperty")}}flowCheckGetterSetterParams(e){const t="get"===e.kind?0:1,n=e.start;e.value.params.length+(e.value.rest?1:0)!==t&&("get"===e.kind?this.raise(n,"getter must not have any formal parameters"):this.raise(n,"setter must have exactly one formal parameter")),"set"===e.kind&&e.value.rest&&this.raise(n,"setter function argument must not be a rest parameter")}flowObjectTypeSemicolon(){this.eat(s.semi)||this.eat(s.comma)||this.match(s.braceR)||this.match(s.braceBarR)||this.unexpected()}flowParseQualifiedTypeIdentifier(e,t,n){e=e||this.state.start,t=t||this.state.startLoc;let r=n||this.flowParseRestrictedIdentifier(!0);for(;this.eat(s.dot);){const n=this.startNodeAt(e,t);n.qualification=r,n.id=this.flowParseRestrictedIdentifier(!0),r=this.finishNode(n,"QualifiedTypeIdentifier")}return r}flowParseGenericType(e,t,n){const r=this.startNodeAt(e,t);return r.typeParameters=null,r.id=this.flowParseQualifiedTypeIdentifier(e,t,n),this.isRelational("<")&&(r.typeParameters=this.flowParseTypeParameterInstantiation()),this.finishNode(r,"GenericTypeAnnotation")}flowParseTypeofType(){const e=this.startNode();return this.expect(s._typeof),e.argument=this.flowParsePrimaryType(),this.finishNode(e,"TypeofTypeAnnotation")}flowParseTupleType(){const e=this.startNode();for(e.types=[],this.expect(s.bracketL);this.state.possuper.parseFunctionBody(e,!0,n)):super.parseFunctionBody(e,!1,n)}parseFunctionBodyAndFinish(e,t,n=!1){if(this.match(s.colon)){const t=this.startNode();[t.typeAnnotation,e.predicate]=this.flowParseTypeAndPredicateInitialiser(),e.returnType=t.typeAnnotation?this.finishNode(t,"TypeAnnotation"):null}super.parseFunctionBodyAndFinish(e,t,n)}parseStatement(e,t){if(this.state.strict&&this.match(s.name)&&"interface"===this.state.value){const e=this.startNode();return this.next(),this.flowParseInterface(e)}if(this.shouldParseEnums()&&this.isContextual("enum")){const e=this.startNode();return this.next(),this.flowParseEnumDeclaration(e)}{const n=super.parseStatement(e,t);return void 0!==this.flowPragma||this.isValidDirective(n)||(this.flowPragma=null),n}}parseExpressionStatement(e,t){if("Identifier"===t.type)if("declare"===t.name){if(this.match(s._class)||this.match(s.name)||this.match(s._function)||this.match(s._var)||this.match(s._export))return this.flowParseDeclare(e)}else if(this.match(s.name)){if("interface"===t.name)return this.flowParseInterface(e);if("type"===t.name)return this.flowParseTypeAlias(e);if("opaque"===t.name)return this.flowParseOpaqueType(e,!1)}return super.parseExpressionStatement(e,t)}shouldParseExportDeclaration(){return this.isContextual("type")||this.isContextual("interface")||this.isContextual("opaque")||this.shouldParseEnums()&&this.isContextual("enum")||super.shouldParseExportDeclaration()}isExportDefaultSpecifier(){return(!this.match(s.name)||!("type"===this.state.value||"interface"===this.state.value||"opaque"===this.state.value||this.shouldParseEnums()&&"enum"===this.state.value))&&super.isExportDefaultSpecifier()}parseExportDefaultExpression(){if(this.shouldParseEnums()&&this.isContextual("enum")){const e=this.startNode();return this.next(),this.flowParseEnumDeclaration(e)}return super.parseExportDefaultExpression()}parseConditional(e,t,n,r,i){if(!this.match(s.question))return e;if(i){const o=this.tryParse(()=>super.parseConditional(e,t,n,r));return o.node?(o.error&&(this.state=o.failState),o.node):(i.start=o.error.pos||this.state.start,e)}this.expect(s.question);const o=this.state.clone(),a=this.state.noArrowAt,u=this.startNodeAt(n,r);let{consequent:c,failed:l}=this.tryParseConditionalConsequent(),[f,p]=this.getArrowLikeExpressions(c);if(l||p.length>0){const e=[...a];if(p.length>0){this.state=o,this.state.noArrowAt=e;for(let t=0;t1&&this.raise(o.start,"Ambiguous expression: wrap the arrow functions in parentheses to disambiguate."),l&&1===f.length&&(this.state=o,this.state.noArrowAt=e.concat(f[0].start),({consequent:c,failed:l}=this.tryParseConditionalConsequent()))}return this.getArrowLikeExpressions(c,!0),this.state.noArrowAt=a,this.expect(s.colon),u.test=e,u.consequent=c,u.alternate=this.forwardNoArrowParamsConversionAt(u,()=>this.parseMaybeAssign(t,void 0,void 0,void 0)),this.finishNode(u,"ConditionalExpression")}tryParseConditionalConsequent(){this.state.noArrowParamsConversionAt.push(this.state.start);const e=this.parseMaybeAssign(),t=!this.match(s.colon);return this.state.noArrowParamsConversionAt.pop(),{consequent:e,failed:t}}getArrowLikeExpressions(e,t){const n=[e],r=[];for(;0!==n.length;){const e=n.pop();"ArrowFunctionExpression"===e.type?(e.typeParameters||!e.returnType?this.finishArrowValidation(e):r.push(e),n.push(e.body)):"ConditionalExpression"===e.type&&(n.push(e.consequent),n.push(e.alternate))}return t?(r.forEach(e=>this.finishArrowValidation(e)),[r,[]]):function(e,t){const n=[],r=[];for(let i=0;ie.params.every(e=>this.isAssignable(e,!0)))}finishArrowValidation(e){var t;this.toAssignableList(e.params,!0,"arrow function parameters",null==(t=e.extra)?void 0:t.trailingComma),this.scope.enter(16|u(!1,!1)),super.checkParams(e,!1,!0),this.scope.exit()}forwardNoArrowParamsConversionAt(e,t){let n;return-1!==this.state.noArrowParamsConversionAt.indexOf(e.start)?(this.state.noArrowParamsConversionAt.push(this.state.start),n=t(),this.state.noArrowParamsConversionAt.pop()):n=t(),n}parseParenItem(e,t,n){if(e=super.parseParenItem(e,t,n),this.eat(s.question)&&(e.optional=!0,this.resetEndLocation(e)),this.match(s.colon)){const r=this.startNodeAt(t,n);return r.expression=e,r.typeAnnotation=this.flowParseTypeAnnotation(),this.finishNode(r,"TypeCastExpression")}return e}assertModuleNodeAllowed(e){"ImportDeclaration"===e.type&&("type"===e.importKind||"typeof"===e.importKind)||"ExportNamedDeclaration"===e.type&&"type"===e.exportKind||"ExportAllDeclaration"===e.type&&"type"===e.exportKind||super.assertModuleNodeAllowed(e)}parseExport(e){const t=super.parseExport(e);return"ExportNamedDeclaration"!==t.type&&"ExportAllDeclaration"!==t.type||(t.exportKind=t.exportKind||"value"),t}parseExportDeclaration(e){if(this.isContextual("type")){e.exportKind="type";const t=this.startNode();return this.next(),this.match(s.braceL)?(e.specifiers=this.parseExportSpecifiers(),this.parseExportFrom(e),null):this.flowParseTypeAlias(t)}if(this.isContextual("opaque")){e.exportKind="type";const t=this.startNode();return this.next(),this.flowParseOpaqueType(t,!1)}if(this.isContextual("interface")){e.exportKind="type";const t=this.startNode();return this.next(),this.flowParseInterface(t)}if(this.shouldParseEnums()&&this.isContextual("enum")){e.exportKind="value";const t=this.startNode();return this.next(),this.flowParseEnumDeclaration(t)}return super.parseExportDeclaration(e)}eatExportStar(e){return!!super.eatExportStar(...arguments)||!(!this.isContextual("type")||this.lookahead().type!==s.star)&&(e.exportKind="type",this.next(),this.next(),!0)}maybeParseExportNamespaceSpecifier(e){const t=this.state.start,n=super.maybeParseExportNamespaceSpecifier(e);return n&&"type"===e.exportKind&&this.unexpected(t),n}parseClassId(e,t,n){super.parseClassId(e,t,n),this.isRelational("<")&&(e.typeParameters=this.flowParseTypeParameterDeclaration())}getTokenFromCode(e){const t=this.input.charCodeAt(this.state.pos+1);return 123===e&&124===t?this.finishOp(s.braceBarL,2):!this.state.inType||62!==e&&60!==e?function(e,t){return 64===e&&64===t}(e,t)?(this.state.isIterator=!0,super.readWord()):super.getTokenFromCode(e):this.finishOp(s.relational,1)}isAssignable(e,t){switch(e.type){case"Identifier":case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":return!0;case"ObjectExpression":{const t=e.properties.length-1;return e.properties.every((e,n)=>"ObjectMethod"!==e.type&&(n===t||"SpreadElement"===e.type)&&this.isAssignable(e))}case"ObjectProperty":return this.isAssignable(e.value);case"SpreadElement":return this.isAssignable(e.argument);case"ArrayExpression":return e.elements.every(e=>this.isAssignable(e));case"AssignmentExpression":return"="===e.operator;case"ParenthesizedExpression":case"TypeCastExpression":return this.isAssignable(e.expression);case"MemberExpression":case"OptionalMemberExpression":return!t;default:return!1}}toAssignable(e,t,n){return"TypeCastExpression"===e.type?super.toAssignable(this.typeCastToParameter(e),t,n):super.toAssignable(e,t,n)}toAssignableList(e,t,n,r){for(let t=0;t1)&&t||this.raise(r.typeAnnotation.start,"The type cast expression is expected to be wrapped with parenthesis")}return e}checkLVal(e,t=64,n,r){if("TypeCastExpression"!==e.type)return super.checkLVal(e,t,n,r)}parseClassProperty(e){return this.match(s.colon)&&(e.typeAnnotation=this.flowParseTypeAnnotation()),super.parseClassProperty(e)}parseClassPrivateProperty(e){return this.match(s.colon)&&(e.typeAnnotation=this.flowParseTypeAnnotation()),super.parseClassPrivateProperty(e)}isClassMethod(){return this.isRelational("<")||super.isClassMethod()}isClassProperty(){return this.match(s.colon)||super.isClassProperty()}isNonstaticConstructor(e){return!this.match(s.colon)&&super.isNonstaticConstructor(e)}pushClassMethod(e,t,n,r,i,o){t.variance&&this.unexpected(t.variance.start),delete t.variance,this.isRelational("<")&&(t.typeParameters=this.flowParseTypeParameterDeclaration()),super.pushClassMethod(e,t,n,r,i,o)}pushClassPrivateMethod(e,t,n,r){t.variance&&this.unexpected(t.variance.start),delete t.variance,this.isRelational("<")&&(t.typeParameters=this.flowParseTypeParameterDeclaration()),super.pushClassPrivateMethod(e,t,n,r)}parseClassSuper(e){if(super.parseClassSuper(e),e.superClass&&this.isRelational("<")&&(e.superTypeParameters=this.flowParseTypeParameterInstantiation()),this.isContextual("implements")){this.next();const t=e.implements=[];do{const e=this.startNode();e.id=this.flowParseRestrictedIdentifier(!0),this.isRelational("<")?e.typeParameters=this.flowParseTypeParameterInstantiation():e.typeParameters=null,t.push(this.finishNode(e,"ClassImplements"))}while(this.eat(s.comma))}}parsePropertyName(e){const t=this.flowParseVariance(),n=super.parsePropertyName(e);return e.variance=t,n}parseObjPropValue(e,t,n,r,i,o,a,u){let c;e.variance&&this.unexpected(e.variance.start),delete e.variance,this.isRelational("<")&&(c=this.flowParseTypeParameterDeclaration(),this.match(s.parenL)||this.unexpected()),super.parseObjPropValue(e,t,n,r,i,o,a,u),c&&((e.value||e).typeParameters=c)}parseAssignableListItemTypes(e){return this.eat(s.question)&&("Identifier"!==e.type&&this.raise(e.start,"A binding pattern parameter cannot be optional in an implementation signature."),e.optional=!0),this.match(s.colon)&&(e.typeAnnotation=this.flowParseTypeAnnotation()),this.resetEndLocation(e),e}parseMaybeDefault(e,t,n){const r=super.parseMaybeDefault(e,t,n);return"AssignmentPattern"===r.type&&r.typeAnnotation&&r.right.startsuper.parseMaybeAssign(e,t,n,r),o),!i.error)return i.node;const{context:a}=this.state;a[a.length-1]===m.j_oTag?a.length-=2:a[a.length-1]===m.j_expr&&(a.length-=1)}if(i&&i.error||this.isRelational("<")){let a;o=o||this.state.clone();const s=this.tryParse(()=>{a=this.flowParseTypeParameterDeclaration();const i=this.forwardNoArrowParamsConversionAt(a,()=>super.parseMaybeAssign(e,t,n,r));return i.typeParameters=a,this.resetStartLocationFromNode(i,a),i},o),u=s.node&&"ArrowFunctionExpression"===s.node.type?s.node:null;if(!s.error&&u)return u;if(i&&i.node)return this.state=i.failState,i.node;if(u)return this.state=s.failState,u;if(i&&i.thrown)throw i.error;if(s.thrown)throw s.error;throw this.raise(a.start,"Expected an arrow function after this type parameter declaration")}return super.parseMaybeAssign(e,t,n,r)}parseArrow(e){if(this.match(s.colon)){const t=this.tryParse(()=>{const t=this.state.noAnonFunctionType;this.state.noAnonFunctionType=!0;const n=this.startNode();return[n.typeAnnotation,e.predicate]=this.flowParseTypeAndPredicateInitialiser(),this.state.noAnonFunctionType=t,this.canInsertSemicolon()&&this.unexpected(),this.match(s.arrow)||this.unexpected(),n});if(t.thrown)return null;t.error&&(this.state=t.failState),e.returnType=t.node.typeAnnotation?this.finishNode(t.node,"TypeAnnotation"):null}return super.parseArrow(e)}shouldParseArrow(){return this.match(s.colon)||super.shouldParseArrow()}setArrowFunctionParameters(e,t){-1!==this.state.noArrowParamsConversionAt.indexOf(e.start)?e.params=t:super.setArrowFunctionParameters(e,t)}checkParams(e,t,n){if(!n||-1===this.state.noArrowParamsConversionAt.indexOf(e.start))return super.checkParams(...arguments)}parseParenAndDistinguishExpression(e){return super.parseParenAndDistinguishExpression(e&&-1===this.state.noArrowAt.indexOf(this.state.start))}parseSubscripts(e,t,n,r){if("Identifier"===e.type&&"async"===e.name&&-1!==this.state.noArrowAt.indexOf(t)){this.next();const r=this.startNodeAt(t,n);r.callee=e,r.arguments=this.parseCallExpressionArguments(s.parenR,!1),e=this.finishNode(r,"CallExpression")}else if("Identifier"===e.type&&"async"===e.name&&this.isRelational("<")){const i=this.state.clone(),o=this.tryParse(e=>this.parseAsyncArrowWithTypeParameters(t,n)||e(),i);if(!o.error&&!o.aborted)return o.node;const a=this.tryParse(()=>super.parseSubscripts(e,t,n,r),i);if(a.node&&!a.error)return a.node;if(o.node)return this.state=o.failState,o.node;if(a.node)return this.state=a.failState,a.node;throw o.error||a.error}return super.parseSubscripts(e,t,n,r)}parseSubscript(e,t,n,r,i){if(this.match(s.questionDot)&&this.isLookaheadRelational("<")){if(this.expectPlugin("optionalChaining"),i.optionalChainMember=!0,r)return i.stop=!0,e;this.next();const o=this.startNodeAt(t,n);return o.callee=e,o.typeArguments=this.flowParseTypeParameterInstantiation(),this.expect(s.parenL),o.arguments=this.parseCallExpressionArguments(s.parenR,!1),o.optional=!0,this.finishCallExpression(o,!0)}if(!r&&this.shouldParseTypes()&&this.isRelational("<")){const r=this.startNodeAt(t,n);r.callee=e;const o=this.tryParse(()=>(r.typeArguments=this.flowParseTypeParameterInstantiationCallOrNew(),this.expect(s.parenL),r.arguments=this.parseCallExpressionArguments(s.parenR,!1),i.optionalChainMember&&(r.optional=!1),this.finishCallExpression(r,i.optionalChainMember)));if(o.node)return o.error&&(this.state=o.failState),o.node}return super.parseSubscript(e,t,n,r,i)}parseNewArguments(e){let t=null;this.shouldParseTypes()&&this.isRelational("<")&&(t=this.tryParse(()=>this.flowParseTypeParameterInstantiationCallOrNew()).node),e.typeArguments=t,super.parseNewArguments(e)}parseAsyncArrowWithTypeParameters(e,t){const n=this.startNodeAt(e,t);if(this.parseFunctionParams(n),this.parseArrow(n))return this.parseArrowExpression(n,void 0,!0)}readToken_mult_modulo(e){const t=this.input.charCodeAt(this.state.pos+1);if(42===e&&47===t&&this.state.hasFlowComment)return this.state.hasFlowComment=!1,this.state.pos+=2,void this.nextToken();super.readToken_mult_modulo(e)}readToken_pipe_amp(e){const t=this.input.charCodeAt(this.state.pos+1);124!==e||125!==t?super.readToken_pipe_amp(e):this.finishOp(s.braceBarR,2)}parseTopLevel(e,t){const n=super.parseTopLevel(e,t);return this.state.hasFlowComment&&this.raise(this.state.pos,"Unterminated flow-comment"),n}skipBlockComment(){if(this.hasPlugin("flowComments")&&this.skipFlowComment())return this.state.hasFlowComment&&this.unexpected(null,"Cannot have a flow comment inside another flow comment"),this.hasFlowCommentCompletion(),this.state.pos+=this.skipFlowComment(),void(this.state.hasFlowComment=!0);if(this.state.hasFlowComment){const e=this.input.indexOf("*-/",this.state.pos+=2);if(-1===e)throw this.raise(this.state.pos-2,"Unterminated comment");this.state.pos=e+3}else super.skipBlockComment()}skipFlowComment(){const{pos:e}=this.state;let t=2;for(;[32,9].includes(this.input.charCodeAt(e+t));)t++;const n=this.input.charCodeAt(t+e),r=this.input.charCodeAt(t+e+1);return 58===n&&58===r?t+2:"flow-include"===this.input.slice(t+e,t+e+12)?t+12:58===n&&58!==r&&t}hasFlowCommentCompletion(){if(-1===this.input.indexOf("*/",this.state.pos))throw this.raise(this.state.pos,"Unterminated comment")}flowEnumErrorBooleanMemberNotInitialized(e,{enumName:t,memberName:n}){this.raise(e,`Boolean enum members need to be initialized. Use either \`${n} = true,\` `+`or \`${n} = false,\` in enum \`${t}\`.`)}flowEnumErrorInvalidMemberName(e,{enumName:t,memberName:n}){const r=n[0].toUpperCase()+n.slice(1);this.raise(e,"Enum member names cannot start with lowercase 'a' through 'z'. Instead of using "+`\`${n}\`, consider using \`${r}\`, in enum \`${t}\`.`)}flowEnumErrorDuplicateMemberName(e,{enumName:t,memberName:n}){this.raise(e,`Enum member names need to be unique, but the name \`${n}\` has already been used `+`before in enum \`${t}\`.`)}flowEnumErrorInconsistentMemberValues(e,{enumName:t}){this.raise(e,`Enum \`${t}\` has inconsistent member initializers. Either use no initializers, or `+"consistently use literals (either booleans, numbers, or strings) for all member initializers.")}flowEnumErrorInvalidExplicitType(e,{enumName:t,suppliedType:n}){const r="Use one of `boolean`, `number`, `string`, or `symbol` in "+`enum \`${t}\`.`,i=null===n?`Supplied enum type is not valid. ${r}`:`Enum type \`${n}\` is not valid. ${r}`;return this.raise(e,i)}flowEnumErrorInvalidMemberInitializer(e,{enumName:t,explicitType:n,memberName:r}){let i=null;switch(n){case"boolean":case"number":case"string":i=`Enum \`${t}\` has type \`${n}\`, so the initializer of `+`\`${r}\` needs to be a ${n} literal.`;break;case"symbol":i=`Symbol enum members cannot be initialized. Use \`${r},\` in `+`enum \`${t}\`.`;break;default:i=`The enum member initializer for \`${r}\` needs to be a literal (either `+`a boolean, number, or string) in enum \`${t}\`.`}return this.raise(e,i)}flowEnumErrorNumberMemberNotInitialized(e,{enumName:t,memberName:n}){this.raise(e,`Number enum members need to be initialized, e.g. \`${n} = 1\` in enum \`${t}\`.`)}flowEnumErrorStringMemberInconsistentlyInitailized(e,{enumName:t}){this.raise(e,"String enum members need to consistently either all use initializers, or use no initializers, "+`in enum \`${t}\`.`)}flowEnumMemberInit(){const e=this.state.start,t=()=>this.match(s.comma)||this.match(s.braceR);switch(this.state.type){case s.num:{const n=this.parseLiteral(this.state.value,"NumericLiteral");return t()?{type:"number",pos:n.start,value:n}:{type:"invalid",pos:e}}case s.string:{const n=this.parseLiteral(this.state.value,"StringLiteral");return t()?{type:"string",pos:n.start,value:n}:{type:"invalid",pos:e}}case s._true:case s._false:{const n=this.parseBooleanLiteral();return t()?{type:"boolean",pos:n.start,value:n}:{type:"invalid",pos:e}}default:return{type:"invalid",pos:e}}}flowEnumMemberRaw(){const e=this.state.start;return{id:this.parseIdentifier(!0),init:this.eat(s.eq)?this.flowEnumMemberInit():{type:"none",pos:e}}}flowEnumCheckExplicitTypeMismatch(e,t,n){const{explicitType:r}=t;null!==r&&r!==n&&this.flowEnumErrorInvalidMemberInitializer(e,t)}flowEnumMembers({enumName:e,explicitType:t}){const n=new Set,r={booleanMembers:[],numberMembers:[],stringMembers:[],defaultedMembers:[]};for(;!this.match(s.braceR);){const i=this.startNode(),{id:o,init:a}=this.flowEnumMemberRaw(),u=o.name;if(""===u)continue;/^[a-z]/.test(u)&&this.flowEnumErrorInvalidMemberName(o.start,{enumName:e,memberName:u}),n.has(u)&&this.flowEnumErrorDuplicateMemberName(o.start,{enumName:e,memberName:u}),n.add(u);const c={enumName:e,explicitType:t,memberName:u};switch(i.id=o,a.type){case"boolean":this.flowEnumCheckExplicitTypeMismatch(a.pos,c,"boolean"),i.init=a.value,r.booleanMembers.push(this.finishNode(i,"EnumBooleanMember"));break;case"number":this.flowEnumCheckExplicitTypeMismatch(a.pos,c,"number"),i.init=a.value,r.numberMembers.push(this.finishNode(i,"EnumNumberMember"));break;case"string":this.flowEnumCheckExplicitTypeMismatch(a.pos,c,"string"),i.init=a.value,r.stringMembers.push(this.finishNode(i,"EnumStringMember"));break;case"invalid":throw this.flowEnumErrorInvalidMemberInitializer(a.pos,c);case"none":switch(t){case"boolean":this.flowEnumErrorBooleanMemberNotInitialized(a.pos,c);break;case"number":this.flowEnumErrorNumberMemberNotInitialized(a.pos,c);break;default:r.defaultedMembers.push(this.finishNode(i,"EnumDefaultedMember"))}}this.match(s.braceR)||this.expect(s.comma)}return r}flowEnumStringMembers(e,t,{enumName:n}){if(0===e.length)return t;if(0===t.length)return e;if(t.length>e.length){for(let t=0;t(e.members=[],this.expect(s.braceR),this.finishNode(e,"EnumStringBody"));e.explicitType=!1;const o=i.booleanMembers.length,a=i.numberMembers.length,u=i.stringMembers.length,c=i.defaultedMembers.length;if(o||a||u||c){if(o||a){if(!a&&!u&&o>=c){for(let e=0,n=i.defaultedMembers;e=c){for(let e=0,n=i.defaultedMembers;eclass extends e{getScopeHandler(){return X}tsIsIdentifier(){return this.match(s.name)}tsNextTokenCanFollowModifier(){return this.next(),!(this.hasPrecedingLineBreak()||this.match(s.parenL)||this.match(s.parenR)||this.match(s.colon)||this.match(s.eq)||this.match(s.question)||this.match(s.bang))}tsParseModifier(e){if(!this.match(s.name))return;const t=this.state.value;return-1!==e.indexOf(t)&&this.tsTryParse(this.tsNextTokenCanFollowModifier.bind(this))?t:void 0}tsParseModifiers(e){const t=Object.create(null);for(;;){const n=this.state.start,r=this.tsParseModifier(e);if(!r)break;Object.hasOwnProperty.call(t,r)&&this.raise(n,`Duplicate modifier: '${r}'`),t[r]=!0}return t}tsIsListTerminator(e){switch(e){case"EnumMembers":case"TypeMembers":return this.match(s.braceR);case"HeritageClauseElement":return this.match(s.braceL);case"TupleElementTypes":return this.match(s.bracketR);case"TypeParametersOrArguments":return this.isRelational(">")}throw new Error("Unreachable")}tsParseList(e,t){const n=[];for(;!this.tsIsListTerminator(e);)n.push(t());return n}tsParseDelimitedList(e,t){return W(this.tsParseDelimitedListWorker(e,t,!0))}tsParseDelimitedListWorker(e,t,n){const r=[];for(;!this.tsIsListTerminator(e);){const i=t();if(null==i)return;if(r.push(i),!this.eat(s.comma)){if(this.tsIsListTerminator(e))break;return void(n&&this.expect(s.comma))}}return r}tsParseBracketedList(e,t,n,r){r||(n?this.expect(s.bracketL):this.expectRelational("<"));const i=this.tsParseDelimitedList(e,t);return n?this.expect(s.bracketR):this.expectRelational(">"),i}tsParseImportType(){const e=this.startNode();return this.expect(s._import),this.expect(s.parenL),this.match(s.string)||this.raise(this.state.start,"Argument in a type import must be a string literal"),e.argument=this.parseExprAtom(),this.expect(s.parenR),this.eat(s.dot)&&(e.qualifier=this.tsParseEntityName(!0)),this.isRelational("<")&&(e.typeParameters=this.tsParseTypeArguments()),this.finishNode(e,"TSImportType")}tsParseEntityName(e){let t=this.parseIdentifier();for(;this.eat(s.dot);){const n=this.startNodeAtNode(t);n.left=t,n.right=this.parseIdentifier(e),t=this.finishNode(n,"TSQualifiedName")}return t}tsParseTypeReference(){const e=this.startNode();return e.typeName=this.tsParseEntityName(!1),!this.hasPrecedingLineBreak()&&this.isRelational("<")&&(e.typeParameters=this.tsParseTypeArguments()),this.finishNode(e,"TSTypeReference")}tsParseThisTypePredicate(e){this.next();const t=this.startNodeAtNode(e);return t.parameterName=e,t.typeAnnotation=this.tsParseTypeAnnotation(!1),this.finishNode(t,"TSTypePredicate")}tsParseThisTypeNode(){const e=this.startNode();return this.next(),this.finishNode(e,"TSThisType")}tsParseTypeQuery(){const e=this.startNode();return this.expect(s._typeof),this.match(s._import)?e.exprName=this.tsParseImportType():e.exprName=this.tsParseEntityName(!0),this.finishNode(e,"TSTypeQuery")}tsParseTypeParameter(){const e=this.startNode();return e.name=this.parseIdentifierName(e.start),e.constraint=this.tsEatThenParseType(s._extends),e.default=this.tsEatThenParseType(s.eq),this.finishNode(e,"TSTypeParameter")}tsTryParseTypeParameters(){if(this.isRelational("<"))return this.tsParseTypeParameters()}tsParseTypeParameters(){const e=this.startNode();return this.isRelational("<")||this.match(s.jsxTagStart)?this.next():this.unexpected(),e.params=this.tsParseBracketedList("TypeParametersOrArguments",this.tsParseTypeParameter.bind(this),!1,!0),this.finishNode(e,"TSTypeParameterDeclaration")}tsTryNextParseConstantContext(){return this.lookahead().type===s._const?(this.next(),this.tsParseTypeReference()):null}tsFillSignature(e,t){const n=e===s.arrow;t.typeParameters=this.tsTryParseTypeParameters(),this.expect(s.parenL),t.parameters=this.tsParseBindingListForSignature(),n?t.typeAnnotation=this.tsParseTypeOrTypePredicateAnnotation(e):this.match(e)&&(t.typeAnnotation=this.tsParseTypeOrTypePredicateAnnotation(e))}tsParseBindingListForSignature(){return this.parseBindingList(s.parenR,41).map(e=>("Identifier"!==e.type&&"RestElement"!==e.type&&"ObjectPattern"!==e.type&&"ArrayPattern"!==e.type&&this.raise(e.start,"Name in a signature must be an Identifier, ObjectPattern or ArrayPattern,"+`instead got ${e.type}`),e))}tsParseTypeMemberSemicolon(){this.eat(s.comma)||this.semicolon()}tsParseSignatureMember(e,t){return this.tsFillSignature(s.colon,t),this.tsParseTypeMemberSemicolon(),this.finishNode(t,e)}tsIsUnambiguouslyIndexSignature(){return this.next(),this.eat(s.name)&&this.match(s.colon)}tsTryParseIndexSignature(e){if(!this.match(s.bracketL)||!this.tsLookAhead(this.tsIsUnambiguouslyIndexSignature.bind(this)))return;this.expect(s.bracketL);const t=this.parseIdentifier();t.typeAnnotation=this.tsParseTypeAnnotation(),this.resetEndLocation(t),this.expect(s.bracketR),e.parameters=[t];const n=this.tsTryParseTypeAnnotation();return n&&(e.typeAnnotation=n),this.tsParseTypeMemberSemicolon(),this.finishNode(e,"TSIndexSignature")}tsParsePropertyOrMethodSignature(e,t){this.eat(s.question)&&(e.optional=!0);const n=e;if(t||!this.match(s.parenL)&&!this.isRelational("<")){const e=n;t&&(e.readonly=!0);const r=this.tsTryParseTypeAnnotation();return r&&(e.typeAnnotation=r),this.tsParseTypeMemberSemicolon(),this.finishNode(e,"TSPropertySignature")}{const e=n;return this.tsFillSignature(s.colon,e),this.tsParseTypeMemberSemicolon(),this.finishNode(e,"TSMethodSignature")}}tsParseTypeMember(){const e=this.startNode();if(this.match(s.parenL)||this.isRelational("<"))return this.tsParseSignatureMember("TSCallSignatureDeclaration",e);if(this.match(s._new)){const t=this.startNode();return this.next(),this.match(s.parenL)||this.isRelational("<")?this.tsParseSignatureMember("TSConstructSignatureDeclaration",e):(e.key=this.createIdentifier(t,"new"),this.tsParsePropertyOrMethodSignature(e,!1))}const t=!!this.tsParseModifier(["readonly"]),n=this.tsTryParseIndexSignature(e);return n?(t&&(e.readonly=!0),n):(this.parsePropertyName(e),this.tsParsePropertyOrMethodSignature(e,t))}tsParseTypeLiteral(){const e=this.startNode();return e.members=this.tsParseObjectTypeMembers(),this.finishNode(e,"TSTypeLiteral")}tsParseObjectTypeMembers(){this.expect(s.braceL);const e=this.tsParseList("TypeMembers",this.tsParseTypeMember.bind(this));return this.expect(s.braceR),e}tsIsStartOfMappedType(){return this.next(),this.eat(s.plusMin)?this.isContextual("readonly"):(this.isContextual("readonly")&&this.next(),!!this.match(s.bracketL)&&(this.next(),!!this.tsIsIdentifier()&&(this.next(),this.match(s._in))))}tsParseMappedTypeParameter(){const e=this.startNode();return e.name=this.parseIdentifierName(e.start),e.constraint=this.tsExpectThenParseType(s._in),this.finishNode(e,"TSTypeParameter")}tsParseMappedType(){const e=this.startNode();return this.expect(s.braceL),this.match(s.plusMin)?(e.readonly=this.state.value,this.next(),this.expectContextual("readonly")):this.eatContextual("readonly")&&(e.readonly=!0),this.expect(s.bracketL),e.typeParameter=this.tsParseMappedTypeParameter(),this.expect(s.bracketR),this.match(s.plusMin)?(e.optional=this.state.value,this.next(),this.expect(s.question)):this.eat(s.question)&&(e.optional=!0),e.typeAnnotation=this.tsTryParseType(),this.semicolon(),this.expect(s.braceR),this.finishNode(e,"TSMappedType")}tsParseTupleType(){const e=this.startNode();e.elementTypes=this.tsParseBracketedList("TupleElementTypes",this.tsParseTupleElementType.bind(this),!0,!1);let t=!1;return e.elementTypes.forEach(e=>{"TSOptionalType"===e.type?t=!0:t&&"TSRestType"!==e.type&&this.raise(e.start,"A required element cannot follow an optional element.")}),this.finishNode(e,"TSTupleType")}tsParseTupleElementType(){if(this.match(s.ellipsis)){const e=this.startNode();return this.next(),e.typeAnnotation=this.tsParseType(),this.match(s.comma)&&93!==this.lookaheadCharCode()&&this.raiseRestNotLast(this.state.start),this.finishNode(e,"TSRestType")}const e=this.tsParseType();if(this.eat(s.question)){const t=this.startNodeAtNode(e);return t.typeAnnotation=e,this.finishNode(t,"TSOptionalType")}return e}tsParseParenthesizedType(){const e=this.startNode();return this.expect(s.parenL),e.typeAnnotation=this.tsParseType(),this.expect(s.parenR),this.finishNode(e,"TSParenthesizedType")}tsParseFunctionOrConstructorType(e){const t=this.startNode();return"TSConstructorType"===e&&this.expect(s._new),this.tsFillSignature(s.arrow,t),this.finishNode(t,e)}tsParseLiteralTypeNode(){const e=this.startNode();return e.literal=(()=>{switch(this.state.type){case s.num:case s.string:case s._true:case s._false:return this.parseExprAtom();default:throw this.unexpected()}})(),this.finishNode(e,"TSLiteralType")}tsParseTemplateLiteralType(){const e=this.startNode(),t=this.parseTemplate(!1);return t.expressions.length>0&&this.raise(t.expressions[0].start,"Template literal types cannot have any substitution"),e.literal=t,this.finishNode(e,"TSLiteralType")}tsParseThisTypeOrThisTypePredicate(){const e=this.tsParseThisTypeNode();return this.isContextual("is")&&!this.hasPrecedingLineBreak()?this.tsParseThisTypePredicate(e):e}tsParseNonArrayType(){switch(this.state.type){case s.name:case s._void:case s._null:{const e=this.match(s._void)?"TSVoidKeyword":this.match(s._null)?"TSNullKeyword":function(e){switch(e){case"any":return"TSAnyKeyword";case"boolean":return"TSBooleanKeyword";case"bigint":return"TSBigIntKeyword";case"never":return"TSNeverKeyword";case"number":return"TSNumberKeyword";case"object":return"TSObjectKeyword";case"string":return"TSStringKeyword";case"symbol":return"TSSymbolKeyword";case"undefined":return"TSUndefinedKeyword";case"unknown":return"TSUnknownKeyword";default:return}}(this.state.value);if(void 0!==e&&46!==this.lookaheadCharCode()){const t=this.startNode();return this.next(),this.finishNode(t,e)}return this.tsParseTypeReference()}case s.string:case s.num:case s._true:case s._false:return this.tsParseLiteralTypeNode();case s.plusMin:if("-"===this.state.value){const e=this.startNode();if(this.lookahead().type!==s.num)throw this.unexpected();return e.literal=this.parseMaybeUnary(),this.finishNode(e,"TSLiteralType")}break;case s._this:return this.tsParseThisTypeOrThisTypePredicate();case s._typeof:return this.tsParseTypeQuery();case s._import:return this.tsParseImportType();case s.braceL:return this.tsLookAhead(this.tsIsStartOfMappedType.bind(this))?this.tsParseMappedType():this.tsParseTypeLiteral();case s.bracketL:return this.tsParseTupleType();case s.parenL:return this.tsParseParenthesizedType();case s.backQuote:return this.tsParseTemplateLiteralType()}throw this.unexpected()}tsParseArrayTypeOrHigher(){let e=this.tsParseNonArrayType();for(;!this.hasPrecedingLineBreak()&&this.eat(s.bracketL);)if(this.match(s.bracketR)){const t=this.startNodeAtNode(e);t.elementType=e,this.expect(s.bracketR),e=this.finishNode(t,"TSArrayType")}else{const t=this.startNodeAtNode(e);t.objectType=e,t.indexType=this.tsParseType(),this.expect(s.bracketR),e=this.finishNode(t,"TSIndexedAccessType")}return e}tsParseTypeOperator(e){const t=this.startNode();return this.expectContextual(e),t.operator=e,t.typeAnnotation=this.tsParseTypeOperatorOrHigher(),"readonly"===e&&this.tsCheckTypeAnnotationForReadOnly(t),this.finishNode(t,"TSTypeOperator")}tsCheckTypeAnnotationForReadOnly(e){switch(e.typeAnnotation.type){case"TSTupleType":case"TSArrayType":return;default:this.raise(e.start,"'readonly' type modifier is only permitted on array and tuple literal types.")}}tsParseInferType(){const e=this.startNode();this.expectContextual("infer");const t=this.startNode();return t.name=this.parseIdentifierName(t.start),e.typeParameter=this.finishNode(t,"TSTypeParameter"),this.finishNode(e,"TSInferType")}tsParseTypeOperatorOrHigher(){const e=["keyof","unique","readonly"].find(e=>this.isContextual(e));return e?this.tsParseTypeOperator(e):this.isContextual("infer")?this.tsParseInferType():this.tsParseArrayTypeOrHigher()}tsParseUnionOrIntersectionType(e,t,n){this.eat(n);let r=t();if(this.match(n)){const i=[r];for(;this.eat(n);)i.push(t());const o=this.startNodeAtNode(r);o.types=i,r=this.finishNode(o,e)}return r}tsParseIntersectionTypeOrHigher(){return this.tsParseUnionOrIntersectionType("TSIntersectionType",this.tsParseTypeOperatorOrHigher.bind(this),s.bitwiseAND)}tsParseUnionTypeOrHigher(){return this.tsParseUnionOrIntersectionType("TSUnionType",this.tsParseIntersectionTypeOrHigher.bind(this),s.bitwiseOR)}tsIsStartOfFunctionType(){return!!this.isRelational("<")||this.match(s.parenL)&&this.tsLookAhead(this.tsIsUnambiguouslyStartOfFunctionType.bind(this))}tsSkipParameterStart(){if(this.match(s.name)||this.match(s._this))return this.next(),!0;if(this.match(s.braceL)){let e=1;for(this.next();e>0;)this.match(s.braceL)?++e:this.match(s.braceR)&&--e,this.next();return!0}if(this.match(s.bracketL)){let e=1;for(this.next();e>0;)this.match(s.bracketL)?++e:this.match(s.bracketR)&&--e,this.next();return!0}return!1}tsIsUnambiguouslyStartOfFunctionType(){if(this.next(),this.match(s.parenR)||this.match(s.ellipsis))return!0;if(this.tsSkipParameterStart()){if(this.match(s.colon)||this.match(s.comma)||this.match(s.question)||this.match(s.eq))return!0;if(this.match(s.parenR)&&(this.next(),this.match(s.arrow)))return!0}return!1}tsParseTypeOrTypePredicateAnnotation(e){return this.tsInType(()=>{const t=this.startNode();this.expect(e);const n=this.tsTryParse(this.tsParseTypePredicateAsserts.bind(this));if(n&&this.match(s._this)){let e=this.tsParseThisTypeOrThisTypePredicate();if("TSThisType"===e.type){const n=this.startNodeAtNode(t);n.parameterName=e,n.asserts=!0,e=this.finishNode(n,"TSTypePredicate")}else e.asserts=!0;return t.typeAnnotation=e,this.finishNode(t,"TSTypeAnnotation")}const r=this.tsIsIdentifier()&&this.tsTryParse(this.tsParseTypePredicatePrefix.bind(this));if(!r){if(!n)return this.tsParseTypeAnnotation(!1,t);const e=this.startNodeAtNode(t);return e.parameterName=this.parseIdentifier(),e.asserts=n,t.typeAnnotation=this.finishNode(e,"TSTypePredicate"),this.finishNode(t,"TSTypeAnnotation")}const i=this.tsParseTypeAnnotation(!1),o=this.startNodeAtNode(t);return o.parameterName=r,o.typeAnnotation=i,o.asserts=n,t.typeAnnotation=this.finishNode(o,"TSTypePredicate"),this.finishNode(t,"TSTypeAnnotation")})}tsTryParseTypeOrTypePredicateAnnotation(){return this.match(s.colon)?this.tsParseTypeOrTypePredicateAnnotation(s.colon):void 0}tsTryParseTypeAnnotation(){return this.match(s.colon)?this.tsParseTypeAnnotation():void 0}tsTryParseType(){return this.tsEatThenParseType(s.colon)}tsParseTypePredicatePrefix(){const e=this.parseIdentifier();if(this.isContextual("is")&&!this.hasPrecedingLineBreak())return this.next(),e}tsParseTypePredicateAsserts(){if(!this.match(s.name)||"asserts"!==this.state.value||this.hasPrecedingLineBreak())return!1;const e=this.state.containsEsc;return this.next(),!(!this.match(s.name)&&!this.match(s._this))&&(e&&this.raise(this.state.lastTokStart,"Escape sequence in keyword asserts"),!0)}tsParseTypeAnnotation(e=!0,t=this.startNode()){return this.tsInType(()=>{e&&this.expect(s.colon),t.typeAnnotation=this.tsParseType()}),this.finishNode(t,"TSTypeAnnotation")}tsParseType(){K(this.state.inType);const e=this.tsParseNonConditionalType();if(this.hasPrecedingLineBreak()||!this.eat(s._extends))return e;const t=this.startNodeAtNode(e);return t.checkType=e,t.extendsType=this.tsParseNonConditionalType(),this.expect(s.question),t.trueType=this.tsParseType(),this.expect(s.colon),t.falseType=this.tsParseType(),this.finishNode(t,"TSConditionalType")}tsParseNonConditionalType(){return this.tsIsStartOfFunctionType()?this.tsParseFunctionOrConstructorType("TSFunctionType"):this.match(s._new)?this.tsParseFunctionOrConstructorType("TSConstructorType"):this.tsParseUnionTypeOrHigher()}tsParseTypeAssertion(){const e=this.startNode(),t=this.tsTryNextParseConstantContext();return e.typeAnnotation=t||this.tsNextThenParseType(),this.expectRelational(">"),e.expression=this.parseMaybeUnary(),this.finishNode(e,"TSTypeAssertion")}tsParseHeritageClause(e){const t=this.state.start,n=this.tsParseDelimitedList("HeritageClauseElement",this.tsParseExpressionWithTypeArguments.bind(this));return n.length||this.raise(t,`'${e}' list cannot be empty.`),n}tsParseExpressionWithTypeArguments(){const e=this.startNode();return e.expression=this.tsParseEntityName(!1),this.isRelational("<")&&(e.typeParameters=this.tsParseTypeArguments()),this.finishNode(e,"TSExpressionWithTypeArguments")}tsParseInterfaceDeclaration(e){e.id=this.parseIdentifier(),this.checkLVal(e.id,130,void 0,"typescript interface declaration"),e.typeParameters=this.tsTryParseTypeParameters(),this.eat(s._extends)&&(e.extends=this.tsParseHeritageClause("extends"));const t=this.startNode();return t.body=this.tsInType(this.tsParseObjectTypeMembers.bind(this)),e.body=this.finishNode(t,"TSInterfaceBody"),this.finishNode(e,"TSInterfaceDeclaration")}tsParseTypeAliasDeclaration(e){return e.id=this.parseIdentifier(),this.checkLVal(e.id,2,void 0,"typescript type alias"),e.typeParameters=this.tsTryParseTypeParameters(),e.typeAnnotation=this.tsExpectThenParseType(s.eq),this.semicolon(),this.finishNode(e,"TSTypeAliasDeclaration")}tsInNoContext(e){const t=this.state.context;this.state.context=[t[0]];try{return e()}finally{this.state.context=t}}tsInType(e){const t=this.state.inType;this.state.inType=!0;try{return e()}finally{this.state.inType=t}}tsEatThenParseType(e){return this.match(e)?this.tsNextThenParseType():void 0}tsExpectThenParseType(e){return this.tsDoThenParseType(()=>this.expect(e))}tsNextThenParseType(){return this.tsDoThenParseType(()=>this.next())}tsDoThenParseType(e){return this.tsInType(()=>(e(),this.tsParseType()))}tsParseEnumMember(){const e=this.startNode();return e.id=this.match(s.string)?this.parseExprAtom():this.parseIdentifier(!0),this.eat(s.eq)&&(e.initializer=this.parseMaybeAssign()),this.finishNode(e,"TSEnumMember")}tsParseEnumDeclaration(e,t){return t&&(e.const=!0),e.id=this.parseIdentifier(),this.checkLVal(e.id,t?779:267,void 0,"typescript enum declaration"),this.expect(s.braceL),e.members=this.tsParseDelimitedList("EnumMembers",this.tsParseEnumMember.bind(this)),this.expect(s.braceR),this.finishNode(e,"TSEnumDeclaration")}tsParseModuleBlock(){const e=this.startNode();return this.scope.enter(0),this.expect(s.braceL),this.parseBlockOrModuleBlockBody(e.body=[],void 0,!0,s.braceR),this.scope.exit(),this.finishNode(e,"TSModuleBlock")}tsParseModuleOrNamespaceDeclaration(e,t=!1){if(e.id=this.parseIdentifier(),t||this.checkLVal(e.id,1024,null,"module or namespace declaration"),this.eat(s.dot)){const t=this.startNode();this.tsParseModuleOrNamespaceDeclaration(t,!0),e.body=t}else this.scope.enter(512),e.body=this.tsParseModuleBlock(),this.scope.exit();return this.finishNode(e,"TSModuleDeclaration")}tsParseAmbientExternalModuleDeclaration(e){return this.isContextual("global")?(e.global=!0,e.id=this.parseIdentifier()):this.match(s.string)?e.id=this.parseExprAtom():this.unexpected(),this.match(s.braceL)?(this.scope.enter(512),e.body=this.tsParseModuleBlock(),this.scope.exit()):this.semicolon(),this.finishNode(e,"TSModuleDeclaration")}tsParseImportEqualsDeclaration(e,t){return e.isExport=t||!1,e.id=this.parseIdentifier(),this.checkLVal(e.id,9,void 0,"import equals declaration"),this.expect(s.eq),e.moduleReference=this.tsParseModuleReference(),this.semicolon(),this.finishNode(e,"TSImportEqualsDeclaration")}tsIsExternalModuleReference(){return this.isContextual("require")&&40===this.lookaheadCharCode()}tsParseModuleReference(){return this.tsIsExternalModuleReference()?this.tsParseExternalModuleReference():this.tsParseEntityName(!1)}tsParseExternalModuleReference(){const e=this.startNode();if(this.expectContextual("require"),this.expect(s.parenL),!this.match(s.string))throw this.unexpected();return e.expression=this.parseExprAtom(),this.expect(s.parenR),this.finishNode(e,"TSExternalModuleReference")}tsLookAhead(e){const t=this.state.clone(),n=e();return this.state=t,n}tsTryParseAndCatch(e){const t=this.tryParse(t=>e()||t());if(!t.aborted&&t.node)return t.error&&(this.state=t.failState),t.node}tsTryParse(e){const t=this.state.clone(),n=e();return void 0!==n&&!1!==n?n:void(this.state=t)}tsTryParseDeclare(e){if(this.isLineTerminator())return;let t,n=this.state.type;switch(this.isContextual("let")&&(n=s._var,t="let"),n){case s._function:return this.parseFunctionStatement(e,!1,!0);case s._class:return e.declare=!0,this.parseClass(e,!0,!1);case s._const:if(this.match(s._const)&&this.isLookaheadContextual("enum"))return this.expect(s._const),this.expectContextual("enum"),this.tsParseEnumDeclaration(e,!0);case s._var:return t=t||this.state.value,this.parseVarStatement(e,t);case s.name:{const t=this.state.value;return"global"===t?this.tsParseAmbientExternalModuleDeclaration(e):this.tsParseDeclaration(e,t,!0)}}}tsTryParseExportDeclaration(){return this.tsParseDeclaration(this.startNode(),this.state.value,!0)}tsParseExpressionStatement(e,t){switch(t.name){case"declare":{const t=this.tsTryParseDeclare(e);if(t)return t.declare=!0,t;break}case"global":if(this.match(s.braceL)){this.scope.enter(512);const n=e;return n.global=!0,n.id=t,n.body=this.tsParseModuleBlock(),this.scope.exit(),this.finishNode(n,"TSModuleDeclaration")}break;default:return this.tsParseDeclaration(e,t.name,!1)}}tsParseDeclaration(e,t,n){switch(t){case"abstract":if(this.tsCheckLineTerminatorAndMatch(s._class,n)){const t=e;return t.abstract=!0,n&&(this.next(),this.match(s._class)||this.unexpected(null,s._class)),this.parseClass(t,!0,!1)}break;case"enum":if(n||this.match(s.name))return n&&this.next(),this.tsParseEnumDeclaration(e,!1);break;case"interface":if(this.tsCheckLineTerminatorAndMatch(s.name,n))return n&&this.next(),this.tsParseInterfaceDeclaration(e);break;case"module":if(n&&this.next(),this.match(s.string))return this.tsParseAmbientExternalModuleDeclaration(e);if(this.tsCheckLineTerminatorAndMatch(s.name,n))return this.tsParseModuleOrNamespaceDeclaration(e);break;case"namespace":if(this.tsCheckLineTerminatorAndMatch(s.name,n))return n&&this.next(),this.tsParseModuleOrNamespaceDeclaration(e);break;case"type":if(this.tsCheckLineTerminatorAndMatch(s.name,n))return n&&this.next(),this.tsParseTypeAliasDeclaration(e)}}tsCheckLineTerminatorAndMatch(e,t){return(t||this.match(e))&&!this.isLineTerminator()}tsTryParseGenericAsyncArrowFunction(e,t){if(!this.isRelational("<"))return;const n=this.tsTryParseAndCatch(()=>{const n=this.startNodeAt(e,t);return n.typeParameters=this.tsParseTypeParameters(),super.parseFunctionParams(n),n.returnType=this.tsTryParseTypeOrTypePredicateAnnotation(),this.expect(s.arrow),n});return n?this.parseArrowExpression(n,null,!0):void 0}tsParseTypeArguments(){const e=this.startNode();return e.params=this.tsInType(()=>this.tsInNoContext(()=>(this.expectRelational("<"),this.tsParseDelimitedList("TypeParametersOrArguments",this.tsParseType.bind(this))))),this.state.exprAllowed=!1,this.expectRelational(">"),this.finishNode(e,"TSTypeParameterInstantiation")}tsIsDeclarationStart(){if(this.match(s.name))switch(this.state.value){case"abstract":case"declare":case"enum":case"interface":case"module":case"namespace":case"type":return!0}return!1}isExportDefaultSpecifier(){return!this.tsIsDeclarationStart()&&super.isExportDefaultSpecifier()}parseAssignableListItem(e,t){const n=this.state.start,r=this.state.startLoc;let i,o=!1;e&&(i=this.parseAccessModifier(),o=!!this.tsParseModifier(["readonly"]));const a=this.parseMaybeDefault();this.parseAssignableListItemTypes(a);const s=this.parseMaybeDefault(a.start,a.loc.start,a);if(i||o){const e=this.startNodeAt(n,r);return t.length&&(e.decorators=t),i&&(e.accessibility=i),o&&(e.readonly=o),"Identifier"!==s.type&&"AssignmentPattern"!==s.type&&this.raise(e.start,"A parameter property may not be declared using a binding pattern."),e.parameter=s,this.finishNode(e,"TSParameterProperty")}return t.length&&(a.decorators=t),s}parseFunctionBodyAndFinish(e,t,n=!1){this.match(s.colon)&&(e.returnType=this.tsParseTypeOrTypePredicateAnnotation(s.colon));const r="FunctionDeclaration"===t?"TSDeclareFunction":"ClassMethod"===t?"TSDeclareMethod":void 0;r&&!this.match(s.braceL)&&this.isLineTerminator()?this.finishNode(e,r):super.parseFunctionBodyAndFinish(e,t,n)}registerFunctionStatementId(e){!e.body&&e.id?this.checkLVal(e.id,1024,null,"function name"):super.registerFunctionStatementId(...arguments)}parseSubscript(e,t,n,r,i){if(!this.hasPrecedingLineBreak()&&this.match(s.bang)){this.state.exprAllowed=!1,this.next();const r=this.startNodeAt(t,n);return r.expression=e,this.finishNode(r,"TSNonNullExpression")}if(this.isRelational("<")){const o=this.tsTryParseAndCatch(()=>{if(!r&&this.atPossibleAsync(e)){const e=this.tsTryParseGenericAsyncArrowFunction(t,n);if(e)return e}const o=this.startNodeAt(t,n);o.callee=e;const a=this.tsParseTypeArguments();if(a){if(!r&&this.eat(s.parenL))return o.arguments=this.parseCallExpressionArguments(s.parenR,!1),o.typeParameters=a,this.finishCallExpression(o,i.optionalChainMember);if(this.match(s.backQuote))return this.parseTaggedTemplateExpression(t,n,e,i,a)}this.unexpected()});if(o)return o}return super.parseSubscript(e,t,n,r,i)}parseNewArguments(e){if(this.isRelational("<")){const t=this.tsTryParseAndCatch(()=>{const e=this.tsParseTypeArguments();return this.match(s.parenL)||this.unexpected(),e});t&&(e.typeParameters=t)}super.parseNewArguments(e)}parseExprOp(e,t,n,r,i){if(W(s._in.binop)>r&&!this.hasPrecedingLineBreak()&&this.isContextual("as")){const o=this.startNodeAt(t,n);o.expression=e;const a=this.tsTryNextParseConstantContext();return o.typeAnnotation=a||this.tsNextThenParseType(),this.finishNode(o,"TSAsExpression"),this.parseExprOp(o,t,n,r,i)}return super.parseExprOp(e,t,n,r,i)}checkReservedWord(e,t,n,r){}checkDuplicateExports(){}parseImport(e){return this.match(s.name)&&this.lookahead().type===s.eq?this.tsParseImportEqualsDeclaration(e):super.parseImport(e)}parseExport(e){if(this.match(s._import))return this.expect(s._import),this.tsParseImportEqualsDeclaration(e,!0);if(this.eat(s.eq)){const t=e;return t.expression=this.parseExpression(),this.semicolon(),this.finishNode(t,"TSExportAssignment")}if(this.eatContextual("as")){const t=e;return this.expectContextual("namespace"),t.id=this.parseIdentifier(),this.semicolon(),this.finishNode(t,"TSNamespaceExportDeclaration")}return super.parseExport(e)}isAbstractClass(){return this.isContextual("abstract")&&this.lookahead().type===s._class}parseExportDefaultExpression(){if(this.isAbstractClass()){const e=this.startNode();return this.next(),this.parseClass(e,!0,!0),e.abstract=!0,e}if("interface"===this.state.value){const e=this.tsParseDeclaration(this.startNode(),this.state.value,!0);if(e)return e}return super.parseExportDefaultExpression()}parseStatementContent(e,t){if(this.state.type===s._const){const e=this.lookahead();if(e.type===s.name&&"enum"===e.value){const e=this.startNode();return this.expect(s._const),this.expectContextual("enum"),this.tsParseEnumDeclaration(e,!0)}}return super.parseStatementContent(e,t)}parseAccessModifier(){return this.tsParseModifier(["public","protected","private"])}parseClassMember(e,t,n,r){const i=this.parseAccessModifier();i&&(t.accessibility=i),super.parseClassMember(e,t,n,r)}parseClassMemberWithIsStatic(e,t,n,r,i){const o=this.tsParseModifiers(["abstract","readonly","declare"]);Object.assign(t,o);const a=this.tsTryParseIndexSignature(t);if(a)return e.body.push(a),o.abstract&&this.raise(t.start,"Index signatures cannot have the 'abstract' modifier"),r&&this.raise(t.start,"Index signatures cannot have the 'static' modifier"),void(t.accessibility&&this.raise(t.start,`Index signatures cannot have an accessibility modifier ('${t.accessibility}')`));super.parseClassMemberWithIsStatic(e,t,n,r,i)}parsePostMemberNameModifiers(e){this.eat(s.question)&&(e.optional=!0),e.readonly&&this.match(s.parenL)&&this.raise(e.start,"Class methods cannot have the 'readonly' modifier"),e.declare&&this.match(s.parenL)&&this.raise(e.start,"Class methods cannot have the 'declare' modifier")}parseExpressionStatement(e,t){return("Identifier"===t.type?this.tsParseExpressionStatement(e,t):void 0)||super.parseExpressionStatement(e,t)}shouldParseExportDeclaration(){return!!this.tsIsDeclarationStart()||super.shouldParseExportDeclaration()}parseConditional(e,t,n,r,i){if(!i||!this.match(s.question))return super.parseConditional(e,t,n,r,i);const o=this.tryParse(()=>super.parseConditional(e,t,n,r));return o.node?(o.error&&(this.state=o.failState),o.node):(i.start=o.error.pos||this.state.start,e)}parseParenItem(e,t,n){if(e=super.parseParenItem(e,t,n),this.eat(s.question)&&(e.optional=!0,this.resetEndLocation(e)),this.match(s.colon)){const r=this.startNodeAt(t,n);return r.expression=e,r.typeAnnotation=this.tsParseTypeAnnotation(),this.finishNode(r,"TSTypeCastExpression")}return e}parseExportDeclaration(e){const t=this.state.start,n=this.state.startLoc,r=this.eatContextual("declare");let i;return this.match(s.name)&&(i=this.tsTryParseExportDeclaration()),i||(i=super.parseExportDeclaration(e)),i&&r&&(this.resetStartLocation(i,t,n),i.declare=!0),i}parseClassId(e,t,n){if((!t||n)&&this.isContextual("implements"))return;super.parseClassId(e,t,n,e.declare?1024:139);const r=this.tsTryParseTypeParameters();r&&(e.typeParameters=r)}parseClassPropertyAnnotation(e){!e.optional&&this.eat(s.bang)&&(e.definite=!0);const t=this.tsTryParseTypeAnnotation();t&&(e.typeAnnotation=t)}parseClassProperty(e){return this.parseClassPropertyAnnotation(e),e.declare&&this.match(s.equal)&&this.raise(this.state.start,"'declare' class fields cannot have an initializer"),super.parseClassProperty(e)}parseClassPrivateProperty(e){return e.abstract&&this.raise(e.start,"Private elements cannot have the 'abstract' modifier."),e.accessibility&&this.raise(e.start,`Private elements cannot have an accessibility modifier ('${e.accessibility}')`),this.parseClassPropertyAnnotation(e),super.parseClassPrivateProperty(e)}pushClassMethod(e,t,n,r,i,o){const a=this.tsTryParseTypeParameters();a&&(t.typeParameters=a),super.pushClassMethod(e,t,n,r,i,o)}pushClassPrivateMethod(e,t,n,r){const i=this.tsTryParseTypeParameters();i&&(t.typeParameters=i),super.pushClassPrivateMethod(e,t,n,r)}parseClassSuper(e){super.parseClassSuper(e),e.superClass&&this.isRelational("<")&&(e.superTypeParameters=this.tsParseTypeArguments()),this.eatContextual("implements")&&(e.implements=this.tsParseHeritageClause("implements"))}parseObjPropValue(e,...t){const n=this.tsTryParseTypeParameters();n&&(e.typeParameters=n),super.parseObjPropValue(e,...t)}parseFunctionParams(e,t){const n=this.tsTryParseTypeParameters();n&&(e.typeParameters=n),super.parseFunctionParams(e,t)}parseVarId(e,t){super.parseVarId(e,t),"Identifier"===e.id.type&&this.eat(s.bang)&&(e.definite=!0);const n=this.tsTryParseTypeAnnotation();n&&(e.id.typeAnnotation=n,this.resetEndLocation(e.id))}parseAsyncArrowFromCallExpression(e,t){return this.match(s.colon)&&(e.returnType=this.tsParseTypeAnnotation()),super.parseAsyncArrowFromCallExpression(e,t)}parseMaybeAssign(...e){let t,n,r,i;if(this.match(s.jsxTagStart)){if(t=this.state.clone(),n=this.tryParse(()=>super.parseMaybeAssign(...e),t),!n.error)return n.node;const{context:r}=this.state;r[r.length-1]===m.j_oTag?r.length-=2:r[r.length-1]===m.j_expr&&(r.length-=1)}if(!(n&&n.error||this.isRelational("<")))return super.parseMaybeAssign(...e);t=t||this.state.clone();const o=this.tryParse(t=>{i=this.tsParseTypeParameters();const n=super.parseMaybeAssign(...e);return("ArrowFunctionExpression"!==n.type||n.extra&&n.extra.parenthesized)&&t(),i&&0!==i.params.length&&this.resetStartLocationFromNode(n,i),n.typeParameters=i,n},t);if(!o.error&&!o.aborted)return o.node;if(!n&&(K(!this.hasPlugin("jsx")),r=this.tryParse(()=>super.parseMaybeAssign(...e),t),!r.error))return r.node;if(n&&n.node)return this.state=n.failState,n.node;if(o.node)return this.state=o.failState,o.node;if(r&&r.node)return this.state=r.failState,r.node;if(n&&n.thrown)throw n.error;if(o.thrown)throw o.error;if(r&&r.thrown)throw r.error;throw n&&n.error||o.error||r&&r.error}parseMaybeUnary(e){return!this.hasPlugin("jsx")&&this.isRelational("<")?this.tsParseTypeAssertion():super.parseMaybeUnary(e)}parseArrow(e){if(this.match(s.colon)){const t=this.tryParse(e=>{const t=this.tsParseTypeOrTypePredicateAnnotation(s.colon);return!this.canInsertSemicolon()&&this.match(s.arrow)||e(),t});if(t.aborted)return;t.thrown||(t.error&&(this.state=t.failState),e.returnType=t.node)}return super.parseArrow(e)}parseAssignableListItemTypes(e){this.eat(s.question)&&("Identifier"!==e.type&&this.raise(e.start,"A binding pattern parameter cannot be optional in an implementation signature."),e.optional=!0);const t=this.tsTryParseTypeAnnotation();return t&&(e.typeAnnotation=t),this.resetEndLocation(e),e}toAssignable(e,t,n){switch(e.type){case"TSTypeCastExpression":return super.toAssignable(this.typeCastToParameter(e),t,n);case"TSParameterProperty":return super.toAssignable(e,t,n);case"TSAsExpression":case"TSNonNullExpression":case"TSTypeAssertion":return e.expression=this.toAssignable(e.expression,t,n),e;default:return super.toAssignable(e,t,n)}}checkLVal(e,t=64,n,r){switch(e.type){case"TSTypeCastExpression":return;case"TSParameterProperty":return void this.checkLVal(e.parameter,t,n,"parameter property");case"TSAsExpression":case"TSNonNullExpression":case"TSTypeAssertion":return void this.checkLVal(e.expression,t,n,r);default:return void super.checkLVal(e,t,n,r)}}parseBindingAtom(){switch(this.state.type){case s._this:return this.parseIdentifier(!0);default:return super.parseBindingAtom()}}parseMaybeDecoratorArguments(e){if(this.isRelational("<")){const t=this.tsParseTypeArguments();if(this.match(s.parenL)){const n=super.parseMaybeDecoratorArguments(e);return n.typeParameters=t,n}this.unexpected(this.state.start,s.parenL)}return super.parseMaybeDecoratorArguments(e)}isClassMethod(){return this.isRelational("<")||super.isClassMethod()}isClassProperty(){return this.match(s.bang)||this.match(s.colon)||super.isClassProperty()}parseMaybeDefault(...e){const t=super.parseMaybeDefault(...e);return"AssignmentPattern"===t.type&&t.typeAnnotation&&t.right.startthis.tsParseTypeArguments());t&&(e.typeParameters=t)}return super.jsxParseOpeningElementAfterName(e)}getGetterSetterExpectedParamCount(e){const t=super.getGetterSetterExpectedParamCount(e),n=e.params[0];return n&&"Identifier"===n.type&&"this"===n.name?t+1:t}},v8intrinsic:e=>class extends e{parseV8Intrinsic(){if(this.match(s.modulo)){const e=this.state.start,t=this.startNode();if(this.eat(s.modulo),this.match(s.name)){const e=this.parseIdentifierName(this.state.start),n=this.createIdentifier(t,e);if(n.type="V8IntrinsicIdentifier",this.match(s.parenL))return n}this.unexpected(e)}}parseExprAtom(){return this.parseV8Intrinsic()||super.parseExprAtom(...arguments)}},placeholders:e=>class extends e{parsePlaceholder(e){if(this.match(s.placeholder)){const t=this.startNode();return this.next(),this.assertNoSpace("Unexpected space in placeholder."),t.name=super.parseIdentifier(!0),this.assertNoSpace("Unexpected space in placeholder."),this.expect(s.placeholder),this.finishPlaceholder(t,e)}}finishPlaceholder(e,t){const n=!(!e.expectedNode||"Placeholder"!==e.type);return e.expectedNode=t,n?e:this.finishNode(e,"Placeholder")}getTokenFromCode(e){return 37===e&&37===this.input.charCodeAt(this.state.pos+1)?this.finishOp(s.placeholder,2):super.getTokenFromCode(...arguments)}parseExprAtom(){return this.parsePlaceholder("Expression")||super.parseExprAtom(...arguments)}parseIdentifier(){return this.parsePlaceholder("Identifier")||super.parseIdentifier(...arguments)}checkReservedWord(e){void 0!==e&&super.checkReservedWord(...arguments)}parseBindingAtom(){return this.parsePlaceholder("Pattern")||super.parseBindingAtom(...arguments)}checkLVal(e){"Placeholder"!==e.type&&super.checkLVal(...arguments)}toAssignable(e){return e&&"Placeholder"===e.type&&"Expression"===e.expectedNode?(e.expectedNode="Pattern",e):super.toAssignable(...arguments)}verifyBreakContinue(e){e.label&&"Placeholder"===e.label.type||super.verifyBreakContinue(...arguments)}parseExpressionStatement(e,t){if("Placeholder"!==t.type||t.extra&&t.extra.parenthesized)return super.parseExpressionStatement(...arguments);if(this.match(s.colon)){const n=e;return n.label=this.finishPlaceholder(t,"Identifier"),this.next(),n.body=this.parseStatement("label"),this.finishNode(n,"LabeledStatement")}return this.semicolon(),e.name=t.name,this.finishPlaceholder(e,"Statement")}parseBlock(){return this.parsePlaceholder("BlockStatement")||super.parseBlock(...arguments)}parseFunctionId(){return this.parsePlaceholder("Identifier")||super.parseFunctionId(...arguments)}parseClass(e,t,n){const r=t?"ClassDeclaration":"ClassExpression";this.next(),this.takeDecorators(e);const i=this.parsePlaceholder("Identifier");if(i)if(this.match(s._extends)||this.match(s.placeholder)||this.match(s.braceL))e.id=i;else{if(n||!t)return e.id=null,e.body=this.finishPlaceholder(i,"ClassBody"),this.finishNode(e,r);this.unexpected(null,"A class name is required")}else this.parseClassId(e,t,n);return this.parseClassSuper(e),e.body=this.parsePlaceholder("ClassBody")||this.parseClassBody(!!e.superClass),this.finishNode(e,r)}parseExport(e){const t=this.parsePlaceholder("Identifier");if(!t)return super.parseExport(...arguments);if(!this.isContextual("from")&&!this.match(s.comma))return e.specifiers=[],e.source=null,e.declaration=this.finishPlaceholder(t,"Declaration"),this.finishNode(e,"ExportNamedDeclaration");this.expectPlugin("exportDefaultFrom");const n=this.startNode();return n.exported=t,e.specifiers=[this.finishNode(n,"ExportDefaultSpecifier")],super.parseExport(e)}maybeParseExportDefaultSpecifier(e){return!!(e.specifiers&&e.specifiers.length>0)||super.maybeParseExportDefaultSpecifier(...arguments)}checkExport(e){const{specifiers:t}=e;t&&t.length&&(e.specifiers=t.filter(e=>"Placeholder"===e.exported.type)),super.checkExport(e),e.specifiers=t}parseImport(e){const t=this.parsePlaceholder("Identifier");if(!t)return super.parseImport(...arguments);if(e.specifiers=[],!this.isContextual("from")&&!this.match(s.comma))return e.source=this.finishPlaceholder(t,"StringLiteral"),this.semicolon(),this.finishNode(e,"ImportDeclaration");const n=this.startNodeAtNode(t);if(n.local=t,this.finishNode(n,"ImportDefaultSpecifier"),e.specifiers.push(n),this.eat(s.comma)){this.maybeParseStarImportSpecifier(e)||this.parseNamedImportSpecifiers(e)}return this.expectContextual("from"),e.source=this.parseImportSource(),this.semicolon(),this.finishNode(e,"ImportDeclaration")}parseImportSource(){return this.parsePlaceholder("StringLiteral")||super.parseImportSource(...arguments)}}},ee=Object.keys(Q),te={sourceType:"script",sourceFilename:void 0,startLine:1,allowAwaitOutsideFunction:!1,allowReturnOutsideFunction:!1,allowImportExportEverywhere:!1,allowSuperOutsideMethod:!1,allowUndeclaredExports:!1,plugins:[],strictMode:null,ranges:!1,tokens:!1,createParenthesizedExpressions:!1,errorRecovery:!1};class ne{constructor(e,t){this.line=e,this.column=t}}class re{constructor(e,t){this.start=e,this.end=t}}function ie(e){return e[e.length-1]}class oe{constructor(){this.errors=[],this.potentialArrowAt=-1,this.noArrowAt=[],this.noArrowParamsConversionAt=[],this.inParameters=!1,this.maybeInArrowParameters=!1,this.inPipeline=!1,this.inType=!1,this.noAnonFunctionType=!1,this.inPropertyName=!1,this.inClassProperty=!1,this.hasFlowComment=!1,this.isIterator=!1,this.topicContext={maxNumOfResolvableTopics:0,maxTopicIndex:null},this.soloAwait=!1,this.inFSharpPipelineDirectBody=!1,this.classLevel=0,this.labels=[],this.decoratorStack=[[]],this.yieldPos=-1,this.awaitPos=-1,this.tokens=[],this.comments=[],this.trailingComments=[],this.leadingComments=[],this.commentStack=[],this.commentPreviousNode=null,this.pos=0,this.lineStart=0,this.type=s.eof,this.value=null,this.start=0,this.end=0,this.lastTokEndLoc=null,this.lastTokStartLoc=null,this.lastTokStart=0,this.lastTokEnd=0,this.context=[m.braceStatement],this.exprAllowed=!0,this.containsEsc=!1,this.containsOctal=!1,this.octalPosition=null,this.exportedIdentifiers=[],this.invalidTemplateEscapePosition=null}init(e){this.strict=!1!==e.strictMode&&"module"===e.sourceType,this.curLine=e.startLine,this.startLoc=this.endLoc=this.curPosition()}curPosition(){return new ne(this.curLine,this.pos-this.lineStart)}clone(e){const t=new oe,n=Object.keys(this);for(let r=0,i=n.length;r=48&&e<=57};const se=new Set(["g","m","s","i","y","u"]),ue={decBinOct:[46,66,69,79,95,98,101,111],hex:[46,88,95,120]},ce={bin:[48,49]};ce.oct=[...ce.bin,50,51,52,53,54,55],ce.dec=[...ce.oct,56,57],ce.hex=[...ce.dec,65,66,67,68,69,70,97,98,99,100,101,102];class le{constructor(e){this.type=e.type,this.value=e.value,this.start=e.start,this.end=e.end,this.loc=new re(e.startLoc,e.endLoc)}}const fe=/^('|")((?:\\?.)*?)\1/;class pe{constructor(e,t,n){this.type="",this.start=t,this.end=0,this.loc=new re(n),e&&e.options.ranges&&(this.range=[t,0]),e&&e.filename&&(this.loc.filename=e.filename)}__clone(){const e=new pe,t=Object.keys(this);for(let n=0,r=t.length;n"ParenthesizedExpression"===e.type?he(e.expression):e;const de={kind:"loop"},ye={kind:"switch"};class me extends class extends class extends class extends class extends class extends class extends class extends class extends class{constructor(){this.sawUnambiguousESM=!1,this.ambiguousScriptDifferentAst=!1}hasPlugin(e){return this.plugins.has(e)}getPluginOption(e,t){if(this.hasPlugin(e))return this.plugins.get(e)[t]}}{addComment(e){this.filename&&(e.loc.filename=this.filename),this.state.trailingComments.push(e),this.state.leadingComments.push(e)}adjustCommentsAfterTrailingComma(e,t,n){if(0===this.state.leadingComments.length)return;let r=null,i=t.length;for(;null===r&&i>0;)r=t[--i];if(null===r)return;for(let e=0;e0?r.trailingComments=o:void 0!==r.trailingComments&&(r.trailingComments=[])}processComment(e){if("Program"===e.type&&e.body.length>0)return;const t=this.state.commentStack;let n,r,i,o,a;if(this.state.trailingComments.length>0)this.state.trailingComments[0].start>=e.end?(i=this.state.trailingComments,this.state.trailingComments=[]):this.state.trailingComments.length=0;else if(t.length>0){const n=ie(t);n.trailingComments&&n.trailingComments[0].start>=e.end&&(i=n.trailingComments,delete n.trailingComments)}for(t.length>0&&ie(t).start>=e.start&&(n=t.pop());t.length>0&&ie(t).start>=e.start;)r=t.pop();if(!r&&n&&(r=n),n)switch(e.type){case"ObjectExpression":this.adjustCommentsAfterTrailingComma(e,e.properties);break;case"ObjectPattern":this.adjustCommentsAfterTrailingComma(e,e.properties,!0);break;case"CallExpression":this.adjustCommentsAfterTrailingComma(e,e.arguments);break;case"ArrayExpression":this.adjustCommentsAfterTrailingComma(e,e.elements);break;case"ArrayPattern":this.adjustCommentsAfterTrailingComma(e,e.elements,!0)}else this.state.commentPreviousNode&&("ImportSpecifier"===this.state.commentPreviousNode.type&&"ImportSpecifier"!==e.type||"ExportSpecifier"===this.state.commentPreviousNode.type&&"ExportSpecifier"!==e.type)&&this.adjustCommentsAfterTrailingComma(e,[this.state.commentPreviousNode],!0);if(r){if(r.leadingComments)if(r!==e&&r.leadingComments.length>0&&ie(r.leadingComments).end<=e.start)e.leadingComments=r.leadingComments,delete r.leadingComments;else for(o=r.leadingComments.length-2;o>=0;--o)if(r.leadingComments[o].end<=e.start){e.leadingComments=r.leadingComments.splice(0,o+1);break}}else if(this.state.leadingComments.length>0)if(ie(this.state.leadingComments).end<=e.start){if(this.state.commentPreviousNode)for(a=0;a0&&(e.leadingComments=this.state.leadingComments,this.state.leadingComments=[])}else{for(o=0;oe.start);o++);const t=this.state.leadingComments.slice(0,o);t.length&&(e.leadingComments=t),i=this.state.leadingComments.slice(o),0===i.length&&(i=null)}this.state.commentPreviousNode=e,i&&(i.length&&i[0].start>=e.start&&ie(i).end<=e.end?e.innerComments=i:e.trailingComments=i),t.push(e)}}{getLocationForPosition(e){let t;return t=e===this.state.start?this.state.startLoc:e===this.state.lastTokStart?this.state.lastTokStartLoc:e===this.state.end?this.state.endLoc:e===this.state.lastTokEnd?this.state.lastTokEndLoc:function(e,t){let n,r=1,i=0;for(f.lastIndex=0;(n=f.exec(e))&&n.index=this.length?this.finishToken(s.eof):e.override?e.override(this):this.getTokenFromCode(this.input.codePointAt(this.state.pos))}pushComment(e,t,n,r,i,o){const a={type:e?"CommentBlock":"CommentLine",value:t,start:n,end:r,loc:new re(i,o)};this.options.tokens&&this.state.tokens.push(a),this.state.comments.push(a),this.addComment(a)}skipBlockComment(){const e=this.state.curPosition(),t=this.state.pos,n=this.input.indexOf("*/",this.state.pos+2);if(-1===n)throw this.raise(t,"Unterminated comment");let r;for(this.state.pos=n+2,f.lastIndex=t;(r=f.exec(this.input))&&r.index=48&&t<=57)throw this.raise(this.state.pos,"Unexpected digit after hash token");if((this.hasPlugin("classPrivateProperties")||this.hasPlugin("classPrivateMethods"))&&this.state.classLevel>0)return++this.state.pos,void this.finishToken(s.hash);if("smart"!==this.getPluginOption("pipelineOperator","proposal"))throw this.raise(this.state.pos,"Unexpected character '#'");this.finishOp(s.hash,1)}readToken_dot(){const e=this.input.charCodeAt(this.state.pos+1);e>=48&&e<=57?this.readNumber(!0):46===e&&46===this.input.charCodeAt(this.state.pos+2)?(this.state.pos+=3,this.finishToken(s.ellipsis)):(++this.state.pos,this.finishToken(s.dot))}readToken_slash(){if(this.state.exprAllowed&&!this.state.inType)return++this.state.pos,void this.readRegexp();61===this.input.charCodeAt(this.state.pos+1)?this.finishOp(s.assign,2):this.finishOp(s.slash,1)}readToken_interpreter(){if(0!==this.state.pos||this.length<2)return!1;const e=this.state.pos;this.state.pos+=1;let t=this.input.charCodeAt(this.state.pos);if(33!==t)return!1;for(;!p(t)&&++this.state.pos=48&&t<=57?(++this.state.pos,this.finishToken(s.question)):(this.state.pos+=2,this.finishToken(s.questionDot)):61===t?this.finishOp(s.assign,3):this.finishOp(s.nullishCoalescing,2)}getTokenFromCode(e){switch(e){case 46:return void this.readToken_dot();case 40:return++this.state.pos,void this.finishToken(s.parenL);case 41:return++this.state.pos,void this.finishToken(s.parenR);case 59:return++this.state.pos,void this.finishToken(s.semi);case 44:return++this.state.pos,void this.finishToken(s.comma);case 91:return++this.state.pos,void this.finishToken(s.bracketL);case 93:return++this.state.pos,void this.finishToken(s.bracketR);case 123:return++this.state.pos,void this.finishToken(s.braceL);case 125:return++this.state.pos,void this.finishToken(s.braceR);case 58:return void(this.hasPlugin("functionBind")&&58===this.input.charCodeAt(this.state.pos+1)?this.finishOp(s.doubleColon,2):(++this.state.pos,this.finishToken(s.colon)));case 63:return void this.readToken_question();case 96:return++this.state.pos,void this.finishToken(s.backQuote);case 48:{const e=this.input.charCodeAt(this.state.pos+1);if(120===e||88===e)return void this.readRadixNumber(16);if(111===e||79===e)return void this.readRadixNumber(8);if(98===e||66===e)return void this.readRadixNumber(2)}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return void this.readNumber(!1);case 34:case 39:return void this.readString(e);case 47:return void this.readToken_slash();case 37:case 42:return void this.readToken_mult_modulo(e);case 124:case 38:return void this.readToken_pipe_amp(e);case 94:return void this.readToken_caret();case 43:case 45:return void this.readToken_plus_min(e);case 60:case 62:return void this.readToken_lt_gt(e);case 61:case 33:return void this.readToken_eq_excl(e);case 126:return void this.finishOp(s.tilde,1);case 64:return++this.state.pos,void this.finishToken(s.at);case 35:return void this.readToken_numberSign();case 92:return void this.readWord();default:if(D(e))return void this.readWord()}throw this.raise(this.state.pos,`Unexpected character '${String.fromCodePoint(e)}'`)}finishOp(e,t){const n=this.input.slice(this.state.pos,this.state.pos+t);this.state.pos+=t,this.finishToken(e,n)}readRegexp(){const e=this.state.pos;let t,n;for(;;){if(this.state.pos>=this.length)throw this.raise(e,"Unterminated regular expression");const r=this.input.charAt(this.state.pos);if(l.test(r))throw this.raise(e,"Unterminated regular expression");if(t)t=!1;else{if("["===r)n=!0;else if("]"===r&&n)n=!1;else if("/"===r&&!n)break;t="\\"===r}++this.state.pos}const r=this.input.slice(e,this.state.pos);++this.state.pos;let i="";for(;this.state.pos-1&&this.raise(this.state.pos+1,"Duplicate regular expression flag");else{if(!I(t)&&92!==t)break;this.raise(this.state.pos+1,"Invalid regular expression flag")}++this.state.pos,i+=e}this.finishToken(s.regexp,{pattern:r,flags:i})}readInt(e,t,n,r=!0){const i=this.state.pos,o=16===e?ue.hex:ue.decBinOct,a=16===e?ce.hex:10===e?ce.dec:8===e?ce.oct:ce.bin;let s=!1,u=0;for(let i=0,c=null==t?1/0:t;i-1||o.indexOf(t)>-1||Number.isNaN(t))&&this.raise(this.state.pos,"A numeric separator is only allowed between two digits"),r||this.raise(this.state.pos,"Numeric separators are not allowed inside unicode escape sequences or hex escape sequences"),++this.state.pos}else{if(c=t>=97?t-97+10:t>=65?t-65+10:ae(t)?t-48:1/0,c>=e)if(this.options.errorRecovery&&c<=9)c=0,this.raise(this.state.start+i+2,"Expected number in radix "+e);else{if(!n)break;c=0,s=!0}++this.state.pos,u=u*e+c}}return this.state.pos===i||null!=t&&this.state.pos-i!==t||s?null:u}readRadixNumber(e){const t=this.state.pos;let n=!1;this.state.pos+=2;const r=this.readInt(e);if(null==r&&this.raise(this.state.start+2,"Expected number in radix "+e),this.hasPlugin("bigInt")&&110===this.input.charCodeAt(this.state.pos)&&(++this.state.pos,n=!0),D(this.input.codePointAt(this.state.pos)))throw this.raise(this.state.pos,"Identifier directly after number");if(n){const e=this.input.slice(t,this.state.pos).replace(/[_n]/g,"");this.finishToken(s.bigint,e)}else this.finishToken(s.num,r)}readNumber(e){const t=this.state.pos;let n=!1,r=!1,i=!1;e||null!==this.readInt(10)||this.raise(t,"Invalid number");let o=this.state.pos-t>=2&&48===this.input.charCodeAt(t);o&&(this.state.strict&&this.raise(t,"Legacy octal literals are not allowed in strict mode"),/[89]/.test(this.input.slice(t,this.state.pos))&&(o=!1,i=!0));let a=this.input.charCodeAt(this.state.pos);if(46!==a||o||(++this.state.pos,this.readInt(10),n=!0,a=this.input.charCodeAt(this.state.pos)),69!==a&&101!==a||o||(a=this.input.charCodeAt(++this.state.pos),43!==a&&45!==a||++this.state.pos,null===this.readInt(10)&&this.raise(t,"Invalid number"),n=!0,a=this.input.charCodeAt(this.state.pos)),this.hasPlugin("numericSeparator")&&(o||i)){const e=this.input.slice(t,this.state.pos).indexOf("_");e>0&&this.raise(e+t,"Numeric separator can not be used after leading 0")}if(this.hasPlugin("bigInt")&&110===a&&((n||o||i)&&this.raise(t,"Invalid BigIntLiteral"),++this.state.pos,r=!0),D(this.input.codePointAt(this.state.pos)))throw this.raise(this.state.pos,"Identifier directly after number");const u=this.input.slice(t,this.state.pos).replace(/[_n]/g,"");if(r)return void this.finishToken(s.bigint,u);const c=o?parseInt(u,8):parseFloat(u);this.finishToken(s.num,c)}readCodePoint(e){let t;if(123===this.input.charCodeAt(this.state.pos)){const n=++this.state.pos;if(t=this.readHexChar(this.input.indexOf("}",this.state.pos)-this.state.pos,!0,e),++this.state.pos,null===t)--this.state.invalidTemplateEscapePosition;else if(t>1114111){if(!e)return this.state.invalidTemplateEscapePosition=n-2,null;this.raise(n,"Code point out of bounds")}}else t=this.readHexChar(4,!1,e);return t}readString(e){let t="",n=++this.state.pos;for(;;){if(this.state.pos>=this.length)throw this.raise(this.state.start,"Unterminated string constant");const r=this.input.charCodeAt(this.state.pos);if(r===e)break;if(92===r)t+=this.input.slice(n,this.state.pos),t+=this.readEscapedChar(!1),n=this.state.pos;else if(8232===r||8233===r)++this.state.pos,++this.state.curLine;else{if(p(r))throw this.raise(this.state.start,"Unterminated string constant");++this.state.pos}}t+=this.input.slice(n,this.state.pos++),this.finishToken(s.string,t)}readTmplToken(){let e="",t=this.state.pos,n=!1;for(;;){if(this.state.pos>=this.length)throw this.raise(this.state.start,"Unterminated template");const r=this.input.charCodeAt(this.state.pos);if(96===r||36===r&&123===this.input.charCodeAt(this.state.pos+1))return this.state.pos===this.state.start&&this.match(s.template)?36===r?(this.state.pos+=2,void this.finishToken(s.dollarBraceL)):(++this.state.pos,void this.finishToken(s.backQuote)):(e+=this.input.slice(t,this.state.pos),void this.finishToken(s.template,n?null:e));if(92===r){e+=this.input.slice(t,this.state.pos);const r=this.readEscapedChar(!0);null===r?n=!0:e+=r,t=this.state.pos}else if(p(r)){switch(e+=this.input.slice(t,this.state.pos),++this.state.pos,r){case 13:10===this.input.charCodeAt(this.state.pos)&&++this.state.pos;case 10:e+="\n";break;default:e+=String.fromCharCode(r)}++this.state.curLine,this.state.lineStart=this.state.pos,t=this.state.pos}else++this.state.pos}}readEscapedChar(e){const t=!e,n=this.input.charCodeAt(++this.state.pos);switch(++this.state.pos,n){case 110:return"\n";case 114:return"\r";case 120:{const e=this.readHexChar(2,!1,t);return null===e?null:String.fromCharCode(e)}case 117:{const e=this.readCodePoint(t);return null===e?null:String.fromCodePoint(e)}case 116:return"\t";case 98:return"\b";case 118:return"\v";case 102:return"\f";case 13:10===this.input.charCodeAt(this.state.pos)&&++this.state.pos;case 10:this.state.lineStart=this.state.pos,++this.state.curLine;case 8232:case 8233:return"";case 56:case 57:if(e){const e=this.state.pos-1;return this.state.invalidTemplateEscapePosition=e,null}default:if(n>=48&&n<=55){const t=this.state.pos-1;let n=this.input.substr(this.state.pos-1,3).match(/^[0-7]+/)[0],r=parseInt(n,8);r>255&&(n=n.slice(0,-1),r=parseInt(n,8)),this.state.pos+=n.length-1;const i=this.input.charCodeAt(this.state.pos);if("0"!==n||56===i||57===i){if(e)return this.state.invalidTemplateEscapePosition=t,null;this.state.strict?this.raise(t,"Octal literal in strict mode"):this.state.containsOctal||(this.state.containsOctal=!0,this.state.octalPosition=t)}return String.fromCharCode(r)}return String.fromCharCode(n)}}readHexChar(e,t,n){const r=this.state.pos,i=this.readInt(16,e,t,!1);return null===i&&(n?this.raise(r,"Bad character escape sequence"):(this.state.pos=r-1,this.state.invalidTemplateEscapePosition=r-1)),i}readWord1(){let e="";this.state.containsEsc=!1;const t=this.state.pos;let n=this.state.pos;for(;this.state.posthis.state.lastTokEnd&&this.raise(this.state.lastTokEnd,e)}unexpected(e,t="Unexpected token"){throw"string"!=typeof t&&(t=`Unexpected token, expected "${t.label}"`),this.raise(null!=e?e:this.state.start,t)}expectPlugin(e,t){if(!this.hasPlugin(e))throw this.raise(null!=t?t:this.state.start,`This experimental syntax requires enabling the parser plugin: '${e}'`,{missingPluginNames:[e]});return!0}expectOnePlugin(e,t){if(!e.some(e=>this.hasPlugin(e)))throw this.raise(null!=t?t:this.state.start,`This experimental syntax requires enabling one of the following parser plugin(s): '${e.join(", ")}'`,{missingPluginNames:e})}checkYieldAwaitInDefaultParams(){-1!==this.state.yieldPos&&(-1===this.state.awaitPos||this.state.yieldPos{throw n.node=e,n});if(this.state.errors.length>t.errors.length){const e=this.state;return this.state=t,{node:r,error:e.errors[t.errors.length],thrown:!1,aborted:!1,failState:e}}return{node:r,error:null,thrown:!1,aborted:!1,failState:null}}catch(e){const r=this.state;if(this.state=t,e instanceof SyntaxError)return{node:null,error:e,thrown:!0,aborted:!1,failState:r};if(e===n)return{node:n.node,error:null,thrown:!1,aborted:!0,failState:r};throw e}}}{startNode(){return new pe(this,this.state.start,this.state.startLoc)}startNodeAt(e,t){return new pe(this,e,t)}startNodeAtNode(e){return this.startNodeAt(e.start,e.loc.start)}finishNode(e,t){return this.finishNodeAt(e,t,this.state.lastTokEnd,this.state.lastTokEndLoc)}finishNodeAt(e,t,n,r){return e.type=t,e.end=n,e.loc.end=r,this.options.ranges&&(e.range[1]=n),this.processComment(e),e}resetStartLocation(e,t,n){e.start=t,e.loc.start=n,this.options.ranges&&(e.range[0]=t)}resetEndLocation(e,t=this.state.lastTokEnd,n=this.state.lastTokEndLoc){e.end=t,e.loc.end=n,this.options.ranges&&(e.range[1]=t)}resetStartLocationFromNode(e,t){this.resetStartLocation(e,t.start,t.loc.start)}}{toAssignable(e,t,n){var r;if(e)switch(e.type){case"Identifier":case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":break;case"ObjectExpression":e.type="ObjectPattern";for(let n=0,r=e.properties.length,o=r-1;n=n.left.start&&(t.start=0),this.checkLVal(u,void 0,void 0,"assignment expression");const a=he(u);let c;return"ObjectPattern"===a.type?c="`({a}) = 0` use `({a} = 0)`":"ArrayPattern"===a.type&&(c="`([a]) = 0` use `([a] = 0)`"),c&&(u.extra&&u.extra.parenthesized||"ParenthesizedExpression"===u.type)&&this.raise(a.start,`You're trying to assign to a parenthesized expression, eg. instead of ${c}`),this.next(),n.right=this.parseMaybeAssign(e),this.finishNode(n,"AssignmentExpression")}return a&&t.start&&this.unexpected(t.start),u}parseMaybeConditional(e,t,n){const r=this.state.start,i=this.state.startLoc,o=this.state.potentialArrowAt,a=this.parseExprOps(e,t);return"ArrowFunctionExpression"===a.type&&a.start===o?a:t&&t.start?a:this.parseConditional(a,e,r,i,n)}parseConditional(e,t,n,r,i){if(this.eat(s.question)){const i=this.startNodeAt(n,r);return i.test=e,i.consequent=this.parseMaybeAssign(),this.expect(s.colon),i.alternate=this.parseMaybeAssign(t),this.finishNode(i,"ConditionalExpression")}return e}parseExprOps(e,t){const n=this.state.start,r=this.state.startLoc,i=this.state.potentialArrowAt,o=this.parseMaybeUnary(t);return"ArrowFunctionExpression"===o.type&&o.start===i?o:t&&t.start?o:this.parseExprOp(o,n,r,-1,e)}parseExprOp(e,t,n,r,i){const o=this.state.type.binop;if(!(null==o||i&&this.match(s._in))&&o>r){const a=this.state.value;if("|>"===a&&this.state.inFSharpPipelineDirectBody)return e;const u=this.startNodeAt(t,n);u.left=e,u.operator=a,"**"!==a||"UnaryExpression"!==e.type||!this.options.createParenthesizedExpressions&&e.extra&&e.extra.parenthesized||this.raise(e.argument.start,"Illegal expression. Wrap left hand side or entire exponentiation in parentheses.");const c=this.state.type;if(c===s.pipeline?(this.expectPlugin("pipelineOperator"),this.state.inPipeline=!0,this.checkPipelineAtInfixOperator(e,t)):c===s.nullishCoalescing&&this.expectPlugin("nullishCoalescingOperator"),this.next(),c===s.pipeline&&"minimal"===this.getPluginOption("pipelineOperator","proposal")&&this.match(s.name)&&"await"===this.state.value&&this.scope.inAsync)throw this.raise(this.state.start,'Unexpected "await" after pipeline body; await must have parentheses in minimal proposal');if(u.right=this.parseExprOpRightExpr(c,o,i),c===s.nullishCoalescing){if(!("LogicalExpression"!==e.type||"??"===e.operator||e.extra&&e.extra.parenthesized))throw this.raise(e.start,"Nullish coalescing operator(??) requires parens when mixing with logical operators");if(!("LogicalExpression"!==u.right.type||"??"===u.right.operator||u.right.extra&&u.right.extra.parenthesized))throw this.raise(u.right.start,"Nullish coalescing operator(??) requires parens when mixing with logical operators")}return this.finishNode(u,c===s.logicalOR||c===s.logicalAND||c===s.nullishCoalescing?"LogicalExpression":"BinaryExpression"),this.parseExprOp(u,t,n,r,i)}return e}parseExprOpRightExpr(e,t,n){const r=this.state.start,i=this.state.startLoc;switch(e){case s.pipeline:switch(this.getPluginOption("pipelineOperator","proposal")){case"smart":return this.withTopicPermittingContext(()=>this.parseSmartPipelineBody(this.parseExprOpBaseRightExpr(e,t,n),r,i));case"fsharp":return this.withSoloAwaitPermittingContext(()=>this.parseFSharpPipelineBody(t,n))}default:return this.parseExprOpBaseRightExpr(e,t,n)}}parseExprOpBaseRightExpr(e,t,n){const r=this.state.start,i=this.state.startLoc;return this.parseExprOp(this.parseMaybeUnary(),r,i,e.rightAssociative?t-1:t,n)}parseMaybeUnary(e){if(this.isContextual("await")&&this.isAwaitAllowed())return this.parseAwait();if(this.state.type.prefix){const t=this.startNode(),n=this.match(s.incDec);if(t.operator=this.state.value,t.prefix=!0,"throw"===t.operator&&this.expectPlugin("throwExpressions"),this.next(),t.argument=this.parseMaybeUnary(),e&&e.start&&this.unexpected(e.start),n)this.checkLVal(t.argument,void 0,void 0,"prefix operation");else if(this.state.strict&&"delete"===t.operator){const e=t.argument;"Identifier"===e.type?this.raise(t.start,"Deleting local variable in strict mode"):"MemberExpression"===e.type&&"PrivateName"===e.property.type&&this.raise(t.start,"Deleting a private field is not allowed")}return this.finishNode(t,n?"UpdateExpression":"UnaryExpression")}const t=this.state.start,n=this.state.startLoc;let r=this.parseExprSubscripts(e);if(e&&e.start)return r;for(;this.state.type.postfix&&!this.canInsertSemicolon();){const e=this.startNodeAt(t,n);e.operator=this.state.value,e.prefix=!1,e.argument=r,this.checkLVal(r,void 0,void 0,"postfix operation"),this.next(),r=this.finishNode(e,"UpdateExpression")}return r}parseExprSubscripts(e){const t=this.state.start,n=this.state.startLoc,r=this.state.potentialArrowAt,i=this.parseExprAtom(e);return"ArrowFunctionExpression"===i.type&&i.start===r?i:e&&e.start?i:this.parseSubscripts(i,t,n)}parseSubscripts(e,t,n,r){const i={optionalChainMember:!1,maybeAsyncArrow:this.atPossibleAsync(e),stop:!1};do{e=this.parseSubscript(e,t,n,r,i),i.maybeAsyncArrow=!1}while(!i.stop);return e}parseSubscript(e,t,n,r,i){if(!r&&this.eat(s.doubleColon)){const o=this.startNodeAt(t,n);return o.object=e,o.callee=this.parseNoCallExpr(),i.stop=!0,this.parseSubscripts(this.finishNode(o,"BindExpression"),t,n,r)}if(this.match(s.questionDot)){if(this.expectPlugin("optionalChaining"),i.optionalChainMember=!0,r&&40===this.lookaheadCharCode())return i.stop=!0,e;this.next();const o=this.startNodeAt(t,n);return this.eat(s.bracketL)?(o.object=e,o.property=this.parseExpression(),o.computed=!0,o.optional=!0,this.expect(s.bracketR),this.finishNode(o,"OptionalMemberExpression")):this.eat(s.parenL)?(o.callee=e,o.arguments=this.parseCallExpressionArguments(s.parenR,!1),o.optional=!0,this.finishCallExpression(o,!0)):(o.object=e,o.property=this.parseIdentifier(!0),o.computed=!1,o.optional=!0,this.finishNode(o,"OptionalMemberExpression"))}if(this.eat(s.dot)){const r=this.startNodeAt(t,n);return r.object=e,r.property=this.parseMaybePrivateName(),r.computed=!1,"PrivateName"===r.property.type&&"Super"===r.object.type&&this.raise(t,"Private fields can't be accessed on super"),i.optionalChainMember?(r.optional=!1,this.finishNode(r,"OptionalMemberExpression")):this.finishNode(r,"MemberExpression")}if(this.eat(s.bracketL)){const r=this.startNodeAt(t,n);return r.object=e,r.property=this.parseExpression(),r.computed=!0,this.expect(s.bracketR),i.optionalChainMember?(r.optional=!1,this.finishNode(r,"OptionalMemberExpression")):this.finishNode(r,"MemberExpression")}if(!r&&this.match(s.parenL)){const r=this.state.maybeInArrowParameters,o=this.state.yieldPos,a=this.state.awaitPos;this.state.maybeInArrowParameters=!0,this.state.yieldPos=-1,this.state.awaitPos=-1,this.next();let u=this.startNodeAt(t,n);return u.callee=e,u.arguments=this.parseCallExpressionArguments(s.parenR,i.maybeAsyncArrow,"Import"===e.type,"Super"!==e.type,u),this.finishCallExpression(u,i.optionalChainMember),i.maybeAsyncArrow&&this.shouldParseAsyncArrow()?(i.stop=!0,u=this.parseAsyncArrowFromCallExpression(this.startNodeAt(t,n),u),this.checkYieldAwaitInDefaultParams(),this.state.yieldPos=o,this.state.awaitPos=a):(this.toReferencedListDeep(u.arguments),-1!==o&&(this.state.yieldPos=o),(this.isAwaitAllowed()||r)&&-1===a||(this.state.awaitPos=a)),this.state.maybeInArrowParameters=r,u}return this.match(s.backQuote)?this.parseTaggedTemplateExpression(t,n,e,i):(i.stop=!0,e)}parseTaggedTemplateExpression(e,t,n,r,i){const o=this.startNodeAt(e,t);return o.tag=n,o.quasi=this.parseTemplate(!0),i&&(o.typeParameters=i),r.optionalChainMember&&this.raise(e,"Tagged Template Literals are not allowed in optionalChain"),this.finishNode(o,"TaggedTemplateExpression")}atPossibleAsync(e){return"Identifier"===e.type&&"async"===e.name&&this.state.lastTokEnd===e.end&&!this.canInsertSemicolon()&&"async"===this.input.slice(e.start,e.end)}finishCallExpression(e,t){if("Import"===e.callee.type)if(1!==e.arguments.length)this.raise(e.start,"import() requires exactly one argument");else{const t=e.arguments[0];t&&"SpreadElement"===t.type&&this.raise(t.start,"... is not allowed in import()")}return this.finishNode(e,t?"OptionalCallExpression":"CallExpression")}parseCallExpressionArguments(e,t,n,r,i){const o=[];let a,u=!0;const c=this.state.inFSharpPipelineDirectBody;for(this.state.inFSharpPipelineDirectBody=!1;!this.eat(e);){if(u)u=!1;else if(this.expect(s.comma),this.match(e)){n&&this.raise(this.state.lastTokStart,"Trailing comma is disallowed inside import(...) arguments"),i&&this.addExtra(i,"trailingComma",this.state.lastTokStart),this.next();break}this.match(s.parenL)&&!a&&(a=this.state.start),o.push(this.parseExprListItem(!1,t?{start:0}:void 0,t?{start:0}:void 0,r))}return t&&a&&this.shouldParseAsyncArrow()&&this.unexpected(),this.state.inFSharpPipelineDirectBody=c,o}shouldParseAsyncArrow(){return this.match(s.arrow)&&!this.canInsertSemicolon()}parseAsyncArrowFromCallExpression(e,t){var n;return this.expect(s.arrow),this.parseArrowExpression(e,t.arguments,!0,null==(n=t.extra)?void 0:n.trailingComma),e}parseNoCallExpr(){const e=this.state.start,t=this.state.startLoc;return this.parseSubscripts(this.parseExprAtom(),e,t,!0)}parseExprAtom(e){this.state.type===s.slash&&this.readRegexp();const t=this.state.potentialArrowAt===this.state.start;let n;switch(this.state.type){case s._super:return n=this.startNode(),this.next(),!this.match(s.parenL)||this.scope.allowDirectSuper||this.options.allowSuperOutsideMethod?this.scope.allowSuper||this.options.allowSuperOutsideMethod||this.raise(n.start,"super is only allowed in object methods and classes"):this.raise(n.start,"super() is only valid inside a class constructor of a subclass. Maybe a typo in the method name ('constructor') or not extending another class?"),this.match(s.parenL)||this.match(s.bracketL)||this.match(s.dot)||this.raise(n.start,"super can only be used with function calls (i.e. super()) or in property accesses (i.e. super.prop or super[prop])"),this.finishNode(n,"Super");case s._import:return n=this.startNode(),this.next(),this.match(s.dot)?this.parseImportMetaProperty(n):(this.expectPlugin("dynamicImport",n.start),this.match(s.parenL)||this.unexpected(null,s.parenL),this.finishNode(n,"Import"));case s._this:return n=this.startNode(),this.next(),this.finishNode(n,"ThisExpression");case s.name:{n=this.startNode();const e=this.state.containsEsc,r=this.parseIdentifier();if(!e&&"async"===r.name&&this.match(s._function)&&!this.canInsertSemicolon()){const e=this.state.context.length-1;if(this.state.context[e]!==m.functionStatement)throw new Error("Internal error");return this.state.context[e]=m.functionExpression,this.next(),this.parseFunction(n,void 0,!0)}if(t&&!e&&"async"===r.name&&this.match(s.name)&&!this.canInsertSemicolon()){const e=[this.parseIdentifier()];return this.expect(s.arrow),this.parseArrowExpression(n,e,!0),n}return t&&this.match(s.arrow)&&!this.canInsertSemicolon()?(this.next(),this.parseArrowExpression(n,[r],!1),n):r}case s._do:{this.expectPlugin("doExpressions");const e=this.startNode();this.next();const t=this.state.labels;return this.state.labels=[],e.body=this.parseBlock(),this.state.labels=t,this.finishNode(e,"DoExpression")}case s.regexp:{const e=this.state.value;return n=this.parseLiteral(e.value,"RegExpLiteral"),n.pattern=e.pattern,n.flags=e.flags,n}case s.num:return this.parseLiteral(this.state.value,"NumericLiteral");case s.bigint:return this.parseLiteral(this.state.value,"BigIntLiteral");case s.string:return this.parseLiteral(this.state.value,"StringLiteral");case s._null:return n=this.startNode(),this.next(),this.finishNode(n,"NullLiteral");case s._true:case s._false:return this.parseBooleanLiteral();case s.parenL:return this.parseParenAndDistinguishExpression(t);case s.bracketL:{const t=this.state.inFSharpPipelineDirectBody;return this.state.inFSharpPipelineDirectBody=!1,n=this.startNode(),this.next(),n.elements=this.parseExprList(s.bracketR,!0,e,n),this.state.maybeInArrowParameters||this.toReferencedList(n.elements),this.state.inFSharpPipelineDirectBody=t,this.finishNode(n,"ArrayExpression")}case s.braceL:{const t=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!1;const n=this.parseObj(!1,e);return this.state.inFSharpPipelineDirectBody=t,n}case s._function:return this.parseFunctionExpression();case s.at:this.parseDecorators();case s._class:return n=this.startNode(),this.takeDecorators(n),this.parseClass(n,!1);case s._new:return this.parseNew();case s.backQuote:return this.parseTemplate(!1);case s.doubleColon:{n=this.startNode(),this.next(),n.object=null;const e=n.callee=this.parseNoCallExpr();if("MemberExpression"===e.type)return this.finishNode(n,"BindExpression");throw this.raise(e.start,"Binding should be performed on object property.")}case s.hash:if(this.state.inPipeline)return n=this.startNode(),"smart"!==this.getPluginOption("pipelineOperator","proposal")&&this.raise(n.start,"Primary Topic Reference found but pipelineOperator not passed 'smart' for 'proposal' option."),this.next(),this.primaryTopicReferenceIsAllowedInCurrentTopicContext()||this.raise(n.start,"Topic reference was used in a lexical context without topic binding"),this.registerTopicReference(),this.finishNode(n,"PipelinePrimaryTopicReference");default:throw this.unexpected()}}parseBooleanLiteral(){const e=this.startNode();return e.value=this.match(s._true),this.next(),this.finishNode(e,"BooleanLiteral")}parseMaybePrivateName(){if(this.match(s.hash)){this.expectOnePlugin(["classPrivateProperties","classPrivateMethods"]);const e=this.startNode();return this.next(),this.assertNoSpace("Unexpected space between # and identifier"),e.id=this.parseIdentifier(!0),this.finishNode(e,"PrivateName")}return this.parseIdentifier(!0)}parseFunctionExpression(){const e=this.startNode();let t=this.startNode();return this.next(),t=this.createIdentifier(t,"function"),this.scope.inGenerator&&this.eat(s.dot)?this.parseMetaProperty(e,t,"sent"):this.parseFunction(e)}parseMetaProperty(e,t,n){e.meta=t,"function"===t.name&&"sent"===n&&(this.isContextual(n)?this.expectPlugin("functionSent"):this.hasPlugin("functionSent")||this.unexpected());const r=this.state.containsEsc;return e.property=this.parseIdentifier(!0),(e.property.name!==n||r)&&this.raise(e.property.start,`The only valid meta property for ${t.name} is ${t.name}.${n}`),this.finishNode(e,"MetaProperty")}parseImportMetaProperty(e){const t=this.createIdentifier(this.startNodeAtNode(e),"import");return this.expect(s.dot),this.isContextual("meta")?(this.expectPlugin("importMeta"),this.inModule||this.raise(t.start,"import.meta may appear only with 'sourceType: \"module\"'",{code:"BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED"}),this.sawUnambiguousESM=!0):this.hasPlugin("importMeta")||this.raise(t.start,"Dynamic imports require a parameter: import('a.js')"),this.parseMetaProperty(e,t,"meta")}parseLiteral(e,t,n,r){n=n||this.state.start,r=r||this.state.startLoc;const i=this.startNodeAt(n,r);return this.addExtra(i,"rawValue",e),this.addExtra(i,"raw",this.input.slice(n,this.state.end)),i.value=e,this.next(),this.finishNode(i,t)}parseParenAndDistinguishExpression(e){const t=this.state.start,n=this.state.startLoc;let r;this.expect(s.parenL);const i=this.state.maybeInArrowParameters,o=this.state.yieldPos,a=this.state.awaitPos,u=this.state.inFSharpPipelineDirectBody;this.state.maybeInArrowParameters=!0,this.state.yieldPos=-1,this.state.awaitPos=-1,this.state.inFSharpPipelineDirectBody=!1;const c=this.state.start,l=this.state.startLoc,f=[],p={start:0},h={start:0};let d,y,m=!0;for(;!this.match(s.parenR);){if(m)m=!1;else if(this.expect(s.comma,h.start||null),this.match(s.parenR)){y=this.state.start;break}if(this.match(s.ellipsis)){const e=this.state.start,t=this.state.startLoc;d=this.state.start,f.push(this.parseParenItem(this.parseRestBinding(),e,t)),this.checkCommaAfterRest(41);break}f.push(this.parseMaybeAssign(!1,p,this.parseParenItem,h))}const v=this.state.start,b=this.state.startLoc;this.expect(s.parenR),this.state.maybeInArrowParameters=i,this.state.inFSharpPipelineDirectBody=u;let g=this.startNodeAt(t,n);if(e&&this.shouldParseArrow()&&(g=this.parseArrow(g))){this.checkYieldAwaitInDefaultParams(),this.state.yieldPos=o,this.state.awaitPos=a;for(let e=0;e1?(r=this.startNodeAt(c,l),r.expressions=f,this.finishNodeAt(r,"SequenceExpression",v,b)):r=f[0],!this.options.createParenthesizedExpressions)return this.addExtra(r,"parenthesized",!0),this.addExtra(r,"parenStart",t),r;const w=this.startNodeAt(t,n);return w.expression=r,this.finishNode(w,"ParenthesizedExpression"),w}shouldParseArrow(){return!this.canInsertSemicolon()}parseArrow(e){if(this.eat(s.arrow))return e}parseParenItem(e,t,n){return e}parseNew(){const e=this.startNode();let t=this.startNode();if(this.next(),t=this.createIdentifier(t,"new"),this.eat(s.dot)){const n=this.parseMetaProperty(e,t,"target");if(!this.scope.inNonArrowFunction&&!this.state.inClassProperty){let e="new.target can only be used in functions";this.hasPlugin("classProperties")&&(e+=" or class properties"),this.raise(n.start,e)}return n}return e.callee=this.parseNoCallExpr(),"Import"===e.callee.type?this.raise(e.callee.start,"Cannot use new with import(...)"):"OptionalMemberExpression"===e.callee.type||"OptionalCallExpression"===e.callee.type?this.raise(this.state.lastTokEnd,"constructors in/after an Optional Chain are not allowed"):this.eat(s.questionDot)&&this.raise(this.state.start,"constructors in/after an Optional Chain are not allowed"),this.parseNewArguments(e),this.finishNode(e,"NewExpression")}parseNewArguments(e){if(this.eat(s.parenL)){const t=this.parseExprList(s.parenR);this.toReferencedList(t),e.arguments=t}else e.arguments=[]}parseTemplateElement(e){const t=this.startNode();return null===this.state.value&&(e?this.state.invalidTemplateEscapePosition=null:this.raise(this.state.invalidTemplateEscapePosition||0,"Invalid escape sequence in template")),t.value={raw:this.input.slice(this.state.start,this.state.end).replace(/\r\n?/g,"\n"),cooked:this.state.value},this.next(),t.tail=this.match(s.backQuote),this.finishNode(t,"TemplateElement")}parseTemplate(e){const t=this.startNode();this.next(),t.expressions=[];let n=this.parseTemplateElement(e);for(t.quasis=[n];!n.tail;)this.expect(s.dollarBraceL),t.expressions.push(this.parseExpression()),this.expect(s.braceR),t.quasis.push(n=this.parseTemplateElement(e));return this.next(),this.finishNode(t,"TemplateLiteral")}parseObj(e,t){const n=Object.create(null);let r=!0;const i=this.startNode();for(i.properties=[],this.next();!this.eat(s.braceR);){if(r)r=!1;else if(this.expect(s.comma),this.match(s.braceR)){this.addExtra(i,"trailingComma",this.state.lastTokStart),this.next();break}const o=this.parseObjectMember(e,t);e||this.checkDuplicatedProto(o,n),o.shorthand&&this.addExtra(o,"shorthand",!0),i.properties.push(o)}return this.match(s.eq)||void 0===n.start||this.raise(n.start,"Redefinition of __proto__ property"),this.finishNode(i,e?"ObjectPattern":"ObjectExpression")}isAsyncProp(e){return!e.computed&&"Identifier"===e.key.type&&"async"===e.key.name&&(this.match(s.name)||this.match(s.num)||this.match(s.string)||this.match(s.bracketL)||this.state.type.keyword||this.match(s.star))&&!this.hasPrecedingLineBreak()}parseObjectMember(e,t){let n=[];if(this.match(s.at))for(this.hasPlugin("decorators")&&this.raise(this.state.start,"Stage 2 decorators disallow object literal property decorators");this.match(s.at);)n.push(this.parseDecorator());const r=this.startNode();let i,o,a=!1,u=!1;if(this.match(s.ellipsis))return n.length&&this.unexpected(),e?(this.next(),r.argument=this.parseIdentifier(),this.checkCommaAfterRest(125),this.finishNode(r,"RestElement")):this.parseSpread();n.length&&(r.decorators=n,n=[]),r.method=!1,(e||t)&&(i=this.state.start,o=this.state.startLoc),e||(a=this.eat(s.star));const c=this.state.containsEsc;return this.parsePropertyName(r),e||c||a||!this.isAsyncProp(r)?u=!1:(u=!0,a=this.eat(s.star),this.parsePropertyName(r)),this.parseObjPropValue(r,i,o,a,u,e,t,c),r}isGetterOrSetterMethod(e,t){return!t&&!e.computed&&"Identifier"===e.key.type&&("get"===e.key.name||"set"===e.key.name)&&(this.match(s.string)||this.match(s.num)||this.match(s.bracketL)||this.match(s.name)||!!this.state.type.keyword)}getGetterSetterExpectedParamCount(e){return"get"===e.kind?0:1}checkGetterSetterParams(e){const t=this.getGetterSetterExpectedParamCount(e),n=e.start;e.params.length!==t&&("get"===e.kind?this.raise(n,"getter must not have any formal parameters"):this.raise(n,"setter must have exactly one formal parameter")),"set"===e.kind&&"RestElement"===e.params[e.params.length-1].type&&this.raise(n,"setter function argument must not be a rest parameter")}parseObjectMethod(e,t,n,r,i){return n||t||this.match(s.parenL)?(r&&this.unexpected(),e.kind="method",e.method=!0,this.parseMethod(e,t,n,!1,!1,"ObjectMethod")):!i&&this.isGetterOrSetterMethod(e,r)?((t||n)&&this.unexpected(),e.kind=e.key.name,this.parsePropertyName(e),this.parseMethod(e,!1,!1,!1,!1,"ObjectMethod"),this.checkGetterSetterParams(e),e):void 0}parseObjectProperty(e,t,n,r,i){return e.shorthand=!1,this.eat(s.colon)?(e.value=r?this.parseMaybeDefault(this.state.start,this.state.startLoc):this.parseMaybeAssign(!1,i),this.finishNode(e,"ObjectProperty")):e.computed||"Identifier"!==e.key.type?void 0:(this.checkReservedWord(e.key.name,e.key.start,!0,!0),r?e.value=this.parseMaybeDefault(t,n,e.key.__clone()):this.match(s.eq)&&i?(i.start||(i.start=this.state.start),e.value=this.parseMaybeDefault(t,n,e.key.__clone())):e.value=e.key.__clone(),e.shorthand=!0,this.finishNode(e,"ObjectProperty"))}parseObjPropValue(e,t,n,r,i,o,a,s){const u=this.parseObjectMethod(e,r,i,o,s)||this.parseObjectProperty(e,t,n,o,a);return u||this.unexpected(),u}parsePropertyName(e){if(this.eat(s.bracketL))e.computed=!0,e.key=this.parseMaybeAssign(),this.expect(s.bracketR);else{const t=this.state.inPropertyName;this.state.inPropertyName=!0,e.key=this.match(s.num)||this.match(s.string)?this.parseExprAtom():this.parseMaybePrivateName(),"PrivateName"!==e.key.type&&(e.computed=!1),this.state.inPropertyName=t}return e.key}initFunction(e,t){e.id=null,e.generator=!1,e.async=!!t}parseMethod(e,t,n,r,i,o,a=!1){const s=this.state.yieldPos,c=this.state.awaitPos;this.state.yieldPos=-1,this.state.awaitPos=-1,this.initFunction(e,n),e.generator=!!t;const l=r;return this.scope.enter(64|u(n,e.generator)|(a?256:0)|(i?128:0)),this.parseFunctionParams(e,l),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBodyAndFinish(e,o,!0),this.scope.exit(),this.state.yieldPos=s,this.state.awaitPos=c,e}parseArrowExpression(e,t,n,r){this.scope.enter(16|u(n,!1)),this.initFunction(e,n);const i=this.state.maybeInArrowParameters,o=this.state.yieldPos,a=this.state.awaitPos;return this.state.maybeInArrowParameters=!1,this.state.yieldPos=-1,this.state.awaitPos=-1,t&&this.setArrowFunctionParameters(e,t,r),this.parseFunctionBody(e,!0),this.scope.exit(),this.state.maybeInArrowParameters=i,this.state.yieldPos=o,this.state.awaitPos=a,this.finishNode(e,"ArrowFunctionExpression")}setArrowFunctionParameters(e,t,n){e.params=this.toAssignableList(t,!0,"arrow function parameters",n)}isStrictBody(e){if("BlockStatement"===e.body.type&&e.body.directives.length)for(let t=0,n=e.body.directives;t" after pipeline body; arrow function in pipeline body must be parenthesized');"PipelineTopicExpression"===t&&"SequenceExpression"===e.type&&this.raise(n,"Pipeline body may not be a comma-separated sequence expression")}parseSmartPipelineBodyInStyle(e,t,n,r){const i=this.startNodeAt(n,r);switch(t){case"PipelineBareFunction":i.callee=e;break;case"PipelineBareConstructor":i.callee=e.callee;break;case"PipelineBareAwaitedFunction":i.callee=e.argument;break;case"PipelineTopicExpression":this.topicReferenceWasUsedInCurrentTopicContext()||this.raise(n,"Pipeline is in topic style but does not use topic reference"),i.expression=e;break;default:throw new Error(`Internal @babel/parser error: Unknown pipeline style (${t})`)}return this.finishNode(i,t)}checkSmartPipelineBodyStyle(e){return e.type,this.isSimpleReference(e)?"PipelineBareFunction":"PipelineTopicExpression"}isSimpleReference(e){switch(e.type){case"MemberExpression":return!e.computed&&this.isSimpleReference(e.object);case"Identifier":return!0;default:return!1}}withTopicPermittingContext(e){const t=this.state.topicContext;this.state.topicContext={maxNumOfResolvableTopics:1,maxTopicIndex:null};try{return e()}finally{this.state.topicContext=t}}withTopicForbiddingContext(e){const t=this.state.topicContext;this.state.topicContext={maxNumOfResolvableTopics:0,maxTopicIndex:null};try{return e()}finally{this.state.topicContext=t}}withSoloAwaitPermittingContext(e){const t=this.state.soloAwait;this.state.soloAwait=!0;try{return e()}finally{this.state.soloAwait=t}}registerTopicReference(){this.state.topicContext.maxTopicIndex=0}primaryTopicReferenceIsAllowedInCurrentTopicContext(){return this.state.topicContext.maxNumOfResolvableTopics>=1}topicReferenceWasUsedInCurrentTopicContext(){return null!=this.state.topicContext.maxTopicIndex&&this.state.topicContext.maxTopicIndex>=0}parseFSharpPipelineBody(e,t){const n=this.state.start,r=this.state.startLoc;this.state.potentialArrowAt=this.state.start;const i=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!0;const o=this.parseExprOp(this.parseMaybeUnary(),n,r,e,t);return this.state.inFSharpPipelineDirectBody=i,o}}{parseTopLevel(e,t){if(t.sourceType=this.options.sourceType,t.interpreter=this.parseInterpreterDirective(),this.parseBlockBody(t,!0,!0,s.eof),this.inModule&&!this.options.allowUndeclaredExports&&this.scope.undefinedExports.size>0)for(let e=0,t=Array.from(this.scope.undefinedExports);ethis.parseStatement("do")),this.state.labels.pop(),this.expect(s._while),e.test=this.parseHeaderExpression(),this.eat(s.semi),this.finishNode(e,"DoWhileStatement")}parseForStatement(e){this.next(),this.state.labels.push(de);let t=-1;if(this.isAwaitAllowed()&&this.eatContextual("await")&&(t=this.state.lastTokStart),this.scope.enter(0),this.expect(s.parenL),this.match(s.semi))return t>-1&&this.unexpected(t),this.parseFor(e,null);const n=this.isLet();if(this.match(s._var)||this.match(s._const)||n){const r=this.startNode(),i=n?"let":this.state.value;return this.next(),this.parseVar(r,!0,i),this.finishNode(r,"VariableDeclaration"),(this.match(s._in)||this.isContextual("of"))&&1===r.declarations.length?this.parseForIn(e,r,t):(t>-1&&this.unexpected(t),this.parseFor(e,r))}const r={start:0},i=this.parseExpression(!0,r);if(this.match(s._in)||this.isContextual("of")){const n=this.isContextual("of")?"for-of statement":"for-in statement";return this.toAssignable(i,void 0,n),this.checkLVal(i,void 0,void 0,n),this.parseForIn(e,i,t)}return r.start&&this.unexpected(r.start),t>-1&&this.unexpected(t),this.parseFor(e,i)}parseFunctionStatement(e,t,n){return this.next(),this.parseFunction(e,1|(n?0:2),t)}parseIfStatement(e){return this.next(),e.test=this.parseHeaderExpression(),e.consequent=this.parseStatement("if"),e.alternate=this.eat(s._else)?this.parseStatement("if"):null,this.finishNode(e,"IfStatement")}parseReturnStatement(e){return this.scope.inFunction||this.options.allowReturnOutsideFunction||this.raise(this.state.start,"'return' outside of function"),this.next(),this.isLineTerminator()?e.argument=null:(e.argument=this.parseExpression(),this.semicolon()),this.finishNode(e,"ReturnStatement")}parseSwitchStatement(e){this.next(),e.discriminant=this.parseHeaderExpression();const t=e.cases=[];let n,r;for(this.expect(s.braceL),this.state.labels.push(ye),this.scope.enter(0);!this.match(s.braceR);)if(this.match(s._case)||this.match(s._default)){const e=this.match(s._case);n&&this.finishNode(n,"SwitchCase"),t.push(n=this.startNode()),n.consequent=[],this.next(),e?n.test=this.parseExpression():(r&&this.raise(this.state.lastTokStart,"Multiple default clauses"),r=!0,n.test=null),this.expect(s.colon)}else n?n.consequent.push(this.parseStatement(null)):this.unexpected();return this.scope.exit(),n&&this.finishNode(n,"SwitchCase"),this.next(),this.state.labels.pop(),this.finishNode(e,"SwitchStatement")}parseThrowStatement(e){return this.next(),l.test(this.input.slice(this.state.lastTokEnd,this.state.start))&&this.raise(this.state.lastTokEnd,"Illegal newline after throw"),e.argument=this.parseExpression(),this.semicolon(),this.finishNode(e,"ThrowStatement")}parseTryStatement(e){if(this.next(),e.block=this.parseBlock(),e.handler=null,this.match(s._catch)){const t=this.startNode();if(this.next(),this.match(s.parenL)){this.expect(s.parenL),t.param=this.parseBindingAtom();const e="Identifier"===t.param.type;this.scope.enter(e?32:0),this.checkLVal(t.param,9,null,"catch clause"),this.expect(s.parenR)}else t.param=null,this.scope.enter(0);t.body=this.withTopicForbiddingContext(()=>this.parseBlock(!1,!1)),this.scope.exit(),e.handler=this.finishNode(t,"CatchClause")}return e.finalizer=this.eat(s._finally)?this.parseBlock():null,e.handler||e.finalizer||this.raise(e.start,"Missing catch or finally clause"),this.finishNode(e,"TryStatement")}parseVarStatement(e,t){return this.next(),this.parseVar(e,!1,t),this.semicolon(),this.finishNode(e,"VariableDeclaration")}parseWhileStatement(e){return this.next(),e.test=this.parseHeaderExpression(),this.state.labels.push(de),e.body=this.withTopicForbiddingContext(()=>this.parseStatement("while")),this.state.labels.pop(),this.finishNode(e,"WhileStatement")}parseWithStatement(e){return this.state.strict&&this.raise(this.state.start,"'with' in strict mode"),this.next(),e.object=this.parseHeaderExpression(),e.body=this.withTopicForbiddingContext(()=>this.parseStatement("with")),this.finishNode(e,"WithStatement")}parseEmptyStatement(e){return this.next(),this.finishNode(e,"EmptyStatement")}parseLabeledStatement(e,t,n,r){for(let e=0,r=this.state.labels;e=0;t--){const n=this.state.labels[t];if(n.statementStart!==e.start)break;n.statementStart=this.state.start,n.kind=i}return this.state.labels.push({name:t,kind:i,statementStart:this.state.start}),e.body=this.parseStatement(r?-1===r.indexOf("label")?r+"label":r:"label"),this.state.labels.pop(),e.label=n,this.finishNode(e,"LabeledStatement")}parseExpressionStatement(e,t){return e.expression=t,this.semicolon(),this.finishNode(e,"ExpressionStatement")}parseBlock(e=!1,t=!0){const n=this.startNode();return this.expect(s.braceL),t&&this.scope.enter(0),this.parseBlockBody(n,e,!1,s.braceR),t&&this.scope.exit(),this.finishNode(n,"BlockStatement")}isValidDirective(e){return"ExpressionStatement"===e.type&&"StringLiteral"===e.expression.type&&!e.expression.extra.parenthesized}parseBlockBody(e,t,n,r){const i=e.body=[],o=e.directives=[];this.parseBlockOrModuleBlockBody(i,t?o:void 0,n,r)}parseBlockOrModuleBlockBody(e,t,n,r){let i,o,a=!1;for(;!this.eat(r);){a||!this.state.containsOctal||o||(o=this.state.octalPosition);const r=this.parseStatement(null,n);if(t&&!a&&this.isValidDirective(r)){const e=this.stmtToDirective(r);t.push(e),void 0===i&&"use strict"===e.value.value&&(i=this.state.strict,this.setStrict(!0),o&&this.raise(o,"Octal literal in strict mode"))}else a=!0,e.push(r)}!1===i&&this.setStrict(!1)}parseFor(e,t){return e.init=t,this.expect(s.semi),e.test=this.match(s.semi)?null:this.parseExpression(),this.expect(s.semi),e.update=this.match(s.parenR)?null:this.parseExpression(),this.expect(s.parenR),e.body=this.withTopicForbiddingContext(()=>this.parseStatement("for")),this.scope.exit(),this.state.labels.pop(),this.finishNode(e,"ForStatement")}parseForIn(e,t,n){const r=this.match(s._in);return this.next(),r?n>-1&&this.unexpected(n):e.await=n>-1,"VariableDeclaration"!==t.type||null==t.declarations[0].init||r&&!this.state.strict&&"var"===t.kind&&"Identifier"===t.declarations[0].id.type?"AssignmentPattern"===t.type&&this.raise(t.start,"Invalid left-hand side in for-loop"):this.raise(t.start,`${r?"for-in":"for-of"} loop variable declaration may not have an initializer`),e.left=t,e.right=r?this.parseExpression():this.parseMaybeAssign(),this.expect(s.parenR),e.body=this.withTopicForbiddingContext(()=>this.parseStatement("for")),this.scope.exit(),this.state.labels.pop(),this.finishNode(e,r?"ForInStatement":"ForOfStatement")}parseVar(e,t,n){const r=e.declarations=[],i=this.hasPlugin("typescript");for(e.kind=n;;){const e=this.startNode();if(this.parseVarId(e,n),this.eat(s.eq)?e.init=this.parseMaybeAssign(t):("const"!==n||this.match(s._in)||this.isContextual("of")?"Identifier"===e.id.type||t&&(this.match(s._in)||this.isContextual("of"))||this.raise(this.state.lastTokEnd,"Complex binding patterns require an initialization value"):i||this.unexpected(),e.init=null),r.push(this.finishNode(e,"VariableDeclarator")),!this.eat(s.comma))break}return e}parseVarId(e,t){e.id=this.parseBindingAtom(),this.checkLVal(e.id,"var"===t?5:9,void 0,"variable declaration","var"!==t)}parseFunction(e,t=0,n=!1){const r=1&t,i=2&t,o=!(!r||4&t);this.initFunction(e,n),this.match(s.star)&&i&&this.raise(this.state.start,"Generators can only be declared at the top level or inside a block"),e.generator=this.eat(s.star),r&&(e.id=this.parseFunctionId(o));const a=this.state.maybeInArrowParameters,c=this.state.inClassProperty,l=this.state.yieldPos,f=this.state.awaitPos;return this.state.maybeInArrowParameters=!1,this.state.inClassProperty=!1,this.state.yieldPos=-1,this.state.awaitPos=-1,this.scope.enter(u(e.async,e.generator)),r||(e.id=this.parseFunctionId()),this.parseFunctionParams(e),this.withTopicForbiddingContext(()=>{this.parseFunctionBodyAndFinish(e,r?"FunctionDeclaration":"FunctionExpression")}),this.scope.exit(),r&&!i&&this.registerFunctionStatementId(e),this.state.maybeInArrowParameters=a,this.state.inClassProperty=c,this.state.yieldPos=l,this.state.awaitPos=f,e}parseFunctionId(e){return e||this.match(s.name)?this.parseIdentifier():null}parseFunctionParams(e,t){const n=this.state.inParameters;this.state.inParameters=!0,this.expect(s.parenL),e.params=this.parseBindingList(s.parenR,41,!1,t),this.state.inParameters=n,this.checkYieldAwaitInDefaultParams()}registerFunctionStatementId(e){e.id&&this.scope.declareName(e.id.name,this.state.strict||e.generator||e.async?this.scope.treatFunctionsAsVar?5:9:17,e.id.start)}parseClass(e,t,n){this.next(),this.takeDecorators(e);const r=this.state.strict;return this.state.strict=!0,this.parseClassId(e,t,n),this.parseClassSuper(e),e.body=this.parseClassBody(!!e.superClass),this.state.strict=r,this.finishNode(e,t?"ClassDeclaration":"ClassExpression")}isClassProperty(){return this.match(s.eq)||this.match(s.semi)||this.match(s.braceR)}isClassMethod(){return this.match(s.parenL)}isNonstaticConstructor(e){return!(e.computed||e.static||"constructor"!==e.key.name&&"constructor"!==e.key.value)}parseClassBody(e){this.state.classLevel++;const t={hadConstructor:!1};let n=[];const r=this.startNode();if(r.body=[],this.expect(s.braceL),this.withTopicForbiddingContext(()=>{for(;!this.eat(s.braceR);){if(this.eat(s.semi)){if(n.length>0)throw this.raise(this.state.lastTokEnd,"Decorators must not be followed by a semicolon");continue}if(this.match(s.at)){n.push(this.parseDecorator());continue}const i=this.startNode();n.length&&(i.decorators=n,this.resetStartLocationFromNode(i,n[0]),n=[]),this.parseClassMember(r,i,t,e),"constructor"===i.kind&&i.decorators&&i.decorators.length>0&&this.raise(i.start,"Decorators can't be used with a constructor. Did you mean '@dec class { ... }'?")}}),n.length)throw this.raise(this.state.start,"You have trailing decorators with no method");return this.state.classLevel--,this.finishNode(r,"ClassBody")}parseClassMember(e,t,n,r){let i=!1;const o=this.state.containsEsc;if(this.match(s.name)&&"static"===this.state.value){const n=this.parseIdentifier(!0);if(this.isClassMethod()){const r=t;return r.kind="method",r.computed=!1,r.key=n,r.static=!1,void this.pushClassMethod(e,r,!1,!1,!1,!1)}if(this.isClassProperty()){const r=t;return r.computed=!1,r.key=n,r.static=!1,void e.body.push(this.parseClassProperty(r))}if(o)throw this.unexpected();i=!0}this.parseClassMemberWithIsStatic(e,t,n,i,r)}parseClassMemberWithIsStatic(e,t,n,r,i){const o=t,a=t,u=t,c=t,l=o,f=o;if(t.static=r,this.eat(s.star))return l.kind="method",this.parseClassPropertyName(l),"PrivateName"===l.key.type?void this.pushClassPrivateMethod(e,a,!0,!1):(this.isNonstaticConstructor(o)&&this.raise(o.key.start,"Constructor can't be a generator"),void this.pushClassMethod(e,o,!0,!1,!1,!1));const p=this.state.containsEsc,h=this.parseClassPropertyName(t),d="PrivateName"===h.type,y="Identifier"===h.type,m=this.state.start;if(this.parsePostMemberNameModifiers(f),this.isClassMethod()){if(l.kind="method",d)return void this.pushClassPrivateMethod(e,a,!1,!1);const t=this.isNonstaticConstructor(o);let r=!1;t&&(o.kind="constructor",n.hadConstructor&&!this.hasPlugin("typescript")&&this.raise(h.start,"Duplicate constructor in the same class"),n.hadConstructor=!0,r=i),this.pushClassMethod(e,o,!1,!1,t,r)}else if(this.isClassProperty())d?this.pushClassPrivateProperty(e,c):this.pushClassProperty(e,u);else if(!y||"async"!==h.name||p||this.isLineTerminator())!y||"get"!==h.name&&"set"!==h.name||p||this.match(s.star)&&this.isLineTerminator()?this.isLineTerminator()?d?this.pushClassPrivateProperty(e,c):this.pushClassProperty(e,u):this.unexpected():(l.kind=h.name,this.parseClassPropertyName(o),"PrivateName"===l.key.type?this.pushClassPrivateMethod(e,a,!1,!1):(this.isNonstaticConstructor(o)&&this.raise(o.key.start,"Constructor can't have get/set modifier"),this.pushClassMethod(e,o,!1,!1,!1,!1)),this.checkGetterSetterParams(o));else{const t=this.eat(s.star);f.optional&&this.unexpected(m),l.kind="method",this.parseClassPropertyName(l),this.parsePostMemberNameModifiers(f),"PrivateName"===l.key.type?this.pushClassPrivateMethod(e,a,t,!0):(this.isNonstaticConstructor(o)&&this.raise(o.key.start,"Constructor can't be an async function"),this.pushClassMethod(e,o,t,!0,!1,!1))}}parseClassPropertyName(e){const t=this.parsePropertyName(e);return e.computed||!e.static||"prototype"!==t.name&&"prototype"!==t.value||this.raise(t.start,"Classes may not have static property named prototype"),"PrivateName"===t.type&&"constructor"===t.id.name&&this.raise(t.start,"Classes may not have a private field named '#constructor'"),t}pushClassProperty(e,t){t.computed||"constructor"!==t.key.name&&"constructor"!==t.key.value||this.raise(t.key.start,"Classes may not have a field named 'constructor'"),e.body.push(this.parseClassProperty(t))}pushClassPrivateProperty(e,t){this.expectPlugin("classPrivateProperties",t.key.start),e.body.push(this.parseClassPrivateProperty(t))}pushClassMethod(e,t,n,r,i,o){e.body.push(this.parseMethod(t,n,r,i,o,"ClassMethod",!0))}pushClassPrivateMethod(e,t,n,r){this.expectPlugin("classPrivateMethods",t.key.start),e.body.push(this.parseMethod(t,n,r,!1,!1,"ClassPrivateMethod",!0))}parsePostMemberNameModifiers(e){}parseAccessModifier(){}parseClassPrivateProperty(e){return this.state.inClassProperty=!0,this.scope.enter(320),e.value=this.eat(s.eq)?this.parseMaybeAssign():null,this.semicolon(),this.state.inClassProperty=!1,this.scope.exit(),this.finishNode(e,"ClassPrivateProperty")}parseClassProperty(e){return e.typeAnnotation||this.expectPlugin("classProperties"),this.state.inClassProperty=!0,this.scope.enter(320),this.match(s.eq)?(this.expectPlugin("classProperties"),this.next(),e.value=this.parseMaybeAssign()):e.value=null,this.semicolon(),this.state.inClassProperty=!1,this.scope.exit(),this.finishNode(e,"ClassProperty")}parseClassId(e,t,n,r=139){this.match(s.name)?(e.id=this.parseIdentifier(),t&&this.checkLVal(e.id,r,void 0,"class name")):n||!t?e.id=null:this.unexpected(null,"A class name is required")}parseClassSuper(e){e.superClass=this.eat(s._extends)?this.parseExprSubscripts():null}parseExport(e){const t=this.maybeParseExportDefaultSpecifier(e),n=!t||this.eat(s.comma),r=n&&this.eatExportStar(e),i=r&&this.maybeParseExportNamespaceSpecifier(e),o=n&&(!i||this.eat(s.comma)),a=t||r;if(r&&!i)return t&&this.unexpected(),this.parseExportFrom(e,!0),this.finishNode(e,"ExportAllDeclaration");const u=this.maybeParseExportNamedSpecifiers(e);if(t&&n&&!r&&!u||i&&o&&!u)throw this.unexpected(null,s.braceL);let c;if(a||u?(c=!1,this.parseExportFrom(e,a)):c=this.maybeParseExportDeclaration(e),a||u||c)return this.checkExport(e,!0,!1,!!e.source),this.finishNode(e,"ExportNamedDeclaration");if(this.eat(s._default))return e.declaration=this.parseExportDefaultExpression(),this.checkExport(e,!0,!0),this.finishNode(e,"ExportDefaultDeclaration");throw this.unexpected(null,s.braceL)}eatExportStar(e){return this.eat(s.star)}maybeParseExportDefaultSpecifier(e){if(this.isExportDefaultSpecifier()){this.expectPlugin("exportDefaultFrom");const t=this.startNode();return t.exported=this.parseIdentifier(!0),e.specifiers=[this.finishNode(t,"ExportDefaultSpecifier")],!0}return!1}maybeParseExportNamespaceSpecifier(e){if(this.isContextual("as")){e.specifiers||(e.specifiers=[]);const t=this.startNodeAt(this.state.lastTokStart,this.state.lastTokStartLoc);return this.next(),t.exported=this.parseIdentifier(!0),e.specifiers.push(this.finishNode(t,"ExportNamespaceSpecifier")),!0}return!1}maybeParseExportNamedSpecifiers(e){return!!this.match(s.braceL)&&(e.specifiers||(e.specifiers=[]),e.specifiers.push(...this.parseExportSpecifiers()),e.source=null,e.declaration=null,!0)}maybeParseExportDeclaration(e){if(this.shouldParseExportDeclaration()){if(this.isContextual("async")){const e=this.nextTokenStart();this.isUnparsedContextual(e,"function")||this.unexpected(e,'Unexpected token, expected "function"')}return e.specifiers=[],e.source=null,e.declaration=this.parseExportDeclaration(e),!0}return!1}isAsyncFunction(){if(!this.isContextual("async"))return!1;const e=this.nextTokenStart();return!l.test(this.input.slice(this.state.pos,e))&&this.isUnparsedContextual(e,"function")}parseExportDefaultExpression(){const e=this.startNode(),t=this.isAsyncFunction();if(this.match(s._function)||t)return this.next(),t&&this.next(),this.parseFunction(e,5,t);if(this.match(s._class))return this.parseClass(e,!0,!0);if(this.match(s.at))return this.hasPlugin("decorators")&&this.getPluginOption("decorators","decoratorsBeforeExport")&&this.raise(this.state.start,"Decorators must be placed *before* the 'export' keyword. You can set the 'decoratorsBeforeExport' option to false to use the 'export @decorator class {}' syntax"),this.parseDecorators(!1),this.parseClass(e,!0,!0);if(this.match(s._const)||this.match(s._var)||this.isLet())throw this.raise(this.state.start,"Only expressions, functions or classes are allowed as the `default` export.");{const e=this.parseMaybeAssign();return this.semicolon(),e}}parseExportDeclaration(e){return this.parseStatement(null)}isExportDefaultSpecifier(){if(this.match(s.name))return"async"!==this.state.value&&"let"!==this.state.value;if(!this.match(s._default))return!1;const e=this.nextTokenStart();return 44===this.input.charCodeAt(e)||this.isUnparsedContextual(e,"from")}parseExportFrom(e,t){this.eatContextual("from")?(e.source=this.parseImportSource(),this.checkExport(e)):t?this.unexpected():e.source=null,this.semicolon()}shouldParseExportDeclaration(){if(this.match(s.at)&&(this.expectOnePlugin(["decorators","decorators-legacy"]),this.hasPlugin("decorators"))){if(!this.getPluginOption("decorators","decoratorsBeforeExport"))return!0;this.unexpected(this.state.start,"Decorators must be placed *before* the 'export' keyword. You can set the 'decoratorsBeforeExport' option to false to use the 'export @decorator class {}' syntax")}return"var"===this.state.type.keyword||"const"===this.state.type.keyword||"function"===this.state.type.keyword||"class"===this.state.type.keyword||this.isLet()||this.isAsyncFunction()}checkExport(e,t,n,r){if(t)if(n)this.checkDuplicateExports(e,"default");else if(e.specifiers&&e.specifiers.length)for(let t=0,n=e.specifiers;t-1&&this.raise(e.start,"default"===t?"Only one default export allowed per module.":`\`${t}\` has already been exported. Exported identifiers must be unique.`),this.state.exportedIdentifiers.push(t)}parseExportSpecifiers(){const e=[];let t=!0;for(this.expect(s.braceL);!this.eat(s.braceR);){if(t)t=!1;else if(this.expect(s.comma),this.eat(s.braceR))break;const n=this.startNode();n.local=this.parseIdentifier(!0),n.exported=this.eatContextual("as")?this.parseIdentifier(!0):n.local.__clone(),e.push(this.finishNode(n,"ExportSpecifier"))}return e}parseImport(e){if(e.specifiers=[],!this.match(s.string)){const t=!this.maybeParseDefaultImportSpecifier(e)||this.eat(s.comma),n=t&&this.maybeParseStarImportSpecifier(e);t&&!n&&this.parseNamedImportSpecifiers(e),this.expectContextual("from")}return e.source=this.parseImportSource(),this.semicolon(),this.finishNode(e,"ImportDeclaration")}parseImportSource(){return this.match(s.string)||this.unexpected(),this.parseExprAtom()}shouldParseDefaultImport(e){return this.match(s.name)}parseImportSpecifierLocal(e,t,n,r){t.local=this.parseIdentifier(),this.checkLVal(t.local,9,void 0,r),e.specifiers.push(this.finishNode(t,n))}maybeParseDefaultImportSpecifier(e){return!!this.shouldParseDefaultImport(e)&&(this.parseImportSpecifierLocal(e,this.startNode(),"ImportDefaultSpecifier","default import specifier"),!0)}maybeParseStarImportSpecifier(e){if(this.match(s.star)){const t=this.startNode();return this.next(),this.expectContextual("as"),this.parseImportSpecifierLocal(e,t,"ImportNamespaceSpecifier","import namespace specifier"),!0}return!1}parseNamedImportSpecifiers(e){let t=!0;for(this.expect(s.braceL);!this.eat(s.braceR);){if(t)t=!1;else{if(this.eat(s.colon))throw this.raise(this.state.start,"ES2015 named imports do not destructure. Use another statement for destructuring after the import.");if(this.expect(s.comma),this.eat(s.braceR))break}this.parseImportSpecifier(e)}}parseImportSpecifier(e){const t=this.startNode();t.imported=this.parseIdentifier(!0),this.eatContextual("as")?t.local=this.parseIdentifier():(this.checkReservedWord(t.imported.name,t.start,!0,!0),t.local=t.imported.__clone()),this.checkLVal(t.local,9,void 0,"import specifier"),e.specifiers.push(this.finishNode(t,"ImportSpecifier"))}}{constructor(e,t){super(e=function(e){const t={};for(let n=0,r=Object.keys(te);n`'${e}'`).join(", "))}(e.plugins),n=function(e){const t=ee.filter(t=>q(e,t)),n=t.join("/");let r=be[n];if(!r){r=me;for(let e=0;e!0}],e.set(n,o);break;case"invalidate":o=[{value:s,valid:a.validator()}],e.set(n,o);break;case"valid":o?o.push({value:s,valid:a.validator()}):(o=[{value:s,valid:a.validator()}],e.set(n,o))}return s}}Object.defineProperty(t,"__esModule",{value:!0}),t.makeStrongCache=function(e){return r(new Map,e)},t.makeWeakCache=function(e){return r(new WeakMap,e)},t.assertSimpleType=o;class i{constructor(e){this._active=!0,this._never=!1,this._forever=!1,this._invalidate=!1,this._configured=!1,this._pairs=[],this._data=e}simple(){return function(e){function t(t){if("boolean"!=typeof t)return e.using(()=>o(t()));t?e.forever():e.never()}return t.forever=()=>e.forever(),t.never=()=>e.never(),t.using=t=>e.using(()=>o(t())),t.invalidate=t=>e.invalidate(()=>o(t())),t}(this)}mode(){return this._never?"never":this._forever?"forever":this._invalidate?"invalidate":"valid"}forever(){if(!this._active)throw new Error("Cannot change caching after evaluation has completed.");if(this._never)throw new Error("Caching has already been configured with .never()");this._forever=!0,this._configured=!0}never(){if(!this._active)throw new Error("Cannot change caching after evaluation has completed.");if(this._forever)throw new Error("Caching has already been configured with .forever()");this._never=!0,this._configured=!0}using(e){if(!this._active)throw new Error("Cannot change caching after evaluation has completed.");if(this._never||this._forever)throw new Error("Caching has already been configured with .never or .forever()");this._configured=!0;const t=e(this._data);return this._pairs.push([t,e]),t}invalidate(e){if(!this._active)throw new Error("Cannot change caching after evaluation has completed.");if(this._never||this._forever)throw new Error("Caching has already been configured with .never or .forever()");this._invalidate=!0,this._configured=!0;const t=e(this._data);return this._pairs.push([t,e]),t}validator(){const e=this._pairs;return t=>e.every(([e,n])=>e===n(t))}deactivate(){this._active=!1}configured(){return this._configured}}function o(e){if(null!=e&&"string"!=typeof e&&"boolean"!=typeof e&&"number"!=typeof e)throw new Error("Cache keys must be either string, boolean, number, null, or undefined.");return e}},function(e,t,n){var r=n(23);e.exports=function(e){if("string"==typeof e||r(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Plugin=function(e){throw new Error(`The (${e}) Babel 5 plugin is being run with an unsupported Babel version.`)},Object.defineProperty(t,"File",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"buildExternalHelpers",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"resolvePlugin",{enumerable:!0,get:function(){return o.resolvePlugin}}),Object.defineProperty(t,"resolvePreset",{enumerable:!0,get:function(){return o.resolvePreset}}),Object.defineProperty(t,"version",{enumerable:!0,get:function(){return a.version}}),Object.defineProperty(t,"getEnv",{enumerable:!0,get:function(){return s.getEnv}}),Object.defineProperty(t,"tokTypes",{enumerable:!0,get:function(){return function(){const e=n(38);return function(){return e},e}().tokTypes}}),Object.defineProperty(t,"traverse",{enumerable:!0,get:function(){return function(){const e=m(n(7));return function(){return e},e}().default}}),Object.defineProperty(t,"template",{enumerable:!0,get:function(){return function(){const e=m(n(39));return function(){return e},e}().default}}),Object.defineProperty(t,"createConfigItem",{enumerable:!0,get:function(){return c.createConfigItem}}),Object.defineProperty(t,"loadPartialConfig",{enumerable:!0,get:function(){return l.loadPartialConfig}}),Object.defineProperty(t,"loadOptions",{enumerable:!0,get:function(){return l.loadOptions}}),Object.defineProperty(t,"transform",{enumerable:!0,get:function(){return f.transform}}),Object.defineProperty(t,"transformSync",{enumerable:!0,get:function(){return f.transformSync}}),Object.defineProperty(t,"transformAsync",{enumerable:!0,get:function(){return f.transformAsync}}),Object.defineProperty(t,"transformFile",{enumerable:!0,get:function(){return p.transformFile}}),Object.defineProperty(t,"transformFileSync",{enumerable:!0,get:function(){return p.transformFileSync}}),Object.defineProperty(t,"transformFileAsync",{enumerable:!0,get:function(){return p.transformFileAsync}}),Object.defineProperty(t,"transformFromAst",{enumerable:!0,get:function(){return h.transformFromAst}}),Object.defineProperty(t,"transformFromAstSync",{enumerable:!0,get:function(){return h.transformFromAstSync}}),Object.defineProperty(t,"transformFromAstAsync",{enumerable:!0,get:function(){return h.transformFromAstAsync}}),Object.defineProperty(t,"parse",{enumerable:!0,get:function(){return d.parse}}),Object.defineProperty(t,"parseSync",{enumerable:!0,get:function(){return d.parseSync}}),Object.defineProperty(t,"parseAsync",{enumerable:!0,get:function(){return d.parseAsync}}),t.types=t.OptionManager=t.DEFAULT_EXTENSIONS=void 0;var r=m(n(78)),i=m(n(360)),o=n(40),a=n(361),s=n(137);function u(){const e=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=y();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(n(0));return u=function(){return e},e}Object.defineProperty(t,"types",{enumerable:!0,get:function(){return u()}});var c=n(41),l=n(25),f=n(368),p=n(410),h=n(411),d=n(412);function y(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return y=function(){return e},e}function m(e){return e&&e.__esModule?e:{default:e}}const v=Object.freeze([".js",".jsx",".es6",".es",".mjs"]);t.DEFAULT_EXTENSIONS=v;t.OptionManager=class{init(e){return(0,l.loadOptions)(e)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){const n=Object.keys(t);for(const r of n)if(e[r]!==t[r])return!1;return!0}},function(e,t,n){var r=n(26),i=n(171),o=n(172),a=n(173),s=n(174),u=n(175);function c(e){var t=this.__data__=new r(e);this.size=t.size}c.prototype.clear=i,c.prototype.delete=o,c.prototype.get=a,c.prototype.has=s,c.prototype.set=u,e.exports=c},function(e,t,n){var r=n(13)(n(5),"Map");e.exports=r},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){var r=n(182),i=n(189),o=n(191),a=n(192),s=n(193);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t-1&&e%1==0&&e-1&&e%1==0&&e<=9007199254740991}},function(e,t){var n=Object.prototype;e.exports=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||n)}},function(e,t,n){var r=n(91),i=n(203),o=n(18);e.exports=function(e){return o(e)?r(e,!0):i(e)}},function(e,t,n){var r=n(208),i=n(94),o=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,s=a?function(e){return null==e?[]:(e=Object(e),r(a(e),(function(t){return o.call(e,t)})))}:i;e.exports=s},function(e,t){e.exports=function(e,t){for(var n=-1,r=t.length,i=e.length;++n{"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(280)(t);const{formatters:i}=e.exports;i.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(9))},function(e,t,n){var r=n(110),i=n(18),o=n(282),a=n(69),s=n(285),u=Math.max;e.exports=function(e,t,n,c){e=i(e)?e:s(e),n=n&&!c?a(n):0;var l=e.length;return n<0&&(n=u(l+n,0)),o(e)?n<=l&&e.indexOf(t,n)>-1:!!l&&r(e,t,n)>-1}},function(e,t,n){var r=n(283);e.exports=function(e){var t=r(e),n=t%1;return t==t?n?t-n:t:0}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,i=Array(r);++nn.comments)):n.shouldPrintComment=n.shouldPrintComment||(e=>n.comments||e.indexOf("@license")>=0||e.indexOf("@preserve")>=0);"auto"===n.compact&&(n.compact=e.length>5e5,n.compact&&console.error("[BABEL] Note: The code generator has deoptimised the styling of "+`${t.filename} as it exceeds the max of 500KB.`));n.compact&&(n.indent.adjustMultilineComment=!1);return n}(n,t),t.sourceMaps?new r.default(t,n):null),this.ast=e}generate(){return super.generate(this.ast)}}t.CodeGenerator=class{constructor(e,t,n){this._generator=new a(e,t,n)}generate(){return this._generator.generate()}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.merge=function(e,t){const{placeholderWhitelist:n=e.placeholderWhitelist,placeholderPattern:r=e.placeholderPattern,preserveComments:i=e.preserveComments,syntacticPlaceholders:o=e.syntacticPlaceholders}=t;return{parser:Object.assign({},e.parser,{},t.parser),placeholderWhitelist:n,placeholderPattern:r,preserveComments:i,syntacticPlaceholders:o}},t.validate=function(e){if(null!=e&&"object"!=typeof e)throw new Error("Unknown template options.");const t=e||{},{placeholderWhitelist:n,placeholderPattern:r,preserveComments:i,syntacticPlaceholders:o}=t,a=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}(t,["placeholderWhitelist","placeholderPattern","preserveComments","syntacticPlaceholders"]);if(null!=n&&!(n instanceof Set))throw new Error("'.placeholderWhitelist' must be a Set, null, or undefined");if(null!=r&&!(r instanceof RegExp)&&!1!==r)throw new Error("'.placeholderPattern' must be a RegExp, false, null, or undefined");if(null!=i&&"boolean"!=typeof i)throw new Error("'.preserveComments' must be a boolean, null, or undefined");if(null!=o&&"boolean"!=typeof o)throw new Error("'.syntacticPlaceholders' must be a boolean, null, or undefined");if(!0===o&&(null!=n||null!=r))throw new Error("'.placeholderWhitelist' and '.placeholderPattern' aren't compatible with '.syntacticPlaceholders: true'");return{parser:a,placeholderWhitelist:n||void 0,placeholderPattern:null==r?void 0:r,preserveComments:null!=i&&i,syntacticPlaceholders:null==o?void 0:o}},t.normalizeReplacements=function(e){if(Array.isArray(e))return e.reduce((e,t,n)=>(e["$"+n]=t,e),{});if("object"==typeof e||null==e)return e||void 0;throw new Error("Template replacements must be an array, object, null, or undefined")}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{constructor(e,t,n){this.key=e.name||n,this.manipulateOptions=e.manipulateOptions,this.post=e.post,this.pre=e.pre,this.visitor=e.visitor||{},this.parserOverride=e.parserOverride,this.generatorOverride=e.generatorOverride,this.options=t}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validate=function(e,t){return l({type:"root",source:e},t)};o(n(75));var r=o(n(363)),i=n(141);function o(e){return e&&e.__esModule?e:{default:e}}const a={cwd:i.assertString,root:i.assertString,rootMode:i.assertRootMode,configFile:i.assertConfigFileSearch,caller:i.assertCallerMetadata,filename:i.assertString,filenameRelative:i.assertString,code:i.assertBoolean,ast:i.assertBoolean,envName:i.assertString},s={babelrc:i.assertBoolean,babelrcRoots:i.assertBabelrcSearch},u={extends:i.assertString,ignore:i.assertIgnoreList,only:i.assertIgnoreList},c={inputSourceMap:i.assertInputSourceMap,presets:i.assertPluginList,plugins:i.assertPluginList,passPerPreset:i.assertBoolean,env:function(e,t){if("env"===e.parent.type)throw new Error(`${(0,i.msg)(e)} is not allowed inside of another .env block`);const n=e.parent,r=(0,i.assertObject)(e,t);if(r)for(const t of Object.keys(r)){const o=(0,i.assertObject)((0,i.access)(e,t),r[t]);o&&l({type:"env",name:t,parent:n},o)}return r},overrides:function(e,t){if("env"===e.parent.type)throw new Error(`${(0,i.msg)(e)} is not allowed inside an .env block`);if("overrides"===e.parent.type)throw new Error(`${(0,i.msg)(e)} is not allowed inside an .overrides block`);const n=e.parent,r=(0,i.assertArray)(e,t);if(r)for(const[t,o]of r.entries()){const r=(0,i.access)(e,t),a=(0,i.assertObject)(r,o);if(!a)throw new Error(`${(0,i.msg)(r)} must be an object`);l({type:"overrides",index:t,parent:n},a)}return r},test:i.assertConfigApplicableTest,include:i.assertConfigApplicableTest,exclude:i.assertConfigApplicableTest,retainLines:i.assertBoolean,comments:i.assertBoolean,shouldPrintComment:i.assertFunction,compact:i.assertCompact,minified:i.assertBoolean,auxiliaryCommentBefore:i.assertString,auxiliaryCommentAfter:i.assertString,sourceType:i.assertSourceType,wrapPluginVisitorMethod:i.assertFunction,highlightCode:i.assertBoolean,sourceMaps:i.assertSourceMaps,sourceMap:i.assertSourceMaps,sourceFileName:i.assertString,sourceRoot:i.assertString,getModuleId:i.assertFunction,moduleRoot:i.assertString,moduleIds:i.assertBoolean,moduleId:i.assertString,parserOpts:i.assertObject,generatorOpts:i.assertObject};function l(e,t){const n=function e(t){return"root"===t.type?t.source:e(t.parent)}(e);return function(e){if(p(e,"sourceMap")&&p(e,"sourceMaps"))throw new Error(".sourceMap is an alias for .sourceMaps, cannot use both")}(t),Object.keys(t).forEach(r=>{const o={type:"option",name:r,parent:e};if("preset"===n&&u[r])throw new Error(`${(0,i.msg)(o)} is not allowed in preset options`);if("arguments"!==n&&a[r])throw new Error(`${(0,i.msg)(o)} is only allowed in root programmatic options`);if("arguments"!==n&&"configfile"!==n&&s[r]){if("babelrcfile"===n||"extendsfile"===n)throw new Error(`${(0,i.msg)(o)} is not allowed in .babelrc or "extends"ed files, only in root programmatic options, `+"or babel.config.js/config file options");throw new Error(`${(0,i.msg)(o)} is only allowed in root programmatic options, or babel.config.js/config file options`)}(c[r]||u[r]||s[r]||a[r]||f)(o,t[r])}),t}function f(e){const t=e.name;if(r.default[t]){const{message:n,version:o=5}=r.default[t];throw new ReferenceError(`Using removed Babel ${o} option: ${(0,i.msg)(e)} - ${n}`)}{const t=`Unknown option: ${(0,i.msg)(e)}. Check out https://babeljs.io/docs/en/babel-core/#options for more information about options.`;throw new ReferenceError(t)}}function p(e,t){return Object.prototype.hasOwnProperty.call(e,t)}},function(e,t,n){var r=n(4),i=n(23),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;e.exports=function(e,t){if(r(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!i(e))||(a.test(e)||!o.test(e)||null!=t&&e in Object(t))}},function(e,t,n){"use strict";function r(){const e=c(n(79));return r=function(){return e},e}function i(){const e=c(n(7));return i=function(){return e},e}function o(){const e=n(37);return o=function(){return e},e}function a(){const e=c(n(0));return a=function(){return e},e}function s(){const e=(t=n(136))&&t.__esModule?t:{default:t};var t;return s=function(){return e},e}function u(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return u=function(){return e},e}function c(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=u();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}return n.default=e,t&&t.set(e,n),n}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;const l={enter(e,t){const n=e.node.loc;n&&(t.loc=n,e.stop())}};t.default=class{constructor(e,{code:t,ast:n,inputMap:r}){this._map=new Map,this.declarations={},this.path=null,this.ast={},this.metadata={},this.code="",this.inputMap=null,this.hub={file:this,getCode:()=>this.code,getScope:()=>this.scope,addHelper:this.addHelper.bind(this),buildError:this.buildCodeFrameError.bind(this)},this.opts=e,this.code=t,this.ast=n,this.inputMap=r,this.path=i().NodePath.get({hub:this.hub,parentPath:null,parent:this.ast,container:this.ast,key:"program"}).setContext(),this.scope=this.path.scope}get shebang(){const{interpreter:e}=this.path.node;return e?e.value:""}set shebang(e){e?this.path.get("interpreter").replaceWith(a().interpreterDirective(e)):this.path.get("interpreter").remove()}set(e,t){if("helpersNamespace"===e)throw new Error("Babel 7.0.0-beta.56 has dropped support for the 'helpersNamespace' utility.If you are using @babel/plugin-external-helpers you will need to use a newer version than the one you currently have installed. If you have your own implementation, you'll want to explore using 'helperGenerator' alongside 'file.availableHelper()'.");this._map.set(e,t)}get(e){return this._map.get(e)}has(e){return this._map.has(e)}getModuleName(){const{filename:e,filenameRelative:t=e,moduleId:n,moduleIds:r=!!n,getModuleId:i,sourceRoot:o,moduleRoot:a=o,sourceRoot:s=a}=this.opts;if(!r)return null;if(null!=n&&!i)return n;let u=null!=a?a+"/":"";if(t){const e=null!=s?new RegExp("^"+s+"/?"):"";u+=t.replace(e,"").replace(/\.(\w*?)$/,"")}return u=u.replace(/\\/g,"/"),i&&i(u)||u}addImport(){throw new Error("This API has been removed. If you're looking for this functionality in Babel 7, you should import the '@babel/helper-module-imports' module and use the functions exposed from that module, such as 'addNamed' or 'addDefault'.")}availableHelper(e,t){let n;try{n=r().minVersion(e)}catch(e){if("BABEL_HELPER_UNKNOWN"!==e.code)throw e;return!1}return"string"!=typeof t||(s().default.valid(t)&&(t=`^${t}`),!s().default.intersects(`<${n}`,t)&&!s().default.intersects(">=8.0.0",t))}addHelper(e){const t=this.declarations[e];if(t)return a().cloneNode(t);const n=this.get("helperGenerator");if(n){const t=n(e);if(t)return t}r().ensure(e);const i=this.declarations[e]=this.scope.generateUidIdentifier(e),o={};for(const t of r().getDependencies(e))o[t]=this.addHelper(t);const{nodes:s,globals:u}=r().get(e,e=>o[e],i,Object.keys(this.scope.getAllBindings()));return u.forEach(e=>{this.path.scope.hasBinding(e,!0)&&this.path.scope.rename(e)}),s.forEach(e=>{e._compact=!0}),this.path.unshiftContainer("body",s),this.path.get("body").forEach(e=>{-1!==s.indexOf(e.node)&&e.isVariableDeclaration()&&this.scope.registerDeclaration(e)}),i}addTemplateObject(){throw new Error("This function has been moved into the template literal transform itself.")}buildCodeFrameError(e,t,n=SyntaxError){let r=e&&(e.loc||e._loc);if(!r&&e){const n={loc:null};(0,i().default)(e,l,this.scope,n),r=n.loc;let o="This is an error on an internal node. Probably an internal error.";r&&(o+=" Location has been estimated."),t+=` (${o})`}if(r){const{highlightCode:e=!0}=this.opts;t+="\n"+(0,o().codeFrameColumns)(this.code,{start:{line:r.start.line,column:r.start.column+1},end:r.end&&r.start.line===r.end.line?{line:r.end.line,column:r.end.column+1}:void 0},{highlightCode:e})}return new n(t)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.get=f,t.minVersion=function(e){return l(e).minVersion()},t.getDependencies=function(e){return Array.from(l(e).dependencies.values())},t.ensure=function(e){l(e)},t.default=t.list=void 0;var r=s(n(7)),i=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=a();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(n(0)),o=s(n(359));function a(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return a=function(){return e},e}function s(e){return e&&e.__esModule?e:{default:e}}function u(e){const t=[];for(;e.parentPath;e=e.parentPath)t.push(e.key),e.inList&&t.push(e.listKey);return t.reverse().join(".")}const c=Object.create(null);function l(e){if(!c[e]){const t=o.default[e];if(!t)throw Object.assign(new ReferenceError(`Unknown helper ${e}`),{code:"BABEL_HELPER_UNKNOWN",helper:e});const n=()=>i.file(t.ast()),a=function(e){const t=new Set,n=new Set,i=new Map;let a,s;const c=[],l=[],f=[];if((0,r.default)(e,{ImportDeclaration(e){const t=e.node.source.value;if(!o.default[t])throw e.buildCodeFrameError(`Unknown helper ${t}`);if(1!==e.get("specifiers").length||!e.get("specifiers.0").isImportDefaultSpecifier())throw e.buildCodeFrameError("Helpers can only import a default value");const n=e.node.specifiers[0].local;i.set(n,t),l.push(u(e))},ExportDefaultDeclaration(e){const t=e.get("declaration");if(t.isFunctionDeclaration()){if(!t.node.id)throw t.buildCodeFrameError("Helpers should give names to their exported func declaration");a=t.node.id.name}s=u(e)},ExportAllDeclaration(e){throw e.buildCodeFrameError("Helpers can only export default")},ExportNamedDeclaration(e){throw e.buildCodeFrameError("Helpers can only export default")},Statement(e){e.isModuleDeclaration()||e.skip()}}),(0,r.default)(e,{Program(e){const t=e.scope.getAllBindings();Object.keys(t).forEach(e=>{e!==a&&(i.has(t[e].identifier)||n.add(e))})},ReferencedIdentifier(e){const n=e.node.name,r=e.scope.getBinding(n,!0);r?i.has(r.identifier)&&f.push(u(e)):t.add(n)},AssignmentExpression(e){const t=e.get("left");if(!(a in t.getBindingIdentifiers()))return;if(!t.isIdentifier())throw t.buildCodeFrameError("Only simple assignments to exports are allowed in helpers");const n=e.scope.getBinding(a);n&&n.scope.path.isProgram()&&c.push(u(e))}}),!s)throw new Error("Helpers must default-export something.");return c.reverse(),{globals:Array.from(t),localBindingNames:Array.from(n),dependencies:i,exportBindingAssignments:c,exportPath:s,exportName:a,importBindingsReferences:f,importPaths:l}}(n());c[e]={build(e,t,o){const s=n();return function(e,t,n,o,a){if(o&&!n)throw new Error("Unexpected local bindings for module-based helpers.");if(!n)return;const{localBindingNames:s,dependencies:u,exportBindingAssignments:c,exportPath:l,exportName:f,importBindingsReferences:p,importPaths:h}=t,d={};u.forEach((e,t)=>{d[t.name]="function"==typeof a&&a(e)||t});const y={},m=new Set(o||[]);s.forEach(e=>{let t=e;for(;m.has(t);)t="_"+t;t!==e&&(y[e]=t)}),"Identifier"===n.type&&f!==n.name&&(y[f]=n.name),(0,r.default)(e,{Program(e){const t=e.get(l),r=h.map(t=>e.get(t)),o=p.map(t=>e.get(t)),a=t.get("declaration");if("Identifier"===n.type)a.isFunctionDeclaration()?t.replaceWith(a):t.replaceWith(i.variableDeclaration("var",[i.variableDeclarator(n,a.node)]));else{if("MemberExpression"!==n.type)throw new Error("Unexpected helper format.");a.isFunctionDeclaration()?(c.forEach(t=>{const r=e.get(t);r.replaceWith(i.assignmentExpression("=",n,r.node))}),t.replaceWith(a),e.pushContainer("body",i.expressionStatement(i.assignmentExpression("=",n,i.identifier(f))))):t.replaceWith(i.expressionStatement(i.assignmentExpression("=",n,a.node)))}Object.keys(y).forEach(t=>{e.scope.rename(t,y[t])});for(const e of r)e.remove();for(const e of o){const t=i.cloneNode(d[e.node.name]);e.replaceWith(t)}e.stop()}})}(s,a,t,o,e),{nodes:s.program.body,globals:a.globals}},minVersion:()=>t.minVersion,dependencies:a.dependencies}}return c[e]}function f(e,t,n,r){return l(e).build(t,n,r)}const p=Object.keys(o.default).map(e=>e.replace(/^_/,"")).filter(e=>"__esModule"!==e);t.list=p;var h=f;t.default=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ForAwaitStatement=t.NumericLiteralTypeAnnotation=t.ExistentialTypeParam=t.SpreadProperty=t.RestProperty=t.Flow=t.Pure=t.Generated=t.User=t.Var=t.BlockScoped=t.Referenced=t.Scope=t.Expression=t.Statement=t.BindingIdentifier=t.ReferencedMemberExpression=t.ReferencedIdentifier=void 0;var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=r?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(0));function i(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}const o={types:["Identifier","JSXIdentifier"],checkPath(e,t){const{node:n,parent:i}=e;if(!r.isIdentifier(n,t)&&!r.isJSXMemberExpression(i,t)){if(!r.isJSXIdentifier(n,t))return!1;if(r.react.isCompatTag(n.name))return!1}return r.isReferenced(n,i,e.parentPath.parent)}};t.ReferencedIdentifier=o;const a={types:["MemberExpression"],checkPath:({node:e,parent:t})=>r.isMemberExpression(e)&&r.isReferenced(e,t)};t.ReferencedMemberExpression=a;const s={types:["Identifier"],checkPath(e){const{node:t,parent:n}=e,i=e.parentPath.parent;return r.isIdentifier(t)&&r.isBinding(t,n,i)}};t.BindingIdentifier=s;const u={types:["Statement"],checkPath({node:e,parent:t}){if(r.isStatement(e)){if(r.isVariableDeclaration(e)){if(r.isForXStatement(t,{left:e}))return!1;if(r.isForStatement(t,{init:e}))return!1}return!0}return!1}};t.Statement=u;const c={types:["Expression"],checkPath:e=>e.isIdentifier()?e.isReferencedIdentifier():r.isExpression(e.node)};t.Expression=c;const l={types:["Scopable"],checkPath:e=>r.isScope(e.node,e.parent)};t.Scope=l;const f={checkPath:e=>r.isReferenced(e.node,e.parent)};t.Referenced=f;const p={checkPath:e=>r.isBlockScoped(e.node)};t.BlockScoped=p;const h={types:["VariableDeclaration"],checkPath:e=>r.isVar(e.node)};t.Var=h;const d={checkPath:e=>e.node&&!!e.node.loc};t.User=d;const y={checkPath:e=>!e.isUser()};t.Generated=y;const m={checkPath:(e,t)=>e.scope.isPure(e.node,t)};t.Pure=m;const v={types:["Flow","ImportDeclaration","ExportDeclaration","ImportSpecifier"],checkPath:({node:e})=>!!r.isFlow(e)||(r.isImportDeclaration(e)?"type"===e.importKind||"typeof"===e.importKind:r.isExportDeclaration(e)?"type"===e.exportKind:!!r.isImportSpecifier(e)&&("type"===e.importKind||"typeof"===e.importKind))};t.Flow=v;const b={types:["RestElement"],checkPath:e=>e.parentPath&&e.parentPath.isObjectPattern()};t.RestProperty=b;const g={types:["RestElement"],checkPath:e=>e.parentPath&&e.parentPath.isObjectExpression()};t.SpreadProperty=g;t.ExistentialTypeParam={types:["ExistsTypeAnnotation"]};t.NumericLiteralTypeAnnotation={types:["NumberLiteralTypeAnnotation"]};const w={types:["ForOfStatement"],checkPath:({node:e})=>!0===e.await};t.ForAwaitStatement=w},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){const n=e.split(".");return e=>(0,i.default)(e,n,t)};var r,i=(r=n(82))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n){if(!(0,r.isMemberExpression)(e))return!1;const i=Array.isArray(t)?t:t.split("."),o=[];let a;for(a=e;(0,r.isMemberExpression)(a);a=a.object)o.push(a.property);if(o.push(a),o.lengthi.length)return!1;for(let e=0,t=o.length-1;e=97&&a<=122||a>=65&&a<=90||36===a||95===a;for(o=new Array(128),a=0;a<128;++a)o[a]=a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57||36===a||95===a;e.exports={isDecimalDigit:function(e){return 48<=e&&e<=57},isHexDigit:function(e){return 48<=e&&e<=57||97<=e&&e<=102||65<=e&&e<=70},isOctalDigit:function(e){return e>=48&&e<=55},isWhiteSpace:function(e){return 32===e||9===e||11===e||12===e||160===e||e>=5760&&r.indexOf(e)>=0},isLineTerminator:function(e){return 10===e||13===e||8232===e||8233===e},isIdentifierStartES5:function(e){return e<128?i[e]:n.NonAsciiIdentifierStart.test(s(e))},isIdentifierPartES5:function(e){return e<128?o[e]:n.NonAsciiIdentifierPart.test(s(e))},isIdentifierStartES6:function(e){return e<128?i[e]:t.NonAsciiIdentifierStart.test(s(e))},isIdentifierPartES6:function(e){return e<128?o[e]:t.NonAsciiIdentifierPart.test(s(e))}}}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if(e===t)return!0;const n=r.PLACEHOLDERS_ALIAS[e];if(n)for(const e of n)if(t===e)return!0;return!1};var r=n(2)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PLACEHOLDERS_FLIPPED_ALIAS=t.PLACEHOLDERS_ALIAS=t.PLACEHOLDERS=void 0;var r=n(8);const i=["Identifier","StringLiteral","Expression","Statement","Declaration","BlockStatement","ClassBody","Pattern"];t.PLACEHOLDERS=i;const o={Declaration:["Statement"],Pattern:["PatternLike","LVal"]};t.PLACEHOLDERS_ALIAS=o;for(const e of i){const t=r.ALIAS_KEYS[e];t&&t.length&&(o[e]=t)}const a={};t.PLACEHOLDERS_FLIPPED_ALIAS=a,Object.keys(o).forEach(e=>{o[e].forEach(t=>{Object.hasOwnProperty.call(a,t)||(a[t]=[]),a[t].push(e)})})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return!(!e||!r.VISITOR_KEYS[e.type])};var r=n(2)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t){const n={},i={},o=[],a=[];for(let s=0;s=0)){if((0,r.isAnyTypeAnnotation)(u))return[u];if((0,r.isFlowBaseAnnotation)(u))i[u.type]=u;else if((0,r.isUnionTypeAnnotation)(u))o.indexOf(u.types)<0&&(t=t.concat(u.types),o.push(u.types));else if((0,r.isGenericTypeAnnotation)(u)){const t=u.id.name;if(n[t]){let r=n[t];r.typeParameters?u.typeParameters&&(r.typeParameters.params=e(r.typeParameters.params.concat(u.typeParameters.params))):r=u.typeParameters}else n[t]=u}else a.push(u)}}for(const e of Object.keys(i))a.push(i[e]);for(const e of Object.keys(n))a.push(n[e]);return a};var r=n(1)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return(0,i.default)(e,!1)};var r,i=(r=n(22))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n){if(!n||!e)return e;const r=`${t}Comments`;e[r]?e[r]="leading"===t?n.concat(e[r]):e[r].concat(n):e[r]=n;return e}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){(0,i.default)("innerComments",e,t)};var r,i=(r=n(65))&&r.__esModule?r:{default:r}},function(e,t,n){var r=n(49),i=n(243),o=n(244);function a(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new r;++te.isScope());return e&&e.scope}get parentBlock(){return this.path.parent}get hub(){return this.path.hub}traverse(e,t,n){(0,a.default)(e,t,this,n,this.path)}generateDeclaredUidIdentifier(e){const t=this.generateUidIdentifier(e);return this.push({id:t}),l.cloneNode(t)}generateUidIdentifier(e){return l.identifier(this.generateUid(e))}generateUid(e="temp"){let t;e=l.toIdentifier(e).replace(/^_+/,"").replace(/[0-9]+$/g,"");let n=0;do{t=this._generateUid(e,n),n++}while(this.hasLabel(t)||this.hasBinding(t)||this.hasGlobal(t)||this.hasReference(t));const r=this.getProgramParent();return r.references[t]=!0,r.uids[t]=!0,t}_generateUid(e,t){let n=e;return t>1&&(n+=t),`_${n}`}generateUidBasedOnNode(e,t){let n=e;l.isAssignmentExpression(e)?n=e.left:l.isVariableDeclarator(e)?n=e.id:(l.isObjectProperty(n)||l.isObjectMethod(n))&&(n=n.key);const r=[];!function e(t,n){if(l.isModuleDeclaration(t))if(t.source)e(t.source,n);else if(t.specifiers&&t.specifiers.length)for(const r of t.specifiers)e(r,n);else t.declaration&&e(t.declaration,n);else if(l.isModuleSpecifier(t))e(t.local,n);else if(l.isMemberExpression(t))e(t.object,n),e(t.property,n);else if(l.isIdentifier(t))n.push(t.name);else if(l.isLiteral(t))n.push(t.value);else if(l.isCallExpression(t))e(t.callee,n);else if(l.isObjectExpression(t)||l.isObjectPattern(t))for(const r of t.properties)e(r.key||r.argument,n);else l.isPrivateName(t)?e(t.id,n):l.isThisExpression(t)?n.push("this"):l.isSuper(t)&&n.push("super")}(n,r);let i=r.join("$");return i=i.replace(/^_/,"")||t||"ref",this.generateUid(i.slice(0,20))}generateUidIdentifierBasedOnNode(e,t){return l.identifier(this.generateUidBasedOnNode(e,t))}isStatic(e){if(l.isThisExpression(e)||l.isSuper(e))return!0;if(l.isIdentifier(e)){const t=this.getBinding(e.name);return t?t.constant:this.hasBinding(e.name)}return!1}maybeGenerateMemoised(e,t){if(this.isStatic(e))return null;{const n=this.generateUidIdentifierBasedOnNode(e);return t?n:(this.push({id:n}),l.cloneNode(n))}}checkBlockScopedCollisions(e,t,n,r){if("param"===t)return;if("local"===e.kind)return;if("let"===t||"let"===e.kind||"const"===e.kind||"module"===e.kind||"param"===e.kind&&("let"===t||"const"===t))throw this.hub.buildError(r,`Duplicate declaration "${n}"`,TypeError)}rename(e,t,n){const r=this.getBinding(e);if(r)return t=t||this.generateUidIdentifier(e).name,new o.default(r,e,t).rename(n)}_renameFromMap(e,t,n,r){e[t]&&(e[n]=r,e[t]=null)}dump(){const e=(0,i.default)("-",60);console.log(e);let t=this;do{console.log("#",t.block.type);for(const e of Object.keys(t.bindings)){const n=t.bindings[e];console.log(" -",e,{constant:n.constant,references:n.references,violations:n.constantViolations.length,kind:n.kind})}}while(t=t.parent);console.log(e)}toArray(e,t){if(l.isIdentifier(e)){const t=this.getBinding(e.name);if(t&&t.constant&&t.path.isGenericType("Array"))return e}if(l.isArrayExpression(e))return e;if(l.isIdentifier(e,{name:"arguments"}))return l.callExpression(l.memberExpression(l.memberExpression(l.memberExpression(l.identifier("Array"),l.identifier("prototype")),l.identifier("slice")),l.identifier("call")),[e]);let n;const r=[e];return!0===t?n="toConsumableArray":t?(r.push(l.numericLiteral(t)),n="slicedToArray"):n="toArray",l.callExpression(this.hub.addHelper(n),r)}hasLabel(e){return!!this.getLabel(e)}getLabel(e){return this.labels.get(e)}registerLabel(e){this.labels.set(e.node.label.name,e)}registerDeclaration(e){if(e.isLabeledStatement())this.registerLabel(e);else if(e.isFunctionDeclaration())this.registerBinding("hoisted",e.get("id"),e);else if(e.isVariableDeclaration()){const t=e.get("declarations");for(const n of t)this.registerBinding(e.node.kind,n)}else if(e.isClassDeclaration())this.registerBinding("let",e);else if(e.isImportDeclaration()){const t=e.get("specifiers");for(const e of t)this.registerBinding("module",e)}else if(e.isExportDeclaration()){const t=e.get("declaration");(t.isClassDeclaration()||t.isFunctionDeclaration()||t.isVariableDeclaration())&&this.registerDeclaration(t)}else this.registerBinding("unknown",e)}buildUndefinedNode(){return l.unaryExpression("void",l.numericLiteral(0),!0)}registerConstantViolation(e){const t=e.getBindingIdentifiers();for(const n of Object.keys(t)){const t=this.getBinding(n);t&&t.reassign(e)}}registerBinding(e,t,n=t){if(!e)throw new ReferenceError("no `kind`");if(t.isVariableDeclaration()){const n=t.get("declarations");for(const t of n)this.registerBinding(e,t);return}const r=this.getProgramParent(),i=t.getOuterBindingIdentifiers(!0);for(const t of Object.keys(i))for(const o of i[t]){const i=this.getOwnBinding(t);if(i){if(i.identifier===o)continue;this.checkBlockScopedCollisions(i,e,t,o)}r.references[t]=!0,i?this.registerConstantViolation(n):this.bindings[t]=new u.default({identifier:o,scope:this,path:n,kind:e})}}addGlobal(e){this.globals[e.name]=e}hasUid(e){let t=this;do{if(t.uids[e])return!0}while(t=t.parent);return!1}hasGlobal(e){let t=this;do{if(t.globals[e])return!0}while(t=t.parent);return!1}hasReference(e){let t=this;do{if(t.references[e])return!0}while(t=t.parent);return!1}isPure(e,t){if(l.isIdentifier(e)){const n=this.getBinding(e.name);return!!n&&(!t||n.constant)}if(l.isClass(e))return!(e.superClass&&!this.isPure(e.superClass,t))&&this.isPure(e.body,t);if(l.isClassBody(e)){for(const n of e.body)if(!this.isPure(n,t))return!1;return!0}if(l.isBinary(e))return this.isPure(e.left,t)&&this.isPure(e.right,t);if(l.isArrayExpression(e)){for(const n of e.elements)if(!this.isPure(n,t))return!1;return!0}if(l.isObjectExpression(e)){for(const n of e.properties)if(!this.isPure(n,t))return!1;return!0}if(l.isClassMethod(e))return!(e.computed&&!this.isPure(e.key,t))&&("get"!==e.kind&&"set"!==e.kind);if(l.isProperty(e))return!(e.computed&&!this.isPure(e.key,t))&&this.isPure(e.value,t);if(l.isUnaryExpression(e))return this.isPure(e.argument,t);if(l.isTaggedTemplateExpression(e))return l.matchesPattern(e.tag,"String.raw")&&!this.hasBinding("String",!0)&&this.isPure(e.quasi,t);if(l.isTemplateLiteral(e)){for(const n of e.expressions)if(!this.isPure(n,t))return!1;return!0}return l.isPureish(e)}setData(e,t){return this.data[e]=t}getData(e){let t=this;do{const n=t.data[e];if(null!=n)return n}while(t=t.parent)}removeData(e){let t=this;do{null!=t.data[e]&&(t.data[e]=null)}while(t=t.parent)}init(){this.references||this.crawl()}crawl(){const e=this.path;if(this.references=Object.create(null),this.bindings=Object.create(null),this.globals=Object.create(null),this.uids=Object.create(null),this.data=Object.create(null),e.isLoop())for(const t of l.FOR_INIT_KEYS){const n=e.get(t);n.isBlockScoped()&&this.registerBinding(n.node.kind,n)}if(e.isFunctionExpression()&&e.has("id")&&(e.get("id").node[l.NOT_LOCAL_BINDING]||this.registerBinding("local",e.get("id"),e)),e.isClassExpression()&&e.has("id")&&(e.get("id").node[l.NOT_LOCAL_BINDING]||this.registerBinding("local",e)),e.isFunction()){const t=e.get("params");for(const e of t)this.registerBinding("param",e)}if(e.isCatchClause()&&this.registerBinding("let",e),this.getProgramParent().crawling)return;const t={references:[],constantViolations:[],assignments:[]};this.crawling=!0,e.traverse(d,t),this.crawling=!1;for(const e of t.assignments){const t=e.getBindingIdentifiers();let n;for(const r of Object.keys(t))e.scope.getBinding(r)||(n=n||e.scope.getProgramParent(),n.addGlobal(t[r]));e.scope.registerConstantViolation(e)}for(const e of t.references){const t=e.scope.getBinding(e.node.name);t?t.reference(e):e.scope.getProgramParent().addGlobal(e.node)}for(const e of t.constantViolations)e.scope.registerConstantViolation(e)}push(e){let t=this.path;t.isBlockStatement()||t.isProgram()||(t=this.getBlockParent().path),t.isSwitchStatement()&&(t=(this.getFunctionParent()||this.getProgramParent()).path),(t.isLoop()||t.isCatchClause()||t.isFunction())&&(t.ensureBlock(),t=t.get("body"));const n=e.unique,r=e.kind||"var",i=null==e._blockHoist?2:e._blockHoist,o=`declaration:${r}:${i}`;let a=!n&&t.getData(o);if(!a){const e=l.variableDeclaration(r,[]);e._blockHoist=i,[a]=t.unshiftContainer("body",[e]),n||t.setData(o,a)}const s=l.variableDeclarator(e.id,e.init);a.node.declarations.push(s),this.registerBinding(r,a.get("declarations").pop())}getProgramParent(){let e=this;do{if(e.path.isProgram())return e}while(e=e.parent);throw new Error("Couldn't find a Program")}getFunctionParent(){let e=this;do{if(e.path.isFunctionParent())return e}while(e=e.parent);return null}getBlockParent(){let e=this;do{if(e.path.isBlockParent())return e}while(e=e.parent);throw new Error("We couldn't find a BlockStatement, For, Switch, Function, Loop or Program...")}getAllBindings(){const e=Object.create(null);let t=this;do{(0,s.default)(e,t.bindings),t=t.parent}while(t);return e}getAllBindingsOfKind(){const e=Object.create(null);for(const t of arguments){let n=this;do{for(const r of Object.keys(n.bindings)){const i=n.bindings[r];i.kind===t&&(e[r]=i)}n=n.parent}while(n)}return e}bindingIdentifierEquals(e,t){return this.getBindingIdentifier(e)===t}getBinding(e){let t=this;do{const n=t.getOwnBinding(e);if(n)return n}while(t=t.parent)}getOwnBinding(e){return this.bindings[e]}getBindingIdentifier(e){const t=this.getBinding(e);return t&&t.identifier}getOwnBindingIdentifier(e){const t=this.bindings[e];return t&&t.identifier}hasOwnBinding(e){return!!this.getOwnBinding(e)}hasBinding(e,t){return!!e&&(!!this.hasOwnBinding(e)||(!!this.parentHasBinding(e,t)||(!!this.hasUid(e)||(!(t||!(0,r.default)(m.globals,e))||!(t||!(0,r.default)(m.contextVariables,e))))))}parentHasBinding(e,t){return this.parent&&this.parent.hasBinding(e,t)}moveBindingTo(e,t){const n=this.getBinding(e);n&&(n.scope.removeOwnBinding(e),n.scope=t,t.bindings[e]=n)}removeOwnBinding(e){delete this.bindings[e]}removeBinding(e){const t=this.getBinding(e);t&&t.scope.removeOwnBinding(e);let n=this;do{n.uids[e]&&(n.uids[e]=!1)}while(n=n.parent)}}t.default=m,m.globals=Object.keys(c.default.builtin),m.contextVariables=["arguments","undefined","Infinity","NaN"]},function(e,t,n){var r=n(287),i=n(71),o=n(69),a=n(72);e.exports=function(e,t,n){return t=(n?i(e,t,n):void 0===t)?1:o(t),r(a(e),t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{constructor({identifier:e,scope:t,path:n,kind:r}){this.identifier=e,this.scope=t,this.path=n,this.kind=r,this.constantViolations=[],this.constant=!0,this.referencePaths=[],this.referenced=!1,this.references=0,this.clearValue()}deoptValue(){this.clearValue(),this.hasDeoptedValue=!0}setValue(e){this.hasDeoptedValue||(this.hasValue=!0,this.value=e)}clearValue(){this.hasDeoptedValue=!1,this.hasValue=!1,this.value=null}reassign(e){this.constant=!1,-1===this.constantViolations.indexOf(e)&&this.constantViolations.push(e)}reference(e){-1===this.referencePaths.indexOf(e)&&(this.referenced=!0,this.references++,this.referencePaths.push(e))}dereference(){this.references--,this.referenced=!!this.references}}},function(e,t,n){var r=n(35),i=n(292),o=n(294);e.exports=function(e,t){return o(i(e,t,r),e+"")}},function(e,t,n){t.SourceMapGenerator=n(126).SourceMapGenerator,t.SourceMapConsumer=n(303).SourceMapConsumer,t.SourceNode=n(306).SourceNode},function(e,t,n){var r=n(127),i=n(24),o=n(128).ArraySet,a=n(302).MappingList;function s(e){e||(e={}),this._file=i.getArg(e,"file",null),this._sourceRoot=i.getArg(e,"sourceRoot",null),this._skipValidation=i.getArg(e,"skipValidation",!1),this._sources=new o,this._names=new o,this._mappings=new a,this._sourcesContents=null}s.prototype._version=3,s.fromSourceMap=function(e){var t=e.sourceRoot,n=new s({file:e.file,sourceRoot:t});return e.eachMapping((function(e){var r={generated:{line:e.generatedLine,column:e.generatedColumn}};null!=e.source&&(r.source=e.source,null!=t&&(r.source=i.relative(t,r.source)),r.original={line:e.originalLine,column:e.originalColumn},null!=e.name&&(r.name=e.name)),n.addMapping(r)})),e.sources.forEach((function(t){var r=e.sourceContentFor(t);null!=r&&n.setSourceContent(t,r)})),n},s.prototype.addMapping=function(e){var t=i.getArg(e,"generated"),n=i.getArg(e,"original",null),r=i.getArg(e,"source",null),o=i.getArg(e,"name",null);this._skipValidation||this._validateMapping(t,n,r,o),null!=r&&(r=String(r),this._sources.has(r)||this._sources.add(r)),null!=o&&(o=String(o),this._names.has(o)||this._names.add(o)),this._mappings.add({generatedLine:t.line,generatedColumn:t.column,originalLine:null!=n&&n.line,originalColumn:null!=n&&n.column,source:r,name:o})},s.prototype.setSourceContent=function(e,t){var n=e;null!=this._sourceRoot&&(n=i.relative(this._sourceRoot,n)),null!=t?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[i.toSetString(n)]=t):this._sourcesContents&&(delete this._sourcesContents[i.toSetString(n)],0===Object.keys(this._sourcesContents).length&&(this._sourcesContents=null))},s.prototype.applySourceMap=function(e,t,n){var r=t;if(null==t){if(null==e.file)throw new Error('SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map\'s "file" property. Both were omitted.');r=e.file}var a=this._sourceRoot;null!=a&&(r=i.relative(a,r));var s=new o,u=new o;this._mappings.unsortedForEach((function(t){if(t.source===r&&null!=t.originalLine){var o=e.originalPositionFor({line:t.originalLine,column:t.originalColumn});null!=o.source&&(t.source=o.source,null!=n&&(t.source=i.join(n,t.source)),null!=a&&(t.source=i.relative(a,t.source)),t.originalLine=o.line,t.originalColumn=o.column,null!=o.name&&(t.name=o.name))}var c=t.source;null==c||s.has(c)||s.add(c);var l=t.name;null==l||u.has(l)||u.add(l)}),this),this._sources=s,this._names=u,e.sources.forEach((function(t){var r=e.sourceContentFor(t);null!=r&&(null!=n&&(t=i.join(n,t)),null!=a&&(t=i.relative(a,t)),this.setSourceContent(t,r))}),this)},s.prototype._validateMapping=function(e,t,n,r){if(t&&"number"!=typeof t.line&&"number"!=typeof t.column)throw new Error("original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.");if((!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0)||t||n||r)&&!(e&&"line"in e&&"column"in e&&t&&"line"in t&&"column"in t&&e.line>0&&e.column>=0&&t.line>0&&t.column>=0&&n))throw new Error("Invalid mapping: "+JSON.stringify({generated:e,source:n,original:t,name:r}))},s.prototype._serializeMappings=function(){for(var e,t,n,o,a=0,s=1,u=0,c=0,l=0,f=0,p="",h=this._mappings.toArray(),d=0,y=h.length;d0){if(!i.compareByGeneratedPositionsInflated(t,h[d-1]))continue;e+=","}e+=r.encode(t.generatedColumn-a),a=t.generatedColumn,null!=t.source&&(o=this._sources.indexOf(t.source),e+=r.encode(o-f),f=o,e+=r.encode(t.originalLine-1-c),c=t.originalLine-1,e+=r.encode(t.originalColumn-u),u=t.originalColumn,null!=t.name&&(n=this._names.indexOf(t.name),e+=r.encode(n-l),l=n)),p+=e}return p},s.prototype._generateSourcesContent=function(e,t){return e.map((function(e){if(!this._sourcesContents)return null;null!=t&&(e=i.relative(t,e));var n=i.toSetString(e);return Object.prototype.hasOwnProperty.call(this._sourcesContents,n)?this._sourcesContents[n]:null}),this)},s.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return null!=this._file&&(e.file=this._file),null!=this._sourceRoot&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e},s.prototype.toString=function(){return JSON.stringify(this.toJSON())},t.SourceMapGenerator=s},function(e,t,n){var r=n(301);t.encode=function(e){var t,n="",i=function(e){return e<0?1+(-e<<1):0+(e<<1)}(e);do{t=31&i,(i>>>=5)>0&&(t|=32),n+=r.encode(t)}while(i>0);return n},t.decode=function(e,t,n){var i,o,a,s,u=e.length,c=0,l=0;do{if(t>=u)throw new Error("Expected more digits in base 64 VLQ value.");if(-1===(o=r.decode(e.charCodeAt(t++))))throw new Error("Invalid base64 digit: "+e.charAt(t-1));i=!!(32&o),c+=(o&=31)<>1,1==(1&a)?-s:s),n.rest=t}},function(e,t,n){var r=n(24),i=Object.prototype.hasOwnProperty,o="undefined"!=typeof Map;function a(){this._array=[],this._set=o?new Map:Object.create(null)}a.fromArray=function(e,t){for(var n=new a,r=0,i=e.length;r=0)return t}else{var n=r.toSetString(e);if(i.call(this._set,n))return this._set[n]}throw new Error('"'+e+'" is not in the set.')},a.prototype.at=function(e){if(e>=0&&e{this.word(e.name)})},t.ArgumentPlaceholder=function(){this.token("?")},t.SpreadElement=t.RestElement=function(e){this.token("..."),this.print(e.argument,e)},t.ObjectPattern=t.ObjectExpression=function(e){const t=e.properties;this.token("{"),this.printInnerComments(e),t.length&&(this.space(),this.printList(t,e,{indent:!0,statement:!0}),this.space());this.token("}")},t.ObjectMethod=function(e){this.printJoin(e.decorators,e),this._methodHead(e),this.space(),this.print(e.body,e)},t.ObjectProperty=function(e){if(this.printJoin(e.decorators,e),e.computed)this.token("["),this.print(e.key,e),this.token("]");else{if(i.isAssignmentPattern(e.value)&&i.isIdentifier(e.key)&&e.key.name===e.value.left.name)return void this.print(e.value,e);if(this.print(e.key,e),e.shorthand&&i.isIdentifier(e.key)&&i.isIdentifier(e.value)&&e.key.name===e.value.name)return}this.token(":"),this.space(),this.print(e.value,e)},t.ArrayPattern=t.ArrayExpression=function(e){const t=e.elements,n=t.length;this.token("["),this.printInnerComments(e);for(let r=0;r0&&this.space(),this.print(i,e),r * @license MIT */ -var r=n(319),i=n(320),o=n(321);function a(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(e,t){if(a()=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function d(e,t){if(u.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return N(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return V(e).length;default:if(r)return N(e).length;t=(""+t).toLowerCase(),r=!0}}function y(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return C(this,t,n);case"utf8":case"utf-8":return E(this,t,n);case"ascii":return j(this,t,n);case"latin1":case"binary":return T(this,t,n);case"base64":return x(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return _(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function m(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function v(e,t,n,r,i){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0){if(!i)return-1;n=0}if("string"==typeof t&&(t=u.from(t,r)),u.isBuffer(t))return 0===t.length?-1:b(e,t,n,r,i);if("number"==typeof t)return t&=255,u.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):b(e,[t],n,r,i);throw new TypeError("val must be string, number or Buffer")}function b(e,t,n,r,i){var o,a=1,s=e.length,u=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,s/=2,u/=2,n/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var l=-1;for(o=n;os&&(n=s-u),o=n;o>=0;o--){for(var f=!0,p=0;pi&&(r=i):r=i;var o=t.length;if(o%2!=0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var a=0;a>8,i=n%256,o.push(i),o.push(r);return o}(t,e.length-n),e,n,r)}function x(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function E(e,t,n){n=Math.min(e.length,n);for(var r=[],i=t;i239?4:c>223?3:c>191?2:1;if(i+f<=n)switch(f){case 1:c<128&&(l=c);break;case 2:128==(192&(o=e[i+1]))&&(u=(31&c)<<6|63&o)>127&&(l=u);break;case 3:o=e[i+1],a=e[i+2],128==(192&o)&&128==(192&a)&&(u=(15&c)<<12|(63&o)<<6|63&a)>2047&&(u<55296||u>57343)&&(l=u);break;case 4:o=e[i+1],a=e[i+2],s=e[i+3],128==(192&o)&&128==(192&a)&&128==(192&s)&&(u=(15&c)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&u<1114112&&(l=u)}null===l?(l=65533,f=1):l>65535&&(l-=65536,r.push(l>>>10&1023|55296),l=56320|1023&l),r.push(l),i+=f}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),""},u.prototype.compare=function(e,t,n,r,i){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw new RangeError("out of range index");if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(this===e)return 0;for(var o=(i>>>=0)-(r>>>=0),a=(n>>>=0)-(t>>>=0),s=Math.min(o,a),c=this.slice(r,i),l=e.slice(t,n),f=0;fi)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return g(this,e,t,n);case"utf8":case"utf-8":return w(this,e,t,n);case"ascii":return S(this,e,t,n);case"latin1":case"binary":return O(this,e,t,n);case"base64":return P(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return k(this,e,t,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function j(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;ir)&&(n=r);for(var i="",o=t;on)throw new RangeError("Trying to access beyond buffer length")}function D(e,t,n,r,i,o){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw new RangeError("Index out of range")}function I(e,t,n,r){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-n,2);i>>8*(r?i:1-i)}function F(e,t,n,r){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-n,4);i>>8*(r?i:3-i)&255}function $(e,t,n,r,i,o){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function M(e,t,n,r,o){return o||$(e,0,n,4),i.write(e,t,n,r,23,4),n+4}function R(e,t,n,r,o){return o||$(e,0,n,8),i.write(e,t,n,r,52,8),n+8}u.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t0&&(i*=256);)r+=this[e+--t]*i;return r},u.prototype.readUInt8=function(e,t){return t||A(e,1,this.length),this[e]},u.prototype.readUInt16LE=function(e,t){return t||A(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUInt16BE=function(e,t){return t||A(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUInt32LE=function(e,t){return t||A(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUInt32BE=function(e,t){return t||A(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||A(e,t,this.length);for(var r=this[e],i=1,o=0;++o=(i*=128)&&(r-=Math.pow(2,8*t)),r},u.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||A(e,t,this.length);for(var r=t,i=1,o=this[e+--r];r>0&&(i*=256);)o+=this[e+--r]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},u.prototype.readInt8=function(e,t){return t||A(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){t||A(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt16BE=function(e,t){t||A(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt32LE=function(e,t){return t||A(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return t||A(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readFloatLE=function(e,t){return t||A(e,4,this.length),i.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return t||A(e,4,this.length),i.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return t||A(e,8,this.length),i.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return t||A(e,8,this.length),i.read(this,e,!1,52,8)},u.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||D(this,e,t,n,Math.pow(2,8*n)-1,0);var i=1,o=0;for(this[t]=255&e;++o=0&&(o*=256);)this[t+i]=e/o&255;return t+n},u.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,1,255,0),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},u.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):I(this,e,t,!0),t+2},u.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):I(this,e,t,!1),t+2},u.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):F(this,e,t,!0),t+4},u.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):F(this,e,t,!1),t+4},u.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);D(this,e,t,n,i-1,-i)}var o=0,a=1,s=0;for(this[t]=255&e;++o>0)-s&255;return t+n},u.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);D(this,e,t,n,i-1,-i)}var o=n-1,a=1,s=0;for(this[t+o]=255&e;--o>=0&&(a*=256);)e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+n},u.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,1,127,-128),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):I(this,e,t,!0),t+2},u.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):I(this,e,t,!1),t+2},u.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):F(this,e,t,!0),t+4},u.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):F(this,e,t,!1),t+4},u.prototype.writeFloatLE=function(e,t,n){return M(this,e,t,!0,n)},u.prototype.writeFloatBE=function(e,t,n){return M(this,e,t,!1,n)},u.prototype.writeDoubleLE=function(e,t,n){return R(this,e,t,!0,n)},u.prototype.writeDoubleBE=function(e,t,n){return R(this,e,t,!1,n)},u.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t=0;--i)e[i+t]=this[i+n];else if(o<1e3||!u.TYPED_ARRAY_SUPPORT)for(i=0;i>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(o=t;o55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function V(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(L,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function z(e,t,n,r){for(var i=0;i=t.length||i>=e.length);++i)t[i+n]=e[i];return i}}).call(this,n(48))},function(e,t,n){var r=n(337),i={};for(var o in r)r.hasOwnProperty(o)&&(i[r[o]]=o);var a=e.exports={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};for(var s in a)if(a.hasOwnProperty(s)){if(!("channels"in a[s]))throw new Error("missing channels property: "+s);if(!("labels"in a[s]))throw new Error("missing channel labels property: "+s);if(a[s].labels.length!==a[s].channels)throw new Error("channel and label counts mismatch: "+s);var u=a[s].channels,c=a[s].labels;delete a[s].channels,delete a[s].labels,Object.defineProperty(a[s],"channels",{value:u}),Object.defineProperty(a[s],"labels",{value:c})}function l(e,t){return Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2)+Math.pow(e[2]-t[2],2)}a.rgb.hsl=function(e){var t,n,r=e[0]/255,i=e[1]/255,o=e[2]/255,a=Math.min(r,i,o),s=Math.max(r,i,o),u=s-a;return s===a?t=0:r===s?t=(i-o)/u:i===s?t=2+(o-r)/u:o===s&&(t=4+(r-i)/u),(t=Math.min(60*t,360))<0&&(t+=360),n=(a+s)/2,[t,100*(s===a?0:n<=.5?u/(s+a):u/(2-s-a)),100*n]},a.rgb.hsv=function(e){var t,n,r,i,o,a=e[0]/255,s=e[1]/255,u=e[2]/255,c=Math.max(a,s,u),l=c-Math.min(a,s,u),f=function(e){return(c-e)/6/l+.5};return 0===l?i=o=0:(o=l/c,t=f(a),n=f(s),r=f(u),a===c?i=r-n:s===c?i=1/3+t-r:u===c&&(i=2/3+n-t),i<0?i+=1:i>1&&(i-=1)),[360*i,100*o,100*c]},a.rgb.hwb=function(e){var t=e[0],n=e[1],r=e[2];return[a.rgb.hsl(e)[0],100*(1/255*Math.min(t,Math.min(n,r))),100*(r=1-1/255*Math.max(t,Math.max(n,r)))]},a.rgb.cmyk=function(e){var t,n=e[0]/255,r=e[1]/255,i=e[2]/255;return[100*((1-n-(t=Math.min(1-n,1-r,1-i)))/(1-t)||0),100*((1-r-t)/(1-t)||0),100*((1-i-t)/(1-t)||0),100*t]},a.rgb.keyword=function(e){var t=i[e];if(t)return t;var n,o=1/0;for(var a in r)if(r.hasOwnProperty(a)){var s=l(e,r[a]);s.04045?Math.pow((t+.055)/1.055,2.4):t/12.92)+.3576*(n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92)+.1805*(r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92)),100*(.2126*t+.7152*n+.0722*r),100*(.0193*t+.1192*n+.9505*r)]},a.rgb.lab=function(e){var t=a.rgb.xyz(e),n=t[0],r=t[1],i=t[2];return r/=100,i/=108.883,n=(n/=95.047)>.008856?Math.pow(n,1/3):7.787*n+16/116,[116*(r=r>.008856?Math.pow(r,1/3):7.787*r+16/116)-16,500*(n-r),200*(r-(i=i>.008856?Math.pow(i,1/3):7.787*i+16/116))]},a.hsl.rgb=function(e){var t,n,r,i,o,a=e[0]/360,s=e[1]/100,u=e[2]/100;if(0===s)return[o=255*u,o,o];t=2*u-(n=u<.5?u*(1+s):u+s-u*s),i=[0,0,0];for(var c=0;c<3;c++)(r=a+1/3*-(c-1))<0&&r++,r>1&&r--,o=6*r<1?t+6*(n-t)*r:2*r<1?n:3*r<2?t+(n-t)*(2/3-r)*6:t,i[c]=255*o;return i},a.hsl.hsv=function(e){var t=e[0],n=e[1]/100,r=e[2]/100,i=n,o=Math.max(r,.01);return n*=(r*=2)<=1?r:2-r,i*=o<=1?o:2-o,[t,100*(0===r?2*i/(o+i):2*n/(r+n)),100*((r+n)/2)]},a.hsv.rgb=function(e){var t=e[0]/60,n=e[1]/100,r=e[2]/100,i=Math.floor(t)%6,o=t-Math.floor(t),a=255*r*(1-n),s=255*r*(1-n*o),u=255*r*(1-n*(1-o));switch(r*=255,i){case 0:return[r,u,a];case 1:return[s,r,a];case 2:return[a,r,u];case 3:return[a,s,r];case 4:return[u,a,r];case 5:return[r,a,s]}},a.hsv.hsl=function(e){var t,n,r,i=e[0],o=e[1]/100,a=e[2]/100,s=Math.max(a,.01);return r=(2-o)*a,n=o*s,[i,100*(n=(n/=(t=(2-o)*s)<=1?t:2-t)||0),100*(r/=2)]},a.hwb.rgb=function(e){var t,n,r,i,o,a,s,u=e[0]/360,c=e[1]/100,l=e[2]/100,f=c+l;switch(f>1&&(c/=f,l/=f),r=6*u-(t=Math.floor(6*u)),0!=(1&t)&&(r=1-r),i=c+r*((n=1-l)-c),t){default:case 6:case 0:o=n,a=i,s=c;break;case 1:o=i,a=n,s=c;break;case 2:o=c,a=n,s=i;break;case 3:o=c,a=i,s=n;break;case 4:o=i,a=c,s=n;break;case 5:o=n,a=c,s=i}return[255*o,255*a,255*s]},a.cmyk.rgb=function(e){var t=e[0]/100,n=e[1]/100,r=e[2]/100,i=e[3]/100;return[255*(1-Math.min(1,t*(1-i)+i)),255*(1-Math.min(1,n*(1-i)+i)),255*(1-Math.min(1,r*(1-i)+i))]},a.xyz.rgb=function(e){var t,n,r,i=e[0]/100,o=e[1]/100,a=e[2]/100;return n=-.9689*i+1.8758*o+.0415*a,r=.0557*i+-.204*o+1.057*a,t=(t=3.2406*i+-1.5372*o+-.4986*a)>.0031308?1.055*Math.pow(t,1/2.4)-.055:12.92*t,n=n>.0031308?1.055*Math.pow(n,1/2.4)-.055:12.92*n,r=r>.0031308?1.055*Math.pow(r,1/2.4)-.055:12.92*r,[255*(t=Math.min(Math.max(0,t),1)),255*(n=Math.min(Math.max(0,n),1)),255*(r=Math.min(Math.max(0,r),1))]},a.xyz.lab=function(e){var t=e[0],n=e[1],r=e[2];return n/=100,r/=108.883,t=(t/=95.047)>.008856?Math.pow(t,1/3):7.787*t+16/116,[116*(n=n>.008856?Math.pow(n,1/3):7.787*n+16/116)-16,500*(t-n),200*(n-(r=r>.008856?Math.pow(r,1/3):7.787*r+16/116))]},a.lab.xyz=function(e){var t,n,r,i=e[0];t=e[1]/500+(n=(i+16)/116),r=n-e[2]/200;var o=Math.pow(n,3),a=Math.pow(t,3),s=Math.pow(r,3);return n=o>.008856?o:(n-16/116)/7.787,t=a>.008856?a:(t-16/116)/7.787,r=s>.008856?s:(r-16/116)/7.787,[t*=95.047,n*=100,r*=108.883]},a.lab.lch=function(e){var t,n=e[0],r=e[1],i=e[2];return(t=360*Math.atan2(i,r)/2/Math.PI)<0&&(t+=360),[n,Math.sqrt(r*r+i*i),t]},a.lch.lab=function(e){var t,n=e[0],r=e[1];return t=e[2]/360*2*Math.PI,[n,r*Math.cos(t),r*Math.sin(t)]},a.rgb.ansi16=function(e){var t=e[0],n=e[1],r=e[2],i=1 in arguments?arguments[1]:a.rgb.hsv(e)[2];if(0===(i=Math.round(i/50)))return 30;var o=30+(Math.round(r/255)<<2|Math.round(n/255)<<1|Math.round(t/255));return 2===i&&(o+=60),o},a.hsv.ansi16=function(e){return a.rgb.ansi16(a.hsv.rgb(e),e[2])},a.rgb.ansi256=function(e){var t=e[0],n=e[1],r=e[2];return t===n&&n===r?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(n/255*5)+Math.round(r/255*5)},a.ansi16.rgb=function(e){var t=e%10;if(0===t||7===t)return e>50&&(t+=3.5),[t=t/10.5*255,t,t];var n=.5*(1+~~(e>50));return[(1&t)*n*255,(t>>1&1)*n*255,(t>>2&1)*n*255]},a.ansi256.rgb=function(e){if(e>=232){var t=10*(e-232)+8;return[t,t,t]}var n;return e-=16,[Math.floor(e/36)/5*255,Math.floor((n=e%36)/6)/5*255,n%6/5*255]},a.rgb.hex=function(e){var t=(((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2]))).toString(16).toUpperCase();return"000000".substring(t.length)+t},a.hex.rgb=function(e){var t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];var n=t[0];3===t[0].length&&(n=n.split("").map((function(e){return e+e})).join(""));var r=parseInt(n,16);return[r>>16&255,r>>8&255,255&r]},a.rgb.hcg=function(e){var t,n=e[0]/255,r=e[1]/255,i=e[2]/255,o=Math.max(Math.max(n,r),i),a=Math.min(Math.min(n,r),i),s=o-a;return t=s<=0?0:o===n?(r-i)/s%6:o===r?2+(i-n)/s:4+(n-r)/s+4,t/=6,[360*(t%=1),100*s,100*(s<1?a/(1-s):0)]},a.hsl.hcg=function(e){var t=e[1]/100,n=e[2]/100,r=1,i=0;return(r=n<.5?2*t*n:2*t*(1-n))<1&&(i=(n-.5*r)/(1-r)),[e[0],100*r,100*i]},a.hsv.hcg=function(e){var t=e[1]/100,n=e[2]/100,r=t*n,i=0;return r<1&&(i=(n-r)/(1-r)),[e[0],100*r,100*i]},a.hcg.rgb=function(e){var t=e[0]/360,n=e[1]/100,r=e[2]/100;if(0===n)return[255*r,255*r,255*r];var i,o=[0,0,0],a=t%1*6,s=a%1,u=1-s;switch(Math.floor(a)){case 0:o[0]=1,o[1]=s,o[2]=0;break;case 1:o[0]=u,o[1]=1,o[2]=0;break;case 2:o[0]=0,o[1]=1,o[2]=s;break;case 3:o[0]=0,o[1]=u,o[2]=1;break;case 4:o[0]=s,o[1]=0,o[2]=1;break;default:o[0]=1,o[1]=0,o[2]=u}return i=(1-n)*r,[255*(n*o[0]+i),255*(n*o[1]+i),255*(n*o[2]+i)]},a.hcg.hsv=function(e){var t=e[1]/100,n=t+e[2]/100*(1-t),r=0;return n>0&&(r=t/n),[e[0],100*r,100*n]},a.hcg.hsl=function(e){var t=e[1]/100,n=e[2]/100*(1-t)+.5*t,r=0;return n>0&&n<.5?r=t/(2*n):n>=.5&&n<1&&(r=t/(2*(1-n))),[e[0],100*r,100*n]},a.hcg.hwb=function(e){var t=e[1]/100,n=t+e[2]/100*(1-t);return[e[0],100*(n-t),100*(1-n)]},a.hwb.hcg=function(e){var t=e[1]/100,n=1-e[2]/100,r=n-t,i=0;return r<1&&(i=(n-r)/(1-r)),[e[0],100*r,100*i]},a.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},a.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},a.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},a.gray.hsl=a.gray.hsv=function(e){return[0,0,e[0]]},a.gray.hwb=function(e){return[0,100,e[0]]},a.gray.cmyk=function(e){return[0,0,0,e[0]]},a.gray.lab=function(e){return[e[0],0,0]},a.gray.hex=function(e){var t=255&Math.round(e[0]/100*255),n=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(n.length)+n},a.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n){const a=function(e,t){t=Object.assign({allowReturnOutsideFunction:!0,allowSuperOutsideMethod:!0,sourceType:"module"},t,{plugins:(t.plugins||[]).concat("placeholders")});try{return(0,i.parse)(e,t)}catch(t){const n=t.loc;throw n&&(t.message+="\n"+(0,o.codeFrameColumns)(e,{start:n}),t.code="BABEL_TEMPLATE_PARSE_ERROR"),t}}(t,n.parser),{placeholderWhitelist:s,placeholderPattern:c,preserveComments:l,syntacticPlaceholders:f}=n;r.removePropertiesDeep(a,{preserveComments:l}),e.validate(a);const p={placeholders:[],placeholderNames:new Set},h={placeholders:[],placeholderNames:new Set},d={value:void 0};return r.traverse(a,u,{syntactic:p,legacy:h,isLegacyRef:d,placeholderWhitelist:s,placeholderPattern:c,syntacticPlaceholders:f}),Object.assign({ast:a},d.value?h:p)};var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=a();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(n(0)),i=n(38),o=n(37);function a(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return a=function(){return e},e}const s=/^[_$A-Z0-9]+$/;function u(e,t,n){let i;if(r.isPlaceholder(e)){if(!1===n.syntacticPlaceholders)throw new Error("%%foo%%-style placeholders can't be used when '.syntacticPlaceholders' is false.");i=e.name.name,n.isLegacyRef.value=!1}else{if(!1===n.isLegacyRef.value||n.syntacticPlaceholders)return;if(r.isIdentifier(e)||r.isJSXIdentifier(e))i=e.name,n.isLegacyRef.value=!0;else{if(!r.isStringLiteral(e))return;i=e.value,n.isLegacyRef.value=!0}}if(!n.isLegacyRef.value&&(null!=n.placeholderPattern||null!=n.placeholderWhitelist))throw new Error("'.placeholderWhitelist' and '.placeholderPattern' aren't compatible with '.syntacticPlaceholders: true'");if(n.isLegacyRef.value&&(!1===n.placeholderPattern||!(n.placeholderPattern||s).test(i))&&(!n.placeholderWhitelist||!n.placeholderWhitelist.has(i)))return;t=t.slice();const{node:o,key:a}=t[t.length-1];let u;r.isStringLiteral(e)||r.isPlaceholder(e,{expectedNode:"StringLiteral"})?u="string":r.isNewExpression(o)&&"arguments"===a||r.isCallExpression(o)&&"arguments"===a||r.isFunction(o)&&"params"===a?u="param":r.isExpressionStatement(o)&&!r.isPlaceholder(e)?(u="statement",t=t.slice(0,-1)):u=r.isStatement(e)&&r.isPlaceholder(e)?"statement":"other";const{placeholders:c,placeholderNames:l}=n.isLegacyRef.value?n.legacy:n.syntactic;c.push({name:i,type:u,resolve:e=>function(e,t){let n=e;for(let e=0;e{if(!Object.prototype.hasOwnProperty.call(t,e.name)){const t=e.name;throw new Error(`Error: No substitution given for "${t}". If this is not meant to be a\n placeholder you may want to consider passing one of the following options to @babel/template:\n - { placeholderPattern: false, placeholderWhitelist: new Set(['${t}'])}\n - { placeholderPattern: /^${t}$/ }`)}}),Object.keys(t).forEach(t=>{if(!e.placeholderNames.has(t))throw new Error(`Unknown substitution "${t}" given`)}));return e.placeholders.slice().reverse().forEach(e=>{try{!function(e,t,n){e.isDuplicate&&(Array.isArray(n)?n=n.map(e=>r.cloneNode(e)):"object"==typeof n&&(n=r.cloneNode(n)));const{parent:i,key:o,index:a}=e.resolve(t);if("string"===e.type){if("string"==typeof n&&(n=r.stringLiteral(n)),!n||!r.isStringLiteral(n))throw new Error("Expected string substitution")}else if("statement"===e.type)void 0===a?n?Array.isArray(n)?n=r.blockStatement(n):"string"==typeof n?n=r.expressionStatement(r.identifier(n)):r.isStatement(n)||(n=r.expressionStatement(n)):n=r.emptyStatement():n&&!Array.isArray(n)&&("string"==typeof n&&(n=r.identifier(n)),r.isStatement(n)||(n=r.expressionStatement(n)));else if("param"===e.type){if("string"==typeof n&&(n=r.identifier(n)),void 0===a)throw new Error("Assertion failure.")}else if("string"==typeof n&&(n=r.identifier(n)),Array.isArray(n))throw new Error("Cannot replace single expression with an array.");if(void 0===a)r.validate(i,o,n),i[o]=n;else{const t=i[o].slice();"statement"===e.type||"param"===e.type?null==n?t.splice(a,1):Array.isArray(n)?t.splice(a,1,...n):t[a]=n:t[a]=n,r.validate(i,o,t),i[o]=t}}(e,n,t&&t[e.name]||null)}catch(t){throw t.message=`@babel/template placeholder "${e.name}": ${t.message}`,t}}),n};var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=r?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(0));function i(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}},function(e,t,n){(function(n){var r;t=e.exports=W,r="object"==typeof n&&n.env&&n.env.NODE_DEBUG&&/\bsemver\b/i.test(n.env.NODE_DEBUG)?function(){var e=Array.prototype.slice.call(arguments,0);e.unshift("SEMVER"),console.log.apply(console,e)}:function(){},t.SEMVER_SPEC_VERSION="2.0.0";var i=Number.MAX_SAFE_INTEGER||9007199254740991,o=t.re=[],a=t.src=[],s=0,u=s++;a[u]="0|[1-9]\\d*";var c=s++;a[c]="[0-9]+";var l=s++;a[l]="\\d*[a-zA-Z-][a-zA-Z0-9-]*";var f=s++;a[f]="("+a[u]+")\\.("+a[u]+")\\.("+a[u]+")";var p=s++;a[p]="("+a[c]+")\\.("+a[c]+")\\.("+a[c]+")";var h=s++;a[h]="(?:"+a[u]+"|"+a[l]+")";var d=s++;a[d]="(?:"+a[c]+"|"+a[l]+")";var y=s++;a[y]="(?:-("+a[h]+"(?:\\."+a[h]+")*))";var m=s++;a[m]="(?:-?("+a[d]+"(?:\\."+a[d]+")*))";var v=s++;a[v]="[0-9A-Za-z-]+";var b=s++;a[b]="(?:\\+("+a[v]+"(?:\\."+a[v]+")*))";var g=s++,w="v?"+a[f]+a[y]+"?"+a[b]+"?";a[g]="^"+w+"$";var S="[v=\\s]*"+a[p]+a[m]+"?"+a[b]+"?",O=s++;a[O]="^"+S+"$";var P=s++;a[P]="((?:<|>)?=?)";var k=s++;a[k]=a[c]+"|x|X|\\*";var x=s++;a[x]=a[u]+"|x|X|\\*";var E=s++;a[E]="[v=\\s]*("+a[x]+")(?:\\.("+a[x]+")(?:\\.("+a[x]+")(?:"+a[y]+")?"+a[b]+"?)?)?";var j=s++;a[j]="[v=\\s]*("+a[k]+")(?:\\.("+a[k]+")(?:\\.("+a[k]+")(?:"+a[m]+")?"+a[b]+"?)?)?";var T=s++;a[T]="^"+a[P]+"\\s*"+a[E]+"$";var C=s++;a[C]="^"+a[P]+"\\s*"+a[j]+"$";var _=s++;a[_]="(?:^|[^\\d])(\\d{1,16})(?:\\.(\\d{1,16}))?(?:\\.(\\d{1,16}))?(?:$|[^\\d])";var A=s++;a[A]="(?:~>?)";var D=s++;a[D]="(\\s*)"+a[A]+"\\s+",o[D]=new RegExp(a[D],"g");var I=s++;a[I]="^"+a[A]+a[E]+"$";var F=s++;a[F]="^"+a[A]+a[j]+"$";var $=s++;a[$]="(?:\\^)";var M=s++;a[M]="(\\s*)"+a[$]+"\\s+",o[M]=new RegExp(a[M],"g");var R=s++;a[R]="^"+a[$]+a[E]+"$";var L=s++;a[L]="^"+a[$]+a[j]+"$";var B=s++;a[B]="^"+a[P]+"\\s*("+S+")$|^$";var N=s++;a[N]="^"+a[P]+"\\s*("+w+")$|^$";var V=s++;a[V]="(\\s*)"+a[P]+"\\s*("+S+"|"+a[E]+")",o[V]=new RegExp(a[V],"g");var z=s++;a[z]="^\\s*("+a[E]+")\\s+-\\s+("+a[E]+")\\s*$";var G=s++;a[G]="^\\s*("+a[j]+")\\s+-\\s+("+a[j]+")\\s*$";var H=s++;a[H]="(<|>)?=?\\s*\\*";for(var U=0;U<35;U++)r(U,a[U]),o[U]||(o[U]=new RegExp(a[U]));function Y(e,t){if(t&&"object"==typeof t||(t={loose:!!t,includePrerelease:!1}),e instanceof W)return e;if("string"!=typeof e)return null;if(e.length>256)return null;if(!(t.loose?o[O]:o[g]).test(e))return null;try{return new W(e,t)}catch(e){return null}}function W(e,t){if(t&&"object"==typeof t||(t={loose:!!t,includePrerelease:!1}),e instanceof W){if(e.loose===t.loose)return e;e=e.version}else if("string"!=typeof e)throw new TypeError("Invalid Version: "+e);if(e.length>256)throw new TypeError("version is longer than 256 characters");if(!(this instanceof W))return new W(e,t);r("SemVer",e,t),this.options=t,this.loose=!!t.loose;var n=e.trim().match(t.loose?o[O]:o[g]);if(!n)throw new TypeError("Invalid Version: "+e);if(this.raw=e,this.major=+n[1],this.minor=+n[2],this.patch=+n[3],this.major>i||this.major<0)throw new TypeError("Invalid major version");if(this.minor>i||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>i||this.patch<0)throw new TypeError("Invalid patch version");n[4]?this.prerelease=n[4].split(".").map((function(e){if(/^[0-9]+$/.test(e)){var t=+e;if(t>=0&&t=0;)"number"==typeof this.prerelease[n]&&(this.prerelease[n]++,n=-2);-1===n&&this.prerelease.push(0)}t&&(this.prerelease[0]===t?isNaN(this.prerelease[1])&&(this.prerelease=[t,0]):this.prerelease=[t,0]);break;default:throw new Error("invalid increment argument: "+e)}return this.format(),this.raw=this.version,this},t.inc=function(e,t,n,r){"string"==typeof n&&(r=n,n=void 0);try{return new W(e,n).inc(t,r).version}catch(e){return null}},t.diff=function(e,t){if(Q(e,t))return null;var n=Y(e),r=Y(t),i="";if(n.prerelease.length||r.prerelease.length){i="pre";var o="prerelease"}for(var a in n)if(("major"===a||"minor"===a||"patch"===a)&&n[a]!==r[a])return i+a;return o},t.compareIdentifiers=K;var X=/^[0-9]+$/;function K(e,t){var n=X.test(e),r=X.test(t);return n&&r&&(e=+e,t=+t),e===t?0:n&&!r?-1:r&&!n?1:e0}function Z(e,t,n){return q(e,t,n)<0}function Q(e,t,n){return 0===q(e,t,n)}function ee(e,t,n){return 0!==q(e,t,n)}function te(e,t,n){return q(e,t,n)>=0}function ne(e,t,n){return q(e,t,n)<=0}function re(e,t,n,r){switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof n&&(n=n.version),e===n;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof n&&(n=n.version),e!==n;case"":case"=":case"==":return Q(e,n,r);case"!=":return ee(e,n,r);case">":return J(e,n,r);case">=":return te(e,n,r);case"<":return Z(e,n,r);case"<=":return ne(e,n,r);default:throw new TypeError("Invalid operator: "+t)}}function ie(e,t){if(t&&"object"==typeof t||(t={loose:!!t,includePrerelease:!1}),e instanceof ie){if(e.loose===!!t.loose)return e;e=e.value}if(!(this instanceof ie))return new ie(e,t);r("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===oe?this.value="":this.value=this.operator+this.semver.version,r("comp",this)}t.rcompareIdentifiers=function(e,t){return K(t,e)},t.major=function(e,t){return new W(e,t).major},t.minor=function(e,t){return new W(e,t).minor},t.patch=function(e,t){return new W(e,t).patch},t.compare=q,t.compareLoose=function(e,t){return q(e,t,!0)},t.rcompare=function(e,t,n){return q(t,e,n)},t.sort=function(e,n){return e.sort((function(e,r){return t.compare(e,r,n)}))},t.rsort=function(e,n){return e.sort((function(e,r){return t.rcompare(e,r,n)}))},t.gt=J,t.lt=Z,t.eq=Q,t.neq=ee,t.gte=te,t.lte=ne,t.cmp=re,t.Comparator=ie;var oe={};function ae(e,t){if(t&&"object"==typeof t||(t={loose:!!t,includePrerelease:!1}),e instanceof ae)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new ae(e.raw,t);if(e instanceof ie)return new ae(e.value,t);if(!(this instanceof ae))return new ae(e,t);if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e,this.set=e.split(/\s*\|\|\s*/).map((function(e){return this.parseRange(e.trim())}),this).filter((function(e){return e.length})),!this.set.length)throw new TypeError("Invalid SemVer Range: "+e);this.format()}function se(e){return!e||"x"===e.toLowerCase()||"*"===e}function ue(e,t,n,r,i,o,a,s,u,c,l,f,p){return((t=se(n)?"":se(r)?">="+n+".0.0":se(i)?">="+n+"."+r+".0":">="+t)+" "+(s=se(u)?"":se(c)?"<"+(+u+1)+".0.0":se(l)?"<"+u+"."+(+c+1)+".0":f?"<="+u+"."+c+"."+l+"-"+f:"<="+s)).trim()}function ce(e,t,n){for(var i=0;i0){var o=e[i].semver;if(o.major===t.major&&o.minor===t.minor&&o.patch===t.patch)return!0}return!1}return!0}function le(e,t,n){try{t=new ae(t,n)}catch(e){return!1}return t.test(e)}function fe(e,t,n,r){var i,o,a,s,u;switch(e=new W(e,r),t=new ae(t,r),n){case">":i=J,o=ne,a=Z,s=">",u=">=";break;case"<":i=Z,o=te,a=J,s="<",u="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(le(e,t,r))return!1;for(var c=0;c=0.0.0")),f=f||e,p=p||e,i(e.semver,f.semver,r)?f=e:a(e.semver,p.semver,r)&&(p=e)})),f.operator===s||f.operator===u)return!1;if((!p.operator||p.operator===s)&&o(e,p.semver))return!1;if(p.operator===u&&a(e,p.semver))return!1}return!0}ie.prototype.parse=function(e){var t=this.options.loose?o[B]:o[N],n=e.match(t);if(!n)throw new TypeError("Invalid comparator: "+e);this.operator=n[1],"="===this.operator&&(this.operator=""),n[2]?this.semver=new W(n[2],this.options.loose):this.semver=oe},ie.prototype.toString=function(){return this.value},ie.prototype.test=function(e){return r("Comparator.test",e,this.options.loose),this.semver===oe||("string"==typeof e&&(e=new W(e,this.options)),re(e,this.operator,this.semver,this.options))},ie.prototype.intersects=function(e,t){if(!(e instanceof ie))throw new TypeError("a Comparator is required");var n;if(t&&"object"==typeof t||(t={loose:!!t,includePrerelease:!1}),""===this.operator)return n=new ae(e.value,t),le(this.value,n,t);if(""===e.operator)return n=new ae(this.value,t),le(e.semver,n,t);var r=!(">="!==this.operator&&">"!==this.operator||">="!==e.operator&&">"!==e.operator),i=!("<="!==this.operator&&"<"!==this.operator||"<="!==e.operator&&"<"!==e.operator),o=this.semver.version===e.semver.version,a=!(">="!==this.operator&&"<="!==this.operator||">="!==e.operator&&"<="!==e.operator),s=re(this.semver,"<",e.semver,t)&&(">="===this.operator||">"===this.operator)&&("<="===e.operator||"<"===e.operator),u=re(this.semver,">",e.semver,t)&&("<="===this.operator||"<"===this.operator)&&(">="===e.operator||">"===e.operator);return r||i||o&&a||s||u},t.Range=ae,ae.prototype.format=function(){return this.range=this.set.map((function(e){return e.join(" ").trim()})).join("||").trim(),this.range},ae.prototype.toString=function(){return this.range},ae.prototype.parseRange=function(e){var t=this.options.loose;e=e.trim();var n=t?o[G]:o[z];e=e.replace(n,ue),r("hyphen replace",e),e=e.replace(o[V],"$1$2$3"),r("comparator trim",e,o[V]),e=(e=(e=e.replace(o[D],"$1~")).replace(o[M],"$1^")).split(/\s+/).join(" ");var i=t?o[B]:o[N],a=e.split(" ").map((function(e){return function(e,t){return r("comp",e,t),e=function(e,t){return e.trim().split(/\s+/).map((function(e){return function(e,t){r("caret",e,t);var n=t.loose?o[L]:o[R];return e.replace(n,(function(t,n,i,o,a){var s;return r("caret",e,t,n,i,o,a),se(n)?s="":se(i)?s=">="+n+".0.0 <"+(+n+1)+".0.0":se(o)?s="0"===n?">="+n+"."+i+".0 <"+n+"."+(+i+1)+".0":">="+n+"."+i+".0 <"+(+n+1)+".0.0":a?(r("replaceCaret pr",a),s="0"===n?"0"===i?">="+n+"."+i+"."+o+"-"+a+" <"+n+"."+i+"."+(+o+1):">="+n+"."+i+"."+o+"-"+a+" <"+n+"."+(+i+1)+".0":">="+n+"."+i+"."+o+"-"+a+" <"+(+n+1)+".0.0"):(r("no pr"),s="0"===n?"0"===i?">="+n+"."+i+"."+o+" <"+n+"."+i+"."+(+o+1):">="+n+"."+i+"."+o+" <"+n+"."+(+i+1)+".0":">="+n+"."+i+"."+o+" <"+(+n+1)+".0.0"),r("caret return",s),s}))}(e,t)})).join(" ")}(e,t),r("caret",e),e=function(e,t){return e.trim().split(/\s+/).map((function(e){return function(e,t){var n=t.loose?o[F]:o[I];return e.replace(n,(function(t,n,i,o,a){var s;return r("tilde",e,t,n,i,o,a),se(n)?s="":se(i)?s=">="+n+".0.0 <"+(+n+1)+".0.0":se(o)?s=">="+n+"."+i+".0 <"+n+"."+(+i+1)+".0":a?(r("replaceTilde pr",a),s=">="+n+"."+i+"."+o+"-"+a+" <"+n+"."+(+i+1)+".0"):s=">="+n+"."+i+"."+o+" <"+n+"."+(+i+1)+".0",r("tilde return",s),s}))}(e,t)})).join(" ")}(e,t),r("tildes",e),e=function(e,t){return r("replaceXRanges",e,t),e.split(/\s+/).map((function(e){return function(e,t){e=e.trim();var n=t.loose?o[C]:o[T];return e.replace(n,(function(t,n,i,o,a,s){r("xRange",e,t,n,i,o,a,s);var u=se(i),c=u||se(o),l=c||se(a);return"="===n&&l&&(n=""),u?t=">"===n||"<"===n?"<0.0.0":"*":n&&l?(c&&(o=0),a=0,">"===n?(n=">=",c?(i=+i+1,o=0,a=0):(o=+o+1,a=0)):"<="===n&&(n="<",c?i=+i+1:o=+o+1),t=n+i+"."+o+"."+a):c?t=">="+i+".0.0 <"+(+i+1)+".0.0":l&&(t=">="+i+"."+o+".0 <"+i+"."+(+o+1)+".0"),r("xRange return",t),t}))}(e,t)})).join(" ")}(e,t),r("xrange",e),e=function(e,t){return r("replaceStars",e,t),e.trim().replace(o[H],"")}(e,t),r("stars",e),e}(e,this.options)}),this).join(" ").split(/\s+/);return this.options.loose&&(a=a.filter((function(e){return!!e.match(i)}))),a=a.map((function(e){return new ie(e,this.options)}),this)},ae.prototype.intersects=function(e,t){if(!(e instanceof ae))throw new TypeError("a Range is required");return this.set.some((function(n){return n.every((function(n){return e.set.some((function(e){return e.every((function(e){return n.intersects(e,t)}))}))}))}))},t.toComparators=function(e,t){return new ae(e,t).set.map((function(e){return e.map((function(e){return e.value})).join(" ").trim().split(" ")}))},ae.prototype.test=function(e){if(!e)return!1;"string"==typeof e&&(e=new W(e,this.options));for(var t=0;t":0===t.prerelease.length?t.patch++:t.prerelease.push(0),t.raw=t.format();case"":case">=":n&&!J(n,t)||(n=t);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+e.operator)}}))}if(n&&e.test(n))return n;return null},t.validRange=function(e,t){try{return new ae(e,t).range||"*"}catch(e){return null}},t.ltr=function(e,t,n){return fe(e,t,"<",n)},t.gtr=function(e,t,n){return fe(e,t,">",n)},t.outside=fe,t.prerelease=function(e,t){var n=Y(e,t);return n&&n.prerelease.length?n.prerelease:null},t.intersects=function(e,t,n){return e=new ae(e,n),t=new ae(t,n),e.intersects(t)},t.coerce=function(e){if(e instanceof W)return e;if("string"!=typeof e)return null;var t=e.match(o[_]);if(null==t)return null;return Y(t[1]+"."+(t[2]||"0")+"."+(t[3]||"0"))}}).call(this,n(9))},function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.getEnv=function(t="development"){return e.env.BABEL_ENV||"production"}}).call(this,n(9))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createCachedDescriptors=function(e,t,n){const{plugins:r,presets:i,passPerPreset:o}=t;return{options:t,plugins:r?()=>c(r,e)(n):()=>[],presets:i?()=>s(i,e)(n)(!!o):()=>[]}},t.createUncachedDescriptors=function(e,t,n){let r,i;return{options:t,plugins:()=>(r||(r=h(t.plugins||[],e,n)),r),presets:()=>(i||(i=p(t.presets||[],e,n,!!t.passPerPreset)),i)}},t.createDescriptor=y;var r=n(40),i=n(41),o=n(42);const a=new WeakMap,s=(0,o.makeWeakCache)((e,t)=>{const n=t.using(e=>e);return(0,o.makeStrongCache)(t=>(0,o.makeStrongCache)(r=>p(e,n,t,r).map(e=>f(a,e))))}),u=new WeakMap,c=(0,o.makeWeakCache)((e,t)=>{const n=t.using(e=>e);return(0,o.makeStrongCache)(t=>h(e,n,t).map(e=>f(u,e)))}),l={};function f(e,t){const{value:n,options:r=l}=t;if(!1===r)return t;let i=e.get(n);i||(i=new WeakMap,e.set(n,i));let o=i.get(r);if(o||(o=[],i.set(r,o)),-1===o.indexOf(t)){const e=o.filter(e=>{return r=t,(n=e).name===r.name&&n.value===r.value&&n.options===r.options&&n.dirname===r.dirname&&n.alias===r.alias&&n.ownPass===r.ownPass&&(n.file&&n.file.request)===(r.file&&r.file.request)&&(n.file&&n.file.resolved)===(r.file&&r.file.resolved);var n,r});if(e.length>0)return e[0];o.push(t)}return t}function p(e,t,n,r){return d("preset",e,t,n,r)}function h(e,t,n){return d("plugin",e,t,n)}function d(e,t,n,r,i){const o=t.map((t,o)=>y(t,n,{type:e,alias:`${r}$${o}`,ownPass:!!i}));return function(e){const t=new Map;for(const n of e){if("function"!=typeof n.value)continue;let r=t.get(n.value);if(r||(r=new Set,t.set(n.value,r)),r.has(n.name)){const t=e.filter(e=>e.value===n.value);throw new Error(["Duplicate plugin/preset detected.","If you'd like to use two separate instances of a plugin,","they need separate names, e.g.",""," plugins: ["," ['some-plugin', {}],"," ['some-plugin', {}, 'some unique name'],"," ]","","Duplicates detected are:",`${JSON.stringify(t,null,2)}`].join("\n"))}r.add(n.name)}}(o),o}function y(e,t,{type:n,alias:o,ownPass:a}){const s=(0,i.getItemDescriptor)(e);if(s)return s;let u,c,l=e;Array.isArray(l)&&(3===l.length?[l,c,u]=l:[l,c]=l);let f=void 0,p=null;if("string"==typeof l){if("string"!=typeof n)throw new Error("To resolve a string-based item, the type of item must be given");const e="plugin"===n?r.loadPlugin:r.loadPreset,i=l;({filepath:p,value:l}=e(l,t)),f={request:i,resolved:p}}if(!l)throw new Error(`Unexpected falsy value: ${String(l)}`);if("object"==typeof l&&l.__esModule){if(!l.default)throw new Error("Must export a default export when using ES6 modules.");l=l.default}if("object"!=typeof l&&"function"!=typeof l)throw new Error(`Unsupported format: ${typeof l}. Expected an object or a function.`);if(null!==p&&"object"==typeof l&&l)throw new Error(`Plugin/Preset files are not allowed to export objects, only functions. In ${p}`);return{name:u,alias:p||o,value:l,options:c,dirname:t,ownPass:a,file:f}}},function(e,t,n){"use strict";function r(e,t){for(const n of Object.keys(t)){const r=t[n];void 0!==r&&(e[n]=r)}}Object.defineProperty(t,"__esModule",{value:!0}),t.mergeOptions=function(e,t){for(const n of Object.keys(t))if("parserOpts"===n&&t.parserOpts){const n=t.parserOpts;r(e.parserOpts=e.parserOpts||{},n)}else if("generatorOpts"===n&&t.generatorOpts){const n=t.generatorOpts;r(e.generatorOpts=e.generatorOpts||{},n)}else{const r=t[n];void 0!==r&&(e[n]=r)}}},function(e,t,n){"use strict";function r(){const e=l(n(15));return r=function(){return e},e}function i(){const e=l(n(67));return i=function(){return e},e}Object.defineProperty(t,"__esModule",{value:!0}),t.buildPresetChain=function(e,t){const n=p(e,t);return n?{plugins:$(n.plugins),presets:$(n.presets),options:n.options.map(e=>F(e))}:null},t.buildRootChain=function(e,t){const n=w({options:e,dirname:t.cwd},t);if(!n)return null;let i;"string"==typeof e.configFile?i=(0,s.loadConfig)(e.configFile,t.cwd,t.envName,t.caller):!1!==e.configFile&&(i=(0,s.findRootConfig)(t.root,t.envName,t.caller));let{babelrc:o,babelrcRoots:u}=e,c=t.cwd;const l={options:[],presets:[],plugins:[]};if(i){const e=v(i),n=S(e,t);if(!n)return null;void 0===o&&(o=e.options.babelrc),void 0===u&&(c=e.dirname,u=e.options.babelrcRoots),D(l,n)}const f="string"==typeof t.filename?(0,s.findPackageData)(t.filename):null;let p,h;const d={options:[],presets:[],plugins:[]};if((!0===o||void 0===o)&&f&&function(e,t,n,i){if("boolean"==typeof n)return n;const o=e.root;if(void 0===n)return-1!==t.directories.indexOf(o);let s=n;Array.isArray(s)||(s=[s]);if(s=s.map(e=>"string"==typeof e?r().default.resolve(i,e):e),1===s.length&&s[0]===o)return-1!==t.directories.indexOf(o);return s.some(n=>("string"==typeof n&&(n=(0,a.default)(n,i)),t.directories.some(t=>N(n,i,t,e))))}(t,f,u,c)){if(({ignore:p,config:h}=(0,s.findRelativeConfig)(f,t.envName,t.caller)),p&&L(t,p.ignore,null,p.dirname))return null;if(h){const e=S(b(h),t);if(!e)return null;D(d,e)}}const y=D(D(D({options:[],presets:[],plugins:[]},l),d),n);return{plugins:$(y.plugins),presets:$(y.presets),options:y.options.map(e=>F(e)),ignore:p||void 0,babelrc:h||void 0,config:i||void 0}},t.buildPresetChainWalker=void 0;var o=n(76),a=l(n(364)),s=n(40),u=n(42),c=n(138);function l(e){return e&&e.__esModule?e:{default:e}}const f=(0,i().default)("babel:config:config-chain");const p=_({init:e=>e,root:e=>h(e),env:(e,t)=>d(e)(t),overrides:(e,t)=>y(e)(t),overridesEnv:(e,t,n)=>m(e)(t)(n)});t.buildPresetChainWalker=p;const h=(0,u.makeWeakCache)(e=>E(e,e.alias,c.createUncachedDescriptors)),d=(0,u.makeWeakCache)(e=>(0,u.makeStrongCache)(t=>j(e,e.alias,c.createUncachedDescriptors,t))),y=(0,u.makeWeakCache)(e=>(0,u.makeStrongCache)(t=>T(e,e.alias,c.createUncachedDescriptors,t))),m=(0,u.makeWeakCache)(e=>(0,u.makeStrongCache)(t=>(0,u.makeStrongCache)(n=>C(e,e.alias,c.createUncachedDescriptors,t,n))));const v=(0,u.makeWeakCache)(e=>({filepath:e.filepath,dirname:e.dirname,options:(0,o.validate)("configfile",e.options)})),b=(0,u.makeWeakCache)(e=>({filepath:e.filepath,dirname:e.dirname,options:(0,o.validate)("babelrcfile",e.options)})),g=(0,u.makeWeakCache)(e=>({filepath:e.filepath,dirname:e.dirname,options:(0,o.validate)("extendsfile",e.options)})),w=_({root:e=>E(e,"base",c.createCachedDescriptors),env:(e,t)=>j(e,"base",c.createCachedDescriptors,t),overrides:(e,t)=>T(e,"base",c.createCachedDescriptors,t),overridesEnv:(e,t,n)=>C(e,"base",c.createCachedDescriptors,t,n)}),S=_({root:e=>O(e),env:(e,t)=>P(e)(t),overrides:(e,t)=>k(e)(t),overridesEnv:(e,t,n)=>x(e)(t)(n)}),O=(0,u.makeWeakCache)(e=>E(e,e.filepath,c.createUncachedDescriptors)),P=(0,u.makeWeakCache)(e=>(0,u.makeStrongCache)(t=>j(e,e.filepath,c.createUncachedDescriptors,t))),k=(0,u.makeWeakCache)(e=>(0,u.makeStrongCache)(t=>T(e,e.filepath,c.createUncachedDescriptors,t))),x=(0,u.makeWeakCache)(e=>(0,u.makeStrongCache)(t=>(0,u.makeStrongCache)(n=>C(e,e.filepath,c.createUncachedDescriptors,t,n))));function E({dirname:e,options:t},n,r){return r(e,t,n)}function j({dirname:e,options:t},n,r,i){const o=t.env&&t.env[i];return o?r(e,o,`${n}.env["${i}"]`):null}function T({dirname:e,options:t},n,r,i){const o=t.overrides&&t.overrides[i];if(!o)throw new Error("Assertion failure - missing override");return r(e,o,`${n}.overrides[${i}]`)}function C({dirname:e,options:t},n,r,i,o){const a=t.overrides&&t.overrides[i];if(!a)throw new Error("Assertion failure - missing override");const s=a.env&&a.env[o];return s?r(e,s,`${n}.overrides[${i}].env["${o}"]`):null}function _({root:e,env:t,overrides:n,overridesEnv:r}){return(i,o,a=new Set)=>{const{dirname:s}=i,u=[],c=e(i);if(M(c,s,o)){u.push(c);const e=t(i,o.envName);e&&M(e,s,o)&&u.push(e),(c.options.overrides||[]).forEach((e,t)=>{const a=n(i,t);if(M(a,s,o)){u.push(a);const e=r(i,t,o.envName);e&&M(e,s,o)&&u.push(e)}})}if(u.some(({options:{ignore:e,only:t}})=>L(o,e,t,s)))return null;const l={options:[],presets:[],plugins:[]};for(const e of u){if(!A(l,e.options,s,o,a))return null;I(l,e)}return l}}function A(e,t,n,r,i){if(void 0===t.extends)return!0;const o=(0,s.loadConfig)(t.extends,n,r.envName,r.caller);if(i.has(o))throw new Error(`Configuration cycle detected loading ${o.filepath}.\n`+"File already loaded following the config chain:\n"+Array.from(i,e=>` - ${e.filepath}`).join("\n"));i.add(o);const a=S(g(o),r,i);return i.delete(o),!!a&&(D(e,a),!0)}function D(e,t){return e.options.push(...t.options),e.plugins.push(...t.plugins),e.presets.push(...t.presets),e}function I(e,{options:t,plugins:n,presets:r}){return e.options.push(t),e.plugins.push(...n()),e.presets.push(...r()),e}function F(e){const t=Object.assign({},e);return delete t.extends,delete t.env,delete t.overrides,delete t.plugins,delete t.presets,delete t.passPerPreset,delete t.ignore,delete t.only,delete t.test,delete t.include,delete t.exclude,Object.prototype.hasOwnProperty.call(t,"sourceMap")&&(t.sourceMaps=t.sourceMap,delete t.sourceMap),t}function $(e){const t=new Map,n=[];for(const r of e)if("function"==typeof r.value){const e=r.value;let i=t.get(e);i||(i=new Map,t.set(e,i));let o=i.get(r.name);o?o.value=r:(o={value:r},n.push(o),r.ownPass||i.set(r.name,o))}else n.push({value:r});return n.reduce((e,t)=>(e.push(t.value),e),[])}function M({options:e},t,n){return(void 0===e.test||R(n,e.test,t))&&(void 0===e.include||R(n,e.include,t))&&(void 0===e.exclude||!R(n,e.exclude,t))}function R(e,t,n){return B(e,Array.isArray(t)?t:[t],n)}function L(e,t,n,r){return t&&B(e,t,r)?(f("Ignored %o because it matched one of %O from %o",e.filename,t,r),!0):!(!n||B(e,n,r))&&(f("Ignored %o because it failed to match one of %O from %o",e.filename,n,r),!0)}function B(e,t,n){return t.some(t=>N(t,n,e.filename,e))}function N(e,t,n,r){if("function"==typeof e)return!!e(n,{dirname:t,envName:r.envName,caller:r.caller});if("string"!=typeof n)throw new Error("Configuration contains string/RegExp pattern, but no filename was passed to Babel");return"string"==typeof e&&(e=(0,a.default)(e,t)),e.test(n)}},function(e,t,n){"use strict";function r(e){switch(e.type){case"root":return"";case"env":return`${r(e.parent)}.env["${e.name}"]`;case"overrides":return`${r(e.parent)}.overrides[${e.index}]`;case"option":return`${r(e.parent)}.${e.name}`;case"access":return`${r(e.parent)}[${JSON.stringify(e.name)}]`;default:throw new Error(`Assertion failure: Unknown type ${e.type}`)}}function i(e,t){return{type:"access",name:t,parent:e}}function o(e,t){if(void 0!==t&&("object"!=typeof t||Array.isArray(t)||!t))throw new Error(`${r(e)} must be an object, or undefined`);return t}function a(e,t){if(null!=t&&!Array.isArray(t))throw new Error(`${r(e)} must be an array, or undefined`);return t}function s(e){return"string"==typeof e||"function"==typeof e||e instanceof RegExp}function u(e,t){if(("object"!=typeof t||!t)&&"string"!=typeof t&&"function"!=typeof t)throw new Error(`${r(e)} must be a string, object, function`);return t}Object.defineProperty(t,"__esModule",{value:!0}),t.msg=r,t.access=i,t.assertRootMode=function(e,t){if(void 0!==t&&"root"!==t&&"upward"!==t&&"upward-optional"!==t)throw new Error(`${r(e)} must be a "root", "upward", "upward-optional" or undefined`);return t},t.assertSourceMaps=function(e,t){if(void 0!==t&&"boolean"!=typeof t&&"inline"!==t&&"both"!==t)throw new Error(`${r(e)} must be a boolean, "inline", "both", or undefined`);return t},t.assertCompact=function(e,t){if(void 0!==t&&"boolean"!=typeof t&&"auto"!==t)throw new Error(`${r(e)} must be a boolean, "auto", or undefined`);return t},t.assertSourceType=function(e,t){if(void 0!==t&&"module"!==t&&"script"!==t&&"unambiguous"!==t)throw new Error(`${r(e)} must be "module", "script", "unambiguous", or undefined`);return t},t.assertCallerMetadata=function(e,t){const n=o(e,t);if(n){if("string"!=typeof n.name)throw new Error(`${r(e)} set but does not contain "name" property string`);for(const t of Object.keys(n)){const o=i(e,t),a=n[t];if(null!=a&&"boolean"!=typeof a&&"string"!=typeof a&&"number"!=typeof a)throw new Error(`${r(o)} must be null, undefined, a boolean, a string, or a number.`)}}return t},t.assertInputSourceMap=function(e,t){if(void 0!==t&&"boolean"!=typeof t&&("object"!=typeof t||!t))throw new Error(`${r(e)} must be a boolean, object, or undefined`);return t},t.assertString=function(e,t){if(void 0!==t&&"string"!=typeof t)throw new Error(`${r(e)} must be a string, or undefined`);return t},t.assertFunction=function(e,t){if(void 0!==t&&"function"!=typeof t)throw new Error(`${r(e)} must be a function, or undefined`);return t},t.assertBoolean=function(e,t){if(void 0!==t&&"boolean"!=typeof t)throw new Error(`${r(e)} must be a boolean, or undefined`);return t},t.assertObject=o,t.assertArray=a,t.assertIgnoreList=function(e,t){const n=a(e,t);n&&n.forEach((t,n)=>function(e,t){if("string"!=typeof t&&"function"!=typeof t&&!(t instanceof RegExp))throw new Error(`${r(e)} must be an array of string/Function/RegExp values, or undefined`);return t}(i(e,n),t));return n},t.assertConfigApplicableTest=function(e,t){if(void 0===t)return t;if(Array.isArray(t))t.forEach((t,n)=>{if(!s(t))throw new Error(`${r(i(e,n))} must be a string/Function/RegExp.`)});else if(!s(t))throw new Error(`${r(e)} must be a string/Function/RegExp, or an array of those`);return t},t.assertConfigFileSearch=function(e,t){if(void 0!==t&&"boolean"!=typeof t&&"string"!=typeof t)throw new Error(`${r(e)} must be a undefined, a boolean, a string, `+`got ${JSON.stringify(t)}`);return t},t.assertBabelrcSearch=function(e,t){if(void 0===t||"boolean"==typeof t)return t;if(Array.isArray(t))t.forEach((t,n)=>{if(!s(t))throw new Error(`${r(i(e,n))} must be a string/Function/RegExp.`)});else if(!s(t))throw new Error(`${r(e)} must be a undefined, a boolean, a string/Function/RegExp `+`or an array of those, got ${JSON.stringify(t)}`);return t},t.assertPluginList=function(e,t){const n=a(e,t);n&&n.forEach((t,n)=>function(e,t){if(Array.isArray(t)){if(0===t.length)throw new Error(`${r(e)} must include an object`);if(t.length>3)throw new Error(`${r(e)} may only be a two-tuple or three-tuple`);if(u(i(e,0),t[0]),t.length>1){const n=t[1];if(void 0!==n&&!1!==n&&("object"!=typeof n||Array.isArray(n)||null===n))throw new Error(`${r(i(e,1))} must be an object, false, or undefined`)}if(3===t.length){const n=t[2];if(void 0!==n&&"string"!=typeof n)throw new Error(`${r(i(e,2))} must be a string, or undefined`)}}else u(e,t);return t}(i(e,n),t));return n}},function(e,t,n){"use strict";function r(){const e=f(n(15));return r=function(){return e},e}Object.defineProperty(t,"__esModule",{value:!0}),t.default=p,t.loadPartialConfig=function(e){const t=p(e);if(!t)return null;const{options:n,babelrc:r,ignore:o,config:a}=t;return(n.plugins||[]).forEach(e=>{if(e.value instanceof i.default)throw new Error("Passing cached plugin instances is not supported in babel.loadPartialConfig()")}),new h(n,r?r.filepath:void 0,o?o.filepath:void 0,a?a.filepath:void 0)};var i=f(n(75)),o=n(139),a=n(41),s=n(140),u=n(137),c=n(76),l=n(40);function f(e){return e&&e.__esModule?e:{default:e}}function p(e){if(null!=e&&("object"!=typeof e||Array.isArray(e)))throw new Error("Babel options must be an object, null, or undefined");const t=e?(0,c.validate)("arguments",e):{},{envName:n=(0,u.getEnv)(),cwd:i=".",root:f=".",rootMode:p="root",caller:h}=t,d=r().default.resolve(i),y=function(e,t){switch(t){case"root":return e;case"upward-optional":{const t=(0,l.findConfigUpwards)(e);return null===t?e:t}case"upward":{const t=(0,l.findConfigUpwards)(e);if(null!==t)return t;throw Object.assign(new Error('Babel was run with rootMode:"upward" but a root could not '+`be found when searching upward from "${e}".\n`+"One of the following config files must be in the directory tree: "+`"${l.ROOT_CONFIG_FILENAMES.join(", ")}".`),{code:"BABEL_ROOT_NOT_FOUND",dirname:e})}default:throw new Error("Assertion failure - unknown rootMode value.")}}(r().default.resolve(d,f),p),m={filename:"string"==typeof t.filename?r().default.resolve(i,t.filename):void 0,cwd:d,root:y,envName:n,caller:h},v=(0,s.buildRootChain)(t,m);if(!v)return null;const b={};return v.options.forEach(e=>{(0,o.mergeOptions)(b,e)}),b.babelrc=!1,b.configFile=!1,b.passPerPreset=!1,b.envName=m.envName,b.cwd=m.cwd,b.root=m.root,b.filename="string"==typeof m.filename?m.filename:void 0,b.plugins=v.plugins.map(e=>(0,a.createItemFromDescriptor)(e)),b.presets=v.presets.map(e=>(0,a.createItemFromDescriptor)(e)),{options:b,context:m,ignore:v.ignore,babelrc:v.babelrc,config:v.config}}class h{constructor(e,t,n,r){this.options=e,this.babelignore=n,this.babelrc=t,this.config=r,Object.freeze(this)}hasFilesystemConfig(){return void 0!==this.babelrc||void 0!==this.config}}Object.freeze(h.prototype)},function(e,t,n){"use strict";function r(){const e=c(n(7));return r=function(){return e},e}Object.defineProperty(t,"__esModule",{value:!0}),t.runAsync=function(e,t,n,r){let i;try{i=l(e,t,n)}catch(e){return r(e)}return r(null,i)},t.runSync=l;var i=c(n(369)),o=c(n(370)),a=c(n(150)),s=c(n(151)),u=c(n(408));function c(e){return e&&e.__esModule?e:{default:e}}function l(e,t,n){const c=(0,s.default)(e.passes,(0,a.default)(e),t,n),l=c.opts;try{!function(e,t){for(const n of t){const t=[],a=[],s=[];for(const r of n.concat([(0,o.default)()])){const n=new i.default(e,r.key,r.options);t.push([r,n]),a.push(n),s.push(r.visitor)}for(const[n,r]of t){const t=n.pre;if(t){if(f(t.call(r,e)))throw new Error("You appear to be using an plugin with an async .pre, which your current version of Babel does not support. If you're using a published plugin, you may need to upgrade your @babel/core version.")}}const u=r().default.visitors.merge(s,a,e.opts.wrapPluginVisitorMethod);(0,r().default)(e.ast,u,e.scope);for(const[n,r]of t){const t=n.post;if(t){if(f(t.call(r,e)))throw new Error("You appear to be using an plugin with an async .post, which your current version of Babel does not support. If you're using a published plugin, you may need to upgrade your @babel/core version.")}}}}(c,e.passes)}catch(e){var p;throw e.message=`${null!=(p=l.filename)?p:"unknown"}: ${e.message}`,e.code||(e.code="BABEL_TRANSFORM_ERROR"),e}let h,d;try{!1!==l.code&&({outputCode:h,outputMap:d}=(0,u.default)(e.passes,c))}catch(e){var y;throw e.message=`${null!=(y=l.filename)?y:"unknown"}: ${e.message}`,e.code||(e.code="BABEL_GENERATE_ERROR"),e}return{metadata:c.metadata,options:l,ast:!0===l.ast?c.ast:null,code:void 0===h?null:h,map:void 0===d?null:d,sourceType:c.ast.program.sourceType}}function f(e){return!(!e||"object"!=typeof e&&"function"!=typeof e||!e.then||"function"!=typeof e.then)}},function(e,t,n){var r=n(378),i=n(6);e.exports=function e(t,n,o,a,s){return t===n||(null==t||null==n||!i(t)&&!i(n)?t!=t&&n!=n:r(t,n,o,a,e,s))}},function(e,t,n){var r=n(109),i=n(379),o=n(111);e.exports=function(e,t,n,a,s,u){var c=1&n,l=e.length,f=t.length;if(l!=f&&!(c&&f>l))return!1;var p=u.get(e);if(p&&u.get(t))return p==t;var h=-1,d=!0,y=2&n?new r:void 0;for(u.set(e,t),u.set(t,e);++h!e.test(t)||(n=t,!1))),[t,n]}function b(e,t){let n=null;return a().traverseFast(t,t=>{[t.leadingComments,n]=v(e,t.leadingComments,n),[t.innerComments,n]=v(e,t.innerComments,n),[t.trailingComments,n]=v(e,t.trailingComments,n)}),n}},function(e,t,n){"use strict";var r=n(405),i=n(15),o=n(406);function a(e,n){var a;(n=n||{}).isFileComment&&(e=function(e,n){var o=t.mapFileCommentRegex.exec(e),a=o[1]||o[2],s=i.resolve(n,a);try{return r.readFileSync(s,"utf8")}catch(e){throw new Error("An error occurred while trying to read the map file at "+s+"\n"+e)}}(e,n.commentFileDir)),n.hasComment&&(e=function(e){return e.split(",").pop()}(e)),n.isEncoded&&(a=e,e=o.Buffer.from(a,"base64").toString()),(n.isJSON||n.isEncoded)&&(e=JSON.parse(e)),this.sourcemap=e}Object.defineProperty(t,"commentRegex",{get:function(){return/^\s*\/(?:\/|\*)[@#]\s+sourceMappingURL=data:(?:application|text)\/json;(?:charset[:=]\S+?;)?base64,(?:.*)$/gm}}),Object.defineProperty(t,"mapFileCommentRegex",{get:function(){return/(?:\/\/[@#][ \t]+sourceMappingURL=([^\s'"`]+?)[ \t]*$)|(?:\/\*[@#][ \t]+sourceMappingURL=([^\*]+?)[ \t]*(?:\*\/){1}[ \t]*$)/gm}}),a.prototype.toJSON=function(e){return JSON.stringify(this.sourcemap,null,e)},a.prototype.toBase64=function(){var e=this.toJSON();return o.Buffer.from(e,"utf8").toString("base64")},a.prototype.toComment=function(e){var t="sourceMappingURL=data:application/json;charset=utf-8;base64,"+this.toBase64();return e&&e.multiline?"/*# "+t+" */":"//# "+t},a.prototype.toObject=function(){return JSON.parse(this.toJSON())},a.prototype.addProperty=function(e,t){if(this.sourcemap.hasOwnProperty(e))throw new Error('property "'+e+'" already exists on the sourcemap, use set property instead');return this.setProperty(e,t)},a.prototype.setProperty=function(e,t){return this.sourcemap[e]=t,this},a.prototype.getProperty=function(e){return this.sourcemap[e]},t.fromObject=function(e){return new a(e)},t.fromJSON=function(e){return new a(e,{isJSON:!0})},t.fromBase64=function(e){return new a(e,{isEncoded:!0})},t.fromComment=function(e){return new a(e=e.replace(/^\/\*/g,"//").replace(/\*\/$/g,""),{isEncoded:!0,hasComment:!0})},t.fromMapFileComment=function(e,t){return new a(e,{commentFileDir:t,isFileComment:!0,isJSON:!0})},t.fromSource=function(e){var n=e.match(t.commentRegex);return n?t.fromComment(n.pop()):null},t.fromMapFileSource=function(e,n){var r=e.match(t.mapFileCommentRegex);return r?t.fromMapFileComment(r.pop(),n):null},t.removeComments=function(e){return e.replace(t.commentRegex,"")},t.removeMapFileComments=function(e){return e.replace(t.mapFileCommentRegex,"")},t.generateMapFileComment=function(e,t){var n="sourceMappingURL="+e;return t&&t.multiline?"/*# "+n+" */":"//# "+n}},,,,,,,function(e,t,n){},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,i=(r=n(10))&&r.__esModule?r:{default:r},o=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=a();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(n(0));function a(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return a=function(){return e},e}t.default=class{constructor(e,t,n,r){this.queue=null,this.parentPath=r,this.scope=e,this.state=n,this.opts=t}shouldVisit(e){const t=this.opts;if(t.enter||t.exit)return!0;if(t[e.type])return!0;const n=o.VISITOR_KEYS[e.type];if(!n||!n.length)return!1;for(const t of n)if(e[t])return!0;return!1}create(e,t,n,r){return i.default.get({parentPath:this.parentPath,parent:e,container:t,key:n,listKey:r})}maybeQueue(e,t){if(this.trap)throw new Error("Infinite cycle detected");this.queue&&(t?this.queue.push(e):this.priorityQueue.push(e))}visitMultiple(e,t,n){if(0===e.length)return!1;const r=[];for(let i=0;i=0)){if(t.push(r.node),r.visit()){n=!0;break}if(this.priorityQueue.length&&(n=this.visitQueue(this.priorityQueue),this.priorityQueue=[],this.queue=e,n))break}for(const t of e)t.popContext();return this.queue=null,n}visit(e,t){const n=e[t];return!!n&&(Array.isArray(n)?this.visitMultiple(n,e,t):this.visitSingle(e,t))}}},function(e,t,n){"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=(0,((r=n(81))&&r.__esModule?r:{default:r}).default)("React.Component");t.default=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return!!e&&/^[a-z]/.test(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){const t=[];for(let n=0;nn.length)throw new Error(`${e}: Too many arguments passed. Received ${a} but can receive no more than ${n.length}`);const s={type:e};let u=0;n.forEach(n=>{const o=i.NODE_FIELDS[e][n];let c;u-1}},function(e,t,n){var r=n(27);e.exports=function(e,t){var n=this.__data__,i=r(n,e);return i<0?(++this.size,n.push([e,t])):n[i][1]=t,this}},function(e,t,n){var r=n(26);e.exports=function(){this.__data__=new r,this.size=0}},function(e,t){e.exports=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}},function(e,t){e.exports=function(e){return this.__data__.get(e)}},function(e,t){e.exports=function(e){return this.__data__.has(e)}},function(e,t,n){var r=n(26),i=n(47),o=n(49);e.exports=function(e,t){var n=this.__data__;if(n instanceof r){var a=n.__data__;if(!i||a.length<199)return a.push([e,t]),this.size=++n.size,this;n=this.__data__=new o(a)}return n.set(e,t),this.size=n.size,this}},function(e,t,n){var r=n(85),i=n(179),o=n(12),a=n(87),s=/^\[object .+?Constructor\]$/,u=Function.prototype,c=Object.prototype,l=u.toString,f=c.hasOwnProperty,p=RegExp("^"+l.call(f).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!o(e)||i(e))&&(r(e)?p:s).test(a(e))}},function(e,t,n){var r=n(16),i=Object.prototype,o=i.hasOwnProperty,a=i.toString,s=r?r.toStringTag:void 0;e.exports=function(e){var t=o.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var i=a.call(e);return r&&(t?e[s]=n:delete e[s]),i}},function(e,t){var n=Object.prototype.toString;e.exports=function(e){return n.call(e)}},function(e,t,n){var r,i=n(180),o=(r=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";e.exports=function(e){return!!o&&o in e}},function(e,t,n){var r=n(5)["__core-js_shared__"];e.exports=r},function(e,t){e.exports=function(e,t){return null==e?void 0:e[t]}},function(e,t,n){var r=n(183),i=n(26),o=n(47);e.exports=function(){this.size=0,this.__data__={hash:new r,map:new(o||i),string:new r}}},function(e,t,n){var r=n(184),i=n(185),o=n(186),a=n(187),s=n(188);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t=r)return!1;if(!(56320<=(o=e.charCodeAt(n))&&o<=57343))return!1;i=1024*(i-55296)+(o-56320)+65536}if(!a(i))return!1;a=t.isIdentifierPartES6}return!0}e.exports={isKeywordES5:r,isKeywordES6:i,isReservedWordES5:o,isReservedWordES6:a,isRestrictedWord:function(e){return"eval"===e||"arguments"===e},isIdentifierNameES5:s,isIdentifierNameES6:u,isIdentifierES5:function(e,t){return s(e)&&!o(e,t)},isIdentifierES6:function(e,t){return u(e)&&!a(e,t)}}}()},function(e,t,n){"use strict";var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=r?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(8));function i(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}const o=(e,t="TypeParameterDeclaration")=>{(0,r.default)(e,{builder:["id","typeParameters","extends","body"],visitor:["id","typeParameters","extends","mixins","implements","body"],aliases:["Flow","FlowDeclaration","Statement","Declaration"],fields:{id:(0,r.validateType)("Identifier"),typeParameters:(0,r.validateOptionalType)(t),extends:(0,r.validateOptional)((0,r.arrayOfType)("InterfaceExtends")),mixins:(0,r.validateOptional)((0,r.arrayOfType)("InterfaceExtends")),implements:(0,r.validateOptional)((0,r.arrayOfType)("ClassImplements")),body:(0,r.validateType)("ObjectTypeAnnotation")}})};(0,r.default)("AnyTypeAnnotation",{aliases:["Flow","FlowType","FlowBaseAnnotation"]}),(0,r.default)("ArrayTypeAnnotation",{visitor:["elementType"],aliases:["Flow","FlowType"],fields:{elementType:(0,r.validateType)("FlowType")}}),(0,r.default)("BooleanTypeAnnotation",{aliases:["Flow","FlowType","FlowBaseAnnotation"]}),(0,r.default)("BooleanLiteralTypeAnnotation",{builder:["value"],aliases:["Flow","FlowType"],fields:{value:(0,r.validate)((0,r.assertValueType)("boolean"))}}),(0,r.default)("NullLiteralTypeAnnotation",{aliases:["Flow","FlowType","FlowBaseAnnotation"]}),(0,r.default)("ClassImplements",{visitor:["id","typeParameters"],aliases:["Flow"],fields:{id:(0,r.validateType)("Identifier"),typeParameters:(0,r.validateOptionalType)("TypeParameterInstantiation")}}),o("DeclareClass"),(0,r.default)("DeclareFunction",{visitor:["id"],aliases:["Flow","FlowDeclaration","Statement","Declaration"],fields:{id:(0,r.validateType)("Identifier"),predicate:(0,r.validateOptionalType)("DeclaredPredicate")}}),o("DeclareInterface"),(0,r.default)("DeclareModule",{builder:["id","body","kind"],visitor:["id","body"],aliases:["Flow","FlowDeclaration","Statement","Declaration"],fields:{id:(0,r.validateType)(["Identifier","StringLiteral"]),body:(0,r.validateType)("BlockStatement"),kind:(0,r.validateOptional)((0,r.assertOneOf)("CommonJS","ES"))}}),(0,r.default)("DeclareModuleExports",{visitor:["typeAnnotation"],aliases:["Flow","FlowDeclaration","Statement","Declaration"],fields:{typeAnnotation:(0,r.validateType)("TypeAnnotation")}}),(0,r.default)("DeclareTypeAlias",{visitor:["id","typeParameters","right"],aliases:["Flow","FlowDeclaration","Statement","Declaration"],fields:{id:(0,r.validateType)("Identifier"),typeParameters:(0,r.validateOptionalType)("TypeParameterDeclaration"),right:(0,r.validateType)("FlowType")}}),(0,r.default)("DeclareOpaqueType",{visitor:["id","typeParameters","supertype"],aliases:["Flow","FlowDeclaration","Statement","Declaration"],fields:{id:(0,r.validateType)("Identifier"),typeParameters:(0,r.validateOptionalType)("TypeParameterDeclaration"),supertype:(0,r.validateOptionalType)("FlowType")}}),(0,r.default)("DeclareVariable",{visitor:["id"],aliases:["Flow","FlowDeclaration","Statement","Declaration"],fields:{id:(0,r.validateType)("Identifier")}}),(0,r.default)("DeclareExportDeclaration",{visitor:["declaration","specifiers","source"],aliases:["Flow","FlowDeclaration","Statement","Declaration"],fields:{declaration:(0,r.validateOptionalType)("Flow"),specifiers:(0,r.validateOptional)((0,r.arrayOfType)(["ExportSpecifier","ExportNamespaceSpecifier"])),source:(0,r.validateOptionalType)("StringLiteral"),default:(0,r.validateOptional)((0,r.assertValueType)("boolean"))}}),(0,r.default)("DeclareExportAllDeclaration",{visitor:["source"],aliases:["Flow","FlowDeclaration","Statement","Declaration"],fields:{source:(0,r.validateType)("StringLiteral"),exportKind:(0,r.validateOptional)((0,r.assertOneOf)("type","value"))}}),(0,r.default)("DeclaredPredicate",{visitor:["value"],aliases:["Flow","FlowPredicate"],fields:{value:(0,r.validateType)("Flow")}}),(0,r.default)("ExistsTypeAnnotation",{aliases:["Flow","FlowType"]}),(0,r.default)("FunctionTypeAnnotation",{visitor:["typeParameters","params","rest","returnType"],aliases:["Flow","FlowType"],fields:{typeParameters:(0,r.validateOptionalType)("TypeParameterDeclaration"),params:(0,r.validate)((0,r.arrayOfType)("FunctionTypeParam")),rest:(0,r.validateOptionalType)("FunctionTypeParam"),returnType:(0,r.validateType)("FlowType")}}),(0,r.default)("FunctionTypeParam",{visitor:["name","typeAnnotation"],aliases:["Flow"],fields:{name:(0,r.validateOptionalType)("Identifier"),typeAnnotation:(0,r.validateType)("FlowType"),optional:(0,r.validateOptional)((0,r.assertValueType)("boolean"))}}),(0,r.default)("GenericTypeAnnotation",{visitor:["id","typeParameters"],aliases:["Flow","FlowType"],fields:{id:(0,r.validateType)(["Identifier","QualifiedTypeIdentifier"]),typeParameters:(0,r.validateOptionalType)("TypeParameterInstantiation")}}),(0,r.default)("InferredPredicate",{aliases:["Flow","FlowPredicate"]}),(0,r.default)("InterfaceExtends",{visitor:["id","typeParameters"],aliases:["Flow"],fields:{id:(0,r.validateType)(["Identifier","QualifiedTypeIdentifier"]),typeParameters:(0,r.validateOptionalType)("TypeParameterInstantiation")}}),o("InterfaceDeclaration"),(0,r.default)("InterfaceTypeAnnotation",{visitor:["extends","body"],aliases:["Flow","FlowType"],fields:{extends:(0,r.validateOptional)((0,r.arrayOfType)("InterfaceExtends")),body:(0,r.validateType)("ObjectTypeAnnotation")}}),(0,r.default)("IntersectionTypeAnnotation",{visitor:["types"],aliases:["Flow","FlowType"],fields:{types:(0,r.validate)((0,r.arrayOfType)("FlowType"))}}),(0,r.default)("MixedTypeAnnotation",{aliases:["Flow","FlowType","FlowBaseAnnotation"]}),(0,r.default)("EmptyTypeAnnotation",{aliases:["Flow","FlowType","FlowBaseAnnotation"]}),(0,r.default)("NullableTypeAnnotation",{visitor:["typeAnnotation"],aliases:["Flow","FlowType"],fields:{typeAnnotation:(0,r.validateType)("FlowType")}}),(0,r.default)("NumberLiteralTypeAnnotation",{builder:["value"],aliases:["Flow","FlowType"],fields:{value:(0,r.validate)((0,r.assertValueType)("number"))}}),(0,r.default)("NumberTypeAnnotation",{aliases:["Flow","FlowType","FlowBaseAnnotation"]}),(0,r.default)("ObjectTypeAnnotation",{visitor:["properties","indexers","callProperties","internalSlots"],aliases:["Flow","FlowType"],builder:["properties","indexers","callProperties","internalSlots","exact"],fields:{properties:(0,r.validate)((0,r.arrayOfType)(["ObjectTypeProperty","ObjectTypeSpreadProperty"])),indexers:(0,r.validateOptional)((0,r.arrayOfType)("ObjectTypeIndexer")),callProperties:(0,r.validateOptional)((0,r.arrayOfType)("ObjectTypeCallProperty")),internalSlots:(0,r.validateOptional)((0,r.arrayOfType)("ObjectTypeInternalSlot")),exact:{validate:(0,r.assertValueType)("boolean"),default:!1},inexact:(0,r.validateOptional)((0,r.assertValueType)("boolean"))}}),(0,r.default)("ObjectTypeInternalSlot",{visitor:["id","value","optional","static","method"],aliases:["Flow","UserWhitespacable"],fields:{id:(0,r.validateType)("Identifier"),value:(0,r.validateType)("FlowType"),optional:(0,r.validate)((0,r.assertValueType)("boolean")),static:(0,r.validate)((0,r.assertValueType)("boolean")),method:(0,r.validate)((0,r.assertValueType)("boolean"))}}),(0,r.default)("ObjectTypeCallProperty",{visitor:["value"],aliases:["Flow","UserWhitespacable"],fields:{value:(0,r.validateType)("FlowType"),static:(0,r.validate)((0,r.assertValueType)("boolean"))}}),(0,r.default)("ObjectTypeIndexer",{visitor:["id","key","value","variance"],aliases:["Flow","UserWhitespacable"],fields:{id:(0,r.validateOptionalType)("Identifier"),key:(0,r.validateType)("FlowType"),value:(0,r.validateType)("FlowType"),static:(0,r.validate)((0,r.assertValueType)("boolean")),variance:(0,r.validateOptionalType)("Variance")}}),(0,r.default)("ObjectTypeProperty",{visitor:["key","value","variance"],aliases:["Flow","UserWhitespacable"],fields:{key:(0,r.validateType)(["Identifier","StringLiteral"]),value:(0,r.validateType)("FlowType"),kind:(0,r.validate)((0,r.assertOneOf)("init","get","set")),static:(0,r.validate)((0,r.assertValueType)("boolean")),proto:(0,r.validate)((0,r.assertValueType)("boolean")),optional:(0,r.validate)((0,r.assertValueType)("boolean")),variance:(0,r.validateOptionalType)("Variance")}}),(0,r.default)("ObjectTypeSpreadProperty",{visitor:["argument"],aliases:["Flow","UserWhitespacable"],fields:{argument:(0,r.validateType)("FlowType")}}),(0,r.default)("OpaqueType",{visitor:["id","typeParameters","supertype","impltype"],aliases:["Flow","FlowDeclaration","Statement","Declaration"],fields:{id:(0,r.validateType)("Identifier"),typeParameters:(0,r.validateOptionalType)("TypeParameterDeclaration"),supertype:(0,r.validateOptionalType)("FlowType"),impltype:(0,r.validateType)("FlowType")}}),(0,r.default)("QualifiedTypeIdentifier",{visitor:["id","qualification"],aliases:["Flow"],fields:{id:(0,r.validateType)("Identifier"),qualification:(0,r.validateType)(["Identifier","QualifiedTypeIdentifier"])}}),(0,r.default)("StringLiteralTypeAnnotation",{builder:["value"],aliases:["Flow","FlowType"],fields:{value:(0,r.validate)((0,r.assertValueType)("string"))}}),(0,r.default)("StringTypeAnnotation",{aliases:["Flow","FlowType","FlowBaseAnnotation"]}),(0,r.default)("ThisTypeAnnotation",{aliases:["Flow","FlowType","FlowBaseAnnotation"]}),(0,r.default)("TupleTypeAnnotation",{visitor:["types"],aliases:["Flow","FlowType"],fields:{types:(0,r.validate)((0,r.arrayOfType)("FlowType"))}}),(0,r.default)("TypeofTypeAnnotation",{visitor:["argument"],aliases:["Flow","FlowType"],fields:{argument:(0,r.validateType)("FlowType")}}),(0,r.default)("TypeAlias",{visitor:["id","typeParameters","right"],aliases:["Flow","FlowDeclaration","Statement","Declaration"],fields:{id:(0,r.validateType)("Identifier"),typeParameters:(0,r.validateOptionalType)("TypeParameterDeclaration"),right:(0,r.validateType)("FlowType")}}),(0,r.default)("TypeAnnotation",{aliases:["Flow"],visitor:["typeAnnotation"],fields:{typeAnnotation:(0,r.validateType)("FlowType")}}),(0,r.default)("TypeCastExpression",{visitor:["expression","typeAnnotation"],aliases:["Flow","ExpressionWrapper","Expression"],fields:{expression:(0,r.validateType)("Expression"),typeAnnotation:(0,r.validateType)("TypeAnnotation")}}),(0,r.default)("TypeParameter",{aliases:["Flow"],visitor:["bound","default","variance"],fields:{name:(0,r.validate)((0,r.assertValueType)("string")),bound:(0,r.validateOptionalType)("TypeAnnotation"),default:(0,r.validateOptionalType)("FlowType"),variance:(0,r.validateOptionalType)("Variance")}}),(0,r.default)("TypeParameterDeclaration",{aliases:["Flow"],visitor:["params"],fields:{params:(0,r.validate)((0,r.arrayOfType)("TypeParameter"))}}),(0,r.default)("TypeParameterInstantiation",{aliases:["Flow"],visitor:["params"],fields:{params:(0,r.validate)((0,r.arrayOfType)("FlowType"))}}),(0,r.default)("UnionTypeAnnotation",{visitor:["types"],aliases:["Flow","FlowType"],fields:{types:(0,r.validate)((0,r.arrayOfType)("FlowType"))}}),(0,r.default)("Variance",{aliases:["Flow"],builder:["kind"],fields:{kind:(0,r.validate)((0,r.assertOneOf)("minus","plus"))}}),(0,r.default)("VoidTypeAnnotation",{aliases:["Flow","FlowType","FlowBaseAnnotation"]}),(0,r.default)("EnumDeclaration",{alises:["Declaration"],visitor:["id","body"],fields:{id:(0,r.validateType)("Identifier"),body:(0,r.validateType)(["EnumBooleanBody","EnumNumberBody","EnumStringBody","EnumSymbolBody"])}}),(0,r.default)("EnumBooleanBody",{aliases:["EnumBody"],visitor:["members"],fields:{explicit:(0,r.validate)((0,r.assertValueType)("boolean")),members:(0,r.validateArrayOfType)("EnumBooleanMember")}}),(0,r.default)("EnumNumberBody",{aliases:["EnumBody"],visitor:["members"],fields:{explicit:(0,r.validate)((0,r.assertValueType)("boolean")),members:(0,r.validateArrayOfType)("EnumNumberMember")}}),(0,r.default)("EnumStringBody",{aliases:["EnumBody"],visitor:["members"],fields:{explicit:(0,r.validate)((0,r.assertValueType)("boolean")),members:(0,r.validateArrayOfType)(["EnumStringMember","EnumDefaultedMember"])}}),(0,r.default)("EnumSymbolBody",{aliases:["EnumBody"],visitor:["members"],fields:{members:(0,r.validateArrayOfType)("EnumDefaultedMember")}}),(0,r.default)("EnumBooleanMember",{aliases:["EnumMember"],visitor:["id"],fields:{id:(0,r.validateType)("Identifier"),init:(0,r.validateType)("BooleanLiteral")}}),(0,r.default)("EnumNumberMember",{aliases:["EnumMember"],visitor:["id","init"],fields:{id:(0,r.validateType)("Identifier"),init:(0,r.validateType)("NumericLiteral")}}),(0,r.default)("EnumStringMember",{aliases:["EnumMember"],visitor:["id","init"],fields:{id:(0,r.validateType)("Identifier"),init:(0,r.validateType)("StringLiteral")}}),(0,r.default)("EnumDefaultedMember",{aliases:["EnumMember"],visitor:["id"],fields:{id:(0,r.validateType)("Identifier")}})},function(e,t,n){"use strict";var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=r?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(8));function i(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}(0,r.default)("JSXAttribute",{visitor:["name","value"],aliases:["JSX","Immutable"],fields:{name:{validate:(0,r.assertNodeType)("JSXIdentifier","JSXNamespacedName")},value:{optional:!0,validate:(0,r.assertNodeType)("JSXElement","JSXFragment","StringLiteral","JSXExpressionContainer")}}}),(0,r.default)("JSXClosingElement",{visitor:["name"],aliases:["JSX","Immutable"],fields:{name:{validate:(0,r.assertNodeType)("JSXIdentifier","JSXMemberExpression","JSXNamespacedName")}}}),(0,r.default)("JSXElement",{builder:["openingElement","closingElement","children","selfClosing"],visitor:["openingElement","children","closingElement"],aliases:["JSX","Immutable","Expression"],fields:{openingElement:{validate:(0,r.assertNodeType)("JSXOpeningElement")},closingElement:{optional:!0,validate:(0,r.assertNodeType)("JSXClosingElement")},children:{validate:(0,r.chain)((0,r.assertValueType)("array"),(0,r.assertEach)((0,r.assertNodeType)("JSXText","JSXExpressionContainer","JSXSpreadChild","JSXElement","JSXFragment")))}}}),(0,r.default)("JSXEmptyExpression",{aliases:["JSX"]}),(0,r.default)("JSXExpressionContainer",{visitor:["expression"],aliases:["JSX","Immutable"],fields:{expression:{validate:(0,r.assertNodeType)("Expression","JSXEmptyExpression")}}}),(0,r.default)("JSXSpreadChild",{visitor:["expression"],aliases:["JSX","Immutable"],fields:{expression:{validate:(0,r.assertNodeType)("Expression")}}}),(0,r.default)("JSXIdentifier",{builder:["name"],aliases:["JSX"],fields:{name:{validate:(0,r.assertValueType)("string")}}}),(0,r.default)("JSXMemberExpression",{visitor:["object","property"],aliases:["JSX"],fields:{object:{validate:(0,r.assertNodeType)("JSXMemberExpression","JSXIdentifier")},property:{validate:(0,r.assertNodeType)("JSXIdentifier")}}}),(0,r.default)("JSXNamespacedName",{visitor:["namespace","name"],aliases:["JSX"],fields:{namespace:{validate:(0,r.assertNodeType)("JSXIdentifier")},name:{validate:(0,r.assertNodeType)("JSXIdentifier")}}}),(0,r.default)("JSXOpeningElement",{builder:["name","attributes","selfClosing"],visitor:["name","attributes"],aliases:["JSX","Immutable"],fields:{name:{validate:(0,r.assertNodeType)("JSXIdentifier","JSXMemberExpression","JSXNamespacedName")},selfClosing:{default:!1,validate:(0,r.assertValueType)("boolean")},attributes:{validate:(0,r.chain)((0,r.assertValueType)("array"),(0,r.assertEach)((0,r.assertNodeType)("JSXAttribute","JSXSpreadAttribute")))},typeParameters:{validate:(0,r.assertNodeType)("TypeParameterInstantiation","TSTypeParameterInstantiation"),optional:!0}}}),(0,r.default)("JSXSpreadAttribute",{visitor:["argument"],aliases:["JSX"],fields:{argument:{validate:(0,r.assertNodeType)("Expression")}}}),(0,r.default)("JSXText",{aliases:["JSX","Immutable"],builder:["value"],fields:{value:{validate:(0,r.assertValueType)("string")}}}),(0,r.default)("JSXFragment",{builder:["openingFragment","closingFragment","children"],visitor:["openingFragment","children","closingFragment"],aliases:["JSX","Immutable","Expression"],fields:{openingFragment:{validate:(0,r.assertNodeType)("JSXOpeningFragment")},closingFragment:{validate:(0,r.assertNodeType)("JSXClosingFragment")},children:{validate:(0,r.chain)((0,r.assertValueType)("array"),(0,r.assertEach)((0,r.assertNodeType)("JSXText","JSXExpressionContainer","JSXSpreadChild","JSXElement","JSXFragment")))}}}),(0,r.default)("JSXOpeningFragment",{aliases:["JSX","Immutable"]}),(0,r.default)("JSXClosingFragment",{aliases:["JSX","Immutable"]})},function(e,t,n){"use strict";var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=o();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var a=r?Object.getOwnPropertyDescriptor(e,i):null;a&&(a.get||a.set)?Object.defineProperty(n,i,a):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(n(8)),i=n(103);function o(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}(0,r.default)("Noop",{visitor:[]}),(0,r.default)("Placeholder",{visitor:[],builder:["expectedNode","name"],fields:{name:{validate:(0,r.assertNodeType)("Identifier")},expectedNode:{validate:(0,r.assertOneOf)(...i.PLACEHOLDERS)}}}),(0,r.default)("V8IntrinsicIdentifier",{builder:["name"],fields:{name:{validate:(0,r.assertValueType)("string")}}})},function(e,t,n){"use strict";var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=o();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var a=r?Object.getOwnPropertyDescriptor(e,i):null;a&&(a.get||a.set)?Object.defineProperty(n,i,a):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(n(8)),i=n(64);function o(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}(0,r.default)("ArgumentPlaceholder",{}),(0,r.default)("AwaitExpression",{builder:["argument"],visitor:["argument"],aliases:["Expression","Terminatorless"],fields:{argument:{validate:(0,r.assertNodeType)("Expression")}}}),(0,r.default)("BindExpression",{visitor:["object","callee"],aliases:["Expression"],fields:{}}),(0,r.default)("ClassProperty",{visitor:["key","value","typeAnnotation","decorators"],builder:["key","value","typeAnnotation","decorators","computed","static"],aliases:["Property"],fields:Object.assign({},i.classMethodOrPropertyCommon,{value:{validate:(0,r.assertNodeType)("Expression"),optional:!0},definite:{validate:(0,r.assertValueType)("boolean"),optional:!0},typeAnnotation:{validate:(0,r.assertNodeType)("TypeAnnotation","TSTypeAnnotation","Noop"),optional:!0},decorators:{validate:(0,r.chain)((0,r.assertValueType)("array"),(0,r.assertEach)((0,r.assertNodeType)("Decorator"))),optional:!0},readonly:{validate:(0,r.assertValueType)("boolean"),optional:!0},declare:{validate:(0,r.assertValueType)("boolean"),optional:!0}})}),(0,r.default)("OptionalMemberExpression",{builder:["object","property","computed","optional"],visitor:["object","property"],aliases:["Expression"],fields:{object:{validate:(0,r.assertNodeType)("Expression")},property:{validate:function(){const e=(0,r.assertNodeType)("Identifier"),t=(0,r.assertNodeType)("Expression");return function(n,r,i){(n.computed?t:e)(n,r,i)}}()},computed:{default:!1},optional:{validate:(0,r.assertValueType)("boolean")}}}),(0,r.default)("PipelineTopicExpression",{builder:["expression"],visitor:["expression"],fields:{expression:{validate:(0,r.assertNodeType)("Expression")}}}),(0,r.default)("PipelineBareFunction",{builder:["callee"],visitor:["callee"],fields:{callee:{validate:(0,r.assertNodeType)("Expression")}}}),(0,r.default)("PipelinePrimaryTopicReference",{aliases:["Expression"]}),(0,r.default)("OptionalCallExpression",{visitor:["callee","arguments","typeParameters","typeArguments"],builder:["callee","arguments","optional"],aliases:["Expression"],fields:{callee:{validate:(0,r.assertNodeType)("Expression")},arguments:{validate:(0,r.chain)((0,r.assertValueType)("array"),(0,r.assertEach)((0,r.assertNodeType)("Expression","SpreadElement","JSXNamespacedName")))},optional:{validate:(0,r.assertValueType)("boolean")},typeArguments:{validate:(0,r.assertNodeType)("TypeParameterInstantiation"),optional:!0},typeParameters:{validate:(0,r.assertNodeType)("TSTypeParameterInstantiation"),optional:!0}}}),(0,r.default)("ClassPrivateProperty",{visitor:["key","value","decorators"],builder:["key","value","decorators"],aliases:["Property","Private"],fields:{key:{validate:(0,r.assertNodeType)("PrivateName")},value:{validate:(0,r.assertNodeType)("Expression"),optional:!0},decorators:{validate:(0,r.chain)((0,r.assertValueType)("array"),(0,r.assertEach)((0,r.assertNodeType)("Decorator"))),optional:!0}}}),(0,r.default)("ClassPrivateMethod",{builder:["kind","key","params","body","static"],visitor:["key","params","body","decorators","returnType","typeParameters"],aliases:["Function","Scopable","BlockParent","FunctionParent","Method","Private"],fields:Object.assign({},i.classMethodOrDeclareMethodCommon,{key:{validate:(0,r.assertNodeType)("PrivateName")},body:{validate:(0,r.assertNodeType)("BlockStatement")}})}),(0,r.default)("Import",{aliases:["Expression"]}),(0,r.default)("Decorator",{visitor:["expression"],fields:{expression:{validate:(0,r.assertNodeType)("Expression")}}}),(0,r.default)("DoExpression",{visitor:["body"],aliases:["Expression"],fields:{body:{validate:(0,r.assertNodeType)("BlockStatement")}}}),(0,r.default)("ExportDefaultSpecifier",{visitor:["exported"],aliases:["ModuleSpecifier"],fields:{exported:{validate:(0,r.assertNodeType)("Identifier")}}}),(0,r.default)("ExportNamespaceSpecifier",{visitor:["exported"],aliases:["ModuleSpecifier"],fields:{exported:{validate:(0,r.assertNodeType)("Identifier")}}}),(0,r.default)("PrivateName",{visitor:["id"],aliases:["Private"],fields:{id:{validate:(0,r.assertNodeType)("Identifier")}}}),(0,r.default)("BigIntLiteral",{builder:["value"],fields:{value:{validate:(0,r.assertValueType)("string")}},aliases:["Expression","Pureish","Literal","Immutable"]})},function(e,t,n){"use strict";var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=a();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(n(8)),i=n(60),o=n(64);function a(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return a=function(){return e},e}const s=(0,r.assertValueType)("boolean"),u={returnType:{validate:(0,r.assertNodeType)("TSTypeAnnotation","Noop"),optional:!0},typeParameters:{validate:(0,r.assertNodeType)("TSTypeParameterDeclaration","Noop"),optional:!0}};(0,r.default)("TSParameterProperty",{aliases:["LVal"],visitor:["parameter"],fields:{accessibility:{validate:(0,r.assertOneOf)("public","private","protected"),optional:!0},readonly:{validate:(0,r.assertValueType)("boolean"),optional:!0},parameter:{validate:(0,r.assertNodeType)("Identifier","AssignmentPattern")}}}),(0,r.default)("TSDeclareFunction",{aliases:["Statement","Declaration"],visitor:["id","typeParameters","params","returnType"],fields:Object.assign({},i.functionDeclarationCommon,{},u)}),(0,r.default)("TSDeclareMethod",{visitor:["decorators","key","typeParameters","params","returnType"],fields:Object.assign({},o.classMethodOrDeclareMethodCommon,{},u)}),(0,r.default)("TSQualifiedName",{aliases:["TSEntityName"],visitor:["left","right"],fields:{left:(0,r.validateType)("TSEntityName"),right:(0,r.validateType)("Identifier")}});const c={typeParameters:(0,r.validateOptionalType)("TSTypeParameterDeclaration"),parameters:(0,r.validateArrayOfType)(["Identifier","RestElement"]),typeAnnotation:(0,r.validateOptionalType)("TSTypeAnnotation")},l={aliases:["TSTypeElement"],visitor:["typeParameters","parameters","typeAnnotation"],fields:c};(0,r.default)("TSCallSignatureDeclaration",l),(0,r.default)("TSConstructSignatureDeclaration",l);const f={key:(0,r.validateType)("Expression"),computed:(0,r.validate)(s),optional:(0,r.validateOptional)(s)};(0,r.default)("TSPropertySignature",{aliases:["TSTypeElement"],visitor:["key","typeAnnotation","initializer"],fields:Object.assign({},f,{readonly:(0,r.validateOptional)(s),typeAnnotation:(0,r.validateOptionalType)("TSTypeAnnotation"),initializer:(0,r.validateOptionalType)("Expression")})}),(0,r.default)("TSMethodSignature",{aliases:["TSTypeElement"],visitor:["key","typeParameters","parameters","typeAnnotation"],fields:Object.assign({},c,{},f)}),(0,r.default)("TSIndexSignature",{aliases:["TSTypeElement"],visitor:["parameters","typeAnnotation"],fields:{readonly:(0,r.validateOptional)(s),parameters:(0,r.validateArrayOfType)("Identifier"),typeAnnotation:(0,r.validateOptionalType)("TSTypeAnnotation")}});const p=["TSAnyKeyword","TSBooleanKeyword","TSBigIntKeyword","TSNeverKeyword","TSNullKeyword","TSNumberKeyword","TSObjectKeyword","TSStringKeyword","TSSymbolKeyword","TSUndefinedKeyword","TSUnknownKeyword","TSVoidKeyword"];for(const e of p)(0,r.default)(e,{aliases:["TSType"],visitor:[],fields:{}});(0,r.default)("TSThisType",{aliases:["TSType"],visitor:[],fields:{}});const h={aliases:["TSType"],visitor:["typeParameters","parameters","typeAnnotation"],fields:c};(0,r.default)("TSFunctionType",h),(0,r.default)("TSConstructorType",h),(0,r.default)("TSTypeReference",{aliases:["TSType"],visitor:["typeName","typeParameters"],fields:{typeName:(0,r.validateType)("TSEntityName"),typeParameters:(0,r.validateOptionalType)("TSTypeParameterInstantiation")}}),(0,r.default)("TSTypePredicate",{aliases:["TSType"],visitor:["parameterName","typeAnnotation"],builder:["parameterName","typeAnnotation","asserts"],fields:{parameterName:(0,r.validateType)(["Identifier","TSThisType"]),typeAnnotation:(0,r.validateOptionalType)("TSTypeAnnotation"),asserts:(0,r.validateOptional)(s)}}),(0,r.default)("TSTypeQuery",{aliases:["TSType"],visitor:["exprName"],fields:{exprName:(0,r.validateType)(["TSEntityName","TSImportType"])}}),(0,r.default)("TSTypeLiteral",{aliases:["TSType"],visitor:["members"],fields:{members:(0,r.validateArrayOfType)("TSTypeElement")}}),(0,r.default)("TSArrayType",{aliases:["TSType"],visitor:["elementType"],fields:{elementType:(0,r.validateType)("TSType")}}),(0,r.default)("TSTupleType",{aliases:["TSType"],visitor:["elementTypes"],fields:{elementTypes:(0,r.validateArrayOfType)("TSType")}}),(0,r.default)("TSOptionalType",{aliases:["TSType"],visitor:["typeAnnotation"],fields:{typeAnnotation:(0,r.validateType)("TSType")}}),(0,r.default)("TSRestType",{aliases:["TSType"],visitor:["typeAnnotation"],fields:{typeAnnotation:(0,r.validateType)("TSType")}});const d={aliases:["TSType"],visitor:["types"],fields:{types:(0,r.validateArrayOfType)("TSType")}};(0,r.default)("TSUnionType",d),(0,r.default)("TSIntersectionType",d),(0,r.default)("TSConditionalType",{aliases:["TSType"],visitor:["checkType","extendsType","trueType","falseType"],fields:{checkType:(0,r.validateType)("TSType"),extendsType:(0,r.validateType)("TSType"),trueType:(0,r.validateType)("TSType"),falseType:(0,r.validateType)("TSType")}}),(0,r.default)("TSInferType",{aliases:["TSType"],visitor:["typeParameter"],fields:{typeParameter:(0,r.validateType)("TSTypeParameter")}}),(0,r.default)("TSParenthesizedType",{aliases:["TSType"],visitor:["typeAnnotation"],fields:{typeAnnotation:(0,r.validateType)("TSType")}}),(0,r.default)("TSTypeOperator",{aliases:["TSType"],visitor:["typeAnnotation"],fields:{operator:(0,r.validate)((0,r.assertValueType)("string")),typeAnnotation:(0,r.validateType)("TSType")}}),(0,r.default)("TSIndexedAccessType",{aliases:["TSType"],visitor:["objectType","indexType"],fields:{objectType:(0,r.validateType)("TSType"),indexType:(0,r.validateType)("TSType")}}),(0,r.default)("TSMappedType",{aliases:["TSType"],visitor:["typeParameter","typeAnnotation"],fields:{readonly:(0,r.validateOptional)(s),typeParameter:(0,r.validateType)("TSTypeParameter"),optional:(0,r.validateOptional)(s),typeAnnotation:(0,r.validateOptionalType)("TSType")}}),(0,r.default)("TSLiteralType",{aliases:["TSType"],visitor:["literal"],fields:{literal:(0,r.validateType)(["NumericLiteral","StringLiteral","BooleanLiteral"])}}),(0,r.default)("TSExpressionWithTypeArguments",{aliases:["TSType"],visitor:["expression","typeParameters"],fields:{expression:(0,r.validateType)("TSEntityName"),typeParameters:(0,r.validateOptionalType)("TSTypeParameterInstantiation")}}),(0,r.default)("TSInterfaceDeclaration",{aliases:["Statement","Declaration"],visitor:["id","typeParameters","extends","body"],fields:{declare:(0,r.validateOptional)(s),id:(0,r.validateType)("Identifier"),typeParameters:(0,r.validateOptionalType)("TSTypeParameterDeclaration"),extends:(0,r.validateOptional)((0,r.arrayOfType)("TSExpressionWithTypeArguments")),body:(0,r.validateType)("TSInterfaceBody")}}),(0,r.default)("TSInterfaceBody",{visitor:["body"],fields:{body:(0,r.validateArrayOfType)("TSTypeElement")}}),(0,r.default)("TSTypeAliasDeclaration",{aliases:["Statement","Declaration"],visitor:["id","typeParameters","typeAnnotation"],fields:{declare:(0,r.validateOptional)(s),id:(0,r.validateType)("Identifier"),typeParameters:(0,r.validateOptionalType)("TSTypeParameterDeclaration"),typeAnnotation:(0,r.validateType)("TSType")}}),(0,r.default)("TSAsExpression",{aliases:["Expression"],visitor:["expression","typeAnnotation"],fields:{expression:(0,r.validateType)("Expression"),typeAnnotation:(0,r.validateType)("TSType")}}),(0,r.default)("TSTypeAssertion",{aliases:["Expression"],visitor:["typeAnnotation","expression"],fields:{typeAnnotation:(0,r.validateType)("TSType"),expression:(0,r.validateType)("Expression")}}),(0,r.default)("TSEnumDeclaration",{aliases:["Statement","Declaration"],visitor:["id","members"],fields:{declare:(0,r.validateOptional)(s),const:(0,r.validateOptional)(s),id:(0,r.validateType)("Identifier"),members:(0,r.validateArrayOfType)("TSEnumMember"),initializer:(0,r.validateOptionalType)("Expression")}}),(0,r.default)("TSEnumMember",{visitor:["id","initializer"],fields:{id:(0,r.validateType)(["Identifier","StringLiteral"]),initializer:(0,r.validateOptionalType)("Expression")}}),(0,r.default)("TSModuleDeclaration",{aliases:["Statement","Declaration"],visitor:["id","body"],fields:{declare:(0,r.validateOptional)(s),global:(0,r.validateOptional)(s),id:(0,r.validateType)(["Identifier","StringLiteral"]),body:(0,r.validateType)(["TSModuleBlock","TSModuleDeclaration"])}}),(0,r.default)("TSModuleBlock",{aliases:["Scopable","Block","BlockParent"],visitor:["body"],fields:{body:(0,r.validateArrayOfType)("Statement")}}),(0,r.default)("TSImportType",{aliases:["TSType"],visitor:["argument","qualifier","typeParameters"],fields:{argument:(0,r.validateType)("StringLiteral"),qualifier:(0,r.validateOptionalType)("TSEntityName"),typeParameters:(0,r.validateOptionalType)("TSTypeParameterInstantiation")}}),(0,r.default)("TSImportEqualsDeclaration",{aliases:["Statement"],visitor:["id","moduleReference"],fields:{isExport:(0,r.validate)(s),id:(0,r.validateType)("Identifier"),moduleReference:(0,r.validateType)(["TSEntityName","TSExternalModuleReference"])}}),(0,r.default)("TSExternalModuleReference",{visitor:["expression"],fields:{expression:(0,r.validateType)("StringLiteral")}}),(0,r.default)("TSNonNullExpression",{aliases:["Expression"],visitor:["expression"],fields:{expression:(0,r.validateType)("Expression")}}),(0,r.default)("TSExportAssignment",{aliases:["Statement"],visitor:["expression"],fields:{expression:(0,r.validateType)("Expression")}}),(0,r.default)("TSNamespaceExportDeclaration",{aliases:["Statement"],visitor:["id"],fields:{id:(0,r.validateType)("Identifier")}}),(0,r.default)("TSTypeAnnotation",{visitor:["typeAnnotation"],fields:{typeAnnotation:{validate:(0,r.assertNodeType)("TSType")}}}),(0,r.default)("TSTypeParameterInstantiation",{visitor:["params"],fields:{params:{validate:(0,r.chain)((0,r.assertValueType)("array"),(0,r.assertEach)((0,r.assertNodeType)("TSType")))}}}),(0,r.default)("TSTypeParameterDeclaration",{visitor:["params"],fields:{params:{validate:(0,r.chain)((0,r.assertValueType)("array"),(0,r.assertEach)((0,r.assertNodeType)("TSTypeParameter")))}}}),(0,r.default)("TSTypeParameter",{builder:["constraint","default","name"],visitor:["constraint","default"],fields:{name:{validate:(0,r.assertValueType)("string")},constraint:{validate:(0,r.assertNodeType)("TSType"),optional:!0},default:{validate:(0,r.assertNodeType)("TSType"),optional:!0}}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if(!(0,i.default)(e)){const t=e&&e.type||JSON.stringify(e);throw new TypeError(`Not a valid node of type "${t}"`)}};var r,i=(r=n(104))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.assertArrayExpression=function(e,t={}){o("ArrayExpression",e,t)},t.assertAssignmentExpression=function(e,t={}){o("AssignmentExpression",e,t)},t.assertBinaryExpression=function(e,t={}){o("BinaryExpression",e,t)},t.assertInterpreterDirective=function(e,t={}){o("InterpreterDirective",e,t)},t.assertDirective=function(e,t={}){o("Directive",e,t)},t.assertDirectiveLiteral=function(e,t={}){o("DirectiveLiteral",e,t)},t.assertBlockStatement=function(e,t={}){o("BlockStatement",e,t)},t.assertBreakStatement=function(e,t={}){o("BreakStatement",e,t)},t.assertCallExpression=function(e,t={}){o("CallExpression",e,t)},t.assertCatchClause=function(e,t={}){o("CatchClause",e,t)},t.assertConditionalExpression=function(e,t={}){o("ConditionalExpression",e,t)},t.assertContinueStatement=function(e,t={}){o("ContinueStatement",e,t)},t.assertDebuggerStatement=function(e,t={}){o("DebuggerStatement",e,t)},t.assertDoWhileStatement=function(e,t={}){o("DoWhileStatement",e,t)},t.assertEmptyStatement=function(e,t={}){o("EmptyStatement",e,t)},t.assertExpressionStatement=function(e,t={}){o("ExpressionStatement",e,t)},t.assertFile=function(e,t={}){o("File",e,t)},t.assertForInStatement=function(e,t={}){o("ForInStatement",e,t)},t.assertForStatement=function(e,t={}){o("ForStatement",e,t)},t.assertFunctionDeclaration=function(e,t={}){o("FunctionDeclaration",e,t)},t.assertFunctionExpression=function(e,t={}){o("FunctionExpression",e,t)},t.assertIdentifier=function(e,t={}){o("Identifier",e,t)},t.assertIfStatement=function(e,t={}){o("IfStatement",e,t)},t.assertLabeledStatement=function(e,t={}){o("LabeledStatement",e,t)},t.assertStringLiteral=function(e,t={}){o("StringLiteral",e,t)},t.assertNumericLiteral=function(e,t={}){o("NumericLiteral",e,t)},t.assertNullLiteral=function(e,t={}){o("NullLiteral",e,t)},t.assertBooleanLiteral=function(e,t={}){o("BooleanLiteral",e,t)},t.assertRegExpLiteral=function(e,t={}){o("RegExpLiteral",e,t)},t.assertLogicalExpression=function(e,t={}){o("LogicalExpression",e,t)},t.assertMemberExpression=function(e,t={}){o("MemberExpression",e,t)},t.assertNewExpression=function(e,t={}){o("NewExpression",e,t)},t.assertProgram=function(e,t={}){o("Program",e,t)},t.assertObjectExpression=function(e,t={}){o("ObjectExpression",e,t)},t.assertObjectMethod=function(e,t={}){o("ObjectMethod",e,t)},t.assertObjectProperty=function(e,t={}){o("ObjectProperty",e,t)},t.assertRestElement=function(e,t={}){o("RestElement",e,t)},t.assertReturnStatement=function(e,t={}){o("ReturnStatement",e,t)},t.assertSequenceExpression=function(e,t={}){o("SequenceExpression",e,t)},t.assertParenthesizedExpression=function(e,t={}){o("ParenthesizedExpression",e,t)},t.assertSwitchCase=function(e,t={}){o("SwitchCase",e,t)},t.assertSwitchStatement=function(e,t={}){o("SwitchStatement",e,t)},t.assertThisExpression=function(e,t={}){o("ThisExpression",e,t)},t.assertThrowStatement=function(e,t={}){o("ThrowStatement",e,t)},t.assertTryStatement=function(e,t={}){o("TryStatement",e,t)},t.assertUnaryExpression=function(e,t={}){o("UnaryExpression",e,t)},t.assertUpdateExpression=function(e,t={}){o("UpdateExpression",e,t)},t.assertVariableDeclaration=function(e,t={}){o("VariableDeclaration",e,t)},t.assertVariableDeclarator=function(e,t={}){o("VariableDeclarator",e,t)},t.assertWhileStatement=function(e,t={}){o("WhileStatement",e,t)},t.assertWithStatement=function(e,t={}){o("WithStatement",e,t)},t.assertAssignmentPattern=function(e,t={}){o("AssignmentPattern",e,t)},t.assertArrayPattern=function(e,t={}){o("ArrayPattern",e,t)},t.assertArrowFunctionExpression=function(e,t={}){o("ArrowFunctionExpression",e,t)},t.assertClassBody=function(e,t={}){o("ClassBody",e,t)},t.assertClassDeclaration=function(e,t={}){o("ClassDeclaration",e,t)},t.assertClassExpression=function(e,t={}){o("ClassExpression",e,t)},t.assertExportAllDeclaration=function(e,t={}){o("ExportAllDeclaration",e,t)},t.assertExportDefaultDeclaration=function(e,t={}){o("ExportDefaultDeclaration",e,t)},t.assertExportNamedDeclaration=function(e,t={}){o("ExportNamedDeclaration",e,t)},t.assertExportSpecifier=function(e,t={}){o("ExportSpecifier",e,t)},t.assertForOfStatement=function(e,t={}){o("ForOfStatement",e,t)},t.assertImportDeclaration=function(e,t={}){o("ImportDeclaration",e,t)},t.assertImportDefaultSpecifier=function(e,t={}){o("ImportDefaultSpecifier",e,t)},t.assertImportNamespaceSpecifier=function(e,t={}){o("ImportNamespaceSpecifier",e,t)},t.assertImportSpecifier=function(e,t={}){o("ImportSpecifier",e,t)},t.assertMetaProperty=function(e,t={}){o("MetaProperty",e,t)},t.assertClassMethod=function(e,t={}){o("ClassMethod",e,t)},t.assertObjectPattern=function(e,t={}){o("ObjectPattern",e,t)},t.assertSpreadElement=function(e,t={}){o("SpreadElement",e,t)},t.assertSuper=function(e,t={}){o("Super",e,t)},t.assertTaggedTemplateExpression=function(e,t={}){o("TaggedTemplateExpression",e,t)},t.assertTemplateElement=function(e,t={}){o("TemplateElement",e,t)},t.assertTemplateLiteral=function(e,t={}){o("TemplateLiteral",e,t)},t.assertYieldExpression=function(e,t={}){o("YieldExpression",e,t)},t.assertAnyTypeAnnotation=function(e,t={}){o("AnyTypeAnnotation",e,t)},t.assertArrayTypeAnnotation=function(e,t={}){o("ArrayTypeAnnotation",e,t)},t.assertBooleanTypeAnnotation=function(e,t={}){o("BooleanTypeAnnotation",e,t)},t.assertBooleanLiteralTypeAnnotation=function(e,t={}){o("BooleanLiteralTypeAnnotation",e,t)},t.assertNullLiteralTypeAnnotation=function(e,t={}){o("NullLiteralTypeAnnotation",e,t)},t.assertClassImplements=function(e,t={}){o("ClassImplements",e,t)},t.assertDeclareClass=function(e,t={}){o("DeclareClass",e,t)},t.assertDeclareFunction=function(e,t={}){o("DeclareFunction",e,t)},t.assertDeclareInterface=function(e,t={}){o("DeclareInterface",e,t)},t.assertDeclareModule=function(e,t={}){o("DeclareModule",e,t)},t.assertDeclareModuleExports=function(e,t={}){o("DeclareModuleExports",e,t)},t.assertDeclareTypeAlias=function(e,t={}){o("DeclareTypeAlias",e,t)},t.assertDeclareOpaqueType=function(e,t={}){o("DeclareOpaqueType",e,t)},t.assertDeclareVariable=function(e,t={}){o("DeclareVariable",e,t)},t.assertDeclareExportDeclaration=function(e,t={}){o("DeclareExportDeclaration",e,t)},t.assertDeclareExportAllDeclaration=function(e,t={}){o("DeclareExportAllDeclaration",e,t)},t.assertDeclaredPredicate=function(e,t={}){o("DeclaredPredicate",e,t)},t.assertExistsTypeAnnotation=function(e,t={}){o("ExistsTypeAnnotation",e,t)},t.assertFunctionTypeAnnotation=function(e,t={}){o("FunctionTypeAnnotation",e,t)},t.assertFunctionTypeParam=function(e,t={}){o("FunctionTypeParam",e,t)},t.assertGenericTypeAnnotation=function(e,t={}){o("GenericTypeAnnotation",e,t)},t.assertInferredPredicate=function(e,t={}){o("InferredPredicate",e,t)},t.assertInterfaceExtends=function(e,t={}){o("InterfaceExtends",e,t)},t.assertInterfaceDeclaration=function(e,t={}){o("InterfaceDeclaration",e,t)},t.assertInterfaceTypeAnnotation=function(e,t={}){o("InterfaceTypeAnnotation",e,t)},t.assertIntersectionTypeAnnotation=function(e,t={}){o("IntersectionTypeAnnotation",e,t)},t.assertMixedTypeAnnotation=function(e,t={}){o("MixedTypeAnnotation",e,t)},t.assertEmptyTypeAnnotation=function(e,t={}){o("EmptyTypeAnnotation",e,t)},t.assertNullableTypeAnnotation=function(e,t={}){o("NullableTypeAnnotation",e,t)},t.assertNumberLiteralTypeAnnotation=function(e,t={}){o("NumberLiteralTypeAnnotation",e,t)},t.assertNumberTypeAnnotation=function(e,t={}){o("NumberTypeAnnotation",e,t)},t.assertObjectTypeAnnotation=function(e,t={}){o("ObjectTypeAnnotation",e,t)},t.assertObjectTypeInternalSlot=function(e,t={}){o("ObjectTypeInternalSlot",e,t)},t.assertObjectTypeCallProperty=function(e,t={}){o("ObjectTypeCallProperty",e,t)},t.assertObjectTypeIndexer=function(e,t={}){o("ObjectTypeIndexer",e,t)},t.assertObjectTypeProperty=function(e,t={}){o("ObjectTypeProperty",e,t)},t.assertObjectTypeSpreadProperty=function(e,t={}){o("ObjectTypeSpreadProperty",e,t)},t.assertOpaqueType=function(e,t={}){o("OpaqueType",e,t)},t.assertQualifiedTypeIdentifier=function(e,t={}){o("QualifiedTypeIdentifier",e,t)},t.assertStringLiteralTypeAnnotation=function(e,t={}){o("StringLiteralTypeAnnotation",e,t)},t.assertStringTypeAnnotation=function(e,t={}){o("StringTypeAnnotation",e,t)},t.assertThisTypeAnnotation=function(e,t={}){o("ThisTypeAnnotation",e,t)},t.assertTupleTypeAnnotation=function(e,t={}){o("TupleTypeAnnotation",e,t)},t.assertTypeofTypeAnnotation=function(e,t={}){o("TypeofTypeAnnotation",e,t)},t.assertTypeAlias=function(e,t={}){o("TypeAlias",e,t)},t.assertTypeAnnotation=function(e,t={}){o("TypeAnnotation",e,t)},t.assertTypeCastExpression=function(e,t={}){o("TypeCastExpression",e,t)},t.assertTypeParameter=function(e,t={}){o("TypeParameter",e,t)},t.assertTypeParameterDeclaration=function(e,t={}){o("TypeParameterDeclaration",e,t)},t.assertTypeParameterInstantiation=function(e,t={}){o("TypeParameterInstantiation",e,t)},t.assertUnionTypeAnnotation=function(e,t={}){o("UnionTypeAnnotation",e,t)},t.assertVariance=function(e,t={}){o("Variance",e,t)},t.assertVoidTypeAnnotation=function(e,t={}){o("VoidTypeAnnotation",e,t)},t.assertEnumDeclaration=function(e,t={}){o("EnumDeclaration",e,t)},t.assertEnumBooleanBody=function(e,t={}){o("EnumBooleanBody",e,t)},t.assertEnumNumberBody=function(e,t={}){o("EnumNumberBody",e,t)},t.assertEnumStringBody=function(e,t={}){o("EnumStringBody",e,t)},t.assertEnumSymbolBody=function(e,t={}){o("EnumSymbolBody",e,t)},t.assertEnumBooleanMember=function(e,t={}){o("EnumBooleanMember",e,t)},t.assertEnumNumberMember=function(e,t={}){o("EnumNumberMember",e,t)},t.assertEnumStringMember=function(e,t={}){o("EnumStringMember",e,t)},t.assertEnumDefaultedMember=function(e,t={}){o("EnumDefaultedMember",e,t)},t.assertJSXAttribute=function(e,t={}){o("JSXAttribute",e,t)},t.assertJSXClosingElement=function(e,t={}){o("JSXClosingElement",e,t)},t.assertJSXElement=function(e,t={}){o("JSXElement",e,t)},t.assertJSXEmptyExpression=function(e,t={}){o("JSXEmptyExpression",e,t)},t.assertJSXExpressionContainer=function(e,t={}){o("JSXExpressionContainer",e,t)},t.assertJSXSpreadChild=function(e,t={}){o("JSXSpreadChild",e,t)},t.assertJSXIdentifier=function(e,t={}){o("JSXIdentifier",e,t)},t.assertJSXMemberExpression=function(e,t={}){o("JSXMemberExpression",e,t)},t.assertJSXNamespacedName=function(e,t={}){o("JSXNamespacedName",e,t)},t.assertJSXOpeningElement=function(e,t={}){o("JSXOpeningElement",e,t)},t.assertJSXSpreadAttribute=function(e,t={}){o("JSXSpreadAttribute",e,t)},t.assertJSXText=function(e,t={}){o("JSXText",e,t)},t.assertJSXFragment=function(e,t={}){o("JSXFragment",e,t)},t.assertJSXOpeningFragment=function(e,t={}){o("JSXOpeningFragment",e,t)},t.assertJSXClosingFragment=function(e,t={}){o("JSXClosingFragment",e,t)},t.assertNoop=function(e,t={}){o("Noop",e,t)},t.assertPlaceholder=function(e,t={}){o("Placeholder",e,t)},t.assertV8IntrinsicIdentifier=function(e,t={}){o("V8IntrinsicIdentifier",e,t)},t.assertArgumentPlaceholder=function(e,t={}){o("ArgumentPlaceholder",e,t)},t.assertAwaitExpression=function(e,t={}){o("AwaitExpression",e,t)},t.assertBindExpression=function(e,t={}){o("BindExpression",e,t)},t.assertClassProperty=function(e,t={}){o("ClassProperty",e,t)},t.assertOptionalMemberExpression=function(e,t={}){o("OptionalMemberExpression",e,t)},t.assertPipelineTopicExpression=function(e,t={}){o("PipelineTopicExpression",e,t)},t.assertPipelineBareFunction=function(e,t={}){o("PipelineBareFunction",e,t)},t.assertPipelinePrimaryTopicReference=function(e,t={}){o("PipelinePrimaryTopicReference",e,t)},t.assertOptionalCallExpression=function(e,t={}){o("OptionalCallExpression",e,t)},t.assertClassPrivateProperty=function(e,t={}){o("ClassPrivateProperty",e,t)},t.assertClassPrivateMethod=function(e,t={}){o("ClassPrivateMethod",e,t)},t.assertImport=function(e,t={}){o("Import",e,t)},t.assertDecorator=function(e,t={}){o("Decorator",e,t)},t.assertDoExpression=function(e,t={}){o("DoExpression",e,t)},t.assertExportDefaultSpecifier=function(e,t={}){o("ExportDefaultSpecifier",e,t)},t.assertExportNamespaceSpecifier=function(e,t={}){o("ExportNamespaceSpecifier",e,t)},t.assertPrivateName=function(e,t={}){o("PrivateName",e,t)},t.assertBigIntLiteral=function(e,t={}){o("BigIntLiteral",e,t)},t.assertTSParameterProperty=function(e,t={}){o("TSParameterProperty",e,t)},t.assertTSDeclareFunction=function(e,t={}){o("TSDeclareFunction",e,t)},t.assertTSDeclareMethod=function(e,t={}){o("TSDeclareMethod",e,t)},t.assertTSQualifiedName=function(e,t={}){o("TSQualifiedName",e,t)},t.assertTSCallSignatureDeclaration=function(e,t={}){o("TSCallSignatureDeclaration",e,t)},t.assertTSConstructSignatureDeclaration=function(e,t={}){o("TSConstructSignatureDeclaration",e,t)},t.assertTSPropertySignature=function(e,t={}){o("TSPropertySignature",e,t)},t.assertTSMethodSignature=function(e,t={}){o("TSMethodSignature",e,t)},t.assertTSIndexSignature=function(e,t={}){o("TSIndexSignature",e,t)},t.assertTSAnyKeyword=function(e,t={}){o("TSAnyKeyword",e,t)},t.assertTSBooleanKeyword=function(e,t={}){o("TSBooleanKeyword",e,t)},t.assertTSBigIntKeyword=function(e,t={}){o("TSBigIntKeyword",e,t)},t.assertTSNeverKeyword=function(e,t={}){o("TSNeverKeyword",e,t)},t.assertTSNullKeyword=function(e,t={}){o("TSNullKeyword",e,t)},t.assertTSNumberKeyword=function(e,t={}){o("TSNumberKeyword",e,t)},t.assertTSObjectKeyword=function(e,t={}){o("TSObjectKeyword",e,t)},t.assertTSStringKeyword=function(e,t={}){o("TSStringKeyword",e,t)},t.assertTSSymbolKeyword=function(e,t={}){o("TSSymbolKeyword",e,t)},t.assertTSUndefinedKeyword=function(e,t={}){o("TSUndefinedKeyword",e,t)},t.assertTSUnknownKeyword=function(e,t={}){o("TSUnknownKeyword",e,t)},t.assertTSVoidKeyword=function(e,t={}){o("TSVoidKeyword",e,t)},t.assertTSThisType=function(e,t={}){o("TSThisType",e,t)},t.assertTSFunctionType=function(e,t={}){o("TSFunctionType",e,t)},t.assertTSConstructorType=function(e,t={}){o("TSConstructorType",e,t)},t.assertTSTypeReference=function(e,t={}){o("TSTypeReference",e,t)},t.assertTSTypePredicate=function(e,t={}){o("TSTypePredicate",e,t)},t.assertTSTypeQuery=function(e,t={}){o("TSTypeQuery",e,t)},t.assertTSTypeLiteral=function(e,t={}){o("TSTypeLiteral",e,t)},t.assertTSArrayType=function(e,t={}){o("TSArrayType",e,t)},t.assertTSTupleType=function(e,t={}){o("TSTupleType",e,t)},t.assertTSOptionalType=function(e,t={}){o("TSOptionalType",e,t)},t.assertTSRestType=function(e,t={}){o("TSRestType",e,t)},t.assertTSUnionType=function(e,t={}){o("TSUnionType",e,t)},t.assertTSIntersectionType=function(e,t={}){o("TSIntersectionType",e,t)},t.assertTSConditionalType=function(e,t={}){o("TSConditionalType",e,t)},t.assertTSInferType=function(e,t={}){o("TSInferType",e,t)},t.assertTSParenthesizedType=function(e,t={}){o("TSParenthesizedType",e,t)},t.assertTSTypeOperator=function(e,t={}){o("TSTypeOperator",e,t)},t.assertTSIndexedAccessType=function(e,t={}){o("TSIndexedAccessType",e,t)},t.assertTSMappedType=function(e,t={}){o("TSMappedType",e,t)},t.assertTSLiteralType=function(e,t={}){o("TSLiteralType",e,t)},t.assertTSExpressionWithTypeArguments=function(e,t={}){o("TSExpressionWithTypeArguments",e,t)},t.assertTSInterfaceDeclaration=function(e,t={}){o("TSInterfaceDeclaration",e,t)},t.assertTSInterfaceBody=function(e,t={}){o("TSInterfaceBody",e,t)},t.assertTSTypeAliasDeclaration=function(e,t={}){o("TSTypeAliasDeclaration",e,t)},t.assertTSAsExpression=function(e,t={}){o("TSAsExpression",e,t)},t.assertTSTypeAssertion=function(e,t={}){o("TSTypeAssertion",e,t)},t.assertTSEnumDeclaration=function(e,t={}){o("TSEnumDeclaration",e,t)},t.assertTSEnumMember=function(e,t={}){o("TSEnumMember",e,t)},t.assertTSModuleDeclaration=function(e,t={}){o("TSModuleDeclaration",e,t)},t.assertTSModuleBlock=function(e,t={}){o("TSModuleBlock",e,t)},t.assertTSImportType=function(e,t={}){o("TSImportType",e,t)},t.assertTSImportEqualsDeclaration=function(e,t={}){o("TSImportEqualsDeclaration",e,t)},t.assertTSExternalModuleReference=function(e,t={}){o("TSExternalModuleReference",e,t)},t.assertTSNonNullExpression=function(e,t={}){o("TSNonNullExpression",e,t)},t.assertTSExportAssignment=function(e,t={}){o("TSExportAssignment",e,t)},t.assertTSNamespaceExportDeclaration=function(e,t={}){o("TSNamespaceExportDeclaration",e,t)},t.assertTSTypeAnnotation=function(e,t={}){o("TSTypeAnnotation",e,t)},t.assertTSTypeParameterInstantiation=function(e,t={}){o("TSTypeParameterInstantiation",e,t)},t.assertTSTypeParameterDeclaration=function(e,t={}){o("TSTypeParameterDeclaration",e,t)},t.assertTSTypeParameter=function(e,t={}){o("TSTypeParameter",e,t)},t.assertExpression=function(e,t={}){o("Expression",e,t)},t.assertBinary=function(e,t={}){o("Binary",e,t)},t.assertScopable=function(e,t={}){o("Scopable",e,t)},t.assertBlockParent=function(e,t={}){o("BlockParent",e,t)},t.assertBlock=function(e,t={}){o("Block",e,t)},t.assertStatement=function(e,t={}){o("Statement",e,t)},t.assertTerminatorless=function(e,t={}){o("Terminatorless",e,t)},t.assertCompletionStatement=function(e,t={}){o("CompletionStatement",e,t)},t.assertConditional=function(e,t={}){o("Conditional",e,t)},t.assertLoop=function(e,t={}){o("Loop",e,t)},t.assertWhile=function(e,t={}){o("While",e,t)},t.assertExpressionWrapper=function(e,t={}){o("ExpressionWrapper",e,t)},t.assertFor=function(e,t={}){o("For",e,t)},t.assertForXStatement=function(e,t={}){o("ForXStatement",e,t)},t.assertFunction=function(e,t={}){o("Function",e,t)},t.assertFunctionParent=function(e,t={}){o("FunctionParent",e,t)},t.assertPureish=function(e,t={}){o("Pureish",e,t)},t.assertDeclaration=function(e,t={}){o("Declaration",e,t)},t.assertPatternLike=function(e,t={}){o("PatternLike",e,t)},t.assertLVal=function(e,t={}){o("LVal",e,t)},t.assertTSEntityName=function(e,t={}){o("TSEntityName",e,t)},t.assertLiteral=function(e,t={}){o("Literal",e,t)},t.assertImmutable=function(e,t={}){o("Immutable",e,t)},t.assertUserWhitespacable=function(e,t={}){o("UserWhitespacable",e,t)},t.assertMethod=function(e,t={}){o("Method",e,t)},t.assertObjectMember=function(e,t={}){o("ObjectMember",e,t)},t.assertProperty=function(e,t={}){o("Property",e,t)},t.assertUnaryLike=function(e,t={}){o("UnaryLike",e,t)},t.assertPattern=function(e,t={}){o("Pattern",e,t)},t.assertClass=function(e,t={}){o("Class",e,t)},t.assertModuleDeclaration=function(e,t={}){o("ModuleDeclaration",e,t)},t.assertExportDeclaration=function(e,t={}){o("ExportDeclaration",e,t)},t.assertModuleSpecifier=function(e,t={}){o("ModuleSpecifier",e,t)},t.assertFlow=function(e,t={}){o("Flow",e,t)},t.assertFlowType=function(e,t={}){o("FlowType",e,t)},t.assertFlowBaseAnnotation=function(e,t={}){o("FlowBaseAnnotation",e,t)},t.assertFlowDeclaration=function(e,t={}){o("FlowDeclaration",e,t)},t.assertFlowPredicate=function(e,t={}){o("FlowPredicate",e,t)},t.assertEnumBody=function(e,t={}){o("EnumBody",e,t)},t.assertEnumMember=function(e,t={}){o("EnumMember",e,t)},t.assertJSX=function(e,t={}){o("JSX",e,t)},t.assertPrivate=function(e,t={}){o("Private",e,t)},t.assertTSTypeElement=function(e,t={}){o("TSTypeElement",e,t)},t.assertTSType=function(e,t={}){o("TSType",e,t)},t.assertNumberLiteral=function(e,t){console.trace("The node type NumberLiteral has been renamed to NumericLiteral"),o("NumberLiteral",e,t)},t.assertRegexLiteral=function(e,t){console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"),o("RegexLiteral",e,t)},t.assertRestProperty=function(e,t){console.trace("The node type RestProperty has been renamed to RestElement"),o("RestProperty",e,t)},t.assertSpreadProperty=function(e,t){console.trace("The node type SpreadProperty has been renamed to SpreadElement"),o("SpreadProperty",e,t)};var r,i=(r=n(61))&&r.__esModule?r:{default:r};function o(e,t,n){if(!(0,i.default)(e,t,n))throw new Error(`Expected type "${e}" with option ${JSON.stringify(n)}, `+`but instead got "${t.type}".`)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if("string"===e)return(0,r.stringTypeAnnotation)();if("number"===e)return(0,r.numberTypeAnnotation)();if("undefined"===e)return(0,r.voidTypeAnnotation)();if("boolean"===e)return(0,r.booleanTypeAnnotation)();if("function"===e)return(0,r.genericTypeAnnotation)((0,r.identifier)("Function"));if("object"===e)return(0,r.genericTypeAnnotation)((0,r.identifier)("Object"));if("symbol"===e)return(0,r.genericTypeAnnotation)((0,r.identifier)("Symbol"));throw new Error("Invalid typeof value")};var r=n(3)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){const t=(0,o.default)(e);return 1===t.length?t[0]:(0,i.unionTypeAnnotation)(t)};var r,i=n(3),o=(r=n(105))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return(0,i.default)(e)};var r,i=(r=n(22))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){const t=(0,i.default)(e);return t.loc=null,t};var r,i=(r=n(106))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n,r){return(0,i.default)(e,t,[{type:r?"CommentLine":"CommentBlock",value:n}])};var r,i=(r=n(107))&&r.__esModule?r:{default:r}},function(e,t,n){var r=n(242);e.exports=function(e){return e&&e.length?r(e):[]}},function(e,t,n){var r=n(109),i=n(245),o=n(249),a=n(111),s=n(250),u=n(66);e.exports=function(e,t,n){var c=-1,l=i,f=e.length,p=!0,h=[],d=h;if(n)p=!1,l=o;else if(f>=200){var y=t?null:s(e);if(y)return u(y);p=!1,l=a,d=new r}else d=t?[]:h;e:for(;++c-1}},function(e,t){e.exports=function(e,t,n,r){for(var i=e.length,o=n+(r?1:-1);r?o--:++o{e[t]=null}),e};var r=n(14)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TSTYPE_TYPES=t.TSTYPEELEMENT_TYPES=t.PRIVATE_TYPES=t.JSX_TYPES=t.ENUMMEMBER_TYPES=t.ENUMBODY_TYPES=t.FLOWPREDICATE_TYPES=t.FLOWDECLARATION_TYPES=t.FLOWBASEANNOTATION_TYPES=t.FLOWTYPE_TYPES=t.FLOW_TYPES=t.MODULESPECIFIER_TYPES=t.EXPORTDECLARATION_TYPES=t.MODULEDECLARATION_TYPES=t.CLASS_TYPES=t.PATTERN_TYPES=t.UNARYLIKE_TYPES=t.PROPERTY_TYPES=t.OBJECTMEMBER_TYPES=t.METHOD_TYPES=t.USERWHITESPACABLE_TYPES=t.IMMUTABLE_TYPES=t.LITERAL_TYPES=t.TSENTITYNAME_TYPES=t.LVAL_TYPES=t.PATTERNLIKE_TYPES=t.DECLARATION_TYPES=t.PUREISH_TYPES=t.FUNCTIONPARENT_TYPES=t.FUNCTION_TYPES=t.FORXSTATEMENT_TYPES=t.FOR_TYPES=t.EXPRESSIONWRAPPER_TYPES=t.WHILE_TYPES=t.LOOP_TYPES=t.CONDITIONAL_TYPES=t.COMPLETIONSTATEMENT_TYPES=t.TERMINATORLESS_TYPES=t.STATEMENT_TYPES=t.BLOCK_TYPES=t.BLOCKPARENT_TYPES=t.SCOPABLE_TYPES=t.BINARY_TYPES=t.EXPRESSION_TYPES=void 0;var r=n(2);const i=r.FLIPPED_ALIAS_KEYS.Expression;t.EXPRESSION_TYPES=i;const o=r.FLIPPED_ALIAS_KEYS.Binary;t.BINARY_TYPES=o;const a=r.FLIPPED_ALIAS_KEYS.Scopable;t.SCOPABLE_TYPES=a;const s=r.FLIPPED_ALIAS_KEYS.BlockParent;t.BLOCKPARENT_TYPES=s;const u=r.FLIPPED_ALIAS_KEYS.Block;t.BLOCK_TYPES=u;const c=r.FLIPPED_ALIAS_KEYS.Statement;t.STATEMENT_TYPES=c;const l=r.FLIPPED_ALIAS_KEYS.Terminatorless;t.TERMINATORLESS_TYPES=l;const f=r.FLIPPED_ALIAS_KEYS.CompletionStatement;t.COMPLETIONSTATEMENT_TYPES=f;const p=r.FLIPPED_ALIAS_KEYS.Conditional;t.CONDITIONAL_TYPES=p;const h=r.FLIPPED_ALIAS_KEYS.Loop;t.LOOP_TYPES=h;const d=r.FLIPPED_ALIAS_KEYS.While;t.WHILE_TYPES=d;const y=r.FLIPPED_ALIAS_KEYS.ExpressionWrapper;t.EXPRESSIONWRAPPER_TYPES=y;const m=r.FLIPPED_ALIAS_KEYS.For;t.FOR_TYPES=m;const v=r.FLIPPED_ALIAS_KEYS.ForXStatement;t.FORXSTATEMENT_TYPES=v;const b=r.FLIPPED_ALIAS_KEYS.Function;t.FUNCTION_TYPES=b;const g=r.FLIPPED_ALIAS_KEYS.FunctionParent;t.FUNCTIONPARENT_TYPES=g;const w=r.FLIPPED_ALIAS_KEYS.Pureish;t.PUREISH_TYPES=w;const S=r.FLIPPED_ALIAS_KEYS.Declaration;t.DECLARATION_TYPES=S;const O=r.FLIPPED_ALIAS_KEYS.PatternLike;t.PATTERNLIKE_TYPES=O;const P=r.FLIPPED_ALIAS_KEYS.LVal;t.LVAL_TYPES=P;const k=r.FLIPPED_ALIAS_KEYS.TSEntityName;t.TSENTITYNAME_TYPES=k;const x=r.FLIPPED_ALIAS_KEYS.Literal;t.LITERAL_TYPES=x;const E=r.FLIPPED_ALIAS_KEYS.Immutable;t.IMMUTABLE_TYPES=E;const j=r.FLIPPED_ALIAS_KEYS.UserWhitespacable;t.USERWHITESPACABLE_TYPES=j;const T=r.FLIPPED_ALIAS_KEYS.Method;t.METHOD_TYPES=T;const C=r.FLIPPED_ALIAS_KEYS.ObjectMember;t.OBJECTMEMBER_TYPES=C;const _=r.FLIPPED_ALIAS_KEYS.Property;t.PROPERTY_TYPES=_;const A=r.FLIPPED_ALIAS_KEYS.UnaryLike;t.UNARYLIKE_TYPES=A;const D=r.FLIPPED_ALIAS_KEYS.Pattern;t.PATTERN_TYPES=D;const I=r.FLIPPED_ALIAS_KEYS.Class;t.CLASS_TYPES=I;const F=r.FLIPPED_ALIAS_KEYS.ModuleDeclaration;t.MODULEDECLARATION_TYPES=F;const $=r.FLIPPED_ALIAS_KEYS.ExportDeclaration;t.EXPORTDECLARATION_TYPES=$;const M=r.FLIPPED_ALIAS_KEYS.ModuleSpecifier;t.MODULESPECIFIER_TYPES=M;const R=r.FLIPPED_ALIAS_KEYS.Flow;t.FLOW_TYPES=R;const L=r.FLIPPED_ALIAS_KEYS.FlowType;t.FLOWTYPE_TYPES=L;const B=r.FLIPPED_ALIAS_KEYS.FlowBaseAnnotation;t.FLOWBASEANNOTATION_TYPES=B;const N=r.FLIPPED_ALIAS_KEYS.FlowDeclaration;t.FLOWDECLARATION_TYPES=N;const V=r.FLIPPED_ALIAS_KEYS.FlowPredicate;t.FLOWPREDICATE_TYPES=V;const z=r.FLIPPED_ALIAS_KEYS.EnumBody;t.ENUMBODY_TYPES=z;const G=r.FLIPPED_ALIAS_KEYS.EnumMember;t.ENUMMEMBER_TYPES=G;const H=r.FLIPPED_ALIAS_KEYS.JSX;t.JSX_TYPES=H;const U=r.FLIPPED_ALIAS_KEYS.Private;t.PRIVATE_TYPES=U;const Y=r.FLIPPED_ALIAS_KEYS.TSTypeElement;t.TSTYPEELEMENT_TYPES=Y;const W=r.FLIPPED_ALIAS_KEYS.TSType;t.TSTYPE_TYPES=W},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t="body"){return e[t]=(0,i.default)(e[t],e)};var r,i=(r=n(115))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){"eval"!==(e=(0,i.default)(e))&&"arguments"!==e||(e="_"+e);return e};var r,i=(r=n(116))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t=e.key||e.property){!e.computed&&(0,r.isIdentifier)(t)&&(t=(0,i.stringLiteral)(t.name));return t};var r=n(1),i=n(3)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){(0,r.isExpressionStatement)(e)&&(e=e.expression);if((0,r.isExpression)(e))return e;(0,r.isClass)(e)?e.type="ClassExpression":(0,r.isFunction)(e)&&(e.type="FunctionExpression");if(!(0,r.isExpression)(e))throw new Error(`cannot turn ${e.type} to an expression`);return e};var r=n(1)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=s;var r=n(1),i=a(n(22)),o=a(n(117));function a(e){return e&&e.__esModule?e:{default:e}}function s(e,t=e.key){let n;return"method"===e.kind?s.increment()+"":(n=(0,r.isIdentifier)(t)?t.name:(0,r.isStringLiteral)(t)?JSON.stringify(t.value):JSON.stringify((0,o.default)((0,i.default)(t))),e.computed&&(n=`[${n}]`),e.static&&(n=`static:${n}`),n)}s.uid=0,s.increment=function(){return s.uid>=Number.MAX_SAFE_INTEGER?s.uid=0:s.uid++}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if(!e||!e.length)return;const n=[],r=(0,i.default)(e,t,n);if(!r)return;for(const e of n)t.push(e);return r};var r,i=(r=n(260))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t,n,s){const u=[];let c=!0;for(const l of t)if(c=!1,(0,i.isExpression)(l))u.push(l);else if((0,i.isExpressionStatement)(l))u.push(l.expression);else if((0,i.isVariableDeclaration)(l)){if("var"!==l.kind)return;for(const e of l.declarations){const t=(0,r.default)(e);for(const e of Object.keys(t))s.push({kind:l.kind,id:(0,a.default)(t[e])});e.init&&u.push((0,o.assignmentExpression)("=",e.id,e.init))}c=!0}else if((0,i.isIfStatement)(l)){const t=l.consequent?e([l.consequent],n,s):n.buildUndefinedNode(),r=l.alternate?e([l.alternate],n,s):n.buildUndefinedNode();if(!t||!r)return;u.push((0,o.conditionalExpression)(l.test,t,r))}else if((0,i.isBlockStatement)(l)){const t=e(l.body,n,s);if(!t)return;u.push(t)}else{if(!(0,i.isEmptyStatement)(l))return;c=!0}c&&u.push(n.buildUndefinedNode());return 1===u.length?u[0]:(0,o.sequenceExpression)(u)};var r=s(n(34)),i=n(1),o=n(3),a=s(n(22));function s(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if((0,r.isStatement)(e))return e;let n,o=!1;if((0,r.isClass)(e))o=!0,n="ClassDeclaration";else if((0,r.isFunction)(e))o=!0,n="FunctionDeclaration";else if((0,r.isAssignmentExpression)(e))return(0,i.expressionStatement)(e);o&&!e.id&&(n=!1);if(!n){if(t)return!1;throw new Error(`cannot turn ${e.type} to a statement`)}return e.type=n,e};var r=n(1),i=n(3)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t){if(void 0===t)return(0,a.identifier)("undefined");if(!0===t||!1===t)return(0,a.booleanLiteral)(t);if(null===t)return(0,a.nullLiteral)();if("string"==typeof t)return(0,a.stringLiteral)(t);if("number"==typeof t){let e;if(Number.isFinite(t))e=(0,a.numericLiteral)(Math.abs(t));else{let n;n=Number.isNaN(t)?(0,a.numericLiteral)(0):(0,a.numericLiteral)(1),e=(0,a.binaryExpression)("/",n,(0,a.numericLiteral)(0))}return(t<0||Object.is(t,-0))&&(e=(0,a.unaryExpression)("-",e)),e}if((0,i.default)(t)){const e=t.source,n=t.toString().match(/\/([a-z]+|)$/)[1];return(0,a.regExpLiteral)(e,n)}if(Array.isArray(t))return(0,a.arrayExpression)(t.map(e));if((0,r.default)(t)){const n=[];for(const r of Object.keys(t)){let i;i=(0,o.default)(r)?(0,a.identifier)(r):(0,a.stringLiteral)(r),n.push((0,a.objectProperty)(i,e(t[r])))}return(0,a.objectExpression)(n)}throw new Error("don't know how to turn this value into a node")};var r=s(n(263)),i=s(n(264)),o=s(n(21)),a=n(3);function s(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){var r=n(11),i=n(58),o=n(6),a=Function.prototype,s=Object.prototype,u=a.toString,c=s.hasOwnProperty,l=u.call(Object);e.exports=function(e){if(!o(e)||"[object Object]"!=r(e))return!1;var t=i(e);if(null===t)return!0;var n=c.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&u.call(n)==l}},function(e,t,n){var r=n(265),i=n(20),o=n(32),a=o&&o.isRegExp,s=a?i(a):r;e.exports=s},function(e,t,n){var r=n(11),i=n(6);e.exports=function(e){return i(e)&&"[object RegExp]"==r(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n=!1){return e.object=(0,r.memberExpression)(e.object,e.property,e.computed),e.property=t,e.computed=!!n,e};var r=n(3)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if(!e||!t)return e;for(const n of i.INHERIT_KEYS.optional)null==e[n]&&(e[n]=t[n]);for(const n of Object.keys(t))"_"===n[0]&&"__clone"!==n&&(e[n]=t[n]);for(const n of i.INHERIT_KEYS.force)e[n]=t[n];return(0,o.default)(e,t),e};var r,i=n(14),o=(r=n(113))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return e.object=(0,r.memberExpression)(t,e.object),e};var r=n(3)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return(0,i.default)(e,t,!0)};var r,i=(r=n(34))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n){"function"==typeof t&&(t={enter:t});const{enter:i,exit:o}=t;!function e(t,n,i,o,a){const s=r.VISITOR_KEYS[t.type];if(!s)return;n&&n(t,a,o);for(const r of s){const s=t[r];if(Array.isArray(s))for(let u=0;u=0)return!0}else if(o===e)return!0}return!1};var r,i=(r=n(34))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return(0,i.isFunctionDeclaration)(e)||(0,i.isClassDeclaration)(e)||(0,o.default)(e)};var r,i=n(1),o=(r=n(120))&&r.__esModule?r:{default:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if((0,i.default)(e.type,"Immutable"))return!0;if((0,o.isIdentifier)(e))return"undefined"===e.name;return!1};var r,i=(r=n(62))&&r.__esModule?r:{default:r},o=n(1)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t,n){if("object"!=typeof t||"object"!=typeof n||null==t||null==n)return t===n;if(t.type!==n.type)return!1;const i=Object.keys(r.NODE_FIELDS[t.type]||t.type),o=r.VISITOR_KEYS[t.type];for(const r of i){if(typeof t[r]!=typeof n[r])return!1;if(null!=t[r]||null!=n[r]){if(null==t[r]||null==n[r])return!1;if(Array.isArray(t[r])){if(!Array.isArray(n[r]))return!1;if(t[r].length!==n[r].length)return!1;for(let i=0;i{if("%%"===n)return n;s++;const o=r.formatters[i];if("function"==typeof o){const r=e[s];n=o.call(t,r),e.splice(s,1),s--}return n}),r.formatArgs.call(t,e),(t.log||r.log).apply(t,e)}return a.namespace=e,a.enabled=r.enabled(e),a.useColors=r.useColors(),a.color=t(e),a.destroy=i,a.extend=o,"function"==typeof r.init&&r.init(a),r.instances.push(a),a}function i(){const e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function o(e,t){const n=r(this.namespace+(void 0===t?":":t)+e);return n.log=this.log,n}function a(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return r.debug=r,r.default=r,r.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},r.disable=function(){const e=[...r.names.map(a),...r.skips.map(a).map(e=>"-"+e)].join(",");return r.enable(""),e},r.enable=function(e){let t;r.save(e),r.names=[],r.skips=[];const n=("string"==typeof e?e:"").split(/[\s,]+/),i=n.length;for(t=0;t{r[t]=e[t]}),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}},function(e,t){var n=1e3,r=6e4,i=36e5,o=24*i;function a(e,t,n,r){var i=t>=1.5*n;return Math.round(e/n)+" "+r+(i?"s":"")}e.exports=function(e,t){t=t||{};var s=typeof e;if("string"===s&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!t)return;var a=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*a;case"weeks":case"week":case"w":return 6048e5*a;case"days":case"day":case"d":return a*o;case"hours":case"hour":case"hrs":case"hr":case"h":return a*i;case"minutes":case"minute":case"mins":case"min":case"m":return a*r;case"seconds":case"second":case"secs":case"sec":case"s":return a*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}(e);if("number"===s&&isFinite(e))return t.long?function(e){var t=Math.abs(e);if(t>=o)return a(e,t,o,"day");if(t>=i)return a(e,t,i,"hour");if(t>=r)return a(e,t,r,"minute");if(t>=n)return a(e,t,n,"second");return e+" ms"}(e):function(e){var t=Math.abs(e);if(t>=o)return Math.round(e/o)+"d";if(t>=i)return Math.round(e/i)+"h";if(t>=r)return Math.round(e/r)+"m";if(t>=n)return Math.round(e/n)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){var r=n(11),i=n(4),o=n(6);e.exports=function(e){return"string"==typeof e||!i(e)&&o(e)&&"[object String]"==r(e)}},function(e,t,n){var r=n(284);e.exports=function(e){return e?(e=r(e))===1/0||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}},function(e,t,n){var r=n(12),i=n(23),o=/^\s+|\s+$/g,a=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,u=/^0o[0-7]+$/i,c=parseInt;e.exports=function(e){if("number"==typeof e)return e;if(i(e))return NaN;if(r(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=r(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(o,"");var n=s.test(e);return n||u.test(e)?c(e.slice(2),n?2:8):a.test(e)?NaN:+e}},function(e,t,n){var r=n(286),i=n(17);e.exports=function(e){return null==e?[]:r(e,i(e))}},function(e,t,n){var r=n(70);e.exports=function(e,t){return r(t,(function(t){return e[t]}))}},function(e,t){var n=Math.floor;e.exports=function(e,t){var r="";if(!e||t<1||t>9007199254740991)return r;do{t%2&&(r+=e),(t=n(t/2))&&(e+=e)}while(t);return r}},function(e,t,n){var r=n(16),i=n(70),o=n(4),a=n(23),s=r?r.prototype:void 0,u=s?s.toString:void 0;e.exports=function e(t){if("string"==typeof t)return t;if(o(t))return i(t,e)+"";if(a(t))return u?u.call(t):"";var n=t+"";return"0"==n&&1/t==-1/0?"-0":n}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;o(n(123));var r=o(n(290));!function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=r?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o]}n.default=e,t&&t.set(e,n)}(n(0));function i(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}function o(e){return e&&e.__esModule?e:{default:e}}const a={ReferencedIdentifier({node:e},t){e.name===t.oldName&&(e.name=t.newName)},Scope(e,t){e.scope.bindingIdentifierEquals(t.oldName,t.binding.identifier)||e.skip()},"AssignmentExpression|Declaration"(e,t){const n=e.getOuterBindingIdentifiers();for(const e in n)e===t.oldName&&(n[e].name=t.newName)}};t.default=class{constructor(e,t,n){this.newName=n,this.oldName=t,this.binding=e}maybeConvertFromExportDeclaration(e){const t=e.parentPath;t.isExportDeclaration()&&(t.isExportDefaultDeclaration()&&!t.get("declaration").node.id||(0,r.default)(t))}maybeConvertFromClassFunctionDeclaration(e){}maybeConvertFromClassFunctionExpression(e){}rename(e){const{binding:t,oldName:n,newName:r}=this,{scope:i,path:o}=t,s=o.find(e=>e.isDeclaration()||e.isFunctionExpression()||e.isClassExpression());if(s){s.getOuterBindingIdentifiers()[n]===t.identifier&&this.maybeConvertFromExportDeclaration(s)}i.traverse(e||i.block,a,this),e||(i.removeOwnBinding(n),i.bindings[r]=t,this.binding.identifier.name=r),t.type,s&&(this.maybeConvertFromClassFunctionDeclaration(s),this.maybeConvertFromClassFunctionExpression(s))}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if(!e.isExportDeclaration())throw new Error("Only export declarations can be splitted.");const t=e.isExportDefaultDeclaration(),n=e.get("declaration"),i=n.isClassDeclaration();if(t){const t=n.isFunctionDeclaration()||i,o=n.isScope()?n.scope.parent:n.scope;let a=n.node.id,s=!1;a||(s=!0,a=o.generateUidIdentifier("default"),(t||n.isFunctionExpression()||n.isClassExpression())&&(n.node.id=r.cloneNode(a)));const u=t?n:r.variableDeclaration("var",[r.variableDeclarator(r.cloneNode(a),n.node)]),c=r.exportNamedDeclaration(null,[r.exportSpecifier(r.cloneNode(a),r.identifier("default"))]);return e.insertAfter(c),e.replaceWith(u),s&&o.registerDeclaration(e),e}if(e.get("specifiers").length>0)throw new Error("It doesn't make sense to split exported specifiers.");const o=n.getOuterBindingIdentifiers(),a=Object.keys(o).map(e=>r.exportSpecifier(r.identifier(e),r.identifier(e))),s=r.exportNamedDeclaration(null,a);return e.insertAfter(s),e.replaceWith(n.node),e};var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=r?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(0));function i(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}},function(e,t,n){var r=n(124),i=n(19),o=n(71),a=n(55),s=Object.prototype,u=s.hasOwnProperty,c=r((function(e,t){e=Object(e);var n=-1,r=t.length,c=r>2?t[2]:void 0;for(c&&o(t[0],t[1],c)&&(r=1);++n0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}},function(e,t,n){"use strict";e.exports=n(299)},function(e){e.exports=JSON.parse('{"builtin":{"Array":false,"ArrayBuffer":false,"Atomics":false,"BigInt":false,"BigInt64Array":false,"BigUint64Array":false,"Boolean":false,"constructor":false,"DataView":false,"Date":false,"decodeURI":false,"decodeURIComponent":false,"encodeURI":false,"encodeURIComponent":false,"Error":false,"escape":false,"eval":false,"EvalError":false,"Float32Array":false,"Float64Array":false,"Function":false,"globalThis":false,"hasOwnProperty":false,"Infinity":false,"Int16Array":false,"Int32Array":false,"Int8Array":false,"isFinite":false,"isNaN":false,"isPrototypeOf":false,"JSON":false,"Map":false,"Math":false,"NaN":false,"Number":false,"Object":false,"parseFloat":false,"parseInt":false,"Promise":false,"propertyIsEnumerable":false,"Proxy":false,"RangeError":false,"ReferenceError":false,"Reflect":false,"RegExp":false,"Set":false,"SharedArrayBuffer":false,"String":false,"Symbol":false,"SyntaxError":false,"toLocaleString":false,"toString":false,"TypeError":false,"Uint16Array":false,"Uint32Array":false,"Uint8Array":false,"Uint8ClampedArray":false,"undefined":false,"unescape":false,"URIError":false,"valueOf":false,"WeakMap":false,"WeakSet":false},"es5":{"Array":false,"Boolean":false,"constructor":false,"Date":false,"decodeURI":false,"decodeURIComponent":false,"encodeURI":false,"encodeURIComponent":false,"Error":false,"escape":false,"eval":false,"EvalError":false,"Function":false,"hasOwnProperty":false,"Infinity":false,"isFinite":false,"isNaN":false,"isPrototypeOf":false,"JSON":false,"Math":false,"NaN":false,"Number":false,"Object":false,"parseFloat":false,"parseInt":false,"propertyIsEnumerable":false,"RangeError":false,"ReferenceError":false,"RegExp":false,"String":false,"SyntaxError":false,"toLocaleString":false,"toString":false,"TypeError":false,"undefined":false,"unescape":false,"URIError":false,"valueOf":false},"es2015":{"Array":false,"ArrayBuffer":false,"Boolean":false,"constructor":false,"DataView":false,"Date":false,"decodeURI":false,"decodeURIComponent":false,"encodeURI":false,"encodeURIComponent":false,"Error":false,"escape":false,"eval":false,"EvalError":false,"Float32Array":false,"Float64Array":false,"Function":false,"hasOwnProperty":false,"Infinity":false,"Int16Array":false,"Int32Array":false,"Int8Array":false,"isFinite":false,"isNaN":false,"isPrototypeOf":false,"JSON":false,"Map":false,"Math":false,"NaN":false,"Number":false,"Object":false,"parseFloat":false,"parseInt":false,"Promise":false,"propertyIsEnumerable":false,"Proxy":false,"RangeError":false,"ReferenceError":false,"Reflect":false,"RegExp":false,"Set":false,"String":false,"Symbol":false,"SyntaxError":false,"toLocaleString":false,"toString":false,"TypeError":false,"Uint16Array":false,"Uint32Array":false,"Uint8Array":false,"Uint8ClampedArray":false,"undefined":false,"unescape":false,"URIError":false,"valueOf":false,"WeakMap":false,"WeakSet":false},"es2017":{"Array":false,"ArrayBuffer":false,"Atomics":false,"Boolean":false,"constructor":false,"DataView":false,"Date":false,"decodeURI":false,"decodeURIComponent":false,"encodeURI":false,"encodeURIComponent":false,"Error":false,"escape":false,"eval":false,"EvalError":false,"Float32Array":false,"Float64Array":false,"Function":false,"hasOwnProperty":false,"Infinity":false,"Int16Array":false,"Int32Array":false,"Int8Array":false,"isFinite":false,"isNaN":false,"isPrototypeOf":false,"JSON":false,"Map":false,"Math":false,"NaN":false,"Number":false,"Object":false,"parseFloat":false,"parseInt":false,"Promise":false,"propertyIsEnumerable":false,"Proxy":false,"RangeError":false,"ReferenceError":false,"Reflect":false,"RegExp":false,"Set":false,"SharedArrayBuffer":false,"String":false,"Symbol":false,"SyntaxError":false,"toLocaleString":false,"toString":false,"TypeError":false,"Uint16Array":false,"Uint32Array":false,"Uint8Array":false,"Uint8ClampedArray":false,"undefined":false,"unescape":false,"URIError":false,"valueOf":false,"WeakMap":false,"WeakSet":false},"browser":{"AbortController":false,"AbortSignal":false,"addEventListener":false,"alert":false,"AnalyserNode":false,"Animation":false,"AnimationEffectReadOnly":false,"AnimationEffectTiming":false,"AnimationEffectTimingReadOnly":false,"AnimationEvent":false,"AnimationPlaybackEvent":false,"AnimationTimeline":false,"applicationCache":false,"ApplicationCache":false,"ApplicationCacheErrorEvent":false,"atob":false,"Attr":false,"Audio":false,"AudioBuffer":false,"AudioBufferSourceNode":false,"AudioContext":false,"AudioDestinationNode":false,"AudioListener":false,"AudioNode":false,"AudioParam":false,"AudioProcessingEvent":false,"AudioScheduledSourceNode":false,"AudioWorkletGlobalScope ":false,"AudioWorkletNode":false,"AudioWorkletProcessor":false,"BarProp":false,"BaseAudioContext":false,"BatteryManager":false,"BeforeUnloadEvent":false,"BiquadFilterNode":false,"Blob":false,"BlobEvent":false,"blur":false,"BroadcastChannel":false,"btoa":false,"BudgetService":false,"ByteLengthQueuingStrategy":false,"Cache":false,"caches":false,"CacheStorage":false,"cancelAnimationFrame":false,"cancelIdleCallback":false,"CanvasCaptureMediaStreamTrack":false,"CanvasGradient":false,"CanvasPattern":false,"CanvasRenderingContext2D":false,"ChannelMergerNode":false,"ChannelSplitterNode":false,"CharacterData":false,"clearInterval":false,"clearTimeout":false,"clientInformation":false,"ClipboardEvent":false,"close":false,"closed":false,"CloseEvent":false,"Comment":false,"CompositionEvent":false,"confirm":false,"console":false,"ConstantSourceNode":false,"ConvolverNode":false,"CountQueuingStrategy":false,"createImageBitmap":false,"Credential":false,"CredentialsContainer":false,"crypto":false,"Crypto":false,"CryptoKey":false,"CSS":false,"CSSConditionRule":false,"CSSFontFaceRule":false,"CSSGroupingRule":false,"CSSImportRule":false,"CSSKeyframeRule":false,"CSSKeyframesRule":false,"CSSMediaRule":false,"CSSNamespaceRule":false,"CSSPageRule":false,"CSSRule":false,"CSSRuleList":false,"CSSStyleDeclaration":false,"CSSStyleRule":false,"CSSStyleSheet":false,"CSSSupportsRule":false,"CustomElementRegistry":false,"customElements":false,"CustomEvent":false,"DataTransfer":false,"DataTransferItem":false,"DataTransferItemList":false,"defaultstatus":false,"defaultStatus":false,"DelayNode":false,"DeviceMotionEvent":false,"DeviceOrientationEvent":false,"devicePixelRatio":false,"dispatchEvent":false,"document":false,"Document":false,"DocumentFragment":false,"DocumentType":false,"DOMError":false,"DOMException":false,"DOMImplementation":false,"DOMMatrix":false,"DOMMatrixReadOnly":false,"DOMParser":false,"DOMPoint":false,"DOMPointReadOnly":false,"DOMQuad":false,"DOMRect":false,"DOMRectReadOnly":false,"DOMStringList":false,"DOMStringMap":false,"DOMTokenList":false,"DragEvent":false,"DynamicsCompressorNode":false,"Element":false,"ErrorEvent":false,"event":false,"Event":false,"EventSource":false,"EventTarget":false,"external":false,"fetch":false,"File":false,"FileList":false,"FileReader":false,"find":false,"focus":false,"FocusEvent":false,"FontFace":false,"FontFaceSetLoadEvent":false,"FormData":false,"frameElement":false,"frames":false,"GainNode":false,"Gamepad":false,"GamepadButton":false,"GamepadEvent":false,"getComputedStyle":false,"getSelection":false,"HashChangeEvent":false,"Headers":false,"history":false,"History":false,"HTMLAllCollection":false,"HTMLAnchorElement":false,"HTMLAreaElement":false,"HTMLAudioElement":false,"HTMLBaseElement":false,"HTMLBodyElement":false,"HTMLBRElement":false,"HTMLButtonElement":false,"HTMLCanvasElement":false,"HTMLCollection":false,"HTMLContentElement":false,"HTMLDataElement":false,"HTMLDataListElement":false,"HTMLDetailsElement":false,"HTMLDialogElement":false,"HTMLDirectoryElement":false,"HTMLDivElement":false,"HTMLDListElement":false,"HTMLDocument":false,"HTMLElement":false,"HTMLEmbedElement":false,"HTMLFieldSetElement":false,"HTMLFontElement":false,"HTMLFormControlsCollection":false,"HTMLFormElement":false,"HTMLFrameElement":false,"HTMLFrameSetElement":false,"HTMLHeadElement":false,"HTMLHeadingElement":false,"HTMLHRElement":false,"HTMLHtmlElement":false,"HTMLIFrameElement":false,"HTMLImageElement":false,"HTMLInputElement":false,"HTMLLabelElement":false,"HTMLLegendElement":false,"HTMLLIElement":false,"HTMLLinkElement":false,"HTMLMapElement":false,"HTMLMarqueeElement":false,"HTMLMediaElement":false,"HTMLMenuElement":false,"HTMLMetaElement":false,"HTMLMeterElement":false,"HTMLModElement":false,"HTMLObjectElement":false,"HTMLOListElement":false,"HTMLOptGroupElement":false,"HTMLOptionElement":false,"HTMLOptionsCollection":false,"HTMLOutputElement":false,"HTMLParagraphElement":false,"HTMLParamElement":false,"HTMLPictureElement":false,"HTMLPreElement":false,"HTMLProgressElement":false,"HTMLQuoteElement":false,"HTMLScriptElement":false,"HTMLSelectElement":false,"HTMLShadowElement":false,"HTMLSlotElement":false,"HTMLSourceElement":false,"HTMLSpanElement":false,"HTMLStyleElement":false,"HTMLTableCaptionElement":false,"HTMLTableCellElement":false,"HTMLTableColElement":false,"HTMLTableElement":false,"HTMLTableRowElement":false,"HTMLTableSectionElement":false,"HTMLTemplateElement":false,"HTMLTextAreaElement":false,"HTMLTimeElement":false,"HTMLTitleElement":false,"HTMLTrackElement":false,"HTMLUListElement":false,"HTMLUnknownElement":false,"HTMLVideoElement":false,"IDBCursor":false,"IDBCursorWithValue":false,"IDBDatabase":false,"IDBFactory":false,"IDBIndex":false,"IDBKeyRange":false,"IDBObjectStore":false,"IDBOpenDBRequest":false,"IDBRequest":false,"IDBTransaction":false,"IDBVersionChangeEvent":false,"IdleDeadline":false,"IIRFilterNode":false,"Image":false,"ImageBitmap":false,"ImageBitmapRenderingContext":false,"ImageCapture":false,"ImageData":false,"indexedDB":false,"innerHeight":false,"innerWidth":false,"InputEvent":false,"IntersectionObserver":false,"IntersectionObserverEntry":false,"Intl":false,"isSecureContext":false,"KeyboardEvent":false,"KeyframeEffect":false,"KeyframeEffectReadOnly":false,"length":false,"localStorage":false,"location":true,"Location":false,"locationbar":false,"matchMedia":false,"MediaDeviceInfo":false,"MediaDevices":false,"MediaElementAudioSourceNode":false,"MediaEncryptedEvent":false,"MediaError":false,"MediaKeyMessageEvent":false,"MediaKeySession":false,"MediaKeyStatusMap":false,"MediaKeySystemAccess":false,"MediaList":false,"MediaQueryList":false,"MediaQueryListEvent":false,"MediaRecorder":false,"MediaSettingsRange":false,"MediaSource":false,"MediaStream":false,"MediaStreamAudioDestinationNode":false,"MediaStreamAudioSourceNode":false,"MediaStreamEvent":false,"MediaStreamTrack":false,"MediaStreamTrackEvent":false,"menubar":false,"MessageChannel":false,"MessageEvent":false,"MessagePort":false,"MIDIAccess":false,"MIDIConnectionEvent":false,"MIDIInput":false,"MIDIInputMap":false,"MIDIMessageEvent":false,"MIDIOutput":false,"MIDIOutputMap":false,"MIDIPort":false,"MimeType":false,"MimeTypeArray":false,"MouseEvent":false,"moveBy":false,"moveTo":false,"MutationEvent":false,"MutationObserver":false,"MutationRecord":false,"name":false,"NamedNodeMap":false,"NavigationPreloadManager":false,"navigator":false,"Navigator":false,"NetworkInformation":false,"Node":false,"NodeFilter":false,"NodeIterator":false,"NodeList":false,"Notification":false,"OfflineAudioCompletionEvent":false,"OfflineAudioContext":false,"offscreenBuffering":false,"OffscreenCanvas":true,"onabort":true,"onafterprint":true,"onanimationend":true,"onanimationiteration":true,"onanimationstart":true,"onappinstalled":true,"onauxclick":true,"onbeforeinstallprompt":true,"onbeforeprint":true,"onbeforeunload":true,"onblur":true,"oncancel":true,"oncanplay":true,"oncanplaythrough":true,"onchange":true,"onclick":true,"onclose":true,"oncontextmenu":true,"oncuechange":true,"ondblclick":true,"ondevicemotion":true,"ondeviceorientation":true,"ondeviceorientationabsolute":true,"ondrag":true,"ondragend":true,"ondragenter":true,"ondragleave":true,"ondragover":true,"ondragstart":true,"ondrop":true,"ondurationchange":true,"onemptied":true,"onended":true,"onerror":true,"onfocus":true,"ongotpointercapture":true,"onhashchange":true,"oninput":true,"oninvalid":true,"onkeydown":true,"onkeypress":true,"onkeyup":true,"onlanguagechange":true,"onload":true,"onloadeddata":true,"onloadedmetadata":true,"onloadstart":true,"onlostpointercapture":true,"onmessage":true,"onmessageerror":true,"onmousedown":true,"onmouseenter":true,"onmouseleave":true,"onmousemove":true,"onmouseout":true,"onmouseover":true,"onmouseup":true,"onmousewheel":true,"onoffline":true,"ononline":true,"onpagehide":true,"onpageshow":true,"onpause":true,"onplay":true,"onplaying":true,"onpointercancel":true,"onpointerdown":true,"onpointerenter":true,"onpointerleave":true,"onpointermove":true,"onpointerout":true,"onpointerover":true,"onpointerup":true,"onpopstate":true,"onprogress":true,"onratechange":true,"onrejectionhandled":true,"onreset":true,"onresize":true,"onscroll":true,"onsearch":true,"onseeked":true,"onseeking":true,"onselect":true,"onstalled":true,"onstorage":true,"onsubmit":true,"onsuspend":true,"ontimeupdate":true,"ontoggle":true,"ontransitionend":true,"onunhandledrejection":true,"onunload":true,"onvolumechange":true,"onwaiting":true,"onwheel":true,"open":false,"openDatabase":false,"opener":false,"Option":false,"origin":false,"OscillatorNode":false,"outerHeight":false,"outerWidth":false,"PageTransitionEvent":false,"pageXOffset":false,"pageYOffset":false,"PannerNode":false,"parent":false,"Path2D":false,"PaymentAddress":false,"PaymentRequest":false,"PaymentRequestUpdateEvent":false,"PaymentResponse":false,"performance":false,"Performance":false,"PerformanceEntry":false,"PerformanceLongTaskTiming":false,"PerformanceMark":false,"PerformanceMeasure":false,"PerformanceNavigation":false,"PerformanceNavigationTiming":false,"PerformanceObserver":false,"PerformanceObserverEntryList":false,"PerformancePaintTiming":false,"PerformanceResourceTiming":false,"PerformanceTiming":false,"PeriodicWave":false,"Permissions":false,"PermissionStatus":false,"personalbar":false,"PhotoCapabilities":false,"Plugin":false,"PluginArray":false,"PointerEvent":false,"PopStateEvent":false,"postMessage":false,"Presentation":false,"PresentationAvailability":false,"PresentationConnection":false,"PresentationConnectionAvailableEvent":false,"PresentationConnectionCloseEvent":false,"PresentationConnectionList":false,"PresentationReceiver":false,"PresentationRequest":false,"print":false,"ProcessingInstruction":false,"ProgressEvent":false,"PromiseRejectionEvent":false,"prompt":false,"PushManager":false,"PushSubscription":false,"PushSubscriptionOptions":false,"queueMicrotask":false,"RadioNodeList":false,"Range":false,"ReadableStream":false,"registerProcessor":false,"RemotePlayback":false,"removeEventListener":false,"Request":false,"requestAnimationFrame":false,"requestIdleCallback":false,"resizeBy":false,"ResizeObserver":false,"ResizeObserverEntry":false,"resizeTo":false,"Response":false,"RTCCertificate":false,"RTCDataChannel":false,"RTCDataChannelEvent":false,"RTCDtlsTransport":false,"RTCIceCandidate":false,"RTCIceGatherer":false,"RTCIceTransport":false,"RTCPeerConnection":false,"RTCPeerConnectionIceEvent":false,"RTCRtpContributingSource":false,"RTCRtpReceiver":false,"RTCRtpSender":false,"RTCSctpTransport":false,"RTCSessionDescription":false,"RTCStatsReport":false,"RTCTrackEvent":false,"screen":false,"Screen":false,"screenLeft":false,"ScreenOrientation":false,"screenTop":false,"screenX":false,"screenY":false,"ScriptProcessorNode":false,"scroll":false,"scrollbars":false,"scrollBy":false,"scrollTo":false,"scrollX":false,"scrollY":false,"SecurityPolicyViolationEvent":false,"Selection":false,"self":false,"ServiceWorker":false,"ServiceWorkerContainer":false,"ServiceWorkerRegistration":false,"sessionStorage":false,"setInterval":false,"setTimeout":false,"ShadowRoot":false,"SharedWorker":false,"SourceBuffer":false,"SourceBufferList":false,"speechSynthesis":false,"SpeechSynthesisEvent":false,"SpeechSynthesisUtterance":false,"StaticRange":false,"status":false,"statusbar":false,"StereoPannerNode":false,"stop":false,"Storage":false,"StorageEvent":false,"StorageManager":false,"styleMedia":false,"StyleSheet":false,"StyleSheetList":false,"SubtleCrypto":false,"SVGAElement":false,"SVGAngle":false,"SVGAnimatedAngle":false,"SVGAnimatedBoolean":false,"SVGAnimatedEnumeration":false,"SVGAnimatedInteger":false,"SVGAnimatedLength":false,"SVGAnimatedLengthList":false,"SVGAnimatedNumber":false,"SVGAnimatedNumberList":false,"SVGAnimatedPreserveAspectRatio":false,"SVGAnimatedRect":false,"SVGAnimatedString":false,"SVGAnimatedTransformList":false,"SVGAnimateElement":false,"SVGAnimateMotionElement":false,"SVGAnimateTransformElement":false,"SVGAnimationElement":false,"SVGCircleElement":false,"SVGClipPathElement":false,"SVGComponentTransferFunctionElement":false,"SVGDefsElement":false,"SVGDescElement":false,"SVGDiscardElement":false,"SVGElement":false,"SVGEllipseElement":false,"SVGFEBlendElement":false,"SVGFEColorMatrixElement":false,"SVGFEComponentTransferElement":false,"SVGFECompositeElement":false,"SVGFEConvolveMatrixElement":false,"SVGFEDiffuseLightingElement":false,"SVGFEDisplacementMapElement":false,"SVGFEDistantLightElement":false,"SVGFEDropShadowElement":false,"SVGFEFloodElement":false,"SVGFEFuncAElement":false,"SVGFEFuncBElement":false,"SVGFEFuncGElement":false,"SVGFEFuncRElement":false,"SVGFEGaussianBlurElement":false,"SVGFEImageElement":false,"SVGFEMergeElement":false,"SVGFEMergeNodeElement":false,"SVGFEMorphologyElement":false,"SVGFEOffsetElement":false,"SVGFEPointLightElement":false,"SVGFESpecularLightingElement":false,"SVGFESpotLightElement":false,"SVGFETileElement":false,"SVGFETurbulenceElement":false,"SVGFilterElement":false,"SVGForeignObjectElement":false,"SVGGElement":false,"SVGGeometryElement":false,"SVGGradientElement":false,"SVGGraphicsElement":false,"SVGImageElement":false,"SVGLength":false,"SVGLengthList":false,"SVGLinearGradientElement":false,"SVGLineElement":false,"SVGMarkerElement":false,"SVGMaskElement":false,"SVGMatrix":false,"SVGMetadataElement":false,"SVGMPathElement":false,"SVGNumber":false,"SVGNumberList":false,"SVGPathElement":false,"SVGPatternElement":false,"SVGPoint":false,"SVGPointList":false,"SVGPolygonElement":false,"SVGPolylineElement":false,"SVGPreserveAspectRatio":false,"SVGRadialGradientElement":false,"SVGRect":false,"SVGRectElement":false,"SVGScriptElement":false,"SVGSetElement":false,"SVGStopElement":false,"SVGStringList":false,"SVGStyleElement":false,"SVGSVGElement":false,"SVGSwitchElement":false,"SVGSymbolElement":false,"SVGTextContentElement":false,"SVGTextElement":false,"SVGTextPathElement":false,"SVGTextPositioningElement":false,"SVGTitleElement":false,"SVGTransform":false,"SVGTransformList":false,"SVGTSpanElement":false,"SVGUnitTypes":false,"SVGUseElement":false,"SVGViewElement":false,"TaskAttributionTiming":false,"Text":false,"TextDecoder":false,"TextEncoder":false,"TextEvent":false,"TextMetrics":false,"TextTrack":false,"TextTrackCue":false,"TextTrackCueList":false,"TextTrackList":false,"TimeRanges":false,"toolbar":false,"top":false,"Touch":false,"TouchEvent":false,"TouchList":false,"TrackEvent":false,"TransitionEvent":false,"TreeWalker":false,"UIEvent":false,"URL":false,"URLSearchParams":false,"ValidityState":false,"visualViewport":false,"VisualViewport":false,"VTTCue":false,"WaveShaperNode":false,"WebAssembly":false,"WebGL2RenderingContext":false,"WebGLActiveInfo":false,"WebGLBuffer":false,"WebGLContextEvent":false,"WebGLFramebuffer":false,"WebGLProgram":false,"WebGLQuery":false,"WebGLRenderbuffer":false,"WebGLRenderingContext":false,"WebGLSampler":false,"WebGLShader":false,"WebGLShaderPrecisionFormat":false,"WebGLSync":false,"WebGLTexture":false,"WebGLTransformFeedback":false,"WebGLUniformLocation":false,"WebGLVertexArrayObject":false,"WebSocket":false,"WheelEvent":false,"window":false,"Window":false,"Worker":false,"WritableStream":false,"XMLDocument":false,"XMLHttpRequest":false,"XMLHttpRequestEventTarget":false,"XMLHttpRequestUpload":false,"XMLSerializer":false,"XPathEvaluator":false,"XPathExpression":false,"XPathResult":false,"XSLTProcessor":false},"worker":{"addEventListener":false,"applicationCache":false,"atob":false,"Blob":false,"BroadcastChannel":false,"btoa":false,"Cache":false,"caches":false,"clearInterval":false,"clearTimeout":false,"close":true,"console":false,"fetch":false,"FileReaderSync":false,"FormData":false,"Headers":false,"IDBCursor":false,"IDBCursorWithValue":false,"IDBDatabase":false,"IDBFactory":false,"IDBIndex":false,"IDBKeyRange":false,"IDBObjectStore":false,"IDBOpenDBRequest":false,"IDBRequest":false,"IDBTransaction":false,"IDBVersionChangeEvent":false,"ImageData":false,"importScripts":true,"indexedDB":false,"location":false,"MessageChannel":false,"MessagePort":false,"name":false,"navigator":false,"Notification":false,"onclose":true,"onconnect":true,"onerror":true,"onlanguagechange":true,"onmessage":true,"onoffline":true,"ononline":true,"onrejectionhandled":true,"onunhandledrejection":true,"performance":false,"Performance":false,"PerformanceEntry":false,"PerformanceMark":false,"PerformanceMeasure":false,"PerformanceNavigation":false,"PerformanceResourceTiming":false,"PerformanceTiming":false,"postMessage":true,"Promise":false,"queueMicrotask":false,"removeEventListener":false,"Request":false,"Response":false,"self":true,"ServiceWorkerRegistration":false,"setInterval":false,"setTimeout":false,"TextDecoder":false,"TextEncoder":false,"URL":false,"URLSearchParams":false,"WebSocket":false,"Worker":false,"WorkerGlobalScope":false,"XMLHttpRequest":false},"node":{"__dirname":false,"__filename":false,"Buffer":false,"clearImmediate":false,"clearInterval":false,"clearTimeout":false,"console":false,"exports":true,"global":false,"Intl":false,"module":false,"process":false,"queueMicrotask":false,"require":false,"setImmediate":false,"setInterval":false,"setTimeout":false,"TextDecoder":false,"TextEncoder":false,"URL":false,"URLSearchParams":false},"commonjs":{"exports":true,"global":false,"module":false,"require":false},"amd":{"define":false,"require":false},"mocha":{"after":false,"afterEach":false,"before":false,"beforeEach":false,"context":false,"describe":false,"it":false,"mocha":false,"run":false,"setup":false,"specify":false,"suite":false,"suiteSetup":false,"suiteTeardown":false,"teardown":false,"test":false,"xcontext":false,"xdescribe":false,"xit":false,"xspecify":false},"jasmine":{"afterAll":false,"afterEach":false,"beforeAll":false,"beforeEach":false,"describe":false,"expect":false,"fail":false,"fdescribe":false,"fit":false,"it":false,"jasmine":false,"pending":false,"runs":false,"spyOn":false,"spyOnProperty":false,"waits":false,"waitsFor":false,"xdescribe":false,"xit":false},"jest":{"afterAll":false,"afterEach":false,"beforeAll":false,"beforeEach":false,"describe":false,"expect":false,"fdescribe":false,"fit":false,"it":false,"jest":false,"pit":false,"require":false,"test":false,"xdescribe":false,"xit":false,"xtest":false},"qunit":{"asyncTest":false,"deepEqual":false,"equal":false,"expect":false,"module":false,"notDeepEqual":false,"notEqual":false,"notOk":false,"notPropEqual":false,"notStrictEqual":false,"ok":false,"propEqual":false,"QUnit":false,"raises":false,"start":false,"stop":false,"strictEqual":false,"test":false,"throws":false},"phantomjs":{"console":true,"exports":true,"phantom":true,"require":true,"WebPage":true},"couch":{"emit":false,"exports":false,"getRow":false,"log":false,"module":false,"provides":false,"require":false,"respond":false,"send":false,"start":false,"sum":false},"rhino":{"defineClass":false,"deserialize":false,"gc":false,"help":false,"importClass":false,"importPackage":false,"java":false,"load":false,"loadClass":false,"Packages":false,"print":false,"quit":false,"readFile":false,"readUrl":false,"runCommand":false,"seal":false,"serialize":false,"spawn":false,"sync":false,"toint32":false,"version":false},"nashorn":{"__DIR__":false,"__FILE__":false,"__LINE__":false,"com":false,"edu":false,"exit":false,"java":false,"Java":false,"javafx":false,"JavaImporter":false,"javax":false,"JSAdapter":false,"load":false,"loadWithNewGlobal":false,"org":false,"Packages":false,"print":false,"quit":false},"wsh":{"ActiveXObject":true,"Enumerator":true,"GetObject":true,"ScriptEngine":true,"ScriptEngineBuildVersion":true,"ScriptEngineMajorVersion":true,"ScriptEngineMinorVersion":true,"VBArray":true,"WScript":true,"WSH":true,"XDomainRequest":true},"jquery":{"$":false,"jQuery":false},"yui":{"YAHOO":false,"YAHOO_config":false,"YUI":false,"YUI_config":false},"shelljs":{"cat":false,"cd":false,"chmod":false,"config":false,"cp":false,"dirs":false,"echo":false,"env":false,"error":false,"exec":false,"exit":false,"find":false,"grep":false,"ln":false,"ls":false,"mkdir":false,"mv":false,"popd":false,"pushd":false,"pwd":false,"rm":false,"sed":false,"set":false,"target":false,"tempdir":false,"test":false,"touch":false,"which":false},"prototypejs":{"$":false,"$$":false,"$A":false,"$break":false,"$continue":false,"$F":false,"$H":false,"$R":false,"$w":false,"Abstract":false,"Ajax":false,"Autocompleter":false,"Builder":false,"Class":false,"Control":false,"Draggable":false,"Draggables":false,"Droppables":false,"Effect":false,"Element":false,"Enumerable":false,"Event":false,"Field":false,"Form":false,"Hash":false,"Insertion":false,"ObjectRange":false,"PeriodicalExecuter":false,"Position":false,"Prototype":false,"Scriptaculous":false,"Selector":false,"Sortable":false,"SortableObserver":false,"Sound":false,"Template":false,"Toggle":false,"Try":false},"meteor":{"_":false,"$":false,"Accounts":false,"AccountsClient":false,"AccountsCommon":false,"AccountsServer":false,"App":false,"Assets":false,"Blaze":false,"check":false,"Cordova":false,"DDP":false,"DDPRateLimiter":false,"DDPServer":false,"Deps":false,"EJSON":false,"Email":false,"HTTP":false,"Log":false,"Match":false,"Meteor":false,"Mongo":false,"MongoInternals":false,"Npm":false,"Package":false,"Plugin":false,"process":false,"Random":false,"ReactiveDict":false,"ReactiveVar":false,"Router":false,"ServiceConfiguration":false,"Session":false,"share":false,"Spacebars":false,"Template":false,"Tinytest":false,"Tracker":false,"UI":false,"Utils":false,"WebApp":false,"WebAppInternals":false},"mongo":{"_isWindows":false,"_rand":false,"BulkWriteResult":false,"cat":false,"cd":false,"connect":false,"db":false,"getHostName":false,"getMemInfo":false,"hostname":false,"ISODate":false,"listFiles":false,"load":false,"ls":false,"md5sumFile":false,"mkdir":false,"Mongo":false,"NumberInt":false,"NumberLong":false,"ObjectId":false,"PlanCache":false,"print":false,"printjson":false,"pwd":false,"quit":false,"removeFile":false,"rs":false,"sh":false,"UUID":false,"version":false,"WriteResult":false},"applescript":{"$":false,"Application":false,"Automation":false,"console":false,"delay":false,"Library":false,"ObjC":false,"ObjectSpecifier":false,"Path":false,"Progress":false,"Ref":false},"serviceworker":{"addEventListener":false,"applicationCache":false,"atob":false,"Blob":false,"BroadcastChannel":false,"btoa":false,"Cache":false,"caches":false,"CacheStorage":false,"clearInterval":false,"clearTimeout":false,"Client":false,"clients":false,"Clients":false,"close":true,"console":false,"ExtendableEvent":false,"ExtendableMessageEvent":false,"fetch":false,"FetchEvent":false,"FileReaderSync":false,"FormData":false,"Headers":false,"IDBCursor":false,"IDBCursorWithValue":false,"IDBDatabase":false,"IDBFactory":false,"IDBIndex":false,"IDBKeyRange":false,"IDBObjectStore":false,"IDBOpenDBRequest":false,"IDBRequest":false,"IDBTransaction":false,"IDBVersionChangeEvent":false,"ImageData":false,"importScripts":false,"indexedDB":false,"location":false,"MessageChannel":false,"MessagePort":false,"name":false,"navigator":false,"Notification":false,"onclose":true,"onconnect":true,"onerror":true,"onfetch":true,"oninstall":true,"onlanguagechange":true,"onmessage":true,"onmessageerror":true,"onnotificationclick":true,"onnotificationclose":true,"onoffline":true,"ononline":true,"onpush":true,"onpushsubscriptionchange":true,"onrejectionhandled":true,"onsync":true,"onunhandledrejection":true,"performance":false,"Performance":false,"PerformanceEntry":false,"PerformanceMark":false,"PerformanceMeasure":false,"PerformanceNavigation":false,"PerformanceResourceTiming":false,"PerformanceTiming":false,"postMessage":true,"Promise":false,"queueMicrotask":false,"registration":false,"removeEventListener":false,"Request":false,"Response":false,"self":false,"ServiceWorker":false,"ServiceWorkerContainer":false,"ServiceWorkerGlobalScope":false,"ServiceWorkerMessageEvent":false,"ServiceWorkerRegistration":false,"setInterval":false,"setTimeout":false,"skipWaiting":false,"TextDecoder":false,"TextEncoder":false,"URL":false,"URLSearchParams":false,"WebSocket":false,"WindowClient":false,"Worker":false,"WorkerGlobalScope":false,"XMLHttpRequest":false},"atomtest":{"advanceClock":false,"fakeClearInterval":false,"fakeClearTimeout":false,"fakeSetInterval":false,"fakeSetTimeout":false,"resetTimeouts":false,"waitsForPromise":false},"embertest":{"andThen":false,"click":false,"currentPath":false,"currentRouteName":false,"currentURL":false,"fillIn":false,"find":false,"findAll":false,"findWithAssert":false,"keyEvent":false,"pauseTest":false,"resumeTest":false,"triggerEvent":false,"visit":false,"wait":false},"protractor":{"$":false,"$$":false,"browser":false,"by":false,"By":false,"DartObject":false,"element":false,"protractor":false},"shared-node-browser":{"clearInterval":false,"clearTimeout":false,"console":false,"setInterval":false,"setTimeout":false,"URL":false,"URLSearchParams":false},"webextensions":{"browser":false,"chrome":false,"opr":false},"greasemonkey":{"cloneInto":false,"createObjectIn":false,"exportFunction":false,"GM":false,"GM_addStyle":false,"GM_deleteValue":false,"GM_getResourceText":false,"GM_getResourceURL":false,"GM_getValue":false,"GM_info":false,"GM_listValues":false,"GM_log":false,"GM_openInTab":false,"GM_registerMenuCommand":false,"GM_setClipboard":false,"GM_setValue":false,"GM_xmlhttpRequest":false,"unsafeWindow":false},"devtools":{"$":false,"$_":false,"$$":false,"$0":false,"$1":false,"$2":false,"$3":false,"$4":false,"$x":false,"chrome":false,"clear":false,"copy":false,"debug":false,"dir":false,"dirxml":false,"getEventListeners":false,"inspect":false,"keys":false,"monitor":false,"monitorEvents":false,"profile":false,"profileEnd":false,"queryObjects":false,"table":false,"undebug":false,"unmonitor":false,"unmonitorEvents":false,"values":false}}')},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,i=(r=n(125))&&r.__esModule?r:{default:r};t.default=class{constructor(e,t){this._cachedMap=null,this._code=t,this._opts=e,this._rawMappings=[]}get(){if(!this._cachedMap){const e=this._cachedMap=new i.default.SourceMapGenerator({sourceRoot:this._opts.sourceRoot}),t=this._code;"string"==typeof t?e.setSourceContent(this._opts.sourceFileName.replace(/\\/g,"/"),t):"object"==typeof t&&Object.keys(t).forEach(n=>{e.setSourceContent(n.replace(/\\/g,"/"),t[n])}),this._rawMappings.forEach(t=>e.addMapping(t),e)}return this._cachedMap.toJSON()}getRawMappings(){return this._rawMappings.slice()}mark(e,t,n,r,i,o,a){this._lastGenLine!==e&&null===n||(a||this._lastGenLine!==e||this._lastSourceLine!==n||this._lastSourceColumn!==r)&&(this._cachedMap=null,this._lastGenLine=e,this._lastSourceLine=n,this._lastSourceColumn=r,this._rawMappings.push({name:i||void 0,generated:{line:e,column:t},source:null==n?void 0:(o||this._opts.sourceFileName).replace(/\\/g,"/"),original:null==n?void 0:{line:n,column:r}}))}}},function(e,t){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");t.encode=function(e){if(0<=e&&ei||o==i&&s>=a||r.compareByGeneratedPositionsInflated(t,n)<=0?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))},i.prototype.toArray=function(){return this._sorted||(this._array.sort(r.compareByGeneratedPositionsInflated),this._sorted=!0),this._array},t.MappingList=i},function(e,t,n){var r=n(24),i=n(304),o=n(128).ArraySet,a=n(127),s=n(305).quickSort;function u(e){var t=e;return"string"==typeof e&&(t=JSON.parse(e.replace(/^\)\]\}'/,""))),null!=t.sections?new f(t):new c(t)}function c(e){var t=e;"string"==typeof e&&(t=JSON.parse(e.replace(/^\)\]\}'/,"")));var n=r.getArg(t,"version"),i=r.getArg(t,"sources"),a=r.getArg(t,"names",[]),s=r.getArg(t,"sourceRoot",null),u=r.getArg(t,"sourcesContent",null),c=r.getArg(t,"mappings"),l=r.getArg(t,"file",null);if(n!=this._version)throw new Error("Unsupported version: "+n);i=i.map(String).map(r.normalize).map((function(e){return s&&r.isAbsolute(s)&&r.isAbsolute(e)?r.relative(s,e):e})),this._names=o.fromArray(a.map(String),!0),this._sources=o.fromArray(i,!0),this.sourceRoot=s,this.sourcesContent=u,this._mappings=c,this.file=l}function l(){this.generatedLine=0,this.generatedColumn=0,this.source=null,this.originalLine=null,this.originalColumn=null,this.name=null}function f(e){var t=e;"string"==typeof e&&(t=JSON.parse(e.replace(/^\)\]\}'/,"")));var n=r.getArg(t,"version"),i=r.getArg(t,"sections");if(n!=this._version)throw new Error("Unsupported version: "+n);this._sources=new o,this._names=new o;var a={line:-1,column:0};this._sections=i.map((function(e){if(e.url)throw new Error("Support for url field in sections not implemented.");var t=r.getArg(e,"offset"),n=r.getArg(t,"line"),i=r.getArg(t,"column");if(n=0){var s=this._originalMappings[a];if(void 0===e.column)for(var u=s.originalLine;s&&s.originalLine===u;)o.push({line:r.getArg(s,"generatedLine",null),column:r.getArg(s,"generatedColumn",null),lastColumn:r.getArg(s,"lastGeneratedColumn",null)}),s=this._originalMappings[++a];else for(var c=s.originalColumn;s&&s.originalLine===t&&s.originalColumn==c;)o.push({line:r.getArg(s,"generatedLine",null),column:r.getArg(s,"generatedColumn",null),lastColumn:r.getArg(s,"lastGeneratedColumn",null)}),s=this._originalMappings[++a]}return o},t.SourceMapConsumer=u,c.prototype=Object.create(u.prototype),c.prototype.consumer=u,c.fromSourceMap=function(e){var t=Object.create(c.prototype),n=t._names=o.fromArray(e._names.toArray(),!0),i=t._sources=o.fromArray(e._sources.toArray(),!0);t.sourceRoot=e._sourceRoot,t.sourcesContent=e._generateSourcesContent(t._sources.toArray(),t.sourceRoot),t.file=e._file;for(var a=e._mappings.toArray().slice(),u=t.__generatedMappings=[],f=t.__originalMappings=[],p=0,h=a.length;p1&&(n.source=y+o[1],y+=o[1],n.originalLine=h+o[2],h=n.originalLine,n.originalLine+=1,n.originalColumn=d+o[3],d=n.originalColumn,o.length>4&&(n.name=m+o[4],m+=o[4])),O.push(n),"number"==typeof n.originalLine&&S.push(n)}s(O,r.compareByGeneratedPositionsDeflated),this.__generatedMappings=O,s(S,r.compareByOriginalPositions),this.__originalMappings=S},c.prototype._findMapping=function(e,t,n,r,o,a){if(e[n]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+e[n]);if(e[r]<0)throw new TypeError("Column must be greater than or equal to 0, got "+e[r]);return i.search(e,t,o,a)},c.prototype.computeColumnSpans=function(){for(var e=0;e=0){var i=this._generatedMappings[n];if(i.generatedLine===t.generatedLine){var o=r.getArg(i,"source",null);null!==o&&(o=this._sources.at(o),null!=this.sourceRoot&&(o=r.join(this.sourceRoot,o)));var a=r.getArg(i,"name",null);return null!==a&&(a=this._names.at(a)),{source:o,line:r.getArg(i,"originalLine",null),column:r.getArg(i,"originalColumn",null),name:a}}}return{source:null,line:null,column:null,name:null}},c.prototype.hasContentsOfAllSources=function(){return!!this.sourcesContent&&(this.sourcesContent.length>=this._sources.size()&&!this.sourcesContent.some((function(e){return null==e})))},c.prototype.sourceContentFor=function(e,t){if(!this.sourcesContent)return null;if(null!=this.sourceRoot&&(e=r.relative(this.sourceRoot,e)),this._sources.has(e))return this.sourcesContent[this._sources.indexOf(e)];var n;if(null!=this.sourceRoot&&(n=r.urlParse(this.sourceRoot))){var i=e.replace(/^file:\/\//,"");if("file"==n.scheme&&this._sources.has(i))return this.sourcesContent[this._sources.indexOf(i)];if((!n.path||"/"==n.path)&&this._sources.has("/"+e))return this.sourcesContent[this._sources.indexOf("/"+e)]}if(t)return null;throw new Error('"'+e+'" is not in the SourceMap.')},c.prototype.generatedPositionFor=function(e){var t=r.getArg(e,"source");if(null!=this.sourceRoot&&(t=r.relative(this.sourceRoot,t)),!this._sources.has(t))return{line:null,column:null,lastColumn:null};var n={source:t=this._sources.indexOf(t),originalLine:r.getArg(e,"line"),originalColumn:r.getArg(e,"column")},i=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",r.compareByOriginalPositions,r.getArg(e,"bias",u.GREATEST_LOWER_BOUND));if(i>=0){var o=this._originalMappings[i];if(o.source===n.source)return{line:r.getArg(o,"generatedLine",null),column:r.getArg(o,"generatedColumn",null),lastColumn:r.getArg(o,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}},t.BasicSourceMapConsumer=c,f.prototype=Object.create(u.prototype),f.prototype.constructor=u,f.prototype._version=3,Object.defineProperty(f.prototype,"sources",{get:function(){for(var e=[],t=0;t0?r-u>1?e(u,r,i,o,a,s):s==t.LEAST_UPPER_BOUND?r1?e(n,u,i,o,a,s):s==t.LEAST_UPPER_BOUND?u:n<0?-1:n}(-1,n.length,e,n,r,i||t.GREATEST_LOWER_BOUND);if(o<0)return-1;for(;o-1>=0&&0===r(n[o],n[o-1],!0);)--o;return o}},function(e,t){function n(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function r(e,t,i,o){if(i=0;t--)this.prepend(e[t]);else{if(!e[a]&&"string"!=typeof e)throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);this.children.unshift(e)}return this},s.prototype.walk=function(e){for(var t,n=0,r=this.children.length;n0){for(t=[],n=0;n{r.call(this,e,t)}),this._printTrailingComments(e),o&&this.token(")"),this._printStack.pop(),this.format.concise=n,this._insideAux=i}_maybeAddAuxComment(e){e&&this._printAuxBeforeComment(),this._insideAux||this._printAuxAfterComment()}_printAuxBeforeComment(){if(this._printAuxAfterOnNextUserNode)return;this._printAuxAfterOnNextUserNode=!0;const e=this.format.auxiliaryCommentBefore;e&&this._printComment({type:"CommentBlock",value:e})}_printAuxAfterComment(){if(!this._printAuxAfterOnNextUserNode)return;this._printAuxAfterOnNextUserNode=!1;const e=this.format.auxiliaryCommentAfter;e&&this._printComment({type:"CommentBlock",value:e})}getPossibleRaw(e){const t=e.extra;if(t&&null!=t.raw&&null!=t.rawValue&&e.value===t.rawValue)return t.raw}printJoin(e,t,n={}){if(!e||!e.length)return;n.indent&&this.indent();const r={addNewlines:n.addNewlines};for(let i=0;i0;n&&this.indent(),this.print(e,t),n&&this.dedent()}printBlock(e){const t=e.body;s.isEmptyStatement(t)||this.space(),this.print(t,e)}_printTrailingComments(e){this._printComments(this._getComments(!1,e))}_printLeadingComments(e){this._printComments(this._getComments(!0,e))}printInnerComments(e,t=!0){e.innerComments&&e.innerComments.length&&(t&&this.indent(),this._printComments(e.innerComments),t&&this.dedent())}printSequence(e,t,n={}){return n.statement=!0,this.printJoin(e,t,n)}printList(e,t,n={}){return null==n.separator&&(n.separator=m),this.printJoin(e,t,n)}_printNewline(e,t,n,r){if(this.format.retainLines||this.format.compact)return;if(this.format.concise)return void this.space();let i=0;if(this._buf.hasContent()){e||i++,r.addNewlines&&(i+=r.addNewlines(e,t)||0),(e?a.needsWhitespaceBefore:a.needsWhitespaceAfter)(t,n)&&i++}this.newline(i)}_getComments(e,t){return t&&(e?t.leadingComments:t.trailingComments)||[]}_printComment(e){if(!this.format.shouldPrintComment(e.value))return;if(e.ignore)return;if(this._printedComments.has(e))return;if(this._printedComments.add(e),null!=e.start){if(this._printedCommentStarts[e.start])return;this._printedCommentStarts[e.start]=!0}const t="CommentBlock"===e.type;this.newline(this._buf.hasContent()&&!this._noLineTerminator&&t?1:0),this.endsWith("[")||this.endsWith("{")||this.space();let n=t||this._noLineTerminator?`/*${e.value}*/`:`//${e.value}\n`;if(t&&this.format.indent.adjustMultilineComment){const t=e.loc&&e.loc.start.column;if(t){const e=new RegExp("\\n\\s{1,"+t+"}","g");n=n.replace(e,"\n")}const r=Math.max(this._getIndent().length,this._buf.getCurrentColumn());n=n.replace(/\n(?!$)/g,`\n${(0,i.default)(" ",r)}`)}this.endsWith("/")&&this._space(),this.withSource("start",e.loc,()=>{this._append(n)}),this.newline(t&&!this._noLineTerminator?1:0)}_printComments(e){if(e&&e.length)for(const t of e)this._printComment(t)}}function m(){this.token(","),this.space()}t.default=y,Object.assign(y.prototype,u)},function(e,t,n){var r=n(69);e.exports=function(e){return"number"==typeof e&&e==r(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;const r=/^[ \t]+$/;t.default=class{constructor(e){this._map=null,this._buf=[],this._last="",this._queue=[],this._position={line:1,column:0},this._sourcePosition={identifierName:null,line:null,column:null,filename:null},this._disallowedPop=null,this._map=e}get(){this._flush();const e=this._map,t={code:this._buf.join("").trimRight(),map:null,rawMappings:e&&e.getRawMappings()};return e&&Object.defineProperty(t,"map",{configurable:!0,enumerable:!0,get(){return this.map=e.get()},set(e){Object.defineProperty(this,"map",{value:e,writable:!0})}}),t}append(e){this._flush();const{line:t,column:n,filename:r,identifierName:i,force:o}=this._sourcePosition;this._append(e,t,n,i,r,o)}queue(e){if("\n"===e)for(;this._queue.length>0&&r.test(this._queue[0][0]);)this._queue.shift();const{line:t,column:n,filename:i,identifierName:o,force:a}=this._sourcePosition;this._queue.unshift([e,t,n,o,i,a])}_flush(){let e;for(;e=this._queue.pop();)this._append(...e)}_append(e,t,n,r,i,o){this._map&&"\n"!==e[0]&&this._map.mark(this._position.line,this._position.column,t,n,r,i,o),this._buf.push(e),this._last=e[e.length-1];for(let t=0;t0&&"\n"===this._queue[0][0]&&this._queue.shift()}removeLastSemicolon(){this._queue.length>0&&";"===this._queue[0][0]&&this._queue.shift()}endsWith(e){if(1===e.length){let t;if(this._queue.length>0){const e=this._queue[0][0];t=e[e.length-1]}else t=this._last;return t===e}const t=this._last+this._queue.reduce((e,t)=>t[0]+e,"");return e.length<=t.length&&t.slice(-e.length)===e}hasContent(){return this._queue.length>0||!!this._last}exactSource(e,t){this.source("start",e,!0),t(),this.source("end",e),this._disallowPop("start",e)}source(e,t,n){e&&!t||this._normalizePosition(e,t,this._sourcePosition,n)}withSource(e,t,n){if(!this._map)return n();const r=this._sourcePosition.line,i=this._sourcePosition.column,o=this._sourcePosition.filename,a=this._sourcePosition.identifierName;this.source(e,t),n(),this._sourcePosition.force&&this._sourcePosition.line===r&&this._sourcePosition.column===i&&this._sourcePosition.filename===o||this._disallowedPop&&this._disallowedPop.line===r&&this._disallowedPop.column===i&&this._disallowedPop.filename===o||(this._sourcePosition.line=r,this._sourcePosition.column=i,this._sourcePosition.filename=o,this._sourcePosition.identifierName=a,this._sourcePosition.force=!1,this._disallowedPop=null)}_disallowPop(e,t){e&&!t||(this._disallowedPop=this._normalizePosition(e,t))}_normalizePosition(e,t,n,r){const i=t?t[e]:null;void 0===n&&(n={identifierName:null,line:null,column:null,filename:null,force:!1});const o=n.line,a=n.column,s=n.filename;return n.identifierName="start"===e&&t&&t.identifierName||null,n.line=i?i.line:null,n.column=i?i.column:null,n.filename=t&&t.filename||null,(r||n.line!==o||n.column!==a||n.filename!==s)&&(n.force=r),n}getCurrentColumn(){const e=this._queue.reduce((e,t)=>t[0]+e,""),t=e.lastIndexOf("\n");return-1===t?this._position.column+e.length:e.length-1-t}getCurrentLine(){const e=this._queue.reduce((e,t)=>t[0]+e,"");let t=0;for(let n=0;n({before:e.consequent.length||t.cases[0]===e,after:!e.consequent.length&&t.cases[t.cases.length-1]===e}),LogicalExpression(e){if(r.isFunction(e.left)||r.isFunction(e.right))return{after:!0}},Literal(e){if("use strict"===e.value)return{after:!0}},CallExpression(e){if(r.isFunction(e.callee)||a(e))return{before:!0,after:!0}},VariableDeclaration(e){for(let t=0;te.declarations.map(e=>e.init),ArrayExpression:e=>e.elements,ObjectExpression:e=>e.properties};t.list=c,[["Function",!0],["Class",!0],["Loop",!0],["LabeledStatement",!0],["SwitchStatement",!0],["TryStatement",!0]].forEach((function([e,t]){"boolean"==typeof t&&(t={after:t,before:t}),[e].concat(r.FLIPPED_ALIAS_KEYS[e]||[]).forEach((function(e){u[e]=function(){return t}}))}))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NullableTypeAnnotation=function(e,t){return r.isArrayTypeAnnotation(t)},t.FunctionTypeAnnotation=function(e,t,n){return r.isUnionTypeAnnotation(t)||r.isIntersectionTypeAnnotation(t)||r.isArrayTypeAnnotation(t)||r.isTypeAnnotation(t)&&r.isArrowFunctionExpression(n[n.length-3])},t.UpdateExpression=function(e,t){return r.isMemberExpression(t,{object:e})||r.isCallExpression(t,{callee:e})||r.isNewExpression(t,{callee:e})||a(e,t)},t.ObjectExpression=function(e,t,n){return c(n,{considerArrow:!0})},t.DoExpression=function(e,t,n){return c(n)},t.Binary=function(e,t){if("**"===e.operator&&r.isBinaryExpression(t,{operator:"**"}))return t.left===e;if(a(e,t))return!0;if((r.isCallExpression(t)||r.isNewExpression(t))&&t.callee===e||r.isUnaryLike(t)||r.isMemberExpression(t)&&t.object===e||r.isAwaitExpression(t))return!0;if(r.isBinary(t)){const n=t.operator,i=o[n],a=e.operator,s=o[a];if(i===s&&t.right===e&&!r.isLogicalExpression(t)||i>s)return!0}return!1},t.IntersectionTypeAnnotation=t.UnionTypeAnnotation=function(e,t){return r.isArrayTypeAnnotation(t)||r.isNullableTypeAnnotation(t)||r.isIntersectionTypeAnnotation(t)||r.isUnionTypeAnnotation(t)},t.TSAsExpression=function(){return!0},t.TSTypeAssertion=function(){return!0},t.TSIntersectionType=t.TSUnionType=function(e,t){return r.isTSArrayType(t)||r.isTSOptionalType(t)||r.isTSIntersectionType(t)||r.isTSUnionType(t)||r.isTSRestType(t)},t.BinaryExpression=function(e,t){return"in"===e.operator&&(r.isVariableDeclarator(t)||r.isFor(t))},t.SequenceExpression=function(e,t){if(r.isForStatement(t)||r.isThrowStatement(t)||r.isReturnStatement(t)||r.isIfStatement(t)&&t.test===e||r.isWhileStatement(t)&&t.test===e||r.isForInStatement(t)&&t.right===e||r.isSwitchStatement(t)&&t.discriminant===e||r.isExpressionStatement(t)&&t.expression===e)return!1;return!0},t.AwaitExpression=t.YieldExpression=function(e,t){return r.isBinary(t)||r.isUnaryLike(t)||r.isCallExpression(t)||r.isMemberExpression(t)||r.isNewExpression(t)||r.isAwaitExpression(t)&&r.isYieldExpression(e)||r.isConditionalExpression(t)&&e===t.test||a(e,t)},t.ClassExpression=function(e,t,n){return c(n,{considerDefaultExports:!0})},t.UnaryLike=s,t.FunctionExpression=function(e,t,n){return c(n,{considerDefaultExports:!0})},t.ArrowFunctionExpression=function(e,t){return r.isExportDeclaration(t)||u(e,t)},t.ConditionalExpression=u,t.OptionalMemberExpression=function(e,t){return r.isCallExpression(t)||r.isMemberExpression(t)},t.AssignmentExpression=function(e){return!!r.isObjectPattern(e.left)||u(...arguments)},t.NewExpression=function(e,t){return a(e,t)};var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=r?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(0));function i(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}const o={"||":0,"&&":1,"|":2,"^":3,"&":4,"==":5,"===":5,"!=":5,"!==":5,"<":6,">":6,"<=":6,">=":6,in:6,instanceof:6,">>":7,"<<":7,">>>":7,"+":8,"-":8,"*":9,"/":9,"%":9,"**":10},a=(e,t)=>(r.isClassDeclaration(t)||r.isClassExpression(t))&&t.superClass===e;function s(e,t){return r.isMemberExpression(t,{object:e})||r.isCallExpression(t,{callee:e})||r.isNewExpression(t,{callee:e})||r.isBinaryExpression(t,{operator:"**",left:e})||a(e,t)}function u(e,t){return!!(r.isUnaryLike(t)||r.isBinary(t)||r.isConditionalExpression(t,{test:e})||r.isAwaitExpression(t)||r.isOptionalMemberExpression(t)||r.isTaggedTemplateExpression(t)||r.isTSTypeAssertion(t)||r.isTSAsExpression(t))||s(e,t)}function c(e,{considerArrow:t=!1,considerDefaultExports:n=!1}={}){let i=e.length-1,o=e[i];i--;let a=e[i];for(;i>0;){if(r.isExpressionStatement(a,{expression:o})||r.isTaggedTemplateExpression(a)||n&&r.isExportDefaultDeclaration(a,{declaration:o})||t&&r.isArrowFunctionExpression(a,{body:o}))return!0;if(!(r.isCallExpression(a,{callee:o})||r.isSequenceExpression(a)&&a.expressions[0]===o||r.isMemberExpression(a,{object:o})||r.isConditional(a,{test:o})||r.isBinary(a,{left:o})||r.isAssignmentExpression(a,{left:o})))return!1;o=a,i--,a=e[i]}return!1}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(313);Object.keys(r).forEach((function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return r[e]}})}));var i=n(314);Object.keys(i).forEach((function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return i[e]}})}));var o=n(315);Object.keys(o).forEach((function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return o[e]}})}));var a=n(316);Object.keys(a).forEach((function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return a[e]}})}));var s=n(317);Object.keys(s).forEach((function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return s[e]}})}));var u=n(130);Object.keys(u).forEach((function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return u[e]}})}));var c=n(131);Object.keys(c).forEach((function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return c[e]}})}));var l=n(322);Object.keys(l).forEach((function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return l[e]}})}));var f=n(323);Object.keys(f).forEach((function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return f[e]}})}));var p=n(324);Object.keys(p).forEach((function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return p[e]}})}));var h=n(325);Object.keys(h).forEach((function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return h[e]}})}))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TaggedTemplateExpression=function(e){this.print(e.tag,e),this.print(e.typeParameters,e),this.print(e.quasi,e)},t.TemplateElement=function(e,t){const n=t.quasis[0]===e,r=t.quasis[t.quasis.length-1]===e,i=(n?"`":"}")+e.value.raw+(r?"`":"${");this.token(i)},t.TemplateLiteral=function(e){const t=e.quasis;for(let n=0;ne.loc.start.line?(this.indent(),this.print(t,e),this.dedent(),this._catchUp("start",e.body.loc)):this.print(t,e),this.token(")")):this.print(t,e):this._params(e);this._predicate(e),this.space(),this.token("=>"),this.space(),this.print(e.body,e)};var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=r?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(0));function i(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}},function(e,t,n){"use strict";(function(t){const n={},r=n.hasOwnProperty,i=(e,t)=>{for(const n in e)r.call(e,n)&&t(n,e[n])},o=n.toString,a=Array.isArray,s=t.isBuffer,u={'"':'\\"',"'":"\\'","\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t"},c=/["'\\\b\f\n\r\t]/,l=/[0-9]/,f=/[ !#-&\(-\[\]-_a-~]/,p=(e,t)=>{const n=()=>{w=g,++t.indentLevel,g=t.indent.repeat(t.indentLevel)},r={escapeEverything:!1,minimal:!1,isScriptContext:!1,quotes:"single",wrap:!1,es6:!1,json:!1,compact:!0,lowercaseHex:!1,numbers:"decimal",indent:"\t",indentLevel:0,__inline1__:!1,__inline2__:!1},h=t&&t.json;var d,y;h&&(r.quotes="double",r.wrap=!0),d=r,"single"!=(t=(y=t)?(i(y,(e,t)=>{d[e]=t}),d):d).quotes&&"double"!=t.quotes&&"backtick"!=t.quotes&&(t.quotes="single");const m="double"==t.quotes?'"':"backtick"==t.quotes?"`":"'",v=t.compact,b=t.lowercaseHex;let g=t.indent.repeat(t.indentLevel),w="";const S=t.__inline1__,O=t.__inline2__,P=v?"":"\n";let k,x=!0;const E="binary"==t.numbers,j="octal"==t.numbers,T="decimal"==t.numbers,C="hexadecimal"==t.numbers;if(h&&e&&"function"==typeof e.toJSON&&(e=e.toJSON()),!(e=>"string"==typeof e||"[object String]"==o.call(e))(e)){if((e=>"[object Map]"==o.call(e))(e))return 0==e.size?"new Map()":(v||(t.__inline1__=!0,t.__inline2__=!1),"new Map("+p(Array.from(e),t)+")");if((e=>"[object Set]"==o.call(e))(e))return 0==e.size?"new Set()":"new Set("+p(Array.from(e),t)+")";if(s(e))return 0==e.length?"Buffer.from([])":"Buffer.from("+p(Array.from(e),t)+")";if(a(e))return k=[],t.wrap=!0,S&&(t.__inline1__=!1,t.__inline2__=!0),O||n(),((e,t)=>{const n=e.length;let r=-1;for(;++r{x=!1,O&&(t.__inline2__=!1),k.push((v||O?"":g)+p(e,t))}),x?"[]":O?"["+k.join(", ")+"]":"["+P+k.join(","+P)+P+(v?"":w)+"]";if(!(e=>"number"==typeof e||"[object Number]"==o.call(e))(e))return(e=>"[object Object]"==o.call(e))(e)?(k=[],t.wrap=!0,n(),i(e,(e,n)=>{x=!1,k.push((v?"":g)+p(e,t)+":"+(v?"":" ")+p(n,t))}),x?"{}":"{"+P+k.join(","+P)+P+(v?"":w)+"}"):h?JSON.stringify(e)||"null":String(e);if(h)return JSON.stringify(e);if(T)return String(e);if(C){let t=e.toString(16);return b||(t=t.toUpperCase()),"0x"+t}if(E)return"0b"+e.toString(2);if(j)return"0o"+e.toString(8)}const _=e;let A=-1;const D=_.length;for(k="";++A=55296&&e<=56319&&D>A+1){const t=_.charCodeAt(A+1);if(t>=56320&&t<=57343){let n=(1024*(e-55296)+t-56320+65536).toString(16);b||(n=n.toUpperCase()),k+="\\u{"+n+"}",++A;continue}}}if(!t.escapeEverything){if(f.test(e)){k+=e;continue}if('"'==e){k+=m==e?'\\"':e;continue}if("`"==e){k+=m==e?"\\`":e;continue}if("'"==e){k+=m==e?"\\'":e;continue}}if("\0"==e&&!h&&!l.test(_.charAt(A+1))){k+="\\0";continue}if(c.test(e)){k+=u[e];continue}const n=e.charCodeAt(0);if(t.minimal&&8232!=n&&8233!=n){k+=e;continue}let r=n.toString(16);b||(r=r.toUpperCase());const i=r.length>2||h,o="\\"+(i?"u":"x")+("0000"+r).slice(i?-4:-2);k+=o}return t.wrap&&(k=m+k+m),"`"==m&&(k=k.replace(/\$\{/g,"\\${")),t.isScriptContext?k.replace(/<\/(script|style)/gi,"<\\/$1").replace(/